diff -urN src/contrib/ntp/COPYRIGHT src.ntp/contrib/ntp/COPYRIGHT --- src/contrib/ntp/COPYRIGHT 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/COPYRIGHT 2010-05-11 09:53:31.000000000 +0200 @@ -2,9 +2,9 @@ Copyright Notice - jpg "Clone me," says Dolly sheepishly + jpg "Clone me," says Dolly sheepishly. - Last update: 20:31 UTC Saturday, January 06, 2007 + Last update: 11-May-2010 04:41 UTC _________________________________________________________________ The following copyright notice applies to all files collectively @@ -13,7 +13,7 @@ applies as if the text was explicitly included in the file. *********************************************************************** * * -* Copyright (c) David L. Mills 1992-2009 * +* Copyright (c) University of Delaware 1992-2010 * * * * Permission to use, copy, modify, and distribute this software and * * its documentation for any purpose with or without fee is hereby * @@ -39,81 +39,88 @@ 3. [3]Viraj Bais and [4]Clayton Kirkwood port to WindowsNT 3.5 4. [5]Michael Barone GPSVME fixes - 5. [6]Jean-Francois Boudreault - IPv6 support - 6. [7]Karl Berry syslog to file option - 7. [8]Greg Brackley Major rework of WINNT + 5. [6]Karl Berry syslog to file option + 6. [7]Greg Brackley Major rework of WINNT port. Clean up recvbuf and iosignal code into separate modules. - 8. [9]Marc Brett Magnavox GPS clock driver - 9. [10]Piete Brooks MSF clock driver, + 7. [8]Marc Brett Magnavox GPS clock driver + 8. [9]Piete Brooks MSF clock driver, Trimble PARSE support - 10. [11]Reg Clemens Oncore driver (Current maintainer) - 11. [12]Steve Clift OMEGA clock driver - 12. [13]Casey Crellin vxWorks (Tornado) port and + 9. [10]Nelson B Bolyard update and complete + broadcast and crypto features in sntp + 10. [11]Jean-Francois Boudreault + IPv6 support + 11. [12]Reg Clemens Oncore driver (Current maintainer) + 12. [13]Steve Clift OMEGA clock driver + 13. [14]Casey Crellin vxWorks (Tornado) port and help with target configuration - 13. [14]Sven Dietrich Palisade reference + 14. [15]Sven Dietrich Palisade reference clock driver, NT adj. residuals, integrated Greg's Winnt port. - 14. [15]John A. Dundas III Apple A/UX port - 15. [16]Torsten Duwe Linux + 15. [16]John A. Dundas III Apple A/UX port + 16. [17]Torsten Duwe Linux port - 16. [17]Dennis Ferguson foundation code for + 17. [18]Dennis Ferguson foundation code for NTP Version 2 as specified in RFC-1119 - 17. [18]John Hay IPv6 support and testing - 18. [19]Glenn Hollinger GOES clock driver - 19. [20]Mike Iglesias DEC Alpha port - 20. [21]Jim Jagielski A/UX port - 21. [22]Jeff Johnson massive prototyping + 18. [19]John Hay IPv6 support and testing + 19. [20]Dave Hart General maintenance, Windows + port interpolation rewrite + 20. [21]Claas Hilbrecht NeoClock4X clock driver + 21. [22]Glenn Hollinger GOES clock driver + 22. [23]Mike Iglesias DEC Alpha port + 23. [24]Jim Jagielski A/UX port + 24. [25]Jeff Johnson massive prototyping overhaul - 22. [23]Hans Lambermont or - [24] ntpsweep - 23. [25]Poul-Henning Kamp Oncore driver (Original + 25. [26]Hans Lambermont or + [27] ntpsweep + 26. [28]Poul-Henning Kamp Oncore driver (Original author) - 24. [26]Frank Kardel [27] PARSE + 27. [29]Frank Kardel [30] PARSE driver (>14 reference clocks), STREAMS modules for PARSE, support scripts, syslog cleanup, dynamic interface handling - 25. [28]William L. Jones RS/6000 AIX + 28. [31]William L. Jones RS/6000 AIX modifications, HPUX modifications - 26. [29]Dave Katz RS/6000 AIX port - 27. [30]Craig Leres 4.4BSD port, ppsclock, Magnavox + 29. [32]Dave Katz RS/6000 AIX port + 30. [33]Craig Leres 4.4BSD port, ppsclock, Magnavox GPS clock driver - 28. [31]George Lindholm SunOS 5.1 port - 29. [32]Louis A. Mamakos MD5-based authentication - 30. [33]Lars H. Mathiesen adaptation of foundation + 31. [34]George Lindholm SunOS 5.1 port + 32. [35]Louis A. Mamakos MD5-based authentication + 33. [36]Lars H. Mathiesen adaptation of foundation code for Version 3 as specified in RFC-1305 - 31. [34]Danny Mayer Network I/O, Windows Port, Code + 34. [37]Danny Mayer Network I/O, Windows Port, Code Maintenance - 32. [35]David L. Mills Version 4 foundation: clock + 35. [38]David L. Mills Version 4 foundation: clock discipline, authentication, precision kernel; clock drivers: Spectracom, Austron, Arbiter, Heath, ATOM, ACTS, KSI/Odetics; audio clock drivers: CHU, WWV/H, IRIG - 33. [36]Wolfgang Moeller VMS port - 34. [37]Jeffrey Mogul ntptrace utility - 35. [38]Tom Moore i386 svr4 port - 36. [39]Kamal A Mostafa SCO OpenServer port - 37. [40]Derek Mulcahy and [41]Damon + 36. [39]Wolfgang Moeller VMS port + 37. [40]Jeffrey Mogul ntptrace utility + 38. [41]Tom Moore i386 svr4 port + 39. [42]Kamal A Mostafa SCO OpenServer port + 40. [43]Derek Mulcahy and [44]Damon Hart-Davis ARCRON MSF clock driver - 38. [42]Rainer Pruy + 41. [45]Rob Neal Bancomm refclock and config/parse code + maintenance + 42. [46]Rainer Pruy monitoring/trap scripts, statistics file handling - 39. [43]Dirce Richards Digital UNIX V4.0 port - 40. [44]Wilfredo Sánchez added support for + 43. [47]Dirce Richards Digital UNIX V4.0 port + 44. [48]Wilfredo Sánchez added support for NetInfo - 41. [45]Nick Sayer SunOS streams modules - 42. [46]Jack Sasportas Saved a Lot of + 45. [49]Nick Sayer SunOS streams modules + 46. [50]Jack Sasportas Saved a Lot of space on the stuff in the html/pic/ subdirectory - 43. [47]Ray Schnitzler Unixware1 port - 44. [48]Michael Shields USNO clock driver - 45. [49]Jeff Steinman Datum PTS clock + 47. [51]Ray Schnitzler Unixware1 port + 48. [52]Michael Shields USNO clock driver + 49. [53]Jeff Steinman Datum PTS clock driver - 46. [50]Harlan Stenn GNU automake/autoconfigure + 50. [54]Harlan Stenn GNU automake/autoconfigure makeover, various other bits (see the ChangeLog) - 47. [51]Kenneth Stone HP-UX port - 48. [52]Ajit Thyagarajan IP multicast/anycast + 51. [55]Kenneth Stone HP-UX port + 52. [56]Ajit Thyagarajan IP multicast/anycast support - 49. [53]Tomoaki TSURUOKA TRAK clock + 53. [57]Tomoaki TSURUOKA TRAK clock driver - 50. [54]Paul A Vixie TrueTime GPS driver, generic + 54. [58]Paul A Vixie TrueTime GPS driver, generic TrueTime clock driver - 51. [55]Ulrich Windl corrected and + 55. [59]Ulrich Windl corrected and validated HTML documents according to the HTML DTD _________________________________________________________________ @@ -124,53 +131,57 @@ 3. mailto:%20vbais@mailman1.intel.co 4. mailto:%20kirkwood@striderfm.intel.com 5. mailto:%20michael.barone@lmco.com - 6. mailto:%20Jean-Francois.Boudreault@viagenie.qc.ca - 7. mailto:%20karl@owl.HQ.ileaf.com - 8. mailto:%20greg.brackley@bigfoot.com - 9. mailto:%20Marc.Brett@westgeo.com - 10. mailto:%20Piete.Brooks@cl.cam.ac.uk - 11. mailto:%20reg@dwf.com - 12. mailto:%20clift@ml.csiro.au - 13. mailto:casey@csc.co.za - 14. mailto:%20Sven_Dietrich@trimble.COM - 15. mailto:%20dundas@salt.jpl.nasa.gov - 16. mailto:%20duwe@immd4.informatik.uni-erlangen.de - 17. mailto:%20dennis@mrbill.canet.ca - 18. mailto:%20jhay@icomtek.csir.co.za - 19. mailto:%20glenn@herald.usask.ca - 20. mailto:%20iglesias@uci.edu - 21. mailto:%20jagubox.gsfc.nasa.gov - 22. mailto:%20jbj@chatham.usdesign.com - 23. mailto:Hans.Lambermont@nl.origin-it.com - 24. mailto:H.Lambermont@chello.nl - 25. mailto:%20phk@FreeBSD.ORG - 26. http://www4.informatik.uni-erlangen.de/%7ekardel - 27. mailto:%20kardel(at)ntp(dot)org - 28. mailto:%20jones@hermes.chpc.utexas.edu - 29. mailto:%20dkatz@cisco.com - 30. mailto:%20leres@ee.lbl.gov - 31. mailto:%20lindholm@ucs.ubc.ca - 32. mailto:%20louie@ni.umd.edu - 33. mailto:%20thorinn@diku.dk - 34. mailto:%20mayer@ntp.org - 35. mailto:%20mills@udel.edu - 36. mailto:%20moeller@gwdgv1.dnet.gwdg.de - 37. mailto:%20mogul@pa.dec.com - 38. mailto:%20tmoore@fievel.daytonoh.ncr.com - 39. mailto:%20kamal@whence.com - 40. mailto:%20derek@toybox.demon.co.uk - 41. mailto:%20d@hd.org - 42. mailto:%20Rainer.Pruy@informatik.uni-erlangen.de - 43. mailto:%20dirce@zk3.dec.com - 44. mailto:%20wsanchez@apple.com - 45. mailto:%20mrapple@quack.kfu.com - 46. mailto:%20jack@innovativeinternet.com - 47. mailto:%20schnitz@unipress.com - 48. mailto:%20shields@tembel.org - 49. mailto:%20pebbles.jpl.nasa.gov - 50. mailto:%20harlan@pfcs.com - 51. mailto:%20ken@sdd.hp.com - 52. mailto:%20ajit@ee.udel.edu - 53. mailto:%20tsuruoka@nc.fukuoka-u.ac.jp - 54. mailto:%20vixie@vix.com - 55. mailto:%20Ulrich.Windl@rz.uni-regensburg.de + 6. mailto:%20karl@owl.HQ.ileaf.com + 7. mailto:%20greg.brackley@bigfoot.com + 8. mailto:%20Marc.Brett@westgeo.com + 9. mailto:%20Piete.Brooks@cl.cam.ac.uk + 10. mailto:%20nelson@bolyard.me + 11. mailto:%20Jean-Francois.Boudreault@viagenie.qc.ca + 12. mailto:%20reg@dwf.com + 13. mailto:%20clift@ml.csiro.au + 14. mailto:casey@csc.co.za + 15. mailto:%20Sven_Dietrich@trimble.COM + 16. mailto:%20dundas@salt.jpl.nasa.gov + 17. mailto:%20duwe@immd4.informatik.uni-erlangen.de + 18. mailto:%20dennis@mrbill.canet.ca + 19. mailto:%20jhay@icomtek.csir.co.za + 20. mailto:%20davehart@davehart.com + 21. mailto:%20neoclock4x@linum.com + 22. mailto:%20glenn@herald.usask.ca + 23. mailto:%20iglesias@uci.edu + 24. mailto:%20jagubox.gsfc.nasa.gov + 25. mailto:%20jbj@chatham.usdesign.com + 26. mailto:Hans.Lambermont@nl.origin-it.com + 27. mailto:H.Lambermont@chello.nl + 28. mailto:%20phk@FreeBSD.ORG + 29. http://www4.informatik.uni-erlangen.de/%7ekardel + 30. mailto:%20kardel(at)ntp(dot)org + 31. mailto:%20jones@hermes.chpc.utexas.edu + 32. mailto:%20dkatz@cisco.com + 33. mailto:%20leres@ee.lbl.gov + 34. mailto:%20lindholm@ucs.ubc.ca + 35. mailto:%20louie@ni.umd.edu + 36. mailto:%20thorinn@diku.dk + 37. mailto:%20mayer@ntp.org + 38. mailto:%20mills@udel.edu + 39. mailto:%20moeller@gwdgv1.dnet.gwdg.de + 40. mailto:%20mogul@pa.dec.com + 41. mailto:%20tmoore@fievel.daytonoh.ncr.com + 42. mailto:%20kamal@whence.com + 43. mailto:%20derek@toybox.demon.co.uk + 44. mailto:%20d@hd.org + 45. mailto:%20neal@ntp.org + 46. mailto:%20Rainer.Pruy@informatik.uni-erlangen.de + 47. mailto:%20dirce@zk3.dec.com + 48. mailto:%20wsanchez@apple.com + 49. mailto:%20mrapple@quack.kfu.com + 50. mailto:%20jack@innovativeinternet.com + 51. mailto:%20schnitz@unipress.com + 52. mailto:%20shields@tembel.org + 53. mailto:%20pebbles.jpl.nasa.gov + 54. mailto:%20harlan@pfcs.com + 55. mailto:%20ken@sdd.hp.com + 56. mailto:%20ajit@ee.udel.edu + 57. mailto:%20tsuruoka@nc.fukuoka-u.ac.jp + 58. mailto:%20vixie@vix.com + 59. mailto:%20Ulrich.Windl@rz.uni-regensburg.de diff -urN src/contrib/ntp/ChangeLog src.ntp/contrib/ntp/ChangeLog --- src/contrib/ntp/ChangeLog 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ChangeLog 2010-07-09 04:25:49.000000000 +0200 @@ -1,4 +1,881 @@ --- +(4.2.6p2) 2010/07/09 Released by Harlan Stenn + +* [Bug 1581] size_t printf format string mismatches, IRIG string buffers + undersized. Mostly backported from earlier ntp-dev fixes by Jürgen + Perlinger. + +--- +(4.2.6p2-RC7) 2010/06/19 Released by Harlan Stenn + +* [Bug 1570] serial clock drivers get outdated input from kernel tty + line buffer after startup +* [Bug 1575] use 'snprintf' with LIB_BUFLENGTH in inttoa.c, tvtoa.c and + utvtoa.c +* [Bug 1576] sys/sysctl.h depends on sys/param.h on OpenBSD. + +--- +(4.2.6p2-RC6) 2010/06/12 Released by Harlan Stenn + +* [Bug 715] libisc Linux IPv6 interface iteration drops multicast flags. + +--- +(4.2.6p2-RC5) 2010/06/03 Released by Harlan Stenn + +* [Bug 1561] ntpq, ntpdc "passwd" prompts for MD5 password w/SHA1. +* [Bug 1565] sntp/crypto.c compile fails on MacOS over vsnprintf(). +* Windows port: do not exit in ntp_timestamp_from_counter() without + first logging the reason. +* Support "passwd blah" syntax in ntpq. + +--- +(4.2.6p2-RC4) 2010/05/19 Released by Harlan Stenn + +* [Bug 1555] 4.2.6p2-RC3 sntp illegal C (mixed code and declarations). + +--- +(4.2.6p2-RC3) 2010/05/11 Released by Harlan Stenn + +* [Bug 1325] unreachable code in sntp recv_bcst_data(). +* [Bug 1459] sntp MD5 authentication does not work with ntpd. +* [Bug 1512] ntpsnmpd should connect to net-snmpd via a unix-domain + socket by default. Provide a command-line 'socket name' option. +* [Bug 1538] update refclock_nmea.c's call to getprotobyname(). +* [Bug 1541] Fix wrong keyword for "maxclock". +* [Bug 1552] update and complete broadcast and crypto features in sntp. +* [Bug 1553] sntp/configure.ac OpenSSL support. +* Escape unprintable characters in a refid in ntpq -p billboard. +* Simplify hash client code by providing OpenSSL EVP_*() API when built + without OpenSSL. (from ntp-dev) +* Do not depend on ASCII values for ('A' - '0'), ('a' - '0') in sntp. +* Windows compiling hints/winnt.html update from G. Sunil Tej. + +--- +(4.2.6p2-RC2) 2010/04/27 Released by Harlan Stenn + +* [Bug 1465] Make sure time from TS2100 is not invalid (backport from + ntp-dev). +* [Bug 1528] Fix EDITLINE_LIBS link order for ntpq and ntpdc. +* [Bug 1534] win32/include/isc/net.h conflicts with VC++ 2010 errno.h. +* [Bug 1535] "restrict -4 default" and "restrict -6 default" ignored. +* Remove --with-arlib from br-flock. + +--- +(4.2.6p2-RC1) 2010/04/18 Released by Harlan Stenn + +* [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. +* [Bug 1504] ntpdate tickles ntpd "discard minimum 1" rate limit if + "restrict ... limited" is used. +* [Bug 1518] Windows ntpd should lock to one processor more + conservatively. +* [Bug 1522] Enable range syntax "trustedkey (301 ... 399)". +* Update html/authopt.html controlkey, requestkey, and trustedkey docs. + +--- +(4.2.6p1) 2010/04/09 Released by Harlan Stenn +(4.2.6p1-RC6) 2010/03/31 Released by Harlan Stenn + +* [Bug 1514] Typo in ntp_proto.c: fabs(foo < .4) should be fabs(foo) < .4. +* [Bug 1464] synchronization source wrong for refclocks ARCRON_MSF (27) + and SHM (28). +* Correct Windows port's refclock_open() to return 0 on failure not -1. +* Correct CHU, dumbclock, and WWVB drivers to check for 0 returned from + refclock_open() on failure. +* Correct "SIMUL=4 ./flock-build -1" to prioritize -1/--one. + +--- +(4.2.6p1-RC5) 2010/02/09 Released by Harlan Stenn + +* [Bug 1140] Clean up debug.html, decode.html, and ntpq.html. +* [Bug 1438] Remove dead code from sntp/networking.c. +* [Bug 1477] 1st non-gmake make in clone w/VPATH can't make COPYRIGHT. +* [Bug 1478] linking fails with undefined reference EVP_MD_pkey_type. +* [Bug 1479] Compilation fails because of not finding readline headers. +* [Bug 1480] snprintf() cleanup caused unterminated refclock IDs. +* [Bug 1484] ushort is not defined in QNX6. + +--- +(4.2.6p1-RC4) 2010/02/04 Released by Harlan Stenn + +* [Bug 1455] ntpd does not try /etc/ntp.audio as documented. +* [Bug 1467] Fix bogus rebuild of sntp/sntp.html +* [Bug 1470] "make distdir" in $srcdir builds keyword-gen, libntp.a. +* [Bug 1473] "make distcheck" before build can't make sntp/version.m4. +* [Bug 1474] ntp_keygen needs LCRYPTO after libntp.a. +* Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). +* Fix widely cut-n-pasted bug in refclock shutdown after failed start. +* Remove some dead code checking for emalloc() returning NULL. +* Remove arlib. + +--- +(4.2.6p1-RC3) 2010/01/24 Released by Harlan Stenn + +* Use TZ=UTC instead of TZ= when calling date in scripts/mkver.in . +* [Bug 1448] Some macros not correctly conditionally or absolutely defined + on Windows. +* [Bug 1449] ntpsim.h in ntp_config.c should be used conditionally. +* [Bug 1450] Option to exclude warnings not unconditionally defined on Windows. +* [Bug 1127] Properly check the return of X590_verify() - missed one. +* [Bug 1439] .texi generation must wait until after binary is linked. +* [Bug 1440] Update configure.ac to support kfreebsd. +* [Bug 1445] IRIX does not have -lcap or support linux capabilities. +* [Bug 1451] CID 115: sntp leaks KoD entry when updating existing. +* [Bug 1453] Use $CC in config.cache filename in ./build script. + +--- +(4.2.6p1-RC2) 2009/12/25 Released by Harlan Stenn + +* [Bug 1411] Fix status messages in refclock_oncore.c. +* [Bug 1416] MAXDNAME undefined on Solaris 2.6. +* [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. +* [Bug 1424] Fix check for rtattr (rtnetlink.h). +* [Bug 1425] unpeer by association ID sets up for duplicate free(). +* [Bug 1426] scripts/VersionName needs . on the search path. +* [Bug 1427] quote missing in ./build - shows up on NetBSD. +* [Bug 1428] Use AC_HEADER_RESOLV to fix breaks from resolv.h +* [Bug 1429] ntpd -4 option does not reliably force IPv4 resolution. +* [Bug 1431] System headers must come before ntp headers in ntp_intres.c . +* [Bug 1434] HP-UX 11 ip_mreq undeclared, _HPUX_SOURCE helps some. +* [Bug 1435] sntp: Test for -lresolv using the same tests as in ntp. + +--- +(4.2.6p1-RC1) 2009/12/20 Released by Harlan Stenn + +* [Bug 1409] Put refclock_neoclock4x.c under the NTP COPYRIGHT notice. + This should allow debian and other distros to add this refclock driver + in further distro releases. + Detect R2 hardware releases. +* [Bug 1412] m4/os_cflags.m4 caches results that depend on $CC. +* [Bug 1413] test OpenSSL headers regarding -Wno-strict-prototypes. +* [Bug 1414] Enable "make distcheck" success with BSD make. +* [Bug 1415] Fix Mac OS X link problem. +* [Bug 1418] building ntpd/ntpdc/ntpq statically with ssl fails. +* Build infrastructure updates to enable beta releases of ntp-stable. + +--- +(4.2.6) 2009/12/09 Released by Harlan Stenn +* Include (4.2.4p8) - [Sec 1331] DoS with mode 7 packets - CVE-2009-3563. +* [Bug 508] Fixed leap second handling for Windows. +(4.2.5p250-RC) 2009/11/30 Released by Harlan Stenn +* sntp documentation updates. +* [Bug 761] internal resolver does not seem to honor -4/-6 qualifiers +* [Bug 1386] Deferred DNS doesn't work on NetBSD +* [Bug 1391] avoid invoking autogen twice for .c and .h files. +* [Bug 1397] shmget() refclock_shm failing because of file mode. +* Pass no_needed to ntp_intres as first part of fixing [Bug 975]. +* Add ./configure --enable-force-defer-DNS to help debugging. +(4.2.5p249-RC) 2009/11/28 Released by Harlan Stenn +* [Bug 1400] An empty KOD DB file causes sntp to coredump. +* sntp: documentation cleanup. +* sntp: clean up some error messages. +* sntp: Use the precision to control how many offset digits are shown. +* sntp: Show root dispersion. +* Cleanup from the automake/autoconf upgrades. +(4.2.5p248-RC) 2009/11/26 Released by Harlan Stenn +* Prepare for the generation of sntp.html. +* Documentation changes from Dave Mills. +* [Bug 1387] Storage leak in ntp_intres (minor). +* [Bug 1389] buffer overflow in refclock_oncore.c +* [Bug 1391] .texi usage text from installed, not built binaries. +* [Bug 1392] intres retries duplicate assocations endlessly. +* Correct *-opts.h dependency so default 'get' action isn't used. +(4.2.5p247-RC) 2009/11/20 Released by Harlan Stenn +* [Bug 1142] nodebug builds shed no light on -d, -D option failure. +* [Bug 1179] point out the problem with -i/--jaildir and -u/--user when + they are disabled by configure. +* [Bug 1308] support systems that lack fork(). +* [Bug 1343] sntp doesn't link on Solaris 7, needs -lresolv. +(4.2.5p246-RC) 2009/11/17 Released by Harlan Stenn +* Upgrade to autogen-5.10 +* [Bug 1378] Unnecessary resetting of peers during interface update. +* [Bug 1382] p245 configure --disable-dependency-tracking won't build. +* [Bug 1384] ntpq :config core dumped with a blank password. +(4.2.5p245-RC) 2009/11/14 Released by Harlan Stenn +* Cleanup from Dave Mills. +* [Bug 1343] sntp illegal C does not compile on Solaris 7. +* [Bug 1381] Version .deps generated include file dependencies to allow + known dependency-breaking changes to force .deps to be cleaned, + triggered by changing the contents of deps-ver and/or sntp/deps-ver. +(4.2.5p244-RC) 2009/11/12 Released by Harlan Stenn +* keygen.html updates from Dave Mills. +* [Bug 1003] ntpdc unconfig command doesn't prompt for keyid. +* [Bug 1376] Enable authenticated ntpq and ntpdc using newly-available + digest types. +* ntp-keygen, Autokey OpenSSL build vs. run version mismatch is now a + non-fatal warning. +(4.2.5p243-RC) 2009/11/11 Released by Harlan Stenn +* [Bug 1226] Fix deferred DNS lookups. +* new crypto signature cleanup. +(4.2.5p242-RC) 2009/11/10 Released by Harlan Stenn +* [Bug 1363] CID 92 clarify fallthrough case in clk_trimtsip.c +* [Bug 1366] ioctl(TIOCSCTTY, 0) fails on NetBSD *[0-2].* > 3.99.7. +* [Bug 1368] typos in libntp --without-crypto case +* [Bug 1371] deferred DNS lookup failing with INFO_ERR_AUTH. +* CID 87 dead code in ntpq.c atoascii(). +* Fix authenticated ntpdc, broken in p240. +* Stub out isc/mem.h, shaving 47k from a MIPS ntpd binary. +* Shrink keyword scanner FSM entries from 64 to 32 bits apiece. +* Documention updates from Dave Mills. +* authkeys.c cleanup from Dave Mills. +(4.2.5p241-RC) 2009/11/07 Released by Harlan Stenn +* html/authopt.html update from Dave Mills. +* Remove unused file from sntp/Makefile.am's distribution list. +* new crypto signature cleanup. +(4.2.5p240-RC) 2009/11/05 Released by Harlan Stenn +* [Bug 1364] clock_gettime() not detected, need -lrt on Debian 5.0.3. +* Provide all of OpenSSL's signature methods for ntp.keys (FIPS 140-2). +(4.2.5p239-RC) 2009/10/30 Released by Harlan Stenn +* [Bug 1357] bogus assert from refclock_shm. +* [Bug 1359] Debug message cleanup. +* CID 101: more pointer/array cleanup. +* [Bug 1356] core dump from refclock_nmea when can't open /dev/gpsU. +* [Bug 1358] AIX 4.3 sntp/networking.c IPV6_JOIN_GROUP undeclared. +* CID 101: pointer/array cleanup. +(4.2.5p238-RC) 2009/10/27 Released by Harlan Stenn +* Changes from Dave Mills. +* driver4.html updates from Dave Mills. +* [Bug 1252] PPSAPI cleanup on ntpd/refclock_wwvb.c. +* [Bug 1354] libtool error building after bootstrap with Autoconf 2.64. +* Allow NTP_VPATH_HACK configure test to handle newer gmake versions. +* CIDs 94-99 make it more clearly impossible for sock_hash() to return + a negative number. +* CID 105, 106 ensure ntpdc arrays are not overrun even if callers + misbehave. +* CID 113 use va_end() in refclock_true.c true_debug(). +* Get rid of configure tests for __ss_family and __ss_len when the more + common ss_family and ss_len are present. +(4.2.5p237-RC) 2009/10/26 Released by Harlan Stenn +* [Bug 610] NMEA support for using PPSAPI on a different device. +* [Bug 1238] use only fudge time2 to offset NMEA serial timestamp. +* [Bug 1355] ntp-dev won't compile on OpenBSD 4.6. +(4.2.5p236-RC) 2009/10/22 Released by Harlan Stenn +* Cleanup from Dave Mills. +* [Bug 1343] ntpd/ntp_io.c close_fd() does not compile on Solaris 7. +* [Bug 1353] ntpq "rv 0 settimeofday" always shows UNKNOWN on unix. +* Do not attempt to execute built binaries from ntpd/Makefile when + cross-compiling (keyword-gen and ntpd --saveconfigquit). +* sntp/main.c: Remove duplicate global adr_buf[] (also defined in + networking.c) which Piotr Grudzinski identified breaking his build. +* Correct in6addr_any test in configure.ac to attempt link too. +(4.2.5p235-RC) 2009/10/18 Released by Harlan Stenn +* [Bug 1343] lib/isc build breaks on systems without IPv6 headers. +(4.2.5p234-RC) 2009/10/16 Released by Harlan Stenn +* [Bug 1339] redux, use unmodified lib/isc/win32/strerror.c and + move #define strerror... to a header not used by lib/isc code. +* [Bug 1345] illegal 'grep' option prevents compilation. +* [Bug 1346] keyword scanner broken where char defaults to unsigned. +* [Bug 1347] ntpd/complete.conf missing multicastclient test case. +(4.2.5p233-RC) 2009/10/15 Released by Harlan Stenn +* [Bug 1337] cast setsockopt() v4 address pointer to void *. +* [Bug 1342] ignore|drop one IPv6 address on an interface blocks all + addresses on that interface. +* Documentation cleanup and updates. +(4.2.5p232-RC) 2009/10/14 Released by Harlan Stenn +* [Bug 1302] OpenSSL under Windows needs applink support. +* [Bug 1337] fix incorrect args to setsockopt(fd, IP_MULTICAST_IF,...). +* [Bug 1339] Fix Windows-only ntp_strerror() infinite recursion. +* [Bug 1341] NMEA driver requires working PPSAPI #ifdef HAVE_PPSAPI. +* Construct ntpd keyword scanner finite state machine at compile time + rather than at runtime, shrink entries from 40+ to 8 bytes. +* Update documentation for ntpq --old-rv, saveconfig, saveconfigdir, + ntpd -I -L and -M, and interface/nic rules. (From Dave Hart) +* [Bug 1337] fix incorrect args to setsockopt(fd, IP_MULTICAST_IF,...) +(4.2.5p231-RC) 2009/10/10 Released by Harlan Stenn +* [Bug 1335] Broadcast client degraded by wildcard default change. +(4.2.5p230-RC) 2009/10/09 Released by Harlan Stenn +* Start the 4.2.6 Release Candidate cycle. +* Broadcast and transit phase cleanup from Dave Mills. +(4.2.5p229) 2009/10/07 Released by Harlan Stenn +* [Bug 1334] ntpsnmpd undefined reference to `ntpqOptions'. +* Change ntpsnmpd/Makefile.am include file order to fix FreeBSD build. +(4.2.5p228) 2009/10/06 Released by Harlan Stenn +* Reclaim syntax tree memory after application in ntpd built with + configure --disable-saveconfig. +* [Bug 1135] ntpq uses sizeof(u_long) where sizeof(u_int32) is meant. +* [Bug 1333] ntpd --interface precedence over --novirtualips lost. +(4.2.5p227) 2009/10/05 Released by Harlan Stenn +* [Bug 1135] :config fails with "Server disallowed request" +* [Bug 1330] disallow interface/nic rules when --novirtualips or + --interface are used. +* [Bug 1332] ntpq -c 'rv 0 variablename' returns extra stuff. +* Add test of ntpd --saveconfigquit fidelity using new complete.conf. +* Documentation updates from Dave Hart/Dave Mills. +(4.2.5p226) 2009/10/04 Released by Harlan Stenn +* [Bug 1318] Allow multiple -g options on ntpd command line. +* [Bug 1327] ntpq, ntpdc, ntp-keygen -d & -D should work with configure + --disable-debugging. +* Add ntpd --saveconfigquit option for future build-time + testing of saveconfig fidelity. +* Clockhop and autokey cleanup from Dave Mills. +* Documentation updates from Dave Mills. +(4.2.5p225) 2009/09/30 Released by Harlan Stenn +* authopt documentation changes from Dave Mills/Dave Hart. +* [Bug 1324] support bracketed IPv6 numeric addresses for restrict. +(4.2.5p224) 2009/09/29 Released by Harlan Stenn +* Clockhop and documentation fixes from Dave Mills. +* Remove "tos maxhop" ntp.conf knob. +(4.2.5p223) 2009/09/28 Released by Harlan Stenn +* [Bug 1321] build doesn't work if . isn't on $PATH. +* [Bug 1323] Implement "revoke #" to match documentation, deprecate + "crypto revoke #". +(4.2.5p222) 2009/09/27 Released by Harlan Stenn +* Update libisc code using bind-9.6.1-P1.tar.gz, rearrange our copy to + mirror the upstream layout (lib/isc/...), and merge in NTP-local + modifications to libisc. There is a new procedure to ease future + libisc merges using a separate "upstream" bk repo. That will enable + normal bk pull automerge to handle carrying forward any local changes + and should enable us to take updated libisc snapshots more often. +* Updated build and flock-build scripts. flock-build --one is a way + to perform a flock-build compatible solitary build, handy for a repo + clone's first build on a machine with autoconf, automake, etc. +* Compiling ntp_parser.y using BSD make correctly places ntp_parser.h + in the top-level ntpd directory instead of A.*/ntpd. +* bootstrap script updated to remove potentially stale .deps dirs. +* Remove unneeded Makefile.am files from the lib/isc/include tree. +(4.2.5p221) 2009/09/26 Released by Harlan Stenn +* [Bug 1316] segfault if refclock_nmea can't open file. +* [Bug 1317] Distribute cvo.sh. +(4.2.5p220) 2009/09/25 Released by Harlan Stenn +* Rearrange libisc code to match the upstream layout in BIND. This is + step one of two, changing the layout but keeping our existing libisc. +(4.2.5p219) 2009/09/24 Released by Harlan Stenn +* [Bug 1315] "interface ignore 0.0.0.0" is ignored. +* add implicit "nic ignore all" rule before any rules from ntp.conf, so + "nic listen eth0" alone means the same as "-I eth0". +* add wildcard match class for interface/nic rules. +* fix mistaken carryover of prefixlen from one rule to the next. +* Ensure IPv6 localhost address ::1 is included in libisc's Windows IPv6 + address enumeration, allowing ntpq and ntpdc's hardcoding to 127.0.0.1 + on Windows to end. +(4.2.5p218) 2009/09/21 Released by Harlan Stenn +* [Bug 1314] saveconfig emits -4 and -6 on when not given. +* correct parsing and processing of setvar directive. +* highlight location of ntpq :config syntax errors with ^. +* clarify (former) NO_ARG, SINGLE_ARG, MULTIPLE_ARG renaming to + FOLLBY_TOKEN, FOLLBY_STRING, FOLLBY_STRINGS_TO_EOC. +* parser, saveconfig cleanup to store T_ identifiers in syntax tree. +(4.2.5p217) 2009/09/20 Released by Harlan Stenn +* [Bug 1300] reject remote configuration of dangerous items. +(4.2.5p216) 2009/09/19 Released by Harlan Stenn +* [Bug 1312] ntpq/ntpdc MD5 passwords truncated to 8 chars on Suns. +* CID 10 missing free(up); in refclock_palisade.c error return, again. +* CID 83 added assertion to demonstrate config_nic_rules() does not + call strchr(NULL, '/'). +(4.2.5p215) 2009/09/18 Released by Harlan Stenn +* [Bug 1292] Workaround last VC6 unsigned __int64 kink. +(4.2.5p214) 2009/09/17 Released by Harlan Stenn +* [Bug 1303] remove top-level "autokey" directive. +* use "nic listen 192.168.0.0/16" instead of + "nic listen 192.168.0.0 prefixlen 16". +(4.2.5p213) 2009/09/16 Released by Harlan Stenn +* [Bug 1310] fix Thunderbolt mode in refclock_palisade.c +(4.2.5p212) 2009/09/15 Released by Harlan Stenn +* [Bug 983] add interface [listen | ignore | drop] ... directive. +* [Bug 1243] MD5auth_setkey zero-fills key from first zero octet. +* [Bug 1295] leftover fix, do not crash on exit in free_config_trap() + when "trap 1.2.3.4" is used without any further options. +* [Bug 1311] 4.2.5p211 doesn't build in no-debug mode. +* document interface (alias nic) and unpeer. +* Correct syntax error line & column numbers. +* CID 79: kod_init_kod_db() fails to fclose(db_s) in two error paths. +* CID 80: attempt to quiet Coverity false positive re: leaking "reason" + in main(). +* Documentation updates from Dave Mills. +* CID 81: savedconfig leaked in save_config(). +* Make the code agree with the spec and the book (Dave Mills). +(4.2.5p211) 2009/09/14 Released by Harlan Stenn +* [Bug 663] respect ntpq -c and -p order on command line. +* [Bug 1292] more VC6 unsigned __int64 workarounds. +* [Bug 1296] Added Support for Trimble Acutime Gold. +(4.2.5p210) 2009/09/06 Released by Harlan Stenn +* [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros for Windows + and remove unnecessary reference to applink.c for Windows +* [Bug 1295] trap directive options are not optional. +* [Bug 1297] yylex() must always set yylval before returning. +(4.2.5p209) 2009/09/01 Released by Harlan Stenn +* [Bug 1290] Fix to use GETTIMEOFDAY macro +* [Bug 1289] Update project files for VC6, VS2003, VS2005, VS 2008 +(4.2.5p208) 2009/08/30 Released by Harlan Stenn +* [Bug 1293] make configuration dumper ready for release, specifically: +* rename ntpq dumpcfg command to "saveconfig". +* require authentication for saveconfig. +* "restrict ... nomodify" prevents saveconfig and :config. +* "saveconfig ." shorthand to save to startup configuration file. +* support strftime() substitution in saveconfig arg to timestamp + the output filename, for example "saveconfig %Y%m%d-%H%M%S.conf". +* display saveconfig response message from ntpd in ntpq. +* save output filename in "savedconfig" variable, fetched with ntpq -c + "rv 0 savedconfig". +* document saveconfig in html/ntpq.html. +* add ./configure --disable-saveconfig to build a smaller ntpd. +* log saveconfig failures and successes to syslog. +(4.2.5p207) 2009/08/29 Released by Harlan Stenn +* [Bug 1292] Minor Windows source tweaks for VC6-era SDK headers. +(4.2.5p206) 2009/08/26 Released by Harlan Stenn +* accopt.html typo fixes from Dave Mills. +* [Bug 1283] default to remembering KoD in sntp. +* clean up numerous sntp/kod_management.c bugs. +* use all addresses resolved from each DNS name in sntp. +(4.2.5p205) 2009/08/18 Released by Harlan Stenn +* accopt.html typo fixes from Dave Mills. +* [Bug 1285] Log ntpq :config/config-from-file events. +* [Bug 1286] dumpcfg omits statsdir, mangles filegen. +(4.2.5p204) 2009/08/17 Released by Harlan Stenn +* [Bug 1284] infinite loop in ntpd dumping more than one trustedkey +(4.2.5p203) 2009/08/16 Released by Harlan Stenn +* Add ntpq -c dumpcfg, Google Summer of Code project of Max Kuehn +(4.2.5p202) 2009/08/14 Released by Harlan Stenn +* install the binary and man page for sntp. +(4.2.5p201) 2009/08/13 Released by Harlan Stenn +* sntp: out with the old, in with the new. +(4.2.5p200) 2009/08/12 Released by Harlan Stenn +* [Bug 1281] Build ntpd on Windows without big SDK download, burn, + and install by checking in essentially unchanging messages.mc build + products to avoid requiring mc.exe, which is not included with VC++ + 2008 EE. +(4.2.5p199) 2009/08/09 Released by Harlan Stenn +* [Bug 1279] Cleanup for warnings from Veracode static analysis. +(4.2.5p198) 2009/08/03 Released by Harlan Stenn +* Upgrade to autogen-5.9.9-pre5. +(4.2.5p197) 2009/07/30 Released by Harlan Stenn +* The build script now has . at the end of PATH for config.guess. +(4.2.5p196) 2009/07/29 Released by Harlan Stenn +* [Bug 1272] gsoc_sntp IPv6 build problems under HP-UX 10. +* [Bug 1273] CID 10: Palisade leaks unit struct in error path. +* [Bug 1274] CID 67: ensure resolve_hosts() output count and pointers + are consistent. +* [Bug 1275] CID 45: CID 46: old sntp uses uninitialized guesses[0], + precs[0]. +* [Bug 1276] CID 52: crypto_xmit() may call crypto_alice[23]() + with NULL peer. +(4.2.5p195) 2009/07/27 Released by Harlan Stenn +* cvo.sh: Add support for CentOS, Fedora, Slackware, SuSE, and QNX. +(4.2.5p194) 2009/07/26 Released by Harlan Stenn +* Documentation updates from Dave Mills. +* Use scripts/cvo.sh in the build script to get better subdir names. +(4.2.5p193) 2009/07/25 Released by Harlan Stenn +* [Bug 1261] CID 34: simulate_server() rbuf.msg_flags uninitialized. +* [Bug 1262] CID 35: xpkt.mac uninitialized in simulate_server(). +* [Bug 1263] CID 37: CID 38: CID 40: CID 43: multiple refclocks + uninitialized tm_zone (arc, chronolog, dumbclock, pcf). +* [Bug 1264] CID 64: gsoc_sntp on_wire() frees wrong ptr receiving KoD. +* [Bug 1265] CID 65: CID 66: gsoc_sntp on_wire() leaks x_pkt, r_pkt. +* [Bug 1266] CID 39: datum_pts_start() uninitialized arg.c_ospeed. +* [Bug 1267] CID 44: old sntp handle_saving() writes stack garbage to + file when clearing. +* [Bug 1268] CID 63: resolve_hosts() leaks error message buffer. +* [Bug 1269] CID 74: use assertion to ensure move_fd() does not return + negative descriptors. +* [Bug 1270] CID 70: gsoc_sntp recv_bcst_data mdevadr.ipv6mr_interface + uninitialized. +(4.2.5p192) 2009/07/24 Released by Harlan Stenn +* [Bug 965] CID 42: ss_family uninitialized. +* [Bug 1250] CID 53: kod_init_kod_db() overruns kod_db malloc'd buffer. +* [Bug 1251] CID 68: search_entry() mishandles dst argument. +* [Bug 1252] CID 32: Quiet Coverity warning with assertion. +* [Bug 1253] CID 50: gsoc_sntp/crypto.c auth_init() always returns a + list with one entry. +* [Bug 1254] CID 56: tv_to_str() leaks a struct tm each call. +* [Bug 1255] CID 55: pkt_output() leaks a copy of each packet. +* [Bug 1256] CID 51: Coverity doesn't recognize our assertion macros as + terminal. +* [Bug 1257] CID 57: gsoc_sntp auth_init() fails to fclose(keyfile). +* [Bug 1258] CID 54: gsoc_sntp resolve_hosts() needs simplification. +* [Bug 1259] CID 59: gsoc_sntp recv_bcast_data() fails to free(rdata) + on error paths. +* [Bug 1260] CID 60: gsoc_sntp recvpkt() fails to free(rdata). +* Updated to AutoGen-5.9.9pre2. +(4.2.5p191) 2009/07/21 Released by Harlan Stenn +* Updated to AutoGen-5.9.9pre1. +(4.2.5p190) 2009/07/20 Released by Harlan Stenn +* Updated to AutoGen-5.9.8. +* [Bug 1248] RES_MSSNTP typo in ntp_proto.c. +* [Bug 1246] use a common template for singly-linked lists, convert most + doubly-linked lists to singly-linked. +* Log warning about signd blocking when restrict mssntp used. +(4.2.5p189) 2009/07/16 Released by Harlan Stenn +* Documentation cleanup from Dave Mills. +(4.2.5p188) 2009/07/15 Released by Harlan Stenn +* [Bug 1245] Broken xmt time sent in fast_xmit() of 4.2.5p187. +(4.2.5p187) 2009/07/11 Released by Harlan Stenn +* [Bug 1042] multicast listeners IPv4+6 ignore new interfaces. +* [Bug 1237] Windows serial code treat CR and LF both as line + terminators. +* [Bug 1238] use fudge time2 for serial timecode offset in NMEA driver. +* [Bug 1242] Remove --enable-wintime, symmetric workaround is now + always enabled. +* [Bug 1244] NTP_INSIST(fd != maxactivefd) failure in intres child +* Added restrict keyword "mssntp" for Samba4 DC operation, by Dave Mills. +(4.2.5p186) 2009/07/08 Released by Harlan Stenn +* ntp_proto.c cleanup from Dave Mills. +(4.2.5p185) 2009/07/01 Released by Harlan Stenn +* Documentation updates from Dave Mills. +* [Bug 1234] convert NMEA driver to use common PPSAPI code. +* timepps-Solaris.h pps_handle_t changed from pointer to scalar +* Spectracom refclock added to Windows port of ntpd +* [Bug 1236] Declaration order fixed. +* Bracket private ONCORE debug statements with #if 0 rather than #ifdef + DEBUG +* Delete ONCORE debug statement that is now handled elsewhere. +(4.2.5p184) 2009/06/24 Released by Harlan Stenn +* [Bug 1233] atom refclock fudge time1 sign flipped in 4.2.5p164. +(4.2.5p183) 2009/06/23 Released by Harlan Stenn +* [Bug 1196] setsockopt(SO_EXCLUSIVEADDRUSE) can fail on Windows 2000 + and earlier with WSAINVAL, do not log a complaint in that case. +* [Bug 1210] ONCORE driver terminates ntpd without logging a reason. +* [Bug 1218] Correct comment in refclock_oncore on /etc/ntp.oncore* + configuration file search order. +* Change ONCORE driver to log using msyslog as well as to any + clockstats file. +* [Bug 1231] ntpsnmpd build fails after sockaddr union changes. +(4.2.5p182) 2009/06/18 Released by Harlan Stenn +* Add missing header dependencies to the ntpdc layout verification. +* prefer.html updates from Dave Mills. +* [Bug 1205] Add ntpd --usepcc and --pccfreq options on Windows +* [Bug 1215] unpeer by association ID +* [Bug 1225] Broadcast address miscalculated on Windows 4.2.5p180 +* [Bug 1229] autokey segfaults in cert_install(). +* Use a union for structs sockaddr, sockaddr_storage, sockaddr_in, and + sockaddr_in6 to remove casts and enable type checking. Collapse + some previously separate IPv4/IPv6 paths into a single codepath. +(4.2.5p181) 2009/06/06 Released by Harlan Stenn +* [Bug 1206] Required compiler changes for Windows +* [Bug 1084] PPSAPI for ntpd on Windows with DLL backends +* [Bug 1204] Unix-style refclock device paths on Windows +* [Bug 1205] partial fix, disable RDTSC use by default on Windows +* [Bug 1208] decodenetnum() buffer overrun on [ with no ] +* [Bug 1211] keysdir free()d twice #ifdef DEBUG +* Enable ONCORE, ARCRON refclocks on Windows (untested) +(4.2.5p180) 2009/05/29 Released by Harlan Stenn +* [Bug 1200] Enable IPv6 in Windows port +* Lose FLAG_FIXPOLL, from Dave Mills. +(4.2.5p179) 2009/05/23 Released by Harlan Stenn +* [Bug 1041] xmt -> aorg timestamp cleanup from Dave Mills, + reported by Dave Hart. +* [Bug 1193] Compile error: conflicting types for emalloc. +* [Bug 1196] VC6 winsock2.h does not define SO_EXCLUSIVEADDRUSE. +* Leap/expire cleanup from Dave Mills. +(4.2.5p178) 2009/05/21 Released by Harlan Stenn +* Provide erealloc() and estrdup(), a la emalloc(). +* Improve ntp.conf's parser error messages. +* [Bug 320] "restrict default ignore" does not affect IPv6. +* [Bug 1192] "restrict -6 ..." reports a syntax error. +(4.2.5p177) 2009/05/18 Released by Harlan Stenn +* Include (4.2.4p7) +* [Bug 1174] nmea_shutdown assumes that nmea has a unit assigned +* [Bug 1190] NMEA refclock fudge flag4 1 obscures position in timecode +* Update NMEA refclock documentation in html/drivers/driver20.html +(4.2.5p176) 2009/05/13 Released by Harlan Stenn +* [Bug 1154] mDNS registration should be done later, repeatedly and only + if asked for. (second try for fix) +(4.2.5p175) 2009/05/12 Released by Harlan Stenn +* Include (4.2.4p7-RC7) +* [Bug 1180] ntpd won't start with more than ~1000 interfaces +* [Bug 1182] Documentation typos and missing bits. +* [Bug 1183] COM port support should extend past COM3 +* [Bug 1184] ntpd is deaf when restricted to second IP on the same net +* Clean up configure.ac NTP_CACHEVERSION interface, display cache + version when clearing. Fixes a regression. +(4.2.5p174) 2009/05/09 Released by Harlan Stenn +* Stale leapsecond file fixes from Dave Mills. +(4.2.5p173) 2009/05/08 Released by Harlan Stenn +* Include (4.2.4p7-RC6) +(4.2.5p172) 2009/05/06 Released by Harlan Stenn +* [Bug 1175] Instability in PLL daemon mode. +* [Bug 1176] refclock_parse.c does not compile without PPSAPI. +(4.2.5p171) 2009/05/04 Released by Harlan Stenn +* Autokey documentation cleanup from Dave Mills. +* [Bug 1171] line editing libs found without headers (Solaris 11) +* [Bug 1173] NMEA refclock fails with Solaris PPSAPI +* Fix problem linking msntp on Solaris when sntp subdir is configured + before parent caused by different gethostent library search order. +* Do not clear config.cache when it is empty. +(4.2.5p170) 2009/05/02 Released by Harlan Stenn +* [Bug 1152] adjust PARSE to new refclock_pps logic +* Include (4.2.4p7-RC5) +* loopfilter FLL/PLL crossover cleanup from Dave Mills. +* Documentation updates from Dave Mills. +* ntp-keygen cleanup from Dave Mills. +* crypto API cleanup from Dave Mills. +* Add NTP_CACHEVERSION mechanism to ignore incompatible config.cache +* Enable gcc -Wstrict-overflow for gsoc_sntp as well +(4.2.5p169) 2009/04/30 Released by Harlan Stenn +* [Bug 1171] Note that we never look for -lreadline by default. +* [Bug 1090] Fix bogus leap seconds in refclock_hpgps. +(4.2.5p168) 2009/04/29 Released by Harlan Stenn +* Include (4.2.4p7-RC4) +* [Bug 1169] quiet compiler warnings +* Re-enable gcc -Wstrict-prototypes when not building with OpenSSL +* Enable gcc -Wstrict-overflow +* ntpq/ntpdc emit newline after accepting password on Windows +* Updates from Dave Mills: +* ntp-keygen.c: Updates. +* Fix the error return and syslog function ID in refclock_{param,ppsapi}. +* Make sure syspoll is within the peer's minpoll/maxpoll bounds. +* ntp_crypto.c: Use sign_siglen, not len. sign key filename cleanup. +* Bump NTP_MAXEXTEN from 1024 to 2048, update values for some field lengths. +* m4/ntp_lineeditlibs.m4: fix warnings from newer Autoconf +* [Bug 1166] Remove truncation of position (blanking) code in refclock_nmea.c +(4.2.5p167) 2009/04/26 Released by Harlan Stenn +* Crypto cleanup from Dave Mills. +(4.2.5p166) 2009/04/25 Released by Harlan Stenn +* [Bug 1165] Clean up small memory leaks in the config file parser +* Correct logconfig keyword declaration to MULTIPLE_ARG +* Enable filename and line number leak reporting on Windows when built + DEBUG for all the typical C runtime allocators such as calloc, + malloc, and strdup. Previously only emalloc calls were covered. +* Add DEBUG-only code to free dynamically allocated memory that would + otherwise remain allocated at ntpd exit, to allow less forgivable + leaks to stand out in leaks reported after exit. +* Ensure termination of strings in ports/winnt/libisc/isc_strerror.c + and quiet compiler warnings. +* [Bug 1057] ntpdc unconfig failure +* [Bug 1161] unpeer AKA unconfig command for ntpq :config +* PPS and crypto cleanup in ntp_proto.c from Dave Mills. +(4.2.5p165) 2009/04/23 Released by Harlan Stenn +* WWVB refclock cleanup from Dave Mills. +* Code cleanup: requested_key -> request_key. +* [Bug 833] ignore whitespace at end of remote configuration lines +* [Bug 1033] ntpdc/ntpq crash prompting for keyid on Windows +* [Bug 1028] Support for W32Time authentication via Samba. +* quiet ntp_parser.c malloc redeclaration warning +* Mitigation and PPS/PPSAPI cleanup from Dave Mills. +* Documentation updates from Dave Mills. +* timepps-Solaris.h patches from Dave Hart. +(4.2.5p164) 2009/04/22 Released by Harlan Stenn +* Include (4.2.4p7-RC3) +* PPS/PPSAPI cleanup from Dave Mills. +* Documentation updates from Dave Mills. +* [Bug 1125] C runtime per-thread initialization on Windows +* [Bug 1152] temporarily disable refclock_parse, refclock_true until + maintainers can repair build break from pps_sample() +* [Bug 1153] refclock_nmea should not mix UTC with GPS time +* [Bug 1159] ntpq overlap diagnostic message test buggy +(4.2.5p163) 2009/04/10 Released by Harlan Stenn +(4.2.5p162) 2009/04/09 Released by Harlan Stenn +* Documentation updates from Dave Mills. +* Mitigation and PPS cleanup from Dave Mills. +* Include (4.2.4p7-RC2) +* [Bug 216] New interpolation scheme for Windows eliminates 1ms jitter +* remove a bunch of #ifdef SYS_WINNT from portable code +* 64-bit time_t cleanup for building on newer Windows compilers +* Only set CMOS clock during ntpd exit on Windows if the computer is + shutting down or restarting. +* [Bug 1148] NMEA reference clock improvements +* remove deleted gsoc_sntp/utilities.o from repository so that .o build + products can be cleaned up without corrupting the repository. +(4.2.5p161) 2009/03/31 Released by Harlan Stenn +* Documentation updates from Dave Mills. +(4.2.5p160) 2009/03/30 Released by Harlan Stenn +* [Bug 1141] refclock_report missing braces cause spurious "peer event: + clock clk_unspec" log entries +* Include (4.2.4p7-RC1) +(4.2.5p159) 2009/03/28 Released by Harlan Stenn +* "bias" changes from Dave Mills. +(4.2.5p158) 2009/01/30 Released by Harlan Stenn +* Fix [CID 72], a typo introduced at the latest fix to prettydate.c. +(4.2.5p157) 2009/01/26 Released by Harlan Stenn +* Cleanup/fixes for ntp_proto.c and ntp_crypto.c from Dave Mills. +(4.2.5p156) 2009/01/19 Released by Harlan Stenn +* [Bug 1118] Fixed sign extension for 32 bit time_t in caljulian() and prettydate(). + Fixed some compiler warnings about missing prototypes. + Fixed some other simple compiler warnings. +* [Bug 1119] [CID 52] Avoid a possible null-dereference in ntp_crypto.c. +* [Bug 1120] [CID 51] INSIST that peer is non-null before we dereference it. +* [Bug 1121] [CID 47] double fclose() in ntp-keygen.c. +(4.2.5p155) 2009/01/18 Released by Harlan Stenn +* Documentation updates from Dave Mills. +* CHU frequency updates. +* Design assertion fixes for ntp_crypto.c from Dave Mills. +(4.2.5p154) 2009/01/13 Released by Harlan Stenn +* [Bug 992] support interface event change on Linux from + Miroslav Lichvar. +(4.2.5p153) 2009/01/09 Released by Harlan Stenn +* Renamed gsoc_sntp/:fetch-stubs to gsoc_sntp/fetch-stubs to avoid + file name problems under Windows. + Removed German umlaut from log msg for 4.2.5p142. +(4.2.5p152) 2009/01/08 Released by Harlan Stenn +* Include (4.2.4p6) 2009/01/08 Released by Harlan Stenn +(4.2.5p151) 2008/12/23 Released by Harlan Stenn +* Stats file logging cleanup from Dave Mills. +(4.2.5p150) 2008/12/15 Released by Harlan Stenn +* [Bug 1099] Fixed wrong behaviour in sntp's crypto.c. +* [Bug 1103] Fix 64-bit issues in the new calendar code. +(4.2.5p149) 2008/12/05 Released by Harlan Stenn +* Fixed mismatches in data types and OID definitions in ntpSnmpSubAgent.c +* added a premliminary MIB file to ntpsnmpd (ntpv4-mib.mib) +(4.2.5p148) 2008/12/04 Released by Harlan Stenn +* [Bug 1070] Fix use of ntpq_parsestring() in ntpsnmpd. +(4.2.5p147) 2008/11/27 Released by Harlan Stenn +* Update gsoc_sntp's GCC warning code. +(4.2.5p146) 2008/11/26 Released by Harlan Stenn +* Update Solaris CFLAGS for gsoc_sntp. +(4.2.5p145) 2008/11/20 Released by Harlan Stenn +* Deal with time.h for sntp under linux. +* Provide rpl_malloc() for sntp for systems that need it. +* Handle ss_len and socklen type for sntp. +* Fixes to the sntp configure.ac script. +* Provide INET6_ADDRSTRLEN if it is missing. +* [Bug 1095] overflow in caljulian.c. +(4.2.5p144) 2008/11/19 Released by Harlan Stenn +* Use int32, not int32_t. +* Avoid the sched*() functions under OSF - link problems. +(4.2.5p143) 2008/11/17 Released by Harlan Stenn +* sntp cleanup and fixes. +(4.2.5p142) 2008/11/16 Released by Harlan Stenn +* Imported GSoC SNTP code from Johannes Maximilian Kuehn. +(4.2.5p141) 2008/11/13 Released by Harlan Stenn +* New caltontp.c and calyearstart.c from Juergen Perlinger. +(4.2.5p140) 2008/11/12 Released by Harlan Stenn +* Cleanup lint from the ntp_scanner files. +* [Bug 1011] gmtime() returns NULL on windows where it would not under Unix. +* Updated caljulian.c and prettydate.c from Juergen Perlinger. +(4.2.5p139) 2008/11/11 Released by Harlan Stenn +* Typo fix to driver20.html. +(4.2.5p138) 2008/11/10 Released by Harlan Stenn +* [Bug 474] --disable-ipv6 is broken. +* IPv6 interfaces were being looked for twice. +* SHM driver grabs more samples, add clockstats +* decode.html and driver20.html updates from Dave Mills. +(4.2.5p137) 2008/11/01 Released by Harlan Stenn +* [Bug 1069] #undef netsnmp's PACKAGE_* macros. +* [Bug 1068] Older versions of netsnmp do not have netsnmp_daemonize(). +(4.2.5p136) 2008/10/27 Released by Harlan Stenn +* [Bug 1078] statsdir configuration parsing is broken. +(4.2.5p135) 2008/09/23 Released by Harlan Stenn +* [Bug 1072] clock_update should not allow updates older than sys_epoch. +(4.2.5p134) 2008/09/17 Released by Harlan Stenn +* Clean up build process for ntpsnmpd. +(4.2.5p133) 2008/09/16 Released by Harlan Stenn +* Add options processing to ntpsnmpd. +* [Bug 1062] Check net-snmp headers before deciding to build ntpsnmpd. +* Clean up the libntpq.a build. +* Regenerate ntp_parser.[ch] from ntp_parser.y +(4.2.5p132) 2008/09/15 Released by Harlan Stenn +* [Bug 1067] Multicast DNS service registration must come after the fork + on Solaris. +* [Bug 1066] Error messages should log as errors. +(4.2.5p131) 2008/09/14 Released by Harlan Stenn +* [Bug 1065] Re-enable support for the timingstats file. +(4.2.5p130) 2008/09/13 Released by Harlan Stenn +* [Bug 1064] Implement --with-net-snmp-config=progname +* [Bug 1063] ntpSnmpSubagentObject.h is missing from the distribution. +(4.2.5p129) 2008/09/11 Released by Harlan Stenn +* Quiet some libntpq-related warnings. +(4.2.5p128) 2008/09/08 Released by Harlan Stenn +* Import Heiko Gerstung's GSoC2008 NTP MIB daemon. +(4.2.5p127) 2008/09/01 Released by Harlan Stenn +* Regenerate ntpd/ntp_parser.c +(4.2.5p126) 2008/08/31 Released by Harlan Stenn +* Stop libtool-1.5 from looking for C++ or Fortran. +* [BUG 610] Documentation update for NMEA reference clock driver. +* [Bug 828] Fix IPv4/IPv6 address parsing. +* Changes from Dave Mills: + Documentation updates. + Fix a corner case where a frequency update was reported but not set. + When LEAP_NOTINSYNC->LEAP_NOWARNING, call crypto_update() if we have + crypto_flags. +(4.2.5p125) 2008/08/18 Released by Harlan Stenn +* [Bug 1052] Add linuxPPS support to ONCORE driver. +(4.2.5p124) 2008/08/17 Released by Harlan Stenn +* Documentation updates from Dave Mills. +* Include (4.2.4p5) 2008/08/17 Released by Harlan Stenn +* [Bug 861] leap info was not being transmitted. +* [Bug 1046] refnumtoa.c is using the wrong header file. +* [Bug 1047] enable/disable options processing fix. +* header file cleanup. +* [Bug 1037] buffer in subroutine was 1 byte short. +* configure.ac: cleanup, add option for wintime, and lay the groundwork + for the changes needed for bug 1028. +* Fixes from Dave Mills: 'bias' and 'interleave' work. Separate + phase and frequency discipline (for long poll intervals). Update + TAI function to match current leapsecond processing. +* Documentation updates from Dave Mills. +* [Bug 1037] Use all 16 of the MD5 passwords generated by ntp-keygen. +* Fixed the incorrect edge parameter being passed to time_pps_kcbind in + NMEA refclock driver. +* [Bug 399] NMEA refclock driver does not honor time1 offset if flag3 set. +* [Bug 985] Modifications to NMEA reference clock driver to support Accord + GPS Clock. +* poll time updates from Dave Mills. +* local refclock documentation updates from Dave Mills. +* [Bug 1022] Fix compilation problems with yesterday's commit. +* Updates and cleanup from Dave Mills: + I've now spent eleven months of a sabbatical year - 7 days a week, 6-10 + hours most days - working on NTP. I have carefully reviewed every major + algorithm, examined its original design and evolution from that design. + I've trimmed off dead code and briar patches and did zillions of tests + contrived to expose evil vulnerabilities. The development article is in + rather good shape and should be ready for prime time. + + 1. The protostats statistics files have been very useful in exposing + little twitches and turns when something hiccups, like a broken PPS + signal. Most of what used to be syslog messages are now repackaged as + protostats messages with optional syslog as well. These can also be sent + as traps which might be handy to tiggle a beeper or celltext. These, the + sysstats files and cryptostats files reveal the ambient health of a busy + server, monitor traffic and error counts and spot crypto attacks. + + 2. Close inspection of the clock discipline behavior at long poll + intervals (36 h) showed it not doing as well as it should. I redesigned + the FLL loop to improve nominal accuracy from several tens of + milliseconds to something less than ten milliseconds. + + 3. Autokey (again). The enhanced error checking was becoming a major + pain. I found a way to toss out gobs of ugly fat code and replace the + function with a much simpler and more comprehensive scheme. It resists + bait-and-switch attacks and quickly detect cases when the protocol is + not correctly synchronized. + + 4. The interface code for the kernel PPS signal was not in sync with the + kernel code itself. Some error checks were duplicated and some + ineffective. I found none of the PPS-capable drivers, including the atom + driver, do anything when the prefer peer fails; the kernel PPS signal + remains in control. The atom driver now disables the kernel PPS when the + prefer peer comes bum. This is important when the prefer peer is not a + reference clock but a remote NTP server. + + 5. The flake restrict bit turned out to be really interesting, + especially with symmtric modes and of those especially those using + Autokey. Small changes in the recovery procedures when packets are lost + now avoid almost all scenarios which previously required protocol resets. + + 6. I've always been a little uncomfortable when using the clock filter + with long poll intervals because the samples become less and less + correlated as the sample age exceeds the Allan intercept. Various + schemes have been used over the years to cope with this fact. The latest + one and the one that works the best is to use a modified sort metric + where the delay is used when the age of the sample is less than the + intercept and the sum of delay and dispersion above that. The net result + is that, at small poll intervals the algorithm operates as a minimum + filter, while at larger poll intervals it morphs to FIFO. Left + unmodified, a sample could be used when twelve days old. This along with + the FLL modifications has made a dramatic improvement at large poll + intervals. + +- [Backward Incompatible] The 'state' variable is no longer reported or + available via ntpq output. The following system status bit names + have been changed: + - sync_alarm -> leap_alarm + - sync_atomic -> sync_pps + - sync_lf_clock -> sync_lf_radio + - sync_hf_clock -> sync_hf_radio + - sync_uhf_clock -> sync_uhf_radio + - sync_local_proto -> sync_local + - sync_udp/time -> sync_other + Other names have been changed as well. See the change history for + libntp/statestr.c for more details. + Other backward-incompatible changes in ntpq include: + - assID -> associd + - rootdispersion -> rootdisp + - pkt_head -> pkt_neader + See the change history for other details. + +* Updates and cleanup from Dave Mills. +* [Bug 995] Remove spurious ; from ntp-keygen.c. +* More cleanup and changes from Dave Mills. +* [Bug 980] Direct help to stdout. +--- (4.2.4p8) 2009/12/08 Released by Harlan Stenn * [Sec 1331] DoS with mode 7 packets - CVE-2009-3563. @@ -93,6 +970,217 @@ Emit a warning if that keyword is used for configuration. * [Bug 959] Refclock on Windows not properly releasing recvbuffs. * [Bug 993] Fix memory leak when fetching system messages. +* much cleanup, fixes, and changes from Dave Mills. +* ntp_control.c: LEAPTAB is a filestamp, not an unsigned. From Dave Mills. +* ntp_config.c: ntp_minpoll fixes from Dave Mills. +* ntp-keygen updates from Dave Mills. +* refresh epoch, throttle, and leap cleanup from Dave Mills. +* Documentation cleanup from Dave Mills. +* [Bug 918] Only use a native md5.h if MD5Init() is available. +* [Bug 979] Provide ntptimeval if it is not otherwise present. +* [Bug 634] Re-instantiate syslog() and logfiles after the daemon fork. +* [Bug 952] Use md5 code with a friendlier license. +* [Bug 977] Fix mismatching #ifdefs for builds without IPv6. +* [Bug 830] Fix the checking order of the interface options. +* Clean up the logfile/syslog setup. +* [Bug 970] Lose obsolete -g flag to ntp-keygen. +* The -e flag to ntp-keygen can write GQ keys now, too. +* ntp_proto.c: sys_survivors and hpoll cleanup from Dave Mills. +* ntp_loopfilter.c: sys_poll cleanup from Dave Mills. +* refclock_wwv.c: maximum-likelihood digit and DSYNC fixes from Dave Mills. +* [Bug 967] preemptable associations are lost forever on a step. +* ntp_config.c: [CID 48] missing "else" clause. +* [Bug 833] ntpq config keyword is quote-mark unfriendly. +* Rename the ntpq "config" keyword to ":config". +* Dave Mills shifted some orphan processing. +* Fix typos in the [Bug 963] patch. +* bootstrap: squawk if genver fails. Use -f with cp in case Dave does a chown. +* Remove obsolete simulator command-line options. +* ntp_request.c: [CID 36] zero sin_zero. +* [Bug 963] get_systime() is too noisy. +* [Bug 960] spurious syslog:crypto_setup:spurious crypto command +* [Bug 964] Change *-*-linux* to *-*-*linux* to allow for uclinux. +* Changes from Dave Mills: + - ntp_util.c: cleanup. + - ntp_timer.c: watch the non-burst packet rate. + - ntp_request.c: cleanup. + - ntp_restrict.c: RES_LIMITED cleanup. + - ntp_proto.c: RES_LIMITED, rate bucktes, counters, overall cleanup. + - ntp_peer.c: disallow peer_unconfig(). + - ntp_monitor.c: RES_LIMITED cleanup. + - ntp_loopfilter.c: poll interval cleanup. + - ntp_crypto.c: volley -> retry. Cleanup TAI leap message. + - ntp_config: average and minimum are ^2 values. + - ntpdc: unknownversion is really "declined", not "bad version". + - Packet retry cleanup. +* [Bug 961] refclock_tpro.c:tpro_poll() calls refclock_receive() twice. +* [Bug 957] Windows only: Let command line parameters from the Windows SCM GUI + override the standard parameters from the ImagePath registry key. +* Added HAVE_INT32_T to the Windows config.h to avoid duplicate definitions. +* Work around a VPATH difference in FreeBSD's 'make' command. +* Update bugreport URL. +* Update -I documentation. +* [Bug 713] Fix bug reporting information. +* A bug in the application of the negative-sawtooth for 12 channel receivers. +* The removal of unneeded startup code used for the original LinuxPPS, it now + conforms to the PPSAPI and does not need special code. +* ntp-keygen.c: Coverity fixes [CID 33,47]. +* Volley cleanup from Dave Mills. +* Fuzz cleanup from Dave Mills. +* [Bug 861] Leap second cleanups from Dave Mills. +* ntpsim.c: add missing protypes and fix [CID 34], a nit. +* Upgraded bison at UDel. +* Update br-flock and flock-build machine lists. +* [Bug 752] QoS: add parse/config handling code. +* Fix the #include order in tickadj.c for picky machines. +* [Bug 752] QoS: On some systems, netinet/ip.h needs netinet/ip_systm.h. +* [Bug 752] Update the QoS tagging (code only - configuration to follow). +* Orphan mode and other protocol cleanup from Dave Mills. +* Documentation cleanup from Dave Mills. +* [Bug 940] ntp-keygen uses -v. Disallow it as a shortcut for --version. +* more cleanup to ntp_lineeditlibs.m4. +* Documentation updates from Dave Mills. +* -ledit cleanup for ntpdc and ntpq. +* Association and other cleanup from Dave Mills. +* NTP_UNREACH changes from Dave Mills. +* Fix the readline history test. +* [Bug 931] Require -lreadline to be asked for explicitly. +* [Bug 764] When looking for -lreadline support, also try using -lncurses. +* [Bug 909] Fix int32_t errors for ntohl(). +* [Bug 376/214] Enhancements to support multiple if names and IP addresses. +* [Bug 929] int32_t is undefined on Windows. Casting wrong. +* [Bug 928] readlink missing braces. +* [Bug 788] Update macros to support VS 2005. +* ntpd/ntp_timer.c: add missing sys_tai parameter for debug printf +* [Bug 917] config parse leaves files open +* [Bug 912] detect conflicting enable/disable configuration on interfaces + sharing an IP address +* [Bug 771] compare scopeid if available for IPv6 addresses +* Lose obsolete crypto subcommands (Dave Mills). +* WWV is an HF source, not an LF source (Dave Mills). +* [Bug 899] Only show -i/--jaildir -u/--user options if we HAVE_DROPROOT. +* [Bug 916] 'cryptosw' is undefined if built without OpenSSL. +* [Bug 891] 'restrict' config file keyword does not work (partial fix). +* [Bug 890] the crypto command seems to be required now. +* [Bug 915] ntpd cores during processing of x509 certificates. +* Crypto lint cleanup from Dave Mills. +* [Bug 897] Check RAND_status() - we may not need a .rnd file. +* Crypto cleanup from Dave Mills. +* [Bug 911] Fix error message in cmd_args.c. +* [Bug 895] Log assertion failures via syslog(), not stderr. +* Documentation updates from Dave Mills. +* Crypto cleanup from Dave Mills. +* [Bug 905] ntp_crypto.c fails to compile without -DDEBUG. +* Avoid double peer stats logging. +* ntp-keygen cleanup from Dave Mills. +* libopts needs to be built after ElectricFence. +* [Bug 894] Initialize keysdir before calling crypto_setup(). +* Calysto cleanup for ntpq. +* ntp-keygen -i takes an arg. +* Cleanup and fixes from Dave Mills. +* [Bug 887] Fix error in ntp_types.h (for sizeof int != 4). +* Bug 880 bug fixes for Windows build +* Improve Calysto support. +* The "revoke" parameter is a crypto command. +* The driftfile wander threshold is a real number. +* [Bug 850] Fix the wander threshold parameter on the driftfile command. +* ntp_io.c: Dead code cleanup - Coverity View 19. +* Leap file related cleanup from Dave Mills. +* ntp_peer.c: Set peer->srcadr before (not after) calling set_peerdstadr(). +* Initialize offset in leap_file() - Coverity View 17. +* Use the correct stratum on KISS codes. +* Fuzz bits cleanup. +* Show more digits in some debug printf's. +* Use drift_file_sw internally to control writing the drift file. +* Implement the wander_threshold option for the driftfile config keyword. +* reformat ntp_control.c; do not use c++ // comments. +* [Bug 629] Undo bug #629 fixes as they cause more problems than were being + solved +* Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, + driftfile write cleanup, packet buffer length checks, documentation updates. +* More assertion checks and malloc()->emalloc(), courtesy of Calysto. +* [Bug 864] Place ntpd service in maintenance mode if using SMF on Solaris +* [Bug 862] includefile nesting; preserve phonelist on reconfig. +* [Bug 604] ntpd regularly dies on linux/alpha. +* more leap second infrastructure fixes from Dave Mills. +* [Bug 858] recent leapfile changes broke non-OpenSSL builds. +* Use emalloc() instead of malloc() in refclock_datum.c (Calysto). +* Start using 'design by contract' assertions. +* [Bug 767] Fast sync to refclocks wanted. +* Allow null driftfile. +* Use YYERROR_VERBOSE for the new parser, and fix related BUILT_SOURCES. +* [Bug 629] changes to ensure broadcast works including on wildcard addresses +* [Bug 853] get_node() must return a pointer to maximally-aligned memory. +* Initial leap file fixes from Dave Mills. +* [Bug 858] Recent leapfile changes broke without OPENSSL. +* Use a char for DIR_SEP, not a string. +* [Bug 850] driftfile parsing changes. +* driftfile maintenance changes from Dave Mills. Use clock_phi instead of + stats_write_tolerance. +* [Bug 828] refid string not being parsed correctly. +* [Bug 846] Correct includefile parsing. +* [Bug 827] New parsing code does not handle "fudge" correctly. +* Enable debugging capability in the config parser. +* [Bug 839] Crypto password not read from ntp.conf. +* Have autogen produce writable output files. +* [Bug 825] Correct logconfig -/+ keyword processing. +* [Bug 828] Correct parsing of " delimited strings. +* Cleanup FILE * usage after fclose() in ntp_filegen.c. +* [Bug 843] Windows Completion port code was incorrectly merged from -stable. +* [Bug 840] do fudge configuration AFTER peers (thus refclocks) have been + configured. +* [Bug 824] Added new parser modules to the Windows project file. +* [Bug 832] Add libisc/log.c headers to the distribution. +* [Bug 808] Only write the drift file if we are in state 4. +* Initial import of libisc/log.c and friends. +* [Bug 826] Fix redefinition of PI. +* [Bug 825] ntp_scanner.c needs to #include . +* [Bug 824] New parser code has some build problems with the SIM code. +* [Bug 817] Use longnames for setting ntp variables on the command-line; + Allowing '-v' with and without an arg to disambiguate usage is error-prone. +* [Bug 822] set progname once, early. +* [Bug 819] remove erroneous #if 0 in Windows completion port code. +* The new config code missed an #ifdef for building without refclocks. +* Distribute some files needed by the new config parsing code. +* [Bug 819] Timeout for WaitForMultipleObjects was 500ms instead of INFINITE +* Use autogen 5.9.1. +* Fix clktest command-line arg processing.' +* Audio documentation updates from Dave Mills. +* New config file parsing code, from Sachin Kamboj. +* fuzz bit cleanup from Dave Mills. +* replay cleanup from Dave Mills. +* [Bug 542] Tolerate missing directory separator at EO statsdir. +* [Bug 812] ntpd should drop supplementary groups. +* [Bug 815] Fix warning compiling 4.2.5p22 under Windows with VC6. +* [Bug 740] Fix kernel/daemon startup drift anomaly. +* refclock_wwv.c fixes from Dave Mills. +* [Bug 810] Fix ntp-keygen documentation. +* [Bug 787] Bug fixes for 64-bit time_t on Windows. +* [Bug 796] Clean up duplicate #defines in ntp_control.c. +* [Bug 569] Use the correct precision for the Leitch CSD-5300. +* [Bug 795] Moved declaration of variable to top of function. +* [Bug 798] ntpq [p typo crashes ntpq/ntpdc. +* [Bug 786] Fix refclock_bancomm.c on Solaris. +* [Bug 774] parsesolaris.c does not compile under the new Solaris. +* [Bug 782] Remove P() macros from Windows files. +* [Bug 778] ntpd fails to lock with drift=+500 when started with drift=-500. +* [Bug 592] Trimble Thunderbolt GPS support. +* IRIG, CHU, WWV, WWVB refclock improvements from Dave Mills. +* [Bug 757] Lose ULONG_CONST(). +* [Bug 756] Require ANSI C (function prototypes). +* codec (audio) and ICOM changes from Dave Mills. + +--- + +* [Bug 450] Windows only: Under original Windows NT we must not discard the + wildcard socket to workaround a bug in NT's getsockname(). +* [Bug 1038] Built-in getpass() function also prompts for password if + not built with DEBUG. +* [Bug 841] Obsolete the "dynamic" keyword and make deferred binding + to local interfaces the default. + Emit a warning if that keyword is used for configuration. +* [Bug 959] Refclock on Windows not properly releasing recvbuffs. +* [Bug 993] Fix memory leak when fetching system messages. * [Bug 987] Wake up the resolver thread/process when a new interface has become available. * Correctly apply negative-sawtooth for oncore 12 channel receiver. @@ -120,7 +1208,6 @@ as under other OSs. * ntpdate.c: Fixed some typos and indents (tabs/spaces). ---- (4.2.4p4) Released by Harlan Stenn * [Bug 902] Fix problems with the -6 flag. @@ -129,33 +1216,43 @@ * [Bug 881] Corrected display of pll offset on 64bit systems. * [Bug 886] Corrected sign handling on 64bit in ntpdc loopinfo command. * [Bug 889] avoid malloc() interrupted by SIGIO risk -* ntpd/refclock_parse.c: cleanup shutdown while the file descriptor is still open. +* ntpd/refclock_parse.c: cleanup shutdown while the file descriptor is still + open. * [Bug 885] use emalloc() to get a message at the end of the memory - unsigned types cannot be less than 0 - default_ai_family is a short - lose trailing , from enum list - clarify ntp_restrict.c for easier automated analysis -* [Bug 884] don't access recv buffers after having them passed to the free list. -* [Bug 882] allow loopback interfaces to share addresses with other interfaces. + unsigned types cannot be less than 0 + default_ai_family is a short + lose trailing , from enum list + clarify ntp_restrict.c for easier automated analysis +* [Bug 884] don't access recv buffers after having them passed to the free + list. +* [Bug 882] allow loopback interfaces to share addresses with other + interfaces. --- (4.2.4p3) Released by Harlan Stenn * [Bug 863] unable to stop ntpd on Windows as the handle reference for events - changed + changed --- (4.2.4p2) Released by Harlan Stenn * [Bug 854] Broadcast address was not correctly set for interface addresses * [Bug 829] reduce syslog noise, while there fix Enabled/Disable logging - to reflect the actual configuration. + to reflect the actual configuration. * [Bug 795] Moved declaration of variable to top of function. * [Bug 789] Fix multicast client crypto authentication and make sure arriving - multicast packets do not disturb the autokey dance. + multicast packets do not disturb the autokey dance. * [Bug 785] improve handling of multicast interfaces - (multicast routers still need to run a multicast routing - software/daemon) + (multicast routers still need to run a multicast routing software/daemon) +* ntpd/refclock_parse.c: cleanup shutdown while the file descriptor is still + open. +* [Bug 885] use emalloc() to get a message at the end of the memory + unsigned types cannot be less than 0 + default_ai_family is a short + lose trailing , from enum list +* [Bug 884] don't access recv buffers after having them passed to the free list. +* [Bug 882] allow loopback interfaces to share addresses with other interfaces. * [Bug 527] Don't write from source address length to wrong location * Upgraded autogen and libopts. * [Bug 811] ntpd should not read a .ntprc file. @@ -249,52 +1346,52 @@ --- (4.2.2p4) Released by Harlan Stenn - * [Bug 710] compat getnameinfo() has off-by-one error - * [Bug 690] Buffer overflow in Windows when doing DNS Lookups +* [Bug 710] compat getnameinfo() has off-by-one error +* [Bug 690] Buffer overflow in Windows when doing DNS Lookups --- (4.2.2p3) Released by Harlan Stenn - * Make the ChangeLog file cleaner and easier to read - * [Bug 601] ntpq's decodeint uses an extra level of indirection - * [Bug 657] Different OSes need different sized args for IP_MULTICAST_LOOP - * release engineering/build changes - * Documentation fixes - * Get sntp working under AIX-5 +* Make the ChangeLog file cleaner and easier to read +* [Bug 601] ntpq's decodeint uses an extra level of indirection +* [Bug 657] Different OSes need different sized args for IP_MULTICAST_LOOP +* release engineering/build changes +* Documentation fixes +* Get sntp working under AIX-5 --- (4.2.2p2) (broken) - * Get sntp working under AIX-5 +* Get sntp working under AIX-5 --- (4.2.2p1) - * [Bug 661] Use environment variable to specify the base path to openssl. - * Resolve an ambiguity in the copyright notice - * Added some new documentation files - * URL cleanup in the documentation - * [Bug 657]: IP_MULTICAST_LOOP uses a u_char value/size - * quiet gcc4 complaints - * more Coverity fixes - * [Bug 614] manage file descriptors better - * [Bug 632] update kernel PPS offsets when PPS offset is re-configured - * [Bug 637] Ignore UP in*addr_any interfaces - * [Bug 633] Avoid writing files in srcdir - * release engineering/build changes +* [Bug 661] Use environment variable to specify the base path to openssl. +* Resolve an ambiguity in the copyright notice +* Added some new documentation files +* URL cleanup in the documentation +* [Bug 657]: IP_MULTICAST_LOOP uses a u_char value/size +* quiet gcc4 complaints +* more Coverity fixes +* [Bug 614] manage file descriptors better +* [Bug 632] update kernel PPS offsets when PPS offset is re-configured +* [Bug 637] Ignore UP in*addr_any interfaces +* [Bug 633] Avoid writing files in srcdir +* release engineering/build changes --- (4.2.2) - * SNTP - * Many bugfixes - * Implements the current "goal state" of NTPv4 - * Autokey improvements - * Much better IPv6 support - * [Bug 360] ntpd loses handles with LAN connection disabled. - * [Bug 239] Fix intermittent autokey failure with multicast clients. - * Rewrite of the multicast code - * New version numbering scheme +* SNTP +* Many bugfixes +* Implements the current "goal state" of NTPv4 +* Autokey improvements +* Much better IPv6 support +* [Bug 360] ntpd loses handles with LAN connection disabled. +* [Bug 239] Fix intermittent autokey failure with multicast clients. +* Rewrite of the multicast code +* New version numbering scheme --- (4.2.0) diff -urN src/contrib/ntp/CommitLog src.ntp/contrib/ntp/CommitLog --- src/contrib/ntp/CommitLog 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/CommitLog 2010-07-09 04:27:19.000000000 +0200 @@ -1,5999 +1,49657 @@ -ChangeSet@1.1612, 2009-12-08 08:30:54-05:00, stenn@whimsy.udel.edu +1 -0 - ChangeLog: - typo +ChangeSet@1.2194, 2010-07-09 02:25:58+00:00, stenn@deacon.udel.edu +27 -0 + NTP_4_2_6P2 + TAG: NTP_4_2_6P2 - ChangeLog@1.95, 2009-12-08 08:30:44-05:00, stenn@whimsy.udel.edu +0 -1 - typo + ChangeLog@1.646, 2010-07-09 02:25:55+00:00, stenn@deacon.udel.edu +1 -0 + NTP_4_2_6P2 -ChangeSet@1.1611, 2009-12-08 08:23:12-05:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P8 - TAG: NTP_4_2_4P8 + ntpd/ntpd-opts.c@1.263, 2010-07-09 02:25:55+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2 - ChangeLog@1.94, 2009-12-08 08:23:01-05:00, stenn@whimsy.udel.edu +1 -0 - NTP_4_2_4P8 + ntpd/ntpd-opts.h@1.263, 2010-07-09 02:25:55+00:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2 - ntpd/ntpd-opts.c@1.86, 2009-12-08 08:23:02-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + ntpd/ntpd-opts.texi@1.261, 2010-07-09 02:25:55+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2 - ntpd/ntpd-opts.h@1.86, 2009-12-08 08:23:02-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P8 + ntpd/ntpd.1@1.261, 2010-07-09 02:25:55+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2 - ntpd/ntpd-opts.texi@1.85, 2009-12-08 08:23:03-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P8 + ntpdc/ntpdc-opts.c@1.259, 2010-07-09 02:25:55+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2 - ntpd/ntpd.1@1.84, 2009-12-08 08:23:03-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + ntpdc/ntpdc-opts.h@1.259, 2010-07-09 02:25:55+00:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2 - ntpd/ntpdsim-opts.c@1.86, 2009-12-08 08:23:03-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + ntpdc/ntpdc-opts.texi@1.258, 2010-07-09 02:25:55+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2 - ntpd/ntpdsim-opts.h@1.86, 2009-12-08 08:23:04-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P8 + ntpdc/ntpdc.1@1.258, 2010-07-09 02:25:56+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2 - ntpd/ntpdsim-opts.texi@1.84, 2009-12-08 08:23:05-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P8 + ntpq/ntpq-opts.c@1.260, 2010-07-09 02:25:56+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2 - ntpd/ntpdsim.1@1.84, 2009-12-08 08:23:05-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + ntpq/ntpq-opts.h@1.260, 2010-07-09 02:25:56+00:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2 - ntpdc/ntpdc-opts.c@1.86, 2009-12-08 08:23:05-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + ntpq/ntpq-opts.texi@1.259, 2010-07-09 02:25:56+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2 - ntpdc/ntpdc-opts.h@1.86, 2009-12-08 08:23:05-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P8 + ntpq/ntpq.1@1.259, 2010-07-09 02:25:56+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2 - ntpdc/ntpdc-opts.texi@1.84, 2009-12-08 08:23:06-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P8 + ntpsnmpd/ntpsnmpd-opts.c@1.139, 2010-07-09 02:25:56+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2 - ntpdc/ntpdc.1@1.84, 2009-12-08 08:23:06-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + ntpsnmpd/ntpsnmpd-opts.h@1.139, 2010-07-09 02:25:56+00:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2 - ntpq/ntpq-opts.c@1.88, 2009-12-08 08:23:06-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + ntpsnmpd/ntpsnmpd-opts.texi@1.139, 2010-07-09 02:25:56+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2 - ntpq/ntpq-opts.h@1.88, 2009-12-08 08:23:06-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P8 + ntpsnmpd/ntpsnmpd.1@1.138, 2010-07-09 02:25:56+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2 - ntpq/ntpq-opts.texi@1.85, 2009-12-08 08:23:07-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P8 + packageinfo.sh@1.277, 2010-07-09 02:25:56+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2 - ntpq/ntpq.1@1.84, 2009-12-08 08:23:07-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + sntp/sntp-opts.c@1.132, 2010-07-09 02:25:56+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2 - packageinfo.sh@1.118, 2009-12-08 08:23:07-05:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P8 + sntp/sntp-opts.h@1.132, 2010-07-09 02:25:56+00:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2 - sntp/sntp-opts.c@1.84, 2009-12-08 08:23:07-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + sntp/sntp-opts.texi@1.132, 2010-07-09 02:25:57+00:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P2 - sntp/sntp-opts.h@1.84, 2009-12-08 08:23:07-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P8 + sntp/sntp.1@1.132, 2010-07-09 02:25:57+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2 - sntp/sntp-opts.texi@1.81, 2009-12-08 08:23:08-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P8 + sntp/sntp.html@1.22, 2010-07-09 02:25:57+00:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P2 - sntp/sntp.1@1.84, 2009-12-08 08:23:08-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + util/ntp-keygen-opts.c@1.262, 2010-07-09 02:25:57+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2 - util/ntp-keygen-opts.c@1.85, 2009-12-08 08:23:08-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + util/ntp-keygen-opts.h@1.262, 2010-07-09 02:25:57+00:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2 - util/ntp-keygen-opts.h@1.85, 2009-12-08 08:23:08-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P8 + util/ntp-keygen-opts.texi@1.261, 2010-07-09 02:25:57+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2 - util/ntp-keygen-opts.texi@1.83, 2009-12-08 08:23:09-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P8 + util/ntp-keygen.1@1.261, 2010-07-09 02:25:57+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2 - util/ntp-keygen.1@1.83, 2009-12-08 08:23:09-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 +ChangeSet@1.2193, 2010-07-08 21:55:47-04:00, stenn@deacon.udel.edu +2 -0 + release 4.2.6p2 -ChangeSet@1.1610, 2009-12-08 07:45:28-05:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P9_RC1 - TAG: NTP_4_2_4P9_RC1 + NEWS@1.107, 2010-07-08 21:53:59-04:00, stenn@deacon.udel.edu +39 -0 + NEWS file for 4.2.6p2 - ChangeLog@1.93, 2009-12-08 07:45:19-05:00, stenn@whimsy.udel.edu +1 -0 - NTP_4_2_4P9_RC1 + packageinfo.sh@1.276, 2010-07-08 21:55:33-04:00, stenn@deacon.udel.edu +1 -1 + release 4.2.6p2 - ntpd/ntpd-opts.c@1.85, 2009-12-08 07:45:19-05:00, stenn@whimsy.udel.edu +5 -5 - NTP_4_2_4P9_RC1 +ChangeSet@1.2192, 2010-07-08 21:49:08-04:00, stenn@deacon.udel.edu +1 -0 + Use the new mirror server names for the trigger mirror update script - ntpd/ntpd-opts.h@1.85, 2009-12-08 07:45:19-05:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P9_RC1 + BitKeeper/triggers/2mirrors@1.6, 2010-07-08 21:49:01-04:00, stenn@deacon.udel.edu +2 -2 + Use the new mirror server names for the trigger mirror update script - ntpd/ntpd-opts.texi@1.84, 2009-12-08 07:45:20-05:00, stenn@whimsy.udel.edu +13 -6 - NTP_4_2_4P9_RC1 +ChangeSet@1.2191, 2010-07-02 07:43:21+01:00, davehart@shiny.ad.hartbrothers.com +10 -0 + [Bug 1581] size_t printf format string mismatches, IRIG string buffers + undersized. Mostly backported from earlier ntp-dev fixes by Jürgen + Perlinger, The exceptions are ntp_intres.c and refclock_irig.c. - ntpd/ntpd.1@1.83, 2009-12-08 07:45:20-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P9_RC1 + ChangeLog@1.645, 2010-07-02 07:43:19+01:00, davehart@shiny.ad.hartbrothers.com +6 -0 + [Bug 1581] size_t printf format string mismatches, IRIG string buffers + undersized. Mostly backported from earlier ntp-dev fixes by Jürgen + Perlinger, The exceptions are ntp_intres.c and refclock_irig.c. - ntpd/ntpdsim-opts.c@1.85, 2009-12-08 07:45:20-05:00, stenn@whimsy.udel.edu +5 -5 - NTP_4_2_4P9_RC1 + libntp/ssl_init.c@1.6, 2010-07-02 07:43:19+01:00, davehart@shiny.ad.hartbrothers.com +5 -4 + [Bug 1581] size_t printf format string mismatches (backported from ntp-dev). - ntpd/ntpdsim-opts.h@1.85, 2009-12-08 07:45:20-05:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P9_RC1 + ntpd/ntp_config.c@1.245, 2010-07-02 07:43:19+01:00, davehart@shiny.ad.hartbrothers.com +4 -4 + [Bug 1581] size_t printf format string mismatches (backported from ntp-dev). - ntpd/ntpdsim-opts.texi@1.83, 2009-12-08 07:45:21-05:00, stenn@whimsy.udel.edu +61 -2 - NTP_4_2_4P9_RC1 + ntpd/ntp_intres.c@1.80, 2010-07-02 07:43:19+01:00, davehart@shiny.ad.hartbrothers.com +6 -4 + [Bug 1581] size_t printf format string mismatches. - ntpd/ntpdsim.1@1.83, 2009-12-08 07:45:21-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P9_RC1 + ntpd/ntp_request.c@1.84, 2010-07-02 07:43:19+01:00, davehart@shiny.ad.hartbrothers.com +8 -7 + [Bug 1581] size_t printf format string mismatches (backported from ntp-dev). - ntpdc/ntpdc-opts.c@1.85, 2009-12-08 07:45:21-05:00, stenn@whimsy.udel.edu +5 -5 - NTP_4_2_4P9_RC1 + ntpd/ntp_scanner.c@1.32, 2010-07-02 07:43:19+01:00, davehart@shiny.ad.hartbrothers.com +2 -2 + [Bug 1581] size_t printf format string mismatches (backported from ntp-dev). - ntpdc/ntpdc-opts.h@1.85, 2009-12-08 07:45:21-05:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P9_RC1 + ntpd/refclock_acts.c@1.37, 2010-07-02 07:43:20+01:00, davehart@shiny.ad.hartbrothers.com +3 -3 + [Bug 1581] size_t printf format string mismatches (backported from ntp-dev). - ntpdc/ntpdc-opts.texi@1.83, 2009-12-08 07:45:21-05:00, stenn@whimsy.udel.edu +7 -4 - NTP_4_2_4P9_RC1 + ntpd/refclock_irig.c@1.33, 2010-07-02 07:43:20+01:00, davehart@shiny.ad.hartbrothers.com +3 -3 + [Bug 1581] sscanf() target buffers lack room for terminating null. - ntpdc/ntpdc.1@1.83, 2009-12-08 07:45:22-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P9_RC1 + ntpdc/ntpdc.c@1.77, 2010-07-02 07:43:20+01:00, davehart@shiny.ad.hartbrothers.com +7 -7 + [Bug 1581] size_t printf format string mismatches (backported from ntp-dev). - ntpq/ntpq-opts.c@1.87, 2009-12-08 07:45:22-05:00, stenn@whimsy.udel.edu +5 -5 - NTP_4_2_4P9_RC1 + ntpq/ntpq.c@1.102, 2010-07-02 07:43:20+01:00, davehart@shiny.ad.hartbrothers.com +6 -6 + [Bug 1581] size_t printf format string mismatches (backported from ntp-dev). - ntpq/ntpq-opts.h@1.87, 2009-12-08 07:45:22-05:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P9_RC1 +ChangeSet@1.2190, 2010-06-19 02:49:04-04:00, stenn@deacon.udel.edu +27 -0 + NTP_4_2_6P2_RC7 + TAG: NTP_4_2_6P2_RC7 - ntpq/ntpq-opts.texi@1.84, 2009-12-08 07:45:22-05:00, stenn@whimsy.udel.edu +8 -4 - NTP_4_2_4P9_RC1 + ChangeLog@1.644, 2010-06-19 02:49:00-04:00, stenn@deacon.udel.edu +1 -0 + NTP_4_2_6P2_RC7 - ntpq/ntpq.1@1.83, 2009-12-08 07:45:23-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P9_RC1 + ntpd/ntpd-opts.c@1.262, 2010-06-19 02:49:00-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC7 - packageinfo.sh@1.117, 2009-12-08 07:45:23-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P9_RC1 + ntpd/ntpd-opts.h@1.262, 2010-06-19 02:49:00-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC7 - sntp/sntp-opts.c@1.83, 2009-12-08 07:45:23-05:00, stenn@whimsy.udel.edu +5 -5 - NTP_4_2_4P9_RC1 + ntpd/ntpd-opts.texi@1.260, 2010-06-19 02:49:00-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC7 - sntp/sntp-opts.h@1.83, 2009-12-08 07:45:23-05:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P9_RC1 + ntpd/ntpd.1@1.260, 2010-06-19 02:49:00-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC7 - sntp/sntp-opts.texi@1.80, 2009-12-08 07:45:24-05:00, stenn@whimsy.udel.edu +54 -2 - NTP_4_2_4P9_RC1 + ntpdc/ntpdc-opts.c@1.258, 2010-06-19 02:49:00-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC7 - sntp/sntp.1@1.83, 2009-12-08 07:45:24-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P9_RC1 + ntpdc/ntpdc-opts.h@1.258, 2010-06-19 02:49:00-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC7 - util/ntp-keygen-opts.c@1.84, 2009-12-08 07:45:24-05:00, stenn@whimsy.udel.edu +5 -5 - NTP_4_2_4P9_RC1 + ntpdc/ntpdc-opts.texi@1.257, 2010-06-19 02:49:00-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC7 - util/ntp-keygen-opts.h@1.84, 2009-12-08 07:45:24-05:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P9_RC1 + ntpdc/ntpdc.1@1.257, 2010-06-19 02:49:00-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC7 - util/ntp-keygen-opts.texi@1.82, 2009-12-08 07:45:24-05:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P9_RC1 + ntpq/ntpq-opts.c@1.259, 2010-06-19 02:49:00-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC7 - util/ntp-keygen.1@1.82, 2009-12-08 07:45:25-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P9_RC1 + ntpq/ntpq-opts.h@1.259, 2010-06-19 02:49:01-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC7 -ChangeSet@1.1609, 2009-12-08 05:36:47-05:00, stenn@whimsy.udel.edu +2 -0 - [Sec 1331] DoS with mode 7 packets - CVE-2009-3563 + ntpq/ntpq-opts.texi@1.258, 2010-06-19 02:49:01-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC7 - NEWS@1.102, 2009-12-08 05:36:36-05:00, stenn@whimsy.udel.edu +34 -0 - [Sec 1331] DoS with mode 7 packets - CVE-2009-3563 + ntpq/ntpq.1@1.258, 2010-06-19 02:49:01-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC7 - packageinfo.sh@1.116, 2009-12-08 05:36:36-05:00, stenn@whimsy.udel.edu +2 -2 - [Sec 1331] DoS with mode 7 packets - CVE-2009-3563 + ntpsnmpd/ntpsnmpd-opts.c@1.138, 2010-06-19 02:49:01-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC7 -ChangeSet@1.1608, 2009-10-07 01:33:22+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - [Sec 1331] DoS with mode 7 packets - CVE-2009-3563. + ntpsnmpd/ntpsnmpd-opts.h@1.138, 2010-06-19 02:49:01-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC7 - ChangeLog@1.92, 2009-10-07 01:33:21+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 - [Sec 1331] DoS with mode 7 packets - CVE-2009-3563. + ntpsnmpd/ntpsnmpd-opts.texi@1.138, 2010-06-19 02:49:01-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC7 - ntpd/ntp_request.c@1.68, 2009-10-07 01:33:21+00:00, davehart@shiny.ad.hartbrothers.com +9 -2 - [Sec 1331] DoS with mode 7 packets - CVE-2009-3563. + ntpsnmpd/ntpsnmpd.1@1.137, 2010-06-19 02:49:01-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC7 -ChangeSet@1.1607, 2009-05-18 05:04:41-04:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P7 - TAG: NTP_4_2_4P7 + packageinfo.sh@1.275, 2010-06-19 02:49:01-04:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P2_RC7 - ChangeLog@1.91, 2009-05-18 05:04:18-04:00, stenn@whimsy.udel.edu +1 -0 - NTP_4_2_4P7 + sntp/sntp-opts.c@1.131, 2010-06-19 02:49:01-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC7 - ntpd/ntpd-opts.c@1.84, 2009-05-18 05:04:19-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P7 + sntp/sntp-opts.h@1.131, 2010-06-19 02:49:01-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC7 - ntpd/ntpd-opts.h@1.84, 2009-05-18 05:04:20-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P7 + sntp/sntp-opts.texi@1.131, 2010-06-19 02:49:01-04:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P2_RC7 - ntpd/ntpd-opts.texi@1.83, 2009-05-18 05:04:21-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7 + sntp/sntp.1@1.131, 2010-06-19 02:49:01-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC7 - ntpd/ntpd.1@1.82, 2009-05-18 05:04:22-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7 + sntp/sntp.html@1.21, 2010-06-19 02:49:01-04:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P2_RC7 - ntpd/ntpdsim-opts.c@1.84, 2009-05-18 05:04:22-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P7 + util/ntp-keygen-opts.c@1.261, 2010-06-19 02:49:01-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC7 - ntpd/ntpdsim-opts.h@1.84, 2009-05-18 05:04:23-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P7 + util/ntp-keygen-opts.h@1.261, 2010-06-19 02:49:01-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC7 - ntpd/ntpdsim-opts.texi@1.82, 2009-05-18 05:04:24-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7 + util/ntp-keygen-opts.texi@1.260, 2010-06-19 02:49:01-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC7 - ntpd/ntpdsim.1@1.82, 2009-05-18 05:04:25-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7 + util/ntp-keygen.1@1.260, 2010-06-19 02:49:01-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC7 - ntpdc/ntpdc-opts.c@1.84, 2009-05-18 05:04:26-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P7 +ChangeSet@1.2189, 2010-06-19 02:32:32-04:00, stenn@deacon.udel.edu +2 -0 + [Bug 1570] serial clock drivers get outdated input from kernel tty line buffer after startup - ntpdc/ntpdc-opts.h@1.84, 2009-05-18 05:04:26-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P7 + ChangeLog@1.643, 2010-06-19 02:32:09-04:00, stenn@deacon.udel.edu +2 -0 + [Bug 1570] serial clock drivers get outdated input from kernel tty line buffer after startup - ntpdc/ntpdc-opts.texi@1.82, 2009-05-18 05:04:27-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7 + ntpd/ntp_refclock.c@1.93, 2010-06-19 02:32:25-04:00, stenn@deacon.udel.edu +21 -0 + [Bug 1570] serial clock drivers get outdated input from kernel tty line buffer after startup - ntpdc/ntpdc.1@1.82, 2009-05-18 05:04:28-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7 +ChangeSet@1.2188, 2010-06-19 01:59:33-04:00, stenn@deacon.udel.edu +1 -0 + merge cleanup - ntpq/ntpq-opts.c@1.86, 2009-05-18 05:04:29-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P7 + ChangeLog@1.642, 2010-06-19 01:59:28-04:00, stenn@deacon.udel.edu +2 -3 + merge cleanup - ntpq/ntpq-opts.h@1.86, 2009-05-18 05:04:29-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P7 +ChangeSet@1.2185.1.1, 2010-06-19 01:57:32-04:00, stenn@deacon.udel.edu +2 -0 + [Bug 1576] sys/sysctl.h depends on sys/param.h on OpenBSD - ntpq/ntpq-opts.texi@1.83, 2009-05-18 05:04:30-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7 + ChangeLog@1.639.1.1, 2010-06-19 01:51:39-04:00, stenn@deacon.udel.edu +4 -0 + [Bug 1576] sys/sysctl.h depends on sys/param.h on OpenBSD - ntpq/ntpq.1@1.82, 2009-05-18 05:04:31-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7 + configure.ac@1.477, 2010-06-19 01:51:39-04:00, stenn@deacon.udel.edu +7 -2 + [Bug 1576] sys/sysctl.h depends on sys/param.h on OpenBSD - packageinfo.sh@1.115, 2009-05-18 05:04:32-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7 +ChangeSet@1.2186, 2010-06-15 08:25:18-04:00, perlinger@psp-deb1.ntp.org +4 -0 + [Bug 1575] use snprintf with LIB_BUFLENGTH in inttoa.c, tvtoa.c, utvtoa.c - sntp/sntp-opts.c@1.82, 2009-05-18 05:04:32-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7 + ChangeLog@1.640, 2010-06-15 08:25:16-04:00, perlinger@psp-deb1.ntp.org +3 -0 + [Bug 1575] use snprintf with LIB_BUFLENGTH in inttoa.c, tvtoa.c, utvtoa.c - sntp/sntp-opts.h@1.82, 2009-05-18 05:04:33-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7 + libntp/inttoa.c@1.4, 2010-06-15 08:25:17-04:00, perlinger@psp-deb1.ntp.org +1 -1 + [Bug 1575] use snprintf with LIB_BUFLENGTH in inttoa.c, tvtoa.c, utvtoa.c - sntp/sntp-opts.texi@1.79, 2009-05-18 05:04:34-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7 + libntp/tvtoa.c@1.4, 2010-06-15 08:25:17-04:00, perlinger@psp-deb1.ntp.org +1 -1 + [Bug 1575] use snprintf with LIB_BUFLENGTH in inttoa.c, tvtoa.c, utvtoa.c - sntp/sntp.1@1.82, 2009-05-18 05:04:34-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7 + libntp/utvtoa.c@1.4, 2010-06-15 08:25:17-04:00, perlinger@psp-deb1.ntp.org +1 -1 + [Bug 1575] use snprintf with LIB_BUFLENGTH in inttoa.c, tvtoa.c, utvtoa.c - util/ntp-keygen-opts.c@1.83, 2009-05-18 05:04:35-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P7 +ChangeSet@1.2185, 2010-06-12 02:21:49-04:00, stenn@deacon.udel.edu +27 -0 + NTP_4_2_6P2_RC6 + TAG: NTP_4_2_6P2_RC6 - util/ntp-keygen-opts.h@1.83, 2009-05-18 05:04:36-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P7 + ChangeLog@1.639, 2010-06-12 02:21:46-04:00, stenn@deacon.udel.edu +1 -0 + NTP_4_2_6P2_RC6 - util/ntp-keygen-opts.texi@1.81, 2009-05-18 05:04:37-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7 + ntpd/ntpd-opts.c@1.261, 2010-06-12 02:21:46-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC6 - util/ntp-keygen.1@1.81, 2009-05-18 05:04:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7 + ntpd/ntpd-opts.h@1.261, 2010-06-12 02:21:46-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC6 -ChangeSet@1.1606, 2009-05-18 03:14:59-04:00, stenn@whimsy.udel.edu +2 -0 - 4.2.4p7 + ntpd/ntpd-opts.texi@1.259, 2010-06-12 02:21:46-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC6 - NEWS@1.101, 2009-05-18 03:14:49-04:00, stenn@whimsy.udel.edu +38 -0 - 4.2.4p7 + ntpd/ntpd.1@1.259, 2010-06-12 02:21:46-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC6 - packageinfo.sh@1.114, 2009-05-18 03:14:50-04:00, stenn@whimsy.udel.edu +1 -1 - 4.2.4p7 + ntpdc/ntpdc-opts.c@1.257, 2010-06-12 02:21:46-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC6 -ChangeSet@1.1605, 2009-05-18 02:56:36-04:00, stenn@whimsy.udel.edu +2 -0 - [Sec 1151] Remote exploit if autokey is enabled - CVE-2009-1252 + ntpdc/ntpdc-opts.h@1.257, 2010-06-12 02:21:46-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC6 - ChangeLog@1.90, 2009-05-18 02:56:22-04:00, stenn@whimsy.udel.edu +1 -0 - [Sec 1151] Remote exploit if autokey is enabled - CVE-2009-1252 + ntpdc/ntpdc-opts.texi@1.256, 2010-06-12 02:21:46-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC6 - ntpd/ntp_crypto.c@1.110, 2009-05-18 02:56:22-04:00, stenn@whimsy.udel.edu +22 -17 - [Sec 1151] Remote exploit if autokey is enabled - CVE-2009-1252 + ntpdc/ntpdc.1@1.256, 2010-06-12 02:21:46-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC6 -ChangeSet@1.1604, 2009-05-18 02:24:31-04:00, stenn@whimsy.udel.edu +2 -0 - [Bug 1187] Update the copyright date. + ntpq/ntpq-opts.c@1.258, 2010-06-12 02:21:46-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC6 - ChangeLog@1.89, 2009-05-18 02:24:21-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 1187] Update the copyright date. + ntpq/ntpq-opts.h@1.258, 2010-06-12 02:21:46-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC6 - include/copyright.def@1.8, 2009-05-18 02:24:22-04:00, stenn@whimsy.udel.edu +1 -1 - [Bug 1187] Update the copyright date. + ntpq/ntpq-opts.texi@1.257, 2010-06-12 02:21:46-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC6 -ChangeSet@1.1603, 2009-05-17 08:59:06+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - [Bug 1191] ntpd fails on Win2000 - "Address already in use" after fix - for [Sec 1149]. + ntpq/ntpq.1@1.257, 2010-06-12 02:21:46-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC6 - ChangeLog@1.88, 2009-05-17 08:59:05+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 - [Bug 1191] ntpd fails on Win2000 - "Address already in use" after fix - for [Sec 1149]. + ntpsnmpd/ntpsnmpd-opts.c@1.137, 2010-06-12 02:21:47-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC6 - ntpd/ntp_io.c@1.261, 2009-05-17 08:59:05+00:00, davehart@shiny.ad.hartbrothers.com +45 -34 - [Bug 1191] ntpd fails on Win2000 - "Address already in use" after fix - for [Sec 1149]. + ntpsnmpd/ntpsnmpd-opts.h@1.137, 2010-06-12 02:21:47-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC6 -ChangeSet@1.1602, 2009-05-14 04:42:10+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - fix error from BitKeeper/triggers/pre-resolve.licfix triggered (ahem) - by recent BitKeeper/etc/config delta updating repologs email address + ntpsnmpd/ntpsnmpd-opts.texi@1.137, 2010-06-12 02:21:47-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC6 - BitKeeper/triggers/pre-resolve.licfix@1.5, 2009-05-14 04:42:09+00:00, davehart@shiny.ad.hartbrothers.com +4 -1 - bk sccscat has been removed, replaced by bk annotate -R - -q grep -> grep -q (untested until recent BitKeeper/etc/config commit - changing repologs@ntp.isc.org to repologs@ntp.org + ntpsnmpd/ntpsnmpd.1@1.136, 2010-06-12 02:21:47-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC6 -ChangeSet@1.1601, 2009-05-12 02:41:56-04:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P7_RC7 - TAG: NTP_4_2_4P7_RC7 + packageinfo.sh@1.274, 2010-06-12 02:21:47-04:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P2_RC6 - ChangeLog@1.87, 2009-05-12 02:41:33-04:00, stenn@whimsy.udel.edu +1 -0 - NTP_4_2_4P7_RC7 + sntp/sntp-opts.c@1.130, 2010-06-12 02:21:47-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC6 - ntpd/ntpd-opts.c@1.83, 2009-05-12 02:41:33-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + sntp/sntp-opts.h@1.130, 2010-06-12 02:21:47-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC6 - ntpd/ntpd-opts.h@1.83, 2009-05-12 02:41:33-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + sntp/sntp-opts.texi@1.130, 2010-06-12 02:21:47-04:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P2_RC6 - ntpd/ntpd-opts.texi@1.82, 2009-05-12 02:41:35-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC7 + sntp/sntp.1@1.130, 2010-06-12 02:21:47-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC6 - ntpd/ntpd.1@1.81, 2009-05-12 02:41:35-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + sntp/sntp.html@1.20, 2010-06-12 02:21:47-04:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P2_RC6 - ntpd/ntpdsim-opts.c@1.83, 2009-05-12 02:41:36-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + util/ntp-keygen-opts.c@1.260, 2010-06-12 02:21:47-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC6 - ntpd/ntpdsim-opts.h@1.83, 2009-05-12 02:41:37-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + util/ntp-keygen-opts.h@1.260, 2010-06-12 02:21:47-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC6 - ntpd/ntpdsim-opts.texi@1.81, 2009-05-12 02:41:37-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC7 + util/ntp-keygen-opts.texi@1.259, 2010-06-12 02:21:47-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC6 - ntpd/ntpdsim.1@1.81, 2009-05-12 02:41:38-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + util/ntp-keygen.1@1.259, 2010-06-12 02:21:48-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC6 - ntpdc/ntpdc-opts.c@1.83, 2009-05-12 02:41:39-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 +ChangeSet@1.2184, 2010-06-08 13:15:32+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 715] libisc Linux IPv6 interface iteration drops multicast flags. - ntpdc/ntpdc-opts.h@1.83, 2009-05-12 02:41:40-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + ChangeLog@1.638, 2010-06-08 13:15:31+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 715] libisc Linux IPv6 interface iteration drops multicast flags. - ntpdc/ntpdc-opts.texi@1.81, 2009-05-12 02:41:41-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC7 + lib/isc/unix/interfaceiter.c@1.18, 2010-06-08 13:15:31+00:00, davehart@shiny.ad.hartbrothers.com +32 -3 + [Bug 715] libisc Linux IPv6 interface iteration drops multicast flags. + patch from joerg@dorchain.net adapted from original by + peter.pramberger@1012surf.net - ntpdc/ntpdc.1@1.81, 2009-05-12 02:41:42-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 +ChangeSet@1.2183, 2010-06-03 02:24:13-04:00, stenn@deacon.udel.edu +27 -0 + NTP_4_2_6P2_RC5 + TAG: NTP_4_2_6P2_RC5 - ntpq/ntpq-opts.c@1.85, 2009-05-12 02:41:43-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + ChangeLog@1.637, 2010-06-03 02:24:09-04:00, stenn@deacon.udel.edu +1 -0 + NTP_4_2_6P2_RC5 - ntpq/ntpq-opts.h@1.85, 2009-05-12 02:41:44-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + ntpd/ntpd-opts.c@1.260, 2010-06-03 02:24:09-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC5 - ntpq/ntpq-opts.texi@1.82, 2009-05-12 02:41:45-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC7 + ntpd/ntpd-opts.h@1.260, 2010-06-03 02:24:09-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC5 - ntpq/ntpq.1@1.81, 2009-05-12 02:41:46-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + ntpd/ntpd-opts.texi@1.258, 2010-06-03 02:24:09-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC5 - packageinfo.sh@1.113, 2009-05-12 02:41:47-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC7 + ntpd/ntpd.1@1.258, 2010-06-03 02:24:09-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC5 - sntp/sntp-opts.c@1.81, 2009-05-12 02:41:47-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + ntpdc/ntpdc-opts.c@1.256, 2010-06-03 02:24:09-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC5 - sntp/sntp-opts.h@1.81, 2009-05-12 02:41:48-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + ntpdc/ntpdc-opts.h@1.256, 2010-06-03 02:24:10-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC5 - sntp/sntp-opts.texi@1.78, 2009-05-12 02:41:49-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC7 + ntpdc/ntpdc-opts.texi@1.255, 2010-06-03 02:24:10-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC5 - sntp/sntp.1@1.81, 2009-05-12 02:41:50-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + ntpdc/ntpdc.1@1.255, 2010-06-03 02:24:10-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC5 - util/ntp-keygen-opts.c@1.82, 2009-05-12 02:41:51-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + ntpq/ntpq-opts.c@1.257, 2010-06-03 02:24:10-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC5 - util/ntp-keygen-opts.h@1.82, 2009-05-12 02:41:51-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + ntpq/ntpq-opts.h@1.257, 2010-06-03 02:24:10-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC5 - util/ntp-keygen-opts.texi@1.80, 2009-05-12 02:41:52-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC7 + ntpq/ntpq-opts.texi@1.256, 2010-06-03 02:24:11-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC5 - util/ntp-keygen.1@1.80, 2009-05-12 02:41:53-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + ntpq/ntpq.1@1.256, 2010-06-03 02:24:11-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC5 -ChangeSet@1.1600, 2009-05-12 01:07:37-04:00, stenn@whimsy.udel.edu +9 -0 - ntp.isc.org -> ntp.org cleanup + ntpsnmpd/ntpsnmpd-opts.c@1.136, 2010-06-03 02:24:11-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC5 - BitKeeper/etc/config@1.10, 2009-05-12 01:06:49-04:00, stenn@whimsy.udel.edu +1 -1 - ntp.isc.org -> ntp.org cleanup + ntpsnmpd/ntpsnmpd-opts.h@1.136, 2010-06-03 02:24:11-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC5 - ChangeLog@1.86, 2009-05-12 01:06:01-04:00, stenn@whimsy.udel.edu +1 -0 - ntp.isc.org -> ntp.org cleanup + ntpsnmpd/ntpsnmpd-opts.texi@1.136, 2010-06-03 02:24:11-04:00, stenn@deacon.udel.edu +24 -2 + NTP_4_2_6P2_RC5 - README@1.23, 2009-05-12 01:06:02-04:00, stenn@whimsy.udel.edu +1 -1 - ntp.isc.org -> ntp.org cleanup + ntpsnmpd/ntpsnmpd.1@1.135, 2010-06-03 02:24:11-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC5 - README.bk@1.19, 2009-05-12 01:06:03-04:00, stenn@whimsy.udel.edu +1 -1 - ntp.isc.org -> ntp.org cleanup + packageinfo.sh@1.273, 2010-06-03 02:24:11-04:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P2_RC5 - README.patches@1.4, 2009-05-12 01:06:03-04:00, stenn@whimsy.udel.edu +1 -1 - ntp.isc.org -> ntp.org cleanup + sntp/sntp-opts.c@1.129, 2010-06-03 02:24:11-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC5 - WHERE-TO-START@1.7, 2009-05-12 01:06:03-04:00, stenn@whimsy.udel.edu +1 -1 - ntp.isc.org -> ntp.org cleanup + sntp/sntp-opts.h@1.129, 2010-06-03 02:24:11-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC5 - configure.ac@1.418, 2009-05-12 01:06:04-04:00, stenn@whimsy.udel.edu +1 -1 - ntp.isc.org -> ntp.org cleanup + sntp/sntp-opts.texi@1.129, 2010-06-03 02:24:11-04:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P2_RC5 - include/copyright.def@1.7, 2009-05-12 01:06:49-04:00, stenn@whimsy.udel.edu +1 -1 - ntp.isc.org -> ntp.org cleanup + sntp/sntp.1@1.129, 2010-06-03 02:24:11-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC5 - sntp/sntp-opts.def@1.11, 2009-05-12 01:06:49-04:00, stenn@whimsy.udel.edu +1 -1 - ntp.isc.org -> ntp.org cleanup + sntp/sntp.html@1.19, 2010-06-03 02:24:11-04:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P2_RC5 -ChangeSet@1.1597.1.1, 2009-05-08 18:11:36+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - configure.ac: - correct help text + util/ntp-keygen-opts.c@1.259, 2010-06-03 02:24:11-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC5 - configure.ac@1.415.1.1, 2009-05-08 18:11:24+00:00, davehart@shiny.ad.hartbrothers.com +11 -5 - correct help text + util/ntp-keygen-opts.h@1.259, 2010-06-03 02:24:11-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC5 -ChangeSet@1.1598, 2009-05-08 17:50:37+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 - add configure --enable-ignore-dns-errors to retry on any failure + util/ntp-keygen-opts.texi@1.258, 2010-06-03 02:24:11-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC5 - ChangeLog@1.85, 2009-05-08 17:50:35+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 - add configure --enable-ignore-dns-errors to retry on any failure + util/ntp-keygen.1@1.258, 2010-06-03 02:24:12-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC5 - configure.ac@1.416, 2009-05-08 17:50:35+00:00, davehart@shiny.ad.hartbrothers.com +26 -4 - add configure --enable-ignore-dns-errors to retry on any failure +ChangeSet@1.2182, 2010-05-31 18:59:05+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1565] sntp/crypto.c compile fails on MacOS over vsnprintf(). + - ntpd/ntp_intres.c@1.55, 2009-05-08 17:50:35+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - add configure --enable-ignore-dns-errors to retry on any failure + ChangeLog@1.636, 2010-05-31 18:59:04+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1565] sntp/crypto.c compile fails on MacOS over vsnprintf(). + -ChangeSet@1.1597, 2009-05-08 15:34:46+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 - Do not exceed FD_SETSIZE in ntp_intres.c - --- - ntp_intres.c: - typo - --- - ntp_intres.c: - missing comma typo - --- - ntp_intres.c: - typo + sntp/configure.ac@1.33, 2010-05-31 18:59:04+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + [Bug 1565] sntp/crypto.c compile fails on MacOS over vsnprintf(). + - ntpd/ntp_intres.c@1.54, 2009-05-08 15:34:45+00:00, davehart@shiny.ad.hartbrothers.com +64 -33 - fix typos, refine "host name not found" log message, stay under FD_SETSIZE +ChangeSet@1.2181, 2010-05-24 15:46:36+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + [Bug 1561] ntpq, ntpdc "passwd" prompts for MD5 password w/SHA1. + Windows port: do not exit in ntp_timestamp_from_counter() without + first logging the reason. + Support "passwd blah" syntax in ntpq. - ntpd/ntp_request.c@1.67, 2009-05-08 15:34:45+00:00, davehart@shiny.ad.hartbrothers.com +21 -3 - after ntp_intres adds a server entry, rescan interfaces, to notice the - return of connectivity sooner. + ChangeLog@1.635, 2010-05-24 15:46:35+00:00, davehart@shiny.ad.hartbrothers.com +7 -0 + [Bug 1561] ntpq, ntpdc "passwd" prompts for MD5 password w/SHA1. + Windows port: do not exit in ntp_timestamp_from_counter() without + first logging the reason. + Support "passwd blah" syntax in ntpq. - ntpd/ntp_timer.c@1.34, 2009-05-08 15:34:45+00:00, davehart@shiny.ad.hartbrothers.com +3 -5 - indent cleanup + include/ntp_stdlib.h@1.42, 2010-05-24 15:46:35+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1561] ntpq, ntpdc "passwd" prompts for MD5 password w/SHA1. - ports/winnt/include/config.h@1.52, 2009-05-08 15:34:45+00:00, davehart@shiny.ad.hartbrothers.com +4 -10 - remove FORCE_DNSRETRY, no longer used - indent cleanup + libntp/ssl_init.c@1.5, 2010-05-24 15:46:35+00:00, davehart@shiny.ad.hartbrothers.com +25 -0 + [Bug 1561] ntpq, ntpdc "passwd" prompts for MD5 password w/SHA1. -ChangeSet@1.1587.1.1, 2009-05-08 11:24:43+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - [Bug 1178] Use prior FORCE_DNSRETRY behavior as needed at runtime + ntpdc/ntpdc.c@1.76, 2010-05-24 15:46:35+00:00, davehart@shiny.ad.hartbrothers.com +2 -14 + [Bug 1561] ntpq, ntpdc "passwd" prompts for MD5 password w/SHA1. - ChangeLog@1.76.1.1, 2009-05-08 11:24:42+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 - [Bug 1178] Use prior FORCE_DNSRETRY behavior as needed at runtime + ntpq/ntpq.c@1.101, 2010-05-24 15:46:35+00:00, davehart@shiny.ad.hartbrothers.com +16 -21 + [Bug 1561] ntpq, ntpdc "passwd" prompts for MD5 password w/SHA1. + Support "passwd blah" syntax in ntpq. - ntpd/ntp_intres.c@1.53, 2009-05-08 11:24:42+00:00, davehart@shiny.ad.hartbrothers.com +53 -55 - [Bug 1178] Use prior FORCE_DNSRETRY behavior as needed at runtime + ports/winnt/ntpd/nt_clockstuff.c@1.40, 2010-05-24 15:46:35+00:00, davehart@shiny.ad.hartbrothers.com +6 -3 + Windows port: do not exit in ntp_timestamp_from_counter() without + first logging the reason. -ChangeSet@1.1595, 2009-05-08 04:42:52-04:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P7_RC6 - TAG: NTP_4_2_4P7_RC6 +ChangeSet@1.2180, 2010-05-19 00:02:06-04:00, stenn@deacon.udel.edu +27 -0 + NTP_4_2_6P2_RC4 + TAG: NTP_4_2_6P2_RC4 - ChangeLog@1.83, 2009-05-08 04:42:28-04:00, stenn@whimsy.udel.edu +1 -0 - NTP_4_2_4P7_RC6 + ChangeLog@1.634, 2010-05-19 00:02:03-04:00, stenn@deacon.udel.edu +1 -0 + NTP_4_2_6P2_RC4 - ntpd/ntpd-opts.c@1.82, 2009-05-08 04:42:28-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + ntpd/ntpd-opts.c@1.259, 2010-05-19 00:02:03-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC4 - ntpd/ntpd-opts.h@1.82, 2009-05-08 04:42:29-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC6 + ntpd/ntpd-opts.h@1.259, 2010-05-19 00:02:04-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC4 - ntpd/ntpd-opts.texi@1.81, 2009-05-08 04:42:30-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + ntpd/ntpd-opts.texi@1.257, 2010-05-19 00:02:04-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC4 - ntpd/ntpd.1@1.80, 2009-05-08 04:42:30-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + ntpd/ntpd.1@1.257, 2010-05-19 00:02:04-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC4 - ntpd/ntpdsim-opts.c@1.82, 2009-05-08 04:42:31-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + ntpdc/ntpdc-opts.c@1.255, 2010-05-19 00:02:04-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC4 - ntpd/ntpdsim-opts.h@1.82, 2009-05-08 04:42:32-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC6 + ntpdc/ntpdc-opts.h@1.255, 2010-05-19 00:02:04-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC4 - ntpd/ntpdsim-opts.texi@1.80, 2009-05-08 04:42:33-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC6 + ntpdc/ntpdc-opts.texi@1.254, 2010-05-19 00:02:04-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC4 - ntpd/ntpdsim.1@1.80, 2009-05-08 04:42:34-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + ntpdc/ntpdc.1@1.254, 2010-05-19 00:02:04-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC4 - ntpdc/ntpdc-opts.c@1.82, 2009-05-08 04:42:35-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + ntpq/ntpq-opts.c@1.256, 2010-05-19 00:02:04-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC4 - ntpdc/ntpdc-opts.h@1.82, 2009-05-08 04:42:35-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC6 + ntpq/ntpq-opts.h@1.256, 2010-05-19 00:02:04-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC4 - ntpdc/ntpdc-opts.texi@1.80, 2009-05-08 04:42:36-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + ntpq/ntpq-opts.texi@1.255, 2010-05-19 00:02:04-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC4 - ntpdc/ntpdc.1@1.80, 2009-05-08 04:42:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + ntpq/ntpq.1@1.255, 2010-05-19 00:02:04-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC4 - ntpq/ntpq-opts.c@1.84, 2009-05-08 04:42:38-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + ntpsnmpd/ntpsnmpd-opts.c@1.135, 2010-05-19 00:02:04-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC4 - ntpq/ntpq-opts.h@1.84, 2009-05-08 04:42:39-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC6 + ntpsnmpd/ntpsnmpd-opts.h@1.135, 2010-05-19 00:02:04-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC4 - ntpq/ntpq-opts.texi@1.81, 2009-05-08 04:42:40-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + ntpsnmpd/ntpsnmpd-opts.texi@1.135, 2010-05-19 00:02:04-04:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P2_RC4 - ntpq/ntpq.1@1.80, 2009-05-08 04:42:41-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + ntpsnmpd/ntpsnmpd.1@1.134, 2010-05-19 00:02:05-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC4 - packageinfo.sh@1.112, 2009-05-08 04:42:42-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC6 + packageinfo.sh@1.272, 2010-05-19 00:02:05-04:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P2_RC4 - sntp/sntp-opts.c@1.80, 2009-05-08 04:42:43-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + sntp/sntp-opts.c@1.128, 2010-05-19 00:02:05-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC4 - sntp/sntp-opts.h@1.80, 2009-05-08 04:42:43-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC6 + sntp/sntp-opts.h@1.128, 2010-05-19 00:02:05-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC4 - sntp/sntp-opts.texi@1.77, 2009-05-08 04:42:44-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC6 + sntp/sntp-opts.texi@1.128, 2010-05-19 00:02:05-04:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P2_RC4 - sntp/sntp.1@1.80, 2009-05-08 04:42:44-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + sntp/sntp.1@1.128, 2010-05-19 00:02:05-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC4 - util/ntp-keygen-opts.c@1.81, 2009-05-08 04:42:45-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + sntp/sntp.html@1.18, 2010-05-19 00:02:05-04:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P2_RC4 - util/ntp-keygen-opts.h@1.81, 2009-05-08 04:42:46-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC6 + util/ntp-keygen-opts.c@1.258, 2010-05-19 00:02:05-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC4 - util/ntp-keygen-opts.texi@1.79, 2009-05-08 04:42:47-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + util/ntp-keygen-opts.h@1.258, 2010-05-19 00:02:05-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC4 - util/ntp-keygen.1@1.79, 2009-05-08 04:42:48-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + util/ntp-keygen-opts.texi@1.257, 2010-05-19 00:02:05-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC4 -ChangeSet@1.1594, 2009-05-08 03:29:16-04:00, stenn@pogo.udel.edu +1 -0 - typo + util/ntp-keygen.1@1.257, 2010-05-19 00:02:05-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC4 - ChangeLog@1.82, 2009-05-08 03:28:46-04:00, stenn@pogo.udel.edu +1 -1 - typo +ChangeSet@1.2179, 2010-05-13 15:39:47+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + * [Bug 1555] 4.2.6p2-RC3 sntp illegal C (mixed code and declarations). + -ChangeSet@1.1593, 2009-05-08 02:13:17+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - Add [Bug 1071] reference to ChangeLog entry + ChangeLog@1.633, 2010-05-13 15:39:46+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + * [Bug 1555] 4.2.6p2-RC3 sntp illegal C (mixed code and declarations). + - ChangeLog@1.81, 2009-05-08 02:13:16+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 - [Bug 1071] Log a message and exit before trying to use FD_SET with a - descriptor larger than FD_SETSIZE, which will corrupt memory - (adds reference to 1071 to existing description) + sntp/networking.c@1.35, 2010-05-13 15:39:46+00:00, davehart@shiny.ad.hartbrothers.com +5 -3 + * [Bug 1555] 4.2.6p2-RC3 sntp illegal C (mixed code and declarations). + -ChangeSet@1.1592, 2009-05-08 01:23:43+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - [Bug 1179] error messages for -u/--user and -i when built w/o droproot +ChangeSet@1.2178, 2010-05-11 03:56:04-04:00, stenn@deacon.udel.edu +27 -0 + NTP_4_2_6P2_RC3 + TAG: NTP_4_2_6P2_RC3 + + ChangeLog@1.632, 2010-05-11 03:56:01-04:00, stenn@deacon.udel.edu +1 -0 + NTP_4_2_6P2_RC3 + + ntpd/ntpd-opts.c@1.258, 2010-05-11 03:56:02-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC3 + + ntpd/ntpd-opts.h@1.258, 2010-05-11 03:56:02-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC3 + + ntpd/ntpd-opts.texi@1.256, 2010-05-11 03:56:02-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC3 + + ntpd/ntpd.1@1.256, 2010-05-11 03:56:02-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC3 + + ntpdc/ntpdc-opts.c@1.254, 2010-05-11 03:56:02-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC3 + + ntpdc/ntpdc-opts.h@1.254, 2010-05-11 03:56:02-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC3 + + ntpdc/ntpdc-opts.texi@1.253, 2010-05-11 03:56:02-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC3 + + ntpdc/ntpdc.1@1.253, 2010-05-11 03:56:02-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC3 + + ntpq/ntpq-opts.c@1.255, 2010-05-11 03:56:02-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC3 + + ntpq/ntpq-opts.h@1.255, 2010-05-11 03:56:02-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC3 + + ntpq/ntpq-opts.texi@1.254, 2010-05-11 03:56:02-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC3 + + ntpq/ntpq.1@1.254, 2010-05-11 03:56:02-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC3 + + ntpsnmpd/ntpsnmpd-opts.c@1.134, 2010-05-11 03:56:02-04:00, stenn@deacon.udel.edu +5 -5 + NTP_4_2_6P2_RC3 + + ntpsnmpd/ntpsnmpd-opts.h@1.134, 2010-05-11 03:56:02-04:00, stenn@deacon.udel.edu +4 -4 + NTP_4_2_6P2_RC3 + + ntpsnmpd/ntpsnmpd-opts.texi@1.134, 2010-05-11 03:56:02-04:00, stenn@deacon.udel.edu +2 -24 + NTP_4_2_6P2_RC3 + + ntpsnmpd/ntpsnmpd.1@1.133, 2010-05-11 03:56:02-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC3 + + packageinfo.sh@1.271, 2010-05-11 03:56:02-04:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P2_RC3 + + sntp/sntp-opts.c@1.127, 2010-05-11 03:56:02-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC3 + + sntp/sntp-opts.h@1.127, 2010-05-11 03:56:02-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC3 + + sntp/sntp-opts.texi@1.127, 2010-05-11 03:56:02-04:00, stenn@deacon.udel.edu +2 -60 + NTP_4_2_6P2_RC3 + + sntp/sntp.1@1.127, 2010-05-11 03:56:02-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC3 + + sntp/sntp.html@1.17, 2010-05-11 03:56:03-04:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P2_RC3 + + util/ntp-keygen-opts.c@1.257, 2010-05-11 03:56:03-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC3 + + util/ntp-keygen-opts.h@1.257, 2010-05-11 03:56:03-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC3 + + util/ntp-keygen-opts.texi@1.256, 2010-05-11 03:56:03-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC3 + + util/ntp-keygen.1@1.256, 2010-05-11 03:56:03-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC3 + +ChangeSet@1.2171.1.1, 2010-05-11 02:31:19-04:00, stenn@deacon.udel.edu +2 -0 + Windows compiling hints/winnt.html update from G. Sunil Tej + + ChangeLog@1.626.1.1, 2010-05-11 02:30:34-04:00, stenn@deacon.udel.edu +1 -0 + Windows compiling hints/winnt.html update from G. Sunil Tej + + html/hints/winnt.html@1.20, 2010-05-11 02:30:34-04:00, stenn@deacon.udel.edu +13 -11 + Windows compiling hints/winnt.html update from G. Sunil Tej + +ChangeSet@1.2176, 2010-05-11 04:44:37+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + Add Nelson B Bolyard to html/copyright.html. + Update ChangeLog entries to reflect filing of [Bug 1552], [Bug 1553]. + + ChangeLog@1.630, 2010-05-11 04:44:35+00:00, davehart@shiny.ad.hartbrothers.com +2 -29 + Update ChangeLog entries to reflect filing of [Bug 1552], [Bug 1553]. + + html/copyright.html@1.47, 2010-05-11 04:44:36+00:00, davehart@shiny.ad.hartbrothers.com +4 -3 + Add Nelson B Bolyard to html/copyright.html. + +ChangeSet@1.2175, 2010-05-10 13:16:18+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + Simplify hash client code by providing OpenSSL EVP_*() API when built + without OpenSSL. (from ntp-dev) + Do not depend on ASCII values for ('A' - '0'), ('a' - '0') in sntp. + + ChangeLog@1.629, 2010-05-10 13:16:15+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + Simplify hash client code by providing OpenSSL EVP_*() API when built + without OpenSSL. (from ntp-dev) + Do not depend on ASCII values for ('A' - '0'), ('a' - '0') in sntp. + + include/ntp_md5.h@1.4, 2010-05-10 13:16:15+00:00, davehart@shiny.ad.hartbrothers.com +21 -5 + expose OpenSSL hash API even when building without OpenSSL, + to simplify client code. Backport from ntp-dev. + + libntp/a_md5encrypt.c@1.27, 2010-05-10 13:16:16+00:00, davehart@shiny.ad.hartbrothers.com +3 -38 + expose OpenSSL hash API even when building without OpenSSL, + to simplify client code. Backport from ntp-dev. + + sntp/crypto.c@1.12, 2010-05-10 13:16:16+00:00, davehart@shiny.ad.hartbrothers.com +34 -64 + remove s_keytype_from_text(), use similar keytype_from_text() from libntp. + + sntp/crypto.h@1.9, 2010-05-10 13:16:16+00:00, davehart@shiny.ad.hartbrothers.com +4 -7 + bring in line with other ntp_md5.h client code + + sntp/networking.c@1.34, 2010-05-10 13:16:16+00:00, davehart@shiny.ad.hartbrothers.com +15 -16 + Simplify hash client code by providing OpenSSL EVP_*() API when built + without OpenSSL. (from ntp-dev) + Do not depend on ASCII values for ('A' - '0'), ('a' - '0') in sntp. + +ChangeSet@1.2174, 2010-05-09 10:38:44+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + Correct ChangeLog spelling of Nelson Bolyard's name, add email address. + + ChangeLog@1.628, 2010-05-09 10:38:42+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + Correct ChangeLog spelling of Nelson Bolyard's name, add email address. + +ChangeSet@1.2173, 2010-05-09 08:12:20+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + cleanup prior changeset, ease -dev merge. + + ntpq/ntpq-subs.c@1.44, 2010-05-09 08:12:19+00:00, davehart@shiny.ad.hartbrothers.com +7 -7 + remove leftover of earlier approach, match AF_UNSPEC use to ntp-dev. + align with ntp-dev regarding empty refid= value from ntpd. + + ntpq/ntpq.c@1.100, 2010-05-09 08:12:19+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + use const qualifier for makeascii char *. + + ntpq/ntpq.h@1.12, 2010-05-09 08:12:19+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + use const qualifier for makeascii char *. + +ChangeSet@1.2172, 2010-05-09 06:33:09+00:00, davehart@shiny.ad.hartbrothers.com +13 -0 + [Bug 1325] unreachable code in sntp recv_bcst_data(). + [Bug 1459] sntp MD5 authentication does not work with ntpd. + Many sntp fixes from Nelson Boyard: + 1. sntp properly handles hex key strings in the keyfile, instead of + just treating the text as binary strings. + 2. sntp handles SHA1 as well as MD5. + 3. If the key file contains more than one key, sntp can use keys + other than the first one in the file. + 4. sntp computes the MAC using the key, then the data (was other way). + 5. sntp handles responses with extensions now. + 6. sntp implements the -b (broadcast/multicast) option. Tested. + The -b option takes an argument which is the broadcast/multicast + address on which to listen for packets. The command still requires a + host address at the end of the command line. This is the address + expected to do the broadcasting/multicasting. + 7. sntp correctly handles network-order key IDs on little-endian. + 8. Eliminated a huge amount of code duplication between the sntp + unicast and multicast code paths, creating a single process_pkt() + function that is used for both paths after the packet is received. + 9. The -t timeout option now works with both unicast and multicast. + Previously it worked with neither. It wasn't coded for unicast, and + was incorrectly coded for multicast. + 10. In unicast mode, the requests are sent MACed using the key + specified with the -a command line option. + 11. Cleaned up indentation consistent with the predominant style in + the files changed, namely, using tab stop characters and not spaces + for indentation. This way, you can set your tab stop spacing as you + like it and the indentation looks correct. This was not a big change. + The files were mostly consistent before. + 12. Eliminated LOTS of blank lines. + sntp/configure.ac OpenSSL support now that sntp optionally uses it. + Escape unprintable characters in a refid in ntpq -p billboard. + + ChangeLog@1.627, 2010-05-09 06:33:07+00:00, davehart@shiny.ad.hartbrothers.com +32 -0 + [Bug 1325] unreachable code in sntp recv_bcst_data(). + [Bug 1459] sntp MD5 authentication does not work with ntpd. + Many sntp fixes from Nelson Boyard: + 1. sntp properly handles hex key strings in the keyfile, instead of + just treating the text as binary strings. + 2. sntp handles SHA1 as well as MD5. + 3. If the key file contains more than one key, sntp can use keys + other than the first one in the file. + 4. sntp computes the MAC using the key, then the data (was other way). + 5. sntp handles responses with extensions now. + 6. sntp implements the -b (broadcast/multicast) option. Tested. + The -b option takes an argument which is the broadcast/multicast + address on which to listen for packets. The command still requires a + host address at the end of the command line. This is the address + expected to do the broadcasting/multicasting. + 7. sntp correctly handles network-order key IDs on little-endian. + 8. Eliminated a huge amount of code duplication between the sntp + unicast and multicast code paths, creating a single process_pkt() + function that is used for both paths after the packet is received. + 9. The -t timeout option now works with both unicast and multicast. + Previously it worked with neither. It wasn't coded for unicast, and + was incorrectly coded for multicast. + 10. In unicast mode, the requests are sent MACed using the key + specified with the -a command line option. + 11. Cleaned up indentation consistent with the predominant style in + the files changed, namely, using tab stop characters and not spaces + for indentation. This way, you can set your tab stop spacing as you + like it and the indentation looks correct. This was not a big change. + The files were mostly consistent before. + 12. Eliminated LOTS of blank lines. + sntp/configure.ac OpenSSL support now that sntp optionally uses it. + Escape unprintable characters in a refid in ntpq -p billboard. + + configure.ac@1.476, 2010-05-09 06:33:07+00:00, davehart@shiny.ad.hartbrothers.com +1 -175 + sntp/configure.ac OpenSSL support now that sntp optionally uses it. + + m4/ntp_openssl.m4@1.1, 2010-05-09 06:32:06+00:00, davehart@shiny.ad.hartbrothers.com +182 -0 + moved from configure.ac to include to share with sntp/configure.ac + + m4/ntp_openssl.m4@1.0, 2010-05-09 06:32:06+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ntpq/ntpq-subs.c@1.43, 2010-05-09 06:33:07+00:00, davehart@shiny.ad.hartbrothers.com +9 -3 + Escape unprintable characters in a refid in ntpq -p billboard. + + ntpq/ntpq.c@1.99, 2010-05-09 06:33:07+00:00, davehart@shiny.ad.hartbrothers.com +1 -2 + Escape unprintable characters in a refid in ntpq -p billboard. + + ntpq/ntpq.h@1.11, 2010-05-09 06:33:07+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + Escape unprintable characters in a refid in ntpq -p billboard. + + sntp/Makefile.am@1.29, 2010-05-09 06:33:07+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + add conditional -lcrypto to LDADD to link against OpenSSL. + + sntp/configure.ac@1.32, 2010-05-09 06:33:07+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + sntp/configure.ac OpenSSL support now that sntp optionally uses it. + + sntp/crypto.c@1.11, 2010-05-09 06:33:07+00:00, davehart@shiny.ad.hartbrothers.com +134 -69 + [Bug 1459] sntp MD5 authentication does not work with ntpd. + Many sntp fixes from Nelson Boyard: + 1. sntp properly handles hex key strings in the keyfile, instead of + just treating the text as binary strings. + 2. sntp handles SHA1 as well as MD5. + 3. If the key file contains more than one key, sntp can use keys + other than the first one in the file. + 4. sntp computes the MAC using the key, then the data (was other way). + 5. sntp handles responses with extensions now. + 6. sntp implements the -b (broadcast/multicast) option. Tested. + The -b option takes an argument which is the broadcast/multicast + address on which to listen for packets. The command still requires a + host address at the end of the command line. This is the address + expected to do the broadcasting/multicasting. + 7. sntp correctly handles network-order key IDs on little-endian. + 8. Eliminated a huge amount of code duplication between the sntp + unicast and multicast code paths, creating a single process_pkt() + function that is used for both paths after the packet is received. + 9. The -t timeout option now works with both unicast and multicast. + Previously it worked with neither. It wasn't coded for unicast, and + was incorrectly coded for multicast. + 10. In unicast mode, the requests are sent MACed using the key + specified with the -a command line option. + 11. Cleaned up indentation consistent with the predominant style in + the files changed, namely, using tab stop characters and not spaces + for indentation. This way, you can set your tab stop spacing as you + like it and the indentation looks correct. This was not a big change. + The files were mostly consistent before. + 12. Eliminated LOTS of blank lines. + - ChangeLog@1.80, 2009-05-08 01:23:41+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - [Bug 1179] error messages for -u/--user and -i when built w/o droproot + sntp/crypto.h@1.8, 2010-05-09 06:33:07+00:00, davehart@shiny.ad.hartbrothers.com +12 -6 + [Bug 1459] sntp MD5 authentication does not work with ntpd. + Many sntp fixes from Nelson Boyard: + 1. sntp properly handles hex key strings in the keyfile, instead of + just treating the text as binary strings. + 2. sntp handles SHA1 as well as MD5. + 3. If the key file contains more than one key, sntp can use keys + other than the first one in the file. + 4. sntp computes the MAC using the key, then the data (was other way). + 5. sntp handles responses with extensions now. + 6. sntp implements the -b (broadcast/multicast) option. Tested. + The -b option takes an argument which is the broadcast/multicast + address on which to listen for packets. The command still requires a + host address at the end of the command line. This is the address + expected to do the broadcasting/multicasting. + 7. sntp correctly handles network-order key IDs on little-endian. + 8. Eliminated a huge amount of code duplication between the sntp + unicast and multicast code paths, creating a single process_pkt() + function that is used for both paths after the packet is received. + 9. The -t timeout option now works with both unicast and multicast. + Previously it worked with neither. It wasn't coded for unicast, and + was incorrectly coded for multicast. + 10. In unicast mode, the requests are sent MACed using the key + specified with the -a command line option. + 11. Cleaned up indentation consistent with the predominant style in + the files changed, namely, using tab stop characters and not spaces + for indentation. This way, you can set your tab stop spacing as you + like it and the indentation looks correct. This was not a big change. + The files were mostly consistent before. + 12. Eliminated LOTS of blank lines. + - ntpd/cmd_args.c@1.49, 2009-05-08 01:23:41+00:00, davehart@shiny.ad.hartbrothers.com +39 -19 - descriptive error messages for -u/--user and -i without droproot + sntp/main.c@1.25, 2010-05-09 06:33:07+00:00, davehart@shiny.ad.hartbrothers.com +110 -103 + [Bug 1459] sntp MD5 authentication does not work with ntpd. + Many sntp fixes from Nelson Boyard: + 1. sntp properly handles hex key strings in the keyfile, instead of + just treating the text as binary strings. + 2. sntp handles SHA1 as well as MD5. + 3. If the key file contains more than one key, sntp can use keys + other than the first one in the file. + 4. sntp computes the MAC using the key, then the data (was other way). + 5. sntp handles responses with extensions now. + 6. sntp implements the -b (broadcast/multicast) option. Tested. + The -b option takes an argument which is the broadcast/multicast + address on which to listen for packets. The command still requires a + host address at the end of the command line. This is the address + expected to do the broadcasting/multicasting. + 7. sntp correctly handles network-order key IDs on little-endian. + 8. Eliminated a huge amount of code duplication between the sntp + unicast and multicast code paths, creating a single process_pkt() + function that is used for both paths after the packet is received. + 9. The -t timeout option now works with both unicast and multicast. + Previously it worked with neither. It wasn't coded for unicast, and + was incorrectly coded for multicast. + 10. In unicast mode, the requests are sent MACed using the key + specified with the -a command line option. + 11. Cleaned up indentation consistent with the predominant style in + the files changed, namely, using tab stop characters and not spaces + for indentation. This way, you can set your tab stop spacing as you + like it and the indentation looks correct. This was not a big change. + The files were mostly consistent before. + 12. Eliminated LOTS of blank lines. + -ChangeSet@1.1591, 2009-05-07 22:15:41+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - ntp_io.c: do not use FD_SET beyond FD_SETSIZE, watch for corruption of inter_list.head + sntp/networking.c@1.33, 2010-05-09 06:33:08+00:00, davehart@shiny.ad.hartbrothers.com +216 -432 + [Bug 1325] unreachable code in sntp recv_bcst_data(). + [Bug 1459] sntp MD5 authentication does not work with ntpd. + Many sntp fixes from Nelson Boyard: + 1. sntp properly handles hex key strings in the keyfile, instead of + just treating the text as binary strings. + 2. sntp handles SHA1 as well as MD5. + 3. If the key file contains more than one key, sntp can use keys + other than the first one in the file. + 4. sntp computes the MAC using the key, then the data (was other way). + 5. sntp handles responses with extensions now. + 6. sntp implements the -b (broadcast/multicast) option. Tested. + The -b option takes an argument which is the broadcast/multicast + address on which to listen for packets. The command still requires a + host address at the end of the command line. This is the address + expected to do the broadcasting/multicasting. + 7. sntp correctly handles network-order key IDs on little-endian. + 8. Eliminated a huge amount of code duplication between the sntp + unicast and multicast code paths, creating a single process_pkt() + function that is used for both paths after the packet is received. + 9. The -t timeout option now works with both unicast and multicast. + Previously it worked with neither. It wasn't coded for unicast, and + was incorrectly coded for multicast. + 10. In unicast mode, the requests are sent MACed using the key + specified with the -a command line option. + 11. Cleaned up indentation consistent with the predominant style in + the files changed, namely, using tab stop characters and not spaces + for indentation. This way, you can set your tab stop spacing as you + like it and the indentation looks correct. This was not a big change. + The files were mostly consistent before. + 12. Eliminated LOTS of blank lines. + - ChangeLog@1.79, 2009-05-07 22:15:39+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 - do not use FD_SET beyond FD_SETSIZE, watch for corruption of inter_list.head + sntp/networking.h@1.18, 2010-05-09 06:33:08+00:00, davehart@shiny.ad.hartbrothers.com +3 -3 + [Bug 1459] sntp MD5 authentication does not work with ntpd. + Many sntp fixes from Nelson Boyard: + 1. sntp properly handles hex key strings in the keyfile, instead of + just treating the text as binary strings. + 2. sntp handles SHA1 as well as MD5. + 3. If the key file contains more than one key, sntp can use keys + other than the first one in the file. + 4. sntp computes the MAC using the key, then the data (was other way). + 5. sntp handles responses with extensions now. + 6. sntp implements the -b (broadcast/multicast) option. Tested. + The -b option takes an argument which is the broadcast/multicast + address on which to listen for packets. The command still requires a + host address at the end of the command line. This is the address + expected to do the broadcasting/multicasting. + 7. sntp correctly handles network-order key IDs on little-endian. + 8. Eliminated a huge amount of code duplication between the sntp + unicast and multicast code paths, creating a single process_pkt() + function that is used for both paths after the packet is received. + 9. The -t timeout option now works with both unicast and multicast. + Previously it worked with neither. It wasn't coded for unicast, and + was incorrectly coded for multicast. + 10. In unicast mode, the requests are sent MACed using the key + specified with the -a command line option. + 11. Cleaned up indentation consistent with the predominant style in + the files changed, namely, using tab stop characters and not spaces + for indentation. This way, you can set your tab stop spacing as you + like it and the indentation looks correct. This was not a big change. + The files were mostly consistent before. + 12. Eliminated LOTS of blank lines. + - ntpd/ntp_io.c@1.260, 2009-05-07 22:15:39+00:00, davehart@shiny.ad.hartbrothers.com +23 -0 - do not use FD_SET beyond FD_SETSIZE, watch for corruption of inter_list.head +ChangeSet@1.2171, 2010-05-03 04:35:06-04:00, stenn@deacon.udel.edu +2 -0 + [Bug 1541] Fix wrong keyword for "maxclock". -ChangeSet@1.1590, 2009-05-07 07:39:41+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - refclock_jjy.c: - add missing newline before EOF + ChangeLog@1.626, 2010-05-03 04:34:54-04:00, stenn@deacon.udel.edu +1 -0 + [Bug 1541] Fix wrong keyword for "maxclock". - ntpd/refclock_jjy.c@1.15, 2009-05-07 07:39:32+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 - add missing newline before EOF + html/decode.html@1.13, 2010-05-03 04:34:54-04:00, stenn@deacon.udel.edu +2 -2 + [Bug 1541] Fix wrong keyword for "maxclock". -ChangeSet@1.1589, 2009-05-07 05:19:36+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 - [Bug 784] Make --enable-linuxcaps the default when available - add reference to refclock_jjy.c to ports/winnt/ntpd/ntpd.vcproj +ChangeSet@1.2170, 2010-04-30 09:03:12+00:00, stenn@psp-fb1.ntp.org +7 -0 + [Bug 1512] ntpsnmpd should connect to net-snmpd via a unix-domain socket by default. Provide a command-line 'socket name' option. - ChangeLog@1.78, 2009-05-07 05:19:34+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - [Bug 784] Make --enable-linuxcaps the default when available + ChangeLog@1.625, 2010-04-30 08:59:54+00:00, stenn@psp-fb1.ntp.org +2 -0 + [Bug 1512] ntpsnmpd should connect to net-snmpd via a unix-domain socket by default. Provide a command-line 'socket name' option. - configure.ac@1.415, 2009-05-07 05:19:34+00:00, davehart@shiny.ad.hartbrothers.com +34 -33 - [Bug 784] Make --enable-linuxcaps the default when available + ntpsnmpd/ntpsnmpd-opts.c@1.133, 2010-04-30 09:01:30+00:00, stenn@psp-fb1.ntp.org +29 -6 + [Bug 1512] ntpsnmpd should connect to net-snmpd via a unix-domain socket by default. Provide a command-line 'socket name' option. - ports/winnt/ntpd/ntpd.vcproj@1.2, 2009-05-07 05:19:34+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 - add reference to refclock_jjy.c to ports/winnt/ntpd/ntpd.vcproj + ntpsnmpd/ntpsnmpd-opts.def@1.2, 2010-04-30 09:01:30+00:00, stenn@psp-fb1.ntp.org +12 -0 + [Bug 1512] ntpsnmpd should connect to net-snmpd via a unix-domain socket by default. Provide a command-line 'socket name' option. -ChangeSet@1.1588, 2009-05-07 05:10:54+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 - Updated JJY reference clock driver from Takao abe - Make ntpd the default project in Visual C++/Visual Studio + ntpsnmpd/ntpsnmpd-opts.h@1.133, 2010-04-30 09:01:30+00:00, stenn@psp-fb1.ntp.org +17 -10 + [Bug 1512] ntpsnmpd should connect to net-snmpd via a unix-domain socket by default. Provide a command-line 'socket name' option. - ChangeLog@1.77, 2009-05-07 05:10:52+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 - Updated JJY reference clock driver from Takao abe + ntpsnmpd/ntpsnmpd-opts.texi@1.133, 2010-04-30 09:01:30+00:00, stenn@psp-fb1.ntp.org +33 -2 + [Bug 1512] ntpsnmpd should connect to net-snmpd via a unix-domain socket by default. Provide a command-line 'socket name' option. - html/drivers/driver40.html@1.14, 2009-05-07 05:10:52+00:00, davehart@shiny.ad.hartbrothers.com +103 -48 - Updated JJY reference clock driver from Takao abe + ntpsnmpd/ntpsnmpd.1@1.132, 2010-04-30 09:01:30+00:00, stenn@psp-fb1.ntp.org +11 -2 + [Bug 1512] ntpsnmpd should connect to net-snmpd via a unix-domain socket by default. Provide a command-line 'socket name' option. - ntpd/refclock_jjy.c@1.14, 2009-05-07 05:10:52+00:00, davehart@shiny.ad.hartbrothers.com +153 -5 - Updated JJY reference clock driver from Takao abe + ntpsnmpd/ntpsnmpd.c@1.4, 2010-04-30 09:01:30+00:00, stenn@psp-fb1.ntp.org +1 -1 + [Bug 1512] ntpsnmpd should connect to net-snmpd via a unix-domain socket by default. Provide a command-line 'socket name' option. - ports/winnt/ntp.sln@1.2, 2009-05-07 05:10:53+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 - Make ntpd the default project in Visual C++/Visual Studio +ChangeSet@1.2169, 2010-04-30 08:54:29+00:00, stenn@psp-fb1.ntp.org +2 -0 + [Bug 1538] update refclock_nmea.c's call to getprotobyname() -ChangeSet@1.1587, 2009-05-02 02:38:49-04:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P7_RC5 - TAG: NTP_4_2_4P7_RC5 + ChangeLog@1.624, 2010-04-30 08:53:42+00:00, stenn@psp-fb1.ntp.org +6 -0 + [Bug 1538] update refclock_nmea.c's call to getprotobyname() - ChangeLog@1.76, 2009-05-02 02:38:22-04:00, stenn@whimsy.udel.edu +1 -0 - NTP_4_2_4P7_RC5 + ntpd/refclock_nmea.c@1.47, 2010-04-30 08:53:58+00:00, stenn@psp-fb1.ntp.org +1 -1 + [Bug 1538] update refclock_nmea.c's call to getprotobyname() - ntpd/ntpd-opts.c@1.81, 2009-05-02 02:38:24-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 +ChangeSet@1.2168, 2010-04-27 02:53:34-04:00, stenn@deacon.udel.edu +27 -0 + NTP_4_2_6P2_RC2 + TAG: NTP_4_2_6P2_RC2 - ntpd/ntpd-opts.h@1.81, 2009-05-02 02:38:25-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC5 + ChangeLog@1.623, 2010-04-27 02:53:31-04:00, stenn@deacon.udel.edu +1 -0 + NTP_4_2_6P2_RC2 - ntpd/ntpd-opts.texi@1.80, 2009-05-02 02:38:27-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC5 + ntpd/ntpd-opts.c@1.257, 2010-04-27 02:53:31-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC2 - ntpd/ntpd.1@1.79, 2009-05-02 02:38:28-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 + ntpd/ntpd-opts.h@1.257, 2010-04-27 02:53:31-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC2 - ntpd/ntpdsim-opts.c@1.81, 2009-05-02 02:38:28-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 + ntpd/ntpd-opts.texi@1.255, 2010-04-27 02:53:31-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC2 - ntpd/ntpdsim-opts.h@1.81, 2009-05-02 02:38:29-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC5 + ntpd/ntpd.1@1.255, 2010-04-27 02:53:31-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC2 - ntpd/ntpdsim-opts.texi@1.79, 2009-05-02 02:38:30-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC5 + ntpdc/ntpdc-opts.c@1.253, 2010-04-27 02:53:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC2 - ntpd/ntpdsim.1@1.79, 2009-05-02 02:38:31-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 + ntpdc/ntpdc-opts.h@1.253, 2010-04-27 02:53:32-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC2 - ntpdc/ntpdc-opts.c@1.81, 2009-05-02 02:38:31-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 + ntpdc/ntpdc-opts.texi@1.252, 2010-04-27 02:53:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC2 - ntpdc/ntpdc-opts.h@1.81, 2009-05-02 02:38:32-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC5 + ntpdc/ntpdc.1@1.252, 2010-04-27 02:53:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC2 - ntpdc/ntpdc-opts.texi@1.79, 2009-05-02 02:38:33-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC5 + ntpq/ntpq-opts.c@1.254, 2010-04-27 02:53:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC2 - ntpdc/ntpdc.1@1.79, 2009-05-02 02:38:33-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 + ntpq/ntpq-opts.h@1.254, 2010-04-27 02:53:32-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC2 - ntpq/ntpq-opts.c@1.83, 2009-05-02 02:38:34-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 + ntpq/ntpq-opts.texi@1.253, 2010-04-27 02:53:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC2 - ntpq/ntpq-opts.h@1.83, 2009-05-02 02:38:35-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC5 + ntpq/ntpq.1@1.253, 2010-04-27 02:53:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC2 - ntpq/ntpq-opts.texi@1.80, 2009-05-02 02:38:36-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC5 + ntpsnmpd/ntpsnmpd-opts.c@1.132, 2010-04-27 02:53:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC2 - ntpq/ntpq.1@1.79, 2009-05-02 02:38:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 + ntpsnmpd/ntpsnmpd-opts.h@1.132, 2010-04-27 02:53:32-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC2 - packageinfo.sh@1.111, 2009-05-02 02:38:38-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC5 + ntpsnmpd/ntpsnmpd-opts.texi@1.132, 2010-04-27 02:53:32-04:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P2_RC2 - sntp/sntp-opts.c@1.79, 2009-05-02 02:38:39-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 + ntpsnmpd/ntpsnmpd.1@1.131, 2010-04-27 02:53:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC2 - sntp/sntp-opts.h@1.79, 2009-05-02 02:38:40-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC5 + packageinfo.sh@1.270, 2010-04-27 02:53:32-04:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P2_RC2 - sntp/sntp-opts.texi@1.76, 2009-05-02 02:38:41-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC5 + sntp/sntp-opts.c@1.126, 2010-04-27 02:53:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC2 - sntp/sntp.1@1.79, 2009-05-02 02:38:42-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 + sntp/sntp-opts.h@1.126, 2010-04-27 02:53:32-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC2 - util/ntp-keygen-opts.c@1.80, 2009-05-02 02:38:43-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 + sntp/sntp-opts.texi@1.126, 2010-04-27 02:53:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC2 - util/ntp-keygen-opts.h@1.80, 2009-05-02 02:38:43-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC5 + sntp/sntp.1@1.126, 2010-04-27 02:53:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC2 - util/ntp-keygen-opts.texi@1.78, 2009-05-02 02:38:44-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC5 + sntp/sntp.html@1.16, 2010-04-27 02:53:32-04:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P2_RC2 - util/ntp-keygen.1@1.78, 2009-05-02 02:38:45-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 + util/ntp-keygen-opts.c@1.256, 2010-04-27 02:53:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC2 -ChangeSet@1.1586, 2009-05-02 01:49:02+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 - flock-build: - set -m wasn't needed with ssh -tt and caused problems, remove - ChangeLog: - [Bug 1172] 4.2.4p7-RC{3,4} fail to build on linux. - remove unportable 'set -m' from flock-build script - configure.ac: - reverse accidental backport from -dev of struct rtattr test in - configure.ac without corresponding ntp_io.c code for HAVE_RTNETLINK + util/ntp-keygen-opts.h@1.256, 2010-04-27 02:53:32-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC2 - ChangeLog@1.75, 2009-05-02 01:48:30+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 - [Bug 1172] 4.2.4p7-RC{3,4} fail to build on linux. - remove unportable 'set -m' from flock-build script + util/ntp-keygen-opts.texi@1.255, 2010-04-27 02:53:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC2 - configure.ac@1.414, 2009-05-02 01:48:30+00:00, davehart@shiny.ad.hartbrothers.com +1 -12 - reverse accidental backport from -dev of struct rtattr test in - configure.ac without corresponding ntp_io.c code for HAVE_RTNETLINK + util/ntp-keygen.1@1.255, 2010-04-27 02:53:33-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC2 - flock-build@1.41, 2009-05-02 01:48:30+00:00, davehart@shiny.ad.hartbrothers.com +3 -5 - set -m wasn't needed with ssh -tt and caused problems, remove +ChangeSet@1.2167, 2010-04-24 05:57:35+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1534] win32/include/isc/net.h conflicts with VC++ 2010 errno.h. + [Bug 1535] "restrict -4 default" and "restrict -6 default" ignored. -ChangeSet@1.1585, 2009-04-29 04:03:41-04:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P7_RC4 - TAG: NTP_4_2_4P7_RC4 + ChangeLog@1.622, 2010-04-24 05:57:34+00:00, davehart@shiny.ad.hartbrothers.com +4 -1 + [Bug 1534] win32/include/isc/net.h conflicts with VC++ 2010 errno.h. + [Bug 1535] "restrict -4 default" and "restrict -6 default" ignored. - ChangeLog@1.74, 2009-04-29 04:03:17-04:00, stenn@whimsy.udel.edu +1 -0 - NTP_4_2_4P7_RC4 + lib/isc/win32/include/isc/net.h@1.10, 2010-04-24 05:57:34+00:00, davehart@shiny.ad.hartbrothers.com +30 -0 + [Bug 1534] win32/include/isc/net.h conflicts with VC++ 2010 errno.h. - ntpd/ntpd-opts.c@1.80, 2009-04-29 04:03:18-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 + ntpd/ntp_parser.c@1.54, 2010-04-24 05:57:34+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + Bison output from ntp_parser.y - ntpd/ntpd-opts.h@1.80, 2009-04-29 04:03:19-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC4 + ntpd/ntp_parser.y@1.49, 2010-04-24 05:57:35+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + [Bug 1535] "restrict -4 default" and "restrict -6 default" ignored. - ntpd/ntpd-opts.texi@1.79, 2009-04-29 04:03:21-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC4 +ChangeSet@1.2166, 2010-04-20 01:55:16-04:00, stenn@deacon.udel.edu +2 -0 + [Bug 1465] Make sure time from TS2100 is not invalid (backport from -dev) - ntpd/ntpd.1@1.78, 2009-04-29 04:03:21-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 + ChangeLog@1.621, 2010-04-20 01:55:04-04:00, stenn@deacon.udel.edu +1 -0 + [Bug 1465] Make sure time from TS2100 is not invalid (backport from -dev) - ntpd/ntpdsim-opts.c@1.80, 2009-04-29 04:03:22-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 + ntpd/refclock_true.c@1.12, 2010-04-20 01:55:05-04:00, stenn@deacon.udel.edu +2 -1 + [Bug 1465] Make sure time from TS2100 is not invalid (backport from -dev) - ntpd/ntpdsim-opts.h@1.80, 2009-04-29 04:03:22-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC4 +ChangeSet@1.2165, 2010-04-20 01:45:17-04:00, stenn@deacon.udel.edu +3 -0 + [Bug 1528] Fix EDITLINE_LIBS link order for ntpq and ntpdc - ntpd/ntpdsim-opts.texi@1.78, 2009-04-29 04:03:24-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC4 + ChangeLog@1.620, 2010-04-20 01:44:57-04:00, stenn@deacon.udel.edu +1 -0 + [Bug 1528] Fix EDITLINE_LIBS link order for ntpq and ntpdc - ntpd/ntpdsim.1@1.78, 2009-04-29 04:03:25-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 + ntpdc/Makefile.am@1.52, 2010-04-20 01:44:57-04:00, stenn@deacon.udel.edu +2 -2 + [Bug 1528] Fix EDITLINE_LIBS link order for ntpq and ntpdc - ntpdc/ntpdc-opts.c@1.80, 2009-04-29 04:03:25-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 + ntpq/Makefile.am@1.47, 2010-04-20 01:44:57-04:00, stenn@deacon.udel.edu +2 -2 + [Bug 1528] Fix EDITLINE_LIBS link order for ntpq and ntpdc - ntpdc/ntpdc-opts.h@1.80, 2009-04-29 04:03:26-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC4 +ChangeSet@1.2164, 2010-04-20 01:30:11-04:00, stenn@deacon.udel.edu +2 -0 + Remove --with-arlib from br-flock - ntpdc/ntpdc-opts.texi@1.78, 2009-04-29 04:03:27-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC4 + ChangeLog@1.619, 2010-04-20 01:29:44-04:00, stenn@deacon.udel.edu +2 -0 + Remove --with-arlib from br-flock - ntpdc/ntpdc.1@1.78, 2009-04-29 04:03:28-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 + br-flock@1.14, 2010-04-20 01:29:44-04:00, stenn@deacon.udel.edu +1 -1 + Remove --with-arlib from br-flock - ntpq/ntpq-opts.c@1.82, 2009-04-29 04:03:29-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 +ChangeSet@1.2163, 2010-04-18 04:14:33-04:00, stenn@deacon.udel.edu +27 -0 + NTP_4_2_6P2_RC1 + TAG: NTP_4_2_6P2_RC1 - ntpq/ntpq-opts.h@1.82, 2009-04-29 04:03:29-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC4 + ChangeLog@1.618, 2010-04-18 04:14:31-04:00, stenn@deacon.udel.edu +1 -0 + NTP_4_2_6P2_RC1 - ntpq/ntpq-opts.texi@1.79, 2009-04-29 04:03:30-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC4 + ntpd/ntpd-opts.c@1.256, 2010-04-18 04:14:31-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC1 - ntpq/ntpq.1@1.78, 2009-04-29 04:03:31-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 + ntpd/ntpd-opts.h@1.256, 2010-04-18 04:14:31-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC1 - packageinfo.sh@1.110, 2009-04-29 04:03:31-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC4 + ntpd/ntpd-opts.texi@1.254, 2010-04-18 04:14:31-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC1 - sntp/sntp-opts.c@1.78, 2009-04-29 04:03:32-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 + ntpd/ntpd.1@1.254, 2010-04-18 04:14:31-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC1 - sntp/sntp-opts.h@1.78, 2009-04-29 04:03:33-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC4 + ntpdc/ntpdc-opts.c@1.252, 2010-04-18 04:14:31-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC1 - sntp/sntp-opts.texi@1.75, 2009-04-29 04:03:34-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC4 + ntpdc/ntpdc-opts.h@1.252, 2010-04-18 04:14:31-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC1 - sntp/sntp.1@1.78, 2009-04-29 04:03:35-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 + ntpdc/ntpdc-opts.texi@1.251, 2010-04-18 04:14:31-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC1 - util/ntp-keygen-opts.c@1.79, 2009-04-29 04:03:36-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 + ntpdc/ntpdc.1@1.251, 2010-04-18 04:14:31-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC1 - util/ntp-keygen-opts.h@1.79, 2009-04-29 04:03:36-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC4 + ntpq/ntpq-opts.c@1.253, 2010-04-18 04:14:31-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC1 - util/ntp-keygen-opts.texi@1.77, 2009-04-29 04:03:36-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC4 + ntpq/ntpq-opts.h@1.253, 2010-04-18 04:14:31-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC1 - util/ntp-keygen.1@1.77, 2009-04-29 04:03:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 + ntpq/ntpq-opts.texi@1.252, 2010-04-18 04:14:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC1 -ChangeSet@1.1584, 2009-04-29 01:50:44-04:00, stenn@pogo.udel.edu +1 -0 - No need to know the GCC -W items in config.h + ntpq/ntpq.1@1.252, 2010-04-18 04:14:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC1 - configure.ac@1.413, 2009-04-29 01:50:36-04:00, stenn@pogo.udel.edu +2 -12 - No need to know the GCC -W items in config.h + ntpsnmpd/ntpsnmpd-opts.c@1.131, 2010-04-18 04:14:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC1 -ChangeSet@1.1583, 2009-04-27 11:47:49+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - ChangeLog: - add [Bug 1167] to ChangeLog entry + ntpsnmpd/ntpsnmpd-opts.h@1.131, 2010-04-18 04:14:32-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC1 - ChangeLog@1.73, 2009-04-27 11:47:36+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 - add [Bug 1167] to ChangeLog entry + ntpsnmpd/ntpsnmpd-opts.texi@1.131, 2010-04-18 04:14:32-04:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P2_RC1 -ChangeSet@1.1582, 2009-04-26 06:10:27+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - gcc -Winit-self is used only if it is understood + ntpsnmpd/ntpsnmpd.1@1.130, 2010-04-18 04:14:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC1 - ChangeLog@1.72, 2009-04-26 06:10:25+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 - gcc -Winit-self is used only if it is understood + packageinfo.sh@1.269, 2010-04-18 04:14:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC1 - configure.ac@1.412, 2009-04-26 06:10:26+00:00, davehart@shiny.ad.hartbrothers.com +34 -2 - gcc -Winit-self is used only if it is understood + sntp/sntp-opts.c@1.125, 2010-04-18 04:14:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC1 -ChangeSet@1.1581, 2009-04-22 08:18:29-04:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P7_RC3 - TAG: NTP_4_2_4P7_RC3 + sntp/sntp-opts.h@1.125, 2010-04-18 04:14:32-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC1 - ChangeLog@1.71, 2009-04-22 08:18:04-04:00, stenn@whimsy.udel.edu +1 -0 - NTP_4_2_4P7_RC3 + sntp/sntp-opts.texi@1.125, 2010-04-18 04:14:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC1 - ntpd/ntpd-opts.c@1.79, 2009-04-22 08:18:04-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + sntp/sntp.1@1.125, 2010-04-18 04:14:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC1 - ntpd/ntpd-opts.h@1.79, 2009-04-22 08:18:05-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC3 + sntp/sntp.html@1.15, 2010-04-18 04:14:32-04:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P2_RC1 - ntpd/ntpd-opts.texi@1.78, 2009-04-22 08:18:05-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + util/ntp-keygen-opts.c@1.255, 2010-04-18 04:14:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC1 - ntpd/ntpd.1@1.77, 2009-04-22 08:18:07-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + util/ntp-keygen-opts.h@1.255, 2010-04-18 04:14:32-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P2_RC1 - ntpd/ntpdsim-opts.c@1.79, 2009-04-22 08:18:08-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + util/ntp-keygen-opts.texi@1.254, 2010-04-18 04:14:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC1 - ntpd/ntpdsim-opts.h@1.79, 2009-04-22 08:18:08-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC3 + util/ntp-keygen.1@1.254, 2010-04-18 04:14:32-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P2_RC1 - ntpd/ntpdsim-opts.texi@1.77, 2009-04-22 08:18:09-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC3 +ChangeSet@1.2162, 2010-04-18 03:57:37-04:00, stenn@deacon.udel.edu +1 -0 + 4.2.6p2-RC1 - ntpd/ntpdsim.1@1.77, 2009-04-22 08:18:10-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + packageinfo.sh@1.268, 2010-04-18 03:57:30-04:00, stenn@deacon.udel.edu +1 -1 + 4.2.6p2-RC1 - ntpdc/ntpdc-opts.c@1.79, 2009-04-22 08:18:11-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 +ChangeSet@1.2161, 2010-04-16 13:59:44+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + fix backport (should have copied and pasted from -dev). - ntpdc/ntpdc-opts.h@1.79, 2009-04-22 08:18:11-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC3 + sntp/networking.c@1.32, 2010-04-16 13:59:43+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + fix backport (should have copied and pasted from -dev). - ntpdc/ntpdc-opts.texi@1.77, 2009-04-22 08:18:12-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 +ChangeSet@1.2158, 2010-04-14 21:16:25+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1518] Windows ntpd should lock to one processor more + conservatively. + - ntpdc/ntpdc.1@1.77, 2009-04-22 08:18:13-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + ChangeLog@1.613.2.1, 2010-04-14 21:16:25+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + [Bug 1518] Windows ntpd should lock to one processor more + conservatively. + + applies to previous changeset, deferred to ease pulling the + prior changeset into -dev ahead of -stable. - ntpq/ntpq-opts.c@1.81, 2009-04-22 08:18:13-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 +ChangeSet@1.2156.2.2, 2010-04-14 20:55:27+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1522] Enable range syntax "trustedkey (301 ... 399)". + Update html/authopt.html controlkey, requestkey, and trustedkey docs. + + ChangeLog@1.613.1.1, 2010-04-14 20:55:26+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + [Bug 1522] Enable range syntax "trustedkey (301 ... 399)". + Update html/authopt.html controlkey, requestkey, and trustedkey docs. + + The first entry applies to the prior changeset, which intentionally + lacked a ChangeLog entry to smooth pulling into -dev before -stable. - ntpq/ntpq-opts.h@1.81, 2009-04-22 08:18:14-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC3 + html/authopt.html@1.60, 2010-04-14 20:55:26+00:00, davehart@shiny.ad.hartbrothers.com +29 -7 + Update html/authopt.html controlkey, requestkey, and trustedkey docs, + add range syntax to trustedkey docs. + - ntpq/ntpq-opts.texi@1.78, 2009-04-22 08:18:15-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 +ChangeSet@1.2156.1.3, 2010-04-14 04:44:52+00:00, davehart@shiny.ad.hartbrothers.com +13 -0 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. + [Bug 1504] ntpdate tickles ntpd "discard minimum 1" rate limit if + "restrict ... limited" is used. - ntpq/ntpq.1@1.77, 2009-04-22 08:18:16-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + ChangeLog@1.615, 2010-04-14 04:44:51+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. + [Bug 1504] ntpdate tickles ntpd "discard minimum 1" rate limit if + "restrict ... limited" is used. - packageinfo.sh@1.109, 2009-04-22 08:18:17-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC3 + include/ntp.h@1.169, 2010-04-14 04:44:51+00:00, davehart@shiny.ad.hartbrothers.com +25 -16 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. - sntp/sntp-opts.c@1.77, 2009-04-22 08:18:19-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + include/ntp_lists.h@1.2, 2010-04-14 04:44:51+00:00, davehart@shiny.ad.hartbrothers.com +163 -10 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. - sntp/sntp-opts.h@1.77, 2009-04-22 08:18:20-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC3 + include/ntp_net.h@1.4, 2010-04-14 04:44:51+00:00, davehart@shiny.ad.hartbrothers.com +34 -13 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. - sntp/sntp-opts.texi@1.74, 2009-04-22 08:18:20-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC3 + include/ntpd.h@1.138, 2010-04-14 04:44:51+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. - sntp/sntp.1@1.77, 2009-04-22 08:18:22-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + ntpd/ntp_io.c@1.310, 2010-04-14 04:44:51+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. - util/ntp-keygen-opts.c@1.78, 2009-04-22 08:18:23-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + ntpd/ntp_monitor.c@1.26, 2010-04-14 04:44:51+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. - util/ntp-keygen-opts.h@1.78, 2009-04-22 08:18:23-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC3 + ntpd/ntp_request.c@1.83, 2010-04-14 04:44:51+00:00, davehart@shiny.ad.hartbrothers.com +72 -37 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. - util/ntp-keygen-opts.texi@1.76, 2009-04-22 08:18:25-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + ntpd/ntp_restrict.c@1.28, 2010-04-14 04:44:51+00:00, davehart@shiny.ad.hartbrothers.com +448 -429 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. - util/ntp-keygen.1@1.76, 2009-04-22 08:18:25-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + ntpdate/ntpdate.c@1.70, 2010-04-14 04:44:51+00:00, davehart@shiny.ad.hartbrothers.com +63 -55 + [Bug 1504] ntpdate tickles ntpd "discard minimum 1" rate limit if + "restrict ... limited" is used. -ChangeSet@1.1580, 2009-04-22 07:00:20-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 1155] Fix compile problem on Windows with VS2005 + ntpdate/ntpdate.h@1.11, 2010-04-14 04:44:51+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + [Bug 1504] ntpdate tickles ntpd "discard minimum 1" rate limit if + "restrict ... limited" is used. - ChangeLog@1.70, 2009-04-22 07:00:11-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 1155] Fix compile problem on Windows with VS2005 + ntpdc/ntpdc_ops.c@1.63, 2010-04-14 04:44:51+00:00, davehart@shiny.ad.hartbrothers.com +3 -3 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. -ChangeSet@1.1579, 2009-04-22 06:06:53-04:00, stenn@whimsy.udel.edu +1 -0 - Cleanup + sntp/networking.c@1.31, 2010-04-14 04:44:51+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. - ChangeLog@1.69, 2009-04-22 06:06:44-04:00, stenn@whimsy.udel.edu +4 -2 - Cleanup +ChangeSet@1.2156.2.1, 2010-04-10 02:26:43+00:00, davehart@shiny.ad.hartbrothers.com +10 -0 + [Bug 1522] Enable range syntax "trustedkey (301 ... 399)". -ChangeSet@1.1578, 2009-04-20 22:55:13+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - ChangeLog: - auto merge not quite right + include/ntp_config.h@1.68, 2010-04-10 02:26:37+00:00, davehart@shiny.ad.hartbrothers.com +7 -5 + add u_int u to attr_val.value union. - ChangeLog@1.68, 2009-04-20 22:55:10+00:00, davehart@shiny.ad.hartbrothers.com +3 -7 - auto merge not quite right + include/ntp_stdlib.h@1.41, 2010-04-10 02:26:37+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + add extern ref to int cache_key from authkeys.c -ChangeSet@1.1577, 2009-04-20 22:42:59+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - ntp_iocompletionport.c: - revert overlooked CreateEvent naming/sharing change not conditionalized away already + ntpd/complete.conf@1.4, 2010-04-10 02:26:38+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + add key ranges to trustedkey - ports/winnt/ntpd/ntp_iocompletionport.c@1.32, 2009-04-20 22:42:50+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 - revert overlooked CreateEvent naming/sharing change not conditionalized away already + ntpd/keyword-gen-utd@1.2, 2010-04-10 02:26:38+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + to indicate ntp_keyword.h is current with keyword-gen.c -ChangeSet@1.1567.1.11, 2009-04-20 06:17:21+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - ChangeLog: - [Bug 1160] Mac OS X is like BSD regarding F_SETOWN + ntpd/keyword-gen.c@1.6, 2010-04-10 02:26:38+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + add T_Ellipsis "..." for + trustedkey (1...65533) 65534 + syntax support. - ChangeLog@1.64.1.3, 2009-04-20 06:17:15+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - [Bug 1160] Mac OS X is like BSD regarding F_SETOWN + ntpd/ntp_config.c@1.244, 2010-04-10 02:26:39+00:00, davehart@shiny.ad.hartbrothers.com +45 -14 + support key ranges for trustedkey -ChangeSet@1.1567.1.10, 2009-04-20 06:02:20+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - configure.ac: - [Bug 1160] MacOS X is like BSD regarding F_SETOWN + ntpd/ntp_keyword.h@1.4, 2010-04-10 02:26:39+00:00, davehart@shiny.ad.hartbrothers.com +848 -844 + add "..." T_Ellipsis - configure.ac@1.411, 2009-04-20 06:02:08+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 - [Bug 1160] MacOS X is like BSD regarding F_SETOWN + ntpd/ntp_parser.c@1.53, 2010-04-10 02:26:40+00:00, davehart@shiny.ad.hartbrothers.com +918 -894 + Bison output -ChangeSet@1.1567.1.9, 2009-04-16 02:39:01+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - configure.ac: - fix for --enable-ntp-signd=/my/path + ntpd/ntp_parser.h@1.33, 2010-04-10 02:26:41+00:00, davehart@shiny.ad.hartbrothers.com +265 -263 + Bison output - configure.ac@1.410, 2009-04-16 02:38:53+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 - fix for --enable-ntp-signd=/my/path + ntpd/ntp_parser.y@1.48, 2010-04-10 02:26:41+00:00, davehart@shiny.ad.hartbrothers.com +23 -1 + support key ranges for trustedkey -ChangeSet@1.1567.1.8, 2009-04-15 12:36:24+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - configure.ac: - do not cache options fix +ChangeSet@1.2156.1.2, 2010-04-09 08:15:04+00:00, stenn@deacon.udel.edu +27 -0 + NTP_4_2_6P1 + TAG: NTP_4_2_6P1 - configure.ac@1.409, 2009-04-15 12:36:12+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 - do not cache options fix + ChangeLog@1.614, 2010-04-09 08:15:02+00:00, stenn@deacon.udel.edu +1 -0 + NTP_4_2_6P1 -ChangeSet@1.1567.1.7, 2009-04-15 10:43:51+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - configure.ac: - Do not cache configure --options, only current values matter - Default --enable-wintime when --enable-ntp-signd + ntpd/ntpd-opts.c@1.255, 2010-04-09 08:15:02+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1 - configure.ac@1.408, 2009-04-15 10:43:32+00:00, davehart@shiny.ad.hartbrothers.com +575 -403 - Do not cache configure --options, only current values matter - Default --enable-wintime when --enable-ntp-signd + ntpd/ntpd-opts.h@1.255, 2010-04-09 08:15:02+00:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P1 -ChangeSet@1.1567.1.6, 2009-04-15 01:32:33+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - use AC_SEARCH_LIBS to avoid problems with sntp + ntpd/ntpd-opts.texi@1.253, 2010-04-09 08:15:02+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1 - configure.ac@1.407, 2009-04-15 01:30:56+00:00, davehart@shiny.ad.hartbrothers.com +12 -20 - use AC_SEARCH_LIBS in preference to AC_CHECK_LIB particulary for sockets, use AM_PROG_CC_C_O which supersets prior AC_PROG_CC_C_O + ntpd/ntpd.1@1.253, 2010-04-09 08:15:02+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1 - sntp/configure.ac@1.17, 2009-04-15 01:28:22+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 - use AC_SEARCH_LIBS which is recommended particularly for sockets over the older AC_CHECK_LIB + ntpdc/ntpdc-opts.c@1.251, 2010-04-09 08:15:02+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1 -ChangeSet@1.1567.1.5, 2009-04-14 13:47:29+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - configure.ac: - tear off sntp/configure.ac from configure.ac + ntpdc/ntpdc-opts.h@1.251, 2010-04-09 08:15:02+00:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P1 - configure.ac@1.406, 2009-04-14 13:46:17+00:00, davehart@shiny.ad.hartbrothers.com +6 -1 - tear off sntp/configure.ac from configure.ac + ntpdc/ntpdc-opts.texi@1.250, 2010-04-09 08:15:02+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1 -ChangeSet@1.1575, 2009-04-14 07:55:41-04:00, mayer@pogo.udel.edu +1 -0 - Added fix for Bug 813 + ntpdc/ntpdc.1@1.250, 2010-04-09 08:15:02+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1 - ChangeLog@1.66, 2009-04-14 07:55:31-04:00, mayer@pogo.udel.edu +1 -0 - Added fix for Bug 813 + ntpq/ntpq-opts.c@1.252, 2010-04-09 08:15:02+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1 -ChangeSet@1.1574, 2009-04-14 07:51:41-04:00, mayer@pogo.udel.edu +1 -0 - [Bug 813] Conditional naming of Event + ntpq/ntpq-opts.h@1.252, 2010-04-09 08:15:03+00:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P1 - ports/winnt/ntpd/ntp_iocompletionport.c@1.31, 2009-04-14 07:51:14-04:00, mayer@pogo.udel.edu +7 -1 - [Bug 813] Conditional naming of Event + ntpq/ntpq-opts.texi@1.251, 2010-04-09 08:15:03+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1 -ChangeSet@1.1567.1.4, 2009-04-14 05:21:17+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - configure.ac: - use unset for tickadj utility test fix + ntpq/ntpq.1@1.251, 2010-04-09 08:15:03+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1 - configure.ac@1.405, 2009-04-14 05:21:15+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 - use unset for tickadj utility test fix + ntpsnmpd/ntpsnmpd-opts.c@1.130, 2010-04-09 08:15:03+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1 -ChangeSet@1.1567.1.3, 2009-04-14 02:59:39+00:00, hart@pogo.udel.edu +1 -0 - build: - do not require nice + ntpsnmpd/ntpsnmpd-opts.h@1.130, 2010-04-09 08:15:03+00:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P1 - build@1.26, 2009-04-14 02:59:20+00:00, hart@pogo.udel.edu +21 -4 - do not require nice + ntpsnmpd/ntpsnmpd-opts.texi@1.130, 2010-04-09 08:15:03+00:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P1 -ChangeSet@1.1567.1.2, 2009-04-14 01:33:01+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - configure.ac, ChangeLog: - [Bug 1158] support for aix6.1 + ntpsnmpd/ntpsnmpd.1@1.129, 2010-04-09 08:15:03+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1 - ChangeLog@1.64.1.2, 2009-04-14 01:33:00+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - [Bug 1158] support for aix6.1 + packageinfo.sh@1.267, 2010-04-09 08:15:03+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1 - configure.ac@1.404, 2009-04-14 01:33:00+00:00, davehart@shiny.ad.hartbrothers.com +8 -8 - [Bug 1158] support for aix6.1 + sntp/sntp-opts.c@1.124, 2010-04-09 08:15:03+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1 -ChangeSet@1.1567.1.1, 2009-04-14 01:28:08+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 - [Bug 1157] quiet OpenSSL warnings, clean up configure.ac - make flock-build quit before causing harm if another has not completed - + sntp/sntp-opts.h@1.124, 2010-04-09 08:15:03+00:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P1 - ChangeLog@1.64.1.1, 2009-04-14 01:28:06+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 - [Bug 1157] quiet OpenSSL warnings, clean up configure.ac + sntp/sntp-opts.texi@1.124, 2010-04-09 08:15:03+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1 - build@1.25, 2009-04-14 01:28:07+00:00, davehart@shiny.ad.hartbrothers.com +6 -7 - prevent multiple flock-builds from stepping on each others work + sntp/sntp.1@1.124, 2010-04-09 08:15:03+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1 - configure.ac@1.403, 2009-04-14 01:28:07+00:00, davehart@shiny.ad.hartbrothers.com +613 -361 - [Bug 1157] quiet OpenSSL warnings, configure.ac cleanup + sntp/sntp.html@1.14, 2010-04-09 08:15:03+00:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P1 - flock-build@1.40, 2009-04-14 01:28:07+00:00, davehart@shiny.ad.hartbrothers.com +76 -20 - prevent multiple flock-builds from stepping on each others work + util/ntp-keygen-opts.c@1.254, 2010-04-09 08:15:03+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1 - sntp/configure.ac@1.16, 2009-04-14 01:28:07+00:00, davehart@shiny.ad.hartbrothers.com +14 -0 - bring in line with -dev to ease merges, no functional change + util/ntp-keygen-opts.h@1.254, 2010-04-09 08:15:03+00:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P1 -ChangeSet@1.1573, 2009-04-13 00:00:55-04:00, mayer@pogo.udel.edu +1 -0 - Forgot the _WIN32_WINNT update + util/ntp-keygen-opts.texi@1.253, 2010-04-09 08:15:03+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1 - ports/winnt/include/config.h@1.51, 2009-04-13 00:00:24-04:00, mayer@pogo.udel.edu +10 -23 - Forgot the _WIN32_WINNT update + util/ntp-keygen.1@1.253, 2010-04-09 08:15:03+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1 -ChangeSet@1.1572, 2009-04-12 00:55:24-04:00, mayer@pogo.udel.edu +1 -0 - Windows bug fixes +ChangeSet@1.2156.1.1, 2010-04-09 03:43:19-04:00, stenn@deacon.udel.edu +2 -0 + Release ntp-4.2.6p1 - ChangeLog@1.65, 2009-04-12 00:54:43-04:00, mayer@pogo.udel.edu +7 -2 - Windows bug fixes + NEWS@1.106, 2010-04-09 03:43:05-04:00, stenn@deacon.udel.edu +14 -0 + Release ntp-4.2.6p1 -ChangeSet@1.1571, 2009-04-12 00:45:48-04:00, mayer@pogo.udel.edu +2 -0 - [Bug 1156] lock_thread_to_processor() should be declared in header + packageinfo.sh@1.266, 2010-04-09 03:43:05-04:00, stenn@deacon.udel.edu +1 -1 + Release ntp-4.2.6p1 - ports/winnt/include/clockstuff.h@1.8, 2009-04-12 00:45:09-04:00, mayer@pogo.udel.edu +1 -0 - [Bug 1156] lock_thread_to_processor() should be declared in header +ChangeSet@1.2157, 2010-04-06 05:37:52+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1518] Windows ntpd should lock to one processor more + conservatively. - ports/winnt/ntpd/nt_clockstuff.c@1.25, 2009-04-12 00:45:09-04:00, mayer@pogo.udel.edu +0 -1 - [Bug 1156] lock_thread_to_processor() should be declared in header + ports/winnt/ntpd/nt_clockstuff.c@1.39, 2010-04-06 05:37:37+00:00, davehart@shiny.ad.hartbrothers.com +144 -108 + [Bug 1518] Windows ntpd should lock to one processor more + conservatively. -ChangeSet@1.1570, 2009-04-12 00:38:47-04:00, mayer@pogo.udel.edu +1 -0 - [Bug 1147] System errors should be logged to msyslog() +ChangeSet@1.2156, 2010-04-01 03:33:20-04:00, stenn@deacon.udel.edu +1 -0 + lose whimsy from br-flock - ports/winnt/ntpd/ntp_iocompletionport.c@1.30, 2009-04-12 00:38:08-04:00, mayer@pogo.udel.edu +17 -14 - [Bug 1147] System errors should be logged to msyslog() + br-flock@1.13, 2010-04-01 03:33:09-04:00, stenn@deacon.udel.edu +1 -1 + lose whimsy from br-flock -ChangeSet@1.1569, 2009-04-12 00:34:41-04:00, mayer@pogo.udel.edu +1 -0 - [Bug 1155] Wrong header included in config.h. Should have been winsock2.h +ChangeSet@1.2155, 2010-03-31 08:45:31+00:00, stenn@deacon.udel.edu +27 -0 + NTP_4_2_6P1_RC6 + TAG: NTP_4_2_6P1_RC6 - ports/winnt/include/config.h@1.50, 2009-04-12 00:34:10-04:00, mayer@pogo.udel.edu +1 -2 - [Bug 1155] Wrong header included in config.h. Should have been winsock2.h + ChangeLog@1.613, 2010-03-31 08:45:28+00:00, stenn@deacon.udel.edu +1 -0 + NTP_4_2_6P1_RC6 -ChangeSet@1.1568, 2009-04-12 00:32:25-04:00, mayer@pogo.udel.edu +1 -0 - [Bug 787] Bug fixes for 64-bit time_t on Windows + ntpd/ntpd-opts.c@1.254, 2010-03-31 08:45:28+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1_RC6 - ports/winnt/libntp/SetSystemTime.c@1.4, 2009-04-12 00:30:42-04:00, mayer@pogo.udel.edu +2 -2 - [Bug 787] Bug fixes for 64-bit time_t on Windows + ntpd/ntpd-opts.h@1.254, 2010-03-31 08:45:28+00:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P1_RC6 -ChangeSet@1.1567, 2009-04-09 07:44:06-04:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P7_RC2 - TAG: NTP_4_2_4P7_RC2 + ntpd/ntpd-opts.texi@1.252, 2010-03-31 08:45:28+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1_RC6 - ChangeLog@1.64, 2009-04-09 07:43:41-04:00, stenn@whimsy.udel.edu +1 -0 - NTP_4_2_4P7_RC2 + ntpd/ntpd.1@1.252, 2010-03-31 08:45:28+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1_RC6 - ntpd/ntpd-opts.c@1.78, 2009-04-09 07:43:42-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + ntpdc/ntpdc-opts.c@1.250, 2010-03-31 08:45:28+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1_RC6 - ntpd/ntpd-opts.h@1.78, 2009-04-09 07:43:43-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC2 + ntpdc/ntpdc-opts.h@1.250, 2010-03-31 08:45:28+00:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P1_RC6 - ntpd/ntpd-opts.texi@1.77, 2009-04-09 07:43:43-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + ntpdc/ntpdc-opts.texi@1.249, 2010-03-31 08:45:28+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1_RC6 - ntpd/ntpd.1@1.76, 2009-04-09 07:43:45-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + ntpdc/ntpdc.1@1.249, 2010-03-31 08:45:29+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1_RC6 - ntpd/ntpdsim-opts.c@1.78, 2009-04-09 07:43:46-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + ntpq/ntpq-opts.c@1.251, 2010-03-31 08:45:29+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1_RC6 - ntpd/ntpdsim-opts.h@1.78, 2009-04-09 07:43:47-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC2 + ntpq/ntpq-opts.h@1.251, 2010-03-31 08:45:29+00:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P1_RC6 - ntpd/ntpdsim-opts.texi@1.76, 2009-04-09 07:43:47-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC2 + ntpq/ntpq-opts.texi@1.250, 2010-03-31 08:45:29+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1_RC6 - ntpd/ntpdsim.1@1.76, 2009-04-09 07:43:48-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + ntpq/ntpq.1@1.250, 2010-03-31 08:45:29+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1_RC6 - ntpdc/ntpdc-opts.c@1.78, 2009-04-09 07:43:49-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + ntpsnmpd/ntpsnmpd-opts.c@1.129, 2010-03-31 08:45:29+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1_RC6 - ntpdc/ntpdc-opts.h@1.78, 2009-04-09 07:43:50-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC2 + ntpsnmpd/ntpsnmpd-opts.h@1.129, 2010-03-31 08:45:29+00:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P1_RC6 - ntpdc/ntpdc-opts.texi@1.76, 2009-04-09 07:43:51-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + ntpsnmpd/ntpsnmpd-opts.texi@1.129, 2010-03-31 08:45:29+00:00, stenn@deacon.udel.edu +2 -23 + NTP_4_2_6P1_RC6 - ntpdc/ntpdc.1@1.76, 2009-04-09 07:43:51-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + ntpsnmpd/ntpsnmpd.1@1.128, 2010-03-31 08:45:29+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1_RC6 - ntpq/ntpq-opts.c@1.80, 2009-04-09 07:43:52-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + packageinfo.sh@1.265, 2010-03-31 08:45:29+00:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6P1_RC6 - ntpq/ntpq-opts.h@1.80, 2009-04-09 07:43:53-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC2 + sntp/sntp-opts.c@1.123, 2010-03-31 08:45:29+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1_RC6 - ntpq/ntpq-opts.texi@1.77, 2009-04-09 07:43:54-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + sntp/sntp-opts.h@1.123, 2010-03-31 08:45:29+00:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P1_RC6 - ntpq/ntpq.1@1.76, 2009-04-09 07:43:55-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + sntp/sntp-opts.texi@1.123, 2010-03-31 08:45:29+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1_RC6 - packageinfo.sh@1.108, 2009-04-09 07:43:55-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC2 + sntp/sntp.1@1.123, 2010-03-31 08:45:29+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1_RC6 - sntp/sntp-opts.c@1.76, 2009-04-09 07:43:57-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + sntp/sntp.html@1.13, 2010-03-31 08:45:29+00:00, stenn@deacon.udel.edu +10 -14 + NTP_4_2_6P1_RC6 - sntp/sntp-opts.h@1.76, 2009-04-09 07:43:58-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC2 + util/ntp-keygen-opts.c@1.253, 2010-03-31 08:45:29+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1_RC6 - sntp/sntp-opts.texi@1.73, 2009-04-09 07:43:58-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC2 + util/ntp-keygen-opts.h@1.253, 2010-03-31 08:45:29+00:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6P1_RC6 - sntp/sntp.1@1.76, 2009-04-09 07:43:59-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + util/ntp-keygen-opts.texi@1.252, 2010-03-31 08:45:29+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1_RC6 - util/ntp-keygen-opts.c@1.77, 2009-04-09 07:44:00-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + util/ntp-keygen.1@1.252, 2010-03-31 08:45:29+00:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6P1_RC6 - util/ntp-keygen-opts.h@1.77, 2009-04-09 07:44:00-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC2 +ChangeSet@1.2154, 2010-03-31 04:14:28-04:00, stenn@deacon.udel.edu +1 -0 + Quiet some trigger debugging - util/ntp-keygen-opts.texi@1.75, 2009-04-09 07:44:02-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + BitKeeper/triggers/triggert@1.8, 2010-03-31 04:14:06-04:00, stenn@deacon.udel.edu +1 -1 + Quiet some trigger debugging - util/ntp-keygen.1@1.75, 2009-04-09 07:44:02-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 +ChangeSet@1.2153, 2010-03-31 04:11:55-04:00, stenn@deacon.udel.edu +2 -0 + [Bug 1514] Typo in ntp_proto.c: fabs(foo < .4) should be fabs(foo) < .4 -ChangeSet@1.1566, 2009-04-09 04:16:50-04:00, stenn@whimsy.udel.edu +1 -0 - ChangLog cleanup + ChangeLog@1.612, 2010-03-31 04:11:43-04:00, stenn@deacon.udel.edu +1 -0 + [Bug 1514] Typo in ntp_proto.c: fabs(foo < .4) should be fabs(foo) < .4 - ChangeLog@1.63, 2009-04-09 04:16:43-04:00, stenn@whimsy.udel.edu +1 -0 - ChangLog cleanup + ntpd/ntp_proto.c@1.298, 2010-03-31 04:11:43-04:00, stenn@deacon.udel.edu +1 -1 + [Bug 1514] Typo in ntp_proto.c: fabs(foo < .4) should be fabs(foo) < .4 -ChangeSet@1.1565, 2009-04-09 04:13:41-04:00, stenn@whimsy.udel.edu +2 -0 - [Sec 1144] limited buffer overflow in ntpq. CVE-2009-0159 +ChangeSet@1.2152, 2010-03-31 03:17:27-04:00, stenn@deacon.udel.edu +4 -0 + trigger cleanup - ChangeLog@1.62, 2009-04-09 04:13:30-04:00, stenn@whimsy.udel.edu +2 -0 - [Sec 1144] limited buffer overflow in ntpq. CVE-2009-0159 + BitKeeper/triggers/trigger.README@1.5, 2010-03-31 03:17:12-04:00, stenn@deacon.udel.edu +5 -3 + trigger cleanup - ntpq/ntpq.c@1.66, 2009-04-09 04:13:30-04:00, stenn@whimsy.udel.edu +2 -2 - [Sec 1144] limited buffer overflow in ntpq. CVE-2009-0159 + BitKeeper/triggers/trigger.cfg@1.13, 2010-03-31 03:17:12-04:00, stenn@deacon.udel.edu +6 -0 + trigger cleanup -ChangeSet@1.1564, 2009-04-07 09:14:58+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 - [Sec 1149] use setsockopt(SO_EXCLUSIVEADDRUSE) on Windows + BitKeeper/triggers/trigger.mk@1.10, 2010-03-31 03:17:12-04:00, stenn@deacon.udel.edu +3 -1 + trigger cleanup - ChangeLog@1.61, 2009-04-07 09:14:56+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 - [Sec 1149] use setsockopt(SO_EXCLUSIVEADDRUSE) on Windows + BitKeeper/triggers/triggert@1.7, 2010-03-31 03:17:12-04:00, stenn@deacon.udel.edu +17 -6 + trigger cleanup - ntpd/ntp_io.c@1.259, 2009-04-07 09:14:56+00:00, davehart@shiny.ad.hartbrothers.com +64 -31 - [Sec 1149] use setsockopt(SO_EXCLUSIVEADDRUSE) on Windows +ChangeSet@1.2151, 2010-03-29 05:16:32-04:00, stenn@deacon.udel.edu +1 -0 + With the new bk, the trigger push needs the -q (quiet) flag - ports/winnt/libntp/libntp.vcproj@1.2, 2009-04-07 09:14:57+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 - add ntp_debug.h + BitKeeper/triggers/2mirrors@1.5, 2010-03-29 05:16:08-04:00, stenn@deacon.udel.edu +3 -3 + With the new bk, the trigger push needs the -q (quiet) flag -ChangeSet@1.1563, 2009-03-30 06:47:41-05:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P7_RC1 - TAG: NTP_4_2_4P7_RC1 +ChangeSet@1.2150, 2010-02-15 23:19:19+00:00, davehart@shiny.ad.hartbrothers.com +8 -0 + [Bug 1464] synchronization source wrong for refclocks ARCRON_MSF (27) + and SHM (28). + Correct Windows port's refclock_open() to return 0 on failure not -1. + Correct CHU, dumbclock, and WWVB drivers to check for 0 returned from + refclock_open() on failure. + Correct "SIMUL=4 ./flock-build -1" to prioritize -1/--one. + - ChangeLog@1.60, 2009-03-30 06:47:19-05:00, stenn@whimsy.udel.edu +1 -0 - NTP_4_2_4P7_RC1 + ChangeLog@1.611, 2010-02-15 23:19:18+00:00, davehart@shiny.ad.hartbrothers.com +9 -0 + [Bug 1464] synchronization source wrong for refclocks ARCRON_MSF (27) + and SHM (28). + Correct Windows port's refclock_open() to return 0 on failure not -1. + Correct CHU, dumbclock, and WWVB drivers to check for 0 returned from + refclock_open() on failure. + Correct "SIMUL=4 ./flock-build -1" to prioritize -1/--one. + - ntpd/ntpd-opts.c@1.77, 2009-03-30 06:47:20-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + flock-build@1.45, 2010-02-15 23:19:18+00:00, davehart@shiny.ad.hartbrothers.com +26 -21 + Correct "SIMUL=4 ./flock-build -1" to prioritize -1/--one. - ntpd/ntpd-opts.h@1.77, 2009-03-30 06:47:21-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC1 + ntpd/ntp_control.c@1.133, 2010-02-15 23:19:18+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + [Bug 1464] synchronization source wrong for refclocks ARCRON_MSF (27) + and SHM (28). - ntpd/ntpd-opts.texi@1.76, 2009-03-30 06:47:22-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ntpd/ntp_refclock.c@1.92, 2010-02-15 23:19:18+00:00, davehart@shiny.ad.hartbrothers.com +4 -1 + Correct Windows port's refclock_open() to return 0 on failure not -1. + Correct CHU, dumbclock, and WWVB drivers to check for 0 returned from + refclock_open() on failure. - ntpd/ntpd.1@1.75, 2009-03-30 06:47:22-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ntpd/refclock_chu.c@1.47, 2010-02-15 23:19:18+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + Correct Windows port's refclock_open() to return 0 on failure not -1. + Correct CHU, dumbclock, and WWVB drivers to check for 0 returned from + refclock_open() on failure. - ntpd/ntpdsim-opts.c@1.77, 2009-03-30 06:47:23-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ntpd/refclock_dumbclock.c@1.15, 2010-02-15 23:19:18+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + Correct Windows port's refclock_open() to return 0 on failure not -1. + Correct CHU, dumbclock, and WWVB drivers to check for 0 returned from + refclock_open() on failure. - ntpd/ntpdsim-opts.h@1.77, 2009-03-30 06:47:24-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC1 + ntpd/refclock_wwvb.c@1.24, 2010-02-15 23:19:18+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + Correct Windows port's refclock_open() to return 0 on failure not -1. + Correct CHU, dumbclock, and WWVB drivers to check for 0 returned from + refclock_open() on failure. - ntpd/ntpdsim-opts.texi@1.75, 2009-03-30 06:47:25-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC1 + ports/winnt/ntpd/win32_io.c@1.20, 2010-02-15 23:19:18+00:00, davehart@shiny.ad.hartbrothers.com +15 -9 + Correct Windows port's refclock_open() to return 0 on failure not -1. + Correct CHU, dumbclock, and WWVB drivers to check for 0 returned from + refclock_open() on failure. - ntpd/ntpdsim.1@1.75, 2009-03-30 06:47:26-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 +ChangeSet@1.2149, 2010-02-09 10:34:59+00:00, stenn@whimsy.udel.edu +27 -0 + NTP_4_2_6P1_RC5 + TAG: NTP_4_2_6P1_RC5 - ntpdc/ntpdc-opts.c@1.77, 2009-03-30 06:47:26-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ChangeLog@1.610, 2010-02-09 10:34:44+00:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_6P1_RC5 - ntpdc/ntpdc-opts.h@1.77, 2009-03-30 06:47:26-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC1 + ntpd/ntpd-opts.c@1.253, 2010-02-09 10:34:44+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC5 - ntpdc/ntpdc-opts.texi@1.75, 2009-03-30 06:47:27-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ntpd/ntpd-opts.h@1.253, 2010-02-09 10:34:45+00:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC5 - ntpdc/ntpdc.1@1.75, 2009-03-30 06:47:28-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ntpd/ntpd-opts.texi@1.251, 2010-02-09 10:34:45+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC5 - ntpq/ntpq-opts.c@1.79, 2009-03-30 06:47:29-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ntpd/ntpd.1@1.251, 2010-02-09 10:34:46+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC5 - ntpq/ntpq-opts.h@1.79, 2009-03-30 06:47:30-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC1 + ntpdc/ntpdc-opts.c@1.249, 2010-02-09 10:34:46+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC5 - ntpq/ntpq-opts.texi@1.76, 2009-03-30 06:47:31-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ntpdc/ntpdc-opts.h@1.249, 2010-02-09 10:34:46+00:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC5 - ntpq/ntpq.1@1.75, 2009-03-30 06:47:32-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ntpdc/ntpdc-opts.texi@1.248, 2010-02-09 10:34:47+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC5 - packageinfo.sh@1.107, 2009-03-30 06:47:33-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ntpdc/ntpdc.1@1.248, 2010-02-09 10:34:47+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC5 - sntp/sntp-opts.c@1.75, 2009-03-30 06:47:33-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ntpq/ntpq-opts.c@1.250, 2010-02-09 10:34:48+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC5 - sntp/sntp-opts.h@1.75, 2009-03-30 06:47:34-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC1 + ntpq/ntpq-opts.h@1.250, 2010-02-09 10:34:48+00:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC5 - sntp/sntp-opts.texi@1.72, 2009-03-30 06:47:35-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC1 + ntpq/ntpq-opts.texi@1.249, 2010-02-09 10:34:48+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC5 - sntp/sntp.1@1.75, 2009-03-30 06:47:35-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ntpq/ntpq.1@1.249, 2010-02-09 10:34:49+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC5 - util/ntp-keygen-opts.c@1.76, 2009-03-30 06:47:36-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ntpsnmpd/ntpsnmpd-opts.c@1.128, 2010-02-09 10:34:49+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC5 - util/ntp-keygen-opts.h@1.76, 2009-03-30 06:47:36-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC1 + ntpsnmpd/ntpsnmpd-opts.h@1.128, 2010-02-09 10:34:50+00:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC5 - util/ntp-keygen-opts.texi@1.74, 2009-03-30 06:47:37-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ntpsnmpd/ntpsnmpd-opts.texi@1.128, 2010-02-09 10:34:50+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC5 - util/ntp-keygen.1@1.74, 2009-03-30 06:47:38-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ntpsnmpd/ntpsnmpd.1@1.127, 2010-02-09 10:34:51+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC5 -ChangeSet@1.1562, 2009-03-30 02:31:49-05:00, stenn@whimsy.udel.edu +1 -0 - Release Candidate + packageinfo.sh@1.264, 2010-02-09 10:34:51+00:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_6P1_RC5 - packageinfo.sh@1.106, 2009-03-30 02:31:39-05:00, stenn@whimsy.udel.edu +1 -1 - Release Candidate + sntp/sntp-opts.c@1.122, 2010-02-09 10:34:51+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC5 -ChangeSet@1.1560, 2009-03-28 02:46:45-05:00, stenn@whimsy.udel.edu +9 -0 - build system email address cleanup + sntp/sntp-opts.h@1.122, 2010-02-09 10:34:52+00:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC5 - BitKeeper/triggers/changelog@1.4, 2009-03-28 02:45:21-05:00, stenn@whimsy.udel.edu +1 -1 - trigger email address cleanup + sntp/sntp-opts.texi@1.122, 2010-02-09 10:34:52+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC5 - BitKeeper/triggers/commitlogs@1.6, 2009-03-28 02:45:22-05:00, stenn@whimsy.udel.edu +1 -1 - trigger email address cleanup + sntp/sntp.1@1.122, 2010-02-09 10:34:53+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC5 - BitKeeper/triggers/delta-changelog@1.8, 2009-03-28 02:45:22-05:00, stenn@whimsy.udel.edu +2 -2 - trigger email address cleanup + sntp/sntp.html@1.12, 2010-02-09 10:34:53+00:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_6P1_RC5 - BitKeeper/triggers/notify@1.4, 2009-03-28 02:45:22-05:00, stenn@whimsy.udel.edu +1 -1 - trigger email address cleanup + util/ntp-keygen-opts.c@1.252, 2010-02-09 10:34:53+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC5 - BitKeeper/triggers/paranoid@1.4, 2009-03-28 02:45:22-05:00, stenn@whimsy.udel.edu +1 -1 - trigger email address cleanup + util/ntp-keygen-opts.h@1.252, 2010-02-09 10:34:54+00:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC5 - BitKeeper/triggers/post-incoming.license-warn@1.7, 2009-03-28 02:45:22-05:00, stenn@whimsy.udel.edu +1 -1 - trigger email address cleanup + util/ntp-keygen-opts.texi@1.251, 2010-02-09 10:34:54+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC5 - BitKeeper/triggers/pre-resolve.licfix@1.4, 2009-03-28 02:45:22-05:00, stenn@whimsy.udel.edu +1 -1 - trigger email address cleanup + util/ntp-keygen.1@1.251, 2010-02-09 10:34:54+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC5 - BitKeeper/triggers/send@1.14, 2009-03-28 02:45:22-05:00, stenn@whimsy.udel.edu +2 -2 - trigger email address cleanup +ChangeSet@1.2148, 2010-02-09 04:02:59-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1438] Remove dead code from sntp/networking.c - ChangeLog@1.58, 2009-03-28 02:46:36-05:00, stenn@whimsy.udel.edu +3 -1 - build system email address cleanup + ChangeLog@1.609, 2010-02-09 04:02:48-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1438] Remove dead code from sntp/networking.c -ChangeSet@1.1559, 2009-03-24 15:22:36+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - config.h: - include winsock.h before ws2tcpip.h to fix VS 2005 build + sntp/networking.c@1.30, 2010-02-09 04:02:48-05:00, stenn@whimsy.udel.edu +0 -1 + [Bug 1438] Remove dead code from sntp/networking.c - ports/winnt/include/config.h@1.49, 2009-03-24 15:22:23+00:00, davehart@shiny.ad.hartbrothers.com +8 -5 - include winsock.h before ws2tcpip.h to fix VS 2005 build +ChangeSet@1.2145.1.1, 2010-02-09 02:49:34-05:00, stenn@whimsy.udel.edu +4 -0 + [Bug 1140] Clean up debug.html, decode.html, and ntpq.html -ChangeSet@1.1549.4.2, 2009-03-24 15:14:36+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - ntp_iocompletionport.c: - use one receive per socket to avoid Win2000 afd.sys bugcheck 0x76 + ChangeLog@1.606.1.1, 2010-02-09 02:49:18-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1140] Clean up debug.html, decode.html, and ntpq.html - ports/winnt/ntpd/ntp_iocompletionport.c@1.26.1.2, 2009-03-24 15:14:23+00:00, davehart@shiny.ad.hartbrothers.com +10 -1 - use one receive per socket to avoid Win2000 afd.sys bugcheck 0x76 + html/debug.html@1.28, 2010-02-09 02:49:18-05:00, stenn@whimsy.udel.edu +3 -3 + [Bug 1140] Clean up debug.html, decode.html, and ntpq.html -ChangeSet@1.1557, 2009-03-22 21:09:43+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - Makefile.am, ChangeLog: - [Bug 774] parsesolaris.c does not compile under the new Solaris + html/decode.html@1.12, 2010-02-09 02:49:19-05:00, stenn@whimsy.udel.edu +11 -7 + [Bug 1140] Clean up debug.html, decode.html, and ntpq.html - ChangeLog@1.57, 2009-03-22 21:09:42+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - [Bug 774] parsesolaris.c does not compile under the new Solaris + html/ntpq.html@1.37, 2010-02-09 02:49:19-05:00, stenn@whimsy.udel.edu +11 -7 + [Bug 1140] Clean up debug.html, decode.html, and ntpq.html - libparse/Makefile.am@1.9, 2009-03-22 21:09:42+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 - [Bug 774] parsesolaris.c does not compile under the new Solaris +ChangeSet@1.2146, 2010-02-08 14:11:12+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + [Bug 1478] linking fails with undefined reference EVP_MD_pkey_type. + [Bug 1479] Compilation fails because of not finding readline headers. + [Bug 1484] ushort is not defined in QNX6. -ChangeSet@1.1556, 2009-03-20 03:39:26+00:00, hart@pogo.udel.edu +1 -0 - ChangeLog: - bk for windows isn't converting line endings correctly, remove two blank lines visible only on Unix side + ChangeLog@1.607, 2010-02-08 14:11:10+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1478] linking fails with undefined reference EVP_MD_pkey_type. + [Bug 1479] Compilation fails because of not finding readline headers. + [Bug 1484] ushort is not defined in QNX6. - ChangeLog@1.56, 2009-03-20 03:39:16+00:00, hart@pogo.udel.edu +0 -2 - bk for windows isn't converting line endings correctly, remove two blank lines visible only on Unix side + include/mbg_gps166.h@1.10, 2010-02-08 14:11:10+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + [Bug 1484] ushort is not defined in QNX6. -ChangeSet@1.1553, 2009-03-20 03:10:22+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - ChangeLog: - remove blank first line + libntp/ntp_lineedit.c@1.8, 2010-02-08 14:11:10+00:00, davehart@shiny.ad.hartbrothers.com +29 -32 + [Bug 1479] Compilation fails because of not finding readline headers. - ChangeLog@1.53, 2009-03-20 03:09:55+00:00, davehart@shiny.ad.hartbrothers.com +0 -1 - remove blank first line + m4/ntp_lineeditlibs.m4@1.7, 2010-02-08 14:11:10+00:00, davehart@shiny.ad.hartbrothers.com +0 -2 + [Bug 1479] Compilation fails because of not finding readline headers. -ChangeSet@1.1549.4.1, 2009-03-20 01:46:15+00:00, davehart@shiny.ad.hartbrothers.com +10 -0 - [Bug 873] Windows serial refclock proper TTY line discipline emulation + ntpd/ntp_control.c@1.132, 2010-02-08 14:11:11+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1478] linking fails with undefined reference EVP_MD_pkey_type. - ChangeLog@1.50.4.1, 2009-03-20 01:46:11+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - [Bug 873] Windows serial refclock proper TTY line discipline emulation +ChangeSet@1.2145, 2010-02-05 22:26:34+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1480] snprintf() cleanup caused unterminated refclock IDs. - ntpd/ntp_io.c@1.256.1.1, 2009-03-20 01:46:11+00:00, davehart@shiny.ad.hartbrothers.com +26 -23 - [Bug 873] Windows serial refclock proper TTY line discipline emulation + ChangeLog@1.606, 2010-02-05 22:26:32+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1480] snprintf() cleanup caused unterminated refclock IDs. - ntpd/ntpd.c@1.86, 2009-03-20 01:46:12+00:00, davehart@shiny.ad.hartbrothers.com +14 -25 - slightly reduce #ifdef SYS_WINNT forest + ntpd/ntp_control.c@1.131, 2010-02-05 22:26:32+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + [Bug 1480] snprintf() cleanup caused unterminated refclock IDs. - ntpd/refclock_dumbclock.c@1.9, 2009-03-20 01:46:12+00:00, davehart@shiny.ad.hartbrothers.com +6 -5 - [Bug 873] Windows serial refclock proper TTY line discipline emulation +ChangeSet@1.2144, 2010-02-04 23:13:52+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1477] 1st non-gmake make in clone w/VPATH can't make COPYRIGHT. - ntpd/refclock_hopfser.c@1.10, 2009-03-20 01:46:12+00:00, davehart@shiny.ad.hartbrothers.com +6 -5 - [Bug 873] Windows serial refclock proper TTY line discipline emulation + ChangeLog@1.605, 2010-02-04 23:13:43+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1477] 1st non-gmake make in clone w/VPATH can't make COPYRIGHT. - ntpd/refclock_nmea.c@1.26, 2009-03-20 01:46:12+00:00, davehart@shiny.ad.hartbrothers.com +6 -5 - [Bug 873] Windows serial refclock proper TTY line discipline emulation + Makefile.am@1.93, 2010-02-04 23:13:43+00:00, davehart@shiny.ad.hartbrothers.com +3 -3 + [Bug 1477] 1st non-gmake make in clone w/VPATH can't make COPYRIGHT. - ntpd/refclock_palisade.c@1.19, 2009-03-20 01:46:12+00:00, davehart@shiny.ad.hartbrothers.com +6 -5 - [Bug 873] Windows serial refclock proper TTY line discipline emulation + sntp/Makefile.am@1.28, 2010-02-04 23:13:43+00:00, davehart@shiny.ad.hartbrothers.com +3 -3 + [Bug 1477] 1st non-gmake make in clone w/VPATH can't make COPYRIGHT. - ports/winnt/include/ntp_iocompletionport.h@1.14, 2009-03-20 01:46:13+00:00, davehart@shiny.ad.hartbrothers.com +8 -9 - [Bug 873] Windows serial refclock proper TTY line discipline emulation +ChangeSet@1.2143, 2010-02-04 02:57:49-05:00, stenn@whimsy.udel.edu +27 -0 + NTP_4_2_6P1_RC4 + TAG: NTP_4_2_6P1_RC4 - ports/winnt/ntpd/ntp_iocompletionport.c@1.26.1.1, 2009-03-20 01:46:13+00:00, davehart@shiny.ad.hartbrothers.com +331 -249 - [Bug 873] Windows serial refclock proper TTY line discipline emulation + ChangeLog@1.604, 2010-02-04 02:57:32-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_6P1_RC4 - ports/winnt/ntpd/win32_io.c@1.13, 2009-03-20 01:46:13+00:00, davehart@shiny.ad.hartbrothers.com +172 -66 - [Bug 873] Windows serial refclock proper TTY line discipline emulation + ntpd/ntpd-opts.c@1.252, 2010-02-04 02:57:33-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC4 -ChangeSet@1.1549.3.2, 2009-03-18 11:44:59+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - [Bug 1014] Enable building with VC9 (in Visual Studio 2008, Visual C++ 2008, or SDK) + ntpd/ntpd-opts.h@1.252, 2010-02-04 02:57:33-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC4 - ChangeLog@1.50.3.1, 2009-03-18 11:44:52+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - [Bug 1014] Enable building with VC9 (in Visual Studio 2008, Visual C++ 2008, or SDK) + ntpd/ntpd-opts.texi@1.250, 2010-02-04 02:57:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC4 -ChangeSet@1.1549.1.4, 2009-03-18 10:14:52+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - [Bug 1117] Deferred interface binding under Windows works only correctly if FORCE_DNSRETRY is defined + ntpd/ntpd.1@1.250, 2010-02-04 02:57:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC4 - ChangeLog@1.50.1.3, 2009-03-18 10:12:28+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - [Bug 1117] Deferred interface binding under Windows works only correctly if FORCE_DNSRETRY is defined + ntpdc/ntpdc-opts.c@1.248, 2010-02-04 02:57:35-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC4 -ChangeSet@1.1549.3.1, 2009-03-17 18:39:09+00:00, davehart@shiny.ad.hartbrothers.com +8 -0 - add .sln and .vcproj files for VC9 + ntpdc/ntpdc-opts.h@1.248, 2010-02-04 02:57:35-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC4 - ports/winnt/instsrv/Instsrv.vcproj@1.1, 2009-03-17 18:34:21+00:00, davehart@shiny.ad.hartbrothers.com +253 -0 - VC9 equivalent to Instsrv.dsp + ntpdc/ntpdc-opts.texi@1.247, 2010-02-04 02:57:36-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC4 - ports/winnt/instsrv/Instsrv.vcproj@1.0, 2009-03-17 18:34:21+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + ntpdc/ntpdc.1@1.247, 2010-02-04 02:57:36-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC4 - ports/winnt/libntp/libntp.vcproj@1.1, 2009-03-17 18:35:45+00:00, davehart@shiny.ad.hartbrothers.com +2229 -0 - VC9 equivalent to libntp.dsp + ntpq/ntpq-opts.c@1.249, 2010-02-04 02:57:36-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC4 - ports/winnt/libntp/libntp.vcproj@1.0, 2009-03-17 18:35:45+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + ntpq/ntpq-opts.h@1.249, 2010-02-04 02:57:37-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC4 - ports/winnt/ntp-keygen/ntpkeygen.vcproj@1.1, 2009-03-17 18:36:28+00:00, davehart@shiny.ad.hartbrothers.com +419 -0 - VC9 equivalent to ntpkeygen.dsp + ntpq/ntpq-opts.texi@1.248, 2010-02-04 02:57:37-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC4 - ports/winnt/ntp-keygen/ntpkeygen.vcproj@1.0, 2009-03-17 18:36:28+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + ntpq/ntpq.1@1.248, 2010-02-04 02:57:38-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC4 - ports/winnt/ntp.sln@1.1, 2009-03-17 18:38:44+00:00, davehart@shiny.ad.hartbrothers.com +71 -0 - VC9 equivalent to ntp.dsw + ntpsnmpd/ntpsnmpd-opts.c@1.127, 2010-02-04 02:57:38-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC4 - ports/winnt/ntp.sln@1.0, 2009-03-17 18:38:44+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + ntpsnmpd/ntpsnmpd-opts.h@1.127, 2010-02-04 02:57:39-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC4 - ports/winnt/ntpd/ntpd.vcproj@1.1, 2009-03-17 18:36:49+00:00, davehart@shiny.ad.hartbrothers.com +2198 -0 - VC9 equivalent to ntpd.dsp + ntpsnmpd/ntpsnmpd-opts.texi@1.127, 2010-02-04 02:57:39-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC4 - ports/winnt/ntpd/ntpd.vcproj@1.0, 2009-03-17 18:36:49+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + ntpsnmpd/ntpsnmpd.1@1.126, 2010-02-04 02:57:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC4 - ports/winnt/ntpdate/ntpdate.vcproj@1.1, 2009-03-17 18:37:19+00:00, davehart@shiny.ad.hartbrothers.com +327 -0 - VC9 equivalent to ntpdate.dsp + packageinfo.sh@1.263, 2010-02-04 02:57:40-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_6P1_RC4 - ports/winnt/ntpdate/ntpdate.vcproj@1.0, 2009-03-17 18:37:19+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + sntp/sntp-opts.c@1.121, 2010-02-04 02:57:41-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC4 - ports/winnt/ntpdc/ntpdc.vcproj@1.1, 2009-03-17 18:37:32+00:00, davehart@shiny.ad.hartbrothers.com +376 -0 - VC9 equivalent to ntpdc.dsp + sntp/sntp-opts.h@1.121, 2010-02-04 02:57:41-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC4 - ports/winnt/ntpdc/ntpdc.vcproj@1.0, 2009-03-17 18:37:31+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + sntp/sntp-opts.texi@1.121, 2010-02-04 02:57:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC4 - ports/winnt/ntpq/ntpq.vcproj@1.1, 2009-03-17 18:37:48+00:00, davehart@shiny.ad.hartbrothers.com +370 -0 - VC9 equivalent to ntpq.dsp + sntp/sntp.1@1.121, 2010-02-04 02:57:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC4 - ports/winnt/ntpq/ntpq.vcproj@1.0, 2009-03-17 18:37:48+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + sntp/sntp.html@1.11, 2010-02-04 02:57:42-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_6P1_RC4 -ChangeSet@1.1549.1.3, 2009-03-17 18:18:13+00:00, hart@pogo.udel.edu +1 -0 - config.h: - now works with VC6 and VC9 compilers, declares DWORD_PTR on VC6 + util/ntp-keygen-opts.c@1.251, 2010-02-04 02:57:43-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC4 - ports/winnt/include/config.h@1.48, 2009-03-17 18:18:01+00:00, hart@pogo.udel.edu +243 -96 - now works with VC6 and VC9 compilers, declares DWORD_PTR on VC6 + util/ntp-keygen-opts.h@1.251, 2010-02-04 02:57:43-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC4 -ChangeSet@1.1549.2.1, 2009-02-21 07:45:56-05:00, utterback@pogo.udel.edu +2 -0 - configure.ac, ChangeLog: - [BUG 1131] UDP sockets should not use SIGPOLL on Solaris. + util/ntp-keygen-opts.texi@1.250, 2010-02-04 02:57:44-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC4 - ChangeLog@1.50.2.1, 2009-02-20 12:30:18-05:00, utterback@pogo.udel.edu +2 -0 - [BUG 1131] UDP sockets should not use SIGPOLL on Solaris. + util/ntp-keygen.1@1.250, 2010-02-04 02:57:44-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC4 - configure.ac@1.402, 2009-02-20 11:30:02-05:00, utterback@pogo.udel.edu +3 -0 - [BUG 1131] UDP sockets should not use SIGPOLL on Solaris. +ChangeSet@1.2142, 2010-02-04 03:01:42+00:00, hart@psp-fb1.ntp.org +2 -0 + Makefile.am: + fix make distdir before make all on FreeBSD make -ChangeSet@1.1549.1.2, 2009-02-07 21:13:17+00:00, hart@pogo.udel.edu +1 -0 - ChangeLog: - formatting of newest line + Makefile.am@1.92, 2010-02-04 03:00:00+00:00, hart@psp-fb1.ntp.org +5 -5 + fix make distdir before make all on FreeBSD make - ChangeLog@1.50.1.2, 2009-02-07 21:12:26+00:00, hart@pogo.udel.edu +1 -1 - formatting of newest line + sntp/Makefile.am@1.27, 2010-02-04 02:59:15+00:00, hart@psp-fb1.ntp.org +26 -25 + fix make distdir before make all on FreeBSD make -ChangeSet@1.1549.1.1, 2009-02-07 21:05:32+00:00, hart@pogo.udel.edu +3 -0 - nt_clockstuff.c, ChangeLog, ntp_iocompletionport.c: - [BUG 1124] Lock QueryPerformanceCounter() client threads to same CPU +ChangeSet@1.2141, 2010-02-03 23:51:52+00:00, davehart@shiny.ad.hartbrothers.com +14 -0 + Remove arlib. - ChangeLog@1.50.1.1, 2009-02-07 21:04:52+00:00, hart@pogo.udel.edu +2 -0 - [BUG 1124] Lock QueryPerformanceCounter() client threads to same CPU + BitKeeper/deleted/.del-COPYING~1e5c94deb8b25a03@1.3, 2010-02-03 23:50:56+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: arlib/COPYING -> BitKeeper/deleted/.del-COPYING~1e5c94deb8b25a03 - ports/winnt/ntpd/nt_clockstuff.c@1.24, 2009-02-07 21:02:04+00:00, hart@pogo.udel.edu +89 -22 - [BUG 1124] Lock QueryPerformanceCounter() client threads to same CPU + BitKeeper/deleted/.del-INSTALL~4c77da0d9f1f3464@1.2, 2010-02-03 23:50:56+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: arlib/INSTALL -> BitKeeper/deleted/.del-INSTALL~4c77da0d9f1f3464 - ports/winnt/ntpd/ntp_iocompletionport.c@1.27, 2009-02-07 21:03:34+00:00, hart@pogo.udel.edu +12 -0 - [BUG 1124] Lock QueryPerformanceCounter() client threads to same CPU + BitKeeper/deleted/.del-Makefile.am~501d14b0d06d3031@1.4, 2010-02-03 23:50:56+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: arlib/Makefile.am -> BitKeeper/deleted/.del-Makefile.am~501d14b0d06d3031 -ChangeSet@1.1551, 2009-02-07 14:08:35-05:00, hart@pogo.udel.edu +1 -0 - ChangeLog: - DPRINTF safer + BitKeeper/deleted/.del-README~4de4615d76ebba47@1.2, 2010-02-03 23:50:56+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: arlib/README -> BitKeeper/deleted/.del-README~4de4615d76ebba47 - ChangeLog@1.51, 2009-02-07 14:07:34-05:00, hart@pogo.udel.edu +2 -0 - DPRINTF safer + BitKeeper/deleted/.del-UNSHAR.HDR~6aa2f933ef5d86df@1.2, 2010-02-03 23:50:57+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: arlib/UNSHAR.HDR -> BitKeeper/deleted/.del-UNSHAR.HDR~6aa2f933ef5d86df -ChangeSet@1.1550, 2009-02-06 19:00:15-05:00, hart@pogo.udel.edu +2 -0 - ntp_debug.h: - DPRINTF won't eat following else, always evaluates to a statement - ntp_io.c: - DPRINTF_INTERFACE always evaluates to a statement - fix DPRINTF use with misplaced semicolon + BitKeeper/deleted/.del-arlib.3~11ae3dd9cdb6a32@1.2, 2010-02-03 23:50:56+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: arlib/arlib.3 -> BitKeeper/deleted/.del-arlib.3~11ae3dd9cdb6a32 - include/ntp_debug.h@1.2, 2009-02-06 18:50:27-05:00, hart@pogo.udel.edu +6 -4 - DPRINTF won't eat following else, always evaluates to a statement + BitKeeper/deleted/.del-arlib.c~fdde50d6ab7b6f64@1.2, 2010-02-03 23:50:57+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: arlib/arlib.c -> BitKeeper/deleted/.del-arlib.c~fdde50d6ab7b6f64 - ntpd/ntp_io.c@1.257, 2009-02-06 18:53:58-05:00, hart@pogo.udel.edu +2 -2 - DPRINTF_INTERFACE always evaluates to a statement - fix DPRINTF use with misplaced semicolon + BitKeeper/deleted/.del-arlib.h~22218072d10baf8e@1.2, 2010-02-03 23:50:56+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: arlib/arlib.h -> BitKeeper/deleted/.del-arlib.h~22218072d10baf8e -ChangeSet@1.1549, 2009-01-08 06:21:48-05:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P6 - TAG: NTP_4_2_4P6 + BitKeeper/deleted/.del-arplib.h~8ccbd9af28d9aa3b@1.2, 2010-02-03 23:50:56+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: arlib/arplib.h -> BitKeeper/deleted/.del-arplib.h~8ccbd9af28d9aa3b - ChangeLog@1.50, 2009-01-08 06:21:25-05:00, stenn@whimsy.udel.edu +1 -2 - NTP_4_2_4P6 + BitKeeper/deleted/.del-configure.in~282cad3ea077c564@1.4, 2010-02-03 23:50:56+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: arlib/configure.in -> BitKeeper/deleted/.del-configure.in~282cad3ea077c564 - ntpd/ntpd-opts.c@1.76, 2009-01-08 06:21:26-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 + BitKeeper/deleted/.del-sample.c~4c74b15f3881e611@1.2, 2010-02-03 23:50:56+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: arlib/sample.c -> BitKeeper/deleted/.del-sample.c~4c74b15f3881e611 - ntpd/ntpd-opts.h@1.76, 2009-01-08 06:21:27-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P6 + ChangeLog@1.603, 2010-02-03 23:51:51+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + Remove arlib. - ntpd/ntpd-opts.texi@1.75, 2009-01-08 06:21:28-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P6 + Makefile.am@1.91, 2010-02-03 23:51:51+00:00, davehart@shiny.ad.hartbrothers.com +1 -4 + Remove arlib. - ntpd/ntpd.1@1.74, 2009-01-08 06:21:29-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 + configure.ac@1.475, 2010-02-03 23:51:51+00:00, davehart@shiny.ad.hartbrothers.com +7 -13 + Remove arlib, replace --with-arlib handling with deprecation warning. - ntpd/ntpdsim-opts.c@1.76, 2009-01-08 06:21:29-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 +ChangeSet@1.2140, 2010-02-03 05:28:18-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1474] ntp_keygen needs LCRYPTO after libntp.a - ntpd/ntpdsim-opts.h@1.76, 2009-01-08 06:21:30-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P6 + ChangeLog@1.602, 2010-02-03 05:24:58-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1474] ntp_keygen needs LCRYPTO after libntp.a - ntpd/ntpdsim-opts.texi@1.74, 2009-01-08 06:21:31-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P6 + util/Makefile.am@1.49, 2010-02-03 05:25:04-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 1474] ntp_keygen needs LCRYPTO after libntp.a - ntpd/ntpdsim.1@1.74, 2009-01-08 06:21:32-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 +ChangeSet@1.2139, 2010-02-03 04:58:33+00:00, davehart@shiny.ad.hartbrothers.com +41 -0 + [Bug 1455] ntpd does not try /etc/ntp.audio as documented. + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. - ntpdc/ntpdc-opts.c@1.76, 2009-01-08 06:21:33-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 + ChangeLog@1.601, 2010-02-03 04:58:29+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1455] ntpd does not try /etc/ntp.audio as documented. + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. - ntpdc/ntpdc-opts.h@1.76, 2009-01-08 06:21:34-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P6 + lib/isc/win32/interfaceiter.c@1.17, 2010-02-03 04:58:29+00:00, davehart@shiny.ad.hartbrothers.com +11 -8 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). - ntpdc/ntpdc-opts.texi@1.74, 2009-01-08 06:21:34-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P6 + libntp/audio.c@1.27, 2010-02-03 04:58:29+00:00, davehart@shiny.ad.hartbrothers.com +8 -5 + [Bug 1455] ntpd does not try /etc/ntp.audio as documented. + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). - ntpdc/ntpdc.1@1.74, 2009-01-08 06:21:35-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 + libntp/findconfig.c@1.3, 2010-02-03 04:58:29+00:00, davehart@shiny.ad.hartbrothers.com +3 -3 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). - ntpq/ntpq-opts.c@1.78, 2009-01-08 06:21:36-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 + libntp/humandate.c@1.8, 2010-02-03 04:58:29+00:00, davehart@shiny.ad.hartbrothers.com +7 -6 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). - ntpq/ntpq-opts.h@1.78, 2009-01-08 06:21:37-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P6 + libntp/modetoa.c@1.3, 2010-02-03 04:58:29+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). - ntpq/ntpq-opts.texi@1.75, 2009-01-08 06:21:37-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P6 + libntp/prettydate.c@1.13, 2010-02-03 04:58:29+00:00, davehart@shiny.ad.hartbrothers.com +11 -10 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). - ntpq/ntpq.1@1.74, 2009-01-08 06:21:39-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 + libntp/uglydate.c@1.4, 2010-02-03 04:58:29+00:00, davehart@shiny.ad.hartbrothers.com +5 -3 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). - packageinfo.sh@1.105, 2009-01-08 06:21:39-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P6 + libntp/uinttoa.c@1.3, 2010-02-03 04:58:29+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). - sntp/sntp-opts.c@1.74, 2009-01-08 06:21:40-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 + ntpd/ntp_control.c@1.130, 2010-02-03 04:58:29+00:00, davehart@shiny.ad.hartbrothers.com +35 -32 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). - sntp/sntp-opts.h@1.74, 2009-01-08 06:21:41-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P6 + ntpd/refclock_arbiter.c@1.15, 2010-02-03 04:58:29+00:00, davehart@shiny.ad.hartbrothers.com +9 -9 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. - sntp/sntp-opts.texi@1.71, 2009-01-08 06:21:42-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P6 + ntpd/refclock_arc.c@1.22, 2010-02-03 04:58:29+00:00, davehart@shiny.ad.hartbrothers.com +13 -7 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. - sntp/sntp.1@1.74, 2009-01-08 06:21:42-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 + ntpd/refclock_as2201.c@1.11, 2010-02-03 04:58:29+00:00, davehart@shiny.ad.hartbrothers.com +9 -10 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. - util/ntp-keygen-opts.c@1.75, 2009-01-08 06:21:43-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 + ntpd/refclock_atom.c@1.61, 2010-02-03 04:58:29+00:00, davehart@shiny.ad.hartbrothers.com +4 -3 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). - util/ntp-keygen-opts.h@1.75, 2009-01-08 06:21:44-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P6 + ntpd/refclock_bancomm.c@1.12, 2010-02-03 04:58:29+00:00, davehart@shiny.ad.hartbrothers.com +28 -21 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + - util/ntp-keygen-opts.texi@1.73, 2009-01-08 06:21:44-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P6 + ntpd/refclock_chronolog.c@1.9, 2010-02-03 04:58:29+00:00, davehart@shiny.ad.hartbrothers.com +10 -10 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_chu.c@1.46, 2010-02-03 04:58:29+00:00, davehart@shiny.ad.hartbrothers.com +44 -20 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_dumbclock.c@1.14, 2010-02-03 04:58:29+00:00, davehart@shiny.ad.hartbrothers.com +10 -6 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_gpsvme.c@1.8, 2010-02-03 04:58:30+00:00, davehart@shiny.ad.hartbrothers.com +10 -11 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_heath.c@1.15, 2010-02-03 04:58:30+00:00, davehart@shiny.ad.hartbrothers.com +6 -4 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + + ntpd/refclock_hopfpci.c@1.11, 2010-02-03 04:58:30+00:00, davehart@shiny.ad.hartbrothers.com +18 -26 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_hopfser.c@1.14, 2010-02-03 04:58:30+00:00, davehart@shiny.ad.hartbrothers.com +13 -18 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_hpgps.c@1.10, 2010-02-03 04:58:30+00:00, davehart@shiny.ad.hartbrothers.com +9 -10 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_irig.c@1.32, 2010-02-03 04:58:30+00:00, davehart@shiny.ad.hartbrothers.com +11 -11 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_jjy.c@1.18, 2010-02-03 04:58:30+00:00, davehart@shiny.ad.hartbrothers.com +22 -22 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_jupiter.c@1.22, 2010-02-03 04:58:30+00:00, davehart@shiny.ad.hartbrothers.com +6 -10 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_leitch.c@1.11, 2010-02-03 04:58:30+00:00, davehart@shiny.ad.hartbrothers.com +12 -3 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + call io_closeclock() on shutdown if io_addclock() succeeded. + + ntpd/refclock_msfees.c@1.13, 2010-02-03 04:58:30+00:00, davehart@shiny.ad.hartbrothers.com +20 -13 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + + ntpd/refclock_mx4200.c@1.25, 2010-02-03 04:58:30+00:00, davehart@shiny.ad.hartbrothers.com +11 -12 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_palisade.c@1.32, 2010-02-03 04:58:30+00:00, davehart@shiny.ad.hartbrothers.com +11 -6 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + + ntpd/refclock_parse.c@1.52, 2010-02-03 04:58:30+00:00, davehart@shiny.ad.hartbrothers.com +3 -3 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + + ntpd/refclock_pcf.c@1.10, 2010-02-03 04:58:30+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + + ntpd/refclock_pst.c@1.10, 2010-02-03 04:58:30+00:00, davehart@shiny.ad.hartbrothers.com +9 -9 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_shm.c@1.21, 2010-02-03 04:58:30+00:00, davehart@shiny.ad.hartbrothers.com +8 -6 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_tpro.c@1.11, 2010-02-03 04:58:30+00:00, davehart@shiny.ad.hartbrothers.com +12 -14 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_trak.c@1.9, 2010-02-03 04:58:30+00:00, davehart@shiny.ad.hartbrothers.com +8 -9 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_wwvb.c@1.23, 2010-02-03 04:58:31+00:00, davehart@shiny.ad.hartbrothers.com +10 -6 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + + ntpq/ntpq-subs.c@1.42, 2010-02-03 04:58:31+00:00, davehart@shiny.ad.hartbrothers.com +28 -22 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + + ntpq/ntpq.c@1.98, 2010-02-03 04:58:31+00:00, davehart@shiny.ad.hartbrothers.com +23 -12 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + + ports/winnt/ntpd/hopf_PCI_io.c@1.7, 2010-02-03 04:58:31+00:00, davehart@shiny.ad.hartbrothers.com +173 -136 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + clean up indent mess. + + ports/winnt/vs2008/libntp/libntp.vcproj@1.25, 2010-02-03 04:58:31+00:00, davehart@shiny.ad.hartbrothers.com +6 -2 + add reference to libntp/audio.c + +ChangeSet@1.2138, 2010-02-02 08:09:04+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1473] "make distcheck" before build can't make sntp/version.m4. + + ChangeLog@1.600, 2010-02-02 08:09:04+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1473] "make distcheck" before build can't make sntp/version.m4. + + Makefile.am@1.90, 2010-02-02 08:09:04+00:00, davehart@shiny.ad.hartbrothers.com +12 -1 + add COPYRIGHT-please target for use by sntp/Makefile.am + minor tweak to COPYRIGHT action to create intermediate file in + build dir not $(srcdir) to minimize parallel VPATH makes + interfering with each other. + add do-nothing action for rule lacking one to avoid any use + of SCCS get default. + + sntp/Makefile.am@1.26, 2010-02-02 08:09:04+00:00, davehart@shiny.ad.hartbrothers.com +34 -5 + [Bug 1473] "make distcheck" before build can't make sntp/version.m4. + add targets for autogen-version.def, version.def, version.m4, and + version.texi which invoke a submake on the corresponding check-* + targets, avoiding an explicit dependency which would cause Autogen + to be invoked to make sntp-opts.h, which would be considered out- + of-date because version.def is, and version,def because it depends + on non-existent check-version.def. The submake ensures the check + action is taken without introducing the troublesome dependency. + use "cd .. && $(MAKE) COPYRIGHT-please" to work around quirk with + FreeBSD 6.x make which fails with "make COPYRIGHT" when + "make ./COPYRIGHT" would work. - util/ntp-keygen.1@1.73, 2009-01-08 06:21:45-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 +ChangeSet@1.2137, 2010-02-02 01:29:56+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + Makefile.am: + keyword-gen-utd is intended to have one line of content. -ChangeSet@1.1548, 2009-01-08 04:49:23-05:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P5 - TAG: NTP_4_2_4P5 + ntpd/Makefile.am@1.87, 2010-02-02 01:28:58+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + keyword-gen-utd is intended to have one line of content. - ChangeLog@1.49, 2009-01-08 04:48:59-05:00, stenn@whimsy.udel.edu +1 -0 - NTP_4_2_4P5 +ChangeSet@1.2136, 2010-02-01 01:56:41+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1470] "make distdir" in $srcdir builds keyword-gen, libntp.a. - ntpd/ntpd-opts.c@1.75, 2009-01-08 04:49:01-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + ChangeLog@1.599, 2010-02-01 01:56:41+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1470] "make distdir" in $srcdir builds keyword-gen, libntp.a. - ntpd/ntpd-opts.h@1.75, 2009-01-08 04:49:01-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + bootstrap@1.31, 2010-02-01 01:56:41+00:00, davehart@shiny.ad.hartbrothers.com +5 -6 + add ntpd/keyword-gen.out to touch targets, at same time as ntp_parser.h. - ntpd/ntpd-opts.texi@1.74, 2009-01-08 04:49:03-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ntpd/Makefile.am@1.86, 2010-02-01 01:56:41+00:00, davehart@shiny.ad.hartbrothers.com +41 -26 + [Bug 1470] "make distdir" in $srcdir builds keyword-gen, libntp.a. + Avoid building keyword-gen if its output is up-to-date in general. - ntpd/ntpd.1@1.73, 2009-01-08 04:49:03-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ntpd/keyword-gen-utd@1.1, 2010-02-01 01:55:44+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + intermediate Makefile target used in avoiding building keyword-gen + after bootstrap or from tarball unless sources change, necessary + to ensure "make distdir" can succeed before compiling without + compiling. See [Bug 1470]. - ntpd/ntpdsim-opts.c@1.75, 2009-01-08 04:49:04-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + ntpd/keyword-gen-utd@1.0, 2010-02-01 01:55:44+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 - ntpd/ntpdsim-opts.h@1.75, 2009-01-08 04:49:04-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 +ChangeSet@1.2135, 2010-01-30 18:06:35-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1467] Fix bogus rebuild of sntp/sntp.html - ntpd/ntpdsim-opts.texi@1.73, 2009-01-08 04:49:05-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + ChangeLog@1.598, 2010-01-30 18:06:02-05:00, stenn@whimsy.udel.edu +4 -0 + [Bug 1467] Fix bogus rebuild of sntp/sntp.html - ntpd/ntpdsim.1@1.73, 2009-01-08 04:49:06-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + bootstrap@1.30, 2010-01-30 18:06:03-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 1467] Fix bogus rebuild of sntp/sntp.html - ntpdc/ntpdc-opts.c@1.75, 2009-01-08 04:49:06-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 +ChangeSet@1.2134, 2010-01-24 10:31:32+00:00, stenn@whimsy.udel.edu +27 -0 + NTP_4_2_6P1_RC3 + TAG: NTP_4_2_6P1_RC3 - ntpdc/ntpdc-opts.h@1.75, 2009-01-08 04:49:07-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + ChangeLog@1.597, 2010-01-24 10:31:16+00:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_6P1_RC3 - ntpdc/ntpdc-opts.texi@1.73, 2009-01-08 04:49:08-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ntpd/ntpd-opts.c@1.251, 2010-01-24 10:31:17+00:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_6P1_RC3 - ntpdc/ntpdc.1@1.73, 2009-01-08 04:49:09-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ntpd/ntpd-opts.h@1.251, 2010-01-24 10:31:17+00:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_6P1_RC3 - ntpq/ntpq-opts.c@1.77, 2009-01-08 04:49:10-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + ntpd/ntpd-opts.texi@1.249, 2010-01-24 10:31:18+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC3 - ntpq/ntpq-opts.h@1.77, 2009-01-08 04:49:10-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + ntpd/ntpd.1@1.249, 2010-01-24 10:31:18+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC3 - ntpq/ntpq-opts.texi@1.74, 2009-01-08 04:49:11-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ntpdc/ntpdc-opts.c@1.247, 2010-01-24 10:31:19+00:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_6P1_RC3 - ntpq/ntpq.1@1.73, 2009-01-08 04:49:12-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ntpdc/ntpdc-opts.h@1.247, 2010-01-24 10:31:19+00:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_6P1_RC3 - packageinfo.sh@1.104, 2009-01-08 04:49:13-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ntpdc/ntpdc-opts.texi@1.246, 2010-01-24 10:31:19+00:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC3 - sntp/sntp-opts.c@1.73, 2009-01-08 04:49:14-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + ntpdc/ntpdc.1@1.246, 2010-01-24 10:31:20+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC3 - sntp/sntp-opts.h@1.73, 2009-01-08 04:49:15-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + ntpq/ntpq-opts.c@1.248, 2010-01-24 10:31:20+00:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_6P1_RC3 - sntp/sntp-opts.texi@1.70, 2009-01-08 04:49:16-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + ntpq/ntpq-opts.h@1.248, 2010-01-24 10:31:21+00:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_6P1_RC3 - sntp/sntp.1@1.73, 2009-01-08 04:49:17-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ntpq/ntpq-opts.texi@1.247, 2010-01-24 10:31:21+00:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC3 - util/ntp-keygen-opts.c@1.74, 2009-01-08 04:49:18-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + ntpq/ntpq.1@1.247, 2010-01-24 10:31:21+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC3 - util/ntp-keygen-opts.h@1.74, 2009-01-08 04:49:19-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + ntpsnmpd/ntpsnmpd-opts.c@1.126, 2010-01-24 10:31:22+00:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_6P1_RC3 - util/ntp-keygen-opts.texi@1.72, 2009-01-08 04:49:20-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ntpsnmpd/ntpsnmpd-opts.h@1.126, 2010-01-24 10:31:22+00:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_6P1_RC3 - util/ntp-keygen.1@1.72, 2009-01-08 04:49:20-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ntpsnmpd/ntpsnmpd-opts.texi@1.126, 2010-01-24 10:31:23+00:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC3 -ChangeSet@1.1547, 2009-01-08 03:21:09-05:00, stenn@whimsy.udel.edu +1 -0 - 4.2.4p6 + ntpsnmpd/ntpsnmpd.1@1.125, 2010-01-24 10:31:23+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC3 - packageinfo.sh@1.103, 2009-01-08 03:20:56-05:00, stenn@whimsy.udel.edu +1 -1 - 4.2.4p6 + packageinfo.sh@1.262, 2010-01-24 10:31:23+00:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_6P1_RC3 -ChangeSet@1.1546, 2009-01-08 03:14:17-05:00, stenn@whimsy.udel.edu +1 -0 - merge cleanup + sntp/sntp-opts.c@1.120, 2010-01-24 10:31:24+00:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_6P1_RC3 - ChangeLog@1.48, 2009-01-08 03:14:09-05:00, stenn@whimsy.udel.edu +1 -1 - merge cleanup + sntp/sntp-opts.h@1.120, 2010-01-24 10:31:24+00:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_6P1_RC3 -ChangeSet@1.1543.1.1, 2009-01-08 02:57:52-05:00, stenn@whimsy.udel.edu +5 -0 - 4.2.4p6 + sntp/sntp-opts.texi@1.120, 2010-01-24 10:31:25+00:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC3 - ChangeLog@1.46, 2009-01-07 05:31:52-05:00, stenn@whimsy.udel.edu +6 -0 - Fix incorrect check of EVP_VerifyFinal()'s return value. + sntp/sntp.1@1.120, 2010-01-24 10:31:25+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC3 - NEWS@1.100, 2009-01-08 02:57:32-05:00, stenn@whimsy.udel.edu +16 -0 - 4.2.4p6 + sntp/sntp.html@1.10, 2010-01-24 10:31:25+00:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_6P1_RC3 - html/copyright.html@1.38, 2009-01-07 05:30:58-05:00, stenn@whimsy.udel.edu +1 -1 - Update the copyright year + util/ntp-keygen-opts.c@1.250, 2010-01-24 10:31:26+00:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_6P1_RC3 - ntpd/ntp_crypto.c@1.108, 2009-01-07 05:31:50-05:00, stenn@whimsy.udel.edu +1 -1 - Fix incorrect check of EVP_VerifyFinal()'s return value. + util/ntp-keygen-opts.h@1.250, 2010-01-24 10:31:26+00:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_6P1_RC3 - packageinfo.sh@1.102, 2009-01-08 02:57:33-05:00, stenn@whimsy.udel.edu +1 -1 - 4.2.4p6 + util/ntp-keygen-opts.texi@1.249, 2010-01-24 10:31:27+00:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC3 -ChangeSet@1.1544, 2009-01-07 18:00:50+01:00, burnicki@pogo.udel.edu +2 -0 - [BUG 1113] Fixed build errors with recent versions of openSSL. + util/ntp-keygen.1@1.249, 2010-01-24 10:31:27+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC3 - ChangeLog@1.45.1.1, 2009-01-07 18:00:47+01:00, burnicki@pogo.udel.edu +1 -0 - [BUG 1113] Fixed build errors with recent versions of openSSL. +ChangeSet@1.2133, 2010-01-24 03:49:59-05:00, stenn@whimsy.udel.edu +2 -0 + Use TZ=UTC instead of TZ= when calling date in scripts/mkver.in - ntpd/ntp_crypto.c@1.107.1.1, 2009-01-07 18:00:47+01:00, burnicki@pogo.udel.edu +2 -2 - [BUG 1113] Fixed build errors with recent versions of openSSL. + ChangeLog@1.596, 2010-01-24 03:49:45-05:00, stenn@whimsy.udel.edu +4 -3 + Use TZ=UTC instead of TZ= when calling date in scripts/mkver.in -ChangeSet@1.1543, 2008-08-17 06:21:39-04:00, stenn@whimsy.udel.edu +1 -0 - typo + scripts/mkver.in@1.12, 2010-01-24 03:49:44-05:00, stenn@whimsy.udel.edu +1 -1 + Use TZ=UTC instead of TZ= when calling date in scripts/mkver.in - scripts/addChangeLogTag@1.3, 2008-08-17 06:21:25-04:00, stenn@whimsy.udel.edu +0 -3 - typo +ChangeSet@1.2132, 2010-01-24 03:44:05-05:00, stenn@whimsy.udel.edu +1 -0 + cleanup -ChangeSet@1.1542, 2008-08-17 06:16:19-04:00, stenn@whimsy.udel.edu +1 -0 - typo + ChangeLog@1.595, 2010-01-24 03:43:54-05:00, stenn@whimsy.udel.edu +2 -2 + cleanup - ChangeLog@1.45, 2008-08-17 06:16:08-04:00, stenn@whimsy.udel.edu +0 -2 - typo +ChangeSet@1.2131, 2010-01-24 03:39:27-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1449] SLEW is no longer needed by the simulator -ChangeSet@1.1541, 2008-08-17 05:30:47-04:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P5 - TAG: NTP_4_2_4P5 + include/ntpsim.h@1.13, 2010-01-24 03:38:33-05:00, stenn@whimsy.udel.edu +0 -1 + [Bug 1449] SLEW is no longer needed by the simulator - ChangeLog@1.44, 2008-08-17 05:30:27-04:00, stenn@whimsy.udel.edu +3 -0 - NTP_4_2_4P5 +ChangeSet@1.2130, 2010-01-23 23:09:00-05:00, mayer@pogo.udel.edu +1 -0 + Bad inputdir reference - ntpd/ntpd-opts.c@1.74, 2008-08-17 05:30:28-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ports/winnt/vc6/libntp.dsp@1.52, 2010-01-23 23:08:40-05:00, mayer@pogo.udel.edu +1 -1 + Bad inputdir reference - ntpd/ntpd-opts.h@1.74, 2008-08-17 05:30:28-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5 +ChangeSet@1.2129, 2010-01-22 11:49:48+01:00, burnicki@pogo.udel.edu +1 -0 + Create the instserv binaries in the correct directories. - ntpd/ntpd-opts.texi@1.73, 2008-08-17 05:30:29-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + ports/winnt/vc6/Instsrv.dsp@1.12, 2010-01-22 11:49:47+01:00, burnicki@pogo.udel.edu +2 -2 + Create the instserv binaries in the correct directories. - ntpd/ntpd.1@1.72, 2008-08-17 05:30:30-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 +ChangeSet@1.2128, 2010-01-21 23:37:23-05:00, mayer@pogo.udel.edu +1 -0 + Remove ipv6.c as unnecessary - ntpd/ntpdsim-opts.c@1.74, 2008-08-17 05:30:30-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ports/winnt/vc6/libntp.dsp@1.51, 2010-01-21 23:36:43-05:00, mayer@pogo.udel.edu +0 -4 + Remove ipv6.c as unnecessary - ntpd/ntpdsim-opts.h@1.74, 2008-08-17 05:30:31-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5 +ChangeSet@1.2127, 2010-01-17 22:28:21-05:00, mayer@pogo.udel.edu +1 -0 + Temporarily include ntpsim.h unconditionally - ntpd/ntpdsim-opts.texi@1.72, 2008-08-17 05:30:32-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + ntpd/ntp_config.c@1.243, 2010-01-17 22:27:47-05:00, mayer@pogo.udel.edu +5 -2 + Temporarily include ntpsim.h unconditionally - ntpd/ntpdsim.1@1.72, 2008-08-17 05:30:33-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 +ChangeSet@1.2125, 2010-01-16 23:20:10-05:00, mayer@pogo.udel.edu +2 -0 + [Bug 1448] Additional fixes for Windows VC6 - ntpdc/ntpdc-opts.c@1.74, 2008-08-17 05:30:33-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + lib/isc/win32/net.c@1.14, 2010-01-16 23:19:28-05:00, mayer@pogo.udel.edu +2 -2 + [Bug 1448] Additional fixes for Windows VC6 - ntpdc/ntpdc-opts.h@1.74, 2008-08-17 05:30:34-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5 + ports/winnt/vc6/libntp.dsp@1.50, 2010-01-16 23:19:28-05:00, mayer@pogo.udel.edu +23 -15 + [Bug 1448] Additional fixes for Windows VC6 - ntpdc/ntpdc-opts.texi@1.72, 2008-08-17 05:30:34-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 +ChangeSet@1.2122.2.3, 2010-01-08 19:11:53+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + Makefile.am: + add dependencies on copyright.def + correct dependencies to refer to $(srcdir)/version.def not + $(srcdir)/../include/version.def + add COPYRIGHT to BUILT_SOURCES, correct EXTRA_DIST reference to + remove unneeded $(srcdir)/ prefix + + sntp/Makefile.am@1.25, 2010-01-08 19:11:53+00:00, davehart@shiny.ad.hartbrothers.com +5 -4 + add dependencies on copyright.def + correct dependencies to refer to $(srcdir)/version.def not + $(srcdir)/../include/version.def + add COPYRIGHT to BUILT_SOURCES, correct EXTRA_DIST reference to + remove unneeded $(srcdir)/ prefix + +ChangeSet@1.2122.2.2, 2010-01-08 17:21:14+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + bump copyright year to 2010 + + html/copyright.html@1.46, 2010-01-08 17:21:14+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + bump copyright year to 2010 + + include/copyright.def@1.11, 2010-01-08 17:21:14+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + bump copyright year to 2010 + +ChangeSet@1.2122.2.1, 2010-01-06 18:52:49+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1453] Use $CC in config.cache filename in ./build script. + + ChangeLog@1.592.2.1, 2010-01-06 18:52:48+00:00, davehart@shiny.ad.hartbrothers.com +4 -3 + [Bug 1453] Use $CC in config.cache filename in ./build script. + + build@1.34, 2010-01-06 18:52:48+00:00, davehart@shiny.ad.hartbrothers.com +26 -27 + [Bug 1453] Use $CC in config.cache filename in ./build script. + +ChangeSet@1.2124, 2010-01-03 23:03:48-05:00, mayer@pogo.udel.edu +1 -0 + Undo unneeded change + + lib/isc/netaddr.c@1.8, 2010-01-03 23:03:02-05:00, mayer@pogo.udel.edu +1 -1 + Undo unneeded change + +ChangeSet@1.2122.1.1, 2010-01-03 21:52:33+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1451] CID 115: sntp leaks KoD entry when updating existing + entry. + + ChangeLog@1.592.1.1, 2010-01-03 21:52:32+00:00, davehart@shiny.ad.hartbrothers.com +4 -3 + [Bug 1451] CID 115: sntp leaks KoD entry when updating existing + entry. + + sntp/kod_management.c@1.16, 2010-01-03 21:52:32+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1451] CID 115: sntp leaks KoD entry when updating existing + entry. + +ChangeSet@1.2123, 2010-01-01 23:49:35-05:00, mayer@pogo.udel.edu +7 -0 + Fixes for bugs 1448-1450 + + ChangeLog@1.593, 2010-01-01 23:48:44-05:00, mayer@pogo.udel.edu +4 -0 + Fixes for bug 1448-1450 + + lib/isc/netaddr.c@1.7, 2010-01-01 23:41:53-05:00, mayer@pogo.udel.edu +1 -1 + [Bug 1448] scope_id and ipv6 any address not defined on vc6 compiler + + lib/isc/win32/include/isc/platform.h@1.7, 2010-01-01 23:38:16-05:00, mayer@pogo.udel.edu +2 -2 + [Bug 1448] Macros not correctly conditionally defined + + lib/isc/win32/interfaceiter.c@1.16, 2010-01-01 23:41:53-05:00, mayer@pogo.udel.edu +2 -0 + [Bug 1448] scope_id and ipv6 any address not defined on vc6 compiler + + ntpd/ntp_config.c@1.242, 2010-01-01 23:44:35-05:00, mayer@pogo.udel.edu +3 -1 + [Bug 1449] ntpsim.h should only be conditionally included and after ntpd-opts.h + + ports/winnt/include/config.h@1.80, 2010-01-01 23:38:15-05:00, mayer@pogo.udel.edu +2 -2 + [Bug 1448] Macros not correctly conditionally defined + + ports/winnt/vc6/libntp.dsp@1.49, 2010-01-01 23:39:14-05:00, mayer@pogo.udel.edu +0 -4 + [Bug 1448] stdtime.c misspelled but not needed at all + +ChangeSet@1.2122, 2009-12-30 05:48:36+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + With EXTRA_DIST fix from [Bug 1446] read-only $(srcdir) hacks in + *.1, *.texi, and *.html Makefile rules are not needed. + + ntpd/Makefile.am@1.85, 2009-12-30 05:48:35+00:00, davehart@shiny.ad.hartbrothers.com +2 -9 + With EXTRA_DIST fix from [Bug 1446] read-only $(srcdir) hacks in + *.1, *.texi, and *.html rules are not needed. + + ntpdc/Makefile.am@1.51, 2009-12-30 05:48:35+00:00, davehart@shiny.ad.hartbrothers.com +2 -9 + With EXTRA_DIST fix from [Bug 1446] read-only $(srcdir) hacks in + *.1, *.texi, and *.html rules are not needed. + + ntpq/Makefile.am@1.46, 2009-12-30 05:48:35+00:00, davehart@shiny.ad.hartbrothers.com +2 -9 + With EXTRA_DIST fix from [Bug 1446] read-only $(srcdir) hacks in + *.1, *.texi, and *.html rules are not needed. + + ntpsnmpd/Makefile.am@1.19, 2009-12-30 05:48:35+00:00, davehart@shiny.ad.hartbrothers.com +2 -9 + With EXTRA_DIST fix from [Bug 1446] read-only $(srcdir) hacks in + *.1, *.texi, and *.html rules are not needed. + + sntp/Makefile.am@1.24, 2009-12-30 05:48:35+00:00, davehart@shiny.ad.hartbrothers.com +3 -12 + With EXTRA_DIST fix from [Bug 1446] read-only $(srcdir) hacks in + *.1, *.texi, and *.html rules are not needed. + + util/Makefile.am@1.48, 2009-12-30 05:48:35+00:00, davehart@shiny.ad.hartbrothers.com +2 -9 + With EXTRA_DIST fix from [Bug 1446] read-only $(srcdir) hacks in + *.1, *.texi, and *.html rules are not needed. + +ChangeSet@1.2121, 2009-12-30 00:23:25+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1446] 4.2.7p6 requires autogen to build missing ntpd.1, *.texi, *.menu. + + ntpd/Makefile.am@1.84, 2009-12-30 00:23:24+00:00, davehart@shiny.ad.hartbrothers.com +4 -1 + [Bug 1446] 4.2.7p6 requires autogen to build missing ntpd.1, *.texi, *.menu. + +ChangeSet@1.2120, 2009-12-28 04:17:49-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1445] IRIX does not have -lcap or support linux capabilities + + ChangeLog@1.592, 2009-12-28 04:17:38-05:00, stenn@whimsy.udel.edu +2 -1 + [Bug 1445] IRIX does not have -lcap or support linux capabilities + + configure.ac@1.474, 2009-12-28 04:17:38-05:00, stenn@whimsy.udel.edu +7 -1 + [Bug 1445] IRIX does not have -lcap or support linux capabilities + +ChangeSet@1.2115.1.1, 2009-12-27 09:16:20+00:00, davehart@shiny.ad.hartbrothers.com +8 -0 + [Bug 1439] .texi generation must wait until after binary is linked. + Quiet RES_TIMEOUT redefinition warning compiling ntp_intres.c + + ChangeLog@1.587.1.1, 2009-12-27 09:16:18+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1439] .texi generation must wait until after binary is linked. + + ntpd/Makefile.am@1.83, 2009-12-27 09:16:18+00:00, davehart@shiny.ad.hartbrothers.com +16 -10 + remove *.texi *.menu *.html *.1 from BUILT_SOURCES, add all except .1 + to noinst_DATA, and remove sub-make hack to build binary [Bug 1439]. + change man_MANS= reference to .1 to have $(srcdir)/ prefix, work around + make distcheck R/O srcdir in .1 and ,texi rules. + separate .menu rule from .texi to avoid redundant Autogen invocation. + + ntpd/ntp_intres.c@1.79, 2009-12-27 09:16:19+00:00, davehart@shiny.ad.hartbrothers.com +7 -3 + follow AC_HEADER_RESOLV suggestion to include sys/types.h ahead + of netinet/in.h + quiet RES_TIMEOUT redefinition warning (resolv.h vs. ntp.h) + + ntpdc/Makefile.am@1.50, 2009-12-27 09:16:19+00:00, davehart@shiny.ad.hartbrothers.com +17 -10 + remove *.texi *.menu *.html *.1 from BUILT_SOURCES, add all except .1 + to noinst_DATA, and remove sub-make hack to build binary [Bug 1439]. + change man_MANS= reference to .1 to have $(srcdir)/ prefix, work around + make distcheck R/O srcdir in .1 and ,texi rules. + separate .menu rule from .texi to avoid redundant Autogen invocation. + + ntpq/Makefile.am@1.45, 2009-12-27 09:16:19+00:00, davehart@shiny.ad.hartbrothers.com +17 -10 + remove *.texi *.menu *.html *.1 from BUILT_SOURCES, add all except .1 + to noinst_DATA, and remove sub-make hack to build binary [Bug 1439]. + change man_MANS= reference to .1 to have $(srcdir)/ prefix, work around + make distcheck R/O srcdir in .1 and ,texi rules. + separate .menu rule from .texi to avoid redundant Autogen invocation. + + ntpsnmpd/Makefile.am@1.18, 2009-12-27 09:16:19+00:00, davehart@shiny.ad.hartbrothers.com +17 -12 + remove *.texi *.menu *.html *.1 from BUILT_SOURCES, add all except .1 + to noinst_DATA, and remove sub-make hack to build binary [Bug 1439]. + change man_MANS= reference to .1 to have $(srcdir)/ prefix, work around + make distcheck R/O srcdir in .1 and ,texi rules. + separate .menu rule from .texi to avoid redundant Autogen invocation. + + sntp/Makefile.am@1.23, 2009-12-27 09:16:19+00:00, davehart@shiny.ad.hartbrothers.com +26 -23 + remove *.texi *.menu *.html *.1 from BUILT_SOURCES, add all except .1 + to noinst_DATA, and remove sub-make hack to build binary [Bug 1439]. + change man_MANS= reference to .1 to have $(srcdir)/ prefix, work around + make distcheck R/O srcdir in .1, .texi, and .html rules. + separate .menu rule from .texi to avoid redundant Autogen invocation. + + util/Makefile.am@1.47, 2009-12-27 09:16:19+00:00, davehart@shiny.ad.hartbrothers.com +17 -9 + remove *.texi *.menu *.html *.1 from BUILT_SOURCES, add all except .1 + to noinst_DATA, and remove sub-make hack to build binary [Bug 1439]. + change man_MANS= reference to .1 to have $(srcdir)/ prefix, work around + make distcheck R/O srcdir in .1 and ,texi rules. + separate .menu rule from .texi to avoid redundant Autogen invocation. - ntpdc/ntpdc.1@1.72, 2008-08-17 05:30:35-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 +ChangeSet@1.2118, 2009-12-27 01:54:07-05:00, stenn@whimsy.udel.edu +1 -0 + cleanup - ntpq/ntpq-opts.c@1.76, 2008-08-17 05:30:35-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ChangeLog@1.590, 2009-12-27 01:53:58-05:00, stenn@whimsy.udel.edu +5 -2 + cleanup - ntpq/ntpq-opts.h@1.76, 2008-08-17 05:30:36-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5 +ChangeSet@1.2117, 2009-12-27 01:47:48-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1440] Update configure.ac to support kfreebsd - ntpq/ntpq-opts.texi@1.73, 2008-08-17 05:30:36-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + ChangeLog@1.589, 2009-12-27 01:47:30-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1440] Update configure.ac to support kfreebsd - ntpq/ntpq.1@1.72, 2008-08-17 05:30:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + configure.ac@1.473, 2009-12-27 01:47:32-05:00, stenn@whimsy.udel.edu +12 -0 + [Bug 1440] Update configure.ac to support kfreebsd - packageinfo.sh@1.101, 2008-08-17 05:30:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 +ChangeSet@1.2116, 2009-12-27 00:40:27-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1127] Properly check the return of X590_verify() - missed one - sntp/sntp-opts.c@1.72, 2008-08-17 05:30:38-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ChangeLog@1.588, 2009-12-27 00:39:31-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1127] Properly check the return of X590_verify() - missed one - sntp/sntp-opts.h@1.72, 2008-08-17 05:30:39-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5 + util/ntp-keygen.c@1.64, 2009-12-27 00:39:31-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 1127] Properly check the return of X590_verify() - missed one - sntp/sntp-opts.texi@1.69, 2008-08-17 05:30:39-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 +ChangeSet@1.2115, 2009-12-25 09:31:42+00:00, stenn@whimsy.udel.edu +27 -0 + NTP_4_2_6P1_RC2 + TAG: NTP_4_2_6P1_RC2 - sntp/sntp.1@1.72, 2008-08-17 05:30:40-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ChangeLog@1.587, 2009-12-25 09:31:32+00:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_6P1_RC2 - util/ntp-keygen-opts.c@1.73, 2008-08-17 05:30:40-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ntpd/ntpd-opts.c@1.250, 2009-12-25 09:31:32+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC2 - util/ntp-keygen-opts.h@1.73, 2008-08-17 05:30:41-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5 + ntpd/ntpd-opts.h@1.250, 2009-12-25 09:31:32+00:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC2 - util/ntp-keygen-opts.texi@1.71, 2008-08-17 05:30:42-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + ntpd/ntpd-opts.texi@1.248, 2009-12-25 09:31:33+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC2 - util/ntp-keygen.1@1.71, 2008-08-17 05:30:42-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ntpd/ntpd.1@1.248, 2009-12-25 09:31:33+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC2 -ChangeSet@1.1540, 2008-08-17 05:29:47-04:00, stenn@whimsy.udel.edu +1 -0 - typo + ntpdc/ntpdc-opts.c@1.246, 2009-12-25 09:31:33+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC2 - scripts/addChangeLogTag@1.2, 2008-08-17 05:29:37-04:00, stenn@whimsy.udel.edu +1 -1 - typo + ntpdc/ntpdc-opts.h@1.246, 2009-12-25 09:31:33+00:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC2 -ChangeSet@1.1539, 2008-08-17 03:28:53-04:00, stenn@whimsy.udel.edu +5 -0 - 4.2.4p5 prep + ntpdc/ntpdc-opts.texi@1.245, 2009-12-25 09:31:33+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC2 - .point-changed-filelist@1.2, 2008-08-17 03:27:42-04:00, stenn@whimsy.udel.edu +1 -0 - 4.2.4p5 prep + ntpdc/ntpdc.1@1.245, 2009-12-25 09:31:34+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC2 - NEWS@1.99, 2008-08-17 03:27:42-04:00, stenn@whimsy.udel.edu +17 -0 - 4.2.4p5 prep + ntpq/ntpq-opts.c@1.247, 2009-12-25 09:31:34+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC2 - packageinfo.sh@1.100, 2008-08-17 03:27:43-04:00, stenn@whimsy.udel.edu +1 -1 - 4.2.4p5 prep + ntpq/ntpq-opts.h@1.247, 2009-12-25 09:31:34+00:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC2 - scripts/addChangeLogTag@1.1, 2008-08-17 03:27:55-04:00, stenn@whimsy.udel.edu +27 -0 - BitKeeper file /deacon/backroom/ntp-stable/scripts/addChangeLogTag + ntpq/ntpq-opts.texi@1.246, 2009-12-25 09:31:34+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC2 - scripts/addChangeLogTag@1.0, 2008-08-17 03:27:55-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq.1@1.246, 2009-12-25 09:31:35+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC2 - scripts/genChangeLogTag@1.1, 2008-08-17 03:27:55-04:00, stenn@whimsy.udel.edu +6 -0 - BitKeeper file /deacon/backroom/ntp-stable/scripts/genChangeLogTag + ntpsnmpd/ntpsnmpd-opts.c@1.125, 2009-12-25 09:31:35+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC2 - scripts/genChangeLogTag@1.0, 2008-08-17 03:27:55-04:00, stenn@whimsy.udel.edu +0 -0 + ntpsnmpd/ntpsnmpd-opts.h@1.125, 2009-12-25 09:31:35+00:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC2 -ChangeSet@1.1538, 2008-08-16 22:42:08-04:00, stenn@whimsy.udel.edu +2 -0 - [BUG 1051] Month off by one in leap second message written to clockstats + ntpsnmpd/ntpsnmpd-opts.texi@1.125, 2009-12-25 09:31:35+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC2 - ChangeLog@1.43, 2008-08-16 22:41:50-04:00, stenn@whimsy.udel.edu +2 -0 - [BUG 1051] Month off by one in leap second message written to clockstats + ntpsnmpd/ntpsnmpd.1@1.124, 2009-12-25 09:31:36+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC2 - ntpd/refclock_oncore.c@1.63, 2008-08-16 22:41:50-04:00, stenn@whimsy.udel.edu +1 -1 - [BUG 1051] Month off by one in leap second message written to clockstats + packageinfo.sh@1.261, 2009-12-25 09:31:36+00:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_6P1_RC2 -ChangeSet@1.1537, 2008-08-10 07:44:31-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P5_RC2 - TAG: NTP_4_2_4P5_RC2 + sntp/sntp-opts.c@1.119, 2009-12-25 09:31:36+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC2 - ntpd/ntpd-opts.c@1.73, 2008-08-10 07:44:09-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC2 + sntp/sntp-opts.h@1.119, 2009-12-25 09:31:36+00:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC2 - ntpd/ntpd-opts.h@1.73, 2008-08-10 07:44:09-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5_RC2 + sntp/sntp-opts.texi@1.119, 2009-12-25 09:31:37+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC2 - ntpd/ntpd-opts.texi@1.72, 2008-08-10 07:44:10-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5_RC2 + sntp/sntp.1@1.119, 2009-12-25 09:31:37+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC2 - ntpd/ntpd.1@1.71, 2008-08-10 07:44:10-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC2 + sntp/sntp.html@1.9, 2009-12-25 09:31:37+00:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_6P1_RC2 - ntpd/ntpdsim-opts.c@1.73, 2008-08-10 07:44:11-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC2 + util/ntp-keygen-opts.c@1.249, 2009-12-25 09:31:37+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC2 - ntpd/ntpdsim-opts.h@1.73, 2008-08-10 07:44:12-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5_RC2 + util/ntp-keygen-opts.h@1.249, 2009-12-25 09:31:38+00:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC2 - ntpd/ntpdsim-opts.texi@1.71, 2008-08-10 07:44:12-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5_RC2 + util/ntp-keygen-opts.texi@1.248, 2009-12-25 09:31:38+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC2 - ntpd/ntpdsim.1@1.71, 2008-08-10 07:44:13-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC2 + util/ntp-keygen.1@1.248, 2009-12-25 09:31:38+00:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC2 - ntpdc/ntpdc-opts.c@1.73, 2008-08-10 07:44:14-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC2 +ChangeSet@1.2112.1.1, 2009-12-25 00:19:40-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1435] sntp: Test for -lresolv using the same tests as in ntp - ntpdc/ntpdc-opts.h@1.73, 2008-08-10 07:44:15-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5_RC2 + ChangeLog@1.584.1.1, 2009-12-25 00:19:29-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1435] sntp: Test for -lresolv using the same tests as in ntp - ntpdc/ntpdc-opts.texi@1.71, 2008-08-10 07:44:16-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5_RC2 + sntp/configure.ac@1.29.1.1, 2009-12-25 00:19:29-05:00, stenn@whimsy.udel.edu +3 -0 + [Bug 1435] sntp: Test for -lresolv using the same tests as in ntp - ntpdc/ntpdc.1@1.71, 2008-08-10 07:44:17-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC2 +ChangeSet@1.2113, 2009-12-24 22:04:26+00:00, davehart@shiny.ad.hartbrothers.com +8 -0 + [Bug 1425] unpeer by association ID sets up for duplicate free(). + [Bug 1434] HP-UX 11 ip_mreq undeclared, _HPUX_SOURCE helps some. + Use HAVE_WORKING_FORK instead of HAVE_FORK to avoid broken fork(). - ntpq/ntpq-opts.c@1.75, 2008-08-10 07:44:17-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC2 + ChangeLog@1.585, 2009-12-24 22:04:25+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1425] unpeer by association ID sets up for duplicate free(). + [Bug 1434] HP-UX 11 ip_mreq undeclared, _HPUX_SOURCE helps some. - ntpq/ntpq-opts.h@1.75, 2008-08-10 07:44:18-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5_RC2 + configure.ac@1.472, 2009-12-24 22:04:25+00:00, davehart@shiny.ad.hartbrothers.com +50 -29 + [Bug 1434] HP-UX 11 ip_mreq undeclared, _HPUX_SOURCE helps some. - ntpq/ntpq-opts.texi@1.72, 2008-08-10 07:44:19-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5_RC2 + include/ntp_intres.h@1.2, 2009-12-24 22:04:25+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + Use HAVE_WORKING_FORK instead of HAVE_FORK preemptively, some rare + systems have a broken fork() - ntpq/ntpq.1@1.71, 2008-08-10 07:44:20-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC2 + m4/os_cflags.m4@1.6, 2009-12-24 22:04:25+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1434] HP-UX 11 ip_mreq undeclared, _HPUX_SOURCE helps some. - packageinfo.sh@1.99, 2008-08-10 07:44:20-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5_RC2 + ntpd/ntp_config.c@1.241, 2009-12-24 22:04:25+00:00, davehart@shiny.ad.hartbrothers.com +0 -2 + [Bug 1425] unpeer by association ID sets up for duplicate free(). - sntp/sntp-opts.c@1.71, 2008-08-10 07:44:22-04:00, stenn@whimsy.udel.edu +4 -5 - NTP_4_2_4P5_RC2 + ntpsnmpd/netsnmp_daemonize.c@1.2, 2009-12-24 22:04:25+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + Use HAVE_WORKING_FORK instead of HAVE_FORK preemptively, some rare + systems have a broken fork() - sntp/sntp-opts.h@1.71, 2008-08-10 07:44:23-04:00, stenn@whimsy.udel.edu +5 -6 - NTP_4_2_4P5_RC2 + sntp/configure.ac@1.30, 2009-12-24 22:04:25+00:00, davehart@shiny.ad.hartbrothers.com +53 -0 + [Bug 1434] HP-UX 11 ip_mreq undeclared, _HPUX_SOURCE helps some. - sntp/sntp-opts.texi@1.68, 2008-08-10 07:44:23-04:00, stenn@whimsy.udel.edu +2 -3 - NTP_4_2_4P5_RC2 + sntp/networking.c@1.29, 2009-12-24 22:04:25+00:00, davehart@shiny.ad.hartbrothers.com +7 -1 + [Bug 1434] HP-UX 11 ip_mreq undeclared, _HPUX_SOURCE helps some. - sntp/sntp.1@1.71, 2008-08-10 07:44:24-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5_RC2 +ChangeSet@1.2110.1.1, 2009-12-24 02:27:39-05:00, stenn@deacon.udel.edu +6 -0 + System headers must come before ntp headers in ntp_intres.c - util/ntp-keygen-opts.c@1.72, 2008-08-10 07:44:25-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC2 + ChangeLog@1.582.1.1, 2009-12-24 02:25:49-05:00, stenn@deacon.udel.edu +1 -0 + System headers must come before ntp headers in ntp_intres.c - util/ntp-keygen-opts.h@1.72, 2008-08-10 07:44:25-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5_RC2 + include/Makefile.am@1.38, 2009-12-24 02:25:55-05:00, stenn@deacon.udel.edu +1 -0 + System headers must come before ntp headers in ntp_intres.c - util/ntp-keygen-opts.texi@1.70, 2008-08-10 07:44:27-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5_RC2 + include/ntp_config.h@1.67, 2009-12-24 02:25:57-05:00, stenn@deacon.udel.edu +0 -10 + System headers must come before ntp headers in ntp_intres.c - util/ntp-keygen.1@1.70, 2008-08-10 07:44:27-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC2 + include/ntp_intres.h@1.1, 2009-12-24 02:08:32-05:00, stenn@deacon.udel.edu +14 -0 + BitKeeper file /deacon/backroom/ntp-stable/include/ntp_intres.h -ChangeSet@1.1531.3.1, 2008-08-10 02:22:22-04:00, stenn@whimsy.udel.edu +1 -0 - triggert needs to handle rooted RESYNC paths now + include/ntp_intres.h@1.0, 2009-12-24 02:08:32-05:00, stenn@deacon.udel.edu +0 -0 - BitKeeper/triggers/triggert@1.5, 2008-08-10 02:22:11-04:00, stenn@whimsy.udel.edu +3 -2 - triggert needs to handle rooted RESYNC paths now + ntpd/ntp_config.c@1.238.1.1, 2009-12-24 02:27:10-05:00, stenn@deacon.udel.edu +1 -0 + System headers must come before ntp headers in ntp_intres.c -ChangeSet@1.1534, 2008-08-09 20:05:06-04:00, stenn@whimsy.udel.edu +2 -0 - AutoGen'd files must be writable + ntpd/ntp_intres.c@1.78, 2009-12-24 02:27:10-05:00, stenn@deacon.udel.edu +10 -8 + System headers must come before ntp headers in ntp_intres.c - sntp/Makefile.am@1.23, 2008-08-09 20:04:56-04:00, stenn@whimsy.udel.edu +2 -2 - AutoGen'd files must be writable +ChangeSet@1.2111, 2009-12-23 11:01:44+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1429] -4 command line option to ntpd does not reliably force IPv4 resolution - sntp/sntp-opts.menu@1.3, 2008-08-09 20:04:10-04:00, stenn@whimsy.udel.edu +0 -0 - Change mode to -rw-rw-r-- + ChangeLog@1.583, 2009-12-23 11:01:43+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1429] -4 command line option to ntpd does not reliably force IPv4 resolution -ChangeSet@1.1531.2.1, 2008-08-07 20:44:31+02:00, burnicki@pogo.udel.edu +3 -0 - [Bug 450] Windows only: Under original Windows NT we must not discard the - wildcard socket to workaround a bug in NT's getsockname(). + ntpd/cmd_args.c@1.57, 2009-12-23 11:01:43+00:00, davehart@shiny.ad.hartbrothers.com +12 -5 + [Bug 1429] -4 command line option to ntpd does not reliably force IPv4 resolution - ChangeLog@1.39.2.1, 2008-08-07 20:44:30+02:00, burnicki@pogo.udel.edu +2 -0 - [Bug 450] Windows only: Under original Windows NT we must not discard the - wildcard socket to workaround a bug in NT's getsockname(). + ntpd/ntp_config.c@1.239, 2009-12-23 11:01:43+00:00, davehart@shiny.ad.hartbrothers.com +2 -8 + [Bug 1429] -4 command line option to ntpd does not reliably force IPv4 resolution - ntpd/ntp_peer.c@1.99.1.1, 2008-08-07 20:44:30+02:00, burnicki@pogo.udel.edu +10 -2 - [Bug 450] Windows only: Under original Windows NT we must not discard the - wildcard socket to workaround a bug in NT's getsockname(). + ntpd/ntp_scanner.h@1.15, 2009-12-23 11:01:43+00:00, davehart@shiny.ad.hartbrothers.com +0 -1 + [Bug 1429] -4 command line option to ntpd does not reliably force IPv4 resolution - ports/winnt/ntpd/ntservice.c@1.11, 2008-08-07 20:44:30+02:00, burnicki@pogo.udel.edu +8 -1 - [Bug 450] Windows only: Under original Windows NT we must not discard the - wildcard socket to workaround a bug in NT's getsockname(). +ChangeSet@1.2110, 2009-12-22 08:36:49+00:00, hart@psp-deb1.ntp.org +1 -0 + UpdatePoint: + correct handling of beta-free stable RC bumps -ChangeSet@1.1531.1.2, 2008-08-05 09:56:08+02:00, burnicki@pogo.udel.edu +1 -0 - Removed Windows-specific debug code which has been added in ntp-dev and fails to compile in ntp-stable. + scripts/UpdatePoint@1.4, 2009-12-22 08:36:38+00:00, hart@psp-deb1.ntp.org +15 -7 + correct handling of beta-free stable RC bumps - ports/winnt/ntpd/ntp_iocompletionport.c@1.26, 2008-08-05 09:56:08+02:00, burnicki@pogo.udel.edu +0 -8 - Removed Windows-specific debug code which has been added in ntp-dev and fails to compile in ntp-stable. +ChangeSet@1.2109, 2009-12-22 03:00:22-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1424] Fix check for rtattr (rtnetlink.h) -ChangeSet@1.1531.1.1, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +10 -0 - [Bug 841] Obsolete the "dynamic" keyword and make deferred binding - to local interfaces the default. - Emit a warning if that keyword is used for configuration. + ChangeLog@1.582, 2009-12-22 03:00:12-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1424] Fix check for rtattr (rtnetlink.h) - ChangeLog@1.39.1.1, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +3 -0 - [Bug 841] Obsolete the "dynamic" keyword and make deferred binding - to local interfaces the default. - Emit a warning if that keyword is used for configuration. + configure.ac@1.471, 2009-12-22 03:00:12-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1424] Fix check for rtattr (rtnetlink.h) - html/confopt.html@1.36, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +0 -2 - Bug 841: Obsolete the "dynamic" keyword. +ChangeSet@1.2108, 2009-12-22 02:52:08-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1416] MAXDNAME undefined on Solaris 2.6 - html/ntpdc.html@1.27, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +2 -3 - Bug 841: Obsolete the "dynamic" keyword. + ChangeLog@1.581, 2009-12-22 02:52:00-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1416] MAXDNAME undefined on Solaris 2.6 - include/ntp.h@1.129, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +0 -1 - Bug 841: Obsolete the "dynamic" keyword. +ChangeSet@1.2107, 2009-12-22 02:29:35-05:00, stenn@whimsy.udel.edu +1 -0 + Bootstrap script should also touch .html files - include/ntp_request.h@1.31, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +0 -1 - Bug 841: Obsolete the "dynamic" keyword. + bootstrap@1.29, 2009-12-22 02:29:22-05:00, stenn@whimsy.udel.edu +1 -1 + Bootstrap script should also touch .html files - ntpd/ntp_config.c@1.144, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +4 -2 - [Bug 841] Obsolete the "dynamic" keyword and make deferred binding - to local interfaces the default. - Emit a warning if that keyword is used for configuration. +ChangeSet@1.2106, 2009-12-22 02:26:26-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1411] Fix status messages in refclock_oncore.c - ntpd/ntp_intres.c@1.52, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +1 -3 - Bug 841: Obsolete the "dynamic" keyword. + ChangeLog@1.580, 2009-12-22 02:26:15-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1411] Fix status messages in refclock_oncore.c - ntpd/ntp_peer.c@1.100, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +5 -25 - [Bug 841] Obsolete the "dynamic" keyword and make deferred binding - to local interfaces the default. + ntpd/refclock_oncore.c@1.82, 2009-12-22 02:26:15-05:00, stenn@whimsy.udel.edu +31 -8 + [Bug 1411] Fix status messages in refclock_oncore.c - ntpd/ntp_request.c@1.66, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +1 -3 - Bug 841: Obsolete the "dynamic" keyword. +ChangeSet@1.2105, 2009-12-22 04:15:31+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + bring Windows mkver.bat in line with packaginfo.sh and + scripts/VersionName changes - ntpdc/ntpdc_ops.c@1.50, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +3 -3 - [Bug 841] Obsolete the "dynamic" keyword and make deferred binding - to local interfaces the default. + ports/winnt/scripts/mkver.bat@1.12, 2009-12-22 04:15:30+00:00, davehart@shiny.ad.hartbrothers.com +14 -11 + bring Windows mkver.bat in line with packaginfo.sh and + scripts/VersionName changes -ChangeSet@1.1532, 2008-07-22 11:41:26+02:00, burnicki@pogo.udel.edu +2 -0 - [Bug 1038] Built-in getpass() function also prompts for password if not built with DEBUG. +ChangeSet@1.2100.1.1, 2009-12-22 00:55:19+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1428] Use AC_HEADER_RESOLV to fix breaks from resolv.h - ChangeLog@1.40, 2008-07-22 11:41:25+02:00, burnicki@pogo.udel.edu +1 -0 - [Bug 1038] Built-in getpass() function also prompts for password if not built with DEBUG. + ChangeLog@1.575.1.1, 2009-12-22 00:55:19+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1428] Use AC_HEADER_RESOLV to fix breaks from resolv.h - libntp/machines.c@1.19, 2008-07-22 11:41:25+02:00, burnicki@pogo.udel.edu +2 -2 - [Bug 1038] Built-in getpass() function also prompts for password if not built with DEBUG. + configure.ac@1.469, 2009-12-22 00:55:19+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1428] Use AC_HEADER_RESOLV to fix breaks from resolv.h -ChangeSet@1.1531, 2008-05-20 03:51:01-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P5_RC1 - TAG: NTP_4_2_4P5_RC1 + ntpd/ntp_intres.c@1.77, 2009-12-22 00:55:19+00:00, davehart@shiny.ad.hartbrothers.com +16 -3 + [Bug 1428] Use AC_HEADER_RESOLV to fix breaks from resolv.h + changes include of resolv.h to match Autoconf doc suggestion - ntpd/ntpd-opts.c@1.72, 2008-05-20 03:50:37-04:00, stenn@whimsy.udel.edu +6 -7 - NTP_4_2_4P5_RC1 +ChangeSet@1.2102, 2009-12-21 06:26:25+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1427] quote missing in ./build - shows up on NetBSD. - ntpd/ntpd-opts.h@1.72, 2008-05-20 03:50:37-04:00, stenn@whimsy.udel.edu +6 -7 - NTP_4_2_4P5_RC1 + ChangeLog@1.577, 2009-12-21 06:26:24+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1427] quote missing in ./build - shows up on NetBSD. - ntpd/ntpd-opts.texi@1.71, 2008-05-20 03:50:38-04:00, stenn@whimsy.udel.edu +8 -11 - NTP_4_2_4P5_RC1 + build@1.33, 2009-12-21 06:26:24+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + [Bug 1427] quote missing in ./build - shows up on NetBSD. - ntpd/ntpd.1@1.70, 2008-05-20 03:50:39-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P5_RC1 +ChangeSet@1.2101, 2009-12-21 05:19:15+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1426] scripts/VersionName needs . on the search path. + correct permissions to 0775 for scripts/UpdatePoint. - ntpd/ntpdsim-opts.c@1.72, 2008-05-20 03:50:40-04:00, stenn@whimsy.udel.edu +6 -7 - NTP_4_2_4P5_RC1 + ChangeLog@1.576, 2009-12-21 05:19:14+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1426] scripts/VersionName needs . on the search path. - ntpd/ntpdsim-opts.h@1.72, 2008-05-20 03:50:41-04:00, stenn@whimsy.udel.edu +6 -7 - NTP_4_2_4P5_RC1 + scripts/UpdatePoint@1.3, 2009-12-21 05:19:14+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + work correctly without . on $PATH - ntpd/ntpdsim-opts.texi@1.70, 2008-05-20 03:50:42-04:00, stenn@whimsy.udel.edu +3 -4 - NTP_4_2_4P5_RC1 + scripts/UpdatePoint@1.2, 2009-12-21 05:18:39+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Change mode to -rwxrwxr-x - ntpd/ntpdsim.1@1.70, 2008-05-20 03:50:43-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P5_RC1 + scripts/VersionName@1.6, 2009-12-21 05:19:14+00:00, davehart@shiny.ad.hartbrothers.com +3 -3 + [Bug 1426] scripts/VersionName needs . on the search path. - ntpdc/ntpdc-opts.c@1.72, 2008-05-20 03:50:44-04:00, stenn@whimsy.udel.edu +6 -7 - NTP_4_2_4P5_RC1 +ChangeSet@1.2100, 2009-12-20 00:52:48-05:00, stenn@whimsy.udel.edu +27 -0 + NTP_4_2_6P1_RC1 + TAG: NTP_4_2_6P1_RC1 - ntpdc/ntpdc-opts.h@1.72, 2008-05-20 03:50:44-04:00, stenn@whimsy.udel.edu +6 -7 - NTP_4_2_4P5_RC1 + ChangeLog@1.575, 2009-12-20 00:52:37-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_6P1_RC1 - ntpdc/ntpdc-opts.texi@1.70, 2008-05-20 03:50:45-04:00, stenn@whimsy.udel.edu +5 -6 - NTP_4_2_4P5_RC1 + ntpd/ntpd-opts.c@1.249, 2009-12-20 00:52:38-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC1 - ntpdc/ntpdc.1@1.70, 2008-05-20 03:50:46-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5_RC1 + ntpd/ntpd-opts.h@1.249, 2009-12-20 00:52:38-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC1 - ntpq/ntpq-opts.c@1.74, 2008-05-20 03:50:47-04:00, stenn@whimsy.udel.edu +6 -7 - NTP_4_2_4P5_RC1 + ntpd/ntpd-opts.texi@1.247, 2009-12-20 00:52:38-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC1 - ntpq/ntpq-opts.h@1.74, 2008-05-20 03:50:47-04:00, stenn@whimsy.udel.edu +6 -7 - NTP_4_2_4P5_RC1 + ntpd/ntpd.1@1.247, 2009-12-20 00:52:38-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC1 - ntpq/ntpq-opts.texi@1.71, 2008-05-20 03:50:48-04:00, stenn@whimsy.udel.edu +5 -6 - NTP_4_2_4P5_RC1 + ntpdc/ntpdc-opts.c@1.245, 2009-12-20 00:52:39-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC1 - ntpq/ntpq.1@1.70, 2008-05-20 03:50:49-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5_RC1 + ntpdc/ntpdc-opts.h@1.245, 2009-12-20 00:52:39-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC1 - packageinfo.sh@1.98, 2008-05-20 03:50:50-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC1 + ntpdc/ntpdc-opts.texi@1.244, 2009-12-20 00:52:39-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC1 - sntp/sntp-opts.c@1.70, 2008-05-20 03:50:51-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC1 + ntpdc/ntpdc.1@1.244, 2009-12-20 00:52:39-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC1 - sntp/sntp-opts.h@1.70, 2008-05-20 03:50:52-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5_RC1 + ntpq/ntpq-opts.c@1.246, 2009-12-20 00:52:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC1 - sntp/sntp-opts.texi@1.67, 2008-05-20 03:50:52-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5_RC1 + ntpq/ntpq-opts.h@1.246, 2009-12-20 00:52:40-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC1 - sntp/sntp.1@1.70, 2008-05-20 03:50:53-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC1 + ntpq/ntpq-opts.texi@1.245, 2009-12-20 00:52:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC1 - util/ntp-keygen-opts.c@1.71, 2008-05-20 03:50:54-04:00, stenn@whimsy.udel.edu +6 -7 - NTP_4_2_4P5_RC1 + ntpq/ntpq.1@1.245, 2009-12-20 00:52:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC1 - util/ntp-keygen-opts.h@1.71, 2008-05-20 03:50:54-04:00, stenn@whimsy.udel.edu +6 -7 - NTP_4_2_4P5_RC1 + ntpsnmpd/ntpsnmpd-opts.c@1.124, 2009-12-20 00:52:41-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC1 - util/ntp-keygen-opts.texi@1.69, 2008-05-20 03:50:55-04:00, stenn@whimsy.udel.edu +7 -9 - NTP_4_2_4P5_RC1 + ntpsnmpd/ntpsnmpd-opts.h@1.124, 2009-12-20 00:52:41-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC1 - util/ntp-keygen.1@1.69, 2008-05-20 03:50:56-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5_RC1 + ntpsnmpd/ntpsnmpd-opts.texi@1.124, 2009-12-20 00:52:41-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC1 -ChangeSet@1.1530, 2008-05-18 05:14:37-04:00, stenn@whimsy.udel.edu +1 -0 - Start the 4.2.4p5 release candidate cycle + ntpsnmpd/ntpsnmpd.1@1.123, 2009-12-20 00:52:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC1 - packageinfo.sh@1.97, 2008-05-18 05:14:27-04:00, stenn@whimsy.udel.edu +1 -1 - Start the 4.2.4p5 release candidate cycle + packageinfo.sh@1.260, 2009-12-20 00:52:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC1 -ChangeSet@1.1529, 2008-04-11 18:41:57-04:00, stenn@whimsy.udel.edu +1 -0 - Solaris _XOPEN_SOURCE updates + sntp/sntp-opts.c@1.118, 2009-12-20 00:52:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC1 - configure.ac@1.401, 2008-04-11 18:41:47-04:00, stenn@whimsy.udel.edu +5 -1 - Solaris _XOPEN_SOURCE updates + sntp/sntp-opts.h@1.118, 2009-12-20 00:52:42-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC1 -ChangeSet@1.1524.1.3, 2008-04-10 02:09:52-04:00, stenn@pogo.udel.edu +1 -0 - Changelog cleanup + sntp/sntp-opts.texi@1.118, 2009-12-20 00:52:43-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC1 - ChangeLog@1.37.1.2, 2008-04-10 02:08:57-04:00, stenn@pogo.udel.edu +2 -1 + sntp/sntp.1@1.118, 2009-12-20 00:52:43-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC1 -ChangeSet@1.1524.1.2, 2008-04-08 12:20:22+02:00, burnicki@pogo.udel.edu +1 -0 - Always sleep a little before calling doconfigure() to make sure the network is completely up. + sntp/sntp.html@1.8, 2009-12-20 00:52:43-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_6P1_RC1 - ntpd/ntp_intres.c@1.51, 2008-04-08 12:20:21+02:00, burnicki@pogo.udel.edu +5 -6 - Always sleep a little before calling doconfigure() to make sure the network is completely up. + util/ntp-keygen-opts.c@1.248, 2009-12-20 00:52:43-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC1 -ChangeSet@1.1524.1.1, 2008-04-03 10:19:03-04:00, burnicki@pogo.udel.edu +5 -0 - [Bug 987] Wake up the resolver thread/process when a new interface has become available. + util/ntp-keygen-opts.h@1.248, 2009-12-20 00:52:44-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_6P1_RC1 - ChangeLog@1.37.1.1, 2008-04-03 10:18:59-04:00, burnicki@pogo.udel.edu +1 -0 - [Bug 987] Wake up the resolver thread/process when a new interface has become available. + util/ntp-keygen-opts.texi@1.247, 2009-12-20 00:52:44-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC1 - include/ntpd.h@1.98, 2008-04-03 10:18:59-04:00, burnicki@pogo.udel.edu +5 -0 - Added vars used to wake up the resolver process/thread. + util/ntp-keygen.1@1.247, 2009-12-20 00:52:44-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_6P1_RC1 - ntpd/ntp_config.c@1.143, 2008-04-03 10:18:59-04:00, burnicki@pogo.udel.edu +34 -1 - Initialize synchronization variables when the resolver process/thread is started. +ChangeSet@1.2099, 2009-12-19 23:55:09-05:00, stenn@pogo.udel.edu +3 -0 + Put refclock_neoclock4x.c under the NTP COPYRIGHT - ntpd/ntp_intres.c@1.50, 2008-04-03 10:18:59-04:00, burnicki@pogo.udel.edu +64 -65 - Enable the resolver to be woken up when a new interface has become available. + ChangeLog@1.574, 2009-12-19 23:53:39-05:00, stenn@pogo.udel.edu +4 -0 + Put refclock_neoclock4x.c under the NTP COPYRIGHT - ntpd/ntp_io.c@1.256, 2008-04-03 10:19:00-04:00, burnicki@pogo.udel.edu +25 -5 - Wake up the resolver thread/process when a new interface has become available. + html/copyright.html@1.45, 2009-12-19 23:53:40-05:00, stenn@pogo.udel.edu +1 -0 + Put refclock_neoclock4x.c under the NTP COPYRIGHT -ChangeSet@1.1527, 2008-03-24 22:12:42-04:00, mayer@pogo.udel.edu +1 -0 - bugs 993 a d 959 + ntpd/refclock_neoclock4x.c@1.17, 2009-12-19 23:53:40-05:00, stenn@pogo.udel.edu +20 -9 + Put refclock_neoclock4x.c under the NTP COPYRIGHT - ChangeLog@1.38, 2008-03-24 22:12:26-04:00, mayer@pogo.udel.edu +2 -0 - bugs 993 a d 959 +ChangeSet@1.2098, 2009-12-19 22:05:09-05:00, stenn@whimsy.udel.edu +1 -0 + Start the 4.2.6p1-RC cycle -ChangeSet@1.1526, 2008-03-24 21:41:55-04:00, mayer@pogo.udel.edu +1 -0 - [Bug 959] Refclock on Windows not properly releasing recvbuffs + packageinfo.sh@1.259, 2009-12-19 22:03:49-05:00, stenn@whimsy.udel.edu +14 -1 + Start the 4.2.6p1-RC cycle - ports/winnt/ntpd/ntp_iocompletionport.c@1.25, 2008-03-24 21:41:37-04:00, mayer@pogo.udel.edu +25 -13 - [Bug 959] Refclock on Windows not properly releasing recvbuffs +ChangeSet@1.2097, 2009-12-19 21:47:40-05:00, stenn@whimsy.udel.edu +3 -0 + [Bug 1415] Fix Mac OS X link problem -ChangeSet@1.1525, 2008-03-24 21:40:32-04:00, mayer@pogo.udel.edu +1 -0 - [Bug 993] Windows: Fix memory leak when fetching system messages + ChangeLog@1.573, 2009-12-19 21:47:29-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1415] Fix Mac OS X link problem - ports/winnt/libisc/isc_strerror.c@1.5, 2008-03-24 21:40:07-04:00, mayer@pogo.udel.edu +78 -18 - [Bug 993] Windows: Fix memory leak when fetching system messages + configure.ac@1.468, 2009-12-19 21:47:30-05:00, stenn@whimsy.udel.edu +5 -0 + [Bug 1415] Fix Mac OS X link problem -ChangeSet@1.1520.3.5, 2008-03-22 02:12:10-05:00, stenn@whimsy.udel.edu +2 -0 - [Bug 977] Fix mismatching #ifdefs for builds without IPv6 + ntpsnmpd/Makefile.am@1.15.1.1, 2009-12-19 21:47:30-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 1415] Fix Mac OS X link problem - ChangeLog@1.35.3.4, 2008-03-22 02:11:57-05:00, stenn@whimsy.udel.edu +1 -0 - [Bug 977] Fix mismatching #ifdefs for builds without IPv6 +ChangeSet@1.2091.1.1, 2009-12-18 05:18:12+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + correct NTP_OS_CFLAGS [Bug 1412] + allow $CC to contain slash and space in build - libisc/net.c@1.9, 2008-03-22 02:11:58-05:00, stenn@whimsy.udel.edu +1 -1 - [Bug 977] Fix mismatching #ifdefs for builds without IPv6 + build@1.32, 2009-12-18 05:18:11+00:00, davehart@shiny.ad.hartbrothers.com +3 -3 + allow space and slash in $CC without breaking build/flock-build -ChangeSet@1.1520.3.4, 2008-03-22 02:02:36-05:00, stenn@whimsy.udel.edu +3 -0 - Update the copyright year + m4/os_cflags.m4@1.5, 2009-12-18 05:18:11+00:00, davehart@shiny.ad.hartbrothers.com +90 -93 + the name of the macro to define must be on the same line as AC_DEFUN( - ChangeLog@1.35.3.3, 2008-03-22 02:02:24-05:00, stenn@whimsy.udel.edu +8 -6 - Update the copyright year +ChangeSet@1.2090.5.1, 2009-12-16 21:26:45+00:00, davehart@shiny.ad.hartbrothers.com +13 -0 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. - html/copyright.html@1.37, 2008-03-22 02:02:25-05:00, stenn@whimsy.udel.edu +1 -1 - Update the copyright year + ChangeLog@1.567.5.1, 2009-12-16 21:26:43+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. - include/copyright.def@1.6, 2008-03-22 02:02:25-05:00, stenn@whimsy.udel.edu +1 -1 - Update the copyright year + adjtimed/Makefile.am@1.7, 2009-12-16 21:26:44+00:00, davehart@shiny.ad.hartbrothers.com +5 -1 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. -ChangeSet@1.1520.3.3, 2008-03-22 01:58:52-05:00, stenn@whimsy.udel.edu +5 -0 - Make autogen-generated files writable + bincheck.mf@1.3, 2009-12-16 21:26:43+00:00, davehart@shiny.ad.hartbrothers.com +5 -5 + respect $bindir, $sbindir instead of assuming $exec_prefix/$BINSUBDIR - ntpd/Makefile.am@1.54, 2008-03-22 01:57:08-05:00, stenn@whimsy.udel.edu +1 -1 - Make autogen-generated files writable + configure.ac@1.465.2.1, 2009-12-16 21:26:43+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. - ntpdc/Makefile.am@1.35, 2008-03-22 01:57:09-05:00, stenn@whimsy.udel.edu +1 -1 - Make autogen-generated files writable + ntpd/Makefile.am@1.79.2.1, 2009-12-16 21:26:44+00:00, davehart@shiny.ad.hartbrothers.com +4 -2 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. - ntpq/Makefile.am@1.27, 2008-03-22 01:57:10-05:00, stenn@whimsy.udel.edu +1 -1 - Make autogen-generated files writable + ntpdate/Makefile.am@1.23, 2009-12-16 21:26:44+00:00, davehart@shiny.ad.hartbrothers.com +6 -2 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. - sntp/Makefile.am@1.22, 2008-03-22 01:57:11-05:00, stenn@whimsy.udel.edu +1 -1 - Make autogen-generated files writable + ntpdc/Makefile.am@1.47.1.1, 2009-12-16 21:26:44+00:00, davehart@shiny.ad.hartbrothers.com +5 -1 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. - util/Makefile.am@1.36, 2008-03-22 01:57:11-05:00, stenn@whimsy.udel.edu +1 -1 - Make autogen-generated files writable + ntpq/Makefile.am@1.42.1.1, 2009-12-16 21:26:44+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. -ChangeSet@1.1520.4.1, 2008-03-16 09:15:13-04:00, burnicki@pogo.udel.edu +2 -0 - [Bug 957] Windows only: Let command line parameters from the Windows SCM GUI override the standard parameters from the ImagePath registry key. + ntpsnmpd/Makefile.am@1.16, 2009-12-16 21:26:44+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. - ChangeLog@1.35.4.1, 2008-03-16 09:15:10-04:00, burnicki@pogo.udel.edu +3 -0 - [Bug 957] Let command line parameters from the Windows SCM GUI override the standard parameters from the ImagePath registry key. + scripts/Makefile.am@1.16.1.1, 2009-12-16 21:26:44+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. - ports/winnt/ntpd/ntservice.c@1.10, 2008-03-16 09:15:11-04:00, burnicki@pogo.udel.edu +11 -2 - [Bug 957] Let command line parameters from the Windows SCM GUI override the standard parameters from the ImagePath registry key. + sntp/Makefile.am@1.20.1.1, 2009-12-16 21:26:44+00:00, davehart@shiny.ad.hartbrothers.com +5 -1 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. -ChangeSet@1.1520.3.1, 2008-03-03 11:50:50+01:00, martin@pc-martin.py.meinberg.de +2 -0 - [Bug 532] nptdate timeout is too long if several servers are supplied - [Bug 698] timeBeginPeriod is called without timeEndPeriod in some NTP tools - [Bug 857] ntpdate debug mode adjusts system clock when it shouldn't - [Bug 908] ntpdate crashes sometimes - [Bug 982] ntpdate(and ntptimeset) buffer overrun if HAVE_POLL_H isn't set (dup of 908) - [Bug 997] ntpdate buffer too small and unsafe - Under Windows check whether NTP port in use under same conditions as under other OSs. - Fixed some typos and indents (tabs/spaces). + sntp/configure.ac@1.29, 2009-12-16 21:26:44+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. - ChangeLog@1.35.3.1, 2008-03-03 11:50:49+01:00, martin@pc-martin.py.meinberg.de +10 -0 - [Bug 532] nptdate timeout is too long if several servers are supplied - [Bug 698] timeBeginPeriod is called without timeEndPeriod in some NTP tools - [Bug 857] ntpdate debug mode adjusts system clock when it shouldn't - [Bug 908] ntpdate crashes sometimes - [Bug 982] ntpdate(and ntptimeset) buffer overrun if HAVE_POLL_H isn't set (dup of 908) - [Bug 997] ntpdate buffer too small and unsafe - Under Windows check whether NTP port in use under same conditions as under other OSs. - Fixed some typos and indents (tabs/spaces). + util/Makefile.am@1.46, 2009-12-16 21:26:44+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. - ntpdate/ntpdate.c@1.62, 2008-03-03 11:50:49+01:00, martin@pc-martin.py.meinberg.de +101 -82 - [Bug 532] nptdate timeout is too long if several servers are supplied - [Bug 698] timeBeginPeriod is called without timeEndPeriod in some NTP tools - [Bug 857] ntpdate debug mode adjusts system clock when it shouldn't - [Bug 908] ntpdate crashes sometimes - [Bug 982] ntpdate(and ntptimeset) buffer overrun if HAVE_POLL_H isn't set (dup of 908) - [Bug 997] ntpdate buffer too small and unsafe - Under Windows check whether NTP port in use under same conditions as under other OSs. - Fixed some typos and indents (tabs/spaces). +ChangeSet@1.2090.4.1, 2009-12-16 20:21:10+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + updated packageinfo.sh, VersionName, and UpdatePoint to use prerelease= + from packageinfo.sh instead of releasecandidate= and added support for + beta releases. -ChangeSet@1.1520.2.7, 2008-02-20 12:13:24+01:00, martin@pc-martin4. +2 -0 - [Bug 909] Define int32_t for Windows (backport from ntp-dev) + ChangeLog@1.567.4.1, 2009-12-16 20:21:09+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + Build infrastructure updates to enable beta releases of ntp-stable. - ChangeLog@1.35.2.3, 2008-02-20 12:13:24+01:00, martin@pc-martin4. +1 -0 - [Bug 909] Define int32_t for Windows (backport from ntp-dev) + packageinfo.sh@1.258, 2009-12-16 20:21:09+00:00, davehart@shiny.ad.hartbrothers.com +69 -16 + updated to use prerelease= instead of releasecandidate=, with support + for prerelease=beta for ntp-stable pre-RC1 test releases - ports/winnt/include/config.h@1.47, 2008-02-20 12:13:24+01:00, martin@pc-martin4. +2 -0 - [Bug 909] Define int32_t for Windows (backport from ntp-dev) + scripts/Makefile.am@1.17, 2009-12-16 20:21:09+00:00, davehart@shiny.ad.hartbrothers.com +36 -5 + reformat, add UpdatePoint to EXTRA_DIST -ChangeSet@1.1520.2.6, 2008-02-19 11:08:55-05:00, burnicki@pogo.udel.edu +1 -0 - Fixed indentation. + scripts/UpdatePoint@1.1, 2009-12-16 20:21:09+00:00, davehart@shiny.ad.hartbrothers.com +323 -0 + updated to use prerelease= from packageinfo.sh instead of releasecandidate= + added support for beta releases - ntpd/ntp_io.c@1.255, 2008-02-19 11:08:52-05:00, burnicki@pogo.udel.edu +1 -1 - Fixed indentation. + scripts/UpdatePoint@1.0, 2009-12-16 20:21:09+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 -ChangeSet@1.1520.2.5, 2008-02-18 09:30:34-05:00, burnicki@pogo.udel.edu +1 -0 - Use new get_free_recv_buffer_alloc(). + scripts/VersionName@1.5, 2009-12-16 20:21:09+00:00, davehart@shiny.ad.hartbrothers.com +32 -18 + updated to use prerelease= from packageinfo.sh instead of releasecandidate= + added support for beta releases - ports/winnt/ntpd/ntp_iocompletionport.c@1.24, 2008-02-18 09:30:31-05:00, burnicki@pogo.udel.edu +4 -4 - Use new get_free_recv_buffer_alloc(). +ChangeSet@1.2090.3.1, 2009-12-14 21:18:10+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1418] building ntpd/ntpdc/ntpq statically with ssl fails. -ChangeSet@1.1520.2.4, 2008-02-17 17:48:29+00:00, kardel@pogo.udel.edu +1 -0 - recvbuff.c: - Bug 1000: add some pico optimizations + ChangeLog@1.567.3.1, 2009-12-14 21:18:09+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1418] building ntpd/ntpdc/ntpq statically with ssl fails. - libntp/recvbuff.c@1.29, 2008-02-17 17:42:21+00:00, kardel@pogo.udel.edu +5 -8 - Bug 1000: add some pico optimizations + ntpd/Makefile.am@1.79.1.1, 2009-12-14 21:18:09+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + move libntp.a ahead of @LCRYPTO@ to fix static openssl link -ChangeSet@1.1520.2.3, 2008-02-17 08:38:07+00:00, kardel@pogo.udel.edu +2 -0 - ntpd.c: - Bug 1000: avoid timer() starvation during high load conditions - ChangeLog: - Bug 1000: additionally fix timer() starvation during high load + ntpdc/Makefile.am@1.48, 2009-12-14 21:18:09+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + move libntp.a ahead of @LCRYPTO@ to fix static openssl link - ChangeLog@1.35.2.2, 2008-02-17 08:37:20+00:00, kardel@pogo.udel.edu +1 -0 - Bug 1000: additionally fix timer() starvation during high load + ntpq/Makefile.am@1.43, 2009-12-14 21:18:09+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + move libntp.a ahead of @LCRYPTO@ to fix static openssl link - ntpd/ntpd.c@1.85, 2008-02-17 08:34:13+00:00, kardel@pogo.udel.edu +11 -0 - Bug 1000: avoid timer() starvation during high load conditions +ChangeSet@1.2090.2.1, 2009-12-13 19:45:56+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1413] test OpenSSL headers regarding -Wno-strict-prototypes. -ChangeSet@1.1520.2.2, 2008-02-17 08:10:59+00:00, kardel@pogo.udel.edu +1 -0 - recvbuff.c: - Bug 1000: replenish when having expeirenced empty free lists + ChangeLog@1.567.2.1, 2009-12-13 19:45:55+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1413] test OpenSSL headers regarding -Wno-strict-prototypes. - libntp/recvbuff.c@1.28, 2008-02-17 08:09:37+00:00, kardel@pogo.udel.edu +1 -1 - Bug 1000: replenish when having expeirenced empty free lists + configure.ac@1.465.1.1, 2009-12-13 19:45:55+00:00, davehart@shiny.ad.hartbrothers.com +52 -10 + [Bug 1413] test OpenSSL headers to see if they trigger warnings before + enablng -Wno-strict-prototypes for gcc. + -Wall does not include -Wstrict-prototypes, so add it expclitly. -ChangeSet@1.1520.2.1, 2008-02-17 07:31:29+00:00, kardel@pogo.udel.edu +4 -0 - recvbuff.c, recvbuff.h, ntp_io.c, ChangeLog: - Bug 1000: Potentially insufficient number of receive buffers at startup +ChangeSet@1.2090.1.1, 2009-12-12 19:55:30+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1414] Enable "make distcheck" success with BSD make. - ChangeLog@1.35.2.1, 2008-02-17 07:29:23+00:00, kardel@pogo.udel.edu +3 -0 - Bug 1000: Potentially insufficient number of receive buffers at startup + ChangeLog@1.567.1.1, 2009-12-12 19:55:29+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1414] Enable "make distcheck" success with BSD make. - include/recvbuff.h@1.13, 2008-02-17 07:30:35+00:00, kardel@pogo.udel.edu +2 -1 - Bug 1000: Potentially insufficient number of receive buffers at startup + libparse/Makefile.am@1.17, 2009-12-12 19:55:29+00:00, davehart@shiny.ad.hartbrothers.com +23 -22 + add info_trimble.c to CLEANFILES [Bug 1414]. + remove references to $U leftover from ansi2knr use. - libntp/recvbuff.c@1.27, 2008-02-17 07:30:09+00:00, kardel@pogo.udel.edu +30 -11 - Bug 1000: Potentially insufficient number of receive buffers at startup + ntpd/Makefile.am@1.80, 2009-12-12 19:55:29+00:00, davehart@shiny.ad.hartbrothers.com +18 -4 + remove $VPHACK and $VPHACK_AFTER from EXTRA_DIST [Bug 1414] - ntpd/ntp_io.c@1.254, 2008-02-17 07:30:50+00:00, kardel@pogo.udel.edu +6 -2 - Bug 1000: Potentially insufficient number of receive buffers at startup + sntp/Makefile.am@1.21, 2009-12-12 19:55:29+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + reference $(srcdir)/COPYRIGHT in EXTRA_DIST not COPYRIGHT [Bug 1414] -ChangeSet@1.1520.1.1, 2008-01-26 06:43:33+00:00, kardel@pogo.udel.edu +3 -0 - ntpdbase-opts.def, ChangeLog, cmd_args.c: - remove minimum interface update interval restriction +ChangeSet@1.2091, 2009-12-12 08:31:39+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1412] m4/os_cflags.m4 caches results that depend on $CC. - ChangeLog@1.35.1.1, 2008-01-26 06:42:11+00:00, kardel@pogo.udel.edu +2 -0 - remove minimum interface update interval restriction + ChangeLog@1.568, 2009-12-12 08:31:38+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1412] m4/os_cflags.m4 caches results that depend on $CC. - ntpd/cmd_args.c@1.48, 2008-01-26 06:42:47+00:00, kardel@pogo.udel.edu +2 -2 - remove minimum interface update interval restriction + configure.ac@1.466, 2009-12-12 08:31:38+00:00, davehart@shiny.ad.hartbrothers.com +1 -47 + [Bug 1412] m4/os_cflags.m4 caches results that depend on $CC. - ntpd/ntpdbase-opts.def@1.11, 2008-01-26 06:43:10+00:00, kardel@pogo.udel.edu +1 -1 - remove minimum interface update interval restriction + m4/os_cflags.m4@1.4, 2009-12-12 08:31:38+00:00, davehart@shiny.ad.hartbrothers.com +82 -72 + [Bug 1412] m4/os_cflags.m4 caches results that depend on $CC. -ChangeSet@1.1523, 2007-11-01 03:52:00-04:00, clemens@pogo.udel.edu +1 -0 - * Negative-sawtooth not applied correctly for oncore 12 channel - receiver. Fixed. - * Startup code for original LinuxPPS removed. LinuxPPS now - conforms to the PPSAPI. +ChangeSet@1.2090, 2009-12-10 05:49:19-05:00, stenn@whimsy.udel.edu +25 -0 + 4.2.6 + TAG: NTP_4_2_6 - ChangeLog@1.36, 2007-11-01 03:51:58-04:00, clemens@pogo.udel.edu +4 -0 - * Negative-sawtooth not applied correctly for oncore 12 channel - receiver. Fixed. - * Startup code for original LinuxPPS removed. LinuxPPS now - conforms to the PPSAPI. + ntpd/ntpd-opts.c@1.248, 2009-12-10 05:48:35-05:00, stenn@whimsy.udel.edu +1 -1 + 4.2.6 -ChangeSet@1.1522, 2007-11-01 03:29:24-04:00, clemens@pogo.udel.edu +1 -0 - The original version of LinuxPPS did not comply with the PPSAPI and required - some changes to the startup code in refclock_oncore.c . The current version - complies, and these changes can be removed. + ntpd/ntpd-opts.h@1.248, 2009-12-10 05:48:36-05:00, stenn@whimsy.udel.edu +1 -1 + 4.2.6 - ntpd/refclock_oncore.c@1.62, 2007-11-01 03:29:21-04:00, clemens@pogo.udel.edu +1 -56 - The original version of LinuxPPS did not comply with the PPSAPI and required - some changes to the startup code in refclock_oncore.c . The current version - complies, and these changes can be removed. + ntpd/ntpd-opts.texi@1.246, 2009-12-10 05:48:36-05:00, stenn@whimsy.udel.edu +1 -1 + 4.2.6 -ChangeSet@1.1521, 2007-11-01 02:16:36-04:00, clemens@pogo.udel.edu +1 -0 - The oncore hardware provides a 'negative saw-tooth' the offset of the PPS signal - which is on the zero crossing of its internal clock, from its true value. the - refclock_oncore.c driver applies this difference to correct the time of the - provided timestamp. This value was being applied correctly for the 6 and 8 channel - receivers, but not for the 12 channel. This has been corrected. + ntpd/ntpd.1@1.246, 2009-12-10 05:48:36-05:00, stenn@whimsy.udel.edu +2 -2 + 4.2.6 - ntpd/refclock_oncore.c@1.61, 2007-11-01 02:16:33-04:00, clemens@pogo.udel.edu +2 -2 - The oncore hardware provides a 'negative saw-tooth' the offset of the PPS signal - which is on the zero crossing of its internal clock, from its true value. the - refclock_oncore.c driver applies this difference to correct the time of the - provided timestamp. This value was being applied correctly for the 6 and 8 channel - receivers, but not for the 12 channel. This has been corrected. + ntpdc/ntpdc-opts.c@1.244, 2009-12-10 05:48:36-05:00, stenn@whimsy.udel.edu +1 -1 + 4.2.6 -ChangeSet@1.1520, 2007-09-10 20:40:19-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P4 - TAG: NTP_4_2_4P4 + ntpdc/ntpdc-opts.h@1.244, 2009-12-10 05:48:37-05:00, stenn@whimsy.udel.edu +1 -1 + 4.2.6 - ntpd/ntpd-opts.c@1.71, 2007-09-10 20:39:55-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + ntpdc/ntpdc-opts.texi@1.243, 2009-12-10 05:48:37-05:00, stenn@whimsy.udel.edu +2 -2 + 4.2.6 - ntpd/ntpd-opts.h@1.71, 2007-09-10 20:39:56-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4 + ntpdc/ntpdc.1@1.243, 2009-12-10 05:48:37-05:00, stenn@whimsy.udel.edu +2 -2 + 4.2.6 - ntpd/ntpd-opts.texi@1.70, 2007-09-10 20:39:57-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P4 + ntpq/ntpq-opts.c@1.245, 2009-12-10 05:48:37-05:00, stenn@whimsy.udel.edu +1 -1 + 4.2.6 - ntpd/ntpd.1@1.69, 2007-09-10 20:39:57-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + ntpq/ntpq-opts.h@1.245, 2009-12-10 05:48:38-05:00, stenn@whimsy.udel.edu +1 -1 + 4.2.6 - ntpd/ntpdsim-opts.c@1.71, 2007-09-10 20:39:58-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + ntpq/ntpq-opts.texi@1.244, 2009-12-10 05:48:38-05:00, stenn@whimsy.udel.edu +2 -2 + 4.2.6 - ntpd/ntpdsim-opts.h@1.71, 2007-09-10 20:39:58-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4 + ntpq/ntpq.1@1.244, 2009-12-10 05:48:38-05:00, stenn@whimsy.udel.edu +2 -2 + 4.2.6 - ntpd/ntpdsim-opts.texi@1.69, 2007-09-10 20:40:00-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P4 + ntpsnmpd/ntpsnmpd-opts.c@1.123, 2009-12-10 05:48:38-05:00, stenn@whimsy.udel.edu +1 -1 + 4.2.6 - ntpd/ntpdsim.1@1.69, 2007-09-10 20:40:00-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + ntpsnmpd/ntpsnmpd-opts.h@1.123, 2009-12-10 05:48:39-05:00, stenn@whimsy.udel.edu +1 -1 + 4.2.6 - ntpdc/ntpdc-opts.c@1.71, 2007-09-10 20:40:01-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + ntpsnmpd/ntpsnmpd-opts.texi@1.123, 2009-12-10 05:48:39-05:00, stenn@whimsy.udel.edu +23 -2 + 4.2.6 - ntpdc/ntpdc-opts.h@1.71, 2007-09-10 20:40:02-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4 + ntpsnmpd/ntpsnmpd.1@1.122, 2009-12-10 05:48:39-05:00, stenn@whimsy.udel.edu +2 -2 + 4.2.6 - ntpdc/ntpdc-opts.texi@1.69, 2007-09-10 20:40:03-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P4 + sntp/sntp-opts.c@1.117, 2009-12-10 05:48:40-05:00, stenn@whimsy.udel.edu +1 -1 + 4.2.6 - ntpdc/ntpdc.1@1.69, 2007-09-10 20:40:03-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + sntp/sntp-opts.h@1.117, 2009-12-10 05:48:40-05:00, stenn@whimsy.udel.edu +1 -1 + 4.2.6 - ntpq/ntpq-opts.c@1.73, 2007-09-10 20:40:04-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + sntp/sntp-opts.texi@1.117, 2009-12-10 05:48:40-05:00, stenn@whimsy.udel.edu +2 -2 + 4.2.6 - ntpq/ntpq-opts.h@1.73, 2007-09-10 20:40:05-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4 + sntp/sntp.1@1.117, 2009-12-10 05:48:40-05:00, stenn@whimsy.udel.edu +2 -2 + 4.2.6 - ntpq/ntpq-opts.texi@1.70, 2007-09-10 20:40:06-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P4 + sntp/sntp.html@1.7, 2009-12-10 05:48:40-05:00, stenn@whimsy.udel.edu +13 -9 + 4.2.6 - ntpq/ntpq.1@1.69, 2007-09-10 20:40:06-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + util/ntp-keygen-opts.c@1.247, 2009-12-10 05:48:41-05:00, stenn@whimsy.udel.edu +1 -1 + 4.2.6 - packageinfo.sh@1.96, 2007-09-10 20:40:07-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + util/ntp-keygen-opts.h@1.247, 2009-12-10 05:48:41-05:00, stenn@whimsy.udel.edu +1 -1 + 4.2.6 - sntp/sntp-opts.c@1.69, 2007-09-10 20:40:08-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + util/ntp-keygen-opts.texi@1.246, 2009-12-10 05:48:41-05:00, stenn@whimsy.udel.edu +2 -2 + 4.2.6 - sntp/sntp-opts.h@1.69, 2007-09-10 20:40:08-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4 + util/ntp-keygen.1@1.246, 2009-12-10 05:48:41-05:00, stenn@whimsy.udel.edu +2 -2 + 4.2.6 - sntp/sntp-opts.texi@1.66, 2007-09-10 20:40:09-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P4 +ChangeSet@1.2089, 2009-12-09 03:46:30-05:00, stenn@deacon.udel.edu +27 -0 + cleanup - sntp/sntp.1@1.69, 2007-09-10 20:40:10-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + ChangeLog@1.567, 2009-12-09 03:39:00-05:00, stenn@deacon.udel.edu +1 -1 + cleanup - util/ntp-keygen-opts.c@1.70, 2007-09-10 20:40:11-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + ntpd/ntpd-opts.c@1.247, 2009-12-09 03:46:05-05:00, stenn@deacon.udel.edu +2 -2 + cleanup - util/ntp-keygen-opts.h@1.70, 2007-09-10 20:40:12-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4 + ntpd/ntpd-opts.h@1.247, 2009-12-09 03:46:05-05:00, stenn@deacon.udel.edu +3 -3 + cleanup - util/ntp-keygen-opts.texi@1.68, 2007-09-10 20:40:13-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P4 + ntpd/ntpd-opts.texi@1.245, 2009-12-09 03:46:05-05:00, stenn@deacon.udel.edu +2 -2 + cleanup - util/ntp-keygen.1@1.68, 2007-09-10 20:40:14-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + ntpd/ntpd.1@1.245, 2009-12-09 03:46:05-05:00, stenn@deacon.udel.edu +2 -2 + cleanup -ChangeSet@1.1519, 2007-09-10 16:56:09-04:00, stenn@whimsy.udel.edu +3 -0 - Release 4.2.4p4 + ntpdc/ntpdc-opts.c@1.243, 2009-12-09 03:46:05-05:00, stenn@deacon.udel.edu +2 -2 + cleanup - ChangeLog@1.35, 2007-09-10 16:55:51-04:00, stenn@whimsy.udel.edu +3 -0 - Release 4.2.4p4 + ntpdc/ntpdc-opts.h@1.243, 2009-12-09 03:46:06-05:00, stenn@deacon.udel.edu +3 -3 + cleanup - NEWS@1.98, 2007-09-10 16:55:54-04:00, stenn@whimsy.udel.edu +11 -0 - Release 4.2.4p4 + ntpdc/ntpdc-opts.texi@1.242, 2009-12-09 03:46:06-05:00, stenn@deacon.udel.edu +3 -3 + cleanup - packageinfo.sh@1.95, 2007-09-10 16:55:58-04:00, stenn@whimsy.udel.edu +1 -1 - Release 4.2.4p4 + ntpdc/ntpdc.1@1.242, 2009-12-09 03:46:06-05:00, stenn@deacon.udel.edu +2 -2 + cleanup -ChangeSet@1.1518, 2007-09-10 01:57:20-04:00, stenn@whimsy.udel.edu +3 -0 - [Bug 902] Fix problems with the -6 flag + ntpq/ntpq-opts.c@1.244, 2009-12-09 03:46:06-05:00, stenn@deacon.udel.edu +2 -2 + cleanup - ChangeLog@1.34, 2007-09-10 01:57:02-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 902] Fix problems with the -6 flag + ntpq/ntpq-opts.h@1.244, 2009-12-09 03:46:06-05:00, stenn@deacon.udel.edu +3 -3 + cleanup - libopts/save.c@1.2, 2007-09-10 01:57:02-04:00, stenn@whimsy.udel.edu +11 -2 - [Bug 902] Fix problems with the -6 flag + ntpq/ntpq-opts.texi@1.243, 2009-12-09 03:46:06-05:00, stenn@deacon.udel.edu +3 -3 + cleanup - sntp/libopts/save.c@1.2, 2007-09-10 01:57:03-04:00, stenn@whimsy.udel.edu +11 -2 - [Bug 902] Fix problems with the -6 flag + ntpq/ntpq.1@1.243, 2009-12-09 03:46:06-05:00, stenn@deacon.udel.edu +2 -2 + cleanup -ChangeSet@1.1517, 2007-08-28 15:34:55-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P4_RC2 - TAG: NTP_4_2_4P4_RC2 + ntpsnmpd/ntpsnmpd-opts.c@1.122, 2009-12-09 03:46:06-05:00, stenn@deacon.udel.edu +2 -2 + cleanup - ntpd/ntpd-opts.c@1.70, 2007-08-28 15:34:28-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P4_RC2 + ntpsnmpd/ntpsnmpd-opts.h@1.122, 2009-12-09 03:46:06-05:00, stenn@deacon.udel.edu +3 -3 + cleanup - ntpd/ntpd-opts.h@1.70, 2007-08-28 15:34:29-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P4_RC2 + ntpsnmpd/ntpsnmpd-opts.texi@1.122, 2009-12-09 03:46:06-05:00, stenn@deacon.udel.edu +1 -1 + cleanup - ntpd/ntpd-opts.texi@1.69, 2007-08-28 15:34:31-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC2 + ntpsnmpd/ntpsnmpd.1@1.121, 2009-12-09 03:46:06-05:00, stenn@deacon.udel.edu +2 -2 + cleanup - ntpd/ntpd.1@1.68, 2007-08-28 15:34:32-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC2 + packageinfo.sh@1.257, 2009-12-09 03:39:00-05:00, stenn@deacon.udel.edu +1 -1 + cleanup - ntpd/ntpdsim-opts.c@1.70, 2007-08-28 15:34:32-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P4_RC2 + sntp/sntp-opts.c@1.116, 2009-12-09 03:46:06-05:00, stenn@deacon.udel.edu +2 -2 + cleanup - ntpd/ntpdsim-opts.h@1.70, 2007-08-28 15:34:33-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P4_RC2 + sntp/sntp-opts.h@1.116, 2009-12-09 03:46:06-05:00, stenn@deacon.udel.edu +3 -3 + cleanup - ntpd/ntpdsim-opts.texi@1.68, 2007-08-28 15:34:34-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P4_RC2 + sntp/sntp-opts.texi@1.116, 2009-12-09 03:46:06-05:00, stenn@deacon.udel.edu +3 -3 + cleanup - ntpd/ntpdsim.1@1.68, 2007-08-28 15:34:34-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC2 + sntp/sntp.1@1.116, 2009-12-09 03:46:06-05:00, stenn@deacon.udel.edu +2 -2 + cleanup - ntpdc/ntpdc-opts.c@1.70, 2007-08-28 15:34:35-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P4_RC2 + sntp/sntp.html@1.6, 2009-12-09 03:46:06-05:00, stenn@deacon.udel.edu +1 -1 + cleanup - ntpdc/ntpdc-opts.h@1.70, 2007-08-28 15:34:36-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P4_RC2 + util/ntp-keygen-opts.c@1.246, 2009-12-09 03:46:06-05:00, stenn@deacon.udel.edu +2 -2 + cleanup - ntpdc/ntpdc-opts.texi@1.68, 2007-08-28 15:34:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC2 + util/ntp-keygen-opts.h@1.246, 2009-12-09 03:46:06-05:00, stenn@deacon.udel.edu +3 -3 + cleanup - ntpdc/ntpdc.1@1.68, 2007-08-28 15:34:38-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC2 + util/ntp-keygen-opts.texi@1.245, 2009-12-09 03:46:07-05:00, stenn@deacon.udel.edu +3 -3 + cleanup - ntpq/ntpq-opts.c@1.72, 2007-08-28 15:34:38-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P4_RC2 + util/ntp-keygen.1@1.245, 2009-12-09 03:46:07-05:00, stenn@deacon.udel.edu +2 -2 + cleanup - ntpq/ntpq-opts.h@1.72, 2007-08-28 15:34:39-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P4_RC2 +ChangeSet@1.2088, 2009-12-09 02:58:13-05:00, stenn@deacon.udel.edu +27 -0 + NTP_4_2_6_RC + TAG: NTP_4_2_6_RC - ntpq/ntpq-opts.texi@1.69, 2007-08-28 15:34:40-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC2 + ChangeLog@1.566, 2009-12-09 02:58:10-05:00, stenn@deacon.udel.edu +1 -0 + NTP_4_2_6_RC - ntpq/ntpq.1@1.68, 2007-08-28 15:34:41-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC2 + ntpd/ntpd-opts.c@1.246, 2009-12-09 02:58:10-05:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6_RC - packageinfo.sh@1.94, 2007-08-28 15:34:41-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P4_RC2 + ntpd/ntpd-opts.h@1.246, 2009-12-09 02:58:10-05:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6_RC - sntp/sntp-opts.c@1.68, 2007-08-28 15:34:42-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC2 + ntpd/ntpd-opts.texi@1.244, 2009-12-09 02:58:11-05:00, stenn@deacon.udel.edu +61 -2 + NTP_4_2_6_RC - sntp/sntp-opts.h@1.68, 2007-08-28 15:34:43-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC2 + ntpd/ntpd.1@1.244, 2009-12-09 02:58:11-05:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6_RC - sntp/sntp-opts.texi@1.65, 2007-08-28 15:34:44-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P4_RC2 + ntpdc/ntpdc-opts.c@1.242, 2009-12-09 02:58:11-05:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6_RC - sntp/sntp.1@1.68, 2007-08-28 15:34:45-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC2 + ntpdc/ntpdc-opts.h@1.242, 2009-12-09 02:58:11-05:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6_RC - util/ntp-keygen-opts.c@1.69, 2007-08-28 15:34:45-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P4_RC2 + ntpdc/ntpdc-opts.texi@1.241, 2009-12-09 02:58:11-05:00, stenn@deacon.udel.edu +66 -2 + NTP_4_2_6_RC - util/ntp-keygen-opts.h@1.69, 2007-08-28 15:34:46-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P4_RC2 + ntpdc/ntpdc.1@1.241, 2009-12-09 02:58:11-05:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6_RC - util/ntp-keygen-opts.texi@1.67, 2007-08-28 15:34:48-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC2 + ntpq/ntpq-opts.c@1.243, 2009-12-09 02:58:11-05:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6_RC - util/ntp-keygen.1@1.67, 2007-08-28 15:34:48-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC2 + ntpq/ntpq-opts.h@1.243, 2009-12-09 02:58:11-05:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6_RC -ChangeSet@1.1516, 2007-08-27 22:38:57-04:00, stenn@whimsy.udel.edu +2 -0 - Updated include/copyright.def (owner and year) + ntpq/ntpq-opts.texi@1.242, 2009-12-09 02:58:11-05:00, stenn@deacon.udel.edu +51 -2 + NTP_4_2_6_RC - ChangeLog@1.33, 2007-08-27 22:38:46-04:00, stenn@whimsy.udel.edu +1 -0 - Updated include/copyright.def (owner and year) + ntpq/ntpq.1@1.242, 2009-12-09 02:58:11-05:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6_RC - include/copyright.def@1.5, 2007-08-27 22:38:47-04:00, stenn@whimsy.udel.edu +2 -2 - Updated include/copyright.def (owner and year) + ntpsnmpd/ntpsnmpd-opts.c@1.121, 2009-12-09 02:58:11-05:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6_RC -ChangeSet@1.1515, 2007-08-19 05:26:13-04:00, dunlop@pogo.udel.edu +2 -0 - ntpdc_ops.c, ChangeLog: - [BUG 881] Corrected display of pll offset on 64bit systems. - [BUG 886] Corrected sign extension of il->compliance on 64 bit systems - [BUG 878] Avoid ntpdc use of refid value as unterminated string. + ntpsnmpd/ntpsnmpd-opts.h@1.121, 2009-12-09 02:58:11-05:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6_RC - ChangeLog@1.32, 2007-08-19 05:20:42-04:00, dunlop@pogo.udel.edu +1 -0 - [Bug 878] Avoid ntpdc use of refid value as unterminated string. + ntpsnmpd/ntpsnmpd-opts.texi@1.121, 2009-12-09 02:58:11-05:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_6_RC - ChangeLog@1.31, 2007-08-19 05:13:18-04:00, dunlop@pogo.udel.edu +1 -0 - [Bug 881] Corrected display of pll offset on 64bit systems. + ntpsnmpd/ntpsnmpd.1@1.120, 2009-12-09 02:58:11-05:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6_RC - ChangeLog@1.30, 2007-08-19 05:01:14-04:00, dunlop@pogo.udel.edu +1 -0 - [BUG 886] Corrected sign extension of il->compliance on 64 bit systems + packageinfo.sh@1.256, 2009-12-09 02:58:11-05:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6_RC - ntpdc/ntpdc_ops.c@1.49, 2007-08-19 05:20:34-04:00, dunlop@pogo.udel.edu +1 -3 - [Bug 878] Avoid ntpdc use of refid value as unterminated string. + sntp/sntp-opts.c@1.115, 2009-12-09 02:58:11-05:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6_RC - ntpdc/ntpdc_ops.c@1.48, 2007-08-19 05:12:52-04:00, dunlop@pogo.udel.edu +1 -1 - [Bug 881] Corrected display of pll offset on 64bit systems. + sntp/sntp-opts.h@1.115, 2009-12-09 02:58:11-05:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6_RC - ntpdc/ntpdc_ops.c@1.47, 2007-08-19 04:59:48-04:00, dunlop@pogo.udel.edu +2 -2 - [BUG 886] Corrected sign extension of il->compliance on 64 bit systems + sntp/sntp-opts.texi@1.115, 2009-12-09 02:58:11-05:00, stenn@deacon.udel.edu +60 -2 + NTP_4_2_6_RC -ChangeSet@1.1514, 2007-08-18 17:11:19-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P4_RC1 - TAG: NTP_4_2_4P4_RC1 + sntp/sntp.1@1.115, 2009-12-09 02:58:11-05:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6_RC - ntpd/ntpd-opts.c@1.69, 2007-08-18 17:10:51-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + sntp/sntp.html@1.5, 2009-12-09 02:58:12-05:00, stenn@deacon.udel.edu +10 -14 + NTP_4_2_6_RC - ntpd/ntpd-opts.h@1.69, 2007-08-18 17:10:52-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC1 + util/ntp-keygen-opts.c@1.245, 2009-12-09 02:58:12-05:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6_RC - ntpd/ntpd-opts.texi@1.68, 2007-08-18 17:10:53-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + util/ntp-keygen-opts.h@1.245, 2009-12-09 02:58:12-05:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_6_RC - ntpd/ntpd.1@1.67, 2007-08-18 17:10:53-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + util/ntp-keygen-opts.texi@1.244, 2009-12-09 02:58:12-05:00, stenn@deacon.udel.edu +46 -2 + NTP_4_2_6_RC - ntpd/ntpdsim-opts.c@1.69, 2007-08-18 17:10:54-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + util/ntp-keygen.1@1.244, 2009-12-09 02:58:12-05:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_6_RC - ntpd/ntpdsim-opts.h@1.69, 2007-08-18 17:10:54-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC1 +ChangeSet@1.2087, 2009-12-09 00:06:06-05:00, stenn@deacon.udel.edu +2 -0 + 4.2.6 - ntpd/ntpdsim-opts.texi@1.67, 2007-08-18 17:10:56-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P4_RC1 + ChangeLog@1.565, 2009-12-09 00:05:55-05:00, stenn@deacon.udel.edu +1 -0 + 4.2.6 - ntpd/ntpdsim.1@1.67, 2007-08-18 17:10:56-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + packageinfo.sh@1.255, 2009-12-09 00:05:55-05:00, stenn@deacon.udel.edu +5 -5 + 4.2.6 - ntpdc/ntpdc-opts.c@1.69, 2007-08-18 17:10:57-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 +ChangeSet@1.2086, 2009-12-08 10:09:30-05:00, stenn@deacon.udel.edu +1 -0 + Include 4.2.4p8 - ntpdc/ntpdc-opts.h@1.69, 2007-08-18 17:10:57-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC1 + ChangeLog@1.564, 2009-12-08 10:07:40-05:00, stenn@deacon.udel.edu +1 -0 - ntpdc/ntpdc-opts.texi@1.67, 2007-08-18 17:10:58-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 +ChangeSet@1.1436.15.75, 2009-12-08 08:30:54-05:00, stenn@whimsy.udel.edu +1 -0 + ChangeLog: + typo - ntpdc/ntpdc.1@1.67, 2007-08-18 17:10:59-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + ChangeLog@1.1.1.94, 2009-12-08 08:30:44-05:00, stenn@whimsy.udel.edu +0 -1 + typo - ntpq/ntpq-opts.c@1.71, 2007-08-18 17:10:59-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 +ChangeSet@1.1436.15.74, 2009-12-08 08:23:12-05:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_4P8 + TAG: NTP_4_2_4P8 - ntpq/ntpq-opts.h@1.71, 2007-08-18 17:11:01-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC1 + ChangeLog@1.1.1.93, 2009-12-08 08:23:01-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_4P8 - ntpq/ntpq-opts.texi@1.68, 2007-08-18 17:11:02-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + ntpd/ntpd-opts.c@1.50.26.2, 2009-12-08 08:23:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P8 - ntpq/ntpq.1@1.67, 2007-08-18 17:11:03-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + ntpd/ntpd-opts.h@1.50.26.2, 2009-12-08 08:23:02-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P8 - packageinfo.sh@1.93, 2007-08-18 17:11:03-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + ntpd/ntpd-opts.texi@1.49.26.2, 2009-12-08 08:23:03-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P8 - sntp/sntp-opts.c@1.67, 2007-08-18 17:11:04-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + ntpd/ntpd.1@1.48.26.2, 2009-12-08 08:23:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P8 - sntp/sntp-opts.h@1.67, 2007-08-18 17:11:05-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC1 + ntpd/ntpdsim-opts.c@1.50.26.2, 2009-12-08 08:23:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P8 - sntp/sntp-opts.texi@1.64, 2007-08-18 17:11:07-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P4_RC1 + ntpd/ntpdsim-opts.h@1.50.26.2, 2009-12-08 08:23:04-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P8 - sntp/sntp.1@1.67, 2007-08-18 17:11:08-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + ntpd/ntpdsim-opts.texi@1.48.26.2, 2009-12-08 08:23:05-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P8 - util/ntp-keygen-opts.c@1.68, 2007-08-18 17:11:08-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + ntpd/ntpdsim.1@1.48.26.2, 2009-12-08 08:23:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P8 - util/ntp-keygen-opts.h@1.68, 2007-08-18 17:11:10-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC1 + ntpdc/ntpdc-opts.c@1.50.26.2, 2009-12-08 08:23:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P8 - util/ntp-keygen-opts.texi@1.66, 2007-08-18 17:11:11-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + ntpdc/ntpdc-opts.h@1.50.26.2, 2009-12-08 08:23:05-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P8 - util/ntp-keygen.1@1.66, 2007-08-18 17:11:11-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + ntpdc/ntpdc-opts.texi@1.48.26.2, 2009-12-08 08:23:06-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P8 -ChangeSet@1.1513, 2007-08-18 16:16:22-04:00, stenn@whimsy.udel.edu +1 -0 - 4.2.4p4-RC + ntpdc/ntpdc.1@1.48.26.2, 2009-12-08 08:23:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P8 - packageinfo.sh@1.92, 2007-08-18 16:16:06-04:00, stenn@whimsy.udel.edu +1 -1 - 4.2.4p4-RC + ntpq/ntpq-opts.c@1.52.26.2, 2009-12-08 08:23:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P8 -ChangeSet@1.1512, 2007-08-18 12:59:45+00:00, kardel@pogo.udel.edu +2 -0 - ntp_restrict.c: - Bug 885: clarify to allow tools to pick up - invariants easier. - Use NULL instead of 0 with pointers. - ChangeLog: - document ntp_restrict.c change + ntpq/ntpq-opts.h@1.52.26.2, 2009-12-08 08:23:06-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P8 - ChangeLog@1.29, 2007-08-18 12:59:05+00:00, kardel@pogo.udel.edu +1 -0 - document ntp_restrict.c change + ntpq/ntpq-opts.texi@1.49.26.2, 2009-12-08 08:23:07-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P8 - ntpd/ntp_restrict.c@1.23, 2007-08-18 12:56:40+00:00, kardel@pogo.udel.edu +21 -21 - Bug 885: clarify to allow tools to pick up - invariants easier. - Use NULL instead of 0 with pointers. + ntpq/ntpq.1@1.48.26.2, 2009-12-08 08:23:07-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P8 -ChangeSet@1.1511, 2007-08-18 12:53:35+00:00, kardel@pogo.udel.edu +2 -0 - recvbuff.c: - Bug 889: avoid malloc() interrupted by SIGIO risk - ChangeLog: - document Bug 889 + packageinfo.sh@1.65.34.3, 2009-12-08 08:23:07-05:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P8 - ChangeLog@1.28, 2007-08-18 12:52:19+00:00, kardel@pogo.udel.edu +1 -0 - document Bug 889 + sntp/sntp-opts.c@1.49.26.2, 2009-12-08 08:23:07-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P8 - libntp/recvbuff.c@1.26, 2007-08-18 12:49:27+00:00, kardel@pogo.udel.edu +28 -21 - Bug 889: avoid malloc() interrupted by SIGIO risk + sntp/sntp-opts.h@1.49.26.2, 2009-12-08 08:23:07-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P8 -ChangeSet@1.1510, 2007-08-18 09:51:41+00:00, kardel@pogo.udel.edu +1 -0 - cmd_args.c: - Bug 885: fix comparison + sntp/sntp-opts.texi@1.46.26.2, 2009-12-08 08:23:08-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P8 - ntpd/cmd_args.c@1.47, 2007-08-18 09:50:28+00:00, kardel@pogo.udel.edu +1 -1 - Bug 885: fix comparison + sntp/sntp.1@1.49.26.2, 2009-12-08 08:23:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P8 -ChangeSet@1.1502.1.1, 2007-08-17 05:28:07-04:00, stenn@pogo.udel.edu +1 -0 - Use autoconf-2.59 and automake-1.9 for building 4.2.4 + util/ntp-keygen-opts.c@1.49.26.2, 2009-12-08 08:23:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P8 - bootstrap@1.19, 2007-08-17 05:27:51-04:00, stenn@pogo.udel.edu +18 -2 - Use autoconf-2.59 and automake-1.9 for building 4.2.4 + util/ntp-keygen-opts.h@1.49.26.2, 2009-12-08 08:23:08-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P8 -ChangeSet@1.1508, 2007-08-11 17:32:22+00:00, kardel@pogo.udel.edu +1 -0 - ChangeLog: - document refclock_parse.c fix + util/ntp-keygen-opts.texi@1.47.26.2, 2009-12-08 08:23:09-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P8 - ChangeLog@1.27, 2007-08-11 17:31:30+00:00, kardel@pogo.udel.edu +1 -0 - document refclock_parse.c fix + util/ntp-keygen.1@1.47.26.2, 2009-12-08 08:23:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P8 -ChangeSet@1.1507, 2007-08-11 17:30:42+00:00, kardel@pogo.udel.edu +4 -0 - ChangeLog: - document Bug 885 - ntp_io.c: - Bug 885: use emalloc() to get a message at the end of the memory - cmd_args.c: - Bug 885: unsigned types cannot be less than 0 - default_ai_family is a short - ntp_config.c: - Bug 885: lose trailing , from enum list +ChangeSet@1.1436.15.73, 2009-12-08 07:45:28-05:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_4P9_RC1 + TAG: NTP_4_2_4P9_RC1 - ChangeLog@1.26, 2007-08-11 17:30:24+00:00, kardel@pogo.udel.edu +4 -0 - document Bug 885 + ChangeLog@1.1.1.92, 2009-12-08 07:45:19-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_4P9_RC1 - ntpd/cmd_args.c@1.46, 2007-08-11 17:19:51+00:00, kardel@pogo.udel.edu +2 -2 - Bug 885: unsigned types cannot be less than 0 - default_ai_family is a short + ntpd/ntpd-opts.c@1.50.26.1, 2009-12-08 07:45:19-05:00, stenn@whimsy.udel.edu +5 -5 + NTP_4_2_4P9_RC1 - ntpd/ntp_config.c@1.142, 2007-08-11 17:20:52+00:00, kardel@pogo.udel.edu +1 -1 - Bug 885: lose trailing , from enum list + ntpd/ntpd-opts.h@1.50.26.1, 2009-12-08 07:45:19-05:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P9_RC1 - ntpd/ntp_io.c@1.253, 2007-08-11 17:21:17+00:00, kardel@pogo.udel.edu +1 -1 - Bug 885: use emalloc() to get a message at the end of the memory + ntpd/ntpd-opts.texi@1.49.26.1, 2009-12-08 07:45:20-05:00, stenn@whimsy.udel.edu +13 -6 + NTP_4_2_4P9_RC1 -ChangeSet@1.1506, 2007-08-11 17:19:45+00:00, kardel@pogo.udel.edu +1 -0 - refclock_parse.c: - remove io binding before io_closeclock() closes the file descriptor + ntpd/ntpd.1@1.48.26.1, 2009-12-08 07:45:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P9_RC1 - ntpd/refclock_parse.c@1.48, 2007-08-11 17:17:16+00:00, kardel@pogo.udel.edu +25 -10 - remove io binding before io_closeclock() closes the file descriptor + ntpd/ntpdsim-opts.c@1.50.26.1, 2009-12-08 07:45:20-05:00, stenn@whimsy.udel.edu +5 -5 + NTP_4_2_4P9_RC1 -ChangeSet@1.1505, 2007-08-09 20:30:55+00:00, kardel@pogo.udel.edu +1 -0 - ChangeLog: - [Bug 882] allow loopback interfaces to share addresses with other interfaces. - [Bug 884] don't access recv buffers after having them passed to the free list. + ntpd/ntpdsim-opts.h@1.50.26.1, 2009-12-08 07:45:20-05:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P9_RC1 - ChangeLog@1.25, 2007-08-09 20:30:26+00:00, kardel@pogo.udel.edu +3 -0 - [Bug 882] allow loopback interfaces to share addresses with other interfaces. - [Bug 884] don't access recv buffers after having them passed to the free list. + ntpd/ntpdsim-opts.texi@1.48.26.1, 2009-12-08 07:45:21-05:00, stenn@whimsy.udel.edu +61 -2 + NTP_4_2_4P9_RC1 -ChangeSet@1.1504, 2007-08-09 19:05:17+00:00, kardel@pogo.udel.edu +1 -0 - ntp_io.c: - Bug 884: no access to recv buffers after they are returned to free pool + ntpd/ntpdsim.1@1.48.26.1, 2009-12-08 07:45:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P9_RC1 - ntpd/ntp_io.c@1.252, 2007-08-09 19:01:30+00:00, kardel@pogo.udel.edu +9 -7 - Bug 884: no access to recv buffers after they are returned to free pool + ntpdc/ntpdc-opts.c@1.50.26.1, 2009-12-08 07:45:21-05:00, stenn@whimsy.udel.edu +5 -5 + NTP_4_2_4P9_RC1 -ChangeSet@1.1503, 2007-08-07 18:14:16+00:00, kardel@pogo.udel.edu +1 -0 - ntp_io.c: - Bug 882: loopback interfaces may share IP addresses with other interfaces - thus allow addresses also found on loopback interfaces to be used - as local address. + ntpdc/ntpdc-opts.h@1.50.26.1, 2009-12-08 07:45:21-05:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P9_RC1 - ntpd/ntp_io.c@1.251, 2007-08-07 18:09:50+00:00, kardel@pogo.udel.edu +1 -1 - Bug 882: loopback interfaces may share IP addresses with other interfaces - thus allow addresses also found on loopback interfaces to be used - as local address. + ntpdc/ntpdc-opts.texi@1.48.26.1, 2009-12-08 07:45:21-05:00, stenn@whimsy.udel.edu +7 -4 + NTP_4_2_4P9_RC1 -ChangeSet@1.1502, 2007-06-29 15:46:00-04:00, stenn@deacon.udel.edu +25 -0 - NTP_4_2_4P3 - TAG: NTP_4_2_4P3 + ntpdc/ntpdc.1@1.48.26.1, 2009-12-08 07:45:22-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P9_RC1 - ntpd/ntpd-opts.c@1.68, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + ntpq/ntpq-opts.c@1.52.26.1, 2009-12-08 07:45:22-05:00, stenn@whimsy.udel.edu +5 -5 + NTP_4_2_4P9_RC1 - ntpd/ntpd-opts.h@1.68, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +3 -3 - NTP_4_2_4P3 + ntpq/ntpq-opts.h@1.52.26.1, 2009-12-08 07:45:22-05:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P9_RC1 - ntpd/ntpd-opts.texi@1.67, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + ntpq/ntpq-opts.texi@1.49.26.1, 2009-12-08 07:45:22-05:00, stenn@whimsy.udel.edu +8 -4 + NTP_4_2_4P9_RC1 - ntpd/ntpd.1@1.66, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + ntpq/ntpq.1@1.48.26.1, 2009-12-08 07:45:23-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P9_RC1 - ntpd/ntpdsim-opts.c@1.68, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + packageinfo.sh@1.65.34.2, 2009-12-08 07:45:23-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P9_RC1 - ntpd/ntpdsim-opts.h@1.68, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +3 -3 - NTP_4_2_4P3 + sntp/sntp-opts.c@1.49.26.1, 2009-12-08 07:45:23-05:00, stenn@whimsy.udel.edu +5 -5 + NTP_4_2_4P9_RC1 - ntpd/ntpdsim-opts.texi@1.66, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +1 -1 - NTP_4_2_4P3 + sntp/sntp-opts.h@1.49.26.1, 2009-12-08 07:45:23-05:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P9_RC1 - ntpd/ntpdsim.1@1.66, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + sntp/sntp-opts.texi@1.46.26.1, 2009-12-08 07:45:24-05:00, stenn@whimsy.udel.edu +54 -2 + NTP_4_2_4P9_RC1 - ntpdc/ntpdc-opts.c@1.68, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + sntp/sntp.1@1.49.26.1, 2009-12-08 07:45:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P9_RC1 - ntpdc/ntpdc-opts.h@1.68, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +3 -3 - NTP_4_2_4P3 + util/ntp-keygen-opts.c@1.49.26.1, 2009-12-08 07:45:24-05:00, stenn@whimsy.udel.edu +5 -5 + NTP_4_2_4P9_RC1 - ntpdc/ntpdc-opts.texi@1.66, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + util/ntp-keygen-opts.h@1.49.26.1, 2009-12-08 07:45:24-05:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P9_RC1 - ntpdc/ntpdc.1@1.66, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + util/ntp-keygen-opts.texi@1.47.26.1, 2009-12-08 07:45:24-05:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P9_RC1 - ntpq/ntpq-opts.c@1.70, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + util/ntp-keygen.1@1.47.26.1, 2009-12-08 07:45:25-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P9_RC1 - ntpq/ntpq-opts.h@1.70, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +3 -3 - NTP_4_2_4P3 +ChangeSet@1.1436.15.72, 2009-12-08 05:36:47-05:00, stenn@whimsy.udel.edu +2 -0 + [Sec 1331] DoS with mode 7 packets - CVE-2009-3563 - ntpq/ntpq-opts.texi@1.67, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + NEWS@1.86.1.16, 2009-12-08 05:36:36-05:00, stenn@whimsy.udel.edu +34 -0 + [Sec 1331] DoS with mode 7 packets - CVE-2009-3563 - ntpq/ntpq.1@1.66, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + packageinfo.sh@1.65.34.1, 2009-12-08 05:36:36-05:00, stenn@whimsy.udel.edu +2 -2 + [Sec 1331] DoS with mode 7 packets - CVE-2009-3563 - packageinfo.sh@1.91, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 +ChangeSet@1.2083, 2009-12-07 11:58:19+01:00, burnicki@pogo.udel.edu +3 -0 + [Bug 508] Fixed leap second handling for Windows. - sntp/sntp-opts.c@1.66, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + ChangeLog@1.561, 2009-12-07 11:58:18+01:00, burnicki@pogo.udel.edu +1 -0 + [Bug 508] Fixed leap second handling for Windows. - sntp/sntp-opts.h@1.66, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +3 -3 - NTP_4_2_4P3 + ntpd/ntp_timer.c@1.56, 2009-12-07 11:58:18+01:00, burnicki@pogo.udel.edu +2 -0 + [Bug 508] Fixed leap second handling for Windows. - sntp/sntp-opts.texi@1.63, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +1 -1 - NTP_4_2_4P3 + ports/winnt/ntpd/nt_clockstuff.c@1.38, 2009-12-07 11:58:18+01:00, burnicki@pogo.udel.edu +17 -2 + [Bug 508] Fixed leap second handling for Windows. - sntp/sntp.1@1.66, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 +ChangeSet@1.2082, 2009-11-30 05:29:50-05:00, stenn@whimsy.udel.edu +27 -0 + NTP_4_2_5P250_RC + TAG: NTP_4_2_5P250_RC - util/ntp-keygen-opts.c@1.67, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + ChangeLog@1.560, 2009-11-30 05:29:40-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P250_RC - util/ntp-keygen-opts.h@1.67, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +3 -3 - NTP_4_2_4P3 + ntpd/ntpd-opts.c@1.245, 2009-11-30 05:29:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P250_RC - util/ntp-keygen-opts.texi@1.65, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + ntpd/ntpd-opts.h@1.245, 2009-11-30 05:29:41-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P250_RC - util/ntp-keygen.1@1.65, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + ntpd/ntpd-opts.texi@1.243, 2009-11-30 05:29:41-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P250_RC -ChangeSet@1.1501, 2007-06-29 15:31:21-04:00, stenn@deacon.udel.edu +3 -0 - Release 4.2.4p3 + ntpd/ntpd.1@1.243, 2009-11-30 05:29:41-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P250_RC - ChangeLog@1.24, 2007-06-29 15:30:58-04:00, stenn@deacon.udel.edu +1 -1 - Release 4.2.4p3 + ntpdc/ntpdc-opts.c@1.241, 2009-11-30 05:29:41-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P250_RC - NEWS@1.97, 2007-06-29 15:30:58-04:00, stenn@deacon.udel.edu +1 -1 - Release 4.2.4p3 + ntpdc/ntpdc-opts.h@1.241, 2009-11-30 05:29:42-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P250_RC - packageinfo.sh@1.90, 2007-06-29 15:30:58-04:00, stenn@deacon.udel.edu +1 -1 - Release 4.2.4p3 + ntpdc/ntpdc-opts.texi@1.240, 2009-11-30 05:29:42-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P250_RC -ChangeSet@1.1500, 2007-06-29 19:03:39+00:00, stenn@ntp1.isc.org +2 -0 - Cosmetic reformatting + ntpdc/ntpdc.1@1.240, 2009-11-30 05:29:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P250_RC - ChangeLog@1.23, 2007-06-29 19:03:32+00:00, stenn@ntp1.isc.org +70 -16 - Cosmetic reformatting + ntpq/ntpq-opts.c@1.242, 2009-11-30 05:29:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P250_RC - NEWS@1.96, 2007-06-29 19:03:32+00:00, stenn@ntp1.isc.org +4 -0 - Cosmetic reformatting + ntpq/ntpq-opts.h@1.242, 2009-11-30 05:29:43-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P250_RC -ChangeSet@1.1499, 2007-06-27 07:46:44-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P3_RC1 - TAG: NTP_4_2_4P3_RC1 + ntpq/ntpq-opts.texi@1.241, 2009-11-30 05:29:43-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P250_RC - ntpd/ntpd-opts.c@1.67, 2007-06-27 07:46:22-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + ntpq/ntpq.1@1.241, 2009-11-30 05:29:43-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P250_RC - ntpd/ntpd-opts.h@1.67, 2007-06-27 07:46:23-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P3_RC1 + ntpsnmpd/ntpsnmpd-opts.c@1.120, 2009-11-30 05:29:43-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P250_RC - ntpd/ntpd-opts.texi@1.66, 2007-06-27 07:46:24-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + ntpsnmpd/ntpsnmpd-opts.h@1.120, 2009-11-30 05:29:43-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P250_RC - ntpd/ntpd.1@1.65, 2007-06-27 07:46:24-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + ntpsnmpd/ntpsnmpd-opts.texi@1.120, 2009-11-30 05:29:44-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P250_RC - ntpd/ntpdsim-opts.c@1.67, 2007-06-27 07:46:25-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + ntpsnmpd/ntpsnmpd.1@1.119, 2009-11-30 05:29:44-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P250_RC - ntpd/ntpdsim-opts.h@1.67, 2007-06-27 07:46:26-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P3_RC1 + packageinfo.sh@1.254, 2009-11-30 05:29:44-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P250_RC - ntpd/ntpdsim-opts.texi@1.65, 2007-06-27 07:46:27-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P3_RC1 + sntp/sntp-opts.c@1.114, 2009-11-30 05:29:44-05:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P250_RC - ntpd/ntpdsim.1@1.65, 2007-06-27 07:46:28-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + sntp/sntp-opts.h@1.114, 2009-11-30 05:29:45-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P250_RC - ntpdc/ntpdc-opts.c@1.67, 2007-06-27 07:46:29-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + sntp/sntp-opts.texi@1.114, 2009-11-30 05:29:45-05:00, stenn@whimsy.udel.edu +7 -7 + NTP_4_2_5P250_RC - ntpdc/ntpdc-opts.h@1.67, 2007-06-27 07:46:29-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P3_RC1 + sntp/sntp.1@1.114, 2009-11-30 05:29:45-05:00, stenn@whimsy.udel.edu +37 -37 + NTP_4_2_5P250_RC - ntpdc/ntpdc-opts.texi@1.65, 2007-06-27 07:46:30-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + sntp/sntp.html@1.4, 2009-11-30 05:29:45-05:00, stenn@whimsy.udel.edu +5 -5 + NTP_4_2_5P250_RC - ntpdc/ntpdc.1@1.65, 2007-06-27 07:46:31-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + util/ntp-keygen-opts.c@1.244, 2009-11-30 05:29:45-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P250_RC - ntpq/ntpq-opts.c@1.69, 2007-06-27 07:46:31-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + util/ntp-keygen-opts.h@1.244, 2009-11-30 05:29:46-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P250_RC - ntpq/ntpq-opts.h@1.69, 2007-06-27 07:46:32-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P3_RC1 + util/ntp-keygen-opts.texi@1.243, 2009-11-30 05:29:46-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P250_RC - ntpq/ntpq-opts.texi@1.66, 2007-06-27 07:46:33-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + util/ntp-keygen.1@1.243, 2009-11-30 05:29:46-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P250_RC - ntpq/ntpq.1@1.65, 2007-06-27 07:46:34-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 +ChangeSet@1.2081, 2009-11-30 04:19:28-05:00, stenn@whimsy.udel.edu +1 -0 + sntp documentation updates - packageinfo.sh@1.89, 2007-06-27 07:46:34-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + sntp/sntp.texi@1.3, 2009-11-30 04:19:16-05:00, stenn@whimsy.udel.edu +2 -2 + sntp documentation updates - sntp/sntp-opts.c@1.65, 2007-06-27 07:46:35-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 +ChangeSet@1.2080, 2009-11-30 04:15:15-05:00, stenn@whimsy.udel.edu +1 -0 + sntp documentation updates - sntp/sntp-opts.h@1.65, 2007-06-27 07:46:36-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P3_RC1 + sntp/sntp.texi@1.2, 2009-11-30 04:15:06-05:00, stenn@whimsy.udel.edu +4 -4 + sntp documentation updates - sntp/sntp-opts.texi@1.62, 2007-06-27 07:46:36-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P3_RC1 +ChangeSet@1.2079, 2009-11-30 04:06:48-05:00, stenn@whimsy.udel.edu +2 -0 + sntp documentation updates - sntp/sntp.1@1.65, 2007-06-27 07:46:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + ChangeLog@1.559, 2009-11-30 04:06:35-05:00, stenn@whimsy.udel.edu +1 -0 + sntp documentation updates - util/ntp-keygen-opts.c@1.66, 2007-06-27 07:46:38-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + sntp/sntp-opts.def@1.15, 2009-11-30 04:06:36-05:00, stenn@whimsy.udel.edu +21 -12 + sntp documentation updates - util/ntp-keygen-opts.h@1.66, 2007-06-27 07:46:39-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P3_RC1 +ChangeSet@1.2075.1.2, 2009-11-29 23:36:52-05:00, murray@malarky.udel.edu +2 -0 + ntp_intres.c, ChangeLog: + Fix for bug 1386: Deferred DNS doesn't work on NetBSD - util/ntp-keygen-opts.texi@1.64, 2007-06-27 07:46:40-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + ChangeLog@1.553.1.10, 2009-11-29 23:36:12-05:00, murray@malarky.udel.edu +1 -0 + Fix for bug 1386: Deferred DNS doesn't work on NetBSD - util/ntp-keygen.1@1.64, 2007-06-27 07:46:40-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + ntpd/ntp_intres.c@1.76, 2009-11-29 23:36:31-05:00, murray@malarky.udel.edu +28 -12 + Fix for bug 1386: Deferred DNS doesn't work on NetBSD -ChangeSet@1.1498, 2007-06-27 01:42:30-04:00, stenn@whimsy.udel.edu +3 -0 - First RC for 4.2.4p3 +ChangeSet@1.2075.1.1, 2009-11-28 21:30:09-05:00, murray@malarky.udel.edu +4 -0 + configure.ac: + Add --enable-force-defer-DNS + Helps debugging deferred DNS lookups. + ChangeLog: + Bug 761: internal resolver does not seem to honor -4/-6 qualifiers + ntp_config.c: + Bug 761: internal resolver does not seem to honor -4/-6 qualifiers + FORCE_DEFER_DNS helps debugging. + Pass no_needed to ntp_intres, first step on Bug 975. + ntp_intres.c: + Bug 761: internal resolver does not seem to honor -4/-6 qualifiers + Take no_needed from ntp_config, first step on Bug 975. - ChangeLog@1.22, 2007-06-27 01:41:43-04:00, stenn@whimsy.udel.edu +2 -1 - First RC for 4.2.4p3 + ChangeLog@1.553.1.9, 2009-11-28 21:25:58-05:00, murray@malarky.udel.edu +3 -0 + Bug 761: internal resolver does not seem to honor -4/-6 qualifiers - NEWS@1.95, 2007-06-27 01:41:46-04:00, stenn@whimsy.udel.edu +8 -0 - First RC for 4.2.4p3 + configure.ac@1.465, 2009-11-28 21:26:24-05:00, murray@malarky.udel.edu +16 -0 + Add --enable-force-defer-DNS + Helps debugging deferred DNS lookups. - packageinfo.sh@1.88, 2007-06-27 01:41:59-04:00, stenn@whimsy.udel.edu +1 -1 - First RC for 4.2.4p3 + ntpd/ntp_config.c@1.238, 2009-11-28 21:27:06-05:00, murray@malarky.udel.edu +20 -10 + Bug 761: internal resolver does not seem to honor -4/-6 qualifiers + FORCE_DEFER_DNS helps debugging. + Pass no_needed to ntp_intres, first step on Bug 975. -ChangeSet@1.1497, 2007-06-23 08:47:07-04:00, mayer@pogo.udel.edu +1 -0 - Added Bug #863 + ntpd/ntp_intres.c@1.75, 2009-11-28 21:28:21-05:00, murray@malarky.udel.edu +31 -17 + Bug 761: internal resolver does not seem to honor -4/-6 qualifiers + Take no_needed from ntp_config, first step on Bug 975. - ChangeLog@1.21, 2007-06-23 08:46:51-04:00, mayer@pogo.udel.edu +2 -0 - Added Bug #863 +ChangeSet@1.2077, 2009-11-28 23:42:10+00:00, davehart@shiny.ad.hartbrothers.com +7 -0 + [Bug 1391] avoid invoking autogen twice for .c and .h files. -ChangeSet@1.1492.1.1, 2007-06-23 08:42:58-04:00, mayer@pogo.udel.edu +3 -0 - Bug #863 Unable to stop ntpd because the handle index changed + ChangeLog@1.557, 2009-11-28 23:42:08+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1391] avoid invoking autogen twice for .c and .h files. - ports/winnt/include/ntp_iocompletionport.h@1.13, 2007-06-23 08:42:41-04:00, mayer@pogo.udel.edu +3 -0 - Bug #863 Unable to stop ntpd because the handle index changed + ntpd/Makefile.am@1.79, 2009-11-28 23:42:09+00:00, davehart@shiny.ad.hartbrothers.com +6 -2 + [Bug 1391] avoid invoking autogen twice for .c and .h files. - ports/winnt/ntpd/ntp_iocompletionport.c@1.23, 2007-06-23 08:42:41-04:00, mayer@pogo.udel.edu +15 -1 - Bug #863 Unable to stop ntpd because the handle index changed + ntpdc/Makefile.am@1.47, 2009-11-28 23:42:09+00:00, davehart@shiny.ad.hartbrothers.com +4 -1 + [Bug 1391] avoid invoking autogen twice for .c and .h files. - ports/winnt/ntpd/ntservice.c@1.9, 2007-06-23 08:42:41-04:00, mayer@pogo.udel.edu +9 -5 - Bug #863 Unable to stop ntpd because the handle index changed + ntpq/Makefile.am@1.42, 2009-11-28 23:42:09+00:00, davehart@shiny.ad.hartbrothers.com +4 -1 + [Bug 1391] avoid invoking autogen twice for .c and .h files. -ChangeSet@1.1495, 2007-06-20 07:45:57-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P2 - TAG: NTP_4_2_4P2 + ntpsnmpd/Makefile.am@1.15, 2009-11-28 23:42:09+00:00, davehart@shiny.ad.hartbrothers.com +4 -1 + [Bug 1391] avoid invoking autogen twice for .c and .h files. - ntpd/ntpd-opts.c@1.66, 2007-06-20 07:45:33-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + sntp/Makefile.am@1.20, 2009-11-28 23:42:09+00:00, davehart@shiny.ad.hartbrothers.com +12 -3 + [Bug 1391] avoid invoking autogen twice for .c and .h files. + when recursively building sntp binary for .texi rule, make libopts.la first - ntpd/ntpd-opts.h@1.66, 2007-06-20 07:45:33-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2 + util/Makefile.am@1.45, 2009-11-28 23:42:09+00:00, davehart@shiny.ad.hartbrothers.com +4 -1 + [Bug 1391] avoid invoking autogen twice for .c and .h files. - ntpd/ntpd-opts.texi@1.65, 2007-06-20 07:45:34-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P2 +ChangeSet@1.2075, 2009-11-28 05:29:18-05:00, stenn@whimsy.udel.edu +27 -0 + NTP_4_2_5P249_RC + TAG: NTP_4_2_5P249_RC - ntpd/ntpd.1@1.64, 2007-06-20 07:45:35-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + ChangeLog@1.553.1.8, 2009-11-28 05:29:06-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P249_RC - ntpd/ntpdsim-opts.c@1.66, 2007-06-20 07:45:35-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + ntpd/ntpd-opts.c@1.244, 2009-11-28 05:29:07-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P249_RC - ntpd/ntpdsim-opts.h@1.66, 2007-06-20 07:45:36-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2 + ntpd/ntpd-opts.h@1.244, 2009-11-28 05:29:07-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P249_RC - ntpd/ntpdsim-opts.texi@1.64, 2007-06-20 07:45:37-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2 + ntpd/ntpd-opts.texi@1.242, 2009-11-28 05:29:07-05:00, stenn@whimsy.udel.edu +2 -61 + NTP_4_2_5P249_RC - ntpd/ntpdsim.1@1.64, 2007-06-20 07:45:38-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + ntpd/ntpd.1@1.242, 2009-11-28 05:29:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P249_RC - ntpdc/ntpdc-opts.c@1.66, 2007-06-20 07:45:39-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + ntpdc/ntpdc-opts.c@1.240, 2009-11-28 05:29:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P249_RC - ntpdc/ntpdc-opts.h@1.66, 2007-06-20 07:45:39-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2 + ntpdc/ntpdc-opts.h@1.240, 2009-11-28 05:29:08-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P249_RC - ntpdc/ntpdc-opts.texi@1.64, 2007-06-20 07:45:40-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + ntpdc/ntpdc-opts.texi@1.239, 2009-11-28 05:29:08-05:00, stenn@whimsy.udel.edu +2 -66 + NTP_4_2_5P249_RC - ntpdc/ntpdc.1@1.64, 2007-06-20 07:45:41-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + ntpdc/ntpdc.1@1.239, 2009-11-28 05:29:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P249_RC - ntpq/ntpq-opts.c@1.68, 2007-06-20 07:45:42-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + ntpq/ntpq-opts.c@1.241, 2009-11-28 05:29:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P249_RC - ntpq/ntpq-opts.h@1.68, 2007-06-20 07:45:43-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2 + ntpq/ntpq-opts.h@1.241, 2009-11-28 05:29:09-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P249_RC - ntpq/ntpq-opts.texi@1.65, 2007-06-20 07:45:43-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + ntpq/ntpq-opts.texi@1.240, 2009-11-28 05:29:10-05:00, stenn@whimsy.udel.edu +2 -51 + NTP_4_2_5P249_RC - ntpq/ntpq.1@1.64, 2007-06-20 07:45:45-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + ntpq/ntpq.1@1.240, 2009-11-28 05:29:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P249_RC - packageinfo.sh@1.87, 2007-06-20 07:45:45-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + ntpsnmpd/ntpsnmpd-opts.c@1.119, 2009-11-28 05:29:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P249_RC - sntp/sntp-opts.c@1.64, 2007-06-20 07:45:46-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + ntpsnmpd/ntpsnmpd-opts.h@1.119, 2009-11-28 05:29:10-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P249_RC - sntp/sntp-opts.h@1.64, 2007-06-20 07:45:47-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2 + ntpsnmpd/ntpsnmpd-opts.texi@1.119, 2009-11-28 05:29:11-05:00, stenn@whimsy.udel.edu +2 -23 + NTP_4_2_5P249_RC - sntp/sntp-opts.texi@1.61, 2007-06-20 07:45:47-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2 + ntpsnmpd/ntpsnmpd.1@1.118, 2009-11-28 05:29:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P249_RC - sntp/sntp.1@1.64, 2007-06-20 07:45:48-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + packageinfo.sh@1.253, 2009-11-28 05:29:11-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P249_RC - util/ntp-keygen-opts.c@1.65, 2007-06-20 07:45:49-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + sntp/sntp-opts.c@1.113, 2009-11-28 05:29:11-05:00, stenn@whimsy.udel.edu +6 -5 + NTP_4_2_5P249_RC - util/ntp-keygen-opts.h@1.65, 2007-06-20 07:45:50-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2 + sntp/sntp-opts.h@1.113, 2009-11-28 05:29:12-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P249_RC - util/ntp-keygen-opts.texi@1.63, 2007-06-20 07:45:51-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + sntp/sntp-opts.texi@1.113, 2009-11-28 05:29:12-05:00, stenn@whimsy.udel.edu +4 -55 + NTP_4_2_5P249_RC - util/ntp-keygen.1@1.63, 2007-06-20 07:45:52-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + sntp/sntp.1@1.113, 2009-11-28 05:29:12-05:00, stenn@whimsy.udel.edu +18 -75 + NTP_4_2_5P249_RC -ChangeSet@1.1494, 2007-06-20 04:07:34-04:00, stenn@deacon.udel.edu +3 -0 - 4.2.4p2 + sntp/sntp.html@1.3, 2009-11-28 05:29:12-05:00, stenn@whimsy.udel.edu +26 -22 + NTP_4_2_5P249_RC - ChangeLog@1.20, 2007-06-20 04:07:25-04:00, stenn@deacon.udel.edu +1 -0 - 4.2.4p2 + util/ntp-keygen-opts.c@1.243, 2009-11-28 05:29:13-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P249_RC - NEWS@1.94, 2007-06-20 04:07:25-04:00, stenn@deacon.udel.edu +8 -13 - 4.2.4p2 + util/ntp-keygen-opts.h@1.243, 2009-11-28 05:29:13-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P249_RC - packageinfo.sh@1.86, 2007-06-20 04:07:26-04:00, stenn@deacon.udel.edu +1 -1 - 4.2.4p2 + util/ntp-keygen-opts.texi@1.242, 2009-11-28 05:29:13-05:00, stenn@whimsy.udel.edu +2 -46 + NTP_4_2_5P249_RC -ChangeSet@1.1493, 2007-06-10 07:58:59-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P2_RC6 - TAG: NTP_4_2_4P2_RC6 + util/ntp-keygen.1@1.242, 2009-11-28 05:29:13-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P249_RC - ntpd/ntpd-opts.c@1.65, 2007-06-10 07:58:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 +ChangeSet@1.2074, 2009-11-28 04:25:13-05:00, stenn@whimsy.udel.edu +1 -0 + cleanup - ntpd/ntpd-opts.h@1.65, 2007-06-10 07:58:37-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC6 + sntp/main.c@1.24, 2009-11-28 04:24:57-05:00, stenn@whimsy.udel.edu +2 -1 + cleanup - ntpd/ntpd-opts.texi@1.64, 2007-06-10 07:58:38-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC6 +ChangeSet@1.2072, 2009-11-28 01:43:01-05:00, stenn@whimsy.udel.edu +4 -0 + sntp cleanup - ntpd/ntpd.1@1.63, 2007-06-10 07:58:39-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 + ChangeLog@1.553.1.6, 2009-11-28 01:41:37-05:00, stenn@whimsy.udel.edu +1 -0 + sntp documentation cleanup - ntpd/ntpdsim-opts.c@1.65, 2007-06-10 07:58:40-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 + ChangeLog@1.553.1.5, 2009-11-28 01:40:32-05:00, stenn@whimsy.udel.edu +3 -0 + sntp: Show dispersion. Clean up error messages and offset - ntpd/ntpdsim-opts.h@1.65, 2007-06-10 07:58:41-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC6 + sntp/main.c@1.23, 2009-11-28 01:40:32-05:00, stenn@whimsy.udel.edu +33 -18 + sntp: Show dispersion. Clean up error messages and offset - ntpd/ntpdsim-opts.texi@1.63, 2007-06-10 07:58:41-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC6 + sntp/networking.h@1.17, 2009-11-28 01:40:51-05:00, stenn@whimsy.udel.edu +1 -1 + cleanup - ntpd/ntpdsim.1@1.63, 2007-06-10 07:58:42-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 + sntp/sntp-opts.def@1.14, 2009-11-28 01:41:37-05:00, stenn@whimsy.udel.edu +16 -74 + sntp documentation cleanup - ntpdc/ntpdc-opts.c@1.65, 2007-06-10 07:58:42-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 +ChangeSet@1.2070.1.1, 2009-11-28 06:31:50+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1400] An empty KOD DB file causes sntp to coredump. - ntpdc/ntpdc-opts.h@1.65, 2007-06-10 07:58:43-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC6 + ChangeLog@1.553.2.1, 2009-11-28 06:31:49+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1400] An empty KOD DB file causes sntp to coredump. - ntpdc/ntpdc-opts.texi@1.63, 2007-06-10 07:58:44-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC6 + sntp/kod_management.c@1.15, 2009-11-28 06:31:49+00:00, davehart@shiny.ad.hartbrothers.com +45 -26 + [Bug 1400] An empty KOD DB file causes sntp to coredump. - ntpdc/ntpdc.1@1.63, 2007-06-10 07:58:44-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 +ChangeSet@1.2071, 2009-11-28 01:27:47-05:00, stenn@whimsy.udel.edu +5 -0 + Cleanup from the autoconf/automake upgrades - ntpq/ntpq-opts.c@1.67, 2007-06-10 07:58:45-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 + ChangeLog@1.553.1.4, 2009-11-28 01:27:32-05:00, stenn@whimsy.udel.edu +1 -0 + Cleanup from the autoconf/automake upgrades - ntpq/ntpq-opts.h@1.67, 2007-06-10 07:58:46-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC6 + Makefile.am@1.89, 2009-11-28 01:27:33-05:00, stenn@whimsy.udel.edu +1 -1 + Cleanup from the autoconf/automake upgrades - ntpq/ntpq-opts.texi@1.64, 2007-06-10 07:58:46-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC6 + configure.ac@1.464, 2009-11-28 01:27:32-05:00, stenn@whimsy.udel.edu +1 -1 + Cleanup from the autoconf/automake upgrades - ntpq/ntpq.1@1.63, 2007-06-10 07:58:47-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 + sntp/Makefile.am@1.19, 2009-11-28 01:27:33-05:00, stenn@whimsy.udel.edu +18 -12 + Cleanup from the autoconf/automake upgrades - packageinfo.sh@1.85, 2007-06-10 07:58:48-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC6 + sntp/configure.ac@1.28, 2009-11-28 01:27:33-05:00, stenn@whimsy.udel.edu +1 -0 + Cleanup from the autoconf/automake upgrades - sntp/sntp-opts.c@1.63, 2007-06-10 07:58:49-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 +ChangeSet@1.2070, 2009-11-26 05:39:41-05:00, stenn@whimsy.udel.edu +27 -0 + NTP_4_2_5P248_RC + TAG: NTP_4_2_5P248_RC - sntp/sntp-opts.h@1.63, 2007-06-10 07:58:50-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC6 + ChangeLog@1.553.1.3, 2009-11-26 05:39:30-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P248_RC - sntp/sntp-opts.texi@1.60, 2007-06-10 07:58:50-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC6 + ntpd/ntpd-opts.c@1.243, 2009-11-26 05:39:30-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P248_RC - sntp/sntp.1@1.63, 2007-06-10 07:58:51-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 + ntpd/ntpd-opts.h@1.243, 2009-11-26 05:39:30-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P248_RC - util/ntp-keygen-opts.c@1.64, 2007-06-10 07:58:51-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 + ntpd/ntpd-opts.texi@1.241, 2009-11-26 05:39:30-05:00, stenn@whimsy.udel.edu +9 -4 + NTP_4_2_5P248_RC - util/ntp-keygen-opts.h@1.64, 2007-06-10 07:58:52-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC6 + ntpd/ntpd.1@1.241, 2009-11-26 05:39:31-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P248_RC - util/ntp-keygen-opts.texi@1.62, 2007-06-10 07:58:53-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC6 + ntpdc/ntpdc-opts.c@1.239, 2009-11-26 05:39:31-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P248_RC - util/ntp-keygen.1@1.62, 2007-06-10 07:58:54-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 + ntpdc/ntpdc-opts.h@1.239, 2009-11-26 05:39:31-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P248_RC -ChangeSet@1.1492, 2007-06-07 09:28:16-04:00, mayer@pogo.udel.edu +1 -0 - Bug #854 Broadcast address was not correctly set for interface addresses + ntpdc/ntpdc-opts.texi@1.238, 2009-11-26 05:39:32-05:00, stenn@whimsy.udel.edu +7 -4 + NTP_4_2_5P248_RC - ChangeLog@1.19, 2007-06-07 09:28:05-04:00, mayer@pogo.udel.edu +1 -0 - Bug #854 Broadcast address was not correctly set for interface addresses + ntpdc/ntpdc.1@1.238, 2009-11-26 05:39:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P248_RC -ChangeSet@1.1491, 2007-06-07 09:25:17-04:00, mayer@pogo.udel.edu +1 -0 - Bug #854 Broadcast address was not correctly set for interface addresses + ntpq/ntpq-opts.c@1.240, 2009-11-26 05:39:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P248_RC - ports/winnt/libisc/interfaceiter.c@1.7, 2007-06-07 09:24:57-04:00, mayer@pogo.udel.edu +35 -13 - Bug #854 Broadcast address was not correctly set for interface addresses + ntpq/ntpq-opts.h@1.240, 2009-11-26 05:39:32-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P248_RC -ChangeSet@1.1490, 2007-05-29 07:43:58-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P2_RC5 - TAG: NTP_4_2_4P2_RC5 + ntpq/ntpq-opts.texi@1.239, 2009-11-26 05:39:33-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P248_RC - ntpd/ntpd-opts.c@1.64, 2007-05-29 07:43:35-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 + ntpq/ntpq.1@1.239, 2009-11-26 05:39:33-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P248_RC - ntpd/ntpd-opts.h@1.64, 2007-05-29 07:43:35-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC5 + ntpsnmpd/ntpsnmpd-opts.c@1.118, 2009-11-26 05:39:33-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P248_RC - ntpd/ntpd-opts.texi@1.63, 2007-05-29 07:43:36-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC5 + ntpsnmpd/ntpsnmpd-opts.h@1.118, 2009-11-26 05:39:33-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P248_RC - ntpd/ntpd.1@1.62, 2007-05-29 07:43:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 + ntpsnmpd/ntpsnmpd-opts.texi@1.118, 2009-11-26 05:39:34-05:00, stenn@whimsy.udel.edu +23 -2 + NTP_4_2_5P248_RC - ntpd/ntpdsim-opts.c@1.64, 2007-05-29 07:43:38-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 + ntpsnmpd/ntpsnmpd.1@1.117, 2009-11-26 05:39:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P248_RC - ntpd/ntpdsim-opts.h@1.64, 2007-05-29 07:43:39-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC5 + packageinfo.sh@1.252, 2009-11-26 05:39:34-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P248_RC - ntpd/ntpdsim-opts.texi@1.62, 2007-05-29 07:43:40-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC5 + sntp/sntp-opts.c@1.112, 2009-11-26 05:39:34-05:00, stenn@whimsy.udel.edu +13 -9 + NTP_4_2_5P248_RC - ntpd/ntpdsim.1@1.62, 2007-05-29 07:43:40-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 + sntp/sntp-opts.h@1.112, 2009-11-26 05:39:35-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P248_RC - ntpdc/ntpdc-opts.c@1.64, 2007-05-29 07:43:41-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 + sntp/sntp-opts.texi@1.112, 2009-11-26 05:39:35-05:00, stenn@whimsy.udel.edu +18 -10 + NTP_4_2_5P248_RC - ntpdc/ntpdc-opts.h@1.64, 2007-05-29 07:43:42-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC5 + sntp/sntp.1@1.112, 2009-11-26 05:39:35-05:00, stenn@whimsy.udel.edu +7 -38 + NTP_4_2_5P248_RC - ntpdc/ntpdc-opts.texi@1.62, 2007-05-29 07:43:43-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC5 + sntp/sntp.html@1.2, 2009-11-26 05:39:35-05:00, stenn@whimsy.udel.edu +22 -26 + NTP_4_2_5P248_RC - ntpdc/ntpdc.1@1.62, 2007-05-29 07:43:43-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 + util/ntp-keygen-opts.c@1.242, 2009-11-26 05:39:36-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P248_RC - ntpq/ntpq-opts.c@1.66, 2007-05-29 07:43:44-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 + util/ntp-keygen-opts.h@1.242, 2009-11-26 05:39:36-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P248_RC - ntpq/ntpq-opts.h@1.66, 2007-05-29 07:43:45-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC5 + util/ntp-keygen-opts.texi@1.241, 2009-11-26 05:39:36-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P248_RC - ntpq/ntpq-opts.texi@1.63, 2007-05-29 07:43:45-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC5 + util/ntp-keygen.1@1.241, 2009-11-26 05:39:36-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P248_RC - ntpq/ntpq.1@1.62, 2007-05-29 07:43:46-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 +ChangeSet@1.2069, 2009-11-26 03:45:44-05:00, stenn@whimsy.udel.edu +4 -0 + updates for sntp/sntp.html - packageinfo.sh@1.84, 2007-05-29 07:43:47-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC5 + .point-changed-filelist@1.7, 2009-11-26 03:45:29-05:00, stenn@whimsy.udel.edu +1 -0 + updates for sntp/sntp.html - sntp/sntp-opts.c@1.62, 2007-05-29 07:43:48-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-version.texi~39e8aa5321c3de71@1.2, 2009-11-26 03:42:47-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: include/version.texi - sntp/sntp-opts.h@1.62, 2007-05-29 07:43:49-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-version.texi~dc1d08ee311794@1.2, 2009-11-26 03:42:47-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/version.texi - sntp/sntp-opts.texi@1.59, 2007-05-29 07:43:49-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC5 + BitKeeper/etc/ignore@1.74, 2009-11-26 03:45:29-05:00, stenn@whimsy.udel.edu +4 -3 + updates for sntp/sntp.html - sntp/sntp.1@1.62, 2007-05-29 07:43:50-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 + BitKeeper/etc/ignore@1.73, 2009-11-26 03:42:15-05:00, stenn@whimsy.udel.edu +1 -0 + added version.texi - util/ntp-keygen-opts.c@1.63, 2007-05-29 07:43:51-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 +ChangeSet@1.2068, 2009-11-26 07:04:26+00:00, hart@pogo.udel.edu +2 -0 + .del-depsver.mf~797b9b4e1db319be: + Delete: sntp/depsver.mf + ignore: + added sntp/depsver.mf + + sntp/depsver.mf is 'generated' (copied) from top-level depsver.mf + by bootstrap script + - util/ntp-keygen-opts.h@1.63, 2007-05-29 07:43:52-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-depsver.mf~797b9b4e1db319be@1.2, 2009-11-26 07:03:15+00:00, hart@pogo.udel.edu +0 -0 + Delete: sntp/depsver.mf - util/ntp-keygen-opts.texi@1.61, 2007-05-29 07:43:53-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC5 + BitKeeper/etc/ignore@1.72, 2009-11-26 07:03:16+00:00, hart@pogo.udel.edu +1 -0 + added sntp/depsver.mf - util/ntp-keygen.1@1.61, 2007-05-29 07:43:54-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 +ChangeSet@1.2067, 2009-11-26 01:42:32-05:00, stenn@psp-deb1.ntp.org +1 -0 + bk: ignore ltmain.sh -ChangeSet@1.1489, 2007-05-29 01:32:29-04:00, stenn@whimsy.udel.edu +2 -0 - typo cleanup + BitKeeper/etc/ignore@1.71, 2009-11-26 01:41:48-05:00, stenn@psp-deb1.ntp.org +1 -0 + added ltmain.sh - ChangeLog@1.18, 2007-05-29 01:32:14-04:00, stenn@whimsy.udel.edu +1 -1 - typo cleanup +ChangeSet@1.2065, 2009-11-26 01:33:57-05:00, stenn@psp-deb1.ntp.org +7 -0 + Prepare for the generation of sntp.html - NEWS@1.93, 2007-05-29 01:32:15-04:00, stenn@whimsy.udel.edu +1 -2 - typo cleanup + BitKeeper/etc/ignore@1.70, 2009-11-26 01:28:58-05:00, stenn@psp-deb1.ntp.org +1 -9 + Update the bk ignore list -ChangeSet@1.1488, 2007-05-28 10:00:27+00:00, kardel@pogo.udel.edu +3 -0 - NEWS, ntp_io.c, ChangeLog: - Bug 829: reduce syslog noise, while there fix Enabled/Disable logging - to reflect the actual configuration + BitKeeper/etc/ignore@1.69, 2009-11-26 01:25:16-05:00, stenn@psp-deb1.ntp.org +1 -0 + added config.cache-* - ChangeLog@1.17, 2007-05-28 09:54:40+00:00, kardel@pogo.udel.edu +2 -0 - Bug 829: reduce syslog noise, while there fix Enabled/Disable logging - to reflect the actual configuration + ChangeLog@1.551.2.1, 2009-11-26 01:33:04-05:00, stenn@psp-deb1.ntp.org +1 -0 + Prepare for the generation of sntp.html - NEWS@1.92, 2007-05-28 09:55:04+00:00, kardel@pogo.udel.edu +3 -0 - Bug 829: reduce syslog noise, while there fix Enabled/Disable logging - to reflect the actual configuration + include/version.texi@1.1, 2009-11-26 01:23:27-05:00, stenn@psp-deb1.ntp.org +3 -0 + BitKeeper file /home/stenn/ntp-dev-sntp/include/version.texi - ntpd/ntp_io.c@1.250, 2007-05-28 09:59:44+00:00, kardel@pogo.udel.edu +58 -44 - Bug 829: reduce syslog noise, while there fix Enabled/Disable logging - to reflect the actual configuration + include/version.texi@1.0, 2009-11-26 01:23:27-05:00, stenn@psp-deb1.ntp.org +0 -0 -ChangeSet@1.1487, 2007-05-27 07:45:05-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P2_RC4 - TAG: NTP_4_2_4P2_RC4 + sntp/Makefile.am@1.17, 2009-11-26 01:33:04-05:00, stenn@psp-deb1.ntp.org +1 -5 + Prepare for the generation of sntp.html - ntpd/ntpd-opts.c@1.63, 2007-05-27 07:44:40-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + sntp/depsver.mf@1.1, 2009-11-24 01:59:59-05:00, stenn@psp-deb1.ntp.org +67 -0 + BitKeeper file /home/stenn/ntp-dev-sntp/sntp/depsver.mf - ntpd/ntpd-opts.h@1.63, 2007-05-27 07:44:40-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC4 + sntp/depsver.mf@1.0, 2009-11-24 01:59:59-05:00, stenn@psp-deb1.ntp.org +0 -0 - ntpd/ntpd-opts.texi@1.62, 2007-05-27 07:44:41-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC4 + sntp/sntp.html@1.1, 2009-11-26 01:23:27-05:00, stenn@psp-deb1.ntp.org +105 -0 + BitKeeper file /home/stenn/ntp-dev-sntp/sntp/sntp.html - ntpd/ntpd.1@1.61, 2007-05-27 07:44:42-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + sntp/sntp.html@1.0, 2009-11-26 01:23:27-05:00, stenn@psp-deb1.ntp.org +0 -0 - ntpd/ntpdsim-opts.c@1.63, 2007-05-27 07:44:43-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + sntp/version.texi@1.1, 2009-11-26 01:23:27-05:00, stenn@psp-deb1.ntp.org +3 -0 + BitKeeper file /home/stenn/ntp-dev-sntp/sntp/version.texi - ntpd/ntpdsim-opts.h@1.63, 2007-05-27 07:44:44-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC4 + sntp/version.texi@1.0, 2009-11-26 01:23:27-05:00, stenn@psp-deb1.ntp.org +0 -0 - ntpd/ntpdsim-opts.texi@1.61, 2007-05-27 07:44:45-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC4 +ChangeSet@1.2060.23.1, 2009-11-26 01:16:35-05:00, stenn@whimsy.udel.edu +4 -0 + Documentation changes from Dave Mills - ntpd/ntpdsim.1@1.61, 2007-05-27 07:44:46-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + ChangeLog@1.553.1.1, 2009-11-26 01:16:05-05:00, stenn@whimsy.udel.edu +1 -0 + Documentation changes from Dave Mills - ntpdc/ntpdc-opts.c@1.63, 2007-05-27 07:44:46-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + html/confopt.html@1.48, 2009-11-26 01:16:15-05:00, stenn@whimsy.udel.edu +53 -60 + Documentation changes from Dave Mills - ntpdc/ntpdc-opts.h@1.63, 2007-05-27 07:44:47-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC4 + html/manyopt.html@1.20, 2009-11-26 01:16:17-05:00, stenn@whimsy.udel.edu +5 -3 + Documentation changes from Dave Mills - ntpdc/ntpdc-opts.texi@1.61, 2007-05-27 07:44:48-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC4 + html/quick.html@1.20, 2009-11-26 01:16:19-05:00, stenn@whimsy.udel.edu +17 -4 + Documentation changes from Dave Mills - ntpdc/ntpdc.1@1.61, 2007-05-27 07:44:49-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 +ChangeSet@1.2060.1.56, 2009-11-26 01:06:36-05:00, stenn@pogo.udel.edu +1 -0 + typo nit - ntpq/ntpq-opts.c@1.65, 2007-05-27 07:44:50-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + ChangeLog@1.555, 2009-11-26 01:06:24-05:00, stenn@pogo.udel.edu +1 -1 - ntpq/ntpq-opts.h@1.65, 2007-05-27 07:44:50-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC4 +ChangeSet@1.2060.22.1, 2009-11-25 14:19:20-05:00, murray@malarky.udel.edu +2 -0 + refclock_shm.c, ChangeLog: + Bug-1397: shmget() failing because of file mode - ntpq/ntpq-opts.texi@1.62, 2007-05-27 07:44:51-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC4 + ChangeLog@1.551.1.1, 2009-11-25 14:17:52-05:00, murray@malarky.udel.edu +1 -0 + Bug-1397: shmget() failing because of file mode - ntpq/ntpq.1@1.61, 2007-05-27 07:44:52-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + ntpd/refclock_shm.c@1.20, 2009-11-25 14:18:57-05:00, murray@malarky.udel.edu +1 -1 + Bug-1397: shmget() failing because of file mode - packageinfo.sh@1.83, 2007-05-27 07:44:52-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC4 +ChangeSet@1.2060.1.54, 2009-11-24 22:05:54+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + One more missing free(), thanks to Hal Murray's sharp eyes - sntp/sntp-opts.c@1.61, 2007-05-27 07:44:53-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + ntpd/ntp_intres.c@1.74, 2009-11-24 22:05:53+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + One more missing free(), thanks to Hal Murray's sharp eyes - sntp/sntp-opts.h@1.61, 2007-05-27 07:44:54-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC4 +ChangeSet@1.2060.1.53, 2009-11-24 14:51:38+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1387] free() conf_entry in ntp_intres removeentry(). + [Bug 1392] intres retries duplicate assocations endlessly. - sntp/sntp-opts.texi@1.58, 2007-05-27 07:44:55-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC4 + ChangeLog@1.553, 2009-11-24 14:51:37+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1387] free() conf_entry in ntp_intres removeentry(). + [Bug 1392] intres retries duplicate assocations endlessly. - sntp/sntp.1@1.61, 2007-05-27 07:44:55-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + ntpd/ntp_intres.c@1.73, 2009-11-24 14:51:37+00:00, davehart@shiny.ad.hartbrothers.com +31 -26 + [Bug 1387] free() conf_entry in ntp_intres removeentry(). + [Bug 1392] intres retries duplicate assocations endlessly. - util/ntp-keygen-opts.c@1.62, 2007-05-27 07:44:56-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + ntpd/ntp_peer.c@1.126, 2009-11-24 14:51:37+00:00, davehart@shiny.ad.hartbrothers.com +6 -11 + use DPRINTF - util/ntp-keygen-opts.h@1.62, 2007-05-27 07:44:57-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC4 +ChangeSet@1.2060.1.52, 2009-11-23 17:43:13+00:00, davehart@shiny.ad.hartbrothers.com +10 -0 + [Bug 1387] Storage leak in ntp_intres (minor). + [Bug 1389] buffer overflow in refclock_oncore.c + [Bug 1391] .texi usage text from installed, not built binaries. + Correct *-opts.h dependency so default 'get' action isn't used. + - util/ntp-keygen-opts.texi@1.60, 2007-05-27 07:44:58-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC4 + ChangeLog@1.552, 2009-11-23 17:43:12+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1387] Storage leak in ntp_intres (minor). + [Bug 1389] buffer overflow in refclock_oncore.c + [Bug 1391] .texi usage text from installed, not built binaries. + Correct *-opts.h dependency so default 'get' action isn't used. + - util/ntp-keygen.1@1.60, 2007-05-27 07:44:59-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + configure.ac@1.459.1.14, 2009-11-23 17:43:12+00:00, davehart@shiny.ad.hartbrothers.com +3 -4 + [Bug 1391] .texi usage text from installed, not built binaries. + no functional change to configure.ac, eliminate duplicate + "checking for net-snmp-config" messages and clarify help text + for --with-ntpsnmpd. -ChangeSet@1.1486, 2007-05-27 00:52:52-04:00, stenn@whimsy.udel.edu +1 -0 - update NEWS file with new fixes + ntpd/Makefile.am@1.78, 2009-11-23 17:43:12+00:00, davehart@shiny.ad.hartbrothers.com +5 -3 + [Bug 1391] .texi usage text from installed, not built binaries. + Correct *-opts.h dependency so default 'get' action isn't used. - NEWS@1.91, 2007-05-27 00:52:43-04:00, stenn@whimsy.udel.edu +6 -0 - update NEWS file with new fixes + ntpd/ntp_intres.c@1.72, 2009-11-23 17:43:12+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1387] Storage leak in ntp_intres (minor). -ChangeSet@1.1485, 2007-05-27 00:31:51-04:00, stenn@deacon.udel.edu +1 -0 - Cleanup + ntpd/refclock_oncore.c@1.81, 2009-11-23 17:43:12+00:00, davehart@shiny.ad.hartbrothers.com +306 -191 + * [Bug 1389] buffer overflow in refclock_oncore.c - ChangeLog@1.16, 2007-05-27 00:31:40-04:00, stenn@deacon.udel.edu +2 -2 - Cleanup + ntpdc/Makefile.am@1.46, 2009-11-23 17:43:12+00:00, davehart@shiny.ad.hartbrothers.com +5 -3 + [Bug 1391] .texi usage text from installed, not built binaries. + Correct *-opts.h dependency so default 'get' action isn't used. -ChangeSet@1.1484, 2007-05-26 08:00:03+00:00, kardel@pogo.udel.edu +2 -0 - ntp_io.c: - [Bug 795] Moved declaration of variable to top of function. - ChangeLog: - [Bug 795] Moved declaration of variable to top of function. + ntpq/Makefile.am@1.41, 2009-11-23 17:43:12+00:00, davehart@shiny.ad.hartbrothers.com +5 -3 + [Bug 1391] .texi usage text from installed, not built binaries. + Correct *-opts.h dependency so default 'get' action isn't used. - ChangeLog@1.15, 2007-05-26 07:57:22+00:00, kardel@pogo.udel.edu +1 -0 - Bug 795 + ntpsnmpd/Makefile.am@1.14, 2009-11-23 17:43:12+00:00, davehart@shiny.ad.hartbrothers.com +8 -3 + [Bug 1391] .texi usage text from installed, not built binaries. + Correct *-opts.h dependency so default 'get' action isn't used. - ntpd/ntp_io.c@1.249, 2007-05-26 07:58:40+00:00, kardel@pogo.udel.edu +4 -1 - [Bug 795] Moved declaration of variable to top of function. + sntp/Makefile.am@1.13.1.6, 2009-11-23 17:43:12+00:00, davehart@shiny.ad.hartbrothers.com +5 -3 + [Bug 1391] .texi usage text from installed, not built binaries. + Correct *-opts.h dependency so default 'get' action isn't used. -ChangeSet@1.1480.1.9, 2007-05-25 07:44:43-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P2_RC3 - TAG: NTP_4_2_4P2_RC3 + util/Makefile.am@1.44, 2009-11-23 17:43:13+00:00, davehart@shiny.ad.hartbrothers.com +5 -3 + [Bug 1391] .texi usage text from installed, not built binaries. + Correct *-opts.h dependency so default 'get' action isn't used. - ntpd/ntpd-opts.c@1.62, 2007-05-25 07:44:20-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 +ChangeSet@1.2060.1.51, 2009-11-20 05:36:49-05:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P247_RC + TAG: NTP_4_2_5P247_RC - ntpd/ntpd-opts.h@1.62, 2007-05-25 07:44:21-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC3 + ChangeLog@1.551, 2009-11-20 05:36:38-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P247_RC - ntpd/ntpd-opts.texi@1.61, 2007-05-25 07:44:22-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC3 + ntpd/ntpd-opts.c@1.242, 2009-11-20 05:36:39-05:00, stenn@whimsy.udel.edu +5 -5 + NTP_4_2_5P247_RC - ntpd/ntpd.1@1.60, 2007-05-25 07:44:23-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 + ntpd/ntpd-opts.h@1.242, 2009-11-20 05:36:39-05:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P247_RC - ntpd/ntpdsim-opts.c@1.62, 2007-05-25 07:44:23-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 + ntpd/ntpd-opts.texi@1.240, 2009-11-20 05:36:39-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P247_RC - ntpd/ntpdsim-opts.h@1.62, 2007-05-25 07:44:24-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC3 + ntpd/ntpd.1@1.240, 2009-11-20 05:36:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P247_RC - ntpd/ntpdsim-opts.texi@1.60, 2007-05-25 07:44:25-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC3 + ntpdc/ntpdc-opts.c@1.238, 2009-11-20 05:36:40-05:00, stenn@whimsy.udel.edu +5 -5 + NTP_4_2_5P247_RC - ntpd/ntpdsim.1@1.60, 2007-05-25 07:44:25-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 + ntpdc/ntpdc-opts.h@1.238, 2009-11-20 05:36:40-05:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P247_RC - ntpdc/ntpdc-opts.c@1.62, 2007-05-25 07:44:26-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 + ntpdc/ntpdc-opts.texi@1.237, 2009-11-20 05:36:40-05:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P247_RC - ntpdc/ntpdc-opts.h@1.62, 2007-05-25 07:44:27-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC3 + ntpdc/ntpdc.1@1.237, 2009-11-20 05:36:41-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P247_RC - ntpdc/ntpdc-opts.texi@1.60, 2007-05-25 07:44:28-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC3 + ntpq/ntpq-opts.c@1.239, 2009-11-20 05:36:41-05:00, stenn@whimsy.udel.edu +5 -5 + NTP_4_2_5P247_RC - ntpdc/ntpdc.1@1.60, 2007-05-25 07:44:28-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 + ntpq/ntpq-opts.h@1.239, 2009-11-20 05:36:41-05:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P247_RC - ntpq/ntpq-opts.c@1.64, 2007-05-25 07:44:29-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 + ntpq/ntpq-opts.texi@1.238, 2009-11-20 05:36:41-05:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P247_RC - ntpq/ntpq-opts.h@1.64, 2007-05-25 07:44:30-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC3 + ntpq/ntpq.1@1.238, 2009-11-20 05:36:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P247_RC - ntpq/ntpq-opts.texi@1.61, 2007-05-25 07:44:31-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC3 + ntpsnmpd/ntpsnmpd-opts.c@1.117, 2009-11-20 05:36:42-05:00, stenn@whimsy.udel.edu +5 -5 + NTP_4_2_5P247_RC - ntpq/ntpq.1@1.60, 2007-05-25 07:44:32-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 + ntpsnmpd/ntpsnmpd-opts.h@1.117, 2009-11-20 05:36:42-05:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P247_RC - packageinfo.sh@1.82, 2007-05-25 07:44:33-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC3 + ntpsnmpd/ntpsnmpd-opts.texi@1.117, 2009-11-20 05:36:42-05:00, stenn@whimsy.udel.edu +2 -23 + NTP_4_2_5P247_RC - sntp/sntp-opts.c@1.60, 2007-05-25 07:44:33-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 + ntpsnmpd/ntpsnmpd.1@1.116, 2009-11-20 05:36:43-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P247_RC - sntp/sntp-opts.h@1.60, 2007-05-25 07:44:35-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC3 + packageinfo.sh@1.251, 2009-11-20 05:36:43-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P247_RC - sntp/sntp-opts.texi@1.57, 2007-05-25 07:44:35-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC3 + sntp/sntp-opts.c@1.111, 2009-11-20 05:36:43-05:00, stenn@whimsy.udel.edu +5 -5 + NTP_4_2_5P247_RC - sntp/sntp.1@1.60, 2007-05-25 07:44:36-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 + sntp/sntp-opts.h@1.111, 2009-11-20 05:36:43-05:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P247_RC - util/ntp-keygen-opts.c@1.61, 2007-05-25 07:44:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 + sntp/sntp-opts.texi@1.111, 2009-11-20 05:36:44-05:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P247_RC - util/ntp-keygen-opts.h@1.61, 2007-05-25 07:44:38-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC3 + sntp/sntp.1@1.111, 2009-11-20 05:36:44-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P247_RC - util/ntp-keygen-opts.texi@1.59, 2007-05-25 07:44:38-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC3 + util/ntp-keygen-opts.c@1.241, 2009-11-20 05:36:44-05:00, stenn@whimsy.udel.edu +5 -5 + NTP_4_2_5P247_RC - util/ntp-keygen.1@1.59, 2007-05-25 07:44:39-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 + util/ntp-keygen-opts.h@1.241, 2009-11-20 05:36:44-05:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P247_RC -ChangeSet@1.1480.1.8, 2007-05-25 02:18:59-04:00, stenn@whimsy.udel.edu +1 -0 - cleanup + util/ntp-keygen-opts.texi@1.240, 2009-11-20 05:36:45-05:00, stenn@whimsy.udel.edu +5 -5 + NTP_4_2_5P247_RC - NEWS@1.90, 2007-05-25 02:18:48-04:00, stenn@whimsy.udel.edu +1 -0 - cleanup + util/ntp-keygen.1@1.240, 2009-11-20 05:36:45-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P247_RC -ChangeSet@1.1480.2.1, 2007-05-25 02:06:52-04:00, stenn@whimsy.udel.edu +2 -0 - Upgraded autogen and libopts +ChangeSet@1.2060.1.50, 2009-11-18 04:29:17+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + [Bug 1308] support systems that lack fork(). - ChangeLog@1.11.2.1, 2007-05-25 02:06:37-04:00, stenn@whimsy.udel.edu +1 -0 - Upgraded autogen and libopts + ChangeLog@1.550, 2009-11-18 04:29:16+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1308] support systems that lack fork(). - NEWS@1.89, 2007-05-25 02:06:38-04:00, stenn@whimsy.udel.edu +1 -0 - Upgraded autogen and libopts + configure.ac@1.459.1.13, 2009-11-18 04:29:16+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1308] support systems that lack fork(). -ChangeSet@1.1480.1.6, 2007-05-25 01:07:59-04:00, stenn@pogo.udel.edu +1 -0 - cleanup ChangeLog + include/ntp_config.h@1.66, 2009-11-18 04:29:16+00:00, davehart@shiny.ad.hartbrothers.com +12 -1 + setup NO_INTRES macro on systems which do not support fork or threads - ChangeLog@1.11.1.3, 2007-05-25 01:07:52-04:00, stenn@pogo.udel.edu +1 -1 - cleanup ChangeLog + include/ntp_machine.h@1.26, 2009-11-18 04:29:16+00:00, davehart@shiny.ad.hartbrothers.com +3 -3 + stay out of compiler/system underscore namespace -ChangeSet@1.1480.1.5, 2007-05-24 08:10:30-04:00, mayer@pogo.udel.edu +1 -0 - Bug #527 Don't write from source address length to wrong location + ntpd/ntp_config.c@1.237, 2009-11-18 04:29:17+00:00, davehart@shiny.ad.hartbrothers.com +12 -23 + [Bug 1308] support systems that lack fork(). - ChangeLog@1.11.1.2, 2007-05-24 08:10:20-04:00, mayer@pogo.udel.edu +1 -0 - Bug #527 Don't write from source address length to wrong location + ntpd/ntp_intres.c@1.71, 2009-11-18 04:29:17+00:00, davehart@shiny.ad.hartbrothers.com +7 -0 + [Bug 1308] support systems that lack fork(). -ChangeSet@1.1480.1.4, 2007-05-24 08:08:34-04:00, mayer@pogo.udel.edu +4 -0 - Bug #527 Don't write from source address length to wrong location +ChangeSet@1.2060.1.49, 2009-11-17 19:43:44+00:00, davehart@shiny.ad.hartbrothers.com +31 -0 + [Bug 1142] nodebug builds shed no light on -d, -D option failure. + [Bug 1179] point out the problem with -i/--jaildir and -u/--user when + they are disabled by configure. + -4/-6 are not equivalent in the libopts sense - include/recvbuff.h@1.12, 2007-05-24 08:08:03-04:00, mayer@pogo.udel.edu +2 -0 - Bug #527 Don't write from source address length to wrong location + ChangeLog@1.549, 2009-11-17 19:43:41+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + * [Bug 1142] nodebug builds shed no light on -d, -D option failure. + * [Bug 1179] point out the problem with -i/--jaildir and -u/--user when + they are disabled by configure. + - libntp/recvbuff.c@1.25, 2007-05-24 08:08:03-04:00, mayer@pogo.udel.edu +27 -13 - Bug #527 Don't write from source address length to wrong location + ntpd/cmd_args.c@1.56, 2009-11-17 19:43:41+00:00, davehart@shiny.ad.hartbrothers.com +9 -41 + [Bug 1142] nodebug builds shed no light on -d, -D option failure. + [Bug 1179] point out the problem with -i/--jaildir and -u/--user when + they are disabled by configure. + -4/-6 are not equivalent in the libopts sense + --authreq and --authnoreq are mutually exclusive - ports/winnt/libntp/transmitbuff.c@1.7, 2007-05-24 08:08:03-04:00, mayer@pogo.udel.edu +10 -10 - Bug #527 Don't write from source address length to wrong location + ntpd/ntpd-opts.c@1.241, 2009-11-17 19:43:41+00:00, davehart@shiny.ad.hartbrothers.com +28 -20 + updated Autogen output - ports/winnt/ntpd/ntp_iocompletionport.c@1.22, 2007-05-24 08:08:03-04:00, mayer@pogo.udel.edu +76 -62 - Bug #527 Don't write from source address length to wrong location + ntpd/ntpd-opts.h@1.241, 2009-11-17 19:43:41+00:00, davehart@shiny.ad.hartbrothers.com +2 -5 + updated Autogen output -ChangeSet@1.1480.1.3, 2007-05-19 07:53:57-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P2_RC2 - TAG: NTP_4_2_4P2_RC2 + ntpd/ntpd-opts.texi@1.239, 2009-11-17 19:43:41+00:00, davehart@shiny.ad.hartbrothers.com +17 -7 + updated Autogen output - ntpd/ntpd-opts.c@1.61, 2007-05-19 07:53:35-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P2_RC2 + ntpd/ntpd.1@1.239, 2009-11-17 19:43:41+00:00, davehart@shiny.ad.hartbrothers.com +16 -6 + updated Autogen output - ntpd/ntpd-opts.h@1.61, 2007-05-19 07:53:35-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC2 + ntpd/ntpdbase-opts.def@1.20, 2009-11-17 19:43:41+00:00, davehart@shiny.ad.hartbrothers.com +18 -6 + [Bug 1142] nodebug builds shed no light on -d, -D option failure. + [Bug 1179] point out the problem with -i/--jaildir and -u/--user when + they are disabled by configure. + -4/-6 are not equivalent in the libopts sense - ntpd/ntpd-opts.texi@1.60, 2007-05-19 07:53:36-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC2 + ntpdc/ntpdc-opts.c@1.237, 2009-11-17 19:43:41+00:00, davehart@shiny.ad.hartbrothers.com +19 -11 + updated Autogen output - ntpd/ntpd.1@1.59, 2007-05-19 07:53:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC2 + ntpdc/ntpdc-opts.def@1.14, 2009-11-17 19:43:41+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + -4/-6 are not equivalent in the libopts sense - ntpd/ntpdsim-opts.c@1.61, 2007-05-19 07:53:38-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P2_RC2 + ntpdc/ntpdc-opts.h@1.237, 2009-11-17 19:43:41+00:00, davehart@shiny.ad.hartbrothers.com +2 -5 + updated Autogen output - ntpd/ntpdsim-opts.h@1.61, 2007-05-19 07:53:39-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC2 + ntpdc/ntpdc-opts.texi@1.236, 2009-11-17 19:43:41+00:00, davehart@shiny.ad.hartbrothers.com +8 -6 + updated Autogen output - ntpd/ntpdsim-opts.texi@1.59, 2007-05-19 07:53:40-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC2 + ntpdc/ntpdc.1@1.236, 2009-11-17 19:43:41+00:00, davehart@shiny.ad.hartbrothers.com +5 -3 + updated Autogen output - ntpd/ntpdsim.1@1.59, 2007-05-19 07:53:40-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC2 + ntpdc/ntpdc.c@1.75, 2009-11-17 19:43:42+00:00, davehart@shiny.ad.hartbrothers.com +3 -8 + -4/-6 are not equivalent in the libopts sense - ntpdc/ntpdc-opts.c@1.61, 2007-05-19 07:53:41-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P2_RC2 + ntpq/ntpq-opts.c@1.238, 2009-11-17 19:43:42+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + updated Autogen output - ntpdc/ntpdc-opts.h@1.61, 2007-05-19 07:53:42-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC2 + ntpq/ntpq-opts.h@1.238, 2009-11-17 19:43:42+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + updated Autogen output - ntpdc/ntpdc-opts.texi@1.59, 2007-05-19 07:53:43-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC2 + ntpq/ntpq-opts.texi@1.237, 2009-11-17 19:43:42+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + updated Autogen output - ntpdc/ntpdc.1@1.59, 2007-05-19 07:53:43-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC2 + ntpq/ntpq.1@1.237, 2009-11-17 19:43:42+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + updated Autogen output - ntpq/ntpq-opts.c@1.63, 2007-05-19 07:53:44-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P2_RC2 + ntpq/ntpq.c@1.97, 2009-11-17 19:43:42+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + Don't use DPRINTF because #ifdef DEBUG isn't valid in utils - ntpq/ntpq-opts.h@1.63, 2007-05-19 07:53:45-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC2 + ntpsnmpd/ntpsnmpd-opts.c@1.116, 2009-11-17 19:43:42+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + updated Autogen output - ntpq/ntpq-opts.texi@1.60, 2007-05-19 07:53:46-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC2 + ntpsnmpd/ntpsnmpd-opts.h@1.116, 2009-11-17 19:43:42+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + updated Autogen output - ntpq/ntpq.1@1.59, 2007-05-19 07:53:47-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC2 + ntpsnmpd/ntpsnmpd-opts.texi@1.116, 2009-11-17 19:43:42+00:00, davehart@shiny.ad.hartbrothers.com +23 -2 + updated Autogen output - packageinfo.sh@1.81, 2007-05-19 07:53:48-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC2 + sntp/main.c@1.22, 2009-11-17 19:43:42+00:00, davehart@shiny.ad.hartbrothers.com +3 -5 + -4/-6 are not equivalent in the libopts sense - sntp/sntp-opts.c@1.59, 2007-05-19 07:53:48-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC2 + sntp/sntp-opts.c@1.110, 2009-11-17 19:43:42+00:00, davehart@shiny.ad.hartbrothers.com +19 -11 + updated Autogen output - sntp/sntp-opts.h@1.59, 2007-05-19 07:53:49-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC2 + sntp/sntp-opts.def@1.11.1.1, 2009-11-17 19:43:42+00:00, davehart@shiny.ad.hartbrothers.com +3 -2 + -4/-6 are not equivalent in the libopts sense - sntp/sntp-opts.texi@1.56, 2007-05-19 07:53:49-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC2 + sntp/sntp-opts.h@1.110, 2009-11-17 19:43:42+00:00, davehart@shiny.ad.hartbrothers.com +2 -5 + updated Autogen output - sntp/sntp.1@1.59, 2007-05-19 07:53:50-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC2 + sntp/sntp-opts.texi@1.110, 2009-11-17 19:43:42+00:00, davehart@shiny.ad.hartbrothers.com +8 -6 + updated Autogen output - util/ntp-keygen-opts.c@1.60, 2007-05-19 07:53:51-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P2_RC2 + sntp/sntp.1@1.110, 2009-11-17 19:43:42+00:00, davehart@shiny.ad.hartbrothers.com +5 -3 + updated Autogen output - util/ntp-keygen-opts.h@1.60, 2007-05-19 07:53:51-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC2 + util/ntp-keygen-opts.c@1.240, 2009-11-17 19:43:42+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + updated Autogen output - util/ntp-keygen-opts.texi@1.58, 2007-05-19 07:53:52-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC2 + util/ntp-keygen-opts.h@1.240, 2009-11-17 19:43:42+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + updated Autogen output - util/ntp-keygen.1@1.58, 2007-05-19 07:53:53-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC2 + util/ntp-keygen-opts.texi@1.239, 2009-11-17 19:43:43+00:00, davehart@shiny.ad.hartbrothers.com +5 -5 + updated Autogen output -ChangeSet@1.1480.1.2, 2007-05-19 02:33:04-04:00, stenn@whimsy.udel.edu +193 -0 - We need another RC release to be sure the new autogen/libopts works. + util/ntp-keygen.1@1.239, 2009-11-17 19:43:43+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + updated Autogen output - BitKeeper/deleted/.del-COPYING.lgpl~492b62c9d62ba57a@1.2, 2007-05-19 00:01:18-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/COPYING.lgpl +ChangeSet@1.2060.1.48, 2009-11-17 16:15:53+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1343] sntp doesn't link on Solaris 7, needs -lresolv. - BitKeeper/deleted/.del-COPYING.lgpl~adfa2ac04d64c0f7@1.2, 2007-05-19 00:00:02-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/COPYING.lgpl + ChangeLog@1.548, 2009-11-17 16:15:52+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1343] sntp doesn't link on Solaris 7, needs -lresolv. - BitKeeper/deleted/.del-COPYING.mbsd~7e1baaedfa33c877@1.2, 2007-05-19 00:00:03-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/COPYING.mbsd + configure.ac@1.459.1.12, 2009-11-17 16:15:52+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + Search for inet_ntop in -lresolv if not in default libs, needed + for sntp on Solaris 7 - BitKeeper/deleted/.del-COPYING.mbsd~e8244dcf5895b58f@1.2, 2007-05-19 00:01:19-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/COPYING.mbsd + sntp/configure.ac@1.27, 2009-11-17 16:15:52+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + Search for inet_ntop in -lresolv if not in default libs, needed + for sntp on Solaris 7 - BitKeeper/deleted/.del-MakeDefs.inc~3fd54e9b117bfdad@1.2, 2007-05-19 00:01:20-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/MakeDefs.inc +ChangeSet@1.2060.1.47, 2009-11-17 07:34:00-05:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P246_RC + TAG: NTP_4_2_5P246_RC - BitKeeper/deleted/.del-MakeDefs.inc~511eb438badc27b@1.2, 2007-05-19 00:00:04-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/MakeDefs.inc + ChangeLog@1.547, 2009-11-17 07:33:49-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-Makefile.am~65692661e68a4392@1.2, 2007-05-19 00:00:04-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/Makefile.am + ntpd/ntpd-opts.c@1.240, 2009-11-17 07:33:50-05:00, stenn@whimsy.udel.edu +32 -33 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-Makefile.am~fdf1a715e04b5f2c@1.2, 2007-05-19 00:01:21-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/Makefile.am + ntpd/ntpd-opts.h@1.240, 2009-11-17 07:33:50-05:00, stenn@whimsy.udel.edu +8 -21 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-README~7ed47aff36cc39c@1.2, 2007-05-19 00:01:22-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/README + ntpd/ntpd-opts.texi@1.238, 2009-11-17 07:33:50-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-README~cec57621589d1ea6@1.2, 2007-05-19 00:00:05-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/README + ntpd/ntpd.1@1.238, 2009-11-17 07:33:51-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-autoopts.c~7b48d6dc5ca9c3b@1.2, 2007-05-19 00:01:22-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/autoopts.c + ntpdc/ntpdc-opts.c@1.236, 2009-11-17 07:33:51-05:00, stenn@whimsy.udel.edu +24 -17 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-autoopts.c~917f3eb3a2030087@1.2, 2007-05-19 00:00:06-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/autoopts.c + ntpdc/ntpdc-opts.h@1.236, 2009-11-17 07:33:51-05:00, stenn@whimsy.udel.edu +6 -5 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-autoopts.h~4184ad33bbb8222@1.2, 2007-05-19 00:00:08-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/autoopts.h + ntpdc/ntpdc-opts.texi@1.235, 2009-11-17 07:33:51-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-autoopts.h~d0834f397c8a330d@1.2, 2007-05-19 00:01:24-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/autoopts.h + ntpdc/ntpdc.1@1.235, 2009-11-17 07:33:52-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-boolean.c~50ae286fc516eee2@1.2, 2007-05-19 00:01:25-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/boolean.c + ntpq/ntpq-opts.c@1.237, 2009-11-17 07:33:52-05:00, stenn@whimsy.udel.edu +24 -17 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-boolean.c~afd23e01a43b9536@1.2, 2007-05-19 00:00:09-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/boolean.c + ntpq/ntpq-opts.h@1.237, 2009-11-17 07:33:52-05:00, stenn@whimsy.udel.edu +5 -5 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-compat.h~2bcdd381f6a570a1@1.2, 2007-05-19 00:01:54-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/compat.h + ntpq/ntpq-opts.texi@1.236, 2009-11-17 07:33:52-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-compat.h~e5d9fc11f0b928f2@1.2, 2007-05-19 00:00:35-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/compat.h + ntpq/ntpq.1@1.236, 2009-11-17 07:33:53-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-configfile.c~53384c73e434a615@1.2, 2007-05-19 00:00:09-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/configfile.c + ntpsnmpd/ntpsnmpd-opts.c@1.115, 2009-11-17 07:33:53-05:00, stenn@whimsy.udel.edu +24 -17 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-configfile.c~ee0b7d49d26b4f74@1.2, 2007-05-19 00:01:26-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/configfile.c + ntpsnmpd/ntpsnmpd-opts.h@1.115, 2009-11-17 07:33:53-05:00, stenn@whimsy.udel.edu +5 -5 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-cook.c~760181d2119b672@1.2, 2007-05-19 00:01:27-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/cook.c + ntpsnmpd/ntpsnmpd-opts.texi@1.115, 2009-11-17 07:33:53-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-cook.c~84c1af00a5581292@1.2, 2007-05-19 00:00:11-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/cook.c + ntpsnmpd/ntpsnmpd.1@1.115, 2009-11-17 07:33:54-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-enumeration.c~551805256cb9068c@1.2, 2007-05-19 00:00:12-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/enumeration.c + packageinfo.sh@1.250, 2009-11-17 07:33:54-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-enumeration.c~969462e75e3913a3@1.2, 2007-05-19 00:01:29-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/enumeration.c + sntp/sntp-opts.c@1.109, 2009-11-17 07:33:54-05:00, stenn@whimsy.udel.edu +24 -17 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-environment.c~643ce1e5a16a4f94@1.2, 2007-05-19 00:01:30-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/environment.c + sntp/sntp-opts.h@1.109, 2009-11-17 07:33:54-05:00, stenn@whimsy.udel.edu +8 -5 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-environment.c~965d8c0fdf1150f5@1.2, 2007-05-19 00:00:13-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/environment.c + sntp/sntp-opts.texi@1.109, 2009-11-17 07:33:55-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-genshell.c~20529138c60103c3@1.2, 2007-05-19 00:00:14-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/genshell.c + sntp/sntp.1@1.109, 2009-11-17 07:33:55-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-genshell.c~bd74153097ec640f@1.2, 2007-05-19 00:01:31-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/genshell.c + util/ntp-keygen-opts.c@1.239, 2009-11-17 07:33:55-05:00, stenn@whimsy.udel.edu +39 -47 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-genshell.h~7f41539b135f914a@1.2, 2007-05-19 00:00:15-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/genshell.h + util/ntp-keygen-opts.h@1.239, 2009-11-17 07:33:55-05:00, stenn@whimsy.udel.edu +11 -32 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-genshell.h~b2793e1ea2981ff5@1.2, 2007-05-19 00:01:32-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/genshell.h + util/ntp-keygen-opts.texi@1.238, 2009-11-17 07:33:56-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-libopts.c~9353e1c3a0c56ad@1.2, 2007-05-19 00:00:16-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/libopts.c + util/ntp-keygen.1@1.238, 2009-11-17 07:33:56-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P246_RC - BitKeeper/deleted/.del-libopts.c~bfc74bb368a309be@1.2, 2007-05-19 00:01:33-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/libopts.c +ChangeSet@1.2060.1.46, 2009-11-17 06:53:35-05:00, stenn@whimsy.udel.edu +12 -0 + autogen upgrade cleanup - BitKeeper/deleted/.del-libopts.m4~9851dd84df41023b@1.2, 2007-05-19 00:00:40-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/m4/libopts.m4 + clockstuff/clktest-opts.c@1.12, 2009-11-17 06:50:27-05:00, stenn@whimsy.udel.edu +130 -361 + autogen upgrade cleanup - BitKeeper/deleted/.del-libopts.m4~9fa7e371d1cc0426@1.2, 2007-05-19 00:02:00-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/m4/libopts.m4 + clockstuff/clktest-opts.h@1.12, 2009-11-17 06:50:27-05:00, stenn@whimsy.udel.edu +90 -100 + autogen upgrade cleanup - BitKeeper/deleted/.del-liboptschk.m4~1828e1c4576e5aea@1.2, 2007-05-19 00:00:41-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/m4/liboptschk.m4 + libopts/autoopts/options.h@1.5, 2009-11-17 06:53:18-05:00, stenn@whimsy.udel.edu +7 -5 + autogen upgrade cleanup - BitKeeper/deleted/.del-liboptschk.m4~480d5c4f1634a9fa@1.2, 2007-05-19 00:02:01-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/m4/liboptschk.m4 + libopts/autoopts/usage-txt.h@1.5, 2009-11-17 06:53:19-05:00, stenn@whimsy.udel.edu +161 -152 + autogen upgrade cleanup - BitKeeper/deleted/.del-load.c~688d4934eb14272@1.2, 2007-05-19 00:01:34-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/load.c + libopts/genshell.c@1.5, 2009-11-17 06:53:18-05:00, stenn@whimsy.udel.edu +22 -15 + autogen upgrade cleanup - BitKeeper/deleted/.del-load.c~b6aa568c6e3eaca1@1.2, 2007-05-19 00:00:16-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/load.c + libopts/genshell.h@1.5, 2009-11-17 06:53:18-05:00, stenn@whimsy.udel.edu +2 -2 + autogen upgrade cleanup - BitKeeper/deleted/.del-makeshell.c~8c63bc5a263da752@1.2, 2007-05-19 00:01:35-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/makeshell.c + ntpd/ntpdsim-opts.c@1.17, 2009-11-17 06:50:27-05:00, stenn@whimsy.udel.edu +237 -319 + autogen upgrade cleanup - BitKeeper/deleted/.del-makeshell.c~a9cd96c3bfbc0835@1.2, 2007-05-19 00:00:17-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/makeshell.c + ntpd/ntpdsim-opts.h@1.17, 2009-11-17 06:50:27-05:00, stenn@whimsy.udel.edu +112 -139 + autogen upgrade cleanup - BitKeeper/deleted/.del-nested.c~1670193227f54043@1.2, 2007-05-19 00:01:36-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/nested.c + sntp/libopts/autoopts/options.h@1.6, 2009-11-17 06:53:19-05:00, stenn@whimsy.udel.edu +7 -5 + autogen upgrade cleanup - BitKeeper/deleted/.del-nested.c~a8521c8fcff292b6@1.2, 2007-05-19 00:00:18-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/nested.c + sntp/libopts/autoopts/usage-txt.h@1.6, 2009-11-17 06:53:20-05:00, stenn@whimsy.udel.edu +161 -152 + autogen upgrade cleanup - BitKeeper/deleted/.del-numeric.c~eb3fbec29633e61@1.2, 2007-05-19 00:01:37-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/numeric.c + sntp/libopts/genshell.c@1.6, 2009-11-17 06:53:19-05:00, stenn@whimsy.udel.edu +22 -15 + autogen upgrade cleanup - BitKeeper/deleted/.del-numeric.c~ec644fa246942cbc@1.2, 2007-05-19 00:00:19-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/numeric.c + sntp/libopts/genshell.h@1.6, 2009-11-17 06:53:19-05:00, stenn@whimsy.udel.edu +2 -2 + autogen upgrade cleanup - BitKeeper/deleted/.del-options.h~3cb6af32ad01957@1.2, 2007-05-19 00:01:52-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/autoopts/options.h +ChangeSet@1.2060.1.45, 2009-11-17 06:44:44-05:00, stenn@whimsy.udel.edu +69 -0 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-options.h~f700d69ce23e3e23@1.2, 2007-05-19 00:00:33-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/autoopts/options.h + ChangeLog@1.546, 2009-11-17 06:43:05-05:00, stenn@whimsy.udel.edu +1 -0 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-pathfind.c~953a96dbc9932@1.2, 2007-05-19 00:01:56-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/pathfind.c + libopts/Makefile.am@1.2, 2009-11-17 06:43:05-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-pathfind.c~c132dab083075929@1.2, 2007-05-19 00:00:36-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/pathfind.c + libopts/ag-char-map.h@1.5, 2009-11-17 06:43:05-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-pgusage.c~5c1f8f132e9a1546@1.2, 2007-05-19 00:01:39-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/pgusage.c + libopts/autoopts.c@1.4, 2009-11-17 06:43:06-05:00, stenn@whimsy.udel.edu +43 -26 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-pgusage.c~cec1309617012832@1.2, 2007-05-19 00:00:20-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/pgusage.c + libopts/autoopts.h@1.4, 2009-11-17 06:43:06-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-proto.h~697b4937ff37ca3f@1.2, 2007-05-19 00:01:40-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/proto.h + libopts/boolean.c@1.4, 2009-11-17 06:43:06-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-proto.h~e2a13f546fbc0d4f@1.2, 2007-05-19 00:00:21-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/proto.h + libopts/compat/compat.h@1.4, 2009-11-17 06:43:11-05:00, stenn@whimsy.udel.edu +48 -25 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-putshell.c~6845ea506fad6426@1.2, 2007-05-19 00:01:41-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/putshell.c + libopts/compat/pathfind.c@1.4, 2009-11-17 06:43:11-05:00, stenn@whimsy.udel.edu +1 -2 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-putshell.c~6e39e6836261f3f7@1.2, 2007-05-19 00:00:22-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/putshell.c + libopts/compat/windows-config.h@1.4, 2009-11-17 06:43:11-05:00, stenn@whimsy.udel.edu +0 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-restore.c~c14d8b96be44c6a8@1.2, 2007-05-19 00:01:42-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/restore.c + libopts/configfile.c@1.4, 2009-11-17 06:43:06-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-restore.c~e2a155efceab6f0d@1.2, 2007-05-19 00:00:23-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/restore.c + libopts/cook.c@1.4, 2009-11-17 06:43:06-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-save.c~17e5ac125a404fb0@1.2, 2007-05-19 00:00:24-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/save.c + libopts/enumeration.c@1.4, 2009-11-17 06:43:07-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-save.c~e7e7366cd24e1a8f@1.2, 2007-05-19 00:01:43-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/save.c + libopts/environment.c@1.5, 2009-11-17 06:43:07-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-snprintf.c~4b42e45647e9ccef@1.2, 2007-05-19 00:00:38-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/snprintf.c + libopts/file.c@1.4, 2009-11-17 06:43:07-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-snprintf.c~988df6799c67781f@1.2, 2007-05-19 00:01:57-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/snprintf.c + libopts/load.c@1.4, 2009-11-17 06:43:07-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-sort.c~586535d7d26d958@1.2, 2007-05-19 00:01:44-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/sort.c + libopts/m4/libopts.m4@1.5, 2009-11-17 06:43:11-05:00, stenn@whimsy.udel.edu +2 -8 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-sort.c~bb92da923b5dcb7@1.2, 2007-05-19 00:00:25-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/sort.c + libopts/m4/liboptschk.m4@1.4, 2009-11-17 06:43:12-05:00, stenn@whimsy.udel.edu +0 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-stack.c~202d33ccdfd74ec@1.2, 2007-05-19 00:01:45-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/stack.c + libopts/makeshell.c@1.4, 2009-11-17 06:43:07-05:00, stenn@whimsy.udel.edu +41 -41 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-stack.c~b60d0ab82970f41f@1.2, 2007-05-19 00:00:26-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/stack.c + libopts/nested.c@1.4, 2009-11-17 06:43:08-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-strchr.c~4a7e412c18f53557@1.2, 2007-05-19 00:01:57-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/strchr.c + libopts/numeric.c@1.4, 2009-11-17 06:43:08-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-strchr.c~7f4589858587fcc4@1.2, 2007-05-19 00:00:38-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/strchr.c + libopts/pgusage.c@1.4, 2009-11-17 06:43:08-05:00, stenn@whimsy.udel.edu +5 -4 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-strdup.c~75e27662f28944b1@1.2, 2007-05-19 00:01:58-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/strdup.c + libopts/proto.h@1.5, 2009-11-17 06:43:08-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-strdup.c~b295027011406c46@1.2, 2007-05-19 00:00:39-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/strdup.c + libopts/putshell.c@1.4, 2009-11-17 06:43:08-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-streqvcmp.c~999e9cfa251ea4b3@1.2, 2007-05-19 00:00:28-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/streqvcmp.c + libopts/reset.c@1.4, 2009-11-17 06:43:09-05:00, stenn@whimsy.udel.edu +8 -2 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-streqvcmp.c~dc5534ffb1c6f28@1.2, 2007-05-19 00:01:47-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/streqvcmp.c + libopts/restore.c@1.4, 2009-11-17 06:43:09-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-text_mmap.c~52f2f1dbe57a9743@1.2, 2007-05-19 00:00:29-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/text_mmap.c + libopts/save.c@1.5, 2009-11-17 06:43:09-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-text_mmap.c~e5096667484e499a@1.2, 2007-05-19 00:01:48-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/text_mmap.c + libopts/sort.c@1.4, 2009-11-17 06:43:09-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-tokenize.c~315c26f9b162f234@1.2, 2007-05-19 00:01:49-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/tokenize.c + libopts/stack.c@1.4, 2009-11-17 06:43:09-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-tokenize.c~6a814216fa293c3c@1.2, 2007-05-19 00:00:30-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/tokenize.c + libopts/streqvcmp.c@1.4, 2009-11-17 06:43:09-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-usage-txt.h~3737a7c76813e8c3@1.2, 2007-05-19 00:00:34-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/autoopts/usage-txt.h + libopts/text_mmap.c@1.4, 2009-11-17 06:43:10-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-usage-txt.h~b71acc916d68c58c@1.2, 2007-05-19 00:01:53-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/autoopts/usage-txt.h + libopts/time.c@1.4, 2009-11-17 06:43:10-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-usage.c~f21924faa210bfa9@1.2, 2007-05-19 00:01:50-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/usage.c + libopts/usage.c@1.4, 2009-11-17 06:43:10-05:00, stenn@whimsy.udel.edu +53 -18 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-usage.c~fe9a0f55b3cc55e4@1.2, 2007-05-19 00:00:31-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/usage.c + libopts/value-type.h@1.5, 2009-11-17 06:43:10-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-version.c~b69eccbdea7f51d9@1.2, 2007-05-19 00:01:51-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/version.c + libopts/version.c@1.4, 2009-11-17 06:43:10-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-version.c~de7f014d3e2ac91e@1.2, 2007-05-19 00:00:32-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/version.c + libopts/xat-attribute.h@1.5, 2009-11-17 06:43:11-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-windows-config.h~11a9a57b2895598f@1.2, 2007-05-19 00:01:59-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/windows-config.h + sntp/libopts/Makefile.am@1.3, 2009-11-17 06:43:12-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - BitKeeper/deleted/.del-windows-config.h~a6ead462c3d18ff0@1.2, 2007-05-19 00:00:39-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/windows-config.h + sntp/libopts/ag-char-map.h@1.6, 2009-11-17 06:43:12-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - clockstuff/clktest-opts.c@1.10, 2007-05-19 02:30:32-04:00, stenn@whimsy.udel.edu +38 -270 - We need to use the upgraded autogen/libopts in -stable too. + sntp/libopts/autoopts.c@1.5, 2009-11-17 06:43:12-05:00, stenn@whimsy.udel.edu +43 -26 + Upgrade to autogen 5.10 - clockstuff/clktest-opts.def@1.6, 2007-05-19 02:27:39-04:00, stenn@whimsy.udel.edu +4 -0 - We need to use the upgraded autogen/libopts in -stable too. + sntp/libopts/autoopts.h@1.5, 2009-11-17 06:43:12-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - clockstuff/clktest-opts.h@1.10, 2007-05-19 02:30:33-04:00, stenn@whimsy.udel.edu +22 -57 - We need to use the upgraded autogen/libopts in -stable too. + sntp/libopts/boolean.c@1.5, 2009-11-17 06:43:13-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - include/autogen-version.def@1.4, 2007-05-19 02:27:41-04:00, stenn@whimsy.udel.edu +1 -1 - We need to use the upgraded autogen/libopts in -stable too. + sntp/libopts/compat/compat.h@1.5, 2009-11-17 06:43:17-05:00, stenn@whimsy.udel.edu +48 -25 + Upgrade to autogen 5.10 - libopts/COPYING.lgpl@1.1, 2007-05-19 00:04:01-04:00, stenn@whimsy.udel.edu +502 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/COPYING.lgpl + sntp/libopts/compat/pathfind.c@1.5, 2009-11-17 06:43:18-05:00, stenn@whimsy.udel.edu +1 -2 + Upgrade to autogen 5.10 - libopts/COPYING.lgpl@1.0, 2007-05-19 00:04:01-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/libopts/compat/windows-config.h@1.5, 2009-11-17 06:43:18-05:00, stenn@whimsy.udel.edu +0 -1 + Upgrade to autogen 5.10 - libopts/COPYING.mbsd@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +26 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/COPYING.mbsd + sntp/libopts/configfile.c@1.5, 2009-11-17 06:43:13-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - libopts/COPYING.mbsd@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/libopts/cook.c@1.5, 2009-11-17 06:43:13-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - libopts/MakeDefs.inc@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/MakeDefs.inc + sntp/libopts/enumeration.c@1.5, 2009-11-17 06:43:13-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - libopts/MakeDefs.inc@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/libopts/environment.c@1.6, 2009-11-17 06:43:13-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - libopts/Makefile.am@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +24 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/Makefile.am + sntp/libopts/file.c@1.5, 2009-11-17 06:43:14-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - libopts/Makefile.am@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/libopts/load.c@1.5, 2009-11-17 06:43:14-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - libopts/README@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +93 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/README + sntp/libopts/m4/libopts.m4@1.6, 2009-11-17 06:43:18-05:00, stenn@whimsy.udel.edu +2 -8 + Upgrade to autogen 5.10 - libopts/README@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/libopts/m4/liboptschk.m4@1.5, 2009-11-17 06:43:18-05:00, stenn@whimsy.udel.edu +0 -1 + Upgrade to autogen 5.10 - libopts/autoopts.c@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +1120 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts.c + sntp/libopts/makeshell.c@1.5, 2009-11-17 06:43:14-05:00, stenn@whimsy.udel.edu +41 -41 + Upgrade to autogen 5.10 - libopts/autoopts.c@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/libopts/nested.c@1.5, 2009-11-17 06:43:14-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - libopts/autoopts.h@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +387 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts.h + sntp/libopts/numeric.c@1.5, 2009-11-17 06:43:14-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - libopts/autoopts.h@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/libopts/pgusage.c@1.5, 2009-11-17 06:43:15-05:00, stenn@whimsy.udel.edu +5 -4 + Upgrade to autogen 5.10 - libopts/autoopts/options.h@1.1, 2007-05-19 00:04:14-04:00, stenn@whimsy.udel.edu +977 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts/options.h + sntp/libopts/proto.h@1.6, 2009-11-17 06:43:15-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - libopts/autoopts/options.h@1.0, 2007-05-19 00:04:14-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/libopts/putshell.c@1.5, 2009-11-17 06:43:15-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - libopts/autoopts/usage-txt.h@1.1, 2007-05-19 00:04:14-04:00, stenn@whimsy.udel.edu +355 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts/usage-txt.h + sntp/libopts/reset.c@1.5, 2009-11-17 06:43:15-05:00, stenn@whimsy.udel.edu +8 -2 + Upgrade to autogen 5.10 - libopts/autoopts/usage-txt.h@1.0, 2007-05-19 00:04:14-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/libopts/restore.c@1.5, 2009-11-17 06:43:15-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - libopts/boolean.c@1.1, 2007-05-19 00:04:03-04:00, stenn@whimsy.udel.edu +106 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/boolean.c + sntp/libopts/save.c@1.6, 2009-11-17 06:43:15-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - libopts/boolean.c@1.0, 2007-05-19 00:04:03-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/libopts/sort.c@1.5, 2009-11-17 06:43:16-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - libopts/compat/compat.h@1.1, 2007-05-19 00:04:15-04:00, stenn@whimsy.udel.edu +319 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/compat.h + sntp/libopts/stack.c@1.5, 2009-11-17 06:43:16-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - libopts/compat/compat.h@1.0, 2007-05-19 00:04:15-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/libopts/streqvcmp.c@1.5, 2009-11-17 06:43:16-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - libopts/compat/pathfind.c@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +339 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/pathfind.c + sntp/libopts/text_mmap.c@1.5, 2009-11-17 06:43:16-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - libopts/compat/pathfind.c@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/libopts/time.c@1.5, 2009-11-17 06:43:16-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - libopts/compat/snprintf.c@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +60 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/snprintf.c + sntp/libopts/usage.c@1.5, 2009-11-17 06:43:17-05:00, stenn@whimsy.udel.edu +53 -18 + Upgrade to autogen 5.10 - libopts/compat/snprintf.c@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/libopts/value-type.h@1.6, 2009-11-17 06:43:17-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - libopts/compat/strchr.c@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +60 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/strchr.c + sntp/libopts/version.c@1.5, 2009-11-17 06:43:17-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - libopts/compat/strchr.c@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/libopts/xat-attribute.h@1.6, 2009-11-17 06:43:17-05:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen 5.10 - libopts/compat/strdup.c@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +19 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/strdup.c +ChangeSet@1.2060.1.44, 2009-11-17 07:27:53+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1384] ntpq :config core dumped with a blank password. - libopts/compat/strdup.c@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 + ChangeLog@1.545, 2009-11-17 07:27:51+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1384] ntpq :config core dumped with a blank password. - libopts/compat/windows-config.h@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +130 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/windows-config.h + ntpq/ntpq-subs.c@1.41, 2009-11-17 07:27:51+00:00, davehart@shiny.ad.hartbrothers.com +60 -41 + [Bug 1384] ntpq :config core dumped with a blank password. - libopts/compat/windows-config.h@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.2060.21.1, 2009-11-17 04:25:42+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + use (peer->pmode == MODE_BROADCAST) rather than + (peer->castflags & MDF_BCLNT) to detect ephemeral broadcastclient + associations to exempt from peer_clear("XFAC") - libopts/configfile.c@1.1, 2007-05-19 00:04:03-04:00, stenn@whimsy.udel.edu +1290 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/configfile.c + ChangeLog@1.542.1.1, 2009-11-17 04:25:41+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1378] Unnecessary resetting of peers during interface update. - libopts/configfile.c@1.0, 2007-05-19 00:04:03-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntp_peer.c@1.125, 2009-11-17 04:25:42+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + use (peer->pmode == MODE_BROADCAST) rather than + (peer->castflags & MDF_BCLNT) to detect broadcastclient + associations to exempt from peer_clear("XFAC"), suggested + by Frank Kardel. - libopts/cook.c@1.1, 2007-05-19 00:04:04-04:00, stenn@whimsy.udel.edu +354 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/cook.c +ChangeSet@1.2060.1.42, 2009-11-16 05:41:46+00:00, davehart@shiny.ad.hartbrothers.com +15 -0 + [Bug 1382] p245 configure --disable-dependency-tracking won't build - libopts/cook.c@1.0, 2007-05-19 00:04:04-04:00, stenn@whimsy.udel.edu +0 -0 + ChangeLog@1.543, 2009-11-16 05:41:44+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1382] p245 configure --disable-dependency-tracking won't build - libopts/enumeration.c@1.1, 2007-05-19 00:04:05-04:00, stenn@whimsy.udel.edu +498 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/enumeration.c + Makefile.am@1.86.1.3, 2009-11-16 05:41:44+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + depsver.mf requires CLEANFILES be set even if empty - libopts/enumeration.c@1.0, 2007-05-19 00:04:05-04:00, stenn@whimsy.udel.edu +0 -0 + adjtimed/Makefile.am@1.6, 2009-11-16 05:41:44+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + depsver.mf requires CLEANFILES be set even if empty - libopts/environment.c@1.1, 2007-05-19 00:04:05-04:00, stenn@whimsy.udel.edu +279 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/environment.c + clockstuff/Makefile.am@1.9, 2009-11-16 05:41:44+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + depsver.mf requires CLEANFILES be set even if empty - libopts/environment.c@1.0, 2007-05-19 00:04:05-04:00, stenn@whimsy.udel.edu +0 -0 + depsver.mf@1.2, 2009-11-16 05:41:44+00:00, davehart@shiny.ad.hartbrothers.com +31 -7 + tolerate --disable-dependency-tracking + use a more targeted ./config.status run - libopts/genshell.c@1.1, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +354 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/genshell.c + include/ntpd.h@1.137, 2009-11-16 05:41:44+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + silence "assignment discards qualifier" warning by using const char * - libopts/genshell.c@1.0, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +0 -0 + libntp/Makefile.am@1.51, 2009-11-16 05:41:44+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + depsver.mf requires CLEANFILES be set even if empty - libopts/genshell.h@1.1, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +149 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/genshell.h + ntpd/cmd_args.c@1.55, 2009-11-16 05:41:44+00:00, davehart@shiny.ad.hartbrothers.com +1 -4 + silence assignment discards qualifiers warning by eliminating assignment - libopts/genshell.h@1.0, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd.c@1.110, 2009-11-16 05:41:45+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + silence "assignment discards qualifier" warning by using const char * - libopts/libopts.c@1.1, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +30 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/libopts.c + ntpdate/Makefile.am@1.22, 2009-11-16 05:41:45+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + depsver.mf requires CLEANFILES be set even if empty - libopts/libopts.c@1.0, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/Makefile.am@1.40, 2009-11-16 05:41:45+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + depsver.mf requires CLEANFILES be set even if empty - libopts/load.c@1.1, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +563 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/load.c + ntpsnmpd/Makefile.am@1.13, 2009-11-16 05:41:45+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + depsver.mf requires CLEANFILES be set even if empty - libopts/load.c@1.0, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +0 -0 + parseutil/Makefile.am@1.12, 2009-11-16 05:41:45+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + depsver.mf requires CLEANFILES be set even if empty - libopts/m4/libopts.m4@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +509 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/m4/libopts.m4 + sntp/Makefile.am@1.13.1.5, 2009-11-16 05:41:45+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + depsver.mf requires CLEANFILES be set even if empty - libopts/m4/libopts.m4@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 + util/Makefile.am@1.43, 2009-11-16 05:41:45+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + depsver.mf requires CLEANFILES be set even if empty - libopts/m4/liboptschk.m4@1.1, 2007-05-19 00:04:17-04:00, stenn@whimsy.udel.edu +42 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/m4/liboptschk.m4 +ChangeSet@1.2060.1.41, 2009-11-14 08:29:21-05:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P245_RC + TAG: NTP_4_2_5P245_RC - libopts/m4/liboptschk.m4@1.0, 2007-05-19 00:04:17-04:00, stenn@whimsy.udel.edu +0 -0 + ChangeLog@1.542, 2009-11-14 08:28:48-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P245_RC - libopts/makeshell.c@1.1, 2007-05-19 00:04:07-04:00, stenn@whimsy.udel.edu +1122 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/makeshell.c + ntpd/ntpd-opts.c@1.239, 2009-11-14 08:28:50-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P245_RC - libopts/makeshell.c@1.0, 2007-05-19 00:04:07-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.h@1.239, 2009-11-14 08:28:51-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P245_RC - libopts/nested.c@1.1, 2007-05-19 00:04:07-04:00, stenn@whimsy.udel.edu +733 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/nested.c + ntpd/ntpd-opts.texi@1.237, 2009-11-14 08:28:52-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P245_RC - libopts/nested.c@1.0, 2007-05-19 00:04:07-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd.1@1.237, 2009-11-14 08:28:54-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P245_RC - libopts/numeric.c@1.1, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +93 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/numeric.c + ntpdc/ntpdc-opts.c@1.235, 2009-11-14 08:28:55-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P245_RC - libopts/numeric.c@1.0, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.h@1.235, 2009-11-14 08:28:56-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P245_RC - libopts/pgusage.c@1.1, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +157 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/pgusage.c + ntpdc/ntpdc-opts.texi@1.234, 2009-11-14 08:28:57-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P245_RC - libopts/pgusage.c@1.0, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc.1@1.234, 2009-11-14 08:28:57-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P245_RC - libopts/proto.h@1.1, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +91 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/proto.h + ntpq/ntpq-opts.c@1.236, 2009-11-14 08:28:59-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P245_RC - libopts/proto.h@1.0, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.h@1.236, 2009-11-14 08:29:00-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P245_RC - libopts/putshell.c@1.1, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +335 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/putshell.c + ntpq/ntpq-opts.texi@1.235, 2009-11-14 08:29:01-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P245_RC - libopts/putshell.c@1.0, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq.1@1.235, 2009-11-14 08:29:01-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P245_RC - libopts/restore.c@1.1, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +250 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/restore.c + ntpsnmpd/ntpsnmpd-opts.c@1.114, 2009-11-14 08:29:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P245_RC - libopts/restore.c@1.0, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +0 -0 + ntpsnmpd/ntpsnmpd-opts.h@1.114, 2009-11-14 08:29:03-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P245_RC - libopts/save.c@1.1, 2007-05-19 00:04:09-04:00, stenn@whimsy.udel.edu +512 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/save.c + ntpsnmpd/ntpsnmpd-opts.texi@1.114, 2009-11-14 08:29:03-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P245_RC - libopts/save.c@1.0, 2007-05-19 00:04:09-04:00, stenn@whimsy.udel.edu +0 -0 + ntpsnmpd/ntpsnmpd.1@1.114, 2009-11-14 08:29:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P245_RC - libopts/sort.c@1.1, 2007-05-19 00:04:09-04:00, stenn@whimsy.udel.edu +359 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/sort.c + packageinfo.sh@1.249, 2009-11-14 08:29:05-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P245_RC - libopts/sort.c@1.0, 2007-05-19 00:04:09-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.c@1.108, 2009-11-14 08:29:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P245_RC - libopts/stack.c@1.1, 2007-05-19 00:04:10-04:00, stenn@whimsy.udel.edu +269 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/stack.c + sntp/sntp-opts.h@1.108, 2009-11-14 08:29:07-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P245_RC - libopts/stack.c@1.0, 2007-05-19 00:04:10-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.texi@1.108, 2009-11-14 08:29:08-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P245_RC - libopts/streqvcmp.c@1.1, 2007-05-19 00:04:11-04:00, stenn@whimsy.udel.edu +289 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/streqvcmp.c + sntp/sntp.1@1.108, 2009-11-14 08:29:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P245_RC - libopts/streqvcmp.c@1.0, 2007-05-19 00:04:11-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.c@1.238, 2009-11-14 08:29:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P245_RC - libopts/text_mmap.c@1.1, 2007-05-19 00:04:11-04:00, stenn@whimsy.udel.edu +363 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/text_mmap.c + util/ntp-keygen-opts.h@1.238, 2009-11-14 08:29:10-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P245_RC - libopts/text_mmap.c@1.0, 2007-05-19 00:04:11-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.texi@1.237, 2009-11-14 08:29:11-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P245_RC - libopts/tokenize.c@1.1, 2007-05-19 00:04:12-04:00, stenn@whimsy.udel.edu +321 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/tokenize.c + util/ntp-keygen.1@1.237, 2009-11-14 08:29:12-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P245_RC - libopts/tokenize.c@1.0, 2007-05-19 00:04:12-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.2060.1.40, 2009-11-14 07:23:50-05:00, stenn@whimsy.udel.edu +7 -0 + Changes from Dave Mills - libopts/usage.c@1.1, 2007-05-19 00:04:13-04:00, stenn@whimsy.udel.edu +740 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/usage.c + ChangeLog@1.541, 2009-11-14 07:23:33-05:00, stenn@whimsy.udel.edu +1 -0 + Changes from Dave Mills - libopts/usage.c@1.0, 2007-05-19 00:04:13-04:00, stenn@whimsy.udel.edu +0 -0 + html/authopt.html@1.59, 2009-11-14 06:00:16-05:00, stenn@whimsy.udel.edu +6 -5 + Cleanup from Dave Mills - libopts/version.c@1.1, 2007-05-19 00:04:13-04:00, stenn@whimsy.udel.edu +178 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/version.c + html/keygen.html@1.19, 2009-11-14 06:00:21-05:00, stenn@whimsy.udel.edu +6 -6 + Cleanup from Dave Mills - libopts/version.c@1.0, 2007-05-19 00:04:13-04:00, stenn@whimsy.udel.edu +0 -0 + html/miscopt.html@1.53, 2009-11-14 06:00:22-05:00, stenn@whimsy.udel.edu +9 -3 + Cleanup from Dave Mills - ntpd/ntpd-opts.c@1.60, 2007-05-19 02:30:34-04:00, stenn@whimsy.udel.edu +20 -11 - We need to use the upgraded autogen/libopts in -stable too. + libntp/authreadkeys.c@1.16, 2009-11-14 05:47:21-05:00, stenn@whimsy.udel.edu +1 -1 + Cleanup from Dave Mills - ntpd/ntpd-opts.h@1.60, 2007-05-19 02:30:36-04:00, stenn@whimsy.udel.edu +4 -4 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/ntp_loopfilter.c@1.153, 2009-11-14 05:46:47-05:00, stenn@whimsy.udel.edu +1 -1 + Cleanup from Dave Mills - ntpd/ntpd-opts.texi@1.59, 2007-05-19 02:30:36-04:00, stenn@whimsy.udel.edu +2 -8 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/refclock_local.c@1.20, 2009-11-14 05:46:57-05:00, stenn@whimsy.udel.edu +0 -9 + Cleanup from Dave Mills - ntpd/ntpd.1@1.58, 2007-05-19 02:30:37-04:00, stenn@whimsy.udel.edu +2 -2 - We need to use the upgraded autogen/libopts in -stable too. +ChangeSet@1.2060.20.1, 2009-11-14 02:20:06+00:00, davehart@shiny.ad.hartbrothers.com +22 -0 + [Bug 1381] Version .deps generated include file dependencies to allow + known dependecy-breaking changes to force .deps to be cleaned, + triggered by changing the contents of deps-ver and/or sntp/deps-ver. - ntpd/ntpdsim-opts.c@1.60, 2007-05-19 02:30:40-04:00, stenn@whimsy.udel.edu +23 -14 - We need to use the upgraded autogen/libopts in -stable too. + ChangeLog@1.538.1.1, 2009-11-14 02:20:03+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1381] Version .deps generated include file dependencies to allow + known dependecy-breaking changes to force .deps to be cleaned, + triggered by changing the contents of deps-ver and/or sntp/deps-ver. - ntpd/ntpdsim-opts.h@1.60, 2007-05-19 02:30:41-04:00, stenn@whimsy.udel.edu +6 -6 - We need to use the upgraded autogen/libopts in -stable too. + Makefile.am@1.86.1.2, 2009-11-14 02:20:03+00:00, davehart@shiny.ad.hartbrothers.com +39 -39 + whitespace cleanup + no longer hunt down and remove CVS directories in distclean, + as we don't have them. - ntpd/ntpdsim-opts.texi@1.58, 2007-05-19 02:30:43-04:00, stenn@whimsy.udel.edu +1 -1 - We need to use the upgraded autogen/libopts in -stable too. + adjtimed/Makefile.am@1.5, 2009-11-14 02:20:04+00:00, davehart@shiny.ad.hartbrothers.com +3 -1 + include depsver.mf - ntpd/ntpdsim.1@1.58, 2007-05-19 02:30:44-04:00, stenn@whimsy.udel.edu +2 -2 - We need to use the upgraded autogen/libopts in -stable too. + arlib/configure.in@1.3, 2009-11-14 02:20:04+00:00, davehart@shiny.ad.hartbrothers.com +6 -3 + bring res_init check in line with main configure.ac to fix + arlib build break - ntpdc/ntpdc-opts.c@1.60, 2007-05-19 02:30:45-04:00, stenn@whimsy.udel.edu +23 -14 - We need to use the upgraded autogen/libopts in -stable too. + bootstrap@1.28, 2009-11-14 02:20:03+00:00, davehart@shiny.ad.hartbrothers.com +1 -17 + remove disabled first whack at this issue - ntpdc/ntpdc-opts.h@1.60, 2007-05-19 02:30:48-04:00, stenn@whimsy.udel.edu +6 -6 - We need to use the upgraded autogen/libopts in -stable too. + clockstuff/Makefile.am@1.8, 2009-11-14 02:20:04+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + include depsver.mf - ntpdc/ntpdc-opts.texi@1.58, 2007-05-19 02:30:48-04:00, stenn@whimsy.udel.edu +3 -3 - We need to use the upgraded autogen/libopts in -stable too. + configure.ac@1.459.3.1, 2009-11-14 02:20:03+00:00, davehart@shiny.ad.hartbrothers.com +0 -3 + remove duplicate AC_SEARCH_LIBS for setsockopt - ntpdc/ntpdc.1@1.58, 2007-05-19 02:30:49-04:00, stenn@whimsy.udel.edu +2 -2 - We need to use the upgraded autogen/libopts in -stable too. + deps-ver@1.1, 2009-11-14 02:17:30+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + a change to the contents of this file cleans any existing .deps - ntpq/ntpq-opts.c@1.62, 2007-05-19 02:30:50-04:00, stenn@whimsy.udel.edu +23 -14 - We need to use the upgraded autogen/libopts in -stable too. + deps-ver@1.0, 2009-11-14 02:17:30+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 - ntpq/ntpq-opts.h@1.62, 2007-05-19 02:30:51-04:00, stenn@whimsy.udel.edu +6 -6 - We need to use the upgraded autogen/libopts in -stable too. + depsver.mf@1.1, 2009-11-14 02:17:28+00:00, davehart@shiny.ad.hartbrothers.com +43 -0 + .am include to implement .deps include file dependency versioning - ntpq/ntpq-opts.texi@1.59, 2007-05-19 02:30:52-04:00, stenn@whimsy.udel.edu +3 -3 - We need to use the upgraded autogen/libopts in -stable too. + depsver.mf@1.0, 2009-11-14 02:17:28+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 - ntpq/ntpq.1@1.58, 2007-05-19 02:30:53-04:00, stenn@whimsy.udel.edu +2 -2 - We need to use the upgraded autogen/libopts in -stable too. + libntp/Makefile.am@1.50, 2009-11-14 02:20:04+00:00, davehart@shiny.ad.hartbrothers.com +2 -3 + include depsver.mf + remove ../include/des.h rule, no longer used - packageinfo.sh@1.80, 2007-05-19 02:28:15-04:00, stenn@whimsy.udel.edu +1 -1 - We need another RC release to be sure the new autogen/libopts works. + libparse/Makefile.am@1.16, 2009-11-14 02:20:04+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + include depsver.mf - sntp/libopts/COPYING.lgpl@1.1, 2007-05-19 00:04:59-04:00, stenn@whimsy.udel.edu +502 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/COPYING.lgpl + ntpd/Makefile.am@1.77, 2009-11-14 02:20:04+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + include depsver.mf - sntp/libopts/COPYING.lgpl@1.0, 2007-05-19 00:04:59-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntp_peer.c@1.124, 2009-11-14 02:20:04+00:00, davehart@shiny.ad.hartbrothers.com +0 -1 + remove stale comment, stoa() uses LIB_GETBUF() and is safe to call + repeatedly in the same printf(). - sntp/libopts/COPYING.mbsd@1.1, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +26 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/COPYING.mbsd + ntpdate/Makefile.am@1.21, 2009-11-14 02:20:04+00:00, davehart@shiny.ad.hartbrothers.com +4 -2 + include depsver.mf - sntp/libopts/COPYING.mbsd@1.0, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/Makefile.am@1.45, 2009-11-14 02:20:04+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + include depsver.mf - sntp/libopts/MakeDefs.inc@1.1, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +0 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/MakeDefs.inc + ntpq/Makefile.am@1.39, 2009-11-14 02:20:04+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + include depsver.mf - sntp/libopts/MakeDefs.inc@1.0, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +0 -0 + ntpsnmpd/Makefile.am@1.12, 2009-11-14 02:20:04+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + include depsver.mf - sntp/libopts/Makefile.am@1.1, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +24 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/Makefile.am + parseutil/Makefile.am@1.11, 2009-11-14 02:20:04+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + include depsver.mf - sntp/libopts/Makefile.am@1.0, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/Makefile.am@1.13.1.4, 2009-11-14 02:20:04+00:00, davehart@shiny.ad.hartbrothers.com +4 -1 + include depsver.mf - sntp/libopts/README@1.1, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +93 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/README + sntp/configure.ac@1.24.1.1, 2009-11-14 02:20:04+00:00, davehart@shiny.ad.hartbrothers.com +1 -2 + AC_SEARCH_LIBS already tries without any libs, so wrapping with + AC_CHECK_FUNC just bloats - sntp/libopts/README@1.0, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/deps-ver@1.1, 2009-11-14 02:17:31+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + a change to the contents of this file cleans any existing .deps - sntp/libopts/autoopts.c@1.1, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +1120 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/autoopts.c + sntp/deps-ver@1.0, 2009-11-14 02:17:31+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 - sntp/libopts/autoopts.c@1.0, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +0 -0 + util/Makefile.am@1.42, 2009-11-14 02:20:04+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + include depsver.mf - sntp/libopts/autoopts.h@1.1, 2007-05-19 00:05:01-04:00, stenn@whimsy.udel.edu +387 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/autoopts.h +ChangeSet@1.2060.1.38, 2009-11-13 13:31:39+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + configure.ac: + mirror inet_ntop(), inet_pton() tests from top configure.ac + remomve ISC_PLATFORM_NEEDATON test, no longer used by libisc - sntp/libopts/autoopts.h@1.0, 2007-05-19 00:05:01-04:00, stenn@whimsy.udel.edu +0 -0 + configure.ac@1.459.1.10, 2009-11-13 13:31:31+00:00, davehart@shiny.ad.hartbrothers.com +0 -1 + remomve ISC_PLATFORM_NEEDATON test, no longer used by libisc - sntp/libopts/autoopts/options.h@1.1, 2007-05-19 00:05:12-04:00, stenn@whimsy.udel.edu +977 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/autoopts/options.h + sntp/configure.ac@1.25, 2009-11-13 13:31:31+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + mirror inet_ntop(), inet_pton() tests from top configure.ac - sntp/libopts/autoopts/options.h@1.0, 2007-05-19 00:05:12-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.2060.1.37, 2009-11-12 13:37:43+00:00, davehart@shiny.ad.hartbrothers.com +9 -0 + [Bug 1343] sntp illegal C does not compile on Solaris 7. + Windows VC9/VS2008: use generic library name libeay32.lib + instead of variants encoding build type to match what you + get building OpenSSL from source. - sntp/libopts/autoopts/usage-txt.h@1.1, 2007-05-19 00:05:13-04:00, stenn@whimsy.udel.edu +355 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/autoopts/usage-txt.h + ChangeLog@1.539, 2009-11-12 13:37:42+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1343] sntp illegal C does not compile on Solaris 7. - sntp/libopts/autoopts/usage-txt.h@1.0, 2007-05-19 00:05:13-04:00, stenn@whimsy.udel.edu +0 -0 + ports/winnt/vs2008/ntp-keygen/ntp-keygen.vcproj@1.9, 2009-11-12 13:37:42+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + use generic library name libeay32.lib instead of variants + encoding build type to match what you get building OpenSSL + from source. - sntp/libopts/boolean.c@1.1, 2007-05-19 00:05:01-04:00, stenn@whimsy.udel.edu +106 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/boolean.c + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.22, 2009-11-12 13:37:42+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + use generic library name libeay32.lib instead of variants + encoding build type to match what you get building OpenSSL + from source. - sntp/libopts/boolean.c@1.0, 2007-05-19 00:05:01-04:00, stenn@whimsy.udel.edu +0 -0 + ports/winnt/vs2008/ntpdate/ntpdate.vcproj@1.12, 2009-11-12 13:37:42+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + use generic library name libeay32.lib instead of variants + encoding build type to match what you get building OpenSSL + from source. - sntp/libopts/compat/compat.h@1.1, 2007-05-19 00:05:13-04:00, stenn@whimsy.udel.edu +319 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/compat.h + ports/winnt/vs2008/ntpdc/ntpdc.vcproj@1.12, 2009-11-12 13:37:42+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + use generic library name libeay32.lib instead of variants + encoding build type to match what you get building OpenSSL + from source. - sntp/libopts/compat/compat.h@1.0, 2007-05-19 00:05:13-04:00, stenn@whimsy.udel.edu +0 -0 + ports/winnt/vs2008/ntpq/ntpq.vcproj@1.11, 2009-11-12 13:37:42+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + use generic library name libeay32.lib instead of variants + encoding build type to match what you get building OpenSSL + from source. - sntp/libopts/compat/pathfind.c@1.1, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +339 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/pathfind.c + sntp/log.c@1.11, 2009-11-12 13:37:42+00:00, davehart@shiny.ad.hartbrothers.com +9 -9 + [Bug 1343] sntp illegal C does not compile on Solaris 7. - sntp/libopts/compat/pathfind.c@1.0, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/main.c@1.21, 2009-11-12 13:37:42+00:00, davehart@shiny.ad.hartbrothers.com +5 -8 + [Bug 1343] sntp illegal C does not compile on Solaris 7. - sntp/libopts/compat/snprintf.c@1.1, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +60 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/snprintf.c + sntp/networking.c@1.28, 2009-11-12 13:37:42+00:00, davehart@shiny.ad.hartbrothers.com +14 -11 + [Bug 1343] sntp illegal C does not compile on Solaris 7. - sntp/libopts/compat/snprintf.c@1.0, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.2060.1.36, 2009-11-12 06:10:27-05:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P244_RC + TAG: NTP_4_2_5P244_RC - sntp/libopts/compat/strchr.c@1.1, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +60 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/strchr.c + ChangeLog@1.538, 2009-11-12 06:10:00-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P244_RC - sntp/libopts/compat/strchr.c@1.0, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.c@1.238, 2009-11-12 06:10:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P244_RC - sntp/libopts/compat/strdup.c@1.1, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +19 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/strdup.c + ntpd/ntpd-opts.h@1.238, 2009-11-12 06:10:02-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P244_RC - sntp/libopts/compat/strdup.c@1.0, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.texi@1.236, 2009-11-12 06:10:03-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P244_RC - sntp/libopts/compat/windows-config.h@1.1, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +130 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/windows-config.h + ntpd/ntpd.1@1.236, 2009-11-12 06:10:04-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P244_RC - sntp/libopts/compat/windows-config.h@1.0, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.c@1.234, 2009-11-12 06:10:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P244_RC - sntp/libopts/configfile.c@1.1, 2007-05-19 00:05:01-04:00, stenn@whimsy.udel.edu +1290 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/configfile.c + ntpdc/ntpdc-opts.h@1.234, 2009-11-12 06:10:06-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P244_RC - sntp/libopts/configfile.c@1.0, 2007-05-19 00:05:01-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.texi@1.233, 2009-11-12 06:10:07-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P244_RC - sntp/libopts/cook.c@1.1, 2007-05-19 00:05:02-04:00, stenn@whimsy.udel.edu +354 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/cook.c + ntpdc/ntpdc.1@1.233, 2009-11-12 06:10:07-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P244_RC - sntp/libopts/cook.c@1.0, 2007-05-19 00:05:02-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.c@1.235, 2009-11-12 06:10:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P244_RC - sntp/libopts/enumeration.c@1.1, 2007-05-19 00:05:03-04:00, stenn@whimsy.udel.edu +498 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/enumeration.c + ntpq/ntpq-opts.h@1.235, 2009-11-12 06:10:09-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P244_RC - sntp/libopts/enumeration.c@1.0, 2007-05-19 00:05:03-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.texi@1.234, 2009-11-12 06:10:10-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P244_RC - sntp/libopts/environment.c@1.1, 2007-05-19 00:05:04-04:00, stenn@whimsy.udel.edu +279 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/environment.c + ntpq/ntpq.1@1.234, 2009-11-12 06:10:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P244_RC - sntp/libopts/environment.c@1.0, 2007-05-19 00:05:04-04:00, stenn@whimsy.udel.edu +0 -0 + ntpsnmpd/ntpsnmpd-opts.c@1.113, 2009-11-12 06:10:12-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P244_RC - sntp/libopts/genshell.c@1.1, 2007-05-19 00:05:04-04:00, stenn@whimsy.udel.edu +354 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/genshell.c + ntpsnmpd/ntpsnmpd-opts.h@1.113, 2009-11-12 06:10:13-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P244_RC - sntp/libopts/genshell.c@1.0, 2007-05-19 00:05:04-04:00, stenn@whimsy.udel.edu +0 -0 + ntpsnmpd/ntpsnmpd-opts.texi@1.113, 2009-11-12 06:10:14-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P244_RC - sntp/libopts/genshell.h@1.1, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +149 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/genshell.h + ntpsnmpd/ntpsnmpd.1@1.113, 2009-11-12 06:10:15-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P244_RC - sntp/libopts/genshell.h@1.0, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +0 -0 + packageinfo.sh@1.248, 2009-11-12 06:10:15-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P244_RC - sntp/libopts/libopts.c@1.1, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +30 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/libopts.c + sntp/sntp-opts.c@1.107, 2009-11-12 06:10:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P244_RC - sntp/libopts/libopts.c@1.0, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.h@1.107, 2009-11-12 06:10:17-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P244_RC - sntp/libopts/load.c@1.1, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +563 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/load.c + sntp/sntp-opts.texi@1.107, 2009-11-12 06:10:17-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P244_RC - sntp/libopts/load.c@1.0, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp.1@1.107, 2009-11-12 06:10:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P244_RC - sntp/libopts/m4/libopts.m4@1.1, 2007-05-19 00:05:15-04:00, stenn@whimsy.udel.edu +509 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/m4/libopts.m4 + util/ntp-keygen-opts.c@1.237, 2009-11-12 06:10:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P244_RC - sntp/libopts/m4/libopts.m4@1.0, 2007-05-19 00:05:15-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.h@1.237, 2009-11-12 06:10:21-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P244_RC - sntp/libopts/m4/liboptschk.m4@1.1, 2007-05-19 00:05:15-04:00, stenn@whimsy.udel.edu +42 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/m4/liboptschk.m4 + util/ntp-keygen-opts.texi@1.236, 2009-11-12 06:10:22-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P244_RC - sntp/libopts/m4/liboptschk.m4@1.0, 2007-05-19 00:05:15-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen.1@1.236, 2009-11-12 06:10:23-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P244_RC - sntp/libopts/makeshell.c@1.1, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +1122 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/makeshell.c +ChangeSet@1.2060.1.35, 2009-11-12 04:26:17-05:00, stenn@whimsy.udel.edu +2 -0 + keygen.html updates from Dave Mills - sntp/libopts/makeshell.c@1.0, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +0 -0 + ChangeLog@1.537, 2009-11-12 04:26:03-05:00, stenn@whimsy.udel.edu +1 -0 + keygen.html updates from Dave Mills - sntp/libopts/nested.c@1.1, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +733 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/nested.c + html/keygen.html@1.18, 2009-11-12 04:26:04-05:00, stenn@whimsy.udel.edu +46 -26 + keygen.html updates from Dave Mills - sntp/libopts/nested.c@1.0, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.2060.1.34, 2009-11-12 02:29:11+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ntp-keygen.c: + 21 bytes don't fit well in a 17 byte buffer - sntp/libopts/numeric.c@1.1, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +93 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/numeric.c + util/ntp-keygen.c@1.63, 2009-11-12 02:28:59+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + 21 bytes don't fit well in a 17 byte buffer - sntp/libopts/numeric.c@1.0, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.2060.1.33, 2009-11-12 00:51:35+00:00, davehart@shiny.ad.hartbrothers.com +11 -0 + Cleanup, fix ntp_intres when requestkey type means digests + larger than 16 octets. + Add /lib to OpenSSL library search path, OpenSolaris has it there. - sntp/libopts/pgusage.c@1.1, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +157 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/pgusage.c + configure.ac@1.459.1.9, 2009-11-12 00:51:33+00:00, davehart@shiny.ad.hartbrothers.com +1 -2 + Add /lib to OpenSSL library search path, OpenSolaris has it there. - sntp/libopts/pgusage.c@1.0, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +0 -0 + include/ntp_request.h@1.40, 2009-11-12 00:51:33+00:00, davehart@shiny.ad.hartbrothers.com +5 -2 + accomodate larger digests in mode 7 struct req_pkt. + introduce REQ_TAIL_MIN to represent struct req_pkt_tail size with a + 16-octet digest. - sntp/libopts/proto.h@1.1, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +91 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/proto.h + include/ntpd.h@1.136, 2009-11-12 00:51:33+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + expose req_keytype, req_hashlen for ntp_config.c use - sntp/libopts/proto.h@1.0, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +0 -0 + libntp/authreadkeys.c@1.15, 2009-11-12 00:51:33+00:00, davehart@shiny.ad.hartbrothers.com +6 -4 + bounds check keystr[] access, eliminate truncation warning - sntp/libopts/putshell.c@1.1, 2007-05-19 00:05:07-04:00, stenn@whimsy.udel.edu +335 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/putshell.c + libntp/hextoint.c@1.3, 2009-11-12 00:51:34+00:00, davehart@shiny.ad.hartbrothers.com +14 -12 + fix indents, more error checks - sntp/libopts/putshell.c@1.0, 2007-05-19 00:05:07-04:00, stenn@whimsy.udel.edu +0 -0 + libntp/ssl_init.c@1.4, 2009-11-12 00:51:34+00:00, davehart@shiny.ad.hartbrothers.com +17 -5 + #include for toupper() - sntp/libopts/restore.c@1.1, 2007-05-19 00:05:07-04:00, stenn@whimsy.udel.edu +250 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/restore.c + ntpd/ntp_config.c@1.236, 2009-11-12 00:51:34+00:00, davehart@shiny.ad.hartbrothers.com +21 -6 + change #if 0 to #ifdef FORCE_DEFER_DNS - sntp/libopts/restore.c@1.0, 2007-05-19 00:05:07-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntp_intres.c@1.70, 2009-11-12 00:51:34+00:00, davehart@shiny.ad.hartbrothers.com +67 -27 + support new authentication layout with larger digests + remove dead debugging code, style - sntp/libopts/save.c@1.1, 2007-05-19 00:05:08-04:00, stenn@whimsy.udel.edu +512 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/save.c + ntpd/ntp_request.c@1.80.1.6, 2009-11-12 00:51:34+00:00, davehart@shiny.ad.hartbrothers.com +3 -3 + account for growth of struct req_pkt_tail beyond 16-octet digest + by using REQ_TAIL_MIN instead of sizeof(req_pkt_tail). + fix format string warnings. - sntp/libopts/save.c@1.0, 2007-05-19 00:05:08-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/layout.std@1.9, 2009-11-12 00:51:34+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + req_pkt and req_pkt_tail both grew by 4 octets, but interop is + preserved - sntp/libopts/sort.c@1.1, 2007-05-19 00:05:08-04:00, stenn@whimsy.udel.edu +359 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/sort.c + ntpdc/ntpdc.c@1.74, 2009-11-12 00:51:34+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + quiet shadows global warning - sntp/libopts/sort.c@1.0, 2007-05-19 00:05:08-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.2060.19.1, 2009-11-11 12:36:24+00:00, davehart@shiny.ad.hartbrothers.com +13 -0 + [Bug 1003] ntpdc unconfig command doesn't prompt for keyid. + [Bug 1376] Enable authenticated ntpq and ntpdc using newly-available + digest types. + ntp-keygen, Autokey OpenSSL build vs. run version mismatch is now a + non-fatal warning. - sntp/libopts/stack.c@1.1, 2007-05-19 00:05:09-04:00, stenn@whimsy.udel.edu +269 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/stack.c + ChangeLog@1.532.1.1, 2009-11-11 12:36:22+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + [Bug 1003] ntpdc unconfig command doesn't prompt for keyid. + [Bug 1376] Enable authenticated ntpq and ntpdc using newly-available + digest types. + ntp-keygen, Autokey OpenSSL build vs. run version mismatch is now a + non-fatal warning. - sntp/libopts/stack.c@1.0, 2007-05-19 00:05:09-04:00, stenn@whimsy.udel.edu +0 -0 + include/ntp_request.h@1.39, 2009-11-11 12:36:22+00:00, davehart@shiny.ad.hartbrothers.com +10 -11 + [Bug 1376] Enable authenticated ntpq and ntpdc using newly-available + digest types. - sntp/libopts/streqvcmp.c@1.1, 2007-05-19 00:05:09-04:00, stenn@whimsy.udel.edu +289 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/streqvcmp.c + include/ntp_stdlib.h@1.40, 2009-11-11 12:36:22+00:00, davehart@shiny.ad.hartbrothers.com +7 -2 + [Bug 1376] Enable authenticated ntpq and ntpdc using newly-available + digest types. - sntp/libopts/streqvcmp.c@1.0, 2007-05-19 00:05:09-04:00, stenn@whimsy.udel.edu +0 -0 + libntp/a_md5encrypt.c@1.26, 2009-11-11 12:36:22+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + [Bug 1376] Enable authenticated ntpq and ntpdc using newly-available + digest types. - sntp/libopts/text_mmap.c@1.1, 2007-05-19 00:05:10-04:00, stenn@whimsy.udel.edu +363 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/text_mmap.c + libntp/authreadkeys.c@1.12.1.1, 2009-11-11 12:36:22+00:00, davehart@shiny.ad.hartbrothers.com +5 -10 + [Bug 1376] Enable authenticated ntpq and ntpdc using newly-available + digest types. - sntp/libopts/text_mmap.c@1.0, 2007-05-19 00:05:10-04:00, stenn@whimsy.udel.edu +0 -0 + libntp/ssl_init.c@1.3, 2009-11-11 12:36:22+00:00, davehart@shiny.ad.hartbrothers.com +88 -5 + ntp-keygen, Autokey OpenSSL build vs. run version mismatch is now a + non-fatal warning. + [Bug 1376] Enable authenticated ntpq and ntpdc using newly-available + digest types. - sntp/libopts/tokenize.c@1.1, 2007-05-19 00:05:10-04:00, stenn@whimsy.udel.edu +321 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/tokenize.c + ntpd/keyword-gen.c@1.5, 2009-11-11 12:36:22+00:00, davehart@shiny.ad.hartbrothers.com +5 -5 + use + + do + a; + while (b); + + rather than equivalent + + a; + while(b) + a; - sntp/libopts/tokenize.c@1.0, 2007-05-19 00:05:10-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntp_intres.c@1.67.1.1, 2009-11-11 12:36:22+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + use sizeof buffer not (formerly) equivalent macro - sntp/libopts/usage.c@1.1, 2007-05-19 00:05:11-04:00, stenn@whimsy.udel.edu +740 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/usage.c + ntpd/ntp_request.c@1.80.1.5, 2009-11-11 12:36:23+00:00, davehart@shiny.ad.hartbrothers.com +80 -88 + [Bug 1376] Enable authenticated ntpq and ntpdc using newly-available + digest types. - sntp/libopts/usage.c@1.0, 2007-05-19 00:05:11-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc.c@1.73, 2009-11-11 12:36:23+00:00, davehart@shiny.ad.hartbrothers.com +143 -94 + [Bug 1003] ntpdc unconfig command doesn't prompt for keyid. + [Bug 1376] Enable authenticated ntpq and ntpdc using newly-available + digest types. - sntp/libopts/version.c@1.1, 2007-05-19 00:05:12-04:00, stenn@whimsy.udel.edu +178 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/version.c + ntpdc/ntpdc_ops.c@1.62, 2009-11-11 12:36:23+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + whitespace only - sntp/libopts/version.c@1.0, 2007-05-19 00:05:12-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-subs.c@1.40, 2009-11-11 12:36:23+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + typo pointed out by Michael Tatarinov - sntp/sntp-opts.c@1.58, 2007-05-19 02:30:55-04:00, stenn@whimsy.udel.edu +21 -12 - We need to use the upgraded autogen/libopts in -stable too. + ntpq/ntpq.c@1.96, 2009-11-11 12:36:23+00:00, davehart@shiny.ad.hartbrothers.com +93 -69 + [Bug 1376] Enable authenticated ntpq and ntpdc using newly-available + digest types. - sntp/sntp-opts.h@1.58, 2007-05-19 02:30:56-04:00, stenn@whimsy.udel.edu +6 -6 - We need to use the upgraded autogen/libopts in -stable too. +ChangeSet@1.2060.1.31, 2009-11-11 05:46:08-05:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P243_RC + TAG: NTP_4_2_5P243_RC - sntp/sntp-opts.texi@1.55, 2007-05-19 02:30:57-04:00, stenn@whimsy.udel.edu +1 -1 - We need to use the upgraded autogen/libopts in -stable too. + ChangeLog@1.535, 2009-11-11 05:45:38-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P243_RC - sntp/sntp.1@1.58, 2007-05-19 02:30:58-04:00, stenn@whimsy.udel.edu +2 -2 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/ntpd-opts.c@1.237, 2009-11-11 05:45:41-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P243_RC - util/ntp-keygen-opts.c@1.59, 2007-05-19 02:31:00-04:00, stenn@whimsy.udel.edu +23 -14 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/ntpd-opts.h@1.237, 2009-11-11 05:45:41-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P243_RC - util/ntp-keygen-opts.h@1.59, 2007-05-19 02:31:02-04:00, stenn@whimsy.udel.edu +6 -6 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/ntpd-opts.texi@1.235, 2009-11-11 05:45:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P243_RC - util/ntp-keygen-opts.texi@1.57, 2007-05-19 02:31:04-04:00, stenn@whimsy.udel.edu +3 -3 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/ntpd.1@1.235, 2009-11-11 05:45:43-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P243_RC - util/ntp-keygen.1@1.57, 2007-05-19 02:31:04-04:00, stenn@whimsy.udel.edu +2 -2 - We need to use the upgraded autogen/libopts in -stable too. + ntpdc/ntpdc-opts.c@1.233, 2009-11-11 05:45:44-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P243_RC -ChangeSet@1.1480.1.1, 2007-05-18 02:20:56-04:00, stenn@whimsy.udel.edu +3 -0 - Release 4.2.4p2 + ntpdc/ntpdc-opts.h@1.233, 2009-11-11 05:45:45-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P243_RC - ChangeLog@1.11.1.1, 2007-05-18 02:19:13-04:00, stenn@whimsy.udel.edu +4 -2 - Release 4.2.4p2 + ntpdc/ntpdc-opts.texi@1.232, 2009-11-11 05:45:46-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P243_RC - NEWS@1.88, 2007-05-18 02:19:14-04:00, stenn@whimsy.udel.edu +6 -0 - Release 4.2.4p2 + ntpdc/ntpdc.1@1.232, 2009-11-11 05:45:47-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P243_RC - packageinfo.sh@1.79, 2007-05-18 02:20:38-04:00, stenn@whimsy.udel.edu +1 -1 - Release 4.2.4p2 + ntpq/ntpq-opts.c@1.234, 2009-11-11 05:45:47-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P243_RC -ChangeSet@1.1482, 2007-04-28 10:19:57+00:00, kardel@pogo.udel.edu +2 -0 - ntp_peer.c: - Bug 789 (backported from ntp-dev): - Fix multicast client crypto authentication and make sure arriving - multicast packets do not disturb the autokey dance. + ntpq/ntpq-opts.h@1.234, 2009-11-11 05:45:48-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P243_RC + + ntpq/ntpq-opts.texi@1.233, 2009-11-11 05:45:49-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P243_RC + + ntpq/ntpq.1@1.233, 2009-11-11 05:45:50-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P243_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.112, 2009-11-11 05:45:51-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P243_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.112, 2009-11-11 05:45:52-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P243_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.112, 2009-11-11 05:45:53-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P243_RC + + ntpsnmpd/ntpsnmpd.1@1.112, 2009-11-11 05:45:54-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P243_RC + + packageinfo.sh@1.247, 2009-11-11 05:45:55-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P243_RC + + sntp/sntp-opts.c@1.106, 2009-11-11 05:45:56-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P243_RC + + sntp/sntp-opts.h@1.106, 2009-11-11 05:45:56-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P243_RC + + sntp/sntp-opts.texi@1.106, 2009-11-11 05:45:57-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P243_RC + + sntp/sntp.1@1.106, 2009-11-11 05:45:57-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P243_RC + + util/ntp-keygen-opts.c@1.236, 2009-11-11 05:45:59-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P243_RC + + util/ntp-keygen-opts.h@1.236, 2009-11-11 05:45:59-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P243_RC + + util/ntp-keygen-opts.texi@1.235, 2009-11-11 05:46:00-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P243_RC + + util/ntp-keygen.1@1.235, 2009-11-11 05:46:01-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P243_RC + +ChangeSet@1.2060.1.30, 2009-11-11 04:04:33-05:00, stenn@pogo.udel.edu +1 -0 + [Bug 1226] Fix deferred DNS lookups + + ChangeLog@1.534, 2009-11-11 04:04:21-05:00, stenn@pogo.udel.edu +1 -0 + [Bug 1226] Fix deferred DNS lookups + +ChangeSet@1.2060.18.2, 2009-11-11 03:08:32-05:00, stenn@whimsy.udel.edu +6 -0 + new crypto signature cleanup + + ChangeLog@1.533, 2009-11-11 03:08:17-05:00, stenn@whimsy.udel.edu +1 -0 + new crypto signature cleanup + + html/authopt.html@1.58, 2009-11-11 03:07:21-05:00, stenn@whimsy.udel.edu +14 -5 + new crypto signature cleanup + + html/keygen.html@1.17, 2009-11-11 03:07:26-05:00, stenn@whimsy.udel.edu +12 -3 + new crypto signature cleanup + + libntp/authkeys.c@1.20, 2009-11-11 03:06:02-05:00, stenn@whimsy.udel.edu +11 -2 + new crypto signature cleanup + + libntp/authreadkeys.c@1.13, 2009-11-11 03:06:03-05:00, stenn@whimsy.udel.edu +38 -12 + new crypto signature cleanup + + util/ntp-keygen.c@1.62, 2009-11-11 03:04:32-05:00, stenn@whimsy.udel.edu +24 -4 + new crypto signature cleanup + +ChangeSet@1.2060.18.1, 2009-11-10 05:02:56-05:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P242_RC + TAG: NTP_4_2_5P242_RC + + ChangeLog@1.532, 2009-11-10 05:02:21-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P242_RC + + ntpd/ntpd-opts.c@1.236, 2009-11-10 05:02:25-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P242_RC + + ntpd/ntpd-opts.h@1.236, 2009-11-10 05:02:26-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P242_RC + + ntpd/ntpd-opts.texi@1.234, 2009-11-10 05:02:27-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P242_RC + + ntpd/ntpd.1@1.234, 2009-11-10 05:02:28-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P242_RC + + ntpdc/ntpdc-opts.c@1.232, 2009-11-10 05:02:28-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P242_RC + + ntpdc/ntpdc-opts.h@1.232, 2009-11-10 05:02:29-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P242_RC + + ntpdc/ntpdc-opts.texi@1.231, 2009-11-10 05:02:30-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P242_RC + + ntpdc/ntpdc.1@1.231, 2009-11-10 05:02:31-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P242_RC + + ntpq/ntpq-opts.c@1.233, 2009-11-10 05:02:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P242_RC + + ntpq/ntpq-opts.h@1.233, 2009-11-10 05:02:32-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P242_RC + + ntpq/ntpq-opts.texi@1.232, 2009-11-10 05:02:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P242_RC + + ntpq/ntpq.1@1.232, 2009-11-10 05:02:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P242_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.111, 2009-11-10 05:02:35-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P242_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.111, 2009-11-10 05:02:36-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P242_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.111, 2009-11-10 05:02:37-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P242_RC + + ntpsnmpd/ntpsnmpd.1@1.111, 2009-11-10 05:02:38-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P242_RC + + packageinfo.sh@1.246, 2009-11-10 05:02:39-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P242_RC + + sntp/sntp-opts.c@1.105, 2009-11-10 05:02:39-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P242_RC + + sntp/sntp-opts.h@1.105, 2009-11-10 05:02:41-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P242_RC + + sntp/sntp-opts.texi@1.105, 2009-11-10 05:02:41-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P242_RC + + sntp/sntp.1@1.105, 2009-11-10 05:02:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P242_RC + + util/ntp-keygen-opts.c@1.235, 2009-11-10 05:02:43-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P242_RC + + util/ntp-keygen-opts.h@1.235, 2009-11-10 05:02:44-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P242_RC + + util/ntp-keygen-opts.texi@1.234, 2009-11-10 05:02:45-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P242_RC + + util/ntp-keygen.1@1.234, 2009-11-10 05:02:46-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P242_RC + +ChangeSet@1.2060.1.28, 2009-11-09 18:15:07-05:00, murray@malarky.udel.edu +3 -0 + configure.ac, ntp_intres.c: + Fix for bug-1266: reload /etc/resolv.conf on deferred DNS + ntp_config.c: + Hacks to help debug deferred DNS + (default off) + + configure.ac@1.459.1.8, 2009-11-09 18:11:48-05:00, murray@malarky.udel.edu +4 -0 + Fix for bug-1266: reload /etc/resolv.conf on deferred DNS + + ntpd/ntp_config.c@1.235, 2009-11-09 18:13:37-05:00, murray@malarky.udel.edu +16 -0 + Hacks to help debug deferred DNS + (default off) + + ntpd/ntp_intres.c@1.68, 2009-11-09 18:14:15-05:00, murray@malarky.udel.edu +15 -7 + Fix for bug-1266: reload /etc/resolv.conf on deferred DNS + +ChangeSet@1.2060.17.2, 2009-11-09 04:14:13-05:00, stenn@whimsy.udel.edu +3 -0 + Documentation updates from Dave Mills + + ChangeLog@1.525.3.2, 2009-11-09 04:13:33-05:00, stenn@whimsy.udel.edu +1 -0 + Documentation updates from Dave Mills + + html/authopt.html@1.57, 2009-11-09 04:13:42-05:00, stenn@whimsy.udel.edu +5 -3 + Documentation updates from Dave Mills + + html/index.html@1.41, 2009-11-09 04:13:46-05:00, stenn@whimsy.udel.edu +25 -4 + Documentation updates from Dave Mills + +ChangeSet@1.2060.17.1, 2009-11-09 04:08:41-05:00, stenn@whimsy.udel.edu +2 -0 + authkeys.c cleanup from Dave Mills + + ChangeLog@1.525.3.1, 2009-11-09 04:08:24-05:00, stenn@whimsy.udel.edu +1 -0 + authkeys.c cleanup from Dave Mills + + libntp/authkeys.c@1.17.1.1, 2009-11-09 04:08:26-05:00, stenn@whimsy.udel.edu +3 -4 + authkeys.c cleanup from Dave Mills + +ChangeSet@1.2060.1.26, 2009-11-09 08:03:02+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1371] deferred DNS lookup failing with INFO_ERR_AUTH. + fixed in prior changeset with ntp_request.h modification + to REQ_LEN_NOMAC. + + ChangeLog@1.530, 2009-11-09 08:03:01+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1371] deferred DNS lookup failing with INFO_ERR_AUTH. + +ChangeSet@1.2060.4.2, 2009-11-09 07:19:52+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + Shrink keyword scanner FSM entries from 64 to 32 bits apiece. + applies to prior changeset and this ChangeLog update + + ChangeLog@1.498.2.1, 2009-11-09 07:19:52+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + Shrink keyword scanner FSM entries from 64 to 32 bits apiece. + +ChangeSet@1.2060.1.23, 2009-11-09 07:17:29+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + Stub out isc/mem.h, shaving 47k from a MIPS ntpd binary. + (applies to prior changeset along with this one) + + ChangeLog@1.511.3.1, 2009-11-09 07:17:28+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + Stub out isc/mem.h, shaving 47k from a MIPS ntpd binary. + + include/isc/mem.h@1.2, 2009-11-09 07:17:28+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + also stub out isc_mem_printallactive() to silence warning and avoid + trouble down the road, it's referenced by tasks.c + +ChangeSet@1.2060.16.1, 2009-11-08 12:32:55+00:00, kardel@pogo.udel.edu +2 -0 + clk_trimtsip.c: + [Bug 1363] CID 92 clarify fallthrough case ChangeLog: - Bug 789 (backported from ntp-dev): - Fix multicast client crypto authentication and make sure arriving - multicast packets do not disturb the autokey dance. + [Bug 1363] CID 92 clarify fallthrough case in clk_trimtsip.c - ChangeLog@1.13, 2007-04-28 10:15:34+00:00, kardel@pogo.udel.edu +4 -1 - Bug 789: - Fix multicast client crypto authentication and make sure arriving - multicast packets do not disturb the autokey dance. + ChangeLog@1.525.2.1, 2009-11-08 12:31:54+00:00, kardel@pogo.udel.edu +1 -0 + [Bug 1363] CID 92 clarify fallthrough case in clk_trimtsip.c - ntpd/ntp_peer.c@1.99, 2007-04-28 10:06:31+00:00, kardel@pogo.udel.edu +21 -12 - Bug 789 (backported from ntp-dev): - fix multicast client mode by re-setting - crypto information only when the local address - changes and not for BCLNTs. - Addtitionally don't update the local address while - a BCLNT is doing the autokey dance. + libparse/clk_trimtsip.c@1.10, 2009-11-08 12:32:13+00:00, kardel@pogo.udel.edu +10 -3 + [Bug 1363] CID 92 clarify fallthrough case -ChangeSet@1.1481, 2007-04-28 10:03:26+00:00, kardel@pogo.udel.edu +3 -0 - ntp_io.c, ChangeLog: - bug 785 (backport from ntp-dev): - improve handling of multicast interfaces - (multicast routers still need to run a multicast routing software/daemon) - ntp_peer.c: - bug 785 (backport from ntp-dev): - clarify debug messages +ChangeSet@1.2060.8.22, 2009-11-07 23:44:10+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + Use Frank Kardel's suggestion to collapse 3 cases to 1 for NetBSD + USE_FSETOWNCTTY test. - ChangeLog@1.12, 2007-04-28 10:00:26+00:00, kardel@pogo.udel.edu +1 -0 - bug 785 (backport from ntp-dev): - improve handling of multicast interfaces - (multicast routers still need to run a multicast routing software/daemon) + configure.ac@1.459.2.4, 2009-11-07 23:44:09+00:00, davehart@shiny.ad.hartbrothers.com +4 -9 + Use Frank Kardel's suggestion to collapse 3 cases to 1 for NetBSD + USE_FSETOWNCTTY test. - ntpd/ntp_io.c@1.248, 2007-04-28 09:52:18+00:00, kardel@pogo.udel.edu +84 -62 - bug 785 (backport from ntp-dev): - improve handling of multicast interfaces - (multicast routers still need to run a multicast routing software/daemon) +ChangeSet@1.2060.15.2, 2009-11-07 22:46:41+00:00, davehart@shiny.ad.hartbrothers.com +14 -0 + Fix authenticated ntpdc, broken in p240. - ntpd/ntp_peer.c@1.98, 2007-04-28 09:53:09+00:00, kardel@pogo.udel.edu +2 -2 - bug 785 (backport from ntp-dev): - clarify debug messages + ChangeLog@1.525.1.2, 2009-11-07 22:46:39+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + Fix authenticated ntpdc, broken in p240. -ChangeSet@1.1480, 2007-04-14 19:05:07-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P2_RC1 - TAG: NTP_4_2_4P2_RC1 + include/ntp.h@1.168, 2009-11-07 22:46:39+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + parenthesize macro expansions such as: + 12 * sizeof(u_int32) - ntpd/ntpd-opts.c@1.59, 2007-04-14 19:04:46-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + include/ntp_request.h@1.38, 2009-11-07 22:46:39+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + comments only - ntpd/ntpd-opts.h@1.59, 2007-04-14 19:04:46-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC1 + include/ntp_stdlib.h@1.39, 2009-11-07 22:46:39+00:00, davehart@shiny.ad.hartbrothers.com +3 -2 + separate OpenSSL version check from INIT_SSL() - ntpd/ntpd-opts.texi@1.58, 2007-04-14 19:04:47-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC1 + libntp/a_md5encrypt.c@1.23.1.2, 2009-11-07 22:46:39+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + [Bug 1368] libntp does not compile --without-crypto + merge cleanup - ntpd/ntpd.1@1.57, 2007-04-14 19:04:47-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + libntp/authkeys.c@1.18, 2009-11-07 22:46:39+00:00, davehart@shiny.ad.hartbrothers.com +3 -4 + move break; in authhavekey() back where it belongs after recent + flub - ntpd/ntpdsim-opts.c@1.59, 2007-04-14 19:04:48-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + libntp/authreadkeys.c@1.10.1.2, 2009-11-07 22:46:40+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + [Bug 1368] libntp doesn't compile --without-crypto - ntpd/ntpdsim-opts.h@1.59, 2007-04-14 19:04:49-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC1 + libntp/ssl_init.c@1.2, 2009-11-07 22:46:40+00:00, davehart@shiny.ad.hartbrothers.com +11 -3 + separate OpenSSL version check from INIT_SSL() - ntpd/ntpdsim-opts.texi@1.57, 2007-04-14 19:04:50-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC1 + ntpd/ntp_control.c@1.129, 2009-11-07 22:46:40+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + correct harmless htons()/ntohs() mixup - ntpd/ntpdsim.1@1.57, 2007-04-14 19:04:50-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + ntpd/ntp_crypto.c@1.146, 2009-11-07 22:46:40+00:00, davehart@shiny.ad.hartbrothers.com +3 -2 + separate OpenSSL version check from INIT_SSL() - ntpdc/ntpdc-opts.c@1.59, 2007-04-14 19:04:51-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + ntpd/ntp_intres.c@1.67, 2009-11-07 22:46:40+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + use sizeof rather than REQ_MAC_LEN for recv buffer size to prepare + for enabling authenticated mode 7 with non-MD5 keys - ntpdc/ntpdc-opts.h@1.59, 2007-04-14 19:04:52-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC1 + ntpd/ntp_request.c@1.80.1.4, 2009-11-07 22:46:40+00:00, davehart@shiny.ad.hartbrothers.com +8 -7 + eliminate extra parentheses, return after req_ack() - ntpdc/ntpdc-opts.texi@1.57, 2007-04-14 19:04:52-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC1 + ntpdc/ntpdc.c@1.72, 2009-11-07 22:46:40+00:00, davehart@shiny.ad.hartbrothers.com +11 -11 + Fix authenticated ntpdc, broken in p240. - ntpdc/ntpdc.1@1.57, 2007-04-14 19:04:53-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + util/ntp-keygen.c@1.61, 2009-11-07 22:46:40+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + separate OpenSSL version check from INIT_SSL() - ntpq/ntpq-opts.c@1.61, 2007-04-14 19:04:54-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 +ChangeSet@1.2060.8.20, 2009-11-07 12:16:01-05:00, murray@pogo.udel.edu +3 -0 + a_md5encrypt.c, authreadkeys.c, ChangeLog: + Fix for bug 1368 - typos in --without-crypto case - ntpq/ntpq-opts.h@1.61, 2007-04-14 19:04:55-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC1 + ChangeLog@1.526, 2009-11-07 12:14:57-05:00, murray@pogo.udel.edu +1 -0 + Fix for bug 1368 - ntpq/ntpq-opts.texi@1.58, 2007-04-14 19:04:55-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC1 + libntp/a_md5encrypt.c@1.24, 2009-11-07 12:15:05-05:00, murray@pogo.udel.edu +1 -0 + Fix for bug 1368 - ntpq/ntpq.1@1.57, 2007-04-14 19:04:56-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + libntp/authreadkeys.c@1.11, 2009-11-07 12:15:14-05:00, murray@pogo.udel.edu +1 -1 + Fix for bug 1368 - packageinfo.sh@1.78, 2007-04-14 19:04:57-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 +ChangeSet@1.2060.8.19, 2009-11-07 05:42:36-05:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P241_RC + TAG: NTP_4_2_5P241_RC - sntp/sntp-opts.c@1.57, 2007-04-14 19:04:57-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + ChangeLog@1.525, 2009-11-07 05:42:05-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P241_RC - sntp/sntp-opts.h@1.57, 2007-04-14 19:04:58-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC1 + ntpd/ntpd-opts.c@1.235, 2009-11-07 05:42:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P241_RC - sntp/sntp-opts.texi@1.54, 2007-04-14 19:04:59-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC1 + ntpd/ntpd-opts.h@1.235, 2009-11-07 05:42:08-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P241_RC - sntp/sntp.1@1.57, 2007-04-14 19:04:59-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + ntpd/ntpd-opts.texi@1.233, 2009-11-07 05:42:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P241_RC - util/ntp-keygen-opts.c@1.58, 2007-04-14 19:05:00-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + ntpd/ntpd.1@1.233, 2009-11-07 05:42:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P241_RC - util/ntp-keygen-opts.h@1.58, 2007-04-14 19:05:01-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC1 + ntpdc/ntpdc-opts.c@1.231, 2009-11-07 05:42:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P241_RC - util/ntp-keygen-opts.texi@1.56, 2007-04-14 19:05:02-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC1 + ntpdc/ntpdc-opts.h@1.231, 2009-11-07 05:42:12-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P241_RC - util/ntp-keygen.1@1.56, 2007-04-14 19:05:03-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + ntpdc/ntpdc-opts.texi@1.230, 2009-11-07 05:42:13-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P241_RC -ChangeSet@1.1479, 2007-04-14 18:16:04-04:00, stenn@deacon.udel.edu +2 -0 - Distribute include/homerc.def + ntpdc/ntpdc.1@1.230, 2009-11-07 05:42:13-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P241_RC - include/Makefile.am@1.25, 2007-04-14 18:15:53-04:00, stenn@deacon.udel.edu +1 -1 - Distribute include/homerc.def + ntpq/ntpq-opts.c@1.232, 2009-11-07 05:42:15-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P241_RC - packageinfo.sh@1.77, 2007-04-14 18:14:54-04:00, stenn@deacon.udel.edu +1 -1 - restart the RC + ntpq/ntpq-opts.h@1.232, 2009-11-07 05:42:16-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P241_RC -ChangeSet@1.1478, 2007-04-14 07:53:43-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P1_RC1 - TAG: NTP_4_2_4P1_RC1 + ntpq/ntpq-opts.texi@1.231, 2009-11-07 05:42:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P241_RC - ntpd/ntpd-opts.c@1.58, 2007-04-14 07:53:21-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + ntpq/ntpq.1@1.231, 2009-11-07 05:42:17-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P241_RC - ntpd/ntpd-opts.h@1.58, 2007-04-14 07:53:21-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P1_RC1 + ntpsnmpd/ntpsnmpd-opts.c@1.110, 2009-11-07 05:42:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P241_RC - ntpd/ntpd-opts.texi@1.57, 2007-04-14 07:53:23-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + ntpsnmpd/ntpsnmpd-opts.h@1.110, 2009-11-07 05:42:19-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P241_RC - ntpd/ntpd.1@1.56, 2007-04-14 07:53:23-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + ntpsnmpd/ntpsnmpd-opts.texi@1.110, 2009-11-07 05:42:20-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P241_RC - ntpd/ntpdsim-opts.c@1.58, 2007-04-14 07:53:24-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + ntpsnmpd/ntpsnmpd.1@1.110, 2009-11-07 05:42:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P241_RC - ntpd/ntpdsim-opts.h@1.58, 2007-04-14 07:53:25-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P1_RC1 + packageinfo.sh@1.245, 2009-11-07 05:42:21-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P241_RC - ntpd/ntpdsim-opts.texi@1.56, 2007-04-14 07:53:26-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P1_RC1 + sntp/sntp-opts.c@1.104, 2009-11-07 05:42:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P241_RC - ntpd/ntpdsim.1@1.56, 2007-04-14 07:53:27-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + sntp/sntp-opts.h@1.104, 2009-11-07 05:42:22-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P241_RC - ntpdc/ntpdc-opts.c@1.58, 2007-04-14 07:53:28-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + sntp/sntp-opts.texi@1.104, 2009-11-07 05:42:23-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P241_RC - ntpdc/ntpdc-opts.h@1.58, 2007-04-14 07:53:29-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P1_RC1 + sntp/sntp.1@1.104, 2009-11-07 05:42:23-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P241_RC - ntpdc/ntpdc-opts.texi@1.56, 2007-04-14 07:53:30-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + util/ntp-keygen-opts.c@1.234, 2009-11-07 05:42:25-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P241_RC - ntpdc/ntpdc.1@1.56, 2007-04-14 07:53:30-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + util/ntp-keygen-opts.h@1.234, 2009-11-07 05:42:26-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P241_RC - ntpq/ntpq-opts.c@1.60, 2007-04-14 07:53:31-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + util/ntp-keygen-opts.texi@1.233, 2009-11-07 05:42:27-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P241_RC - ntpq/ntpq-opts.h@1.60, 2007-04-14 07:53:32-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P1_RC1 + util/ntp-keygen.1@1.233, 2009-11-07 05:42:27-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P241_RC - ntpq/ntpq-opts.texi@1.57, 2007-04-14 07:53:33-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 +ChangeSet@1.2060.14.1, 2009-11-07 07:57:11+00:00, davehart@shiny.ad.hartbrothers.com +26 -0 + [Bug 1366] ioctl(TIOCSCTTY, 0) fails on NetBSD *[0-2].* > 3.99.7. + initialize OpenSSL before first use in libntp + ntpq, ntpdc, ntpdate use OpenSSL and need applink on Windows + add crypto digest and setvar default tests to ntpd/complete.conf - ntpq/ntpq.1@1.56, 2007-04-14 07:53:33-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + ChangeLog@1.521.1.1, 2009-11-07 07:57:09+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1366] ioctl(TIOCSCTTY, 0) fails on NetBSD *[0-2].* > 3.99.7. + CID 87 dead code in ntpq.c atoascii(). + - packageinfo.sh@1.76, 2007-04-14 07:53:34-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + configure.ac@1.459.2.3, 2009-11-07 07:57:09+00:00, davehart@shiny.ad.hartbrothers.com +44 -26 + [Bug 1366] ioctl(TIOCSCTTY, 0) fails on NetBSD *[0-2].* > 3.99.7. - sntp/sntp-opts.c@1.56, 2007-04-14 07:53:35-04:00, stenn@whimsy.udel.edu +8 -7 - NTP_4_2_4P1_RC1 + include/Makefile.am@1.35.2.2, 2009-11-07 07:57:09+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + new file include/ssl_applink.c - sntp/sntp-opts.h@1.56, 2007-04-14 07:53:35-04:00, stenn@whimsy.udel.edu +8 -14 - NTP_4_2_4P1_RC1 + include/ntp.h@1.167, 2009-11-07 07:57:09+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + make KEY_TYPE_MD5 equivalence to NID_md5 explicit - sntp/sntp-opts.texi@1.53, 2007-04-14 07:53:36-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P1_RC1 + include/ntp_request.h@1.37, 2009-11-07 07:57:09+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + req_pkt uses MAX_MD5_LEN not MAX_MAC_LEN now - sntp/sntp.1@1.56, 2007-04-14 07:53:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + include/ntp_stdlib.h@1.38, 2009-11-07 07:57:09+00:00, davehart@shiny.ad.hartbrothers.com +13 -0 + add ssl_init.c references - util/ntp-keygen-opts.c@1.57, 2007-04-14 07:53:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + include/ssl_applink.c@1.1, 2009-11-07 07:36:47+00:00, davehart@shiny.ad.hartbrothers.com +74 -0 + common code for Windows OpenSSL applink (ntpd, ntpdate, ntpdc, ntpq, ntp-keygen) + + include/ssl_applink.c@1.0, 2009-11-07 07:36:47+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + libntp/Makefile.am@1.47.1.1, 2009-11-07 07:57:09+00:00, davehart@shiny.ad.hartbrothers.com +65 -13 + add ssl_init.c + + libntp/a_md5encrypt.c@1.22.1.1, 2009-11-07 07:57:09+00:00, davehart@shiny.ad.hartbrothers.com +15 -6 + ensure OpenSSL has been initialized before use + use u_int instead of unsigned consistently + + libntp/authreadkeys.c@1.9.1.1, 2009-11-07 07:57:09+00:00, davehart@shiny.ad.hartbrothers.com +3 -7 + warning + + libntp/ssl_init.c@1.1, 2009-11-07 07:37:00+00:00, davehart@shiny.ad.hartbrothers.com +42 -0 + Shared OpenSSL initialization code for libntp, ntpd, ntp-keygen + + libntp/ssl_init.c@1.0, 2009-11-07 07:37:00+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ntpd/complete.conf@1.3, 2009-11-07 07:57:09+00:00, davehart@shiny.ad.hartbrothers.com +3 -2 + add crypto digest test, setvar default test + + ntpd/ntp_config.c@1.234, 2009-11-07 07:57:09+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + KEY_TYPE_MD5 -> NID_md5 + + ntpd/ntp_crypto.c@1.145, 2009-11-07 07:57:09+00:00, davehart@shiny.ad.hartbrothers.com +13 -23 + use common libntp OpenSSL initialization code + + ntpd/ntp_request.c@1.80.1.3, 2009-11-07 07:57:09+00:00, davehart@shiny.ad.hartbrothers.com +3 -5 + don't compare floats for equality, use DPRINTF + + ntpdate/ntpdate.c@1.69, 2009-11-07 07:57:09+00:00, davehart@shiny.ad.hartbrothers.com +10 -16 + ntpq, ntpdc, ntpdate use OpenSSL and need applink on Windows + + ntpdc/ntpdc.c@1.71, 2009-11-07 07:57:09+00:00, davehart@shiny.ad.hartbrothers.com +6 -11 + ntpq, ntpdc, ntpdate use OpenSSL and need applink on Windows + + ntpq/Makefile.am@1.38, 2009-11-07 07:57:09+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + add rule to build libntp.a + + ntpq/ntpq.c@1.95, 2009-11-07 07:57:10+00:00, davehart@shiny.ad.hartbrothers.com +77 -78 + ntpq, ntpdc, ntpdate use OpenSSL and need applink on Windows + + ports/winnt/ntpd/ntservice.c@1.22, 2009-11-07 07:57:10+00:00, davehart@shiny.ad.hartbrothers.com +3 -39 + ntpq, ntpdc, ntpdate use OpenSSL and need applink on Windows + + ports/winnt/vc6/libntp.dsp@1.46.1.1, 2009-11-07 07:57:10+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add ssl_init.c + + ports/winnt/vs2003/libntp.vcproj@1.5.1.1, 2009-11-07 07:57:10+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add ssl_init.c + + ports/winnt/vs2005/libntp.vcproj@1.5.1.1, 2009-11-07 07:57:10+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add ssl_init.c + + ports/winnt/vs2008/libntp/libntp.vcproj@1.22.1.1, 2009-11-07 07:57:10+00:00, davehart@shiny.ad.hartbrothers.com +6 -2 + add ssl_init.c + + sntp/Makefile.am@1.13.2.1, 2009-11-07 07:57:10+00:00, davehart@shiny.ad.hartbrothers.com +9 -1 + remove reference to bk rm'd netutils.h + add rule to build libntp.a + add rule to build COPYRIGHT with zero-byte version bk rm'd + + util/ntp-keygen.c@1.60, 2009-11-07 07:57:10+00:00, davehart@shiny.ad.hartbrothers.com +7 -23 + Use common OpenSSL initialization from libntp + ntpq, ntpdc, ntpdate use OpenSSL and need applink on Windows + +ChangeSet@1.2060.8.18, 2009-11-07 01:15:29-05:00, stenn@whimsy.udel.edu +2 -0 + authopt.html update from Dave Mills + + ChangeLog@1.524, 2009-11-07 01:15:17-05:00, stenn@whimsy.udel.edu +1 -0 + authopt.html update from Dave Mills + + html/authopt.html@1.56, 2009-11-07 01:15:19-05:00, stenn@whimsy.udel.edu +59 -29 + authopt.html update from Dave Mills + +ChangeSet@1.2060.8.17, 2009-11-07 01:09:12-05:00, stenn@whimsy.udel.edu +5 -0 + Remove unused file from the sntp/Makefile.am + + ChangeLog@1.523, 2009-11-07 01:08:57-05:00, stenn@whimsy.udel.edu +1 -0 + Remove unused file from the sntp/Makefile.am + + ChangeLog@1.522, 2009-11-07 01:02:47-05:00, stenn@whimsy.udel.edu +1 -0 + new crypto signature cleanup + + libntp/a_md5encrypt.c@1.23, 2009-11-07 01:00:55-05:00, stenn@whimsy.udel.edu +23 -23 + new crypto signature cleanup + + libntp/authkeys.c@1.17, 2009-11-07 01:00:56-05:00, stenn@whimsy.udel.edu +54 -13 + new crypto signature cleanup + + libntp/authreadkeys.c@1.10, 2009-11-07 01:00:57-05:00, stenn@whimsy.udel.edu +31 -22 + new crypto signature cleanup + + sntp/Makefile.am@1.13.1.2, 2009-11-07 01:06:55-05:00, stenn@whimsy.udel.edu +0 -1 + Remove unused file from the sntp/Makefile.am + +ChangeSet@1.2060.8.16, 2009-11-05 04:05:18-05:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P240_RC + TAG: NTP_4_2_5P240_RC + + ChangeLog@1.521, 2009-11-05 04:04:46-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P240_RC + + ntpd/ntpd-opts.c@1.234, 2009-11-05 04:04:49-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P240_RC + + ntpd/ntpd-opts.h@1.234, 2009-11-05 04:04:49-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P240_RC + + ntpd/ntpd-opts.texi@1.232, 2009-11-05 04:04:51-05:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P240_RC + + ntpd/ntpd.1@1.232, 2009-11-05 04:04:52-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P240_RC + + ntpdc/ntpdc-opts.c@1.230, 2009-11-05 04:04:53-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P240_RC + + ntpdc/ntpdc-opts.h@1.230, 2009-11-05 04:04:53-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P240_RC + + ntpdc/ntpdc-opts.texi@1.229, 2009-11-05 04:04:54-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P240_RC + + ntpdc/ntpdc.1@1.229, 2009-11-05 04:04:55-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P240_RC + + ntpq/ntpq-opts.c@1.231, 2009-11-05 04:04:56-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P240_RC + + ntpq/ntpq-opts.h@1.231, 2009-11-05 04:04:57-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P240_RC + + ntpq/ntpq-opts.texi@1.230, 2009-11-05 04:04:57-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P240_RC + + ntpq/ntpq.1@1.230, 2009-11-05 04:04:58-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P240_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.109, 2009-11-05 04:04:59-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P240_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.109, 2009-11-05 04:05:00-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P240_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.109, 2009-11-05 04:05:01-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P240_RC + + ntpsnmpd/ntpsnmpd.1@1.109, 2009-11-05 04:05:01-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P240_RC + + packageinfo.sh@1.244, 2009-11-05 04:05:02-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P240_RC + + sntp/sntp-opts.c@1.103, 2009-11-05 04:05:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P240_RC + + sntp/sntp-opts.h@1.103, 2009-11-05 04:05:04-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P240_RC + + sntp/sntp-opts.texi@1.103, 2009-11-05 04:05:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P240_RC + + sntp/sntp.1@1.103, 2009-11-05 04:05:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P240_RC + + util/ntp-keygen-opts.c@1.233, 2009-11-05 04:05:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P240_RC + + util/ntp-keygen-opts.h@1.233, 2009-11-05 04:05:08-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P240_RC + + util/ntp-keygen-opts.texi@1.232, 2009-11-05 04:05:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P240_RC + + util/ntp-keygen.1@1.232, 2009-11-05 04:05:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P240_RC + +ChangeSet@1.2060.13.2, 2009-11-05 02:04:25-05:00, stenn@whimsy.udel.edu +5 -0 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS 140-2) + + ChangeLog@1.517.1.2, 2009-11-05 02:03:36-05:00, stenn@whimsy.udel.edu +1 -1 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS 140-2) + + html/authopt.html@1.55, 2009-11-05 02:03:10-05:00, stenn@whimsy.udel.edu +20 -17 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS 140-2) + + html/keygen.html@1.16, 2009-11-05 02:03:15-05:00, stenn@whimsy.udel.edu +33 -9 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS 140-2) + + libntp/a_md5encrypt.c@1.20.1.1, 2009-11-05 02:02:46-05:00, stenn@whimsy.udel.edu +2 -2 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS 140-2) + + libntp/authkeys.c@1.16, 2009-11-05 02:02:47-05:00, stenn@whimsy.udel.edu +1 -2 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS 140-2) + +ChangeSet@1.2060.8.14, 2009-11-05 01:33:53+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + remove leftover RSAREF tidbit global.h no longer used + + BitKeeper/deleted/.del-global.h~3aed0663@1.5, 2009-11-05 01:33:16+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Delete: include/global.h + + include/Makefile.am@1.35.2.1, 2009-11-05 01:33:52+00:00, davehart@shiny.ad.hartbrothers.com +0 -1 + remove leftover RSAREF tidbit global.h no longer used + +ChangeSet@1.2060.8.13, 2009-11-05 00:24:26+00:00, davehart@shiny.ad.hartbrothers.com +18 -0 + remove testing leftover #undef OPENSSL + warning cleanup + linking with libntp now requires -lcrypto / libeay32.lib + + + include/ntp_stdlib.h@1.37, 2009-11-05 00:24:25+00:00, davehart@shiny.ad.hartbrothers.com +8 -0 + #define NID_md5 when not building with OpenSSL + + libntp/a_md5encrypt.c@1.21, 2009-11-05 00:24:25+00:00, davehart@shiny.ad.hartbrothers.com +22 -28 + remove testing leftover #undef OPENSSL + warning cleanup + assert rather than crash if openssl isn't working + + libntp/authreadkeys.c@1.9, 2009-11-05 00:24:25+00:00, davehart@shiny.ad.hartbrothers.com +6 -6 + remove testing leftover #undef OPENSSL + warning cleanup + + ntpdate/Makefile.am@1.20, 2009-11-05 00:24:25+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + add -lcrypto to ntpdate_LDADD now that libntp references openssl + + ntpdc/Makefile.am@1.44, 2009-11-05 00:24:25+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + linking with libntp now requires -lcrypto + + ntpq/Makefile.am@1.37, 2009-11-05 00:24:25+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + linking with libntp now requires -lcrypto + + ports/winnt/vc6/ntpdate.dsp@1.25, 2009-11-05 00:24:25+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + + ports/winnt/vc6/ntpdc.dsp@1.28, 2009-11-05 00:24:25+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + + ports/winnt/vc6/ntpq.dsp@1.29, 2009-11-05 00:24:25+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + + ports/winnt/vs2003/ntpdate.vcproj@1.4, 2009-11-05 00:24:25+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + + ports/winnt/vs2003/ntpdc.vcproj@1.4, 2009-11-05 00:24:25+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + + ports/winnt/vs2003/ntpq.vcproj@1.4, 2009-11-05 00:24:25+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + + ports/winnt/vs2005/ntpdate.vcproj@1.4, 2009-11-05 00:24:25+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + + ports/winnt/vs2005/ntpdc.vcproj@1.4, 2009-11-05 00:24:25+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + + ports/winnt/vs2005/ntpq.vcproj@1.4, 2009-11-05 00:24:25+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + + ports/winnt/vs2008/ntpdate/ntpdate.vcproj@1.11, 2009-11-05 00:24:25+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + + ports/winnt/vs2008/ntpdc/ntpdc.vcproj@1.11, 2009-11-05 00:24:25+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + + ports/winnt/vs2008/ntpq/ntpq.vcproj@1.10, 2009-11-05 00:24:25+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + +ChangeSet@1.2060.13.1, 2009-11-04 14:53:24-05:00, stenn@whimsy.udel.edu +22 -0 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + ChangeLog@1.517.1.1, 2009-11-04 14:47:42-05:00, stenn@whimsy.udel.edu +1 -0 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + html/authopt.html@1.54, 2009-11-04 14:48:01-05:00, stenn@whimsy.udel.edu +32 -3 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + html/ntpq.html@1.36, 2009-11-04 14:48:07-05:00, stenn@whimsy.udel.edu +12 -4 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + include/ntp.h@1.166, 2009-11-04 14:49:05-05:00, stenn@whimsy.udel.edu +4 -4 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + include/ntp_control.h@1.38, 2009-11-04 14:49:08-05:00, stenn@whimsy.udel.edu +5 -4 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + include/ntp_crypto.h@1.46, 2009-11-04 14:49:08-05:00, stenn@whimsy.udel.edu +2 -0 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + include/ntp_request.h@1.36, 2009-11-04 14:49:12-05:00, stenn@whimsy.udel.edu +2 -2 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + include/ntp_stdlib.h@1.36, 2009-11-04 14:49:13-05:00, stenn@whimsy.udel.edu +3 -3 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + libntp/a_md5encrypt.c@1.20, 2009-11-04 14:49:23-05:00, stenn@whimsy.udel.edu +63 -21 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + libntp/authkeys.c@1.15, 2009-11-04 14:49:25-05:00, stenn@whimsy.udel.edu +13 -17 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + libntp/authreadkeys.c@1.8, 2009-11-04 14:49:26-05:00, stenn@whimsy.udel.edu +50 -38 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + libntp/authusekey.c@1.7, 2009-11-04 14:49:26-05:00, stenn@whimsy.udel.edu +1 -13 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + ntpd/keyword-gen.c@1.1.1.2, 2009-11-04 14:49:54-05:00, stenn@whimsy.udel.edu +1 -0 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + ntpd/ntp_config.c@1.233, 2009-11-04 14:49:55-05:00, stenn@whimsy.udel.edu +8 -18 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + ntpd/ntp_control.c@1.128, 2009-11-04 14:49:57-05:00, stenn@whimsy.udel.edu +17 -7 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + ntpd/ntp_crypto.c@1.144, 2009-11-04 14:49:58-05:00, stenn@whimsy.udel.edu +17 -3 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + ntpd/ntp_keyword.h@1.1.1.1, 2009-11-04 14:50:01-05:00, stenn@whimsy.udel.edu +737 -732 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + ntpd/ntp_parser.c@1.52, 2009-11-04 14:50:02-05:00, stenn@whimsy.udel.edu +1031 -1013 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + ntpd/ntp_parser.h@1.32, 2009-11-04 14:50:09-05:00, stenn@whimsy.udel.edu +277 -275 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + ntpd/ntp_parser.y@1.47, 2009-11-04 14:50:10-05:00, stenn@whimsy.udel.edu +3 -0 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + ntpd/ntp_proto.c@1.297, 2009-11-04 14:50:11-05:00, stenn@whimsy.udel.edu +13 -18 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + sntp/crypto.h@1.5.1.1, 2009-11-04 14:50:29-05:00, stenn@whimsy.udel.edu +1 -0 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + +ChangeSet@1.2060.8.11, 2009-11-02 19:31:57+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + correct linuxcaps AC_MSG_RESULT() to occur after considering + --enable-linuxcaps + + configure.ac@1.459.2.2, 2009-11-02 19:31:56+00:00, davehart@shiny.ad.hartbrothers.com +1 -4 + correct linuxcaps AC_MSG_RESULT() to occur after considering + --enable-linuxcaps + +ChangeSet@1.2060.12.1, 2009-11-02 06:08:22+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1364] clock_gettime() not detected, need -lrt on Debian 5.0.3. + + ChangeLog@1.518, 2009-11-02 06:08:21+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1364] clock_gettime() not detected, need -lrt on Debian 5.0.3. + + configure.ac@1.459.2.1, 2009-11-02 06:08:21+00:00, davehart@shiny.ad.hartbrothers.com +4 -2 + [Bug 1364] clock_gettime() not detected, need -lrt on Debian 5.0.3. + bump cache version so previous results not finding clock_gettime() will + be tossed. + +ChangeSet@1.2060.8.9, 2009-10-31 06:38:39+09:00, Amidamaru@yumi.mxiesoft.com +13 -0 + .del-netutils.c~1f7e234e73bebdf5: + Delete: sntp/netutils.c + .del-COPYRIGHT~cdd0795ee52aa7b5: + Delete: sntp/COPYRIGHT + .del-netutils.h~b347f6069a2cfce1: + Delete: sntp/netutils.h + Many files: + Removed copyright statement + + BitKeeper/deleted/.del-COPYRIGHT~cdd0795ee52aa7b5@1.3, 2009-10-31 06:28:24+09:00, Amidamaru@yumi.mxiesoft.com +0 -0 + Delete: sntp/COPYRIGHT + + BitKeeper/deleted/.del-netutils.c~1f7e234e73bebdf5@1.4, 2009-10-31 06:36:45+09:00, Amidamaru@yumi.mxiesoft.com +0 -0 + Delete: sntp/netutils.c + + BitKeeper/deleted/.del-netutils.h~b347f6069a2cfce1@1.3, 2009-10-31 06:36:47+09:00, Amidamaru@yumi.mxiesoft.com +0 -0 + Delete: sntp/netutils.h + + sntp/crypto.c@1.10, 2009-10-31 06:37:30+09:00, Amidamaru@yumi.mxiesoft.com +0 -17 + Removed copyright statement + + sntp/crypto.h@1.6, 2009-10-31 06:37:54+09:00, Amidamaru@yumi.mxiesoft.com +0 -17 + Removed copyright statement + + sntp/kod_management.c@1.14, 2009-10-31 06:38:01+09:00, Amidamaru@yumi.mxiesoft.com +0 -18 + Removed copyright statement + + sntp/kod_management.h@1.8, 2009-10-31 06:38:05+09:00, Amidamaru@yumi.mxiesoft.com +0 -17 + Removed copyright statement + + sntp/log.c@1.10, 2009-10-31 06:38:07+09:00, Amidamaru@yumi.mxiesoft.com +0 -17 + Removed copyright statement + + sntp/log.h@1.7, 2009-10-31 06:38:10+09:00, Amidamaru@yumi.mxiesoft.com +0 -17 + Removed copyright statement + + sntp/networking.c@1.27, 2009-10-31 06:38:12+09:00, Amidamaru@yumi.mxiesoft.com +0 -17 + Removed copyright statement + + sntp/networking.h@1.16, 2009-10-31 06:38:13+09:00, Amidamaru@yumi.mxiesoft.com +0 -17 + Removed copyright statement + + sntp/utilities.c@1.10, 2009-10-31 06:38:15+09:00, Amidamaru@yumi.mxiesoft.com +0 -17 + Removed copyright statement + + sntp/utilities.h@1.8, 2009-10-31 06:38:18+09:00, Amidamaru@yumi.mxiesoft.com +0 -34 + Removed copyright statement + +ChangeSet@1.2060.8.8, 2009-10-30 01:30:30-05:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P239_RC + TAG: NTP_4_2_5P239_RC + + ChangeLog@1.517, 2009-10-30 01:30:03-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P239_RC + + ntpd/ntpd-opts.c@1.233, 2009-10-30 01:30:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P239_RC + + ntpd/ntpd-opts.h@1.233, 2009-10-30 01:30:07-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P239_RC + + ntpd/ntpd-opts.texi@1.231, 2009-10-30 01:30:08-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P239_RC + + ntpd/ntpd.1@1.231, 2009-10-30 01:30:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P239_RC + + ntpdc/ntpdc-opts.c@1.229, 2009-10-30 01:30:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P239_RC + + ntpdc/ntpdc-opts.h@1.229, 2009-10-30 01:30:10-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P239_RC + + ntpdc/ntpdc-opts.texi@1.228, 2009-10-30 01:30:12-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P239_RC + + ntpdc/ntpdc.1@1.228, 2009-10-30 01:30:12-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P239_RC + + ntpq/ntpq-opts.c@1.230, 2009-10-30 01:30:13-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P239_RC + + ntpq/ntpq-opts.h@1.230, 2009-10-30 01:30:14-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P239_RC + + ntpq/ntpq-opts.texi@1.229, 2009-10-30 01:30:15-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P239_RC + + ntpq/ntpq.1@1.229, 2009-10-30 01:30:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P239_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.108, 2009-10-30 01:30:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P239_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.108, 2009-10-30 01:30:17-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P239_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.108, 2009-10-30 01:30:18-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P239_RC + + ntpsnmpd/ntpsnmpd.1@1.108, 2009-10-30 01:30:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P239_RC + + packageinfo.sh@1.243, 2009-10-30 01:30:20-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P239_RC + + sntp/sntp-opts.c@1.102, 2009-10-30 01:30:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P239_RC + + sntp/sntp-opts.h@1.102, 2009-10-30 01:30:21-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P239_RC + + sntp/sntp-opts.texi@1.102, 2009-10-30 01:30:22-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P239_RC + + sntp/sntp.1@1.102, 2009-10-30 01:30:22-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P239_RC + + util/ntp-keygen-opts.c@1.232, 2009-10-30 01:30:23-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P239_RC + + util/ntp-keygen-opts.h@1.232, 2009-10-30 01:30:24-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P239_RC + + util/ntp-keygen-opts.texi@1.231, 2009-10-30 01:30:24-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P239_RC + + util/ntp-keygen.1@1.231, 2009-10-30 01:30:25-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P239_RC + +ChangeSet@1.2060.11.1, 2009-10-29 02:55:07-05:00, stenn@whimsy.udel.edu +3 -0 + CID 101 and Bug 1359 + + ChangeLog@1.514.1.2, 2009-10-29 02:54:35-05:00, stenn@whimsy.udel.edu +1 -0 + CID 101: more pointer/array cleanup + + ChangeLog@1.514.1.1, 2009-10-29 02:53:28-05:00, stenn@whimsy.udel.edu +1 -0 + CID 101: more pointer/array cleanup + + ntpd/ntp_crypto.c@1.143, 2009-10-29 02:53:30-05:00, stenn@whimsy.udel.edu +2 -1 + CID 101: more pointer/array cleanup + + ntpd/ntp_loopfilter.c@1.152, 2009-10-29 02:54:37-05:00, stenn@whimsy.udel.edu +2 -1 + CID 101: more pointer/array cleanup + +ChangeSet@1.2060.8.6, 2009-10-28 15:49:51-04:00, murray@pogo.udel.edu +1 -0 + ChangeLog: + Bug-1357: bogus assert in refclock_shm + + ChangeLog@1.515, 2009-10-28 15:49:00-04:00, murray@pogo.udel.edu +1 -0 + Bug-1357: bogus assert in refclock_shm + +ChangeSet@1.2060.8.5, 2009-10-28 13:32:36-04:00, murray@pogo.udel.edu +1 -0 + refclock_shm.c: + Fix for bug-1357: bogus assert in refclock_shm + + ntpd/refclock_shm.c@1.19, 2009-10-28 13:31:53-04:00, murray@pogo.udel.edu +4 -1 + Fix for bug-1357: bogus assert in refclock_shm + +ChangeSet@1.2060.9.2, 2009-10-28 09:19:39+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + networking.c: + 2nd half of [Bug 1158] in recv_bcast_data() + + sntp/networking.c@1.26, 2009-10-28 09:19:33+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + 2nd half of [Bug 1158] in recv_bcast_data() + +ChangeSet@1.2060.10.1, 2009-10-28 03:47:47-05:00, stenn@whimsy.udel.edu +2 -0 + CID 101: pointer/array cleanup + + ChangeLog@1.511.2.1, 2009-10-28 03:46:53-05:00, stenn@whimsy.udel.edu +1 -0 + CID 101: pointer/array cleanup + + ntpd/ntp_crypto.c@1.142, 2009-10-28 03:46:55-05:00, stenn@whimsy.udel.edu +10 -10 + CID 101: pointer/array cleanup + +ChangeSet@1.2060.9.1, 2009-10-28 07:35:54+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + [Bug 1358] AIX 4.3 sntp/networking.c IPV6_JOIN_GROUP undeclared. + + ChangeLog@1.511.1.1, 2009-10-28 07:35:53+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1358] AIX 4.3 sntp/networking.c IPV6_JOIN_GROUP undeclared. + + include/ntp_rfc2553.h@1.33, 2009-10-28 07:35:53+00:00, davehart@shiny.ad.hartbrothers.com +17 -2 + conditionalize definition of AI_ flags on AI_PASSIVE instead of + AI_NUMERICHOST, as the latter isn't defined on AIX 4.3 while + AI_PASSIVE is. + provide a 0 definition for AI_NUMERICHOST for those platforms + that don't have that flag. + + ntpd/ntp_io.c@1.307.1.1, 2009-10-28 07:35:53+00:00, davehart@shiny.ad.hartbrothers.com +0 -14 + move INCLUDE_IPV6_SUPPORT and INCLUDE_IPV6_MULTICAST_SUPPORT + definitions to ntp_rfc2553.h to share with sntp + + sntp/networking.c@1.25, 2009-10-28 07:35:53+00:00, davehart@shiny.ad.hartbrothers.com +8 -3 + Compile on systems such as AIX 4.3 with IPv6 but without IPv6 multicast + support via setsockopt(), + [Bug 1358] AIX 4.3 sntp/networking.c IPV6_JOIN_GROUP undeclared. + + sntp/networking.h@1.15, 2009-10-28 07:35:53+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + pick up INCLUDE_IPV6_MULTICAST_SUPPORT from ntp_rfc2553.h + +ChangeSet@1.2060.8.1, 2009-10-28 03:42:47+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1356] core dump from refclock_nmea when can't open /dev/gpsU. + + ChangeLog@1.512, 2009-10-28 03:42:45+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1356] core dump from refclock_nmea when can't open /dev/gpsU. + + ntpd/refclock_nmea.c@1.46, 2009-10-28 03:42:45+00:00, davehart@shiny.ad.hartbrothers.com +17 -8 + [Bug 1356] core dump from refclock_nmea when can't open /dev/gpsU. + +ChangeSet@1.2060.1.22, 2009-10-27 21:53:59+00:00, davehart@shiny.ad.hartbrothers.com +12 -0 + stub out isc/mem.c using NTP-local /include/isc/mem.h (leaving + /lib/isc/include/isc/mem.h untouched). + + configure.ac@1.459.1.6, 2009-10-27 21:53:57+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + add reference to include/isc/Makefile + + include/Makefile.am@1.35.1.2, 2009-10-27 21:53:57+00:00, davehart@shiny.ad.hartbrothers.com +3 -2 + add reference to include/isc/Makefile.am + + include/isc/Makefile.am@1.1, 2009-10-27 21:53:49+00:00, davehart@shiny.ad.hartbrothers.com +7 -0 + Override isc/mem.h for NTP to stub it out and save ~50KB + + include/isc/Makefile.am@1.0, 2009-10-27 21:53:49+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + include/isc/mem.h@1.1, 2009-10-27 21:53:51+00:00, davehart@shiny.ad.hartbrothers.com +54 -0 + Override isc/mem.h for NTP to stub it out and save ~50KB + + include/isc/mem.h@1.0, 2009-10-27 21:53:51+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + libntp/Makefile.am@1.48, 2009-10-27 21:53:57+00:00, davehart@shiny.ad.hartbrothers.com +0 -1 + mem.c is stubbed out + + libntp/emalloc.c@1.10, 2009-10-27 21:53:57+00:00, davehart@shiny.ad.hartbrothers.com +3 -2 + implement GNU malloc behavior in emalloc() and erealloc(), libisc mem.h + stubs depend on it (could be implemented in mem.h, but other code may + grow a dependency being tested only on GNU malloc, so play it safe.) + + ntpd/ntp_io.c@1.308, 2009-10-27 21:53:58+00:00, davehart@shiny.ad.hartbrothers.com +1 -37 + remove ntp_memalloc(), ntp_memfree(), pass dummy non-null mctx + to to libisc interface iterator. + + ports/winnt/vc6/libntp.dsp@1.47, 2009-10-27 21:53:58+00:00, davehart@shiny.ad.hartbrothers.com +0 -4 + lib/isc/mem.c is no longer compiled + + ports/winnt/vs2003/libntp.vcproj@1.6, 2009-10-27 21:53:58+00:00, davehart@shiny.ad.hartbrothers.com +1 -4 + remove change mem.h reference to NTP override copy in include/isc + lib/isc/mem.c is no longer compiled. + + ports/winnt/vs2005/libntp.vcproj@1.6, 2009-10-27 21:53:58+00:00, davehart@shiny.ad.hartbrothers.com +1 -5 + remove change mem.h reference to NTP override copy in include/isc + lib/isc/mem.c is no longer compiled. + + ports/winnt/vs2008/libntp/libntp.vcproj@1.23, 2009-10-27 21:53:58+00:00, davehart@shiny.ad.hartbrothers.com +1 -5 + remove change mem.h reference to NTP override copy in include/isc + lib/isc/mem.c is no longer compiled. + + util/ntptime.c@1.21, 2009-10-27 21:53:58+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + add "int debug;" global for libntp consumption + +ChangeSet@1.2060.1.21, 2009-10-27 05:47:37-05:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P238_RC + TAG: NTP_4_2_5P238_RC + + ChangeLog@1.511, 2009-10-27 05:47:06-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P238_RC + + ntpd/ntpd-opts.c@1.232, 2009-10-27 05:47:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P238_RC + + ntpd/ntpd-opts.h@1.232, 2009-10-27 05:47:10-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P238_RC + + ntpd/ntpd-opts.texi@1.230, 2009-10-27 05:47:11-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P238_RC + + ntpd/ntpd.1@1.230, 2009-10-27 05:47:13-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P238_RC + + ntpdc/ntpdc-opts.c@1.228, 2009-10-27 05:47:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P238_RC + + ntpdc/ntpdc-opts.h@1.228, 2009-10-27 05:47:15-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P238_RC + + ntpdc/ntpdc-opts.texi@1.227, 2009-10-27 05:47:15-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P238_RC + + ntpdc/ntpdc.1@1.227, 2009-10-27 05:47:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P238_RC + + ntpq/ntpq-opts.c@1.229, 2009-10-27 05:47:17-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P238_RC + + ntpq/ntpq-opts.h@1.229, 2009-10-27 05:47:18-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P238_RC + + ntpq/ntpq-opts.texi@1.228, 2009-10-27 05:47:20-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P238_RC + + ntpq/ntpq.1@1.228, 2009-10-27 05:47:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P238_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.107, 2009-10-27 05:47:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P238_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.107, 2009-10-27 05:47:23-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P238_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.107, 2009-10-27 05:47:24-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P238_RC + + ntpsnmpd/ntpsnmpd.1@1.107, 2009-10-27 05:47:25-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P238_RC + + packageinfo.sh@1.242, 2009-10-27 05:47:26-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P238_RC + + sntp/sntp-opts.c@1.101, 2009-10-27 05:47:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P238_RC + + sntp/sntp-opts.h@1.101, 2009-10-27 05:47:27-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P238_RC + + sntp/sntp-opts.texi@1.101, 2009-10-27 05:47:28-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P238_RC + + sntp/sntp.1@1.101, 2009-10-27 05:47:28-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P238_RC + + util/ntp-keygen-opts.c@1.231, 2009-10-27 05:47:29-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P238_RC + + util/ntp-keygen-opts.h@1.231, 2009-10-27 05:47:30-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P238_RC + + util/ntp-keygen-opts.texi@1.230, 2009-10-27 05:47:31-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P238_RC + + util/ntp-keygen.1@1.230, 2009-10-27 05:47:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P238_RC + +ChangeSet@1.2060.7.3, 2009-10-26 22:25:38-05:00, stenn@whimsy.udel.edu +3 -0 + Changes from Dave Mills + + ChangeLog@1.506.1.3, 2009-10-26 22:24:50-05:00, stenn@whimsy.udel.edu +1 -0 + Changes from Dave Mills + + ntpd/ntp_refclock.c@1.91, 2009-10-26 22:25:05-05:00, stenn@whimsy.udel.edu +1 -1 + Changes from Dave Mills + + ntpd/refclock_wwv.c@1.73, 2009-10-26 22:25:20-05:00, stenn@whimsy.udel.edu +0 -1 + Changes from Dave Mills + +ChangeSet@1.2060.7.2, 2009-10-26 22:20:49-05:00, stenn@whimsy.udel.edu +2 -0 + driver4.html updates from Dave Mills + + ChangeLog@1.506.1.2, 2009-10-26 22:20:29-05:00, stenn@whimsy.udel.edu +1 -0 + driver4.html updates from Dave Mills + + html/drivers/driver4.html@1.15, 2009-10-26 22:20:31-05:00, stenn@whimsy.udel.edu +2 -2 + driver4.html updates from Dave Mills + +ChangeSet@1.2060.7.1, 2009-10-26 22:16:02-05:00, stenn@whimsy.udel.edu +2 -0 + PPSAPI Cleanup of ntpd/refclock_wwvb.c + + ChangeLog@1.506.1.1, 2009-10-26 22:15:41-05:00, stenn@whimsy.udel.edu +1 -0 + PPSAPI Cleanup of ntpd/refclock_wwvb.c + + ntpd/refclock_wwvb.c@1.22, 2009-10-26 22:15:42-05:00, stenn@whimsy.udel.edu +73 -23 + PPSAPI Cleanup of ntpd/refclock_wwvb.c + +ChangeSet@1.2060.1.19, 2009-10-27 00:16:02+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + Get rid of configure tests for __ss_family and __ss_len when the more + common ss_family and ss_len are present. + + ChangeLog@1.509, 2009-10-27 00:16:01+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + Get rid of configure tests for __ss_family and __ss_len when the more + common ss_family and ss_len are present. + + configure.ac@1.459.1.5, 2009-10-27 00:16:01+00:00, davehart@shiny.ad.hartbrothers.com +175 -107 + Get rid of configure tests for __ss_family and __ss_len when the more + common ss_family and ss_len are present. + + sntp/configure.ac@1.24, 2009-10-27 00:16:01+00:00, davehart@shiny.ad.hartbrothers.com +141 -46 + Get rid of configure tests for __ss_family and __ss_len when the more + common ss_family and ss_len are present. + +ChangeSet@1.2060.1.18, 2009-10-26 20:49:30+00:00, davehart@shiny.ad.hartbrothers.com +8 -0 + CIDs 94-99 make it more clearly impossible for sock_hash() to return + a negative number. + CID 105, 106 ensure ntpdc arrays are not overrun even if callers + misbehave. + CID 113 use va_end() in refclock_true.c true_debug(). + + ChangeLog@1.508, 2009-10-26 20:49:28+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + CIDs 94-99 make it more clearly impossible for sock_hash() to return + a negative number. + CID 105, 106 ensure ntpdc arrays are not overrun even if callers + misbehave. + CID 113 use va_end() in refclock_true.c true_debug(). + + include/ntpd.h@1.135, 2009-10-26 20:49:28+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + CIDs 94-99 -- make it more clearly impossible for sock_hash to + return a negative number + + libntp/ntp_rfc2553.c@1.41, 2009-10-26 20:49:29+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + protect sys/socket.h inclusion with #ifdef HAVE_SYS_SOCKET_H + + ntpd/ntp_monitor.c@1.25, 2009-10-26 20:49:29+00:00, davehart@shiny.ad.hartbrothers.com +6 -6 + CIDs 94-99 -- make it more clearly impossible for sock_hash to + return a negative number + + ntpd/ntp_peer.c@1.123, 2009-10-26 20:49:29+00:00, davehart@shiny.ad.hartbrothers.com +9 -9 + CIDs 94-99 -- make it more clearly impossible for sock_hash to + return a negative number + + ntpd/ntp_util.c@1.75, 2009-10-26 20:49:29+00:00, davehart@shiny.ad.hartbrothers.com +15 -18 + CIDs 94-99 -- make it more clearly impossible for sock_hash to + return a negative number + + ntpd/refclock_true.c@1.11, 2009-10-26 20:49:29+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + CID 113 use va_end() + + ntpdc/ntpdc_ops.c@1.61, 2009-10-26 20:49:29+00:00, davehart@shiny.ad.hartbrothers.com +23 -14 + CID 105, 106 -- ensure array are not overrun even if callers + misbehave + +ChangeSet@1.2060.1.16, 2009-10-26 05:45:09-05:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P237_RC + TAG: NTP_4_2_5P237_RC + + ChangeLog@1.506, 2009-10-26 05:44:38-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P237_RC + + ntpd/ntpd-opts.c@1.231, 2009-10-26 05:44:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P237_RC + + ntpd/ntpd-opts.h@1.231, 2009-10-26 05:44:41-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P237_RC + + ntpd/ntpd-opts.texi@1.229, 2009-10-26 05:44:42-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P237_RC + + ntpd/ntpd.1@1.229, 2009-10-26 05:44:44-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P237_RC + + ntpdc/ntpdc-opts.c@1.227, 2009-10-26 05:44:45-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P237_RC + + ntpdc/ntpdc-opts.h@1.227, 2009-10-26 05:44:46-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P237_RC + + ntpdc/ntpdc-opts.texi@1.226, 2009-10-26 05:44:47-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P237_RC + + ntpdc/ntpdc.1@1.226, 2009-10-26 05:44:47-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P237_RC + + ntpq/ntpq-opts.c@1.228, 2009-10-26 05:44:49-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P237_RC + + ntpq/ntpq-opts.h@1.228, 2009-10-26 05:44:50-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P237_RC + + ntpq/ntpq-opts.texi@1.227, 2009-10-26 05:44:50-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P237_RC + + ntpq/ntpq.1@1.227, 2009-10-26 05:44:51-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P237_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.106, 2009-10-26 05:44:52-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P237_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.106, 2009-10-26 05:44:53-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P237_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.106, 2009-10-26 05:44:54-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P237_RC + + ntpsnmpd/ntpsnmpd.1@1.106, 2009-10-26 05:44:55-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P237_RC + + packageinfo.sh@1.241, 2009-10-26 05:44:55-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P237_RC + + sntp/sntp-opts.c@1.100, 2009-10-26 05:44:56-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P237_RC + + sntp/sntp-opts.h@1.100, 2009-10-26 05:44:57-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P237_RC + + sntp/sntp-opts.texi@1.100, 2009-10-26 05:44:58-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P237_RC + + sntp/sntp.1@1.100, 2009-10-26 05:44:59-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P237_RC + + util/ntp-keygen-opts.c@1.230, 2009-10-26 05:45:00-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P237_RC + + util/ntp-keygen-opts.h@1.230, 2009-10-26 05:45:01-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P237_RC + + util/ntp-keygen-opts.texi@1.229, 2009-10-26 05:45:02-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P237_RC + + util/ntp-keygen.1@1.229, 2009-10-26 05:45:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P237_RC + +ChangeSet@1.2060.6.1, 2009-10-25 11:25:16+00:00, davehart@shiny.ad.hartbrothers.com +32 -0 + [Bug 1355] ntp-dev won't compile on OpenBSD 4.6. + + BitKeeper/deleted/.del-in.h~29080509@1.4, 2009-10-25 11:22:17+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/include/netinet/in.h -> BitKeeper/deleted/.del-in.h~29080509 + + BitKeeper/deleted/.del-in_system.h~c86910dc@1.3, 2009-10-25 11:22:19+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/include/netinet/in_system.h -> BitKeeper/deleted/.del-in_system.h~c86910dc + + BitKeeper/deleted/.del-ip.h~eb192092@1.3, 2009-10-25 11:22:19+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/include/netinet/ip.h -> BitKeeper/deleted/.del-ip.h~eb192092 + + BitKeeper/deleted/.del-socket.h~29080509@1.4, 2009-10-25 11:22:18+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/include/sys/socket.h -> BitKeeper/deleted/.del-socket.h~29080509 + + ChangeLog@1.503.2.1, 2009-10-25 11:25:12+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1355] ntp-dev won't compile on OpenBSD 4.6. + + include/Makefile.am@1.35.1.1, 2009-10-25 11:25:12+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + move lib_strbuf.h from libntp to include + + include/l_stdlib.h@1.17, 2009-10-25 11:25:12+00:00, davehart@shiny.ad.hartbrothers.com +1 -4 + require sys/types.h + + include/lib_strbuf.h@1.6, 2009-10-25 11:22:18+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: libntp/lib_strbuf.h -> include/lib_strbuf.h + + include/ntp_io.h@1.13, 2009-10-25 11:25:12+00:00, davehart@shiny.ad.hartbrothers.com +1 -3 + require sys/types.h + + include/ntp_net.h@1.3, 2009-10-25 11:25:12+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + protect sys/socket.h, netinet/in.h inclusion with config.h macros + + include/ntp_stdlib.h@1.35, 2009-10-25 11:25:12+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + protect sys/socket.h inclusion with #ifdef HAVE_SYS_SOCKET_H + + include/ntp_types.h@1.14, 2009-10-25 11:25:12+00:00, davehart@shiny.ad.hartbrothers.com +4 -5 + stay out of system/compiler underscore namespace + + include/ntpsim.h@1.12, 2009-10-25 11:25:13+00:00, davehart@shiny.ad.hartbrothers.com +8 -7 + protect sys/socket.h inclusion with #ifdef HAVE_SYS_SOCKET_H + + libntp/Makefile.am@1.47, 2009-10-25 11:25:13+00:00, davehart@shiny.ad.hartbrothers.com +0 -2 + move lib_strbuf.h from libntp to include + + libntp/decodenetnum.c@1.10, 2009-10-25 11:25:13+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + include config.h + protect sys/socket.h, netinet/in.h inclusion with config.h macros + + libntp/inttoa.c@1.3, 2009-10-25 11:25:13+00:00, davehart@shiny.ad.hartbrothers.com +3 -2 + include config.h + use snprintf() in favor of sprintf() + + libntp/msyslog.c@1.24, 2009-10-25 11:25:13+00:00, davehart@shiny.ad.hartbrothers.com +1 -3 + require sys/types.h + + libntp/ntp_random.c@1.7, 2009-10-25 11:25:13+00:00, davehart@shiny.ad.hartbrothers.com +1 -3 + require sys/types.h + + libntp/numtoa.c@1.5, 2009-10-25 11:25:13+00:00, davehart@shiny.ad.hartbrothers.com +2 -3 + [Bug 1355] ntp-dev won't compile on OpenBSD 4.6. + protect netinet/in.h inclusion with HAVE_NETINET_IN_H + + libntp/numtohost.c@1.5, 2009-10-25 11:25:13+00:00, davehart@shiny.ad.hartbrothers.com +2 -4 + [Bug 1355] ntp-dev won't compile on OpenBSD 4.6. + protect netinet/in.h inclusion with HAVE_NETINET_IN_H + + libntp/socktoa.c@1.11, 2009-10-25 11:25:13+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + protect sys/socket.h, netinet/in.h inclusion with config.h macros + + libntp/socktohost.c@1.7, 2009-10-25 11:25:13+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + protect sys/socket.h, netinet/in.h inclusion with config.h macros + + ntpd/keyword-gen.c@1.1.1.1, 2009-10-25 11:25:13+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + [Bug 1355] ntp-dev won't compile on OpenBSD 4.6. + + ntpd/ntp_control.c@1.127, 2009-10-25 11:25:13+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + protect netinet/in.h inclusion with HAVE_NETINET_IN_H + + ntpd/ntp_intres.c@1.66, 2009-10-25 11:25:13+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + protect netinet/in.h inclusion with HAVE_NETINET_IN_H + + ntpd/ntp_request.c@1.80.1.2, 2009-10-25 11:25:13+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + protect netinet/in.h inclusion with HAVE_NETINET_IN_H + + ntpdc/ntpdc_ops.c@1.60, 2009-10-25 11:25:13+00:00, davehart@shiny.ad.hartbrothers.com +9 -4 + protect netinet/in.h inclusion with #ifdef HAVE_NETINET_IN_H. + stay within array bounds in clockstat() even if calling code + misbehaves. + + + ports/winnt/vc6/libntp.dsp@1.43.1.1, 2009-10-25 11:25:13+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + move lib_strbuf.h from libntp to include + + ports/winnt/vs2003/libntp.vcproj@1.5, 2009-10-25 11:25:13+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + move lib_strbuf.h from libntp to include + + ports/winnt/vs2005/libntp.vcproj@1.5, 2009-10-25 11:25:13+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + move lib_strbuf.h from libntp to include + + ports/winnt/vs2008/libntp/libntp.vcproj@1.22, 2009-10-25 11:25:14+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + move lib_strbuf.h from libntp to include + + util/ntp-keygen.c@1.59, 2009-10-25 11:25:14+00:00, davehart@shiny.ad.hartbrothers.com +1 -9 + require sys/types.h + remove old #ifdef SYS_WINNT related to ntp_getopt, ntp-keygen uses libopts + +ChangeSet@1.2060.5.1, 2009-10-25 03:06:29+00:00, davehart@shiny.ad.hartbrothers.com +17 -0 + [Bug 1354] libtool error building after bootstrap with Autoconf 2.64. + Allow NTP_VPATH_HACK configure test to handle newer gmake versions. + + BitKeeper/deleted/.del-ltmain.sh~1dcd783dfc596fc7@1.3, 2009-10-25 03:05:14+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: sntp/ltmain.sh -> BitKeeper/deleted/.del-ltmain.sh~1dcd783dfc596fc7 + + BitKeeper/deleted/.del-ltmain.sh~2b9d9fc0af8c0735@1.2, 2009-10-25 03:05:12+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ltmain.sh -> BitKeeper/deleted/.del-ltmain.sh~2b9d9fc0af8c0735 + + ChangeLog@1.503.1.1, 2009-10-25 03:06:27+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1354] libtool error building after bootstrap with Autoconf 2.64. + Allow NTP_VPATH_HACK configure test to handle newer gmake versions. + + Makefile.am@1.86.1.1, 2009-10-25 03:06:27+00:00, davehart@shiny.ad.hartbrothers.com +11 -3 + add rule to rebuild libtool if needed. + no need to use unix2dos on *.ds* after bk admin -fEOLN_WINDOWS + + configure.ac@1.459.1.4, 2009-10-25 03:06:27+00:00, davehart@shiny.ad.hartbrothers.com +3 -1 + use AC_CONFIG_MACRO_DIR() to keep m4 files in m4 + + m4/ntp_vpathhack.m4@1.2, 2009-10-25 03:06:27+00:00, davehart@shiny.ad.hartbrothers.com +23 -17 + NTP_VPATH_HACK was misfiring on FreeBSD with recent GNU Make due to + a change from "GNU Make version" to "GNU Make" as the gmake -v output. + Also do not cache the result, running make -v and grep is worth it to + allow changing make without flushing the cache. + + ports/winnt/vc6/Instsrv.dsp@1.11, 2009-10-25 03:05:15+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Turn on EOLN_WINDOWS flag + + ports/winnt/vc6/Instsrv.dsp@1.10, 2009-10-25 03:05:15+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Turn off EOLN_NATIVE flag + + ports/winnt/vc6/libntp.dsp@1.45, 2009-10-25 03:05:15+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Turn on EOLN_WINDOWS flag + + ports/winnt/vc6/libntp.dsp@1.44, 2009-10-25 03:05:15+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Turn off EOLN_NATIVE flag + + ports/winnt/vc6/ntp.dsw@1.11, 2009-10-25 03:05:15+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Turn on EOLN_WINDOWS flag + + ports/winnt/vc6/ntp.dsw@1.10, 2009-10-25 03:05:15+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Turn off EOLN_NATIVE flag + + ports/winnt/vc6/ntpd.dsp@1.41, 2009-10-25 03:05:15+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Turn on EOLN_WINDOWS flag + + ports/winnt/vc6/ntpd.dsp@1.40, 2009-10-25 03:05:15+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Turn off EOLN_NATIVE flag + + ports/winnt/vc6/ntpdate.dsp@1.24, 2009-10-25 03:05:13+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Turn on EOLN_WINDOWS flag + + ports/winnt/vc6/ntpdate.dsp@1.23, 2009-10-25 03:05:13+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Turn off EOLN_NATIVE flag + + ports/winnt/vc6/ntpdc.dsp@1.27, 2009-10-25 03:05:14+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Turn on EOLN_WINDOWS flag + + ports/winnt/vc6/ntpdc.dsp@1.26, 2009-10-25 03:05:14+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Turn off EOLN_NATIVE flag + + ports/winnt/vc6/ntpkeygen.dsp@1.20, 2009-10-25 03:05:14+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Turn on EOLN_WINDOWS flag + + ports/winnt/vc6/ntpkeygen.dsp@1.19, 2009-10-25 03:05:14+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Turn off EOLN_NATIVE flag + + ports/winnt/vc6/ntpq.dsp@1.28, 2009-10-25 03:05:13+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Turn on EOLN_WINDOWS flag + + ports/winnt/vc6/ntpq.dsp@1.27, 2009-10-25 03:05:13+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Turn off EOLN_NATIVE flag + + scripts/genCommitLog@1.5, 2009-10-25 03:06:27+00:00, davehart@shiny.ad.hartbrothers.com +9 -0 + crude workaround for read-only srcdir seen in make distcheck + + sntp/Makefile.am@1.13.1.1, 2009-10-25 03:06:27+00:00, davehart@shiny.ad.hartbrothers.com +13 -2 + add rule to rebuild libtool if needed + + sntp/configure.ac@1.23, 2009-10-25 03:06:27+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + use AC_CONFIG_MACRO_DIR() to keep m4 files in m4 + +ChangeSet@1.2060.1.14, 2009-10-24 05:55:49+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 610] NMEA support for using PPSAPI on a different device. + [Bug 1238] use only fudge time2 to offset NMEA serial timestamp. + + ChangeLog@1.504, 2009-10-24 05:55:49+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 610] NMEA support for using PPSAPI on a different device. + [Bug 1238] use only fudge time2 to offset NMEA serial timestamp. + + include/ntp_refclock.h@1.24, 2009-10-24 05:55:49+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + [Bug 1238] use only fudge time2 to offset NMEA serial timestamp. + + ntpd/ntp_refclock.c@1.90, 2009-10-24 05:55:49+00:00, davehart@shiny.ad.hartbrothers.com +15 -5 + [Bug 1238] use only fudge time2 to offset NMEA serial timestamp. + + ntpd/refclock_nmea.c@1.45, 2009-10-24 05:55:49+00:00, davehart@shiny.ad.hartbrothers.com +45 -13 + [Bug 610] NMEA support for using PPSAPI on a different device. + [Bug 1238] use only fudge time2 to offset NMEA serial timestamp. + +ChangeSet@1.2060.4.1, 2009-10-23 16:57:07+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + shrink 750 keyword scanner states from 64 to 32 bits apiece + + ntpd/keyword-gen.c@1.2, 2009-10-23 16:57:06+00:00, davehart@shiny.ad.hartbrothers.com +133 -18 + shrink 750 keyword scanner states from 64 to 32 bits apiece + + ntpd/ntp_keyword.h@1.2, 2009-10-23 16:57:06+00:00, davehart@shiny.ad.hartbrothers.com +741 -741 + shrink 750 keyword scanner states from 64 to 32 bits apiece + + ntpd/ntp_scanner.c@1.31, 2009-10-23 16:57:07+00:00, davehart@shiny.ad.hartbrothers.com +20 -16 + shrink 750 keyword scanner states from 64 to 32 bits apiece + + ntpd/ntp_scanner.h@1.14, 2009-10-23 16:57:07+00:00, davehart@shiny.ad.hartbrothers.com +37 -10 + shrink 750 keyword scanner states from 64 to 32 bits apiece + +ChangeSet@1.2060.1.13, 2009-10-22 06:47:25-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P236_RC + TAG: NTP_4_2_5P236_RC + + ChangeLog@1.503, 2009-10-22 06:46:59-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P236_RC + + ntpd/ntpd-opts.c@1.230, 2009-10-22 06:47:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P236_RC + + ntpd/ntpd-opts.h@1.230, 2009-10-22 06:47:01-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P236_RC + + ntpd/ntpd-opts.texi@1.228, 2009-10-22 06:47:02-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P236_RC + + ntpd/ntpd.1@1.228, 2009-10-22 06:47:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P236_RC + + ntpdc/ntpdc-opts.c@1.226, 2009-10-22 06:47:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P236_RC + + ntpdc/ntpdc-opts.h@1.226, 2009-10-22 06:47:05-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P236_RC + + ntpdc/ntpdc-opts.texi@1.225, 2009-10-22 06:47:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P236_RC + + ntpdc/ntpdc.1@1.225, 2009-10-22 06:47:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P236_RC + + ntpq/ntpq-opts.c@1.227, 2009-10-22 06:47:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P236_RC + + ntpq/ntpq-opts.h@1.227, 2009-10-22 06:47:09-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P236_RC + + ntpq/ntpq-opts.texi@1.226, 2009-10-22 06:47:10-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P236_RC + + ntpq/ntpq.1@1.226, 2009-10-22 06:47:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P236_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.105, 2009-10-22 06:47:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P236_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.105, 2009-10-22 06:47:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P236_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.105, 2009-10-22 06:47:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P236_RC + + ntpsnmpd/ntpsnmpd.1@1.105, 2009-10-22 06:47:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P236_RC + + packageinfo.sh@1.240, 2009-10-22 06:47:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P236_RC + + sntp/sntp-opts.c@1.99, 2009-10-22 06:47:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P236_RC + + sntp/sntp-opts.h@1.99, 2009-10-22 06:47:15-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P236_RC + + sntp/sntp-opts.texi@1.99, 2009-10-22 06:47:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P236_RC + + sntp/sntp.1@1.99, 2009-10-22 06:47:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P236_RC + + util/ntp-keygen-opts.c@1.229, 2009-10-22 06:47:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P236_RC + + util/ntp-keygen-opts.h@1.229, 2009-10-22 06:47:18-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P236_RC + + util/ntp-keygen-opts.texi@1.228, 2009-10-22 06:47:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P236_RC + + util/ntp-keygen.1@1.228, 2009-10-22 06:47:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P236_RC + +ChangeSet@1.2060.1.12, 2009-10-22 05:02:37-04:00, stenn@whimsy.udel.edu +4 -0 + Cleanup from Dave Mills + + ChangeLog@1.502, 2009-10-22 05:02:25-04:00, stenn@whimsy.udel.edu +1 -0 + Cleanup from Dave Mills + + html/authopt.html@1.53, 2009-10-22 05:01:02-04:00, stenn@whimsy.udel.edu +42 -9 + Cleanup from Dave Mills + + html/ntpq.html@1.35, 2009-10-22 05:01:09-04:00, stenn@whimsy.udel.edu +10 -9 + Cleanup from Dave Mills + + ntpd/ntp_loopfilter.c@1.151, 2009-10-22 05:00:41-04:00, stenn@whimsy.udel.edu +4 -5 + Cleanup from Dave Mills + +ChangeSet@1.2060.3.1, 2009-10-21 21:59:17+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + [Bug 1353] ntpq "rv 0 settimeofday" always shows UNKNOWN on unix. + + ChangeLog@1.498.1.1, 2009-10-21 21:59:16+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1353] ntpq "rv 0 settimeofday" always shows UNKNOWN on unix. + + include/ntp_stdlib.h@1.34, 2009-10-21 21:59:16+00:00, davehart@shiny.ad.hartbrothers.com +7 -1 + [Bug 1353] ntpq "rv 0 settimeofday" always shows UNKNOWN on unix. + + libntp/machines.c@1.21, 2009-10-21 21:59:16+00:00, davehart@shiny.ad.hartbrothers.com +49 -16 + [Bug 1353] ntpq "rv 0 settimeofday" always shows UNKNOWN on unix. + + ntpd/ntp_config.c@1.232, 2009-10-21 21:59:16+00:00, davehart@shiny.ad.hartbrothers.com +25 -4 + [Bug 1353] ntpq "rv 0 settimeofday" always shows UNKNOWN on unix. + + ports/winnt/libntp/SetSystemTime.c@1.7, 2009-10-21 21:59:16+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + [Bug 1353] ntpq "rv 0 settimeofday" always shows UNKNOWN on unix. + + ports/winnt/ntpd/nt_clockstuff.c@1.37, 2009-10-21 21:59:16+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + [Bug 1353] ntpq "rv 0 settimeofday" always shows UNKNOWN on unix. + +ChangeSet@1.2060.1.10, 2009-10-21 15:38:30+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + configure.ac: + AC_FUNC_MALLOC is unneeded, breaks cross-compile with uClibc with + undefined references to rpl_malloc + + sntp/configure.ac@1.22, 2009-10-21 15:38:18+00:00, davehart@shiny.ad.hartbrothers.com +0 -1 + AC_FUNC_MALLOC is unneeded, breaks cross-compile with uClibc with + undefined references to rpl_malloc + +ChangeSet@1.2060.1.9, 2009-10-21 04:27:03+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + configure.ac: + correct sa_len test butchered recently + + configure.ac@1.459.1.3, 2009-10-21 04:26:54+00:00, davehart@shiny.ad.hartbrothers.com +20 -2 + correct sa_len test butchered recently + +ChangeSet@1.2060.1.8, 2009-10-20 17:47:04+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + Do not attempt to execute built binaries from ntpd/Makefile when + cross-compiling (keyword-gen and ntpd --saveconfigquit). + sntp/main.c: Remove duplicate global adr_buf[] (also defined in + networking.c) which Piotr Grudzinski identified breaking his build. + Correct in6addr_any test in configure.ac to attempt link too. + + ChangeLog@1.500, 2009-10-20 17:47:03+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + Do not attempt to execute built binaries from ntpd/Makefile when + cross-compiling (keyword-gen and ntpd --saveconfigquit). + sntp/main.c: Remove duplicate global adr_buf[] (also defined in + networking.c) which Piotr Grudzinski identified breaking his build. + Correct in6addr_any test in configure.ac to attempt link too. + + configure.ac@1.459.1.2, 2009-10-20 17:47:03+00:00, davehart@shiny.ad.hartbrothers.com +8 -6 + Correct in6addr_any test in configure.ac to attempt link too. + Introduce NTP_CROSSCOMPILE automake conditional + + ntpd/Makefile.am@1.76, 2009-10-20 17:47:03+00:00, davehart@shiny.ad.hartbrothers.com +17 -3 + Use NTP_CROSSCOMPILE automake conditional to avoid attempting to execute + built binaries when cross-compiling (keyword-gen and ntpd --saveconfigquit) + + sntp/configure.ac@1.21, 2009-10-20 17:47:03+00:00, davehart@shiny.ad.hartbrothers.com +6 -5 + Correct in6addr_any test in configure.ac to attempt link too. + + sntp/main.c@1.20, 2009-10-20 17:47:03+00:00, davehart@shiny.ad.hartbrothers.com +9 -9 + sntp/main.c: Remove duplicate global adr_buf[] (also defined in + networking.c) which Piotr Grudzinski identified breaking his build. + +ChangeSet@1.2060.1.7, 2009-10-19 17:23:04+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1343] ntpd/ntp_io.c close_fd() does not compile on Solaris 7. + Also includes similar fix to sntp/crypto.c identified on same machine. + + ChangeLog@1.499, 2009-10-19 17:23:03+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1343] ntpd/ntp_io.c close_fd() does not compile on Solaris 7. + Also includes similar fix to sntp/crypto.c identified on same machine. + + ntpd/ntp_io.c@1.307, 2009-10-19 17:23:04+00:00, davehart@shiny.ad.hartbrothers.com +4 -2 + move code after local variable declaration in move_fd() to cure + compiling with compilers that know the difference between C and C++ + + sntp/crypto.c@1.9, 2009-10-19 17:23:04+00:00, davehart@shiny.ad.hartbrothers.com +44 -43 + move digest_data variable declaration ahead of code in auth_md5() for + compatibility with ANSI C. + +ChangeSet@1.2060.1.6, 2009-10-18 06:46:43-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P235_RC + TAG: NTP_4_2_5P235_RC + + ChangeLog@1.498, 2009-10-18 06:46:14-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P235_RC + + ntpd/ntpd-opts.c@1.229, 2009-10-18 06:46:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P235_RC + + ntpd/ntpd-opts.h@1.229, 2009-10-18 06:46:18-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P235_RC + + ntpd/ntpd-opts.texi@1.227, 2009-10-18 06:46:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P235_RC + + ntpd/ntpd.1@1.227, 2009-10-18 06:46:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P235_RC + + ntpdc/ntpdc-opts.c@1.225, 2009-10-18 06:46:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P235_RC + + ntpdc/ntpdc-opts.h@1.225, 2009-10-18 06:46:22-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P235_RC + + ntpdc/ntpdc-opts.texi@1.224, 2009-10-18 06:46:23-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P235_RC + + ntpdc/ntpdc.1@1.224, 2009-10-18 06:46:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P235_RC + + ntpq/ntpq-opts.c@1.226, 2009-10-18 06:46:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P235_RC + + ntpq/ntpq-opts.h@1.226, 2009-10-18 06:46:26-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P235_RC + + ntpq/ntpq-opts.texi@1.225, 2009-10-18 06:46:27-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P235_RC + + ntpq/ntpq.1@1.225, 2009-10-18 06:46:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P235_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.104, 2009-10-18 06:46:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P235_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.104, 2009-10-18 06:46:30-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P235_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.104, 2009-10-18 06:46:30-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P235_RC + + ntpsnmpd/ntpsnmpd.1@1.104, 2009-10-18 06:46:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P235_RC + + packageinfo.sh@1.239, 2009-10-18 06:46:32-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P235_RC + + sntp/sntp-opts.c@1.98, 2009-10-18 06:46:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P235_RC + + sntp/sntp-opts.h@1.98, 2009-10-18 06:46:33-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P235_RC + + sntp/sntp-opts.texi@1.98, 2009-10-18 06:46:34-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P235_RC + + sntp/sntp.1@1.98, 2009-10-18 06:46:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P235_RC + + util/ntp-keygen-opts.c@1.228, 2009-10-18 06:46:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P235_RC + + util/ntp-keygen-opts.h@1.228, 2009-10-18 06:46:36-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P235_RC + + util/ntp-keygen-opts.texi@1.227, 2009-10-18 06:46:37-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P235_RC + + util/ntp-keygen.1@1.227, 2009-10-18 06:46:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P235_RC + +ChangeSet@1.2060.1.5, 2009-10-18 01:54:01+00:00, davehart@shiny.ad.hartbrothers.com +13 -0 + [Bug 1343] lib/isc build breaks on systems without IPv6 headers. + + ChangeLog@1.497, 2009-10-18 01:54:00+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1343] lib/isc build breaks on systems without IPv6 headers. + + configure.ac@1.459.1.1, 2009-10-18 01:54:00+00:00, davehart@shiny.ad.hartbrothers.com +22 -23 + remove one of two sockaddr sa_len tests. + convert in_port_t tested to cached. + + include/ntp_rfc2553.h@1.32, 2009-10-18 01:54:00+00:00, davehart@shiny.ad.hartbrothers.com +4 -87 + [Bug 1343] lib/isc build breaks on systems without IPv6 headers. + + lib/isc/unix/include/isc/net.h@1.11, 2009-10-18 01:54:00+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + [Bug 1343] lib/isc build breaks on systems without IPv6 headers. + + lib/isc/unix/net.c@1.14, 2009-10-18 01:54:00+00:00, davehart@shiny.ad.hartbrothers.com +4 -3 + [Bug 1343] lib/isc build breaks on systems without IPv6 headers. + + lib/isc/win32/include/isc/ipv6.h@1.9, 2009-10-18 01:54:00+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + [Bug 1343] lib/isc build breaks on systems without IPv6 headers. + + lib/isc/win32/include/isc/net.h@1.9, 2009-10-18 01:54:00+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + [Bug 1343] lib/isc build breaks on systems without IPv6 headers. + + lib/isc/win32/net.c@1.13, 2009-10-18 01:54:00+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + [Bug 1343] lib/isc build breaks on systems without IPv6 headers. + + libntp/ntp_rfc2553.c@1.40, 2009-10-18 01:54:00+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + [Bug 1343] lib/isc build breaks on systems without IPv6 headers. + + ntpd/ntp_request.c@1.80.1.1, 2009-10-18 01:54:00+00:00, davehart@shiny.ad.hartbrothers.com +10 -10 + [Bug 1343] lib/isc build breaks on systems without IPv6 headers. + + ntpdc/ntpdc_ops.c@1.59, 2009-10-18 01:54:00+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + [Bug 1343] lib/isc build breaks on systems without IPv6 headers. + + ports/winnt/vs2008/libntp/libntp.vcproj@1.21, 2009-10-18 01:54:00+00:00, davehart@shiny.ad.hartbrothers.com +3 -3 + correct isc/net.h path + + sntp/configure.ac@1.20, 2009-10-18 01:54:00+00:00, davehart@shiny.ad.hartbrothers.com +56 -21 + libisc on systems without in_port_t wasn't compiling. + cache in_port_t test. + +ChangeSet@1.2060.1.4, 2009-10-16 06:48:28-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P234_RC + TAG: NTP_4_2_5P234_RC + + ChangeLog@1.496, 2009-10-16 06:48:02-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P234_RC + + ntpd/ntpd-opts.c@1.228, 2009-10-16 06:48:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P234_RC + + ntpd/ntpd-opts.h@1.228, 2009-10-16 06:48:04-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P234_RC + + ntpd/ntpd-opts.texi@1.226, 2009-10-16 06:48:05-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P234_RC + + ntpd/ntpd.1@1.226, 2009-10-16 06:48:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P234_RC + + ntpdc/ntpdc-opts.c@1.224, 2009-10-16 06:48:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P234_RC + + ntpdc/ntpdc-opts.h@1.224, 2009-10-16 06:48:07-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P234_RC + + ntpdc/ntpdc-opts.texi@1.223, 2009-10-16 06:48:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P234_RC + + ntpdc/ntpdc.1@1.223, 2009-10-16 06:48:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P234_RC + + ntpq/ntpq-opts.c@1.225, 2009-10-16 06:48:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P234_RC + + ntpq/ntpq-opts.h@1.225, 2009-10-16 06:48:11-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P234_RC + + ntpq/ntpq-opts.texi@1.224, 2009-10-16 06:48:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P234_RC + + ntpq/ntpq.1@1.224, 2009-10-16 06:48:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P234_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.103, 2009-10-16 06:48:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P234_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.103, 2009-10-16 06:48:15-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P234_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.103, 2009-10-16 06:48:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P234_RC + + ntpsnmpd/ntpsnmpd.1@1.103, 2009-10-16 06:48:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P234_RC + + packageinfo.sh@1.238, 2009-10-16 06:48:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P234_RC + + sntp/sntp-opts.c@1.97, 2009-10-16 06:48:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P234_RC + + sntp/sntp-opts.h@1.97, 2009-10-16 06:48:18-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P234_RC + + sntp/sntp-opts.texi@1.97, 2009-10-16 06:48:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P234_RC + + sntp/sntp.1@1.97, 2009-10-16 06:48:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P234_RC + + util/ntp-keygen-opts.c@1.227, 2009-10-16 06:48:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P234_RC + + util/ntp-keygen-opts.h@1.227, 2009-10-16 06:48:21-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P234_RC + + util/ntp-keygen-opts.texi@1.226, 2009-10-16 06:48:22-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P234_RC + + util/ntp-keygen.1@1.226, 2009-10-16 06:48:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P234_RC + +ChangeSet@1.2060.2.1, 2009-10-16 07:32:59+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + [Bug 1339] redux, use unmodified lib/isc/win32/strerror.c and + move #define strerror... to a header not used by lib/isc code. + + ChangeLog@1.493.1.1, 2009-10-16 07:32:58+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1339] redux, use unmodified lib/isc/win32/strerror.c and + move #define strerror... to a header not used by lib/isc code. + + include/ntp_stdlib.h@1.33, 2009-10-16 07:32:58+00:00, davehart@shiny.ad.hartbrothers.com +12 -3 + [Bug 1339] redux, use unmodified lib/isc/win32/strerror.c and + move #define strerror... to a header not used by lib/isc code. + + lib/isc/win32/strerror.c@1.13, 2009-10-16 07:32:58+00:00, davehart@shiny.ad.hartbrothers.com +10 -18 + [Bug 1339] redux, use unmodified lib/isc/win32/strerror.c and + move #define strerror... to a header not used by lib/isc code. + + ports/winnt/include/config.h@1.79, 2009-10-16 07:32:58+00:00, davehart@shiny.ad.hartbrothers.com +12 -8 + [Bug 1339] redux, use unmodified lib/isc/win32/strerror.c and + move #define strerror... to a header not used by lib/isc code. + + ports/winnt/include/syslog.h@1.6, 2009-10-16 07:32:58+00:00, davehart@shiny.ad.hartbrothers.com +0 -3 + [Bug 1339] redux, use unmodified lib/isc/win32/strerror.c and + move #define strerror... to a header not used by lib/isc code. + +ChangeSet@1.2060.1.2, 2009-10-15 22:09:06+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + [Bug 1345] illegal 'grep' option prevents compilation. + [Bug 1346] keyword scanner broken where char defaults to unsigned. + [Bug 1347] ntpd/complete.conf missing multicastclient test case. + + ChangeLog@1.494, 2009-10-15 22:08:53+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1345] illegal 'grep' option prevents compilation. + [Bug 1346] keyword scanner broken where char defaults to unsigned. + [Bug 1347] ntpd/complete.conf missing multicastclient test case. + + ntpd/Makefile.am@1.75, 2009-10-15 22:08:53+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + [Bug 1345] illegal 'grep' option prevents compilation. + + ntpd/complete.conf@1.2, 2009-10-15 22:08:53+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1347] ntpd/complete.conf missing multicastclient test case. + + ntpd/ntp_config.c@1.231, 2009-10-15 22:08:53+00:00, davehart@shiny.ad.hartbrothers.com +9 -15 + [Bug 1347] ntpd/complete.conf missing multicastclient test case. + + ntpd/ntp_scanner.c@1.30, 2009-10-15 22:08:53+00:00, davehart@shiny.ad.hartbrothers.com +20 -18 + [Bug 1346] keyword scanner broken where char defaults to unsigned. + + ntpd/ntp_scanner.h@1.13, 2009-10-15 22:08:53+00:00, davehart@shiny.ad.hartbrothers.com +0 -1 + [Bug 1346] keyword scanner broken where char defaults to unsigned. + +ChangeSet@1.2062, 2009-10-15 04:15:55-07:00, hstenn@lgmac-hstenn.local +2 -0 + sntp doc updates + + sntp/Makefile.am@1.15, 2009-10-15 04:15:20-07:00, hstenn@lgmac-hstenn.local +1 -0 + distribute sntp.texi + + sntp/sntp.texi@1.1, 2009-10-15 04:13:08-07:00, hstenn@lgmac-hstenn.local +84 -0 + BitKeeper file /Users/hstenn/src/ntp-dev-snmp/sntp/sntp.texi + + sntp/sntp.texi@1.0, 2009-10-15 04:13:08-07:00, hstenn@lgmac-hstenn.local +0 -0 + +ChangeSet@1.2060.1.1, 2009-10-15 06:43:07-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P233_RC + TAG: NTP_4_2_5P233_RC + + ChangeLog@1.493, 2009-10-15 06:42:36-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P233_RC + + ntpd/ntpd-opts.c@1.227, 2009-10-15 06:42:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P233_RC + + ntpd/ntpd-opts.h@1.227, 2009-10-15 06:42:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P233_RC + + ntpd/ntpd-opts.texi@1.225, 2009-10-15 06:42:40-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P233_RC + + ntpd/ntpd.1@1.225, 2009-10-15 06:42:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P233_RC + + ntpdc/ntpdc-opts.c@1.223, 2009-10-15 06:42:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P233_RC + + ntpdc/ntpdc-opts.h@1.223, 2009-10-15 06:42:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P233_RC + + ntpdc/ntpdc-opts.texi@1.222, 2009-10-15 06:42:44-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P233_RC + + ntpdc/ntpdc.1@1.222, 2009-10-15 06:42:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P233_RC + + ntpq/ntpq-opts.c@1.224, 2009-10-15 06:42:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P233_RC + + ntpq/ntpq-opts.h@1.224, 2009-10-15 06:42:48-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P233_RC + + ntpq/ntpq-opts.texi@1.223, 2009-10-15 06:42:49-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P233_RC + + ntpq/ntpq.1@1.223, 2009-10-15 06:42:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P233_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.102, 2009-10-15 06:42:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P233_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.102, 2009-10-15 06:42:51-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P233_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.102, 2009-10-15 06:42:52-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P233_RC + + ntpsnmpd/ntpsnmpd.1@1.102, 2009-10-15 06:42:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P233_RC + + packageinfo.sh@1.237, 2009-10-15 06:42:53-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P233_RC + + sntp/sntp-opts.c@1.96, 2009-10-15 06:42:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P233_RC + + sntp/sntp-opts.h@1.96, 2009-10-15 06:42:55-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P233_RC + + sntp/sntp-opts.texi@1.96, 2009-10-15 06:42:56-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P233_RC + + sntp/sntp.1@1.96, 2009-10-15 06:42:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P233_RC + + util/ntp-keygen-opts.c@1.226, 2009-10-15 06:42:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P233_RC + + util/ntp-keygen-opts.h@1.226, 2009-10-15 06:42:58-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P233_RC + + util/ntp-keygen-opts.texi@1.225, 2009-10-15 06:42:59-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P233_RC + + util/ntp-keygen.1@1.225, 2009-10-15 06:43:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P233_RC + +ChangeSet@1.2061, 2009-10-15 03:43:07-07:00, hstenn@lgmac-hstenn.local +6 -0 + Prep for sntp docs + + Makefile.am@1.87, 2009-10-15 03:32:53-07:00, hstenn@lgmac-hstenn.local +5 -1 + Create include/version.texi + + configure.ac@1.460, 2009-10-15 03:36:29-07:00, hstenn@lgmac-hstenn.local +7 -2 + K_open() is not used anymore. kvm_open() needs kvm.h + + include/Makefile.am@1.36, 2009-10-15 03:36:58-07:00, hstenn@lgmac-hstenn.local +1 -1 + include version.texi + + scripts/genver@1.5, 2009-10-15 03:37:44-07:00, hstenn@lgmac-hstenn.local +22 -1 + Handle version.texi + + sntp/Makefile.am@1.14, 2009-10-15 03:38:47-07:00, hstenn@lgmac-hstenn.local +17 -2 + Prep for building sntp.html + + sntp/sntp-opts.def@1.12, 2009-10-15 03:39:29-07:00, hstenn@lgmac-hstenn.local +15 -41 + updates + +ChangeSet@1.2057.1.1, 2009-10-15 00:53:23-04:00, stenn@whimsy.udel.edu +4 -0 + Documentation cleanup and updates + + ChangeLog@1.489.1.1, 2009-10-15 00:52:42-04:00, stenn@whimsy.udel.edu +1 -0 + Documentation cleanup and updates + + html/miscopt.html@1.52, 2009-10-15 00:52:54-04:00, stenn@whimsy.udel.edu +1 -1 + Documentation cleanup and updates + + html/ntpd.html@1.51, 2009-10-15 00:52:56-04:00, stenn@whimsy.udel.edu +72 -54 + Documentation cleanup and updates + + html/ntpq.html@1.34, 2009-10-15 00:52:58-04:00, stenn@whimsy.udel.edu +99 -73 + Documentation cleanup and updates + +ChangeSet@1.2058, 2009-10-15 03:30:56+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + [Bug 1342] ignore|drop one IPv6 address on an interface blocks all + addresses on that interface. + + ChangeLog@1.490, 2009-10-15 03:30:55+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1342] ignore|drop one IPv6 address on an interface blocks all + addresses on that interface. + + lib/isc/win32/interfaceiter.c@1.15, 2009-10-15 03:30:55+00:00, davehart@shiny.ad.hartbrothers.com +10 -25 + Cleanup incomplete merge of NTP local changes from recent libisc update + + ntpd/ntp_config.c@1.230, 2009-10-15 03:30:55+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + Use NULL for peer_config() interface arg instead of wildcard + to ensure the correct interface is used from the start. + + ntpd/ntp_io.c@1.304.1.1, 2009-10-15 03:30:55+00:00, davehart@shiny.ad.hartbrothers.com +17 -14 + [Bug 1342] ignore|drop one IPv6 address on an interface blocks all + addresses on that interface. + + ntpd/ntp_peer.c@1.122, 2009-10-15 03:30:55+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + Do not peer_clear("XFAC") manycast server associations or they will + never regain their ACST refid. + + ports/winnt/ntpd/ntservice.c@1.21, 2009-10-15 03:30:55+00:00, davehart@shiny.ad.hartbrothers.com +20 -8 + Make windows-only command-line hack a little less broken + +ChangeSet@1.2057, 2009-10-14 04:22:12-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P232_RC + TAG: NTP_4_2_5P232_RC + + ChangeLog@1.489, 2009-10-14 04:21:39-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P232_RC + + ntpd/ntpd-opts.c@1.226, 2009-10-14 04:21:41-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P232_RC + + ntpd/ntpd-opts.h@1.226, 2009-10-14 04:21:42-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P232_RC + + ntpd/ntpd-opts.texi@1.224, 2009-10-14 04:21:43-04:00, stenn@whimsy.udel.edu +15 -6 + NTP_4_2_5P232_RC + + ntpd/ntpd.1@1.224, 2009-10-14 04:21:45-04:00, stenn@whimsy.udel.edu +16 -7 + NTP_4_2_5P232_RC + + ntpdc/ntpdc-opts.c@1.222, 2009-10-14 04:21:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P232_RC + + ntpdc/ntpdc-opts.h@1.222, 2009-10-14 04:21:46-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P232_RC + + ntpdc/ntpdc-opts.texi@1.221, 2009-10-14 04:21:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P232_RC + + ntpdc/ntpdc.1@1.221, 2009-10-14 04:21:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P232_RC + + ntpq/ntpq-opts.c@1.223, 2009-10-14 04:21:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P232_RC + + ntpq/ntpq-opts.h@1.223, 2009-10-14 04:21:50-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P232_RC + + ntpq/ntpq-opts.texi@1.222, 2009-10-14 04:21:51-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P232_RC + + ntpq/ntpq.1@1.222, 2009-10-14 04:21:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P232_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.101, 2009-10-14 04:21:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P232_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.101, 2009-10-14 04:21:54-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P232_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.101, 2009-10-14 04:21:55-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P232_RC + + ntpsnmpd/ntpsnmpd.1@1.101, 2009-10-14 04:21:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P232_RC + + packageinfo.sh@1.236, 2009-10-14 04:21:57-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P232_RC + + sntp/sntp-opts.c@1.95, 2009-10-14 04:21:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P232_RC + + sntp/sntp-opts.h@1.95, 2009-10-14 04:21:58-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P232_RC + + sntp/sntp-opts.texi@1.95, 2009-10-14 04:21:59-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P232_RC + + sntp/sntp.1@1.95, 2009-10-14 04:22:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P232_RC + + util/ntp-keygen-opts.c@1.225, 2009-10-14 04:22:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P232_RC + + util/ntp-keygen-opts.h@1.225, 2009-10-14 04:22:01-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P232_RC + + util/ntp-keygen-opts.texi@1.224, 2009-10-14 04:22:02-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P232_RC + + util/ntp-keygen.1@1.224, 2009-10-14 04:22:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P232_RC + +ChangeSet@1.2050.5.1, 2009-10-13 23:48:18+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1341] NMEA driver requires working PPSAPI #ifdef HAVE_PPSAPI. + + ChangeLog@1.482.5.1, 2009-10-13 23:48:16+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1341] NMEA driver requires working PPSAPI #ifdef HAVE_PPSAPI. + + libntp/refnumtoa.c@1.7, 2009-10-13 23:48:17+00:00, davehart@shiny.ad.hartbrothers.com +2 -5 + do not require refnumtoa() callers to have called ISREFCLOCKADR() first + + ntpd/ntp_control.c@1.126, 2009-10-13 23:48:17+00:00, davehart@shiny.ad.hartbrothers.com +1 -2 + remove unneeded #ifdef REFCLOCK, ISREFCLOCKADR() is now always present + and refnumtoa() has long been always present, even without REFCLOCK. + + ntpd/refclock_nmea.c@1.44, 2009-10-13 23:48:17+00:00, davehart@shiny.ad.hartbrothers.com +73 -22 + [Bug 1341] NMEA driver requires working PPSAPI #ifdef HAVE_PPSAPI. + +ChangeSet@1.2050.4.1, 2009-10-13 02:24:57+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + Documentation updates for ntpq --oldrv, saveconfig, saveconfigdir, + ntpd -I -L and -M switches and interface/nic directive + + ChangeLog@1.482.4.1, 2009-10-13 02:24:57+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + Update documentation for ntpq --old-rv, saveconfig, saveconfigdir, + ntpd -I -L and -M, and interface/nic rules. (From Dave Hart) + + html/miscopt.html@1.51, 2009-10-13 02:24:57+00:00, davehart@shiny.ad.hartbrothers.com +4 -2 + Add saveconfigdir docs. + Add wildcard match class to interface/nic docs. + + html/ntpd.html@1.50, 2009-10-13 02:24:57+00:00, davehart@shiny.ad.hartbrothers.com +7 -3 + Update -L docs, add -I + + html/ntpq.html@1.33, 2009-10-13 02:24:57+00:00, davehart@shiny.ad.hartbrothers.com +5 -3 + Add ntpq --old-rv docs. + Update saveconfig docs to mention saveconfigdir. + + html/scripts/miscopt.txt@1.3, 2009-10-13 02:24:57+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + Add saveconfigdir + + ntpd/ntpdbase-opts.def@1.19, 2009-10-13 02:24:57+00:00, davehart@shiny.ad.hartbrothers.com +14 -4 + Update -L and -I docs to match HTML updates. + Expand -M docs. + +ChangeSet@1.2050.3.1, 2009-10-12 15:24:02+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + [Bug 1339] Fix Windows-only ntp_strerror() infinite recursion. + + ChangeLog@1.482.3.1, 2009-10-12 15:24:01+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1339] Fix Windows-only ntp_strerror() infinite recursion. + + lib/isc/win32/strerror.c@1.12, 2009-10-12 15:24:02+00:00, davehart@shiny.ad.hartbrothers.com +7 -4 + [Bug 1339] Fix Windows-only ntp_strerror() infinite recursion. + + ports/winnt/include/config.h@1.78, 2009-10-12 15:24:02+00:00, davehart@shiny.ad.hartbrothers.com +0 -3 + [Bug 1339] Fix Windows-only ntp_strerror() infinite recursion. + + ports/winnt/include/syslog.h@1.5, 2009-10-12 15:24:02+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1339] Fix Windows-only ntp_strerror() infinite recursion. + + ports/winnt/libntp/syslog.c@1.7, 2009-10-12 15:24:02+00:00, davehart@shiny.ad.hartbrothers.com +4 -10 + [Bug 1339] Fix Windows-only ntp_strerror() infinite recursion. + +ChangeSet@1.2050.1.2, 2009-10-12 03:40:08+00:00, kardel@pogo.udel.edu +2 -0 + ntp_io.c, ChangeLog: + cast address pointer to void * for bug 1337 + + ChangeLog@1.482.1.2, 2009-10-12 03:38:30+00:00, kardel@pogo.udel.edu +1 -0 + cast address pointer to void * for bug 1337 + + ntpd/ntp_io.c@1.305, 2009-10-12 03:36:51+00:00, kardel@pogo.udel.edu +1 -1 + cast address pointer to void * for bug 1337 + +ChangeSet@1.2050.2.2, 2009-10-11 22:09:53+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + Fix build break --with-arlib and config.cache + + arlib/configure.in@1.2, 2009-10-11 22:09:53+00:00, davehart@shiny.ad.hartbrothers.com +6 -7 + Fix build break --with-arlib and config.cache + +ChangeSet@1.2050.2.1, 2009-10-11 19:27:05+00:00, davehart@shiny.ad.hartbrothers.com +11 -0 + Construct ntpd keyword scanner finite state machine at compile time + rather than at runtime, shrink entries from 40+ to 8 bytes. + + ChangeLog@1.482.2.1, 2009-10-11 19:27:04+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + Construct ntpd keyword scanner finite state machine at compile time + rather than at runtime, shrink entries from 40+ to 8 bytes. + + bootstrap@1.27, 2009-10-11 19:27:04+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + touch new generated file ntp_keyword.h after ntp_parser.[ch] + + include/ntp_filegen.h@1.7, 2009-10-11 19:27:04+00:00, davehart@shiny.ad.hartbrothers.com +11 -11 + const is a virus + + ntpd/Makefile.am@1.74, 2009-10-11 19:27:04+00:00, davehart@shiny.ad.hartbrothers.com +17 -4 + add keyword-gen program which produces ntp_keyword.h + + ntpd/keyword-gen.c@1.1, 2009-10-11 19:25:15+00:00, davehart@shiny.ad.hartbrothers.com +546 -0 + new build-time tool to generate ntp_keyword.h with keyword scanner + finite state machine and token text array. + remove duplicate token table entries for "disable", "enable", + "monitor", and "version". + + ntpd/keyword-gen.c@1.0, 2009-10-11 19:25:15+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ntpd/ntp_config.c@1.229, 2009-10-11 19:27:04+00:00, davehart@shiny.ad.hartbrothers.com +2 -10 + remove references to create/delete_keyword_scanner() + + ntpd/ntp_filegen.c@1.17, 2009-10-11 19:27:04+00:00, davehart@shiny.ad.hartbrothers.com +12 -14 + const is a virus + + ntpd/ntp_keyword.h@1.1, 2009-10-11 19:25:12+00:00, davehart@shiny.ad.hartbrothers.com +920 -0 + generated by keyword-gen.c, contains keyword_text array and + keyword scanner finite state machine. + + ntpd/ntp_keyword.h@1.0, 2009-10-11 19:25:12+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ntpd/ntp_scanner.c@1.29, 2009-10-11 19:27:04+00:00, davehart@shiny.ad.hartbrothers.com +26 -343 + remove pieces to keyword-gen.c, new generated ntp_keyword.h + + ntpd/ntp_scanner.h@1.12, 2009-10-11 19:27:04+00:00, davehart@shiny.ad.hartbrothers.com +19 -16 + move struct key_tok to keyword-gen.c, add scan_state struct replacing + previous struct state. + add multiple-inclusion protection + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.21, 2009-10-11 19:27:04+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add reference to ntp_keyword.h + +ChangeSet@1.2050.1.1, 2009-10-11 11:50:51+00:00, kardel@pogo.udel.edu +2 -0 + ntp_io.c, ChangeLog: + [Bug 1337] fix incorrect args to setsockopt(fd, IP_MULTICAST_IF,...) + + ChangeLog@1.482.1.1, 2009-10-11 11:49:59+00:00, kardel@pogo.udel.edu +1 -0 + [Bug 1337] fix incorrect args to setsockopt(fd, IP_MULTICAST_IF,...) + + ntpd/ntp_io.c@1.304, 2009-10-11 11:50:26+00:00, kardel@pogo.udel.edu +1 -1 + [Bug 1337] fix incorrect args to setsockopt(fd, IP_MULTICAST_IF,...) + +ChangeSet@1.2051, 2009-10-11 02:36:55+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1302] OpenSSL under Windows needs applink support. + + ChangeLog@1.483, 2009-10-11 02:36:32+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1302] OpenSSL under Windows needs applink support. + + ports/winnt/ntpd/ntservice.c@1.20, 2009-10-11 02:36:32+00:00, davehart@shiny.ad.hartbrothers.com +54 -12 + [Bug 1302] OpenSSL under Windows needs applink support. + + util/ntp-keygen.c@1.58, 2009-10-11 02:36:32+00:00, davehart@shiny.ad.hartbrothers.com +7 -1 + [Bug 1302] OpenSSL under Windows needs applink support. + +ChangeSet@1.2050, 2009-10-10 06:41:51-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P231_RC + TAG: NTP_4_2_5P231_RC + + ChangeLog@1.482, 2009-10-10 06:41:20-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P231_RC + + ntpd/ntpd-opts.c@1.225, 2009-10-10 06:41:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P231_RC + + ntpd/ntpd-opts.h@1.225, 2009-10-10 06:41:22-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P231_RC + + ntpd/ntpd-opts.texi@1.223, 2009-10-10 06:41:23-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P231_RC + + ntpd/ntpd.1@1.223, 2009-10-10 06:41:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P231_RC + + ntpdc/ntpdc-opts.c@1.221, 2009-10-10 06:41:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P231_RC + + ntpdc/ntpdc-opts.h@1.221, 2009-10-10 06:41:27-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P231_RC + + ntpdc/ntpdc-opts.texi@1.220, 2009-10-10 06:41:28-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P231_RC + + ntpdc/ntpdc.1@1.220, 2009-10-10 06:41:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P231_RC + + ntpq/ntpq-opts.c@1.222, 2009-10-10 06:41:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P231_RC + + ntpq/ntpq-opts.h@1.222, 2009-10-10 06:41:30-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P231_RC + + ntpq/ntpq-opts.texi@1.221, 2009-10-10 06:41:31-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P231_RC + + ntpq/ntpq.1@1.221, 2009-10-10 06:41:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P231_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.100, 2009-10-10 06:41:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P231_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.100, 2009-10-10 06:41:34-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P231_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.100, 2009-10-10 06:41:35-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P231_RC + + ntpsnmpd/ntpsnmpd.1@1.100, 2009-10-10 06:41:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P231_RC + + packageinfo.sh@1.235, 2009-10-10 06:41:36-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P231_RC + + sntp/sntp-opts.c@1.94, 2009-10-10 06:41:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P231_RC + + sntp/sntp-opts.h@1.94, 2009-10-10 06:41:38-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P231_RC + + sntp/sntp-opts.texi@1.94, 2009-10-10 06:41:38-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P231_RC + + sntp/sntp.1@1.94, 2009-10-10 06:41:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P231_RC + + util/ntp-keygen-opts.c@1.224, 2009-10-10 06:41:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P231_RC + + util/ntp-keygen-opts.h@1.224, 2009-10-10 06:41:41-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P231_RC + + util/ntp-keygen-opts.texi@1.223, 2009-10-10 06:41:42-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P231_RC + + util/ntp-keygen.1@1.223, 2009-10-10 06:41:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P231_RC + +ChangeSet@1.2049, 2009-10-09 17:15:23+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1335] Broadcast client degraded by wildcard default change. + + ChangeLog@1.481, 2009-10-09 17:15:22+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1335] Broadcast client degraded by wildcard default change. + + ntpd/ntp_io.c@1.303, 2009-10-09 17:15:22+00:00, davehart@shiny.ad.hartbrothers.com +16 -3 + default wildcard addresses to drop, exclude from "all" match class + +ChangeSet@1.2048, 2009-10-09 02:25:40-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P230_RC + TAG: NTP_4_2_5P230_RC + + ChangeLog@1.480, 2009-10-09 02:25:13-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P230_RC + + ntpd/ntpd-opts.c@1.224, 2009-10-09 02:25:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P230_RC + + ntpd/ntpd-opts.h@1.224, 2009-10-09 02:25:15-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P230_RC + + ntpd/ntpd-opts.texi@1.222, 2009-10-09 02:25:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P230_RC + + ntpd/ntpd.1@1.222, 2009-10-09 02:25:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P230_RC + + ntpdc/ntpdc-opts.c@1.220, 2009-10-09 02:25:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P230_RC + + ntpdc/ntpdc-opts.h@1.220, 2009-10-09 02:25:18-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P230_RC + + ntpdc/ntpdc-opts.texi@1.219, 2009-10-09 02:25:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P230_RC + + ntpdc/ntpdc.1@1.219, 2009-10-09 02:25:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P230_RC + + ntpq/ntpq-opts.c@1.221, 2009-10-09 02:25:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P230_RC + + ntpq/ntpq-opts.h@1.221, 2009-10-09 02:25:23-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P230_RC + + ntpq/ntpq-opts.texi@1.220, 2009-10-09 02:25:24-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P230_RC + + ntpq/ntpq.1@1.220, 2009-10-09 02:25:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P230_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.99, 2009-10-09 02:25:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P230_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.99, 2009-10-09 02:25:26-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P230_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.99, 2009-10-09 02:25:27-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P230_RC + + ntpsnmpd/ntpsnmpd.1@1.99, 2009-10-09 02:25:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P230_RC + + packageinfo.sh@1.234, 2009-10-09 02:25:28-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P230_RC + + sntp/sntp-opts.c@1.93, 2009-10-09 02:25:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P230_RC + + sntp/sntp-opts.h@1.93, 2009-10-09 02:25:30-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P230_RC + + sntp/sntp-opts.texi@1.93, 2009-10-09 02:25:31-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P230_RC + + sntp/sntp.1@1.93, 2009-10-09 02:25:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P230_RC + + util/ntp-keygen-opts.c@1.223, 2009-10-09 02:25:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P230_RC + + util/ntp-keygen-opts.h@1.223, 2009-10-09 02:25:33-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P230_RC + + util/ntp-keygen-opts.texi@1.222, 2009-10-09 02:25:34-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P230_RC + + util/ntp-keygen.1@1.222, 2009-10-09 02:25:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P230_RC + +ChangeSet@1.2047, 2009-10-08 23:54:02-04:00, stenn@whimsy.udel.edu +2 -0 + Start the 4.2.6 Release Candidate cycle + + ChangeLog@1.479, 2009-10-08 23:52:59-04:00, stenn@whimsy.udel.edu +1 -0 + Start the 4.2.6 Release Candidate cycle + + packageinfo.sh@1.233, 2009-10-08 23:53:06-04:00, stenn@whimsy.udel.edu +2 -2 + Start the 4.2.6 Release Candidate cycle + +ChangeSet@1.2046, 2009-10-08 19:48:15-04:00, stenn@whimsy.udel.edu +3 -0 + Broadcast and transit phase cleanup from Dave Mills + + ChangeLog@1.478, 2009-10-08 19:47:58-04:00, stenn@whimsy.udel.edu +1 -0 + Broadcast and transit phase cleanup from Dave Mills + + ntpd/ntp_crypto.c@1.141, 2009-10-08 19:47:20-04:00, stenn@whimsy.udel.edu +2 -2 + Broadcast and transit phase cleanup from Dave Mills + + ntpd/ntp_proto.c@1.296, 2009-10-08 19:47:24-04:00, stenn@whimsy.udel.edu +7 -1 + Broadcast and transit phase cleanup from Dave Mills + +ChangeSet@1.2045, 2009-10-07 06:41:31-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P229 + TAG: NTP_4_2_5P229 + + ChangeLog@1.477, 2009-10-07 06:41:04-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P229 + + ntpd/ntpd-opts.c@1.223, 2009-10-07 06:41:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P229 + + ntpd/ntpd-opts.h@1.223, 2009-10-07 06:41:07-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P229 + + ntpd/ntpd-opts.texi@1.221, 2009-10-07 06:41:08-04:00, stenn@whimsy.udel.edu +4 -2 + NTP_4_2_5P229 + + ntpd/ntpd.1@1.221, 2009-10-07 06:41:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P229 + + ntpdc/ntpdc-opts.c@1.219, 2009-10-07 06:41:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P229 + + ntpdc/ntpdc-opts.h@1.219, 2009-10-07 06:41:10-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P229 + + ntpdc/ntpdc-opts.texi@1.218, 2009-10-07 06:41:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P229 + + ntpdc/ntpdc.1@1.218, 2009-10-07 06:41:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P229 + + ntpq/ntpq-opts.c@1.220, 2009-10-07 06:41:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P229 + + ntpq/ntpq-opts.h@1.220, 2009-10-07 06:41:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P229 + + ntpq/ntpq-opts.texi@1.219, 2009-10-07 06:41:15-04:00, stenn@whimsy.udel.edu +7 -3 + NTP_4_2_5P229 + + ntpq/ntpq.1@1.219, 2009-10-07 06:41:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P229 + + ntpsnmpd/ntpsnmpd-opts.c@1.98, 2009-10-07 06:41:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P229 + + ntpsnmpd/ntpsnmpd-opts.h@1.98, 2009-10-07 06:41:17-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P229 + + ntpsnmpd/ntpsnmpd-opts.texi@1.98, 2009-10-07 06:41:18-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P229 + + ntpsnmpd/ntpsnmpd.1@1.98, 2009-10-07 06:41:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P229 + + packageinfo.sh@1.232, 2009-10-07 06:41:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P229 + + sntp/sntp-opts.c@1.92, 2009-10-07 06:41:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P229 + + sntp/sntp-opts.h@1.92, 2009-10-07 06:41:21-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P229 + + sntp/sntp-opts.texi@1.92, 2009-10-07 06:41:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P229 + + sntp/sntp.1@1.92, 2009-10-07 06:41:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P229 + + util/ntp-keygen-opts.c@1.222, 2009-10-07 06:41:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P229 + + util/ntp-keygen-opts.h@1.222, 2009-10-07 06:41:24-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P229 + + util/ntp-keygen-opts.texi@1.221, 2009-10-07 06:41:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P229 + + util/ntp-keygen.1@1.221, 2009-10-07 06:41:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P229 + +ChangeSet@1.1436.15.71, 2009-10-07 01:33:22+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Sec 1331] DoS with mode 7 packets - CVE-2009-3563. + + ChangeLog@1.1.1.91, 2009-10-07 01:33:21+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Sec 1331] DoS with mode 7 packets - CVE-2009-3563. + + ntpd/ntp_request.c@1.65.1.3, 2009-10-07 01:33:21+00:00, davehart@shiny.ad.hartbrothers.com +9 -2 + [Sec 1331] DoS with mode 7 packets - CVE-2009-3563. + +ChangeSet@1.2044, 2009-10-06 15:37:07+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + [Bug 1334] ntpsnmpd undefined reference to `ntpqOptions'. + Change ntpsnmpd/Makefile.am include file order to fix FreeBSD build. + + ChangeLog@1.476, 2009-10-06 15:37:06+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1334] ntpsnmpd undefined reference to `ntpqOptions'. + Change ntpsnmpd/Makefile.am include file order to fix FreeBSD build. + + ntpq/ntpq-subs.c@1.39, 2009-10-06 15:37:06+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + [Bug 1334] ntpsnmpd undefined reference to `ntpqOptions'. + + ntpq/ntpq.c@1.94, 2009-10-06 15:37:06+00:00, davehart@shiny.ad.hartbrothers.com +11 -0 + [Bug 1334] ntpsnmpd undefined reference to `ntpqOptions'. + + ntpq/ntpq.h@1.10, 2009-10-06 15:37:06+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1334] ntpsnmpd undefined reference to `ntpqOptions'. + + ntpsnmpd/Makefile.am@1.11, 2009-10-06 15:37:06+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + list $(LIBOPTS_CFLAGS) ahead of @SNMP_CPPFLAGS@ to pick up our copy + of autoopts/options.h ahead of any on the generous include search + path in @SNMP_CPPFLAGS@ + +ChangeSet@1.2043, 2009-10-06 04:55:16-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P228 + TAG: NTP_4_2_5P228 + + ChangeLog@1.475, 2009-10-06 04:54:48-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P228 + + ntpd/ntpd-opts.c@1.222, 2009-10-06 04:54:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P228 + + ntpd/ntpd-opts.h@1.222, 2009-10-06 04:54:51-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P228 + + ntpd/ntpd-opts.texi@1.220, 2009-10-06 04:54:51-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P228 + + ntpd/ntpd.1@1.220, 2009-10-06 04:54:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P228 + + ntpdc/ntpdc-opts.c@1.218, 2009-10-06 04:54:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P228 + + ntpdc/ntpdc-opts.h@1.218, 2009-10-06 04:54:54-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P228 + + ntpdc/ntpdc-opts.texi@1.217, 2009-10-06 04:54:55-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P228 + + ntpdc/ntpdc.1@1.217, 2009-10-06 04:54:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P228 + + ntpq/ntpq-opts.c@1.219, 2009-10-06 04:54:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P228 + + ntpq/ntpq-opts.h@1.219, 2009-10-06 04:54:57-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P228 + + ntpq/ntpq-opts.texi@1.218, 2009-10-06 04:54:58-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P228 + + ntpq/ntpq.1@1.218, 2009-10-06 04:55:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P228 + + ntpsnmpd/ntpsnmpd-opts.c@1.97, 2009-10-06 04:55:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P228 + + ntpsnmpd/ntpsnmpd-opts.h@1.97, 2009-10-06 04:55:01-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P228 + + ntpsnmpd/ntpsnmpd-opts.texi@1.97, 2009-10-06 04:55:02-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P228 + + ntpsnmpd/ntpsnmpd.1@1.97, 2009-10-06 04:55:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P228 + + packageinfo.sh@1.231, 2009-10-06 04:55:03-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P228 + + sntp/sntp-opts.c@1.91, 2009-10-06 04:55:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P228 + + sntp/sntp-opts.h@1.91, 2009-10-06 04:55:05-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P228 + + sntp/sntp-opts.texi@1.91, 2009-10-06 04:55:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P228 + + sntp/sntp.1@1.91, 2009-10-06 04:55:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P228 + + util/ntp-keygen-opts.c@1.221, 2009-10-06 04:55:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P228 + + util/ntp-keygen-opts.h@1.221, 2009-10-06 04:55:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P228 + + util/ntp-keygen-opts.texi@1.220, 2009-10-06 04:55:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P228 + + util/ntp-keygen.1@1.220, 2009-10-06 04:55:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P228 + +ChangeSet@1.2042, 2009-10-06 06:48:31+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + Reclaim syntax tree memory after application in ntpd built with + configure --disable-saveconfig. + + ChangeLog@1.474, 2009-10-06 06:48:30+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + Reclaim syntax tree memory after application in ntpd built with + configure --disable-saveconfig. + + include/ntp_config.h@1.65, 2009-10-06 06:48:30+00:00, davehart@shiny.ad.hartbrothers.com +10 -0 + Reclaim syntax tree memory after application in ntpd built with + configure --disable-saveconfig. + + ntpd/ntp_config.c@1.228, 2009-10-06 06:48:30+00:00, davehart@shiny.ad.hartbrothers.com +57 -43 + Reclaim syntax tree memory after application in ntpd built with + configure --disable-saveconfig. + +ChangeSet@1.2039.1.1, 2009-10-06 03:49:05+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1135] ntpq uses sizeof(u_long) where sizeof(u_int32) is meant. + add new file ntpd/complete.conf to ntpd/Makefile.am EXTRA_DIST + + ChangeLog@1.471.1.1, 2009-10-06 03:49:04+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + [Bug 1135] ntpq uses sizeof(u_long) where sizeof(u_int32) is meant. + wrap [Bug 1327] line at 72 chars + + Makefile.am@1.86, 2009-10-06 03:49:04+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + run distcheck configure with -C so arlib, sntp configure runs benefit + from top-level configure.cache + + ntpd/Makefile.am@1.73, 2009-10-06 03:49:04+00:00, davehart@shiny.ad.hartbrothers.com +6 -2 + add new file ntpd/complete.conf to ntpd/Makefile.am EXTRA_DIST + + ntpq/ntpq.c@1.93, 2009-10-06 03:49:04+00:00, davehart@shiny.ad.hartbrothers.com +16 -17 + [Bug 1135] ntpq uses sizeof(u_long) where sizeof(u_int32) is meant. + +ChangeSet@1.2040, 2009-10-05 16:34:09+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1333] ntpd --interface precedence over --novirtualips lost. + + ChangeLog@1.472, 2009-10-05 16:34:07+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1333] ntpd --interface precedence over --novirtualips lost. + + ntpd/ntp_io.c@1.302, 2009-10-05 16:34:07+00:00, davehart@shiny.ad.hartbrothers.com +39 -26 + [Bug 1333] ntpd --interface precedence over --novirtualips lost. + +ChangeSet@1.2039, 2009-10-05 07:45:16-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P227 + TAG: NTP_4_2_5P227 + + ChangeLog@1.471, 2009-10-05 07:44:46-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P227 + + ntpd/ntpd-opts.c@1.221, 2009-10-05 07:44:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P227 + + ntpd/ntpd-opts.h@1.221, 2009-10-05 07:44:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P227 + + ntpd/ntpd-opts.texi@1.219, 2009-10-05 07:44:50-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P227 + + ntpd/ntpd.1@1.219, 2009-10-05 07:44:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P227 + + ntpdc/ntpdc-opts.c@1.217, 2009-10-05 07:44:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P227 + + ntpdc/ntpdc-opts.h@1.217, 2009-10-05 07:44:53-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P227 + + ntpdc/ntpdc-opts.texi@1.216, 2009-10-05 07:44:55-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P227 + + ntpdc/ntpdc.1@1.216, 2009-10-05 07:44:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P227 + + ntpq/ntpq-opts.c@1.218, 2009-10-05 07:44:56-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P227 + + ntpq/ntpq-opts.h@1.218, 2009-10-05 07:44:57-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P227 + + ntpq/ntpq-opts.texi@1.217, 2009-10-05 07:44:58-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P227 + + ntpq/ntpq.1@1.217, 2009-10-05 07:44:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P227 + + ntpsnmpd/ntpsnmpd-opts.c@1.96, 2009-10-05 07:45:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P227 + + ntpsnmpd/ntpsnmpd-opts.h@1.96, 2009-10-05 07:45:01-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P227 + + ntpsnmpd/ntpsnmpd-opts.texi@1.96, 2009-10-05 07:45:02-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P227 + + ntpsnmpd/ntpsnmpd.1@1.96, 2009-10-05 07:45:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P227 + + packageinfo.sh@1.230, 2009-10-05 07:45:03-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P227 + + sntp/sntp-opts.c@1.90, 2009-10-05 07:45:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P227 + + sntp/sntp-opts.h@1.90, 2009-10-05 07:45:04-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P227 + + sntp/sntp-opts.texi@1.90, 2009-10-05 07:45:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P227 + + sntp/sntp.1@1.90, 2009-10-05 07:45:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P227 + + util/ntp-keygen-opts.c@1.220, 2009-10-05 07:45:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P227 + + util/ntp-keygen-opts.h@1.220, 2009-10-05 07:45:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P227 + + util/ntp-keygen-opts.texi@1.219, 2009-10-05 07:45:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P227 + + util/ntp-keygen.1@1.219, 2009-10-05 07:45:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P227 + +ChangeSet@1.2038, 2009-10-05 07:29:55+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1135] :config fails with "Server disallowed request" + + ChangeLog@1.470, 2009-10-05 07:29:54+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1135] :config fails with "Server disallowed request" + + ntpd/ntp_control.c@1.125, 2009-10-05 07:29:54+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + [Bug 1135] :config fails with "Server disallowed request" + +ChangeSet@1.2037, 2009-10-05 06:35:21+00:00, davehart@shiny.ad.hartbrothers.com +9 -0 + [Bug 1332] ntpq -c 'rv 0 variablename' returns extra stuff. + add ntpq --old-rv + fix ipv4/ipv6 which are not equivalent in the libopts sense + + ChangeLog@1.469, 2009-10-05 06:35:19+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1332] ntpq -c 'rv 0 variablename' returns extra stuff. + + ntpq/ntpq-opts.c@1.217, 2009-10-05 06:35:19+00:00, davehart@shiny.ad.hartbrothers.com +39 -10 + autogen output + + ntpq/ntpq-opts.def@1.14, 2009-10-05 06:35:19+00:00, davehart@shiny.ad.hartbrothers.com +16 -2 + add ntpq --old-rv + fix ipv4/ipv6 which are not equivalent in the libopts sense + + ntpq/ntpq-opts.h@1.217, 2009-10-05 06:35:20+00:00, davehart@shiny.ad.hartbrothers.com +15 -10 + autogen output + + ntpq/ntpq-opts.texi@1.216, 2009-10-05 06:35:20+00:00, davehart@shiny.ad.hartbrothers.com +21 -5 + autogen output + + ntpq/ntpq-subs.c@1.38, 2009-10-05 06:35:20+00:00, davehart@shiny.ad.hartbrothers.com +38 -21 + [Bug 1332] ntpq -c 'rv 0 variablename' returns extra stuff. + add ntpq --old-rv + + ntpq/ntpq.1@1.216, 2009-10-05 06:35:20+00:00, davehart@shiny.ad.hartbrothers.com +17 -4 + autogen output + + ntpq/ntpq.c@1.92, 2009-10-05 06:35:20+00:00, davehart@shiny.ad.hartbrothers.com +22 -25 + [Bug 1332] ntpq -c 'rv 0 variablename' returns extra stuff. + + ntpq/ntpq.h@1.9, 2009-10-05 06:35:20+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + [Bug 1332] ntpq -c 'rv 0 variablename' returns extra stuff. + +ChangeSet@1.2032.1.1, 2009-10-04 18:35:23-04:00, stenn@whimsy.udel.edu +3 -0 + Documentation updates from Dave Hart/Dave Mills + + ChangeLog@1.465.1.1, 2009-10-04 18:33:22-04:00, stenn@whimsy.udel.edu +1 -0 + Documentation updates from Dave Hart/Dave Mills + + html/clockopt.html@1.22, 2009-10-04 18:33:46-04:00, stenn@whimsy.udel.edu +7 -5 + Documentation updates from Dave Hart/Dave Mills + + html/miscopt.html@1.50, 2009-10-04 18:33:50-04:00, stenn@whimsy.udel.edu +32 -35 + Documentation updates from Dave Hart/Dave Mills + +ChangeSet@1.2035, 2009-10-04 22:17:11+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + actually ignore nic/interface via :config with -I or -L, saying so + isn't enough. + + ntpd/ntp_config.c@1.227, 2009-10-04 22:17:10+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + actually ignore nic/interface via :config with -I or -L, saying so + isn't enough. + +ChangeSet@1.2034, 2009-10-04 20:28:52+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1330] disallow interface/nic rules when --novirtualips or + --interface are used. + + ChangeLog@1.467, 2009-10-04 20:28:50+00:00, davehart@shiny.ad.hartbrothers.com +4 -2 + [Bug 1330] disallow interface/nic rules when --novirtualips or + --interface are used. + add missing "* " prefix to 1318, 1327 entries + + ntpd/ntp_config.c@1.226, 2009-10-04 20:28:51+00:00, davehart@shiny.ad.hartbrothers.com +12 -1 + [Bug 1330] disallow interface/nic rules when --novirtualips or + --interface are used. + +ChangeSet@1.2033, 2009-10-04 18:14:14+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + Add test of ntpd --saveconfigquit fidelity using new complete.conf. + + ChangeLog@1.466, 2009-10-04 18:14:13+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + Add test of ntpd --saveconfigquit fidelity using new complete.conf. + + configure.ac@1.459, 2009-10-04 18:14:13+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + make "if SAVECONFIG_ENABLED" work in ntpd/Makefile.am + + ntpd/Makefile.am@1.72, 2009-10-04 18:14:13+00:00, davehart@shiny.ad.hartbrothers.com +14 -1 + add check_saveconfig target and list in check-local: to validate + --saveconfigquit produces the same configuration it is given. + + ntpd/complete.conf@1.1, 2009-10-04 18:14:13+00:00, davehart@shiny.ad.hartbrothers.com +54 -0 + This file represents an attempt to hit every keyword and syntax nook + + ntpd/complete.conf@1.0, 2009-10-04 18:14:13+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ntpd/ntp_config.c@1.225, 2009-10-04 18:14:13+00:00, davehart@shiny.ad.hartbrothers.com +39 -19 + move --saveconfigquit handling to before application of initial + syntax tree + + ntpdc/Makefile.am@1.43, 2009-10-04 18:14:13+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + correct reference to $(srcdir)/layout.std + +ChangeSet@1.2032, 2009-10-04 07:49:28-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P226 + TAG: NTP_4_2_5P226 + + ChangeLog@1.465, 2009-10-04 07:49:02-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P226 + + ntpd/ntpd-opts.c@1.220, 2009-10-04 07:49:03-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P226 + + ntpd/ntpd-opts.h@1.220, 2009-10-04 07:49:03-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P226 + + ntpd/ntpd-opts.texi@1.218, 2009-10-04 07:49:04-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P226 + + ntpd/ntpd.1@1.218, 2009-10-04 07:49:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P226 + + ntpdc/ntpdc-opts.c@1.216, 2009-10-04 07:49:06-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P226 + + ntpdc/ntpdc-opts.h@1.216, 2009-10-04 07:49:08-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P226 + + ntpdc/ntpdc-opts.texi@1.215, 2009-10-04 07:49:09-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P226 + + ntpdc/ntpdc.1@1.215, 2009-10-04 07:49:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P226 + + ntpq/ntpq-opts.c@1.216, 2009-10-04 07:49:10-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P226 + + ntpq/ntpq-opts.h@1.216, 2009-10-04 07:49:10-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P226 + + ntpq/ntpq-opts.texi@1.215, 2009-10-04 07:49:11-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P226 + + ntpq/ntpq.1@1.215, 2009-10-04 07:49:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P226 + + ntpsnmpd/ntpsnmpd-opts.c@1.95, 2009-10-04 07:49:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P226 + + ntpsnmpd/ntpsnmpd-opts.h@1.95, 2009-10-04 07:49:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P226 + + ntpsnmpd/ntpsnmpd-opts.texi@1.95, 2009-10-04 07:49:15-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P226 + + ntpsnmpd/ntpsnmpd.1@1.95, 2009-10-04 07:49:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P226 + + packageinfo.sh@1.229, 2009-10-04 07:49:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P226 + + sntp/sntp-opts.c@1.89, 2009-10-04 07:49:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P226 + + sntp/sntp-opts.h@1.89, 2009-10-04 07:49:17-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P226 + + sntp/sntp-opts.texi@1.89, 2009-10-04 07:49:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P226 + + sntp/sntp.1@1.89, 2009-10-04 07:49:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P226 + + util/ntp-keygen-opts.c@1.219, 2009-10-04 07:49:20-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P226 + + util/ntp-keygen-opts.h@1.219, 2009-10-04 07:49:21-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P226 + + util/ntp-keygen-opts.texi@1.218, 2009-10-04 07:49:22-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P226 + + util/ntp-keygen.1@1.218, 2009-10-04 07:49:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P226 + +ChangeSet@1.2029.1.2, 2009-10-03 01:26:37-04:00, stenn@whimsy.udel.edu +5 -0 + Clockhop and autokey cleanup from Dave Mills + + ChangeLog@1.462.1.2, 2009-10-03 01:26:17-04:00, stenn@whimsy.udel.edu +1 -0 + Clockhop and autokey cleanup from Dave Mills + + include/ntp.h@1.165, 2009-10-03 01:24:36-04:00, stenn@whimsy.udel.edu +1 -1 + Clockhop and autokey cleanup from Dave Mills + + libntp/statestr.c@1.19, 2009-10-03 01:25:10-04:00, stenn@whimsy.udel.edu +3 -3 + Clockhop and autokey cleanup from Dave Mills + + ntpd/ntp_crypto.c@1.140, 2009-10-03 01:25:18-04:00, stenn@whimsy.udel.edu +8 -10 + Clockhop and autokey cleanup from Dave Mills + + ntpd/ntp_proto.c@1.295, 2009-10-03 01:25:23-04:00, stenn@whimsy.udel.edu +10 -9 + Clockhop and autokey cleanup from Dave Mills + +ChangeSet@1.2029.1.1, 2009-10-03 01:19:40-04:00, stenn@whimsy.udel.edu +3 -0 + Documentation updates from Dave Mills + + ChangeLog@1.462.1.1, 2009-10-03 01:19:21-04:00, stenn@whimsy.udel.edu +1 -0 + Documentation updates from Dave Mills + + html/accopt.html@1.33, 2009-10-03 01:19:23-04:00, stenn@whimsy.udel.edu +6 -6 + Documentation updates from Dave Mills + + html/assoc.html@1.29, 2009-10-03 01:19:24-04:00, stenn@whimsy.udel.edu +8 -2 + Documentation updates from Dave Mills + +ChangeSet@1.2030, 2009-10-03 05:13:07+00:00, davehart@shiny.ad.hartbrothers.com +37 -0 + [Bug 1318] Allow multiple -g options on ntpd command line. + [Bug 1327] ntpq, ntpdc, ntp-keygen -d and -D should work with configure + --disable-debugging. + Add ntpd --saveconfigquit option for future build-time + testing of saveconfig fidelity. + + ChangeLog@1.463, 2009-10-03 05:13:03+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + [Bug 1318] Allow multiple -g options on ntpd command line. + [Bug 1327] ntpq, ntpdc, ntp-keygen -d and -D should work with configure + --disable-debugging. + Add ntpd --saveconfigquit option for future build-time + testing of saveconfig fidelity. + + configure.ac@1.458, 2009-10-03 05:13:03+00:00, davehart@shiny.ad.hartbrothers.com +3 -3 + [Bug 1327] ntpq, ntpdc, ntp-keygen -d and -D should work with configure + --disable-debugging. + + include/debug-opt.def@1.5, 2009-10-03 05:13:03+00:00, davehart@shiny.ad.hartbrothers.com +0 -2 + [Bug 1327] ntpq, ntpdc, ntp-keygen -d and -D should work with configure + --disable-debugging. + + include/ntp_config.h@1.64, 2009-10-03 05:13:03+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + add comment parameter to dump_config_tree() and dump_all_config_trees() + + libntp/Makefile.am@1.46, 2009-10-03 05:13:03+00:00, davehart@shiny.ad.hartbrothers.com +3 -9 + remove as much whitespace as possible from -I include dir sequence to + keep the signal-to-noise ratio higher on BSD make, which leaves tabs + in the constructed gcc command lines. + + libparse/Makefile.am@1.15, 2009-10-03 05:13:03+00:00, davehart@shiny.ad.hartbrothers.com +13 -15 + convert leading spaces to tabs. + remove as much whitespace as possible from -I include dir sequence to + keep the signal-to-noise ratio higher on BSD make, which leaves tabs + in the constructed gcc command lines. + + ntpd/Makefile.am@1.71, 2009-10-03 05:13:03+00:00, davehart@shiny.ad.hartbrothers.com +87 -39 + remove as much whitespace as possible from -I include dir sequence to + keep the signal-to-noise ratio higher on BSD make, which leaves tabs + in the constructed gcc command lines. + [Bug 1327] ntpq, ntpdc, ntp-keygen -d and -D should work with configure + --disable-debugging. + + ntpd/ntp_config.c@1.224, 2009-10-03 05:13:03+00:00, davehart@shiny.ad.hartbrothers.com +41 -17 + Add ntpd --saveconfigquit option for future build-time + testing of saveconfig fidelity. + + ntpd/ntp_control.c@1.124, 2009-10-03 05:13:03+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + Add ntpd --saveconfigquit option for future build-time + testing of saveconfig fidelity. + + ntpd/ntp_io.c@1.301, 2009-10-03 05:13:03+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + Add ntpd --saveconfigquit option for future build-time + testing of saveconfig fidelity. + + ntpd/ntpd-opts.c@1.219, 2009-10-03 05:13:03+00:00, davehart@shiny.ad.hartbrothers.com +55 -24 + autogen output + + ntpd/ntpd-opts.h@1.219, 2009-10-03 05:13:04+00:00, davehart@shiny.ad.hartbrothers.com +28 -19 + autogen output + + ntpd/ntpd-opts.texi@1.217, 2009-10-03 05:13:04+00:00, davehart@shiny.ad.hartbrothers.com +26 -2 + autogen output + + ntpd/ntpd.1@1.217, 2009-10-03 05:13:04+00:00, davehart@shiny.ad.hartbrothers.com +10 -2 + autogen output + + ntpd/ntpd.c@1.109, 2009-10-03 05:13:04+00:00, davehart@shiny.ad.hartbrothers.com +36 -28 + ntpdsim --help was crashing due to failure to init autoopts. + Add ntpd --saveconfigquit option for future build-time + testing of saveconfig fidelity. + + ntpd/ntpdbase-opts.def@1.18, 2009-10-03 05:13:04+00:00, davehart@shiny.ad.hartbrothers.com +46 -1 + [Bug 1318] Allow multiple -g options on ntpd command line. + [Bug 1327] ntpq, ntpdc, ntp-keygen -d and -D should work with configure + --disable-debugging. + Add ntpd --saveconfigquit option for future build-time + testing of saveconfig fidelity. + + ntpdate/Makefile.am@1.19, 2009-10-03 05:13:04+00:00, davehart@shiny.ad.hartbrothers.com +5 -5 + remove as much whitespace as possible from -I include dir sequence to + keep the signal-to-noise ratio higher on BSD make, which leaves tabs + in the constructed gcc command lines. + + ntpdc/Makefile.am@1.42, 2009-10-03 05:13:04+00:00, davehart@shiny.ad.hartbrothers.com +3 -6 + remove as much whitespace as possible from -I include dir sequence to + keep the signal-to-noise ratio higher on BSD make, which leaves tabs + in the constructed gcc command lines. + + ntpdc/ntpdc-opts.c@1.215, 2009-10-03 05:13:04+00:00, davehart@shiny.ad.hartbrothers.com +5 -30 + autogen output + + ntpdc/ntpdc-opts.h@1.215, 2009-10-03 05:13:04+00:00, davehart@shiny.ad.hartbrothers.com +2 -6 + autogen output + + ntpdc/ntpdc-opts.texi@1.214, 2009-10-03 05:13:04+00:00, davehart@shiny.ad.hartbrothers.com +4 -8 + autogen output + + ntpdc/ntpdc.1@1.214, 2009-10-03 05:13:04+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + autogen output + + ntpq/Makefile.am@1.36, 2009-10-03 05:13:04+00:00, davehart@shiny.ad.hartbrothers.com +5 -6 + remove as much whitespace as possible from -I include dir sequence to + keep the signal-to-noise ratio higher on BSD make, which leaves tabs + in the constructed gcc command lines. + + ntpq/ntpq-opts.c@1.215, 2009-10-03 05:13:04+00:00, davehart@shiny.ad.hartbrothers.com +5 -30 + autogen output + + ntpq/ntpq-opts.h@1.215, 2009-10-03 05:13:04+00:00, davehart@shiny.ad.hartbrothers.com +2 -6 + autogen output + + ntpq/ntpq-opts.texi@1.214, 2009-10-03 05:13:04+00:00, davehart@shiny.ad.hartbrothers.com +4 -8 + autogen output + + ntpq/ntpq.1@1.214, 2009-10-03 05:13:04+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + autogen output + + ntpsnmpd/Makefile.am@1.10, 2009-10-03 05:13:04+00:00, davehart@shiny.ad.hartbrothers.com +7 -10 + ntpsnmpd-opts.def doesn't include debug-opt.def. + remove as much whitespace as possible from -I include dir sequence to + keep the signal-to-noise ratio higher on BSD make, which leaves tabs + in the constructed gcc command lines. + + parseutil/Makefile.am@1.10, 2009-10-03 05:13:04+00:00, davehart@shiny.ad.hartbrothers.com +5 -5 + remove as much whitespace as possible from -I include dir sequence to + keep the signal-to-noise ratio higher on BSD make, which leaves tabs + in the constructed gcc command lines. + + ports/winnt/ntpd/ntservice.c@1.19, 2009-10-03 05:13:04+00:00, davehart@shiny.ad.hartbrothers.com +7 -1 + recognize alternate spellings of option names in win32 service startup hack + + ports/winnt/vs2008/libntp/libntp.vcproj@1.20, 2009-10-03 05:13:05+00:00, davehart@shiny.ad.hartbrothers.com +6 -2 + add reference to ntp_md5.h + + sntp/Makefile.am@1.13, 2009-10-03 05:13:05+00:00, davehart@shiny.ad.hartbrothers.com +5 -6 + remove as much whitespace as possible from -I include dir sequence to + keep the signal-to-noise ratio higher on BSD make, which leaves tabs + in the constructed gcc command lines. + + util/Makefile.am@1.41, 2009-10-03 05:13:05+00:00, davehart@shiny.ad.hartbrothers.com +4 -6 + remove as much whitespace as possible from -I include dir sequence to + keep the signal-to-noise ratio higher on BSD make, which leaves tabs + in the constructed gcc command lines. + + util/ntp-keygen-opts.c@1.218, 2009-10-03 05:13:05+00:00, davehart@shiny.ad.hartbrothers.com +5 -30 + autogen output + + util/ntp-keygen-opts.h@1.218, 2009-10-03 05:13:05+00:00, davehart@shiny.ad.hartbrothers.com +2 -6 + autogen output + + util/ntp-keygen-opts.texi@1.217, 2009-10-03 05:13:05+00:00, davehart@shiny.ad.hartbrothers.com +4 -8 + autogen output + + util/ntp-keygen.1@1.217, 2009-10-03 05:13:05+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + autogen output + +ChangeSet@1.2029, 2009-09-30 07:43:31-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P225 + TAG: NTP_4_2_5P225 + + ChangeLog@1.462, 2009-09-30 07:43:00-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P225 + + ntpd/ntpd-opts.c@1.218, 2009-09-30 07:43:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P225 + + ntpd/ntpd-opts.h@1.218, 2009-09-30 07:43:03-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P225 + + ntpd/ntpd-opts.texi@1.216, 2009-09-30 07:43:03-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P225 + + ntpd/ntpd.1@1.216, 2009-09-30 07:43:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P225 + + ntpdc/ntpdc-opts.c@1.214, 2009-09-30 07:43:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P225 + + ntpdc/ntpdc-opts.h@1.214, 2009-09-30 07:43:07-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P225 + + ntpdc/ntpdc-opts.texi@1.213, 2009-09-30 07:43:08-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P225 + + ntpdc/ntpdc.1@1.213, 2009-09-30 07:43:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P225 + + ntpq/ntpq-opts.c@1.214, 2009-09-30 07:43:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P225 + + ntpq/ntpq-opts.h@1.214, 2009-09-30 07:43:10-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P225 + + ntpq/ntpq-opts.texi@1.213, 2009-09-30 07:43:12-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P225 + + ntpq/ntpq.1@1.213, 2009-09-30 07:43:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P225 + + ntpsnmpd/ntpsnmpd-opts.c@1.94, 2009-09-30 07:43:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P225 + + ntpsnmpd/ntpsnmpd-opts.h@1.94, 2009-09-30 07:43:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P225 + + ntpsnmpd/ntpsnmpd-opts.texi@1.94, 2009-09-30 07:43:15-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P225 + + ntpsnmpd/ntpsnmpd.1@1.94, 2009-09-30 07:43:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P225 + + packageinfo.sh@1.228, 2009-09-30 07:43:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P225 + + sntp/sntp-opts.c@1.88, 2009-09-30 07:43:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P225 + + sntp/sntp-opts.h@1.88, 2009-09-30 07:43:18-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P225 + + sntp/sntp-opts.texi@1.88, 2009-09-30 07:43:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P225 + + sntp/sntp.1@1.88, 2009-09-30 07:43:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P225 + + util/ntp-keygen-opts.c@1.217, 2009-09-30 07:43:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P225 + + util/ntp-keygen-opts.h@1.217, 2009-09-30 07:43:22-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P225 + + util/ntp-keygen-opts.texi@1.216, 2009-09-30 07:43:23-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P225 + + util/ntp-keygen.1@1.216, 2009-09-30 07:43:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P225 + +ChangeSet@1.2026.1.1, 2009-09-30 06:32:09+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1324] support bracketed IPv6 numeric addresses for restrict. + + ChangeLog@1.459.1.1, 2009-09-30 06:32:09+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1324] support bracketed IPv6 numeric addresses for restrict. + + ntpd/ntp_config.c@1.223, 2009-09-30 06:32:09+00:00, davehart@shiny.ad.hartbrothers.com +73 -43 + [Bug 1324] support bracketed IPv6 numeric addresses for restrict. + + ntpd/ntp_io.c@1.300, 2009-09-30 06:32:09+00:00, davehart@shiny.ad.hartbrothers.com +13 -7 + [Bug 1324] support bracketed IPv6 numeric addresses for restrict. + +ChangeSet@1.2027, 2009-09-30 02:10:49-04:00, stenn@whimsy.udel.edu +3 -0 + authopt documentation changes from Dave Mills/Dave Hart + + ChangeLog@1.460, 2009-09-30 02:10:25-04:00, stenn@whimsy.udel.edu +1 -0 + authopt documentation changes from Dave Mills/Dave Hart + + html/authopt.html@1.52, 2009-09-30 02:10:27-04:00, stenn@whimsy.udel.edu +2 -2 + authopt documentation changes from Dave Mills/Dave Hart + + html/scripts/authopt.txt@1.2, 2009-09-30 02:10:27-04:00, stenn@whimsy.udel.edu +3 -4 + authopt documentation changes from Dave Mills/Dave Hart + +ChangeSet@1.2026, 2009-09-29 07:44:52-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P224 + TAG: NTP_4_2_5P224 + + ChangeLog@1.459, 2009-09-29 07:44:25-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P224 + + ntpd/ntpd-opts.c@1.217, 2009-09-29 07:44:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P224 + + ntpd/ntpd-opts.h@1.217, 2009-09-29 07:44:28-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P224 + + ntpd/ntpd-opts.texi@1.215, 2009-09-29 07:44:28-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P224 + + ntpd/ntpd.1@1.215, 2009-09-29 07:44:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P224 + + ntpdc/ntpdc-opts.c@1.213, 2009-09-29 07:44:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P224 + + ntpdc/ntpdc-opts.h@1.213, 2009-09-29 07:44:31-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P224 + + ntpdc/ntpdc-opts.texi@1.212, 2009-09-29 07:44:32-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P224 + + ntpdc/ntpdc.1@1.212, 2009-09-29 07:44:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P224 + + ntpq/ntpq-opts.c@1.213, 2009-09-29 07:44:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P224 + + ntpq/ntpq-opts.h@1.213, 2009-09-29 07:44:34-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P224 + + ntpq/ntpq-opts.texi@1.212, 2009-09-29 07:44:35-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P224 + + ntpq/ntpq.1@1.212, 2009-09-29 07:44:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P224 + + ntpsnmpd/ntpsnmpd-opts.c@1.93, 2009-09-29 07:44:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P224 + + ntpsnmpd/ntpsnmpd-opts.h@1.93, 2009-09-29 07:44:37-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P224 + + ntpsnmpd/ntpsnmpd-opts.texi@1.93, 2009-09-29 07:44:38-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P224 + + ntpsnmpd/ntpsnmpd.1@1.93, 2009-09-29 07:44:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P224 + + packageinfo.sh@1.227, 2009-09-29 07:44:39-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P224 + + sntp/sntp-opts.c@1.87, 2009-09-29 07:44:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P224 + + sntp/sntp-opts.h@1.87, 2009-09-29 07:44:41-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P224 + + sntp/sntp-opts.texi@1.87, 2009-09-29 07:44:41-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P224 + + sntp/sntp.1@1.87, 2009-09-29 07:44:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P224 + + util/ntp-keygen-opts.c@1.216, 2009-09-29 07:44:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P224 + + util/ntp-keygen-opts.h@1.216, 2009-09-29 07:44:44-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P224 + + util/ntp-keygen-opts.texi@1.215, 2009-09-29 07:44:45-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P224 + + util/ntp-keygen.1@1.215, 2009-09-29 07:44:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P224 + +ChangeSet@1.2025, 2009-09-29 06:38:31+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + Remove "tos maxhop" ntp.conf knob. + + ChangeLog@1.458, 2009-09-29 06:38:30+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + Remove "tos maxhop" ntp.conf knob. + + ntpd/ntp_parser.c@1.51, 2009-09-29 06:38:30+00:00, davehart@shiny.ad.hartbrothers.com +888 -902 + Bison output from ntp_parser.y + + ntpd/ntp_parser.h@1.31, 2009-09-29 06:38:30+00:00, davehart@shiny.ad.hartbrothers.com +175 -177 + Bison output from ntp_parser.y + + ntpd/ntp_parser.y@1.46, 2009-09-29 06:38:30+00:00, davehart@shiny.ad.hartbrothers.com +0 -3 + Remove "tos maxhop" ntp.conf knob. + + ntpd/ntp_scanner.c@1.28, 2009-09-29 06:38:30+00:00, davehart@shiny.ad.hartbrothers.com +0 -1 + Remove "tos maxhop" ntp.conf knob. + +ChangeSet@1.2024, 2009-09-28 22:36:59-04:00, stenn@whimsy.udel.edu +9 -0 + Clockhop and documentation fixes from Dave Mills + + ChangeLog@1.457, 2009-09-28 22:35:54-04:00, stenn@whimsy.udel.edu +1 -0 + Clockhop and documentation fixes from Dave Mills + + html/confopt.html@1.47, 2009-09-28 22:35:44-04:00, stenn@whimsy.udel.edu +1 -3 + Clockhop and documentation fixes from Dave Mills + + html/copyright.html@1.44, 2009-09-28 22:35:44-04:00, stenn@whimsy.udel.edu +7 -4 + Clockhop and documentation fixes from Dave Mills + + html/decode.html@1.11, 2009-09-28 22:35:45-04:00, stenn@whimsy.udel.edu +6 -1 + Clockhop and documentation fixes from Dave Mills + + html/miscopt.html@1.49, 2009-09-28 22:35:46-04:00, stenn@whimsy.udel.edu +7 -2 + Clockhop and documentation fixes from Dave Mills + + include/ntp.h@1.164, 2009-09-28 22:35:47-04:00, stenn@whimsy.udel.edu +1 -0 + Clockhop and documentation fixes from Dave Mills + + libntp/statestr.c@1.18, 2009-09-28 22:35:49-04:00, stenn@whimsy.udel.edu +1 -0 + Clockhop and documentation fixes from Dave Mills + + ntpd/ntp_config.c@1.222, 2009-09-28 22:35:50-04:00, stenn@whimsy.udel.edu +0 -5 + Clockhop and documentation fixes from Dave Mills + + ntpd/ntp_proto.c@1.294, 2009-09-28 22:35:52-04:00, stenn@whimsy.udel.edu +49 -31 + Clockhop and documentation fixes from Dave Mills + +ChangeSet@1.2023, 2009-09-28 07:43:25-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P223 + TAG: NTP_4_2_5P223 + + ChangeLog@1.456, 2009-09-28 07:42:59-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P223 + + ntpd/ntpd-opts.c@1.216, 2009-09-28 07:43:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P223 + + ntpd/ntpd-opts.h@1.216, 2009-09-28 07:43:01-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P223 + + ntpd/ntpd-opts.texi@1.214, 2009-09-28 07:43:02-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P223 + + ntpd/ntpd.1@1.214, 2009-09-28 07:43:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P223 + + ntpdc/ntpdc-opts.c@1.212, 2009-09-28 07:43:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P223 + + ntpdc/ntpdc-opts.h@1.212, 2009-09-28 07:43:05-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P223 + + ntpdc/ntpdc-opts.texi@1.211, 2009-09-28 07:43:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P223 + + ntpdc/ntpdc.1@1.211, 2009-09-28 07:43:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P223 + + ntpq/ntpq-opts.c@1.212, 2009-09-28 07:43:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P223 + + ntpq/ntpq-opts.h@1.212, 2009-09-28 07:43:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P223 + + ntpq/ntpq-opts.texi@1.211, 2009-09-28 07:43:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P223 + + ntpq/ntpq.1@1.211, 2009-09-28 07:43:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P223 + + ntpsnmpd/ntpsnmpd-opts.c@1.92, 2009-09-28 07:43:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P223 + + ntpsnmpd/ntpsnmpd-opts.h@1.92, 2009-09-28 07:43:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P223 + + ntpsnmpd/ntpsnmpd-opts.texi@1.92, 2009-09-28 07:43:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P223 + + ntpsnmpd/ntpsnmpd.1@1.92, 2009-09-28 07:43:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P223 + + packageinfo.sh@1.226, 2009-09-28 07:43:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P223 + + sntp/sntp-opts.c@1.86, 2009-09-28 07:43:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P223 + + sntp/sntp-opts.h@1.86, 2009-09-28 07:43:16-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P223 + + sntp/sntp-opts.texi@1.86, 2009-09-28 07:43:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P223 + + sntp/sntp.1@1.86, 2009-09-28 07:43:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P223 + + util/ntp-keygen-opts.c@1.215, 2009-09-28 07:43:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P223 + + util/ntp-keygen-opts.h@1.215, 2009-09-28 07:43:19-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P223 + + util/ntp-keygen-opts.texi@1.214, 2009-09-28 07:43:20-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P223 + + util/ntp-keygen.1@1.214, 2009-09-28 07:43:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P223 + +ChangeSet@1.2020.1.1, 2009-09-28 00:58:51+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + [Bug 1323] Implement "revoke #" to match documentation, deprecate + "crypto revoke #". + + ChangeLog@1.453.1.1, 2009-09-28 00:58:50+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1323] Implement "revoke #" to match documentation, deprecate + "crypto revoke #". + + ntpd/ntp_config.c@1.221, 2009-09-28 00:58:50+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + [Bug 1323] Implement "revoke #" to match documentation, deprecate + "crypto revoke #". + + ntpd/ntp_parser.c@1.50, 2009-09-28 00:58:50+00:00, davehart@shiny.ad.hartbrothers.com +675 -661 + Bison output from ntp_parser.y + + ntpd/ntp_parser.y@1.45, 2009-09-28 00:58:51+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + [Bug 1323] Implement "revoke #" to match documentation, deprecate + "crypto revoke #". + + ports/winnt/vs2008/ntp-keygen/ntp-keygen.vcproj@1.8, 2009-09-28 00:58:51+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + fix lingering references to $(OPENSSL)\lib to $(OPENSSL_LIB) + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.20, 2009-09-28 00:58:51+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + fix lingering references to $(OPENSSL)\lib to $(OPENSSL_LIB) + +ChangeSet@1.2021, 2009-09-27 20:24:13+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1321] build doesn't work if . isn't on $PATH. + + ChangeLog@1.454, 2009-09-27 20:24:13+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1321] build doesn't work if . isn't on $PATH. + + build@1.31, 2009-09-27 20:24:13+00:00, davehart@shiny.ad.hartbrothers.com +6 -1 + [Bug 1321] build doesn't work if . isn't on $PATH. + +ChangeSet@1.2020, 2009-09-27 15:31:58-04:00, stenn@whimsy.udel.edu +1 -0 + Hold off on the .deps cleanup for now + + bootstrap@1.26, 2009-09-27 07:01:49-04:00, stenn@whimsy.udel.edu +13 -3 + Hold off on the .deps cleanup for now + +ChangeSet@1.2019, 2009-09-27 07:50:18-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P222 + TAG: NTP_4_2_5P222 + + ChangeLog@1.453, 2009-09-27 07:49:50-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P222 + + ntpd/ntpd-opts.c@1.215, 2009-09-27 07:49:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P222 + + ntpd/ntpd-opts.h@1.215, 2009-09-27 07:49:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P222 + + ntpd/ntpd-opts.texi@1.213, 2009-09-27 07:49:52-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P222 + + ntpd/ntpd.1@1.213, 2009-09-27 07:49:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P222 + + ntpdc/ntpdc-opts.c@1.211, 2009-09-27 07:49:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P222 + + ntpdc/ntpdc-opts.h@1.211, 2009-09-27 07:49:54-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P222 + + ntpdc/ntpdc-opts.texi@1.210, 2009-09-27 07:49:56-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P222 + + ntpdc/ntpdc.1@1.210, 2009-09-27 07:49:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P222 + + ntpq/ntpq-opts.c@1.211, 2009-09-27 07:49:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P222 + + ntpq/ntpq-opts.h@1.211, 2009-09-27 07:49:59-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P222 + + ntpq/ntpq-opts.texi@1.210, 2009-09-27 07:50:00-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P222 + + ntpq/ntpq.1@1.210, 2009-09-27 07:50:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P222 + + ntpsnmpd/ntpsnmpd-opts.c@1.91, 2009-09-27 07:50:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P222 + + ntpsnmpd/ntpsnmpd-opts.h@1.91, 2009-09-27 07:50:03-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P222 + + ntpsnmpd/ntpsnmpd-opts.texi@1.91, 2009-09-27 07:50:04-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P222 + + ntpsnmpd/ntpsnmpd.1@1.91, 2009-09-27 07:50:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P222 + + packageinfo.sh@1.225, 2009-09-27 07:50:07-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P222 + + sntp/sntp-opts.c@1.85, 2009-09-27 07:50:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P222 + + sntp/sntp-opts.h@1.85, 2009-09-27 07:50:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P222 + + sntp/sntp-opts.texi@1.85, 2009-09-27 07:50:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P222 + + sntp/sntp.1@1.85, 2009-09-27 07:50:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P222 + + util/ntp-keygen-opts.c@1.214, 2009-09-27 07:50:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P222 + + util/ntp-keygen-opts.h@1.214, 2009-09-27 07:50:11-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P222 + + util/ntp-keygen-opts.texi@1.213, 2009-09-27 07:50:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P222 + + util/ntp-keygen.1@1.213, 2009-09-27 07:50:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P222 + +ChangeSet@1.2018, 2009-09-27 06:07:50-04:00, stenn@whimsy.udel.edu +1 -0 + Use find/xargs to remove .deps files + + bootstrap@1.25, 2009-09-27 06:07:38-04:00, stenn@whimsy.udel.edu +1 -2 + Use find/xargs to remove .deps files + +ChangeSet@1.2017, 2009-09-27 09:34:20+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + .del-Makefile.am~f0c497c686043766: + Delete: lib/isc/nothreads/include/isc/Makefile.am + + BitKeeper/deleted/.del-Makefile.am~f0c497c686043766@1.2, 2009-09-27 09:34:09+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Delete: lib/isc/nothreads/include/isc/Makefile.am + +ChangeSet@1.2011.1.3, 2009-09-27 05:22:57-04:00, stenn@whimsy.udel.edu +5 -0 + Remove unneeded Makefile.am files from lib/isc/include + + BitKeeper/deleted/.del-Makefile.am~3d21d1b06f4d0a5e@1.1.1.1, 2009-09-27 05:19:32-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: lib/isc/unix/include/isc/Makefile.am + + BitKeeper/deleted/.del-Makefile.am~5be91011328ee7b@1.9.1.1, 2009-09-27 05:19:02-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: lib/isc/include/isc/Makefile.am + + ChangeLog@1.450.1.1, 2009-09-27 05:22:00-04:00, stenn@whimsy.udel.edu +1 -0 + Remove unneeded Makefile.am files from lib/isc/include + + Makefile.am@1.83.1.1, 2009-09-27 05:22:03-04:00, stenn@whimsy.udel.edu +0 -2 + Remove unneeded Makefile.am files from lib/isc/include + + configure.ac@1.455.1.1, 2009-09-27 05:22:09-04:00, stenn@whimsy.udel.edu +0 -2 + Remove unneeded Makefile.am files from lib/isc/include + +ChangeSet@1.2014, 2009-09-27 06:53:59+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + Updated build and flock-build scripts. flock-build --one is a way + to perform a flock-build compatible solitary build, handy for a repo + clone's first build on a machine with autoconf, automake, etc. + Compiling ntp_parser.y using BSD make correctly places ntp_parser.h + in the top-level ntpd directory instead of A.*/ntpd. + bootstrap script updated to remove potentially stale .deps dirs. + + + ChangeLog@1.449.1.2, 2009-09-27 06:53:59+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + Updated build and flock-build scripts. flock-build --one is a way + to perform a flock-build compatible solitary build, handy for a repo + clone's first build on a machine with autoconf, automake, etc. + Compiling ntp_parser.y using BSD make correctly places ntp_parser.h + in the top-level ntpd directory instead of A.*/ntpd. + bootstrap script updated to remove potentially stale .deps dirs. + + + bootstrap@1.24, 2009-09-27 06:53:59+00:00, davehart@shiny.ad.hartbrothers.com +8 -0 + remove .deps directories to handle source code shuffles + + build@1.30, 2009-09-27 06:53:59+00:00, davehart@shiny.ad.hartbrothers.com +26 -19 + store configure cache in top srcdir config.cache-{hostname} + so flock-build runs configure uncached once + + flock-build@1.44, 2009-09-27 06:53:59+00:00, davehart@shiny.ad.hartbrothers.com +54 -37 + add --one option to invoke a single build on the invoking + host using flock-build's options to configure, useful to + bring a repo clone tree to a state like a tarball, ready + for flock-building on hosts without all dev tools (such + as autoconf, automake, bison). + update udel flock default LIST + + ntpd/Makefile.am@1.70, 2009-09-27 06:53:59+00:00, davehart@shiny.ad.hartbrothers.com +27 -1 + introduce vphack_after rule to fix ntp_parser.h placement when + using build and BSD make. Thanks for Harlan's help on this. + +ChangeSet@1.2011.1.2, 2009-09-26 07:42:06-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P221 + TAG: NTP_4_2_5P221 + + ChangeLog@1.450, 2009-09-26 07:41:39-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P221 + + ntpd/ntpd-opts.c@1.214, 2009-09-26 07:41:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P221 + + ntpd/ntpd-opts.h@1.214, 2009-09-26 07:41:41-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P221 + + ntpd/ntpd-opts.texi@1.212, 2009-09-26 07:41:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P221 + + ntpd/ntpd.1@1.212, 2009-09-26 07:41:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P221 + + ntpdc/ntpdc-opts.c@1.210, 2009-09-26 07:41:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P221 + + ntpdc/ntpdc-opts.h@1.210, 2009-09-26 07:41:44-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P221 + + ntpdc/ntpdc-opts.texi@1.209, 2009-09-26 07:41:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P221 + + ntpdc/ntpdc.1@1.209, 2009-09-26 07:41:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P221 + + ntpq/ntpq-opts.c@1.210, 2009-09-26 07:41:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P221 + + ntpq/ntpq-opts.h@1.210, 2009-09-26 07:41:48-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P221 + + ntpq/ntpq-opts.texi@1.209, 2009-09-26 07:41:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P221 + + ntpq/ntpq.1@1.209, 2009-09-26 07:41:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P221 + + ntpsnmpd/ntpsnmpd-opts.c@1.90, 2009-09-26 07:41:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P221 + + ntpsnmpd/ntpsnmpd-opts.h@1.90, 2009-09-26 07:41:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P221 + + ntpsnmpd/ntpsnmpd-opts.texi@1.90, 2009-09-26 07:41:53-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P221 + + ntpsnmpd/ntpsnmpd.1@1.90, 2009-09-26 07:41:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P221 + + packageinfo.sh@1.224, 2009-09-26 07:41:54-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P221 + + sntp/sntp-opts.c@1.84, 2009-09-26 07:41:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P221 + + sntp/sntp-opts.h@1.84, 2009-09-26 07:41:56-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P221 + + sntp/sntp-opts.texi@1.84, 2009-09-26 07:41:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P221 + + sntp/sntp.1@1.84, 2009-09-26 07:41:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P221 + + util/ntp-keygen-opts.c@1.213, 2009-09-26 07:41:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P221 + + util/ntp-keygen-opts.h@1.213, 2009-09-26 07:41:59-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P221 + + util/ntp-keygen-opts.texi@1.212, 2009-09-26 07:42:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P221 + + util/ntp-keygen.1@1.212, 2009-09-26 07:42:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P221 + +ChangeSet@1.2010.1.1, 2009-09-26 03:55:56-04:00, murray@pogo.udel.edu +2 -0 + ChangeLog, refclock_nmea.c: + Fix for Bug 1316: segfault from refclock_nmea + + ChangeLog@1.448, 2009-09-25 17:24:57-04:00, murray@pogo.udel.edu +1 -0 + Fix for Bug 1316 + + ntpd/refclock_nmea.c@1.43, 2009-09-25 17:26:16-04:00, murray@pogo.udel.edu +4 -2 + Fix for Bug 1316 + +ChangeSet@1.2011, 2009-09-25 19:32:13-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1317] Distribute cvo.sh + + ChangeLog@1.447.1.1, 2009-09-25 19:31:54-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1317] Distribute cvo.sh + + scripts/Makefile.am@1.16, 2009-09-25 19:31:47-04:00, stenn@whimsy.udel.edu +2 -2 + [Bug 1317] Distribute cvo.sh + +ChangeSet@1.2004.2.1, 2009-09-25 19:30:24+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + correct a few overlooked bk mv's in upstream libisc repo related to + lib/isc/nothreads/include/isc + + BitKeeper/deleted/.del-mutex.h~d46b831ccac8e078@1.2, 2009-09-25 19:25:03+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Delete: lib/isc/nothreads/include/isc/mutex.h + + BitKeeper/deleted/.del-once.h~79619f1c64fdf49b@1.2, 2009-09-25 19:25:56+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Delete: lib/isc/nothreads/include/isc/once.h + + BitKeeper/deleted/.del-strerror.c~5704d44@1.2.1.1, 2009-09-25 19:22:52+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Delete: ports/winnt/libntp/strerror.c + + lib/isc/nothreads/include/isc/mutex.h@1.3.1.2, 2009-09-25 19:30:23+00:00, davehart@shiny.ad.hartbrothers.com +10 -10 + correct a few overlooked bk mv's in upstream libisc repo related to + lib/isc/nothreads/include/isc + + lib/isc/nothreads/include/isc/mutex.h@1.3.1.1, 2009-09-25 19:25:37+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: lib/isc/include/isc/mutex.h -> lib/isc/nothreads/include/isc/mutex.h + + lib/isc/nothreads/include/isc/once.h@1.3.1.2, 2009-09-25 19:30:23+00:00, davehart@shiny.ad.hartbrothers.com +10 -10 + correct a few overlooked bk mv's in upstream libisc repo related to + lib/isc/nothreads/include/isc + + lib/isc/nothreads/include/isc/once.h@1.3.1.1, 2009-09-25 19:26:05+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: lib/isc/include/isc/once.h -> lib/isc/nothreads/include/isc/once.h + +ChangeSet@1.2004.1.3, 2009-09-25 19:17:24+00:00, davehart@shiny.ad.hartbrothers.com +49 -0 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + BitKeeper/deleted/.del-mutex.h~cf2fbab1@1.4, 2009-09-25 19:14:52+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: lib/isc/include/isc/mutex.h -> BitKeeper/deleted/.del-mutex.h~cf2fbab1 + + BitKeeper/deleted/.del-once.h~cfad354a@1.4, 2009-09-25 19:14:53+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: lib/isc/include/isc/once.h -> BitKeeper/deleted/.del-once.h~cfad354a + + BitKeeper/deleted/.del-strerror.c~5704d44@1.3, 2009-09-25 19:14:52+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/libntp/strerror.c -> BitKeeper/deleted/.del-strerror.c~5704d44 + + ChangeLog@1.443.1.1, 2009-09-25 19:17:19+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + Makefile.am@1.82.1.1, 2009-09-25 19:17:19+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + configure.ac@1.456, 2009-09-25 19:17:19+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + add reference to lib/isc/nothreads/include/isc/Makefile.am + + lib/isc/include/isc/Makefile.am@1.10, 2009-09-25 19:17:19+00:00, davehart@shiny.ad.hartbrothers.com +71 -30 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + lib/isc/include/isc/interfaceiter.h@1.7, 2009-09-25 19:17:19+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + add NTP-local broadcast address, broadcast & multicast bitflags + to libisc network interface iterator + + lib/isc/include/isc/msgs.h@1.6, 2009-09-25 19:17:19+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + add ISC_MSG_GETBCSTADDR used by NTP-local interface iterator changes + + lib/isc/inet_ntop.c@1.8, 2009-09-25 19:17:19+00:00, davehart@shiny.ad.hartbrothers.com +6 -2 + use ntp_snprintf.h's SNPRINTF for SunOS 4 compat + + lib/isc/nothreads/include/isc/Makefile.am@1.1, 2009-09-25 19:17:22+00:00, davehart@shiny.ad.hartbrothers.com +12 -0 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + lib/isc/nothreads/include/isc/Makefile.am@1.0, 2009-09-25 19:17:22+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/sockaddr.c@1.9, 2009-09-25 19:17:19+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + cast to silence warning + + lib/isc/unix/ifiter_getifaddrs.c@1.8, 2009-09-25 19:17:19+00:00, davehart@shiny.ad.hartbrothers.com +14 -1 + add NTP-local broadcast address, broadcast & multicast bitflags + to libisc network interface iterator + + lib/isc/unix/ifiter_ioctl.c@1.28, 2009-09-25 19:17:19+00:00, davehart@shiny.ad.hartbrothers.com +76 -0 + add NTP-local broadcast address, broadcast & multicast bitflags + to libisc network interface iterator + + lib/isc/unix/ifiter_sysctl.c@1.15, 2009-09-25 19:17:20+00:00, davehart@shiny.ad.hartbrothers.com +13 -0 + add NTP-local broadcast address, broadcast & multicast bitflags + to libisc network interface iterator + + lib/isc/unix/include/isc/Makefile.am@1.2, 2009-09-25 19:17:20+00:00, davehart@shiny.ad.hartbrothers.com +12 -8 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + lib/isc/unix/net.c@1.13, 2009-09-25 19:17:20+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + NTP-local change, use GETSOCKNAME_SOCKLEN_TYPE + + lib/isc/unix/strerror.c@1.6, 2009-09-25 19:17:20+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + NTP local change, #include "l_stdlib.h" + + lib/isc/win32/include/isc/platform.h@1.6, 2009-09-25 19:17:20+00:00, davehart@shiny.ad.hartbrothers.com +20 -11 + NTP-local change, disable __declspec(dllimport) for libisc public + interfaces with #define ISC_STATIC_WIN + + lib/isc/win32/include/isc/stat.h@1.4, 2009-09-25 19:17:20+00:00, davehart@shiny.ad.hartbrothers.com +15 -0 + NTP-local changes: alias more identifiers from POSIX names to Microsoft's, + with leading underscores, so libopts builds on Windows + + lib/isc/win32/include/isc/thread.h@1.2, 2009-09-25 19:17:20+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + NTP-local fix type, silence warning + + lib/isc/win32/interfaceiter.c@1.10.1.3, 2009-09-25 19:17:20+00:00, davehart@shiny.ad.hartbrothers.com +36 -1 + add NTP-local broadcast address, broadcast & multicast bitflags + to libisc network interface iterator + + lib/isc/win32/net.c@1.12, 2009-09-25 19:17:20+00:00, davehart@shiny.ad.hartbrothers.com +3 -3 + NTP-local changes fix closeocket(s) typo, silence two warnings with casts + + lib/isc/win32/strerror.c@1.11, 2009-09-25 19:17:20+00:00, davehart@shiny.ad.hartbrothers.com +15 -10 + NTP-local changes: use CRT_strerror() not strerror() to avoid our + #define strerror, do not reference _sys_nerr when calling strerror() + will do and avoids a deprecation warning for _sys_nerr + + lib/isc/win32/thread.c@1.2, 2009-09-25 19:17:20+00:00, davehart@shiny.ad.hartbrothers.com +7 -3 + NTP-local change, handle 64-bit isc_threadresult_t correctly + + libntp/Makefile.am@1.45, 2009-09-25 19:17:20+00:00, davehart@shiny.ad.hartbrothers.com +44 -19 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + libparse/Makefile.am@1.14, 2009-09-25 19:17:20+00:00, davehart@shiny.ad.hartbrothers.com +9 -6 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + ntpd/Makefile.am@1.69, 2009-09-25 19:17:20+00:00, davehart@shiny.ad.hartbrothers.com +9 -7 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + ntpd/ntp_io.c@1.297.1.1, 2009-09-25 19:17:20+00:00, davehart@shiny.ad.hartbrothers.com +54 -11 + libisc network interface iterator now requires a mctx, build one + on top of emalloc() + + ntpdate/Makefile.am@1.18, 2009-09-25 19:17:20+00:00, davehart@shiny.ad.hartbrothers.com +4 -3 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + ntpdc/Makefile.am@1.41, 2009-09-25 19:17:20+00:00, davehart@shiny.ad.hartbrothers.com +5 -4 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + ntpq/Makefile.am@1.35, 2009-09-25 19:17:21+00:00, davehart@shiny.ad.hartbrothers.com +5 -4 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + ntpsnmpd/Makefile.am@1.9, 2009-09-25 19:17:21+00:00, davehart@shiny.ad.hartbrothers.com +7 -6 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + parseutil/Makefile.am@1.9, 2009-09-25 19:17:21+00:00, davehart@shiny.ad.hartbrothers.com +4 -3 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + ports/winnt/include/config.h@1.77, 2009-09-25 19:17:21+00:00, davehart@shiny.ad.hartbrothers.com +9 -2 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + ports/winnt/libntp/syslog.c@1.6, 2009-09-25 19:17:21+00:00, davehart@shiny.ad.hartbrothers.com +28 -1 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + ports/winnt/ntpd/ntservice.c@1.18, 2009-09-25 19:17:21+00:00, davehart@shiny.ad.hartbrothers.com +4 -14 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + ports/winnt/ntpd/win32_io.c@1.19, 2009-09-25 19:17:21+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + #include to quiet warning about _open_osfhandle + + ports/winnt/vc6/libntp.dsp@1.43, 2009-09-25 19:17:21+00:00, davehart@shiny.ad.hartbrothers.com +38 -2 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + ports/winnt/vc6/ntpd.dsp@1.39, 2009-09-25 19:17:21+00:00, davehart@shiny.ad.hartbrothers.com +5 -5 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + ports/winnt/vs2003/libntp.vcproj@1.4, 2009-09-25 19:17:21+00:00, davehart@shiny.ad.hartbrothers.com +98 -47 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + ports/winnt/vs2003/ntpd.vcproj@1.4, 2009-09-25 19:17:21+00:00, davehart@shiny.ad.hartbrothers.com +5 -5 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + ports/winnt/vs2005/libntp.vcproj@1.4, 2009-09-25 19:17:21+00:00, davehart@shiny.ad.hartbrothers.com +102 -46 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + ports/winnt/vs2005/ntpd.vcproj@1.4, 2009-09-25 19:17:21+00:00, davehart@shiny.ad.hartbrothers.com +5 -5 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + ports/winnt/vs2008/libntp/libntp.vcproj@1.19, 2009-09-25 19:17:21+00:00, davehart@shiny.ad.hartbrothers.com +102 -1358 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.19, 2009-09-25 19:17:21+00:00, davehart@shiny.ad.hartbrothers.com +6 -6 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + sntp/Makefile.am@1.12, 2009-09-25 19:17:22+00:00, davehart@shiny.ad.hartbrothers.com +5 -4 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + sntp/main.c@1.19, 2009-09-25 19:17:22+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + util/Makefile.am@1.40, 2009-09-25 19:17:22+00:00, davehart@shiny.ad.hartbrothers.com +5 -4 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + +ChangeSet@1.2008.1.1, 2009-09-25 15:48:47+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + Makefile.am: correct EXTRA_DIST reference from libisc to lib/isc + + Makefile.am@1.83, 2009-09-25 15:48:47+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + correct EXTRA_DIST reference from libisc to lib/isc + +ChangeSet@1.2009, 2009-09-25 07:47:32-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P220 + TAG: NTP_4_2_5P220 + + ChangeLog@1.447, 2009-09-25 07:47:02-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P220 + + ntpd/ntpd-opts.c@1.213, 2009-09-25 07:47:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P220 + + ntpd/ntpd-opts.h@1.213, 2009-09-25 07:47:04-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P220 + + ntpd/ntpd-opts.texi@1.211, 2009-09-25 07:47:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P220 + + ntpd/ntpd.1@1.211, 2009-09-25 07:47:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P220 + + ntpdc/ntpdc-opts.c@1.209, 2009-09-25 07:47:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P220 + + ntpdc/ntpdc-opts.h@1.209, 2009-09-25 07:47:09-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P220 + + ntpdc/ntpdc-opts.texi@1.208, 2009-09-25 07:47:10-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P220 + + ntpdc/ntpdc.1@1.208, 2009-09-25 07:47:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P220 + + ntpq/ntpq-opts.c@1.209, 2009-09-25 07:47:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P220 + + ntpq/ntpq-opts.h@1.209, 2009-09-25 07:47:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P220 + + ntpq/ntpq-opts.texi@1.208, 2009-09-25 07:47:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P220 + + ntpq/ntpq.1@1.208, 2009-09-25 07:47:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P220 + + ntpsnmpd/ntpsnmpd-opts.c@1.89, 2009-09-25 07:47:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P220 + + ntpsnmpd/ntpsnmpd-opts.h@1.89, 2009-09-25 07:47:16-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P220 + + ntpsnmpd/ntpsnmpd-opts.texi@1.89, 2009-09-25 07:47:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P220 + + ntpsnmpd/ntpsnmpd.1@1.89, 2009-09-25 07:47:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P220 + + packageinfo.sh@1.223, 2009-09-25 07:47:18-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P220 + + sntp/sntp-opts.c@1.83, 2009-09-25 07:47:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P220 + + sntp/sntp-opts.h@1.83, 2009-09-25 07:47:20-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P220 + + sntp/sntp-opts.texi@1.83, 2009-09-25 07:47:21-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P220 + + sntp/sntp.1@1.83, 2009-09-25 07:47:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P220 + + util/ntp-keygen-opts.c@1.212, 2009-09-25 07:47:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P220 + + util/ntp-keygen-opts.h@1.212, 2009-09-25 07:47:24-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P220 + + util/ntp-keygen-opts.texi@1.211, 2009-09-25 07:47:25-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P220 + + util/ntp-keygen.1@1.211, 2009-09-25 07:47:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P220 + +ChangeSet@1.2008, 2009-09-25 07:09:49+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + Rearrange libisc code to match the upstream layout in BIND. This is + step one of two, changing the layout but keeping our existing libisc. + + ChangeLog@1.446, 2009-09-25 07:09:48+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + Rearrange libisc code to match the upstream layout in BIND. This is + step one of two, changing the layout but keeping our existing libisc. + +ChangeSet@1.2004.1.2, 2009-09-24 15:52:46+00:00, davehart@shiny.ad.hartbrothers.com +239 -0 + import unmodified lib/isc from ISC bind-9.6.1-P1.tar.gz + + lib/isc/alpha/include/isc/atomic.h@1.1, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +184 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/alpha/include/isc/atomic.h@1.0, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/api@1.1, 2009-09-24 15:50:35+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/api@1.0, 2009-09-24 15:50:35+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/assertions.c@1.4, 2009-09-24 15:50:35+00:00, davehart@shiny.ad.hartbrothers.com +17 -13 + bind-9.6.1-P1.tar.gz + + lib/isc/base32.c@1.1, 2009-09-24 15:50:35+00:00, davehart@shiny.ad.hartbrothers.com +371 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/base32.c@1.0, 2009-09-24 15:50:35+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/base64.c@1.1, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +250 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/base64.c@1.0, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/bitstring.c@1.1, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +127 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/bitstring.c@1.0, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/buffer.c@1.1, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +489 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/buffer.c@1.0, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/bufferlist.c@1.1, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +64 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/bufferlist.c@1.0, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/commandline.c@1.1, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +225 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/commandline.c@1.0, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/entropy.c@1.1, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +1274 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/entropy.c@1.0, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/error.c@1.4, 2009-09-24 15:50:35+00:00, davehart@shiny.ad.hartbrothers.com +15 -10 + bind-9.6.1-P1.tar.gz + + lib/isc/event.c@1.1, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +88 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/event.c@1.0, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/fsaccess.c@1.1, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +102 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/fsaccess.c@1.0, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/hash.c@1.1, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +390 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/hash.c@1.0, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/heap.c@1.1, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +262 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/heap.c@1.0, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/hex.c@1.1, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +201 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/hex.c@1.0, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/hmacmd5.c@1.1, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +118 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/hmacmd5.c@1.0, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/hmacsha.c@1.1, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +438 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/hmacsha.c@1.0, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/httpd.c@1.1, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +987 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/httpd.c@1.0, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/ia64/include/isc/atomic.h@1.1, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +100 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/ia64/include/isc/atomic.h@1.0, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/app.h@1.4, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +57 -57 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/assertions.h@1.4, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +16 -12 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/base32.h@1.1, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +128 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/base32.h@1.0, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/base64.h@1.1, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +99 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/base64.h@1.0, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/bitstring.h@1.1, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +157 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/bitstring.h@1.0, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/boolean.h@1.4, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +12 -10 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/buffer.h@1.4, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +251 -147 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/bufferlist.h@1.1, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +86 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/bufferlist.h@1.0, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/commandline.h@1.1, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +50 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/commandline.h@1.0, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/entropy.h@1.1, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +314 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/entropy.h@1.0, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/error.h@1.4, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +17 -10 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/event.h@1.1, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +121 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/event.h@1.0, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/eventclass.h@1.1, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +53 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/eventclass.h@1.0, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/file.h@1.4, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +8 -8 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/formatcheck.h@1.4, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +20 -14 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/fsaccess.h@1.1, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +178 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/fsaccess.h@1.0, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/hash.h@1.1, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +185 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/hash.h@1.0, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/heap.h@1.1, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +170 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/heap.h@1.0, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/hex.h@1.1, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +98 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/hex.h@1.0, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/hmacmd5.h@1.1, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +63 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/hmacmd5.h@1.0, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/hmacsha.h@1.1, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +156 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/hmacsha.h@1.0, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/httpd.h@1.1, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +64 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/httpd.h@1.0, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/interfaceiter.h@1.6, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +46 -50 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/ipv6.h@1.9, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +22 -29 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/iterated_hash.h@1.1, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +47 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/iterated_hash.h@1.0, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/lang.h@1.4, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +12 -10 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/lex.h@1.1, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +431 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/lex.h@1.0, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/lfsr.h@1.1, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +130 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/lfsr.h@1.0, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/lib.h@1.4, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +14 -12 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/list.h@1.4, 2009-09-24 15:50:39+00:00, davehart@shiny.ad.hartbrothers.com +17 -13 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/log.h@1.3, 2009-09-24 15:50:39+00:00, davehart@shiny.ad.hartbrothers.com +15 -14 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/magic.h@1.4, 2009-09-24 15:50:39+00:00, davehart@shiny.ad.hartbrothers.com +13 -12 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/mem.h@1.5, 2009-09-24 15:50:39+00:00, davehart@shiny.ad.hartbrothers.com +612 -19 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/msgcat.h@1.4, 2009-09-24 15:50:39+00:00, davehart@shiny.ad.hartbrothers.com +33 -34 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/msgs.h@1.5, 2009-09-24 15:50:39+00:00, davehart@shiny.ad.hartbrothers.com +137 -126 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/mutexblock.h@1.1, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +71 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/mutexblock.h@1.0, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/netaddr.h@1.6, 2009-09-24 15:50:39+00:00, davehart@shiny.ad.hartbrothers.com +58 -27 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/netscope.h@1.3, 2009-09-24 15:50:39+00:00, davehart@shiny.ad.hartbrothers.com +9 -6 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/ondestroy.h@1.1, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +116 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/ondestroy.h@1.0, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/os.h@1.1, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +38 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/os.h@1.0, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/parseint.h@1.1, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +64 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/parseint.h@1.0, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/platform.h.in@1.1, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +339 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/platform.h.in@1.0, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/portset.h@1.1, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +141 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/portset.h@1.0, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/print.h@1.4, 2009-09-24 15:50:39+00:00, davehart@shiny.ad.hartbrothers.com +31 -13 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/quota.h@1.1, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +119 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/quota.h@1.0, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/radix.h@1.1, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +240 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/radix.h@1.0, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/random.h@1.1, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +62 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/random.h@1.0, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/ratelimiter.h@1.1, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +134 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/ratelimiter.h@1.0, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/refcount.h@1.1, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +233 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/refcount.h@1.0, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/region.h@1.3, 2009-09-24 15:50:39+00:00, davehart@shiny.ad.hartbrothers.com +14 -10 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/resource.h@1.1, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +97 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/resource.h@1.0, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/result.h@1.5, 2009-09-24 15:50:39+00:00, davehart@shiny.ad.hartbrothers.com +69 -68 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/resultclass.h@1.1, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +50 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/resultclass.h@1.0, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/rwlock.h@1.1, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +135 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/rwlock.h@1.0, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/serial.h@1.1, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +75 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/serial.h@1.0, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/sha1.h@1.1, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +59 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/sha1.h@1.0, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/sha2.h@1.1, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +132 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/sha2.h@1.0, 2009-09-24 15:50:41+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/sockaddr.h@1.5, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +83 -44 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/socket.h@1.1, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +1007 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/socket.h@1.0, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/stats.h@1.1, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +121 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/stats.h@1.0, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/stdio.h@1.3, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/stdlib.h@1.1, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +40 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/stdlib.h@1.0, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/string.h@1.4, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +188 -13 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/symtab.h@1.1, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +131 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/symtab.h@1.0, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/task.h@1.1, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +624 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/task.h@1.0, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/taskpool.h@1.1, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +105 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/taskpool.h@1.0, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/timer.h@1.1, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +344 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/timer.h@1.0, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/types.h@1.4, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +81 -59 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/util.h@1.4, 2009-09-24 15:50:40+00:00, davehart@shiny.ad.hartbrothers.com +26 -18 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/version.h@1.1, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +28 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/version.h@1.0, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/include/isc/xml.h@1.1, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +41 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/xml.h@1.0, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/inet_aton.c@1.4, 2009-09-24 15:50:35+00:00, davehart@shiny.ad.hartbrothers.com +9 -8 + bind-9.6.1-P1.tar.gz + + lib/isc/inet_ntop.c@1.7, 2009-09-24 15:50:35+00:00, davehart@shiny.ad.hartbrothers.com +25 -31 + bind-9.6.1-P1.tar.gz + + lib/isc/inet_pton.c@1.4, 2009-09-24 15:50:35+00:00, davehart@shiny.ad.hartbrothers.com +34 -37 + bind-9.6.1-P1.tar.gz + + lib/isc/iterated_hash.c@1.1, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +48 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/iterated_hash.c@1.0, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/lex.c@1.1, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +959 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/lex.c@1.0, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/lfsr.c@1.1, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +161 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/lfsr.c@1.0, 2009-09-24 15:50:36+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/lib.c@1.4, 2009-09-24 15:50:35+00:00, davehart@shiny.ad.hartbrothers.com +13 -11 + bind-9.6.1-P1.tar.gz + + lib/isc/log.c@1.3, 2009-09-24 15:50:35+00:00, davehart@shiny.ad.hartbrothers.com +15 -15 + bind-9.6.1-P1.tar.gz + + lib/isc/mem.c@1.5, 2009-09-24 15:50:35+00:00, davehart@shiny.ad.hartbrothers.com +2181 -23 + bind-9.6.1-P1.tar.gz + + lib/isc/mips/include/isc/atomic.h@1.1, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +98 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/mips/include/isc/atomic.h@1.0, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/mutexblock.c@1.1, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +59 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/mutexblock.c@1.0, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/netaddr.c@1.6, 2009-09-24 15:50:35+00:00, davehart@shiny.ad.hartbrothers.com +83 -10 + bind-9.6.1-P1.tar.gz + + lib/isc/netscope.c@1.3, 2009-09-24 15:50:35+00:00, davehart@shiny.ad.hartbrothers.com +5 -3 + bind-9.6.1-P1.tar.gz + + lib/isc/nls/msgcat.c@1.6, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +14 -13 + bind-9.6.1-P1.tar.gz + + lib/isc/noatomic/include/isc/atomic.h@1.1, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +24 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/noatomic/include/isc/atomic.h@1.0, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/nothreads/condition.c@1.1, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +24 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/nothreads/condition.c@1.0, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/nothreads/include/isc/condition.h@1.1, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +59 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/nothreads/include/isc/condition.h@1.0, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/nothreads/include/isc/mutex.h@1.1, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +39 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/nothreads/include/isc/mutex.h@1.0, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/nothreads/include/isc/once.h@1.1, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +32 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/nothreads/include/isc/once.h@1.0, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/nothreads/include/isc/thread.h@1.1, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +35 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/nothreads/include/isc/thread.h@1.0, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/nothreads/mutex.c@1.1, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +25 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/nothreads/mutex.c@1.0, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/nothreads/thread.c@1.1, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +28 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/nothreads/thread.c@1.0, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/ondestroy.c@1.1, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +85 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/ondestroy.c@1.0, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/parseint.c@1.1, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +72 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/parseint.c@1.0, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/portset.c@1.1, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +143 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/portset.c@1.0, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/powerpc/include/isc/atomic.h@1.1, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +160 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/powerpc/include/isc/atomic.h@1.0, 2009-09-24 15:50:42+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/print.c@1.1, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +624 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/print.c@1.0, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/pthreads/condition.c@1.1, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +74 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/pthreads/condition.c@1.0, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/pthreads/include/isc/condition.h@1.1, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +65 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/pthreads/include/isc/condition.h@1.0, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/pthreads/include/isc/mutex.h@1.1, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +145 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/pthreads/include/isc/mutex.h@1.0, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/pthreads/include/isc/once.h@1.1, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +50 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/pthreads/include/isc/once.h@1.0, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/pthreads/include/isc/thread.h@1.1, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +60 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/pthreads/include/isc/thread.h@1.0, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/pthreads/mutex.c@1.1, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +272 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/pthreads/mutex.c@1.0, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/pthreads/thread.c@1.1, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +76 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/pthreads/thread.c@1.0, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/quota.c@1.1, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +101 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/quota.c@1.0, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/radix.c@1.1, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +706 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/radix.c@1.0, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/random.c@1.1, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +104 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/random.c@1.0, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/ratelimiter.c@1.1, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +328 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/ratelimiter.c@1.0, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/refcount.c@1.1, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +37 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/refcount.c@1.0, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/region.c@1.1, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +45 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/region.c@1.0, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/result.c@1.1, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +213 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/result.c@1.0, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/rwlock.c@1.1, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +808 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/rwlock.c@1.0, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/serial.c@1.1, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +59 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/serial.c@1.0, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/sha1.c@1.1, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +315 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/sha1.c@1.0, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/sha2.c@1.1, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +1234 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/sha2.c@1.0, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/sockaddr.c@1.8, 2009-09-24 15:50:35+00:00, davehart@shiny.ad.hartbrothers.com +87 -64 + bind-9.6.1-P1.tar.gz + + lib/isc/sparc64/include/isc/atomic.h@1.1, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +127 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/sparc64/include/isc/atomic.h@1.0, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/stats.c@1.1, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +326 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/stats.c@1.0, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/string.c@1.1, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +270 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/string.c@1.0, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/strtoul.c@1.1, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +129 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/strtoul.c@1.0, 2009-09-24 15:50:37+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/symtab.c@1.1, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +252 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/symtab.c@1.0, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/task.c@1.1, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +1376 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/task.c@1.0, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/task_p.h@1.1, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +31 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/task_p.h@1.0, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/taskpool.c@1.1, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +96 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/taskpool.c@1.0, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/timer.c@1.1, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +933 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/timer.c@1.0, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/timer_p.h@1.1, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +31 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/timer_p.h@1.0, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/unix/app.c@1.1, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +684 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/app.c@1.0, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/unix/dir.c@1.1, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +251 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/dir.c@1.0, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/unix/entropy.c@1.1, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +605 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/entropy.c@1.0, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/unix/errno2result.c@1.1, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +123 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/errno2result.c@1.0, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/unix/errno2result.h@1.1, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +39 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/errno2result.h@1.0, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/unix/file.c@1.1, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +444 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/file.c@1.0, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/unix/fsaccess.c@1.1, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +93 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/fsaccess.c@1.0, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/unix/ifiter_getifaddrs.c@1.7, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +72 -29 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/ifiter_ioctl.c@1.27, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +49 -236 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/ifiter_sysctl.c@1.14, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +6 -19 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/include/isc/dir.h@1.3, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +3 -3 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/include/isc/int.h@1.4, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +13 -11 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/include/isc/keyboard.h@1.1, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +52 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/include/isc/keyboard.h@1.0, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/unix/include/isc/net.h@1.10, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +91 -56 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/include/isc/netdb.h@1.1, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +57 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/include/isc/netdb.h@1.0, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/unix/include/isc/offset.h@1.4, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +14 -12 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/include/isc/stat.h@1.3, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +3 -3 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/include/isc/stdtime.h@1.1, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +60 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/include/isc/stdtime.h@1.0, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/unix/include/isc/strerror.h@1.4, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +15 -12 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/include/isc/syslog.h@1.1, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +47 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/include/isc/syslog.h@1.0, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/unix/include/isc/time.h@1.3, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +40 -10 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/interfaceiter.c@1.17, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +99 -7 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/ipv6.c@1.1, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +27 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/ipv6.c@1.0, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/unix/keyboard.c@1.1, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +126 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/keyboard.c@1.0, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/unix/net.c@1.12, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +232 -19 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/os.c@1.1, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +94 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/os.c@1.0, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/unix/resource.c@1.1, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +231 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/resource.c@1.0, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/unix/socket.c@1.1, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +5550 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/socket.c@1.0, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/unix/socket_p.h@1.1, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +32 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/socket_p.h@1.0, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/unix/stdio.c@1.1, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +117 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/stdio.c@1.0, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/unix/stdtime.c@1.1, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +86 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/stdtime.c@1.0, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/unix/strerror.c@1.5, 2009-09-24 15:50:43+00:00, davehart@shiny.ad.hartbrothers.com +15 -15 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/syslog.c@1.1, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +84 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/syslog.c@1.0, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/unix/time.c@1.1, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +438 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/time.c@1.0, 2009-09-24 15:50:44+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/version.c@1.1, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +28 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/version.c@1.0, 2009-09-24 15:50:38+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/DLLMain.c@1.1, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +58 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/DLLMain.c@1.0, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/app.c@1.1, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +260 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/app.c@1.0, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/condition.c@1.1, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +258 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/condition.c@1.0, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/dir.c@1.1, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +312 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/dir.c@1.0, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/entropy.c@1.1, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +307 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/entropy.c@1.0, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/errno2result.c@1.1, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +113 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/errno2result.c@1.0, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/errno2result.h@1.1, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +40 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/errno2result.h@1.0, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/file.c@1.1, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +507 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/file.c@1.0, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/fsaccess.c@1.1, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +375 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/fsaccess.c@1.0, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/include/isc/bind_registry.h@1.1, 2009-09-24 15:50:47+00:00, davehart@shiny.ad.hartbrothers.com +50 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/bind_registry.h@1.0, 2009-09-24 15:50:47+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/include/isc/bindevt.h@1.1, 2009-09-24 15:50:47+00:00, davehart@shiny.ad.hartbrothers.com +91 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/bindevt.h@1.0, 2009-09-24 15:50:47+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/include/isc/condition.h@1.1, 2009-09-24 15:50:47+00:00, davehart@shiny.ad.hartbrothers.com +67 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/condition.h@1.0, 2009-09-24 15:50:47+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/include/isc/dir.h@1.1, 2009-09-24 15:50:47+00:00, davehart@shiny.ad.hartbrothers.com +83 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/dir.h@1.0, 2009-09-24 15:50:47+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/include/isc/int.h@1.4, 2009-09-24 15:50:47+00:00, davehart@shiny.ad.hartbrothers.com +10 -10 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/ipv6.h@1.8, 2009-09-24 15:50:47+00:00, davehart@shiny.ad.hartbrothers.com +10 -15 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/keyboard.h@1.1, 2009-09-24 15:50:47+00:00, davehart@shiny.ad.hartbrothers.com +47 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/keyboard.h@1.0, 2009-09-24 15:50:47+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/include/isc/mutex.h@1.4, 2009-09-24 15:50:47+00:00, davehart@shiny.ad.hartbrothers.com +17 -13 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/netdb.h@1.1, 2009-09-24 15:50:48+00:00, davehart@shiny.ad.hartbrothers.com +54 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/netdb.h@1.0, 2009-09-24 15:50:48+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/include/isc/ntgroups.h@1.1, 2009-09-24 15:50:48+00:00, davehart@shiny.ad.hartbrothers.com +35 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/ntgroups.h@1.0, 2009-09-24 15:50:48+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/include/isc/ntpaths.h@1.1, 2009-09-24 15:50:48+00:00, davehart@shiny.ad.hartbrothers.com +71 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/ntpaths.h@1.0, 2009-09-24 15:50:48+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/include/isc/offset.h@1.4, 2009-09-24 15:50:47+00:00, davehart@shiny.ad.hartbrothers.com +11 -12 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/once.h@1.4, 2009-09-24 15:50:47+00:00, davehart@shiny.ad.hartbrothers.com +10 -10 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/platform.h@1.5, 2009-09-24 15:50:47+00:00, davehart@shiny.ad.hartbrothers.com +26 -23 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/stat.h@1.3, 2009-09-24 15:50:47+00:00, davehart@shiny.ad.hartbrothers.com +3 -23 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/stdtime.h@1.1, 2009-09-24 15:50:48+00:00, davehart@shiny.ad.hartbrothers.com +58 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/stdtime.h@1.0, 2009-09-24 15:50:48+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/include/isc/strerror.h@1.4, 2009-09-24 15:50:47+00:00, davehart@shiny.ad.hartbrothers.com +10 -10 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/syslog.h@1.1, 2009-09-24 15:50:48+00:00, davehart@shiny.ad.hartbrothers.com +45 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/syslog.h@1.0, 2009-09-24 15:50:48+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/include/isc/thread.h@1.1, 2009-09-24 15:50:48+00:00, davehart@shiny.ad.hartbrothers.com +100 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/thread.h@1.0, 2009-09-24 15:50:48+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/include/isc/time.h@1.1, 2009-09-24 15:50:48+00:00, davehart@shiny.ad.hartbrothers.com +291 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/time.h@1.0, 2009-09-24 15:50:48+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/include/isc/win32os.h@1.4, 2009-09-24 15:50:47+00:00, davehart@shiny.ad.hartbrothers.com +11 -11 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/interfaceiter.c@1.10.1.2, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +11 -45 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/ipv6.c@1.1, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +27 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/ipv6.c@1.0, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/keyboard.c@1.1, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +89 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/keyboard.c@1.0, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/libisc.def@1.1, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +551 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/libisc.def@1.0, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/libisc.dsp@1.1, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +784 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/libisc.dsp@1.0, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/libisc.dsw@1.1, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +29 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/libisc.dsw@1.0, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/libisc.mak@1.1, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +2006 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/libisc.mak@1.0, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/net.c@1.11, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/netdb.h@1.1, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +187 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/netdb.h@1.0, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/ntgroups.c@1.1, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +186 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/ntgroups.c@1.0, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/ntpaths.c@1.1, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +140 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/ntpaths.c@1.0, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/once.c@1.4, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +15 -12 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/os.c@1.1, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +45 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/os.c@1.0, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/resource.c@1.1, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +72 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/resource.c@1.0, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/socket.c@1.1, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +3674 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/socket.c@1.0, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/stdio.c@1.1, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +117 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/stdio.c@1.0, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/stdtime.c@1.1, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +37 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/stdtime.c@1.0, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/strerror.c@1.10, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +71 -221 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/syslog.c@1.1, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +181 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/syslog.c@1.0, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/syslog.h@1.1, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +76 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/syslog.h@1.0, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/thread.c@1.1, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +90 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/thread.c@1.0, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/time.c@1.1, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +295 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/time.c@1.0, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/unistd.h@1.1, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +53 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/unistd.h@1.0, 2009-09-24 15:50:46+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/version.c@1.1, 2009-09-24 15:50:47+00:00, davehart@shiny.ad.hartbrothers.com +28 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/version.c@1.0, 2009-09-24 15:50:47+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/win32/win32os.c@1.4, 2009-09-24 15:50:45+00:00, davehart@shiny.ad.hartbrothers.com +11 -11 + bind-9.6.1-P1.tar.gz + + lib/isc/x86_32/include/isc/atomic.h@1.1, 2009-09-24 15:50:48+00:00, davehart@shiny.ad.hartbrothers.com +176 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/x86_32/include/isc/atomic.h@1.0, 2009-09-24 15:50:48+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/x86_64/include/isc/atomic.h@1.1, 2009-09-24 15:50:48+00:00, davehart@shiny.ad.hartbrothers.com +123 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/x86_64/include/isc/atomic.h@1.0, 2009-09-24 15:50:48+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + +ChangeSet@1.2006, 2009-09-24 07:52:55-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P219 + TAG: NTP_4_2_5P219 + + ChangeLog@1.445, 2009-09-24 07:52:26-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P219 + + ntpd/ntpd-opts.c@1.212, 2009-09-24 07:52:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P219 + + ntpd/ntpd-opts.h@1.212, 2009-09-24 07:52:29-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P219 + + ntpd/ntpd-opts.texi@1.210, 2009-09-24 07:52:30-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P219 + + ntpd/ntpd.1@1.210, 2009-09-24 07:52:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P219 + + ntpdc/ntpdc-opts.c@1.208, 2009-09-24 07:52:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P219 + + ntpdc/ntpdc-opts.h@1.208, 2009-09-24 07:52:32-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P219 + + ntpdc/ntpdc-opts.texi@1.207, 2009-09-24 07:52:33-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P219 + + ntpdc/ntpdc.1@1.207, 2009-09-24 07:52:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P219 + + ntpq/ntpq-opts.c@1.208, 2009-09-24 07:52:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P219 + + ntpq/ntpq-opts.h@1.208, 2009-09-24 07:52:36-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P219 + + ntpq/ntpq-opts.texi@1.207, 2009-09-24 07:52:38-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P219 + + ntpq/ntpq.1@1.207, 2009-09-24 07:52:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P219 + + ntpsnmpd/ntpsnmpd-opts.c@1.88, 2009-09-24 07:52:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P219 + + ntpsnmpd/ntpsnmpd-opts.h@1.88, 2009-09-24 07:52:40-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P219 + + ntpsnmpd/ntpsnmpd-opts.texi@1.88, 2009-09-24 07:52:42-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P219 + + ntpsnmpd/ntpsnmpd.1@1.88, 2009-09-24 07:52:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P219 + + packageinfo.sh@1.222, 2009-09-24 07:52:43-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P219 + + sntp/sntp-opts.c@1.82, 2009-09-24 07:52:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P219 + + sntp/sntp-opts.h@1.82, 2009-09-24 07:52:44-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P219 + + sntp/sntp-opts.texi@1.82, 2009-09-24 07:52:45-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P219 + + sntp/sntp.1@1.82, 2009-09-24 07:52:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P219 + + util/ntp-keygen-opts.c@1.211, 2009-09-24 07:52:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P219 + + util/ntp-keygen-opts.h@1.211, 2009-09-24 07:52:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P219 + + util/ntp-keygen-opts.texi@1.210, 2009-09-24 07:52:49-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P219 + + util/ntp-keygen.1@1.210, 2009-09-24 07:52:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P219 + +ChangeSet@1.2004.1.1, 2009-09-24 07:27:15+00:00, davehart@shiny.ad.hartbrothers.com +114 -0 + Reorganize our copy of libisc code to match BIND 9 tarball layout, preparing + for easier drop-in of newer libisc code in the future via a + "ntp-dev-libisc-upstream" repo which gets only unmodified ISC source, and is + pulled into ntp-dev allowing BK to assist with the merge of local changes in + the future. + + BitKeeper/deleted/.del-interfaceiter.c~554505c@1.4, 2009-09-24 07:20:59+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/libntp/interfaceiter.c -> BitKeeper/deleted/.del-interfaceiter.c~554505c + + BitKeeper/deleted/.del-strerror.c~7b58fc6b@1.3, 2009-09-24 07:21:01+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: libisc/strerror.c -> BitKeeper/deleted/.del-strerror.c~7b58fc6b + + Makefile.am@1.82, 2009-09-24 07:27:03+00:00, davehart@shiny.ad.hartbrothers.com +7 -4 + out with include/isc, in with lib/isc/include/isc and + lib/isc/unix/include/isc + + configure.ac@1.455, 2009-09-24 07:27:03+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + out with include/isc, in with lib/isc/include/isc and + lib/isc/unix/include/isc + + include/Makefile.am@1.35, 2009-09-24 07:27:03+00:00, davehart@shiny.ad.hartbrothers.com +0 -2 + out with include/isc, in with lib/isc/include/isc and + lib/isc/unix/include/isc + + lib/isc/assertions.c@1.3, 2009-09-24 07:21:02+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: libisc/assertions.c -> lib/isc/assertions.c + + lib/isc/error.c@1.3, 2009-09-24 07:21:04+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: libisc/error.c -> lib/isc/error.c + + lib/isc/include/isc/Makefile.am@1.9, 2009-09-24 07:27:03+00:00, davehart@shiny.ad.hartbrothers.com +3 -8 + out with include/isc, in with lib/isc/include/isc and + lib/isc/unix/include/isc + + lib/isc/include/isc/Makefile.am@1.8, 2009-09-24 07:20:57+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/Makefile.am -> lib/isc/include/isc/Makefile.am + + lib/isc/include/isc/app.h@1.3, 2009-09-24 07:21:02+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/app.h -> lib/isc/include/isc/app.h + + lib/isc/include/isc/assertions.h@1.3, 2009-09-24 07:20:56+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/assertions.h -> lib/isc/include/isc/assertions.h + + lib/isc/include/isc/boolean.h@1.3, 2009-09-24 07:21:04+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/boolean.h -> lib/isc/include/isc/boolean.h + + lib/isc/include/isc/buffer.h@1.3, 2009-09-24 07:21:06+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/buffer.h -> lib/isc/include/isc/buffer.h + + lib/isc/include/isc/error.h@1.3, 2009-09-24 07:21:02+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/error.h -> lib/isc/include/isc/error.h + + lib/isc/include/isc/file.h@1.3, 2009-09-24 07:21:03+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/file.h -> lib/isc/include/isc/file.h + + lib/isc/include/isc/formatcheck.h@1.3, 2009-09-24 07:20:57+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/formatcheck.h -> lib/isc/include/isc/formatcheck.h + + lib/isc/include/isc/interfaceiter.h@1.5, 2009-09-24 07:21:05+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/interfaceiter.h -> lib/isc/include/isc/interfaceiter.h + + lib/isc/include/isc/ipv6.h@1.8, 2009-09-24 07:20:59+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/ipv6.h -> lib/isc/include/isc/ipv6.h + + lib/isc/include/isc/lang.h@1.3, 2009-09-24 07:21:03+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/lang.h -> lib/isc/include/isc/lang.h + + lib/isc/include/isc/lib.h@1.3, 2009-09-24 07:21:04+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/lib.h -> lib/isc/include/isc/lib.h + + lib/isc/include/isc/list.h@1.3, 2009-09-24 07:20:59+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/list.h -> lib/isc/include/isc/list.h + + lib/isc/include/isc/log.h@1.2, 2009-09-24 07:21:06+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/log.h -> lib/isc/include/isc/log.h + + lib/isc/include/isc/magic.h@1.3, 2009-09-24 07:21:00+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/magic.h -> lib/isc/include/isc/magic.h + + lib/isc/include/isc/md5.h@1.2, 2009-09-24 07:21:05+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/md5.h -> lib/isc/include/isc/md5.h + + lib/isc/include/isc/mem.h@1.4, 2009-09-24 07:21:03+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/mem.h -> lib/isc/include/isc/mem.h + + lib/isc/include/isc/msgcat.h@1.3, 2009-09-24 07:21:04+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/msgcat.h -> lib/isc/include/isc/msgcat.h + + lib/isc/include/isc/msgs.h@1.4, 2009-09-24 07:20:58+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/msgs.h -> lib/isc/include/isc/msgs.h + + lib/isc/include/isc/mutex.h@1.3, 2009-09-24 07:21:04+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/mutex.h -> lib/isc/include/isc/mutex.h + + lib/isc/include/isc/netaddr.h@1.5, 2009-09-24 07:21:02+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/netaddr.h -> lib/isc/include/isc/netaddr.h + + lib/isc/include/isc/netscope.h@1.2, 2009-09-24 07:21:04+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/netscope.h -> lib/isc/include/isc/netscope.h + + lib/isc/include/isc/once.h@1.3, 2009-09-24 07:20:56+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/once.h -> lib/isc/include/isc/once.h + + lib/isc/include/isc/platform.h@1.3, 2009-09-24 07:21:05+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/platform.h -> lib/isc/include/isc/platform.h + + lib/isc/include/isc/print.h@1.3, 2009-09-24 07:20:56+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/print.h -> lib/isc/include/isc/print.h + + lib/isc/include/isc/region.h@1.2, 2009-09-24 07:20:56+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/region.h -> lib/isc/include/isc/region.h + + lib/isc/include/isc/result.h@1.4, 2009-09-24 07:21:04+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/result.h -> lib/isc/include/isc/result.h + + lib/isc/include/isc/sockaddr.h@1.4, 2009-09-24 07:20:59+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/sockaddr.h -> lib/isc/include/isc/sockaddr.h + + lib/isc/include/isc/stdio.h@1.2, 2009-09-24 07:21:03+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/stdio.h -> lib/isc/include/isc/stdio.h + + lib/isc/include/isc/string.h@1.3, 2009-09-24 07:21:02+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/string.h -> lib/isc/include/isc/string.h + + lib/isc/include/isc/types.h@1.3, 2009-09-24 07:21:00+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/types.h -> lib/isc/include/isc/types.h + + lib/isc/include/isc/util.h@1.3, 2009-09-24 07:21:02+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/util.h -> lib/isc/include/isc/util.h + + lib/isc/inet_aton.c@1.3, 2009-09-24 07:20:57+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: libisc/inet_aton.c -> lib/isc/inet_aton.c + + lib/isc/inet_ntop.c@1.6, 2009-09-24 07:21:01+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: libisc/inet_ntop.c -> lib/isc/inet_ntop.c + + lib/isc/inet_pton.c@1.3, 2009-09-24 07:20:59+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: libisc/inet_pton.c -> lib/isc/inet_pton.c + + lib/isc/lib.c@1.3, 2009-09-24 07:21:00+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: libisc/lib.c -> lib/isc/lib.c + + lib/isc/log.c@1.2, 2009-09-24 07:21:01+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: libisc/log.c -> lib/isc/log.c + + lib/isc/md5.c@1.2, 2009-09-24 07:21:00+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: libisc/md5.c -> lib/isc/md5.c + + lib/isc/mem.c@1.4, 2009-09-24 07:20:59+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: libisc/mem.c -> lib/isc/mem.c + + lib/isc/netaddr.c@1.5, 2009-09-24 07:21:02+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: libisc/netaddr.c -> lib/isc/netaddr.c + + lib/isc/netscope.c@1.2, 2009-09-24 07:21:03+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: libisc/netscope.c -> lib/isc/netscope.c + + lib/isc/nls/msgcat.c@1.5, 2009-09-24 07:21:41+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: lib/isc/msgcat.c -> lib/isc/nls/msgcat.c + + lib/isc/msgcat.c@1.4, 2009-09-24 07:21:06+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: libisc/msgcat.c -> lib/isc/msgcat.c + + lib/isc/sockaddr.c@1.7, 2009-09-24 07:20:59+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: libisc/sockaddr.c -> lib/isc/sockaddr.c + + lib/isc/unix/ifiter_getifaddrs.c@1.6, 2009-09-24 07:21:05+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: libisc/ifiter_getifaddrs.c -> lib/isc/unix/ifiter_getifaddrs.c + + lib/isc/unix/ifiter_ioctl.c@1.26, 2009-09-24 07:21:01+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: libisc/ifiter_ioctl.c -> lib/isc/unix/ifiter_ioctl.c + + lib/isc/unix/ifiter_sysctl.c@1.13, 2009-09-24 07:20:57+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: libisc/ifiter_sysctl.c -> lib/isc/unix/ifiter_sysctl.c + + lib/isc/unix/include/isc/Makefile.am@1.1, 2009-09-24 07:27:05+00:00, davehart@shiny.ad.hartbrothers.com +15 -0 + overlooked lib/isc/unix/include/isc + + lib/isc/unix/include/isc/Makefile.am@1.0, 2009-09-24 07:27:05+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + lib/isc/unix/include/isc/dir.h@1.2, 2009-09-24 07:20:57+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/dir.h -> lib/isc/unix/include/isc/dir.h + + lib/isc/unix/include/isc/int.h@1.3, 2009-09-24 07:20:58+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/int.h -> lib/isc/unix/include/isc/int.h + + lib/isc/unix/include/isc/net.h@1.9, 2009-09-24 07:20:59+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/net.h -> lib/isc/unix/include/isc/net.h + + lib/isc/unix/include/isc/offset.h@1.3, 2009-09-24 07:20:57+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/offset.h -> lib/isc/unix/include/isc/offset.h + + lib/isc/unix/include/isc/stat.h@1.2, 2009-09-24 07:21:05+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/stat.h -> lib/isc/unix/include/isc/stat.h + + lib/isc/unix/include/isc/strerror.h@1.3, 2009-09-24 07:21:01+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/strerror.h -> lib/isc/unix/include/isc/strerror.h + + lib/isc/unix/include/isc/time.h@1.2, 2009-09-24 07:20:57+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/isc/time.h -> lib/isc/unix/include/isc/time.h + + lib/isc/unix/interfaceiter.c@1.16, 2009-09-24 07:20:56+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: libisc/interfaceiter.c -> lib/isc/unix/interfaceiter.c + + lib/isc/unix/net.c@1.11, 2009-09-24 07:21:04+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: libisc/net.c -> lib/isc/unix/net.c + + lib/isc/unix/strerror.c@1.4, 2009-09-24 07:21:05+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: libisc/isc_strerror.c -> lib/isc/unix/strerror.c + + lib/isc/win32/include/isc/int.h@1.3, 2009-09-24 07:21:04+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/include/isc/int.h -> lib/isc/win32/include/isc/int.h + + lib/isc/win32/include/isc/ipv6.h@1.7, 2009-09-24 07:21:00+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/include/isc/ipv6.h -> lib/isc/win32/include/isc/ipv6.h + + lib/isc/win32/include/isc/mutex.h@1.3, 2009-09-24 07:20:59+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/include/isc/mutex.h -> lib/isc/win32/include/isc/mutex.h + + lib/isc/win32/include/isc/net.h@1.8, 2009-09-24 07:20:56+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/include/isc/net.h -> lib/isc/win32/include/isc/net.h + + lib/isc/win32/include/isc/offset.h@1.3, 2009-09-24 07:21:01+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/include/isc/offset.h -> lib/isc/win32/include/isc/offset.h + + lib/isc/win32/include/isc/once.h@1.3, 2009-09-24 07:20:58+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/include/isc/once.h -> lib/isc/win32/include/isc/once.h + + lib/isc/win32/include/isc/platform.h@1.4, 2009-09-24 07:20:57+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/include/isc/platform.h -> lib/isc/win32/include/isc/platform.h + + lib/isc/win32/include/isc/stat.h@1.2, 2009-09-24 07:21:01+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/include/isc/stat.h -> lib/isc/win32/include/isc/stat.h + + lib/isc/win32/include/isc/strerror.h@1.3, 2009-09-24 07:21:02+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/include/isc/strerror.h -> lib/isc/win32/include/isc/strerror.h + + lib/isc/win32/include/isc/win32os.h@1.3, 2009-09-24 07:21:00+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/include/isc/win32os.h -> lib/isc/win32/include/isc/win32os.h + + lib/isc/win32/interfaceiter.c@1.10.1.1, 2009-09-24 07:21:04+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/libisc/interfaceiter.c -> lib/isc/win32/interfaceiter.c + + lib/isc/win32/net.c@1.10, 2009-09-24 07:21:05+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/libisc/net.c -> lib/isc/win32/net.c + + lib/isc/win32/once.c@1.3, 2009-09-24 07:21:02+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/libisc/once.c -> lib/isc/win32/once.c + + lib/isc/win32/strerror.c@1.9, 2009-09-24 07:21:02+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/libisc/isc_strerror.c -> lib/isc/win32/strerror.c + + lib/isc/win32/win32os.c@1.3, 2009-09-24 07:21:01+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/libisc/win32os.c -> lib/isc/win32/win32os.c + + libntp/Makefile.am@1.44, 2009-09-24 07:27:03+00:00, davehart@shiny.ad.hartbrothers.com +16 -9 + Reorganize our copy of libisc code to match BIND 9 tarball layout + + libntp/bsd_strerror.c@1.5, 2009-09-24 07:21:03+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: libntp/strerror.c -> libntp/bsd_strerror.c + + libparse/Makefile.am@1.13, 2009-09-24 07:27:04+00:00, davehart@shiny.ad.hartbrothers.com +6 -1 + Reorganize our copy of libisc code to match BIND 9 tarball layout + + ntpd/Makefile.am@1.68, 2009-09-24 07:27:04+00:00, davehart@shiny.ad.hartbrothers.com +9 -1 + Reorganize our copy of libisc code to match BIND 9 tarball layout + + ntpdate/Makefile.am@1.17, 2009-09-24 07:27:04+00:00, davehart@shiny.ad.hartbrothers.com +5 -1 + Reorganize our copy of libisc code to match BIND 9 tarball layout + + ntpdc/Makefile.am@1.40, 2009-09-24 07:27:04+00:00, davehart@shiny.ad.hartbrothers.com +6 -1 + Reorganize our copy of libisc code to match BIND 9 tarball layout + + ntpq/Makefile.am@1.34, 2009-09-24 07:27:04+00:00, davehart@shiny.ad.hartbrothers.com +6 -1 + Reorganize our copy of libisc code to match BIND 9 tarball layout + + ntpsnmpd/Makefile.am@1.8, 2009-09-24 07:27:04+00:00, davehart@shiny.ad.hartbrothers.com +8 -2 + Reorganize our copy of libisc code to match BIND 9 tarball layout + + parseutil/Makefile.am@1.8, 2009-09-24 07:27:04+00:00, davehart@shiny.ad.hartbrothers.com +5 -1 + Reorganize our copy of libisc code to match BIND 9 tarball layout + + ports/winnt/vc6/libntp.dsp@1.42, 2009-09-24 07:27:04+00:00, davehart@shiny.ad.hartbrothers.com +18 -18 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vc6/ntpd.dsp@1.38, 2009-09-24 07:27:04+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vc6/ntpdate.dsp@1.22, 2009-09-24 07:27:04+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vc6/ntpdc.dsp@1.25, 2009-09-24 07:27:04+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vc6/ntpkeygen.dsp@1.18, 2009-09-24 07:27:04+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vc6/ntpq.dsp@1.26, 2009-09-24 07:27:04+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2003/libntp.vcproj@1.3, 2009-09-24 07:27:04+00:00, davehart@shiny.ad.hartbrothers.com +18 -18 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2003/ntpd.vcproj@1.3, 2009-09-24 07:27:04+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2003/ntpdate.vcproj@1.3, 2009-09-24 07:27:04+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2003/ntpdc.vcproj@1.3, 2009-09-24 07:27:04+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2003/ntpkeygen.vcproj@1.3, 2009-09-24 07:27:04+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2003/ntpq.vcproj@1.3, 2009-09-24 07:27:04+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2005/libntp.vcproj@1.3, 2009-09-24 07:27:05+00:00, davehart@shiny.ad.hartbrothers.com +18 -18 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2005/ntpd.vcproj@1.3, 2009-09-24 07:27:05+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2005/ntpdate.vcproj@1.3, 2009-09-24 07:27:05+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2005/ntpdc.vcproj@1.3, 2009-09-24 07:27:05+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2005/ntpkeygen.vcproj@1.3, 2009-09-24 07:27:05+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2005/ntpq.vcproj@1.3, 2009-09-24 07:27:05+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2008/libntp/libntp.vcproj@1.18, 2009-09-24 07:27:05+00:00, davehart@shiny.ad.hartbrothers.com +18 -36 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2008/ntp-keygen/ntp-keygen.vcproj@1.7, 2009-09-24 07:27:05+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.18, 2009-09-24 07:27:05+00:00, davehart@shiny.ad.hartbrothers.com +12 -12 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2008/ntpdate/ntpdate.vcproj@1.10, 2009-09-24 07:27:05+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2008/ntpdc/ntpdc.vcproj@1.10, 2009-09-24 07:27:05+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2008/ntpq/ntpq.vcproj@1.9, 2009-09-24 07:27:05+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + sntp/Makefile.am@1.11, 2009-09-24 07:27:05+00:00, davehart@shiny.ad.hartbrothers.com +7 -3 + out with include/isc, in with lib/isc/include/isc and + lib/isc/unix/include/isc + + util/Makefile.am@1.39, 2009-09-24 07:27:05+00:00, davehart@shiny.ad.hartbrothers.com +6 -1 + out with include/isc, in with lib/isc/include/isc and + lib/isc/unix/include/isc + +ChangeSet@1.2005, 2009-09-22 19:22:09+00:00, davehart@shiny.ad.hartbrothers.com +13 -0 + [Bug 1315] "interface ignore 0.0.0.0" is ignored. + add implicit "nic ignore all" rule before any rules from ntp.conf, so + "nic listen eth0" alone means the same as "-I eth0". + add wildcard match class for interface/nic rules. + fix mistaken carryover of prefixlen from one rule to the next. + Ensure IPv6 localhost address ::1 is included in libisc's Windows IPv6 + address enumeration, allowing ntpq and ntpdc's hardcoding to 127.0.0.1 + on Windows to end. + + ChangeLog@1.444, 2009-09-22 19:22:07+00:00, davehart@shiny.ad.hartbrothers.com +8 -0 + [Bug 1315] "interface ignore 0.0.0.0" is ignored. + add implicit "nic ignore all" rule before any rules from ntp.conf, so + "nic listen eth0" alone means the same as "-I eth0". + add wildcard match class for interface/nic rules. + fix mistaken carryover of prefixlen from one rule to the next. + Ensure IPv6 localhost address ::1 is included in libisc's Windows IPv6 + address enumeration, allowing ntpq and ntpdc's hardcoding to 127.0.0.1 + on Windows to end. + + include/ntp_io.h@1.12, 2009-09-22 19:22:07+00:00, davehart@shiny.ad.hartbrothers.com +4 -2 + add wildcard match class for interface/nic rules. + add sau_from_netaddr() prototype + + ntpd/ntp_config.c@1.220, 2009-09-22 19:22:07+00:00, davehart@shiny.ad.hartbrothers.com +26 -9 + fix mistaken carryover of prefixlen from one rule to the next. + add wildcard match class for interface/nic rules. + + ntpd/ntp_io.c@1.298, 2009-09-22 19:22:07+00:00, davehart@shiny.ad.hartbrothers.com +193 -76 + [Bug 1315] "interface ignore 0.0.0.0" is ignored. + add implicit "nic ignore all" rule before any rules from ntp.conf, so + "nic listen eth0" alone means the same as "-I eth0". + add wildcard match class for interface/nic rules. + + + ntpd/ntp_parser.c@1.49, 2009-09-22 19:22:07+00:00, davehart@shiny.ad.hartbrothers.com +595 -595 + Bison product + + ntpd/ntp_parser.h@1.30, 2009-09-22 19:22:07+00:00, davehart@shiny.ad.hartbrothers.com +33 -31 + Bison product + + ntpd/ntp_parser.y@1.44, 2009-09-22 19:22:08+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + add wildcard match class for interface/nic rules. + + ntpd/ntp_scanner.c@1.27, 2009-09-22 19:22:08+00:00, davehart@shiny.ad.hartbrothers.com +18 -9 + add wildcard match class for interface/nic rules. + better fix for Sunday's change to close-double-quote handling. + + ntpd/ntp_scanner.h@1.11, 2009-09-22 19:22:08+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + FOLLBY_TOKEN/FOLLBY_STRING use clarification comment + + ntpd/ntpd.c@1.108, 2009-09-22 19:22:08+00:00, davehart@shiny.ad.hartbrothers.com +0 -6 + add implicit "nic ignore all" rule before any rules from ntp.conf, so + "nic listen eth0" alone means the same as "-I eth0". + + ntpdc/ntpdc.c@1.70, 2009-09-22 19:22:08+00:00, davehart@shiny.ad.hartbrothers.com +0 -8 + Ensure IPv6 localhost address ::1 is included in libisc's Windows IPv6 + address enumeration, allowing ntpq and ntpdc's hardcoding to 127.0.0.1 + on Windows to end. + + ntpq/ntpq.c@1.91, 2009-09-22 19:22:08+00:00, davehart@shiny.ad.hartbrothers.com +0 -8 + Ensure IPv6 localhost address ::1 is included in libisc's Windows IPv6 + address enumeration, allowing ntpq and ntpdc's hardcoding to 127.0.0.1 + on Windows to end. + + ports/winnt/libisc/interfaceiter.c@1.11, 2009-09-22 19:22:08+00:00, davehart@shiny.ad.hartbrothers.com +72 -11 + Ensure IPv6 localhost address ::1 is included in libisc's Windows IPv6 + address enumeration, allowing ntpq and ntpdc's hardcoding to 127.0.0.1 + on Windows to end. + +ChangeSet@1.2004, 2009-09-21 07:51:38-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P218 + TAG: NTP_4_2_5P218 + + ChangeLog@1.443, 2009-09-21 07:51:09-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P218 + + ntpd/ntpd-opts.c@1.211, 2009-09-21 07:51:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P218 + + ntpd/ntpd-opts.h@1.211, 2009-09-21 07:51:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P218 + + ntpd/ntpd-opts.texi@1.209, 2009-09-21 07:51:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P218 + + ntpd/ntpd.1@1.209, 2009-09-21 07:51:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P218 + + ntpdc/ntpdc-opts.c@1.207, 2009-09-21 07:51:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P218 + + ntpdc/ntpdc-opts.h@1.207, 2009-09-21 07:51:15-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P218 + + ntpdc/ntpdc-opts.texi@1.206, 2009-09-21 07:51:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P218 + + ntpdc/ntpdc.1@1.206, 2009-09-21 07:51:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P218 + + ntpq/ntpq-opts.c@1.207, 2009-09-21 07:51:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P218 + + ntpq/ntpq-opts.h@1.207, 2009-09-21 07:51:19-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P218 + + ntpq/ntpq-opts.texi@1.206, 2009-09-21 07:51:20-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P218 + + ntpq/ntpq.1@1.206, 2009-09-21 07:51:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P218 + + ntpsnmpd/ntpsnmpd-opts.c@1.87, 2009-09-21 07:51:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P218 + + ntpsnmpd/ntpsnmpd-opts.h@1.87, 2009-09-21 07:51:22-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P218 + + ntpsnmpd/ntpsnmpd-opts.texi@1.87, 2009-09-21 07:51:23-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P218 + + ntpsnmpd/ntpsnmpd.1@1.87, 2009-09-21 07:51:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P218 + + packageinfo.sh@1.221, 2009-09-21 07:51:25-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P218 + + sntp/sntp-opts.c@1.81, 2009-09-21 07:51:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P218 + + sntp/sntp-opts.h@1.81, 2009-09-21 07:51:26-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P218 + + sntp/sntp-opts.texi@1.81, 2009-09-21 07:51:27-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P218 + + sntp/sntp.1@1.81, 2009-09-21 07:51:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P218 + + util/ntp-keygen-opts.c@1.210, 2009-09-21 07:51:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P218 + + util/ntp-keygen-opts.h@1.210, 2009-09-21 07:51:30-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P218 + + util/ntp-keygen-opts.texi@1.209, 2009-09-21 07:51:31-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P218 + + util/ntp-keygen.1@1.209, 2009-09-21 07:51:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P218 + +ChangeSet@1.2003, 2009-09-21 04:57:32+00:00, davehart@shiny.ad.hartbrothers.com +7 -0 + correct parsing and processing of setvar directive. + highlight location of ntpq :config syntax errors with ^. + + ChangeLog@1.442, 2009-09-21 04:57:31+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + correct parsing and processing of setvar directive. + highlight location of ntpq :config syntax errors with ^. + + include/ntp_config.h@1.63, 2009-09-21 04:57:31+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + correct parsing and processing of setvar directive. + + ntpd/ntp_config.c@1.219, 2009-09-21 04:57:31+00:00, davehart@shiny.ad.hartbrothers.com +62 -55 + correct parsing and processing of setvar directive. + + ntpd/ntp_scanner.c@1.26, 2009-09-21 04:57:31+00:00, davehart@shiny.ad.hartbrothers.com +35 -5 + correct parsing and processing of setvar directive. + + ntpd/ntp_scanner.h@1.10, 2009-09-21 04:57:31+00:00, davehart@shiny.ad.hartbrothers.com +7 -6 + correct parsing and processing of setvar directive. + + ntpq/ntpq-subs.c@1.37, 2009-09-21 04:57:31+00:00, davehart@shiny.ad.hartbrothers.com +25 -9 + highlight location of ntpq :config syntax errors with ^. + + ntpq/ntpq.h@1.8, 2009-09-21 04:57:31+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + expose interactive variable to ntpq-subs.c + +ChangeSet@1.2000.1.1, 2009-09-21 00:10:58+00:00, davehart@shiny.ad.hartbrothers.com +8 -0 + [Bug 1314] saveconfig emits -4 and -6 on when not given. + clarify (former) NO_ARG, SINGLE_ARG, MULTIPLE_ARG renaming to + FOLLBY_TOKEN, FOLLBY_STRING, FOLLBY_STRINGS_TO_EOC. + parser, saveconfig cleanup to store T_ identifiers in syntax tree. + + ChangeLog@1.439.1.1, 2009-09-21 00:10:57+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1314] saveconfig emits -4 and -6 on when not given. + clarify (former) NO_ARG, SINGLE_ARG, MULTIPLE_ARG renaming to + FOLLBY_TOKEN, FOLLBY_STRING, FOLLBY_STRINGS_TO_EOC. + parser, saveconfig cleanup to store T_ identifiers in syntax tree. + + include/ntp_config.h@1.62, 2009-09-21 00:10:57+00:00, davehart@shiny.ad.hartbrothers.com +8 -9 + parser, saveconfig cleanup to store T_ identifiers in syntax tree. + + ntpd/ntp_config.c@1.218, 2009-09-21 00:10:57+00:00, davehart@shiny.ad.hartbrothers.com +612 -947 + parser, saveconfig cleanup to store T_ identifiers in syntax tree. + move scanner's keyword table from ntp_config.c to ntp_scanner.c + + ntpd/ntp_parser.c@1.48, 2009-09-21 00:10:57+00:00, davehart@shiny.ad.hartbrothers.com +275 -466 + Bison product + + ntpd/ntp_parser.h@1.29, 2009-09-21 00:10:57+00:00, davehart@shiny.ad.hartbrothers.com +3 -3 + Bison output + + ntpd/ntp_parser.y@1.43, 2009-09-21 00:10:58+00:00, davehart@shiny.ad.hartbrothers.com +100 -96 + parser, saveconfig cleanup to store T_ identifiers in syntax tree. + + ntpd/ntp_scanner.c@1.25, 2009-09-21 00:10:58+00:00, davehart@shiny.ad.hartbrothers.com +269 -64 + clarify (former) NO_ARG, SINGLE_ARG, MULTIPLE_ARG renaming to + FOLLBY_TOKEN, FOLLBY_STRING, FOLLBY_STRINGS_TO_EOC. + move scanner's keyword table from ntp_config.c to ntp_scanner.c + + ntpd/ntp_scanner.h@1.9, 2009-09-21 00:10:58+00:00, davehart@shiny.ad.hartbrothers.com +25 -9 + clarify (former) NO_ARG, SINGLE_ARG, MULTIPLE_ARG renaming to + FOLLBY_TOKEN, FOLLBY_STRING, FOLLBY_STRINGS_TO_EOC. + +ChangeSet@1.2001, 2009-09-20 07:51:55-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P217 + TAG: NTP_4_2_5P217 + + ChangeLog@1.440, 2009-09-20 07:51:25-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P217 + + ntpd/ntpd-opts.c@1.210, 2009-09-20 07:51:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P217 + + ntpd/ntpd-opts.h@1.210, 2009-09-20 07:51:28-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P217 + + ntpd/ntpd-opts.texi@1.208, 2009-09-20 07:51:29-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P217 + + ntpd/ntpd.1@1.208, 2009-09-20 07:51:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P217 + + ntpdc/ntpdc-opts.c@1.206, 2009-09-20 07:51:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P217 + + ntpdc/ntpdc-opts.h@1.206, 2009-09-20 07:51:32-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P217 + + ntpdc/ntpdc-opts.texi@1.205, 2009-09-20 07:51:33-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P217 + + ntpdc/ntpdc.1@1.205, 2009-09-20 07:51:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P217 + + ntpq/ntpq-opts.c@1.206, 2009-09-20 07:51:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P217 + + ntpq/ntpq-opts.h@1.206, 2009-09-20 07:51:36-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P217 + + ntpq/ntpq-opts.texi@1.205, 2009-09-20 07:51:37-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P217 + + ntpq/ntpq.1@1.205, 2009-09-20 07:51:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P217 + + ntpsnmpd/ntpsnmpd-opts.c@1.86, 2009-09-20 07:51:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P217 + + ntpsnmpd/ntpsnmpd-opts.h@1.86, 2009-09-20 07:51:40-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P217 + + ntpsnmpd/ntpsnmpd-opts.texi@1.86, 2009-09-20 07:51:41-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P217 + + ntpsnmpd/ntpsnmpd.1@1.86, 2009-09-20 07:51:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P217 + + packageinfo.sh@1.220, 2009-09-20 07:51:43-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P217 + + sntp/sntp-opts.c@1.80, 2009-09-20 07:51:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P217 + + sntp/sntp-opts.h@1.80, 2009-09-20 07:51:44-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P217 + + sntp/sntp-opts.texi@1.80, 2009-09-20 07:51:46-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P217 + + sntp/sntp.1@1.80, 2009-09-20 07:51:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P217 + + util/ntp-keygen-opts.c@1.209, 2009-09-20 07:51:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P217 + + util/ntp-keygen-opts.h@1.209, 2009-09-20 07:51:48-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P217 + + util/ntp-keygen-opts.texi@1.208, 2009-09-20 07:51:49-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P217 + + util/ntp-keygen.1@1.208, 2009-09-20 07:51:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P217 + +ChangeSet@1.2000, 2009-09-19 16:52:44+00:00, davehart@shiny.ad.hartbrothers.com +9 -0 + [Bug 1300] reject remote configuration of dangerous items. + + ChangeLog@1.439, 2009-09-19 16:52:43+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1300] reject remote configuration of dangerous items. + + include/ntpd.h@1.134, 2009-09-19 16:52:43+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1300] reject remote configuration of dangerous items. + + ntpd/ntp_config.c@1.217, 2009-09-19 16:52:43+00:00, davehart@shiny.ad.hartbrothers.com +43 -10 + [Bug 1300] reject remote configuration of dangerous items. + + ntpd/ntp_control.c@1.123, 2009-09-19 16:52:43+00:00, davehart@shiny.ad.hartbrothers.com +61 -74 + [Bug 1300] reject remote configuration of dangerous items. + + ntpd/ntp_parser.c@1.47, 2009-09-19 16:52:43+00:00, davehart@shiny.ad.hartbrothers.com +838 -743 + Bison output + + ntpd/ntp_parser.h@1.28, 2009-09-19 16:52:43+00:00, davehart@shiny.ad.hartbrothers.com +87 -85 + Bison output + + ntpd/ntp_parser.y@1.42, 2009-09-19 16:52:43+00:00, davehart@shiny.ad.hartbrothers.com +106 -17 + [Bug 1300] reject remote configuration of dangerous items. + + ntpd/refclock_palisade.c@1.31, 2009-09-19 16:52:44+00:00, davehart@shiny.ad.hartbrothers.com +2 -5 + un-revert another earlier fix (no need for Windows-specific COM%d:) + + ntpq/ntpq-subs.c@1.36, 2009-09-19 16:52:44+00:00, davehart@shiny.ad.hartbrothers.com +19 -15 + trim one trailing newline from :config response + +ChangeSet@1.1999, 2009-09-19 07:53:27-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P216 + TAG: NTP_4_2_5P216 + + ChangeLog@1.438, 2009-09-19 07:52:57-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P216 + + ntpd/ntpd-opts.c@1.209, 2009-09-19 07:52:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P216 + + ntpd/ntpd-opts.h@1.209, 2009-09-19 07:52:59-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P216 + + ntpd/ntpd-opts.texi@1.207, 2009-09-19 07:53:00-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P216 + + ntpd/ntpd.1@1.207, 2009-09-19 07:53:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P216 + + ntpdc/ntpdc-opts.c@1.205, 2009-09-19 07:53:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P216 + + ntpdc/ntpdc-opts.h@1.205, 2009-09-19 07:53:03-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P216 + + ntpdc/ntpdc-opts.texi@1.204, 2009-09-19 07:53:05-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P216 + + ntpdc/ntpdc.1@1.204, 2009-09-19 07:53:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P216 + + ntpq/ntpq-opts.c@1.205, 2009-09-19 07:53:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P216 + + ntpq/ntpq-opts.h@1.205, 2009-09-19 07:53:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P216 + + ntpq/ntpq-opts.texi@1.204, 2009-09-19 07:53:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P216 + + ntpq/ntpq.1@1.204, 2009-09-19 07:53:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P216 + + ntpsnmpd/ntpsnmpd-opts.c@1.85, 2009-09-19 07:53:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P216 + + ntpsnmpd/ntpsnmpd-opts.h@1.85, 2009-09-19 07:53:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P216 + + ntpsnmpd/ntpsnmpd-opts.texi@1.85, 2009-09-19 07:53:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P216 + + ntpsnmpd/ntpsnmpd.1@1.85, 2009-09-19 07:53:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P216 + + packageinfo.sh@1.219, 2009-09-19 07:53:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P216 + + sntp/sntp-opts.c@1.79, 2009-09-19 07:53:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P216 + + sntp/sntp-opts.h@1.79, 2009-09-19 07:53:16-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P216 + + sntp/sntp-opts.texi@1.79, 2009-09-19 07:53:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P216 + + sntp/sntp.1@1.79, 2009-09-19 07:53:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P216 + + util/ntp-keygen-opts.c@1.208, 2009-09-19 07:53:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P216 + + util/ntp-keygen-opts.h@1.208, 2009-09-19 07:53:19-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P216 + + util/ntp-keygen-opts.texi@1.207, 2009-09-19 07:53:21-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P216 + + util/ntp-keygen.1@1.207, 2009-09-19 07:53:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P216 + +ChangeSet@1.1998, 2009-09-19 06:21:08+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + CID 10 missing free(up); in refclock_palisade.c error return, again. + CID 83 added assertion to demonstrate config_nic_rules() does not + call strchr(NULL, '/'). + + ChangeLog@1.437, 2009-09-19 06:21:07+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + CID 10 missing free(up); in refclock_palisade.c error return, again. + CID 83 added assertion to demonstrate config_nic_rules() does not + call strchr(NULL, '/'). + + ntpd/ntp_config.c@1.216, 2009-09-19 06:21:07+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + CID 83 added assertion to demonstrate config_nic_rules() does not + call strchr(NULL, '/'). + + ntpd/refclock_palisade.c@1.30, 2009-09-19 06:21:08+00:00, davehart@shiny.ad.hartbrothers.com +3 -9 + CID 10 missing free(up); in refclock_palisade.c error return, again. + +ChangeSet@1.1997, 2009-09-19 02:18:44+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + [Bug 1312] ntpq/ntpdc MD5 passwords truncated to 8 chars on Suns. + + ChangeLog@1.436, 2009-09-19 02:18:43+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1312] ntpq/ntpdc MD5 passwords truncated to 8 chars on Suns. + + configure.ac@1.454, 2009-09-19 02:18:43+00:00, davehart@shiny.ad.hartbrothers.com +16 -0 + [Bug 1312] ntpq/ntpdc MD5 passwords truncated to 8 chars on Suns. + + include/ntp_stdlib.h@1.32, 2009-09-19 02:18:43+00:00, davehart@shiny.ad.hartbrothers.com +4 -3 + make #include "ntp_stdlib.h" all that's needed to use msyslog() by + including ntp_syslog.h from ntp_stdlib.h + + ntpdc/ntpdc.c@1.69, 2009-09-19 02:18:43+00:00, davehart@shiny.ad.hartbrothers.com +12 -4 + [Bug 1312] ntpq/ntpdc MD5 passwords truncated to 8 chars on Suns. + Clean up authenticated request codepath. + + ntpq/ntpq.c@1.90, 2009-09-19 02:18:43+00:00, davehart@shiny.ad.hartbrothers.com +13 -17 + [Bug 1312] ntpq/ntpdc MD5 passwords truncated to 8 chars on Suns. + Clean up authenticated request codepath. + Remove unneeded SYS_WINNT libntp workarounds from last century. + +ChangeSet@1.1996, 2009-09-18 07:51:03-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P215 + TAG: NTP_4_2_5P215 + + ChangeLog@1.435, 2009-09-18 07:50:36-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P215 + + ntpd/ntpd-opts.c@1.208, 2009-09-18 07:50:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P215 + + ntpd/ntpd-opts.h@1.208, 2009-09-18 07:50:38-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P215 + + ntpd/ntpd-opts.texi@1.206, 2009-09-18 07:50:39-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P215 + + ntpd/ntpd.1@1.206, 2009-09-18 07:50:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P215 + + ntpdc/ntpdc-opts.c@1.204, 2009-09-18 07:50:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P215 + + ntpdc/ntpdc-opts.h@1.204, 2009-09-18 07:50:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P215 + + ntpdc/ntpdc-opts.texi@1.203, 2009-09-18 07:50:43-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P215 + + ntpdc/ntpdc.1@1.203, 2009-09-18 07:50:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P215 + + ntpq/ntpq-opts.c@1.204, 2009-09-18 07:50:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P215 + + ntpq/ntpq-opts.h@1.204, 2009-09-18 07:50:46-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P215 + + ntpq/ntpq-opts.texi@1.203, 2009-09-18 07:50:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P215 + + ntpq/ntpq.1@1.203, 2009-09-18 07:50:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P215 + + ntpsnmpd/ntpsnmpd-opts.c@1.84, 2009-09-18 07:50:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P215 + + ntpsnmpd/ntpsnmpd-opts.h@1.84, 2009-09-18 07:50:50-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P215 + + ntpsnmpd/ntpsnmpd-opts.texi@1.84, 2009-09-18 07:50:51-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P215 + + ntpsnmpd/ntpsnmpd.1@1.84, 2009-09-18 07:50:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P215 + + packageinfo.sh@1.218, 2009-09-18 07:50:52-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P215 + + sntp/sntp-opts.c@1.78, 2009-09-18 07:50:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P215 + + sntp/sntp-opts.h@1.78, 2009-09-18 07:50:54-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P215 + + sntp/sntp-opts.texi@1.78, 2009-09-18 07:50:55-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P215 + + sntp/sntp.1@1.78, 2009-09-18 07:50:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P215 + + util/ntp-keygen-opts.c@1.207, 2009-09-18 07:50:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P215 + + util/ntp-keygen-opts.h@1.207, 2009-09-18 07:50:57-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P215 + + util/ntp-keygen-opts.texi@1.206, 2009-09-18 07:50:58-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P215 + + util/ntp-keygen.1@1.206, 2009-09-18 07:50:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P215 + +ChangeSet@1.1995, 2009-09-17 23:25:59-04:00, stenn@pogo.udel.edu +1 -0 + [Bug 1292] Workaround last VC6 unsigned __int64 kink + + ChangeLog@1.434, 2009-09-17 23:25:47-04:00, stenn@pogo.udel.edu +1 -0 + [Bug 1292] Workaround last VC6 unsigned __int64 kink + +ChangeSet@1.1994, 2009-09-17 15:28:57+02:00, burnicki@pogo.udel.edu +1 -0 + [Bug 1292] Workaround last VC6 unsigned __int64 kink. + + ports/winnt/ntpd/nt_clockstuff.c@1.36, 2009-09-17 15:28:57+02:00, burnicki@pogo.udel.edu +1 -1 + [Bug 1292] Workaround last VC6 unsigned __int64 kink. + +ChangeSet@1.1993, 2009-09-17 07:55:35-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P214 + TAG: NTP_4_2_5P214 + + ChangeLog@1.433, 2009-09-17 07:55:02-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P214 + + ntpd/ntpd-opts.c@1.207, 2009-09-17 07:55:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P214 + + ntpd/ntpd-opts.h@1.207, 2009-09-17 07:55:05-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P214 + + ntpd/ntpd-opts.texi@1.205, 2009-09-17 07:55:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P214 + + ntpd/ntpd.1@1.205, 2009-09-17 07:55:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P214 + + ntpdc/ntpdc-opts.c@1.203, 2009-09-17 07:55:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P214 + + ntpdc/ntpdc-opts.h@1.203, 2009-09-17 07:55:09-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P214 + + ntpdc/ntpdc-opts.texi@1.202, 2009-09-17 07:55:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P214 + + ntpdc/ntpdc.1@1.202, 2009-09-17 07:55:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P214 + + ntpq/ntpq-opts.c@1.203, 2009-09-17 07:55:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P214 + + ntpq/ntpq-opts.h@1.203, 2009-09-17 07:55:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P214 + + ntpq/ntpq-opts.texi@1.202, 2009-09-17 07:55:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P214 + + ntpq/ntpq.1@1.202, 2009-09-17 07:55:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P214 + + ntpsnmpd/ntpsnmpd-opts.c@1.83, 2009-09-17 07:55:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P214 + + ntpsnmpd/ntpsnmpd-opts.h@1.83, 2009-09-17 07:55:16-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P214 + + ntpsnmpd/ntpsnmpd-opts.texi@1.83, 2009-09-17 07:55:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P214 + + ntpsnmpd/ntpsnmpd.1@1.83, 2009-09-17 07:55:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P214 + + packageinfo.sh@1.217, 2009-09-17 07:55:18-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P214 + + sntp/sntp-opts.c@1.77, 2009-09-17 07:55:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P214 + + sntp/sntp-opts.h@1.77, 2009-09-17 07:55:21-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P214 + + sntp/sntp-opts.texi@1.77, 2009-09-17 07:55:22-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P214 + + sntp/sntp.1@1.77, 2009-09-17 07:55:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P214 + + util/ntp-keygen-opts.c@1.206, 2009-09-17 07:55:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P214 + + util/ntp-keygen-opts.h@1.206, 2009-09-17 07:55:25-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P214 + + util/ntp-keygen-opts.texi@1.205, 2009-09-17 07:55:27-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P214 + + util/ntp-keygen.1@1.205, 2009-09-17 07:55:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P214 + +ChangeSet@1.1992, 2009-09-17 01:31:14+00:00, davehart@shiny.ad.hartbrothers.com +8 -0 + [Bug 1303] remove top-level "autokey" directive. + correct "checking" message for --disable-bug1243-fix. + use "nic listen 192.168.0.0/16" instead of + "nic listen 192.168.0.0 prefixlen 16" + + ChangeLog@1.432, 2009-09-17 01:31:12+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1303] remove top-level "autokey" directive. + use "nic listen 192.168.0.0/16" instead of + "nic listen 192.168.0.0 prefixlen 16". + + configure.ac@1.453, 2009-09-17 01:31:12+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + correct "checking" message for --disable-bug1243-fix. + + html/miscopt.html@1.48, 2009-09-17 01:31:12+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + use "nic listen 192.168.0.0/16" instead of + "nic listen 192.168.0.0 prefixlen 16". + + include/ntp_config.h@1.61, 2009-09-17 01:31:12+00:00, davehart@shiny.ad.hartbrothers.com +1 -3 + [Bug 1303] remove top-level "autokey" directive. + + ntpd/ntp_config.c@1.215, 2009-09-17 01:31:12+00:00, davehart@shiny.ad.hartbrothers.com +28 -10 + use "nic listen 192.168.0.0/16" instead of + "nic listen 192.168.0.0 prefixlen 16". + + ntpd/ntp_parser.c@1.46, 2009-09-17 01:31:13+00:00, davehart@shiny.ad.hartbrothers.com +758 -789 + Bison output + + ntpd/ntp_parser.h@1.27, 2009-09-17 01:31:13+00:00, davehart@shiny.ad.hartbrothers.com +103 -105 + use "nic listen 192.168.0.0/16" instead of + "nic listen 192.168.0.0 prefixlen 16". + + ntpd/ntp_parser.y@1.41, 2009-09-17 01:31:13+00:00, davehart@shiny.ad.hartbrothers.com +4 -12 + [Bug 1303] remove top-level "autokey" directive. + use "nic listen 192.168.0.0/16" instead of + "nic listen 192.168.0.0 prefixlen 16". + +ChangeSet@1.1991, 2009-09-16 07:51:15-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P213 + TAG: NTP_4_2_5P213 + + ChangeLog@1.431, 2009-09-16 07:50:44-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P213 + + ntpd/ntpd-opts.c@1.206, 2009-09-16 07:50:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P213 + + ntpd/ntpd-opts.h@1.206, 2009-09-16 07:50:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P213 + + ntpd/ntpd-opts.texi@1.204, 2009-09-16 07:50:48-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P213 + + ntpd/ntpd.1@1.204, 2009-09-16 07:50:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P213 + + ntpdc/ntpdc-opts.c@1.202, 2009-09-16 07:50:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P213 + + ntpdc/ntpdc-opts.h@1.202, 2009-09-16 07:50:50-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P213 + + ntpdc/ntpdc-opts.texi@1.201, 2009-09-16 07:50:51-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P213 + + ntpdc/ntpdc.1@1.201, 2009-09-16 07:50:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P213 + + ntpq/ntpq-opts.c@1.202, 2009-09-16 07:50:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P213 + + ntpq/ntpq-opts.h@1.202, 2009-09-16 07:50:54-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P213 + + ntpq/ntpq-opts.texi@1.201, 2009-09-16 07:50:55-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P213 + + ntpq/ntpq.1@1.201, 2009-09-16 07:50:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P213 + + ntpsnmpd/ntpsnmpd-opts.c@1.82, 2009-09-16 07:50:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P213 + + ntpsnmpd/ntpsnmpd-opts.h@1.82, 2009-09-16 07:50:57-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P213 + + ntpsnmpd/ntpsnmpd-opts.texi@1.82, 2009-09-16 07:50:58-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P213 + + ntpsnmpd/ntpsnmpd.1@1.82, 2009-09-16 07:50:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P213 + + packageinfo.sh@1.216, 2009-09-16 07:51:00-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P213 + + sntp/sntp-opts.c@1.76, 2009-09-16 07:51:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P213 + + sntp/sntp-opts.h@1.76, 2009-09-16 07:51:01-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P213 + + sntp/sntp-opts.texi@1.76, 2009-09-16 07:51:02-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P213 + + sntp/sntp.1@1.76, 2009-09-16 07:51:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P213 + + util/ntp-keygen-opts.c@1.205, 2009-09-16 07:51:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P213 + + util/ntp-keygen-opts.h@1.205, 2009-09-16 07:51:05-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P213 + + util/ntp-keygen-opts.texi@1.204, 2009-09-16 07:51:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P213 + + util/ntp-keygen.1@1.204, 2009-09-16 07:51:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P213 + +ChangeSet@1.1988.1.1, 2009-09-15 13:08:48-04:00, murray@pogo.udel.edu +2 -0 + refclock_palisade.c, ChangeLog: + Fix for bug 1310 + + ChangeLog@1.428.1.1, 2009-09-15 13:07:14-04:00, murray@pogo.udel.edu +1 -0 + Fix for bug 1310 + + ntpd/refclock_palisade.c@1.29, 2009-09-15 13:08:12-04:00, murray@pogo.udel.edu +12 -9 + Fix for bug 1310 + +ChangeSet@1.1989, 2009-09-15 07:57:12-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P212 + TAG: NTP_4_2_5P212 + + ChangeLog@1.429, 2009-09-15 07:56:46-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P212 + + ntpd/ntpd-opts.c@1.205, 2009-09-15 07:56:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P212 + + ntpd/ntpd-opts.h@1.205, 2009-09-15 07:56:48-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P212 + + ntpd/ntpd-opts.texi@1.203, 2009-09-15 07:56:48-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P212 + + ntpd/ntpd.1@1.203, 2009-09-15 07:56:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P212 + + ntpdc/ntpdc-opts.c@1.201, 2009-09-15 07:56:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P212 + + ntpdc/ntpdc-opts.h@1.201, 2009-09-15 07:56:51-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P212 + + ntpdc/ntpdc-opts.texi@1.200, 2009-09-15 07:56:53-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P212 + + ntpdc/ntpdc.1@1.200, 2009-09-15 07:56:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P212 + + ntpq/ntpq-opts.c@1.201, 2009-09-15 07:56:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P212 + + ntpq/ntpq-opts.h@1.201, 2009-09-15 07:56:56-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P212 + + ntpq/ntpq-opts.texi@1.200, 2009-09-15 07:56:57-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P212 + + ntpq/ntpq.1@1.200, 2009-09-15 07:56:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P212 + + ntpsnmpd/ntpsnmpd-opts.c@1.81, 2009-09-15 07:56:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P212 + + ntpsnmpd/ntpsnmpd-opts.h@1.81, 2009-09-15 07:56:59-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P212 + + ntpsnmpd/ntpsnmpd-opts.texi@1.81, 2009-09-15 07:57:00-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P212 + + ntpsnmpd/ntpsnmpd.1@1.81, 2009-09-15 07:57:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P212 + + packageinfo.sh@1.215, 2009-09-15 07:57:01-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P212 + + sntp/sntp-opts.c@1.75, 2009-09-15 07:57:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P212 + + sntp/sntp-opts.h@1.75, 2009-09-15 07:57:03-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P212 + + sntp/sntp-opts.texi@1.75, 2009-09-15 07:57:03-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P212 + + sntp/sntp.1@1.75, 2009-09-15 07:57:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P212 + + util/ntp-keygen-opts.c@1.204, 2009-09-15 07:57:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P212 + + util/ntp-keygen-opts.h@1.204, 2009-09-15 07:57:06-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P212 + + util/ntp-keygen-opts.texi@1.203, 2009-09-15 07:57:07-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P212 + + util/ntp-keygen.1@1.203, 2009-09-15 07:57:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P212 + +ChangeSet@1.1988, 2009-09-15 03:49:51-04:00, stenn@whimsy.udel.edu +1 -0 + Typo cleanup + + ChangeLog@1.428, 2009-09-15 03:49:37-04:00, stenn@whimsy.udel.edu +1 -2 + Typo cleanup + +ChangeSet@1.1987, 2009-09-15 07:25:11+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1311] 4.2.5p211 doesn't build in no-debug mode. + + ChangeLog@1.427, 2009-09-15 07:25:10+00:00, davehart@shiny.ad.hartbrothers.com +3 -1 + [Bug 1311] 4.2.5p211 doesn't build in no-debug mode. + + ntpd/refclock_palisade.c@1.28, 2009-09-15 07:25:10+00:00, davehart@shiny.ad.hartbrothers.com +73 -68 + [Bug 1311] 4.2.5p211 doesn't build in no-debug mode. + convert leading whitespace to tabs + + ntpd/refclock_palisade.h@1.13, 2009-09-15 07:25:10+00:00, davehart@shiny.ad.hartbrothers.com +12 -10 + convert leading whitespace to tabs + +ChangeSet@1.1984.1.3, 2009-09-15 02:21:46-04:00, stenn@whimsy.udel.edu +3 -0 + Documentation updates from Dave Mills + + ChangeLog@1.421.2.6, 2009-09-15 02:21:33-04:00, stenn@whimsy.udel.edu +1 -0 + Documentation updates from Dave Mills + + html/authopt.html@1.51, 2009-09-15 02:13:00-04:00, stenn@whimsy.udel.edu +2 -2 + Documentation updates from Dave Mills + + html/miscopt.html@1.43.1.1, 2009-09-15 02:13:04-04:00, stenn@whimsy.udel.edu +2 -2 + Documentation updates from Dave Mills + +ChangeSet@1.1984.1.2, 2009-09-15 01:28:52-04:00, stenn@whimsy.udel.edu +5 -0 + Make the code agree with the spec and the book (Dave Mills) + + ChangeLog@1.421.2.5, 2009-09-15 01:25:29-04:00, stenn@whimsy.udel.edu +1 -0 + Make the code agree with the spec and the book (Dave Mills) + + include/ntp.h@1.163, 2009-09-15 01:25:42-04:00, stenn@whimsy.udel.edu +1 -1 + Make the code agree with the spec and the book (Dave Mills) + + libntp/systime.c@1.48, 2009-09-15 01:26:13-04:00, stenn@whimsy.udel.edu +24 -19 + Make the code agree with the spec and the book (Dave Mills) + + ntpd/ntp_proto.c@1.293, 2009-09-15 01:26:37-04:00, stenn@whimsy.udel.edu +22 -29 + Make the code agree with the spec and the book (Dave Mills) + + ntpd/ntp_timer.c@1.55, 2009-09-15 01:26:41-04:00, stenn@whimsy.udel.edu +1 -1 + Make the code agree with the spec and the book (Dave Mills) + +ChangeSet@1.1984.1.1, 2009-09-14 07:52:01-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P211 + TAG: NTP_4_2_5P211 + + ChangeLog@1.421.2.4, 2009-09-14 07:51:34-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P211 + + ntpd/ntpd-opts.c@1.204, 2009-09-14 07:51:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P211 + + ntpd/ntpd-opts.h@1.204, 2009-09-14 07:51:37-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P211 + + ntpd/ntpd-opts.texi@1.202, 2009-09-14 07:51:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P211 + + ntpd/ntpd.1@1.202, 2009-09-14 07:51:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P211 + + ntpdc/ntpdc-opts.c@1.200, 2009-09-14 07:51:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P211 + + ntpdc/ntpdc-opts.h@1.200, 2009-09-14 07:51:40-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P211 + + ntpdc/ntpdc-opts.texi@1.199, 2009-09-14 07:51:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P211 + + ntpdc/ntpdc.1@1.199, 2009-09-14 07:51:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P211 + + ntpq/ntpq-opts.c@1.200, 2009-09-14 07:51:43-04:00, stenn@whimsy.udel.edu +12 -6 + NTP_4_2_5P211 + + ntpq/ntpq-opts.h@1.200, 2009-09-14 07:51:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P211 + + ntpq/ntpq-opts.texi@1.199, 2009-09-14 07:51:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P211 + + ntpq/ntpq.1@1.199, 2009-09-14 07:51:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P211 + + ntpsnmpd/ntpsnmpd-opts.c@1.80, 2009-09-14 07:51:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P211 + + ntpsnmpd/ntpsnmpd-opts.h@1.80, 2009-09-14 07:51:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P211 + + ntpsnmpd/ntpsnmpd-opts.texi@1.80, 2009-09-14 07:51:48-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P211 + + ntpsnmpd/ntpsnmpd.1@1.80, 2009-09-14 07:51:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P211 + + packageinfo.sh@1.214, 2009-09-14 07:51:49-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P211 + + sntp/sntp-opts.c@1.74, 2009-09-14 07:51:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P211 + + sntp/sntp-opts.h@1.74, 2009-09-14 07:51:50-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P211 + + sntp/sntp-opts.texi@1.74, 2009-09-14 07:51:51-04:00, stenn@whimsy.udel.edu +51 -2 + NTP_4_2_5P211 + + sntp/sntp.1@1.74, 2009-09-14 07:51:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P211 + + util/ntp-keygen-opts.c@1.203, 2009-09-14 07:51:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P211 + + util/ntp-keygen-opts.h@1.203, 2009-09-14 07:51:53-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P211 + + util/ntp-keygen-opts.texi@1.202, 2009-09-14 07:51:54-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P211 + + util/ntp-keygen.1@1.202, 2009-09-14 07:51:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P211 + +ChangeSet@1.1983, 2009-09-14 03:30:37-04:00, stenn@pogo.udel.edu +1 -0 + [Bug 1296] Added Support for Trimble Acutime Gold + + ChangeLog@1.421.4.1, 2009-09-14 03:30:22-04:00, stenn@pogo.udel.edu +1 -0 + [Bug 1296] Added Support for Trimble Acutime Gold + +ChangeSet@1.1981.4.1, 2009-09-12 11:54:54+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1292] more VC6 unsigned __int64 workarounds. + + ChangeLog@1.421.3.1, 2009-09-12 11:54:53+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1292] more VC6 unsigned __int64 workarounds. + + ports/winnt/ntpd/nt_clockstuff.c@1.35, 2009-09-12 11:54:54+00:00, davehart@shiny.ad.hartbrothers.com +11 -4 + [Bug 1292] more VC6 unsigned __int64 workarounds. + +ChangeSet@1.1981.3.1, 2009-09-12 07:25:45+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 663] respect ntpq -c and -p order on command line. + + ChangeLog@1.421.2.1, 2009-09-12 07:25:44+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 663] respect ntpq -c and -p order on command line. + + ntpq/ntpq-opts.def@1.13, 2009-09-12 07:25:44+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + [Bug 663] respect ntpq -c and -p order on command line. + + ntpq/ntpq.c@1.89, 2009-09-12 07:25:44+00:00, davehart@shiny.ad.hartbrothers.com +37 -13 + [Bug 663] respect ntpq -c and -p order on command line. + +ChangeSet@1.1981.2.1, 2009-09-11 06:55:37+00:00, davehart@shiny.ad.hartbrothers.com +9 -0 + [Bug 1243] MD5auth_setkey zero-fills key from first zero octet. + [Bug 1295] leftover fix, do not crash on exit in free_config_trap() + when "trap 1.2.3.4" is used without any further options. + CID 79: kod_init_kod_db() fails to fclose(db_s) in two error paths. + CID 80: attempt to quiet Coverity false positive re: leaking "reason" + in main(). + CID 81: savedconfig leaked in save_config(). + + ChangeLog@1.421.1.1, 2009-09-11 06:55:36+00:00, davehart@shiny.ad.hartbrothers.com +7 -0 + [Bug 1243] MD5auth_setkey zero-fills key from first zero octet. + [Bug 1295] leftover fix, do not crash on exit in free_config_trap() + when "trap 1.2.3.4" is used without any further options. + CID 79: kod_init_kod_db() fails to fclose(db_s) in two error paths. + CID 80: attempt to quiet Coverity false positive re: leaking "reason" + in main(). + CID 81: savedconfig leaked in save_config(). + + configure.ac@1.450.1.1, 2009-09-11 06:55:36+00:00, davehart@shiny.ad.hartbrothers.com +20 -0 + add support for --disable-bug1243-fix + + include/ntpd.h@1.131.1.1, 2009-09-11 06:55:36+00:00, davehart@shiny.ad.hartbrothers.com +12 -0 + add framework from "enable bc_bug1243" under #ifdef for future use + + libntp/authkeys.c@1.14, 2009-09-11 06:55:36+00:00, davehart@shiny.ad.hartbrothers.com +18 -16 + [Bug 1243] MD5auth_setkey zero-fills key from first zero octet. + + ntpd/ntp_config.c@1.211.1.1, 2009-09-11 06:55:36+00:00, davehart@shiny.ad.hartbrothers.com +122 -84 + add framework from "enable bc_bug1243" under #ifdef for future use. + [Bug 1295] leftover fix, do not crash on exit in free_config_trap() when + "trap 1.2.3.4" is used without any further options. + + ntpd/ntp_control.c@1.120.1.1, 2009-09-11 06:55:36+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + CID 81: savedconfig leaked in save_config() + + ntpd/ntp_parser.c@1.42.1.1, 2009-09-11 06:55:36+00:00, davehart@shiny.ad.hartbrothers.com +207 -210 + Bison product + + ntpd/ntp_parser.y@1.37.1.1, 2009-09-11 06:55:37+00:00, davehart@shiny.ad.hartbrothers.com +11 -15 + do not crash applying "crypto" command with no options. + add framework from "enable bc_bug1243" under #ifdef for future use. + + sntp/kod_management.c@1.13, 2009-09-11 06:55:37+00:00, davehart@shiny.ad.hartbrothers.com +6 -2 + CID 79: kod_init_kod_db() fails to fclose(db_s) in two error paths + CID 80: attempt to quiet Coverity false positive re: leaking + "reason" in main() + +ChangeSet@1.1981.1.3, 2009-09-10 20:12:31+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + pick up Dr. Mills' miscopt.html leapfile indent correction from 8-Sep + + html/miscopt.html@1.46, 2009-09-10 20:12:30+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + pick up Dr. Mills' leapfile indent correction from 8-Sep + +ChangeSet@1.1981.1.2, 2009-09-10 04:31:45+00:00, davehart@shiny.ad.hartbrothers.com +8 -0 + switch to verb then object order, "nic listen all", "interface drop eth0" + Correct syntax error line & column numbers. + + ChangeLog@1.423, 2009-09-10 04:31:44+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + switch to verb then object order, "nic listen all", "interface drop eth0" + Correct syntax error line & column numbers. + + html/miscopt.html@1.45, 2009-09-10 04:31:44+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + switch to verb then object order, "nic listen all", "interface drop eth0" + + ntpd/ntp_config.c@1.213, 2009-09-10 04:31:44+00:00, davehart@shiny.ad.hartbrothers.com +27 -21 + switch to verb then object order, "nic listen all", "interface drop eth0" + + ntpd/ntp_control.c@1.121, 2009-09-10 04:31:44+00:00, davehart@shiny.ad.hartbrothers.com +4 -8 + pass parser error message on to ntpq :config/config-from-file + + ntpd/ntp_parser.c@1.44, 2009-09-10 04:31:44+00:00, davehart@shiny.ad.hartbrothers.com +338 -346 + Bison product + + ntpd/ntp_parser.y@1.39, 2009-09-10 04:31:44+00:00, davehart@shiny.ad.hartbrothers.com +22 -30 + switch to verb then object order, "nic listen all", "interface drop eth0" + + ntpd/ntp_scanner.c@1.24, 2009-09-10 04:31:44+00:00, davehart@shiny.ad.hartbrothers.com +23 -4 + get syntax error position right in more cases + + ntpd/ntp_scanner.h@1.8, 2009-09-10 04:31:44+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + get syntax error position right in more cases + +ChangeSet@1.1981.1.1, 2009-09-09 16:58:54+00:00, davehart@shiny.ad.hartbrothers.com +16 -0 + [Bug 983] add interface ... [listen | ignore | drop] directive. + document interface (alias nic) and unpeer + make sure accessing ip_file->line_no is safe for :config + + ChangeLog@1.422, 2009-09-09 16:58:51+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 983] add interface ... [listen | ignore | drop] directive. + document interface (alias nic) and unpeer + + configure.ac@1.451, 2009-09-09 16:58:51+00:00, davehart@shiny.ad.hartbrothers.com +0 -17 + remove --disable-listen-read-drop + + html/confopt.html@1.46, 2009-09-09 16:58:51+00:00, davehart@shiny.ad.hartbrothers.com +10 -4 + document unpeer ntp.conf/ntpq :config directive + + html/copyright.html@1.43, 2009-09-09 16:58:52+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + add Dave Hart, fix @@ typo for John Hay + + html/miscopt.html@1.44, 2009-09-09 16:58:52+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + document interface ... [listen | ignore | drop] + + html/scripts/confopt.txt@1.2, 2009-09-09 16:58:52+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + add unpeer + + html/scripts/miscopt.txt@1.2, 2009-09-09 16:58:52+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + add interface and alias nic + + include/ntp_config.h@1.60, 2009-09-09 16:58:52+00:00, davehart@shiny.ad.hartbrothers.com +25 -7 + [Bug 983] add interface ... [listen | ignore | drop] directive. + + include/ntp_io.h@1.11, 2009-09-09 16:58:52+00:00, davehart@shiny.ad.hartbrothers.com +26 -3 + [Bug 983] add interface ... [listen | ignore | drop] directive. + + include/ntpd.h@1.132, 2009-09-09 16:58:52+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 983] add interface ... [listen | ignore | drop] directive. + + ntpd/ntp_config.c@1.212, 2009-09-09 16:58:52+00:00, davehart@shiny.ad.hartbrothers.com +224 -31 + [Bug 983] add interface ... [listen | ignore | drop] directive. + make sure accessing ipfile->line_no and similar is safe during + runtime configuration + + ntpd/ntp_io.c@1.297, 2009-09-09 16:58:52+00:00, davehart@shiny.ad.hartbrothers.com +193 -132 + [Bug 983] add interface ... [listen | ignore | drop] directive. + + ntpd/ntp_parser.c@1.43, 2009-09-09 16:58:52+00:00, davehart@shiny.ad.hartbrothers.com +1055 -984 + Bison output + + ntpd/ntp_parser.h@1.26, 2009-09-09 16:58:52+00:00, davehart@shiny.ad.hartbrothers.com +321 -307 + Bison output + + ntpd/ntp_parser.y@1.38, 2009-09-09 16:58:52+00:00, davehart@shiny.ad.hartbrothers.com +53 -4 + [Bug 983] add interface ... [listen | ignore | drop] directive. + + ntpd/ntpd.c@1.107, 2009-09-09 16:58:52+00:00, davehart@shiny.ad.hartbrothers.com +16 -3 + [Bug 983] add interface ... [listen | ignore | drop] directive. + +ChangeSet@1.1982, 2009-09-06 12:00:45-04:00, fernandoph@pogo.udel.edu +2 -0 + refclock_palisade.c, refclock_palisade.h: + [BUG 1296] Added Support for Trimble Acutime Gold. + + ntpd/refclock_palisade.c@1.27, 2009-09-06 11:48:10-04:00, fernandoph@pogo.udel.edu +131 -23 + [BUG 1296] Added Support for Trimble Acutime Gold. + + ntpd/refclock_palisade.h@1.12, 2009-09-06 11:48:44-04:00, fernandoph@pogo.udel.edu +6 -4 + [BUG 1296] Added Support for Trimble Acutime Gold. + +ChangeSet@1.1981, 2009-09-06 07:51:31-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P210 + TAG: NTP_4_2_5P210 + + ChangeLog@1.421, 2009-09-06 07:51:03-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P210 + + ntpd/ntpd-opts.c@1.203, 2009-09-06 07:51:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P210 + + ntpd/ntpd-opts.h@1.203, 2009-09-06 07:51:07-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P210 + + ntpd/ntpd-opts.texi@1.201, 2009-09-06 07:51:08-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P210 + + ntpd/ntpd.1@1.201, 2009-09-06 07:51:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P210 + + ntpdc/ntpdc-opts.c@1.199, 2009-09-06 07:51:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P210 + + ntpdc/ntpdc-opts.h@1.199, 2009-09-06 07:51:10-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P210 + + ntpdc/ntpdc-opts.texi@1.198, 2009-09-06 07:51:11-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P210 + + ntpdc/ntpdc.1@1.198, 2009-09-06 07:51:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P210 + + ntpq/ntpq-opts.c@1.199, 2009-09-06 07:51:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P210 + + ntpq/ntpq-opts.h@1.199, 2009-09-06 07:51:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P210 + + ntpq/ntpq-opts.texi@1.198, 2009-09-06 07:51:15-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P210 + + ntpq/ntpq.1@1.198, 2009-09-06 07:51:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P210 + + ntpsnmpd/ntpsnmpd-opts.c@1.79, 2009-09-06 07:51:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P210 + + ntpsnmpd/ntpsnmpd-opts.h@1.79, 2009-09-06 07:51:17-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P210 + + ntpsnmpd/ntpsnmpd-opts.texi@1.79, 2009-09-06 07:51:18-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P210 + + ntpsnmpd/ntpsnmpd.1@1.79, 2009-09-06 07:51:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P210 + + packageinfo.sh@1.213, 2009-09-06 07:51:20-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P210 + + sntp/sntp-opts.c@1.73, 2009-09-06 07:51:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P210 + + sntp/sntp-opts.h@1.73, 2009-09-06 07:51:21-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P210 + + sntp/sntp-opts.texi@1.73, 2009-09-06 07:51:22-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P210 + + sntp/sntp.1@1.73, 2009-09-06 07:51:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P210 + + util/ntp-keygen-opts.c@1.202, 2009-09-06 07:51:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P210 + + util/ntp-keygen-opts.h@1.202, 2009-09-06 07:51:24-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P210 + + util/ntp-keygen-opts.texi@1.201, 2009-09-06 07:51:25-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P210 + + util/ntp-keygen.1@1.201, 2009-09-06 07:51:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P210 + +ChangeSet@1.1979, 2009-09-06 08:38:28+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + [Bug 1294] change vs2008 include search path for OpenSSL from + $(OPENSSL)\inc32,$(OPENSSL)\include + to + $(OPENSSL_INC) + to match vc6, vs2003, and vs2005 changes from Danny + + ports/winnt/vs2008/libntp/libntp.vcproj@1.17, 2009-09-06 08:38:27+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + [Bug 1294] change vs2008 include search path for OpenSSL from + $(OPENSSL)\inc32,$(OPENSSL)\include + to + $(OPENSSL_INC) + to match vc6, vs2003, and vs2005 changes from Danny + + ports/winnt/vs2008/ntp-keygen/ntp-keygen.vcproj@1.6, 2009-09-06 08:38:27+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + [Bug 1294] change vs2008 include search path for OpenSSL from + $(OPENSSL)\inc32,$(OPENSSL)\include + to + $(OPENSSL_INC) + to match vc6, vs2003, and vs2005 changes from Danny + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.17, 2009-09-06 08:38:27+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + [Bug 1294] change vs2008 include search path for OpenSSL from + $(OPENSSL)\inc32,$(OPENSSL)\include + to + $(OPENSSL_INC) + to match vc6, vs2003, and vs2005 changes from Danny + + ports/winnt/vs2008/ntpdate/ntpdate.vcproj@1.9, 2009-09-06 08:38:27+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + [Bug 1294] change vs2008 include search path for OpenSSL from + $(OPENSSL)\inc32,$(OPENSSL)\include + to + $(OPENSSL_INC) + to match vc6, vs2003, and vs2005 changes from Danny + + ports/winnt/vs2008/ntpdc/ntpdc.vcproj@1.9, 2009-09-06 08:38:27+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + [Bug 1294] change vs2008 include search path for OpenSSL from + $(OPENSSL)\inc32,$(OPENSSL)\include + to + $(OPENSSL_INC) + to match vc6, vs2003, and vs2005 changes from Danny + + ports/winnt/vs2008/ntpq/ntpq.vcproj@1.8, 2009-09-06 08:38:27+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + [Bug 1294] change vs2008 include search path for OpenSSL from + $(OPENSSL)\inc32,$(OPENSSL)\include + to + $(OPENSSL_INC) + to match vc6, vs2003, and vs2005 changes from Danny + +ChangeSet@1.1976.1.1, 2009-09-06 04:00:32+00:00, davehart@shiny.ad.hartbrothers.com +10 -0 + [Bug 1295] trap directive options are not optional. + [Bug 1297] yylex() must always set yylval before returning. + + ChangeLog@1.418.1.1, 2009-09-06 04:00:30+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1295] trap directive options are not optional. + [Bug 1297] yylex() must always set yylval before returning. + + include/ntp.h@1.162, 2009-09-06 04:00:31+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + comment typo + + include/ntp_config.h@1.59, 2009-09-06 04:00:31+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + add token_name() declaration + + ntpd/Makefile.am@1.67, 2009-09-06 04:00:31+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + enable yacc/Bison report file (ntp_parser.output) generation + when making ntp_parser.[ch]. There is no need to commit + or distribute ntp_parser.output, it is only useful when + testing ntp_parser.y changes. + + + ntpd/ntp_config.c@1.211, 2009-09-06 04:00:31+00:00, davehart@shiny.ad.hartbrothers.com +11 -10 + enable yydebug verbose parser output with -D5 and higher + [Bug 1295] config_trap() bug introduced with dumper in 4.2.5p203 + + + ntpd/ntp_control.c@1.120, 2009-09-06 04:00:31+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + truncate saveconfig output file at open so remnants of longer file + do not remain at the end after overwriting. + + ntpd/ntp_parser.c@1.42, 2009-09-06 04:00:31+00:00, davehart@shiny.ad.hartbrothers.com +876 -924 + Bison product + + ntpd/ntp_parser.h@1.25, 2009-09-06 04:00:31+00:00, davehart@shiny.ad.hartbrothers.com +200 -204 + Bison product + + ntpd/ntp_parser.y@1.37, 2009-09-06 04:00:31+00:00, davehart@shiny.ad.hartbrothers.com +230 -208 + [Bug 1295] trap directive options are not optional. + [Bug 1297] yylex() debug output improvement needs %token-table and + new function to access it, token_name() + make all terminal T_ tokens type Integer so they can be used in + actions as $1, $2, etc: { imaginary_func($2) } instead of + { imaginary_func(T_Sometoken) } + + + ntpd/ntp_scanner.c@1.23, 2009-09-06 04:00:31+00:00, davehart@shiny.ad.hartbrothers.com +56 -27 + fix $1 style references to T_ values by setting yylval.Integer to the + T_ token for simple tokens with no other semantic value + improve debug output: yylex: lexeme 'trap' -> T_Trap + + +ChangeSet@1.1978, 2009-09-02 14:15:16-04:00, mayer@pogo.udel.edu +1 -0 + [Bug 1294] + + ChangeLog@1.419, 2009-09-02 14:15:04-04:00, mayer@pogo.udel.edu +2 -0 + [Bug 1294] + +ChangeSet@1.1977, 2009-09-02 14:13:00-04:00, mayer@pogo.udel.edu +20 -0 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros for windows and Remove unnecessary OPENSSL applink.c include + + ntpdc/ntpdc.c@1.68, 2009-09-02 14:08:49-04:00, mayer@pogo.udel.edu +0 -6 + [Bug1294] Remove unnecessary OPENSSL applink.c include + + ntpq/ntpq.c@1.88, 2009-09-02 14:08:50-04:00, mayer@pogo.udel.edu +0 -6 + [Bug1294] Remove unnecessary OPENSSL applink.c include + + ports/winnt/vc6/libntp.dsp@1.41, 2009-09-02 14:10:15-04:00, mayer@pogo.udel.edu +2 -2 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vc6/ntpd.dsp@1.37, 2009-09-02 14:10:15-04:00, mayer@pogo.udel.edu +4 -4 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vc6/ntpdate.dsp@1.21, 2009-09-02 14:10:15-04:00, mayer@pogo.udel.edu +2 -2 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vc6/ntpdc.dsp@1.24, 2009-09-02 14:10:15-04:00, mayer@pogo.udel.edu +2 -2 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vc6/ntpkeygen.dsp@1.17, 2009-09-02 14:10:15-04:00, mayer@pogo.udel.edu +4 -4 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vc6/ntpq.dsp@1.25, 2009-09-02 14:10:15-04:00, mayer@pogo.udel.edu +2 -2 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2003/libntp.vcproj@1.2, 2009-09-02 14:10:55-04:00, mayer@pogo.udel.edu +2 -2 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2003/ntpd.vcproj@1.2, 2009-09-02 14:10:55-04:00, mayer@pogo.udel.edu +6 -6 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2003/ntpdate.vcproj@1.2, 2009-09-02 14:10:56-04:00, mayer@pogo.udel.edu +2 -2 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2003/ntpdc.vcproj@1.2, 2009-09-02 14:10:56-04:00, mayer@pogo.udel.edu +2 -2 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2003/ntpkeygen.vcproj@1.2, 2009-09-02 14:10:56-04:00, mayer@pogo.udel.edu +4 -4 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2003/ntpq.vcproj@1.2, 2009-09-02 14:10:56-04:00, mayer@pogo.udel.edu +2 -2 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2005/libntp.vcproj@1.2, 2009-09-02 14:11:31-04:00, mayer@pogo.udel.edu +3 -3 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2005/ntpd.vcproj@1.2, 2009-09-02 14:11:31-04:00, mayer@pogo.udel.edu +7 -7 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2005/ntpdate.vcproj@1.2, 2009-09-02 14:11:31-04:00, mayer@pogo.udel.edu +3 -3 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2005/ntpdc.vcproj@1.2, 2009-09-02 14:11:31-04:00, mayer@pogo.udel.edu +3 -3 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2005/ntpkeygen.vcproj@1.2, 2009-09-02 14:11:31-04:00, mayer@pogo.udel.edu +5 -5 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2005/ntpq.vcproj@1.2, 2009-09-02 14:11:31-04:00, mayer@pogo.udel.edu +3 -3 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + +ChangeSet@1.1976, 2009-09-01 07:51:38-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P209 + TAG: NTP_4_2_5P209 + + ChangeLog@1.418, 2009-09-01 07:51:10-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P209 + + ntpd/ntpd-opts.c@1.202, 2009-09-01 07:51:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P209 + + ntpd/ntpd-opts.h@1.202, 2009-09-01 07:51:13-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P209 + + ntpd/ntpd-opts.texi@1.200, 2009-09-01 07:51:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P209 + + ntpd/ntpd.1@1.200, 2009-09-01 07:51:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P209 + + ntpdc/ntpdc-opts.c@1.198, 2009-09-01 07:51:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P209 + + ntpdc/ntpdc-opts.h@1.198, 2009-09-01 07:51:16-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P209 + + ntpdc/ntpdc-opts.texi@1.197, 2009-09-01 07:51:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P209 + + ntpdc/ntpdc.1@1.197, 2009-09-01 07:51:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P209 + + ntpq/ntpq-opts.c@1.198, 2009-09-01 07:51:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P209 + + ntpq/ntpq-opts.h@1.198, 2009-09-01 07:51:19-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P209 + + ntpq/ntpq-opts.texi@1.197, 2009-09-01 07:51:20-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P209 + + ntpq/ntpq.1@1.197, 2009-09-01 07:51:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P209 + + ntpsnmpd/ntpsnmpd-opts.c@1.78, 2009-09-01 07:51:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P209 + + ntpsnmpd/ntpsnmpd-opts.h@1.78, 2009-09-01 07:51:23-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P209 + + ntpsnmpd/ntpsnmpd-opts.texi@1.78, 2009-09-01 07:51:24-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P209 + + ntpsnmpd/ntpsnmpd.1@1.78, 2009-09-01 07:51:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P209 + + packageinfo.sh@1.212, 2009-09-01 07:51:25-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P209 + + sntp/sntp-opts.c@1.72, 2009-09-01 07:51:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P209 + + sntp/sntp-opts.h@1.72, 2009-09-01 07:51:27-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P209 + + sntp/sntp-opts.texi@1.72, 2009-09-01 07:51:28-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P209 + + sntp/sntp.1@1.72, 2009-09-01 07:51:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P209 + + util/ntp-keygen-opts.c@1.201, 2009-09-01 07:51:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P209 + + util/ntp-keygen-opts.h@1.201, 2009-09-01 07:51:29-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P209 + + util/ntp-keygen-opts.texi@1.200, 2009-09-01 07:51:30-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P209 + + util/ntp-keygen.1@1.200, 2009-09-01 07:51:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P209 + +ChangeSet@1.1974, 2009-09-01 08:20:19+00:00, davehart@shiny.ad.hartbrothers.com +22 -0 + revert accidental pull of wrong repo (windowscompiler) + + BitKeeper/deleted/.del-instsrv-VS2008.vcproj~af3a7a4284dd8b4f@1.2, 2009-09-01 08:16:02+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Delete: ports/winnt/instsrv/instsrv-VS2008.vcproj + + BitKeeper/deleted/.del-libntp-VS2008.vcproj~e944822ae4545d06@1.2, 2009-09-01 08:16:23+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Delete: ports/winnt/libntp/libntp-VS2008.vcproj + + BitKeeper/deleted/.del-ntp-VS2008.sln~b08951bb97303271@1.2, 2009-09-01 08:16:45+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Delete: ports/winnt/ntp-VS2008.sln + + BitKeeper/deleted/.del-ntp-keygen-VS2008.vcproj~f2e7f85d5942b392@1.2, 2009-09-01 08:14:15+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Delete: ports/winnt/ntp-keygen/ntp-keygen-VS2008.vcproj + + BitKeeper/deleted/.del-ntpd-VS2008.vcproj~63a1a8b5a4f17de8@1.2, 2009-09-01 08:17:28+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Delete: ports/winnt/ntpd/ntpd-VS2008.vcproj + + BitKeeper/deleted/.del-ntpdate-VS2008.vcproj~dcb57743d0d7d96d@1.2, 2009-09-01 08:17:46+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Delete: ports/winnt/ntpdate/ntpdate-VS2008.vcproj + + BitKeeper/deleted/.del-ntpdc-VS2008.vcproj~6b071c10ef40334b@1.2, 2009-09-01 08:17:54+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Delete: ports/winnt/ntpdc/ntpdc-VS2008.vcproj + + BitKeeper/deleted/.del-ntpkeygen.vcproj~9130c0edbfb4b39b@1.2, 2009-09-01 08:13:29+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Delete: ports/winnt/ntp-keygen/ntpkeygen.vcproj + + BitKeeper/deleted/.del-ntpq-VS2008.vcproj~3d9c726f33ecd5f@1.2, 2009-09-01 08:18:09+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Delete: ports/winnt/ntpq/ntpq-VS2008.vcproj + + ChangeLog@1.416, 2009-09-01 08:20:15+00:00, davehart@shiny.ad.hartbrothers.com +0 -2 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/libntp/libntp.dsp@1.38, 2009-09-01 08:20:15+00:00, davehart@shiny.ad.hartbrothers.com +0 -4 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/libntp/libntp.vcproj@1.14, 2009-09-01 08:20:15+00:00, davehart@shiny.ad.hartbrothers.com +47 -148 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/ntp-keygen/ntpkeygen.dsp@1.14, 2009-09-01 08:20:16+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/ntp.sln@1.5, 2009-09-01 08:20:15+00:00, davehart@shiny.ad.hartbrothers.com +46 -43 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/ntpd/ntpd.dsp@1.34, 2009-09-01 08:20:16+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/ntpd/ntpd.vcproj@1.14, 2009-09-01 08:20:16+00:00, davehart@shiny.ad.hartbrothers.com +117 -119 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/ntpdate/ntpdate.dsp@1.18, 2009-09-01 08:20:16+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/ntpdate/ntpdate.vcproj@1.6, 2009-09-01 08:20:16+00:00, davehart@shiny.ad.hartbrothers.com +85 -20 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/ntpdc/ntpdc.dsp@1.21, 2009-09-01 08:20:16+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/ntpdc/ntpdc.vcproj@1.6, 2009-09-01 08:20:16+00:00, davehart@shiny.ad.hartbrothers.com +46 -20 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/ntpq/ntpq.dsp@1.22, 2009-09-01 08:20:16+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/ntpq/ntpq.vcproj@1.5, 2009-09-01 08:20:16+00:00, davehart@shiny.ad.hartbrothers.com +36 -20 + revert accidental pull of wrong repo (windowscompiler) + +ChangeSet@1.1968.1.18, 2009-08-31 21:57:23-04:00, mayer@pogo.udel.edu +1 -0 + [Bug 1289] update to add VS2003 + + ChangeLog@1.413.1.11, 2009-08-31 21:57:00-04:00, mayer@pogo.udel.edu +1 -1 + [Bug 1289] update to add VS2003 + +ChangeSet@1.1968.1.17, 2009-08-31 16:58:47-04:00, mayer@pogo.udel.edu +8 -0 + [Bug 1289] Add vs2003 compiler files + + ports/winnt/vs2003/Instsrv.vcproj@1.1, 2009-08-31 16:58:32-04:00, mayer@pogo.udel.edu +174 -0 + [Bug 1289] Add vs2003 compiler files + + ports/winnt/vs2003/Instsrv.vcproj@1.0, 2009-08-31 16:58:32-04:00, mayer@pogo.udel.edu +0 -0 + + ports/winnt/vs2003/libntp.vcproj@1.1, 2009-08-31 16:58:33-04:00, mayer@pogo.udel.edu +2058 -0 + [Bug 1289] Add vs2003 compiler files + + ports/winnt/vs2003/libntp.vcproj@1.0, 2009-08-31 16:58:33-04:00, mayer@pogo.udel.edu +0 -0 + + ports/winnt/vs2003/ntp.sln@1.1, 2009-08-31 16:58:33-04:00, mayer@pogo.udel.edu +73 -0 + [Bug 1289] Add vs2003 compiler files + + ports/winnt/vs2003/ntp.sln@1.0, 2009-08-31 16:58:33-04:00, mayer@pogo.udel.edu +0 -0 + + ports/winnt/vs2003/ntpd.vcproj@1.1, 2009-08-31 16:58:33-04:00, mayer@pogo.udel.edu +2113 -0 + [Bug 1289] Add vs2003 compiler files + + ports/winnt/vs2003/ntpd.vcproj@1.0, 2009-08-31 16:58:33-04:00, mayer@pogo.udel.edu +0 -0 + + ports/winnt/vs2003/ntpdate.vcproj@1.1, 2009-08-31 16:58:33-04:00, mayer@pogo.udel.edu +221 -0 + [Bug 1289] Add vs2003 compiler files + + ports/winnt/vs2003/ntpdate.vcproj@1.0, 2009-08-31 16:58:33-04:00, mayer@pogo.udel.edu +0 -0 + + ports/winnt/vs2003/ntpdc.vcproj@1.1, 2009-08-31 16:58:33-04:00, mayer@pogo.udel.edu +265 -0 + [Bug 1289] Add vs2003 compiler files + + ports/winnt/vs2003/ntpdc.vcproj@1.0, 2009-08-31 16:58:33-04:00, mayer@pogo.udel.edu +0 -0 + + ports/winnt/vs2003/ntpkeygen.vcproj@1.1, 2009-08-31 16:58:33-04:00, mayer@pogo.udel.edu +302 -0 + [Bug 1289] Add vs2003 compiler files + + ports/winnt/vs2003/ntpkeygen.vcproj@1.0, 2009-08-31 16:58:33-04:00, mayer@pogo.udel.edu +0 -0 + + ports/winnt/vs2003/ntpq.vcproj@1.1, 2009-08-31 16:58:33-04:00, mayer@pogo.udel.edu +263 -0 + [Bug 1289] Add vs2003 compiler files + + ports/winnt/vs2003/ntpq.vcproj@1.0, 2009-08-31 16:58:33-04:00, mayer@pogo.udel.edu +0 -0 + +ChangeSet@1.1968.1.16, 2009-08-31 09:56:29-04:00, mayer@pogo.udel.edu +1 -0 + [Bug 1290] + + ChangeLog@1.413.1.10, 2009-08-31 09:56:17-04:00, mayer@pogo.udel.edu +2 -1 + [Bug 1290] + +ChangeSet@1.1968.1.15, 2009-08-31 09:54:57-04:00, mayer@pogo.udel.edu +1 -0 + [Bug 1290] Fix to use GETTIMEOFDAY macro + + ntpd/refclock_oncore.c@1.78.1.1, 2009-08-31 09:54:42-04:00, mayer@pogo.udel.edu +1 -1 + [Bug 1290] Fix to use GETTIMEOFDAY macro + +ChangeSet@1.1968.1.14, 2009-08-31 09:50:13-04:00, mayer@pogo.udel.edu +1 -0 + [Bug 1289] Use quotes instead of angle brackets for include of messages.h + + ports/winnt/libntp/syslog.c@1.5, 2009-08-31 09:49:50-04:00, mayer@pogo.udel.edu +1 -1 + [Bug 1289] Use quotes instead of angle brackets for include of messages.h + +ChangeSet@1.1968.1.13, 2009-08-30 23:47:19-04:00, mayer@pogo.udel.edu +1 -0 + [Bug 1289] + + ChangeLog@1.413.1.9, 2009-08-30 23:47:02-04:00, mayer@pogo.udel.edu +1 -0 + [Bug 1289] + +ChangeSet@1.1968.1.12, 2009-08-30 23:36:44-04:00, mayer@pogo.udel.edu +8 -0 + [Bug #1289] Update project files for VS2005 + + ports/winnt/vs2005/Instsrv.vcproj@1.1, 2009-08-30 23:36:06-04:00, mayer@pogo.udel.edu +242 -0 + [Bug #1289] Update project files for VS2005 + + ports/winnt/vs2005/Instsrv.vcproj@1.0, 2009-08-30 23:36:06-04:00, mayer@pogo.udel.edu +0 -0 + + ports/winnt/vs2005/libntp.vcproj@1.1, 2009-08-30 23:36:06-04:00, mayer@pogo.udel.edu +2250 -0 + [Bug #1289] Update project files for VS2005 + + ports/winnt/vs2005/libntp.vcproj@1.0, 2009-08-30 23:36:06-04:00, mayer@pogo.udel.edu +0 -0 + + ports/winnt/vs2005/ntp.sln@1.1, 2009-08-30 23:35:21-04:00, mayer@pogo.udel.edu +68 -0 + [Bug #1289] Update project files for VS6 + + ports/winnt/vs2005/ntp.sln@1.0, 2009-08-30 23:35:21-04:00, mayer@pogo.udel.edu +0 -0 + + ports/winnt/vs2005/ntpd.vcproj@1.1, 2009-08-30 23:36:06-04:00, mayer@pogo.udel.edu +2237 -0 + [Bug #1289] Update project files for VS2005 + + ports/winnt/vs2005/ntpd.vcproj@1.0, 2009-08-30 23:36:06-04:00, mayer@pogo.udel.edu +0 -0 + + ports/winnt/vs2005/ntpdate.vcproj@1.1, 2009-08-30 23:36:06-04:00, mayer@pogo.udel.edu +292 -0 + [Bug #1289] Update project files for VS2005 + + ports/winnt/vs2005/ntpdate.vcproj@1.0, 2009-08-30 23:36:06-04:00, mayer@pogo.udel.edu +0 -0 + + ports/winnt/vs2005/ntpdc.vcproj@1.1, 2009-08-30 23:36:06-04:00, mayer@pogo.udel.edu +336 -0 + [Bug #1289] Update project files for VS2005 + + ports/winnt/vs2005/ntpdc.vcproj@1.0, 2009-08-30 23:36:06-04:00, mayer@pogo.udel.edu +0 -0 + + ports/winnt/vs2005/ntpkeygen.vcproj@1.1, 2009-08-30 23:36:06-04:00, mayer@pogo.udel.edu +376 -0 + [Bug #1289] Update project files for VS2005 + + ports/winnt/vs2005/ntpkeygen.vcproj@1.0, 2009-08-30 23:36:06-04:00, mayer@pogo.udel.edu +0 -0 + + ports/winnt/vs2005/ntpq.vcproj@1.1, 2009-08-30 23:36:06-04:00, mayer@pogo.udel.edu +336 -0 + [Bug #1289] Update project files for VS2005 + + ports/winnt/vs2005/ntpq.vcproj@1.0, 2009-08-30 23:36:06-04:00, mayer@pogo.udel.edu +0 -0 + +ChangeSet@1.1968.1.11, 2009-08-30 23:30:53-04:00, mayer@pogo.udel.edu +8 -0 + [Bug #1289] Update project files for VS6 + + ports/winnt/vc6/Instsrv.dsp@1.9, 2009-08-30 23:30:29-04:00, mayer@pogo.udel.edu +9 -9 + [Bug #1289] Update project files for VS6 + + ports/winnt/vc6/libntp.dsp@1.36.1.2, 2009-08-30 23:30:29-04:00, mayer@pogo.udel.edu +23 -19 + [Bug #1289] Update project files for VS6 + + ports/winnt/vc6/ntp.dsw@1.9, 2009-08-30 23:30:29-04:00, mayer@pogo.udel.edu +7 -7 + [Bug #1289] Update project files for VS6 + + ports/winnt/vc6/ntpd.dsp@1.32.1.2, 2009-08-30 23:30:29-04:00, mayer@pogo.udel.edu +17 -21 + [Bug #1289] Update project files for VS6 + + ports/winnt/vc6/ntpdate.dsp@1.16.1.2, 2009-08-30 23:30:30-04:00, mayer@pogo.udel.edu +12 -16 + [Bug #1289] Update project files for VS6 + + ports/winnt/vc6/ntpdc.dsp@1.19.1.2, 2009-08-30 23:30:30-04:00, mayer@pogo.udel.edu +13 -17 + [Bug #1289] Update project files for VS6 + + ports/winnt/vc6/ntpkeygen.dsp@1.12.1.2, 2009-08-30 23:30:30-04:00, mayer@pogo.udel.edu +10 -14 + [Bug #1289] Update project files for VS6 + + ports/winnt/vc6/ntpq.dsp@1.20.1.2, 2009-08-30 23:30:30-04:00, mayer@pogo.udel.edu +12 -16 + [Bug #1289] Update project files for VS6 + +ChangeSet@1.1968.1.10, 2009-08-30 23:28:42-04:00, mayer@pogo.udel.edu +8 -0 + [Bug #1289] Move compiler project for VS6 + + ports/winnt/vc6/Instsrv.dsp@1.8, 2009-08-30 23:20:03-04:00, mayer@pogo.udel.edu +0 -0 + Rename: ports/winnt/instsrv/Instsrv.dsp -> ports/winnt/vc6/Instsrv.dsp + + ports/winnt/vc6/libntp.dsp@1.36.1.1, 2009-08-30 23:15:56-04:00, mayer@pogo.udel.edu +0 -0 + Rename: ports/winnt/libntp/libntp.dsp -> ports/winnt/vc6/libntp.dsp + + ports/winnt/vc6/ntp.dsw@1.8, 2009-08-30 23:15:18-04:00, mayer@pogo.udel.edu +0 -0 + Rename: ports/winnt/ntp.dsw -> ports/winnt/vc6/ntp.dsw + + ports/winnt/vc6/ntpd.dsp@1.32.1.1, 2009-08-30 23:16:14-04:00, mayer@pogo.udel.edu +0 -0 + Rename: ports/winnt/ntpd/ntpd.dsp -> ports/winnt/vc6/ntpd.dsp + + ports/winnt/vc6/ntpdate.dsp@1.16.1.1, 2009-08-30 23:17:44-04:00, mayer@pogo.udel.edu +0 -0 + Rename: ports/winnt/ntpdate/ntpdate.dsp -> ports/winnt/vc6/ntpdate.dsp + + ports/winnt/vc6/ntpdc.dsp@1.19.1.1, 2009-08-30 23:17:09-04:00, mayer@pogo.udel.edu +0 -0 + Rename: ports/winnt/ntpdc/ntpdc.dsp -> ports/winnt/vc6/ntpdc.dsp + + ports/winnt/vc6/ntpkeygen.dsp@1.12.1.1, 2009-08-30 23:18:11-04:00, mayer@pogo.udel.edu +0 -0 + Rename: ports/winnt/ntp-keygen/ntpkeygen.dsp -> ports/winnt/vc6/ntpkeygen.dsp + + ports/winnt/vc6/ntpq.dsp@1.20.1.1, 2009-08-30 23:16:51-04:00, mayer@pogo.udel.edu +0 -0 + Rename: ports/winnt/ntpq/ntpq.dsp -> ports/winnt/vc6/ntpq.dsp + +ChangeSet@1.1968.1.8, 2009-08-30 03:02:04-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P208 + TAG: NTP_4_2_5P208 + + ChangeLog@1.413.1.7, 2009-08-30 03:01:35-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P208 + + ntpd/ntpd-opts.c@1.201, 2009-08-30 03:01:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P208 + + ntpd/ntpd-opts.h@1.201, 2009-08-30 03:01:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P208 + + ntpd/ntpd-opts.texi@1.199, 2009-08-30 03:01:39-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P208 + + ntpd/ntpd.1@1.199, 2009-08-30 03:01:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P208 + + ntpdc/ntpdc-opts.c@1.197, 2009-08-30 03:01:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P208 + + ntpdc/ntpdc-opts.h@1.197, 2009-08-30 03:01:42-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P208 + + ntpdc/ntpdc-opts.texi@1.196, 2009-08-30 03:01:43-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P208 + + ntpdc/ntpdc.1@1.196, 2009-08-30 03:01:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P208 + + ntpq/ntpq-opts.c@1.197, 2009-08-30 03:01:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P208 + + ntpq/ntpq-opts.h@1.197, 2009-08-30 03:01:46-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P208 + + ntpq/ntpq-opts.texi@1.196, 2009-08-30 03:01:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P208 + + ntpq/ntpq.1@1.196, 2009-08-30 03:01:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P208 + + ntpsnmpd/ntpsnmpd-opts.c@1.77, 2009-08-30 03:01:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P208 + + ntpsnmpd/ntpsnmpd-opts.h@1.77, 2009-08-30 03:01:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P208 + + ntpsnmpd/ntpsnmpd-opts.texi@1.77, 2009-08-30 03:01:50-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P208 + + ntpsnmpd/ntpsnmpd.1@1.77, 2009-08-30 03:01:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P208 + + packageinfo.sh@1.211, 2009-08-30 03:01:51-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P208 + + sntp/sntp-opts.c@1.71, 2009-08-30 03:01:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P208 + + sntp/sntp-opts.h@1.71, 2009-08-30 03:01:53-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P208 + + sntp/sntp-opts.texi@1.71, 2009-08-30 03:01:54-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P208 + + sntp/sntp.1@1.71, 2009-08-30 03:01:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P208 + + util/ntp-keygen-opts.c@1.200, 2009-08-30 03:01:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P208 + + util/ntp-keygen-opts.h@1.200, 2009-08-30 03:01:56-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P208 + + util/ntp-keygen-opts.texi@1.199, 2009-08-30 03:01:57-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P208 + + util/ntp-keygen.1@1.199, 2009-08-30 03:01:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P208 + +ChangeSet@1.1968.3.2, 2009-08-29 21:22:45+00:00, davehart@shiny.ad.hartbrothers.com +12 -0 + [Bug 1293] make configuration dumper ready for release, specifically: + rename ntpq dumpcfg command to "saveconfig". + require authentication for saveconfig. + "restrict ... nomodify" prevents saveconfig and :config. + "saveconfig ." shorthand to save to startup configuration file. + support strftime() substitution in saveconfig arg to timestamp + the output filename, for example "saveconfig %Y%m%d-%H%M%S.conf". + display saveconfig response message from ntpd in ntpq. + save output filename in "savedconfig" variable, fetched with ntpq -c + "rv 0 savedconfig". + document saveconfig in html/ntpq.html. + add ./configure --disable-saveconfig to build a smaller ntpd. + log saveconfig failures and successes to syslog. + + + ChangeLog@1.413.3.1, 2009-08-29 21:22:43+00:00, davehart@shiny.ad.hartbrothers.com +13 -0 + [Bug 1293] make configuration dumper ready for release, specifically: + rename ntpq dumpcfg command to "saveconfig". + require authentication for saveconfig. + "restrict ... nomodify" prevents saveconfig and :config. + "saveconfig ." shorthand to save to startup configuration file. + support strftime() substitution in saveconfig arg to timestamp + the output filename, for example "saveconfig %Y%m%d-%H%M%S.conf". + display saveconfig response message from ntpd in ntpq. + save output filename in "savedconfig" variable, fetched with ntpq -c + "rv 0 savedconfig". + document saveconfig in html/ntpq.html. + add ./configure --disable-saveconfig to build a smaller ntpd. + log saveconfig failures and successes to syslog. + + + html/ntpq.html@1.32, 2009-08-29 21:22:43+00:00, davehart@shiny.ad.hartbrothers.com +13 -8 + document "config-from-file" and "saveconfig" + use
and no
between "cv" and "clockvar" as with other synonyms. + typo "helpl" -> "help". + typo "apear" -> "appear" + + include/ntp_config.h@1.58, 2009-08-29 21:22:43+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + support ./configure --disable-saveconfig + + include/ntp_control.h@1.37, 2009-08-29 21:22:43+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + CTL_OP_DUMPCONFIG renamed CTL_OP_SAVECONFIG + + include/ntpd.h@1.131, 2009-08-29 21:22:43+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + expose cfg_tree_history as extern for ntp_control.c save_config() + + ntpd/ntp_config.c@1.210, 2009-08-29 21:22:44+00:00, davehart@shiny.ad.hartbrothers.com +5 -1 + support ./configure --disable-saveconfig + + ntpd/ntp_control.c@1.119, 2009-08-29 21:22:44+00:00, davehart@shiny.ad.hartbrothers.com +101 -35 + dump_config() renamed save_config() + CTL_OP_DUMPCONFIG renamed CTL_OP_SAVECONFIG + add "savedconfig" system variable containing last saveconfig filename + support ./configure --disable-saveconfig + log saveconfig failures and successes to syslog + enforce "restrict ... nomodify" preventing ntpq :config, config-from-file, + and saveconfig + require authentication for saveconfig + remove restrictions on saveconfig output directory, allow overwriting + exiting files + support "saveconfig ." to replace the startup configuration file + allow strftime() format specifiers in saveconfig filename, such as + "saveconfig ntp-%Y%m%d-%H%M%S.conf" + + ntpd/ntp_intres.c@1.65, 2009-08-29 21:22:44+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + clean up unreferenced local warnings + + ntpd/ntp_io.c@1.296, 2009-08-29 21:22:44+00:00, davehart@shiny.ad.hartbrothers.com +1 -2 + clean up unreferenced local warning + + ntpq/ntpq-subs.c@1.35, 2009-08-29 21:22:44+00:00, davehart@shiny.ad.hartbrothers.com +21 -13 + rename ntpq dumpcfg to saveconfig, require authentication + + ports/winnt/include/config.h@1.74.1.1, 2009-08-29 21:22:44+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + default to equivalent of --enable-saveconfig as with Unix + warn on unreferenced local variables + + ports/winnt/ntpd/ntp_iocompletionport.c@1.49, 2009-08-29 21:22:44+00:00, davehart@shiny.ad.hartbrothers.com +0 -2 + remove unreferenced locals + +ChangeSet@1.1968.1.6, 2009-08-29 07:50:13-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P207 + TAG: NTP_4_2_5P207 + + ChangeLog@1.413.1.5, 2009-08-29 07:49:45-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P207 + + ntpd/ntpd-opts.c@1.200, 2009-08-29 07:49:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P207 + + ntpd/ntpd-opts.h@1.200, 2009-08-29 07:49:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P207 + + ntpd/ntpd-opts.texi@1.198, 2009-08-29 07:49:48-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P207 + + ntpd/ntpd.1@1.198, 2009-08-29 07:49:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P207 + + ntpdc/ntpdc-opts.c@1.196, 2009-08-29 07:49:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P207 + + ntpdc/ntpdc-opts.h@1.196, 2009-08-29 07:49:51-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P207 + + ntpdc/ntpdc-opts.texi@1.195, 2009-08-29 07:49:51-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P207 + + ntpdc/ntpdc.1@1.195, 2009-08-29 07:49:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P207 + + ntpq/ntpq-opts.c@1.196, 2009-08-29 07:49:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P207 + + ntpq/ntpq-opts.h@1.196, 2009-08-29 07:49:53-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P207 + + ntpq/ntpq-opts.texi@1.195, 2009-08-29 07:49:54-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P207 + + ntpq/ntpq.1@1.195, 2009-08-29 07:49:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P207 + + ntpsnmpd/ntpsnmpd-opts.c@1.76, 2009-08-29 07:49:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P207 + + ntpsnmpd/ntpsnmpd-opts.h@1.76, 2009-08-29 07:49:56-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P207 + + ntpsnmpd/ntpsnmpd-opts.texi@1.76, 2009-08-29 07:49:57-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P207 + + ntpsnmpd/ntpsnmpd.1@1.76, 2009-08-29 07:49:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P207 + + packageinfo.sh@1.210, 2009-08-29 07:49:58-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P207 + + sntp/sntp-opts.c@1.70, 2009-08-29 07:49:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P207 + + sntp/sntp-opts.h@1.70, 2009-08-29 07:50:00-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P207 + + sntp/sntp-opts.texi@1.70, 2009-08-29 07:50:01-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P207 + + sntp/sntp.1@1.70, 2009-08-29 07:50:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P207 + + util/ntp-keygen-opts.c@1.199, 2009-08-29 07:50:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P207 + + util/ntp-keygen-opts.h@1.199, 2009-08-29 07:50:03-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P207 + + util/ntp-keygen-opts.texi@1.198, 2009-08-29 07:50:04-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P207 + + util/ntp-keygen.1@1.198, 2009-08-29 07:50:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P207 + +ChangeSet@1.1968.3.1, 2009-08-29 05:08:56-04:00, stenn@pogo.udel.edu +1 -0 + [Bug 1293] add support for --disable-saveconfig to configure.ac + + configure.ac@1.450, 2009-08-29 05:08:48-04:00, stenn@pogo.udel.edu +10 -0 + [Bug 1293] add support for --disable-saveconfig to configure.ac + +ChangeSet@1.1968.2.1, 2009-08-28 07:40:42+00:00, davehart@shiny.ad.hartbrothers.com +10 -0 + [Bug 1289] Move vc9/vs2008 build to ports\winnt\vs2008. + + ChangeLog@1.413.2.1, 2009-08-28 07:40:40+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1289] Move vc9/vs2008 build to ports\winnt\vs2008. + + ports/winnt/scripts/mkver.bat@1.11, 2009-08-28 07:40:40+00:00, davehart@shiny.ad.hartbrothers.com +19 -24 + support per-compiler build subdirs under winnt + remove no-longer-needed support for getting version from version.m4 + (packageinfo.sh has been used for some time) + + ports/winnt/vs2008/instsrv/instsrv.vcproj@1.4, 2009-08-28 07:40:40+00:00, davehart@shiny.ad.hartbrothers.com +15 -15 + [Bug 1289] Move vc9/vs2008 build to ports\winnt\vs2008. + + ports/winnt/vs2008/instsrv/instsrv.vcproj@1.3, 2009-08-28 06:33:08+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/vs2008/instsrv.vcproj -> ports/winnt/vs2008/instsrv/instsrv.vcproj + + ports/winnt/vs2008/instsrv.vcproj@1.2, 2009-08-28 04:47:10+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/instsrv/instsrv.vcproj -> ports/winnt/vs2008/instsrv.vcproj + + ports/winnt/vs2008/libntp/libntp.vcproj@1.12.1.3, 2009-08-28 07:40:40+00:00, davehart@shiny.ad.hartbrothers.com +150 -150 + [Bug 1289] Move vc9/vs2008 build to ports\winnt\vs2008. + + ports/winnt/vs2008/libntp/libntp.vcproj@1.12.1.2, 2009-08-28 06:35:07+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/vs2008/libntp.vcproj -> ports/winnt/vs2008/libntp/libntp.vcproj + + ports/winnt/vs2008/libntp.vcproj@1.12.1.1, 2009-08-28 04:47:49+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/libntp/libntp.vcproj -> ports/winnt/vs2008/libntp.vcproj + + ports/winnt/vs2008/ntp-keygen/ntp-keygen.vcproj@1.5, 2009-08-28 07:40:40+00:00, davehart@shiny.ad.hartbrothers.com +27 -27 + [Bug 1289] Move vc9/vs2008 build to ports\winnt\vs2008. + + ports/winnt/vs2008/ntp-keygen/ntp-keygen.vcproj@1.4, 2009-08-28 06:44:37+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/vs2008/ntp-keygen.vcproj -> ports/winnt/vs2008/ntp-keygen/ntp-keygen.vcproj + + ports/winnt/vs2008/ntp-keygen.vcproj@1.3, 2009-08-28 06:44:12+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/ntp-keygen/ntp-keygen.vcproj -> ports/winnt/vs2008/ntp-keygen.vcproj + + ports/winnt/vs2008/ntp.sln@1.3.1.1, 2009-08-28 04:46:26+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/ntp.sln -> ports/winnt/vs2008/ntp.sln + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.12.1.3, 2009-08-28 07:40:40+00:00, davehart@shiny.ad.hartbrothers.com +169 -169 + [Bug 1289] Move vc9/vs2008 build to ports\winnt\vs2008. + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.12.1.2, 2009-08-28 06:39:11+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/vs2008/ntpd.vcproj -> ports/winnt/vs2008/ntpd/ntpd.vcproj + + ports/winnt/vs2008/ntpd.vcproj@1.12.1.1, 2009-08-28 05:01:52+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/ntpd/ntpd.vcproj -> ports/winnt/vs2008/ntpd.vcproj + + ports/winnt/vs2008/ntpdate/ntpdate.vcproj@1.4.1.3, 2009-08-28 07:40:40+00:00, davehart@shiny.ad.hartbrothers.com +35 -35 + [Bug 1289] Move vc9/vs2008 build to ports\winnt\vs2008. + + ports/winnt/vs2008/ntpdate/ntpdate.vcproj@1.4.1.2, 2009-08-28 06:39:45+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/vs2008/ntpdate.vcproj -> ports/winnt/vs2008/ntpdate/ntpdate.vcproj + + ports/winnt/vs2008/ntpdate.vcproj@1.4.1.1, 2009-08-28 05:51:09+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/ntpdate/ntpdate.vcproj -> ports/winnt/vs2008/ntpdate.vcproj + + ports/winnt/vs2008/ntpdc/ntpdc.vcproj@1.4.1.3, 2009-08-28 07:40:40+00:00, davehart@shiny.ad.hartbrothers.com +26 -26 + [Bug 1289] Move vc9/vs2008 build to ports\winnt\vs2008. + + ports/winnt/vs2008/ntpdc/ntpdc.vcproj@1.4.1.2, 2009-08-28 06:40:26+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/vs2008/ntpdc.vcproj -> ports/winnt/vs2008/ntpdc/ntpdc.vcproj + + ports/winnt/vs2008/ntpdc.vcproj@1.4.1.1, 2009-08-28 06:00:44+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/ntpdc/ntpdc.vcproj -> ports/winnt/vs2008/ntpdc.vcproj + + ports/winnt/vs2008/ntpq/ntpq.vcproj@1.3.1.3, 2009-08-28 07:40:40+00:00, davehart@shiny.ad.hartbrothers.com +25 -25 + [Bug 1289] Move vc9/vs2008 build to ports\winnt\vs2008. + + ports/winnt/vs2008/ntpq/ntpq.vcproj@1.3.1.2, 2009-08-28 06:41:02+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/vs2008/ntpq.vcproj -> ports/winnt/vs2008/ntpq/ntpq.vcproj + + ports/winnt/vs2008/ntpq.vcproj@1.3.1.1, 2009-08-28 06:07:58+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/ntpq/ntpq.vcproj -> ports/winnt/vs2008/ntpq.vcproj + +ChangeSet@1.1968.1.5, 2009-08-27 20:02:26+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1292] Minor Windows source tweaks for VC6-era SDK headers. + From Martin Burnicki + + ChangeLog@1.413.1.4, 2009-08-27 20:02:25+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1292] Minor Windows source tweaks for VC6-era SDK headers. + From Martin Burnicki + + ports/winnt/include/config.h@1.75, 2009-08-27 20:02:25+00:00, davehart@shiny.ad.hartbrothers.com +3 -1 + #include before for VC6 header compatibility + unconditionally #define ISC_PLATFORM_HAVEIN6PKTINFO + Thanks Martin Burnicki + + ports/winnt/libisc/interfaceiter.c@1.10, 2009-08-27 20:02:25+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + protect reference to sin6_scope_id with ISC_PLATFORM_HAVESCOPEID for + VC6 SDK headers compatibility + +ChangeSet@1.1972, 2009-08-26 23:42:30-04:00, mayer@pogo.udel.edu +8 -0 + Bug #1289 - separate compiler files for VS 2008 + + ports/winnt/instsrv/instsrv-VS2008.vcproj@1.1, 2009-08-26 23:42:13-04:00, mayer@pogo.udel.edu +253 -0 + Bug #1289 - separate compiler files for VS 2008 + + ports/winnt/instsrv/instsrv-VS2008.vcproj@1.0, 2009-08-26 23:42:13-04:00, mayer@pogo.udel.edu +0 -0 + + ports/winnt/libntp/libntp-VS2008.vcproj@1.1, 2009-08-26 23:42:13-04:00, mayer@pogo.udel.edu +2149 -0 + Bug #1289 - separate compiler files for VS 2008 + + ports/winnt/libntp/libntp-VS2008.vcproj@1.0, 2009-08-26 23:42:13-04:00, mayer@pogo.udel.edu +0 -0 + + ports/winnt/ntp-VS2008.sln@1.1, 2009-08-26 23:42:13-04:00, mayer@pogo.udel.edu +71 -0 + Bug #1289 - separate compiler files for VS 2008 + + ports/winnt/ntp-VS2008.sln@1.0, 2009-08-26 23:42:13-04:00, mayer@pogo.udel.edu +0 -0 + + ports/winnt/ntp-keygen/ntp-keygen-VS2008.vcproj@1.1, 2009-08-26 23:42:13-04:00, mayer@pogo.udel.edu +397 -0 + Bug #1289 - separate compiler files for VS 2008 + + ports/winnt/ntp-keygen/ntp-keygen-VS2008.vcproj@1.0, 2009-08-26 23:42:13-04:00, mayer@pogo.udel.edu +0 -0 + + ports/winnt/ntpd/ntpd-VS2008.vcproj@1.1, 2009-08-26 23:42:13-04:00, mayer@pogo.udel.edu +2235 -0 + Bug #1289 - separate compiler files for VS 2008 + + ports/winnt/ntpd/ntpd-VS2008.vcproj@1.0, 2009-08-26 23:42:13-04:00, mayer@pogo.udel.edu +0 -0 + + ports/winnt/ntpdate/ntpdate-VS2008.vcproj@1.1, 2009-08-26 23:42:13-04:00, mayer@pogo.udel.edu +357 -0 + Bug #1289 - separate compiler files for VS 2008 + + ports/winnt/ntpdate/ntpdate-VS2008.vcproj@1.0, 2009-08-26 23:42:13-04:00, mayer@pogo.udel.edu +0 -0 + + ports/winnt/ntpdc/ntpdc-VS2008.vcproj@1.1, 2009-08-26 23:42:13-04:00, mayer@pogo.udel.edu +362 -0 + Bug #1289 - separate compiler files for VS 2008 + + ports/winnt/ntpdc/ntpdc-VS2008.vcproj@1.0, 2009-08-26 23:42:13-04:00, mayer@pogo.udel.edu +0 -0 + + ports/winnt/ntpq/ntpq-VS2008.vcproj@1.1, 2009-08-26 23:42:13-04:00, mayer@pogo.udel.edu +352 -0 + Bug #1289 - separate compiler files for VS 2008 + + ports/winnt/ntpq/ntpq-VS2008.vcproj@1.0, 2009-08-26 23:42:13-04:00, mayer@pogo.udel.edu +0 -0 + +ChangeSet@1.1968.1.4, 2009-08-26 07:54:28-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P206 + TAG: NTP_4_2_5P206 + + ChangeLog@1.413.1.3, 2009-08-26 07:54:01-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P206 + + ntpd/ntpd-opts.c@1.199, 2009-08-26 07:54:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P206 + + ntpd/ntpd-opts.h@1.199, 2009-08-26 07:54:04-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P206 + + ntpd/ntpd-opts.texi@1.197, 2009-08-26 07:54:05-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P206 + + ntpd/ntpd.1@1.197, 2009-08-26 07:54:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P206 + + ntpdc/ntpdc-opts.c@1.195, 2009-08-26 07:54:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P206 + + ntpdc/ntpdc-opts.h@1.195, 2009-08-26 07:54:07-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P206 + + ntpdc/ntpdc-opts.texi@1.194, 2009-08-26 07:54:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P206 + + ntpdc/ntpdc.1@1.194, 2009-08-26 07:54:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P206 + + ntpq/ntpq-opts.c@1.195, 2009-08-26 07:54:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P206 + + ntpq/ntpq-opts.h@1.195, 2009-08-26 07:54:11-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P206 + + ntpq/ntpq-opts.texi@1.194, 2009-08-26 07:54:11-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P206 + + ntpq/ntpq.1@1.194, 2009-08-26 07:54:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P206 + + ntpsnmpd/ntpsnmpd-opts.c@1.75, 2009-08-26 07:54:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P206 + + ntpsnmpd/ntpsnmpd-opts.h@1.75, 2009-08-26 07:54:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P206 + + ntpsnmpd/ntpsnmpd-opts.texi@1.75, 2009-08-26 07:54:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P206 + + ntpsnmpd/ntpsnmpd.1@1.75, 2009-08-26 07:54:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P206 + + packageinfo.sh@1.209, 2009-08-26 07:54:15-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P206 + + sntp/sntp-opts.c@1.69, 2009-08-26 07:54:16-04:00, stenn@whimsy.udel.edu +11 -11 + NTP_4_2_5P206 + + sntp/sntp-opts.h@1.69, 2009-08-26 07:54:17-04:00, stenn@whimsy.udel.edu +6 -6 + NTP_4_2_5P206 + + sntp/sntp-opts.texi@1.69, 2009-08-26 07:54:17-04:00, stenn@whimsy.udel.edu +11 -9 + NTP_4_2_5P206 + + sntp/sntp.1@1.69, 2009-08-26 07:54:18-04:00, stenn@whimsy.udel.edu +15 -13 + NTP_4_2_5P206 + + util/ntp-keygen-opts.c@1.198, 2009-08-26 07:54:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P206 + + util/ntp-keygen-opts.h@1.198, 2009-08-26 07:54:20-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P206 + + util/ntp-keygen-opts.texi@1.197, 2009-08-26 07:54:21-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P206 + + util/ntp-keygen.1@1.197, 2009-08-26 07:54:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P206 + +ChangeSet@1.1968.1.3, 2009-08-26 04:48:50-04:00, stenn@whimsy.udel.edu +2 -0 + accopt.html typo fixes from Dave Mills + + ChangeLog@1.413.1.2, 2009-08-26 04:48:01-04:00, stenn@whimsy.udel.edu +1 -0 + accopt.html typo fixes from Dave Mills + + html/accopt.html@1.32, 2009-08-26 04:47:07-04:00, stenn@whimsy.udel.edu +3 -3 + accopt.html typo fixes from Dave Mills + +ChangeSet@1.1968.1.2, 2009-08-26 04:14:45-04:00, stenn@whimsy.udel.edu +1 -0 + The 2nd fopen in write_kod_db() must be inside the block. From Dave Hart. + + sntp/kod_management.c@1.12, 2009-08-26 04:14:01-04:00, stenn@whimsy.udel.edu +16 -17 + The 2nd fopen in write_kod_db() must be inside the block. From Dave Hart. + +ChangeSet@1.1968.1.1, 2009-08-26 00:48:46+00:00, davehart@shiny.ad.hartbrothers.com +14 -0 + [Bug 1283] default to remembering KoD in sntp + clean up numerous sntp/kod_management.c bugs + use all addresses resolved from each DNS name + + ChangeLog@1.413.1.1, 2009-08-26 00:48:44+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1283] default to remembering KoD in sntp. + clean up numerous sntp/kod_management.c bugs. + use all addresses resolved from each DNS name. + + configure.ac@1.449, 2009-08-26 00:48:44+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + change "permanent DNS errors" to "permanent DNS failures" to make + it simpler to grep for errors in make.log + + libntp/emalloc.c@1.9, 2009-08-26 00:48:44+00:00, davehart@shiny.ad.hartbrothers.com +22 -9 + send emalloc() and friends fatal error messages to stderr as well as syslog + + ntpd/ntp_config.c@1.209, 2009-08-26 00:48:44+00:00, davehart@shiny.ad.hartbrothers.com +6 -11 + clean up unreferenced locals warnings in free_config_*() + + sntp/configure.ac@1.19, 2009-08-26 00:48:44+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + add NTP_DIR_SEP to define DIR_SEP (/ or \) + + sntp/crypto.c@1.8, 2009-08-26 00:48:44+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + malloc() -> emalloc() + + sntp/kod_management.c@1.11, 2009-08-26 00:48:44+00:00, davehart@shiny.ad.hartbrothers.com +148 -142 + KOD -> KoD + Do not complain about KoD file format if it's named /dev/null + change KoD field separator from colon to space to support IPv6 addresses + save KoD file even if one wasn't loaded + create directories if needed while writing KoD file + clean up confusion over kod_db being an array of pointers or structs + + + sntp/kod_management.h@1.7, 2009-08-26 00:48:44+00:00, davehart@shiny.ad.hartbrothers.com +8 -9 + use time_t for KoD timestamp instead of uint + remove unused items + + sntp/main.c@1.18, 2009-08-26 00:48:44+00:00, davehart@shiny.ad.hartbrothers.com +83 -68 + [Bug 1283] default to remembering KoD in sntp + use all addresses resolved from each DNS name + add test code for KoD DB (disabled by #ifdef) + resolve alloca() implicit decl warnings by eliminating its use + don't treat pkt.refid as zero terminated, it's not + + sntp/netutils.c@1.3, 2009-08-26 00:48:45+00:00, davehart@shiny.ad.hartbrothers.com +5 -5 + malloc() -> emalloc() + + sntp/networking.c@1.24, 2009-08-26 00:48:45+00:00, davehart@shiny.ad.hartbrothers.com +5 -5 + malloc() -> emalloc() + change default broadcast timeout from 60 to 68 since ntpd + broadcasts every 64 seconds + + sntp/sntp-opts.def@1.11, 2009-08-26 00:48:45+00:00, davehart@shiny.ad.hartbrothers.com +11 -17 + Update --kod/-K descrip and doc + use common copyright.def instead of explicit copyright block + Update -b & -t descrip/doc to reflect change to 68 second timeout + + sntp/utilities.c@1.9, 2009-08-26 00:48:45+00:00, davehart@shiny.ad.hartbrothers.com +8 -19 + malloc() -> emalloc() + use pointer cast instead of copy in pkt_output() + + sntp/utilities.h@1.7, 2009-08-26 00:48:45+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + include ntp_stdlib.h for emalloc() + +ChangeSet@1.1971, 2009-08-24 15:25:59-04:00, mayer@pogo.udel.edu +2 -0 + Bug fixes 1289 and 1290 + + ChangeLog@1.414, 2009-08-24 15:25:47-04:00, mayer@pogo.udel.edu +2 -0 + Bug fixes 1289 and 1290 + + ntpd/refclock_oncore.c@1.79, 2009-08-24 15:23:26-04:00, mayer@pogo.udel.edu +1 -1 + [Bug 1290] use macro GETTIMEOFDAY instead of gettimeofday() + +ChangeSet@1.1970, 2009-08-24 15:19:05-04:00, mayer@pogo.udel.edu +1 -0 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/ntp-keygen/ntpkeygen.vcproj@1.1, 2009-08-24 15:18:51-04:00, mayer@pogo.udel.edu +376 -0 + keygen file + + ports/winnt/ntp-keygen/ntpkeygen.vcproj@1.0, 2009-08-24 15:18:51-04:00, mayer@pogo.udel.edu +0 -0 + +ChangeSet@1.1969, 2009-08-24 15:14:02-04:00, mayer@pogo.udel.edu +12 -0 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/libntp/libntp.dsp@1.37, 2009-08-24 15:13:43-04:00, mayer@pogo.udel.edu +4 -0 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/libntp/libntp.vcproj@1.13, 2009-08-24 15:13:44-04:00, mayer@pogo.udel.edu +148 -47 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/ntp-keygen/ntpkeygen.dsp@1.13, 2009-08-24 15:13:44-04:00, mayer@pogo.udel.edu +0 -4 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/ntp.sln@1.4, 2009-08-24 15:13:43-04:00, mayer@pogo.udel.edu +43 -46 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/ntpd/ntpd.dsp@1.33, 2009-08-24 15:13:44-04:00, mayer@pogo.udel.edu +0 -4 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/ntpd/ntpd.vcproj@1.13, 2009-08-24 15:13:44-04:00, mayer@pogo.udel.edu +119 -117 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/ntpdate/ntpdate.dsp@1.17, 2009-08-24 15:13:44-04:00, mayer@pogo.udel.edu +0 -4 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/ntpdate/ntpdate.vcproj@1.5, 2009-08-24 15:13:44-04:00, mayer@pogo.udel.edu +20 -85 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/ntpdc/ntpdc.dsp@1.20, 2009-08-24 15:13:44-04:00, mayer@pogo.udel.edu +0 -4 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/ntpdc/ntpdc.vcproj@1.5, 2009-08-24 15:13:44-04:00, mayer@pogo.udel.edu +20 -46 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/ntpq/ntpq.dsp@1.21, 2009-08-24 15:13:44-04:00, mayer@pogo.udel.edu +0 -4 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/ntpq/ntpq.vcproj@1.4, 2009-08-24 15:13:44-04:00, mayer@pogo.udel.edu +20 -36 + [Bug 1289] Fix compiler files for Windows + +ChangeSet@1.1968, 2009-08-18 07:50:08-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P205 + TAG: NTP_4_2_5P205 + + ChangeLog@1.413, 2009-08-18 07:49:42-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P205 + + ntpd/ntpd-opts.c@1.198, 2009-08-18 07:49:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P205 + + ntpd/ntpd-opts.h@1.198, 2009-08-18 07:49:45-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P205 + + ntpd/ntpd-opts.texi@1.196, 2009-08-18 07:49:46-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P205 + + ntpd/ntpd.1@1.196, 2009-08-18 07:49:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P205 + + ntpdc/ntpdc-opts.c@1.194, 2009-08-18 07:49:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P205 + + ntpdc/ntpdc-opts.h@1.194, 2009-08-18 07:49:48-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P205 + + ntpdc/ntpdc-opts.texi@1.193, 2009-08-18 07:49:48-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P205 + + ntpdc/ntpdc.1@1.193, 2009-08-18 07:49:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P205 + + ntpq/ntpq-opts.c@1.194, 2009-08-18 07:49:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P205 + + ntpq/ntpq-opts.h@1.194, 2009-08-18 07:49:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P205 + + ntpq/ntpq-opts.texi@1.193, 2009-08-18 07:49:52-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P205 + + ntpq/ntpq.1@1.193, 2009-08-18 07:49:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P205 + + ntpsnmpd/ntpsnmpd-opts.c@1.74, 2009-08-18 07:49:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P205 + + ntpsnmpd/ntpsnmpd-opts.h@1.74, 2009-08-18 07:49:55-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P205 + + ntpsnmpd/ntpsnmpd-opts.texi@1.74, 2009-08-18 07:49:55-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P205 + + ntpsnmpd/ntpsnmpd.1@1.74, 2009-08-18 07:49:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P205 + + packageinfo.sh@1.208, 2009-08-18 07:49:57-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P205 + + sntp/sntp-opts.c@1.68, 2009-08-18 07:49:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P205 + + sntp/sntp-opts.h@1.68, 2009-08-18 07:49:58-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P205 + + sntp/sntp-opts.texi@1.68, 2009-08-18 07:49:59-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P205 + + sntp/sntp.1@1.68, 2009-08-18 07:49:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P205 + + util/ntp-keygen-opts.c@1.197, 2009-08-18 07:50:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P205 + + util/ntp-keygen-opts.h@1.197, 2009-08-18 07:50:01-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P205 + + util/ntp-keygen-opts.texi@1.196, 2009-08-18 07:50:02-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P205 + + util/ntp-keygen.1@1.196, 2009-08-18 07:50:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P205 + +ChangeSet@1.1967, 2009-08-18 02:18:21-04:00, stenn@whimsy.udel.edu +2 -0 + accopt.html typo fixes from Dave Mills + + ChangeLog@1.412, 2009-08-18 02:17:27-04:00, stenn@whimsy.udel.edu +1 -0 + accopt.html typo fixes from Dave Mills + + html/accopt.html@1.31, 2009-08-18 02:17:28-04:00, stenn@whimsy.udel.edu +7 -11 + accopt.html typo fixes from Dave Mills + +ChangeSet@1.1966, 2009-08-18 05:05:46+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + [Bug 1285] Log ntpq :config/config-from-file events. + + ChangeLog@1.411, 2009-08-18 05:05:45+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1285] Log ntpq :config/config-from-file events. + + include/ntp_config.h@1.57, 2009-08-18 05:05:45+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + provide source address to config_remotely + + ntpd/ntp_config.c@1.208, 2009-08-18 05:05:45+00:00, davehart@shiny.ad.hartbrothers.com +17 -1 + Log source of each dumpcfg section (startup config or ntpq) + + ntpd/ntp_control.c@1.118, 2009-08-18 05:05:45+00:00, davehart@shiny.ad.hartbrothers.com +52 -30 + [Bug 1285] Log ntpq :config/config-from-file events. + + ntpq/ntpq-subs.c@1.34, 2009-08-18 05:05:46+00:00, davehart@shiny.ad.hartbrothers.com +11 -2 + display each line while sending in ntpq config-from-file + +ChangeSet@1.1965, 2009-08-17 16:32:18+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1286] dumpcfg omits statsdir, mangles filegen + + ChangeLog@1.410, 2009-08-17 16:32:18+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1286] dumpcfg omits statsdir, mangles filegen + + ntpd/ntp_config.c@1.207, 2009-08-17 16:32:18+00:00, davehart@shiny.ad.hartbrothers.com +425 -432 + [Bug 1286] dumpcfg omits statsdir, mangles filegen + rearrange dump output to group related items, come closer to examples + +ChangeSet@1.1964, 2009-08-17 07:50:54-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P204 + TAG: NTP_4_2_5P204 + + ChangeLog@1.409, 2009-08-17 07:50:25-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P204 + + ntpd/ntpd-opts.c@1.197, 2009-08-17 07:50:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P204 + + ntpd/ntpd-opts.h@1.197, 2009-08-17 07:50:29-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P204 + + ntpd/ntpd-opts.texi@1.195, 2009-08-17 07:50:30-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P204 + + ntpd/ntpd.1@1.195, 2009-08-17 07:50:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P204 + + ntpdc/ntpdc-opts.c@1.193, 2009-08-17 07:50:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P204 + + ntpdc/ntpdc-opts.h@1.193, 2009-08-17 07:50:32-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P204 + + ntpdc/ntpdc-opts.texi@1.192, 2009-08-17 07:50:33-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P204 + + ntpdc/ntpdc.1@1.192, 2009-08-17 07:50:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P204 + + ntpq/ntpq-opts.c@1.193, 2009-08-17 07:50:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P204 + + ntpq/ntpq-opts.h@1.193, 2009-08-17 07:50:36-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P204 + + ntpq/ntpq-opts.texi@1.192, 2009-08-17 07:50:37-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P204 + + ntpq/ntpq.1@1.192, 2009-08-17 07:50:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P204 + + ntpsnmpd/ntpsnmpd-opts.c@1.73, 2009-08-17 07:50:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P204 + + ntpsnmpd/ntpsnmpd-opts.h@1.73, 2009-08-17 07:50:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P204 + + ntpsnmpd/ntpsnmpd-opts.texi@1.73, 2009-08-17 07:50:40-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P204 + + ntpsnmpd/ntpsnmpd.1@1.73, 2009-08-17 07:50:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P204 + + packageinfo.sh@1.207, 2009-08-17 07:50:41-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P204 + + sntp/sntp-opts.c@1.67, 2009-08-17 07:50:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P204 + + sntp/sntp-opts.h@1.67, 2009-08-17 07:50:42-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P204 + + sntp/sntp-opts.texi@1.67, 2009-08-17 07:50:42-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P204 + + sntp/sntp.1@1.67, 2009-08-17 07:50:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P204 + + util/ntp-keygen-opts.c@1.196, 2009-08-17 07:50:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P204 + + util/ntp-keygen-opts.h@1.196, 2009-08-17 07:50:45-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P204 + + util/ntp-keygen-opts.texi@1.195, 2009-08-17 07:50:45-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P204 + + util/ntp-keygen.1@1.195, 2009-08-17 07:50:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P204 + +ChangeSet@1.1963, 2009-08-17 03:07:26+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1284] infinite loop in ntpd dumping more than one trustedkey + use free_config_*() routines at exit on DEBUG builds to free + config tree and expose remaining leaks + + ChangeLog@1.408, 2009-08-17 03:07:26+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1284] infinite loop in ntpd dumping more than one trustedkey + + ntpd/ntp_config.c@1.206, 2009-08-17 03:07:26+00:00, davehart@shiny.ad.hartbrothers.com +55 -10 + [Bug 1284] infinite loop in ntpd dumping more than one trustedkey + use free_config_*() routines at exit on DEBUG builds to free + config tree and expose remaining leaks + +ChangeSet@1.1962, 2009-08-16 20:53:29-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P203 + TAG: NTP_4_2_5P203 + + ChangeLog@1.407, 2009-08-16 20:53:03-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P203 + + ntpd/ntpd-opts.c@1.196, 2009-08-16 20:53:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P203 + + ntpd/ntpd-opts.h@1.196, 2009-08-16 20:53:07-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P203 + + ntpd/ntpd-opts.texi@1.194, 2009-08-16 20:53:08-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P203 + + ntpd/ntpd.1@1.194, 2009-08-16 20:53:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P203 + + ntpdc/ntpdc-opts.c@1.192, 2009-08-16 20:53:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P203 + + ntpdc/ntpdc-opts.h@1.192, 2009-08-16 20:53:10-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P203 + + ntpdc/ntpdc-opts.texi@1.191, 2009-08-16 20:53:11-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P203 + + ntpdc/ntpdc.1@1.191, 2009-08-16 20:53:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P203 + + ntpq/ntpq-opts.c@1.192, 2009-08-16 20:53:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P203 + + ntpq/ntpq-opts.h@1.192, 2009-08-16 20:53:13-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P203 + + ntpq/ntpq-opts.texi@1.191, 2009-08-16 20:53:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P203 + + ntpq/ntpq.1@1.191, 2009-08-16 20:53:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P203 + + ntpsnmpd/ntpsnmpd-opts.c@1.72, 2009-08-16 20:53:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P203 + + ntpsnmpd/ntpsnmpd-opts.h@1.72, 2009-08-16 20:53:16-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P203 + + ntpsnmpd/ntpsnmpd-opts.texi@1.72, 2009-08-16 20:53:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P203 + + ntpsnmpd/ntpsnmpd.1@1.72, 2009-08-16 20:53:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P203 + + packageinfo.sh@1.206, 2009-08-16 20:53:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P203 + + sntp/sntp-opts.c@1.66, 2009-08-16 20:53:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P203 + + sntp/sntp-opts.h@1.66, 2009-08-16 20:53:20-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P203 + + sntp/sntp-opts.texi@1.66, 2009-08-16 20:53:21-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P203 + + sntp/sntp.1@1.66, 2009-08-16 20:53:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P203 + + util/ntp-keygen-opts.c@1.195, 2009-08-16 20:53:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P203 + + util/ntp-keygen-opts.h@1.195, 2009-08-16 20:53:22-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P203 + + util/ntp-keygen-opts.texi@1.194, 2009-08-16 20:53:23-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P203 + + util/ntp-keygen.1@1.194, 2009-08-16 20:53:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P203 + +ChangeSet@1.1961, 2009-08-16 17:41:19+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + Add extra heap-checking calls to atexit-invoked routines + dump -4 and -6 switches to server/peer + use %g printf format instead of %f to trim uninformative zeros + switch enable/disable dumper to correct oddball identifiers + Do not free in-use receive buffers at exit to avoid race for now + + ntpd/ntp_config.c@1.205, 2009-08-16 17:41:18+00:00, davehart@shiny.ad.hartbrothers.com +77 -114 + Add extra heap-checking calls to atexit-invoked routines + dump -4 and -6 switches to server/peer + use %g printf format instead of %f to trim uninformative zeros + switch enable/disable dumper to correct oddball identifiers + + ntpd/ntp_util.c@1.74, 2009-08-16 17:41:19+00:00, davehart@shiny.ad.hartbrothers.com +7 -0 + Add extra heap-checking calls to atexit-invoked routines + + ports/winnt/ntpd/ntp_iocompletionport.c@1.48, 2009-08-16 17:41:19+00:00, davehart@shiny.ad.hartbrothers.com +15 -1 + Do not free in-use receive buffers at exit to avoid race for now + Add extra heap-checking calls to atexit-invoked routines + +ChangeSet@1.1960, 2009-08-16 14:08:44+00:00, hart@pogo.udel.edu +1 -0 + ntp_control.c: + include for S_IRUSR, S_IWUSR + + ntpd/ntp_control.c@1.117, 2009-08-16 14:08:33+00:00, hart@pogo.udel.edu +1 -0 + include for S_IRUSR, S_IWUSR + +ChangeSet@1.1959, 2009-08-16 13:59:26+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + ntpq -c "dumpcfg ntp.conf.out" works ok for me now + + include/ntp_config.h@1.56, 2009-08-16 13:59:25+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + rename config_tree.prior to link to reflect use + + ntpd/ntp_config.c@1.204, 2009-08-16 13:59:25+00:00, davehart@shiny.ad.hartbrothers.com +139 -118 + correct merge with ntp-dev regarding default_ntp_signd_socket + rename config_tree.prior to link to reflect use + dump keysdir, keys, trustedkey, requestkey, controlkey + collapse multiple manycastserver, multicastclient lines to one each + correct tinker, tos, restrict dump code to use oddball identifiers + fix ntpq :config (process correct config tree) + + ntpd/ntp_control.c@1.116, 2009-08-16 13:59:25+00:00, davehart@shiny.ad.hartbrothers.com +6 -3 + use macros for open() perm bits, different values on Windows + +ChangeSet@1.1958, 2009-08-16 09:38:50+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + add dumpcfg ChangeLog entry + fix unix build + + ChangeLog@1.406, 2009-08-16 09:38:49+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + Add ntpq -c dumpcfg, Google Summer of Code project of Max Kuehn + + ntpd/ntp_control.c@1.115, 2009-08-16 09:38:49+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + no MAX_PATH on unix apparently + +ChangeSet@1.1957, 2009-08-16 09:31:04+00:00, hart@pogo.udel.edu +2 -0 + ntp_parser.h, ntp_parser.c: + Bison products + + ntpd/ntp_parser.c@1.41, 2009-08-16 09:30:51+00:00, hart@pogo.udel.edu +950 -960 + Bison products + + ntpd/ntp_parser.h@1.24, 2009-08-16 09:30:51+00:00, hart@pogo.udel.edu +133 -135 + Bison products + +ChangeSet@1.1956, 2009-08-16 09:14:30+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ntp_config.c: + use correct union member not union itself + + ntpd/ntp_config.c@1.203, 2009-08-16 09:14:22+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + use correct union member not union itself + +ChangeSet@1.1955, 2009-08-16 09:10:06+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + preserve peer options queue for dumper + remove remnants of "broadcastclient novolley" + dump correct peer keywords (server, pool, etc) + dump peer options (minpoll, iburst, etc) + quote dumped filenames (better to do so only if needed) + dump only to /var/tmp (unix) or %TEMP% (windows) directories + create dump file with 0600 (owner-only) permission + + include/ntp_config.h@1.55, 2009-08-16 09:10:05+00:00, davehart@shiny.ad.hartbrothers.com +1 -5 + preserve peer options queue for dumper + remove remnants of "broadcastclient novolley" + + ntpd/ntp_config.c@1.202, 2009-08-16 09:10:05+00:00, davehart@shiny.ad.hartbrothers.com +152 -28 + preserve peer options queue for dumper + remove remnants of "broadcastclient novolley" + dump correct peer keywords (server, pool, etc) + dump peer options (minpoll, iburst, etc) + quote dumped filenames (better to do so only if needed) + + ntpd/ntp_control.c@1.114, 2009-08-16 09:10:05+00:00, davehart@shiny.ad.hartbrothers.com +27 -10 + dump only to /var/tmp (unix) or %TEMP% (windows) directories + create dump file with 0600 (owner-only) permission + + ntpd/ntp_parser.y@1.36, 2009-08-16 09:10:05+00:00, davehart@shiny.ad.hartbrothers.com +1 -4 + remove remnants of "broadcastclient novolley" + + ports/winnt/include/config.h@1.74, 2009-08-16 09:10:05+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + comment only + +ChangeSet@1.1954, 2009-08-16 04:45:36+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + more ntp_config.c merge cleanup + + ntpd/ntp_config.c@1.201, 2009-08-16 04:45:36+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + more merge cleanup + +ChangeSet@1.1877.3.11, 2009-08-16 02:58:43+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + add default: cases to config dumper switch statements + move variable declarations ahead of code for C compliance + use sizeof(buf) not hardcoded constants + + ntpd/ntp_config.c@1.193.1.8, 2009-08-16 02:58:43+00:00, davehart@shiny.ad.hartbrothers.com +164 -82 + move variable declarations before code for C compliance + add default: cases to config dumper switch statements + + ntpd/ntp_control.c@1.110.1.3, 2009-08-16 02:58:43+00:00, davehart@shiny.ad.hartbrothers.com +9 -10 + use sizeof(buf) not hardcoded constants + + ntpq/ntpq-subs.c@1.30.1.3, 2009-08-16 02:58:43+00:00, davehart@shiny.ad.hartbrothers.com +1 -3 + remove unused local a + +ChangeSet@1.1877.3.10, 2009-08-16 02:47:29+09:00, Amidamaru@yumi.mxiesoft.com +1 -0 + ntp_config.h: + Added source and timestamp to the config_tree structure + + include/ntp_config.h@1.52.1.4, 2009-08-16 02:45:29+09:00, Amidamaru@yumi.mxiesoft.com +9 -0 + Added source and timestamp to the config_tree structure + +ChangeSet@1.1877.3.9, 2009-08-15 02:15:30+09:00, Amidamaru@yumi.mxiesoft.com +3 -0 + ntp_control.c: + Handling the dumpfile argument of the dumpcfg command + ntp_config.c: + Config dumper: Combined the server and fudge output + ntpq-subs.c: + Added the dumpfile argument to the dumpcfg command + + ntpd/ntp_config.c@1.193.1.7, 2009-08-15 02:14:09+09:00, Amidamaru@yumi.mxiesoft.com +38 -5 + Config dumper: Combined the server and fudge output + + ntpd/ntp_control.c@1.110.1.2, 2009-08-15 02:14:58+09:00, Amidamaru@yumi.mxiesoft.com +13 -2 + Handling the dumpfile argument of the dumpcfg command + + ntpq/ntpq-subs.c@1.30.1.2, 2009-08-15 02:13:36+09:00, Amidamaru@yumi.mxiesoft.com +12 -13 + Added the dumpfile argument to the dumpcfg command + +ChangeSet@1.1952, 2009-08-14 07:51:00-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P202 + TAG: NTP_4_2_5P202 + + ChangeLog@1.405, 2009-08-14 07:50:36-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P202 + + ntpd/ntpd-opts.c@1.195, 2009-08-14 07:50:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P202 + + ntpd/ntpd-opts.h@1.195, 2009-08-14 07:50:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P202 + + ntpd/ntpd-opts.texi@1.193, 2009-08-14 07:50:40-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P202 + + ntpd/ntpd.1@1.193, 2009-08-14 07:50:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P202 + + ntpdc/ntpdc-opts.c@1.191, 2009-08-14 07:50:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P202 + + ntpdc/ntpdc-opts.h@1.191, 2009-08-14 07:50:42-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P202 + + ntpdc/ntpdc-opts.texi@1.190, 2009-08-14 07:50:43-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P202 + + ntpdc/ntpdc.1@1.190, 2009-08-14 07:50:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P202 + + ntpq/ntpq-opts.c@1.191, 2009-08-14 07:50:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P202 + + ntpq/ntpq-opts.h@1.191, 2009-08-14 07:50:45-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P202 + + ntpq/ntpq-opts.texi@1.190, 2009-08-14 07:50:46-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P202 + + ntpq/ntpq.1@1.190, 2009-08-14 07:50:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P202 + + ntpsnmpd/ntpsnmpd-opts.c@1.71, 2009-08-14 07:50:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P202 + + ntpsnmpd/ntpsnmpd-opts.h@1.71, 2009-08-14 07:50:48-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P202 + + ntpsnmpd/ntpsnmpd-opts.texi@1.71, 2009-08-14 07:50:49-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P202 + + ntpsnmpd/ntpsnmpd.1@1.71, 2009-08-14 07:50:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P202 + + packageinfo.sh@1.205, 2009-08-14 07:50:51-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P202 + + sntp/sntp-opts.c@1.65, 2009-08-14 07:50:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P202 + + sntp/sntp-opts.h@1.65, 2009-08-14 07:50:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P202 + + sntp/sntp-opts.texi@1.65, 2009-08-14 07:50:53-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P202 + + sntp/sntp.1@1.65, 2009-08-14 07:50:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P202 + + util/ntp-keygen-opts.c@1.194, 2009-08-14 07:50:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P202 + + util/ntp-keygen-opts.h@1.194, 2009-08-14 07:50:54-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P202 + + util/ntp-keygen-opts.texi@1.193, 2009-08-14 07:50:55-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P202 + + util/ntp-keygen.1@1.193, 2009-08-14 07:50:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P202 + +ChangeSet@1.1951, 2009-08-13 16:27:44-04:00, stenn@whimsy.udel.edu +2 -0 + install the binary and man page for sntp + + ChangeLog@1.404, 2009-08-13 16:27:26-04:00, stenn@whimsy.udel.edu +1 -0 + install the binary and man page for sntp + + sntp/Makefile.am@1.10, 2009-08-13 16:27:29-04:00, stenn@whimsy.udel.edu +7 -11 + install the binary and man page for sntp + +ChangeSet@1.1950, 2009-08-13 07:57:57-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P201 + TAG: NTP_4_2_5P201 + + ChangeLog@1.403, 2009-08-13 07:57:29-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P201 + + ntpd/ntpd-opts.c@1.194, 2009-08-13 07:57:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P201 + + ntpd/ntpd-opts.h@1.194, 2009-08-13 07:57:32-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P201 + + ntpd/ntpd-opts.texi@1.192, 2009-08-13 07:57:32-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P201 + + ntpd/ntpd.1@1.192, 2009-08-13 07:57:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P201 + + ntpdc/ntpdc-opts.c@1.190, 2009-08-13 07:57:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P201 + + ntpdc/ntpdc-opts.h@1.190, 2009-08-13 07:57:35-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P201 + + ntpdc/ntpdc-opts.texi@1.189, 2009-08-13 07:57:36-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P201 + + ntpdc/ntpdc.1@1.189, 2009-08-13 07:57:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P201 + + ntpq/ntpq-opts.c@1.190, 2009-08-13 07:57:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P201 + + ntpq/ntpq-opts.h@1.190, 2009-08-13 07:57:38-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P201 + + ntpq/ntpq-opts.texi@1.189, 2009-08-13 07:57:39-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P201 + + ntpq/ntpq.1@1.189, 2009-08-13 07:57:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P201 + + ntpsnmpd/ntpsnmpd-opts.c@1.70, 2009-08-13 07:57:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P201 + + ntpsnmpd/ntpsnmpd-opts.h@1.70, 2009-08-13 07:57:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P201 + + ntpsnmpd/ntpsnmpd-opts.texi@1.70, 2009-08-13 07:57:44-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P201 + + ntpsnmpd/ntpsnmpd.1@1.70, 2009-08-13 07:57:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P201 + + packageinfo.sh@1.204, 2009-08-13 07:57:45-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P201 + + sntp/sntp-opts.c@1.64, 2009-08-13 07:57:46-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P201 + + sntp/sntp-opts.h@1.64, 2009-08-13 07:57:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P201 + + sntp/sntp-opts.texi@1.64, 2009-08-13 07:57:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P201 + + sntp/sntp.1@1.64, 2009-08-13 07:57:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P201 + + util/ntp-keygen-opts.c@1.193, 2009-08-13 07:57:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P201 + + util/ntp-keygen-opts.h@1.193, 2009-08-13 07:57:50-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P201 + + util/ntp-keygen-opts.texi@1.192, 2009-08-13 07:57:51-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P201 + + util/ntp-keygen.1@1.192, 2009-08-13 07:57:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P201 + +ChangeSet@1.1947.1.1, 2009-08-12 07:57:54-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P200 + TAG: NTP_4_2_5P200 + + ChangeLog@1.400.1.1, 2009-08-12 07:57:24-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P200 + + gsoc_sntp/sntp-opts.c@1.61.1.1, 2009-08-12 07:57:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P200 + + gsoc_sntp/sntp-opts.h@1.61.1.1, 2009-08-12 07:57:27-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P200 + + gsoc_sntp/sntp-opts.texi@1.61.1.1, 2009-08-12 07:57:28-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P200 + + gsoc_sntp/sntp.1@1.61.1.1, 2009-08-12 07:57:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P200 + + ntpd/ntpd-opts.c@1.193, 2009-08-12 07:57:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P200 + + ntpd/ntpd-opts.h@1.193, 2009-08-12 07:57:30-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P200 + + ntpd/ntpd-opts.texi@1.191, 2009-08-12 07:57:30-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P200 + + ntpd/ntpd.1@1.191, 2009-08-12 07:57:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P200 + + ntpdc/ntpdc-opts.c@1.189, 2009-08-12 07:57:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P200 + + ntpdc/ntpdc-opts.h@1.189, 2009-08-12 07:57:33-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P200 + + ntpdc/ntpdc-opts.texi@1.188, 2009-08-12 07:57:33-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P200 + + ntpdc/ntpdc.1@1.188, 2009-08-12 07:57:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P200 + + ntpq/ntpq-opts.c@1.189, 2009-08-12 07:57:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P200 + + ntpq/ntpq-opts.h@1.189, 2009-08-12 07:57:36-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P200 + + ntpq/ntpq-opts.texi@1.188, 2009-08-12 07:57:37-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P200 + + ntpq/ntpq.1@1.188, 2009-08-12 07:57:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P200 + + ntpsnmpd/ntpsnmpd-opts.c@1.69, 2009-08-12 07:57:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P200 + + ntpsnmpd/ntpsnmpd-opts.h@1.69, 2009-08-12 07:57:40-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P200 + + ntpsnmpd/ntpsnmpd-opts.texi@1.69, 2009-08-12 07:57:40-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P200 + + ntpsnmpd/ntpsnmpd.1@1.69, 2009-08-12 07:57:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P200 + + packageinfo.sh@1.203, 2009-08-12 07:57:42-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P200 + + sntp/sntp-opts.c@1.188.1.1, 2009-08-12 07:57:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P200 + + sntp/sntp-opts.h@1.188.1.1, 2009-08-12 07:57:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P200 + + sntp/sntp-opts.texi@1.187.1.1, 2009-08-12 07:57:44-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P200 + + sntp/sntp.1@1.187.1.1, 2009-08-12 07:57:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P200 + + util/ntp-keygen-opts.c@1.192, 2009-08-12 07:57:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P200 + + util/ntp-keygen-opts.h@1.192, 2009-08-12 07:57:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P200 + + util/ntp-keygen-opts.texi@1.191, 2009-08-12 07:57:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P200 + + util/ntp-keygen.1@1.191, 2009-08-12 07:57:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P200 + +ChangeSet@1.1948, 2009-08-12 07:09:37-04:00, stenn@whimsy.udel.edu +158 -0 + sntp: out with the old, in with the new + + .point-changed-filelist@1.6, 2009-08-12 07:08:49-04:00, stenn@whimsy.udel.edu +0 -4 + sntp: out with the old, in with the new + + BitKeeper/deleted/.del-COPYING.gplv3@1.2, 2009-08-12 05:40:37-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/COPYING.gplv3 + + BitKeeper/deleted/.del-COPYING.lgplv3@1.2, 2009-08-12 05:40:39-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/COPYING.lgplv3 + + BitKeeper/deleted/.del-COPYING.mbsd~dfd1a50aaa7f1a01@1.2, 2009-08-12 05:40:40-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/COPYING.mbsd + + BitKeeper/deleted/.del-COPYRIGHT@1.3, 2009-08-12 05:40:09-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/COPYRIGHT + + BitKeeper/deleted/.del-MakeDefs.inc~f7b11e92a11b82c@1.2, 2009-08-12 05:40:41-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/MakeDefs.inc + + BitKeeper/deleted/.del-Makefile.am~7eb131bb540e19f2@1.26, 2009-08-12 05:40:10-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/Makefile.am + + BitKeeper/deleted/.del-Makefile.am~84a984572db47579@1.2, 2009-08-12 05:40:42-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/Makefile.am + + BitKeeper/deleted/.del-Mf@1.2, 2009-08-12 05:40:11-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/Mf + + BitKeeper/deleted/.del-README~9ce987ed19d4905a@1.3, 2009-08-12 05:40:12-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/README + + BitKeeper/deleted/.del-README~cb95e57599607dd8@1.3, 2009-08-12 05:40:43-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/README + + BitKeeper/deleted/.del-RFC2030.TXT@1.2, 2009-08-12 05:40:14-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/RFC2030.TXT + + BitKeeper/deleted/.del-RFC4330.TXT@1.2, 2009-08-12 05:40:15-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/RFC4330.TXT + + BitKeeper/deleted/.del-ag-char-map.h@1.5, 2009-08-12 05:40:44-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/ag-char-map.h + + BitKeeper/deleted/.del-autoopts.c~524f4366bd5298d@1.4, 2009-08-12 05:40:46-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.h~8da4370be20d3b14@1.4, 2009-08-12 05:40:47-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts.h + + BitKeeper/deleted/.del-boolean.c~b7c57a2b81d3da1d@1.4, 2009-08-12 05:40:48-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/boolean.c + + BitKeeper/deleted/.del-compat.h~e2f82823ab217382@1.4, 2009-08-12 05:41:35-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/compat.h + + BitKeeper/deleted/.del-configfile.c~107d2e38a77fa938@1.4, 2009-08-12 05:40:49-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/configfile.c + + BitKeeper/deleted/.del-configure.ac@1.24, 2009-08-12 05:40:17-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/configure.ac + + BitKeeper/deleted/.del-cook.c~dabc0ea67f8d04b@1.4, 2009-08-12 05:40:51-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/cook.c + + BitKeeper/deleted/.del-draft-mills-sntp-v4-00.txt@1.2, 2009-08-12 05:40:18-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/draft-mills-sntp-v4-00.txt + + BitKeeper/deleted/.del-enumeration.c~bb2f678a6e7847e4@1.4, 2009-08-12 05:40:53-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/enumeration.c + + BitKeeper/deleted/.del-environment.c~a4572011a478e1f8@1.5, 2009-08-12 05:40:54-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/environment.c + + BitKeeper/deleted/.del-file.c@1.4, 2009-08-12 05:40:56-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/file.c + + BitKeeper/deleted/.del-genshell.c~b902390cefc557fe@1.5, 2009-08-12 05:40:57-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/genshell.c + + BitKeeper/deleted/.del-genshell.h~3aefffa4f2e6155e@1.5, 2009-08-12 05:40:58-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/genshell.h + + BitKeeper/deleted/.del-header.h@1.7, 2009-08-12 05:40:18-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/header.h + + BitKeeper/deleted/.del-internet.c@1.5, 2009-08-12 05:40:20-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/internet.c + + BitKeeper/deleted/.del-internet.h@1.4, 2009-08-12 05:40:21-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/internet.h + + BitKeeper/deleted/.del-kludges.h@1.2, 2009-08-12 05:40:22-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/kludges.h + + BitKeeper/deleted/.del-libopts.c~fa546a962604b990@1.2, 2009-08-12 05:40:59-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/libopts.c + + BitKeeper/deleted/.del-libopts.m4~cea4d9dfe3c6ddbf@1.5, 2009-08-12 05:41:42-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-liboptschk.m4~3a61aba4c71ee48a@1.4, 2009-08-12 05:41:43-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-load.c~d526b4ded3e5d941@1.4, 2009-08-12 05:41:00-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/load.c + + BitKeeper/deleted/.del-ltmain.sh@1.2, 2009-08-12 05:40:23-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/ltmain.sh + + BitKeeper/deleted/.del-main.c@1.11, 2009-08-12 05:40:25-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/main.c + + BitKeeper/deleted/.del-makeshell.c~dcec62d7527150f2@1.4, 2009-08-12 05:41:02-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/makeshell.c + + BitKeeper/deleted/.del-nested.c~9a65b1b3c71987c2@1.4, 2009-08-12 05:41:03-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/nested.c + + BitKeeper/deleted/.del-numeric.c~6843f965b3b4e5d4@1.4, 2009-08-12 05:41:05-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/numeric.c + + BitKeeper/deleted/.del-options.h~756b87b5d8493503@1.5, 2009-08-12 05:41:31-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts/options.h + + BitKeeper/deleted/.del-parse-duration.c@1.2, 2009-08-12 05:41:06-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/parse-duration.c + + BitKeeper/deleted/.del-parse-duration.h@1.2, 2009-08-12 05:41:08-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/parse-duration.h + + BitKeeper/deleted/.del-pathfind.c~d124c4b9c98df625@1.4, 2009-08-12 05:41:36-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pgusage.c~7f2f61c96b4f690@1.4, 2009-08-12 05:41:09-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/pgusage.c + + BitKeeper/deleted/.del-proto.h~3f55e562dfc99640@1.5, 2009-08-12 05:41:10-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/proto.h + + BitKeeper/deleted/.del-putshell.c~6ddb7f83260a15cb@1.4, 2009-08-12 05:41:11-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/putshell.c + + BitKeeper/deleted/.del-reset.c@1.4, 2009-08-12 05:41:12-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/reset.c + + BitKeeper/deleted/.del-restore.c~36055bf073cf20d2@1.4, 2009-08-12 05:41:13-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/restore.c + + BitKeeper/deleted/.del-save.c~818d9fbdc6efce79@1.5, 2009-08-12 05:41:15-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/save.c + + BitKeeper/deleted/.del-snprintf.c~e2a566791af51ab1@1.2, 2009-08-12 05:41:38-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/snprintf.c + + BitKeeper/deleted/.del-sntp-opts.c~4bdc915913c58b8d@1.189, 2009-08-12 05:40:27-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/sntp-opts.c + + BitKeeper/deleted/.del-sntp-opts.def@1.13, 2009-08-12 05:40:28-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/sntp-opts.def + + BitKeeper/deleted/.del-sntp-opts.h~6c9afb942ebc8da5@1.189, 2009-08-12 05:40:29-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/sntp-opts.h + + BitKeeper/deleted/.del-sntp-opts.menu@1.5, 2009-08-12 05:40:30-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/sntp-opts.menu + + BitKeeper/deleted/.del-sntp-opts.texi~a472a50d2839eadc@1.188, 2009-08-12 05:40:31-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/sntp-opts.texi + + BitKeeper/deleted/.del-sntp.1~852b6b2cb9eef68@1.188, 2009-08-12 05:40:33-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/sntp.1 + + BitKeeper/deleted/.del-socket.c@1.9, 2009-08-12 05:40:34-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/socket.c + + BitKeeper/deleted/.del-sort.c~2b3c290f2056ef51@1.4, 2009-08-12 05:41:16-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/sort.c + + BitKeeper/deleted/.del-stack.c~275738ac7e7d319d@1.4, 2009-08-12 05:41:18-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/stack.c + + BitKeeper/deleted/.del-strchr.c~1aac99425a598121@1.2, 2009-08-12 05:41:39-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/strchr.c + + BitKeeper/deleted/.del-strdup.c~5fa61194752a37e3@1.2, 2009-08-12 05:41:40-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/strdup.c + + BitKeeper/deleted/.del-streqvcmp.c~e58f9bd033a84719@1.4, 2009-08-12 05:41:19-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/streqvcmp.c + + BitKeeper/deleted/.del-text_mmap.c~7c49bd8e3f86066f@1.4, 2009-08-12 05:41:21-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/text_mmap.c + + BitKeeper/deleted/.del-time.c@1.4, 2009-08-12 05:41:22-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/time.c + + BitKeeper/deleted/.del-timing.c@1.4, 2009-08-12 05:40:35-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/timing.c + + BitKeeper/deleted/.del-tokenize.c~be5669e7aebf805@1.3, 2009-08-12 05:41:23-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/tokenize.c + + BitKeeper/deleted/.del-unix.c@1.4, 2009-08-12 05:40:37-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/unix.c + + BitKeeper/deleted/.del-usage-txt.h~e9f5b7f89caa54c2@1.5, 2009-08-12 05:41:33-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage.c~84e8c04ecb3c0839@1.4, 2009-08-12 05:41:24-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/usage.c + + BitKeeper/deleted/.del-value-type.c@1.3, 2009-08-12 05:41:26-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/value-type.c + + BitKeeper/deleted/.del-value-type.h@1.5, 2009-08-12 05:41:27-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/value-type.h + + BitKeeper/deleted/.del-version.c~f331be699b32ed05@1.4, 2009-08-12 05:41:28-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/version.c + + BitKeeper/deleted/.del-windows-config.h~c97f2a667a4b84f5@1.4, 2009-08-12 05:41:41-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/windows-config.h + + BitKeeper/deleted/.del-xat-attribute.c@1.3, 2009-08-12 05:41:29-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/xat-attribute.c + + BitKeeper/deleted/.del-xat-attribute.h@1.5, 2009-08-12 05:41:30-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/xat-attribute.h + + ChangeLog@1.401, 2009-08-12 07:08:49-04:00, stenn@whimsy.udel.edu +1 -0 + sntp: out with the old, in with the new + + Makefile.am@1.81, 2009-08-12 07:08:51-04:00, stenn@whimsy.udel.edu +0 -2 + sntp: out with the old, in with the new + + bootstrap@1.23, 2009-08-12 07:08:53-04:00, stenn@whimsy.udel.edu +0 -1 + sntp: out with the old, in with the new + + configure.ac@1.448, 2009-08-12 07:08:54-04:00, stenn@whimsy.udel.edu +0 -1 + sntp: out with the old, in with the new + + sntp/COPYRIGHT@1.2, 2009-08-12 05:42:50-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/COPYRIGHT -> sntp/COPYRIGHT + + sntp/Makefile.am@1.9, 2009-08-12 05:42:50-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/Makefile.am -> sntp/Makefile.am + + sntp/configure.ac@1.18, 2009-08-12 05:42:50-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/configure.ac -> sntp/configure.ac + + sntp/crypto.c@1.7, 2009-08-12 05:42:51-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/crypto.c -> sntp/crypto.c + + sntp/crypto.h@1.5, 2009-08-12 05:42:51-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/crypto.h -> sntp/crypto.h + + sntp/data_formats.h@1.5, 2009-08-12 05:42:51-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/data_formats.h -> sntp/data_formats.h + + sntp/fetch-stubs@1.6, 2009-08-12 05:42:51-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/fetch-stubs -> sntp/fetch-stubs + + sntp/header.h@1.4, 2009-08-12 05:42:51-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/header.h -> sntp/header.h + + sntp/kod_management.c@1.10, 2009-08-12 05:42:52-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/kod_management.c -> sntp/kod_management.c + + sntp/kod_management.h@1.6, 2009-08-12 05:42:52-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/kod_management.h -> sntp/kod_management.h + + sntp/libopts/COPYING.gplv3@1.2, 2009-08-12 05:42:58-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/COPYING.gplv3 -> sntp/libopts/COPYING.gplv3 + + sntp/libopts/COPYING.lgplv3@1.2, 2009-08-12 05:42:58-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/COPYING.lgplv3 -> sntp/libopts/COPYING.lgplv3 + + sntp/libopts/COPYING.mbsd@1.2, 2009-08-12 05:42:59-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/COPYING.mbsd -> sntp/libopts/COPYING.mbsd + + sntp/libopts/MakeDefs.inc@1.2, 2009-08-12 05:42:59-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/MakeDefs.inc -> sntp/libopts/MakeDefs.inc + + sntp/libopts/Makefile.am@1.2, 2009-08-12 05:42:59-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/Makefile.am -> sntp/libopts/Makefile.am + + sntp/libopts/README@1.3, 2009-08-12 05:42:59-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/README -> sntp/libopts/README + + sntp/libopts/ag-char-map.h@1.5, 2009-08-12 05:42:59-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/ag-char-map.h -> sntp/libopts/ag-char-map.h + + sntp/libopts/autoopts.c@1.4, 2009-08-12 05:43:00-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/autoopts.c -> sntp/libopts/autoopts.c + + sntp/libopts/autoopts.h@1.4, 2009-08-12 05:43:00-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/autoopts.h -> sntp/libopts/autoopts.h + + sntp/libopts/autoopts/options.h@1.5, 2009-08-12 05:43:11-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/autoopts/options.h -> sntp/libopts/autoopts/options.h + + sntp/libopts/autoopts/usage-txt.h@1.5, 2009-08-12 05:43:12-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/autoopts/usage-txt.h -> sntp/libopts/autoopts/usage-txt.h + + sntp/libopts/boolean.c@1.4, 2009-08-12 05:43:00-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/boolean.c -> sntp/libopts/boolean.c + + sntp/libopts/compat/compat.h@1.4, 2009-08-12 05:43:13-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/compat/compat.h -> sntp/libopts/compat/compat.h + + sntp/libopts/compat/pathfind.c@1.4, 2009-08-12 05:43:13-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/compat/pathfind.c -> sntp/libopts/compat/pathfind.c + + sntp/libopts/compat/snprintf.c@1.2, 2009-08-12 05:43:14-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/compat/snprintf.c -> sntp/libopts/compat/snprintf.c + + sntp/libopts/compat/strchr.c@1.2, 2009-08-12 05:43:14-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/compat/strchr.c -> sntp/libopts/compat/strchr.c + + sntp/libopts/compat/strdup.c@1.2, 2009-08-12 05:43:14-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/compat/strdup.c -> sntp/libopts/compat/strdup.c + + sntp/libopts/compat/windows-config.h@1.4, 2009-08-12 05:43:14-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/compat/windows-config.h -> sntp/libopts/compat/windows-config.h + + sntp/libopts/configfile.c@1.4, 2009-08-12 05:43:01-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/configfile.c -> sntp/libopts/configfile.c + + sntp/libopts/cook.c@1.4, 2009-08-12 05:43:01-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/cook.c -> sntp/libopts/cook.c + + sntp/libopts/enumeration.c@1.4, 2009-08-12 05:43:02-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/enumeration.c -> sntp/libopts/enumeration.c + + sntp/libopts/environment.c@1.5, 2009-08-12 05:43:02-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/environment.c -> sntp/libopts/environment.c + + sntp/libopts/file.c@1.4, 2009-08-12 05:43:03-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/file.c -> sntp/libopts/file.c + + sntp/libopts/genshell.c@1.5, 2009-08-12 05:43:03-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/genshell.c -> sntp/libopts/genshell.c + + sntp/libopts/genshell.h@1.5, 2009-08-12 05:43:04-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/genshell.h -> sntp/libopts/genshell.h + + sntp/libopts/libopts.c@1.2, 2009-08-12 05:43:04-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/libopts.c -> sntp/libopts/libopts.c + + sntp/libopts/load.c@1.4, 2009-08-12 05:43:04-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/load.c -> sntp/libopts/load.c + + sntp/libopts/m4/libopts.m4@1.5, 2009-08-12 05:43:14-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/m4/libopts.m4 -> sntp/libopts/m4/libopts.m4 + + sntp/libopts/m4/liboptschk.m4@1.4, 2009-08-12 05:43:15-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/m4/liboptschk.m4 -> sntp/libopts/m4/liboptschk.m4 + + sntp/libopts/makeshell.c@1.4, 2009-08-12 05:43:05-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/makeshell.c -> sntp/libopts/makeshell.c + + sntp/libopts/nested.c@1.4, 2009-08-12 05:43:05-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/nested.c -> sntp/libopts/nested.c + + sntp/libopts/numeric.c@1.4, 2009-08-12 05:43:06-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/numeric.c -> sntp/libopts/numeric.c + + sntp/libopts/parse-duration.c@1.2, 2009-08-12 05:43:06-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/parse-duration.c -> sntp/libopts/parse-duration.c + + sntp/libopts/parse-duration.h@1.2, 2009-08-12 05:43:06-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/parse-duration.h -> sntp/libopts/parse-duration.h + + sntp/libopts/pgusage.c@1.4, 2009-08-12 05:43:06-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/pgusage.c -> sntp/libopts/pgusage.c + + sntp/libopts/proto.h@1.5, 2009-08-12 05:43:06-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/proto.h -> sntp/libopts/proto.h + + sntp/libopts/putshell.c@1.4, 2009-08-12 05:43:06-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/putshell.c -> sntp/libopts/putshell.c + + sntp/libopts/reset.c@1.4, 2009-08-12 05:43:07-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/reset.c -> sntp/libopts/reset.c + + sntp/libopts/restore.c@1.4, 2009-08-12 05:43:07-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/restore.c -> sntp/libopts/restore.c + + sntp/libopts/save.c@1.5, 2009-08-12 05:43:07-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/save.c -> sntp/libopts/save.c + + sntp/libopts/sort.c@1.4, 2009-08-12 05:43:08-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/sort.c -> sntp/libopts/sort.c + + sntp/libopts/stack.c@1.4, 2009-08-12 05:43:08-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/stack.c -> sntp/libopts/stack.c + + sntp/libopts/streqvcmp.c@1.4, 2009-08-12 05:43:09-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/streqvcmp.c -> sntp/libopts/streqvcmp.c + + sntp/libopts/text_mmap.c@1.4, 2009-08-12 05:43:09-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/text_mmap.c -> sntp/libopts/text_mmap.c + + sntp/libopts/time.c@1.4, 2009-08-12 05:43:10-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/time.c -> sntp/libopts/time.c + + sntp/libopts/tokenize.c@1.3, 2009-08-12 05:43:10-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/tokenize.c -> sntp/libopts/tokenize.c + + sntp/libopts/usage.c@1.4, 2009-08-12 05:43:11-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/usage.c -> sntp/libopts/usage.c + + sntp/libopts/value-type.c@1.3, 2009-08-12 05:43:11-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/value-type.c -> sntp/libopts/value-type.c + + sntp/libopts/value-type.h@1.5, 2009-08-12 05:43:11-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/value-type.h -> sntp/libopts/value-type.h + + sntp/libopts/version.c@1.4, 2009-08-12 05:43:11-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/version.c -> sntp/libopts/version.c + + sntp/libopts/xat-attribute.c@1.3, 2009-08-12 05:43:11-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/xat-attribute.c -> sntp/libopts/xat-attribute.c + + sntp/libopts/xat-attribute.h@1.5, 2009-08-12 05:43:11-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/libopts/xat-attribute.h -> sntp/libopts/xat-attribute.h + + sntp/log.c@1.9, 2009-08-12 05:42:52-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/log.c -> sntp/log.c + + sntp/log.h@1.6, 2009-08-12 05:42:52-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/log.h -> sntp/log.h + + sntp/ltmain.sh@1.2, 2009-08-12 05:42:52-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/ltmain.sh -> sntp/ltmain.sh + + sntp/main.c@1.17, 2009-08-12 05:42:54-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/main.c -> sntp/main.c + + sntp/netutils.c@1.2, 2009-08-12 05:42:54-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/netutils.c -> sntp/netutils.c + + sntp/netutils.h@1.2, 2009-08-12 05:42:54-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/netutils.h -> sntp/netutils.h + + sntp/networking.c@1.23, 2009-08-12 05:42:54-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/networking.c -> sntp/networking.c + + sntp/networking.h@1.14, 2009-08-12 05:42:55-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/networking.h -> sntp/networking.h + + sntp/sntp-opts.c@1.62, 2009-08-12 05:42:56-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/sntp-opts.c -> sntp/sntp-opts.c + + sntp/sntp-opts.def@1.10, 2009-08-12 05:42:56-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/sntp-opts.def -> sntp/sntp-opts.def + + sntp/sntp-opts.h@1.62, 2009-08-12 05:42:57-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/sntp-opts.h -> sntp/sntp-opts.h + + sntp/sntp-opts.menu@1.2, 2009-08-12 05:42:57-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/sntp-opts.menu -> sntp/sntp-opts.menu + + sntp/sntp-opts.texi@1.62, 2009-08-12 05:42:57-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/sntp-opts.texi -> sntp/sntp-opts.texi + + sntp/sntp.1@1.62, 2009-08-12 05:42:58-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/sntp.1 -> sntp/sntp.1 + + sntp/utilities.c@1.8, 2009-08-12 05:42:58-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/utilities.c -> sntp/utilities.c + + sntp/utilities.h@1.6, 2009-08-12 05:42:58-04:00, stenn@whimsy.udel.edu +0 -0 + Rename: gsoc_sntp/utilities.h -> sntp/utilities.h + +ChangeSet@1.1877.3.7, 2009-08-12 17:25:58+09:00, Amidamaru@yumi.mxiesoft.com +1 -0 + ntp_config.c: + Config dumper: Added fudge output to server/peer output + + ntpd/ntp_config.c@1.193.1.6, 2009-08-12 17:25:22+09:00, Amidamaru@yumi.mxiesoft.com +96 -78 + Config dumper: Added fudge output to server/peer output + +ChangeSet@1.1877.4.1, 2009-08-12 17:09:40+09:00, Amidamaru@yumi.mxiesoft.com +1 -0 + ntp_control.c: + Added handler for dump opcode + + ntpd/ntp_control.c@1.110.1.1, 2009-08-12 17:09:16+09:00, Amidamaru@yumi.mxiesoft.com +25 -0 + Added handler for dump opcode + +ChangeSet@1.1947, 2009-08-10 23:09:52+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1281] Build ntpd on Windows without big SDK download, burn, + and install by checking in essentially unchanging messages.mc build + products to avoid requiring mc.exe, which is not included with VC++ + 2008 EE. + + ChangeLog@1.400, 2009-08-10 23:09:51+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1281] Build ntpd on Windows without big SDK download, burn, + and install by checking in essentially unchanging messages.mc build + products to avoid requiring mc.exe, which is not included with VC++ + 2008 EE. + + ports/winnt/libntp/MSG00001.bin@1.1, 2009-08-10 23:09:03+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + BitKeeper file C:/ntp/ntp-dev-1281/ports/winnt/libntp/MSG00001.bin + + ports/winnt/libntp/MSG00001.bin@1.0, 2009-08-10 23:09:03+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/libntp/messages.h@1.1, 2009-08-10 23:09:09+00:00, davehart@shiny.ad.hartbrothers.com +199 -0 + BitKeeper file C:/ntp/ntp-dev-1281/ports/winnt/libntp/messages.h + + ports/winnt/libntp/messages.h@1.0, 2009-08-10 23:09:09+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/libntp/messages.rc@1.1, 2009-08-10 23:09:09+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + BitKeeper file C:/ntp/ntp-dev-1281/ports/winnt/libntp/messages.rc + + ports/winnt/libntp/messages.rc@1.0, 2009-08-10 23:09:09+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + +ChangeSet@1.1946, 2009-08-09 07:55:30-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P199 + TAG: NTP_4_2_5P199 + + ChangeLog@1.399, 2009-08-09 07:54:56-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P199 + + gsoc_sntp/sntp-opts.c@1.61, 2009-08-09 07:54:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P199 + + gsoc_sntp/sntp-opts.h@1.61, 2009-08-09 07:54:58-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P199 + + gsoc_sntp/sntp-opts.texi@1.61, 2009-08-09 07:54:59-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P199 + + gsoc_sntp/sntp.1@1.61, 2009-08-09 07:55:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P199 + + ntpd/ntpd-opts.c@1.192, 2009-08-09 07:55:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P199 + + ntpd/ntpd-opts.h@1.192, 2009-08-09 07:55:01-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P199 + + ntpd/ntpd-opts.texi@1.190, 2009-08-09 07:55:02-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P199 + + ntpd/ntpd.1@1.190, 2009-08-09 07:55:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P199 + + ntpdc/ntpdc-opts.c@1.188, 2009-08-09 07:55:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P199 + + ntpdc/ntpdc-opts.h@1.188, 2009-08-09 07:55:05-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P199 + + ntpdc/ntpdc-opts.texi@1.187, 2009-08-09 07:55:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P199 + + ntpdc/ntpdc.1@1.187, 2009-08-09 07:55:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P199 + + ntpq/ntpq-opts.c@1.188, 2009-08-09 07:55:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P199 + + ntpq/ntpq-opts.h@1.188, 2009-08-09 07:55:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P199 + + ntpq/ntpq-opts.texi@1.187, 2009-08-09 07:55:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P199 + + ntpq/ntpq.1@1.187, 2009-08-09 07:55:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P199 + + ntpsnmpd/ntpsnmpd-opts.c@1.68, 2009-08-09 07:55:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P199 + + ntpsnmpd/ntpsnmpd-opts.h@1.68, 2009-08-09 07:55:13-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P199 + + ntpsnmpd/ntpsnmpd-opts.texi@1.68, 2009-08-09 07:55:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P199 + + ntpsnmpd/ntpsnmpd.1@1.68, 2009-08-09 07:55:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P199 + + packageinfo.sh@1.202, 2009-08-09 07:55:15-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P199 + + sntp/sntp-opts.c@1.188, 2009-08-09 07:55:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P199 + + sntp/sntp-opts.h@1.188, 2009-08-09 07:55:16-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P199 + + sntp/sntp-opts.texi@1.187, 2009-08-09 07:55:18-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P199 + + sntp/sntp.1@1.187, 2009-08-09 07:55:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P199 + + util/ntp-keygen-opts.c@1.191, 2009-08-09 07:55:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P199 + + util/ntp-keygen-opts.h@1.191, 2009-08-09 07:55:20-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P199 + + util/ntp-keygen-opts.texi@1.190, 2009-08-09 07:55:21-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P199 + + util/ntp-keygen.1@1.190, 2009-08-09 07:55:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P199 + +ChangeSet@1.1945, 2009-08-08 16:39:12-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1279] Cleanup for warnings from Veracode static analysis + + ChangeLog@1.398, 2009-08-08 16:38:57-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1279] Cleanup for warnings from Veracode static analysis + +ChangeSet@1.1944, 2009-08-08 17:30:14+00:00, davehart@shiny.ad.hartbrothers.com +21 -0 + First pass at quieting Veracode static analysis warnings, + mostly buffer manipulation that is already safe but used + unsafe interface functions such as strcpy() and sprintf(). + use emalloc(), estrdup() where appropriate. + + libntp/msyslog.c@1.23, 2009-08-08 17:30:11+00:00, davehart@shiny.ad.hartbrothers.com +7 -6 + use memcpy instead of strcpy to quiet Veracode analysis warning + + libntp/ntp_rfc2553.c@1.39, 2009-08-08 17:30:11+00:00, davehart@shiny.ad.hartbrothers.com +2 -6 + use estrdup() instead of malloc() then strcpy() + + libntp/statestr.c@1.17, 2009-08-08 17:30:11+00:00, davehart@shiny.ad.hartbrothers.com +5 -4 + sprintf() -> snprintf() Veracode + + libparse/parse.c@1.13, 2009-08-08 17:30:11+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + See if cast is enough to quiet Veracode int truncation warning + + ntpd/ntp_config.c@1.199, 2009-08-08 17:30:11+00:00, davehart@shiny.ad.hartbrothers.com +7 -3 + sprintf()->snprintf() + check for unlink() failure + + ntpd/ntp_control.c@1.112, 2009-08-08 17:30:11+00:00, davehart@shiny.ad.hartbrothers.com +28 -27 + strcpy() + strcat() -> snprintf() + strcpy() -> memcpy() + correct 'be" buffer end calculations + + ntpd/ntp_intres.c@1.64, 2009-08-08 17:30:11+00:00, davehart@shiny.ad.hartbrothers.com +7 -3 + check for unlink() failure + ensure zero termination with strncpy() + + ntpd/ntp_io.c@1.295, 2009-08-08 17:30:12+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ensure null termination with strncpy + + ntpd/ntp_scanner.c@1.22, 2009-08-08 17:30:12+00:00, davehart@shiny.ad.hartbrothers.com +30 -5 + bounds-check access to yytext[] + + ntpd/ntp_signd.c@1.2, 2009-08-08 17:30:12+00:00, davehart@shiny.ad.hartbrothers.com +1 -4 + use emalloc() + + ntpd/ntp_util.c@1.73, 2009-08-08 17:30:12+00:00, davehart@shiny.ad.hartbrothers.com +8 -3 + check for rename(), _unlink() failures + + ntpd/ntpd.c@1.106, 2009-08-08 17:30:12+00:00, davehart@shiny.ad.hartbrothers.com +7 -3 + add chdir("/") after chroot(), can't hurt and Veracode wants it + + ntpd/refclock_acts.c@1.36, 2009-08-08 17:30:12+00:00, davehart@shiny.ad.hartbrothers.com +0 -3 + emalloc() never returns NULL + + ntpd/refclock_bancomm.c@1.11, 2009-08-08 17:30:12+00:00, davehart@shiny.ad.hartbrothers.com +2 -3 + use emalloc() + + ntpd/refclock_datum.c@1.13, 2009-08-08 17:30:12+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + use emalloc() + + ntpd/refclock_oncore.c@1.78, 2009-08-08 17:30:12+00:00, davehart@shiny.ad.hartbrothers.com +7 -24 + use emalloc() + + ntpdate/ntpdate.c@1.68, 2009-08-08 17:30:12+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + use emalloc() + + ntpdc/ntpdc.c@1.67, 2009-08-08 17:30:12+00:00, davehart@shiny.ad.hartbrothers.com +1 -5 + use emalloc() + + ntpq/ntpq-subs.c@1.32, 2009-08-08 17:30:12+00:00, davehart@shiny.ad.hartbrothers.com +2 -26 + remove strsave from ntpq, same as libntp's estrdup() + + ports/winnt/libisc/isc_strerror.c@1.8, 2009-08-08 17:30:12+00:00, davehart@shiny.ad.hartbrothers.com +9 -6 + use emalloc() + #undef our strerror() before calling the CRT version, infinite + recursion is no fun + + ports/winnt/ntpd/ntp_iocompletionport.c@1.47, 2009-08-08 17:30:12+00:00, davehart@shiny.ad.hartbrothers.com +8 -5 + calloc() -> emalloc() then memset zero + +ChangeSet@1.1877.3.6, 2009-08-06 12:04:59+00:00, davehart@shiny.ad.hartbrothers.com +8 -0 + maintain history of config trees + + include/ntp_config.h@1.52.1.3, 2009-08-06 12:04:58+00:00, davehart@shiny.ad.hartbrothers.com +2 -40 + remove unused leftovers, add list link field to struct config_tree + + include/ntp_data_structures.h@1.5, 2009-08-06 12:04:58+00:00, davehart@shiny.ad.hartbrothers.com +0 -8 + remove unused s_list + + libntp/ntp_lineedit.c@1.7, 2009-08-06 12:04:58+00:00, davehart@shiny.ad.hartbrothers.com +4 -5 + use estrdup() instead of strdup() + + ntpd/ntp_config.c@1.193.1.5, 2009-08-06 12:04:58+00:00, davehart@shiny.ad.hartbrothers.com +112 -79 + maintain history of config trees + + ntpd/ntp_data_structures.c@1.11, 2009-08-06 12:04:58+00:00, davehart@shiny.ad.hartbrothers.com +5 -2 + make next_node() actually work + + ntpd/ntp_parser.c@1.38.1.1, 2009-08-06 12:04:58+00:00, davehart@shiny.ad.hartbrothers.com +50 -50 + parse to struct config_tree cfgt rather than my_config + + ntpd/ntp_parser.y@1.33.1.1, 2009-08-06 12:04:58+00:00, davehart@shiny.ad.hartbrothers.com +50 -50 + parse to struct config_tree cfgt rather than my_config + + ntpd/ntp_scanner.h@1.7, 2009-08-06 12:04:59+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + parse to struct config_tree cfgt rather than my_config + +ChangeSet@1.1877.3.5, 2009-08-05 21:13:22+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + separate consumption (freeing) of syntax tree from application + by introducing free_config_*() routines for each config_*() + which allocates memory pointed to by a node. + + include/ntpd.h@1.127.1.1, 2009-08-05 21:13:21+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + make sizeof(sys_ttl) work + + ntpd/ntp_config.c@1.193.1.4, 2009-08-05 21:13:21+00:00, davehart@shiny.ad.hartbrothers.com +526 -194 + separate consumption (freeing) of syntax tree from application + by introducing free_config_*() routines for each config_*() + which allocates memory pointed to by a node. + + ntpd/ntp_filegen.c@1.16, 2009-08-05 21:13:21+00:00, davehart@shiny.ad.hartbrothers.com +4 -2 + use bounded copy function (memcpy instead of strcpy) + +ChangeSet@1.1877.3.4, 2009-08-05 14:26:32+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + Dump from config tree not s_list clone + + include/ntp_config.h@1.52.1.2, 2009-08-05 14:26:31+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + Dump from config tree not clone + + include/ntp_data_structures.h@1.4, 2009-08-05 14:26:31+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + add routines to walk queue without destroying + + ntpd/ntp_config.c@1.193.1.3, 2009-08-05 14:26:31+00:00, davehart@shiny.ad.hartbrothers.com +389 -402 + lay groundwork for keeping list of config trees, one from file then + one from each ntpq :config + + ntpd/ntp_data_structures.c@1.10, 2009-08-05 14:26:31+00:00, davehart@shiny.ad.hartbrothers.com +27 -48 + add routines to walk queue without destroying + +ChangeSet@1.1877.3.3, 2009-08-05 00:45:45+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + fix problems compiling as C with Visual C++ + + ntpd/ntp_config.c@1.193.1.2, 2009-08-05 00:45:44+00:00, davehart@shiny.ad.hartbrothers.com +20 -15 + fix problems compiling as C with Visual C++ + + ntpd/ntp_data_structures.c@1.9, 2009-08-05 00:45:44+00:00, davehart@shiny.ad.hartbrothers.com +10 -6 + fix problems compiling as C with Visual C++ + +ChangeSet@1.1877.3.2, 2009-08-04 19:40:02+02:00, amidamaru@melchior.mxiesoft.com +1 -0 + ntp_control.h: + Added dumpcfg bindings + + include/ntp_control.h@1.34.1.1, 2009-08-04 19:39:42+02:00, amidamaru@melchior.mxiesoft.com +1 -0 + Added dumpcfg bindings + +ChangeSet@1.1877.3.1, 2009-08-04 17:31:42+02:00, amidamaru@melchior.mxiesoft.com +5 -0 + ntp_data_structures.h: + Added singly-linked list datatype s_list + ntp_data_structures.c: + Added functions for dealing with singly linked lists + ntp_config.c: + Added config dumper and functions dealing with the linked-list copy of the configuration tree + ntpq-subs.c: + Added config dumper bindings + ntp_config.h: + Added config dumper prototypes + + include/ntp_config.h@1.52.1.1, 2009-08-04 17:25:58+02:00, amidamaru@melchior.mxiesoft.com +43 -0 + Added config dumper prototypes + + include/ntp_data_structures.h@1.3, 2009-08-04 17:25:37+02:00, amidamaru@melchior.mxiesoft.com +10 -0 + Added singly-linked list datatype s_list + + ntpd/ntp_config.c@1.193.1.1, 2009-08-04 17:23:32+02:00, amidamaru@melchior.mxiesoft.com +891 -31 + Added config dumper and functions dealing with the linked-list copy of the configuration tree + + ntpd/ntp_data_structures.c@1.8, 2009-08-04 17:24:59+02:00, amidamaru@melchior.mxiesoft.com +44 -0 + Added functions for dealing with singly linked lists + + ntpq/ntpq-subs.c@1.30.1.1, 2009-08-04 17:29:15+02:00, amidamaru@melchior.mxiesoft.com +33 -1 + Added config dumper bindings + +ChangeSet@1.1943, 2009-08-03 08:00:33-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P198 + TAG: NTP_4_2_5P198 + + ChangeLog@1.397, 2009-08-03 08:00:03-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P198 + + gsoc_sntp/sntp-opts.c@1.60, 2009-08-03 08:00:04-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P198 + + gsoc_sntp/sntp-opts.h@1.60, 2009-08-03 08:00:04-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P198 + + gsoc_sntp/sntp-opts.texi@1.60, 2009-08-03 08:00:05-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P198 + + gsoc_sntp/sntp.1@1.60, 2009-08-03 08:00:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P198 + + ntpd/ntpd-opts.c@1.191, 2009-08-03 08:00:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P198 + + ntpd/ntpd-opts.h@1.191, 2009-08-03 08:00:09-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P198 + + ntpd/ntpd-opts.texi@1.189, 2009-08-03 08:00:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P198 + + ntpd/ntpd.1@1.189, 2009-08-03 08:00:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P198 + + ntpdc/ntpdc-opts.c@1.187, 2009-08-03 08:00:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P198 + + ntpdc/ntpdc-opts.h@1.187, 2009-08-03 08:00:12-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P198 + + ntpdc/ntpdc-opts.texi@1.186, 2009-08-03 08:00:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P198 + + ntpdc/ntpdc.1@1.186, 2009-08-03 08:00:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P198 + + ntpq/ntpq-opts.c@1.187, 2009-08-03 08:00:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P198 + + ntpq/ntpq-opts.h@1.187, 2009-08-03 08:00:16-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P198 + + ntpq/ntpq-opts.texi@1.186, 2009-08-03 08:00:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P198 + + ntpq/ntpq.1@1.186, 2009-08-03 08:00:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P198 + + ntpsnmpd/ntpsnmpd-opts.c@1.67, 2009-08-03 08:00:18-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P198 + + ntpsnmpd/ntpsnmpd-opts.h@1.67, 2009-08-03 08:00:19-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P198 + + ntpsnmpd/ntpsnmpd-opts.texi@1.67, 2009-08-03 08:00:20-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P198 + + ntpsnmpd/ntpsnmpd.1@1.67, 2009-08-03 08:00:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P198 + + packageinfo.sh@1.201, 2009-08-03 08:00:21-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P198 + + sntp/sntp-opts.c@1.187, 2009-08-03 08:00:22-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P198 + + sntp/sntp-opts.h@1.187, 2009-08-03 08:00:22-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P198 + + sntp/sntp-opts.texi@1.186, 2009-08-03 08:00:23-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P198 + + sntp/sntp.1@1.186, 2009-08-03 08:00:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P198 + + util/ntp-keygen-opts.c@1.190, 2009-08-03 08:00:25-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P198 + + util/ntp-keygen-opts.h@1.190, 2009-08-03 08:00:26-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P198 + + util/ntp-keygen-opts.texi@1.189, 2009-08-03 08:00:27-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P198 + + util/ntp-keygen.1@1.189, 2009-08-03 08:00:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P198 + +ChangeSet@1.1940.1.1, 2009-08-03 01:32:51-04:00, stenn@whimsy.udel.edu +115 -0 + Upgraded to autogen-5.9.9-pre5 + + ChangeLog@1.396, 2009-08-03 01:32:38-04:00, stenn@whimsy.udel.edu +1 -0 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/ag-char-map.h@1.4, 2009-08-03 01:28:56-04:00, stenn@whimsy.udel.edu +37 -6 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/autoopts.c@1.3, 2009-08-03 01:28:56-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/autoopts.h@1.3, 2009-08-03 01:28:57-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/autoopts/options.h@1.4, 2009-08-03 01:31:50-04:00, stenn@whimsy.udel.edu +34 -40 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/autoopts/usage-txt.h@1.4, 2009-08-03 01:31:51-04:00, stenn@whimsy.udel.edu +1 -1 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/boolean.c@1.3, 2009-08-03 01:28:58-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/compat/compat.h@1.3, 2009-08-03 01:29:10-04:00, stenn@whimsy.udel.edu +1 -1 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/compat/pathfind.c@1.3, 2009-08-03 01:29:11-04:00, stenn@whimsy.udel.edu +2 -2 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/compat/windows-config.h@1.3, 2009-08-03 01:29:12-04:00, stenn@whimsy.udel.edu +1 -1 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/configfile.c@1.3, 2009-08-03 01:28:58-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/cook.c@1.3, 2009-08-03 01:28:59-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/enumeration.c@1.3, 2009-08-03 01:29:00-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/environment.c@1.4, 2009-08-03 01:29:00-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/file.c@1.3, 2009-08-03 01:29:01-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/genshell.c@1.4, 2009-08-03 01:31:48-04:00, stenn@whimsy.udel.edu +2 -2 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/genshell.h@1.4, 2009-08-03 01:31:49-04:00, stenn@whimsy.udel.edu +2 -2 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/load.c@1.3, 2009-08-03 01:29:01-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/m4/libopts.m4@1.4, 2009-08-03 01:29:12-04:00, stenn@whimsy.udel.edu +2 -2 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/m4/liboptschk.m4@1.3, 2009-08-03 01:29:13-04:00, stenn@whimsy.udel.edu +1 -1 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/makeshell.c@1.3, 2009-08-03 01:29:02-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/nested.c@1.3, 2009-08-03 01:29:02-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/numeric.c@1.3, 2009-08-03 01:29:03-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/pgusage.c@1.3, 2009-08-03 01:29:03-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/proto.h@1.4, 2009-08-03 01:29:03-04:00, stenn@whimsy.udel.edu +1 -1 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/putshell.c@1.3, 2009-08-03 01:29:03-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/reset.c@1.3, 2009-08-03 01:29:04-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/restore.c@1.3, 2009-08-03 01:29:04-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/save.c@1.4, 2009-08-03 01:29:05-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/sort.c@1.3, 2009-08-03 01:29:06-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/stack.c@1.3, 2009-08-03 01:29:06-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/streqvcmp.c@1.3, 2009-08-03 01:29:07-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/text_mmap.c@1.3, 2009-08-03 01:29:08-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/time.c@1.3, 2009-08-03 01:29:08-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/tokenize.c@1.2, 2009-08-03 01:29:09-04:00, stenn@whimsy.udel.edu +2 -2 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/usage.c@1.3, 2009-08-03 01:29:09-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/value-type.h@1.4, 2009-08-03 01:29:10-04:00, stenn@whimsy.udel.edu +1 -1 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/version.c@1.3, 2009-08-03 01:29:10-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/xat-attribute.h@1.4, 2009-08-03 01:29:10-04:00, stenn@whimsy.udel.edu +1 -1 + Upgraded to autogen-5.9.9-pre5 + + libopts/ag-char-map.h@1.4, 2009-08-03 01:29:14-04:00, stenn@whimsy.udel.edu +37 -6 + Upgraded to autogen-5.9.9-pre5 + + libopts/autoopts.c@1.3, 2009-08-03 01:29:14-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/autoopts.h@1.3, 2009-08-03 01:29:15-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/autoopts/options.h@1.4, 2009-08-03 01:31:53-04:00, stenn@whimsy.udel.edu +34 -40 + Upgraded to autogen-5.9.9-pre5 + + libopts/autoopts/usage-txt.h@1.4, 2009-08-03 01:31:54-04:00, stenn@whimsy.udel.edu +1 -1 + Upgraded to autogen-5.9.9-pre5 + + libopts/boolean.c@1.3, 2009-08-03 01:29:16-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/compat/compat.h@1.3, 2009-08-03 01:29:26-04:00, stenn@whimsy.udel.edu +1 -1 + Upgraded to autogen-5.9.9-pre5 + + libopts/compat/pathfind.c@1.3, 2009-08-03 01:29:26-04:00, stenn@whimsy.udel.edu +2 -2 + Upgraded to autogen-5.9.9-pre5 + + libopts/compat/windows-config.h@1.3, 2009-08-03 01:29:27-04:00, stenn@whimsy.udel.edu +1 -1 + Upgraded to autogen-5.9.9-pre5 + + libopts/configfile.c@1.3, 2009-08-03 01:29:16-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/cook.c@1.3, 2009-08-03 01:29:17-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/enumeration.c@1.3, 2009-08-03 01:29:17-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/environment.c@1.4, 2009-08-03 01:29:18-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/file.c@1.3, 2009-08-03 01:29:18-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/genshell.c@1.4, 2009-08-03 01:31:52-04:00, stenn@whimsy.udel.edu +2 -2 + Upgraded to autogen-5.9.9-pre5 + + libopts/genshell.h@1.4, 2009-08-03 01:31:53-04:00, stenn@whimsy.udel.edu +2 -2 + Upgraded to autogen-5.9.9-pre5 + + libopts/load.c@1.3, 2009-08-03 01:29:19-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/m4/libopts.m4@1.4, 2009-08-03 01:29:27-04:00, stenn@whimsy.udel.edu +2 -2 + Upgraded to autogen-5.9.9-pre5 + + libopts/m4/liboptschk.m4@1.3, 2009-08-03 01:29:27-04:00, stenn@whimsy.udel.edu +1 -1 + Upgraded to autogen-5.9.9-pre5 + + libopts/makeshell.c@1.3, 2009-08-03 01:29:19-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/nested.c@1.3, 2009-08-03 01:29:20-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/numeric.c@1.3, 2009-08-03 01:29:20-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/pgusage.c@1.3, 2009-08-03 01:29:20-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/proto.h@1.4, 2009-08-03 01:29:21-04:00, stenn@whimsy.udel.edu +1 -1 + Upgraded to autogen-5.9.9-pre5 + + libopts/putshell.c@1.3, 2009-08-03 01:29:21-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/reset.c@1.3, 2009-08-03 01:29:21-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/restore.c@1.3, 2009-08-03 01:29:21-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/save.c@1.4, 2009-08-03 01:29:22-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/sort.c@1.3, 2009-08-03 01:29:22-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/stack.c@1.3, 2009-08-03 01:29:23-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/streqvcmp.c@1.3, 2009-08-03 01:29:23-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/text_mmap.c@1.3, 2009-08-03 01:29:24-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/time.c@1.3, 2009-08-03 01:29:24-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/tokenize.c@1.2, 2009-08-03 01:29:24-04:00, stenn@whimsy.udel.edu +2 -2 + Upgraded to autogen-5.9.9-pre5 + + libopts/usage.c@1.3, 2009-08-03 01:29:25-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/value-type.h@1.4, 2009-08-03 01:29:25-04:00, stenn@whimsy.udel.edu +1 -1 + Upgraded to autogen-5.9.9-pre5 + + libopts/version.c@1.3, 2009-08-03 01:29:26-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/xat-attribute.h@1.4, 2009-08-03 01:29:26-04:00, stenn@whimsy.udel.edu +1 -1 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/ag-char-map.h@1.4, 2009-08-03 01:29:28-04:00, stenn@whimsy.udel.edu +37 -6 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/autoopts.c@1.3, 2009-08-03 01:29:28-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/autoopts.h@1.3, 2009-08-03 01:29:29-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/autoopts/options.h@1.4, 2009-08-03 01:31:55-04:00, stenn@whimsy.udel.edu +34 -40 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/autoopts/usage-txt.h@1.4, 2009-08-03 01:31:56-04:00, stenn@whimsy.udel.edu +1 -1 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/boolean.c@1.3, 2009-08-03 01:29:29-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/compat/compat.h@1.3, 2009-08-03 01:29:43-04:00, stenn@whimsy.udel.edu +1 -1 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/compat/pathfind.c@1.3, 2009-08-03 01:29:44-04:00, stenn@whimsy.udel.edu +2 -2 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/compat/windows-config.h@1.3, 2009-08-03 01:29:45-04:00, stenn@whimsy.udel.edu +1 -1 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/configfile.c@1.3, 2009-08-03 01:29:30-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/cook.c@1.3, 2009-08-03 01:29:31-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/enumeration.c@1.3, 2009-08-03 01:29:31-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/environment.c@1.4, 2009-08-03 01:29:32-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/file.c@1.3, 2009-08-03 01:29:33-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/genshell.c@1.4, 2009-08-03 01:31:54-04:00, stenn@whimsy.udel.edu +2 -2 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/genshell.h@1.4, 2009-08-03 01:31:54-04:00, stenn@whimsy.udel.edu +2 -2 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/load.c@1.3, 2009-08-03 01:29:33-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/m4/libopts.m4@1.4, 2009-08-03 01:29:45-04:00, stenn@whimsy.udel.edu +2 -2 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/m4/liboptschk.m4@1.3, 2009-08-03 01:29:46-04:00, stenn@whimsy.udel.edu +1 -1 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/makeshell.c@1.3, 2009-08-03 01:29:34-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/nested.c@1.3, 2009-08-03 01:29:35-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/numeric.c@1.3, 2009-08-03 01:29:35-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/pgusage.c@1.3, 2009-08-03 01:29:36-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/proto.h@1.4, 2009-08-03 01:29:36-04:00, stenn@whimsy.udel.edu +1 -1 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/putshell.c@1.3, 2009-08-03 01:29:37-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/reset.c@1.3, 2009-08-03 01:29:37-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/restore.c@1.3, 2009-08-03 01:29:37-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/save.c@1.4, 2009-08-03 01:29:38-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/sort.c@1.3, 2009-08-03 01:29:39-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/stack.c@1.3, 2009-08-03 01:29:39-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/streqvcmp.c@1.3, 2009-08-03 01:29:40-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/text_mmap.c@1.3, 2009-08-03 01:29:41-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/time.c@1.3, 2009-08-03 01:29:41-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/tokenize.c@1.2, 2009-08-03 01:29:41-04:00, stenn@whimsy.udel.edu +2 -2 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/usage.c@1.3, 2009-08-03 01:29:42-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/value-type.h@1.4, 2009-08-03 01:29:43-04:00, stenn@whimsy.udel.edu +1 -1 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/version.c@1.3, 2009-08-03 01:29:43-04:00, stenn@whimsy.udel.edu +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/xat-attribute.h@1.4, 2009-08-03 01:29:43-04:00, stenn@whimsy.udel.edu +1 -1 + Upgraded to autogen-5.9.9-pre5 + +ChangeSet@1.1941, 2009-08-03 05:01:24+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + remove workaround ports/winnt/include/inttypes.h for Autogen 5.98 + problem fixed in 5.99 + + BitKeeper/deleted/.del-inttypes.h~d8eb65583f310a51@1.2, 2009-08-01 16:37:34+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Delete: ports/winnt/include/inttypes.h + + ports/winnt/include/config.h@1.73, 2009-08-03 05:01:23+00:00, davehart@shiny.ad.hartbrothers.com +0 -1 + remove empty inttypes.h workaround for Autogen 5.98 problem fixed in 5.99 + + ports/winnt/libntp/libntp.vcproj@1.12, 2009-08-03 05:01:23+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + add libopts\ag-char-map.h reference, remove workaround inttypes.h + +ChangeSet@1.1940, 2009-07-30 07:53:13-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P197 + TAG: NTP_4_2_5P197 + + ChangeLog@1.395, 2009-07-30 07:52:43-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P197 + + gsoc_sntp/sntp-opts.c@1.59, 2009-07-30 07:52:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P197 + + gsoc_sntp/sntp-opts.h@1.59, 2009-07-30 07:52:46-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P197 + + gsoc_sntp/sntp-opts.texi@1.59, 2009-07-30 07:52:46-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P197 + + gsoc_sntp/sntp.1@1.59, 2009-07-30 07:52:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P197 + + ntpd/ntpd-opts.c@1.190, 2009-07-30 07:52:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P197 + + ntpd/ntpd-opts.h@1.190, 2009-07-30 07:52:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P197 + + ntpd/ntpd-opts.texi@1.188, 2009-07-30 07:52:50-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P197 + + ntpd/ntpd.1@1.188, 2009-07-30 07:52:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P197 + + ntpdc/ntpdc-opts.c@1.186, 2009-07-30 07:52:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P197 + + ntpdc/ntpdc-opts.h@1.186, 2009-07-30 07:52:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P197 + + ntpdc/ntpdc-opts.texi@1.185, 2009-07-30 07:52:53-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P197 + + ntpdc/ntpdc.1@1.185, 2009-07-30 07:52:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P197 + + ntpq/ntpq-opts.c@1.186, 2009-07-30 07:52:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P197 + + ntpq/ntpq-opts.h@1.186, 2009-07-30 07:52:55-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P197 + + ntpq/ntpq-opts.texi@1.185, 2009-07-30 07:52:56-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P197 + + ntpq/ntpq.1@1.185, 2009-07-30 07:52:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P197 + + ntpsnmpd/ntpsnmpd-opts.c@1.66, 2009-07-30 07:52:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P197 + + ntpsnmpd/ntpsnmpd-opts.h@1.66, 2009-07-30 07:52:59-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P197 + + ntpsnmpd/ntpsnmpd-opts.texi@1.66, 2009-07-30 07:53:00-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P197 + + ntpsnmpd/ntpsnmpd.1@1.66, 2009-07-30 07:53:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P197 + + packageinfo.sh@1.200, 2009-07-30 07:53:01-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P197 + + sntp/sntp-opts.c@1.186, 2009-07-30 07:53:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P197 + + sntp/sntp-opts.h@1.186, 2009-07-30 07:53:03-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P197 + + sntp/sntp-opts.texi@1.185, 2009-07-30 07:53:04-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P197 + + sntp/sntp.1@1.185, 2009-07-30 07:53:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P197 + + util/ntp-keygen-opts.c@1.189, 2009-07-30 07:53:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P197 + + util/ntp-keygen-opts.h@1.189, 2009-07-30 07:53:06-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P197 + + util/ntp-keygen-opts.texi@1.188, 2009-07-30 07:53:07-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P197 + + util/ntp-keygen.1@1.188, 2009-07-30 07:53:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P197 + +ChangeSet@1.1939, 2009-07-30 02:38:38-04:00, stenn@whimsy.udel.edu +2 -0 + The build script now has . at the end of PATH for config.guess + + ChangeLog@1.394, 2009-07-30 02:37:46-04:00, stenn@whimsy.udel.edu +1 -0 + The build script now has . at the end of PATH for config.guess + + build@1.29, 2009-07-30 02:37:49-04:00, stenn@whimsy.udel.edu +3 -0 + The build script now has . at the end of PATH for config.guess + +ChangeSet@1.1938, 2009-07-29 07:54:11-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P196 + TAG: NTP_4_2_5P196 + + ChangeLog@1.393, 2009-07-29 07:53:38-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P196 + + gsoc_sntp/sntp-opts.c@1.58, 2009-07-29 07:53:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P196 + + gsoc_sntp/sntp-opts.h@1.58, 2009-07-29 07:53:42-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P196 + + gsoc_sntp/sntp-opts.texi@1.58, 2009-07-29 07:53:42-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P196 + + gsoc_sntp/sntp.1@1.58, 2009-07-29 07:53:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P196 + + ntpd/ntpd-opts.c@1.189, 2009-07-29 07:53:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P196 + + ntpd/ntpd-opts.h@1.189, 2009-07-29 07:53:45-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P196 + + ntpd/ntpd-opts.texi@1.187, 2009-07-29 07:53:45-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P196 + + ntpd/ntpd.1@1.187, 2009-07-29 07:53:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P196 + + ntpdc/ntpdc-opts.c@1.185, 2009-07-29 07:53:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P196 + + ntpdc/ntpdc-opts.h@1.185, 2009-07-29 07:53:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P196 + + ntpdc/ntpdc-opts.texi@1.184, 2009-07-29 07:53:48-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P196 + + ntpdc/ntpdc.1@1.184, 2009-07-29 07:53:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P196 + + ntpq/ntpq-opts.c@1.185, 2009-07-29 07:53:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P196 + + ntpq/ntpq-opts.h@1.185, 2009-07-29 07:53:51-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P196 + + ntpq/ntpq-opts.texi@1.184, 2009-07-29 07:53:52-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P196 + + ntpq/ntpq.1@1.184, 2009-07-29 07:53:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P196 + + ntpsnmpd/ntpsnmpd-opts.c@1.65, 2009-07-29 07:53:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P196 + + ntpsnmpd/ntpsnmpd-opts.h@1.65, 2009-07-29 07:53:55-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P196 + + ntpsnmpd/ntpsnmpd-opts.texi@1.65, 2009-07-29 07:53:55-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P196 + + ntpsnmpd/ntpsnmpd.1@1.65, 2009-07-29 07:53:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P196 + + packageinfo.sh@1.199, 2009-07-29 07:53:57-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P196 + + sntp/sntp-opts.c@1.185, 2009-07-29 07:53:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P196 + + sntp/sntp-opts.h@1.185, 2009-07-29 07:53:58-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P196 + + sntp/sntp-opts.texi@1.184, 2009-07-29 07:53:59-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P196 + + sntp/sntp.1@1.184, 2009-07-29 07:53:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P196 + + util/ntp-keygen-opts.c@1.188, 2009-07-29 07:54:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P196 + + util/ntp-keygen-opts.h@1.188, 2009-07-29 07:54:01-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P196 + + util/ntp-keygen-opts.texi@1.187, 2009-07-29 07:54:02-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P196 + + util/ntp-keygen.1@1.187, 2009-07-29 07:54:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P196 + +ChangeSet@1.1937, 2009-07-29 02:25:28-04:00, stenn@whimsy.udel.edu +1 -0 + Typo fix, and note cvo.sh supports QNX now, too + + ChangeLog@1.392, 2009-07-29 02:25:00-04:00, stenn@whimsy.udel.edu +1 -1 + cvo.sh now supports QNX + + ChangeLog@1.391, 2009-07-29 02:24:22-04:00, stenn@whimsy.udel.edu +1 -1 + typo + +ChangeSet@1.1934.1.1, 2009-07-29 02:03:51-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1276 normal] CID 52: crypto_xmit() may call crypto_alice[23]() with NULL peer + + ChangeLog@1.388.1.1, 2009-07-29 02:03:31-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1276 normal] CID 52: crypto_xmit() may call crypto_alice[23]() with NULL peer + + ntpd/ntp_crypto.c@1.139, 2009-07-29 02:03:33-04:00, stenn@whimsy.udel.edu +9 -0 + [Bug 1276 normal] CID 52: crypto_xmit() may call crypto_alice[23]() with NULL peer + +ChangeSet@1.1935, 2009-07-29 04:13:53+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + [Bug 1272] gsoc_sntp IPv6 build problems under HP-UX 10. + [Bug 1273] CID 10: Palisade leaks unit struct in error path. + [Bug 1274] CID 67: ensure resolve_hosts() output count and pointers + are consistent. + [Bug 1275] CID 45: CID 46: old sntp uses uninitialized guesses[0], + precs[0]. + + + ChangeLog@1.389, 2009-07-29 04:13:53+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + [Bug 1272] gsoc_sntp IPv6 build problems under HP-UX 10. + [Bug 1273] CID 10: Palisade leaks unit struct in error path. + [Bug 1274] CID 67: ensure resolve_hosts() output count and pointers + are consistent. + [Bug 1275] CID 45: CID 46: old sntp uses uninitialized guesses[0], + precs[0]. + + + gsoc_sntp/networking.c@1.22, 2009-07-29 04:13:53+00:00, davehart@shiny.ad.hartbrothers.com +11 -3 + [Bug 1272] gsoc_sntp IPv6 build problems under HP-UX 10. + [Bug 1274] CID 67: ensure resolve_hosts() output count and pointers + are consistent. + + ntpd/ntp_io.c@1.294, 2009-07-29 04:13:53+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + cleanup from sockaddr_u introduction, stoa needs pointer to sockaddr_u not interface + + ntpd/refclock_palisade.c@1.26, 2009-07-29 04:13:53+00:00, davehart@shiny.ad.hartbrothers.com +3 -9 + [Bug 1273] CID 10: Palisade leaks unit struct in error path. + + + sntp/main.c@1.10, 2009-07-29 04:13:53+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1275] CID 45: CID 46: old sntp uses uninitialized guesses[0], + precs[0]. + + +ChangeSet@1.1934, 2009-07-27 07:54:24-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P195 + TAG: NTP_4_2_5P195 + + ChangeLog@1.388, 2009-07-27 07:53:52-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P195 + + gsoc_sntp/sntp-opts.c@1.57, 2009-07-27 07:53:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P195 + + gsoc_sntp/sntp-opts.h@1.57, 2009-07-27 07:53:55-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P195 + + gsoc_sntp/sntp-opts.texi@1.57, 2009-07-27 07:53:56-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P195 + + gsoc_sntp/sntp.1@1.57, 2009-07-27 07:53:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P195 + + ntpd/ntpd-opts.c@1.188, 2009-07-27 07:53:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P195 + + ntpd/ntpd-opts.h@1.188, 2009-07-27 07:53:58-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P195 + + ntpd/ntpd-opts.texi@1.186, 2009-07-27 07:53:59-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P195 + + ntpd/ntpd.1@1.186, 2009-07-27 07:54:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P195 + + ntpdc/ntpdc-opts.c@1.184, 2009-07-27 07:54:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P195 + + ntpdc/ntpdc-opts.h@1.184, 2009-07-27 07:54:02-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P195 + + ntpdc/ntpdc-opts.texi@1.183, 2009-07-27 07:54:02-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P195 + + ntpdc/ntpdc.1@1.183, 2009-07-27 07:54:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P195 + + ntpq/ntpq-opts.c@1.184, 2009-07-27 07:54:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P195 + + ntpq/ntpq-opts.h@1.184, 2009-07-27 07:54:05-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P195 + + ntpq/ntpq-opts.texi@1.183, 2009-07-27 07:54:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P195 + + ntpq/ntpq.1@1.183, 2009-07-27 07:54:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P195 + + ntpsnmpd/ntpsnmpd-opts.c@1.64, 2009-07-27 07:54:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P195 + + ntpsnmpd/ntpsnmpd-opts.h@1.64, 2009-07-27 07:54:09-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P195 + + ntpsnmpd/ntpsnmpd-opts.texi@1.64, 2009-07-27 07:54:10-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P195 + + ntpsnmpd/ntpsnmpd.1@1.64, 2009-07-27 07:54:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P195 + + packageinfo.sh@1.198, 2009-07-27 07:54:12-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P195 + + sntp/sntp-opts.c@1.184, 2009-07-27 07:54:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P195 + + sntp/sntp-opts.h@1.184, 2009-07-27 07:54:13-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P195 + + sntp/sntp-opts.texi@1.183, 2009-07-27 07:54:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P195 + + sntp/sntp.1@1.183, 2009-07-27 07:54:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P195 + + util/ntp-keygen-opts.c@1.187, 2009-07-27 07:54:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P195 + + util/ntp-keygen-opts.h@1.187, 2009-07-27 07:54:17-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P195 + + util/ntp-keygen-opts.texi@1.186, 2009-07-27 07:54:18-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P195 + + util/ntp-keygen.1@1.186, 2009-07-27 07:54:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P195 + +ChangeSet@1.1933, 2009-07-27 06:57:03+00:00, stenn@psp-fb1.ntp.org +2 -0 + cvo.sh: Add support for CentOS, Fedora, Slackware, SuSE + + ChangeLog@1.387, 2009-07-27 06:56:57+00:00, stenn@psp-fb1.ntp.org +1 -0 + cvo.sh: Add support for CentOS, Fedora, Slackware, SuSE + + scripts/cvo.sh@1.3, 2009-07-27 06:56:57+00:00, stenn@psp-fb1.ntp.org +30 -6 + cvo.sh: Add support for CentOS, Fedora, Slackware, SuSE + +ChangeSet@1.1932, 2009-07-26 07:54:22-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P194 + TAG: NTP_4_2_5P194 + + ChangeLog@1.386, 2009-07-26 07:53:51-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P194 + + gsoc_sntp/sntp-opts.c@1.56, 2009-07-26 07:53:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P194 + + gsoc_sntp/sntp-opts.h@1.56, 2009-07-26 07:53:54-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P194 + + gsoc_sntp/sntp-opts.texi@1.56, 2009-07-26 07:53:55-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P194 + + gsoc_sntp/sntp.1@1.56, 2009-07-26 07:53:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P194 + + ntpd/ntpd-opts.c@1.187, 2009-07-26 07:53:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P194 + + ntpd/ntpd-opts.h@1.187, 2009-07-26 07:53:57-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P194 + + ntpd/ntpd-opts.texi@1.185, 2009-07-26 07:53:58-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P194 + + ntpd/ntpd.1@1.185, 2009-07-26 07:53:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P194 + + ntpdc/ntpdc-opts.c@1.183, 2009-07-26 07:53:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P194 + + ntpdc/ntpdc-opts.h@1.183, 2009-07-26 07:54:00-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P194 + + ntpdc/ntpdc-opts.texi@1.182, 2009-07-26 07:54:01-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P194 + + ntpdc/ntpdc.1@1.182, 2009-07-26 07:54:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P194 + + ntpq/ntpq-opts.c@1.183, 2009-07-26 07:54:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P194 + + ntpq/ntpq-opts.h@1.183, 2009-07-26 07:54:04-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P194 + + ntpq/ntpq-opts.texi@1.182, 2009-07-26 07:54:05-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P194 + + ntpq/ntpq.1@1.182, 2009-07-26 07:54:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P194 + + ntpsnmpd/ntpsnmpd-opts.c@1.63, 2009-07-26 07:54:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P194 + + ntpsnmpd/ntpsnmpd-opts.h@1.63, 2009-07-26 07:54:07-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P194 + + ntpsnmpd/ntpsnmpd-opts.texi@1.63, 2009-07-26 07:54:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P194 + + ntpsnmpd/ntpsnmpd.1@1.63, 2009-07-26 07:54:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P194 + + packageinfo.sh@1.197, 2009-07-26 07:54:10-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P194 + + sntp/sntp-opts.c@1.183, 2009-07-26 07:54:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P194 + + sntp/sntp-opts.h@1.183, 2009-07-26 07:54:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P194 + + sntp/sntp-opts.texi@1.182, 2009-07-26 07:54:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P194 + + sntp/sntp.1@1.182, 2009-07-26 07:54:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P194 + + util/ntp-keygen-opts.c@1.186, 2009-07-26 07:54:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P194 + + util/ntp-keygen-opts.h@1.186, 2009-07-26 07:54:15-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P194 + + util/ntp-keygen-opts.texi@1.185, 2009-07-26 07:54:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P194 + + util/ntp-keygen.1@1.185, 2009-07-26 07:54:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P194 + +ChangeSet@1.1931, 2009-07-25 22:36:56-04:00, stenn@psp-deb1.ntp.org +1 -0 + Handle debian + + scripts/cvo.sh@1.2, 2009-07-25 22:36:49-04:00, stenn@psp-deb1.ntp.org +5 -0 + Handle debian + +ChangeSet@1.1930, 2009-07-25 22:36:32-04:00, stenn@psp-deb1.ntp.org +1 -0 + better sanity checking in "build" + + build@1.28, 2009-07-25 22:36:27-04:00, stenn@psp-deb1.ntp.org +3 -0 + better sanity checking in "build" + +ChangeSet@1.1929, 2009-07-25 21:47:07-04:00, stenn@whimsy.udel.edu +2 -0 + Documentation updates from Dave Mills + + ChangeLog@1.385, 2009-07-25 21:46:51-04:00, stenn@whimsy.udel.edu +1 -0 + Documentation updates from Dave Mills + + html/debug.html@1.27, 2009-07-25 21:46:54-04:00, stenn@whimsy.udel.edu +6 -5 + Documentation updates from Dave Mills + +ChangeSet@1.1928, 2009-07-25 21:41:08-04:00, stenn@whimsy.udel.edu +3 -0 + Use scripts/cvo.sh in the build script to get better subdir names + + ChangeLog@1.384, 2009-07-25 21:40:18-04:00, stenn@whimsy.udel.edu +1 -0 + Use scripts/cvo.sh in the build script to get better subdir names + + build@1.27, 2009-07-25 21:40:20-04:00, stenn@whimsy.udel.edu +1 -1 + Use scripts/cvo.sh in the build script to get better subdir names + + scripts/cvo.sh@1.1, 2009-07-25 21:39:14-04:00, stenn@whimsy.udel.edu +120 -0 + BitKeeper file /deacon/backroom/ntp-dev/scripts/cvo.sh + + scripts/cvo.sh@1.0, 2009-07-25 21:39:14-04:00, stenn@whimsy.udel.edu +0 -0 + +ChangeSet@1.1927, 2009-07-25 07:54:56-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P193 + TAG: NTP_4_2_5P193 + + ChangeLog@1.383, 2009-07-25 07:54:24-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P193 + + gsoc_sntp/sntp-opts.c@1.55, 2009-07-25 07:54:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P193 + + gsoc_sntp/sntp-opts.h@1.55, 2009-07-25 07:54:26-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P193 + + gsoc_sntp/sntp-opts.texi@1.55, 2009-07-25 07:54:27-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P193 + + gsoc_sntp/sntp.1@1.55, 2009-07-25 07:54:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P193 + + ntpd/ntpd-opts.c@1.186, 2009-07-25 07:54:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P193 + + ntpd/ntpd-opts.h@1.186, 2009-07-25 07:54:29-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P193 + + ntpd/ntpd-opts.texi@1.184, 2009-07-25 07:54:30-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P193 + + ntpd/ntpd.1@1.184, 2009-07-25 07:54:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P193 + + ntpdc/ntpdc-opts.c@1.182, 2009-07-25 07:54:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P193 + + ntpdc/ntpdc-opts.h@1.182, 2009-07-25 07:54:32-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P193 + + ntpdc/ntpdc-opts.texi@1.181, 2009-07-25 07:54:33-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P193 + + ntpdc/ntpdc.1@1.181, 2009-07-25 07:54:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P193 + + ntpq/ntpq-opts.c@1.182, 2009-07-25 07:54:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P193 + + ntpq/ntpq-opts.h@1.182, 2009-07-25 07:54:35-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P193 + + ntpq/ntpq-opts.texi@1.181, 2009-07-25 07:54:36-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P193 + + ntpq/ntpq.1@1.181, 2009-07-25 07:54:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P193 + + ntpsnmpd/ntpsnmpd-opts.c@1.62, 2009-07-25 07:54:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P193 + + ntpsnmpd/ntpsnmpd-opts.h@1.62, 2009-07-25 07:54:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P193 + + ntpsnmpd/ntpsnmpd-opts.texi@1.62, 2009-07-25 07:54:40-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P193 + + ntpsnmpd/ntpsnmpd.1@1.62, 2009-07-25 07:54:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P193 + + packageinfo.sh@1.196, 2009-07-25 07:54:41-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P193 + + sntp/sntp-opts.c@1.182, 2009-07-25 07:54:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P193 + + sntp/sntp-opts.h@1.182, 2009-07-25 07:54:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P193 + + sntp/sntp-opts.texi@1.181, 2009-07-25 07:54:44-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P193 + + sntp/sntp.1@1.181, 2009-07-25 07:54:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P193 + + util/ntp-keygen-opts.c@1.185, 2009-07-25 07:54:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P193 + + util/ntp-keygen-opts.h@1.185, 2009-07-25 07:54:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P193 + + util/ntp-keygen-opts.texi@1.184, 2009-07-25 07:54:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P193 + + util/ntp-keygen.1@1.184, 2009-07-25 07:54:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P193 + +ChangeSet@1.1926, 2009-07-25 01:12:25+00:00, davehart@shiny.ad.hartbrothers.com +14 -0 + [Bug 1261] CID 34: simulate_server() rbuf.msg_flags uninitialized. + [Bug 1262] CID 35: xpkt.mac uninitialized in simulate_server(). + [Bug 1263] CID 37: CID 38: CID 40: CID 43: multiple refclocks + uninitialized tm_zone (arc, chronolog, dumbclock, pcf). + [Bug 1264] CID 64: gsoc_sntp on_wire() frees wrong ptr receiving KoD. + [Bug 1265] CID 65: CID 66: gsoc_sntp on_wire() leaks x_pkt, r_pkt. + [Bug 1266] CID 39: datum_pts_start() uninitialized arg.c_ospeed. + [Bug 1267] CID 44: old sntp handle_saving() writes stack garbage to + file when clearing. + [Bug 1268] CID 63: resolve_hosts() leaks error message buffer. + [Bug 1269] CID 74: use assertion to ensure move_fd() does not return + negative descriptors. + [Bug 1270] CID 70: gsoc_sntp recv_bcst_data mdevadr.ipv6mr_interface + uninitialized. + + + ChangeLog@1.382, 2009-07-25 01:12:24+00:00, davehart@shiny.ad.hartbrothers.com +14 -0 + [Bug 1261] CID 34: simulate_server() rbuf.msg_flags uninitialized. + [Bug 1262] CID 35: xpkt.mac uninitialized in simulate_server(). + [Bug 1263] CID 37: CID 38: CID 40: CID 43: multiple refclocks + uninitialized tm_zone (arc, chronolog, dumbclock, pcf). + [Bug 1264] CID 64: gsoc_sntp on_wire() frees wrong ptr receiving KoD. + [Bug 1265] CID 65: CID 66: gsoc_sntp on_wire() leaks x_pkt, r_pkt. + [Bug 1266] CID 39: datum_pts_start() uninitialized arg.c_ospeed. + [Bug 1267] CID 44: old sntp handle_saving() writes stack garbage to + file when clearing. + [Bug 1268] CID 63: resolve_hosts() leaks error message buffer. + [Bug 1269] CID 74: use assertion to ensure move_fd() does not return + negative descriptors. + [Bug 1270] CID 70: gsoc_sntp recv_bcst_data mdevadr.ipv6mr_interface + uninitialized. + + + gsoc_sntp/main.c@1.16, 2009-07-25 01:12:24+00:00, davehart@shiny.ad.hartbrothers.com +7 -10 + [Bug 1264] CID 64: gsoc_sntp on_wire() frees wrong ptr receiving KoD. + [Bug 1265] CID 65: CID 66: gsoc_sntp on_wire() leaks x_pkt, r_pkt. + + + gsoc_sntp/networking.c@1.21, 2009-07-25 01:12:24+00:00, davehart@shiny.ad.hartbrothers.com +3 -3 + [Bug 1268] CID 63: resolve_hosts() leaks error message buffer. + [Bug 1270] CID 70: gsoc_sntp recv_bcst_data mdevadr.ipv6mr_interface + uninitialized. + + + ntpd/ntp_io.c@1.293, 2009-07-25 01:12:24+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1269] CID 74: use assertion to ensure move_fd() does not return + negative descriptors. + + ntpd/ntpsim.c@1.22, 2009-07-25 01:12:24+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1261] CID 34: simulate_server() rbuf.msg_flags uninitialized. + [Bug 1262] CID 35: xpkt.mac uninitialized in simulate_server(). + + + ntpd/refclock_arc.c@1.21, 2009-07-25 01:12:24+00:00, davehart@shiny.ad.hartbrothers.com +129 -127 + [Bug 1263] CID 37: CID 38: CID 40: CID 43: multiple refclocks + uninitialized tm_zone (arc, chronolog, dumbclock, pcf). + + + ntpd/refclock_chronolog.c@1.8, 2009-07-25 01:12:24+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1263] CID 37: CID 38: CID 40: CID 43: multiple refclocks + uninitialized tm_zone (arc, chronolog, dumbclock, pcf). + + + ntpd/refclock_datum.c@1.12, 2009-07-25 01:12:24+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1266] CID 39: datum_pts_start() uninitialized arg.c_ospeed. + + + ntpd/refclock_dumbclock.c@1.13, 2009-07-25 01:12:24+00:00, davehart@shiny.ad.hartbrothers.com +20 -26 + [Bug 1263] CID 37: CID 38: CID 40: CID 43: multiple refclocks + uninitialized tm_zone (arc, chronolog, dumbclock, pcf). + + + ntpd/refclock_pcf.c@1.9, 2009-07-25 01:12:24+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1263] CID 37: CID 38: CID 40: CID 43: multiple refclocks + uninitialized tm_zone (arc, chronolog, dumbclock, pcf). + + + ports/winnt/include/config.h@1.72, 2009-07-25 01:12:24+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + Enable dumbclock, Chronolog refclock drivers in Windows ntpd + + ports/winnt/ntpd/ntpd.dsp@1.32, 2009-07-25 01:12:24+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add refclock_chronolog.c + + ports/winnt/ntpd/ntpd.vcproj@1.12, 2009-07-25 01:12:24+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add refclock_chronolog.c + + sntp/main.c@1.9, 2009-07-25 01:12:24+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + zero stack buffer before writing to file in save_clear operation + +ChangeSet@1.1925, 2009-07-24 08:00:56-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P192 + TAG: NTP_4_2_5P192 + + ChangeLog@1.381, 2009-07-24 08:00:25-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P192 + + gsoc_sntp/sntp-opts.c@1.54, 2009-07-24 08:00:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P192 + + gsoc_sntp/sntp-opts.h@1.54, 2009-07-24 08:00:28-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P192 + + gsoc_sntp/sntp-opts.texi@1.54, 2009-07-24 08:00:28-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P192 + + gsoc_sntp/sntp.1@1.54, 2009-07-24 08:00:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P192 + + ntpd/ntpd-opts.c@1.185, 2009-07-24 08:00:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P192 + + ntpd/ntpd-opts.h@1.185, 2009-07-24 08:00:31-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P192 + + ntpd/ntpd-opts.texi@1.183, 2009-07-24 08:00:32-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P192 + + ntpd/ntpd.1@1.183, 2009-07-24 08:00:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P192 + + ntpdc/ntpdc-opts.c@1.181, 2009-07-24 08:00:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P192 + + ntpdc/ntpdc-opts.h@1.181, 2009-07-24 08:00:34-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P192 + + ntpdc/ntpdc-opts.texi@1.180, 2009-07-24 08:00:35-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P192 + + ntpdc/ntpdc.1@1.180, 2009-07-24 08:00:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P192 + + ntpq/ntpq-opts.c@1.181, 2009-07-24 08:00:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P192 + + ntpq/ntpq-opts.h@1.181, 2009-07-24 08:00:38-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P192 + + ntpq/ntpq-opts.texi@1.180, 2009-07-24 08:00:38-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P192 + + ntpq/ntpq.1@1.180, 2009-07-24 08:00:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P192 + + ntpsnmpd/ntpsnmpd-opts.c@1.61, 2009-07-24 08:00:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P192 + + ntpsnmpd/ntpsnmpd-opts.h@1.61, 2009-07-24 08:00:42-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P192 + + ntpsnmpd/ntpsnmpd-opts.texi@1.61, 2009-07-24 08:00:42-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P192 + + ntpsnmpd/ntpsnmpd.1@1.61, 2009-07-24 08:00:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P192 + + packageinfo.sh@1.195, 2009-07-24 08:00:44-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P192 + + sntp/sntp-opts.c@1.181, 2009-07-24 08:00:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P192 + + sntp/sntp-opts.h@1.181, 2009-07-24 08:00:45-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P192 + + sntp/sntp-opts.texi@1.180, 2009-07-24 08:00:46-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P192 + + sntp/sntp.1@1.180, 2009-07-24 08:00:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P192 + + util/ntp-keygen-opts.c@1.184, 2009-07-24 08:00:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P192 + + util/ntp-keygen-opts.h@1.184, 2009-07-24 08:00:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P192 + + util/ntp-keygen-opts.texi@1.183, 2009-07-24 08:00:50-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P192 + + util/ntp-keygen.1@1.183, 2009-07-24 08:00:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P192 + +ChangeSet@1.1922.1.1, 2009-07-24 06:41:17+00:00, davehart@shiny.ad.hartbrothers.com +13 -0 + [Bug 965] CID 42: ss_family uninitialized. + [Bug 1250] CID 53: kod_init_kod_db() overruns kod_db malloc'd buffer. + [Bug 1251] CID 68: search_entry() mishandles dst argument. + [Bug 1252] CID 32: Quiet Coverity warning with assertion. + [Bug 1253] CID 50: gsoc_sntp/crypto.c auth_init() always returns a + list with one entry. + [Bug 1254] CID 56: tv_to_str() leaks a struct tm each call. + [Bug 1255] CID 55: pkt_output() leaks a copy of each packet. + [Bug 1256] CID 51: Coverity doesn't recognize our assertion macros as + terminal. + [Bug 1257] CID 57: gsoc_sntp auth_init() fails to fclose(keyfile). + [Bug 1258] CID 54: gsoc_sntp resolve_hosts() needs simplification. + [Bug 1259] CID 59: gsoc_sntp recv_bcast_data() fails to free(rdata) + on error paths. + [Bug 1260] CID 60: gsoc_sntp recvpkt() fails to free(rdata). + + + ChangeLog@1.378.1.1, 2009-07-24 06:41:15+00:00, davehart@shiny.ad.hartbrothers.com +15 -0 + [Bug 965] CID 42: ss_family uninitialized. + [Bug 1250] CID 53: kod_init_kod_db() overruns kod_db malloc'd buffer. + [Bug 1251] CID 68: search_entry() mishandles dst argument. + [Bug 1252] CID 32: Quiet Coverity warning with assertion. + [Bug 1253] CID 50: gsoc_sntp/crypto.c auth_init() always returns a + list with one entry. + [Bug 1254] CID 56: tv_to_str() leaks a struct tm each call. + [Bug 1255] CID 55: pkt_output() leaks a copy of each packet. + [Bug 1256] CID 51: Coverity doesn't recognize our assertion macros as + terminal. + [Bug 1257] CID 57: gsoc_sntp auth_init() fails to fclose(keyfile). + [Bug 1258] CID 54: gsoc_sntp resolve_hosts() needs simplification. + [Bug 1259] CID 59: gsoc_sntp recv_bcast_data() fails to free(rdata) + on error paths. + [Bug 1260] CID 60: gsoc_sntp recvpkt() fails to free(rdata). + + + gsoc_sntp/crypto.c@1.6, 2009-07-24 06:41:15+00:00, davehart@shiny.ad.hartbrothers.com +8 -10 + use sizeof(buf) rather than hardcode + [Bug 1253] CID 50: gsoc_sntp/crypto.c auth_init() always returns a + list with one entry. + [Bug 1257] CID 57: gsoc_sntp auth_init() fails to fclose(keyfile). + + + gsoc_sntp/kod_management.c@1.9, 2009-07-24 06:41:15+00:00, davehart@shiny.ad.hartbrothers.com +55 -40 + [Bug 1250] CID 53: kod_init_kod_db() overruns kod_db malloc'd buffer. + [Bug 1251] CID 68: search_entry() mishandles dst argument. + + + gsoc_sntp/main.c@1.15, 2009-07-24 06:41:15+00:00, davehart@shiny.ad.hartbrothers.com +25 -26 + [Bug 1251] CID 68: search_entry() mishandles dst argument. + [Bug 1258] CID 54: gsoc_sntp resolve_hosts() needs simplification. + + + gsoc_sntp/networking.c@1.20, 2009-07-24 06:41:15+00:00, davehart@shiny.ad.hartbrothers.com +35 -58 + [Bug 1258] CID 54: gsoc_sntp resolve_hosts() needs simplification. + [Bug 1259] CID 59: gsoc_sntp recv_bcast_data() fails to free(rdata) + on error paths. + [Bug 1260] CID 60: gsoc_sntp recvpkt() fails to free(rdata). + + + gsoc_sntp/networking.h@1.13, 2009-07-24 06:41:15+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + [Bug 1258] CID 54: gsoc_sntp resolve_hosts() needs simplification. + + + gsoc_sntp/utilities.c@1.7, 2009-07-24 06:41:15+00:00, davehart@shiny.ad.hartbrothers.com +9 -2 + [Bug 1254] CID 56: tv_to_str() leaks a struct tm each call. + [Bug 1255] CID 55: pkt_output() leaks a copy of each packet. + + + include/ntp_assert.h@1.3, 2009-07-24 06:41:15+00:00, davehart@shiny.ad.hartbrothers.com +46 -13 + [Bug 1256] CID 51: Coverity doesn't recognize our assertion macros as + terminal. + + + ntpd/refclock_nmea.c@1.42, 2009-07-24 06:41:15+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 965] CID 42: ss_family uninitialized. + + ntpdc/ntpdc.c@1.66, 2009-07-24 06:41:15+00:00, davehart@shiny.ad.hartbrothers.com +9 -2 + [Bug 1252] CID 32: Quiet Coverity warning with assertion. + + + ports/winnt/libntp/libntp.vcproj@1.11, 2009-07-24 06:41:16+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add ntp_assert.h reference + + ports/winnt/ntpd/ntpd.vcproj@1.11, 2009-07-24 06:41:16+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add ntp_assert.h reference + + ports/winnt/ntpdc/ntpdc.vcproj@1.4, 2009-07-24 06:41:16+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add ntp_assert.h reference + +ChangeSet@1.1923, 2009-07-24 01:21:05-04:00, stenn@whimsy.udel.edu +115 -0 + Upgrade to autogen-5.9.9pre2 + + ChangeLog@1.379, 2009-07-24 01:15:42-04:00, stenn@whimsy.udel.edu +1 -0 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/README@1.2, 2009-07-24 01:15:44-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/ag-char-map.h@1.3, 2009-07-24 01:15:44-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/autoopts.c@1.2, 2009-07-24 01:15:45-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/autoopts.h@1.2, 2009-07-24 01:15:45-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/autoopts/options.h@1.3, 2009-07-24 01:19:46-04:00, stenn@whimsy.udel.edu +2 -2 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/autoopts/usage-txt.h@1.3, 2009-07-24 01:19:47-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/boolean.c@1.2, 2009-07-24 01:15:46-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/compat/compat.h@1.2, 2009-07-24 01:16:00-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/compat/pathfind.c@1.2, 2009-07-24 01:16:01-04:00, stenn@whimsy.udel.edu +2 -2 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/compat/windows-config.h@1.2, 2009-07-24 01:16:02-04:00, stenn@whimsy.udel.edu +3 -3 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/configfile.c@1.2, 2009-07-24 01:15:46-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/cook.c@1.2, 2009-07-24 01:15:47-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/enumeration.c@1.2, 2009-07-24 01:15:48-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/environment.c@1.3, 2009-07-24 01:15:49-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/file.c@1.2, 2009-07-24 01:15:49-04:00, stenn@whimsy.udel.edu +4 -3 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/genshell.c@1.3, 2009-07-24 01:19:44-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/genshell.h@1.3, 2009-07-24 01:19:45-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/load.c@1.2, 2009-07-24 01:15:50-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/m4/libopts.m4@1.3, 2009-07-24 01:16:02-04:00, stenn@whimsy.udel.edu +4 -4 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/m4/liboptschk.m4@1.2, 2009-07-24 01:16:03-04:00, stenn@whimsy.udel.edu +4 -3 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/makeshell.c@1.2, 2009-07-24 01:15:50-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/nested.c@1.2, 2009-07-24 01:15:51-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/numeric.c@1.2, 2009-07-24 01:15:51-04:00, stenn@whimsy.udel.edu +9 -8 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/pgusage.c@1.2, 2009-07-24 01:15:52-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/proto.h@1.3, 2009-07-24 01:15:52-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/putshell.c@1.2, 2009-07-24 01:15:52-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/reset.c@1.2, 2009-07-24 01:15:53-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/restore.c@1.2, 2009-07-24 01:15:53-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/save.c@1.3, 2009-07-24 01:15:54-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/sort.c@1.2, 2009-07-24 01:15:55-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/stack.c@1.2, 2009-07-24 01:15:56-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/streqvcmp.c@1.2, 2009-07-24 01:15:57-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/text_mmap.c@1.2, 2009-07-24 01:15:58-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/time.c@1.2, 2009-07-24 01:15:59-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/usage.c@1.2, 2009-07-24 01:15:59-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/value-type.h@1.3, 2009-07-24 01:15:59-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/version.c@1.2, 2009-07-24 01:16:00-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/xat-attribute.h@1.3, 2009-07-24 01:16:00-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/README@1.2, 2009-07-24 01:16:04-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/ag-char-map.h@1.3, 2009-07-24 01:16:05-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/autoopts.c@1.2, 2009-07-24 01:16:05-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/autoopts.h@1.2, 2009-07-24 01:16:06-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/autoopts/options.h@1.3, 2009-07-24 01:19:47-04:00, stenn@whimsy.udel.edu +2 -2 + Upgrade to autogen-5.9.9pre2 + + libopts/autoopts/usage-txt.h@1.3, 2009-07-24 01:19:48-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/boolean.c@1.2, 2009-07-24 01:16:06-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/compat/compat.h@1.2, 2009-07-24 01:16:16-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/compat/pathfind.c@1.2, 2009-07-24 01:16:17-04:00, stenn@whimsy.udel.edu +2 -2 + Upgrade to autogen-5.9.9pre2 + + libopts/compat/windows-config.h@1.2, 2009-07-24 01:16:18-04:00, stenn@whimsy.udel.edu +3 -3 + Upgrade to autogen-5.9.9pre2 + + libopts/configfile.c@1.2, 2009-07-24 01:16:07-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/cook.c@1.2, 2009-07-24 01:16:07-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/enumeration.c@1.2, 2009-07-24 01:16:08-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/environment.c@1.3, 2009-07-24 01:16:09-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/file.c@1.2, 2009-07-24 01:16:09-04:00, stenn@whimsy.udel.edu +4 -3 + Upgrade to autogen-5.9.9pre2 + + libopts/genshell.c@1.3, 2009-07-24 01:19:47-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/genshell.h@1.3, 2009-07-24 01:19:47-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/load.c@1.2, 2009-07-24 01:16:10-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/m4/libopts.m4@1.3, 2009-07-24 01:16:18-04:00, stenn@whimsy.udel.edu +4 -4 + Upgrade to autogen-5.9.9pre2 + + libopts/m4/liboptschk.m4@1.2, 2009-07-24 01:16:19-04:00, stenn@whimsy.udel.edu +4 -3 + Upgrade to autogen-5.9.9pre2 + + libopts/makeshell.c@1.2, 2009-07-24 01:16:10-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/nested.c@1.2, 2009-07-24 01:16:11-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/numeric.c@1.2, 2009-07-24 01:16:12-04:00, stenn@whimsy.udel.edu +9 -8 + Upgrade to autogen-5.9.9pre2 + + libopts/pgusage.c@1.2, 2009-07-24 01:16:12-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/proto.h@1.3, 2009-07-24 01:16:12-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/putshell.c@1.2, 2009-07-24 01:16:12-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/reset.c@1.2, 2009-07-24 01:16:13-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/restore.c@1.2, 2009-07-24 01:16:13-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/save.c@1.3, 2009-07-24 01:16:13-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/sort.c@1.2, 2009-07-24 01:16:14-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/stack.c@1.2, 2009-07-24 01:16:14-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/streqvcmp.c@1.2, 2009-07-24 01:16:14-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/text_mmap.c@1.2, 2009-07-24 01:16:15-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/time.c@1.2, 2009-07-24 01:16:16-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/usage.c@1.2, 2009-07-24 01:16:16-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/value-type.h@1.3, 2009-07-24 01:16:16-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/version.c@1.2, 2009-07-24 01:16:16-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/xat-attribute.h@1.3, 2009-07-24 01:16:16-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/README@1.2, 2009-07-24 01:16:19-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/ag-char-map.h@1.3, 2009-07-24 01:16:19-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/autoopts.c@1.2, 2009-07-24 01:16:19-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/autoopts.h@1.2, 2009-07-24 01:16:20-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/autoopts/options.h@1.3, 2009-07-24 01:19:50-04:00, stenn@whimsy.udel.edu +2 -2 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/autoopts/usage-txt.h@1.3, 2009-07-24 01:19:51-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/boolean.c@1.2, 2009-07-24 01:16:21-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/compat/compat.h@1.2, 2009-07-24 01:16:36-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/compat/pathfind.c@1.2, 2009-07-24 01:16:37-04:00, stenn@whimsy.udel.edu +2 -2 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/compat/windows-config.h@1.2, 2009-07-24 01:16:37-04:00, stenn@whimsy.udel.edu +3 -3 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/configfile.c@1.2, 2009-07-24 01:16:21-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/cook.c@1.2, 2009-07-24 01:16:22-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/enumeration.c@1.2, 2009-07-24 01:16:23-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/environment.c@1.3, 2009-07-24 01:16:24-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/file.c@1.2, 2009-07-24 01:16:25-04:00, stenn@whimsy.udel.edu +4 -3 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/genshell.c@1.3, 2009-07-24 01:19:48-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/genshell.h@1.3, 2009-07-24 01:19:50-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/load.c@1.2, 2009-07-24 01:16:25-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/m4/libopts.m4@1.3, 2009-07-24 01:16:38-04:00, stenn@whimsy.udel.edu +4 -4 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/m4/liboptschk.m4@1.2, 2009-07-24 01:16:38-04:00, stenn@whimsy.udel.edu +4 -3 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/makeshell.c@1.2, 2009-07-24 01:16:26-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/nested.c@1.2, 2009-07-24 01:16:27-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/numeric.c@1.2, 2009-07-24 01:16:27-04:00, stenn@whimsy.udel.edu +9 -8 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/pgusage.c@1.2, 2009-07-24 01:16:28-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/proto.h@1.3, 2009-07-24 01:16:28-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/putshell.c@1.2, 2009-07-24 01:16:28-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/reset.c@1.2, 2009-07-24 01:16:29-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/restore.c@1.2, 2009-07-24 01:16:30-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/save.c@1.3, 2009-07-24 01:16:30-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/sort.c@1.2, 2009-07-24 01:16:32-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/stack.c@1.2, 2009-07-24 01:16:32-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/streqvcmp.c@1.2, 2009-07-24 01:16:33-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/text_mmap.c@1.2, 2009-07-24 01:16:34-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/time.c@1.2, 2009-07-24 01:16:34-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/usage.c@1.2, 2009-07-24 01:16:34-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/value-type.h@1.3, 2009-07-24 01:16:35-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/version.c@1.2, 2009-07-24 01:16:36-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/xat-attribute.h@1.3, 2009-07-24 01:16:36-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre2 + +ChangeSet@1.1922, 2009-07-21 07:59:39-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P191 + TAG: NTP_4_2_5P191 + + ChangeLog@1.378, 2009-07-21 07:59:06-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P191 + + gsoc_sntp/sntp-opts.c@1.53, 2009-07-21 07:59:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P191 + + gsoc_sntp/sntp-opts.h@1.53, 2009-07-21 07:59:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P191 + + gsoc_sntp/sntp-opts.texi@1.53, 2009-07-21 07:59:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P191 + + gsoc_sntp/sntp.1@1.53, 2009-07-21 07:59:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P191 + + ntpd/ntpd-opts.c@1.184, 2009-07-21 07:59:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P191 + + ntpd/ntpd-opts.h@1.184, 2009-07-21 07:59:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P191 + + ntpd/ntpd-opts.texi@1.182, 2009-07-21 07:59:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P191 + + ntpd/ntpd.1@1.182, 2009-07-21 07:59:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P191 + + ntpdc/ntpdc-opts.c@1.180, 2009-07-21 07:59:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P191 + + ntpdc/ntpdc-opts.h@1.180, 2009-07-21 07:59:16-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P191 + + ntpdc/ntpdc-opts.texi@1.179, 2009-07-21 07:59:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P191 + + ntpdc/ntpdc.1@1.179, 2009-07-21 07:59:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P191 + + ntpq/ntpq-opts.c@1.180, 2009-07-21 07:59:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P191 + + ntpq/ntpq-opts.h@1.180, 2009-07-21 07:59:20-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P191 + + ntpq/ntpq-opts.texi@1.179, 2009-07-21 07:59:21-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P191 + + ntpq/ntpq.1@1.179, 2009-07-21 07:59:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P191 + + ntpsnmpd/ntpsnmpd-opts.c@1.60, 2009-07-21 07:59:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P191 + + ntpsnmpd/ntpsnmpd-opts.h@1.60, 2009-07-21 07:59:24-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P191 + + ntpsnmpd/ntpsnmpd-opts.texi@1.60, 2009-07-21 07:59:24-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P191 + + ntpsnmpd/ntpsnmpd.1@1.60, 2009-07-21 07:59:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P191 + + packageinfo.sh@1.194, 2009-07-21 07:59:26-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P191 + + sntp/sntp-opts.c@1.180, 2009-07-21 07:59:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P191 + + sntp/sntp-opts.h@1.180, 2009-07-21 07:59:27-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P191 + + sntp/sntp-opts.texi@1.179, 2009-07-21 07:59:29-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P191 + + sntp/sntp.1@1.179, 2009-07-21 07:59:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P191 + + util/ntp-keygen-opts.c@1.183, 2009-07-21 07:59:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P191 + + util/ntp-keygen-opts.h@1.183, 2009-07-21 07:59:32-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P191 + + util/ntp-keygen-opts.texi@1.182, 2009-07-21 07:59:33-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P191 + + util/ntp-keygen.1@1.182, 2009-07-21 07:59:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P191 + +ChangeSet@1.1921, 2009-07-21 04:22:31-04:00, stenn@whimsy.udel.edu +40 -0 + Upgrade to autogen-5.9.9pre1 + + ChangeLog@1.377, 2009-07-21 04:22:16-04:00, stenn@whimsy.udel.edu +1 -0 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/ag-char-map.h@1.2, 2009-07-21 04:17:02-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/autoopts/options.h@1.2, 2009-07-21 04:20:15-04:00, stenn@whimsy.udel.edu +2 -2 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/autoopts/usage-txt.h@1.2, 2009-07-21 04:20:16-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/environment.c@1.2, 2009-07-21 04:17:02-04:00, stenn@whimsy.udel.edu +4 -3 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/genshell.c@1.2, 2009-07-21 04:20:14-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/genshell.h@1.2, 2009-07-21 04:20:15-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/m4/libopts.m4@1.2, 2009-07-21 04:17:05-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/proto.h@1.2, 2009-07-21 04:17:03-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/save.c@1.2, 2009-07-21 04:17:03-04:00, stenn@whimsy.udel.edu +4 -3 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/value-type.c@1.2, 2009-07-21 04:17:04-04:00, stenn@whimsy.udel.edu +1 -4 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/value-type.h@1.2, 2009-07-21 04:17:04-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/xat-attribute.c@1.2, 2009-07-21 04:17:04-04:00, stenn@whimsy.udel.edu +1 -4 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/xat-attribute.h@1.2, 2009-07-21 04:17:05-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + libopts/ag-char-map.h@1.2, 2009-07-21 04:17:06-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + libopts/autoopts/options.h@1.2, 2009-07-21 04:20:17-04:00, stenn@whimsy.udel.edu +2 -2 + Upgrade to autogen-5.9.9pre1 + + libopts/autoopts/usage-txt.h@1.2, 2009-07-21 04:20:18-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + libopts/environment.c@1.2, 2009-07-21 04:17:06-04:00, stenn@whimsy.udel.edu +4 -3 + Upgrade to autogen-5.9.9pre1 + + libopts/genshell.c@1.2, 2009-07-21 04:20:16-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + libopts/genshell.h@1.2, 2009-07-21 04:20:17-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + libopts/m4/libopts.m4@1.2, 2009-07-21 04:17:08-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + libopts/proto.h@1.2, 2009-07-21 04:17:07-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + libopts/save.c@1.2, 2009-07-21 04:17:07-04:00, stenn@whimsy.udel.edu +4 -3 + Upgrade to autogen-5.9.9pre1 + + libopts/value-type.c@1.2, 2009-07-21 04:17:07-04:00, stenn@whimsy.udel.edu +1 -4 + Upgrade to autogen-5.9.9pre1 + + libopts/value-type.h@1.2, 2009-07-21 04:17:08-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + libopts/xat-attribute.c@1.2, 2009-07-21 04:17:08-04:00, stenn@whimsy.udel.edu +1 -4 + Upgrade to autogen-5.9.9pre1 + + libopts/xat-attribute.h@1.2, 2009-07-21 04:17:08-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/ag-char-map.h@1.2, 2009-07-21 04:17:09-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/autoopts/options.h@1.2, 2009-07-21 04:20:19-04:00, stenn@whimsy.udel.edu +2 -2 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/autoopts/usage-txt.h@1.2, 2009-07-21 04:20:20-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/environment.c@1.2, 2009-07-21 04:17:09-04:00, stenn@whimsy.udel.edu +4 -3 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/genshell.c@1.2, 2009-07-21 04:20:19-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/genshell.h@1.2, 2009-07-21 04:20:19-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/m4/libopts.m4@1.2, 2009-07-21 04:17:13-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/proto.h@1.2, 2009-07-21 04:17:10-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/save.c@1.2, 2009-07-21 04:17:10-04:00, stenn@whimsy.udel.edu +4 -3 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/value-type.c@1.2, 2009-07-21 04:17:11-04:00, stenn@whimsy.udel.edu +1 -4 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/value-type.h@1.2, 2009-07-21 04:17:12-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/xat-attribute.c@1.2, 2009-07-21 04:17:12-04:00, stenn@whimsy.udel.edu +1 -4 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/xat-attribute.h@1.2, 2009-07-21 04:17:13-04:00, stenn@whimsy.udel.edu +1 -1 + Upgrade to autogen-5.9.9pre1 + +ChangeSet@1.1920, 2009-07-20 08:08:06-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P190 + TAG: NTP_4_2_5P190 + + ChangeLog@1.376, 2009-07-20 08:07:33-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P190 + + gsoc_sntp/sntp-opts.c@1.52, 2009-07-20 08:07:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P190 + + gsoc_sntp/sntp-opts.h@1.52, 2009-07-20 08:07:36-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P190 + + gsoc_sntp/sntp-opts.texi@1.52, 2009-07-20 08:07:37-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P190 + + gsoc_sntp/sntp.1@1.52, 2009-07-20 08:07:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P190 + + ntpd/ntpd-opts.c@1.183, 2009-07-20 08:07:38-04:00, stenn@whimsy.udel.edu +66 -60 + NTP_4_2_5P190 + + ntpd/ntpd-opts.h@1.183, 2009-07-20 08:07:40-04:00, stenn@whimsy.udel.edu +75 -56 + NTP_4_2_5P190 + + ntpd/ntpd-opts.texi@1.181, 2009-07-20 08:07:41-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P190 + + ntpd/ntpd.1@1.181, 2009-07-20 08:07:42-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P190 + + ntpdc/ntpdc-opts.c@1.179, 2009-07-20 08:07:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P190 + + ntpdc/ntpdc-opts.h@1.179, 2009-07-20 08:07:44-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P190 + + ntpdc/ntpdc-opts.texi@1.178, 2009-07-20 08:07:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P190 + + ntpdc/ntpdc.1@1.178, 2009-07-20 08:07:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P190 + + ntpq/ntpq-opts.c@1.179, 2009-07-20 08:07:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P190 + + ntpq/ntpq-opts.h@1.179, 2009-07-20 08:07:48-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P190 + + ntpq/ntpq-opts.texi@1.178, 2009-07-20 08:07:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P190 + + ntpq/ntpq.1@1.178, 2009-07-20 08:07:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P190 + + ntpsnmpd/ntpsnmpd-opts.c@1.59, 2009-07-20 08:07:50-04:00, stenn@whimsy.udel.edu +66 -63 + NTP_4_2_5P190 + + ntpsnmpd/ntpsnmpd-opts.h@1.59, 2009-07-20 08:07:51-04:00, stenn@whimsy.udel.edu +48 -29 + NTP_4_2_5P190 + + ntpsnmpd/ntpsnmpd-opts.texi@1.59, 2009-07-20 08:07:53-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P190 + + ntpsnmpd/ntpsnmpd.1@1.59, 2009-07-20 08:07:53-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P190 + + packageinfo.sh@1.193, 2009-07-20 08:07:54-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P190 + + sntp/sntp-opts.c@1.179, 2009-07-20 08:07:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P190 + + sntp/sntp-opts.h@1.179, 2009-07-20 08:07:55-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P190 + + sntp/sntp-opts.texi@1.178, 2009-07-20 08:07:57-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P190 + + sntp/sntp.1@1.178, 2009-07-20 08:07:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P190 + + util/ntp-keygen-opts.c@1.182, 2009-07-20 08:07:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P190 + + util/ntp-keygen-opts.h@1.182, 2009-07-20 08:08:00-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P190 + + util/ntp-keygen-opts.texi@1.181, 2009-07-20 08:08:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P190 + + util/ntp-keygen.1@1.181, 2009-07-20 08:08:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P190 + +ChangeSet@1.1919, 2009-07-20 09:39:06+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + Windows port fixes for new Autogen and libopts + + ports/winnt/include/config.h@1.71, 2009-07-20 09:39:05+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + Windows port fixes for new Autogen and libopts + + ports/winnt/include/inttypes.h@1.1, 2009-07-20 09:39:05+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + add dummy (empty) inttypes.h to work around problem with new libopts + + ports/winnt/include/inttypes.h@1.0, 2009-07-20 09:39:05+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/libntp/libntp.dsp@1.36, 2009-07-20 09:39:05+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add dummy (empty) inttypes.h to work around problem with new libopts + + ports/winnt/libntp/libntp.vcproj@1.10, 2009-07-20 09:39:05+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add dummy (empty) inttypes.h to work around problem with new libopts + +ChangeSet@1.1918, 2009-07-20 05:20:37-04:00, stenn@whimsy.udel.edu +20 -0 + Updated to AutoGen-5.9.8 + + gsoc_sntp/sntp-opts.c@1.51, 2009-07-20 05:19:44-04:00, stenn@whimsy.udel.edu +65 -62 + Updated to AutoGen-5.9.8 + + gsoc_sntp/sntp-opts.h@1.51, 2009-07-20 05:19:44-04:00, stenn@whimsy.udel.edu +56 -37 + Updated to AutoGen-5.9.8 + + gsoc_sntp/sntp-opts.texi@1.51, 2009-07-20 05:19:45-04:00, stenn@whimsy.udel.edu +1 -1 + Updated to AutoGen-5.9.8 + + gsoc_sntp/sntp.1@1.51, 2009-07-20 05:19:45-04:00, stenn@whimsy.udel.edu +4 -4 + Updated to AutoGen-5.9.8 + + ntpdc/ntpdc-opts.c@1.178, 2009-07-20 05:19:46-04:00, stenn@whimsy.udel.edu +67 -68 + Updated to AutoGen-5.9.8 + + ntpdc/ntpdc-opts.h@1.178, 2009-07-20 05:19:47-04:00, stenn@whimsy.udel.edu +54 -35 + Updated to AutoGen-5.9.8 + + ntpdc/ntpdc-opts.texi@1.177, 2009-07-20 05:19:48-04:00, stenn@whimsy.udel.edu +2 -2 + Updated to AutoGen-5.9.8 + + ntpdc/ntpdc.1@1.177, 2009-07-20 05:19:49-04:00, stenn@whimsy.udel.edu +4 -4 + Updated to AutoGen-5.9.8 + + ntpq/ntpq-opts.c@1.178, 2009-07-20 05:19:50-04:00, stenn@whimsy.udel.edu +67 -68 + Updated to AutoGen-5.9.8 + + ntpq/ntpq-opts.h@1.178, 2009-07-20 05:19:51-04:00, stenn@whimsy.udel.edu +52 -33 + Updated to AutoGen-5.9.8 + + ntpq/ntpq-opts.texi@1.177, 2009-07-20 05:19:51-04:00, stenn@whimsy.udel.edu +2 -2 + Updated to AutoGen-5.9.8 + + ntpq/ntpq.1@1.177, 2009-07-20 05:19:52-04:00, stenn@whimsy.udel.edu +4 -4 + Updated to AutoGen-5.9.8 + + sntp/sntp-opts.c@1.178, 2009-07-20 05:19:53-04:00, stenn@whimsy.udel.edu +81 -81 + Updated to AutoGen-5.9.8 + + sntp/sntp-opts.h@1.178, 2009-07-20 05:19:54-04:00, stenn@whimsy.udel.edu +52 -33 + Updated to AutoGen-5.9.8 + + sntp/sntp-opts.texi@1.177, 2009-07-20 05:19:55-04:00, stenn@whimsy.udel.edu +1 -1 + Updated to AutoGen-5.9.8 + + sntp/sntp.1@1.177, 2009-07-20 05:19:56-04:00, stenn@whimsy.udel.edu +4 -4 + Updated to AutoGen-5.9.8 + + util/ntp-keygen-opts.c@1.181, 2009-07-20 05:19:57-04:00, stenn@whimsy.udel.edu +90 -91 + Updated to AutoGen-5.9.8 + + util/ntp-keygen-opts.h@1.181, 2009-07-20 05:19:58-04:00, stenn@whimsy.udel.edu +62 -43 + Updated to AutoGen-5.9.8 + + util/ntp-keygen-opts.texi@1.180, 2009-07-20 05:19:59-04:00, stenn@whimsy.udel.edu +2 -2 + Updated to AutoGen-5.9.8 + + util/ntp-keygen.1@1.180, 2009-07-20 05:20:00-04:00, stenn@whimsy.udel.edu +4 -4 + Updated to AutoGen-5.9.8 + +ChangeSet@1.1917, 2009-07-20 04:59:15-04:00, stenn@whimsy.udel.edu +1 -0 + Updated to AutoGen-5.9.8 + + gsoc_sntp/Makefile.am@1.8, 2009-07-20 04:58:02-04:00, stenn@whimsy.udel.edu +1 -1 + Updated to AutoGen-5.9.8 + +ChangeSet@1.1916, 2009-07-20 04:52:47-04:00, stenn@whimsy.udel.edu +1 -0 + Updated to AutoGen-5.9.8 + + ChangeLog@1.375, 2009-07-20 04:52:34-04:00, stenn@whimsy.udel.edu +1 -0 + Updated to AutoGen-5.9.8 + +ChangeSet@1.1915, 2009-07-20 04:45:24-04:00, stenn@whimsy.udel.edu +279 -0 + Updated to AutoGen-5.9.8 + + BitKeeper/deleted/.del-COPYING.lgpl~1ddc43fbfc0a8d91@1.2, 2009-07-20 02:43:50-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/COPYING.lgpl + + BitKeeper/deleted/.del-COPYING.lgpl~356acd7e9a658616@1.3, 2009-07-20 04:22:58-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/COPYING.lgpl + + BitKeeper/deleted/.del-COPYING.lgpl~91629dd76e5e4436@1.2, 2009-07-20 02:50:01-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/COPYING.lgpl + + BitKeeper/deleted/.del-COPYING.mbsd~506f41bf4379b14b@1.2, 2009-07-20 02:43:52-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/COPYING.mbsd + + BitKeeper/deleted/.del-COPYING.mbsd~c869a8655e2d3668@1.3, 2009-07-20 04:22:59-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/COPYING.mbsd + + BitKeeper/deleted/.del-COPYING.mbsd~dc651c8bedf8ab57@1.2, 2009-07-20 02:50:03-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/COPYING.mbsd + + BitKeeper/deleted/.del-MakeDefs.inc~31cdb1dbe002e14a@1.2, 2009-07-20 02:43:53-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/MakeDefs.inc + + BitKeeper/deleted/.del-MakeDefs.inc~3c0055ac72058207@1.2, 2009-07-20 02:50:04-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/MakeDefs.inc + + BitKeeper/deleted/.del-MakeDefs.inc~eeacd10582f902ab@1.3, 2009-07-20 04:23:01-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/MakeDefs.inc + + BitKeeper/deleted/.del-Makefile.am~2469a6a54aac94a1@1.3, 2009-07-20 04:23:02-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/Makefile.am + + BitKeeper/deleted/.del-Makefile.am~83bfe0c1134a9dfb@1.2, 2009-07-20 02:50:05-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/Makefile.am + + BitKeeper/deleted/.del-Makefile.am~92f4a0c4f9cd9ea9@1.2, 2009-07-20 02:43:55-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/Makefile.am + + BitKeeper/deleted/.del-README~6c0e8c52bc2917b1@1.2, 2009-07-20 02:43:56-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/README + + BitKeeper/deleted/.del-README~b02c8a60f4cf32fe@1.2, 2009-07-20 02:50:07-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/README + + BitKeeper/deleted/.del-README~f742f7fd37644d2@1.3, 2009-07-20 04:23:03-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/README + + BitKeeper/deleted/.del-autoopts.c~3e84323623aff6e7@1.2, 2009-07-20 02:43:57-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.c~9fb35908790bfaa9@1.3, 2009-07-20 04:23:04-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.c~b42b972a53764910@1.2, 2009-07-20 02:50:09-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.h~5bc4082052258182@1.2, 2009-07-20 02:43:59-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/autoopts.h + + BitKeeper/deleted/.del-autoopts.h~63e256b712b3cc83@1.3, 2009-07-20 04:23:06-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/autoopts.h + + BitKeeper/deleted/.del-autoopts.h~7ed5c5ad6dbc0297@1.2, 2009-07-20 02:50:10-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts.h + + BitKeeper/deleted/.del-boolean.c~131707465ccb681@1.2, 2009-07-20 02:50:12-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/boolean.c + + BitKeeper/deleted/.del-boolean.c~3fc4c58774ba3ff@1.2, 2009-07-20 02:44:00-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/boolean.c + + BitKeeper/deleted/.del-boolean.c~7e6a10bd3f3866cf@1.3, 2009-07-20 04:23:07-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/boolean.c + + BitKeeper/deleted/.del-compat.h~d62907f830867563@1.2, 2009-07-20 02:44:37-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/compat.h + + BitKeeper/deleted/.del-compat.h~d716e3994afa17ee@1.3, 2009-07-20 04:23:45-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/compat/compat.h + + BitKeeper/deleted/.del-compat.h~ff97c2854c9b9586@1.2, 2009-07-20 02:50:45-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/compat.h + + BitKeeper/deleted/.del-configfile.c~b6f779d27e6c4608@1.2, 2009-07-20 02:44:02-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/configfile.c + + BitKeeper/deleted/.del-configfile.c~b9949d5548dc9e7d@1.2, 2009-07-20 02:50:13-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/configfile.c + + BitKeeper/deleted/.del-configfile.c~bc87cafa8bb69d84@1.3, 2009-07-20 04:23:09-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/configfile.c + + BitKeeper/deleted/.del-cook.c~23f6c5524e2fd0b9@1.2, 2009-07-20 02:50:15-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/cook.c + + BitKeeper/deleted/.del-cook.c~d29aaca7ee3c2e03@1.3, 2009-07-20 04:23:10-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/cook.c + + BitKeeper/deleted/.del-cook.c~e72da2a3e260c2ae@1.2, 2009-07-20 02:44:04-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/cook.c + + BitKeeper/deleted/.del-enumeration.c~1a1ac98e84630322@1.2, 2009-07-20 02:44:05-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/enumeration.c + + BitKeeper/deleted/.del-enumeration.c~56f8f00f64229802@1.2, 2009-07-20 02:50:16-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/enumeration.c + + BitKeeper/deleted/.del-enumeration.c~73f8914b25fdf1cb@1.3, 2009-07-20 04:23:12-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/enumeration.c + + BitKeeper/deleted/.del-environment.c~3fc0f27d83271522@1.3, 2009-07-20 04:23:14-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/environment.c + + BitKeeper/deleted/.del-environment.c~43f215aff8170b0d@1.2, 2009-07-20 02:50:17-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/environment.c + + BitKeeper/deleted/.del-environment.c~654c5635a28f680a@1.2, 2009-07-20 02:44:07-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/environment.c + + BitKeeper/deleted/.del-genshell.c~19c1b0098a7d195e@1.2, 2009-07-20 02:50:19-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/genshell.c + + BitKeeper/deleted/.del-genshell.c~8cec4f90c9677dad@1.3, 2009-07-20 04:23:15-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/genshell.c + + BitKeeper/deleted/.del-genshell.c~d151b9234159786e@1.2, 2009-07-20 02:44:08-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/genshell.c + + BitKeeper/deleted/.del-genshell.h~39a68cd82b716d3d@1.2, 2009-07-20 02:50:20-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/genshell.h + + BitKeeper/deleted/.del-genshell.h~4684aecaf31474bd@1.3, 2009-07-20 04:23:17-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/genshell.h + + BitKeeper/deleted/.del-genshell.h~fba29f6d134cf39@1.2, 2009-07-20 02:44:10-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/genshell.h + + BitKeeper/deleted/.del-libopts.c~3fdfbf411c197e0b@1.2, 2009-07-20 02:44:11-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/libopts.c + + BitKeeper/deleted/.del-libopts.c~d2eaf9d4d9c22da8@1.2, 2009-07-20 02:50:21-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/libopts.c + + BitKeeper/deleted/.del-libopts.c~e6b4ffdc895fd9c7@1.3, 2009-07-20 04:23:18-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/libopts.c + + BitKeeper/deleted/.del-libopts.m4~1e6c2484e7bcaa8e@1.2, 2009-07-20 02:50:52-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-libopts.m4~22764fd769234d87@1.3, 2009-07-20 04:23:53-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-libopts.m4~babfee32f8439fb7@1.2, 2009-07-20 02:44:44-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-liboptschk.m4~5684906422d310d5@1.3, 2009-07-20 04:23:55-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-liboptschk.m4~7f8c6092b16525fa@1.2, 2009-07-20 02:44:46-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-liboptschk.m4~f7c5b75baf234b93@1.2, 2009-07-20 02:50:54-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-load.c~49f0fde1bda6dab1@1.2, 2009-07-20 02:50:22-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/load.c + + BitKeeper/deleted/.del-load.c~7fe0c22d7c968b7@1.2, 2009-07-20 02:44:13-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/load.c + + BitKeeper/deleted/.del-load.c~e9afe1c55b052708@1.3, 2009-07-20 04:23:19-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/load.c + + BitKeeper/deleted/.del-makeshell.c~271eaff05907e0a2@1.2, 2009-07-20 02:50:24-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/makeshell.c + + BitKeeper/deleted/.del-makeshell.c~67d09f76ea0a6ed5@1.3, 2009-07-20 04:23:20-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/makeshell.c + + BitKeeper/deleted/.del-makeshell.c~ba6349435fd3fc83@1.2, 2009-07-20 02:44:14-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/makeshell.c + + BitKeeper/deleted/.del-nested.c~5752e76eefab7f9f@1.2, 2009-07-20 02:44:16-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/nested.c + + BitKeeper/deleted/.del-nested.c~7f5db28ad8a858b9@1.3, 2009-07-20 04:23:22-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/nested.c + + BitKeeper/deleted/.del-nested.c~a7ab0b07538b5e49@1.2, 2009-07-20 02:50:25-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/nested.c + + BitKeeper/deleted/.del-numeric.c~a21fe674dc3847e2@1.3, 2009-07-20 04:23:23-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/numeric.c + + BitKeeper/deleted/.del-numeric.c~ab97d8c3d6609e2a@1.2, 2009-07-20 02:44:17-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/numeric.c + + BitKeeper/deleted/.del-numeric.c~e1d7cbb7cecbff8c@1.2, 2009-07-20 02:50:26-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/numeric.c + + BitKeeper/deleted/.del-options.h~56723cc66b175bd8@1.3, 2009-07-20 04:23:42-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/autoopts/options.h + + BitKeeper/deleted/.del-options.h~ce496734ff365a8f@1.2, 2009-07-20 02:44:34-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/autoopts/options.h + + BitKeeper/deleted/.del-options.h~eaf98d11dd68785b@1.2, 2009-07-20 02:50:41-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts/options.h + + BitKeeper/deleted/.del-pathfind.c~5eb7c4a7238a3334@1.2, 2009-07-20 02:50:46-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pathfind.c~660d016d9d4bfaf0@1.2, 2009-07-20 02:44:39-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pathfind.c~ad86b5a5886760c0@1.3, 2009-07-20 04:23:46-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pgusage.c~7a129c2a1b3dc002@1.2, 2009-07-20 02:44:18-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/pgusage.c + + BitKeeper/deleted/.del-pgusage.c~8894b938253faf7a@1.3, 2009-07-20 04:23:25-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/pgusage.c + + BitKeeper/deleted/.del-pgusage.c~f3a06f0e78822dea@1.2, 2009-07-20 02:50:27-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/pgusage.c + + BitKeeper/deleted/.del-proto.h~322bc5cfd3f14a53@1.2, 2009-07-20 02:44:19-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/proto.h + + BitKeeper/deleted/.del-proto.h~600f5c521621fb7@1.2, 2009-07-20 02:50:28-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/proto.h + + BitKeeper/deleted/.del-proto.h~77f289b58b0425ed@1.3, 2009-07-20 04:23:26-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/proto.h + + BitKeeper/deleted/.del-putshell.c~454ab3a4821e880@1.3, 2009-07-20 04:23:28-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/putshell.c + + BitKeeper/deleted/.del-putshell.c~afc504b27eed29b0@1.2, 2009-07-20 02:50:29-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/putshell.c + + BitKeeper/deleted/.del-putshell.c~b671799440bdb0e6@1.2, 2009-07-20 02:44:20-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/putshell.c + + BitKeeper/deleted/.del-restore.c~11e16df450dfc6be@1.3, 2009-07-20 04:23:29-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/restore.c + + BitKeeper/deleted/.del-restore.c~4e87dc67454a7987@1.2, 2009-07-20 02:50:31-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/restore.c + + BitKeeper/deleted/.del-restore.c~a699a151ee8b8476@1.2, 2009-07-20 02:44:21-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/restore.c + + BitKeeper/deleted/.del-save.c~4b1d83a0b1611d7c@1.3, 2009-07-20 02:50:32-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/save.c + + BitKeeper/deleted/.del-save.c~efa5c354e672893a@1.4, 2009-07-20 04:23:30-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/save.c + + BitKeeper/deleted/.del-save.c~f88133d32eccbf4b@1.3, 2009-07-20 02:44:23-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/save.c + + BitKeeper/deleted/.del-snprintf.c~147cb0d37c1e7307@1.2, 2009-07-20 02:50:47-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/snprintf.c + + BitKeeper/deleted/.del-snprintf.c~8f0c3b04d748ef30@1.2, 2009-07-20 02:44:40-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/snprintf.c + + BitKeeper/deleted/.del-snprintf.c~d3120f77949ff1f1@1.3, 2009-07-20 04:23:48-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/compat/snprintf.c + + BitKeeper/deleted/.del-sort.c~2a84210ffa0f5197@1.2, 2009-07-20 02:50:33-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/sort.c + + BitKeeper/deleted/.del-sort.c~3d68b8c2f01ade31@1.3, 2009-07-20 04:23:31-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/sort.c + + BitKeeper/deleted/.del-sort.c~91f412b45a139031@1.2, 2009-07-20 02:44:24-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/sort.c + + BitKeeper/deleted/.del-stack.c~3275408d176af9c1@1.3, 2009-07-20 04:23:33-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/stack.c + + BitKeeper/deleted/.del-stack.c~591385237e0f3ce2@1.2, 2009-07-20 02:44:26-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/stack.c + + BitKeeper/deleted/.del-stack.c~ade9ed5bb7b8fb6c@1.2, 2009-07-20 02:50:34-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/stack.c + + BitKeeper/deleted/.del-strchr.c~45ec0a98e0025509@1.2, 2009-07-20 02:44:41-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/strchr.c + + BitKeeper/deleted/.del-strchr.c~62e63feb4f1bb259@1.3, 2009-07-20 04:23:49-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/compat/strchr.c + + BitKeeper/deleted/.del-strchr.c~ee5d954d3d137acf@1.2, 2009-07-20 02:50:49-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/strchr.c + + BitKeeper/deleted/.del-strdup.c~516aa8c43634df59@1.2, 2009-07-20 02:50:50-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/strdup.c + + BitKeeper/deleted/.del-strdup.c~bf4073cb7820ac7e@1.2, 2009-07-20 02:44:43-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/strdup.c + + BitKeeper/deleted/.del-strdup.c~f6c99142400aadb0@1.3, 2009-07-20 04:23:50-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/compat/strdup.c + + BitKeeper/deleted/.del-streqvcmp.c~2b8aaed8d8cbdfa@1.3, 2009-07-20 04:23:35-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/streqvcmp.c + + BitKeeper/deleted/.del-streqvcmp.c~3a8c4c9ed2c0bb96@1.2, 2009-07-20 02:44:27-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/streqvcmp.c + + BitKeeper/deleted/.del-streqvcmp.c~7c57f427df22897@1.2, 2009-07-20 02:50:35-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/streqvcmp.c + + BitKeeper/deleted/.del-text_mmap.c~24b4f1774aa17978@1.2, 2009-07-20 02:50:36-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/text_mmap.c + + BitKeeper/deleted/.del-text_mmap.c~73112689c5763d@1.3, 2009-07-20 04:23:36-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/text_mmap.c + + BitKeeper/deleted/.del-text_mmap.c~d9d668bcff3485b5@1.2, 2009-07-20 02:44:28-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/text_mmap.c + + BitKeeper/deleted/.del-tokenize.c~4fd8a727c28d24c@1.3, 2009-07-20 04:23:37-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/tokenize.c + + BitKeeper/deleted/.del-tokenize.c~a50a40638aa720cf@1.2, 2009-07-20 02:50:38-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/tokenize.c + + BitKeeper/deleted/.del-tokenize.c~fffe49aa64a78644@1.2, 2009-07-20 02:44:30-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/tokenize.c + + BitKeeper/deleted/.del-usage-txt.h~36c2f46a3cd8cbd@1.2, 2009-07-20 02:50:43-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage-txt.h~6abe748ce418395@1.3, 2009-07-20 04:23:43-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage-txt.h~6fa28bed13f28bc9@1.2, 2009-07-20 02:44:35-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage.c~79a0f715733bdccf@1.2, 2009-07-20 02:44:31-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/usage.c + + BitKeeper/deleted/.del-usage.c~e8da7f6b2f71a374@1.3, 2009-07-20 04:23:39-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/usage.c + + BitKeeper/deleted/.del-usage.c~eb257c90352f0b1a@1.2, 2009-07-20 02:50:39-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/usage.c + + BitKeeper/deleted/.del-version.c~45de4739ab05f47b@1.3, 2009-07-20 04:23:40-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/version.c + + BitKeeper/deleted/.del-version.c~96adea57d42d29f6@1.2, 2009-07-20 02:50:40-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/version.c + + BitKeeper/deleted/.del-version.c~f18bf6a7860ad7f7@1.2, 2009-07-20 02:44:32-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/version.c + + BitKeeper/deleted/.del-windows-config.h~1665be9c16e9725d@1.2, 2009-07-20 02:50:51-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/windows-config.h + + BitKeeper/deleted/.del-windows-config.h~c8c7442a9420d50@1.2, 2009-07-20 02:44:43-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/windows-config.h + + BitKeeper/deleted/.del-windows-config.h~e3ddaca75ec0f439@1.3, 2009-07-20 04:23:51-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/libopts/compat/windows-config.h + + gsoc_sntp/libopts/COPYING.gplv3@1.1, 2009-07-20 04:28:19-04:00, stenn@whimsy.udel.edu +674 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/COPYING.gplv3 + + gsoc_sntp/libopts/COPYING.gplv3@1.0, 2009-07-20 04:28:19-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/COPYING.lgplv3@1.1, 2009-07-20 04:28:19-04:00, stenn@whimsy.udel.edu +165 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/COPYING.lgplv3 + + gsoc_sntp/libopts/COPYING.lgplv3@1.0, 2009-07-20 04:28:19-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/COPYING.mbsd@1.1, 2009-07-20 04:28:20-04:00, stenn@whimsy.udel.edu +26 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/COPYING.mbsd + + gsoc_sntp/libopts/COPYING.mbsd@1.0, 2009-07-20 04:28:20-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/MakeDefs.inc@1.1, 2009-07-20 04:28:20-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/MakeDefs.inc + + gsoc_sntp/libopts/MakeDefs.inc@1.0, 2009-07-20 04:28:20-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/Makefile.am@1.1, 2009-07-20 04:28:20-04:00, stenn@whimsy.udel.edu +28 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/Makefile.am + + gsoc_sntp/libopts/Makefile.am@1.0, 2009-07-20 04:28:20-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/README@1.1, 2009-07-20 04:28:20-04:00, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/README + + gsoc_sntp/libopts/README@1.0, 2009-07-20 04:28:20-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/ag-char-map.h@1.1, 2009-07-20 04:28:21-04:00, stenn@whimsy.udel.edu +129 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/ag-char-map.h + + gsoc_sntp/libopts/ag-char-map.h@1.0, 2009-07-20 04:28:21-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/autoopts.c@1.1, 2009-07-20 04:28:21-04:00, stenn@whimsy.udel.edu +1164 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/autoopts.c + + gsoc_sntp/libopts/autoopts.c@1.0, 2009-07-20 04:28:21-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/autoopts.h@1.1, 2009-07-20 04:28:22-04:00, stenn@whimsy.udel.edu +364 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/autoopts.h + + gsoc_sntp/libopts/autoopts.h@1.0, 2009-07-20 04:28:22-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/autoopts/options.h@1.1, 2009-07-20 04:28:39-04:00, stenn@whimsy.udel.edu +1055 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/autoopts/options.h + + gsoc_sntp/libopts/autoopts/options.h@1.0, 2009-07-20 04:28:39-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/autoopts/usage-txt.h@1.1, 2009-07-20 04:28:40-04:00, stenn@whimsy.udel.edu +393 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/autoopts/usage-txt.h + + gsoc_sntp/libopts/autoopts/usage-txt.h@1.0, 2009-07-20 04:28:40-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/boolean.c@1.1, 2009-07-20 04:28:22-04:00, stenn@whimsy.udel.edu +91 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/boolean.c + + gsoc_sntp/libopts/boolean.c@1.0, 2009-07-20 04:28:22-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/compat/compat.h@1.1, 2009-07-20 04:28:41-04:00, stenn@whimsy.udel.edu +366 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/compat/compat.h + + gsoc_sntp/libopts/compat/compat.h@1.0, 2009-07-20 04:28:41-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/compat/pathfind.c@1.1, 2009-07-20 04:28:42-04:00, stenn@whimsy.udel.edu +338 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/compat/pathfind.c + + gsoc_sntp/libopts/compat/pathfind.c@1.0, 2009-07-20 04:28:42-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/compat/snprintf.c@1.1, 2009-07-20 04:28:43-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/compat/snprintf.c + + gsoc_sntp/libopts/compat/snprintf.c@1.0, 2009-07-20 04:28:43-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/compat/strchr.c@1.1, 2009-07-20 04:28:43-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/compat/strchr.c + + gsoc_sntp/libopts/compat/strchr.c@1.0, 2009-07-20 04:28:43-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/compat/strdup.c@1.1, 2009-07-20 04:28:43-04:00, stenn@whimsy.udel.edu +19 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/compat/strdup.c + + gsoc_sntp/libopts/compat/strdup.c@1.0, 2009-07-20 04:28:43-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/compat/windows-config.h@1.1, 2009-07-20 04:28:43-04:00, stenn@whimsy.udel.edu +147 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/compat/windows-config.h + + gsoc_sntp/libopts/compat/windows-config.h@1.0, 2009-07-20 04:28:43-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/configfile.c@1.1, 2009-07-20 04:28:23-04:00, stenn@whimsy.udel.edu +1251 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/configfile.c + + gsoc_sntp/libopts/configfile.c@1.0, 2009-07-20 04:28:23-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/cook.c@1.1, 2009-07-20 04:28:24-04:00, stenn@whimsy.udel.edu +293 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/cook.c + + gsoc_sntp/libopts/cook.c@1.0, 2009-07-20 04:28:24-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/enumeration.c@1.1, 2009-07-20 04:28:24-04:00, stenn@whimsy.udel.edu +512 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/enumeration.c + + gsoc_sntp/libopts/enumeration.c@1.0, 2009-07-20 04:28:24-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/environment.c@1.1, 2009-07-20 04:28:25-04:00, stenn@whimsy.udel.edu +240 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/environment.c + + gsoc_sntp/libopts/environment.c@1.0, 2009-07-20 04:28:25-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/file.c@1.1, 2009-07-20 04:28:26-04:00, stenn@whimsy.udel.edu +169 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/file.c + + gsoc_sntp/libopts/file.c@1.0, 2009-07-20 04:28:26-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/genshell.c@1.1, 2009-07-20 04:28:26-04:00, stenn@whimsy.udel.edu +358 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/genshell.c + + gsoc_sntp/libopts/genshell.c@1.0, 2009-07-20 04:28:26-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/genshell.h@1.1, 2009-07-20 04:28:27-04:00, stenn@whimsy.udel.edu +165 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/genshell.h + + gsoc_sntp/libopts/genshell.h@1.0, 2009-07-20 04:28:27-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/libopts.c@1.1, 2009-07-20 04:28:27-04:00, stenn@whimsy.udel.edu +38 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/libopts.c + + gsoc_sntp/libopts/libopts.c@1.0, 2009-07-20 04:28:27-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/load.c@1.1, 2009-07-20 04:28:27-04:00, stenn@whimsy.udel.edu +540 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/load.c + + gsoc_sntp/libopts/load.c@1.0, 2009-07-20 04:28:27-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/m4/libopts.m4@1.1, 2009-07-20 04:28:44-04:00, stenn@whimsy.udel.edu +548 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/m4/libopts.m4 + + gsoc_sntp/libopts/m4/libopts.m4@1.0, 2009-07-20 04:28:44-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/m4/liboptschk.m4@1.1, 2009-07-20 04:28:45-04:00, stenn@whimsy.udel.edu +42 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/m4/liboptschk.m4 + + gsoc_sntp/libopts/m4/liboptschk.m4@1.0, 2009-07-20 04:28:45-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/makeshell.c@1.1, 2009-07-20 04:28:28-04:00, stenn@whimsy.udel.edu +1099 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/makeshell.c + + gsoc_sntp/libopts/makeshell.c@1.0, 2009-07-20 04:28:28-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/nested.c@1.1, 2009-07-20 04:28:29-04:00, stenn@whimsy.udel.edu +843 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/nested.c + + gsoc_sntp/libopts/nested.c@1.0, 2009-07-20 04:28:29-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/numeric.c@1.1, 2009-07-20 04:28:29-04:00, stenn@whimsy.udel.edu +175 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/numeric.c + + gsoc_sntp/libopts/numeric.c@1.0, 2009-07-20 04:28:29-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/parse-duration.c@1.1, 2009-07-20 04:28:30-04:00, stenn@whimsy.udel.edu +582 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/parse-duration.c + + gsoc_sntp/libopts/parse-duration.c@1.0, 2009-07-20 04:28:30-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/parse-duration.h@1.1, 2009-07-20 04:28:30-04:00, stenn@whimsy.udel.edu +82 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/parse-duration.h + + gsoc_sntp/libopts/parse-duration.h@1.0, 2009-07-20 04:28:30-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/pgusage.c@1.1, 2009-07-20 04:28:30-04:00, stenn@whimsy.udel.edu +140 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/pgusage.c + + gsoc_sntp/libopts/pgusage.c@1.0, 2009-07-20 04:28:30-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/proto.h@1.1, 2009-07-20 04:28:31-04:00, stenn@whimsy.udel.edu +112 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/proto.h + + gsoc_sntp/libopts/proto.h@1.0, 2009-07-20 04:28:31-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/putshell.c@1.1, 2009-07-20 04:28:31-04:00, stenn@whimsy.udel.edu +320 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/putshell.c + + gsoc_sntp/libopts/putshell.c@1.0, 2009-07-20 04:28:31-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/reset.c@1.1, 2009-07-20 04:28:31-04:00, stenn@whimsy.udel.edu +128 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/reset.c + + gsoc_sntp/libopts/reset.c@1.0, 2009-07-20 04:28:31-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/restore.c@1.1, 2009-07-20 04:28:32-04:00, stenn@whimsy.udel.edu +227 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/restore.c + + gsoc_sntp/libopts/restore.c@1.0, 2009-07-20 04:28:32-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/save.c@1.1, 2009-07-20 04:28:32-04:00, stenn@whimsy.udel.edu +790 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/save.c + + gsoc_sntp/libopts/save.c@1.0, 2009-07-20 04:28:32-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/sort.c@1.1, 2009-07-20 04:28:33-04:00, stenn@whimsy.udel.edu +336 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/sort.c + + gsoc_sntp/libopts/sort.c@1.0, 2009-07-20 04:28:33-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/stack.c@1.1, 2009-07-20 04:28:34-04:00, stenn@whimsy.udel.edu +264 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/stack.c + + gsoc_sntp/libopts/stack.c@1.0, 2009-07-20 04:28:34-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/streqvcmp.c@1.1, 2009-07-20 04:28:35-04:00, stenn@whimsy.udel.edu +266 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/streqvcmp.c + + gsoc_sntp/libopts/streqvcmp.c@1.0, 2009-07-20 04:28:35-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/text_mmap.c@1.1, 2009-07-20 04:28:35-04:00, stenn@whimsy.udel.edu +383 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/text_mmap.c + + gsoc_sntp/libopts/text_mmap.c@1.0, 2009-07-20 04:28:35-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/time.c@1.1, 2009-07-20 04:28:36-04:00, stenn@whimsy.udel.edu +88 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/time.c + + gsoc_sntp/libopts/time.c@1.0, 2009-07-20 04:28:36-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/tokenize.c@1.1, 2009-07-20 04:28:36-04:00, stenn@whimsy.udel.edu +323 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/tokenize.c + + gsoc_sntp/libopts/tokenize.c@1.0, 2009-07-20 04:28:36-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/usage.c@1.1, 2009-07-20 04:28:37-04:00, stenn@whimsy.udel.edu +756 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/usage.c + + gsoc_sntp/libopts/usage.c@1.0, 2009-07-20 04:28:37-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/value-type.c@1.1, 2009-07-20 04:28:38-04:00, stenn@whimsy.udel.edu +123 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/value-type.c + + gsoc_sntp/libopts/value-type.c@1.0, 2009-07-20 04:28:38-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/value-type.h@1.1, 2009-07-20 04:28:38-04:00, stenn@whimsy.udel.edu +25 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/value-type.h + + gsoc_sntp/libopts/value-type.h@1.0, 2009-07-20 04:28:38-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/version.c@1.1, 2009-07-20 04:28:38-04:00, stenn@whimsy.udel.edu +157 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/version.c + + gsoc_sntp/libopts/version.c@1.0, 2009-07-20 04:28:38-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/xat-attribute.c@1.1, 2009-07-20 04:28:38-04:00, stenn@whimsy.udel.edu +114 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/xat-attribute.c + + gsoc_sntp/libopts/xat-attribute.c@1.0, 2009-07-20 04:28:38-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/xat-attribute.h@1.1, 2009-07-20 04:28:39-04:00, stenn@whimsy.udel.edu +22 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/xat-attribute.h + + gsoc_sntp/libopts/xat-attribute.h@1.0, 2009-07-20 04:28:39-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/COPYING.gplv3@1.1, 2009-07-20 02:52:27-04:00, stenn@whimsy.udel.edu +674 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/COPYING.gplv3 + + libopts/COPYING.gplv3@1.0, 2009-07-20 02:52:27-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/COPYING.lgplv3@1.1, 2009-07-20 02:52:28-04:00, stenn@whimsy.udel.edu +165 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/COPYING.lgplv3 + + libopts/COPYING.lgplv3@1.0, 2009-07-20 02:52:28-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/COPYING.mbsd@1.1, 2009-07-20 02:52:28-04:00, stenn@whimsy.udel.edu +26 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/COPYING.mbsd + + libopts/COPYING.mbsd@1.0, 2009-07-20 02:52:28-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/MakeDefs.inc@1.1, 2009-07-20 02:52:28-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/MakeDefs.inc + + libopts/MakeDefs.inc@1.0, 2009-07-20 02:52:28-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/Makefile.am@1.1, 2009-07-20 02:52:28-04:00, stenn@whimsy.udel.edu +28 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/Makefile.am + + libopts/Makefile.am@1.0, 2009-07-20 02:52:28-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/README@1.1, 2009-07-20 02:52:28-04:00, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/README + + libopts/README@1.0, 2009-07-20 02:52:28-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/ag-char-map.h@1.1, 2009-07-20 02:52:28-04:00, stenn@whimsy.udel.edu +129 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/ag-char-map.h + + libopts/ag-char-map.h@1.0, 2009-07-20 02:52:28-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/autoopts.c@1.1, 2009-07-20 02:52:29-04:00, stenn@whimsy.udel.edu +1164 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts.c + + libopts/autoopts.c@1.0, 2009-07-20 02:52:29-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/autoopts.h@1.1, 2009-07-20 02:52:30-04:00, stenn@whimsy.udel.edu +364 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts.h + + libopts/autoopts.h@1.0, 2009-07-20 02:52:30-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/autoopts/options.h@1.1, 2009-07-20 02:52:41-04:00, stenn@whimsy.udel.edu +1055 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts/options.h + + libopts/autoopts/options.h@1.0, 2009-07-20 02:52:41-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/autoopts/usage-txt.h@1.1, 2009-07-20 02:52:42-04:00, stenn@whimsy.udel.edu +393 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts/usage-txt.h + + libopts/autoopts/usage-txt.h@1.0, 2009-07-20 02:52:42-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/boolean.c@1.1, 2009-07-20 02:52:30-04:00, stenn@whimsy.udel.edu +91 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/boolean.c + + libopts/boolean.c@1.0, 2009-07-20 02:52:30-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/compat.h@1.1, 2009-07-20 02:52:43-04:00, stenn@whimsy.udel.edu +366 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/compat.h + + libopts/compat/compat.h@1.0, 2009-07-20 02:52:43-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/pathfind.c@1.1, 2009-07-20 02:52:43-04:00, stenn@whimsy.udel.edu +338 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/pathfind.c + + libopts/compat/pathfind.c@1.0, 2009-07-20 02:52:43-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/snprintf.c@1.1, 2009-07-20 02:52:44-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/snprintf.c + + libopts/compat/snprintf.c@1.0, 2009-07-20 02:52:44-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/strchr.c@1.1, 2009-07-20 02:52:44-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/strchr.c + + libopts/compat/strchr.c@1.0, 2009-07-20 02:52:44-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/strdup.c@1.1, 2009-07-20 02:52:44-04:00, stenn@whimsy.udel.edu +19 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/strdup.c + + libopts/compat/strdup.c@1.0, 2009-07-20 02:52:44-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/windows-config.h@1.1, 2009-07-20 02:52:44-04:00, stenn@whimsy.udel.edu +147 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/windows-config.h + + libopts/compat/windows-config.h@1.0, 2009-07-20 02:52:44-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/configfile.c@1.1, 2009-07-20 02:52:30-04:00, stenn@whimsy.udel.edu +1251 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/configfile.c + + libopts/configfile.c@1.0, 2009-07-20 02:52:30-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/cook.c@1.1, 2009-07-20 02:52:31-04:00, stenn@whimsy.udel.edu +293 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/cook.c + + libopts/cook.c@1.0, 2009-07-20 02:52:31-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/enumeration.c@1.1, 2009-07-20 02:52:32-04:00, stenn@whimsy.udel.edu +512 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/enumeration.c + + libopts/enumeration.c@1.0, 2009-07-20 02:52:32-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/environment.c@1.1, 2009-07-20 02:52:32-04:00, stenn@whimsy.udel.edu +240 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/environment.c + + libopts/environment.c@1.0, 2009-07-20 02:52:32-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/file.c@1.1, 2009-07-20 02:52:33-04:00, stenn@whimsy.udel.edu +169 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/file.c + + libopts/file.c@1.0, 2009-07-20 02:52:33-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/genshell.c@1.1, 2009-07-20 02:52:33-04:00, stenn@whimsy.udel.edu +358 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/genshell.c + + libopts/genshell.c@1.0, 2009-07-20 02:52:33-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/genshell.h@1.1, 2009-07-20 02:52:33-04:00, stenn@whimsy.udel.edu +165 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/genshell.h + + libopts/genshell.h@1.0, 2009-07-20 02:52:33-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/libopts.c@1.1, 2009-07-20 02:52:33-04:00, stenn@whimsy.udel.edu +38 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/libopts.c + + libopts/libopts.c@1.0, 2009-07-20 02:52:33-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/load.c@1.1, 2009-07-20 02:52:33-04:00, stenn@whimsy.udel.edu +540 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/load.c + + libopts/load.c@1.0, 2009-07-20 02:52:33-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/m4/libopts.m4@1.1, 2009-07-20 02:52:44-04:00, stenn@whimsy.udel.edu +548 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/m4/libopts.m4 + + libopts/m4/libopts.m4@1.0, 2009-07-20 02:52:44-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/m4/liboptschk.m4@1.1, 2009-07-20 02:52:45-04:00, stenn@whimsy.udel.edu +42 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/m4/liboptschk.m4 + + libopts/m4/liboptschk.m4@1.0, 2009-07-20 02:52:45-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/makeshell.c@1.1, 2009-07-20 02:52:34-04:00, stenn@whimsy.udel.edu +1099 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/makeshell.c + + libopts/makeshell.c@1.0, 2009-07-20 02:52:34-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/nested.c@1.1, 2009-07-20 02:52:34-04:00, stenn@whimsy.udel.edu +843 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/nested.c + + libopts/nested.c@1.0, 2009-07-20 02:52:34-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/numeric.c@1.1, 2009-07-20 02:52:35-04:00, stenn@whimsy.udel.edu +175 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/numeric.c + + libopts/numeric.c@1.0, 2009-07-20 02:52:35-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/parse-duration.c@1.1, 2009-07-20 02:52:35-04:00, stenn@whimsy.udel.edu +582 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/parse-duration.c + + libopts/parse-duration.c@1.0, 2009-07-20 02:52:35-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/parse-duration.h@1.1, 2009-07-20 02:52:36-04:00, stenn@whimsy.udel.edu +82 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/parse-duration.h + + libopts/parse-duration.h@1.0, 2009-07-20 02:52:36-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/pgusage.c@1.1, 2009-07-20 02:52:36-04:00, stenn@whimsy.udel.edu +140 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/pgusage.c + + libopts/pgusage.c@1.0, 2009-07-20 02:52:36-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/proto.h@1.1, 2009-07-20 02:52:36-04:00, stenn@whimsy.udel.edu +112 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/proto.h + + libopts/proto.h@1.0, 2009-07-20 02:52:36-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/putshell.c@1.1, 2009-07-20 02:52:36-04:00, stenn@whimsy.udel.edu +320 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/putshell.c + + libopts/putshell.c@1.0, 2009-07-20 02:52:36-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/reset.c@1.1, 2009-07-20 02:52:36-04:00, stenn@whimsy.udel.edu +128 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/reset.c + + libopts/reset.c@1.0, 2009-07-20 02:52:36-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/restore.c@1.1, 2009-07-20 02:52:36-04:00, stenn@whimsy.udel.edu +227 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/restore.c + + libopts/restore.c@1.0, 2009-07-20 02:52:36-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/save.c@1.1, 2009-07-20 02:52:37-04:00, stenn@whimsy.udel.edu +790 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/save.c + + libopts/save.c@1.0, 2009-07-20 02:52:37-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/sort.c@1.1, 2009-07-20 02:52:38-04:00, stenn@whimsy.udel.edu +336 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/sort.c + + libopts/sort.c@1.0, 2009-07-20 02:52:38-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/stack.c@1.1, 2009-07-20 02:52:38-04:00, stenn@whimsy.udel.edu +264 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/stack.c + + libopts/stack.c@1.0, 2009-07-20 02:52:38-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/streqvcmp.c@1.1, 2009-07-20 02:52:39-04:00, stenn@whimsy.udel.edu +266 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/streqvcmp.c + + libopts/streqvcmp.c@1.0, 2009-07-20 02:52:39-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/text_mmap.c@1.1, 2009-07-20 02:52:39-04:00, stenn@whimsy.udel.edu +383 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/text_mmap.c + + libopts/text_mmap.c@1.0, 2009-07-20 02:52:39-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/time.c@1.1, 2009-07-20 02:52:40-04:00, stenn@whimsy.udel.edu +88 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/time.c + + libopts/time.c@1.0, 2009-07-20 02:52:40-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/tokenize.c@1.1, 2009-07-20 02:52:40-04:00, stenn@whimsy.udel.edu +323 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/tokenize.c + + libopts/tokenize.c@1.0, 2009-07-20 02:52:40-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/usage.c@1.1, 2009-07-20 02:52:40-04:00, stenn@whimsy.udel.edu +756 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/usage.c + + libopts/usage.c@1.0, 2009-07-20 02:52:40-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/value-type.c@1.1, 2009-07-20 02:52:41-04:00, stenn@whimsy.udel.edu +123 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/value-type.c + + libopts/value-type.c@1.0, 2009-07-20 02:52:41-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/value-type.h@1.1, 2009-07-20 02:52:41-04:00, stenn@whimsy.udel.edu +25 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/value-type.h + + libopts/value-type.h@1.0, 2009-07-20 02:52:41-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/version.c@1.1, 2009-07-20 02:52:41-04:00, stenn@whimsy.udel.edu +157 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/version.c + + libopts/version.c@1.0, 2009-07-20 02:52:41-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/xat-attribute.c@1.1, 2009-07-20 02:52:41-04:00, stenn@whimsy.udel.edu +114 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/xat-attribute.c + + libopts/xat-attribute.c@1.0, 2009-07-20 02:52:41-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/xat-attribute.h@1.1, 2009-07-20 02:52:41-04:00, stenn@whimsy.udel.edu +22 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/xat-attribute.h + + libopts/xat-attribute.h@1.0, 2009-07-20 02:52:41-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/COPYING.gplv3@1.1, 2009-07-20 02:53:39-04:00, stenn@whimsy.udel.edu +674 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/COPYING.gplv3 + + sntp/libopts/COPYING.gplv3@1.0, 2009-07-20 02:53:39-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/COPYING.lgplv3@1.1, 2009-07-20 02:53:40-04:00, stenn@whimsy.udel.edu +165 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/COPYING.lgplv3 + + sntp/libopts/COPYING.lgplv3@1.0, 2009-07-20 02:53:40-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/COPYING.mbsd@1.1, 2009-07-20 02:53:41-04:00, stenn@whimsy.udel.edu +26 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/COPYING.mbsd + + sntp/libopts/COPYING.mbsd@1.0, 2009-07-20 02:53:41-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/MakeDefs.inc@1.1, 2009-07-20 02:53:41-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/MakeDefs.inc + + sntp/libopts/MakeDefs.inc@1.0, 2009-07-20 02:53:41-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/Makefile.am@1.1, 2009-07-20 02:53:41-04:00, stenn@whimsy.udel.edu +28 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/Makefile.am + + sntp/libopts/Makefile.am@1.0, 2009-07-20 02:53:41-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/README@1.1, 2009-07-20 02:53:41-04:00, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/README + + sntp/libopts/README@1.0, 2009-07-20 02:53:41-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/ag-char-map.h@1.1, 2009-07-20 02:53:41-04:00, stenn@whimsy.udel.edu +129 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/ag-char-map.h + + sntp/libopts/ag-char-map.h@1.0, 2009-07-20 02:53:41-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/autoopts.c@1.1, 2009-07-20 02:53:42-04:00, stenn@whimsy.udel.edu +1164 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts.c + + sntp/libopts/autoopts.c@1.0, 2009-07-20 02:53:42-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/autoopts.h@1.1, 2009-07-20 02:53:43-04:00, stenn@whimsy.udel.edu +364 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts.h + + sntp/libopts/autoopts.h@1.0, 2009-07-20 02:53:43-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/autoopts/options.h@1.1, 2009-07-20 02:53:57-04:00, stenn@whimsy.udel.edu +1055 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts/options.h + + sntp/libopts/autoopts/options.h@1.0, 2009-07-20 02:53:57-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/autoopts/usage-txt.h@1.1, 2009-07-20 02:53:58-04:00, stenn@whimsy.udel.edu +393 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts/usage-txt.h + + sntp/libopts/autoopts/usage-txt.h@1.0, 2009-07-20 02:53:58-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/boolean.c@1.1, 2009-07-20 02:53:43-04:00, stenn@whimsy.udel.edu +91 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/boolean.c + + sntp/libopts/boolean.c@1.0, 2009-07-20 02:53:43-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/compat.h@1.1, 2009-07-20 02:53:59-04:00, stenn@whimsy.udel.edu +366 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/compat.h + + sntp/libopts/compat/compat.h@1.0, 2009-07-20 02:53:59-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/pathfind.c@1.1, 2009-07-20 02:54:00-04:00, stenn@whimsy.udel.edu +338 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/pathfind.c + + sntp/libopts/compat/pathfind.c@1.0, 2009-07-20 02:54:00-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/snprintf.c@1.1, 2009-07-20 02:54:00-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/snprintf.c + + sntp/libopts/compat/snprintf.c@1.0, 2009-07-20 02:54:00-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/strchr.c@1.1, 2009-07-20 02:54:01-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/strchr.c + + sntp/libopts/compat/strchr.c@1.0, 2009-07-20 02:54:01-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/strdup.c@1.1, 2009-07-20 02:54:01-04:00, stenn@whimsy.udel.edu +19 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/strdup.c + + sntp/libopts/compat/strdup.c@1.0, 2009-07-20 02:54:01-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/windows-config.h@1.1, 2009-07-20 02:54:01-04:00, stenn@whimsy.udel.edu +147 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/windows-config.h + + sntp/libopts/compat/windows-config.h@1.0, 2009-07-20 02:54:01-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/configfile.c@1.1, 2009-07-20 02:53:43-04:00, stenn@whimsy.udel.edu +1251 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/configfile.c + + sntp/libopts/configfile.c@1.0, 2009-07-20 02:53:43-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/cook.c@1.1, 2009-07-20 02:53:44-04:00, stenn@whimsy.udel.edu +293 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/cook.c + + sntp/libopts/cook.c@1.0, 2009-07-20 02:53:44-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/enumeration.c@1.1, 2009-07-20 02:53:45-04:00, stenn@whimsy.udel.edu +512 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/enumeration.c + + sntp/libopts/enumeration.c@1.0, 2009-07-20 02:53:45-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/environment.c@1.1, 2009-07-20 02:53:46-04:00, stenn@whimsy.udel.edu +240 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/environment.c + + sntp/libopts/environment.c@1.0, 2009-07-20 02:53:46-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/file.c@1.1, 2009-07-20 02:53:46-04:00, stenn@whimsy.udel.edu +169 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/file.c + + sntp/libopts/file.c@1.0, 2009-07-20 02:53:46-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/genshell.c@1.1, 2009-07-20 02:53:47-04:00, stenn@whimsy.udel.edu +358 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/genshell.c + + sntp/libopts/genshell.c@1.0, 2009-07-20 02:53:47-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/genshell.h@1.1, 2009-07-20 02:53:47-04:00, stenn@whimsy.udel.edu +165 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/genshell.h + + sntp/libopts/genshell.h@1.0, 2009-07-20 02:53:47-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/libopts.c@1.1, 2009-07-20 02:53:47-04:00, stenn@whimsy.udel.edu +38 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/libopts.c + + sntp/libopts/libopts.c@1.0, 2009-07-20 02:53:47-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/load.c@1.1, 2009-07-20 02:53:47-04:00, stenn@whimsy.udel.edu +540 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/load.c + + sntp/libopts/load.c@1.0, 2009-07-20 02:53:47-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/m4/libopts.m4@1.1, 2009-07-20 02:54:01-04:00, stenn@whimsy.udel.edu +548 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/m4/libopts.m4 + + sntp/libopts/m4/libopts.m4@1.0, 2009-07-20 02:54:01-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/m4/liboptschk.m4@1.1, 2009-07-20 02:54:02-04:00, stenn@whimsy.udel.edu +42 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/m4/liboptschk.m4 + + sntp/libopts/m4/liboptschk.m4@1.0, 2009-07-20 02:54:02-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/makeshell.c@1.1, 2009-07-20 02:53:48-04:00, stenn@whimsy.udel.edu +1099 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/makeshell.c + + sntp/libopts/makeshell.c@1.0, 2009-07-20 02:53:48-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/nested.c@1.1, 2009-07-20 02:53:49-04:00, stenn@whimsy.udel.edu +843 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/nested.c + + sntp/libopts/nested.c@1.0, 2009-07-20 02:53:49-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/numeric.c@1.1, 2009-07-20 02:53:49-04:00, stenn@whimsy.udel.edu +175 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/numeric.c + + sntp/libopts/numeric.c@1.0, 2009-07-20 02:53:49-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/parse-duration.c@1.1, 2009-07-20 02:53:49-04:00, stenn@whimsy.udel.edu +582 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/parse-duration.c + + sntp/libopts/parse-duration.c@1.0, 2009-07-20 02:53:49-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/parse-duration.h@1.1, 2009-07-20 02:53:50-04:00, stenn@whimsy.udel.edu +82 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/parse-duration.h + + sntp/libopts/parse-duration.h@1.0, 2009-07-20 02:53:50-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/pgusage.c@1.1, 2009-07-20 02:53:50-04:00, stenn@whimsy.udel.edu +140 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/pgusage.c + + sntp/libopts/pgusage.c@1.0, 2009-07-20 02:53:50-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/proto.h@1.1, 2009-07-20 02:53:51-04:00, stenn@whimsy.udel.edu +112 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/proto.h + + sntp/libopts/proto.h@1.0, 2009-07-20 02:53:50-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/putshell.c@1.1, 2009-07-20 02:53:51-04:00, stenn@whimsy.udel.edu +320 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/putshell.c + + sntp/libopts/putshell.c@1.0, 2009-07-20 02:53:51-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/reset.c@1.1, 2009-07-20 02:53:51-04:00, stenn@whimsy.udel.edu +128 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/reset.c + + sntp/libopts/reset.c@1.0, 2009-07-20 02:53:51-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/restore.c@1.1, 2009-07-20 02:53:52-04:00, stenn@whimsy.udel.edu +227 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/restore.c + + sntp/libopts/restore.c@1.0, 2009-07-20 02:53:52-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/save.c@1.1, 2009-07-20 02:53:52-04:00, stenn@whimsy.udel.edu +790 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/save.c + + sntp/libopts/save.c@1.0, 2009-07-20 02:53:52-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/sort.c@1.1, 2009-07-20 02:53:53-04:00, stenn@whimsy.udel.edu +336 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/sort.c + + sntp/libopts/sort.c@1.0, 2009-07-20 02:53:53-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/stack.c@1.1, 2009-07-20 02:53:53-04:00, stenn@whimsy.udel.edu +264 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/stack.c + + sntp/libopts/stack.c@1.0, 2009-07-20 02:53:53-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/streqvcmp.c@1.1, 2009-07-20 02:53:54-04:00, stenn@whimsy.udel.edu +266 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/streqvcmp.c + + sntp/libopts/streqvcmp.c@1.0, 2009-07-20 02:53:54-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/text_mmap.c@1.1, 2009-07-20 02:53:55-04:00, stenn@whimsy.udel.edu +383 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/text_mmap.c + + sntp/libopts/text_mmap.c@1.0, 2009-07-20 02:53:55-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/time.c@1.1, 2009-07-20 02:53:55-04:00, stenn@whimsy.udel.edu +88 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/time.c + + sntp/libopts/time.c@1.0, 2009-07-20 02:53:55-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/tokenize.c@1.1, 2009-07-20 02:53:55-04:00, stenn@whimsy.udel.edu +323 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/tokenize.c + + sntp/libopts/tokenize.c@1.0, 2009-07-20 02:53:55-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/usage.c@1.1, 2009-07-20 02:53:56-04:00, stenn@whimsy.udel.edu +756 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/usage.c + + sntp/libopts/usage.c@1.0, 2009-07-20 02:53:56-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/value-type.c@1.1, 2009-07-20 02:53:57-04:00, stenn@whimsy.udel.edu +123 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/value-type.c + + sntp/libopts/value-type.c@1.0, 2009-07-20 02:53:57-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/value-type.h@1.1, 2009-07-20 02:53:57-04:00, stenn@whimsy.udel.edu +25 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/value-type.h + + sntp/libopts/value-type.h@1.0, 2009-07-20 02:53:57-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/version.c@1.1, 2009-07-20 02:53:57-04:00, stenn@whimsy.udel.edu +157 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/version.c + + sntp/libopts/version.c@1.0, 2009-07-20 02:53:57-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/xat-attribute.c@1.1, 2009-07-20 02:53:57-04:00, stenn@whimsy.udel.edu +114 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/xat-attribute.c + + sntp/libopts/xat-attribute.c@1.0, 2009-07-20 02:53:57-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/xat-attribute.h@1.1, 2009-07-20 02:53:57-04:00, stenn@whimsy.udel.edu +22 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/xat-attribute.h + + sntp/libopts/xat-attribute.h@1.0, 2009-07-20 02:53:57-04:00, stenn@whimsy.udel.edu +0 -0 + +ChangeSet@1.1914, 2009-07-20 00:18:45-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1248] RES_MSSNTP typo in ntp_proto.c + + ChangeLog@1.374, 2009-07-20 00:18:28-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1248] RES_MSSNTP typo in ntp_proto.c + + ntpd/ntp_proto.c@1.292, 2009-07-20 00:18:31-04:00, stenn@whimsy.udel.edu +1 -1 + [Bug 1248] RES_MSSNTP typo in ntp_proto.c + +ChangeSet@1.1913, 2009-07-19 22:02:21-04:00, stenn@pogo.udel.edu +1 -0 + distribute ntp_lists.h + + include/Makefile.am@1.34, 2009-07-19 22:02:04-04:00, stenn@pogo.udel.edu +1 -0 + distribute ntp_lists.h + +ChangeSet@1.1910.1.1, 2009-07-20 00:11:58+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + Log warning about signd operations blocking ntpd when mssntp restrict keyword seen + + ChangeLog@1.371.1.1, 2009-07-20 00:11:57+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + Log warning about signd operations blocking ntpd when mssntp restrict keyword seen + + ntpd/ntp_config.c@1.198, 2009-07-20 00:11:58+00:00, davehart@shiny.ad.hartbrothers.com +13 -0 + Log warning about signd operations blocking ntpd when mssntp restrict keyword seen + +ChangeSet@1.1901.4.1, 2009-07-16 16:23:37+00:00, davehart@shiny.ad.hartbrothers.com +13 -0 + [Bug 1246] use a common template for singly-linked lists, convert most + doubly-linked lists to singly-linked. + + ChangeLog@1.362.4.1, 2009-07-16 16:23:34+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1246] use a common template for singly-linked lists, convert most + doubly-linked lists to singly-linked. + + include/ntp.h@1.159.1.1, 2009-07-16 16:23:34+00:00, davehart@shiny.ad.hartbrothers.com +24 -25 + use singly-linked lists instead of ISC's doubly-linked + + include/ntp_io.h@1.10, 2009-07-16 16:23:34+00:00, davehart@shiny.ad.hartbrothers.com +3 -5 + remove no-longer-needed doubly-linked list initialization routines + + include/ntp_lists.h@1.1, 2009-07-16 16:23:35+00:00, davehart@shiny.ad.hartbrothers.com +104 -0 + singly-linked list template macros + + include/ntp_lists.h@1.0, 2009-07-16 16:23:35+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + include/recvbuff.h@1.19, 2009-07-16 16:23:34+00:00, davehart@shiny.ad.hartbrothers.com +5 -6 + use singly-linked list for free_recv_buff + + libntp/recvbuff.c@1.33, 2009-07-16 16:23:34+00:00, davehart@shiny.ad.hartbrothers.com +29 -42 + use singly-linked list for free_recv_buff + + ntpd/ntp_io.c@1.289.2.1, 2009-07-16 16:23:34+00:00, davehart@shiny.ad.hartbrothers.com +128 -203 + use singly-linked lists instead of ISC's doubly-linked + + ntpd/ntp_peer.c@1.121, 2009-07-16 16:23:34+00:00, davehart@shiny.ad.hartbrothers.com +51 -72 + use new common singly-linked list template macros for + peer_hash and assoc_hash + + ntpd/ntpd.c@1.105, 2009-07-16 16:23:34+00:00, davehart@shiny.ad.hartbrothers.com +1 -5 + remove no-longer-needed doubly-linked list initialization routines + + ports/winnt/libntp/libntp.dsp@1.35, 2009-07-16 16:23:35+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add include/ntp_lists.h reference + + ports/winnt/libntp/libntp.vcproj@1.9, 2009-07-16 16:23:35+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add include/ntp_lists.h reference + + ports/winnt/ntpd/ntp_iocompletionport.c@1.44.1.1, 2009-07-16 16:23:35+00:00, davehart@shiny.ad.hartbrothers.com +20 -13 + use singly-linked list for compl_info_list + + ports/winnt/ntpd/ntpd.vcproj@1.10, 2009-07-16 16:23:35+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + add include/ntp_lists.h reference + +ChangeSet@1.1910, 2009-07-16 07:54:10-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P189 + TAG: NTP_4_2_5P189 + + ChangeLog@1.371, 2009-07-16 07:53:37-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P189 + + gsoc_sntp/sntp-opts.c@1.50, 2009-07-16 07:53:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P189 + + gsoc_sntp/sntp-opts.h@1.50, 2009-07-16 07:53:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P189 + + gsoc_sntp/sntp-opts.texi@1.50, 2009-07-16 07:53:40-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P189 + + gsoc_sntp/sntp.1@1.50, 2009-07-16 07:53:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P189 + + ntpd/ntpd-opts.c@1.182, 2009-07-16 07:53:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P189 + + ntpd/ntpd-opts.h@1.182, 2009-07-16 07:53:44-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P189 + + ntpd/ntpd-opts.texi@1.180, 2009-07-16 07:53:45-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P189 + + ntpd/ntpd.1@1.180, 2009-07-16 07:53:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P189 + + ntpdc/ntpdc-opts.c@1.177, 2009-07-16 07:53:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P189 + + ntpdc/ntpdc-opts.h@1.177, 2009-07-16 07:53:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P189 + + ntpdc/ntpdc-opts.texi@1.176, 2009-07-16 07:53:48-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P189 + + ntpdc/ntpdc.1@1.176, 2009-07-16 07:53:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P189 + + ntpq/ntpq-opts.c@1.177, 2009-07-16 07:53:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P189 + + ntpq/ntpq-opts.h@1.177, 2009-07-16 07:53:50-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P189 + + ntpq/ntpq-opts.texi@1.176, 2009-07-16 07:53:50-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P189 + + ntpq/ntpq.1@1.176, 2009-07-16 07:53:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P189 + + ntpsnmpd/ntpsnmpd-opts.c@1.58, 2009-07-16 07:53:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P189 + + ntpsnmpd/ntpsnmpd-opts.h@1.58, 2009-07-16 07:53:53-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P189 + + ntpsnmpd/ntpsnmpd-opts.texi@1.58, 2009-07-16 07:53:54-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P189 + + ntpsnmpd/ntpsnmpd.1@1.58, 2009-07-16 07:53:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P189 + + packageinfo.sh@1.192, 2009-07-16 07:53:56-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P189 + + sntp/sntp-opts.c@1.177, 2009-07-16 07:53:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P189 + + sntp/sntp-opts.h@1.177, 2009-07-16 07:53:56-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P189 + + sntp/sntp-opts.texi@1.176, 2009-07-16 07:53:57-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P189 + + sntp/sntp.1@1.176, 2009-07-16 07:53:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P189 + + util/ntp-keygen-opts.c@1.180, 2009-07-16 07:53:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P189 + + util/ntp-keygen-opts.h@1.180, 2009-07-16 07:54:00-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P189 + + util/ntp-keygen-opts.texi@1.179, 2009-07-16 07:54:01-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P189 + + util/ntp-keygen.1@1.179, 2009-07-16 07:54:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P189 + +ChangeSet@1.1909, 2009-07-15 16:51:50-04:00, stenn@whimsy.udel.edu +15 -0 + Documentation cleanup from Dave Mills + + ChangeLog@1.370, 2009-07-15 16:25:00-04:00, stenn@whimsy.udel.edu +1 -0 + Documentation cleanup from Dave Mills + + html/accopt.html@1.30, 2009-07-15 16:25:13-04:00, stenn@whimsy.udel.edu +99 -28 + Documentation cleanup from Dave Mills + + html/assoc.html@1.28, 2009-07-15 16:25:13-04:00, stenn@whimsy.udel.edu +10 -1 + Documentation cleanup from Dave Mills + + html/audio.html@1.21, 2009-07-15 16:25:14-04:00, stenn@whimsy.udel.edu +29 -4 + Documentation cleanup from Dave Mills + + html/authopt.html@1.50, 2009-07-15 16:25:15-04:00, stenn@whimsy.udel.edu +18 -2 + Documentation cleanup from Dave Mills + + html/bugs.html@1.5, 2009-07-15 16:25:16-04:00, stenn@whimsy.udel.edu +4 -1 + Documentation cleanup from Dave Mills + + html/config.html@1.23, 2009-07-15 16:25:18-04:00, stenn@whimsy.udel.edu +1 -1 + Documentation cleanup from Dave Mills + + html/confopt.html@1.45, 2009-07-15 16:25:19-04:00, stenn@whimsy.udel.edu +15 -13 + Documentation cleanup from Dave Mills + + html/debug.html@1.26, 2009-07-15 16:25:19-04:00, stenn@whimsy.udel.edu +29 -5 + Documentation cleanup from Dave Mills + + html/decode.html@1.10, 2009-07-15 16:25:20-04:00, stenn@whimsy.udel.edu +9 -5 + Documentation cleanup from Dave Mills + + html/extern.html@1.15, 2009-07-15 16:25:21-04:00, stenn@whimsy.udel.edu +21 -4 + Documentation cleanup from Dave Mills + + html/gadget.html@1.4, 2009-07-15 16:25:21-04:00, stenn@whimsy.udel.edu +9 -1 + Documentation cleanup from Dave Mills + + html/howto.html@1.22, 2009-07-15 16:25:22-04:00, stenn@whimsy.udel.edu +19 -4 + Documentation cleanup from Dave Mills + + html/index.html@1.40, 2009-07-15 16:25:22-04:00, stenn@whimsy.udel.edu +7 -2 + Documentation cleanup from Dave Mills + + html/manyopt.html@1.19, 2009-07-15 16:25:24-04:00, stenn@whimsy.udel.edu +5 -1 + Documentation cleanup from Dave Mills + +ChangeSet@1.1908, 2009-07-15 07:52:57-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P188 + TAG: NTP_4_2_5P188 + + ChangeLog@1.369, 2009-07-15 07:52:28-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P188 + + gsoc_sntp/sntp-opts.c@1.49, 2009-07-15 07:52:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P188 + + gsoc_sntp/sntp-opts.h@1.49, 2009-07-15 07:52:30-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P188 + + gsoc_sntp/sntp-opts.texi@1.49, 2009-07-15 07:52:31-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P188 + + gsoc_sntp/sntp.1@1.49, 2009-07-15 07:52:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P188 + + ntpd/ntpd-opts.c@1.181, 2009-07-15 07:52:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P188 + + ntpd/ntpd-opts.h@1.181, 2009-07-15 07:52:34-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P188 + + ntpd/ntpd-opts.texi@1.179, 2009-07-15 07:52:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P188 + + ntpd/ntpd.1@1.179, 2009-07-15 07:52:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P188 + + ntpdc/ntpdc-opts.c@1.176, 2009-07-15 07:52:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P188 + + ntpdc/ntpdc-opts.h@1.176, 2009-07-15 07:52:37-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P188 + + ntpdc/ntpdc-opts.texi@1.175, 2009-07-15 07:52:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P188 + + ntpdc/ntpdc.1@1.175, 2009-07-15 07:52:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P188 + + ntpq/ntpq-opts.c@1.176, 2009-07-15 07:52:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P188 + + ntpq/ntpq-opts.h@1.176, 2009-07-15 07:52:40-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P188 + + ntpq/ntpq-opts.texi@1.175, 2009-07-15 07:52:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P188 + + ntpq/ntpq.1@1.175, 2009-07-15 07:52:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P188 + + ntpsnmpd/ntpsnmpd-opts.c@1.57, 2009-07-15 07:52:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P188 + + ntpsnmpd/ntpsnmpd-opts.h@1.57, 2009-07-15 07:52:44-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P188 + + ntpsnmpd/ntpsnmpd-opts.texi@1.57, 2009-07-15 07:52:45-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P188 + + ntpsnmpd/ntpsnmpd.1@1.57, 2009-07-15 07:52:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P188 + + packageinfo.sh@1.191, 2009-07-15 07:52:46-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P188 + + sntp/sntp-opts.c@1.176, 2009-07-15 07:52:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P188 + + sntp/sntp-opts.h@1.176, 2009-07-15 07:52:48-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P188 + + sntp/sntp-opts.texi@1.175, 2009-07-15 07:52:49-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P188 + + sntp/sntp.1@1.175, 2009-07-15 07:52:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P188 + + util/ntp-keygen-opts.c@1.179, 2009-07-15 07:52:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P188 + + util/ntp-keygen-opts.h@1.179, 2009-07-15 07:52:51-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P188 + + util/ntp-keygen-opts.texi@1.178, 2009-07-15 07:52:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P188 + + util/ntp-keygen.1@1.178, 2009-07-15 07:52:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P188 + +ChangeSet@1.1907, 2009-07-15 00:35:46-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1245] Broken xmt time sent in fast_xmit() of 4.2.5p187 + + ChangeLog@1.368, 2009-07-15 00:35:06-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1245] Broken xmt time sent in fast_xmit() of 4.2.5p187 + + ntpd/ntp_proto.c@1.291, 2009-07-15 00:35:07-04:00, stenn@whimsy.udel.edu +1 -2 + [Bug 1245] Broken xmt time sent in fast_xmit() of 4.2.5p187 + +ChangeSet@1.1906, 2009-07-11 07:57:23-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P187 + TAG: NTP_4_2_5P187 + + ChangeLog@1.367, 2009-07-11 07:56:56-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P187 + + gsoc_sntp/sntp-opts.c@1.48, 2009-07-11 07:56:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P187 + + gsoc_sntp/sntp-opts.h@1.48, 2009-07-11 07:56:58-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P187 + + gsoc_sntp/sntp-opts.texi@1.48, 2009-07-11 07:56:59-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P187 + + gsoc_sntp/sntp.1@1.48, 2009-07-11 07:56:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P187 + + ntpd/ntpd-opts.c@1.180, 2009-07-11 07:57:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P187 + + ntpd/ntpd-opts.h@1.180, 2009-07-11 07:57:00-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P187 + + ntpd/ntpd-opts.texi@1.178, 2009-07-11 07:57:01-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P187 + + ntpd/ntpd.1@1.178, 2009-07-11 07:57:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P187 + + ntpdc/ntpdc-opts.c@1.175, 2009-07-11 07:57:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P187 + + ntpdc/ntpdc-opts.h@1.175, 2009-07-11 07:57:04-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P187 + + ntpdc/ntpdc-opts.texi@1.174, 2009-07-11 07:57:05-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P187 + + ntpdc/ntpdc.1@1.174, 2009-07-11 07:57:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P187 + + ntpq/ntpq-opts.c@1.175, 2009-07-11 07:57:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P187 + + ntpq/ntpq-opts.h@1.175, 2009-07-11 07:57:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P187 + + ntpq/ntpq-opts.texi@1.174, 2009-07-11 07:57:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P187 + + ntpq/ntpq.1@1.174, 2009-07-11 07:57:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P187 + + ntpsnmpd/ntpsnmpd-opts.c@1.56, 2009-07-11 07:57:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P187 + + ntpsnmpd/ntpsnmpd-opts.h@1.56, 2009-07-11 07:57:11-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P187 + + ntpsnmpd/ntpsnmpd-opts.texi@1.56, 2009-07-11 07:57:12-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P187 + + ntpsnmpd/ntpsnmpd.1@1.56, 2009-07-11 07:57:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P187 + + packageinfo.sh@1.190, 2009-07-11 07:57:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P187 + + sntp/sntp-opts.c@1.175, 2009-07-11 07:57:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P187 + + sntp/sntp-opts.h@1.175, 2009-07-11 07:57:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P187 + + sntp/sntp-opts.texi@1.174, 2009-07-11 07:57:15-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P187 + + sntp/sntp.1@1.174, 2009-07-11 07:57:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P187 + + util/ntp-keygen-opts.c@1.178, 2009-07-11 07:57:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P187 + + util/ntp-keygen-opts.h@1.178, 2009-07-11 07:57:17-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P187 + + util/ntp-keygen-opts.texi@1.177, 2009-07-11 07:57:18-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P187 + + util/ntp-keygen.1@1.177, 2009-07-11 07:57:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P187 + +ChangeSet@1.1901.2.2, 2009-07-11 01:48:52-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1242] Remove --enable-wintime + + configure.ac@1.447, 2009-07-11 01:48:36-04:00, stenn@whimsy.udel.edu +0 -25 + [Bug 1242] Remove --enable-wintime + +ChangeSet@1.1901.3.1, 2009-07-11 05:47:56+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1237] Windows serial code treat CR and LF both as line + terminators. + [Bug 1238] use fudge time2 for serial timecode offset in NMEA driver. + document fudge time1 as PPS offset, fudge time2 as serial timecode offset + for driver20.html (NMEA) + + ChangeLog@1.362.3.1, 2009-07-11 05:47:55+00:00, davehart@shiny.ad.hartbrothers.com +5 -1 + [Bug 1237] Windows serial code treat CR and LF both as line + terminators. + [Bug 1238] use fudge time2 for serial timecode offset in NMEA driver. + + html/drivers/driver20.html@1.20, 2009-07-11 05:47:55+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + Document fudge time2 as serial-only offset, time1 as PPS-only + + ntpd/refclock_nmea.c@1.41, 2009-07-11 05:47:55+00:00, davehart@shiny.ad.hartbrothers.com +14 -2 + [Bug 1238] use fudge time2 for serial timecode offset in NMEA driver. + + ports/winnt/ntpd/ntp_iocompletionport.c@1.45, 2009-07-11 05:47:55+00:00, davehart@shiny.ad.hartbrothers.com +22 -2 + [Bug 1237] Windows serial code treat CR and LF both as line terminators. + +ChangeSet@1.1901.2.1, 2009-07-11 01:37:42-04:00, stenn@whimsy.udel.edu +8 -0 + Added restrict keyword "mssntp" for Samba4 DC operation, by Dave Mills + + ChangeLog@1.362.2.1, 2009-07-11 01:25:48-04:00, stenn@whimsy.udel.edu +3 -0 + Added restrict keyword "mssntp" for Samba4 DC operation, by Dave Mills + + html/accopt.html@1.29, 2009-07-11 01:25:48-04:00, stenn@whimsy.udel.edu +13 -12 + Added restrict keyword "mssntp" for Samba4 DC operation, by Dave Mills + + include/ntp.h@1.160, 2009-07-11 01:26:03-04:00, stenn@whimsy.udel.edu +15 -16 + Added restrict keyword "mssntp" for Samba4 DC operation, by Dave Mills + + ntpd/ntp_config.c@1.197, 2009-07-11 01:34:41-04:00, stenn@whimsy.udel.edu +1 -0 + Added restrict keyword "mssntp" for Samba4 DC operation, by Dave Mills + + ntpd/ntp_parser.c@1.39, 2009-07-11 01:34:44-04:00, stenn@whimsy.udel.edu +897 -887 + Added restrict keyword "mssntp" for Samba4 DC operation, by Dave Mills + + ntpd/ntp_parser.h@1.23, 2009-07-11 01:34:47-04:00, stenn@whimsy.udel.edu +203 -201 + Added restrict keyword "mssntp" for Samba4 DC operation, by Dave Mills + + ntpd/ntp_parser.y@1.34, 2009-07-11 01:34:48-04:00, stenn@whimsy.udel.edu +2 -0 + Added restrict keyword "mssntp" for Samba4 DC operation, by Dave Mills + + ntpd/ntp_proto.c@1.290, 2009-07-11 01:34:49-04:00, stenn@whimsy.udel.edu +35 -39 + Added restrict keyword "mssntp" for Samba4 DC operation, by Dave Mills + +ChangeSet@1.1901.1.3, 2009-07-11 04:41:58+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1244] NTP_INSIST(fd != maxactivefd) failure in intres child + + ChangeLog@1.362.1.3, 2009-07-11 04:41:57+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1244] NTP_INSIST(fd != maxactivefd) failure in intres child + + include/ntpd.h@1.129, 2009-07-11 04:41:57+00:00, davehart@shiny.ad.hartbrothers.com +3 -1 + conditionalize kill_asyncio(), not used on Windows + + ntpd/ntp_io.c@1.289.1.1, 2009-07-11 04:41:57+00:00, davehart@shiny.ad.hartbrothers.com +13 -0 + [Bug 1244] NTP_INSIST(fd != maxactivefd) failure in intres child + +ChangeSet@1.1901.1.2, 2009-07-08 07:53:10-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P186 + TAG: NTP_4_2_5P186 + + ChangeLog@1.362.1.2, 2009-07-08 07:52:40-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P186 + + gsoc_sntp/sntp-opts.c@1.47, 2009-07-08 07:52:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P186 + + gsoc_sntp/sntp-opts.h@1.47, 2009-07-08 07:52:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P186 + + gsoc_sntp/sntp-opts.texi@1.47, 2009-07-08 07:52:44-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P186 + + gsoc_sntp/sntp.1@1.47, 2009-07-08 07:52:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P186 + + ntpd/ntpd-opts.c@1.179, 2009-07-08 07:52:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P186 + + ntpd/ntpd-opts.h@1.179, 2009-07-08 07:52:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P186 + + ntpd/ntpd-opts.texi@1.177, 2009-07-08 07:52:48-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P186 + + ntpd/ntpd.1@1.177, 2009-07-08 07:52:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P186 + + ntpdc/ntpdc-opts.c@1.174, 2009-07-08 07:52:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P186 + + ntpdc/ntpdc-opts.h@1.174, 2009-07-08 07:52:51-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P186 + + ntpdc/ntpdc-opts.texi@1.173, 2009-07-08 07:52:52-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P186 + + ntpdc/ntpdc.1@1.173, 2009-07-08 07:52:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P186 + + ntpq/ntpq-opts.c@1.174, 2009-07-08 07:52:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P186 + + ntpq/ntpq-opts.h@1.174, 2009-07-08 07:52:55-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P186 + + ntpq/ntpq-opts.texi@1.173, 2009-07-08 07:52:55-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P186 + + ntpq/ntpq.1@1.173, 2009-07-08 07:52:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P186 + + ntpsnmpd/ntpsnmpd-opts.c@1.55, 2009-07-08 07:52:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P186 + + ntpsnmpd/ntpsnmpd-opts.h@1.55, 2009-07-08 07:52:58-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P186 + + ntpsnmpd/ntpsnmpd-opts.texi@1.55, 2009-07-08 07:52:58-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P186 + + ntpsnmpd/ntpsnmpd.1@1.55, 2009-07-08 07:52:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P186 + + packageinfo.sh@1.189, 2009-07-08 07:53:00-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P186 + + sntp/sntp-opts.c@1.174, 2009-07-08 07:53:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P186 + + sntp/sntp-opts.h@1.174, 2009-07-08 07:53:01-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P186 + + sntp/sntp-opts.texi@1.173, 2009-07-08 07:53:02-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P186 + + sntp/sntp.1@1.173, 2009-07-08 07:53:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P186 + + util/ntp-keygen-opts.c@1.177, 2009-07-08 07:53:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P186 + + util/ntp-keygen-opts.h@1.177, 2009-07-08 07:53:04-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P186 + + util/ntp-keygen-opts.texi@1.176, 2009-07-08 07:53:05-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P186 + + util/ntp-keygen.1@1.176, 2009-07-08 07:53:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P186 + +ChangeSet@1.1901.1.1, 2009-07-08 02:47:48-04:00, stenn@whimsy.udel.edu +2 -0 + ntp_proto.c cleanup from Dave Mills + + ChangeLog@1.362.1.1, 2009-07-08 02:47:34-04:00, stenn@whimsy.udel.edu +1 -0 + ntp_proto.c cleanup from Dave Mills + + ntpd/ntp_proto.c@1.289, 2009-07-08 02:47:02-04:00, stenn@whimsy.udel.edu +19 -30 + cleanup from Dave Mills + +ChangeSet@1.1889.2.1, 2009-07-03 03:26:28+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + ChangeLog: + [Bug 1042] multicast listeners IPv4+6 ignore new interfaces + ntp_io.c: + [Bug 1042] multicast listeners IPv4+6 ignore new interfaces + more detailed DPRINTFs + + ChangeLog@1.351.2.1, 2009-07-03 03:26:18+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1042] multicast listeners IPv4+6 ignore new interfaces + + ntpd/ntp_io.c@1.288.1.1, 2009-07-03 03:26:19+00:00, davehart@shiny.ad.hartbrothers.com +10 -3 + [Bug 1042] multicast listeners IPv4+6 ignore new interfaces + more detailed DPRINTFs + +ChangeSet@1.1901, 2009-07-01 07:53:52-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P185 + TAG: NTP_4_2_5P185 + + ChangeLog@1.362, 2009-07-01 07:53:20-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P185 + + gsoc_sntp/sntp-opts.c@1.46, 2009-07-01 07:53:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P185 + + gsoc_sntp/sntp-opts.h@1.46, 2009-07-01 07:53:22-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P185 + + gsoc_sntp/sntp-opts.texi@1.46, 2009-07-01 07:53:23-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P185 + + gsoc_sntp/sntp.1@1.46, 2009-07-01 07:53:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P185 + + ntpd/ntpd-opts.c@1.178, 2009-07-01 07:53:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P185 + + ntpd/ntpd-opts.h@1.178, 2009-07-01 07:53:26-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P185 + + ntpd/ntpd-opts.texi@1.176, 2009-07-01 07:53:26-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P185 + + ntpd/ntpd.1@1.176, 2009-07-01 07:53:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P185 + + ntpdc/ntpdc-opts.c@1.173, 2009-07-01 07:53:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P185 + + ntpdc/ntpdc-opts.h@1.173, 2009-07-01 07:53:29-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P185 + + ntpdc/ntpdc-opts.texi@1.172, 2009-07-01 07:53:30-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P185 + + ntpdc/ntpdc.1@1.172, 2009-07-01 07:53:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P185 + + ntpq/ntpq-opts.c@1.173, 2009-07-01 07:53:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P185 + + ntpq/ntpq-opts.h@1.173, 2009-07-01 07:53:32-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P185 + + ntpq/ntpq-opts.texi@1.172, 2009-07-01 07:53:33-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P185 + + ntpq/ntpq.1@1.172, 2009-07-01 07:53:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P185 + + ntpsnmpd/ntpsnmpd-opts.c@1.54, 2009-07-01 07:53:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P185 + + ntpsnmpd/ntpsnmpd-opts.h@1.54, 2009-07-01 07:53:36-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P185 + + ntpsnmpd/ntpsnmpd-opts.texi@1.54, 2009-07-01 07:53:36-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P185 + + ntpsnmpd/ntpsnmpd.1@1.54, 2009-07-01 07:53:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P185 + + packageinfo.sh@1.188, 2009-07-01 07:53:38-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P185 + + sntp/sntp-opts.c@1.173, 2009-07-01 07:53:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P185 + + sntp/sntp-opts.h@1.173, 2009-07-01 07:53:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P185 + + sntp/sntp-opts.texi@1.172, 2009-07-01 07:53:40-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P185 + + sntp/sntp.1@1.172, 2009-07-01 07:53:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P185 + + util/ntp-keygen-opts.c@1.176, 2009-07-01 07:53:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P185 + + util/ntp-keygen-opts.h@1.176, 2009-07-01 07:53:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P185 + + util/ntp-keygen-opts.texi@1.175, 2009-07-01 07:53:43-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P185 + + util/ntp-keygen.1@1.175, 2009-07-01 07:53:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P185 + +ChangeSet@1.1900, 2009-07-01 03:06:34-04:00, stenn@whimsy.udel.edu +4 -0 + Documentation updates from Dave Mills + + ChangeLog@1.361, 2009-07-01 03:06:20-04:00, stenn@whimsy.udel.edu +2 -1 + Documentation updates from Dave Mills + + html/miscopt.html@1.43, 2009-07-01 03:05:19-04:00, stenn@whimsy.udel.edu +2 -2 + Documentation updates from Dave Mills + + html/ntpd.html@1.49, 2009-07-01 03:05:21-04:00, stenn@whimsy.udel.edu +2 -2 + Documentation updates from Dave Mills + + html/prefer.html@1.22, 2009-07-01 03:05:24-04:00, stenn@whimsy.udel.edu +134 -31 + Documentation updates from Dave Mills + +ChangeSet@1.1898, 2009-06-30 14:46:05-04:00, clemens@pogo.udel.edu +1 -0 + Fix order of declarations. + + ntpd/refclock_oncore.c@1.77, 2009-06-30 14:41:22-04:00, clemens@pogo.udel.edu +1 -2 + +ChangeSet@1.1895.1.2, 2009-06-30 07:59:26+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + driver20.html: + note fudge flag1 now enables/disables (default) PPSAPI support + make bitrate setting values more obvious to those not fluent in binary shifting + ChangeLog: + punctuation + + ChangeLog@1.359, 2009-06-30 07:59:23+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + punctuation + + html/drivers/driver20.html@1.19, 2009-06-30 07:59:23+00:00, davehart@shiny.ad.hartbrothers.com +6 -6 + note fudge flag1 now enables/disables (default) PPSAPI support + make bitrate setting values more obvious to those not fluent in binary shifting + +ChangeSet@1.1897, 2009-06-30 03:41:23-04:00, stenn@pogo.udel.edu +1 -0 + typos + + ChangeLog@1.357.1.2, 2009-06-30 03:41:14-04:00, stenn@pogo.udel.edu +2 -2 + typos + + ChangeLog@1.357.1.1, 2009-06-29 13:46:31-04:00, clemens@pogo.udel.edu +3 -0 + Declaration order fixed. + +ChangeSet@1.1896, 2009-06-25 02:13:57-04:00, clemens@pogo.udel.edu +1 -0 + ChangeLog additon, ONCORE use of #if 0 where it used #ifdef DEBUG + + ntpd/refclock_oncore.c@1.76, 2009-06-25 02:05:31-04:00, clemens@pogo.udel.edu +14 -22 + No BUG[]. NTP now uses the DEBUG preprocessor variable. I have now bracketed + private debug statements with #if 0 rather than #ifdef DEBUG + +ChangeSet@1.1895, 2009-06-24 07:52:37-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P184 + TAG: NTP_4_2_5P184 + + ChangeLog@1.357, 2009-06-24 07:52:10-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P184 + + gsoc_sntp/sntp-opts.c@1.45, 2009-06-24 07:52:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P184 + + gsoc_sntp/sntp-opts.h@1.45, 2009-06-24 07:52:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P184 + + gsoc_sntp/sntp-opts.texi@1.45, 2009-06-24 07:52:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P184 + + gsoc_sntp/sntp.1@1.45, 2009-06-24 07:52:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P184 + + ntpd/ntpd-opts.c@1.177, 2009-06-24 07:52:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P184 + + ntpd/ntpd-opts.h@1.177, 2009-06-24 07:52:16-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P184 + + ntpd/ntpd-opts.texi@1.175, 2009-06-24 07:52:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P184 + + ntpd/ntpd.1@1.175, 2009-06-24 07:52:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P184 + + ntpdc/ntpdc-opts.c@1.172, 2009-06-24 07:52:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P184 + + ntpdc/ntpdc-opts.h@1.172, 2009-06-24 07:52:19-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P184 + + ntpdc/ntpdc-opts.texi@1.171, 2009-06-24 07:52:20-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P184 + + ntpdc/ntpdc.1@1.171, 2009-06-24 07:52:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P184 + + ntpq/ntpq-opts.c@1.172, 2009-06-24 07:52:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P184 + + ntpq/ntpq-opts.h@1.172, 2009-06-24 07:52:22-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P184 + + ntpq/ntpq-opts.texi@1.171, 2009-06-24 07:52:23-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P184 + + ntpq/ntpq.1@1.171, 2009-06-24 07:52:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P184 + + ntpsnmpd/ntpsnmpd-opts.c@1.53, 2009-06-24 07:52:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P184 + + ntpsnmpd/ntpsnmpd-opts.h@1.53, 2009-06-24 07:52:25-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P184 + + ntpsnmpd/ntpsnmpd-opts.texi@1.53, 2009-06-24 07:52:26-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P184 + + ntpsnmpd/ntpsnmpd.1@1.53, 2009-06-24 07:52:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P184 + + packageinfo.sh@1.187, 2009-06-24 07:52:27-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P184 + + sntp/sntp-opts.c@1.172, 2009-06-24 07:52:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P184 + + sntp/sntp-opts.h@1.172, 2009-06-24 07:52:28-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P184 + + sntp/sntp-opts.texi@1.171, 2009-06-24 07:52:29-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P184 + + sntp/sntp.1@1.171, 2009-06-24 07:52:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P184 + + util/ntp-keygen-opts.c@1.175, 2009-06-24 07:52:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P184 + + util/ntp-keygen-opts.h@1.175, 2009-06-24 07:52:32-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P184 + + util/ntp-keygen-opts.texi@1.174, 2009-06-24 07:52:33-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P184 + + util/ntp-keygen.1@1.174, 2009-06-24 07:52:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P184 + +ChangeSet@1.1894, 2009-06-24 01:25:37-04:00, stenn@whimsy.udel.edu +2 -0 + [Bg 1233] atom refclock fudge time1 sign flipped in 4.2.4p164 + + ChangeLog@1.356, 2009-06-24 01:25:23-04:00, stenn@whimsy.udel.edu +1 -0 + [Bg 1233] atom refclock fudge time1 sign flipped in 4.2.4p164 + + ntpd/ntp_refclock.c@1.89, 2009-06-24 01:25:22-04:00, stenn@whimsy.udel.edu +1 -1 + [Bg 1233] atom refclock fudge time1 sign flipped in 4.2.4p164 + +ChangeSet@1.1893, 2009-06-23 07:55:19-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P183 + TAG: NTP_4_2_5P183 + + ChangeLog@1.355, 2009-06-23 07:54:47-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P183 + + gsoc_sntp/sntp-opts.c@1.44, 2009-06-23 07:54:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P183 + + gsoc_sntp/sntp-opts.h@1.44, 2009-06-23 07:54:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P183 + + gsoc_sntp/sntp-opts.texi@1.44, 2009-06-23 07:54:50-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P183 + + gsoc_sntp/sntp.1@1.44, 2009-06-23 07:54:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P183 + + ntpd/ntpd-opts.c@1.176, 2009-06-23 07:54:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P183 + + ntpd/ntpd-opts.h@1.176, 2009-06-23 07:54:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P183 + + ntpd/ntpd-opts.texi@1.174, 2009-06-23 07:54:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P183 + + ntpd/ntpd.1@1.174, 2009-06-23 07:54:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P183 + + ntpdc/ntpdc-opts.c@1.171, 2009-06-23 07:54:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P183 + + ntpdc/ntpdc-opts.h@1.171, 2009-06-23 07:54:55-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P183 + + ntpdc/ntpdc-opts.texi@1.170, 2009-06-23 07:54:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P183 + + ntpdc/ntpdc.1@1.170, 2009-06-23 07:54:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P183 + + ntpq/ntpq-opts.c@1.171, 2009-06-23 07:54:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P183 + + ntpq/ntpq-opts.h@1.171, 2009-06-23 07:54:58-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P183 + + ntpq/ntpq-opts.texi@1.170, 2009-06-23 07:54:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P183 + + ntpq/ntpq.1@1.170, 2009-06-23 07:55:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P183 + + ntpsnmpd/ntpsnmpd-opts.c@1.52, 2009-06-23 07:55:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P183 + + ntpsnmpd/ntpsnmpd-opts.h@1.52, 2009-06-23 07:55:02-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P183 + + ntpsnmpd/ntpsnmpd-opts.texi@1.52, 2009-06-23 07:55:03-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P183 + + ntpsnmpd/ntpsnmpd.1@1.52, 2009-06-23 07:55:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P183 + + packageinfo.sh@1.186, 2009-06-23 07:55:04-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P183 + + sntp/sntp-opts.c@1.171, 2009-06-23 07:55:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P183 + + sntp/sntp-opts.h@1.171, 2009-06-23 07:55:05-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P183 + + sntp/sntp-opts.texi@1.170, 2009-06-23 07:55:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P183 + + sntp/sntp.1@1.170, 2009-06-23 07:55:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P183 + + util/ntp-keygen-opts.c@1.174, 2009-06-23 07:55:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P183 + + util/ntp-keygen-opts.h@1.174, 2009-06-23 07:55:09-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P183 + + util/ntp-keygen-opts.texi@1.173, 2009-06-23 07:55:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P183 + + util/ntp-keygen.1@1.173, 2009-06-23 07:55:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P183 + +ChangeSet@1.1881.3.2, 2009-06-19 02:45:57+00:00, hart@pogo.udel.edu +1 -0 + ChangeLog: + [Bug 1210], [Bug 1218], ONCORE logs to msyslog as well as clockstats + + ChangeLog@1.343.3.2, 2009-06-19 02:42:48+00:00, hart@pogo.udel.edu +5 -2 + [Bug 1210], [Bug 1218], ONCORE logs to msyslog as well as clockstats + +ChangeSet@1.1889.1.1, 2009-06-18 21:28:09+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + libntpq.h, ChangeLog: + [Bug 1231] ntpsnmpd build fails after sockaddr union changes + + ChangeLog@1.351.1.1, 2009-06-18 21:27:57+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1231] ntpsnmpd build fails after sockaddr union changes + + ntpq/libntpq.h@1.3, 2009-06-18 21:27:57+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1231] ntpsnmpd build fails after sockaddr union changes + +ChangeSet@1.1890, 2009-06-18 12:35:02+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + ntp_io.c, ChangeLog: + [Bug 1196] setsockopt(SO_EXCLUSIVEADDRUSE) can fail on Windows 2000 + and earlier with WSAINVAL, do not log a complaint in that case. + nt_clockstuff.c: + fix EOPNOTSUPP macro redefinition warning introduced with support for + PPSAPI on Windows. + + ChangeLog@1.352, 2009-06-18 12:34:56+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1196] setsockopt(SO_EXCLUSIVEADDRUSE) can fail on Windows 2000 + and earlier with WSAINVAL, do not log a complaint in that case. + + ntpd/ntp_io.c@1.289, 2009-06-18 12:34:57+00:00, davehart@shiny.ad.hartbrothers.com +24 -4 + [Bug 1196] setsockopt(SO_EXCLUSIVEADDRUSE) can fail on Windows 2000 + and earlier with WSAINVAL, do not log a complaint in that case. + + ports/winnt/ntpd/nt_clockstuff.c@1.34, 2009-06-18 12:34:57+00:00, davehart@shiny.ad.hartbrothers.com +8 -1 + fix EOPNOTSUPP macro redefinition warning introduced with support for + PPSAPI on Windows. + +ChangeSet@1.1889, 2009-06-18 08:00:58-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P182 + TAG: NTP_4_2_5P182 + + ChangeLog@1.351, 2009-06-18 08:00:24-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P182 + + gsoc_sntp/sntp-opts.c@1.43, 2009-06-18 08:00:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P182 + + gsoc_sntp/sntp-opts.h@1.43, 2009-06-18 08:00:27-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P182 + + gsoc_sntp/sntp-opts.texi@1.43, 2009-06-18 08:00:28-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P182 + + gsoc_sntp/sntp.1@1.43, 2009-06-18 08:00:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P182 + + ntpd/ntpd-opts.c@1.175, 2009-06-18 08:00:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P182 + + ntpd/ntpd-opts.h@1.175, 2009-06-18 08:00:31-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P182 + + ntpd/ntpd-opts.texi@1.173, 2009-06-18 08:00:31-04:00, stenn@whimsy.udel.edu +37 -2 + NTP_4_2_5P182 + + ntpd/ntpd.1@1.173, 2009-06-18 08:00:32-04:00, stenn@whimsy.udel.edu +17 -2 + NTP_4_2_5P182 + + ntpdc/ntpdc-opts.c@1.170, 2009-06-18 08:00:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P182 + + ntpdc/ntpdc-opts.h@1.170, 2009-06-18 08:00:34-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P182 + + ntpdc/ntpdc-opts.texi@1.169, 2009-06-18 08:00:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P182 + + ntpdc/ntpdc.1@1.169, 2009-06-18 08:00:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P182 + + ntpq/ntpq-opts.c@1.170, 2009-06-18 08:00:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P182 + + ntpq/ntpq-opts.h@1.170, 2009-06-18 08:00:38-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P182 + + ntpq/ntpq-opts.texi@1.169, 2009-06-18 08:00:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P182 + + ntpq/ntpq.1@1.169, 2009-06-18 08:00:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P182 + + ntpsnmpd/ntpsnmpd-opts.c@1.51, 2009-06-18 08:00:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P182 + + ntpsnmpd/ntpsnmpd-opts.h@1.51, 2009-06-18 08:00:42-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P182 + + ntpsnmpd/ntpsnmpd-opts.texi@1.51, 2009-06-18 08:00:43-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P182 + + ntpsnmpd/ntpsnmpd.1@1.51, 2009-06-18 08:00:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P182 + + packageinfo.sh@1.185, 2009-06-18 08:00:44-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P182 + + sntp/sntp-opts.c@1.170, 2009-06-18 08:00:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P182 + + sntp/sntp-opts.h@1.170, 2009-06-18 08:00:46-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P182 + + sntp/sntp-opts.texi@1.169, 2009-06-18 08:00:46-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P182 + + sntp/sntp.1@1.169, 2009-06-18 08:00:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P182 + + util/ntp-keygen-opts.c@1.173, 2009-06-18 08:00:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P182 + + util/ntp-keygen-opts.h@1.173, 2009-06-18 08:00:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P182 + + util/ntp-keygen-opts.texi@1.172, 2009-06-18 08:00:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P182 + + util/ntp-keygen.1@1.172, 2009-06-18 08:00:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P182 + +ChangeSet@1.1888, 2009-06-18 05:09:12-04:00, stenn@whimsy.udel.edu +2 -0 + Add missing header dependencies to the ntpdc layout verification + + ChangeLog@1.350, 2009-06-18 05:08:56-04:00, stenn@whimsy.udel.edu +1 -0 + Add missing header dependencies to the ntpdc layout verification + + ntpdc/Makefile.am@1.39, 2009-06-18 05:08:57-04:00, stenn@whimsy.udel.edu +1 -1 + Add missing header dependencies to the ntpdc layout verification + +ChangeSet@1.1887, 2009-06-18 05:04:55-04:00, stenn@whimsy.udel.edu +2 -0 + prefer.html updates from Dave Mills + + ChangeLog@1.349, 2009-06-18 05:04:33-04:00, stenn@whimsy.udel.edu +1 -0 + prefer.html updates from Dave Mills + + html/prefer.html@1.21, 2009-06-18 05:04:35-04:00, stenn@whimsy.udel.edu +31 -134 + prefer.html updates from Dave Mills + +ChangeSet@1.1886, 2009-06-18 08:10:30+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ChangeLog: + merge cleanup cleanup + + ChangeLog@1.348, 2009-06-18 08:10:24+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + merge cleanup cleanup + +ChangeSet@1.1881.4.1, 2009-06-18 03:54:37-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1229] autokey segfaults in cert_install() + + ChangeLog@1.343.4.1, 2009-06-18 03:54:18-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1229] autokey segfaults in cert_install() + + ntpd/ntp_crypto.c@1.136.1.1, 2009-06-18 03:54:20-04:00, stenn@whimsy.udel.edu +7 -8 + [Bug 1229] autokey segfaults in cert_install() + +ChangeSet@1.1881.3.1, 2009-06-17 17:02:49-04:00, clemens@pogo.udel.edu +2 -0 + refclock_oncore.c: + BUG[no bug report] A bytes available message for the input subsystem (Debug message). + BUG[no bug report] Change exit statements to return(0) in ONCORE driver top + level program. This signals an error to the calling code. + BUG[1218] The comment on where the oncore driver gets its input file does not + * agree with the code. Change the comment. + BUGS[no bug report] This patch puts back in some code to interpret @@Bl messages + on the VP and extract LEAP SECOND information. See the code for a more complete + comment. + ChangeLog: + Add comment re ONCORE changes to message subsystem. + refclock_oncore.c: + BUG[no bug report] This code adds a message for TRAIM messages. Users often worry about the + driver not starting up, and it is often because of signal strength being low. + Low signal strength will give TRAIM messages. + BUG[1220] OK, big patch, but mostly done mechanically. Change direct calls to write + to clockstats to a call to oncore_log, which now calls the old routine plus msyslog. + Have to set the LOG_LEVELS of the calls for msyslog, and this was done by hand. New + routine oncore_log. + BUGS[no bug report] Users often worry that the code is hung when there is + no output after a restart. If the receiver does not have battery backup + can take up to 30minutes to acuqire an almanac and this is necessary before + the driver can start. This message should reasurre the user that the driver + has not died. + + ChangeLog@1.343.3.1, 2009-06-15 03:25:43-04:00, clemens@pogo.udel.edu +2 -0 + Add comment re ONCORE changes to message subsystem. + + ntpd/refclock_oncore.c@1.75, 2009-06-15 03:19:21-04:00, clemens@pogo.udel.edu +387 -331 + BUG[1220] OK, big patch, but mostly done mechanically. Change direct calls to write + to clockstats to a call to oncore_log, which now calls the old routine plus msyslog. + Have to set the LOG_LEVELS of the calls for msyslog, and this was done by hand. New + routine oncore_log. + + ntpd/refclock_oncore.c@1.74, 2009-06-15 03:13:18-04:00, clemens@pogo.udel.edu +6 -2 + BUG[1218] The comment on where the oncore driver gets its input file does not + * agree with the code. Change the comment. + + + ntpd/refclock_oncore.c@1.73, 2009-06-15 03:08:05-04:00, clemens@pogo.udel.edu +11 -6 + BUG[no bug report] Change exit statements to return(0) in ONCORE driver top + level program. This signals an error to the calling code. + + ntpd/refclock_oncore.c@1.72, 2009-06-15 02:53:52-04:00, clemens@pogo.udel.edu +4 -0 + BUG[no bug report] A bytes available message for the input subsystem (Debug message). + + + ntpd/refclock_oncore.c@1.71, 2009-06-15 02:47:26-04:00, clemens@pogo.udel.edu +8 -1 + BUG[no bug report] This code adds a message for TRAIM messages. Users often worry about the + driver not starting up, and it is often because of signal strength being low. + Low signal strength will give TRAIM messages. + + ntpd/refclock_oncore.c@1.70, 2009-06-15 02:36:58-04:00, clemens@pogo.udel.edu +11 -4 + BUGS[no bug report] Users often worry that the code is hung when there is + no output after a restart. If the receiver does not have battery backup + can take up to 30minutes to acuqire an almanac and this is necessary before + the driver can start. This message should reasurre the user that the driver + has not died. + + ntpd/refclock_oncore.c@1.69, 2009-06-15 02:30:56-04:00, clemens@pogo.udel.edu +149 -1 + BUGS[no bug report] This patch puts back in some code to interpret @@Bl messages + on the VP and extract LEAP SECOND information. See the code for a more complete + comment. + +ChangeSet@1.1881.2.2, 2009-06-16 04:22:15+00:00, davehart@shiny.ad.hartbrothers.com +23 -0 + remove netsyslog(), equivalent to msyslog() + update ports/winnt/libisc/net.c winnt/include/net.h from BIND 9.6.1b1 + to pick up change to call InitSockets (WSAStartup) in net.c + initialize_action (used by isc_net_probe...() routines), making + it safe to initialize ipv4_works and ipv6_works before init_io() + various fixes for build and runtime issues exposed by building + on Solaris, FreeBSD and Linux and testing on Linux + + ChangeLog@1.343.2.2, 2009-06-16 04:21:58+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1225] Broadcast address miscalculated on Windows 4.2.5p180 + + gsoc_sntp/main.c@1.14, 2009-06-16 04:21:58+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + close_socket -> closesocket + + include/ntp.h@1.159, 2009-06-16 04:21:58+00:00, davehart@shiny.ad.hartbrothers.com +3 -2 + spaces -> tab + + include/ntp_rfc2553.h@1.31, 2009-06-16 04:21:58+00:00, davehart@shiny.ad.hartbrothers.com +7 -7 + stay out of system namespace by avoiding leading underscore + + include/ntp_select.h@1.4, 2009-06-16 04:21:58+00:00, davehart@shiny.ad.hartbrothers.com +10 -5 + add InitSockets prototype (new with updated win32 libisc net.c) + + include/ntp_stdlib.h@1.31, 2009-06-16 04:21:59+00:00, davehart@shiny.ad.hartbrothers.com +0 -2 + remove netsyslog, WSAGetLastError tested equivalent to GetLastError + in Windows NT 4.0 and later at least. + + libntp/lib_strbuf.c@1.5, 2009-06-16 04:21:59+00:00, davehart@shiny.ad.hartbrothers.com +3 -2 + correct test for isc_net_probeipvX() return value + + libntp/lib_strbuf.h@1.5, 2009-06-16 04:21:59+00:00, davehart@shiny.ad.hartbrothers.com +0 -2 + ipv4_works, ipv6_works are in ntp_stdlib.h + + libntp/msyslog.c@1.22, 2009-06-16 04:22:00+00:00, davehart@shiny.ad.hartbrothers.com +0 -51 + remove netsyslog, WSAGetLastError tested equivalent to GetLastError + in Windows NT 4.0 and later at least. + + libntp/socktoa.c@1.10, 2009-06-16 04:22:00+00:00, davehart@shiny.ad.hartbrothers.com +10 -7 + allow AF_UNSPEC again, add missing break to case AF_INET6 + + ntpd/ntp_intres.c@1.63, 2009-06-16 04:22:01+00:00, davehart@shiny.ad.hartbrothers.com +7 -14 + remove unused LOCALHOST #define, use ipv6_works instead of isc_net_probeipv6() + use estrdup() + remove \n from msyslog() format string + + ntpd/ntp_io.c@1.288, 2009-06-16 04:22:01+00:00, davehart@shiny.ad.hartbrothers.com +40 -51 + one missed merge cleanup + header shuffle to fix unix build + a = b = c == d is an assignment but not the one intended + itf_flags = -> itf_flags |=, parentheses + use isc_net_probe_ipv6only() to decide if we setsockopt(IPV6_V6ONLY) + extraneous '&' broke unix recvfrom/recvmsg + + ntpd/ntpd.c@1.102.1.2, 2009-06-16 04:22:03+00:00, davehart@shiny.ad.hartbrothers.com +3 -3 + move init_lib() call back to original location + remove netsyslog, WSAGetLastError tested equivalent to GetLastError + in Windows NT 4.0 and later at least. + + ntpdate/ntpdate.c@1.67, 2009-06-16 04:22:04+00:00, davehart@shiny.ad.hartbrothers.com +24 -34 + if (isc_net_probeipv6() != ISC_R_SUCCESS) -> if (!ipv6_works) + remove netsyslog, WSAGetLastError tested equivalent to GetLastError + in Windows NT 4.0 and later at least. + remove explicit WSAStartup() call on Windows, now handled in init_lib() + + ntpdc/ntpdc.c@1.65, 2009-06-16 04:22:05+00:00, davehart@shiny.ad.hartbrothers.com +3 -10 + if (isc_net_probeipv6() != ISC_R_SUCCESS) -> if (!ipv6_works) + remove Win32InitSockets call, handled by init_lib() now + + ntpq/ntpq.c@1.87, 2009-06-16 04:22:05+00:00, davehart@shiny.ad.hartbrothers.com +2 -8 + if (isc_net_probeipv6() != ISC_R_SUCCESS) -> if (!ipv6_works) + remove Win32InitSockets call, handled by init_lib() now + + ports/winnt/include/config.h@1.67.2.2, 2009-06-16 04:22:09+00:00, davehart@shiny.ad.hartbrothers.com +0 -2 + remove INCLUDE_IPV6_SUPPORT, INCLUDE_IPV6_MULTICAST_SUPPORT, unneeded + + ports/winnt/include/isc/net.h@1.7, 2009-06-16 04:22:10+00:00, davehart@shiny.ad.hartbrothers.com +50 -31 + updated from BIND 9.6.1.b1 + + ports/winnt/libisc/interfaceiter.c@1.9, 2009-06-16 04:22:10+00:00, davehart@shiny.ad.hartbrothers.com +6 -6 + [Bug 1225] set netmask before using it to calculate broadcast address + in internal_current() + + ports/winnt/libisc/net.c@1.9, 2009-06-16 04:22:10+00:00, davehart@shiny.ad.hartbrothers.com +79 -72 + updated from BIND 9.6.1.b1 + + ports/winnt/libntp/libntp.vcproj@1.8, 2009-06-16 04:22:11+00:00, davehart@shiny.ad.hartbrothers.com +0 -22 + remove dnslookup.c reference, unused code unlikely to be revived + + ports/winnt/libntp/setpriority.c@1.2, 2009-06-16 04:22:11+00:00, davehart@shiny.ad.hartbrothers.com +28 -0 + Add InitSockets() to libntp for Windows (needed by updated + ports/winnt/libisc/net.c) + + ports/winnt/ntpd/ntp_iocompletionport.c@1.42.1.2, 2009-06-16 04:22:12+00:00, davehart@shiny.ad.hartbrothers.com +1 -13 + remove short-lived dummy InitSockets from mixed libisc versions, + now lives in libntp (ports/winnt/libntp/setpriority.c) + remove netsyslog, WSAGetLastError tested equivalent to GetLastError + in Windows NT 4.0 and later at least. + +ChangeSet@1.1873.1.1, 2009-06-15 03:46:17+00:00, davehart@shiny.ad.hartbrothers.com +68 -0 + Use a union for structs sockaddr, sockaddr_storage, sockaddr_in, and + sockaddr_in6 to remove casts and enable type checking. Collapse + some previously separate IPv4/IPv6 paths into a single codepath. + + ChangeLog@1.336.1.1, 2009-06-15 03:46:06+00:00, davehart@shiny.ad.hartbrothers.com +4 -1 + Use a union for structs sockaddr, sockaddr_storage, sockaddr_in, and + sockaddr_in6 to remove casts and enable type checking. Collapse + some previously separate IPv4/IPv6 paths into a single codepath. + + gsoc_sntp/main.c@1.13, 2009-06-15 03:46:06+00:00, davehart@shiny.ad.hartbrothers.com +5 -5 + struct sockaddr_storage -> sockaddr_u + use sizeof instead of constant + + gsoc_sntp/networking.c@1.19, 2009-06-15 03:46:06+00:00, davehart@shiny.ad.hartbrothers.com +117 -130 + struct sockaddr_storage -> sockaddr_u + use sizeof instead of constant + + gsoc_sntp/networking.h@1.12, 2009-06-15 03:46:06+00:00, davehart@shiny.ad.hartbrothers.com +6 -8 + struct sockaddr_storage -> sockaddr_u + + gsoc_sntp/utilities.c@1.6, 2009-06-15 03:46:06+00:00, davehart@shiny.ad.hartbrothers.com +5 -3 + struct sockaddr_storage -> sockaddr_u + + gsoc_sntp/utilities.h@1.5, 2009-06-15 03:46:06+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + struct sockaddr_storage -> sockaddr_u + + include/interfaceiter.h@1.4, 2009-06-15 03:45:32+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: BitKeeper/deleted/.del-interfaceiter.h~52531bc -> include/interfaceiter.h + + BitKeeper/deleted/.del-interfaceiter.h~52531bc@1.3, 2009-06-15 03:42:25+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: include/interfaceiter.h -> BitKeeper/deleted/.del-interfaceiter.h~52531bc + + include/iosignal.h@1.4, 2009-06-15 03:46:06+00:00, davehart@shiny.ad.hartbrothers.com +8 -8 + whitespace cleanup + + include/ntp.h@1.155.2.1, 2009-06-15 03:46:06+00:00, davehart@shiny.ad.hartbrothers.com +16 -102 + whitespace cleanup, move sockaddr macros to ntp_net.h + + include/ntp_control.h@1.35, 2009-06-15 03:46:06+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + struct sockaddr_storage -> sockaddr_u + + include/ntp_fp.h@1.15, 2009-06-15 03:46:06+00:00, davehart@shiny.ad.hartbrothers.com +10 -12 + whitespace cleanup, stay out of system namespace by avoiding + leading underscore for identifiers + + include/ntp_malloc.h@1.3, 2009-06-15 03:46:06+00:00, davehart@shiny.ad.hartbrothers.com +5 -5 + stay out of system namespace _ntp_malloc_h -> NTP_MALLOC_H + + include/ntp_net.h@1.2, 2009-06-15 03:46:06+00:00, davehart@shiny.ad.hartbrothers.com +189 -0 + move sockaddr macros from ntp.h, add more + + include/ntp_refclock.h@1.23, 2009-06-15 03:46:07+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + struct sockaddr_storage -> sockaddr_u + + include/ntp_request.h@1.35, 2009-06-15 03:46:07+00:00, davehart@shiny.ad.hartbrothers.com +5 -5 + rename struct info_monitor.lastdrop to restr to reflect its use + + include/ntp_stdlib.h@1.30, 2009-06-15 03:46:07+00:00, davehart@shiny.ad.hartbrothers.com +13 -6 + struct sockaddr_storage -> sockaddr_u + + include/ntpd.h@1.128, 2009-06-15 03:46:07+00:00, davehart@shiny.ad.hartbrothers.com +37 -39 + struct sockaddr_storage -> sockaddr_u + whitespace cleanup + + include/ntpsim.h@1.11, 2009-06-15 03:46:07+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + struct sockaddr_storage -> sockaddr_u + + include/recvbuff.h@1.16.1.1, 2009-06-15 03:46:07+00:00, davehart@shiny.ad.hartbrothers.com +5 -6 + struct sockaddr_storage -> sockaddr_u + + libntp/a_md5encrypt.c@1.19, 2009-06-15 03:46:07+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + struct sockaddr_storage -> sockaddr_u + + libntp/clocktypes.c@1.18, 2009-06-15 03:46:07+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + spaces to tabs + + libntp/decodenetnum.c@1.6.1.1, 2009-06-15 03:46:07+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + struct sockaddr_storage -> sockaddr_u + + libntp/lib_strbuf.c@1.4, 2009-06-15 03:46:07+00:00, davehart@shiny.ad.hartbrothers.com +8 -0 + IPv6 on Windows (cherry picked and previously committed, [Bug 1200]) + + libntp/lib_strbuf.h@1.4, 2009-06-15 03:46:07+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + IPv6 on Windows (cherry picked and previously committed, [Bug 1200]) + + libntp/netof.c@1.7, 2009-06-15 03:46:07+00:00, davehart@shiny.ad.hartbrothers.com +30 -24 + struct sockaddr_storage -> sockaddr_u + + libntp/numtoa.c@1.4, 2009-06-15 03:46:07+00:00, davehart@shiny.ad.hartbrothers.com +5 -3 + sprintf -> snprintf + + libntp/recvbuff.c@1.29.1.1, 2009-06-15 03:46:07+00:00, davehart@shiny.ad.hartbrothers.com +2 -7 + IPv6 on Windows (cherry picked and previously committed, [Bug 1200]) + + libntp/refnumtoa.c@1.6, 2009-06-15 03:46:07+00:00, davehart@shiny.ad.hartbrothers.com +13 -10 + struct sockaddr_storage -> sockaddr_u + sprintf -> snprintf + + libntp/socktoa.c@1.9, 2009-06-15 03:46:08+00:00, davehart@shiny.ad.hartbrothers.com +12 -13 + struct sockaddr_storage -> sockaddr_u + strcpy -> strncpy + + libntp/socktohost.c@1.6, 2009-06-15 03:46:08+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + struct sockaddr_storage -> sockaddr_u + + ntpd/ntp_config.c@1.192.1.1, 2009-06-15 03:46:08+00:00, davehart@shiny.ad.hartbrothers.com +93 -124 + struct sockaddr_storage -> sockaddr_u + + ntpd/ntp_control.c@1.111, 2009-06-15 03:46:08+00:00, davehart@shiny.ad.hartbrothers.com +9 -9 + struct sockaddr_storage -> sockaddr_u + + ntpd/ntp_crypto.c@1.137, 2009-06-15 03:46:08+00:00, davehart@shiny.ad.hartbrothers.com +15 -23 + struct sockaddr_storage -> sockaddr_u + use DPRINTF + emalloc + strcpy -> estrdup + + ntpd/ntp_intres.c@1.62, 2009-06-15 03:46:08+00:00, davehart@shiny.ad.hartbrothers.com +12 -12 + struct sockaddr_storage -> sockaddr_u + + ntpd/ntp_io.c@1.285.1.1, 2009-06-15 03:46:08+00:00, davehart@shiny.ad.hartbrothers.com +1470 -1649 + struct sockaddr_storage -> sockaddr_u + + ntpd/ntp_monitor.c@1.24, 2009-06-15 03:46:08+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + struct sockaddr_storage -> sockaddr_u + + ntpd/ntp_peer.c@1.118.1.1, 2009-06-15 03:46:09+00:00, davehart@shiny.ad.hartbrothers.com +45 -50 + struct sockaddr_storage -> sockaddr_u + + ntpd/ntp_proto.c@1.286.1.1, 2009-06-15 03:46:09+00:00, davehart@shiny.ad.hartbrothers.com +11 -13 + struct sockaddr_storage -> sockaddr_u + use DPRINTF + + ntpd/ntp_refclock.c@1.86.1.1, 2009-06-15 03:46:09+00:00, davehart@shiny.ad.hartbrothers.com +2 -14 + struct sockaddr_storage -> sockaddr_u + ISREFCLOCKADR() no longer assumes address given is IPv4 + + ntpd/ntp_request.c@1.78.1.1, 2009-06-15 03:46:09+00:00, davehart@shiny.ad.hartbrothers.com +323 -339 + struct sockaddr_storage -> sockaddr_u + ISREFCLOCKADR() no longer assumes address given is IPv4 + + ntpd/ntp_restrict.c@1.27, 2009-06-15 03:46:09+00:00, davehart@shiny.ad.hartbrothers.com +19 -23 + struct sockaddr_storage -> sockaddr_u + + ntpd/ntp_timer.c@1.54, 2009-06-15 03:46:09+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + eliminate truncation warning, whitespace + + ntpd/ntp_util.c@1.72, 2009-06-15 03:46:09+00:00, davehart@shiny.ad.hartbrothers.com +14 -14 + struct sockaddr_storage -> sockaddr_u + + ntpd/ntpd.c@1.102.1.1, 2009-06-15 03:46:09+00:00, davehart@shiny.ad.hartbrothers.com +18 -15 + IPv6 on Windows (cherry picked and previously committed, [Bug 1200]) + remove 3rd call to setup_logfile(), only needed once after daemonizing + + ntpd/ntpsim.c@1.21, 2009-06-15 03:46:09+00:00, davehart@shiny.ad.hartbrothers.com +132 -133 + struct sockaddr_storage -> sockaddr_u + use sizeof(var) not sizeof(typeof(var)) to insulate against breakage + whitespace cleanup + + ntpd/refclock_nmea.c@1.37.1.1, 2009-06-15 03:46:10+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + SOCKLEN misuse + use struct recvbuff.recv_peer instead of unioned recv_srcclock to avoid cast + + ntpdate/ntpdate.c@1.66, 2009-06-15 03:46:10+00:00, davehart@shiny.ad.hartbrothers.com +28 -45 + struct sockaddr_storage -> sockaddr_u + + ntpdate/ntpdate.h@1.10, 2009-06-15 03:46:10+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + struct sockaddr_storage -> sockaddr_u + + ntpdc/layout.std@1.8, 2009-06-15 03:46:10+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + rename monlist lastdrop field to restr as it hold restrict bits not time + + ntpdc/ntpdc.c@1.62.1.1, 2009-06-15 03:46:10+00:00, davehart@shiny.ad.hartbrothers.com +8 -10 + struct sockaddr_storage -> sockaddr_u + + ntpdc/ntpdc.h@1.9, 2009-06-15 03:46:10+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + struct sockaddr_storage -> sockaddr_u + + ntpdc/ntpdc_ops.c@1.56.1.1, 2009-06-15 03:46:10+00:00, davehart@shiny.ad.hartbrothers.com +165 -219 + struct sockaddr_storage -> sockaddr_u + + ntpq/libntpq.c@1.3, 2009-06-15 03:46:10+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + struct sockaddr_storage -> sockaddr_u + + ntpq/libntpq.h@1.2, 2009-06-15 03:46:10+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + struct sockaddr_storage -> sockaddr_u + + ntpq/libntpq_subs.c@1.2, 2009-06-15 03:46:10+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + struct sockaddr_storage -> sockaddr_u + + ntpq/ntpq-subs.c@1.31, 2009-06-15 03:46:10+00:00, davehart@shiny.ad.hartbrothers.com +23 -26 + struct sockaddr_storage -> sockaddr_u + + ntpq/ntpq.c@1.84.1.1, 2009-06-15 03:46:10+00:00, davehart@shiny.ad.hartbrothers.com +8 -11 + struct sockaddr_storage -> sockaddr_u + ISREFCLOCKADR() includes IS_IPV4 check + + ntpq/ntpq.h@1.7, 2009-06-15 03:46:10+00:00, davehart@shiny.ad.hartbrothers.com +3 -3 + struct sockaddr_storage -> sockaddr_u + + ports/winnt/include/config.h@1.65.1.1, 2009-06-15 03:46:11+00:00, davehart@shiny.ad.hartbrothers.com +29 -12 + IPv6 on Windows (cherry picked and previously committed, [Bug 1200]) + + ports/winnt/include/ntp_iocompletionport.h@1.17, 2009-06-15 03:46:11+00:00, davehart@shiny.ad.hartbrothers.com +8 -9 + struct sockaddr_storage -> sockaddr_u + IPv6 on Windows (cherry picked and previously committed, [Bug 1200]) + + ports/winnt/include/transmitbuff.h@1.6.1.1, 2009-06-15 03:46:11+00:00, davehart@shiny.ad.hartbrothers.com +3 -7 + IPv6 on Windows (cherry picked and previously committed, [Bug 1200]) + + ports/winnt/include/win32_io.h@1.9.1.1, 2009-06-15 03:46:11+00:00, davehart@shiny.ad.hartbrothers.com +3 -1 + groundwork for bug 1016 (refclock_arc.c support on Windows) + + ports/winnt/libntp/libntp.vcproj@1.5.1.1, 2009-06-15 03:46:11+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add ntp_net.h reference + + ports/winnt/libntp/transmitbuff.c@1.7.1.1, 2009-06-15 03:46:11+00:00, davehart@shiny.ad.hartbrothers.com +10 -6 + IPv6 on Windows (cherry picked and previously committed, [Bug 1200]) + + ports/winnt/ntpd/nt_clockstuff.c@1.29.1.1, 2009-06-15 03:46:11+00:00, davehart@shiny.ad.hartbrothers.com +14 -1 + abort if SIZEOF_ macros are wrong on DEBUG + + ports/winnt/ntpd/ntp_iocompletionport.c@1.41.1.1, 2009-06-15 03:46:11+00:00, davehart@shiny.ad.hartbrothers.com +68 -67 + struct sockaddr_storage -> sockaddr_u + IPv6 on Windows (cherry picked and previously committed, [Bug 1200]) + + ports/winnt/ntpd/ntpd.vcproj@1.5.1.1, 2009-06-15 03:46:11+00:00, davehart@shiny.ad.hartbrothers.com +8 -1 + add ntp_net.h, ntp_signd.c references + no need to exclude refclock_arc.c from build, CLOCK_ARCRON_MSF is not + defined in ports/winnt/include/config.h yet + + ports/winnt/ntpdate/ntpdate.vcproj@1.2.1.1, 2009-06-15 03:46:11+00:00, davehart@shiny.ad.hartbrothers.com +52 -0 + add references to a bunch of headers ntpdate uses + +ChangeSet@1.1881.1.2, 2009-06-12 21:05:42+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + document Windows-specific ntpd options -M, --pccfreq, --usepcc + + html/ntpd.html@1.48, 2009-06-12 21:05:41+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + document Windows-specific ntpd options -M, --pccfreq, --usepcc + +ChangeSet@1.1881.1.1, 2009-06-12 17:53:01+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + [Bug 1205] Add ntpd --usepcc and --pccfreq options on Windows + + ChangeLog@1.343.1.1, 2009-06-12 17:52:59+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1205] Add ntpd --usepcc and --pccfreq options on Windows + + ntpd/ntpd-opts.c@1.174, 2009-06-12 17:52:59+00:00, davehart@shiny.ad.hartbrothers.com +63 -2 + [Bug 1205] Add ntpd --usepcc and --pccfreq options on Windows + generated by autogen autoopts + + ntpd/ntpd-opts.h@1.174, 2009-06-12 17:52:59+00:00, davehart@shiny.ad.hartbrothers.com +23 -5 + [Bug 1205] Add ntpd --usepcc and --pccfreq options on Windows + generated by autogen autoopts + + ntpd/ntpd.c@1.103, 2009-06-12 17:53:00+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + Switch to configured logfile from syslog just before init_winnt_time() + (rather than just after) + + ntpd/ntpdbase-opts.def@1.17, 2009-06-12 17:53:00+00:00, davehart@shiny.ad.hartbrothers.com +24 -0 + [Bug 1205] Add ntpd --usepcc and --pccfreq options on Windows + + ports/winnt/ntpd/nt_clockstuff.c@1.32, 2009-06-12 17:53:00+00:00, davehart@shiny.ad.hartbrothers.com +10 -5 + [Bug 1205] Add ntpd --usepcc and --pccfreq options on Windows + +ChangeSet@1.1880.1.1, 2009-06-09 22:36:51+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + timepps-Solaris.h pps_handle_t changed from pointer to scalar + NMEA refclock converted to use common PPSAPI code + Spectracom refclock added to Windows port of ntpd + + ChangeLog@1.342.1.1, 2009-06-09 22:36:48+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + timepps-Solaris.h pps_handle_t changed from pointer to scalar + NMEA refclock converted to use common PPSAPI code + Spectracom refclock added to Windows port of ntpd + + include/timepps-Solaris.h@1.6, 2009-06-09 22:36:48+00:00, davehart@shiny.ad.hartbrothers.com +50 -31 + timepps-Solaris.h pps_handle_t changed from pointer to scalar + + ntpd/refclock_nmea.c@1.39, 2009-06-09 22:36:49+00:00, davehart@shiny.ad.hartbrothers.com +77 -242 + NMEA refclock converted to use common PPSAPI code + + ports/winnt/include/config.h@1.67.1.1, 2009-06-09 22:36:49+00:00, davehart@shiny.ad.hartbrothers.com +3 -2 + Spectracom refclock added to Windows port of ntpd + + ports/winnt/ntpd/ntpd.vcproj@1.8, 2009-06-09 22:36:49+00:00, davehart@shiny.ad.hartbrothers.com +0 -2 + Spectracom refclock added to Windows port of ntpd + +ChangeSet@1.1882, 2009-06-08 17:51:47+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + [Bug 1215] unpeer by association ID + + ChangeLog@1.344, 2009-06-08 17:51:45+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1215] unpeer by association ID + + include/ntp_config.h@1.53, 2009-06-08 17:51:46+00:00, davehart@shiny.ad.hartbrothers.com +7 -6 + [Bug 1215] unpeer by association ID + + libntp/recvbuff.c@1.31, 2009-06-08 17:51:46+00:00, davehart@shiny.ad.hartbrothers.com +49 -5 + free receive buffers on free, full lists at shutdown on DEBUG + + ntpd/ntp_config.c@1.195, 2009-06-08 17:51:46+00:00, davehart@shiny.ad.hartbrothers.com +43 -7 + [Bug 1215] unpeer by association ID + + ports/winnt/include/config.h@1.68, 2009-06-08 17:51:46+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + added commented #define MALLOC_LINT for ease of enabling it + + ports/winnt/ntpd/ntp_iocompletionport.c@1.43, 2009-06-08 17:51:46+00:00, davehart@shiny.ad.hartbrothers.com +79 -19 + free receive buffers on free, full lists at shutdown on DEBUG + free in-use (receive or send) I/O buffers at shutdown on DEBUG + +ChangeSet@1.1881, 2009-06-06 07:53:58-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P181 + TAG: NTP_4_2_5P181 + + ChangeLog@1.343, 2009-06-06 07:53:26-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P181 + + gsoc_sntp/sntp-opts.c@1.42, 2009-06-06 07:53:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P181 + + gsoc_sntp/sntp-opts.h@1.42, 2009-06-06 07:53:28-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P181 + + gsoc_sntp/sntp-opts.texi@1.42, 2009-06-06 07:53:29-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P181 + + gsoc_sntp/sntp.1@1.42, 2009-06-06 07:53:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P181 + + ntpd/ntpd-opts.c@1.173, 2009-06-06 07:53:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P181 + + ntpd/ntpd-opts.h@1.173, 2009-06-06 07:53:31-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P181 + + ntpd/ntpd-opts.texi@1.172, 2009-06-06 07:53:32-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P181 + + ntpd/ntpd.1@1.172, 2009-06-06 07:53:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P181 + + ntpdc/ntpdc-opts.c@1.169, 2009-06-06 07:53:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P181 + + ntpdc/ntpdc-opts.h@1.169, 2009-06-06 07:53:34-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P181 + + ntpdc/ntpdc-opts.texi@1.168, 2009-06-06 07:53:35-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P181 + + ntpdc/ntpdc.1@1.168, 2009-06-06 07:53:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P181 + + ntpq/ntpq-opts.c@1.169, 2009-06-06 07:53:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P181 + + ntpq/ntpq-opts.h@1.169, 2009-06-06 07:53:37-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P181 + + ntpq/ntpq-opts.texi@1.168, 2009-06-06 07:53:38-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P181 + + ntpq/ntpq.1@1.168, 2009-06-06 07:53:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P181 + + ntpsnmpd/ntpsnmpd-opts.c@1.50, 2009-06-06 07:53:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P181 + + ntpsnmpd/ntpsnmpd-opts.h@1.50, 2009-06-06 07:53:41-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P181 + + ntpsnmpd/ntpsnmpd-opts.texi@1.50, 2009-06-06 07:53:42-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P181 + + ntpsnmpd/ntpsnmpd.1@1.50, 2009-06-06 07:53:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P181 + + packageinfo.sh@1.184, 2009-06-06 07:53:43-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P181 + + sntp/sntp-opts.c@1.169, 2009-06-06 07:53:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P181 + + sntp/sntp-opts.h@1.169, 2009-06-06 07:53:45-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P181 + + sntp/sntp-opts.texi@1.168, 2009-06-06 07:53:46-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P181 + + sntp/sntp.1@1.168, 2009-06-06 07:53:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P181 + + util/ntp-keygen-opts.c@1.172, 2009-06-06 07:53:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P181 + + util/ntp-keygen-opts.h@1.172, 2009-06-06 07:53:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P181 + + util/ntp-keygen-opts.texi@1.171, 2009-06-06 07:53:50-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P181 + + util/ntp-keygen.1@1.171, 2009-06-06 07:53:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P181 + +ChangeSet@1.1877.1.4, 2009-06-06 04:29:46+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + timepps.h: + Use FreeLibrary in load_pps_provider failure paths, correct + (provtime_pps_destroy) cast, and fix for always returning -1 + meaning failure but errno 0 on successful time_pps_destroy() + + ports/winnt/include/timepps.h@1.2, 2009-06-06 04:29:30+00:00, davehart@shiny.ad.hartbrothers.com +10 -2 + Use FreeLibrary in load_pps_provider failure paths, correct + (provtime_pps_destroy) cast, and fix for always returning -1 + meaning failure but errno 0 on successful time_pps_destroy() + +ChangeSet@1.1877.2.1, 2009-06-05 23:35:04+00:00, davehart@shiny.ad.hartbrothers.com +20 -0 + [Bug 1084] PPSAPI for ntpd on Windows with DLL backends + [Bug 1204] Unix-style refclock device paths on Windows + [Bug 1205] partial fix, disable RDTSC use by default on Windows + Enable ONCORE, ARCRON refclocks on Windows (untested) + + + + ChangeLog@1.340.2.1, 2009-06-05 23:34:58+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1084] PPSAPI for ntpd on Windows with DLL backends + [Bug 1204] Unix-style refclock device paths on Windows + [Bug 1205] partial fix, disable RDTSC use by default on Windows + Enable ONCORE, ARCRON refclocks on Windows (untested) + + + include/ntp_types.h@1.13, 2009-06-05 23:34:58+00:00, davehart@shiny.ad.hartbrothers.com +14 -0 + [Bug 1204] Unix-style refclock device paths on Windows + + ntpd/refclock_arc.c@1.20, 2009-06-05 23:34:59+00:00, davehart@shiny.ad.hartbrothers.com +4 -2 + Enable ONCORE, ARCRON refclocks on Windows (untested) + + ntpd/refclock_atom.c@1.60, 2009-06-05 23:34:59+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + [Bug 1204] Unix-style refclock device paths on Windows + + ntpd/refclock_hopfser.c@1.13, 2009-06-05 23:34:59+00:00, davehart@shiny.ad.hartbrothers.com +1 -4 + [Bug 1204] Unix-style refclock device paths on Windows + + ntpd/refclock_nmea.c@1.38, 2009-06-05 23:34:59+00:00, davehart@shiny.ad.hartbrothers.com +12 -12 + [Bug 1204] Unix-style refclock device paths on Windows + quiet type conversion warning + + ntpd/refclock_oncore.c@1.68, 2009-06-05 23:34:59+00:00, davehart@shiny.ad.hartbrothers.com +12 -4 + Enable ONCORE, ARCRON refclocks on Windows (untested) + + ntpd/refclock_palisade.c@1.25, 2009-06-05 23:34:59+00:00, davehart@shiny.ad.hartbrothers.com +2 -4 + [Bug 1204] Unix-style refclock device paths on Windows + + ports/winnt/include/clockstuff.h@1.10, 2009-06-05 23:35:00+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + #include "ntp_fp.h" + + ports/winnt/include/config.h@1.67, 2009-06-05 23:35:00+00:00, davehart@shiny.ad.hartbrothers.com +21 -5 + Enable ONCORE, ARCRON refclocks on Windows (untested) + + ports/winnt/include/timepps.h@1.1, 2009-06-05 23:35:01+00:00, davehart@shiny.ad.hartbrothers.com +803 -0 + [Bug 1084] PPSAPI for ntpd on Windows with DLL backends + + ports/winnt/include/timepps.h@1.0, 2009-06-05 23:35:01+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/ntpd/nt_clockstuff.c@1.31, 2009-06-05 23:35:00+00:00, davehart@shiny.ad.hartbrothers.com +46 -1 + [Bug 1205] partial fix, disable RDTSC use by default on Windows + + ports/winnt/ntpd/ntpd.vcproj@1.7, 2009-06-05 23:35:00+00:00, davehart@shiny.ad.hartbrothers.com +0 -3 + Enable ONCORE, ARCRON refclocks on Windows (untested) + + ports/winnt/ntpd/win32_io.c@1.18, 2009-06-05 23:35:00+00:00, davehart@shiny.ad.hartbrothers.com +75 -34 + [Bug 1204] Unix-style refclock device paths on Windows + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.c@1.1, 2009-06-05 23:35:00+00:00, davehart@shiny.ad.hartbrothers.com +382 -0 + Sample source for Windows PPSAPI provider DLL implementing interface + defined in ports/winnt/include/timepps.h + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.c@1.0, 2009-06-05 23:35:00+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.def@1.1, 2009-06-05 23:35:00+00:00, davehart@shiny.ad.hartbrothers.com +9 -0 + Sample source for Windows PPSAPI provider DLL implementing interface + defined in ports/winnt/include/timepps.h + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.def@1.0, 2009-06-05 23:35:00+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.h@1.1, 2009-06-05 23:35:01+00:00, davehart@shiny.ad.hartbrothers.com +22 -0 + Sample source for Windows PPSAPI provider DLL implementing interface + defined in ports/winnt/include/timepps.h + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.h@1.0, 2009-06-05 23:35:01+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.sln@1.1, 2009-06-05 23:35:01+00:00, davehart@shiny.ad.hartbrothers.com +19 -0 + Sample source for Windows PPSAPI provider DLL implementing interface + defined in ports/winnt/include/timepps.h + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.sln@1.0, 2009-06-05 23:35:01+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.vcproj@1.1, 2009-06-05 23:35:01+00:00, davehart@shiny.ad.hartbrothers.com +227 -0 + Sample source for Windows PPSAPI provider DLL implementing interface + defined in ports/winnt/include/timepps.h + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.vcproj@1.0, 2009-06-05 23:35:01+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/ppsapi/skelprov/sys/time.h@1.1, 2009-06-05 23:35:01+00:00, davehart@shiny.ad.hartbrothers.com +18 -0 + Sample source for Windows PPSAPI provider DLL implementing interface + defined in ports/winnt/include/timepps.h + + ports/winnt/ppsapi/skelprov/sys/time.h@1.0, 2009-06-05 23:35:01+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + +ChangeSet@1.1877.1.2, 2009-06-03 01:35:02+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1211] keysdir free()d twice #ifdef DEBUG + + ChangeLog@1.340.1.2, 2009-06-03 01:35:00+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1211] keysdir free()d twice #ifdef DEBUG + + libntp/decodenetnum.c@1.8, 2009-06-03 01:35:00+00:00, davehart@shiny.ad.hartbrothers.com +3 -3 + this 1208 fix works + + ntpd/ntp_config.c@1.194, 2009-06-03 01:35:00+00:00, davehart@shiny.ad.hartbrothers.com +10 -32 + [Bug 1211] keysdir free()d twice #ifdef DEBUG + + ports/winnt/ntpd/ntservice.c@1.17, 2009-06-03 01:35:00+00:00, davehart@shiny.ad.hartbrothers.com +23 -10 + turn on more heap checking on Windows DEBUG build + +ChangeSet@1.1877.1.1, 2009-06-02 22:04:37+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1208] decodenetnum() buffer overrun on [ with no ] + + ChangeLog@1.340.1.1, 2009-06-02 22:04:36+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1208] decodenetnum() buffer overrun on [ with no ] + + libntp/decodenetnum.c@1.7, 2009-06-02 22:04:36+00:00, davehart@shiny.ad.hartbrothers.com +17 -11 + [Bug 1208] decodenetnum() buffer overrun on [ with no ] + +ChangeSet@1.1878, 2009-06-01 08:52:39-04:00, mayer@pogo.udel.edu +2 -0 + [Bug 1206] Required compiler changes for Windows + + ChangeLog@1.341, 2009-06-01 08:52:22-04:00, mayer@pogo.udel.edu +1 -0 + [Bug 1206] Required compiler changes for Windows + + ports/winnt/libntp/libntp.dsp@1.34, 2009-06-01 08:51:10-04:00, mayer@pogo.udel.edu +8 -12 + [Bug 1206] Required compiler changes for Windows + +ChangeSet@1.1877, 2009-05-29 07:54:39-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P180 + TAG: NTP_4_2_5P180 + + ChangeLog@1.340, 2009-05-29 07:54:08-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P180 + + gsoc_sntp/sntp-opts.c@1.41, 2009-05-29 07:54:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P180 + + gsoc_sntp/sntp-opts.h@1.41, 2009-05-29 07:54:09-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P180 + + gsoc_sntp/sntp-opts.texi@1.41, 2009-05-29 07:54:10-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P180 + + gsoc_sntp/sntp.1@1.41, 2009-05-29 07:54:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P180 + + ntpd/ntpd-opts.c@1.172, 2009-05-29 07:54:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P180 + + ntpd/ntpd-opts.h@1.172, 2009-05-29 07:54:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P180 + + ntpd/ntpd-opts.texi@1.171, 2009-05-29 07:54:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P180 + + ntpd/ntpd.1@1.171, 2009-05-29 07:54:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P180 + + ntpdc/ntpdc-opts.c@1.168, 2009-05-29 07:54:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P180 + + ntpdc/ntpdc-opts.h@1.168, 2009-05-29 07:54:16-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P180 + + ntpdc/ntpdc-opts.texi@1.167, 2009-05-29 07:54:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P180 + + ntpdc/ntpdc.1@1.167, 2009-05-29 07:54:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P180 + + ntpq/ntpq-opts.c@1.168, 2009-05-29 07:54:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P180 + + ntpq/ntpq-opts.h@1.168, 2009-05-29 07:54:19-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P180 + + ntpq/ntpq-opts.texi@1.167, 2009-05-29 07:54:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P180 + + ntpq/ntpq.1@1.167, 2009-05-29 07:54:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P180 + + ntpsnmpd/ntpsnmpd-opts.c@1.49, 2009-05-29 07:54:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P180 + + ntpsnmpd/ntpsnmpd-opts.h@1.49, 2009-05-29 07:54:23-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P180 + + ntpsnmpd/ntpsnmpd-opts.texi@1.49, 2009-05-29 07:54:24-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P180 + + ntpsnmpd/ntpsnmpd.1@1.49, 2009-05-29 07:54:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P180 + + packageinfo.sh@1.183, 2009-05-29 07:54:26-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P180 + + sntp/sntp-opts.c@1.168, 2009-05-29 07:54:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P180 + + sntp/sntp-opts.h@1.168, 2009-05-29 07:54:27-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P180 + + sntp/sntp-opts.texi@1.167, 2009-05-29 07:54:28-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P180 + + sntp/sntp.1@1.167, 2009-05-29 07:54:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P180 + + util/ntp-keygen-opts.c@1.171, 2009-05-29 07:54:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P180 + + util/ntp-keygen-opts.h@1.171, 2009-05-29 07:54:31-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P180 + + util/ntp-keygen-opts.texi@1.170, 2009-05-29 07:54:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P180 + + util/ntp-keygen.1@1.170, 2009-05-29 07:54:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P180 + +ChangeSet@1.1874.1.1, 2009-05-29 03:50:53-04:00, stenn@whimsy.udel.edu +7 -0 + Lose FLAG_FIXPOLL, from Dave Mills + + ChangeLog@1.337.1.1, 2009-05-29 03:49:47-04:00, stenn@whimsy.udel.edu +1 -0 + Lose FLAG_FIXPOLL, from Dave Mills + + include/ntp.h@1.155.1.1, 2009-05-29 03:49:23-04:00, stenn@whimsy.udel.edu +3 -4 + Lose FLAG_FIXPOLL, from Dave Mills + + ntpd/ntp_config.c@1.193, 2009-05-29 03:48:45-04:00, stenn@whimsy.udel.edu +2 -2 + Lose FLAG_FIXPOLL, from Dave Mills + + ntpd/ntp_peer.c@1.119, 2009-05-29 03:48:49-04:00, stenn@whimsy.udel.edu +20 -3 + Lose FLAG_FIXPOLL, from Dave Mills + + ntpd/ntp_proto.c@1.287, 2009-05-29 03:48:50-04:00, stenn@whimsy.udel.edu +1 -2 + Lose FLAG_FIXPOLL, from Dave Mills + + ntpd/ntp_refclock.c@1.87, 2009-05-29 03:48:52-04:00, stenn@whimsy.udel.edu +1 -1 + Lose FLAG_FIXPOLL, from Dave Mills + + ntpd/refclock_acts.c@1.35, 2009-05-29 03:48:58-04:00, stenn@whimsy.udel.edu +0 -1 + Lose FLAG_FIXPOLL, from Dave Mills + +ChangeSet@1.1875, 2009-05-29 04:29:18+00:00, davehart@shiny.ad.hartbrothers.com +22 -0 + [Bug 1200] Enable IPv6 in Windows port + + ChangeLog@1.338, 2009-05-29 04:29:10+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1200] Enable IPv6 in Windows port + + include/isc/interfaceiter.h@1.4, 2009-05-29 04:29:11+00:00, davehart@shiny.ad.hartbrothers.com +1 -3 + remove unnecessary additions to struct isc_interface, eases + future integration of libisc drops + + include/ntp.h@1.156, 2009-05-29 04:29:10+00:00, davehart@shiny.ad.hartbrothers.com +7 -8 + [Bug 1200] Enable IPv6 in Windows port + remove never used ifindex from struct interface, make phase u_short + instead of u_char, move next to u_short family for better packing + + include/recvbuff.h@1.17, 2009-05-29 04:29:11+00:00, davehart@shiny.ad.hartbrothers.com +4 -5 + [Bug 1200] Enable IPv6 in Windows port + rename Windows-only src_addr_len to recv_srcadr_len to clarify it is + associated with recv_srcadr + remove wsabuff, send/recv routines can safely put it on stack + + libntp/recvbuff.c@1.30, 2009-05-29 04:29:11+00:00, davehart@shiny.ad.hartbrothers.com +0 -5 + recvbuff.wsabuff removal + + ntpd/ntp_io.c@1.286, 2009-05-29 04:29:11+00:00, davehart@shiny.ad.hartbrothers.com +4 -21 + [Bug 1200] Enable IPv6 in Windows port + remove unused ifindex from struct interface + do not initialize unused transmitbuff.c code + + ntpd/ntp_request.c@1.79, 2009-05-29 04:29:11+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + remove unused ifindex from struct interface + + ntpdc/ntpdc.c@1.63, 2009-05-29 04:29:11+00:00, davehart@shiny.ad.hartbrothers.com +9 -1 + [Bug 1200] Enable IPv6 in Windows port + + ntpdc/ntpdc_ops.c@1.57, 2009-05-29 04:29:12+00:00, davehart@shiny.ad.hartbrothers.com +4 -5 + do not display ifindex in ifstats, was always zero and now removed + + ntpq/ntpq.c@1.85, 2009-05-29 04:29:12+00:00, davehart@shiny.ad.hartbrothers.com +13 -4 + [Bug 1200] Enable IPv6 in Windows port + + ports/winnt/include/config.h@1.66, 2009-05-29 04:29:12+00:00, davehart@shiny.ad.hartbrothers.com +39 -14 + [Bug 1200] Enable IPv6 in Windows port + + ports/winnt/include/transmitbuff.h@1.7, 2009-05-29 04:29:12+00:00, davehart@shiny.ad.hartbrothers.com +3 -7 + remove wsabuff, stack allocation is no problem for it + + ports/winnt/include/win32_io.h@1.10, 2009-05-29 04:29:13+00:00, davehart@shiny.ad.hartbrothers.com +3 -1 + prep for future refclock_arc.c support on windows + + ports/winnt/libisc/interfaceiter.c@1.8, 2009-05-29 04:29:13+00:00, davehart@shiny.ad.hartbrothers.com +203 -92 + [Bug 1200] Enable IPv6 in Windows port + + ports/winnt/libisc/net.c@1.8, 2009-05-29 04:29:13+00:00, davehart@shiny.ad.hartbrothers.com +8 -18 + [Bug 1200] Enable IPv6 in Windows port + + ports/winnt/libntp/interfaceiter.c@1.3, 2009-05-29 04:29:13+00:00, davehart@shiny.ad.hartbrothers.com +188 -68 + not used, upstream drop from BIND 9.6.1b1 is baseline for + ports/winnt/libisc/interfaceiter.c + + ports/winnt/libntp/libntp.vcproj@1.6, 2009-05-29 04:29:13+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add ntp_net.h reference + + ports/winnt/libntp/transmitbuff.c@1.8, 2009-05-29 04:29:13+00:00, davehart@shiny.ad.hartbrothers.com +10 -6 + remove wsabuf initialization, note the code is dead in top comment + + ports/winnt/ntpd/nt_clockstuff.c@1.30, 2009-05-29 04:29:13+00:00, davehart@shiny.ad.hartbrothers.com +16 -1 + complain on DEBUG builds if hardcoded SIZEOF_ macros are wrong + + ports/winnt/ntpd/ntp_iocompletionport.c@1.42, 2009-05-29 04:29:14+00:00, davehart@shiny.ad.hartbrothers.com +86 -79 + [Bug 1200] Enable IPv6 on Windows + remove wsabuf from transmitbuff_t, recvbuff + + ports/winnt/ntpd/ntpd.vcproj@1.6, 2009-05-29 04:29:14+00:00, davehart@shiny.ad.hartbrothers.com +8 -1 + add ntp_signd.c, ntp_net.h references + + ports/winnt/ntpdate/ntpdate.vcproj@1.3, 2009-05-29 04:29:14+00:00, davehart@shiny.ad.hartbrothers.com +52 -0 + add a bunch of missing header references (not all by far though) + +ChangeSet@1.1874, 2009-05-23 07:55:15-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P179 + TAG: NTP_4_2_5P179 + + ChangeLog@1.337, 2009-05-23 07:54:45-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P179 + + gsoc_sntp/sntp-opts.c@1.40, 2009-05-23 07:54:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P179 + + gsoc_sntp/sntp-opts.h@1.40, 2009-05-23 07:54:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P179 + + gsoc_sntp/sntp-opts.texi@1.40, 2009-05-23 07:54:48-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P179 + + gsoc_sntp/sntp.1@1.40, 2009-05-23 07:54:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P179 + + ntpd/ntpd-opts.c@1.171, 2009-05-23 07:54:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P179 + + ntpd/ntpd-opts.h@1.171, 2009-05-23 07:54:50-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P179 + + ntpd/ntpd-opts.texi@1.170, 2009-05-23 07:54:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P179 + + ntpd/ntpd.1@1.170, 2009-05-23 07:54:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P179 + + ntpdc/ntpdc-opts.c@1.167, 2009-05-23 07:54:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P179 + + ntpdc/ntpdc-opts.h@1.167, 2009-05-23 07:54:54-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P179 + + ntpdc/ntpdc-opts.texi@1.166, 2009-05-23 07:54:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P179 + + ntpdc/ntpdc.1@1.166, 2009-05-23 07:54:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P179 + + ntpq/ntpq-opts.c@1.167, 2009-05-23 07:54:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P179 + + ntpq/ntpq-opts.h@1.167, 2009-05-23 07:54:57-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P179 + + ntpq/ntpq-opts.texi@1.166, 2009-05-23 07:54:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P179 + + ntpq/ntpq.1@1.166, 2009-05-23 07:54:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P179 + + ntpsnmpd/ntpsnmpd-opts.c@1.48, 2009-05-23 07:55:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P179 + + ntpsnmpd/ntpsnmpd-opts.h@1.48, 2009-05-23 07:55:01-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P179 + + ntpsnmpd/ntpsnmpd-opts.texi@1.48, 2009-05-23 07:55:02-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P179 + + ntpsnmpd/ntpsnmpd.1@1.48, 2009-05-23 07:55:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P179 + + packageinfo.sh@1.182, 2009-05-23 07:55:03-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P179 + + sntp/sntp-opts.c@1.167, 2009-05-23 07:55:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P179 + + sntp/sntp-opts.h@1.167, 2009-05-23 07:55:05-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P179 + + sntp/sntp-opts.texi@1.166, 2009-05-23 07:55:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P179 + + sntp/sntp.1@1.166, 2009-05-23 07:55:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P179 + + util/ntp-keygen-opts.c@1.170, 2009-05-23 07:55:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P179 + + util/ntp-keygen-opts.h@1.170, 2009-05-23 07:55:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P179 + + util/ntp-keygen-opts.texi@1.169, 2009-05-23 07:55:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P179 + + util/ntp-keygen.1@1.169, 2009-05-23 07:55:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P179 + +ChangeSet@1.1871.1.1, 2009-05-22 22:13:36-04:00, stenn@whimsy.udel.edu +1 -0 + Dave's latest change fixes a reported bug - update the ChangeLog + + ChangeLog@1.334.1.1, 2009-05-22 22:13:20-04:00, stenn@whimsy.udel.edu +3 -2 + Dave's latest change fixes a reported bug - update the ChangeLog + +ChangeSet@1.1872, 2009-05-23 02:02:18+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + Bug [1041] manycastclient fails with 4.2.5p120. + (fixed by Dave Mills' prior delta to ntp_peer.c xmt -> aorg) + Bug [1196] VC6 winsock2.h does not define SO_EXLUSIVEADDRUSE. + + + ChangeLog@1.335, 2009-05-23 02:02:15+00:00, davehart@shiny.ad.hartbrothers.com +3 -1 + Bug [1041] manycastclient fails with 4.2.5p120. + Bug [1196] VC6 winsock2.h does not define SO_EXLUSIVEADDRUSE. + + + ntpd/ntp_io.c@1.285, 2009-05-23 02:02:15+00:00, davehart@shiny.ad.hartbrothers.com +17 -6 + disambiguate two identical DPRINTFs in findbcastinter() + + ports/winnt/include/config.h@1.65, 2009-05-23 02:02:16+00:00, davehart@shiny.ad.hartbrothers.com +7 -0 + Bug [1196] VC6 winsock2.h does not define SO_EXLUSIVEADDRUSE. + + +ChangeSet@1.1869.1.1, 2009-05-22 21:16:18-04:00, stenn@whimsy.udel.edu +4 -0 + xmt/aorg and leap_expire fixes from Dave Mills + + ChangeLog@1.332.1.2, 2009-05-22 21:13:40-04:00, stenn@whimsy.udel.edu +1 -0 + xmt -> aorg timestamp cleanup from Dave Mills, reported by Dave Hart + + ChangeLog@1.332.1.1, 2009-05-22 21:11:12-04:00, stenn@whimsy.udel.edu +1 -0 + Leap/expire cleanup from Dave Mills + + ntpd/ntp_crypto.c@1.136, 2009-05-22 21:11:15-04:00, stenn@whimsy.udel.edu +1 -0 + Leap/expire cleanup from Dave Mills + + ntpd/ntp_peer.c@1.118, 2009-05-22 21:13:12-04:00, stenn@whimsy.udel.edu +1 -1 + xmt -> aorg timestamp cleanup from Dave Mills, reported by Dave Hart + + ntpd/ntp_proto.c@1.286, 2009-05-22 21:13:13-04:00, stenn@whimsy.udel.edu +7 -6 + xmt -> aorg timestamp cleanup from Dave Mills, reported by Dave Hart + +ChangeSet@1.1870, 2009-05-21 18:34:36+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1193] Compile error: conflicting types for emalloc + + ChangeLog@1.333, 2009-05-21 18:34:34+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1193] Compile error: conflicting types for emalloc + + libntp/emalloc.c@1.8, 2009-05-21 18:34:34+00:00, davehart@shiny.ad.hartbrothers.com +3 -3 + [Bug 1193] correct emalloc arg type from u_int -> size_t to match header + correct printf format specifier mismatch of %d (int) and strlen (size_t) + +ChangeSet@1.1869, 2009-05-21 07:54:56-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P178 + TAG: NTP_4_2_5P178 + + ChangeLog@1.332, 2009-05-21 07:54:29-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P178 + + gsoc_sntp/sntp-opts.c@1.39, 2009-05-21 07:54:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P178 + + gsoc_sntp/sntp-opts.h@1.39, 2009-05-21 07:54:31-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P178 + + gsoc_sntp/sntp-opts.texi@1.39, 2009-05-21 07:54:32-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P178 + + gsoc_sntp/sntp.1@1.39, 2009-05-21 07:54:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P178 + + ntpd/ntpd-opts.c@1.170, 2009-05-21 07:54:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P178 + + ntpd/ntpd-opts.h@1.170, 2009-05-21 07:54:34-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P178 + + ntpd/ntpd-opts.texi@1.169, 2009-05-21 07:54:34-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P178 + + ntpd/ntpd.1@1.169, 2009-05-21 07:54:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P178 + + ntpdc/ntpdc-opts.c@1.166, 2009-05-21 07:54:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P178 + + ntpdc/ntpdc-opts.h@1.166, 2009-05-21 07:54:37-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P178 + + ntpdc/ntpdc-opts.texi@1.165, 2009-05-21 07:54:37-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P178 + + ntpdc/ntpdc.1@1.165, 2009-05-21 07:54:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P178 + + ntpq/ntpq-opts.c@1.166, 2009-05-21 07:54:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P178 + + ntpq/ntpq-opts.h@1.166, 2009-05-21 07:54:40-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P178 + + ntpq/ntpq-opts.texi@1.165, 2009-05-21 07:54:41-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P178 + + ntpq/ntpq.1@1.165, 2009-05-21 07:54:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P178 + + ntpsnmpd/ntpsnmpd-opts.c@1.47, 2009-05-21 07:54:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P178 + + ntpsnmpd/ntpsnmpd-opts.h@1.47, 2009-05-21 07:54:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P178 + + ntpsnmpd/ntpsnmpd-opts.texi@1.47, 2009-05-21 07:54:44-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P178 + + ntpsnmpd/ntpsnmpd.1@1.47, 2009-05-21 07:54:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P178 + + packageinfo.sh@1.181, 2009-05-21 07:54:45-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P178 + + sntp/sntp-opts.c@1.166, 2009-05-21 07:54:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P178 + + sntp/sntp-opts.h@1.166, 2009-05-21 07:54:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P178 + + sntp/sntp-opts.texi@1.165, 2009-05-21 07:54:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P178 + + sntp/sntp.1@1.165, 2009-05-21 07:54:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P178 + + util/ntp-keygen-opts.c@1.169, 2009-05-21 07:54:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P178 + + util/ntp-keygen-opts.h@1.169, 2009-05-21 07:54:50-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P178 + + util/ntp-keygen-opts.texi@1.168, 2009-05-21 07:54:51-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P178 + + util/ntp-keygen.1@1.168, 2009-05-21 07:54:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P178 + +ChangeSet@1.1868, 2009-05-21 03:03:04-04:00, stenn@whimsy.udel.edu +1 -0 + Note fixes for bugs 320 and 1192, and erealloc() and estrdup(), along with better config parser error messages. + + ChangeLog@1.331, 2009-05-21 03:02:43-04:00, stenn@whimsy.udel.edu +4 -0 + Note fixes for bugs 320 and 1192, and erealloc() and estrdup(), along with better config parser error messages. + +ChangeSet@1.1867, 2009-05-21 05:30:18+00:00, davehart@shiny.ad.hartbrothers.com +19 -0 + [Bug 320] restrict default should apply to both IPv4 and IPv6 + [Bug 1192] restrict -4 default / restrict -6 default lost with new + ntp.conf parser. + Dynamically allocate Windows serial handles array to save 1KB static + show column of syntax errors as well as line + add erealloc(), estrdup() + save column number at start of each token for more precise syntax + error messages + + include/ntp_calendar.h@1.4, 2009-05-21 05:30:12+00:00, davehart@shiny.ad.hartbrothers.com +13 -13 + whitespace cleanup, parenthesize macro arg + + include/ntp_config.h@1.52, 2009-05-21 05:30:12+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + whitespace + + include/ntp_filegen.h@1.6, 2009-05-21 05:30:12+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + changed prototype for filegen_unregister() + + include/ntp_stdlib.h@1.29, 2009-05-21 05:30:12+00:00, davehart@shiny.ad.hartbrothers.com +10 -5 + add erealloc(), estrdup() + + include/ntp_types.h@1.12, 2009-05-21 05:30:12+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + add COUNTOF(array) macro + + include/ntpd.h@1.127, 2009-05-21 05:30:12+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + add comment that fstostr time_t arg isn't a typical time_t + + libntp/emalloc.c@1.7, 2009-05-21 05:30:12+00:00, davehart@shiny.ad.hartbrothers.com +75 -14 + add erealloc(), estrdup() + + libntp/ntp_lineedit.c@1.6, 2009-05-21 05:30:12+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + strdup() -> estrdup() + + ntpd/ntp_config.c@1.192, 2009-05-21 05:30:13+00:00, davehart@shiny.ad.hartbrothers.com +310 -244 + [Bug 320] restrict default should apply to both IPv4 and IPv6 + [Bug 1192] restrict -4 default / restrict -6 default lost with new + ntp.conf parser. + Remove unnecessary casts, use sizeof(*ptr) instead of sizeof(ptr_type) + change switch/case indents to NTP style + wrap long lines, remove unneeded casts, silence uninit warning + strdup() -> estrdup() + + ntpd/ntp_filegen.c@1.15, 2009-05-21 05:30:13+00:00, davehart@shiny.ad.hartbrothers.com +226 -194 + free more malloc()'d memory at shutdown #ifdef DEBUG + whitespace cleanup, wrap long lines + remove unnecessary casts + sprintf()->snprintf() + constants on left side of == to catch accidental change to =, and put + more informative item first + '/' -> DIR_SEP + restore DPRINTF()s that gave Alpha compiler fits by using %p printf format + + ntpd/ntp_parser.c@1.38, 2009-05-21 05:30:13+00:00, davehart@shiny.ad.hartbrothers.com +1000 -955 + Bison output from ntp_parser.y + + + ntpd/ntp_parser.h@1.22, 2009-05-21 05:30:14+00:00, davehart@shiny.ad.hartbrothers.com +225 -225 + Bison output from ntp_parser.y + + + ntpd/ntp_parser.y@1.33, 2009-05-21 05:30:14+00:00, davehart@shiny.ad.hartbrothers.com +50 -22 + [Bug 1192] restrict -4 default / restrict -6 default lost with new + ntp.conf parser. + correct else block indent in include processing code + remove unwanted \n from end of msyslog() in yyerror() + strdup() -> estrdup() + display line and column numbers in syntax error messages + save column number at start of each token for more precise syntax + error messages + + ntpd/ntp_scanner.c@1.21, 2009-05-21 05:30:14+00:00, davehart@shiny.ad.hartbrothers.com +110 -118 + strdup() -> estrdup() + first line number is one not zero + save column number at start of each token for more precise syntax + error messages + clarify reason for -4/-6 hack in yylex() comment + + ntpd/ntp_scanner.h@1.6, 2009-05-21 05:30:14+00:00, davehart@shiny.ad.hartbrothers.com +16 -13 + save column number at start of each token for more precise syntax + error messages + whitespace cleanup + + ntpd/ntp_util.c@1.71, 2009-05-21 05:30:15+00:00, davehart@shiny.ad.hartbrothers.com +42 -52 + free() then emalloc() becomes erealloc() + thin #ifdef forest + + ports/winnt/include/win32_io.h@1.9, 2009-05-21 05:30:15+00:00, davehart@shiny.ad.hartbrothers.com +95 -85 + whitespace and indent cleanup + stay out of system namespace (leading _) + + ports/winnt/ntpd/nt_clockstuff.c@1.29, 2009-05-21 05:30:15+00:00, davehart@shiny.ad.hartbrothers.com +0 -3 + COUNTOF() macro moved to ntp_types.h + + ports/winnt/ntpd/win32_io.c@1.17, 2009-05-21 05:30:15+00:00, davehart@shiny.ad.hartbrothers.com +420 -202 + dynamically allocate serial handles array (saves 1 KB static) + change switch/case intents to NTP style + add TIOCMGET tty ioctl emulation, improve TIOCMSET emulation + correct tcsetattr() & tcgetattr() return values + remove superfluous NT_COM: prefix from error texts + +ChangeSet@1.1866, 2009-05-18 08:14:01-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P177 + TAG: NTP_4_2_5P177 + + ChangeLog@1.330, 2009-05-18 08:13:31-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P177 + + gsoc_sntp/sntp-opts.c@1.38, 2009-05-18 08:13:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P177 + + gsoc_sntp/sntp-opts.h@1.38, 2009-05-18 08:13:34-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P177 + + gsoc_sntp/sntp-opts.texi@1.38, 2009-05-18 08:13:34-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P177 + + gsoc_sntp/sntp.1@1.38, 2009-05-18 08:13:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P177 + + ntpd/ntpd-opts.c@1.169, 2009-05-18 08:13:37-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P177 + + ntpd/ntpd-opts.h@1.169, 2009-05-18 08:13:38-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P177 + + ntpd/ntpd-opts.texi@1.168, 2009-05-18 08:13:39-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P177 + + ntpd/ntpd.1@1.168, 2009-05-18 08:13:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P177 + + ntpdc/ntpdc-opts.c@1.165, 2009-05-18 08:13:40-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P177 + + ntpdc/ntpdc-opts.h@1.165, 2009-05-18 08:13:41-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P177 + + ntpdc/ntpdc-opts.texi@1.164, 2009-05-18 08:13:42-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P177 + + ntpdc/ntpdc.1@1.164, 2009-05-18 08:13:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P177 + + ntpq/ntpq-opts.c@1.165, 2009-05-18 08:13:44-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P177 + + ntpq/ntpq-opts.h@1.165, 2009-05-18 08:13:45-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P177 + + ntpq/ntpq-opts.texi@1.164, 2009-05-18 08:13:46-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P177 + + ntpq/ntpq.1@1.164, 2009-05-18 08:13:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P177 + + ntpsnmpd/ntpsnmpd-opts.c@1.46, 2009-05-18 08:13:47-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P177 + + ntpsnmpd/ntpsnmpd-opts.h@1.46, 2009-05-18 08:13:48-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P177 + + ntpsnmpd/ntpsnmpd-opts.texi@1.46, 2009-05-18 08:13:49-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P177 + + ntpsnmpd/ntpsnmpd.1@1.46, 2009-05-18 08:13:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P177 + + packageinfo.sh@1.180, 2009-05-18 08:13:50-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P177 + + sntp/sntp-opts.c@1.165, 2009-05-18 08:13:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P177 + + sntp/sntp-opts.h@1.165, 2009-05-18 08:13:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P177 + + sntp/sntp-opts.texi@1.164, 2009-05-18 08:13:52-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P177 + + sntp/sntp.1@1.164, 2009-05-18 08:13:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P177 + + util/ntp-keygen-opts.c@1.168, 2009-05-18 08:13:54-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P177 + + util/ntp-keygen-opts.h@1.168, 2009-05-18 08:13:55-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P177 + + util/ntp-keygen-opts.texi@1.167, 2009-05-18 08:13:55-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P177 + + util/ntp-keygen.1@1.167, 2009-05-18 08:13:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P177 + +ChangeSet@1.1436.15.70, 2009-05-18 05:04:41-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_4P7 + TAG: NTP_4_2_4P7 + + ChangeLog@1.1.1.90, 2009-05-18 05:04:18-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_4P7 + + ntpd/ntpd-opts.c@1.50.25.1, 2009-05-18 05:04:19-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P7 + + ntpd/ntpd-opts.h@1.50.25.1, 2009-05-18 05:04:20-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P7 + + ntpd/ntpd-opts.texi@1.49.25.1, 2009-05-18 05:04:21-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7 + + ntpd/ntpd.1@1.48.25.1, 2009-05-18 05:04:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7 + + ntpd/ntpdsim-opts.c@1.50.25.1, 2009-05-18 05:04:22-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P7 + + ntpd/ntpdsim-opts.h@1.50.25.1, 2009-05-18 05:04:23-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P7 + + ntpd/ntpdsim-opts.texi@1.48.25.1, 2009-05-18 05:04:24-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7 + + ntpd/ntpdsim.1@1.48.25.1, 2009-05-18 05:04:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7 + + ntpdc/ntpdc-opts.c@1.50.25.1, 2009-05-18 05:04:26-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P7 + + ntpdc/ntpdc-opts.h@1.50.25.1, 2009-05-18 05:04:26-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P7 + + ntpdc/ntpdc-opts.texi@1.48.25.1, 2009-05-18 05:04:27-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7 + + ntpdc/ntpdc.1@1.48.25.1, 2009-05-18 05:04:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7 + + ntpq/ntpq-opts.c@1.52.25.1, 2009-05-18 05:04:29-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P7 + + ntpq/ntpq-opts.h@1.52.25.1, 2009-05-18 05:04:29-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P7 + + ntpq/ntpq-opts.texi@1.49.25.1, 2009-05-18 05:04:30-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7 + + ntpq/ntpq.1@1.48.25.1, 2009-05-18 05:04:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7 + + packageinfo.sh@1.65.33.2, 2009-05-18 05:04:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7 + + sntp/sntp-opts.c@1.49.25.1, 2009-05-18 05:04:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7 + + sntp/sntp-opts.h@1.49.25.1, 2009-05-18 05:04:33-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7 + + sntp/sntp-opts.texi@1.46.25.1, 2009-05-18 05:04:34-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7 + + sntp/sntp.1@1.49.25.1, 2009-05-18 05:04:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7 + + util/ntp-keygen-opts.c@1.49.25.1, 2009-05-18 05:04:35-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P7 + + util/ntp-keygen-opts.h@1.49.25.1, 2009-05-18 05:04:36-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P7 + + util/ntp-keygen-opts.texi@1.47.25.1, 2009-05-18 05:04:37-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7 + + util/ntp-keygen.1@1.47.25.1, 2009-05-18 05:04:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7 + +ChangeSet@1.1436.15.69, 2009-05-18 03:14:59-04:00, stenn@whimsy.udel.edu +2 -0 + 4.2.4p7 + + NEWS@1.86.1.15, 2009-05-18 03:14:49-04:00, stenn@whimsy.udel.edu +38 -0 + 4.2.4p7 + + packageinfo.sh@1.65.33.1, 2009-05-18 03:14:50-04:00, stenn@whimsy.udel.edu +1 -1 + 4.2.4p7 + +ChangeSet@1.1436.15.68, 2009-05-18 02:56:36-04:00, stenn@whimsy.udel.edu +2 -0 + [Sec 1151] Remote exploit if autokey is enabled - CVE-2009-1252 + + ChangeLog@1.1.1.89, 2009-05-18 02:56:22-04:00, stenn@whimsy.udel.edu +1 -0 + [Sec 1151] Remote exploit if autokey is enabled - CVE-2009-1252 + + ntpd/ntp_crypto.c@1.107.1.3, 2009-05-18 02:56:22-04:00, stenn@whimsy.udel.edu +22 -17 + [Sec 1151] Remote exploit if autokey is enabled - CVE-2009-1252 + +ChangeSet@1.1436.15.67, 2009-05-18 02:24:31-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1187] Update the copyright date. + + ChangeLog@1.1.1.88, 2009-05-18 02:24:21-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1187] Update the copyright date. + + include/copyright.def@1.5.1.3, 2009-05-18 02:24:22-04:00, stenn@whimsy.udel.edu +1 -1 + [Bug 1187] Update the copyright date. + +ChangeSet@1.1436.15.66, 2009-05-17 08:59:06+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1191] ntpd fails on Win2000 - "Address already in use" after fix + for [Sec 1149]. + + ChangeLog@1.1.1.87, 2009-05-17 08:59:05+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + [Bug 1191] ntpd fails on Win2000 - "Address already in use" after fix + for [Sec 1149]. + + ntpd/ntp_io.c@1.244.2.17, 2009-05-17 08:59:05+00:00, davehart@shiny.ad.hartbrothers.com +45 -34 + [Bug 1191] ntpd fails on Win2000 - "Address already in use" after fix + for [Sec 1149]. + +ChangeSet@1.1860.1.2, 2009-05-15 19:54:46+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1174] nmea_shutdown assumes that nmea has a unit assigned + + ChangeLog@1.325.1.2, 2009-05-15 19:54:45+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1174] nmea_shutdown assumes that nmea has a unit assigned + + ntpd/refclock_nmea.c@1.37, 2009-05-15 19:54:45+00:00, davehart@shiny.ad.hartbrothers.com +6 -2 + [Bug 1174] nmea_shutdown assumes that nmea has a unit assigned + +ChangeSet@1.1860.1.1, 2009-05-15 19:37:17+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1190] NMEA refclock fudge flag4 1 obscures position in timecode + Update NMEA documentation for a number of changes over the last year + + ChangeLog@1.325.1.1, 2009-05-15 19:37:15+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1190] NMEA refclock fudge flag4 1 obscures position in timecode + Update NMEA documentation for a number of changes over the last year + + html/drivers/driver20.html@1.18, 2009-05-15 19:37:15+00:00, davehart@shiny.ad.hartbrothers.com +18 -21 + Update NMEA documentation for a number of changes over the last year + + ntpd/refclock_nmea.c@1.36, 2009-05-15 19:37:15+00:00, davehart@shiny.ad.hartbrothers.com +89 -13 + [Bug 1190] NMEA refclock fudge flag4 1 obscures position in timecode + +ChangeSet@1.1436.15.65, 2009-05-14 04:42:10+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + fix error from BitKeeper/triggers/pre-resolve.licfix triggered (ahem) + by recent BitKeeper/etc/config delta updating repologs email address + + BitKeeper/triggers/pre-resolve.licfix@1.5, 2009-05-14 04:42:09+00:00, davehart@shiny.ad.hartbrothers.com +4 -1 + bk sccscat has been removed, replaced by bk annotate -R + -q grep -> grep -q (untested until recent BitKeeper/etc/config commit + changing repologs@ntp.isc.org to repologs@ntp.org + +ChangeSet@1.1861, 2009-05-14 01:33:16+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ChangeLog: + remove duplicate [Bug 1154] entry from failed first fix + + ChangeLog@1.326, 2009-05-14 01:33:10+00:00, davehart@shiny.ad.hartbrothers.com +0 -2 + remove duplicate [Bug 1154] entry from failed first fix + +ChangeSet@1.1860, 2009-05-13 07:54:55-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P176 + TAG: NTP_4_2_5P176 + + ChangeLog@1.325, 2009-05-13 07:54:25-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P176 + + gsoc_sntp/sntp-opts.c@1.37, 2009-05-13 07:54:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P176 + + gsoc_sntp/sntp-opts.h@1.37, 2009-05-13 07:54:27-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P176 + + gsoc_sntp/sntp-opts.texi@1.37, 2009-05-13 07:54:28-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P176 + + gsoc_sntp/sntp.1@1.37, 2009-05-13 07:54:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P176 + + ntpd/ntpd-opts.c@1.168, 2009-05-13 07:54:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P176 + + ntpd/ntpd-opts.h@1.168, 2009-05-13 07:54:31-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P176 + + ntpd/ntpd-opts.texi@1.167, 2009-05-13 07:54:31-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P176 + + ntpd/ntpd.1@1.167, 2009-05-13 07:54:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P176 + + ntpdc/ntpdc-opts.c@1.164, 2009-05-13 07:54:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P176 + + ntpdc/ntpdc-opts.h@1.164, 2009-05-13 07:54:34-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P176 + + ntpdc/ntpdc-opts.texi@1.163, 2009-05-13 07:54:35-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P176 + + ntpdc/ntpdc.1@1.163, 2009-05-13 07:54:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P176 + + ntpq/ntpq-opts.c@1.164, 2009-05-13 07:54:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P176 + + ntpq/ntpq-opts.h@1.164, 2009-05-13 07:54:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P176 + + ntpq/ntpq-opts.texi@1.163, 2009-05-13 07:54:39-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P176 + + ntpq/ntpq.1@1.163, 2009-05-13 07:54:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P176 + + ntpsnmpd/ntpsnmpd-opts.c@1.45, 2009-05-13 07:54:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P176 + + ntpsnmpd/ntpsnmpd-opts.h@1.45, 2009-05-13 07:54:42-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P176 + + ntpsnmpd/ntpsnmpd-opts.texi@1.45, 2009-05-13 07:54:43-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P176 + + ntpsnmpd/ntpsnmpd.1@1.45, 2009-05-13 07:54:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P176 + + packageinfo.sh@1.179, 2009-05-13 07:54:45-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P176 + + sntp/sntp-opts.c@1.164, 2009-05-13 07:54:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P176 + + sntp/sntp-opts.h@1.164, 2009-05-13 07:54:46-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P176 + + sntp/sntp-opts.texi@1.163, 2009-05-13 07:54:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P176 + + sntp/sntp.1@1.163, 2009-05-13 07:54:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P176 + + util/ntp-keygen-opts.c@1.167, 2009-05-13 07:54:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P176 + + util/ntp-keygen-opts.h@1.167, 2009-05-13 07:54:50-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P176 + + util/ntp-keygen-opts.texi@1.166, 2009-05-13 07:54:50-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P176 + + util/ntp-keygen.1@1.166, 2009-05-13 07:54:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P176 + +ChangeSet@1.1845.6.2, 2009-05-12 08:57:55-04:00, utterback@pogo.udel.edu +1 -0 + ntpd.c: + [Bug 1154] mDNS registration should be done later, repeatedly and only if asked for. + + ntpd/ntpd.c@1.100.1.1, 2009-05-12 08:57:20-04:00, utterback@pogo.udel.edu +29 -7 + [Bug 1154] mDNS registration should be done later, repeatedly and only if asked for. + +ChangeSet@1.1845.6.1, 2009-05-12 08:51:48-04:00, utterback@pogo.udel.edu +1 -0 + ChangeLog: + [Bug 1154] mDNS registration should be done later, repeatedly and only if asked for. + + ChangeLog@1.310.5.1, 2009-05-12 08:42:51-04:00, utterback@pogo.udel.edu +2 -0 + [Bug 1154] mDNS registration should be done later, repeatedly and only if asked for. + +ChangeSet@1.1858, 2009-05-12 08:07:45-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P175 + TAG: NTP_4_2_5P175 + + ChangeLog@1.323, 2009-05-12 08:07:16-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P175 + + gsoc_sntp/sntp-opts.c@1.36, 2009-05-12 08:07:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P175 + + gsoc_sntp/sntp-opts.h@1.36, 2009-05-12 08:07:18-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P175 + + gsoc_sntp/sntp-opts.texi@1.36, 2009-05-12 08:07:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P175 + + gsoc_sntp/sntp.1@1.36, 2009-05-12 08:07:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P175 + + ntpd/ntpd-opts.c@1.167, 2009-05-12 08:07:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P175 + + ntpd/ntpd-opts.h@1.167, 2009-05-12 08:07:21-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P175 + + ntpd/ntpd-opts.texi@1.166, 2009-05-12 08:07:22-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P175 + + ntpd/ntpd.1@1.166, 2009-05-12 08:07:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P175 + + ntpdc/ntpdc-opts.c@1.163, 2009-05-12 08:07:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P175 + + ntpdc/ntpdc-opts.h@1.163, 2009-05-12 08:07:25-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P175 + + ntpdc/ntpdc-opts.texi@1.162, 2009-05-12 08:07:25-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P175 + + ntpdc/ntpdc.1@1.162, 2009-05-12 08:07:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P175 + + ntpq/ntpq-opts.c@1.163, 2009-05-12 08:07:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P175 + + ntpq/ntpq-opts.h@1.163, 2009-05-12 08:07:27-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P175 + + ntpq/ntpq-opts.texi@1.162, 2009-05-12 08:07:28-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P175 + + ntpq/ntpq.1@1.162, 2009-05-12 08:07:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P175 + + ntpsnmpd/ntpsnmpd-opts.c@1.44, 2009-05-12 08:07:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P175 + + ntpsnmpd/ntpsnmpd-opts.h@1.44, 2009-05-12 08:07:30-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P175 + + ntpsnmpd/ntpsnmpd-opts.texi@1.44, 2009-05-12 08:07:31-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P175 + + ntpsnmpd/ntpsnmpd.1@1.44, 2009-05-12 08:07:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P175 + + packageinfo.sh@1.178, 2009-05-12 08:07:33-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P175 + + sntp/sntp-opts.c@1.163, 2009-05-12 08:07:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P175 + + sntp/sntp-opts.h@1.163, 2009-05-12 08:07:34-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P175 + + sntp/sntp-opts.texi@1.162, 2009-05-12 08:07:36-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P175 + + sntp/sntp.1@1.162, 2009-05-12 08:07:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P175 + + util/ntp-keygen-opts.c@1.166, 2009-05-12 08:07:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P175 + + util/ntp-keygen-opts.h@1.166, 2009-05-12 08:07:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P175 + + util/ntp-keygen-opts.texi@1.165, 2009-05-12 08:07:40-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P175 + + util/ntp-keygen.1@1.165, 2009-05-12 08:07:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P175 + +ChangeSet@1.1857, 2009-05-12 05:37:53-04:00, stenn@whimsy.udel.edu +1 -0 + Merge cleanup + + ChangeLog@1.322, 2009-05-12 05:37:42-04:00, stenn@whimsy.udel.edu +1 -0 + Merge cleanup + +ChangeSet@1.1436.15.64, 2009-05-12 02:41:56-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_4P7_RC7 + TAG: NTP_4_2_4P7_RC7 + + ChangeLog@1.1.1.86, 2009-05-12 02:41:33-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_4P7_RC7 + + ntpd/ntpd-opts.c@1.50.24.1, 2009-05-12 02:41:33-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC7 + + ntpd/ntpd-opts.h@1.50.24.1, 2009-05-12 02:41:33-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC7 + + ntpd/ntpd-opts.texi@1.49.24.1, 2009-05-12 02:41:35-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC7 + + ntpd/ntpd.1@1.48.24.1, 2009-05-12 02:41:35-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC7 + + ntpd/ntpdsim-opts.c@1.50.24.1, 2009-05-12 02:41:36-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC7 + + ntpd/ntpdsim-opts.h@1.50.24.1, 2009-05-12 02:41:37-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC7 + + ntpd/ntpdsim-opts.texi@1.48.24.1, 2009-05-12 02:41:37-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC7 + + ntpd/ntpdsim.1@1.48.24.1, 2009-05-12 02:41:38-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC7 + + ntpdc/ntpdc-opts.c@1.50.24.1, 2009-05-12 02:41:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC7 + + ntpdc/ntpdc-opts.h@1.50.24.1, 2009-05-12 02:41:40-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC7 + + ntpdc/ntpdc-opts.texi@1.48.24.1, 2009-05-12 02:41:41-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC7 + + ntpdc/ntpdc.1@1.48.24.1, 2009-05-12 02:41:42-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC7 + + ntpq/ntpq-opts.c@1.52.24.1, 2009-05-12 02:41:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC7 + + ntpq/ntpq-opts.h@1.52.24.1, 2009-05-12 02:41:44-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC7 + + ntpq/ntpq-opts.texi@1.49.24.1, 2009-05-12 02:41:45-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC7 + + ntpq/ntpq.1@1.48.24.1, 2009-05-12 02:41:46-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC7 + + packageinfo.sh@1.65.32.1, 2009-05-12 02:41:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC7 + + sntp/sntp-opts.c@1.49.24.1, 2009-05-12 02:41:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC7 + + sntp/sntp-opts.h@1.49.24.1, 2009-05-12 02:41:48-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC7 + + sntp/sntp-opts.texi@1.46.24.1, 2009-05-12 02:41:49-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC7 + + sntp/sntp.1@1.49.24.1, 2009-05-12 02:41:50-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC7 + + util/ntp-keygen-opts.c@1.49.24.1, 2009-05-12 02:41:51-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC7 + + util/ntp-keygen-opts.h@1.49.24.1, 2009-05-12 02:41:51-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC7 + + util/ntp-keygen-opts.texi@1.47.24.1, 2009-05-12 02:41:52-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC7 + + util/ntp-keygen.1@1.47.24.1, 2009-05-12 02:41:53-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC7 + +ChangeSet@1.1436.15.63, 2009-05-12 01:07:37-04:00, stenn@whimsy.udel.edu +9 -0 + ntp.isc.org -> ntp.org cleanup + + BitKeeper/etc/config@1.10, 2009-05-12 01:06:49-04:00, stenn@whimsy.udel.edu +1 -1 + ntp.isc.org -> ntp.org cleanup + + ChangeLog@1.1.1.85, 2009-05-12 01:06:01-04:00, stenn@whimsy.udel.edu +1 -0 + ntp.isc.org -> ntp.org cleanup + + README@1.22.1.1, 2009-05-12 01:06:02-04:00, stenn@whimsy.udel.edu +1 -1 + ntp.isc.org -> ntp.org cleanup + + README.bk@1.18.1.1, 2009-05-12 01:06:03-04:00, stenn@whimsy.udel.edu +1 -1 + ntp.isc.org -> ntp.org cleanup + + README.patches@1.3.1.1, 2009-05-12 01:06:03-04:00, stenn@whimsy.udel.edu +1 -1 + ntp.isc.org -> ntp.org cleanup + + WHERE-TO-START@1.6.1.1, 2009-05-12 01:06:03-04:00, stenn@whimsy.udel.edu +1 -1 + ntp.isc.org -> ntp.org cleanup + + configure.ac@1.400.1.18, 2009-05-12 01:06:04-04:00, stenn@whimsy.udel.edu +1 -1 + ntp.isc.org -> ntp.org cleanup + + include/copyright.def@1.5.1.2, 2009-05-12 01:06:49-04:00, stenn@whimsy.udel.edu +1 -1 + ntp.isc.org -> ntp.org cleanup + + sntp/sntp-opts.def@1.10.1.1, 2009-05-12 01:06:49-04:00, stenn@whimsy.udel.edu +1 -1 + ntp.isc.org -> ntp.org cleanup + +ChangeSet@1.1845.5.1, 2009-05-11 21:43:27-04:00, stenn@whimsy.udel.edu +4 -0 + [Bug 1182] Documentation typos and missing bits + + ChangeLog@1.310.4.1, 2009-05-11 21:41:59-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1182] Documentation typos and missing bits + + html/accopt.html@1.28, 2009-05-11 21:42:05-04:00, stenn@whimsy.udel.edu +120 -67 + [Bug 1182] Documentation typos and missing bits + + html/decode.html@1.9, 2009-05-11 21:42:07-04:00, stenn@whimsy.udel.edu +37 -25 + [Bug 1182] Documentation typos and missing bits + + html/monopt.html@1.30, 2009-05-11 21:42:10-04:00, stenn@whimsy.udel.edu +511 -457 + [Bug 1182] Documentation typos and missing bits + +ChangeSet@1.1845.4.2, 2009-05-12 00:58:59+00:00, davehart@shiny.ad.hartbrothers.com +9 -0 + [Bug 1183] COM port support should extend past COM3 + + ChangeLog@1.310.3.2, 2009-05-12 00:58:54+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1183] COM port support should extend past COM3 + + libisc/sockaddr.c@1.6, 2009-05-12 00:58:55+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + silence truncation warning + + ntpd/ntp_control.c@1.110, 2009-05-12 00:58:55+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + silence truncation warning + + ntpd/ntp_peer.c@1.117, 2009-05-12 00:58:55+00:00, davehart@shiny.ad.hartbrothers.com +7 -10 + silence truncation warnings, use NULL not 0 for pointers + + ntpd/ntp_refclock.c@1.86, 2009-05-12 00:58:55+00:00, davehart@shiny.ad.hartbrothers.com +57 -81 + [Bug 1183] COM port support should extend past COM3 + silence a few truncation warnings, clean up indents + + ntpd/ntp_scanner.c@1.20, 2009-05-12 00:58:55+00:00, davehart@shiny.ad.hartbrothers.com +0 -1 + remove dead code "return 1" at end of yylex(), silencing warning and + allowing the compiler to catch any future change which revives it, as + then the compiler would error on the missing "return" + + ntpd/ntpd.c@1.101, 2009-05-12 00:58:55+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + fix leading whitespace, correct #endif comment + + ports/winnt/include/config.h@1.62.1.1, 2009-05-12 00:58:56+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + disable CLOCK_DUMBCLOCK on Windows, it needs work first + + ports/winnt/ntpd/win32_io.c@1.16, 2009-05-12 00:58:56+00:00, davehart@shiny.ad.hartbrothers.com +6 -4 + [Bug 1183] COM port support should extend past COM3 + +ChangeSet@1.1845.2.5, 2009-05-11 19:01:24+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1184] ntpd is deaf when restricted to second IP on the same net + + ChangeLog@1.310.2.3, 2009-05-11 19:01:22+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1184] ntpd is deaf when restricted to second IP on the same net + + include/ntp.h@1.155, 2009-05-11 19:01:22+00:00, davehart@shiny.ad.hartbrothers.com +10 -9 + add indents, parentheses to clarify SOCKCMP macro + + ntpd/ntp_io.c@1.283, 2009-05-11 19:01:23+00:00, davehart@shiny.ad.hartbrothers.com +163 -34 + [Bug 1184] ntpd is deaf when restricted to second IP on the same net + +ChangeSet@1.1845.2.4, 2009-05-09 17:54:29+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + configure.ac: + correct config.h comment quoting + + configure.ac@1.441.2.2, 2009-05-09 17:54:27+00:00, davehart@shiny.ad.hartbrothers.com +7 -7 + correct config.h comment quoting, use AS_HELP_STRING + +ChangeSet@1.1845.4.1, 2009-05-09 07:55:25-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P174 + TAG: NTP_4_2_5P174 + + ChangeLog@1.310.3.1, 2009-05-09 07:54:54-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P174 + + gsoc_sntp/sntp-opts.c@1.35, 2009-05-09 07:54:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P174 + + gsoc_sntp/sntp-opts.h@1.35, 2009-05-09 07:54:56-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P174 + + gsoc_sntp/sntp-opts.texi@1.35, 2009-05-09 07:54:57-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P174 + + gsoc_sntp/sntp.1@1.35, 2009-05-09 07:54:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P174 + + ntpd/ntpd-opts.c@1.166, 2009-05-09 07:55:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P174 + + ntpd/ntpd-opts.h@1.166, 2009-05-09 07:55:02-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P174 + + ntpd/ntpd-opts.texi@1.165, 2009-05-09 07:55:02-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P174 + + ntpd/ntpd.1@1.165, 2009-05-09 07:55:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P174 + + ntpdc/ntpdc-opts.c@1.162, 2009-05-09 07:55:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P174 + + ntpdc/ntpdc-opts.h@1.162, 2009-05-09 07:55:05-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P174 + + ntpdc/ntpdc-opts.texi@1.161, 2009-05-09 07:55:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P174 + + ntpdc/ntpdc.1@1.161, 2009-05-09 07:55:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P174 + + ntpq/ntpq-opts.c@1.162, 2009-05-09 07:55:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P174 + + ntpq/ntpq-opts.h@1.162, 2009-05-09 07:55:09-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P174 + + ntpq/ntpq-opts.texi@1.161, 2009-05-09 07:55:10-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P174 + + ntpq/ntpq.1@1.161, 2009-05-09 07:55:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P174 + + ntpsnmpd/ntpsnmpd-opts.c@1.43, 2009-05-09 07:55:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P174 + + ntpsnmpd/ntpsnmpd-opts.h@1.43, 2009-05-09 07:55:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P174 + + ntpsnmpd/ntpsnmpd-opts.texi@1.43, 2009-05-09 07:55:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P174 + + ntpsnmpd/ntpsnmpd.1@1.43, 2009-05-09 07:55:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P174 + + packageinfo.sh@1.177, 2009-05-09 07:55:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P174 + + sntp/sntp-opts.c@1.162, 2009-05-09 07:55:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P174 + + sntp/sntp-opts.h@1.162, 2009-05-09 07:55:16-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P174 + + sntp/sntp-opts.texi@1.161, 2009-05-09 07:55:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P174 + + sntp/sntp.1@1.161, 2009-05-09 07:55:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P174 + + util/ntp-keygen-opts.c@1.165, 2009-05-09 07:55:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P174 + + util/ntp-keygen-opts.h@1.165, 2009-05-09 07:55:19-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P174 + + util/ntp-keygen-opts.texi@1.164, 2009-05-09 07:55:20-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P174 + + util/ntp-keygen.1@1.164, 2009-05-09 07:55:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P174 + +ChangeSet@1.1845.2.3, 2009-05-09 09:00:06+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add --disable-listen-read-drop configure option for machines with more + interfaces than FD_SETSIZE [Bug 1180] + + ChangeLog@1.310.2.2, 2009-05-09 09:00:04+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1180] ntpd won't start with more than ~1000 interfaces + + configure.ac@1.441.2.1, 2009-05-09 09:00:04+00:00, davehart@shiny.ad.hartbrothers.com +18 -0 + add --disable-listen-read-drop configure option for machines with more + interfaces than FD_SETSIZE [Bug 1180] + + ntpd/ntp_io.c@1.282, 2009-05-09 09:00:04+00:00, davehart@shiny.ad.hartbrothers.com +27 -7 + add --disable-listen-read-drop configure option for machines with more + interfaces than FD_SETSIZE [Bug 1180] + + ports/winnt/ntpd/ntpd.vcproj@1.5, 2009-05-09 09:00:04+00:00, davehart@shiny.ad.hartbrothers.com +4 -22 + relocate cmd_args.c from ntpd header files to ntp source code in VS + +ChangeSet@1.1845.3.1, 2009-05-08 22:44:33+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ntp_io.c: + make -I override -L, do not listen on unused interfaces + + ntpd/ntp_io.c@1.281, 2009-05-08 22:44:21+00:00, davehart@shiny.ad.hartbrothers.com +9 -16 + make -I override -L, do not listen on unused interfaces + +ChangeSet@1.1845.2.1, 2009-05-08 17:32:49-04:00, stenn@whimsy.udel.edu +9 -0 + Stale leapsecond file fixes from Dave Mills + + ChangeLog@1.310.2.1, 2009-05-08 17:30:38-04:00, stenn@whimsy.udel.edu +1 -0 + Stale leapsecond file fixes from Dave Mills + + html/decode.html@1.8, 2009-05-08 17:32:34-04:00, stenn@whimsy.udel.edu +844 -683 + Stale leapsecond file fixes from Dave Mills + + include/ntp.h@1.154, 2009-05-08 17:31:10-04:00, stenn@whimsy.udel.edu +4 -0 + Stale leapsecond file fixes from Dave Mills + + include/ntpd.h@1.126, 2009-05-08 17:31:17-04:00, stenn@whimsy.udel.edu +1 -0 + Stale leapsecond file fixes from Dave Mills + + libntp/statestr.c@1.16, 2009-05-08 17:30:56-04:00, stenn@whimsy.udel.edu +3 -0 + Stale leapsecond file fixes from Dave Mills + + ntpd/ntp_control.c@1.109, 2009-05-08 17:31:26-04:00, stenn@whimsy.udel.edu +2 -2 + Stale leapsecond file fixes from Dave Mills + + ntpd/ntp_crypto.c@1.134, 2009-05-08 17:31:27-04:00, stenn@whimsy.udel.edu +8 -1 + Stale leapsecond file fixes from Dave Mills + + ntpd/ntp_timer.c@1.51.1.1, 2009-05-08 17:31:32-04:00, stenn@whimsy.udel.edu +5 -1 + Stale leapsecond file fixes from Dave Mills + + ntpd/ntp_util.c@1.70, 2009-05-08 17:31:33-04:00, stenn@whimsy.udel.edu +33 -7 + Stale leapsecond file fixes from Dave Mills + +ChangeSet@1.1436.23.1, 2009-05-08 18:11:36+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + configure.ac: + correct help text + + configure.ac@1.400.2.1, 2009-05-08 18:11:24+00:00, davehart@shiny.ad.hartbrothers.com +11 -5 + correct help text + +ChangeSet@1.1436.15.61, 2009-05-08 17:50:37+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + add configure --enable-ignore-dns-errors to retry on any failure + + ChangeLog@1.1.1.84, 2009-05-08 17:50:35+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + add configure --enable-ignore-dns-errors to retry on any failure + + configure.ac@1.400.1.16, 2009-05-08 17:50:35+00:00, davehart@shiny.ad.hartbrothers.com +26 -4 + add configure --enable-ignore-dns-errors to retry on any failure + + ntpd/ntp_intres.c@1.48.1.7, 2009-05-08 17:50:35+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + add configure --enable-ignore-dns-errors to retry on any failure + +ChangeSet@1.1436.15.60, 2009-05-08 15:34:46+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + Do not exceed FD_SETSIZE in ntp_intres.c + --- + ntp_intres.c: + typo + --- + ntp_intres.c: + missing comma typo + --- + ntp_intres.c: + typo + + ntpd/ntp_intres.c@1.48.1.6, 2009-05-08 15:34:45+00:00, davehart@shiny.ad.hartbrothers.com +64 -33 + fix typos, refine "host name not found" log message, stay under FD_SETSIZE + + ntpd/ntp_request.c@1.65.1.2, 2009-05-08 15:34:45+00:00, davehart@shiny.ad.hartbrothers.com +21 -3 + after ntp_intres adds a server entry, rescan interfaces, to notice the + return of connectivity sooner. + + ntpd/ntp_timer.c@1.33.1.1, 2009-05-08 15:34:45+00:00, davehart@shiny.ad.hartbrothers.com +3 -5 + indent cleanup + + ports/winnt/include/config.h@1.46.1.6, 2009-05-08 15:34:45+00:00, davehart@shiny.ad.hartbrothers.com +4 -10 + remove FORCE_DNSRETRY, no longer used + indent cleanup + +ChangeSet@1.1845.1.8, 2009-05-08 08:07:08-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P173 + TAG: NTP_4_2_5P173 + + ChangeLog@1.310.1.6, 2009-05-08 08:06:39-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P173 + + gsoc_sntp/sntp-opts.c@1.34, 2009-05-08 08:06:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P173 + + gsoc_sntp/sntp-opts.h@1.34, 2009-05-08 08:06:41-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P173 + + gsoc_sntp/sntp-opts.texi@1.34, 2009-05-08 08:06:42-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P173 + + gsoc_sntp/sntp.1@1.34, 2009-05-08 08:06:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P173 + + ntpd/ntpd-opts.c@1.165, 2009-05-08 08:06:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P173 + + ntpd/ntpd-opts.h@1.165, 2009-05-08 08:06:44-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P173 + + ntpd/ntpd-opts.texi@1.164, 2009-05-08 08:06:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P173 + + ntpd/ntpd.1@1.164, 2009-05-08 08:06:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P173 + + ntpdc/ntpdc-opts.c@1.161, 2009-05-08 08:06:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P173 + + ntpdc/ntpdc-opts.h@1.161, 2009-05-08 08:06:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P173 + + ntpdc/ntpdc-opts.texi@1.160, 2009-05-08 08:06:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P173 + + ntpdc/ntpdc.1@1.160, 2009-05-08 08:06:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P173 + + ntpq/ntpq-opts.c@1.161, 2009-05-08 08:06:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P173 + + ntpq/ntpq-opts.h@1.161, 2009-05-08 08:06:51-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P173 + + ntpq/ntpq-opts.texi@1.160, 2009-05-08 08:06:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P173 + + ntpq/ntpq.1@1.160, 2009-05-08 08:06:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P173 + + ntpsnmpd/ntpsnmpd-opts.c@1.42, 2009-05-08 08:06:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P173 + + ntpsnmpd/ntpsnmpd-opts.h@1.42, 2009-05-08 08:06:55-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P173 + + ntpsnmpd/ntpsnmpd-opts.texi@1.42, 2009-05-08 08:06:56-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P173 + + ntpsnmpd/ntpsnmpd.1@1.42, 2009-05-08 08:06:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P173 + + packageinfo.sh@1.176, 2009-05-08 08:06:57-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P173 + + sntp/sntp-opts.c@1.161, 2009-05-08 08:06:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P173 + + sntp/sntp-opts.h@1.161, 2009-05-08 08:06:58-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P173 + + sntp/sntp-opts.texi@1.160, 2009-05-08 08:06:59-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P173 + + sntp/sntp.1@1.160, 2009-05-08 08:07:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P173 + + util/ntp-keygen-opts.c@1.164, 2009-05-08 08:07:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P173 + + util/ntp-keygen-opts.h@1.164, 2009-05-08 08:07:02-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P173 + + util/ntp-keygen-opts.texi@1.163, 2009-05-08 08:07:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P173 + + util/ntp-keygen.1@1.163, 2009-05-08 08:07:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P173 + +ChangeSet@1.1436.22.1, 2009-05-08 11:24:43+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1178] Use prior FORCE_DNSRETRY behavior as needed at runtime + + ChangeLog@1.1.17.1, 2009-05-08 11:24:42+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1178] Use prior FORCE_DNSRETRY behavior as needed at runtime + + ntpd/ntp_intres.c@1.48.1.5, 2009-05-08 11:24:42+00:00, davehart@shiny.ad.hartbrothers.com +53 -55 + [Bug 1178] Use prior FORCE_DNSRETRY behavior as needed at runtime + +ChangeSet@1.1436.15.58, 2009-05-08 04:42:52-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_4P7_RC6 + TAG: NTP_4_2_4P7_RC6 + + ChangeLog@1.1.1.82, 2009-05-08 04:42:28-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_4P7_RC6 + + ntpd/ntpd-opts.c@1.50.23.1, 2009-05-08 04:42:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC6 + + ntpd/ntpd-opts.h@1.50.23.1, 2009-05-08 04:42:29-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC6 + + ntpd/ntpd-opts.texi@1.49.23.1, 2009-05-08 04:42:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC6 + + ntpd/ntpd.1@1.48.23.1, 2009-05-08 04:42:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC6 + + ntpd/ntpdsim-opts.c@1.50.23.1, 2009-05-08 04:42:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC6 + + ntpd/ntpdsim-opts.h@1.50.23.1, 2009-05-08 04:42:32-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC6 + + ntpd/ntpdsim-opts.texi@1.48.23.1, 2009-05-08 04:42:33-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC6 + + ntpd/ntpdsim.1@1.48.23.1, 2009-05-08 04:42:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC6 + + ntpdc/ntpdc-opts.c@1.50.23.1, 2009-05-08 04:42:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC6 + + ntpdc/ntpdc-opts.h@1.50.23.1, 2009-05-08 04:42:35-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC6 + + ntpdc/ntpdc-opts.texi@1.48.23.1, 2009-05-08 04:42:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC6 + + ntpdc/ntpdc.1@1.48.23.1, 2009-05-08 04:42:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC6 + + ntpq/ntpq-opts.c@1.52.23.1, 2009-05-08 04:42:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC6 + + ntpq/ntpq-opts.h@1.52.23.1, 2009-05-08 04:42:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC6 + + ntpq/ntpq-opts.texi@1.49.23.1, 2009-05-08 04:42:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC6 + + ntpq/ntpq.1@1.48.23.1, 2009-05-08 04:42:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC6 + + packageinfo.sh@1.65.31.1, 2009-05-08 04:42:42-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC6 + + sntp/sntp-opts.c@1.49.23.1, 2009-05-08 04:42:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC6 + + sntp/sntp-opts.h@1.49.23.1, 2009-05-08 04:42:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC6 + + sntp/sntp-opts.texi@1.46.23.1, 2009-05-08 04:42:44-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC6 + + sntp/sntp.1@1.49.23.1, 2009-05-08 04:42:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC6 + + util/ntp-keygen-opts.c@1.49.23.1, 2009-05-08 04:42:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC6 + + util/ntp-keygen-opts.h@1.49.23.1, 2009-05-08 04:42:46-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC6 + + util/ntp-keygen-opts.texi@1.47.23.1, 2009-05-08 04:42:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC6 + + util/ntp-keygen.1@1.47.23.1, 2009-05-08 04:42:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC6 + +ChangeSet@1.1436.15.57, 2009-05-08 03:29:16-04:00, stenn@pogo.udel.edu +1 -0 + typo + + ChangeLog@1.1.1.81, 2009-05-08 03:28:46-04:00, stenn@pogo.udel.edu +1 -1 + typo + +ChangeSet@1.1436.15.56, 2009-05-08 02:13:17+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + Add [Bug 1071] reference to ChangeLog entry + + ChangeLog@1.1.1.80, 2009-05-08 02:13:16+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + [Bug 1071] Log a message and exit before trying to use FD_SET with a + descriptor larger than FD_SETSIZE, which will corrupt memory + (adds reference to 1071 to existing description) + +ChangeSet@1.1436.15.55, 2009-05-08 01:23:43+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1179] error messages for -u/--user and -i when built w/o droproot + + ChangeLog@1.1.1.79, 2009-05-08 01:23:41+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1179] error messages for -u/--user and -i when built w/o droproot + + ntpd/cmd_args.c@1.45.3.4, 2009-05-08 01:23:41+00:00, davehart@shiny.ad.hartbrothers.com +39 -19 + descriptive error messages for -u/--user and -i without droproot + +ChangeSet@1.1436.15.54, 2009-05-07 22:15:41+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + ntp_io.c: do not use FD_SET beyond FD_SETSIZE, watch for corruption of inter_list.head + + ChangeLog@1.1.1.78, 2009-05-07 22:15:39+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + do not use FD_SET beyond FD_SETSIZE, watch for corruption of inter_list.head + + ntpd/ntp_io.c@1.244.2.16, 2009-05-07 22:15:39+00:00, davehart@shiny.ad.hartbrothers.com +23 -0 + do not use FD_SET beyond FD_SETSIZE, watch for corruption of inter_list.head + +ChangeSet@1.1436.15.53, 2009-05-07 07:39:41+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + refclock_jjy.c: + add missing newline before EOF + + ntpd/refclock_jjy.c@1.13.1.2, 2009-05-07 07:39:32+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + add missing newline before EOF + +ChangeSet@1.1845.1.2, 2009-05-07 05:58:42+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + refclock_jjy.c merge from stable cleanup + + ntpd/refclock_jjy.c@1.16, 2009-05-07 05:58:41+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + dropped a prototype in merge from stable + + ports/winnt/ntp.sln@1.3, 2009-05-07 05:58:41+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + moving ntpd.vcproj to be listed first should make it the default project + + ports/winnt/ntpd/ntpd.vcproj@1.4, 2009-05-07 05:58:41+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add refclock_jjy.c reference + +ChangeSet@1.1436.15.52, 2009-05-07 05:19:36+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 784] Make --enable-linuxcaps the default when available + add reference to refclock_jjy.c to ports/winnt/ntpd/ntpd.vcproj + + ChangeLog@1.1.1.77, 2009-05-07 05:19:34+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 784] Make --enable-linuxcaps the default when available + + configure.ac@1.400.1.15, 2009-05-07 05:19:34+00:00, davehart@shiny.ad.hartbrothers.com +34 -33 + [Bug 784] Make --enable-linuxcaps the default when available + + ports/winnt/ntpd/ntpd.vcproj@1.1.1.1, 2009-05-07 05:19:34+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add reference to refclock_jjy.c to ports/winnt/ntpd/ntpd.vcproj + +ChangeSet@1.1436.15.51, 2009-05-07 05:10:54+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + Updated JJY reference clock driver from Takao abe + Make ntpd the default project in Visual C++/Visual Studio + + ChangeLog@1.1.1.76, 2009-05-07 05:10:52+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + Updated JJY reference clock driver from Takao abe + + html/drivers/driver40.html@1.14, 2009-05-07 05:10:52+00:00, davehart@shiny.ad.hartbrothers.com +103 -48 + Updated JJY reference clock driver from Takao abe + + ntpd/refclock_jjy.c@1.13.1.1, 2009-05-07 05:10:52+00:00, davehart@shiny.ad.hartbrothers.com +153 -5 + Updated JJY reference clock driver from Takao abe + + ports/winnt/ntp.sln@1.1.1.1, 2009-05-07 05:10:53+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + Make ntpd the default project in Visual C++/Visual Studio + +ChangeSet@1.1846, 2009-05-06 17:29:45+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + Simplify configure.ac NTP_CACHEVERSION interface, update comments + + ChangeLog@1.311, 2009-05-06 17:29:43+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + Clean up configure.ac NTP_CACHEVERSION interface, display cache version + when clearing. Fixes a regression. + + + configure.ac@1.442, 2009-05-06 17:29:43+00:00, davehart@shiny.ad.hartbrothers.com +16 -25 + Simplify configure.ac NTP_CACHEVERSION interface, update comments + + gsoc_sntp/configure.ac@1.17, 2009-05-06 17:29:43+00:00, davehart@shiny.ad.hartbrothers.com +16 -14 + Simplify configure.ac NTP_CACHEVERSION interface, update comments + + m4/ntp_cacheversion.m4@1.8, 2009-05-06 17:29:43+00:00, davehart@shiny.ad.hartbrothers.com +18 -48 + Simplify configure.ac NTP_CACHEVERSION interface, display cache version + for top configure when clearing due to mismatch (fix regression) + + sntp/configure.ac@1.23, 2009-05-06 17:29:44+00:00, davehart@shiny.ad.hartbrothers.com +19 -17 + Simplify configure.ac NTP_CACHEVERSION interface, update comments + +ChangeSet@1.1845, 2009-05-06 07:55:27-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P172 + TAG: NTP_4_2_5P172 + + ChangeLog@1.310, 2009-05-06 07:55:01-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P172 + + gsoc_sntp/sntp-opts.c@1.33, 2009-05-06 07:55:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P172 + + gsoc_sntp/sntp-opts.h@1.33, 2009-05-06 07:55:02-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P172 + + gsoc_sntp/sntp-opts.texi@1.33, 2009-05-06 07:55:03-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P172 + + gsoc_sntp/sntp.1@1.33, 2009-05-06 07:55:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P172 + + ntpd/ntpd-opts.c@1.164, 2009-05-06 07:55:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P172 + + ntpd/ntpd-opts.h@1.164, 2009-05-06 07:55:05-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P172 + + ntpd/ntpd-opts.texi@1.163, 2009-05-06 07:55:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P172 + + ntpd/ntpd.1@1.163, 2009-05-06 07:55:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P172 + + ntpdc/ntpdc-opts.c@1.160, 2009-05-06 07:55:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P172 + + ntpdc/ntpdc-opts.h@1.160, 2009-05-06 07:55:09-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P172 + + ntpdc/ntpdc-opts.texi@1.159, 2009-05-06 07:55:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P172 + + ntpdc/ntpdc.1@1.159, 2009-05-06 07:55:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P172 + + ntpq/ntpq-opts.c@1.160, 2009-05-06 07:55:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P172 + + ntpq/ntpq-opts.h@1.160, 2009-05-06 07:55:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P172 + + ntpq/ntpq-opts.texi@1.159, 2009-05-06 07:55:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P172 + + ntpq/ntpq.1@1.159, 2009-05-06 07:55:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P172 + + ntpsnmpd/ntpsnmpd-opts.c@1.41, 2009-05-06 07:55:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P172 + + ntpsnmpd/ntpsnmpd-opts.h@1.41, 2009-05-06 07:55:15-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P172 + + ntpsnmpd/ntpsnmpd-opts.texi@1.41, 2009-05-06 07:55:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P172 + + ntpsnmpd/ntpsnmpd.1@1.41, 2009-05-06 07:55:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P172 + + packageinfo.sh@1.175, 2009-05-06 07:55:18-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P172 + + sntp/sntp-opts.c@1.160, 2009-05-06 07:55:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P172 + + sntp/sntp-opts.h@1.160, 2009-05-06 07:55:19-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P172 + + sntp/sntp-opts.texi@1.159, 2009-05-06 07:55:20-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P172 + + sntp/sntp.1@1.159, 2009-05-06 07:55:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P172 + + util/ntp-keygen-opts.c@1.163, 2009-05-06 07:55:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P172 + + util/ntp-keygen-opts.h@1.163, 2009-05-06 07:55:22-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P172 + + util/ntp-keygen-opts.texi@1.162, 2009-05-06 07:55:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P172 + + util/ntp-keygen.1@1.162, 2009-05-06 07:55:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P172 + +ChangeSet@1.1844, 2009-05-06 02:47:31-04:00, stenn@whimsy.udel.edu +5 -0 + [Bug 1175] Instability in PLL daemon mode + + ChangeLog@1.309, 2009-05-06 02:42:40-04:00, stenn@whimsy.udel.edu +2 -1 + [Bug 1175] Instability in PLL daemon mode + + include/Makefile.am@1.33, 2009-05-06 02:41:06-04:00, stenn@whimsy.udel.edu +57 -55 + typo + + include/ntpd.h@1.125, 2009-05-06 02:44:26-04:00, stenn@whimsy.udel.edu +1 -1 + [Bug 1175] Instability in PLL daemon mode + + ntpd/ntp_loopfilter.c@1.150, 2009-05-06 02:44:48-04:00, stenn@whimsy.udel.edu +14 -12 + [Bug 1175] Instability in PLL daemon mode + + ntpd/ntp_proto.c@1.285, 2009-05-06 02:44:51-04:00, stenn@whimsy.udel.edu +1 -1 + [Bug 1175] Instability in PLL daemon mode + +ChangeSet@1.1840.1.1, 2009-05-05 21:07:51+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + Makefile.am: + add new file ntp_lineedit.h to noinst_HEADERS + + include/Makefile.am@1.32, 2009-05-05 21:07:35+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + add new file ntp_lineedit.h to noinst_HEADERS + +ChangeSet@1.1842, 2009-05-05 19:19:25+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1176] refclock_parse.c does not compile without PPSAPI + + ChangeLog@1.308, 2009-05-05 19:19:24+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1176] refclock_parse.c does not compile without PPSAPI + + ntpd/refclock_parse.c@1.51, 2009-05-05 19:19:24+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1176] refclock_parse.c does not compile without PPSAPI + +ChangeSet@1.1841, 2009-05-04 08:02:28-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P171 + TAG: NTP_4_2_5P171 + + ChangeLog@1.307, 2009-05-04 08:01:58-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P171 + + gsoc_sntp/sntp-opts.c@1.32, 2009-05-04 08:01:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P171 + + gsoc_sntp/sntp-opts.h@1.32, 2009-05-04 08:02:00-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P171 + + gsoc_sntp/sntp-opts.texi@1.32, 2009-05-04 08:02:01-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P171 + + gsoc_sntp/sntp.1@1.32, 2009-05-04 08:02:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P171 + + ntpd/ntpd-opts.c@1.163, 2009-05-04 08:02:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P171 + + ntpd/ntpd-opts.h@1.163, 2009-05-04 08:02:04-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P171 + + ntpd/ntpd-opts.texi@1.162, 2009-05-04 08:02:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P171 + + ntpd/ntpd.1@1.162, 2009-05-04 08:02:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P171 + + ntpdc/ntpdc-opts.c@1.159, 2009-05-04 08:02:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P171 + + ntpdc/ntpdc-opts.h@1.159, 2009-05-04 08:02:07-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P171 + + ntpdc/ntpdc-opts.texi@1.158, 2009-05-04 08:02:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P171 + + ntpdc/ntpdc.1@1.158, 2009-05-04 08:02:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P171 + + ntpq/ntpq-opts.c@1.159, 2009-05-04 08:02:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P171 + + ntpq/ntpq-opts.h@1.159, 2009-05-04 08:02:10-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P171 + + ntpq/ntpq-opts.texi@1.158, 2009-05-04 08:02:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P171 + + ntpq/ntpq.1@1.158, 2009-05-04 08:02:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P171 + + ntpsnmpd/ntpsnmpd-opts.c@1.40, 2009-05-04 08:02:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P171 + + ntpsnmpd/ntpsnmpd-opts.h@1.40, 2009-05-04 08:02:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P171 + + ntpsnmpd/ntpsnmpd-opts.texi@1.40, 2009-05-04 08:02:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P171 + + ntpsnmpd/ntpsnmpd.1@1.40, 2009-05-04 08:02:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P171 + + packageinfo.sh@1.174, 2009-05-04 08:02:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P171 + + sntp/sntp-opts.c@1.159, 2009-05-04 08:02:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P171 + + sntp/sntp-opts.h@1.159, 2009-05-04 08:02:17-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P171 + + sntp/sntp-opts.texi@1.158, 2009-05-04 08:02:18-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P171 + + sntp/sntp.1@1.158, 2009-05-04 08:02:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P171 + + util/ntp-keygen-opts.c@1.162, 2009-05-04 08:02:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P171 + + util/ntp-keygen-opts.h@1.162, 2009-05-04 08:02:21-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P171 + + util/ntp-keygen-opts.texi@1.161, 2009-05-04 08:02:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P171 + + util/ntp-keygen.1@1.161, 2009-05-04 08:02:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P171 + +ChangeSet@1.1837.1.2, 2009-05-04 06:41:39+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ntp_cacheversion.m4: + iterate to find the quoting problem + + m4/ntp_cacheversion.m4@1.7, 2009-05-04 06:41:24+00:00, davehart@shiny.ad.hartbrothers.com +8 -8 + iterate to find the quoting problem + +ChangeSet@1.1837.1.1, 2009-05-04 06:23:22+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ntp_cacheversion.m4: + m4 goes infinite + + m4/ntp_cacheversion.m4@1.6, 2009-05-04 06:22:49+00:00, davehart@shiny.ad.hartbrothers.com +11 -11 + m4 goes infinite + +ChangeSet@1.1837, 2009-05-04 02:05:29+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + solve occasional sntp link problems with socket APIs by bringing its + AC_SEARCH_LIBS for gethostent in line with main and gsoc_sntp configure + tests, bump sntp/configure.ac cache version to 20090503 as a result + --- + ntp_cacheversion.m4: clear even other version stamps when flushing + cache iff we are the top configure this invocation. + + + ChangeLog@1.305, 2009-05-04 02:05:27+00:00, davehart@shiny.ad.hartbrothers.com +3 -1 + Fix msntp link problem on Solaris when configured before parent + + configure.ac@1.439.1.1, 2009-05-04 02:05:27+00:00, davehart@shiny.ad.hartbrothers.com +22 -1 + finally an idiom for "default to null not unset" that works + --- + bump cache version due to changes in sntp and gsoc_sntp gethostent + library search order, the result of which is cached and shared with + this configure. + + gsoc_sntp/configure.ac@1.16, 2009-05-04 02:05:27+00:00, davehart@shiny.ad.hartbrothers.com +5 -4 + make gethostent library search compatible with parent configure, and + bump cache version because it is cached. + + m4/ntp_cacheversion.m4@1.5, 2009-05-04 02:05:27+00:00, davehart@shiny.ad.hartbrothers.com +67 -36 + clear even other version stamps when flushing cache iff we are the + top configure this invocation. Prevents bump of child version stamp + and parent version stamp at the same time from causing a useless + second flush by the child just after the parent has recreated it from + empty. + + sntp/configure.ac@1.22, 2009-05-04 02:05:27+00:00, davehart@shiny.ad.hartbrothers.com +15 -2 + solve occasional sntp link problems with socket APIs by bringing its + AC_SEARCH_LIBS for gethostent in line with main and gsoc_sntp configure + --- + bump config.cache version for incompatible gethostent library search + +ChangeSet@1.1833.2.1, 2009-05-03 15:21:37-04:00, stenn@whimsy.udel.edu +5 -0 + Autokey documentation cleanup from Dave Mills + + ChangeLog@1.302.2.1, 2009-05-03 15:21:15-04:00, stenn@whimsy.udel.edu +1 -0 + Autokey documentation cleanup from Dave Mills + + html/authopt.html@1.49, 2009-05-03 15:20:23-04:00, stenn@whimsy.udel.edu +345 -217 + Autokey documentation cleanup from Dave Mills + + html/decode.html@1.7, 2009-05-03 15:20:25-04:00, stenn@whimsy.udel.edu +8 -8 + Autokey documentation cleanup from Dave Mills + + html/rate.html@1.5, 2009-05-03 15:20:30-04:00, stenn@whimsy.udel.edu +4 -2 + Autokey documentation cleanup from Dave Mills + + html/xleave.html@1.4, 2009-05-03 15:20:32-04:00, stenn@whimsy.udel.edu +4 -2 + Autokey documentation cleanup from Dave Mills + +ChangeSet@1.1835, 2009-05-03 14:43:41+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + reliably detect invocation of child configure (NTP_CONFIGURE_PARENT) + + gsoc_sntp/configure.ac@1.15, 2009-05-03 14:43:40+00:00, davehart@shiny.ad.hartbrothers.com +10 -0 + reliably detect invocation of child configure (NTP_CONFIGURE_PARENT) + + m4/ntp_cacheversion.m4@1.4, 2009-05-03 14:43:40+00:00, davehart@shiny.ad.hartbrothers.com +44 -17 + reliably detect invocation of child configure (NTP_CONFIGURE_PARENT) + + sntp/configure.ac@1.21, 2009-05-03 14:43:40+00:00, davehart@shiny.ad.hartbrothers.com +10 -0 + reliably detect invocation of child configure (NTP_CONFIGURE_PARENT) + +ChangeSet@1.1833.1.5, 2009-05-03 09:15:12+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ntp_lineedit.c: + remove leftover of another approach + + libntp/ntp_lineedit.c@1.5, 2009-05-03 09:14:58+00:00, davehart@shiny.ad.hartbrothers.com +0 -2 + remove leftover of another approach + +ChangeSet@1.1833.1.4, 2009-05-03 08:37:39+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ntp_lineedit.c: + emit newline at interactive EOF to avoid ntpq> osprompt$ + --- + ntp_lineedit.c: + alternating between readline and stone hammers is not good + --- + ntp_lineedit.c: + keep preprocessor # in column one, fix readline path bug + + libntp/ntp_lineedit.c@1.4, 2009-05-03 08:37:38+00:00, davehart@shiny.ad.hartbrothers.com +102 -92 + emit newline at interactive EOF to avoid ntpq> osprompt$ + --- + alternating between readline and stone hammers is not good + --- + keep preprocessor # in column one, fix readline path bug + +ChangeSet@1.1833.1.3, 2009-05-03 06:25:51+00:00, davehart@shiny.ad.hartbrothers.com +8 -0 + void printf(...) -> int printf(...) quiets gcc warning + ../../libparse/clk_computime.c:57: warning: conflicting types for built-in function 'printf' + + libparse/clk_computime.c@1.10, 2009-05-03 06:25:49+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + void printf(...) -> int printf(...) quiets gcc warning + ../../libparse/clk_computime.c:57: warning: conflicting types for built-in function 'printf' + + libparse/clk_dcf7000.c@1.10, 2009-05-03 06:25:49+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + void printf(...) -> int printf(...) quiets gcc warning + ../../libparse/clk_computime.c:57: warning: conflicting types for built-in function 'printf' + + libparse/clk_hopf6021.c@1.10, 2009-05-03 06:25:49+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + void printf(...) -> int printf(...) quiets gcc warning + ../../libparse/clk_computime.c:57: warning: conflicting types for built-in function 'printf' + + libparse/clk_rcc8000.c@1.10, 2009-05-03 06:25:49+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + void printf(...) -> int printf(...) quiets gcc warning + ../../libparse/clk_computime.c:57: warning: conflicting types for built-in function 'printf' + + libparse/clk_schmid.c@1.10, 2009-05-03 06:25:49+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + void printf(...) -> int printf(...) quiets gcc warning + ../../libparse/clk_computime.c:57: warning: conflicting types for built-in function 'printf' + + libparse/clk_trimtaip.c@1.10, 2009-05-03 06:25:49+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + void printf(...) -> int printf(...) quiets gcc warning + ../../libparse/clk_computime.c:57: warning: conflicting types for built-in function 'printf' + + libparse/clk_varitext.c@1.9, 2009-05-03 06:25:49+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + void printf(...) -> int printf(...) quiets gcc warning + ../../libparse/clk_computime.c:57: warning: conflicting types for built-in function 'printf' + + ports/winnt/ntpd/ntpd.vcproj@1.3, 2009-05-03 06:25:49+00:00, davehart@shiny.ad.hartbrothers.com +12 -0 + add libparse/clk_varitext.c (excluded from Windows build) + +ChangeSet@1.1833.1.2, 2009-05-03 05:08:34+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + ../../libparse/parse.c:211: warning: implicit declaration of function 'bcopy' + ../../libparse/parse.c:211: warning: incompatible implicit declaration of built- + in function 'bcopy' + + #include in ntp_lineedit.c which uses free() + + configure.ac@1.440, 2009-05-03 05:08:32+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ../../libparse/parse.c:211: warning: implicit declaration of function 'bcopy' + ../../libparse/parse.c:211: warning: incompatible implicit declaration of built- + in function 'bcopy' + + + include/ntp_string.h@1.4, 2009-05-03 05:08:32+00:00, davehart@shiny.ad.hartbrothers.com +12 -5 + ../../libparse/parse.c:211: warning: implicit declaration of function 'bcopy' + ../../libparse/parse.c:211: warning: incompatible implicit declaration of built- + in function 'bcopy' + + + libntp/ntp_lineedit.c@1.3, 2009-05-03 05:08:32+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + implicit free decl warning + +ChangeSet@1.1833.1.1, 2009-05-03 01:47:51+00:00, davehart@shiny.ad.hartbrothers.com +11 -0 + [Bug 1171] line editing in ntpq/ntpdc + [Bug 1173] NMEA PPSAPI fails on Solaris + + ChangeLog@1.302.1.1, 2009-05-03 01:47:47+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1171] [Bug 1173] + + include/ntp_lineedit.h@1.1, 2009-05-03 01:25:44+00:00, davehart@shiny.ad.hartbrothers.com +13 -0 + centralize ntpq/ntpdc interactive line editing + + include/ntp_lineedit.h@1.0, 2009-05-03 01:25:44+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + libntp/Makefile.am@1.43, 2009-05-03 01:47:47+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + add libntp/ntp_lineedit.c + + libntp/ntp_lineedit.c@1.2, 2009-05-03 01:47:47+00:00, davehart@shiny.ad.hartbrothers.com +13 -6 + always return a non-empty string or NULL + + libntp/ntp_lineedit.c@1.1, 2009-05-03 01:25:44+00:00, davehart@shiny.ad.hartbrothers.com +227 -0 + centralize ntpq/ntpdc interactive line editing + + libntp/ntp_lineedit.c@1.0, 2009-05-03 01:25:44+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + m4/ntp_lineeditlibs.m4@1.6, 2009-05-03 01:47:47+00:00, davehart@shiny.ad.hartbrothers.com +53 -53 + [Bug 1171] + + ntpd/refclock_nmea.c@1.35, 2009-05-03 01:47:47+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1173] set pps_params.api_version = PPS_API_VERS_1 before calling pps_params + + ntpdc/ntpdc.c@1.62, 2009-05-03 01:47:47+00:00, davehart@shiny.ad.hartbrothers.com +9 -30 + [Bug 1171] + + ntpq/ntpq.c@1.84, 2009-05-03 01:47:47+00:00, davehart@shiny.ad.hartbrothers.com +10 -30 + [Bug 1171] + + ports/winnt/libntp/libntp.vcproj@1.5, 2009-05-03 01:47:48+00:00, davehart@shiny.ad.hartbrothers.com +8 -0 + add ntp_lineedit.c ntp_lineedit.h references + + ports/winnt/ntpdc/ntpdc.vcproj@1.3, 2009-05-03 01:47:48+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add ntp_lineedit.h reference + + ports/winnt/ntpq/ntpq.vcproj@1.3, 2009-05-03 01:47:48+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add ntp_lineedit.h reference + +ChangeSet@1.1833, 2009-05-02 08:06:28-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P170 + TAG: NTP_4_2_5P170 + + ChangeLog@1.302, 2009-05-02 08:05:57-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P170 + + gsoc_sntp/sntp-opts.c@1.31, 2009-05-02 08:05:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P170 + + gsoc_sntp/sntp-opts.h@1.31, 2009-05-02 08:06:00-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P170 + + gsoc_sntp/sntp-opts.texi@1.31, 2009-05-02 08:06:01-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P170 + + gsoc_sntp/sntp.1@1.31, 2009-05-02 08:06:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P170 + + ntpd/ntpd-opts.c@1.162, 2009-05-02 08:06:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P170 + + ntpd/ntpd-opts.h@1.162, 2009-05-02 08:06:04-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P170 + + ntpd/ntpd-opts.texi@1.161, 2009-05-02 08:06:05-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P170 + + ntpd/ntpd.1@1.161, 2009-05-02 08:06:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P170 + + ntpdc/ntpdc-opts.c@1.158, 2009-05-02 08:06:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P170 + + ntpdc/ntpdc-opts.h@1.158, 2009-05-02 08:06:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P170 + + ntpdc/ntpdc-opts.texi@1.157, 2009-05-02 08:06:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P170 + + ntpdc/ntpdc.1@1.157, 2009-05-02 08:06:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P170 + + ntpq/ntpq-opts.c@1.158, 2009-05-02 08:06:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P170 + + ntpq/ntpq-opts.h@1.158, 2009-05-02 08:06:11-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P170 + + ntpq/ntpq-opts.texi@1.157, 2009-05-02 08:06:12-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P170 + + ntpq/ntpq.1@1.157, 2009-05-02 08:06:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P170 + + ntpsnmpd/ntpsnmpd-opts.c@1.39, 2009-05-02 08:06:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P170 + + ntpsnmpd/ntpsnmpd-opts.h@1.39, 2009-05-02 08:06:15-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P170 + + ntpsnmpd/ntpsnmpd-opts.texi@1.39, 2009-05-02 08:06:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P170 + + ntpsnmpd/ntpsnmpd.1@1.39, 2009-05-02 08:06:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P170 + + packageinfo.sh@1.173, 2009-05-02 08:06:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P170 + + sntp/sntp-opts.c@1.158, 2009-05-02 08:06:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P170 + + sntp/sntp-opts.h@1.158, 2009-05-02 08:06:18-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P170 + + sntp/sntp-opts.texi@1.157, 2009-05-02 08:06:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P170 + + sntp/sntp.1@1.157, 2009-05-02 08:06:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P170 + + util/ntp-keygen-opts.c@1.161, 2009-05-02 08:06:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P170 + + util/ntp-keygen-opts.h@1.161, 2009-05-02 08:06:22-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P170 + + util/ntp-keygen-opts.texi@1.160, 2009-05-02 08:06:22-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P170 + + util/ntp-keygen.1@1.160, 2009-05-02 08:06:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P170 + +ChangeSet@1.1830.4.3, 2009-05-02 10:26:07+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ntp_cacheversion.m4: + remove diagnostic after successful tests + + m4/ntp_cacheversion.m4@1.3, 2009-05-02 10:25:56+00:00, davehart@shiny.ad.hartbrothers.com +0 -1 + remove diagnostic after successful tests + +ChangeSet@1.1830.4.2, 2009-05-02 08:37:14+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + do not clear config.cache immediately after it is created empty + + ChangeLog@1.299.4.2, 2009-05-02 08:37:12+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + do not clear config.cache immediately after it is created empty + + m4/ntp_cacheversion.m4@1.2, 2009-05-02 08:37:12+00:00, davehart@shiny.ad.hartbrothers.com +19 -6 + do not clear config.cache immediately after it is created empty + +ChangeSet@1.1436.15.50, 2009-05-02 02:38:49-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_4P7_RC5 + TAG: NTP_4_2_4P7_RC5 + + ChangeLog@1.1.1.75, 2009-05-02 02:38:22-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_4P7_RC5 + + ntpd/ntpd-opts.c@1.50.22.1, 2009-05-02 02:38:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC5 + + ntpd/ntpd-opts.h@1.50.22.1, 2009-05-02 02:38:25-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC5 + + ntpd/ntpd-opts.texi@1.49.22.1, 2009-05-02 02:38:27-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC5 + + ntpd/ntpd.1@1.48.22.1, 2009-05-02 02:38:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC5 + + ntpd/ntpdsim-opts.c@1.50.22.1, 2009-05-02 02:38:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC5 + + ntpd/ntpdsim-opts.h@1.50.22.1, 2009-05-02 02:38:29-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC5 + + ntpd/ntpdsim-opts.texi@1.48.22.1, 2009-05-02 02:38:30-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC5 + + ntpd/ntpdsim.1@1.48.22.1, 2009-05-02 02:38:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC5 + + ntpdc/ntpdc-opts.c@1.50.22.1, 2009-05-02 02:38:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC5 + + ntpdc/ntpdc-opts.h@1.50.22.1, 2009-05-02 02:38:32-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC5 + + ntpdc/ntpdc-opts.texi@1.48.22.1, 2009-05-02 02:38:33-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC5 + + ntpdc/ntpdc.1@1.48.22.1, 2009-05-02 02:38:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC5 + + ntpq/ntpq-opts.c@1.52.22.1, 2009-05-02 02:38:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC5 + + ntpq/ntpq-opts.h@1.52.22.1, 2009-05-02 02:38:35-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC5 + + ntpq/ntpq-opts.texi@1.49.22.1, 2009-05-02 02:38:36-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC5 + + ntpq/ntpq.1@1.48.22.1, 2009-05-02 02:38:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC5 + + packageinfo.sh@1.65.30.1, 2009-05-02 02:38:38-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC5 + + sntp/sntp-opts.c@1.49.22.1, 2009-05-02 02:38:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC5 + + sntp/sntp-opts.h@1.49.22.1, 2009-05-02 02:38:40-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC5 + + sntp/sntp-opts.texi@1.46.22.1, 2009-05-02 02:38:41-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC5 + + sntp/sntp.1@1.49.22.1, 2009-05-02 02:38:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC5 + + util/ntp-keygen-opts.c@1.49.22.1, 2009-05-02 02:38:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC5 + + util/ntp-keygen-opts.h@1.49.22.1, 2009-05-02 02:38:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC5 + + util/ntp-keygen-opts.texi@1.47.22.1, 2009-05-02 02:38:44-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC5 + + util/ntp-keygen.1@1.47.22.1, 2009-05-02 02:38:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC5 + +ChangeSet@1.1830.3.1, 2009-05-02 00:13:27-04:00, stenn@whimsy.udel.edu +8 -0 + Updates from Dave Mills + + ChangeLog@1.299.3.4, 2009-05-02 00:11:33-04:00, stenn@whimsy.udel.edu +1 -0 + loopfilter FLL/PLL crossover cleanup from Dave Mills + + ChangeLog@1.299.3.3, 2009-05-02 00:04:11-04:00, stenn@whimsy.udel.edu +1 -0 + Documentation updates from Dave Mills + + ChangeLog@1.299.3.2, 2009-05-02 00:00:38-04:00, stenn@whimsy.udel.edu +1 -0 + Cleanup from Dave Mills + + ChangeLog@1.299.3.1, 2009-05-01 23:59:02-04:00, stenn@whimsy.udel.edu +1 -0 + crypto API cleanup from Dave Mills + + html/authopt.html@1.48, 2009-05-02 00:02:59-04:00, stenn@whimsy.udel.edu +4 -2 + Documentation updates from Dave Mills + + html/keygen.html@1.15, 2009-05-02 00:03:04-04:00, stenn@whimsy.udel.edu +20 -63 + Documentation updates from Dave Mills + + include/ntpd.h@1.124, 2009-05-01 23:53:07-04:00, stenn@whimsy.udel.edu +1 -1 + crypto API cleanup from Dave Mills + + ntpd/ntp_crypto.c@1.133, 2009-05-01 23:58:37-04:00, stenn@whimsy.udel.edu +38 -55 + crypto API cleanup from Dave Mills + + ntpd/ntp_loopfilter.c@1.149, 2009-05-02 00:08:21-04:00, stenn@whimsy.udel.edu +12 -19 + loopfilter FLL/PLL crossover cleanup from Dave Mills + + ntpd/ntp_proto.c@1.284, 2009-05-01 23:58:38-04:00, stenn@whimsy.udel.edu +9 -11 + crypto API cleanup from Dave Mills + + util/ntp-keygen.c@1.57, 2009-05-02 00:00:12-04:00, stenn@whimsy.udel.edu +2 -6 + Cleanup from Dave Mills + +ChangeSet@1.1830.2.2, 2009-05-02 01:55:12+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + configure.ac: + restore -dev version of HAS_ROUTING_SOCKET stuff after merging from + -stable un-backporting of same + + configure.ac@1.437.2.2, 2009-05-02 01:54:40+00:00, davehart@shiny.ad.hartbrothers.com +12 -1 + restore -dev version of HAS_ROUTING_SOCKET stuff after merging from + -stable un-backporting of same + +ChangeSet@1.1436.15.49, 2009-05-02 01:49:02+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + flock-build: + set -m wasn't needed with ssh -tt and caused problems, remove + ChangeLog: + [Bug 1172] 4.2.4p7-RC{3,4} fail to build on linux. + remove unportable 'set -m' from flock-build script + configure.ac: + reverse accidental backport from -dev of struct rtattr test in + configure.ac without corresponding ntp_io.c code for HAVE_RTNETLINK + + ChangeLog@1.1.1.74, 2009-05-02 01:48:30+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + [Bug 1172] 4.2.4p7-RC{3,4} fail to build on linux. + remove unportable 'set -m' from flock-build script + + configure.ac@1.400.1.14, 2009-05-02 01:48:30+00:00, davehart@shiny.ad.hartbrothers.com +1 -12 + reverse accidental backport from -dev of struct rtattr test in + configure.ac without corresponding ntp_io.c code for HAVE_RTNETLINK + + flock-build@1.39.1.2, 2009-05-02 01:48:30+00:00, davehart@shiny.ad.hartbrothers.com +3 -5 + set -m wasn't needed with ssh -tt and caused problems, remove + +ChangeSet@1.1828.1.1, 2009-05-01 20:05:24+00:00, davehart@shiny.ad.hartbrothers.com +9 -0 + add NTP_CACHEVERSION to toss config.cache from different version + --- + enable gcc -Wstrict-overflow for gsoc_sntp + + ChangeLog@1.297.1.1, 2009-05-01 20:05:21+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + Add NTP_CACHEVERSION to configure.ac m4/ntp_cacheversion.m4 + + configure.ac@1.437.1.1, 2009-05-01 20:01:29+00:00, davehart@shiny.ad.hartbrothers.com +21 -5 + add NTP_CACHEVERSION() m4 macro to flush incompatible config.cache + + gsoc_sntp/Makefile.am@1.7, 2009-05-01 20:01:30+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + ACLOCAL_AMFLAGS += -I ../m4 + + gsoc_sntp/configure.ac@1.14, 2009-05-01 20:01:30+00:00, davehart@shiny.ad.hartbrothers.com +17 -1 + add NTP_CACHEVERSION() m4 macro to flush incompatible config.cache + --- + enable gcc -Wstrict-overflow + + include/ntp.h@1.153, 2009-05-01 20:01:30+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + references l_fp type, needs #include + + m4/ntp_cacheversion.m4@1.1, 2009-05-01 20:01:31+00:00, davehart@shiny.ad.hartbrothers.com +82 -0 + add NTP_CACHEVERSION() m4 macro to flush incompatible config.cache + + m4/ntp_cacheversion.m4@1.0, 2009-05-01 20:01:31+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ntpd/ntp_refclock.c@1.85, 2009-05-01 20:01:30+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + pps_handle_t is properly an opaque scalar, timepps-Solaris.h will be fixed + + sntp/Makefile.am@1.25, 2009-05-01 20:01:30+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + ACLOCAL_AMFLAGS += -I ../m4 + + sntp/configure.ac@1.20, 2009-05-01 20:01:31+00:00, davehart@shiny.ad.hartbrothers.com +17 -1 + add NTP_CACHEVERSION() m4 macro to flush incompatible config.cache + +ChangeSet@1.1831, 2009-05-01 15:05:10+00:00, kardel@pogo.udel.edu +3 -0 + configure.ac, refclock_parse.c, ChangeLog: + [Bug 1152] adjust PARSE to new refclock_pps logic + + ChangeLog@1.300, 2009-05-01 13:19:38+00:00, kardel@pogo.udel.edu +1 -0 + [Bug 1152] adjust PARSE to new refclock_pps logic + + configure.ac@1.438, 2009-05-01 13:19:58+00:00, kardel@pogo.udel.edu +0 -4 + [Bug 1152] adjust PARSE to new refclock_pps logic + + ntpd/refclock_parse.c@1.50, 2009-05-01 13:20:46+00:00, kardel@pogo.udel.edu +55 -42 + [Bug 1152] adjust PARSE to new refclock_pps logic + +ChangeSet@1.1830, 2009-04-30 07:58:03-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P169 + TAG: NTP_4_2_5P169 + + ChangeLog@1.299, 2009-04-30 07:57:32-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P169 + + gsoc_sntp/sntp-opts.c@1.30, 2009-04-30 07:57:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P169 + + gsoc_sntp/sntp-opts.h@1.30, 2009-04-30 07:57:34-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P169 + + gsoc_sntp/sntp-opts.texi@1.30, 2009-04-30 07:57:35-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P169 + + gsoc_sntp/sntp.1@1.30, 2009-04-30 07:57:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P169 + + ntpd/ntpd-opts.c@1.161, 2009-04-30 07:57:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P169 + + ntpd/ntpd-opts.h@1.161, 2009-04-30 07:57:38-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P169 + + ntpd/ntpd-opts.texi@1.160, 2009-04-30 07:57:39-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P169 + + ntpd/ntpd.1@1.160, 2009-04-30 07:57:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P169 + + ntpdc/ntpdc-opts.c@1.157, 2009-04-30 07:57:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P169 + + ntpdc/ntpdc-opts.h@1.157, 2009-04-30 07:57:42-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P169 + + ntpdc/ntpdc-opts.texi@1.156, 2009-04-30 07:57:43-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P169 + + ntpdc/ntpdc.1@1.156, 2009-04-30 07:57:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P169 + + ntpq/ntpq-opts.c@1.157, 2009-04-30 07:57:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P169 + + ntpq/ntpq-opts.h@1.157, 2009-04-30 07:57:45-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P169 + + ntpq/ntpq-opts.texi@1.156, 2009-04-30 07:57:46-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P169 + + ntpq/ntpq.1@1.156, 2009-04-30 07:57:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P169 + + ntpsnmpd/ntpsnmpd-opts.c@1.38, 2009-04-30 07:57:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P169 + + ntpsnmpd/ntpsnmpd-opts.h@1.38, 2009-04-30 07:57:48-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P169 + + ntpsnmpd/ntpsnmpd-opts.texi@1.38, 2009-04-30 07:57:49-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P169 + + ntpsnmpd/ntpsnmpd.1@1.38, 2009-04-30 07:57:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P169 + + packageinfo.sh@1.172, 2009-04-30 07:57:51-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P169 + + sntp/sntp-opts.c@1.157, 2009-04-30 07:57:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P169 + + sntp/sntp-opts.h@1.157, 2009-04-30 07:57:53-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P169 + + sntp/sntp-opts.texi@1.156, 2009-04-30 07:57:54-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P169 + + sntp/sntp.1@1.156, 2009-04-30 07:57:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P169 + + util/ntp-keygen-opts.c@1.160, 2009-04-30 07:57:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P169 + + util/ntp-keygen-opts.h@1.160, 2009-04-30 07:57:56-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P169 + + util/ntp-keygen-opts.texi@1.159, 2009-04-30 07:57:57-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P169 + + util/ntp-keygen.1@1.159, 2009-04-30 07:57:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P169 + +ChangeSet@1.1829, 2009-04-30 02:59:43-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1171] Note that we never look for -lreadline by default + + ChangeLog@1.298, 2009-04-30 02:59:30-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1171] Note that we never look for -lreadline by default + + m4/ntp_lineeditlibs.m4@1.5, 2009-04-30 02:59:31-04:00, stenn@whimsy.udel.edu +1 -1 + [Bug 1171] Note that we never look for -lreadline by default + +ChangeSet@1.1826.1.1, 2009-04-29 18:46:50-04:00, stenn@whimsy.udel.edu +1 -0 + typo fix on [Bug 1166] entry + + ChangeLog@1.295.1.1, 2009-04-29 18:46:37-04:00, stenn@whimsy.udel.edu +1 -1 + typo fix on [Bug 1166] entry + +ChangeSet@1.1826, 2009-04-29 08:04:45-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P168 + TAG: NTP_4_2_5P168 + + ChangeLog@1.295, 2009-04-29 08:04:16-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P168 + + gsoc_sntp/sntp-opts.c@1.29, 2009-04-29 08:04:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P168 + + gsoc_sntp/sntp-opts.h@1.29, 2009-04-29 08:04:19-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P168 + + gsoc_sntp/sntp-opts.texi@1.29, 2009-04-29 08:04:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P168 + + gsoc_sntp/sntp.1@1.29, 2009-04-29 08:04:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P168 + + ntpd/ntpd-opts.c@1.160, 2009-04-29 08:04:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P168 + + ntpd/ntpd-opts.h@1.160, 2009-04-29 08:04:21-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P168 + + ntpd/ntpd-opts.texi@1.159, 2009-04-29 08:04:22-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P168 + + ntpd/ntpd.1@1.159, 2009-04-29 08:04:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P168 + + ntpdc/ntpdc-opts.c@1.156, 2009-04-29 08:04:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P168 + + ntpdc/ntpdc-opts.h@1.156, 2009-04-29 08:04:25-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P168 + + ntpdc/ntpdc-opts.texi@1.155, 2009-04-29 08:04:26-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P168 + + ntpdc/ntpdc.1@1.155, 2009-04-29 08:04:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P168 + + ntpq/ntpq-opts.c@1.156, 2009-04-29 08:04:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P168 + + ntpq/ntpq-opts.h@1.156, 2009-04-29 08:04:28-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P168 + + ntpq/ntpq-opts.texi@1.155, 2009-04-29 08:04:30-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P168 + + ntpq/ntpq.1@1.155, 2009-04-29 08:04:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P168 + + ntpsnmpd/ntpsnmpd-opts.c@1.37, 2009-04-29 08:04:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P168 + + ntpsnmpd/ntpsnmpd-opts.h@1.37, 2009-04-29 08:04:32-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P168 + + ntpsnmpd/ntpsnmpd-opts.texi@1.37, 2009-04-29 08:04:32-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P168 + + ntpsnmpd/ntpsnmpd.1@1.37, 2009-04-29 08:04:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P168 + + packageinfo.sh@1.171, 2009-04-29 08:04:34-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P168 + + sntp/sntp-opts.c@1.156, 2009-04-29 08:04:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P168 + + sntp/sntp-opts.h@1.156, 2009-04-29 08:04:35-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P168 + + sntp/sntp-opts.texi@1.155, 2009-04-29 08:04:36-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P168 + + sntp/sntp.1@1.155, 2009-04-29 08:04:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P168 + + util/ntp-keygen-opts.c@1.159, 2009-04-29 08:04:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P168 + + util/ntp-keygen-opts.h@1.159, 2009-04-29 08:04:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P168 + + util/ntp-keygen-opts.texi@1.158, 2009-04-29 08:04:39-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P168 + + util/ntp-keygen.1@1.158, 2009-04-29 08:04:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P168 + +ChangeSet@1.1436.15.48, 2009-04-29 04:03:41-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_4P7_RC4 + TAG: NTP_4_2_4P7_RC4 + + ChangeLog@1.1.1.73, 2009-04-29 04:03:17-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_4P7_RC4 + + ntpd/ntpd-opts.c@1.50.21.1, 2009-04-29 04:03:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC4 + + ntpd/ntpd-opts.h@1.50.21.1, 2009-04-29 04:03:19-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC4 + + ntpd/ntpd-opts.texi@1.49.21.1, 2009-04-29 04:03:21-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC4 + + ntpd/ntpd.1@1.48.21.1, 2009-04-29 04:03:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC4 + + ntpd/ntpdsim-opts.c@1.50.21.1, 2009-04-29 04:03:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC4 + + ntpd/ntpdsim-opts.h@1.50.21.1, 2009-04-29 04:03:22-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC4 + + ntpd/ntpdsim-opts.texi@1.48.21.1, 2009-04-29 04:03:24-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC4 + + ntpd/ntpdsim.1@1.48.21.1, 2009-04-29 04:03:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC4 + + ntpdc/ntpdc-opts.c@1.50.21.1, 2009-04-29 04:03:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC4 + + ntpdc/ntpdc-opts.h@1.50.21.1, 2009-04-29 04:03:26-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC4 + + ntpdc/ntpdc-opts.texi@1.48.21.1, 2009-04-29 04:03:27-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC4 + + ntpdc/ntpdc.1@1.48.21.1, 2009-04-29 04:03:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC4 + + ntpq/ntpq-opts.c@1.52.21.1, 2009-04-29 04:03:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC4 + + ntpq/ntpq-opts.h@1.52.21.1, 2009-04-29 04:03:29-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC4 + + ntpq/ntpq-opts.texi@1.49.21.1, 2009-04-29 04:03:30-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC4 + + ntpq/ntpq.1@1.48.21.1, 2009-04-29 04:03:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC4 + + packageinfo.sh@1.65.29.1, 2009-04-29 04:03:31-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC4 + + sntp/sntp-opts.c@1.49.21.1, 2009-04-29 04:03:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC4 + + sntp/sntp-opts.h@1.49.21.1, 2009-04-29 04:03:33-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC4 + + sntp/sntp-opts.texi@1.46.21.1, 2009-04-29 04:03:34-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC4 + + sntp/sntp.1@1.49.21.1, 2009-04-29 04:03:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC4 + + util/ntp-keygen-opts.c@1.49.21.1, 2009-04-29 04:03:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC4 + + util/ntp-keygen-opts.h@1.49.21.1, 2009-04-29 04:03:36-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC4 + + util/ntp-keygen-opts.texi@1.47.21.1, 2009-04-29 04:03:36-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC4 + + util/ntp-keygen.1@1.47.21.1, 2009-04-29 04:03:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC4 + +ChangeSet@1.1436.15.47, 2009-04-29 01:50:44-04:00, stenn@pogo.udel.edu +1 -0 + No need to know the GCC -W items in config.h + + configure.ac@1.400.1.13, 2009-04-29 01:50:36-04:00, stenn@pogo.udel.edu +2 -12 + No need to know the GCC -W items in config.h + +ChangeSet@1.1817.4.1, 2009-04-29 01:40:19-04:00, stenn@whimsy.udel.edu +8 -0 + Updates from Dave Mills + + ChangeLog@1.286.4.6, 2009-04-29 01:40:07-04:00, stenn@whimsy.udel.edu +1 -0 + Updates from Dave Mills + + ChangeLog@1.286.4.5, 2009-04-29 01:37:22-04:00, stenn@whimsy.udel.edu +1 -0 + updates + + ChangeLog@1.286.4.4, 2009-04-29 01:35:22-04:00, stenn@whimsy.udel.edu +1 -0 + Fix the error return and syslog function ID in refclock_{param,ppsapi} + + ChangeLog@1.286.4.3, 2009-04-29 01:30:23-04:00, stenn@whimsy.udel.edu +1 -0 + Make sure syspoll is within the peer's minpoll/maxpoll bounds + + ChangeLog@1.286.4.2, 2009-04-29 01:28:39-04:00, stenn@whimsy.udel.edu +1 -0 + ntp_crypto.c: Use sign_siglen, not len. sign key filename cleanup. + + ChangeLog@1.286.4.1, 2009-04-29 01:23:45-04:00, stenn@whimsy.udel.edu +1 -0 + Bump NTP_MAXEXTEN from 1024 to 2048, update values for some field lengths + + html/keygen.html@1.14, 2009-04-29 01:39:33-04:00, stenn@whimsy.udel.edu +222 -133 + ntp-keygen updates + + include/ntp.h@1.152, 2009-04-29 01:23:24-04:00, stenn@whimsy.udel.edu +3 -3 + Bump NTP_MAXEXTEN from 1024 to 2048, update values for some field lengths + + include/ntp_crypto.h@1.45, 2009-04-29 01:23:26-04:00, stenn@whimsy.udel.edu +1 -1 + Bump NTP_MAXEXTEN from 1024 to 2048, update values for some field lengths + + ntpd/ntp_crypto.c@1.132, 2009-04-29 01:28:41-04:00, stenn@whimsy.udel.edu +19 -23 + ntp_crypto.c: Use sign_siglen, not len. sign key filename cleanup. + + ntpd/ntp_proto.c@1.283, 2009-04-29 01:30:25-04:00, stenn@whimsy.udel.edu +18 -2 + Make sure syspoll is within the peer's minpoll/maxpoll bounds + + ntpd/ntp_refclock.c@1.82.1.1, 2009-04-29 01:35:25-04:00, stenn@whimsy.udel.edu +7 -7 + Fix the error return and syslog function ID in refclock_{param,ppsapi} + + util/ntp-keygen.c@1.54.1.1, 2009-04-29 01:37:24-04:00, stenn@whimsy.udel.edu +27 -16 + updates + +ChangeSet@1.1817.3.1, 2009-04-28 08:09:13-04:00, murray@pogo.udel.edu +2 -0 + refclock_hpgps.c: + Fix for bug 1090, bogus leapseconds + ChangeLog: + Fix for bug 1090, bogus leapseconds in refclock_hpgps + + ChangeLog@1.286.3.1, 2009-04-28 08:04:55-04:00, murray@pogo.udel.edu +1 -0 + Fix for bug 1090, bogus leapseconds in refclock_hpgps + + ntpd/refclock_hpgps.c@1.9, 2009-04-28 08:05:43-04:00, murray@pogo.udel.edu +12 -5 + Fix for bug 1090, bogus leapseconds + +ChangeSet@1.1817.2.2, 2009-04-28 08:23:30+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + dcfd.c: + tvsec -> tv_sec typo + + parseutil/dcfd.c@1.22, 2009-04-28 08:23:21+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + tvsec -> tv_sec typo + +ChangeSet@1.1816.1.2, 2009-04-28 07:00:17+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + ntp_parser.h, ntp_parser.c: + bison 2.4.1 generated files + + ntpd/ntp_parser.c@1.37, 2009-04-28 07:00:10+00:00, davehart@shiny.ad.hartbrothers.com +372 -214 + bison 2.4.1 generated files + + ntpd/ntp_parser.h@1.21, 2009-04-28 07:00:11+00:00, davehart@shiny.ad.hartbrothers.com +159 -1 + bison 2.4.1 generated files + +ChangeSet@1.1816.1.1, 2009-04-28 06:59:44+00:00, davehart@shiny.ad.hartbrothers.com +40 -0 + [Bug 1169] quiet compiler warnings + Re-enable gcc -Wstrict-prototypes when not building with OpenSSL + Enable gcc -Wstrict-overflow + ntpq/ntpdc emit newline after accepting password on Windows + + ChangeLog@1.285.1.1, 2009-04-28 06:59:31+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + * [Bug 1169] quiet compiler warnings + * Re-enable gcc -Wstrict-prototypes when not building with OpenSSL + * Enable gcc -Wstrict-overflow + * ntpq/ntpdc emit newline after accepting password on Windows + + + configure.ac@1.434.1.1, 2009-04-28 06:59:31+00:00, davehart@shiny.ad.hartbrothers.com +40 -26 + enable -Wstrict-overflow, use -Wno-strict-prototypes only w/OpenSSL + + gsoc_sntp/crypto.c@1.5, 2009-04-28 06:59:32+00:00, davehart@shiny.ad.hartbrothers.com +3 -3 + auth_init() local key_cnt shadowed global of same name + --- + add const qualifier to auth_init() keyfile argument + + gsoc_sntp/crypto.h@1.4, 2009-04-28 06:59:32+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + add const qualifier to auth_init() keyfile argument + + gsoc_sntp/kod_management.c@1.8, 2009-04-28 06:59:32+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + add const qualifier to kod_db_file, kod_init_kod_db() arg + + gsoc_sntp/kod_management.h@1.5, 2009-04-28 06:59:32+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + add const qualifier to kod_db_file, kod_init_kod_db() arg + + gsoc_sntp/log.c@1.8, 2009-04-28 06:59:32+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + add const qualifier + + gsoc_sntp/log.h@1.5, 2009-04-28 06:59:32+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + add const qualifier + + gsoc_sntp/main.c@1.12, 2009-04-28 06:59:33+00:00, davehart@shiny.ad.hartbrothers.com +4 -3 + #include for isc_net_probeipv6 prototype + --- + remove three casts with const qualifiers fixed + + gsoc_sntp/networking.c@1.18, 2009-04-28 06:59:33+00:00, davehart@shiny.ad.hartbrothers.com +7 -17 + remove unused sockaddr_in, sockaddr_in6 + --- + char *buf shadowed declaration warning, printf %li not %i + --- + two more char *buf shadowy declarations + + include/isc/file.h@1.2, 2009-04-28 06:59:33+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + change parameter name in prototype from time to mtime to avoid (noisy) + warning about shadowing another "time" declaration + + include/isc/mem.h@1.3, 2009-04-28 06:59:34+00:00, davehart@shiny.ad.hartbrothers.com +10 -5 + macro away troublesom isc_mem_t incomplete type warnings + --- + #include (probably redundant with ) + + include/ntp_config.h@1.51, 2009-04-28 06:59:33+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + prototype destroy_address_node() + + include/ntp_stdlib.h@1.28, 2009-04-28 06:59:33+00:00, davehart@shiny.ad.hartbrothers.com +5 -5 + indent, whitespace cleanup + + include/ntpsim.h@1.10, 2009-04-28 06:59:33+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + prototype entrypoint ntpsim(argc, argv) + + libisc/inet_ntop.c@1.5, 2009-04-28 06:59:34+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + conditionalize code to match header + + libisc/inet_pton.c@1.2, 2009-04-28 06:59:34+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + conditionalize code to match header + + libisc/mem.c@1.3, 2009-04-28 06:59:34+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + note disuse of mem.c + + libntp/Makefile.am@1.42, 2009-04-28 06:59:34+00:00, davehart@shiny.ad.hartbrothers.com +2 -4 + let's see if libisc/log.c is really used + --- + remove mem.c from build in favor of isc/mem.h macros + + libntp/machines.c@1.20, 2009-04-28 06:59:34+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + emit newline after ntpq/ntpdc passwd prompt on Windows + + libntp/numtoa.c@1.3, 2009-04-28 06:59:35+00:00, davehart@shiny.ad.hartbrothers.com +8 -0 + include config.h, netinet/in.h for htonl + + libntp/numtohost.c@1.4, 2009-04-28 06:59:35+00:00, davehart@shiny.ad.hartbrothers.com +8 -0 + include config.h, netinet/in.h for htonl + + libntp/prettydate.c@1.12, 2009-04-28 06:59:35+00:00, davehart@shiny.ad.hartbrothers.com +3 -1 + prototype common_prettydate() + + libntp/statestr.c@1.15, 2009-04-28 06:59:35+00:00, davehart@shiny.ad.hartbrothers.com +5 -1 + flash_codes unused, see ntpq.c tstflagnames + + libparse/parsesolaris.c@1.8, 2009-04-28 06:59:35+00:00, davehart@shiny.ad.hartbrothers.com +12 -12 + ctime -> c_time to quiet shadowed declaration warning + remove const from pprintf format string to match use + + ntpd/ntp_config.c@1.191, 2009-04-28 06:59:36+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + missed DESTROY_QUEUE(unpeers) in merge into 1165 repo + --- + quiet compiler warning about unused get_next_address for !SIM + + ntpd/ntp_intres.c@1.59, 2009-04-28 06:59:36+00:00, davehart@shiny.ad.hartbrothers.com +0 -1 + ding dong, the bong is dead. (remove unused bong() prototype) + + ntpd/ntp_parser.y@1.32, 2009-04-28 06:59:36+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + missing semicolons on Unpeer, Unconfig trip up original yacc, bison -y + + ntpd/ntp_refclock.c@1.83, 2009-04-28 06:59:36+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + quiet two warnings comparing scalar ap->handle with pointer NULL + + ntpd/ntp_util.c@1.69, 2009-04-28 06:59:36+00:00, davehart@shiny.ad.hartbrothers.com +7 -0 + prototype uninit_util() + + ntpd/ntpsim.c@1.20, 2009-04-28 06:59:37+00:00, davehart@shiny.ad.hartbrothers.com +0 -1 + prototype entry point ntpsim(argc, argv) moves to ntpdsim.h + + ntpd/refclock_mx4200.c@1.24, 2009-04-28 06:59:37+00:00, davehart@shiny.ad.hartbrothers.com +12 -12 + %lu not %ul printf format specifier + local leapsec -> leapsec_warn to avoid shadowing global leapsec + + ntpd/refclock_palisade.c@1.24, 2009-04-28 06:59:37+00:00, davehart@shiny.ad.hartbrothers.com +5 -3 + wrap dead sendcmd() in #ifdef UNUSED + + ntpd/refclock_palisade.h@1.11, 2009-04-28 06:59:37+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + wrap sendcmd() prototype with #ifdef UNUSED + + ntpq/ntpq.c@1.83, 2009-04-28 06:59:37+00:00, davehart@shiny.ad.hartbrothers.com +181 -162 + conditionalize VxWorks-only clear_globals so it doesn't compile others + --- + quiet warnings building ntpq.c for libntpq, getcmds and abortcmd + --- + quiet tokenize, getarg defined but not used for libntpq + --- + quiet xcp possibly uninitialized in help + clean up indents, whitespace + + parseutil/dcfd.c@1.21, 2009-04-28 06:59:38+00:00, davehart@shiny.ad.hartbrothers.com +5 -4 + use explicit offset test rather than timercmp() to avoid 'simplifying + conditional to constant' warning with -Wstrict-overflow from testing if + constant 0 max_adj_offset.tv_sec is greater than something else. + + ports/winnt/libntp/libntp.vcproj@1.4, 2009-04-28 06:59:38+00:00, davehart@shiny.ad.hartbrothers.com +0 -22 + remove libisc/mem.c from build in favor of isc/mem.h macros + + ports/winnt/ntpd/ntpd.vcproj@1.2, 2009-04-28 06:59:38+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add reference to ntpsim.h + + ports/winnt/ntpd/ntservice.c@1.16, 2009-04-28 06:59:38+00:00, davehart@shiny.ad.hartbrothers.com +5 -5 + correct #ifdefs for leak debugging + + util/ntp-keygen.c@1.55, 2009-04-28 06:59:39+00:00, davehart@shiny.ad.hartbrothers.com +7 -7 + use strdup to get non-const copies of string args + cast time_t to long/u_long explicitly for 64-bit time_t + +ChangeSet@1.1436.15.46, 2009-04-27 11:47:49+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ChangeLog: + add [Bug 1167] to ChangeLog entry + + ChangeLog@1.1.1.72, 2009-04-27 11:47:36+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + add [Bug 1167] to ChangeLog entry + +ChangeSet@1.1817.1.2, 2009-04-26 14:17:47+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + Remove truncation of position (blanking) code in refclock_nmea.c + + ChangeLog@1.286.1.2, 2009-04-26 14:17:45+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + Remove truncation of position (blanking) code in refclock_nmea.c + + ntpd/refclock_nmea.c@1.34, 2009-04-26 14:17:45+00:00, davehart@shiny.ad.hartbrothers.com +1 -71 + Remove truncation of position (blanking) code in refclock_nmea.c + +ChangeSet@1.1817.1.1, 2009-04-26 07:54:41-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P167 + TAG: NTP_4_2_5P167 + + ChangeLog@1.286.1.1, 2009-04-26 07:54:15-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P167 + + gsoc_sntp/sntp-opts.c@1.28, 2009-04-26 07:54:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P167 + + gsoc_sntp/sntp-opts.h@1.28, 2009-04-26 07:54:17-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P167 + + gsoc_sntp/sntp-opts.texi@1.28, 2009-04-26 07:54:18-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P167 + + gsoc_sntp/sntp.1@1.28, 2009-04-26 07:54:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P167 + + ntpd/ntpd-opts.c@1.159, 2009-04-26 07:54:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P167 + + ntpd/ntpd-opts.h@1.159, 2009-04-26 07:54:20-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P167 + + ntpd/ntpd-opts.texi@1.158, 2009-04-26 07:54:21-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P167 + + ntpd/ntpd.1@1.158, 2009-04-26 07:54:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P167 + + ntpdc/ntpdc-opts.c@1.155, 2009-04-26 07:54:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P167 + + ntpdc/ntpdc-opts.h@1.155, 2009-04-26 07:54:23-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P167 + + ntpdc/ntpdc-opts.texi@1.154, 2009-04-26 07:54:24-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P167 + + ntpdc/ntpdc.1@1.154, 2009-04-26 07:54:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P167 + + ntpq/ntpq-opts.c@1.155, 2009-04-26 07:54:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P167 + + ntpq/ntpq-opts.h@1.155, 2009-04-26 07:54:26-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P167 + + ntpq/ntpq-opts.texi@1.154, 2009-04-26 07:54:27-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P167 + + ntpq/ntpq.1@1.154, 2009-04-26 07:54:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P167 + + ntpsnmpd/ntpsnmpd-opts.c@1.36, 2009-04-26 07:54:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P167 + + ntpsnmpd/ntpsnmpd-opts.h@1.36, 2009-04-26 07:54:29-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P167 + + ntpsnmpd/ntpsnmpd-opts.texi@1.36, 2009-04-26 07:54:30-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P167 + + ntpsnmpd/ntpsnmpd.1@1.36, 2009-04-26 07:54:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P167 + + packageinfo.sh@1.170, 2009-04-26 07:54:31-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P167 + + sntp/sntp-opts.c@1.155, 2009-04-26 07:54:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P167 + + sntp/sntp-opts.h@1.155, 2009-04-26 07:54:33-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P167 + + sntp/sntp-opts.texi@1.154, 2009-04-26 07:54:34-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P167 + + sntp/sntp.1@1.154, 2009-04-26 07:54:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P167 + + util/ntp-keygen-opts.c@1.158, 2009-04-26 07:54:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P167 + + util/ntp-keygen-opts.h@1.158, 2009-04-26 07:54:36-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P167 + + util/ntp-keygen-opts.texi@1.157, 2009-04-26 07:54:37-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P167 + + util/ntp-keygen.1@1.157, 2009-04-26 07:54:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P167 + +ChangeSet@1.1819, 2009-04-26 06:18:21+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + NTP_LINEEDITLIBS refinements for Autoconf 2.62 warnings + + ChangeLog@1.288, 2009-04-26 06:18:20+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + NTP_LINEEDITLIBS refinements for Autoconf 2.62 warnings + + m4/ntp_lineeditlibs.m4@1.4, 2009-04-26 06:18:20+00:00, davehart@shiny.ad.hartbrothers.com +46 -40 + NTP_LINEEDITLIBS refinements for Autoconf 2.62 warnings + +ChangeSet@1.1436.15.45, 2009-04-26 06:10:27+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + gcc -Winit-self is used only if it is understood + + ChangeLog@1.1.1.71, 2009-04-26 06:10:25+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + gcc -Winit-self is used only if it is understood + + configure.ac@1.400.1.12, 2009-04-26 06:10:26+00:00, davehart@shiny.ad.hartbrothers.com +34 -2 + gcc -Winit-self is used only if it is understood + +ChangeSet@1.1817, 2009-04-25 20:02:54-04:00, stenn@whimsy.udel.edu +3 -0 + Crypto cleanup from Dave Mills + + ChangeLog@1.286, 2009-04-25 20:02:42-04:00, stenn@whimsy.udel.edu +1 -0 + Crypto cleanup from Dave Mills + + ntpd/ntp_crypto.c@1.131, 2009-04-25 20:02:03-04:00, stenn@whimsy.udel.edu +4 -6 + Crypto cleanup from Dave Mills + + ntpd/ntp_proto.c@1.282, 2009-04-25 20:02:07-04:00, stenn@whimsy.udel.edu +16 -11 + Crypto cleanup from Dave Mills + +ChangeSet@1.1816, 2009-04-25 07:55:55-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P166 + TAG: NTP_4_2_5P166 + + ChangeLog@1.285, 2009-04-25 07:55:26-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P166 + + gsoc_sntp/sntp-opts.c@1.27, 2009-04-25 07:55:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P166 + + gsoc_sntp/sntp-opts.h@1.27, 2009-04-25 07:55:29-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P166 + + gsoc_sntp/sntp-opts.texi@1.27, 2009-04-25 07:55:30-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P166 + + gsoc_sntp/sntp.1@1.27, 2009-04-25 07:55:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P166 + + ntpd/ntpd-opts.c@1.158, 2009-04-25 07:55:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P166 + + ntpd/ntpd-opts.h@1.158, 2009-04-25 07:55:32-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P166 + + ntpd/ntpd-opts.texi@1.157, 2009-04-25 07:55:32-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P166 + + ntpd/ntpd.1@1.157, 2009-04-25 07:55:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P166 + + ntpdc/ntpdc-opts.c@1.154, 2009-04-25 07:55:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P166 + + ntpdc/ntpdc-opts.h@1.154, 2009-04-25 07:55:35-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P166 + + ntpdc/ntpdc-opts.texi@1.153, 2009-04-25 07:55:35-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P166 + + ntpdc/ntpdc.1@1.153, 2009-04-25 07:55:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P166 + + ntpq/ntpq-opts.c@1.154, 2009-04-25 07:55:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P166 + + ntpq/ntpq-opts.h@1.154, 2009-04-25 07:55:38-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P166 + + ntpq/ntpq-opts.texi@1.153, 2009-04-25 07:55:39-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P166 + + ntpq/ntpq.1@1.153, 2009-04-25 07:55:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P166 + + ntpsnmpd/ntpsnmpd-opts.c@1.35, 2009-04-25 07:55:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P166 + + ntpsnmpd/ntpsnmpd-opts.h@1.35, 2009-04-25 07:55:41-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P166 + + ntpsnmpd/ntpsnmpd-opts.texi@1.35, 2009-04-25 07:55:42-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P166 + + ntpsnmpd/ntpsnmpd.1@1.35, 2009-04-25 07:55:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P166 + + packageinfo.sh@1.169, 2009-04-25 07:55:43-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P166 + + sntp/sntp-opts.c@1.154, 2009-04-25 07:55:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P166 + + sntp/sntp-opts.h@1.154, 2009-04-25 07:55:44-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P166 + + sntp/sntp-opts.texi@1.153, 2009-04-25 07:55:44-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P166 + + sntp/sntp.1@1.153, 2009-04-25 07:55:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P166 + + util/ntp-keygen-opts.c@1.157, 2009-04-25 07:55:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P166 + + util/ntp-keygen-opts.h@1.157, 2009-04-25 07:55:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P166 + + util/ntp-keygen-opts.texi@1.156, 2009-04-25 07:55:48-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P166 + + util/ntp-keygen.1@1.156, 2009-04-25 07:55:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P166 + +ChangeSet@1.1815, 2009-04-25 08:22:13+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + bison products + + ntpd/ntp_parser.c@1.36, 2009-04-25 08:22:11+00:00, davehart@shiny.ad.hartbrothers.com +649 -373 + generated from [Bug 1165] ChangeSet's ntp_parser.y + + ntpd/ntp_parser.h@1.20, 2009-04-25 08:22:12+00:00, davehart@shiny.ad.hartbrothers.com +25 -177 + generated from [Bug 1165] ChangeSet's ntp_parser.y + +ChangeSet@1.1807.2.1, 2009-04-25 08:08:01+00:00, davehart@shiny.ad.hartbrothers.com +17 -0 + * [Bug 1165] Clean up small memory leaks in the config file parser + * Correct logconfig keyword declaration to MULTIPLE_ARG + * Enable filename and line number leak reporting on Windows when built + DEBUG for all the typical C runtime allocators such as calloc, + malloc, and strdup. Previously only emalloc calls were covered. + * Add DEBUG-only code to free dynamically allocated memory that would + otherwise remain allocated at ntpd exit, to allow less forgivable + leaks to stand out in leaks reported after exit. + * Ensure termination of strings in ports/winnt/libisc/isc_strerror.c + and quiet compiler warnings. + + + ChangeLog@1.280.2.1, 2009-04-25 08:07:56+00:00, davehart@shiny.ad.hartbrothers.com +10 -0 + [Bug 1165] config parser leak + logconfig keyword correction + DEBUG-only freeing of allocated memory at exit + Windows CRT leak debugging enhanced + isc_strerror compile warnings quieted + + include/ntp_filegen.h@1.5, 2009-04-25 08:07:56+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + DEBUG-only freeing of allocated memory at exit + + include/ntp_stdlib.h@1.27, 2009-04-25 08:07:56+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + Windows CRT leak debugging enhanced + + include/ntpd.h@1.121.1.1, 2009-04-25 08:07:56+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + no const qualifier for ntp_signd_socket matches parser return types + + libntp/emalloc.c@1.6, 2009-04-25 08:07:56+00:00, davehart@shiny.ad.hartbrothers.com +17 -18 + Windows CRT leak debugging enhanced + + libntp/msyslog.c@1.21, 2009-04-25 08:07:56+00:00, davehart@shiny.ad.hartbrothers.com +7 -4 + use errno for msyslog on Windows if (NO_ERROR == GetLastError()) + + ntpd/ntp_config.c@1.188.1.1, 2009-04-25 08:07:56+00:00, davehart@shiny.ad.hartbrothers.com +152 -60 + [Bug 1165] config parser leak + logconfig keyword correction + DEBUG-only freeing of allocated memory at exit + + ntpd/ntp_data_structures.c@1.7, 2009-04-25 08:07:57+00:00, davehart@shiny.ad.hartbrothers.com +5 -10 + C doesn't require casts from void *, emalloc doesn't return NULL + + ntpd/ntp_filegen.c@1.14, 2009-04-25 08:07:57+00:00, davehart@shiny.ad.hartbrothers.com +8 -6 + DEBUG-only freeing of allocated memory at exit + + ntpd/ntp_parser.y@1.29.1.1, 2009-04-25 08:07:57+00:00, davehart@shiny.ad.hartbrothers.com +10 -8 + [Bug 1165] config parser leak + + ntpd/ntp_scanner.c@1.19, 2009-04-25 08:07:57+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + DEBUG-only freeing of allocated memory at exit + + ntpd/ntp_scanner.h@1.5, 2009-04-25 08:07:57+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + DEBUG-only freeing of allocated memory at exit + + ntpd/ntp_util.c@1.68, 2009-04-25 08:07:57+00:00, davehart@shiny.ad.hartbrothers.com +49 -12 + DEBUG-only freeing of allocated memory at exit + + ports/winnt/include/config.h@1.62, 2009-04-25 08:07:57+00:00, davehart@shiny.ad.hartbrothers.com +10 -1 + Windows CRT leak debugging enhanced + + ports/winnt/libisc/isc_strerror.c@1.7, 2009-04-25 08:07:58+00:00, davehart@shiny.ad.hartbrothers.com +137 -31 + ensure NULL termination of error messages + quiet compiler warnings + + ports/winnt/libntp/randfile.c@1.4, 2009-04-25 08:07:58+00:00, davehart@shiny.ad.hartbrothers.com +1 -6 + quiet compiler warnings by including config.h + + ports/winnt/ntpd/ntservice.c@1.15, 2009-04-25 08:07:58+00:00, davehart@shiny.ad.hartbrothers.com +22 -7 + DEBUG-only freeing of allocated memory at exit + +ChangeSet@1.1807.1.2, 2009-04-25 00:34:16-04:00, stenn@whimsy.udel.edu +2 -0 + PPS and crypto cleanup in ntp_proto.c from Dave Mills + + ChangeLog@1.280.1.1, 2009-04-25 00:33:49-04:00, stenn@whimsy.udel.edu +1 -0 + PPS and crypto cleanup in ntp_proto.c from Dave Mills + + ntpd/ntp_proto.c@1.281, 2009-04-25 00:33:27-04:00, stenn@whimsy.udel.edu +3 -3 + PPS and crypto cleanup in ntp_proto.c from Dave Mills + +ChangeSet@1.1812, 2009-04-24 00:01:08+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + bison-generated files from ntp_parser.y for [Bug 1161] + + ntpd/ntp_parser.c@1.35, 2009-04-24 00:01:07+00:00, davehart@shiny.ad.hartbrothers.com +949 -914 + bison-generated files from ntp_parser.y + + ntpd/ntp_parser.h@1.19, 2009-04-24 00:01:07+00:00, davehart@shiny.ad.hartbrothers.com +39 -35 + bison-generated files from ntp_parser.y + +ChangeSet@1.1811, 2009-04-23 23:58:33+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + Many files: + [Bug 1161] unpeer AKA unconfig command for ntpq :config + + ChangeLog@1.282, 2009-04-23 23:58:31+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1161] unpeer AKA unconfig command for ntpq :config + + include/ntp_config.h@1.50, 2009-04-23 23:58:31+00:00, davehart@shiny.ad.hartbrothers.com +6 -0 + [Bug 1161] unpeer AKA unconfig command for ntpq :config + + ntpd/ntp_config.c@1.189, 2009-04-23 23:58:31+00:00, davehart@shiny.ad.hartbrothers.com +104 -8 + [Bug 1161] unpeer AKA unconfig command for ntpq :config + + ntpd/ntp_parser.y@1.30, 2009-04-23 23:58:31+00:00, davehart@shiny.ad.hartbrothers.com +23 -1 + [Bug 1161] unpeer AKA unconfig command for ntpq :config + +ChangeSet@1.1809, 2009-04-23 19:45:43+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ChangeLog: + [Bug 1057] ntpdc unconfig failure + + ChangeLog@1.279.1.1, 2009-04-23 19:45:33+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1057] ntpdc unconfig failure + +ChangeSet@1.1807.1.1, 2009-04-23 08:03:28-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P165 + TAG: NTP_4_2_5P165 + + ChangeLog@1.280, 2009-04-23 08:03:01-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P165 + + gsoc_sntp/sntp-opts.c@1.26, 2009-04-23 08:03:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P165 + + gsoc_sntp/sntp-opts.h@1.26, 2009-04-23 08:03:03-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P165 + + gsoc_sntp/sntp-opts.texi@1.26, 2009-04-23 08:03:03-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P165 + + gsoc_sntp/sntp.1@1.26, 2009-04-23 08:03:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P165 + + ntpd/ntpd-opts.c@1.157, 2009-04-23 08:03:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P165 + + ntpd/ntpd-opts.h@1.157, 2009-04-23 08:03:05-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P165 + + ntpd/ntpd-opts.texi@1.156, 2009-04-23 08:03:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P165 + + ntpd/ntpd.1@1.156, 2009-04-23 08:03:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P165 + + ntpdc/ntpdc-opts.c@1.153, 2009-04-23 08:03:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P165 + + ntpdc/ntpdc-opts.h@1.153, 2009-04-23 08:03:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P165 + + ntpdc/ntpdc-opts.texi@1.152, 2009-04-23 08:03:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P165 + + ntpdc/ntpdc.1@1.152, 2009-04-23 08:03:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P165 + + ntpq/ntpq-opts.c@1.153, 2009-04-23 08:03:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P165 + + ntpq/ntpq-opts.h@1.153, 2009-04-23 08:03:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P165 + + ntpq/ntpq-opts.texi@1.152, 2009-04-23 08:03:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P165 + + ntpq/ntpq.1@1.152, 2009-04-23 08:03:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P165 + + ntpsnmpd/ntpsnmpd-opts.c@1.34, 2009-04-23 08:03:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P165 + + ntpsnmpd/ntpsnmpd-opts.h@1.34, 2009-04-23 08:03:15-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P165 + + ntpsnmpd/ntpsnmpd-opts.texi@1.34, 2009-04-23 08:03:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P165 + + ntpsnmpd/ntpsnmpd.1@1.34, 2009-04-23 08:03:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P165 + + packageinfo.sh@1.168, 2009-04-23 08:03:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P165 + + sntp/sntp-opts.c@1.153, 2009-04-23 08:03:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P165 + + sntp/sntp-opts.h@1.153, 2009-04-23 08:03:18-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P165 + + sntp/sntp-opts.texi@1.152, 2009-04-23 08:03:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P165 + + sntp/sntp.1@1.152, 2009-04-23 08:03:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P165 + + util/ntp-keygen-opts.c@1.156, 2009-04-23 08:03:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P165 + + util/ntp-keygen-opts.h@1.156, 2009-04-23 08:03:21-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P165 + + util/ntp-keygen-opts.texi@1.155, 2009-04-23 08:03:22-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P165 + + util/ntp-keygen.1@1.155, 2009-04-23 08:03:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P165 + +ChangeSet@1.1808, 2009-04-23 11:51:56+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1057] partial fix, re-enable ntpdc unconfig + + include/ntpd.h@1.122, 2009-04-23 11:51:54+00:00, davehart@shiny.ad.hartbrothers.com +2 -3 + [Bug 1057] partial fix, re-enable ntpdc unconfig + + ntpd/ntp_peer.c@1.116, 2009-04-23 11:51:54+00:00, davehart@shiny.ad.hartbrothers.com +0 -15 + [Bug 1057] partial fix, re-enable ntpdc unconfig + + ntpd/ntp_request.c@1.77, 2009-04-23 11:51:55+00:00, davehart@shiny.ad.hartbrothers.com +26 -16 + [Bug 1057] partial fix, re-enable ntpdc unconfig + +ChangeSet@1.1807, 2009-04-23 06:42:56-04:00, stenn@whimsy.udel.edu +2 -0 + WWVB refclock cleanup from Dave Mills + + ChangeLog@1.279, 2009-04-23 06:42:41-04:00, stenn@whimsy.udel.edu +1 -0 + WWVB refclock cleanup from Dave Mills + + ntpd/refclock_wwvb.c@1.21, 2009-04-23 06:42:19-04:00, stenn@whimsy.udel.edu +3 -3 + WWVB refclock cleanup from Dave Mills + +ChangeSet@1.1806, 2009-04-23 06:35:25-04:00, stenn@whimsy.udel.edu +6 -0 + Code cleanup: requested_key -> request_key + + ChangeLog@1.278, 2009-04-23 06:28:55-04:00, stenn@whimsy.udel.edu +1 -0 + Code cleanup: requested_key -> request_key + + include/ntp_config.h@1.49, 2009-04-23 06:29:05-04:00, stenn@whimsy.udel.edu +1 -1 + Code cleanup: requested_key -> request_key + + ntpd/ntp_config.c@1.188, 2009-04-23 06:34:41-04:00, stenn@whimsy.udel.edu +4 -4 + Code cleanup: requested_key -> request_key + + ntpd/ntp_parser.c@1.34, 2009-04-23 06:33:56-04:00, stenn@whimsy.udel.edu +5 -5 + Code cleanup: requested_key -> request_key + + ntpd/ntp_parser.h@1.18, 2009-04-23 06:34:00-04:00, stenn@whimsy.udel.edu +2 -2 + Code cleanup: requested_key -> request_key + + ntpd/ntp_parser.y@1.29, 2009-04-23 06:34:01-04:00, stenn@whimsy.udel.edu +1 -1 + Code cleanup: requested_key -> request_key + +ChangeSet@1.1801.1.6, 2009-04-23 08:23:49+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ChangeLog: + belated ntp_parser.y malloc redeclaration entry + + ChangeLog@1.273.1.2, 2009-04-23 08:23:43+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + belated ntp_parser.y malloc redeclaration entry + +ChangeSet@1.1801.1.5, 2009-04-23 08:18:08+00:00, hart@pogo.udel.edu +2 -0 + ntp_parser.c: + generated from updated ntp_parser.y by bison 2.3 + ntp_parser.h: + force a null delta to keep this file newer than ntp_parser.y + + ntpd/ntp_parser.c@1.33, 2009-04-23 08:17:50+00:00, hart@pogo.udel.edu +365 -355 + generated from updated ntp_parser.y by bison 2.3 + + ntpd/ntp_parser.h@1.17, 2009-04-23 08:15:04+00:00, hart@pogo.udel.edu +0 -0 + force a null delta to keep this file newer than ntp_parser.y + +ChangeSet@1.1801.1.4, 2009-04-23 08:08:30+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ntp_parser.y: + quiet malloc redeclaration warning compiling ntp_parser.c + + ntpd/ntp_parser.y@1.28, 2009-04-23 08:08:23+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + quiet malloc redeclaration warning compiling ntp_parser.c + +ChangeSet@1.1804, 2009-04-23 03:43:50-04:00, stenn@whimsy.udel.edu +1 -0 + cleanup + + ChangeLog@1.276, 2009-04-23 03:43:38-04:00, stenn@whimsy.udel.edu +2 -1 + cleanup + +ChangeSet@1.1801.1.3, 2009-04-23 07:31:41+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + allow OpenSSL DLLs' C runtime version to differ from ntpq's and ntpdc's + [Bug 833] ignore whitespace at end of remote configuration lines + [Bug 1033] ntpdc/ntpq crash prompting for keyid on Windows + + ChangeLog@1.273.1.1, 2009-04-23 07:31:39+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 833] ignore whitespace at end of remote configuration lines + [Bug 1033] ntpdc/ntpq crash prompting for keyid on Windows + + ntpd/ntp_scanner.c@1.18, 2009-04-23 07:31:39+00:00, davehart@shiny.ad.hartbrothers.com +14 -3 + [Bug 833] ignore whitespace at end of remote configuration lines + + ntpdc/ntpdc.c@1.61, 2009-04-23 07:31:39+00:00, davehart@shiny.ad.hartbrothers.com +7 -1 + allow OpenSSL DLLs' C runtime version to differ from ntpdc's + [Bug 1033] ntpdc/ntpq crash prompting for keyid on Windows + + ntpq/ntpq.c@1.82, 2009-04-23 07:31:39+00:00, davehart@shiny.ad.hartbrothers.com +7 -1 + allow OpenSSL DLLs' C runtime version to differ from ntpq's + [Bug 1033] ntpdc/ntpq crash prompting for keyid on Windows + +ChangeSet@1.1801.1.2, 2009-04-23 07:04:18+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ntp_scanner.c: + quiet type conversion warnings, do not push back EOF + + ntpd/ntp_scanner.c@1.17, 2009-04-23 07:04:08+00:00, davehart@shiny.ad.hartbrothers.com +10 -11 + quiet type conversion warnings, do not push back EOF + +ChangeSet@1.1801.1.1, 2009-04-23 06:59:15+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + ntp_parser.y, ntp_scanner.c: + whitespace and indent cleanup only + + ntpd/ntp_parser.y@1.27, 2009-04-23 06:59:07+00:00, davehart@shiny.ad.hartbrothers.com +516 -510 + whitespace and indent cleanup only + + ntpd/ntp_scanner.c@1.16, 2009-04-23 06:59:07+00:00, davehart@shiny.ad.hartbrothers.com +47 -50 + whitespace and indent cleanup only + +ChangeSet@1.1796.12.31, 2009-04-22 18:33:43-04:00, stenn@whimsy.udel.edu +2 -0 + Documentation updates from Dave Mills + + html/drivers/driver22.html@1.18, 2009-04-22 18:30:12-04:00, stenn@whimsy.udel.edu +76 -27 + Documentation updates from Dave Mills + + html/drivers/driver4.html@1.14, 2009-04-22 18:30:16-04:00, stenn@whimsy.udel.edu +103 -60 + Documentation updates from Dave Mills + +ChangeSet@1.1796.12.30, 2009-04-22 18:26:09-04:00, stenn@whimsy.udel.edu +4 -0 + Documentation updates from Dave Mills + + ChangeLog@1.268.11.16, 2009-04-22 18:24:40-04:00, stenn@whimsy.udel.edu +1 -0 + Mitigation and PPS/PPSAPI cleanup from Dave Mills + + ntpd/ntp_proto.c@1.276.1.5, 2009-04-22 18:24:52-04:00, stenn@whimsy.udel.edu +2 -1 + Mitigation and PPS/PPSAPI cleanup from Dave Mills + + ntpd/refclock_atom.c@1.59, 2009-04-22 18:24:58-04:00, stenn@whimsy.udel.edu +21 -11 + Mitigation and PPS/PPSAPI cleanup from Dave Mills + + ntpd/refclock_wwvb.c@1.20, 2009-04-22 18:25:06-04:00, stenn@whimsy.udel.edu +30 -6 + Mitigation and PPS/PPSAPI cleanup from Dave Mills + +ChangeSet@1.1796.12.29, 2009-04-22 18:20:19-04:00, stenn@whimsy.udel.edu +3 -0 + Documentation updates from Dave Mills + + ChangeLog@1.268.11.15, 2009-04-22 18:20:03-04:00, stenn@whimsy.udel.edu +1 -0 + Documentation updates from Dave Mills + + html/miscopt.html@1.42, 2009-04-22 18:18:38-04:00, stenn@whimsy.udel.edu +2 -2 + Documentation updates from Dave Mills + + html/prefer.html@1.20, 2009-04-22 18:18:41-04:00, stenn@whimsy.udel.edu +36 -11 + Documentation updates from Dave Mills + +ChangeSet@1.1796.12.28, 2009-04-22 18:14:48-04:00, stenn@whimsy.udel.edu +2 -0 + timepps-Solaris.h patches from Dave Hart + + ChangeLog@1.268.11.14, 2009-04-22 18:14:34-04:00, stenn@whimsy.udel.edu +1 -0 + timepps-Solaris.h patches from Dave Hart + + include/timepps-Solaris.h@1.5, 2009-04-22 18:14:09-04:00, stenn@whimsy.udel.edu +68 -19 + timepps-Solaris.h patches from Dave Hart + +ChangeSet@1.1796.12.27, 2009-04-22 10:38:59-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P164 + TAG: NTP_4_2_5P164 + + ChangeLog@1.268.11.13, 2009-04-22 10:38:05-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P164 + + gsoc_sntp/sntp-opts.c@1.25, 2009-04-22 10:38:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P164 + + gsoc_sntp/sntp-opts.h@1.25, 2009-04-22 10:38:09-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P164 + + gsoc_sntp/sntp-opts.texi@1.25, 2009-04-22 10:38:10-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P164 + + gsoc_sntp/sntp.1@1.25, 2009-04-22 10:38:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P164 + + ntpd/ntpd-opts.c@1.156, 2009-04-22 10:38:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P164 + + ntpd/ntpd-opts.h@1.156, 2009-04-22 10:38:13-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P164 + + ntpd/ntpd-opts.texi@1.155, 2009-04-22 10:38:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P164 + + ntpd/ntpd.1@1.155, 2009-04-22 10:38:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P164 + + ntpdc/ntpdc-opts.c@1.152, 2009-04-22 10:38:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P164 + + ntpdc/ntpdc-opts.h@1.152, 2009-04-22 10:38:20-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P164 + + ntpdc/ntpdc-opts.texi@1.151, 2009-04-22 10:38:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P164 + + ntpdc/ntpdc.1@1.151, 2009-04-22 10:38:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P164 + + ntpq/ntpq-opts.c@1.152, 2009-04-22 10:38:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P164 + + ntpq/ntpq-opts.h@1.152, 2009-04-22 10:38:28-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P164 + + ntpq/ntpq-opts.texi@1.151, 2009-04-22 10:38:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P164 + + ntpq/ntpq.1@1.151, 2009-04-22 10:38:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P164 + + ntpsnmpd/ntpsnmpd-opts.c@1.33, 2009-04-22 10:38:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P164 + + ntpsnmpd/ntpsnmpd-opts.h@1.33, 2009-04-22 10:38:35-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P164 + + ntpsnmpd/ntpsnmpd-opts.texi@1.33, 2009-04-22 10:38:36-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P164 + + ntpsnmpd/ntpsnmpd.1@1.33, 2009-04-22 10:38:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P164 + + packageinfo.sh@1.167, 2009-04-22 10:38:38-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P164 + + sntp/sntp-opts.c@1.152, 2009-04-22 10:38:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P164 + + sntp/sntp-opts.h@1.152, 2009-04-22 10:38:41-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P164 + + sntp/sntp-opts.texi@1.151, 2009-04-22 10:38:42-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P164 + + sntp/sntp.1@1.151, 2009-04-22 10:38:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P164 + + util/ntp-keygen-opts.c@1.155, 2009-04-22 10:38:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P164 + + util/ntp-keygen-opts.h@1.155, 2009-04-22 10:38:45-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P164 + + util/ntp-keygen-opts.texi@1.154, 2009-04-22 10:38:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P164 + + util/ntp-keygen.1@1.154, 2009-04-22 10:38:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P164 + +ChangeSet@1.1436.15.44, 2009-04-22 08:18:29-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_4P7_RC3 + TAG: NTP_4_2_4P7_RC3 + + ChangeLog@1.1.1.70, 2009-04-22 08:18:04-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_4P7_RC3 + + ntpd/ntpd-opts.c@1.50.20.1, 2009-04-22 08:18:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC3 + + ntpd/ntpd-opts.h@1.50.20.1, 2009-04-22 08:18:05-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC3 + + ntpd/ntpd-opts.texi@1.49.20.1, 2009-04-22 08:18:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC3 + + ntpd/ntpd.1@1.48.20.1, 2009-04-22 08:18:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC3 + + ntpd/ntpdsim-opts.c@1.50.20.1, 2009-04-22 08:18:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC3 + + ntpd/ntpdsim-opts.h@1.50.20.1, 2009-04-22 08:18:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC3 + + ntpd/ntpdsim-opts.texi@1.48.20.1, 2009-04-22 08:18:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC3 + + ntpd/ntpdsim.1@1.48.20.1, 2009-04-22 08:18:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC3 + + ntpdc/ntpdc-opts.c@1.50.20.1, 2009-04-22 08:18:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC3 + + ntpdc/ntpdc-opts.h@1.50.20.1, 2009-04-22 08:18:11-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC3 + + ntpdc/ntpdc-opts.texi@1.48.20.1, 2009-04-22 08:18:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC3 + + ntpdc/ntpdc.1@1.48.20.1, 2009-04-22 08:18:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC3 + + ntpq/ntpq-opts.c@1.52.20.1, 2009-04-22 08:18:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC3 + + ntpq/ntpq-opts.h@1.52.20.1, 2009-04-22 08:18:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC3 + + ntpq/ntpq-opts.texi@1.49.20.1, 2009-04-22 08:18:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC3 + + ntpq/ntpq.1@1.48.20.1, 2009-04-22 08:18:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC3 + + packageinfo.sh@1.65.28.1, 2009-04-22 08:18:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC3 + + sntp/sntp-opts.c@1.49.20.1, 2009-04-22 08:18:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC3 + + sntp/sntp-opts.h@1.49.20.1, 2009-04-22 08:18:20-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC3 + + sntp/sntp-opts.texi@1.46.20.1, 2009-04-22 08:18:20-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC3 + + sntp/sntp.1@1.49.20.1, 2009-04-22 08:18:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC3 + + util/ntp-keygen-opts.c@1.49.20.1, 2009-04-22 08:18:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC3 + + util/ntp-keygen-opts.h@1.49.20.1, 2009-04-22 08:18:23-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC3 + + util/ntp-keygen-opts.texi@1.47.20.1, 2009-04-22 08:18:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC3 + + util/ntp-keygen.1@1.47.20.1, 2009-04-22 08:18:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC3 + +ChangeSet@1.1436.15.43, 2009-04-22 07:00:20-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1155] Fix compile problem on Windows with VS2005 + + ChangeLog@1.1.1.69, 2009-04-22 07:00:11-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1155] Fix compile problem on Windows with VS2005 + +ChangeSet@1.1436.15.42, 2009-04-22 06:06:53-04:00, stenn@whimsy.udel.edu +1 -0 + Cleanup + + ChangeLog@1.1.1.68, 2009-04-22 06:06:44-04:00, stenn@whimsy.udel.edu +4 -2 + Cleanup + +ChangeSet@1.1796.18.1, 2009-04-22 02:35:47-04:00, stenn@whimsy.udel.edu +12 -0 + PPS/PPSAPI cleanup from Dave Mills + + ChangeLog@1.268.16.2, 2009-04-22 02:35:29-04:00, stenn@whimsy.udel.edu +1 -0 + PPS/PPSAPI cleanup from Dave Mills + + ChangeLog@1.268.16.1, 2009-04-22 02:23:35-04:00, stenn@whimsy.udel.edu +1 -0 + Documentation updates from Dave Mills + + html/howto.html@1.21, 2009-04-22 02:22:45-04:00, stenn@whimsy.udel.edu +54 -41 + Documentation updates from Dave Mills + + html/prefer.html@1.19, 2009-04-22 02:22:49-04:00, stenn@whimsy.udel.edu +38 -31 + Documentation updates from Dave Mills + + include/Makefile.am@1.31, 2009-04-22 02:33:45-04:00, stenn@whimsy.udel.edu +1 -0 + PPS/PPSAPI cleanup from Dave Mills + + include/ntp.h@1.148.1.2, 2009-04-22 02:33:50-04:00, stenn@whimsy.udel.edu +2 -1 + PPS/PPSAPI cleanup from Dave Mills + + include/ntpd.h@1.118.2.1, 2009-04-22 02:33:57-04:00, stenn@whimsy.udel.edu +0 -1 + PPS/PPSAPI cleanup from Dave Mills + + include/refclock_atom.h@1.2, 2009-04-22 02:33:59-04:00, stenn@whimsy.udel.edu +1 -1 + PPS/PPSAPI cleanup from Dave Mills + + include/refclock_atom.h@1.1, 2009-04-19 23:15:06-04:00, stenn@whimsy.udel.edu +15 -0 + BitKeeper file /deacon/backroom/ntp-dev/include/refclock_atom.h + + include/refclock_atom.h@1.0, 2009-04-19 23:15:06-04:00, stenn@whimsy.udel.edu +0 -0 + + ntpd/ntp_proto.c@1.276.1.4, 2009-04-22 02:33:15-04:00, stenn@whimsy.udel.edu +30 -31 + PPS/PPSAPI cleanup from Dave Mills + + ntpd/ntp_refclock.c@1.82, 2009-04-22 02:33:18-04:00, stenn@whimsy.udel.edu +156 -0 + PPS/PPSAPI cleanup from Dave Mills + + ntpd/ntp_request.c@1.76, 2009-04-22 02:33:18-04:00, stenn@whimsy.udel.edu +6 -0 + PPS/PPSAPI cleanup from Dave Mills + + ntpd/refclock_atom.c@1.58, 2009-04-22 02:33:25-04:00, stenn@whimsy.udel.edu +38 -182 + PPS/PPSAPI cleanup from Dave Mills + + ntpd/refclock_wwvb.c@1.19, 2009-04-22 02:33:31-04:00, stenn@whimsy.udel.edu +30 -1 + PPS/PPSAPI cleanup from Dave Mills + +ChangeSet@1.1436.15.41, 2009-04-20 22:55:13+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ChangeLog: + auto merge not quite right + + ChangeLog@1.1.1.67, 2009-04-20 22:55:10+00:00, davehart@shiny.ad.hartbrothers.com +3 -7 + auto merge not quite right + +ChangeSet@1.1436.15.40, 2009-04-20 22:42:59+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ntp_iocompletionport.c: + revert overlooked CreateEvent naming/sharing change not conditionalized away already + + ports/winnt/ntpd/ntp_iocompletionport.c@1.21.1.11, 2009-04-20 22:42:50+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + revert overlooked CreateEvent naming/sharing change not conditionalized away already + +ChangeSet@1.1796.12.21, 2009-04-20 06:26:09+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ChangeLog: + merge cleanup + + ChangeLog@1.268.11.7, 2009-04-20 06:26:03+00:00, davehart@shiny.ad.hartbrothers.com +1 -3 + merge cleanup + +ChangeSet@1.1436.21.11, 2009-04-20 06:17:21+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ChangeLog: + [Bug 1160] Mac OS X is like BSD regarding F_SETOWN + + ChangeLog@1.1.16.3, 2009-04-20 06:17:15+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1160] Mac OS X is like BSD regarding F_SETOWN + +ChangeSet@1.1796.12.19, 2009-04-20 06:13:35+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + recvbuff.c: + ENSURE that get_free_recv_buffer_alloc does not return NULL + + libntp/recvbuff.c@1.29, 2009-04-20 06:13:25+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + ENSURE that get_free_recv_buffer_alloc does not return NULL + +ChangeSet@1.1436.21.10, 2009-04-20 06:02:20+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + configure.ac: + [Bug 1160] MacOS X is like BSD regarding F_SETOWN + + configure.ac@1.400.1.11, 2009-04-20 06:02:08+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1160] MacOS X is like BSD regarding F_SETOWN + +ChangeSet@1.1796.17.1, 2009-04-19 17:50:29+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + ntp_intres.c, ntpd.h, ChangeLog, ntp_config.c: + [Bug 1125] C runtime per-thread initialization on Windows + + ChangeLog@1.268.15.1, 2009-04-19 17:50:21+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1125] C runtime per-thread initialization on Windows + + include/ntpd.h@1.118.1.2, 2009-04-19 17:50:21+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Bug 1125] C runtime per-thread initialization on Windows + + ntpd/ntp_config.c@1.184.1.2, 2009-04-19 17:50:21+00:00, davehart@shiny.ad.hartbrothers.com +12 -11 + [Bug 1125] C runtime per-thread initialization on Windows + + ntpd/ntp_intres.c@1.58, 2009-04-19 17:50:21+00:00, davehart@shiny.ad.hartbrothers.com +16 -1 + [Bug 1125] C runtime per-thread initialization on Windows + +ChangeSet@1.1796.16.3, 2009-04-18 14:23:56+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ntpq.c: + fix false positive duplicate detection + + ntpq/ntpq.c@1.77.1.3, 2009-04-18 14:23:40+00:00, davehart@shiny.ad.hartbrothers.com +9 -3 + fix false positive duplicate detection + +ChangeSet@1.1796.16.2, 2009-04-18 13:51:18+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ntpq.c: + quiet gcc, msc type warnings from decodeint calls to [hex|oct]toint + + ntpq/ntpq.c@1.77.1.2, 2009-04-18 13:51:02+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + quiet gcc, msc type warnings from decodeint calls to [hex|oct]toint + +ChangeSet@1.1796.16.1, 2009-04-18 04:46:01+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + ntpq.c, ChangeLog: + [Bug 1159] ntpq overlap diagnostic message test buggy + + ChangeLog@1.268.14.1, 2009-04-18 04:45:52+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1159] ntpq overlap diagnostic message test buggy + + ntpq/ntpq.c@1.77.1.1, 2009-04-18 04:45:38+00:00, davehart@shiny.ad.hartbrothers.com +303 -266 + [Bug 1159] ntpq overlap diagnostic message test buggy + +ChangeSet@1.1796.15.1, 2009-04-16 19:09:05+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + configure.ac: + do not disable refclock_true (CLOCK_TRUETIME) due to pps_sample disappearance, relevant code is under CLOCK_PPS720 ifdef which only affects rare systems with pcl720.h present + + configure.ac@1.424.1.1, 2009-04-16 19:08:53+00:00, davehart@shiny.ad.hartbrothers.com +0 -1 + do not disable refclock_true (CLOCK_TRUETIME) due to pps_sample disappearance, relevant code is under CLOCK_PPS720 ifdef which only affects rare systems with pcl720.h present + +ChangeSet@1.1796.12.12, 2009-04-16 09:00:55+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + configure.ac: + revert too-long, incorrect option text change + + configure.ac@1.432, 2009-04-16 09:00:51+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + revert too-long, incorrect option text change + +ChangeSet@1.1436.21.9, 2009-04-16 02:39:01+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + configure.ac: + fix for --enable-ntp-signd=/my/path + + configure.ac@1.400.1.10, 2009-04-16 02:38:53+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + fix for --enable-ntp-signd=/my/path + +ChangeSet@1.1436.21.8, 2009-04-15 12:36:24+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + configure.ac: + do not cache options fix + + configure.ac@1.400.1.9, 2009-04-15 12:36:12+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + do not cache options fix + +ChangeSet@1.1796.12.9, 2009-04-15 11:21:07+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + configure.ac: + choosing compilers: use C99 if available, warn if C89 is not + + configure.ac@1.429, 2009-04-15 11:21:01+00:00, davehart@shiny.ad.hartbrothers.com +19 -9 + choosing compilers: use C99 if available, warn if C89 is not + + gsoc_sntp/configure.ac@1.13, 2009-04-15 11:21:01+00:00, davehart@shiny.ad.hartbrothers.com +15 -4 + choosing compilers: use C99 if available, warn if C89 is not + +ChangeSet@1.1436.21.7, 2009-04-15 10:43:51+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + configure.ac: + Do not cache configure --options, only current values matter + Default --enable-wintime when --enable-ntp-signd + + configure.ac@1.400.1.8, 2009-04-15 10:43:32+00:00, davehart@shiny.ad.hartbrothers.com +575 -403 + Do not cache configure --options, only current values matter + Default --enable-wintime when --enable-ntp-signd + +ChangeSet@1.1796.12.7, 2009-04-15 01:47:06+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + configure.ac: + switch AC_CHECK_LIB to AC_SEARCH_LIBS for sockets to avoid occasional failure to use -lsocket + + gsoc_sntp/configure.ac@1.12, 2009-04-15 01:47:00+00:00, davehart@shiny.ad.hartbrothers.com +4 -5 + switch AC_CHECK_LIB to AC_SEARCH_LIBS for sockets to avoid occasional failure to use -lsocket + +ChangeSet@1.1436.21.6, 2009-04-15 01:32:33+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + use AC_SEARCH_LIBS to avoid problems with sntp + + configure.ac@1.400.1.7, 2009-04-15 01:30:56+00:00, davehart@shiny.ad.hartbrothers.com +12 -20 + use AC_SEARCH_LIBS in preference to AC_CHECK_LIB particulary for sockets, use AM_PROG_CC_C_O which supersets prior AC_PROG_CC_C_O + + sntp/configure.ac@1.15.1.2, 2009-04-15 01:28:22+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + use AC_SEARCH_LIBS which is recommended particularly for sockets over the older AC_CHECK_LIB + +ChangeSet@1.1796.12.5, 2009-04-14 13:56:37+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + configure.ac: + merge improvments from configure.ac into gsoc_sntp/configure.ac + + gsoc_sntp/configure.ac@1.11, 2009-04-14 13:56:26+00:00, davehart@shiny.ad.hartbrothers.com +210 -108 + merge improvments from configure.ac into gsoc_sntp/configure.ac + +ChangeSet@1.1436.21.5, 2009-04-14 13:47:29+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + configure.ac: + tear off sntp/configure.ac from configure.ac + + configure.ac@1.400.1.6, 2009-04-14 13:46:17+00:00, davehart@shiny.ad.hartbrothers.com +6 -1 + tear off sntp/configure.ac from configure.ac + +ChangeSet@1.1436.15.38, 2009-04-14 07:55:41-04:00, mayer@pogo.udel.edu +1 -0 + Added fix for Bug 813 + + ChangeLog@1.1.1.65, 2009-04-14 07:55:31-04:00, mayer@pogo.udel.edu +1 -0 + Added fix for Bug 813 + +ChangeSet@1.1436.15.37, 2009-04-14 07:51:41-04:00, mayer@pogo.udel.edu +1 -0 + [Bug 813] Conditional naming of Event + + ports/winnt/ntpd/ntp_iocompletionport.c@1.21.1.10, 2009-04-14 07:51:14-04:00, mayer@pogo.udel.edu +7 -1 + [Bug 813] Conditional naming of Event + +ChangeSet@1.1796.14.1, 2009-04-14 09:31:17+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + ntpdc.c, ntpq.c: + remove duplicate #define closesocket, in .h now + ChangeLog, refclock_nmea.c: + [Bug 1153] refclock_nmea should not mix UTC with GPS time + + ChangeLog@1.268.13.1, 2009-04-14 09:30:49+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1153] refclock_nmea should not mix UTC with GPS time + + ntpd/refclock_nmea.c@1.33, 2009-04-14 09:30:49+00:00, davehart@shiny.ad.hartbrothers.com +41 -31 + [Bug 1153] refclock_nmea should not mix UTC with GPS time + + ntpdc/ntpdc.c@1.60, 2009-04-14 09:30:21+00:00, davehart@shiny.ad.hartbrothers.com +0 -2 + remove duplicate #define closesocket, in .h now + + ntpq/ntpq.c@1.78, 2009-04-14 09:30:21+00:00, davehart@shiny.ad.hartbrothers.com +0 -2 + remove duplicate #define closesocket, in .h now + +ChangeSet@1.1796.13.2, 2009-04-14 08:20:36+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + configure.ac: + complete the merge from stable cleanup + + configure.ac@1.423.1.2, 2009-04-14 08:20:29+00:00, davehart@shiny.ad.hartbrothers.com +63 -1 + complete the merge from stable cleanup + +ChangeSet@1.1436.21.4, 2009-04-14 05:21:17+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + configure.ac: + use unset for tickadj utility test fix + + configure.ac@1.400.1.5, 2009-04-14 05:21:15+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + use unset for tickadj utility test fix + +ChangeSet@1.1436.21.3, 2009-04-14 02:59:39+00:00, hart@pogo.udel.edu +1 -0 + build: + do not require nice + + build@1.26, 2009-04-14 02:59:20+00:00, hart@pogo.udel.edu +21 -4 + do not require nice + +ChangeSet@1.1436.21.2, 2009-04-14 01:33:01+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + configure.ac, ChangeLog: + [Bug 1158] support for aix6.1 + + ChangeLog@1.1.16.2, 2009-04-14 01:33:00+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1158] support for aix6.1 + + configure.ac@1.400.1.4, 2009-04-14 01:33:00+00:00, davehart@shiny.ad.hartbrothers.com +8 -8 + [Bug 1158] support for aix6.1 + +ChangeSet@1.1436.21.1, 2009-04-14 01:28:08+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + [Bug 1157] quiet OpenSSL warnings, clean up configure.ac + make flock-build quit before causing harm if another has not completed + + + ChangeLog@1.1.16.1, 2009-04-14 01:28:06+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Bug 1157] quiet OpenSSL warnings, clean up configure.ac + + build@1.25, 2009-04-14 01:28:07+00:00, davehart@shiny.ad.hartbrothers.com +6 -7 + prevent multiple flock-builds from stepping on each others work + + configure.ac@1.400.1.3, 2009-04-14 01:28:07+00:00, davehart@shiny.ad.hartbrothers.com +613 -361 + [Bug 1157] quiet OpenSSL warnings, configure.ac cleanup + + flock-build@1.39.1.1, 2009-04-14 01:28:07+00:00, davehart@shiny.ad.hartbrothers.com +76 -20 + prevent multiple flock-builds from stepping on each others work + + sntp/configure.ac@1.15.1.1, 2009-04-14 01:28:07+00:00, davehart@shiny.ad.hartbrothers.com +14 -0 + bring in line with -dev to ease merges, no functional change + +ChangeSet@1.1796.12.1, 2009-04-13 20:20:58+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + configure.ac, ChangeLog: + [Bug 1152] temporarily disable refclock_parse and refclock_true until maintainers repair pps_sample() build break + + ChangeLog@1.268.11.1, 2009-04-13 20:20:43+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1152] temporarily disable refclock_parse and refclock_true until maintainers repair pps_sample() build break + + configure.ac@1.424, 2009-04-13 20:20:43+00:00, davehart@shiny.ad.hartbrothers.com +5 -2 + [Bug 1152] temporarily disable refclock_parse and refclock_true until maintainers repair pps_sample() build break + +ChangeSet@1.1796.1.36, 2009-04-13 11:10:38-04:00, utterback@pogo.udel.edu +1 -0 + ChangeLog: + [Bug 1154] mDNS registration should be done later, repeatedly and only if asked for. + + ChangeLog@1.268.1.36, 2009-04-13 11:03:45-04:00, utterback@pogo.udel.edu +1 -0 + [Bug 1154] mDNS registration should be done later, repeatedly and only if asked for. + +ChangeSet@1.1436.15.36, 2009-04-13 00:00:55-04:00, mayer@pogo.udel.edu +1 -0 + Forgot the _WIN32_WINNT update + + ports/winnt/include/config.h@1.46.1.5, 2009-04-13 00:00:24-04:00, mayer@pogo.udel.edu +10 -23 + Forgot the _WIN32_WINNT update + +ChangeSet@1.1436.15.35, 2009-04-12 00:55:24-04:00, mayer@pogo.udel.edu +1 -0 + Windows bug fixes + + ChangeLog@1.1.1.64, 2009-04-12 00:54:43-04:00, mayer@pogo.udel.edu +7 -2 + Windows bug fixes + +ChangeSet@1.1436.15.34, 2009-04-12 00:45:48-04:00, mayer@pogo.udel.edu +2 -0 + [Bug 1156] lock_thread_to_processor() should be declared in header + + ports/winnt/include/clockstuff.h@1.7.1.1, 2009-04-12 00:45:09-04:00, mayer@pogo.udel.edu +1 -0 + [Bug 1156] lock_thread_to_processor() should be declared in header + + ports/winnt/ntpd/nt_clockstuff.c@1.23.1.2, 2009-04-12 00:45:09-04:00, mayer@pogo.udel.edu +0 -1 + [Bug 1156] lock_thread_to_processor() should be declared in header + +ChangeSet@1.1436.15.33, 2009-04-12 00:38:47-04:00, mayer@pogo.udel.edu +1 -0 + [Bug 1147] System errors should be logged to msyslog() + + ports/winnt/ntpd/ntp_iocompletionport.c@1.21.1.9, 2009-04-12 00:38:08-04:00, mayer@pogo.udel.edu +17 -14 + [Bug 1147] System errors should be logged to msyslog() + +ChangeSet@1.1436.15.32, 2009-04-12 00:34:41-04:00, mayer@pogo.udel.edu +1 -0 + [Bug 1155] Wrong header included in config.h. Should have been winsock2.h + + ports/winnt/include/config.h@1.46.1.4, 2009-04-12 00:34:10-04:00, mayer@pogo.udel.edu +1 -2 + [Bug 1155] Wrong header included in config.h. Should have been winsock2.h + +ChangeSet@1.1436.15.31, 2009-04-12 00:32:25-04:00, mayer@pogo.udel.edu +1 -0 + [Bug 787] Bug fixes for 64-bit time_t on Windows + + ports/winnt/libntp/SetSystemTime.c@1.3.1.1, 2009-04-12 00:30:42-04:00, mayer@pogo.udel.edu +2 -2 + [Bug 787] Bug fixes for 64-bit time_t on Windows + +ChangeSet@1.1796.1.35, 2009-04-10 07:56:46-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P163 + TAG: NTP_4_2_5P163 + + ChangeLog@1.268.1.35, 2009-04-10 07:56:18-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P163 + + gsoc_sntp/sntp-opts.c@1.24, 2009-04-10 07:56:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P163 + + gsoc_sntp/sntp-opts.h@1.24, 2009-04-10 07:56:19-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P163 + + gsoc_sntp/sntp-opts.texi@1.24, 2009-04-10 07:56:20-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P163 + + gsoc_sntp/sntp.1@1.24, 2009-04-10 07:56:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P163 + + ntpd/ntpd-opts.c@1.155, 2009-04-10 07:56:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P163 + + ntpd/ntpd-opts.h@1.155, 2009-04-10 07:56:22-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P163 + + ntpd/ntpd-opts.texi@1.154, 2009-04-10 07:56:23-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P163 + + ntpd/ntpd.1@1.154, 2009-04-10 07:56:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P163 + + ntpdc/ntpdc-opts.c@1.151, 2009-04-10 07:56:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P163 + + ntpdc/ntpdc-opts.h@1.151, 2009-04-10 07:56:25-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P163 + + ntpdc/ntpdc-opts.texi@1.150, 2009-04-10 07:56:26-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P163 + + ntpdc/ntpdc.1@1.150, 2009-04-10 07:56:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P163 + + ntpq/ntpq-opts.c@1.151, 2009-04-10 07:56:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P163 + + ntpq/ntpq-opts.h@1.151, 2009-04-10 07:56:28-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P163 + + ntpq/ntpq-opts.texi@1.150, 2009-04-10 07:56:28-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P163 + + ntpq/ntpq.1@1.150, 2009-04-10 07:56:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P163 + + ntpsnmpd/ntpsnmpd-opts.c@1.32, 2009-04-10 07:56:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P163 + + ntpsnmpd/ntpsnmpd-opts.h@1.32, 2009-04-10 07:56:31-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P163 + + ntpsnmpd/ntpsnmpd-opts.texi@1.32, 2009-04-10 07:56:32-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P163 + + ntpsnmpd/ntpsnmpd.1@1.32, 2009-04-10 07:56:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P163 + + packageinfo.sh@1.166, 2009-04-10 07:56:33-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P163 + + sntp/sntp-opts.c@1.151, 2009-04-10 07:56:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P163 + + sntp/sntp-opts.h@1.151, 2009-04-10 07:56:35-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P163 + + sntp/sntp-opts.texi@1.150, 2009-04-10 07:56:36-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P163 + + sntp/sntp.1@1.150, 2009-04-10 07:56:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P163 + + util/ntp-keygen-opts.c@1.154, 2009-04-10 07:56:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P163 + + util/ntp-keygen-opts.h@1.154, 2009-04-10 07:56:38-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P163 + + util/ntp-keygen-opts.texi@1.153, 2009-04-10 07:56:39-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P163 + + util/ntp-keygen.1@1.153, 2009-04-10 07:56:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P163 + +ChangeSet@1.1796.1.33, 2009-04-09 09:58:19-04:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P162 + TAG: NTP_4_2_5P162 + + ChangeLog@1.268.1.33, 2009-04-09 09:57:31-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P162 + + gsoc_sntp/sntp-opts.c@1.23, 2009-04-09 09:57:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P162 + + gsoc_sntp/sntp-opts.h@1.23, 2009-04-09 09:57:36-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P162 + + gsoc_sntp/sntp-opts.texi@1.23, 2009-04-09 09:57:38-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P162 + + gsoc_sntp/sntp.1@1.23, 2009-04-09 09:57:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P162 + + ntpd/ntpd-opts.c@1.154, 2009-04-09 09:57:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P162 + + ntpd/ntpd-opts.h@1.154, 2009-04-09 09:57:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P162 + + ntpd/ntpd-opts.texi@1.153, 2009-04-09 09:57:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P162 + + ntpd/ntpd.1@1.153, 2009-04-09 09:57:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P162 + + ntpdc/ntpdc-opts.c@1.150, 2009-04-09 09:57:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P162 + + ntpdc/ntpdc-opts.h@1.150, 2009-04-09 09:57:46-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P162 + + ntpdc/ntpdc-opts.texi@1.149, 2009-04-09 09:57:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P162 + + ntpdc/ntpdc.1@1.149, 2009-04-09 09:57:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P162 + + ntpq/ntpq-opts.c@1.150, 2009-04-09 09:57:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P162 + + ntpq/ntpq-opts.h@1.150, 2009-04-09 09:57:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P162 + + ntpq/ntpq-opts.texi@1.149, 2009-04-09 09:57:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P162 + + ntpq/ntpq.1@1.149, 2009-04-09 09:57:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P162 + + ntpsnmpd/ntpsnmpd-opts.c@1.31, 2009-04-09 09:57:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P162 + + ntpsnmpd/ntpsnmpd-opts.h@1.31, 2009-04-09 09:57:51-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P162 + + ntpsnmpd/ntpsnmpd-opts.texi@1.31, 2009-04-09 09:57:52-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P162 + + ntpsnmpd/ntpsnmpd.1@1.31, 2009-04-09 09:57:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P162 + + packageinfo.sh@1.165, 2009-04-09 09:57:57-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P162 + + sntp/sntp-opts.c@1.150, 2009-04-09 09:57:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P162 + + sntp/sntp-opts.h@1.150, 2009-04-09 09:58:00-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P162 + + sntp/sntp-opts.texi@1.149, 2009-04-09 09:58:03-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P162 + + sntp/sntp.1@1.149, 2009-04-09 09:58:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P162 + + util/ntp-keygen-opts.c@1.153, 2009-04-09 09:58:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P162 + + util/ntp-keygen-opts.h@1.153, 2009-04-09 09:58:06-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P162 + + util/ntp-keygen-opts.texi@1.152, 2009-04-09 09:58:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P162 + + util/ntp-keygen.1@1.152, 2009-04-09 09:58:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P162 + +ChangeSet@1.1436.15.30, 2009-04-09 07:44:06-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_4P7_RC2 + TAG: NTP_4_2_4P7_RC2 + + ChangeLog@1.1.1.63, 2009-04-09 07:43:41-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_4P7_RC2 + + ntpd/ntpd-opts.c@1.50.19.1, 2009-04-09 07:43:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC2 + + ntpd/ntpd-opts.h@1.50.19.1, 2009-04-09 07:43:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC2 + + ntpd/ntpd-opts.texi@1.49.19.1, 2009-04-09 07:43:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC2 + + ntpd/ntpd.1@1.48.19.1, 2009-04-09 07:43:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC2 + + ntpd/ntpdsim-opts.c@1.50.19.1, 2009-04-09 07:43:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC2 + + ntpd/ntpdsim-opts.h@1.50.19.1, 2009-04-09 07:43:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC2 + + ntpd/ntpdsim-opts.texi@1.48.19.1, 2009-04-09 07:43:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC2 + + ntpd/ntpdsim.1@1.48.19.1, 2009-04-09 07:43:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC2 + + ntpdc/ntpdc-opts.c@1.50.19.1, 2009-04-09 07:43:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC2 + + ntpdc/ntpdc-opts.h@1.50.19.1, 2009-04-09 07:43:50-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC2 + + ntpdc/ntpdc-opts.texi@1.48.19.1, 2009-04-09 07:43:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC2 + + ntpdc/ntpdc.1@1.48.19.1, 2009-04-09 07:43:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC2 + + ntpq/ntpq-opts.c@1.52.19.1, 2009-04-09 07:43:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC2 + + ntpq/ntpq-opts.h@1.52.19.1, 2009-04-09 07:43:53-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC2 + + ntpq/ntpq-opts.texi@1.49.19.1, 2009-04-09 07:43:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC2 + + ntpq/ntpq.1@1.48.19.1, 2009-04-09 07:43:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC2 + + packageinfo.sh@1.65.27.1, 2009-04-09 07:43:55-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC2 + + sntp/sntp-opts.c@1.49.19.1, 2009-04-09 07:43:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC2 + + sntp/sntp-opts.h@1.49.19.1, 2009-04-09 07:43:58-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC2 + + sntp/sntp-opts.texi@1.46.19.1, 2009-04-09 07:43:58-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC2 + + sntp/sntp.1@1.49.19.1, 2009-04-09 07:43:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC2 + + util/ntp-keygen-opts.c@1.49.19.1, 2009-04-09 07:44:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC2 + + util/ntp-keygen-opts.h@1.49.19.1, 2009-04-09 07:44:00-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC2 + + util/ntp-keygen-opts.texi@1.47.19.1, 2009-04-09 07:44:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC2 + + util/ntp-keygen.1@1.47.19.1, 2009-04-09 07:44:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC2 + +ChangeSet@1.1796.11.2, 2009-04-09 04:49:27-04:00, stenn@whimsy.udel.edu +8 -0 + Documentation updates from Dave Mills + + ChangeLog@1.268.10.2, 2009-04-09 04:49:17-04:00, stenn@whimsy.udel.edu +1 -0 + Documentation updates from Dave Mills + + html/comdex.html@1.2, 2009-04-09 04:48:58-04:00, stenn@whimsy.udel.edu +4 -2 + Documentation updates from Dave Mills + + html/decode.html@1.6, 2009-04-09 04:48:59-04:00, stenn@whimsy.udel.edu +5 -3 + Documentation updates from Dave Mills + + html/index.html@1.39, 2009-04-09 04:49:01-04:00, stenn@whimsy.udel.edu +4 -3 + Documentation updates from Dave Mills + + html/miscopt.html@1.41, 2009-04-09 04:49:02-04:00, stenn@whimsy.udel.edu +64 -54 + Documentation updates from Dave Mills + + html/monopt.html@1.29, 2009-04-09 04:49:03-04:00, stenn@whimsy.udel.edu +4 -2 + Documentation updates from Dave Mills + + html/prefer.html@1.18, 2009-04-09 04:49:06-04:00, stenn@whimsy.udel.edu +123 -58 + Documentation updates from Dave Mills + + html/sitemap.html@1.3, 2009-04-09 04:49:07-04:00, stenn@whimsy.udel.edu +5 -3 + Documentation updates from Dave Mills + +ChangeSet@1.1796.11.1, 2009-04-09 04:44:58-04:00, stenn@whimsy.udel.edu +8 -0 + Mitigation and PPS cleanup from Dave Mills + + ChangeLog@1.268.10.1, 2009-04-09 04:44:46-04:00, stenn@whimsy.udel.edu +4 -3 + Mitigation and PPS cleanup from Dave Mills + + include/ntpd.h@1.118.1.1, 2009-04-09 04:43:10-04:00, stenn@whimsy.udel.edu +1 -2 + Mitigation and PPS cleanup from Dave Mills + + ntpd/ntp_loopfilter.c@1.148, 2009-04-09 04:42:33-04:00, stenn@whimsy.udel.edu +2 -6 + Mitigation and PPS cleanup from Dave Mills + + ntpd/ntp_proto.c@1.276.1.3, 2009-04-09 04:42:36-04:00, stenn@whimsy.udel.edu +170 -161 + Mitigation and PPS cleanup from Dave Mills + + ntpd/ntp_timer.c@1.49.1.1, 2009-04-09 04:42:39-04:00, stenn@whimsy.udel.edu +7 -1 + Mitigation and PPS cleanup from Dave Mills + + ntpd/refclock_atom.c@1.57, 2009-04-09 04:42:42-04:00, stenn@whimsy.udel.edu +24 -170 + Mitigation and PPS cleanup from Dave Mills + + ntpd/refclock_conf.c@1.27, 2009-04-09 04:42:44-04:00, stenn@whimsy.udel.edu +1 -1 + Mitigation and PPS cleanup from Dave Mills + + ntpd/refclock_local.c@1.19, 2009-04-09 04:42:46-04:00, stenn@whimsy.udel.edu +18 -34 + Mitigation and PPS cleanup from Dave Mills + +ChangeSet@1.1436.15.29, 2009-04-09 04:16:50-04:00, stenn@whimsy.udel.edu +1 -0 + ChangLog cleanup + + ChangeLog@1.1.1.62, 2009-04-09 04:16:43-04:00, stenn@whimsy.udel.edu +1 -0 + ChangLog cleanup + +ChangeSet@1.1436.15.28, 2009-04-09 04:13:41-04:00, stenn@whimsy.udel.edu +2 -0 + [Sec 1144] limited buffer overflow in ntpq. CVE-2009-0159 + + ChangeLog@1.1.1.61, 2009-04-09 04:13:30-04:00, stenn@whimsy.udel.edu +2 -0 + [Sec 1144] limited buffer overflow in ntpq. CVE-2009-0159 + + ntpq/ntpq.c@1.65.2.1, 2009-04-09 04:13:30-04:00, stenn@whimsy.udel.edu +2 -2 + [Sec 1144] limited buffer overflow in ntpq. CVE-2009-0159 + +ChangeSet@1.1796.10.2, 2009-04-07 09:37:52+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + libntp.vcproj: + add overlooked ntp_debug.h + + ports/winnt/libntp/libntp.vcproj@1.1.1.1, 2009-04-07 09:37:46+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add overlooked ntp_debug.h + +ChangeSet@1.1436.15.27, 2009-04-07 09:14:58+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 + [Sec 1149] use setsockopt(SO_EXCLUSIVEADDRUSE) on Windows + + ChangeLog@1.1.1.60, 2009-04-07 09:14:56+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + [Sec 1149] use setsockopt(SO_EXCLUSIVEADDRUSE) on Windows + + ntpd/ntp_io.c@1.244.2.15, 2009-04-07 09:14:56+00:00, davehart@shiny.ad.hartbrothers.com +64 -31 + [Sec 1149] use setsockopt(SO_EXCLUSIVEADDRUSE) on Windows + + ports/winnt/libntp/libntp.vcproj@1.1.1.1, 2009-04-07 09:14:57+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 + add ntp_debug.h + +ChangeSet@1.1796.9.2, 2009-04-03 19:06:56+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + config.h, nt_clockstuff.c: + VC6 compatibility (thanks Martin!) + + ports/winnt/include/config.h@1.60, 2009-04-03 19:05:29+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + VC6 compatibility (thanks Martin!) + + ports/winnt/ntpd/nt_clockstuff.c@1.27, 2009-04-03 19:05:29+00:00, davehart@shiny.ad.hartbrothers.com +27 -16 + VC6 compatibility (thanks Martin!) + +ChangeSet@1.1796.9.1, 2009-04-03 03:49:05+00:00, davehart@shiny.ad.hartbrothers.com +43 -0 + new Windows interpolation knocks out 1ms jitter in previous + remove dead code + thin #ifdef SYS_WINNT forest + 64-bit time_t truncation fixes, warnings silenced + do not set hardware clock on exit unless system is shutting down + + BitKeeper/deleted/.del-ntpkeygen.vcproj@1.2, 2009-04-02 15:21:07+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + Rename: ports/winnt/ntp-keygen/ntpkeygen.vcproj -> BitKeeper/deleted/.del-ntpkeygen.vcproj + + ChangeLog@1.268.8.1, 2009-04-03 03:48:51+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 + [Bug 216] new interpolation, reduce #ifdef SYS_WINNT, 64-bit time_t cleanup, only set Windows CMOS clock at ntpd exit if the computer is shutting down + + include/ntp_machine.h@1.25, 2009-04-03 03:48:52+00:00, davehart@shiny.ad.hartbrothers.com +3 -46 + remove SYS_WINNT stuff (redundant with ports/winnt/config.h) + + include/ntp_stdlib.h@1.26, 2009-04-03 03:48:52+00:00, davehart@shiny.ad.hartbrothers.com +0 -1 + remove dead humandate() code + + include/ntp_types.h@1.11, 2009-04-03 03:48:52+00:00, davehart@shiny.ad.hartbrothers.com +18 -0 + UNUSED_ARG macro definition, used to quiet compiler warnings + --- + define sock_timeval for Windows 64-bit time_t compatibility + + include/ntp_unixtime.h@1.6, 2009-04-02 23:53:28+00:00, davehart@shiny.ad.hartbrothers.com +0 -3 + remove dead code: tvtoa(), utvtoa() declarations + + libntp/Makefile.am@1.41, 2009-04-03 03:48:52+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 + remove dead tvtoa.c & utvtoa.c from libntp + + libntp/buftvtots.c@1.5, 2009-04-03 03:48:52+00:00, davehart@shiny.ad.hartbrothers.com +18 -0 + Windows has no tty_clock discipline, don't look for timestamp in refclock recvbuff + + libntp/humandate.c@1.7, 2009-04-03 03:48:52+00:00, davehart@shiny.ad.hartbrothers.com +1 -30 + remove dead humandate() code + + libntp/prettydate.c@1.11, 2009-04-03 03:48:52+00:00, davehart@shiny.ad.hartbrothers.com +17 -27 + fix compiler warning with 64-bit time_t, fold duplicate code into common helper + + libntp/systime.c@1.47, 2009-04-03 03:48:53+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + quiet compiler warning with 64-bit time_t + + ntpd/ntp_config.c@1.184.1.1, 2009-04-03 03:48:53+00:00, davehart@shiny.ad.hartbrothers.com +6 -6 + quiet compiler warnings about storing int into u_short with casts + + ntpd/ntp_crypto.c@1.130, 2009-04-03 03:48:53+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + quiet compiler warning with 64-bit time_t + + ntpd/ntp_intres.c@1.57, 2009-04-03 03:48:53+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + struct sock_timeval for 64-bit time_t compatibility on Windows + + ntpd/ntp_timer.c@1.50, 2009-04-03 03:48:53+00:00, davehart@shiny.ad.hartbrothers.com +0 -27 + remove redundant code, nt_clockstuff.c enables privs earlier + + ntpd/ntpd.c@1.100, 2009-04-03 03:48:54+00:00, davehart@shiny.ad.hartbrothers.com +0 -4 + chop down some #ifdef forest + + ntpd/refclock_dumbclock.c@1.12, 2009-04-03 03:48:54+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + 64-bit time_t compiler warning silenced + + ntpdate/ntpdate.c@1.65, 2009-04-03 03:48:54+00:00, davehart@shiny.ad.hartbrothers.com +5 -18 + struct sock_timeval for 64-bit time_t compatibility on Windows, more #ifdef SYS_WINNT deforestation + + ntpdc/ntpdc.c@1.59, 2009-04-03 03:48:54+00:00, davehart@shiny.ad.hartbrothers.com +4 -16 + struct sock_timeval for 64-bit time_t compatibility on Windows + + ntpq/ntpq.c@1.76, 2009-04-03 03:48:54+00:00, davehart@shiny.ad.hartbrothers.com +5 -5 + struct sock_timeval for 64-bit time_t compatibility on Windows + + ports/winnt/include/clockstuff.h@1.8, 2009-04-03 03:48:55+00:00, davehart@shiny.ad.hartbrothers.com +32 -7 + new interpolation scheme knocks out 1ms jitter inherent in previous + + ports/winnt/include/config.h@1.59, 2009-04-03 03:48:55+00:00, davehart@shiny.ad.hartbrothers.com +27 -5 + struct sock_timeval for 64-bit time_t compatibility on Windows, more #ifdef SYS_WINNT deforestation + + ports/winnt/include/ntservice.h@1.3, 2009-04-03 03:48:55+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + expose ntservice_systemisshuttingdown(), fix calling convention mismatch + + ports/winnt/include/sys/resource.h@1.4, 2009-04-03 03:48:55+00:00, davehart@shiny.ad.hartbrothers.com +10 -4 + emulate BSD setpriority() to reduce #ifdef SYS_WINNT + + ports/winnt/include/sys/time.h@1.5, 2009-04-03 03:48:55+00:00, davehart@shiny.ad.hartbrothers.com +14 -6 + new interpolation scheme knocks out 1ms jitter inherent in previous + + ports/winnt/libntp/SetSystemTime.c@1.5, 2009-04-03 03:48:55+00:00, davehart@shiny.ad.hartbrothers.com +18 -16 + new interpolation scheme knocks out 1ms jitter inherent in previous + do not mix C runtime and Windows Gregorian calendar routines + + ports/winnt/libntp/getclock.c@1.1, 2009-04-03 03:48:58+00:00, davehart@shiny.ad.hartbrothers.com +49 -0 + emulate BSD getclock() interface + + ports/winnt/libntp/getclock.c@1.0, 2009-04-03 03:48:58+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/libntp/libntp.dsp@1.33, 2009-04-03 03:48:55+00:00, davehart@shiny.ad.hartbrothers.com +8 -0 + add getclock.c setpriority.c + + ports/winnt/libntp/libntp.vcproj@1.2, 2009-04-03 03:48:56+00:00, davehart@shiny.ad.hartbrothers.com +13 -59 + remove dead tvtoa.c & utvtoa.c from libntp, add getclock.c setpriority.c and util_clockstuff.c + + ports/winnt/libntp/randfile.c@1.3, 2009-04-03 03:48:56+00:00, davehart@shiny.ad.hartbrothers.com +3 -2 + buffer overrun protection + + ports/winnt/libntp/setpriority.c@1.1, 2009-04-03 03:48:58+00:00, davehart@shiny.ad.hartbrothers.com +79 -0 + emulate BSD setpriority() to thin #ifdef forest in ntpd.c + + ports/winnt/libntp/setpriority.c@1.0, 2009-04-03 03:48:58+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/libntp/syslog.c@1.4, 2009-04-03 03:48:56+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + use strncpy instead of strcpy, force null termination as Windows strncpy doesn't when buffer exceeded + + ports/winnt/libntp/util_clockstuff.c@1.4, 2009-04-03 03:48:56+00:00, davehart@shiny.ad.hartbrothers.com +9 -17 + no longer conflicts with ports/winnt/ntpd/nt_clockstuff.c, can be added to libntp library. + + ports/winnt/ntp-keygen/ntp-keygen.vcproj@1.2, 2009-04-03 03:48:56+00:00, davehart@shiny.ad.hartbrothers.com +0 -22 + remove util_clockstuff.c from individual projects, it's now in libntp library + + ports/winnt/ntpd/nt_clockstuff.c@1.26, 2009-04-03 03:48:56+00:00, davehart@shiny.ad.hartbrothers.com +1180 -332 + new interpolation scheme knocks out 1ms jitter inherent in previous + + ports/winnt/ntpd/ntp_iocompletionport.c@1.40, 2009-04-03 03:48:57+00:00, davehart@shiny.ad.hartbrothers.com +3 -5 + move lock_thread_to_processor prototype to clockstuff.h + + ports/winnt/ntpd/ntservice.c@1.14, 2009-04-03 03:48:57+00:00, davehart@shiny.ad.hartbrothers.com +52 -41 + ntservice_systemisshuttingdown(), fix mismatched calling convention, remove erroneous SetServiceStatus calls, eliminate unreachable code warning by removing exit() calls from main() + + ports/winnt/ntpd/win32_io.c@1.15, 2009-04-03 03:48:57+00:00, davehart@shiny.ad.hartbrothers.com +0 -12 + emulate BSD setpriority() to reduce #ifdef SYS_WINNT + + ports/winnt/ntpdate/ntpdate.vcproj@1.2, 2009-04-03 03:48:57+00:00, davehart@shiny.ad.hartbrothers.com +0 -22 + remove util_clockstuff.c from individual projects, it's now in libntp library + + ports/winnt/ntpdc/ntpdc.vcproj@1.2, 2009-04-03 03:48:57+00:00, davehart@shiny.ad.hartbrothers.com +0 -22 + remove util_clockstuff.c from individual projects, it's now in libntp library + + ports/winnt/ntpq/ntpq.vcproj@1.2, 2009-04-03 03:48:57+00:00, davehart@shiny.ad.hartbrothers.com +0 -22 + remove util_clockstuff.c from individual projects, it's now in libntp library + + ports/winnt/scripts/mkver.bat@1.10, 2009-04-03 03:48:58+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 + fix VC++ 2008 parallel build collision on %TEMP%\TZ.TMP by using a different filename for each program + + util/ntp-keygen.c@1.54, 2009-04-03 03:48:58+00:00, davehart@shiny.ad.hartbrothers.com +1 -4 + remove #ifdef SYS_WINNT, gettimeofday() prototype on Windows now matches Unix + +ChangeSet@1.1796.8.2, 2009-04-01 01:13:42+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + bk gone the former gsoc_sntp/utilities.o so that all .o files can be removed without corrupting the repo + + BitKeeper/etc/gone@1.9, 2009-04-01 01:13:41+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + bk gone the former gsoc_sntp/utilities.o so that all .o files can be removed without corrupting the repo + + ChangeLog@1.268.7.2, 2009-04-01 01:13:41+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + bk gone the former gsoc_sntp/utilities.o so that all .o files can be removed without corrupting the repo + +ChangeSet@1.1796.8.1, 2009-03-31 06:56:41-05:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P161 + TAG: NTP_4_2_5P161 + + ChangeLog@1.268.7.1, 2009-03-31 06:56:15-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P161 + + gsoc_sntp/sntp-opts.c@1.22, 2009-03-31 06:56:17-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P161 + + gsoc_sntp/sntp-opts.h@1.22, 2009-03-31 06:56:18-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P161 + + gsoc_sntp/sntp-opts.texi@1.22, 2009-03-31 06:56:18-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P161 + + gsoc_sntp/sntp.1@1.22, 2009-03-31 06:56:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P161 + + ntpd/ntpd-opts.c@1.153, 2009-03-31 06:56:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P161 + + ntpd/ntpd-opts.h@1.153, 2009-03-31 06:56:20-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P161 + + ntpd/ntpd-opts.texi@1.152, 2009-03-31 06:56:21-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P161 + + ntpd/ntpd.1@1.152, 2009-03-31 06:56:22-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P161 + + ntpdc/ntpdc-opts.c@1.149, 2009-03-31 06:56:22-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P161 + + ntpdc/ntpdc-opts.h@1.149, 2009-03-31 06:56:23-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P161 + + ntpdc/ntpdc-opts.texi@1.148, 2009-03-31 06:56:24-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P161 + + ntpdc/ntpdc.1@1.148, 2009-03-31 06:56:25-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P161 + + ntpq/ntpq-opts.c@1.149, 2009-03-31 06:56:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P161 + + ntpq/ntpq-opts.h@1.149, 2009-03-31 06:56:26-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P161 + + ntpq/ntpq-opts.texi@1.148, 2009-03-31 06:56:27-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P161 + + ntpq/ntpq.1@1.148, 2009-03-31 06:56:28-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P161 + + ntpsnmpd/ntpsnmpd-opts.c@1.30, 2009-03-31 06:56:29-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P161 + + ntpsnmpd/ntpsnmpd-opts.h@1.30, 2009-03-31 06:56:30-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P161 + + ntpsnmpd/ntpsnmpd-opts.texi@1.30, 2009-03-31 06:56:30-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P161 + + ntpsnmpd/ntpsnmpd.1@1.30, 2009-03-31 06:56:31-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P161 + + packageinfo.sh@1.164, 2009-03-31 06:56:31-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P161 + + sntp/sntp-opts.c@1.149, 2009-03-31 06:56:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P161 + + sntp/sntp-opts.h@1.149, 2009-03-31 06:56:33-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P161 + + sntp/sntp-opts.texi@1.148, 2009-03-31 06:56:34-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P161 + + sntp/sntp.1@1.148, 2009-03-31 06:56:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P161 + + util/ntp-keygen-opts.c@1.152, 2009-03-31 06:56:35-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P161 + + util/ntp-keygen-opts.h@1.152, 2009-03-31 06:56:35-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P161 + + util/ntp-keygen-opts.texi@1.151, 2009-03-31 06:56:36-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P161 + + util/ntp-keygen.1@1.151, 2009-03-31 06:56:37-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P161 + +ChangeSet@1.1796.1.28, 2009-03-31 09:33:53+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + refclock_nmea.c: + [Bug 1148] NMEA reference clock improvements + + ChangeLog@1.268.1.28, 2009-03-31 09:33:43+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1148] NMEA reference clock improvements + + ntpd/refclock_nmea.c@1.32, 2009-03-31 09:33:44+00:00, davehart@shiny.ad.hartbrothers.com +377 -222 + [Bug 1148] NMEA reference clock improvements + +ChangeSet@1.1796.1.27, 2009-03-30 14:44:58-05:00, stenn@whimsy.udel.edu +3 -0 + Documentation updates from Dave Mills + + ChangeLog@1.268.1.27, 2009-03-30 14:44:45-05:00, stenn@whimsy.udel.edu +1 -0 + Documentation updates from Dave Mills + + html/confopt.html@1.44, 2009-03-30 14:44:26-05:00, stenn@whimsy.udel.edu +194 -89 + Documentation updates from Dave Mills + + html/ntpq.html@1.31, 2009-03-30 14:44:29-05:00, stenn@whimsy.udel.edu +23 -6 + Documentation updates from Dave Mills + +ChangeSet@1.1796.1.25, 2009-03-30 09:06:35-05:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P160 + TAG: NTP_4_2_5P160 + + ChangeLog@1.268.1.25, 2009-03-30 09:05:39-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P160 + + gsoc_sntp/sntp-opts.c@1.21, 2009-03-30 09:05:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P160 + + gsoc_sntp/sntp-opts.h@1.21, 2009-03-30 09:05:43-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P160 + + gsoc_sntp/sntp-opts.texi@1.21, 2009-03-30 09:05:44-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P160 + + gsoc_sntp/sntp.1@1.21, 2009-03-30 09:05:44-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P160 + + ntpd/ntpd-opts.c@1.152, 2009-03-30 09:05:45-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P160 + + ntpd/ntpd-opts.h@1.152, 2009-03-30 09:05:51-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P160 + + ntpd/ntpd-opts.texi@1.151, 2009-03-30 09:05:56-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P160 + + ntpd/ntpd.1@1.151, 2009-03-30 09:06:00-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P160 + + ntpdc/ntpdc-opts.c@1.148, 2009-03-30 09:06:00-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P160 + + ntpdc/ntpdc-opts.h@1.148, 2009-03-30 09:06:03-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P160 + + ntpdc/ntpdc-opts.texi@1.147, 2009-03-30 09:06:04-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P160 + + ntpdc/ntpdc.1@1.147, 2009-03-30 09:06:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P160 + + ntpq/ntpq-opts.c@1.148, 2009-03-30 09:06:07-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P160 + + ntpq/ntpq-opts.h@1.148, 2009-03-30 09:06:09-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P160 + + ntpq/ntpq-opts.texi@1.147, 2009-03-30 09:06:09-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P160 + + ntpq/ntpq.1@1.147, 2009-03-30 09:06:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P160 + + ntpsnmpd/ntpsnmpd-opts.c@1.29, 2009-03-30 09:06:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P160 + + ntpsnmpd/ntpsnmpd-opts.h@1.29, 2009-03-30 09:06:13-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P160 + + ntpsnmpd/ntpsnmpd-opts.texi@1.29, 2009-03-30 09:06:14-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P160 + + ntpsnmpd/ntpsnmpd.1@1.29, 2009-03-30 09:06:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P160 + + packageinfo.sh@1.163, 2009-03-30 09:06:16-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P160 + + sntp/sntp-opts.c@1.148, 2009-03-30 09:06:17-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P160 + + sntp/sntp-opts.h@1.148, 2009-03-30 09:06:18-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P160 + + sntp/sntp-opts.texi@1.147, 2009-03-30 09:06:20-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P160 + + sntp/sntp.1@1.147, 2009-03-30 09:06:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P160 + + util/ntp-keygen-opts.c@1.151, 2009-03-30 09:06:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P160 + + util/ntp-keygen-opts.h@1.151, 2009-03-30 09:06:21-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P160 + + util/ntp-keygen-opts.texi@1.150, 2009-03-30 09:06:22-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P160 + + util/ntp-keygen.1@1.150, 2009-03-30 09:06:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P160 + +ChangeSet@1.1436.15.26, 2009-03-30 06:47:41-05:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_4P7_RC1 + TAG: NTP_4_2_4P7_RC1 + + ChangeLog@1.1.1.59, 2009-03-30 06:47:19-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_4P7_RC1 + + ntpd/ntpd-opts.c@1.50.18.1, 2009-03-30 06:47:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC1 + + ntpd/ntpd-opts.h@1.50.18.1, 2009-03-30 06:47:21-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC1 + + ntpd/ntpd-opts.texi@1.49.18.1, 2009-03-30 06:47:22-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC1 + + ntpd/ntpd.1@1.48.18.1, 2009-03-30 06:47:22-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC1 + + ntpd/ntpdsim-opts.c@1.50.18.1, 2009-03-30 06:47:23-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC1 + + ntpd/ntpdsim-opts.h@1.50.18.1, 2009-03-30 06:47:24-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC1 + + ntpd/ntpdsim-opts.texi@1.48.18.1, 2009-03-30 06:47:25-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC1 + + ntpd/ntpdsim.1@1.48.18.1, 2009-03-30 06:47:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC1 + + ntpdc/ntpdc-opts.c@1.50.18.1, 2009-03-30 06:47:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC1 + + ntpdc/ntpdc-opts.h@1.50.18.1, 2009-03-30 06:47:26-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC1 + + ntpdc/ntpdc-opts.texi@1.48.18.1, 2009-03-30 06:47:27-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC1 + + ntpdc/ntpdc.1@1.48.18.1, 2009-03-30 06:47:28-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC1 + + ntpq/ntpq-opts.c@1.52.18.1, 2009-03-30 06:47:29-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC1 + + ntpq/ntpq-opts.h@1.52.18.1, 2009-03-30 06:47:30-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC1 + + ntpq/ntpq-opts.texi@1.49.18.1, 2009-03-30 06:47:31-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC1 + + ntpq/ntpq.1@1.48.18.1, 2009-03-30 06:47:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC1 + + packageinfo.sh@1.65.26.1, 2009-03-30 06:47:33-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC1 + + sntp/sntp-opts.c@1.49.18.1, 2009-03-30 06:47:33-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC1 + + sntp/sntp-opts.h@1.49.18.1, 2009-03-30 06:47:34-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC1 + + sntp/sntp-opts.texi@1.46.18.1, 2009-03-30 06:47:35-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P7_RC1 + + sntp/sntp.1@1.49.18.1, 2009-03-30 06:47:35-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC1 + + util/ntp-keygen-opts.c@1.49.18.1, 2009-03-30 06:47:36-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC1 + + util/ntp-keygen-opts.h@1.49.18.1, 2009-03-30 06:47:36-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P7_RC1 + + util/ntp-keygen-opts.texi@1.47.18.1, 2009-03-30 06:47:37-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC1 + + util/ntp-keygen.1@1.47.18.1, 2009-03-30 06:47:38-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P7_RC1 + +ChangeSet@1.1436.15.25, 2009-03-30 02:31:49-05:00, stenn@whimsy.udel.edu +1 -0 + Release Candidate + + packageinfo.sh@1.65.25.1, 2009-03-30 02:31:39-05:00, stenn@whimsy.udel.edu +1 -1 + Release Candidate + +ChangeSet@1.1796.7.2, 2009-03-28 06:55:26-05:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P159 + TAG: NTP_4_2_5P159 + + ChangeLog@1.268.6.2, 2009-03-28 06:54:55-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P159 + + gsoc_sntp/sntp-opts.c@1.20, 2009-03-28 06:54:57-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P159 + + gsoc_sntp/sntp-opts.h@1.20, 2009-03-28 06:54:58-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P159 + + gsoc_sntp/sntp-opts.texi@1.20, 2009-03-28 06:54:58-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P159 + + gsoc_sntp/sntp.1@1.20, 2009-03-28 06:54:59-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P159 + + ntpd/ntpd-opts.c@1.151, 2009-03-28 06:55:00-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P159 + + ntpd/ntpd-opts.h@1.151, 2009-03-28 06:55:01-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P159 + + ntpd/ntpd-opts.texi@1.150, 2009-03-28 06:55:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P159 + + ntpd/ntpd.1@1.150, 2009-03-28 06:55:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P159 + + ntpdc/ntpdc-opts.c@1.147, 2009-03-28 06:55:04-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P159 + + ntpdc/ntpdc-opts.h@1.147, 2009-03-28 06:55:05-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P159 + + ntpdc/ntpdc-opts.texi@1.146, 2009-03-28 06:55:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P159 + + ntpdc/ntpdc.1@1.146, 2009-03-28 06:55:07-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P159 + + ntpq/ntpq-opts.c@1.147, 2009-03-28 06:55:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P159 + + ntpq/ntpq-opts.h@1.147, 2009-03-28 06:55:09-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P159 + + ntpq/ntpq-opts.texi@1.146, 2009-03-28 06:55:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P159 + + ntpq/ntpq.1@1.146, 2009-03-28 06:55:12-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P159 + + ntpsnmpd/ntpsnmpd-opts.c@1.28, 2009-03-28 06:55:12-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P159 + + ntpsnmpd/ntpsnmpd-opts.h@1.28, 2009-03-28 06:55:13-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P159 + + ntpsnmpd/ntpsnmpd-opts.texi@1.28, 2009-03-28 06:55:14-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P159 + + ntpsnmpd/ntpsnmpd.1@1.28, 2009-03-28 06:55:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P159 + + packageinfo.sh@1.162, 2009-03-28 06:55:15-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P159 + + sntp/sntp-opts.c@1.147, 2009-03-28 06:55:15-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P159 + + sntp/sntp-opts.h@1.147, 2009-03-28 06:55:16-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P159 + + sntp/sntp-opts.texi@1.146, 2009-03-28 06:55:16-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P159 + + sntp/sntp.1@1.146, 2009-03-28 06:55:17-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P159 + + util/ntp-keygen-opts.c@1.150, 2009-03-28 06:55:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P159 + + util/ntp-keygen-opts.h@1.150, 2009-03-28 06:55:19-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P159 + + util/ntp-keygen-opts.texi@1.149, 2009-03-28 06:55:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P159 + + util/ntp-keygen.1@1.149, 2009-03-28 06:55:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P159 + +ChangeSet@1.1436.15.23, 2009-03-28 02:46:45-05:00, stenn@whimsy.udel.edu +9 -0 + build system email address cleanup + + BitKeeper/triggers/changelog@1.4, 2009-03-28 02:45:21-05:00, stenn@whimsy.udel.edu +1 -1 + trigger email address cleanup + + BitKeeper/triggers/commitlogs@1.6, 2009-03-28 02:45:22-05:00, stenn@whimsy.udel.edu +1 -1 + trigger email address cleanup + + BitKeeper/triggers/delta-changelog@1.8, 2009-03-28 02:45:22-05:00, stenn@whimsy.udel.edu +2 -2 + trigger email address cleanup + + BitKeeper/triggers/notify@1.4, 2009-03-28 02:45:22-05:00, stenn@whimsy.udel.edu +1 -1 + trigger email address cleanup + + BitKeeper/triggers/paranoid@1.4, 2009-03-28 02:45:22-05:00, stenn@whimsy.udel.edu +1 -1 + trigger email address cleanup + + BitKeeper/triggers/post-incoming.license-warn@1.7, 2009-03-28 02:45:22-05:00, stenn@whimsy.udel.edu +1 -1 + trigger email address cleanup + + BitKeeper/triggers/pre-resolve.licfix@1.4, 2009-03-28 02:45:22-05:00, stenn@whimsy.udel.edu +1 -1 + trigger email address cleanup + + BitKeeper/triggers/send@1.14, 2009-03-28 02:45:22-05:00, stenn@whimsy.udel.edu +2 -2 + trigger email address cleanup + + ChangeLog@1.1.1.57, 2009-03-28 02:46:36-05:00, stenn@whimsy.udel.edu +3 -1 + build system email address cleanup + +ChangeSet@1.1796.7.1, 2009-03-28 02:14:41-05:00, stenn@whimsy.udel.edu +6 -0 + "bias" changes from Dave Mills + + ChangeLog@1.268.6.1, 2009-03-28 02:13:56-05:00, stenn@whimsy.udel.edu +1 -0 + "bias" changes from Dave Mills + + include/ntp.h@1.148.1.1, 2009-03-28 02:13:41-05:00, stenn@whimsy.udel.edu +2 -1 + "bias" changes from Dave Mills + + include/ntp_control.h@1.34, 2009-03-28 02:13:44-05:00, stenn@whimsy.udel.edu +9 -8 + "bias" changes from Dave Mills + + ntpd/ntp_control.c@1.108, 2009-03-28 02:13:17-05:00, stenn@whimsy.udel.edu +18 -10 + "bias" changes from Dave Mills + + ntpd/ntp_crypto.c@1.129, 2009-03-28 02:13:19-05:00, stenn@whimsy.udel.edu +13 -11 + "bias" changes from Dave Mills + + ntpd/ntp_proto.c@1.276.1.2, 2009-03-28 02:13:22-05:00, stenn@whimsy.udel.edu +69 -92 + "bias" changes from Dave Mills + +ChangeSet@1.1796.1.21, 2009-03-28 05:37:50+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + ntp_refclock.c, ChangeLog: + [Bug 1141] refclock_report missing braces cause spurious 'peer event: clock clk_unspec' log entries + + ChangeLog@1.268.1.21, 2009-03-28 05:37:40+00:00, davehart@shiny.ad.hartbrothers.com +8 -5 + [Bug 1141] refclock_report missing braces cause spurious 'peer event: clock clk_unspec' log entries + + ntpd/ntp_refclock.c@1.81, 2009-03-28 05:37:34+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 + [Bug 1141] refclock_report missing braces cause spurious 'peer event: clock clk_unspec' log entries + +ChangeSet@1.1796.1.20, 2009-03-24 15:23:07+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + config.h: + include winsock.h before ws2tcpip.h to fix VS 2005 build + + ports/winnt/include/config.h@1.57, 2009-03-24 15:23:00+00:00, davehart@shiny.ad.hartbrothers.com +8 -5 + include winsock.h before ws2tcpip.h to fix VS 2005 build + +ChangeSet@1.1436.15.22, 2009-03-24 15:22:36+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + config.h: + include winsock.h before ws2tcpip.h to fix VS 2005 build + + ports/winnt/include/config.h@1.46.1.3, 2009-03-24 15:22:23+00:00, davehart@shiny.ad.hartbrothers.com +8 -5 + include winsock.h before ws2tcpip.h to fix VS 2005 build + +ChangeSet@1.1436.20.2, 2009-03-24 15:14:36+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ntp_iocompletionport.c: + use one receive per socket to avoid Win2000 afd.sys bugcheck 0x76 + + ports/winnt/ntpd/ntp_iocompletionport.c@1.21.2.2, 2009-03-24 15:14:23+00:00, davehart@shiny.ad.hartbrothers.com +10 -1 + use one receive per socket to avoid Win2000 afd.sys bugcheck 0x76 + +ChangeSet@1.1796.6.2, 2009-03-24 15:04:27+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ntp_iocompletionport.c: + use one receive per socket to avoid Win2000 afd.sys bugcheck 0x76 + + ports/winnt/ntpd/ntp_iocompletionport.c@1.35.1.2, 2009-03-24 15:03:36+00:00, davehart@shiny.ad.hartbrothers.com +10 -1 + use one receive per socket to avoid Win2000 afd.sys bugcheck 0x76 + +ChangeSet@1.1436.15.20, 2009-03-22 21:09:43+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + Makefile.am, ChangeLog: + [Bug 774] parsesolaris.c does not compile under the new Solaris + + ChangeLog@1.1.1.56, 2009-03-22 21:09:42+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 774] parsesolaris.c does not compile under the new Solaris + + libparse/Makefile.am@1.8.1.1, 2009-03-22 21:09:42+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + [Bug 774] parsesolaris.c does not compile under the new Solaris + +ChangeSet@1.1436.15.19, 2009-03-20 03:39:26+00:00, hart@pogo.udel.edu +1 -0 + ChangeLog: + bk for windows isn't converting line endings correctly, remove two blank lines visible only on Unix side + + ChangeLog@1.1.1.55, 2009-03-20 03:39:16+00:00, hart@pogo.udel.edu +0 -2 + bk for windows isn't converting line endings correctly, remove two blank lines visible only on Unix side + +ChangeSet@1.1796.1.18, 2009-03-20 03:34:09+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ChangeLog: + I'm learning + add DPRINTF line omitted accidentally + + ChangeLog@1.268.1.20, 2009-03-20 03:33:51+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + add DPRINTF line omitted accidentally + + ChangeLog@1.268.1.19, 2009-03-20 03:29:35+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + I'm learning + +ChangeSet@1.1436.15.16, 2009-03-20 03:10:22+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + ChangeLog: + remove blank first line + + ChangeLog@1.1.1.52, 2009-03-20 03:09:55+00:00, davehart@shiny.ad.hartbrothers.com +0 -1 + remove blank first line + +ChangeSet@1.1436.20.1, 2009-03-20 01:46:15+00:00, davehart@shiny.ad.hartbrothers.com +10 -0 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ChangeLog@1.1.15.1, 2009-03-20 01:46:11+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ntpd/ntp_io.c@1.244.3.1, 2009-03-20 01:46:11+00:00, davehart@shiny.ad.hartbrothers.com +26 -23 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ntpd/ntpd.c@1.82.2.4, 2009-03-20 01:46:12+00:00, davehart@shiny.ad.hartbrothers.com +14 -25 + slightly reduce #ifdef SYS_WINNT forest + + ntpd/refclock_dumbclock.c@1.8.1.1, 2009-03-20 01:46:12+00:00, davehart@shiny.ad.hartbrothers.com +6 -5 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ntpd/refclock_hopfser.c@1.9.1.1, 2009-03-20 01:46:12+00:00, davehart@shiny.ad.hartbrothers.com +6 -5 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ntpd/refclock_nmea.c@1.25.1.1, 2009-03-20 01:46:12+00:00, davehart@shiny.ad.hartbrothers.com +6 -5 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ntpd/refclock_palisade.c@1.18.1.1, 2009-03-20 01:46:12+00:00, davehart@shiny.ad.hartbrothers.com +6 -5 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ports/winnt/include/ntp_iocompletionport.h@1.13.1.1, 2009-03-20 01:46:13+00:00, davehart@shiny.ad.hartbrothers.com +8 -9 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ports/winnt/ntpd/ntp_iocompletionport.c@1.21.2.1, 2009-03-20 01:46:13+00:00, davehart@shiny.ad.hartbrothers.com +331 -249 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ports/winnt/ntpd/win32_io.c@1.12.1.1, 2009-03-20 01:46:13+00:00, davehart@shiny.ad.hartbrothers.com +172 -66 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + +ChangeSet@1.1796.6.1, 2009-03-20 01:31:56+00:00, davehart@shiny.ad.hartbrothers.com +10 -0 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + --- + Merge shiny.ad.hartbrothers.com:c:\ntp\ntp-stable-873 + into shiny.ad.hartbrothers.com:C:/ntp/ntp-dev-873 + + ChangeLog@1.268.5.1, 2009-03-20 01:31:52+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + + ntpd/ntp_io.c@1.275.1.1, 2009-03-20 01:31:52+00:00, davehart@shiny.ad.hartbrothers.com +25 -22 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + + ntpd/ntpd.c@1.98, 2009-03-20 01:31:53+00:00, davehart@shiny.ad.hartbrothers.com +17 -29 + slightly reduce #ifdef SYS_WINNT forest + + + ntpd/refclock_dumbclock.c@1.10, 2009-03-20 01:31:53+00:00, davehart@shiny.ad.hartbrothers.com +6 -5 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ntpd/refclock_hopfser.c@1.11, 2009-03-20 01:31:53+00:00, davehart@shiny.ad.hartbrothers.com +6 -5 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ntpd/refclock_nmea.c@1.30, 2009-03-20 01:31:53+00:00, davehart@shiny.ad.hartbrothers.com +6 -5 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ntpd/refclock_palisade.c@1.22, 2009-03-20 01:31:53+00:00, davehart@shiny.ad.hartbrothers.com +6 -5 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + + ports/winnt/include/ntp_iocompletionport.h@1.15, 2009-03-20 01:31:53+00:00, davehart@shiny.ad.hartbrothers.com +8 -9 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ports/winnt/ntpd/ntp_iocompletionport.c@1.35.1.1, 2009-03-20 01:31:54+00:00, davehart@shiny.ad.hartbrothers.com +335 -255 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ports/winnt/ntpd/win32_io.c@1.13, 2009-03-20 01:31:54+00:00, davehart@shiny.ad.hartbrothers.com +172 -66 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + +ChangeSet@1.1436.19.2, 2009-03-18 11:44:59+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1014] Enable building with VC9 (in Visual Studio 2008, Visual C++ 2008, or SDK) + + ChangeLog@1.1.14.1, 2009-03-18 11:44:52+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1014] Enable building with VC9 (in Visual Studio 2008, Visual C++ 2008, or SDK) + +ChangeSet@1.1796.5.2, 2009-03-18 11:42:38+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1014] Enable building with VC9 (in Visual Studio 2008, Visual C++ 2008, or SDK) + + ChangeLog@1.268.4.1, 2009-03-18 11:42:11+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1014] Enable building with VC9 (in Visual Studio 2008, Visual C++ 2008, or SDK) + +ChangeSet@1.1436.17.4, 2009-03-18 10:14:52+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 + [Bug 1117] Deferred interface binding under Windows works only correctly if FORCE_DNSRETRY is defined + + ChangeLog@1.1.12.3, 2009-03-18 10:12:28+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 + [Bug 1117] Deferred interface binding under Windows works only correctly if FORCE_DNSRETRY is defined + +ChangeSet@1.1796.5.1, 2009-03-17 19:21:10+00:00, davehart@shiny.ad.hartbrothers.com +8 -0 + [bug 1014] compile on VC9 AKA VC++ 2008 EE AKA VS 2008 + + ports/winnt/instsrv/instsrv.vcproj@1.1, 2009-03-17 19:15:18+00:00, davehart@shiny.ad.hartbrothers.com +253 -0 + [bug 1014] VC9 equivalent to .dsp + + ports/winnt/instsrv/instsrv.vcproj@1.0, 2009-03-17 19:15:18+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/libntp/libntp.vcproj@1.1, 2009-03-17 19:15:18+00:00, davehart@shiny.ad.hartbrothers.com +2211 -0 + [bug 1014] VC9 equivalent to .dsp + + ports/winnt/libntp/libntp.vcproj@1.0, 2009-03-17 19:15:18+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/ntp-keygen/ntp-keygen.vcproj@1.1, 2009-03-17 19:15:19+00:00, davehart@shiny.ad.hartbrothers.com +419 -0 + [bug 1014] VC9 equivalent to .dsp + + ports/winnt/ntp-keygen/ntp-keygen.vcproj@1.0, 2009-03-17 19:15:19+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/ntp.sln@1.2, 2009-03-17 19:18:50+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 + [bug 1014] VC9 equivalent to ntp.dsw (checkin comment only change) + + ports/winnt/ntp.sln@1.1, 2009-03-17 19:12:52+00:00, davehart@shiny.ad.hartbrothers.com +71 -0 + BitKeeper file C:/ntp/ntp-dev-1014/ports/winnt/ntp.sln + + ports/winnt/ntp.sln@1.0, 2009-03-17 19:12:52+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/ntpd/ntpd.vcproj@1.1, 2009-03-17 19:15:19+00:00, davehart@shiny.ad.hartbrothers.com +2218 -0 + [bug 1014] VC9 equivalent to .dsp + + ports/winnt/ntpd/ntpd.vcproj@1.0, 2009-03-17 19:15:19+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/ntpdate/ntpdate.vcproj@1.1, 2009-03-17 19:15:19+00:00, davehart@shiny.ad.hartbrothers.com +327 -0 + [bug 1014] VC9 equivalent to .dsp + + ports/winnt/ntpdate/ntpdate.vcproj@1.0, 2009-03-17 19:15:19+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/ntpdc/ntpdc.vcproj@1.1, 2009-03-17 19:15:19+00:00, davehart@shiny.ad.hartbrothers.com +376 -0 + [bug 1014] VC9 equivalent to .dsp + + ports/winnt/ntpdc/ntpdc.vcproj@1.0, 2009-03-17 19:15:19+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/ntpq/ntpq.vcproj@1.1, 2009-03-17 19:15:19+00:00, davehart@shiny.ad.hartbrothers.com +370 -0 + [bug 1014] VC9 equivalent to .dsp + + ports/winnt/ntpq/ntpq.vcproj@1.0, 2009-03-17 19:15:19+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + +ChangeSet@1.1436.19.1, 2009-03-17 18:39:09+00:00, davehart@shiny.ad.hartbrothers.com +8 -0 + add .sln and .vcproj files for VC9 + + ports/winnt/instsrv/Instsrv.vcproj@1.1, 2009-03-17 18:34:21+00:00, davehart@shiny.ad.hartbrothers.com +253 -0 + VC9 equivalent to Instsrv.dsp + + ports/winnt/instsrv/Instsrv.vcproj@1.0, 2009-03-17 18:34:21+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/libntp/libntp.vcproj@1.1, 2009-03-17 18:35:45+00:00, davehart@shiny.ad.hartbrothers.com +2229 -0 + VC9 equivalent to libntp.dsp + + ports/winnt/libntp/libntp.vcproj@1.0, 2009-03-17 18:35:45+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/ntp-keygen/ntpkeygen.vcproj@1.1, 2009-03-17 18:36:28+00:00, davehart@shiny.ad.hartbrothers.com +419 -0 + VC9 equivalent to ntpkeygen.dsp + + ports/winnt/ntp-keygen/ntpkeygen.vcproj@1.0, 2009-03-17 18:36:28+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/ntp.sln@1.1, 2009-03-17 18:38:44+00:00, davehart@shiny.ad.hartbrothers.com +71 -0 + VC9 equivalent to ntp.dsw + + ports/winnt/ntp.sln@1.0, 2009-03-17 18:38:44+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/ntpd/ntpd.vcproj@1.1, 2009-03-17 18:36:49+00:00, davehart@shiny.ad.hartbrothers.com +2198 -0 + VC9 equivalent to ntpd.dsp + + ports/winnt/ntpd/ntpd.vcproj@1.0, 2009-03-17 18:36:49+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/ntpdate/ntpdate.vcproj@1.1, 2009-03-17 18:37:19+00:00, davehart@shiny.ad.hartbrothers.com +327 -0 + VC9 equivalent to ntpdate.dsp + + ports/winnt/ntpdate/ntpdate.vcproj@1.0, 2009-03-17 18:37:19+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/ntpdc/ntpdc.vcproj@1.1, 2009-03-17 18:37:32+00:00, davehart@shiny.ad.hartbrothers.com +376 -0 + VC9 equivalent to ntpdc.dsp + + ports/winnt/ntpdc/ntpdc.vcproj@1.0, 2009-03-17 18:37:31+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + + ports/winnt/ntpq/ntpq.vcproj@1.1, 2009-03-17 18:37:48+00:00, davehart@shiny.ad.hartbrothers.com +370 -0 + VC9 equivalent to ntpq.dsp + + ports/winnt/ntpq/ntpq.vcproj@1.0, 2009-03-17 18:37:48+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + +ChangeSet@1.1436.17.3, 2009-03-17 18:18:13+00:00, hart@pogo.udel.edu +1 -0 + config.h: + now works with VC6 and VC9 compilers, declares DWORD_PTR on VC6 + + ports/winnt/include/config.h@1.46.1.2, 2009-03-17 18:18:01+00:00, hart@pogo.udel.edu +243 -96 + now works with VC6 and VC9 compilers, declares DWORD_PTR on VC6 + +ChangeSet@1.1796.4.3, 2009-03-17 18:15:41+00:00, hart@pogo.udel.edu +1 -0 + config.h: + now works with VC6 and VC9 compilers, declares DWORD_PTR for VC6 + + ports/winnt/include/config.h@1.55, 2009-03-17 18:14:03+00:00, hart@pogo.udel.edu +238 -116 + now works with VC6 and VC9 compilers + +ChangeSet@1.1436.18.1, 2009-02-21 07:45:56-05:00, utterback@pogo.udel.edu +2 -0 + configure.ac, ChangeLog: + [BUG 1131] UDP sockets should not use SIGPOLL on Solaris. + + ChangeLog@1.1.13.1, 2009-02-20 12:30:18-05:00, utterback@pogo.udel.edu +2 -0 + [BUG 1131] UDP sockets should not use SIGPOLL on Solaris. + + configure.ac@1.400.1.2, 2009-02-20 11:30:02-05:00, utterback@pogo.udel.edu +3 -0 + [BUG 1131] UDP sockets should not use SIGPOLL on Solaris. + +ChangeSet@1.1436.17.2, 2009-02-07 21:13:17+00:00, hart@pogo.udel.edu +1 -0 + ChangeLog: + formatting of newest line + + ChangeLog@1.1.12.2, 2009-02-07 21:12:26+00:00, hart@pogo.udel.edu +1 -1 + formatting of newest line + +ChangeSet@1.1436.17.1, 2009-02-07 21:05:32+00:00, hart@pogo.udel.edu +3 -0 + nt_clockstuff.c, ChangeLog, ntp_iocompletionport.c: + [BUG 1124] Lock QueryPerformanceCounter() client threads to same CPU + + ChangeLog@1.1.12.1, 2009-02-07 21:04:52+00:00, hart@pogo.udel.edu +2 -0 + [BUG 1124] Lock QueryPerformanceCounter() client threads to same CPU + + ports/winnt/ntpd/nt_clockstuff.c@1.23.1.1, 2009-02-07 21:02:04+00:00, hart@pogo.udel.edu +89 -22 + [BUG 1124] Lock QueryPerformanceCounter() client threads to same CPU + + ports/winnt/ntpd/ntp_iocompletionport.c@1.21.1.6, 2009-02-07 21:03:34+00:00, hart@pogo.udel.edu +12 -0 + [BUG 1124] Lock QueryPerformanceCounter() client threads to same CPU + +ChangeSet@1.1436.15.14, 2009-02-07 14:08:35-05:00, hart@pogo.udel.edu +1 -0 + ChangeLog: + DPRINTF safer + + ChangeLog@1.1.1.50, 2009-02-07 14:07:34-05:00, hart@pogo.udel.edu +2 -0 + DPRINTF safer + +ChangeSet@1.1436.15.13, 2009-02-06 19:00:15-05:00, hart@pogo.udel.edu +2 -0 + ntp_debug.h: + DPRINTF won't eat following else, always evaluates to a statement + ntp_io.c: + DPRINTF_INTERFACE always evaluates to a statement + fix DPRINTF use with misplaced semicolon + + include/ntp_debug.h@1.2, 2009-02-06 18:50:27-05:00, hart@pogo.udel.edu +6 -4 + DPRINTF won't eat following else, always evaluates to a statement + + ntpd/ntp_io.c@1.244.2.13, 2009-02-06 18:53:58-05:00, hart@pogo.udel.edu +2 -2 + DPRINTF_INTERFACE always evaluates to a statement + fix DPRINTF use with misplaced semicolon + +ChangeSet@1.1796.1.13, 2009-01-30 06:54:34-05:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P158 + TAG: NTP_4_2_5P158 + + ChangeLog@1.268.1.13, 2009-01-30 06:54:05-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P158 + + gsoc_sntp/sntp-opts.c@1.19, 2009-01-30 06:54:07-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P158 + + gsoc_sntp/sntp-opts.h@1.19, 2009-01-30 06:54:08-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P158 + + gsoc_sntp/sntp-opts.texi@1.19, 2009-01-30 06:54:09-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P158 + + gsoc_sntp/sntp.1@1.19, 2009-01-30 06:54:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P158 + + ntpd/ntpd-opts.c@1.150, 2009-01-30 06:54:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P158 + + ntpd/ntpd-opts.h@1.150, 2009-01-30 06:54:11-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P158 + + ntpd/ntpd-opts.texi@1.149, 2009-01-30 06:54:12-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P158 + + ntpd/ntpd.1@1.149, 2009-01-30 06:54:13-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P158 + + ntpdc/ntpdc-opts.c@1.146, 2009-01-30 06:54:13-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P158 + + ntpdc/ntpdc-opts.h@1.146, 2009-01-30 06:54:14-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P158 + + ntpdc/ntpdc-opts.texi@1.145, 2009-01-30 06:54:15-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P158 + + ntpdc/ntpdc.1@1.145, 2009-01-30 06:54:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P158 + + ntpq/ntpq-opts.c@1.146, 2009-01-30 06:54:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P158 + + ntpq/ntpq-opts.h@1.146, 2009-01-30 06:54:17-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P158 + + ntpq/ntpq-opts.texi@1.145, 2009-01-30 06:54:18-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P158 + + ntpq/ntpq.1@1.145, 2009-01-30 06:54:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P158 + + ntpsnmpd/ntpsnmpd-opts.c@1.27, 2009-01-30 06:54:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P158 + + ntpsnmpd/ntpsnmpd-opts.h@1.27, 2009-01-30 06:54:20-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P158 + + ntpsnmpd/ntpsnmpd-opts.texi@1.27, 2009-01-30 06:54:21-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P158 + + ntpsnmpd/ntpsnmpd.1@1.27, 2009-01-30 06:54:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P158 + + packageinfo.sh@1.161, 2009-01-30 06:54:22-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P158 + + sntp/sntp-opts.c@1.146, 2009-01-30 06:54:23-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P158 + + sntp/sntp-opts.h@1.146, 2009-01-30 06:54:24-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P158 + + sntp/sntp-opts.texi@1.145, 2009-01-30 06:54:25-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P158 + + sntp/sntp.1@1.145, 2009-01-30 06:54:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P158 + + util/ntp-keygen-opts.c@1.149, 2009-01-30 06:54:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P158 + + util/ntp-keygen-opts.h@1.149, 2009-01-30 06:54:28-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P158 + + util/ntp-keygen-opts.texi@1.148, 2009-01-30 06:54:29-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P158 + + util/ntp-keygen.1@1.148, 2009-01-30 06:54:30-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P158 + +ChangeSet@1.1796.1.12, 2009-01-30 03:47:58-05:00, stenn@whimsy.udel.edu +2 -0 + Fix [CID 72], a typo introduced at the latest fix to prettydate.c + + ChangeLog@1.268.1.12, 2009-01-30 03:47:40-05:00, stenn@whimsy.udel.edu +1 -0 + Fix [CID 72], a typo introduced at the latest fix to prettydate.c + + libntp/prettydate.c@1.10, 2009-01-30 03:47:41-05:00, stenn@whimsy.udel.edu +2 -1 + Fix [CID 72], a typo introduced at the latest fix to prettydate.c + +ChangeSet@1.1796.1.11, 2009-01-26 06:55:24-05:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P157 + TAG: NTP_4_2_5P157 + + ChangeLog@1.268.1.11, 2009-01-26 06:54:51-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P157 + + gsoc_sntp/sntp-opts.c@1.18, 2009-01-26 06:54:53-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P157 + + gsoc_sntp/sntp-opts.h@1.18, 2009-01-26 06:54:54-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P157 + + gsoc_sntp/sntp-opts.texi@1.18, 2009-01-26 06:54:55-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P157 + + gsoc_sntp/sntp.1@1.18, 2009-01-26 06:54:56-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P157 + + ntpd/ntpd-opts.c@1.149, 2009-01-26 06:54:58-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P157 + + ntpd/ntpd-opts.h@1.149, 2009-01-26 06:54:58-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P157 + + ntpd/ntpd-opts.texi@1.148, 2009-01-26 06:55:00-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P157 + + ntpd/ntpd.1@1.148, 2009-01-26 06:55:01-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P157 + + ntpdc/ntpdc-opts.c@1.145, 2009-01-26 06:55:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P157 + + ntpdc/ntpdc-opts.h@1.145, 2009-01-26 06:55:03-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P157 + + ntpdc/ntpdc-opts.texi@1.144, 2009-01-26 06:55:04-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P157 + + ntpdc/ntpdc.1@1.144, 2009-01-26 06:55:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P157 + + ntpq/ntpq-opts.c@1.145, 2009-01-26 06:55:07-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P157 + + ntpq/ntpq-opts.h@1.145, 2009-01-26 06:55:08-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P157 + + ntpq/ntpq-opts.texi@1.144, 2009-01-26 06:55:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P157 + + ntpq/ntpq.1@1.144, 2009-01-26 06:55:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P157 + + ntpsnmpd/ntpsnmpd-opts.c@1.26, 2009-01-26 06:55:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P157 + + ntpsnmpd/ntpsnmpd-opts.h@1.26, 2009-01-26 06:55:11-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P157 + + ntpsnmpd/ntpsnmpd-opts.texi@1.26, 2009-01-26 06:55:12-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P157 + + ntpsnmpd/ntpsnmpd.1@1.26, 2009-01-26 06:55:13-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P157 + + packageinfo.sh@1.160, 2009-01-26 06:55:13-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P157 + + sntp/sntp-opts.c@1.145, 2009-01-26 06:55:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P157 + + sntp/sntp-opts.h@1.145, 2009-01-26 06:55:15-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P157 + + sntp/sntp-opts.texi@1.144, 2009-01-26 06:55:16-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P157 + + sntp/sntp.1@1.144, 2009-01-26 06:55:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P157 + + util/ntp-keygen-opts.c@1.148, 2009-01-26 06:55:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P157 + + util/ntp-keygen-opts.h@1.148, 2009-01-26 06:55:18-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P157 + + util/ntp-keygen-opts.texi@1.147, 2009-01-26 06:55:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P157 + + util/ntp-keygen.1@1.147, 2009-01-26 06:55:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P157 + +ChangeSet@1.1796.1.10, 2009-01-26 02:08:57-05:00, stenn@whimsy.udel.edu +3 -0 + Cleanup/fixes for ntp_proto.c and ntp_crypto.c from Dave Mills + + ChangeLog@1.268.1.10, 2009-01-26 02:05:41-05:00, stenn@whimsy.udel.edu +1 -0 + Cleanup/fixes for ntp_proto.c and ntp_crypto.c from Dave Mills + + ntpd/ntp_crypto.c@1.128, 2009-01-26 02:05:44-05:00, stenn@whimsy.udel.edu +31 -16 + Cleanup/fixes for ntp_proto.c and ntp_crypto.c from Dave Mills + + ntpd/ntp_proto.c@1.276.1.1, 2009-01-26 02:05:45-05:00, stenn@whimsy.udel.edu +7 -12 + Cleanup/fixes for ntp_proto.c and ntp_crypto.c from Dave Mills + +ChangeSet@1.1796.1.9, 2009-01-19 06:56:21-05:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P156 + TAG: NTP_4_2_5P156 + + ChangeLog@1.268.1.9, 2009-01-19 06:55:53-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P156 + + gsoc_sntp/sntp-opts.c@1.17, 2009-01-19 06:55:54-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P156 + + gsoc_sntp/sntp-opts.h@1.17, 2009-01-19 06:55:55-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P156 + + gsoc_sntp/sntp-opts.texi@1.17, 2009-01-19 06:55:56-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P156 + + gsoc_sntp/sntp.1@1.17, 2009-01-19 06:55:57-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P156 + + ntpd/ntpd-opts.c@1.148, 2009-01-19 06:55:58-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P156 + + ntpd/ntpd-opts.h@1.148, 2009-01-19 06:55:59-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P156 + + ntpd/ntpd-opts.texi@1.147, 2009-01-19 06:56:00-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P156 + + ntpd/ntpd.1@1.147, 2009-01-19 06:56:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P156 + + ntpdc/ntpdc-opts.c@1.144, 2009-01-19 06:56:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P156 + + ntpdc/ntpdc-opts.h@1.144, 2009-01-19 06:56:03-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P156 + + ntpdc/ntpdc-opts.texi@1.143, 2009-01-19 06:56:04-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P156 + + ntpdc/ntpdc.1@1.143, 2009-01-19 06:56:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P156 + + ntpq/ntpq-opts.c@1.144, 2009-01-19 06:56:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P156 + + ntpq/ntpq-opts.h@1.144, 2009-01-19 06:56:06-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P156 + + ntpq/ntpq-opts.texi@1.143, 2009-01-19 06:56:07-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P156 + + ntpq/ntpq.1@1.143, 2009-01-19 06:56:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P156 + + ntpsnmpd/ntpsnmpd-opts.c@1.25, 2009-01-19 06:56:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P156 + + ntpsnmpd/ntpsnmpd-opts.h@1.25, 2009-01-19 06:56:09-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P156 + + ntpsnmpd/ntpsnmpd-opts.texi@1.25, 2009-01-19 06:56:10-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P156 + + ntpsnmpd/ntpsnmpd.1@1.25, 2009-01-19 06:56:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P156 + + packageinfo.sh@1.159, 2009-01-19 06:56:11-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P156 + + sntp/sntp-opts.c@1.144, 2009-01-19 06:56:12-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P156 + + sntp/sntp-opts.h@1.144, 2009-01-19 06:56:12-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P156 + + sntp/sntp-opts.texi@1.143, 2009-01-19 06:56:13-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P156 + + sntp/sntp.1@1.143, 2009-01-19 06:56:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P156 + + util/ntp-keygen-opts.c@1.147, 2009-01-19 06:56:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P156 + + util/ntp-keygen-opts.h@1.147, 2009-01-19 06:56:15-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P156 + + util/ntp-keygen-opts.texi@1.146, 2009-01-19 06:56:16-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P156 + + util/ntp-keygen.1@1.146, 2009-01-19 06:56:17-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P156 + +ChangeSet@1.1796.3.7, 2009-01-19 03:51:58-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1119] [CID 52] Avoid a possible null-dereference in ntp_crypto.c + + ChangeLog@1.268.3.7, 2009-01-19 03:51:27-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1119] [CID 52] Avoid a possible null-dereference in ntp_crypto.c + + ntpd/ntp_crypto.c@1.127, 2009-01-19 03:51:28-05:00, stenn@whimsy.udel.edu +7 -7 + [Bug 1119] [CID 52] Avoid a possible null-dereference in ntp_crypto.c + +ChangeSet@1.1796.3.6, 2009-01-19 03:41:10-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1120] [CID 51] INSIST that peer is non-null before we dereference it + + ChangeLog@1.268.3.6, 2009-01-19 03:40:54-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1120] [CID 51] INSIST that peer is non-null before we dereference it + + ntpd/ntp_control.c@1.107, 2009-01-19 03:40:54-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1120] [CID 51] INSIST that peer is non-null before we dereference it + +ChangeSet@1.1796.3.5, 2009-01-19 02:58:27-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1121] [CID 47] double fclose() in ntp-keygen.c + + ChangeLog@1.268.3.5, 2009-01-19 02:58:07-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1121] [CID 47] double fclose() in ntp-keygen.c + + util/ntp-keygen.c@1.53, 2009-01-19 02:58:08-05:00, stenn@whimsy.udel.edu +0 -1 + [Bug 1121] [CID 47] double fclose() in ntp-keygen.c + +ChangeSet@1.1796.3.4, 2009-01-18 06:55:12-05:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P155 + TAG: NTP_4_2_5P155 + + ChangeLog@1.268.3.4, 2009-01-18 06:54:42-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P155 + + gsoc_sntp/sntp-opts.c@1.16, 2009-01-18 06:54:43-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P155 + + gsoc_sntp/sntp-opts.h@1.16, 2009-01-18 06:54:44-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P155 + + gsoc_sntp/sntp-opts.texi@1.16, 2009-01-18 06:54:45-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P155 + + gsoc_sntp/sntp.1@1.16, 2009-01-18 06:54:46-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P155 + + ntpd/ntpd-opts.c@1.147, 2009-01-18 06:54:47-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P155 + + ntpd/ntpd-opts.h@1.147, 2009-01-18 06:54:48-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P155 + + ntpd/ntpd-opts.texi@1.146, 2009-01-18 06:54:48-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P155 + + ntpd/ntpd.1@1.146, 2009-01-18 06:54:49-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P155 + + ntpdc/ntpdc-opts.c@1.143, 2009-01-18 06:54:50-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P155 + + ntpdc/ntpdc-opts.h@1.143, 2009-01-18 06:54:51-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P155 + + ntpdc/ntpdc-opts.texi@1.142, 2009-01-18 06:54:52-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P155 + + ntpdc/ntpdc.1@1.142, 2009-01-18 06:54:53-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P155 + + ntpq/ntpq-opts.c@1.143, 2009-01-18 06:54:54-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P155 + + ntpq/ntpq-opts.h@1.143, 2009-01-18 06:54:55-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P155 + + ntpq/ntpq-opts.texi@1.142, 2009-01-18 06:54:55-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P155 + + ntpq/ntpq.1@1.142, 2009-01-18 06:54:56-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P155 + + ntpsnmpd/ntpsnmpd-opts.c@1.24, 2009-01-18 06:54:57-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P155 + + ntpsnmpd/ntpsnmpd-opts.h@1.24, 2009-01-18 06:54:59-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P155 + + ntpsnmpd/ntpsnmpd-opts.texi@1.24, 2009-01-18 06:54:59-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P155 + + ntpsnmpd/ntpsnmpd.1@1.24, 2009-01-18 06:55:00-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P155 + + packageinfo.sh@1.158, 2009-01-18 06:55:00-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P155 + + sntp/sntp-opts.c@1.143, 2009-01-18 06:55:01-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P155 + + sntp/sntp-opts.h@1.143, 2009-01-18 06:55:02-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P155 + + sntp/sntp-opts.texi@1.142, 2009-01-18 06:55:03-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P155 + + sntp/sntp.1@1.142, 2009-01-18 06:55:04-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P155 + + util/ntp-keygen-opts.c@1.146, 2009-01-18 06:55:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P155 + + util/ntp-keygen-opts.h@1.146, 2009-01-18 06:55:06-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P155 + + util/ntp-keygen-opts.texi@1.145, 2009-01-18 06:55:08-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P155 + + util/ntp-keygen.1@1.145, 2009-01-18 06:55:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P155 + +ChangeSet@1.1796.3.3, 2009-01-17 19:30:18-05:00, stenn@whimsy.udel.edu +5 -0 + Documentation updates from Dave Mills + + ChangeLog@1.268.3.3, 2009-01-17 19:30:07-05:00, stenn@whimsy.udel.edu +1 -0 + Documentation updates from Dave Mills + + html/assoc.html@1.27, 2009-01-17 19:29:30-05:00, stenn@whimsy.udel.edu +6 -1 + Documentation updates from Dave Mills + + html/config.html@1.22, 2009-01-17 19:29:32-05:00, stenn@whimsy.udel.edu +19 -149 + Documentation updates from Dave Mills + + html/decode.html@1.5, 2009-01-17 19:29:33-05:00, stenn@whimsy.udel.edu +9 -4 + Documentation updates from Dave Mills + + html/ntpd.html@1.47, 2009-01-17 19:29:38-05:00, stenn@whimsy.udel.edu +21 -5 + Documentation updates from Dave Mills + +ChangeSet@1.1796.3.2, 2009-01-17 19:25:33-05:00, stenn@whimsy.udel.edu +3 -0 + CHU Frequency updates + + ChangeLog@1.268.3.2, 2009-01-17 19:25:16-05:00, stenn@whimsy.udel.edu +1 -0 + CHU Frequency updates + + html/drivers/driver7.html@1.27, 2009-01-17 19:25:14-05:00, stenn@whimsy.udel.edu +11 -2 + CHU Frequency updates + + ntpd/refclock_chu.c@1.45, 2009-01-17 19:25:15-05:00, stenn@whimsy.udel.edu +4 -4 + CHU Frequency updates + +ChangeSet@1.1796.3.1, 2009-01-17 19:08:44-05:00, stenn@whimsy.udel.edu +2 -0 + Design assertion fixes for ntp_crypto.c from Dave Mills + + ChangeLog@1.268.3.1, 2009-01-17 19:08:29-05:00, stenn@whimsy.udel.edu +1 -0 + Design assertion fixes for ntp_crypto.c from Dave Mills + + ntpd/ntp_crypto.c@1.126, 2009-01-17 19:08:31-05:00, stenn@whimsy.udel.edu +3 -6 + Design assertion fixes for ntp_crypto.c from Dave Mills + +ChangeSet@1.1796.1.7, 2009-01-16 15:53:26+01:00, burnicki@pogo.udel.edu +5 -0 + Bug 1118: Fixed sign extension for 32 bit time_t in caljulian() and prettydate(). + Fixed some compiler warnings about missing prototypes. + Fixed some other simple compiler warnings. + + ChangeLog@1.268.1.7, 2009-01-16 15:53:26+01:00, burnicki@pogo.udel.edu +3 -0 + Bug 1118: Fixed sign extension for 32 bit time_t in caljulian() and prettydate(). + Fixed some compiler warnings about missing prototypes. + Fixed some other simple compiler warnings. + + include/recvbuff.h@1.16, 2009-01-16 15:21:51+01:00, burnicki@pogo.udel.edu +2 -1 + Added prototype for get_free_recv_buffer_alloc(). + + libntp/caljulian.c@1.11, 2009-01-16 15:21:51+01:00, burnicki@pogo.udel.edu +11 -2 + Bug 1118: Fixed sign extension for 32 bit time_t. + Added 2 casts to fix compiler warnings. + + libntp/prettydate.c@1.9, 2009-01-16 15:25:43+01:00, burnicki@pogo.udel.edu +10 -1 + Bug 1118: Fixed sign extension for 32 bit time_t. + Fixed a compiler warning. + + ntpd/ntp_timer.c@1.49, 2009-01-12 10:58:20+01:00, burnicki@pogo.udel.edu +4 -1 + Include openssl/rand.h to have prototypes available. + +ChangeSet@1.1796.1.6, 2009-01-13 06:57:59-05:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P154 + TAG: NTP_4_2_5P154 + + ChangeLog@1.268.1.6, 2009-01-13 06:57:31-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P154 + + gsoc_sntp/sntp-opts.c@1.15, 2009-01-13 06:57:33-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P154 + + gsoc_sntp/sntp-opts.h@1.15, 2009-01-13 06:57:33-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P154 + + gsoc_sntp/sntp-opts.texi@1.15, 2009-01-13 06:57:34-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P154 + + gsoc_sntp/sntp.1@1.15, 2009-01-13 06:57:35-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P154 + + ntpd/ntpd-opts.c@1.146, 2009-01-13 06:57:36-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P154 + + ntpd/ntpd-opts.h@1.146, 2009-01-13 06:57:36-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P154 + + ntpd/ntpd-opts.texi@1.145, 2009-01-13 06:57:37-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P154 + + ntpd/ntpd.1@1.145, 2009-01-13 06:57:38-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P154 + + ntpdc/ntpdc-opts.c@1.142, 2009-01-13 06:57:39-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P154 + + ntpdc/ntpdc-opts.h@1.142, 2009-01-13 06:57:39-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P154 + + ntpdc/ntpdc-opts.texi@1.141, 2009-01-13 06:57:41-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P154 + + ntpdc/ntpdc.1@1.141, 2009-01-13 06:57:41-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P154 + + ntpq/ntpq-opts.c@1.142, 2009-01-13 06:57:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P154 + + ntpq/ntpq-opts.h@1.142, 2009-01-13 06:57:44-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P154 + + ntpq/ntpq-opts.texi@1.141, 2009-01-13 06:57:44-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P154 + + ntpq/ntpq.1@1.141, 2009-01-13 06:57:45-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P154 + + ntpsnmpd/ntpsnmpd-opts.c@1.23, 2009-01-13 06:57:46-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P154 + + ntpsnmpd/ntpsnmpd-opts.h@1.23, 2009-01-13 06:57:46-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P154 + + ntpsnmpd/ntpsnmpd-opts.texi@1.23, 2009-01-13 06:57:47-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P154 + + ntpsnmpd/ntpsnmpd.1@1.23, 2009-01-13 06:57:48-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P154 + + packageinfo.sh@1.157, 2009-01-13 06:57:48-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P154 + + sntp/sntp-opts.c@1.142, 2009-01-13 06:57:49-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P154 + + sntp/sntp-opts.h@1.142, 2009-01-13 06:57:50-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P154 + + sntp/sntp-opts.texi@1.141, 2009-01-13 06:57:51-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P154 + + sntp/sntp.1@1.141, 2009-01-13 06:57:51-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P154 + + util/ntp-keygen-opts.c@1.145, 2009-01-13 06:57:52-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P154 + + util/ntp-keygen-opts.h@1.145, 2009-01-13 06:57:53-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P154 + + util/ntp-keygen-opts.texi@1.144, 2009-01-13 06:57:54-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P154 + + util/ntp-keygen.1@1.144, 2009-01-13 06:57:55-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P154 + +ChangeSet@1.1796.1.5, 2009-01-11 16:53:36+00:00, kardel@pogo.udel.edu +3 -0 + ChangeLog: + bug 992 - support interface event change on Linux + configure.ac, ntp_io.c: + support interface event change on Linux + + ChangeLog@1.268.1.5, 2009-01-11 16:51:59+00:00, kardel@pogo.udel.edu +2 -0 + bug 992 - support interface event change on Linux + + configure.ac@1.422, 2009-01-11 16:52:21+00:00, kardel@pogo.udel.edu +13 -1 + support interface event change on Linux + + ntpd/ntp_io.c@1.275, 2009-01-11 16:52:40+00:00, kardel@pogo.udel.edu +55 -13 + support interface event change on Linux + +ChangeSet@1.1796.1.4, 2009-01-09 07:20:22-05:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P153 + TAG: NTP_4_2_5P153 + + ChangeLog@1.268.1.4, 2009-01-09 07:19:44-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P153 + + gsoc_sntp/sntp-opts.c@1.14, 2009-01-09 07:19:46-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P153 + + gsoc_sntp/sntp-opts.h@1.14, 2009-01-09 07:19:47-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P153 + + gsoc_sntp/sntp-opts.texi@1.14, 2009-01-09 07:19:48-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P153 + + gsoc_sntp/sntp.1@1.14, 2009-01-09 07:19:48-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P153 + + ntpd/ntpd-opts.c@1.145, 2009-01-09 07:19:49-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P153 + + ntpd/ntpd-opts.h@1.145, 2009-01-09 07:19:51-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P153 + + ntpd/ntpd-opts.texi@1.144, 2009-01-09 07:19:52-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P153 + + ntpd/ntpd.1@1.144, 2009-01-09 07:19:53-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P153 + + ntpdc/ntpdc-opts.c@1.141, 2009-01-09 07:19:53-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P153 + + ntpdc/ntpdc-opts.h@1.141, 2009-01-09 07:19:54-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P153 + + ntpdc/ntpdc-opts.texi@1.140, 2009-01-09 07:19:55-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P153 + + ntpdc/ntpdc.1@1.140, 2009-01-09 07:19:56-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P153 + + ntpq/ntpq-opts.c@1.141, 2009-01-09 07:19:56-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P153 + + ntpq/ntpq-opts.h@1.141, 2009-01-09 07:19:58-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P153 + + ntpq/ntpq-opts.texi@1.140, 2009-01-09 07:19:58-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P153 + + ntpq/ntpq.1@1.140, 2009-01-09 07:20:00-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P153 + + ntpsnmpd/ntpsnmpd-opts.c@1.22, 2009-01-09 07:20:00-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P153 + + ntpsnmpd/ntpsnmpd-opts.h@1.22, 2009-01-09 07:20:02-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P153 + + ntpsnmpd/ntpsnmpd-opts.texi@1.22, 2009-01-09 07:20:03-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P153 + + ntpsnmpd/ntpsnmpd.1@1.22, 2009-01-09 07:20:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P153 + + packageinfo.sh@1.156, 2009-01-09 07:20:05-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P153 + + sntp/sntp-opts.c@1.141, 2009-01-09 07:20:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P153 + + sntp/sntp-opts.h@1.141, 2009-01-09 07:20:06-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P153 + + sntp/sntp-opts.texi@1.140, 2009-01-09 07:20:08-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P153 + + sntp/sntp.1@1.140, 2009-01-09 07:20:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P153 + + util/ntp-keygen-opts.c@1.144, 2009-01-09 07:20:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P153 + + util/ntp-keygen-opts.h@1.144, 2009-01-09 07:20:12-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P153 + + util/ntp-keygen-opts.texi@1.143, 2009-01-09 07:20:13-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P153 + + util/ntp-keygen.1@1.143, 2009-01-09 07:20:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P153 + +ChangeSet@1.1796.2.3, 2009-01-08 09:46:10-05:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P152 + TAG: NTP_4_2_5P152 + + ChangeLog@1.268.2.2, 2009-01-08 09:45:39-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P152 + + gsoc_sntp/sntp-opts.c@1.13, 2009-01-08 09:45:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P152 + + gsoc_sntp/sntp-opts.h@1.13, 2009-01-08 09:45:41-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P152 + + gsoc_sntp/sntp-opts.texi@1.13, 2009-01-08 09:45:42-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P152 + + gsoc_sntp/sntp.1@1.13, 2009-01-08 09:45:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P152 + + ntpd/ntpd-opts.c@1.144, 2009-01-08 09:45:44-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P152 + + ntpd/ntpd-opts.h@1.144, 2009-01-08 09:45:45-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P152 + + ntpd/ntpd-opts.texi@1.143, 2009-01-08 09:45:46-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P152 + + ntpd/ntpd.1@1.143, 2009-01-08 09:45:47-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P152 + + ntpdc/ntpdc-opts.c@1.140, 2009-01-08 09:45:48-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P152 + + ntpdc/ntpdc-opts.h@1.140, 2009-01-08 09:45:48-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P152 + + ntpdc/ntpdc-opts.texi@1.139, 2009-01-08 09:45:49-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P152 + + ntpdc/ntpdc.1@1.139, 2009-01-08 09:45:50-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P152 + + ntpq/ntpq-opts.c@1.140, 2009-01-08 09:45:51-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P152 + + ntpq/ntpq-opts.h@1.140, 2009-01-08 09:45:52-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P152 + + ntpq/ntpq-opts.texi@1.139, 2009-01-08 09:45:53-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P152 + + ntpq/ntpq.1@1.139, 2009-01-08 09:45:54-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P152 + + ntpsnmpd/ntpsnmpd-opts.c@1.21, 2009-01-08 09:45:55-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P152 + + ntpsnmpd/ntpsnmpd-opts.h@1.21, 2009-01-08 09:45:55-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P152 + + ntpsnmpd/ntpsnmpd-opts.texi@1.21, 2009-01-08 09:45:56-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P152 + + ntpsnmpd/ntpsnmpd.1@1.21, 2009-01-08 09:45:57-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P152 + + packageinfo.sh@1.155, 2009-01-08 09:45:58-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P152 + + sntp/sntp-opts.c@1.140, 2009-01-08 09:45:59-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P152 + + sntp/sntp-opts.h@1.140, 2009-01-08 09:46:00-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P152 + + sntp/sntp-opts.texi@1.139, 2009-01-08 09:46:01-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P152 + + sntp/sntp.1@1.139, 2009-01-08 09:46:01-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P152 + + util/ntp-keygen-opts.c@1.143, 2009-01-08 09:46:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P152 + + util/ntp-keygen-opts.h@1.143, 2009-01-08 09:46:04-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P152 + + util/ntp-keygen-opts.texi@1.142, 2009-01-08 09:46:05-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P152 + + util/ntp-keygen.1@1.142, 2009-01-08 09:46:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P152 + +ChangeSet@1.1796.2.2, 2009-01-08 08:07:59-05:00, stenn@whimsy.udel.edu +1 -0 + merge cleanup + + ntpd/ntp_crypto.c@1.125, 2009-01-08 08:07:38-05:00, stenn@whimsy.udel.edu +1 -1 + merge cleanup + +ChangeSet@1.1436.15.12, 2009-01-08 06:21:48-05:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_4P6 + TAG: NTP_4_2_4P6 + + ChangeLog@1.1.1.49, 2009-01-08 06:21:25-05:00, stenn@whimsy.udel.edu +1 -2 + NTP_4_2_4P6 + + ntpd/ntpd-opts.c@1.50.17.2, 2009-01-08 06:21:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P6 + + ntpd/ntpd-opts.h@1.50.17.2, 2009-01-08 06:21:27-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P6 + + ntpd/ntpd-opts.texi@1.49.17.2, 2009-01-08 06:21:28-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P6 + + ntpd/ntpd.1@1.48.17.2, 2009-01-08 06:21:29-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P6 + + ntpd/ntpdsim-opts.c@1.50.17.2, 2009-01-08 06:21:29-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P6 + + ntpd/ntpdsim-opts.h@1.50.17.2, 2009-01-08 06:21:30-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P6 + + ntpd/ntpdsim-opts.texi@1.48.17.2, 2009-01-08 06:21:31-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P6 + + ntpd/ntpdsim.1@1.48.17.2, 2009-01-08 06:21:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P6 + + ntpdc/ntpdc-opts.c@1.50.17.2, 2009-01-08 06:21:33-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P6 + + ntpdc/ntpdc-opts.h@1.50.17.2, 2009-01-08 06:21:34-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P6 + + ntpdc/ntpdc-opts.texi@1.48.17.2, 2009-01-08 06:21:34-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P6 + + ntpdc/ntpdc.1@1.48.17.2, 2009-01-08 06:21:35-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P6 + + ntpq/ntpq-opts.c@1.52.17.2, 2009-01-08 06:21:36-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P6 + + ntpq/ntpq-opts.h@1.52.17.2, 2009-01-08 06:21:37-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P6 + + ntpq/ntpq-opts.texi@1.49.17.2, 2009-01-08 06:21:37-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P6 + + ntpq/ntpq.1@1.48.17.2, 2009-01-08 06:21:39-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P6 + + packageinfo.sh@1.65.24.4, 2009-01-08 06:21:39-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P6 + + sntp/sntp-opts.c@1.49.17.2, 2009-01-08 06:21:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P6 + + sntp/sntp-opts.h@1.49.17.2, 2009-01-08 06:21:41-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P6 + + sntp/sntp-opts.texi@1.46.17.2, 2009-01-08 06:21:42-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P6 + + sntp/sntp.1@1.49.17.2, 2009-01-08 06:21:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P6 + + util/ntp-keygen-opts.c@1.49.17.2, 2009-01-08 06:21:43-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P6 + + util/ntp-keygen-opts.h@1.49.17.2, 2009-01-08 06:21:44-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P6 + + util/ntp-keygen-opts.texi@1.47.17.2, 2009-01-08 06:21:44-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P6 + + util/ntp-keygen.1@1.47.17.2, 2009-01-08 06:21:45-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P6 + +ChangeSet@1.1436.15.11, 2009-01-08 04:49:23-05:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_4P5 + TAG: NTP_4_2_4P5 + + ChangeLog@1.1.1.48, 2009-01-08 04:48:59-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_4P5 + + ntpd/ntpd-opts.c@1.50.17.1, 2009-01-08 04:49:01-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5 + + ntpd/ntpd-opts.h@1.50.17.1, 2009-01-08 04:49:01-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5 + + ntpd/ntpd-opts.texi@1.49.17.1, 2009-01-08 04:49:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + + ntpd/ntpd.1@1.48.17.1, 2009-01-08 04:49:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + + ntpd/ntpdsim-opts.c@1.50.17.1, 2009-01-08 04:49:04-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5 + + ntpd/ntpdsim-opts.h@1.50.17.1, 2009-01-08 04:49:04-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5 + + ntpd/ntpdsim-opts.texi@1.48.17.1, 2009-01-08 04:49:05-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5 + + ntpd/ntpdsim.1@1.48.17.1, 2009-01-08 04:49:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + + ntpdc/ntpdc-opts.c@1.50.17.1, 2009-01-08 04:49:06-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5 + + ntpdc/ntpdc-opts.h@1.50.17.1, 2009-01-08 04:49:07-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5 + + ntpdc/ntpdc-opts.texi@1.48.17.1, 2009-01-08 04:49:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + + ntpdc/ntpdc.1@1.48.17.1, 2009-01-08 04:49:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + + ntpq/ntpq-opts.c@1.52.17.1, 2009-01-08 04:49:10-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5 + + ntpq/ntpq-opts.h@1.52.17.1, 2009-01-08 04:49:10-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5 + + ntpq/ntpq-opts.texi@1.49.17.1, 2009-01-08 04:49:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + + ntpq/ntpq.1@1.48.17.1, 2009-01-08 04:49:12-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + + packageinfo.sh@1.65.24.3, 2009-01-08 04:49:13-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + + sntp/sntp-opts.c@1.49.17.1, 2009-01-08 04:49:14-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5 + + sntp/sntp-opts.h@1.49.17.1, 2009-01-08 04:49:15-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5 + + sntp/sntp-opts.texi@1.46.17.1, 2009-01-08 04:49:16-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5 + + sntp/sntp.1@1.49.17.1, 2009-01-08 04:49:17-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + + util/ntp-keygen-opts.c@1.49.17.1, 2009-01-08 04:49:18-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5 + + util/ntp-keygen-opts.h@1.49.17.1, 2009-01-08 04:49:19-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5 + + util/ntp-keygen-opts.texi@1.47.17.1, 2009-01-08 04:49:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + + util/ntp-keygen.1@1.47.17.1, 2009-01-08 04:49:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + +ChangeSet@1.1436.15.10, 2009-01-08 03:21:09-05:00, stenn@whimsy.udel.edu +1 -0 + 4.2.4p6 + + packageinfo.sh@1.65.24.2, 2009-01-08 03:20:56-05:00, stenn@whimsy.udel.edu +1 -1 + 4.2.4p6 + +ChangeSet@1.1436.15.9, 2009-01-08 03:14:17-05:00, stenn@whimsy.udel.edu +1 -0 + merge cleanup + + ChangeLog@1.1.1.47, 2009-01-08 03:14:09-05:00, stenn@whimsy.udel.edu +1 -1 + merge cleanup + +ChangeSet@1.1436.16.1, 2009-01-08 02:57:52-05:00, stenn@whimsy.udel.edu +5 -0 + 4.2.4p6 + + ChangeLog@1.1.1.45, 2009-01-07 05:31:52-05:00, stenn@whimsy.udel.edu +6 -0 + Fix incorrect check of EVP_VerifyFinal()'s return value. + + NEWS@1.86.1.14, 2009-01-08 02:57:32-05:00, stenn@whimsy.udel.edu +16 -0 + 4.2.4p6 + + html/copyright.html@1.36.1.2, 2009-01-07 05:30:58-05:00, stenn@whimsy.udel.edu +1 -1 + Update the copyright year + + ntpd/ntp_crypto.c@1.107.1.1, 2009-01-07 05:31:50-05:00, stenn@whimsy.udel.edu +1 -1 + Fix incorrect check of EVP_VerifyFinal()'s return value. + + packageinfo.sh@1.65.24.1, 2009-01-08 02:57:33-05:00, stenn@whimsy.udel.edu +1 -1 + 4.2.4p6 + +ChangeSet@1.1436.15.7, 2009-01-07 18:00:50+01:00, burnicki@pogo.udel.edu +2 -0 + [BUG 1113] Fixed build errors with recent versions of openSSL. + + ChangeLog@1.1.11.1, 2009-01-07 18:00:47+01:00, burnicki@pogo.udel.edu +1 -0 + [BUG 1113] Fixed build errors with recent versions of openSSL. + + ntpd/ntp_crypto.c@1.107.2.1, 2009-01-07 18:00:47+01:00, burnicki@pogo.udel.edu +2 -2 + [BUG 1113] Fixed build errors with recent versions of openSSL. + +ChangeSet@1.1796.1.2, 2009-01-07 15:18:18+01:00, burnicki@pogo.udel.edu +2 -0 + Renamed gsoc_sntp/:fetch-stubs to gsoc_sntp/fetch-stubs to avoid + file name problems under Windows. + Removed German umlaut from log msg for 4.2.5p142. + + ChangeLog@1.268.1.2, 2009-01-07 15:18:12+01:00, burnicki@pogo.udel.edu +4 -1 + Renamed gsoc_sntp/:fetch-stubs to gsoc_sntp/fetch-stubs to avoid + file name problems under Windows. + Removed German umlaut from log msg for 4.2.5p142. + + gsoc_sntp/fetch-stubs@1.5, 2009-01-07 15:05:52+01:00, burnicki@pogo.udel.edu +0 -0 + Rename: gsoc_sntp/:fetch-stubs -> gsoc_sntp/fetch-stubs + +ChangeSet@1.1796.1.1, 2008-12-23 06:53:33-05:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P151 + TAG: NTP_4_2_5P151 + + ChangeLog@1.268.1.1, 2008-12-23 06:53:02-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P151 + + gsoc_sntp/sntp-opts.c@1.12, 2008-12-23 06:53:04-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P151 + + gsoc_sntp/sntp-opts.h@1.12, 2008-12-23 06:53:05-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P151 + + gsoc_sntp/sntp-opts.texi@1.12, 2008-12-23 06:53:06-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P151 + + gsoc_sntp/sntp.1@1.12, 2008-12-23 06:53:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P151 + + ntpd/ntpd-opts.c@1.143, 2008-12-23 06:53:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P151 + + ntpd/ntpd-opts.h@1.143, 2008-12-23 06:53:09-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P151 + + ntpd/ntpd-opts.texi@1.142, 2008-12-23 06:53:09-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P151 + + ntpd/ntpd.1@1.142, 2008-12-23 06:53:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P151 + + ntpdc/ntpdc-opts.c@1.139, 2008-12-23 06:53:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P151 + + ntpdc/ntpdc-opts.h@1.139, 2008-12-23 06:53:11-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P151 + + ntpdc/ntpdc-opts.texi@1.138, 2008-12-23 06:53:12-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P151 + + ntpdc/ntpdc.1@1.138, 2008-12-23 06:53:13-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P151 + + ntpq/ntpq-opts.c@1.139, 2008-12-23 06:53:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P151 + + ntpq/ntpq-opts.h@1.139, 2008-12-23 06:53:14-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P151 + + ntpq/ntpq-opts.texi@1.138, 2008-12-23 06:53:15-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P151 + + ntpq/ntpq.1@1.138, 2008-12-23 06:53:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P151 + + ntpsnmpd/ntpsnmpd-opts.c@1.20, 2008-12-23 06:53:17-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P151 + + ntpsnmpd/ntpsnmpd-opts.h@1.20, 2008-12-23 06:53:18-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P151 + + ntpsnmpd/ntpsnmpd-opts.texi@1.20, 2008-12-23 06:53:19-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P151 + + ntpsnmpd/ntpsnmpd.1@1.20, 2008-12-23 06:53:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P151 + + packageinfo.sh@1.154, 2008-12-23 06:53:20-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P151 + + sntp/sntp-opts.c@1.139, 2008-12-23 06:53:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P151 + + sntp/sntp-opts.h@1.139, 2008-12-23 06:53:22-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P151 + + sntp/sntp-opts.texi@1.138, 2008-12-23 06:53:23-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P151 + + sntp/sntp.1@1.138, 2008-12-23 06:53:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P151 + + util/ntp-keygen-opts.c@1.142, 2008-12-23 06:53:25-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P151 + + util/ntp-keygen-opts.h@1.142, 2008-12-23 06:53:26-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P151 + + util/ntp-keygen-opts.texi@1.141, 2008-12-23 06:53:27-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P151 + + util/ntp-keygen.1@1.141, 2008-12-23 06:53:28-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P151 + +ChangeSet@1.1795.1.1, 2008-12-23 04:34:32-05:00, stenn@whimsy.udel.edu +11 -0 + [Bug 1028] Support for W32Time authentication via Samba + + ChangeLog@1.267.1.1, 2008-12-23 04:33:42-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1028] Support for W32Time authentication via Samba + + include/ntp.h@1.149, 2008-12-23 04:32:53-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1028] Support for W32Time authentication via Samba + + include/ntp_config.h@1.48, 2008-12-23 04:32:54-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1028] Support for W32Time authentication via Samba + + include/ntpd.h@1.119, 2008-12-23 04:32:56-05:00, stenn@whimsy.udel.edu +14 -0 + [Bug 1028] Support for W32Time authentication via Samba + + ntpd/Makefile.am@1.66, 2008-12-23 04:33:07-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 1028] Support for W32Time authentication via Samba + + ntpd/ntp_config.c@1.185, 2008-12-23 04:33:08-05:00, stenn@whimsy.udel.edu +11 -0 + [Bug 1028] Support for W32Time authentication via Samba + + ntpd/ntp_parser.c@1.32, 2008-12-23 04:33:10-05:00, stenn@whimsy.udel.edu +908 -889 + [Bug 1028] Support for W32Time authentication via Samba + + ntpd/ntp_parser.h@1.16, 2008-12-23 04:33:12-05:00, stenn@whimsy.udel.edu +123 -121 + [Bug 1028] Support for W32Time authentication via Samba + + ntpd/ntp_parser.y@1.26, 2008-12-23 04:33:13-05:00, stenn@whimsy.udel.edu +3 -0 + [Bug 1028] Support for W32Time authentication via Samba + + ntpd/ntp_proto.c@1.277, 2008-12-23 04:33:14-05:00, stenn@whimsy.udel.edu +53 -11 + [Bug 1028] Support for W32Time authentication via Samba + + ntpd/ntp_signd.c@1.1, 2008-12-23 04:34:08-05:00, stenn@whimsy.udel.edu +242 -0 + BitKeeper file /deacon/backroom/ntp-dev-samba/ntpd/ntp_signd.c + + ntpd/ntp_signd.c@1.0, 2008-12-23 04:34:08-05:00, stenn@whimsy.udel.edu +0 -0 + +ChangeSet@1.1796, 2008-12-23 02:59:12-05:00, stenn@whimsy.udel.edu +2 -0 + Stats file logging cleanup from Dave Mills + + ChangeLog@1.268, 2008-12-23 02:58:21-05:00, stenn@whimsy.udel.edu +1 -0 + Stats file logging cleanup from Dave Mills + + ntpd/ntp_control.c@1.106, 2008-12-23 02:58:20-05:00, stenn@whimsy.udel.edu +31 -13 + Stats file logging cleanup from Dave Mills + +ChangeSet@1.1795, 2008-12-15 06:54:36-05:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P150 + TAG: NTP_4_2_5P150 + + ChangeLog@1.267, 2008-12-15 06:54:07-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P150 + + gsoc_sntp/sntp-opts.c@1.11, 2008-12-15 06:54:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P150 + + gsoc_sntp/sntp-opts.h@1.11, 2008-12-15 06:54:09-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P150 + + gsoc_sntp/sntp-opts.texi@1.11, 2008-12-15 06:54:10-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P150 + + gsoc_sntp/sntp.1@1.11, 2008-12-15 06:54:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P150 + + ntpd/ntpd-opts.c@1.142, 2008-12-15 06:54:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P150 + + ntpd/ntpd-opts.h@1.142, 2008-12-15 06:54:13-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P150 + + ntpd/ntpd-opts.texi@1.141, 2008-12-15 06:54:13-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P150 + + ntpd/ntpd.1@1.141, 2008-12-15 06:54:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P150 + + ntpdc/ntpdc-opts.c@1.138, 2008-12-15 06:54:15-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P150 + + ntpdc/ntpdc-opts.h@1.138, 2008-12-15 06:54:16-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P150 + + ntpdc/ntpdc-opts.texi@1.137, 2008-12-15 06:54:17-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P150 + + ntpdc/ntpdc.1@1.137, 2008-12-15 06:54:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P150 + + ntpq/ntpq-opts.c@1.138, 2008-12-15 06:54:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P150 + + ntpq/ntpq-opts.h@1.138, 2008-12-15 06:54:19-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P150 + + ntpq/ntpq-opts.texi@1.137, 2008-12-15 06:54:20-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P150 + + ntpq/ntpq.1@1.137, 2008-12-15 06:54:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P150 + + ntpsnmpd/ntpsnmpd-opts.c@1.19, 2008-12-15 06:54:22-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P150 + + ntpsnmpd/ntpsnmpd-opts.h@1.19, 2008-12-15 06:54:23-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P150 + + ntpsnmpd/ntpsnmpd-opts.texi@1.19, 2008-12-15 06:54:24-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P150 + + ntpsnmpd/ntpsnmpd.1@1.19, 2008-12-15 06:54:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P150 + + packageinfo.sh@1.153, 2008-12-15 06:54:26-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P150 + + sntp/sntp-opts.c@1.138, 2008-12-15 06:54:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P150 + + sntp/sntp-opts.h@1.138, 2008-12-15 06:54:27-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P150 + + sntp/sntp-opts.texi@1.137, 2008-12-15 06:54:28-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P150 + + sntp/sntp.1@1.137, 2008-12-15 06:54:29-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P150 + + util/ntp-keygen-opts.c@1.141, 2008-12-15 06:54:29-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P150 + + util/ntp-keygen-opts.h@1.141, 2008-12-15 06:54:30-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P150 + + util/ntp-keygen-opts.texi@1.140, 2008-12-15 06:54:31-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P150 + + util/ntp-keygen.1@1.140, 2008-12-15 06:54:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P150 + +ChangeSet@1.1791.1.3, 2008-12-15 04:12:45-05:00, stenn@pogo.udel.edu +1 -0 + [Bug 1103] Fix 64-bit issues in the new calendar code + + ChangeLog@1.264.1.9, 2008-12-15 04:12:37-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 1103] Fix 64-bit issues in the new calendar code + +ChangeSet@1.1791.2.11, 2008-12-05 07:13:56-05:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P149 + TAG: NTP_4_2_5P149 + + ChangeLog@1.264.1.8, 2008-12-05 07:13:29-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P149 + + gsoc_sntp/sntp-opts.c@1.10, 2008-12-05 07:13:29-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P149 + + gsoc_sntp/sntp-opts.h@1.10, 2008-12-05 07:13:30-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P149 + + gsoc_sntp/sntp-opts.texi@1.10, 2008-12-05 07:13:31-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P149 + + gsoc_sntp/sntp.1@1.10, 2008-12-05 07:13:31-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P149 + + ntpd/ntpd-opts.c@1.141, 2008-12-05 07:13:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P149 + + ntpd/ntpd-opts.h@1.141, 2008-12-05 07:13:33-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P149 + + ntpd/ntpd-opts.texi@1.140, 2008-12-05 07:13:34-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P149 + + ntpd/ntpd.1@1.140, 2008-12-05 07:13:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P149 + + ntpdc/ntpdc-opts.c@1.137, 2008-12-05 07:13:35-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P149 + + ntpdc/ntpdc-opts.h@1.137, 2008-12-05 07:13:36-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P149 + + ntpdc/ntpdc-opts.texi@1.136, 2008-12-05 07:13:37-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P149 + + ntpdc/ntpdc.1@1.136, 2008-12-05 07:13:38-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P149 + + ntpq/ntpq-opts.c@1.137, 2008-12-05 07:13:39-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P149 + + ntpq/ntpq-opts.h@1.137, 2008-12-05 07:13:40-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P149 + + ntpq/ntpq-opts.texi@1.136, 2008-12-05 07:13:41-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P149 + + ntpq/ntpq.1@1.136, 2008-12-05 07:13:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P149 + + ntpsnmpd/ntpsnmpd-opts.c@1.18, 2008-12-05 07:13:43-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P149 + + ntpsnmpd/ntpsnmpd-opts.h@1.18, 2008-12-05 07:13:43-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P149 + + ntpsnmpd/ntpsnmpd-opts.texi@1.18, 2008-12-05 07:13:44-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P149 + + ntpsnmpd/ntpsnmpd.1@1.18, 2008-12-05 07:13:44-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P149 + + packageinfo.sh@1.152, 2008-12-05 07:13:45-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P149 + + sntp/sntp-opts.c@1.137, 2008-12-05 07:13:45-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P149 + + sntp/sntp-opts.h@1.137, 2008-12-05 07:13:46-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P149 + + sntp/sntp-opts.texi@1.136, 2008-12-05 07:13:47-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P149 + + sntp/sntp.1@1.136, 2008-12-05 07:13:48-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P149 + + util/ntp-keygen-opts.c@1.140, 2008-12-05 07:13:49-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P149 + + util/ntp-keygen-opts.h@1.140, 2008-12-05 07:13:49-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P149 + + util/ntp-keygen-opts.texi@1.139, 2008-12-05 07:13:50-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P149 + + util/ntp-keygen.1@1.139, 2008-12-05 07:13:52-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P149 + +ChangeSet@1.1791.2.10, 2008-12-05 05:48:37-05:00, stenn@pogo.udel.edu +1 -0 + Distribute ntpv4-mib.mib + + ntpsnmpd/Makefile.am@1.7, 2008-12-05 05:48:30-05:00, stenn@pogo.udel.edu +4 -2 + Distribute ntpv4-mib.mib + +ChangeSet@1.1791.2.9, 2008-12-05 11:23:22+01:00, gerstung@pogo.udel.edu +1 -0 + * changelog comments added for changes regarding ntpSnmpSubAgent.c and ntpv4-mib.mib + + ChangeLog@1.264.1.7, 2008-12-05 11:23:21+01:00, gerstung@pogo.udel.edu +3 -0 + * changelog comments added for changes regarding ntpSnmpSubAgent.c and ntpv4-mib.mib + +ChangeSet@1.1791.2.8, 2008-12-05 11:13:33+01:00, gerstung@pogo.udel.edu +2 -0 + * fixed two wrong data types + * fixed wrong OID definitions + * added preliminaray and unofficial MIB for TESTING PURPOSES ONLY + + ntpsnmpd/ntpSnmpSubagentObject.c@1.3, 2008-12-05 11:13:33+01:00, gerstung@pogo.udel.edu +16 -17 + * fixed two wrong data types + * fixed wrong OID definitions + + ntpsnmpd/ntpv4-mib.mib@1.1, 2008-12-05 11:13:33+01:00, gerstung@pogo.udel.edu +1005 -0 + * added for testing purposes --- DO NOT USE IN PRODUCTIVE ENVIRONMENTS --- this MIB file will change as soon as the NTPv4 MIB RFC has been approved and the required OID has been registered with IANA + + ntpsnmpd/ntpv4-mib.mib@1.0, 2008-12-05 11:13:33+01:00, gerstung@pogo.udel.edu +0 -0 + +ChangeSet@1.1791.2.7, 2008-12-04 06:53:18-05:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P148 + TAG: NTP_4_2_5P148 + + ChangeLog@1.264.1.6, 2008-12-04 06:52:48-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P148 + + gsoc_sntp/sntp-opts.c@1.9, 2008-12-04 06:52:50-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P148 + + gsoc_sntp/sntp-opts.h@1.9, 2008-12-04 06:52:50-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P148 + + gsoc_sntp/sntp-opts.texi@1.9, 2008-12-04 06:52:51-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P148 + + gsoc_sntp/sntp.1@1.9, 2008-12-04 06:52:52-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P148 + + ntpd/ntpd-opts.c@1.140, 2008-12-04 06:52:52-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P148 + + ntpd/ntpd-opts.h@1.140, 2008-12-04 06:52:53-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P148 + + ntpd/ntpd-opts.texi@1.139, 2008-12-04 06:52:54-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P148 + + ntpd/ntpd.1@1.139, 2008-12-04 06:52:55-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P148 + + ntpdc/ntpdc-opts.c@1.136, 2008-12-04 06:52:55-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P148 + + ntpdc/ntpdc-opts.h@1.136, 2008-12-04 06:52:56-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P148 + + ntpdc/ntpdc-opts.texi@1.135, 2008-12-04 06:52:57-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P148 + + ntpdc/ntpdc.1@1.135, 2008-12-04 06:52:58-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P148 + + ntpq/ntpq-opts.c@1.136, 2008-12-04 06:53:00-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P148 + + ntpq/ntpq-opts.h@1.136, 2008-12-04 06:53:00-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P148 + + ntpq/ntpq-opts.texi@1.135, 2008-12-04 06:53:01-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P148 + + ntpq/ntpq.1@1.135, 2008-12-04 06:53:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P148 + + ntpsnmpd/ntpsnmpd-opts.c@1.17, 2008-12-04 06:53:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P148 + + ntpsnmpd/ntpsnmpd-opts.h@1.17, 2008-12-04 06:53:03-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P148 + + ntpsnmpd/ntpsnmpd-opts.texi@1.17, 2008-12-04 06:53:04-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P148 + + ntpsnmpd/ntpsnmpd.1@1.17, 2008-12-04 06:53:04-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P148 + + packageinfo.sh@1.151, 2008-12-04 06:53:05-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P148 + + sntp/sntp-opts.c@1.136, 2008-12-04 06:53:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P148 + + sntp/sntp-opts.h@1.136, 2008-12-04 06:53:06-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P148 + + sntp/sntp-opts.texi@1.135, 2008-12-04 06:53:07-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P148 + + sntp/sntp.1@1.135, 2008-12-04 06:53:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P148 + + util/ntp-keygen-opts.c@1.139, 2008-12-04 06:53:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P148 + + util/ntp-keygen-opts.h@1.139, 2008-12-04 06:53:09-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P148 + + util/ntp-keygen-opts.texi@1.138, 2008-12-04 06:53:10-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P148 + + util/ntp-keygen.1@1.138, 2008-12-04 06:53:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P148 + +ChangeSet@1.1791.2.6, 2008-12-04 03:33:40-05:00, stenn@pogo.udel.edu +1 -0 + [Bug 1070] Fix use of ntpq_parsestring() in ntpsnmpd + + ChangeLog@1.264.1.5, 2008-12-04 03:33:30-05:00, stenn@pogo.udel.edu +1 -0 + [Bug 1070] Fix use of ntpq_parsestring() in ntpsnmpd + +ChangeSet@1.1791.2.5, 2008-12-04 09:08:53+01:00, gerstung@pogo.udel.edu +2 -0 + * bug 1070 fixed (call to undefined function ntpq_parsestring) + * added new string handler functions for dealing with ntpd responses + * fixed handling of SoftwareName entity (unreachable code) + * added function prototypes to reduce/remove compiler warnings + + ntpsnmpd/ntpSnmpSubagentObject.c@1.2, 2008-12-04 09:08:53+01:00, gerstung@pogo.udel.edu +224 -8 + * bug 1070 fixed (call to undefined function ntpq_parsestring) + * added new string handler functions for dealing with ntpd responses + * fixed handling of SoftwareName entity (unreachable code) + + + ntpsnmpd/ntpSnmpSubagentObject.h@1.2, 2008-12-04 09:08:53+01:00, gerstung@pogo.udel.edu +4 -1 + * added function prototypes to avoid compiler warnings + +ChangeSet@1.1791.2.4, 2008-11-27 06:54:28-05:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P147 + TAG: NTP_4_2_5P147 + + ChangeLog@1.264.1.4, 2008-11-27 06:53:59-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P147 + + gsoc_sntp/sntp-opts.c@1.8, 2008-11-27 06:54:01-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P147 + + gsoc_sntp/sntp-opts.h@1.8, 2008-11-27 06:54:02-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P147 + + gsoc_sntp/sntp-opts.texi@1.8, 2008-11-27 06:54:03-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P147 + + gsoc_sntp/sntp.1@1.8, 2008-11-27 06:54:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P147 + + ntpd/ntpd-opts.c@1.139, 2008-11-27 06:54:04-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P147 + + ntpd/ntpd-opts.h@1.139, 2008-11-27 06:54:05-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P147 + + ntpd/ntpd-opts.texi@1.138, 2008-11-27 06:54:06-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P147 + + ntpd/ntpd.1@1.138, 2008-11-27 06:54:07-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P147 + + ntpdc/ntpdc-opts.c@1.135, 2008-11-27 06:54:07-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P147 + + ntpdc/ntpdc-opts.h@1.135, 2008-11-27 06:54:09-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P147 + + ntpdc/ntpdc-opts.texi@1.134, 2008-11-27 06:54:10-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P147 + + ntpdc/ntpdc.1@1.134, 2008-11-27 06:54:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P147 + + ntpq/ntpq-opts.c@1.135, 2008-11-27 06:54:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P147 + + ntpq/ntpq-opts.h@1.135, 2008-11-27 06:54:12-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P147 + + ntpq/ntpq-opts.texi@1.134, 2008-11-27 06:54:13-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P147 + + ntpq/ntpq.1@1.134, 2008-11-27 06:54:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P147 + + ntpsnmpd/ntpsnmpd-opts.c@1.16, 2008-11-27 06:54:15-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P147 + + ntpsnmpd/ntpsnmpd-opts.h@1.16, 2008-11-27 06:54:16-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P147 + + ntpsnmpd/ntpsnmpd-opts.texi@1.16, 2008-11-27 06:54:16-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P147 + + ntpsnmpd/ntpsnmpd.1@1.16, 2008-11-27 06:54:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P147 + + packageinfo.sh@1.150, 2008-11-27 06:54:17-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P147 + + sntp/sntp-opts.c@1.135, 2008-11-27 06:54:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P147 + + sntp/sntp-opts.h@1.135, 2008-11-27 06:54:19-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P147 + + sntp/sntp-opts.texi@1.134, 2008-11-27 06:54:19-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P147 + + sntp/sntp.1@1.134, 2008-11-27 06:54:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P147 + + util/ntp-keygen-opts.c@1.138, 2008-11-27 06:54:22-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P147 + + util/ntp-keygen-opts.h@1.138, 2008-11-27 06:54:23-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P147 + + util/ntp-keygen-opts.texi@1.137, 2008-11-27 06:54:23-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P147 + + util/ntp-keygen.1@1.137, 2008-11-27 06:54:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P147 + +ChangeSet@1.1791.2.3, 2008-11-27 02:56:55-05:00, stenn@whimsy.udel.edu +3 -0 + Update gsoc_sntp's GCC warning code + + ChangeLog@1.264.1.3, 2008-11-27 02:56:41-05:00, stenn@whimsy.udel.edu +1 -0 + Update gsoc_sntp's GCC warning code + + gsoc_sntp/Makefile.am@1.6, 2008-11-27 02:56:43-05:00, stenn@whimsy.udel.edu +2 -2 + Update gsoc_sntp's GCC warning code + + gsoc_sntp/configure.ac@1.10, 2008-11-27 02:56:43-05:00, stenn@whimsy.udel.edu +21 -0 + Update gsoc_sntp's GCC warning code + +ChangeSet@1.1791.2.2, 2008-11-26 07:09:34-05:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P146 + TAG: NTP_4_2_5P146 + + ChangeLog@1.264.1.2, 2008-11-26 07:09:04-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P146 + + gsoc_sntp/sntp-opts.c@1.7, 2008-11-26 07:09:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P146 + + gsoc_sntp/sntp-opts.h@1.7, 2008-11-26 07:09:07-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P146 + + gsoc_sntp/sntp-opts.texi@1.7, 2008-11-26 07:09:08-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P146 + + gsoc_sntp/sntp.1@1.7, 2008-11-26 07:09:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P146 + + ntpd/ntpd-opts.c@1.138, 2008-11-26 07:09:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P146 + + ntpd/ntpd-opts.h@1.138, 2008-11-26 07:09:10-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P146 + + ntpd/ntpd-opts.texi@1.137, 2008-11-26 07:09:10-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P146 + + ntpd/ntpd.1@1.137, 2008-11-26 07:09:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P146 + + ntpdc/ntpdc-opts.c@1.134, 2008-11-26 07:09:12-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P146 + + ntpdc/ntpdc-opts.h@1.134, 2008-11-26 07:09:13-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P146 + + ntpdc/ntpdc-opts.texi@1.133, 2008-11-26 07:09:14-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P146 + + ntpdc/ntpdc.1@1.133, 2008-11-26 07:09:15-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P146 + + ntpq/ntpq-opts.c@1.134, 2008-11-26 07:09:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P146 + + ntpq/ntpq-opts.h@1.134, 2008-11-26 07:09:17-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P146 + + ntpq/ntpq-opts.texi@1.133, 2008-11-26 07:09:17-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P146 + + ntpq/ntpq.1@1.133, 2008-11-26 07:09:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P146 + + ntpsnmpd/ntpsnmpd-opts.c@1.15, 2008-11-26 07:09:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P146 + + ntpsnmpd/ntpsnmpd-opts.h@1.15, 2008-11-26 07:09:19-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P146 + + ntpsnmpd/ntpsnmpd-opts.texi@1.15, 2008-11-26 07:09:20-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P146 + + ntpsnmpd/ntpsnmpd.1@1.15, 2008-11-26 07:09:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P146 + + packageinfo.sh@1.149, 2008-11-26 07:09:21-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P146 + + sntp/sntp-opts.c@1.134, 2008-11-26 07:09:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P146 + + sntp/sntp-opts.h@1.134, 2008-11-26 07:09:22-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P146 + + sntp/sntp-opts.texi@1.133, 2008-11-26 07:09:23-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P146 + + sntp/sntp.1@1.133, 2008-11-26 07:09:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P146 + + util/ntp-keygen-opts.c@1.137, 2008-11-26 07:09:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P146 + + util/ntp-keygen-opts.h@1.137, 2008-11-26 07:09:26-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P146 + + util/ntp-keygen-opts.texi@1.136, 2008-11-26 07:09:26-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P146 + + util/ntp-keygen.1@1.136, 2008-11-26 07:09:27-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P146 + +ChangeSet@1.1791.2.1, 2008-11-26 06:02:22-05:00, stenn@whimsy.udel.edu +2 -0 + Update Solaris CFLAGS for gsoc_sntp + + ChangeLog@1.264.1.1, 2008-11-26 06:02:03-05:00, stenn@whimsy.udel.edu +1 -0 + Update Solaris CFLAGS for gsoc_sntp + + gsoc_sntp/configure.ac@1.9, 2008-11-26 06:01:56-05:00, stenn@whimsy.udel.edu +11 -0 + Update Solaris CFLAGS for gsoc_sntp + +ChangeSet@1.1791.1.1, 2008-11-25 21:23:21+00:00, kuehn@pogo.udel.edu +3 -0 + prettydate.c, caljulian.c, calyearstart.c: + Added changes from Juergen + + libntp/caljulian.c@1.10, 2008-11-25 21:22:00+00:00, kuehn@pogo.udel.edu +13 -10 + Added changes from Juergen + + libntp/calyearstart.c@1.4, 2008-11-25 21:22:35+00:00, kuehn@pogo.udel.edu +5 -2 + Added changes from Juergen + + libntp/prettydate.c@1.8, 2008-11-25 21:22:27+00:00, kuehn@pogo.udel.edu +5 -6 + Added changes from Juergen + +ChangeSet@1.1793, 2008-11-22 00:54:08+00:00, kuehn@pogo.udel.edu +1 -0 + ChangeLog: + Added entry for bug #1099 + + ChangeLog@1.265, 2008-11-22 00:53:31+00:00, kuehn@pogo.udel.edu +1 -0 + Added entry for bug #1099 + +ChangeSet@1.1792, 2008-11-22 01:22:42+01:00, Amidamaru@melchior.mxiesoft.com +1 -0 + crypto.c: + Fixed auth_init to detect empty lines and malformed entries + + gsoc_sntp/crypto.c@1.4, 2008-11-22 01:22:11+01:00, Amidamaru@melchior.mxiesoft.com +25 -15 + Fixed auth_init to detect empty lines and malformed entries + +ChangeSet@1.1791, 2008-11-20 06:54:56-05:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P145 + TAG: NTP_4_2_5P145 + + ChangeLog@1.264, 2008-11-20 06:54:29-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P145 + + gsoc_sntp/sntp-opts.c@1.6, 2008-11-20 06:54:31-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P145 + + gsoc_sntp/sntp-opts.h@1.6, 2008-11-20 06:54:31-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P145 + + gsoc_sntp/sntp-opts.texi@1.6, 2008-11-20 06:54:32-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P145 + + gsoc_sntp/sntp.1@1.6, 2008-11-20 06:54:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P145 + + ntpd/ntpd-opts.c@1.137, 2008-11-20 06:54:33-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P145 + + ntpd/ntpd-opts.h@1.137, 2008-11-20 06:54:34-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P145 + + ntpd/ntpd-opts.texi@1.136, 2008-11-20 06:54:35-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P145 + + ntpd/ntpd.1@1.136, 2008-11-20 06:54:36-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P145 + + ntpdc/ntpdc-opts.c@1.133, 2008-11-20 06:54:37-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P145 + + ntpdc/ntpdc-opts.h@1.133, 2008-11-20 06:54:38-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P145 + + ntpdc/ntpdc-opts.texi@1.132, 2008-11-20 06:54:39-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P145 + + ntpdc/ntpdc.1@1.132, 2008-11-20 06:54:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P145 + + ntpq/ntpq-opts.c@1.133, 2008-11-20 06:54:41-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P145 + + ntpq/ntpq-opts.h@1.133, 2008-11-20 06:54:41-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P145 + + ntpq/ntpq-opts.texi@1.132, 2008-11-20 06:54:42-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P145 + + ntpq/ntpq.1@1.132, 2008-11-20 06:54:43-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P145 + + ntpsnmpd/ntpsnmpd-opts.c@1.14, 2008-11-20 06:54:44-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P145 + + ntpsnmpd/ntpsnmpd-opts.h@1.14, 2008-11-20 06:54:45-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P145 + + ntpsnmpd/ntpsnmpd-opts.texi@1.14, 2008-11-20 06:54:45-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P145 + + ntpsnmpd/ntpsnmpd.1@1.14, 2008-11-20 06:54:46-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P145 + + packageinfo.sh@1.148, 2008-11-20 06:54:46-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P145 + + sntp/sntp-opts.c@1.133, 2008-11-20 06:54:47-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P145 + + sntp/sntp-opts.h@1.133, 2008-11-20 06:54:48-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P145 + + sntp/sntp-opts.texi@1.132, 2008-11-20 06:54:49-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P145 + + sntp/sntp.1@1.132, 2008-11-20 06:54:49-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P145 + + util/ntp-keygen-opts.c@1.136, 2008-11-20 06:54:50-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P145 + + util/ntp-keygen-opts.h@1.136, 2008-11-20 06:54:51-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P145 + + util/ntp-keygen-opts.texi@1.135, 2008-11-20 06:54:52-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P145 + + util/ntp-keygen.1@1.135, 2008-11-20 06:54:52-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P145 + +ChangeSet@1.1790, 2008-11-20 08:43:08+00:00, stenn@poog.il.thewrittenword.com +2 -0 + Deal with time.h for sntp under linux + + ChangeLog@1.263, 2008-11-20 08:42:58+00:00, stenn@poog.il.thewrittenword.com +1 -0 + Deal with time.h for sntp under linux + + gsoc_sntp/configure.ac@1.8, 2008-11-20 08:42:58+00:00, stenn@poog.il.thewrittenword.com +3 -1 + Deal with time.h for sntp under linux + +ChangeSet@1.1789, 2008-11-20 07:09:48+00:00, stenn@poog.il.thewrittenword.com +3 -0 + Provide rpl_malloc() for sntp for systems that need it + + ChangeLog@1.262, 2008-11-20 07:09:35+00:00, stenn@poog.il.thewrittenword.com +1 -0 + Provide rpl_malloc() for sntp for systems that need it + + gsoc_sntp/main.c@1.11, 2008-11-20 07:09:35+00:00, stenn@poog.il.thewrittenword.com +10 -0 + Provide rpl_malloc() for sntp for systems that need it + + gsoc_sntp/networking.c@1.17, 2008-11-20 07:08:07+00:00, stenn@poog.il.thewrittenword.com +3 -3 + Handle ss_len and socklen type for sntp + +ChangeSet@1.1788, 2008-11-20 07:07:09+00:00, stenn@poog.il.thewrittenword.com +2 -0 + Handle ss_len and socklen type for sntp + + ChangeLog@1.261, 2008-11-20 07:06:57+00:00, stenn@poog.il.thewrittenword.com +1 -0 + Handle ss_len and socklen type for sntp + + gsoc_sntp/configure.ac@1.7, 2008-11-20 07:06:57+00:00, stenn@poog.il.thewrittenword.com +74 -0 + Handle ss_len and socklen type for sntp + +ChangeSet@1.1787, 2008-11-20 05:42:04+00:00, stenn@poog.il.thewrittenword.com +2 -0 + Fixes to the sntp configure.ac script. + + ChangeLog@1.260, 2008-11-20 05:41:54+00:00, stenn@poog.il.thewrittenword.com +1 -0 + Fixes to the sntp configure.ac script. + + gsoc_sntp/configure.ac@1.6, 2008-11-20 05:41:54+00:00, stenn@poog.il.thewrittenword.com +227 -20 + Fixes to the sntp configure.ac script. + +ChangeSet@1.1786, 2008-11-20 05:41:10+00:00, stenn@poog.il.thewrittenword.com +2 -0 + Provide INET6_ADDRSTRLEN if it is missing + + ChangeLog@1.259, 2008-11-20 05:41:00+00:00, stenn@poog.il.thewrittenword.com +1 -0 + Provide INET6_ADDRSTRLEN if it is missing + + include/ntp_rfc2553.h@1.30, 2008-11-20 05:41:00+00:00, stenn@poog.il.thewrittenword.com +15 -11 + Provide INET6_ADDRSTRLEN if it is missing + +ChangeSet@1.1785, 2008-11-19 22:18:03+00:00, stenn@poog.il.thewrittenword.com +2 -0 + [Bug 1095] overflow in caljulian.c + + ChangeLog@1.258, 2008-11-19 22:17:35+00:00, stenn@poog.il.thewrittenword.com +1 -0 + [Bug 1095] overflow in caljulian.c + + libntp/caljulian.c@1.9, 2008-11-19 22:17:35+00:00, stenn@poog.il.thewrittenword.com +2 -1 + [Bug 1095] overflow in caljulian.c + +ChangeSet@1.1784, 2008-11-19 06:58:01-05:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P144 + TAG: NTP_4_2_5P144 + + ChangeLog@1.257, 2008-11-19 06:57:29-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P144 + + gsoc_sntp/sntp-opts.c@1.5, 2008-11-19 06:57:30-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P144 + + gsoc_sntp/sntp-opts.h@1.5, 2008-11-19 06:57:31-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P144 + + gsoc_sntp/sntp-opts.texi@1.5, 2008-11-19 06:57:31-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P144 + + gsoc_sntp/sntp.1@1.5, 2008-11-19 06:57:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P144 + + ntpd/ntpd-opts.c@1.136, 2008-11-19 06:57:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P144 + + ntpd/ntpd-opts.h@1.136, 2008-11-19 06:57:34-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P144 + + ntpd/ntpd-opts.texi@1.135, 2008-11-19 06:57:35-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P144 + + ntpd/ntpd.1@1.135, 2008-11-19 06:57:36-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P144 + + ntpdc/ntpdc-opts.c@1.132, 2008-11-19 06:57:37-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P144 + + ntpdc/ntpdc-opts.h@1.132, 2008-11-19 06:57:37-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P144 + + ntpdc/ntpdc-opts.texi@1.131, 2008-11-19 06:57:38-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P144 + + ntpdc/ntpdc.1@1.131, 2008-11-19 06:57:39-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P144 + + ntpq/ntpq-opts.c@1.132, 2008-11-19 06:57:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P144 + + ntpq/ntpq-opts.h@1.132, 2008-11-19 06:57:41-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P144 + + ntpq/ntpq-opts.texi@1.131, 2008-11-19 06:57:41-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P144 + + ntpq/ntpq.1@1.131, 2008-11-19 06:57:43-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P144 + + ntpsnmpd/ntpsnmpd-opts.c@1.13, 2008-11-19 06:57:44-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P144 + + ntpsnmpd/ntpsnmpd-opts.h@1.13, 2008-11-19 06:57:44-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P144 + + ntpsnmpd/ntpsnmpd-opts.texi@1.13, 2008-11-19 06:57:45-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P144 + + ntpsnmpd/ntpsnmpd.1@1.13, 2008-11-19 06:57:46-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P144 + + packageinfo.sh@1.147, 2008-11-19 06:57:46-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P144 + + sntp/sntp-opts.c@1.132, 2008-11-19 06:57:47-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P144 + + sntp/sntp-opts.h@1.132, 2008-11-19 06:57:49-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P144 + + sntp/sntp-opts.texi@1.131, 2008-11-19 06:57:50-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P144 + + sntp/sntp.1@1.131, 2008-11-19 06:57:51-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P144 + + util/ntp-keygen-opts.c@1.135, 2008-11-19 06:57:52-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P144 + + util/ntp-keygen-opts.h@1.135, 2008-11-19 06:57:52-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P144 + + util/ntp-keygen-opts.texi@1.134, 2008-11-19 06:57:53-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P144 + + util/ntp-keygen.1@1.134, 2008-11-19 06:57:54-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P144 + +ChangeSet@1.1783, 2008-11-18 23:32:18+00:00, stenn@poog.il.thewrittenword.com +2 -0 + Use int32, not int32_t + + ChangeLog@1.256, 2008-11-18 23:32:01+00:00, stenn@poog.il.thewrittenword.com +1 -0 + Use int32, not int32_t + + ntpdc/ntpdc_ops.c@1.56, 2008-11-18 23:32:01+00:00, stenn@poog.il.thewrittenword.com +3 -3 + Use int32, not int32_t + +ChangeSet@1.1782, 2008-11-18 22:33:11+00:00, stenn@poog.il.thewrittenword.com +2 -0 + Avoid the sched*() functions under OSF - link problems + + ChangeLog@1.255, 2008-11-18 22:32:57+00:00, stenn@poog.il.thewrittenword.com +1 -0 + Avoid the sched*() functions under OSF - link problems + + configure.ac@1.421, 2008-11-18 22:32:57+00:00, stenn@poog.il.thewrittenword.com +5 -0 + Avoid the sched*() functions under OSF - link problems + +ChangeSet@1.1781, 2008-11-17 06:53:07-05:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P143 + TAG: NTP_4_2_5P143 + + ChangeLog@1.254, 2008-11-17 06:52:41-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P143 + + gsoc_sntp/sntp-opts.c@1.4, 2008-11-17 06:52:43-05:00, stenn@whimsy.udel.edu +37 -7 + NTP_4_2_5P143 + + gsoc_sntp/sntp-opts.h@1.4, 2008-11-17 06:52:44-05:00, stenn@whimsy.udel.edu +77 -6 + NTP_4_2_5P143 + + gsoc_sntp/sntp-opts.texi@1.4, 2008-11-17 06:52:44-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P143 + + gsoc_sntp/sntp.1@1.4, 2008-11-17 06:52:45-05:00, stenn@whimsy.udel.edu +7 -2 + NTP_4_2_5P143 + + ntpd/ntpd-opts.c@1.135, 2008-11-17 06:52:46-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P143 + + ntpd/ntpd-opts.h@1.135, 2008-11-17 06:52:46-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P143 + + ntpd/ntpd-opts.texi@1.134, 2008-11-17 06:52:48-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P143 + + ntpd/ntpd.1@1.134, 2008-11-17 06:52:49-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P143 + + ntpdc/ntpdc-opts.c@1.131, 2008-11-17 06:52:49-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P143 + + ntpdc/ntpdc-opts.h@1.131, 2008-11-17 06:52:50-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P143 + + ntpdc/ntpdc-opts.texi@1.130, 2008-11-17 06:52:51-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P143 + + ntpdc/ntpdc.1@1.130, 2008-11-17 06:52:52-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P143 + + ntpq/ntpq-opts.c@1.131, 2008-11-17 06:52:52-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P143 + + ntpq/ntpq-opts.h@1.131, 2008-11-17 06:52:53-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P143 + + ntpq/ntpq-opts.texi@1.130, 2008-11-17 06:52:54-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P143 + + ntpq/ntpq.1@1.130, 2008-11-17 06:52:55-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P143 + + ntpsnmpd/ntpsnmpd-opts.c@1.12, 2008-11-17 06:52:55-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P143 + + ntpsnmpd/ntpsnmpd-opts.h@1.12, 2008-11-17 06:52:56-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P143 + + ntpsnmpd/ntpsnmpd-opts.texi@1.12, 2008-11-17 06:52:57-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P143 + + ntpsnmpd/ntpsnmpd.1@1.12, 2008-11-17 06:52:57-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P143 + + packageinfo.sh@1.146, 2008-11-17 06:52:57-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P143 + + sntp/sntp-opts.c@1.131, 2008-11-17 06:52:58-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P143 + + sntp/sntp-opts.h@1.131, 2008-11-17 06:52:59-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P143 + + sntp/sntp-opts.texi@1.130, 2008-11-17 06:53:00-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P143 + + sntp/sntp.1@1.130, 2008-11-17 06:53:00-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P143 + + util/ntp-keygen-opts.c@1.134, 2008-11-17 06:53:01-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P143 + + util/ntp-keygen-opts.h@1.134, 2008-11-17 06:53:02-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P143 + + util/ntp-keygen-opts.texi@1.133, 2008-11-17 06:53:02-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P143 + + util/ntp-keygen.1@1.133, 2008-11-17 06:53:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P143 + +ChangeSet@1.1780, 2008-11-17 03:29:26-05:00, stenn@whimsy.udel.edu +4 -0 + update generated files + + gsoc_sntp/sntp-opts.c@1.3, 2008-11-17 03:29:12-05:00, stenn@whimsy.udel.edu +7 -37 + update generated files + + gsoc_sntp/sntp-opts.h@1.3, 2008-11-17 03:29:13-05:00, stenn@whimsy.udel.edu +7 -78 + update generated files + + gsoc_sntp/sntp-opts.texi@1.3, 2008-11-17 03:29:13-05:00, stenn@whimsy.udel.edu +3 -3 + update generated files + + gsoc_sntp/sntp.1@1.3, 2008-11-17 03:29:14-05:00, stenn@whimsy.udel.edu +3 -8 + update generated files + +ChangeSet@1.1779, 2008-11-17 03:18:55-05:00, stenn@pogo.udel.edu +1 -0 + sntp cleanup and fixes + + ChangeLog@1.253, 2008-11-17 03:18:47-05:00, stenn@pogo.udel.edu +1 -0 + sntp cleanup and fixes + +ChangeSet@1.1775.1.2, 2008-11-17 01:25:35+01:00, Amidamaru@melchior.mxiesoft.com +1 -0 + sntp-opts.def: + Set the normalverbose option to -d + + gsoc_sntp/sntp-opts.def@1.9, 2008-11-17 01:25:08+01:00, Amidamaru@melchior.mxiesoft.com +1 -1 + Set the normalverbose option to -d + +ChangeSet@1.1775.1.1, 2008-11-17 01:16:44+01:00, Amidamaru@melchior.mxiesoft.com +5 -0 + utilities.h, utilities.c: + Added the tv_to_str function which converts a struct timeval to a timestamp string. + kod_management.c: + Replaced strlcpy with strncpy for compatibility reasons. + main.c: + Fixed the time difference report part and the set_time call part of bug #1088 + + gsoc_sntp/kod_management.c@1.7, 2008-11-17 01:14:45+01:00, Amidamaru@melchior.mxiesoft.com +1 -1 + Replaced strlcpy with strncpy for compatibility reasons. + + gsoc_sntp/main.c@1.10, 2008-11-17 01:12:59+01:00, Amidamaru@melchior.mxiesoft.com +23 -15 + Fixed the time difference report part and the set_time call part of bug #1088 + + gsoc_sntp/networking.c@1.16, 2008-11-17 01:15:15+01:00, Amidamaru@melchior.mxiesoft.com +2 -2 + + gsoc_sntp/utilities.c@1.5, 2008-11-17 01:13:40+01:00, Amidamaru@melchior.mxiesoft.com +36 -0 + Added the tv_to_str function which converts a struct timeval to a timestamp string. + + gsoc_sntp/utilities.h@1.4, 2008-11-17 01:14:31+01:00, Amidamaru@melchior.mxiesoft.com +1 -0 + Added the tv_to_str function which converts a struct timeval to a timestamp string. + +ChangeSet@1.1777, 2008-11-16 07:03:17-05:00, stenn@whimsy.udel.edu +30 -0 + NTP_4_2_5P142 + TAG: NTP_4_2_5P142 + + ChangeLog@1.252, 2008-11-16 07:02:51-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P142 + + gsoc_sntp/sntp-opts.c@1.2, 2008-11-16 07:02:53-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P142 + + gsoc_sntp/sntp-opts.h@1.2, 2008-11-16 07:02:53-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P142 + + gsoc_sntp/sntp-opts.texi@1.2, 2008-11-16 07:02:54-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P142 + + gsoc_sntp/sntp.1@1.2, 2008-11-16 07:02:54-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P142 + + ntpd/ntpd-opts.c@1.134, 2008-11-16 07:02:55-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P142 + + ntpd/ntpd-opts.h@1.134, 2008-11-16 07:02:56-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P142 + + ntpd/ntpd-opts.texi@1.133, 2008-11-16 07:02:56-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P142 + + ntpd/ntpd.1@1.133, 2008-11-16 07:02:58-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P142 + + ntpdc/ntpdc-opts.c@1.130, 2008-11-16 07:02:59-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P142 + + ntpdc/ntpdc-opts.h@1.130, 2008-11-16 07:02:59-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P142 + + ntpdc/ntpdc-opts.texi@1.129, 2008-11-16 07:03:00-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P142 + + ntpdc/ntpdc.1@1.129, 2008-11-16 07:03:01-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P142 + + ntpq/ntpq-opts.c@1.130, 2008-11-16 07:03:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P142 + + ntpq/ntpq-opts.h@1.130, 2008-11-16 07:03:03-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P142 + + ntpq/ntpq-opts.texi@1.129, 2008-11-16 07:03:03-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P142 + + ntpq/ntpq.1@1.129, 2008-11-16 07:03:04-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P142 + + ntpsnmpd/ntpsnmpd-opts.c@1.11, 2008-11-16 07:03:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P142 + + ntpsnmpd/ntpsnmpd-opts.h@1.11, 2008-11-16 07:03:06-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P142 + + ntpsnmpd/ntpsnmpd-opts.texi@1.11, 2008-11-16 07:03:07-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P142 + + ntpsnmpd/ntpsnmpd.1@1.11, 2008-11-16 07:03:07-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P142 + + packageinfo.sh@1.145, 2008-11-16 07:03:08-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P142 + + sntp/sntp-opts.c@1.130, 2008-11-16 07:03:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P142 + + sntp/sntp-opts.h@1.130, 2008-11-16 07:03:09-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P142 + + sntp/sntp-opts.texi@1.129, 2008-11-16 07:03:10-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P142 + + sntp/sntp.1@1.129, 2008-11-16 07:03:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P142 + + util/ntp-keygen-opts.c@1.133, 2008-11-16 07:03:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P142 + + util/ntp-keygen-opts.h@1.133, 2008-11-16 07:03:12-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P142 + + util/ntp-keygen-opts.texi@1.132, 2008-11-16 07:03:13-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P142 + + util/ntp-keygen.1@1.132, 2008-11-16 07:03:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P142 + +ChangeSet@1.1776, 2008-11-16 02:16:42-05:00, stenn@whimsy.udel.edu +5 -0 + Imported GSoC SNTP code from Johannes Maximilian Khn + + .point-changed-filelist@1.5, 2008-11-16 02:12:36-05:00, stenn@whimsy.udel.edu +4 -0 + Add gsoc-sntp files to .point-changed-filelist + + BitKeeper/deleted/.del-bincheck.mf@1.2, 2008-11-15 18:48:37-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: gsoc_sntp/bincheck.mf + + gsoc_sntp/bincheck.mf@1.1, 2008-11-15 17:41:19-05:00, stenn@whimsy.udel.edu +15 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/bincheck.mf + + gsoc_sntp/bincheck.mf@1.0, 2008-11-15 17:41:19-05:00, stenn@whimsy.udel.edu +0 -0 + + BitKeeper/etc/ignore@1.68, 2008-11-16 02:13:16-05:00, stenn@whimsy.udel.edu +14 -14 + Added gsoc_sntp files to the ignore list + + ChangeLog@1.251, 2008-11-16 02:16:15-05:00, stenn@whimsy.udel.edu +1 -0 + Imported GSoC SNTP code from Johannes Maximilian Khn + + bootstrap@1.22, 2008-11-16 02:14:57-05:00, stenn@whimsy.udel.edu +1 -0 + Add gsoc_sntp files t bootstrap + +ChangeSet@1.1774, 2008-11-15 16:06:12-05:00, stenn@pogo.udel.edu +10 -0 + Hack gsoc_sntp for inclusion in the main tree + + BitKeeper/etc/ignore@1.67, 2008-11-14 21:14:59-05:00, stenn@pogo.udel.edu +1 -0 + added bincheck.mf + + BitKeeper/etc/ignore@1.66, 2008-11-14 21:14:09-05:00, stenn@pogo.udel.edu +1 -0 + added autogen-version.def + + BitKeeper/etc/ignore@1.65, 2008-11-14 21:13:31-05:00, stenn@pogo.udel.edu +1 -0 + added version.def + + gsoc_sntp/COPYRIGHT@1.1, 2008-11-14 23:34:33-05:00, stenn@pogo.udel.edu +0 -0 + BitKeeper file /pogo/users/stenn/ntp-dev-kuehn/gsoc_sntp/COPYRIGHT + + gsoc_sntp/COPYRIGHT@1.0, 2008-11-14 23:34:33-05:00, stenn@pogo.udel.edu +0 -0 + + gsoc_sntp/Makefile.am@1.5, 2008-11-15 16:04:42-05:00, stenn@pogo.udel.edu +44 -16 + Hack gsoc_sntp for inclusion in the main tree + + gsoc_sntp/configure.ac@1.5, 2008-11-15 16:05:23-05:00, stenn@pogo.udel.edu +19 -2 + Hack gsoc_sntp for inclusion in the main tree + + gsoc_sntp/ltmain.sh@1.1, 2008-11-14 21:17:00-05:00, stenn@pogo.udel.edu +6863 -0 + BitKeeper file /pogo/users/stenn/ntp-dev-kuehn/gsoc_sntp/ltmain.sh + + gsoc_sntp/ltmain.sh@1.0, 2008-11-14 21:17:00-05:00, stenn@pogo.udel.edu +0 -0 + + gsoc_sntp/sntp-opts.c@1.1, 2008-11-14 21:17:00-05:00, stenn@pogo.udel.edu +638 -0 + BitKeeper file /pogo/users/stenn/ntp-dev-kuehn/gsoc_sntp/sntp-opts.c + + gsoc_sntp/sntp-opts.c@1.0, 2008-11-14 21:17:00-05:00, stenn@pogo.udel.edu +0 -0 + + gsoc_sntp/sntp-opts.h@1.1, 2008-11-14 21:17:00-05:00, stenn@pogo.udel.edu +234 -0 + BitKeeper file /pogo/users/stenn/ntp-dev-kuehn/gsoc_sntp/sntp-opts.h + + gsoc_sntp/sntp-opts.h@1.0, 2008-11-14 21:17:00-05:00, stenn@pogo.udel.edu +0 -0 + + gsoc_sntp/sntp-opts.menu@1.1, 2008-11-14 21:17:00-05:00, stenn@pogo.udel.edu +1 -0 + BitKeeper file /pogo/users/stenn/ntp-dev-kuehn/gsoc_sntp/sntp-opts.menu + + gsoc_sntp/sntp-opts.menu@1.0, 2008-11-14 21:17:00-05:00, stenn@pogo.udel.edu +0 -0 + + gsoc_sntp/sntp-opts.texi@1.1, 2008-11-14 21:17:00-05:00, stenn@pogo.udel.edu +208 -0 + BitKeeper file /pogo/users/stenn/ntp-dev-kuehn/gsoc_sntp/sntp-opts.texi + + gsoc_sntp/sntp-opts.texi@1.0, 2008-11-14 21:17:00-05:00, stenn@pogo.udel.edu +0 -0 + + gsoc_sntp/sntp.1@1.1, 2008-11-14 21:17:18-05:00, stenn@pogo.udel.edu +298 -0 + BitKeeper file /pogo/users/stenn/ntp-dev-kuehn/gsoc_sntp/sntp.1 + + gsoc_sntp/sntp.1@1.0, 2008-11-14 21:17:18-05:00, stenn@pogo.udel.edu +0 -0 + +ChangeSet@1.1771.1.1, 2008-11-14 17:32:58-05:00, stenn@pogo.udel.edu +1 -0 + updates + + gsoc_sntp/:fetch-stubs@1.4, 2008-11-14 17:32:47-05:00, stenn@pogo.udel.edu +0 -12 + updates + +ChangeSet@1.1735.1.72, 2008-11-13 06:42:06-05:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P141 + TAG: NTP_4_2_5P141 + + ChangeLog@1.250, 2008-11-13 06:41:43-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P141 + + ntpd/ntpd-opts.c@1.133, 2008-11-13 06:41:45-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P141 + + ntpd/ntpd-opts.h@1.133, 2008-11-13 06:41:45-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P141 + + ntpd/ntpd-opts.texi@1.132, 2008-11-13 06:41:46-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P141 + + ntpd/ntpd.1@1.132, 2008-11-13 06:41:47-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P141 + + ntpdc/ntpdc-opts.c@1.129, 2008-11-13 06:41:47-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P141 + + ntpdc/ntpdc-opts.h@1.129, 2008-11-13 06:41:48-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P141 + + ntpdc/ntpdc-opts.texi@1.128, 2008-11-13 06:41:49-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P141 + + ntpdc/ntpdc.1@1.128, 2008-11-13 06:41:50-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P141 + + ntpq/ntpq-opts.c@1.129, 2008-11-13 06:41:50-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P141 + + ntpq/ntpq-opts.h@1.129, 2008-11-13 06:41:51-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P141 + + ntpq/ntpq-opts.texi@1.128, 2008-11-13 06:41:52-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P141 + + ntpq/ntpq.1@1.128, 2008-11-13 06:41:52-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P141 + + ntpsnmpd/ntpsnmpd-opts.c@1.10, 2008-11-13 06:41:53-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P141 + + ntpsnmpd/ntpsnmpd-opts.h@1.10, 2008-11-13 06:41:54-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P141 + + ntpsnmpd/ntpsnmpd-opts.texi@1.10, 2008-11-13 06:41:55-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P141 + + ntpsnmpd/ntpsnmpd.1@1.10, 2008-11-13 06:41:55-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P141 + + packageinfo.sh@1.144, 2008-11-13 06:41:56-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P141 + + sntp/sntp-opts.c@1.129, 2008-11-13 06:41:57-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P141 + + sntp/sntp-opts.h@1.129, 2008-11-13 06:41:57-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P141 + + sntp/sntp-opts.texi@1.128, 2008-11-13 06:41:59-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P141 + + sntp/sntp.1@1.128, 2008-11-13 06:41:59-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P141 + + util/ntp-keygen-opts.c@1.132, 2008-11-13 06:42:00-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P141 + + util/ntp-keygen-opts.h@1.132, 2008-11-13 06:42:01-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P141 + + util/ntp-keygen-opts.texi@1.131, 2008-11-13 06:42:02-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P141 + + util/ntp-keygen.1@1.131, 2008-11-13 06:42:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P141 + +ChangeSet@1.1735.1.71, 2008-11-12 16:09:45-05:00, stenn@whimsy.udel.edu +3 -0 + New caltontp.c and calyearstart.c from Juergen Perlinger + + ChangeLog@1.249, 2008-11-12 16:09:28-05:00, stenn@whimsy.udel.edu +1 -0 + New caltontp.c and calyearstart.c from Juergen Perlinger + + libntp/caltontp.c@1.3, 2008-11-12 16:09:29-05:00, stenn@whimsy.udel.edu +88 -25 + New caltontp.c and calyearstart.c from Juergen Perlinger + + libntp/calyearstart.c@1.3, 2008-11-12 16:09:29-05:00, stenn@whimsy.udel.edu +38 -7 + New caltontp.c and calyearstart.c from Juergen Perlinger + +ChangeSet@1.1735.1.70, 2008-11-12 06:43:31-05:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P140 + TAG: NTP_4_2_5P140 + + ChangeLog@1.248, 2008-11-12 06:43:07-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P140 + + ntpd/ntpd-opts.c@1.132, 2008-11-12 06:43:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P140 + + ntpd/ntpd-opts.h@1.132, 2008-11-12 06:43:09-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P140 + + ntpd/ntpd-opts.texi@1.131, 2008-11-12 06:43:09-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P140 + + ntpd/ntpd.1@1.131, 2008-11-12 06:43:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P140 + + ntpdc/ntpdc-opts.c@1.128, 2008-11-12 06:43:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P140 + + ntpdc/ntpdc-opts.h@1.128, 2008-11-12 06:43:12-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P140 + + ntpdc/ntpdc-opts.texi@1.127, 2008-11-12 06:43:13-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P140 + + ntpdc/ntpdc.1@1.127, 2008-11-12 06:43:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P140 + + ntpq/ntpq-opts.c@1.128, 2008-11-12 06:43:15-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P140 + + ntpq/ntpq-opts.h@1.128, 2008-11-12 06:43:16-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P140 + + ntpq/ntpq-opts.texi@1.127, 2008-11-12 06:43:17-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P140 + + ntpq/ntpq.1@1.127, 2008-11-12 06:43:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P140 + + ntpsnmpd/ntpsnmpd-opts.c@1.9, 2008-11-12 06:43:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P140 + + ntpsnmpd/ntpsnmpd-opts.h@1.9, 2008-11-12 06:43:19-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P140 + + ntpsnmpd/ntpsnmpd-opts.texi@1.9, 2008-11-12 06:43:20-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P140 + + ntpsnmpd/ntpsnmpd.1@1.9, 2008-11-12 06:43:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P140 + + packageinfo.sh@1.143, 2008-11-12 06:43:20-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P140 + + sntp/sntp-opts.c@1.128, 2008-11-12 06:43:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P140 + + sntp/sntp-opts.h@1.128, 2008-11-12 06:43:22-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P140 + + sntp/sntp-opts.texi@1.127, 2008-11-12 06:43:22-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P140 + + sntp/sntp.1@1.127, 2008-11-12 06:43:23-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P140 + + util/ntp-keygen-opts.c@1.131, 2008-11-12 06:43:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P140 + + util/ntp-keygen-opts.h@1.131, 2008-11-12 06:43:24-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P140 + + util/ntp-keygen-opts.texi@1.130, 2008-11-12 06:43:25-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P140 + + util/ntp-keygen.1@1.130, 2008-11-12 06:43:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P140 + +ChangeSet@1.1735.1.69, 2008-11-12 02:36:31-05:00, stenn@whimsy.udel.edu +3 -0 + ntp_scanner lint removal + + ChangeLog@1.247, 2008-11-12 02:36:17-05:00, stenn@whimsy.udel.edu +1 -0 + ntp_scanner lint removal + + ntpd/ntp_scanner.c@1.15, 2008-11-12 02:36:19-05:00, stenn@whimsy.udel.edu +2 -1 + ntp_scanner lint removal + + ntpd/ntp_scanner.h@1.4, 2008-11-12 02:36:19-05:00, stenn@whimsy.udel.edu +1 -1 + ntp_scanner lint removal + +ChangeSet@1.1735.1.68, 2008-11-12 02:18:18-05:00, stenn@pogo.udel.edu +1 -0 + Reindent ntp_scanner.c + + ntpd/ntp_scanner.c@1.14, 2008-11-12 02:18:09-05:00, stenn@pogo.udel.edu +109 -65 + Reindent ntp_scanner.c + +ChangeSet@1.1735.1.67, 2008-11-11 16:49:27-05:00, stenn@whimsy.udel.edu +3 -0 + [Bug 1011] gmtime() returns NULL on windows where it would not under Unix + + ChangeLog@1.246, 2008-11-11 16:49:09-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1011] gmtime() returns NULL on windows where it would not under Unix + + libntp/caljulian.c@1.8, 2008-11-11 16:49:11-05:00, stenn@whimsy.udel.edu +121 -86 + [Bug 1011] gmtime() returns NULL on windows where it would not under Unix + + libntp/prettydate.c@1.7, 2008-11-11 16:49:11-05:00, stenn@whimsy.udel.edu +107 -39 + [Bug 1011] gmtime() returns NULL on windows where it would not under Unix + +ChangeSet@1.1735.1.66, 2008-11-11 06:42:25-05:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P139 + TAG: NTP_4_2_5P139 + + ChangeLog@1.245, 2008-11-11 06:42:01-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P139 + + ntpd/ntpd-opts.c@1.131, 2008-11-11 06:42:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P139 + + ntpd/ntpd-opts.h@1.131, 2008-11-11 06:42:04-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P139 + + ntpd/ntpd-opts.texi@1.130, 2008-11-11 06:42:04-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P139 + + ntpd/ntpd.1@1.130, 2008-11-11 06:42:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P139 + + ntpdc/ntpdc-opts.c@1.127, 2008-11-11 06:42:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P139 + + ntpdc/ntpdc-opts.h@1.127, 2008-11-11 06:42:07-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P139 + + ntpdc/ntpdc-opts.texi@1.126, 2008-11-11 06:42:07-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P139 + + ntpdc/ntpdc.1@1.126, 2008-11-11 06:42:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P139 + + ntpq/ntpq-opts.c@1.127, 2008-11-11 06:42:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P139 + + ntpq/ntpq-opts.h@1.127, 2008-11-11 06:42:10-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P139 + + ntpq/ntpq-opts.texi@1.126, 2008-11-11 06:42:11-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P139 + + ntpq/ntpq.1@1.126, 2008-11-11 06:42:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P139 + + ntpsnmpd/ntpsnmpd-opts.c@1.8, 2008-11-11 06:42:12-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P139 + + ntpsnmpd/ntpsnmpd-opts.h@1.8, 2008-11-11 06:42:13-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P139 + + ntpsnmpd/ntpsnmpd-opts.texi@1.8, 2008-11-11 06:42:13-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P139 + + ntpsnmpd/ntpsnmpd.1@1.8, 2008-11-11 06:42:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P139 + + packageinfo.sh@1.142, 2008-11-11 06:42:14-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P139 + + sntp/sntp-opts.c@1.127, 2008-11-11 06:42:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P139 + + sntp/sntp-opts.h@1.127, 2008-11-11 06:42:15-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P139 + + sntp/sntp-opts.texi@1.126, 2008-11-11 06:42:16-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P139 + + sntp/sntp.1@1.126, 2008-11-11 06:42:17-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P139 + + util/ntp-keygen-opts.c@1.130, 2008-11-11 06:42:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P139 + + util/ntp-keygen-opts.h@1.130, 2008-11-11 06:42:19-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P139 + + util/ntp-keygen-opts.texi@1.129, 2008-11-11 06:42:20-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P139 + + util/ntp-keygen.1@1.129, 2008-11-11 06:42:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P139 + +ChangeSet@1.1735.1.65, 2008-11-11 01:39:34-05:00, stenn@whimsy.udel.edu +2 -0 + Typo fix to driver20.html + + ChangeLog@1.244, 2008-11-11 01:39:16-05:00, stenn@whimsy.udel.edu +1 -0 + Typo fix to driver20.html + + html/drivers/driver20.html@1.17, 2008-11-11 01:39:18-05:00, stenn@whimsy.udel.edu +1 -1 + Typo fix to driver20.html + +ChangeSet@1.1735.1.64, 2008-11-10 06:44:15-05:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P138 + TAG: NTP_4_2_5P138 + + ChangeLog@1.243, 2008-11-10 06:43:52-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P138 + + ntpd/ntpd-opts.c@1.130, 2008-11-10 06:43:53-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P138 + + ntpd/ntpd-opts.h@1.130, 2008-11-10 06:43:54-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P138 + + ntpd/ntpd-opts.texi@1.129, 2008-11-10 06:43:55-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P138 + + ntpd/ntpd.1@1.129, 2008-11-10 06:43:55-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P138 + + ntpdc/ntpdc-opts.c@1.126, 2008-11-10 06:43:56-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P138 + + ntpdc/ntpdc-opts.h@1.126, 2008-11-10 06:43:57-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P138 + + ntpdc/ntpdc-opts.texi@1.125, 2008-11-10 06:43:58-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P138 + + ntpdc/ntpdc.1@1.125, 2008-11-10 06:43:59-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P138 + + ntpq/ntpq-opts.c@1.126, 2008-11-10 06:44:00-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P138 + + ntpq/ntpq-opts.h@1.126, 2008-11-10 06:44:01-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P138 + + ntpq/ntpq-opts.texi@1.125, 2008-11-10 06:44:01-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P138 + + ntpq/ntpq.1@1.125, 2008-11-10 06:44:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P138 + + ntpsnmpd/ntpsnmpd-opts.c@1.7, 2008-11-10 06:44:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P138 + + ntpsnmpd/ntpsnmpd-opts.h@1.7, 2008-11-10 06:44:03-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P138 + + ntpsnmpd/ntpsnmpd-opts.texi@1.7, 2008-11-10 06:44:04-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P138 + + ntpsnmpd/ntpsnmpd.1@1.7, 2008-11-10 06:44:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P138 + + packageinfo.sh@1.141, 2008-11-10 06:44:05-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P138 + + sntp/sntp-opts.c@1.126, 2008-11-10 06:44:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P138 + + sntp/sntp-opts.h@1.126, 2008-11-10 06:44:06-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P138 + + sntp/sntp-opts.texi@1.125, 2008-11-10 06:44:07-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P138 + + sntp/sntp.1@1.125, 2008-11-10 06:44:07-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P138 + + util/ntp-keygen-opts.c@1.129, 2008-11-10 06:44:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P138 + + util/ntp-keygen-opts.h@1.129, 2008-11-10 06:44:09-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P138 + + util/ntp-keygen-opts.texi@1.128, 2008-11-10 06:44:10-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P138 + + util/ntp-keygen.1@1.128, 2008-11-10 06:44:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P138 + +ChangeSet@1.1735.1.63, 2008-11-10 02:00:40-05:00, stenn@whimsy.udel.edu +2 -0 + IPv6 interfaces were being looked for twice; fix bug 474 + + ChangeLog@1.242, 2008-11-10 01:58:33-05:00, stenn@whimsy.udel.edu +2 -0 + IPv6 interfaces were being looked for twice; fix bug 474 + + ntpd/ntp_io.c@1.274, 2008-11-10 01:58:34-05:00, stenn@whimsy.udel.edu +1 -8 + IPv6 interfaces were being looked for twice; fix bug 474 + +ChangeSet@1.1735.1.62, 2008-11-09 23:19:25-05:00, stenn@pogo.udel.edu +1 -0 + Used ntp-4.2.5p138 instead of the date + + html/drivers/driver28.html@1.12, 2008-11-09 23:19:08-05:00, stenn@pogo.udel.edu +1 -1 + Used ntp-4.2.5p138 instead of the date + +ChangeSet@1.1735.8.7, 2008-11-09 22:38:13-05:00, stenn@whimsy.udel.edu +3 -0 + decode.html and driver20.html updates from Dave Mills + + ChangeLog@1.238.1.5, 2008-11-09 22:37:47-05:00, stenn@whimsy.udel.edu +1 -0 + decode.html and driver20.html updates from Dave Mills + + html/decode.html@1.4, 2008-11-09 22:37:48-05:00, stenn@whimsy.udel.edu +12 -6 + decode.html and driver20.html updates from Dave Mills + + html/drivers/driver20.html@1.16, 2008-11-09 22:37:48-05:00, stenn@whimsy.udel.edu +1 -1 + decode.html and driver20.html updates from Dave Mills + +ChangeSet@1.1735.8.6, 2008-11-01 06:46:41-05:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P137 + TAG: NTP_4_2_5P137 + + ChangeLog@1.238.1.4, 2008-11-01 06:46:13-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P137 + + ntpd/ntpd-opts.c@1.129, 2008-11-01 06:46:15-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P137 + + ntpd/ntpd-opts.h@1.129, 2008-11-01 06:46:16-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P137 + + ntpd/ntpd-opts.texi@1.128, 2008-11-01 06:46:17-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P137 + + ntpd/ntpd.1@1.128, 2008-11-01 06:46:17-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P137 + + ntpdc/ntpdc-opts.c@1.125, 2008-11-01 06:46:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P137 + + ntpdc/ntpdc-opts.h@1.125, 2008-11-01 06:46:18-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P137 + + ntpdc/ntpdc-opts.texi@1.124, 2008-11-01 06:46:20-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P137 + + ntpdc/ntpdc.1@1.124, 2008-11-01 06:46:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P137 + + ntpq/ntpq-opts.c@1.125, 2008-11-01 06:46:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P137 + + ntpq/ntpq-opts.h@1.125, 2008-11-01 06:46:22-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P137 + + ntpq/ntpq-opts.texi@1.124, 2008-11-01 06:46:22-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P137 + + ntpq/ntpq.1@1.124, 2008-11-01 06:46:23-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P137 + + ntpsnmpd/ntpsnmpd-opts.c@1.6, 2008-11-01 06:46:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P137 + + ntpsnmpd/ntpsnmpd-opts.h@1.6, 2008-11-01 06:46:25-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P137 + + ntpsnmpd/ntpsnmpd-opts.texi@1.6, 2008-11-01 06:46:25-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P137 + + ntpsnmpd/ntpsnmpd.1@1.6, 2008-11-01 06:46:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P137 + + packageinfo.sh@1.140, 2008-11-01 06:46:27-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P137 + + sntp/sntp-opts.c@1.125, 2008-11-01 06:46:27-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P137 + + sntp/sntp-opts.h@1.125, 2008-11-01 06:46:28-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P137 + + sntp/sntp-opts.texi@1.124, 2008-11-01 06:46:29-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P137 + + sntp/sntp.1@1.124, 2008-11-01 06:46:29-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P137 + + util/ntp-keygen-opts.c@1.128, 2008-11-01 06:46:30-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P137 + + util/ntp-keygen-opts.h@1.128, 2008-11-01 06:46:31-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P137 + + util/ntp-keygen-opts.texi@1.127, 2008-11-01 06:46:32-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P137 + + util/ntp-keygen.1@1.127, 2008-11-01 06:46:33-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P137 + +ChangeSet@1.1735.8.5, 2008-11-01 00:22:33-05:00, stenn@whimsy.udel.edu +1 -0 + netsnmp_daemonize lib check cleanup + + configure.ac@1.417.1.5, 2008-11-01 00:22:22-05:00, stenn@whimsy.udel.edu +1 -1 + netsnmp_daemonize lib check cleanup + +ChangeSet@1.1735.8.4, 2008-10-31 23:31:45-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1069] #undef netsnmp's PACKAGE_* macros + + ChangeLog@1.238.1.3, 2008-10-31 23:31:31-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1069] #undef netsnmp's PACKAGE_* macros + + ntpsnmpd/ntpsnmpd.c@1.3, 2008-10-31 23:31:33-05:00, stenn@whimsy.udel.edu +6 -0 + [Bug 1069] #undef netsnmp's PACKAGE_* macros + +ChangeSet@1.1735.8.3, 2008-10-31 23:27:50-05:00, stenn@whimsy.udel.edu +3 -0 + [Bug 1068] Older versions of netsnmp do not have netsnmp_daemonize() + + configure.ac@1.417.1.4, 2008-10-31 23:23:16-05:00, stenn@whimsy.udel.edu +12 -0 + [Bug 1068] Older versions of netsnmp do not have netsnmp_daemonize() + + ntpsnmpd/Makefile.am@1.6, 2008-10-31 23:23:03-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 1068] Older versions of netsnmp do not have netsnmp_daemonize() + + ntpsnmpd/netsnmp_daemonize.c@1.1, 2008-10-31 23:22:34-05:00, stenn@whimsy.udel.edu +266 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpsnmpd/netsnmp_daemonize.c + + ntpsnmpd/netsnmp_daemonize.c@1.0, 2008-10-31 23:22:34-05:00, stenn@whimsy.udel.edu +0 -0 + +ChangeSet@1.1735.8.2, 2008-10-27 06:43:43-05:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P136 + TAG: NTP_4_2_5P136 + + ChangeLog@1.238.1.2, 2008-10-27 06:43:18-05:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P136 + + ntpd/ntpd-opts.c@1.128, 2008-10-27 06:43:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P136 + + ntpd/ntpd-opts.h@1.128, 2008-10-27 06:43:19-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P136 + + ntpd/ntpd-opts.texi@1.127, 2008-10-27 06:43:20-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P136 + + ntpd/ntpd.1@1.127, 2008-10-27 06:43:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P136 + + ntpdc/ntpdc-opts.c@1.124, 2008-10-27 06:43:22-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P136 + + ntpdc/ntpdc-opts.h@1.124, 2008-10-27 06:43:23-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P136 + + ntpdc/ntpdc-opts.texi@1.123, 2008-10-27 06:43:24-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P136 + + ntpdc/ntpdc.1@1.123, 2008-10-27 06:43:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P136 + + ntpq/ntpq-opts.c@1.124, 2008-10-27 06:43:25-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P136 + + ntpq/ntpq-opts.h@1.124, 2008-10-27 06:43:26-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P136 + + ntpq/ntpq-opts.texi@1.123, 2008-10-27 06:43:27-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P136 + + ntpq/ntpq.1@1.123, 2008-10-27 06:43:28-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P136 + + ntpsnmpd/ntpsnmpd-opts.c@1.5, 2008-10-27 06:43:28-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P136 + + ntpsnmpd/ntpsnmpd-opts.h@1.5, 2008-10-27 06:43:29-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P136 + + ntpsnmpd/ntpsnmpd-opts.texi@1.5, 2008-10-27 06:43:30-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P136 + + ntpsnmpd/ntpsnmpd.1@1.5, 2008-10-27 06:43:30-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P136 + + packageinfo.sh@1.139, 2008-10-27 06:43:30-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P136 + + sntp/sntp-opts.c@1.124, 2008-10-27 06:43:31-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P136 + + sntp/sntp-opts.h@1.124, 2008-10-27 06:43:32-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P136 + + sntp/sntp-opts.texi@1.123, 2008-10-27 06:43:33-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P136 + + sntp/sntp.1@1.123, 2008-10-27 06:43:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P136 + + util/ntp-keygen-opts.c@1.127, 2008-10-27 06:43:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P136 + + util/ntp-keygen-opts.h@1.127, 2008-10-27 06:43:35-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P136 + + util/ntp-keygen-opts.texi@1.126, 2008-10-27 06:43:36-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P136 + + util/ntp-keygen.1@1.126, 2008-10-27 06:43:37-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P136 + +ChangeSet@1.1735.8.1, 2008-10-27 02:20:45-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1078] statsdir configuration parsing is broken + + ChangeLog@1.238.1.1, 2008-10-27 02:20:24-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1078] statsdir configuration parsing is broken + + ntpd/ntp_util.c@1.67, 2008-10-27 02:20:25-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 1078] statsdir configuration parsing is broken + +ChangeSet@1.1735.1.59, 2008-10-23 19:21:21-04:00, murray@pogo.udel.edu +3 -0 + ChangeLog: + SHM fix. + driver28.html: + Fix to probe once per second rather + than once per polling interval. + Add clockstats for debugging if flag4 is on. (just counters) + refclock_shm.c: + Fix to probe once per second rather + than once per polling interval. + Add clockstats for debugging if flag4 is on. (just counters) + + ChangeLog@1.239, 2008-10-23 19:17:13-04:00, murray@pogo.udel.edu +1 -0 + SHM fix. + + html/drivers/driver28.html@1.11, 2008-10-23 19:18:47-04:00, murray@pogo.udel.edu +56 -9 + Fix to probe once per second rather + than once per polling interval. + Add clockstats for debugging if flag4 is on. (just counters) + + ntpd/refclock_shm.c@1.18, 2008-10-23 19:17:27-04:00, murray@pogo.udel.edu +151 -51 + Fix to probe once per second rather + than once per polling interval. + Add clockstats for debugging if flag4 is on. (just counters) + +ChangeSet@1.1735.1.58, 2008-09-23 07:43:30-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P135 + TAG: NTP_4_2_5P135 + + ChangeLog@1.238, 2008-09-23 07:43:05-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P135 + + ntpd/ntpd-opts.c@1.127, 2008-09-23 07:43:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P135 + + ntpd/ntpd-opts.h@1.127, 2008-09-23 07:43:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P135 + + ntpd/ntpd-opts.texi@1.126, 2008-09-23 07:43:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P135 + + ntpd/ntpd.1@1.126, 2008-09-23 07:43:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P135 + + ntpdc/ntpdc-opts.c@1.123, 2008-09-23 07:43:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P135 + + ntpdc/ntpdc-opts.h@1.123, 2008-09-23 07:43:11-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P135 + + ntpdc/ntpdc-opts.texi@1.122, 2008-09-23 07:43:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P135 + + ntpdc/ntpdc.1@1.122, 2008-09-23 07:43:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P135 + + ntpq/ntpq-opts.c@1.123, 2008-09-23 07:43:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P135 + + ntpq/ntpq-opts.h@1.123, 2008-09-23 07:43:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P135 + + ntpq/ntpq-opts.texi@1.122, 2008-09-23 07:43:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P135 + + ntpq/ntpq.1@1.122, 2008-09-23 07:43:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P135 + + ntpsnmpd/ntpsnmpd-opts.c@1.4, 2008-09-23 07:43:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P135 + + ntpsnmpd/ntpsnmpd-opts.h@1.4, 2008-09-23 07:43:18-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P135 + + ntpsnmpd/ntpsnmpd-opts.texi@1.4, 2008-09-23 07:43:18-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P135 + + ntpsnmpd/ntpsnmpd.1@1.4, 2008-09-23 07:43:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P135 + + packageinfo.sh@1.138, 2008-09-23 07:43:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P135 + + sntp/sntp-opts.c@1.123, 2008-09-23 07:43:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P135 + + sntp/sntp-opts.h@1.123, 2008-09-23 07:43:20-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P135 + + sntp/sntp-opts.texi@1.122, 2008-09-23 07:43:21-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P135 + + sntp/sntp.1@1.122, 2008-09-23 07:43:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P135 + + util/ntp-keygen-opts.c@1.126, 2008-09-23 07:43:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P135 + + util/ntp-keygen-opts.h@1.126, 2008-09-23 07:43:24-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P135 + + util/ntp-keygen-opts.texi@1.125, 2008-09-23 07:43:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P135 + + util/ntp-keygen.1@1.125, 2008-09-23 07:43:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P135 + +ChangeSet@1.1735.1.57, 2008-09-22 20:30:50-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1072] clock_update should not allow updates older than sys_epoch + + ChangeLog@1.237, 2008-09-22 20:30:35-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1072] clock_update should not allow updates older than sys_epoch + + ntpd/ntp_proto.c@1.276, 2008-09-22 20:30:36-04:00, stenn@whimsy.udel.edu +3 -3 + [Bug 1072] clock_update should not allow updates older than sys_epoch + +ChangeSet@1.1735.1.56, 2008-09-17 07:46:56-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P134 + TAG: NTP_4_2_5P134 + + ChangeLog@1.236, 2008-09-17 07:46:30-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P134 + + ntpd/ntpd-opts.c@1.126, 2008-09-17 07:46:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P134 + + ntpd/ntpd-opts.h@1.126, 2008-09-17 07:46:32-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P134 + + ntpd/ntpd-opts.texi@1.125, 2008-09-17 07:46:33-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P134 + + ntpd/ntpd.1@1.125, 2008-09-17 07:46:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P134 + + ntpdc/ntpdc-opts.c@1.122, 2008-09-17 07:46:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P134 + + ntpdc/ntpdc-opts.h@1.122, 2008-09-17 07:46:35-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P134 + + ntpdc/ntpdc-opts.texi@1.121, 2008-09-17 07:46:35-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P134 + + ntpdc/ntpdc.1@1.121, 2008-09-17 07:46:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P134 + + ntpq/ntpq-opts.c@1.122, 2008-09-17 07:46:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P134 + + ntpq/ntpq-opts.h@1.122, 2008-09-17 07:46:38-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P134 + + ntpq/ntpq-opts.texi@1.121, 2008-09-17 07:46:39-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P134 + + ntpq/ntpq.1@1.121, 2008-09-17 07:46:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P134 + + ntpsnmpd/ntpsnmpd-opts.c@1.3, 2008-09-17 07:46:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P134 + + ntpsnmpd/ntpsnmpd-opts.h@1.3, 2008-09-17 07:46:41-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P134 + + ntpsnmpd/ntpsnmpd-opts.texi@1.3, 2008-09-17 07:46:41-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P134 + + ntpsnmpd/ntpsnmpd.1@1.3, 2008-09-17 07:46:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P134 + + packageinfo.sh@1.137, 2008-09-17 07:46:42-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P134 + + sntp/sntp-opts.c@1.122, 2008-09-17 07:46:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P134 + + sntp/sntp-opts.h@1.122, 2008-09-17 07:46:44-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P134 + + sntp/sntp-opts.texi@1.121, 2008-09-17 07:46:45-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P134 + + sntp/sntp.1@1.121, 2008-09-17 07:46:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P134 + + util/ntp-keygen-opts.c@1.125, 2008-09-17 07:46:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P134 + + util/ntp-keygen-opts.h@1.125, 2008-09-17 07:46:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P134 + + util/ntp-keygen-opts.texi@1.124, 2008-09-17 07:46:48-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P134 + + util/ntp-keygen.1@1.124, 2008-09-17 07:46:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P134 + +ChangeSet@1.1735.1.55, 2008-09-16 21:05:36-04:00, stenn@whimsy.udel.edu +4 -0 + Clean up build process for ntpsnmpd. + + ChangeLog@1.235, 2008-09-16 21:00:57-04:00, stenn@whimsy.udel.edu +1 -0 + Clean up build process for ntpsnmpd. + + Makefile.am@1.76.1.2, 2008-09-16 21:03:27-04:00, stenn@whimsy.udel.edu +1 -1 + Clean up build process for ntpsnmpd. + + configure.ac@1.417.1.3, 2008-09-16 21:00:58-04:00, stenn@whimsy.udel.edu +2 -2 + Clean up build process for ntpsnmpd. + + ntpsnmpd/Makefile.am@1.5, 2008-09-16 21:01:00-04:00, stenn@whimsy.udel.edu +2 -1 + Clean up build process for ntpsnmpd. + +ChangeSet@1.1735.1.54, 2008-09-16 19:12:17-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_5P133 + TAG: NTP_4_2_5P133 + + ChangeLog@1.234, 2008-09-16 19:11:55-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P133 + + ntpd/ntpd-opts.c@1.125, 2008-09-16 19:11:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P133 + + ntpd/ntpd-opts.h@1.125, 2008-09-16 19:11:57-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P133 + + ntpd/ntpd-opts.texi@1.124, 2008-09-16 19:11:58-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P133 + + ntpd/ntpd.1@1.124, 2008-09-16 19:11:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P133 + + ntpdc/ntpdc-opts.c@1.121, 2008-09-16 19:12:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P133 + + ntpdc/ntpdc-opts.h@1.121, 2008-09-16 19:12:01-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P133 + + ntpdc/ntpdc-opts.texi@1.120, 2008-09-16 19:12:01-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P133 + + ntpdc/ntpdc.1@1.120, 2008-09-16 19:12:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P133 + + ntpq/ntpq-opts.c@1.121, 2008-09-16 19:12:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P133 + + ntpq/ntpq-opts.h@1.121, 2008-09-16 19:12:03-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P133 + + ntpq/ntpq-opts.texi@1.120, 2008-09-16 19:12:04-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P133 + + ntpq/ntpq.1@1.120, 2008-09-16 19:12:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P133 + + ntpsnmpd/ntpsnmpd-opts.c@1.2, 2008-09-16 19:12:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P133 + + ntpsnmpd/ntpsnmpd-opts.h@1.2, 2008-09-16 19:12:06-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P133 + + ntpsnmpd/ntpsnmpd-opts.texi@1.2, 2008-09-16 19:12:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P133 + + ntpsnmpd/ntpsnmpd.1@1.2, 2008-09-16 19:12:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P133 + + packageinfo.sh@1.136, 2008-09-16 19:12:07-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P133 + + sntp/sntp-opts.c@1.121, 2008-09-16 19:12:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P133 + + sntp/sntp-opts.h@1.121, 2008-09-16 19:12:09-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P133 + + sntp/sntp-opts.texi@1.120, 2008-09-16 19:12:10-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P133 + + sntp/sntp.1@1.120, 2008-09-16 19:12:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P133 + + util/ntp-keygen-opts.c@1.124, 2008-09-16 19:12:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P133 + + util/ntp-keygen-opts.h@1.124, 2008-09-16 19:12:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P133 + + util/ntp-keygen-opts.texi@1.123, 2008-09-16 19:12:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P133 + + util/ntp-keygen.1@1.123, 2008-09-16 19:12:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P133 + +ChangeSet@1.1735.1.53, 2008-09-16 03:34:05-04:00, stenn@whimsy.udel.edu +10 -0 + Add options processing to ntpsnmpd. + + .point-changed-filelist@1.4, 2008-09-16 03:32:05-04:00, stenn@whimsy.udel.edu +4 -0 + Add options processing to ntpsnmpd. + + ChangeLog@1.233, 2008-09-16 03:30:58-04:00, stenn@whimsy.udel.edu +1 -0 + Add options processing to ntpsnmpd. + + ntpsnmpd/Makefile.am@1.4, 2008-09-16 03:30:35-04:00, stenn@whimsy.udel.edu +26 -3 + Add options processing to ntpsnmpd. + + ntpsnmpd/ntpsnmpd-opts.c@1.1, 2008-09-16 03:33:15-04:00, stenn@whimsy.udel.edu +398 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpsnmpd/ntpsnmpd-opts.c + + ntpsnmpd/ntpsnmpd-opts.c@1.0, 2008-09-16 03:33:15-04:00, stenn@whimsy.udel.edu +0 -0 + + ntpsnmpd/ntpsnmpd-opts.def@1.1, 2008-09-16 03:29:56-04:00, stenn@whimsy.udel.edu +28 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpsnmpd/ntpsnmpd-opts.def + + ntpsnmpd/ntpsnmpd-opts.def@1.0, 2008-09-16 03:29:56-04:00, stenn@whimsy.udel.edu +0 -0 + + ntpsnmpd/ntpsnmpd-opts.h@1.1, 2008-09-16 03:33:16-04:00, stenn@whimsy.udel.edu +160 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpsnmpd/ntpsnmpd-opts.h + + ntpsnmpd/ntpsnmpd-opts.h@1.0, 2008-09-16 03:33:16-04:00, stenn@whimsy.udel.edu +0 -0 + + ntpsnmpd/ntpsnmpd-opts.menu@1.1, 2008-09-16 03:33:16-04:00, stenn@whimsy.udel.edu +1 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpsnmpd/ntpsnmpd-opts.menu + + ntpsnmpd/ntpsnmpd-opts.menu@1.0, 2008-09-16 03:33:16-04:00, stenn@whimsy.udel.edu +0 -0 + + ntpsnmpd/ntpsnmpd-opts.texi@1.1, 2008-09-16 03:33:16-04:00, stenn@whimsy.udel.edu +52 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpsnmpd/ntpsnmpd-opts.texi + + ntpsnmpd/ntpsnmpd-opts.texi@1.0, 2008-09-16 03:33:16-04:00, stenn@whimsy.udel.edu +0 -0 + + ntpsnmpd/ntpsnmpd.1@1.1, 2008-09-16 03:33:16-04:00, stenn@whimsy.udel.edu +77 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpsnmpd/ntpsnmpd.1 + + ntpsnmpd/ntpsnmpd.1@1.0, 2008-09-16 03:33:16-04:00, stenn@whimsy.udel.edu +0 -0 + + ntpsnmpd/ntpsnmpd.c@1.2, 2008-09-16 03:30:35-04:00, stenn@whimsy.udel.edu +24 -8 + Add options processing to ntpsnmpd. + +ChangeSet@1.1735.1.52, 2008-09-16 05:40:31+00:00, stenn@ntp1.isc.org +2 -0 + [Bug 1062] Check net-snmp headers before deciding to build ntpsnmpd. + + ChangeLog@1.232, 2008-09-16 05:40:06+00:00, stenn@ntp1.isc.org +1 -0 + [Bug 1062] Check net-snmp headers before deciding to build ntpsnmpd. + + configure.ac@1.417.1.2, 2008-09-16 05:40:20+00:00, stenn@ntp1.isc.org +10 -1 + [Bug 1062] Check net-snmp headers before deciding to build ntpsnmpd. + +ChangeSet@1.1735.1.51, 2008-09-15 23:06:04-04:00, stenn@whimsy.udel.edu +2 -0 + Clean up the libntpq.a build. + + ChangeLog@1.231, 2008-09-15 23:05:39-04:00, stenn@whimsy.udel.edu +1 -0 + Clean up the libntpq.a build. + + ntpq/Makefile.am@1.33, 2008-09-15 23:05:25-04:00, stenn@whimsy.udel.edu +2 -1 + Clean up the libntpq.a build. + +ChangeSet@1.1735.1.50, 2008-09-15 21:15:48-04:00, stenn@whimsy.udel.edu +3 -0 + Regenerate ntp_parser.[ch] from ntp_parser.y + + ChangeLog@1.230, 2008-09-15 21:15:31-04:00, stenn@whimsy.udel.edu +1 -0 + Regenerate ntp_parser.[ch] from ntp_parser.y + + ntpd/ntp_parser.c@1.31, 2008-09-15 21:14:21-04:00, stenn@whimsy.udel.edu +8 -8 + Regenerate ntp_parser.[ch] from ntp_parser.y + + ntpd/ntp_parser.h@1.15, 2008-09-15 21:14:26-04:00, stenn@whimsy.udel.edu +1 -1 + Regenerate ntp_parser.[ch] from ntp_parser.y + +ChangeSet@1.1735.1.49, 2008-09-15 07:43:30-04:00, stenn@whimsy.udel.edu +22 -0 + NTP_4_2_5P132 + TAG: NTP_4_2_5P132 + + ChangeLog@1.229, 2008-09-15 07:43:11-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P132 + + ntpd/ntpd-opts.c@1.124, 2008-09-15 07:43:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P132 + + ntpd/ntpd-opts.h@1.124, 2008-09-15 07:43:13-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P132 + + ntpd/ntpd-opts.texi@1.123, 2008-09-15 07:43:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P132 + + ntpd/ntpd.1@1.123, 2008-09-15 07:43:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P132 + + ntpdc/ntpdc-opts.c@1.120, 2008-09-15 07:43:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P132 + + ntpdc/ntpdc-opts.h@1.120, 2008-09-15 07:43:16-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P132 + + ntpdc/ntpdc-opts.texi@1.119, 2008-09-15 07:43:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P132 + + ntpdc/ntpdc.1@1.119, 2008-09-15 07:43:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P132 + + ntpq/ntpq-opts.c@1.120, 2008-09-15 07:43:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P132 + + ntpq/ntpq-opts.h@1.120, 2008-09-15 07:43:19-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P132 + + ntpq/ntpq-opts.texi@1.119, 2008-09-15 07:43:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P132 + + ntpq/ntpq.1@1.119, 2008-09-15 07:43:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P132 + + packageinfo.sh@1.135, 2008-09-15 07:43:20-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P132 + + sntp/sntp-opts.c@1.120, 2008-09-15 07:43:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P132 + + sntp/sntp-opts.h@1.120, 2008-09-15 07:43:22-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P132 + + sntp/sntp-opts.texi@1.119, 2008-09-15 07:43:23-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P132 + + sntp/sntp.1@1.119, 2008-09-15 07:43:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P132 + + util/ntp-keygen-opts.c@1.123, 2008-09-15 07:43:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P132 + + util/ntp-keygen-opts.h@1.123, 2008-09-15 07:43:25-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P132 + + util/ntp-keygen-opts.texi@1.122, 2008-09-15 07:43:26-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P132 + + util/ntp-keygen.1@1.122, 2008-09-15 07:43:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P132 + +ChangeSet@1.1735.1.48, 2008-09-14 18:41:58-04:00, stenn@whimsy.udel.edu +1 -0 + Remove comment made spurious by the fix for [Bug 1067] + + ntpd/ntpd.c@1.97, 2008-09-14 18:41:37-04:00, stenn@whimsy.udel.edu +0 -1 + Remove comment made spurious by the fix for [Bug 1067] + +ChangeSet@1.1735.1.47, 2008-09-14 18:32:56-04:00, stenn@pogo.udel.edu +1 -0 + tidy a comment + + ChangeLog@1.228, 2008-09-14 18:32:46-04:00, stenn@pogo.udel.edu +3 -2 + tidy a comment + +ChangeSet@1.1735.1.46, 2008-09-14 18:11:27-04:00, utterback@pogo.udel.edu +2 -0 + ntpd.c, ChangeLog: + Multicast DNS service registration must come after the fork on Solaris. + + ChangeLog@1.227, 2008-09-14 18:11:12-04:00, utterback@pogo.udel.edu +1 -0 + Multicast DNS service registration must come after the fork on Solaris. + + ntpd/ntpd.c@1.96, 2008-09-14 18:10:17-04:00, utterback@pogo.udel.edu +8 -8 + Multicast DNS service registration must come after the fork on Solaris. + +ChangeSet@1.1735.1.45, 2008-09-14 10:35:32-04:00, utterback@pogo.udel.edu +3 -0 + ChangeLog: + Error messages should log as errors. + ntp_parser.y, ntp_config.c: + Error messages should log as errors. + + ChangeLog@1.226, 2008-09-14 10:34:30-04:00, utterback@pogo.udel.edu +1 -0 + Error messages should log as errors + + ntpd/ntp_config.c@1.184, 2008-09-14 10:29:55-04:00, utterback@pogo.udel.edu +1 -1 + Error messages should log as errors. + + ntpd/ntp_parser.y@1.25, 2008-09-14 10:30:10-04:00, utterback@pogo.udel.edu +5 -5 + Error messages should log as errors. + +ChangeSet@1.1735.1.44, 2008-09-14 07:43:33-04:00, stenn@whimsy.udel.edu +22 -0 + NTP_4_2_5P131 + TAG: NTP_4_2_5P131 + + ChangeLog@1.225, 2008-09-14 07:43:11-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P131 + + ntpd/ntpd-opts.c@1.123, 2008-09-14 07:43:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P131 + + ntpd/ntpd-opts.h@1.123, 2008-09-14 07:43:13-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P131 + + ntpd/ntpd-opts.texi@1.122, 2008-09-14 07:43:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P131 + + ntpd/ntpd.1@1.122, 2008-09-14 07:43:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P131 + + ntpdc/ntpdc-opts.c@1.119, 2008-09-14 07:43:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P131 + + ntpdc/ntpdc-opts.h@1.119, 2008-09-14 07:43:16-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P131 + + ntpdc/ntpdc-opts.texi@1.118, 2008-09-14 07:43:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P131 + + ntpdc/ntpdc.1@1.118, 2008-09-14 07:43:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P131 + + ntpq/ntpq-opts.c@1.119, 2008-09-14 07:43:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P131 + + ntpq/ntpq-opts.h@1.119, 2008-09-14 07:43:19-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P131 + + ntpq/ntpq-opts.texi@1.118, 2008-09-14 07:43:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P131 + + ntpq/ntpq.1@1.118, 2008-09-14 07:43:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P131 + + packageinfo.sh@1.134, 2008-09-14 07:43:21-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P131 + + sntp/sntp-opts.c@1.119, 2008-09-14 07:43:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P131 + + sntp/sntp-opts.h@1.119, 2008-09-14 07:43:22-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P131 + + sntp/sntp-opts.texi@1.118, 2008-09-14 07:43:23-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P131 + + sntp/sntp.1@1.118, 2008-09-14 07:43:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P131 + + util/ntp-keygen-opts.c@1.122, 2008-09-14 07:43:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P131 + + util/ntp-keygen-opts.h@1.122, 2008-09-14 07:43:26-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P131 + + util/ntp-keygen-opts.texi@1.121, 2008-09-14 07:43:26-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P131 + + util/ntp-keygen.1@1.121, 2008-09-14 07:43:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P131 + +ChangeSet@1.1735.1.43, 2008-09-13 23:07:30-04:00, stenn@pogo.udel.edu +1 -0 + [Bug 1065] Re-enable support for the timingstats file + + ChangeLog@1.224, 2008-09-13 23:07:24-04:00, stenn@pogo.udel.edu +1 -0 + [Bug 1065] Re-enable support for the timingstats file + +ChangeSet@1.1735.1.42, 2008-09-13 23:03:22-04:00, stenn@pogo.udel.edu +2 -0 + rebuild ntp_parser.[ch] with newer bison + + ntpd/ntp_parser.c@1.30, 2008-09-13 23:02:50-04:00, stenn@pogo.udel.edu +2449 -1618 + rebuild with newer bison + + ntpd/ntp_parser.h@1.14, 2008-09-13 23:02:50-04:00, stenn@pogo.udel.edu +363 -161 + rebuild with newer bison + +ChangeSet@1.1735.1.41, 2008-09-13 21:42:40-04:00, utterback@pogo.udel.edu +1 -0 + ntp_config.c: + Reinstate timingstats file + + ntpd/ntp_config.c@1.183, 2008-09-13 21:42:13-04:00, utterback@pogo.udel.edu +1 -0 + Reinstate timingstats file + +ChangeSet@1.1735.7.4, 2008-09-13 07:49:17-04:00, stenn@whimsy.udel.edu +22 -0 + NTP_4_2_5P130 + TAG: NTP_4_2_5P130 + + ChangeLog@1.223, 2008-09-13 07:48:57-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P130 + + ntpd/ntpd-opts.c@1.122, 2008-09-13 07:48:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P130 + + ntpd/ntpd-opts.h@1.122, 2008-09-13 07:48:59-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P130 + + ntpd/ntpd-opts.texi@1.121, 2008-09-13 07:49:00-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P130 + + ntpd/ntpd.1@1.121, 2008-09-13 07:49:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P130 + + ntpdc/ntpdc-opts.c@1.118, 2008-09-13 07:49:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P130 + + ntpdc/ntpdc-opts.h@1.118, 2008-09-13 07:49:02-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P130 + + ntpdc/ntpdc-opts.texi@1.117, 2008-09-13 07:49:03-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P130 + + ntpdc/ntpdc.1@1.117, 2008-09-13 07:49:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P130 + + ntpq/ntpq-opts.c@1.118, 2008-09-13 07:49:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P130 + + ntpq/ntpq-opts.h@1.118, 2008-09-13 07:49:05-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P130 + + ntpq/ntpq-opts.texi@1.117, 2008-09-13 07:49:05-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P130 + + ntpq/ntpq.1@1.117, 2008-09-13 07:49:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P130 + + packageinfo.sh@1.133, 2008-09-13 07:49:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P130 + + sntp/sntp-opts.c@1.118, 2008-09-13 07:49:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P130 + + sntp/sntp-opts.h@1.118, 2008-09-13 07:49:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P130 + + sntp/sntp-opts.texi@1.117, 2008-09-13 07:49:08-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P130 + + sntp/sntp.1@1.117, 2008-09-13 07:49:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P130 + + util/ntp-keygen-opts.c@1.121, 2008-09-13 07:49:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P130 + + util/ntp-keygen-opts.h@1.121, 2008-09-13 07:49:11-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P130 + + util/ntp-keygen-opts.texi@1.120, 2008-09-13 07:49:12-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P130 + + util/ntp-keygen.1@1.120, 2008-09-13 07:49:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P130 + +ChangeSet@1.1735.7.3, 2008-09-13 05:04:00-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1064] Implement --with-net-snmp-config=progname + + ChangeLog@1.222, 2008-09-13 05:03:42-04:00, stenn@whimsy.udel.edu +1 -1 + [Bug 1064] Implement --with-net-snmp-config=progname + +ChangeSet@1.1735.7.2, 2008-09-13 04:58:45-04:00, stenn@whimsy.udel.edu +3 -0 + net-snmp-config cleanup + + ChangeLog@1.221, 2008-09-13 04:58:18-04:00, stenn@whimsy.udel.edu +1 -0 + net-snmp-config cleanup + + configure.ac@1.417.1.1, 2008-09-13 04:58:24-04:00, stenn@whimsy.udel.edu +45 -3 + net-snmp-config cleanup + + ntpsnmpd/Makefile.am@1.3, 2008-09-13 04:55:59-04:00, stenn@whimsy.udel.edu +2 -13 + net-snmp-config cleanup + +ChangeSet@1.1735.7.1, 2008-09-12 15:20:13-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1063] ntpSnmpSubagentObject.h is missing from the distribution + + ChangeLog@1.220, 2008-09-12 15:19:52-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1063] ntpSnmpSubagentObject.h is missing from the distribution + + ntpsnmpd/Makefile.am@1.2, 2008-09-12 15:19:51-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1063] ntpSnmpSubagentObject.h is missing from the distribution + +ChangeSet@1.1735.1.39, 2008-09-12 09:39:33-04:00, utterback@pogo.udel.edu +4 -0 + ntp_util.c, ntp_parser.y, ntp_parser.h, ntp_parser.c: + Reinstate lost timingstats file + + ntpd/ntp_parser.c@1.29, 2008-09-12 09:37:53-04:00, utterback@pogo.udel.edu +1818 -2649 + Reinstate lost timingstats file + + ntpd/ntp_parser.h@1.13, 2008-09-12 09:38:21-04:00, utterback@pogo.udel.edu +161 -361 + Reinstate lost timingstats file + + ntpd/ntp_parser.y@1.24, 2008-09-12 09:38:41-04:00, utterback@pogo.udel.edu +3 -0 + Reinstate lost timingstats file + + ntpd/ntp_util.c@1.66, 2008-09-12 09:38:46-04:00, utterback@pogo.udel.edu +8 -0 + Reinstate lost timingstats file + +ChangeSet@1.1735.1.38, 2008-09-11 07:43:06-04:00, stenn@whimsy.udel.edu +22 -0 + NTP_4_2_5P129 + TAG: NTP_4_2_5P129 + + ChangeLog@1.219, 2008-09-11 07:42:45-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P129 + + ntpd/ntpd-opts.c@1.121, 2008-09-11 07:42:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P129 + + ntpd/ntpd-opts.h@1.121, 2008-09-11 07:42:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P129 + + ntpd/ntpd-opts.texi@1.120, 2008-09-11 07:42:48-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P129 + + ntpd/ntpd.1@1.120, 2008-09-11 07:42:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P129 + + ntpdc/ntpdc-opts.c@1.117, 2008-09-11 07:42:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P129 + + ntpdc/ntpdc-opts.h@1.117, 2008-09-11 07:42:50-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P129 + + ntpdc/ntpdc-opts.texi@1.116, 2008-09-11 07:42:51-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P129 + + ntpdc/ntpdc.1@1.116, 2008-09-11 07:42:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P129 + + ntpq/ntpq-opts.c@1.117, 2008-09-11 07:42:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P129 + + ntpq/ntpq-opts.h@1.117, 2008-09-11 07:42:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P129 + + ntpq/ntpq-opts.texi@1.116, 2008-09-11 07:42:53-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P129 + + ntpq/ntpq.1@1.116, 2008-09-11 07:42:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P129 + + packageinfo.sh@1.132, 2008-09-11 07:42:54-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P129 + + sntp/sntp-opts.c@1.117, 2008-09-11 07:42:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P129 + + sntp/sntp-opts.h@1.117, 2008-09-11 07:42:56-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P129 + + sntp/sntp-opts.texi@1.116, 2008-09-11 07:42:57-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P129 + + sntp/sntp.1@1.116, 2008-09-11 07:42:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P129 + + util/ntp-keygen-opts.c@1.120, 2008-09-11 07:42:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P129 + + util/ntp-keygen-opts.h@1.120, 2008-09-11 07:42:59-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P129 + + util/ntp-keygen-opts.texi@1.119, 2008-09-11 07:43:00-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P129 + + util/ntp-keygen.1@1.119, 2008-09-11 07:43:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P129 + +ChangeSet@1.1735.1.37, 2008-09-11 02:52:01-04:00, stenn@whimsy.udel.edu +3 -0 + Quiet some libntpq-related warnings + + ChangeLog@1.218, 2008-09-11 02:51:50-04:00, stenn@whimsy.udel.edu +1 -0 + Quiet some libntpq-related warnings + + ntpq/Makefile.am@1.32, 2008-09-11 02:51:17-04:00, stenn@whimsy.udel.edu +2 -2 + Quiet some libntpq-related warnings + + ntpq/libntpq.c@1.2, 2008-09-11 02:51:18-04:00, stenn@whimsy.udel.edu +1 -1 + Quiet some libntpq-related warnings + +ChangeSet@1.1771, 2008-09-11 00:35:34-04:00, stenn@pogo.udel.edu +1 -0 + No c++ or F77 for libtool, get socket libraries + + gsoc_sntp/configure.ac@1.4, 2008-09-11 00:35:27-04:00, stenn@pogo.udel.edu +13 -0 + No c++ or F77 for libtool, get socket libraries + +ChangeSet@1.1770, 2008-09-11 00:32:37-04:00, stenn@pogo.udel.edu +1 -0 + doc strings must be tab-indented, not space + + gsoc_sntp/sntp-opts.def@1.8, 2008-09-11 00:32:30-04:00, stenn@pogo.udel.edu +2 -4 + doc strings must be tab-indented, not space + +ChangeSet@1.1768, 2008-09-10 20:26:26-04:00, stenn@pogo.udel.edu +3 -0 + updates + + gsoc_sntp/Makefile.am@1.4, 2008-09-10 20:26:09-04:00, stenn@pogo.udel.edu +1 -0 + updates + + gsoc_sntp/log.c@1.7, 2008-09-10 20:26:09-04:00, stenn@pogo.udel.edu +5 -1 + updates + + gsoc_sntp/sntp-opts.def@1.7, 2008-09-10 20:26:10-04:00, stenn@pogo.udel.edu +49 -33 + updates + +ChangeSet@1.1767, 2008-09-10 23:37:56+00:00, kuehn@pogo.udel.edu +5 -0 + main.c: + fixed includes + crypto.c, networking.c: + Fixed compile errors + + gsoc_sntp/crypto.c@1.3, 2008-09-10 23:37:01+00:00, kuehn@pogo.udel.edu +3 -3 + Fixed compile errors + + gsoc_sntp/crypto.h@1.3, 2008-09-10 23:37:22+00:00, kuehn@pogo.udel.edu +1 -1 + + gsoc_sntp/main.c@1.9, 2008-09-10 23:37:30+00:00, kuehn@pogo.udel.edu +2 -2 + fixed includes + + gsoc_sntp/networking.c@1.15, 2008-09-10 23:36:30+00:00, kuehn@pogo.udel.edu +8 -9 + Fixed compile errors + + gsoc_sntp/networking.h@1.11, 2008-09-10 23:36:46+00:00, kuehn@pogo.udel.edu +2 -0 + +ChangeSet@1.1766, 2008-09-10 22:58:04+00:00, kuehn@pogo.udel.edu +13 -0 + log.h: + fixed missing timestamp for file logging + kod_management.c: + Fixed the core dump when no kod file is specified + networking.c: + Some fixes for broadcast mode + remove filter reachable (no use for this function) + utilities.c: + Added a function to convert a struct sockaddr_storage to a string containing its hostname + crypto.c: + Completeted auth md5 functions + + BitKeeper/etc/gone@1.8, 2008-09-10 22:56:50+00:00, kuehn@pogo.udel.edu +14 -0 + + gsoc_sntp/crypto.c@1.2, 2008-09-10 22:50:58+00:00, kuehn@pogo.udel.edu +125 -39 + Completeted auth md5 functions + + gsoc_sntp/crypto.h@1.2, 2008-09-10 22:51:33+00:00, kuehn@pogo.udel.edu +35 -5 + + gsoc_sntp/header.h@1.3, 2008-09-10 22:51:40+00:00, kuehn@pogo.udel.edu +5 -3 + + gsoc_sntp/kod_management.c@1.6, 2008-09-10 22:51:45+00:00, kuehn@pogo.udel.edu +25 -4 + Fixed the core dump when no kod file is specified + + gsoc_sntp/kod_management.h@1.4, 2008-09-10 22:52:08+00:00, kuehn@pogo.udel.edu +18 -1 + + gsoc_sntp/log.c@1.6, 2008-09-10 22:52:10+00:00, kuehn@pogo.udel.edu +26 -5 + + gsoc_sntp/log.h@1.4, 2008-09-10 22:52:10+00:00, kuehn@pogo.udel.edu +20 -2 + fixed missing timestamp for file logging + + gsoc_sntp/main.c@1.8, 2008-09-10 22:52:31+00:00, kuehn@pogo.udel.edu +18 -11 + + gsoc_sntp/networking.c@1.14, 2008-09-10 22:52:48+00:00, kuehn@pogo.udel.edu +457 -94 + Some fixes for broadcast mode + remove filter reachable (no use for this function) + + gsoc_sntp/networking.h@1.10, 2008-09-10 22:53:06+00:00, kuehn@pogo.udel.edu +33 -3 + + gsoc_sntp/utilities.c@1.4, 2008-09-10 22:53:09+00:00, kuehn@pogo.udel.edu +46 -0 + Added a function to convert a struct sockaddr_storage to a string containing its hostname + + gsoc_sntp/utilities.h@1.3, 2008-09-10 22:53:52+00:00, kuehn@pogo.udel.edu +35 -0 + +ChangeSet@1.1735.1.36, 2008-09-08 07:46:43-04:00, stenn@whimsy.udel.edu +22 -0 + NTP_4_2_5P128 + TAG: NTP_4_2_5P128 + + ChangeLog@1.217, 2008-09-08 07:46:23-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P128 + + ntpd/ntpd-opts.c@1.120, 2008-09-08 07:46:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P128 + + ntpd/ntpd-opts.h@1.120, 2008-09-08 07:46:24-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P128 + + ntpd/ntpd-opts.texi@1.119, 2008-09-08 07:46:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P128 + + ntpd/ntpd.1@1.119, 2008-09-08 07:46:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P128 + + ntpdc/ntpdc-opts.c@1.116, 2008-09-08 07:46:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P128 + + ntpdc/ntpdc-opts.h@1.116, 2008-09-08 07:46:28-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P128 + + ntpdc/ntpdc-opts.texi@1.115, 2008-09-08 07:46:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P128 + + ntpdc/ntpdc.1@1.115, 2008-09-08 07:46:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P128 + + ntpq/ntpq-opts.c@1.116, 2008-09-08 07:46:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P128 + + ntpq/ntpq-opts.h@1.116, 2008-09-08 07:46:31-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P128 + + ntpq/ntpq-opts.texi@1.115, 2008-09-08 07:46:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P128 + + ntpq/ntpq.1@1.115, 2008-09-08 07:46:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P128 + + packageinfo.sh@1.131, 2008-09-08 07:46:33-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P128 + + sntp/sntp-opts.c@1.116, 2008-09-08 07:46:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P128 + + sntp/sntp-opts.h@1.116, 2008-09-08 07:46:34-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P128 + + sntp/sntp-opts.texi@1.115, 2008-09-08 07:46:35-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P128 + + sntp/sntp.1@1.115, 2008-09-08 07:46:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P128 + + util/ntp-keygen-opts.c@1.119, 2008-09-08 07:46:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P128 + + util/ntp-keygen-opts.h@1.119, 2008-09-08 07:46:37-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P128 + + util/ntp-keygen-opts.texi@1.118, 2008-09-08 07:46:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P128 + + util/ntp-keygen.1@1.118, 2008-09-08 07:46:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P128 + +ChangeSet@1.1735.6.4, 2008-09-08 03:57:36-04:00, stenn@whimsy.udel.edu +1 -0 + Cleanup missing ChangeLog message + + ChangeLog@1.213.1.3, 2008-09-08 03:57:21-04:00, stenn@whimsy.udel.edu +1 -0 + Cleanup missing ChangeLog message + +ChangeSet@1.1759.1.1, 2008-09-05 00:08:08+00:00, kuehn@pogo.udel.edu +8 -0 + kod_management.h, main.c, kod_management.c: + Fixes + networking.h: + fixes + broadcast mode + crypto.h: + BitKeeper file /pogo/users/kuehn/rsync_repo/ntp-dev/gsoc_sntp/crypto.h + crypto.c: + BitKeeper file /pogo/users/kuehn/rsync_repo/ntp-dev/gsoc_sntp/crypto.c + networking.c: + Fixes + Broadcast mode + sntp-opts.def: + Added new options, removed host list + + gsoc_sntp/crypto.c@1.1, 2008-09-05 00:06:25+00:00, kuehn@pogo.udel.edu +97 -0 + BitKeeper file /pogo/users/kuehn/rsync_repo/ntp-dev/gsoc_sntp/crypto.c + + gsoc_sntp/crypto.c@1.0, 2008-09-05 00:06:25+00:00, kuehn@pogo.udel.edu +0 -0 + + gsoc_sntp/crypto.h@1.1, 2008-09-05 00:06:33+00:00, kuehn@pogo.udel.edu +19 -0 + BitKeeper file /pogo/users/kuehn/rsync_repo/ntp-dev/gsoc_sntp/crypto.h + + gsoc_sntp/crypto.h@1.0, 2008-09-05 00:06:33+00:00, kuehn@pogo.udel.edu +0 -0 + +ChangeSet@1.1735.6.3, 2008-09-01 07:42:29-04:00, stenn@whimsy.udel.edu +22 -0 + NTP_4_2_5P127 + TAG: NTP_4_2_5P127 + + ChangeLog@1.213.1.2, 2008-09-01 07:42:07-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P127 + + ntpd/ntpd-opts.c@1.119, 2008-09-01 07:42:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P127 + + ntpd/ntpd-opts.h@1.119, 2008-09-01 07:42:09-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P127 + + ntpd/ntpd-opts.texi@1.118, 2008-09-01 07:42:11-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P127 + + ntpd/ntpd.1@1.118, 2008-09-01 07:42:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P127 + + ntpdc/ntpdc-opts.c@1.115, 2008-09-01 07:42:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P127 + + ntpdc/ntpdc-opts.h@1.115, 2008-09-01 07:42:13-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P127 + + ntpdc/ntpdc-opts.texi@1.114, 2008-09-01 07:42:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P127 + + ntpdc/ntpdc.1@1.114, 2008-09-01 07:42:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P127 + + ntpq/ntpq-opts.c@1.115, 2008-09-01 07:42:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P127 + + ntpq/ntpq-opts.h@1.115, 2008-09-01 07:42:16-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P127 + + ntpq/ntpq-opts.texi@1.114, 2008-09-01 07:42:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P127 + + ntpq/ntpq.1@1.114, 2008-09-01 07:42:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P127 + + packageinfo.sh@1.130, 2008-09-01 07:42:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P127 + + sntp/sntp-opts.c@1.115, 2008-09-01 07:42:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P127 + + sntp/sntp-opts.h@1.115, 2008-09-01 07:42:20-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P127 + + sntp/sntp-opts.texi@1.114, 2008-09-01 07:42:21-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P127 + + sntp/sntp.1@1.114, 2008-09-01 07:42:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P127 + + util/ntp-keygen-opts.c@1.118, 2008-09-01 07:42:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P127 + + util/ntp-keygen-opts.h@1.118, 2008-09-01 07:42:24-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P127 + + util/ntp-keygen-opts.texi@1.117, 2008-09-01 07:42:24-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P127 + + util/ntp-keygen.1@1.117, 2008-09-01 07:42:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P127 + +ChangeSet@1.1735.6.2, 2008-08-31 20:42:07-04:00, stenn@whimsy.udel.edu +1 -0 + regenerate ntp_parser.c + + ntpd/ntp_parser.c@1.28, 2008-08-31 20:41:47-04:00, stenn@whimsy.udel.edu +802 -851 + regenerate ntp_parser.c + +ChangeSet@1.1735.6.1, 2008-08-31 07:49:04-04:00, stenn@whimsy.udel.edu +22 -0 + NTP_4_2_5P126 + TAG: NTP_4_2_5P126 + + ChangeLog@1.213.1.1, 2008-08-31 07:48:41-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P126 + + ntpd/ntpd-opts.c@1.118, 2008-08-31 07:48:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P126 + + ntpd/ntpd-opts.h@1.118, 2008-08-31 07:48:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P126 + + ntpd/ntpd-opts.texi@1.117, 2008-08-31 07:48:44-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P126 + + ntpd/ntpd.1@1.117, 2008-08-31 07:48:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P126 + + ntpdc/ntpdc-opts.c@1.114, 2008-08-31 07:48:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P126 + + ntpdc/ntpdc-opts.h@1.114, 2008-08-31 07:48:48-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P126 + + ntpdc/ntpdc-opts.texi@1.113, 2008-08-31 07:48:48-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P126 + + ntpdc/ntpdc.1@1.113, 2008-08-31 07:48:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P126 + + ntpq/ntpq-opts.c@1.114, 2008-08-31 07:48:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P126 + + ntpq/ntpq-opts.h@1.114, 2008-08-31 07:48:51-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P126 + + ntpq/ntpq-opts.texi@1.113, 2008-08-31 07:48:52-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P126 + + ntpq/ntpq.1@1.113, 2008-08-31 07:48:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P126 + + packageinfo.sh@1.129, 2008-08-31 07:48:53-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P126 + + sntp/sntp-opts.c@1.114, 2008-08-31 07:48:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P126 + + sntp/sntp-opts.h@1.114, 2008-08-31 07:48:55-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P126 + + sntp/sntp-opts.texi@1.113, 2008-08-31 07:48:56-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P126 + + sntp/sntp.1@1.113, 2008-08-31 07:48:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P126 + + util/ntp-keygen-opts.c@1.117, 2008-08-31 07:48:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P126 + + util/ntp-keygen-opts.h@1.117, 2008-08-31 07:48:58-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P126 + + util/ntp-keygen-opts.texi@1.116, 2008-08-31 07:48:59-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P126 + + util/ntp-keygen.1@1.116, 2008-08-31 07:49:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P126 + +ChangeSet@1.1764, 2008-08-31 07:15:07-04:00, stenn@pogo.udel.edu +3 -0 + portability fixes + + configure.ac@1.416.1.1, 2008-08-31 07:13:22-04:00, stenn@pogo.udel.edu +1 -0 + build gsoc_snmp + +ChangeSet@1.1763, 2008-08-31 05:56:21-04:00, stenn@pogo.udel.edu +1 -0 + Have libtool ignore C++ and F77 + +ChangeSet@1.1735.5.1, 2008-08-31 04:59:46-04:00, stenn@pogo.udel.edu +13 -0 + Prepare for GSoC2008 NTP MIB daemon import + + ChangeLog@1.212.1.1, 2008-08-31 04:57:51-04:00, stenn@pogo.udel.edu +1 -0 + Prepare for GSoC2008 NTP MIB daemon import + + Makefile.am@1.76.1.1, 2008-08-31 04:57:51-04:00, stenn@pogo.udel.edu +2 -0 + Prepare for GSoC2008 NTP MIB daemon import + + configure.ac@1.415.1.1, 2008-08-31 04:57:52-04:00, stenn@pogo.udel.edu +27 -0 + Prepare for GSoC2008 NTP MIB daemon import + + ntpq/Makefile.am@1.31, 2008-08-31 04:58:17-04:00, stenn@pogo.udel.edu +6 -5 + Prepare for GSoC2008 NTP MIB daemon import + + ntpq/libntpq.c@1.1, 2008-08-22 17:46:04-04:00, stenn@pogo.udel.edu +790 -0 + BitKeeper file /pogo/users/gerstung/gsoc/ntp-dev/ntpq/libntpq.c + + ntpq/libntpq.c@1.0, 2008-08-22 17:46:04-04:00, stenn@pogo.udel.edu +0 -0 + + ntpq/libntpq.h@1.1, 2008-08-22 17:46:04-04:00, stenn@pogo.udel.edu +108 -0 + BitKeeper file /pogo/users/gerstung/gsoc/ntp-dev/ntpq/libntpq.h + + ntpq/libntpq.h@1.0, 2008-08-22 17:46:04-04:00, stenn@pogo.udel.edu +0 -0 + + ntpq/libntpq_subs.c@1.1, 2008-08-22 17:46:04-04:00, stenn@pogo.udel.edu +50 -0 + BitKeeper file /pogo/users/gerstung/gsoc/ntp-dev/ntpq/libntpq_subs.c + + ntpq/libntpq_subs.c@1.0, 2008-08-22 17:46:04-04:00, stenn@pogo.udel.edu +0 -0 + + ntpq/ntpq.c@1.75, 2008-08-31 04:58:18-04:00, stenn@pogo.udel.edu +7 -2 + Prepare for GSoC2008 NTP MIB daemon import + + ntpsnmpd/Makefile.am@1.1, 2008-08-31 04:54:39-04:00, stenn@pogo.udel.edu +19 -0 + BitKeeper file /pogo/users/gerstung/gsoc/ntp-dev/ntpsnmpd/Makefile.am + + ntpsnmpd/Makefile.am@1.0, 2008-08-31 04:54:39-04:00, stenn@pogo.udel.edu +0 -0 + + ntpsnmpd/README@1.1, 2008-08-31 04:54:39-04:00, stenn@pogo.udel.edu +40 -0 + BitKeeper file /pogo/users/gerstung/gsoc/ntp-dev/ntpsnmpd/README + + ntpsnmpd/README@1.0, 2008-08-31 04:54:39-04:00, stenn@pogo.udel.edu +0 -0 + + ntpsnmpd/ntpSnmpSubagentObject.c@1.1, 2008-08-31 04:54:39-04:00, stenn@pogo.udel.edu +490 -0 + BitKeeper file /pogo/users/gerstung/gsoc/ntp-dev/ntpsnmpd/ntpSnmpSubagentObject.c + + ntpsnmpd/ntpSnmpSubagentObject.c@1.0, 2008-08-31 04:54:39-04:00, stenn@pogo.udel.edu +0 -0 + + ntpsnmpd/ntpSnmpSubagentObject.h@1.1, 2008-08-31 04:54:39-04:00, stenn@pogo.udel.edu +72 -0 + BitKeeper file /pogo/users/gerstung/gsoc/ntp-dev/ntpsnmpd/ntpSnmpSubagentObject.h + + ntpsnmpd/ntpSnmpSubagentObject.h@1.0, 2008-08-31 04:54:39-04:00, stenn@pogo.udel.edu +0 -0 + + ntpsnmpd/ntpsnmpd.c@1.1, 2008-08-31 04:54:39-04:00, stenn@pogo.udel.edu +107 -0 + BitKeeper file /pogo/users/gerstung/gsoc/ntp-dev/ntpsnmpd/ntpsnmpd.c + + ntpsnmpd/ntpsnmpd.c@1.0, 2008-08-31 04:54:39-04:00, stenn@pogo.udel.edu +0 -0 + +ChangeSet@1.1735.1.32, 2008-08-31 04:43:40-04:00, stenn@whimsy.udel.edu +1 -0 + Stop libtool-1.5 from looking for C++ or Fortran + + sntp/configure.ac@1.17, 2008-08-31 04:43:30-04:00, stenn@whimsy.udel.edu +3 -0 + Stop libtool-1.5 from looking for C++ or Fortran + +ChangeSet@1.1735.1.31, 2008-08-31 04:33:40-04:00, stenn@whimsy.udel.edu +2 -0 + Stop libtool-1.5 from looking for C++ or Fortran + + ChangeLog@1.213, 2008-08-31 04:33:24-04:00, stenn@whimsy.udel.edu +1 -0 + Stop libtool-1.5 from looking for C++ or Fortran + + configure.ac@1.416, 2008-08-31 04:33:26-04:00, stenn@whimsy.udel.edu +4 -0 + Stop libtool-1.5 from looking for C++ or Fortran + +ChangeSet@1.1735.4.4, 2008-08-31 02:06:36-04:00, stenn@whimsy.udel.edu +4 -0 + [Bug 828] Fix IPv4/IPv6 address parsing + + ChangeLog@1.210.1.4, 2008-08-31 02:05:49-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 828] Fix IPv4/IPv6 address parsing + + ntpd/ntp_config.c@1.182, 2008-08-31 02:05:58-04:00, stenn@whimsy.udel.edu +11 -2 + [Bug 828] Fix IPv4/IPv6 address parsing + + ntpd/ntp_parser.y@1.23, 2008-08-31 02:06:00-04:00, stenn@whimsy.udel.edu +9 -42 + [Bug 828] Fix IPv4/IPv6 address parsing + + ntpd/ntp_scanner.c@1.13, 2008-08-31 02:06:02-04:00, stenn@whimsy.udel.edu +43 -31 + [Bug 828] Fix IPv4/IPv6 address parsing + +ChangeSet@1.1761, 2008-08-31 01:43:34-04:00, stenn@pogo.udel.edu +3 -0 + portability fixes + +ChangeSet@1.1735.4.3, 2008-08-30 23:19:40-04:00, stenn@whimsy.udel.edu +19 -0 + Documentation updates from Dave Mills + + ChangeLog@1.210.1.3, 2008-08-30 23:19:25-04:00, stenn@whimsy.udel.edu +1 -0 + Documentation updates from Dave Mills + + html/confopt.html@1.43, 2008-08-30 23:18:11-04:00, stenn@whimsy.udel.edu +1 -1 + Documentation updates from Dave Mills + + html/decode.html@1.3, 2008-08-30 23:18:12-04:00, stenn@whimsy.udel.edu +0 -1 + Documentation updates from Dave Mills + + html/gadget.html@1.3, 2008-08-30 23:18:13-04:00, stenn@whimsy.udel.edu +3 -3 + Documentation updates from Dave Mills + + html/howto.html@1.20, 2008-08-30 23:18:13-04:00, stenn@whimsy.udel.edu +3 -2 + Documentation updates from Dave Mills + + html/index.html@1.38, 2008-08-30 23:18:14-04:00, stenn@whimsy.udel.edu +9 -8 + Documentation updates from Dave Mills + + html/kern.html@1.17, 2008-08-30 23:18:15-04:00, stenn@whimsy.udel.edu +3 -3 + Documentation updates from Dave Mills + + html/keygen.html@1.13, 2008-08-30 23:18:16-04:00, stenn@whimsy.udel.edu +65 -20 + Documentation updates from Dave Mills + + html/manyopt.html@1.18, 2008-08-30 23:18:16-04:00, stenn@whimsy.udel.edu +3 -3 + Documentation updates from Dave Mills + + html/ntp_conf.html@1.3, 2008-08-30 23:18:18-04:00, stenn@whimsy.udel.edu +10 -9 + Documentation updates from Dave Mills + + html/ntpd.html@1.46, 2008-08-30 23:18:19-04:00, stenn@whimsy.udel.edu +9 -9 + Documentation updates from Dave Mills + + html/ntpdsim_new.html@1.4, 2008-08-30 23:18:20-04:00, stenn@whimsy.udel.edu +8 -1 + Documentation updates from Dave Mills + + html/parsenew.html@1.11, 2008-08-30 23:18:21-04:00, stenn@whimsy.udel.edu +1 -3 + Documentation updates from Dave Mills + + html/pps.html@1.20, 2008-08-30 23:18:22-04:00, stenn@whimsy.udel.edu +6 -4 + Documentation updates from Dave Mills + + html/prefer.html@1.17, 2008-08-30 23:18:22-04:00, stenn@whimsy.udel.edu +14 -14 + Documentation updates from Dave Mills + + html/rate.html@1.4, 2008-08-30 23:18:24-04:00, stenn@whimsy.udel.edu +14 -8 + Documentation updates from Dave Mills + + html/refclock.html@1.34, 2008-08-30 23:18:24-04:00, stenn@whimsy.udel.edu +47 -47 + Documentation updates from Dave Mills + + html/release.html@1.36, 2008-08-30 23:18:25-04:00, stenn@whimsy.udel.edu +27 -24 + Documentation updates from Dave Mills + + html/xleave.html@1.3, 2008-08-30 23:18:27-04:00, stenn@whimsy.udel.edu +3 -2 + Documentation updates from Dave Mills + +ChangeSet@1.1735.4.2, 2008-08-30 23:14:01-04:00, stenn@whimsy.udel.edu +2 -0 + Fix a corner case where a frequency update was reported but not set + + ChangeLog@1.210.1.2, 2008-08-30 23:13:47-04:00, stenn@whimsy.udel.edu +1 -0 + Fix a corner case where a frequency update was reported but not set + + ntpd/ntp_loopfilter.c@1.147, 2008-08-30 23:13:14-04:00, stenn@whimsy.udel.edu +6 -5 + Fix a corner case where a frequency update was reported but not set + +ChangeSet@1.1735.4.1, 2008-08-30 22:09:29-04:00, stenn@whimsy.udel.edu +3 -0 + When LEAP_NOTINSYNC->LEAP_NOWARNING, call crypto_update() if we have crypto_flags + + ChangeLog@1.210.1.1, 2008-08-30 22:09:11-04:00, stenn@whimsy.udel.edu +3 -0 + When LEAP_NOTINSYNC->LEAP_NOWARNING, call crypto_update() if we have crypto_flags + + html/pic/boom4.gif@1.1, 2008-08-30 00:33:26-04:00, stenn@whimsy.udel.edu +361 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/boom4.gif + + html/pic/boom4.gif@1.0, 2008-08-30 00:33:26-04:00, stenn@whimsy.udel.edu +0 -0 + + ntpd/ntp_proto.c@1.275, 2008-08-30 22:01:58-04:00, stenn@whimsy.udel.edu +6 -1 + When LEAP_NOTINSYNC->LEAP_NOWARNING, call crypto_update() if we have crypto_flags + +ChangeSet@1.1759, 2008-08-22 21:27:59-04:00, stenn@pogo.udel.edu +1 -0 + remove bogus .o file + + BitKeeper/deleted/.del-utilities.o@1.2, 2008-08-22 21:27:25-04:00, stenn@pogo.udel.edu +0 -0 + Delete: gsoc_sntp/utilities.o + +ChangeSet@1.1735.1.29, 2008-08-21 05:05:19+00:00, gopal@pogo.udel.edu +2 -0 + driver20.html: + [BUG 610] Documentation update for NMEA reference clock driver. + ChangeLog: + Added appropriate comments for documentation update. + + ChangeLog@1.211, 2008-08-21 05:03:55+00:00, gopal@pogo.udel.edu +1 -0 + Added appropriate comments for documentation update. + + html/drivers/driver20.html@1.15, 2008-08-21 05:02:31+00:00, gopal@pogo.udel.edu +23 -6 + [BUG 610] Documentation update for NMEA reference clock driver. + +ChangeSet@1.1757, 2008-08-18 21:37:27+09:00, Amidamaru@yumi.mxiesoft.com +7 -0 + utilities.c, networking.c: + Fixes + sntp-opts.def: + added broadcast and timeout options + log.c: + Fixes, one bug with filelogging left + main.c: + Fixed KOD handling in on_Ăwire + + gsoc_sntp/log.c@1.5, 2008-08-18 21:36:18+09:00, Amidamaru@yumi.mxiesoft.com +2 -4 + Fixes, one bug with filelogging left + + gsoc_sntp/main.c@1.7, 2008-08-18 21:36:42+09:00, Amidamaru@yumi.mxiesoft.com +87 -35 + Fixed KOD handling in on_Ăwire + + gsoc_sntp/networking.c@1.13, 2008-08-18 21:35:48+09:00, Amidamaru@yumi.mxiesoft.com +85 -75 + Fixes + + gsoc_sntp/networking.h@1.9, 2008-08-18 21:36:09+09:00, Amidamaru@yumi.mxiesoft.com +85 -14 + + gsoc_sntp/sntp-opts.def@1.6, 2008-08-18 21:36:32+09:00, Amidamaru@yumi.mxiesoft.com +23 -0 + added broadcast and timeout options + + gsoc_sntp/utilities.c@1.3, 2008-08-18 21:36:11+09:00, Amidamaru@yumi.mxiesoft.com +12 -0 + Fixes + + gsoc_sntp/utilities.h@1.2, 2008-08-18 21:36:17+09:00, Amidamaru@yumi.mxiesoft.com +1 -0 + +ChangeSet@1.1735.1.28, 2008-08-18 07:43:18-04:00, stenn@whimsy.udel.edu +22 -0 + NTP_4_2_5P125 + TAG: NTP_4_2_5P125 + + ChangeLog@1.210, 2008-08-18 07:43:02-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P125 + + ntpd/ntpd-opts.c@1.117, 2008-08-18 07:43:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P125 + + ntpd/ntpd-opts.h@1.117, 2008-08-18 07:43:04-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P125 + + ntpd/ntpd-opts.texi@1.116, 2008-08-18 07:43:04-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P125 + + ntpd/ntpd.1@1.116, 2008-08-18 07:43:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P125 + + ntpdc/ntpdc-opts.c@1.113, 2008-08-18 07:43:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P125 + + ntpdc/ntpdc-opts.h@1.113, 2008-08-18 07:43:06-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P125 + + ntpdc/ntpdc-opts.texi@1.112, 2008-08-18 07:43:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P125 + + ntpdc/ntpdc.1@1.112, 2008-08-18 07:43:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P125 + + ntpq/ntpq-opts.c@1.113, 2008-08-18 07:43:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P125 + + ntpq/ntpq-opts.h@1.113, 2008-08-18 07:43:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P125 + + ntpq/ntpq-opts.texi@1.112, 2008-08-18 07:43:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P125 + + ntpq/ntpq.1@1.112, 2008-08-18 07:43:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P125 + + packageinfo.sh@1.128, 2008-08-18 07:43:10-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P125 + + sntp/sntp-opts.c@1.113, 2008-08-18 07:43:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P125 + + sntp/sntp-opts.h@1.113, 2008-08-18 07:43:11-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P125 + + sntp/sntp-opts.texi@1.112, 2008-08-18 07:43:12-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P125 + + sntp/sntp.1@1.112, 2008-08-18 07:43:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P125 + + util/ntp-keygen-opts.c@1.116, 2008-08-18 07:43:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P125 + + util/ntp-keygen-opts.h@1.116, 2008-08-18 07:43:13-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P125 + + util/ntp-keygen-opts.texi@1.115, 2008-08-18 07:43:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P125 + + util/ntp-keygen.1@1.115, 2008-08-18 07:43:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P125 + +ChangeSet@1.1735.1.27, 2008-08-17 19:38:48-04:00, stenn@pogo.udel.edu +1 -0 + [Bug 1052] Add linuxPPS support to ONCORE driver + + ChangeLog@1.209, 2008-08-17 19:38:40-04:00, stenn@pogo.udel.edu +1 -0 + [Bug 1052] Add linuxPPS support to ONCORE driver + +ChangeSet@1.1735.3.3, 2008-08-17 07:52:08-04:00, stenn@whimsy.udel.edu +22 -0 + NTP_4_2_5P124 + TAG: NTP_4_2_5P124 + + ChangeLog@1.208, 2008-08-17 07:51:51-04:00, stenn@whimsy.udel.edu +1 -0 + NTP_4_2_5P124 + + ntpd/ntpd-opts.c@1.116, 2008-08-17 07:51:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P124 + + ntpd/ntpd-opts.h@1.116, 2008-08-17 07:51:53-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P124 + + ntpd/ntpd-opts.texi@1.115, 2008-08-17 07:51:53-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P124 + + ntpd/ntpd.1@1.115, 2008-08-17 07:51:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P124 + + ntpdc/ntpdc-opts.c@1.112, 2008-08-17 07:51:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P124 + + ntpdc/ntpdc-opts.h@1.112, 2008-08-17 07:51:55-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P124 + + ntpdc/ntpdc-opts.texi@1.111, 2008-08-17 07:51:56-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P124 + + ntpdc/ntpdc.1@1.111, 2008-08-17 07:51:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P124 + + ntpq/ntpq-opts.c@1.112, 2008-08-17 07:51:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P124 + + ntpq/ntpq-opts.h@1.112, 2008-08-17 07:51:58-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P124 + + ntpq/ntpq-opts.texi@1.111, 2008-08-17 07:51:59-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P124 + + ntpq/ntpq.1@1.111, 2008-08-17 07:51:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P124 + + packageinfo.sh@1.127, 2008-08-17 07:52:00-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P124 + + sntp/sntp-opts.c@1.112, 2008-08-17 07:52:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P124 + + sntp/sntp-opts.h@1.112, 2008-08-17 07:52:01-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P124 + + sntp/sntp-opts.texi@1.111, 2008-08-17 07:52:02-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P124 + + sntp/sntp.1@1.111, 2008-08-17 07:52:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P124 + + util/ntp-keygen-opts.c@1.115, 2008-08-17 07:52:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P124 + + util/ntp-keygen-opts.h@1.115, 2008-08-17 07:52:04-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P124 + + util/ntp-keygen-opts.texi@1.114, 2008-08-17 07:52:04-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P124 + + util/ntp-keygen.1@1.114, 2008-08-17 07:52:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P124 + +ChangeSet@1.1735.3.2, 2008-08-17 06:57:54-04:00, stenn@whimsy.udel.edu +3 -0 + Documentation updates from Dave Mills + + ChangeLog@1.207, 2008-08-17 06:57:44-04:00, stenn@whimsy.udel.edu +1 -0 + Documentation updates from Dave Mills + + html/ntpd.html@1.45, 2008-08-17 06:57:11-04:00, stenn@whimsy.udel.edu +11 -1 + Documentation updates from Dave Mills + + html/xleave.html@1.2, 2008-08-17 06:57:12-04:00, stenn@whimsy.udel.edu +9 -2 + Documentation updates from Dave Mills + +ChangeSet@1.1436.15.6, 2008-08-17 06:21:39-04:00, stenn@whimsy.udel.edu +1 -0 + typo + + scripts/addChangeLogTag@1.3, 2008-08-17 06:21:25-04:00, stenn@whimsy.udel.edu +0 -3 + typo + +ChangeSet@1.1436.15.5, 2008-08-17 06:16:19-04:00, stenn@whimsy.udel.edu +1 -0 + typo + + ChangeLog@1.1.1.44, 2008-08-17 06:16:08-04:00, stenn@whimsy.udel.edu +0 -2 + typo + +ChangeSet@1.1436.15.4, 2008-08-17 05:30:47-04:00, stenn@whimsy.udel.edu +26 -0 + NTP_4_2_4P5 + TAG: NTP_4_2_4P5 + + ChangeLog@1.1.1.43, 2008-08-17 05:30:27-04:00, stenn@whimsy.udel.edu +3 -0 + NTP_4_2_4P5 + + ntpd/ntpd-opts.c@1.50.16.1, 2008-08-17 05:30:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + + ntpd/ntpd-opts.h@1.50.16.1, 2008-08-17 05:30:28-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P5 + + ntpd/ntpd-opts.texi@1.49.16.1, 2008-08-17 05:30:29-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5 + + ntpd/ntpd.1@1.48.16.1, 2008-08-17 05:30:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + + ntpd/ntpdsim-opts.c@1.50.16.1, 2008-08-17 05:30:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + + ntpd/ntpdsim-opts.h@1.50.16.1, 2008-08-17 05:30:31-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P5 + + ntpd/ntpdsim-opts.texi@1.48.16.1, 2008-08-17 05:30:32-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5 + + ntpd/ntpdsim.1@1.48.16.1, 2008-08-17 05:30:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + + ntpdc/ntpdc-opts.c@1.50.16.1, 2008-08-17 05:30:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + + ntpdc/ntpdc-opts.h@1.50.16.1, 2008-08-17 05:30:34-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P5 + + ntpdc/ntpdc-opts.texi@1.48.16.1, 2008-08-17 05:30:34-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5 + + ntpdc/ntpdc.1@1.48.16.1, 2008-08-17 05:30:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + + ntpq/ntpq-opts.c@1.52.16.1, 2008-08-17 05:30:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + + ntpq/ntpq-opts.h@1.52.16.1, 2008-08-17 05:30:36-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P5 + + ntpq/ntpq-opts.texi@1.49.16.1, 2008-08-17 05:30:36-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5 + + ntpq/ntpq.1@1.48.16.1, 2008-08-17 05:30:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + + packageinfo.sh@1.65.23.2, 2008-08-17 05:30:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + + sntp/sntp-opts.c@1.49.16.1, 2008-08-17 05:30:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + + sntp/sntp-opts.h@1.49.16.1, 2008-08-17 05:30:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P5 + + sntp/sntp-opts.texi@1.46.16.1, 2008-08-17 05:30:39-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5 + + sntp/sntp.1@1.49.16.1, 2008-08-17 05:30:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + + util/ntp-keygen-opts.c@1.49.16.1, 2008-08-17 05:30:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + + util/ntp-keygen-opts.h@1.49.16.1, 2008-08-17 05:30:41-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P5 + + util/ntp-keygen-opts.texi@1.47.16.1, 2008-08-17 05:30:42-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5 + + util/ntp-keygen.1@1.47.16.1, 2008-08-17 05:30:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5 + +ChangeSet@1.1436.15.3, 2008-08-17 05:29:47-04:00, stenn@whimsy.udel.edu +1 -0 + typo + + scripts/addChangeLogTag@1.2, 2008-08-17 05:29:37-04:00, stenn@whimsy.udel.edu +1 -1 + typo + +ChangeSet@1.1436.15.2, 2008-08-17 03:28:53-04:00, stenn@whimsy.udel.edu +5 -0 + 4.2.4p5 prep + + .point-changed-filelist@1.1.1.1, 2008-08-17 03:27:42-04:00, stenn@whimsy.udel.edu +1 -0 + 4.2.4p5 prep + + NEWS@1.86.1.13, 2008-08-17 03:27:42-04:00, stenn@whimsy.udel.edu +17 -0 + 4.2.4p5 prep + + packageinfo.sh@1.65.23.1, 2008-08-17 03:27:43-04:00, stenn@whimsy.udel.edu +1 -1 + 4.2.4p5 prep + + scripts/addChangeLogTag@1.1, 2008-08-17 03:27:55-04:00, stenn@whimsy.udel.edu +27 -0 + BitKeeper file /deacon/backroom/ntp-stable/scripts/addChangeLogTag + + scripts/addChangeLogTag@1.0, 2008-08-17 03:27:55-04:00, stenn@whimsy.udel.edu +0 -0 + + scripts/genChangeLogTag@1.1, 2008-08-17 03:27:55-04:00, stenn@whimsy.udel.edu +6 -0 + BitKeeper file /deacon/backroom/ntp-stable/scripts/genChangeLogTag + + scripts/genChangeLogTag@1.0, 2008-08-17 03:27:55-04:00, stenn@whimsy.udel.edu +0 -0 + +ChangeSet@1.1436.15.1, 2008-08-16 22:42:08-04:00, stenn@whimsy.udel.edu +2 -0 + [BUG 1051] Month off by one in leap second message written to clockstats + + ChangeLog@1.1.1.42, 2008-08-16 22:41:50-04:00, stenn@whimsy.udel.edu +2 -0 + [BUG 1051] Month off by one in leap second message written to clockstats + + ntpd/refclock_oncore.c@1.60.2.1, 2008-08-16 22:41:50-04:00, stenn@whimsy.udel.edu +1 -1 + [BUG 1051] Month off by one in leap second message written to clockstats + +ChangeSet@1.1756, 2008-08-17 05:57:54+09:00, Amidamaru@yumi.mxiesoft.com +5 -0 + networking.h: + Removed useless prototype filter_ntp + main.c, utilities.c, networking.c, kod_management.c: + Cleaning up + + gsoc_sntp/kod_management.c@1.5, 2008-08-17 05:57:00+09:00, Amidamaru@yumi.mxiesoft.com +2 -4 + Cleaning up + + gsoc_sntp/main.c@1.6, 2008-08-17 05:57:10+09:00, Amidamaru@yumi.mxiesoft.com +14 -12 + Cleaning up + + gsoc_sntp/networking.c@1.12, 2008-08-17 05:57:15+09:00, Amidamaru@yumi.mxiesoft.com +4 -16 + Cleaning up + + gsoc_sntp/networking.h@1.8, 2008-08-17 05:57:19+09:00, Amidamaru@yumi.mxiesoft.com +2 -18 + Removed useless prototype filter_ntp + + gsoc_sntp/utilities.c@1.2, 2008-08-17 05:57:36+09:00, Amidamaru@yumi.mxiesoft.com +1 -1 + Cleaning up + +ChangeSet@1.1755, 2008-08-16 06:41:28+09:00, Amidamaru@yumi.mxiesoft.com +12 -0 + utilities.h: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/ntp-dev/gsoc_sntp/utilities.h + Makefile.am: + Added sntp-opts.c to sources + + minor fixes + main.c: + on_wire, timesetting stuff etc. + log.c, kod_management.c: + Bug fixes + utilities.o: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/ntp-dev/gsoc_sntp/utilities.o + utilities.c: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/ntp-dev/gsoc_sntp/utilities.c + sntp-opts.def: + fixed arg-type stuff + + gsoc_sntp/Makefile.am@1.3, 2008-08-16 06:39:18+09:00, Amidamaru@yumi.mxiesoft.com +6 -2 + Added sntp-opts.c to sources + + minor fixes + + gsoc_sntp/kod_management.c@1.4, 2008-08-16 06:38:49+09:00, Amidamaru@yumi.mxiesoft.com +9 -7 + Bug fixes + + gsoc_sntp/kod_management.h@1.3, 2008-08-16 06:38:58+09:00, Amidamaru@yumi.mxiesoft.com +2 -1 + + gsoc_sntp/log.c@1.4, 2008-08-16 06:38:59+09:00, Amidamaru@yumi.mxiesoft.com +10 -11 + Bug fixes + + gsoc_sntp/log.h@1.3, 2008-08-16 06:39:16+09:00, Amidamaru@yumi.mxiesoft.com +0 -3 + + gsoc_sntp/main.c@1.5, 2008-08-16 06:39:36+09:00, Amidamaru@yumi.mxiesoft.com +180 -56 + on_wire, timesetting stuff etc. + + gsoc_sntp/networking.c@1.11, 2008-08-16 06:39:48+09:00, Amidamaru@yumi.mxiesoft.com +82 -72 + + gsoc_sntp/networking.h@1.7, 2008-08-16 06:39:50+09:00, Amidamaru@yumi.mxiesoft.com +6 -4 + + gsoc_sntp/sntp-opts.def@1.5, 2008-08-16 06:39:54+09:00, Amidamaru@yumi.mxiesoft.com +21 -6 + fixed arg-type stuff + + gsoc_sntp/utilities.c@1.1, 2008-08-16 06:40:44+09:00, Amidamaru@yumi.mxiesoft.com +101 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/ntp-dev/gsoc_sntp/utilities.c + + gsoc_sntp/utilities.c@1.0, 2008-08-16 06:40:44+09:00, Amidamaru@yumi.mxiesoft.com +0 -0 + + gsoc_sntp/utilities.h@1.1, 2008-08-16 06:40:48+09:00, Amidamaru@yumi.mxiesoft.com +21 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/ntp-dev/gsoc_sntp/utilities.h + + gsoc_sntp/utilities.h@1.0, 2008-08-16 06:40:48+09:00, Amidamaru@yumi.mxiesoft.com +0 -0 + + gsoc_sntp/utilities.o@1.1, 2008-08-16 06:41:08+09:00, Amidamaru@yumi.mxiesoft.com +177 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/ntp-dev/gsoc_sntp/utilities.o + + gsoc_sntp/utilities.o@1.0, 2008-08-16 06:41:08+09:00, Amidamaru@yumi.mxiesoft.com +0 -0 + +ChangeSet@1.1436.1.105, 2008-08-10 21:56:17-04:00, clemens@pogo.udel.edu +1 -0 + BUG[1052] Minor reordering of previous patch to make it more robust. + + ntpd/refclock_oncore.c@1.60.1.6, 2008-08-10 21:56:15-04:00, clemens@pogo.udel.edu +57 -58 + BUG[1052] Minor reordering of previous patch to make it more robust. + +ChangeSet@1.1436.1.104, 2008-08-10 18:31:13-04:00, clemens@pogo.udel.edu +1 -0 + [BUG 1052] Modify ONCORE driver for linuxPPS which uses a line discipline for the + PPS source. + + ntpd/refclock_oncore.c@1.60.1.5, 2008-08-10 18:31:11-04:00, clemens@pogo.udel.edu +21 -6 + [BUG 1052] Modify ONCORE driver for linuxPPS which uses a line discipline for the + PPS source. + +ChangeSet@1.1436.1.103, 2008-08-10 18:21:32-04:00, clemens@pogo.udel.edu +1 -0 + Remove unneeded variable. + + ntpd/refclock_oncore.c@1.60.1.4, 2008-08-10 18:21:30-04:00, clemens@pogo.udel.edu +2 -3 + Remove unneeded variable. + +ChangeSet@1.1436.1.102, 2008-08-10 18:18:56-04:00, clemens@pogo.udel.edu +1 -0 + [BUG 1051] Month off by one in leap second message written to clockstats file, fixed. + + ntpd/refclock_oncore.c@1.60.1.3, 2008-08-10 18:18:54-04:00, clemens@pogo.udel.edu +1 -1 + [BUG 1051] Month off by one in leap second message written to clockstats file, fixed. + +ChangeSet@1.1735.1.23, 2008-08-10 09:45:36-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P123 + TAG: NTP_4_2_5P123 + + ntpd/ntpd-opts.c@1.115, 2008-08-10 09:45:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P123 + + ntpd/ntpd-opts.h@1.115, 2008-08-10 09:45:11-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P123 + + ntpd/ntpd-opts.texi@1.114, 2008-08-10 09:45:11-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P123 + + ntpd/ntpd.1@1.114, 2008-08-10 09:45:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P123 + + ntpdc/ntpdc-opts.c@1.111, 2008-08-10 09:45:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P123 + + ntpdc/ntpdc-opts.h@1.111, 2008-08-10 09:45:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P123 + + ntpdc/ntpdc-opts.texi@1.110, 2008-08-10 09:45:15-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P123 + + ntpdc/ntpdc.1@1.110, 2008-08-10 09:45:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P123 + + ntpq/ntpq-opts.c@1.111, 2008-08-10 09:45:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P123 + + ntpq/ntpq-opts.h@1.111, 2008-08-10 09:45:19-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P123 + + ntpq/ntpq-opts.texi@1.110, 2008-08-10 09:45:20-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P123 + + ntpq/ntpq.1@1.110, 2008-08-10 09:45:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P123 + + packageinfo.sh@1.126, 2008-08-10 09:45:22-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P123 + + sntp/sntp-opts.c@1.111, 2008-08-10 09:45:23-04:00, stenn@whimsy.udel.edu +4 -5 + NTP_4_2_5P123 + + sntp/sntp-opts.h@1.111, 2008-08-10 09:45:25-04:00, stenn@whimsy.udel.edu +5 -6 + NTP_4_2_5P123 + + sntp/sntp-opts.texi@1.110, 2008-08-10 09:45:25-04:00, stenn@whimsy.udel.edu +2 -3 + NTP_4_2_5P123 + + sntp/sntp.1@1.110, 2008-08-10 09:45:26-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P123 + + util/ntp-keygen-opts.c@1.114, 2008-08-10 09:45:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P123 + + util/ntp-keygen-opts.h@1.114, 2008-08-10 09:45:28-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P123 + + util/ntp-keygen-opts.texi@1.113, 2008-08-10 09:45:29-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P123 + + util/ntp-keygen.1@1.113, 2008-08-10 09:45:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P123 + +ChangeSet@1.1436.1.101, 2008-08-10 07:44:31-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_4P5_RC2 + TAG: NTP_4_2_4P5_RC2 + + ntpd/ntpd-opts.c@1.50.15.1, 2008-08-10 07:44:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5_RC2 + + ntpd/ntpd-opts.h@1.50.15.1, 2008-08-10 07:44:09-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P5_RC2 + + ntpd/ntpd-opts.texi@1.49.15.1, 2008-08-10 07:44:10-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5_RC2 + + ntpd/ntpd.1@1.48.15.1, 2008-08-10 07:44:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5_RC2 + + ntpd/ntpdsim-opts.c@1.50.15.1, 2008-08-10 07:44:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5_RC2 + + ntpd/ntpdsim-opts.h@1.50.15.1, 2008-08-10 07:44:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P5_RC2 + + ntpd/ntpdsim-opts.texi@1.48.15.1, 2008-08-10 07:44:12-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5_RC2 + + ntpd/ntpdsim.1@1.48.15.1, 2008-08-10 07:44:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5_RC2 + + ntpdc/ntpdc-opts.c@1.50.15.1, 2008-08-10 07:44:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5_RC2 + + ntpdc/ntpdc-opts.h@1.50.15.1, 2008-08-10 07:44:15-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P5_RC2 + + ntpdc/ntpdc-opts.texi@1.48.15.1, 2008-08-10 07:44:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5_RC2 + + ntpdc/ntpdc.1@1.48.15.1, 2008-08-10 07:44:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5_RC2 + + ntpq/ntpq-opts.c@1.52.15.1, 2008-08-10 07:44:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5_RC2 + + ntpq/ntpq-opts.h@1.52.15.1, 2008-08-10 07:44:18-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P5_RC2 + + ntpq/ntpq-opts.texi@1.49.15.1, 2008-08-10 07:44:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5_RC2 + + ntpq/ntpq.1@1.48.15.1, 2008-08-10 07:44:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5_RC2 + + packageinfo.sh@1.65.22.1, 2008-08-10 07:44:20-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5_RC2 + + sntp/sntp-opts.c@1.49.15.1, 2008-08-10 07:44:22-04:00, stenn@whimsy.udel.edu +4 -5 + NTP_4_2_4P5_RC2 + + sntp/sntp-opts.h@1.49.15.1, 2008-08-10 07:44:23-04:00, stenn@whimsy.udel.edu +5 -6 + NTP_4_2_4P5_RC2 + + sntp/sntp-opts.texi@1.46.15.1, 2008-08-10 07:44:23-04:00, stenn@whimsy.udel.edu +2 -3 + NTP_4_2_4P5_RC2 + + sntp/sntp.1@1.49.15.1, 2008-08-10 07:44:24-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P5_RC2 + + util/ntp-keygen-opts.c@1.49.15.1, 2008-08-10 07:44:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5_RC2 + + util/ntp-keygen-opts.h@1.49.15.1, 2008-08-10 07:44:25-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P5_RC2 + + util/ntp-keygen-opts.texi@1.47.15.1, 2008-08-10 07:44:27-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5_RC2 + + util/ntp-keygen.1@1.47.15.1, 2008-08-10 07:44:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5_RC2 + +ChangeSet@1.1735.1.22, 2008-08-10 03:11:51-04:00, stenn@whimsy.udel.edu +4 -0 + [Bug 861] leap info was not being transmitted + + ChangeLog@1.205, 2008-08-10 03:09:08-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 861] leap info was not being transmitted + + ntpd/ntp_crypto.c@1.123, 2008-08-10 03:09:17-04:00, stenn@whimsy.udel.edu +2 -2 + [Bug 861] leap info was not being transmitted + + ntpd/ntp_timer.c@1.48, 2008-08-10 03:09:22-04:00, stenn@whimsy.udel.edu +1 -1 + [Bug 861] leap info was not being transmitted + + ntpd/refclock_local.c@1.18, 2008-08-10 03:09:32-04:00, stenn@whimsy.udel.edu +4 -1 + [Bug 861] leap info was not being transmitted + +ChangeSet@1.1436.14.1, 2008-08-10 02:22:22-04:00, stenn@whimsy.udel.edu +1 -0 + triggert needs to handle rooted RESYNC paths now + + BitKeeper/triggers/triggert@1.4.1.1, 2008-08-10 02:22:11-04:00, stenn@whimsy.udel.edu +3 -2 + triggert needs to handle rooted RESYNC paths now + +ChangeSet@1.1735.1.20, 2008-08-09 20:56:32-04:00, stenn@whimsy.udel.edu +1 -0 + cleanup + + ChangeLog@1.204, 2008-08-09 20:56:23-04:00, stenn@whimsy.udel.edu +4 -10 + cleanup + +ChangeSet@1.1436.1.98, 2008-08-09 20:05:06-04:00, stenn@whimsy.udel.edu +2 -0 + AutoGen'd files must be writable + + sntp/Makefile.am@1.21.1.2, 2008-08-09 20:04:56-04:00, stenn@whimsy.udel.edu +2 -2 + AutoGen'd files must be writable + + sntp/sntp-opts.menu@1.2.1.1, 2008-08-09 20:04:10-04:00, stenn@whimsy.udel.edu +0 -0 + Change mode to -rw-rw-r-- + +ChangeSet@1.1754, 2008-08-09 07:28:37+09:00, Amidamaru@yumi.mxiesoft.com +4 -0 + main.c: + bug fixes + networking.c, kod_management.c: + Bug fixes + + gsoc_sntp/kod_management.c@1.3, 2008-08-09 07:27:47+09:00, Amidamaru@yumi.mxiesoft.com +62 -18 + Bug fixes + + gsoc_sntp/log.c@1.3, 2008-08-09 07:27:55+09:00, Amidamaru@yumi.mxiesoft.com +27 -6 + + gsoc_sntp/main.c@1.4, 2008-08-09 07:28:04+09:00, Amidamaru@yumi.mxiesoft.com +124 -27 + bug fixes + + gsoc_sntp/networking.c@1.10, 2008-08-09 07:28:10+09:00, Amidamaru@yumi.mxiesoft.com +115 -21 + Bug fixes + +ChangeSet@1.1436.13.1, 2008-08-07 20:44:31+02:00, burnicki@pogo.udel.edu +3 -0 + [Bug 450] Windows only: Under original Windows NT we must not discard the + wildcard socket to workaround a bug in NT's getsockname(). + + ChangeLog@1.1.10.1, 2008-08-07 20:44:30+02:00, burnicki@pogo.udel.edu +2 -0 + [Bug 450] Windows only: Under original Windows NT we must not discard the + wildcard socket to workaround a bug in NT's getsockname(). + + ntpd/ntp_peer.c@1.97.2.1, 2008-08-07 20:44:30+02:00, burnicki@pogo.udel.edu +10 -2 + [Bug 450] Windows only: Under original Windows NT we must not discard the + wildcard socket to workaround a bug in NT's getsockname(). + + ports/winnt/ntpd/ntservice.c@1.9.1.2, 2008-08-07 20:44:30+02:00, burnicki@pogo.udel.edu +8 -1 + [Bug 450] Windows only: Under original Windows NT we must not discard the + wildcard socket to workaround a bug in NT's getsockname(). + +ChangeSet@1.1753, 2008-08-06 17:05:34+09:00, Amidamaru@yumi.mxiesoft.com +1 -0 + networking.c: + Fixed resolver and some minor stuff + + gsoc_sntp/networking.c@1.9, 2008-08-06 17:05:12+09:00, Amidamaru@yumi.mxiesoft.com +70 -22 + Fixed resolver and some minor stuff + +ChangeSet@1.1735.1.15, 2008-08-05 19:56:11-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P122 + TAG: NTP_4_2_5P122 + + ntpd/ntpd-opts.c@1.114, 2008-08-05 19:55:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P122 + + ntpd/ntpd-opts.h@1.114, 2008-08-05 19:55:54-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P122 + + ntpd/ntpd-opts.texi@1.113, 2008-08-05 19:55:55-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P122 + + ntpd/ntpd.1@1.113, 2008-08-05 19:55:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P122 + + ntpdc/ntpdc-opts.c@1.110, 2008-08-05 19:55:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P122 + + ntpdc/ntpdc-opts.h@1.110, 2008-08-05 19:55:57-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P122 + + ntpdc/ntpdc-opts.texi@1.109, 2008-08-05 19:55:59-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P122 + + ntpdc/ntpdc.1@1.109, 2008-08-05 19:56:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P122 + + ntpq/ntpq-opts.c@1.110, 2008-08-05 19:56:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P122 + + ntpq/ntpq-opts.h@1.110, 2008-08-05 19:56:00-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P122 + + ntpq/ntpq-opts.texi@1.109, 2008-08-05 19:56:01-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P122 + + ntpq/ntpq.1@1.109, 2008-08-05 19:56:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P122 + + packageinfo.sh@1.125, 2008-08-05 19:56:02-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P122 + + sntp/sntp-opts.c@1.110, 2008-08-05 19:56:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P122 + + sntp/sntp-opts.h@1.110, 2008-08-05 19:56:03-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P122 + + sntp/sntp-opts.texi@1.109, 2008-08-05 19:56:04-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P122 + + sntp/sntp.1@1.109, 2008-08-05 19:56:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P122 + + util/ntp-keygen-opts.c@1.113, 2008-08-05 19:56:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P122 + + util/ntp-keygen-opts.h@1.113, 2008-08-05 19:56:06-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P122 + + util/ntp-keygen-opts.texi@1.112, 2008-08-05 19:56:07-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P122 + + util/ntp-keygen.1@1.112, 2008-08-05 19:56:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P122 + +ChangeSet@1.1735.1.14, 2008-08-05 06:07:25-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1046] refnumtoa.c is using the wrong header file + + ChangeLog@1.199, 2008-08-05 06:06:33-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1046] refnumtoa.c is using the wrong header file + + libntp/refnumtoa.c@1.5, 2008-08-05 06:06:34-04:00, stenn@whimsy.udel.edu +1 -1 + [Bug 1046] refnumtoa.c is using the wrong header file + +ChangeSet@1.1735.1.13, 2008-08-05 05:00:05-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1047] enable/disable options processing fix + + ChangeLog@1.198, 2008-08-05 04:59:49-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1047] enable/disable options processing fix + + ntpd/ntp_config.c@1.180, 2008-08-05 04:59:50-04:00, stenn@whimsy.udel.edu +12 -15 + [Bug 1047] enable/disable options processing fix + +ChangeSet@1.1436.12.2, 2008-08-05 09:56:08+02:00, burnicki@pogo.udel.edu +1 -0 + Removed Windows-specific debug code which has been added in ntp-dev and fails to compile in ntp-stable. + + ports/winnt/ntpd/ntp_iocompletionport.c@1.21.1.5, 2008-08-05 09:56:08+02:00, burnicki@pogo.udel.edu +0 -8 + Removed Windows-specific debug code which has been added in ntp-dev and fails to compile in ntp-stable. + +ChangeSet@1.1436.12.1, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +10 -0 + [Bug 841] Obsolete the "dynamic" keyword and make deferred binding + to local interfaces the default. + Emit a warning if that keyword is used for configuration. + + ChangeLog@1.1.9.1, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +3 -0 + [Bug 841] Obsolete the "dynamic" keyword and make deferred binding + to local interfaces the default. + Emit a warning if that keyword is used for configuration. + + html/confopt.html@1.35.1.1, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +0 -2 + Bug 841: Obsolete the "dynamic" keyword. + + html/ntpdc.html@1.26.1.1, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +2 -3 + Bug 841: Obsolete the "dynamic" keyword. + + include/ntp.h@1.128.1.1, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +0 -1 + Bug 841: Obsolete the "dynamic" keyword. + + include/ntp_request.h@1.30.1.1, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +0 -1 + Bug 841: Obsolete the "dynamic" keyword. + + ntpd/ntp_config.c@1.141.1.3, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +4 -2 + [Bug 841] Obsolete the "dynamic" keyword and make deferred binding + to local interfaces the default. + Emit a warning if that keyword is used for configuration. + + ntpd/ntp_intres.c@1.48.1.4, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +1 -3 + Bug 841: Obsolete the "dynamic" keyword. + + ntpd/ntp_peer.c@1.97.1.3, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +5 -25 + [Bug 841] Obsolete the "dynamic" keyword and make deferred binding + to local interfaces the default. + + ntpd/ntp_request.c@1.65.1.1, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +1 -3 + Bug 841: Obsolete the "dynamic" keyword. + + ntpdc/ntpdc_ops.c@1.46.1.4, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +3 -3 + [Bug 841] Obsolete the "dynamic" keyword and make deferred binding + to local interfaces the default. + +ChangeSet@1.1749.1.2, 2008-08-02 07:02:15-04:00, stenn@pogo.udel.edu +1 -0 + typo + + gsoc_sntp/main.c@1.3, 2008-08-02 07:02:00-04:00, stenn@pogo.udel.edu +2 -1 + typo + +ChangeSet@1.1749.1.1, 2008-07-29 19:04:34-04:00, stenn@pogo.udel.edu +4 -0 + cleanups + + gsoc_sntp/configure.ac@1.3, 2008-07-29 19:04:25-04:00, stenn@pogo.udel.edu +1 -1 + cleanups + + gsoc_sntp/header.h@1.2, 2008-07-29 19:04:26-04:00, stenn@pogo.udel.edu +0 -1 + cleanups + + gsoc_sntp/main.c@1.2, 2008-07-29 19:04:26-04:00, stenn@pogo.udel.edu +9 -4 + cleanups + + gsoc_sntp/networking.h@1.6, 2008-07-29 19:04:26-04:00, stenn@pogo.udel.edu +2 -1 + cleanups + +ChangeSet@1.1747.1.1, 2008-07-28 04:38:59+09:00, Amidamaru@yumi.mxiesoft.com +1 -0 + sntp-opts.def: + removed unnecessary verbosity flags + + gsoc_sntp/sntp-opts.def@1.2.1.1, 2008-07-28 04:38:18+09:00, Amidamaru@yumi.mxiesoft.com +1 -15 + removed unnecessary verbosity flags + +ChangeSet@1.1749, 2008-07-27 15:10:03-04:00, stenn@pogo.udel.edu +1 -0 + Use ntp_machine.h + + gsoc_sntp/data_formats.h@1.4, 2008-07-27 15:09:56-04:00, stenn@pogo.udel.edu +1 -0 + Use ntp_machine.h + +ChangeSet@1.1748, 2008-07-27 15:09:23-04:00, stenn@pogo.udel.edu +2 -0 + Fix the "kod" keyword + + gsoc_sntp/:fetch-stubs@1.3, 2008-07-27 15:09:13-04:00, stenn@pogo.udel.edu +1 -1 + Fix the "kod" keyword + + gsoc_sntp/sntp-opts.def@1.3, 2008-07-27 15:09:13-04:00, stenn@pogo.udel.edu +2 -3 + Fix the "kod" keyword + +ChangeSet@1.1735.1.12, 2008-07-24 15:28:20-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P121 + TAG: NTP_4_2_5P121 + + ntpd/ntpd-opts.c@1.113, 2008-07-24 15:28:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P121 + + ntpd/ntpd-opts.h@1.113, 2008-07-24 15:28:03-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P121 + + ntpd/ntpd-opts.texi@1.112, 2008-07-24 15:28:03-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P121 + + ntpd/ntpd.1@1.112, 2008-07-24 15:28:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P121 + + ntpdc/ntpdc-opts.c@1.109, 2008-07-24 15:28:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P121 + + ntpdc/ntpdc-opts.h@1.109, 2008-07-24 15:28:05-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P121 + + ntpdc/ntpdc-opts.texi@1.108, 2008-07-24 15:28:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P121 + + ntpdc/ntpdc.1@1.108, 2008-07-24 15:28:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P121 + + ntpq/ntpq-opts.c@1.109, 2008-07-24 15:28:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P121 + + ntpq/ntpq-opts.h@1.109, 2008-07-24 15:28:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P121 + + ntpq/ntpq-opts.texi@1.108, 2008-07-24 15:28:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P121 + + ntpq/ntpq.1@1.108, 2008-07-24 15:28:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P121 + + packageinfo.sh@1.124, 2008-07-24 15:28:10-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P121 + + sntp/sntp-opts.c@1.109, 2008-07-24 15:28:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P121 + + sntp/sntp-opts.h@1.109, 2008-07-24 15:28:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P121 + + sntp/sntp-opts.texi@1.108, 2008-07-24 15:28:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P121 + + sntp/sntp.1@1.108, 2008-07-24 15:28:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P121 + + util/ntp-keygen-opts.c@1.112, 2008-07-24 15:28:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P121 + + util/ntp-keygen-opts.h@1.112, 2008-07-24 15:28:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P121 + + util/ntp-keygen-opts.texi@1.111, 2008-07-24 15:28:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P121 + + util/ntp-keygen.1@1.111, 2008-07-24 15:28:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P121 + +ChangeSet@1.1746, 2008-07-24 17:07:55+09:00, Amidamaru@yumi.mxiesoft.com +1 -0 + networking.c: + Fixing the mess + + gsoc_sntp/networking.c@1.7, 2008-07-24 17:07:37+09:00, Amidamaru@yumi.mxiesoft.com +3 -1 + Fixing the mess + + gsoc_sntp/networking.c@1.6, 2008-07-24 16:55:01+09:00, Amidamaru@yumi.mxiesoft.com +0 -2 + +ChangeSet@1.1745, 2008-07-24 16:53:33+09:00, Amidamaru@yumi.mxiesoft.com +1 -0 + networking.c: + redo include + + gsoc_sntp/networking.c@1.5, 2008-07-24 16:53:12+09:00, Amidamaru@yumi.mxiesoft.com +2 -0 + redo include + +ChangeSet@1.1744, 2008-07-24 16:49:34+09:00, Amidamaru@yumi.mxiesoft.com +1 -0 + fixed includes + + gsoc_sntp/networking.c@1.4, 2008-07-24 16:46:58+09:00, Amidamaru@yumi.mxiesoft.com +2 -2 + +ChangeSet@1.1739.1.8, 2008-07-24 03:47:48-04:00, stenn@pogo.udel.edu +2 -0 + header cleanup + + gsoc_sntp/networking.c@1.1.1.3, 2008-07-24 03:47:43-04:00, stenn@pogo.udel.edu +2 -1 + header cleanup + + gsoc_sntp/networking.h@1.1.1.3, 2008-07-24 03:47:43-04:00, stenn@pogo.udel.edu +3 -1 + header cleanup + +ChangeSet@1.1739.1.7, 2008-07-24 03:45:53-04:00, stenn@pogo.udel.edu +1 -0 + reorder headers + + gsoc_sntp/data_formats.h@1.3, 2008-07-24 03:45:48-04:00, stenn@pogo.udel.edu +1 -1 + reorder headers + +ChangeSet@1.1739.1.6, 2008-07-24 03:44:24-04:00, stenn@pogo.udel.edu +1 -0 + hack ISC_PLATFORM_HAVEIPV6 + + gsoc_sntp/configure.ac@1.2, 2008-07-24 03:44:17-04:00, stenn@pogo.udel.edu +1 -0 + hack ISC_PLATFORM_HAVEIPV6 + +ChangeSet@1.1739.1.5, 2008-07-24 03:23:31-04:00, stenn@pogo.udel.edu +1 -0 + header cleanup + + gsoc_sntp/networking.c@1.1.1.2, 2008-07-24 03:23:25-04:00, stenn@pogo.udel.edu +0 -1 + header cleanup + +ChangeSet@1.1739.1.4, 2008-07-24 03:01:29-04:00, stenn@pogo.udel.edu +3 -0 + hacks + + gsoc_sntp/data_formats.h@1.2, 2008-07-24 03:00:51-04:00, stenn@pogo.udel.edu +0 -3 + hacks + + gsoc_sntp/networking.c@1.1.1.1, 2008-07-24 03:00:51-04:00, stenn@pogo.udel.edu +1 -1 + hacks + + gsoc_sntp/networking.h@1.1.1.2, 2008-07-24 03:00:52-04:00, stenn@pogo.udel.edu +8 -8 + hacks + +ChangeSet@1.1739.1.3, 2008-07-24 02:06:52-04:00, stenn@pogo.udel.edu +1 -0 + cleanup + + gsoc_sntp/networking.h@1.1.1.1, 2008-07-24 02:06:44-04:00, stenn@pogo.udel.edu +2 -5 + cleanup + +ChangeSet@1.1735.1.11, 2008-07-24 02:26:46+00:00, stenn@poog.il.thewrittenword.com +6 -0 + header file cleanup + + ChangeLog@1.197, 2008-07-24 02:26:36+00:00, stenn@poog.il.thewrittenword.com +1 -0 + header file cleanup + + include/Makefile.am@1.30, 2008-07-24 02:25:18+00:00, stenn@poog.il.thewrittenword.com +1 -0 + Added ntp_net.h + + include/ntp.h@1.147, 2008-07-24 02:24:56+00:00, stenn@poog.il.thewrittenword.com +4 -2 + Header cleanup + + include/ntp_fp.h@1.14, 2008-07-24 01:37:37+00:00, stenn@poog.il.thewrittenword.com +0 -6 + ntp_fp.h should have *never* been how we pulled in network stuff + + include/ntp_net.h@1.1, 2008-07-24 01:32:09+00:00, stenn@poog.il.thewrittenword.com +14 -0 + BitKeeper file /home/stenn/ntp-dev/include/ntp_net.h + + include/ntp_net.h@1.0, 2008-07-24 01:32:09+00:00, stenn@poog.il.thewrittenword.com +0 -0 + + include/recvbuff.h@1.15, 2008-07-24 01:37:04+00:00, stenn@poog.il.thewrittenword.com +0 -1 + Header cleanup + +ChangeSet@1.1739.1.1, 2008-07-22 16:12:19-04:00, stenn@pogo.udel.edu +2 -0 + build infrastructure updates + + gsoc_sntp/:fetch-stubs@1.2, 2008-07-22 16:11:53-04:00, stenn@pogo.udel.edu +7 -0 + updates + + gsoc_sntp/configure.ac@1.1, 2008-07-22 16:07:27-04:00, stenn@pogo.udel.edu +89 -0 + BitKeeper file /pogo/users/stenn/ntp-dev-kuehn/gsoc_sntp/configure.ac + + gsoc_sntp/configure.ac@1.0, 2008-07-22 16:07:27-04:00, stenn@pogo.udel.edu +0 -0 + +ChangeSet@1.1737.1.1, 2008-07-23 03:52:14+09:00, Amidamaru@yumi.mxiesoft.com +8 -0 + log.h, log.c: + Changed name of debug output function to avoid name collision with opt flag variable + kod_management.c: + Changed from fgets to fscanf (easier data extraction) + + gsoc_sntp/Makefile@1.1.1.1, 2008-07-23 03:50:12+09:00, Amidamaru@yumi.mxiesoft.com +16 -19 + + gsoc_sntp/Makefile.in@1.1.1.1, 2008-07-23 03:50:22+09:00, Amidamaru@yumi.mxiesoft.com +3 -6 + + gsoc_sntp/kod_management.c@1.2, 2008-07-23 03:50:23+09:00, Amidamaru@yumi.mxiesoft.com +22 -57 + Changed from fgets to fscanf (easier data extraction) + + gsoc_sntp/kod_management.h@1.2, 2008-07-23 03:51:08+09:00, Amidamaru@yumi.mxiesoft.com +1 -1 + + gsoc_sntp/log.c@1.2, 2008-07-23 03:51:20+09:00, Amidamaru@yumi.mxiesoft.com +1 -1 + Changed name of debug output function to avoid name collision with opt flag variable + + gsoc_sntp/log.h@1.2, 2008-07-23 03:51:51+09:00, Amidamaru@yumi.mxiesoft.com +1 -1 + Changed name of debug output function to avoid name collision with opt flag variable + + gsoc_sntp/networking.c@1.2, 2008-07-23 03:52:00+09:00, Amidamaru@yumi.mxiesoft.com +20 -11 + + gsoc_sntp/networking.h@1.2, 2008-07-23 03:52:04+09:00, Amidamaru@yumi.mxiesoft.com +4 -4 + +ChangeSet@1.1739, 2008-07-22 14:38:08-04:00, stenn@pogo.udel.edu +1 -0 + added :fetch-stubs + + gsoc_sntp/:fetch-stubs@1.1, 2008-07-22 14:37:23-04:00, stenn@pogo.udel.edu +13 -0 + BitKeeper file /pogo/users/stenn/ntp-dev-kuehn/gsoc_sntp/:fetch-stubs + + gsoc_sntp/:fetch-stubs@1.0, 2008-07-22 14:37:23-04:00, stenn@pogo.udel.edu +0 -0 + +ChangeSet@1.1738, 2008-07-22 14:29:55-04:00, stenn@pogo.udel.edu +46 -0 + sntp fixes + + BitKeeper/deleted/.del-Makefile@1.2, 2008-07-13 17:43:07-04:00, stenn@pogo.udel.edu +0 -0 + Delete: gsoc_sntp/Makefile + + BitKeeper/deleted/.del-Makefile.in@1.2, 2008-07-13 17:43:07-04:00, stenn@pogo.udel.edu +0 -0 + Delete: gsoc_sntp/Makefile.in + + Makefile.am@1.77, 2008-07-22 14:25:53-04:00, stenn@pogo.udel.edu +2 -0 + Add gsoc_sntp to the build + + gsoc_sntp/Makefile.am@1.2, 2008-07-22 14:25:19-04:00, stenn@pogo.udel.edu +15 -18 + autogen stuff + + gsoc_sntp/libopts/COPYING.lgpl@1.2, 2008-07-13 22:41:55-04:00, stenn@pogo.udel.edu +0 -0 + bk cp COPYING.lgpl ../gsoc_sntp/libopts/COPYING.lgpl + + gsoc_sntp/libopts/COPYING.lgpl@1.1, 2007-05-19 00:04:01-04:00, stenn@whimsy.udel.edu +502 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/COPYING.lgpl + + gsoc_sntp/libopts/COPYING.lgpl@1.0, 2007-05-19 00:04:01-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/COPYING.mbsd@1.2, 2008-07-13 22:41:55-04:00, stenn@pogo.udel.edu +0 -0 + bk cp COPYING.mbsd ../gsoc_sntp/libopts/COPYING.mbsd + + gsoc_sntp/libopts/COPYING.mbsd@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +26 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/COPYING.mbsd + + gsoc_sntp/libopts/COPYING.mbsd@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/MakeDefs.inc@1.2, 2008-07-13 22:41:55-04:00, stenn@pogo.udel.edu +0 -0 + bk cp MakeDefs.inc ../gsoc_sntp/libopts/MakeDefs.inc + + gsoc_sntp/libopts/MakeDefs.inc@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/MakeDefs.inc + + gsoc_sntp/libopts/MakeDefs.inc@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/Makefile.am@1.2, 2008-07-13 22:41:56-04:00, stenn@pogo.udel.edu +0 -0 + bk cp Makefile.am ../gsoc_sntp/libopts/Makefile.am + + gsoc_sntp/libopts/Makefile.am@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +24 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/Makefile.am + + gsoc_sntp/libopts/Makefile.am@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/README@1.2, 2008-07-13 22:41:56-04:00, stenn@pogo.udel.edu +0 -0 + bk cp README ../gsoc_sntp/libopts/README + + gsoc_sntp/libopts/README@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/README + + gsoc_sntp/libopts/README@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/autoopts.c@1.2, 2008-07-13 22:41:57-04:00, stenn@pogo.udel.edu +0 -0 + bk cp autoopts.c ../gsoc_sntp/libopts/autoopts.c + + gsoc_sntp/libopts/autoopts.c@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +1120 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts.c + + gsoc_sntp/libopts/autoopts.c@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/autoopts.h@1.2, 2008-07-13 22:41:57-04:00, stenn@pogo.udel.edu +0 -0 + bk cp autoopts.h ../gsoc_sntp/libopts/autoopts.h + + gsoc_sntp/libopts/autoopts.h@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +387 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts.h + + gsoc_sntp/libopts/autoopts.h@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/autoopts/options.h@1.2, 2008-07-13 22:41:56-04:00, stenn@pogo.udel.edu +0 -0 + bk cp autoopts/options.h ../gsoc_sntp/libopts/autoopts/options.h + + gsoc_sntp/libopts/autoopts/options.h@1.1, 2007-05-19 00:04:14-04:00, stenn@whimsy.udel.edu +977 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts/options.h + + gsoc_sntp/libopts/autoopts/options.h@1.0, 2007-05-19 00:04:14-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/autoopts/usage-txt.h@1.2, 2008-07-13 22:41:57-04:00, stenn@pogo.udel.edu +0 -0 + bk cp autoopts/usage-txt.h ../gsoc_sntp/libopts/autoopts/usage-txt.h + + gsoc_sntp/libopts/autoopts/usage-txt.h@1.1, 2007-05-19 00:04:14-04:00, stenn@whimsy.udel.edu +355 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts/usage-txt.h + + gsoc_sntp/libopts/autoopts/usage-txt.h@1.0, 2007-05-19 00:04:14-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/boolean.c@1.2, 2008-07-13 22:41:58-04:00, stenn@pogo.udel.edu +0 -0 + bk cp boolean.c ../gsoc_sntp/libopts/boolean.c + + gsoc_sntp/libopts/boolean.c@1.1, 2007-05-19 00:04:03-04:00, stenn@whimsy.udel.edu +106 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/boolean.c + + gsoc_sntp/libopts/boolean.c@1.0, 2007-05-19 00:04:03-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/compat/compat.h@1.2, 2008-07-13 22:41:58-04:00, stenn@pogo.udel.edu +0 -0 + bk cp compat/compat.h ../gsoc_sntp/libopts/compat/compat.h + + gsoc_sntp/libopts/compat/compat.h@1.1, 2007-05-19 00:04:15-04:00, stenn@whimsy.udel.edu +319 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/compat.h + + gsoc_sntp/libopts/compat/compat.h@1.0, 2007-05-19 00:04:15-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/compat/pathfind.c@1.2, 2008-07-13 22:41:59-04:00, stenn@pogo.udel.edu +0 -0 + bk cp compat/pathfind.c ../gsoc_sntp/libopts/compat/pathfind.c + + gsoc_sntp/libopts/compat/pathfind.c@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +339 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/pathfind.c + + gsoc_sntp/libopts/compat/pathfind.c@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/compat/snprintf.c@1.2, 2008-07-13 22:41:59-04:00, stenn@pogo.udel.edu +0 -0 + bk cp compat/snprintf.c ../gsoc_sntp/libopts/compat/snprintf.c + + gsoc_sntp/libopts/compat/snprintf.c@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/snprintf.c + + gsoc_sntp/libopts/compat/snprintf.c@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/compat/strchr.c@1.2, 2008-07-13 22:41:59-04:00, stenn@pogo.udel.edu +0 -0 + bk cp compat/strchr.c ../gsoc_sntp/libopts/compat/strchr.c + + gsoc_sntp/libopts/compat/strchr.c@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/strchr.c + + gsoc_sntp/libopts/compat/strchr.c@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/compat/strdup.c@1.2, 2008-07-13 22:41:58-04:00, stenn@pogo.udel.edu +0 -0 + bk cp compat/strdup.c ../gsoc_sntp/libopts/compat/strdup.c + + gsoc_sntp/libopts/compat/strdup.c@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +19 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/strdup.c + + gsoc_sntp/libopts/compat/strdup.c@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/compat/windows-config.h@1.2, 2008-07-13 22:41:58-04:00, stenn@pogo.udel.edu +0 -0 + bk cp compat/windows-config.h ../gsoc_sntp/libopts/compat/windows-config.h + + gsoc_sntp/libopts/compat/windows-config.h@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +130 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/windows-config.h + + gsoc_sntp/libopts/compat/windows-config.h@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/configfile.c@1.2, 2008-07-13 22:42:00-04:00, stenn@pogo.udel.edu +0 -0 + bk cp configfile.c ../gsoc_sntp/libopts/configfile.c + + gsoc_sntp/libopts/configfile.c@1.1, 2007-05-19 00:04:03-04:00, stenn@whimsy.udel.edu +1290 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/configfile.c + + gsoc_sntp/libopts/configfile.c@1.0, 2007-05-19 00:04:03-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/cook.c@1.2, 2008-07-13 22:42:00-04:00, stenn@pogo.udel.edu +0 -0 + bk cp cook.c ../gsoc_sntp/libopts/cook.c + + gsoc_sntp/libopts/cook.c@1.1, 2007-05-19 00:04:04-04:00, stenn@whimsy.udel.edu +354 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/cook.c + + gsoc_sntp/libopts/cook.c@1.0, 2007-05-19 00:04:04-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/enumeration.c@1.2, 2008-07-13 22:42:00-04:00, stenn@pogo.udel.edu +0 -0 + bk cp enumeration.c ../gsoc_sntp/libopts/enumeration.c + + gsoc_sntp/libopts/enumeration.c@1.1, 2007-05-19 00:04:05-04:00, stenn@whimsy.udel.edu +498 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/enumeration.c + + gsoc_sntp/libopts/enumeration.c@1.0, 2007-05-19 00:04:05-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/environment.c@1.2, 2008-07-13 22:42:00-04:00, stenn@pogo.udel.edu +0 -0 + bk cp environment.c ../gsoc_sntp/libopts/environment.c + + gsoc_sntp/libopts/environment.c@1.1, 2007-05-19 00:04:05-04:00, stenn@whimsy.udel.edu +279 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/environment.c + + gsoc_sntp/libopts/environment.c@1.0, 2007-05-19 00:04:05-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/genshell.c@1.2, 2008-07-13 22:42:01-04:00, stenn@pogo.udel.edu +0 -0 + bk cp genshell.c ../gsoc_sntp/libopts/genshell.c + + gsoc_sntp/libopts/genshell.c@1.1, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +354 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/genshell.c + + gsoc_sntp/libopts/genshell.c@1.0, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/genshell.h@1.2, 2008-07-13 22:42:01-04:00, stenn@pogo.udel.edu +0 -0 + bk cp genshell.h ../gsoc_sntp/libopts/genshell.h + + gsoc_sntp/libopts/genshell.h@1.1, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +149 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/genshell.h + + gsoc_sntp/libopts/genshell.h@1.0, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/libopts.c@1.2, 2008-07-13 22:42:01-04:00, stenn@pogo.udel.edu +0 -0 + bk cp libopts.c ../gsoc_sntp/libopts/libopts.c + + gsoc_sntp/libopts/libopts.c@1.1, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +30 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/libopts.c + + gsoc_sntp/libopts/libopts.c@1.0, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/load.c@1.2, 2008-07-13 22:42:02-04:00, stenn@pogo.udel.edu +0 -0 + bk cp load.c ../gsoc_sntp/libopts/load.c + + gsoc_sntp/libopts/load.c@1.1, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +563 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/load.c + + gsoc_sntp/libopts/load.c@1.0, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/m4/libopts.m4@1.2, 2008-07-13 22:42:02-04:00, stenn@pogo.udel.edu +0 -0 + bk cp m4/libopts.m4 ../gsoc_sntp/libopts/m4/libopts.m4 + + gsoc_sntp/libopts/m4/libopts.m4@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +509 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/m4/libopts.m4 + + gsoc_sntp/libopts/m4/libopts.m4@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/m4/liboptschk.m4@1.2, 2008-07-13 22:42:02-04:00, stenn@pogo.udel.edu +0 -0 + bk cp m4/liboptschk.m4 ../gsoc_sntp/libopts/m4/liboptschk.m4 + + gsoc_sntp/libopts/m4/liboptschk.m4@1.1, 2007-05-19 00:04:17-04:00, stenn@whimsy.udel.edu +42 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/m4/liboptschk.m4 + + gsoc_sntp/libopts/m4/liboptschk.m4@1.0, 2007-05-19 00:04:17-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/makeshell.c@1.2, 2008-07-13 22:42:03-04:00, stenn@pogo.udel.edu +0 -0 + bk cp makeshell.c ../gsoc_sntp/libopts/makeshell.c + + gsoc_sntp/libopts/makeshell.c@1.1, 2007-05-19 00:04:07-04:00, stenn@whimsy.udel.edu +1122 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/makeshell.c + + gsoc_sntp/libopts/makeshell.c@1.0, 2007-05-19 00:04:07-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/nested.c@1.2, 2008-07-13 22:42:03-04:00, stenn@pogo.udel.edu +0 -0 + bk cp nested.c ../gsoc_sntp/libopts/nested.c + + gsoc_sntp/libopts/nested.c@1.1, 2007-05-19 00:04:07-04:00, stenn@whimsy.udel.edu +733 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/nested.c + + gsoc_sntp/libopts/nested.c@1.0, 2007-05-19 00:04:07-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/numeric.c@1.2, 2008-07-13 22:42:03-04:00, stenn@pogo.udel.edu +0 -0 + bk cp numeric.c ../gsoc_sntp/libopts/numeric.c + + gsoc_sntp/libopts/numeric.c@1.1, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/numeric.c + + gsoc_sntp/libopts/numeric.c@1.0, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/pgusage.c@1.2, 2008-07-13 22:42:03-04:00, stenn@pogo.udel.edu +0 -0 + bk cp pgusage.c ../gsoc_sntp/libopts/pgusage.c + + gsoc_sntp/libopts/pgusage.c@1.1, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +157 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/pgusage.c + + gsoc_sntp/libopts/pgusage.c@1.0, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/proto.h@1.2, 2008-07-13 22:42:04-04:00, stenn@pogo.udel.edu +0 -0 + bk cp proto.h ../gsoc_sntp/libopts/proto.h + + gsoc_sntp/libopts/proto.h@1.1, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +91 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/proto.h + + gsoc_sntp/libopts/proto.h@1.0, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/putshell.c@1.2, 2008-07-13 22:42:04-04:00, stenn@pogo.udel.edu +0 -0 + bk cp putshell.c ../gsoc_sntp/libopts/putshell.c + + gsoc_sntp/libopts/putshell.c@1.1, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +335 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/putshell.c + + gsoc_sntp/libopts/putshell.c@1.0, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/restore.c@1.2, 2008-07-13 22:42:04-04:00, stenn@pogo.udel.edu +0 -0 + bk cp restore.c ../gsoc_sntp/libopts/restore.c + + gsoc_sntp/libopts/restore.c@1.1, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +250 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/restore.c + + gsoc_sntp/libopts/restore.c@1.0, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/save.c@1.3, 2008-07-13 22:42:05-04:00, stenn@pogo.udel.edu +0 -0 + bk cp save.c ../gsoc_sntp/libopts/save.c + + gsoc_sntp/libopts/save.c@1.2, 2007-09-10 01:57:02-04:00, stenn@whimsy.udel.edu +11 -2 + [Bug 902] Fix problems with the -6 flag + + gsoc_sntp/libopts/save.c@1.1, 2007-05-19 00:04:09-04:00, stenn@whimsy.udel.edu +512 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/save.c + + gsoc_sntp/libopts/save.c@1.0, 2007-05-19 00:04:09-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/sort.c@1.2, 2008-07-13 22:42:05-04:00, stenn@pogo.udel.edu +0 -0 + bk cp sort.c ../gsoc_sntp/libopts/sort.c + + gsoc_sntp/libopts/sort.c@1.1, 2007-05-19 00:04:09-04:00, stenn@whimsy.udel.edu +359 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/sort.c + + gsoc_sntp/libopts/sort.c@1.0, 2007-05-19 00:04:09-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/stack.c@1.2, 2008-07-13 22:42:05-04:00, stenn@pogo.udel.edu +0 -0 + bk cp stack.c ../gsoc_sntp/libopts/stack.c + + gsoc_sntp/libopts/stack.c@1.1, 2007-05-19 00:04:10-04:00, stenn@whimsy.udel.edu +269 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/stack.c + + gsoc_sntp/libopts/stack.c@1.0, 2007-05-19 00:04:10-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/streqvcmp.c@1.2, 2008-07-13 22:42:05-04:00, stenn@pogo.udel.edu +0 -0 + bk cp streqvcmp.c ../gsoc_sntp/libopts/streqvcmp.c + + gsoc_sntp/libopts/streqvcmp.c@1.1, 2007-05-19 00:04:11-04:00, stenn@whimsy.udel.edu +289 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/streqvcmp.c + + gsoc_sntp/libopts/streqvcmp.c@1.0, 2007-05-19 00:04:11-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/text_mmap.c@1.2, 2008-07-13 22:42:06-04:00, stenn@pogo.udel.edu +0 -0 + bk cp text_mmap.c ../gsoc_sntp/libopts/text_mmap.c + + gsoc_sntp/libopts/text_mmap.c@1.1, 2007-05-19 00:04:11-04:00, stenn@whimsy.udel.edu +363 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/text_mmap.c + + gsoc_sntp/libopts/text_mmap.c@1.0, 2007-05-19 00:04:11-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/tokenize.c@1.2, 2008-07-13 22:42:06-04:00, stenn@pogo.udel.edu +0 -0 + bk cp tokenize.c ../gsoc_sntp/libopts/tokenize.c + + gsoc_sntp/libopts/tokenize.c@1.1, 2007-05-19 00:04:12-04:00, stenn@whimsy.udel.edu +321 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/tokenize.c + + gsoc_sntp/libopts/tokenize.c@1.0, 2007-05-19 00:04:12-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/usage.c@1.2, 2008-07-13 22:42:07-04:00, stenn@pogo.udel.edu +0 -0 + bk cp usage.c ../gsoc_sntp/libopts/usage.c + + gsoc_sntp/libopts/usage.c@1.1, 2007-05-19 00:04:13-04:00, stenn@whimsy.udel.edu +740 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/usage.c + + gsoc_sntp/libopts/usage.c@1.0, 2007-05-19 00:04:13-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/version.c@1.2, 2008-07-13 22:42:07-04:00, stenn@pogo.udel.edu +0 -0 + bk cp version.c ../gsoc_sntp/libopts/version.c + + gsoc_sntp/libopts/version.c@1.1, 2007-05-19 00:04:13-04:00, stenn@whimsy.udel.edu +178 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/version.c + + gsoc_sntp/libopts/version.c@1.0, 2007-05-19 00:04:13-04:00, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/sntp-opts.def@1.2, 2008-07-22 14:28:19-04:00, stenn@pogo.udel.edu +1 -1 + Update the copyright year + +ChangeSet@1.1436.1.96, 2008-07-22 11:41:26+02:00, burnicki@pogo.udel.edu +2 -0 + [Bug 1038] Built-in getpass() function also prompts for password if not built with DEBUG. + + ChangeLog@1.1.1.39, 2008-07-22 11:41:25+02:00, burnicki@pogo.udel.edu +1 -0 + [Bug 1038] Built-in getpass() function also prompts for password if not built with DEBUG. + + libntp/machines.c@1.19, 2008-07-22 11:41:25+02:00, burnicki@pogo.udel.edu +2 -2 + [Bug 1038] Built-in getpass() function also prompts for password if not built with DEBUG. + +ChangeSet@1.1735.1.10, 2008-07-16 18:07:06-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P120 + TAG: NTP_4_2_5P120 + + ntpd/ntpd-opts.c@1.112, 2008-07-16 18:06:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P120 + + ntpd/ntpd-opts.h@1.112, 2008-07-16 18:06:46-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P120 + + ntpd/ntpd-opts.texi@1.111, 2008-07-16 18:06:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P120 + + ntpd/ntpd.1@1.111, 2008-07-16 18:06:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P120 + + ntpdc/ntpdc-opts.c@1.108, 2008-07-16 18:06:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P120 + + ntpdc/ntpdc-opts.h@1.108, 2008-07-16 18:06:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P120 + + ntpdc/ntpdc-opts.texi@1.107, 2008-07-16 18:06:50-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P120 + + ntpdc/ntpdc.1@1.107, 2008-07-16 18:06:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P120 + + ntpq/ntpq-opts.c@1.108, 2008-07-16 18:06:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P120 + + ntpq/ntpq-opts.h@1.108, 2008-07-16 18:06:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P120 + + ntpq/ntpq-opts.texi@1.107, 2008-07-16 18:06:53-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P120 + + ntpq/ntpq.1@1.107, 2008-07-16 18:06:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P120 + + packageinfo.sh@1.123, 2008-07-16 18:06:55-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P120 + + sntp/sntp-opts.c@1.108, 2008-07-16 18:06:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P120 + + sntp/sntp-opts.h@1.108, 2008-07-16 18:06:57-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P120 + + sntp/sntp-opts.texi@1.107, 2008-07-16 18:06:58-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P120 + + sntp/sntp.1@1.107, 2008-07-16 18:06:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P120 + + util/ntp-keygen-opts.c@1.111, 2008-07-16 18:06:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P120 + + util/ntp-keygen-opts.h@1.111, 2008-07-16 18:07:00-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P120 + + util/ntp-keygen-opts.texi@1.110, 2008-07-16 18:07:02-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P120 + + util/ntp-keygen.1@1.110, 2008-07-16 18:07:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P120 + +ChangeSet@1.1735.1.9, 2008-07-16 17:13:00-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1037]: buffer in subroutine was 1 byte short + + ChangeLog@1.196, 2008-07-16 17:12:45-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1037]: buffer in subroutine was 1 byte short + + util/ntp-keygen.c@1.52, 2008-07-16 17:11:52-04:00, stenn@whimsy.udel.edu +1 -1 + [Bug 1037]: buffer in subroutine was 1 byte short + +ChangeSet@1.1735.1.8, 2008-07-16 06:22:25-04:00, stenn@whimsy.udel.edu +1 -0 + .del-genkeys.html: + Delete: html/genkeys.html + + BitKeeper/deleted/.del-genkeys.html@1.3, 2008-07-16 06:21:53-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/genkeys.html + +ChangeSet@1.1735.1.7, 2008-07-16 06:17:22-04:00, stenn@whimsy.udel.edu +1 -0 + interleave documentation + + html/xleave.html@1.1, 2008-07-16 06:16:33-04:00, stenn@whimsy.udel.edu +32 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/xleave.html + + html/xleave.html@1.0, 2008-07-16 06:16:33-04:00, stenn@whimsy.udel.edu +0 -0 + +ChangeSet@1.1735.1.6, 2008-07-16 05:32:55-04:00, stenn@whimsy.udel.edu +2 -0 + configure.ac: cleanup, added wintime and bug 1028 options + + ChangeLog@1.195, 2008-07-16 05:32:36-04:00, stenn@whimsy.udel.edu +2 -0 + configure.ac: cleanup, added wintime and bug 1028 options + + configure.ac@1.415, 2008-07-16 05:32:38-04:00, stenn@whimsy.udel.edu +46 -6 + configure.ac: cleanup, added wintime and bug 1028 options + +ChangeSet@1.1735.1.5, 2008-07-16 05:26:43-04:00, stenn@whimsy.udel.edu +14 -0 + Bias and Interleave stuff from Dave Mills. + + ChangeLog@1.194, 2008-07-16 05:26:31-04:00, stenn@whimsy.udel.edu +3 -0 + Bias and Interleave stuff from Dave Mills. + + include/ntp.h@1.146, 2008-07-16 05:25:09-04:00, stenn@whimsy.udel.edu +12 -3 + Bias and Interleave stuff from Dave Mills. + + include/ntp_config.h@1.47, 2008-07-16 05:25:11-04:00, stenn@whimsy.udel.edu +1 -0 + Bias and Interleave stuff from Dave Mills. + + libntp/statestr.c@1.14, 2008-07-16 05:26:14-04:00, stenn@whimsy.udel.edu +2 -0 + Bias and Interleave stuff from Dave Mills. + + ntpd/ntp_config.c@1.179, 2008-07-16 05:22:50-04:00, stenn@whimsy.udel.edu +5 -0 + Bias and Interleave stuff from Dave Mills. + + ntpd/ntp_control.c@1.105, 2008-07-16 05:22:51-04:00, stenn@whimsy.udel.edu +13 -8 + Bias and Interleave stuff from Dave Mills. + + ntpd/ntp_loopfilter.c@1.146, 2008-07-16 05:19:07-04:00, stenn@whimsy.udel.edu +8 -9 + separate phase/freq discipline. + + ntpd/ntp_parser.c@1.27, 2008-07-16 05:22:54-04:00, stenn@whimsy.udel.edu +1092 -1065 + Bias and Interleave stuff from Dave Mills. + + ntpd/ntp_parser.h@1.12, 2008-07-16 05:22:58-04:00, stenn@whimsy.udel.edu +289 -285 + Bias and Interleave stuff from Dave Mills. + + ntpd/ntp_parser.y@1.22, 2008-07-16 05:22:59-04:00, stenn@whimsy.udel.edu +4 -0 + Bias and Interleave stuff from Dave Mills. + + ntpd/ntp_proto.c@1.274, 2008-07-16 05:22:59-04:00, stenn@whimsy.udel.edu +332 -160 + Bias and Interleave stuff from Dave Mills. + + ntpd/ntp_refclock.c@1.80, 2008-07-16 05:23:01-04:00, stenn@whimsy.udel.edu +2 -2 + Bias and Interleave stuff from Dave Mills. + + ntpd/ntp_request.c@1.74, 2008-07-16 05:23:02-04:00, stenn@whimsy.udel.edu +1 -2 + Bias and Interleave stuff from Dave Mills. + + ntpd/ntp_util.c@1.65, 2008-07-16 05:23:04-04:00, stenn@whimsy.udel.edu +4 -9 + Bias and Interleave stuff from Dave Mills. + +ChangeSet@1.1735.1.4, 2008-07-16 05:12:48-04:00, stenn@whimsy.udel.edu +8 -0 + Documentation updates from Dave Mills + + ChangeLog@1.193, 2008-07-16 05:12:35-04:00, stenn@whimsy.udel.edu +1 -0 + Documentation updates from Dave Mills + + html/confopt.html@1.41, 2008-07-16 05:11:42-04:00, stenn@whimsy.udel.edu +28 -19 + Documentation updates from Dave Mills + + html/copyright.html@1.41, 2008-07-16 05:11:43-04:00, stenn@whimsy.udel.edu +1 -1 + Documentation updates from Dave Mills + + html/decode.html@1.2, 2008-07-16 05:11:44-04:00, stenn@whimsy.udel.edu +2 -2 + Documentation updates from Dave Mills + + html/keygen.html@1.12, 2008-07-16 05:11:46-04:00, stenn@whimsy.udel.edu +3 -2 + Documentation updates from Dave Mills + + html/monopt.html@1.28, 2008-07-16 05:11:47-04:00, stenn@whimsy.udel.edu +1 -1 + Documentation updates from Dave Mills + + html/ntpd.html@1.44, 2008-07-16 05:11:49-04:00, stenn@whimsy.udel.edu +2 -1 + Documentation updates from Dave Mills + + html/ntpq.html@1.30, 2008-07-16 05:11:50-04:00, stenn@whimsy.udel.edu +6 -2 + Documentation updates from Dave Mills + +ChangeSet@1.1735.1.3, 2008-07-16 05:06:03-04:00, stenn@whimsy.udel.edu +1 -0 + jitter.c: make NBUF about 10x bigger + + util/jitter.c@1.9, 2008-07-16 05:05:46-04:00, stenn@whimsy.udel.edu +1 -1 + jitter.c: make NBUF about 10x bigger + +ChangeSet@1.1735.1.2, 2008-07-15 03:44:23-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P119 + TAG: NTP_4_2_5P119 + + ntpd/ntpd-opts.c@1.111, 2008-07-15 03:44:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P119 + + ntpd/ntpd-opts.h@1.111, 2008-07-15 03:44:05-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P119 + + ntpd/ntpd-opts.texi@1.110, 2008-07-15 03:44:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P119 + + ntpd/ntpd.1@1.110, 2008-07-15 03:44:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P119 + + ntpdc/ntpdc-opts.c@1.107, 2008-07-15 03:44:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P119 + + ntpdc/ntpdc-opts.h@1.107, 2008-07-15 03:44:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P119 + + ntpdc/ntpdc-opts.texi@1.106, 2008-07-15 03:44:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P119 + + ntpdc/ntpdc.1@1.106, 2008-07-15 03:44:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P119 + + ntpq/ntpq-opts.c@1.107, 2008-07-15 03:44:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P119 + + ntpq/ntpq-opts.h@1.107, 2008-07-15 03:44:11-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P119 + + ntpq/ntpq-opts.texi@1.106, 2008-07-15 03:44:12-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P119 + + ntpq/ntpq.1@1.106, 2008-07-15 03:44:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P119 + + packageinfo.sh@1.122, 2008-07-15 03:44:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P119 + + sntp/sntp-opts.c@1.107, 2008-07-15 03:44:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P119 + + sntp/sntp-opts.h@1.107, 2008-07-15 03:44:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P119 + + sntp/sntp-opts.texi@1.106, 2008-07-15 03:44:15-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P119 + + sntp/sntp.1@1.106, 2008-07-15 03:44:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P119 + + util/ntp-keygen-opts.c@1.110, 2008-07-15 03:44:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P119 + + util/ntp-keygen-opts.h@1.110, 2008-07-15 03:44:18-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P119 + + util/ntp-keygen-opts.texi@1.109, 2008-07-15 03:44:18-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P119 + + util/ntp-keygen.1@1.109, 2008-07-15 03:44:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P119 + +ChangeSet@1.1735.1.1, 2008-07-14 01:28:14-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1037] Use all 16 of the MD5 passwords generated by ntp-keygen + + ChangeLog@1.192, 2008-07-14 01:27:33-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1037] Use all 16 of the MD5 passwords generated by ntp-keygen + + util/ntp-keygen.c@1.51, 2008-07-14 01:27:35-04:00, stenn@whimsy.udel.edu +1 -1 + [Bug 1037] Use all 16 of the MD5 passwords generated by ntp-keygen + +ChangeSet@1.1737, 2008-07-09 05:45:39+09:00, Amidamaru@yumi.mxiesoft.com +2 -0 + networking.h: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/networking.h + networking.c: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/networking.c + + gsoc_sntp/networking.c@1.1, 2008-07-09 05:41:32+09:00, Amidamaru@yumi.mxiesoft.com +278 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/networking.c + + gsoc_sntp/networking.c@1.0, 2008-07-09 05:41:32+09:00, Amidamaru@yumi.mxiesoft.com +0 -0 + + gsoc_sntp/networking.h@1.1, 2008-07-09 05:41:35+09:00, Amidamaru@yumi.mxiesoft.com +48 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/networking.h + + gsoc_sntp/networking.h@1.0, 2008-07-09 05:41:35+09:00, Amidamaru@yumi.mxiesoft.com +0 -0 + +ChangeSet@1.1736, 2008-07-09 05:14:24+09:00, Amidamaru@yumi.mxiesoft.com +14 -0 + ignore: + added config.guess config.h config.h.in config.log config.status config.sub + Makefile.in: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/Makefile.in + netutils.c: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/netutils.c + header.h: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/header.h + sntp-opts.def: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/sntp-opts.def + netutils.h: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/netutils.h + kod_management.h: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/kod_management.h + ignore: + added aclocal.m4 + kod_management.c: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/kod_management.c + Makefile: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/Makefile + ignore: + added config.h + main.c: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/main.c + ignore: + added test.kod + log.c: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/log.c + data_formats.h: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/data_formats.h + log.h: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/log.h + Makefile.am: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/Makefile.am + + BitKeeper/etc/ignore@1.64, 2008-07-09 05:10:45+09:00, Amidamaru@yumi.mxiesoft.com +1 -0 + added test.kod + + BitKeeper/etc/ignore@1.63, 2008-07-09 05:10:33+09:00, Amidamaru@yumi.mxiesoft.com +1 -0 + added aclocal.m4 + + BitKeeper/etc/ignore@1.62, 2008-07-09 05:10:21+09:00, Amidamaru@yumi.mxiesoft.com +6 -0 + added config.guess config.h config.h.in config.log config.status config.sub + + BitKeeper/etc/ignore@1.61, 2008-07-09 05:10:14+09:00, Amidamaru@yumi.mxiesoft.com +1 -0 + added config.h + + gsoc_sntp/Makefile@1.1, 2008-07-09 05:05:13+09:00, Amidamaru@yumi.mxiesoft.com +694 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/Makefile + + gsoc_sntp/Makefile@1.0, 2008-07-09 05:05:13+09:00, Amidamaru@yumi.mxiesoft.com +0 -0 + + gsoc_sntp/Makefile.am@1.1, 2008-07-09 05:05:20+09:00, Amidamaru@yumi.mxiesoft.com +69 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/Makefile.am + + gsoc_sntp/Makefile.am@1.0, 2008-07-09 05:05:20+09:00, Amidamaru@yumi.mxiesoft.com +0 -0 + + gsoc_sntp/Makefile.in@1.1, 2008-07-09 05:05:24+09:00, Amidamaru@yumi.mxiesoft.com +694 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/Makefile.in + + gsoc_sntp/Makefile.in@1.0, 2008-07-09 05:05:24+09:00, Amidamaru@yumi.mxiesoft.com +0 -0 + + gsoc_sntp/data_formats.h@1.1, 2008-07-09 05:08:31+09:00, Amidamaru@yumi.mxiesoft.com +10 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/data_formats.h + + gsoc_sntp/data_formats.h@1.0, 2008-07-09 05:08:31+09:00, Amidamaru@yumi.mxiesoft.com +0 -0 + + gsoc_sntp/header.h@1.1, 2008-07-09 05:08:42+09:00, Amidamaru@yumi.mxiesoft.com +87 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/header.h + + gsoc_sntp/header.h@1.0, 2008-07-09 05:08:42+09:00, Amidamaru@yumi.mxiesoft.com +0 -0 + + gsoc_sntp/kod_management.c@1.1, 2008-07-09 05:07:01+09:00, Amidamaru@yumi.mxiesoft.com +258 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/kod_management.c + + gsoc_sntp/kod_management.c@1.0, 2008-07-09 05:07:01+09:00, Amidamaru@yumi.mxiesoft.com +0 -0 + + gsoc_sntp/kod_management.h@1.1, 2008-07-09 05:07:01+09:00, Amidamaru@yumi.mxiesoft.com +20 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/kod_management.h + + gsoc_sntp/kod_management.h@1.0, 2008-07-09 05:07:01+09:00, Amidamaru@yumi.mxiesoft.com +0 -0 + + gsoc_sntp/log.c@1.1, 2008-07-09 05:06:13+09:00, Amidamaru@yumi.mxiesoft.com +52 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/log.c + + gsoc_sntp/log.c@1.0, 2008-07-09 05:06:13+09:00, Amidamaru@yumi.mxiesoft.com +0 -0 + + gsoc_sntp/log.h@1.1, 2008-07-09 05:06:14+09:00, Amidamaru@yumi.mxiesoft.com +21 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/log.h + + gsoc_sntp/log.h@1.0, 2008-07-09 05:06:14+09:00, Amidamaru@yumi.mxiesoft.com +0 -0 + + gsoc_sntp/main.c@1.1, 2008-07-09 05:07:38+09:00, Amidamaru@yumi.mxiesoft.com +86 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/main.c + + gsoc_sntp/main.c@1.0, 2008-07-09 05:07:38+09:00, Amidamaru@yumi.mxiesoft.com +0 -0 + + gsoc_sntp/netutils.c@1.1, 2008-07-09 05:07:09+09:00, Amidamaru@yumi.mxiesoft.com +320 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/netutils.c + + gsoc_sntp/netutils.c@1.0, 2008-07-09 05:07:09+09:00, Amidamaru@yumi.mxiesoft.com +0 -0 + + gsoc_sntp/netutils.h@1.1, 2008-07-09 05:07:09+09:00, Amidamaru@yumi.mxiesoft.com +10 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/netutils.h + + gsoc_sntp/netutils.h@1.0, 2008-07-09 05:07:09+09:00, Amidamaru@yumi.mxiesoft.com +0 -0 + + gsoc_sntp/sntp-opts.def@1.1, 2008-07-09 05:07:23+09:00, Amidamaru@yumi.mxiesoft.com +293 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/sntp-opts.def + + gsoc_sntp/sntp-opts.def@1.0, 2008-07-09 05:07:23+09:00, Amidamaru@yumi.mxiesoft.com +0 -0 + +ChangeSet@1.1735, 2008-06-06 19:56:21-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P118 + TAG: NTP_4_2_5P118 + + ntpd/ntpd-opts.c@1.110, 2008-06-06 19:56:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P118 + + ntpd/ntpd-opts.h@1.110, 2008-06-06 19:56:03-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P118 + + ntpd/ntpd-opts.texi@1.109, 2008-06-06 19:56:04-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P118 + + ntpd/ntpd.1@1.109, 2008-06-06 19:56:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P118 + + ntpdc/ntpdc-opts.c@1.106, 2008-06-06 19:56:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P118 + + ntpdc/ntpdc-opts.h@1.106, 2008-06-06 19:56:06-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P118 + + ntpdc/ntpdc-opts.texi@1.105, 2008-06-06 19:56:07-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P118 + + ntpdc/ntpdc.1@1.105, 2008-06-06 19:56:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P118 + + ntpq/ntpq-opts.c@1.106, 2008-06-06 19:56:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P118 + + ntpq/ntpq-opts.h@1.106, 2008-06-06 19:56:09-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P118 + + ntpq/ntpq-opts.texi@1.105, 2008-06-06 19:56:10-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P118 + + ntpq/ntpq.1@1.105, 2008-06-06 19:56:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P118 + + packageinfo.sh@1.121, 2008-06-06 19:56:11-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P118 + + sntp/sntp-opts.c@1.106, 2008-06-06 19:56:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P118 + + sntp/sntp-opts.h@1.106, 2008-06-06 19:56:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P118 + + sntp/sntp-opts.texi@1.105, 2008-06-06 19:56:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P118 + + sntp/sntp.1@1.105, 2008-06-06 19:56:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P118 + + util/ntp-keygen-opts.c@1.109, 2008-06-06 19:56:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P118 + + util/ntp-keygen-opts.h@1.109, 2008-06-06 19:56:16-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P118 + + util/ntp-keygen-opts.texi@1.108, 2008-06-06 19:56:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P118 + + util/ntp-keygen.1@1.108, 2008-06-06 19:56:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P118 + +ChangeSet@1.1728.1.4, 2008-05-30 00:54:03-04:00, stenn@whimsy.udel.edu +1 -0 + Triggers are fired with an absolute (v. relative) path. + + BitKeeper/triggers/triggert@1.5, 2008-05-30 00:53:48-04:00, stenn@whimsy.udel.edu +3 -2 + Triggers are fired with an absolute (v. relative) path. + +ChangeSet@1.1728.1.3, 2008-05-23 03:00:07-04:00, stenn@whimsy.udel.edu +3 -0 + Poll time and local refclock documentation updates from Dave Mills + + ChangeLog@1.186.1.1, 2008-05-23 02:59:50-04:00, stenn@whimsy.udel.edu +2 -0 + Poll time and local refclock documentation updates from Dave Mills + + html/drivers/driver1.html@1.16, 2008-05-23 02:58:24-04:00, stenn@whimsy.udel.edu +3 -18 + local refclock documentation updates from Dave Mills + + ntpd/ntp_proto.c@1.273, 2008-05-23 02:58:56-04:00, stenn@whimsy.udel.edu +11 -2 + poll time updates from Dave Mills + +ChangeSet@1.1728.1.2, 2008-05-21 07:48:20-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P117 + TAG: NTP_4_2_5P117 + + ntpd/ntpd-opts.c@1.109, 2008-05-21 07:47:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P117 + + ntpd/ntpd-opts.h@1.109, 2008-05-21 07:48:00-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P117 + + ntpd/ntpd-opts.texi@1.108, 2008-05-21 07:48:01-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P117 + + ntpd/ntpd.1@1.108, 2008-05-21 07:48:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P117 + + ntpdc/ntpdc-opts.c@1.105, 2008-05-21 07:48:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P117 + + ntpdc/ntpdc-opts.h@1.105, 2008-05-21 07:48:03-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P117 + + ntpdc/ntpdc-opts.texi@1.104, 2008-05-21 07:48:04-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P117 + + ntpdc/ntpdc.1@1.104, 2008-05-21 07:48:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P117 + + ntpq/ntpq-opts.c@1.105, 2008-05-21 07:48:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P117 + + ntpq/ntpq-opts.h@1.105, 2008-05-21 07:48:06-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P117 + + ntpq/ntpq-opts.texi@1.104, 2008-05-21 07:48:08-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P117 + + ntpq/ntpq.1@1.104, 2008-05-21 07:48:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P117 + + packageinfo.sh@1.120, 2008-05-21 07:48:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P117 + + sntp/sntp-opts.c@1.105, 2008-05-21 07:48:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P117 + + sntp/sntp-opts.h@1.105, 2008-05-21 07:48:11-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P117 + + sntp/sntp-opts.texi@1.104, 2008-05-21 07:48:11-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P117 + + sntp/sntp.1@1.104, 2008-05-21 07:48:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P117 + + util/ntp-keygen-opts.c@1.108, 2008-05-21 07:48:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P117 + + util/ntp-keygen-opts.h@1.108, 2008-05-21 07:48:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P117 + + util/ntp-keygen-opts.texi@1.107, 2008-05-21 07:48:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P117 + + util/ntp-keygen.1@1.107, 2008-05-21 07:48:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P117 + +ChangeSet@1.1731, 2008-05-21 09:32:13+05:30, venu@door.(none) +1 -0 + ChangeLog: + Corrected the comments for NMEA refclock driver. + + ChangeLog@1.190, 2008-05-21 09:31:21+05:30, venu@door.(none) +2 -1 + Corrected the comments for NMEA refclock driver. + +ChangeSet@1.1730, 2008-05-20 18:34:17+05:30, venu@door.(none) +2 -0 + ChangeLog: + Added comments for fixing the incorrect edge parameter passed to time_pps_kcbind. + refclock_nmea.c: + Fixed the incorrect edge parameter being passed to time_pps_kcbind. + + ChangeLog@1.189, 2008-05-20 18:32:56+05:30, venu@door.(none) +1 -0 + Added comments for fixing the incorrect edge parameter passed to time_pps_kcbind. + + ntpd/refclock_nmea.c@1.29, 2008-05-20 18:31:09+05:30, venu@door.(none) +1 -1 + Fixed the incorrect edge parameter being passed to time_pps_kcbind. + +ChangeSet@1.1729, 2008-05-20 08:13:42+00:00, gopal@pogo.udel.edu +2 -0 + ChangeLog: + Added comments for bug 985. + refclock_nmea.c: + [Bug 399] NMEA refclock driver does not honor time1 offset if flag3 set. + [Bug 985] Modifications to NMEA reference clock driver to support Accord GPS Clock. + ChangeLog: + Added comments for bug 399. + + ChangeLog@1.188, 2008-05-20 02:30:23-04:00, gopal@pogo.udel.edu +1 -0 + Added comments for bug 399. + + ChangeLog@1.187, 2008-05-20 02:16:04-04:00, gopal@pogo.udel.edu +1 -0 + Added comments for bug 985. + + ntpd/refclock_nmea.c@1.28, 2008-05-20 02:29:27-04:00, gopal@pogo.udel.edu +24 -4 + [Bug 399] NMEA refclock driver does not honor time1 offset if flag3 set. + + ntpd/refclock_nmea.c@1.27, 2008-05-20 02:13:49-04:00, gopal@pogo.udel.edu +111 -21 + [Bug 985] Modifications to NMEA reference clock driver to support Accord GPS Clock. + +ChangeSet@1.1436.1.95, 2008-05-20 03:51:01-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_4P5_RC1 + TAG: NTP_4_2_4P5_RC1 + + ntpd/ntpd-opts.c@1.50.14.1, 2008-05-20 03:50:37-04:00, stenn@whimsy.udel.edu +6 -7 + NTP_4_2_4P5_RC1 + + ntpd/ntpd-opts.h@1.50.14.1, 2008-05-20 03:50:37-04:00, stenn@whimsy.udel.edu +6 -7 + NTP_4_2_4P5_RC1 + + ntpd/ntpd-opts.texi@1.49.14.1, 2008-05-20 03:50:38-04:00, stenn@whimsy.udel.edu +8 -11 + NTP_4_2_4P5_RC1 + + ntpd/ntpd.1@1.48.14.1, 2008-05-20 03:50:39-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P5_RC1 + + ntpd/ntpdsim-opts.c@1.50.14.1, 2008-05-20 03:50:40-04:00, stenn@whimsy.udel.edu +6 -7 + NTP_4_2_4P5_RC1 + + ntpd/ntpdsim-opts.h@1.50.14.1, 2008-05-20 03:50:41-04:00, stenn@whimsy.udel.edu +6 -7 + NTP_4_2_4P5_RC1 + + ntpd/ntpdsim-opts.texi@1.48.14.1, 2008-05-20 03:50:42-04:00, stenn@whimsy.udel.edu +3 -4 + NTP_4_2_4P5_RC1 + + ntpd/ntpdsim.1@1.48.14.1, 2008-05-20 03:50:43-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P5_RC1 + + ntpdc/ntpdc-opts.c@1.50.14.1, 2008-05-20 03:50:44-04:00, stenn@whimsy.udel.edu +6 -7 + NTP_4_2_4P5_RC1 + + ntpdc/ntpdc-opts.h@1.50.14.1, 2008-05-20 03:50:44-04:00, stenn@whimsy.udel.edu +6 -7 + NTP_4_2_4P5_RC1 + + ntpdc/ntpdc-opts.texi@1.48.14.1, 2008-05-20 03:50:45-04:00, stenn@whimsy.udel.edu +5 -6 + NTP_4_2_4P5_RC1 + + ntpdc/ntpdc.1@1.48.14.1, 2008-05-20 03:50:46-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P5_RC1 + + ntpq/ntpq-opts.c@1.52.14.1, 2008-05-20 03:50:47-04:00, stenn@whimsy.udel.edu +6 -7 + NTP_4_2_4P5_RC1 + + ntpq/ntpq-opts.h@1.52.14.1, 2008-05-20 03:50:47-04:00, stenn@whimsy.udel.edu +6 -7 + NTP_4_2_4P5_RC1 + + ntpq/ntpq-opts.texi@1.49.14.1, 2008-05-20 03:50:48-04:00, stenn@whimsy.udel.edu +5 -6 + NTP_4_2_4P5_RC1 + + ntpq/ntpq.1@1.48.14.1, 2008-05-20 03:50:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P5_RC1 + + packageinfo.sh@1.65.21.1, 2008-05-20 03:50:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5_RC1 + + sntp/sntp-opts.c@1.49.14.1, 2008-05-20 03:50:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5_RC1 + + sntp/sntp-opts.h@1.49.14.1, 2008-05-20 03:50:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P5_RC1 + + sntp/sntp-opts.texi@1.46.14.1, 2008-05-20 03:50:52-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P5_RC1 + + sntp/sntp.1@1.49.14.1, 2008-05-20 03:50:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P5_RC1 + + util/ntp-keygen-opts.c@1.49.14.1, 2008-05-20 03:50:54-04:00, stenn@whimsy.udel.edu +6 -7 + NTP_4_2_4P5_RC1 + + util/ntp-keygen-opts.h@1.49.14.1, 2008-05-20 03:50:54-04:00, stenn@whimsy.udel.edu +6 -7 + NTP_4_2_4P5_RC1 + + util/ntp-keygen-opts.texi@1.47.14.1, 2008-05-20 03:50:55-04:00, stenn@whimsy.udel.edu +7 -9 + NTP_4_2_4P5_RC1 + + util/ntp-keygen.1@1.47.14.1, 2008-05-20 03:50:56-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P5_RC1 + +ChangeSet@1.1728, 2008-05-18 07:57:45-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P116 + TAG: NTP_4_2_5P116 + + ntpd/ntpd-opts.c@1.108, 2008-05-18 07:57:24-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P116 + + ntpd/ntpd-opts.h@1.108, 2008-05-18 07:57:25-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P116 + + ntpd/ntpd-opts.texi@1.107, 2008-05-18 07:57:26-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P116 + + ntpd/ntpd.1@1.107, 2008-05-18 07:57:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P116 + + ntpdc/ntpdc-opts.c@1.104, 2008-05-18 07:57:28-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P116 + + ntpdc/ntpdc-opts.h@1.104, 2008-05-18 07:57:29-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P116 + + ntpdc/ntpdc-opts.texi@1.103, 2008-05-18 07:57:30-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P116 + + ntpdc/ntpdc.1@1.103, 2008-05-18 07:57:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P116 + + ntpq/ntpq-opts.c@1.104, 2008-05-18 07:57:31-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P116 + + ntpq/ntpq-opts.h@1.104, 2008-05-18 07:57:32-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P116 + + ntpq/ntpq-opts.texi@1.103, 2008-05-18 07:57:33-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P116 + + ntpq/ntpq.1@1.103, 2008-05-18 07:57:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P116 + + packageinfo.sh@1.119, 2008-05-18 07:57:34-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P116 + + sntp/sntp-opts.c@1.104, 2008-05-18 07:57:35-04:00, stenn@whimsy.udel.edu +5 -4 + NTP_4_2_5P116 + + sntp/sntp-opts.h@1.104, 2008-05-18 07:57:36-04:00, stenn@whimsy.udel.edu +6 -5 + NTP_4_2_5P116 + + sntp/sntp-opts.texi@1.103, 2008-05-18 07:57:37-04:00, stenn@whimsy.udel.edu +3 -2 + NTP_4_2_5P116 + + sntp/sntp.1@1.103, 2008-05-18 07:57:38-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P116 + + util/ntp-keygen-opts.c@1.107, 2008-05-18 07:57:39-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P116 + + util/ntp-keygen-opts.h@1.107, 2008-05-18 07:57:40-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P116 + + util/ntp-keygen-opts.texi@1.106, 2008-05-18 07:57:41-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P116 + + util/ntp-keygen.1@1.106, 2008-05-18 07:57:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P116 + +ChangeSet@1.1436.1.94, 2008-05-18 05:14:37-04:00, stenn@whimsy.udel.edu +1 -0 + Start the 4.2.4p5 release candidate cycle + + packageinfo.sh@1.65.20.1, 2008-05-18 05:14:27-04:00, stenn@whimsy.udel.edu +1 -1 + Start the 4.2.4p5 release candidate cycle + +ChangeSet@1.1726, 2008-05-18 04:59:09-04:00, stenn@whimsy.udel.edu +1 -0 + fix a merge conflict + + ntpd/ntp_io.c@1.273, 2008-05-18 04:58:38-04:00, stenn@whimsy.udel.edu +1 -1 + fix a merge conflict + +ChangeSet@1.1724, 2008-05-15 07:44:36-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P115 + TAG: NTP_4_2_5P115 + + ntpd/ntpd-opts.c@1.107, 2008-05-15 07:44:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P115 + + ntpd/ntpd-opts.h@1.107, 2008-05-15 07:44:16-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P115 + + ntpd/ntpd-opts.texi@1.106, 2008-05-15 07:44:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P115 + + ntpd/ntpd.1@1.106, 2008-05-15 07:44:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P115 + + ntpdc/ntpdc-opts.c@1.103, 2008-05-15 07:44:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P115 + + ntpdc/ntpdc-opts.h@1.103, 2008-05-15 07:44:19-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P115 + + ntpdc/ntpdc-opts.texi@1.102, 2008-05-15 07:44:20-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P115 + + ntpdc/ntpdc.1@1.102, 2008-05-15 07:44:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P115 + + ntpq/ntpq-opts.c@1.103, 2008-05-15 07:44:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P115 + + ntpq/ntpq-opts.h@1.103, 2008-05-15 07:44:23-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P115 + + ntpq/ntpq-opts.texi@1.102, 2008-05-15 07:44:24-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P115 + + ntpq/ntpq.1@1.102, 2008-05-15 07:44:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P115 + + packageinfo.sh@1.118, 2008-05-15 07:44:26-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P115 + + sntp/sntp-opts.c@1.103, 2008-05-15 07:44:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P115 + + sntp/sntp-opts.h@1.103, 2008-05-15 07:44:27-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P115 + + sntp/sntp-opts.texi@1.102, 2008-05-15 07:44:28-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P115 + + sntp/sntp.1@1.102, 2008-05-15 07:44:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P115 + + util/ntp-keygen-opts.c@1.106, 2008-05-15 07:44:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P115 + + util/ntp-keygen-opts.h@1.106, 2008-05-15 07:44:30-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P115 + + util/ntp-keygen-opts.texi@1.105, 2008-05-15 07:44:31-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P115 + + util/ntp-keygen.1@1.105, 2008-05-15 07:44:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P115 + +ChangeSet@1.1723, 2008-05-15 02:03:40-04:00, stenn@whimsy.udel.edu +6 -0 + [Bug 1022] Fix compilation problems with yesterday's commit + + ChangeLog@1.185, 2008-05-15 02:01:31-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 1022] Fix compilation problems with yesterday's commit + + include/ntp.h@1.145, 2008-05-15 02:00:27-04:00, stenn@whimsy.udel.edu +1 -1 + [Bug 1022] Fix compilation problems with yesterday's commit + + ntpd/ntp_intres.c@1.54, 2008-05-15 01:59:44-04:00, stenn@whimsy.udel.edu +5 -0 + [Bug 1022] Fix compilation problems with yesterday's commit + + ntpd/ntp_peer.c@1.113, 2008-05-15 01:59:47-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 1022] Fix compilation problems with yesterday's commit + + ntpd/ntp_request.c@1.73, 2008-05-15 01:59:48-04:00, stenn@whimsy.udel.edu +5 -1 + [Bug 1022] Fix compilation problems with yesterday's commit + + ntpd/refclock_acts.c@1.34, 2008-05-15 01:59:53-04:00, stenn@whimsy.udel.edu +1 -1 + [Bug 1022] Fix compilation problems with yesterday's commit + +ChangeSet@1.1722, 2008-05-13 07:49:21-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P114 + TAG: NTP_4_2_5P114 + + ntpd/ntpd-opts.c@1.106, 2008-05-13 07:49:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P114 + + ntpd/ntpd-opts.h@1.106, 2008-05-13 07:49:00-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P114 + + ntpd/ntpd-opts.texi@1.105, 2008-05-13 07:49:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P114 + + ntpd/ntpd.1@1.105, 2008-05-13 07:49:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P114 + + ntpdc/ntpdc-opts.c@1.102, 2008-05-13 07:49:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P114 + + ntpdc/ntpdc-opts.h@1.102, 2008-05-13 07:49:04-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P114 + + ntpdc/ntpdc-opts.texi@1.101, 2008-05-13 07:49:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P114 + + ntpdc/ntpdc.1@1.101, 2008-05-13 07:49:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P114 + + ntpq/ntpq-opts.c@1.102, 2008-05-13 07:49:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P114 + + ntpq/ntpq-opts.h@1.102, 2008-05-13 07:49:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P114 + + ntpq/ntpq-opts.texi@1.101, 2008-05-13 07:49:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P114 + + ntpq/ntpq.1@1.101, 2008-05-13 07:49:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P114 + + packageinfo.sh@1.117, 2008-05-13 07:49:12-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P114 + + sntp/sntp-opts.c@1.102, 2008-05-13 07:49:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P114 + + sntp/sntp-opts.h@1.102, 2008-05-13 07:49:13-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P114 + + sntp/sntp-opts.texi@1.101, 2008-05-13 07:49:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P114 + + sntp/sntp.1@1.101, 2008-05-13 07:49:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P114 + + util/ntp-keygen-opts.c@1.105, 2008-05-13 07:49:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P114 + + util/ntp-keygen-opts.h@1.105, 2008-05-13 07:49:16-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P114 + + util/ntp-keygen-opts.texi@1.104, 2008-05-13 07:49:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P114 + + util/ntp-keygen.1@1.104, 2008-05-13 07:49:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P114 + +ChangeSet@1.1721, 2008-05-13 05:18:04-04:00, stenn@whimsy.udel.edu +76 -0 + Changes from Dave Mills (some backward-incompatible changes) + + ChangeLog@1.184, 2008-05-13 05:16:52-04:00, stenn@whimsy.udel.edu +71 -0 + Changes from Dave Mills (some backward-incompatible changes) + + html/accopt.html@1.27, 2008-05-12 01:36:14-04:00, stenn@whimsy.udel.edu +30 -21 + Documentation updated from Dave Mills + + html/accopt.html@1.26, 2008-02-22 22:54:01-05:00, stenn@whimsy.udel.edu +4 -5 + Documentation updates from Dave Mills + + html/authopt.html@1.47, 2008-05-12 01:36:15-04:00, stenn@whimsy.udel.edu +38 -24 + Documentation updated from Dave Mills + + html/bugs.html@1.4, 2008-05-12 01:36:16-04:00, stenn@whimsy.udel.edu +2 -2 + Documentation updated from Dave Mills + + html/build.html@1.23, 2008-05-12 01:36:17-04:00, stenn@whimsy.udel.edu +9 -10 + Documentation updated from Dave Mills + + html/clockopt.html@1.21, 2008-05-12 01:36:17-04:00, stenn@whimsy.udel.edu +5 -5 + Documentation updated from Dave Mills + + html/comdex.html@1.1, 2008-05-12 01:34:40-04:00, stenn@whimsy.udel.edu +30 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/comdex.html + + html/comdex.html@1.0, 2008-05-12 01:34:40-04:00, stenn@whimsy.udel.edu +0 -0 + + html/config.html@1.21, 2008-05-12 01:36:18-04:00, stenn@whimsy.udel.edu +5 -5 + Documentation updated from Dave Mills + + html/confopt.html@1.40, 2008-05-12 01:36:19-04:00, stenn@whimsy.udel.edu +7 -6 + Documentation updated from Dave Mills + + html/copyright.html@1.39, 2008-05-12 01:36:19-04:00, stenn@whimsy.udel.edu +1 -2 + Documentation updated from Dave Mills + + html/debug.html@1.25, 2008-05-12 01:36:20-04:00, stenn@whimsy.udel.edu +20 -121 + Documentation updated from Dave Mills + + html/decode.html@1.1, 2008-05-12 01:34:41-04:00, stenn@whimsy.udel.edu +681 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/decode.html + + html/decode.html@1.0, 2008-05-12 01:34:41-04:00, stenn@whimsy.udel.edu +0 -0 + + html/genkeys.html@1.2, 2008-05-12 01:36:22-04:00, stenn@whimsy.udel.edu +1 -1 + Documentation updated from Dave Mills + + html/hints/winnt.html@1.19, 2008-05-12 01:38:01-04:00, stenn@whimsy.udel.edu +4 -3 + Documentation updated from Dave Mills + + html/index.html@1.37, 2008-05-12 01:36:23-04:00, stenn@whimsy.udel.edu +5 -4 + Documentation updated from Dave Mills + + html/kern.html@1.16, 2008-05-12 01:36:25-04:00, stenn@whimsy.udel.edu +2 -2 + Documentation updated from Dave Mills + + html/kernpps.html@1.2, 2008-05-12 01:36:25-04:00, stenn@whimsy.udel.edu +3 -0 + Documentation updated from Dave Mills + + html/manyopt.html@1.17, 2008-05-12 01:36:26-04:00, stenn@whimsy.udel.edu +22 -19 + Documentation updated from Dave Mills + + html/miscopt.html@1.40, 2008-05-12 01:36:27-04:00, stenn@whimsy.udel.edu +47 -69 + Documentation updated from Dave Mills + + html/monopt.html@1.27, 2008-05-12 01:36:27-04:00, stenn@whimsy.udel.edu +388 -356 + Documentation updated from Dave Mills + + html/monopt.html@1.26, 2008-02-22 22:54:04-05:00, stenn@whimsy.udel.edu +363 -330 + Documentation updates from Dave Mills + + html/msyslog.html@1.9, 2008-05-12 01:36:29-04:00, stenn@whimsy.udel.edu +3 -3 + Documentation updated from Dave Mills + + html/msyslog.html@1.8, 2008-02-22 22:54:05-05:00, stenn@whimsy.udel.edu +5 -2 + Documentation updates from Dave Mills + + html/ntp_conf.html@1.2, 2008-05-12 01:36:29-04:00, stenn@whimsy.udel.edu +3 -3 + Documentation updated from Dave Mills + + html/ntpd.html@1.43, 2008-05-12 01:36:30-04:00, stenn@whimsy.udel.edu +50 -71 + Documentation updated from Dave Mills + + html/ntpd.html@1.42, 2008-02-22 22:54:06-05:00, stenn@whimsy.udel.edu +2 -2 + Documentation updates from Dave Mills + + html/ntpdsim.html@1.7, 2008-05-12 01:36:31-04:00, stenn@whimsy.udel.edu +3 -3 + Documentation updated from Dave Mills + + html/ntpdsim_new.html@1.3, 2008-05-12 01:36:31-04:00, stenn@whimsy.udel.edu +3 -3 + Documentation updated from Dave Mills + + html/ntpq.html@1.29, 2008-05-12 01:36:32-04:00, stenn@whimsy.udel.edu +453 -190 + Documentation updated from Dave Mills + + html/ntptime.html@1.16, 2008-05-12 01:36:33-04:00, stenn@whimsy.udel.edu +3 -3 + Documentation updated from Dave Mills + + html/pic/alice15.gif@1.1, 2008-05-12 01:34:42-04:00, stenn@whimsy.udel.edu +587 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/alice15.gif + + html/pic/alice15.gif@1.0, 2008-05-12 01:34:42-04:00, stenn@whimsy.udel.edu +0 -0 + + html/pic/flatheads.gif@1.1, 2008-05-12 01:34:42-04:00, stenn@whimsy.udel.edu +292 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/flatheads.gif + + html/pic/flatheads.gif@1.0, 2008-05-12 01:34:42-04:00, stenn@whimsy.udel.edu +0 -0 + + html/pic/pogo7.gif@1.1, 2008-05-12 01:34:42-04:00, stenn@whimsy.udel.edu +309 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/pogo7.gif + + html/pic/pogo7.gif@1.0, 2008-05-12 01:34:42-04:00, stenn@whimsy.udel.edu +0 -0 + + html/pic/tonea.gif@1.2, 2008-05-12 01:36:51-04:00, stenn@whimsy.udel.edu +251 -347 + Documentation updated from Dave Mills + + html/pic/tribeb.gif@1.1, 2008-05-12 01:34:43-04:00, stenn@whimsy.udel.edu +675 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/tribeb.gif + + html/pic/tribeb.gif@1.0, 2008-05-12 01:34:43-04:00, stenn@whimsy.udel.edu +0 -0 + + html/pic/wingdorothy.gif@1.2, 2008-05-12 01:36:52-04:00, stenn@whimsy.udel.edu +226 -313 + Documentation updated from Dave Mills + + html/quick.html@1.19, 2008-05-12 01:36:34-04:00, stenn@whimsy.udel.edu +4 -4 + Documentation updated from Dave Mills + + html/rate.html@1.3, 2008-05-12 01:36:35-04:00, stenn@whimsy.udel.edu +24 -20 + Documentation updated from Dave Mills + + html/release.html@1.35, 2008-05-12 01:36:36-04:00, stenn@whimsy.udel.edu +2 -2 + Documentation updated from Dave Mills + + html/scripts/accopt.txt@1.1, 2008-05-12 01:34:44-04:00, stenn@whimsy.udel.edu +5 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/accopt.txt + + html/scripts/accopt.txt@1.0, 2008-05-12 01:34:44-04:00, stenn@whimsy.udel.edu +0 -0 + + html/scripts/authopt.txt@1.1, 2008-05-12 01:34:44-04:00, stenn@whimsy.udel.edu +11 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/authopt.txt + + html/scripts/authopt.txt@1.0, 2008-05-12 01:34:44-04:00, stenn@whimsy.udel.edu +0 -0 + + html/scripts/clockopt.txt@1.1, 2008-05-12 01:34:44-04:00, stenn@whimsy.udel.edu +5 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/clockopt.txt + + html/scripts/clockopt.txt@1.0, 2008-05-12 01:34:44-04:00, stenn@whimsy.udel.edu +0 -0 + + html/scripts/command.txt@1.2, 2008-05-12 01:37:00-04:00, stenn@whimsy.udel.edu +1 -0 + Documentation updated from Dave Mills + + html/scripts/config.txt@1.2, 2008-05-12 01:37:00-04:00, stenn@whimsy.udel.edu +1 -1 + Documentation updated from Dave Mills + + html/scripts/confopt.txt@1.1, 2008-05-12 01:34:44-04:00, stenn@whimsy.udel.edu +11 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/confopt.txt + + html/scripts/confopt.txt@1.0, 2008-05-12 01:34:44-04:00, stenn@whimsy.udel.edu +0 -0 + + html/scripts/external.txt@1.2, 2008-05-12 01:37:01-04:00, stenn@whimsy.udel.edu +6 -4 + Documentation updated from Dave Mills + + html/scripts/install.txt@1.2, 2008-05-12 01:37:01-04:00, stenn@whimsy.udel.edu +3 -2 + Documentation updated from Dave Mills + + html/scripts/manual.txt@1.2, 2008-05-12 01:37:01-04:00, stenn@whimsy.udel.edu +2 -2 + Documentation updated from Dave Mills + + html/scripts/miscopt.txt@1.1, 2008-05-12 01:34:44-04:00, stenn@whimsy.udel.edu +16 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/miscopt.txt + + html/scripts/miscopt.txt@1.0, 2008-05-12 01:34:44-04:00, stenn@whimsy.udel.edu +0 -0 + + html/scripts/monopt.txt@1.1, 2008-05-12 01:34:44-04:00, stenn@whimsy.udel.edu +5 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/monopt.txt + + html/scripts/monopt.txt@1.0, 2008-05-12 01:34:44-04:00, stenn@whimsy.udel.edu +0 -0 + + html/sitemap.html@1.2, 2008-05-12 01:36:38-04:00, stenn@whimsy.udel.edu +4 -4 + Documentation updated from Dave Mills + + html/sntp.html@1.6, 2008-05-12 01:36:39-04:00, stenn@whimsy.udel.edu +4 -4 + Documentation updated from Dave Mills + + include/ntp.h@1.144, 2008-05-13 04:41:09-04:00, stenn@whimsy.udel.edu +61 -46 + Changes from Dave Mills + + include/ntp_control.h@1.33, 2008-05-13 04:41:11-04:00, stenn@whimsy.udel.edu +47 -47 + Changes from Dave Mills + + include/ntp_crypto.h@1.44, 2008-05-13 04:41:11-04:00, stenn@whimsy.udel.edu +11 -10 + Changes from Dave Mills + + include/ntpd.h@1.117, 2008-05-13 04:41:16-04:00, stenn@whimsy.udel.edu +22 -24 + Changes from Dave Mills + + libntp/statestr.c@1.13, 2008-05-13 04:28:39-04:00, stenn@whimsy.udel.edu +120 -105 + Changes from Dave Mills (some backward-incompatible changes) + + ntpd/ntp_config.c@1.177, 2008-05-13 05:13:24-04:00, stenn@whimsy.udel.edu +4 -3 + Changes from Dave Mills + + ntpd/ntp_control.c@1.104, 2008-05-13 05:13:25-04:00, stenn@whimsy.udel.edu +98 -123 + Changes from Dave Mills + + ntpd/ntp_crypto.c@1.122, 2008-05-13 05:13:27-04:00, stenn@whimsy.udel.edu +337 -497 + Changes from Dave Mills + + ntpd/ntp_intres.c@1.53, 2008-05-13 05:13:29-04:00, stenn@whimsy.udel.edu +3 -6 + Changes from Dave Mills + + ntpd/ntp_loopfilter.c@1.145, 2008-05-13 05:13:30-04:00, stenn@whimsy.udel.edu +163 -177 + Changes from Dave Mills + + ntpd/ntp_monitor.c@1.23, 2008-05-13 05:13:31-04:00, stenn@whimsy.udel.edu +45 -35 + Changes from Dave Mills + + ntpd/ntp_parser.c@1.26, 2008-05-13 05:13:32-04:00, stenn@whimsy.udel.edu +964 -938 + Changes from Dave Mills + + ntpd/ntp_parser.h@1.11, 2008-05-13 05:13:36-04:00, stenn@whimsy.udel.edu +227 -223 + Changes from Dave Mills + + ntpd/ntp_parser.y@1.21, 2008-05-13 05:13:37-04:00, stenn@whimsy.udel.edu +7 -2 + Changes from Dave Mills + + ntpd/ntp_peer.c@1.112, 2008-05-13 05:13:38-04:00, stenn@whimsy.udel.edu +113 -81 + Changes from Dave Mills + + ntpd/ntp_proto.c@1.272, 2008-05-13 05:13:38-04:00, stenn@whimsy.udel.edu +511 -474 + Changes from Dave Mills + + ntpd/ntp_refclock.c@1.79, 2008-05-13 05:13:40-04:00, stenn@whimsy.udel.edu +13 -40 + Changes from Dave Mills + + ntpd/ntp_request.c@1.72, 2008-05-13 05:13:41-04:00, stenn@whimsy.udel.edu +4 -12 + Changes from Dave Mills + + ntpd/ntp_timer.c@1.47, 2008-05-13 05:13:44-04:00, stenn@whimsy.udel.edu +6 -8 + Changes from Dave Mills + + ntpd/ntp_util.c@1.64, 2008-05-13 05:13:45-04:00, stenn@whimsy.udel.edu +78 -35 + Changes from Dave Mills + + ntpd/ntpd.c@1.94, 2008-05-13 05:13:47-04:00, stenn@whimsy.udel.edu +1 -7 + Changes from Dave Mills + + ntpd/refclock_acts.c@1.33, 2008-05-13 05:13:50-04:00, stenn@whimsy.udel.edu +30 -21 + Changes from Dave Mills + + ntpd/refclock_atom.c@1.56, 2008-05-13 05:13:51-04:00, stenn@whimsy.udel.edu +4 -3 + Changes from Dave Mills + + ntpd/refclock_local.c@1.17, 2008-05-13 05:13:54-04:00, stenn@whimsy.udel.edu +11 -17 + Changes from Dave Mills + + ntpq/ntpq-subs.c@1.30, 2008-05-13 04:55:14-04:00, stenn@whimsy.udel.edu +125 -88 + Changes from Dave Mills (some backward-incompatible changes) + + ntpq/ntpq.c@1.74, 2008-05-13 04:55:15-04:00, stenn@whimsy.udel.edu +11 -12 + Changes from Dave Mills (some backward-incompatible changes) + + scripts/ntp-wait.in@1.6, 2008-05-13 05:16:32-04:00, stenn@whimsy.udel.edu +23 -11 + handle the new ntpq format + +ChangeSet@1.1436.1.93, 2008-04-11 18:41:57-04:00, stenn@whimsy.udel.edu +1 -0 + Solaris _XOPEN_SOURCE updates + + configure.ac@1.400.1.1, 2008-04-11 18:41:47-04:00, stenn@whimsy.udel.edu +5 -1 + Solaris _XOPEN_SOURCE updates + +ChangeSet@1.1436.11.3, 2008-04-10 02:09:52-04:00, stenn@pogo.udel.edu +1 -0 + Changelog cleanup + + ChangeLog@1.1.8.2, 2008-04-10 02:08:57-04:00, stenn@pogo.udel.edu +2 -1 + +ChangeSet@1.1436.11.2, 2008-04-08 12:20:22+02:00, burnicki@pogo.udel.edu +1 -0 + Always sleep a little before calling doconfigure() to make sure the network is completely up. + + ntpd/ntp_intres.c@1.48.1.3, 2008-04-08 12:20:21+02:00, burnicki@pogo.udel.edu +5 -6 + Always sleep a little before calling doconfigure() to make sure the network is completely up. + +ChangeSet@1.1436.11.1, 2008-04-03 10:19:03-04:00, burnicki@pogo.udel.edu +5 -0 + [Bug 987] Wake up the resolver thread/process when a new interface has become available. + + ChangeLog@1.1.8.1, 2008-04-03 10:18:59-04:00, burnicki@pogo.udel.edu +1 -0 + [Bug 987] Wake up the resolver thread/process when a new interface has become available. + + include/ntpd.h@1.97.1.1, 2008-04-03 10:18:59-04:00, burnicki@pogo.udel.edu +5 -0 + Added vars used to wake up the resolver process/thread. + + ntpd/ntp_config.c@1.141.1.2, 2008-04-03 10:18:59-04:00, burnicki@pogo.udel.edu +34 -1 + Initialize synchronization variables when the resolver process/thread is started. + + ntpd/ntp_intres.c@1.48.1.2, 2008-04-03 10:18:59-04:00, burnicki@pogo.udel.edu +64 -65 + Enable the resolver to be woken up when a new interface has become available. + + ntpd/ntp_io.c@1.244.2.12, 2008-04-03 10:19:00-04:00, burnicki@pogo.udel.edu +25 -5 + Wake up the resolver thread/process when a new interface has become available. + +ChangeSet@1.1436.1.91, 2008-03-24 22:12:42-04:00, mayer@pogo.udel.edu +1 -0 + bugs 993 a d 959 + + ChangeLog@1.1.1.37, 2008-03-24 22:12:26-04:00, mayer@pogo.udel.edu +2 -0 + bugs 993 a d 959 + +ChangeSet@1.1436.1.90, 2008-03-24 21:41:55-04:00, mayer@pogo.udel.edu +1 -0 + [Bug 959] Refclock on Windows not properly releasing recvbuffs + + ports/winnt/ntpd/ntp_iocompletionport.c@1.21.1.4, 2008-03-24 21:41:37-04:00, mayer@pogo.udel.edu +25 -13 + [Bug 959] Refclock on Windows not properly releasing recvbuffs + +ChangeSet@1.1436.1.89, 2008-03-24 21:40:32-04:00, mayer@pogo.udel.edu +1 -0 + [Bug 993] Windows: Fix memory leak when fetching system messages + + ports/winnt/libisc/isc_strerror.c@1.4.1.1, 2008-03-24 21:40:07-04:00, mayer@pogo.udel.edu +78 -18 + [Bug 993] Windows: Fix memory leak when fetching system messages + +ChangeSet@1.1436.9.5, 2008-03-22 02:12:10-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 977] Fix mismatching #ifdefs for builds without IPv6 + + ChangeLog@1.1.6.4, 2008-03-22 02:11:57-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 977] Fix mismatching #ifdefs for builds without IPv6 + + libisc/net.c@1.8.1.1, 2008-03-22 02:11:58-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 977] Fix mismatching #ifdefs for builds without IPv6 + +ChangeSet@1.1436.9.4, 2008-03-22 02:02:36-05:00, stenn@whimsy.udel.edu +3 -0 + Update the copyright year + + ChangeLog@1.1.6.3, 2008-03-22 02:02:24-05:00, stenn@whimsy.udel.edu +8 -6 + Update the copyright year + + html/copyright.html@1.36.1.1, 2008-03-22 02:02:25-05:00, stenn@whimsy.udel.edu +1 -1 + Update the copyright year + + include/copyright.def@1.5.1.1, 2008-03-22 02:02:25-05:00, stenn@whimsy.udel.edu +1 -1 + Update the copyright year + +ChangeSet@1.1436.9.3, 2008-03-22 01:58:52-05:00, stenn@whimsy.udel.edu +5 -0 + Make autogen-generated files writable + + ntpd/Makefile.am@1.52.2.2, 2008-03-22 01:57:08-05:00, stenn@whimsy.udel.edu +1 -1 + Make autogen-generated files writable + + ntpdc/Makefile.am@1.33.1.2, 2008-03-22 01:57:09-05:00, stenn@whimsy.udel.edu +1 -1 + Make autogen-generated files writable + + ntpq/Makefile.am@1.25.1.2, 2008-03-22 01:57:10-05:00, stenn@whimsy.udel.edu +1 -1 + Make autogen-generated files writable + + sntp/Makefile.am@1.21.1.1, 2008-03-22 01:57:11-05:00, stenn@whimsy.udel.edu +1 -1 + Make autogen-generated files writable + + util/Makefile.am@1.34.1.2, 2008-03-22 01:57:11-05:00, stenn@whimsy.udel.edu +1 -1 + Make autogen-generated files writable + +ChangeSet@1.1436.10.1, 2008-03-16 09:15:13-04:00, burnicki@pogo.udel.edu +2 -0 + [Bug 957] Windows only: Let command line parameters from the Windows SCM GUI override the standard parameters from the ImagePath registry key. + + ChangeLog@1.1.7.1, 2008-03-16 09:15:10-04:00, burnicki@pogo.udel.edu +3 -0 + [Bug 957] Let command line parameters from the Windows SCM GUI override the standard parameters from the ImagePath registry key. + + ports/winnt/ntpd/ntservice.c@1.9.1.1, 2008-03-16 09:15:11-04:00, burnicki@pogo.udel.edu +11 -2 + [Bug 957] Let command line parameters from the Windows SCM GUI override the standard parameters from the ImagePath registry key. + +ChangeSet@1.1436.9.1, 2008-03-03 11:50:50+01:00, martin@pc-martin.py.meinberg.de +2 -0 + [Bug 532] nptdate timeout is too long if several servers are supplied + [Bug 698] timeBeginPeriod is called without timeEndPeriod in some NTP tools + [Bug 857] ntpdate debug mode adjusts system clock when it shouldn't + [Bug 908] ntpdate crashes sometimes + [Bug 982] ntpdate(and ntptimeset) buffer overrun if HAVE_POLL_H isn't set (dup of 908) + [Bug 997] ntpdate buffer too small and unsafe + Under Windows check whether NTP port in use under same conditions as under other OSs. + Fixed some typos and indents (tabs/spaces). + + ChangeLog@1.1.6.1, 2008-03-03 11:50:49+01:00, martin@pc-martin.py.meinberg.de +10 -0 + [Bug 532] nptdate timeout is too long if several servers are supplied + [Bug 698] timeBeginPeriod is called without timeEndPeriod in some NTP tools + [Bug 857] ntpdate debug mode adjusts system clock when it shouldn't + [Bug 908] ntpdate crashes sometimes + [Bug 982] ntpdate(and ntptimeset) buffer overrun if HAVE_POLL_H isn't set (dup of 908) + [Bug 997] ntpdate buffer too small and unsafe + Under Windows check whether NTP port in use under same conditions as under other OSs. + Fixed some typos and indents (tabs/spaces). + + ntpdate/ntpdate.c@1.59.1.3, 2008-03-03 11:50:49+01:00, martin@pc-martin.py.meinberg.de +101 -82 + [Bug 532] nptdate timeout is too long if several servers are supplied + [Bug 698] timeBeginPeriod is called without timeEndPeriod in some NTP tools + [Bug 857] ntpdate debug mode adjusts system clock when it shouldn't + [Bug 908] ntpdate crashes sometimes + [Bug 982] ntpdate(and ntptimeset) buffer overrun if HAVE_POLL_H isn't set (dup of 908) + [Bug 997] ntpdate buffer too small and unsafe + Under Windows check whether NTP port in use under same conditions as under other OSs. + Fixed some typos and indents (tabs/spaces). + +ChangeSet@1.1436.8.7, 2008-02-20 12:13:24+01:00, martin@pc-martin4. +2 -0 + [Bug 909] Define int32_t for Windows (backport from ntp-dev) + + ChangeLog@1.1.5.3, 2008-02-20 12:13:24+01:00, martin@pc-martin4. +1 -0 + [Bug 909] Define int32_t for Windows (backport from ntp-dev) + + ports/winnt/include/config.h@1.46.1.1, 2008-02-20 12:13:24+01:00, martin@pc-martin4. +2 -0 + [Bug 909] Define int32_t for Windows (backport from ntp-dev) + +ChangeSet@1.1436.8.6, 2008-02-19 11:08:55-05:00, burnicki@pogo.udel.edu +1 -0 + Fixed indentation. + + ntpd/ntp_io.c@1.244.2.11, 2008-02-19 11:08:52-05:00, burnicki@pogo.udel.edu +1 -1 + Fixed indentation. + +ChangeSet@1.1436.8.5, 2008-02-18 09:30:34-05:00, burnicki@pogo.udel.edu +1 -0 + Use new get_free_recv_buffer_alloc(). + + ports/winnt/ntpd/ntp_iocompletionport.c@1.21.1.3, 2008-02-18 09:30:31-05:00, burnicki@pogo.udel.edu +4 -4 + Use new get_free_recv_buffer_alloc(). + +ChangeSet@1.1436.8.4, 2008-02-17 17:48:29+00:00, kardel@pogo.udel.edu +1 -0 + recvbuff.c: + Bug 1000: add some pico optimizations + + libntp/recvbuff.c@1.26.1.3, 2008-02-17 17:42:21+00:00, kardel@pogo.udel.edu +5 -8 + Bug 1000: add some pico optimizations + +ChangeSet@1.1436.8.3, 2008-02-17 08:38:07+00:00, kardel@pogo.udel.edu +2 -0 + ntpd.c: + Bug 1000: avoid timer() starvation during high load conditions + ChangeLog: + Bug 1000: additionally fix timer() starvation during high load + + ChangeLog@1.1.5.2, 2008-02-17 08:37:20+00:00, kardel@pogo.udel.edu +1 -0 + Bug 1000: additionally fix timer() starvation during high load + + ntpd/ntpd.c@1.82.2.3, 2008-02-17 08:34:13+00:00, kardel@pogo.udel.edu +11 -0 + Bug 1000: avoid timer() starvation during high load conditions + +ChangeSet@1.1436.8.2, 2008-02-17 08:10:59+00:00, kardel@pogo.udel.edu +1 -0 + recvbuff.c: + Bug 1000: replenish when having expeirenced empty free lists + + libntp/recvbuff.c@1.26.1.2, 2008-02-17 08:09:37+00:00, kardel@pogo.udel.edu +1 -1 + Bug 1000: replenish when having expeirenced empty free lists + +ChangeSet@1.1436.8.1, 2008-02-17 07:31:29+00:00, kardel@pogo.udel.edu +4 -0 + recvbuff.c, recvbuff.h, ntp_io.c, ChangeLog: + Bug 1000: Potentially insufficient number of receive buffers at startup + + ChangeLog@1.1.5.1, 2008-02-17 07:29:23+00:00, kardel@pogo.udel.edu +3 -0 + Bug 1000: Potentially insufficient number of receive buffers at startup + + include/recvbuff.h@1.11.1.2, 2008-02-17 07:30:35+00:00, kardel@pogo.udel.edu +2 -1 + Bug 1000: Potentially insufficient number of receive buffers at startup + + libntp/recvbuff.c@1.26.1.1, 2008-02-17 07:30:09+00:00, kardel@pogo.udel.edu +30 -11 + Bug 1000: Potentially insufficient number of receive buffers at startup + + ntpd/ntp_io.c@1.244.2.10, 2008-02-17 07:30:50+00:00, kardel@pogo.udel.edu +6 -2 + Bug 1000: Potentially insufficient number of receive buffers at startup + +ChangeSet@1.1720, 2008-02-08 06:48:48-05:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P113 + TAG: NTP_4_2_5P113 + + ntpd/ntpd-opts.c@1.105, 2008-02-08 06:48:27-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P113 + + ntpd/ntpd-opts.h@1.105, 2008-02-08 06:48:28-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P113 + + ntpd/ntpd-opts.texi@1.104, 2008-02-08 06:48:29-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P113 + + ntpd/ntpd.1@1.104, 2008-02-08 06:48:30-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P113 + + ntpdc/ntpdc-opts.c@1.101, 2008-02-08 06:48:31-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P113 + + ntpdc/ntpdc-opts.h@1.101, 2008-02-08 06:48:31-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P113 + + ntpdc/ntpdc-opts.texi@1.100, 2008-02-08 06:48:33-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P113 + + ntpdc/ntpdc.1@1.100, 2008-02-08 06:48:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P113 + + ntpq/ntpq-opts.c@1.101, 2008-02-08 06:48:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P113 + + ntpq/ntpq-opts.h@1.101, 2008-02-08 06:48:35-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P113 + + ntpq/ntpq-opts.texi@1.100, 2008-02-08 06:48:36-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P113 + + ntpq/ntpq.1@1.100, 2008-02-08 06:48:37-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P113 + + packageinfo.sh@1.116, 2008-02-08 06:48:38-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P113 + + sntp/sntp-opts.c@1.101, 2008-02-08 06:48:39-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P113 + + sntp/sntp-opts.h@1.101, 2008-02-08 06:48:39-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P113 + + sntp/sntp-opts.texi@1.100, 2008-02-08 06:48:40-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P113 + + sntp/sntp.1@1.100, 2008-02-08 06:48:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P113 + + util/ntp-keygen-opts.c@1.104, 2008-02-08 06:48:41-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P113 + + util/ntp-keygen-opts.h@1.104, 2008-02-08 06:48:42-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P113 + + util/ntp-keygen-opts.texi@1.103, 2008-02-08 06:48:43-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P113 + + util/ntp-keygen.1@1.103, 2008-02-08 06:48:43-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P113 + +ChangeSet@1.1719, 2008-02-08 05:59:25-05:00, stenn@whimsy.udel.edu +7 -0 + Updates and cleanup from Dave Mills + + ChangeLog@1.183, 2008-02-08 05:58:31-05:00, stenn@whimsy.udel.edu +1 -0 + Updates and cleanup from Dave Mills + + html/bugs.html@1.3, 2008-02-08 05:58:32-05:00, stenn@whimsy.udel.edu +7 -6 + Updates and cleanup from Dave Mills + + html/miscopt.html@1.39, 2008-02-08 05:58:32-05:00, stenn@whimsy.udel.edu +7 -10 + Updates and cleanup from Dave Mills + + html/monopt.html@1.25, 2008-02-08 05:58:34-05:00, stenn@whimsy.udel.edu +26 -16 + Updates and cleanup from Dave Mills + + html/rate.html@1.2, 2008-02-08 05:58:34-05:00, stenn@whimsy.udel.edu +19 -19 + Updates and cleanup from Dave Mills + + ntpd/ntp_loopfilter.c@1.144, 2008-02-08 05:58:35-05:00, stenn@whimsy.udel.edu +0 -1 + Updates and cleanup from Dave Mills + + ntpd/ntp_proto.c@1.271, 2008-02-08 05:58:37-05:00, stenn@whimsy.udel.edu +50 -48 + Updates and cleanup from Dave Mills + +ChangeSet@1.1718, 2008-02-07 06:45:57-05:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P112 + TAG: NTP_4_2_5P112 + + ntpd/ntpd-opts.c@1.104, 2008-02-07 06:45:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P112 + + ntpd/ntpd-opts.h@1.104, 2008-02-07 06:45:34-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P112 + + ntpd/ntpd-opts.texi@1.103, 2008-02-07 06:45:35-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P112 + + ntpd/ntpd.1@1.103, 2008-02-07 06:45:36-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P112 + + ntpdc/ntpdc-opts.c@1.100, 2008-02-07 06:45:37-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P112 + + ntpdc/ntpdc-opts.h@1.100, 2008-02-07 06:45:38-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P112 + + ntpdc/ntpdc-opts.texi@1.99, 2008-02-07 06:45:39-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P112 + + ntpdc/ntpdc.1@1.99, 2008-02-07 06:45:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P112 + + ntpq/ntpq-opts.c@1.100, 2008-02-07 06:45:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P112 + + ntpq/ntpq-opts.h@1.100, 2008-02-07 06:45:41-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P112 + + ntpq/ntpq-opts.texi@1.99, 2008-02-07 06:45:42-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P112 + + ntpq/ntpq.1@1.99, 2008-02-07 06:45:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P112 + + packageinfo.sh@1.115, 2008-02-07 06:45:43-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P112 + + sntp/sntp-opts.c@1.100, 2008-02-07 06:45:44-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P112 + + sntp/sntp-opts.h@1.100, 2008-02-07 06:45:44-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P112 + + sntp/sntp-opts.texi@1.99, 2008-02-07 06:45:45-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P112 + + sntp/sntp.1@1.99, 2008-02-07 06:45:46-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P112 + + util/ntp-keygen-opts.c@1.103, 2008-02-07 06:45:47-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P112 + + util/ntp-keygen-opts.h@1.103, 2008-02-07 06:45:47-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P112 + + util/ntp-keygen-opts.texi@1.102, 2008-02-07 06:45:48-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P112 + + util/ntp-keygen.1@1.102, 2008-02-07 06:45:49-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P112 + +ChangeSet@1.1717, 2008-02-07 01:30:59-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 995] Remove spurious ; from ntp-keygen.c + + ChangeLog@1.182, 2008-02-07 01:30:17-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 995] Remove spurious ; from ntp-keygen.c + + util/ntp-keygen.c@1.50, 2008-02-07 01:30:19-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 995] Remove spurious ; from ntp-keygen.c + +ChangeSet@1.1716, 2008-02-01 06:46:14-05:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P111 + TAG: NTP_4_2_5P111 + + ntpd/ntpd-opts.c@1.103, 2008-02-01 06:45:53-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P111 + + ntpd/ntpd-opts.h@1.103, 2008-02-01 06:45:54-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P111 + + ntpd/ntpd-opts.texi@1.102, 2008-02-01 06:45:56-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P111 + + ntpd/ntpd.1@1.102, 2008-02-01 06:45:56-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P111 + + ntpdc/ntpdc-opts.c@1.99, 2008-02-01 06:45:57-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P111 + + ntpdc/ntpdc-opts.h@1.99, 2008-02-01 06:45:58-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P111 + + ntpdc/ntpdc-opts.texi@1.98, 2008-02-01 06:45:59-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P111 + + ntpdc/ntpdc.1@1.98, 2008-02-01 06:45:59-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P111 + + ntpq/ntpq-opts.c@1.99, 2008-02-01 06:46:00-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P111 + + ntpq/ntpq-opts.h@1.99, 2008-02-01 06:46:01-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P111 + + ntpq/ntpq-opts.texi@1.98, 2008-02-01 06:46:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P111 + + ntpq/ntpq.1@1.98, 2008-02-01 06:46:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P111 + + packageinfo.sh@1.114, 2008-02-01 06:46:04-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P111 + + sntp/sntp-opts.c@1.99, 2008-02-01 06:46:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P111 + + sntp/sntp-opts.h@1.99, 2008-02-01 06:46:05-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P111 + + sntp/sntp-opts.texi@1.98, 2008-02-01 06:46:06-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P111 + + sntp/sntp.1@1.98, 2008-02-01 06:46:07-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P111 + + util/ntp-keygen-opts.c@1.102, 2008-02-01 06:46:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P111 + + util/ntp-keygen-opts.h@1.102, 2008-02-01 06:46:08-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P111 + + util/ntp-keygen-opts.texi@1.101, 2008-02-01 06:46:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P111 + + util/ntp-keygen.1@1.101, 2008-02-01 06:46:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P111 + +ChangeSet@1.1715, 2008-02-01 01:42:27-05:00, stenn@whimsy.udel.edu +12 -0 + Cleanup from Dave Mills + + ChangeLog@1.181, 2008-02-01 01:42:01-05:00, stenn@whimsy.udel.edu +4 -3 + Cleanup from Dave Mills + + include/ntp.h@1.143, 2008-02-01 01:30:19-05:00, stenn@whimsy.udel.edu +3 -11 + Cleanup from Dave Mills + + include/ntpd.h@1.116, 2008-02-01 01:30:25-05:00, stenn@whimsy.udel.edu +1 -1 + Cleanup from Dave Mills + + ntpd/ntp_config.c@1.176, 2008-02-01 01:30:35-05:00, stenn@whimsy.udel.edu +3 -3 + Cleanup from Dave Mills + + ntpd/ntp_loopfilter.c@1.143, 2008-02-01 01:30:37-05:00, stenn@whimsy.udel.edu +3 -4 + Cleanup from Dave Mills + + ntpd/ntp_monitor.c@1.22, 2008-02-01 01:30:38-05:00, stenn@whimsy.udel.edu +11 -6 + Cleanup from Dave Mills + + ntpd/ntp_parser.c@1.25, 2008-02-01 01:30:39-05:00, stenn@whimsy.udel.edu +1 -1 + Cleanup from Dave Mills + + ntpd/ntp_parser.y@1.20, 2008-02-01 01:30:42-05:00, stenn@whimsy.udel.edu +1 -1 + Cleanup from Dave Mills + + ntpd/ntp_proto.c@1.270, 2008-02-01 01:30:43-05:00, stenn@whimsy.udel.edu +79 -116 + Cleanup from Dave Mills + + ntpd/ntp_timer.c@1.46, 2008-02-01 01:30:46-05:00, stenn@whimsy.udel.edu +0 -1 + Cleanup from Dave Mills + + ntpd/ntp_util.c@1.63, 2008-02-01 01:30:47-05:00, stenn@whimsy.udel.edu +5 -2 + Cleanup from Dave Mills + + ntpdc/ntpdc_ops.c@1.54, 2008-02-01 01:41:38-05:00, stenn@whimsy.udel.edu +1 -1 + Cleanup from Dave Mills + +ChangeSet@1.1714, 2008-01-27 21:42:55-05:00, mayer@pogo.udel.edu +2 -0 + [Bug #980] Direct ntptrace help to stdout + + ChangeLog@1.180, 2008-01-27 21:42:29-05:00, mayer@pogo.udel.edu +1 -0 + [Bug #980] + + scripts/ntptrace.in@1.6, 2008-01-27 21:41:55-05:00, mayer@pogo.udel.edu +1 -0 + [Bug #980] Direct help to stdout + +ChangeSet@1.1713, 2008-01-27 21:39:10-05:00, mayer@pogo.udel.edu +3 -0 + [Bug 959] Refclock on Windows not properly releasing recvbuffs + + ChangeLog@1.179, 2008-01-27 21:38:50-05:00, mayer@pogo.udel.edu +1 -0 + Bug 959 + + libntp/recvbuff.c@1.27, 2008-01-27 21:37:54-05:00, mayer@pogo.udel.edu +0 -4 + [Bug 959] Refclock on Windows not properly releasing recvbuffs + + ports/winnt/ntpd/ntp_iocompletionport.c@1.33, 2008-01-27 21:37:54-05:00, mayer@pogo.udel.edu +5 -9 + [Bug 959] Refclock on Windows not properly releasing recvbuffs + +ChangeSet@1.1712, 2008-01-27 21:06:48-05:00, mayer@pogo.udel.edu +1 -0 + Bug 993 + + ChangeLog@1.178, 2008-01-27 21:06:32-05:00, mayer@pogo.udel.edu +1 -0 + Bug 993 + +ChangeSet@1.1711, 2008-01-27 21:05:20-05:00, mayer@pogo.udel.edu +1 -0 + [Bug 993] Fix memory leak when fetching system messages + + ports/winnt/libisc/isc_strerror.c@1.5, 2008-01-27 21:05:04-05:00, mayer@pogo.udel.edu +78 -18 + [Bug 993] Fix memory leak when fetching system messages + +ChangeSet@1.1710, 2008-01-26 06:51:10-05:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P110 + TAG: NTP_4_2_5P110 + + ntpd/ntpd-opts.c@1.102, 2008-01-26 06:50:49-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P110 + + ntpd/ntpd-opts.h@1.102, 2008-01-26 06:50:50-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P110 + + ntpd/ntpd-opts.texi@1.101, 2008-01-26 06:50:51-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P110 + + ntpd/ntpd.1@1.101, 2008-01-26 06:50:52-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P110 + + ntpdc/ntpdc-opts.c@1.98, 2008-01-26 06:50:53-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P110 + + ntpdc/ntpdc-opts.h@1.98, 2008-01-26 06:50:53-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P110 + + ntpdc/ntpdc-opts.texi@1.97, 2008-01-26 06:50:54-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P110 + + ntpdc/ntpdc.1@1.97, 2008-01-26 06:50:55-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P110 + + ntpq/ntpq-opts.c@1.98, 2008-01-26 06:50:56-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P110 + + ntpq/ntpq-opts.h@1.98, 2008-01-26 06:50:56-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P110 + + ntpq/ntpq-opts.texi@1.97, 2008-01-26 06:50:58-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P110 + + ntpq/ntpq.1@1.97, 2008-01-26 06:50:59-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P110 + + packageinfo.sh@1.113, 2008-01-26 06:51:00-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P110 + + sntp/sntp-opts.c@1.98, 2008-01-26 06:51:01-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P110 + + sntp/sntp-opts.h@1.98, 2008-01-26 06:51:01-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P110 + + sntp/sntp-opts.texi@1.97, 2008-01-26 06:51:02-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P110 + + sntp/sntp.1@1.97, 2008-01-26 06:51:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P110 + + util/ntp-keygen-opts.c@1.101, 2008-01-26 06:51:04-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P110 + + util/ntp-keygen-opts.h@1.101, 2008-01-26 06:51:05-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P110 + + util/ntp-keygen-opts.texi@1.100, 2008-01-26 06:51:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P110 + + util/ntp-keygen.1@1.100, 2008-01-26 06:51:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P110 + +ChangeSet@1.1709, 2008-01-26 04:02:52-05:00, stenn@whimsy.udel.edu +9 -0 + much cleanup, fixes, and changes from Dave Mills + + ChangeLog@1.177, 2008-01-26 04:01:51-05:00, stenn@whimsy.udel.edu +1 -0 + much cleanup, fixes, and changes from Dave Mills + + ntpd/ntp_crypto.c@1.121, 2008-01-26 04:01:57-05:00, stenn@whimsy.udel.edu +156 -177 + much cleanup, fixes, and changes from Dave Mills + + ntpd/ntp_intres.c@1.52, 2008-01-26 04:01:58-05:00, stenn@whimsy.udel.edu +4 -3 + much cleanup, fixes, and changes from Dave Mills + + ntpd/ntp_loopfilter.c@1.142, 2008-01-26 04:02:00-05:00, stenn@whimsy.udel.edu +176 -163 + much cleanup, fixes, and changes from Dave Mills + + ntpd/ntp_monitor.c@1.21, 2008-01-26 04:02:01-05:00, stenn@whimsy.udel.edu +4 -4 + much cleanup, fixes, and changes from Dave Mills + + ntpd/ntp_peer.c@1.111, 2008-01-26 04:02:02-05:00, stenn@whimsy.udel.edu +1 -2 + much cleanup, fixes, and changes from Dave Mills + + ntpd/ntp_proto.c@1.269, 2008-01-26 04:02:04-05:00, stenn@whimsy.udel.edu +218 -142 + much cleanup, fixes, and changes from Dave Mills + + ntpd/ntp_timer.c@1.45, 2008-01-26 04:02:06-05:00, stenn@whimsy.udel.edu +22 -28 + much cleanup, fixes, and changes from Dave Mills + + ntpd/ntp_util.c@1.62, 2008-01-26 04:02:07-05:00, stenn@whimsy.udel.edu +108 -91 + much cleanup, fixes, and changes from Dave Mills + +ChangeSet@1.1708, 2008-01-26 03:46:39-05:00, stenn@whimsy.udel.edu +2 -0 + ntp_control.c: LEAPTAB is a filestamp, not an unsigned. From Dave Mills. + + ChangeLog@1.176, 2008-01-26 03:46:26-05:00, stenn@whimsy.udel.edu +1 -0 + ntp_control.c: LEAPTAB is a filestamp, not an unsigned. From Dave Mills. + + ntpd/ntp_control.c@1.103, 2008-01-26 03:46:27-05:00, stenn@whimsy.udel.edu +1 -1 + ntp_control.c: LEAPTAB is a filestamp, not an unsigned. From Dave Mills. + +ChangeSet@1.1707, 2008-01-26 03:41:54-05:00, stenn@whimsy.udel.edu +2 -0 + ntp_config.c: ntp_minpoll fixes from Dave Mills + + ChangeLog@1.175, 2008-01-26 03:41:40-05:00, stenn@whimsy.udel.edu +1 -0 + ntp_config.c: ntp_minpoll fixes from Dave Mills + + ntpd/ntp_config.c@1.175, 2008-01-26 03:41:41-05:00, stenn@whimsy.udel.edu +4 -4 + ntp_config.c: ntp_minpoll fixes from Dave Mills + +ChangeSet@1.1706, 2008-01-26 03:36:11-05:00, stenn@whimsy.udel.edu +2 -0 + ntp-keygen updated from Dave Mills + + ChangeLog@1.174, 2008-01-26 03:35:57-05:00, stenn@whimsy.udel.edu +1 -0 + ntp-keygen updated from Dave Mills + + util/ntp-keygen.c@1.49, 2008-01-26 03:35:58-05:00, stenn@whimsy.udel.edu +614 -460 + ntp-keygen updated from Dave Mills + +ChangeSet@1.1705, 2008-01-26 03:30:14-05:00, stenn@whimsy.udel.edu +4 -0 + refresh epoch, throttle, and leap cleanup from Dave Mills + + ChangeLog@1.173, 2008-01-26 03:29:59-05:00, stenn@whimsy.udel.edu +1 -0 + refresh epoch, throttle, and leap cleanup from Dave Mills + + include/ntp.h@1.142, 2008-01-26 03:29:44-05:00, stenn@whimsy.udel.edu +9 -14 + refresh epoch, throttle, and leap cleanup from Dave Mills + + include/ntp_crypto.h@1.43, 2008-01-26 03:29:47-05:00, stenn@whimsy.udel.edu +1 -0 + refresh epoch, throttle, and leap cleanup from Dave Mills + + include/ntpd.h@1.115, 2008-01-26 03:29:52-05:00, stenn@whimsy.udel.edu +7 -16 + refresh epoch, throttle, and leap cleanup from Dave Mills + +ChangeSet@1.1704, 2008-01-26 03:16:13-05:00, stenn@whimsy.udel.edu +110 -0 + Documentation updates from Dave Mills + + BitKeeper/deleted/.del-footer.txt@1.2, 2007-12-31 21:17:16-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/build/scripts/footer.txt + + BitKeeper/deleted/.del-groups.html@1.2, 2008-01-26 02:29:44-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/groups.html + + BitKeeper/deleted/.del-ldisc.html@1.13, 2008-01-26 02:40:16-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/ldisc.html + + BitKeeper/deleted/.del-links10.txt@1.2, 2007-12-31 21:17:17-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/build/scripts/links10.txt + + BitKeeper/deleted/.del-links10.txt~2eb1ee39ee3ae750@1.3, 2008-01-26 02:29:49-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/scripts/links10.txt + + BitKeeper/deleted/.del-links11.txt@1.2, 2007-12-31 21:17:18-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/build/scripts/links11.txt + + BitKeeper/deleted/.del-links11.txt~6bbb69abc176cdfa@1.3, 2008-01-26 02:29:51-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/scripts/links11.txt + + BitKeeper/deleted/.del-links12.txt@1.2, 2007-12-31 21:17:19-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/build/scripts/links12.txt + + BitKeeper/deleted/.del-links12.txt~44ae7fa96b25e3d8@1.2, 2008-01-26 02:29:52-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/scripts/links12.txt + + BitKeeper/deleted/.del-links7.txt@1.2, 2007-12-31 21:17:20-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/build/scripts/links7.txt + + BitKeeper/deleted/.del-links7.txt~82fadd0532b4ef1f@1.5, 2008-01-26 02:29:53-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/scripts/links7.txt + + BitKeeper/deleted/.del-links8.txt@1.2, 2007-12-31 21:17:21-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/build/scripts/links8.txt + + BitKeeper/deleted/.del-links8.txt~af6a09ad412e8a40@1.3, 2008-01-26 02:29:54-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/scripts/links8.txt + + BitKeeper/deleted/.del-links9.txt@1.2, 2007-12-31 21:17:23-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/build/scripts/links9.txt + + BitKeeper/deleted/.del-links9.txt~8709272ab9515ec0@1.4, 2008-01-26 02:29:56-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/scripts/links9.txt + + BitKeeper/deleted/.del-measure.html@1.12, 2008-01-26 02:29:47-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/measure.html + + BitKeeper/deleted/.del-mx4200data.html@1.12, 2008-01-26 02:29:48-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/mx4200data.html + + BitKeeper/deleted/.del-netbsd@1.4, 2008-01-26 02:29:46-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/hints/netbsd + + html/hints/netbsd@1.3, 2007-12-31 20:50:26-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/netbsd -> html/hints/netbsd + + BitKeeper/deleted/.del-notes.html@1.19, 2008-01-26 02:40:18-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/notes.html + + BitKeeper/deleted/.del-patches.html@1.19, 2008-01-26 02:40:19-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/patches.html + + html/patches.html@1.18, 2007-12-31 21:24:18-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/patches.html -> html/patches.html + + BitKeeper/deleted/.del-porting.html@1.15, 2008-01-26 02:40:21-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/porting.html + + html/porting.html@1.14, 2007-12-31 21:24:20-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/porting.html -> html/porting.html + + BitKeeper/deleted/.del-style.css@1.2, 2007-12-31 21:17:24-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: html/build/scripts/style.css + + ChangeLog@1.172, 2008-01-26 03:15:53-05:00, stenn@whimsy.udel.edu +1 -0 + Documentation updates from Dave Mills + + html/accopt.html@1.25, 2008-01-26 03:11:40-05:00, stenn@whimsy.udel.edu +3 -3 + Documentation updates from Dave Mills + + html/assoc.html@1.26, 2008-01-26 03:11:41-05:00, stenn@whimsy.udel.edu +9 -9 + Documentation updates from Dave Mills + + html/audio.html@1.20, 2008-01-26 03:11:42-05:00, stenn@whimsy.udel.edu +3 -2 + Documentation updates from Dave Mills + + html/authopt.html@1.46, 2008-01-26 03:11:43-05:00, stenn@whimsy.udel.edu +123 -57 + Documentation updates from Dave Mills + + html/bugs.html@1.2, 2008-01-26 03:11:43-05:00, stenn@whimsy.udel.edu +8 -10 + Documentation updates from Dave Mills + + html/build.html@1.22, 2008-01-26 03:11:44-05:00, stenn@whimsy.udel.edu +53 -76 + Documentation updates from Dave Mills + + html/build.html@1.21, 2007-12-31 21:24:13-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/build.html -> html/build.html + + html/clockopt.html@1.20, 2008-01-26 03:11:45-05:00, stenn@whimsy.udel.edu +4 -3 + Documentation updates from Dave Mills + + html/config.html@1.20, 2008-01-26 03:11:45-05:00, stenn@whimsy.udel.edu +48 -47 + Documentation updates from Dave Mills + + html/config.html@1.19, 2007-12-31 21:24:15-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/config.html -> html/config.html + + html/confopt.html@1.39, 2008-01-26 03:11:46-05:00, stenn@whimsy.udel.edu +2 -2 + Documentation updates from Dave Mills + + html/copyright.html@1.38, 2008-01-26 03:11:46-05:00, stenn@whimsy.udel.edu +3 -4 + Documentation updates from Dave Mills + + html/debug.html@1.24, 2008-01-26 03:11:47-05:00, stenn@whimsy.udel.edu +2 -2 + Documentation updates from Dave Mills + + html/description_files/description.jpg@1.1, 2008-01-26 03:04:39-05:00, stenn@whimsy.udel.edu +761 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/description_files/description.jpg + + html/description_files/description.jpg@1.0, 2008-01-26 03:04:39-05:00, stenn@whimsy.udel.edu +0 -0 + + html/drivers/driver10.html@1.12, 2008-01-26 03:12:05-05:00, stenn@whimsy.udel.edu +46 -46 + Documentation updates from Dave Mills + + html/drivers/driver11.html@1.12, 2008-01-26 03:12:06-05:00, stenn@whimsy.udel.edu +55 -57 + Documentation updates from Dave Mills + + html/drivers/driver18.html@1.16, 2008-01-26 03:12:06-05:00, stenn@whimsy.udel.edu +2 -2 + Documentation updates from Dave Mills + + html/drivers/driver19.html@1.11, 2008-01-26 03:12:07-05:00, stenn@whimsy.udel.edu +48 -48 + Documentation updates from Dave Mills + + html/drivers/driver27.html@1.15, 2008-01-26 03:12:08-05:00, stenn@whimsy.udel.edu +0 -2 + Documentation updates from Dave Mills + + html/drivers/driver34.html@1.12, 2008-01-26 03:12:08-05:00, stenn@whimsy.udel.edu +67 -105 + Documentation updates from Dave Mills + + html/drivers/driver4.html@1.13, 2008-01-26 03:12:08-05:00, stenn@whimsy.udel.edu +3 -4 + Documentation updates from Dave Mills + + html/drivers/driver9.html@1.14, 2008-01-26 03:12:09-05:00, stenn@whimsy.udel.edu +50 -51 + Documentation updates from Dave Mills + + html/drivers/mx4200data.html@1.1, 2008-01-26 03:04:40-05:00, stenn@whimsy.udel.edu +1074 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/drivers/mx4200data.html + + html/drivers/mx4200data.html@1.0, 2008-01-26 03:04:40-05:00, stenn@whimsy.udel.edu +0 -0 + + html/gadget.html@1.2, 2008-01-26 03:11:48-05:00, stenn@whimsy.udel.edu +2 -1 + Documentation updates from Dave Mills + + html/genkeys.html@1.1, 2008-01-26 03:04:37-05:00, stenn@whimsy.udel.edu +94 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/genkeys.html + + html/genkeys.html@1.0, 2008-01-26 03:04:37-05:00, stenn@whimsy.udel.edu +0 -0 + + html/hints.html@1.17, 2008-01-26 03:11:48-05:00, stenn@whimsy.udel.edu +17 -16 + Documentation updates from Dave Mills + + html/hints.html@1.16, 2007-12-31 21:24:16-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints.html -> html/hints.html + + html/hints/a-ux@1.4, 2007-12-31 20:50:23-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/a-ux -> html/hints/a-ux + + html/hints/aix@1.4, 2007-12-31 20:50:23-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/aix -> html/hints/aix + + html/hints/bsdi@1.4, 2007-12-31 20:50:23-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/bsdi -> html/hints/bsdi + + html/hints/changes@1.4, 2007-12-31 20:50:23-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/changes -> html/hints/changes + + html/hints/decosf1@1.4, 2007-12-31 20:50:24-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/decosf1 -> html/hints/decosf1 + + html/hints/decosf2@1.4, 2007-12-31 20:50:24-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/decosf2 -> html/hints/decosf2 + + html/hints/freebsd@1.4, 2007-12-31 20:50:24-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/freebsd -> html/hints/freebsd + + html/hints/hpux@1.4, 2007-12-31 20:50:25-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/hpux -> html/hints/hpux + + html/hints/linux@1.4, 2007-12-31 20:50:25-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/linux -> html/hints/linux + + html/hints/mpeix@1.4, 2007-12-31 20:50:25-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/mpeix -> html/hints/mpeix + + html/hints/notes-xntp-v3@1.4, 2007-12-31 20:50:26-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/notes-xntp-v3 -> html/hints/notes-xntp-v3 + + html/hints/parse@1.6, 2008-01-26 03:12:09-05:00, stenn@whimsy.udel.edu +1 -1 + Documentation updates from Dave Mills + + html/hints/parse@1.5, 2007-12-31 20:50:26-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/parse -> html/hints/parse + + html/hints/refclocks@1.4, 2007-12-31 20:50:26-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/refclocks -> html/hints/refclocks + + html/hints/rs6000@1.4, 2007-12-31 20:50:26-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/rs6000 -> html/hints/rs6000 + + html/hints/sco.html@1.10, 2008-01-26 03:12:09-05:00, stenn@whimsy.udel.edu +10 -9 + Documentation updates from Dave Mills + + html/hints/sco.html@1.9, 2007-12-31 20:50:27-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/sco.html -> html/hints/sco.html + + html/hints/sgi@1.4, 2007-12-31 20:50:27-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/sgi -> html/hints/sgi + + html/hints/solaris-dosynctodr.html@1.7, 2008-01-26 03:12:10-05:00, stenn@whimsy.udel.edu +11 -11 + Documentation updates from Dave Mills + + html/hints/solaris-dosynctodr.html@1.6, 2007-12-31 20:50:27-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/solaris-dosynctodr.html -> html/hints/solaris-dosynctodr.html + + html/hints/solaris.html@1.10, 2008-01-26 03:12:10-05:00, stenn@whimsy.udel.edu +1 -1 + Documentation updates from Dave Mills + + html/hints/solaris.html@1.9, 2007-12-31 20:50:28-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/solaris.html -> html/hints/solaris.html + + html/hints/solaris.xtra.4023118@1.4, 2007-12-31 20:50:28-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/solaris.xtra.4023118 -> html/hints/solaris.xtra.4023118 + + html/hints/solaris.xtra.4095849@1.4, 2007-12-31 20:50:28-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/solaris.xtra.4095849 -> html/hints/solaris.xtra.4095849 + + html/hints/solaris.xtra.S99ntpd@1.5, 2007-12-31 20:50:29-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/solaris.xtra.S99ntpd -> html/hints/solaris.xtra.S99ntpd + + html/hints/solaris.xtra.patchfreq@1.4, 2007-12-31 20:50:29-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/solaris.xtra.patchfreq -> html/hints/solaris.xtra.patchfreq + + html/hints/sun4@1.4, 2007-12-31 20:50:30-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/sun4 -> html/hints/sun4 + + html/hints/svr4-dell@1.4, 2007-12-31 20:50:30-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/svr4-dell -> html/hints/svr4-dell + + html/hints/svr4_package@1.4, 2007-12-31 20:50:30-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/svr4_package -> html/hints/svr4_package + + html/hints/todo@1.4, 2007-12-31 20:50:30-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/todo -> html/hints/todo + + html/hints/vxworks.html@1.9, 2008-01-26 03:12:10-05:00, stenn@whimsy.udel.edu +64 -61 + Documentation updates from Dave Mills + + html/hints/vxworks.html@1.8, 2007-12-31 20:50:31-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/vxworks.html -> html/hints/vxworks.html + + html/hints/winnt.html@1.18, 2008-01-26 03:12:11-05:00, stenn@whimsy.udel.edu +142 -239 + Documentation updates from Dave Mills + + html/hints/winnt.html@1.17, 2007-12-31 20:50:31-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/hints/winnt.html -> html/hints/winnt.html + + html/howto.html@1.19, 2008-01-26 03:11:49-05:00, stenn@whimsy.udel.edu +31 -52 + Documentation updates from Dave Mills + + html/index.html@1.36, 2008-01-26 03:11:50-05:00, stenn@whimsy.udel.edu +28 -66 + Documentation updates from Dave Mills + + html/kern.html@1.15, 2008-01-26 03:11:51-05:00, stenn@whimsy.udel.edu +4 -5 + Documentation updates from Dave Mills + + html/kernpps.html@1.1, 2008-01-26 03:04:38-05:00, stenn@whimsy.udel.edu +47 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/kernpps.html + + html/kernpps.html@1.0, 2008-01-26 03:04:38-05:00, stenn@whimsy.udel.edu +0 -0 + + html/keygen.html@1.11, 2008-01-26 03:11:52-05:00, stenn@whimsy.udel.edu +17 -25 + Documentation updates from Dave Mills + + html/manyopt.html@1.16, 2008-01-26 03:11:52-05:00, stenn@whimsy.udel.edu +22 -32 + Documentation updates from Dave Mills + + html/miscopt.html@1.38, 2008-01-26 03:11:53-05:00, stenn@whimsy.udel.edu +8 -3 + Documentation updates from Dave Mills + + html/monopt.html@1.24, 2008-01-26 03:11:54-05:00, stenn@whimsy.udel.edu +360 -104 + Documentation updates from Dave Mills + + html/msyslog.html@1.7, 2008-01-26 03:11:55-05:00, stenn@whimsy.udel.edu +2 -2 + Documentation updates from Dave Mills + + html/ntpd.html@1.41, 2008-01-26 03:11:56-05:00, stenn@whimsy.udel.edu +2 -2 + Documentation updates from Dave Mills + + html/ntpdc.html@1.29, 2008-01-26 03:11:56-05:00, stenn@whimsy.udel.edu +2 -2 + Documentation updates from Dave Mills + + html/ntpdsim.html@1.6, 2008-01-26 03:11:57-05:00, stenn@whimsy.udel.edu +2 -2 + Documentation updates from Dave Mills + + html/ntpdsim_new.html@1.2, 2008-01-26 03:11:58-05:00, stenn@whimsy.udel.edu +4 -4 + Documentation updates from Dave Mills + + html/ntpq.html@1.28, 2008-01-26 03:11:58-05:00, stenn@whimsy.udel.edu +2 -2 + Documentation updates from Dave Mills + + html/ntptrace.html@1.14, 2008-01-26 03:11:59-05:00, stenn@whimsy.udel.edu +3 -2 + Documentation updates from Dave Mills + + html/pic/broad.gif@1.1, 2008-01-26 03:04:40-05:00, stenn@whimsy.udel.edu +129 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/broad.gif + + html/pic/broad.gif@1.0, 2008-01-26 03:04:40-05:00, stenn@whimsy.udel.edu +0 -0 + + html/pic/peer.gif@1.1, 2008-01-26 03:04:40-05:00, stenn@whimsy.udel.edu +111 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/peer.gif + + html/pic/peer.gif@1.0, 2008-01-26 03:04:40-05:00, stenn@whimsy.udel.edu +0 -0 + + html/pps.html@1.19, 2008-01-26 03:11:59-05:00, stenn@whimsy.udel.edu +26 -20 + Documentation updates from Dave Mills + + html/prefer.html@1.16, 2008-01-26 03:12:00-05:00, stenn@whimsy.udel.edu +2 -10 + Documentation updates from Dave Mills + + html/quick.html@1.18, 2008-01-26 03:12:01-05:00, stenn@whimsy.udel.edu +26 -23 + Documentation updates from Dave Mills + + html/quick.html@1.17, 2007-12-31 21:24:21-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: html/build/quick.html -> html/quick.html + + html/rate.html@1.1, 2008-01-26 03:04:38-05:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/rate.html + + html/rate.html@1.0, 2008-01-26 03:04:38-05:00, stenn@whimsy.udel.edu +0 -0 + + html/rdebug.html@1.16, 2008-01-26 03:12:02-05:00, stenn@whimsy.udel.edu +3 -4 + Documentation updates from Dave Mills + + html/refclock.html@1.33, 2008-01-26 03:12:02-05:00, stenn@whimsy.udel.edu +17 -30 + Documentation updates from Dave Mills + + html/release.html@1.34, 2008-01-26 03:12:03-05:00, stenn@whimsy.udel.edu +23 -33 + Documentation updates from Dave Mills + + html/scripts/audio.txt@1.1, 2008-01-26 03:04:41-05:00, stenn@whimsy.udel.edu +7 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/audio.txt + + html/scripts/audio.txt@1.0, 2008-01-26 03:04:41-05:00, stenn@whimsy.udel.edu +0 -0 + + html/scripts/command.txt@1.1, 2008-01-26 03:04:41-05:00, stenn@whimsy.udel.edu +10 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/command.txt + + html/scripts/command.txt@1.0, 2008-01-26 03:04:41-05:00, stenn@whimsy.udel.edu +0 -0 + + html/scripts/config.txt@1.1, 2008-01-26 03:04:41-05:00, stenn@whimsy.udel.edu +7 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/config.txt + + html/scripts/config.txt@1.0, 2008-01-26 03:04:41-05:00, stenn@whimsy.udel.edu +0 -0 + + html/scripts/external.txt@1.1, 2008-01-26 03:04:42-05:00, stenn@whimsy.udel.edu +13 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/external.txt + + html/scripts/external.txt@1.0, 2008-01-26 03:04:42-05:00, stenn@whimsy.udel.edu +0 -0 + + html/scripts/install.txt@1.1, 2008-01-26 03:04:42-05:00, stenn@whimsy.udel.edu +11 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/install.txt + + html/scripts/install.txt@1.0, 2008-01-26 03:04:42-05:00, stenn@whimsy.udel.edu +0 -0 + + html/scripts/manual.txt@1.1, 2008-01-26 03:04:42-05:00, stenn@whimsy.udel.edu +13 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/manual.txt + + html/scripts/manual.txt@1.0, 2008-01-26 03:04:42-05:00, stenn@whimsy.udel.edu +0 -0 + + html/scripts/misc.txt@1.1, 2008-01-26 03:04:42-05:00, stenn@whimsy.udel.edu +9 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/misc.txt + + html/scripts/misc.txt@1.0, 2008-01-26 03:04:42-05:00, stenn@whimsy.udel.edu +0 -0 + + html/scripts/refclock.txt@1.1, 2008-01-26 03:04:42-05:00, stenn@whimsy.udel.edu +7 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/refclock.txt + + html/scripts/refclock.txt@1.0, 2008-01-26 03:04:42-05:00, stenn@whimsy.udel.edu +0 -0 + + html/sitemap.html@1.1, 2008-01-26 03:04:38-05:00, stenn@whimsy.udel.edu +34 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/sitemap.html + + html/sitemap.html@1.0, 2008-01-26 03:04:38-05:00, stenn@whimsy.udel.edu +0 -0 + + html/sntp.html@1.5, 2008-01-26 03:12:04-05:00, stenn@whimsy.udel.edu +2 -3 + Documentation updates from Dave Mills + + html/tickadj.html@1.15, 2008-01-26 03:12:05-05:00, stenn@whimsy.udel.edu +8 -11 + Documentation updates from Dave Mills + +ChangeSet@1.1436.7.1, 2008-01-26 06:43:33+00:00, kardel@pogo.udel.edu +3 -0 + ntpdbase-opts.def, ChangeLog, cmd_args.c: + remove minimum interface update interval restriction + + ChangeLog@1.1.4.1, 2008-01-26 06:42:11+00:00, kardel@pogo.udel.edu +2 -0 + remove minimum interface update interval restriction + + ntpd/cmd_args.c@1.45.3.3, 2008-01-26 06:42:47+00:00, kardel@pogo.udel.edu +2 -2 + remove minimum interface update interval restriction + + ntpd/ntpdbase-opts.def@1.10.1.1, 2008-01-26 06:43:10+00:00, kardel@pogo.udel.edu +1 -1 + remove minimum interface update interval restriction + +ChangeSet@1.1703, 2007-12-19 06:45:26-05:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P109 + TAG: NTP_4_2_5P109 + + ntpd/ntpd-opts.c@1.101, 2007-12-19 06:45:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P109 + + ntpd/ntpd-opts.h@1.101, 2007-12-19 06:45:04-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P109 + + ntpd/ntpd-opts.texi@1.100, 2007-12-19 06:45:05-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P109 + + ntpd/ntpd.1@1.100, 2007-12-19 06:45:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P109 + + ntpdc/ntpdc-opts.c@1.97, 2007-12-19 06:45:07-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P109 + + ntpdc/ntpdc-opts.h@1.97, 2007-12-19 06:45:07-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P109 + + ntpdc/ntpdc-opts.texi@1.96, 2007-12-19 06:45:09-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P109 + + ntpdc/ntpdc.1@1.96, 2007-12-19 06:45:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P109 + + ntpq/ntpq-opts.c@1.97, 2007-12-19 06:45:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P109 + + ntpq/ntpq-opts.h@1.97, 2007-12-19 06:45:11-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P109 + + ntpq/ntpq-opts.texi@1.96, 2007-12-19 06:45:12-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P109 + + ntpq/ntpq.1@1.96, 2007-12-19 06:45:13-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P109 + + packageinfo.sh@1.112, 2007-12-19 06:45:14-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P109 + + sntp/sntp-opts.c@1.97, 2007-12-19 06:45:15-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P109 + + sntp/sntp-opts.h@1.97, 2007-12-19 06:45:16-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P109 + + sntp/sntp-opts.texi@1.96, 2007-12-19 06:45:17-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P109 + + sntp/sntp.1@1.96, 2007-12-19 06:45:17-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P109 + + util/ntp-keygen-opts.c@1.100, 2007-12-19 06:45:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P109 + + util/ntp-keygen-opts.h@1.100, 2007-12-19 06:45:18-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P109 + + util/ntp-keygen-opts.texi@1.99, 2007-12-19 06:45:20-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P109 + + util/ntp-keygen.1@1.99, 2007-12-19 06:45:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P109 + +ChangeSet@1.1702, 2007-12-18 12:05:55-05:00, burnicki@pogo.udel.edu +1 -0 + Account for changes due to bug 918. + + ports/winnt/libntp/libntp.dsp@1.32, 2007-12-18 12:05:52-05:00, burnicki@pogo.udel.edu +1 -1 + Account for changes due to bug 918. + +ChangeSet@1.1701, 2007-12-18 06:49:15-05:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P108 + TAG: NTP_4_2_5P108 + + ntpd/ntpd-opts.c@1.100, 2007-12-18 06:48:52-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P108 + + ntpd/ntpd-opts.h@1.100, 2007-12-18 06:48:52-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P108 + + ntpd/ntpd-opts.texi@1.99, 2007-12-18 06:48:53-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P108 + + ntpd/ntpd.1@1.99, 2007-12-18 06:48:54-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P108 + + ntpdc/ntpdc-opts.c@1.96, 2007-12-18 06:48:56-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P108 + + ntpdc/ntpdc-opts.h@1.96, 2007-12-18 06:48:56-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P108 + + ntpdc/ntpdc-opts.texi@1.95, 2007-12-18 06:48:57-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P108 + + ntpdc/ntpdc.1@1.95, 2007-12-18 06:48:58-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P108 + + ntpq/ntpq-opts.c@1.96, 2007-12-18 06:48:58-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P108 + + ntpq/ntpq-opts.h@1.96, 2007-12-18 06:48:59-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P108 + + ntpq/ntpq-opts.texi@1.95, 2007-12-18 06:49:01-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P108 + + ntpq/ntpq.1@1.95, 2007-12-18 06:49:01-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P108 + + packageinfo.sh@1.111, 2007-12-18 06:49:02-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P108 + + sntp/sntp-opts.c@1.96, 2007-12-18 06:49:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P108 + + sntp/sntp-opts.h@1.96, 2007-12-18 06:49:04-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P108 + + sntp/sntp-opts.texi@1.95, 2007-12-18 06:49:05-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P108 + + sntp/sntp.1@1.95, 2007-12-18 06:49:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P108 + + util/ntp-keygen-opts.c@1.99, 2007-12-18 06:49:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P108 + + util/ntp-keygen-opts.h@1.99, 2007-12-18 06:49:07-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P108 + + util/ntp-keygen-opts.texi@1.98, 2007-12-18 06:49:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P108 + + util/ntp-keygen.1@1.98, 2007-12-18 06:49:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P108 + +ChangeSet@1.1700, 2007-12-18 04:02:42-05:00, stenn@whimsy.udel.edu +3 -0 + [Bug 918] Only use a native md5.h if MD5Init() is available + + ChangeLog@1.171, 2007-12-18 04:02:00-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 918] Only use a native md5.h if MD5Init() is available + + configure.ac@1.413, 2007-12-18 04:02:01-05:00, stenn@whimsy.udel.edu +2 -7 + [Bug 918] Only use a native md5.h if MD5Init() is available + + include/ntp_md5.h@1.3, 2007-12-18 04:02:03-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 918] Only use a native md5.h if MD5Init() is available + +ChangeSet@1.1689.1.1, 2007-12-16 12:16:08-05:00, mayer@pogo.udel.edu +1 -0 + Bug #830 Fix interface count + + ntpd/ntp_io.c@1.271, 2007-12-16 12:15:38-05:00, mayer@pogo.udel.edu +3 -1 + Bug #830 Fix interface count + +ChangeSet@1.1698, 2007-12-16 06:49:22-05:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P107 + TAG: NTP_4_2_5P107 + + ntpd/ntpd-opts.c@1.99, 2007-12-16 06:48:59-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P107 + + ntpd/ntpd-opts.h@1.99, 2007-12-16 06:49:00-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P107 + + ntpd/ntpd-opts.texi@1.98, 2007-12-16 06:49:01-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P107 + + ntpd/ntpd.1@1.98, 2007-12-16 06:49:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P107 + + ntpdc/ntpdc-opts.c@1.95, 2007-12-16 06:49:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P107 + + ntpdc/ntpdc-opts.h@1.95, 2007-12-16 06:49:03-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P107 + + ntpdc/ntpdc-opts.texi@1.94, 2007-12-16 06:49:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P107 + + ntpdc/ntpdc.1@1.94, 2007-12-16 06:49:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P107 + + ntpq/ntpq-opts.c@1.95, 2007-12-16 06:49:07-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P107 + + ntpq/ntpq-opts.h@1.95, 2007-12-16 06:49:08-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P107 + + ntpq/ntpq-opts.texi@1.94, 2007-12-16 06:49:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P107 + + ntpq/ntpq.1@1.94, 2007-12-16 06:49:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P107 + + packageinfo.sh@1.110, 2007-12-16 06:49:10-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P107 + + sntp/sntp-opts.c@1.95, 2007-12-16 06:49:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P107 + + sntp/sntp-opts.h@1.95, 2007-12-16 06:49:12-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P107 + + sntp/sntp-opts.texi@1.94, 2007-12-16 06:49:13-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P107 + + sntp/sntp.1@1.94, 2007-12-16 06:49:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P107 + + util/ntp-keygen-opts.c@1.98, 2007-12-16 06:49:15-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P107 + + util/ntp-keygen-opts.h@1.98, 2007-12-16 06:49:16-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P107 + + util/ntp-keygen-opts.texi@1.97, 2007-12-16 06:49:17-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P107 + + util/ntp-keygen.1@1.97, 2007-12-16 06:49:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P107 + +ChangeSet@1.1697, 2007-12-16 04:51:58-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 979] Provide ntptimeval if it is not otherwise present + + ChangeLog@1.170, 2007-12-16 04:51:09-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 979] Provide ntptimeval if it is not otherwise present + + include/ntp_syscall.h@1.8, 2007-12-16 04:51:10-05:00, stenn@whimsy.udel.edu +9 -0 + [Bug 979] Provide ntptimeval if it is not otherwise present + +ChangeSet@1.1696, 2007-12-16 02:44:58-05:00, stenn@whimsy.udel.edu +1 -0 + code cleanup + + ntpd/ntpd.c@1.93, 2007-12-16 02:44:42-05:00, stenn@whimsy.udel.edu +37 -35 + code cleanup + +ChangeSet@1.1695, 2007-12-15 23:29:17-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 634] Re-instantiate syslog() and logfiles after the daemon fork + + ChangeLog@1.169, 2007-12-15 23:29:00-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 634] Re-instantiate syslog() and logfiles after the daemon fork + + ntpd/ntpd.c@1.92, 2007-12-15 23:29:00-05:00, stenn@whimsy.udel.edu +4 -0 + [Bug 634] Re-instantiate syslog() and logfiles after the daemon fork + +ChangeSet@1.1694, 2007-12-15 22:41:36-05:00, stenn@whimsy.udel.edu +1 -0 + We no longer need to check for MD5Init() + + configure.ac@1.412, 2007-12-15 22:41:25-05:00, stenn@whimsy.udel.edu +0 -1 + We no longer need to check for MD5Init() + +ChangeSet@1.1693, 2007-12-15 07:33:48-05:00, stenn@whimsy.udel.edu +4 -0 + [Bug 952] Use md5 code with a friendlier license + + BitKeeper/deleted/.del-md5c.c@1.9, 2007-12-15 06:19:02-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: libntp/md5c.c + + BitKeeper/deleted/.del-rsa_md5.h@1.8, 2007-12-15 06:20:04-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: include/rsa_md5.h + + include/Makefile.am@1.29, 2007-12-15 07:33:24-05:00, stenn@whimsy.udel.edu +0 -1 + [Bug 952] Use md5 code with a friendlier license + + include/ntp_md5.h@1.2, 2007-12-15 07:33:25-05:00, stenn@whimsy.udel.edu +5 -1 + [Bug 952] Use md5 code with a friendlier license + +ChangeSet@1.1692, 2007-12-15 06:18:07-05:00, stenn@whimsy.udel.edu +5 -0 + [Bug 952] Use md5 code with a friendlier license + + ChangeLog@1.168, 2007-12-15 06:17:44-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 952] Use md5 code with a friendlier license + + include/isc/Makefile.am@1.7, 2007-12-15 06:17:44-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 952] Use md5 code with a friendlier license + + include/isc/md5.h@1.1, 2007-12-15 06:12:56-05:00, stenn@whimsy.udel.edu +73 -0 + BitKeeper file /deacon/backroom/ntp-dev-hms/include/isc/md5.h + + include/isc/md5.h@1.0, 2007-12-15 06:12:56-05:00, stenn@whimsy.udel.edu +0 -0 + + libisc/md5.c@1.1, 2007-12-15 06:12:56-05:00, stenn@whimsy.udel.edu +251 -0 + BitKeeper file /deacon/backroom/ntp-dev-hms/libisc/md5.c + + libisc/md5.c@1.0, 2007-12-15 06:12:56-05:00, stenn@whimsy.udel.edu +0 -0 + + libntp/Makefile.am@1.40, 2007-12-15 06:17:44-05:00, stenn@whimsy.udel.edu +2 -2 + [Bug 952] Use md5 code with a friendlier license + +ChangeSet@1.1691, 2007-12-13 06:46:42-05:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P106 + TAG: NTP_4_2_5P106 + + ntpd/ntpd-opts.c@1.98, 2007-12-13 06:46:22-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P106 + + ntpd/ntpd-opts.h@1.98, 2007-12-13 06:46:23-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P106 + + ntpd/ntpd-opts.texi@1.97, 2007-12-13 06:46:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P106 + + ntpd/ntpd.1@1.97, 2007-12-13 06:46:25-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P106 + + ntpdc/ntpdc-opts.c@1.94, 2007-12-13 06:46:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P106 + + ntpdc/ntpdc-opts.h@1.94, 2007-12-13 06:46:27-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P106 + + ntpdc/ntpdc-opts.texi@1.93, 2007-12-13 06:46:28-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P106 + + ntpdc/ntpdc.1@1.93, 2007-12-13 06:46:29-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P106 + + ntpq/ntpq-opts.c@1.94, 2007-12-13 06:46:29-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P106 + + ntpq/ntpq-opts.h@1.94, 2007-12-13 06:46:30-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P106 + + ntpq/ntpq-opts.texi@1.93, 2007-12-13 06:46:31-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P106 + + ntpq/ntpq.1@1.93, 2007-12-13 06:46:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P106 + + packageinfo.sh@1.109, 2007-12-13 06:46:33-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P106 + + sntp/sntp-opts.c@1.94, 2007-12-13 06:46:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P106 + + sntp/sntp-opts.h@1.94, 2007-12-13 06:46:34-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P106 + + sntp/sntp-opts.texi@1.93, 2007-12-13 06:46:35-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P106 + + sntp/sntp.1@1.93, 2007-12-13 06:46:35-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P106 + + util/ntp-keygen-opts.c@1.97, 2007-12-13 06:46:36-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P106 + + util/ntp-keygen-opts.h@1.97, 2007-12-13 06:46:37-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P106 + + util/ntp-keygen-opts.texi@1.96, 2007-12-13 06:46:38-05:00, stenn@whimsy.udel.edu +3 -4 + NTP_4_2_5P106 + + util/ntp-keygen.1@1.96, 2007-12-13 06:46:38-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P106 + +ChangeSet@1.1690, 2007-12-13 04:55:28-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 977] Fix mismatching #ifdefs for builds without IPv6 + + ChangeLog@1.167, 2007-12-13 04:55:16-05:00, stenn@whimsy.udel.edu +2 -1 + [Bug 977] Fix mismatching #ifdefs for builds without IPv6 + + libisc/net.c@1.9, 2007-12-13 04:55:17-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 977] Fix mismatching #ifdefs for builds without IPv6 + +ChangeSet@1.1689, 2007-12-13 04:22:19-05:00, stenn@whimsy.udel.edu +1 -0 + hack around a problem + + ntpd/ntp_io.c@1.270, 2007-12-13 04:22:02-05:00, stenn@whimsy.udel.edu +1 -1 + hack around a problem + +ChangeSet@1.1685.1.1, 2007-12-13 03:47:59-05:00, stenn@whimsy.udel.edu +4 -0 + Clean up the logfile/syslog setup + + ChangeLog@1.164.1.1, 2007-12-13 03:47:44-05:00, stenn@whimsy.udel.edu +1 -0 + Clean up the logfile/syslog setup + + include/ntpd.h@1.114, 2007-12-13 03:44:44-05:00, stenn@whimsy.udel.edu +2 -0 + Cleanup log setup + + ntpd/ntp_config.c@1.174, 2007-12-13 03:42:46-05:00, stenn@whimsy.udel.edu +159 -165 + Cleanup log setup + + ntpd/ntpd.c@1.91, 2007-12-13 03:43:47-05:00, stenn@whimsy.udel.edu +9 -7 + Cleanup log setup + +ChangeSet@1.1687, 2007-12-12 16:59:29-05:00, mayer@pogo.udel.edu +1 -0 + [Bug 830] + + ChangeLog@1.165, 2007-12-12 16:59:17-05:00, mayer@pogo.udel.edu +1 -0 + [Bug 830] + +ChangeSet@1.1686, 2007-12-12 16:57:34-05:00, mayer@pogo.udel.edu +1 -0 + [Bug #830] Fix the checking order of the interface options + + ntpd/ntp_io.c@1.269, 2007-12-12 16:57:06-05:00, mayer@pogo.udel.edu +15 -39 + [Bug #830] Fix the checking order of the interface options + +ChangeSet@1.1685, 2007-12-05 06:46:56-05:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P105 + TAG: NTP_4_2_5P105 + + ntpd/ntpd-opts.c@1.97, 2007-12-05 06:46:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P105 + + ntpd/ntpd-opts.h@1.97, 2007-12-05 06:46:35-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P105 + + ntpd/ntpd-opts.texi@1.96, 2007-12-05 06:46:35-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P105 + + ntpd/ntpd.1@1.96, 2007-12-05 06:46:36-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P105 + + ntpdc/ntpdc-opts.c@1.93, 2007-12-05 06:46:37-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P105 + + ntpdc/ntpdc-opts.h@1.93, 2007-12-05 06:46:38-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P105 + + ntpdc/ntpdc-opts.texi@1.92, 2007-12-05 06:46:39-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P105 + + ntpdc/ntpdc.1@1.92, 2007-12-05 06:46:39-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P105 + + ntpq/ntpq-opts.c@1.93, 2007-12-05 06:46:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P105 + + ntpq/ntpq-opts.h@1.93, 2007-12-05 06:46:41-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P105 + + ntpq/ntpq-opts.texi@1.92, 2007-12-05 06:46:42-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P105 + + ntpq/ntpq.1@1.92, 2007-12-05 06:46:43-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P105 + + packageinfo.sh@1.108, 2007-12-05 06:46:44-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P105 + + sntp/sntp-opts.c@1.93, 2007-12-05 06:46:44-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P105 + + sntp/sntp-opts.h@1.93, 2007-12-05 06:46:45-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P105 + + sntp/sntp-opts.texi@1.92, 2007-12-05 06:46:46-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P105 + + sntp/sntp.1@1.92, 2007-12-05 06:46:47-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P105 + + util/ntp-keygen-opts.c@1.96, 2007-12-05 06:46:48-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P105 + + util/ntp-keygen-opts.h@1.96, 2007-12-05 06:46:48-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P105 + + util/ntp-keygen-opts.texi@1.95, 2007-12-05 06:46:50-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P105 + + util/ntp-keygen.1@1.95, 2007-12-05 06:46:50-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P105 + +ChangeSet@1.1684, 2007-12-05 02:21:17-05:00, stenn@whimsy.udel.edu +7 -0 + [Bug 970] Lose obsolete -g flag to ntp-keygen + + ChangeLog@1.164, 2007-12-05 02:20:17-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 970] Lose obsolete -g flag to ntp-keygen + + util/ntp-keygen-opts.c@1.95, 2007-12-05 02:20:27-05:00, stenn@whimsy.udel.edu +28 -58 + [Bug 970] Lose obsolete -g flag to ntp-keygen + + util/ntp-keygen-opts.def@1.11, 2007-12-05 02:20:28-05:00, stenn@whimsy.udel.edu +0 -12 + [Bug 970] Lose obsolete -g flag to ntp-keygen + + util/ntp-keygen-opts.h@1.95, 2007-12-05 02:20:29-05:00, stenn@whimsy.udel.edu +20 -29 + [Bug 970] Lose obsolete -g flag to ntp-keygen + + util/ntp-keygen-opts.texi@1.94, 2007-12-05 02:20:30-05:00, stenn@whimsy.udel.edu +1 -18 + [Bug 970] Lose obsolete -g flag to ntp-keygen + + util/ntp-keygen.1@1.94, 2007-12-05 02:20:31-05:00, stenn@whimsy.udel.edu +1 -8 + [Bug 970] Lose obsolete -g flag to ntp-keygen + + util/ntp-keygen.c@1.48, 2007-12-05 02:20:31-05:00, stenn@whimsy.udel.edu +0 -4 + [Bug 970] Lose obsolete -g flag to ntp-keygen + +ChangeSet@1.1683, 2007-12-05 01:57:39-05:00, stenn@whimsy.udel.edu +6 -0 + The -e flag to ntp-keygen can write GQ keys now, too. + + ChangeLog@1.163, 2007-12-05 01:57:24-05:00, stenn@whimsy.udel.edu +1 -0 + The -e flag to ntp-keygen can write GQ keys now, too. + + util/ntp-keygen-opts.c@1.94, 2007-12-05 01:56:59-05:00, stenn@whimsy.udel.edu +2 -2 + The -e flag to ntp-keygen can write GQ keys now, too. + + util/ntp-keygen-opts.def@1.10, 2007-12-05 01:57:00-05:00, stenn@whimsy.udel.edu +19 -19 + The -e flag to ntp-keygen can write GQ keys now, too. + + util/ntp-keygen-opts.h@1.94, 2007-12-05 01:57:01-05:00, stenn@whimsy.udel.edu +1 -1 + The -e flag to ntp-keygen can write GQ keys now, too. + + util/ntp-keygen-opts.texi@1.93, 2007-12-05 01:57:02-05:00, stenn@whimsy.udel.edu +4 -4 + The -e flag to ntp-keygen can write GQ keys now, too. + + util/ntp-keygen.1@1.93, 2007-12-05 01:57:03-05:00, stenn@whimsy.udel.edu +4 -4 + The -e flag to ntp-keygen can write GQ keys now, too. + +ChangeSet@1.1682, 2007-12-05 01:34:40-05:00, stenn@whimsy.udel.edu +3 -0 + Fixes from Dave Mills + + ChangeLog@1.162, 2007-12-05 01:33:37-05:00, stenn@whimsy.udel.edu +1 -0 + sys_survivors and hpoll cleanup from Dave Mills + + ChangeLog@1.161, 2007-12-05 01:31:45-05:00, stenn@whimsy.udel.edu +1 -0 + sys_poll cleanup from Dave Mills + + ntpd/ntp_loopfilter.c@1.141, 2007-12-05 01:31:46-05:00, stenn@whimsy.udel.edu +6 -7 + sys_poll cleanup from Dave Mills + + ntpd/ntp_proto.c@1.268, 2007-12-05 01:33:38-05:00, stenn@whimsy.udel.edu +9 -6 + sys_survivors and hpoll cleanup from Dave Mills + +ChangeSet@1.1681, 2007-12-05 01:24:01-05:00, stenn@whimsy.udel.edu +2 -0 + maximum-likelihood digit and DSYNC fixes from Dave Mills + + ChangeLog@1.160, 2007-12-05 01:23:49-05:00, stenn@whimsy.udel.edu +1 -0 + maximum-likelihood digit and DSYNC fixes from Dave Mills + + ntpd/refclock_wwv.c@1.72, 2007-12-05 01:23:10-05:00, stenn@whimsy.udel.edu +11 -15 + maximum-likelihood digit and DSYNC fixes from Dave Mills + +ChangeSet@1.1680, 2007-11-27 06:45:40-05:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P104 + TAG: NTP_4_2_5P104 + + ntpd/ntpd-opts.c@1.96, 2007-11-27 06:45:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P104 + + ntpd/ntpd-opts.h@1.96, 2007-11-27 06:45:19-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P104 + + ntpd/ntpd-opts.texi@1.95, 2007-11-27 06:45:20-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P104 + + ntpd/ntpd.1@1.95, 2007-11-27 06:45:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P104 + + ntpdc/ntpdc-opts.c@1.92, 2007-11-27 06:45:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P104 + + ntpdc/ntpdc-opts.h@1.92, 2007-11-27 06:45:22-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P104 + + ntpdc/ntpdc-opts.texi@1.91, 2007-11-27 06:45:23-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P104 + + ntpdc/ntpdc.1@1.91, 2007-11-27 06:45:23-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P104 + + ntpq/ntpq-opts.c@1.92, 2007-11-27 06:45:25-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P104 + + ntpq/ntpq-opts.h@1.92, 2007-11-27 06:45:26-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P104 + + ntpq/ntpq-opts.texi@1.91, 2007-11-27 06:45:27-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P104 + + ntpq/ntpq.1@1.91, 2007-11-27 06:45:27-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P104 + + packageinfo.sh@1.107, 2007-11-27 06:45:28-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P104 + + sntp/sntp-opts.c@1.92, 2007-11-27 06:45:29-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P104 + + sntp/sntp-opts.h@1.92, 2007-11-27 06:45:30-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P104 + + sntp/sntp-opts.texi@1.91, 2007-11-27 06:45:31-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P104 + + sntp/sntp.1@1.91, 2007-11-27 06:45:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P104 + + util/ntp-keygen-opts.c@1.93, 2007-11-27 06:45:33-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P104 + + util/ntp-keygen-opts.h@1.93, 2007-11-27 06:45:34-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P104 + + util/ntp-keygen-opts.texi@1.92, 2007-11-27 06:45:35-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P104 + + util/ntp-keygen.1@1.92, 2007-11-27 06:45:35-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P104 + +ChangeSet@1.1679, 2007-11-26 17:04:10-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 967] preemptable associations are lost forever on a step + + ChangeLog@1.159, 2007-11-26 17:03:51-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 967] preemptable associations are lost forever on a step + + ntpd/ntp_peer.c@1.110, 2007-11-26 17:03:52-05:00, stenn@whimsy.udel.edu +0 -3 + [Bug 967] preemptable associations are lost forever on a step + +ChangeSet@1.1678, 2007-11-25 06:45:57-05:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P103 + TAG: NTP_4_2_5P103 + + ntpd/ntpd-opts.c@1.95, 2007-11-25 06:45:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P103 + + ntpd/ntpd-opts.h@1.95, 2007-11-25 06:45:35-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P103 + + ntpd/ntpd-opts.texi@1.94, 2007-11-25 06:45:37-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P103 + + ntpd/ntpd.1@1.94, 2007-11-25 06:45:37-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P103 + + ntpdc/ntpdc-opts.c@1.91, 2007-11-25 06:45:38-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P103 + + ntpdc/ntpdc-opts.h@1.91, 2007-11-25 06:45:39-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P103 + + ntpdc/ntpdc-opts.texi@1.90, 2007-11-25 06:45:40-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P103 + + ntpdc/ntpdc.1@1.90, 2007-11-25 06:45:41-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P103 + + ntpq/ntpq-opts.c@1.91, 2007-11-25 06:45:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P103 + + ntpq/ntpq-opts.h@1.91, 2007-11-25 06:45:43-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P103 + + ntpq/ntpq-opts.texi@1.90, 2007-11-25 06:45:45-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P103 + + ntpq/ntpq.1@1.90, 2007-11-25 06:45:45-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P103 + + packageinfo.sh@1.106, 2007-11-25 06:45:46-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P103 + + sntp/sntp-opts.c@1.91, 2007-11-25 06:45:47-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P103 + + sntp/sntp-opts.h@1.91, 2007-11-25 06:45:48-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P103 + + sntp/sntp-opts.texi@1.90, 2007-11-25 06:45:49-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P103 + + sntp/sntp.1@1.90, 2007-11-25 06:45:50-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P103 + + util/ntp-keygen-opts.c@1.92, 2007-11-25 06:45:51-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P103 + + util/ntp-keygen-opts.h@1.92, 2007-11-25 06:45:51-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P103 + + util/ntp-keygen-opts.texi@1.91, 2007-11-25 06:45:52-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P103 + + util/ntp-keygen.1@1.91, 2007-11-25 06:45:53-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P103 + +ChangeSet@1.1673.1.2, 2007-11-24 18:52:51-05:00, stenn@whimsy.udel.edu +2 -0 + documentation update from Dave Mills + + html/assoc.html@1.25, 2007-11-24 18:52:38-05:00, stenn@whimsy.udel.edu +8 -8 + documentation update from Dave Mills + + html/bugs.html@1.1, 2007-11-23 18:07:25-05:00, stenn@whimsy.udel.edu +30 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/bugs.html + + html/bugs.html@1.0, 2007-11-23 18:07:25-05:00, stenn@whimsy.udel.edu +0 -0 + +ChangeSet@1.1676, 2007-11-24 18:50:51-05:00, stenn@pogo.udel.edu +1 -0 + [CID 48] missing "else" clause + + ChangeLog@1.158, 2007-11-24 18:50:38-05:00, stenn@pogo.udel.edu +1 -0 + [CID 48] missing "else" clause + +ChangeSet@1.1673.1.1, 2007-11-24 06:45:27-05:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P102 + TAG: NTP_4_2_5P102 + + ntpd/ntpd-opts.c@1.94, 2007-11-24 06:45:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P102 + + ntpd/ntpd-opts.h@1.94, 2007-11-24 06:45:06-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P102 + + ntpd/ntpd-opts.texi@1.93, 2007-11-24 06:45:07-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P102 + + ntpd/ntpd.1@1.93, 2007-11-24 06:45:07-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P102 + + ntpdc/ntpdc-opts.c@1.90, 2007-11-24 06:45:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P102 + + ntpdc/ntpdc-opts.h@1.90, 2007-11-24 06:45:09-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P102 + + ntpdc/ntpdc-opts.texi@1.89, 2007-11-24 06:45:10-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P102 + + ntpdc/ntpdc.1@1.89, 2007-11-24 06:45:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P102 + + ntpq/ntpq-opts.c@1.90, 2007-11-24 06:45:12-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P102 + + ntpq/ntpq-opts.h@1.90, 2007-11-24 06:45:12-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P102 + + ntpq/ntpq-opts.texi@1.89, 2007-11-24 06:45:14-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P102 + + ntpq/ntpq.1@1.89, 2007-11-24 06:45:15-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P102 + + packageinfo.sh@1.105, 2007-11-24 06:45:15-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P102 + + sntp/sntp-opts.c@1.90, 2007-11-24 06:45:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P102 + + sntp/sntp-opts.h@1.90, 2007-11-24 06:45:17-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P102 + + sntp/sntp-opts.texi@1.89, 2007-11-24 06:45:18-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P102 + + sntp/sntp.1@1.89, 2007-11-24 06:45:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P102 + + util/ntp-keygen-opts.c@1.91, 2007-11-24 06:45:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P102 + + util/ntp-keygen-opts.h@1.91, 2007-11-24 06:45:21-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P102 + + util/ntp-keygen-opts.texi@1.90, 2007-11-24 06:45:22-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P102 + + util/ntp-keygen.1@1.90, 2007-11-24 06:45:22-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P102 + +ChangeSet@1.1674, 2007-11-23 20:01:46+00:00, kamboj@pogo.udel.edu +1 -0 + ntp_config.c: + Fixed a minor bug reported by coverity + + ntpd/ntp_config.c@1.173, 2007-11-23 20:00:48+00:00, kamboj@pogo.udel.edu +6 -3 + Fixed a minor bug reported by coverity + +ChangeSet@1.1673, 2007-11-23 14:59:15-05:00, stenn@whimsy.udel.edu +3 -0 + ChangeLog: + [Bug 833] ntpq "config" keyword is 2ble-quote-mark-unfriendly. + Rename the 'config' keyword to ':config'. + + ChangeLog@1.157, 2007-11-23 14:50:00-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 833] ntpq "config" keyword is 2ble-quote-mark-unfriendly. + Rename the 'config' keyword to ':config'. + + ntpq/ntpq-subs.c@1.29, 2007-11-23 14:51:22-05:00, stenn@whimsy.udel.edu +2 -2 + + ntpq/ntpq.c@1.73, 2007-11-23 14:51:30-05:00, stenn@whimsy.udel.edu +27 -11 + +ChangeSet@1.1672, 2007-11-23 06:49:02-05:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P101 + TAG: NTP_4_2_5P101 + + ntpd/ntpd-opts.c@1.93, 2007-11-23 06:48:37-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P101 + + ntpd/ntpd-opts.h@1.93, 2007-11-23 06:48:38-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P101 + + ntpd/ntpd-opts.texi@1.92, 2007-11-23 06:48:39-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P101 + + ntpd/ntpd.1@1.92, 2007-11-23 06:48:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P101 + + ntpdc/ntpdc-opts.c@1.89, 2007-11-23 06:48:41-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P101 + + ntpdc/ntpdc-opts.h@1.89, 2007-11-23 06:48:42-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P101 + + ntpdc/ntpdc-opts.texi@1.88, 2007-11-23 06:48:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P101 + + ntpdc/ntpdc.1@1.88, 2007-11-23 06:48:43-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P101 + + ntpq/ntpq-opts.c@1.89, 2007-11-23 06:48:44-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P101 + + ntpq/ntpq-opts.h@1.89, 2007-11-23 06:48:45-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P101 + + ntpq/ntpq-opts.texi@1.88, 2007-11-23 06:48:46-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P101 + + ntpq/ntpq.1@1.88, 2007-11-23 06:48:47-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P101 + + packageinfo.sh@1.104, 2007-11-23 06:48:47-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P101 + + sntp/sntp-opts.c@1.89, 2007-11-23 06:48:48-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P101 + + sntp/sntp-opts.h@1.89, 2007-11-23 06:48:49-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P101 + + sntp/sntp-opts.texi@1.88, 2007-11-23 06:48:50-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P101 + + sntp/sntp.1@1.88, 2007-11-23 06:48:50-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P101 + + util/ntp-keygen-opts.c@1.90, 2007-11-23 06:48:52-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P101 + + util/ntp-keygen-opts.h@1.90, 2007-11-23 06:48:53-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P101 + + util/ntp-keygen-opts.texi@1.89, 2007-11-23 06:48:53-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P101 + + util/ntp-keygen.1@1.89, 2007-11-23 06:48:54-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P101 + +ChangeSet@1.1671, 2007-11-23 04:34:06-05:00, stenn@whimsy.udel.edu +4 -0 + Dave Mills shifted some orphan processing + + ChangeLog@1.156, 2007-11-23 04:33:48-05:00, stenn@whimsy.udel.edu +1 -0 + Dave Mills shifted some orphan processing + + include/ntpd.h@1.113, 2007-11-23 04:33:49-05:00, stenn@whimsy.udel.edu +3 -0 + Dave Mills shifted some orphan processing + + ntpd/ntp_proto.c@1.267, 2007-11-23 04:33:50-05:00, stenn@whimsy.udel.edu +2 -17 + Dave Mills shifted some orphan processing + + ntpd/ntp_timer.c@1.44, 2007-11-23 04:33:51-05:00, stenn@whimsy.udel.edu +18 -0 + Dave Mills shifted some orphan processing + +ChangeSet@1.1670, 2007-11-22 21:30:50-05:00, stenn@whimsy.udel.edu +3 -0 + Fix typos in the [Bug 963] patch + + ChangeLog@1.155, 2007-11-22 21:30:29-05:00, stenn@whimsy.udel.edu +1 -0 + Fix typos in the [Bug 963] patch + + libntp/systime.c@1.46, 2007-11-22 21:30:30-05:00, stenn@whimsy.udel.edu +1 -1 + Fix typos in the [Bug 963] patch + + ntpd/ntp_io.c@1.268, 2007-11-22 21:30:31-05:00, stenn@whimsy.udel.edu +1 -1 + Fix typos in the [Bug 963] patch + +ChangeSet@1.1669, 2007-11-22 16:37:57-05:00, stenn@whimsy.udel.edu +2 -0 + bootstrap: squawk if genver fails. Use -f with cp in case Dave does a chown + + ChangeLog@1.154, 2007-11-22 16:37:40-05:00, stenn@whimsy.udel.edu +1 -0 + bootstrap: squawk if genver fails. Use -f with cp in case Dave does a chown + + bootstrap@1.21, 2007-11-22 16:37:09-05:00, stenn@whimsy.udel.edu +2 -2 + bootstrap: squawk if genver fails. Use -f with cp in case Dave does a chown + +ChangeSet@1.1668, 2007-11-22 06:46:46-05:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P100 + TAG: NTP_4_2_5P100 + + ntpd/ntpd-opts.c@1.92, 2007-11-22 06:46:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P100 + + ntpd/ntpd-opts.h@1.92, 2007-11-22 06:46:25-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P100 + + ntpd/ntpd-opts.texi@1.91, 2007-11-22 06:46:25-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P100 + + ntpd/ntpd.1@1.91, 2007-11-22 06:46:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P100 + + ntpdc/ntpdc-opts.c@1.88, 2007-11-22 06:46:28-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P100 + + ntpdc/ntpdc-opts.h@1.88, 2007-11-22 06:46:28-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P100 + + ntpdc/ntpdc-opts.texi@1.87, 2007-11-22 06:46:29-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P100 + + ntpdc/ntpdc.1@1.87, 2007-11-22 06:46:30-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P100 + + ntpq/ntpq-opts.c@1.88, 2007-11-22 06:46:31-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P100 + + ntpq/ntpq-opts.h@1.88, 2007-11-22 06:46:32-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P100 + + ntpq/ntpq-opts.texi@1.87, 2007-11-22 06:46:33-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P100 + + ntpq/ntpq.1@1.87, 2007-11-22 06:46:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P100 + + packageinfo.sh@1.103, 2007-11-22 06:46:35-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P100 + + sntp/sntp-opts.c@1.88, 2007-11-22 06:46:35-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P100 + + sntp/sntp-opts.h@1.88, 2007-11-22 06:46:37-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P100 + + sntp/sntp-opts.texi@1.87, 2007-11-22 06:46:38-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P100 + + sntp/sntp.1@1.87, 2007-11-22 06:46:38-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P100 + + util/ntp-keygen-opts.c@1.89, 2007-11-22 06:46:39-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P100 + + util/ntp-keygen-opts.h@1.89, 2007-11-22 06:46:40-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P100 + + util/ntp-keygen-opts.texi@1.88, 2007-11-22 06:46:41-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P100 + + util/ntp-keygen.1@1.88, 2007-11-22 06:46:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P100 + +ChangeSet@1.1667, 2007-11-22 04:19:55-05:00, stenn@whimsy.udel.edu +6 -0 + Remove obsolete simulator command-line options + + ChangeLog@1.153, 2007-11-22 04:18:47-05:00, stenn@whimsy.udel.edu +1 -0 + Remove obsolete simulator command-line options + + ntpd/ntpd-opts.c@1.91, 2007-11-22 04:19:27-05:00, stenn@whimsy.udel.edu +50 -329 + Remove obsolete simulator command-line options + + ntpd/ntpd-opts.h@1.91, 2007-11-22 04:19:28-05:00, stenn@whimsy.udel.edu +31 -112 + Remove obsolete simulator command-line options + + ntpd/ntpd-opts.texi@1.90, 2007-11-22 04:19:30-05:00, stenn@whimsy.udel.edu +1 -136 + Remove obsolete simulator command-line options + + ntpd/ntpd.1@1.90, 2007-11-22 04:19:31-05:00, stenn@whimsy.udel.edu +2 -47 + Remove obsolete simulator command-line options + + ntpd/ntpdbase-opts.def@1.15, 2007-11-22 04:19:32-05:00, stenn@whimsy.udel.edu +0 -90 + Remove obsolete simulator command-line options + +ChangeSet@1.1666, 2007-11-22 03:59:23-05:00, stenn@whimsy.udel.edu +2 -0 + [CID 36] zero sin_zero + + ChangeLog@1.152, 2007-11-22 03:59:08-05:00, stenn@whimsy.udel.edu +1 -0 + [CID 36] zero sin_zero + + ntpd/ntp_request.c@1.71, 2007-11-22 03:59:10-05:00, stenn@whimsy.udel.edu +1 -0 + [CID 36] zero sin_zero + +ChangeSet@1.1665, 2007-11-22 02:34:27-05:00, stenn@whimsy.udel.edu +3 -0 + [Bug 963] get_systime() is too noisy + + ChangeLog@1.151, 2007-11-22 02:33:47-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 963] get_systime() is too noisy + + libntp/systime.c@1.45, 2007-11-22 02:33:46-05:00, stenn@whimsy.udel.edu +26 -12 + [Bug 963] get_systime() is too noisy + + ntpd/ntp_io.c@1.267, 2007-11-22 02:33:44-05:00, stenn@whimsy.udel.edu +2 -1 + [Bug 963] get_systime() is too noisy + +ChangeSet@1.1662.1.3, 2007-11-21 06:49:11-05:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P99 + TAG: NTP_4_2_5P99 + + ntpd/ntpd-opts.c@1.90, 2007-11-21 06:48:50-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P99 + + ntpd/ntpd-opts.h@1.90, 2007-11-21 06:48:51-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P99 + + ntpd/ntpd-opts.texi@1.89, 2007-11-21 06:48:51-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P99 + + ntpd/ntpd.1@1.89, 2007-11-21 06:48:52-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P99 + + ntpdc/ntpdc-opts.c@1.87, 2007-11-21 06:48:52-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P99 + + ntpdc/ntpdc-opts.h@1.87, 2007-11-21 06:48:53-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P99 + + ntpdc/ntpdc-opts.texi@1.86, 2007-11-21 06:48:55-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P99 + + ntpdc/ntpdc.1@1.86, 2007-11-21 06:48:56-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P99 + + ntpq/ntpq-opts.c@1.87, 2007-11-21 06:48:57-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P99 + + ntpq/ntpq-opts.h@1.87, 2007-11-21 06:48:58-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P99 + + ntpq/ntpq-opts.texi@1.86, 2007-11-21 06:48:59-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P99 + + ntpq/ntpq.1@1.86, 2007-11-21 06:48:59-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P99 + + packageinfo.sh@1.102, 2007-11-21 06:49:00-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P99 + + sntp/sntp-opts.c@1.87, 2007-11-21 06:49:01-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P99 + + sntp/sntp-opts.h@1.87, 2007-11-21 06:49:02-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P99 + + sntp/sntp-opts.texi@1.86, 2007-11-21 06:49:03-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P99 + + sntp/sntp.1@1.86, 2007-11-21 06:49:04-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P99 + + util/ntp-keygen-opts.c@1.88, 2007-11-21 06:49:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P99 + + util/ntp-keygen-opts.h@1.88, 2007-11-21 06:49:05-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P99 + + util/ntp-keygen-opts.texi@1.87, 2007-11-21 06:49:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P99 + + util/ntp-keygen.1@1.87, 2007-11-21 06:49:07-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P99 + +ChangeSet@1.1662.1.2, 2007-11-21 01:26:56-05:00, stenn@deacon.udel.edu +2 -0 + [Bug 964] Change *-*-linux* to *-*-*linux* to allow for uclinux + + ChangeLog@1.148.1.2, 2007-11-21 01:20:43-05:00, stenn@deacon.udel.edu +1 -0 + [Bug 964] Change *-*-linux* to *-*-*linux* to allow for uclinux + + configure.ac@1.411, 2007-11-21 01:20:43-05:00, stenn@deacon.udel.edu +16 -16 + [Bug 964] Change *-*-linux* to *-*-*linux* to allow for uclinux + +ChangeSet@1.1662.1.1, 2007-11-21 01:12:13-05:00, stenn@deacon.udel.edu +14 -0 + ntp_timer.c: + ntp_timer.c: watch the non-burst packet rate + ntp_monitor.c: + ntp_monitor.c: RES_LIMITED cleanup from Dave Mills + ntp_config.c: + config: average and minimum are ^2 values + ntp_peer.c: + ntp_peer.c: disallow peer_unconfig() + ntpdc_ops.c: + Dave Mills: unknownversion is really "declined", not "bad version" + ntp_restrict.c: + ntp_restrict.c: RES_LIMITED cleanup from Dave Mills + ChangeLog: + Changes from Dave Mills + ntp_crypto.c: + ntp_crypto.c: volley -> retry. Cleanup TAI leap message. + ntp_request.c: + Cleanup from Dave Mills + ntp_loopfilter.c: + ntp_loopfilter.c: poll interval cleanup from Dave Mills + ntp_proto.c: + ntp_proto.c: RES_LIMITED, rate bucktes, counters, overall cleanup from Dave Mills + ntpd.h, ntp.h: + general and packet retry cleanup from Dave Mills + ntp_util.c: + cleanup + + ChangeLog@1.148.1.1, 2007-11-21 01:12:05-05:00, stenn@deacon.udel.edu +13 -0 + Changes from Dave Mills + + include/ntp.h@1.141, 2007-11-21 00:39:40-05:00, stenn@deacon.udel.edu +15 -14 + general and packet retry cleanup from Dave Mills + + include/ntpd.h@1.112, 2007-11-21 00:39:41-05:00, stenn@deacon.udel.edu +9 -9 + general and packet retry cleanup from Dave Mills + + ntpd/ntp_config.c@1.170.1.1, 2007-11-21 00:43:09-05:00, stenn@deacon.udel.edu +2 -2 + config: average and minimum are ^2 values + + ntpd/ntp_crypto.c@1.120, 2007-11-21 00:45:38-05:00, stenn@deacon.udel.edu +9 -6 + ntp_crypto.c: volley -> retry. Cleanup TAI leap message. + + ntpd/ntp_loopfilter.c@1.140, 2007-11-21 00:49:00-05:00, stenn@deacon.udel.edu +18 -7 + ntp_loopfilter.c: poll interval cleanup from Dave Mills + + ntpd/ntp_monitor.c@1.20, 2007-11-21 00:55:23-05:00, stenn@deacon.udel.edu +66 -31 + ntp_monitor.c: RES_LIMITED cleanup from Dave Mills + + ntpd/ntp_peer.c@1.109, 2007-11-21 00:58:28-05:00, stenn@deacon.udel.edu +20 -48 + ntp_peer.c: disallow peer_unconfig() + + ntpd/ntp_proto.c@1.266, 2007-11-21 01:06:33-05:00, stenn@deacon.udel.edu +317 -251 + ntp_proto.c: RES_LIMITED, rate bucktes, counters, overall cleanup from Dave Mills + + ntpd/ntp_request.c@1.70, 2007-11-21 01:09:27-05:00, stenn@deacon.udel.edu +9 -7 + Cleanup from Dave Mills + + ntpd/ntp_restrict.c@1.26, 2007-11-21 01:08:37-05:00, stenn@deacon.udel.edu +33 -60 + ntp_restrict.c: RES_LIMITED cleanup from Dave Mills + + ntpd/ntp_timer.c@1.43, 2007-11-21 01:10:44-05:00, stenn@deacon.udel.edu +13 -2 + ntp_timer.c: watch the non-burst packet rate + + ntpd/ntp_util.c@1.61, 2007-11-21 01:11:16-05:00, stenn@deacon.udel.edu +5 -5 + cleanup + + ntpdc/ntpdc_ops.c@1.53, 2007-11-21 00:41:17-05:00, stenn@deacon.udel.edu +1 -1 + Dave Mills: unknownversion is really "declined", not "bad version" + +ChangeSet@1.1663, 2007-11-20 21:36:27-05:00, neal@pogo.udel.edu +2 -0 + ChangeLog: + [Bug 960] spurious crypto command + ntp_config.c: + [Bug 960] spurious crypto command + + ChangeLog@1.149, 2007-11-20 21:35:21-05:00, neal@pogo.udel.edu +1 -0 + [Bug 960] spurious crypto command message + + ntpd/ntp_config.c@1.171, 2007-11-20 21:31:38-05:00, neal@pogo.udel.edu +3 -1 + [Bug 960] spurious crypto command + +ChangeSet@1.1662, 2007-11-14 06:45:25-05:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P98 + TAG: NTP_4_2_5P98 + + ntpd/ntpd-opts.c@1.89, 2007-11-14 06:44:59-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P98 + + ntpd/ntpd-opts.h@1.89, 2007-11-14 06:45:00-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P98 + + ntpd/ntpd-opts.texi@1.88, 2007-11-14 06:45:01-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P98 + + ntpd/ntpd.1@1.88, 2007-11-14 06:45:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P98 + + ntpdc/ntpdc-opts.c@1.86, 2007-11-14 06:45:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P98 + + ntpdc/ntpdc-opts.h@1.86, 2007-11-14 06:45:03-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P98 + + ntpdc/ntpdc-opts.texi@1.85, 2007-11-14 06:45:04-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P98 + + ntpdc/ntpdc.1@1.85, 2007-11-14 06:45:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P98 + + ntpq/ntpq-opts.c@1.86, 2007-11-14 06:45:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P98 + + ntpq/ntpq-opts.h@1.86, 2007-11-14 06:45:07-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P98 + + ntpq/ntpq-opts.texi@1.85, 2007-11-14 06:45:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P98 + + ntpq/ntpq.1@1.85, 2007-11-14 06:45:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P98 + + packageinfo.sh@1.101, 2007-11-14 06:45:10-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P98 + + sntp/sntp-opts.c@1.86, 2007-11-14 06:45:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P98 + + sntp/sntp-opts.h@1.86, 2007-11-14 06:45:12-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P98 + + sntp/sntp-opts.texi@1.85, 2007-11-14 06:45:13-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P98 + + sntp/sntp.1@1.85, 2007-11-14 06:45:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P98 + + util/ntp-keygen-opts.c@1.87, 2007-11-14 06:45:15-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P98 + + util/ntp-keygen-opts.h@1.87, 2007-11-14 06:45:17-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P98 + + util/ntp-keygen-opts.texi@1.86, 2007-11-14 06:45:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P98 + + util/ntp-keygen.1@1.86, 2007-11-14 06:45:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P98 + +ChangeSet@1.1661, 2007-11-13 16:57:44-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 961] refclock_tpro.c:tpro_poll() calls refclock_receive() twice + + ChangeLog@1.148, 2007-11-13 16:57:27-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 961] refclock_tpro.c:tpro_poll() calls refclock_receive() twice + + ntpd/refclock_tpro.c@1.10, 2007-11-13 16:57:28-05:00, stenn@whimsy.udel.edu +0 -1 + [Bug 961] refclock_tpro.c:tpro_poll() calls refclock_receive() twice + +ChangeSet@1.1660, 2007-11-12 06:46:23-05:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P97 + TAG: NTP_4_2_5P97 + + ntpd/ntpd-opts.c@1.88, 2007-11-12 06:46:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P97 + + ntpd/ntpd-opts.h@1.88, 2007-11-12 06:46:03-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P97 + + ntpd/ntpd-opts.texi@1.87, 2007-11-12 06:46:04-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P97 + + ntpd/ntpd.1@1.87, 2007-11-12 06:46:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P97 + + ntpdc/ntpdc-opts.c@1.85, 2007-11-12 06:46:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P97 + + ntpdc/ntpdc-opts.h@1.85, 2007-11-12 06:46:07-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P97 + + ntpdc/ntpdc-opts.texi@1.84, 2007-11-12 06:46:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P97 + + ntpdc/ntpdc.1@1.84, 2007-11-12 06:46:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P97 + + ntpq/ntpq-opts.c@1.85, 2007-11-12 06:46:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P97 + + ntpq/ntpq-opts.h@1.85, 2007-11-12 06:46:10-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P97 + + ntpq/ntpq-opts.texi@1.84, 2007-11-12 06:46:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P97 + + ntpq/ntpq.1@1.84, 2007-11-12 06:46:12-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P97 + + packageinfo.sh@1.100, 2007-11-12 06:46:12-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P97 + + sntp/sntp-opts.c@1.85, 2007-11-12 06:46:13-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P97 + + sntp/sntp-opts.h@1.85, 2007-11-12 06:46:14-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P97 + + sntp/sntp-opts.texi@1.84, 2007-11-12 06:46:15-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P97 + + sntp/sntp.1@1.84, 2007-11-12 06:46:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P97 + + util/ntp-keygen-opts.c@1.86, 2007-11-12 06:46:17-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P97 + + util/ntp-keygen-opts.h@1.86, 2007-11-12 06:46:17-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P97 + + util/ntp-keygen-opts.texi@1.85, 2007-11-12 06:46:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P97 + + util/ntp-keygen.1@1.85, 2007-11-12 06:46:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P97 + +ChangeSet@1.1657.1.2, 2007-11-09 06:48:04-05:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P96 + TAG: NTP_4_2_5P96 + + ntpd/ntpd-opts.c@1.87, 2007-11-09 06:47:43-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P96 + + ntpd/ntpd-opts.h@1.87, 2007-11-09 06:47:43-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P96 + + ntpd/ntpd-opts.texi@1.86, 2007-11-09 06:47:44-05:00, stenn@whimsy.udel.edu +5 -5 + NTP_4_2_5P96 + + ntpd/ntpd.1@1.86, 2007-11-09 06:47:45-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P96 + + ntpdc/ntpdc-opts.c@1.84, 2007-11-09 06:47:47-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P96 + + ntpdc/ntpdc-opts.h@1.84, 2007-11-09 06:47:48-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P96 + + ntpdc/ntpdc-opts.texi@1.83, 2007-11-09 06:47:49-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P96 + + ntpdc/ntpdc.1@1.83, 2007-11-09 06:47:50-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P96 + + ntpq/ntpq-opts.c@1.84, 2007-11-09 06:47:50-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P96 + + ntpq/ntpq-opts.h@1.84, 2007-11-09 06:47:51-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P96 + + ntpq/ntpq-opts.texi@1.83, 2007-11-09 06:47:52-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P96 + + ntpq/ntpq.1@1.83, 2007-11-09 06:47:53-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P96 + + packageinfo.sh@1.99, 2007-11-09 06:47:53-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P96 + + sntp/sntp-opts.c@1.84, 2007-11-09 06:47:54-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P96 + + sntp/sntp-opts.h@1.84, 2007-11-09 06:47:55-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P96 + + sntp/sntp-opts.texi@1.83, 2007-11-09 06:47:56-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P96 + + sntp/sntp.1@1.83, 2007-11-09 06:47:57-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P96 + + util/ntp-keygen-opts.c@1.85, 2007-11-09 06:47:58-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P96 + + util/ntp-keygen-opts.h@1.85, 2007-11-09 06:47:58-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P96 + + util/ntp-keygen-opts.texi@1.84, 2007-11-09 06:48:00-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P96 + + util/ntp-keygen.1@1.84, 2007-11-09 06:48:01-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P96 + +ChangeSet@1.1657.1.1, 2007-11-09 02:10:13-05:00, stenn@whimsy.udel.edu +4 -0 + Work around a VPATH difference in FreeBSD's 'make' command + + ChangeLog@1.145.1.1, 2007-11-09 02:06:39-05:00, stenn@whimsy.udel.edu +1 -0 + Work around a VPATH difference in FreeBSD's 'make' command + + configure.ac@1.410, 2007-11-09 02:06:39-05:00, stenn@whimsy.udel.edu +1 -0 + Work around a VPATH difference in FreeBSD's 'make' command + + m4/ntp_vpathhack.m4@1.1, 2007-11-09 02:04:19-05:00, stenn@whimsy.udel.edu +23 -0 + BitKeeper file /deacon/backroom/ntp-dev-hms/m4/ntp_vpathhack.m4 + + m4/ntp_vpathhack.m4@1.0, 2007-11-09 02:04:19-05:00, stenn@whimsy.udel.edu +0 -0 + + ntpd/Makefile.am@1.64, 2007-11-09 02:06:41-05:00, stenn@whimsy.udel.edu +11 -1 + Work around a VPATH difference in FreeBSD's 'make' command + +ChangeSet@1.1658, 2007-11-08 12:08:38-05:00, burnicki@pogo.udel.edu +3 -0 + [Bug 713] Windows only: Let command line parameters from the Windows SCM GUI + override the standard parameters from the ImagePath registry key. + * Added HAVE_INT32_T to the Windows config.h to avoid duplicate definitions. + + ChangeLog@1.146, 2007-11-08 12:08:36-05:00, burnicki@pogo.udel.edu +3 -0 + Updated for bug #957. + + ports/winnt/include/config.h@1.53, 2007-11-08 12:08:36-05:00, burnicki@pogo.udel.edu +1 -0 + Added HAVE_INT32_T to the Windows config.h to avoid duplicate definitions. + + ports/winnt/ntpd/ntservice.c@1.11, 2007-11-08 12:08:36-05:00, burnicki@pogo.udel.edu +11 -2 + [Bug 957] Let command line parameters from the Windows SCM GUI + override the standard parameters from the ImagePath registry key. + +ChangeSet@1.1657, 2007-11-06 06:46:44-05:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P95 + TAG: NTP_4_2_5P95 + + ntpd/ntpd-opts.c@1.86, 2007-11-06 06:46:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P95 + + ntpd/ntpd-opts.h@1.86, 2007-11-06 06:46:25-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P95 + + ntpd/ntpd-opts.texi@1.85, 2007-11-06 06:46:26-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P95 + + ntpd/ntpd.1@1.85, 2007-11-06 06:46:27-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P95 + + ntpdc/ntpdc-opts.c@1.83, 2007-11-06 06:46:28-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P95 + + ntpdc/ntpdc-opts.h@1.83, 2007-11-06 06:46:29-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P95 + + ntpdc/ntpdc-opts.texi@1.82, 2007-11-06 06:46:30-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P95 + + ntpdc/ntpdc.1@1.82, 2007-11-06 06:46:31-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P95 + + ntpq/ntpq-opts.c@1.83, 2007-11-06 06:46:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P95 + + ntpq/ntpq-opts.h@1.83, 2007-11-06 06:46:32-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P95 + + ntpq/ntpq-opts.texi@1.82, 2007-11-06 06:46:33-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P95 + + ntpq/ntpq.1@1.82, 2007-11-06 06:46:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P95 + + packageinfo.sh@1.98, 2007-11-06 06:46:35-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P95 + + sntp/sntp-opts.c@1.83, 2007-11-06 06:46:35-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P95 + + sntp/sntp-opts.h@1.83, 2007-11-06 06:46:35-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P95 + + sntp/sntp-opts.texi@1.82, 2007-11-06 06:46:36-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P95 + + sntp/sntp.1@1.82, 2007-11-06 06:46:37-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P95 + + util/ntp-keygen-opts.c@1.84, 2007-11-06 06:46:38-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P95 + + util/ntp-keygen-opts.h@1.84, 2007-11-06 06:46:39-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P95 + + util/ntp-keygen-opts.texi@1.83, 2007-11-06 06:46:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P95 + + util/ntp-keygen.1@1.83, 2007-11-06 06:46:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P95 + +ChangeSet@1.1656, 2007-11-06 01:50:44-05:00, stenn@whimsy.udel.edu +27 -0 + Update bugreport URL + + ChangeLog@1.145, 2007-11-06 01:50:34-05:00, stenn@whimsy.udel.edu +1 -0 + Update bugreport URL + + README@1.23, 2007-11-06 01:49:34-05:00, stenn@whimsy.udel.edu +1 -1 + Update bugreport URL + + README.bk@1.19, 2007-11-06 01:49:35-05:00, stenn@whimsy.udel.edu +1 -1 + Update bugreport URL + + README.patches@1.4, 2007-11-06 01:49:35-05:00, stenn@whimsy.udel.edu +1 -1 + Update bugreport URL + + WHERE-TO-START@1.7, 2007-11-06 01:49:35-05:00, stenn@whimsy.udel.edu +1 -1 + Update bugreport URL + + include/copyright.def@1.7, 2007-11-06 01:44:22-05:00, stenn@whimsy.udel.edu +1 -1 + Update bugreport URL + + ntpd/ntpd-opts.c@1.85, 2007-11-06 01:48:07-05:00, stenn@whimsy.udel.edu +2 -2 + Update bugreport URL + + ntpd/ntpd-opts.h@1.85, 2007-11-06 01:48:07-05:00, stenn@whimsy.udel.edu +1 -1 + Update bugreport URL + + ntpd/ntpd-opts.texi@1.84, 2007-11-06 01:48:08-05:00, stenn@whimsy.udel.edu +1 -1 + Update bugreport URL + + ntpd/ntpd.1@1.84, 2007-11-06 01:48:10-05:00, stenn@whimsy.udel.edu +2 -2 + Update bugreport URL + + ntpdc/ntpdc-opts.c@1.82, 2007-11-06 01:48:11-05:00, stenn@whimsy.udel.edu +2 -2 + Update bugreport URL + + ntpdc/ntpdc-opts.h@1.82, 2007-11-06 01:48:13-05:00, stenn@whimsy.udel.edu +1 -1 + Update bugreport URL + + ntpdc/ntpdc-opts.texi@1.81, 2007-11-06 01:48:13-05:00, stenn@whimsy.udel.edu +2 -2 + Update bugreport URL + + ntpdc/ntpdc.1@1.81, 2007-11-06 01:48:14-05:00, stenn@whimsy.udel.edu +3 -3 + Update bugreport URL + + ntpq/ntpq-opts.c@1.82, 2007-11-06 01:48:15-05:00, stenn@whimsy.udel.edu +2 -2 + Update bugreport URL + + ntpq/ntpq-opts.h@1.82, 2007-11-06 01:48:16-05:00, stenn@whimsy.udel.edu +1 -1 + Update bugreport URL + + ntpq/ntpq-opts.texi@1.81, 2007-11-06 01:48:17-05:00, stenn@whimsy.udel.edu +2 -2 + Update bugreport URL + + ntpq/ntpq.1@1.81, 2007-11-06 01:48:18-05:00, stenn@whimsy.udel.edu +3 -3 + Update bugreport URL + + sntp/sntp-opts.c@1.82, 2007-11-06 01:48:19-05:00, stenn@whimsy.udel.edu +2 -2 + Update bugreport URL + + sntp/sntp-opts.def@1.11, 2007-11-06 01:44:22-05:00, stenn@whimsy.udel.edu +1 -1 + Update bugreport URL + + sntp/sntp-opts.h@1.82, 2007-11-06 01:48:19-05:00, stenn@whimsy.udel.edu +1 -1 + Update bugreport URL + + sntp/sntp-opts.texi@1.81, 2007-11-06 01:48:20-05:00, stenn@whimsy.udel.edu +1 -1 + Update bugreport URL + + sntp/sntp.1@1.81, 2007-11-06 01:48:21-05:00, stenn@whimsy.udel.edu +3 -3 + Update bugreport URL + + util/ntp-keygen-opts.c@1.83, 2007-11-06 01:48:22-05:00, stenn@whimsy.udel.edu +2 -2 + Update bugreport URL + + util/ntp-keygen-opts.h@1.83, 2007-11-06 01:48:23-05:00, stenn@whimsy.udel.edu +1 -1 + Update bugreport URL + + util/ntp-keygen-opts.texi@1.82, 2007-11-06 01:48:24-05:00, stenn@whimsy.udel.edu +2 -2 + Update bugreport URL + + util/ntp-keygen.1@1.82, 2007-11-06 01:48:24-05:00, stenn@whimsy.udel.edu +3 -3 + Update bugreport URL + +ChangeSet@1.1655, 2007-11-06 00:45:47-05:00, stenn@whimsy.udel.edu +6 -0 + Update -I documentation + + ChangeLog@1.144, 2007-11-06 00:45:32-05:00, stenn@whimsy.udel.edu +1 -0 + Update -I documentation + + ntpd/ntpd-opts.c@1.84, 2007-11-06 00:44:55-05:00, stenn@whimsy.udel.edu +330 -51 + Update -I documentation + + ntpd/ntpd-opts.h@1.84, 2007-11-06 00:44:56-05:00, stenn@whimsy.udel.edu +112 -31 + Update -I documentation + + ntpd/ntpd-opts.texi@1.83, 2007-11-06 00:44:56-05:00, stenn@whimsy.udel.edu +137 -2 + Update -I documentation + + ntpd/ntpd.1@1.83, 2007-11-06 00:44:57-05:00, stenn@whimsy.udel.edu +48 -3 + Update -I documentation + + ntpd/ntpdbase-opts.def@1.14, 2007-11-06 00:44:58-05:00, stenn@whimsy.udel.edu +10 -19 + Update -I documentation + +ChangeSet@1.1654, 2007-11-05 21:27:36-05:00, stenn@whimsy.udel.edu +4 -0 + [Bug 713] Fix bug reporting information + + ChangeLog@1.143, 2007-11-05 21:27:05-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 713] Fix bug reporting information + + html/index.html@1.35, 2007-11-05 21:26:27-05:00, stenn@whimsy.udel.edu +2 -2 + [Bug 713] Fix bug reporting information + + html/msyslog.html@1.6, 2007-11-05 21:26:30-05:00, stenn@whimsy.udel.edu +3 -3 + [Bug 713] Fix bug reporting information + + html/release.html@1.33, 2007-11-05 21:26:34-05:00, stenn@whimsy.udel.edu +3 -3 + [Bug 713] Fix bug reporting information + +ChangeSet@1.1649.1.2, 2007-11-05 06:45:45-05:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P94 + TAG: NTP_4_2_5P94 + + ntpd/ntpd-opts.c@1.83, 2007-11-05 06:45:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P94 + + ntpd/ntpd-opts.h@1.83, 2007-11-05 06:45:27-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P94 + + ntpd/ntpd-opts.texi@1.82, 2007-11-05 06:45:28-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P94 + + ntpd/ntpd.1@1.82, 2007-11-05 06:45:29-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P94 + + ntpdc/ntpdc-opts.c@1.81, 2007-11-05 06:45:29-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P94 + + ntpdc/ntpdc-opts.h@1.81, 2007-11-05 06:45:30-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P94 + + ntpdc/ntpdc-opts.texi@1.80, 2007-11-05 06:45:31-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P94 + + ntpdc/ntpdc.1@1.80, 2007-11-05 06:45:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P94 + + ntpq/ntpq-opts.c@1.81, 2007-11-05 06:45:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P94 + + ntpq/ntpq-opts.h@1.81, 2007-11-05 06:45:33-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P94 + + ntpq/ntpq-opts.texi@1.80, 2007-11-05 06:45:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P94 + + ntpq/ntpq.1@1.80, 2007-11-05 06:45:35-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P94 + + packageinfo.sh@1.97, 2007-11-05 06:45:36-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P94 + + sntp/sntp-opts.c@1.81, 2007-11-05 06:45:37-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P94 + + sntp/sntp-opts.h@1.81, 2007-11-05 06:45:37-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P94 + + sntp/sntp-opts.texi@1.80, 2007-11-05 06:45:38-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P94 + + sntp/sntp.1@1.80, 2007-11-05 06:45:39-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P94 + + util/ntp-keygen-opts.c@1.82, 2007-11-05 06:45:39-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P94 + + util/ntp-keygen-opts.h@1.82, 2007-11-05 06:45:40-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P94 + + util/ntp-keygen-opts.texi@1.81, 2007-11-05 06:45:41-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P94 + + util/ntp-keygen.1@1.81, 2007-11-05 06:45:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P94 + +ChangeSet@1.1649.1.1, 2007-11-05 03:12:05-05:00, stenn@whimsy.udel.edu +11 -0 + ntp_config.c: + reindent + ntp-keygen.c: + Coverity fixes [CID 33,47] + ntp_util.c, ntp_crypto.c, ntp_timer.c: + [Bug 861] Leap second cleanups from Dave Mills + systime.c: + Fuzz cleanup from Dave Mills. + ntp.h: + Volley cleanup from Dave Mills. + ntp_io.c: + Fuzz cleanup from Dave Mills + ntp_proto.c: + [Bug 861] Leap second cleanups from Dave Mills. + Volley cleanup from Dave Mills. + ntpd.h: + Leap second file cleanups from Dave Mills + + ChangeLog@1.140.1.1, 2007-11-05 03:11:51-05:00, stenn@whimsy.udel.edu +4 -0 + + include/ntp.h@1.140, 2007-11-05 03:01:16-05:00, stenn@whimsy.udel.edu +0 -1 + Volley cleanup from Dave Mills. + + include/ntpd.h@1.111, 2007-11-05 02:48:59-05:00, stenn@whimsy.udel.edu +0 -1 + Leap second file cleanups from Dave Mills + + libntp/systime.c@1.44, 2007-11-05 03:02:28-05:00, stenn@whimsy.udel.edu +2 -4 + Fuzz cleanup from Dave Mills. + + ntpd/ntp_config.c@1.170, 2007-11-05 02:55:30-05:00, stenn@whimsy.udel.edu +6 -6 + reindent + + ntpd/ntp_crypto.c@1.119, 2007-11-05 02:54:56-05:00, stenn@whimsy.udel.edu +7 -4 + [Bug 861] Leap second cleanups from Dave Mills + + ntpd/ntp_io.c@1.266, 2007-11-05 02:56:05-05:00, stenn@whimsy.udel.edu +2 -8 + Fuzz cleanup from Dave Mills + + ntpd/ntp_proto.c@1.265, 2007-11-05 03:00:27-05:00, stenn@whimsy.udel.edu +64 -115 + [Bug 861] Leap second cleanups from Dave Mills. + Volley cleanup from Dave Mills. + + ntpd/ntp_timer.c@1.42, 2007-11-05 02:58:19-05:00, stenn@whimsy.udel.edu +17 -7 + [Bug 861] Leap second cleanups from Dave Mills + + ntpd/ntp_util.c@1.60, 2007-11-05 02:58:20-05:00, stenn@whimsy.udel.edu +3 -3 + [Bug 861] Leap second cleanups from Dave Mills + + util/ntp-keygen.c@1.47, 2007-11-05 03:10:41-05:00, stenn@whimsy.udel.edu +9 -10 + Coverity fixes [CID 33,47] + +ChangeSet@1.1436.1.87, 2007-11-01 03:52:00-04:00, clemens@pogo.udel.edu +1 -0 + * Negative-sawtooth not applied correctly for oncore 12 channel + receiver. Fixed. + * Startup code for original LinuxPPS removed. LinuxPPS now + conforms to the PPSAPI. + + ChangeLog@1.1.1.35, 2007-11-01 03:51:58-04:00, clemens@pogo.udel.edu +4 -0 + * Negative-sawtooth not applied correctly for oncore 12 channel + receiver. Fixed. + * Startup code for original LinuxPPS removed. LinuxPPS now + conforms to the PPSAPI. + +ChangeSet@1.1652, 2007-11-01 03:49:06-04:00, clemens@pogo.udel.edu +1 -0 + * A bug in the application of the negative-sawtoot for 12 channel receivers. + * The removal of unneeded startup code used for the original LinuxPPS, it now + conforms to the PPSAPI and does not need special code. + + ChangeLog@1.141, 2007-11-01 03:49:04-04:00, clemens@pogo.udel.edu +3 -0 + * A bug in the application of the negative-sawtoot for 12 channel receivers. + * The removal of unneeded startup code used for the original LinuxPPS, it now + conforms to the PPSAPI and does not need special code. + +ChangeSet@1.1436.1.86, 2007-11-01 03:29:24-04:00, clemens@pogo.udel.edu +1 -0 + The original version of LinuxPPS did not comply with the PPSAPI and required + some changes to the startup code in refclock_oncore.c . The current version + complies, and these changes can be removed. + + ntpd/refclock_oncore.c@1.60.1.2, 2007-11-01 03:29:21-04:00, clemens@pogo.udel.edu +1 -56 + The original version of LinuxPPS did not comply with the PPSAPI and required + some changes to the startup code in refclock_oncore.c . The current version + complies, and these changes can be removed. + +ChangeSet@1.1651, 2007-11-01 03:24:16-04:00, clemens@pogo.udel.edu +1 -0 + The original version of LinuxPPS did not comply with the PPSAPI and required + some changes to the startup code in refclock_oncore.c . The current version + complies, and these changes can be removed. + + ntpd/refclock_oncore.c@1.63, 2007-11-01 03:24:14-04:00, clemens@pogo.udel.edu +1 -56 + The original version of LinuxPPS did not comply with the PPSAPI and required + some changes to the startup code in refclock_oncore.c . The current version + complies, and these changes can be removed. + +ChangeSet@1.1436.1.85, 2007-11-01 02:16:36-04:00, clemens@pogo.udel.edu +1 -0 + The oncore hardware provides a 'negative saw-tooth' the offset of the PPS signal + which is on the zero crossing of its internal clock, from its true value. the + refclock_oncore.c driver applies this difference to correct the time of the + provided timestamp. This value was being applied correctly for the 6 and 8 channel + receivers, but not for the 12 channel. This has been corrected. + + ntpd/refclock_oncore.c@1.60.1.1, 2007-11-01 02:16:33-04:00, clemens@pogo.udel.edu +2 -2 + The oncore hardware provides a 'negative saw-tooth' the offset of the PPS signal + which is on the zero crossing of its internal clock, from its true value. the + refclock_oncore.c driver applies this difference to correct the time of the + provided timestamp. This value was being applied correctly for the 6 and 8 channel + receivers, but not for the 12 channel. This has been corrected. + +ChangeSet@1.1650, 2007-11-01 02:13:19-04:00, clemens@pogo.udel.edu +1 -0 + ntpd/refclock_oncore.c + The oncore hardware provides a 'negative saw-tooth' the offset of the PPS signal + which is on the zero crossing of its internal clock, from its true value. the + refclock_oncore.c driver applies this difference to correct the time of the + provided timestamp. This value was being applied correctly for the 6 and 8 channel + receivers, but not for the 12 channel. This has been corrected. + + ntpd/refclock_oncore.c@1.62, 2007-11-01 02:13:15-04:00, clemens@pogo.udel.edu +2 -2 + The oncore hardware provides a 'negative saw-tooth' the offset of the PPS signal + which is on the zero crossing of its internal clock, from its true value. the + refclock_oncore.c driver applies this difference to correct the time of the + provided timestamp. This value was being applied correctly for the 6 and 8 channel + receivers, but not for the 12 channel. This has been corrected. + +ChangeSet@1.1649, 2007-10-31 06:46:05-05:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P93 + TAG: NTP_4_2_5P93 + + ntpd/ntpd-opts.c@1.82, 2007-10-31 06:45:46-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P93 + + ntpd/ntpd-opts.h@1.82, 2007-10-31 06:45:47-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P93 + + ntpd/ntpd-opts.texi@1.81, 2007-10-31 06:45:48-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P93 + + ntpd/ntpd.1@1.81, 2007-10-31 06:45:48-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P93 + + ntpdc/ntpdc-opts.c@1.80, 2007-10-31 06:45:49-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P93 + + ntpdc/ntpdc-opts.h@1.80, 2007-10-31 06:45:50-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P93 + + ntpdc/ntpdc-opts.texi@1.79, 2007-10-31 06:45:51-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P93 + + ntpdc/ntpdc.1@1.79, 2007-10-31 06:45:51-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P93 + + ntpq/ntpq-opts.c@1.80, 2007-10-31 06:45:52-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P93 + + ntpq/ntpq-opts.h@1.80, 2007-10-31 06:45:53-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P93 + + ntpq/ntpq-opts.texi@1.79, 2007-10-31 06:45:54-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P93 + + ntpq/ntpq.1@1.79, 2007-10-31 06:45:54-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P93 + + packageinfo.sh@1.96, 2007-10-31 06:45:56-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P93 + + sntp/sntp-opts.c@1.80, 2007-10-31 06:45:56-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P93 + + sntp/sntp-opts.h@1.80, 2007-10-31 06:45:57-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P93 + + sntp/sntp-opts.texi@1.79, 2007-10-31 06:45:58-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P93 + + sntp/sntp.1@1.79, 2007-10-31 06:45:58-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P93 + + util/ntp-keygen-opts.c@1.81, 2007-10-31 06:45:59-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P93 + + util/ntp-keygen-opts.h@1.81, 2007-10-31 06:46:00-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P93 + + util/ntp-keygen-opts.texi@1.80, 2007-10-31 06:46:01-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P93 + + util/ntp-keygen.1@1.80, 2007-10-31 06:46:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P93 + +ChangeSet@1.1648, 2007-10-31 01:26:20-05:00, stenn@whimsy.udel.edu +1 -0 + Document the reasoning behind the c_d directory variable + + flock-build@1.41, 2007-10-31 01:26:09-05:00, stenn@whimsy.udel.edu +2 -0 + Document the reasoning behind the c_d directory variable + +ChangeSet@1.1647, 2007-10-30 06:46:30-05:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P92 + TAG: NTP_4_2_5P92 + + ntpd/ntpd-opts.c@1.81, 2007-10-30 06:46:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P92 + + ntpd/ntpd-opts.h@1.81, 2007-10-30 06:46:10-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P92 + + ntpd/ntpd-opts.texi@1.80, 2007-10-30 06:46:12-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P92 + + ntpd/ntpd.1@1.80, 2007-10-30 06:46:13-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P92 + + ntpdc/ntpdc-opts.c@1.79, 2007-10-30 06:46:13-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P92 + + ntpdc/ntpdc-opts.h@1.79, 2007-10-30 06:46:14-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P92 + + ntpdc/ntpdc-opts.texi@1.78, 2007-10-30 06:46:15-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P92 + + ntpdc/ntpdc.1@1.78, 2007-10-30 06:46:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P92 + + ntpq/ntpq-opts.c@1.79, 2007-10-30 06:46:17-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P92 + + ntpq/ntpq-opts.h@1.79, 2007-10-30 06:46:17-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P92 + + ntpq/ntpq-opts.texi@1.78, 2007-10-30 06:46:18-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P92 + + ntpq/ntpq.1@1.78, 2007-10-30 06:46:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P92 + + packageinfo.sh@1.95, 2007-10-30 06:46:20-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P92 + + sntp/sntp-opts.c@1.79, 2007-10-30 06:46:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P92 + + sntp/sntp-opts.h@1.79, 2007-10-30 06:46:21-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P92 + + sntp/sntp-opts.texi@1.78, 2007-10-30 06:46:22-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P92 + + sntp/sntp.1@1.78, 2007-10-30 06:46:23-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P92 + + util/ntp-keygen-opts.c@1.80, 2007-10-30 06:46:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P92 + + util/ntp-keygen-opts.h@1.80, 2007-10-30 06:46:24-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P92 + + util/ntp-keygen-opts.texi@1.79, 2007-10-30 06:46:25-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P92 + + util/ntp-keygen.1@1.79, 2007-10-30 06:46:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P92 + +ChangeSet@1.1646, 2007-10-30 02:27:06-05:00, stenn@whimsy.udel.edu +2 -0 + ntpsim.c: add missing protypes and fix [CID 34], a nit + + ChangeLog@1.140, 2007-10-30 02:26:53-05:00, stenn@whimsy.udel.edu +1 -0 + ntpsim.c: add missing protypes and fix [CID 34], a nit + + ntpd/ntpsim.c@1.19, 2007-10-30 02:26:54-05:00, stenn@whimsy.udel.edu +7 -0 + ntpsim.c: add missing protypes and fix [CID 34], a nit + +ChangeSet@1.1645, 2007-10-30 01:31:05-05:00, stenn@whimsy.udel.edu +1 -0 + ntp_scanner.c: + reindent + + ntpd/ntp_scanner.c@1.12, 2007-10-30 01:30:53-05:00, stenn@whimsy.udel.edu +377 -360 + reindent + +ChangeSet@1.1644, 2007-10-30 01:09:30-05:00, stenn@whimsy.udel.edu +5 -0 + ntp_parser.h, ntp_parser.c, ChangeLog: + Upgraded bison at UDel + br-flock, ChangeLog, flock-build: + Update br-flock and flock-build machine lists + + ChangeLog@1.139, 2007-10-30 01:09:03-05:00, stenn@whimsy.udel.edu +1 -0 + Upgraded bison at UDel + + ChangeLog@1.138, 2007-10-30 01:08:20-05:00, stenn@whimsy.udel.edu +1 -0 + Update br-flock and flock-build machine lists + + br-flock@1.12, 2007-10-30 01:07:55-05:00, stenn@whimsy.udel.edu +1 -1 + Update br-flock and flock-build machine lists + + flock-build@1.40, 2007-10-30 01:07:55-05:00, stenn@whimsy.udel.edu +6 -5 + Update br-flock and flock-build machine lists + + ntpd/ntp_parser.c@1.24, 2007-10-30 01:09:06-05:00, stenn@whimsy.udel.edu +1072 -684 + Upgraded bison at UDel + + ntpd/ntp_parser.h@1.10, 2007-10-30 01:09:08-05:00, stenn@whimsy.udel.edu +29 -20 + Upgraded bison at UDel + +ChangeSet@1.1643, 2007-10-29 17:17:35-04:00, neal@pogo.udel.edu +1 -0 + ntp_scanner.c: + [Bug 828] use is_ip_address from ntp_io.c in scanner + + ntpd/ntp_scanner.c@1.11, 2007-10-29 17:16:40-04:00, neal@pogo.udel.edu +5 -43 + [Bug 828] use is_ip_address from ntp_io.c in scanner + +ChangeSet@1.1642, 2007-10-29 10:28:31-04:00, neal@pogo.udel.edu +1 -0 + ntp_scanner.c: + [Bug 828] correct IPv6 address parsing + + ntpd/ntp_scanner.c@1.10, 2007-10-29 10:27:34-04:00, neal@pogo.udel.edu +2 -42 + [Bug 828] correct IPv6 address parsing + +ChangeSet@1.1641, 2007-10-28 20:40:12-04:00, neal@pogo.udel.edu +1 -0 + copyright.html: + add self to copyright notice + + html/copyright.html@1.37, 2007-10-28 20:39:37-04:00, neal@pogo.udel.edu +1 -0 + add self to copyright notice + +ChangeSet@1.1638.1.1, 2007-10-27 12:27:18-04:00, neal@pogo.udel.edu +7 -0 + ntp_io.c: + [Bug 752] QoS: add parser/config support. + Many files: + [Bug 752] QoS: add parser/config support. + + ChangeLog@1.137, 2007-10-27 12:24:10-04:00, neal@pogo.udel.edu +1 -0 + [Bug 752] QoS: add parser/config support. + + include/ntp_config.h@1.46, 2007-10-27 12:26:20-04:00, neal@pogo.udel.edu +24 -0 + [Bug 752] QoS: add parser/config support. + + ntpd/ntp_config.c@1.169, 2007-10-27 12:25:16-04:00, neal@pogo.udel.edu +67 -1 + [Bug 752] QoS: add parser/config support. + + ntpd/ntp_io.c@1.265, 2007-10-27 12:25:38-04:00, neal@pogo.udel.edu +5 -5 + [Bug 752] QoS: add parser/config support. + , + + ntpd/ntp_parser.c@1.23, 2007-10-27 12:25:52-04:00, neal@pogo.udel.edu +2031 -1577 + [Bug 752] QoS: add parser/config support. + + ntpd/ntp_parser.h@1.9, 2007-10-27 12:25:58-04:00, neal@pogo.udel.edu +341 -152 + [Bug 752] QoS: add parser/config support. + + ntpd/ntp_parser.y@1.19, 2007-10-27 12:26:04-04:00, neal@pogo.udel.edu +3 -0 + [Bug 752] QoS: add parser/config support. + +ChangeSet@1.1639, 2007-10-27 07:44:18-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P91 + TAG: NTP_4_2_5P91 + + ntpd/ntpd-opts.c@1.80, 2007-10-27 07:43:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P91 + + ntpd/ntpd-opts.h@1.80, 2007-10-27 07:44:00-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P91 + + ntpd/ntpd-opts.texi@1.79, 2007-10-27 07:44:01-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P91 + + ntpd/ntpd.1@1.79, 2007-10-27 07:44:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P91 + + ntpdc/ntpdc-opts.c@1.78, 2007-10-27 07:44:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P91 + + ntpdc/ntpdc-opts.h@1.78, 2007-10-27 07:44:03-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P91 + + ntpdc/ntpdc-opts.texi@1.77, 2007-10-27 07:44:05-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P91 + + ntpdc/ntpdc.1@1.77, 2007-10-27 07:44:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P91 + + ntpq/ntpq-opts.c@1.78, 2007-10-27 07:44:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P91 + + ntpq/ntpq-opts.h@1.78, 2007-10-27 07:44:07-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P91 + + ntpq/ntpq-opts.texi@1.77, 2007-10-27 07:44:08-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P91 + + ntpq/ntpq.1@1.77, 2007-10-27 07:44:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P91 + + packageinfo.sh@1.94, 2007-10-27 07:44:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P91 + + sntp/sntp-opts.c@1.78, 2007-10-27 07:44:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P91 + + sntp/sntp-opts.h@1.78, 2007-10-27 07:44:10-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P91 + + sntp/sntp-opts.texi@1.77, 2007-10-27 07:44:11-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P91 + + sntp/sntp.1@1.77, 2007-10-27 07:44:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P91 + + util/ntp-keygen-opts.c@1.79, 2007-10-27 07:44:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P91 + + util/ntp-keygen-opts.h@1.79, 2007-10-27 07:44:13-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P91 + + util/ntp-keygen-opts.texi@1.78, 2007-10-27 07:44:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P91 + + util/ntp-keygen.1@1.78, 2007-10-27 07:44:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P91 + +ChangeSet@1.1638, 2007-10-26 17:40:27-04:00, stenn@whimsy.udel.edu +2 -0 + Fix the #include order in tickadj.c for picky machines + + ChangeLog@1.136, 2007-10-26 17:40:16-04:00, stenn@whimsy.udel.edu +1 -0 + Fix the #include order in tickadj.c for picky machines + + util/tickadj.c@1.8, 2007-10-26 17:40:16-04:00, stenn@whimsy.udel.edu +1 -1 + Fix the #include order in tickadj.c for picky machines + +ChangeSet@1.1637, 2007-10-26 07:43:57-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P90 + TAG: NTP_4_2_5P90 + + ntpd/ntpd-opts.c@1.79, 2007-10-26 07:43:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P90 + + ntpd/ntpd-opts.h@1.79, 2007-10-26 07:43:37-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P90 + + ntpd/ntpd-opts.texi@1.78, 2007-10-26 07:43:38-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P90 + + ntpd/ntpd.1@1.78, 2007-10-26 07:43:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P90 + + ntpdc/ntpdc-opts.c@1.77, 2007-10-26 07:43:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P90 + + ntpdc/ntpdc-opts.h@1.77, 2007-10-26 07:43:40-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P90 + + ntpdc/ntpdc-opts.texi@1.76, 2007-10-26 07:43:41-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P90 + + ntpdc/ntpdc.1@1.76, 2007-10-26 07:43:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P90 + + ntpq/ntpq-opts.c@1.77, 2007-10-26 07:43:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P90 + + ntpq/ntpq-opts.h@1.77, 2007-10-26 07:43:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P90 + + ntpq/ntpq-opts.texi@1.76, 2007-10-26 07:43:44-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P90 + + ntpq/ntpq.1@1.76, 2007-10-26 07:43:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P90 + + packageinfo.sh@1.93, 2007-10-26 07:43:45-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P90 + + sntp/sntp-opts.c@1.77, 2007-10-26 07:43:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P90 + + sntp/sntp-opts.h@1.77, 2007-10-26 07:43:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P90 + + sntp/sntp-opts.texi@1.76, 2007-10-26 07:43:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P90 + + sntp/sntp.1@1.76, 2007-10-26 07:43:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P90 + + util/ntp-keygen-opts.c@1.78, 2007-10-26 07:43:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P90 + + util/ntp-keygen-opts.h@1.78, 2007-10-26 07:43:50-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P90 + + util/ntp-keygen-opts.texi@1.77, 2007-10-26 07:43:51-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P90 + + util/ntp-keygen.1@1.77, 2007-10-26 07:43:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P90 + +ChangeSet@1.1636, 2007-10-26 00:30:22-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 752] QoS: On some systems, netinet/ip.h needs netinet/ip_systm.h + + ChangeLog@1.135, 2007-10-26 00:28:50-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 752] QoS: On some systems, netinet/ip.h needs netinet/ip_systm.h + + include/ntp_io.h@1.9, 2007-10-26 00:28:51-04:00, stenn@whimsy.udel.edu +3 -0 + [Bug 752] QoS: On some systems, netinet/ip.h needs netinet/ip_systm.h + +ChangeSet@1.1635, 2007-10-25 07:48:29-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P89 + TAG: NTP_4_2_5P89 + + ntpd/ntpd-opts.c@1.78, 2007-10-25 07:48:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P89 + + ntpd/ntpd-opts.h@1.78, 2007-10-25 07:48:11-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P89 + + ntpd/ntpd-opts.texi@1.77, 2007-10-25 07:48:12-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P89 + + ntpd/ntpd.1@1.77, 2007-10-25 07:48:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P89 + + ntpdc/ntpdc-opts.c@1.76, 2007-10-25 07:48:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P89 + + ntpdc/ntpdc-opts.h@1.76, 2007-10-25 07:48:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P89 + + ntpdc/ntpdc-opts.texi@1.75, 2007-10-25 07:48:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P89 + + ntpdc/ntpdc.1@1.75, 2007-10-25 07:48:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P89 + + ntpq/ntpq-opts.c@1.76, 2007-10-25 07:48:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P89 + + ntpq/ntpq-opts.h@1.76, 2007-10-25 07:48:17-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P89 + + ntpq/ntpq-opts.texi@1.75, 2007-10-25 07:48:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P89 + + ntpq/ntpq.1@1.75, 2007-10-25 07:48:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P89 + + packageinfo.sh@1.92, 2007-10-25 07:48:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P89 + + sntp/sntp-opts.c@1.76, 2007-10-25 07:48:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P89 + + sntp/sntp-opts.h@1.76, 2007-10-25 07:48:20-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P89 + + sntp/sntp-opts.texi@1.75, 2007-10-25 07:48:21-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P89 + + sntp/sntp.1@1.75, 2007-10-25 07:48:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P89 + + util/ntp-keygen-opts.c@1.77, 2007-10-25 07:48:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P89 + + util/ntp-keygen-opts.h@1.77, 2007-10-25 07:48:24-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P89 + + util/ntp-keygen-opts.texi@1.76, 2007-10-25 07:48:25-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P89 + + util/ntp-keygen.1@1.76, 2007-10-25 07:48:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P89 + +ChangeSet@1.1634, 2007-10-25 01:14:55-04:00, stenn@whimsy.udel.edu +4 -0 + [Bug 752] Update the QoS tagging (code only - configuration to follow) + + ChangeLog@1.134, 2007-10-25 01:13:41-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 752] Update the QoS tagging (code only - configuration to follow) + + configure.ac@1.409, 2007-10-25 01:14:18-04:00, stenn@whimsy.udel.edu +18 -0 + [Bug 752] Update the QoS tagging (code only - configuration to follow) + + include/ntp_io.h@1.8, 2007-10-25 01:14:20-04:00, stenn@whimsy.udel.edu +6 -0 + [Bug 752] Update the QoS tagging (code only - configuration to follow) + + ntpd/ntp_io.c@1.264, 2007-10-25 01:14:20-04:00, stenn@whimsy.udel.edu +18 -14 + [Bug 752] Update the QoS tagging (code only - configuration to follow) + +ChangeSet@1.1633, 2007-10-24 22:43:04-04:00, stenn@whimsy.udel.edu +4 -0 + ntp_proto.c: + Orphan mode and other protocol cleanup from Dave Mills + manyopt.html, assoc.html: + Documentation cleanup from Dave Mills + ChangeLog: + Documentation cleanup from Dave Mills + Orphan mode and other protocol cleanup from Dave Mills + + ChangeLog@1.133, 2007-10-24 22:42:25-04:00, stenn@whimsy.udel.edu +2 -0 + Documentation cleanup from Dave Mills + Orphan mode and other protocol cleanup from Dave Mills + + html/assoc.html@1.24, 2007-10-24 22:40:23-04:00, stenn@whimsy.udel.edu +37 -38 + Documentation cleanup from Dave Mills + + html/manyopt.html@1.15, 2007-10-24 22:40:27-04:00, stenn@whimsy.udel.edu +23 -7 + Documentation cleanup from Dave Mills + + ntpd/ntp_proto.c@1.264, 2007-10-24 22:41:50-04:00, stenn@whimsy.udel.edu +43 -68 + Orphan mode and other protocol cleanup from Dave Mills + +ChangeSet@1.1632, 2007-10-23 07:44:01-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P88 + TAG: NTP_4_2_5P88 + + ntpd/ntpd-opts.c@1.77, 2007-10-23 07:43:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P88 + + ntpd/ntpd-opts.h@1.77, 2007-10-23 07:43:42-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P88 + + ntpd/ntpd-opts.texi@1.76, 2007-10-23 07:43:43-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P88 + + ntpd/ntpd.1@1.76, 2007-10-23 07:43:44-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P88 + + ntpdc/ntpdc-opts.c@1.75, 2007-10-23 07:43:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P88 + + ntpdc/ntpdc-opts.h@1.75, 2007-10-23 07:43:45-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P88 + + ntpdc/ntpdc-opts.texi@1.74, 2007-10-23 07:43:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P88 + + ntpdc/ntpdc.1@1.74, 2007-10-23 07:43:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P88 + + ntpq/ntpq-opts.c@1.75, 2007-10-23 07:43:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P88 + + ntpq/ntpq-opts.h@1.75, 2007-10-23 07:43:49-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P88 + + ntpq/ntpq-opts.texi@1.74, 2007-10-23 07:43:49-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P88 + + ntpq/ntpq.1@1.74, 2007-10-23 07:43:50-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P88 + + packageinfo.sh@1.91, 2007-10-23 07:43:51-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P88 + + sntp/sntp-opts.c@1.75, 2007-10-23 07:43:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P88 + + sntp/sntp-opts.h@1.75, 2007-10-23 07:43:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P88 + + sntp/sntp-opts.texi@1.74, 2007-10-23 07:43:53-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P88 + + sntp/sntp.1@1.74, 2007-10-23 07:43:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P88 + + util/ntp-keygen-opts.c@1.76, 2007-10-23 07:43:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P88 + + util/ntp-keygen-opts.h@1.76, 2007-10-23 07:43:55-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P88 + + util/ntp-keygen-opts.texi@1.75, 2007-10-23 07:43:56-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P88 + + util/ntp-keygen.1@1.75, 2007-10-23 07:43:57-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P88 + +ChangeSet@1.1631, 2007-10-22 21:39:01-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 940] ntp-keygen uses -v. Disallow it as a shortcut for --version + + ChangeLog@1.132, 2007-10-22 21:38:32-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 940] ntp-keygen uses -v. Disallow it as a shortcut for --version + + include/copyright.def@1.6, 2007-10-22 21:38:32-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 940] ntp-keygen uses -v. Disallow it as a shortcut for --version + +ChangeSet@1.1630, 2007-10-21 07:47:45-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P87 + TAG: NTP_4_2_5P87 + + ntpd/ntpd-opts.c@1.76, 2007-10-21 07:47:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P87 + + ntpd/ntpd-opts.h@1.76, 2007-10-21 07:47:27-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P87 + + ntpd/ntpd-opts.texi@1.75, 2007-10-21 07:47:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P87 + + ntpd/ntpd.1@1.75, 2007-10-21 07:47:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P87 + + ntpdc/ntpdc-opts.c@1.74, 2007-10-21 07:47:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P87 + + ntpdc/ntpdc-opts.h@1.74, 2007-10-21 07:47:29-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P87 + + ntpdc/ntpdc-opts.texi@1.73, 2007-10-21 07:47:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P87 + + ntpdc/ntpdc.1@1.73, 2007-10-21 07:47:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P87 + + ntpq/ntpq-opts.c@1.74, 2007-10-21 07:47:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P87 + + ntpq/ntpq-opts.h@1.74, 2007-10-21 07:47:33-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P87 + + ntpq/ntpq-opts.texi@1.73, 2007-10-21 07:47:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P87 + + ntpq/ntpq.1@1.73, 2007-10-21 07:47:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P87 + + packageinfo.sh@1.90, 2007-10-21 07:47:34-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P87 + + sntp/sntp-opts.c@1.74, 2007-10-21 07:47:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P87 + + sntp/sntp-opts.h@1.74, 2007-10-21 07:47:36-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P87 + + sntp/sntp-opts.texi@1.73, 2007-10-21 07:47:37-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P87 + + sntp/sntp.1@1.73, 2007-10-21 07:47:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P87 + + util/ntp-keygen-opts.c@1.75, 2007-10-21 07:47:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P87 + + util/ntp-keygen-opts.h@1.75, 2007-10-21 07:47:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P87 + + util/ntp-keygen-opts.texi@1.74, 2007-10-21 07:47:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P87 + + util/ntp-keygen.1@1.74, 2007-10-21 07:47:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P87 + +ChangeSet@1.1629, 2007-10-20 18:30:10-04:00, stenn@whimsy.udel.edu +2 -0 + more cleanup to ntp_lineeditlibs.m4 + + ChangeLog@1.131, 2007-10-20 18:29:55-04:00, stenn@whimsy.udel.edu +1 -0 + more cleanup to ntp_lineeditlibs.m4 + + m4/ntp_lineeditlibs.m4@1.3, 2007-10-20 18:29:55-04:00, stenn@whimsy.udel.edu +46 -39 + more cleanup to ntp_lineeditlibs.m4 + +ChangeSet@1.1628, 2007-10-20 07:44:48-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P86 + TAG: NTP_4_2_5P86 + + ntpd/ntpd-opts.c@1.75, 2007-10-20 07:44:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P86 + + ntpd/ntpd-opts.h@1.75, 2007-10-20 07:44:28-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P86 + + ntpd/ntpd-opts.texi@1.74, 2007-10-20 07:44:29-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P86 + + ntpd/ntpd.1@1.74, 2007-10-20 07:44:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P86 + + ntpdc/ntpdc-opts.c@1.73, 2007-10-20 07:44:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P86 + + ntpdc/ntpdc-opts.h@1.73, 2007-10-20 07:44:31-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P86 + + ntpdc/ntpdc-opts.texi@1.72, 2007-10-20 07:44:32-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P86 + + ntpdc/ntpdc.1@1.72, 2007-10-20 07:44:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P86 + + ntpq/ntpq-opts.c@1.73, 2007-10-20 07:44:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P86 + + ntpq/ntpq-opts.h@1.73, 2007-10-20 07:44:34-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P86 + + ntpq/ntpq-opts.texi@1.72, 2007-10-20 07:44:35-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P86 + + ntpq/ntpq.1@1.72, 2007-10-20 07:44:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P86 + + packageinfo.sh@1.89, 2007-10-20 07:44:36-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P86 + + sntp/sntp-opts.c@1.73, 2007-10-20 07:44:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P86 + + sntp/sntp-opts.h@1.73, 2007-10-20 07:44:38-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P86 + + sntp/sntp-opts.texi@1.72, 2007-10-20 07:44:39-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P86 + + sntp/sntp.1@1.72, 2007-10-20 07:44:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P86 + + util/ntp-keygen-opts.c@1.74, 2007-10-20 07:44:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P86 + + util/ntp-keygen-opts.h@1.74, 2007-10-20 07:44:40-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P86 + + util/ntp-keygen-opts.texi@1.73, 2007-10-20 07:44:42-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P86 + + util/ntp-keygen.1@1.73, 2007-10-20 07:44:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P86 + +ChangeSet@1.1627, 2007-10-20 01:32:29-04:00, stenn@whimsy.udel.edu +6 -0 + Documentation updates from Dave Mills + + ChangeLog@1.130, 2007-10-20 01:30:05-04:00, stenn@whimsy.udel.edu +1 -0 + Documentation updates from Dave Mills + + html/assoc.html@1.23, 2007-10-20 01:30:16-04:00, stenn@whimsy.udel.edu +39 -30 + Documentation updates from Dave Mills + + html/confopt.html@1.38, 2007-10-20 01:30:18-04:00, stenn@whimsy.udel.edu +35 -35 + Documentation updates from Dave Mills + + html/manyopt.html@1.14, 2007-10-20 01:30:20-04:00, stenn@whimsy.udel.edu +6 -38 + Documentation updates from Dave Mills + + html/miscopt.html@1.37, 2007-10-20 01:30:21-04:00, stenn@whimsy.udel.edu +22 -1 + Documentation updates from Dave Mills + + html/scripts/links7.txt@1.4, 2007-10-20 01:30:40-04:00, stenn@whimsy.udel.edu +1 -0 + Documentation updates from Dave Mills + +ChangeSet@1.1626, 2007-10-19 07:44:27-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P85 + TAG: NTP_4_2_5P85 + + ntpd/ntpd-opts.c@1.74, 2007-10-19 07:44:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P85 + + ntpd/ntpd-opts.h@1.74, 2007-10-19 07:44:10-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P85 + + ntpd/ntpd-opts.texi@1.73, 2007-10-19 07:44:10-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P85 + + ntpd/ntpd.1@1.73, 2007-10-19 07:44:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P85 + + ntpdc/ntpdc-opts.c@1.72, 2007-10-19 07:44:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P85 + + ntpdc/ntpdc-opts.h@1.72, 2007-10-19 07:44:13-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P85 + + ntpdc/ntpdc-opts.texi@1.71, 2007-10-19 07:44:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P85 + + ntpdc/ntpdc.1@1.71, 2007-10-19 07:44:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P85 + + ntpq/ntpq-opts.c@1.72, 2007-10-19 07:44:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P85 + + ntpq/ntpq-opts.h@1.72, 2007-10-19 07:44:15-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P85 + + ntpq/ntpq-opts.texi@1.71, 2007-10-19 07:44:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P85 + + ntpq/ntpq.1@1.71, 2007-10-19 07:44:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P85 + + packageinfo.sh@1.88, 2007-10-19 07:44:18-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P85 + + sntp/sntp-opts.c@1.72, 2007-10-19 07:44:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P85 + + sntp/sntp-opts.h@1.72, 2007-10-19 07:44:19-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P85 + + sntp/sntp-opts.texi@1.71, 2007-10-19 07:44:20-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P85 + + sntp/sntp.1@1.71, 2007-10-19 07:44:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P85 + + util/ntp-keygen-opts.c@1.73, 2007-10-19 07:44:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P85 + + util/ntp-keygen-opts.h@1.73, 2007-10-19 07:44:22-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P85 + + util/ntp-keygen-opts.texi@1.72, 2007-10-19 07:44:23-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P85 + + util/ntp-keygen.1@1.72, 2007-10-19 07:44:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P85 + +ChangeSet@1.1625, 2007-10-19 06:57:12+00:00, stenn@ntp1.isc.org +3 -0 + -ledit cleanup for ntpdc and ntpq. + + ChangeLog@1.129, 2007-10-19 06:57:04+00:00, stenn@ntp1.isc.org +1 -0 + -ledit cleanup for ntpdc and ntpq. + + ntpdc/ntpdc.c@1.58, 2007-10-19 06:57:00+00:00, stenn@ntp1.isc.org +3 -3 + -ledit cleanup for ntpdc and ntpq. + + ntpq/ntpq.c@1.72, 2007-10-19 06:56:53+00:00, stenn@ntp1.isc.org +3 -3 + -ledit cleanup for ntpdc and ntpq. + +ChangeSet@1.1624, 2007-10-18 07:49:09-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P84 + TAG: NTP_4_2_5P84 + + ntpd/ntpd-opts.c@1.73, 2007-10-18 07:48:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P84 + + ntpd/ntpd-opts.h@1.73, 2007-10-18 07:48:51-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P84 + + ntpd/ntpd-opts.texi@1.72, 2007-10-18 07:48:52-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P84 + + ntpd/ntpd.1@1.72, 2007-10-18 07:48:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P84 + + ntpdc/ntpdc-opts.c@1.71, 2007-10-18 07:48:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P84 + + ntpdc/ntpdc-opts.h@1.71, 2007-10-18 07:48:54-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P84 + + ntpdc/ntpdc-opts.texi@1.70, 2007-10-18 07:48:55-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P84 + + ntpdc/ntpdc.1@1.70, 2007-10-18 07:48:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P84 + + ntpq/ntpq-opts.c@1.71, 2007-10-18 07:48:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P84 + + ntpq/ntpq-opts.h@1.71, 2007-10-18 07:48:57-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P84 + + ntpq/ntpq-opts.texi@1.70, 2007-10-18 07:48:57-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P84 + + ntpq/ntpq.1@1.70, 2007-10-18 07:48:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P84 + + packageinfo.sh@1.87, 2007-10-18 07:48:59-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P84 + + sntp/sntp-opts.c@1.71, 2007-10-18 07:49:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P84 + + sntp/sntp-opts.h@1.71, 2007-10-18 07:49:00-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P84 + + sntp/sntp-opts.texi@1.70, 2007-10-18 07:49:01-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P84 + + sntp/sntp.1@1.70, 2007-10-18 07:49:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P84 + + util/ntp-keygen-opts.c@1.72, 2007-10-18 07:49:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P84 + + util/ntp-keygen-opts.h@1.72, 2007-10-18 07:49:03-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P84 + + util/ntp-keygen-opts.texi@1.71, 2007-10-18 07:49:04-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P84 + + util/ntp-keygen.1@1.71, 2007-10-18 07:49:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P84 + +ChangeSet@1.1623, 2007-10-18 01:57:55-04:00, stenn@whimsy.udel.edu +1 -0 + README.hackers: + cleanup + + README.hackers@1.11, 2007-10-18 01:57:32-04:00, stenn@whimsy.udel.edu +0 -13 + cleanup + +ChangeSet@1.1622, 2007-10-18 01:52:51-04:00, stenn@whimsy.udel.edu +6 -0 + refclock_acts.c, ntp_peer.c, ChangeLog, ntp_proto.c, ntp_config.c: + Association and other cleanup from Dave Mills + ntp.h: + NTP_UNREACH changes from Dave Mills. + + ChangeLog@1.128, 2007-10-18 01:52:32-04:00, stenn@whimsy.udel.edu +2 -0 + Association and other cleanup from Dave Mills + + include/ntp.h@1.139, 2007-10-18 01:48:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_UNREACH changes from Dave Mills. + + ntpd/ntp_config.c@1.168, 2007-10-18 01:51:59-04:00, stenn@whimsy.udel.edu +20 -24 + Association and other cleanup from Dave Mills + + ntpd/ntp_peer.c@1.108, 2007-10-18 01:52:04-04:00, stenn@whimsy.udel.edu +45 -65 + Association and other cleanup from Dave Mills + + ntpd/ntp_proto.c@1.263, 2007-10-18 01:52:05-04:00, stenn@whimsy.udel.edu +11 -34 + Association and other cleanup from Dave Mills + + ntpd/refclock_acts.c@1.32, 2007-10-18 01:52:11-04:00, stenn@whimsy.udel.edu +2 -0 + Association and other cleanup from Dave Mills + +ChangeSet@1.1621, 2007-10-17 20:21:31-04:00, stenn@whimsy.udel.edu +2 -0 + Fix the readline history test + + ChangeLog@1.127, 2007-10-17 20:21:15-04:00, stenn@whimsy.udel.edu +1 -0 + Fix the readline history test + + m4/ntp_lineeditlibs.m4@1.2, 2007-10-17 20:21:16-04:00, stenn@whimsy.udel.edu +4 -1 + Fix the readline history test + +ChangeSet@1.1620, 2007-10-15 07:49:05-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P83 + TAG: NTP_4_2_5P83 + + ntpd/ntpd-opts.c@1.72, 2007-10-15 07:48:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P83 + + ntpd/ntpd-opts.h@1.72, 2007-10-15 07:48:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P83 + + ntpd/ntpd-opts.texi@1.71, 2007-10-15 07:48:48-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P83 + + ntpd/ntpd.1@1.71, 2007-10-15 07:48:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P83 + + ntpdc/ntpdc-opts.c@1.70, 2007-10-15 07:48:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P83 + + ntpdc/ntpdc-opts.h@1.70, 2007-10-15 07:48:50-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P83 + + ntpdc/ntpdc-opts.texi@1.69, 2007-10-15 07:48:50-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P83 + + ntpdc/ntpdc.1@1.69, 2007-10-15 07:48:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P83 + + ntpq/ntpq-opts.c@1.70, 2007-10-15 07:48:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P83 + + ntpq/ntpq-opts.h@1.70, 2007-10-15 07:48:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P83 + + ntpq/ntpq-opts.texi@1.69, 2007-10-15 07:48:53-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P83 + + ntpq/ntpq.1@1.69, 2007-10-15 07:48:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P83 + + packageinfo.sh@1.86, 2007-10-15 07:48:55-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P83 + + sntp/sntp-opts.c@1.70, 2007-10-15 07:48:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P83 + + sntp/sntp-opts.h@1.70, 2007-10-15 07:48:56-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P83 + + sntp/sntp-opts.texi@1.69, 2007-10-15 07:48:57-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P83 + + sntp/sntp.1@1.69, 2007-10-15 07:48:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P83 + + util/ntp-keygen-opts.c@1.71, 2007-10-15 07:48:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P83 + + util/ntp-keygen-opts.h@1.71, 2007-10-15 07:48:59-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P83 + + util/ntp-keygen-opts.texi@1.70, 2007-10-15 07:49:00-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P83 + + util/ntp-keygen.1@1.70, 2007-10-15 07:49:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P83 + +ChangeSet@1.1619, 2007-10-15 04:52:10-04:00, stenn@whimsy.udel.edu +7 -0 + ChangeLog: + [Bug 931] Require -lreadline to be asked for explicitly. + [Bug 764] When looking for -lreadline support, also try using -lncurses. + Use new line edit library autoconf macro. + configure.ac: + Use the NTP_LINEEDITLIBS macro now. + Makefile.am, ntpdc.c, ntpq.c: + Use new line editing library detection code + ntp_lineeditlibs.m4: + BitKeeper file /deacon/backroom/ntp-dev-hms/m4/ntp_lineeditlibs.m4 + + ChangeLog@1.126, 2007-10-15 04:50:14-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 931] Require -lreadline to be asked for explicitly. + [Bug 764] When looking for -lreadline support, also try using -lncurses. + Use new line edit library autoconf macro. + + configure.ac@1.408, 2007-10-15 04:43:03-04:00, stenn@whimsy.udel.edu +2 -26 + Use the NTP_LINEEDITLIBS macro now. + + m4/ntp_lineeditlibs.m4@1.1, 2007-10-15 04:41:30-04:00, stenn@whimsy.udel.edu +86 -0 + BitKeeper file /deacon/backroom/ntp-dev-hms/m4/ntp_lineeditlibs.m4 + + m4/ntp_lineeditlibs.m4@1.0, 2007-10-15 04:41:30-04:00, stenn@whimsy.udel.edu +0 -0 + + ntpdc/Makefile.am@1.37, 2007-10-15 04:48:54-04:00, stenn@whimsy.udel.edu +1 -1 + Use new line editing library detection code + + ntpdc/ntpdc.c@1.57, 2007-10-15 04:48:55-04:00, stenn@whimsy.udel.edu +6 -2 + Use new line editing library detection code + + ntpq/Makefile.am@1.29, 2007-10-15 04:49:02-04:00, stenn@whimsy.udel.edu +1 -1 + Use new line editing library detection code + + ntpq/ntpq.c@1.71, 2007-10-15 04:49:03-04:00, stenn@whimsy.udel.edu +6 -2 + Use new line editing library detection code + +ChangeSet@1.1618, 2007-10-14 07:44:25-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P82 + TAG: NTP_4_2_5P82 + + ntpd/ntpd-opts.c@1.71, 2007-10-14 07:44:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P82 + + ntpd/ntpd-opts.h@1.71, 2007-10-14 07:44:06-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P82 + + ntpd/ntpd-opts.texi@1.70, 2007-10-14 07:44:07-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P82 + + ntpd/ntpd.1@1.70, 2007-10-14 07:44:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P82 + + ntpdc/ntpdc-opts.c@1.69, 2007-10-14 07:44:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P82 + + ntpdc/ntpdc-opts.h@1.69, 2007-10-14 07:44:09-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P82 + + ntpdc/ntpdc-opts.texi@1.68, 2007-10-14 07:44:11-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P82 + + ntpdc/ntpdc.1@1.68, 2007-10-14 07:44:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P82 + + ntpq/ntpq-opts.c@1.69, 2007-10-14 07:44:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P82 + + ntpq/ntpq-opts.h@1.69, 2007-10-14 07:44:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P82 + + ntpq/ntpq-opts.texi@1.68, 2007-10-14 07:44:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P82 + + ntpq/ntpq.1@1.68, 2007-10-14 07:44:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P82 + + packageinfo.sh@1.85, 2007-10-14 07:44:15-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P82 + + sntp/sntp-opts.c@1.69, 2007-10-14 07:44:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P82 + + sntp/sntp-opts.h@1.69, 2007-10-14 07:44:17-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P82 + + sntp/sntp-opts.texi@1.68, 2007-10-14 07:44:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P82 + + sntp/sntp.1@1.68, 2007-10-14 07:44:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P82 + + util/ntp-keygen-opts.c@1.70, 2007-10-14 07:44:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P82 + + util/ntp-keygen-opts.h@1.70, 2007-10-14 07:44:19-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P82 + + util/ntp-keygen-opts.texi@1.69, 2007-10-14 07:44:20-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P82 + + util/ntp-keygen.1@1.69, 2007-10-14 07:44:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P82 + +ChangeSet@1.1617, 2007-10-14 03:35:11-04:00, stenn@pogo.udel.edu +1 -0 + Reformat entries + + ChangeLog@1.125, 2007-10-14 03:35:02-04:00, stenn@pogo.udel.edu +5 -5 + Reformat entries + +ChangeSet@1.1616, 2007-10-13 21:47:27-04:00, mayer@pogo.udel.edu +2 -0 + Bug #909 Fix int32_t errors for ntohl() + + ntpdc/ntpdc_ops.c@1.52, 2007-10-13 21:46:37-04:00, mayer@pogo.udel.edu +107 -107 + Bug #909 Fix int32_t errors for ntohl() + + ports/winnt/include/config.h@1.52, 2007-10-13 21:46:59-04:00, mayer@pogo.udel.edu +1 -0 + Bug #909 Fix int32_t errors for ntohl() + +ChangeSet@1.1615, 2007-10-08 15:47:23-04:00, mayer@pogo.udel.edu +1 -0 + Bug #909 Fix int32_t errors for ntohl() + + ChangeLog@1.124, 2007-10-08 15:47:10-04:00, mayer@pogo.udel.edu +1 -0 + Bug #909 Fix int32_t errors for ntohl() + +ChangeSet@1.1614, 2007-10-08 15:45:47-04:00, mayer@pogo.udel.edu +1 -0 + Bug #909 Fix int32_t errors for ntohl() + + ntpdc/ntpdc_ops.c@1.51, 2007-10-08 15:45:15-04:00, mayer@pogo.udel.edu +107 -107 + Bug #909 Fix int32_t errors for ntohl() + +ChangeSet@1.1613, 2007-10-07 20:47:32-04:00, mayer@pogo.udel.edu +1 -0 + Bug #376/214 enhancements + + ChangeLog@1.123, 2007-10-07 20:46:55-04:00, mayer@pogo.udel.edu +1 -0 + +ChangeSet@1.1612, 2007-10-07 12:27:06-04:00, mayer@pogo.udel.edu +3 -0 + Bug #376/214 Enhancements to support multiple if names and IP addresses + + include/ntp_io.h@1.7, 2007-10-07 12:26:20-04:00, mayer@pogo.udel.edu +6 -0 + Bug #376/214 Enhancements to support multiple if names and IP addresses + + ntpd/ntp_io.c@1.263, 2007-10-07 12:26:20-04:00, mayer@pogo.udel.edu +151 -2 + Bug #376/214 Enhancements to support multiple if names and IP addresses + + ntpd/ntpd.c@1.90, 2007-10-07 12:26:20-04:00, mayer@pogo.udel.edu +7 -6 + Bug #376/214 Enhancements to support multiple if names and IP addresses + +ChangeSet@1.1611, 2007-10-05 09:54:42-04:00, mayer@pogo.udel.edu +1 -0 + Bug #788 Update macros to support VS 2005 + + ports/winnt/include/config.h@1.51, 2007-10-05 09:54:28-04:00, mayer@pogo.udel.edu +3 -1 + Bug #788 Update macros to support VS 2005 + +ChangeSet@1.1610, 2007-10-05 09:20:49-04:00, mayer@pogo.udel.edu +1 -0 + New bug fixes + + ChangeLog@1.122, 2007-10-05 09:20:36-04:00, mayer@pogo.udel.edu +3 -0 + New bug fixes + +ChangeSet@1.1609, 2007-10-05 09:17:12-04:00, mayer@pogo.udel.edu +1 -0 + Bug #929 int32_t is undefined on Windows. Casting wrong + + ntpdc/ntpdc_ops.c@1.50, 2007-10-05 09:16:40-04:00, mayer@pogo.udel.edu +4 -4 + Bug #929 int32_t is undefined on Windows. Casting wrong + +ChangeSet@1.1608, 2007-10-05 08:57:08-04:00, mayer@pogo.udel.edu +1 -0 + Bug #928 readlink missing braces + + util/ntp-keygen.c@1.46, 2007-10-05 08:56:53-04:00, mayer@pogo.udel.edu +2 -2 + Bug #928 readlink missing braces + +ChangeSet@1.1607, 2007-10-05 08:46:39-04:00, mayer@pogo.udel.edu +7 -0 + Bug #788 Update macros to support VS 2005 + + ports/winnt/instsrv/Instsrv.dsp@1.7, 2007-10-05 08:45:00-04:00, mayer@pogo.udel.edu +2 -2 + Bug #788 Update macros to support VS 2005 + + ports/winnt/libntp/libntp.dsp@1.31, 2007-10-05 08:45:00-04:00, mayer@pogo.udel.edu +2 -2 + Bug #788 Update macros to support VS 2005 + + ports/winnt/ntp-keygen/ntpkeygen.dsp@1.12, 2007-10-05 08:45:59-04:00, mayer@pogo.udel.edu +4 -4 + Bug #788 Update macros to support VS 2005 + + ports/winnt/ntpd/ntpd.dsp@1.31, 2007-10-05 08:45:00-04:00, mayer@pogo.udel.edu +2 -2 + Bug #788 Update macros to support VS 2005 + + ports/winnt/ntpdate/ntpdate.dsp@1.16, 2007-10-05 08:45:00-04:00, mayer@pogo.udel.edu +2 -2 + Bug #788 Update macros to support VS 2005 + + ports/winnt/ntpdc/ntpdc.dsp@1.19, 2007-10-05 08:45:00-04:00, mayer@pogo.udel.edu +2 -2 + Bug #788 Update macros to support VS 2005 + + ports/winnt/ntpq/ntpq.dsp@1.20, 2007-10-05 08:45:00-04:00, mayer@pogo.udel.edu +2 -2 + Bug #788 Update macros to support VS 2005 + +ChangeSet@1.1606, 2007-10-04 07:45:47-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P81 + TAG: NTP_4_2_5P81 + + ntpd/ntpd-opts.c@1.70, 2007-10-04 07:45:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P81 + + ntpd/ntpd-opts.h@1.70, 2007-10-04 07:45:27-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P81 + + ntpd/ntpd-opts.texi@1.69, 2007-10-04 07:45:28-04:00, stenn@whimsy.udel.edu +3 -5 + NTP_4_2_5P81 + + ntpd/ntpd.1@1.69, 2007-10-04 07:45:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P81 + + ntpdc/ntpdc-opts.c@1.68, 2007-10-04 07:45:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P81 + + ntpdc/ntpdc-opts.h@1.68, 2007-10-04 07:45:30-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P81 + + ntpdc/ntpdc-opts.texi@1.67, 2007-10-04 07:45:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P81 + + ntpdc/ntpdc.1@1.67, 2007-10-04 07:45:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P81 + + ntpq/ntpq-opts.c@1.68, 2007-10-04 07:45:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P81 + + ntpq/ntpq-opts.h@1.68, 2007-10-04 07:45:33-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P81 + + ntpq/ntpq-opts.texi@1.67, 2007-10-04 07:45:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P81 + + ntpq/ntpq.1@1.67, 2007-10-04 07:45:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P81 + + packageinfo.sh@1.84, 2007-10-04 07:45:35-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P81 + + sntp/sntp-opts.c@1.68, 2007-10-04 07:45:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P81 + + sntp/sntp-opts.h@1.68, 2007-10-04 07:45:36-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P81 + + sntp/sntp-opts.texi@1.67, 2007-10-04 07:45:37-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P81 + + sntp/sntp.1@1.67, 2007-10-04 07:45:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P81 + + util/ntp-keygen-opts.c@1.69, 2007-10-04 07:45:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P81 + + util/ntp-keygen-opts.h@1.69, 2007-10-04 07:45:40-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P81 + + util/ntp-keygen-opts.texi@1.68, 2007-10-04 07:45:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P81 + + util/ntp-keygen.1@1.68, 2007-10-04 07:45:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P81 + +ChangeSet@1.1605, 2007-10-04 03:02:00-04:00, stenn@whimsy.udel.edu +1 -0 + documentation update from Dave Mills + + html/authopt.html@1.45, 2007-10-04 03:01:49-04:00, stenn@whimsy.udel.edu +2 -2 + documentation update from Dave Mills + +ChangeSet@1.1599.1.1, 2007-10-03 21:38:31-04:00, stenn@whimsy.udel.edu +9 -0 + Many files: + Lose obsolete crypto subcommands + sco.html, authopt.html: + documentation cleanup + ChangeLog, ntp_control.c: + WWV is an HF source, not an LF source + + ChangeLog@1.116.1.2, 2007-10-03 21:35:45-04:00, stenn@whimsy.udel.edu +1 -0 + Lose obsolete crypto subcommands + + ChangeLog@1.116.1.1, 2007-10-03 21:32:25-04:00, stenn@whimsy.udel.edu +1 -0 + WWV is an HF source, not an LF source + + html/authopt.html@1.44, 2007-10-03 21:37:19-04:00, stenn@whimsy.udel.edu +2 -3 + documentation cleanup + + html/build/hints/sco.html@1.8, 2007-10-03 21:37:20-04:00, stenn@whimsy.udel.edu +1 -0 + documentation cleanup + + ntpd/ntp_config.c@1.167, 2007-10-03 21:33:28-04:00, stenn@whimsy.udel.edu +0 -5 + Lose obsolete crypto subcommands + + ntpd/ntp_control.c@1.102, 2007-10-03 21:31:33-04:00, stenn@whimsy.udel.edu +1 -1 + WWV is an HF source, not an LF source + + ntpd/ntp_crypto.c@1.118, 2007-10-03 21:34:23-04:00, stenn@whimsy.udel.edu +0 -25 + Lose obsolete crypto subcommands + + ntpd/ntp_parser.c@1.22, 2007-10-03 21:34:26-04:00, stenn@whimsy.udel.edu +826 -848 + Lose obsolete crypto subcommands + + ntpd/ntp_parser.h@1.8, 2007-10-03 21:34:29-04:00, stenn@whimsy.udel.edu +132 -136 + Lose obsolete crypto subcommands + + ntpd/ntp_parser.y@1.18, 2007-10-03 21:34:30-04:00, stenn@whimsy.udel.edu +9 -14 + Lose obsolete crypto subcommands + +ChangeSet@1.1603, 2007-09-30 16:40:51+00:00, kardel@pogo.udel.edu +2 -0 + ChangeLog: + ntpd/ntp_timer.c: add missing sys_tai parameter for debug printf + ntp_timer.c: + add missing sys_tai parameter for debug printf + + ChangeLog@1.120, 2007-09-30 16:40:38+00:00, kardel@pogo.udel.edu +1 -0 + ntpd/ntp_timer.c: add missing sys_tai parameter for debug printf + + ntpd/ntp_timer.c@1.41, 2007-09-30 16:38:57+00:00, kardel@pogo.udel.edu +1 -1 + add missing sys_tai parameter for debug printf + +ChangeSet@1.1602, 2007-09-30 16:09:50+00:00, kardel@pogo.udel.edu +2 -0 + ChangeLog: + [Bug 917] config parse leaves files open + ntp_scanner.c: + Bug 917: config parse leaves files open + + ChangeLog@1.119, 2007-09-30 16:09:31+00:00, kardel@pogo.udel.edu +1 -0 + [Bug 917] config parse leaves files open + + ntpd/ntp_scanner.c@1.9, 2007-09-30 16:06:19+00:00, kardel@pogo.udel.edu +3 -2 + Bug 917: config parse leaves files open + +ChangeSet@1.1601, 2007-09-30 16:05:00+00:00, kardel@pogo.udel.edu +2 -0 + ntp_io.c: + Bug 912: detect conflicting enable/disable configuration on interfaces sharing an IP address + ChangeLog: + [Bug 912] detect conflicting enable/disable configuration on interfaces sharing an IP address + + ChangeLog@1.118, 2007-09-30 16:04:44+00:00, kardel@pogo.udel.edu +1 -0 + [Bug 912] detect conflicting enable/disable configuration on interfaces sharing an IP address + + ntpd/ntp_io.c@1.262, 2007-09-30 15:59:48+00:00, kardel@pogo.udel.edu +39 -2 + Bug 912: detect conflicting enable/disable configuration on interfaces sharing an IP address + +ChangeSet@1.1600, 2007-09-30 15:57:52+00:00, kardel@pogo.udel.edu +2 -0 + ChangeLog: + [Bug 771] compare scopeid if available for IPv6 addresses + ntp.h: + Bug 771: compare scopeid if available for IPv6 addresses + + ChangeLog@1.117, 2007-09-30 15:57:26+00:00, kardel@pogo.udel.edu +1 -0 + [Bug 771] compare scopeid if available for IPv6 addresses + + include/ntp.h@1.138, 2007-09-30 15:54:35+00:00, kardel@pogo.udel.edu +7 -1 + Bug 771: compare scopeid if available for IPv6 addresses + +ChangeSet@1.1599, 2007-09-23 07:45:18-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P80 + TAG: NTP_4_2_5P80 + + ntpd/ntpd-opts.c@1.69, 2007-09-23 07:44:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P80 + + ntpd/ntpd-opts.h@1.69, 2007-09-23 07:44:59-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P80 + + ntpd/ntpd-opts.texi@1.68, 2007-09-23 07:45:00-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P80 + + ntpd/ntpd.1@1.68, 2007-09-23 07:45:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P80 + + ntpdc/ntpdc-opts.c@1.67, 2007-09-23 07:45:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P80 + + ntpdc/ntpdc-opts.h@1.67, 2007-09-23 07:45:02-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P80 + + ntpdc/ntpdc-opts.texi@1.66, 2007-09-23 07:45:03-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P80 + + ntpdc/ntpdc.1@1.66, 2007-09-23 07:45:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P80 + + ntpq/ntpq-opts.c@1.67, 2007-09-23 07:45:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P80 + + ntpq/ntpq-opts.h@1.67, 2007-09-23 07:45:05-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P80 + + ntpq/ntpq-opts.texi@1.66, 2007-09-23 07:45:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P80 + + ntpq/ntpq.1@1.66, 2007-09-23 07:45:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P80 + + packageinfo.sh@1.83, 2007-09-23 07:45:07-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P80 + + sntp/sntp-opts.c@1.67, 2007-09-23 07:45:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P80 + + sntp/sntp-opts.h@1.67, 2007-09-23 07:45:09-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P80 + + sntp/sntp-opts.texi@1.66, 2007-09-23 07:45:10-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P80 + + sntp/sntp.1@1.66, 2007-09-23 07:45:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P80 + + util/ntp-keygen-opts.c@1.68, 2007-09-23 07:45:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P80 + + util/ntp-keygen-opts.h@1.68, 2007-09-23 07:45:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P80 + + util/ntp-keygen-opts.texi@1.67, 2007-09-23 07:45:12-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P80 + + util/ntp-keygen.1@1.67, 2007-09-23 07:45:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P80 + +ChangeSet@1.1598, 2007-09-23 03:16:18-04:00, stenn@whimsy.udel.edu +6 -0 + [Bug 899] Only show -i/--jaildir -u/--user options if we HAVE_DROPROOT + + ChangeLog@1.116, 2007-09-23 03:14:57-04:00, stenn@whimsy.udel.edu +1 -1 + [Bug 899] Only show -i/--jaildir -u/--user options if we HAVE_DROPROOT + + ntpd/ntpd-opts.c@1.68, 2007-09-23 03:15:38-04:00, stenn@whimsy.udel.edu +40 -31 + [Bug 899] Only show -i/--jaildir -u/--user options if we HAVE_DROPROOT + + ntpd/ntpd-opts.h@1.68, 2007-09-23 03:15:38-04:00, stenn@whimsy.udel.edu +16 -14 + [Bug 899] Only show -i/--jaildir -u/--user options if we HAVE_DROPROOT + + ntpd/ntpd-opts.texi@1.67, 2007-09-23 03:15:40-04:00, stenn@whimsy.udel.edu +19 -12 + [Bug 899] Only show -i/--jaildir -u/--user options if we HAVE_DROPROOT + + ntpd/ntpd.1@1.67, 2007-09-23 03:15:40-04:00, stenn@whimsy.udel.edu +10 -10 + [Bug 899] Only show -i/--jaildir -u/--user options if we HAVE_DROPROOT + + ntpd/ntpdbase-opts.def@1.13, 2007-09-23 03:15:41-04:00, stenn@whimsy.udel.edu +26 -25 + [Bug 899] Only show -i/--jaildir -u/--user options if we HAVE_DROPROOT + +ChangeSet@1.1597, 2007-09-23 02:06:55-04:00, stenn@whimsy.udel.edu +6 -0 + [Bug 899] Only show -i/--jaildir option if we HAVE_DROPROOT + + ChangeLog@1.115, 2007-09-23 02:05:09-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 899] Only show -i/--jaildir option if we HAVE_DROPROOT + + ntpd/ntpd-opts.c@1.67, 2007-09-23 02:05:54-04:00, stenn@whimsy.udel.edu +10 -1 + [Bug 899] Only show -i/--jaildir option if we HAVE_DROPROOT + + ntpd/ntpd-opts.h@1.67, 2007-09-23 02:05:54-04:00, stenn@whimsy.udel.edu +3 -1 + [Bug 899] Only show -i/--jaildir option if we HAVE_DROPROOT + + ntpd/ntpd-opts.texi@1.66, 2007-09-23 02:05:55-04:00, stenn@whimsy.udel.edu +8 -1 + [Bug 899] Only show -i/--jaildir option if we HAVE_DROPROOT + + ntpd/ntpd.1@1.66, 2007-09-23 02:05:56-04:00, stenn@whimsy.udel.edu +2 -2 + [Bug 899] Only show -i/--jaildir option if we HAVE_DROPROOT + + ntpd/ntpdbase-opts.def@1.12, 2007-09-23 02:05:56-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 899] Only show -i/--jaildir option if we HAVE_DROPROOT + +ChangeSet@1.1596, 2007-09-20 07:43:57-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P79 + TAG: NTP_4_2_5P79 + + ntpd/ntpd-opts.c@1.66, 2007-09-20 07:43:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P79 + + ntpd/ntpd-opts.h@1.66, 2007-09-20 07:43:38-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P79 + + ntpd/ntpd-opts.texi@1.65, 2007-09-20 07:43:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P79 + + ntpd/ntpd.1@1.65, 2007-09-20 07:43:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P79 + + ntpdc/ntpdc-opts.c@1.66, 2007-09-20 07:43:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P79 + + ntpdc/ntpdc-opts.h@1.66, 2007-09-20 07:43:42-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P79 + + ntpdc/ntpdc-opts.texi@1.65, 2007-09-20 07:43:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P79 + + ntpdc/ntpdc.1@1.65, 2007-09-20 07:43:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P79 + + ntpq/ntpq-opts.c@1.66, 2007-09-20 07:43:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P79 + + ntpq/ntpq-opts.h@1.66, 2007-09-20 07:43:45-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P79 + + ntpq/ntpq-opts.texi@1.65, 2007-09-20 07:43:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P79 + + ntpq/ntpq.1@1.65, 2007-09-20 07:43:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P79 + + packageinfo.sh@1.82, 2007-09-20 07:43:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P79 + + sntp/sntp-opts.c@1.66, 2007-09-20 07:43:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P79 + + sntp/sntp-opts.h@1.66, 2007-09-20 07:43:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P79 + + sntp/sntp-opts.texi@1.65, 2007-09-20 07:43:49-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P79 + + sntp/sntp.1@1.65, 2007-09-20 07:43:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P79 + + util/ntp-keygen-opts.c@1.67, 2007-09-20 07:43:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P79 + + util/ntp-keygen-opts.h@1.67, 2007-09-20 07:43:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P79 + + util/ntp-keygen-opts.texi@1.66, 2007-09-20 07:43:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P79 + + util/ntp-keygen.1@1.66, 2007-09-20 07:43:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P79 + +ChangeSet@1.1595, 2007-09-19 14:40:52-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 916] 'cryptosw' is undefined if built without OpenSSL + + ntpd/ntp_config.c@1.166, 2007-09-19 14:39:58-04:00, stenn@whimsy.udel.edu +0 -2 + [Bug 916] 'cryptosw' is undefined if built without OpenSSL + +ChangeSet@1.1594, 2007-09-19 07:45:04-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P78 + TAG: NTP_4_2_5P78 + + ntpd/ntpd-opts.c@1.65, 2007-09-19 07:44:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P78 + + ntpd/ntpd-opts.h@1.65, 2007-09-19 07:44:45-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P78 + + ntpd/ntpd-opts.texi@1.64, 2007-09-19 07:44:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P78 + + ntpd/ntpd.1@1.64, 2007-09-19 07:44:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P78 + + ntpdc/ntpdc-opts.c@1.65, 2007-09-19 07:44:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P78 + + ntpdc/ntpdc-opts.h@1.65, 2007-09-19 07:44:48-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P78 + + ntpdc/ntpdc-opts.texi@1.64, 2007-09-19 07:44:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P78 + + ntpdc/ntpdc.1@1.64, 2007-09-19 07:44:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P78 + + ntpq/ntpq-opts.c@1.65, 2007-09-19 07:44:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P78 + + ntpq/ntpq-opts.h@1.65, 2007-09-19 07:44:51-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P78 + + ntpq/ntpq-opts.texi@1.64, 2007-09-19 07:44:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P78 + + ntpq/ntpq.1@1.64, 2007-09-19 07:44:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P78 + + packageinfo.sh@1.81, 2007-09-19 07:44:54-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P78 + + sntp/sntp-opts.c@1.65, 2007-09-19 07:44:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P78 + + sntp/sntp-opts.h@1.65, 2007-09-19 07:44:55-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P78 + + sntp/sntp-opts.texi@1.64, 2007-09-19 07:44:56-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P78 + + sntp/sntp.1@1.64, 2007-09-19 07:44:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P78 + + util/ntp-keygen-opts.c@1.66, 2007-09-19 07:44:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P78 + + util/ntp-keygen-opts.h@1.66, 2007-09-19 07:44:58-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P78 + + util/ntp-keygen-opts.texi@1.65, 2007-09-19 07:44:58-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P78 + + util/ntp-keygen.1@1.65, 2007-09-19 07:44:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P78 + +ChangeSet@1.1593, 2007-09-19 06:46:54-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 916] 'cryptosw' is undefined if built without OpenSSL + + ChangeLog@1.114, 2007-09-19 06:46:43-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 916] 'cryptosw' is undefined if built without OpenSSL + +ChangeSet@1.1592, 2007-09-19 04:16:11-04:00, stenn@whimsy.udel.edu +2 -0 + Documentation updates + + html/authopt.html@1.43, 2007-09-19 04:15:52-04:00, stenn@whimsy.udel.edu +45 -59 + Documentation updates + + html/keygen.html@1.10, 2007-09-19 04:15:55-04:00, stenn@whimsy.udel.edu +41 -44 + Documentation updates + +ChangeSet@1.1591, 2007-09-19 04:05:50-04:00, stenn@whimsy.udel.edu +6 -0 + [Bug 890] the crypto command seems to be required now\n[Bug 891] 'restrict' config file keyword does not work (partial fix) + + ChangeLog@1.113, 2007-09-19 04:04:52-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 890] the crypto command seems to be required now\n[Bug 891] 'restrict' config file keyword does not work (partial fix) + + ChangeLog@1.112, 2007-09-19 03:48:44-04:00, stenn@whimsy.udel.edu +3 -0 + [Bug 890] the crypto command seems to be required now + + ntpd/ntp_config.c@1.165, 2007-09-19 04:04:54-04:00, stenn@whimsy.udel.edu +9 -1 + [Bug 890] the crypto command seems to be required now\n[Bug 891] 'restrict' config file keyword does not work (partial fix) + + ntpd/ntp_crypto.c@1.117, 2007-09-19 02:25:35-04:00, stenn@whimsy.udel.edu +13 -17 + [Bug 915] ntpd cores during processing of x509 certificates\nRemove lint. + + ntpd/ntp_parser.c@1.21, 2007-09-19 03:48:45-04:00, stenn@whimsy.udel.edu +238 -236 + [Bug 890] the crypto command seems to be required now + + ntpd/ntp_parser.y@1.17, 2007-09-19 03:48:48-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 890] the crypto command seems to be required now + + ntpd/ntp_restrict.c@1.25, 2007-09-19 02:19:55-04:00, stenn@whimsy.udel.edu +6 -1 + restrict processing debug information + +ChangeSet@1.1590, 2007-09-16 07:44:22-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P77 + TAG: NTP_4_2_5P77 + + ntpd/ntpd-opts.c@1.64, 2007-09-16 07:44:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P77 + + ntpd/ntpd-opts.h@1.64, 2007-09-16 07:44:06-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P77 + + ntpd/ntpd-opts.texi@1.63, 2007-09-16 07:44:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P77 + + ntpd/ntpd.1@1.63, 2007-09-16 07:44:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P77 + + ntpdc/ntpdc-opts.c@1.64, 2007-09-16 07:44:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P77 + + ntpdc/ntpdc-opts.h@1.64, 2007-09-16 07:44:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P77 + + ntpdc/ntpdc-opts.texi@1.63, 2007-09-16 07:44:10-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P77 + + ntpdc/ntpdc.1@1.63, 2007-09-16 07:44:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P77 + + ntpq/ntpq-opts.c@1.64, 2007-09-16 07:44:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P77 + + ntpq/ntpq-opts.h@1.64, 2007-09-16 07:44:11-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P77 + + ntpq/ntpq-opts.texi@1.63, 2007-09-16 07:44:12-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P77 + + ntpq/ntpq.1@1.63, 2007-09-16 07:44:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P77 + + packageinfo.sh@1.80, 2007-09-16 07:44:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P77 + + sntp/sntp-opts.c@1.64, 2007-09-16 07:44:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P77 + + sntp/sntp-opts.h@1.64, 2007-09-16 07:44:15-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P77 + + sntp/sntp-opts.texi@1.63, 2007-09-16 07:44:15-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P77 + + sntp/sntp.1@1.63, 2007-09-16 07:44:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P77 + + util/ntp-keygen-opts.c@1.65, 2007-09-16 07:44:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P77 + + util/ntp-keygen-opts.h@1.65, 2007-09-16 07:44:17-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P77 + + util/ntp-keygen-opts.texi@1.64, 2007-09-16 07:44:18-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P77 + + util/ntp-keygen.1@1.64, 2007-09-16 07:44:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P77 + +ChangeSet@1.1589, 2007-09-15 16:40:14-04:00, stenn@whimsy.udel.edu +4 -0 + Crypto cleanup from Dave Mills.\n[Bug 897] Check RAND_status() - we may not need a .rnd file + + ChangeLog@1.111, 2007-09-15 16:40:05-04:00, stenn@whimsy.udel.edu +2 -0 + Crypto cleanup from Dave Mills.\n[Bug 897] Check RAND_status() - we may not need a .rnd file + + ntpd/ntp_control.c@1.101, 2007-09-15 16:37:37-04:00, stenn@whimsy.udel.edu +2 -2 + Crypto cleanup from Dave Mills.\n[Bug 897] Check RAND_status() - we may not need a .rnd file + + ntpd/ntp_crypto.c@1.116, 2007-09-15 16:37:39-04:00, stenn@whimsy.udel.edu +102 -70 + Crypto cleanup from Dave Mills.\n[Bug 897] Check RAND_status() - we may not need a .rnd file + + util/ntp-keygen.c@1.45, 2007-09-15 16:37:13-04:00, stenn@whimsy.udel.edu +143 -202 + Crypto cleanup from Dave Mills.\n[Bug 897] Check RAND_status() - we may not need a .rnd file + +ChangeSet@1.1588, 2007-09-13 07:44:43-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P76 + TAG: NTP_4_2_5P76 + + ntpd/ntpd-opts.c@1.63, 2007-09-13 07:44:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P76 + + ntpd/ntpd-opts.h@1.63, 2007-09-13 07:44:26-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P76 + + ntpd/ntpd-opts.texi@1.62, 2007-09-13 07:44:27-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P76 + + ntpd/ntpd.1@1.62, 2007-09-13 07:44:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P76 + + ntpdc/ntpdc-opts.c@1.63, 2007-09-13 07:44:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P76 + + ntpdc/ntpdc-opts.h@1.63, 2007-09-13 07:44:29-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P76 + + ntpdc/ntpdc-opts.texi@1.62, 2007-09-13 07:44:30-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P76 + + ntpdc/ntpdc.1@1.62, 2007-09-13 07:44:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P76 + + ntpq/ntpq-opts.c@1.63, 2007-09-13 07:44:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P76 + + ntpq/ntpq-opts.h@1.63, 2007-09-13 07:44:32-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P76 + + ntpq/ntpq-opts.texi@1.62, 2007-09-13 07:44:32-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P76 + + ntpq/ntpq.1@1.62, 2007-09-13 07:44:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P76 + + packageinfo.sh@1.79, 2007-09-13 07:44:34-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P76 + + sntp/sntp-opts.c@1.63, 2007-09-13 07:44:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P76 + + sntp/sntp-opts.h@1.63, 2007-09-13 07:44:35-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P76 + + sntp/sntp-opts.texi@1.62, 2007-09-13 07:44:36-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P76 + + sntp/sntp.1@1.62, 2007-09-13 07:44:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P76 + + util/ntp-keygen-opts.c@1.64, 2007-09-13 07:44:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P76 + + util/ntp-keygen-opts.h@1.64, 2007-09-13 07:44:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P76 + + util/ntp-keygen-opts.texi@1.63, 2007-09-13 07:44:39-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P76 + + util/ntp-keygen.1@1.63, 2007-09-13 07:44:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P76 + +ChangeSet@1.1587, 2007-09-12 17:22:55-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 911] Fix error message in cmd_args.c + + ChangeLog@1.110, 2007-09-12 17:22:42-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 911] Fix error message in cmd_args.c + + ntpd/cmd_args.c@1.52, 2007-09-12 17:22:44-04:00, stenn@whimsy.udel.edu +0 -1 + [Bug 911] Fix error message in cmd_args.c + +ChangeSet@1.1586, 2007-09-11 07:47:21-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P75 + TAG: NTP_4_2_5P75 + + ntpd/ntpd-opts.c@1.62, 2007-09-11 07:47:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P75 + + ntpd/ntpd-opts.h@1.62, 2007-09-11 07:47:03-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P75 + + ntpd/ntpd-opts.texi@1.61, 2007-09-11 07:47:04-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P75 + + ntpd/ntpd.1@1.61, 2007-09-11 07:47:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P75 + + ntpdc/ntpdc-opts.c@1.62, 2007-09-11 07:47:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P75 + + ntpdc/ntpdc-opts.h@1.62, 2007-09-11 07:47:06-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P75 + + ntpdc/ntpdc-opts.texi@1.61, 2007-09-11 07:47:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P75 + + ntpdc/ntpdc.1@1.61, 2007-09-11 07:47:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P75 + + ntpq/ntpq-opts.c@1.62, 2007-09-11 07:47:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P75 + + ntpq/ntpq-opts.h@1.62, 2007-09-11 07:47:09-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P75 + + ntpq/ntpq-opts.texi@1.61, 2007-09-11 07:47:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P75 + + ntpq/ntpq.1@1.61, 2007-09-11 07:47:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P75 + + packageinfo.sh@1.78, 2007-09-11 07:47:11-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P75 + + sntp/sntp-opts.c@1.62, 2007-09-11 07:47:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P75 + + sntp/sntp-opts.h@1.62, 2007-09-11 07:47:13-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P75 + + sntp/sntp-opts.texi@1.61, 2007-09-11 07:47:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P75 + + sntp/sntp.1@1.61, 2007-09-11 07:47:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P75 + + util/ntp-keygen-opts.c@1.63, 2007-09-11 07:47:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P75 + + util/ntp-keygen-opts.h@1.63, 2007-09-11 07:47:15-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P75 + + util/ntp-keygen-opts.texi@1.62, 2007-09-11 07:47:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P75 + + util/ntp-keygen.1@1.62, 2007-09-11 07:47:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P75 + +ChangeSet@1.1585, 2007-09-11 04:14:55-04:00, murray@pogo.udel.edu +1 -0 + [Bug 895] Log assertion failures via syslog(), not stderr + + ChangeLog@1.109, 2007-09-11 04:14:02-04:00, murray@pogo.udel.edu +1 -0 + [Bug 895] Log assertion failures via syslog(), not stderr + +ChangeSet@1.1436.1.84, 2007-09-10 20:40:19-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_4P4 + TAG: NTP_4_2_4P4 + + ntpd/ntpd-opts.c@1.50.13.1, 2007-09-10 20:39:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4 + + ntpd/ntpd-opts.h@1.50.13.1, 2007-09-10 20:39:56-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P4 + + ntpd/ntpd-opts.texi@1.49.13.1, 2007-09-10 20:39:57-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P4 + + ntpd/ntpd.1@1.48.13.1, 2007-09-10 20:39:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4 + + ntpd/ntpdsim-opts.c@1.50.13.1, 2007-09-10 20:39:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4 + + ntpd/ntpdsim-opts.h@1.50.13.1, 2007-09-10 20:39:58-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P4 + + ntpd/ntpdsim-opts.texi@1.48.13.1, 2007-09-10 20:40:00-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P4 + + ntpd/ntpdsim.1@1.48.13.1, 2007-09-10 20:40:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4 + + ntpdc/ntpdc-opts.c@1.50.13.1, 2007-09-10 20:40:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4 + + ntpdc/ntpdc-opts.h@1.50.13.1, 2007-09-10 20:40:02-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P4 + + ntpdc/ntpdc-opts.texi@1.48.13.1, 2007-09-10 20:40:03-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P4 + + ntpdc/ntpdc.1@1.48.13.1, 2007-09-10 20:40:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4 + + ntpq/ntpq-opts.c@1.52.13.1, 2007-09-10 20:40:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4 + + ntpq/ntpq-opts.h@1.52.13.1, 2007-09-10 20:40:05-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P4 + + ntpq/ntpq-opts.texi@1.49.13.1, 2007-09-10 20:40:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P4 + + ntpq/ntpq.1@1.48.13.1, 2007-09-10 20:40:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4 + + packageinfo.sh@1.65.19.2, 2007-09-10 20:40:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4 + + sntp/sntp-opts.c@1.49.13.1, 2007-09-10 20:40:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4 + + sntp/sntp-opts.h@1.49.13.1, 2007-09-10 20:40:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P4 + + sntp/sntp-opts.texi@1.46.13.1, 2007-09-10 20:40:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P4 + + sntp/sntp.1@1.49.13.1, 2007-09-10 20:40:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4 + + util/ntp-keygen-opts.c@1.49.13.1, 2007-09-10 20:40:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4 + + util/ntp-keygen-opts.h@1.49.13.1, 2007-09-10 20:40:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P4 + + util/ntp-keygen-opts.texi@1.47.13.1, 2007-09-10 20:40:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P4 + + util/ntp-keygen.1@1.47.13.1, 2007-09-10 20:40:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4 + +ChangeSet@1.1436.1.83, 2007-09-10 16:56:09-04:00, stenn@whimsy.udel.edu +3 -0 + Release 4.2.4p4 + + ChangeLog@1.1.1.34, 2007-09-10 16:55:51-04:00, stenn@whimsy.udel.edu +3 -0 + Release 4.2.4p4 + + NEWS@1.86.1.12, 2007-09-10 16:55:54-04:00, stenn@whimsy.udel.edu +11 -0 + Release 4.2.4p4 + + packageinfo.sh@1.65.19.1, 2007-09-10 16:55:58-04:00, stenn@whimsy.udel.edu +1 -1 + Release 4.2.4p4 + +ChangeSet@1.1582.1.7, 2007-09-10 07:56:32-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P74 + TAG: NTP_4_2_5P74 + + ntpd/ntpd-opts.c@1.61, 2007-09-10 07:56:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P74 + + ntpd/ntpd-opts.h@1.61, 2007-09-10 07:56:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P74 + + ntpd/ntpd-opts.texi@1.60, 2007-09-10 07:56:15-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P74 + + ntpd/ntpd.1@1.60, 2007-09-10 07:56:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P74 + + ntpdc/ntpdc-opts.c@1.61, 2007-09-10 07:56:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P74 + + ntpdc/ntpdc-opts.h@1.61, 2007-09-10 07:56:17-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P74 + + ntpdc/ntpdc-opts.texi@1.60, 2007-09-10 07:56:18-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P74 + + ntpdc/ntpdc.1@1.60, 2007-09-10 07:56:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P74 + + ntpq/ntpq-opts.c@1.61, 2007-09-10 07:56:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P74 + + ntpq/ntpq-opts.h@1.61, 2007-09-10 07:56:20-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P74 + + ntpq/ntpq-opts.texi@1.60, 2007-09-10 07:56:20-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P74 + + ntpq/ntpq.1@1.60, 2007-09-10 07:56:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P74 + + packageinfo.sh@1.77, 2007-09-10 07:56:22-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P74 + + sntp/sntp-opts.c@1.61, 2007-09-10 07:56:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P74 + + sntp/sntp-opts.h@1.61, 2007-09-10 07:56:23-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P74 + + sntp/sntp-opts.texi@1.60, 2007-09-10 07:56:24-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P74 + + sntp/sntp.1@1.60, 2007-09-10 07:56:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P74 + + util/ntp-keygen-opts.c@1.62, 2007-09-10 07:56:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P74 + + util/ntp-keygen-opts.h@1.62, 2007-09-10 07:56:26-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P74 + + util/ntp-keygen-opts.texi@1.61, 2007-09-10 07:56:26-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P74 + + util/ntp-keygen.1@1.61, 2007-09-10 07:56:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P74 + +ChangeSet@1.1582.1.6, 2007-09-10 02:32:58-04:00, stenn@whimsy.udel.edu +3 -0 + Documentation updates from Dave Mills + + ChangeLog@1.107, 2007-09-10 02:32:35-04:00, stenn@whimsy.udel.edu +1 -0 + Documentation updates from Dave Mills + + html/authopt.html@1.42, 2007-09-10 02:32:35-04:00, stenn@whimsy.udel.edu +56 -54 + Documentation updates from Dave Mills + + html/keygen.html@1.9, 2007-09-10 02:32:37-04:00, stenn@whimsy.udel.edu +49 -59 + Documentation updates from Dave Mills + +ChangeSet@1.1436.1.82, 2007-09-10 01:57:20-04:00, stenn@whimsy.udel.edu +3 -0 + [Bug 902] Fix problems with the -6 flag + + ChangeLog@1.1.1.33, 2007-09-10 01:57:02-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 902] Fix problems with the -6 flag + + libopts/save.c@1.2, 2007-09-10 01:57:02-04:00, stenn@whimsy.udel.edu +11 -2 + [Bug 902] Fix problems with the -6 flag + + sntp/libopts/save.c@1.2, 2007-09-10 01:57:03-04:00, stenn@whimsy.udel.edu +11 -2 + [Bug 902] Fix problems with the -6 flag + +ChangeSet@1.1582.1.4, 2007-09-09 07:10:45-04:00, stenn@whimsy.udel.edu +8 -0 + crypto fixes from Dave Mills + + ChangeLog@1.105, 2007-09-09 07:09:52-04:00, stenn@whimsy.udel.edu +2 -0 + crypto fixes from Dave Mills + + include/ntp.h@1.137, 2007-09-09 07:07:54-04:00, stenn@whimsy.udel.edu +3 -3 + crypto fixes from Dave Mills + + include/ntp_control.h@1.32, 2007-09-09 07:08:01-04:00, stenn@whimsy.udel.edu +4 -6 + crypto fixes from Dave Mills + + include/ntpd.h@1.110, 2007-09-09 07:08:34-04:00, stenn@whimsy.udel.edu +1 -0 + crypto fixes from Dave Mills + + ntpd/ntp_control.c@1.100, 2007-09-09 07:09:23-04:00, stenn@whimsy.udel.edu +12 -21 + crypto fixes from Dave Mills + + ntpd/ntp_crypto.c@1.115, 2007-09-09 07:09:25-04:00, stenn@whimsy.udel.edu +472 -540 + crypto fixes from Dave Mills + + ntpd/ntp_peer.c@1.107, 2007-09-09 07:09:28-04:00, stenn@whimsy.udel.edu +3 -0 + crypto fixes from Dave Mills + + ntpd/ntp_proto.c@1.262, 2007-09-09 07:09:29-04:00, stenn@whimsy.udel.edu +3 -6 + crypto fixes from Dave Mills + +ChangeSet@1.1582.1.3, 2007-09-09 06:48:21-04:00, stenn@whimsy.udel.edu +2 -0 + Avoid double peer stats logging + + ChangeLog@1.104, 2007-09-09 06:48:08-04:00, stenn@whimsy.udel.edu +1 -0 + Avoid double peer stats logging + + ntpd/ntp_refclock.c@1.78, 2007-09-09 06:48:08-04:00, stenn@whimsy.udel.edu +0 -3 + Avoid double peer stats logging + +ChangeSet@1.1582.1.2, 2007-09-09 05:30:21-04:00, stenn@whimsy.udel.edu +2 -0 + ntp-keygen cleanup from Dave Mills + + ChangeLog@1.103, 2007-09-09 05:29:19-04:00, stenn@whimsy.udel.edu +1 -0 + ntp-keygen cleanup from Dave Mills + + util/ntp-keygen.c@1.44, 2007-09-09 05:29:37-04:00, stenn@whimsy.udel.edu +187 -146 + ntp-keygen cleanup from Dave Mills + +ChangeSet@1.1582.1.1, 2007-09-09 05:19:17-04:00, stenn@whimsy.udel.edu +2 -0 + libopts needs to be built after ElectricFence + + ChangeLog@1.102, 2007-09-09 05:19:02-04:00, stenn@whimsy.udel.edu +1 -0 + libopts needs to be built after ElectricFence + + Makefile.am@1.76, 2007-09-09 05:19:03-04:00, stenn@whimsy.udel.edu +4 -3 + libopts needs to be built after ElectricFence + +ChangeSet@1.1583, 2007-09-06 16:56:06-04:00, murray@pogo.udel.edu +1 -0 + Fix for bug 895 + + ntpd/ntpd.c@1.89, 2007-09-06 16:56:03-04:00, murray@pogo.udel.edu +91 -0 + Fix for bug 895 + +ChangeSet@1.1582, 2007-08-29 07:48:23-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P73 + TAG: NTP_4_2_5P73 + + ntpd/ntpd-opts.c@1.60, 2007-08-29 07:48:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P73 + + ntpd/ntpd-opts.h@1.60, 2007-08-29 07:48:01-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P73 + + ntpd/ntpd-opts.texi@1.59, 2007-08-29 07:48:02-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P73 + + ntpd/ntpd.1@1.59, 2007-08-29 07:48:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P73 + + ntpdc/ntpdc-opts.c@1.60, 2007-08-29 07:48:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P73 + + ntpdc/ntpdc-opts.h@1.60, 2007-08-29 07:48:04-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P73 + + ntpdc/ntpdc-opts.texi@1.59, 2007-08-29 07:48:05-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P73 + + ntpdc/ntpdc.1@1.59, 2007-08-29 07:48:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P73 + + ntpq/ntpq-opts.c@1.60, 2007-08-29 07:48:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P73 + + ntpq/ntpq-opts.h@1.60, 2007-08-29 07:48:07-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P73 + + ntpq/ntpq-opts.texi@1.59, 2007-08-29 07:48:08-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P73 + + ntpq/ntpq.1@1.59, 2007-08-29 07:48:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P73 + + packageinfo.sh@1.76, 2007-08-29 07:48:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P73 + + sntp/sntp-opts.c@1.60, 2007-08-29 07:48:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P73 + + sntp/sntp-opts.h@1.60, 2007-08-29 07:48:11-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P73 + + sntp/sntp-opts.texi@1.59, 2007-08-29 07:48:12-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P73 + + sntp/sntp.1@1.59, 2007-08-29 07:48:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P73 + + util/ntp-keygen-opts.c@1.61, 2007-08-29 07:48:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P73 + + util/ntp-keygen-opts.h@1.61, 2007-08-29 07:48:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P73 + + util/ntp-keygen-opts.texi@1.60, 2007-08-29 07:48:15-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P73 + + util/ntp-keygen.1@1.60, 2007-08-29 07:48:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P73 + +ChangeSet@1.1436.1.81, 2007-08-28 15:34:55-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_4P4_RC2 + TAG: NTP_4_2_4P4_RC2 + + ntpd/ntpd-opts.c@1.50.12.1, 2007-08-28 15:34:28-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P4_RC2 + + ntpd/ntpd-opts.h@1.50.12.1, 2007-08-28 15:34:29-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P4_RC2 + + ntpd/ntpd-opts.texi@1.49.12.1, 2007-08-28 15:34:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC2 + + ntpd/ntpd.1@1.48.12.1, 2007-08-28 15:34:32-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P4_RC2 + + ntpd/ntpdsim-opts.c@1.50.12.1, 2007-08-28 15:34:32-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P4_RC2 + + ntpd/ntpdsim-opts.h@1.50.12.1, 2007-08-28 15:34:33-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P4_RC2 + + ntpd/ntpdsim-opts.texi@1.48.12.1, 2007-08-28 15:34:34-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P4_RC2 + + ntpd/ntpdsim.1@1.48.12.1, 2007-08-28 15:34:34-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P4_RC2 + + ntpdc/ntpdc-opts.c@1.50.12.1, 2007-08-28 15:34:35-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P4_RC2 + + ntpdc/ntpdc-opts.h@1.50.12.1, 2007-08-28 15:34:36-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P4_RC2 + + ntpdc/ntpdc-opts.texi@1.48.12.1, 2007-08-28 15:34:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC2 + + ntpdc/ntpdc.1@1.48.12.1, 2007-08-28 15:34:38-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P4_RC2 + + ntpq/ntpq-opts.c@1.52.12.1, 2007-08-28 15:34:38-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P4_RC2 + + ntpq/ntpq-opts.h@1.52.12.1, 2007-08-28 15:34:39-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P4_RC2 + + ntpq/ntpq-opts.texi@1.49.12.1, 2007-08-28 15:34:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC2 + + ntpq/ntpq.1@1.48.12.1, 2007-08-28 15:34:41-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P4_RC2 + + packageinfo.sh@1.65.18.1, 2007-08-28 15:34:41-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P4_RC2 + + sntp/sntp-opts.c@1.49.12.1, 2007-08-28 15:34:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC2 + + sntp/sntp-opts.h@1.49.12.1, 2007-08-28 15:34:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P4_RC2 + + sntp/sntp-opts.texi@1.46.12.1, 2007-08-28 15:34:44-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P4_RC2 + + sntp/sntp.1@1.49.12.1, 2007-08-28 15:34:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC2 + + util/ntp-keygen-opts.c@1.49.12.1, 2007-08-28 15:34:45-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P4_RC2 + + util/ntp-keygen-opts.h@1.49.12.1, 2007-08-28 15:34:46-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P4_RC2 + + util/ntp-keygen-opts.texi@1.47.12.1, 2007-08-28 15:34:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC2 + + util/ntp-keygen.1@1.47.12.1, 2007-08-28 15:34:48-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P4_RC2 + +ChangeSet@1.1580, 2007-08-28 07:52:12-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P72 + TAG: NTP_4_2_5P72 + + ntpd/ntpd-opts.c@1.59, 2007-08-28 07:51:51-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P72 + + ntpd/ntpd-opts.h@1.59, 2007-08-28 07:51:52-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P72 + + ntpd/ntpd-opts.texi@1.58, 2007-08-28 07:51:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P72 + + ntpd/ntpd.1@1.58, 2007-08-28 07:51:53-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P72 + + ntpdc/ntpdc-opts.c@1.59, 2007-08-28 07:51:54-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P72 + + ntpdc/ntpdc-opts.h@1.59, 2007-08-28 07:51:54-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P72 + + ntpdc/ntpdc-opts.texi@1.58, 2007-08-28 07:51:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P72 + + ntpdc/ntpdc.1@1.58, 2007-08-28 07:51:55-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P72 + + ntpq/ntpq-opts.c@1.59, 2007-08-28 07:51:56-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P72 + + ntpq/ntpq-opts.h@1.59, 2007-08-28 07:51:56-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P72 + + ntpq/ntpq-opts.texi@1.58, 2007-08-28 07:51:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P72 + + ntpq/ntpq.1@1.58, 2007-08-28 07:51:57-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P72 + + packageinfo.sh@1.75, 2007-08-28 07:51:59-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P72 + + sntp/sntp-opts.c@1.59, 2007-08-28 07:51:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P72 + + sntp/sntp-opts.h@1.59, 2007-08-28 07:52:00-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P72 + + sntp/sntp-opts.texi@1.58, 2007-08-28 07:52:01-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P72 + + sntp/sntp.1@1.58, 2007-08-28 07:52:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P72 + + util/ntp-keygen-opts.c@1.60, 2007-08-28 07:52:03-04:00, stenn@whimsy.udel.edu +6 -5 + NTP_4_2_5P72 + + util/ntp-keygen-opts.h@1.60, 2007-08-28 07:52:03-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P72 + + util/ntp-keygen-opts.texi@1.59, 2007-08-28 07:52:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P72 + + util/ntp-keygen.1@1.59, 2007-08-28 07:52:05-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P72 + +ChangeSet@1.1579, 2007-08-28 00:00:03-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 894] Initialize keysdir before calling crypto_setup() + + ChangeLog@1.101, 2007-08-27 23:59:12-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 894] Initialize keysdir before calling crypto_setup() + +ChangeSet@1.1576.1.2, 2007-08-27 23:42:20-04:00, stenn@whimsy.udel.edu +12 -0 + ntp-keygen-opts.def: + ntp-keygen -i takes an arg + ntpq.c: + Calysto cleanup for ntpq. + Many files: + Cleanup from Dave Mills + ChangeLog: + Cleanup from Dave Mills. + Coverity fix for ntpq. + ntp-keygen -i takes an arg. + + ChangeLog@1.100, 2007-08-27 23:41:04-04:00, stenn@whimsy.udel.edu +3 -0 + Cleanup from Dave Mills. + Coverity fix for ntpq. + ntp-keygen -i takes an arg. + + include/ntp.h@1.136, 2007-08-27 23:32:57-04:00, stenn@whimsy.udel.edu +3 -5 + Cleanup from Dave Mills + + include/ntp_crypto.h@1.42, 2007-08-27 23:33:00-04:00, stenn@whimsy.udel.edu +20 -14 + Cleanup from Dave Mills + + include/ntpd.h@1.109, 2007-08-27 23:33:05-04:00, stenn@whimsy.udel.edu +2 -1 + Cleanup from Dave Mills + + ntpd/ntp_control.c@1.99, 2007-08-27 23:39:51-04:00, stenn@whimsy.udel.edu +23 -28 + Cleanup from Dave Mills + + ntpd/ntp_crypto.c@1.114, 2007-08-27 23:39:53-04:00, stenn@whimsy.udel.edu +337 -345 + Cleanup from Dave Mills + + ntpd/ntp_parser.c@1.20, 2007-08-27 23:39:56-04:00, stenn@whimsy.udel.edu +578 -586 + Cleanup from Dave Mills + + ntpd/ntp_parser.y@1.16, 2007-08-27 23:40:00-04:00, stenn@whimsy.udel.edu +0 -2 + Cleanup from Dave Mills + + ntpd/ntp_proto.c@1.261, 2007-08-27 23:40:01-04:00, stenn@whimsy.udel.edu +30 -43 + Cleanup from Dave Mills + + ntpq/ntpq.c@1.70, 2007-08-27 23:38:05-04:00, stenn@whimsy.udel.edu +2 -0 + Calysto cleanup for ntpq. + + util/ntp-keygen-opts.def@1.9, 2007-08-27 23:35:35-04:00, stenn@whimsy.udel.edu +2 -0 + ntp-keygen -i takes an arg + + util/ntp-keygen.c@1.43, 2007-08-27 23:36:45-04:00, stenn@whimsy.udel.edu +188 -200 + Cleanup from Dave Mills + +ChangeSet@1.1436.1.80, 2007-08-27 22:38:57-04:00, stenn@whimsy.udel.edu +2 -0 + Updated include/copyright.def (owner and year) + + ChangeLog@1.1.1.32, 2007-08-27 22:38:46-04:00, stenn@whimsy.udel.edu +1 -0 + Updated include/copyright.def (owner and year) + + include/copyright.def@1.5, 2007-08-27 22:38:47-04:00, stenn@whimsy.udel.edu +2 -2 + Updated include/copyright.def (owner and year) + +ChangeSet@1.1577, 2007-08-25 13:22:24+00:00, kardel@pogo.udel.edu +1 -0 + ntp_config.c: + Bug 894: initialize keysdir BEFORE crypto_setup() is called - so it has a fair + chance to find the keys. + + ntpd/ntp_config.c@1.164, 2007-08-25 13:21:03+00:00, kardel@pogo.udel.edu +5 -4 + Bug 894: initialize keysdir BEFORE crypto_setup() is called - so it has a fair + chance to find the keys. + +ChangeSet@1.1576, 2007-08-19 07:45:24-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P71 + TAG: NTP_4_2_5P71 + + ntpd/ntpd-opts.c@1.58, 2007-08-19 07:45:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P71 + + ntpd/ntpd-opts.h@1.58, 2007-08-19 07:45:06-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P71 + + ntpd/ntpd-opts.texi@1.57, 2007-08-19 07:45:07-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P71 + + ntpd/ntpd.1@1.57, 2007-08-19 07:45:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P71 + + ntpdc/ntpdc-opts.c@1.58, 2007-08-19 07:45:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P71 + + ntpdc/ntpdc-opts.h@1.58, 2007-08-19 07:45:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P71 + + ntpdc/ntpdc-opts.texi@1.57, 2007-08-19 07:45:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P71 + + ntpdc/ntpdc.1@1.57, 2007-08-19 07:45:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P71 + + ntpq/ntpq-opts.c@1.58, 2007-08-19 07:45:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P71 + + ntpq/ntpq-opts.h@1.58, 2007-08-19 07:45:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P71 + + ntpq/ntpq-opts.texi@1.57, 2007-08-19 07:45:12-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P71 + + ntpq/ntpq.1@1.57, 2007-08-19 07:45:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P71 + + packageinfo.sh@1.74, 2007-08-19 07:45:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P71 + + sntp/sntp-opts.c@1.58, 2007-08-19 07:45:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P71 + + sntp/sntp-opts.h@1.58, 2007-08-19 07:45:15-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P71 + + sntp/sntp-opts.texi@1.57, 2007-08-19 07:45:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P71 + + sntp/sntp.1@1.57, 2007-08-19 07:45:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P71 + + util/ntp-keygen-opts.c@1.59, 2007-08-19 07:45:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P71 + + util/ntp-keygen-opts.h@1.59, 2007-08-19 07:45:18-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P71 + + util/ntp-keygen-opts.texi@1.58, 2007-08-19 07:45:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P71 + + util/ntp-keygen.1@1.58, 2007-08-19 07:45:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P71 + +ChangeSet@1.1436.1.79, 2007-08-19 05:26:13-04:00, dunlop@pogo.udel.edu +2 -0 + ntpdc_ops.c, ChangeLog: + [BUG 881] Corrected display of pll offset on 64bit systems. + [BUG 886] Corrected sign extension of il->compliance on 64 bit systems + [BUG 878] Avoid ntpdc use of refid value as unterminated string. + + ChangeLog@1.1.1.31, 2007-08-19 05:20:42-04:00, dunlop@pogo.udel.edu +1 -0 + [Bug 878] Avoid ntpdc use of refid value as unterminated string. + + ChangeLog@1.1.1.30, 2007-08-19 05:13:18-04:00, dunlop@pogo.udel.edu +1 -0 + [Bug 881] Corrected display of pll offset on 64bit systems. + + ChangeLog@1.1.1.29, 2007-08-19 05:01:14-04:00, dunlop@pogo.udel.edu +1 -0 + [BUG 886] Corrected sign extension of il->compliance on 64 bit systems + + ntpdc/ntpdc_ops.c@1.46.1.3, 2007-08-19 05:20:34-04:00, dunlop@pogo.udel.edu +1 -3 + [Bug 878] Avoid ntpdc use of refid value as unterminated string. + + ntpdc/ntpdc_ops.c@1.46.1.2, 2007-08-19 05:12:52-04:00, dunlop@pogo.udel.edu +1 -1 + [Bug 881] Corrected display of pll offset on 64bit systems. + + ntpdc/ntpdc_ops.c@1.46.1.1, 2007-08-19 04:59:48-04:00, dunlop@pogo.udel.edu +2 -2 + [BUG 886] Corrected sign extension of il->compliance on 64 bit systems + +ChangeSet@1.1575, 2007-08-19 08:35:04+00:00, stenn@ntp1.isc.org +3 -0 + [Bug 887] Fix error in ntp_types.h (for sizeof int != 4) + + ChangeLog@1.98, 2007-08-19 08:34:46+00:00, stenn@ntp1.isc.org +1 -0 + [Bug 887] Fix error in ntp_types.h (for sizeof int != 4) + + dot.emacs@1.8, 2007-08-19 08:34:31+00:00, stenn@ntp1.isc.org +4 -3 + updates + + include/ntp_types.h@1.10, 2007-08-19 08:34:47+00:00, stenn@ntp1.isc.org +2 -2 + [Bug 887] Fix error in ntp_types.h (for sizeof int != 4) + +ChangeSet@1.1574, 2007-08-18 19:14:33-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P70 + TAG: NTP_4_2_5P70 + + ntpd/ntpd-opts.c@1.57, 2007-08-18 19:14:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P70 + + ntpd/ntpd-opts.h@1.57, 2007-08-18 19:14:15-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P70 + + ntpd/ntpd-opts.texi@1.56, 2007-08-18 19:14:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P70 + + ntpd/ntpd.1@1.56, 2007-08-18 19:14:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P70 + + ntpdc/ntpdc-opts.c@1.57, 2007-08-18 19:14:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P70 + + ntpdc/ntpdc-opts.h@1.57, 2007-08-18 19:14:18-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P70 + + ntpdc/ntpdc-opts.texi@1.56, 2007-08-18 19:14:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P70 + + ntpdc/ntpdc.1@1.56, 2007-08-18 19:14:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P70 + + ntpq/ntpq-opts.c@1.57, 2007-08-18 19:14:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P70 + + ntpq/ntpq-opts.h@1.57, 2007-08-18 19:14:21-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P70 + + ntpq/ntpq-opts.texi@1.56, 2007-08-18 19:14:22-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P70 + + ntpq/ntpq.1@1.56, 2007-08-18 19:14:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P70 + + packageinfo.sh@1.73, 2007-08-18 19:14:23-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P70 + + sntp/sntp-opts.c@1.57, 2007-08-18 19:14:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P70 + + sntp/sntp-opts.h@1.57, 2007-08-18 19:14:25-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P70 + + sntp/sntp-opts.texi@1.56, 2007-08-18 19:14:25-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P70 + + sntp/sntp.1@1.56, 2007-08-18 19:14:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P70 + + util/ntp-keygen-opts.c@1.58, 2007-08-18 19:14:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P70 + + util/ntp-keygen-opts.h@1.58, 2007-08-18 19:14:28-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P70 + + util/ntp-keygen-opts.texi@1.57, 2007-08-18 19:14:28-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P70 + + util/ntp-keygen.1@1.57, 2007-08-18 19:14:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P70 + +ChangeSet@1.1436.1.78, 2007-08-18 17:11:19-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_4P4_RC1 + TAG: NTP_4_2_4P4_RC1 + + ntpd/ntpd-opts.c@1.50.11.1, 2007-08-18 17:10:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC1 + + ntpd/ntpd-opts.h@1.50.11.1, 2007-08-18 17:10:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P4_RC1 + + ntpd/ntpd-opts.texi@1.49.11.1, 2007-08-18 17:10:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC1 + + ntpd/ntpd.1@1.48.11.1, 2007-08-18 17:10:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC1 + + ntpd/ntpdsim-opts.c@1.50.11.1, 2007-08-18 17:10:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC1 + + ntpd/ntpdsim-opts.h@1.50.11.1, 2007-08-18 17:10:54-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P4_RC1 + + ntpd/ntpdsim-opts.texi@1.48.11.1, 2007-08-18 17:10:56-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P4_RC1 + + ntpd/ntpdsim.1@1.48.11.1, 2007-08-18 17:10:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC1 + + ntpdc/ntpdc-opts.c@1.50.11.1, 2007-08-18 17:10:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC1 + + ntpdc/ntpdc-opts.h@1.50.11.1, 2007-08-18 17:10:57-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P4_RC1 + + ntpdc/ntpdc-opts.texi@1.48.11.1, 2007-08-18 17:10:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC1 + + ntpdc/ntpdc.1@1.48.11.1, 2007-08-18 17:10:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC1 + + ntpq/ntpq-opts.c@1.52.11.1, 2007-08-18 17:10:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC1 + + ntpq/ntpq-opts.h@1.52.11.1, 2007-08-18 17:11:01-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P4_RC1 + + ntpq/ntpq-opts.texi@1.49.11.1, 2007-08-18 17:11:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC1 + + ntpq/ntpq.1@1.48.11.1, 2007-08-18 17:11:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC1 + + packageinfo.sh@1.65.17.2, 2007-08-18 17:11:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC1 + + sntp/sntp-opts.c@1.49.11.1, 2007-08-18 17:11:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC1 + + sntp/sntp-opts.h@1.49.11.1, 2007-08-18 17:11:05-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P4_RC1 + + sntp/sntp-opts.texi@1.46.11.1, 2007-08-18 17:11:07-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P4_RC1 + + sntp/sntp.1@1.49.11.1, 2007-08-18 17:11:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC1 + + util/ntp-keygen-opts.c@1.49.11.1, 2007-08-18 17:11:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC1 + + util/ntp-keygen-opts.h@1.49.11.1, 2007-08-18 17:11:10-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P4_RC1 + + util/ntp-keygen-opts.texi@1.47.11.1, 2007-08-18 17:11:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC1 + + util/ntp-keygen.1@1.47.11.1, 2007-08-18 17:11:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P4_RC1 + +ChangeSet@1.1436.1.77, 2007-08-18 16:16:22-04:00, stenn@whimsy.udel.edu +1 -0 + 4.2.4p4-RC + + packageinfo.sh@1.65.17.1, 2007-08-18 16:16:06-04:00, stenn@whimsy.udel.edu +1 -1 + 4.2.4p4-RC + +ChangeSet@1.1436.1.76, 2007-08-18 12:59:45+00:00, kardel@pogo.udel.edu +2 -0 + ntp_restrict.c: + Bug 885: clarify to allow tools to pick up + invariants easier. + Use NULL instead of 0 with pointers. + ChangeLog: + document ntp_restrict.c change + + ChangeLog@1.1.1.28, 2007-08-18 12:59:05+00:00, kardel@pogo.udel.edu +1 -0 + document ntp_restrict.c change + + ntpd/ntp_restrict.c@1.22.1.1, 2007-08-18 12:56:40+00:00, kardel@pogo.udel.edu +21 -21 + Bug 885: clarify to allow tools to pick up + invariants easier. + Use NULL instead of 0 with pointers. + +ChangeSet@1.1436.1.75, 2007-08-18 12:53:35+00:00, kardel@pogo.udel.edu +2 -0 + recvbuff.c: + Bug 889: avoid malloc() interrupted by SIGIO risk + ChangeLog: + document Bug 889 + + ChangeLog@1.1.1.27, 2007-08-18 12:52:19+00:00, kardel@pogo.udel.edu +1 -0 + document Bug 889 + + libntp/recvbuff.c@1.26, 2007-08-18 12:49:27+00:00, kardel@pogo.udel.edu +28 -21 + Bug 889: avoid malloc() interrupted by SIGIO risk + +ChangeSet@1.1572, 2007-08-18 07:46:58-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P69 + TAG: NTP_4_2_5P69 + + ntpd/ntpd-opts.c@1.56, 2007-08-18 07:46:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P69 + + ntpd/ntpd-opts.h@1.56, 2007-08-18 07:46:38-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P69 + + ntpd/ntpd-opts.texi@1.55, 2007-08-18 07:46:39-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P69 + + ntpd/ntpd.1@1.55, 2007-08-18 07:46:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P69 + + ntpdc/ntpdc-opts.c@1.56, 2007-08-18 07:46:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P69 + + ntpdc/ntpdc-opts.h@1.56, 2007-08-18 07:46:41-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P69 + + ntpdc/ntpdc-opts.texi@1.55, 2007-08-18 07:46:41-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P69 + + ntpdc/ntpdc.1@1.55, 2007-08-18 07:46:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P69 + + ntpq/ntpq-opts.c@1.56, 2007-08-18 07:46:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P69 + + ntpq/ntpq-opts.h@1.56, 2007-08-18 07:46:45-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P69 + + ntpq/ntpq-opts.texi@1.55, 2007-08-18 07:46:45-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P69 + + ntpq/ntpq.1@1.55, 2007-08-18 07:46:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P69 + + packageinfo.sh@1.72, 2007-08-18 07:46:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P69 + + sntp/sntp-opts.c@1.56, 2007-08-18 07:46:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P69 + + sntp/sntp-opts.h@1.56, 2007-08-18 07:46:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P69 + + sntp/sntp-opts.texi@1.55, 2007-08-18 07:46:49-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P69 + + sntp/sntp.1@1.55, 2007-08-18 07:46:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P69 + + util/ntp-keygen-opts.c@1.57, 2007-08-18 07:46:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P69 + + util/ntp-keygen-opts.h@1.57, 2007-08-18 07:46:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P69 + + util/ntp-keygen-opts.texi@1.56, 2007-08-18 07:46:53-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P69 + + util/ntp-keygen.1@1.56, 2007-08-18 07:46:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P69 + +ChangeSet@1.1436.1.74, 2007-08-18 09:51:41+00:00, kardel@pogo.udel.edu +1 -0 + cmd_args.c: + Bug 885: fix comparison + + ntpd/cmd_args.c@1.45.3.2, 2007-08-18 09:50:28+00:00, kardel@pogo.udel.edu +1 -1 + Bug 885: fix comparison + +ChangeSet@1.1570, 2007-08-18 04:07:51-04:00, stenn@pogo.udel.edu +1 -0 + merge cleanup + + ChangeLog@1.95.1.2, 2007-08-18 04:07:41-04:00, stenn@pogo.udel.edu +13 -0 + merge cleanup + +ChangeSet@1.1564.2.2, 2007-08-17 07:46:18-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P68 + TAG: NTP_4_2_5P68 + + ntpd/ntpd-opts.c@1.55, 2007-08-17 07:45:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P68 + + ntpd/ntpd-opts.h@1.55, 2007-08-17 07:45:59-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P68 + + ntpd/ntpd-opts.texi@1.54, 2007-08-17 07:46:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P68 + + ntpd/ntpd.1@1.54, 2007-08-17 07:46:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P68 + + ntpdc/ntpdc-opts.c@1.55, 2007-08-17 07:46:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P68 + + ntpdc/ntpdc-opts.h@1.55, 2007-08-17 07:46:02-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P68 + + ntpdc/ntpdc-opts.texi@1.54, 2007-08-17 07:46:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P68 + + ntpdc/ntpdc.1@1.54, 2007-08-17 07:46:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P68 + + ntpq/ntpq-opts.c@1.55, 2007-08-17 07:46:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P68 + + ntpq/ntpq-opts.h@1.55, 2007-08-17 07:46:04-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P68 + + ntpq/ntpq-opts.texi@1.54, 2007-08-17 07:46:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P68 + + ntpq/ntpq.1@1.54, 2007-08-17 07:46:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P68 + + packageinfo.sh@1.71, 2007-08-17 07:46:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P68 + + sntp/sntp-opts.c@1.55, 2007-08-17 07:46:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P68 + + sntp/sntp-opts.h@1.55, 2007-08-17 07:46:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P68 + + sntp/sntp-opts.texi@1.54, 2007-08-17 07:46:08-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P68 + + sntp/sntp.1@1.54, 2007-08-17 07:46:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P68 + + util/ntp-keygen-opts.c@1.56, 2007-08-17 07:46:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P68 + + util/ntp-keygen-opts.h@1.56, 2007-08-17 07:46:10-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P68 + + util/ntp-keygen-opts.texi@1.55, 2007-08-17 07:46:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P68 + + util/ntp-keygen.1@1.55, 2007-08-17 07:46:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P68 + +ChangeSet@1.1436.6.1, 2007-08-17 05:28:07-04:00, stenn@pogo.udel.edu +1 -0 + Use autoconf-2.59 and automake-1.9 for building 4.2.4 + + bootstrap@1.18.1.1, 2007-08-17 05:27:51-04:00, stenn@pogo.udel.edu +18 -2 + Use autoconf-2.59 and automake-1.9 for building 4.2.4 + +ChangeSet@1.1564.2.1, 2007-08-17 01:38:48-04:00, stenn@whimsy.udel.edu +28 -0 + Cleanup from Dave Mills + + html/assoc.html@1.22, 2007-08-17 01:35:18-04:00, stenn@whimsy.udel.edu +22 -13 + Cleanup from Dave Mills + + html/index.html@1.34, 2007-08-17 01:35:20-04:00, stenn@whimsy.udel.edu +6 -6 + Cleanup from Dave Mills + + html/release.html@1.32, 2007-08-17 01:35:24-04:00, stenn@whimsy.udel.edu +7 -9 + Cleanup from Dave Mills + + include/ntp.h@1.135, 2007-08-17 01:35:37-04:00, stenn@whimsy.udel.edu +11 -10 + Cleanup from Dave Mills + + include/ntp_crypto.h@1.41, 2007-08-17 01:35:38-04:00, stenn@whimsy.udel.edu +21 -17 + Cleanup from Dave Mills + + include/ntp_refclock.h@1.22, 2007-08-17 01:35:41-04:00, stenn@whimsy.udel.edu +1 -1 + Cleanup from Dave Mills + + include/ntp_request.h@1.33, 2007-08-17 01:35:41-04:00, stenn@whimsy.udel.edu +2 -2 + Cleanup from Dave Mills + + include/ntpd.h@1.108, 2007-08-17 01:35:44-04:00, stenn@whimsy.udel.edu +12 -12 + Cleanup from Dave Mills + + libntp/statestr.c@1.12, 2007-08-17 01:36:00-04:00, stenn@whimsy.udel.edu +1 -1 + Cleanup from Dave Mills + + ntpd/ntp_config.c@1.161.1.1, 2007-08-17 01:36:57-04:00, stenn@whimsy.udel.edu +6 -9 + Cleanup from Dave Mills + + ntpd/ntp_control.c@1.98, 2007-08-17 01:36:58-04:00, stenn@whimsy.udel.edu +8 -5 + Cleanup from Dave Mills + + ntpd/ntp_crypto.c@1.113, 2007-08-17 01:37:00-04:00, stenn@whimsy.udel.edu +175 -101 + Cleanup from Dave Mills + + ntpd/ntp_loopfilter.c@1.139, 2007-08-17 01:37:02-04:00, stenn@whimsy.udel.edu +85 -77 + Cleanup from Dave Mills + + ntpd/ntp_parser.c@1.19, 2007-08-17 01:37:04-04:00, stenn@whimsy.udel.edu +239 -261 + Cleanup from Dave Mills + + ntpd/ntp_parser.y@1.15, 2007-08-17 01:37:07-04:00, stenn@whimsy.udel.edu +1 -23 + Cleanup from Dave Mills + + ntpd/ntp_peer.c@1.106, 2007-08-17 01:37:08-04:00, stenn@whimsy.udel.edu +4 -14 + Cleanup from Dave Mills + + ntpd/ntp_proto.c@1.260, 2007-08-17 01:37:09-04:00, stenn@whimsy.udel.edu +390 -490 + Cleanup from Dave Mills + + ntpd/ntp_refclock.c@1.77, 2007-08-17 01:37:11-04:00, stenn@whimsy.udel.edu +4 -6 + Cleanup from Dave Mills + + ntpd/ntp_request.c@1.69, 2007-08-17 01:37:12-04:00, stenn@whimsy.udel.edu +4 -4 + Cleanup from Dave Mills + + ntpd/ntp_restrict.c@1.23, 2007-08-17 01:37:13-04:00, stenn@whimsy.udel.edu +2 -2 + Cleanup from Dave Mills + + ntpd/ntp_timer.c@1.40, 2007-08-17 01:37:15-04:00, stenn@whimsy.udel.edu +7 -20 + Cleanup from Dave Mills + + ntpd/ntp_util.c@1.59, 2007-08-17 01:37:15-04:00, stenn@whimsy.udel.edu +1 -3 + Cleanup from Dave Mills + + ntpd/ntpd.c@1.88, 2007-08-17 01:37:17-04:00, stenn@whimsy.udel.edu +6 -21 + Cleanup from Dave Mills + + ntpd/ntpsim.c@1.18, 2007-08-17 01:37:19-04:00, stenn@whimsy.udel.edu +1 -1 + Cleanup from Dave Mills + + ntpd/refclock_acts.c@1.31, 2007-08-17 01:37:20-04:00, stenn@whimsy.udel.edu +1 -3 + Cleanup from Dave Mills + + ntpdate/ntpdate.c@1.63, 2007-08-17 01:38:06-04:00, stenn@whimsy.udel.edu +2 -2 + Cleanup from Dave Mills + + ntpdate/ntpdate.h@1.9, 2007-08-17 01:38:07-04:00, stenn@whimsy.udel.edu +1 -1 + Cleanup from Dave Mills + + ntpq/ntpq.c@1.69, 2007-08-17 01:38:18-04:00, stenn@whimsy.udel.edu +4 -4 + Cleanup from Dave Mills + +ChangeSet@1.1564.1.4, 2007-08-14 23:01:09-04:00, mayer@pogo.udel.edu +1 -0 + Bug 880 fixes + + ChangeLog@1.96, 2007-08-14 23:00:53-04:00, mayer@pogo.udel.edu +1 -0 + Bug 880 fixes + +ChangeSet@1.1564.1.3, 2007-08-14 22:55:12-04:00, mayer@pogo.udel.edu +2 -0 + Bug 880 bug fixes for Windows build + + ntpd/ntp_data_structures.c@1.6, 2007-08-14 22:54:11-04:00, mayer@pogo.udel.edu +1 -0 + Bug 880 Include missing. Needed for emalloc prototype + + ports/winnt/ntpd/nt_clockstuff.c@1.24, 2007-08-14 22:53:26-04:00, mayer@pogo.udel.edu +1 -1 + Bug 880 Use leap_sec instead of leap_next + +ChangeSet@1.1436.1.72, 2007-08-11 17:32:22+00:00, kardel@pogo.udel.edu +1 -0 + ChangeLog: + document refclock_parse.c fix + + ChangeLog@1.1.1.26, 2007-08-11 17:31:30+00:00, kardel@pogo.udel.edu +1 -0 + document refclock_parse.c fix + +ChangeSet@1.1436.1.71, 2007-08-11 17:30:42+00:00, kardel@pogo.udel.edu +4 -0 + ChangeLog: + document Bug 885 + ntp_io.c: + Bug 885: use emalloc() to get a message at the end of the memory + cmd_args.c: + Bug 885: unsigned types cannot be less than 0 + default_ai_family is a short + ntp_config.c: + Bug 885: lose trailing , from enum list + + ChangeLog@1.1.1.25, 2007-08-11 17:30:24+00:00, kardel@pogo.udel.edu +4 -0 + document Bug 885 + + ntpd/cmd_args.c@1.45.3.1, 2007-08-11 17:19:51+00:00, kardel@pogo.udel.edu +2 -2 + Bug 885: unsigned types cannot be less than 0 + default_ai_family is a short + + ntpd/ntp_config.c@1.141.1.1, 2007-08-11 17:20:52+00:00, kardel@pogo.udel.edu +1 -1 + Bug 885: lose trailing , from enum list + + ntpd/ntp_io.c@1.244.2.9, 2007-08-11 17:21:17+00:00, kardel@pogo.udel.edu +1 -1 + Bug 885: use emalloc() to get a message at the end of the memory + +ChangeSet@1.1436.1.70, 2007-08-11 17:19:45+00:00, kardel@pogo.udel.edu +1 -0 + refclock_parse.c: + remove io binding before io_closeclock() closes the file descriptor + + ntpd/refclock_parse.c@1.47.1.1, 2007-08-11 17:17:16+00:00, kardel@pogo.udel.edu +25 -10 + remove io binding before io_closeclock() closes the file descriptor + +ChangeSet@1.1436.1.69, 2007-08-09 20:30:55+00:00, kardel@pogo.udel.edu +1 -0 + ChangeLog: + [Bug 882] allow loopback interfaces to share addresses with other interfaces. + [Bug 884] don't access recv buffers after having them passed to the free list. + + ChangeLog@1.1.1.24, 2007-08-09 20:30:26+00:00, kardel@pogo.udel.edu +3 -0 + [Bug 882] allow loopback interfaces to share addresses with other interfaces. + [Bug 884] don't access recv buffers after having them passed to the free list. + +ChangeSet@1.1436.1.68, 2007-08-09 19:05:17+00:00, kardel@pogo.udel.edu +1 -0 + ntp_io.c: + Bug 884: no access to recv buffers after they are returned to free pool + + ntpd/ntp_io.c@1.244.2.8, 2007-08-09 19:01:30+00:00, kardel@pogo.udel.edu +9 -7 + Bug 884: no access to recv buffers after they are returned to free pool + +ChangeSet@1.1564.1.2, 2007-08-09 07:43:48-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P67 + TAG: NTP_4_2_5P67 + + ntpd/ntpd-opts.c@1.54, 2007-08-09 07:43:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P67 + + ntpd/ntpd-opts.h@1.54, 2007-08-09 07:43:31-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P67 + + ntpd/ntpd-opts.texi@1.53, 2007-08-09 07:43:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P67 + + ntpd/ntpd.1@1.53, 2007-08-09 07:43:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P67 + + ntpdc/ntpdc-opts.c@1.54, 2007-08-09 07:43:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P67 + + ntpdc/ntpdc-opts.h@1.54, 2007-08-09 07:43:34-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P67 + + ntpdc/ntpdc-opts.texi@1.53, 2007-08-09 07:43:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P67 + + ntpdc/ntpdc.1@1.53, 2007-08-09 07:43:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P67 + + ntpq/ntpq-opts.c@1.54, 2007-08-09 07:43:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P67 + + ntpq/ntpq-opts.h@1.54, 2007-08-09 07:43:36-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P67 + + ntpq/ntpq-opts.texi@1.53, 2007-08-09 07:43:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P67 + + ntpq/ntpq.1@1.53, 2007-08-09 07:43:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P67 + + packageinfo.sh@1.70, 2007-08-09 07:43:39-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P67 + + sntp/sntp-opts.c@1.54, 2007-08-09 07:43:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P67 + + sntp/sntp-opts.h@1.54, 2007-08-09 07:43:40-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P67 + + sntp/sntp-opts.texi@1.53, 2007-08-09 07:43:41-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P67 + + sntp/sntp.1@1.53, 2007-08-09 07:43:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P67 + + util/ntp-keygen-opts.c@1.55, 2007-08-09 07:43:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P67 + + util/ntp-keygen-opts.h@1.55, 2007-08-09 07:43:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P67 + + util/ntp-keygen-opts.texi@1.54, 2007-08-09 07:43:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P67 + + util/ntp-keygen.1@1.54, 2007-08-09 07:43:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P67 + +ChangeSet@1.1564.1.1, 2007-08-08 20:33:49-04:00, stenn@whimsy.udel.edu +2 -0 + Improve Calysto support + + ChangeLog@1.95, 2007-08-08 20:33:36-04:00, stenn@whimsy.udel.edu +1 -0 + Improve Calysto support + + include/ntp_assert.h@1.2, 2007-08-08 20:33:37-04:00, stenn@whimsy.udel.edu +12 -0 + Improve Calysto support + +ChangeSet@1.1436.1.67, 2007-08-07 18:14:16+00:00, kardel@pogo.udel.edu +1 -0 + ntp_io.c: + Bug 882: loopback interfaces may share IP addresses with other interfaces + thus allow addresses also found on loopback interfaces to be used + as local address. + + ntpd/ntp_io.c@1.244.2.7, 2007-08-07 18:09:50+00:00, kardel@pogo.udel.edu +1 -1 + Bug 882: loopback interfaces may share IP addresses with other interfaces + thus allow addresses also found on loopback interfaces to be used + as local address. + +ChangeSet@1.1564, 2007-08-07 07:44:49-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P66 + TAG: NTP_4_2_5P66 + + ntpd/ntpd-opts.c@1.53, 2007-08-07 07:44:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P66 + + ntpd/ntpd-opts.h@1.53, 2007-08-07 07:44:30-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P66 + + ntpd/ntpd-opts.texi@1.52, 2007-08-07 07:44:30-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P66 + + ntpd/ntpd.1@1.52, 2007-08-07 07:44:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P66 + + ntpdc/ntpdc-opts.c@1.53, 2007-08-07 07:44:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P66 + + ntpdc/ntpdc-opts.h@1.53, 2007-08-07 07:44:32-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P66 + + ntpdc/ntpdc-opts.texi@1.52, 2007-08-07 07:44:33-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P66 + + ntpdc/ntpdc.1@1.52, 2007-08-07 07:44:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P66 + + ntpq/ntpq-opts.c@1.53, 2007-08-07 07:44:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P66 + + ntpq/ntpq-opts.h@1.53, 2007-08-07 07:44:36-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P66 + + ntpq/ntpq-opts.texi@1.52, 2007-08-07 07:44:36-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P66 + + ntpq/ntpq.1@1.52, 2007-08-07 07:44:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P66 + + packageinfo.sh@1.69, 2007-08-07 07:44:37-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P66 + + sntp/sntp-opts.c@1.53, 2007-08-07 07:44:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P66 + + sntp/sntp-opts.h@1.53, 2007-08-07 07:44:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P66 + + sntp/sntp-opts.texi@1.52, 2007-08-07 07:44:40-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P66 + + sntp/sntp.1@1.52, 2007-08-07 07:44:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P66 + + util/ntp-keygen-opts.c@1.54, 2007-08-07 07:44:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P66 + + util/ntp-keygen-opts.h@1.54, 2007-08-07 07:44:42-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P66 + + util/ntp-keygen-opts.texi@1.53, 2007-08-07 07:44:43-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P66 + + util/ntp-keygen.1@1.53, 2007-08-07 07:44:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P66 + +ChangeSet@1.1563, 2007-08-07 03:10:48-04:00, stenn@whimsy.udel.edu +3 -0 + The "revoke" parameter is a crypto command + + ChangeLog@1.94, 2007-08-07 03:10:31-04:00, stenn@whimsy.udel.edu +1 -0 + The "revoke" parameter is a crypto command + + ntpd/ntp_parser.c@1.18, 2007-08-07 03:10:32-04:00, stenn@whimsy.udel.edu +183 -193 + The "revoke" parameter is a crypto command + + ntpd/ntp_parser.y@1.14, 2007-08-07 03:10:33-04:00, stenn@whimsy.udel.edu +11 -11 + The "revoke" parameter is a crypto command + +ChangeSet@1.1562, 2007-08-07 01:21:53-04:00, stenn@whimsy.udel.edu +2 -0 + The driftfile wander threshold is a real number + + ChangeLog@1.93, 2007-08-07 01:21:36-04:00, stenn@whimsy.udel.edu +1 -0 + The driftfile wander threshold is a real number + + ntpd/ntp_parser.c@1.17, 2007-08-07 01:21:37-04:00, stenn@whimsy.udel.edu +151 -141 + The driftfile wander threshold is a real number + +ChangeSet@1.1561, 2007-08-05 07:44:12-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P65 + TAG: NTP_4_2_5P65 + + ntpd/ntpd-opts.c@1.52, 2007-08-05 07:43:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P65 + + ntpd/ntpd-opts.h@1.52, 2007-08-05 07:43:55-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P65 + + ntpd/ntpd-opts.texi@1.51, 2007-08-05 07:43:56-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P65 + + ntpd/ntpd.1@1.51, 2007-08-05 07:43:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P65 + + ntpdc/ntpdc-opts.c@1.52, 2007-08-05 07:43:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P65 + + ntpdc/ntpdc-opts.h@1.52, 2007-08-05 07:43:58-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P65 + + ntpdc/ntpdc-opts.texi@1.51, 2007-08-05 07:43:58-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P65 + + ntpdc/ntpdc.1@1.51, 2007-08-05 07:43:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P65 + + ntpq/ntpq-opts.c@1.52, 2007-08-05 07:44:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P65 + + ntpq/ntpq-opts.h@1.52, 2007-08-05 07:44:00-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P65 + + ntpq/ntpq-opts.texi@1.51, 2007-08-05 07:44:01-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P65 + + ntpq/ntpq.1@1.51, 2007-08-05 07:44:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P65 + + packageinfo.sh@1.68, 2007-08-05 07:44:03-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P65 + + sntp/sntp-opts.c@1.52, 2007-08-05 07:44:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P65 + + sntp/sntp-opts.h@1.52, 2007-08-05 07:44:04-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P65 + + sntp/sntp-opts.texi@1.51, 2007-08-05 07:44:05-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P65 + + sntp/sntp.1@1.51, 2007-08-05 07:44:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P65 + + util/ntp-keygen-opts.c@1.53, 2007-08-05 07:44:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P65 + + util/ntp-keygen-opts.h@1.53, 2007-08-05 07:44:06-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P65 + + util/ntp-keygen-opts.texi@1.52, 2007-08-05 07:44:07-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P65 + + util/ntp-keygen.1@1.52, 2007-08-05 07:44:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P65 + +ChangeSet@1.1560, 2007-08-04 16:51:04-04:00, stenn@whimsy.udel.edu +3 -0 + [Bug 850] Fix the wander threshold parameter on the driftfile command + + ChangeLog@1.92, 2007-08-04 16:50:34-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 850] Fix the wander threshold parameter on the driftfile command + + ntpd/ntp_parser.c@1.16, 2007-08-04 16:50:36-04:00, stenn@whimsy.udel.edu +142 -152 + [Bug 850] Fix the wander threshold parameter on the driftfile command + + ntpd/ntp_parser.y@1.13, 2007-08-04 16:50:37-04:00, stenn@whimsy.udel.edu +1 -1 + [Bug 850] Fix the wander threshold parameter on the driftfile command + +ChangeSet@1.1559, 2007-07-30 07:45:28-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P64 + TAG: NTP_4_2_5P64 + + ntpd/ntpd-opts.c@1.51, 2007-07-30 07:45:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P64 + + ntpd/ntpd-opts.h@1.51, 2007-07-30 07:45:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P64 + + ntpd/ntpd-opts.texi@1.50, 2007-07-30 07:45:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P64 + + ntpd/ntpd.1@1.50, 2007-07-30 07:45:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P64 + + ntpdc/ntpdc-opts.c@1.51, 2007-07-30 07:45:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P64 + + ntpdc/ntpdc-opts.h@1.51, 2007-07-30 07:45:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P64 + + ntpdc/ntpdc-opts.texi@1.50, 2007-07-30 07:45:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P64 + + ntpdc/ntpdc.1@1.50, 2007-07-30 07:45:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P64 + + ntpq/ntpq-opts.c@1.51, 2007-07-30 07:45:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P64 + + ntpq/ntpq-opts.h@1.51, 2007-07-30 07:45:15-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P64 + + ntpq/ntpq-opts.texi@1.50, 2007-07-30 07:45:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P64 + + ntpq/ntpq.1@1.50, 2007-07-30 07:45:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P64 + + packageinfo.sh@1.67, 2007-07-30 07:45:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P64 + + sntp/sntp-opts.c@1.51, 2007-07-30 07:45:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P64 + + sntp/sntp-opts.h@1.51, 2007-07-30 07:45:18-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P64 + + sntp/sntp-opts.texi@1.50, 2007-07-30 07:45:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P64 + + sntp/sntp.1@1.50, 2007-07-30 07:45:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P64 + + util/ntp-keygen-opts.c@1.52, 2007-07-30 07:45:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P64 + + util/ntp-keygen-opts.h@1.52, 2007-07-30 07:45:21-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P64 + + util/ntp-keygen-opts.texi@1.51, 2007-07-30 07:45:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P64 + + util/ntp-keygen.1@1.51, 2007-07-30 07:45:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P64 + +ChangeSet@1.1558, 2007-07-29 15:44:57-04:00, stenn@whimsy.udel.edu +4 -0 + ntp_peer.c, ChangeLog: + Set peer->srcadr before (not after) calling set_peerdstadr() + ntp_util.c, ChangeLog: + Leap file related cleanup from Dave Mills + ntp_io.c, ChangeLog: + Dead code cleanup - Coverity View 19 + + ChangeLog@1.91, 2007-07-29 15:44:07-04:00, stenn@whimsy.udel.edu +1 -0 + Dead code cleanup - Coverity View 19 + + ChangeLog@1.90, 2007-07-29 15:42:21-04:00, stenn@whimsy.udel.edu +1 -0 + Leap file related cleanup from Dave Mills + + ChangeLog@1.89, 2007-07-29 15:40:44-04:00, stenn@whimsy.udel.edu +1 -0 + Set peer->srcadr before (not after) calling set_peerdstadr() + + ntpd/ntp_io.c@1.259, 2007-07-29 15:44:08-04:00, stenn@whimsy.udel.edu +0 -13 + Dead code cleanup - Coverity View 19 + + ntpd/ntp_peer.c@1.105, 2007-07-29 15:38:57-04:00, stenn@whimsy.udel.edu +11 -15 + Set peer->srcadr before (not after) calling set_peerdstadr() + + ntpd/ntp_util.c@1.58, 2007-07-29 15:42:20-04:00, stenn@whimsy.udel.edu +21 -37 + Leap file related cleanup from Dave Mills + +ChangeSet@1.1557, 2007-07-29 07:44:44-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P63 + TAG: NTP_4_2_5P63 + + ntpd/ntpd-opts.c@1.50, 2007-07-29 07:44:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P63 + + ntpd/ntpd-opts.h@1.50, 2007-07-29 07:44:25-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P63 + + ntpd/ntpd-opts.texi@1.49, 2007-07-29 07:44:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P63 + + ntpd/ntpd.1@1.49, 2007-07-29 07:44:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P63 + + ntpdc/ntpdc-opts.c@1.50, 2007-07-29 07:44:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P63 + + ntpdc/ntpdc-opts.h@1.50, 2007-07-29 07:44:28-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P63 + + ntpdc/ntpdc-opts.texi@1.49, 2007-07-29 07:44:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P63 + + ntpdc/ntpdc.1@1.49, 2007-07-29 07:44:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P63 + + ntpq/ntpq-opts.c@1.50, 2007-07-29 07:44:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P63 + + ntpq/ntpq-opts.h@1.50, 2007-07-29 07:44:31-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P63 + + ntpq/ntpq-opts.texi@1.49, 2007-07-29 07:44:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P63 + + ntpq/ntpq.1@1.49, 2007-07-29 07:44:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P63 + + packageinfo.sh@1.66, 2007-07-29 07:44:33-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P63 + + sntp/sntp-opts.c@1.50, 2007-07-29 07:44:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P63 + + sntp/sntp-opts.h@1.50, 2007-07-29 07:44:35-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P63 + + sntp/sntp-opts.texi@1.49, 2007-07-29 07:44:35-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P63 + + sntp/sntp.1@1.49, 2007-07-29 07:44:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P63 + + util/ntp-keygen-opts.c@1.51, 2007-07-29 07:44:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P63 + + util/ntp-keygen-opts.h@1.51, 2007-07-29 07:44:37-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P63 + + util/ntp-keygen-opts.texi@1.50, 2007-07-29 07:44:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P63 + + util/ntp-keygen.1@1.50, 2007-07-29 07:44:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P63 + +ChangeSet@1.1556, 2007-07-29 02:30:13-04:00, stenn@whimsy.udel.edu +2 -0 + Initialize offset in leap_file() - Coverity View 17 + + ChangeLog@1.88, 2007-07-29 02:29:59-04:00, stenn@whimsy.udel.edu +1 -0 + Initialize offset in leap_file() - Coverity View 17 + + ntpd/ntp_util.c@1.57, 2007-07-29 02:29:59-04:00, stenn@whimsy.udel.edu +2 -1 + Initialize offset in leap_file() - Coverity View 17 + +ChangeSet@1.1555, 2007-07-28 07:44:54-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P62 + TAG: NTP_4_2_5P62 + + ntpd/ntpd-opts.c@1.49, 2007-07-28 07:44:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P62 + + ntpd/ntpd-opts.h@1.49, 2007-07-28 07:44:36-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P62 + + ntpd/ntpd-opts.texi@1.48, 2007-07-28 07:44:36-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P62 + + ntpd/ntpd.1@1.48, 2007-07-28 07:44:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P62 + + ntpdc/ntpdc-opts.c@1.49, 2007-07-28 07:44:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P62 + + ntpdc/ntpdc-opts.h@1.49, 2007-07-28 07:44:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P62 + + ntpdc/ntpdc-opts.texi@1.48, 2007-07-28 07:44:40-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P62 + + ntpdc/ntpdc.1@1.48, 2007-07-28 07:44:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P62 + + ntpq/ntpq-opts.c@1.49, 2007-07-28 07:44:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P62 + + ntpq/ntpq-opts.h@1.49, 2007-07-28 07:44:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P62 + + ntpq/ntpq-opts.texi@1.48, 2007-07-28 07:44:44-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P62 + + ntpq/ntpq.1@1.48, 2007-07-28 07:44:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P62 + + packageinfo.sh@1.65, 2007-07-28 07:44:45-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P62 + + sntp/sntp-opts.c@1.49, 2007-07-28 07:44:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P62 + + sntp/sntp-opts.h@1.49, 2007-07-28 07:44:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P62 + + sntp/sntp-opts.texi@1.48, 2007-07-28 07:44:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P62 + + sntp/sntp.1@1.48, 2007-07-28 07:44:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P62 + + util/ntp-keygen-opts.c@1.50, 2007-07-28 07:44:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P62 + + util/ntp-keygen-opts.h@1.50, 2007-07-28 07:44:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P62 + + util/ntp-keygen-opts.texi@1.49, 2007-07-28 07:44:49-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P62 + + util/ntp-keygen.1@1.49, 2007-07-28 07:44:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P62 + +ChangeSet@1.1554, 2007-07-28 02:22:13-04:00, stenn@whimsy.udel.edu +1 -0 + (ChangeLog entries for previous changeset) + + ChangeLog@1.87, 2007-07-28 02:20:30-04:00, stenn@whimsy.udel.edu +3 -0 + +ChangeSet@1.1553, 2007-07-27 23:47:45-04:00, stenn@whimsy.udel.edu +3 -0 + systime.c: + fuzz cleanup + ntp_loopfilter.c, ntp_proto.c: + Show more digits during some debug printfs. Use the correct packet stratum in KISS codes. + + libntp/systime.c@1.43, 2007-07-27 23:45:15-04:00, stenn@whimsy.udel.edu +2 -2 + fuzz cleanup + + ntpd/ntp_loopfilter.c@1.138, 2007-07-27 23:44:02-04:00, stenn@whimsy.udel.edu +1 -1 + Show more digits during some debug printfs. Use the correct packet stratum in KISS codes. + + ntpd/ntp_proto.c@1.259, 2007-07-27 23:44:05-04:00, stenn@whimsy.udel.edu +2 -2 + Show more digits during some debug printfs. Use the correct packet stratum in KISS codes. + +ChangeSet@1.1552, 2007-07-25 07:44:25-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P61 + TAG: NTP_4_2_5P61 + + ntpd/ntpd-opts.c@1.48, 2007-07-25 07:44:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P61 + + ntpd/ntpd-opts.h@1.48, 2007-07-25 07:44:07-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P61 + + ntpd/ntpd-opts.texi@1.47, 2007-07-25 07:44:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P61 + + ntpd/ntpd.1@1.47, 2007-07-25 07:44:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P61 + + ntpdc/ntpdc-opts.c@1.48, 2007-07-25 07:44:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P61 + + ntpdc/ntpdc-opts.h@1.48, 2007-07-25 07:44:10-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P61 + + ntpdc/ntpdc-opts.texi@1.47, 2007-07-25 07:44:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P61 + + ntpdc/ntpdc.1@1.47, 2007-07-25 07:44:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P61 + + ntpq/ntpq-opts.c@1.48, 2007-07-25 07:44:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P61 + + ntpq/ntpq-opts.h@1.48, 2007-07-25 07:44:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P61 + + ntpq/ntpq-opts.texi@1.47, 2007-07-25 07:44:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P61 + + ntpq/ntpq.1@1.47, 2007-07-25 07:44:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P61 + + packageinfo.sh@1.64, 2007-07-25 07:44:15-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P61 + + sntp/sntp-opts.c@1.48, 2007-07-25 07:44:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P61 + + sntp/sntp-opts.h@1.48, 2007-07-25 07:44:17-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P61 + + sntp/sntp-opts.texi@1.47, 2007-07-25 07:44:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P61 + + sntp/sntp.1@1.47, 2007-07-25 07:44:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P61 + + util/ntp-keygen-opts.c@1.49, 2007-07-25 07:44:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P61 + + util/ntp-keygen-opts.h@1.49, 2007-07-25 07:44:19-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P61 + + util/ntp-keygen-opts.texi@1.48, 2007-07-25 07:44:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P61 + + util/ntp-keygen.1@1.48, 2007-07-25 07:44:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P61 + +ChangeSet@1.1551, 2007-07-24 15:01:03-04:00, stenn@whimsy.udel.edu +5 -0 + internal driftfile write control: drift_file_sw + + ChangeLog@1.86, 2007-07-24 15:00:20-04:00, stenn@whimsy.udel.edu +1 -0 + internal driftfile write control: drift_file_sw + + include/ntpd.h@1.107, 2007-07-24 14:59:45-04:00, stenn@whimsy.udel.edu +1 -0 + internal driftfile write control: drift_file_sw + + ntpd/ntp_config.c@1.161, 2007-07-24 14:58:56-04:00, stenn@whimsy.udel.edu +3 -1 + internal driftfile write control: drift_file_sw + + ntpd/ntp_loopfilter.c@1.137, 2007-07-24 14:59:00-04:00, stenn@whimsy.udel.edu +2 -1 + internal driftfile write control: drift_file_sw + + ntpd/ntp_util.c@1.56, 2007-07-24 14:59:07-04:00, stenn@whimsy.udel.edu +5 -3 + internal driftfile write control: drift_file_sw + +ChangeSet@1.1550, 2007-07-24 07:44:32-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P60 + TAG: NTP_4_2_5P60 + + ntpd/ntpd-opts.c@1.47, 2007-07-24 07:44:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P60 + + ntpd/ntpd-opts.h@1.47, 2007-07-24 07:44:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P60 + + ntpd/ntpd-opts.texi@1.46, 2007-07-24 07:44:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P60 + + ntpd/ntpd.1@1.46, 2007-07-24 07:44:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P60 + + ntpdc/ntpdc-opts.c@1.47, 2007-07-24 07:44:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P60 + + ntpdc/ntpdc-opts.h@1.47, 2007-07-24 07:44:17-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P60 + + ntpdc/ntpdc-opts.texi@1.46, 2007-07-24 07:44:18-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P60 + + ntpdc/ntpdc.1@1.46, 2007-07-24 07:44:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P60 + + ntpq/ntpq-opts.c@1.47, 2007-07-24 07:44:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P60 + + ntpq/ntpq-opts.h@1.47, 2007-07-24 07:44:20-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P60 + + ntpq/ntpq-opts.texi@1.46, 2007-07-24 07:44:20-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P60 + + ntpq/ntpq.1@1.46, 2007-07-24 07:44:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P60 + + packageinfo.sh@1.63, 2007-07-24 07:44:22-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P60 + + sntp/sntp-opts.c@1.47, 2007-07-24 07:44:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P60 + + sntp/sntp-opts.h@1.47, 2007-07-24 07:44:23-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P60 + + sntp/sntp-opts.texi@1.46, 2007-07-24 07:44:24-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P60 + + sntp/sntp.1@1.46, 2007-07-24 07:44:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P60 + + util/ntp-keygen-opts.c@1.48, 2007-07-24 07:44:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P60 + + util/ntp-keygen-opts.h@1.48, 2007-07-24 07:44:26-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P60 + + util/ntp-keygen-opts.texi@1.47, 2007-07-24 07:44:27-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P60 + + util/ntp-keygen.1@1.47, 2007-07-24 07:44:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P60 + +ChangeSet@1.1549, 2007-07-24 01:52:29-04:00, stenn@whimsy.udel.edu +5 -0 + Implement the wander_threshold option for the driftfile config keyword + + ChangeLog@1.85, 2007-07-24 01:52:11-04:00, stenn@whimsy.udel.edu +1 -0 + Implement the wander_threshold option for the driftfile config keyword + + ntpd/ntp_config.c@1.160, 2007-07-24 01:50:37-04:00, stenn@whimsy.udel.edu +3 -5 + Implement the wander_threshold option for the driftfile config keyword + + ntpd/ntp_parser.c@1.15, 2007-07-24 01:50:41-04:00, stenn@whimsy.udel.edu +321 -319 + Implement the wander_threshold option for the driftfile config keyword + + ntpd/ntp_parser.h@1.7, 2007-07-24 01:50:43-04:00, stenn@whimsy.udel.edu +1 -1 + Implement the wander_threshold option for the driftfile config keyword + + ntpd/ntp_parser.y@1.12, 2007-07-24 01:50:44-04:00, stenn@whimsy.udel.edu +207 -206 + Implement the wander_threshold option for the driftfile config keyword + +ChangeSet@1.1548, 2007-07-24 01:32:19-04:00, stenn@whimsy.udel.edu +2 -0 + c++ // comments are not allowed. + + ChangeLog@1.84, 2007-07-24 01:32:07-04:00, stenn@whimsy.udel.edu +1 -0 + c++ // comments are not allowed. + + ntpd/ntp_control.c@1.97, 2007-07-24 01:31:07-04:00, stenn@whimsy.udel.edu +449 -445 + c++ // comments are not allowed. + +ChangeSet@1.1547, 2007-07-23 07:45:57-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P59 + TAG: NTP_4_2_5P59 + + ntpd/ntpd-opts.c@1.46, 2007-07-23 07:45:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P59 + + ntpd/ntpd-opts.h@1.46, 2007-07-23 07:45:40-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P59 + + ntpd/ntpd-opts.texi@1.45, 2007-07-23 07:45:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P59 + + ntpd/ntpd.1@1.45, 2007-07-23 07:45:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P59 + + ntpdc/ntpdc-opts.c@1.46, 2007-07-23 07:45:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P59 + + ntpdc/ntpdc-opts.h@1.46, 2007-07-23 07:45:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P59 + + ntpdc/ntpdc-opts.texi@1.45, 2007-07-23 07:45:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P59 + + ntpdc/ntpdc.1@1.45, 2007-07-23 07:45:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P59 + + ntpq/ntpq-opts.c@1.46, 2007-07-23 07:45:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P59 + + ntpq/ntpq-opts.h@1.46, 2007-07-23 07:45:46-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P59 + + ntpq/ntpq-opts.texi@1.45, 2007-07-23 07:45:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P59 + + ntpq/ntpq.1@1.45, 2007-07-23 07:45:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P59 + + packageinfo.sh@1.62, 2007-07-23 07:45:49-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P59 + + sntp/sntp-opts.c@1.46, 2007-07-23 07:45:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P59 + + sntp/sntp-opts.h@1.46, 2007-07-23 07:45:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P59 + + sntp/sntp-opts.texi@1.45, 2007-07-23 07:45:50-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P59 + + sntp/sntp.1@1.45, 2007-07-23 07:45:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P59 + + util/ntp-keygen-opts.c@1.47, 2007-07-23 07:45:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P59 + + util/ntp-keygen-opts.h@1.47, 2007-07-23 07:45:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P59 + + util/ntp-keygen-opts.texi@1.46, 2007-07-23 07:45:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P59 + + util/ntp-keygen.1@1.46, 2007-07-23 07:45:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P59 + +ChangeSet@1.1541.1.1, 2007-07-23 01:34:01-04:00, stenn@whimsy.udel.edu +21 -0 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, driftfile write cleanup, packet buffer length checks + + ChangeLog@1.81.1.1, 2007-07-23 01:33:50-04:00, stenn@whimsy.udel.edu +2 -0 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, driftfile write cleanup, packet buffer length checks + + html/confopt.html@1.37, 2007-07-23 01:31:10-04:00, stenn@whimsy.udel.edu +2 -0 + Documentation fixes from Dave Mills + + html/drivers/driver6.html@1.25, 2007-07-23 01:31:44-04:00, stenn@whimsy.udel.edu +4 -5 + Documentation fixes from Dave Mills + + html/index.html@1.33, 2007-07-23 01:31:12-04:00, stenn@whimsy.udel.edu +2 -2 + Documentation fixes from Dave Mills + + html/miscopt.html@1.36, 2007-07-23 01:31:13-04:00, stenn@whimsy.udel.edu +3 -13 + Documentation fixes from Dave Mills + + html/ntpd.html@1.40, 2007-07-23 01:31:15-04:00, stenn@whimsy.udel.edu +28 -20 + Documentation fixes from Dave Mills + + html/ntpdc.html@1.28, 2007-07-23 01:31:16-04:00, stenn@whimsy.udel.edu +3 -2 + Documentation fixes from Dave Mills + + html/scripts/links7.txt@1.3, 2007-07-23 01:31:45-04:00, stenn@whimsy.udel.edu +4 -1 + Documentation fixes from Dave Mills + + include/ntp.h@1.134, 2007-07-22 23:16:35-04:00, stenn@whimsy.udel.edu +12 -1 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup + + include/ntp_control.h@1.31, 2007-07-22 23:16:36-04:00, stenn@whimsy.udel.edu +21 -19 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup + + include/ntp_crypto.h@1.40, 2007-07-22 23:16:37-04:00, stenn@whimsy.udel.edu +3 -3 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup + + include/ntpd.h@1.106, 2007-07-22 23:16:41-04:00, stenn@whimsy.udel.edu +10 -8 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup + + ntpd/ntp_config.c@1.159, 2007-07-22 23:18:02-04:00, stenn@whimsy.udel.edu +8 -7 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, driftfile write cleanup, packet buffer length checks + + ntpd/ntp_control.c@1.96, 2007-07-22 23:18:04-04:00, stenn@whimsy.udel.edu +66 -50 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, driftfile write cleanup, packet buffer length checks + + ntpd/ntp_crypto.c@1.112, 2007-07-22 23:18:06-04:00, stenn@whimsy.udel.edu +153 -259 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, driftfile write cleanup, packet buffer length checks + + ntpd/ntp_loopfilter.c@1.136, 2007-07-22 23:18:08-04:00, stenn@whimsy.udel.edu +6 -9 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, driftfile write cleanup, packet buffer length checks + + ntpd/ntp_peer.c@1.104, 2007-07-22 23:18:10-04:00, stenn@whimsy.udel.edu +70 -71 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, driftfile write cleanup, packet buffer length checks + + ntpd/ntp_proto.c@1.258, 2007-07-22 23:18:11-04:00, stenn@whimsy.udel.edu +222 -176 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, driftfile write cleanup, packet buffer length checks + + ntpd/ntp_timer.c@1.39, 2007-07-22 23:18:15-04:00, stenn@whimsy.udel.edu +51 -40 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, driftfile write cleanup, packet buffer length checks + + ntpd/ntp_util.c@1.55, 2007-07-22 23:18:15-04:00, stenn@whimsy.udel.edu +36 -15 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, driftfile write cleanup, packet buffer length checks + + ntpd/refclock_acts.c@1.30, 2007-07-22 23:18:20-04:00, stenn@whimsy.udel.edu +1 -1 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, driftfile write cleanup, packet buffer length checks + +ChangeSet@1.1545, 2007-07-18 15:09:31-04:00, mayer@pogo.udel.edu +1 -0 + Undo bug #629 fixes as they cause more problems than were being solved + + ChangeLog@1.82, 2007-07-18 15:09:14-04:00, mayer@pogo.udel.edu +1 -0 + Undo bug #629 fixes as they cause more problems than were being solved + +ChangeSet@1.1544, 2007-07-18 15:03:37-04:00, mayer@pogo.udel.edu +1 -0 + Undo bug #629 fixes as they cause more problems than were being solved + + ntpd/ntp_io.c@1.258, 2007-07-18 15:03:20-04:00, mayer@pogo.udel.edu +1 -8 + Undo bug #629 fixes as they cause more problems than were eing solved + +ChangeSet@1.1543, 2007-07-18 13:57:51-04:00, mayer@pogo.udel.edu +1 -0 + Undo bug #629 fixes as they cause more problems than were being solved + + ports/winnt/ntpd/ntp_iocompletionport.c@1.32, 2007-07-18 13:57:37-04:00, mayer@pogo.udel.edu +2 -4 + Undo bug #629 fixes as they cause more problems than were being solved + +ChangeSet@1.1529.2.12, 2007-07-18 13:53:24-04:00, mayer@pogo.udel.edu +2 -0 + Undo bug #629 fixes as they cause more problems than were eing solved + + ntpd/ntp_io.c@1.257, 2007-07-18 13:52:56-04:00, mayer@pogo.udel.edu +1 -8 + Undo bug #629 fixes as they cause more problems than were being solved + + ports/winnt/ntpd/ntp_iocompletionport.c@1.31, 2007-07-18 13:52:57-04:00, mayer@pogo.udel.edu +0 -15 + Undo bug #629 fixes as they cause more problems than were being solved + +ChangeSet@1.1541, 2007-06-30 07:46:53-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P58 + TAG: NTP_4_2_5P58 + + ntpd/ntpd-opts.c@1.45, 2007-06-30 07:46:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P58 + + ntpd/ntpd-opts.h@1.45, 2007-06-30 07:46:34-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P58 + + ntpd/ntpd-opts.texi@1.44, 2007-06-30 07:46:35-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P58 + + ntpd/ntpd.1@1.44, 2007-06-30 07:46:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P58 + + ntpdc/ntpdc-opts.c@1.45, 2007-06-30 07:46:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P58 + + ntpdc/ntpdc-opts.h@1.45, 2007-06-30 07:46:38-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P58 + + ntpdc/ntpdc-opts.texi@1.44, 2007-06-30 07:46:39-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P58 + + ntpdc/ntpdc.1@1.44, 2007-06-30 07:46:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P58 + + ntpq/ntpq-opts.c@1.45, 2007-06-30 07:46:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P58 + + ntpq/ntpq-opts.h@1.45, 2007-06-30 07:46:41-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P58 + + ntpq/ntpq-opts.texi@1.44, 2007-06-30 07:46:41-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P58 + + ntpq/ntpq.1@1.44, 2007-06-30 07:46:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P58 + + packageinfo.sh@1.61, 2007-06-30 07:46:43-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P58 + + sntp/sntp-opts.c@1.45, 2007-06-30 07:46:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P58 + + sntp/sntp-opts.h@1.45, 2007-06-30 07:46:44-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P58 + + sntp/sntp-opts.texi@1.44, 2007-06-30 07:46:45-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P58 + + sntp/sntp.1@1.44, 2007-06-30 07:46:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P58 + + util/ntp-keygen-opts.c@1.46, 2007-06-30 07:46:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P58 + + util/ntp-keygen-opts.h@1.46, 2007-06-30 07:46:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P58 + + util/ntp-keygen-opts.texi@1.45, 2007-06-30 07:46:48-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P58 + + util/ntp-keygen.1@1.45, 2007-06-30 07:46:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P58 + +ChangeSet@1.1540, 2007-06-29 21:15:27+00:00, stenn@ntp1.isc.org +1 -0 + format cleanup + + ChangeLog@1.81, 2007-06-29 21:15:11+00:00, stenn@ntp1.isc.org +37 -39 + format cleanup + +ChangeSet@1.1539, 2007-06-29 16:23:16-04:00, stenn@whimsy.udel.edu +1 -0 + cleanup + + NEWS@1.100, 2007-06-29 16:23:05-04:00, stenn@whimsy.udel.edu +1 -0 + cleanup + +ChangeSet@1.1436.1.66, 2007-06-29 15:46:00-04:00, stenn@deacon.udel.edu +25 -0 + NTP_4_2_4P3 + TAG: NTP_4_2_4P3 + + ntpd/ntpd-opts.c@1.50.10.1, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_4P3 + + ntpd/ntpd-opts.h@1.50.10.1, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_4P3 + + ntpd/ntpd-opts.texi@1.49.10.1, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_4P3 + + ntpd/ntpd.1@1.48.10.1, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_4P3 + + ntpd/ntpdsim-opts.c@1.50.10.1, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_4P3 + + ntpd/ntpdsim-opts.h@1.50.10.1, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_4P3 + + ntpd/ntpdsim-opts.texi@1.48.10.1, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_4P3 + + ntpd/ntpdsim.1@1.48.10.1, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_4P3 + + ntpdc/ntpdc-opts.c@1.50.10.1, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_4P3 + + ntpdc/ntpdc-opts.h@1.50.10.1, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_4P3 + + ntpdc/ntpdc-opts.texi@1.48.10.1, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_4P3 + + ntpdc/ntpdc.1@1.48.10.1, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_4P3 + + ntpq/ntpq-opts.c@1.52.10.1, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_4P3 + + ntpq/ntpq-opts.h@1.52.10.1, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_4P3 + + ntpq/ntpq-opts.texi@1.49.10.1, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_4P3 + + ntpq/ntpq.1@1.48.10.1, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_4P3 + + packageinfo.sh@1.65.16.2, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_4P3 + + sntp/sntp-opts.c@1.49.10.1, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_4P3 + + sntp/sntp-opts.h@1.49.10.1, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_4P3 + + sntp/sntp-opts.texi@1.46.10.1, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +1 -1 + NTP_4_2_4P3 + + sntp/sntp.1@1.49.10.1, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_4P3 + + util/ntp-keygen-opts.c@1.49.10.1, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_4P3 + + util/ntp-keygen-opts.h@1.49.10.1, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +3 -3 + NTP_4_2_4P3 + + util/ntp-keygen-opts.texi@1.47.10.1, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_4P3 + + util/ntp-keygen.1@1.47.10.1, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 + NTP_4_2_4P3 + +ChangeSet@1.1436.1.65, 2007-06-29 15:31:21-04:00, stenn@deacon.udel.edu +3 -0 + Release 4.2.4p3 + + ChangeLog@1.1.1.23, 2007-06-29 15:30:58-04:00, stenn@deacon.udel.edu +1 -1 + Release 4.2.4p3 + + NEWS@1.86.1.11, 2007-06-29 15:30:58-04:00, stenn@deacon.udel.edu +1 -1 + Release 4.2.4p3 + + packageinfo.sh@1.65.16.1, 2007-06-29 15:30:58-04:00, stenn@deacon.udel.edu +1 -1 + Release 4.2.4p3 + +ChangeSet@1.1436.1.64, 2007-06-29 19:03:39+00:00, stenn@ntp1.isc.org +2 -0 + Cosmetic reformatting + + ChangeLog@1.1.1.22, 2007-06-29 19:03:32+00:00, stenn@ntp1.isc.org +70 -16 + Cosmetic reformatting + + NEWS@1.86.1.10, 2007-06-29 19:03:32+00:00, stenn@ntp1.isc.org +4 -0 + Cosmetic reformatting + +ChangeSet@1.1537, 2007-06-28 07:47:21-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P57 + TAG: NTP_4_2_5P57 + + ntpd/ntpd-opts.c@1.44, 2007-06-28 07:47:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P57 + + ntpd/ntpd-opts.h@1.44, 2007-06-28 07:47:03-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P57 + + ntpd/ntpd-opts.texi@1.43, 2007-06-28 07:47:04-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P57 + + ntpd/ntpd.1@1.43, 2007-06-28 07:47:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P57 + + ntpdc/ntpdc-opts.c@1.44, 2007-06-28 07:47:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P57 + + ntpdc/ntpdc-opts.h@1.44, 2007-06-28 07:47:06-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P57 + + ntpdc/ntpdc-opts.texi@1.43, 2007-06-28 07:47:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P57 + + ntpdc/ntpdc.1@1.43, 2007-06-28 07:47:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P57 + + ntpq/ntpq-opts.c@1.44, 2007-06-28 07:47:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P57 + + ntpq/ntpq-opts.h@1.44, 2007-06-28 07:47:09-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P57 + + ntpq/ntpq-opts.texi@1.43, 2007-06-28 07:47:10-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P57 + + ntpq/ntpq.1@1.43, 2007-06-28 07:47:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P57 + + packageinfo.sh@1.60, 2007-06-28 07:47:12-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P57 + + sntp/sntp-opts.c@1.44, 2007-06-28 07:47:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P57 + + sntp/sntp-opts.h@1.44, 2007-06-28 07:47:13-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P57 + + sntp/sntp-opts.texi@1.43, 2007-06-28 07:47:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P57 + + sntp/sntp.1@1.43, 2007-06-28 07:47:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P57 + + util/ntp-keygen-opts.c@1.45, 2007-06-28 07:47:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P57 + + util/ntp-keygen-opts.h@1.45, 2007-06-28 07:47:16-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P57 + + util/ntp-keygen-opts.texi@1.44, 2007-06-28 07:47:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P57 + + util/ntp-keygen.1@1.44, 2007-06-28 07:47:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P57 + +ChangeSet@1.1535, 2007-06-28 04:11:15-04:00, stenn@whimsy.udel.edu +3 -0 + More assertion checks and malloc()->emalloc(), courtesy of Calysto + + ChangeLog@1.78, 2007-06-28 04:10:24-04:00, stenn@whimsy.udel.edu +1 -0 + More assertion checks and malloc()->emalloc(), courtesy of Calysto + + ntpd/ntp_crypto.c@1.111, 2007-06-28 04:10:27-04:00, stenn@whimsy.udel.edu +6 -1 + More assertion checks and malloc()->emalloc(), courtesy of Calysto + + ntpd/ntp_data_structures.c@1.5, 2007-06-28 04:10:30-04:00, stenn@whimsy.udel.edu +2 -2 + More assertion checks and malloc()->emalloc(), courtesy of Calysto + +ChangeSet@1.1534, 2007-06-28 04:05:43-04:00, stenn@whimsy.udel.edu +1 -0 + typo + + ChangeLog@1.77, 2007-06-28 04:05:30-04:00, stenn@whimsy.udel.edu +1 -1 + typo + +ChangeSet@1.1533, 2007-06-27 09:48:59-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P56 + TAG: NTP_4_2_5P56 + + ntpd/ntpd-opts.c@1.43, 2007-06-27 09:48:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P56 + + ntpd/ntpd-opts.h@1.43, 2007-06-27 09:48:41-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P56 + + ntpd/ntpd-opts.texi@1.42, 2007-06-27 09:48:43-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P56 + + ntpd/ntpd.1@1.42, 2007-06-27 09:48:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P56 + + ntpdc/ntpdc-opts.c@1.43, 2007-06-27 09:48:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P56 + + ntpdc/ntpdc-opts.h@1.43, 2007-06-27 09:48:44-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P56 + + ntpdc/ntpdc-opts.texi@1.42, 2007-06-27 09:48:45-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P56 + + ntpdc/ntpdc.1@1.42, 2007-06-27 09:48:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P56 + + ntpq/ntpq-opts.c@1.43, 2007-06-27 09:48:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P56 + + ntpq/ntpq-opts.h@1.43, 2007-06-27 09:48:48-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P56 + + ntpq/ntpq-opts.texi@1.42, 2007-06-27 09:48:48-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P56 + + ntpq/ntpq.1@1.42, 2007-06-27 09:48:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P56 + + packageinfo.sh@1.59, 2007-06-27 09:48:50-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P56 + + sntp/sntp-opts.c@1.43, 2007-06-27 09:48:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P56 + + sntp/sntp-opts.h@1.43, 2007-06-27 09:48:51-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P56 + + sntp/sntp-opts.texi@1.42, 2007-06-27 09:48:52-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P56 + + sntp/sntp.1@1.42, 2007-06-27 09:48:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P56 + + util/ntp-keygen-opts.c@1.44, 2007-06-27 09:48:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P56 + + util/ntp-keygen-opts.h@1.44, 2007-06-27 09:48:55-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P56 + + util/ntp-keygen-opts.texi@1.43, 2007-06-27 09:48:55-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P56 + + util/ntp-keygen.1@1.43, 2007-06-27 09:48:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P56 + +ChangeSet@1.1436.1.63, 2007-06-27 07:46:44-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_4P3_RC1 + TAG: NTP_4_2_4P3_RC1 + + ntpd/ntpd-opts.c@1.50.9.1, 2007-06-27 07:46:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P3_RC1 + + ntpd/ntpd-opts.h@1.50.9.1, 2007-06-27 07:46:23-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P3_RC1 + + ntpd/ntpd-opts.texi@1.49.9.1, 2007-06-27 07:46:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P3_RC1 + + ntpd/ntpd.1@1.48.9.1, 2007-06-27 07:46:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P3_RC1 + + ntpd/ntpdsim-opts.c@1.50.9.1, 2007-06-27 07:46:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P3_RC1 + + ntpd/ntpdsim-opts.h@1.50.9.1, 2007-06-27 07:46:26-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P3_RC1 + + ntpd/ntpdsim-opts.texi@1.48.9.1, 2007-06-27 07:46:27-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P3_RC1 + + ntpd/ntpdsim.1@1.48.9.1, 2007-06-27 07:46:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P3_RC1 + + ntpdc/ntpdc-opts.c@1.50.9.1, 2007-06-27 07:46:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P3_RC1 + + ntpdc/ntpdc-opts.h@1.50.9.1, 2007-06-27 07:46:29-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P3_RC1 + + ntpdc/ntpdc-opts.texi@1.48.9.1, 2007-06-27 07:46:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P3_RC1 + + ntpdc/ntpdc.1@1.48.9.1, 2007-06-27 07:46:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P3_RC1 + + ntpq/ntpq-opts.c@1.52.9.1, 2007-06-27 07:46:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P3_RC1 + + ntpq/ntpq-opts.h@1.52.9.1, 2007-06-27 07:46:32-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P3_RC1 + + ntpq/ntpq-opts.texi@1.49.9.1, 2007-06-27 07:46:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P3_RC1 + + ntpq/ntpq.1@1.48.9.1, 2007-06-27 07:46:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P3_RC1 + + packageinfo.sh@1.65.15.2, 2007-06-27 07:46:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P3_RC1 + + sntp/sntp-opts.c@1.49.9.1, 2007-06-27 07:46:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P3_RC1 + + sntp/sntp-opts.h@1.49.9.1, 2007-06-27 07:46:36-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P3_RC1 + + sntp/sntp-opts.texi@1.46.9.1, 2007-06-27 07:46:36-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P3_RC1 + + sntp/sntp.1@1.49.9.1, 2007-06-27 07:46:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P3_RC1 + + util/ntp-keygen-opts.c@1.49.9.1, 2007-06-27 07:46:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P3_RC1 + + util/ntp-keygen-opts.h@1.49.9.1, 2007-06-27 07:46:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P3_RC1 + + util/ntp-keygen-opts.texi@1.47.9.1, 2007-06-27 07:46:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P3_RC1 + + util/ntp-keygen.1@1.47.9.1, 2007-06-27 07:46:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P3_RC1 + +ChangeSet@1.1529.3.4, 2007-06-27 02:21:23-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 604] ntpd regularly dies on linux/alpha + + ChangeLog@1.73.3.3, 2007-06-27 02:21:06-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 604] ntpd regularly dies on linux/alpha + + ntpd/ntp_proto.c@1.255.1.2, 2007-06-27 02:21:08-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 604] ntpd regularly dies on linux/alpha + +ChangeSet@1.1529.3.3, 2007-06-27 02:15:24-04:00, stenn@whimsy.udel.edu +5 -0 + More leapsecond table file fixes from Dave Mills + + ChangeLog@1.73.3.2, 2007-06-27 02:15:02-04:00, stenn@whimsy.udel.edu +1 -1 + More leapsecond table file fixes from Dave Mills + + include/ntpd.h@1.105, 2007-06-27 02:11:23-04:00, stenn@whimsy.udel.edu +1 -0 + More leapsecond table file fixes from Dave Mills + + ntpd/ntp_crypto.c@1.110, 2007-06-27 02:12:17-04:00, stenn@whimsy.udel.edu +18 -6 + More leapsecond table file fixes from Dave Mills + + ntpd/ntp_proto.c@1.255.1.1, 2007-06-27 02:12:20-04:00, stenn@whimsy.udel.edu +41 -37 + More leapsecond table file fixes from Dave Mills + + ntpd/ntp_util.c@1.54, 2007-06-27 02:12:25-04:00, stenn@whimsy.udel.edu +16 -6 + More leapsecond table file fixes from Dave Mills + +ChangeSet@1.1529.3.2, 2007-06-27 02:06:19-04:00, stenn@whimsy.udel.edu +1 -0 + Notes for release + + NEWS@1.95.1.1, 2007-06-27 02:05:30-04:00, stenn@whimsy.udel.edu +2 -0 + Notes for release + +ChangeSet@1.1436.1.62, 2007-06-27 01:42:30-04:00, stenn@whimsy.udel.edu +3 -0 + First RC for 4.2.4p3 + + ChangeLog@1.1.1.21, 2007-06-27 01:41:43-04:00, stenn@whimsy.udel.edu +2 -1 + First RC for 4.2.4p3 + + NEWS@1.86.1.9, 2007-06-27 01:41:46-04:00, stenn@whimsy.udel.edu +8 -0 + First RC for 4.2.4p3 + + packageinfo.sh@1.65.15.1, 2007-06-27 01:41:59-04:00, stenn@whimsy.udel.edu +1 -1 + First RC for 4.2.4p3 + +ChangeSet@1.1529.3.1, 2007-06-26 22:43:22-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 858] recent leapfile changes broke non-OpenSSL builds. + + ChangeLog@1.73.3.1, 2007-06-26 22:43:10-04:00, stenn@whimsy.udel.edu +4 -2 + [Bug 858] recent leapfile changes broke non-OpenSSL builds. + + ntpd/ntp_control.c@1.95, 2007-06-26 22:43:09-04:00, stenn@whimsy.udel.edu +2 -1 + [Bug 858] recent leapfile changes broke non-OpenSSL builds. + +ChangeSet@1.1529.2.8, 2007-06-23 09:19:06-04:00, mayer@pogo.udel.edu +1 -0 + Added Bug #863 + + ChangeLog@1.73.2.2, 2007-06-23 09:18:34-04:00, mayer@pogo.udel.edu +2 -0 + Added Bug #863 + +ChangeSet@1.1523.1.2, 2007-06-23 08:50:46-04:00, mayer@pogo.udel.edu +3 -0 + Bug #863 Unable to stop ntpd because the handle index changed + + ports/winnt/include/ntp_iocompletionport.h@1.12.1.1, 2007-06-23 08:50:21-04:00, mayer@pogo.udel.edu +3 -0 + Bug #863 Unable to stop ntpd because the handle index changed + + ports/winnt/ntpd/ntp_iocompletionport.c@1.29, 2007-06-23 08:50:21-04:00, mayer@pogo.udel.edu +15 -1 + Bug #863 Unable to stop ntpd because the handle index changed + + ports/winnt/ntpd/ntservice.c@1.8.1.1, 2007-06-23 08:50:21-04:00, mayer@pogo.udel.edu +9 -5 + Bug #863 Unable to stop ntpd because the handle index changed + +ChangeSet@1.1436.1.61, 2007-06-23 08:47:07-04:00, mayer@pogo.udel.edu +1 -0 + Added Bug #863 + + ChangeLog@1.1.1.20, 2007-06-23 08:46:51-04:00, mayer@pogo.udel.edu +2 -0 + Added Bug #863 + +ChangeSet@1.1436.5.1, 2007-06-23 08:42:58-04:00, mayer@pogo.udel.edu +3 -0 + Bug #863 Unable to stop ntpd because the handle index changed + + ports/winnt/include/ntp_iocompletionport.h@1.13, 2007-06-23 08:42:41-04:00, mayer@pogo.udel.edu +3 -0 + Bug #863 Unable to stop ntpd because the handle index changed + + ports/winnt/ntpd/ntp_iocompletionport.c@1.21.1.2, 2007-06-23 08:42:41-04:00, mayer@pogo.udel.edu +15 -1 + Bug #863 Unable to stop ntpd because the handle index changed + + ports/winnt/ntpd/ntservice.c@1.9, 2007-06-23 08:42:41-04:00, mayer@pogo.udel.edu +9 -5 + Bug #863 Unable to stop ntpd because the handle index changed + +ChangeSet@1.1529.2.6, 2007-06-23 07:42:56-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P55 + TAG: NTP_4_2_5P55 + + ntpd/ntpd-opts.c@1.42, 2007-06-23 07:42:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P55 + + ntpd/ntpd-opts.h@1.42, 2007-06-23 07:42:35-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P55 + + ntpd/ntpd-opts.texi@1.41, 2007-06-23 07:42:36-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P55 + + ntpd/ntpd.1@1.41, 2007-06-23 07:42:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P55 + + ntpdc/ntpdc-opts.c@1.42, 2007-06-23 07:42:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P55 + + ntpdc/ntpdc-opts.h@1.42, 2007-06-23 07:42:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P55 + + ntpdc/ntpdc-opts.texi@1.41, 2007-06-23 07:42:40-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P55 + + ntpdc/ntpdc.1@1.41, 2007-06-23 07:42:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P55 + + ntpq/ntpq-opts.c@1.42, 2007-06-23 07:42:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P55 + + ntpq/ntpq-opts.h@1.42, 2007-06-23 07:42:42-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P55 + + ntpq/ntpq-opts.texi@1.41, 2007-06-23 07:42:43-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P55 + + ntpq/ntpq.1@1.41, 2007-06-23 07:42:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P55 + + packageinfo.sh@1.58, 2007-06-23 07:42:44-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P55 + + sntp/sntp-opts.c@1.42, 2007-06-23 07:42:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P55 + + sntp/sntp-opts.h@1.42, 2007-06-23 07:42:45-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P55 + + sntp/sntp-opts.texi@1.41, 2007-06-23 07:42:46-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P55 + + sntp/sntp.1@1.41, 2007-06-23 07:42:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P55 + + util/ntp-keygen-opts.c@1.43, 2007-06-23 07:42:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P55 + + util/ntp-keygen-opts.h@1.43, 2007-06-23 07:42:48-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P55 + + util/ntp-keygen-opts.texi@1.42, 2007-06-23 07:42:49-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P55 + + util/ntp-keygen.1@1.42, 2007-06-23 07:42:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P55 + +ChangeSet@1.1529.2.5, 2007-06-23 01:03:58-04:00, stenn@whimsy.udel.edu +1 -0 + Add more assertions (Calypso) + + util/ntp-keygen.c@1.42, 2007-06-23 01:03:45-04:00, stenn@whimsy.udel.edu +57 -1 + Add more assertions (Calypso) + +ChangeSet@1.1529.2.4, 2007-06-23 00:38:42-04:00, stenn@whimsy.udel.edu +1 -0 + Add more assertions (Calypso) + + util/ntp-keygen.c@1.41, 2007-06-23 00:38:31-04:00, stenn@whimsy.udel.edu +11 -8 + Add more assertions (Calypso) + +ChangeSet@1.1529.2.3, 2007-06-23 00:30:39-04:00, stenn@whimsy.udel.edu +1 -0 + Add more assertions (Calypso) + + libntp/caljulian.c@1.7, 2007-06-23 00:30:28-04:00, stenn@whimsy.udel.edu +3 -0 + Add more assertions (Calypso) + +ChangeSet@1.1529.2.2, 2007-06-23 00:18:26-04:00, stenn@whimsy.udel.edu +1 -0 + Add more assertions (Calypso) + + ntpd/ntp_crypto.c@1.109, 2007-06-23 00:18:15-04:00, stenn@whimsy.udel.edu +4 -1 + Add more assertions (Calypso) + +ChangeSet@1.1529.2.1, 2007-06-22 23:51:03-04:00, stenn@whimsy.udel.edu +2 -0 + Use emalloc() instead of malloc() in refclock_datum.c (Calypso). + + ChangeLog@1.73.2.1, 2007-06-22 23:50:51-04:00, stenn@whimsy.udel.edu +1 -0 + Use emalloc() instead of malloc() in refclock_datum.c (Calypso). + + ntpd/refclock_datum.c@1.11, 2007-06-22 23:50:52-04:00, stenn@whimsy.udel.edu +2 -2 + Use emalloc() instead of malloc() in refclock_datum.c (Calypso). + +ChangeSet@1.1529.1.5, 2007-06-22 12:52:24-04:00, utterback@pogo.udel.edu +4 -0 + [Bug 864] Place ntpd service in maintenance mode if using SMF on Solaris + + ChangeLog@1.73.1.3, 2007-06-22 12:52:20-04:00, utterback@pogo.udel.edu +1 -0 + [Bug 864] Place ntpd service in maintenance mode if using SMF on Solaris + + configure.ac@1.407, 2007-06-22 12:52:20-04:00, utterback@pogo.udel.edu +7 -1 + [Bug 864] Place ntpd service in maintenance mode if using SMF on Solaris + + ntpd/Makefile.am@1.63, 2007-06-22 12:52:21-04:00, utterback@pogo.udel.edu +2 -2 + [Bug 864] Place ntpd service in maintenance mode if using SMF on Solaris + + ntpd/ntp_proto.c@1.256, 2007-06-22 12:52:21-04:00, utterback@pogo.udel.edu +19 -0 + [Bug 864] Place ntpd service in maintenance mode if using SMF on Solaris + +ChangeSet@1.1529.1.4, 2007-06-22 07:43:48-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P54 + TAG: NTP_4_2_5P54 + + ntpd/ntpd-opts.c@1.41, 2007-06-22 07:43:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P54 + + ntpd/ntpd-opts.h@1.41, 2007-06-22 07:43:30-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P54 + + ntpd/ntpd-opts.texi@1.40, 2007-06-22 07:43:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P54 + + ntpd/ntpd.1@1.40, 2007-06-22 07:43:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P54 + + ntpdc/ntpdc-opts.c@1.41, 2007-06-22 07:43:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P54 + + ntpdc/ntpdc-opts.h@1.41, 2007-06-22 07:43:33-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P54 + + ntpdc/ntpdc-opts.texi@1.40, 2007-06-22 07:43:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P54 + + ntpdc/ntpdc.1@1.40, 2007-06-22 07:43:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P54 + + ntpq/ntpq-opts.c@1.41, 2007-06-22 07:43:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P54 + + ntpq/ntpq-opts.h@1.41, 2007-06-22 07:43:36-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P54 + + ntpq/ntpq-opts.texi@1.40, 2007-06-22 07:43:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P54 + + ntpq/ntpq.1@1.40, 2007-06-22 07:43:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P54 + + packageinfo.sh@1.57, 2007-06-22 07:43:39-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P54 + + sntp/sntp-opts.c@1.41, 2007-06-22 07:43:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P54 + + sntp/sntp-opts.h@1.41, 2007-06-22 07:43:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P54 + + sntp/sntp-opts.texi@1.40, 2007-06-22 07:43:40-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P54 + + sntp/sntp.1@1.40, 2007-06-22 07:43:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P54 + + util/ntp-keygen-opts.c@1.42, 2007-06-22 07:43:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P54 + + util/ntp-keygen-opts.h@1.42, 2007-06-22 07:43:42-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P54 + + util/ntp-keygen-opts.texi@1.41, 2007-06-22 07:43:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P54 + + util/ntp-keygen.1@1.41, 2007-06-22 07:43:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P54 + +ChangeSet@1.1529.1.3, 2007-06-22 02:11:30-04:00, stenn@deacon.udel.edu +10 -0 + Leapsecond file support + + ChangeLog@1.73.1.2, 2007-06-22 02:11:16-04:00, stenn@deacon.udel.edu +2 -2 + Leapsecond file support + + include/ntp.h@1.133, 2007-06-22 02:11:16-04:00, stenn@deacon.udel.edu +1 -0 + Leapsecond file support + + ntpd/ntp_config.c@1.156.1.2, 2007-06-22 02:11:16-04:00, stenn@deacon.udel.edu +6 -1 + Leapsecond file support + + ntpd/ntp_config.c@1.156.1.1, 2007-06-22 01:25:05-04:00, stenn@deacon.udel.edu +1 -0 + More leapsecond fixes from Dave Mills + + ntpd/ntp_control.c@1.94, 2007-06-22 01:25:05-04:00, stenn@deacon.udel.edu +3 -4 + More leapsecond fixes from Dave Mills + + ntpd/ntp_parser.c@1.14, 2007-06-22 01:25:05-04:00, stenn@deacon.udel.edu +684 -675 + More leapsecond fixes from Dave Mills + + ntpd/ntp_parser.h@1.6, 2007-06-22 01:25:05-04:00, stenn@deacon.udel.edu +92 -91 + More leapsecond fixes from Dave Mills + + ntpd/ntp_parser.y@1.11, 2007-06-22 01:25:05-04:00, stenn@deacon.udel.edu +3 -0 + More leapsecond fixes from Dave Mills + + ntpd/ntp_proto.c@1.255, 2007-06-22 01:25:05-04:00, stenn@deacon.udel.edu +65 -68 + More leapsecond fixes from Dave Mills + + ntpd/ntp_timer.c@1.38, 2007-06-22 01:25:06-04:00, stenn@deacon.udel.edu +20 -7 + More leapsecond fixes from Dave Mills + + ntpd/ntp_util.c@1.53, 2007-06-22 02:11:16-04:00, stenn@deacon.udel.edu +11 -1 + Leapsecond file support + + ntpd/ntp_util.c@1.52, 2007-06-22 01:25:06-04:00, stenn@deacon.udel.edu +44 -43 + More leapsecond fixes from Dave Mills + +ChangeSet@1.1529.1.2, 2007-06-22 01:17:17-04:00, stenn@deacon.udel.edu +1 -0 + Start using 'design by contract' assertions + + ntpd/ntp_io.c@1.254.1.1, 2007-06-22 01:17:11-04:00, stenn@deacon.udel.edu +3 -0 + Start using 'design by contract' assertions + +ChangeSet@1.1529.1.1, 2007-06-22 01:01:28-04:00, stenn@deacon.udel.edu +5 -0 + Start using 'design by contract' assertions + + ChangeLog@1.73.1.1, 2007-06-22 01:00:47-04:00, stenn@deacon.udel.edu +1 -0 + Start using 'design by contract' assertions + + include/Makefile.am@1.28, 2007-06-22 01:00:48-04:00, stenn@deacon.udel.edu +1 -0 + Start using 'design by contract' assertions + + include/ntp_assert.h@1.1, 2007-06-22 01:00:58-04:00, stenn@deacon.udel.edu +15 -0 + BitKeeper file /deacon/backroom/ntp-dev/include/ntp_assert.h + + include/ntp_assert.h@1.0, 2007-06-22 01:00:58-04:00, stenn@deacon.udel.edu +0 -0 + + libntp/atolfp.c@1.3, 2007-06-22 01:00:48-04:00, stenn@deacon.udel.edu +3 -0 + Start using 'design by contract' assertions + + libntp/prettydate.c@1.6, 2007-06-22 01:00:48-04:00, stenn@deacon.udel.edu +2 -0 + Start using 'design by contract' assertions + +ChangeSet@1.1530, 2007-06-21 09:10:39-04:00, neal@pogo.udel.edu +3 -0 + ChangeLog, ntp_config.c: + [Bug 862] includefile nesting; preserve phonelist on reconfig. + ntp_scanner.h: + [Bug 862] includefile nesting. + + ChangeLog@1.74, 2007-06-21 09:09:29-04:00, neal@pogo.udel.edu +1 -0 + [Bug 862] includefile nesting; preserve phonelist on reconfig. + + ntpd/ntp_config.c@1.157, 2007-06-21 09:05:15-04:00, neal@pogo.udel.edu +3 -2 + [Bug 862] includefile nesting; preserve phonelist on reconfig. + + ntpd/ntp_scanner.h@1.3, 2007-06-21 09:07:42-04:00, neal@pogo.udel.edu +1 -1 + [Bug 862] includefile nesting. + +ChangeSet@1.1529, 2007-06-20 09:18:36-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P53 + TAG: NTP_4_2_5P53 + + ntpd/ntpd-opts.c@1.40, 2007-06-20 09:18:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P53 + + ntpd/ntpd-opts.h@1.40, 2007-06-20 09:18:17-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P53 + + ntpd/ntpd-opts.texi@1.39, 2007-06-20 09:18:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P53 + + ntpd/ntpd.1@1.39, 2007-06-20 09:18:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P53 + + ntpdc/ntpdc-opts.c@1.40, 2007-06-20 09:18:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P53 + + ntpdc/ntpdc-opts.h@1.40, 2007-06-20 09:18:21-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P53 + + ntpdc/ntpdc-opts.texi@1.39, 2007-06-20 09:18:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P53 + + ntpdc/ntpdc.1@1.39, 2007-06-20 09:18:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P53 + + ntpq/ntpq-opts.c@1.40, 2007-06-20 09:18:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P53 + + ntpq/ntpq-opts.h@1.40, 2007-06-20 09:18:24-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P53 + + ntpq/ntpq-opts.texi@1.39, 2007-06-20 09:18:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P53 + + ntpq/ntpq.1@1.39, 2007-06-20 09:18:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P53 + + packageinfo.sh@1.56, 2007-06-20 09:18:26-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P53 + + sntp/sntp-opts.c@1.40, 2007-06-20 09:18:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P53 + + sntp/sntp-opts.h@1.40, 2007-06-20 09:18:28-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P53 + + sntp/sntp-opts.texi@1.39, 2007-06-20 09:18:29-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P53 + + sntp/sntp.1@1.39, 2007-06-20 09:18:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P53 + + util/ntp-keygen-opts.c@1.41, 2007-06-20 09:18:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P53 + + util/ntp-keygen-opts.h@1.41, 2007-06-20 09:18:30-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P53 + + util/ntp-keygen-opts.texi@1.40, 2007-06-20 09:18:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P53 + + util/ntp-keygen.1@1.40, 2007-06-20 09:18:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P53 + +ChangeSet@1.1436.1.59, 2007-06-20 07:45:57-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_4P2 + TAG: NTP_4_2_4P2 + + ntpd/ntpd-opts.c@1.50.8.1, 2007-06-20 07:45:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2 + + ntpd/ntpd-opts.h@1.50.8.1, 2007-06-20 07:45:33-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2 + + ntpd/ntpd-opts.texi@1.49.8.1, 2007-06-20 07:45:34-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P2 + + ntpd/ntpd.1@1.48.8.1, 2007-06-20 07:45:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2 + + ntpd/ntpdsim-opts.c@1.50.8.1, 2007-06-20 07:45:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2 + + ntpd/ntpdsim-opts.h@1.50.8.1, 2007-06-20 07:45:36-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2 + + ntpd/ntpdsim-opts.texi@1.48.8.1, 2007-06-20 07:45:37-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2 + + ntpd/ntpdsim.1@1.48.8.1, 2007-06-20 07:45:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2 + + ntpdc/ntpdc-opts.c@1.50.8.1, 2007-06-20 07:45:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2 + + ntpdc/ntpdc-opts.h@1.50.8.1, 2007-06-20 07:45:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2 + + ntpdc/ntpdc-opts.texi@1.48.8.1, 2007-06-20 07:45:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2 + + ntpdc/ntpdc.1@1.48.8.1, 2007-06-20 07:45:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2 + + ntpq/ntpq-opts.c@1.52.8.1, 2007-06-20 07:45:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2 + + ntpq/ntpq-opts.h@1.52.8.1, 2007-06-20 07:45:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2 + + ntpq/ntpq-opts.texi@1.49.8.1, 2007-06-20 07:45:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2 + + ntpq/ntpq.1@1.48.8.1, 2007-06-20 07:45:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2 + + packageinfo.sh@1.65.14.2, 2007-06-20 07:45:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2 + + sntp/sntp-opts.c@1.49.8.1, 2007-06-20 07:45:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2 + + sntp/sntp-opts.h@1.49.8.1, 2007-06-20 07:45:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2 + + sntp/sntp-opts.texi@1.46.8.1, 2007-06-20 07:45:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2 + + sntp/sntp.1@1.49.8.1, 2007-06-20 07:45:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2 + + util/ntp-keygen-opts.c@1.49.8.1, 2007-06-20 07:45:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2 + + util/ntp-keygen-opts.h@1.49.8.1, 2007-06-20 07:45:50-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2 + + util/ntp-keygen-opts.texi@1.47.8.1, 2007-06-20 07:45:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2 + + util/ntp-keygen.1@1.47.8.1, 2007-06-20 07:45:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2 + +ChangeSet@1.1436.1.58, 2007-06-20 04:07:34-04:00, stenn@deacon.udel.edu +3 -0 + 4.2.4p2 + + ChangeLog@1.1.1.19, 2007-06-20 04:07:25-04:00, stenn@deacon.udel.edu +1 -0 + 4.2.4p2 + + NEWS@1.86.1.8, 2007-06-20 04:07:25-04:00, stenn@deacon.udel.edu +8 -13 + 4.2.4p2 + + packageinfo.sh@1.65.14.1, 2007-06-20 04:07:26-04:00, stenn@deacon.udel.edu +1 -1 + 4.2.4p2 + +ChangeSet@1.1527, 2007-06-20 01:51:36-04:00, stenn@pogo.udel.edu +1 -0 + merge cleanup + + ntpd/ntp_util.c@1.51, 2007-06-20 01:51:24-04:00, stenn@pogo.udel.edu +1 -1 + merge cleanup + +ChangeSet@1.1523.2.2, 2007-06-19 18:55:53-04:00, stenn@whimsy.udel.edu +1 -0 + leap second cleanup from Dave Mills + + ChangeLog@1.71.1.1, 2007-06-19 18:55:44-04:00, stenn@whimsy.udel.edu +1 -0 + leap second cleanup from Dave Mills + +ChangeSet@1.1523.2.1, 2007-06-19 18:50:51-04:00, stenn@whimsy.udel.edu +5 -0 + leap second cleanup from Dave Mills + + include/ntpd.h@1.104, 2007-06-19 18:48:13-04:00, stenn@whimsy.udel.edu +0 -1 + leap second cleanup from Dave Mills + + ntpd/ntp_loopfilter.c@1.135, 2007-06-19 18:49:37-04:00, stenn@whimsy.udel.edu +13 -25 + leap second cleanup from Dave Mills + + ntpd/ntp_proto.c@1.254, 2007-06-19 18:49:38-04:00, stenn@whimsy.udel.edu +44 -19 + leap second cleanup from Dave Mills + + ntpd/ntp_timer.c@1.37, 2007-06-19 18:49:42-04:00, stenn@whimsy.udel.edu +12 -8 + leap second cleanup from Dave Mills + + ntpd/ntp_util.c@1.47.1.2, 2007-06-19 18:49:42-04:00, stenn@whimsy.udel.edu +51 -40 + leap second cleanup from Dave Mills + +ChangeSet@1.1519.1.1, 2007-06-19 08:37:26-04:00, mayer@pogo.udel.edu +2 -0 + Bug 629 Check for broadcast mode was in wrong place + + ntpd/ntp_io.c@1.253.1.1, 2007-06-19 08:35:52-04:00, mayer@pogo.udel.edu +35 -11 + Bug 629 Check for broadcast mode was in wrong place + + ports/winnt/ntpd/ntp_iocompletionport.c@1.28, 2007-06-19 08:36:52-04:00, mayer@pogo.udel.edu +8 -2 + Bug 629 Additional debug info + +ChangeSet@1.1525, 2007-06-19 03:13:46-04:00, stenn@pogo.udel.edu +1 -0 + regenerated ntp_parser.c + + ntpd/ntp_parser.c@1.13, 2007-06-19 03:13:33-04:00, stenn@pogo.udel.edu +504 -493 + regenerated file + +ChangeSet@1.1523, 2007-06-17 07:44:01-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P52 + TAG: NTP_4_2_5P52 + + ntpd/ntpd-opts.c@1.39, 2007-06-17 07:43:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P52 + + ntpd/ntpd-opts.h@1.39, 2007-06-17 07:43:42-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P52 + + ntpd/ntpd-opts.texi@1.38, 2007-06-17 07:43:43-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P52 + + ntpd/ntpd.1@1.38, 2007-06-17 07:43:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P52 + + ntpdc/ntpdc-opts.c@1.39, 2007-06-17 07:43:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P52 + + ntpdc/ntpdc-opts.h@1.39, 2007-06-17 07:43:45-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P52 + + ntpdc/ntpdc-opts.texi@1.38, 2007-06-17 07:43:46-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P52 + + ntpdc/ntpdc.1@1.38, 2007-06-17 07:43:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P52 + + ntpq/ntpq-opts.c@1.39, 2007-06-17 07:43:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P52 + + ntpq/ntpq-opts.h@1.39, 2007-06-17 07:43:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P52 + + ntpq/ntpq-opts.texi@1.38, 2007-06-17 07:43:49-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P52 + + ntpq/ntpq.1@1.38, 2007-06-17 07:43:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P52 + + packageinfo.sh@1.55, 2007-06-17 07:43:51-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P52 + + sntp/sntp-opts.c@1.39, 2007-06-17 07:43:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P52 + + sntp/sntp-opts.h@1.39, 2007-06-17 07:43:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P52 + + sntp/sntp-opts.texi@1.38, 2007-06-17 07:43:53-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P52 + + sntp/sntp.1@1.38, 2007-06-17 07:43:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P52 + + util/ntp-keygen-opts.c@1.40, 2007-06-17 07:43:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P52 + + util/ntp-keygen-opts.h@1.40, 2007-06-17 07:43:56-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P52 + + util/ntp-keygen-opts.texi@1.39, 2007-06-17 07:43:56-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P52 + + util/ntp-keygen.1@1.39, 2007-06-17 07:43:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P52 + +ChangeSet@1.1522, 2007-06-17 01:24:40-04:00, stenn@whimsy.udel.edu +5 -0 + Use YYERROR_VERBOSE for the new parser, and fix related BUILT_SOURCES + + ChangeLog@1.71, 2007-06-17 01:21:47-04:00, stenn@whimsy.udel.edu +1 -0 + Use YYERROR_VERBOSE for the new parser, and fix related BUILT_SOURCES + + ntpd/Makefile.am@1.62, 2007-06-17 01:22:00-04:00, stenn@whimsy.udel.edu +2 -1 + Use YYERROR_VERBOSE for the new parser, and fix related BUILT_SOURCES + + ntpd/ntp_parser.c@1.10.1.1, 2007-06-17 01:22:02-04:00, stenn@whimsy.udel.edu +1511 -1964 + Use YYERROR_VERBOSE for the new parser, and fix related BUILT_SOURCES + + ntpd/ntp_parser.h@1.3.1.1, 2007-06-17 01:22:04-04:00, stenn@whimsy.udel.edu +155 -345 + Use YYERROR_VERBOSE for the new parser, and fix related BUILT_SOURCES + + ntpd/ntp_parser.y@1.8.1.1, 2007-06-17 01:22:06-04:00, stenn@whimsy.udel.edu +2 -0 + Use YYERROR_VERBOSE for the new parser, and fix related BUILT_SOURCES + +ChangeSet@1.1521, 2007-06-16 07:44:30-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P51 + TAG: NTP_4_2_5P51 + + ntpd/ntpd-opts.c@1.38, 2007-06-16 07:44:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P51 + + ntpd/ntpd-opts.h@1.38, 2007-06-16 07:44:11-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P51 + + ntpd/ntpd-opts.texi@1.37, 2007-06-16 07:44:12-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P51 + + ntpd/ntpd.1@1.37, 2007-06-16 07:44:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P51 + + ntpdc/ntpdc-opts.c@1.38, 2007-06-16 07:44:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P51 + + ntpdc/ntpdc-opts.h@1.38, 2007-06-16 07:44:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P51 + + ntpdc/ntpdc-opts.texi@1.37, 2007-06-16 07:44:15-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P51 + + ntpdc/ntpdc.1@1.37, 2007-06-16 07:44:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P51 + + ntpq/ntpq-opts.c@1.38, 2007-06-16 07:44:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P51 + + ntpq/ntpq-opts.h@1.38, 2007-06-16 07:44:18-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P51 + + ntpq/ntpq-opts.texi@1.37, 2007-06-16 07:44:18-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P51 + + ntpq/ntpq.1@1.37, 2007-06-16 07:44:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P51 + + packageinfo.sh@1.54, 2007-06-16 07:44:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P51 + + sntp/sntp-opts.c@1.38, 2007-06-16 07:44:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P51 + + sntp/sntp-opts.h@1.38, 2007-06-16 07:44:21-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P51 + + sntp/sntp-opts.texi@1.37, 2007-06-16 07:44:22-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P51 + + sntp/sntp.1@1.37, 2007-06-16 07:44:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P51 + + util/ntp-keygen-opts.c@1.39, 2007-06-16 07:44:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P51 + + util/ntp-keygen-opts.h@1.39, 2007-06-16 07:44:25-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P51 + + util/ntp-keygen-opts.texi@1.38, 2007-06-16 07:44:25-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P51 + + util/ntp-keygen.1@1.38, 2007-06-16 07:44:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P51 + +ChangeSet@1.1520, 2007-06-15 19:36:46-04:00, stenn@deacon.udel.edu +1 -0 + typo + + ntpd/ntp_io.c@1.254, 2007-06-15 19:36:39-04:00, stenn@deacon.udel.edu +1 -1 + typo + +ChangeSet@1.1518, 2007-06-15 07:48:47-04:00, mayer@pogo.udel.edu +1 -0 + Remove unused variable + + ntpd/ntp_io.c@1.253, 2007-06-15 07:48:30-04:00, mayer@pogo.udel.edu +0 -1 + Remove unused variable + +ChangeSet@1.1512.1.15, 2007-06-15 07:42:58-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P50 + TAG: NTP_4_2_5P50 + + ntpd/ntpd-opts.c@1.37, 2007-06-15 07:42:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P50 + + ntpd/ntpd-opts.h@1.37, 2007-06-15 07:42:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P50 + + ntpd/ntpd-opts.texi@1.36, 2007-06-15 07:42:39-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P50 + + ntpd/ntpd.1@1.36, 2007-06-15 07:42:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P50 + + ntpdc/ntpdc-opts.c@1.37, 2007-06-15 07:42:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P50 + + ntpdc/ntpdc-opts.h@1.37, 2007-06-15 07:42:41-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P50 + + ntpdc/ntpdc-opts.texi@1.36, 2007-06-15 07:42:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P50 + + ntpdc/ntpdc.1@1.36, 2007-06-15 07:42:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P50 + + ntpq/ntpq-opts.c@1.37, 2007-06-15 07:42:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P50 + + ntpq/ntpq-opts.h@1.37, 2007-06-15 07:42:45-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P50 + + ntpq/ntpq-opts.texi@1.36, 2007-06-15 07:42:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P50 + + ntpq/ntpq.1@1.36, 2007-06-15 07:42:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P50 + + packageinfo.sh@1.53, 2007-06-15 07:42:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P50 + + sntp/sntp-opts.c@1.37, 2007-06-15 07:42:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P50 + + sntp/sntp-opts.h@1.37, 2007-06-15 07:42:48-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P50 + + sntp/sntp-opts.texi@1.36, 2007-06-15 07:42:49-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P50 + + sntp/sntp.1@1.36, 2007-06-15 07:42:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P50 + + util/ntp-keygen-opts.c@1.38, 2007-06-15 07:42:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P50 + + util/ntp-keygen-opts.h@1.38, 2007-06-15 07:42:51-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P50 + + util/ntp-keygen-opts.texi@1.37, 2007-06-15 07:42:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P50 + + util/ntp-keygen.1@1.37, 2007-06-15 07:42:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P50 + +ChangeSet@1.1517, 2007-06-14 23:22:06-04:00, mayer@pogo.udel.edu +1 -0 + Bug #629 changes to ensure broadcast works including on wildcard addresses + + ChangeLog@1.70, 2007-06-14 23:21:42-04:00, mayer@pogo.udel.edu +1 -0 + Bug #629 changes to ensure broadcast works including on wildcard addresses + +ChangeSet@1.1515, 2007-06-14 23:06:42-04:00, mayer@pogo.udel.edu +2 -0 + Bug #629 changes to ensure broadcast works including on wildcard addresses + + ntpd/ntp_io.c@1.252, 2007-06-14 23:05:45-04:00, mayer@pogo.udel.edu +22 -17 + Bug #629 changes to ensure broadcast works including on wildcard addresses + + ports/winnt/ntpd/ntp_iocompletionport.c@1.27, 2007-06-14 23:06:16-04:00, mayer@pogo.udel.edu +12 -3 + Bug #629 changes to ensure broadcast works including on wildcard addresses + +ChangeSet@1.1512.1.14, 2007-06-14 18:42:17-04:00, stenn@whimsy.udel.edu +3 -0 + [Bug 853] get_node() must return a pointer to maximally-aligned memory + + ChangeLog@1.69, 2007-06-14 18:41:59-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 853] get_node() must return a pointer to maximally-aligned memory + + include/ntp_data_structures.h@1.2, 2007-06-14 18:42:00-04:00, stenn@whimsy.udel.edu +5 -1 + [Bug 853] get_node() must return a pointer to maximally-aligned memory + + ntpd/ntp_data_structures.c@1.4, 2007-06-14 18:42:00-04:00, stenn@whimsy.udel.edu +7 -7 + [Bug 853] get_node() must return a pointer to maximally-aligned memory + +ChangeSet@1.1512.1.13, 2007-06-14 07:43:15-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P49 + TAG: NTP_4_2_5P49 + + ntpd/ntpd-opts.c@1.36, 2007-06-14 07:42:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P49 + + ntpd/ntpd-opts.h@1.36, 2007-06-14 07:42:59-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P49 + + ntpd/ntpd-opts.texi@1.35, 2007-06-14 07:43:00-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P49 + + ntpd/ntpd.1@1.35, 2007-06-14 07:43:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P49 + + ntpdc/ntpdc-opts.c@1.36, 2007-06-14 07:43:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P49 + + ntpdc/ntpdc-opts.h@1.36, 2007-06-14 07:43:02-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P49 + + ntpdc/ntpdc-opts.texi@1.35, 2007-06-14 07:43:02-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P49 + + ntpdc/ntpdc.1@1.35, 2007-06-14 07:43:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P49 + + ntpq/ntpq-opts.c@1.36, 2007-06-14 07:43:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P49 + + ntpq/ntpq-opts.h@1.36, 2007-06-14 07:43:05-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P49 + + ntpq/ntpq-opts.texi@1.35, 2007-06-14 07:43:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P49 + + ntpq/ntpq.1@1.35, 2007-06-14 07:43:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P49 + + packageinfo.sh@1.52, 2007-06-14 07:43:07-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P49 + + sntp/sntp-opts.c@1.36, 2007-06-14 07:43:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P49 + + sntp/sntp-opts.h@1.36, 2007-06-14 07:43:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P49 + + sntp/sntp-opts.texi@1.35, 2007-06-14 07:43:08-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P49 + + sntp/sntp.1@1.35, 2007-06-14 07:43:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P49 + + util/ntp-keygen-opts.c@1.37, 2007-06-14 07:43:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P49 + + util/ntp-keygen-opts.h@1.37, 2007-06-14 07:43:10-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P49 + + util/ntp-keygen-opts.texi@1.36, 2007-06-14 07:43:11-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P49 + + util/ntp-keygen.1@1.36, 2007-06-14 07:43:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P49 + +ChangeSet@1.1512.1.12, 2007-06-14 01:40:14-04:00, stenn@whimsy.udel.edu +5 -0 + Leap file fixes from Dave Mills + + ChangeLog@1.68, 2007-06-14 01:39:42-04:00, stenn@whimsy.udel.edu +1 -0 + Leap file fixes from Dave Mills + + include/ntpd.h@1.103, 2007-06-14 01:39:44-04:00, stenn@whimsy.udel.edu +3 -1 + Leap file fixes from Dave Mills + + ntpd/ntp_proto.c@1.253, 2007-06-14 01:38:55-04:00, stenn@whimsy.udel.edu +35 -12 + Leap file fixes from Dave Mills + + ntpd/ntp_timer.c@1.36, 2007-06-14 01:38:57-04:00, stenn@whimsy.udel.edu +9 -2 + Leap file fixes from Dave Mills + + ntpd/ntp_util.c@1.47.1.1, 2007-06-14 01:38:58-04:00, stenn@whimsy.udel.edu +52 -2 + Leap file fixes from Dave Mills + +ChangeSet@1.1512.3.1, 2007-06-12 18:03:45-04:00, neal@pogo.udel.edu +7 -0 + Many files: + allow null driftfile. + + ChangeLog@1.66.1.1, 2007-06-12 18:03:21-04:00, neal@pogo.udel.edu +1 -0 + allow null driftfile. + + ntpd/ntp_config.c@1.156, 2007-06-12 17:59:35-04:00, neal@pogo.udel.edu +10 -2 + allow null driftfile. + + ntpd/ntp_parser.c@1.11, 2007-06-12 18:00:48-04:00, neal@pogo.udel.edu +507 -509 + allow null driftfile. + + ntpd/ntp_parser.h@1.4, 2007-06-12 18:00:58-04:00, neal@pogo.udel.edu +1 -1 + allow null driftfile. + + ntpd/ntp_parser.y@1.9, 2007-06-12 18:01:08-04:00, neal@pogo.udel.edu +16 -9 + allow null driftfile. + + ntpd/ntp_scanner.c@1.8, 2007-06-12 18:01:18-04:00, neal@pogo.udel.edu +10 -6 + allow null driftfile. + + ntpd/ntp_util.c@1.48, 2007-06-12 18:01:28-04:00, neal@pogo.udel.edu +1 -1 + allow null driftfile. + +ChangeSet@1.1512.1.11, 2007-06-12 08:00:26-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P48 + TAG: NTP_4_2_5P48 + + ntpd/ntpd-opts.c@1.35, 2007-06-12 08:00:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P48 + + ntpd/ntpd-opts.h@1.35, 2007-06-12 08:00:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P48 + + ntpd/ntpd-opts.texi@1.34, 2007-06-12 08:00:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P48 + + ntpd/ntpd.1@1.34, 2007-06-12 08:00:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P48 + + ntpdc/ntpdc-opts.c@1.35, 2007-06-12 08:00:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P48 + + ntpdc/ntpdc-opts.h@1.35, 2007-06-12 08:00:11-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P48 + + ntpdc/ntpdc-opts.texi@1.34, 2007-06-12 08:00:12-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P48 + + ntpdc/ntpdc.1@1.34, 2007-06-12 08:00:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P48 + + ntpq/ntpq-opts.c@1.35, 2007-06-12 08:00:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P48 + + ntpq/ntpq-opts.h@1.35, 2007-06-12 08:00:13-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P48 + + ntpq/ntpq-opts.texi@1.34, 2007-06-12 08:00:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P48 + + ntpq/ntpq.1@1.34, 2007-06-12 08:00:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P48 + + packageinfo.sh@1.51, 2007-06-12 08:00:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P48 + + sntp/sntp-opts.c@1.35, 2007-06-12 08:00:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P48 + + sntp/sntp-opts.h@1.35, 2007-06-12 08:00:18-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P48 + + sntp/sntp-opts.texi@1.34, 2007-06-12 08:00:18-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P48 + + sntp/sntp.1@1.34, 2007-06-12 08:00:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P48 + + util/ntp-keygen-opts.c@1.36, 2007-06-12 08:00:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P48 + + util/ntp-keygen-opts.h@1.36, 2007-06-12 08:00:20-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P48 + + util/ntp-keygen-opts.texi@1.35, 2007-06-12 08:00:21-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P48 + + util/ntp-keygen.1@1.35, 2007-06-12 08:00:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P48 + +ChangeSet@1.1512.1.10, 2007-06-11 20:40:23-04:00, stenn@deacon.udel.edu +3 -0 + [Bug 858] Recent leapfile changes broke without OPENSSL + + ChangeLog@1.67, 2007-06-11 20:40:15-04:00, stenn@deacon.udel.edu +1 -0 + [Bug 858] Recent leapfile changes broke without OPENSSL + + include/ntp_crypto.h@1.39, 2007-06-11 20:40:15-04:00, stenn@deacon.udel.edu +1 -2 + [Bug 858] Recent leapfile changes broke without OPENSSL + + include/ntpd.h@1.102, 2007-06-11 20:40:15-04:00, stenn@deacon.udel.edu +4 -2 + [Bug 858] Recent leapfile changes broke without OPENSSL + +ChangeSet@1.1512.1.9, 2007-06-10 10:00:31-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P47 + TAG: NTP_4_2_5P47 + + ntpd/ntpd-opts.c@1.34, 2007-06-10 10:00:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P47 + + ntpd/ntpd-opts.h@1.34, 2007-06-10 10:00:13-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P47 + + ntpd/ntpd-opts.texi@1.33, 2007-06-10 10:00:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P47 + + ntpd/ntpd.1@1.33, 2007-06-10 10:00:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P47 + + ntpdc/ntpdc-opts.c@1.34, 2007-06-10 10:00:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P47 + + ntpdc/ntpdc-opts.h@1.34, 2007-06-10 10:00:16-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P47 + + ntpdc/ntpdc-opts.texi@1.33, 2007-06-10 10:00:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P47 + + ntpdc/ntpdc.1@1.33, 2007-06-10 10:00:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P47 + + ntpq/ntpq-opts.c@1.34, 2007-06-10 10:00:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P47 + + ntpq/ntpq-opts.h@1.34, 2007-06-10 10:00:18-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P47 + + ntpq/ntpq-opts.texi@1.33, 2007-06-10 10:00:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P47 + + ntpq/ntpq.1@1.33, 2007-06-10 10:00:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P47 + + packageinfo.sh@1.50, 2007-06-10 10:00:22-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P47 + + sntp/sntp-opts.c@1.34, 2007-06-10 10:00:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P47 + + sntp/sntp-opts.h@1.34, 2007-06-10 10:00:23-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P47 + + sntp/sntp-opts.texi@1.33, 2007-06-10 10:00:24-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P47 + + sntp/sntp.1@1.33, 2007-06-10 10:00:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P47 + + util/ntp-keygen-opts.c@1.35, 2007-06-10 10:00:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P47 + + util/ntp-keygen-opts.h@1.35, 2007-06-10 10:00:26-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P47 + + util/ntp-keygen-opts.texi@1.34, 2007-06-10 10:00:26-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P47 + + util/ntp-keygen.1@1.34, 2007-06-10 10:00:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P47 + +ChangeSet@1.1436.1.57, 2007-06-10 07:58:59-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_4P2_RC6 + TAG: NTP_4_2_4P2_RC6 + + ntpd/ntpd-opts.c@1.50.7.1, 2007-06-10 07:58:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC6 + + ntpd/ntpd-opts.h@1.50.7.1, 2007-06-10 07:58:37-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC6 + + ntpd/ntpd-opts.texi@1.49.7.1, 2007-06-10 07:58:38-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC6 + + ntpd/ntpd.1@1.48.7.1, 2007-06-10 07:58:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC6 + + ntpd/ntpdsim-opts.c@1.50.7.1, 2007-06-10 07:58:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC6 + + ntpd/ntpdsim-opts.h@1.50.7.1, 2007-06-10 07:58:41-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC6 + + ntpd/ntpdsim-opts.texi@1.48.7.1, 2007-06-10 07:58:41-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC6 + + ntpd/ntpdsim.1@1.48.7.1, 2007-06-10 07:58:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC6 + + ntpdc/ntpdc-opts.c@1.50.7.1, 2007-06-10 07:58:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC6 + + ntpdc/ntpdc-opts.h@1.50.7.1, 2007-06-10 07:58:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC6 + + ntpdc/ntpdc-opts.texi@1.48.7.1, 2007-06-10 07:58:44-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC6 + + ntpdc/ntpdc.1@1.48.7.1, 2007-06-10 07:58:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC6 + + ntpq/ntpq-opts.c@1.52.7.1, 2007-06-10 07:58:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC6 + + ntpq/ntpq-opts.h@1.52.7.1, 2007-06-10 07:58:46-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC6 + + ntpq/ntpq-opts.texi@1.49.7.1, 2007-06-10 07:58:46-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC6 + + ntpq/ntpq.1@1.48.7.1, 2007-06-10 07:58:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC6 + + packageinfo.sh@1.65.13.1, 2007-06-10 07:58:48-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC6 + + sntp/sntp-opts.c@1.49.7.1, 2007-06-10 07:58:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC6 + + sntp/sntp-opts.h@1.49.7.1, 2007-06-10 07:58:50-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC6 + + sntp/sntp-opts.texi@1.46.7.1, 2007-06-10 07:58:50-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC6 + + sntp/sntp.1@1.49.7.1, 2007-06-10 07:58:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC6 + + util/ntp-keygen-opts.c@1.49.7.1, 2007-06-10 07:58:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC6 + + util/ntp-keygen-opts.h@1.49.7.1, 2007-06-10 07:58:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC6 + + util/ntp-keygen-opts.texi@1.47.7.1, 2007-06-10 07:58:53-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC6 + + util/ntp-keygen.1@1.47.7.1, 2007-06-10 07:58:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC6 + +ChangeSet@1.1512.1.8, 2007-06-10 03:26:26-04:00, stenn@deacon.udel.edu +8 -0 + ntp_dir_sep.m4, config.h: + Use a char for DIR_SEP, not a string + ntp_util.c, ntp_loopfilter.c, ntpd.h, ntp.h, ntp_timer.c, ChangeLog: + leap file improvements from Dave Mills. + + ChangeLog@1.66, 2007-06-10 03:25:11-04:00, stenn@deacon.udel.edu +1 -0 + leap file improvements from Dave Mills. + + include/ntp.h@1.132, 2007-06-10 03:24:37-04:00, stenn@deacon.udel.edu +1 -0 + leap file improvements from Dave Mills. + + include/ntpd.h@1.101, 2007-06-10 03:24:38-04:00, stenn@deacon.udel.edu +2 -1 + leap file improvements from Dave Mills. + + m4/ntp_dir_sep.m4@1.2, 2007-06-10 03:25:56-04:00, stenn@deacon.udel.edu +3 -3 + Use a char for DIR_SEP, not a string + + ntpd/ntp_loopfilter.c@1.134, 2007-06-10 03:24:26-04:00, stenn@deacon.udel.edu +13 -37 + leap file improvements from Dave Mills. + + ntpd/ntp_timer.c@1.35, 2007-06-10 03:24:26-04:00, stenn@deacon.udel.edu +6 -0 + leap file improvements from Dave Mills. + + ntpd/ntp_util.c@1.47, 2007-06-10 03:24:26-04:00, stenn@deacon.udel.edu +138 -45 + leap file improvements from Dave Mills. + + ports/winnt/include/config.h@1.50, 2007-06-10 03:25:56-04:00, stenn@deacon.udel.edu +1 -1 + Use a char for DIR_SEP, not a string + +ChangeSet@1.1512.2.1, 2007-06-07 15:57:08-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P46 + TAG: NTP_4_2_5P46 + + ntpd/ntpd-opts.c@1.33, 2007-06-07 15:56:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P46 + + ntpd/ntpd-opts.h@1.33, 2007-06-07 15:56:50-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P46 + + ntpd/ntpd-opts.texi@1.32, 2007-06-07 15:56:50-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P46 + + ntpd/ntpd.1@1.32, 2007-06-07 15:56:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P46 + + ntpdc/ntpdc-opts.c@1.33, 2007-06-07 15:56:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P46 + + ntpdc/ntpdc-opts.h@1.33, 2007-06-07 15:56:53-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P46 + + ntpdc/ntpdc-opts.texi@1.32, 2007-06-07 15:56:54-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P46 + + ntpdc/ntpdc.1@1.32, 2007-06-07 15:56:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P46 + + ntpq/ntpq-opts.c@1.33, 2007-06-07 15:56:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P46 + + ntpq/ntpq-opts.h@1.33, 2007-06-07 15:56:56-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P46 + + ntpq/ntpq-opts.texi@1.32, 2007-06-07 15:56:57-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P46 + + ntpq/ntpq.1@1.32, 2007-06-07 15:56:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P46 + + packageinfo.sh@1.49, 2007-06-07 15:56:59-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P46 + + sntp/sntp-opts.c@1.33, 2007-06-07 15:56:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P46 + + sntp/sntp-opts.h@1.33, 2007-06-07 15:57:00-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P46 + + sntp/sntp-opts.texi@1.32, 2007-06-07 15:57:01-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P46 + + sntp/sntp.1@1.32, 2007-06-07 15:57:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P46 + + util/ntp-keygen-opts.c@1.34, 2007-06-07 15:57:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P46 + + util/ntp-keygen-opts.h@1.34, 2007-06-07 15:57:03-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P46 + + util/ntp-keygen-opts.texi@1.33, 2007-06-07 15:57:03-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P46 + + util/ntp-keygen.1@1.33, 2007-06-07 15:57:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P46 + +ChangeSet@1.1512.1.5, 2007-06-07 10:48:26-04:00, neal@pogo.udel.edu +5 -0 + ntp_parser.y, ntp_parser.h, ntp_parser.c, ChangeLog, ntp_config.c: + [Bug 850] driftfile parsing changes. + + ChangeLog@1.64, 2007-06-07 10:44:11-04:00, neal@pogo.udel.edu +1 -0 + [Bug 850] driftfile parsing changes. + + ntpd/ntp_config.c@1.155, 2007-06-07 10:44:57-04:00, neal@pogo.udel.edu +3 -0 + [Bug 850] driftfile parsing changes. + + ntpd/ntp_parser.c@1.10, 2007-06-07 10:45:14-04:00, neal@pogo.udel.edu +2040 -1569 + [Bug 850] driftfile parsing changes. + + ntpd/ntp_parser.h@1.3, 2007-06-07 10:45:39-04:00, neal@pogo.udel.edu +345 -154 + [Bug 850] driftfile parsing changes. + + ntpd/ntp_parser.y@1.8, 2007-06-07 10:45:55-04:00, neal@pogo.udel.edu +9 -2 + [Bug 850] driftfile parsing changes. + +ChangeSet@1.1436.1.56, 2007-06-07 09:28:16-04:00, mayer@pogo.udel.edu +1 -0 + Bug #854 Broadcast address was not correctly set for interface addresses + + ChangeLog@1.1.1.18, 2007-06-07 09:28:05-04:00, mayer@pogo.udel.edu +1 -0 + Bug #854 Broadcast address was not correctly set for interface addresses + +ChangeSet@1.1436.1.55, 2007-06-07 09:25:17-04:00, mayer@pogo.udel.edu +1 -0 + Bug #854 Broadcast address was not correctly set for interface addresses + + ports/winnt/libisc/interfaceiter.c@1.7, 2007-06-07 09:24:57-04:00, mayer@pogo.udel.edu +35 -13 + Bug #854 Broadcast address was not correctly set for interface addresses + +ChangeSet@1.1512.1.4, 2007-06-07 06:40:49-04:00, stenn@deacon.udel.edu +3 -0 + driftfile maintenance changes from Dave Mills. Use clock_phi instead of stats_write_tolerance + + ChangeLog@1.63, 2007-06-07 06:40:43-04:00, stenn@deacon.udel.edu +2 -0 + driftfile maintenance changes from Dave Mills. Use clock_phi instead of stats_write_tolerance + + ntpd/ntp_util.c@1.46, 2007-06-07 06:39:53-04:00, stenn@deacon.udel.edu +8 -15 + driftfile maintenance changes from Dave Mills. Use clock_phi instead of stats_write_tolerance + + ntpd/ntpd.c@1.87, 2007-06-07 06:39:53-04:00, stenn@deacon.udel.edu +1 -1 + driftfile maintenance changes from Dave Mills. Use clock_phi instead of stats_write_tolerance + +ChangeSet@1.1512.1.3, 2007-06-07 01:49:17-04:00, stenn@deacon.udel.edu +1 -0 + IRIG refclock improvements from Dave Mills + + ntpd/refclock_irig.c@1.31, 2007-06-07 01:46:42-04:00, stenn@deacon.udel.edu +55 -65 + IRIG refclock improvements from Dave Mills + +ChangeSet@1.1512.1.2, 2007-06-05 07:45:25-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P45 + TAG: NTP_4_2_5P45 + + ntpd/ntpd-opts.c@1.32, 2007-06-05 07:45:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P45 + + ntpd/ntpd-opts.h@1.32, 2007-06-05 07:45:07-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P45 + + ntpd/ntpd-opts.texi@1.31, 2007-06-05 07:45:07-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P45 + + ntpd/ntpd.1@1.31, 2007-06-05 07:45:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P45 + + ntpdc/ntpdc-opts.c@1.32, 2007-06-05 07:45:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P45 + + ntpdc/ntpdc-opts.h@1.32, 2007-06-05 07:45:10-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P45 + + ntpdc/ntpdc-opts.texi@1.31, 2007-06-05 07:45:10-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P45 + + ntpdc/ntpdc.1@1.31, 2007-06-05 07:45:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P45 + + ntpq/ntpq-opts.c@1.32, 2007-06-05 07:45:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P45 + + ntpq/ntpq-opts.h@1.32, 2007-06-05 07:45:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P45 + + ntpq/ntpq-opts.texi@1.31, 2007-06-05 07:45:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P45 + + ntpq/ntpq.1@1.31, 2007-06-05 07:45:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P45 + + packageinfo.sh@1.48, 2007-06-05 07:45:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P45 + + sntp/sntp-opts.c@1.32, 2007-06-05 07:45:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P45 + + sntp/sntp-opts.h@1.32, 2007-06-05 07:45:15-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P45 + + sntp/sntp-opts.texi@1.31, 2007-06-05 07:45:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P45 + + sntp/sntp.1@1.31, 2007-06-05 07:45:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P45 + + util/ntp-keygen-opts.c@1.33, 2007-06-05 07:45:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P45 + + util/ntp-keygen-opts.h@1.33, 2007-06-05 07:45:19-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P45 + + util/ntp-keygen-opts.texi@1.32, 2007-06-05 07:45:20-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P45 + + util/ntp-keygen.1@1.32, 2007-06-05 07:45:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P45 + +ChangeSet@1.1512.1.1, 2007-06-05 02:28:01-04:00, stenn@whimsy.udel.edu +1 -0 + indentation cleanup + + ntpd/ntp_config.c@1.154, 2007-06-05 02:27:14-04:00, stenn@whimsy.udel.edu +1676 -1559 + indentation cleanup + +ChangeSet@1.1495.1.1, 2007-06-02 18:30:39-04:00, mayer@pogo.udel.edu +5 -0 + Bug #629 Allow certain broadcast packets to be received on the wildcard socket + + include/ntp_io.h@1.6, 2007-06-02 18:28:47-04:00, mayer@pogo.udel.edu +3 -0 + Bug #629 Allow certain broadcast packets to be received on the wildcard socket + + include/ntp_request.h@1.32, 2007-06-02 18:28:47-04:00, mayer@pogo.udel.edu +7 -0 + Bug #629 Allow certain broadcast packets to be received on the wildcard socket + + ntpd/ntp_io.c@1.249.1.1, 2007-06-02 18:28:46-04:00, mayer@pogo.udel.edu +27 -2 + Bug #629 Allow certain broadcast packets to be received on the wildcard socket + + ntpd/ntp_request.c@1.68, 2007-06-02 18:28:46-04:00, mayer@pogo.udel.edu +9 -0 + Bug #629 Allow certain broadcast packets to be received on the wildcard socket + + ports/winnt/ntpd/ntp_iocompletionport.c@1.26, 2007-06-02 18:28:47-04:00, mayer@pogo.udel.edu +20 -2 + Bug #629 Allow certain broadcast packets to be received on the wildcard socket + +ChangeSet@1.1512, 2007-06-02 07:44:39-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P44 + TAG: NTP_4_2_5P44 + + ntpd/ntpd-opts.c@1.31, 2007-06-02 07:44:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P44 + + ntpd/ntpd-opts.h@1.31, 2007-06-02 07:44:22-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P44 + + ntpd/ntpd-opts.texi@1.30, 2007-06-02 07:44:23-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P44 + + ntpd/ntpd.1@1.30, 2007-06-02 07:44:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P44 + + ntpdc/ntpdc-opts.c@1.31, 2007-06-02 07:44:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P44 + + ntpdc/ntpdc-opts.h@1.31, 2007-06-02 07:44:24-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P44 + + ntpdc/ntpdc-opts.texi@1.30, 2007-06-02 07:44:25-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P44 + + ntpdc/ntpdc.1@1.30, 2007-06-02 07:44:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P44 + + ntpq/ntpq-opts.c@1.31, 2007-06-02 07:44:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P44 + + ntpq/ntpq-opts.h@1.31, 2007-06-02 07:44:27-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P44 + + ntpq/ntpq-opts.texi@1.30, 2007-06-02 07:44:28-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P44 + + ntpq/ntpq.1@1.30, 2007-06-02 07:44:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P44 + + packageinfo.sh@1.47, 2007-06-02 07:44:30-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P44 + + sntp/sntp-opts.c@1.31, 2007-06-02 07:44:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P44 + + sntp/sntp-opts.h@1.31, 2007-06-02 07:44:31-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P44 + + sntp/sntp-opts.texi@1.30, 2007-06-02 07:44:31-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P44 + + sntp/sntp.1@1.30, 2007-06-02 07:44:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P44 + + util/ntp-keygen-opts.c@1.32, 2007-06-02 07:44:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P44 + + util/ntp-keygen-opts.h@1.32, 2007-06-02 07:44:34-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P44 + + util/ntp-keygen-opts.texi@1.31, 2007-06-02 07:44:34-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P44 + + util/ntp-keygen.1@1.31, 2007-06-02 07:44:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P44 + +ChangeSet@1.1511, 2007-06-02 00:27:35-04:00, stenn@whimsy.udel.edu +1 -0 + Updated from the recent change to ntp_parser.y + + ntpd/ntp_parser.c@1.9, 2007-06-02 00:27:23-04:00, stenn@whimsy.udel.edu +196 -182 + Updated from the recent change to ntp_parser.y + +ChangeSet@1.1510, 2007-06-01 18:30:18-04:00, neal@pogo.udel.edu +2 -0 + ntp_scanner.c, ChangeLog: + [Bug 828] refid not being parsed correctly. + + ChangeLog@1.62, 2007-06-01 18:27:30-04:00, neal@pogo.udel.edu +1 -0 + [Bug 828] refid not being parsed correctly. + + ntpd/ntp_scanner.c@1.7, 2007-06-01 18:26:56-04:00, neal@pogo.udel.edu +8 -6 + [Bug 828] refid not being parsed correctly. + +ChangeSet@1.1506.1.2, 2007-06-01 08:13:55-04:00, neal@pogo.udel.edu +1 -0 + commit to correct bk merge problems. + + ChangeLog@1.59.1.2, 2007-06-01 08:12:49-04:00, neal@pogo.udel.edu +1 -0 + +ChangeSet@1.1506.1.1, 2007-06-01 07:52:58-04:00, neal@pogo.udel.edu +3 -0 + ntp_parser.y, ntp_scanner.c, ChangeLog: + [Bug 846] Correct includefile parsing. + + ChangeLog@1.59.1.1, 2007-06-01 07:50:05-04:00, neal@pogo.udel.edu +1 -0 + [Bug 846] Correct includefile parsing. + + ntpd/ntp_parser.y@1.7, 2007-06-01 07:51:22-04:00, neal@pogo.udel.edu +2 -2 + [Bug 846] Correct includefile parsing. + + ntpd/ntp_scanner.c@1.6, 2007-06-01 07:51:45-04:00, neal@pogo.udel.edu +7 -2 + [Bug 846] Correct includefile parsing. + +ChangeSet@1.1508, 2007-06-01 07:44:04-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P43 + TAG: NTP_4_2_5P43 + + ntpd/ntpd-opts.c@1.30, 2007-06-01 07:43:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P43 + + ntpd/ntpd-opts.h@1.30, 2007-06-01 07:43:46-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P43 + + ntpd/ntpd-opts.texi@1.29, 2007-06-01 07:43:46-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P43 + + ntpd/ntpd.1@1.29, 2007-06-01 07:43:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P43 + + ntpdc/ntpdc-opts.c@1.30, 2007-06-01 07:43:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P43 + + ntpdc/ntpdc-opts.h@1.30, 2007-06-01 07:43:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P43 + + ntpdc/ntpdc-opts.texi@1.29, 2007-06-01 07:43:49-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P43 + + ntpdc/ntpdc.1@1.29, 2007-06-01 07:43:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P43 + + ntpq/ntpq-opts.c@1.30, 2007-06-01 07:43:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P43 + + ntpq/ntpq-opts.h@1.30, 2007-06-01 07:43:51-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P43 + + ntpq/ntpq-opts.texi@1.29, 2007-06-01 07:43:52-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P43 + + ntpq/ntpq.1@1.29, 2007-06-01 07:43:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P43 + + packageinfo.sh@1.46, 2007-06-01 07:43:53-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P43 + + sntp/sntp-opts.c@1.30, 2007-06-01 07:43:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P43 + + sntp/sntp-opts.h@1.30, 2007-06-01 07:43:54-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P43 + + sntp/sntp-opts.texi@1.29, 2007-06-01 07:43:55-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P43 + + sntp/sntp.1@1.29, 2007-06-01 07:43:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P43 + + util/ntp-keygen-opts.c@1.31, 2007-06-01 07:43:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P43 + + util/ntp-keygen-opts.h@1.31, 2007-06-01 07:43:58-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P43 + + util/ntp-keygen-opts.texi@1.30, 2007-06-01 07:43:58-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P43 + + util/ntp-keygen.1@1.30, 2007-06-01 07:43:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P43 + +ChangeSet@1.1507, 2007-06-01 02:17:28-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 827] New parsing code does not handle "fudge" correctly + + ChangeLog@1.60, 2007-06-01 02:17:17-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 827] New parsing code does not handle "fudge" correctly + +ChangeSet@1.1506, 2007-05-31 07:47:43-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P42 + TAG: NTP_4_2_5P42 + + ntpd/ntpd-opts.c@1.29, 2007-05-31 07:47:26-04:00, stenn@whimsy.udel.edu +4 -5 + NTP_4_2_5P42 + + ntpd/ntpd-opts.h@1.29, 2007-05-31 07:47:26-04:00, stenn@whimsy.udel.edu +5 -6 + NTP_4_2_5P42 + + ntpd/ntpd-opts.texi@1.28, 2007-05-31 07:47:27-04:00, stenn@whimsy.udel.edu +2 -3 + NTP_4_2_5P42 + + ntpd/ntpd.1@1.28, 2007-05-31 07:47:28-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P42 + + ntpdc/ntpdc-opts.c@1.29, 2007-05-31 07:47:28-04:00, stenn@whimsy.udel.edu +4 -5 + NTP_4_2_5P42 + + ntpdc/ntpdc-opts.h@1.29, 2007-05-31 07:47:29-04:00, stenn@whimsy.udel.edu +5 -6 + NTP_4_2_5P42 + + ntpdc/ntpdc-opts.texi@1.28, 2007-05-31 07:47:30-04:00, stenn@whimsy.udel.edu +2 -3 + NTP_4_2_5P42 + + ntpdc/ntpdc.1@1.28, 2007-05-31 07:47:31-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P42 + + ntpq/ntpq-opts.c@1.29, 2007-05-31 07:47:32-04:00, stenn@whimsy.udel.edu +4 -5 + NTP_4_2_5P42 + + ntpq/ntpq-opts.h@1.29, 2007-05-31 07:47:32-04:00, stenn@whimsy.udel.edu +5 -6 + NTP_4_2_5P42 + + ntpq/ntpq-opts.texi@1.28, 2007-05-31 07:47:32-04:00, stenn@whimsy.udel.edu +2 -3 + NTP_4_2_5P42 + + ntpq/ntpq.1@1.28, 2007-05-31 07:47:33-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P42 + + packageinfo.sh@1.45, 2007-05-31 07:47:34-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P42 + + sntp/sntp-opts.c@1.29, 2007-05-31 07:47:34-04:00, stenn@whimsy.udel.edu +4 -5 + NTP_4_2_5P42 + + sntp/sntp-opts.h@1.29, 2007-05-31 07:47:35-04:00, stenn@whimsy.udel.edu +5 -6 + NTP_4_2_5P42 + + sntp/sntp-opts.texi@1.28, 2007-05-31 07:47:36-04:00, stenn@whimsy.udel.edu +2 -3 + NTP_4_2_5P42 + + sntp/sntp.1@1.28, 2007-05-31 07:47:36-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P42 + + util/ntp-keygen-opts.c@1.30, 2007-05-31 07:47:38-04:00, stenn@whimsy.udel.edu +4 -5 + NTP_4_2_5P42 + + util/ntp-keygen-opts.h@1.30, 2007-05-31 07:47:38-04:00, stenn@whimsy.udel.edu +5 -6 + NTP_4_2_5P42 + + util/ntp-keygen-opts.texi@1.29, 2007-05-31 07:47:39-04:00, stenn@whimsy.udel.edu +2 -3 + NTP_4_2_5P42 + + util/ntp-keygen.1@1.29, 2007-05-31 07:47:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P42 + +ChangeSet@1.1505, 2007-05-31 01:32:15-04:00, stenn@whimsy.udel.edu +3 -0 + Enable debugging capability in the config parser. + + ChangeLog@1.59, 2007-05-31 01:31:53-04:00, stenn@whimsy.udel.edu +1 -0 + Enable debugging capability in the config parser. + + ntpd/Makefile.am@1.61, 2007-05-31 01:31:54-04:00, stenn@whimsy.udel.edu +1 -1 + Enable debugging capability in the config parser. + + ntpd/ntp_parser.c@1.8, 2007-05-31 01:31:54-04:00, stenn@whimsy.udel.edu +1 -1 + Enable debugging capability in the config parser. + +ChangeSet@1.1504, 2007-05-30 22:54:36-04:00, stenn@whimsy.udel.edu +3 -0 + [Bug 839] Crypto password not read from ntp.conf + + ChangeLog@1.58, 2007-05-30 22:54:18-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 839] Crypto password not read from ntp.conf + + ntpd/ntp_parser.c@1.7, 2007-05-30 22:54:19-04:00, stenn@whimsy.udel.edu +198 -194 + [Bug 839] Crypto password not read from ntp.conf + + ntpd/ntp_parser.y@1.6, 2007-05-30 22:54:20-04:00, stenn@whimsy.udel.edu +5 -1 + [Bug 839] Crypto password not read from ntp.conf + +ChangeSet@1.1503, 2007-05-30 22:44:11-04:00, stenn@whimsy.udel.edu +6 -0 + Have autogen produce writable output files + + ChangeLog@1.57, 2007-05-30 22:44:02-04:00, stenn@whimsy.udel.edu +1 -0 + Have autogen produce writable output files + + ntpd/Makefile.am@1.60, 2007-05-30 22:35:13-04:00, stenn@whimsy.udel.edu +1 -1 + Have autogen produce writable output files + + ntpdc/Makefile.am@1.36, 2007-05-30 22:35:13-04:00, stenn@whimsy.udel.edu +1 -1 + Have autogen produce writable output files + + ntpq/Makefile.am@1.28, 2007-05-30 22:35:14-04:00, stenn@whimsy.udel.edu +1 -1 + Have autogen produce writable output files + + sntp/Makefile.am@1.22, 2007-05-30 22:35:14-04:00, stenn@whimsy.udel.edu +2 -2 + Have autogen produce writable output files + + util/Makefile.am@1.37, 2007-05-30 22:35:15-04:00, stenn@whimsy.udel.edu +1 -1 + Have autogen produce writable output files + +ChangeSet@1.1501, 2007-05-30 07:45:27-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P41 + TAG: NTP_4_2_5P41 + + ntpd/ntpd-opts.c@1.28, 2007-05-30 07:45:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P41 + + ntpd/ntpd-opts.h@1.28, 2007-05-30 07:45:10-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P41 + + ntpd/ntpd-opts.texi@1.27, 2007-05-30 07:45:11-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P41 + + ntpd/ntpd.1@1.27, 2007-05-30 07:45:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P41 + + ntpdc/ntpdc-opts.c@1.28, 2007-05-30 07:45:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P41 + + ntpdc/ntpdc-opts.h@1.28, 2007-05-30 07:45:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P41 + + ntpdc/ntpdc-opts.texi@1.27, 2007-05-30 07:45:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P41 + + ntpdc/ntpdc.1@1.27, 2007-05-30 07:45:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P41 + + ntpq/ntpq-opts.c@1.28, 2007-05-30 07:45:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P41 + + ntpq/ntpq-opts.h@1.28, 2007-05-30 07:45:15-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P41 + + ntpq/ntpq-opts.texi@1.27, 2007-05-30 07:45:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P41 + + ntpq/ntpq.1@1.27, 2007-05-30 07:45:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P41 + + packageinfo.sh@1.44, 2007-05-30 07:45:18-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P41 + + sntp/sntp-opts.c@1.28, 2007-05-30 07:45:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P41 + + sntp/sntp-opts.h@1.28, 2007-05-30 07:45:19-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P41 + + sntp/sntp-opts.texi@1.27, 2007-05-30 07:45:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P41 + + sntp/sntp.1@1.27, 2007-05-30 07:45:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P41 + + util/ntp-keygen-opts.c@1.29, 2007-05-30 07:45:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P41 + + util/ntp-keygen-opts.h@1.29, 2007-05-30 07:45:22-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P41 + + util/ntp-keygen-opts.texi@1.28, 2007-05-30 07:45:22-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P41 + + util/ntp-keygen.1@1.28, 2007-05-30 07:45:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P41 + +ChangeSet@1.1500, 2007-05-29 23:39:45-04:00, stenn@pogo.udel.edu +1 -0 + ChangeLog: + [Bug 825] Correct logconfig -/+ keyword processing. + [Bug 828] Correct parsing of " delimited strings. + + ChangeLog@1.56, 2007-05-29 23:39:10-04:00, stenn@pogo.udel.edu +2 -0 + [Bug 825] Correct logconfig -/+ keyword processing. + [Bug 828] Correct parsing of " delimited strings. + +ChangeSet@1.1499, 2007-05-29 15:46:00-04:00, neal@pogo.udel.edu +2 -0 + ntp_config.c: + [Bug 825] Correct logconfig -/+ keyword processing. + ntp_scanner.c: + [Bug 828] Correct parsing of " delimited strings. + + ntpd/ntp_config.c@1.153, 2007-05-29 13:23:28-04:00, neal@pogo.udel.edu +1 -1 + [Bug 825] Correct logconfig -/+ keyword processing. + + ntpd/ntp_scanner.c@1.5, 2007-05-29 13:22:33-04:00, neal@pogo.udel.edu +14 -2 + [Bug 828] Correct parsing of " delimited strings. + +ChangeSet@1.1498, 2007-05-29 09:39:55-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P40 + TAG: NTP_4_2_5P40 + + ntpd/ntpd-opts.c@1.27, 2007-05-29 09:39:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P40 + + ntpd/ntpd-opts.h@1.27, 2007-05-29 09:39:37-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P40 + + ntpd/ntpd-opts.texi@1.26, 2007-05-29 09:39:38-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P40 + + ntpd/ntpd.1@1.26, 2007-05-29 09:39:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P40 + + ntpdc/ntpdc-opts.c@1.27, 2007-05-29 09:39:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P40 + + ntpdc/ntpdc-opts.h@1.27, 2007-05-29 09:39:40-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P40 + + ntpdc/ntpdc-opts.texi@1.26, 2007-05-29 09:39:40-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P40 + + ntpdc/ntpdc.1@1.26, 2007-05-29 09:39:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P40 + + ntpq/ntpq-opts.c@1.27, 2007-05-29 09:39:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P40 + + ntpq/ntpq-opts.h@1.27, 2007-05-29 09:39:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P40 + + ntpq/ntpq-opts.texi@1.26, 2007-05-29 09:39:44-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P40 + + ntpq/ntpq.1@1.26, 2007-05-29 09:39:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P40 + + packageinfo.sh@1.43, 2007-05-29 09:39:45-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P40 + + sntp/sntp-opts.c@1.27, 2007-05-29 09:39:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P40 + + sntp/sntp-opts.h@1.27, 2007-05-29 09:39:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P40 + + sntp/sntp-opts.texi@1.26, 2007-05-29 09:39:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P40 + + sntp/sntp.1@1.26, 2007-05-29 09:39:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P40 + + util/ntp-keygen-opts.c@1.28, 2007-05-29 09:39:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P40 + + util/ntp-keygen-opts.h@1.28, 2007-05-29 09:39:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P40 + + util/ntp-keygen-opts.texi@1.27, 2007-05-29 09:39:50-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P40 + + util/ntp-keygen.1@1.27, 2007-05-29 09:39:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P40 + +ChangeSet@1.1436.1.54, 2007-05-29 07:43:58-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_4P2_RC5 + TAG: NTP_4_2_4P2_RC5 + + ntpd/ntpd-opts.c@1.50.6.1, 2007-05-29 07:43:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC5 + + ntpd/ntpd-opts.h@1.50.6.1, 2007-05-29 07:43:35-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC5 + + ntpd/ntpd-opts.texi@1.49.6.1, 2007-05-29 07:43:36-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC5 + + ntpd/ntpd.1@1.48.6.1, 2007-05-29 07:43:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC5 + + ntpd/ntpdsim-opts.c@1.50.6.1, 2007-05-29 07:43:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC5 + + ntpd/ntpdsim-opts.h@1.50.6.1, 2007-05-29 07:43:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC5 + + ntpd/ntpdsim-opts.texi@1.48.6.1, 2007-05-29 07:43:40-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC5 + + ntpd/ntpdsim.1@1.48.6.1, 2007-05-29 07:43:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC5 + + ntpdc/ntpdc-opts.c@1.50.6.1, 2007-05-29 07:43:41-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC5 + + ntpdc/ntpdc-opts.h@1.50.6.1, 2007-05-29 07:43:42-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC5 + + ntpdc/ntpdc-opts.texi@1.48.6.1, 2007-05-29 07:43:43-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC5 + + ntpdc/ntpdc.1@1.48.6.1, 2007-05-29 07:43:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC5 + + ntpq/ntpq-opts.c@1.52.6.1, 2007-05-29 07:43:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC5 + + ntpq/ntpq-opts.h@1.52.6.1, 2007-05-29 07:43:45-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC5 + + ntpq/ntpq-opts.texi@1.49.6.1, 2007-05-29 07:43:45-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC5 + + ntpq/ntpq.1@1.48.6.1, 2007-05-29 07:43:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC5 + + packageinfo.sh@1.65.12.1, 2007-05-29 07:43:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC5 + + sntp/sntp-opts.c@1.49.6.1, 2007-05-29 07:43:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC5 + + sntp/sntp-opts.h@1.49.6.1, 2007-05-29 07:43:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC5 + + sntp/sntp-opts.texi@1.46.6.1, 2007-05-29 07:43:49-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC5 + + sntp/sntp.1@1.49.6.1, 2007-05-29 07:43:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC5 + + util/ntp-keygen-opts.c@1.49.6.1, 2007-05-29 07:43:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC5 + + util/ntp-keygen-opts.h@1.49.6.1, 2007-05-29 07:43:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC5 + + util/ntp-keygen-opts.texi@1.47.6.1, 2007-05-29 07:43:53-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC5 + + util/ntp-keygen.1@1.47.6.1, 2007-05-29 07:43:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC5 + +ChangeSet@1.1436.1.53, 2007-05-29 01:32:29-04:00, stenn@whimsy.udel.edu +2 -0 + typo cleanup + + ChangeLog@1.1.1.17, 2007-05-29 01:32:14-04:00, stenn@whimsy.udel.edu +1 -1 + typo cleanup + + NEWS@1.86.1.7, 2007-05-29 01:32:15-04:00, stenn@whimsy.udel.edu +1 -2 + typo cleanup + +ChangeSet@1.1496, 2007-05-29 01:07:40-04:00, stenn@whimsy.udel.edu +2 -0 + Cleanup FILE * usage after fclose() in ntp_filegen.c + + ChangeLog@1.54, 2007-05-29 01:07:19-04:00, stenn@whimsy.udel.edu +5 -3 + Cleanup FILE * usage after fclose() in ntp_filegen.c + + ntpd/ntp_filegen.c@1.13, 2007-05-29 01:07:20-04:00, stenn@whimsy.udel.edu +27 -19 + Cleanup FILE * usage after fclose() in ntp_filegen.c + +ChangeSet@1.1495, 2007-05-28 07:47:31-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P39 + TAG: NTP_4_2_5P39 + + ntpd/ntpd-opts.c@1.26, 2007-05-28 07:47:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P39 + + ntpd/ntpd-opts.h@1.26, 2007-05-28 07:47:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P39 + + ntpd/ntpd-opts.texi@1.25, 2007-05-28 07:47:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P39 + + ntpd/ntpd.1@1.25, 2007-05-28 07:47:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P39 + + ntpdc/ntpdc-opts.c@1.26, 2007-05-28 07:47:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P39 + + ntpdc/ntpdc-opts.h@1.26, 2007-05-28 07:47:16-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P39 + + ntpdc/ntpdc-opts.texi@1.25, 2007-05-28 07:47:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P39 + + ntpdc/ntpdc.1@1.25, 2007-05-28 07:47:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P39 + + ntpq/ntpq-opts.c@1.26, 2007-05-28 07:47:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P39 + + ntpq/ntpq-opts.h@1.26, 2007-05-28 07:47:19-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P39 + + ntpq/ntpq-opts.texi@1.25, 2007-05-28 07:47:20-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P39 + + ntpq/ntpq.1@1.25, 2007-05-28 07:47:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P39 + + packageinfo.sh@1.42, 2007-05-28 07:47:21-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P39 + + sntp/sntp-opts.c@1.26, 2007-05-28 07:47:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P39 + + sntp/sntp-opts.h@1.26, 2007-05-28 07:47:22-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P39 + + sntp/sntp-opts.texi@1.25, 2007-05-28 07:47:23-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P39 + + sntp/sntp.1@1.25, 2007-05-28 07:47:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P39 + + util/ntp-keygen-opts.c@1.27, 2007-05-28 07:47:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P39 + + util/ntp-keygen-opts.h@1.27, 2007-05-28 07:47:25-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P39 + + util/ntp-keygen-opts.texi@1.26, 2007-05-28 07:47:26-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P39 + + util/ntp-keygen.1@1.26, 2007-05-28 07:47:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P39 + +ChangeSet@1.1436.1.52, 2007-05-28 10:00:27+00:00, kardel@pogo.udel.edu +3 -0 + NEWS, ntp_io.c, ChangeLog: + Bug 829: reduce syslog noise, while there fix Enabled/Disable logging + to reflect the actual configuration + + ChangeLog@1.1.1.16, 2007-05-28 09:54:40+00:00, kardel@pogo.udel.edu +2 -0 + Bug 829: reduce syslog noise, while there fix Enabled/Disable logging + to reflect the actual configuration + + NEWS@1.86.1.6, 2007-05-28 09:55:04+00:00, kardel@pogo.udel.edu +3 -0 + Bug 829: reduce syslog noise, while there fix Enabled/Disable logging + to reflect the actual configuration + + ntpd/ntp_io.c@1.244.2.6, 2007-05-28 09:59:44+00:00, kardel@pogo.udel.edu +58 -44 + Bug 829: reduce syslog noise, while there fix Enabled/Disable logging + to reflect the actual configuration + +ChangeSet@1.1493, 2007-05-27 20:13:47-04:00, mayer@pogo.udel.edu +1 -0 + Bug #843 Windows Completion port code was incorrectly merged from -stable + + ChangeLog@1.53, 2007-05-27 20:13:13-04:00, mayer@pogo.udel.edu +1 -0 + Bug #843 Windows Completion port code was incorrectly merged from -stable + +ChangeSet@1.1492, 2007-05-27 20:11:03-04:00, mayer@pogo.udel.edu +1 -0 + Bug #843 Windows Completion port code was incorrectly merged from -stable + + ports/winnt/ntpd/ntp_iocompletionport.c@1.25, 2007-05-27 20:10:47-04:00, mayer@pogo.udel.edu +0 -15 + Bug #843 Windows Completion port code was incorrectly merged from -stable + +ChangeSet@1.1491, 2007-05-27 09:46:31-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P38 + TAG: NTP_4_2_5P38 + + ntpd/ntpd-opts.c@1.25, 2007-05-27 09:46:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P38 + + ntpd/ntpd-opts.h@1.25, 2007-05-27 09:46:12-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P38 + + ntpd/ntpd-opts.texi@1.24, 2007-05-27 09:46:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P38 + + ntpd/ntpd.1@1.24, 2007-05-27 09:46:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P38 + + ntpdc/ntpdc-opts.c@1.25, 2007-05-27 09:46:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P38 + + ntpdc/ntpdc-opts.h@1.25, 2007-05-27 09:46:15-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P38 + + ntpdc/ntpdc-opts.texi@1.24, 2007-05-27 09:46:15-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P38 + + ntpdc/ntpdc.1@1.24, 2007-05-27 09:46:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P38 + + ntpq/ntpq-opts.c@1.25, 2007-05-27 09:46:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P38 + + ntpq/ntpq-opts.h@1.25, 2007-05-27 09:46:17-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P38 + + ntpq/ntpq-opts.texi@1.24, 2007-05-27 09:46:18-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P38 + + ntpq/ntpq.1@1.24, 2007-05-27 09:46:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P38 + + packageinfo.sh@1.41, 2007-05-27 09:46:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P38 + + sntp/sntp-opts.c@1.25, 2007-05-27 09:46:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P38 + + sntp/sntp-opts.h@1.25, 2007-05-27 09:46:20-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P38 + + sntp/sntp-opts.texi@1.24, 2007-05-27 09:46:21-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P38 + + sntp/sntp.1@1.24, 2007-05-27 09:46:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P38 + + util/ntp-keygen-opts.c@1.26, 2007-05-27 09:46:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P38 + + util/ntp-keygen-opts.h@1.26, 2007-05-27 09:46:24-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P38 + + util/ntp-keygen-opts.texi@1.25, 2007-05-27 09:46:24-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P38 + + util/ntp-keygen.1@1.25, 2007-05-27 09:46:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P38 + +ChangeSet@1.1436.1.51, 2007-05-27 07:45:05-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_4P2_RC4 + TAG: NTP_4_2_4P2_RC4 + + ntpd/ntpd-opts.c@1.50.5.1, 2007-05-27 07:44:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC4 + + ntpd/ntpd-opts.h@1.50.5.1, 2007-05-27 07:44:40-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC4 + + ntpd/ntpd-opts.texi@1.49.5.1, 2007-05-27 07:44:41-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC4 + + ntpd/ntpd.1@1.48.5.1, 2007-05-27 07:44:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC4 + + ntpd/ntpdsim-opts.c@1.50.5.1, 2007-05-27 07:44:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC4 + + ntpd/ntpdsim-opts.h@1.50.5.1, 2007-05-27 07:44:44-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC4 + + ntpd/ntpdsim-opts.texi@1.48.5.1, 2007-05-27 07:44:45-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC4 + + ntpd/ntpdsim.1@1.48.5.1, 2007-05-27 07:44:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC4 + + ntpdc/ntpdc-opts.c@1.50.5.1, 2007-05-27 07:44:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC4 + + ntpdc/ntpdc-opts.h@1.50.5.1, 2007-05-27 07:44:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC4 + + ntpdc/ntpdc-opts.texi@1.48.5.1, 2007-05-27 07:44:48-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC4 + + ntpdc/ntpdc.1@1.48.5.1, 2007-05-27 07:44:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC4 + + ntpq/ntpq-opts.c@1.52.5.1, 2007-05-27 07:44:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC4 + + ntpq/ntpq-opts.h@1.52.5.1, 2007-05-27 07:44:50-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC4 + + ntpq/ntpq-opts.texi@1.49.5.1, 2007-05-27 07:44:51-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC4 + + ntpq/ntpq.1@1.48.5.1, 2007-05-27 07:44:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC4 + + packageinfo.sh@1.65.11.1, 2007-05-27 07:44:52-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC4 + + sntp/sntp-opts.c@1.49.5.1, 2007-05-27 07:44:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC4 + + sntp/sntp-opts.h@1.49.5.1, 2007-05-27 07:44:54-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC4 + + sntp/sntp-opts.texi@1.46.5.1, 2007-05-27 07:44:55-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC4 + + sntp/sntp.1@1.49.5.1, 2007-05-27 07:44:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC4 + + util/ntp-keygen-opts.c@1.49.5.1, 2007-05-27 07:44:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC4 + + util/ntp-keygen-opts.h@1.49.5.1, 2007-05-27 07:44:57-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC4 + + util/ntp-keygen-opts.texi@1.47.5.1, 2007-05-27 07:44:58-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC4 + + util/ntp-keygen.1@1.47.5.1, 2007-05-27 07:44:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC4 + +ChangeSet@1.1436.1.50, 2007-05-27 00:52:52-04:00, stenn@whimsy.udel.edu +1 -0 + update NEWS file with new fixes + + NEWS@1.86.1.5, 2007-05-27 00:52:43-04:00, stenn@whimsy.udel.edu +6 -0 + update NEWS file with new fixes + +ChangeSet@1.1436.1.49, 2007-05-27 00:31:51-04:00, stenn@deacon.udel.edu +1 -0 + Cleanup + + ChangeLog@1.1.1.15, 2007-05-27 00:31:40-04:00, stenn@deacon.udel.edu +2 -2 + Cleanup + +ChangeSet@1.1485.2.2, 2007-05-26 15:10:28+00:00, kardel@pogo.udel.edu +9 -0 + Many files: + Bug 841: make deferred binding to local interface the default + + ChangeLog@1.47.2.2, 2007-05-26 15:08:45+00:00, kardel@pogo.udel.edu +2 -0 + Bug 841: make deferred binding to local interface the default + + html/confopt.html@1.36, 2007-05-26 15:05:35+00:00, kardel@pogo.udel.edu +0 -2 + Bug 841: make deferred binding to local interface the default + + html/ntpdc.html@1.27, 2007-05-26 15:05:37+00:00, kardel@pogo.udel.edu +2 -3 + Bug 841: make deferred binding to local interface the default + + include/ntp.h@1.131, 2007-05-26 15:05:49+00:00, kardel@pogo.udel.edu +0 -1 + Bug 841: make deferred binding to local interface the default + + include/ntp_request.h@1.31, 2007-05-26 15:05:50+00:00, kardel@pogo.udel.edu +0 -1 + Bug 841: make deferred binding to local interface the default + + ntpd/ntp_intres.c@1.51, 2007-05-26 15:06:07+00:00, kardel@pogo.udel.edu +1 -3 + Bug 841: make deferred binding to local interface the default + + ntpd/ntp_peer.c@1.101.1.1, 2007-05-26 15:06:08+00:00, kardel@pogo.udel.edu +1 -20 + Bug 841: make deferred binding to local interface the default + + ntpd/ntp_request.c@1.67, 2007-05-26 15:06:08+00:00, kardel@pogo.udel.edu +1 -3 + Bug 841: make deferred binding to local interface the default + + ntpdc/ntpdc_ops.c@1.48, 2007-05-26 15:06:16+00:00, kardel@pogo.udel.edu +2 -4 + Bug 841: make deferred binding to local interface the default + +ChangeSet@1.1485.2.1, 2007-05-26 13:29:05+00:00, kardel@pogo.udel.edu +2 -0 + ChangeLog: + Bug 840: do fudge configuration AFTER peers (thus refclocks) have been configured + ntp_config.c: + Bug 840: do fudge configuration AFTER peers (thus refclocks) have been configured + + ChangeLog@1.47.2.1, 2007-05-26 13:27:43+00:00, kardel@pogo.udel.edu +1 -0 + Bug 840: do fudge configuration AFTER peers (thus refclocks) have been configured + + ntpd/ntp_config.c@1.152, 2007-05-26 13:23:26+00:00, kardel@pogo.udel.edu +1 -1 + Bug 840: do fudge commands AFTER configuring peers (and thus refclocks) + +ChangeSet@1.1487.1.1, 2007-05-26 08:05:51-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P37 + TAG: NTP_4_2_5P37 + + ntpd/ntpd-opts.c@1.24, 2007-05-26 08:05:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P37 + + ntpd/ntpd-opts.h@1.24, 2007-05-26 08:05:31-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P37 + + ntpd/ntpd-opts.texi@1.23, 2007-05-26 08:05:32-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P37 + + ntpd/ntpd.1@1.23, 2007-05-26 08:05:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P37 + + ntpdc/ntpdc-opts.c@1.24, 2007-05-26 08:05:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P37 + + ntpdc/ntpdc-opts.h@1.24, 2007-05-26 08:05:34-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P37 + + ntpdc/ntpdc-opts.texi@1.23, 2007-05-26 08:05:35-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P37 + + ntpdc/ntpdc.1@1.23, 2007-05-26 08:05:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P37 + + ntpq/ntpq-opts.c@1.24, 2007-05-26 08:05:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P37 + + ntpq/ntpq-opts.h@1.24, 2007-05-26 08:05:37-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P37 + + ntpq/ntpq-opts.texi@1.23, 2007-05-26 08:05:38-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P37 + + ntpq/ntpq.1@1.23, 2007-05-26 08:05:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P37 + + packageinfo.sh@1.40, 2007-05-26 08:05:39-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P37 + + sntp/sntp-opts.c@1.24, 2007-05-26 08:05:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P37 + + sntp/sntp-opts.h@1.24, 2007-05-26 08:05:40-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P37 + + sntp/sntp-opts.texi@1.23, 2007-05-26 08:05:41-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P37 + + sntp/sntp.1@1.23, 2007-05-26 08:05:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P37 + + util/ntp-keygen-opts.c@1.25, 2007-05-26 08:05:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P37 + + util/ntp-keygen-opts.h@1.25, 2007-05-26 08:05:44-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P37 + + util/ntp-keygen-opts.texi@1.24, 2007-05-26 08:05:44-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P37 + + util/ntp-keygen.1@1.24, 2007-05-26 08:05:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P37 + +ChangeSet@1.1436.1.48, 2007-05-26 08:00:03+00:00, kardel@pogo.udel.edu +2 -0 + ntp_io.c: + [Bug 795] Moved declaration of variable to top of function. + ChangeLog: + [Bug 795] Moved declaration of variable to top of function. + + ChangeLog@1.1.1.14, 2007-05-26 07:57:22+00:00, kardel@pogo.udel.edu +1 -0 + Bug 795 + + ntpd/ntp_io.c@1.244.2.5, 2007-05-26 07:58:40+00:00, kardel@pogo.udel.edu +4 -1 + [Bug 795] Moved declaration of variable to top of function. + +ChangeSet@1.1436.3.9, 2007-05-25 07:44:43-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_4P2_RC3 + TAG: NTP_4_2_4P2_RC3 + + ntpd/ntpd-opts.c@1.50.4.1, 2007-05-25 07:44:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC3 + + ntpd/ntpd-opts.h@1.50.4.1, 2007-05-25 07:44:21-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC3 + + ntpd/ntpd-opts.texi@1.49.4.1, 2007-05-25 07:44:22-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC3 + + ntpd/ntpd.1@1.48.4.1, 2007-05-25 07:44:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC3 + + ntpd/ntpdsim-opts.c@1.50.4.1, 2007-05-25 07:44:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC3 + + ntpd/ntpdsim-opts.h@1.50.4.1, 2007-05-25 07:44:24-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC3 + + ntpd/ntpdsim-opts.texi@1.48.4.1, 2007-05-25 07:44:25-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC3 + + ntpd/ntpdsim.1@1.48.4.1, 2007-05-25 07:44:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC3 + + ntpdc/ntpdc-opts.c@1.50.4.1, 2007-05-25 07:44:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC3 + + ntpdc/ntpdc-opts.h@1.50.4.1, 2007-05-25 07:44:27-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC3 + + ntpdc/ntpdc-opts.texi@1.48.4.1, 2007-05-25 07:44:28-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC3 + + ntpdc/ntpdc.1@1.48.4.1, 2007-05-25 07:44:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC3 + + ntpq/ntpq-opts.c@1.52.4.1, 2007-05-25 07:44:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC3 + + ntpq/ntpq-opts.h@1.52.4.1, 2007-05-25 07:44:30-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC3 + + ntpq/ntpq-opts.texi@1.49.4.1, 2007-05-25 07:44:31-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC3 + + ntpq/ntpq.1@1.48.4.1, 2007-05-25 07:44:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC3 + + packageinfo.sh@1.65.10.1, 2007-05-25 07:44:33-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC3 + + sntp/sntp-opts.c@1.49.4.1, 2007-05-25 07:44:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC3 + + sntp/sntp-opts.h@1.49.4.1, 2007-05-25 07:44:35-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC3 + + sntp/sntp-opts.texi@1.46.4.1, 2007-05-25 07:44:35-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC3 + + sntp/sntp.1@1.49.4.1, 2007-05-25 07:44:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC3 + + util/ntp-keygen-opts.c@1.49.4.1, 2007-05-25 07:44:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC3 + + util/ntp-keygen-opts.h@1.49.4.1, 2007-05-25 07:44:38-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC3 + + util/ntp-keygen-opts.texi@1.47.4.1, 2007-05-25 07:44:38-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC3 + + util/ntp-keygen.1@1.47.4.1, 2007-05-25 07:44:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC3 + +ChangeSet@1.1436.3.8, 2007-05-25 02:18:59-04:00, stenn@whimsy.udel.edu +1 -0 + cleanup + + NEWS@1.86.1.4, 2007-05-25 02:18:48-04:00, stenn@whimsy.udel.edu +1 -0 + cleanup + +ChangeSet@1.1436.4.1, 2007-05-25 02:06:52-04:00, stenn@whimsy.udel.edu +2 -0 + Upgraded autogen and libopts + + ChangeLog@1.1.3.1, 2007-05-25 02:06:37-04:00, stenn@whimsy.udel.edu +1 -0 + Upgraded autogen and libopts + + NEWS@1.86.1.3, 2007-05-25 02:06:38-04:00, stenn@whimsy.udel.edu +1 -0 + Upgraded autogen and libopts + +ChangeSet@1.1436.3.6, 2007-05-25 01:07:59-04:00, stenn@pogo.udel.edu +1 -0 + cleanup ChangeLog + + ChangeLog@1.1.2.3, 2007-05-25 01:07:52-04:00, stenn@pogo.udel.edu +1 -1 + cleanup ChangeLog + +ChangeSet@1.1436.3.5, 2007-05-24 08:10:30-04:00, mayer@pogo.udel.edu +1 -0 + Bug #527 Don't write from source address length to wrong location + + ChangeLog@1.1.2.2, 2007-05-24 08:10:20-04:00, mayer@pogo.udel.edu +1 -0 + Bug #527 Don't write from source address length to wrong location + +ChangeSet@1.1436.3.4, 2007-05-24 08:08:34-04:00, mayer@pogo.udel.edu +4 -0 + Bug #527 Don't write from source address length to wrong location + + include/recvbuff.h@1.11.1.1, 2007-05-24 08:08:03-04:00, mayer@pogo.udel.edu +2 -0 + Bug #527 Don't write from source address length to wrong location + + libntp/recvbuff.c@1.25, 2007-05-24 08:08:03-04:00, mayer@pogo.udel.edu +27 -13 + Bug #527 Don't write from source address length to wrong location + + ports/winnt/libntp/transmitbuff.c@1.7, 2007-05-24 08:08:03-04:00, mayer@pogo.udel.edu +10 -10 + Bug #527 Don't write from source address length to wrong location + + ports/winnt/ntpd/ntp_iocompletionport.c@1.21.1.1, 2007-05-24 08:08:03-04:00, mayer@pogo.udel.edu +76 -62 + Bug #527 Don't write from source address length to wrong location + +ChangeSet@1.1485.1.2, 2007-05-24 07:44:46-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P36 + TAG: NTP_4_2_5P36 + + ntpd/ntpd-opts.c@1.23, 2007-05-24 07:44:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P36 + + ntpd/ntpd-opts.h@1.23, 2007-05-24 07:44:28-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P36 + + ntpd/ntpd-opts.texi@1.22, 2007-05-24 07:44:29-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P36 + + ntpd/ntpd.1@1.22, 2007-05-24 07:44:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P36 + + ntpdc/ntpdc-opts.c@1.23, 2007-05-24 07:44:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P36 + + ntpdc/ntpdc-opts.h@1.23, 2007-05-24 07:44:32-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P36 + + ntpdc/ntpdc-opts.texi@1.22, 2007-05-24 07:44:33-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P36 + + ntpdc/ntpdc.1@1.22, 2007-05-24 07:44:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P36 + + ntpq/ntpq-opts.c@1.23, 2007-05-24 07:44:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P36 + + ntpq/ntpq-opts.h@1.23, 2007-05-24 07:44:35-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P36 + + ntpq/ntpq-opts.texi@1.22, 2007-05-24 07:44:35-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P36 + + ntpq/ntpq.1@1.22, 2007-05-24 07:44:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P36 + + packageinfo.sh@1.39, 2007-05-24 07:44:37-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P36 + + sntp/sntp-opts.c@1.23, 2007-05-24 07:44:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P36 + + sntp/sntp-opts.h@1.23, 2007-05-24 07:44:38-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P36 + + sntp/sntp-opts.texi@1.22, 2007-05-24 07:44:39-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P36 + + sntp/sntp.1@1.22, 2007-05-24 07:44:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P36 + + util/ntp-keygen-opts.c@1.24, 2007-05-24 07:44:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P36 + + util/ntp-keygen-opts.h@1.24, 2007-05-24 07:44:41-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P36 + + util/ntp-keygen-opts.texi@1.23, 2007-05-24 07:44:42-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P36 + + util/ntp-keygen.1@1.23, 2007-05-24 07:44:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P36 + +ChangeSet@1.1485.1.1, 2007-05-24 01:38:12-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 832] Add libisc/log.c headers to the distribution. + + ChangeLog@1.47.1.1, 2007-05-24 01:38:00-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 832] Add libisc/log.c headers to the distribution. + + include/isc/Makefile.am@1.6, 2007-05-24 01:38:01-04:00, stenn@whimsy.udel.edu +6 -0 + [Bug 832] Add libisc/log.c headers to the distribution. + +ChangeSet@1.1486, 2007-05-22 15:19:42+00:00, burnicki@pogo.udel.edu +2 -0 + [Bug 824] Added the new parser modules to the Windows project file. + + ChangeLog@1.48, 2007-05-22 15:19:40+00:00, burnicki@pogo.udel.edu +1 -0 + Added the new parser modules to the Windows project file. + + ports/winnt/ntpd/ntpd.dsp@1.30, 2007-05-22 15:19:40+00:00, burnicki@pogo.udel.edu +12 -0 + Added the new parser modules to the Windows project file. + +ChangeSet@1.1485, 2007-05-21 07:44:27-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P35 + TAG: NTP_4_2_5P35 + + ntpd/ntpd-opts.c@1.22, 2007-05-21 07:44:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P35 + + ntpd/ntpd-opts.h@1.22, 2007-05-21 07:44:10-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P35 + + ntpd/ntpd-opts.texi@1.21, 2007-05-21 07:44:11-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P35 + + ntpd/ntpd.1@1.21, 2007-05-21 07:44:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P35 + + ntpdc/ntpdc-opts.c@1.22, 2007-05-21 07:44:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P35 + + ntpdc/ntpdc-opts.h@1.22, 2007-05-21 07:44:13-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P35 + + ntpdc/ntpdc-opts.texi@1.21, 2007-05-21 07:44:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P35 + + ntpdc/ntpdc.1@1.21, 2007-05-21 07:44:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P35 + + ntpq/ntpq-opts.c@1.22, 2007-05-21 07:44:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P35 + + ntpq/ntpq-opts.h@1.22, 2007-05-21 07:44:16-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P35 + + ntpq/ntpq-opts.texi@1.21, 2007-05-21 07:44:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P35 + + ntpq/ntpq.1@1.21, 2007-05-21 07:44:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P35 + + packageinfo.sh@1.38, 2007-05-21 07:44:19-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P35 + + sntp/sntp-opts.c@1.22, 2007-05-21 07:44:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P35 + + sntp/sntp-opts.h@1.22, 2007-05-21 07:44:20-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P35 + + sntp/sntp-opts.texi@1.21, 2007-05-21 07:44:20-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P35 + + sntp/sntp.1@1.21, 2007-05-21 07:44:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P35 + + util/ntp-keygen-opts.c@1.23, 2007-05-21 07:44:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P35 + + util/ntp-keygen-opts.h@1.23, 2007-05-21 07:44:22-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P35 + + util/ntp-keygen-opts.texi@1.22, 2007-05-21 07:44:23-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P35 + + util/ntp-keygen.1@1.22, 2007-05-21 07:44:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P35 + +ChangeSet@1.1484, 2007-05-21 00:29:26-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 808] Only write the drift file if we are in state 4 + + ChangeLog@1.47, 2007-05-21 00:29:10-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 808] Only write the drift file if we are in state 4 + + ntpd/ntp_util.c@1.45, 2007-05-21 00:29:11-04:00, stenn@whimsy.udel.edu +27 -24 + [Bug 808] Only write the drift file if we are in state 4 + +ChangeSet@1.1483, 2007-05-20 21:52:55-04:00, stenn@whimsy.udel.edu +1 -0 + Initial import of libisc/log.c and friends + + libntp/Makefile.am@1.39, 2007-05-20 21:52:40-04:00, stenn@whimsy.udel.edu +1 -0 + Initial import of libisc/log.c and friends + +ChangeSet@1.1482, 2007-05-20 16:32:43-04:00, stenn@whimsy.udel.edu +8 -0 + Initial import of libisc/log.c and friends + + ChangeLog@1.46, 2007-05-20 16:31:29-04:00, stenn@whimsy.udel.edu +1 -0 + Initial import of libisc/log.c and friends + + include/isc/dir.h@1.1, 2007-05-20 16:26:17-04:00, stenn@whimsy.udel.edu +94 -0 + BitKeeper file /deacon/backroom/ntp-dev/include/isc/dir.h + + include/isc/dir.h@1.0, 2007-05-20 16:26:16-04:00, stenn@whimsy.udel.edu +0 -0 + + include/isc/file.h@1.1, 2007-05-20 16:26:17-04:00, stenn@whimsy.udel.edu +256 -0 + BitKeeper file /deacon/backroom/ntp-dev/include/isc/file.h + + include/isc/file.h@1.0, 2007-05-20 16:26:17-04:00, stenn@whimsy.udel.edu +0 -0 + + include/isc/log.h@1.1, 2007-05-20 16:26:18-04:00, stenn@whimsy.udel.edu +913 -0 + BitKeeper file /deacon/backroom/ntp-dev/include/isc/log.h + + include/isc/log.h@1.0, 2007-05-20 16:26:18-04:00, stenn@whimsy.udel.edu +0 -0 + + include/isc/stat.h@1.1, 2007-05-20 16:26:18-04:00, stenn@whimsy.udel.edu +52 -0 + BitKeeper file /deacon/backroom/ntp-dev/include/isc/stat.h + + include/isc/stat.h@1.0, 2007-05-20 16:26:18-04:00, stenn@whimsy.udel.edu +0 -0 + + include/isc/stdio.h@1.1, 2007-05-20 16:26:19-04:00, stenn@whimsy.udel.edu +77 -0 + BitKeeper file /deacon/backroom/ntp-dev/include/isc/stdio.h + + include/isc/stdio.h@1.0, 2007-05-20 16:26:19-04:00, stenn@whimsy.udel.edu +0 -0 + + include/isc/time.h@1.1, 2007-05-20 16:26:19-04:00, stenn@whimsy.udel.edu +304 -0 + BitKeeper file /deacon/backroom/ntp-dev/include/isc/time.h + + include/isc/time.h@1.0, 2007-05-20 16:26:19-04:00, stenn@whimsy.udel.edu +0 -0 + + libisc/log.c@1.1, 2007-05-20 16:26:20-04:00, stenn@whimsy.udel.edu +1762 -0 + BitKeeper file /deacon/backroom/ntp-dev/libisc/log.c + + libisc/log.c@1.0, 2007-05-20 16:26:20-04:00, stenn@whimsy.udel.edu +0 -0 + +ChangeSet@1.1436.3.3, 2007-05-19 07:53:57-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_4P2_RC2 + TAG: NTP_4_2_4P2_RC2 + + ntpd/ntpd-opts.c@1.50.3.2, 2007-05-19 07:53:35-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P2_RC2 + + ntpd/ntpd-opts.h@1.50.3.2, 2007-05-19 07:53:35-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC2 + + ntpd/ntpd-opts.texi@1.49.3.2, 2007-05-19 07:53:36-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC2 + + ntpd/ntpd.1@1.48.3.2, 2007-05-19 07:53:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC2 + + ntpd/ntpdsim-opts.c@1.50.3.2, 2007-05-19 07:53:38-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P2_RC2 + + ntpd/ntpdsim-opts.h@1.50.3.2, 2007-05-19 07:53:39-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC2 + + ntpd/ntpdsim-opts.texi@1.48.3.2, 2007-05-19 07:53:40-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC2 + + ntpd/ntpdsim.1@1.48.3.2, 2007-05-19 07:53:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC2 + + ntpdc/ntpdc-opts.c@1.50.3.2, 2007-05-19 07:53:41-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P2_RC2 + + ntpdc/ntpdc-opts.h@1.50.3.2, 2007-05-19 07:53:42-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC2 + + ntpdc/ntpdc-opts.texi@1.48.3.2, 2007-05-19 07:53:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC2 + + ntpdc/ntpdc.1@1.48.3.2, 2007-05-19 07:53:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC2 + + ntpq/ntpq-opts.c@1.52.3.2, 2007-05-19 07:53:44-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P2_RC2 + + ntpq/ntpq-opts.h@1.52.3.2, 2007-05-19 07:53:45-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC2 + + ntpq/ntpq-opts.texi@1.49.3.2, 2007-05-19 07:53:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC2 + + ntpq/ntpq.1@1.48.3.2, 2007-05-19 07:53:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC2 + + packageinfo.sh@1.65.9.3, 2007-05-19 07:53:48-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC2 + + sntp/sntp-opts.c@1.49.3.2, 2007-05-19 07:53:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC2 + + sntp/sntp-opts.h@1.49.3.2, 2007-05-19 07:53:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC2 + + sntp/sntp-opts.texi@1.46.3.2, 2007-05-19 07:53:49-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC2 + + sntp/sntp.1@1.49.3.2, 2007-05-19 07:53:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC2 + + util/ntp-keygen-opts.c@1.49.3.2, 2007-05-19 07:53:51-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_4P2_RC2 + + util/ntp-keygen-opts.h@1.49.3.2, 2007-05-19 07:53:51-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC2 + + util/ntp-keygen-opts.texi@1.47.3.2, 2007-05-19 07:53:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC2 + + util/ntp-keygen.1@1.47.3.2, 2007-05-19 07:53:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC2 + +ChangeSet@1.1436.3.2, 2007-05-19 02:33:04-04:00, stenn@whimsy.udel.edu +193 -0 + We need another RC release to be sure the new autogen/libopts works. + + BitKeeper/deleted/.del-COPYING.lgpl~492b62c9d62ba57a@1.1.1.1, 2007-05-19 00:01:18-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/COPYING.lgpl + + BitKeeper/deleted/.del-COPYING.lgpl~adfa2ac04d64c0f7@1.1.1.1, 2007-05-19 00:00:02-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/COPYING.lgpl + + BitKeeper/deleted/.del-COPYING.mbsd~7e1baaedfa33c877@1.1.1.1, 2007-05-19 00:00:03-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/COPYING.mbsd + + BitKeeper/deleted/.del-COPYING.mbsd~e8244dcf5895b58f@1.1.1.1, 2007-05-19 00:01:19-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/COPYING.mbsd + + BitKeeper/deleted/.del-MakeDefs.inc~3fd54e9b117bfdad@1.1.1.1, 2007-05-19 00:01:20-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/MakeDefs.inc + + BitKeeper/deleted/.del-MakeDefs.inc~511eb438badc27b@1.1.1.1, 2007-05-19 00:00:04-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/MakeDefs.inc + + BitKeeper/deleted/.del-Makefile.am~65692661e68a4392@1.1.1.1, 2007-05-19 00:00:04-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/Makefile.am + + BitKeeper/deleted/.del-Makefile.am~fdf1a715e04b5f2c@1.1.1.1, 2007-05-19 00:01:21-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/Makefile.am + + BitKeeper/deleted/.del-README~7ed47aff36cc39c@1.1.1.1, 2007-05-19 00:01:22-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/README + + BitKeeper/deleted/.del-README~cec57621589d1ea6@1.1.1.1, 2007-05-19 00:00:05-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/README + + BitKeeper/deleted/.del-autoopts.c~7b48d6dc5ca9c3b@1.1.1.1, 2007-05-19 00:01:22-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.c~917f3eb3a2030087@1.1.1.1, 2007-05-19 00:00:06-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.h~4184ad33bbb8222@1.1.1.1, 2007-05-19 00:00:08-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/autoopts.h + + BitKeeper/deleted/.del-autoopts.h~d0834f397c8a330d@1.1.1.1, 2007-05-19 00:01:24-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts.h + + BitKeeper/deleted/.del-boolean.c~50ae286fc516eee2@1.1.1.1, 2007-05-19 00:01:25-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/boolean.c + + BitKeeper/deleted/.del-boolean.c~afd23e01a43b9536@1.1.1.1, 2007-05-19 00:00:09-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/boolean.c + + BitKeeper/deleted/.del-compat.h~2bcdd381f6a570a1@1.1.1.1, 2007-05-19 00:01:54-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/compat.h + + BitKeeper/deleted/.del-compat.h~e5d9fc11f0b928f2@1.1.1.1, 2007-05-19 00:00:35-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/compat.h + + BitKeeper/deleted/.del-configfile.c~53384c73e434a615@1.1.1.1, 2007-05-19 00:00:09-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/configfile.c + + BitKeeper/deleted/.del-configfile.c~ee0b7d49d26b4f74@1.1.1.1, 2007-05-19 00:01:26-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/configfile.c + + BitKeeper/deleted/.del-cook.c~760181d2119b672@1.1.1.1, 2007-05-19 00:01:27-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/cook.c + + BitKeeper/deleted/.del-cook.c~84c1af00a5581292@1.1.1.1, 2007-05-19 00:00:11-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/cook.c + + BitKeeper/deleted/.del-enumeration.c~551805256cb9068c@1.1.1.1, 2007-05-19 00:00:12-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/enumeration.c + + BitKeeper/deleted/.del-enumeration.c~969462e75e3913a3@1.1.1.1, 2007-05-19 00:01:29-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/enumeration.c + + BitKeeper/deleted/.del-environment.c~643ce1e5a16a4f94@1.1.1.1, 2007-05-19 00:01:30-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/environment.c + + BitKeeper/deleted/.del-environment.c~965d8c0fdf1150f5@1.1.1.1, 2007-05-19 00:00:13-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/environment.c + + BitKeeper/deleted/.del-genshell.c~20529138c60103c3@1.1.1.1, 2007-05-19 00:00:14-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/genshell.c + + BitKeeper/deleted/.del-genshell.c~bd74153097ec640f@1.1.1.1, 2007-05-19 00:01:31-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/genshell.c + + BitKeeper/deleted/.del-genshell.h~7f41539b135f914a@1.1.1.1, 2007-05-19 00:00:15-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/genshell.h + + BitKeeper/deleted/.del-genshell.h~b2793e1ea2981ff5@1.1.1.1, 2007-05-19 00:01:32-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/genshell.h + + BitKeeper/deleted/.del-libopts.c~9353e1c3a0c56ad@1.1.1.1, 2007-05-19 00:00:16-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/libopts.c + + BitKeeper/deleted/.del-libopts.c~bfc74bb368a309be@1.1.1.1, 2007-05-19 00:01:33-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/libopts.c + + BitKeeper/deleted/.del-libopts.m4~9851dd84df41023b@1.1.1.1, 2007-05-19 00:00:40-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-libopts.m4~9fa7e371d1cc0426@1.1.1.1, 2007-05-19 00:02:00-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-liboptschk.m4~1828e1c4576e5aea@1.1.1.1, 2007-05-19 00:00:41-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-liboptschk.m4~480d5c4f1634a9fa@1.1.1.1, 2007-05-19 00:02:01-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-load.c~688d4934eb14272@1.1.1.1, 2007-05-19 00:01:34-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/load.c + + BitKeeper/deleted/.del-load.c~b6aa568c6e3eaca1@1.1.1.1, 2007-05-19 00:00:16-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/load.c + + BitKeeper/deleted/.del-makeshell.c~8c63bc5a263da752@1.1.1.1, 2007-05-19 00:01:35-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/makeshell.c + + BitKeeper/deleted/.del-makeshell.c~a9cd96c3bfbc0835@1.1.1.1, 2007-05-19 00:00:17-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/makeshell.c + + BitKeeper/deleted/.del-nested.c~1670193227f54043@1.1.1.1, 2007-05-19 00:01:36-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/nested.c + + BitKeeper/deleted/.del-nested.c~a8521c8fcff292b6@1.1.1.1, 2007-05-19 00:00:18-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/nested.c + + BitKeeper/deleted/.del-numeric.c~eb3fbec29633e61@1.1.1.1, 2007-05-19 00:01:37-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/numeric.c + + BitKeeper/deleted/.del-numeric.c~ec644fa246942cbc@1.1.1.1, 2007-05-19 00:00:19-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/numeric.c + + BitKeeper/deleted/.del-options.h~3cb6af32ad01957@1.1.1.1, 2007-05-19 00:01:52-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts/options.h + + BitKeeper/deleted/.del-options.h~f700d69ce23e3e23@1.1.1.1, 2007-05-19 00:00:33-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/autoopts/options.h + + BitKeeper/deleted/.del-pathfind.c~953a96dbc9932@1.1.1.1, 2007-05-19 00:01:56-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pathfind.c~c132dab083075929@1.1.1.1, 2007-05-19 00:00:36-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pgusage.c~5c1f8f132e9a1546@1.1.1.1, 2007-05-19 00:01:39-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/pgusage.c + + BitKeeper/deleted/.del-pgusage.c~cec1309617012832@1.1.1.1, 2007-05-19 00:00:20-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/pgusage.c + + BitKeeper/deleted/.del-proto.h~697b4937ff37ca3f@1.1.1.1, 2007-05-19 00:01:40-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/proto.h + + BitKeeper/deleted/.del-proto.h~e2a13f546fbc0d4f@1.1.1.1, 2007-05-19 00:00:21-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/proto.h + + BitKeeper/deleted/.del-putshell.c~6845ea506fad6426@1.1.1.1, 2007-05-19 00:01:41-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/putshell.c + + BitKeeper/deleted/.del-putshell.c~6e39e6836261f3f7@1.1.1.1, 2007-05-19 00:00:22-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/putshell.c + + BitKeeper/deleted/.del-restore.c~c14d8b96be44c6a8@1.1.1.1, 2007-05-19 00:01:42-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/restore.c + + BitKeeper/deleted/.del-restore.c~e2a155efceab6f0d@1.1.1.1, 2007-05-19 00:00:23-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/restore.c + + BitKeeper/deleted/.del-save.c~17e5ac125a404fb0@1.1.1.1, 2007-05-19 00:00:24-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/save.c + + BitKeeper/deleted/.del-save.c~e7e7366cd24e1a8f@1.1.1.1, 2007-05-19 00:01:43-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/save.c + + BitKeeper/deleted/.del-snprintf.c~4b42e45647e9ccef@1.1.1.1, 2007-05-19 00:00:38-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/snprintf.c + + BitKeeper/deleted/.del-snprintf.c~988df6799c67781f@1.1.1.1, 2007-05-19 00:01:57-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/snprintf.c + + BitKeeper/deleted/.del-sort.c~586535d7d26d958@1.1.1.1, 2007-05-19 00:01:44-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/sort.c + + BitKeeper/deleted/.del-sort.c~bb92da923b5dcb7@1.1.1.1, 2007-05-19 00:00:25-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/sort.c + + BitKeeper/deleted/.del-stack.c~202d33ccdfd74ec@1.1.1.1, 2007-05-19 00:01:45-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/stack.c + + BitKeeper/deleted/.del-stack.c~b60d0ab82970f41f@1.1.1.1, 2007-05-19 00:00:26-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/stack.c + + BitKeeper/deleted/.del-strchr.c~4a7e412c18f53557@1.1.1.1, 2007-05-19 00:01:57-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/strchr.c + + BitKeeper/deleted/.del-strchr.c~7f4589858587fcc4@1.1.1.1, 2007-05-19 00:00:38-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/strchr.c + + BitKeeper/deleted/.del-strdup.c~75e27662f28944b1@1.1.1.1, 2007-05-19 00:01:58-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/strdup.c + + BitKeeper/deleted/.del-strdup.c~b295027011406c46@1.1.1.1, 2007-05-19 00:00:39-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/strdup.c + + BitKeeper/deleted/.del-streqvcmp.c~999e9cfa251ea4b3@1.1.1.1, 2007-05-19 00:00:28-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/streqvcmp.c + + BitKeeper/deleted/.del-streqvcmp.c~dc5534ffb1c6f28@1.1.1.1, 2007-05-19 00:01:47-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/streqvcmp.c + + BitKeeper/deleted/.del-text_mmap.c~52f2f1dbe57a9743@1.1.1.1, 2007-05-19 00:00:29-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/text_mmap.c + + BitKeeper/deleted/.del-text_mmap.c~e5096667484e499a@1.1.1.1, 2007-05-19 00:01:48-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/text_mmap.c + + BitKeeper/deleted/.del-tokenize.c~315c26f9b162f234@1.1.1.1, 2007-05-19 00:01:49-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/tokenize.c + + BitKeeper/deleted/.del-tokenize.c~6a814216fa293c3c@1.1.1.1, 2007-05-19 00:00:30-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/tokenize.c + + BitKeeper/deleted/.del-usage-txt.h~3737a7c76813e8c3@1.1.1.1, 2007-05-19 00:00:34-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage-txt.h~b71acc916d68c58c@1.1.1.1, 2007-05-19 00:01:53-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage.c~f21924faa210bfa9@1.1.1.1, 2007-05-19 00:01:50-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/usage.c + + BitKeeper/deleted/.del-usage.c~fe9a0f55b3cc55e4@1.1.1.1, 2007-05-19 00:00:31-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/usage.c + + BitKeeper/deleted/.del-version.c~b69eccbdea7f51d9@1.1.1.1, 2007-05-19 00:01:51-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/version.c + + BitKeeper/deleted/.del-version.c~de7f014d3e2ac91e@1.1.1.1, 2007-05-19 00:00:32-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/version.c + + BitKeeper/deleted/.del-windows-config.h~11a9a57b2895598f@1.1.1.1, 2007-05-19 00:01:59-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/windows-config.h + + BitKeeper/deleted/.del-windows-config.h~a6ead462c3d18ff0@1.1.1.1, 2007-05-19 00:00:39-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/windows-config.h + + clockstuff/clktest-opts.c@1.9.1.1, 2007-05-19 02:30:32-04:00, stenn@whimsy.udel.edu +38 -270 + We need to use the upgraded autogen/libopts in -stable too. + + clockstuff/clktest-opts.def@1.5.1.1, 2007-05-19 02:27:39-04:00, stenn@whimsy.udel.edu +4 -0 + We need to use the upgraded autogen/libopts in -stable too. + + clockstuff/clktest-opts.h@1.9.1.1, 2007-05-19 02:30:33-04:00, stenn@whimsy.udel.edu +22 -57 + We need to use the upgraded autogen/libopts in -stable too. + + include/autogen-version.def@1.4, 2007-05-19 02:27:41-04:00, stenn@whimsy.udel.edu +1 -1 + We need to use the upgraded autogen/libopts in -stable too. + + libopts/COPYING.lgpl@1.1, 2007-05-19 00:04:01-04:00, stenn@whimsy.udel.edu +502 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/COPYING.lgpl + + libopts/COPYING.lgpl@1.0, 2007-05-19 00:04:01-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/COPYING.mbsd@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +26 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/COPYING.mbsd + + libopts/COPYING.mbsd@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/MakeDefs.inc@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/MakeDefs.inc + + libopts/MakeDefs.inc@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/Makefile.am@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +24 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/Makefile.am + + libopts/Makefile.am@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/README@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/README + + libopts/README@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/autoopts.c@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +1120 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts.c + + libopts/autoopts.c@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/autoopts.h@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +387 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts.h + + libopts/autoopts.h@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/autoopts/options.h@1.1, 2007-05-19 00:04:14-04:00, stenn@whimsy.udel.edu +977 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts/options.h + + libopts/autoopts/options.h@1.0, 2007-05-19 00:04:14-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/autoopts/usage-txt.h@1.1, 2007-05-19 00:04:14-04:00, stenn@whimsy.udel.edu +355 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts/usage-txt.h + + libopts/autoopts/usage-txt.h@1.0, 2007-05-19 00:04:14-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/boolean.c@1.1, 2007-05-19 00:04:03-04:00, stenn@whimsy.udel.edu +106 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/boolean.c + + libopts/boolean.c@1.0, 2007-05-19 00:04:03-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/compat.h@1.1, 2007-05-19 00:04:15-04:00, stenn@whimsy.udel.edu +319 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/compat.h + + libopts/compat/compat.h@1.0, 2007-05-19 00:04:15-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/pathfind.c@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +339 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/pathfind.c + + libopts/compat/pathfind.c@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/snprintf.c@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/snprintf.c + + libopts/compat/snprintf.c@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/strchr.c@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/strchr.c + + libopts/compat/strchr.c@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/strdup.c@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +19 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/strdup.c + + libopts/compat/strdup.c@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/windows-config.h@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +130 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/windows-config.h + + libopts/compat/windows-config.h@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/configfile.c@1.1, 2007-05-19 00:04:03-04:00, stenn@whimsy.udel.edu +1290 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/configfile.c + + libopts/configfile.c@1.0, 2007-05-19 00:04:03-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/cook.c@1.1, 2007-05-19 00:04:04-04:00, stenn@whimsy.udel.edu +354 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/cook.c + + libopts/cook.c@1.0, 2007-05-19 00:04:04-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/enumeration.c@1.1, 2007-05-19 00:04:05-04:00, stenn@whimsy.udel.edu +498 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/enumeration.c + + libopts/enumeration.c@1.0, 2007-05-19 00:04:05-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/environment.c@1.1, 2007-05-19 00:04:05-04:00, stenn@whimsy.udel.edu +279 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/environment.c + + libopts/environment.c@1.0, 2007-05-19 00:04:05-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/genshell.c@1.1, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +354 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/genshell.c + + libopts/genshell.c@1.0, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/genshell.h@1.1, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +149 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/genshell.h + + libopts/genshell.h@1.0, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/libopts.c@1.1, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +30 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/libopts.c + + libopts/libopts.c@1.0, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/load.c@1.1, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +563 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/load.c + + libopts/load.c@1.0, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/m4/libopts.m4@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +509 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/m4/libopts.m4 + + libopts/m4/libopts.m4@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/m4/liboptschk.m4@1.1, 2007-05-19 00:04:17-04:00, stenn@whimsy.udel.edu +42 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/m4/liboptschk.m4 + + libopts/m4/liboptschk.m4@1.0, 2007-05-19 00:04:17-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/makeshell.c@1.1, 2007-05-19 00:04:07-04:00, stenn@whimsy.udel.edu +1122 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/makeshell.c + + libopts/makeshell.c@1.0, 2007-05-19 00:04:07-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/nested.c@1.1, 2007-05-19 00:04:07-04:00, stenn@whimsy.udel.edu +733 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/nested.c + + libopts/nested.c@1.0, 2007-05-19 00:04:07-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/numeric.c@1.1, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/numeric.c + + libopts/numeric.c@1.0, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/pgusage.c@1.1, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +157 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/pgusage.c + + libopts/pgusage.c@1.0, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/proto.h@1.1, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +91 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/proto.h + + libopts/proto.h@1.0, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/putshell.c@1.1, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +335 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/putshell.c + + libopts/putshell.c@1.0, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/restore.c@1.1, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +250 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/restore.c + + libopts/restore.c@1.0, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/save.c@1.1, 2007-05-19 00:04:09-04:00, stenn@whimsy.udel.edu +512 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/save.c + + libopts/save.c@1.0, 2007-05-19 00:04:09-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/sort.c@1.1, 2007-05-19 00:04:09-04:00, stenn@whimsy.udel.edu +359 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/sort.c + + libopts/sort.c@1.0, 2007-05-19 00:04:09-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/stack.c@1.1, 2007-05-19 00:04:10-04:00, stenn@whimsy.udel.edu +269 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/stack.c + + libopts/stack.c@1.0, 2007-05-19 00:04:10-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/streqvcmp.c@1.1, 2007-05-19 00:04:11-04:00, stenn@whimsy.udel.edu +289 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/streqvcmp.c + + libopts/streqvcmp.c@1.0, 2007-05-19 00:04:11-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/text_mmap.c@1.1, 2007-05-19 00:04:11-04:00, stenn@whimsy.udel.edu +363 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/text_mmap.c + + libopts/text_mmap.c@1.0, 2007-05-19 00:04:11-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/tokenize.c@1.1, 2007-05-19 00:04:12-04:00, stenn@whimsy.udel.edu +321 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/tokenize.c + + libopts/tokenize.c@1.0, 2007-05-19 00:04:12-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/usage.c@1.1, 2007-05-19 00:04:13-04:00, stenn@whimsy.udel.edu +740 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/usage.c + + libopts/usage.c@1.0, 2007-05-19 00:04:13-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/version.c@1.1, 2007-05-19 00:04:13-04:00, stenn@whimsy.udel.edu +178 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/version.c + + libopts/version.c@1.0, 2007-05-19 00:04:13-04:00, stenn@whimsy.udel.edu +0 -0 + + ntpd/ntpd-opts.c@1.50.3.1, 2007-05-19 02:30:34-04:00, stenn@whimsy.udel.edu +20 -11 + We need to use the upgraded autogen/libopts in -stable too. + + ntpd/ntpd-opts.h@1.50.3.1, 2007-05-19 02:30:36-04:00, stenn@whimsy.udel.edu +4 -4 + We need to use the upgraded autogen/libopts in -stable too. + + ntpd/ntpd-opts.texi@1.49.3.1, 2007-05-19 02:30:36-04:00, stenn@whimsy.udel.edu +2 -8 + We need to use the upgraded autogen/libopts in -stable too. + + ntpd/ntpd.1@1.48.3.1, 2007-05-19 02:30:37-04:00, stenn@whimsy.udel.edu +2 -2 + We need to use the upgraded autogen/libopts in -stable too. + + ntpd/ntpdsim-opts.c@1.50.3.1, 2007-05-19 02:30:40-04:00, stenn@whimsy.udel.edu +23 -14 + We need to use the upgraded autogen/libopts in -stable too. + + ntpd/ntpdsim-opts.h@1.50.3.1, 2007-05-19 02:30:41-04:00, stenn@whimsy.udel.edu +6 -6 + We need to use the upgraded autogen/libopts in -stable too. + + ntpd/ntpdsim-opts.texi@1.48.3.1, 2007-05-19 02:30:43-04:00, stenn@whimsy.udel.edu +1 -1 + We need to use the upgraded autogen/libopts in -stable too. + + ntpd/ntpdsim.1@1.48.3.1, 2007-05-19 02:30:44-04:00, stenn@whimsy.udel.edu +2 -2 + We need to use the upgraded autogen/libopts in -stable too. + + ntpdc/ntpdc-opts.c@1.50.3.1, 2007-05-19 02:30:45-04:00, stenn@whimsy.udel.edu +23 -14 + We need to use the upgraded autogen/libopts in -stable too. + + ntpdc/ntpdc-opts.h@1.50.3.1, 2007-05-19 02:30:48-04:00, stenn@whimsy.udel.edu +6 -6 + We need to use the upgraded autogen/libopts in -stable too. + + ntpdc/ntpdc-opts.texi@1.48.3.1, 2007-05-19 02:30:48-04:00, stenn@whimsy.udel.edu +3 -3 + We need to use the upgraded autogen/libopts in -stable too. + + ntpdc/ntpdc.1@1.48.3.1, 2007-05-19 02:30:49-04:00, stenn@whimsy.udel.edu +2 -2 + We need to use the upgraded autogen/libopts in -stable too. + + ntpq/ntpq-opts.c@1.52.3.1, 2007-05-19 02:30:50-04:00, stenn@whimsy.udel.edu +23 -14 + We need to use the upgraded autogen/libopts in -stable too. + + ntpq/ntpq-opts.h@1.52.3.1, 2007-05-19 02:30:51-04:00, stenn@whimsy.udel.edu +6 -6 + We need to use the upgraded autogen/libopts in -stable too. + + ntpq/ntpq-opts.texi@1.49.3.1, 2007-05-19 02:30:52-04:00, stenn@whimsy.udel.edu +3 -3 + We need to use the upgraded autogen/libopts in -stable too. + + ntpq/ntpq.1@1.48.3.1, 2007-05-19 02:30:53-04:00, stenn@whimsy.udel.edu +2 -2 + We need to use the upgraded autogen/libopts in -stable too. + + packageinfo.sh@1.65.9.2, 2007-05-19 02:28:15-04:00, stenn@whimsy.udel.edu +1 -1 + We need another RC release to be sure the new autogen/libopts works. + + sntp/libopts/COPYING.lgpl@1.1, 2007-05-19 00:04:59-04:00, stenn@whimsy.udel.edu +502 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/COPYING.lgpl + + sntp/libopts/COPYING.lgpl@1.0, 2007-05-19 00:04:59-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/COPYING.mbsd@1.1, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +26 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/COPYING.mbsd + + sntp/libopts/COPYING.mbsd@1.0, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/MakeDefs.inc@1.1, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/MakeDefs.inc + + sntp/libopts/MakeDefs.inc@1.0, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/Makefile.am@1.1, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +24 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/Makefile.am + + sntp/libopts/Makefile.am@1.0, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/README@1.1, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/README + + sntp/libopts/README@1.0, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/autoopts.c@1.1, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +1120 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/autoopts.c + + sntp/libopts/autoopts.c@1.0, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/autoopts.h@1.1, 2007-05-19 00:05:01-04:00, stenn@whimsy.udel.edu +387 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/autoopts.h + + sntp/libopts/autoopts.h@1.0, 2007-05-19 00:05:01-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/autoopts/options.h@1.1, 2007-05-19 00:05:12-04:00, stenn@whimsy.udel.edu +977 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/autoopts/options.h + + sntp/libopts/autoopts/options.h@1.0, 2007-05-19 00:05:12-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/autoopts/usage-txt.h@1.1, 2007-05-19 00:05:13-04:00, stenn@whimsy.udel.edu +355 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/autoopts/usage-txt.h + + sntp/libopts/autoopts/usage-txt.h@1.0, 2007-05-19 00:05:13-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/boolean.c@1.1, 2007-05-19 00:05:01-04:00, stenn@whimsy.udel.edu +106 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/boolean.c + + sntp/libopts/boolean.c@1.0, 2007-05-19 00:05:01-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/compat.h@1.1, 2007-05-19 00:05:13-04:00, stenn@whimsy.udel.edu +319 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/compat.h + + sntp/libopts/compat/compat.h@1.0, 2007-05-19 00:05:13-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/pathfind.c@1.1, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +339 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/pathfind.c + + sntp/libopts/compat/pathfind.c@1.0, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/snprintf.c@1.1, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/snprintf.c + + sntp/libopts/compat/snprintf.c@1.0, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/strchr.c@1.1, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/strchr.c + + sntp/libopts/compat/strchr.c@1.0, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/strdup.c@1.1, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +19 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/strdup.c + + sntp/libopts/compat/strdup.c@1.0, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/windows-config.h@1.1, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +130 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/windows-config.h + + sntp/libopts/compat/windows-config.h@1.0, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/configfile.c@1.1, 2007-05-19 00:05:01-04:00, stenn@whimsy.udel.edu +1290 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/configfile.c + + sntp/libopts/configfile.c@1.0, 2007-05-19 00:05:01-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/cook.c@1.1, 2007-05-19 00:05:02-04:00, stenn@whimsy.udel.edu +354 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/cook.c + + sntp/libopts/cook.c@1.0, 2007-05-19 00:05:02-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/enumeration.c@1.1, 2007-05-19 00:05:03-04:00, stenn@whimsy.udel.edu +498 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/enumeration.c + + sntp/libopts/enumeration.c@1.0, 2007-05-19 00:05:03-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/environment.c@1.1, 2007-05-19 00:05:04-04:00, stenn@whimsy.udel.edu +279 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/environment.c + + sntp/libopts/environment.c@1.0, 2007-05-19 00:05:04-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/genshell.c@1.1, 2007-05-19 00:05:04-04:00, stenn@whimsy.udel.edu +354 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/genshell.c + + sntp/libopts/genshell.c@1.0, 2007-05-19 00:05:04-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/genshell.h@1.1, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +149 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/genshell.h + + sntp/libopts/genshell.h@1.0, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/libopts.c@1.1, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +30 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/libopts.c + + sntp/libopts/libopts.c@1.0, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/load.c@1.1, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +563 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/load.c + + sntp/libopts/load.c@1.0, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/m4/libopts.m4@1.1, 2007-05-19 00:05:15-04:00, stenn@whimsy.udel.edu +509 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/m4/libopts.m4 + + sntp/libopts/m4/libopts.m4@1.0, 2007-05-19 00:05:15-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/m4/liboptschk.m4@1.1, 2007-05-19 00:05:15-04:00, stenn@whimsy.udel.edu +42 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/m4/liboptschk.m4 + + sntp/libopts/m4/liboptschk.m4@1.0, 2007-05-19 00:05:15-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/makeshell.c@1.1, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +1122 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/makeshell.c + + sntp/libopts/makeshell.c@1.0, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/nested.c@1.1, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +733 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/nested.c + + sntp/libopts/nested.c@1.0, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/numeric.c@1.1, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/numeric.c + + sntp/libopts/numeric.c@1.0, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/pgusage.c@1.1, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +157 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/pgusage.c + + sntp/libopts/pgusage.c@1.0, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/proto.h@1.1, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +91 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/proto.h + + sntp/libopts/proto.h@1.0, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/putshell.c@1.1, 2007-05-19 00:05:07-04:00, stenn@whimsy.udel.edu +335 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/putshell.c + + sntp/libopts/putshell.c@1.0, 2007-05-19 00:05:07-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/restore.c@1.1, 2007-05-19 00:05:07-04:00, stenn@whimsy.udel.edu +250 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/restore.c + + sntp/libopts/restore.c@1.0, 2007-05-19 00:05:07-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/save.c@1.1, 2007-05-19 00:05:08-04:00, stenn@whimsy.udel.edu +512 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/save.c + + sntp/libopts/save.c@1.0, 2007-05-19 00:05:08-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/sort.c@1.1, 2007-05-19 00:05:08-04:00, stenn@whimsy.udel.edu +359 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/sort.c + + sntp/libopts/sort.c@1.0, 2007-05-19 00:05:08-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/stack.c@1.1, 2007-05-19 00:05:09-04:00, stenn@whimsy.udel.edu +269 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/stack.c + + sntp/libopts/stack.c@1.0, 2007-05-19 00:05:09-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/streqvcmp.c@1.1, 2007-05-19 00:05:09-04:00, stenn@whimsy.udel.edu +289 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/streqvcmp.c + + sntp/libopts/streqvcmp.c@1.0, 2007-05-19 00:05:09-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/text_mmap.c@1.1, 2007-05-19 00:05:10-04:00, stenn@whimsy.udel.edu +363 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/text_mmap.c + + sntp/libopts/text_mmap.c@1.0, 2007-05-19 00:05:10-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/tokenize.c@1.1, 2007-05-19 00:05:10-04:00, stenn@whimsy.udel.edu +321 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/tokenize.c + + sntp/libopts/tokenize.c@1.0, 2007-05-19 00:05:10-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/usage.c@1.1, 2007-05-19 00:05:11-04:00, stenn@whimsy.udel.edu +740 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/usage.c + + sntp/libopts/usage.c@1.0, 2007-05-19 00:05:11-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/version.c@1.1, 2007-05-19 00:05:12-04:00, stenn@whimsy.udel.edu +178 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/version.c + + sntp/libopts/version.c@1.0, 2007-05-19 00:05:12-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/sntp-opts.c@1.49.3.1, 2007-05-19 02:30:55-04:00, stenn@whimsy.udel.edu +21 -12 + We need to use the upgraded autogen/libopts in -stable too. + + sntp/sntp-opts.h@1.49.3.1, 2007-05-19 02:30:56-04:00, stenn@whimsy.udel.edu +6 -6 + We need to use the upgraded autogen/libopts in -stable too. + + sntp/sntp-opts.texi@1.46.3.1, 2007-05-19 02:30:57-04:00, stenn@whimsy.udel.edu +1 -1 + We need to use the upgraded autogen/libopts in -stable too. + + sntp/sntp.1@1.49.3.1, 2007-05-19 02:30:58-04:00, stenn@whimsy.udel.edu +2 -2 + We need to use the upgraded autogen/libopts in -stable too. + + util/ntp-keygen-opts.c@1.49.3.1, 2007-05-19 02:31:00-04:00, stenn@whimsy.udel.edu +23 -14 + We need to use the upgraded autogen/libopts in -stable too. + + util/ntp-keygen-opts.h@1.49.3.1, 2007-05-19 02:31:02-04:00, stenn@whimsy.udel.edu +6 -6 + We need to use the upgraded autogen/libopts in -stable too. + + util/ntp-keygen-opts.texi@1.47.3.1, 2007-05-19 02:31:04-04:00, stenn@whimsy.udel.edu +3 -3 + We need to use the upgraded autogen/libopts in -stable too. + + util/ntp-keygen.1@1.47.3.1, 2007-05-19 02:31:04-04:00, stenn@whimsy.udel.edu +2 -2 + We need to use the upgraded autogen/libopts in -stable too. + +ChangeSet@1.1436.3.1, 2007-05-18 02:20:56-04:00, stenn@whimsy.udel.edu +3 -0 + Release 4.2.4p2 + + ChangeLog@1.1.2.1, 2007-05-18 02:19:13-04:00, stenn@whimsy.udel.edu +4 -2 + Release 4.2.4p2 + + NEWS@1.86.1.2, 2007-05-18 02:19:14-04:00, stenn@whimsy.udel.edu +6 -0 + Release 4.2.4p2 + + packageinfo.sh@1.65.9.1, 2007-05-18 02:20:38-04:00, stenn@whimsy.udel.edu +1 -1 + Release 4.2.4p2 + +ChangeSet@1.1481, 2007-05-16 07:44:03-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P34 + TAG: NTP_4_2_5P34 + + ntpd/ntpd-opts.c@1.21, 2007-05-16 07:43:44-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P34 + + ntpd/ntpd-opts.h@1.21, 2007-05-16 07:43:45-04:00, stenn@whimsy.udel.edu +5 -5 + NTP_4_2_5P34 + + ntpd/ntpd-opts.texi@1.20, 2007-05-16 07:43:46-04:00, stenn@whimsy.udel.edu +5 -5 + NTP_4_2_5P34 + + ntpd/ntpd.1@1.20, 2007-05-16 07:43:47-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P34 + + ntpdc/ntpdc-opts.c@1.21, 2007-05-16 07:43:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P34 + + ntpdc/ntpdc-opts.h@1.21, 2007-05-16 07:43:48-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P34 + + ntpdc/ntpdc-opts.texi@1.20, 2007-05-16 07:43:49-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P34 + + ntpdc/ntpdc.1@1.20, 2007-05-16 07:43:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P34 + + ntpq/ntpq-opts.c@1.21, 2007-05-16 07:43:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P34 + + ntpq/ntpq-opts.h@1.21, 2007-05-16 07:43:51-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P34 + + ntpq/ntpq-opts.texi@1.20, 2007-05-16 07:43:52-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P34 + + ntpq/ntpq.1@1.20, 2007-05-16 07:43:52-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P34 + + packageinfo.sh@1.37, 2007-05-16 07:43:53-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P34 + + sntp/sntp-opts.c@1.21, 2007-05-16 07:43:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P34 + + sntp/sntp-opts.h@1.21, 2007-05-16 07:43:55-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P34 + + sntp/sntp-opts.texi@1.20, 2007-05-16 07:43:55-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P34 + + sntp/sntp.1@1.20, 2007-05-16 07:43:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P34 + + util/ntp-keygen-opts.c@1.22, 2007-05-16 07:43:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P34 + + util/ntp-keygen-opts.h@1.22, 2007-05-16 07:43:58-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P34 + + util/ntp-keygen-opts.texi@1.21, 2007-05-16 07:43:58-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P34 + + util/ntp-keygen.1@1.21, 2007-05-16 07:43:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P34 + +ChangeSet@1.1480, 2007-05-16 03:56:15-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 826] Fix redefinition of PI + + ChangeLog@1.45, 2007-05-16 03:56:02-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 826] Fix redefinition of PI + +ChangeSet@1.1479, 2007-05-16 03:47:57-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 825] ntp_scanner.c needs to #include + + ChangeLog@1.44, 2007-05-16 03:47:42-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 825] ntp_scanner.c needs to #include + + ntpd/ntp_scanner.c@1.4, 2007-05-16 03:47:42-04:00, stenn@whimsy.udel.edu +4 -0 + [Bug 825] ntp_scanner.c needs to #include + +ChangeSet@1.1478, 2007-05-16 03:39:02-04:00, stenn@whimsy.udel.edu +8 -0 + [Bug 824] New parser code has some build problems with the SIM code. + + ChangeLog@1.43, 2007-05-16 03:38:39-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 824] New parser code has some build problems with the SIM code. + + include/ntp_config.h@1.45, 2007-05-16 03:38:40-04:00, stenn@whimsy.udel.edu +1 -5 + [Bug 824] New parser code has some build problems with the SIM code. + + include/ntpsim.h@1.9, 2007-05-16 03:38:40-04:00, stenn@whimsy.udel.edu +3 -4 + [Bug 824] New parser code has some build problems with the SIM code. + + ntpd/ntp_config.c@1.151, 2007-05-16 03:38:42-04:00, stenn@whimsy.udel.edu +11 -0 + [Bug 824] New parser code has some build problems with the SIM code. + + ntpd/ntp_data_structures.c@1.3, 2007-05-16 03:38:44-04:00, stenn@whimsy.udel.edu +1 -1 + [Bug 824] New parser code has some build problems with the SIM code. + + ntpd/ntp_parser.c@1.6, 2007-05-16 03:38:44-04:00, stenn@whimsy.udel.edu +2 -2 + [Bug 824] New parser code has some build problems with the SIM code. + + ntpd/ntp_parser.y@1.5, 2007-05-16 03:38:46-04:00, stenn@whimsy.udel.edu +1 -1 + [Bug 824] New parser code has some build problems with the SIM code. + + ntpd/ntpsim.c@1.17, 2007-05-16 03:38:46-04:00, stenn@whimsy.udel.edu +5 -2 + [Bug 824] New parser code has some build problems with the SIM code. + +ChangeSet@1.1477, 2007-05-16 00:49:12-04:00, stenn@whimsy.udel.edu +3 -0 + [Bug 817] Use longnames for setting ntp variables on the command-line + + ChangeLog@1.42, 2007-05-16 00:48:58-04:00, stenn@whimsy.udel.edu +3 -0 + [Bug 817] Use longnames for setting ntp variables on the command-line + + NEWS@1.91, 2007-05-16 00:48:59-04:00, stenn@whimsy.udel.edu +5 -0 + [Bug 817] Use longnames for setting ntp variables on the command-line + + ntpd/ntpdbase-opts.def@1.11, 2007-05-16 00:49:00-04:00, stenn@whimsy.udel.edu +2 -2 + [Bug 817] Use longnames for setting ntp variables on the command-line + +ChangeSet@1.1476, 2007-05-16 00:26:17-04:00, stenn@whimsy.udel.edu +2 -0 + [Bug 822] set progname once, early. + + ChangeLog@1.41, 2007-05-16 00:26:01-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 822] set progname once, early. + + ntpd/ntp_config.c@1.150, 2007-05-16 00:22:50-04:00, stenn@whimsy.udel.edu +0 -1 + [Bug 822] set progname once, early. + +ChangeSet@1.1475, 2007-05-15 07:43:16-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P33 + TAG: NTP_4_2_5P33 + + ntpd/ntpd-opts.c@1.20, 2007-05-15 07:42:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P33 + + ntpd/ntpd-opts.h@1.20, 2007-05-15 07:43:00-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P33 + + ntpd/ntpd-opts.texi@1.19, 2007-05-15 07:43:00-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P33 + + ntpd/ntpd.1@1.19, 2007-05-15 07:43:01-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P33 + + ntpdc/ntpdc-opts.c@1.20, 2007-05-15 07:43:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P33 + + ntpdc/ntpdc-opts.h@1.20, 2007-05-15 07:43:02-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P33 + + ntpdc/ntpdc-opts.texi@1.19, 2007-05-15 07:43:03-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P33 + + ntpdc/ntpdc.1@1.19, 2007-05-15 07:43:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P33 + + ntpq/ntpq-opts.c@1.20, 2007-05-15 07:43:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P33 + + ntpq/ntpq-opts.h@1.20, 2007-05-15 07:43:05-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P33 + + ntpq/ntpq-opts.texi@1.19, 2007-05-15 07:43:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P33 + + ntpq/ntpq.1@1.19, 2007-05-15 07:43:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P33 + + packageinfo.sh@1.36, 2007-05-15 07:43:08-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P33 + + sntp/sntp-opts.c@1.20, 2007-05-15 07:43:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P33 + + sntp/sntp-opts.h@1.20, 2007-05-15 07:43:09-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P33 + + sntp/sntp-opts.texi@1.19, 2007-05-15 07:43:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P33 + + sntp/sntp.1@1.19, 2007-05-15 07:43:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P33 + + util/ntp-keygen-opts.c@1.21, 2007-05-15 07:43:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P33 + + util/ntp-keygen-opts.h@1.21, 2007-05-15 07:43:11-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P33 + + util/ntp-keygen-opts.texi@1.20, 2007-05-15 07:43:12-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P33 + + util/ntp-keygen.1@1.20, 2007-05-15 07:43:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P33 + +ChangeSet@1.1474, 2007-05-15 06:42:51-04:00, stenn@pogo.udel.edu +1 -0 + Correct ChangeLog entry format + + ChangeLog@1.40, 2007-05-15 06:42:19-04:00, stenn@pogo.udel.edu +1 -1 + Correct ChangeLog entry format + +ChangeSet@1.1473, 2007-05-14 16:58:33-04:00, mayer@pogo.udel.edu +2 -0 + Bug 819 remove erroneous #if 0 in Windows code + + ChangeLog@1.39, 2007-05-14 16:58:19-04:00, mayer@pogo.udel.edu +1 -0 + Bug 819 remove erroneous #if 0 in Windows code + + ports/winnt/ntpd/ntp_iocompletionport.c@1.23, 2007-05-14 16:55:34-04:00, mayer@pogo.udel.edu +0 -2 + Bug 819 remove erroneous #if 0 + +ChangeSet@1.1472, 2007-05-13 07:43:28-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P32 + TAG: NTP_4_2_5P32 + + ntpd/ntpd-opts.c@1.19, 2007-05-13 07:43:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P32 + + ntpd/ntpd-opts.h@1.19, 2007-05-13 07:43:08-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P32 + + ntpd/ntpd-opts.texi@1.18, 2007-05-13 07:43:09-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P32 + + ntpd/ntpd.1@1.18, 2007-05-13 07:43:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P32 + + ntpdc/ntpdc-opts.c@1.19, 2007-05-13 07:43:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P32 + + ntpdc/ntpdc-opts.h@1.19, 2007-05-13 07:43:11-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P32 + + ntpdc/ntpdc-opts.texi@1.18, 2007-05-13 07:43:12-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P32 + + ntpdc/ntpdc.1@1.18, 2007-05-13 07:43:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P32 + + ntpq/ntpq-opts.c@1.19, 2007-05-13 07:43:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P32 + + ntpq/ntpq-opts.h@1.19, 2007-05-13 07:43:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P32 + + ntpq/ntpq-opts.texi@1.18, 2007-05-13 07:43:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P32 + + ntpq/ntpq.1@1.18, 2007-05-13 07:43:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P32 + + packageinfo.sh@1.35, 2007-05-13 07:43:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P32 + + sntp/sntp-opts.c@1.19, 2007-05-13 07:43:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P32 + + sntp/sntp-opts.h@1.19, 2007-05-13 07:43:17-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P32 + + sntp/sntp-opts.texi@1.18, 2007-05-13 07:43:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P32 + + sntp/sntp.1@1.18, 2007-05-13 07:43:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P32 + + util/ntp-keygen-opts.c@1.20, 2007-05-13 07:43:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P32 + + util/ntp-keygen-opts.h@1.20, 2007-05-13 07:43:19-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P32 + + util/ntp-keygen-opts.texi@1.19, 2007-05-13 07:43:21-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P32 + + util/ntp-keygen.1@1.19, 2007-05-13 07:43:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P32 + +ChangeSet@1.1471, 2007-05-13 03:42:41-04:00, stenn@whimsy.udel.edu +2 -0 + The new config code missed an #ifdef for building without refclocks + + ChangeLog@1.38, 2007-05-13 03:42:09-04:00, stenn@whimsy.udel.edu +1 -0 + The new config code missed an #ifdef for building without refclocks + + ntpd/ntp_config.c@1.149, 2007-05-13 03:42:08-04:00, stenn@whimsy.udel.edu +4 -0 + The new config code missed an #ifdef for building without refclocks + +ChangeSet@1.1470, 2007-05-13 00:04:25-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P31 + TAG: NTP_4_2_5P31 + + ntpd/ntpd-opts.c@1.18, 2007-05-13 00:04:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P31 + + ntpd/ntpd-opts.h@1.18, 2007-05-13 00:04:07-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P31 + + ntpd/ntpd-opts.texi@1.17, 2007-05-13 00:04:08-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P31 + + ntpd/ntpd.1@1.17, 2007-05-13 00:04:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P31 + + ntpdc/ntpdc-opts.c@1.18, 2007-05-13 00:04:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P31 + + ntpdc/ntpdc-opts.h@1.18, 2007-05-13 00:04:10-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P31 + + ntpdc/ntpdc-opts.texi@1.17, 2007-05-13 00:04:11-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P31 + + ntpdc/ntpdc.1@1.17, 2007-05-13 00:04:11-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P31 + + ntpq/ntpq-opts.c@1.18, 2007-05-13 00:04:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P31 + + ntpq/ntpq-opts.h@1.18, 2007-05-13 00:04:13-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P31 + + ntpq/ntpq-opts.texi@1.17, 2007-05-13 00:04:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P31 + + ntpq/ntpq.1@1.17, 2007-05-13 00:04:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P31 + + packageinfo.sh@1.34, 2007-05-13 00:04:16-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P31 + + sntp/sntp-opts.c@1.18, 2007-05-13 00:04:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P31 + + sntp/sntp-opts.h@1.18, 2007-05-13 00:04:17-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P31 + + sntp/sntp-opts.texi@1.17, 2007-05-13 00:04:17-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P31 + + sntp/sntp.1@1.17, 2007-05-13 00:04:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P31 + + util/ntp-keygen-opts.c@1.19, 2007-05-13 00:04:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P31 + + util/ntp-keygen-opts.h@1.19, 2007-05-13 00:04:20-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P31 + + util/ntp-keygen-opts.texi@1.18, 2007-05-13 00:04:21-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P31 + + util/ntp-keygen.1@1.18, 2007-05-13 00:04:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P31 + +ChangeSet@1.1469, 2007-05-12 23:13:08-04:00, stenn@whimsy.udel.edu +3 -0 + Distribute some files needed by the new config parsing code + + ChangeLog@1.37, 2007-05-12 23:12:57-04:00, stenn@whimsy.udel.edu +1 -0 + Distribute some files needed by the new config parsing code + + include/Makefile.am@1.27, 2007-05-12 23:12:56-04:00, stenn@whimsy.udel.edu +1 -0 + Distribute some files needed by the new config parsing code + + ntpd/Makefile.am@1.59, 2007-05-12 23:12:56-04:00, stenn@whimsy.udel.edu +2 -1 + Distribute some files needed by the new config parsing code + +ChangeSet@1.1468, 2007-05-12 20:05:36-04:00, stenn@whimsy.udel.edu +21 -0 + NTP_4_2_5P30 + TAG: NTP_4_2_5P30 + + ntpd/ntpd-opts.c@1.17, 2007-05-12 20:05:18-04:00, stenn@whimsy.udel.edu +19 -10 + NTP_4_2_5P30 + + ntpd/ntpd-opts.h@1.17, 2007-05-12 20:05:19-04:00, stenn@whimsy.udel.edu +6 -6 + NTP_4_2_5P30 + + ntpd/ntpd-opts.texi@1.16, 2007-05-12 20:05:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P30 + + ntpd/ntpd.1@1.16, 2007-05-12 20:05:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P30 + + ntpdc/ntpdc-opts.c@1.17, 2007-05-12 20:05:21-04:00, stenn@whimsy.udel.edu +22 -13 + NTP_4_2_5P30 + + ntpdc/ntpdc-opts.h@1.17, 2007-05-12 20:05:22-04:00, stenn@whimsy.udel.edu +8 -8 + NTP_4_2_5P30 + + ntpdc/ntpdc-opts.texi@1.16, 2007-05-12 20:05:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P30 + + ntpdc/ntpdc.1@1.16, 2007-05-12 20:05:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P30 + + ntpq/ntpq-opts.c@1.17, 2007-05-12 20:05:24-04:00, stenn@whimsy.udel.edu +22 -13 + NTP_4_2_5P30 + + ntpq/ntpq-opts.h@1.17, 2007-05-12 20:05:24-04:00, stenn@whimsy.udel.edu +8 -8 + NTP_4_2_5P30 + + ntpq/ntpq-opts.texi@1.16, 2007-05-12 20:05:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P30 + + ntpq/ntpq.1@1.16, 2007-05-12 20:05:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P30 + + packageinfo.sh@1.33, 2007-05-12 20:05:26-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P30 + + sntp/sntp-opts.c@1.17, 2007-05-12 20:05:27-04:00, stenn@whimsy.udel.edu +22 -13 + NTP_4_2_5P30 + + sntp/sntp-opts.h@1.17, 2007-05-12 20:05:27-04:00, stenn@whimsy.udel.edu +8 -8 + NTP_4_2_5P30 + + sntp/sntp-opts.texi@1.16, 2007-05-12 20:05:28-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P30 + + sntp/sntp.1@1.16, 2007-05-12 20:05:29-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P30 + + util/ntp-keygen-opts.c@1.18, 2007-05-12 20:05:29-04:00, stenn@whimsy.udel.edu +22 -13 + NTP_4_2_5P30 + + util/ntp-keygen-opts.h@1.18, 2007-05-12 20:05:31-04:00, stenn@whimsy.udel.edu +8 -8 + NTP_4_2_5P30 + + util/ntp-keygen-opts.texi@1.17, 2007-05-12 20:05:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P30 + + util/ntp-keygen.1@1.17, 2007-05-12 20:05:32-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P30 + +ChangeSet@1.1467, 2007-05-12 18:51:18-04:00, stenn@whimsy.udel.edu +1 -0 + ntpdsim does not need a separate.def file anymore + + .point-changed-filelist@1.2, 2007-05-12 18:51:06-04:00, stenn@whimsy.udel.edu +0 -4 + ntpdsim does not need a separate.def file anymore + +ChangeSet@1.1464.1.3, 2007-05-12 15:20:21-04:00, stenn@whimsy.udel.edu +1 -0 + update ChangeLog + + ChangeLog@1.34.1.1, 2007-05-12 15:20:05-04:00, stenn@whimsy.udel.edu +2 -0 + update + +ChangeSet@1.1464.1.2, 2007-05-12 15:11:16-04:00, stenn@whimsy.udel.edu +1 -0 + ntpdsim still needs to be linked with libntpsim.a + + ntpd/Makefile.am@1.58, 2007-05-12 15:11:04-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdsim still needs to be linked with libntpsim.a + +ChangeSet@1.1464.1.1, 2007-05-12 15:03:30-04:00, stenn@whimsy.udel.edu +165 -0 + The commandline args for clktest are different for CLKLDISC and STREAM + + BitKeeper/deleted/.del-COPYING.lgpl~10cb8d69d91c1d1a@1.2, 2007-05-12 00:40:50-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/COPYING.lgpl + + BitKeeper/deleted/.del-COPYING.lgpl~28a379c1d0a7d65b@1.2, 2007-05-12 00:47:49-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/COPYING.lgpl + + BitKeeper/deleted/.del-COPYING.mbsd~533e88f3b3fcf954@1.2, 2007-05-12 00:47:50-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/COPYING.mbsd + + BitKeeper/deleted/.del-COPYING.mbsd~b64c211489c98f8f@1.2, 2007-05-12 00:40:51-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/COPYING.mbsd + + BitKeeper/deleted/.del-MakeDefs.inc~1864382369b1f319@1.2, 2007-05-12 00:40:53-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/MakeDefs.inc + + BitKeeper/deleted/.del-MakeDefs.inc~834c15d5a9c89a66@1.2, 2007-05-12 00:47:52-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/MakeDefs.inc + + BitKeeper/deleted/.del-Makefile.am~1b934e5bbc1a52da@1.2, 2007-05-12 00:40:54-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/Makefile.am + + BitKeeper/deleted/.del-Makefile.am~6ccd1a00699fb256@1.2, 2007-05-12 00:47:53-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/Makefile.am + + BitKeeper/deleted/.del-README~92b3aeada81a2d71@1.2, 2007-05-12 00:40:55-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/README + + BitKeeper/deleted/.del-README~b514dee5178a5580@1.2, 2007-05-12 00:47:54-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/README + + BitKeeper/deleted/.del-autoopts.c~a46d961b536d64bf@1.2, 2007-05-12 00:40:56-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.c~bf6955d92ba49ae1@1.2, 2007-05-12 00:47:55-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.h~23dbdb3099b1cca4@1.2, 2007-05-12 00:40:57-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts.h + + BitKeeper/deleted/.del-autoopts.h~747513602f92fac1@1.2, 2007-05-12 00:47:57-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/autoopts.h + + BitKeeper/deleted/.del-boolean.c~94ccecb255a48b6e@1.2, 2007-05-12 00:40:58-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/boolean.c + + BitKeeper/deleted/.del-boolean.c~f7c50fbef5ac98e0@1.2, 2007-05-12 00:47:58-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/boolean.c + + BitKeeper/deleted/.del-compat.h~304782365980b0a6@1.2, 2007-05-12 00:48:32-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/compat.h + + BitKeeper/deleted/.del-compat.h~395225886f65b320@1.2, 2007-05-12 00:42:52-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/compat.h + + BitKeeper/deleted/.del-configfile.c~9bf9a8e83a3bd417@1.2, 2007-05-12 00:41:00-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/configfile.c + + BitKeeper/deleted/.del-configfile.c~c3073ecc386accae@1.2, 2007-05-12 00:47:59-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/configfile.c + + BitKeeper/deleted/.del-cook.c~aaac2f8aa56207ea@1.2, 2007-05-12 00:41:01-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/cook.c + + BitKeeper/deleted/.del-cook.c~ab79f9ba24a65414@1.2, 2007-05-12 00:48:01-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/cook.c + + BitKeeper/deleted/.del-enumeration.c~712ed026511a4fad@1.2, 2007-05-12 00:48:02-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/enumeration.c + + BitKeeper/deleted/.del-enumeration.c~8a49e92b5bc59603@1.2, 2007-05-12 00:41:02-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/enumeration.c + + BitKeeper/deleted/.del-environment.c~8c989df39464c6e6@1.2, 2007-05-12 00:48:03-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/environment.c + + BitKeeper/deleted/.del-environment.c~d00f13b319acf94@1.2, 2007-05-12 00:41:04-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/environment.c + + BitKeeper/deleted/.del-genshell.c~8eefb6dfb144e83@1.2, 2007-05-12 00:41:05-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/genshell.c + + BitKeeper/deleted/.del-genshell.c~d7f99fb1e982ee07@1.2, 2007-05-12 00:48:05-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/genshell.c + + BitKeeper/deleted/.del-genshell.h~51e39da43a911455@1.2, 2007-05-12 00:41:06-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/genshell.h + + BitKeeper/deleted/.del-genshell.h~d288760f8010eb26@1.2, 2007-05-12 00:48:06-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/genshell.h + + BitKeeper/deleted/.del-libopts.c~58110c12582b3028@1.2, 2007-05-12 00:48:08-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/libopts.c + + BitKeeper/deleted/.del-libopts.c~752b4eb28ce283b5@1.2, 2007-05-12 00:41:07-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/libopts.c + + BitKeeper/deleted/.del-libopts.m4~3768711f3ababaf6@1.2, 2007-05-12 00:48:39-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-libopts.m4~3ff78500945f8450@1.2, 2007-05-12 00:43:00-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-liboptschk.m4~7fc066e5c8ec737b@1.2, 2007-05-12 00:43:01-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-liboptschk.m4~874c63212488adfb@1.2, 2007-05-12 00:48:41-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-load.c~5266a52b9cc7c4c@1.2, 2007-05-12 00:48:09-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/load.c + + BitKeeper/deleted/.del-load.c~a2d76f9cb0ad15c2@1.2, 2007-05-12 00:41:09-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/load.c + + BitKeeper/deleted/.del-makeshell.c~29fe57c8fbbb00e3@1.2, 2007-05-12 00:48:10-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/makeshell.c + + BitKeeper/deleted/.del-makeshell.c~fc83cd9174e79990@1.2, 2007-05-12 00:41:10-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/makeshell.c + + BitKeeper/deleted/.del-nested.c~28f13939b51c52fd@1.2, 2007-05-12 00:41:11-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/nested.c + + BitKeeper/deleted/.del-nested.c~b140b093a1d64d9@1.2, 2007-05-12 00:48:12-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/nested.c + + BitKeeper/deleted/.del-numeric.c~65425d5a1d1c4bfe@1.2, 2007-05-12 00:41:13-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/numeric.c + + BitKeeper/deleted/.del-numeric.c~999e8ac5e2da8761@1.2, 2007-05-12 00:48:13-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/numeric.c + + BitKeeper/deleted/.del-options.h~5da7e2edf4e59b5a@1.2, 2007-05-12 00:48:29-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/autoopts/options.h + + BitKeeper/deleted/.del-options.h~b9d54ea51e67a003@1.2, 2007-05-12 00:42:40-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts/options.h + + BitKeeper/deleted/.del-pathfind.c~3b1936ad642daffc@1.2, 2007-05-12 00:48:33-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pathfind.c~a2ca5c6362091a22@1.2, 2007-05-12 00:42:53-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pgusage.c~b5c6b4ec94715759@1.2, 2007-05-12 00:41:14-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/pgusage.c + + BitKeeper/deleted/.del-pgusage.c~d5c1858d8398fae@1.2, 2007-05-12 00:48:14-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/pgusage.c + + BitKeeper/deleted/.del-proto.h~154b3828fc24cf61@1.2, 2007-05-12 00:48:15-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/proto.h + + BitKeeper/deleted/.del-proto.h~a1f40edb75ffe53a@1.2, 2007-05-12 00:41:16-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/proto.h + + BitKeeper/deleted/.del-putshell.c~a5873e4bd316e7ed@1.2, 2007-05-12 00:41:17-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/putshell.c + + BitKeeper/deleted/.del-putshell.c~e6ab712597a00d22@1.2, 2007-05-12 00:48:16-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/putshell.c + + BitKeeper/deleted/.del-restore.c~5d8d9d9524a773de@1.2, 2007-05-12 00:41:18-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/restore.c + + BitKeeper/deleted/.del-restore.c~88a5fde95bcff4ab@1.2, 2007-05-12 00:48:17-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/restore.c + + BitKeeper/deleted/.del-save.c~be7b0aaf121ec52c@1.2, 2007-05-12 00:41:20-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/save.c + + BitKeeper/deleted/.del-save.c~c6c15efe6c1d79fd@1.2, 2007-05-12 00:48:18-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/save.c + + BitKeeper/deleted/.del-snprintf.c~755eb3e8b8fdc776@1.2, 2007-05-12 00:42:54-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/snprintf.c + + BitKeeper/deleted/.del-snprintf.c~bd80dbf654a1386@1.2, 2007-05-12 00:48:34-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/snprintf.c + + BitKeeper/deleted/.del-sort.c~3107cfeb6d4410e0@1.2, 2007-05-12 00:48:19-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/sort.c + + BitKeeper/deleted/.del-sort.c~fd8c39deb0ab5d4f@1.2, 2007-05-12 00:41:21-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/sort.c + + BitKeeper/deleted/.del-stack.c~311ef6ab451f1f6@1.2, 2007-05-12 00:41:23-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/stack.c + + BitKeeper/deleted/.del-stack.c~63cca8b0f353d8f2@1.2, 2007-05-12 00:48:21-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/stack.c + + BitKeeper/deleted/.del-strchr.c~9747020ee65f676@1.2, 2007-05-12 00:48:36-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/strchr.c + + BitKeeper/deleted/.del-strchr.c~ee7c33848acad72@1.2, 2007-05-12 00:42:56-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/strchr.c + + BitKeeper/deleted/.del-strdup.c~b372303835eae985@1.2, 2007-05-12 00:42:57-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/strdup.c + + BitKeeper/deleted/.del-strdup.c~f0c4c4c41ddd1a3@1.2, 2007-05-12 00:48:37-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/strdup.c + + BitKeeper/deleted/.del-streqvcmp.c~73dcf75bcf91f8b9@1.2, 2007-05-12 00:48:22-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/streqvcmp.c + + BitKeeper/deleted/.del-streqvcmp.c~a7f96578aba73fa7@1.2, 2007-05-12 00:41:24-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/streqvcmp.c + + BitKeeper/deleted/.del-text_mmap.c~54ffd8e6a894fd3a@1.2, 2007-05-12 00:48:24-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/text_mmap.c + + BitKeeper/deleted/.del-text_mmap.c~a418cd03686e4369@1.2, 2007-05-12 00:41:25-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/text_mmap.c + + BitKeeper/deleted/.del-tokenize.c~383b75d922a43542@1.2, 2007-05-12 00:41:26-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/tokenize.c + + BitKeeper/deleted/.del-tokenize.c~a0a274ef5a23941b@1.2, 2007-05-12 00:48:25-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/tokenize.c + + BitKeeper/deleted/.del-usage-txt.h~2e88ec29a506e890@1.2, 2007-05-12 00:48:31-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage-txt.h~d982bb81a1b02298@1.2, 2007-05-12 00:42:41-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage.c~1108ba561360111a@1.2, 2007-05-12 00:48:27-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/usage.c + + BitKeeper/deleted/.del-usage.c~f5dfbb0ffd6bfc47@1.2, 2007-05-12 00:41:27-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/usage.c + + BitKeeper/deleted/.del-version.c~2149af8e100594bb@1.2, 2007-05-12 00:41:29-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/version.c + + BitKeeper/deleted/.del-version.c~d6d1f6f786b289e3@1.2, 2007-05-12 00:48:28-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/version.c + + BitKeeper/deleted/.del-windows-config.h~49e33bce6ec73aa9@1.2, 2007-05-12 00:48:38-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/windows-config.h + + BitKeeper/deleted/.del-windows-config.h~70a3d851a9350311@1.2, 2007-05-12 00:42:58-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/windows-config.h + + clockstuff/clktest-opts.def@1.6, 2007-05-12 15:03:20-04:00, stenn@whimsy.udel.edu +4 -0 + The commandline args for clktest are different for CLKLDISC and STREAM + + libopts/COPYING.lgpl@1.1, 2007-05-12 00:49:23-04:00, stenn@whimsy.udel.edu +502 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/COPYING.lgpl + + libopts/COPYING.lgpl@1.0, 2007-05-12 00:49:23-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/COPYING.mbsd@1.1, 2007-05-12 00:49:24-04:00, stenn@whimsy.udel.edu +26 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/COPYING.mbsd + + libopts/COPYING.mbsd@1.0, 2007-05-12 00:49:24-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/MakeDefs.inc@1.1, 2007-05-12 00:49:24-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/MakeDefs.inc + + libopts/MakeDefs.inc@1.0, 2007-05-12 00:49:24-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/Makefile.am@1.1, 2007-05-12 00:49:24-04:00, stenn@whimsy.udel.edu +24 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/Makefile.am + + libopts/Makefile.am@1.0, 2007-05-12 00:49:24-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/README@1.1, 2007-05-12 00:49:24-04:00, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/README + + libopts/README@1.0, 2007-05-12 00:49:24-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/autoopts.c@1.1, 2007-05-12 00:49:24-04:00, stenn@whimsy.udel.edu +1120 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts.c + + libopts/autoopts.c@1.0, 2007-05-12 00:49:24-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/autoopts.h@1.1, 2007-05-12 00:49:25-04:00, stenn@whimsy.udel.edu +387 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts.h + + libopts/autoopts.h@1.0, 2007-05-12 00:49:25-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/autoopts/options.h@1.1, 2007-05-12 00:49:35-04:00, stenn@whimsy.udel.edu +977 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts/options.h + + libopts/autoopts/options.h@1.0, 2007-05-12 00:49:35-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/autoopts/usage-txt.h@1.1, 2007-05-12 00:49:36-04:00, stenn@whimsy.udel.edu +355 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts/usage-txt.h + + libopts/autoopts/usage-txt.h@1.0, 2007-05-12 00:49:36-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/boolean.c@1.1, 2007-05-12 00:49:26-04:00, stenn@whimsy.udel.edu +106 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/boolean.c + + libopts/boolean.c@1.0, 2007-05-12 00:49:26-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/compat.h@1.1, 2007-05-12 00:49:37-04:00, stenn@whimsy.udel.edu +319 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/compat.h + + libopts/compat/compat.h@1.0, 2007-05-12 00:49:37-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/pathfind.c@1.1, 2007-05-12 00:49:37-04:00, stenn@whimsy.udel.edu +339 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/pathfind.c + + libopts/compat/pathfind.c@1.0, 2007-05-12 00:49:37-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/snprintf.c@1.1, 2007-05-12 00:49:37-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/snprintf.c + + libopts/compat/snprintf.c@1.0, 2007-05-12 00:49:37-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/strchr.c@1.1, 2007-05-12 00:49:37-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/strchr.c + + libopts/compat/strchr.c@1.0, 2007-05-12 00:49:37-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/strdup.c@1.1, 2007-05-12 00:49:37-04:00, stenn@whimsy.udel.edu +19 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/strdup.c + + libopts/compat/strdup.c@1.0, 2007-05-12 00:49:37-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/windows-config.h@1.1, 2007-05-12 00:49:38-04:00, stenn@whimsy.udel.edu +130 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/windows-config.h + + libopts/compat/windows-config.h@1.0, 2007-05-12 00:49:38-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/configfile.c@1.1, 2007-05-12 00:49:26-04:00, stenn@whimsy.udel.edu +1290 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/configfile.c + + libopts/configfile.c@1.0, 2007-05-12 00:49:26-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/cook.c@1.1, 2007-05-12 00:49:26-04:00, stenn@whimsy.udel.edu +354 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/cook.c + + libopts/cook.c@1.0, 2007-05-12 00:49:26-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/enumeration.c@1.1, 2007-05-12 00:49:27-04:00, stenn@whimsy.udel.edu +498 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/enumeration.c + + libopts/enumeration.c@1.0, 2007-05-12 00:49:27-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/environment.c@1.1, 2007-05-12 00:49:27-04:00, stenn@whimsy.udel.edu +279 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/environment.c + + libopts/environment.c@1.0, 2007-05-12 00:49:27-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/genshell.c@1.1, 2007-05-12 00:49:28-04:00, stenn@whimsy.udel.edu +354 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/genshell.c + + libopts/genshell.c@1.0, 2007-05-12 00:49:28-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/genshell.h@1.1, 2007-05-12 00:49:29-04:00, stenn@whimsy.udel.edu +149 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/genshell.h + + libopts/genshell.h@1.0, 2007-05-12 00:49:29-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/libopts.c@1.1, 2007-05-12 00:49:29-04:00, stenn@whimsy.udel.edu +30 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/libopts.c + + libopts/libopts.c@1.0, 2007-05-12 00:49:29-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/load.c@1.1, 2007-05-12 00:49:29-04:00, stenn@whimsy.udel.edu +563 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/load.c + + libopts/load.c@1.0, 2007-05-12 00:49:29-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/m4/libopts.m4@1.1, 2007-05-12 00:49:38-04:00, stenn@whimsy.udel.edu +509 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/m4/libopts.m4 + + libopts/m4/libopts.m4@1.0, 2007-05-12 00:49:38-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/m4/liboptschk.m4@1.1, 2007-05-12 00:49:38-04:00, stenn@whimsy.udel.edu +42 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/m4/liboptschk.m4 + + libopts/m4/liboptschk.m4@1.0, 2007-05-12 00:49:38-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/makeshell.c@1.1, 2007-05-12 00:49:29-04:00, stenn@whimsy.udel.edu +1122 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/makeshell.c + + libopts/makeshell.c@1.0, 2007-05-12 00:49:29-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/nested.c@1.1, 2007-05-12 00:49:30-04:00, stenn@whimsy.udel.edu +733 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/nested.c + + libopts/nested.c@1.0, 2007-05-12 00:49:30-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/numeric.c@1.1, 2007-05-12 00:49:30-04:00, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/numeric.c + + libopts/numeric.c@1.0, 2007-05-12 00:49:30-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/pgusage.c@1.1, 2007-05-12 00:49:30-04:00, stenn@whimsy.udel.edu +157 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/pgusage.c + + libopts/pgusage.c@1.0, 2007-05-12 00:49:30-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/proto.h@1.1, 2007-05-12 00:49:30-04:00, stenn@whimsy.udel.edu +91 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/proto.h + + libopts/proto.h@1.0, 2007-05-12 00:49:30-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/putshell.c@1.1, 2007-05-12 00:49:30-04:00, stenn@whimsy.udel.edu +335 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/putshell.c + + libopts/putshell.c@1.0, 2007-05-12 00:49:30-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/restore.c@1.1, 2007-05-12 00:49:31-04:00, stenn@whimsy.udel.edu +250 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/restore.c + + libopts/restore.c@1.0, 2007-05-12 00:49:31-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/save.c@1.1, 2007-05-12 00:49:31-04:00, stenn@whimsy.udel.edu +512 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/save.c + + libopts/save.c@1.0, 2007-05-12 00:49:31-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/sort.c@1.1, 2007-05-12 00:49:32-04:00, stenn@whimsy.udel.edu +359 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/sort.c + + libopts/sort.c@1.0, 2007-05-12 00:49:32-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/stack.c@1.1, 2007-05-12 00:49:33-04:00, stenn@whimsy.udel.edu +269 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/stack.c + + libopts/stack.c@1.0, 2007-05-12 00:49:33-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/streqvcmp.c@1.1, 2007-05-12 00:49:33-04:00, stenn@whimsy.udel.edu +289 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/streqvcmp.c + + libopts/streqvcmp.c@1.0, 2007-05-12 00:49:33-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/text_mmap.c@1.1, 2007-05-12 00:49:34-04:00, stenn@whimsy.udel.edu +363 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/text_mmap.c + + libopts/text_mmap.c@1.0, 2007-05-12 00:49:34-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/tokenize.c@1.1, 2007-05-12 00:49:34-04:00, stenn@whimsy.udel.edu +321 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/tokenize.c + + libopts/tokenize.c@1.0, 2007-05-12 00:49:34-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/usage.c@1.1, 2007-05-12 00:49:35-04:00, stenn@whimsy.udel.edu +740 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/usage.c + + libopts/usage.c@1.0, 2007-05-12 00:49:35-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/version.c@1.1, 2007-05-12 00:49:35-04:00, stenn@whimsy.udel.edu +178 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/version.c + + libopts/version.c@1.0, 2007-05-12 00:49:35-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/COPYING.lgpl@1.1, 2007-05-12 00:45:13-04:00, stenn@whimsy.udel.edu +502 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/COPYING.lgpl + + sntp/libopts/COPYING.lgpl@1.0, 2007-05-12 00:45:13-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/COPYING.mbsd@1.1, 2007-05-12 00:45:14-04:00, stenn@whimsy.udel.edu +26 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/COPYING.mbsd + + sntp/libopts/COPYING.mbsd@1.0, 2007-05-12 00:45:14-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/MakeDefs.inc@1.1, 2007-05-12 00:45:14-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/MakeDefs.inc + + sntp/libopts/MakeDefs.inc@1.0, 2007-05-12 00:45:14-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/Makefile.am@1.1, 2007-05-12 00:45:14-04:00, stenn@whimsy.udel.edu +24 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/Makefile.am + + sntp/libopts/Makefile.am@1.0, 2007-05-12 00:45:14-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/README@1.1, 2007-05-12 00:45:14-04:00, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/README + + sntp/libopts/README@1.0, 2007-05-12 00:45:14-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/autoopts.c@1.1, 2007-05-12 00:45:14-04:00, stenn@whimsy.udel.edu +1120 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts.c + + sntp/libopts/autoopts.c@1.0, 2007-05-12 00:45:14-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/autoopts.h@1.1, 2007-05-12 00:45:14-04:00, stenn@whimsy.udel.edu +387 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts.h + + sntp/libopts/autoopts.h@1.0, 2007-05-12 00:45:14-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/autoopts/options.h@1.1, 2007-05-12 00:45:25-04:00, stenn@whimsy.udel.edu +977 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts/options.h + + sntp/libopts/autoopts/options.h@1.0, 2007-05-12 00:45:25-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/autoopts/usage-txt.h@1.1, 2007-05-12 00:45:26-04:00, stenn@whimsy.udel.edu +355 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts/usage-txt.h + + sntp/libopts/autoopts/usage-txt.h@1.0, 2007-05-12 00:45:26-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/boolean.c@1.1, 2007-05-12 00:45:15-04:00, stenn@whimsy.udel.edu +106 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/boolean.c + + sntp/libopts/boolean.c@1.0, 2007-05-12 00:45:15-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/compat.h@1.1, 2007-05-12 00:45:26-04:00, stenn@whimsy.udel.edu +319 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/compat.h + + sntp/libopts/compat/compat.h@1.0, 2007-05-12 00:45:26-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/pathfind.c@1.1, 2007-05-12 00:45:27-04:00, stenn@whimsy.udel.edu +339 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/pathfind.c + + sntp/libopts/compat/pathfind.c@1.0, 2007-05-12 00:45:27-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/snprintf.c@1.1, 2007-05-12 00:45:27-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/snprintf.c + + sntp/libopts/compat/snprintf.c@1.0, 2007-05-12 00:45:27-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/strchr.c@1.1, 2007-05-12 00:45:27-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/strchr.c + + sntp/libopts/compat/strchr.c@1.0, 2007-05-12 00:45:27-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/strdup.c@1.1, 2007-05-12 00:45:27-04:00, stenn@whimsy.udel.edu +19 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/strdup.c + + sntp/libopts/compat/strdup.c@1.0, 2007-05-12 00:45:27-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/windows-config.h@1.1, 2007-05-12 00:45:28-04:00, stenn@whimsy.udel.edu +130 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/windows-config.h + + sntp/libopts/compat/windows-config.h@1.0, 2007-05-12 00:45:28-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/configfile.c@1.1, 2007-05-12 00:45:15-04:00, stenn@whimsy.udel.edu +1290 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/configfile.c + + sntp/libopts/configfile.c@1.0, 2007-05-12 00:45:15-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/cook.c@1.1, 2007-05-12 00:45:15-04:00, stenn@whimsy.udel.edu +354 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/cook.c + + sntp/libopts/cook.c@1.0, 2007-05-12 00:45:15-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/enumeration.c@1.1, 2007-05-12 00:45:16-04:00, stenn@whimsy.udel.edu +498 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/enumeration.c + + sntp/libopts/enumeration.c@1.0, 2007-05-12 00:45:16-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/environment.c@1.1, 2007-05-12 00:45:17-04:00, stenn@whimsy.udel.edu +279 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/environment.c + + sntp/libopts/environment.c@1.0, 2007-05-12 00:45:17-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/genshell.c@1.1, 2007-05-12 00:45:17-04:00, stenn@whimsy.udel.edu +354 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/genshell.c + + sntp/libopts/genshell.c@1.0, 2007-05-12 00:45:17-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/genshell.h@1.1, 2007-05-12 00:45:18-04:00, stenn@whimsy.udel.edu +149 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/genshell.h + + sntp/libopts/genshell.h@1.0, 2007-05-12 00:45:18-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/libopts.c@1.1, 2007-05-12 00:45:18-04:00, stenn@whimsy.udel.edu +30 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/libopts.c + + sntp/libopts/libopts.c@1.0, 2007-05-12 00:45:18-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/load.c@1.1, 2007-05-12 00:45:18-04:00, stenn@whimsy.udel.edu +563 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/load.c + + sntp/libopts/load.c@1.0, 2007-05-12 00:45:18-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/m4/libopts.m4@1.1, 2007-05-12 00:45:28-04:00, stenn@whimsy.udel.edu +509 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/m4/libopts.m4 + + sntp/libopts/m4/libopts.m4@1.0, 2007-05-12 00:45:28-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/m4/liboptschk.m4@1.1, 2007-05-12 00:45:28-04:00, stenn@whimsy.udel.edu +42 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/m4/liboptschk.m4 + + sntp/libopts/m4/liboptschk.m4@1.0, 2007-05-12 00:45:28-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/makeshell.c@1.1, 2007-05-12 00:45:19-04:00, stenn@whimsy.udel.edu +1122 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/makeshell.c + + sntp/libopts/makeshell.c@1.0, 2007-05-12 00:45:19-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/nested.c@1.1, 2007-05-12 00:45:19-04:00, stenn@whimsy.udel.edu +733 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/nested.c + + sntp/libopts/nested.c@1.0, 2007-05-12 00:45:19-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/numeric.c@1.1, 2007-05-12 00:45:20-04:00, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/numeric.c + + sntp/libopts/numeric.c@1.0, 2007-05-12 00:45:20-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/pgusage.c@1.1, 2007-05-12 00:45:20-04:00, stenn@whimsy.udel.edu +157 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/pgusage.c + + sntp/libopts/pgusage.c@1.0, 2007-05-12 00:45:20-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/proto.h@1.1, 2007-05-12 00:45:20-04:00, stenn@whimsy.udel.edu +91 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/proto.h + + sntp/libopts/proto.h@1.0, 2007-05-12 00:45:20-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/putshell.c@1.1, 2007-05-12 00:45:20-04:00, stenn@whimsy.udel.edu +335 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/putshell.c + + sntp/libopts/putshell.c@1.0, 2007-05-12 00:45:20-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/restore.c@1.1, 2007-05-12 00:45:21-04:00, stenn@whimsy.udel.edu +250 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/restore.c + + sntp/libopts/restore.c@1.0, 2007-05-12 00:45:21-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/save.c@1.1, 2007-05-12 00:45:21-04:00, stenn@whimsy.udel.edu +512 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/save.c + + sntp/libopts/save.c@1.0, 2007-05-12 00:45:21-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/sort.c@1.1, 2007-05-12 00:45:22-04:00, stenn@whimsy.udel.edu +359 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/sort.c + + sntp/libopts/sort.c@1.0, 2007-05-12 00:45:22-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/stack.c@1.1, 2007-05-12 00:45:22-04:00, stenn@whimsy.udel.edu +269 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/stack.c + + sntp/libopts/stack.c@1.0, 2007-05-12 00:45:22-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/streqvcmp.c@1.1, 2007-05-12 00:45:23-04:00, stenn@whimsy.udel.edu +289 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/streqvcmp.c + + sntp/libopts/streqvcmp.c@1.0, 2007-05-12 00:45:23-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/text_mmap.c@1.1, 2007-05-12 00:45:23-04:00, stenn@whimsy.udel.edu +363 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/text_mmap.c + + sntp/libopts/text_mmap.c@1.0, 2007-05-12 00:45:23-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/tokenize.c@1.1, 2007-05-12 00:45:24-04:00, stenn@whimsy.udel.edu +321 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/tokenize.c + + sntp/libopts/tokenize.c@1.0, 2007-05-12 00:45:24-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/usage.c@1.1, 2007-05-12 00:45:24-04:00, stenn@whimsy.udel.edu +740 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/usage.c + + sntp/libopts/usage.c@1.0, 2007-05-12 00:45:24-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/version.c@1.1, 2007-05-12 00:45:25-04:00, stenn@whimsy.udel.edu +178 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/version.c + + sntp/libopts/version.c@1.0, 2007-05-12 00:45:25-04:00, stenn@whimsy.udel.edu +0 -0 + +ChangeSet@1.1465, 2007-05-12 12:29:54-04:00, mayer@pogo.udel.edu +2 -0 + Bug 819 - Timeout for WaitForMultipleObjects was set to 500ms instead of INFINITE + + ChangeLog@1.35, 2007-05-12 12:29:35-04:00, mayer@pogo.udel.edu +1 -0 + Bug 819 - Timeout for WaitForMultipleObjects was set to 500ms instead of INFINITE + + ports/winnt/ntpd/ntp_iocompletionport.c@1.22, 2007-05-12 12:24:09-04:00, mayer@pogo.udel.edu +1 -2 + Bug 819 - Timeout for WaitForMultipleObjects was set to 500ms instead of INFINITE + +ChangeSet@1.1464, 2007-05-10 18:45:48-04:00, stenn@whimsy.udel.edu +5 -0 + Audio documentation updates from Dave Mills + + ChangeLog@1.34, 2007-05-10 18:45:36-04:00, stenn@whimsy.udel.edu +1 -0 + Audio documentation updates from Dave Mills + + html/audio.html@1.19, 2007-05-10 18:43:38-04:00, stenn@whimsy.udel.edu +5 -6 + Audio documentation updates from Dave Mills + + html/drivers/driver36.html@1.32, 2007-05-10 18:43:39-04:00, stenn@whimsy.udel.edu +6 -6 + Audio documentation updates from Dave Mills + + html/drivers/driver6.html@1.24, 2007-05-10 18:43:39-04:00, stenn@whimsy.udel.edu +3 -3 + Audio documentation updates from Dave Mills + + html/drivers/driver7.html@1.26, 2007-05-10 18:43:40-04:00, stenn@whimsy.udel.edu +4 -5 + Audio documentation updates from Dave Mills + +ChangeSet@1.1463, 2007-05-09 23:39:05-04:00, stenn@whimsy.udel.edu +1 -0 + refenerate ntp_parser.c + + ntpd/ntp_parser.c@1.5, 2007-05-09 23:38:37-04:00, stenn@whimsy.udel.edu +260 -236 + regenerate .y->.c file + +ChangeSet@1.1462, 2007-05-09 20:42:07-04:00, stenn@pogo.udel.edu +2 -0 + Build even if no OPENSSL + + ntpd/ntp_config.c@1.148, 2007-05-09 20:41:48-04:00, stenn@pogo.udel.edu +12 -2 + Build even if no OPENSSL + + ntpd/ntp_parser.y@1.4, 2007-05-09 20:41:49-04:00, stenn@pogo.udel.edu +23 -0 + Build even if no OPENSSL + +ChangeSet@1.1440.1.99, 2007-05-09 16:23:14-04:00, stenn@whimsy.udel.edu +2 -0 + More fuzz bit cleanup from Dave Mills + + ChangeLog@1.31.1.2, 2007-05-09 16:20:35-04:00, stenn@whimsy.udel.edu +2 -1 + More fuzz bit cleanup from Dave Mills + + libntp/systime.c@1.38.1.2, 2007-05-09 16:20:36-04:00, stenn@whimsy.udel.edu +18 -16 + More fuzz bit cleanup from Dave Mills + +ChangeSet@1.1440.1.98, 2007-05-09 07:42:10-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P29 + TAG: NTP_4_2_5P29 + + ntpd/ntpd-opts.c@1.16, 2007-05-09 07:41:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P29 + + ntpd/ntpd-opts.h@1.16, 2007-05-09 07:41:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P29 + + ntpd/ntpd-opts.texi@1.15, 2007-05-09 07:41:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P29 + + ntpd/ntpd.1@1.15, 2007-05-09 07:41:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P29 + + ntpd/ntpdsim-opts.c@1.16, 2007-05-09 07:41:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P29 + + ntpd/ntpdsim-opts.h@1.16, 2007-05-09 07:41:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P29 + + ntpd/ntpdsim-opts.texi@1.15, 2007-05-09 07:41:53-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P29 + + ntpd/ntpdsim.1@1.15, 2007-05-09 07:41:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P29 + + ntpdc/ntpdc-opts.c@1.16, 2007-05-09 07:41:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P29 + + ntpdc/ntpdc-opts.h@1.16, 2007-05-09 07:41:55-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P29 + + ntpdc/ntpdc-opts.texi@1.15, 2007-05-09 07:41:55-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P29 + + ntpdc/ntpdc.1@1.15, 2007-05-09 07:41:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P29 + + ntpq/ntpq-opts.c@1.16, 2007-05-09 07:41:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P29 + + ntpq/ntpq-opts.h@1.16, 2007-05-09 07:41:57-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P29 + + ntpq/ntpq-opts.texi@1.15, 2007-05-09 07:41:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P29 + + ntpq/ntpq.1@1.15, 2007-05-09 07:41:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P29 + + packageinfo.sh@1.32, 2007-05-09 07:42:00-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P29 + + sntp/sntp-opts.c@1.16, 2007-05-09 07:42:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P29 + + sntp/sntp-opts.h@1.16, 2007-05-09 07:42:01-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P29 + + sntp/sntp-opts.texi@1.15, 2007-05-09 07:42:01-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P29 + + sntp/sntp.1@1.15, 2007-05-09 07:42:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P29 + + util/ntp-keygen-opts.c@1.17, 2007-05-09 07:42:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P29 + + util/ntp-keygen-opts.h@1.17, 2007-05-09 07:42:03-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P29 + + util/ntp-keygen-opts.texi@1.16, 2007-05-09 07:42:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P29 + + util/ntp-keygen.1@1.16, 2007-05-09 07:42:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P29 + +ChangeSet@1.1440.1.97, 2007-05-09 05:19:46-04:00, stenn@whimsy.udel.edu +1 -0 + Added the ChangeLog entry from the previous commit + + ChangeLog@1.31.1.1, 2007-05-09 05:05:25-04:00, stenn@whimsy.udel.edu +1 -0 + Added the ChangeLog entry from the previous commit + +ChangeSet@1.1459, 2007-05-08 20:32:56-04:00, stenn@pogo.udel.edu +2 -0 + Protect some "debug" references + + ntpd/ntp_control.c@1.93, 2007-05-08 20:32:36-04:00, stenn@pogo.udel.edu +3 -0 + Protect some "debug" references + + ntpd/ntp_scanner.c@1.3, 2007-05-08 20:32:36-04:00, stenn@pogo.udel.edu +4 -2 + Protect some "debug" references + +ChangeSet@1.1440.1.96, 2007-05-07 07:42:57-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P28 + TAG: NTP_4_2_5P28 + + ntpd/ntpd-opts.c@1.15, 2007-05-07 07:42:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P28 + + ntpd/ntpd-opts.h@1.15, 2007-05-07 07:42:34-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P28 + + ntpd/ntpd-opts.texi@1.14, 2007-05-07 07:42:35-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P28 + + ntpd/ntpd.1@1.14, 2007-05-07 07:42:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P28 + + ntpd/ntpdsim-opts.c@1.15, 2007-05-07 07:42:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P28 + + ntpd/ntpdsim-opts.h@1.15, 2007-05-07 07:42:37-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P28 + + ntpd/ntpdsim-opts.texi@1.14, 2007-05-07 07:42:38-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P28 + + ntpd/ntpdsim.1@1.14, 2007-05-07 07:42:38-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P28 + + ntpdc/ntpdc-opts.c@1.15, 2007-05-07 07:42:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P28 + + ntpdc/ntpdc-opts.h@1.15, 2007-05-07 07:42:40-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P28 + + ntpdc/ntpdc-opts.texi@1.14, 2007-05-07 07:42:41-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P28 + + ntpdc/ntpdc.1@1.14, 2007-05-07 07:42:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P28 + + ntpq/ntpq-opts.c@1.15, 2007-05-07 07:42:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P28 + + ntpq/ntpq-opts.h@1.15, 2007-05-07 07:42:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P28 + + ntpq/ntpq-opts.texi@1.14, 2007-05-07 07:42:44-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P28 + + ntpq/ntpq.1@1.14, 2007-05-07 07:42:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P28 + + packageinfo.sh@1.31, 2007-05-07 07:42:45-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P28 + + sntp/sntp-opts.c@1.15, 2007-05-07 07:42:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P28 + + sntp/sntp-opts.h@1.15, 2007-05-07 07:42:46-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P28 + + sntp/sntp-opts.texi@1.14, 2007-05-07 07:42:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P28 + + sntp/sntp.1@1.14, 2007-05-07 07:42:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P28 + + util/ntp-keygen-opts.c@1.16, 2007-05-07 07:42:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P28 + + util/ntp-keygen-opts.h@1.16, 2007-05-07 07:42:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P28 + + util/ntp-keygen-opts.texi@1.15, 2007-05-07 07:42:50-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P28 + + util/ntp-keygen.1@1.15, 2007-05-07 07:42:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P28 + +ChangeSet@1.1440.1.95, 2007-05-07 06:43:34-04:00, stenn@whimsy.udel.edu +1 -0 + replay cleanup from Dave Mills + + ntpd/ntp_proto.c@1.252, 2007-05-07 06:43:07-04:00, stenn@whimsy.udel.edu +15 -18 + replay cleanup from Dave Mills + +ChangeSet@1.1440.1.94, 2007-05-07 06:35:26-04:00, stenn@whimsy.udel.edu +1 -0 + Cleanup random fuzz bits. (Dave Mills) + + libntp/systime.c@1.38.1.1, 2007-05-07 06:35:09-04:00, stenn@whimsy.udel.edu +7 -15 + Cleanup random fuzz bits. (Dave Mills) + +ChangeSet@1.1458, 2007-05-05 22:28:37-04:00, stenn@pogo.udel.edu +1 -0 + New config file parsing code + + ChangeLog@1.32, 2007-05-05 22:28:24-04:00, stenn@pogo.udel.edu +1 -0 + New config file parsing code + +ChangeSet@1.1457, 2007-05-05 14:29:11-04:00, stenn@pogo.udel.edu +1 -0 + bootstrap yacc/bison files + + bootstrap@1.19, 2007-05-05 14:29:04-04:00, stenn@pogo.udel.edu +4 -0 + bootstrap yacc/bison files + +ChangeSet@1.1455, 2007-05-05 14:15:36-04:00, stenn@pogo.udel.edu +1 -0 + OPENSSL and DEBUG cleanup + + ntpd/ntp_config.c@1.147, 2007-05-05 14:15:27-04:00, stenn@pogo.udel.edu +6 -0 + OPENSSL and DEBUG cleanup + +ChangeSet@1.1436.1.46, 2007-04-28 10:19:57+00:00, kardel@pogo.udel.edu +2 -0 + ntp_peer.c: + Bug 789 (backported from ntp-dev): + Fix multicast client crypto authentication and make sure arriving + multicast packets do not disturb the autokey dance. + ChangeLog: + Bug 789 (backported from ntp-dev): + Fix multicast client crypto authentication and make sure arriving + multicast packets do not disturb the autokey dance. + + ChangeLog@1.1.1.12, 2007-04-28 10:15:34+00:00, kardel@pogo.udel.edu +4 -1 + Bug 789: + Fix multicast client crypto authentication and make sure arriving + multicast packets do not disturb the autokey dance. + + ntpd/ntp_peer.c@1.97.1.2, 2007-04-28 10:06:31+00:00, kardel@pogo.udel.edu +21 -12 + Bug 789 (backported from ntp-dev): + fix multicast client mode by re-setting + crypto information only when the local address + changes and not for BCLNTs. + Addtitionally don't update the local address while + a BCLNT is doing the autokey dance. + +ChangeSet@1.1436.1.45, 2007-04-28 10:03:26+00:00, kardel@pogo.udel.edu +3 -0 + ntp_io.c, ChangeLog: + bug 785 (backport from ntp-dev): + improve handling of multicast interfaces + (multicast routers still need to run a multicast routing software/daemon) + ntp_peer.c: + bug 785 (backport from ntp-dev): + clarify debug messages + + ChangeLog@1.1.1.11, 2007-04-28 10:00:26+00:00, kardel@pogo.udel.edu +1 -0 + bug 785 (backport from ntp-dev): + improve handling of multicast interfaces + (multicast routers still need to run a multicast routing software/daemon) + + ntpd/ntp_io.c@1.244.2.4, 2007-04-28 09:52:18+00:00, kardel@pogo.udel.edu +84 -62 + bug 785 (backport from ntp-dev): + improve handling of multicast interfaces + (multicast routers still need to run a multicast routing software/daemon) + + ntpd/ntp_peer.c@1.97.1.1, 2007-04-28 09:53:09+00:00, kardel@pogo.udel.edu +2 -2 + bug 785 (backport from ntp-dev): + clarify debug messages + +ChangeSet@1.1440.1.93, 2007-04-25 07:46:23-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P27 + TAG: NTP_4_2_5P27 + + ntpd/ntpd-opts.c@1.14, 2007-04-25 07:46:02-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P27 + + ntpd/ntpd-opts.h@1.14, 2007-04-25 07:46:02-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P27 + + ntpd/ntpd-opts.texi@1.13, 2007-04-25 07:46:03-04:00, stenn@whimsy.udel.edu +2 -8 + NTP_4_2_5P27 + + ntpd/ntpd.1@1.13, 2007-04-25 07:46:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P27 + + ntpd/ntpdsim-opts.c@1.14, 2007-04-25 07:46:04-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P27 + + ntpd/ntpdsim-opts.h@1.14, 2007-04-25 07:46:05-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P27 + + ntpd/ntpdsim-opts.texi@1.13, 2007-04-25 07:46:06-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P27 + + ntpd/ntpdsim.1@1.13, 2007-04-25 07:46:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P27 + + ntpdc/ntpdc-opts.c@1.14, 2007-04-25 07:46:07-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P27 + + ntpdc/ntpdc-opts.h@1.14, 2007-04-25 07:46:07-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P27 + + ntpdc/ntpdc-opts.texi@1.13, 2007-04-25 07:46:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P27 + + ntpdc/ntpdc.1@1.13, 2007-04-25 07:46:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P27 + + ntpq/ntpq-opts.c@1.14, 2007-04-25 07:46:10-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P27 + + ntpq/ntpq-opts.h@1.14, 2007-04-25 07:46:11-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P27 + + ntpq/ntpq-opts.texi@1.13, 2007-04-25 07:46:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P27 + + ntpq/ntpq.1@1.13, 2007-04-25 07:46:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P27 + + packageinfo.sh@1.30, 2007-04-25 07:46:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P27 + + sntp/sntp-opts.c@1.14, 2007-04-25 07:46:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P27 + + sntp/sntp-opts.h@1.14, 2007-04-25 07:46:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P27 + + sntp/sntp-opts.texi@1.13, 2007-04-25 07:46:15-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P27 + + sntp/sntp.1@1.13, 2007-04-25 07:46:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P27 + + util/ntp-keygen-opts.c@1.15, 2007-04-25 07:46:17-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P27 + + util/ntp-keygen-opts.h@1.15, 2007-04-25 07:46:18-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P27 + + util/ntp-keygen-opts.texi@1.14, 2007-04-25 07:46:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P27 + + util/ntp-keygen.1@1.14, 2007-04-25 07:46:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P27 + +ChangeSet@1.1440.1.92, 2007-04-25 03:39:23-04:00, stenn@whimsy.udel.edu +1 -0 + The m4/ subdirectory is magically handled. + + Makefile.am@1.75, 2007-04-25 03:39:15-04:00, stenn@whimsy.udel.edu +0 -1 + The m4/ subdirectory is magically handled. + +ChangeSet@1.1440.1.91, 2007-04-25 02:45:35-04:00, stenn@whimsy.udel.edu +6 -0 + [Bug 542] Tolerate missing directory separator at EO statsdir + + ChangeLog@1.31, 2007-04-25 02:44:44-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 542] Tolerate missing directory separator at EO statsdir + + Makefile.am@1.74, 2007-04-25 02:44:44-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 542] Tolerate missing directory separator at EO statsdir + + configure.ac@1.404.1.1, 2007-04-25 02:44:45-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 542] Tolerate missing directory separator at EO statsdir + + m4/ntp_dir_sep.m4@1.1, 2007-04-25 02:40:45-04:00, stenn@whimsy.udel.edu +18 -0 + BitKeeper file /deacon/backroom/ntp-dev/m4/ntp_dir_sep.m4 + + m4/ntp_dir_sep.m4@1.0, 2007-04-25 02:40:45-04:00, stenn@whimsy.udel.edu +0 -0 + + ntpd/ntp_util.c@1.44, 2007-04-25 02:44:47-04:00, stenn@whimsy.udel.edu +20 -1 + [Bug 542] Tolerate missing directory separator at EO statsdir + + ports/winnt/include/config.h@1.49, 2007-04-25 02:44:47-04:00, stenn@whimsy.udel.edu +10 -7 + [Bug 542] Tolerate missing directory separator at EO statsdir + +ChangeSet@1.1454, 2007-04-23 16:33:49+00:00, kamboj@pogo.udel.edu +15 -0 + Includes changes to allow the seperate compilation of ntp_data_structures.c ntp_scanner.c and ntp_parser.y + Also includes other minor bugfixes. + + BitKeeper/etc/ignore@1.60, 2007-04-20 22:53:07-04:00, stenn@pogo.udel.edu +1 -0 + added ylwrap + + configure.ac@1.405, 2007-04-23 16:33:44+00:00, kamboj@pogo.udel.edu +1 -0 + Minor Changes + + include/ntp_config.h@1.44, 2007-04-23 16:22:55+00:00, kamboj@pogo.udel.edu +25 -9 + Moved some declarations from ntp_scanner.h to this file and vice versa. + + include/ntpsim.h@1.8, 2007-04-23 16:33:44+00:00, kamboj@pogo.udel.edu +0 -1 + Removed a comment + + libntp/systime.c@1.40, 2007-04-23 16:33:44+00:00, kamboj@pogo.udel.edu +2 -1 + No changes + + ntpd/Makefile.am@1.57, 2007-04-23 16:33:44+00:00, kamboj@pogo.udel.edu +5 -2 + Updated SOURCES to include ntp_data_structures.c ntp_scanner.c and ntp_parser.y files + + ntpd/cmd_args.c@1.49, 2007-04-23 16:33:45+00:00, kamboj@pogo.udel.edu +1 -1 + Minor bugfix + + ntpd/ntp_config.c@1.146, 2007-04-23 16:33:45+00:00, kamboj@pogo.udel.edu +8 -58 + Removed the direcrt inclusion of source files. + Including headers instead. + + ntpd/ntp_data_structures.c@1.2, 2007-04-23 16:33:45+00:00, kamboj@pogo.udel.edu +5 -2 + Updated to include a header file for the data structures. + + ntpd/ntp_parser.c@1.4, 2007-04-23 16:33:45+00:00, kamboj@pogo.udel.edu +683 -650 + New file generated from ntp_parser.y + + ntpd/ntp_parser.c@1.3, 2007-04-20 18:15:01-04:00, stenn@pogo.udel.edu +0 -0 + Rename: ntpd/ntp_config.tab.c -> ntpd/ntp_parser.c + + ntpd/ntp_parser.h@1.2, 2007-04-23 16:33:45+00:00, kamboj@pogo.udel.edu +4 -3 + New file generated from ntp_parser.y + + ntpd/ntp_parser.h@1.1, 2007-04-20 22:52:36-04:00, stenn@pogo.udel.edu +174 -0 + BitKeeper file /pogo/users/kamboj/new-config-bk-repo/ntpd/ntp_parser.h + + ntpd/ntp_parser.h@1.0, 2007-04-20 22:52:36-04:00, stenn@pogo.udel.edu +0 -0 + + ntpd/ntp_parser.y@1.3, 2007-04-23 16:33:46+00:00, kamboj@pogo.udel.edu +38 -1 + Added required headers to the code + + ntpd/ntp_parser.y@1.2, 2007-04-20 18:15:14-04:00, stenn@pogo.udel.edu +0 -0 + Rename: ntpd/ntp_config.y -> ntpd/ntp_parser.y + + ntpd/ntp_scanner.c@1.2, 2007-04-23 16:33:46+00:00, kamboj@pogo.udel.edu +25 -36 + Minor changes: + Updated function definitions to conform to ANSI C + Moved some data from ntp_scanner.h to this file + + ntpd/ntp_scanner.h@1.2, 2007-04-23 16:33:46+00:00, kamboj@pogo.udel.edu +14 -36 + Moved some declarations to ntp_config.h + + ntpd/ntp_scanner.h@1.1, 2007-04-20 22:45:28-04:00, stenn@pogo.udel.edu +97 -0 + BitKeeper file /pogo/users/kamboj/new-config-bk-repo/ntpd/ntp_scanner.h + + ntpd/ntp_scanner.h@1.0, 2007-04-20 22:45:28-04:00, stenn@pogo.udel.edu +0 -0 + + ntpd/ntpsim.c@1.16, 2007-04-23 16:33:46+00:00, kamboj@pogo.udel.edu +6 -35 + Removed some old redundant comments + +ChangeSet@1.1440.1.90, 2007-04-22 07:42:54-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P26 + TAG: NTP_4_2_5P26 + + ntpd/ntpd-opts.c@1.13, 2007-04-22 07:42:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P26 + + ntpd/ntpd-opts.h@1.13, 2007-04-22 07:42:35-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P26 + + ntpd/ntpd-opts.texi@1.12, 2007-04-22 07:42:35-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P26 + + ntpd/ntpd.1@1.12, 2007-04-22 07:42:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P26 + + ntpd/ntpdsim-opts.c@1.13, 2007-04-22 07:42:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P26 + + ntpd/ntpdsim-opts.h@1.13, 2007-04-22 07:42:37-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P26 + + ntpd/ntpdsim-opts.texi@1.12, 2007-04-22 07:42:38-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P26 + + ntpd/ntpdsim.1@1.12, 2007-04-22 07:42:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P26 + + ntpdc/ntpdc-opts.c@1.13, 2007-04-22 07:42:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P26 + + ntpdc/ntpdc-opts.h@1.13, 2007-04-22 07:42:40-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P26 + + ntpdc/ntpdc-opts.texi@1.12, 2007-04-22 07:42:41-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P26 + + ntpdc/ntpdc.1@1.12, 2007-04-22 07:42:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P26 + + ntpq/ntpq-opts.c@1.13, 2007-04-22 07:42:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P26 + + ntpq/ntpq-opts.h@1.13, 2007-04-22 07:42:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P26 + + ntpq/ntpq-opts.texi@1.12, 2007-04-22 07:42:44-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P26 + + ntpq/ntpq.1@1.12, 2007-04-22 07:42:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P26 + + packageinfo.sh@1.29, 2007-04-22 07:42:46-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P26 + + sntp/sntp-opts.c@1.13, 2007-04-22 07:42:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P26 + + sntp/sntp-opts.h@1.13, 2007-04-22 07:42:47-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P26 + + sntp/sntp-opts.texi@1.12, 2007-04-22 07:42:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P26 + + sntp/sntp.1@1.12, 2007-04-22 07:42:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P26 + + util/ntp-keygen-opts.c@1.14, 2007-04-22 07:42:49-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P26 + + util/ntp-keygen-opts.h@1.14, 2007-04-22 07:42:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P26 + + util/ntp-keygen-opts.texi@1.13, 2007-04-22 07:42:50-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P26 + + util/ntp-keygen.1@1.13, 2007-04-22 07:42:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P26 + +ChangeSet@1.1440.1.89, 2007-04-21 13:13:03-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 812] ntpd should drop supplementary groups + + ChangeLog@1.30, 2007-04-21 13:12:44-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 812] ntpd should drop supplementary groups + +ChangeSet@1.1440.1.88, 2007-04-21 07:43:00-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P25 + TAG: NTP_4_2_5P25 + + ntpd/ntpd-opts.c@1.12, 2007-04-21 07:42:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P25 + + ntpd/ntpd-opts.h@1.12, 2007-04-21 07:42:40-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P25 + + ntpd/ntpd-opts.texi@1.11, 2007-04-21 07:42:41-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P25 + + ntpd/ntpd.1@1.11, 2007-04-21 07:42:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P25 + + ntpd/ntpdsim-opts.c@1.12, 2007-04-21 07:42:42-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P25 + + ntpd/ntpdsim-opts.h@1.12, 2007-04-21 07:42:43-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P25 + + ntpd/ntpdsim-opts.texi@1.11, 2007-04-21 07:42:44-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P25 + + ntpd/ntpdsim.1@1.11, 2007-04-21 07:42:45-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P25 + + ntpdc/ntpdc-opts.c@1.12, 2007-04-21 07:42:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P25 + + ntpdc/ntpdc-opts.h@1.12, 2007-04-21 07:42:46-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P25 + + ntpdc/ntpdc-opts.texi@1.11, 2007-04-21 07:42:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P25 + + ntpdc/ntpdc.1@1.11, 2007-04-21 07:42:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P25 + + ntpq/ntpq-opts.c@1.12, 2007-04-21 07:42:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P25 + + ntpq/ntpq-opts.h@1.12, 2007-04-21 07:42:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P25 + + ntpq/ntpq-opts.texi@1.11, 2007-04-21 07:42:49-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P25 + + ntpq/ntpq.1@1.11, 2007-04-21 07:42:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P25 + + packageinfo.sh@1.28, 2007-04-21 07:42:51-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P25 + + sntp/sntp-opts.c@1.12, 2007-04-21 07:42:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P25 + + sntp/sntp-opts.h@1.12, 2007-04-21 07:42:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P25 + + sntp/sntp-opts.texi@1.11, 2007-04-21 07:42:52-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P25 + + sntp/sntp.1@1.11, 2007-04-21 07:42:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P25 + + util/ntp-keygen-opts.c@1.13, 2007-04-21 07:42:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P25 + + util/ntp-keygen-opts.h@1.13, 2007-04-21 07:42:55-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P25 + + util/ntp-keygen-opts.texi@1.12, 2007-04-21 07:42:56-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P25 + + util/ntp-keygen.1@1.12, 2007-04-21 07:42:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P25 + +ChangeSet@1.1440.1.87, 2007-04-21 01:14:37-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 812] ntpd should drop supplementary groups + + ntpd/ntpd.c@1.83.1.3, 2007-04-21 01:14:24-04:00, stenn@whimsy.udel.edu +24 -2 + [Bug 812] ntpd should drop supplementary groups + +ChangeSet@1.1453, 2007-04-20 16:18:30+00:00, kamboj@pogo.udel.edu +3 -0 + Minor Bugfixes + + include/ntp_config.h@1.43, 2007-04-20 16:18:27+00:00, kamboj@pogo.udel.edu +1 -1 + A minor bugfix to make a prototype ANSI C compliant + + ntpd/ntp_config.c@1.145, 2007-04-20 16:18:27+00:00, kamboj@pogo.udel.edu +5 -3 + Minor bugfixes + + ntpd/ntp_config.tab.c@1.2, 2007-04-20 16:18:27+00:00, kamboj@pogo.udel.edu +1193 -984 + Added minor bugfixes to ntp_config.y + +ChangeSet@1.1440.1.86, 2007-04-20 07:42:36-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P24 + TAG: NTP_4_2_5P24 + + ntpd/ntpd-opts.c@1.11, 2007-04-20 07:42:14-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P24 + + ntpd/ntpd-opts.h@1.11, 2007-04-20 07:42:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P24 + + ntpd/ntpd-opts.texi@1.10, 2007-04-20 07:42:15-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P24 + + ntpd/ntpd.1@1.10, 2007-04-20 07:42:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P24 + + ntpd/ntpdsim-opts.c@1.11, 2007-04-20 07:42:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P24 + + ntpd/ntpdsim-opts.h@1.11, 2007-04-20 07:42:17-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P24 + + ntpd/ntpdsim-opts.texi@1.10, 2007-04-20 07:42:18-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P24 + + ntpd/ntpdsim.1@1.10, 2007-04-20 07:42:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P24 + + ntpdc/ntpdc-opts.c@1.11, 2007-04-20 07:42:20-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P24 + + ntpdc/ntpdc-opts.h@1.11, 2007-04-20 07:42:21-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P24 + + ntpdc/ntpdc-opts.texi@1.10, 2007-04-20 07:42:22-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P24 + + ntpdc/ntpdc.1@1.10, 2007-04-20 07:42:22-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P24 + + ntpq/ntpq-opts.c@1.11, 2007-04-20 07:42:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P24 + + ntpq/ntpq-opts.h@1.11, 2007-04-20 07:42:24-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P24 + + ntpq/ntpq-opts.texi@1.10, 2007-04-20 07:42:24-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P24 + + ntpq/ntpq.1@1.10, 2007-04-20 07:42:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P24 + + packageinfo.sh@1.27, 2007-04-20 07:42:26-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P24 + + sntp/sntp-opts.c@1.11, 2007-04-20 07:42:26-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P24 + + sntp/sntp-opts.h@1.11, 2007-04-20 07:42:27-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P24 + + sntp/sntp-opts.texi@1.10, 2007-04-20 07:42:27-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P24 + + sntp/sntp.1@1.10, 2007-04-20 07:42:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P24 + + util/ntp-keygen-opts.c@1.12, 2007-04-20 07:42:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P24 + + util/ntp-keygen-opts.h@1.12, 2007-04-20 07:42:29-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P24 + + util/ntp-keygen-opts.texi@1.11, 2007-04-20 07:42:30-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P24 + + util/ntp-keygen.1@1.11, 2007-04-20 07:42:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P24 + +ChangeSet@1.1440.1.85, 2007-04-20 01:04:24-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 815] Fix warning compiling 4.2.5p22 under Windows with VC6 + + ChangeLog@1.29, 2007-04-20 01:04:05-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 815] Fix warning compiling 4.2.5p22 under Windows with VC6 + +ChangeSet@1.1440.1.84, 2007-04-20 00:56:48-04:00, stenn@whimsy.udel.edu +1 -0 + Fix permissions of sntp/sntp-opts.menu + + sntp/sntp-opts.menu@1.3, 2007-04-20 00:55:50-04:00, stenn@whimsy.udel.edu +0 -0 + Change mode to -rw-rw-r-- + +ChangeSet@1.1440.1.83, 2007-04-18 12:53:10+00:00, burnicki@pogo.udel.edu +1 -0 + [Bug #815] Define HAVE_UINTPTR_T under Windows to avoid duplicate definition elsewhere. + + ports/winnt/include/config.h@1.48, 2007-04-18 12:53:08+00:00, burnicki@pogo.udel.edu +2 -0 + [Bug #815] Define HAVE_UINTPTR_T under Windows to avoid duplicate definition elsewhere. + +ChangeSet@1.1440.1.82, 2007-04-18 08:18:53-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P23 + TAG: NTP_4_2_5P23 + + ntpd/ntpd-opts.c@1.10, 2007-04-18 08:18:18-04:00, stenn@whimsy.udel.edu +7 -50 + NTP_4_2_5P23 + + ntpd/ntpd-opts.h@1.10, 2007-04-18 08:18:20-04:00, stenn@whimsy.udel.edu +5 -13 + NTP_4_2_5P23 + + ntpd/ntpd-opts.texi@1.9, 2007-04-18 08:18:21-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P23 + + ntpd/ntpd.1@1.9, 2007-04-18 08:18:22-04:00, stenn@whimsy.udel.edu +3 -19 + NTP_4_2_5P23 + + ntpd/ntpdsim-opts.c@1.10, 2007-04-18 08:18:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P23 + + ntpd/ntpdsim-opts.h@1.10, 2007-04-18 08:18:23-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P23 + + ntpd/ntpdsim-opts.texi@1.9, 2007-04-18 08:18:24-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P23 + + ntpd/ntpdsim.1@1.9, 2007-04-18 08:18:25-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P23 + + ntpdc/ntpdc-opts.c@1.10, 2007-04-18 08:18:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P23 + + ntpdc/ntpdc-opts.h@1.10, 2007-04-18 08:18:28-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P23 + + ntpdc/ntpdc-opts.texi@1.9, 2007-04-18 08:18:28-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P23 + + ntpdc/ntpdc.1@1.9, 2007-04-18 08:18:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P23 + + ntpq/ntpq-opts.c@1.10, 2007-04-18 08:18:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P23 + + ntpq/ntpq-opts.h@1.10, 2007-04-18 08:18:33-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P23 + + ntpq/ntpq-opts.texi@1.9, 2007-04-18 08:18:34-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P23 + + ntpq/ntpq.1@1.9, 2007-04-18 08:18:35-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P23 + + packageinfo.sh@1.26, 2007-04-18 08:18:36-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P23 + + sntp/sntp-opts.c@1.10, 2007-04-18 08:18:36-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P23 + + sntp/sntp-opts.h@1.10, 2007-04-18 08:18:37-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P23 + + sntp/sntp-opts.texi@1.9, 2007-04-18 08:18:39-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P23 + + sntp/sntp.1@1.9, 2007-04-18 08:18:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P23 + + util/ntp-keygen-opts.c@1.11, 2007-04-18 08:18:40-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P23 + + util/ntp-keygen-opts.h@1.11, 2007-04-18 08:18:41-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P23 + + util/ntp-keygen-opts.texi@1.10, 2007-04-18 08:18:42-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P23 + + util/ntp-keygen.1@1.10, 2007-04-18 08:18:43-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P23 + +ChangeSet@1.1440.5.1, 2007-04-18 06:05:04-04:00, stenn@deacon.udel.edu +5 -0 + [Bug 740] Fix kernel/daemon startup drift anomaly + + ChangeLog@1.26.1.1, 2007-04-18 06:04:15-04:00, stenn@deacon.udel.edu +1 -0 + [Bug 740] Fix kernel/daemon startup drift anomaly + + conf/beauregard.conf@1.3, 2007-04-18 05:53:47-04:00, stenn@deacon.udel.edu +1 -1 + fix a typo in a comment line + + ntpd/cmd_args.c@1.45.2.1, 2007-04-18 06:04:21-04:00, stenn@deacon.udel.edu +3 -2 + [Bug 740] Fix kernel/daemon startup drift anomaly + + ntpd/ntp_loopfilter.c@1.133, 2007-04-18 06:04:22-04:00, stenn@deacon.udel.edu +4 -4 + [Bug 740] Fix kernel/daemon startup drift anomaly + + ntpd/ntp_proto.c@1.251, 2007-04-18 06:04:22-04:00, stenn@deacon.udel.edu +0 -8 + [Bug 740] Fix kernel/daemon startup drift anomaly + +ChangeSet@1.1436.1.44, 2007-04-14 19:05:07-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_4P2_RC1 + TAG: NTP_4_2_4P2_RC1 + + ntpd/ntpd-opts.c@1.50.2.3, 2007-04-14 19:04:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC1 + + ntpd/ntpd-opts.h@1.50.2.3, 2007-04-14 19:04:46-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC1 + + ntpd/ntpd-opts.texi@1.49.2.3, 2007-04-14 19:04:47-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC1 + + ntpd/ntpd.1@1.48.2.3, 2007-04-14 19:04:47-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC1 + + ntpd/ntpdsim-opts.c@1.50.2.3, 2007-04-14 19:04:48-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC1 + + ntpd/ntpdsim-opts.h@1.50.2.3, 2007-04-14 19:04:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC1 + + ntpd/ntpdsim-opts.texi@1.48.2.3, 2007-04-14 19:04:50-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC1 + + ntpd/ntpdsim.1@1.48.2.3, 2007-04-14 19:04:50-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC1 + + ntpdc/ntpdc-opts.c@1.50.2.3, 2007-04-14 19:04:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC1 + + ntpdc/ntpdc-opts.h@1.50.2.3, 2007-04-14 19:04:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC1 + + ntpdc/ntpdc-opts.texi@1.48.2.3, 2007-04-14 19:04:52-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC1 + + ntpdc/ntpdc.1@1.48.2.3, 2007-04-14 19:04:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC1 + + ntpq/ntpq-opts.c@1.52.2.3, 2007-04-14 19:04:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC1 + + ntpq/ntpq-opts.h@1.52.2.3, 2007-04-14 19:04:55-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC1 + + ntpq/ntpq-opts.texi@1.49.2.3, 2007-04-14 19:04:55-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC1 + + ntpq/ntpq.1@1.48.2.3, 2007-04-14 19:04:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC1 + + packageinfo.sh@1.65.8.4, 2007-04-14 19:04:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC1 + + sntp/sntp-opts.c@1.49.2.2, 2007-04-14 19:04:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC1 + + sntp/sntp-opts.h@1.49.2.2, 2007-04-14 19:04:58-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC1 + + sntp/sntp-opts.texi@1.46.2.2, 2007-04-14 19:04:59-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC1 + + sntp/sntp.1@1.49.2.2, 2007-04-14 19:04:59-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC1 + + util/ntp-keygen-opts.c@1.49.2.3, 2007-04-14 19:05:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC1 + + util/ntp-keygen-opts.h@1.49.2.3, 2007-04-14 19:05:01-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P2_RC1 + + util/ntp-keygen-opts.texi@1.47.2.3, 2007-04-14 19:05:02-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P2_RC1 + + util/ntp-keygen.1@1.47.2.3, 2007-04-14 19:05:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P2_RC1 + +ChangeSet@1.1436.1.43, 2007-04-14 18:16:04-04:00, stenn@deacon.udel.edu +2 -0 + Distribute include/homerc.def + + include/Makefile.am@1.24.1.1, 2007-04-14 18:15:53-04:00, stenn@deacon.udel.edu +1 -1 + Distribute include/homerc.def + + packageinfo.sh@1.65.8.3, 2007-04-14 18:14:54-04:00, stenn@deacon.udel.edu +1 -1 + restart the RC + +ChangeSet@1.1436.1.42, 2007-04-14 07:53:43-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_4P1_RC1 + TAG: NTP_4_2_4P1_RC1 + + ntpd/ntpd-opts.c@1.50.2.2, 2007-04-14 07:53:21-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P1_RC1 + + ntpd/ntpd-opts.h@1.50.2.2, 2007-04-14 07:53:21-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P1_RC1 + + ntpd/ntpd-opts.texi@1.49.2.2, 2007-04-14 07:53:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P1_RC1 + + ntpd/ntpd.1@1.48.2.2, 2007-04-14 07:53:23-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P1_RC1 + + ntpd/ntpdsim-opts.c@1.50.2.2, 2007-04-14 07:53:24-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P1_RC1 + + ntpd/ntpdsim-opts.h@1.50.2.2, 2007-04-14 07:53:25-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P1_RC1 + + ntpd/ntpdsim-opts.texi@1.48.2.2, 2007-04-14 07:53:26-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P1_RC1 + + ntpd/ntpdsim.1@1.48.2.2, 2007-04-14 07:53:27-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P1_RC1 + + ntpdc/ntpdc-opts.c@1.50.2.2, 2007-04-14 07:53:28-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P1_RC1 + + ntpdc/ntpdc-opts.h@1.50.2.2, 2007-04-14 07:53:29-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P1_RC1 + + ntpdc/ntpdc-opts.texi@1.48.2.2, 2007-04-14 07:53:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P1_RC1 + + ntpdc/ntpdc.1@1.48.2.2, 2007-04-14 07:53:30-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P1_RC1 + + ntpq/ntpq-opts.c@1.52.2.2, 2007-04-14 07:53:31-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P1_RC1 + + ntpq/ntpq-opts.h@1.52.2.2, 2007-04-14 07:53:32-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P1_RC1 + + ntpq/ntpq-opts.texi@1.49.2.2, 2007-04-14 07:53:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P1_RC1 + + ntpq/ntpq.1@1.48.2.2, 2007-04-14 07:53:33-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P1_RC1 + + packageinfo.sh@1.65.8.2, 2007-04-14 07:53:34-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P1_RC1 + + sntp/sntp-opts.c@1.49.2.1, 2007-04-14 07:53:35-04:00, stenn@whimsy.udel.edu +8 -7 + NTP_4_2_4P1_RC1 + + sntp/sntp-opts.h@1.49.2.1, 2007-04-14 07:53:35-04:00, stenn@whimsy.udel.edu +8 -14 + NTP_4_2_4P1_RC1 + + sntp/sntp-opts.texi@1.46.2.1, 2007-04-14 07:53:36-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P1_RC1 + + sntp/sntp.1@1.49.2.1, 2007-04-14 07:53:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P1_RC1 + + util/ntp-keygen-opts.c@1.49.2.2, 2007-04-14 07:53:37-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P1_RC1 + + util/ntp-keygen-opts.h@1.49.2.2, 2007-04-14 07:53:38-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P1_RC1 + + util/ntp-keygen-opts.texi@1.47.2.2, 2007-04-14 07:53:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P1_RC1 + + util/ntp-keygen.1@1.47.2.2, 2007-04-14 07:53:39-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P1_RC1 + +ChangeSet@1.1436.1.41, 2007-04-14 05:13:18-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 811] ntpd should not read a .ntprc file + + ChangeLog@1.1.1.10, 2007-04-14 05:12:51-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 811] ntpd should not read a .ntprc file + +ChangeSet@1.1436.1.40, 2007-04-14 04:47:21-04:00, stenn@whimsy.udel.edu +1 -0 + start an RC cycle + + packageinfo.sh@1.65.8.1, 2007-04-14 04:47:01-04:00, stenn@whimsy.udel.edu +2 -2 + start an RC cycle + +ChangeSet@1.1436.1.39, 2007-04-14 02:38:03-04:00, stenn@whimsy.udel.edu +32 -0 + [Bug 811] ntpd should not read a .ntprc file + + clockstuff/Makefile.am@1.5.1.1, 2007-04-14 02:35:13-04:00, stenn@whimsy.udel.edu +1 -1 + [Bug 811] ntpd should not read a .ntprc file + + clockstuff/clktest-opts.def@1.5, 2007-04-14 02:35:14-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 811] ntpd should not read a .ntprc file + + include/copyright.def@1.4, 2007-04-14 02:35:14-04:00, stenn@whimsy.udel.edu +0 -7 + [Bug 811] ntpd should not read a .ntprc file + + include/homerc.def@1.1, 2007-04-14 01:19:52-04:00, stenn@whimsy.udel.edu +9 -0 + BitKeeper file /deacon/backroom/ntp-stable/include/homerc.def + + include/homerc.def@1.0, 2007-04-14 01:19:52-04:00, stenn@whimsy.udel.edu +0 -0 + + ntpd/Makefile.am@1.52.2.1, 2007-04-14 02:35:14-04:00, stenn@whimsy.udel.edu +3 -3 + [Bug 811] ntpd should not read a .ntprc file + + ntpd/ntpd-opts.c@1.50.2.1, 2007-04-14 02:36:43-04:00, stenn@whimsy.udel.edu +12 -54 + [Bug 811] ntpd should not read a .ntprc file + + ntpd/ntpd-opts.h@1.50.2.1, 2007-04-14 02:36:44-04:00, stenn@whimsy.udel.edu +8 -22 + [Bug 811] ntpd should not read a .ntprc file + + ntpd/ntpd-opts.texi@1.49.2.1, 2007-04-14 02:36:44-04:00, stenn@whimsy.udel.edu +3 -3 + [Bug 811] ntpd should not read a .ntprc file + + ntpd/ntpd.1@1.48.2.1, 2007-04-14 02:36:45-04:00, stenn@whimsy.udel.edu +3 -19 + [Bug 811] ntpd should not read a .ntprc file + + ntpd/ntpdsim-opts.c@1.50.2.1, 2007-04-14 02:36:46-04:00, stenn@whimsy.udel.edu +7 -6 + [Bug 811] ntpd should not read a .ntprc file + + ntpd/ntpdsim-opts.def@1.6, 2007-04-14 02:35:15-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 811] ntpd should not read a .ntprc file + + ntpd/ntpdsim-opts.h@1.50.2.1, 2007-04-14 02:36:46-04:00, stenn@whimsy.udel.edu +6 -12 + [Bug 811] ntpd should not read a .ntprc file + + ntpd/ntpdsim-opts.texi@1.48.2.1, 2007-04-14 02:36:47-04:00, stenn@whimsy.udel.edu +1 -1 + [Bug 811] ntpd should not read a .ntprc file + + ntpd/ntpdsim.1@1.48.2.1, 2007-04-14 02:36:48-04:00, stenn@whimsy.udel.edu +2 -2 + [Bug 811] ntpd should not read a .ntprc file + + ntpdc/Makefile.am@1.33.1.1, 2007-04-14 02:35:15-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 811] ntpd should not read a .ntprc file + + ntpdc/ntpdc-opts.c@1.50.2.1, 2007-04-14 02:36:48-04:00, stenn@whimsy.udel.edu +7 -6 + [Bug 811] ntpd should not read a .ntprc file + + ntpdc/ntpdc-opts.def@1.13, 2007-04-14 02:35:16-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 811] ntpd should not read a .ntprc file + + ntpdc/ntpdc-opts.h@1.50.2.1, 2007-04-14 02:36:49-04:00, stenn@whimsy.udel.edu +6 -12 + [Bug 811] ntpd should not read a .ntprc file + + ntpdc/ntpdc-opts.texi@1.48.2.1, 2007-04-14 02:36:50-04:00, stenn@whimsy.udel.edu +3 -3 + [Bug 811] ntpd should not read a .ntprc file + + ntpdc/ntpdc.1@1.48.2.1, 2007-04-14 02:36:51-04:00, stenn@whimsy.udel.edu +2 -2 + [Bug 811] ntpd should not read a .ntprc file + + ntpq/Makefile.am@1.25.1.1, 2007-04-14 02:35:16-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 811] ntpd should not read a .ntprc file + + ntpq/ntpq-opts.c@1.52.2.1, 2007-04-14 02:36:52-04:00, stenn@whimsy.udel.edu +7 -6 + [Bug 811] ntpd should not read a .ntprc file + + ntpq/ntpq-opts.def@1.12, 2007-04-14 02:35:16-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 811] ntpd should not read a .ntprc file + + ntpq/ntpq-opts.h@1.52.2.1, 2007-04-14 02:36:53-04:00, stenn@whimsy.udel.edu +6 -12 + [Bug 811] ntpd should not read a .ntprc file + + ntpq/ntpq-opts.texi@1.49.2.1, 2007-04-14 02:36:53-04:00, stenn@whimsy.udel.edu +3 -3 + [Bug 811] ntpd should not read a .ntprc file + + ntpq/ntpq.1@1.48.2.1, 2007-04-14 02:36:54-04:00, stenn@whimsy.udel.edu +2 -2 + [Bug 811] ntpd should not read a .ntprc file + + util/Makefile.am@1.34.1.1, 2007-04-14 02:35:17-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 811] ntpd should not read a .ntprc file + + util/ntp-keygen-opts.c@1.49.2.1, 2007-04-14 02:36:55-04:00, stenn@whimsy.udel.edu +7 -6 + [Bug 811] ntpd should not read a .ntprc file + + util/ntp-keygen-opts.def@1.6.1.1, 2007-04-14 02:35:18-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 811] ntpd should not read a .ntprc file + + util/ntp-keygen-opts.h@1.49.2.1, 2007-04-14 02:36:55-04:00, stenn@whimsy.udel.edu +6 -12 + [Bug 811] ntpd should not read a .ntprc file + + util/ntp-keygen-opts.texi@1.47.2.1, 2007-04-14 02:36:56-04:00, stenn@whimsy.udel.edu +3 -3 + [Bug 811] ntpd should not read a .ntprc file + + util/ntp-keygen.1@1.47.2.1, 2007-04-14 02:36:57-04:00, stenn@whimsy.udel.edu +2 -2 + [Bug 811] ntpd should not read a .ntprc file + +ChangeSet@1.1436.1.38, 2007-04-14 01:11:33-04:00, stenn@whimsy.udel.edu +166 -0 + autogen/libopts upgrade + + BitKeeper/deleted/.del-COPYING.lgpl@1.2.1.1, 2007-04-13 18:58:46-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/COPYING.lgpl + + BitKeeper/deleted/.del-COPYING.lgpl~54a90ba0899593cb@1.1.1.1, 2007-04-13 19:05:57-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/COPYING.lgpl + + BitKeeper/deleted/.del-COPYING.mbsd@1.1.1.1, 2007-04-13 18:58:48-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/COPYING.mbsd + + BitKeeper/deleted/.del-COPYING.mbsd~9b1945bb2136c70b@1.1.1.1, 2007-04-13 19:05:59-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/COPYING.mbsd + + BitKeeper/deleted/.del-MakeDefs.inc@1.1.1.1, 2007-04-13 18:58:49-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/MakeDefs.inc + + BitKeeper/deleted/.del-MakeDefs.inc~2b8fdfc9df6d652d@1.1.1.1, 2007-04-13 19:06:00-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/MakeDefs.inc + + BitKeeper/deleted/.del-Makefile.am@1.6.1.1, 2007-04-13 18:58:50-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/Makefile.am + + BitKeeper/deleted/.del-Makefile.am~fa9bd87b6045015c@1.4.1.1, 2007-04-13 19:06:01-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/Makefile.am + + BitKeeper/deleted/.del-README@1.1.1.1, 2007-04-13 18:58:51-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/README + + BitKeeper/deleted/.del-README~1ae087758ee867d4@1.1.1.1, 2007-04-13 19:06:02-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/README + + BitKeeper/deleted/.del-autoopts.c@1.10.1.1, 2007-04-13 18:58:52-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.c~5b417341bc85d7a8@1.7.1.1, 2007-04-13 19:06:03-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.h@1.9.1.1, 2007-04-13 18:58:53-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/autoopts.h + + BitKeeper/deleted/.del-autoopts.h~8cdce21b181a1a01@1.7.1.1, 2007-04-13 19:06:05-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts.h + + BitKeeper/deleted/.del-boolean.c@1.8.1.1, 2007-04-13 18:58:54-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/boolean.c + + BitKeeper/deleted/.del-boolean.c~a5d10c8997e6a2e2@1.5.1.1, 2007-04-13 19:06:06-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/boolean.c + + BitKeeper/deleted/.del-compat.h@1.12.1.1, 2007-04-13 19:04:47-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/compat.h + + BitKeeper/deleted/.del-compat.h~9682d0ac273ae32@1.8.1.1, 2007-04-13 19:06:50-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/compat.h + + BitKeeper/deleted/.del-configfile.c@1.10.1.1, 2007-04-13 18:58:56-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/configfile.c + + BitKeeper/deleted/.del-configfile.c~8194f784686fa804@1.7.1.1, 2007-04-13 19:06:07-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/configfile.c + + BitKeeper/deleted/.del-cook.c@1.9.1.1, 2007-04-13 18:58:57-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/cook.c + + BitKeeper/deleted/.del-cook.c~e48d079a438432dc@1.6.1.1, 2007-04-13 19:06:08-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/cook.c + + BitKeeper/deleted/.del-enumeration.c@1.9.1.1, 2007-04-13 18:58:59-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/enumeration.c + + BitKeeper/deleted/.del-enumeration.c~5f4e6af2706370ae@1.6.1.1, 2007-04-13 19:06:10-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/enumeration.c + + BitKeeper/deleted/.del-environment.c@1.8.1.1, 2007-04-13 18:59:00-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/environment.c + + BitKeeper/deleted/.del-environment.c~2bae2966695067c2@1.5.1.1, 2007-04-13 19:06:11-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/environment.c + + BitKeeper/deleted/.del-genshell.c@1.9.1.1, 2007-04-13 18:59:01-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/genshell.c + + BitKeeper/deleted/.del-genshell.c~1fd152b2b52bdab@1.6.1.1, 2007-04-13 19:06:12-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/genshell.c + + BitKeeper/deleted/.del-genshell.h@1.9.1.1, 2007-04-13 18:59:02-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/genshell.h + + BitKeeper/deleted/.del-genshell.h~375f0fa5b925f454@1.6.1.1, 2007-04-13 19:06:14-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/genshell.h + + BitKeeper/deleted/.del-libopts.c@1.3.1.1, 2007-04-13 18:59:04-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/libopts.c + + BitKeeper/deleted/.del-libopts.c~58b8fbed850e6d5e@1.3.1.1, 2007-04-13 19:06:15-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/libopts.c + + BitKeeper/deleted/.del-libopts.m4@1.14.1.1, 2007-04-13 19:04:54-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-libopts.m4~9e0f33f57d3a0a9@1.11.1.1, 2007-04-13 19:06:56-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-liboptschk.m4@1.3.1.1, 2007-04-13 19:04:55-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-liboptschk.m4~bbeebebe76865058@1.3.1.1, 2007-04-13 19:06:58-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-libtool.m4@1.1.1.1, 2007-04-13 19:04:57-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/m4/libtool.m4 + + BitKeeper/deleted/.del-libtool.m4~db8acbd0fb34597f@1.1.1.1, 2007-04-13 19:07:00-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/m4/libtool.m4 + + BitKeeper/deleted/.del-load.c@1.10.1.1, 2007-04-13 18:59:05-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/load.c + + BitKeeper/deleted/.del-load.c~59960aa12bb95bf7@1.7.1.1, 2007-04-13 19:06:16-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/load.c + + BitKeeper/deleted/.del-makeshell.c@1.11.1.1, 2007-04-13 18:59:06-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/makeshell.c + + BitKeeper/deleted/.del-makeshell.c~4fcd12fc31c0a4a4@1.8.1.1, 2007-04-13 19:06:18-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/makeshell.c + + BitKeeper/deleted/.del-nested.c@1.9.1.1, 2007-04-13 18:59:07-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/nested.c + + BitKeeper/deleted/.del-nested.c~85346d5d12098689@1.6.1.1, 2007-04-13 19:06:19-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/nested.c + + BitKeeper/deleted/.del-numeric.c@1.9.1.1, 2007-04-13 18:59:08-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/numeric.c + + BitKeeper/deleted/.del-numeric.c~cdb7deb5cf6f27c2@1.6.1.1, 2007-04-13 19:06:21-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/numeric.c + + BitKeeper/deleted/.del-options.h@1.10.1.1, 2007-04-13 19:04:44-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/autoopts/options.h + + BitKeeper/deleted/.del-options.h~6eb465cb95a56bee@1.7.1.1, 2007-04-13 19:06:45-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts/options.h + + BitKeeper/deleted/.del-pathfind.c@1.9.1.1, 2007-04-13 19:04:49-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pathfind.c~a0863179d884d4a4@1.6.1.1, 2007-04-13 19:06:51-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pgusage.c@1.9.1.1, 2007-04-13 18:59:09-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/pgusage.c + + BitKeeper/deleted/.del-pgusage.c~d981c42eb301cfdd@1.5.1.1, 2007-04-13 19:06:22-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/pgusage.c + + BitKeeper/deleted/.del-proto.h@1.11.1.1, 2007-04-13 18:59:11-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/proto.h + + BitKeeper/deleted/.del-proto.h~fa076f6dd9d0667e@1.8.1.1, 2007-04-13 19:06:23-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/proto.h + + BitKeeper/deleted/.del-putshell.c@1.10.1.1, 2007-04-13 18:59:12-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/putshell.c + + BitKeeper/deleted/.del-putshell.c~24959f5e1ba688e6@1.7.1.1, 2007-04-13 19:06:24-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/putshell.c + + BitKeeper/deleted/.del-restore.c@1.9.1.1, 2007-04-13 18:59:13-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/restore.c + + BitKeeper/deleted/.del-restore.c~eada4acbf21cd8bf@1.5.1.1, 2007-04-13 19:06:26-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/restore.c + + BitKeeper/deleted/.del-save.c@1.10.1.1, 2007-04-13 18:59:15-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/save.c + + BitKeeper/deleted/.del-save.c~a29f5bd429a568bb@1.7.1.1, 2007-04-13 19:06:27-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/save.c + + BitKeeper/deleted/.del-snprintf.c@1.4.1.1, 2007-04-13 19:04:50-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/snprintf.c + + BitKeeper/deleted/.del-snprintf.c~66578c716014cd3d@1.3.1.1, 2007-04-13 19:06:52-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/snprintf.c + + BitKeeper/deleted/.del-sort.c@1.8.1.1, 2007-04-13 18:59:16-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/sort.c + + BitKeeper/deleted/.del-sort.c~bec5a7fb6a01a5dc@1.4.1.1, 2007-04-13 19:06:28-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/sort.c + + BitKeeper/deleted/.del-stack.c@1.10.1.1, 2007-04-13 18:59:17-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/stack.c + + BitKeeper/deleted/.del-stack.c~e817b57b18b315c1@1.7.1.1, 2007-04-13 19:06:29-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/stack.c + + BitKeeper/deleted/.del-strchr.c@1.3.1.1, 2007-04-13 19:04:51-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/strchr.c + + BitKeeper/deleted/.del-strchr.c~80e88afbe7e2209a@1.3.1.1, 2007-04-13 19:06:53-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/strchr.c + + BitKeeper/deleted/.del-strdup.c@1.3.1.1, 2007-04-13 19:04:52-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/strdup.c + + BitKeeper/deleted/.del-strdup.c~1f262be5e55c3c4a@1.2.1.1, 2007-04-13 19:06:54-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/strdup.c + + BitKeeper/deleted/.del-streqvcmp.c@1.9.1.1, 2007-04-13 18:59:19-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/streqvcmp.c + + BitKeeper/deleted/.del-streqvcmp.c~66420c6082b06827@1.6.1.1, 2007-04-13 19:06:31-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/streqvcmp.c + + BitKeeper/deleted/.del-text_mmap.c@1.8.1.1, 2007-04-13 18:59:20-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/text_mmap.c + + BitKeeper/deleted/.del-text_mmap.c~f1915a52b87816ba@1.5.1.1, 2007-04-13 19:06:32-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/text_mmap.c + + BitKeeper/deleted/.del-tokenize.c@1.5.1.1, 2007-04-13 18:59:21-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/tokenize.c + + BitKeeper/deleted/.del-tokenize.c~ae2f23dbb2bee589@1.4.1.1, 2007-04-13 19:06:33-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/tokenize.c + + BitKeeper/deleted/.del-usage-txt.h@1.9.1.1, 2007-04-13 19:04:46-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage-txt.h~6ce4dce87430d1b@1.6.1.1, 2007-04-13 19:06:47-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage.c@1.9.1.1, 2007-04-13 18:59:22-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/usage.c + + BitKeeper/deleted/.del-usage.c~c868ef1e661a6eb1@1.7.1.1, 2007-04-13 19:06:34-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/usage.c + + BitKeeper/deleted/.del-version.c@1.9.1.1, 2007-04-13 18:59:24-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/version.c + + BitKeeper/deleted/.del-version.c~a426e6b58b20d06@1.6.1.1, 2007-04-13 19:06:35-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/version.c + + BitKeeper/deleted/.del-windows-config.h@1.5.1.1, 2007-04-13 19:04:53-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/windows-config.h + + BitKeeper/deleted/.del-windows-config.h~36f7ad2ccf764ad2@1.3.1.1, 2007-04-13 19:06:56-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/windows-config.h + + libopts/COPYING.lgpl@1.1, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +502 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/COPYING.lgpl + + libopts/COPYING.lgpl@1.0, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/COPYING.mbsd@1.1, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +26 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/COPYING.mbsd + + libopts/COPYING.mbsd@1.0, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/MakeDefs.inc@1.1, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/MakeDefs.inc + + libopts/MakeDefs.inc@1.0, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/Makefile.am@1.1, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +24 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/Makefile.am + + libopts/Makefile.am@1.0, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/README@1.1, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/README + + libopts/README@1.0, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/autoopts.c@1.1, 2007-04-13 19:10:06-04:00, stenn@whimsy.udel.edu +1101 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/autoopts.c + + libopts/autoopts.c@1.0, 2007-04-13 19:10:06-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/autoopts.h@1.1, 2007-04-13 19:10:06-04:00, stenn@whimsy.udel.edu +377 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/autoopts.h + + libopts/autoopts.h@1.0, 2007-04-13 19:10:06-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/autoopts/options.h@1.1, 2007-04-13 19:10:30-04:00, stenn@whimsy.udel.edu +964 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/autoopts/options.h + + libopts/autoopts/options.h@1.0, 2007-04-13 19:10:30-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/autoopts/usage-txt.h@1.1, 2007-04-13 19:10:31-04:00, stenn@whimsy.udel.edu +355 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/autoopts/usage-txt.h + + libopts/autoopts/usage-txt.h@1.0, 2007-04-13 19:10:31-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/boolean.c@1.1, 2007-04-13 19:10:07-04:00, stenn@whimsy.udel.edu +106 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/boolean.c + + libopts/boolean.c@1.0, 2007-04-13 19:10:07-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/compat.h@1.1, 2007-04-13 19:10:38-04:00, stenn@whimsy.udel.edu +314 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/compat.h + + libopts/compat/compat.h@1.0, 2007-04-13 19:10:38-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/pathfind.c@1.1, 2007-04-13 19:10:38-04:00, stenn@whimsy.udel.edu +339 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/pathfind.c + + libopts/compat/pathfind.c@1.0, 2007-04-13 19:10:38-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/snprintf.c@1.1, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/snprintf.c + + libopts/compat/snprintf.c@1.0, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/strchr.c@1.1, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/strchr.c + + libopts/compat/strchr.c@1.0, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/strdup.c@1.1, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +19 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/strdup.c + + libopts/compat/strdup.c@1.0, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/windows-config.h@1.1, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +129 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/windows-config.h + + libopts/compat/windows-config.h@1.0, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/configfile.c@1.1, 2007-04-13 19:10:07-04:00, stenn@whimsy.udel.edu +1288 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/configfile.c + + libopts/configfile.c@1.0, 2007-04-13 19:10:07-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/cook.c@1.1, 2007-04-13 19:10:08-04:00, stenn@whimsy.udel.edu +354 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/cook.c + + libopts/cook.c@1.0, 2007-04-13 19:10:08-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/enumeration.c@1.1, 2007-04-13 19:10:09-04:00, stenn@whimsy.udel.edu +498 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/enumeration.c + + libopts/enumeration.c@1.0, 2007-04-13 19:10:09-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/environment.c@1.1, 2007-04-13 19:10:09-04:00, stenn@whimsy.udel.edu +260 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/environment.c + + libopts/environment.c@1.0, 2007-04-13 19:10:09-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/genshell.c@1.1, 2007-04-13 19:10:10-04:00, stenn@whimsy.udel.edu +345 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/genshell.c + + libopts/genshell.c@1.0, 2007-04-13 19:10:10-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/genshell.h@1.1, 2007-04-13 19:10:10-04:00, stenn@whimsy.udel.edu +149 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/genshell.h + + libopts/genshell.h@1.0, 2007-04-13 19:10:10-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/libopts.c@1.1, 2007-04-13 19:10:10-04:00, stenn@whimsy.udel.edu +30 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/libopts.c + + libopts/libopts.c@1.0, 2007-04-13 19:10:10-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/load.c@1.1, 2007-04-13 19:10:11-04:00, stenn@whimsy.udel.edu +563 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/load.c + + libopts/load.c@1.0, 2007-04-13 19:10:11-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/m4/libopts.m4@1.1, 2007-04-13 19:10:43-04:00, stenn@whimsy.udel.edu +489 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/m4/libopts.m4 + + libopts/m4/libopts.m4@1.0, 2007-04-13 19:10:43-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/m4/liboptschk.m4@1.1, 2007-04-13 19:10:43-04:00, stenn@whimsy.udel.edu +42 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/m4/liboptschk.m4 + + libopts/m4/liboptschk.m4@1.0, 2007-04-13 19:10:43-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/makeshell.c@1.1, 2007-04-13 19:10:11-04:00, stenn@whimsy.udel.edu +1122 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/makeshell.c + + libopts/makeshell.c@1.0, 2007-04-13 19:10:11-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/nested.c@1.1, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +733 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/nested.c + + libopts/nested.c@1.0, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/numeric.c@1.1, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/numeric.c + + libopts/numeric.c@1.0, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/pgusage.c@1.1, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +157 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/pgusage.c + + libopts/pgusage.c@1.0, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/proto.h@1.1, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +91 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/proto.h + + libopts/proto.h@1.0, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/putshell.c@1.1, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +335 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/putshell.c + + libopts/putshell.c@1.0, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/restore.c@1.1, 2007-04-13 19:10:13-04:00, stenn@whimsy.udel.edu +250 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/restore.c + + libopts/restore.c@1.0, 2007-04-13 19:10:13-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/save.c@1.1, 2007-04-13 19:10:14-04:00, stenn@whimsy.udel.edu +512 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/save.c + + libopts/save.c@1.0, 2007-04-13 19:10:14-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/sort.c@1.1, 2007-04-13 19:10:14-04:00, stenn@whimsy.udel.edu +359 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/sort.c + + libopts/sort.c@1.0, 2007-04-13 19:10:14-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/stack.c@1.1, 2007-04-13 19:10:15-04:00, stenn@whimsy.udel.edu +269 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/stack.c + + libopts/stack.c@1.0, 2007-04-13 19:10:15-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/streqvcmp.c@1.1, 2007-04-13 19:10:15-04:00, stenn@whimsy.udel.edu +289 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/streqvcmp.c + + libopts/streqvcmp.c@1.0, 2007-04-13 19:10:15-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/text_mmap.c@1.1, 2007-04-13 19:10:16-04:00, stenn@whimsy.udel.edu +363 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/text_mmap.c + + libopts/text_mmap.c@1.0, 2007-04-13 19:10:16-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/tokenize.c@1.1, 2007-04-13 19:10:17-04:00, stenn@whimsy.udel.edu +321 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/tokenize.c + + libopts/tokenize.c@1.0, 2007-04-13 19:10:17-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/usage.c@1.1, 2007-04-13 19:10:17-04:00, stenn@whimsy.udel.edu +731 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/usage.c + + libopts/usage.c@1.0, 2007-04-13 19:10:17-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/version.c@1.1, 2007-04-13 19:10:18-04:00, stenn@whimsy.udel.edu +176 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/version.c + + libopts/version.c@1.0, 2007-04-13 19:10:18-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/COPYING.lgpl@1.1, 2007-04-13 19:09:02-04:00, stenn@whimsy.udel.edu +502 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/COPYING.lgpl + + sntp/libopts/COPYING.lgpl@1.0, 2007-04-13 19:09:02-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/COPYING.mbsd@1.1, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +26 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/COPYING.mbsd + + sntp/libopts/COPYING.mbsd@1.0, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/MakeDefs.inc@1.1, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/MakeDefs.inc + + sntp/libopts/MakeDefs.inc@1.0, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/Makefile.am@1.1, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +24 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/Makefile.am + + sntp/libopts/Makefile.am@1.0, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/README@1.1, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/README + + sntp/libopts/README@1.0, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/autoopts.c@1.1, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +1101 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/autoopts.c + + sntp/libopts/autoopts.c@1.0, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/autoopts.h@1.1, 2007-04-13 19:08:51-04:00, stenn@whimsy.udel.edu +377 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/autoopts.h + + sntp/libopts/autoopts.h@1.0, 2007-04-13 19:08:51-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/autoopts/options.h@1.1, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +964 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/autoopts/options.h + + sntp/libopts/autoopts/options.h@1.0, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/autoopts/usage-txt.h@1.1, 2007-04-13 19:08:49-04:00, stenn@whimsy.udel.edu +355 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/autoopts/usage-txt.h + + sntp/libopts/autoopts/usage-txt.h@1.0, 2007-04-13 19:08:49-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/boolean.c@1.1, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +106 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/boolean.c + + sntp/libopts/boolean.c@1.0, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/compat.h@1.1, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +314 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/compat.h + + sntp/libopts/compat/compat.h@1.0, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/pathfind.c@1.1, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +339 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/pathfind.c + + sntp/libopts/compat/pathfind.c@1.0, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/snprintf.c@1.1, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/snprintf.c + + sntp/libopts/compat/snprintf.c@1.0, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/strchr.c@1.1, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/strchr.c + + sntp/libopts/compat/strchr.c@1.0, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/strdup.c@1.1, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +19 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/strdup.c + + sntp/libopts/compat/strdup.c@1.0, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/windows-config.h@1.1, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +129 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/windows-config.h + + sntp/libopts/compat/windows-config.h@1.0, 2007-04-13 19:08:47-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/configfile.c@1.1, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +1288 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/configfile.c + + sntp/libopts/configfile.c@1.0, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/cook.c@1.1, 2007-04-13 19:08:53-04:00, stenn@whimsy.udel.edu +354 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/cook.c + + sntp/libopts/cook.c@1.0, 2007-04-13 19:08:53-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/enumeration.c@1.1, 2007-04-13 19:08:53-04:00, stenn@whimsy.udel.edu +498 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/enumeration.c + + sntp/libopts/enumeration.c@1.0, 2007-04-13 19:08:53-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/environment.c@1.1, 2007-04-13 19:08:54-04:00, stenn@whimsy.udel.edu +260 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/environment.c + + sntp/libopts/environment.c@1.0, 2007-04-13 19:08:54-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/genshell.c@1.1, 2007-04-13 19:08:55-04:00, stenn@whimsy.udel.edu +345 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/genshell.c + + sntp/libopts/genshell.c@1.0, 2007-04-13 19:08:55-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/genshell.h@1.1, 2007-04-13 19:08:51-04:00, stenn@whimsy.udel.edu +149 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/genshell.h + + sntp/libopts/genshell.h@1.0, 2007-04-13 19:08:51-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/libopts.c@1.1, 2007-04-13 19:08:50-04:00, stenn@whimsy.udel.edu +30 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/libopts.c + + sntp/libopts/libopts.c@1.0, 2007-04-13 19:08:50-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/load.c@1.1, 2007-04-13 19:08:55-04:00, stenn@whimsy.udel.edu +563 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/load.c + + sntp/libopts/load.c@1.0, 2007-04-13 19:08:55-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/m4/libopts.m4@1.1, 2007-04-13 19:08:50-04:00, stenn@whimsy.udel.edu +489 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/m4/libopts.m4 + + sntp/libopts/m4/libopts.m4@1.0, 2007-04-13 19:08:50-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/m4/liboptschk.m4@1.1, 2007-04-13 19:08:50-04:00, stenn@whimsy.udel.edu +42 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/m4/liboptschk.m4 + + sntp/libopts/m4/liboptschk.m4@1.0, 2007-04-13 19:08:50-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/makeshell.c@1.1, 2007-04-13 19:08:56-04:00, stenn@whimsy.udel.edu +1122 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/makeshell.c + + sntp/libopts/makeshell.c@1.0, 2007-04-13 19:08:56-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/nested.c@1.1, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +733 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/nested.c + + sntp/libopts/nested.c@1.0, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/numeric.c@1.1, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/numeric.c + + sntp/libopts/numeric.c@1.0, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/pgusage.c@1.1, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +157 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/pgusage.c + + sntp/libopts/pgusage.c@1.0, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/proto.h@1.1, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +91 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/proto.h + + sntp/libopts/proto.h@1.0, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/putshell.c@1.1, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +335 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/putshell.c + + sntp/libopts/putshell.c@1.0, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/restore.c@1.1, 2007-04-13 19:08:58-04:00, stenn@whimsy.udel.edu +250 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/restore.c + + sntp/libopts/restore.c@1.0, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/save.c@1.1, 2007-04-13 19:08:58-04:00, stenn@whimsy.udel.edu +512 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/save.c + + sntp/libopts/save.c@1.0, 2007-04-13 19:08:58-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/sort.c@1.1, 2007-04-13 19:08:59-04:00, stenn@whimsy.udel.edu +359 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/sort.c + + sntp/libopts/sort.c@1.0, 2007-04-13 19:08:59-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/stack.c@1.1, 2007-04-13 19:08:59-04:00, stenn@whimsy.udel.edu +269 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/stack.c + + sntp/libopts/stack.c@1.0, 2007-04-13 19:08:59-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/streqvcmp.c@1.1, 2007-04-13 19:09:00-04:00, stenn@whimsy.udel.edu +289 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/streqvcmp.c + + sntp/libopts/streqvcmp.c@1.0, 2007-04-13 19:09:00-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/text_mmap.c@1.1, 2007-04-13 19:09:01-04:00, stenn@whimsy.udel.edu +363 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/text_mmap.c + + sntp/libopts/text_mmap.c@1.0, 2007-04-13 19:09:01-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/tokenize.c@1.1, 2007-04-13 19:09:01-04:00, stenn@whimsy.udel.edu +321 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/tokenize.c + + sntp/libopts/tokenize.c@1.0, 2007-04-13 19:09:01-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/usage.c@1.1, 2007-04-13 19:09:02-04:00, stenn@whimsy.udel.edu +731 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/usage.c + + sntp/libopts/usage.c@1.0, 2007-04-13 19:09:02-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/version.c@1.1, 2007-04-13 19:09:02-04:00, stenn@whimsy.udel.edu +176 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/version.c + + sntp/libopts/version.c@1.0, 2007-04-13 19:09:02-04:00, stenn@whimsy.udel.edu +0 -0 + +ChangeSet@1.1440.1.79, 2007-04-13 07:42:22-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P22 + TAG: NTP_4_2_5P22 + + ntpd/ntpd-opts.c@1.9, 2007-04-13 07:42:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P22 + + ntpd/ntpd-opts.h@1.9, 2007-04-13 07:42:01-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P22 + + ntpd/ntpd-opts.texi@1.8, 2007-04-13 07:42:02-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P22 + + ntpd/ntpd.1@1.8, 2007-04-13 07:42:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P22 + + ntpd/ntpdsim-opts.c@1.9, 2007-04-13 07:42:03-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P22 + + ntpd/ntpdsim-opts.h@1.9, 2007-04-13 07:42:04-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P22 + + ntpd/ntpdsim-opts.texi@1.8, 2007-04-13 07:42:05-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P22 + + ntpd/ntpdsim.1@1.8, 2007-04-13 07:42:05-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P22 + + ntpdc/ntpdc-opts.c@1.9, 2007-04-13 07:42:06-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P22 + + ntpdc/ntpdc-opts.h@1.9, 2007-04-13 07:42:07-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P22 + + ntpdc/ntpdc-opts.texi@1.8, 2007-04-13 07:42:08-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P22 + + ntpdc/ntpdc.1@1.8, 2007-04-13 07:42:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P22 + + ntpq/ntpq-opts.c@1.9, 2007-04-13 07:42:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P22 + + ntpq/ntpq-opts.h@1.9, 2007-04-13 07:42:10-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P22 + + ntpq/ntpq-opts.texi@1.8, 2007-04-13 07:42:11-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P22 + + ntpq/ntpq.1@1.8, 2007-04-13 07:42:12-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P22 + + packageinfo.sh@1.25, 2007-04-13 07:42:13-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P22 + + sntp/sntp-opts.c@1.9, 2007-04-13 07:42:13-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P22 + + sntp/sntp-opts.h@1.9, 2007-04-13 07:42:14-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P22 + + sntp/sntp-opts.texi@1.8, 2007-04-13 07:42:14-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P22 + + sntp/sntp.1@1.8, 2007-04-13 07:42:15-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P22 + + util/ntp-keygen-opts.c@1.10, 2007-04-13 07:42:16-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P22 + + util/ntp-keygen-opts.h@1.10, 2007-04-13 07:42:17-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P22 + + util/ntp-keygen-opts.texi@1.9, 2007-04-13 07:42:18-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P22 + + util/ntp-keygen.1@1.9, 2007-04-13 07:42:19-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P22 + +ChangeSet@1.1440.1.78, 2007-04-13 03:57:20-04:00, stenn@whimsy.udel.edu +2 -0 + refclock_wwv.c fixes from Dave Mills + + ChangeLog@1.26, 2007-04-13 03:57:03-04:00, stenn@whimsy.udel.edu +1 -0 + refclock_wwv.c fixes from Dave Mills + + ntpd/refclock_wwv.c@1.71, 2007-04-13 03:57:03-04:00, stenn@whimsy.udel.edu +9 -7 + refclock_wwv.c fixes from Dave Mills + +ChangeSet@1.1440.1.77, 2007-04-13 02:10:55-04:00, stenn@whimsy.udel.edu +6 -0 + [Bug 810] Fix ntp-keygen documentation + + ChangeLog@1.25, 2007-04-13 02:06:37-04:00, stenn@whimsy.udel.edu +1 -0 + [Bug 810] Fix ntp-keygen documentation + + util/ntp-keygen-opts.c@1.9, 2007-04-13 02:09:53-04:00, stenn@whimsy.udel.edu +1 -1 + [Bug 810] Fix ntp-keygen documentation + + util/ntp-keygen-opts.def@1.7, 2007-04-13 02:06:46-04:00, stenn@whimsy.udel.edu +37 -20 + [Bug 810] Fix ntp-keygen documentation + + util/ntp-keygen-opts.h@1.9, 2007-04-13 02:09:55-04:00, stenn@whimsy.udel.edu +1 -1 + [Bug 810] Fix ntp-keygen documentation + + util/ntp-keygen-opts.texi@1.8, 2007-04-13 02:09:55-04:00, stenn@whimsy.udel.edu +39 -19 + [Bug 810] Fix ntp-keygen documentation + + util/ntp-keygen.1@1.8, 2007-04-13 02:09:56-04:00, stenn@whimsy.udel.edu +39 -19 + [Bug 810] Fix ntp-keygen documentation + +ChangeSet@1.1440.1.76, 2007-04-12 08:20:16-04:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P21 + TAG: NTP_4_2_5P21 + + ntpd/ntpd-opts.c@1.8, 2007-04-12 08:19:44-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P21 + + ntpd/ntpd-opts.h@1.8, 2007-04-12 08:19:45-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P21 + + ntpd/ntpd-opts.texi@1.7, 2007-04-12 08:19:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P21 + + ntpd/ntpd.1@1.7, 2007-04-12 08:19:46-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P21 + + ntpd/ntpdsim-opts.c@1.8, 2007-04-12 08:19:47-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P21 + + ntpd/ntpdsim-opts.h@1.8, 2007-04-12 08:19:49-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P21 + + ntpd/ntpdsim-opts.texi@1.7, 2007-04-12 08:19:50-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P21 + + ntpd/ntpdsim.1@1.7, 2007-04-12 08:19:51-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P21 + + ntpdc/ntpdc-opts.c@1.8, 2007-04-12 08:19:52-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P21 + + ntpdc/ntpdc-opts.h@1.8, 2007-04-12 08:19:52-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P21 + + ntpdc/ntpdc-opts.texi@1.7, 2007-04-12 08:19:53-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P21 + + ntpdc/ntpdc.1@1.7, 2007-04-12 08:19:54-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P21 + + ntpq/ntpq-opts.c@1.8, 2007-04-12 08:19:55-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P21 + + ntpq/ntpq-opts.h@1.8, 2007-04-12 08:19:56-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P21 + + ntpq/ntpq-opts.texi@1.7, 2007-04-12 08:19:56-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P21 + + ntpq/ntpq.1@1.7, 2007-04-12 08:19:57-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P21 + + packageinfo.sh@1.24, 2007-04-12 08:19:58-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P21 + + sntp/sntp-opts.c@1.8, 2007-04-12 08:19:58-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P21 + + sntp/sntp-opts.h@1.8, 2007-04-12 08:19:59-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P21 + + sntp/sntp-opts.texi@1.7, 2007-04-12 08:20:00-04:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P21 + + sntp/sntp.1@1.7, 2007-04-12 08:20:00-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P21 + + util/ntp-keygen-opts.c@1.8, 2007-04-12 08:20:05-04:00, stenn@whimsy.udel.edu +4 -4 + NTP_4_2_5P21 + + util/ntp-keygen-opts.h@1.8, 2007-04-12 08:20:07-04:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P21 + + util/ntp-keygen-opts.texi@1.7, 2007-04-12 08:20:08-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P21 + + util/ntp-keygen.1@1.7, 2007-04-12 08:20:09-04:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P21 + +ChangeSet@1.1436.1.37, 2007-04-12 06:32:19-04:00, stenn@whimsy.udel.edu +1 -0 + Added ntp2 mirror + + BitKeeper/triggers/2mirrors@1.4, 2007-04-12 06:30:59-04:00, stenn@whimsy.udel.edu +1 -0 + Added ntp2 mirror + +ChangeSet@1.1440.1.74, 2007-04-12 05:47:01-04:00, stenn@whimsy.udel.edu +180 -0 + autogen upgrade + + BitKeeper/deleted/.del-COPYING.lgpl@1.3, 2007-04-12 02:36:22-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/COPYING.lgpl + + BitKeeper/deleted/.del-COPYING.lgpl~54a90ba0899593cb@1.2, 2007-04-12 03:38:12-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/COPYING.lgpl + + BitKeeper/deleted/.del-COPYING.mbsd@1.2, 2007-04-12 02:36:23-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/COPYING.mbsd + + BitKeeper/deleted/.del-COPYING.mbsd~9b1945bb2136c70b@1.2, 2007-04-12 03:38:13-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/COPYING.mbsd + + BitKeeper/deleted/.del-MakeDefs.inc@1.2, 2007-04-12 02:36:24-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/MakeDefs.inc + + BitKeeper/deleted/.del-MakeDefs.inc~2b8fdfc9df6d652d@1.2, 2007-04-12 03:38:14-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/MakeDefs.inc + + BitKeeper/deleted/.del-Makefile.am@1.7, 2007-04-12 02:36:25-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/Makefile.am + + BitKeeper/deleted/.del-Makefile.am~fa9bd87b6045015c@1.5, 2007-04-12 03:38:15-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/Makefile.am + + BitKeeper/deleted/.del-README@1.2, 2007-04-12 02:37:20-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/README + + BitKeeper/deleted/.del-README~1ae087758ee867d4@1.2, 2007-04-12 03:38:15-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/README + + BitKeeper/deleted/.del-autoopts.c@1.11, 2007-04-12 02:36:26-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.c~5b417341bc85d7a8@1.8, 2007-04-12 03:38:17-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.h@1.10, 2007-04-12 02:36:27-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/autoopts.h + + BitKeeper/deleted/.del-autoopts.h~8cdce21b181a1a01@1.8, 2007-04-12 03:38:18-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts.h + + BitKeeper/deleted/.del-boolean.c@1.9, 2007-04-12 02:36:29-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/boolean.c + + BitKeeper/deleted/.del-boolean.c~a5d10c8997e6a2e2@1.6, 2007-04-12 03:38:19-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/boolean.c + + BitKeeper/deleted/.del-compat.h@1.13, 2007-04-12 02:34:50-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/compat.h + + BitKeeper/deleted/.del-compat.h~9682d0ac273ae32@1.9, 2007-04-12 03:47:41-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/compat.h + + BitKeeper/deleted/.del-configfile.c@1.11, 2007-04-12 02:36:30-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/configfile.c + + BitKeeper/deleted/.del-configfile.c~8194f784686fa804@1.8, 2007-04-12 03:38:20-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/configfile.c + + BitKeeper/deleted/.del-cook.c@1.10, 2007-04-12 02:36:31-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/cook.c + + BitKeeper/deleted/.del-cook.c~e48d079a438432dc@1.7, 2007-04-12 03:38:22-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/cook.c + + BitKeeper/deleted/.del-enumeration.c@1.10, 2007-04-12 02:36:33-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/enumeration.c + + BitKeeper/deleted/.del-enumeration.c~5f4e6af2706370ae@1.7, 2007-04-12 03:38:23-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/enumeration.c + + BitKeeper/deleted/.del-environment.c@1.9, 2007-04-12 02:36:34-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/environment.c + + BitKeeper/deleted/.del-environment.c~2bae2966695067c2@1.6, 2007-04-12 03:38:24-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/environment.c + + BitKeeper/deleted/.del-genshell.c@1.10, 2007-04-12 02:36:35-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/genshell.c + + BitKeeper/deleted/.del-genshell.c~1fd152b2b52bdab@1.7, 2007-04-12 03:38:25-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/genshell.c + + BitKeeper/deleted/.del-genshell.h@1.10, 2007-04-12 02:36:36-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/genshell.h + + BitKeeper/deleted/.del-genshell.h~375f0fa5b925f454@1.7, 2007-04-12 03:38:27-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/genshell.h + + BitKeeper/deleted/.del-libopts.c@1.4, 2007-04-12 02:36:37-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/libopts.c + + BitKeeper/deleted/.del-libopts.c~58b8fbed850e6d5e@1.4, 2007-04-12 03:38:28-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/libopts.c + + BitKeeper/deleted/.del-libopts.m4@1.15, 2007-04-12 02:36:02-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-libopts.m4~9e0f33f57d3a0a9@1.12, 2007-04-12 03:37:59-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-liboptschk.m4@1.4, 2007-04-12 02:36:03-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-liboptschk.m4~bbeebebe76865058@1.4, 2007-04-12 03:38:00-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-libtool.m4@1.2, 2007-04-12 02:36:05-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/m4/libtool.m4 + + BitKeeper/deleted/.del-libtool.m4~db8acbd0fb34597f@1.2, 2007-04-12 03:38:02-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/m4/libtool.m4 + + BitKeeper/deleted/.del-load.c@1.11, 2007-04-12 02:36:38-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/load.c + + BitKeeper/deleted/.del-load.c~59960aa12bb95bf7@1.8, 2007-04-12 03:38:29-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/load.c + + BitKeeper/deleted/.del-makeshell.c@1.12, 2007-04-12 02:36:39-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/makeshell.c + + BitKeeper/deleted/.del-makeshell.c~4fcd12fc31c0a4a4@1.9, 2007-04-12 03:38:31-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/makeshell.c + + BitKeeper/deleted/.del-nested.c@1.10, 2007-04-12 02:36:41-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/nested.c + + BitKeeper/deleted/.del-nested.c~85346d5d12098689@1.7, 2007-04-12 03:38:32-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/nested.c + + BitKeeper/deleted/.del-numeric.c@1.10, 2007-04-12 02:36:42-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/numeric.c + + BitKeeper/deleted/.del-numeric.c~cdb7deb5cf6f27c2@1.7, 2007-04-12 03:38:33-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/numeric.c + + BitKeeper/deleted/.del-options.h@1.11, 2007-04-12 02:34:30-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/autoopts/options.h + + BitKeeper/deleted/.del-options.h~6eb465cb95a56bee@1.8, 2007-04-12 03:46:14-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts/options.h + + BitKeeper/deleted/.del-pathfind.c@1.10, 2007-04-12 02:34:52-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pathfind.c~a0863179d884d4a4@1.7, 2007-04-12 03:47:43-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pgusage.c@1.10, 2007-04-12 02:36:43-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/pgusage.c + + BitKeeper/deleted/.del-pgusage.c~d981c42eb301cfdd@1.6, 2007-04-12 03:38:34-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/pgusage.c + + BitKeeper/deleted/.del-proto.h@1.12, 2007-04-12 02:36:44-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/proto.h + + BitKeeper/deleted/.del-proto.h~fa076f6dd9d0667e@1.9, 2007-04-12 03:38:36-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/proto.h + + BitKeeper/deleted/.del-putshell.c@1.11, 2007-04-12 02:36:45-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/putshell.c + + BitKeeper/deleted/.del-putshell.c~24959f5e1ba688e6@1.8, 2007-04-12 03:38:37-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/putshell.c + + BitKeeper/deleted/.del-restore.c@1.10, 2007-04-12 02:36:47-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/restore.c + + BitKeeper/deleted/.del-restore.c~eada4acbf21cd8bf@1.6, 2007-04-12 03:38:38-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/restore.c + + BitKeeper/deleted/.del-save.c@1.11, 2007-04-12 02:36:48-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/save.c + + BitKeeper/deleted/.del-save.c~a29f5bd429a568bb@1.8, 2007-04-12 03:38:39-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/save.c + + BitKeeper/deleted/.del-snprintf.c@1.5, 2007-04-12 02:34:53-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/snprintf.c + + BitKeeper/deleted/.del-snprintf.c~66578c716014cd3d@1.4, 2007-04-12 03:47:44-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/snprintf.c + + BitKeeper/deleted/.del-sort.c@1.9, 2007-04-12 02:36:49-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/sort.c + + BitKeeper/deleted/.del-sort.c~bec5a7fb6a01a5dc@1.5, 2007-04-12 03:38:40-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/sort.c + + BitKeeper/deleted/.del-stack.c@1.11, 2007-04-12 02:36:50-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/stack.c + + BitKeeper/deleted/.del-stack.c~e817b57b18b315c1@1.8, 2007-04-12 03:38:42-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/stack.c + + BitKeeper/deleted/.del-strchr.c@1.4, 2007-04-12 02:34:54-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/strchr.c + + BitKeeper/deleted/.del-strchr.c~80e88afbe7e2209a@1.4, 2007-04-12 03:47:45-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/strchr.c + + BitKeeper/deleted/.del-strdup.c@1.4, 2007-04-12 02:34:55-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/strdup.c + + BitKeeper/deleted/.del-strdup.c~1f262be5e55c3c4a@1.3, 2007-04-12 03:47:46-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/strdup.c + + BitKeeper/deleted/.del-streqvcmp.c@1.10, 2007-04-12 02:36:51-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/streqvcmp.c + + BitKeeper/deleted/.del-streqvcmp.c~66420c6082b06827@1.7, 2007-04-12 03:38:43-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/streqvcmp.c + + BitKeeper/deleted/.del-text_mmap.c@1.9, 2007-04-12 02:36:52-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/text_mmap.c + + BitKeeper/deleted/.del-text_mmap.c~f1915a52b87816ba@1.6, 2007-04-12 03:38:44-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/text_mmap.c + + BitKeeper/deleted/.del-tokenize.c@1.6, 2007-04-12 02:36:53-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/tokenize.c + + BitKeeper/deleted/.del-tokenize.c~ae2f23dbb2bee589@1.5, 2007-04-12 03:38:45-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/tokenize.c + + BitKeeper/deleted/.del-usage-txt.h@1.10, 2007-04-12 02:34:31-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage-txt.h~6ce4dce87430d1b@1.7, 2007-04-12 03:46:16-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage.c@1.10, 2007-04-12 02:36:54-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/usage.c + + BitKeeper/deleted/.del-usage.c~c868ef1e661a6eb1@1.8, 2007-04-12 03:38:46-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/usage.c + + BitKeeper/deleted/.del-version.c@1.10, 2007-04-12 02:36:56-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/version.c + + BitKeeper/deleted/.del-version.c~a426e6b58b20d06@1.7, 2007-04-12 03:38:47-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/version.c + + BitKeeper/deleted/.del-windows-config.h@1.6, 2007-04-12 02:34:56-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: libopts/compat/windows-config.h + + BitKeeper/deleted/.del-windows-config.h~36f7ad2ccf764ad2@1.4, 2007-04-12 03:47:47-04:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/libopts/compat/windows-config.h + + clockstuff/clktest-opts.c@1.10, 2007-04-12 05:44:59-04:00, stenn@whimsy.udel.edu +8 -7 + autogen upgrade + + clockstuff/clktest-opts.h@1.10, 2007-04-12 05:44:59-04:00, stenn@whimsy.udel.edu +8 -14 + autogen upgrade + + libopts/COPYING.lgpl@1.1, 2007-04-12 02:40:02-04:00, stenn@whimsy.udel.edu +502 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/COPYING.lgpl + + libopts/COPYING.lgpl@1.0, 2007-04-12 02:40:02-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/COPYING.mbsd@1.1, 2007-04-12 02:40:02-04:00, stenn@whimsy.udel.edu +26 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/COPYING.mbsd + + libopts/COPYING.mbsd@1.0, 2007-04-12 02:40:02-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/MakeDefs.inc@1.1, 2007-04-12 02:40:02-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/MakeDefs.inc + + libopts/MakeDefs.inc@1.0, 2007-04-12 02:40:02-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/Makefile.am@1.1, 2007-04-12 02:40:02-04:00, stenn@whimsy.udel.edu +24 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/Makefile.am + + libopts/Makefile.am@1.0, 2007-04-12 02:40:02-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/README@1.1, 2007-04-12 02:40:02-04:00, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/README + + libopts/README@1.0, 2007-04-12 02:40:02-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/autoopts.c@1.1, 2007-04-12 02:40:02-04:00, stenn@whimsy.udel.edu +1101 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts.c + + libopts/autoopts.c@1.0, 2007-04-12 02:40:02-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/autoopts.h@1.1, 2007-04-12 02:40:03-04:00, stenn@whimsy.udel.edu +377 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts.h + + libopts/autoopts.h@1.0, 2007-04-12 02:40:03-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/autoopts/options.h@1.1, 2007-04-12 02:40:26-04:00, stenn@whimsy.udel.edu +964 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts/options.h + + libopts/autoopts/options.h@1.0, 2007-04-12 02:40:26-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/autoopts/usage-txt.h@1.1, 2007-04-12 02:40:26-04:00, stenn@whimsy.udel.edu +355 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts/usage-txt.h + + libopts/autoopts/usage-txt.h@1.0, 2007-04-12 02:40:26-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/boolean.c@1.1, 2007-04-12 02:40:04-04:00, stenn@whimsy.udel.edu +106 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/boolean.c + + libopts/boolean.c@1.0, 2007-04-12 02:40:04-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/compat.h@1.1, 2007-04-12 02:40:33-04:00, stenn@whimsy.udel.edu +314 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/compat.h + + libopts/compat/compat.h@1.0, 2007-04-12 02:40:33-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/pathfind.c@1.1, 2007-04-12 02:40:34-04:00, stenn@whimsy.udel.edu +339 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/pathfind.c + + libopts/compat/pathfind.c@1.0, 2007-04-12 02:40:34-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/snprintf.c@1.1, 2007-04-12 02:40:34-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/snprintf.c + + libopts/compat/snprintf.c@1.0, 2007-04-12 02:40:34-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/strchr.c@1.1, 2007-04-12 02:40:34-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/strchr.c + + libopts/compat/strchr.c@1.0, 2007-04-12 02:40:34-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/strdup.c@1.1, 2007-04-12 02:40:34-04:00, stenn@whimsy.udel.edu +19 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/strdup.c + + libopts/compat/strdup.c@1.0, 2007-04-12 02:40:34-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/compat/windows-config.h@1.1, 2007-04-12 02:40:34-04:00, stenn@whimsy.udel.edu +129 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/windows-config.h + + libopts/compat/windows-config.h@1.0, 2007-04-12 02:40:34-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/configfile.c@1.1, 2007-04-12 02:40:04-04:00, stenn@whimsy.udel.edu +1288 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/configfile.c + + libopts/configfile.c@1.0, 2007-04-12 02:40:04-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/cook.c@1.1, 2007-04-12 02:40:04-04:00, stenn@whimsy.udel.edu +354 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/cook.c + + libopts/cook.c@1.0, 2007-04-12 02:40:04-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/enumeration.c@1.1, 2007-04-12 02:40:05-04:00, stenn@whimsy.udel.edu +498 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/enumeration.c + + libopts/enumeration.c@1.0, 2007-04-12 02:40:05-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/environment.c@1.1, 2007-04-12 02:40:05-04:00, stenn@whimsy.udel.edu +260 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/environment.c + + libopts/environment.c@1.0, 2007-04-12 02:40:05-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/genshell.c@1.1, 2007-04-12 02:40:06-04:00, stenn@whimsy.udel.edu +345 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/genshell.c + + libopts/genshell.c@1.0, 2007-04-12 02:40:06-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/genshell.h@1.1, 2007-04-12 02:40:07-04:00, stenn@whimsy.udel.edu +149 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/genshell.h + + libopts/genshell.h@1.0, 2007-04-12 02:40:07-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/libopts.c@1.1, 2007-04-12 02:40:07-04:00, stenn@whimsy.udel.edu +30 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/libopts.c + + libopts/libopts.c@1.0, 2007-04-12 02:40:07-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/load.c@1.1, 2007-04-12 02:40:07-04:00, stenn@whimsy.udel.edu +563 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/load.c + + libopts/load.c@1.0, 2007-04-12 02:40:07-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/m4/libopts.m4@1.1, 2007-04-12 02:40:39-04:00, stenn@whimsy.udel.edu +489 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/m4/libopts.m4 + + libopts/m4/libopts.m4@1.0, 2007-04-12 02:40:38-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/m4/liboptschk.m4@1.1, 2007-04-12 02:40:39-04:00, stenn@whimsy.udel.edu +42 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/m4/liboptschk.m4 + + libopts/m4/liboptschk.m4@1.0, 2007-04-12 02:40:39-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/makeshell.c@1.1, 2007-04-12 02:40:08-04:00, stenn@whimsy.udel.edu +1122 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/makeshell.c + + libopts/makeshell.c@1.0, 2007-04-12 02:40:08-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/nested.c@1.1, 2007-04-12 02:40:08-04:00, stenn@whimsy.udel.edu +733 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/nested.c + + libopts/nested.c@1.0, 2007-04-12 02:40:08-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/numeric.c@1.1, 2007-04-12 02:40:09-04:00, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/numeric.c + + libopts/numeric.c@1.0, 2007-04-12 02:40:09-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/pgusage.c@1.1, 2007-04-12 02:40:09-04:00, stenn@whimsy.udel.edu +157 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/pgusage.c + + libopts/pgusage.c@1.0, 2007-04-12 02:40:09-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/proto.h@1.1, 2007-04-12 02:40:09-04:00, stenn@whimsy.udel.edu +91 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/proto.h + + libopts/proto.h@1.0, 2007-04-12 02:40:09-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/putshell.c@1.1, 2007-04-12 02:40:09-04:00, stenn@whimsy.udel.edu +335 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/putshell.c + + libopts/putshell.c@1.0, 2007-04-12 02:40:09-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/restore.c@1.1, 2007-04-12 02:40:09-04:00, stenn@whimsy.udel.edu +250 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/restore.c + + libopts/restore.c@1.0, 2007-04-12 02:40:09-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/save.c@1.1, 2007-04-12 02:40:10-04:00, stenn@whimsy.udel.edu +512 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/save.c + + libopts/save.c@1.0, 2007-04-12 02:40:10-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/sort.c@1.1, 2007-04-12 02:40:10-04:00, stenn@whimsy.udel.edu +359 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/sort.c + + libopts/sort.c@1.0, 2007-04-12 02:40:10-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/stack.c@1.1, 2007-04-12 02:40:11-04:00, stenn@whimsy.udel.edu +269 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/stack.c + + libopts/stack.c@1.0, 2007-04-12 02:40:11-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/streqvcmp.c@1.1, 2007-04-12 02:40:11-04:00, stenn@whimsy.udel.edu +289 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/streqvcmp.c + + libopts/streqvcmp.c@1.0, 2007-04-12 02:40:11-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/text_mmap.c@1.1, 2007-04-12 02:40:12-04:00, stenn@whimsy.udel.edu +363 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/text_mmap.c + + libopts/text_mmap.c@1.0, 2007-04-12 02:40:12-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/tokenize.c@1.1, 2007-04-12 02:40:12-04:00, stenn@whimsy.udel.edu +321 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/tokenize.c + + libopts/tokenize.c@1.0, 2007-04-12 02:40:12-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/usage.c@1.1, 2007-04-12 02:40:13-04:00, stenn@whimsy.udel.edu +731 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/usage.c + + libopts/usage.c@1.0, 2007-04-12 02:40:13-04:00, stenn@whimsy.udel.edu +0 -0 + + libopts/version.c@1.1, 2007-04-12 02:40:13-04:00, stenn@whimsy.udel.edu +176 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/version.c + + libopts/version.c@1.0, 2007-04-12 02:40:13-04:00, stenn@whimsy.udel.edu +0 -0 + + ntpd/ntpd-opts.c@1.7, 2007-04-12 05:45:00-04:00, stenn@whimsy.udel.edu +9 -8 + autogen upgrade + + ntpd/ntpd-opts.h@1.7, 2007-04-12 05:45:02-04:00, stenn@whimsy.udel.edu +6 -12 + autogen upgrade + + ntpd/ntpdsim-opts.c@1.7, 2007-04-12 05:45:02-04:00, stenn@whimsy.udel.edu +9 -8 + autogen upgrade + + ntpd/ntpdsim-opts.h@1.7, 2007-04-12 05:45:04-04:00, stenn@whimsy.udel.edu +6 -12 + autogen upgrade + + ntpdc/ntpdc-opts.c@1.7, 2007-04-12 05:45:04-04:00, stenn@whimsy.udel.edu +9 -8 + autogen upgrade + + ntpdc/ntpdc-opts.h@1.7, 2007-04-12 05:45:05-04:00, stenn@whimsy.udel.edu +6 -12 + autogen upgrade + + ntpq/ntpq-opts.c@1.7, 2007-04-12 05:45:05-04:00, stenn@whimsy.udel.edu +9 -8 + autogen upgrade + + ntpq/ntpq-opts.h@1.7, 2007-04-12 05:45:06-04:00, stenn@whimsy.udel.edu +6 -12 + autogen upgrade + + sntp/libopts/COPYING.lgpl@1.1, 2007-04-12 03:51:16-04:00, stenn@whimsy.udel.edu +502 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/COPYING.lgpl + + sntp/libopts/COPYING.lgpl@1.0, 2007-04-12 03:51:16-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/COPYING.mbsd@1.1, 2007-04-12 03:51:16-04:00, stenn@whimsy.udel.edu +26 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/COPYING.mbsd + + sntp/libopts/COPYING.mbsd@1.0, 2007-04-12 03:51:16-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/MakeDefs.inc@1.1, 2007-04-12 03:51:16-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/MakeDefs.inc + + sntp/libopts/MakeDefs.inc@1.0, 2007-04-12 03:51:16-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/Makefile.am@1.1, 2007-04-12 03:51:16-04:00, stenn@whimsy.udel.edu +24 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/Makefile.am + + sntp/libopts/Makefile.am@1.0, 2007-04-12 03:51:16-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/README@1.1, 2007-04-12 03:51:16-04:00, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/README + + sntp/libopts/README@1.0, 2007-04-12 03:51:16-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/autoopts.c@1.1, 2007-04-12 03:51:16-04:00, stenn@whimsy.udel.edu +1101 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts.c + + sntp/libopts/autoopts.c@1.0, 2007-04-12 03:51:16-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/autoopts.h@1.1, 2007-04-12 03:51:17-04:00, stenn@whimsy.udel.edu +377 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts.h + + sntp/libopts/autoopts.h@1.0, 2007-04-12 03:51:17-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/autoopts/options.h@1.1, 2007-04-12 03:51:37-04:00, stenn@whimsy.udel.edu +964 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts/options.h + + sntp/libopts/autoopts/options.h@1.0, 2007-04-12 03:51:37-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/autoopts/usage-txt.h@1.1, 2007-04-12 03:51:37-04:00, stenn@whimsy.udel.edu +355 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts/usage-txt.h + + sntp/libopts/autoopts/usage-txt.h@1.0, 2007-04-12 03:51:37-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/boolean.c@1.1, 2007-04-12 03:51:17-04:00, stenn@whimsy.udel.edu +106 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/boolean.c + + sntp/libopts/boolean.c@1.0, 2007-04-12 03:51:17-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/compat.h@1.1, 2007-04-12 03:51:42-04:00, stenn@whimsy.udel.edu +314 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/compat.h + + sntp/libopts/compat/compat.h@1.0, 2007-04-12 03:51:42-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/pathfind.c@1.1, 2007-04-12 03:51:43-04:00, stenn@whimsy.udel.edu +339 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/pathfind.c + + sntp/libopts/compat/pathfind.c@1.0, 2007-04-12 03:51:43-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/snprintf.c@1.1, 2007-04-12 03:51:43-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/snprintf.c + + sntp/libopts/compat/snprintf.c@1.0, 2007-04-12 03:51:43-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/strchr.c@1.1, 2007-04-12 03:51:44-04:00, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/strchr.c + + sntp/libopts/compat/strchr.c@1.0, 2007-04-12 03:51:44-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/strdup.c@1.1, 2007-04-12 03:51:44-04:00, stenn@whimsy.udel.edu +19 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/strdup.c + + sntp/libopts/compat/strdup.c@1.0, 2007-04-12 03:51:44-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/compat/windows-config.h@1.1, 2007-04-12 03:51:44-04:00, stenn@whimsy.udel.edu +129 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/windows-config.h + + sntp/libopts/compat/windows-config.h@1.0, 2007-04-12 03:51:44-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/configfile.c@1.1, 2007-04-12 03:51:17-04:00, stenn@whimsy.udel.edu +1288 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/configfile.c + + sntp/libopts/configfile.c@1.0, 2007-04-12 03:51:17-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/cook.c@1.1, 2007-04-12 03:51:18-04:00, stenn@whimsy.udel.edu +354 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/cook.c + + sntp/libopts/cook.c@1.0, 2007-04-12 03:51:18-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/enumeration.c@1.1, 2007-04-12 03:51:19-04:00, stenn@whimsy.udel.edu +498 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/enumeration.c + + sntp/libopts/enumeration.c@1.0, 2007-04-12 03:51:19-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/environment.c@1.1, 2007-04-12 03:51:19-04:00, stenn@whimsy.udel.edu +260 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/environment.c + + sntp/libopts/environment.c@1.0, 2007-04-12 03:51:19-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/genshell.c@1.1, 2007-04-12 03:51:20-04:00, stenn@whimsy.udel.edu +345 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/genshell.c + + sntp/libopts/genshell.c@1.0, 2007-04-12 03:51:20-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/genshell.h@1.1, 2007-04-12 03:51:21-04:00, stenn@whimsy.udel.edu +149 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/genshell.h + + sntp/libopts/genshell.h@1.0, 2007-04-12 03:51:21-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/libopts.c@1.1, 2007-04-12 03:51:21-04:00, stenn@whimsy.udel.edu +30 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/libopts.c + + sntp/libopts/libopts.c@1.0, 2007-04-12 03:51:21-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/load.c@1.1, 2007-04-12 03:51:21-04:00, stenn@whimsy.udel.edu +563 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/load.c + + sntp/libopts/load.c@1.0, 2007-04-12 03:51:21-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/m4/libopts.m4@1.1, 2007-04-12 03:51:48-04:00, stenn@whimsy.udel.edu +489 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/m4/libopts.m4 + + sntp/libopts/m4/libopts.m4@1.0, 2007-04-12 03:51:48-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/m4/liboptschk.m4@1.1, 2007-04-12 03:51:49-04:00, stenn@whimsy.udel.edu +42 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/m4/liboptschk.m4 + + sntp/libopts/m4/liboptschk.m4@1.0, 2007-04-12 03:51:48-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/makeshell.c@1.1, 2007-04-12 03:51:21-04:00, stenn@whimsy.udel.edu +1122 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/makeshell.c + + sntp/libopts/makeshell.c@1.0, 2007-04-12 03:51:21-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/nested.c@1.1, 2007-04-12 03:51:22-04:00, stenn@whimsy.udel.edu +733 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/nested.c + + sntp/libopts/nested.c@1.0, 2007-04-12 03:51:22-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/numeric.c@1.1, 2007-04-12 03:51:22-04:00, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/numeric.c + + sntp/libopts/numeric.c@1.0, 2007-04-12 03:51:22-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/pgusage.c@1.1, 2007-04-12 03:51:22-04:00, stenn@whimsy.udel.edu +157 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/pgusage.c + + sntp/libopts/pgusage.c@1.0, 2007-04-12 03:51:22-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/proto.h@1.1, 2007-04-12 03:51:22-04:00, stenn@whimsy.udel.edu +91 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/proto.h + + sntp/libopts/proto.h@1.0, 2007-04-12 03:51:22-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/putshell.c@1.1, 2007-04-12 03:51:22-04:00, stenn@whimsy.udel.edu +335 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/putshell.c + + sntp/libopts/putshell.c@1.0, 2007-04-12 03:51:22-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/restore.c@1.1, 2007-04-12 03:51:23-04:00, stenn@whimsy.udel.edu +250 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/restore.c + + sntp/libopts/restore.c@1.0, 2007-04-12 03:51:23-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/save.c@1.1, 2007-04-12 03:51:24-04:00, stenn@whimsy.udel.edu +512 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/save.c + + sntp/libopts/save.c@1.0, 2007-04-12 03:51:24-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/sort.c@1.1, 2007-04-12 03:51:24-04:00, stenn@whimsy.udel.edu +359 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/sort.c + + sntp/libopts/sort.c@1.0, 2007-04-12 03:51:24-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/stack.c@1.1, 2007-04-12 03:51:25-04:00, stenn@whimsy.udel.edu +269 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/stack.c + + sntp/libopts/stack.c@1.0, 2007-04-12 03:51:25-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/streqvcmp.c@1.1, 2007-04-12 03:51:25-04:00, stenn@whimsy.udel.edu +289 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/streqvcmp.c + + sntp/libopts/streqvcmp.c@1.0, 2007-04-12 03:51:25-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/text_mmap.c@1.1, 2007-04-12 03:51:26-04:00, stenn@whimsy.udel.edu +363 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/text_mmap.c + + sntp/libopts/text_mmap.c@1.0, 2007-04-12 03:51:26-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/tokenize.c@1.1, 2007-04-12 03:51:26-04:00, stenn@whimsy.udel.edu +321 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/tokenize.c + + sntp/libopts/tokenize.c@1.0, 2007-04-12 03:51:26-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/usage.c@1.1, 2007-04-12 03:51:27-04:00, stenn@whimsy.udel.edu +731 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/usage.c + + sntp/libopts/usage.c@1.0, 2007-04-12 03:51:27-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/libopts/version.c@1.1, 2007-04-12 03:51:27-04:00, stenn@whimsy.udel.edu +176 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/version.c + + sntp/libopts/version.c@1.0, 2007-04-12 03:51:27-04:00, stenn@whimsy.udel.edu +0 -0 + + sntp/sntp-opts.c@1.7, 2007-04-12 05:45:07-04:00, stenn@whimsy.udel.edu +7 -6 + autogen upgrade + + sntp/sntp-opts.h@1.7, 2007-04-12 05:45:08-04:00, stenn@whimsy.udel.edu +6 -12 + autogen upgrade + + util/ntp-keygen-opts.c@1.7, 2007-04-12 05:45:08-04:00, stenn@whimsy.udel.edu +9 -8 + autogen upgrade + + util/ntp-keygen-opts.h@1.7, 2007-04-12 05:45:09-04:00, stenn@whimsy.udel.edu +6 -12 + autogen upgrade + +ChangeSet@1.1440.1.73, 2007-03-26 06:42:22-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P20 + TAG: NTP_4_2_5P20 + + ntpd/ntpd-opts.c@1.6, 2007-03-26 06:42:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P20 + + ntpd/ntpd-opts.h@1.6, 2007-03-26 06:42:03-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P20 + + ntpd/ntpd-opts.texi@1.6, 2007-03-26 06:42:04-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P20 + + ntpd/ntpd.1@1.6, 2007-03-26 06:42:04-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P20 + + ntpd/ntpdsim-opts.c@1.6, 2007-03-26 06:42:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P20 + + ntpd/ntpdsim-opts.h@1.6, 2007-03-26 06:42:07-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P20 + + ntpd/ntpdsim-opts.texi@1.6, 2007-03-26 06:42:07-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P20 + + ntpd/ntpdsim.1@1.6, 2007-03-26 06:42:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P20 + + ntpdc/ntpdc-opts.c@1.6, 2007-03-26 06:42:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P20 + + ntpdc/ntpdc-opts.h@1.6, 2007-03-26 06:42:09-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P20 + + ntpdc/ntpdc-opts.texi@1.6, 2007-03-26 06:42:10-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P20 + + ntpdc/ntpdc.1@1.6, 2007-03-26 06:42:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P20 + + ntpq/ntpq-opts.c@1.6, 2007-03-26 06:42:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P20 + + ntpq/ntpq-opts.h@1.6, 2007-03-26 06:42:12-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P20 + + ntpq/ntpq-opts.texi@1.6, 2007-03-26 06:42:13-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P20 + + ntpq/ntpq.1@1.6, 2007-03-26 06:42:13-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P20 + + packageinfo.sh@1.23, 2007-03-26 06:42:14-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P20 + + sntp/sntp-opts.c@1.6, 2007-03-26 06:42:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P20 + + sntp/sntp-opts.h@1.6, 2007-03-26 06:42:15-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P20 + + sntp/sntp-opts.texi@1.6, 2007-03-26 06:42:16-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P20 + + sntp/sntp.1@1.6, 2007-03-26 06:42:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P20 + + util/ntp-keygen-opts.c@1.6, 2007-03-26 06:42:17-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P20 + + util/ntp-keygen-opts.h@1.6, 2007-03-26 06:42:17-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P20 + + util/ntp-keygen-opts.texi@1.6, 2007-03-26 06:42:18-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P20 + + util/ntp-keygen.1@1.6, 2007-03-26 06:42:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P20 + +ChangeSet@1.1440.4.6, 2007-03-25 21:27:11+00:00, kardel@pogo.udel.edu +1 -0 + ChangeLog: + document fix for [Bug 789] + + ChangeLog@1.22.1.1, 2007-03-25 21:26:23+00:00, kardel@pogo.udel.edu +2 -1 + document fix for [Bug 789] + +ChangeSet@1.1440.1.71, 2007-03-25 16:56:03-04:00, stenn@pogo.udel.edu +1 -0 + [Bug 787] Bug fixes for 64-bit time_t on Windows + + ChangeLog@1.23, 2007-03-25 16:55:41-04:00, stenn@pogo.udel.edu +1 -0 + [Bug 787] Bug fixes for 64-bit time_t on Windows + +ChangeSet@1.1440.4.5, 2007-03-25 20:07:31+00:00, kardel@pogo.udel.edu +1 -0 + ntp_peer.c: + [Bug 789] avoid broadcast/multicast client associations + getting confused when multicast packets arrive + during the autokey/delay dance + + ntpd/ntp_peer.c@1.101, 2007-03-25 20:03:33+00:00, kardel@pogo.udel.edu +15 -3 + [Bug 789] avoid peers getting confused when multicast packets arrive + during the autokey/delay dance + +ChangeSet@1.1440.4.4, 2007-03-20 06:42:12-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P19 + TAG: NTP_4_2_5P19 + + ntpd/ntpd-opts.c@1.5, 2007-03-20 06:41:54-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P19 + + ntpd/ntpd-opts.h@1.5, 2007-03-20 06:41:55-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P19 + + ntpd/ntpd-opts.texi@1.5, 2007-03-20 06:41:55-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P19 + + ntpd/ntpd.1@1.5, 2007-03-20 06:41:56-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P19 + + ntpd/ntpdsim-opts.c@1.5, 2007-03-20 06:41:57-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P19 + + ntpd/ntpdsim-opts.h@1.5, 2007-03-20 06:41:58-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P19 + + ntpd/ntpdsim-opts.texi@1.5, 2007-03-20 06:41:59-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P19 + + ntpd/ntpdsim.1@1.5, 2007-03-20 06:41:59-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P19 + + ntpdc/ntpdc-opts.c@1.5, 2007-03-20 06:42:00-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P19 + + ntpdc/ntpdc-opts.h@1.5, 2007-03-20 06:42:01-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P19 + + ntpdc/ntpdc-opts.texi@1.5, 2007-03-20 06:42:01-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P19 + + ntpdc/ntpdc.1@1.5, 2007-03-20 06:42:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P19 + + ntpq/ntpq-opts.c@1.5, 2007-03-20 06:42:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P19 + + ntpq/ntpq-opts.h@1.5, 2007-03-20 06:42:03-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P19 + + ntpq/ntpq-opts.texi@1.5, 2007-03-20 06:42:04-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P19 + + ntpq/ntpq.1@1.5, 2007-03-20 06:42:04-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P19 + + packageinfo.sh@1.22, 2007-03-20 06:42:05-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P19 + + sntp/sntp-opts.c@1.5, 2007-03-20 06:42:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P19 + + sntp/sntp-opts.h@1.5, 2007-03-20 06:42:06-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P19 + + sntp/sntp-opts.texi@1.5, 2007-03-20 06:42:07-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P19 + + sntp/sntp.1@1.5, 2007-03-20 06:42:07-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P19 + + util/ntp-keygen-opts.c@1.5, 2007-03-20 06:42:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P19 + + util/ntp-keygen-opts.h@1.5, 2007-03-20 06:42:08-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P19 + + util/ntp-keygen-opts.texi@1.5, 2007-03-20 06:42:09-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P19 + + util/ntp-keygen.1@1.5, 2007-03-20 06:42:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P19 + +ChangeSet@1.1440.4.3, 2007-03-20 02:19:52-05:00, stenn@whimsy.udel.edu +1 -0 + Clean up some \\n's on error messages + + ntpd/ntpd.c@1.83.1.2, 2007-03-20 02:19:31-05:00, stenn@whimsy.udel.edu +2 -2 + Clean up some \\n's on error messages + +ChangeSet@1.1440.4.2, 2007-03-20 01:00:23-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 796] Clean up duplicate #defines in ntp_control.c + + ChangeLog@1.22, 2007-03-20 01:00:14-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 796] Clean up duplicate #defines in ntp_control.c + + ntpd/ntp_control.c@1.89.1.1, 2007-03-20 00:59:50-05:00, stenn@whimsy.udel.edu +4 -9 + [Bug 796] Clean up duplicate #defines in ntp_control.c + +ChangeSet@1.1440.4.1, 2007-03-18 06:47:40-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P18 + TAG: NTP_4_2_5P18 + + ntpd/ntpd-opts.c@1.4, 2007-03-18 06:47:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P18 + + ntpd/ntpd-opts.h@1.4, 2007-03-18 06:47:21-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P18 + + ntpd/ntpd-opts.texi@1.4, 2007-03-18 06:47:22-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P18 + + ntpd/ntpd.1@1.4, 2007-03-18 06:47:23-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P18 + + ntpd/ntpdsim-opts.c@1.4, 2007-03-18 06:47:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P18 + + ntpd/ntpdsim-opts.h@1.4, 2007-03-18 06:47:25-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P18 + + ntpd/ntpdsim-opts.texi@1.4, 2007-03-18 06:47:25-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P18 + + ntpd/ntpdsim.1@1.4, 2007-03-18 06:47:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P18 + + ntpdc/ntpdc-opts.c@1.4, 2007-03-18 06:47:27-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P18 + + ntpdc/ntpdc-opts.h@1.4, 2007-03-18 06:47:28-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P18 + + ntpdc/ntpdc-opts.texi@1.4, 2007-03-18 06:47:28-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P18 + + ntpdc/ntpdc.1@1.4, 2007-03-18 06:47:29-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P18 + + ntpq/ntpq-opts.c@1.4, 2007-03-18 06:47:29-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P18 + + ntpq/ntpq-opts.h@1.4, 2007-03-18 06:47:30-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P18 + + ntpq/ntpq-opts.texi@1.4, 2007-03-18 06:47:30-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P18 + + ntpq/ntpq.1@1.4, 2007-03-18 06:47:31-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P18 + + packageinfo.sh@1.21, 2007-03-18 06:47:32-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P18 + + sntp/sntp-opts.c@1.4, 2007-03-18 06:47:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P18 + + sntp/sntp-opts.h@1.4, 2007-03-18 06:47:33-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P18 + + sntp/sntp-opts.texi@1.4, 2007-03-18 06:47:34-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P18 + + sntp/sntp.1@1.4, 2007-03-18 06:47:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P18 + + util/ntp-keygen-opts.c@1.4, 2007-03-18 06:47:35-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P18 + + util/ntp-keygen-opts.h@1.4, 2007-03-18 06:47:35-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P18 + + util/ntp-keygen-opts.texi@1.4, 2007-03-18 06:47:36-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P18 + + util/ntp-keygen.1@1.4, 2007-03-18 06:47:37-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P18 + +ChangeSet@1.1410.1.1, 2007-03-18 02:35:16-04:00, mayer@pogo.udel.edu +3 -0 + Bug #787 Bug fixes for 64-bit time_t on Windows + + ports/winnt/include/config.h@1.47, 2007-03-18 02:33:16-04:00, mayer@pogo.udel.edu +25 -7 + Bug #787 Bug fixes for 64-bit time_t on Windows + + ports/winnt/include/ntp_timer.h@1.3.1.1, 2007-03-18 02:33:32-04:00, mayer@pogo.udel.edu +2 -2 + Bug #787 Bug fixes for 64-bit time_t on Windows + + ports/winnt/libntp/SetSystemTime.c@1.4, 2007-03-18 02:34:38-04:00, mayer@pogo.udel.edu +2 -2 + Bug #787 Bug fixes for 64-bit time_t on Windows + +ChangeSet@1.1440.1.67, 2007-03-17 19:35:08-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 569] Use the correct precision for the Leitch CSD-5300 + + ChangeLog@1.21, 2007-03-17 19:34:25-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 569] Use the correct precision for the Leitch CSD-5300 + + ntpd/refclock_leitch.c@1.10, 2007-03-17 19:34:26-05:00, stenn@whimsy.udel.edu +2 -1 + [Bug 569] Use the correct precision for the Leitch CSD-5300 + +ChangeSet@1.1440.1.66, 2007-03-17 15:19:52-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 798] ntpq [p typo crashes ntpdc + + ChangeLog@1.20, 2007-03-17 15:19:33-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 798] ntpq [p typo crashes ntpdc + + ntpdc/ntpdc.c@1.56, 2007-03-17 15:19:13-05:00, stenn@whimsy.udel.edu +8 -4 + [Bug 798] ntpq [p typo crashes ntpdc + +ChangeSet@1.1440.1.65, 2007-03-17 06:43:30-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P17 + TAG: NTP_4_2_5P17 + + ntpd/ntpd-opts.c@1.3, 2007-03-17 06:43:12-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P17 + + ntpd/ntpd-opts.h@1.3, 2007-03-17 06:43:12-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P17 + + ntpd/ntpd-opts.texi@1.3, 2007-03-17 06:43:13-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P17 + + ntpd/ntpd.1@1.3, 2007-03-17 06:43:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P17 + + ntpd/ntpdsim-opts.c@1.3, 2007-03-17 06:43:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P17 + + ntpd/ntpdsim-opts.h@1.3, 2007-03-17 06:43:16-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P17 + + ntpd/ntpdsim-opts.texi@1.3, 2007-03-17 06:43:16-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P17 + + ntpd/ntpdsim.1@1.3, 2007-03-17 06:43:17-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P17 + + ntpdc/ntpdc-opts.c@1.3, 2007-03-17 06:43:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P17 + + ntpdc/ntpdc-opts.h@1.3, 2007-03-17 06:43:18-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P17 + + ntpdc/ntpdc-opts.texi@1.3, 2007-03-17 06:43:19-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P17 + + ntpdc/ntpdc.1@1.3, 2007-03-17 06:43:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P17 + + ntpq/ntpq-opts.c@1.3, 2007-03-17 06:43:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P17 + + ntpq/ntpq-opts.h@1.3, 2007-03-17 06:43:20-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P17 + + ntpq/ntpq-opts.texi@1.3, 2007-03-17 06:43:21-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P17 + + ntpq/ntpq.1@1.3, 2007-03-17 06:43:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P17 + + packageinfo.sh@1.20, 2007-03-17 06:43:22-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P17 + + sntp/sntp-opts.c@1.3, 2007-03-17 06:43:22-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P17 + + sntp/sntp-opts.h@1.3, 2007-03-17 06:43:23-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P17 + + sntp/sntp-opts.texi@1.3, 2007-03-17 06:43:24-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P17 + + sntp/sntp.1@1.3, 2007-03-17 06:43:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P17 + + util/ntp-keygen-opts.c@1.3, 2007-03-17 06:43:25-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P17 + + util/ntp-keygen-opts.h@1.3, 2007-03-17 06:43:26-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P17 + + util/ntp-keygen-opts.texi@1.3, 2007-03-17 06:43:26-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P17 + + util/ntp-keygen.1@1.3, 2007-03-17 06:43:27-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P17 + +ChangeSet@1.1440.1.64, 2007-03-17 06:54:45-04:00, stenn@pogo.udel.edu +1 -0 + [Bug 795] Moved declaration of variable to top of function + + ChangeLog@1.19, 2007-03-17 06:54:38-04:00, stenn@pogo.udel.edu +1 -0 + [Bug 795] Moved declaration of variable to top of function + +ChangeSet@1.1440.3.1, 2007-03-17 04:53:50-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 798] ntpq [p typo crashes ntpq + + ChangeLog@1.18, 2007-03-17 04:53:39-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 798] ntpq [p typo crashes ntpq + + ntpq/ntpq.c@1.66.1.1, 2007-03-17 04:53:16-05:00, stenn@whimsy.udel.edu +8 -4 + [Bug 798] ntpq [p typo crashes ntpq + +ChangeSet@1.1440.1.62, 2007-03-12 09:06:55+00:00, burnicki@pogo.udel.edu +1 -0 + [Bug 795] Moved declaration of variable to top of function to avoid build error. + + ntpd/ntp_io.c@1.245.1.4, 2007-03-12 09:06:52+00:00, burnicki@pogo.udel.edu +4 -1 + Moved declaration of variable to top of function to avoid build error. + +ChangeSet@1.1436.1.36, 2007-03-07 06:46:09-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_4P0 + TAG: NTP_4_2_4P0 + + ntpd/ntpd-opts.c@1.50.1.6, 2007-03-07 06:45:46-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0 + + ntpd/ntpd-opts.h@1.50.1.6, 2007-03-07 06:45:47-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P0 + + ntpd/ntpd-opts.texi@1.49.1.6, 2007-03-07 06:45:48-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P0 + + ntpd/ntpd.1@1.48.1.6, 2007-03-07 06:45:48-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0 + + ntpd/ntpdsim-opts.c@1.50.1.6, 2007-03-07 06:45:49-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0 + + ntpd/ntpdsim-opts.h@1.50.1.6, 2007-03-07 06:45:50-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P0 + + ntpd/ntpdsim-opts.texi@1.48.1.6, 2007-03-07 06:45:51-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P0 + + ntpd/ntpdsim.1@1.48.1.6, 2007-03-07 06:45:51-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0 + + ntpdc/ntpdc-opts.c@1.50.1.6, 2007-03-07 06:45:52-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0 + + ntpdc/ntpdc-opts.h@1.50.1.6, 2007-03-07 06:45:53-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P0 + + ntpdc/ntpdc-opts.texi@1.48.1.6, 2007-03-07 06:45:53-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P0 + + ntpdc/ntpdc.1@1.48.1.6, 2007-03-07 06:45:54-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0 + + ntpq/ntpq-opts.c@1.52.1.6, 2007-03-07 06:45:55-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0 + + ntpq/ntpq-opts.h@1.52.1.6, 2007-03-07 06:45:56-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P0 + + ntpq/ntpq-opts.texi@1.49.1.6, 2007-03-07 06:45:57-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P0 + + ntpq/ntpq.1@1.48.1.6, 2007-03-07 06:45:58-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0 + + packageinfo.sh@1.65.7.2, 2007-03-07 06:45:58-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0 + + sntp/sntp-opts.c@1.49.1.6, 2007-03-07 06:45:59-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0 + + sntp/sntp-opts.h@1.49.1.6, 2007-03-07 06:46:00-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P0 + + sntp/sntp-opts.texi@1.46.1.6, 2007-03-07 06:46:01-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P0 + + sntp/sntp.1@1.49.1.6, 2007-03-07 06:46:01-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0 + + util/ntp-keygen-opts.c@1.49.1.6, 2007-03-07 06:46:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0 + + util/ntp-keygen-opts.h@1.49.1.6, 2007-03-07 06:46:03-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P0 + + util/ntp-keygen-opts.texi@1.47.1.6, 2007-03-07 06:46:04-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P0 + + util/ntp-keygen.1@1.47.1.6, 2007-03-07 06:46:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0 + +ChangeSet@1.1436.1.35, 2007-03-07 00:53:31-05:00, stenn@whimsy.udel.edu +1 -0 + time to release + + packageinfo.sh@1.65.7.1, 2007-03-07 00:53:21-05:00, stenn@whimsy.udel.edu +3 -1 + time to release + +ChangeSet@1.1440.1.61, 2007-03-04 07:33:47-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P16 + TAG: NTP_4_2_5P16 + + ntpd/ntpd-opts.c@1.2, 2007-03-04 07:33:27-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P16 + + ntpd/ntpd-opts.h@1.2, 2007-03-04 07:33:28-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P16 + + ntpd/ntpd-opts.texi@1.2, 2007-03-04 07:33:28-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P16 + + ntpd/ntpd.1@1.2, 2007-03-04 07:33:29-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P16 + + ntpd/ntpdsim-opts.c@1.2, 2007-03-04 07:33:30-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P16 + + ntpd/ntpdsim-opts.h@1.2, 2007-03-04 07:33:31-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P16 + + ntpd/ntpdsim-opts.texi@1.2, 2007-03-04 07:33:32-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P16 + + ntpd/ntpdsim.1@1.2, 2007-03-04 07:33:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P16 + + ntpdc/ntpdc-opts.c@1.2, 2007-03-04 07:33:33-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P16 + + ntpdc/ntpdc-opts.h@1.2, 2007-03-04 07:33:33-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P16 + + ntpdc/ntpdc-opts.texi@1.2, 2007-03-04 07:33:34-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P16 + + ntpdc/ntpdc.1@1.2, 2007-03-04 07:33:35-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P16 + + ntpq/ntpq-opts.c@1.2, 2007-03-04 07:33:35-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P16 + + ntpq/ntpq-opts.h@1.2, 2007-03-04 07:33:36-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P16 + + ntpq/ntpq-opts.texi@1.2, 2007-03-04 07:33:37-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P16 + + ntpq/ntpq.1@1.2, 2007-03-04 07:33:37-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P16 + + packageinfo.sh@1.19, 2007-03-04 07:33:39-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P16 + + sntp/sntp-opts.c@1.2, 2007-03-04 07:33:39-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P16 + + sntp/sntp-opts.h@1.2, 2007-03-04 07:33:40-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P16 + + sntp/sntp-opts.texi@1.2, 2007-03-04 07:33:41-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P16 + + sntp/sntp.1@1.2, 2007-03-04 07:33:41-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P16 + + util/ntp-keygen-opts.c@1.2, 2007-03-04 07:33:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P16 + + util/ntp-keygen-opts.h@1.2, 2007-03-04 07:33:43-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P16 + + util/ntp-keygen-opts.texi@1.2, 2007-03-04 07:33:44-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P16 + + util/ntp-keygen.1@1.2, 2007-03-04 07:33:44-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P16 + +ChangeSet@1.1440.1.60, 2007-03-03 22:41:27-05:00, stenn@whimsy.udel.edu +48 -0 + .point-changed-filelist items are distinct between -stable and -dev. + + BitKeeper/deleted/.del-ntp-keygen-opts.c@1.71, 2007-03-03 22:41:10-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: util/ntp-keygen-opts.c + + BitKeeper/deleted/.del-ntp-keygen-opts.h@1.71, 2007-03-03 22:41:13-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: util/ntp-keygen-opts.h + + BitKeeper/deleted/.del-ntp-keygen-opts.texi@1.69, 2007-03-03 22:41:16-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: util/ntp-keygen-opts.texi + + BitKeeper/deleted/.del-ntp-keygen.1@1.69, 2007-03-03 22:41:19-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: util/ntp-keygen.1 + + BitKeeper/deleted/.del-ntpd-opts.c@1.72, 2007-03-03 22:40:17-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: ntpd/ntpd-opts.c + + BitKeeper/deleted/.del-ntpd-opts.h@1.72, 2007-03-03 22:40:19-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: ntpd/ntpd-opts.h + + BitKeeper/deleted/.del-ntpd-opts.texi@1.71, 2007-03-03 22:40:22-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: ntpd/ntpd-opts.texi + + BitKeeper/deleted/.del-ntpd.1@1.70, 2007-03-03 22:40:24-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: ntpd/ntpd.1 + + BitKeeper/deleted/.del-ntpdc-opts.c@1.72, 2007-03-03 22:40:36-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: ntpdc/ntpdc-opts.c + + BitKeeper/deleted/.del-ntpdc-opts.h@1.72, 2007-03-03 22:40:39-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: ntpdc/ntpdc-opts.h + + BitKeeper/deleted/.del-ntpdc-opts.texi@1.70, 2007-03-03 22:40:42-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: ntpdc/ntpdc-opts.texi + + BitKeeper/deleted/.del-ntpdc.1@1.70, 2007-03-03 22:40:44-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: ntpdc/ntpdc.1 + + BitKeeper/deleted/.del-ntpdsim-opts.c@1.72, 2007-03-03 22:40:26-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: ntpd/ntpdsim-opts.c + + BitKeeper/deleted/.del-ntpdsim-opts.h@1.72, 2007-03-03 22:40:28-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: ntpd/ntpdsim-opts.h + + BitKeeper/deleted/.del-ntpdsim-opts.texi@1.70, 2007-03-03 22:40:31-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: ntpd/ntpdsim-opts.texi + + BitKeeper/deleted/.del-ntpdsim.1@1.70, 2007-03-03 22:40:33-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: ntpd/ntpdsim.1 + + BitKeeper/deleted/.del-ntpq-opts.c@1.74, 2007-03-03 22:40:46-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: ntpq/ntpq-opts.c + + BitKeeper/deleted/.del-ntpq-opts.h@1.74, 2007-03-03 22:40:49-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: ntpq/ntpq-opts.h + + BitKeeper/deleted/.del-ntpq-opts.texi@1.71, 2007-03-03 22:40:52-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: ntpq/ntpq-opts.texi + + BitKeeper/deleted/.del-ntpq.1@1.70, 2007-03-03 22:40:56-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: ntpq/ntpq.1 + + BitKeeper/deleted/.del-sntp-opts.c@1.71, 2007-03-03 22:41:00-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/sntp-opts.c + + BitKeeper/deleted/.del-sntp-opts.h@1.71, 2007-03-03 22:41:03-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/sntp-opts.h + + BitKeeper/deleted/.del-sntp-opts.texi@1.68, 2007-03-03 22:41:06-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/sntp-opts.texi + + BitKeeper/deleted/.del-sntp.1@1.71, 2007-03-03 22:41:08-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: sntp/sntp.1 + + ntpd/ntpd-opts.c@1.1, 2007-03-03 22:40:18-05:00, stenn@whimsy.udel.edu +1055 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpd/ntpd-opts.c + + ntpd/ntpd-opts.c@1.0, 2007-03-03 22:40:18-05:00, stenn@whimsy.udel.edu +0 -0 + + ntpd/ntpd-opts.h@1.1, 2007-03-03 22:40:20-05:00, stenn@whimsy.udel.edu +366 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpd/ntpd-opts.h + + ntpd/ntpd-opts.h@1.0, 2007-03-03 22:40:20-05:00, stenn@whimsy.udel.edu +0 -0 + + ntpd/ntpd-opts.texi@1.1, 2007-03-03 22:40:22-05:00, stenn@whimsy.udel.edu +498 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpd/ntpd-opts.texi + + ntpd/ntpd-opts.texi@1.0, 2007-03-03 22:40:22-05:00, stenn@whimsy.udel.edu +0 -0 + + ntpd/ntpd.1@1.1, 2007-03-03 22:40:25-05:00, stenn@whimsy.udel.edu +312 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpd/ntpd.1 + + ntpd/ntpd.1@1.0, 2007-03-03 22:40:25-05:00, stenn@whimsy.udel.edu +0 -0 + + ntpd/ntpdsim-opts.c@1.1, 2007-03-03 22:40:27-05:00, stenn@whimsy.udel.edu +1253 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpd/ntpdsim-opts.c + + ntpd/ntpdsim-opts.c@1.0, 2007-03-03 22:40:27-05:00, stenn@whimsy.udel.edu +0 -0 + + ntpd/ntpdsim-opts.h@1.1, 2007-03-03 22:40:29-05:00, stenn@whimsy.udel.edu +429 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpd/ntpdsim-opts.h + + ntpd/ntpdsim-opts.h@1.0, 2007-03-03 22:40:29-05:00, stenn@whimsy.udel.edu +0 -0 + + ntpd/ntpdsim-opts.texi@1.1, 2007-03-03 22:40:32-05:00, stenn@whimsy.udel.edu +510 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpd/ntpdsim-opts.texi + + ntpd/ntpdsim-opts.texi@1.0, 2007-03-03 22:40:32-05:00, stenn@whimsy.udel.edu +0 -0 + + ntpd/ntpdsim.1@1.1, 2007-03-03 22:40:35-05:00, stenn@whimsy.udel.edu +357 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpd/ntpdsim.1 + + ntpd/ntpdsim.1@1.0, 2007-03-03 22:40:35-05:00, stenn@whimsy.udel.edu +0 -0 + + ntpdc/ntpdc-opts.c@1.1, 2007-03-03 22:40:37-05:00, stenn@whimsy.udel.edu +658 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpdc/ntpdc-opts.c + + ntpdc/ntpdc-opts.c@1.0, 2007-03-03 22:40:37-05:00, stenn@whimsy.udel.edu +0 -0 + + ntpdc/ntpdc-opts.h@1.1, 2007-03-03 22:40:41-05:00, stenn@whimsy.udel.edu +229 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpdc/ntpdc-opts.h + + ntpdc/ntpdc-opts.h@1.0, 2007-03-03 22:40:41-05:00, stenn@whimsy.udel.edu +0 -0 + + ntpdc/ntpdc-opts.texi@1.1, 2007-03-03 22:40:43-05:00, stenn@whimsy.udel.edu +276 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpdc/ntpdc-opts.texi + + ntpdc/ntpdc-opts.texi@1.0, 2007-03-03 22:40:43-05:00, stenn@whimsy.udel.edu +0 -0 + + ntpdc/ntpdc.1@1.1, 2007-03-03 22:40:45-05:00, stenn@whimsy.udel.edu +158 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpdc/ntpdc.1 + + ntpdc/ntpdc.1@1.0, 2007-03-03 22:40:45-05:00, stenn@whimsy.udel.edu +0 -0 + + ntpq/ntpq-opts.c@1.1, 2007-03-03 22:40:48-05:00, stenn@whimsy.udel.edu +598 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpq/ntpq-opts.c + + ntpq/ntpq-opts.c@1.0, 2007-03-03 22:40:48-05:00, stenn@whimsy.udel.edu +0 -0 + + ntpq/ntpq-opts.h@1.1, 2007-03-03 22:40:51-05:00, stenn@whimsy.udel.edu +215 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpq/ntpq-opts.h + + ntpq/ntpq-opts.h@1.0, 2007-03-03 22:40:51-05:00, stenn@whimsy.udel.edu +0 -0 + + ntpq/ntpq-opts.texi@1.1, 2007-03-03 22:40:54-05:00, stenn@whimsy.udel.edu +216 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpq/ntpq-opts.texi + + ntpq/ntpq-opts.texi@1.0, 2007-03-03 22:40:54-05:00, stenn@whimsy.udel.edu +0 -0 + + ntpq/ntpq.1@1.1, 2007-03-03 22:40:58-05:00, stenn@whimsy.udel.edu +385 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpq/ntpq.1 + + ntpq/ntpq.1@1.0, 2007-03-03 22:40:58-05:00, stenn@whimsy.udel.edu +0 -0 + + sntp/sntp-opts.c@1.1, 2007-03-03 22:41:02-05:00, stenn@whimsy.udel.edu +682 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/sntp-opts.c + + sntp/sntp-opts.c@1.0, 2007-03-03 22:41:02-05:00, stenn@whimsy.udel.edu +0 -0 + + sntp/sntp-opts.h@1.1, 2007-03-03 22:41:04-05:00, stenn@whimsy.udel.edu +290 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/sntp-opts.h + + sntp/sntp-opts.h@1.0, 2007-03-03 22:41:04-05:00, stenn@whimsy.udel.edu +0 -0 + + sntp/sntp-opts.texi@1.1, 2007-03-03 22:41:07-05:00, stenn@whimsy.udel.edu +174 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/sntp-opts.texi + + sntp/sntp-opts.texi@1.0, 2007-03-03 22:41:07-05:00, stenn@whimsy.udel.edu +0 -0 + + sntp/sntp.1@1.1, 2007-03-03 22:41:09-05:00, stenn@whimsy.udel.edu +400 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/sntp.1 + + sntp/sntp.1@1.0, 2007-03-03 22:41:09-05:00, stenn@whimsy.udel.edu +0 -0 + + util/ntp-keygen-opts.c@1.1, 2007-03-03 22:41:12-05:00, stenn@whimsy.udel.edu +1035 -0 + BitKeeper file /deacon/backroom/ntp-dev/util/ntp-keygen-opts.c + + util/ntp-keygen-opts.c@1.0, 2007-03-03 22:41:12-05:00, stenn@whimsy.udel.edu +0 -0 + + util/ntp-keygen-opts.h@1.1, 2007-03-03 22:41:15-05:00, stenn@whimsy.udel.edu +325 -0 + BitKeeper file /deacon/backroom/ntp-dev/util/ntp-keygen-opts.h + + util/ntp-keygen-opts.h@1.0, 2007-03-03 22:41:15-05:00, stenn@whimsy.udel.edu +0 -0 + + util/ntp-keygen-opts.texi@1.1, 2007-03-03 22:41:17-05:00, stenn@whimsy.udel.edu +366 -0 + BitKeeper file /deacon/backroom/ntp-dev/util/ntp-keygen-opts.texi + + util/ntp-keygen-opts.texi@1.0, 2007-03-03 22:41:17-05:00, stenn@whimsy.udel.edu +0 -0 + + util/ntp-keygen.1@1.1, 2007-03-03 22:41:20-05:00, stenn@whimsy.udel.edu +176 -0 + BitKeeper file /deacon/backroom/ntp-dev/util/ntp-keygen.1 + + util/ntp-keygen.1@1.0, 2007-03-03 22:41:20-05:00, stenn@whimsy.udel.edu +0 -0 + +ChangeSet@1.1436.1.34, 2007-03-03 19:21:29-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 793] Update Hans Lambermont's email address in ntpsweep + + ChangeLog@1.1.1.9, 2007-03-03 19:21:16-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 793] Update Hans Lambermont's email address in ntpsweep + + scripts/ntpsweep.in@1.3, 2007-03-03 19:21:17-05:00, stenn@whimsy.udel.edu +1 -2 + [Bug 793] Update Hans Lambermont's email address in ntpsweep + +ChangeSet@1.1440.1.58, 2007-03-03 06:43:50-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P15 + TAG: NTP_4_2_5P15 + + ntpd/ntpd-opts.c@1.70, 2007-03-03 06:43:27-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P15 + + ntpd/ntpd-opts.h@1.70, 2007-03-03 06:43:27-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P15 + + ntpd/ntpd-opts.texi@1.69, 2007-03-03 06:43:28-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P15 + + ntpd/ntpd.1@1.68, 2007-03-03 06:43:29-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P15 + + ntpd/ntpdsim-opts.c@1.70, 2007-03-03 06:43:29-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P15 + + ntpd/ntpdsim-opts.h@1.70, 2007-03-03 06:43:30-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P15 + + ntpd/ntpdsim-opts.texi@1.68, 2007-03-03 06:43:32-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P15 + + ntpd/ntpdsim.1@1.68, 2007-03-03 06:43:33-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P15 + + ntpdc/ntpdc-opts.c@1.70, 2007-03-03 06:43:33-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P15 + + ntpdc/ntpdc-opts.h@1.70, 2007-03-03 06:43:34-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P15 + + ntpdc/ntpdc-opts.texi@1.68, 2007-03-03 06:43:35-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P15 + + ntpdc/ntpdc.1@1.68, 2007-03-03 06:43:36-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P15 + + ntpq/ntpq-opts.c@1.72, 2007-03-03 06:43:36-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P15 + + ntpq/ntpq-opts.h@1.72, 2007-03-03 06:43:37-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P15 + + ntpq/ntpq-opts.texi@1.69, 2007-03-03 06:43:38-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P15 + + ntpq/ntpq.1@1.68, 2007-03-03 06:43:38-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P15 + + packageinfo.sh@1.18, 2007-03-03 06:43:39-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P15 + + sntp/sntp-opts.c@1.69, 2007-03-03 06:43:39-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P15 + + sntp/sntp-opts.h@1.69, 2007-03-03 06:43:40-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P15 + + sntp/sntp-opts.texi@1.66, 2007-03-03 06:43:41-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P15 + + sntp/sntp.1@1.69, 2007-03-03 06:43:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P15 + + util/ntp-keygen-opts.c@1.69, 2007-03-03 06:43:43-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P15 + + util/ntp-keygen-opts.h@1.69, 2007-03-03 06:43:44-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P15 + + util/ntp-keygen-opts.texi@1.67, 2007-03-03 06:43:45-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P15 + + util/ntp-keygen.1@1.67, 2007-03-03 06:43:46-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P15 + +ChangeSet@1.1440.1.57, 2007-03-03 01:16:11-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 786] Fix refclock_bancomm.c on Solaris + + ChangeLog@1.16, 2007-03-03 01:15:58-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 786] Fix refclock_bancomm.c on Solaris + +ChangeSet@1.1440.1.56, 2007-03-01 10:16:30-05:00, neal@pogo.udel.edu +1 -0 + refclock_bancomm.c: + [BUG 786] - add Solaris 10 support + + ntpd/refclock_bancomm.c@1.10, 2007-03-01 10:13:45-05:00, neal@pogo.udel.edu +97 -17 + [BUG 786] - add Solaris 10 support + +ChangeSet@1.1440.1.55, 2007-02-26 06:42:31-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P14 + TAG: NTP_4_2_5P14 + + ntpd/ntpd-opts.c@1.69, 2007-02-26 06:42:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P14 + + ntpd/ntpd-opts.h@1.69, 2007-02-26 06:42:10-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P14 + + ntpd/ntpd-opts.texi@1.68, 2007-02-26 06:42:11-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P14 + + ntpd/ntpd.1@1.67, 2007-02-26 06:42:12-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P14 + + ntpd/ntpdsim-opts.c@1.69, 2007-02-26 06:42:13-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P14 + + ntpd/ntpdsim-opts.h@1.69, 2007-02-26 06:42:14-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P14 + + ntpd/ntpdsim-opts.texi@1.67, 2007-02-26 06:42:15-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P14 + + ntpd/ntpdsim.1@1.67, 2007-02-26 06:42:15-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P14 + + ntpdc/ntpdc-opts.c@1.69, 2007-02-26 06:42:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P14 + + ntpdc/ntpdc-opts.h@1.69, 2007-02-26 06:42:17-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P14 + + ntpdc/ntpdc-opts.texi@1.67, 2007-02-26 06:42:18-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P14 + + ntpdc/ntpdc.1@1.67, 2007-02-26 06:42:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P14 + + ntpq/ntpq-opts.c@1.71, 2007-02-26 06:42:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P14 + + ntpq/ntpq-opts.h@1.71, 2007-02-26 06:42:20-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P14 + + ntpq/ntpq-opts.texi@1.68, 2007-02-26 06:42:21-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P14 + + ntpq/ntpq.1@1.67, 2007-02-26 06:42:22-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P14 + + packageinfo.sh@1.17, 2007-02-26 06:42:23-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P14 + + sntp/sntp-opts.c@1.68, 2007-02-26 06:42:23-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P14 + + sntp/sntp-opts.h@1.68, 2007-02-26 06:42:24-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P14 + + sntp/sntp-opts.texi@1.65, 2007-02-26 06:42:25-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P14 + + sntp/sntp.1@1.68, 2007-02-26 06:42:25-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P14 + + util/ntp-keygen-opts.c@1.68, 2007-02-26 06:42:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P14 + + util/ntp-keygen-opts.h@1.68, 2007-02-26 06:42:27-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P14 + + util/ntp-keygen-opts.texi@1.66, 2007-02-26 06:42:27-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P14 + + util/ntp-keygen.1@1.66, 2007-02-26 06:42:27-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P14 + +ChangeSet@1.1440.1.54, 2007-02-25 18:42:26-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 789] Fix multicast client crypto authentication + + ChangeLog@1.15, 2007-02-25 18:42:16-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 789] Fix multicast client crypto authentication + +ChangeSet@1.1440.1.53, 2007-02-25 17:21:59+00:00, kardel@pogo.udel.edu +1 -0 + ntp_peer.c: + Bug 789: + insure that crypto information is only cleared when the local address + changes. fixes multicast client mode + + ntpd/ntp_peer.c@1.100, 2007-02-25 17:01:10+00:00, kardel@pogo.udel.edu +10 -13 + Bug 789: + insure that crypto information is only cleared when the local address + changes. fixes multicast client mode + +ChangeSet@1.1440.1.52, 2007-02-25 06:42:44-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P13 + TAG: NTP_4_2_5P13 + + ntpd/ntpd-opts.c@1.68, 2007-02-25 06:42:22-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P13 + + ntpd/ntpd-opts.h@1.68, 2007-02-25 06:42:23-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P13 + + ntpd/ntpd-opts.texi@1.67, 2007-02-25 06:42:23-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P13 + + ntpd/ntpd.1@1.66, 2007-02-25 06:42:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P13 + + ntpd/ntpdsim-opts.c@1.68, 2007-02-25 06:42:25-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P13 + + ntpd/ntpdsim-opts.h@1.68, 2007-02-25 06:42:25-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P13 + + ntpd/ntpdsim-opts.texi@1.66, 2007-02-25 06:42:26-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P13 + + ntpd/ntpdsim.1@1.66, 2007-02-25 06:42:27-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P13 + + ntpdc/ntpdc-opts.c@1.68, 2007-02-25 06:42:28-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P13 + + ntpdc/ntpdc-opts.h@1.68, 2007-02-25 06:42:28-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P13 + + ntpdc/ntpdc-opts.texi@1.66, 2007-02-25 06:42:30-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P13 + + ntpdc/ntpdc.1@1.66, 2007-02-25 06:42:31-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P13 + + ntpq/ntpq-opts.c@1.70, 2007-02-25 06:42:31-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P13 + + ntpq/ntpq-opts.h@1.70, 2007-02-25 06:42:32-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P13 + + ntpq/ntpq-opts.texi@1.67, 2007-02-25 06:42:33-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P13 + + ntpq/ntpq.1@1.66, 2007-02-25 06:42:33-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P13 + + packageinfo.sh@1.16, 2007-02-25 06:42:34-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P13 + + sntp/sntp-opts.c@1.67, 2007-02-25 06:42:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P13 + + sntp/sntp-opts.h@1.67, 2007-02-25 06:42:35-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P13 + + sntp/sntp-opts.texi@1.64, 2007-02-25 06:42:36-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P13 + + sntp/sntp.1@1.67, 2007-02-25 06:42:37-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P13 + + util/ntp-keygen-opts.c@1.67, 2007-02-25 06:42:37-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P13 + + util/ntp-keygen-opts.h@1.67, 2007-02-25 06:42:38-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P13 + + util/ntp-keygen-opts.texi@1.65, 2007-02-25 06:42:39-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P13 + + util/ntp-keygen.1@1.65, 2007-02-25 06:42:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P13 + +ChangeSet@1.1440.1.51, 2007-02-25 00:21:52+00:00, kardel@pogo.udel.edu +2 -0 + ntp_io.c: + bug 785: + improve handling of multicast interfaces + (multicast routers still need to run a multicast routing software/daemon) + ntp_peer.c: + clarify debug messages + + ntpd/ntp_io.c@1.245.1.3, 2007-02-25 00:17:43+00:00, kardel@pogo.udel.edu +84 -62 + bug 785: + improve handling of multicast interfaces + (multicast routers still need to run a multicast routing software/daemon) + + ntpd/ntp_peer.c@1.99, 2007-02-25 00:20:28+00:00, kardel@pogo.udel.edu +2 -2 + clarify debug messages + +ChangeSet@1.1440.1.50, 2007-02-24 08:33:25-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P12 + TAG: NTP_4_2_5P12 + + ntpd/ntpd-opts.c@1.67, 2007-02-24 08:33:01-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P12 + + ntpd/ntpd-opts.h@1.67, 2007-02-24 08:33:03-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P12 + + ntpd/ntpd-opts.texi@1.66, 2007-02-24 08:33:04-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P12 + + ntpd/ntpd.1@1.65, 2007-02-24 08:33:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P12 + + ntpd/ntpdsim-opts.c@1.67, 2007-02-24 08:33:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P12 + + ntpd/ntpdsim-opts.h@1.67, 2007-02-24 08:33:06-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P12 + + ntpd/ntpdsim-opts.texi@1.65, 2007-02-24 08:33:07-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P12 + + ntpd/ntpdsim.1@1.65, 2007-02-24 08:33:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P12 + + ntpdc/ntpdc-opts.c@1.67, 2007-02-24 08:33:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P12 + + ntpdc/ntpdc-opts.h@1.67, 2007-02-24 08:33:09-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P12 + + ntpdc/ntpdc-opts.texi@1.65, 2007-02-24 08:33:10-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P12 + + ntpdc/ntpdc.1@1.65, 2007-02-24 08:33:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P12 + + ntpq/ntpq-opts.c@1.69, 2007-02-24 08:33:12-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P12 + + ntpq/ntpq-opts.h@1.69, 2007-02-24 08:33:13-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P12 + + ntpq/ntpq-opts.texi@1.66, 2007-02-24 08:33:14-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P12 + + ntpq/ntpq.1@1.65, 2007-02-24 08:33:15-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P12 + + packageinfo.sh@1.15, 2007-02-24 08:33:15-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P12 + + sntp/sntp-opts.c@1.66, 2007-02-24 08:33:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P12 + + sntp/sntp-opts.h@1.66, 2007-02-24 08:33:16-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P12 + + sntp/sntp-opts.texi@1.63, 2007-02-24 08:33:17-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P12 + + sntp/sntp.1@1.66, 2007-02-24 08:33:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P12 + + util/ntp-keygen-opts.c@1.66, 2007-02-24 08:33:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P12 + + util/ntp-keygen-opts.h@1.66, 2007-02-24 08:33:19-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P12 + + util/ntp-keygen-opts.texi@1.64, 2007-02-24 08:33:20-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P12 + + util/ntp-keygen.1@1.64, 2007-02-24 08:33:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P12 + +ChangeSet@1.1436.1.33, 2007-02-24 06:42:26-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_4P0_RC5 + TAG: NTP_4_2_4P0_RC5 + + ntpd/ntpd-opts.c@1.50.1.5, 2007-02-24 06:42:04-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC5 + + ntpd/ntpd-opts.h@1.50.1.5, 2007-02-24 06:42:05-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P0_RC5 + + ntpd/ntpd-opts.texi@1.49.1.5, 2007-02-24 06:42:06-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P0_RC5 + + ntpd/ntpd.1@1.48.1.5, 2007-02-24 06:42:07-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC5 + + ntpd/ntpdsim-opts.c@1.50.1.5, 2007-02-24 06:42:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC5 + + ntpd/ntpdsim-opts.h@1.50.1.5, 2007-02-24 06:42:08-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P0_RC5 + + ntpd/ntpdsim-opts.texi@1.48.1.5, 2007-02-24 06:42:09-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P0_RC5 + + ntpd/ntpdsim.1@1.48.1.5, 2007-02-24 06:42:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC5 + + ntpdc/ntpdc-opts.c@1.50.1.5, 2007-02-24 06:42:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC5 + + ntpdc/ntpdc-opts.h@1.50.1.5, 2007-02-24 06:42:11-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P0_RC5 + + ntpdc/ntpdc-opts.texi@1.48.1.5, 2007-02-24 06:42:12-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P0_RC5 + + ntpdc/ntpdc.1@1.48.1.5, 2007-02-24 06:42:13-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC5 + + ntpq/ntpq-opts.c@1.52.1.5, 2007-02-24 06:42:13-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC5 + + ntpq/ntpq-opts.h@1.52.1.5, 2007-02-24 06:42:14-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P0_RC5 + + ntpq/ntpq-opts.texi@1.49.1.5, 2007-02-24 06:42:15-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P0_RC5 + + ntpq/ntpq.1@1.48.1.5, 2007-02-24 06:42:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC5 + + packageinfo.sh@1.65.6.1, 2007-02-24 06:42:17-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P0_RC5 + + sntp/sntp-opts.c@1.49.1.5, 2007-02-24 06:42:17-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC5 + + sntp/sntp-opts.h@1.49.1.5, 2007-02-24 06:42:18-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P0_RC5 + + sntp/sntp-opts.texi@1.46.1.5, 2007-02-24 06:42:18-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P0_RC5 + + sntp/sntp.1@1.49.1.5, 2007-02-24 06:42:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC5 + + util/ntp-keygen-opts.c@1.49.1.5, 2007-02-24 06:42:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC5 + + util/ntp-keygen-opts.h@1.49.1.5, 2007-02-24 06:42:21-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P0_RC5 + + util/ntp-keygen-opts.texi@1.47.1.5, 2007-02-24 06:42:21-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P0_RC5 + + util/ntp-keygen.1@1.47.1.5, 2007-02-24 06:42:22-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC5 + +ChangeSet@1.1440.1.49, 2007-02-24 05:24:04-05:00, stenn@whimsy.udel.edu +1 -0 + Updates to ntp_loopfilter.c from Dave Mills + + ntpd/ntp_loopfilter.c@1.132, 2007-02-24 05:23:52-05:00, stenn@whimsy.udel.edu +2 -3 + Updates to ntp_loopfilter.c from Dave Mills + +ChangeSet@1.1436.1.32, 2007-02-24 05:07:16-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 628] Fallback to ntp discipline not working for large offsets + + ntpd/ntp_loopfilter.c@1.127.1.1, 2007-02-24 05:07:04-05:00, stenn@whimsy.udel.edu +9 -24 + [Bug 628] Fallback to ntp discipline not working for large offsets + +ChangeSet@1.1440.1.47, 2007-02-23 06:42:48-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P11 + TAG: NTP_4_2_5P11 + + ntpd/ntpd-opts.c@1.66, 2007-02-23 06:42:25-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P11 + + ntpd/ntpd-opts.h@1.66, 2007-02-23 06:42:26-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P11 + + ntpd/ntpd-opts.texi@1.65, 2007-02-23 06:42:27-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P11 + + ntpd/ntpd.1@1.64, 2007-02-23 06:42:28-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P11 + + ntpd/ntpdsim-opts.c@1.66, 2007-02-23 06:42:28-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P11 + + ntpd/ntpdsim-opts.h@1.66, 2007-02-23 06:42:29-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P11 + + ntpd/ntpdsim-opts.texi@1.64, 2007-02-23 06:42:31-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P11 + + ntpd/ntpdsim.1@1.64, 2007-02-23 06:42:31-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P11 + + ntpdc/ntpdc-opts.c@1.66, 2007-02-23 06:42:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P11 + + ntpdc/ntpdc-opts.h@1.66, 2007-02-23 06:42:33-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P11 + + ntpdc/ntpdc-opts.texi@1.64, 2007-02-23 06:42:33-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P11 + + ntpdc/ntpdc.1@1.64, 2007-02-23 06:42:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P11 + + ntpq/ntpq-opts.c@1.68, 2007-02-23 06:42:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P11 + + ntpq/ntpq-opts.h@1.68, 2007-02-23 06:42:36-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P11 + + ntpq/ntpq-opts.texi@1.65, 2007-02-23 06:42:37-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P11 + + ntpq/ntpq.1@1.64, 2007-02-23 06:42:38-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P11 + + packageinfo.sh@1.14, 2007-02-23 06:42:39-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P11 + + sntp/sntp-opts.c@1.65, 2007-02-23 06:42:39-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P11 + + sntp/sntp-opts.h@1.65, 2007-02-23 06:42:40-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P11 + + sntp/sntp-opts.texi@1.62, 2007-02-23 06:42:40-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P11 + + sntp/sntp.1@1.65, 2007-02-23 06:42:41-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P11 + + util/ntp-keygen-opts.c@1.65, 2007-02-23 06:42:42-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P11 + + util/ntp-keygen-opts.h@1.65, 2007-02-23 06:42:42-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P11 + + util/ntp-keygen-opts.texi@1.63, 2007-02-23 06:42:43-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P11 + + util/ntp-keygen.1@1.63, 2007-02-23 06:42:45-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P11 + +ChangeSet@1.1440.1.46, 2007-02-23 03:16:58-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 774] parsesolaris.c does not compile under the new Solaris + + libparse/Makefile.am@1.11, 2007-02-23 03:16:47-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 774] parsesolaris.c does not compile under the new Solaris + +ChangeSet@1.1440.1.45, 2007-02-23 02:47:57-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 774] parsesolaris.c does not compile under the new Solaris + + ChangeLog@1.14, 2007-02-23 02:47:42-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 774] parsesolaris.c does not compile under the new Solaris + + libparse/Makefile.am@1.10, 2007-02-23 02:47:12-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 774] parsesolaris.c does not compile under the new Solaris + +ChangeSet@1.1440.1.44, 2007-02-22 06:46:29-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P10 + TAG: NTP_4_2_5P10 + + ntpd/ntpd-opts.c@1.65, 2007-02-22 06:46:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P10 + + ntpd/ntpd-opts.h@1.65, 2007-02-22 06:46:10-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P10 + + ntpd/ntpd-opts.texi@1.64, 2007-02-22 06:46:10-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P10 + + ntpd/ntpd.1@1.63, 2007-02-22 06:46:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P10 + + ntpd/ntpdsim-opts.c@1.65, 2007-02-22 06:46:12-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P10 + + ntpd/ntpdsim-opts.h@1.65, 2007-02-22 06:46:12-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P10 + + ntpd/ntpdsim-opts.texi@1.63, 2007-02-22 06:46:13-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P10 + + ntpd/ntpdsim.1@1.63, 2007-02-22 06:46:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P10 + + ntpdc/ntpdc-opts.c@1.65, 2007-02-22 06:46:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P10 + + ntpdc/ntpdc-opts.h@1.65, 2007-02-22 06:46:15-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P10 + + ntpdc/ntpdc-opts.texi@1.63, 2007-02-22 06:46:16-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P10 + + ntpdc/ntpdc.1@1.63, 2007-02-22 06:46:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P10 + + ntpq/ntpq-opts.c@1.67, 2007-02-22 06:46:17-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P10 + + ntpq/ntpq-opts.h@1.67, 2007-02-22 06:46:18-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P10 + + ntpq/ntpq-opts.texi@1.64, 2007-02-22 06:46:18-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P10 + + ntpq/ntpq.1@1.63, 2007-02-22 06:46:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P10 + + packageinfo.sh@1.13, 2007-02-22 06:46:20-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P10 + + sntp/sntp-opts.c@1.64, 2007-02-22 06:46:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P10 + + sntp/sntp-opts.h@1.64, 2007-02-22 06:46:21-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P10 + + sntp/sntp-opts.texi@1.61, 2007-02-22 06:46:21-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P10 + + sntp/sntp.1@1.64, 2007-02-22 06:46:22-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P10 + + util/ntp-keygen-opts.c@1.64, 2007-02-22 06:46:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P10 + + util/ntp-keygen-opts.h@1.64, 2007-02-22 06:46:24-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P10 + + util/ntp-keygen-opts.texi@1.62, 2007-02-22 06:46:25-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P10 + + util/ntp-keygen.1@1.62, 2007-02-22 06:46:25-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P10 + +ChangeSet@1.1436.1.31, 2007-02-21 15:16:15-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 776] Remove the obsolete r: from the getopt string in ntpdate + + ntpdate/ntpdate.c@1.59.1.2, 2007-02-21 15:16:00-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 776] Remove the obsolete r: from the getopt string in ntpdate + +ChangeSet@1.1440.1.42, 2007-02-19 08:43:35-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P9 + TAG: NTP_4_2_5P9 + + ntpd/ntpd-opts.c@1.63, 2007-02-19 08:43:12-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P9 + + ntpd/ntpd-opts.h@1.63, 2007-02-19 08:43:13-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P9 + + ntpd/ntpd-opts.texi@1.62, 2007-02-19 08:43:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P9 + + ntpd/ntpd.1@1.61, 2007-02-19 08:43:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P9 + + ntpd/ntpdsim-opts.c@1.63, 2007-02-19 08:43:15-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P9 + + ntpd/ntpdsim-opts.h@1.63, 2007-02-19 08:43:17-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P9 + + ntpd/ntpdsim-opts.texi@1.61, 2007-02-19 08:43:18-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P9 + + ntpd/ntpdsim.1@1.61, 2007-02-19 08:43:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P9 + + ntpdc/ntpdc-opts.c@1.63, 2007-02-19 08:43:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P9 + + ntpdc/ntpdc-opts.h@1.63, 2007-02-19 08:43:19-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P9 + + ntpdc/ntpdc-opts.texi@1.61, 2007-02-19 08:43:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P9 + + ntpdc/ntpdc.1@1.61, 2007-02-19 08:43:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P9 + + ntpq/ntpq-opts.c@1.65, 2007-02-19 08:43:22-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P9 + + ntpq/ntpq-opts.h@1.65, 2007-02-19 08:43:23-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P9 + + ntpq/ntpq-opts.texi@1.62, 2007-02-19 08:43:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P9 + + ntpq/ntpq.1@1.61, 2007-02-19 08:43:25-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P9 + + packageinfo.sh@1.12, 2007-02-19 08:43:25-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P9 + + sntp/sntp-opts.c@1.62, 2007-02-19 08:43:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P9 + + sntp/sntp-opts.h@1.62, 2007-02-19 08:43:26-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P9 + + sntp/sntp-opts.texi@1.59, 2007-02-19 08:43:27-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P9 + + sntp/sntp.1@1.62, 2007-02-19 08:43:28-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P9 + + util/ntp-keygen-opts.c@1.62, 2007-02-19 08:43:28-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P9 + + util/ntp-keygen-opts.h@1.62, 2007-02-19 08:43:29-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P9 + + util/ntp-keygen-opts.texi@1.60, 2007-02-19 08:43:30-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P9 + + util/ntp-keygen.1@1.60, 2007-02-19 08:43:31-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P9 + +ChangeSet@1.1436.1.30, 2007-02-19 06:46:30-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_4P0_RC4 + TAG: NTP_4_2_4P0_RC4 + + ntpd/ntpd-opts.c@1.50.1.4, 2007-02-19 06:46:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC4 + + ntpd/ntpd-opts.h@1.50.1.4, 2007-02-19 06:46:11-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P0_RC4 + + ntpd/ntpd-opts.texi@1.49.1.4, 2007-02-19 06:46:12-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC4 + + ntpd/ntpd.1@1.48.1.4, 2007-02-19 06:46:13-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC4 + + ntpd/ntpdsim-opts.c@1.50.1.4, 2007-02-19 06:46:13-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC4 + + ntpd/ntpdsim-opts.h@1.50.1.4, 2007-02-19 06:46:14-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P0_RC4 + + ntpd/ntpdsim-opts.texi@1.48.1.4, 2007-02-19 06:46:15-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P0_RC4 + + ntpd/ntpdsim.1@1.48.1.4, 2007-02-19 06:46:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC4 + + ntpdc/ntpdc-opts.c@1.50.1.4, 2007-02-19 06:46:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC4 + + ntpdc/ntpdc-opts.h@1.50.1.4, 2007-02-19 06:46:17-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P0_RC4 + + ntpdc/ntpdc-opts.texi@1.48.1.4, 2007-02-19 06:46:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC4 + + ntpdc/ntpdc.1@1.48.1.4, 2007-02-19 06:46:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC4 + + ntpq/ntpq-opts.c@1.52.1.4, 2007-02-19 06:46:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC4 + + ntpq/ntpq-opts.h@1.52.1.4, 2007-02-19 06:46:19-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P0_RC4 + + ntpq/ntpq-opts.texi@1.49.1.4, 2007-02-19 06:46:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC4 + + ntpq/ntpq.1@1.48.1.4, 2007-02-19 06:46:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC4 + + packageinfo.sh@1.65.5.1, 2007-02-19 06:46:22-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P0_RC4 + + sntp/sntp-opts.c@1.49.1.4, 2007-02-19 06:46:22-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC4 + + sntp/sntp-opts.h@1.49.1.4, 2007-02-19 06:46:23-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P0_RC4 + + sntp/sntp-opts.texi@1.46.1.4, 2007-02-19 06:46:24-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4P0_RC4 + + sntp/sntp.1@1.49.1.4, 2007-02-19 06:46:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC4 + + util/ntp-keygen-opts.c@1.49.1.4, 2007-02-19 06:46:25-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC4 + + util/ntp-keygen-opts.h@1.49.1.4, 2007-02-19 06:46:25-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4P0_RC4 + + util/ntp-keygen-opts.texi@1.47.1.4, 2007-02-19 06:46:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC4 + + util/ntp-keygen.1@1.47.1.4, 2007-02-19 06:46:27-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4P0_RC4 + +ChangeSet@1.1440.1.41, 2007-02-19 05:26:33-05:00, stenn@whimsy.udel.edu +4 -0 + [Bug 782] Remove P() macros from Windows files + + ChangeLog@1.13, 2007-02-19 05:26:20-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 782] Remove P() macros from Windows files + + ports/winnt/include/ntp_timer.h@1.4, 2007-02-19 05:25:50-05:00, stenn@whimsy.udel.edu +3 -5 + [Bug 782] Remove P() macros from Windows files + + ports/winnt/include/transmitbuff.h@1.6, 2007-02-19 05:25:51-05:00, stenn@whimsy.udel.edu +3 -3 + [Bug 782] Remove P() macros from Windows files + + ports/winnt/include/win32_io.h@1.8, 2007-02-19 05:25:51-05:00, stenn@whimsy.udel.edu +2 -2 + [Bug 782] Remove P() macros from Windows files + +ChangeSet@1.1436.1.29, 2007-02-19 00:19:22-05:00, stenn@whimsy.udel.edu +1 -0 + Ready to go... + + packageinfo.sh@1.65.4.2, 2007-02-19 00:19:05-05:00, stenn@whimsy.udel.edu +2 -2 + Ready to go... + +ChangeSet@1.1436.1.28, 2007-02-19 00:14:29-05:00, stenn@whimsy.udel.edu +3 -0 + [Bug 776] Remove unimplemented "rate" flag from ntpdate + + ChangeLog@1.1.1.8, 2007-02-19 00:14:19-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 776] Remove unimplemented "rate" flag from ntpdate + + ntpdate/Makefile.am@1.14.1.1, 2007-02-19 00:13:50-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 776] Remove unimplemented "rate" flag from ntpdate + + ntpdate/ntpdate.c@1.59.1.1, 2007-02-19 00:13:51-05:00, stenn@whimsy.udel.edu +1 -21 + [Bug 776] Remove unimplemented "rate" flag from ntpdate + +ChangeSet@1.1440.1.39, 2007-02-17 06:42:34-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P8 + TAG: NTP_4_2_5P8 + + ntpd/ntpd-opts.c@1.61, 2007-02-17 06:42:12-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P8 + + ntpd/ntpd-opts.h@1.61, 2007-02-17 06:42:13-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P8 + + ntpd/ntpd-opts.texi@1.60, 2007-02-17 06:42:14-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P8 + + ntpd/ntpd.1@1.59, 2007-02-17 06:42:15-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P8 + + ntpd/ntpdsim-opts.c@1.61, 2007-02-17 06:42:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P8 + + ntpd/ntpdsim-opts.h@1.61, 2007-02-17 06:42:16-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P8 + + ntpd/ntpdsim-opts.texi@1.59, 2007-02-17 06:42:17-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P8 + + ntpd/ntpdsim.1@1.59, 2007-02-17 06:42:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P8 + + ntpdc/ntpdc-opts.c@1.61, 2007-02-17 06:42:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P8 + + ntpdc/ntpdc-opts.h@1.61, 2007-02-17 06:42:19-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P8 + + ntpdc/ntpdc-opts.texi@1.59, 2007-02-17 06:42:20-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P8 + + ntpdc/ntpdc.1@1.59, 2007-02-17 06:42:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P8 + + ntpq/ntpq-opts.c@1.63, 2007-02-17 06:42:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P8 + + ntpq/ntpq-opts.h@1.63, 2007-02-17 06:42:22-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P8 + + ntpq/ntpq-opts.texi@1.60, 2007-02-17 06:42:23-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P8 + + ntpq/ntpq.1@1.59, 2007-02-17 06:42:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P8 + + packageinfo.sh@1.11, 2007-02-17 06:42:25-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P8 + + sntp/sntp-opts.c@1.60, 2007-02-17 06:42:25-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P8 + + sntp/sntp-opts.h@1.60, 2007-02-17 06:42:26-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P8 + + sntp/sntp-opts.texi@1.57, 2007-02-17 06:42:27-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P8 + + sntp/sntp.1@1.60, 2007-02-17 06:42:27-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P8 + + util/ntp-keygen-opts.c@1.60, 2007-02-17 06:42:28-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P8 + + util/ntp-keygen-opts.h@1.60, 2007-02-17 06:42:29-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P8 + + util/ntp-keygen-opts.texi@1.58, 2007-02-17 06:42:30-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P8 + + util/ntp-keygen.1@1.58, 2007-02-17 06:42:30-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P8 + +ChangeSet@1.1440.1.38, 2007-02-17 04:40:04-05:00, stenn@whimsy.udel.edu +1 -0 + ntpd.h: + Lose the fabs() and sqrt() declarations because + they are in math.h and "lose" on some HP-UX machines. + + include/ntpd.h@1.100, 2007-02-17 04:37:45-05:00, stenn@whimsy.udel.edu +0 -3 + Lose the fabs() and sqrt() declarations because + they are in math.h and "lose" on some HP-UX machines. + +ChangeSet@1.1440.1.37, 2007-02-16 06:42:39-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P7 + TAG: NTP_4_2_5P7 + + ntpd/ntpd-opts.c@1.60, 2007-02-16 06:42:17-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P7 + + ntpd/ntpd-opts.h@1.60, 2007-02-16 06:42:17-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P7 + + ntpd/ntpd-opts.texi@1.59, 2007-02-16 06:42:19-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P7 + + ntpd/ntpd.1@1.58, 2007-02-16 06:42:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P7 + + ntpd/ntpdsim-opts.c@1.60, 2007-02-16 06:42:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P7 + + ntpd/ntpdsim-opts.h@1.60, 2007-02-16 06:42:21-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P7 + + ntpd/ntpdsim-opts.texi@1.58, 2007-02-16 06:42:22-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P7 + + ntpd/ntpdsim.1@1.58, 2007-02-16 06:42:23-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P7 + + ntpdc/ntpdc-opts.c@1.60, 2007-02-16 06:42:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P7 + + ntpdc/ntpdc-opts.h@1.60, 2007-02-16 06:42:24-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P7 + + ntpdc/ntpdc-opts.texi@1.58, 2007-02-16 06:42:25-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P7 + + ntpdc/ntpdc.1@1.58, 2007-02-16 06:42:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P7 + + ntpq/ntpq-opts.c@1.62, 2007-02-16 06:42:27-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P7 + + ntpq/ntpq-opts.h@1.62, 2007-02-16 06:42:28-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P7 + + ntpq/ntpq-opts.texi@1.59, 2007-02-16 06:42:29-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P7 + + ntpq/ntpq.1@1.58, 2007-02-16 06:42:30-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P7 + + packageinfo.sh@1.10, 2007-02-16 06:42:30-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P7 + + sntp/sntp-opts.c@1.59, 2007-02-16 06:42:31-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P7 + + sntp/sntp-opts.h@1.59, 2007-02-16 06:42:31-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P7 + + sntp/sntp-opts.texi@1.56, 2007-02-16 06:42:32-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P7 + + sntp/sntp.1@1.59, 2007-02-16 06:42:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P7 + + util/ntp-keygen-opts.c@1.59, 2007-02-16 06:42:33-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P7 + + util/ntp-keygen-opts.h@1.59, 2007-02-16 06:42:34-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P7 + + util/ntp-keygen-opts.texi@1.57, 2007-02-16 06:42:35-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P7 + + util/ntp-keygen.1@1.57, 2007-02-16 06:42:35-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P7 + +ChangeSet@1.1440.1.36, 2007-02-16 03:30:53-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 778] ntpd fails to lock with drift=+500 when started with drift=-500 + + ChangeLog@1.11, 2007-02-16 03:30:36-05:00, stenn@whimsy.udel.edu +2 -1 + [Bug 778] ntpd fails to lock with drift=+500 when started with drift=-500 + +ChangeSet@1.1440.1.35, 2007-02-16 03:24:28-05:00, stenn@whimsy.udel.edu +2 -0 + ntp_loopfilter.c: + Avoid setting the kernel freq if kernel mode is not disabled in the + config file and either the step threshold has been set to 0 or -x + has been given. (This is Harlan's interpretation of Dave's comment + #14 to bug 778: ) + refclock_irig.c: + Change the max PLL time constant to 10 (Dave Mills) + + ntpd/ntp_loopfilter.c@1.130, 2007-02-16 03:14:23-05:00, stenn@whimsy.udel.edu +5 -4 + Avoid setting the kernel freq if kernel mode is not disabled in the + config file and either the step threshold has been set to 0 or -x + has been given. (This is Harlan's interpretation of Dave's comment + #14 to bug 778: ) + + ntpd/refclock_irig.c@1.30, 2007-02-16 03:21:29-05:00, stenn@whimsy.udel.edu +1 -1 + Change the max PLL time constant to 10 (Dave Mills) + +ChangeSet@1.1440.1.34, 2007-02-05 08:45:44-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P6 + TAG: NTP_4_2_5P6 + + ntpd/ntpd-opts.c@1.59, 2007-02-05 08:45:22-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P6 + + ntpd/ntpd-opts.h@1.59, 2007-02-05 08:45:23-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P6 + + ntpd/ntpd-opts.texi@1.58, 2007-02-05 08:45:23-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P6 + + ntpd/ntpd.1@1.57, 2007-02-05 08:45:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P6 + + ntpd/ntpdsim-opts.c@1.59, 2007-02-05 08:45:25-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P6 + + ntpd/ntpdsim-opts.h@1.59, 2007-02-05 08:45:26-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P6 + + ntpd/ntpdsim-opts.texi@1.57, 2007-02-05 08:45:27-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P6 + + ntpd/ntpdsim.1@1.57, 2007-02-05 08:45:27-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P6 + + ntpdc/ntpdc-opts.c@1.59, 2007-02-05 08:45:28-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P6 + + ntpdc/ntpdc-opts.h@1.59, 2007-02-05 08:45:29-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P6 + + ntpdc/ntpdc-opts.texi@1.57, 2007-02-05 08:45:30-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P6 + + ntpdc/ntpdc.1@1.57, 2007-02-05 08:45:31-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P6 + + ntpq/ntpq-opts.c@1.61, 2007-02-05 08:45:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P6 + + ntpq/ntpq-opts.h@1.61, 2007-02-05 08:45:33-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P6 + + ntpq/ntpq-opts.texi@1.58, 2007-02-05 08:45:33-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P6 + + ntpq/ntpq.1@1.57, 2007-02-05 08:45:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P6 + + packageinfo.sh@1.9, 2007-02-05 08:45:34-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P6 + + sntp/sntp-opts.c@1.58, 2007-02-05 08:45:35-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P6 + + sntp/sntp-opts.h@1.58, 2007-02-05 08:45:35-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P6 + + sntp/sntp-opts.texi@1.55, 2007-02-05 08:45:36-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P6 + + sntp/sntp.1@1.58, 2007-02-05 08:45:37-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P6 + + util/ntp-keygen-opts.c@1.58, 2007-02-05 08:45:37-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P6 + + util/ntp-keygen-opts.h@1.58, 2007-02-05 08:45:38-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P6 + + util/ntp-keygen-opts.texi@1.56, 2007-02-05 08:45:39-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P6 + + util/ntp-keygen.1@1.56, 2007-02-05 08:45:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P6 + +ChangeSet@1.1436.1.27, 2007-02-05 06:47:44-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_4_RC3 + TAG: NTP_4_2_4_RC3 + + ntpd/ntpd-opts.c@1.50.1.3, 2007-02-05 06:47:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC3 + + ntpd/ntpd-opts.h@1.50.1.3, 2007-02-05 06:47:21-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4_RC3 + + ntpd/ntpd-opts.texi@1.49.1.3, 2007-02-05 06:47:22-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4_RC3 + + ntpd/ntpd.1@1.48.1.3, 2007-02-05 06:47:23-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC3 + + ntpd/ntpdsim-opts.c@1.50.1.3, 2007-02-05 06:47:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC3 + + ntpd/ntpdsim-opts.h@1.50.1.3, 2007-02-05 06:47:24-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4_RC3 + + ntpd/ntpdsim-opts.texi@1.48.1.3, 2007-02-05 06:47:25-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4_RC3 + + ntpd/ntpdsim.1@1.48.1.3, 2007-02-05 06:47:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC3 + + ntpdc/ntpdc-opts.c@1.50.1.3, 2007-02-05 06:47:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC3 + + ntpdc/ntpdc-opts.h@1.50.1.3, 2007-02-05 06:47:28-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4_RC3 + + ntpdc/ntpdc-opts.texi@1.48.1.3, 2007-02-05 06:47:28-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4_RC3 + + ntpdc/ntpdc.1@1.48.1.3, 2007-02-05 06:47:29-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC3 + + ntpq/ntpq-opts.c@1.52.1.3, 2007-02-05 06:47:30-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC3 + + ntpq/ntpq-opts.h@1.52.1.3, 2007-02-05 06:47:30-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4_RC3 + + ntpq/ntpq-opts.texi@1.49.1.3, 2007-02-05 06:47:31-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4_RC3 + + ntpq/ntpq.1@1.48.1.3, 2007-02-05 06:47:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC3 + + packageinfo.sh@1.65.4.1, 2007-02-05 06:47:33-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4_RC3 + + sntp/sntp-opts.c@1.49.1.3, 2007-02-05 06:47:33-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC3 + + sntp/sntp-opts.h@1.49.1.3, 2007-02-05 06:47:34-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4_RC3 + + sntp/sntp-opts.texi@1.46.1.3, 2007-02-05 06:47:35-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4_RC3 + + sntp/sntp.1@1.49.1.3, 2007-02-05 06:47:37-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC3 + + util/ntp-keygen-opts.c@1.49.1.3, 2007-02-05 06:47:38-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC3 + + util/ntp-keygen-opts.h@1.49.1.3, 2007-02-05 06:47:39-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4_RC3 + + util/ntp-keygen-opts.texi@1.47.1.3, 2007-02-05 06:47:39-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4_RC3 + + util/ntp-keygen.1@1.47.1.3, 2007-02-05 06:47:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC3 + +ChangeSet@1.1440.1.33, 2007-02-05 02:16:55-05:00, stenn@whimsy.udel.edu +8 -0 + More CHU, IRIG, WWV, and WWVB fixes from Dave Mills + + ChangeLog@1.10, 2007-02-05 02:16:13-05:00, stenn@whimsy.udel.edu +1 -1 + More CHU, IRIG, WWV, and WWVB fixes from Dave Mills + + html/drivers/driver36.html@1.31, 2007-02-05 02:16:15-05:00, stenn@whimsy.udel.edu +36 -30 + More CHU, IRIG, WWV, and WWVB fixes from Dave Mills + + html/drivers/driver6.html@1.23, 2007-02-05 02:16:13-05:00, stenn@whimsy.udel.edu +12 -24 + More CHU, IRIG, WWV, and WWVB fixes from Dave Mills + + html/drivers/driver7.html@1.25, 2007-02-05 02:16:14-05:00, stenn@whimsy.udel.edu +11 -29 + More CHU, IRIG, WWV, and WWVB fixes from Dave Mills + + ntpd/refclock_chu.c@1.44, 2007-02-05 02:07:38-05:00, stenn@whimsy.udel.edu +39 -31 + More CHU, IRIG, WWV, and WWVB fixes from Dave Mills + + ntpd/refclock_irig.c@1.29, 2007-02-05 02:07:39-05:00, stenn@whimsy.udel.edu +195 -128 + More CHU, IRIG, WWV, and WWVB fixes from Dave Mills + + ntpd/refclock_wwv.c@1.70, 2007-02-05 02:07:39-05:00, stenn@whimsy.udel.edu +50 -39 + More CHU, IRIG, WWV, and WWVB fixes from Dave Mills + + ntpd/refclock_wwvb.c@1.18, 2007-02-05 02:07:40-05:00, stenn@whimsy.udel.edu +0 -2 + More CHU, IRIG, WWV, and WWVB fixes from Dave Mills + +ChangeSet@1.1436.1.26, 2007-02-04 23:08:28-05:00, stenn@whimsy.udel.edu +1 -0 + Danny forgot to pull before editing - replace the change he undid. + + ntpq/ntpq-subs.c@1.25.2.2, 2007-02-04 23:08:17-05:00, stenn@whimsy.udel.edu +3 -2 + Danny forgot to pull before editing - replace the change he undid. + +ChangeSet@1.1436.1.25, 2007-02-04 22:53:32-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 586] Avoid lookups if AI_NUMERICHOST is set. + + ChangeLog@1.1.1.7, 2007-02-04 22:53:22-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 586] Avoid lookups if AI_NUMERICHOST is set. + +ChangeSet@1.1436.1.24, 2007-02-04 21:51:15-05:00, mayer@pogo.udel.edu +1 -0 + Bug #586 Don't do lookups if AI_NUMERICHOST is set + + libntp/ntp_rfc2553.c@1.36.1.1, 2007-02-04 21:51:01-05:00, mayer@pogo.udel.edu +6 -0 + Bug #586 Don't do lookups if AI_NUMERICHOST is set + +ChangeSet@1.1436.1.23, 2007-02-04 21:44:13-05:00, mayer@pogo.udel.edu +1 -0 + Bug #586 Check for <4 characters for the refid first + + ntpq/ntpq-subs.c@1.25.2.1, 2007-02-04 21:43:38-05:00, mayer@pogo.udel.edu +9 -10 + Bug #586 Check for <4 characters for the refid first + +ChangeSet@1.1436.1.22, 2007-02-04 17:56:17+00:00, kardel@pogo.udel.edu +1 -0 + ntpd.c: + comment clarification about capabilities used + + ntpd/ntpd.c@1.82.2.2, 2007-02-04 17:55:31+00:00, kardel@pogo.udel.edu +4 -7 + comment clarification about capabilities used + +ChangeSet@1.1436.2.1, 2007-02-04 17:47:20+00:00, kardel@pogo.udel.edu +1 -0 + ntpd.c: + Bug 765: + use Linux capability mechanism to allow dynamic interface tracking to continue in + unprivileged mode. + + ntpd/ntpd.c@1.82.2.1, 2007-02-04 17:45:55+00:00, kardel@pogo.udel.edu +11 -1 + Bug 765: + use Linux capability mechanism to allow dynamic interface tracking to continue in + unprivileged mode. - util/ntp-keygen-opts.h@1.57, 2007-04-14 07:53:38-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P1_RC1 +ChangeSet@1.1440.1.29, 2007-01-31 06:42:22-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P5 + TAG: NTP_4_2_5P5 - util/ntp-keygen-opts.texi@1.55, 2007-04-14 07:53:39-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + ntpd/ntpd-opts.c@1.57, 2007-01-31 06:42:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P5 - util/ntp-keygen.1@1.55, 2007-04-14 07:53:39-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + ntpd/ntpd-opts.h@1.57, 2007-01-31 06:42:02-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P5 -ChangeSet@1.1477, 2007-04-14 05:13:18-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpd-opts.texi@1.56, 2007-01-31 06:42:03-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P5 - ChangeLog@1.11, 2007-04-14 05:12:51-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpd.1@1.55, 2007-01-31 06:42:04-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P5 -ChangeSet@1.1476, 2007-04-14 04:47:21-04:00, stenn@whimsy.udel.edu +1 -0 - start an RC cycle + ntpd/ntpdsim-opts.c@1.57, 2007-01-31 06:42:04-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P5 - packageinfo.sh@1.75, 2007-04-14 04:47:01-04:00, stenn@whimsy.udel.edu +2 -2 - start an RC cycle + ntpd/ntpdsim-opts.h@1.57, 2007-01-31 06:42:05-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P5 -ChangeSet@1.1475, 2007-04-14 02:38:03-04:00, stenn@whimsy.udel.edu +32 -0 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpdsim-opts.texi@1.55, 2007-01-31 06:42:07-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P5 - clockstuff/Makefile.am@1.6, 2007-04-14 02:35:13-04:00, stenn@whimsy.udel.edu +1 -1 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpdsim.1@1.55, 2007-01-31 06:42:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P5 - clockstuff/clktest-opts.def@1.5, 2007-04-14 02:35:14-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 811] ntpd should not read a .ntprc file + ntpdc/ntpdc-opts.c@1.57, 2007-01-31 06:42:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P5 - include/copyright.def@1.4, 2007-04-14 02:35:14-04:00, stenn@whimsy.udel.edu +0 -7 - [Bug 811] ntpd should not read a .ntprc file + ntpdc/ntpdc-opts.h@1.57, 2007-01-31 06:42:09-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P5 - include/homerc.def@1.1, 2007-04-14 01:19:52-04:00, stenn@whimsy.udel.edu +9 -0 - BitKeeper file /deacon/backroom/ntp-stable/include/homerc.def + ntpdc/ntpdc-opts.texi@1.55, 2007-01-31 06:42:10-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P5 - include/homerc.def@1.0, 2007-04-14 01:19:52-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc.1@1.55, 2007-01-31 06:42:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P5 - ntpd/Makefile.am@1.53, 2007-04-14 02:35:14-04:00, stenn@whimsy.udel.edu +3 -3 - [Bug 811] ntpd should not read a .ntprc file + ntpq/ntpq-opts.c@1.59, 2007-01-31 06:42:11-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P5 - ntpd/ntpd-opts.c@1.57, 2007-04-14 02:36:43-04:00, stenn@whimsy.udel.edu +12 -54 - [Bug 811] ntpd should not read a .ntprc file + ntpq/ntpq-opts.h@1.59, 2007-01-31 06:42:12-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P5 - ntpd/ntpd-opts.h@1.57, 2007-04-14 02:36:44-04:00, stenn@whimsy.udel.edu +8 -22 - [Bug 811] ntpd should not read a .ntprc file + ntpq/ntpq-opts.texi@1.56, 2007-01-31 06:42:12-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P5 - ntpd/ntpd-opts.texi@1.56, 2007-04-14 02:36:44-04:00, stenn@whimsy.udel.edu +3 -3 - [Bug 811] ntpd should not read a .ntprc file + ntpq/ntpq.1@1.55, 2007-01-31 06:42:13-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P5 - ntpd/ntpd.1@1.55, 2007-04-14 02:36:45-04:00, stenn@whimsy.udel.edu +3 -19 - [Bug 811] ntpd should not read a .ntprc file + packageinfo.sh@1.8, 2007-01-31 06:42:14-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P5 - ntpd/ntpdsim-opts.c@1.57, 2007-04-14 02:36:46-04:00, stenn@whimsy.udel.edu +7 -6 - [Bug 811] ntpd should not read a .ntprc file + sntp/sntp-opts.c@1.56, 2007-01-31 06:42:15-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P5 - ntpd/ntpdsim-opts.def@1.6, 2007-04-14 02:35:15-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 811] ntpd should not read a .ntprc file + sntp/sntp-opts.h@1.56, 2007-01-31 06:42:15-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P5 - ntpd/ntpdsim-opts.h@1.57, 2007-04-14 02:36:46-04:00, stenn@whimsy.udel.edu +6 -12 - [Bug 811] ntpd should not read a .ntprc file + sntp/sntp-opts.texi@1.53, 2007-01-31 06:42:16-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P5 - ntpd/ntpdsim-opts.texi@1.55, 2007-04-14 02:36:47-04:00, stenn@whimsy.udel.edu +1 -1 - [Bug 811] ntpd should not read a .ntprc file + sntp/sntp.1@1.56, 2007-01-31 06:42:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P5 - ntpd/ntpdsim.1@1.55, 2007-04-14 02:36:48-04:00, stenn@whimsy.udel.edu +2 -2 - [Bug 811] ntpd should not read a .ntprc file + util/ntp-keygen-opts.c@1.56, 2007-01-31 06:42:17-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P5 - ntpdc/Makefile.am@1.34, 2007-04-14 02:35:15-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 811] ntpd should not read a .ntprc file + util/ntp-keygen-opts.h@1.56, 2007-01-31 06:42:18-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P5 - ntpdc/ntpdc-opts.c@1.57, 2007-04-14 02:36:48-04:00, stenn@whimsy.udel.edu +7 -6 - [Bug 811] ntpd should not read a .ntprc file + util/ntp-keygen-opts.texi@1.54, 2007-01-31 06:42:18-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P5 - ntpdc/ntpdc-opts.def@1.13, 2007-04-14 02:35:16-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 811] ntpd should not read a .ntprc file + util/ntp-keygen.1@1.54, 2007-01-31 06:42:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P5 - ntpdc/ntpdc-opts.h@1.57, 2007-04-14 02:36:49-04:00, stenn@whimsy.udel.edu +6 -12 - [Bug 811] ntpd should not read a .ntprc file +ChangeSet@1.1440.1.28, 2007-01-30 19:44:35-05:00, stenn@whimsy.udel.edu +1 -0 + re-indent/cleanup refclock_palisade.c - ntpdc/ntpdc-opts.texi@1.55, 2007-04-14 02:36:50-04:00, stenn@whimsy.udel.edu +3 -3 - [Bug 811] ntpd should not read a .ntprc file + ntpd/refclock_palisade.c@1.21, 2007-01-30 19:44:11-05:00, stenn@whimsy.udel.edu +347 -449 + re-indent refclock_palisade.c - ntpdc/ntpdc.1@1.55, 2007-04-14 02:36:51-04:00, stenn@whimsy.udel.edu +2 -2 - [Bug 811] ntpd should not read a .ntprc file +ChangeSet@1.1440.1.27, 2007-01-30 08:41:43-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P4 + TAG: NTP_4_2_5P4 - ntpq/Makefile.am@1.26, 2007-04-14 02:35:16-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpd-opts.c@1.56, 2007-01-30 08:41:20-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P4 - ntpq/ntpq-opts.c@1.59, 2007-04-14 02:36:52-04:00, stenn@whimsy.udel.edu +7 -6 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpd-opts.h@1.56, 2007-01-30 08:41:21-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P4 - ntpq/ntpq-opts.def@1.12, 2007-04-14 02:35:16-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpd-opts.texi@1.55, 2007-01-30 08:41:21-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P4 - ntpq/ntpq-opts.h@1.59, 2007-04-14 02:36:53-04:00, stenn@whimsy.udel.edu +6 -12 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpd.1@1.54, 2007-01-30 08:41:22-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P4 - ntpq/ntpq-opts.texi@1.56, 2007-04-14 02:36:53-04:00, stenn@whimsy.udel.edu +3 -3 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpdsim-opts.c@1.56, 2007-01-30 08:41:23-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P4 - ntpq/ntpq.1@1.55, 2007-04-14 02:36:54-04:00, stenn@whimsy.udel.edu +2 -2 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpdsim-opts.h@1.56, 2007-01-30 08:41:23-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P4 - util/Makefile.am@1.35, 2007-04-14 02:35:17-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpdsim-opts.texi@1.54, 2007-01-30 08:41:24-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P4 - util/ntp-keygen-opts.c@1.56, 2007-04-14 02:36:55-04:00, stenn@whimsy.udel.edu +7 -6 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpdsim.1@1.54, 2007-01-30 08:41:25-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P4 - util/ntp-keygen-opts.def@1.7, 2007-04-14 02:35:18-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 811] ntpd should not read a .ntprc file + ntpdc/ntpdc-opts.c@1.56, 2007-01-30 08:41:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P4 - util/ntp-keygen-opts.h@1.56, 2007-04-14 02:36:55-04:00, stenn@whimsy.udel.edu +6 -12 - [Bug 811] ntpd should not read a .ntprc file + ntpdc/ntpdc-opts.h@1.56, 2007-01-30 08:41:27-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P4 - util/ntp-keygen-opts.texi@1.54, 2007-04-14 02:36:56-04:00, stenn@whimsy.udel.edu +3 -3 - [Bug 811] ntpd should not read a .ntprc file + ntpdc/ntpdc-opts.texi@1.54, 2007-01-30 08:41:28-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P4 - util/ntp-keygen.1@1.54, 2007-04-14 02:36:57-04:00, stenn@whimsy.udel.edu +2 -2 - [Bug 811] ntpd should not read a .ntprc file + ntpdc/ntpdc.1@1.54, 2007-01-30 08:41:28-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P4 -ChangeSet@1.1474, 2007-04-14 01:11:33-04:00, stenn@whimsy.udel.edu +166 -0 - autogen/libopts upgrade + ntpq/ntpq-opts.c@1.58, 2007-01-30 08:41:29-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P4 - BitKeeper/deleted/.del-COPYING.lgpl@1.3, 2007-04-13 18:58:46-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/COPYING.lgpl + ntpq/ntpq-opts.h@1.58, 2007-01-30 08:41:30-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P4 - BitKeeper/deleted/.del-COPYING.lgpl~54a90ba0899593cb@1.2, 2007-04-13 19:05:57-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/COPYING.lgpl + ntpq/ntpq-opts.texi@1.55, 2007-01-30 08:41:30-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P4 - BitKeeper/deleted/.del-COPYING.mbsd@1.2, 2007-04-13 18:58:48-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/COPYING.mbsd + ntpq/ntpq.1@1.54, 2007-01-30 08:41:31-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P4 - BitKeeper/deleted/.del-COPYING.mbsd~9b1945bb2136c70b@1.2, 2007-04-13 19:05:59-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/COPYING.mbsd + packageinfo.sh@1.7, 2007-01-30 08:41:32-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P4 - BitKeeper/deleted/.del-MakeDefs.inc@1.2, 2007-04-13 18:58:49-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/MakeDefs.inc + sntp/sntp-opts.c@1.55, 2007-01-30 08:41:32-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P4 - BitKeeper/deleted/.del-MakeDefs.inc~2b8fdfc9df6d652d@1.2, 2007-04-13 19:06:00-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/MakeDefs.inc + sntp/sntp-opts.h@1.55, 2007-01-30 08:41:33-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P4 - BitKeeper/deleted/.del-Makefile.am@1.7, 2007-04-13 18:58:50-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/Makefile.am + sntp/sntp-opts.texi@1.52, 2007-01-30 08:41:33-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P4 - BitKeeper/deleted/.del-Makefile.am~fa9bd87b6045015c@1.5, 2007-04-13 19:06:01-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/Makefile.am + sntp/sntp.1@1.55, 2007-01-30 08:41:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P4 - BitKeeper/deleted/.del-README@1.2, 2007-04-13 18:58:51-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/README + util/ntp-keygen-opts.c@1.55, 2007-01-30 08:41:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P4 - BitKeeper/deleted/.del-README~1ae087758ee867d4@1.2, 2007-04-13 19:06:02-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/README + util/ntp-keygen-opts.h@1.55, 2007-01-30 08:41:35-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P4 - BitKeeper/deleted/.del-autoopts.c@1.11, 2007-04-13 18:58:52-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/autoopts.c + util/ntp-keygen-opts.texi@1.53, 2007-01-30 08:41:36-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P4 - BitKeeper/deleted/.del-autoopts.c~5b417341bc85d7a8@1.8, 2007-04-13 19:06:03-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/autoopts.c + util/ntp-keygen.1@1.53, 2007-01-30 08:41:38-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P4 - BitKeeper/deleted/.del-autoopts.h@1.10, 2007-04-13 18:58:53-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/autoopts.h +ChangeSet@1.1436.1.20, 2007-01-30 06:44:11-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_4_RC2 + TAG: NTP_4_2_4_RC2 - BitKeeper/deleted/.del-autoopts.h~8cdce21b181a1a01@1.8, 2007-04-13 19:06:05-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/autoopts.h + ntpd/ntpd-opts.c@1.50.1.2, 2007-01-30 06:43:46-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-boolean.c@1.9, 2007-04-13 18:58:54-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/boolean.c + ntpd/ntpd-opts.h@1.50.1.2, 2007-01-30 06:43:46-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-boolean.c~a5d10c8997e6a2e2@1.6, 2007-04-13 19:06:06-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/boolean.c + ntpd/ntpd-opts.texi@1.49.1.2, 2007-01-30 06:43:47-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-compat.h@1.13, 2007-04-13 19:04:47-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/compat.h + ntpd/ntpd.1@1.48.1.2, 2007-01-30 06:43:48-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-compat.h~9682d0ac273ae32@1.9, 2007-04-13 19:06:50-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/compat.h + ntpd/ntpdsim-opts.c@1.50.1.2, 2007-01-30 06:43:49-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-configfile.c@1.11, 2007-04-13 18:58:56-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/configfile.c + ntpd/ntpdsim-opts.h@1.50.1.2, 2007-01-30 06:43:50-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-configfile.c~8194f784686fa804@1.8, 2007-04-13 19:06:07-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/configfile.c + ntpd/ntpdsim-opts.texi@1.48.1.2, 2007-01-30 06:43:51-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-cook.c@1.10, 2007-04-13 18:58:57-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/cook.c + ntpd/ntpdsim.1@1.48.1.2, 2007-01-30 06:43:52-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-cook.c~e48d079a438432dc@1.7, 2007-04-13 19:06:08-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/cook.c + ntpdc/ntpdc-opts.c@1.50.1.2, 2007-01-30 06:43:52-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-enumeration.c@1.10, 2007-04-13 18:58:59-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/enumeration.c + ntpdc/ntpdc-opts.h@1.50.1.2, 2007-01-30 06:43:54-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-enumeration.c~5f4e6af2706370ae@1.7, 2007-04-13 19:06:10-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/enumeration.c + ntpdc/ntpdc-opts.texi@1.48.1.2, 2007-01-30 06:43:55-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-environment.c@1.9, 2007-04-13 18:59:00-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/environment.c + ntpdc/ntpdc.1@1.48.1.2, 2007-01-30 06:43:55-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-environment.c~2bae2966695067c2@1.6, 2007-04-13 19:06:11-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/environment.c + ntpq/ntpq-opts.c@1.52.1.2, 2007-01-30 06:43:56-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-genshell.c@1.10, 2007-04-13 18:59:01-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/genshell.c + ntpq/ntpq-opts.h@1.52.1.2, 2007-01-30 06:43:57-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-genshell.c~1fd152b2b52bdab@1.7, 2007-04-13 19:06:12-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/genshell.c + ntpq/ntpq-opts.texi@1.49.1.2, 2007-01-30 06:43:57-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-genshell.h@1.10, 2007-04-13 18:59:02-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/genshell.h + ntpq/ntpq.1@1.48.1.2, 2007-01-30 06:43:58-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-genshell.h~375f0fa5b925f454@1.7, 2007-04-13 19:06:14-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/genshell.h + packageinfo.sh@1.65.3.1, 2007-01-30 06:43:59-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-libopts.c@1.4, 2007-04-13 18:59:04-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/libopts.c + sntp/sntp-opts.c@1.49.1.2, 2007-01-30 06:43:59-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-libopts.c~58b8fbed850e6d5e@1.4, 2007-04-13 19:06:15-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/libopts.c + sntp/sntp-opts.h@1.49.1.2, 2007-01-30 06:44:00-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-libopts.m4@1.15, 2007-04-13 19:04:54-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/m4/libopts.m4 + sntp/sntp-opts.texi@1.46.1.2, 2007-01-30 06:44:01-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-libopts.m4~9e0f33f57d3a0a9@1.12, 2007-04-13 19:06:56-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/m4/libopts.m4 + sntp/sntp.1@1.49.1.2, 2007-01-30 06:44:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-liboptschk.m4@1.4, 2007-04-13 19:04:55-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/m4/liboptschk.m4 + util/ntp-keygen-opts.c@1.49.1.2, 2007-01-30 06:44:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-liboptschk.m4~bbeebebe76865058@1.4, 2007-04-13 19:06:58-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/m4/liboptschk.m4 + util/ntp-keygen-opts.h@1.49.1.2, 2007-01-30 06:44:03-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-libtool.m4@1.2, 2007-04-13 19:04:57-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/m4/libtool.m4 + util/ntp-keygen-opts.texi@1.47.1.2, 2007-01-30 06:44:04-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-libtool.m4~db8acbd0fb34597f@1.2, 2007-04-13 19:07:00-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/m4/libtool.m4 + util/ntp-keygen.1@1.47.1.2, 2007-01-30 06:44:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-load.c@1.11, 2007-04-13 18:59:05-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/load.c +ChangeSet@1.1440.1.26, 2007-01-30 01:09:52-05:00, stenn@whimsy.udel.edu +1 -0 + Lose K&R prototype macro - BitKeeper/deleted/.del-load.c~59960aa12bb95bf7@1.8, 2007-04-13 19:06:16-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/load.c + libntp/ntp_rfc2553.c@1.37, 2007-01-30 01:09:41-05:00, stenn@whimsy.udel.edu +2 -2 + Lose K&R prototype macro - BitKeeper/deleted/.del-makeshell.c@1.12, 2007-04-13 18:59:06-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/makeshell.c +ChangeSet@1.1436.1.19, 2007-01-29 21:20:08-05:00, stenn@whimsy.udel.edu +2 -0 + [Bug 770] Fix numeric parameters to ntp-keygen (Alain Guibert). - BitKeeper/deleted/.del-makeshell.c~4fcd12fc31c0a4a4@1.9, 2007-04-13 19:06:18-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/makeshell.c + ChangeLog@1.1.1.6, 2007-01-29 21:19:52-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 770] Fix numeric parameters to ntp-keygen (Alain Guibert). - BitKeeper/deleted/.del-nested.c@1.10, 2007-04-13 18:59:07-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/nested.c + util/ntp-keygen.c@1.37.1.1, 2007-01-29 21:19:53-05:00, stenn@whimsy.udel.edu +3 -3 + [Bug 770] Fix numeric parameters to ntp-keygen (Alain Guibert). - BitKeeper/deleted/.del-nested.c~85346d5d12098689@1.7, 2007-04-13 19:06:19-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/nested.c +ChangeSet@1.1436.1.18, 2007-01-29 17:43:41-05:00, stenn@whimsy.udel.edu +1 -0 + More ChangeLog -> CommitLog fixes - BitKeeper/deleted/.del-numeric.c@1.10, 2007-04-13 18:59:08-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/numeric.c + scripts/genCommitLog@1.4, 2007-01-29 17:42:48-05:00, stenn@whimsy.udel.edu +2 -2 + More ChangeLog -> CommitLog fixes - BitKeeper/deleted/.del-numeric.c~cdb7deb5cf6f27c2@1.7, 2007-04-13 19:06:21-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/numeric.c +ChangeSet@1.1436.1.17, 2007-01-29 16:52:38-05:00, stenn@whimsy.udel.edu +3 -0 + More ChangeLog -> CommitLog fixes - BitKeeper/deleted/.del-options.h@1.11, 2007-04-13 19:04:44-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/autoopts/options.h + Makefile.am@1.70.1.2, 2007-01-29 16:52:06-05:00, stenn@whimsy.udel.edu +5 -5 + More ChangeLog -> CommitLog fixes - BitKeeper/deleted/.del-options.h~6eb465cb95a56bee@1.8, 2007-04-13 19:06:45-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/autoopts/options.h + scripts/Makefile.am@1.15, 2007-01-29 16:52:07-05:00, stenn@whimsy.udel.edu +1 -1 + More ChangeLog -> CommitLog fixes - BitKeeper/deleted/.del-pathfind.c@1.10, 2007-04-13 19:04:49-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/pathfind.c + scripts/genCommitLog@1.3, 2007-01-29 16:09:19-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: scripts/genChangeLog -> scripts/genCommitLog - BitKeeper/deleted/.del-pathfind.c~a0863179d884d4a4@1.7, 2007-04-13 19:06:51-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/pathfind.c +ChangeSet@1.1436.1.16, 2007-01-28 23:24:05-05:00, stenn@whimsy.udel.edu +1 -0 + Entries for bugs 765 and 768 - BitKeeper/deleted/.del-pgusage.c@1.10, 2007-04-13 18:59:09-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/pgusage.c + ChangeLog@1.1.1.5, 2007-01-28 23:23:45-05:00, stenn@whimsy.udel.edu +2 -0 + Entries for bugs 765 and 768 - BitKeeper/deleted/.del-pgusage.c~d981c42eb301cfdd@1.6, 2007-04-13 19:06:22-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/pgusage.c +ChangeSet@1.1436.1.15, 2007-01-27 08:54:51+00:00, kardel@pogo.udel.edu +1 -0 + ntp_io.c: + fix misleading error message when calling io_setbclient() and + broadcast sockets are already open and not new sockets need to + be opened. + Bug 768: fix binding for broadcast client mode (Ulrich Weber) - BitKeeper/deleted/.del-proto.h@1.12, 2007-04-13 18:59:11-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/proto.h + ntpd/ntp_io.c@1.244.2.3, 2007-01-27 08:51:50+00:00, kardel@pogo.udel.edu +6 -3 + fix misleading error message when calling io_setbclient() and + broadcast sockets are already open and not new sockets need to + be opened. - BitKeeper/deleted/.del-proto.h~fa076f6dd9d0667e@1.9, 2007-04-13 19:06:23-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/proto.h + ntpd/ntp_io.c@1.244.2.2, 2007-01-27 08:24:25+00:00, kardel@pogo.udel.edu +2 -2 + Bug 768: fix binding for broadcast client mode (Ulrich Weber) - BitKeeper/deleted/.del-putshell.c@1.11, 2007-04-13 18:59:12-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/putshell.c +ChangeSet@1.1440.1.22, 2007-01-25 19:55:47-05:00, stenn@whimsy.udel.edu +4 -0 + CHU, IRIG, and WWV improvements from Dave Mills - BitKeeper/deleted/.del-putshell.c~24959f5e1ba688e6@1.8, 2007-04-13 19:06:24-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/putshell.c + libntp/audio.c@1.26, 2007-01-25 19:19:16-05:00, stenn@whimsy.udel.edu +6 -3 + CHU, IRIG, and WWV improvements from Dave Mills - BitKeeper/deleted/.del-restore.c@1.10, 2007-04-13 18:59:13-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/restore.c + ntpd/refclock_chu.c@1.43, 2007-01-25 19:19:16-05:00, stenn@whimsy.udel.edu +25 -22 + CHU, IRIG, and WWV improvements from Dave Mills - BitKeeper/deleted/.del-restore.c~eada4acbf21cd8bf@1.6, 2007-04-13 19:06:26-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/restore.c + ntpd/refclock_irig.c@1.28, 2007-01-25 19:19:17-05:00, stenn@whimsy.udel.edu +113 -117 + CHU, IRIG, and WWV improvements from Dave Mills - BitKeeper/deleted/.del-save.c@1.11, 2007-04-13 18:59:15-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/save.c + ntpd/refclock_wwv.c@1.69, 2007-01-25 19:19:18-05:00, stenn@whimsy.udel.edu +26 -28 + CHU, IRIG, and WWV improvements from Dave Mills - BitKeeper/deleted/.del-save.c~a29f5bd429a568bb@1.8, 2007-04-13 19:06:27-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/save.c +ChangeSet@1.1440.1.21, 2007-01-25 18:30:28-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P3 + TAG: NTP_4_2_5P3 - BitKeeper/deleted/.del-snprintf.c@1.5, 2007-04-13 19:04:50-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/snprintf.c + ntpd/ntpd-opts.c@1.55, 2007-01-25 18:28:57-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-snprintf.c~66578c716014cd3d@1.4, 2007-04-13 19:06:52-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/snprintf.c + ntpd/ntpd-opts.h@1.55, 2007-01-25 18:29:00-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P3 - BitKeeper/deleted/.del-sort.c@1.9, 2007-04-13 18:59:16-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/sort.c + ntpd/ntpd-opts.texi@1.54, 2007-01-25 18:29:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-sort.c~bec5a7fb6a01a5dc@1.5, 2007-04-13 19:06:28-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/sort.c + ntpd/ntpd.1@1.53, 2007-01-25 18:29:04-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-stack.c@1.11, 2007-04-13 18:59:17-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/stack.c + ntpd/ntpdsim-opts.c@1.55, 2007-01-25 18:29:08-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-stack.c~e817b57b18b315c1@1.8, 2007-04-13 19:06:29-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/stack.c + ntpd/ntpdsim-opts.h@1.55, 2007-01-25 18:29:12-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P3 - BitKeeper/deleted/.del-strchr.c@1.4, 2007-04-13 19:04:51-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/strchr.c + ntpd/ntpdsim-opts.texi@1.53, 2007-01-25 18:29:16-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P3 - BitKeeper/deleted/.del-strchr.c~80e88afbe7e2209a@1.4, 2007-04-13 19:06:53-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/strchr.c + ntpd/ntpdsim.1@1.53, 2007-01-25 18:29:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-strdup.c@1.4, 2007-04-13 19:04:52-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/strdup.c + ntpdc/ntpdc-opts.c@1.55, 2007-01-25 18:29:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-strdup.c~1f262be5e55c3c4a@1.3, 2007-04-13 19:06:54-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/strdup.c + ntpdc/ntpdc-opts.h@1.55, 2007-01-25 18:29:24-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P3 - BitKeeper/deleted/.del-streqvcmp.c@1.10, 2007-04-13 18:59:19-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/streqvcmp.c + ntpdc/ntpdc-opts.texi@1.53, 2007-01-25 18:29:26-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-streqvcmp.c~66420c6082b06827@1.7, 2007-04-13 19:06:31-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/streqvcmp.c + ntpdc/ntpdc.1@1.53, 2007-01-25 18:29:28-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-text_mmap.c@1.9, 2007-04-13 18:59:20-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/text_mmap.c + ntpq/ntpq-opts.c@1.57, 2007-01-25 18:29:30-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-text_mmap.c~f1915a52b87816ba@1.6, 2007-04-13 19:06:32-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/text_mmap.c + ntpq/ntpq-opts.h@1.57, 2007-01-25 18:29:33-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P3 - BitKeeper/deleted/.del-tokenize.c@1.6, 2007-04-13 18:59:21-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/tokenize.c + ntpq/ntpq-opts.texi@1.54, 2007-01-25 18:29:35-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-tokenize.c~ae2f23dbb2bee589@1.5, 2007-04-13 19:06:33-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/tokenize.c + ntpq/ntpq.1@1.53, 2007-01-25 18:29:39-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-usage-txt.h@1.10, 2007-04-13 19:04:46-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/autoopts/usage-txt.h + packageinfo.sh@1.6, 2007-01-25 18:29:42-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P3 - BitKeeper/deleted/.del-usage-txt.h~6ce4dce87430d1b@1.7, 2007-04-13 19:06:47-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/autoopts/usage-txt.h + sntp/sntp-opts.c@1.54, 2007-01-25 18:29:44-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-usage.c@1.10, 2007-04-13 18:59:22-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/usage.c + sntp/sntp-opts.h@1.54, 2007-01-25 18:29:45-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P3 - BitKeeper/deleted/.del-usage.c~c868ef1e661a6eb1@1.8, 2007-04-13 19:06:34-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/usage.c + sntp/sntp-opts.texi@1.51, 2007-01-25 18:29:48-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P3 - BitKeeper/deleted/.del-version.c@1.10, 2007-04-13 18:59:24-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/version.c + sntp/sntp.1@1.54, 2007-01-25 18:29:49-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-version.c~a426e6b58b20d06@1.7, 2007-04-13 19:06:35-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/version.c + util/ntp-keygen-opts.c@1.54, 2007-01-25 18:29:53-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-windows-config.h@1.6, 2007-04-13 19:04:53-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/windows-config.h + util/ntp-keygen-opts.h@1.54, 2007-01-25 18:29:55-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P3 - BitKeeper/deleted/.del-windows-config.h~36f7ad2ccf764ad2@1.4, 2007-04-13 19:06:56-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/windows-config.h + util/ntp-keygen-opts.texi@1.52, 2007-01-25 18:29:58-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P3 - libopts/COPYING.lgpl@1.1, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +502 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/COPYING.lgpl + util/ntp-keygen.1@1.52, 2007-01-25 18:30:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P3 - libopts/COPYING.lgpl@1.0, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1440.1.20, 2007-01-23 06:44:39-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 592] Trimble Thunderbolt GPS support. - libopts/COPYING.mbsd@1.1, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +26 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/COPYING.mbsd + ChangeLog@1.6, 2007-01-23 06:44:29-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 592] Trimble Thunderbolt GPS support. - libopts/COPYING.mbsd@1.0, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1436.1.14, 2007-01-23 04:47:08-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_4_RC1 + TAG: NTP_4_2_4_RC1 - libopts/MakeDefs.inc@1.1, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +0 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/MakeDefs.inc + ntpd/ntpd-opts.c@1.50.1.1, 2007-01-23 04:46:47-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC1 - libopts/MakeDefs.inc@1.0, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.h@1.50.1.1, 2007-01-23 04:46:48-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4_RC1 - libopts/Makefile.am@1.1, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +24 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/Makefile.am + ntpd/ntpd-opts.texi@1.49.1.1, 2007-01-23 04:46:48-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC1 - libopts/Makefile.am@1.0, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd.1@1.48.1.1, 2007-01-23 04:46:49-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC1 - libopts/README@1.1, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +93 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/README + ntpd/ntpdsim-opts.c@1.50.1.1, 2007-01-23 04:46:50-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC1 - libopts/README@1.0, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim-opts.h@1.50.1.1, 2007-01-23 04:46:50-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4_RC1 - libopts/autoopts.c@1.1, 2007-04-13 19:10:06-04:00, stenn@whimsy.udel.edu +1101 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/autoopts.c + ntpd/ntpdsim-opts.texi@1.48.1.1, 2007-01-23 04:46:52-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4_RC1 - libopts/autoopts.c@1.0, 2007-04-13 19:10:06-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim.1@1.48.1.1, 2007-01-23 04:46:52-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC1 - libopts/autoopts.h@1.1, 2007-04-13 19:10:06-04:00, stenn@whimsy.udel.edu +377 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/autoopts.h + ntpdc/ntpdc-opts.c@1.50.1.1, 2007-01-23 04:46:53-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC1 - libopts/autoopts.h@1.0, 2007-04-13 19:10:06-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.h@1.50.1.1, 2007-01-23 04:46:54-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4_RC1 - libopts/autoopts/options.h@1.1, 2007-04-13 19:10:30-04:00, stenn@whimsy.udel.edu +964 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/autoopts/options.h + ntpdc/ntpdc-opts.texi@1.48.1.1, 2007-01-23 04:46:54-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC1 - libopts/autoopts/options.h@1.0, 2007-04-13 19:10:30-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc.1@1.48.1.1, 2007-01-23 04:46:55-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC1 - libopts/autoopts/usage-txt.h@1.1, 2007-04-13 19:10:31-04:00, stenn@whimsy.udel.edu +355 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/autoopts/usage-txt.h + ntpq/ntpq-opts.c@1.52.1.1, 2007-01-23 04:46:56-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC1 - libopts/autoopts/usage-txt.h@1.0, 2007-04-13 19:10:31-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.h@1.52.1.1, 2007-01-23 04:46:57-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4_RC1 - libopts/boolean.c@1.1, 2007-04-13 19:10:07-04:00, stenn@whimsy.udel.edu +106 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/boolean.c + ntpq/ntpq-opts.texi@1.49.1.1, 2007-01-23 04:46:57-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC1 - libopts/boolean.c@1.0, 2007-04-13 19:10:07-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq.1@1.48.1.1, 2007-01-23 04:46:58-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC1 - libopts/compat/compat.h@1.1, 2007-04-13 19:10:38-04:00, stenn@whimsy.udel.edu +314 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/compat.h + packageinfo.sh@1.65.2.1, 2007-01-23 04:46:59-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4_RC1 - libopts/compat/compat.h@1.0, 2007-04-13 19:10:38-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.c@1.49.1.1, 2007-01-23 04:47:00-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC1 - libopts/compat/pathfind.c@1.1, 2007-04-13 19:10:38-04:00, stenn@whimsy.udel.edu +339 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/pathfind.c + sntp/sntp-opts.h@1.49.1.1, 2007-01-23 04:47:00-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4_RC1 - libopts/compat/pathfind.c@1.0, 2007-04-13 19:10:38-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.texi@1.46.1.1, 2007-01-23 04:47:01-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_4_RC1 - libopts/compat/snprintf.c@1.1, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +60 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/snprintf.c + sntp/sntp.1@1.49.1.1, 2007-01-23 04:47:02-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC1 - libopts/compat/snprintf.c@1.0, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.c@1.49.1.1, 2007-01-23 04:47:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC1 - libopts/compat/strchr.c@1.1, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +60 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/strchr.c + util/ntp-keygen-opts.h@1.49.1.1, 2007-01-23 04:47:04-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_4_RC1 - libopts/compat/strchr.c@1.0, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.texi@1.47.1.1, 2007-01-23 04:47:04-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC1 - libopts/compat/strdup.c@1.1, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +19 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/strdup.c + util/ntp-keygen.1@1.47.1.1, 2007-01-23 04:47:05-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_4_RC1 - libopts/compat/strdup.c@1.0, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1440.1.18, 2007-01-22 01:53:23-05:00, fernandoph@pogo.udel.edu +1 -0 + thunderbolt.jpg: + BitKeeper file /pogo/users/fernandoph/ntp-dev-592/html/pic/thunderbolt.jpg - libopts/compat/windows-config.h@1.1, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +129 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/windows-config.h + html/pic/thunderbolt.jpg@1.1, 2007-01-22 01:52:42-05:00, fernandoph@pogo.udel.edu +862 -0 + BitKeeper file /pogo/users/fernandoph/ntp-dev-592/html/pic/thunderbolt.jpg - libopts/compat/windows-config.h@1.0, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +0 -0 + html/pic/thunderbolt.jpg@1.0, 2007-01-22 01:52:42-05:00, fernandoph@pogo.udel.edu +0 -0 - libopts/configfile.c@1.1, 2007-04-13 19:10:07-04:00, stenn@whimsy.udel.edu +1288 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/configfile.c +ChangeSet@1.1440.1.17, 2007-01-22 01:28:51-05:00, fernandoph@pogo.udel.edu +3 -0 + refclock_palisade.c, driver29.html, refclock_palisade.h: + [BUG 592] Added support for Thunderbolt Receiver (mode 2). - libopts/configfile.c@1.0, 2007-04-13 19:10:07-04:00, stenn@whimsy.udel.edu +0 -0 + html/drivers/driver29.html@1.15, 2007-01-22 01:05:54-05:00, fernandoph@pogo.udel.edu +319 -5 + [BUG 592] Added support for Thunderbolt Receiver (mode 2). - libopts/cook.c@1.1, 2007-04-13 19:10:08-04:00, stenn@whimsy.udel.edu +354 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/cook.c + ntpd/refclock_palisade.c@1.20, 2007-01-22 01:03:31-05:00, fernandoph@pogo.udel.edu +325 -9 + [BUG 592] Added support for Thunderbolt Receiver (mode 2). - libopts/cook.c@1.0, 2007-04-13 19:10:08-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/refclock_palisade.h@1.10, 2007-01-22 01:05:29-05:00, fernandoph@pogo.udel.edu +29 -0 + [BUG 592] Added support for Thunderbolt Receiver (mode 2). - libopts/enumeration.c@1.1, 2007-04-13 19:10:09-04:00, stenn@whimsy.udel.edu +498 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/enumeration.c +ChangeSet@1.1436.1.13, 2007-01-21 12:44:07-05:00, stenn@whimsy.udel.edu +1 -0 + Danny fixed bug 360 in 4.2.2 - libopts/enumeration.c@1.0, 2007-04-13 19:10:09-04:00, stenn@whimsy.udel.edu +0 -0 + ChangeLog@1.1.1.4, 2007-01-21 12:43:50-05:00, stenn@whimsy.udel.edu +1 -0 + Danny fixed bug 360 in 4.2.2 - libopts/environment.c@1.1, 2007-04-13 19:10:09-04:00, stenn@whimsy.udel.edu +260 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/environment.c +ChangeSet@1.1436.1.12, 2007-01-21 12:40:23-05:00, stenn@whimsy.udel.edu +1 -0 + Danny fixed bug 239 in 4.2.2 - libopts/environment.c@1.0, 2007-04-13 19:10:09-04:00, stenn@whimsy.udel.edu +0 -0 + ChangeLog@1.1.1.3, 2007-01-21 12:40:13-05:00, stenn@whimsy.udel.edu +2 -0 + Danny fixed bug 239 in 4.2.2 - libopts/genshell.c@1.1, 2007-04-13 19:10:10-04:00, stenn@whimsy.udel.edu +345 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/genshell.c +ChangeSet@1.1436.1.11, 2007-01-21 12:33:46-05:00, stenn@pogo.udel.edu +1 -0 + Added bug 760 description to the ChangeLog - libopts/genshell.c@1.0, 2007-04-13 19:10:10-04:00, stenn@whimsy.udel.edu +0 -0 + ChangeLog@1.1.1.2, 2007-01-21 12:33:38-05:00, stenn@pogo.udel.edu +1 -0 + Added bug 760 description to the ChangeLog - libopts/genshell.h@1.1, 2007-04-13 19:10:10-04:00, stenn@whimsy.udel.edu +149 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/genshell.h +ChangeSet@1.1436.1.10, 2007-01-21 12:28:04-05:00, stenn@pogo.udel.edu +1 -0 + Update the ChangeLog - libopts/genshell.h@1.0, 2007-04-13 19:10:10-04:00, stenn@whimsy.udel.edu +0 -0 + ChangeLog@1.1.1.1, 2007-01-21 12:27:59-05:00, stenn@pogo.udel.edu +3 -0 + Update the ChangeLog - libopts/libopts.c@1.1, 2007-04-13 19:10:10-04:00, stenn@whimsy.udel.edu +30 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/libopts.c +ChangeSet@1.1440.1.15, 2007-01-21 02:51:30-05:00, stenn@whimsy.udel.edu +6 -0 + CHU, IRIG, and WWV refclock improvements from Dave Mills. - libopts/libopts.c@1.0, 2007-04-13 19:10:10-04:00, stenn@whimsy.udel.edu +0 -0 + ChangeLog@1.4, 2007-01-21 02:50:47-05:00, stenn@whimsy.udel.edu +1 -0 + CHU, IRIG, and WWV refclock improvements from Dave Mills. - libopts/load.c@1.1, 2007-04-13 19:10:11-04:00, stenn@whimsy.udel.edu +563 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/load.c + html/drivers/driver36.html@1.30, 2007-01-21 02:50:50-05:00, stenn@whimsy.udel.edu +35 -46 + CHU, IRIG, and WWV refclock improvements from Dave Mills. - libopts/load.c@1.0, 2007-04-13 19:10:11-04:00, stenn@whimsy.udel.edu +0 -0 + html/drivers/driver6.html@1.22, 2007-01-21 02:50:48-05:00, stenn@whimsy.udel.edu +18 -18 + CHU, IRIG, and WWV refclock improvements from Dave Mills. - libopts/m4/libopts.m4@1.1, 2007-04-13 19:10:43-04:00, stenn@whimsy.udel.edu +489 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/m4/libopts.m4 + html/drivers/driver7.html@1.24, 2007-01-21 02:50:49-05:00, stenn@whimsy.udel.edu +78 -141 + CHU, IRIG, and WWV refclock improvements from Dave Mills. - libopts/m4/libopts.m4@1.0, 2007-04-13 19:10:43-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/refclock_chu.c@1.42, 2007-01-21 02:50:51-05:00, stenn@whimsy.udel.edu +168 -225 + CHU, IRIG, and WWV refclock improvements from Dave Mills. - libopts/m4/liboptschk.m4@1.1, 2007-04-13 19:10:43-04:00, stenn@whimsy.udel.edu +42 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/m4/liboptschk.m4 + ntpd/refclock_irig.c@1.27, 2007-01-21 02:50:52-05:00, stenn@whimsy.udel.edu +90 -146 + CHU, IRIG, and WWV refclock improvements from Dave Mills. - libopts/m4/liboptschk.m4@1.0, 2007-04-13 19:10:43-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1436.1.9, 2007-01-21 07:49:58+00:00, kardel@pogo.udel.edu +1 -0 + ntp_io.c: + pick the right type for the recv*() length argument (use GETSOCKNAME_SOCKLEN_TYPE config.h define) - libopts/makeshell.c@1.1, 2007-04-13 19:10:11-04:00, stenn@whimsy.udel.edu +1122 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/makeshell.c + ntpd/ntp_io.c@1.244.2.1, 2007-01-21 07:48:16+00:00, kardel@pogo.udel.edu +1 -1 + pick the right type for the recv*() length argument (use GETSOCKNAME_SOCKLEN_TYPE config.h define) - libopts/makeshell.c@1.0, 2007-04-13 19:10:11-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1436.1.8, 2007-01-20 14:38:38+00:00, kardel@pogo.udel.edu +1 -0 + confopt.html: + move description for "dynamic" keyword into the right section - libopts/nested.c@1.1, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +733 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/nested.c + html/confopt.html@1.35, 2007-01-20 14:37:48+00:00, kardel@pogo.udel.edu +4 -3 + move description for "dynamic" keyword into the right section - libopts/nested.c@1.0, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1440.1.14, 2007-01-16 03:45:54-05:00, stenn@pogo.udel.edu +1 -0 + AC_PROG_CC_C_O -> AM_PROG_CC_C_O for automake upgrade - libopts/numeric.c@1.1, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +93 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/numeric.c + configure.ac@1.404, 2007-01-16 03:45:45-05:00, stenn@pogo.udel.edu +1 -1 + AC_PROG_CC_C_O -> AM_PROG_CC_C_O for automake upgrade - libopts/numeric.c@1.0, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1447.1.1, 2007-01-16 02:20:41-05:00, skamboj@ferrari.local +3 -0 + ntp_control.c: + Added configure prototype + ntp_control.h: + Added opcode for configure. + rsa_md5.h: + Removed double bracket - libopts/pgusage.c@1.1, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +157 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/pgusage.c + include/ntp_control.h@1.30, 2007-01-16 02:19:57-05:00, skamboj@ferrari.local +1 -0 + Added opcode for configure. - libopts/pgusage.c@1.0, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +0 -0 + include/rsa_md5.h@1.5.1.1, 2007-01-16 02:19:57-05:00, skamboj@ferrari.local +3 -3 + Removed double bracket - libopts/proto.h@1.1, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +91 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/proto.h + ntpd/ntp_control.c@1.88.1.2, 2007-01-16 02:19:58-05:00, skamboj@ferrari.local +1 -0 + Added configure prototype - libopts/proto.h@1.0, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1442.1.1, 2007-01-16 00:27:25-05:00, skamboj@ferrari.local +10 -0 + This changeset should now contain the remainder of the changes needed to incorporate the change in the configuration and simulator code. - libopts/putshell.c@1.1, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +335 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/putshell.c + include/ntp_config.h@1.42, 2007-01-16 00:27:22-05:00, skamboj@ferrari.local +138 -164 + Updated ntp_config.c to use a phrase structure grammar - libopts/putshell.c@1.0, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +0 -0 + include/ntpsim.h@1.5.1.1, 2007-01-16 00:27:22-05:00, skamboj@ferrari.local +112 -61 + Replaced the simulator code to allow the use of multiple servers - libopts/restore.c@1.1, 2007-04-13 19:10:13-04:00, stenn@whimsy.udel.edu +250 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/restore.c + libntp/systime.c@1.39, 2007-01-16 00:27:22-05:00, skamboj@ferrari.local +3 -177 + Removed the code needed by the simulator and added it to ntpsim.c, where IMHO, it rightfully belonged. - libopts/restore.c@1.0, 2007-04-13 19:10:13-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/cmd_args.c@1.45.1.1, 2007-01-16 00:27:22-05:00, skamboj@ferrari.local +5 -28 + Removed command line arguments from the simulator code - libopts/save.c@1.1, 2007-04-13 19:10:14-04:00, stenn@whimsy.udel.edu +512 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/save.c + ntpd/ntp_config.c@1.142.1.1, 2007-01-16 00:27:23-05:00, skamboj@ferrari.local +1821 -1835 + Updated ntp_config.c to use a phrase structure grammar - libopts/save.c@1.0, 2007-04-13 19:10:14-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntp_control.c@1.87.1.1, 2007-01-16 00:27:23-05:00, skamboj@ferrari.local +54 -0 + Added a configure option to allow remote configuration of NTP through the use of ntpq - libopts/sort.c@1.1, 2007-04-13 19:10:14-04:00, stenn@whimsy.udel.edu +359 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/sort.c + ntpd/ntp_io.c@1.244.1.1, 2007-01-16 00:27:23-05:00, skamboj@ferrari.local +1 -1 + Changed the line of code that sent a packet to the simulator. - libopts/sort.c@1.0, 2007-04-13 19:10:14-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpsim.c@1.13.1.1, 2007-01-16 00:27:24-05:00, skamboj@ferrari.local +573 -322 + Replaced the simulator code to allow the use of multiple servers - libopts/stack.c@1.1, 2007-04-13 19:10:15-04:00, stenn@whimsy.udel.edu +269 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/stack.c + ntpq/ntpq-subs.c@1.25.1.1, 2007-01-16 00:27:24-05:00, skamboj@ferrari.local +90 -0 + Added a configure option to allow remote configuration of NTP through the use of ntpq - libopts/stack.c@1.0, 2007-04-13 19:10:15-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq.c@1.65.1.1, 2007-01-16 00:27:24-05:00, skamboj@ferrari.local +20 -3 + Modified tokenize to allow the use of a quoted string. Needed by the new configure command. - libopts/streqvcmp.c@1.1, 2007-04-13 19:10:15-04:00, stenn@whimsy.udel.edu +289 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/streqvcmp.c +ChangeSet@1.1436.1.7, 2007-01-14 08:46:00+00:00, kardel@pogo.udel.edu +1 -0 + parse.h: + Bug 753: make union timestamp anonymous (Philip Prindeville) + now there are OSes that claim that name in netinet/ip.h... - libopts/streqvcmp.c@1.0, 2007-04-13 19:10:15-04:00, stenn@whimsy.udel.edu +0 -0 + include/parse.h@1.7.1.1, 2007-01-14 08:41:52+00:00, kardel@pogo.udel.edu +8 -4 + Bug 753: make union timestamp anonymous (Philip Prindeville) + now there are OSes that claim that name in netinet/ip.h... - libopts/text_mmap.c@1.1, 2007-04-13 19:10:16-04:00, stenn@whimsy.udel.edu +363 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/text_mmap.c +ChangeSet@1.1436.1.6, 2007-01-13 11:36:29+00:00, kardel@pogo.udel.edu +1 -0 + ntp_intres.c: + support dynamic keyword - libopts/text_mmap.c@1.0, 2007-04-13 19:10:16-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntp_intres.c@1.48.1.1, 2007-01-13 11:35:58+00:00, kardel@pogo.udel.edu +3 -1 + support dynamic keyword - libopts/tokenize.c@1.1, 2007-04-13 19:10:17-04:00, stenn@whimsy.udel.edu +321 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/tokenize.c +ChangeSet@1.1440.1.13, 2007-01-08 06:01:47-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P2 + TAG: NTP_4_2_5P2 - libopts/tokenize.c@1.0, 2007-04-13 19:10:17-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.c@1.53, 2007-01-08 06:01:24-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P2 - libopts/usage.c@1.1, 2007-04-13 19:10:17-04:00, stenn@whimsy.udel.edu +731 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/usage.c + ntpd/ntpd-opts.h@1.53, 2007-01-08 06:01:25-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P2 - libopts/usage.c@1.0, 2007-04-13 19:10:17-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.texi@1.52, 2007-01-08 06:01:25-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P2 - libopts/version.c@1.1, 2007-04-13 19:10:18-04:00, stenn@whimsy.udel.edu +176 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/version.c + ntpd/ntpd.1@1.51, 2007-01-08 06:01:27-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P2 - libopts/version.c@1.0, 2007-04-13 19:10:18-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim-opts.c@1.53, 2007-01-08 06:01:28-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P2 - sntp/libopts/COPYING.lgpl@1.1, 2007-04-13 19:09:02-04:00, stenn@whimsy.udel.edu +502 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/COPYING.lgpl + ntpd/ntpdsim-opts.h@1.53, 2007-01-08 06:01:29-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P2 - sntp/libopts/COPYING.lgpl@1.0, 2007-04-13 19:09:02-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim-opts.texi@1.51, 2007-01-08 06:01:30-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P2 - sntp/libopts/COPYING.mbsd@1.1, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +26 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/COPYING.mbsd + ntpd/ntpdsim.1@1.51, 2007-01-08 06:01:30-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P2 - sntp/libopts/COPYING.mbsd@1.0, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.c@1.53, 2007-01-08 06:01:31-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P2 - sntp/libopts/MakeDefs.inc@1.1, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +0 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/MakeDefs.inc + ntpdc/ntpdc-opts.h@1.53, 2007-01-08 06:01:32-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P2 - sntp/libopts/MakeDefs.inc@1.0, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.texi@1.51, 2007-01-08 06:01:32-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P2 - sntp/libopts/Makefile.am@1.1, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +24 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/Makefile.am + ntpdc/ntpdc.1@1.51, 2007-01-08 06:01:33-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P2 - sntp/libopts/Makefile.am@1.0, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.c@1.55, 2007-01-08 06:01:34-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P2 - sntp/libopts/README@1.1, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +93 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/README + ntpq/ntpq-opts.h@1.55, 2007-01-08 06:01:35-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P2 - sntp/libopts/README@1.0, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.texi@1.52, 2007-01-08 06:01:35-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P2 - sntp/libopts/autoopts.c@1.1, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +1101 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/autoopts.c + ntpq/ntpq.1@1.51, 2007-01-08 06:01:36-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P2 - sntp/libopts/autoopts.c@1.0, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +0 -0 + packageinfo.sh@1.5, 2007-01-08 06:01:37-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P2 - sntp/libopts/autoopts.h@1.1, 2007-04-13 19:08:51-04:00, stenn@whimsy.udel.edu +377 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/autoopts.h + sntp/sntp-opts.c@1.52, 2007-01-08 06:01:37-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P2 - sntp/libopts/autoopts.h@1.0, 2007-04-13 19:08:51-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.h@1.52, 2007-01-08 06:01:38-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P2 - sntp/libopts/autoopts/options.h@1.1, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +964 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/autoopts/options.h + sntp/sntp-opts.texi@1.49, 2007-01-08 06:01:39-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P2 - sntp/libopts/autoopts/options.h@1.0, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp.1@1.52, 2007-01-08 06:01:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P2 - sntp/libopts/autoopts/usage-txt.h@1.1, 2007-04-13 19:08:49-04:00, stenn@whimsy.udel.edu +355 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/autoopts/usage-txt.h + util/ntp-keygen-opts.c@1.52, 2007-01-08 06:01:40-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P2 - sntp/libopts/autoopts/usage-txt.h@1.0, 2007-04-13 19:08:49-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.h@1.52, 2007-01-08 06:01:41-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P2 - sntp/libopts/boolean.c@1.1, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +106 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/boolean.c + util/ntp-keygen-opts.texi@1.50, 2007-01-08 06:01:42-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P2 - sntp/libopts/boolean.c@1.0, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen.1@1.50, 2007-01-08 06:01:44-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P2 - sntp/libopts/compat/compat.h@1.1, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +314 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/compat.h +ChangeSet@1.1436.1.5, 2007-01-06 18:24:18-05:00, stenn@whimsy.udel.edu +1 -0 + Updated copyright year - sntp/libopts/compat/compat.h@1.0, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +0 -0 + html/copyright.html@1.36, 2007-01-06 18:23:45-05:00, stenn@whimsy.udel.edu +2 -2 + Updated copyright year - sntp/libopts/compat/pathfind.c@1.1, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +339 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/pathfind.c +ChangeSet@1.1440.1.11, 2007-01-06 16:09:45-05:00, stenn@whimsy.udel.edu +8 -0 + Documentation updates - sntp/libopts/compat/pathfind.c@1.0, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +0 -0 + html/audio.html@1.18, 2007-01-06 16:09:24-05:00, stenn@whimsy.udel.edu +32 -24 + Documentation updates - sntp/libopts/compat/snprintf.c@1.1, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +60 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/snprintf.c + html/drivers/driver36.html@1.29, 2007-01-06 16:09:25-05:00, stenn@whimsy.udel.edu +20 -14 + Documentation updates - sntp/libopts/compat/snprintf.c@1.0, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +0 -0 + html/drivers/driver6.html@1.21, 2007-01-06 16:09:26-05:00, stenn@whimsy.udel.edu +6 -9 + Documentation updates - sntp/libopts/compat/strchr.c@1.1, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +60 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/strchr.c + html/drivers/driver7.html@1.23, 2007-01-06 16:09:27-05:00, stenn@whimsy.udel.edu +19 -31 + Documentation updates - sntp/libopts/compat/strchr.c@1.0, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +0 -0 + html/pic/description.jpg@1.1, 2007-01-06 16:08:34-05:00, stenn@whimsy.udel.edu +761 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/description.jpg - sntp/libopts/compat/strdup.c@1.1, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +19 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/strdup.c + html/pic/description.jpg@1.0, 2007-01-06 16:08:34-05:00, stenn@whimsy.udel.edu +0 -0 - sntp/libopts/compat/strdup.c@1.0, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +0 -0 + html/pic/freq1211.gif@1.1, 2007-01-06 16:08:34-05:00, stenn@whimsy.udel.edu +255 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/freq1211.gif - sntp/libopts/compat/windows-config.h@1.1, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +129 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/windows-config.h + html/pic/freq1211.gif@1.0, 2007-01-06 16:08:34-05:00, stenn@whimsy.udel.edu +0 -0 - sntp/libopts/compat/windows-config.h@1.0, 2007-04-13 19:08:47-04:00, stenn@whimsy.udel.edu +0 -0 + html/pic/offset1211.gif@1.1, 2007-01-06 16:08:35-05:00, stenn@whimsy.udel.edu +568 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/offset1211.gif - sntp/libopts/configfile.c@1.1, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +1288 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/configfile.c + html/pic/offset1211.gif@1.0, 2007-01-06 16:08:35-05:00, stenn@whimsy.udel.edu +0 -0 - sntp/libopts/configfile.c@1.0, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +0 -0 + html/pic/pzf509.jpg@1.1, 2007-01-06 16:08:36-05:00, stenn@whimsy.udel.edu +291 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/pzf509.jpg - sntp/libopts/cook.c@1.1, 2007-04-13 19:08:53-04:00, stenn@whimsy.udel.edu +354 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/cook.c + html/pic/pzf509.jpg@1.0, 2007-01-06 16:08:36-05:00, stenn@whimsy.udel.edu +0 -0 - sntp/libopts/cook.c@1.0, 2007-04-13 19:08:53-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1440.1.10, 2007-01-06 05:35:24-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P1 + TAG: NTP_4_2_5P1 - sntp/libopts/enumeration.c@1.1, 2007-04-13 19:08:53-04:00, stenn@whimsy.udel.edu +498 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/enumeration.c + ntpd/ntpd-opts.c@1.52, 2007-01-06 05:35:04-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P1 - sntp/libopts/enumeration.c@1.0, 2007-04-13 19:08:53-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.h@1.52, 2007-01-06 05:35:05-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P1 - sntp/libopts/environment.c@1.1, 2007-04-13 19:08:54-04:00, stenn@whimsy.udel.edu +260 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/environment.c + ntpd/ntpd-opts.texi@1.51, 2007-01-06 05:35:05-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P1 - sntp/libopts/environment.c@1.0, 2007-04-13 19:08:54-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd.1@1.50, 2007-01-06 05:35:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P1 - sntp/libopts/genshell.c@1.1, 2007-04-13 19:08:55-04:00, stenn@whimsy.udel.edu +345 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/genshell.c + ntpd/ntpdsim-opts.c@1.52, 2007-01-06 05:35:07-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P1 - sntp/libopts/genshell.c@1.0, 2007-04-13 19:08:55-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim-opts.h@1.52, 2007-01-06 05:35:08-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P1 - sntp/libopts/genshell.h@1.1, 2007-04-13 19:08:51-04:00, stenn@whimsy.udel.edu +149 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/genshell.h + ntpd/ntpdsim-opts.texi@1.50, 2007-01-06 05:35:09-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P1 - sntp/libopts/genshell.h@1.0, 2007-04-13 19:08:51-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim.1@1.50, 2007-01-06 05:35:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P1 - sntp/libopts/libopts.c@1.1, 2007-04-13 19:08:50-04:00, stenn@whimsy.udel.edu +30 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/libopts.c + ntpdc/ntpdc-opts.c@1.52, 2007-01-06 05:35:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P1 - sntp/libopts/libopts.c@1.0, 2007-04-13 19:08:50-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.h@1.52, 2007-01-06 05:35:10-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P1 - sntp/libopts/load.c@1.1, 2007-04-13 19:08:55-04:00, stenn@whimsy.udel.edu +563 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/load.c + ntpdc/ntpdc-opts.texi@1.50, 2007-01-06 05:35:11-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P1 - sntp/libopts/load.c@1.0, 2007-04-13 19:08:55-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc.1@1.50, 2007-01-06 05:35:12-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P1 - sntp/libopts/m4/libopts.m4@1.1, 2007-04-13 19:08:50-04:00, stenn@whimsy.udel.edu +489 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/m4/libopts.m4 + ntpq/ntpq-opts.c@1.54, 2007-01-06 05:35:12-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P1 - sntp/libopts/m4/libopts.m4@1.0, 2007-04-13 19:08:50-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.h@1.54, 2007-01-06 05:35:13-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P1 - sntp/libopts/m4/liboptschk.m4@1.1, 2007-04-13 19:08:50-04:00, stenn@whimsy.udel.edu +42 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/m4/liboptschk.m4 + ntpq/ntpq-opts.texi@1.51, 2007-01-06 05:35:14-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P1 - sntp/libopts/m4/liboptschk.m4@1.0, 2007-04-13 19:08:50-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq.1@1.50, 2007-01-06 05:35:15-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P1 - sntp/libopts/makeshell.c@1.1, 2007-04-13 19:08:56-04:00, stenn@whimsy.udel.edu +1122 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/makeshell.c + packageinfo.sh@1.4, 2007-01-06 05:35:16-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P1 - sntp/libopts/makeshell.c@1.0, 2007-04-13 19:08:56-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.c@1.51, 2007-01-06 05:35:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P1 - sntp/libopts/nested.c@1.1, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +733 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/nested.c + sntp/sntp-opts.h@1.51, 2007-01-06 05:35:17-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P1 - sntp/libopts/nested.c@1.0, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.texi@1.48, 2007-01-06 05:35:18-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P1 - sntp/libopts/numeric.c@1.1, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +93 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/numeric.c + sntp/sntp.1@1.51, 2007-01-06 05:35:18-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P1 - sntp/libopts/numeric.c@1.0, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.c@1.51, 2007-01-06 05:35:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P1 - sntp/libopts/pgusage.c@1.1, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +157 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/pgusage.c + util/ntp-keygen-opts.h@1.51, 2007-01-06 05:35:20-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P1 - sntp/libopts/pgusage.c@1.0, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.texi@1.49, 2007-01-06 05:35:20-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P1 - sntp/libopts/proto.h@1.1, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +91 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/proto.h + util/ntp-keygen.1@1.49, 2007-01-06 05:35:21-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P1 - sntp/libopts/proto.h@1.0, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1440.1.9, 2007-01-06 04:40:47-05:00, stenn@whimsy.udel.edu +1 -0 + refclock_chu.c changes from Dave Mills - sntp/libopts/putshell.c@1.1, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +335 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/putshell.c + ntpd/refclock_chu.c@1.41, 2007-01-06 04:40:36-05:00, stenn@whimsy.udel.edu +224 -142 + refclock_chu.c changes from Dave Mills - sntp/libopts/putshell.c@1.0, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1440.1.8, 2007-01-06 04:05:36-05:00, stenn@whimsy.udel.edu +6 -0 + [Bug 757] Lose ULONG_CONST() - sntp/libopts/restore.c@1.1, 2007-04-13 19:08:58-04:00, stenn@whimsy.udel.edu +250 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/restore.c + BitKeeper/deleted/.del-hs_ulong_const.m4@1.3, 2007-01-06 04:02:09-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: m4/hs_ulong_const.m4 - sntp/libopts/restore.c@1.0, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +0 -0 + ChangeLog@1.3, 2007-01-06 04:04:27-05:00, stenn@whimsy.udel.edu +1 -0 + [Bug 757] Lose ULONG_CONST() - sntp/libopts/save.c@1.1, 2007-04-13 19:08:58-04:00, stenn@whimsy.udel.edu +512 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/save.c + configure.ac@1.403, 2007-01-06 04:03:34-05:00, stenn@whimsy.udel.edu +0 -2 + [Bug 757] Lose ULONG_CONST() - sntp/libopts/save.c@1.0, 2007-04-13 19:08:58-04:00, stenn@whimsy.udel.edu +0 -0 + libparse/gpstolfp.c@1.9, 2007-01-06 04:03:35-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 757] Lose ULONG_CONST() - sntp/libopts/sort.c@1.1, 2007-04-13 19:08:59-04:00, stenn@whimsy.udel.edu +359 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/sort.c + ntpd/ntp_control.c@1.89, 2007-01-06 04:03:36-05:00, stenn@whimsy.udel.edu +2 -2 + [Bug 757] Lose ULONG_CONST() - sntp/libopts/sort.c@1.0, 2007-04-13 19:08:59-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen.c@1.39, 2007-01-06 04:05:22-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 757] Lose ULONG_CONST() - sntp/libopts/stack.c@1.1, 2007-04-13 19:08:59-04:00, stenn@whimsy.udel.edu +269 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/stack.c +ChangeSet@1.1440.1.7, 2007-01-06 03:25:15-05:00, stenn@whimsy.udel.edu +17 -0 + [Bug 756] Require function prototypes - sntp/libopts/stack.c@1.0, 2007-04-13 19:08:59-04:00, stenn@whimsy.udel.edu +0 -0 + configure.ac@1.402, 2007-01-06 03:24:28-05:00, stenn@whimsy.udel.edu +2 -32 + [Bug 756] Require function prototypes - sntp/libopts/streqvcmp.c@1.1, 2007-04-13 19:09:00-04:00, stenn@whimsy.udel.edu +289 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/streqvcmp.c + include/ntp_rfc2553.h@1.29, 2007-01-06 00:45:15-05:00, stenn@whimsy.udel.edu +6 -6 + [Bug 756] Require function prototypes - sntp/libopts/streqvcmp.c@1.0, 2007-04-13 19:09:00-04:00, stenn@whimsy.udel.edu +0 -0 + include/ntp_select.h@1.3, 2007-01-06 00:45:16-05:00, stenn@whimsy.udel.edu +2 -2 + [Bug 756] Require function prototypes - sntp/libopts/text_mmap.c@1.1, 2007-04-13 19:09:01-04:00, stenn@whimsy.udel.edu +363 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/text_mmap.c + include/ntp_syscall.h@1.7, 2007-01-06 00:45:17-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 756] Require function prototypes - sntp/libopts/text_mmap.c@1.0, 2007-04-13 19:09:01-04:00, stenn@whimsy.udel.edu +0 -0 + include/rsa_md5.h@1.6, 2007-01-06 01:24:42-05:00, stenn@whimsy.udel.edu +3 -4 + [Bug 756] Require function prototypes - sntp/libopts/tokenize.c@1.1, 2007-04-13 19:09:01-04:00, stenn@whimsy.udel.edu +321 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/tokenize.c + libntp/audio.c@1.25, 2007-01-06 00:46:16-05:00, stenn@whimsy.udel.edu +2 -2 + [Bug 756] Require function prototypes - sntp/libopts/tokenize.c@1.0, 2007-04-13 19:09:01-04:00, stenn@whimsy.udel.edu +0 -0 + libntp/md5c.c@1.8, 2007-01-06 01:33:03-05:00, stenn@whimsy.udel.edu +5 -7 + [Bug 756] Require function prototypes - sntp/libopts/usage.c@1.1, 2007-04-13 19:09:02-04:00, stenn@whimsy.udel.edu +731 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/usage.c + libntp/syssignal.c@1.9, 2007-01-06 00:46:25-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 756] Require function prototypes - sntp/libopts/usage.c@1.0, 2007-04-13 19:09:02-04:00, stenn@whimsy.udel.edu +0 -0 + libparse/clk_wharton.c@1.7, 2007-01-06 00:59:05-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 756] Require function prototypes - sntp/libopts/version.c@1.1, 2007-04-13 19:09:02-04:00, stenn@whimsy.udel.edu +176 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/version.c + libparse/parsestreams.c@1.7, 2007-01-06 00:59:09-05:00, stenn@whimsy.udel.edu +23 -23 + [Bug 756] Require function prototypes - sntp/libopts/version.c@1.0, 2007-04-13 19:09:02-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/refclock_ripencc.c@1.7, 2007-01-06 00:53:57-05:00, stenn@whimsy.udel.edu +21 -21 + [Bug 756] Require function prototypes -ChangeSet@1.1473, 2007-04-12 06:32:19-04:00, stenn@whimsy.udel.edu +1 -0 - Added ntp2 mirror + ntpd/refclock_tpro.c@1.9, 2007-01-06 00:55:40-05:00, stenn@whimsy.udel.edu +3 -3 + [Bug 756] Require function prototypes - BitKeeper/triggers/2mirrors@1.4, 2007-04-12 06:30:59-04:00, stenn@whimsy.udel.edu +1 -0 - Added ntp2 mirror + ntpd/refclock_tt560.c@1.2, 2007-01-06 00:56:59-05:00, stenn@whimsy.udel.edu +3 -3 + [Bug 756] Require function prototypes -ChangeSet@1.1472, 2007-03-07 06:46:09-05:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P0 - TAG: NTP_4_2_4P0 + sntp/configure.ac@1.16, 2007-01-06 03:24:29-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 756] Require function prototypes - ntpd/ntpd-opts.c@1.56, 2007-03-07 06:45:46-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 + util/hist.c@1.7, 2007-01-06 01:05:47-05:00, stenn@whimsy.udel.edu +1 -1 + [Bug 756] Require function prototypes - ntpd/ntpd-opts.h@1.56, 2007-03-07 06:45:47-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0 + util/jitter.h@1.3, 2007-01-06 01:05:48-05:00, stenn@whimsy.udel.edu +16 -16 + [Bug 756] Require function prototypes - ntpd/ntpd-opts.texi@1.55, 2007-03-07 06:45:48-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0 + util/tickadj.c@1.7, 2007-01-06 01:05:51-05:00, stenn@whimsy.udel.edu +4 -4 + [Bug 756] Require function prototypes - ntpd/ntpd.1@1.54, 2007-03-07 06:45:48-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 +ChangeSet@1.1440.1.6, 2007-01-05 00:41:52-05:00, stenn@whimsy.udel.edu +1 -0 + Add in ntp-dev updates to the new ChangeLog - ntpd/ntpdsim-opts.c@1.56, 2007-03-07 06:45:49-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 + ChangeLog@1.2, 2007-01-05 00:41:42-05:00, stenn@whimsy.udel.edu +3 -0 + Add in ntp-dev updates to the new ChangeLog - ntpd/ntpdsim-opts.h@1.56, 2007-03-07 06:45:50-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0 +ChangeSet@1.1436.1.4, 2007-01-05 00:27:33-05:00, stenn@whimsy.udel.edu +4 -0 + ChangeLog->CommitLog, NEWS->ChangeLog, Release Info->NEWS - ntpd/ntpdsim-opts.texi@1.54, 2007-03-07 06:45:51-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0 + ChangeLog@1.1, 2007-01-05 00:06:33-05:00, stenn@whimsy.udel.edu +260 -0 + BitKeeper file /deacon/backroom/ntp-stable/ChangeLog - ntpd/ntpdsim.1@1.54, 2007-03-07 06:45:51-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 + ChangeLog@1.0, 2007-01-05 00:06:33-05:00, stenn@whimsy.udel.edu +0 -0 - ntpdc/ntpdc-opts.c@1.56, 2007-03-07 06:45:52-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 + CommitLog-4.1.0@1.592, 2007-01-05 00:05:52-05:00, stenn@whimsy.udel.edu +0 -0 + Rename: ChangeLog-4.1.0 -> CommitLog-4.1.0 - ntpdc/ntpdc-opts.h@1.56, 2007-03-07 06:45:53-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0 + Makefile.am@1.70.1.1, 2007-01-05 00:27:13-05:00, stenn@whimsy.udel.edu +2 -1 + ChangeLog->CommitLog, NEWS->ChangeLog, Release Info->NEWS - ntpdc/ntpdc-opts.texi@1.54, 2007-03-07 06:45:53-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0 + NEWS@1.86.1.1, 2007-01-05 00:27:14-05:00, stenn@whimsy.udel.edu +14 -256 + ChangeLog->CommitLog, NEWS->ChangeLog, Release Info->NEWS - ntpdc/ntpdc.1@1.54, 2007-03-07 06:45:54-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 +ChangeSet@1.1436.1.3, 2007-01-04 23:41:02-05:00, stenn@whimsy.udel.edu +1 -0 + ChangeLog->CommitLog in the ignore file + + BitKeeper/etc/ignore@1.59, 2007-01-04 23:40:52-05:00, stenn@whimsy.udel.edu +1 -2 + ChangeLog->CommitLog in the ignore file - ntpq/ntpq-opts.c@1.58, 2007-03-07 06:45:55-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 +ChangeSet@1.1436.1.2, 2007-01-04 19:31:07-05:00, stenn@whimsy.udel.edu +1 -0 + hostname updates for flock-build - ntpq/ntpq-opts.h@1.58, 2007-03-07 06:45:56-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0 + flock-build@1.39, 2007-01-04 19:30:49-05:00, stenn@whimsy.udel.edu +15 -19 + hostname updates for flock-build - ntpq/ntpq-opts.texi@1.55, 2007-03-07 06:45:57-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0 +ChangeSet@1.1445, 2007-01-04 01:22:19-05:00, stenn@pogo.udel.edu +1 -0 + What about ntpdsim.1? - ntpq/ntpq.1@1.54, 2007-03-07 06:45:58-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 + ntpd/Makefile.am@1.55, 2007-01-04 01:22:10-05:00, stenn@pogo.udel.edu +2 -0 + What about ntpdsim.1? - packageinfo.sh@1.74, 2007-03-07 06:45:58-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 +ChangeSet@1.1443, 2007-01-03 19:12:30-05:00, stenn@pogo.udel.edu +5 -0 + ntpdsim no longer needs special command-line options - sntp/sntp-opts.c@1.55, 2007-03-07 06:45:59-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 + NEWS@1.87.1.1, 2007-01-03 19:12:22-05:00, stenn@pogo.udel.edu +2 -0 + ntpdsim no longer needs special command-line options - sntp/sntp-opts.h@1.55, 2007-03-07 06:46:00-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0 + ntpd/Makefile.am@1.52.1.1, 2007-01-03 19:10:41-05:00, stenn@pogo.udel.edu +3 -19 + ntpdsim no longer needs special command-line options - sntp/sntp-opts.texi@1.52, 2007-03-07 06:46:01-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0 + ntpd/cmd_args.c@1.46, 2007-01-03 19:10:41-05:00, stenn@pogo.udel.edu +2 -9 + ntpdsim no longer needs special command-line options - sntp/sntp.1@1.55, 2007-03-07 06:46:01-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 + ntpd/ntpd.c@1.82.1.1, 2007-01-03 19:10:42-05:00, stenn@pogo.udel.edu +2 -7 + ntpdsim no longer needs special command-line options - util/ntp-keygen-opts.c@1.55, 2007-03-07 06:46:03-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 + ntpd/ntpsim.c@1.14, 2007-01-03 19:10:43-05:00, stenn@pogo.udel.edu +3 -3 + ntpdsim no longer needs special command-line options - util/ntp-keygen-opts.h@1.55, 2007-03-07 06:46:03-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0 +ChangeSet@1.1440.1.1, 2007-01-03 16:46:18-05:00, stenn@whimsy.udel.edu +2 -0 + CHU and IRIG changes from Dave Mills - util/ntp-keygen-opts.texi@1.53, 2007-03-07 06:46:04-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0 + ntpd/refclock_chu.c@1.38.1.1, 2007-01-03 16:46:03-05:00, stenn@whimsy.udel.edu +163 -230 + CHU and IRIG changes from Dave Mills - util/ntp-keygen.1@1.53, 2007-03-07 06:46:05-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 + ntpd/refclock_irig.c@1.24.1.1, 2007-01-03 16:46:04-05:00, stenn@whimsy.udel.edu +7 -6 + CHU and IRIG changes from Dave Mills -ChangeSet@1.1471, 2007-03-07 00:53:31-05:00, stenn@whimsy.udel.edu +1 -0 - time to release +ChangeSet@1.1439.1.1, 2007-01-03 16:41:43-05:00, stenn@pogo.udel.edu +123 -0 + [Bug 756] Require ANSI C (function prototypes) - packageinfo.sh@1.73, 2007-03-07 00:53:21-05:00, stenn@whimsy.udel.edu +3 -1 - time to release + Makefile.am@1.71, 2007-01-03 16:39:19-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1470, 2007-03-03 19:21:29-05:00, stenn@whimsy.udel.edu +2 -0 - [Bug 793] Update Hans Lambermont's email address in ntpsweep + NEWS@1.88, 2007-01-03 16:41:33-05:00, stenn@pogo.udel.edu +1 -0 + [Bug 756] Require ANSI C (function prototypes) - ChangeLog@1.10, 2007-03-03 19:21:16-05:00, stenn@whimsy.udel.edu +1 -0 - [Bug 793] Update Hans Lambermont's email address in ntpsweep + adjtimed/Makefile.am@1.4, 2007-01-03 16:39:39-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - scripts/ntpsweep.in@1.3, 2007-03-03 19:21:17-05:00, stenn@whimsy.udel.edu +1 -2 - [Bug 793] Update Hans Lambermont's email address in ntpsweep + arlib/Makefile.am@1.3, 2007-01-03 16:39:39-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1469, 2007-02-24 06:42:26-05:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P0_RC5 - TAG: NTP_4_2_4P0_RC5 + clockstuff/Makefile.am@1.6, 2007-01-03 16:39:39-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd-opts.c@1.55, 2007-02-24 06:42:04-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + configure.ac@1.401, 2007-01-03 16:35:19-05:00, stenn@pogo.udel.edu +4 -2 + [Bug 756] Require ANSI C. For Solaris, lose -D_XOPEN_SOURCE=500 as that conflicts with recent ANSI/POSIX stuff - ntpd/ntpd-opts.h@1.55, 2007-02-24 06:42:05-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC5 + include/Makefile.am@1.25, 2007-01-03 16:39:49-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd-opts.texi@1.54, 2007-02-24 06:42:06-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0_RC5 + include/audio.h@1.7, 2007-01-03 16:39:49-05:00, stenn@pogo.udel.edu +3 -3 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd.1@1.53, 2007-02-24 06:42:07-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + include/binio.h@1.5, 2007-01-03 16:39:49-05:00, stenn@pogo.udel.edu +8 -8 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.c@1.55, 2007-02-24 06:42:08-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + include/global.h@1.4, 2007-01-03 16:39:49-05:00, stenn@pogo.udel.edu +0 -19 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.h@1.55, 2007-02-24 06:42:08-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC5 + include/icom.h@1.5, 2007-01-03 16:39:49-05:00, stenn@pogo.udel.edu +2 -2 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.texi@1.53, 2007-02-24 06:42:09-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0_RC5 + include/ieee754io.h@1.5, 2007-01-03 16:39:49-05:00, stenn@pogo.udel.edu +2 -2 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim.1@1.53, 2007-02-24 06:42:10-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + include/iosignal.h@1.3, 2007-01-03 16:39:49-05:00, stenn@pogo.udel.edu +6 -6 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.c@1.55, 2007-02-24 06:42:11-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + include/isc/Makefile.am@1.5, 2007-01-03 16:39:52-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.h@1.55, 2007-02-24 06:42:11-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC5 + include/l_stdlib.h@1.16, 2007-01-03 16:39:49-05:00, stenn@pogo.udel.edu +67 -332 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.texi@1.53, 2007-02-24 06:42:12-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0_RC5 + include/mbg_gps166.h@1.9, 2007-01-03 16:39:50-05:00, stenn@pogo.udel.edu +24 -24 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc.1@1.53, 2007-02-24 06:42:13-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + include/ntp.h@1.130, 2007-01-03 16:39:50-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.c@1.57, 2007-02-24 06:42:13-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + include/ntp_calendar.h@1.3, 2007-01-03 16:39:50-05:00, stenn@pogo.udel.edu +3 -3 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.h@1.57, 2007-02-24 06:42:14-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC5 + include/ntp_cmdargs.h@1.5, 2007-01-03 16:39:50-05:00, stenn@pogo.udel.edu +2 -2 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.texi@1.54, 2007-02-24 06:42:15-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0_RC5 + include/ntp_filegen.h@1.4, 2007-01-03 16:39:50-05:00, stenn@pogo.udel.edu +4 -4 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq.1@1.53, 2007-02-24 06:42:16-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + include/ntp_fp.h@1.13, 2007-01-03 16:39:50-05:00, stenn@pogo.udel.edu +17 -17 + [Bug 756] Require ANSI C (function prototypes) - packageinfo.sh@1.72, 2007-02-24 06:42:17-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0_RC5 + include/ntp_machine.h@1.24, 2007-01-03 16:39:50-05:00, stenn@pogo.udel.edu +11 -23 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp-opts.c@1.54, 2007-02-24 06:42:17-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + include/ntp_random.h@1.2, 2007-01-03 16:39:51-05:00, stenn@pogo.udel.edu +6 -6 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp-opts.h@1.54, 2007-02-24 06:42:18-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC5 + include/ntp_refclock.h@1.21, 2007-01-03 16:39:51-05:00, stenn@pogo.udel.edu +28 -28 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp-opts.texi@1.51, 2007-02-24 06:42:18-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0_RC5 + include/ntp_stdlib.h@1.25, 2007-01-03 16:39:51-05:00, stenn@pogo.udel.edu +64 -70 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp.1@1.54, 2007-02-24 06:42:19-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + include/ntp_string.h@1.3, 2007-01-03 16:39:51-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - util/ntp-keygen-opts.c@1.54, 2007-02-24 06:42:20-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + include/ntp_types.h@1.9, 2007-01-03 16:39:51-05:00, stenn@pogo.udel.edu +0 -11 + [Bug 756] Require ANSI C (function prototypes) - util/ntp-keygen-opts.h@1.54, 2007-02-24 06:42:21-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC5 + include/ntp_unixtime.h@1.5, 2007-01-03 16:39:51-05:00, stenn@pogo.udel.edu +2 -2 + [Bug 756] Require ANSI C (function prototypes) - util/ntp-keygen-opts.texi@1.52, 2007-02-24 06:42:21-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0_RC5 + include/ntpd.h@1.99, 2007-01-03 16:39:51-05:00, stenn@pogo.udel.edu +120 -120 + [Bug 756] Require ANSI C (function prototypes) - util/ntp-keygen.1@1.52, 2007-02-24 06:42:22-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + include/ntpsim.h@1.6, 2007-01-03 16:39:52-05:00, stenn@pogo.udel.edu +16 -16 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1468, 2007-02-24 05:07:16-05:00, stenn@whimsy.udel.edu +1 -0 - [Bug 628] Fallback to ntp discipline not working for large offsets + include/parse.h@1.8, 2007-01-03 16:39:52-05:00, stenn@pogo.udel.edu +32 -32 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntp_loopfilter.c@1.128, 2007-02-24 05:07:04-05:00, stenn@whimsy.udel.edu +9 -24 - [Bug 628] Fallback to ntp discipline not working for large offsets + include/recvbuff.h@1.12, 2007-01-03 16:39:52-05:00, stenn@pogo.udel.edu +13 -13 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1467, 2007-02-21 15:16:15-05:00, stenn@whimsy.udel.edu +1 -0 - [Bug 776] Remove the obsolete r: from the getopt string in ntpdate + include/trimble.h@1.5, 2007-01-03 16:39:52-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpdate/ntpdate.c@1.61, 2007-02-21 15:16:00-05:00, stenn@whimsy.udel.edu +1 -1 - [Bug 776] Remove the obsolete r: from the getopt string in ntpdate + kernel/Makefile.am@1.3, 2007-01-03 16:39:53-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1466, 2007-02-19 06:46:30-05:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P0_RC4 - TAG: NTP_4_2_4P0_RC4 + kernel/sys/Makefile.am@1.4, 2007-01-03 16:39:54-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd-opts.c@1.54, 2007-02-19 06:46:11-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libntp/Makefile.am@1.38, 2007-01-03 16:39:55-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd-opts.h@1.54, 2007-02-19 06:46:11-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC4 + libntp/authreadkeys.c@1.7, 2007-01-03 16:39:55-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd-opts.texi@1.53, 2007-02-19 06:46:12-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libntp/icom.c@1.11, 2007-01-03 16:39:56-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd.1@1.52, 2007-02-19 06:46:13-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libntp/iosignal.c@1.14, 2007-01-03 16:39:56-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.c@1.54, 2007-02-19 06:46:13-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libntp/msyslog.c@1.20, 2007-01-03 16:39:57-05:00, stenn@pogo.udel.edu +2 -2 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.h@1.54, 2007-02-19 06:46:14-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC4 + libntp/ntp_random.c@1.6, 2007-01-03 16:39:57-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.texi@1.52, 2007-02-19 06:46:15-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0_RC4 + libntp/statestr.c@1.11, 2007-01-03 16:39:57-05:00, stenn@pogo.udel.edu +2 -2 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim.1@1.52, 2007-02-19 06:46:16-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libparse/Makefile.am@1.9, 2007-01-03 16:40:00-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.c@1.54, 2007-02-19 06:46:16-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libparse/clk_computime.c@1.9, 2007-01-03 16:40:00-05:00, stenn@pogo.udel.edu +3 -3 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.h@1.54, 2007-02-19 06:46:17-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC4 + libparse/clk_dcf7000.c@1.9, 2007-01-03 16:40:00-05:00, stenn@pogo.udel.edu +3 -3 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.texi@1.52, 2007-02-19 06:46:18-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libparse/clk_hopf6021.c@1.9, 2007-01-03 16:40:00-05:00, stenn@pogo.udel.edu +3 -3 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc.1@1.52, 2007-02-19 06:46:18-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libparse/clk_meinberg.c@1.10, 2007-01-03 16:40:00-05:00, stenn@pogo.udel.edu +4 -4 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.c@1.56, 2007-02-19 06:46:19-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libparse/clk_rawdcf.c@1.15, 2007-01-03 16:40:01-05:00, stenn@pogo.udel.edu +3 -3 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.h@1.56, 2007-02-19 06:46:19-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC4 + libparse/clk_rcc8000.c@1.9, 2007-01-03 16:40:01-05:00, stenn@pogo.udel.edu +3 -3 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.texi@1.53, 2007-02-19 06:46:20-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libparse/clk_schmid.c@1.9, 2007-01-03 16:40:01-05:00, stenn@pogo.udel.edu +3 -3 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq.1@1.52, 2007-02-19 06:46:21-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libparse/clk_trimtaip.c@1.9, 2007-01-03 16:40:01-05:00, stenn@pogo.udel.edu +3 -3 + [Bug 756] Require ANSI C (function prototypes) - packageinfo.sh@1.71, 2007-02-19 06:46:22-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC4 + libparse/clk_trimtsip.c@1.9, 2007-01-03 16:40:01-05:00, stenn@pogo.udel.edu +2 -2 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp-opts.c@1.53, 2007-02-19 06:46:22-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libparse/clk_varitext.c@1.8, 2007-01-03 16:40:01-05:00, stenn@pogo.udel.edu +3 -3 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp-opts.h@1.53, 2007-02-19 06:46:23-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC4 + libparse/data_mbg.c@1.9, 2007-01-03 16:40:01-05:00, stenn@pogo.udel.edu +2 -2 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp-opts.texi@1.50, 2007-02-19 06:46:24-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0_RC4 + libparse/ieee754io.c@1.9, 2007-01-03 16:40:01-05:00, stenn@pogo.udel.edu +2 -2 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp.1@1.53, 2007-02-19 06:46:24-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libparse/parse.c@1.12, 2007-01-03 16:40:01-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - util/ntp-keygen-opts.c@1.53, 2007-02-19 06:46:25-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libparse/parsesolaris.c@1.7, 2007-01-03 16:40:02-05:00, stenn@pogo.udel.edu +13 -13 + [Bug 756] Require ANSI C (function prototypes) - util/ntp-keygen-opts.h@1.53, 2007-02-19 06:46:25-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC4 + m4/hs_ulong_const.m4@1.2, 2007-01-03 16:40:02-05:00, stenn@pogo.udel.edu +1 -9 + [Bug 756] Require ANSI C (function prototypes) - util/ntp-keygen-opts.texi@1.51, 2007-02-19 06:46:26-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + m4/os_cflags.m4@1.3, 2007-01-03 16:38:27-05:00, stenn@pogo.udel.edu +8 -5 + Upgraded to the latest version from am-utils - util/ntp-keygen.1@1.51, 2007-02-19 06:46:27-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + ntpd/Makefile.am@1.53, 2007-01-03 16:40:02-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1465, 2007-02-19 00:19:22-05:00, stenn@whimsy.udel.edu +1 -0 - Ready to go... + ntpd/ntp_config.c@1.143, 2007-01-03 16:40:02-05:00, stenn@pogo.udel.edu +15 -15 + [Bug 756] Require ANSI C (function prototypes) - packageinfo.sh@1.70, 2007-02-19 00:19:05-05:00, stenn@whimsy.udel.edu +2 -2 - Ready to go... + ntpd/ntp_control.c@1.88, 2007-01-03 16:40:02-05:00, stenn@pogo.udel.edu +31 -31 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1464, 2007-02-19 00:14:29-05:00, stenn@whimsy.udel.edu +3 -0 - [Bug 776] Remove unimplemented "rate" flag from ntpdate + ntpd/ntp_crypto.c@1.108, 2007-01-03 16:40:03-05:00, stenn@pogo.udel.edu +25 -25 + [Bug 756] Require ANSI C (function prototypes) - ChangeLog@1.9, 2007-02-19 00:14:19-05:00, stenn@whimsy.udel.edu +1 -0 - [Bug 776] Remove unimplemented "rate" flag from ntpdate + ntpd/ntp_filegen.c@1.12, 2007-01-03 16:40:03-05:00, stenn@pogo.udel.edu +4 -4 + [Bug 756] Require ANSI C (function prototypes) - ntpdate/Makefile.am@1.15, 2007-02-19 00:13:50-05:00, stenn@whimsy.udel.edu +1 -1 - [Bug 776] Remove unimplemented "rate" flag from ntpdate + ntpd/ntp_intres.c@1.49, 2007-01-03 16:40:03-05:00, stenn@pogo.udel.edu +12 -12 + [Bug 756] Require ANSI C (function prototypes) - ntpdate/ntpdate.c@1.60, 2007-02-19 00:13:51-05:00, stenn@whimsy.udel.edu +1 -21 - [Bug 776] Remove unimplemented "rate" flag from ntpdate + ntpd/ntp_io.c@1.245, 2007-01-03 16:40:03-05:00, stenn@pogo.udel.edu +35 -35 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1463, 2007-02-05 06:47:44-05:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4_RC3 - TAG: NTP_4_2_4_RC3 + ntpd/ntp_loopfilter.c@1.129, 2007-01-03 16:40:04-05:00, stenn@pogo.udel.edu +2 -2 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd-opts.c@1.53, 2007-02-05 06:47:21-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/ntp_monitor.c@1.19, 2007-01-03 16:40:04-05:00, stenn@pogo.udel.edu +2 -2 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd-opts.h@1.53, 2007-02-05 06:47:21-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC3 + ntpd/ntp_peer.c@1.98, 2007-01-03 16:40:04-05:00, stenn@pogo.udel.edu +2 -2 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd-opts.texi@1.52, 2007-02-05 06:47:22-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC3 + ntpd/ntp_proto.c@1.250, 2007-01-03 16:40:04-05:00, stenn@pogo.udel.edu +8 -8 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd.1@1.51, 2007-02-05 06:47:23-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/ntp_refclock.c@1.76, 2007-01-03 16:40:04-05:00, stenn@pogo.udel.edu +3 -3 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.c@1.53, 2007-02-05 06:47:24-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/ntp_request.c@1.66, 2007-01-03 16:40:05-05:00, stenn@pogo.udel.edu +50 -50 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.h@1.53, 2007-02-05 06:47:24-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC3 + ntpd/ntp_timer.c@1.34, 2007-01-03 16:40:05-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.texi@1.51, 2007-02-05 06:47:25-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC3 + ntpd/ntpd.c@1.83, 2007-01-03 16:40:05-05:00, stenn@pogo.udel.edu +9 -9 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim.1@1.51, 2007-02-05 06:47:26-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/refclock_acts.c@1.29, 2007-01-03 16:40:06-05:00, stenn@pogo.udel.edu +9 -9 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.c@1.53, 2007-02-05 06:47:26-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/refclock_arbiter.c@1.14, 2007-01-03 16:40:06-05:00, stenn@pogo.udel.edu +4 -4 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.h@1.53, 2007-02-05 06:47:28-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC3 + ntpd/refclock_arc.c@1.19, 2007-01-03 16:40:06-05:00, stenn@pogo.udel.edu +7 -7 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.texi@1.51, 2007-02-05 06:47:28-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC3 + ntpd/refclock_as2201.c@1.10, 2007-01-03 16:40:06-05:00, stenn@pogo.udel.edu +4 -4 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc.1@1.51, 2007-02-05 06:47:29-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/refclock_atom.c@1.55, 2007-01-03 16:40:06-05:00, stenn@pogo.udel.edu +7 -7 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.c@1.55, 2007-02-05 06:47:30-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/refclock_chronolog.c@1.7, 2007-01-03 16:40:07-05:00, stenn@pogo.udel.edu +4 -4 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.h@1.55, 2007-02-05 06:47:30-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC3 + ntpd/refclock_chu.c@1.39, 2007-01-03 16:40:07-05:00, stenn@pogo.udel.edu +17 -17 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.texi@1.52, 2007-02-05 06:47:31-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC3 + ntpd/refclock_datum.c@1.10, 2007-01-03 16:40:07-05:00, stenn@pogo.udel.edu +8 -8 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq.1@1.51, 2007-02-05 06:47:32-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/refclock_dumbclock.c@1.9, 2007-01-03 16:40:07-05:00, stenn@pogo.udel.edu +4 -4 + [Bug 756] Require ANSI C (function prototypes) - packageinfo.sh@1.69, 2007-02-05 06:47:33-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC3 + ntpd/refclock_fg.c@1.11, 2007-01-03 16:40:07-05:00, stenn@pogo.udel.edu +5 -5 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp-opts.c@1.52, 2007-02-05 06:47:33-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/refclock_heath.c@1.14, 2007-01-03 16:40:07-05:00, stenn@pogo.udel.edu +4 -4 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp-opts.h@1.52, 2007-02-05 06:47:34-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC3 + ntpd/refclock_hopfser.c@1.10, 2007-01-03 16:40:07-05:00, stenn@pogo.udel.edu +5 -5 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp-opts.texi@1.49, 2007-02-05 06:47:35-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC3 + ntpd/refclock_hpgps.c@1.8, 2007-01-03 16:40:07-05:00, stenn@pogo.udel.edu +4 -4 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp.1@1.52, 2007-02-05 06:47:37-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/refclock_irig.c@1.25, 2007-01-03 16:40:08-05:00, stenn@pogo.udel.edu +8 -8 + [Bug 756] Require ANSI C (function prototypes) - util/ntp-keygen-opts.c@1.52, 2007-02-05 06:47:38-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/refclock_jjy.c@1.14, 2007-01-03 16:40:08-05:00, stenn@pogo.udel.edu +10 -10 + [Bug 756] Require ANSI C (function prototypes) - util/ntp-keygen-opts.h@1.52, 2007-02-05 06:47:39-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC3 + ntpd/refclock_jupiter.c@1.21, 2007-01-03 16:40:08-05:00, stenn@pogo.udel.edu +19 -19 + [Bug 756] Require ANSI C (function prototypes) - util/ntp-keygen-opts.texi@1.50, 2007-02-05 06:47:39-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC3 + ntpd/refclock_leitch.c@1.9, 2007-01-03 16:40:08-05:00, stenn@pogo.udel.edu +11 -11 + [Bug 756] Require ANSI C (function prototypes) - util/ntp-keygen.1@1.50, 2007-02-05 06:47:40-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/refclock_local.c@1.16, 2007-01-03 16:40:08-05:00, stenn@pogo.udel.edu +2 -2 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1462, 2007-02-04 23:08:28-05:00, stenn@whimsy.udel.edu +1 -0 - Danny forgot to pull before editing - replace the change he undid. + ntpd/refclock_mx4200.c@1.23, 2007-01-03 16:40:08-05:00, stenn@pogo.udel.edu +16 -16 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-subs.c@1.27, 2007-02-04 23:08:17-05:00, stenn@whimsy.udel.edu +3 -2 - Danny forgot to pull before editing - replace the change he undid. + ntpd/refclock_neoclock4x.c@1.16, 2007-01-03 16:40:08-05:00, stenn@pogo.udel.edu +12 -12 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1461, 2007-02-04 22:53:32-05:00, stenn@whimsy.udel.edu +1 -0 - [Bug 586] Avoid lookups if AI_NUMERICHOST is set. + ntpd/refclock_nmea.c@1.26, 2007-01-03 16:40:08-05:00, stenn@pogo.udel.edu +10 -10 + [Bug 756] Require ANSI C (function prototypes) - ChangeLog@1.8, 2007-02-04 22:53:22-05:00, stenn@whimsy.udel.edu +1 -0 - [Bug 586] Avoid lookups if AI_NUMERICHOST is set. + ntpd/refclock_oncore.c@1.61, 2007-01-03 16:40:08-05:00, stenn@pogo.udel.edu +48 -48 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1460, 2007-02-04 21:51:15-05:00, mayer@pogo.udel.edu +1 -0 - Bug #586 Don't do lookups if AI_NUMERICHOST is set + ntpd/refclock_palisade.c@1.19, 2007-01-03 16:40:09-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - libntp/ntp_rfc2553.c@1.37, 2007-02-04 21:51:01-05:00, mayer@pogo.udel.edu +6 -0 - Bug #586 Don't do lookups if AI_NUMERICHOST is set + ntpd/refclock_palisade.h@1.9, 2007-01-03 16:40:09-05:00, stenn@pogo.udel.edu +11 -11 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1459, 2007-02-04 21:44:13-05:00, mayer@pogo.udel.edu +1 -0 - Bug #586 Check for <4 characters for the refid first + ntpd/refclock_parse.c@1.48, 2007-01-03 16:40:09-05:00, stenn@pogo.udel.edu +67 -67 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-subs.c@1.26, 2007-02-04 21:43:38-05:00, mayer@pogo.udel.edu +9 -10 - Bug #586 Check for <4 characters for the refid first + ntpd/refclock_pcf.c@1.8, 2007-01-03 16:40:09-05:00, stenn@pogo.udel.edu +3 -3 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1458, 2007-02-04 17:56:17+00:00, kardel@pogo.udel.edu +1 -0 - ntpd.c: - comment clarification about capabilities used + ntpd/refclock_pst.c@1.9, 2007-01-03 16:40:09-05:00, stenn@pogo.udel.edu +4 -4 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd.c@1.84, 2007-02-04 17:55:31+00:00, kardel@pogo.udel.edu +4 -7 - comment clarification about capabilities used + ntpd/refclock_true.c@1.10, 2007-01-03 16:40:10-05:00, stenn@pogo.udel.edu +7 -7 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1451.1.1, 2007-02-04 17:47:20+00:00, kardel@pogo.udel.edu +1 -0 - ntpd.c: - Bug 765: - use Linux capability mechanism to allow dynamic interface tracking to continue in - unprivileged mode. + ntpd/refclock_ulink.c@1.14, 2007-01-03 16:40:10-05:00, stenn@pogo.udel.edu +4 -4 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd.c@1.83, 2007-02-04 17:45:55+00:00, kardel@pogo.udel.edu +11 -1 - Bug 765: - use Linux capability mechanism to allow dynamic interface tracking to continue in - unprivileged mode. + ntpd/refclock_wwv.c@1.68, 2007-01-03 16:40:10-05:00, stenn@pogo.udel.edu +21 -21 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1456, 2007-01-30 06:44:11-05:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4_RC2 - TAG: NTP_4_2_4_RC2 + ntpd/refclock_wwvb.c@1.17, 2007-01-03 16:40:10-05:00, stenn@pogo.udel.edu +5 -5 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd-opts.c@1.52, 2007-01-30 06:43:46-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 + ntpd/refclock_zyfer.c@1.5, 2007-01-03 16:40:10-05:00, stenn@pogo.udel.edu +4 -4 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd-opts.h@1.52, 2007-01-30 06:43:46-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC2 + ntpdate/Makefile.am@1.15, 2007-01-03 16:40:10-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd-opts.texi@1.51, 2007-01-30 06:43:47-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC2 + ntpdate/ntpdate.c@1.60, 2007-01-03 16:40:10-05:00, stenn@pogo.udel.edu +19 -19 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd.1@1.50, 2007-01-30 06:43:48-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 + ntpdate/ntpdate.h@1.8, 2007-01-03 16:40:11-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.c@1.52, 2007-01-30 06:43:49-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 + ntpdc/Makefile.am@1.34, 2007-01-03 16:40:11-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.h@1.52, 2007-01-30 06:43:50-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC2 + ntpdc/ntpdc.c@1.55, 2007-01-03 16:40:11-05:00, stenn@pogo.udel.edu +30 -30 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.texi@1.50, 2007-01-30 06:43:51-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC2 + ntpdc/ntpdc.h@1.8, 2007-01-03 16:40:11-05:00, stenn@pogo.udel.edu +3 -3 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim.1@1.50, 2007-01-30 06:43:52-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 + ntpdc/ntpdc_ops.c@1.47, 2007-01-03 16:40:12-05:00, stenn@pogo.udel.edu +53 -53 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.c@1.52, 2007-01-30 06:43:52-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 + ntpq/Makefile.am@1.26, 2007-01-03 16:40:12-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.h@1.52, 2007-01-30 06:43:54-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC2 + ntpq/ntpq-subs.c@1.26, 2007-01-03 16:40:12-05:00, stenn@pogo.udel.edu +41 -41 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.texi@1.50, 2007-01-30 06:43:55-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC2 + ntpq/ntpq.c@1.66, 2007-01-03 16:40:12-05:00, stenn@pogo.udel.edu +46 -46 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc.1@1.50, 2007-01-30 06:43:55-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 + ntpq/ntpq.h@1.6, 2007-01-03 16:40:13-05:00, stenn@pogo.udel.edu +13 -13 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.c@1.54, 2007-01-30 06:43:56-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 + parseutil/Makefile.am@1.7, 2007-01-03 16:40:13-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.h@1.54, 2007-01-30 06:43:57-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC2 + parseutil/dcfd.c@1.20, 2007-01-03 16:40:13-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.texi@1.51, 2007-01-30 06:43:57-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC2 + util/Makefile.am@1.35, 2007-01-03 16:40:20-05:00, stenn@pogo.udel.edu +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq.1@1.50, 2007-01-30 06:43:58-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 + util/jitter.h@1.2, 2007-01-03 16:40:21-05:00, stenn@pogo.udel.edu +0 -11 + [Bug 756] Require ANSI C (function prototypes) - packageinfo.sh@1.68, 2007-01-30 06:43:59-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC2 + util/ntp-keygen.c@1.38, 2007-01-03 16:40:21-05:00, stenn@pogo.udel.edu +14 -14 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp-opts.c@1.51, 2007-01-30 06:43:59-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 + util/ntptime.c@1.20, 2007-01-03 16:40:21-05:00, stenn@pogo.udel.edu +3 -3 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp-opts.h@1.51, 2007-01-30 06:44:00-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC2 +ChangeSet@1.1442, 2007-01-02 23:16:36-05:00, skamboj@ferrari.local +1 -0 + ntp_config.y: + New BitKeeper file ``ntpd/ntp_config.y'' - sntp/sntp-opts.texi@1.48, 2007-01-30 06:44:01-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC2 + ntpd/ntp_config.y@1.1, 2007-01-02 23:15:05-05:00, skamboj@ferrari.local +917 -0 + New BitKeeper file ``ntpd/ntp_config.y'' - sntp/sntp.1@1.51, 2007-01-30 06:44:02-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 + ntpd/ntp_config.y@1.0, 2007-01-02 23:15:05-05:00, skamboj@ferrari.local +0 -0 - util/ntp-keygen-opts.c@1.51, 2007-01-30 06:44:03-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 +ChangeSet@1.1441, 2007-01-02 23:14:13-05:00, skamboj@ferrari.local +4 -0 + Added code for: + 1. A phrase-structure grammar based NTP configuration file parser + 2. A multi-server NTP simulator - util/ntp-keygen-opts.h@1.51, 2007-01-30 06:44:03-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC2 + include/ntp_data_structures.h@1.1, 2007-01-02 23:14:12-05:00, skamboj@ferrari.local +47 -0 + New BitKeeper file ``include/ntp_data_structures.h'' - util/ntp-keygen-opts.texi@1.49, 2007-01-30 06:44:04-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC2 + include/ntp_data_structures.h@1.0, 2007-01-02 23:14:12-05:00, skamboj@ferrari.local +0 -0 - util/ntp-keygen.1@1.49, 2007-01-30 06:44:05-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 + ntpd/ntp_config.tab.c@1.1, 2007-01-02 23:14:12-05:00, skamboj@ferrari.local +2351 -0 + New BitKeeper file ``ntpd/ntp_config.tab.c'' -ChangeSet@1.1455, 2007-01-29 21:20:08-05:00, stenn@whimsy.udel.edu +2 -0 - [Bug 770] Fix numeric parameters to ntp-keygen (Alain Guibert). + ntpd/ntp_config.tab.c@1.0, 2007-01-02 23:14:12-05:00, skamboj@ferrari.local +0 -0 - ChangeLog@1.7, 2007-01-29 21:19:52-05:00, stenn@whimsy.udel.edu +1 -0 - [Bug 770] Fix numeric parameters to ntp-keygen (Alain Guibert). + ntpd/ntp_data_structures.c@1.1, 2007-01-02 23:14:12-05:00, skamboj@ferrari.local +170 -0 + New BitKeeper file ``ntpd/ntp_data_structures.c'' - util/ntp-keygen.c@1.38, 2007-01-29 21:19:53-05:00, stenn@whimsy.udel.edu +3 -3 - [Bug 770] Fix numeric parameters to ntp-keygen (Alain Guibert). + ntpd/ntp_data_structures.c@1.0, 2007-01-02 23:14:12-05:00, skamboj@ferrari.local +0 -0 -ChangeSet@1.1454, 2007-01-29 17:43:41-05:00, stenn@whimsy.udel.edu +1 -0 - More ChangeLog -> CommitLog fixes + ntpd/ntp_scanner.c@1.1, 2007-01-02 23:14:12-05:00, skamboj@ferrari.local +638 -0 + New BitKeeper file ``ntpd/ntp_scanner.c'' - scripts/genCommitLog@1.4, 2007-01-29 17:42:48-05:00, stenn@whimsy.udel.edu +2 -2 - More ChangeLog -> CommitLog fixes + ntpd/ntp_scanner.c@1.0, 2007-01-02 23:14:12-05:00, skamboj@ferrari.local +0 -0 -ChangeSet@1.1453, 2007-01-29 16:52:38-05:00, stenn@whimsy.udel.edu +3 -0 - More ChangeLog -> CommitLog fixes +ChangeSet@1.1440, 2006-12-29 06:43:02-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5P0 + TAG: NTP_4_2_5P0 - Makefile.am@1.72, 2007-01-29 16:52:06-05:00, stenn@whimsy.udel.edu +5 -5 - More ChangeLog -> CommitLog fixes + ntpd/ntpd-opts.c@1.49.1.2, 2006-12-29 06:42:43-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P0 - scripts/Makefile.am@1.15, 2007-01-29 16:52:07-05:00, stenn@whimsy.udel.edu +1 -1 - More ChangeLog -> CommitLog fixes + ntpd/ntpd-opts.h@1.49.1.2, 2006-12-29 06:42:43-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P0 - scripts/genCommitLog@1.3, 2007-01-29 16:09:19-05:00, stenn@whimsy.udel.edu +0 -0 - Rename: scripts/genChangeLog -> scripts/genCommitLog + ntpd/ntpd-opts.texi@1.48.1.2, 2006-12-29 06:42:44-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P0 -ChangeSet@1.1452, 2007-01-28 23:24:05-05:00, stenn@whimsy.udel.edu +1 -0 - Entries for bugs 765 and 768 + ntpd/ntpd.1@1.47.1.2, 2006-12-29 06:42:45-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P0 - ChangeLog@1.6, 2007-01-28 23:23:45-05:00, stenn@whimsy.udel.edu +2 -0 - Entries for bugs 765 and 768 + ntpd/ntpdsim-opts.c@1.49.1.2, 2006-12-29 06:42:45-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P0 -ChangeSet@1.1451, 2007-01-27 08:54:51+00:00, kardel@pogo.udel.edu +1 -0 - ntp_io.c: - fix misleading error message when calling io_setbclient() and - broadcast sockets are already open and not new sockets need to - be opened. - Bug 768: fix binding for broadcast client mode (Ulrich Weber) + ntpd/ntpdsim-opts.h@1.49.1.2, 2006-12-29 06:42:46-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P0 - ntpd/ntp_io.c@1.247, 2007-01-27 08:51:50+00:00, kardel@pogo.udel.edu +6 -3 - fix misleading error message when calling io_setbclient() and - broadcast sockets are already open and not new sockets need to - be opened. + ntpd/ntpdsim-opts.texi@1.47.1.2, 2006-12-29 06:42:47-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P0 - ntpd/ntp_io.c@1.246, 2007-01-27 08:24:25+00:00, kardel@pogo.udel.edu +2 -2 - Bug 768: fix binding for broadcast client mode (Ulrich Weber) + ntpd/ntpdsim.1@1.47.1.2, 2006-12-29 06:42:48-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P0 -ChangeSet@1.1450, 2007-01-23 04:47:08-05:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4_RC1 - TAG: NTP_4_2_4_RC1 + ntpdc/ntpdc-opts.c@1.49.1.2, 2006-12-29 06:42:48-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P0 - ntpd/ntpd-opts.c@1.51, 2007-01-23 04:46:47-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + ntpdc/ntpdc-opts.h@1.49.1.2, 2006-12-29 06:42:49-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P0 - ntpd/ntpd-opts.h@1.51, 2007-01-23 04:46:48-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC1 + ntpdc/ntpdc-opts.texi@1.47.1.2, 2006-12-29 06:42:50-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P0 - ntpd/ntpd-opts.texi@1.50, 2007-01-23 04:46:48-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + ntpdc/ntpdc.1@1.47.1.2, 2006-12-29 06:42:51-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P0 - ntpd/ntpd.1@1.49, 2007-01-23 04:46:49-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + ntpq/ntpq-opts.c@1.51.1.2, 2006-12-29 06:42:51-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P0 - ntpd/ntpdsim-opts.c@1.51, 2007-01-23 04:46:50-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + ntpq/ntpq-opts.h@1.51.1.2, 2006-12-29 06:42:52-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P0 - ntpd/ntpdsim-opts.h@1.51, 2007-01-23 04:46:50-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC1 + ntpq/ntpq-opts.texi@1.48.1.2, 2006-12-29 06:42:53-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P0 - ntpd/ntpdsim-opts.texi@1.49, 2007-01-23 04:46:52-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC1 + ntpq/ntpq.1@1.47.1.2, 2006-12-29 06:42:53-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P0 - ntpd/ntpdsim.1@1.49, 2007-01-23 04:46:52-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + packageinfo.sh@1.3, 2006-12-29 06:42:54-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P0 - ntpdc/ntpdc-opts.c@1.51, 2007-01-23 04:46:53-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + sntp/sntp-opts.c@1.48.1.2, 2006-12-29 06:42:54-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P0 - ntpdc/ntpdc-opts.h@1.51, 2007-01-23 04:46:54-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC1 + sntp/sntp-opts.h@1.48.1.2, 2006-12-29 06:42:55-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P0 - ntpdc/ntpdc-opts.texi@1.49, 2007-01-23 04:46:54-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + sntp/sntp-opts.texi@1.45.1.2, 2006-12-29 06:42:55-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P0 - ntpdc/ntpdc.1@1.49, 2007-01-23 04:46:55-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + sntp/sntp.1@1.48.1.2, 2006-12-29 06:42:56-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P0 - ntpq/ntpq-opts.c@1.53, 2007-01-23 04:46:56-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + util/ntp-keygen-opts.c@1.48.1.2, 2006-12-29 06:42:57-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P0 - ntpq/ntpq-opts.h@1.53, 2007-01-23 04:46:57-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC1 + util/ntp-keygen-opts.h@1.48.1.2, 2006-12-29 06:42:57-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5P0 - ntpq/ntpq-opts.texi@1.50, 2007-01-23 04:46:57-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + util/ntp-keygen-opts.texi@1.46.1.2, 2006-12-29 06:42:58-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5P0 - ntpq/ntpq.1@1.49, 2007-01-23 04:46:58-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + util/ntp-keygen.1@1.46.1.2, 2006-12-29 06:42:59-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5P0 - packageinfo.sh@1.67, 2007-01-23 04:46:59-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC1 +ChangeSet@1.1439, 2006-12-28 22:56:08-05:00, stenn@whimsy.udel.edu +10 -0 + codec (audio) and ICOM changes from Dave Mills - sntp/sntp-opts.c@1.50, 2007-01-23 04:47:00-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + NEWS@1.87, 2006-12-28 22:55:58-05:00, stenn@whimsy.udel.edu +2 -0 + codec (audio) and ICOM changes from Dave Mills - sntp/sntp-opts.h@1.50, 2007-01-23 04:47:00-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC1 + include/ntp.h@1.129, 2006-12-28 22:51:34-05:00, stenn@whimsy.udel.edu +1 -0 + codec (audio) changes from Dave Mills - sntp/sntp-opts.texi@1.47, 2007-01-23 04:47:01-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC1 + include/ntp_config.h@1.41, 2006-12-28 22:51:36-05:00, stenn@whimsy.udel.edu +1 -0 + codec (audio) changes from Dave Mills - sntp/sntp.1@1.50, 2007-01-23 04:47:02-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + include/ntpd.h@1.98, 2006-12-28 22:51:43-05:00, stenn@whimsy.udel.edu +1 -0 + codec (audio) changes from Dave Mills - util/ntp-keygen-opts.c@1.50, 2007-01-23 04:47:03-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + libntp/audio.c@1.24, 2006-12-28 22:52:25-05:00, stenn@whimsy.udel.edu +2 -1 + codec (audio) and ICOM changes from Dave Mills - util/ntp-keygen-opts.h@1.50, 2007-01-23 04:47:04-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC1 + libntp/icom.c@1.10, 2006-12-28 22:52:30-05:00, stenn@whimsy.udel.edu +33 -218 + codec (audio) and ICOM changes from Dave Mills - util/ntp-keygen-opts.texi@1.48, 2007-01-23 04:47:04-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + ntpd/ntp_config.c@1.142, 2006-12-28 22:54:05-05:00, stenn@whimsy.udel.edu +4 -0 + codec (audio) and ICOM changes from Dave Mills - util/ntp-keygen.1@1.48, 2007-01-23 04:47:05-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + ntpd/ntp_loopfilter.c@1.128, 2006-12-28 22:54:08-05:00, stenn@whimsy.udel.edu +5 -10 + codec (audio) and ICOM changes from Dave Mills -ChangeSet@1.1449, 2007-01-21 12:44:07-05:00, stenn@whimsy.udel.edu +1 -0 - Danny fixed bug 360 in 4.2.2 + ntpd/refclock_irig.c@1.24, 2006-12-28 22:54:17-05:00, stenn@whimsy.udel.edu +1 -1 + codec (audio) and ICOM changes from Dave Mills - ChangeLog@1.5, 2007-01-21 12:43:50-05:00, stenn@whimsy.udel.edu +1 -0 - Danny fixed bug 360 in 4.2.2 + ntpd/refclock_wwv.c@1.67, 2006-12-28 22:54:22-05:00, stenn@whimsy.udel.edu +45 -54 + codec (audio) and ICOM changes from Dave Mills -ChangeSet@1.1448, 2007-01-21 12:40:23-05:00, stenn@whimsy.udel.edu +1 -0 - Danny fixed bug 239 in 4.2.2 +ChangeSet@1.1438, 2006-12-28 21:29:25-05:00, stenn@whimsy.udel.edu +25 -0 + NTP_4_2_5 + TAG: NTP_4_2_5 - ChangeLog@1.4, 2007-01-21 12:40:13-05:00, stenn@whimsy.udel.edu +2 -0 - Danny fixed bug 239 in 4.2.2 + ntpd/ntpd-opts.c@1.49.1.1, 2006-12-28 21:29:00-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5 -ChangeSet@1.1447, 2007-01-21 12:33:46-05:00, stenn@pogo.udel.edu +1 -0 - Added bug 760 description to the ChangeLog + ntpd/ntpd-opts.h@1.49.1.1, 2006-12-28 21:29:01-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5 - ChangeLog@1.3, 2007-01-21 12:33:38-05:00, stenn@pogo.udel.edu +1 -0 - Added bug 760 description to the ChangeLog + ntpd/ntpd-opts.texi@1.48.1.1, 2006-12-28 21:29:02-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5 -ChangeSet@1.1446, 2007-01-21 12:28:04-05:00, stenn@pogo.udel.edu +1 -0 - Update the ChangeLog + ntpd/ntpd.1@1.47.1.1, 2006-12-28 21:29:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5 - ChangeLog@1.2, 2007-01-21 12:27:59-05:00, stenn@pogo.udel.edu +3 -0 - Update the ChangeLog + ntpd/ntpdsim-opts.c@1.49.1.1, 2006-12-28 21:29:03-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5 -ChangeSet@1.1445, 2007-01-21 07:49:58+00:00, kardel@pogo.udel.edu +1 -0 - ntp_io.c: - pick the right type for the recv*() length argument (use GETSOCKNAME_SOCKLEN_TYPE config.h define) + ntpd/ntpdsim-opts.h@1.49.1.1, 2006-12-28 21:29:04-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5 - ntpd/ntp_io.c@1.245, 2007-01-21 07:48:16+00:00, kardel@pogo.udel.edu +1 -1 - pick the right type for the recv*() length argument (use GETSOCKNAME_SOCKLEN_TYPE config.h define) + ntpd/ntpdsim-opts.texi@1.47.1.1, 2006-12-28 21:29:05-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5 -ChangeSet@1.1444, 2007-01-20 14:38:38+00:00, kardel@pogo.udel.edu +1 -0 - confopt.html: - move description for "dynamic" keyword into the right section + ntpd/ntpdsim.1@1.47.1.1, 2006-12-28 21:29:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5 - html/confopt.html@1.35, 2007-01-20 14:37:48+00:00, kardel@pogo.udel.edu +4 -3 - move description for "dynamic" keyword into the right section + ntpdc/ntpdc-opts.c@1.49.1.1, 2006-12-28 21:29:06-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5 -ChangeSet@1.1443, 2007-01-14 08:46:00+00:00, kardel@pogo.udel.edu +1 -0 - parse.h: - Bug 753: make union timestamp anonymous (Philip Prindeville) - now there are OSes that claim that name in netinet/ip.h... + ntpdc/ntpdc-opts.h@1.49.1.1, 2006-12-28 21:29:08-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5 - include/parse.h@1.8, 2007-01-14 08:41:52+00:00, kardel@pogo.udel.edu +8 -4 - Bug 753: make union timestamp anonymous (Philip Prindeville) - now there are OSes that claim that name in netinet/ip.h... + ntpdc/ntpdc-opts.texi@1.47.1.1, 2006-12-28 21:29:08-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5 -ChangeSet@1.1442, 2007-01-13 11:36:29+00:00, kardel@pogo.udel.edu +1 -0 - ntp_intres.c: - support dynamic keyword + ntpdc/ntpdc.1@1.47.1.1, 2006-12-28 21:29:09-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5 - ntpd/ntp_intres.c@1.49, 2007-01-13 11:35:58+00:00, kardel@pogo.udel.edu +3 -1 - support dynamic keyword + ntpq/ntpq-opts.c@1.51.1.1, 2006-12-28 21:29:10-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5 -ChangeSet@1.1441, 2007-01-06 18:24:18-05:00, stenn@whimsy.udel.edu +1 -0 - Updated copyright year + ntpq/ntpq-opts.h@1.51.1.1, 2006-12-28 21:29:10-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5 - html/copyright.html@1.36, 2007-01-06 18:23:45-05:00, stenn@whimsy.udel.edu +2 -2 - Updated copyright year + ntpq/ntpq-opts.texi@1.48.1.1, 2006-12-28 21:29:11-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5 -ChangeSet@1.1440, 2007-01-05 00:27:33-05:00, stenn@whimsy.udel.edu +4 -0 - ChangeLog->CommitLog, NEWS->ChangeLog, Release Info->NEWS + ntpq/ntpq.1@1.47.1.1, 2006-12-28 21:29:12-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5 - ChangeLog@1.1, 2007-01-05 00:06:33-05:00, stenn@whimsy.udel.edu +260 -0 - BitKeeper file /deacon/backroom/ntp-stable/ChangeLog + packageinfo.sh@1.2, 2006-12-28 21:29:13-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5 - ChangeLog@1.0, 2007-01-05 00:06:33-05:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.c@1.48.1.1, 2006-12-28 21:29:14-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5 - CommitLog-4.1.0@1.592, 2007-01-05 00:05:52-05:00, stenn@whimsy.udel.edu +0 -0 - Rename: ChangeLog-4.1.0 -> CommitLog-4.1.0 + sntp/sntp-opts.h@1.48.1.1, 2006-12-28 21:29:15-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5 - Makefile.am@1.71, 2007-01-05 00:27:13-05:00, stenn@whimsy.udel.edu +2 -1 - ChangeLog->CommitLog, NEWS->ChangeLog, Release Info->NEWS + sntp/sntp-opts.texi@1.45.1.1, 2006-12-28 21:29:15-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5 - NEWS@1.87, 2007-01-05 00:27:14-05:00, stenn@whimsy.udel.edu +14 -256 - ChangeLog->CommitLog, NEWS->ChangeLog, Release Info->NEWS + sntp/sntp.1@1.48.1.1, 2006-12-28 21:29:16-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5 -ChangeSet@1.1439, 2007-01-04 23:41:02-05:00, stenn@whimsy.udel.edu +1 -0 - ChangeLog->CommitLog in the ignore file + util/ntp-keygen-opts.c@1.48.1.1, 2006-12-28 21:29:17-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5 - BitKeeper/etc/ignore@1.59, 2007-01-04 23:40:52-05:00, stenn@whimsy.udel.edu +1 -2 - ChangeLog->CommitLog in the ignore file + util/ntp-keygen-opts.h@1.48.1.1, 2006-12-28 21:29:17-05:00, stenn@whimsy.udel.edu +3 -3 + NTP_4_2_5 -ChangeSet@1.1438, 2007-01-04 19:31:07-05:00, stenn@whimsy.udel.edu +1 -0 - hostname updates for flock-build + util/ntp-keygen-opts.texi@1.46.1.1, 2006-12-28 21:29:18-05:00, stenn@whimsy.udel.edu +1 -1 + NTP_4_2_5 - flock-build@1.39, 2007-01-04 19:30:49-05:00, stenn@whimsy.udel.edu +15 -19 - hostname updates for flock-build + util/ntp-keygen.1@1.46.1.1, 2006-12-28 21:29:19-05:00, stenn@whimsy.udel.edu +2 -2 + NTP_4_2_5 -ChangeSet@1.1437, 2006-12-28 19:21:25-05:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1436.1.1, 2006-12-28 19:21:25-05:00, stenn@whimsy.udel.edu +25 -0 NTP_4_2_4 TAG: NTP_4_2_4 @@ -6045,7 +49703,7 @@ ntpq/ntpq.1@1.48, 2006-12-28 19:21:14-05:00, stenn@whimsy.udel.edu +2 -2 NTP_4_2_4 - packageinfo.sh@1.66, 2006-12-28 19:21:15-05:00, stenn@whimsy.udel.edu +2 -2 + packageinfo.sh@1.65.1.1, 2006-12-28 19:21:15-05:00, stenn@whimsy.udel.edu +2 -2 NTP_4_2_4 sntp/sntp-opts.c@1.49, 2006-12-28 19:21:15-05:00, stenn@whimsy.udel.edu +2 -2 @@ -6072,6 +49730,17 @@ util/ntp-keygen.1@1.47, 2006-12-28 19:21:21-05:00, stenn@whimsy.udel.edu +2 -2 NTP_4_2_4 +ChangeSet@1.1435.1.1, 2006-12-28 03:20:53-05:00, stenn@whimsy.udel.edu +2 -0 + ntp-4.2.5 + + BitKeeper/deleted/.del-packageinfo.sh~9547f70d1df81d4@1.64.1.1, 2006-12-28 03:17:43-05:00, stenn@whimsy.udel.edu +0 -0 + Delete: packageinfo.sh + + packageinfo.sh@1.1, 2006-12-28 03:18:24-05:00, stenn@whimsy.udel.edu +28 -0 + BitKeeper file /deacon/backroom/ntp-dev/packageinfo.sh + + packageinfo.sh@1.0, 2006-12-28 03:18:24-05:00, stenn@whimsy.udel.edu +0 -0 + ChangeSet@1.1436, 2006-12-28 03:09:12-05:00, stenn@whimsy.udel.edu +1 -0 typo @@ -14920,7 +58589,7 @@ [Bug 527] Lose signalled IO. configure.ac@1.359.1.28, 2006-04-20 23:58:47-04:00, stenn@whimsy.udel.edu +7 -2 - [Bug 527] Lose signalled IO. + [Bug 527] Losed signalled IO. ChangeSet@1.1251.85.1, 2006-04-18 05:58:13-04:00, stenn@whimsy.udel.edu +1 -0 there are 240 ntp-dev patch releases so far @@ -16372,10 +60041,10 @@ [Bug 517] Allow dynamic SSL libraries configure.ac@1.359.1.24, 2005-10-25 20:15:34-04:00, stenn@deacon.udel.edu +3 -2 - [Bug 517] Allow dynamic SSL libraries: also check /usr/sfw/{lib,include} + [Bug 519] Allow dynamic SSL libraries: also check /usr/sfw/{lib,include} ntpd/ntpd.c@1.61.1.12, 2005-10-25 20:14:38-04:00, stenn@deacon.udel.edu +9 -0 - [Bug 517] Allow dynamic SSL libraries: check SSLeay() for version info + [Bug 519] Allow dynamic SSL libraries: check SSLeay() for version info ChangeSet@1.1251.67.10, 2005-10-24 04:35:24-04:00, stenn@deacon.udel.edu +2 -0 Fixes from Dave Mills @@ -21850,7 +65519,6 @@ ntpdate/ntpdate.c@1.48, 2004-11-28 03:34:45-05:00, stenn@whimsy.udel.edu +2 -2 [Bug 363] ntpdate: use -1 to represent an invalid fd - Fix from Rainer Weikusat. ChangeSet@1.1251.1.27, 2004-11-21 21:33:09-05:00, stenn@whimsy.udel.edu +2 -0 [Bug 349] Patches from Takao Abe diff -urN src/contrib/ntp/Makefile.am src.ntp/contrib/ntp/Makefile.am --- src/contrib/ntp/Makefile.am 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/Makefile.am 2010-02-05 11:01:20.000000000 +0100 @@ -1,24 +1,25 @@ -#AUTOMAKE_OPTIONS = util/ansi2knr foreign dist-tarZ no-dependencies -AUTOMAKE_OPTIONS = util/ansi2knr foreign 1.8 +AUTOMAKE_OPTIONS = foreign 1.10 ACLOCAL_AMFLAGS= -I m4 -I libopts/m4 NULL= SUBDIRS= -if NEED_LIBOPTS -SUBDIRS+= libopts -endif SUBDIRS+= \ scripts \ include \ ElectricFence \ - @ARLIB_DIR@ \ + $(NULL) +if NEED_LIBOPTS +SUBDIRS+= libopts +endif +SUBDIRS+= \ libntp \ libparse \ ntpd \ ntpdate \ ntpdc \ ntpq \ + ntpsnmpd \ parseutil \ adjtimed \ clockstuff \ @@ -31,7 +32,6 @@ scripts \ include \ ElectricFence \ - arlib \ libntp \ libopts \ libparse \ @@ -39,6 +39,7 @@ ntpdate \ ntpdc \ ntpq \ + ntpsnmpd \ parseutil \ adjtimed \ clockstuff \ @@ -47,59 +48,79 @@ util \ $(NULL) -DISTCHECK_CONFIGURE_FLAGS= --with-arlib --enable-local-libopts +DISTCHECK_CONFIGURE_FLAGS = -C -EXTRA_DIST = \ - COPYRIGHT \ - ChangeLog \ - CommitLog \ - CommitLog-4.1.0 \ - NEWS \ - NOTES.y2kfixes \ - README.bk \ - README.hackers \ - README.patches \ - README.refclocks \ - README.versions \ - TODO \ - WHERE-TO-START \ - bootstrap \ - build \ - config.guess \ - config.h.in \ - config.sub \ - dot.emacs \ - excludes \ - flock-build \ - install-sh \ - packageinfo.sh \ - readme.y2kfixes \ +EXTRA_DIST = \ + $(srcdir)/COPYRIGHT \ + ChangeLog \ + CommitLog \ + CommitLog-4.1.0 \ + NEWS \ + NOTES.y2kfixes \ + README.bk \ + README.hackers \ + README.patches \ + README.refclocks \ + README.versions \ + TODO \ + WHERE-TO-START \ + bootstrap \ + build \ + config.guess \ + config.h.in \ + config.sub \ + dot.emacs \ + excludes \ + flock-build \ + install-sh \ + packageinfo.sh \ + readme.y2kfixes \ results.y2kfixes \ \ - conf \ - html \ - libisc \ - ports \ + conf \ + html \ + lib/isc \ + ports \ \ - bincheck.mf \ - version \ - version.m4 \ + bincheck.mf \ + depsver.mf \ + deps-ver \ + $(srcdir)/version \ + version.m4 \ \ $(NULL) +CLEANFILES = DISTCLEANFILES = .gcc-warning -#ETAGS_ARGS = $(srcdir)/Makefile.am $(srcdir)/configure.ac ETAGS_ARGS = Makefile.am configure.ac # HMS: make ports be the last directory... # DIST_HOOK_DIRS = conf html scripts ports # HMS: Keep .gcc-warning first, as that way it gets printed first. -BUILT_SOURCES = .gcc-warning $(srcdir)/COPYRIGHT $(srcdir)/version $(srcdir)/version.m4 $(srcdir)/include/version.def +BUILT_SOURCES = \ + .gcc-warning \ + libtool \ + $(srcdir)/COPYRIGHT \ + $(srcdir)/version \ + $(srcdir)/version.m4 \ + $(srcdir)/include/version.def \ + $(srcdir)/include/version.texi \ + $(NULL) $(srcdir)/COPYRIGHT: $(srcdir)/html/copyright.html - ( echo "This file is automatically generated from html/copyright.html" ; lynx -dump $(srcdir)/html/copyright.html ) > $(srcdir)/COPYRIGHT.new && mv $(srcdir)/COPYRIGHT.new $(srcdir)/COPYRIGHT + { echo "This file is automatically generated from html/copyright.html" ; \ + lynx -dump $(srcdir)/html/copyright.html ;} > COPYRIGHT.new \ + && mv -f COPYRIGHT.new $(srcdir)/COPYRIGHT + +COPYRIGHT-please: $(srcdir)/COPYRIGHT + @: do-nothing action to prevent default \ + This target is needed by sntp/Makefile.am on decrepit \ + FreeBSD 6.x make which fails with "make COPYRIGHT" \ + configured in $(srcdir) but "make ./COPYRIGHT" succeeds. \ + Rather than determine our $(srcdir) from sntp/Makefile.am \ + COPYRIGHT-please serves as a fixed target. # HMS: The next bit is still suboptimal. If bk is present but this NTP # repo is not a bk repo, we'll get an error message from the prs command. @@ -109,7 +130,7 @@ $(srcdir)/version: FRC.version -(bk version) >/dev/null 2>&1 && \ cd $(srcdir) && \ - x=`bk -R prs -hr+ -nd:I: ChangeSet` && \ + x=`bk -R prs -hr+ -nd:I: ChangeSet` && \ y=`cat version 2>/dev/null` || true && \ case "$$x" in ''|$$y) ;; *) echo $$x > version ;; esac @@ -121,12 +142,16 @@ cd $(srcdir) && \ ./scripts/genver include/version.def +$(srcdir)/include/version.texi: $(srcdir)/packageinfo.sh + cd $(srcdir) && \ + ./scripts/genver include/version.texi + +libtool: $(LIBTOOL_DEPS) + ./config.status --recheck + dist-hook: - @find $(distdir) -type d -name CVS -print | xargs rm -rf @find $(distdir) -type d -name SCCS -print | xargs rm -rf @chmod u+w $(distdir)/ports/winnt - @for i in `find $(distdir)/ports/winnt -type f -name '*.ds*' -print`; \ - do chmod u+w $$i ; unix2dos $$i $$i; done .gcc-warning: @echo "Compiling with GCC now generates lots of new warnings." @@ -172,6 +197,7 @@ fi FRC.CommitLog FRC.distwarn FRC.checkcvo FRC.checkhost FRC.version: + @: do-nothing action prevents any default # HMS: what was I trying to do with this? #dot.emacs: FRC.distwarn diff -urN src/contrib/ntp/Makefile.in src.ntp/contrib/ntp/Makefile.in --- src/contrib/ntp/Makefile.in 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/Makefile.in 2010-07-09 04:21:36.000000000 +0200 @@ -38,11 +38,16 @@ DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \ $(srcdir)/Makefile.in $(srcdir)/config.h.in \ $(top_srcdir)/configure ChangeLog INSTALL NEWS TODO compile \ - config.guess config.sub depcomp install-sh ltmain.sh missing + config.guess config.sub depcomp install-sh ltmain.sh missing \ + ylwrap ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ + $(top_srcdir)/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/m4/ntp_openssl.m4 \ + $(top_srcdir)/m4/ntp_vpathhack.m4 \ $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ @@ -108,7 +113,6 @@ ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -129,6 +133,7 @@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EF_LIBS = @EF_LIBS@ EF_PROGS = @EF_PROGS@ EGREP = @EGREP@ @@ -160,6 +165,7 @@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ @@ -176,18 +182,22 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ PATH_SEPARATOR = @PATH_SEPARATOR@ PATH_SH = @PATH_SH@ PROPDELAY = @PROPDELAY@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ VERSION = @VERSION@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ @@ -239,19 +249,16 @@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ - -#AUTOMAKE_OPTIONS = util/ansi2knr foreign dist-tarZ no-dependencies -AUTOMAKE_OPTIONS = util/ansi2knr foreign 1.8 +AUTOMAKE_OPTIONS = foreign 1.10 ACLOCAL_AMFLAGS = -I m4 -I libopts/m4 NULL = -SUBDIRS = $(am__append_1) scripts include ElectricFence @ARLIB_DIR@ \ - libntp libparse ntpd ntpdate ntpdc ntpq parseutil adjtimed \ +SUBDIRS = scripts include ElectricFence $(NULL) $(am__append_1) libntp \ + libparse ntpd ntpdate ntpdc ntpq ntpsnmpd parseutil adjtimed \ clockstuff kernel sntp util $(NULL) DIST_SUBDIRS = \ scripts \ include \ ElectricFence \ - arlib \ libntp \ libopts \ libparse \ @@ -259,6 +266,7 @@ ntpdate \ ntpdc \ ntpq \ + ntpsnmpd \ parseutil \ adjtimed \ clockstuff \ @@ -267,55 +275,65 @@ util \ $(NULL) -DISTCHECK_CONFIGURE_FLAGS = --with-arlib --enable-local-libopts +DISTCHECK_CONFIGURE_FLAGS = -C EXTRA_DIST = \ - COPYRIGHT \ - ChangeLog \ - CommitLog \ - CommitLog-4.1.0 \ - NEWS \ - NOTES.y2kfixes \ - README.bk \ - README.hackers \ - README.patches \ - README.refclocks \ - README.versions \ - TODO \ - WHERE-TO-START \ - bootstrap \ - build \ - config.guess \ - config.h.in \ - config.sub \ - dot.emacs \ - excludes \ - flock-build \ - install-sh \ - packageinfo.sh \ - readme.y2kfixes \ + $(srcdir)/COPYRIGHT \ + ChangeLog \ + CommitLog \ + CommitLog-4.1.0 \ + NEWS \ + NOTES.y2kfixes \ + README.bk \ + README.hackers \ + README.patches \ + README.refclocks \ + README.versions \ + TODO \ + WHERE-TO-START \ + bootstrap \ + build \ + config.guess \ + config.h.in \ + config.sub \ + dot.emacs \ + excludes \ + flock-build \ + install-sh \ + packageinfo.sh \ + readme.y2kfixes \ results.y2kfixes \ \ - conf \ - html \ - libisc \ - ports \ + conf \ + html \ + lib/isc \ + ports \ \ - bincheck.mf \ - version \ - version.m4 \ + bincheck.mf \ + depsver.mf \ + deps-ver \ + $(srcdir)/version \ + version.m4 \ \ $(NULL) +CLEANFILES = DISTCLEANFILES = .gcc-warning - -#ETAGS_ARGS = $(srcdir)/Makefile.am $(srcdir)/configure.ac ETAGS_ARGS = Makefile.am configure.ac # HMS: make ports be the last directory... # DIST_HOOK_DIRS = conf html scripts ports # HMS: Keep .gcc-warning first, as that way it gets printed first. -BUILT_SOURCES = .gcc-warning $(srcdir)/COPYRIGHT $(srcdir)/version $(srcdir)/version.m4 $(srcdir)/include/version.def +BUILT_SOURCES = \ + .gcc-warning \ + libtool \ + $(srcdir)/COPYRIGHT \ + $(srcdir)/version \ + $(srcdir)/version.m4 \ + $(srcdir)/include/version.def \ + $(srcdir)/include/version.texi \ + $(NULL) + # HMS: The following seems to be a work-in-progress... CVO = `$(srcdir)/config.guess` @@ -721,6 +739,7 @@ mostlyclean-generic: clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) @@ -823,7 +842,17 @@ $(srcdir)/COPYRIGHT: $(srcdir)/html/copyright.html - ( echo "This file is automatically generated from html/copyright.html" ; lynx -dump $(srcdir)/html/copyright.html ) > $(srcdir)/COPYRIGHT.new && mv $(srcdir)/COPYRIGHT.new $(srcdir)/COPYRIGHT + { echo "This file is automatically generated from html/copyright.html" ; \ + lynx -dump $(srcdir)/html/copyright.html ;} > COPYRIGHT.new \ + && mv -f COPYRIGHT.new $(srcdir)/COPYRIGHT + +COPYRIGHT-please: $(srcdir)/COPYRIGHT + @: do-nothing action to prevent default \ + This target is needed by sntp/Makefile.am on decrepit \ + FreeBSD 6.x make which fails with "make COPYRIGHT" \ + configured in $(srcdir) but "make ./COPYRIGHT" succeeds. \ + Rather than determine our $(srcdir) from sntp/Makefile.am \ + COPYRIGHT-please serves as a fixed target. # HMS: The next bit is still suboptimal. If bk is present but this NTP # repo is not a bk repo, we'll get an error message from the prs command. @@ -833,7 +862,7 @@ $(srcdir)/version: FRC.version -(bk version) >/dev/null 2>&1 && \ cd $(srcdir) && \ - x=`bk -R prs -hr+ -nd:I: ChangeSet` && \ + x=`bk -R prs -hr+ -nd:I: ChangeSet` && \ y=`cat version 2>/dev/null` || true && \ case "$$x" in ''|$$y) ;; *) echo $$x > version ;; esac @@ -845,12 +874,16 @@ cd $(srcdir) && \ ./scripts/genver include/version.def +$(srcdir)/include/version.texi: $(srcdir)/packageinfo.sh + cd $(srcdir) && \ + ./scripts/genver include/version.texi + +libtool: $(LIBTOOL_DEPS) + ./config.status --recheck + dist-hook: - @find $(distdir) -type d -name CVS -print | xargs rm -rf @find $(distdir) -type d -name SCCS -print | xargs rm -rf @chmod u+w $(distdir)/ports/winnt - @for i in `find $(distdir)/ports/winnt -type f -name '*.ds*' -print`; \ - do chmod u+w $$i ; unix2dos $$i $$i; done .gcc-warning: @echo "Compiling with GCC now generates lots of new warnings." @@ -890,6 +923,7 @@ fi FRC.CommitLog FRC.distwarn FRC.checkcvo FRC.checkhost FRC.version: + @: do-nothing action prevents any default # HMS: what was I trying to do with this? #dot.emacs: FRC.distwarn diff -urN src/contrib/ntp/NEWS src.ntp/contrib/ntp/NEWS --- src/contrib/ntp/NEWS 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/NEWS 2010-07-09 04:17:22.000000000 +0200 @@ -1,3 +1,56 @@ +NTP 4.2.6p2 (Harlan Stenn , 2010/07/08) + +Focus: Bug fixes and portability improvements + +Severity: Medium + +This is a recommended upgrade. + +This release includes build infrastructure updates, code +clean-ups, minor bug fixes, fixes for a number of minor +ref-clock issues, improved KOD handling, OpenSSL related +updates and documentation revisions. + +Portability improvements in this release affect Irix, Linux, +Mac OS, Microsoft Windows, OpenBSD and QNX6 + +New features / changes in this release: + +ntpd +* Range syntax for the trustedkey configuration directive +* Unified IPv4 and IPv6 restrict lists + +ntpdate +* Rate limiting and KOD handling + +ntpsnmpd +* default connection to net-snmpd via a unix-domain socket +* command-line 'socket name' option + +ntpq / ntpdc +* support for the "passwd ..." syntax +* key-type specific password prompts + +sntp +* MD5 authentication of an ntpd +* Broadcast and crypto +* OpenSSL support + +--- +NTP 4.2.6p1 (Harlan Stenn , 2010/04/09) + +Focus: Bug fixes, portability fixes, and documentation improvements + +Severity: Medium + +This is a recommended upgrade. + +--- +NTP 4.2.6 (Harlan Stenn , 2009/12/08) + +Focus: enhancements and bug fixes. + +--- NTP 4.2.4p8 (Harlan Stenn , 2009/12/08) Focus: Security Fixes @@ -32,6 +85,14 @@ THIS IS A STRONGLY RECOMMENDED UPGRADE. --- +ntpd now syncs to refclocks right away. + +Backward-Incomatible changes: + +ntpd no longer accepts '-v name' or '-V name' to define internal variables. +Use '--var name' or '--dvar name' instead. (Bug 817) + +--- NTP 4.2.4p7 (Harlan Stenn , 2009/05/04) Focus: Security and Bug Fixes diff -urN src/contrib/ntp/README.hackers src.ntp/contrib/ntp/README.hackers --- src/contrib/ntp/README.hackers 2004-07-20 17:00:59.000000000 +0200 +++ src.ntp/contrib/ntp/README.hackers 2009-12-09 08:36:35.000000000 +0100 @@ -9,19 +9,6 @@ --- -NTP4 uses ANSI C. Some folks are blessed with a pre-ansi C compiler. We -support them by using "ansi2knr" in the Makefiles, which is automatically -detected and selected by the configure process. - -For ansi2knr to work, we MUST define functions as follows: - -type stuff -function_name ( actual parameters ) - -While the whitespace is optional, the function name MUST start at column 0. - ---- - We'd like to see *all* system function declarations live in include/l_stdlib.h and NEVER appear in the .c files. diff -urN src/contrib/ntp/WHERE-TO-START src.ntp/contrib/ntp/WHERE-TO-START --- src/contrib/ntp/WHERE-TO-START 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/WHERE-TO-START 2009-12-09 08:36:36.000000000 +0100 @@ -15,7 +15,7 @@ This distribution is normally available by anonymous ftp as the compressed tar archive ntp-.tar.gz in the pub/ntp directory on huey.udel.edu and is the version number. The current stable -and development version numbers can be found at . +and development version numbers can be found at . A considerable amount of documentation, including build instructions, configuration advice, program usage and miscellaneous information is diff -urN src/contrib/ntp/aclocal.m4 src.ntp/contrib/ntp/aclocal.m4 --- src/contrib/ntp/aclocal.m4 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/aclocal.m4 2010-07-09 04:21:23.000000000 +0200 @@ -6952,32 +6952,6 @@ AC_DEFUN([_AM_IF_OPTION], [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) -# Copyright (C) 1996, 1997, 1998, 2000, 2001, 2002, 2003, 2005, 2006 -# Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# serial 5 - -AC_DEFUN([AM_C_PROTOTYPES], -[AC_REQUIRE([AC_C_PROTOTYPES]) -if test "$ac_cv_prog_cc_stdc" != no; then - U= ANSI2KNR= -else - U=_ ANSI2KNR=./ansi2knr -fi -# Ensure some checks needed by ansi2knr itself. -AC_REQUIRE([AC_HEADER_STDC]) -AC_CHECK_HEADERS([string.h]) -AC_SUBST([U])dnl -AC_SUBST([ANSI2KNR])dnl -_AM_SUBST_NOTMAKE([ANSI2KNR])dnl -]) - -AU_DEFUN([fp_C_PROTOTYPES], [AM_C_PROTOTYPES]) - # Check to make sure that the build environment is sane. -*- Autoconf -*- # Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008 @@ -7188,5 +7162,9 @@ m4_include([libopts/m4/libopts.m4]) m4_include([m4/define_dir.m4]) -m4_include([m4/hs_ulong_const.m4]) +m4_include([m4/ntp_cacheversion.m4]) +m4_include([m4/ntp_dir_sep.m4]) +m4_include([m4/ntp_lineeditlibs.m4]) +m4_include([m4/ntp_openssl.m4]) +m4_include([m4/ntp_vpathhack.m4]) m4_include([m4/os_cflags.m4]) diff -urN src/contrib/ntp/adjtimed/Makefile.am src.ntp/contrib/ntp/adjtimed/Makefile.am --- src/contrib/ntp/adjtimed/Makefile.am 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/adjtimed/Makefile.am 2009-12-22 11:01:35.000000000 +0100 @@ -1,10 +1,17 @@ -AUTOMAKE_OPTIONS= ../util/ansi2knr +AUTOMAKE_OPTIONS= -bindir= ${exec_prefix}/${BINSUBDIR} +if NTP_BINSUBDIR_IS_BIN bin_PROGRAMS= @MAKE_ADJTIMED@ +else +sbin_PROGRAMS= @MAKE_ADJTIMED@ +endif + +BUILT_SOURCES= +CLEANFILES= EXTRA_PROGRAMS= adjtimed AM_CPPFLAGS= -I$(top_srcdir)/include LDADD= ../libntp/libntp.a ETAGS_ARGS= Makefile.am -include ../bincheck.mf +include $(top_srcdir)/bincheck.mf +include $(top_srcdir)/depsver.mf diff -urN src/contrib/ntp/adjtimed/Makefile.in src.ntp/contrib/ntp/adjtimed/Makefile.in --- src/contrib/ntp/adjtimed/Makefile.in 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/adjtimed/Makefile.in 2010-07-09 04:21:31.000000000 +0200 @@ -38,15 +38,18 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -ANSI2KNR = ../util/ansi2knr EXTRA_PROGRAMS = adjtimed$(EXEEXT) -DIST_COMMON = README $(srcdir)/../bincheck.mf $(srcdir)/Makefile.am \ - $(srcdir)/Makefile.in +DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ + $(top_srcdir)/bincheck.mf $(top_srcdir)/depsver.mf subdir = adjtimed ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ + $(top_srcdir)/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/m4/ntp_openssl.m4 \ + $(top_srcdir)/m4/ntp_vpathhack.m4 \ $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ @@ -55,10 +58,10 @@ CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = -am__installdirs = "$(DESTDIR)$(bindir)" -PROGRAMS = $(bin_PROGRAMS) +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(sbindir)" +PROGRAMS = $(bin_PROGRAMS) $(sbin_PROGRAMS) adjtimed_SOURCES = adjtimed.c -adjtimed_OBJECTS = adjtimed$U.$(OBJEXT) +adjtimed_OBJECTS = adjtimed.$(OBJEXT) adjtimed_LDADD = $(LDADD) adjtimed_DEPENDENCIES = ../libntp/libntp.a DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) @@ -82,7 +85,6 @@ ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -103,6 +105,7 @@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EF_LIBS = @EF_LIBS@ EF_PROGS = @EF_PROGS@ EGREP = @EGREP@ @@ -134,6 +137,7 @@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ @@ -150,18 +154,22 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ PATH_SEPARATOR = @PATH_SEPARATOR@ PATH_SH = @PATH_SH@ PROPDELAY = @PROPDELAY@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ VERSION = @VERSION@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ @@ -172,7 +180,7 @@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ -bindir = ${exec_prefix}/${BINSUBDIR} +bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ @@ -213,16 +221,20 @@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -AUTOMAKE_OPTIONS = ../util/ansi2knr -bin_PROGRAMS = @MAKE_ADJTIMED@ +AUTOMAKE_OPTIONS = +@NTP_BINSUBDIR_IS_BIN_TRUE@bin_PROGRAMS = @MAKE_ADJTIMED@ +@NTP_BINSUBDIR_IS_BIN_FALSE@sbin_PROGRAMS = @MAKE_ADJTIMED@ +BUILT_SOURCES = .deps-ver +CLEANFILES = .deps-ver AM_CPPFLAGS = -I$(top_srcdir)/include LDADD = ../libntp/libntp.a ETAGS_ARGS = Makefile.am -all: all-am +all: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(srcdir)/../bincheck.mf $(am__configure_deps) +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/bincheck.mf $(top_srcdir)/depsver.mf $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -295,6 +307,49 @@ list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ echo " rm -f" $$list; \ rm -f $$list +install-sbinPROGRAMS: $(sbin_PROGRAMS) + @$(NORMAL_INSTALL) + test -z "$(sbindir)" || $(MKDIR_P) "$(DESTDIR)$(sbindir)" + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p || test -f $$p1; \ + then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-sbinPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(sbindir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(sbindir)" && rm -f $$files + +clean-sbinPROGRAMS: + @list='$(sbin_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list adjtimed$(EXEEXT): $(adjtimed_OBJECTS) $(adjtimed_DEPENDENCIES) @rm -f adjtimed$(EXEEXT) $(LINK) $(adjtimed_OBJECTS) $(adjtimed_LDADD) $(LIBS) @@ -304,13 +359,8 @@ distclean-compile: -rm -f *.tab.c -../util/ansi2knr: - $(am__cd) ../util && $(MAKE) $(AM_MAKEFLAGS) ./ansi2knr - -mostlyclean-kr: - -test "$U" = "" || rm -f *_.c -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/adjtimed$U.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/adjtimed.Po@am__quote@ .c.o: @am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @@ -332,9 +382,6 @@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< -adjtimed_.c: adjtimed.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/adjtimed.c; then echo $(srcdir)/adjtimed.c; else echo adjtimed.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -adjtimed_.$(OBJEXT) adjtimed_.lo : $(ANSI2KNR) mostlyclean-libtool: -rm -f *.lo @@ -425,13 +472,15 @@ fi; \ done check-am: all-am -check: check-am +check: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) check-am all-am: Makefile $(PROGRAMS) installdirs: - for dir in "$(DESTDIR)$(bindir)"; do \ + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(sbindir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done -install: install-am +install: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am @@ -448,6 +497,7 @@ mostlyclean-generic: clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) @@ -456,9 +506,11 @@ maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." + -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-am -clean-am: clean-binPROGRAMS clean-generic clean-libtool mostlyclean-am +clean-am: clean-binPROGRAMS clean-generic clean-libtool \ + clean-sbinPROGRAMS mostlyclean-am distclean: distclean-am -rm -rf ./$(DEPDIR) @@ -484,7 +536,7 @@ install-dvi-am: -install-exec-am: install-binPROGRAMS +install-exec-am: install-binPROGRAMS install-sbinPROGRAMS @$(NORMAL_INSTALL) $(MAKE) $(AM_MAKEFLAGS) install-exec-hook install-html: install-html-am @@ -514,7 +566,7 @@ mostlyclean: mostlyclean-am -mostlyclean-am: mostlyclean-compile mostlyclean-generic mostlyclean-kr \ +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am @@ -525,36 +577,101 @@ ps-am: -uninstall-am: uninstall-binPROGRAMS +uninstall-am: uninstall-binPROGRAMS uninstall-sbinPROGRAMS -.MAKE: ../util/ansi2knr install-am install-exec-am install-strip +.MAKE: all check install install-am install-exec-am install-strip .PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \ - clean-generic clean-libtool ctags distclean distclean-compile \ - distclean-generic distclean-libtool distclean-tags distdir dvi \ - dvi-am html html-am info info-am install install-am \ - install-binPROGRAMS install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-exec-hook \ - install-html install-html-am install-info install-info-am \ - install-man install-pdf install-pdf-am install-ps \ - install-ps-am install-strip installcheck installcheck-am \ - installdirs maintainer-clean maintainer-clean-generic \ - mostlyclean mostlyclean-compile mostlyclean-generic \ - mostlyclean-kr mostlyclean-libtool pdf pdf-am ps ps-am tags \ - uninstall uninstall-am uninstall-binPROGRAMS + clean-generic clean-libtool clean-sbinPROGRAMS ctags distclean \ + distclean-compile distclean-generic distclean-libtool \ + distclean-tags distdir dvi dvi-am html html-am info info-am \ + install install-am install-binPROGRAMS install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-exec-hook install-html install-html-am \ + install-info install-info-am install-man install-pdf \ + install-pdf-am install-ps install-ps-am install-sbinPROGRAMS \ + install-strip installcheck installcheck-am installdirs \ + maintainer-clean maintainer-clean-generic mostlyclean \ + mostlyclean-compile mostlyclean-generic mostlyclean-libtool \ + pdf pdf-am ps ps-am tags uninstall uninstall-am \ + uninstall-binPROGRAMS uninstall-sbinPROGRAMS install-exec-hook: - @case ${BINSUBDIR} in \ - bin) ODIR=${exec_prefix}/sbin ;; \ - sbin) ODIR=${exec_prefix}/bin ;; \ - esac; \ - test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ + @case ${BINSUBDIR} in \ + bin) ODIR=${sbindir} ;; \ + sbin) ODIR=${bindir} ;; \ + esac; \ + test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ test ! -f $$ODIR/$$i || echo "*** $$i is also in $$ODIR!"; \ done # +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + ..) \ + cd .. && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + *) \ + echo 'Fatal: depsver.mf Automake fragment limited' \ + 'to immediate subdirectories.' && \ + echo "top_builddir: $(top_builddir)" && \ + echo "subdir: $(subdir)" && \ + exit 1 \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff -urN src/contrib/ntp/arlib/COPYING src.ntp/contrib/ntp/arlib/COPYING --- src/contrib/ntp/arlib/COPYING 2004-07-20 17:01:23.000000000 +0200 +++ src.ntp/contrib/ntp/arlib/COPYING 1970-01-01 01:00:00.000000000 +0100 @@ -1,46 +0,0 @@ -Replied: Fri, 16 Feb 2001 14:12:54 -0500 -Replied: "Darren Reed " -Received: from [139.134.6.79] by whimsy.udel.edu id aa15476; - 16 Feb 2001 04:21 EST -Received: from CPE-61-9-164-106.vic.bigpond.net.au - ([139.134.4.52]) by mailin6.bigpond.com (Netscape Messaging - Server 4.15) with SMTP id G8UFIB00.4QI for - ; Fri, 16 Feb 2001 19:25:23 +1000 -Received: from CPE-61-9-164-110.vic.bigpond.net.au ([61.9.164.110]) by mail5.bigpond.com (Claudes-Retiring-MailRouter V2.9c 9/11963672); 16 Feb 2001 19:20:45 -Received: (from root@localhost) - by CPE-61-9-164-106.vic.bigpond.net.au (8.11.0/8.11.0) id f1G92GC29158 - for ; Fri, 16 Feb 2001 20:02:16 +1100 -From: Darren Reed -Message-Id: <200102160901.UAA23657@avalon.reed.wattle.id.au> -Subject: Re: arlib? -In-Reply-To: <901.982219274@whimsy.udel.edu> from Harlan Stenn at "Feb 15, 1 01:41:14 am" -To: Harlan Stenn -Date: Fri, 16 Feb 2001 20:01:46 +1100 -X-Mailer: ELM [version 2.4ME+ PL37 (25)] -MIME-Version: 1.0 -Content-Type: text/plain; charset=US-ASCII -Content-Transfer-Encoding: 7bit - -In some email I received from Harlan Stenn, sie wrote: -> Darren, -> -> I'm looking for an async resolver library that I can use with NTP. -> -> I noticed your code in the contrib/ subdir of later bind8 distribution -> and I noticed the Copyright notice in arlib.c: -> -> * arlib.c (C)opyright 1993 Darren Reed. All rights reserved. -> * This file may not be distributed without the author's permission in any -> * shape or form. The author takes no responsibility for any damage or loss -> * of property which results from the use of this software. -> -> so I thought I'd ask your permission to distribute your files if I can -> figure out how to make it all work with ntpd. - -http://coombs.anu.edu.au/~avalon/arlib.tar.gz - -a few bug fixes (inc. buffer overflow :) and stuff in there. - -But otherwise, go for it. - -Darren diff -urN src/contrib/ntp/arlib/INSTALL src.ntp/contrib/ntp/arlib/INSTALL --- src/contrib/ntp/arlib/INSTALL 2004-07-20 17:01:24.000000000 +0200 +++ src.ntp/contrib/ntp/arlib/INSTALL 1970-01-01 01:00:00.000000000 +0100 @@ -1,182 +0,0 @@ -Basic Installation -================== - - These are generic installation instructions. - - The `configure' shell script attempts to guess correct values for -various system-dependent variables used during compilation. It uses -those values to create a `Makefile' in each directory of the package. -It may also create one or more `.h' files containing system-dependent -definitions. Finally, it creates a shell script `config.status' that -you can run in the future to recreate the current configuration, a file -`config.cache' that saves the results of its tests to speed up -reconfiguring, and a file `config.log' containing compiler output -(useful mainly for debugging `configure'). - - If you need to do unusual things to compile the package, please try -to figure out how `configure' could check whether to do them, and mail -diffs or instructions to the address given in the `README' so they can -be considered for the next release. If at some point `config.cache' -contains results you don't want to keep, you may remove or edit it. - - The file `configure.in' is used to create `configure' by a program -called `autoconf'. You only need `configure.in' if you want to change -it or regenerate `configure' using a newer version of `autoconf'. - -The simplest way to compile this package is: - - 1. `cd' to the directory containing the package's source code and type - `./configure' to configure the package for your system. If you're - using `csh' on an old version of System V, you might need to type - `sh ./configure' instead to prevent `csh' from trying to execute - `configure' itself. - - Running `configure' takes awhile. While running, it prints some - messages telling which features it is checking for. - - 2. Type `make' to compile the package. - - 3. Optionally, type `make check' to run any self-tests that come with - the package. - - 4. Type `make install' to install the programs and any data files and - documentation. - - 5. You can remove the program binaries and object files from the - source code directory by typing `make clean'. To also remove the - files that `configure' created (so you can compile the package for - a different kind of computer), type `make distclean'. There is - also a `make maintainer-clean' target, but that is intended mainly - for the package's developers. If you use it, you may have to get - all sorts of other programs in order to regenerate files that came - with the distribution. - -Compilers and Options -===================== - - Some systems require unusual options for compilation or linking that -the `configure' script does not know about. You can give `configure' -initial values for variables by setting them in the environment. Using -a Bourne-compatible shell, you can do that on the command line like -this: - CC=c89 CFLAGS=-O2 LIBS=-lposix ./configure - -Or on systems that have the `env' program, you can do it like this: - env CPPFLAGS=-I/usr/local/include LDFLAGS=-s ./configure - -Compiling For Multiple Architectures -==================================== - - You can compile the package for more than one kind of computer at the -same time, by placing the object files for each architecture in their -own directory. To do this, you must use a version of `make' that -supports the `VPATH' variable, such as GNU `make'. `cd' to the -directory where you want the object files and executables to go and run -the `configure' script. `configure' automatically checks for the -source code in the directory that `configure' is in and in `..'. - - If you have to use a `make' that does not supports the `VPATH' -variable, you have to compile the package for one architecture at a time -in the source code directory. After you have installed the package for -one architecture, use `make distclean' before reconfiguring for another -architecture. - -Installation Names -================== - - By default, `make install' will install the package's files in -`/usr/local/bin', `/usr/local/man', etc. You can specify an -installation prefix other than `/usr/local' by giving `configure' the -option `--prefix=PATH'. - - You can specify separate installation prefixes for -architecture-specific files and architecture-independent files. If you -give `configure' the option `--exec-prefix=PATH', the package will use -PATH as the prefix for installing programs and libraries. -Documentation and other data files will still use the regular prefix. - - In addition, if you use an unusual directory layout you can give -options like `--bindir=PATH' to specify different values for particular -kinds of files. Run `configure --help' for a list of the directories -you can set and what kinds of files go in them. - - If the package supports it, you can cause programs to be installed -with an extra prefix or suffix on their names by giving `configure' the -option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'. - -Optional Features -================= - - Some packages pay attention to `--enable-FEATURE' options to -`configure', where FEATURE indicates an optional part of the package. -They may also pay attention to `--with-PACKAGE' options, where PACKAGE -is something like `gnu-as' or `x' (for the X Window System). The -`README' should mention any `--enable-' and `--with-' options that the -package recognizes. - - For packages that use the X Window System, `configure' can usually -find the X include and library files automatically, but if it doesn't, -you can use the `configure' options `--x-includes=DIR' and -`--x-libraries=DIR' to specify their locations. - -Specifying the System Type -========================== - - There may be some features `configure' can not figure out -automatically, but needs to determine by the type of host the package -will run on. Usually `configure' can figure that out, but if it prints -a message saying it can not guess the host type, give it the -`--host=TYPE' option. TYPE can either be a short name for the system -type, such as `sun4', or a canonical name with three fields: - CPU-COMPANY-SYSTEM - -See the file `config.sub' for the possible values of each field. If -`config.sub' isn't included in this package, then this package doesn't -need to know the host type. - - If you are building compiler tools for cross-compiling, you can also -use the `--target=TYPE' option to select the type of system they will -produce code for and the `--build=TYPE' option to select the type of -system on which you are compiling the package. - -Sharing Defaults -================ - - If you want to set default values for `configure' scripts to share, -you can create a site shell script called `config.site' that gives -default values for variables like `CC', `cache_file', and `prefix'. -`configure' looks for `PREFIX/share/config.site' if it exists, then -`PREFIX/etc/config.site' if it exists. Or, you can set the -`CONFIG_SITE' environment variable to the location of the site script. -A warning: not all `configure' scripts look for a site script. - -Operation Controls -================== - - `configure' recognizes the following options to control how it -operates. - -`--cache-file=FILE' - Use and save the results of the tests in FILE instead of - `./config.cache'. Set FILE to `/dev/null' to disable caching, for - debugging `configure'. - -`--help' - Print a summary of the options to `configure', and exit. - -`--quiet' -`--silent' -`-q' - Do not print messages saying which checks are being made. To - suppress all normal output, redirect it to `/dev/null' (any error - messages will still be shown). - -`--srcdir=DIR' - Look for the package's source code in directory DIR. Usually - `configure' can determine that directory automatically. - -`--version' - Print the version of Autoconf used to generate the `configure' - script, and exit. - -`configure' also accepts some other, not widely useful, options. diff -urN src/contrib/ntp/arlib/Makefile.am src.ntp/contrib/ntp/arlib/Makefile.am --- src/contrib/ntp/arlib/Makefile.am 2004-07-20 17:01:24.000000000 +0200 +++ src.ntp/contrib/ntp/arlib/Makefile.am 1970-01-01 01:00:00.000000000 +0100 @@ -1,15 +0,0 @@ -AUTOMAKE_OPTIONS = foreign # ansi2knr - -#lib_LIBRARIES = libares.a -noinst_LIBRARIES = libares.a -libares_a_SOURCES = arlib.c arplib.h -#include_HEADERS = arlib.h -noinst_HEADERS = arlib.h - -noinst_PROGRAMS = example -example_SOURCES = sample.c -example_LDADD = libares.a -#man_MANS = arlib.3 -#EXTRA_DIST = $(man_MANS) UNSHAR.HDR -noinst_MANS = arlib.3 -EXTRA_DIST = $(noinst_MANS) UNSHAR.HDR diff -urN src/contrib/ntp/arlib/Makefile.in src.ntp/contrib/ntp/arlib/Makefile.in --- src/contrib/ntp/arlib/Makefile.in 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/arlib/Makefile.in 1970-01-01 01:00:00.000000000 +0100 @@ -1,580 +0,0 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - - - -VPATH = @srcdir@ -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -noinst_PROGRAMS = example$(EXEEXT) -subdir = . -DIST_COMMON = README $(am__configure_deps) $(noinst_HEADERS) \ - $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ - $(top_srcdir)/configure COPYING INSTALL depcomp install-sh \ - missing -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/configure.in -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ - configure.lineno config.status.lineno -mkinstalldirs = $(install_sh) -d -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -LIBRARIES = $(noinst_LIBRARIES) -AR = ar -ARFLAGS = cru -libares_a_AR = $(AR) $(ARFLAGS) -libares_a_LIBADD = -am_libares_a_OBJECTS = arlib.$(OBJEXT) -libares_a_OBJECTS = $(am_libares_a_OBJECTS) -PROGRAMS = $(noinst_PROGRAMS) -am_example_OBJECTS = sample.$(OBJEXT) -example_OBJECTS = $(am_example_OBJECTS) -example_DEPENDENCIES = libares.a -DEFAULT_INCLUDES = -I.@am__isrc@ -depcomp = $(SHELL) $(top_srcdir)/depcomp -am__depfiles_maybe = depfiles -am__mv = mv -f -COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ - $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -CCLD = $(CC) -LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ -SOURCES = $(libares_a_SOURCES) $(example_SOURCES) -DIST_SOURCES = $(libares_a_SOURCES) $(example_SOURCES) -HEADERS = $(noinst_HEADERS) -ETAGS = etags -CTAGS = ctags -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -distdir = $(PACKAGE)-$(VERSION) -top_distdir = $(distdir) -am__remove_distdir = \ - { test ! -d "$(distdir)" \ - || { find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \ - && rm -fr "$(distdir)"; }; } -DIST_ARCHIVES = $(distdir).tar.gz -GZIP_ENV = --best -distuninstallcheck_listfiles = find . -type f -print -distcleancheck_listfiles = find . -type f -print -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CPPFLAGS = @CPPFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EXEEXT = @EXEEXT@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LDFLAGS = @LDFLAGS@ -LIBOBJS = @LIBOBJS@ -LIBS = @LIBS@ -LTLIBOBJS = @LTLIBOBJS@ -MAKEINFO = @MAKEINFO@ -MKDIR_P = @MKDIR_P@ -OBJEXT = @OBJEXT@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -RANLIB = @RANLIB@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_CC = @ac_ct_CC@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build_alias = @build_alias@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host_alias = @host_alias@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pdfdir = @pdfdir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -AUTOMAKE_OPTIONS = foreign # ansi2knr - -#lib_LIBRARIES = libares.a -noinst_LIBRARIES = libares.a -libares_a_SOURCES = arlib.c arplib.h -#include_HEADERS = arlib.h -noinst_HEADERS = arlib.h -example_SOURCES = sample.c -example_LDADD = libares.a -#man_MANS = arlib.3 -#EXTRA_DIST = $(man_MANS) UNSHAR.HDR -noinst_MANS = arlib.3 -EXTRA_DIST = $(noinst_MANS) UNSHAR.HDR -all: all-am - -.SUFFIXES: -.SUFFIXES: .c .o .obj -am--refresh: - @: -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - echo ' cd $(srcdir) && $(AUTOMAKE) --foreign'; \ - $(am__cd) $(srcdir) && $(AUTOMAKE) --foreign \ - && exit 0; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign Makefile -.PRECIOUS: Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - echo ' $(SHELL) ./config.status'; \ - $(SHELL) ./config.status;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - $(SHELL) ./config.status --recheck - -$(top_srcdir)/configure: $(am__configure_deps) - $(am__cd) $(srcdir) && $(AUTOCONF) -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - $(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) -$(am__aclocal_m4_deps): - -clean-noinstLIBRARIES: - -test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES) -libares.a: $(libares_a_OBJECTS) $(libares_a_DEPENDENCIES) - -rm -f libares.a - $(libares_a_AR) libares.a $(libares_a_OBJECTS) $(libares_a_LIBADD) - $(RANLIB) libares.a - -clean-noinstPROGRAMS: - -test -z "$(noinst_PROGRAMS)" || rm -f $(noinst_PROGRAMS) -example$(EXEEXT): $(example_OBJECTS) $(example_DEPENDENCIES) - @rm -f example$(EXEEXT) - $(LINK) $(example_OBJECTS) $(example_LDADD) $(LIBS) - -mostlyclean-compile: - -rm -f *.$(OBJEXT) - -distclean-compile: - -rm -f *.tab.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/arlib.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sample.Po@am__quote@ - -.c.o: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c $< - -.c.obj: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` - -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - set x; \ - here=`pwd`; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - shift; \ - if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - if test $$# -gt 0; then \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - "$$@" $$unique; \ - else \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$unique; \ - fi; \ - fi -ctags: CTAGS -CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - test -z "$(CTAGS_ARGS)$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && $(am__cd) $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) "$$here" - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags - -distdir: $(DISTFILES) - $(am__remove_distdir) - test -d "$(distdir)" || mkdir "$(distdir)" - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done - -test -n "$(am__skip_mode_fix)" \ - || find "$(distdir)" -type d ! -perm -777 -exec chmod a+rwx {} \; -o \ - ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \ - ! -type d ! -perm -400 -exec chmod a+r {} \; -o \ - ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \ - || chmod -R a+r "$(distdir)" -dist-gzip: distdir - tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz - $(am__remove_distdir) - -dist-bzip2: distdir - tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2 - $(am__remove_distdir) - -dist-lzma: distdir - tardir=$(distdir) && $(am__tar) | lzma -9 -c >$(distdir).tar.lzma - $(am__remove_distdir) - -dist-xz: distdir - tardir=$(distdir) && $(am__tar) | xz -c >$(distdir).tar.xz - $(am__remove_distdir) - -dist-tarZ: distdir - tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z - $(am__remove_distdir) - -dist-shar: distdir - shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz - $(am__remove_distdir) - -dist-zip: distdir - -rm -f $(distdir).zip - zip -rq $(distdir).zip $(distdir) - $(am__remove_distdir) - -dist dist-all: distdir - tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz - $(am__remove_distdir) - -# This target untars the dist file and tries a VPATH configuration. Then -# it guarantees that the distribution is self-contained by making another -# tarfile. -distcheck: dist - case '$(DIST_ARCHIVES)' in \ - *.tar.gz*) \ - GZIP=$(GZIP_ENV) gunzip -c $(distdir).tar.gz | $(am__untar) ;;\ - *.tar.bz2*) \ - bunzip2 -c $(distdir).tar.bz2 | $(am__untar) ;;\ - *.tar.lzma*) \ - unlzma -c $(distdir).tar.lzma | $(am__untar) ;;\ - *.tar.xz*) \ - xz -dc $(distdir).tar.xz | $(am__untar) ;;\ - *.tar.Z*) \ - uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ - *.shar.gz*) \ - GZIP=$(GZIP_ENV) gunzip -c $(distdir).shar.gz | unshar ;;\ - *.zip*) \ - unzip $(distdir).zip ;;\ - esac - chmod -R a-w $(distdir); chmod a+w $(distdir) - mkdir $(distdir)/_build - mkdir $(distdir)/_inst - chmod a-w $(distdir) - test -d $(distdir)/_build || exit 0; \ - dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \ - && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \ - && am__cwd=`pwd` \ - && $(am__cd) $(distdir)/_build \ - && ../configure --srcdir=.. --prefix="$$dc_install_base" \ - $(DISTCHECK_CONFIGURE_FLAGS) \ - && $(MAKE) $(AM_MAKEFLAGS) \ - && $(MAKE) $(AM_MAKEFLAGS) dvi \ - && $(MAKE) $(AM_MAKEFLAGS) check \ - && $(MAKE) $(AM_MAKEFLAGS) install \ - && $(MAKE) $(AM_MAKEFLAGS) installcheck \ - && $(MAKE) $(AM_MAKEFLAGS) uninstall \ - && $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \ - distuninstallcheck \ - && chmod -R a-w "$$dc_install_base" \ - && ({ \ - (cd ../.. && umask 077 && mkdir "$$dc_destdir") \ - && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \ - && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \ - && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \ - distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \ - } || { rm -rf "$$dc_destdir"; exit 1; }) \ - && rm -rf "$$dc_destdir" \ - && $(MAKE) $(AM_MAKEFLAGS) dist \ - && rm -rf $(DIST_ARCHIVES) \ - && $(MAKE) $(AM_MAKEFLAGS) distcleancheck \ - && cd "$$am__cwd" \ - || exit 1 - $(am__remove_distdir) - @(echo "$(distdir) archives ready for distribution: "; \ - list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \ - sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x' -distuninstallcheck: - @$(am__cd) '$(distuninstallcheck_dir)' \ - && test `$(distuninstallcheck_listfiles) | wc -l` -le 1 \ - || { echo "ERROR: files left after uninstall:" ; \ - if test -n "$(DESTDIR)"; then \ - echo " (check DESTDIR support)"; \ - fi ; \ - $(distuninstallcheck_listfiles) ; \ - exit 1; } >&2 -distcleancheck: distclean - @if test '$(srcdir)' = . ; then \ - echo "ERROR: distcleancheck can only run from a VPATH build" ; \ - exit 1 ; \ - fi - @test `$(distcleancheck_listfiles) | wc -l` -eq 0 \ - || { echo "ERROR: files left in build directory after distclean:" ; \ - $(distcleancheck_listfiles) ; \ - exit 1; } >&2 -check-am: all-am -check: check-am -all-am: Makefile $(LIBRARIES) $(PROGRAMS) $(HEADERS) -installdirs: -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-am - -clean-am: clean-generic clean-noinstLIBRARIES clean-noinstPROGRAMS \ - mostlyclean-am - -distclean: distclean-am - -rm -f $(am__CONFIG_DISTCLEAN_FILES) - -rm -rf ./$(DEPDIR) - -rm -f Makefile -distclean-am: clean-am distclean-compile distclean-generic \ - distclean-tags - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: - -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -f $(am__CONFIG_DISTCLEAN_FILES) - -rm -rf $(top_srcdir)/autom4te.cache - -rm -rf ./$(DEPDIR) - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-compile mostlyclean-generic - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: - -.MAKE: install-am install-strip - -.PHONY: CTAGS GTAGS all all-am am--refresh check check-am clean \ - clean-generic clean-noinstLIBRARIES clean-noinstPROGRAMS ctags \ - dist dist-all dist-bzip2 dist-gzip dist-lzma dist-shar \ - dist-tarZ dist-xz dist-zip distcheck distclean \ - distclean-compile distclean-generic distclean-tags \ - distcleancheck distdir distuninstallcheck dvi dvi-am html \ - html-am info info-am install install-am install-data \ - install-data-am install-dvi install-dvi-am install-exec \ - install-exec-am install-html install-html-am install-info \ - install-info-am install-man install-pdf install-pdf-am \ - install-ps install-ps-am install-strip installcheck \ - installcheck-am installdirs maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-compile \ - mostlyclean-generic pdf pdf-am ps ps-am tags uninstall \ - uninstall-am - - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff -urN src/contrib/ntp/arlib/README src.ntp/contrib/ntp/arlib/README --- src/contrib/ntp/arlib/README 2004-07-20 17:01:22.000000000 +0200 +++ src.ntp/contrib/ntp/arlib/README 1970-01-01 01:00:00.000000000 +0100 @@ -1,49 +0,0 @@ - - Asynchronous DNS - ---------------- - - Intro. - -For those who write real time network applications that have to handle -multiple TCP or UDP connections, the problem of effectively doing DNS -lookups is quite real. Generally, this means the program waits while -the query finishes, holding everything else up. This small library of -routines aims to solve that problem by performing the DNS query and -then returning the program to its normal flow. - - Whats included ? - -The library routines, arlib.c, a header file for it, arlib.h, a man -page, arlib.3 and an example of how this sort of code is used, -sample.c. - - - Compilation & Installation. - -Edit the Makefile and do "make install" to install things where you -wish them to go. You should check it makes and works before doing -this :) - -If the compilation is successful, you'll have an executeable called -"example" and libares.a. "example" is a simple program which will -do hostname->IP# or IP#->hostnae lookups by entering either the -hostname or IP# on the line with "Host-->". You dont have to wait -for a query to fail or succeed before typing in the next line. - - Portability. - -I'm not sure how portable this is, it was written under SunOS 4.1.2 -on a Sparc 1+ and hasn't been tested very widely. If you find any -problems when compiling/execution, plase send me a patch (using -diff -c) to avalon@coombs.anu.edu.au. If it goes well enough, I'll -send it to comp.unix.sources or comp.sources.misc for further testing. - - Future additions. - -Adding a working cache would be nice but I'm not sure if that really -is needed (?). I guess it depends on how often your program is -required to do a DNS lookup and whether caching would help. - - -Cheers, -Darren. diff -urN src/contrib/ntp/arlib/UNSHAR.HDR src.ntp/contrib/ntp/arlib/UNSHAR.HDR --- src/contrib/ntp/arlib/UNSHAR.HDR 2004-07-20 17:01:25.000000000 +0200 +++ src.ntp/contrib/ntp/arlib/UNSHAR.HDR 1970-01-01 01:00:00.000000000 +0100 @@ -1,32 +0,0 @@ -Replied: Sun, 19 Dec 93 09:58:30 PST -Replied: "Darren Reed " -Return-Path: avalon@coombs.anu.edu.au -Received: by gw.home.vix.com id AA12017; Sun, 19 Dec 93 07:04:44 -0800 -Message-Id: <9312191504.AA12017@gw.home.vix.com> -Received: by coombs.anu.edu.au - (1.37.109.8/16.2) id AA10850; Mon, 20 Dec 1993 02:07:21 +1100 -From: Darren Reed -Subject: Addition for 4.9 "contrib" directory -To: paul@vix.com -Date: Mon, 20 Dec 1993 02:07:20 +1000 (EDT) -X-Mailer: ELM [version 2.4 PL21] -Mime-Version: 1.0 -Content-Type: text/plain; charset=US-ASCII -Content-Transfer-Encoding: 7bit -Content-Length: 67950 - - -Well, I just sent one letter off to dec.com, being from the 4.9 README I had. - -So, to sum up what I said, I've included below, some code I've written to -perform async. DNS lookups - `replacements' for gethostbyname and -gethostbyaddr. I've written and tested it mainly on a HP-UX machine, so -I'm not sure how it will port to others, but I've tried to keep the amount -of OS specific code to a minimum. - -The Makefile is setup to work best from "contrib/arlib", which is how I -checked to make sure it worked and ran well. There's a man page included -also. - -Cheers, -Darren diff -urN src/contrib/ntp/arlib/aclocal.m4 src.ntp/contrib/ntp/arlib/aclocal.m4 --- src/contrib/ntp/arlib/aclocal.m4 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/arlib/aclocal.m4 1970-01-01 01:00:00.000000000 +0100 @@ -1,951 +0,0 @@ -# generated automatically by aclocal 1.11 -*- Autoconf -*- - -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, -# 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc. -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -m4_ifndef([AC_AUTOCONF_VERSION], - [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl -m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.65],, -[m4_warning([this file was generated for autoconf 2.65. -You have another version of autoconf. It may work, but is not guaranteed to. -If you have problems, you may need to regenerate the build system entirely. -To do so, use the procedure documented by the package, typically `autoreconf'.])]) - -# Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# AM_AUTOMAKE_VERSION(VERSION) -# ---------------------------- -# Automake X.Y traces this macro to ensure aclocal.m4 has been -# generated from the m4 files accompanying Automake X.Y. -# (This private macro should not be called outside this file.) -AC_DEFUN([AM_AUTOMAKE_VERSION], -[am__api_version='1.11' -dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to -dnl require some minimum version. Point them to the right macro. -m4_if([$1], [1.11], [], - [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl -]) - -# _AM_AUTOCONF_VERSION(VERSION) -# ----------------------------- -# aclocal traces this macro to find the Autoconf version. -# This is a private macro too. Using m4_define simplifies -# the logic in aclocal, which can simply ignore this definition. -m4_define([_AM_AUTOCONF_VERSION], []) - -# AM_SET_CURRENT_AUTOMAKE_VERSION -# ------------------------------- -# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. -# This function is AC_REQUIREd by AM_INIT_AUTOMAKE. -AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], -[AM_AUTOMAKE_VERSION([1.11])dnl -m4_ifndef([AC_AUTOCONF_VERSION], - [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl -_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) - -# AM_AUX_DIR_EXPAND -*- Autoconf -*- - -# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets -# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to -# `$srcdir', `$srcdir/..', or `$srcdir/../..'. -# -# Of course, Automake must honor this variable whenever it calls a -# tool from the auxiliary directory. The problem is that $srcdir (and -# therefore $ac_aux_dir as well) can be either absolute or relative, -# depending on how configure is run. This is pretty annoying, since -# it makes $ac_aux_dir quite unusable in subdirectories: in the top -# source directory, any form will work fine, but in subdirectories a -# relative path needs to be adjusted first. -# -# $ac_aux_dir/missing -# fails when called from a subdirectory if $ac_aux_dir is relative -# $top_srcdir/$ac_aux_dir/missing -# fails if $ac_aux_dir is absolute, -# fails when called from a subdirectory in a VPATH build with -# a relative $ac_aux_dir -# -# The reason of the latter failure is that $top_srcdir and $ac_aux_dir -# are both prefixed by $srcdir. In an in-source build this is usually -# harmless because $srcdir is `.', but things will broke when you -# start a VPATH build or use an absolute $srcdir. -# -# So we could use something similar to $top_srcdir/$ac_aux_dir/missing, -# iff we strip the leading $srcdir from $ac_aux_dir. That would be: -# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` -# and then we would define $MISSING as -# MISSING="\${SHELL} $am_aux_dir/missing" -# This will work as long as MISSING is not called from configure, because -# unfortunately $(top_srcdir) has no meaning in configure. -# However there are other variables, like CC, which are often used in -# configure, and could therefore not use this "fixed" $ac_aux_dir. -# -# Another solution, used here, is to always expand $ac_aux_dir to an -# absolute PATH. The drawback is that using absolute paths prevent a -# configured tree to be moved without reconfiguration. - -AC_DEFUN([AM_AUX_DIR_EXPAND], -[dnl Rely on autoconf to set up CDPATH properly. -AC_PREREQ([2.50])dnl -# expand $ac_aux_dir to an absolute path -am_aux_dir=`cd $ac_aux_dir && pwd` -]) - -# AM_CONDITIONAL -*- Autoconf -*- - -# Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006, 2008 -# Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# serial 9 - -# AM_CONDITIONAL(NAME, SHELL-CONDITION) -# ------------------------------------- -# Define a conditional. -AC_DEFUN([AM_CONDITIONAL], -[AC_PREREQ(2.52)dnl - ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], - [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl -AC_SUBST([$1_TRUE])dnl -AC_SUBST([$1_FALSE])dnl -_AM_SUBST_NOTMAKE([$1_TRUE])dnl -_AM_SUBST_NOTMAKE([$1_FALSE])dnl -m4_define([_AM_COND_VALUE_$1], [$2])dnl -if $2; then - $1_TRUE= - $1_FALSE='#' -else - $1_TRUE='#' - $1_FALSE= -fi -AC_CONFIG_COMMANDS_PRE( -[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then - AC_MSG_ERROR([[conditional "$1" was never defined. -Usually this means the macro was only invoked conditionally.]]) -fi])]) - -# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009 -# Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# serial 10 - -# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be -# written in clear, in which case automake, when reading aclocal.m4, -# will think it sees a *use*, and therefore will trigger all it's -# C support machinery. Also note that it means that autoscan, seeing -# CC etc. in the Makefile, will ask for an AC_PROG_CC use... - - -# _AM_DEPENDENCIES(NAME) -# ---------------------- -# See how the compiler implements dependency checking. -# NAME is "CC", "CXX", "GCJ", or "OBJC". -# We try a few techniques and use that to set a single cache variable. -# -# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was -# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular -# dependency, and given that the user is not expected to run this macro, -# just rely on AC_PROG_CC. -AC_DEFUN([_AM_DEPENDENCIES], -[AC_REQUIRE([AM_SET_DEPDIR])dnl -AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl -AC_REQUIRE([AM_MAKE_INCLUDE])dnl -AC_REQUIRE([AM_DEP_TRACK])dnl - -ifelse([$1], CC, [depcc="$CC" am_compiler_list=], - [$1], CXX, [depcc="$CXX" am_compiler_list=], - [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'], - [$1], UPC, [depcc="$UPC" am_compiler_list=], - [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'], - [depcc="$$1" am_compiler_list=]) - -AC_CACHE_CHECK([dependency style of $depcc], - [am_cv_$1_dependencies_compiler_type], -[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then - # We make a subdir and do the tests there. Otherwise we can end up - # making bogus files that we don't know about and never remove. For - # instance it was reported that on HP-UX the gcc test will end up - # making a dummy file named `D' -- because `-MD' means `put the output - # in D'. - mkdir conftest.dir - # Copy depcomp to subdir because otherwise we won't find it if we're - # using a relative directory. - cp "$am_depcomp" conftest.dir - cd conftest.dir - # We will build objects and dependencies in a subdirectory because - # it helps to detect inapplicable dependency modes. For instance - # both Tru64's cc and ICC support -MD to output dependencies as a - # side effect of compilation, but ICC will put the dependencies in - # the current directory while Tru64 will put them in the object - # directory. - mkdir sub - - am_cv_$1_dependencies_compiler_type=none - if test "$am_compiler_list" = ""; then - am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` - fi - am__universal=false - m4_case([$1], [CC], - [case " $depcc " in #( - *\ -arch\ *\ -arch\ *) am__universal=true ;; - esac], - [CXX], - [case " $depcc " in #( - *\ -arch\ *\ -arch\ *) am__universal=true ;; - esac]) - - for depmode in $am_compiler_list; do - # Setup a source with many dependencies, because some compilers - # like to wrap large dependency lists on column 80 (with \), and - # we should not choose a depcomp mode which is confused by this. - # - # We need to recreate these files for each test, as the compiler may - # overwrite some of them when testing with obscure command lines. - # This happens at least with the AIX C compiler. - : > sub/conftest.c - for i in 1 2 3 4 5 6; do - echo '#include "conftst'$i'.h"' >> sub/conftest.c - # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with - # Solaris 8's {/usr,}/bin/sh. - touch sub/conftst$i.h - done - echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf - - # We check with `-c' and `-o' for the sake of the "dashmstdout" - # mode. It turns out that the SunPro C++ compiler does not properly - # handle `-M -o', and we need to detect this. Also, some Intel - # versions had trouble with output in subdirs - am__obj=sub/conftest.${OBJEXT-o} - am__minus_obj="-o $am__obj" - case $depmode in - gcc) - # This depmode causes a compiler race in universal mode. - test "$am__universal" = false || continue - ;; - nosideeffect) - # after this tag, mechanisms are not by side-effect, so they'll - # only be used when explicitly requested - if test "x$enable_dependency_tracking" = xyes; then - continue - else - break - fi - ;; - msvisualcpp | msvcmsys) - # This compiler won't grok `-c -o', but also, the minuso test has - # not run yet. These depmodes are late enough in the game, and - # so weak that their functioning should not be impacted. - am__obj=conftest.${OBJEXT-o} - am__minus_obj= - ;; - none) break ;; - esac - if depmode=$depmode \ - source=sub/conftest.c object=$am__obj \ - depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ - $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ - >/dev/null 2>conftest.err && - grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && - grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && - grep $am__obj sub/conftest.Po > /dev/null 2>&1 && - ${MAKE-make} -s -f confmf > /dev/null 2>&1; then - # icc doesn't choke on unknown options, it will just issue warnings - # or remarks (even with -Werror). So we grep stderr for any message - # that says an option was ignored or not supported. - # When given -MP, icc 7.0 and 7.1 complain thusly: - # icc: Command line warning: ignoring option '-M'; no argument required - # The diagnosis changed in icc 8.0: - # icc: Command line remark: option '-MP' not supported - if (grep 'ignoring option' conftest.err || - grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else - am_cv_$1_dependencies_compiler_type=$depmode - break - fi - fi - done - - cd .. - rm -rf conftest.dir -else - am_cv_$1_dependencies_compiler_type=none -fi -]) -AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) -AM_CONDITIONAL([am__fastdep$1], [ - test "x$enable_dependency_tracking" != xno \ - && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) -]) - - -# AM_SET_DEPDIR -# ------------- -# Choose a directory name for dependency files. -# This macro is AC_REQUIREd in _AM_DEPENDENCIES -AC_DEFUN([AM_SET_DEPDIR], -[AC_REQUIRE([AM_SET_LEADING_DOT])dnl -AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl -]) - - -# AM_DEP_TRACK -# ------------ -AC_DEFUN([AM_DEP_TRACK], -[AC_ARG_ENABLE(dependency-tracking, -[ --disable-dependency-tracking speeds up one-time build - --enable-dependency-tracking do not reject slow dependency extractors]) -if test "x$enable_dependency_tracking" != xno; then - am_depcomp="$ac_aux_dir/depcomp" - AMDEPBACKSLASH='\' -fi -AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) -AC_SUBST([AMDEPBACKSLASH])dnl -_AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl -]) - -# Generate code to set up dependency tracking. -*- Autoconf -*- - -# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008 -# Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -#serial 5 - -# _AM_OUTPUT_DEPENDENCY_COMMANDS -# ------------------------------ -AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], -[{ - # Autoconf 2.62 quotes --file arguments for eval, but not when files - # are listed without --file. Let's play safe and only enable the eval - # if we detect the quoting. - case $CONFIG_FILES in - *\'*) eval set x "$CONFIG_FILES" ;; - *) set x $CONFIG_FILES ;; - esac - shift - for mf - do - # Strip MF so we end up with the name of the file. - mf=`echo "$mf" | sed -e 's/:.*$//'` - # Check whether this is an Automake generated Makefile or not. - # We used to match only the files named `Makefile.in', but - # some people rename them; so instead we look at the file content. - # Grep'ing the first line is not enough: some people post-process - # each Makefile.in and add a new line on top of each file to say so. - # Grep'ing the whole file is not good either: AIX grep has a line - # limit of 2048, but all sed's we know have understand at least 4000. - if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then - dirpart=`AS_DIRNAME("$mf")` - else - continue - fi - # Extract the definition of DEPDIR, am__include, and am__quote - # from the Makefile without running `make'. - DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` - test -z "$DEPDIR" && continue - am__include=`sed -n 's/^am__include = //p' < "$mf"` - test -z "am__include" && continue - am__quote=`sed -n 's/^am__quote = //p' < "$mf"` - # When using ansi2knr, U may be empty or an underscore; expand it - U=`sed -n 's/^U = //p' < "$mf"` - # Find all dependency output files, they are included files with - # $(DEPDIR) in their names. We invoke sed twice because it is the - # simplest approach to changing $(DEPDIR) to its actual value in the - # expansion. - for file in `sed -n " - s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ - sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do - # Make sure the directory exists. - test -f "$dirpart/$file" && continue - fdir=`AS_DIRNAME(["$file"])` - AS_MKDIR_P([$dirpart/$fdir]) - # echo "creating $dirpart/$file" - echo '# dummy' > "$dirpart/$file" - done - done -} -])# _AM_OUTPUT_DEPENDENCY_COMMANDS - - -# AM_OUTPUT_DEPENDENCY_COMMANDS -# ----------------------------- -# This macro should only be invoked once -- use via AC_REQUIRE. -# -# This code is only required when automatic dependency tracking -# is enabled. FIXME. This creates each `.P' file that we will -# need in order to bootstrap the dependency handling code. -AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], -[AC_CONFIG_COMMANDS([depfiles], - [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], - [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) -]) - -# Do all the work for Automake. -*- Autoconf -*- - -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, -# 2005, 2006, 2008, 2009 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# serial 16 - -# This macro actually does too much. Some checks are only needed if -# your package does certain things. But this isn't really a big deal. - -# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) -# AM_INIT_AUTOMAKE([OPTIONS]) -# ----------------------------------------------- -# The call with PACKAGE and VERSION arguments is the old style -# call (pre autoconf-2.50), which is being phased out. PACKAGE -# and VERSION should now be passed to AC_INIT and removed from -# the call to AM_INIT_AUTOMAKE. -# We support both call styles for the transition. After -# the next Automake release, Autoconf can make the AC_INIT -# arguments mandatory, and then we can depend on a new Autoconf -# release and drop the old call support. -AC_DEFUN([AM_INIT_AUTOMAKE], -[AC_PREREQ([2.62])dnl -dnl Autoconf wants to disallow AM_ names. We explicitly allow -dnl the ones we care about. -m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl -AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl -AC_REQUIRE([AC_PROG_INSTALL])dnl -if test "`cd $srcdir && pwd`" != "`pwd`"; then - # Use -I$(srcdir) only when $(srcdir) != ., so that make's output - # is not polluted with repeated "-I." - AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl - # test to see if srcdir already configured - if test -f $srcdir/config.status; then - AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) - fi -fi - -# test whether we have cygpath -if test -z "$CYGPATH_W"; then - if (cygpath --version) >/dev/null 2>/dev/null; then - CYGPATH_W='cygpath -w' - else - CYGPATH_W=echo - fi -fi -AC_SUBST([CYGPATH_W]) - -# Define the identity of the package. -dnl Distinguish between old-style and new-style calls. -m4_ifval([$2], -[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl - AC_SUBST([PACKAGE], [$1])dnl - AC_SUBST([VERSION], [$2])], -[_AM_SET_OPTIONS([$1])dnl -dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. -m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,, - [m4_fatal([AC_INIT should be called with package and version arguments])])dnl - AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl - AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl - -_AM_IF_OPTION([no-define],, -[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) - AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl - -# Some tools Automake needs. -AC_REQUIRE([AM_SANITY_CHECK])dnl -AC_REQUIRE([AC_ARG_PROGRAM])dnl -AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version}) -AM_MISSING_PROG(AUTOCONF, autoconf) -AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version}) -AM_MISSING_PROG(AUTOHEADER, autoheader) -AM_MISSING_PROG(MAKEINFO, makeinfo) -AC_REQUIRE([AM_PROG_INSTALL_SH])dnl -AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl -AC_REQUIRE([AM_PROG_MKDIR_P])dnl -# We need awk for the "check" target. The system "awk" is bad on -# some platforms. -AC_REQUIRE([AC_PROG_AWK])dnl -AC_REQUIRE([AC_PROG_MAKE_SET])dnl -AC_REQUIRE([AM_SET_LEADING_DOT])dnl -_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], - [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], - [_AM_PROG_TAR([v7])])]) -_AM_IF_OPTION([no-dependencies],, -[AC_PROVIDE_IFELSE([AC_PROG_CC], - [_AM_DEPENDENCIES(CC)], - [define([AC_PROG_CC], - defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl -AC_PROVIDE_IFELSE([AC_PROG_CXX], - [_AM_DEPENDENCIES(CXX)], - [define([AC_PROG_CXX], - defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl -AC_PROVIDE_IFELSE([AC_PROG_OBJC], - [_AM_DEPENDENCIES(OBJC)], - [define([AC_PROG_OBJC], - defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl -]) -_AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl -dnl The `parallel-tests' driver may need to know about EXEEXT, so add the -dnl `am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This macro -dnl is hooked onto _AC_COMPILER_EXEEXT early, see below. -AC_CONFIG_COMMANDS_PRE(dnl -[m4_provide_if([_AM_COMPILER_EXEEXT], - [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl -]) - -dnl Hook into `_AC_COMPILER_EXEEXT' early to learn its expansion. Do not -dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further -dnl mangled by Autoconf and run in a shell conditional statement. -m4_define([_AC_COMPILER_EXEEXT], -m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])]) - - -# When config.status generates a header, we must update the stamp-h file. -# This file resides in the same directory as the config header -# that is generated. The stamp files are numbered to have different names. - -# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the -# loop where config.status creates the headers, so we can generate -# our stamp files there. -AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], -[# Compute $1's index in $config_headers. -_am_arg=$1 -_am_stamp_count=1 -for _am_header in $config_headers :; do - case $_am_header in - $_am_arg | $_am_arg:* ) - break ;; - * ) - _am_stamp_count=`expr $_am_stamp_count + 1` ;; - esac -done -echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) - -# Copyright (C) 2001, 2003, 2005, 2008 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# AM_PROG_INSTALL_SH -# ------------------ -# Define $install_sh. -AC_DEFUN([AM_PROG_INSTALL_SH], -[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl -if test x"${install_sh}" != xset; then - case $am_aux_dir in - *\ * | *\ *) - install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; - *) - install_sh="\${SHELL} $am_aux_dir/install-sh" - esac -fi -AC_SUBST(install_sh)]) - -# Copyright (C) 2003, 2005 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# serial 2 - -# Check whether the underlying file-system supports filenames -# with a leading dot. For instance MS-DOS doesn't. -AC_DEFUN([AM_SET_LEADING_DOT], -[rm -rf .tst 2>/dev/null -mkdir .tst 2>/dev/null -if test -d .tst; then - am__leading_dot=. -else - am__leading_dot=_ -fi -rmdir .tst 2>/dev/null -AC_SUBST([am__leading_dot])]) - -# Check to see how 'make' treats includes. -*- Autoconf -*- - -# Copyright (C) 2001, 2002, 2003, 2005, 2009 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# serial 4 - -# AM_MAKE_INCLUDE() -# ----------------- -# Check to see how make treats includes. -AC_DEFUN([AM_MAKE_INCLUDE], -[am_make=${MAKE-make} -cat > confinc << 'END' -am__doit: - @echo this is the am__doit target -.PHONY: am__doit -END -# If we don't find an include directive, just comment out the code. -AC_MSG_CHECKING([for style of include used by $am_make]) -am__include="#" -am__quote= -_am_result=none -# First try GNU make style include. -echo "include confinc" > confmf -# Ignore all kinds of additional output from `make'. -case `$am_make -s -f confmf 2> /dev/null` in #( -*the\ am__doit\ target*) - am__include=include - am__quote= - _am_result=GNU - ;; -esac -# Now try BSD make style include. -if test "$am__include" = "#"; then - echo '.include "confinc"' > confmf - case `$am_make -s -f confmf 2> /dev/null` in #( - *the\ am__doit\ target*) - am__include=.include - am__quote="\"" - _am_result=BSD - ;; - esac -fi -AC_SUBST([am__include]) -AC_SUBST([am__quote]) -AC_MSG_RESULT([$_am_result]) -rm -f confinc confmf -]) - -# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- - -# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005, 2008 -# Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# serial 6 - -# AM_MISSING_PROG(NAME, PROGRAM) -# ------------------------------ -AC_DEFUN([AM_MISSING_PROG], -[AC_REQUIRE([AM_MISSING_HAS_RUN]) -$1=${$1-"${am_missing_run}$2"} -AC_SUBST($1)]) - - -# AM_MISSING_HAS_RUN -# ------------------ -# Define MISSING if not defined so far and test if it supports --run. -# If it does, set am_missing_run to use it, otherwise, to nothing. -AC_DEFUN([AM_MISSING_HAS_RUN], -[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl -AC_REQUIRE_AUX_FILE([missing])dnl -if test x"${MISSING+set}" != xset; then - case $am_aux_dir in - *\ * | *\ *) - MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; - *) - MISSING="\${SHELL} $am_aux_dir/missing" ;; - esac -fi -# Use eval to expand $SHELL -if eval "$MISSING --run true"; then - am_missing_run="$MISSING --run " -else - am_missing_run= - AC_MSG_WARN([`missing' script is too old or missing]) -fi -]) - -# Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# AM_PROG_MKDIR_P -# --------------- -# Check for `mkdir -p'. -AC_DEFUN([AM_PROG_MKDIR_P], -[AC_PREREQ([2.60])dnl -AC_REQUIRE([AC_PROG_MKDIR_P])dnl -dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P, -dnl while keeping a definition of mkdir_p for backward compatibility. -dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile. -dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of -dnl Makefile.ins that do not define MKDIR_P, so we do our own -dnl adjustment using top_builddir (which is defined more often than -dnl MKDIR_P). -AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl -case $mkdir_p in - [[\\/$]]* | ?:[[\\/]]*) ;; - */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; -esac -]) - -# Helper functions for option handling. -*- Autoconf -*- - -# Copyright (C) 2001, 2002, 2003, 2005, 2008 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# serial 4 - -# _AM_MANGLE_OPTION(NAME) -# ----------------------- -AC_DEFUN([_AM_MANGLE_OPTION], -[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) - -# _AM_SET_OPTION(NAME) -# ------------------------------ -# Set option NAME. Presently that only means defining a flag for this option. -AC_DEFUN([_AM_SET_OPTION], -[m4_define(_AM_MANGLE_OPTION([$1]), 1)]) - -# _AM_SET_OPTIONS(OPTIONS) -# ---------------------------------- -# OPTIONS is a space-separated list of Automake options. -AC_DEFUN([_AM_SET_OPTIONS], -[m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) - -# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) -# ------------------------------------------- -# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. -AC_DEFUN([_AM_IF_OPTION], -[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) - -# Check to make sure that the build environment is sane. -*- Autoconf -*- - -# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008 -# Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# serial 5 - -# AM_SANITY_CHECK -# --------------- -AC_DEFUN([AM_SANITY_CHECK], -[AC_MSG_CHECKING([whether build environment is sane]) -# Just in case -sleep 1 -echo timestamp > conftest.file -# Reject unsafe characters in $srcdir or the absolute working directory -# name. Accept space and tab only in the latter. -am_lf=' -' -case `pwd` in - *[[\\\"\#\$\&\'\`$am_lf]]*) - AC_MSG_ERROR([unsafe absolute working directory name]);; -esac -case $srcdir in - *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*) - AC_MSG_ERROR([unsafe srcdir value: `$srcdir']);; -esac - -# Do `set' in a subshell so we don't clobber the current shell's -# arguments. Must try -L first in case configure is actually a -# symlink; some systems play weird games with the mod time of symlinks -# (eg FreeBSD returns the mod time of the symlink's containing -# directory). -if ( - set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` - if test "$[*]" = "X"; then - # -L didn't work. - set X `ls -t "$srcdir/configure" conftest.file` - fi - rm -f conftest.file - if test "$[*]" != "X $srcdir/configure conftest.file" \ - && test "$[*]" != "X conftest.file $srcdir/configure"; then - - # If neither matched, then we have a broken ls. This can happen - # if, for instance, CONFIG_SHELL is bash and it inherits a - # broken ls alias from the environment. This has actually - # happened. Such a system could not be considered "sane". - AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken -alias in your environment]) - fi - - test "$[2]" = conftest.file - ) -then - # Ok. - : -else - AC_MSG_ERROR([newly created file is older than distributed files! -Check your system clock]) -fi -AC_MSG_RESULT(yes)]) - -# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# AM_PROG_INSTALL_STRIP -# --------------------- -# One issue with vendor `install' (even GNU) is that you can't -# specify the program used to strip binaries. This is especially -# annoying in cross-compiling environments, where the build's strip -# is unlikely to handle the host's binaries. -# Fortunately install-sh will honor a STRIPPROG variable, so we -# always use install-sh in `make install-strip', and initialize -# STRIPPROG with the value of the STRIP variable (set by the user). -AC_DEFUN([AM_PROG_INSTALL_STRIP], -[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl -# Installed binaries are usually stripped using `strip' when the user -# run `make install-strip'. However `strip' might not be the right -# tool to use in cross-compilation environments, therefore Automake -# will honor the `STRIP' environment variable to overrule this program. -dnl Don't test for $cross_compiling = yes, because it might be `maybe'. -if test "$cross_compiling" != no; then - AC_CHECK_TOOL([STRIP], [strip], :) -fi -INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" -AC_SUBST([INSTALL_STRIP_PROGRAM])]) - -# Copyright (C) 2006, 2008 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# serial 2 - -# _AM_SUBST_NOTMAKE(VARIABLE) -# --------------------------- -# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. -# This macro is traced by Automake. -AC_DEFUN([_AM_SUBST_NOTMAKE]) - -# AM_SUBST_NOTMAKE(VARIABLE) -# --------------------------- -# Public sister of _AM_SUBST_NOTMAKE. -AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) - -# Check how to create a tarball. -*- Autoconf -*- - -# Copyright (C) 2004, 2005 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# serial 2 - -# _AM_PROG_TAR(FORMAT) -# -------------------- -# Check how to create a tarball in format FORMAT. -# FORMAT should be one of `v7', `ustar', or `pax'. -# -# Substitute a variable $(am__tar) that is a command -# writing to stdout a FORMAT-tarball containing the directory -# $tardir. -# tardir=directory && $(am__tar) > result.tar -# -# Substitute a variable $(am__untar) that extract such -# a tarball read from stdin. -# $(am__untar) < result.tar -AC_DEFUN([_AM_PROG_TAR], -[# Always define AMTAR for backward compatibility. -AM_MISSING_PROG([AMTAR], [tar]) -m4_if([$1], [v7], - [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'], - [m4_case([$1], [ustar],, [pax],, - [m4_fatal([Unknown tar format])]) -AC_MSG_CHECKING([how to create a $1 tar archive]) -# Loop over all known methods to create a tar archive until one works. -_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' -_am_tools=${am_cv_prog_tar_$1-$_am_tools} -# Do not fold the above two line into one, because Tru64 sh and -# Solaris sh will not grok spaces in the rhs of `-'. -for _am_tool in $_am_tools -do - case $_am_tool in - gnutar) - for _am_tar in tar gnutar gtar; - do - AM_RUN_LOG([$_am_tar --version]) && break - done - am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' - am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' - am__untar="$_am_tar -xf -" - ;; - plaintar) - # Must skip GNU tar: if it does not support --format= it doesn't create - # ustar tarball either. - (tar --version) >/dev/null 2>&1 && continue - am__tar='tar chf - "$$tardir"' - am__tar_='tar chf - "$tardir"' - am__untar='tar xf -' - ;; - pax) - am__tar='pax -L -x $1 -w "$$tardir"' - am__tar_='pax -L -x $1 -w "$tardir"' - am__untar='pax -r' - ;; - cpio) - am__tar='find "$$tardir" -print | cpio -o -H $1 -L' - am__tar_='find "$tardir" -print | cpio -o -H $1 -L' - am__untar='cpio -i -H $1 -d' - ;; - none) - am__tar=false - am__tar_=false - am__untar=false - ;; - esac - - # If the value was cached, stop now. We just wanted to have am__tar - # and am__untar set. - test -n "${am_cv_prog_tar_$1}" && break - - # tar/untar a dummy directory, and stop if the command works - rm -rf conftest.dir - mkdir conftest.dir - echo GrepMe > conftest.dir/file - AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) - rm -rf conftest.dir - if test -s conftest.tar; then - AM_RUN_LOG([$am__untar /dev/null 2>&1 && break - fi -done -rm -rf conftest.dir - -AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) -AC_MSG_RESULT([$am_cv_prog_tar_$1])]) -AC_SUBST([am__tar]) -AC_SUBST([am__untar]) -]) # _AM_PROG_TAR - diff -urN src/contrib/ntp/arlib/arlib.3 src.ntp/contrib/ntp/arlib/arlib.3 --- src/contrib/ntp/arlib/arlib.3 2004-07-20 17:01:25.000000000 +0200 +++ src.ntp/contrib/ntp/arlib/arlib.3 1970-01-01 01:00:00.000000000 +0100 @@ -1,230 +0,0 @@ -.TH arlib 3 -.SH NAME -ar_answer, ar_close, ar_delete, ar_gethostbyname, ar_gethostbyaddr, -ar_init, ar_open, ar_timeout - Asynchronous DNS library routines -.SH SYNOPSIS -.nf -.B #include "arlib.h" - -.B struct hostent *ar_answer(dataptr, size) -.B char *dataptr; -.B int size; - -.B void ar_close(); - -.B int ar_delete(dataptr, size) -.B char *dataptr; -.B int size; - -.B int ar_gethostbyname(name, dataptr, size) -.B char *name; -.B char *dataptr; -.B int size; - -.B int ar_gethostbyaddr(name, dataptr, size) -.B char *name; -.B char *dataptr; -.B int size; - -.B int ar_init(flags) -.B int flags; - -.B int ar_open(); - -.B long ar_timeout(time, dataptr, size) -.B long time; -.B char *dataptr; -.B int size; -.fi -.SH DESCRIPTION - -.PP - This small library of DNS routines is intended to provide an -asynchronous interface to performing hostname and IP number lookups. -Only lookups of Internet domain are handled as yet. To use this -set of routines properly, the presence of the -.B "BIND 4.8" -resolve -libraries is required (or any library derived from it). -.PP - This library should be used in conjunction with -.B select(2) -to wait for -the name server's reply to arrive or the lookup to timeout. -.PP - To open a fd for talking to the name server, either -.B ar_open() -or -ar_init() -must be used. -.B ar_open() - will open either a datagram socket -or a virtual circuit with the name server, depending on the flags -set in the _res structure (see -.B resolv(5) -). In both cases, if the socket - -> i -.B ar_init() -is -used to both open the socket (as in -.B ar_open() -) and initialize the -queues used by this library. The values recognized as parameters to -.B ar_init() -are: - -.RS -#define ARES_INITLIST 1 -.RE -.RS -#define ARES_CALLINIT 2 -.RE -.RS -#define ARES_INITSOCK 4 -.RE -.RS -#define ARES_INITDEBG 8 -.RE - - ARES_INITLIST initializes the list of queries waiting for replies. -ARES_CALLINIT is a flag which when set causes -.B res_init() -to be called. -ARES_INITSOCK will close the current socket if it is open and call -.B ar_open() -to open a new one, returning the fd for that socket. -ARES_INITDEBG sets the RES_DEBUG flag of the -.B _res -structure. -ARES_INITCACH is as yet, unused and is for future use where the library -keeps its own cache of replies. - - To send a query about either a hostname or an IP number, -.B ar_gethostbyname() -and -.B ar_gethostbyaddr() -must be used. Each takes -either a pointer to the hostname or the IP number respectively for use -when making the query. In addition to this, both (optionally) can be -passed a pointer to data, dataptr, with the size also passed which can -be used for identifying individual queries. A copy of the area pointed -to is made if dataptr is non NULL and size is non zero. These functions -will always return NULL unless the answer to the query is found in -internal caches. A new flag, RES_CHECKPTR is checked during the -processing of answers for -.B ar_gethostbyname() -which will automatically -cause a reverse lookup to be queued, causing a failure if that reply -differs from the original. - - To check for a query, -.B ar_answer() -is called with a pointer to an area -of memory which is sufficient to hold what was originally passed via -.B ar_gethostbyname() -or -.B ar_gethostbyaddr() -through dataptr. If an answer -is found, a pointer to the host information is returned and the data -segment copied if dataptr is non NULL and it was originally passed. The -size of the copied data is the smaller of the passed size and that of -original data stored. - - To expire old queries, -.B ar_timeout() -is called with the 'current' time -(or the time for which you want to do timeouts for). If a queue entry -is too old, it will be expired when it has exhausted all available avenues -for lookups and the data segment for the expired query copied into -dataptr. The size of the copied data is the smaller of the passed size -and that of the original stored data. Only 1 entry is thus expired with -each call, requiring that it be called immediately after an expiration -to check for others. In addition to expiring lookups, -.B ar_timeout() -also -triggers resends of queries and the searching of the domain tree for the -host, the latter works from the -.B _res -structure of -.B resolv(5). - - To delete entries from the queue, -.B ar_delete() -can be used and by -passing the pointer and size of the data segment, all queries have their -data segments checked (if present) for an exact match, being deleted if -and only if there is a match. A NULL pointer passed to ar_deleted() -matches all queries which were called with a NULL dataptr parameter. -The amount of data compared is the smaller of the size passed and that -of the data stored for the queue entry being compared. - - To close a socket opened by -.B ar_open() -, -.B ar_close() -should be used so -that it is closed and also marked closed within this library. - - -.SH DIAGNOSIS - -.B ar_open() -returns -1 if a socket isn't open and could not be opened; -otherwise returns the current fd open or the fd it opened. - -.B ar_init() -returns -1 for any errors, the value returned by -.B res_init() -if -.B res_init() -was called, the return value for -.B ar_open() -if that was -called or the current socket open if 0 is passed and a socket is open. -If neither -.B res_init() -or -.B ar_open() -are called and the flags are non-zero, -2 is returned. - -.B ar_gethostbyaddr() -and -.B ar_gethostbyname() -will always return NULL in this version but may return a pointer to a hostent -structure if a cache is being used and the answer is found in the cache. - -.B ar_answer() -returns NULL if the answer is either not found or the -query returned an error and another attempt at a lookup is attempted. -If an answer was found, it returned a pointer to this structure and -the contents of the data segment copied over. - -.B ar_timeout() -returns the time when it should be called next or 0 if -there are no queries in the queue to be checked later. If any queries -are expired, the data segment is copied over if dataptr is non NULL. - -.B ar_delete() -returns the number of entries that were found to match -and consequently deleted. - -.SH SEE ALSO - -gethostbyaddr(3), gethostbyname(3), resolv(5) - -.SH FILES -.nf -arlib.h -/usr/include/resolv.h -/usr/include/arpa/nameser.h -/etc/resolv.conf - -.SH BUGS - -The results of a successful call to ar_answer() destroy the structure -for any previous calls. - -.SH AUTHOR - -Darren Reed. Email address: avalon@coombs.anu.edu.au diff -urN src/contrib/ntp/arlib/arlib.c src.ntp/contrib/ntp/arlib/arlib.c --- src/contrib/ntp/arlib/arlib.c 2004-07-20 17:01:25.000000000 +0200 +++ src.ntp/contrib/ntp/arlib/arlib.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,1056 +0,0 @@ -/* - * arlib.c (C)opyright 1993 Darren Reed. All rights reserved. - * This file may not be distributed without the author's permission in any - * shape or form. The author takes no responsibility for any damage or loss - * of property which results from the use of this software. - */ -#ifndef lint -static char sccsid[] = "@(#)arlib.c 1.9 6/5/93 (C)opyright 1992 Darren \ -Reed. ASYNC DNS"; -#endif - -#include -#include -#include -#include -#include -#include -#include -#include "netdb.h" -#include "arpa/nameser.h" -#include -#include "arlib.h" -#include "arplib.h" - -extern int errno, h_errno; -static char ar_hostbuf[65], ar_domainname[65]; -static char ar_dot[] = "."; -static int ar_resfd = -1, ar_vc = 0; -static struct reslist *ar_last, *ar_first; - -/* - * Statistics structure. - */ -static struct resstats { - int re_errors; - int re_nu_look; - int re_na_look; - int re_replies; - int re_requests; - int re_resends; - int re_sent; - int re_timeouts; -} ar_reinfo; - -static int do_query_name(/* struct resinfo *, char *, struct reslist * */); -static int do_query_number(/* struct resinfo *, char *, struct reslist * */); -static int ar_resend_query(/* struct reslist * */); - -/* - * ar_init - * - * Initializes the various ARLIB internal varilables and related DNS - * options for res_init(). - * - * Returns 0 or the socket opened for use with talking to name servers - * if 0 is passed or ARES_INITSOCK is set. - */ -int ar_init(op) -int op; -{ - int ret = 0; - - if (op & ARES_INITLIST) - { - bzero(&ar_reinfo, sizeof(ar_reinfo)); - ar_first = ar_last = NULL; - } - - if (op & ARES_CALLINIT && !(_res.options & RES_INIT)) - { - ret = res_init(); - (void)strcpy(ar_domainname, ar_dot); - (void)strncat(ar_domainname, _res.defdname, - sizeof(ar_domainname)-2); - } - - if (op & ARES_INITSOCK) - ret = ar_resfd = ar_open(); - - if (op & ARES_INITDEBG) - _res.options |= RES_DEBUG; - - if (op == 0) - ret = ar_resfd; - - return ret; -} - - -/* - * ar_open - * - * Open a socket to talk to a name server with. - * Check _res.options to see if we use a TCP or UDP socket. - */ -int ar_open() -{ - if (ar_resfd == -1) - { - if (_res.options & RES_USEVC) - { - struct sockaddr_in *sip; - int i; - - sip = _res.NS_ADDR_LIST; /* was _res.nsaddr_list */ - ar_vc = 1; - ar_resfd = socket(AF_INET, SOCK_STREAM, 0); - - /* - * Try each name server listed in sequence until we - * succeed or run out. - */ - while (connect(ar_resfd, (struct sockaddr *)sip++, - sizeof(struct sockaddr))) - { - (void)close(ar_resfd); - ar_resfd = -1; - if (i >= _res.nscount) - break; - ar_resfd = socket(AF_INET, SOCK_STREAM, 0); - } - } - else - ar_resfd = socket(AF_INET, SOCK_DGRAM, 0); - } - if (ar_resfd >= 0) - { /* Need one of these two here - and it MUST work!! */ - int flags; - - if ((flags = fcntl(ar_resfd, F_GETFL, 0)) != -1) -#ifdef O_NONBLOCK - if (fcntl(ar_resfd, F_SETFL, flags|O_NONBLOCK) == -1) -#else -# ifdef O_NDELAY - if (fcntl(ar_resfd, F_SETFL, flags|O_NDELAY) == -1) -# else -# ifdef FNDELAY - if (fcntl(ar_resfd, F_SETFL, flags|FNDELAY) == -1) -# endif -# endif -#endif - { - (void)close(ar_resfd); - ar_resfd = -1; - } - } - return ar_resfd; -} - - -/* - * ar_close - * - * Closes and flags the ARLIB socket as closed. - */ -void ar_close() -{ - (void)close(ar_resfd); - ar_resfd = -1; - return; -} - - -/* - * ar_add_request - * - * Add a new DNS query to the end of the query list. - */ -static int ar_add_request(new) -struct reslist *new; -{ - if (!new) - return -1; - if (!ar_first) - ar_first = ar_last = new; - else { - ar_last->re_next = new; - ar_last = new; - } - new->re_next = NULL; - ar_reinfo.re_requests++; - return 0; -} - - -/* - * ar_remrequest - * - * Remove a request from the list. This must also free any memory that has - * been allocated for temporary storage of DNS results. - * - * Returns -1 if there are anyy problems removing the requested structure - * or 0 if the remove is successful. - */ -static int ar_remrequest(old) -struct reslist *old; -{ - register struct reslist *rptr, *r2ptr; - register char **s; - - if (!old) - return -1; - for (rptr = ar_first, r2ptr = NULL; rptr; rptr = rptr->re_next) - { - if (rptr == old) - break; - r2ptr = rptr; - } - - if (!rptr) - return -1; - if (rptr == ar_first) - ar_first = ar_first->re_next; - else if (rptr == ar_last) - { - if (ar_last = r2ptr) - ar_last->re_next = NULL; - } - else - r2ptr->re_next = rptr->re_next; - - if (!ar_first) - ar_last = ar_first; - -#ifdef ARLIB_DEBUG - ar_dump_hostent("ar_remrequest:", rptr->re_he); -#endif - - if (rptr->re_he.h_name) - (void)free(rptr->re_he.h_name); - if (s = rptr->re_he.h_aliases) - for (; *s; s++) - (void)free(*s); - if (rptr->re_rinfo.ri_ptr) - (void)free(rptr->re_rinfo.ri_ptr); - (void)free(rptr); - - return 0; -} - - -/* - * ar_make_request - * - * Create a DNS query recorded for the request being made and place it on the - * current list awaiting replies. Initialization of the record with set - * values should also be done. - */ -static struct reslist *ar_make_request(resi) -register struct resinfo *resi; -{ - register struct reslist *rptr; - register struct resinfo *rp; - - rptr = (struct reslist *)calloc(1, sizeof(struct reslist)); - rp = &rptr->re_rinfo; - - rptr->re_next = NULL; /* where NULL is non-zero ;) */ - rptr->re_sentat = time(NULL); - rptr->re_retries = _res.retry; - rptr->re_sends = 1; - rptr->re_resend = 1; - rptr->re_timeout = rptr->re_sentat + _res.retrans; - rptr->re_he.h_name = NULL; - rptr->re_he.h_addrtype = AF_INET; - rptr->re_he.h_aliases[0] = NULL; - rp->ri_ptr = resi->ri_ptr; - rp->ri_size = resi->ri_size; - - (void)ar_add_request(rptr); - - return rptr; -} - - -/* - * ar_timeout - * - * Remove queries from the list which have been there too long without - * being resolved. - */ -long ar_timeout(now, info, size) -time_t now; -char *info; -int size; -{ - register struct reslist *rptr, *r2ptr; - register long next = 0; - - for (rptr = ar_first, r2ptr = NULL; rptr; rptr = r2ptr) - { - r2ptr = rptr->re_next; - if (now >= rptr->re_timeout) - { - /* - * If the timeout for the query has been exceeded, - * then resend the query if we still have some - * 'retry credit' and reset the timeout. If we have - * used it all up, then remove the request. - */ - if (--rptr->re_retries <= 0) - { - ar_reinfo.re_timeouts++; - if (info && rptr->re_rinfo.ri_ptr) - bcopy(rptr->re_rinfo.ri_ptr, info, - MIN(rptr->re_rinfo.ri_size, - size)); - (void)ar_remrequest(rptr); - return now; - } - else - { - rptr->re_sends++; - rptr->re_sentat = now; - rptr->re_timeout = now + _res.retrans; - (void)ar_resend_query(rptr); - } - } - if (!next || rptr->re_timeout < next) - next = rptr->re_timeout; - } - return next; -} - - -/* - * ar_send_res_msg - * - * When sending queries to nameservers listed in the resolv.conf file, - * don't send a query to every one, but increase the number sent linearly - * to match the number of resends. This increase only occurs if there are - * multiple nameserver entries in the resolv.conf file. - * The return value is the number of messages successfully sent to - * nameservers or -1 if no successful sends. - */ -static int ar_send_res_msg(msg, len, rcount) -char *msg; -int len, rcount; -{ - register int i; - int sent = 0; - - if (!msg) - return -1; - - rcount = (_res.nscount > rcount) ? rcount : _res.nscount; - if (_res.options & RES_PRIMARY) - rcount = 1; - - if (ar_vc) - { - ar_reinfo.re_sent++; - sent++; - if (write(ar_resfd, msg, len) == -1) - { - int errtmp = errno; - (void)close(ar_resfd); - errno = errtmp; - ar_resfd = -1; - } - } - else - for (i = 0; i < rcount; i++) - { - if (sendto(ar_resfd, msg, len, 0, - (struct sockaddr *)&(_res.NS_ADDR_LIST[i]), - sizeof(struct sockaddr_in)) == len) - { - ar_reinfo.re_sent++; - sent++; - } - } - return (sent) ? sent : -1; -} - - -/* - * ar_find_id - * - * find a dns query record by the id (id is determined by dn_mkquery) - */ -static struct reslist *ar_find_id(id) -int id; -{ - register struct reslist *rptr; - - for (rptr = ar_first; rptr; rptr = rptr->re_next) - if (rptr->re_id == id) - return rptr; - return NULL; -} - - -/* - * ar_delete - * - * Delete a request from the waiting list if it has a data pointer which - * matches the one passed. - */ -int ar_delete(ptr, size) -char *ptr; -int size; -{ - register struct reslist *rptr; - register struct reslist *r2ptr; - int removed = 0; - - for (rptr = ar_first; rptr; rptr = r2ptr) - { - r2ptr = rptr->re_next; - if (rptr->re_rinfo.ri_ptr && ptr && size && - bcmp(rptr->re_rinfo.ri_ptr, ptr, size) == 0) - { - (void)ar_remrequest(rptr); - removed++; - } - } - return removed; -} - - -/* - * ar_query_name - * - * generate a query based on class, type and name. - */ -static int ar_query_name(name, class, type, rptr) -char *name; -int class, type; -struct reslist *rptr; -{ - static char buf[MAXPACKET]; - int r,s,a; - HEADER *hptr; - - bzero(buf, sizeof(buf)); - r = res_mkquery(QUERY, name, class, type, NULL, 0, NULL, - buf, sizeof(buf)); - if (r <= 0) - { - h_errno = NO_RECOVERY; - return r; - } - hptr = (HEADER *)buf; - rptr->re_id = ntohs(hptr->id); - - s = ar_send_res_msg(buf, r, rptr->re_sends); - - if (s == -1) - { - h_errno = TRY_AGAIN; - return -1; - } - else - rptr->re_sent += s; - return 0; -} - - -/* - * ar_gethostbyname - * - * Replacement library function call to gethostbyname(). This one, however, - * doesn't return the record being looked up but just places the query in the - * queue to await answers. - */ -int ar_gethostbyname(name, info, size) -char *name; -char *info; -int size; -{ - char host[65]; - struct resinfo resi; - register struct resinfo *rp = &resi; - - if (size && info) - { - rp->ri_ptr = (char *)malloc(size); - bcopy(info, rp->ri_ptr, size); - rp->ri_size = size; - } - else - bzero((char *)rp, sizeof(resi)); - ar_reinfo.re_na_look++; - (void)strncpy(host, name, 64); - host[64] = '\0'; - - return (do_query_name(rp, host, NULL)); -} - - -static int do_query_name(resi, name, rptr) -struct resinfo *resi; -char *name; -register struct reslist *rptr; -{ - char hname[65]; - int len; - - len = strlen((char *)strncpy(hname, name, sizeof(hname)-1)); - - if (rptr && (hname[len-1] != '.')) - { - (void)strncat(hname, ar_dot, sizeof(hname)-len-1); - /* - * NOTE: The logical relationship between DNSRCH and DEFNAMES - * is implies. ie no DEFNAES, no DNSRCH. - */ - if (_res.options & (RES_DEFNAMES|RES_DNSRCH) == - (RES_DEFNAMES|RES_DNSRCH)) - { - if (_res.dnsrch[rptr->re_srch]) - (void)strncat(hname, _res.dnsrch[rptr->re_srch], - sizeof(hname) - ++len -1); - } - else if (_res.options & RES_DEFNAMES) - (void)strncat(hname, ar_domainname, sizeof(hname) - len -1); - } - - /* - * Store the name passed as the one to lookup and generate other host - * names to pass onto the nameserver(s) for lookups. - */ - if (!rptr) - { - rptr = ar_make_request(resi); - rptr->re_type = T_A; - (void)strncpy(rptr->re_name, name, sizeof(rptr->re_name)-1); - } - return (ar_query_name(hname, C_IN, T_A, rptr)); -} - - -/* - * ar_gethostbyaddr - * - * Generates a query for a given IP address. - */ -int ar_gethostbyaddr(addr, info, size) -char *addr; -char *info; -int size; -{ - struct resinfo resi; - register struct resinfo *rp = &resi; - - if (size && info) - { - rp->ri_ptr = (char *)malloc(size); - bcopy(info, rp->ri_ptr, size); - rp->ri_size = size; - } - else - bzero((char *)rp, sizeof(resi)); - ar_reinfo.re_nu_look++; - return (do_query_number(rp, addr, NULL)); -} - - -/* - * do_query_number - * - * Use this to do reverse IP# lookups. - */ -static int do_query_number(resi, numb, rptr) -struct resinfo *resi; -char *numb; -register struct reslist *rptr; -{ - register unsigned char *cp; - static char ipbuf[32]; - - /* - * Generate name in the "in-addr.arpa" domain. No addings bits to this - * name to get more names to query!. - */ - cp = (unsigned char *)numb; - (void)sprintf(ipbuf,"%u.%u.%u.%u.in-addr.arpa.", - (unsigned int)(cp[3]), (unsigned int)(cp[2]), - (unsigned int)(cp[1]), (unsigned int)(cp[0])); - - if (!rptr) - { - rptr = ar_make_request(resi); - rptr->re_type = T_PTR; - rptr->re_he.h_length = sizeof(struct in_addr); - bcopy(numb, (char *)&rptr->re_addr, rptr->re_he.h_length); - bcopy(numb, (char *)&rptr->re_he.h_addr_list[0].s_addr, - rptr->re_he.h_length); - } - return (ar_query_name(ipbuf, C_IN, T_PTR, rptr)); -} - - -/* - * ar_resent_query - * - * resends a query. - */ -static int ar_resend_query(rptr) -struct reslist *rptr; -{ - if (!rptr->re_resend) - return -1; - - switch(rptr->re_type) - { - case T_PTR: - ar_reinfo.re_resends++; - return do_query_number(NULL, &rptr->re_addr, rptr); - case T_A: - ar_reinfo.re_resends++; - return do_query_name(NULL, rptr->re_name, rptr); - default: - break; - } - - return -1; -} - - -/* - * ar_procanswer - * - * process an answer received from a nameserver. - */ -static int ar_procanswer(rptr, hptr, buf, eob) -struct reslist *rptr; -char *buf, *eob; -HEADER *hptr; -{ - char *cp, **alias, *s; - int class, type, dlen, len, ans = 0, n, i; - u_int32_t ttl, dr, *adr; - struct hent *hp; - - cp = buf + sizeof(HEADER); - adr = (u_int32_t *)rptr->re_he.h_addr_list; - - while (*adr) - adr++; - - alias = rptr->re_he.h_aliases; - while (*alias) - alias++; - - hp = &rptr->re_he; - - - /* - * Skip over the original question. - */ - while (hptr->qdcount-- > 0) - cp += dn_skipname(cp, eob) + QFIXEDSZ; - /* - * proccess each answer sent to us. blech. - */ - while (hptr->ancount-- > 0 && cp < eob) { - n = dn_expand(buf, eob, cp, ar_hostbuf, sizeof(ar_hostbuf)); - cp += n; - if (n <= 0) - return ans; - - ans++; - /* - * 'skip' past the general dns crap (ttl, class, etc) to get - * the pointer to the right spot. Some of thse are actually - * useful so its not a good idea to skip past in one big jump. - */ - type = (int)_getshort(cp); - cp += sizeof(short); - class = (int)_getshort(cp); - cp += sizeof(short); - ttl = (u_int32_t)_getlong(cp); - cp += sizeof(u_int32_t); - dlen = (int)_getshort(cp); - cp += sizeof(short); - rptr->re_type = type; - - switch(type) - { - case T_A : - rptr->re_he.h_length = dlen; - if (ans == 1) - rptr->re_he.h_addrtype=(class == C_IN) ? - AF_INET : AF_UNSPEC; - if (dlen != sizeof(dr)) - { - h_errno = TRY_AGAIN; - continue; - } - bcopy(cp, &dr, dlen); - *adr++ = dr; - *adr = 0; - cp += dlen; - len = strlen(ar_hostbuf); - if (!rptr->re_he.h_name) - { - rptr->re_he.h_name = (char *)malloc(len+1); - if (!rptr->re_he.h_name) - break; - (void)strcpy(rptr->re_he.h_name, ar_hostbuf); - } - break; - case T_PTR : - if ((n = dn_expand(buf, eob, cp, ar_hostbuf, - sizeof(ar_hostbuf) )) < 0) - { - cp += n; - continue; - } - cp += n; - len = strlen(ar_hostbuf)+1; - /* - * copy the returned hostname into the host name - * or alias field if there is a known hostname - * already. - */ - if (!rptr->re_he.h_name) - { - rptr->re_he.h_name = (char *)malloc(len); - if (!rptr->re_he.h_name) - break; - (void)strcpy(rptr->re_he.h_name, ar_hostbuf); - } - else - { - *alias = (char *)malloc(len); - if (!*alias) - return -1; - (void)strcpy(*alias++, ar_hostbuf); - *alias = NULL; - } - break; - case T_CNAME : - cp += dlen; - if (alias >= &(rptr->re_he.h_aliases[MAXALIASES-1])) - continue; - n = strlen(ar_hostbuf)+1; - *alias = (char *)malloc(n); - if (!*alias) - return -1; - (void)strcpy(*alias++, ar_hostbuf); - *alias = NULL; - break; - default : - break; - } - } - - return ans; -} - - -/* - * ar_answer - * - * Get an answer from a DNS server and process it. If a query is found to - * which no answer has been given to yet, copy its 'info' structure back - * to where "reip" points and return a pointer to the hostent structure. - */ -struct hostent *ar_answer(reip, size) -char *reip; -int size; -{ - static char ar_rcvbuf[sizeof(HEADER) + MAXPACKET]; - static struct hostent ar_host; - - register HEADER *hptr; - register struct reslist *rptr = NULL; - register struct hostent *hp; - register char **s; - unsigned long *adr; - int rc, i, n, a; - - rc = recv(ar_resfd, ar_rcvbuf, sizeof(ar_rcvbuf), 0); - if (rc <= 0) - goto getres_err; - - ar_reinfo.re_replies++; - hptr = (HEADER *)ar_rcvbuf; - /* - * convert things to be in the right order. - */ - hptr->id = ntohs(hptr->id); - hptr->ancount = ntohs(hptr->ancount); - hptr->arcount = ntohs(hptr->arcount); - hptr->nscount = ntohs(hptr->nscount); - hptr->qdcount = ntohs(hptr->qdcount); - /* - * response for an id which we have already received an answer for - * just ignore this response. - */ - rptr = ar_find_id(hptr->id); - if (!rptr) - goto getres_err; - - if ((hptr->rcode != NOERROR) || (hptr->ancount == 0)) - { - switch (hptr->rcode) - { - case NXDOMAIN: - h_errno = HOST_NOT_FOUND; - break; - case SERVFAIL: - h_errno = TRY_AGAIN; - break; - case NOERROR: - h_errno = NO_DATA; - break; - case FORMERR: - case NOTIMP: - case REFUSED: - default: - h_errno = NO_RECOVERY; - break; - } - ar_reinfo.re_errors++; - /* - ** If a bad error was returned, we stop here and dont send - ** send any more (no retries granted). - */ - if (h_errno != TRY_AGAIN) - { - rptr->re_resend = 0; - rptr->re_retries = 0; - } - goto getres_err; - } - - a = ar_procanswer(rptr, hptr, ar_rcvbuf, ar_rcvbuf+rc); - - if ((rptr->re_type == T_PTR) && (_res.options & RES_CHECKPTR)) - { - /* - * For reverse lookups on IP#'s, lookup the name that is given - * for the ip# and return with that as the official result. - * -avalon - */ - rptr->re_type = T_A; - /* - * Clean out the list of addresses already set, even though - * there should only be one :) - */ - adr = (unsigned long *)rptr->re_he.h_addr_list; - while (*adr) - *adr++ = 0L; - /* - * Lookup the name that we were given for the ip# - */ - ar_reinfo.re_na_look++; - (void)strncpy(rptr->re_name, rptr->re_he.h_name, - sizeof(rptr->re_name)-1); - rptr->re_he.h_name = NULL; - rptr->re_retries = _res.retry; - rptr->re_sends = 1; - rptr->re_resend = 1; - rptr->re_he.h_name = NULL; - ar_reinfo.re_na_look++; - (void)ar_query_name(rptr->re_name, C_IN, T_A, rptr); - return NULL; - } - - if (reip && rptr->re_rinfo.ri_ptr && size) - bcopy(rptr->re_rinfo.ri_ptr, reip, - MIN(rptr->re_rinfo.ri_size, size)); - /* - * Clean up structure from previous usage. - */ - hp = &ar_host; -#ifdef ARLIB_DEBUG - ar_dump_hostent("ar_answer: previous usage", hp); -#endif - - if (hp->h_name) - (void)free(hp->h_name); - if (s = hp->h_aliases) - { - while (*s) - (void)free(*s++); - (void)free(hp->h_aliases); - } - if (s = hp->h_addr_list) - { - /* - * Only free once since we allocated space for - * address in one big chunk. - */ - (void)free(*s); - (void)free(hp->h_addr_list); - } - bzero((char *)hp, sizeof(*hp)); - - /* - * Setup and copy details for the structure we return a pointer to. - */ - hp->h_addrtype = AF_INET; - hp->h_length = sizeof(struct in_addr); - if(rptr->re_he.h_name) - { - hp->h_name = (char *)malloc(strlen(rptr->re_he.h_name)+1); - if(!hp->h_name) - { -#ifdef ARLIB_DEBUG - fprintf(stderr, "no memory for hostname\n"); -#endif - h_errno = TRY_AGAIN; - goto getres_err; - } - (void)strcpy(hp->h_name, rptr->re_he.h_name); - } -#ifdef ARLIB_DEBUG - ar_dump_hostent("ar_answer: (snap) store name", hp); -#endif - - /* - * Count IP#'s. - */ - for (i = 0, n = 0; i < MAXADDRS; i++, n++) - if (!rptr->re_he.h_addr_list[i].s_addr) - break; - s = hp->h_addr_list = (char **)malloc((n + 1) * sizeof(char *)); - if (n) - { - *s = (char *)malloc(n * sizeof(struct in_addr)); - if(!*s) - { -#ifdef ARLIB_DEBUG - fprintf(stderr, "no memory for IP#'s (%d)\n", n); -#endif - h_errno = TRY_AGAIN; - goto getres_err; - } - bcopy((char *)&rptr->re_he.h_addr_list[0].s_addr, *s, - sizeof(struct in_addr)); - s++; - for (i = 1; i < n; i++, s++) - { - *s = hp->h_addr + i * sizeof(struct in_addr); - bcopy((char *)&rptr->re_he.h_addr_list[i].s_addr, *s, - sizeof(struct in_addr)); - } - } - *s = NULL; -#ifdef ARLIB_DEBUG - ar_dump_hostent("ar_answer: (snap) store IP#'s", hp); -#endif - - /* - * Count CNAMEs - */ - for (i = 0, n = 0; i < MAXADDRS; i++, n++) - if (!rptr->re_he.h_aliases[i]) - break; - s = hp->h_aliases = (char **)malloc((n + 1) * sizeof(char *)); - if (!s) - { -#ifdef ARLIB_DEBUG - fprintf(stderr, "no memory for aliases (%d)\n", n); -#endif - h_errno = TRY_AGAIN; - goto getres_err; - } - for (i = 0; i < n; i++) - { - *s++ = rptr->re_he.h_aliases[i]; - rptr->re_he.h_aliases[i] = NULL; - } - *s = NULL; -#ifdef ARLIB_DEBUG - ar_dump_hostent("ar_answer: (snap) store CNAMEs", hp); - ar_dump_hostent("ar_answer: new one", hp); -#endif - - if (a > 0) - (void)ar_remrequest(rptr); - else - if (!rptr->re_sent) - (void)ar_remrequest(rptr); - return hp; - -getres_err: - if (rptr) - { - if (reip && rptr->re_rinfo.ri_ptr && size) - bcopy(rptr->re_rinfo.ri_ptr, reip, - MIN(rptr->re_rinfo.ri_size, size)); - if ((h_errno != TRY_AGAIN) && - (_res.options & (RES_DNSRCH|RES_DEFNAMES) == - (RES_DNSRCH|RES_DEFNAMES) )) - if (_res.dnsrch[rptr->re_srch]) - { - rptr->re_retries = _res.retry; - rptr->re_sends = 1; - rptr->re_resend = 1; - (void)ar_resend_query(rptr); - rptr->re_srch++; - } - return NULL; - } - return NULL; -} - - -#ifdef ARLIB_DEBUG -void ar_dump_hostent(prefix, hp) -char *prefix; -struct hostent *hp; -{ - register char **s; - - fflush(stdout); - - fprintf(stderr, "%s\n", prefix); - fprintf(stderr, " hp %p\n", hp); - fprintf(stderr, " h_name %p '%s'\n", - hp->h_name, hp->h_name); - if (s = hp->h_aliases) - { - fprintf(stderr, " h_aliases %p\n", - hp->h_aliases); - while (*s) - { - fprintf(stderr, " element %p\n", *s); - s++; - } - } - if (s = hp->h_addr_list) - { - fprintf(stderr, " h_addr_list %p\n", - hp->h_addr_list); - while (*s) - { - fprintf(stderr, " element %p\n", *s); - s++; - } - } - - fflush(stderr); -} - - -void ar_dump_reslist(FILE* fp) -{ - register struct reslist *rptr; - int c; - - c = 0; - for (rptr = ar_first; rptr; rptr = rptr->re_next) - { - fprintf(fp, "%4d [%p] %4d [%p]: %s\n", rptr->re_id, rptr, - *(rptr->re_rinfo.ri_ptr), rptr->re_rinfo.ri_ptr, - rptr->re_name); - } -} -#endif diff -urN src/contrib/ntp/arlib/arlib.h src.ntp/contrib/ntp/arlib/arlib.h --- src/contrib/ntp/arlib/arlib.h 2004-07-20 17:01:22.000000000 +0200 +++ src.ntp/contrib/ntp/arlib/arlib.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,29 +0,0 @@ -/* - * arlib.h (C)opyright 1992 Darren Reed. - */ - -#define ARES_INITLIST 1 -#define ARES_CALLINIT 2 -#define ARES_INITSOCK 4 -#define ARES_INITDEBG 8 -#define ARES_INITCACH 16 - -#ifdef __STDC__ -extern struct hostent *ar_answer(char *, int); -extern void ar_close(); -extern int ar_delete(char *, int); -extern int ar_gethostbyname(char *, char *, int); -extern int ar_gethostbyaddr(char *, char *, int); -extern int ar_init(int); -extern int ar_open(); -extern long ar_timeout(time_t, char *, int); -#else -extern struct hostent *ar_answer(); -extern void ar_close(); -extern int ar_delete(); -extern int ar_gethostbyname(); -extern int ar_gethostbyaddr(); -extern int ar_init(); -extern int ar_open(); -extern long ar_timeout(); -#endif diff -urN src/contrib/ntp/arlib/arplib.h src.ntp/contrib/ntp/arlib/arplib.h --- src/contrib/ntp/arlib/arplib.h 2004-07-20 17:01:25.000000000 +0200 +++ src.ntp/contrib/ntp/arlib/arplib.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,45 +0,0 @@ -/* - * arplib.h (C)opyright 1992 Darren Reed. - */ - -#define MAXPACKET 1024 -#define MAXALIASES 35 -#define MAXADDRS 35 - -#define RES_CHECKPTR 0x0400 - -struct hent { - char *h_name; /* official name of host */ - char *h_aliases[MAXALIASES]; /* alias list */ - int h_addrtype; /* host address type */ - int h_length; /* length of address */ - /* list of addresses from name server */ - struct in_addr h_addr_list[MAXADDRS]; -#define h_addr h_addr_list[0] /* address, for backward compatiblity */ -}; - -struct resinfo { - char *ri_ptr; - int ri_size; -}; - -struct reslist { - int re_id; - char re_type; - char re_retries; - char re_resend; /* send flag. 0 == dont resend */ - char re_sends; - char re_srch; - int re_sent; - u_long re_sentat; - u_long re_timeout; - struct in_addr re_addr; - struct resinfo re_rinfo; - struct hent re_he; - struct reslist *re_next, *re_prev; - char re_name[65]; -}; - -#ifndef MIN -#define MIN(a,b) ((a) > (b) ? (b) : (a)) -#endif diff -urN src/contrib/ntp/arlib/configure src.ntp/contrib/ntp/arlib/configure --- src/contrib/ntp/arlib/configure 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/arlib/configure 1970-01-01 01:00:00.000000000 +0100 @@ -1,5008 +0,0 @@ -#! /bin/sh -# Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.65. -# -# -# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, -# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. -# -# -# This configure script is free software; the Free Software Foundation -# gives unlimited permission to copy, distribute and modify it. -## -------------------- ## -## M4sh Initialization. ## -## -------------------- ## - -# Be more Bourne compatible -DUALCASE=1; export DUALCASE # for MKS sh -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in #( - *posix*) : - set -o posix ;; #( - *) : - ;; -esac -fi - - -as_nl=' -' -export as_nl -# Printing a long string crashes Solaris 7 /usr/bin/printf. -as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo -# Prefer a ksh shell builtin over an external printf program on Solaris, -# but without wasting forks for bash or zsh. -if test -z "$BASH_VERSION$ZSH_VERSION" \ - && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='print -r --' - as_echo_n='print -rn --' -elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='printf %s\n' - as_echo_n='printf %s' -else - if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then - as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' - as_echo_n='/usr/ucb/echo -n' - else - as_echo_body='eval expr "X$1" : "X\\(.*\\)"' - as_echo_n_body='eval - arg=$1; - case $arg in #( - *"$as_nl"*) - expr "X$arg" : "X\\(.*\\)$as_nl"; - arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; - esac; - expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" - ' - export as_echo_n_body - as_echo_n='sh -c $as_echo_n_body as_echo' - fi - export as_echo_body - as_echo='sh -c $as_echo_body as_echo' -fi - -# The user is always right. -if test "${PATH_SEPARATOR+set}" != set; then - PATH_SEPARATOR=: - (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { - (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || - PATH_SEPARATOR=';' - } -fi - - -# IFS -# We need space, tab and new line, in precisely that order. Quoting is -# there to prevent editors from complaining about space-tab. -# (If _AS_PATH_WALK were called with IFS unset, it would disable word -# splitting by setting IFS to empty value.) -IFS=" "" $as_nl" - -# Find who we are. Look in the path if we contain no directory separator. -case $0 in #(( - *[\\/]* ) as_myself=$0 ;; - *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break - done -IFS=$as_save_IFS - - ;; -esac -# We did not find ourselves, most probably we were run as `sh COMMAND' -# in which case we are not to be found in the path. -if test "x$as_myself" = x; then - as_myself=$0 -fi -if test ! -f "$as_myself"; then - $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 - exit 1 -fi - -# Unset variables that we do not need and which cause bugs (e.g. in -# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" -# suppresses any "Segmentation fault" message there. '((' could -# trigger a bug in pdksh 5.2.14. -for as_var in BASH_ENV ENV MAIL MAILPATH -do eval test x\${$as_var+set} = xset \ - && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : -done -PS1='$ ' -PS2='> ' -PS4='+ ' - -# NLS nuisances. -LC_ALL=C -export LC_ALL -LANGUAGE=C -export LANGUAGE - -# CDPATH. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - -if test "x$CONFIG_SHELL" = x; then - as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which - # is contrary to our usage. Disable this feature. - alias -g '\${1+\"\$@\"}'='\"\$@\"' - setopt NO_GLOB_SUBST -else - case \`(set -o) 2>/dev/null\` in #( - *posix*) : - set -o posix ;; #( - *) : - ;; -esac -fi -" - as_required="as_fn_return () { (exit \$1); } -as_fn_success () { as_fn_return 0; } -as_fn_failure () { as_fn_return 1; } -as_fn_ret_success () { return 0; } -as_fn_ret_failure () { return 1; } - -exitcode=0 -as_fn_success || { exitcode=1; echo as_fn_success failed.; } -as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } -as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } -as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } -if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : - -else - exitcode=1; echo positional parameters were not saved. -fi -test x\$exitcode = x0 || exit 1" - as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO - as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO - eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && - test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1" - if (eval "$as_required") 2>/dev/null; then : - as_have_required=yes -else - as_have_required=no -fi - if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : - -else - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -as_found=false -for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - as_found=: - case $as_dir in #( - /*) - for as_base in sh bash ksh sh5; do - # Try only shells that exist, to save several forks. - as_shell=$as_dir/$as_base - if { test -f "$as_shell" || test -f "$as_shell.exe"; } && - { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : - CONFIG_SHELL=$as_shell as_have_required=yes - if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : - break 2 -fi -fi - done;; - esac - as_found=false -done -$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && - { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : - CONFIG_SHELL=$SHELL as_have_required=yes -fi; } -IFS=$as_save_IFS - - - if test "x$CONFIG_SHELL" != x; then : - # We cannot yet assume a decent shell, so we have to provide a - # neutralization value for shells without unset; and this also - # works around shells that cannot unset nonexistent variables. - BASH_ENV=/dev/null - ENV=/dev/null - (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV - export CONFIG_SHELL - exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"} -fi - - if test x$as_have_required = xno; then : - $as_echo "$0: This script requires a shell more modern than all" - $as_echo "$0: the shells that I found on your system." - if test x${ZSH_VERSION+set} = xset ; then - $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" - $as_echo "$0: be upgraded to zsh 4.3.4 or later." - else - $as_echo "$0: Please tell bug-autoconf@gnu.org about your system, -$0: including any error possibly output before this -$0: message. Then install a modern shell, or manually run -$0: the script under such a shell if you do have one." - fi - exit 1 -fi -fi -fi -SHELL=${CONFIG_SHELL-/bin/sh} -export SHELL -# Unset more variables known to interfere with behavior of common tools. -CLICOLOR_FORCE= GREP_OPTIONS= -unset CLICOLOR_FORCE GREP_OPTIONS - -## --------------------- ## -## M4sh Shell Functions. ## -## --------------------- ## -# as_fn_unset VAR -# --------------- -# Portably unset VAR. -as_fn_unset () -{ - { eval $1=; unset $1;} -} -as_unset=as_fn_unset - -# as_fn_set_status STATUS -# ----------------------- -# Set $? to STATUS, without forking. -as_fn_set_status () -{ - return $1 -} # as_fn_set_status - -# as_fn_exit STATUS -# ----------------- -# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. -as_fn_exit () -{ - set +e - as_fn_set_status $1 - exit $1 -} # as_fn_exit - -# as_fn_mkdir_p -# ------------- -# Create "$as_dir" as a directory, including parents if necessary. -as_fn_mkdir_p () -{ - - case $as_dir in #( - -*) as_dir=./$as_dir;; - esac - test -d "$as_dir" || eval $as_mkdir_p || { - as_dirs= - while :; do - case $as_dir in #( - *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( - *) as_qdir=$as_dir;; - esac - as_dirs="'$as_qdir' $as_dirs" - as_dir=`$as_dirname -- "$as_dir" || -$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_dir" : 'X\(//\)[^/]' \| \ - X"$as_dir" : 'X\(//\)$' \| \ - X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_dir" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - test -d "$as_dir" && break - done - test -z "$as_dirs" || eval "mkdir $as_dirs" - } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir" - - -} # as_fn_mkdir_p -# as_fn_append VAR VALUE -# ---------------------- -# Append the text in VALUE to the end of the definition contained in VAR. Take -# advantage of any shell optimizations that allow amortized linear growth over -# repeated appends, instead of the typical quadratic growth present in naive -# implementations. -if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : - eval 'as_fn_append () - { - eval $1+=\$2 - }' -else - as_fn_append () - { - eval $1=\$$1\$2 - } -fi # as_fn_append - -# as_fn_arith ARG... -# ------------------ -# Perform arithmetic evaluation on the ARGs, and store the result in the -# global $as_val. Take advantage of shells that can avoid forks. The arguments -# must be portable across $(()) and expr. -if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : - eval 'as_fn_arith () - { - as_val=$(( $* )) - }' -else - as_fn_arith () - { - as_val=`expr "$@" || test $? -eq 1` - } -fi # as_fn_arith - - -# as_fn_error ERROR [LINENO LOG_FD] -# --------------------------------- -# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are -# provided, also output the error to LOG_FD, referencing LINENO. Then exit the -# script with status $?, using 1 if that was 0. -as_fn_error () -{ - as_status=$?; test $as_status -eq 0 && as_status=1 - if test "$3"; then - as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3 - fi - $as_echo "$as_me: error: $1" >&2 - as_fn_exit $as_status -} # as_fn_error - -if expr a : '\(a\)' >/dev/null 2>&1 && - test "X`expr 00001 : '.*\(...\)'`" = X001; then - as_expr=expr -else - as_expr=false -fi - -if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then - as_basename=basename -else - as_basename=false -fi - -if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then - as_dirname=dirname -else - as_dirname=false -fi - -as_me=`$as_basename -- "$0" || -$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ - X"$0" : 'X\(//\)$' \| \ - X"$0" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X/"$0" | - sed '/^.*\/\([^/][^/]*\)\/*$/{ - s//\1/ - q - } - /^X\/\(\/\/\)$/{ - s//\1/ - q - } - /^X\/\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - -# Avoid depending upon Character Ranges. -as_cr_letters='abcdefghijklmnopqrstuvwxyz' -as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' -as_cr_Letters=$as_cr_letters$as_cr_LETTERS -as_cr_digits='0123456789' -as_cr_alnum=$as_cr_Letters$as_cr_digits - - - as_lineno_1=$LINENO as_lineno_1a=$LINENO - as_lineno_2=$LINENO as_lineno_2a=$LINENO - eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && - test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { - # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) - sed -n ' - p - /[$]LINENO/= - ' <$as_myself | - sed ' - s/[$]LINENO.*/&-/ - t lineno - b - :lineno - N - :loop - s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ - t loop - s/-\n.*// - ' >$as_me.lineno && - chmod +x "$as_me.lineno" || - { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } - - # Don't try to exec as it changes $[0], causing all sort of problems - # (the dirname of $[0] is not the place where we might find the - # original and so on. Autoconf is especially sensitive to this). - . "./$as_me.lineno" - # Exit status is that of the last command. - exit -} - -ECHO_C= ECHO_N= ECHO_T= -case `echo -n x` in #((((( --n*) - case `echo 'xy\c'` in - *c*) ECHO_T=' ';; # ECHO_T is single tab character. - xy) ECHO_C='\c';; - *) echo `echo ksh88 bug on AIX 6.1` > /dev/null - ECHO_T=' ';; - esac;; -*) - ECHO_N='-n';; -esac - -rm -f conf$$ conf$$.exe conf$$.file -if test -d conf$$.dir; then - rm -f conf$$.dir/conf$$.file -else - rm -f conf$$.dir - mkdir conf$$.dir 2>/dev/null -fi -if (echo >conf$$.file) 2>/dev/null; then - if ln -s conf$$.file conf$$ 2>/dev/null; then - as_ln_s='ln -s' - # ... but there are two gotchas: - # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. - # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -p'. - ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || - as_ln_s='cp -p' - elif ln conf$$.file conf$$ 2>/dev/null; then - as_ln_s=ln - else - as_ln_s='cp -p' - fi -else - as_ln_s='cp -p' -fi -rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file -rmdir conf$$.dir 2>/dev/null - -if mkdir -p . 2>/dev/null; then - as_mkdir_p='mkdir -p "$as_dir"' -else - test -d ./-p && rmdir ./-p - as_mkdir_p=false -fi - -if test -x / >/dev/null 2>&1; then - as_test_x='test -x' -else - if ls -dL / >/dev/null 2>&1; then - as_ls_L_option=L - else - as_ls_L_option= - fi - as_test_x=' - eval sh -c '\'' - if test -d "$1"; then - test -d "$1/."; - else - case $1 in #( - -*)set "./$1";; - esac; - case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( - ???[sx]*):;;*)false;;esac;fi - '\'' sh - ' -fi -as_executable_p=$as_test_x - -# Sed expression to map a string onto a valid CPP name. -as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" - -# Sed expression to map a string onto a valid variable name. -as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" - - -test -n "$DJDIR" || exec 7<&0 &1 - -# Name of the host. -# hostname on some systems (SVR3.2, Linux) returns a bogus exit status, -# so uname gets run too. -ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` - -# -# Initializations. -# -ac_default_prefix=/usr/local -ac_clean_files= -ac_config_libobj_dir=. -LIBOBJS= -cross_compiling=no -subdirs= -MFLAGS= -MAKEFLAGS= - -# Identity of this package. -PACKAGE_NAME= -PACKAGE_TARNAME= -PACKAGE_VERSION= -PACKAGE_STRING= -PACKAGE_BUGREPORT= -PACKAGE_URL= - -ac_unique_file="arlib.c" -ac_subst_vars='am__EXEEXT_FALSE -am__EXEEXT_TRUE -LTLIBOBJS -LIBOBJS -RANLIB -am__fastdepCC_FALSE -am__fastdepCC_TRUE -CCDEPMODE -AMDEPBACKSLASH -AMDEP_FALSE -AMDEP_TRUE -am__quote -am__include -DEPDIR -OBJEXT -EXEEXT -ac_ct_CC -CPPFLAGS -LDFLAGS -CFLAGS -CC -am__untar -am__tar -AMTAR -am__leading_dot -SET_MAKE -AWK -mkdir_p -MKDIR_P -INSTALL_STRIP_PROGRAM -STRIP -install_sh -MAKEINFO -AUTOHEADER -AUTOMAKE -AUTOCONF -ACLOCAL -VERSION -PACKAGE -CYGPATH_W -am__isrc -INSTALL_DATA -INSTALL_SCRIPT -INSTALL_PROGRAM -target_alias -host_alias -build_alias -LIBS -ECHO_T -ECHO_N -ECHO_C -DEFS -mandir -localedir -libdir -psdir -pdfdir -dvidir -htmldir -infodir -docdir -oldincludedir -includedir -localstatedir -sharedstatedir -sysconfdir -datadir -datarootdir -libexecdir -sbindir -bindir -program_transform_name -prefix -exec_prefix -PACKAGE_URL -PACKAGE_BUGREPORT -PACKAGE_STRING -PACKAGE_VERSION -PACKAGE_TARNAME -PACKAGE_NAME -PATH_SEPARATOR -SHELL' -ac_subst_files='' -ac_user_opts=' -enable_option_checking -enable_dependency_tracking -' - ac_precious_vars='build_alias -host_alias -target_alias -CC -CFLAGS -LDFLAGS -LIBS -CPPFLAGS' - - -# Initialize some variables set by options. -ac_init_help= -ac_init_version=false -ac_unrecognized_opts= -ac_unrecognized_sep= -# The variables have the same names as the options, with -# dashes changed to underlines. -cache_file=/dev/null -exec_prefix=NONE -no_create= -no_recursion= -prefix=NONE -program_prefix=NONE -program_suffix=NONE -program_transform_name=s,x,x, -silent= -site= -srcdir= -verbose= -x_includes=NONE -x_libraries=NONE - -# Installation directory options. -# These are left unexpanded so users can "make install exec_prefix=/foo" -# and all the variables that are supposed to be based on exec_prefix -# by default will actually change. -# Use braces instead of parens because sh, perl, etc. also accept them. -# (The list follows the same order as the GNU Coding Standards.) -bindir='${exec_prefix}/bin' -sbindir='${exec_prefix}/sbin' -libexecdir='${exec_prefix}/libexec' -datarootdir='${prefix}/share' -datadir='${datarootdir}' -sysconfdir='${prefix}/etc' -sharedstatedir='${prefix}/com' -localstatedir='${prefix}/var' -includedir='${prefix}/include' -oldincludedir='/usr/include' -docdir='${datarootdir}/doc/${PACKAGE}' -infodir='${datarootdir}/info' -htmldir='${docdir}' -dvidir='${docdir}' -pdfdir='${docdir}' -psdir='${docdir}' -libdir='${exec_prefix}/lib' -localedir='${datarootdir}/locale' -mandir='${datarootdir}/man' - -ac_prev= -ac_dashdash= -for ac_option -do - # If the previous option needs an argument, assign it. - if test -n "$ac_prev"; then - eval $ac_prev=\$ac_option - ac_prev= - continue - fi - - case $ac_option in - *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; - *) ac_optarg=yes ;; - esac - - # Accept the important Cygnus configure options, so we can diagnose typos. - - case $ac_dashdash$ac_option in - --) - ac_dashdash=yes ;; - - -bindir | --bindir | --bindi | --bind | --bin | --bi) - ac_prev=bindir ;; - -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) - bindir=$ac_optarg ;; - - -build | --build | --buil | --bui | --bu) - ac_prev=build_alias ;; - -build=* | --build=* | --buil=* | --bui=* | --bu=*) - build_alias=$ac_optarg ;; - - -cache-file | --cache-file | --cache-fil | --cache-fi \ - | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) - ac_prev=cache_file ;; - -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ - | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) - cache_file=$ac_optarg ;; - - --config-cache | -C) - cache_file=config.cache ;; - - -datadir | --datadir | --datadi | --datad) - ac_prev=datadir ;; - -datadir=* | --datadir=* | --datadi=* | --datad=*) - datadir=$ac_optarg ;; - - -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ - | --dataroo | --dataro | --datar) - ac_prev=datarootdir ;; - -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ - | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) - datarootdir=$ac_optarg ;; - - -disable-* | --disable-*) - ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error "invalid feature name: $ac_useropt" - ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"enable_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval enable_$ac_useropt=no ;; - - -docdir | --docdir | --docdi | --doc | --do) - ac_prev=docdir ;; - -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) - docdir=$ac_optarg ;; - - -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) - ac_prev=dvidir ;; - -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) - dvidir=$ac_optarg ;; - - -enable-* | --enable-*) - ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error "invalid feature name: $ac_useropt" - ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"enable_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval enable_$ac_useropt=\$ac_optarg ;; - - -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ - | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ - | --exec | --exe | --ex) - ac_prev=exec_prefix ;; - -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ - | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ - | --exec=* | --exe=* | --ex=*) - exec_prefix=$ac_optarg ;; - - -gas | --gas | --ga | --g) - # Obsolete; use --with-gas. - with_gas=yes ;; - - -help | --help | --hel | --he | -h) - ac_init_help=long ;; - -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) - ac_init_help=recursive ;; - -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) - ac_init_help=short ;; - - -host | --host | --hos | --ho) - ac_prev=host_alias ;; - -host=* | --host=* | --hos=* | --ho=*) - host_alias=$ac_optarg ;; - - -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) - ac_prev=htmldir ;; - -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ - | --ht=*) - htmldir=$ac_optarg ;; - - -includedir | --includedir | --includedi | --included | --include \ - | --includ | --inclu | --incl | --inc) - ac_prev=includedir ;; - -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ - | --includ=* | --inclu=* | --incl=* | --inc=*) - includedir=$ac_optarg ;; - - -infodir | --infodir | --infodi | --infod | --info | --inf) - ac_prev=infodir ;; - -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) - infodir=$ac_optarg ;; - - -libdir | --libdir | --libdi | --libd) - ac_prev=libdir ;; - -libdir=* | --libdir=* | --libdi=* | --libd=*) - libdir=$ac_optarg ;; - - -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ - | --libexe | --libex | --libe) - ac_prev=libexecdir ;; - -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ - | --libexe=* | --libex=* | --libe=*) - libexecdir=$ac_optarg ;; - - -localedir | --localedir | --localedi | --localed | --locale) - ac_prev=localedir ;; - -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) - localedir=$ac_optarg ;; - - -localstatedir | --localstatedir | --localstatedi | --localstated \ - | --localstate | --localstat | --localsta | --localst | --locals) - ac_prev=localstatedir ;; - -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ - | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) - localstatedir=$ac_optarg ;; - - -mandir | --mandir | --mandi | --mand | --man | --ma | --m) - ac_prev=mandir ;; - -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) - mandir=$ac_optarg ;; - - -nfp | --nfp | --nf) - # Obsolete; use --without-fp. - with_fp=no ;; - - -no-create | --no-create | --no-creat | --no-crea | --no-cre \ - | --no-cr | --no-c | -n) - no_create=yes ;; - - -no-recursion | --no-recursion | --no-recursio | --no-recursi \ - | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) - no_recursion=yes ;; - - -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ - | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ - | --oldin | --oldi | --old | --ol | --o) - ac_prev=oldincludedir ;; - -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ - | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ - | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) - oldincludedir=$ac_optarg ;; - - -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) - ac_prev=prefix ;; - -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) - prefix=$ac_optarg ;; - - -program-prefix | --program-prefix | --program-prefi | --program-pref \ - | --program-pre | --program-pr | --program-p) - ac_prev=program_prefix ;; - -program-prefix=* | --program-prefix=* | --program-prefi=* \ - | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) - program_prefix=$ac_optarg ;; - - -program-suffix | --program-suffix | --program-suffi | --program-suff \ - | --program-suf | --program-su | --program-s) - ac_prev=program_suffix ;; - -program-suffix=* | --program-suffix=* | --program-suffi=* \ - | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) - program_suffix=$ac_optarg ;; - - -program-transform-name | --program-transform-name \ - | --program-transform-nam | --program-transform-na \ - | --program-transform-n | --program-transform- \ - | --program-transform | --program-transfor \ - | --program-transfo | --program-transf \ - | --program-trans | --program-tran \ - | --progr-tra | --program-tr | --program-t) - ac_prev=program_transform_name ;; - -program-transform-name=* | --program-transform-name=* \ - | --program-transform-nam=* | --program-transform-na=* \ - | --program-transform-n=* | --program-transform-=* \ - | --program-transform=* | --program-transfor=* \ - | --program-transfo=* | --program-transf=* \ - | --program-trans=* | --program-tran=* \ - | --progr-tra=* | --program-tr=* | --program-t=*) - program_transform_name=$ac_optarg ;; - - -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) - ac_prev=pdfdir ;; - -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) - pdfdir=$ac_optarg ;; - - -psdir | --psdir | --psdi | --psd | --ps) - ac_prev=psdir ;; - -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) - psdir=$ac_optarg ;; - - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil) - silent=yes ;; - - -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) - ac_prev=sbindir ;; - -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ - | --sbi=* | --sb=*) - sbindir=$ac_optarg ;; - - -sharedstatedir | --sharedstatedir | --sharedstatedi \ - | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ - | --sharedst | --shareds | --shared | --share | --shar \ - | --sha | --sh) - ac_prev=sharedstatedir ;; - -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ - | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ - | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ - | --sha=* | --sh=*) - sharedstatedir=$ac_optarg ;; - - -site | --site | --sit) - ac_prev=site ;; - -site=* | --site=* | --sit=*) - site=$ac_optarg ;; - - -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) - ac_prev=srcdir ;; - -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) - srcdir=$ac_optarg ;; - - -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ - | --syscon | --sysco | --sysc | --sys | --sy) - ac_prev=sysconfdir ;; - -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ - | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) - sysconfdir=$ac_optarg ;; - - -target | --target | --targe | --targ | --tar | --ta | --t) - ac_prev=target_alias ;; - -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) - target_alias=$ac_optarg ;; - - -v | -verbose | --verbose | --verbos | --verbo | --verb) - verbose=yes ;; - - -version | --version | --versio | --versi | --vers | -V) - ac_init_version=: ;; - - -with-* | --with-*) - ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error "invalid package name: $ac_useropt" - ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"with_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval with_$ac_useropt=\$ac_optarg ;; - - -without-* | --without-*) - ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error "invalid package name: $ac_useropt" - ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"with_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval with_$ac_useropt=no ;; - - --x) - # Obsolete; use --with-x. - with_x=yes ;; - - -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ - | --x-incl | --x-inc | --x-in | --x-i) - ac_prev=x_includes ;; - -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ - | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) - x_includes=$ac_optarg ;; - - -x-libraries | --x-libraries | --x-librarie | --x-librari \ - | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) - ac_prev=x_libraries ;; - -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ - | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) - x_libraries=$ac_optarg ;; - - -*) as_fn_error "unrecognized option: \`$ac_option' -Try \`$0 --help' for more information." - ;; - - *=*) - ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` - # Reject names that are not valid shell variable names. - case $ac_envvar in #( - '' | [0-9]* | *[!_$as_cr_alnum]* ) - as_fn_error "invalid variable name: \`$ac_envvar'" ;; - esac - eval $ac_envvar=\$ac_optarg - export $ac_envvar ;; - - *) - # FIXME: should be removed in autoconf 3.0. - $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 - expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && - $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 - : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option} - ;; - - esac -done - -if test -n "$ac_prev"; then - ac_option=--`echo $ac_prev | sed 's/_/-/g'` - as_fn_error "missing argument to $ac_option" -fi - -if test -n "$ac_unrecognized_opts"; then - case $enable_option_checking in - no) ;; - fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;; - *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; - esac -fi - -# Check all directory arguments for consistency. -for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ - datadir sysconfdir sharedstatedir localstatedir includedir \ - oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ - libdir localedir mandir -do - eval ac_val=\$$ac_var - # Remove trailing slashes. - case $ac_val in - */ ) - ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` - eval $ac_var=\$ac_val;; - esac - # Be sure to have absolute directory names. - case $ac_val in - [\\/$]* | ?:[\\/]* ) continue;; - NONE | '' ) case $ac_var in *prefix ) continue;; esac;; - esac - as_fn_error "expected an absolute directory name for --$ac_var: $ac_val" -done - -# There might be people who depend on the old broken behavior: `$host' -# used to hold the argument of --host etc. -# FIXME: To remove some day. -build=$build_alias -host=$host_alias -target=$target_alias - -# FIXME: To remove some day. -if test "x$host_alias" != x; then - if test "x$build_alias" = x; then - cross_compiling=maybe - $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host. - If a cross compiler is detected then cross compile mode will be used." >&2 - elif test "x$build_alias" != "x$host_alias"; then - cross_compiling=yes - fi -fi - -ac_tool_prefix= -test -n "$host_alias" && ac_tool_prefix=$host_alias- - -test "$silent" = yes && exec 6>/dev/null - - -ac_pwd=`pwd` && test -n "$ac_pwd" && -ac_ls_di=`ls -di .` && -ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || - as_fn_error "working directory cannot be determined" -test "X$ac_ls_di" = "X$ac_pwd_ls_di" || - as_fn_error "pwd does not report name of working directory" - - -# Find the source files, if location was not specified. -if test -z "$srcdir"; then - ac_srcdir_defaulted=yes - # Try the directory containing this script, then the parent directory. - ac_confdir=`$as_dirname -- "$as_myself" || -$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_myself" : 'X\(//\)[^/]' \| \ - X"$as_myself" : 'X\(//\)$' \| \ - X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_myself" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - srcdir=$ac_confdir - if test ! -r "$srcdir/$ac_unique_file"; then - srcdir=.. - fi -else - ac_srcdir_defaulted=no -fi -if test ! -r "$srcdir/$ac_unique_file"; then - test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." - as_fn_error "cannot find sources ($ac_unique_file) in $srcdir" -fi -ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" -ac_abs_confdir=`( - cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg" - pwd)` -# When building in place, set srcdir=. -if test "$ac_abs_confdir" = "$ac_pwd"; then - srcdir=. -fi -# Remove unnecessary trailing slashes from srcdir. -# Double slashes in file names in object file debugging info -# mess up M-x gdb in Emacs. -case $srcdir in -*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; -esac -for ac_var in $ac_precious_vars; do - eval ac_env_${ac_var}_set=\${${ac_var}+set} - eval ac_env_${ac_var}_value=\$${ac_var} - eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} - eval ac_cv_env_${ac_var}_value=\$${ac_var} -done - -# -# Report the --help message. -# -if test "$ac_init_help" = "long"; then - # Omit some internal or obsolete options to make the list less imposing. - # This message is too long to be a string in the A/UX 3.1 sh. - cat <<_ACEOF -\`configure' configures this package to adapt to many kinds of systems. - -Usage: $0 [OPTION]... [VAR=VALUE]... - -To assign environment variables (e.g., CC, CFLAGS...), specify them as -VAR=VALUE. See below for descriptions of some of the useful variables. - -Defaults for the options are specified in brackets. - -Configuration: - -h, --help display this help and exit - --help=short display options specific to this package - --help=recursive display the short help of all the included packages - -V, --version display version information and exit - -q, --quiet, --silent do not print \`checking...' messages - --cache-file=FILE cache test results in FILE [disabled] - -C, --config-cache alias for \`--cache-file=config.cache' - -n, --no-create do not create output files - --srcdir=DIR find the sources in DIR [configure dir or \`..'] - -Installation directories: - --prefix=PREFIX install architecture-independent files in PREFIX - [$ac_default_prefix] - --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX - [PREFIX] - -By default, \`make install' will install all the files in -\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify -an installation prefix other than \`$ac_default_prefix' using \`--prefix', -for instance \`--prefix=\$HOME'. - -For better control, use the options below. - -Fine tuning of the installation directories: - --bindir=DIR user executables [EPREFIX/bin] - --sbindir=DIR system admin executables [EPREFIX/sbin] - --libexecdir=DIR program executables [EPREFIX/libexec] - --sysconfdir=DIR read-only single-machine data [PREFIX/etc] - --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] - --localstatedir=DIR modifiable single-machine data [PREFIX/var] - --libdir=DIR object code libraries [EPREFIX/lib] - --includedir=DIR C header files [PREFIX/include] - --oldincludedir=DIR C header files for non-gcc [/usr/include] - --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] - --datadir=DIR read-only architecture-independent data [DATAROOTDIR] - --infodir=DIR info documentation [DATAROOTDIR/info] - --localedir=DIR locale-dependent data [DATAROOTDIR/locale] - --mandir=DIR man documentation [DATAROOTDIR/man] - --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE] - --htmldir=DIR html documentation [DOCDIR] - --dvidir=DIR dvi documentation [DOCDIR] - --pdfdir=DIR pdf documentation [DOCDIR] - --psdir=DIR ps documentation [DOCDIR] -_ACEOF - - cat <<\_ACEOF - -Program names: - --program-prefix=PREFIX prepend PREFIX to installed program names - --program-suffix=SUFFIX append SUFFIX to installed program names - --program-transform-name=PROGRAM run sed PROGRAM on installed program names -_ACEOF -fi - -if test -n "$ac_init_help"; then - - cat <<\_ACEOF - -Optional Features: - --disable-option-checking ignore unrecognized --enable/--with options - --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) - --enable-FEATURE[=ARG] include FEATURE [ARG=yes] - --disable-dependency-tracking speeds up one-time build - --enable-dependency-tracking do not reject slow dependency extractors - -Some influential environment variables: - CC C compiler command - CFLAGS C compiler flags - LDFLAGS linker flags, e.g. -L if you have libraries in a - nonstandard directory - LIBS libraries to pass to the linker, e.g. -l - CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I if - you have headers in a nonstandard directory - -Use these variables to override the choices made by `configure' or to help -it to find libraries and programs with nonstandard names/locations. - -Report bugs to the package provider. -_ACEOF -ac_status=$? -fi - -if test "$ac_init_help" = "recursive"; then - # If there are subdirs, report their specific --help. - for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue - test -d "$ac_dir" || - { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || - continue - ac_builddir=. - -case "$ac_dir" in -.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; -*) - ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` - # A ".." for each directory in $ac_dir_suffix. - ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` - case $ac_top_builddir_sub in - "") ac_top_builddir_sub=. ac_top_build_prefix= ;; - *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; - esac ;; -esac -ac_abs_top_builddir=$ac_pwd -ac_abs_builddir=$ac_pwd$ac_dir_suffix -# for backward compatibility: -ac_top_builddir=$ac_top_build_prefix - -case $srcdir in - .) # We are building in place. - ac_srcdir=. - ac_top_srcdir=$ac_top_builddir_sub - ac_abs_top_srcdir=$ac_pwd ;; - [\\/]* | ?:[\\/]* ) # Absolute name. - ac_srcdir=$srcdir$ac_dir_suffix; - ac_top_srcdir=$srcdir - ac_abs_top_srcdir=$srcdir ;; - *) # Relative name. - ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix - ac_top_srcdir=$ac_top_build_prefix$srcdir - ac_abs_top_srcdir=$ac_pwd/$srcdir ;; -esac -ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix - - cd "$ac_dir" || { ac_status=$?; continue; } - # Check for guested configure. - if test -f "$ac_srcdir/configure.gnu"; then - echo && - $SHELL "$ac_srcdir/configure.gnu" --help=recursive - elif test -f "$ac_srcdir/configure"; then - echo && - $SHELL "$ac_srcdir/configure" --help=recursive - else - $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 - fi || ac_status=$? - cd "$ac_pwd" || { ac_status=$?; break; } - done -fi - -test -n "$ac_init_help" && exit $ac_status -if $ac_init_version; then - cat <<\_ACEOF -configure -generated by GNU Autoconf 2.65 - -Copyright (C) 2009 Free Software Foundation, Inc. -This configure script is free software; the Free Software Foundation -gives unlimited permission to copy, distribute and modify it. -_ACEOF - exit -fi - -## ------------------------ ## -## Autoconf initialization. ## -## ------------------------ ## - -# ac_fn_c_try_compile LINENO -# -------------------------- -# Try to compile conftest.$ac_ext, and return whether this succeeded. -ac_fn_c_try_compile () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - rm -f conftest.$ac_objext - if { { ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_compile") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then : - ac_retval=0 -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} - as_fn_set_status $ac_retval - -} # ac_fn_c_try_compile - -# ac_fn_c_check_func LINENO FUNC VAR -# ---------------------------------- -# Tests whether FUNC exists, setting the cache variable VAR accordingly -ac_fn_c_check_func () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -/* Define $2 to an innocuous variant, in case declares $2. - For example, HP-UX 11i declares gettimeofday. */ -#define $2 innocuous_$2 - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $2 (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $2 - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $2 (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$2 || defined __stub___$2 -choke me -#endif - -int -main () -{ -return $2 (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - eval "$3=yes" -else - eval "$3=no" -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} - -} # ac_fn_c_check_func - -# ac_fn_c_check_type LINENO TYPE VAR INCLUDES -# ------------------------------------------- -# Tests whether TYPE exists after having included INCLUDES, setting cache -# variable VAR accordingly. -ac_fn_c_check_type () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : - $as_echo_n "(cached) " >&6 -else - eval "$3=no" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main () -{ -if (sizeof ($2)) - return 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main () -{ -if (sizeof (($2))) - return 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - -else - eval "$3=yes" -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} - -} # ac_fn_c_check_type -cat >config.log <<_ACEOF -This file contains any messages produced by compilers while -running configure, to aid debugging if configure makes a mistake. - -It was created by $as_me, which was -generated by GNU Autoconf 2.65. Invocation command line was - - $ $0 $@ - -_ACEOF -exec 5>>config.log -{ -cat <<_ASUNAME -## --------- ## -## Platform. ## -## --------- ## - -hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` -uname -m = `(uname -m) 2>/dev/null || echo unknown` -uname -r = `(uname -r) 2>/dev/null || echo unknown` -uname -s = `(uname -s) 2>/dev/null || echo unknown` -uname -v = `(uname -v) 2>/dev/null || echo unknown` - -/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` -/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` - -/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` -/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` -/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` -/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` -/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` -/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` -/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` - -_ASUNAME - -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - $as_echo "PATH: $as_dir" - done -IFS=$as_save_IFS - -} >&5 - -cat >&5 <<_ACEOF - - -## ----------- ## -## Core tests. ## -## ----------- ## - -_ACEOF - - -# Keep a trace of the command line. -# Strip out --no-create and --no-recursion so they do not pile up. -# Strip out --silent because we don't want to record it for future runs. -# Also quote any args containing shell meta-characters. -# Make two passes to allow for proper duplicate-argument suppression. -ac_configure_args= -ac_configure_args0= -ac_configure_args1= -ac_must_keep_next=false -for ac_pass in 1 2 -do - for ac_arg - do - case $ac_arg in - -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil) - continue ;; - *\'*) - ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; - esac - case $ac_pass in - 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; - 2) - as_fn_append ac_configure_args1 " '$ac_arg'" - if test $ac_must_keep_next = true; then - ac_must_keep_next=false # Got value, back to normal. - else - case $ac_arg in - *=* | --config-cache | -C | -disable-* | --disable-* \ - | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ - | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ - | -with-* | --with-* | -without-* | --without-* | --x) - case "$ac_configure_args0 " in - "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; - esac - ;; - -* ) ac_must_keep_next=true ;; - esac - fi - as_fn_append ac_configure_args " '$ac_arg'" - ;; - esac - done -done -{ ac_configure_args0=; unset ac_configure_args0;} -{ ac_configure_args1=; unset ac_configure_args1;} - -# When interrupted or exit'd, cleanup temporary files, and complete -# config.log. We remove comments because anyway the quotes in there -# would cause problems or look ugly. -# WARNING: Use '\'' to represent an apostrophe within the trap. -# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. -trap 'exit_status=$? - # Save into config.log some information that might help in debugging. - { - echo - - cat <<\_ASBOX -## ---------------- ## -## Cache variables. ## -## ---------------- ## -_ASBOX - echo - # The following way of writing the cache mishandles newlines in values, -( - for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do - eval ac_val=\$$ac_var - case $ac_val in #( - *${as_nl}*) - case $ac_var in #( - *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 -$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; - esac - case $ac_var in #( - _ | IFS | as_nl) ;; #( - BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( - *) { eval $ac_var=; unset $ac_var;} ;; - esac ;; - esac - done - (set) 2>&1 | - case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( - *${as_nl}ac_space=\ *) - sed -n \ - "s/'\''/'\''\\\\'\'''\''/g; - s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" - ;; #( - *) - sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" - ;; - esac | - sort -) - echo - - cat <<\_ASBOX -## ----------------- ## -## Output variables. ## -## ----------------- ## -_ASBOX - echo - for ac_var in $ac_subst_vars - do - eval ac_val=\$$ac_var - case $ac_val in - *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; - esac - $as_echo "$ac_var='\''$ac_val'\''" - done | sort - echo - - if test -n "$ac_subst_files"; then - cat <<\_ASBOX -## ------------------- ## -## File substitutions. ## -## ------------------- ## -_ASBOX - echo - for ac_var in $ac_subst_files - do - eval ac_val=\$$ac_var - case $ac_val in - *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; - esac - $as_echo "$ac_var='\''$ac_val'\''" - done | sort - echo - fi - - if test -s confdefs.h; then - cat <<\_ASBOX -## ----------- ## -## confdefs.h. ## -## ----------- ## -_ASBOX - echo - cat confdefs.h - echo - fi - test "$ac_signal" != 0 && - $as_echo "$as_me: caught signal $ac_signal" - $as_echo "$as_me: exit $exit_status" - } >&5 - rm -f core *.core core.conftest.* && - rm -f -r conftest* confdefs* conf$$* $ac_clean_files && - exit $exit_status -' 0 -for ac_signal in 1 2 13 15; do - trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal -done -ac_signal=0 - -# confdefs.h avoids OS command line length limits that DEFS can exceed. -rm -f -r conftest* confdefs.h - -$as_echo "/* confdefs.h */" > confdefs.h - -# Predefined preprocessor variables. - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_NAME "$PACKAGE_NAME" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_TARNAME "$PACKAGE_TARNAME" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_VERSION "$PACKAGE_VERSION" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_STRING "$PACKAGE_STRING" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_URL "$PACKAGE_URL" -_ACEOF - - -# Let the site file select an alternate cache file if it wants to. -# Prefer an explicitly selected file to automatically selected ones. -ac_site_file1=NONE -ac_site_file2=NONE -if test -n "$CONFIG_SITE"; then - ac_site_file1=$CONFIG_SITE -elif test "x$prefix" != xNONE; then - ac_site_file1=$prefix/share/config.site - ac_site_file2=$prefix/etc/config.site -else - ac_site_file1=$ac_default_prefix/share/config.site - ac_site_file2=$ac_default_prefix/etc/config.site -fi -for ac_site_file in "$ac_site_file1" "$ac_site_file2" -do - test "x$ac_site_file" = xNONE && continue - if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 -$as_echo "$as_me: loading site script $ac_site_file" >&6;} - sed 's/^/| /' "$ac_site_file" >&5 - . "$ac_site_file" - fi -done - -if test -r "$cache_file"; then - # Some versions of bash will fail to source /dev/null (special files - # actually), so we avoid doing that. DJGPP emulates it as a regular file. - if test /dev/null != "$cache_file" && test -f "$cache_file"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 -$as_echo "$as_me: loading cache $cache_file" >&6;} - case $cache_file in - [\\/]* | ?:[\\/]* ) . "$cache_file";; - *) . "./$cache_file";; - esac - fi -else - { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 -$as_echo "$as_me: creating cache $cache_file" >&6;} - >$cache_file -fi - -# Check that the precious variables saved in the cache have kept the same -# value. -ac_cache_corrupted=false -for ac_var in $ac_precious_vars; do - eval ac_old_set=\$ac_cv_env_${ac_var}_set - eval ac_new_set=\$ac_env_${ac_var}_set - eval ac_old_val=\$ac_cv_env_${ac_var}_value - eval ac_new_val=\$ac_env_${ac_var}_value - case $ac_old_set,$ac_new_set in - set,) - { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 -$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} - ac_cache_corrupted=: ;; - ,set) - { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 -$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} - ac_cache_corrupted=: ;; - ,);; - *) - if test "x$ac_old_val" != "x$ac_new_val"; then - # differences in whitespace do not lead to failure. - ac_old_val_w=`echo x $ac_old_val` - ac_new_val_w=`echo x $ac_new_val` - if test "$ac_old_val_w" != "$ac_new_val_w"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 -$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} - ac_cache_corrupted=: - else - { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 -$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} - eval $ac_var=\$ac_old_val - fi - { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 -$as_echo "$as_me: former value: \`$ac_old_val'" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 -$as_echo "$as_me: current value: \`$ac_new_val'" >&2;} - fi;; - esac - # Pass precious variables to config.status. - if test "$ac_new_set" = set; then - case $ac_new_val in - *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; - *) ac_arg=$ac_var=$ac_new_val ;; - esac - case " $ac_configure_args " in - *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. - *) as_fn_append ac_configure_args " '$ac_arg'" ;; - esac - fi -done -if $ac_cache_corrupted; then - { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 -$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} - as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 -fi -## -------------------- ## -## Main body of script. ## -## -------------------- ## - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - -am__api_version='1.11' - -ac_aux_dir= -for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do - for ac_t in install-sh install.sh shtool; do - if test -f "$ac_dir/$ac_t"; then - ac_aux_dir=$ac_dir - ac_install_sh="$ac_aux_dir/$ac_t -c" - break 2 - fi - done -done -if test -z "$ac_aux_dir"; then - as_fn_error "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5 -fi - -# These three variables are undocumented and unsupported, -# and are intended to be withdrawn in a future Autoconf release. -# They can cause serious problems if a builder's source tree is in a directory -# whose full name contains unusual characters. -ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. -ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. -ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. - - -# Find a good install program. We prefer a C program (faster), -# so one script is as good as another. But avoid the broken or -# incompatible versions: -# SysV /etc/install, /usr/sbin/install -# SunOS /usr/etc/install -# IRIX /sbin/install -# AIX /bin/install -# AmigaOS /C/install, which installs bootblocks on floppy discs -# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag -# AFS /usr/afsws/bin/install, which mishandles nonexistent args -# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" -# OS/2's system install, which has a completely different semantic -# ./install, which can be erroneously created by make from ./install.sh. -# Reject install programs that cannot install multiple files. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 -$as_echo_n "checking for a BSD-compatible install... " >&6; } -if test -z "$INSTALL"; then -if test "${ac_cv_path_install+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - # Account for people who put trailing slashes in PATH elements. -case $as_dir/ in #(( - ./ | .// | /[cC]/* | \ - /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ - ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ - /usr/ucb/* ) ;; - *) - # OSF1 and SCO ODT 3.0 have their own names for install. - # Don't use installbsd from OSF since it installs stuff as root - # by default. - for ac_prog in ginstall scoinst install; do - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then - if test $ac_prog = install && - grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then - # AIX install. It has an incompatible calling convention. - : - elif test $ac_prog = install && - grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then - # program-specific install script used by HP pwplus--don't use. - : - else - rm -rf conftest.one conftest.two conftest.dir - echo one > conftest.one - echo two > conftest.two - mkdir conftest.dir - if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && - test -s conftest.one && test -s conftest.two && - test -s conftest.dir/conftest.one && - test -s conftest.dir/conftest.two - then - ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" - break 3 - fi - fi - fi - done - done - ;; -esac - - done -IFS=$as_save_IFS - -rm -rf conftest.one conftest.two conftest.dir - -fi - if test "${ac_cv_path_install+set}" = set; then - INSTALL=$ac_cv_path_install - else - # As a last resort, use the slow shell script. Don't cache a - # value for INSTALL within a source directory, because that will - # break other packages using the cache if that directory is - # removed, or if the value is a relative name. - INSTALL=$ac_install_sh - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 -$as_echo "$INSTALL" >&6; } - -# Use test -z because SunOS4 sh mishandles braces in ${var-val}. -# It thinks the first close brace ends the variable substitution. -test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' - -test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' - -test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 -$as_echo_n "checking whether build environment is sane... " >&6; } -# Just in case -sleep 1 -echo timestamp > conftest.file -# Reject unsafe characters in $srcdir or the absolute working directory -# name. Accept space and tab only in the latter. -am_lf=' -' -case `pwd` in - *[\\\"\#\$\&\'\`$am_lf]*) - as_fn_error "unsafe absolute working directory name" "$LINENO" 5;; -esac -case $srcdir in - *[\\\"\#\$\&\'\`$am_lf\ \ ]*) - as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;; -esac - -# Do `set' in a subshell so we don't clobber the current shell's -# arguments. Must try -L first in case configure is actually a -# symlink; some systems play weird games with the mod time of symlinks -# (eg FreeBSD returns the mod time of the symlink's containing -# directory). -if ( - set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` - if test "$*" = "X"; then - # -L didn't work. - set X `ls -t "$srcdir/configure" conftest.file` - fi - rm -f conftest.file - if test "$*" != "X $srcdir/configure conftest.file" \ - && test "$*" != "X conftest.file $srcdir/configure"; then - - # If neither matched, then we have a broken ls. This can happen - # if, for instance, CONFIG_SHELL is bash and it inherits a - # broken ls alias from the environment. This has actually - # happened. Such a system could not be considered "sane". - as_fn_error "ls -t appears to fail. Make sure there is not a broken -alias in your environment" "$LINENO" 5 - fi - - test "$2" = conftest.file - ) -then - # Ok. - : -else - as_fn_error "newly created file is older than distributed files! -Check your system clock" "$LINENO" 5 -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -test "$program_prefix" != NONE && - program_transform_name="s&^&$program_prefix&;$program_transform_name" -# Use a double $ so make ignores it. -test "$program_suffix" != NONE && - program_transform_name="s&\$&$program_suffix&;$program_transform_name" -# Double any \ or $. -# By default was `s,x,x', remove it if useless. -ac_script='s/[\\$]/&&/g;s/;s,x,x,$//' -program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"` - -# expand $ac_aux_dir to an absolute path -am_aux_dir=`cd $ac_aux_dir && pwd` - -if test x"${MISSING+set}" != xset; then - case $am_aux_dir in - *\ * | *\ *) - MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; - *) - MISSING="\${SHELL} $am_aux_dir/missing" ;; - esac -fi -# Use eval to expand $SHELL -if eval "$MISSING --run true"; then - am_missing_run="$MISSING --run " -else - am_missing_run= - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5 -$as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;} -fi - -if test x"${install_sh}" != xset; then - case $am_aux_dir in - *\ * | *\ *) - install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; - *) - install_sh="\${SHELL} $am_aux_dir/install-sh" - esac -fi - -# Installed binaries are usually stripped using `strip' when the user -# run `make install-strip'. However `strip' might not be the right -# tool to use in cross-compilation environments, therefore Automake -# will honor the `STRIP' environment variable to overrule this program. -if test "$cross_compiling" != no; then - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. -set dummy ${ac_tool_prefix}strip; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_STRIP+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$STRIP"; then - ac_cv_prog_STRIP="$STRIP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_STRIP="${ac_tool_prefix}strip" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -STRIP=$ac_cv_prog_STRIP -if test -n "$STRIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 -$as_echo "$STRIP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_STRIP"; then - ac_ct_STRIP=$STRIP - # Extract the first word of "strip", so it can be a program name with args. -set dummy strip; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_STRIP"; then - ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_STRIP="strip" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP -if test -n "$ac_ct_STRIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 -$as_echo "$ac_ct_STRIP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_STRIP" = x; then - STRIP=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - STRIP=$ac_ct_STRIP - fi -else - STRIP="$ac_cv_prog_STRIP" -fi - -fi -INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5 -$as_echo_n "checking for a thread-safe mkdir -p... " >&6; } -if test -z "$MKDIR_P"; then - if test "${ac_cv_path_mkdir+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in mkdir gmkdir; do - for ac_exec_ext in '' $ac_executable_extensions; do - { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue - case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #( - 'mkdir (GNU coreutils) '* | \ - 'mkdir (coreutils) '* | \ - 'mkdir (fileutils) '4.1*) - ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext - break 3;; - esac - done - done - done -IFS=$as_save_IFS - -fi - - test -d ./--version && rmdir ./--version - if test "${ac_cv_path_mkdir+set}" = set; then - MKDIR_P="$ac_cv_path_mkdir -p" - else - # As a last resort, use the slow shell script. Don't cache a - # value for MKDIR_P within a source directory, because that will - # break other packages using the cache if that directory is - # removed, or if the value is a relative name. - MKDIR_P="$ac_install_sh -d" - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 -$as_echo "$MKDIR_P" >&6; } - -mkdir_p="$MKDIR_P" -case $mkdir_p in - [\\/$]* | ?:[\\/]*) ;; - */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; -esac - -for ac_prog in gawk mawk nawk awk -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_AWK+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$AWK"; then - ac_cv_prog_AWK="$AWK" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_AWK="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -AWK=$ac_cv_prog_AWK -if test -n "$AWK"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 -$as_echo "$AWK" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$AWK" && break -done - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 -$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } -set x ${MAKE-make} -ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` -if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then : - $as_echo_n "(cached) " >&6 -else - cat >conftest.make <<\_ACEOF -SHELL = /bin/sh -all: - @echo '@@@%%%=$(MAKE)=@@@%%%' -_ACEOF -# GNU make sometimes prints "make[1]: Entering...", which would confuse us. -case `${MAKE-make} -f conftest.make 2>/dev/null` in - *@@@%%%=?*=@@@%%%*) - eval ac_cv_prog_make_${ac_make}_set=yes;; - *) - eval ac_cv_prog_make_${ac_make}_set=no;; -esac -rm -f conftest.make -fi -if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - SET_MAKE= -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - SET_MAKE="MAKE=${MAKE-make}" -fi - -rm -rf .tst 2>/dev/null -mkdir .tst 2>/dev/null -if test -d .tst; then - am__leading_dot=. -else - am__leading_dot=_ -fi -rmdir .tst 2>/dev/null - -if test "`cd $srcdir && pwd`" != "`pwd`"; then - # Use -I$(srcdir) only when $(srcdir) != ., so that make's output - # is not polluted with repeated "-I." - am__isrc=' -I$(srcdir)' - # test to see if srcdir already configured - if test -f $srcdir/config.status; then - as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5 - fi -fi - -# test whether we have cygpath -if test -z "$CYGPATH_W"; then - if (cygpath --version) >/dev/null 2>/dev/null; then - CYGPATH_W='cygpath -w' - else - CYGPATH_W=echo - fi -fi - - -# Define the identity of the package. - PACKAGE=arlib - VERSION=1.0 - - -cat >>confdefs.h <<_ACEOF -#define PACKAGE "$PACKAGE" -_ACEOF - - -cat >>confdefs.h <<_ACEOF -#define VERSION "$VERSION" -_ACEOF - -# Some tools Automake needs. - -ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"} - - -AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"} - - -AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"} - - -AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} - - -MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} - -# We need awk for the "check" target. The system "awk" is bad on -# some platforms. -# Always define AMTAR for backward compatibility. - -AMTAR=${AMTAR-"${am_missing_run}tar"} - -am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -' - - - - - - -#AM_CONFIG_HEADER([config.h]) - -# Checks for programs. -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. -set dummy ${ac_tool_prefix}gcc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_CC="${ac_tool_prefix}gcc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_CC"; then - ac_ct_CC=$CC - # Extract the first word of "gcc", so it can be a program name with args. -set dummy gcc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_CC="gcc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 -$as_echo "$ac_ct_CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -else - CC="$ac_cv_prog_CC" -fi - -if test -z "$CC"; then - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. -set dummy ${ac_tool_prefix}cc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_CC="${ac_tool_prefix}cc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - fi -fi -if test -z "$CC"; then - # Extract the first word of "cc", so it can be a program name with args. -set dummy cc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else - ac_prog_rejected=no -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then - ac_prog_rejected=yes - continue - fi - ac_cv_prog_CC="cc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -if test $ac_prog_rejected = yes; then - # We found a bogon in the path, so make sure we never use it. - set dummy $ac_cv_prog_CC - shift - if test $# != 0; then - # We chose a different compiler from the bogus one. - # However, it has the same basename, so the bogon will be chosen - # first if we set CC to just the basename; use the full file name. - shift - ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" - fi -fi -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$CC"; then - if test -n "$ac_tool_prefix"; then - for ac_prog in cl.exe - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_CC="$ac_tool_prefix$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$CC" && break - done -fi -if test -z "$CC"; then - ac_ct_CC=$CC - for ac_prog in cl.exe -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_CC="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 -$as_echo "$ac_ct_CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$ac_ct_CC" && break -done - - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -fi - -fi - - -test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error "no acceptable C compiler found in \$PATH -See \`config.log' for more details." "$LINENO" 5; } - -# Provide some information about the compiler. -$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 -set X $ac_compile -ac_compiler=$2 -for ac_option in --version -v -V -qversion; do - { { ac_try="$ac_compiler $ac_option >&5" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_compiler $ac_option >&5") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - sed '10a\ -... rest of stderr output deleted ... - 10q' conftest.err >conftest.er1 - cat conftest.er1 >&5 - fi - rm -f conftest.er1 conftest.err - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } -done - -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -ac_clean_files_save=$ac_clean_files -ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" -# Try to create an executable without -o first, disregard a.out. -# It will help us diagnose broken compilers, and finding out an intuition -# of exeext. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 -$as_echo_n "checking whether the C compiler works... " >&6; } -ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` - -# The possible output files: -ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" - -ac_rmfiles= -for ac_file in $ac_files -do - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; - * ) ac_rmfiles="$ac_rmfiles $ac_file";; - esac -done -rm -f $ac_rmfiles - -if { { ac_try="$ac_link_default" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link_default") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then : - # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. -# So ignore a value of `no', otherwise this would lead to `EXEEXT = no' -# in a Makefile. We should not override ac_cv_exeext if it was cached, -# so that the user can short-circuit this test for compilers unknown to -# Autoconf. -for ac_file in $ac_files '' -do - test -f "$ac_file" || continue - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) - ;; - [ab].out ) - # We found the default executable, but exeext='' is most - # certainly right. - break;; - *.* ) - if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; - then :; else - ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` - fi - # We set ac_cv_exeext here because the later test for it is not - # safe: cross compilers may not add the suffix if given an `-o' - # argument, so we may need to know it at that point already. - # Even if this section looks crufty: it has the advantage of - # actually working. - break;; - * ) - break;; - esac -done -test "$ac_cv_exeext" = no && ac_cv_exeext= - -else - ac_file='' -fi -if test -z "$ac_file"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "C compiler cannot create executables -See \`config.log' for more details." "$LINENO" 5; }; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 -$as_echo_n "checking for C compiler default output file name... " >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 -$as_echo "$ac_file" >&6; } -ac_exeext=$ac_cv_exeext - -rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out -ac_clean_files=$ac_clean_files_save -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 -$as_echo_n "checking for suffix of executables... " >&6; } -if { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then : - # If both `conftest.exe' and `conftest' are `present' (well, observable) -# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will -# work properly (i.e., refer to `conftest.exe'), while it won't with -# `rm'. -for ac_file in conftest.exe conftest conftest.*; do - test -f "$ac_file" || continue - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; - *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` - break;; - * ) break;; - esac -done -else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error "cannot compute suffix of executables: cannot compile and link -See \`config.log' for more details." "$LINENO" 5; } -fi -rm -f conftest conftest$ac_cv_exeext -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 -$as_echo "$ac_cv_exeext" >&6; } - -rm -f conftest.$ac_ext -EXEEXT=$ac_cv_exeext -ac_exeext=$EXEEXT -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -int -main () -{ -FILE *f = fopen ("conftest.out", "w"); - return ferror (f) || fclose (f) != 0; - - ; - return 0; -} -_ACEOF -ac_clean_files="$ac_clean_files conftest.out" -# Check that the compiler produces executables we can run. If not, either -# the compiler is broken, or we cross compile. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 -$as_echo_n "checking whether we are cross compiling... " >&6; } -if test "$cross_compiling" != yes; then - { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - if { ac_try='./conftest$ac_cv_exeext' - { { case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; }; then - cross_compiling=no - else - if test "$cross_compiling" = maybe; then - cross_compiling=yes - else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error "cannot run C compiled programs. -If you meant to cross compile, use \`--host'. -See \`config.log' for more details." "$LINENO" 5; } - fi - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 -$as_echo "$cross_compiling" >&6; } - -rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out -ac_clean_files=$ac_clean_files_save -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 -$as_echo_n "checking for suffix of object files... " >&6; } -if test "${ac_cv_objext+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.o conftest.obj -if { { ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_compile") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then : - for ac_file in conftest.o conftest.obj conftest.*; do - test -f "$ac_file" || continue; - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; - *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` - break;; - esac -done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error "cannot compute suffix of object files: cannot compile -See \`config.log' for more details." "$LINENO" 5; } -fi -rm -f conftest.$ac_cv_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 -$as_echo "$ac_cv_objext" >&6; } -OBJEXT=$ac_cv_objext -ac_objext=$OBJEXT -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 -$as_echo_n "checking whether we are using the GNU C compiler... " >&6; } -if test "${ac_cv_c_compiler_gnu+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ -#ifndef __GNUC__ - choke me -#endif - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_compiler_gnu=yes -else - ac_compiler_gnu=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -ac_cv_c_compiler_gnu=$ac_compiler_gnu - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 -$as_echo "$ac_cv_c_compiler_gnu" >&6; } -if test $ac_compiler_gnu = yes; then - GCC=yes -else - GCC= -fi -ac_test_CFLAGS=${CFLAGS+set} -ac_save_CFLAGS=$CFLAGS -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 -$as_echo_n "checking whether $CC accepts -g... " >&6; } -if test "${ac_cv_prog_cc_g+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_save_c_werror_flag=$ac_c_werror_flag - ac_c_werror_flag=yes - ac_cv_prog_cc_g=no - CFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_g=yes -else - CFLAGS="" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - -else - ac_c_werror_flag=$ac_save_c_werror_flag - CFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_g=yes -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - ac_c_werror_flag=$ac_save_c_werror_flag -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 -$as_echo "$ac_cv_prog_cc_g" >&6; } -if test "$ac_test_CFLAGS" = set; then - CFLAGS=$ac_save_CFLAGS -elif test $ac_cv_prog_cc_g = yes; then - if test "$GCC" = yes; then - CFLAGS="-g -O2" - else - CFLAGS="-g" - fi -else - if test "$GCC" = yes; then - CFLAGS="-O2" - else - CFLAGS= - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 -$as_echo_n "checking for $CC option to accept ISO C89... " >&6; } -if test "${ac_cv_prog_cc_c89+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_prog_cc_c89=no -ac_save_CC=$CC -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#include -#include -/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ -struct buf { int x; }; -FILE * (*rcsopen) (struct buf *, struct stat *, int); -static char *e (p, i) - char **p; - int i; -{ - return p[i]; -} -static char *f (char * (*g) (char **, int), char **p, ...) -{ - char *s; - va_list v; - va_start (v,p); - s = g (p, va_arg (v,int)); - va_end (v); - return s; -} - -/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has - function prototypes and stuff, but not '\xHH' hex character constants. - These don't provoke an error unfortunately, instead are silently treated - as 'x'. The following induces an error, until -std is added to get - proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an - array size at least. It's necessary to write '\x00'==0 to get something - that's true only with -std. */ -int osf4_cc_array ['\x00' == 0 ? 1 : -1]; - -/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters - inside strings and character constants. */ -#define FOO(x) 'x' -int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; - -int test (int i, double x); -struct s1 {int (*f) (int a);}; -struct s2 {int (*f) (double a);}; -int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); -int argc; -char **argv; -int -main () -{ -return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; - ; - return 0; -} -_ACEOF -for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ - -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" -do - CC="$ac_save_CC $ac_arg" - if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_c89=$ac_arg -fi -rm -f core conftest.err conftest.$ac_objext - test "x$ac_cv_prog_cc_c89" != "xno" && break -done -rm -f conftest.$ac_ext -CC=$ac_save_CC - -fi -# AC_CACHE_VAL -case "x$ac_cv_prog_cc_c89" in - x) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -$as_echo "none needed" >&6; } ;; - xno) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -$as_echo "unsupported" >&6; } ;; - *) - CC="$CC $ac_cv_prog_cc_c89" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 -$as_echo "$ac_cv_prog_cc_c89" >&6; } ;; -esac -if test "x$ac_cv_prog_cc_c89" != xno; then : - -fi - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -DEPDIR="${am__leading_dot}deps" - -ac_config_commands="$ac_config_commands depfiles" - - -am_make=${MAKE-make} -cat > confinc << 'END' -am__doit: - @echo this is the am__doit target -.PHONY: am__doit -END -# If we don't find an include directive, just comment out the code. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5 -$as_echo_n "checking for style of include used by $am_make... " >&6; } -am__include="#" -am__quote= -_am_result=none -# First try GNU make style include. -echo "include confinc" > confmf -# Ignore all kinds of additional output from `make'. -case `$am_make -s -f confmf 2> /dev/null` in #( -*the\ am__doit\ target*) - am__include=include - am__quote= - _am_result=GNU - ;; -esac -# Now try BSD make style include. -if test "$am__include" = "#"; then - echo '.include "confinc"' > confmf - case `$am_make -s -f confmf 2> /dev/null` in #( - *the\ am__doit\ target*) - am__include=.include - am__quote="\"" - _am_result=BSD - ;; - esac -fi - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5 -$as_echo "$_am_result" >&6; } -rm -f confinc confmf - -# Check whether --enable-dependency-tracking was given. -if test "${enable_dependency_tracking+set}" = set; then : - enableval=$enable_dependency_tracking; -fi - -if test "x$enable_dependency_tracking" != xno; then - am_depcomp="$ac_aux_dir/depcomp" - AMDEPBACKSLASH='\' -fi - if test "x$enable_dependency_tracking" != xno; then - AMDEP_TRUE= - AMDEP_FALSE='#' -else - AMDEP_TRUE='#' - AMDEP_FALSE= -fi - - - -depcc="$CC" am_compiler_list= - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 -$as_echo_n "checking dependency style of $depcc... " >&6; } -if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then - # We make a subdir and do the tests there. Otherwise we can end up - # making bogus files that we don't know about and never remove. For - # instance it was reported that on HP-UX the gcc test will end up - # making a dummy file named `D' -- because `-MD' means `put the output - # in D'. - mkdir conftest.dir - # Copy depcomp to subdir because otherwise we won't find it if we're - # using a relative directory. - cp "$am_depcomp" conftest.dir - cd conftest.dir - # We will build objects and dependencies in a subdirectory because - # it helps to detect inapplicable dependency modes. For instance - # both Tru64's cc and ICC support -MD to output dependencies as a - # side effect of compilation, but ICC will put the dependencies in - # the current directory while Tru64 will put them in the object - # directory. - mkdir sub - - am_cv_CC_dependencies_compiler_type=none - if test "$am_compiler_list" = ""; then - am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` - fi - am__universal=false - case " $depcc " in #( - *\ -arch\ *\ -arch\ *) am__universal=true ;; - esac - - for depmode in $am_compiler_list; do - # Setup a source with many dependencies, because some compilers - # like to wrap large dependency lists on column 80 (with \), and - # we should not choose a depcomp mode which is confused by this. - # - # We need to recreate these files for each test, as the compiler may - # overwrite some of them when testing with obscure command lines. - # This happens at least with the AIX C compiler. - : > sub/conftest.c - for i in 1 2 3 4 5 6; do - echo '#include "conftst'$i'.h"' >> sub/conftest.c - # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with - # Solaris 8's {/usr,}/bin/sh. - touch sub/conftst$i.h - done - echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf - - # We check with `-c' and `-o' for the sake of the "dashmstdout" - # mode. It turns out that the SunPro C++ compiler does not properly - # handle `-M -o', and we need to detect this. Also, some Intel - # versions had trouble with output in subdirs - am__obj=sub/conftest.${OBJEXT-o} - am__minus_obj="-o $am__obj" - case $depmode in - gcc) - # This depmode causes a compiler race in universal mode. - test "$am__universal" = false || continue - ;; - nosideeffect) - # after this tag, mechanisms are not by side-effect, so they'll - # only be used when explicitly requested - if test "x$enable_dependency_tracking" = xyes; then - continue - else - break - fi - ;; - msvisualcpp | msvcmsys) - # This compiler won't grok `-c -o', but also, the minuso test has - # not run yet. These depmodes are late enough in the game, and - # so weak that their functioning should not be impacted. - am__obj=conftest.${OBJEXT-o} - am__minus_obj= - ;; - none) break ;; - esac - if depmode=$depmode \ - source=sub/conftest.c object=$am__obj \ - depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ - $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ - >/dev/null 2>conftest.err && - grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && - grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && - grep $am__obj sub/conftest.Po > /dev/null 2>&1 && - ${MAKE-make} -s -f confmf > /dev/null 2>&1; then - # icc doesn't choke on unknown options, it will just issue warnings - # or remarks (even with -Werror). So we grep stderr for any message - # that says an option was ignored or not supported. - # When given -MP, icc 7.0 and 7.1 complain thusly: - # icc: Command line warning: ignoring option '-M'; no argument required - # The diagnosis changed in icc 8.0: - # icc: Command line remark: option '-MP' not supported - if (grep 'ignoring option' conftest.err || - grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else - am_cv_CC_dependencies_compiler_type=$depmode - break - fi - fi - done - - cd .. - rm -rf conftest.dir -else - am_cv_CC_dependencies_compiler_type=none -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 -$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } -CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type - - if - test "x$enable_dependency_tracking" != xno \ - && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then - am__fastdepCC_TRUE= - am__fastdepCC_FALSE='#' -else - am__fastdepCC_TRUE='#' - am__fastdepCC_FALSE= -fi - - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. -set dummy ${ac_tool_prefix}ranlib; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_RANLIB+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$RANLIB"; then - ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -RANLIB=$ac_cv_prog_RANLIB -if test -n "$RANLIB"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 -$as_echo "$RANLIB" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_RANLIB"; then - ac_ct_RANLIB=$RANLIB - # Extract the first word of "ranlib", so it can be a program name with args. -set dummy ranlib; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_RANLIB"; then - ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_RANLIB="ranlib" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB -if test -n "$ac_ct_RANLIB"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 -$as_echo "$ac_ct_RANLIB" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_RANLIB" = x; then - RANLIB=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - RANLIB=$ac_ct_RANLIB - fi -else - RANLIB="$ac_cv_prog_RANLIB" -fi - - -# Checks for libraries. -ac_fn_c_check_func "$LINENO" "gethostent" "ac_cv_func_gethostent" -if test "x$ac_cv_func_gethostent" = x""yes; then : - -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostent in -lnsl" >&5 -$as_echo_n "checking for gethostent in -lnsl... " >&6; } -if test "${ac_cv_lib_nsl_gethostent+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lnsl -lsocket $LIBS" - - -# ac_fn_c_try_link LINENO -# ----------------------- -# Try to link conftest.$ac_ext, and return whether this succeeded. -ac_fn_c_try_link () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - rm -f conftest.$ac_objext conftest$ac_exeext - if { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then : - ac_retval=0 -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information - # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would - # interfere with the next link command; also delete a directory that is - # left behind by Apple's compiler. We do this before executing the actions. - rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} - as_fn_set_status $ac_retval - -} # ac_fn_c_try_link -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char gethostent (); -int -main () -{ -return gethostent (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_nsl_gethostent=yes -else - ac_cv_lib_nsl_gethostent=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostent" >&5 -$as_echo "$ac_cv_lib_nsl_gethostent" >&6; } -if test "x$ac_cv_lib_nsl_gethostent" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBNSL 1 -_ACEOF - - LIBS="-lnsl $LIBS" - -fi - -fi - -ac_fn_c_check_func "$LINENO" "setsockopt" "ac_cv_func_setsockopt" -if test "x$ac_cv_func_setsockopt" = x""yes; then : - -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for setsockopt in -lsocket" >&5 -$as_echo_n "checking for setsockopt in -lsocket... " >&6; } -if test "${ac_cv_lib_socket_setsockopt+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lsocket $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char setsockopt (); -int -main () -{ -return setsockopt (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_socket_setsockopt=yes -else - ac_cv_lib_socket_setsockopt=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_setsockopt" >&5 -$as_echo "$ac_cv_lib_socket_setsockopt" >&6; } -if test "x$ac_cv_lib_socket_setsockopt" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBSOCKET 1 -_ACEOF - - LIBS="-lsocket $LIBS" - -fi - -fi - -ac_fn_c_check_func "$LINENO" "res_init" "ac_cv_func_res_init" -if test "x$ac_cv_func_res_init" = x""yes; then : - -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init in -lresolv" >&5 -$as_echo_n "checking for res_init in -lresolv... " >&6; } -if test "${ac_cv_lib_resolv_res_init+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lresolv $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char res_init (); -int -main () -{ -return res_init (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_resolv_res_init=yes -else - ac_cv_lib_resolv_res_init=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_init" >&5 -$as_echo "$ac_cv_lib_resolv_res_init" >&6; } -if test "x$ac_cv_lib_resolv_res_init" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBRESOLV 1 -_ACEOF - - LIBS="-lresolv $LIBS" - -fi - -fi - - -# Checks for header files. - -# Checks for typedefs, structures, and compiler characteristics. - -ac_fn_c_check_type "$LINENO" "u_int32_t" "ac_cv_type_u_int32_t" " -#include -#include -" -if test "x$ac_cv_type_u_int32_t" = x""yes; then : - -else - -$as_echo "#define u_int32_t unsigned int" >>confdefs.h - -fi - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for name of NS address list" >&5 -$as_echo_n "checking for name of NS address list... " >&6; } -if test "${ac_cv_var_ns_addr_list+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ans='' -# Normal -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -#include -#include -#include -#include -int -main () -{ - return sizeof(_res.nsaddr_list); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ans=nsaddr_list -else - # Ultrix -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -#include -#include -#include -#include -int -main () -{ - return sizeof(_res.ns_list); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ans=ns_list -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - case "$ans" in - '') { $as_echo "$as_me:${as_lineno-$LINENO}: result: ???" >&5 -$as_echo "???" >&6; } - as_fn_error "Can't find nameserver address list in _res" "$LINENO" 5 - ;; - esac - ac_cv_var_ns_addr_list=$ans -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_ns_addr_list" >&5 -$as_echo "$ac_cv_var_ns_addr_list" >&6; } - -cat >>confdefs.h <<_ACEOF -#define NS_ADDR_LIST $ans -_ACEOF - - -# Checks for library functions. - -ac_config_files="$ac_config_files Makefile" - -cat >confcache <<\_ACEOF -# This file is a shell script that caches the results of configure -# tests run on this system so they can be shared between configure -# scripts and configure runs, see configure's option --config-cache. -# It is not useful on other systems. If it contains results you don't -# want to keep, you may remove or edit it. -# -# config.status only pays attention to the cache file if you give it -# the --recheck option to rerun configure. -# -# `ac_cv_env_foo' variables (set or unset) will be overridden when -# loading this file, other *unset* `ac_cv_foo' will be assigned the -# following values. - -_ACEOF - -# The following way of writing the cache mishandles newlines in values, -# but we know of no workaround that is simple, portable, and efficient. -# So, we kill variables containing newlines. -# Ultrix sh set writes to stderr and can't be redirected directly, -# and sets the high bit in the cache file unless we assign to the vars. -( - for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do - eval ac_val=\$$ac_var - case $ac_val in #( - *${as_nl}*) - case $ac_var in #( - *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 -$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; - esac - case $ac_var in #( - _ | IFS | as_nl) ;; #( - BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( - *) { eval $ac_var=; unset $ac_var;} ;; - esac ;; - esac - done - - (set) 2>&1 | - case $as_nl`(ac_space=' '; set) 2>&1` in #( - *${as_nl}ac_space=\ *) - # `set' does not quote correctly, so add quotes: double-quote - # substitution turns \\\\ into \\, and sed turns \\ into \. - sed -n \ - "s/'/'\\\\''/g; - s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" - ;; #( - *) - # `set' quotes correctly as required by POSIX, so do not add quotes. - sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" - ;; - esac | - sort -) | - sed ' - /^ac_cv_env_/b end - t clear - :clear - s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ - t end - s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ - :end' >>confcache -if diff "$cache_file" confcache >/dev/null 2>&1; then :; else - if test -w "$cache_file"; then - test "x$cache_file" != "x/dev/null" && - { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 -$as_echo "$as_me: updating cache $cache_file" >&6;} - cat confcache >$cache_file - else - { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 -$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} - fi -fi -rm -f confcache - -test "x$prefix" = xNONE && prefix=$ac_default_prefix -# Let make expand exec_prefix. -test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' - -# Transform confdefs.h into DEFS. -# Protect against shell expansion while executing Makefile rules. -# Protect against Makefile macro expansion. -# -# If the first sed substitution is executed (which looks for macros that -# take arguments), then branch to the quote section. Otherwise, -# look for a macro that doesn't take arguments. -ac_script=' -:mline -/\\$/{ - N - s,\\\n,, - b mline -} -t clear -:clear -s/^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\)/-D\1=\2/g -t quote -s/^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)/-D\1=\2/g -t quote -b any -:quote -s/[ `~#$^&*(){}\\|;'\''"<>?]/\\&/g -s/\[/\\&/g -s/\]/\\&/g -s/\$/$$/g -H -:any -${ - g - s/^\n// - s/\n/ /g - p -} -' -DEFS=`sed -n "$ac_script" confdefs.h` - - -ac_libobjs= -ac_ltlibobjs= -for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue - # 1. Remove the extension, and $U if already installed. - ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' - ac_i=`$as_echo "$ac_i" | sed "$ac_script"` - # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR - # will be set to the directory where LIBOBJS objects are built. - as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" - as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' -done -LIBOBJS=$ac_libobjs - -LTLIBOBJS=$ac_ltlibobjs - - - if test -n "$EXEEXT"; then - am__EXEEXT_TRUE= - am__EXEEXT_FALSE='#' -else - am__EXEEXT_TRUE='#' - am__EXEEXT_FALSE= -fi - -if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then - as_fn_error "conditional \"AMDEP\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then - as_fn_error "conditional \"am__fastdepCC\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi - -: ${CONFIG_STATUS=./config.status} -ac_write_fail=0 -ac_clean_files_save=$ac_clean_files -ac_clean_files="$ac_clean_files $CONFIG_STATUS" -{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 -$as_echo "$as_me: creating $CONFIG_STATUS" >&6;} -as_write_fail=0 -cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 -#! $SHELL -# Generated by $as_me. -# Run this file to recreate the current configuration. -# Compiler output produced by configure, useful for debugging -# configure, is in config.log if it exists. - -debug=false -ac_cs_recheck=false -ac_cs_silent=false - -SHELL=\${CONFIG_SHELL-$SHELL} -export SHELL -_ASEOF -cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 -## -------------------- ## -## M4sh Initialization. ## -## -------------------- ## - -# Be more Bourne compatible -DUALCASE=1; export DUALCASE # for MKS sh -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in #( - *posix*) : - set -o posix ;; #( - *) : - ;; -esac -fi - - -as_nl=' -' -export as_nl -# Printing a long string crashes Solaris 7 /usr/bin/printf. -as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo -# Prefer a ksh shell builtin over an external printf program on Solaris, -# but without wasting forks for bash or zsh. -if test -z "$BASH_VERSION$ZSH_VERSION" \ - && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='print -r --' - as_echo_n='print -rn --' -elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='printf %s\n' - as_echo_n='printf %s' -else - if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then - as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' - as_echo_n='/usr/ucb/echo -n' - else - as_echo_body='eval expr "X$1" : "X\\(.*\\)"' - as_echo_n_body='eval - arg=$1; - case $arg in #( - *"$as_nl"*) - expr "X$arg" : "X\\(.*\\)$as_nl"; - arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; - esac; - expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" - ' - export as_echo_n_body - as_echo_n='sh -c $as_echo_n_body as_echo' - fi - export as_echo_body - as_echo='sh -c $as_echo_body as_echo' -fi - -# The user is always right. -if test "${PATH_SEPARATOR+set}" != set; then - PATH_SEPARATOR=: - (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { - (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || - PATH_SEPARATOR=';' - } -fi - - -# IFS -# We need space, tab and new line, in precisely that order. Quoting is -# there to prevent editors from complaining about space-tab. -# (If _AS_PATH_WALK were called with IFS unset, it would disable word -# splitting by setting IFS to empty value.) -IFS=" "" $as_nl" - -# Find who we are. Look in the path if we contain no directory separator. -case $0 in #(( - *[\\/]* ) as_myself=$0 ;; - *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break - done -IFS=$as_save_IFS - - ;; -esac -# We did not find ourselves, most probably we were run as `sh COMMAND' -# in which case we are not to be found in the path. -if test "x$as_myself" = x; then - as_myself=$0 -fi -if test ! -f "$as_myself"; then - $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 - exit 1 -fi - -# Unset variables that we do not need and which cause bugs (e.g. in -# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" -# suppresses any "Segmentation fault" message there. '((' could -# trigger a bug in pdksh 5.2.14. -for as_var in BASH_ENV ENV MAIL MAILPATH -do eval test x\${$as_var+set} = xset \ - && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : -done -PS1='$ ' -PS2='> ' -PS4='+ ' - -# NLS nuisances. -LC_ALL=C -export LC_ALL -LANGUAGE=C -export LANGUAGE - -# CDPATH. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - - -# as_fn_error ERROR [LINENO LOG_FD] -# --------------------------------- -# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are -# provided, also output the error to LOG_FD, referencing LINENO. Then exit the -# script with status $?, using 1 if that was 0. -as_fn_error () -{ - as_status=$?; test $as_status -eq 0 && as_status=1 - if test "$3"; then - as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3 - fi - $as_echo "$as_me: error: $1" >&2 - as_fn_exit $as_status -} # as_fn_error - - -# as_fn_set_status STATUS -# ----------------------- -# Set $? to STATUS, without forking. -as_fn_set_status () -{ - return $1 -} # as_fn_set_status - -# as_fn_exit STATUS -# ----------------- -# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. -as_fn_exit () -{ - set +e - as_fn_set_status $1 - exit $1 -} # as_fn_exit - -# as_fn_unset VAR -# --------------- -# Portably unset VAR. -as_fn_unset () -{ - { eval $1=; unset $1;} -} -as_unset=as_fn_unset -# as_fn_append VAR VALUE -# ---------------------- -# Append the text in VALUE to the end of the definition contained in VAR. Take -# advantage of any shell optimizations that allow amortized linear growth over -# repeated appends, instead of the typical quadratic growth present in naive -# implementations. -if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : - eval 'as_fn_append () - { - eval $1+=\$2 - }' -else - as_fn_append () - { - eval $1=\$$1\$2 - } -fi # as_fn_append - -# as_fn_arith ARG... -# ------------------ -# Perform arithmetic evaluation on the ARGs, and store the result in the -# global $as_val. Take advantage of shells that can avoid forks. The arguments -# must be portable across $(()) and expr. -if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : - eval 'as_fn_arith () - { - as_val=$(( $* )) - }' -else - as_fn_arith () - { - as_val=`expr "$@" || test $? -eq 1` - } -fi # as_fn_arith - - -if expr a : '\(a\)' >/dev/null 2>&1 && - test "X`expr 00001 : '.*\(...\)'`" = X001; then - as_expr=expr -else - as_expr=false -fi - -if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then - as_basename=basename -else - as_basename=false -fi - -if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then - as_dirname=dirname -else - as_dirname=false -fi - -as_me=`$as_basename -- "$0" || -$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ - X"$0" : 'X\(//\)$' \| \ - X"$0" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X/"$0" | - sed '/^.*\/\([^/][^/]*\)\/*$/{ - s//\1/ - q - } - /^X\/\(\/\/\)$/{ - s//\1/ - q - } - /^X\/\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - -# Avoid depending upon Character Ranges. -as_cr_letters='abcdefghijklmnopqrstuvwxyz' -as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' -as_cr_Letters=$as_cr_letters$as_cr_LETTERS -as_cr_digits='0123456789' -as_cr_alnum=$as_cr_Letters$as_cr_digits - -ECHO_C= ECHO_N= ECHO_T= -case `echo -n x` in #((((( --n*) - case `echo 'xy\c'` in - *c*) ECHO_T=' ';; # ECHO_T is single tab character. - xy) ECHO_C='\c';; - *) echo `echo ksh88 bug on AIX 6.1` > /dev/null - ECHO_T=' ';; - esac;; -*) - ECHO_N='-n';; -esac - -rm -f conf$$ conf$$.exe conf$$.file -if test -d conf$$.dir; then - rm -f conf$$.dir/conf$$.file -else - rm -f conf$$.dir - mkdir conf$$.dir 2>/dev/null -fi -if (echo >conf$$.file) 2>/dev/null; then - if ln -s conf$$.file conf$$ 2>/dev/null; then - as_ln_s='ln -s' - # ... but there are two gotchas: - # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. - # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -p'. - ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || - as_ln_s='cp -p' - elif ln conf$$.file conf$$ 2>/dev/null; then - as_ln_s=ln - else - as_ln_s='cp -p' - fi -else - as_ln_s='cp -p' -fi -rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file -rmdir conf$$.dir 2>/dev/null - - -# as_fn_mkdir_p -# ------------- -# Create "$as_dir" as a directory, including parents if necessary. -as_fn_mkdir_p () -{ - - case $as_dir in #( - -*) as_dir=./$as_dir;; - esac - test -d "$as_dir" || eval $as_mkdir_p || { - as_dirs= - while :; do - case $as_dir in #( - *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( - *) as_qdir=$as_dir;; - esac - as_dirs="'$as_qdir' $as_dirs" - as_dir=`$as_dirname -- "$as_dir" || -$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_dir" : 'X\(//\)[^/]' \| \ - X"$as_dir" : 'X\(//\)$' \| \ - X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_dir" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - test -d "$as_dir" && break - done - test -z "$as_dirs" || eval "mkdir $as_dirs" - } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir" - - -} # as_fn_mkdir_p -if mkdir -p . 2>/dev/null; then - as_mkdir_p='mkdir -p "$as_dir"' -else - test -d ./-p && rmdir ./-p - as_mkdir_p=false -fi - -if test -x / >/dev/null 2>&1; then - as_test_x='test -x' -else - if ls -dL / >/dev/null 2>&1; then - as_ls_L_option=L - else - as_ls_L_option= - fi - as_test_x=' - eval sh -c '\'' - if test -d "$1"; then - test -d "$1/."; - else - case $1 in #( - -*)set "./$1";; - esac; - case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( - ???[sx]*):;;*)false;;esac;fi - '\'' sh - ' -fi -as_executable_p=$as_test_x - -# Sed expression to map a string onto a valid CPP name. -as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" - -# Sed expression to map a string onto a valid variable name. -as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" - - -exec 6>&1 -## ----------------------------------- ## -## Main body of $CONFIG_STATUS script. ## -## ----------------------------------- ## -_ASEOF -test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# Save the log message, to keep $0 and so on meaningful, and to -# report actual input values of CONFIG_FILES etc. instead of their -# values after options handling. -ac_log=" -This file was extended by $as_me, which was -generated by GNU Autoconf 2.65. Invocation command line was - - CONFIG_FILES = $CONFIG_FILES - CONFIG_HEADERS = $CONFIG_HEADERS - CONFIG_LINKS = $CONFIG_LINKS - CONFIG_COMMANDS = $CONFIG_COMMANDS - $ $0 $@ - -on `(hostname || uname -n) 2>/dev/null | sed 1q` -" - -_ACEOF - -case $ac_config_files in *" -"*) set x $ac_config_files; shift; ac_config_files=$*;; -esac - - - -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -# Files that config.status was made for. -config_files="$ac_config_files" -config_commands="$ac_config_commands" - -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -ac_cs_usage="\ -\`$as_me' instantiates files and other configuration actions -from templates according to the current configuration. Unless the files -and actions are specified as TAGs, all are instantiated by default. - -Usage: $0 [OPTION]... [TAG]... - - -h, --help print this help, then exit - -V, --version print version number and configuration settings, then exit - --config print configuration, then exit - -q, --quiet, --silent - do not print progress messages - -d, --debug don't remove temporary files - --recheck update $as_me by reconfiguring in the same conditions - --file=FILE[:TEMPLATE] - instantiate the configuration file FILE - -Configuration files: -$config_files - -Configuration commands: -$config_commands - -Report bugs to the package provider." - -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" -ac_cs_version="\\ -config.status -configured by $0, generated by GNU Autoconf 2.65, - with options \\"\$ac_cs_config\\" - -Copyright (C) 2009 Free Software Foundation, Inc. -This config.status script is free software; the Free Software Foundation -gives unlimited permission to copy, distribute and modify it." - -ac_pwd='$ac_pwd' -srcdir='$srcdir' -INSTALL='$INSTALL' -MKDIR_P='$MKDIR_P' -AWK='$AWK' -test -n "\$AWK" || AWK=awk -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# The default lists apply if the user does not specify any file. -ac_need_defaults=: -while test $# != 0 -do - case $1 in - --*=*) - ac_option=`expr "X$1" : 'X\([^=]*\)='` - ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` - ac_shift=: - ;; - *) - ac_option=$1 - ac_optarg=$2 - ac_shift=shift - ;; - esac - - case $ac_option in - # Handling of the options. - -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) - ac_cs_recheck=: ;; - --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) - $as_echo "$ac_cs_version"; exit ;; - --config | --confi | --conf | --con | --co | --c ) - $as_echo "$ac_cs_config"; exit ;; - --debug | --debu | --deb | --de | --d | -d ) - debug=: ;; - --file | --fil | --fi | --f ) - $ac_shift - case $ac_optarg in - *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; - esac - as_fn_append CONFIG_FILES " '$ac_optarg'" - ac_need_defaults=false;; - --he | --h | --help | --hel | -h ) - $as_echo "$ac_cs_usage"; exit ;; - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil | --si | --s) - ac_cs_silent=: ;; - - # This is an error. - -*) as_fn_error "unrecognized option: \`$1' -Try \`$0 --help' for more information." ;; - - *) as_fn_append ac_config_targets " $1" - ac_need_defaults=false ;; - - esac - shift -done - -ac_configure_extra_args= - -if $ac_cs_silent; then - exec 6>/dev/null - ac_configure_extra_args="$ac_configure_extra_args --silent" -fi - -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -if \$ac_cs_recheck; then - set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion - shift - \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 - CONFIG_SHELL='$SHELL' - export CONFIG_SHELL - exec "\$@" -fi - -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -exec 5>>config.log -{ - echo - sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX -## Running $as_me. ## -_ASBOX - $as_echo "$ac_log" -} >&5 - -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -# -# INIT-COMMANDS -# -AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" - -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 - -# Handling of arguments. -for ac_config_target in $ac_config_targets -do - case $ac_config_target in - "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; - "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; - - *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;; - esac -done - - -# If the user did not use the arguments to specify the items to instantiate, -# then the envvar interface is used. Set only those that are not. -# We use the long form for the default assignment because of an extremely -# bizarre bug on SunOS 4.1.3. -if $ac_need_defaults; then - test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files - test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands -fi - -# Have a temporary directory for convenience. Make it in the build tree -# simply because there is no reason against having it here, and in addition, -# creating and moving files from /tmp can sometimes cause problems. -# Hook for its removal unless debugging. -# Note that there is a small window in which the directory will not be cleaned: -# after its creation but before its name has been assigned to `$tmp'. -$debug || -{ - tmp= - trap 'exit_status=$? - { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status -' 0 - trap 'as_fn_exit 1' 1 2 13 15 -} -# Create a (secure) tmp directory for tmp files. - -{ - tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && - test -n "$tmp" && test -d "$tmp" -} || -{ - tmp=./conf$$-$RANDOM - (umask 077 && mkdir "$tmp") -} || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5 - -# Set up the scripts for CONFIG_FILES section. -# No need to generate them if there are no CONFIG_FILES. -# This happens for instance with `./config.status config.h'. -if test -n "$CONFIG_FILES"; then - - -ac_cr=`echo X | tr X '\015'` -# On cygwin, bash can eat \r inside `` if the user requested igncr. -# But we know of no other shell where ac_cr would be empty at this -# point, so we can use a bashism as a fallback. -if test "x$ac_cr" = x; then - eval ac_cr=\$\'\\r\' -fi -ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' /dev/null` -if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then - ac_cs_awk_cr='\r' -else - ac_cs_awk_cr=$ac_cr -fi - -echo 'BEGIN {' >"$tmp/subs1.awk" && -_ACEOF - - -{ - echo "cat >conf$$subs.awk <<_ACEOF" && - echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && - echo "_ACEOF" -} >conf$$subs.sh || - as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 -ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'` -ac_delim='%!_!# ' -for ac_last_try in false false false false false :; do - . ./conf$$subs.sh || - as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 - - ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` - if test $ac_delim_n = $ac_delim_num; then - break - elif $ac_last_try; then - as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 - else - ac_delim="$ac_delim!$ac_delim _$ac_delim!! " - fi -done -rm -f conf$$subs.sh - -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -cat >>"\$tmp/subs1.awk" <<\\_ACAWK && -_ACEOF -sed -n ' -h -s/^/S["/; s/!.*/"]=/ -p -g -s/^[^!]*!// -:repl -t repl -s/'"$ac_delim"'$// -t delim -:nl -h -s/\(.\{148\}\)..*/\1/ -t more1 -s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ -p -n -b repl -:more1 -s/["\\]/\\&/g; s/^/"/; s/$/"\\/ -p -g -s/.\{148\}// -t nl -:delim -h -s/\(.\{148\}\)..*/\1/ -t more2 -s/["\\]/\\&/g; s/^/"/; s/$/"/ -p -b -:more2 -s/["\\]/\\&/g; s/^/"/; s/$/"\\/ -p -g -s/.\{148\}// -t delim -' >$CONFIG_STATUS || ac_write_fail=1 -rm -f conf$$subs.awk -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -_ACAWK -cat >>"\$tmp/subs1.awk" <<_ACAWK && - for (key in S) S_is_set[key] = 1 - FS = "" - -} -{ - line = $ 0 - nfields = split(line, field, "@") - substed = 0 - len = length(field[1]) - for (i = 2; i < nfields; i++) { - key = field[i] - keylen = length(key) - if (S_is_set[key]) { - value = S[key] - line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) - len += length(value) + length(field[++i]) - substed = 1 - } else - len += 1 + keylen - } - - print line -} - -_ACAWK -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then - sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" -else - cat -fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \ - || as_fn_error "could not setup config files machinery" "$LINENO" 5 -_ACEOF - -# VPATH may cause trouble with some makes, so we remove $(srcdir), -# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and -# trailing colons and then remove the whole line if VPATH becomes empty -# (actually we leave an empty line to preserve line numbers). -if test "x$srcdir" = x.; then - ac_vpsub='/^[ ]*VPATH[ ]*=/{ -s/:*\$(srcdir):*/:/ -s/:*\${srcdir}:*/:/ -s/:*@srcdir@:*/:/ -s/^\([^=]*=[ ]*\):*/\1/ -s/:*$// -s/^[^=]*=[ ]*$// -}' -fi - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -fi # test -n "$CONFIG_FILES" - - -eval set X " :F $CONFIG_FILES :C $CONFIG_COMMANDS" -shift -for ac_tag -do - case $ac_tag in - :[FHLC]) ac_mode=$ac_tag; continue;; - esac - case $ac_mode$ac_tag in - :[FHL]*:*);; - :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;; - :[FH]-) ac_tag=-:-;; - :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; - esac - ac_save_IFS=$IFS - IFS=: - set x $ac_tag - IFS=$ac_save_IFS - shift - ac_file=$1 - shift - - case $ac_mode in - :L) ac_source=$1;; - :[FH]) - ac_file_inputs= - for ac_f - do - case $ac_f in - -) ac_f="$tmp/stdin";; - *) # Look for the file first in the build tree, then in the source tree - # (if the path is not absolute). The absolute path cannot be DOS-style, - # because $ac_f cannot contain `:'. - test -f "$ac_f" || - case $ac_f in - [\\/$]*) false;; - *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; - esac || - as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;; - esac - case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac - as_fn_append ac_file_inputs " '$ac_f'" - done - - # Let's still pretend it is `configure' which instantiates (i.e., don't - # use $as_me), people would be surprised to read: - # /* config.h. Generated by config.status. */ - configure_input='Generated from '` - $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' - `' by configure.' - if test x"$ac_file" != x-; then - configure_input="$ac_file. $configure_input" - { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 -$as_echo "$as_me: creating $ac_file" >&6;} - fi - # Neutralize special characters interpreted by sed in replacement strings. - case $configure_input in #( - *\&* | *\|* | *\\* ) - ac_sed_conf_input=`$as_echo "$configure_input" | - sed 's/[\\\\&|]/\\\\&/g'`;; #( - *) ac_sed_conf_input=$configure_input;; - esac - - case $ac_tag in - *:-:* | *:-) cat >"$tmp/stdin" \ - || as_fn_error "could not create $ac_file" "$LINENO" 5 ;; - esac - ;; - esac - - ac_dir=`$as_dirname -- "$ac_file" || -$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$ac_file" : 'X\(//\)[^/]' \| \ - X"$ac_file" : 'X\(//\)$' \| \ - X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$ac_file" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - as_dir="$ac_dir"; as_fn_mkdir_p - ac_builddir=. - -case "$ac_dir" in -.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; -*) - ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` - # A ".." for each directory in $ac_dir_suffix. - ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` - case $ac_top_builddir_sub in - "") ac_top_builddir_sub=. ac_top_build_prefix= ;; - *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; - esac ;; -esac -ac_abs_top_builddir=$ac_pwd -ac_abs_builddir=$ac_pwd$ac_dir_suffix -# for backward compatibility: -ac_top_builddir=$ac_top_build_prefix - -case $srcdir in - .) # We are building in place. - ac_srcdir=. - ac_top_srcdir=$ac_top_builddir_sub - ac_abs_top_srcdir=$ac_pwd ;; - [\\/]* | ?:[\\/]* ) # Absolute name. - ac_srcdir=$srcdir$ac_dir_suffix; - ac_top_srcdir=$srcdir - ac_abs_top_srcdir=$srcdir ;; - *) # Relative name. - ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix - ac_top_srcdir=$ac_top_build_prefix$srcdir - ac_abs_top_srcdir=$ac_pwd/$srcdir ;; -esac -ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix - - - case $ac_mode in - :F) - # - # CONFIG_FILE - # - - case $INSTALL in - [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; - *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; - esac - ac_MKDIR_P=$MKDIR_P - case $MKDIR_P in - [\\/$]* | ?:[\\/]* ) ;; - */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; - esac -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# If the template does not know about datarootdir, expand it. -# FIXME: This hack should be removed a few years after 2.60. -ac_datarootdir_hack=; ac_datarootdir_seen= -ac_sed_dataroot=' -/datarootdir/ { - p - q -} -/@datadir@/p -/@docdir@/p -/@infodir@/p -/@localedir@/p -/@mandir@/p' -case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in -*datarootdir*) ac_datarootdir_seen=yes;; -*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 -$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 - ac_datarootdir_hack=' - s&@datadir@&$datadir&g - s&@docdir@&$docdir&g - s&@infodir@&$infodir&g - s&@localedir@&$localedir&g - s&@mandir@&$mandir&g - s&\\\${datarootdir}&$datarootdir&g' ;; -esac -_ACEOF - -# Neutralize VPATH when `$srcdir' = `.'. -# Shell code in configure.ac might set extrasub. -# FIXME: do we really want to maintain this feature? -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -ac_sed_extra="$ac_vpsub -$extrasub -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -:t -/@[a-zA-Z_][a-zA-Z_0-9]*@/!b -s|@configure_input@|$ac_sed_conf_input|;t t -s&@top_builddir@&$ac_top_builddir_sub&;t t -s&@top_build_prefix@&$ac_top_build_prefix&;t t -s&@srcdir@&$ac_srcdir&;t t -s&@abs_srcdir@&$ac_abs_srcdir&;t t -s&@top_srcdir@&$ac_top_srcdir&;t t -s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t -s&@builddir@&$ac_builddir&;t t -s&@abs_builddir@&$ac_abs_builddir&;t t -s&@abs_top_builddir@&$ac_abs_top_builddir&;t t -s&@INSTALL@&$ac_INSTALL&;t t -s&@MKDIR_P@&$ac_MKDIR_P&;t t -$ac_datarootdir_hack -" -eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \ - || as_fn_error "could not create $ac_file" "$LINENO" 5 - -test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && - { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } && - { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } && - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' -which seems to be undefined. Please make sure it is defined." >&5 -$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' -which seems to be undefined. Please make sure it is defined." >&2;} - - rm -f "$tmp/stdin" - case $ac_file in - -) cat "$tmp/out" && rm -f "$tmp/out";; - *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";; - esac \ - || as_fn_error "could not create $ac_file" "$LINENO" 5 - ;; - - - :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 -$as_echo "$as_me: executing $ac_file commands" >&6;} - ;; - esac - - - case $ac_file$ac_mode in - "depfiles":C) test x"$AMDEP_TRUE" != x"" || { - # Autoconf 2.62 quotes --file arguments for eval, but not when files - # are listed without --file. Let's play safe and only enable the eval - # if we detect the quoting. - case $CONFIG_FILES in - *\'*) eval set x "$CONFIG_FILES" ;; - *) set x $CONFIG_FILES ;; - esac - shift - for mf - do - # Strip MF so we end up with the name of the file. - mf=`echo "$mf" | sed -e 's/:.*$//'` - # Check whether this is an Automake generated Makefile or not. - # We used to match only the files named `Makefile.in', but - # some people rename them; so instead we look at the file content. - # Grep'ing the first line is not enough: some people post-process - # each Makefile.in and add a new line on top of each file to say so. - # Grep'ing the whole file is not good either: AIX grep has a line - # limit of 2048, but all sed's we know have understand at least 4000. - if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then - dirpart=`$as_dirname -- "$mf" || -$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$mf" : 'X\(//\)[^/]' \| \ - X"$mf" : 'X\(//\)$' \| \ - X"$mf" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$mf" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - else - continue - fi - # Extract the definition of DEPDIR, am__include, and am__quote - # from the Makefile without running `make'. - DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` - test -z "$DEPDIR" && continue - am__include=`sed -n 's/^am__include = //p' < "$mf"` - test -z "am__include" && continue - am__quote=`sed -n 's/^am__quote = //p' < "$mf"` - # When using ansi2knr, U may be empty or an underscore; expand it - U=`sed -n 's/^U = //p' < "$mf"` - # Find all dependency output files, they are included files with - # $(DEPDIR) in their names. We invoke sed twice because it is the - # simplest approach to changing $(DEPDIR) to its actual value in the - # expansion. - for file in `sed -n " - s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ - sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do - # Make sure the directory exists. - test -f "$dirpart/$file" && continue - fdir=`$as_dirname -- "$file" || -$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$file" : 'X\(//\)[^/]' \| \ - X"$file" : 'X\(//\)$' \| \ - X"$file" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$file" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - as_dir=$dirpart/$fdir; as_fn_mkdir_p - # echo "creating $dirpart/$file" - echo '# dummy' > "$dirpart/$file" - done - done -} - ;; - - esac -done # for ac_tag - - -as_fn_exit 0 -_ACEOF -ac_clean_files=$ac_clean_files_save - -test $ac_write_fail = 0 || - as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5 - - -# configure is writing to config.log, and then calls config.status. -# config.status does its own redirection, appending to config.log. -# Unfortunately, on DOS this fails, as config.log is still kept open -# by configure, so config.status won't be able to write to it; its -# output is simply discarded. So we exec the FD to /dev/null, -# effectively closing config.log, so it can be properly (re)opened and -# appended to by config.status. When coming back to configure, we -# need to make the FD available again. -if test "$no_create" != yes; then - ac_cs_success=: - ac_config_status_args= - test "$silent" = yes && - ac_config_status_args="$ac_config_status_args --quiet" - exec 5>/dev/null - $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false - exec 5>>config.log - # Use ||, not &&, to avoid exiting from the if with $? = 1, which - # would make configure fail if this is the last instruction. - $ac_cs_success || as_fn_exit $? -fi -if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 -$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} -fi - diff -urN src/contrib/ntp/arlib/configure.in src.ntp/contrib/ntp/arlib/configure.in --- src/contrib/ntp/arlib/configure.in 2004-07-20 17:01:25.000000000 +0200 +++ src.ntp/contrib/ntp/arlib/configure.in 1970-01-01 01:00:00.000000000 +0100 @@ -1,57 +0,0 @@ -# Process this file with autoconf to produce a configure script. -AC_INIT -AM_INIT_AUTOMAKE(arlib, 1.0) -AC_CONFIG_SRCDIR([arlib.c]) -#AM_CONFIG_HEADER([config.h]) - -# Checks for programs. -AC_PROG_CC -AC_PROG_RANLIB - -# Checks for libraries. -AC_CHECK_FUNC(gethostent, , AC_CHECK_LIB(nsl, gethostent, , , -lsocket)) -AC_CHECK_FUNC(setsockopt, , AC_CHECK_LIB(socket, setsockopt)) -AC_CHECK_FUNC(res_init, , AC_CHECK_LIB(resolv, res_init)) - -# Checks for header files. -dnl AC_CHECK_HEADERS([errno.h fcntl.h netdb.h netinet/in.h strings.h sys/socket.h sys/time.h]) - -# Checks for typedefs, structures, and compiler characteristics. -dnl AC_HEADER_TIME - -AC_CHECK_TYPE(u_int32_t, , - [AC_DEFINE(u_int32_t, [unsigned int], [Unsigned 32-bit type])],[ -#include -#include ]) - -AC_CACHE_CHECK([for name of NS address list], [ac_cv_var_ns_addr_list], - [ans='' -# Normal -AC_TRY_COMPILE([ -#include -#include -#include -#include ], [ return sizeof(_res.nsaddr_list);], -[ans=nsaddr_list], -[# Ultrix -AC_TRY_COMPILE([ -#include -#include -#include -#include ], [ return sizeof(_res.ns_list);], -[ans=ns_list])]) - case "$ans" in - '') AC_MSG_RESULT([???]) - AC_MSG_ERROR([Can't find nameserver address list in _res]) - ;; - esac - ac_cv_var_ns_addr_list=$ans]) -AC_DEFINE_UNQUOTED(NS_ADDR_LIST, $ans, [The name of the NS address list in _res]) - -# Checks for library functions. -dnl AC_HEADER_STDC -dnl AC_FUNC_MALLOC -dnl AC_CHECK_FUNCS([bzero inet_ntoa select socket]) - -AC_CONFIG_FILES([Makefile]) -AC_OUTPUT diff -urN src/contrib/ntp/arlib/depcomp src.ntp/contrib/ntp/arlib/depcomp --- src/contrib/ntp/arlib/depcomp 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/arlib/depcomp 1970-01-01 01:00:00.000000000 +0100 @@ -1,530 +0,0 @@ -#! /bin/sh -# depcomp - compile a program generating dependencies as side-effects - -scriptversion=2005-07-09.11 - -# Copyright (C) 1999, 2000, 2003, 2004, 2005 Free Software Foundation, Inc. - -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2, or (at your option) -# any later version. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. - -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -# 02110-1301, USA. - -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - -# Originally written by Alexandre Oliva . - -case $1 in - '') - echo "$0: No command. Try \`$0 --help' for more information." 1>&2 - exit 1; - ;; - -h | --h*) - cat <<\EOF -Usage: depcomp [--help] [--version] PROGRAM [ARGS] - -Run PROGRAMS ARGS to compile a file, generating dependencies -as side-effects. - -Environment variables: - depmode Dependency tracking mode. - source Source file read by `PROGRAMS ARGS'. - object Object file output by `PROGRAMS ARGS'. - DEPDIR directory where to store dependencies. - depfile Dependency file to output. - tmpdepfile Temporary file to use when outputing dependencies. - libtool Whether libtool is used (yes/no). - -Report bugs to . -EOF - exit $? - ;; - -v | --v*) - echo "depcomp $scriptversion" - exit $? - ;; -esac - -if test -z "$depmode" || test -z "$source" || test -z "$object"; then - echo "depcomp: Variables source, object and depmode must be set" 1>&2 - exit 1 -fi - -# Dependencies for sub/bar.o or sub/bar.obj go into sub/.deps/bar.Po. -depfile=${depfile-`echo "$object" | - sed 's|[^\\/]*$|'${DEPDIR-.deps}'/&|;s|\.\([^.]*\)$|.P\1|;s|Pobj$|Po|'`} -tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`} - -rm -f "$tmpdepfile" - -# Some modes work just like other modes, but use different flags. We -# parameterize here, but still list the modes in the big case below, -# to make depend.m4 easier to write. Note that we *cannot* use a case -# here, because this file can only contain one case statement. -if test "$depmode" = hp; then - # HP compiler uses -M and no extra arg. - gccflag=-M - depmode=gcc -fi - -if test "$depmode" = dashXmstdout; then - # This is just like dashmstdout with a different argument. - dashmflag=-xM - depmode=dashmstdout -fi - -case "$depmode" in -gcc3) -## gcc 3 implements dependency tracking that does exactly what -## we want. Yay! Note: for some reason libtool 1.4 doesn't like -## it if -MD -MP comes after the -MF stuff. Hmm. - "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" - stat=$? - if test $stat -eq 0; then : - else - rm -f "$tmpdepfile" - exit $stat - fi - mv "$tmpdepfile" "$depfile" - ;; - -gcc) -## There are various ways to get dependency output from gcc. Here's -## why we pick this rather obscure method: -## - Don't want to use -MD because we'd like the dependencies to end -## up in a subdir. Having to rename by hand is ugly. -## (We might end up doing this anyway to support other compilers.) -## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like -## -MM, not -M (despite what the docs say). -## - Using -M directly means running the compiler twice (even worse -## than renaming). - if test -z "$gccflag"; then - gccflag=-MD, - fi - "$@" -Wp,"$gccflag$tmpdepfile" - stat=$? - if test $stat -eq 0; then : - else - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - echo "$object : \\" > "$depfile" - alpha=ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz -## The second -e expression handles DOS-style file names with drive letters. - sed -e 's/^[^:]*: / /' \ - -e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile" -## This next piece of magic avoids the `deleted header file' problem. -## The problem is that when a header file which appears in a .P file -## is deleted, the dependency causes make to die (because there is -## typically no way to rebuild the header). We avoid this by adding -## dummy dependencies for each header file. Too bad gcc doesn't do -## this for us directly. - tr ' ' ' -' < "$tmpdepfile" | -## Some versions of gcc put a space before the `:'. On the theory -## that the space means something, we add a space to the output as -## well. -## Some versions of the HPUX 10.20 sed can't process this invocation -## correctly. Breaking it into two sed invocations is a workaround. - sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -hp) - # This case exists only to let depend.m4 do its work. It works by - # looking at the text of this script. This case will never be run, - # since it is checked for above. - exit 1 - ;; - -sgi) - if test "$libtool" = yes; then - "$@" "-Wp,-MDupdate,$tmpdepfile" - else - "$@" -MDupdate "$tmpdepfile" - fi - stat=$? - if test $stat -eq 0; then : - else - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - - if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files - echo "$object : \\" > "$depfile" - - # Clip off the initial element (the dependent). Don't try to be - # clever and replace this with sed code, as IRIX sed won't handle - # lines with more than a fixed number of characters (4096 in - # IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines; - # the IRIX cc adds comments like `#:fec' to the end of the - # dependency line. - tr ' ' ' -' < "$tmpdepfile" \ - | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' | \ - tr ' -' ' ' >> $depfile - echo >> $depfile - - # The second pass generates a dummy entry for each header file. - tr ' ' ' -' < "$tmpdepfile" \ - | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \ - >> $depfile - else - # The sourcefile does not contain any dependencies, so just - # store a dummy comment line, to avoid errors with the Makefile - # "include basename.Plo" scheme. - echo "#dummy" > "$depfile" - fi - rm -f "$tmpdepfile" - ;; - -aix) - # The C for AIX Compiler uses -M and outputs the dependencies - # in a .u file. In older versions, this file always lives in the - # current directory. Also, the AIX compiler puts `$object:' at the - # start of each line; $object doesn't have directory information. - # Version 6 uses the directory in both cases. - stripped=`echo "$object" | sed 's/\(.*\)\..*$/\1/'` - tmpdepfile="$stripped.u" - if test "$libtool" = yes; then - "$@" -Wc,-M - else - "$@" -M - fi - stat=$? - - if test -f "$tmpdepfile"; then : - else - stripped=`echo "$stripped" | sed 's,^.*/,,'` - tmpdepfile="$stripped.u" - fi - - if test $stat -eq 0; then : - else - rm -f "$tmpdepfile" - exit $stat - fi - - if test -f "$tmpdepfile"; then - outname="$stripped.o" - # Each line is of the form `foo.o: dependent.h'. - # Do two passes, one to just change these to - # `$object: dependent.h' and one to simply `dependent.h:'. - sed -e "s,^$outname:,$object :," < "$tmpdepfile" > "$depfile" - sed -e "s,^$outname: \(.*\)$,\1:," < "$tmpdepfile" >> "$depfile" - else - # The sourcefile does not contain any dependencies, so just - # store a dummy comment line, to avoid errors with the Makefile - # "include basename.Plo" scheme. - echo "#dummy" > "$depfile" - fi - rm -f "$tmpdepfile" - ;; - -icc) - # Intel's C compiler understands `-MD -MF file'. However on - # icc -MD -MF foo.d -c -o sub/foo.o sub/foo.c - # ICC 7.0 will fill foo.d with something like - # foo.o: sub/foo.c - # foo.o: sub/foo.h - # which is wrong. We want: - # sub/foo.o: sub/foo.c - # sub/foo.o: sub/foo.h - # sub/foo.c: - # sub/foo.h: - # ICC 7.1 will output - # foo.o: sub/foo.c sub/foo.h - # and will wrap long lines using \ : - # foo.o: sub/foo.c ... \ - # sub/foo.h ... \ - # ... - - "$@" -MD -MF "$tmpdepfile" - stat=$? - if test $stat -eq 0; then : - else - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - # Each line is of the form `foo.o: dependent.h', - # or `foo.o: dep1.h dep2.h \', or ` dep3.h dep4.h \'. - # Do two passes, one to just change these to - # `$object: dependent.h' and one to simply `dependent.h:'. - sed "s,^[^:]*:,$object :," < "$tmpdepfile" > "$depfile" - # Some versions of the HPUX 10.20 sed can't process this invocation - # correctly. Breaking it into two sed invocations is a workaround. - sed 's,^[^:]*: \(.*\)$,\1,;s/^\\$//;/^$/d;/:$/d' < "$tmpdepfile" | - sed -e 's/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -tru64) - # The Tru64 compiler uses -MD to generate dependencies as a side - # effect. `cc -MD -o foo.o ...' puts the dependencies into `foo.o.d'. - # At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put - # dependencies in `foo.d' instead, so we check for that too. - # Subdirectories are respected. - dir=`echo "$object" | sed -e 's|/[^/]*$|/|'` - test "x$dir" = "x$object" && dir= - base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'` - - if test "$libtool" = yes; then - # With Tru64 cc, shared objects can also be used to make a - # static library. This mecanism is used in libtool 1.4 series to - # handle both shared and static libraries in a single compilation. - # With libtool 1.4, dependencies were output in $dir.libs/$base.lo.d. - # - # With libtool 1.5 this exception was removed, and libtool now - # generates 2 separate objects for the 2 libraries. These two - # compilations output dependencies in in $dir.libs/$base.o.d and - # in $dir$base.o.d. We have to check for both files, because - # one of the two compilations can be disabled. We should prefer - # $dir$base.o.d over $dir.libs/$base.o.d because the latter is - # automatically cleaned when .libs/ is deleted, while ignoring - # the former would cause a distcleancheck panic. - tmpdepfile1=$dir.libs/$base.lo.d # libtool 1.4 - tmpdepfile2=$dir$base.o.d # libtool 1.5 - tmpdepfile3=$dir.libs/$base.o.d # libtool 1.5 - tmpdepfile4=$dir.libs/$base.d # Compaq CCC V6.2-504 - "$@" -Wc,-MD - else - tmpdepfile1=$dir$base.o.d - tmpdepfile2=$dir$base.d - tmpdepfile3=$dir$base.d - tmpdepfile4=$dir$base.d - "$@" -MD - fi - - stat=$? - if test $stat -eq 0; then : - else - rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" "$tmpdepfile4" - exit $stat - fi - - for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" "$tmpdepfile4" - do - test -f "$tmpdepfile" && break - done - if test -f "$tmpdepfile"; then - sed -e "s,^.*\.[a-z]*:,$object:," < "$tmpdepfile" > "$depfile" - # That's a tab and a space in the []. - sed -e 's,^.*\.[a-z]*:[ ]*,,' -e 's,$,:,' < "$tmpdepfile" >> "$depfile" - else - echo "#dummy" > "$depfile" - fi - rm -f "$tmpdepfile" - ;; - -#nosideeffect) - # This comment above is used by automake to tell side-effect - # dependency tracking mechanisms from slower ones. - -dashmstdout) - # Important note: in order to support this mode, a compiler *must* - # always write the preprocessed file to stdout, regardless of -o. - "$@" || exit $? - - # Remove the call to Libtool. - if test "$libtool" = yes; then - while test $1 != '--mode=compile'; do - shift - done - shift - fi - - # Remove `-o $object'. - IFS=" " - for arg - do - case $arg in - -o) - shift - ;; - $object) - shift - ;; - *) - set fnord "$@" "$arg" - shift # fnord - shift # $arg - ;; - esac - done - - test -z "$dashmflag" && dashmflag=-M - # Require at least two characters before searching for `:' - # in the target name. This is to cope with DOS-style filenames: - # a dependency such as `c:/foo/bar' could be seen as target `c' otherwise. - "$@" $dashmflag | - sed 's:^[ ]*[^: ][^:][^:]*\:[ ]*:'"$object"'\: :' > "$tmpdepfile" - rm -f "$depfile" - cat < "$tmpdepfile" > "$depfile" - tr ' ' ' -' < "$tmpdepfile" | \ -## Some versions of the HPUX 10.20 sed can't process this invocation -## correctly. Breaking it into two sed invocations is a workaround. - sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -dashXmstdout) - # This case only exists to satisfy depend.m4. It is never actually - # run, as this mode is specially recognized in the preamble. - exit 1 - ;; - -makedepend) - "$@" || exit $? - # Remove any Libtool call - if test "$libtool" = yes; then - while test $1 != '--mode=compile'; do - shift - done - shift - fi - # X makedepend - shift - cleared=no - for arg in "$@"; do - case $cleared in - no) - set ""; shift - cleared=yes ;; - esac - case "$arg" in - -D*|-I*) - set fnord "$@" "$arg"; shift ;; - # Strip any option that makedepend may not understand. Remove - # the object too, otherwise makedepend will parse it as a source file. - -*|$object) - ;; - *) - set fnord "$@" "$arg"; shift ;; - esac - done - obj_suffix="`echo $object | sed 's/^.*\././'`" - touch "$tmpdepfile" - ${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@" - rm -f "$depfile" - cat < "$tmpdepfile" > "$depfile" - sed '1,2d' "$tmpdepfile" | tr ' ' ' -' | \ -## Some versions of the HPUX 10.20 sed can't process this invocation -## correctly. Breaking it into two sed invocations is a workaround. - sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" "$tmpdepfile".bak - ;; - -cpp) - # Important note: in order to support this mode, a compiler *must* - # always write the preprocessed file to stdout. - "$@" || exit $? - - # Remove the call to Libtool. - if test "$libtool" = yes; then - while test $1 != '--mode=compile'; do - shift - done - shift - fi - - # Remove `-o $object'. - IFS=" " - for arg - do - case $arg in - -o) - shift - ;; - $object) - shift - ;; - *) - set fnord "$@" "$arg" - shift # fnord - shift # $arg - ;; - esac - done - - "$@" -E | - sed -n -e '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \ - -e '/^#line [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' | - sed '$ s: \\$::' > "$tmpdepfile" - rm -f "$depfile" - echo "$object : \\" > "$depfile" - cat < "$tmpdepfile" >> "$depfile" - sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -msvisualcpp) - # Important note: in order to support this mode, a compiler *must* - # always write the preprocessed file to stdout, regardless of -o, - # because we must use -o when running libtool. - "$@" || exit $? - IFS=" " - for arg - do - case "$arg" in - "-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI") - set fnord "$@" - shift - shift - ;; - *) - set fnord "$@" "$arg" - shift - shift - ;; - esac - done - "$@" -E | - sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::echo "`cygpath -u \\"\1\\"`":p' | sort | uniq > "$tmpdepfile" - rm -f "$depfile" - echo "$object : \\" > "$depfile" - . "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s:: \1 \\:p' >> "$depfile" - echo " " >> "$depfile" - . "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s::\1\::p' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -none) - exec "$@" - ;; - -*) - echo "Unknown depmode $depmode" 1>&2 - exit 1 - ;; -esac - -exit 0 - -# Local Variables: -# mode: shell-script -# sh-indentation: 2 -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-end: "$" -# End: diff -urN src/contrib/ntp/arlib/install-sh src.ntp/contrib/ntp/arlib/install-sh --- src/contrib/ntp/arlib/install-sh 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/arlib/install-sh 1970-01-01 01:00:00.000000000 +0100 @@ -1,323 +0,0 @@ -#!/bin/sh -# install - install a program, script, or datafile - -scriptversion=2005-05-14.22 - -# This originates from X11R5 (mit/util/scripts/install.sh), which was -# later released in X11R6 (xc/config/util/install.sh) with the -# following copyright and license. -# -# Copyright (C) 1994 X Consortium -# -# Permission is hereby granted, free of charge, to any person obtaining a copy -# of this software and associated documentation files (the "Software"), to -# deal in the Software without restriction, including without limitation the -# rights to use, copy, modify, merge, publish, distribute, sublicense, and/or -# sell copies of the Software, and to permit persons to whom the Software is -# furnished to do so, subject to the following conditions: -# -# The above copyright notice and this permission notice shall be included in -# all copies or substantial portions of the Software. -# -# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -# X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -# AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC- -# TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -# -# Except as contained in this notice, the name of the X Consortium shall not -# be used in advertising or otherwise to promote the sale, use or other deal- -# ings in this Software without prior written authorization from the X Consor- -# tium. -# -# -# FSF changes to this file are in the public domain. -# -# Calling this script install-sh is preferred over install.sh, to prevent -# `make' implicit rules from creating a file called install from it -# when there is no Makefile. -# -# This script is compatible with the BSD install script, but was written -# from scratch. It can only install one file at a time, a restriction -# shared with many OS's install programs. - -# set DOITPROG to echo to test this script - -# Don't use :- since 4.3BSD and earlier shells don't like it. -doit="${DOITPROG-}" - -# put in absolute paths if you don't have them in your path; or use env. vars. - -mvprog="${MVPROG-mv}" -cpprog="${CPPROG-cp}" -chmodprog="${CHMODPROG-chmod}" -chownprog="${CHOWNPROG-chown}" -chgrpprog="${CHGRPPROG-chgrp}" -stripprog="${STRIPPROG-strip}" -rmprog="${RMPROG-rm}" -mkdirprog="${MKDIRPROG-mkdir}" - -chmodcmd="$chmodprog 0755" -chowncmd= -chgrpcmd= -stripcmd= -rmcmd="$rmprog -f" -mvcmd="$mvprog" -src= -dst= -dir_arg= -dstarg= -no_target_directory= - -usage="Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE - or: $0 [OPTION]... SRCFILES... DIRECTORY - or: $0 [OPTION]... -t DIRECTORY SRCFILES... - or: $0 [OPTION]... -d DIRECTORIES... - -In the 1st form, copy SRCFILE to DSTFILE. -In the 2nd and 3rd, copy all SRCFILES to DIRECTORY. -In the 4th, create DIRECTORIES. - -Options: --c (ignored) --d create directories instead of installing files. --g GROUP $chgrpprog installed files to GROUP. --m MODE $chmodprog installed files to MODE. --o USER $chownprog installed files to USER. --s $stripprog installed files. --t DIRECTORY install into DIRECTORY. --T report an error if DSTFILE is a directory. ---help display this help and exit. ---version display version info and exit. - -Environment variables override the default commands: - CHGRPPROG CHMODPROG CHOWNPROG CPPROG MKDIRPROG MVPROG RMPROG STRIPPROG -" - -while test -n "$1"; do - case $1 in - -c) shift - continue;; - - -d) dir_arg=true - shift - continue;; - - -g) chgrpcmd="$chgrpprog $2" - shift - shift - continue;; - - --help) echo "$usage"; exit $?;; - - -m) chmodcmd="$chmodprog $2" - shift - shift - continue;; - - -o) chowncmd="$chownprog $2" - shift - shift - continue;; - - -s) stripcmd=$stripprog - shift - continue;; - - -t) dstarg=$2 - shift - shift - continue;; - - -T) no_target_directory=true - shift - continue;; - - --version) echo "$0 $scriptversion"; exit $?;; - - *) # When -d is used, all remaining arguments are directories to create. - # When -t is used, the destination is already specified. - test -n "$dir_arg$dstarg" && break - # Otherwise, the last argument is the destination. Remove it from $@. - for arg - do - if test -n "$dstarg"; then - # $@ is not empty: it contains at least $arg. - set fnord "$@" "$dstarg" - shift # fnord - fi - shift # arg - dstarg=$arg - done - break;; - esac -done - -if test -z "$1"; then - if test -z "$dir_arg"; then - echo "$0: no input file specified." >&2 - exit 1 - fi - # It's OK to call `install-sh -d' without argument. - # This can happen when creating conditional directories. - exit 0 -fi - -for src -do - # Protect names starting with `-'. - case $src in - -*) src=./$src ;; - esac - - if test -n "$dir_arg"; then - dst=$src - src= - - if test -d "$dst"; then - mkdircmd=: - chmodcmd= - else - mkdircmd=$mkdirprog - fi - else - # Waiting for this to be detected by the "$cpprog $src $dsttmp" command - # might cause directories to be created, which would be especially bad - # if $src (and thus $dsttmp) contains '*'. - if test ! -f "$src" && test ! -d "$src"; then - echo "$0: $src does not exist." >&2 - exit 1 - fi - - if test -z "$dstarg"; then - echo "$0: no destination specified." >&2 - exit 1 - fi - - dst=$dstarg - # Protect names starting with `-'. - case $dst in - -*) dst=./$dst ;; - esac - - # If destination is a directory, append the input filename; won't work - # if double slashes aren't ignored. - if test -d "$dst"; then - if test -n "$no_target_directory"; then - echo "$0: $dstarg: Is a directory" >&2 - exit 1 - fi - dst=$dst/`basename "$src"` - fi - fi - - # This sed command emulates the dirname command. - dstdir=`echo "$dst" | sed -e 's,/*$,,;s,[^/]*$,,;s,/*$,,;s,^$,.,'` - - # Make sure that the destination directory exists. - - # Skip lots of stat calls in the usual case. - if test ! -d "$dstdir"; then - defaultIFS=' - ' - IFS="${IFS-$defaultIFS}" - - oIFS=$IFS - # Some sh's can't handle IFS=/ for some reason. - IFS='%' - set x `echo "$dstdir" | sed -e 's@/@%@g' -e 's@^%@/@'` - shift - IFS=$oIFS - - pathcomp= - - while test $# -ne 0 ; do - pathcomp=$pathcomp$1 - shift - if test ! -d "$pathcomp"; then - $mkdirprog "$pathcomp" - # mkdir can fail with a `File exist' error in case several - # install-sh are creating the directory concurrently. This - # is OK. - test -d "$pathcomp" || exit - fi - pathcomp=$pathcomp/ - done - fi - - if test -n "$dir_arg"; then - $doit $mkdircmd "$dst" \ - && { test -z "$chowncmd" || $doit $chowncmd "$dst"; } \ - && { test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } \ - && { test -z "$stripcmd" || $doit $stripcmd "$dst"; } \ - && { test -z "$chmodcmd" || $doit $chmodcmd "$dst"; } - - else - dstfile=`basename "$dst"` - - # Make a couple of temp file names in the proper directory. - dsttmp=$dstdir/_inst.$$_ - rmtmp=$dstdir/_rm.$$_ - - # Trap to clean up those temp files at exit. - trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0 - trap '(exit $?); exit' 1 2 13 15 - - # Copy the file name to the temp name. - $doit $cpprog "$src" "$dsttmp" && - - # and set any options; do chmod last to preserve setuid bits. - # - # If any of these fail, we abort the whole thing. If we want to - # ignore errors from any of these, just make sure not to ignore - # errors from the above "$doit $cpprog $src $dsttmp" command. - # - { test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } \ - && { test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } \ - && { test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } \ - && { test -z "$chmodcmd" || $doit $chmodcmd "$dsttmp"; } && - - # Now rename the file to the real destination. - { $doit $mvcmd -f "$dsttmp" "$dstdir/$dstfile" 2>/dev/null \ - || { - # The rename failed, perhaps because mv can't rename something else - # to itself, or perhaps because mv is so ancient that it does not - # support -f. - - # Now remove or move aside any old file at destination location. - # We try this two ways since rm can't unlink itself on some - # systems and the destination file might be busy for other - # reasons. In this case, the final cleanup might fail but the new - # file should still install successfully. - { - if test -f "$dstdir/$dstfile"; then - $doit $rmcmd -f "$dstdir/$dstfile" 2>/dev/null \ - || $doit $mvcmd -f "$dstdir/$dstfile" "$rmtmp" 2>/dev/null \ - || { - echo "$0: cannot unlink or rename $dstdir/$dstfile" >&2 - (exit 1); exit 1 - } - else - : - fi - } && - - # Now rename the file to the real destination. - $doit $mvcmd "$dsttmp" "$dstdir/$dstfile" - } - } - fi || { (exit 1); exit 1; } -done - -# The final little trick to "correctly" pass the exit status to the exit trap. -{ - (exit 0); exit 0 -} - -# Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-end: "$" -# End: diff -urN src/contrib/ntp/arlib/missing src.ntp/contrib/ntp/arlib/missing --- src/contrib/ntp/arlib/missing 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/arlib/missing 1970-01-01 01:00:00.000000000 +0100 @@ -1,360 +0,0 @@ -#! /bin/sh -# Common stub for a few missing GNU programs while installing. - -scriptversion=2005-06-08.21 - -# Copyright (C) 1996, 1997, 1999, 2000, 2002, 2003, 2004, 2005 -# Free Software Foundation, Inc. -# Originally by Fran,cois Pinard , 1996. - -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2, or (at your option) -# any later version. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. - -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -# 02110-1301, USA. - -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - -if test $# -eq 0; then - echo 1>&2 "Try \`$0 --help' for more information" - exit 1 -fi - -run=: - -# In the cases where this matters, `missing' is being run in the -# srcdir already. -if test -f configure.ac; then - configure_ac=configure.ac -else - configure_ac=configure.in -fi - -msg="missing on your system" - -case "$1" in ---run) - # Try to run requested program, and just exit if it succeeds. - run= - shift - "$@" && exit 0 - # Exit code 63 means version mismatch. This often happens - # when the user try to use an ancient version of a tool on - # a file that requires a minimum version. In this case we - # we should proceed has if the program had been absent, or - # if --run hadn't been passed. - if test $? = 63; then - run=: - msg="probably too old" - fi - ;; - - -h|--h|--he|--hel|--help) - echo "\ -$0 [OPTION]... PROGRAM [ARGUMENT]... - -Handle \`PROGRAM [ARGUMENT]...' for when PROGRAM is missing, or return an -error status if there is no known handling for PROGRAM. - -Options: - -h, --help display this help and exit - -v, --version output version information and exit - --run try to run the given command, and emulate it if it fails - -Supported PROGRAM values: - aclocal touch file \`aclocal.m4' - autoconf touch file \`configure' - autoheader touch file \`config.h.in' - automake touch all \`Makefile.in' files - bison create \`y.tab.[ch]', if possible, from existing .[ch] - flex create \`lex.yy.c', if possible, from existing .c - help2man touch the output file - lex create \`lex.yy.c', if possible, from existing .c - makeinfo touch the output file - tar try tar, gnutar, gtar, then tar without non-portable flags - yacc create \`y.tab.[ch]', if possible, from existing .[ch] - -Send bug reports to ." - exit $? - ;; - - -v|--v|--ve|--ver|--vers|--versi|--versio|--version) - echo "missing $scriptversion (GNU Automake)" - exit $? - ;; - - -*) - echo 1>&2 "$0: Unknown \`$1' option" - echo 1>&2 "Try \`$0 --help' for more information" - exit 1 - ;; - -esac - -# Now exit if we have it, but it failed. Also exit now if we -# don't have it and --version was passed (most likely to detect -# the program). -case "$1" in - lex|yacc) - # Not GNU programs, they don't have --version. - ;; - - tar) - if test -n "$run"; then - echo 1>&2 "ERROR: \`tar' requires --run" - exit 1 - elif test "x$2" = "x--version" || test "x$2" = "x--help"; then - exit 1 - fi - ;; - - *) - if test -z "$run" && ($1 --version) > /dev/null 2>&1; then - # We have it, but it failed. - exit 1 - elif test "x$2" = "x--version" || test "x$2" = "x--help"; then - # Could not run --version or --help. This is probably someone - # running `$TOOL --version' or `$TOOL --help' to check whether - # $TOOL exists and not knowing $TOOL uses missing. - exit 1 - fi - ;; -esac - -# If it does not exist, or fails to run (possibly an outdated version), -# try to emulate it. -case "$1" in - aclocal*) - echo 1>&2 "\ -WARNING: \`$1' is $msg. You should only need it if - you modified \`acinclude.m4' or \`${configure_ac}'. You might want - to install the \`Automake' and \`Perl' packages. Grab them from - any GNU archive site." - touch aclocal.m4 - ;; - - autoconf) - echo 1>&2 "\ -WARNING: \`$1' is $msg. You should only need it if - you modified \`${configure_ac}'. You might want to install the - \`Autoconf' and \`GNU m4' packages. Grab them from any GNU - archive site." - touch configure - ;; - - autoheader) - echo 1>&2 "\ -WARNING: \`$1' is $msg. You should only need it if - you modified \`acconfig.h' or \`${configure_ac}'. You might want - to install the \`Autoconf' and \`GNU m4' packages. Grab them - from any GNU archive site." - files=`sed -n 's/^[ ]*A[CM]_CONFIG_HEADER(\([^)]*\)).*/\1/p' ${configure_ac}` - test -z "$files" && files="config.h" - touch_files= - for f in $files; do - case "$f" in - *:*) touch_files="$touch_files "`echo "$f" | - sed -e 's/^[^:]*://' -e 's/:.*//'`;; - *) touch_files="$touch_files $f.in";; - esac - done - touch $touch_files - ;; - - automake*) - echo 1>&2 "\ -WARNING: \`$1' is $msg. You should only need it if - you modified \`Makefile.am', \`acinclude.m4' or \`${configure_ac}'. - You might want to install the \`Automake' and \`Perl' packages. - Grab them from any GNU archive site." - find . -type f -name Makefile.am -print | - sed 's/\.am$/.in/' | - while read f; do touch "$f"; done - ;; - - autom4te) - echo 1>&2 "\ -WARNING: \`$1' is needed, but is $msg. - You might have modified some files without having the - proper tools for further handling them. - You can get \`$1' as part of \`Autoconf' from any GNU - archive site." - - file=`echo "$*" | sed -n 's/.*--output[ =]*\([^ ]*\).*/\1/p'` - test -z "$file" && file=`echo "$*" | sed -n 's/.*-o[ ]*\([^ ]*\).*/\1/p'` - if test -f "$file"; then - touch $file - else - test -z "$file" || exec >$file - echo "#! /bin/sh" - echo "# Created by GNU Automake missing as a replacement of" - echo "# $ $@" - echo "exit 0" - chmod +x $file - exit 1 - fi - ;; - - bison|yacc) - echo 1>&2 "\ -WARNING: \`$1' $msg. You should only need it if - you modified a \`.y' file. You may need the \`Bison' package - in order for those modifications to take effect. You can get - \`Bison' from any GNU archive site." - rm -f y.tab.c y.tab.h - if [ $# -ne 1 ]; then - eval LASTARG="\${$#}" - case "$LASTARG" in - *.y) - SRCFILE=`echo "$LASTARG" | sed 's/y$/c/'` - if [ -f "$SRCFILE" ]; then - cp "$SRCFILE" y.tab.c - fi - SRCFILE=`echo "$LASTARG" | sed 's/y$/h/'` - if [ -f "$SRCFILE" ]; then - cp "$SRCFILE" y.tab.h - fi - ;; - esac - fi - if [ ! -f y.tab.h ]; then - echo >y.tab.h - fi - if [ ! -f y.tab.c ]; then - echo 'main() { return 0; }' >y.tab.c - fi - ;; - - lex|flex) - echo 1>&2 "\ -WARNING: \`$1' is $msg. You should only need it if - you modified a \`.l' file. You may need the \`Flex' package - in order for those modifications to take effect. You can get - \`Flex' from any GNU archive site." - rm -f lex.yy.c - if [ $# -ne 1 ]; then - eval LASTARG="\${$#}" - case "$LASTARG" in - *.l) - SRCFILE=`echo "$LASTARG" | sed 's/l$/c/'` - if [ -f "$SRCFILE" ]; then - cp "$SRCFILE" lex.yy.c - fi - ;; - esac - fi - if [ ! -f lex.yy.c ]; then - echo 'main() { return 0; }' >lex.yy.c - fi - ;; - - help2man) - echo 1>&2 "\ -WARNING: \`$1' is $msg. You should only need it if - you modified a dependency of a manual page. You may need the - \`Help2man' package in order for those modifications to take - effect. You can get \`Help2man' from any GNU archive site." - - file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'` - if test -z "$file"; then - file=`echo "$*" | sed -n 's/.*--output=\([^ ]*\).*/\1/p'` - fi - if [ -f "$file" ]; then - touch $file - else - test -z "$file" || exec >$file - echo ".ab help2man is required to generate this page" - exit 1 - fi - ;; - - makeinfo) - echo 1>&2 "\ -WARNING: \`$1' is $msg. You should only need it if - you modified a \`.texi' or \`.texinfo' file, or any other file - indirectly affecting the aspect of the manual. The spurious - call might also be the consequence of using a buggy \`make' (AIX, - DU, IRIX). You might want to install the \`Texinfo' package or - the \`GNU make' package. Grab either from any GNU archive site." - # The file to touch is that specified with -o ... - file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'` - if test -z "$file"; then - # ... or it is the one specified with @setfilename ... - infile=`echo "$*" | sed 's/.* \([^ ]*\) *$/\1/'` - file=`sed -n '/^@setfilename/ { s/.* \([^ ]*\) *$/\1/; p; q; }' $infile` - # ... or it is derived from the source name (dir/f.texi becomes f.info) - test -z "$file" && file=`echo "$infile" | sed 's,.*/,,;s,.[^.]*$,,'`.info - fi - # If the file does not exist, the user really needs makeinfo; - # let's fail without touching anything. - test -f $file || exit 1 - touch $file - ;; - - tar) - shift - - # We have already tried tar in the generic part. - # Look for gnutar/gtar before invocation to avoid ugly error - # messages. - if (gnutar --version > /dev/null 2>&1); then - gnutar "$@" && exit 0 - fi - if (gtar --version > /dev/null 2>&1); then - gtar "$@" && exit 0 - fi - firstarg="$1" - if shift; then - case "$firstarg" in - *o*) - firstarg=`echo "$firstarg" | sed s/o//` - tar "$firstarg" "$@" && exit 0 - ;; - esac - case "$firstarg" in - *h*) - firstarg=`echo "$firstarg" | sed s/h//` - tar "$firstarg" "$@" && exit 0 - ;; - esac - fi - - echo 1>&2 "\ -WARNING: I can't seem to be able to run \`tar' with the given arguments. - You may want to install GNU tar or Free paxutils, or check the - command line arguments." - exit 1 - ;; - - *) - echo 1>&2 "\ -WARNING: \`$1' is needed, and is $msg. - You might have modified some files without having the - proper tools for further handling them. Check the \`README' file, - it often tells you about the needed prerequisites for installing - this package. You may also peek at any GNU archive site, in case - some other package would contain this missing \`$1' program." - exit 1 - ;; -esac - -exit 0 - -# Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-end: "$" -# End: diff -urN src/contrib/ntp/arlib/sample.c src.ntp/contrib/ntp/arlib/sample.c --- src/contrib/ntp/arlib/sample.c 2004-07-20 17:01:25.000000000 +0200 +++ src.ntp/contrib/ntp/arlib/sample.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,143 +0,0 @@ -#include -#include -#include -#include -#include -#include -#include -#include "arlib.h" - -#ifndef lint -static char sccsid[] = "@(#)sample.c 1.1 12/21/92 (C)1992 Darren Reed. ASYNC DNS"; -#endif - -char line[512]; - -int lookup = 0, seq = 0; -long expire = 0; - -main() -{ - struct in_addr adr; - struct timeval tv2; - fd_set rd; - long now; - char *s; - int afd, nfd, pid = getpid(), del; - - afd = ar_init(ARES_INITLIST|ARES_CALLINIT|ARES_INITSOCK); - - (void)printf("afd = %d pid = %d\n",afd, pid); - - while (1) - { - (void)printf("Host =>"); - (void)fflush(stdout); - *line = '\0'; - FD_ZERO(&rd); - FD_SET(0,&rd); - FD_SET(afd,&rd); - now = time(NULL); - if (expire >= now) - { - tv2.tv_usec = 0; - tv2.tv_sec = expire - now; - nfd = select(FD_SETSIZE, &rd, NULL, NULL, &tv2); - } - else - nfd = select(FD_SETSIZE, &rd, NULL, NULL, NULL); - - if (FD_ISSET(0, &rd)) - { - if (!fgets(line, sizeof(line) - 1, stdin)) - exit(0); - if (s = index(line, '\n')) - *s = '\0'; - } - - if (isalpha(*line)) - { - (void)printf("Asking about [%s] #%d.\n",line, ++seq); - (void)ar_gethostbyname(line, (char *)&seq, - sizeof(seq)); - lookup++; - } - else if (isdigit(*line)) - { - (void)printf("Asking about IP#[%s] #%d.\n", - line, ++seq); - adr.s_addr = inet_addr(line); - (void)ar_gethostbyaddr(&adr, (char *)&seq, - sizeof(seq)); - lookup++; - } - if (lookup) - (void)printf("Waiting for answer:\n"); - if (FD_ISSET(afd, &rd)) - (void)waitonlookup(afd); - del = 0; - expire = ar_timeout(time(NULL), &del, sizeof(del)); - if (del) - { - (void)fprintf(stderr,"#%d failed\n", del); - lookup--; - } - } -} - -printhostent(hp) -struct hostent *hp; -{ - struct in_addr ip; - int i; - - (void)printf("hname = %s\n", hp->h_name); - for (i = 0; hp->h_aliases[i]; i++) - (void)printf("alias %d = %s\n", i+1, hp->h_aliases[i]); - for (i = 0; hp->h_addr_list[i]; i++) - { - bcopy(hp->h_addr_list[i], (char *)&ip, sizeof(ip)); - (void)printf("IP# %d = %s\n", i+1, inet_ntoa(ip)); - } -} - -int waitonlookup(afd) -int afd; -{ - struct timeval delay; - struct hostent *hp; - fd_set rd; - long now; - int nfd, del; - -waitloop: - FD_ZERO(&rd); - now = time(NULL); - if (expire >= now) - delay.tv_sec = expire - now; - else - delay.tv_sec = 1; - delay.tv_usec = 0; - FD_SET(afd, &rd); - FD_SET(0, &rd); - - nfd = select(FD_SETSIZE, &rd, 0, 0, &delay); - if (nfd == 0) - return 0; - else if (FD_ISSET(afd, &rd)) - { - del = 0; - hp = ar_answer(&del, sizeof(del)); - - (void)printf("hp=%x seq=%d\n",hp,del); - if (hp) - { - (void)printhostent(hp); - if (!--lookup) - return 1; - } - } - if (FD_ISSET(0, &rd)) - return 2; - return 0; -} diff -urN src/contrib/ntp/bincheck.mf src.ntp/contrib/ntp/bincheck.mf --- src/contrib/ntp/bincheck.mf 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/bincheck.mf 2009-12-22 11:01:33.000000000 +0100 @@ -3,11 +3,11 @@ # subdir to warn folks if there is another version there. install-exec-hook: - @case ${BINSUBDIR} in \ - bin) ODIR=${exec_prefix}/sbin ;; \ - sbin) ODIR=${exec_prefix}/bin ;; \ - esac; \ - test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ + @case ${BINSUBDIR} in \ + bin) ODIR=${sbindir} ;; \ + sbin) ODIR=${bindir} ;; \ + esac; \ + test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ test ! -f $$ODIR/$$i || echo "*** $$i is also in $$ODIR!"; \ done diff -urN src/contrib/ntp/bootstrap src.ntp/contrib/ntp/bootstrap --- src/contrib/ntp/bootstrap 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/bootstrap 2010-02-04 08:26:58.000000000 +0100 @@ -27,7 +27,7 @@ set -e -scripts/genver +scripts/genver || { echo scripts/genver failed ; exit 1; } # autoreconf says: # The environment variables AUTOCONF, AUTOHEADER, AUTOMAKE, ACLOCAL, @@ -78,9 +78,9 @@ ## Non-AutoGen stuff -for i in autogen-version.def version.def +for i in autogen-version.def version.def version.texi do - cmp -s include/$i sntp/$i || cp -p include/$i sntp/$i + cmp -s include/$i sntp/$i || cp -fp include/$i sntp/$i done # touch the stuff generated by the opt files @@ -92,7 +92,7 @@ for i in `ls -1 $f*` do case "$i" in - *.c|*.h|*.1|*.texi|*.menu) + *.c|*.h|*.1|*.html|*.texi|*.menu) l="$l $i" ;; esac @@ -106,7 +106,15 @@ ## EOAutoGen stuff +# Yacc/bison files ntp_parser.[ch] so we don't require the tool if +# ntp_parser.y hasn't been updated. At the same time, keyword-gen-utd +# and ntp_keyword.h which are derived from ntp_parser.h and +# keyword-gen.c. + +touch ntpd/ntp_parser.[ch] ntpd/keyword-gen-utd ntpd/ntp_keyword.h + cp bincheck.mf sntp/ +cp depsver.mf sntp/ ${AUTORECONF} -i -v diff -urN src/contrib/ntp/build src.ntp/contrib/ntp/build --- src/contrib/ntp/build 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/build 2010-01-24 11:01:46.000000000 +0100 @@ -18,8 +18,8 @@ echo "This is <`pwd`>" echo "SIG is <$SIG>" echo "KEY is <$KEY>" - exit 1 - ;; + exit 1 + ;; esac ;; *) @@ -30,17 +30,25 @@ #set -e #set -x -CVO=`./config.guess` +# scripts/cvo.sh invokes config.guess, and we want it to use the copy +# in the top directory (alongside build) if there's not another +# config.guess earlier on the path, so we invoke it using env to append +# . to the PATH. + +CVO=`env PATH="$PATH:." scripts/cvo.sh @cvo@` case "$CVO" in + *-*-*-*) "echo scripts/cvo.sh returned <$CVO>, which makes no sense to me." + exit 1 + ;; *-*-*) ;; - *) echo "config.guess returned <$CVO>, which makes no sense to me." + *) echo "scripts/cvo.sh returned <$CVO>, which makes no sense to me." exit 1 ;; esac case "$IAM" in *.udel.edu) - BDIR=A.$MYNAME + BASEDIR=A.$MYNAME CONFIG_ARGS="$CONFIG_ARGS --enable-local-libopts" case "$CVO" in *-*-ultrix*) @@ -49,7 +57,7 @@ esac ;; *) - BDIR=A.$CVO + BASEDIR=A.$CVO ;; esac @@ -76,15 +84,16 @@ ;; esac -CCSUF="" - case "$CC" in - '') ;; - *) CCSUF="-$CC" + '') + CCSUF="" + ;; + *) + CCSUF="-`echo $CC | sed -e 's: :_:g' -e's:/:+:g'`" ;; esac -BDIR="$BDIR$KEYSUF$CCSUF" +BDIR="$BASEDIR$KEYSUF$CCSUF" [ -d "$BDIR" ] || mkdir $BDIR [ -f "$BDIR/.buildcvo" ] || echo $CVO > $BDIR/.buildcvo @@ -94,29 +103,37 @@ cd $BDIR # -# make sure we have a nice that works, +# Make sure we have a nice that works. +# To disable use of nice, setenv NO_NICE_BUILD=1 # -nice true && NICEB=nice -nice true || NICEB=./.nicebuild-$MYNAME-$SIG && ( - cat > .nicebuild-$MYNAME-$SIG < $NICEB <<-HEREDOC + #! /bin/sh + shift + \$* +HEREDOC + chmod +x $NICEB +} + +CONFIGURE="../configure --cache-file=../config.cache-$IAM$CCSUF $CONFIG_ARGS" + +( # This sequence of commands is logged to make.log. + [ -f config.status ] || $NICEB -7 $CONFIGURE + $NICEB -5 ./config.status + $NICEB -14 ${MAKE-make} && $NICEB -10 ${MAKE-make} check ) > $LOGF 2>&1 + +EXITCODE=$? + +# clean up if we made a dummy nice script +case "$NICEB" in + nice) + ;; + *) + rm $NICEB +esac + +exit $EXITCODE diff -urN src/contrib/ntp/clockstuff/Makefile.am src.ntp/contrib/ntp/clockstuff/Makefile.am --- src/contrib/ntp/clockstuff/Makefile.am 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/clockstuff/Makefile.am 2009-12-09 08:36:36.000000000 +0100 @@ -1,5 +1,5 @@ #AUTOMAKE_OPTIONS = ../ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr +AUTOMAKE_OPTIONS = noinst_PROGRAMS = @PROPDELAY@ @CHUTEST@ @CLKTEST@ EXTRA_PROGRAMS = propdelay chutest clktest @@ -10,9 +10,13 @@ clktest_LDADD = ../libntp/libntp.a ETAGS_ARGS = Makefile.am #EXTRA_DIST = TAGS +BUILT_SOURCES = +CLEANFILES = # clktest-opts.def wants ../include/copyright.def ../include/homerc.def chutest$(EXEEXT): ../libntp/libntp.a clktest$(EXEEXT): ../libntp/libntp.a + +include $(top_srcdir)/depsver.mf diff -urN src/contrib/ntp/clockstuff/Makefile.in src.ntp/contrib/ntp/clockstuff/Makefile.in --- src/contrib/ntp/clockstuff/Makefile.in 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/clockstuff/Makefile.in 2010-07-09 04:21:31.000000000 +0200 @@ -34,14 +34,18 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -ANSI2KNR = ../util/ansi2knr EXTRA_PROGRAMS = propdelay$(EXEEXT) chutest$(EXEEXT) clktest$(EXEEXT) +DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ + $(top_srcdir)/depsver.mf subdir = clockstuff -DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ + $(top_srcdir)/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/m4/ntp_openssl.m4 \ + $(top_srcdir)/m4/ntp_vpathhack.m4 \ $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ @@ -52,13 +56,13 @@ CONFIG_CLEAN_VPATH_FILES = PROGRAMS = $(noinst_PROGRAMS) chutest_SOURCES = chutest.c -chutest_OBJECTS = chutest$U.$(OBJEXT) +chutest_OBJECTS = chutest.$(OBJEXT) chutest_DEPENDENCIES = ../libntp/libntp.a clktest_SOURCES = clktest.c -clktest_OBJECTS = clktest$U.$(OBJEXT) +clktest_OBJECTS = clktest.$(OBJEXT) clktest_DEPENDENCIES = ../libntp/libntp.a propdelay_SOURCES = propdelay.c -propdelay_OBJECTS = propdelay$U.$(OBJEXT) +propdelay_OBJECTS = propdelay.$(OBJEXT) propdelay_DEPENDENCIES = ../libntp/libntp.a DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) depcomp = $(SHELL) $(top_srcdir)/depcomp @@ -81,7 +85,6 @@ ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -102,6 +105,7 @@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EF_LIBS = @EF_LIBS@ EF_PROGS = @EF_PROGS@ EGREP = @EGREP@ @@ -133,6 +137,7 @@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ @@ -149,18 +154,22 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ PATH_SEPARATOR = @PATH_SEPARATOR@ PATH_SH = @PATH_SH@ PROPDELAY = @PROPDELAY@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ VERSION = @VERSION@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ @@ -214,7 +223,7 @@ top_srcdir = @top_srcdir@ #AUTOMAKE_OPTIONS = ../ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr +AUTOMAKE_OPTIONS = noinst_PROGRAMS = @PROPDELAY@ @CHUTEST@ @CLKTEST@ INCLUDES = -I$(top_srcdir)/include # We need -lm (and perhaps $(COMPAT) for propdelay, -lntp for {chu,clk}test @@ -222,11 +231,15 @@ chutest_LDADD = ../libntp/libntp.a clktest_LDADD = ../libntp/libntp.a ETAGS_ARGS = Makefile.am -all: all-am +#EXTRA_DIST = TAGS +BUILT_SOURCES = .deps-ver +CLEANFILES = .deps-ver +all: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/depsver.mf $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -274,15 +287,10 @@ distclean-compile: -rm -f *.tab.c -../util/ansi2knr: - $(am__cd) ../util && $(MAKE) $(AM_MAKEFLAGS) ./ansi2knr - -mostlyclean-kr: - -test "$U" = "" || rm -f *_.c -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/chutest$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clktest$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/propdelay$U.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/chutest.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clktest.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/propdelay.Po@am__quote@ .c.o: @am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @@ -304,14 +312,6 @@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< -chutest_.c: chutest.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/chutest.c; then echo $(srcdir)/chutest.c; else echo chutest.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clktest_.c: clktest.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clktest.c; then echo $(srcdir)/clktest.c; else echo clktest.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -propdelay_.c: propdelay.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/propdelay.c; then echo $(srcdir)/propdelay.c; else echo propdelay.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -chutest_.$(OBJEXT) chutest_.lo clktest_.$(OBJEXT) clktest_.lo \ -propdelay_.$(OBJEXT) propdelay_.lo : $(ANSI2KNR) mostlyclean-libtool: -rm -f *.lo @@ -402,10 +402,12 @@ fi; \ done check-am: all-am -check: check-am +check: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) check-am all-am: Makefile $(PROGRAMS) installdirs: -install: install-am +install: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am @@ -422,6 +424,7 @@ mostlyclean-generic: clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) @@ -430,6 +433,7 @@ maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." + -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-am clean-am: clean-generic clean-libtool clean-noinstPROGRAMS \ @@ -488,7 +492,7 @@ mostlyclean: mostlyclean-am -mostlyclean-am: mostlyclean-compile mostlyclean-generic mostlyclean-kr \ +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am @@ -501,7 +505,7 @@ uninstall-am: -.MAKE: ../util/ansi2knr install-am install-strip +.MAKE: all check install install-am install-strip .PHONY: CTAGS GTAGS all all-am check check-am clean clean-generic \ clean-libtool clean-noinstPROGRAMS ctags distclean \ @@ -513,17 +517,79 @@ install-pdf install-pdf-am install-ps install-ps-am \ install-strip installcheck installcheck-am installdirs \ maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-compile mostlyclean-generic mostlyclean-kr \ - mostlyclean-libtool pdf pdf-am ps ps-am tags uninstall \ - uninstall-am + mostlyclean-compile mostlyclean-generic mostlyclean-libtool \ + pdf pdf-am ps ps-am tags uninstall uninstall-am -#EXTRA_DIST = TAGS # clktest-opts.def wants ../include/copyright.def ../include/homerc.def chutest$(EXEEXT): ../libntp/libntp.a clktest$(EXEEXT): ../libntp/libntp.a +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + ..) \ + cd .. && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + *) \ + echo 'Fatal: depsver.mf Automake fragment limited' \ + 'to immediate subdirectories.' && \ + echo "top_builddir: $(top_builddir)" && \ + echo "subdir: $(subdir)" && \ + exit 1 \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff -urN src/contrib/ntp/conf/beauregard.conf src.ntp/contrib/ntp/conf/beauregard.conf --- src/contrib/ntp/conf/beauregard.conf 1999-12-09 14:01:18.000000000 +0100 +++ src.ntp/contrib/ntp/conf/beauregard.conf 2009-12-09 08:36:37.000000000 +0100 @@ -1,6 +1,6 @@ # # NTP configuration file (ntp.conf) -# bearegard.udel.edu +# beauregard.udel.edu # server 127.127.18.1 # NIST ACTS modem driver fudge 127.127.18.1 time1 .0035 diff -urN src/contrib/ntp/config.h.in src.ntp/contrib/ntp/config.h.in --- src/contrib/ntp/config.h.in 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/config.h.in 2010-07-09 04:23:25.000000000 +0200 @@ -162,7 +162,7 @@ /* Zyfer GPStarplus */ #undef CLOCK_ZYFER -/* Enable debugging? */ +/* Enable ntpd debugging code? */ #undef DEBUG /* Enable processing time debugging? */ @@ -267,6 +267,12 @@ /* What is the fallback value for HZ? */ #undef DEFAULT_HZ +/* Directory separator character, usually / or \\ */ +#undef DIR_SEP + +/* use old autokey session key behavior? */ +#undef DISABLE_BUG1243_FIX + /* synch TODR hourly? */ #undef DOSYNCTODR @@ -279,6 +285,9 @@ /* fopen(3) accepts a 't' in the mode flag */ #undef FOPEN_TEXT_FLAG +/* Force deferred DNS lookups? */ +#undef FORCE_DEFER_DNS + /* force ntpdate to step the clock if !defined(STEP_SLEW) ? */ #undef FORCE_NTPDATE_STEP @@ -328,24 +337,21 @@ /* Define to 1 if you don't have `vprintf' but do have `_doprnt.' */ #undef HAVE_DOPRNT -/* [Can we drop root privileges?] */ +/* Can we drop root privileges? */ #undef HAVE_DROPROOT /* Define to 1 if you have the header file. */ #undef HAVE_ERRNO_H -/* Define to 1 if you have the `EVP_md2' function. */ -#undef HAVE_EVP_MD2 - -/* Define to 1 if you have the `EVP_mdc2' function. */ -#undef HAVE_EVP_MDC2 - /* Define to 1 if you have the header file. */ #undef HAVE_FCNTL_H /* Define to 1 if you have the `finite' function. */ #undef HAVE_FINITE +/* Define to 1 if you have the `fork' function. */ +#undef HAVE_FORK + /* Define to 1 if you have the `getbootfile' function. */ #undef HAVE_GETBOOTFILE @@ -358,12 +364,21 @@ /* Define to 1 if you have the `getifaddrs' function. */ #undef HAVE_GETIFADDRS +/* Define to 1 if you have the `getpassphrase' function. */ +#undef HAVE_GETPASSPHRASE + /* Define to 1 if you have the `getrusage' function. */ #undef HAVE_GETRUSAGE /* Define to 1 if you have the `getuid' function. */ #undef HAVE_GETUID +/* Define to 1 if you have the header file. */ +#undef HAVE_HISTEDIT_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_HISTORY_H + /* Define to 1 if you have the `hstrerror' function. */ #undef HAVE_HSTRERROR @@ -400,21 +415,15 @@ /* Define to 1 if you have the `isfinite' function. */ #undef HAVE_ISFINITE +/* Define to 1 if you have the header file. */ +#undef HAVE_KVM_H + /* Define to 1 if you have the `kvm_open' function. */ #undef HAVE_KVM_OPEN -/* Define to 1 if you have the `K_open' function. */ -#undef HAVE_K_OPEN - /* Define to 1 if you have the `advapi32' library (-ladvapi32). */ #undef HAVE_LIBADVAPI32 -/* Do we have the curses library? */ -#undef HAVE_LIBCURSES - -/* Do we have the edit library? */ -#undef HAVE_LIBEDIT - /* Define to 1 if you have the `elf' library (-lelf). */ #undef HAVE_LIBELF @@ -433,11 +442,14 @@ /* Define to 1 if you have the `mld' library (-lmld). */ #undef HAVE_LIBMLD +/* Define to 1 if you have the `netsnmp' library (-lnetsnmp). */ +#undef HAVE_LIBNETSNMP + /* Define to 1 if you have the `posix4' library (-lposix4). */ #undef HAVE_LIBPOSIX4 -/* Define to 1 if you have the `readline' library (-lreadline). */ -#undef HAVE_LIBREADLINE +/* Define to 1 if you have the `resolv' library (-lresolv). */ +#undef HAVE_LIBRESOLV /* Define to 1 if you have the `rt' library (-lrt). */ #undef HAVE_LIBRT @@ -448,7 +460,7 @@ /* Define to 1 if you have the header file. */ #undef HAVE_LIMITS_H -/* [Do we have Linux capabilities?] */ +/* Do we have Linux capabilities? */ #undef HAVE_LINUX_CAPABILITIES /* Define to 1 if you have the header file. */ @@ -544,6 +556,9 @@ /* Define this if pathfind(3) works */ #undef HAVE_PATHFIND +/* Define to 1 if the system has the type `pid_t'. */ +#undef HAVE_PID_T + /* Define to 1 if you have the `plock' function. */ #undef HAVE_PLOCK @@ -553,15 +568,18 @@ /* Do we have the PPS API per the Draft RFC? */ #undef HAVE_PPSAPI -/* Are function prototypes OK? */ -#undef HAVE_PROTOTYPES - /* Define to 1 if you have the `pututline' function. */ #undef HAVE_PUTUTLINE /* Define to 1 if you have the `pututxline' function. */ #undef HAVE_PUTUTXLINE +/* Define to 1 if you have the header file. */ +#undef HAVE_READLINE_H + +/* Define if your readline library has \`add_history' */ +#undef HAVE_READLINE_HISTORY + /* Define to 1 if you have the header file. */ #undef HAVE_READLINE_HISTORY_H @@ -580,11 +598,17 @@ /* Define to 1 if you have the header file. */ #undef HAVE_RESOLV_H +/* Define to 1 if you have the `res_init' function. */ +#undef HAVE_RES_INIT + +/* Do we have Linux routing socket? */ +#undef HAVE_RTNETLINK + /* Define to 1 if you have the `rtprio' function. */ #undef HAVE_RTPRIO -/* Should be obvious... */ -#undef HAVE_SA_LEN_IN_STRUCT_SOCKADDR +/* Define to 1 if you have the header file. */ +#undef HAVE_RUNETYPE_H /* Obvious... */ #undef HAVE_SA_SIGACTION_IN_STRUCT_SIGACTION @@ -640,18 +664,15 @@ /* Define to 1 if you have the `sigvec' function. */ #undef HAVE_SIGVEC +/* Define to 1 if the system has the type `size_t'. */ +#undef HAVE_SIZE_T + /* Define to 1 if you have the `snprintf' function. */ #undef HAVE_SNPRINTF -/* [Are Solaris privileges available?] */ +/* Are Solaris privileges available? */ #undef HAVE_SOLARIS_PRIVS -/* Does struct sockaddr_storage have ss_family? */ -#undef HAVE_SS_FAMILY_IN_SS - -/* Does struct sockaddr_storage have ss_len? */ -#undef HAVE_SS_LEN_IN_SS - /* Define to 1 if you have the header file. */ #undef HAVE_STDARG_H @@ -685,6 +706,9 @@ /* Define to 1 if you have the `strrchr' function. */ #undef HAVE_STRRCHR +/* Define to 1 if you have the `strsignal' function. */ +#undef HAVE_STRSIGNAL + /* Define to 1 if you have the `strstr' function. */ #undef HAVE_STRSTR @@ -948,6 +972,12 @@ /* Define to 1 if you have the header file. */ #undef HAVE_VARARGS_H +/* Define to 1 if you have the `vfork' function. */ +#undef HAVE_VFORK + +/* Define to 1 if you have the header file. */ +#undef HAVE_VFORK_H + /* Define to 1 if you have the `vprintf' function. */ #undef HAVE_VPRINTF @@ -957,6 +987,21 @@ /* Define to 1 if you have the `vsprintf' function. */ #undef HAVE_VSPRINTF +/* Define to 1 if you have the header file. */ +#undef HAVE_WCHAR_H + +/* Define to 1 if the system has the type `wchar_t'. */ +#undef HAVE_WCHAR_T + +/* Define to 1 if the system has the type `wint_t'. */ +#undef HAVE_WINT_T + +/* Define to 1 if `fork' works. */ +#undef HAVE_WORKING_FORK + +/* Define to 1 if `vfork' works. */ +#undef HAVE_WORKING_VFORK + /* Define to 1 if you have the header file. */ #undef HAVE__SYS_SYNC_QUEUE_H @@ -969,12 +1014,31 @@ /* Define to 1 if you have the `__ntp_gettime' function. */ #undef HAVE___NTP_GETTIME +/* Define to 1 if you have the `__res_init' function. */ +#undef HAVE___RES_INIT + /* Does struct sockaddr_storage have __ss_family? */ #undef HAVE___SS_FAMILY_IN_SS + + /* Handle sockaddr_storage.__ss_family */ + #ifdef HAVE___SS_FAMILY_IN_SS + # define ss_family __ss_family + #endif /* HAVE___SS_FAMILY_IN_SS */ + + + /* Does struct sockaddr_storage have __ss_len? */ #undef HAVE___SS_LEN_IN_SS + + /* Handle sockaddr_storage.__ss_len */ + #ifdef HAVE___SS_LEN_IN_SS + # define ss_len __ss_len + #endif /* HAVE___SS_LEN_IN_SS */ + + + /* [Retry queries on _any_ DNS error?] */ #undef IGNORE_DNS_ERRORS @@ -999,15 +1063,12 @@ /* have IPv6? */ #undef ISC_PLATFORM_HAVEIPV6 -/* ISC: struct sockaddr as sa_len? */ +/* struct sockaddr has sa_len? */ #undef ISC_PLATFORM_HAVESALEN /* have sin6_scope_id? */ #undef ISC_PLATFORM_HAVESCOPEID -/* ISC: provide inet_aton() */ -#undef ISC_PLATFORM_NEEDATON - /* missing in6addr_any? */ #undef ISC_PLATFORM_NEEDIN6ADDRANY @@ -1017,7 +1078,7 @@ /* ISC: provide inet_ntop() */ #undef ISC_PLATFORM_NEEDNTOP -/* Do we need our own in_port_t? */ +/* Declare in_port_t? */ #undef ISC_PLATFORM_NEEDPORTT /* ISC: provide inet_pton() */ @@ -1044,7 +1105,7 @@ /* Should we align with the NIST lockclock scheme? */ #undef LOCKCLOCK -/* Does the kernel support multicasting IP? */ +/* Does the target support multicast IP? */ #undef MCAST /* Should we recommend a minimum value for tickadj? */ @@ -1056,6 +1117,9 @@ /* Do we want the HPUX FindConfig()? */ #undef NEED_HPUX_FINDCONFIG +/* We need to provide netsnmp_daemonize() */ +#undef NEED_NETSNMP_DAEMONIZE + /* Do we need the qnx adjtime call? */ #undef NEED_QNX_ADJTIME @@ -1144,9 +1208,6 @@ /* Do we have the ppsclock streams module? */ #undef PPS -/* PPS auxiliary interface for ATOM? */ -#undef PPS_SAMPLE - /* PARSE kernel PLL PPS support */ #undef PPS_SYNC @@ -1156,9 +1217,6 @@ /* Preset a value for 'tickadj'? */ #undef PRESET_TICKADJ -/* Define to 1 if the C compiler supports function prototypes. */ -#undef PROTOTYPES - /* Does qsort expect to work on "void *" stuff? */ #undef QSORT_USES_VOID_P @@ -1177,6 +1235,9 @@ /* Define as the return type of signal handlers (`int' or `void'). */ #undef RETSIGTYPE +/* saveconfig mechanism */ +#undef SAVECONFIG + /* Do we want the SCO clock hacks? */ #undef SCO5_CLOCK @@ -1252,9 +1313,6 @@ /* Do we set process groups with -pid? */ #undef UDP_BACKWARDS_SETOWN -/* How do we create unsigned long constants? */ -#undef ULONG_CONST - /* Must we have a CTTY for fsetown? */ #undef USE_FSETOWNCTTY @@ -1292,9 +1350,6 @@ /* configure --enable-ipv6 */ #undef WANT_IPV6 -/* Do we want the windows symmetric client hack? */ -#undef WINTIME - /* Define this if a working libregex can be found */ #undef WITH_LIBREGEX @@ -1310,16 +1365,6 @@ # endif #endif -/* Handle ss_family */ -#if !defined(HAVE_SS_FAMILY_IN_SS) && defined(HAVE___SS_FAMILY_IN_SS) -# define ss_family __ss_family -#endif /* !defined(HAVE_SS_FAMILY_IN_SS) && defined(HAVE_SA_FAMILY_IN_SS) */ - -/* Handle ss_len */ -#if !defined(HAVE_SS_LEN_IN_SS) && defined(HAVE___SS_LEN_IN_SS) -# define ss_len __ss_len -#endif /* !defined(HAVE_SS_LEN_IN_SS) && defined(HAVE_SA_LEN_IN_SS) */ - /* Define to 1 if on MINIX. */ #undef _MINIX @@ -1335,9 +1380,6 @@ # undef __CHAR_UNSIGNED__ #endif -/* Define like PROTOTYPES; this can be used by system headers. */ -#undef __PROTOTYPES - /* Define to empty if `const' does not conform to ANSI C. */ #undef const @@ -1353,6 +1395,9 @@ /* Define to `long int' if does not define. */ #undef off_t +/* Define to `int' if does not define. */ +#undef pid_t + /* Define to `unsigned int' if does not define. */ #undef size_t @@ -1362,8 +1407,8 @@ /* Define to `int' if doesn't define. */ #undef uid_t -/* Alternate uintptr_t for systems without it. */ -#undef uintptr_t +/* Define as `fork' if `vfork' does not work. */ +#undef vfork /* Does the compiler like "volatile"? */ #undef volatile diff -urN src/contrib/ntp/configure src.ntp/contrib/ntp/configure --- src/contrib/ntp/configure 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/configure 2010-07-09 04:21:39.000000000 +0200 @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.65 for ntp 4.2.4p8. +# Generated by GNU Autoconf 2.65 for ntp 4.2.6p2. # # # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, @@ -699,8 +699,8 @@ # Identity of this package. PACKAGE_NAME='ntp' PACKAGE_TARNAME='ntp' -PACKAGE_VERSION='4.2.4p8' -PACKAGE_STRING='ntp 4.2.4p8' +PACKAGE_VERSION='4.2.6p2' +PACKAGE_STRING='ntp 4.2.6p2' PACKAGE_BUGREPORT='' PACKAGE_URL='' @@ -745,7 +745,14 @@ am__EXEEXT_TRUE LTLIBOBJS LIBOBJS +subdirs +SAVECONFIG_ENABLED_FALSE +SAVECONFIG_ENABLED_TRUE LSCF +MAKE_NTPSNMPD +SNMP_CFLAGS +SNMP_CPPFLAGS +SNMP_LIBS MAKE_NTPDSIM MAKE_LIBNTPSIM MAKE_TIMETRIM @@ -770,9 +777,8 @@ MAKE_LIBPARSE LIBPARSE HAVE_INLINE -ANSI2KNR -U -READLINE_LIBS +EDITLINE_LIBS +PATH_NET_SNMP_CONFIG PATH_PERL PATH_SH LIBTOOL @@ -780,9 +786,11 @@ AR ECHO LN_S -ARLIB_DIR -subdirs +NTP_BINSUBDIR_IS_BIN_FALSE +NTP_BINSUBDIR_IS_BIN_TRUE BINSUBDIR +NTP_CROSSCOMPILE_FALSE +NTP_CROSSCOMPILE_TRUE LIBOPTS_CFLAGS LIBOPTS_LDADD NEED_LIBOPTS_FALSE @@ -790,6 +798,10 @@ INSTALL_LIBOPTS_FALSE INSTALL_LIBOPTS_TRUE LIBOPTS_DIR +VPATH_HACK_FALSE +VPATH_HACK_TRUE +YFLAGS +YACC EGREP GREP CPP @@ -900,11 +912,14 @@ enable_libtool_lock with_pic with_tags +with_net_snmp_config +with_lineeditlibs enable_getifaddrs enable_debugging enable_debug_timing enable_dst_minutes enable_ignore_dns_errors +enable_force_defer_DNS enable_BANCOMM enable_GPSVME enable_all_clocks @@ -965,19 +980,21 @@ enable_tick enable_tickadj enable_simulator +with_ntpsnmpd enable_slew_always enable_step_slew enable_ntpdate_step enable_hourly_todr_sync enable_kernel_fll_bug +enable_bug1243_fix enable_irig_sawtooth enable_nist enable_ntp_signd -enable_wintime enable_clockctl enable_linuxcaps enable_ipv6 with_kame +enable_saveconfig ' ac_precious_vars='build_alias host_alias @@ -987,9 +1004,10 @@ LDFLAGS LIBS CPPFLAGS -CPP' -ac_subdirs_all='arlib -sntp' +CPP +YACC +YFLAGS' +ac_subdirs_all='sntp' # Initialize some variables set by options. ac_init_help= @@ -1530,7 +1548,7 @@ # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures ntp 4.2.4p8 to adapt to many kinds of systems. +\`configure' configures ntp 4.2.6p2 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1600,7 +1618,7 @@ if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of ntp 4.2.4p8:";; + short | recursive ) echo "Configuration of ntp 4.2.6p2:";; esac cat <<\_ACEOF @@ -1622,12 +1640,14 @@ --enable-getifaddrs s Enable the use of getifaddrs() [[yes|no|glibc]]. glibc: Use getifaddrs() in glibc if you know it supports IPv6. - --enable-debugging + include debugging code + --enable-debugging + include ntpd debugging code --enable-debug-timing - include processing time debugging code (costs performance) --enable-dst-minutes n minutes per DST adjustment [60] --enable-ignore-dns-errors - retry DNS queries on any error + --enable-force-defer-DNS + - force all DNS lookups to take the deferred path --enable-BANCOMM - Datum/Bancomm bc635/VME interface --enable-GPSVME - TrueTime GPS receiver/VME interface --enable-all-clocks + include all suitable non-PARSE clocks: @@ -1691,14 +1711,15 @@ --enable-hourly-todr-sync s if we should sync TODR hourly --enable-kernel-fll-bug s if we should avoid a kernel FLL bug + --enable-bug1243-fix + use unmodified autokey session keys --enable-irig-sawtooth s if we should enable the IRIG sawtooth filter --enable-nist - if we should enable the NIST lockclock scheme --enable-ntp-signd - Provide support for Samba's signing daemon, =/var/run/ntp_signd - --enable-wintime - Provide the windows symmetric client hack --enable-clockctl s Use /dev/clockctl for non-root clock control --enable-linuxcaps + Use Linux capabilities for non-root clock control --enable-ipv6 s use IPv6? + --enable-saveconfig + saveconfig mechanism Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] @@ -1709,16 +1730,19 @@ --with-libregex-cflags libregex compile flags --with-libregex-libs libregex link command arguments --with-binsubdir bin ={bin,sbin} - --with-arlib - Compile the async resolver library? + --with-arlib - deprecated, arlib not distributed --without-rpath s Disable auto-added -R linker paths --with-gnu-ld assume the C compiler uses GNU ld [default=no] --with-pic try to use only PIC/non-PIC objects [default=use both] --with-tags[=TAGS] include additional configurations [automatic] + --with-net-snmp-config + =net-snmp-config + --with-lineeditlibs edit,editline (readline may be specified if desired) --with-openssl-libdir + =/something/reasonable --with-openssl-incdir + =/something/reasonable --with-crypto + =openssl --with-electricfence - compile with ElectricFence malloc debugger + --with-ntpsnmpd s Build ntpsnmpd MIB agent? --with-kame - =/usr/local/v6 Some influential environment variables: @@ -1730,6 +1754,11 @@ CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I if you have headers in a nonstandard directory CPP C preprocessor + YACC The `Yet Another C Compiler' implementation to use. Defaults to + the first program found out of: `bison -y', `byacc', `yacc'. + YFLAGS The list of arguments that will be passed by default to $YACC. + This script will default YFLAGS to the empty string to avoid a + default value of `-d' given by some make applications. Use these variables to override the choices made by `configure' or to help it to find libraries and programs with nonstandard names/locations. @@ -1797,7 +1826,7 @@ test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -ntp configure 4.2.4p8 +ntp configure 4.2.6p2 generated by GNU Autoconf 2.65 Copyright (C) 2009 Free Software Foundation, Inc. @@ -2451,7 +2480,7 @@ This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by ntp $as_me 4.2.4p8, which was +It was created by ntp $as_me 4.2.6p2, which was generated by GNU Autoconf 2.65. Invocation command line was $ $0 $@ @@ -2798,10 +2827,9 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu -am__api_version='1.11' ac_aux_dir= -for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do +for ac_dir in . "$srcdir"/.; do for ac_t in install-sh install.sh shtool; do if test -f "$ac_dir/$ac_t"; then ac_aux_dir=$ac_dir @@ -2811,7 +2839,7 @@ done done if test -z "$ac_aux_dir"; then - as_fn_error "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5 + as_fn_error "cannot find install-sh, install.sh, or shtool in . \"$srcdir\"/." "$LINENO" 5 fi # These three variables are undocumented and unsupported, @@ -2823,6 +2851,132 @@ ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. + +# Increment ntp_configure_cache_version by one for each change to +# configure.ac or .m4 files which invalidates cached values from +# previous versions. +# +# If the change affects cache variables used only by the main NTP +# configure.ac, then only its version number should be bumped, while +# the subdir configure.ac version numbers should be unchanged. The +# same is true for a test/variable that is used only by one subdir +# being changed incompatibly; only that subdir's cache version needs +# bumping. +# +# If a change affects variables shared by all NTP configure scripts, +# please bump the version numbers of all three. If you are not sure, +# the safe choice is to bump all three on any cache-invalidating change. +# +# In order to avoid the risk of version stamp collision between -stable +# and -dev branches, do not simply increment the version, instead use +# the date YYYYMMDD optionally with -HHMM if there is more than one +# bump in a day. + +ntp_configure_cache_version=20091117 + +# When the cache version of config.cache and configure do not +# match, NTP_CACHEVERSION will flush the cache. + + + + ntp_cache_flush=1 + + case "$ntp_cv_main_cache_version" in + $ntp_configure_cache_version) + # same version, good + ntp_cache_flush=0 + ;; + '') + # No cache, predates ntp_cv_main_cache_version, or is empty. + case "$cache_file" in + /dev/null) + ntp_cache_flush=0 + ;; + *) + case "$NTP_CACHEVERSION_PARENT" in + '') + # Do not clear the cache immediately after it is created + # empty as it is noisy. Differentiate a newly-created + # config.cache from one predating the cache version + # mechanism by looking for the first cached variable set + # by Autoconf + case "$ac_cv_path_install" in + '') + # empty config.cache file + ntp_cache_flush=0 + esac + ;; + *) + # Parent configure just created cache from empty, + # flushing would be counterproductive. + ntp_cache_flush=0; + esac + esac + ;; + *) + # configure cache version mismatches config.cache version + esac + + case "$ntp_cache_flush" in + 1) + c_version="${ntp_cv_main_cache_version:-(no version found)}" + + # Do we flush all variables or exclude others' version stamps? + + case "$NTP_CACHEVERSION_PARENT" in + '') + # Clear all *_cv_* variables including our child subdirs' + # ntp_cv_*_cache_version variables. This prevents subdir + # configure scripts from noticing a version mismatch just + # after the top configure in the invocation cleared and + # recreated the cache. + + c_varname_list=`set | + sed -n -e 's/=.*$//' \ + -e '/_cv_/p' + ` + ;; + *) + # This is not the top configure this particular invocation. + # Clear all *_cv_* variables sparing the version stamps + # of other configure scripts, so we don't trigger + # useless repeated clearings. + + c_varname_list=`set | + sed -n -e 's/=.*$//' \ + -e '/ntp_cv_.*_cache_version/d' \ + -e '/_cv_/p' + ` + esac + + for c_varname in $c_varname_list + do + eval ${c_varname}=; $as_unset $c_varname + done + + c_varname_list=; $as_unset c_varname_list c_varname + + { $as_echo "$as_me:${as_lineno-$LINENO}: $cache_file saved by another version, ignored." >&5 +$as_echo "$as_me: $cache_file saved by another version, ignored." >&6;} + { $as_echo "$as_me:${as_lineno-$LINENO}: configure script cache version: $ntp_configure_cache_version" >&5 +$as_echo "$as_me: configure script cache version: $ntp_configure_cache_version" >&6;} + { $as_echo "$as_me:${as_lineno-$LINENO}: $cache_file version: $c_version" >&5 +$as_echo "$as_me: $cache_file version: $c_version" >&6;} + $as_unset c_version + esac + + # save configure version in config.cache for next time + ntp_cv_main_cache_version="$ntp_configure_cache_version" + + $as_unset ntp_cache_flush + + # let any subdir configure.ac NTP_CACHEVERSION invocations + # know they are not the top level. + NTP_CACHEVERSION_PARENT='main' ; export NTP_CACHEVERSION_PARENT + + +am__api_version='1.11' + # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or # incompatible versions: @@ -3259,7 +3413,7 @@ # Define the identity of the package. PACKAGE='ntp' - VERSION='4.2.4p8' + VERSION='4.2.6p2' cat >>confdefs.h <<_ACEOF @@ -3378,7 +3532,6 @@ ac_config_headers="$ac_config_headers config.h" - ac_cv_var_atom_ok=no ac_cv_var_oncore_ok=no ac_cv_var_parse_ok=no @@ -5653,6 +5806,193 @@ fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 +$as_echo_n "checking how to run the C preprocessor... " >&6; } +# On Suns, sometimes $CPP names a directory. +if test -n "$CPP" && test -d "$CPP"; then + CPP= +fi +if test -z "$CPP"; then + if test "${ac_cv_prog_CPP+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + # Double quotes because CPP needs to be expanded + for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" + do + ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + break +fi + + done + ac_cv_prog_CPP=$CPP + +fi + CPP=$ac_cv_prog_CPP +else + ac_cv_prog_CPP=$CPP +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 +$as_echo "$CPP" >&6; } +ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + +else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error "C preprocessor \"$CPP\" fails sanity check +See \`config.log' for more details." "$LINENO" 5; } +fi + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +for ac_prog in 'bison -y' byacc +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if test "${ac_cv_prog_YACC+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$YACC"; then + ac_cv_prog_YACC="$YACC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + ac_cv_prog_YACC="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +YACC=$ac_cv_prog_YACC +if test -n "$YACC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5 +$as_echo "$YACC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$YACC" && break +done +test -n "$YACC" || YACC="yacc" + + +# AC_PROG_CC_STDC has two functions. It attempts to find a compiler +# capable of C99, or failing that, for C89. CC is set afterward with +# the selected invocation, such as "gcc --std=gnu99". Also, the +# ac_cv_prog_cc_stdc variable is no if the compiler selected for CC +# does not accept C89. + case $ac_cv_prog_cc_stdc in #( no) : ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #( @@ -5946,157 +6286,17 @@ $as_echo "$ac_cv_prog_cc_stdc" >&6; } ;; esac -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 -$as_echo_n "checking how to run the C preprocessor... " >&6; } -# On Suns, sometimes $CPP names a directory. -if test -n "$CPP" && test -d "$CPP"; then - CPP= -fi -if test -z "$CPP"; then - if test "${ac_cv_prog_CPP+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - # Double quotes because CPP needs to be expanded - for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" - do - ac_preproc_ok=false -for ac_c_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # Prefer to if __STDC__ is defined, since - # exists even on freestanding compilers. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifdef __STDC__ -# include -#else -# include -#endif - Syntax error -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - -else - # Broken: fails on valid input. -continue -fi -rm -f conftest.err conftest.$ac_ext - - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - # Broken: success on invalid input. -continue -else - # Passes both tests. -ac_preproc_ok=: -break -fi -rm -f conftest.err conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.err conftest.$ac_ext -if $ac_preproc_ok; then : - break -fi - - done - ac_cv_prog_CPP=$CPP - -fi - CPP=$ac_cv_prog_CPP -else - ac_cv_prog_CPP=$CPP -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 -$as_echo "$CPP" >&6; } -ac_preproc_ok=false -for ac_c_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # Prefer to if __STDC__ is defined, since - # exists even on freestanding compilers. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifdef __STDC__ -# include -#else -# include -#endif - Syntax error -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - -else - # Broken: fails on valid input. -continue -fi -rm -f conftest.err conftest.$ac_ext - - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - # Broken: success on invalid input. -continue -else - # Passes both tests. -ac_preproc_ok=: -break -fi -rm -f conftest.err conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.err conftest.$ac_ext -if $ac_preproc_ok; then : - -else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error "C preprocessor \"$CPP\" fails sanity check -See \`config.log' for more details." "$LINENO" 5; } -fi - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu +case "$ac_cv_prog_cc_stdc" in + no) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ANSI C89/ISO C90 is the minimum to compile NTP + version 4.2.5 and higher." >&5 +$as_echo "$as_me: WARNING: ANSI C89/ISO C90 is the minimum to compile NTP + version 4.2.5 and higher." >&2;} +esac # HMS: These need to be moved to AM_CPPFLAGS and/or AM_CFLAGS case "$host" in - *-*-amigaos) - CFLAGS="$CFLAGS -Dfork=vfork -DSYS_AMIGA" - ;; - *-*-hpux10.*) # at least for hppa2.0-hp-hpux10.20 - case "$GCC" in - yes) - ;; - *) CFLAGS="$CFLAGS -Wp,-H18816" - ;; - esac - ;; *-pc-cygwin*) CFLAGS="$CFLAGS -DSYS_CYGWIN32" ;; @@ -6123,92 +6323,153 @@ esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking additional compiler flags" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking additional compiler flags" >&5 $as_echo_n "checking additional compiler flags... " >&6; } -if test "${ac_cv_os_cflags+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - -case "${host_os}" in - irix6* ) - case "${CC}" in - cc ) - # do not use 64-bit compiler - ac_cv_os_cflags="-n32 -mips3 -Wl,-woff,84" - ;; - esac - ;; -# HMS: am-utils needed this but we don't (apparently) -# osf[[1-3]]* ) -# # get the right version of struct sockaddr -# case "${CC}" in -# cc ) -# ac_cv_os_cflags="-std -D_SOCKADDR_LEN -D_NO_PROTO" -# ;; -# * ) -# ac_cv_os_cflags="-D_SOCKADDR_LEN -D_NO_PROTO" -# ;; -# esac -# ;; -# osf* ) -# # get the right version of struct sockaddr -# case "${CC}" in -# cc ) -# ac_cv_os_cflags="-std -D_SOCKADDR_LEN" -# ;; -# * ) -# ac_cv_os_cflags="-D_SOCKADDR_LEN" -# ;; -# esac -# ;; - aix[1-3]* ) - ac_cv_os_cflags="" ;; - aix4.[0-2]* ) - # turn on additional headers - ac_cv_os_cflags="-D_XOPEN_EXTENDED_SOURCE" - ;; - aix* ) - # avoid circular dependencies in yp headers - ac_cv_os_cflags="-DHAVE_BAD_HEADERS -D_XOPEN_EXTENDED_SOURCE" + # allow ntp_os_flags to be preset to skip this stuff + case "${ntp_os_cflags+set}" in + set) + ;; + *) + ntp_os_cflags="" + case "$host_os" in + aix[1-3]*) + ;; + aix4.[0-2]*) + # turn on additional headers + ntp_os_cflags="-D_XOPEN_EXTENDED_SOURCE" + ;; + aix5.3*) + # avoid circular dependencies in yp headers, and more + ntp_os_cflags="-DHAVE_BAD_HEADERS -D_XOPEN_EXTENDED_SOURCE" + ntp_os_cflags="${ntp_os_cflags} -D_USE_IRS -D_MSGQSUPPORT" + ;; + aix*) + # avoid circular dependencies in yp headers + ntp_os_cflags="-DHAVE_BAD_HEADERS -D_XOPEN_EXTENDED_SOURCE" + ntp_os_cflags="${ntp_os_cflags} -D_USE_IRS" + ;; + amigaos) + ntp_os_cflags="-DSYS_AMIGA" + ;; + darwin*|macosx*|rhapsody*) + ntp_os_cflags="-D_P1003_1B_VISIBLE" + ;; + hpux10.*) # at least for hppa2.0-hp-hpux10.20 + case "$GCC" in + yes) ;; - OFF-sunos4* ) - # make sure passing whole structures is handled in gcc - case "${CC}" in - gcc ) - ac_cv_os_cflags="-fpcc-struct-return" - ;; - esac + *) + # use Ansi compiler on HPUX, and some -Wp magic + ntp_os_cflags="-Ae -Wp,-H18816" ;; - sunos[34]* | solaris1* | solaris2.[0-5]* | sunos5.[0-5]* ) - ac_cv_os_cflags="" ;; - solaris* | sunos* ) - # turn on 64-bit file offset interface - case "${CC}" in - * ) - ac_cv_os_cflags="-D_LARGEFILE64_SOURCE" - ;; - esac + esac + ntp_os_cflags="${ntp_os_cflags} -D_HPUX_SOURCE" + ;; + hpux*) + case "$GCC" in + yes) ;; - hpux* ) + *) # use Ansi compiler on HPUX - case "${CC}" in - cc ) - ac_cv_os_cflags="-Ae" - ;; - esac - ;; - darwin* | rhapsody* ) - ac_cv_os_cflags="-D_P1003_1B_VISIBLE" - ;; - * ) - ac_cv_os_cflags="" + ntp_os_cflags="-Ae" + esac + ntp_os_cflags="${ntp_os_cflags} -D_HPUX_SOURCE" + ;; + irix6*) + case "$CC" in + cc) + # do not use 64-bit compiler + ntp_os_cflags="-n32 -mips3 -Wl,-woff,84" + esac + ;; + nextstep3) + ntp_os_cflags="-posix" + ;; + solaris1*|solaris2.[0-5]|solaris2.5.*) + ;; + sunos[34]*|sunos5.[0-5]|sunos5.5.*) + ;; + solaris2*|sunos5*) + # turn on 64-bit file offset interface + ntp_os_cflags="-D_LARGEFILE64_SOURCE" + ;; + vxworks*) + case "$build" in + $host) ;; -esac + *) + # Quick and dirty sanity check + case "$VX_KERNEL" in + '') + as_fn_error "See html/build/hints/vxworks.html" "$LINENO" 5 + esac + ntp_os_cflags="-DSYS_VXWORKS" + esac + ;; + esac + esac + case "$ntp_os_flags" in + '') + ntp_os_cflags_msg="none needed" + ;; + *) + ntp_os_cflags_msg="$ntp_os_cflags" + CFLAGS="$CFLAGS $ntp_os_cflags" + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_os_cflags_msg" >&5 +$as_echo "$ntp_os_cflags_msg" >&6; } + { ntp_os_cflags_msg=; unset ntp_os_cflags_msg;} + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for directory path separator" >&5 +$as_echo_n "checking for directory path separator... " >&6; } +if test "${ac_cv_dir_sep+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + case "$ac_cv_dir_sep" in + '') + case "$target_os" in + *djgpp | *mingw32* | *emx*) ac_cv_dir_sep="'\\'" ;; + *) ac_cv_dir_sep="'/'" ;; + esac + ;; + esac + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_dir_sep" >&5 +$as_echo "$ac_cv_dir_sep" >&6; } + +cat >>confdefs.h <<_ACEOF +#define DIR_SEP $ac_cv_dir_sep +_ACEOF + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking to see if we need a VPATH hack" >&5 +$as_echo_n "checking to see if we need a VPATH hack... " >&6; } +ntp_vpath_hack="no" +case "$srcdir::$build_os::${force_ntp_vpath_hack+set}" in + .::*::*) + ;; + *::*::set) + ntp_vpath_hack="yes" + ;; + *::freebsd*::) + case "`${MAKE-make} -v -f /dev/null 2>/dev/null | grep 'GNU Make'`" in + '') + ntp_vpath_hack="yes" + esac +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_vpath_hack" >&5 +$as_echo "$ntp_vpath_hack" >&6; } + if test x$ntp_vpath_hack = xyes; then + VPATH_HACK_TRUE= + VPATH_HACK_FALSE='#' +else + VPATH_HACK_TRUE='#' + VPATH_HACK_FALSE= fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cflags" >&5 -$as_echo "$ac_cv_os_cflags" >&6; } -CFLAGS="$CFLAGS $ac_cv_os_cflags" + # NTP has (so far) been relying on leading-edge autogen. @@ -6224,6 +6485,17 @@ set) ;; *) enable_libopts_install=no ;; esac +ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" +if test "x$ac_cv_type_pid_t" = x""yes; then : + +else + +cat >>confdefs.h <<_ACEOF +#define pid_t int +_ACEOF + +fi + NEED_LIBOPTS_DIR='' @@ -6335,9 +6607,6 @@ if test X${INVOKE_LIBOPTS_MACROS_FIRST_done} != Xyes ; then - # ================= - # AC_HEADER_STDC - # ================= { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 $as_echo_n "checking for ANSI C header files... " >&6; } if test "${ac_cv_header_stdc+set}" = set; then : @@ -6450,9 +6719,6 @@ fi - # ================= - # AC_HEADER_DIRENT - # ================= ac_header_dirent=no for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` @@ -6708,6 +6974,64 @@ as_fn_error "You must have one of limits.h, sys/limits.h or values.h" "$LINENO" 5 fi + # ---------------------------------------------------------------------- + # check for various programs used during the build. + # On OS/X, "wchar.h" needs "runetype.h" to work properly. + # ---------------------------------------------------------------------- + for ac_header in runetype.h wchar.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" " + $ac_includes_default + #if HAVE_RUNETYPE_H + # include + #endif + +" +eval as_val=\$$as_ac_Header + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + + # ---------------------------------------------------------------------- + # Checks for typedefs + # ---------------------------------------------------------------------- + ac_fn_c_check_type "$LINENO" "wchar_t" "ac_cv_type_wchar_t" "$ac_includes_default" +if test "x$ac_cv_type_wchar_t" = x""yes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_WCHAR_T 1 +_ACEOF + + +fi + + ac_fn_c_check_type "$LINENO" "wint_t" "ac_cv_type_wint_t" " + $ac_includes_default + #if HAVE_RUNETYPE_H + # include + #endif + #if HAVE_WCHAR_H + # include + #endif + +" +if test "x$ac_cv_type_wint_t" = x""yes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_WINT_T 1 +_ACEOF + + +fi + + # ======================== # ...and int types headers # ======================== @@ -6788,6 +7112,15 @@ fi +ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default" +if test "x$ac_cv_type_uintptr_t" = x""yes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_UINTPTR_T 1 +_ACEOF + + +fi ac_fn_c_check_type "$LINENO" "uint_t" "ac_cv_type_uint_t" "$ac_includes_default" if test "x$ac_cv_type_uint_t" = x""yes; then : @@ -6797,25 +7130,29 @@ fi - - - # ==================== - # uintptr type & sizes - # ==================== - ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default" -if test "x$ac_cv_type_uintptr_t" = x""yes; then : +ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" +if test "x$ac_cv_type_pid_t" = x""yes; then : cat >>confdefs.h <<_ACEOF -#define HAVE_UINTPTR_T 1 +#define HAVE_PID_T 1 _ACEOF -else +fi +ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" +if test "x$ac_cv_type_size_t" = x""yes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_SIZE_T 1 +_ACEOF -$as_echo "#define uintptr_t unsigned long" >>confdefs.h fi + + # ===== + # sizes + # ===== # The cast to long int works around a bug in the HP C Compiler # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. @@ -7020,7 +7357,19 @@ done - for ac_func in mmap canonicalize_file_name snprintf strdup strchr strrchr + for ac_header in vfork.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default" +if test "x$ac_cv_header_vfork_h" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_VFORK_H 1 +_ACEOF + +fi + +done + +for ac_func in fork vfork do : as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" @@ -7033,26 +7382,229 @@ fi done - INVOKE_LIBOPTS_MACROS_FIRST_done=yes -fi - # Check to see if a reg expr header is specified. - - -# Check whether --with-regex-header was given. -if test "${with_regex_header+set}" = set; then : - withval=$with_regex_header; libopts_cv_with_regex_header=${with_regex_header} -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a reg expr header is specified" >&5 -$as_echo_n "checking whether a reg expr header is specified... " >&6; } -if test "${libopts_cv_with_regex_header+set}" = set; then : +if test "x$ac_cv_func_fork" = xyes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5 +$as_echo_n "checking for working fork... " >&6; } +if test "${ac_cv_func_fork_works+set}" = set; then : $as_echo_n "(cached) " >&6 else - libopts_cv_with_regex_header=no -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_regex_header" >&5 -$as_echo "$libopts_cv_with_regex_header" >&6; } - -fi + if test "$cross_compiling" = yes; then : + ac_cv_func_fork_works=cross +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ + + /* By Ruediger Kuhlmann. */ + return fork () < 0; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_func_fork_works=yes +else + ac_cv_func_fork_works=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5 +$as_echo "$ac_cv_func_fork_works" >&6; } + +else + ac_cv_func_fork_works=$ac_cv_func_fork +fi +if test "x$ac_cv_func_fork_works" = xcross; then + case $host in + *-*-amigaos* | *-*-msdosdjgpp*) + # Override, as these systems have only a dummy fork() stub + ac_cv_func_fork_works=no + ;; + *) + ac_cv_func_fork_works=yes + ;; + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5 +$as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;} +fi +ac_cv_func_vfork_works=$ac_cv_func_vfork +if test "x$ac_cv_func_vfork" = xyes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5 +$as_echo_n "checking for working vfork... " >&6; } +if test "${ac_cv_func_vfork_works+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ac_cv_func_vfork_works=cross +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* Thanks to Paul Eggert for this test. */ +$ac_includes_default +#include +#ifdef HAVE_VFORK_H +# include +#endif +/* On some sparc systems, changes by the child to local and incoming + argument registers are propagated back to the parent. The compiler + is told about this with #include , but some compilers + (e.g. gcc -O) don't grok . Test for this by using a + static variable whose address is put into a register that is + clobbered by the vfork. */ +static void +#ifdef __cplusplus +sparc_address_test (int arg) +# else +sparc_address_test (arg) int arg; +#endif +{ + static pid_t child; + if (!child) { + child = vfork (); + if (child < 0) { + perror ("vfork"); + _exit(2); + } + if (!child) { + arg = getpid(); + write(-1, "", 0); + _exit (arg); + } + } +} + +int +main () +{ + pid_t parent = getpid (); + pid_t child; + + sparc_address_test (0); + + child = vfork (); + + if (child == 0) { + /* Here is another test for sparc vfork register problems. This + test uses lots of local variables, at least as many local + variables as main has allocated so far including compiler + temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris + 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should + reuse the register of parent for one of the local variables, + since it will think that parent can't possibly be used any more + in this routine. Assigning to the local variable will thus + munge parent in the parent process. */ + pid_t + p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(), + p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid(); + /* Convince the compiler that p..p7 are live; otherwise, it might + use the same hardware register for all 8 local variables. */ + if (p != p1 || p != p2 || p != p3 || p != p4 + || p != p5 || p != p6 || p != p7) + _exit(1); + + /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent + from child file descriptors. If the child closes a descriptor + before it execs or exits, this munges the parent's descriptor + as well. Test for this by closing stdout in the child. */ + _exit(close(fileno(stdout)) != 0); + } else { + int status; + struct stat st; + + while (wait(&status) != child) + ; + return ( + /* Was there some problem with vforking? */ + child < 0 + + /* Did the child fail? (This shouldn't happen.) */ + || status + + /* Did the vfork/compiler bug occur? */ + || parent != getpid() + + /* Did the file descriptor bug occur? */ + || fstat(fileno(stdout), &st) != 0 + ); + } +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_func_vfork_works=yes +else + ac_cv_func_vfork_works=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5 +$as_echo "$ac_cv_func_vfork_works" >&6; } + +fi; +if test "x$ac_cv_func_fork_works" = xcross; then + ac_cv_func_vfork_works=$ac_cv_func_vfork + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5 +$as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;} +fi + +if test "x$ac_cv_func_vfork_works" = xyes; then + +$as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h + +else + +$as_echo "#define vfork fork" >>confdefs.h + +fi +if test "x$ac_cv_func_fork_works" = xyes; then + +$as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h + +fi + + for ac_func in mmap canonicalize_file_name snprintf strdup strchr \ + strrchr strsignal +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +eval as_val=\$$as_ac_var + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + +fi +done + + INVOKE_LIBOPTS_MACROS_FIRST_done=yes +fi + # Check to see if a reg expr header is specified. + + +# Check whether --with-regex-header was given. +if test "${with_regex_header+set}" = set; then : + withval=$with_regex_header; libopts_cv_with_regex_header=${with_regex_header} +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a reg expr header is specified" >&5 +$as_echo_n "checking whether a reg expr header is specified... " >&6; } +if test "${libopts_cv_with_regex_header+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + libopts_cv_with_regex_header=no +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_regex_header" >&5 +$as_echo "$libopts_cv_with_regex_header" >&6; } + +fi # end of AC_ARG_WITH if test "X${libopts_cv_with_regex_header}" != Xno @@ -7532,9 +8084,6 @@ else if test X${INVOKE_LIBOPTS_MACROS_FIRST_done} != Xyes ; then - # ================= - # AC_HEADER_STDC - # ================= { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 $as_echo_n "checking for ANSI C header files... " >&6; } if test "${ac_cv_header_stdc+set}" = set; then : @@ -7647,9 +8196,6 @@ fi - # ================= - # AC_HEADER_DIRENT - # ================= ac_header_dirent=no for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` @@ -7905,6 +8451,64 @@ as_fn_error "You must have one of limits.h, sys/limits.h or values.h" "$LINENO" 5 fi + # ---------------------------------------------------------------------- + # check for various programs used during the build. + # On OS/X, "wchar.h" needs "runetype.h" to work properly. + # ---------------------------------------------------------------------- + for ac_header in runetype.h wchar.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" " + $ac_includes_default + #if HAVE_RUNETYPE_H + # include + #endif + +" +eval as_val=\$$as_ac_Header + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + + # ---------------------------------------------------------------------- + # Checks for typedefs + # ---------------------------------------------------------------------- + ac_fn_c_check_type "$LINENO" "wchar_t" "ac_cv_type_wchar_t" "$ac_includes_default" +if test "x$ac_cv_type_wchar_t" = x""yes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_WCHAR_T 1 +_ACEOF + + +fi + + ac_fn_c_check_type "$LINENO" "wint_t" "ac_cv_type_wint_t" " + $ac_includes_default + #if HAVE_RUNETYPE_H + # include + #endif + #if HAVE_WCHAR_H + # include + #endif + +" +if test "x$ac_cv_type_wint_t" = x""yes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_WINT_T 1 +_ACEOF + + +fi + + # ======================== # ...and int types headers # ======================== @@ -7985,6 +8589,15 @@ fi +ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default" +if test "x$ac_cv_type_uintptr_t" = x""yes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_UINTPTR_T 1 +_ACEOF + + +fi ac_fn_c_check_type "$LINENO" "uint_t" "ac_cv_type_uint_t" "$ac_includes_default" if test "x$ac_cv_type_uint_t" = x""yes; then : @@ -7994,25 +8607,29 @@ fi - - - # ==================== - # uintptr type & sizes - # ==================== - ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default" -if test "x$ac_cv_type_uintptr_t" = x""yes; then : +ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" +if test "x$ac_cv_type_pid_t" = x""yes; then : cat >>confdefs.h <<_ACEOF -#define HAVE_UINTPTR_T 1 +#define HAVE_PID_T 1 _ACEOF -else +fi +ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" +if test "x$ac_cv_type_size_t" = x""yes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_SIZE_T 1 +_ACEOF -$as_echo "#define uintptr_t unsigned long" >>confdefs.h fi + + # ===== + # sizes + # ===== # The cast to long int works around a bug in the HP C Compiler # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. @@ -8217,7 +8834,222 @@ done - for ac_func in mmap canonicalize_file_name snprintf strdup strchr strrchr + for ac_header in vfork.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default" +if test "x$ac_cv_header_vfork_h" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_VFORK_H 1 +_ACEOF + +fi + +done + +for ac_func in fork vfork +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +eval as_val=\$$as_ac_var + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + +fi +done + +if test "x$ac_cv_func_fork" = xyes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5 +$as_echo_n "checking for working fork... " >&6; } +if test "${ac_cv_func_fork_works+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ac_cv_func_fork_works=cross +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ + + /* By Ruediger Kuhlmann. */ + return fork () < 0; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_func_fork_works=yes +else + ac_cv_func_fork_works=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5 +$as_echo "$ac_cv_func_fork_works" >&6; } + +else + ac_cv_func_fork_works=$ac_cv_func_fork +fi +if test "x$ac_cv_func_fork_works" = xcross; then + case $host in + *-*-amigaos* | *-*-msdosdjgpp*) + # Override, as these systems have only a dummy fork() stub + ac_cv_func_fork_works=no + ;; + *) + ac_cv_func_fork_works=yes + ;; + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5 +$as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;} +fi +ac_cv_func_vfork_works=$ac_cv_func_vfork +if test "x$ac_cv_func_vfork" = xyes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5 +$as_echo_n "checking for working vfork... " >&6; } +if test "${ac_cv_func_vfork_works+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ac_cv_func_vfork_works=cross +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* Thanks to Paul Eggert for this test. */ +$ac_includes_default +#include +#ifdef HAVE_VFORK_H +# include +#endif +/* On some sparc systems, changes by the child to local and incoming + argument registers are propagated back to the parent. The compiler + is told about this with #include , but some compilers + (e.g. gcc -O) don't grok . Test for this by using a + static variable whose address is put into a register that is + clobbered by the vfork. */ +static void +#ifdef __cplusplus +sparc_address_test (int arg) +# else +sparc_address_test (arg) int arg; +#endif +{ + static pid_t child; + if (!child) { + child = vfork (); + if (child < 0) { + perror ("vfork"); + _exit(2); + } + if (!child) { + arg = getpid(); + write(-1, "", 0); + _exit (arg); + } + } +} + +int +main () +{ + pid_t parent = getpid (); + pid_t child; + + sparc_address_test (0); + + child = vfork (); + + if (child == 0) { + /* Here is another test for sparc vfork register problems. This + test uses lots of local variables, at least as many local + variables as main has allocated so far including compiler + temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris + 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should + reuse the register of parent for one of the local variables, + since it will think that parent can't possibly be used any more + in this routine. Assigning to the local variable will thus + munge parent in the parent process. */ + pid_t + p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(), + p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid(); + /* Convince the compiler that p..p7 are live; otherwise, it might + use the same hardware register for all 8 local variables. */ + if (p != p1 || p != p2 || p != p3 || p != p4 + || p != p5 || p != p6 || p != p7) + _exit(1); + + /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent + from child file descriptors. If the child closes a descriptor + before it execs or exits, this munges the parent's descriptor + as well. Test for this by closing stdout in the child. */ + _exit(close(fileno(stdout)) != 0); + } else { + int status; + struct stat st; + + while (wait(&status) != child) + ; + return ( + /* Was there some problem with vforking? */ + child < 0 + + /* Did the child fail? (This shouldn't happen.) */ + || status + + /* Did the vfork/compiler bug occur? */ + || parent != getpid() + + /* Did the file descriptor bug occur? */ + || fstat(fileno(stdout), &st) != 0 + ); + } +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_func_vfork_works=yes +else + ac_cv_func_vfork_works=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5 +$as_echo "$ac_cv_func_vfork_works" >&6; } + +fi; +if test "x$ac_cv_func_fork_works" = xcross; then + ac_cv_func_vfork_works=$ac_cv_func_vfork + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5 +$as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;} +fi + +if test "x$ac_cv_func_vfork_works" = xyes; then + +$as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h + +else + +$as_echo "#define vfork fork" >>confdefs.h + +fi +if test "x$ac_cv_func_fork_works" = xyes; then + +$as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h + +fi + + for ac_func in mmap canonicalize_file_name snprintf strdup strchr \ + strrchr strsignal do : as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" @@ -8236,6 +9068,221 @@ # end of AC_DEFUN of LIBOPTS_CHECK +for ac_header in vfork.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default" +if test "x$ac_cv_header_vfork_h" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_VFORK_H 1 +_ACEOF + +fi + +done + +for ac_func in fork vfork +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +eval as_val=\$$as_ac_var + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + +fi +done + +if test "x$ac_cv_func_fork" = xyes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5 +$as_echo_n "checking for working fork... " >&6; } +if test "${ac_cv_func_fork_works+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ac_cv_func_fork_works=cross +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ + + /* By Ruediger Kuhlmann. */ + return fork () < 0; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_func_fork_works=yes +else + ac_cv_func_fork_works=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5 +$as_echo "$ac_cv_func_fork_works" >&6; } + +else + ac_cv_func_fork_works=$ac_cv_func_fork +fi +if test "x$ac_cv_func_fork_works" = xcross; then + case $host in + *-*-amigaos* | *-*-msdosdjgpp*) + # Override, as these systems have only a dummy fork() stub + ac_cv_func_fork_works=no + ;; + *) + ac_cv_func_fork_works=yes + ;; + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5 +$as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;} +fi +ac_cv_func_vfork_works=$ac_cv_func_vfork +if test "x$ac_cv_func_vfork" = xyes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5 +$as_echo_n "checking for working vfork... " >&6; } +if test "${ac_cv_func_vfork_works+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ac_cv_func_vfork_works=cross +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* Thanks to Paul Eggert for this test. */ +$ac_includes_default +#include +#ifdef HAVE_VFORK_H +# include +#endif +/* On some sparc systems, changes by the child to local and incoming + argument registers are propagated back to the parent. The compiler + is told about this with #include , but some compilers + (e.g. gcc -O) don't grok . Test for this by using a + static variable whose address is put into a register that is + clobbered by the vfork. */ +static void +#ifdef __cplusplus +sparc_address_test (int arg) +# else +sparc_address_test (arg) int arg; +#endif +{ + static pid_t child; + if (!child) { + child = vfork (); + if (child < 0) { + perror ("vfork"); + _exit(2); + } + if (!child) { + arg = getpid(); + write(-1, "", 0); + _exit (arg); + } + } +} + +int +main () +{ + pid_t parent = getpid (); + pid_t child; + + sparc_address_test (0); + + child = vfork (); + + if (child == 0) { + /* Here is another test for sparc vfork register problems. This + test uses lots of local variables, at least as many local + variables as main has allocated so far including compiler + temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris + 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should + reuse the register of parent for one of the local variables, + since it will think that parent can't possibly be used any more + in this routine. Assigning to the local variable will thus + munge parent in the parent process. */ + pid_t + p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(), + p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid(); + /* Convince the compiler that p..p7 are live; otherwise, it might + use the same hardware register for all 8 local variables. */ + if (p != p1 || p != p2 || p != p3 || p != p4 + || p != p5 || p != p6 || p != p7) + _exit(1); + + /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent + from child file descriptors. If the child closes a descriptor + before it execs or exits, this munges the parent's descriptor + as well. Test for this by closing stdout in the child. */ + _exit(close(fileno(stdout)) != 0); + } else { + int status; + struct stat st; + + while (wait(&status) != child) + ; + return ( + /* Was there some problem with vforking? */ + child < 0 + + /* Did the child fail? (This shouldn't happen.) */ + || status + + /* Did the vfork/compiler bug occur? */ + || parent != getpid() + + /* Did the file descriptor bug occur? */ + || fstat(fileno(stdout), &st) != 0 + ); + } +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_func_vfork_works=yes +else + ac_cv_func_vfork_works=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5 +$as_echo "$ac_cv_func_vfork_works" >&6; } + +fi; +if test "x$ac_cv_func_fork_works" = xcross; then + ac_cv_func_vfork_works=$ac_cv_func_vfork + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5 +$as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;} +fi + +if test "x$ac_cv_func_vfork_works" = xyes; then + +$as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h + +else + +$as_echo "#define vfork fork" >>confdefs.h + +fi +if test "x$ac_cv_func_fork_works" = xyes; then + +$as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h + +fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC can handle #warning" >&5 $as_echo_n "checking if $CC can handle #warning... " >&6; } if test "${ac_cv_cpp_warning+set}" = set; then : @@ -8306,7 +9353,7 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gcc_Wstrict_overflow" >&5 $as_echo "$ac_cv_gcc_Wstrict_overflow" >&6; } CFLAGS="$SAVED_CFLAGS_AC" - unset SAVED_CFLAGS_AC + $as_unset SAVED_CFLAGS_AC # # $ac_cv_gcc_Wstrict_overflow is tested later to add the # flag to CFLAGS. @@ -8348,13 +9395,21 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gcc_Winit_self" >&5 $as_echo "$ac_cv_gcc_Winit_self" >&6; } CFLAGS="$SAVED_CFLAGS_AC" - unset SAVED_CFLAGS_AC + $as_unset SAVED_CFLAGS_AC # # $ac_cv_gcc_Winit_self is tested later to add the # flag to CFLAGS. # esac +# Expose a cross-compilation indicator to makefiles + if test $build != $host; then + NTP_CROSSCOMPILE_TRUE= + NTP_CROSSCOMPILE_FALSE='#' +else + NTP_CROSSCOMPILE_TRUE='#' + NTP_CROSSCOMPILE_FALSE= +fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bin subdirectory" >&5 @@ -8379,11 +9434,20 @@ esac { $as_echo "$as_me:${as_lineno-$LINENO}: result: $use_binsubdir" >&5 $as_echo "$use_binsubdir" >&6; } + BINSUBDIR=$use_binsubdir + if test "bin" = "$BINSUBDIR"; then + NTP_BINSUBDIR_IS_BIN_TRUE= + NTP_BINSUBDIR_IS_BIN_FALSE='#' +else + NTP_BINSUBDIR_IS_BIN_TRUE='#' + NTP_BINSUBDIR_IS_BIN_FALSE= +fi + -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to use arlib" >&5 -$as_echo_n "checking if we want to use arlib... " >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for deprecated --with-arlib" >&5 +$as_echo_n "checking for deprecated --with-arlib... " >&6; } # Check whether --with-arlib was given. if test "${with_arlib+set}" = set; then : @@ -8395,19 +9459,11 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 $as_echo "$ans" >&6; } -if test -d $srcdir/arlib -then - case "$ans" in - yes) - ARLIB_DIR=arlib - - -subdirs="$subdirs arlib" - - ;; - esac -fi - +case "$ans" in + yes) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Please do not use --with-arlib, arlib is no longer included. In the future, --with-arlib will not be recognized." >&5 +$as_echo "$as_me: WARNING: Please do not use --with-arlib, arlib is no longer included. In the future, --with-arlib will not be recognized." >&2;} +esac # Check whether --with-rpath was given. @@ -8441,24 +9497,7 @@ case "$need_dash_r" in no) ;; *) need_dash_r=1 - ;; - esac - ;; -esac - - -case "$build" in - $host) - ;; - *) case "$host" in - *-*-vxworks*) - # Quick and dirty sanity check - case "$VX_KERNEL" in - '') as_fn_error "Please follow the directions in html/build/hints/vxworks.html!" "$LINENO" 5 - ;; - esac - CFLAGS="$CFLAGS -DSYS_VXWORKS" - ;; + ;; esac ;; esac @@ -8551,16 +9590,6 @@ CFLAGS="$CFLAGS -Wmissing-prototypes" CFLAGS="$CFLAGS -Wpointer-arith" CFLAGS="$CFLAGS -Wshadow" - # - # OpenSSL has a number of callback prototypes - # inside other function prototypes which trigger - # warnings with -Wstrict-prototypes, such as: - # - # int i2d_RSA_NET(const RSA *a, unsigned char **pp, - # int (*cb)(), int sgckey); - # ^^^^^^^^^^^ - # - CFLAGS="$CFLAGS -Wno-strict-prototypes" # CFLAGS="$CFLAGS -Wtraditional" # CFLAGS="$CFLAGS -Wwrite-strings" case "$ac_cv_gcc_Winit_self" in @@ -8569,15 +9598,9 @@ esac case "$ac_cv_gcc_Wstrict_overflow" in yes) - #not yet: CFLAGS="$CFLAGS -Wstrict-overflow" + CFLAGS="$CFLAGS -Wstrict-overflow" esac - ;; -esac - -case "$host" in - *-next-nextstep3) - CFLAGS="$CFLAGS -posix" - ;; + # -W[no-]strict-prototypes is added later depending on OpenSSL esac ac_busted_vpath_in_make=no @@ -9123,7 +10146,7 @@ ;; *-*-irix6*) # Find out which ABI we are using. - echo '#line 9126 "configure"' > conftest.$ac_ext + echo '#line 10149 "configure"' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? @@ -10258,11 +11281,11 @@ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:10261: $lt_compile\"" >&5) + (eval echo "\"\$as_me:11284: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:10265: \$? = $ac_status" >&5 + echo "$as_me:11288: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -10520,11 +11543,11 @@ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:10523: $lt_compile\"" >&5) + (eval echo "\"\$as_me:11546: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:10527: \$? = $ac_status" >&5 + echo "$as_me:11550: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -10582,11 +11605,11 @@ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:10585: $lt_compile\"" >&5) + (eval echo "\"\$as_me:11608: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:10589: \$? = $ac_status" >&5 + echo "$as_me:11612: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized @@ -12454,7 +13477,7 @@ lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext < conftest.$ac_ext <&5) + (eval echo "\"\$as_me:14357: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:13338: \$? = $ac_status" >&5 + echo "$as_me:14361: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -13593,11 +14616,11 @@ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:13596: $lt_compile\"" >&5) + (eval echo "\"\$as_me:14619: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:13600: \$? = $ac_status" >&5 + echo "$as_me:14623: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -13655,11 +14678,11 @@ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:13658: $lt_compile\"" >&5) + (eval echo "\"\$as_me:14681: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:13662: \$? = $ac_status" >&5 + echo "$as_me:14685: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized @@ -15527,7 +16550,7 @@ lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext < conftest.$ac_ext <conftest.$ac_ext -/* end confdefs.h. */ -#define ACAT(a,b)a ## b -ACAT(Cir,cus) - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "Circus" >/dev/null 2>&1; then : - $as_echo "#define ULONG_CONST(a) a ## UL" >>confdefs.h - +# Check whether --with-net-snmp-config was given. +if test "${with_net_snmp_config+set}" = set; then : + withval=$with_net_snmp_config; ans=$withval else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#define RCAT(a,b)a/**/b -RCAT(Rei,ser) + ans=yes +fi -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "Reiser" >/dev/null 2>&1; then : - $as_echo "#define ULONG_CONST(a) a/**/L" >>confdefs.h +case "$ans" in + no) ;; + yes) + ans=net-snmp-config + ;; + /*) ;; + */*) + as_fn_error "--with-net-snmp-config takes either a name or an absolute path" "$LINENO" 5 + ;; + *) + ;; +esac +PROG_NET_SNMP_CONFIG=$ans +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for net-snmp-config path" >&5 +$as_echo_n "checking for net-snmp-config path... " >&6; } +case "$PROG_NET_SNMP_CONFIG" in + no) ;; + /*) + PATH_NET_SNMP_CONFIG=$PROG_NET_SNMP_CONFIG + ;; + *) # Extract the first word of "$PROG_NET_SNMP_CONFIG", so it can be a program name with args. +set dummy $PROG_NET_SNMP_CONFIG; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if test "${ac_cv_path_PATH_NET_SNMP_CONFIG+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + case $PATH_NET_SNMP_CONFIG in + [\\/]* | ?:[\\/]*) + ac_cv_path_PATH_NET_SNMP_CONFIG="$PATH_NET_SNMP_CONFIG" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + ac_cv_path_PATH_NET_SNMP_CONFIG="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + ;; +esac +fi +PATH_NET_SNMP_CONFIG=$ac_cv_path_PATH_NET_SNMP_CONFIG +if test -n "$PATH_NET_SNMP_CONFIG"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATH_NET_SNMP_CONFIG" >&5 +$as_echo "$PATH_NET_SNMP_CONFIG" >&6; } else - as_fn_error "How do we create an unsigned long constant?" "$LINENO" 5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi -rm -f conftest* -fi -rm -f conftest* - # remove for 4.2.5 + + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATH_NET_SNMP_CONFIG" >&5 +$as_echo "$PATH_NET_SNMP_CONFIG" >&6; } case "$host" in *-*-vxworks*) @@ -17216,35 +18281,38 @@ done -# following block becomes on 4.2.5: NTP_LINEEDITLIBS -for ac_header in readline/history.h readline/readline.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF + NTP_ORIG_LIBS="$LIBS" + +# Check whether --with-lineeditlibs was given. +if test "${with_lineeditlibs+set}" = set; then : + withval=$with_lineeditlibs; use_lineeditlibs="$withval" +else + use_lineeditlibs="edit,editline" fi -done -case "$ac_cv_header_readline_history_h$ac_cv_header_readline_readline_h" in - *no*) ;; - *) save_LIBS=$LIBS - LIBS= - # Ralf Wildenhues: either unset ... or cache READLINE_LIBS - unset ac_cv_lib_readline_readline - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for readline in -lreadline" >&5 -$as_echo_n "checking for readline in -lreadline... " >&6; } -if test "${ac_cv_lib_readline_readline+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lreadline $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + { $as_echo "$as_me:${as_lineno-$LINENO}: checking line editing libraries" >&5 +$as_echo_n "checking line editing libraries... " >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $use_lineeditlibs" >&5 +$as_echo "$use_lineeditlibs" >&6; } + case "$use_lineeditlibs" in + no) + ntp_lib_lineedit=no + ;; + *) + for lineedit_lib in `echo $use_lineeditlibs | sed -e 's/,/ /'`; do + for term_lib in "" termcap curses ncurses; do + case "$term_lib" in + '') + TRY_LIB="-l$lineedit_lib" + ;; + *) TRY_LIB="-l$lineedit_lib -l$term_lib" + esac # $term_lib + LIBS="$NTP_ORIG_LIBS $TRY_LIB" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for readline() with $TRY_LIB" >&5 +$as_echo_n "checking for readline() with $TRY_LIB... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. @@ -17263,35 +18331,29 @@ } _ACEOF if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_readline_readline=yes -else - ac_cv_lib_readline_readline=no + ntp_lib_lineedit="$TRY_LIB" fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_readline" >&5 -$as_echo "$ac_cv_lib_readline_readline" >&6; } -if test "x$ac_cv_lib_readline_readline" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBREADLINE 1 -_ACEOF - - LIBS="-lreadline $LIBS" - -else - { $as_echo "$as_me:${as_lineno-$LINENO}: Trying again with -lcurses" >&5 -$as_echo "$as_me: Trying again with -lcurses" >&6;} - unset ac_cv_lib_readline_readline - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for readline in -lreadline" >&5 -$as_echo_n "checking for readline in -lreadline... " >&6; } -if test "${ac_cv_lib_readline_readline+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lreadline -lcurses $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + case "$ntp_lib_lineedit" in + '') + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + ;; + *) + # Use readline() + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + break + esac # $ntp_lib_lineedit + case "$term_lib" in + '') + # do not try el_gets without a terminal library + ;; + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for el_gets() with $TRY_LIB" >&5 +$as_echo_n "checking for el_gets() with $TRY_LIB... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. @@ -17300,42 +18362,94 @@ #ifdef __cplusplus extern "C" #endif -char readline (); +char el_gets (); int main () { -return readline (); +return el_gets (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_readline_readline=yes -else - ac_cv_lib_readline_readline=no + ntp_lib_lineedit="$TRY_LIB" fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS + case "$ntp_lib_lineedit" in + '') + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + ;; + *) # Use el_gets() + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + break + ;; + esac # $ntp_lib_lineedit + esac # $term_lib + done + case "$ntp_lib_lineedit" in + '') ;; + *) break ;; + esac + done + LIBS="$NTP_ORIG_LIBS" + ;; + esac # $use_lineeditlibs + + case "$ntp_lib_lineedit" in + '') + ntp_lib_lineedit="no" + ;; + no) + ;; + *) + EDITLINE_LIBS="$ntp_lib_lineedit" + + ;; + esac # $ntp_lib_lineedit + + case "$ntp_lib_lineedit" in + no) + ;; + *) + for ac_header in readline.h readline/readline.h histedit.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +eval as_val=\$$as_ac_Header + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + for ac_header in history.h readline/history.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +eval as_val=\$$as_ac_Header + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_readline" >&5 -$as_echo "$ac_cv_lib_readline_readline" >&6; } -if test "x$ac_cv_lib_readline_readline" = x""yes; then : - LIBS="-lreadline -lcurses $LIBS" - $as_echo "#define HAVE_LIBREADLINE 1" >>confdefs.h +done -$as_echo "#define HAVE_LIBCURSES /**/" >>confdefs.h -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for readline in -ledit" >&5 -$as_echo_n "checking for readline in -ledit... " >&6; } -if test "${ac_cv_lib_edit_readline+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ledit -lcurses $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readline supports history" >&5 +$as_echo_n "checking whether readline supports history... " >&6; } + + ntp_lib_lineedit_history="no" + ORIG_LIBS="$LIBS" + LIBS="$ORIG_LIBS $ntp_lib_lineedit" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. @@ -17344,51 +18458,40 @@ #ifdef __cplusplus extern "C" #endif -char readline (); +char add_history (); int main () { -return readline (); +return add_history (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_edit_readline=yes -else - ac_cv_lib_edit_readline=no + ntp_lib_lineedit_history="yes" fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_edit_readline" >&5 -$as_echo "$ac_cv_lib_edit_readline" >&6; } -if test "x$ac_cv_lib_edit_readline" = x""yes; then : - LIBS="-ledit -lcurses" - -$as_echo "#define HAVE_LIBEDIT /**/" >>confdefs.h - + LIBS="$ORIG_LIBS" -$as_echo "#define HAVE_LIBCURSES /**/" >>confdefs.h + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_lib_lineedit_history" >&5 +$as_echo "$ntp_lib_lineedit_history" >&6; } + case "$ntp_lib_lineedit_history" in + yes) -fi - - -fi +$as_echo "#define HAVE_READLINE_HISTORY 1" >>confdefs.h -fi - - READLINE_LIBS=$LIBS + esac # $ntp_lib_lineedit_history + esac # $ntp_lib_lineedit + $as_unset NTP_ORIG_LIBS TRY_LIB use_lineeditlibs - LIBS=$save_LIBS - ;; -esac case "$host" in *-*-*linux*) ;; + *-*-osf4*) ;; + *-*-osf5*) ;; *) { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sched_setscheduler in -lrt" >&5 $as_echo_n "checking for sched_setscheduler in -lrt... " >&6; } @@ -17484,16 +18587,127 @@ ;; esac -ac_fn_c_check_func "$LINENO" "setsockopt" "ac_cv_func_setsockopt" -if test "x$ac_cv_func_setsockopt" = x""yes; then : - -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setsockopt" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setsockopt" >&5 $as_echo_n "checking for library containing setsockopt... " >&6; } if test "${ac_cv_search_setsockopt+set}" = set; then : $as_echo_n "(cached) " >&6 else - ac_func_search_save_LIBS=$LIBS + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char setsockopt (); +int +main () +{ +return setsockopt (); + ; + return 0; +} +_ACEOF +for ac_lib in '' socket xnet; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_setsockopt=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if test "${ac_cv_search_setsockopt+set}" = set; then : + break +fi +done +if test "${ac_cv_search_setsockopt+set}" = set; then : + +else + ac_cv_search_setsockopt=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_setsockopt" >&5 +$as_echo "$ac_cv_search_setsockopt" >&6; } +ac_res=$ac_cv_search_setsockopt +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing res_init" >&5 +$as_echo_n "checking for library containing res_init... " >&6; } +if test "${ac_cv_search_res_init+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char res_init (); +int +main () +{ +return res_init (); + ; + return 0; +} +_ACEOF +for ac_lib in '' resolv; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib -lsocket -lnsl $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_res_init=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if test "${ac_cv_search_res_init+set}" = set; then : + break +fi +done +if test "${ac_cv_search_res_init+set}" = set; then : + +else + ac_cv_search_res_init=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_res_init" >&5 +$as_echo "$ac_cv_search_res_init" >&6; } +ac_res=$ac_cv_search_res_init +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + +case "$host" in + *-*-darwin*) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_9_init in -lresolv" >&5 +$as_echo_n "checking for res_9_init in -lresolv... " >&6; } +if test "${ac_cv_lib_resolv_res_9_init+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lresolv $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -17503,48 +18717,76 @@ #ifdef __cplusplus extern "C" #endif -char setsockopt (); +char res_9_init (); int main () { -return setsockopt (); +return res_9_init (); ; return 0; } _ACEOF -for ac_lib in '' socket xnet; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_setsockopt=$ac_res +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_resolv_res_9_init=yes +else + ac_cv_lib_resolv_res_9_init=no fi rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext - if test "${ac_cv_search_setsockopt+set}" = set; then : - break + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS fi -done -if test "${ac_cv_search_setsockopt+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_9_init" >&5 +$as_echo "$ac_cv_lib_resolv_res_9_init" >&6; } +if test "x$ac_cv_lib_resolv_res_9_init" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_LIBRESOLV 1 +_ACEOF + + LIBS="-lresolv $LIBS" -else - ac_cv_search_setsockopt=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_setsockopt" >&5 -$as_echo "$ac_cv_search_setsockopt" >&6; } -ac_res=$ac_cv_search_setsockopt -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + + ;; +esac +for ac_header in sys/types.h netinet/in.h arpa/nameser.h netdb.h resolv.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "#ifdef HAVE_SYS_TYPES_H +# include +#endif +#ifdef HAVE_NETINET_IN_H +# include /* inet_ functions / structs */ +#endif +#ifdef HAVE_ARPA_NAMESER_H +# include /* DNS HEADER struct */ +#endif +#ifdef HAVE_NETDB_H +# include +#endif +" +eval as_val=\$$as_ac_Header + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF fi +done + + +for ac_func in res_init __res_init +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +eval as_val=\$$as_ac_var + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + fi +done { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 @@ -17721,7 +18963,7 @@ case "$ac_cv_lib_dns_sd_DNSServiceRegister" in yes) LIBS="-ldns_sd $LIBS" ;; esac -for ac_header in errno.h fcntl.h ieeefp.h math.h +for ac_header in errno.h fcntl.h ieeefp.h kvm.h math.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" @@ -17736,12 +18978,7 @@ done -# HMS: Lame, but fast. -if test -f /etc/redhat-release -then - : -else - for ac_header in md5.h +for ac_header in md5.h do : ac_fn_c_check_header_compile "$LINENO" "md5.h" "ac_cv_header_md5_h" "#if HAVE_SYS_TYPES_H #include @@ -17757,7 +18994,6 @@ done -fi for ac_header in memory.h netdb.h poll.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` @@ -17800,6 +19036,7 @@ done + case "$host" in *-*-aix*) for ac_header in utmpx.h @@ -17845,6 +19082,31 @@ done ;; esac + +# +# On Suns only (so far) getpass() truncates the typed password to 8 +# characters, but getpassphrase() allows up to 257. Most systems' +# getpass() does not truncate, at least not so as to affect ntpq and +# ntpdc password prompts. +# +# So check for getpassphrase(), but only on Sun operating systems. +# + +case "$host" in + *-*-sunos*|*-*-solaris*) + for ac_func in getpassphrase +do : + ac_fn_c_check_func "$LINENO" "getpassphrase" "ac_cv_func_getpassphrase" +if test "x$ac_cv_func_getpassphrase" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_GETPASSPHRASE 1 +_ACEOF + +fi +done + +esac + for ac_header in arpa/nameser.h do : ac_fn_c_check_header_mongrel "$LINENO" "arpa/nameser.h" "ac_cv_header_arpa_nameser_h" "$ac_includes_default" @@ -18169,7 +19431,7 @@ ;; esac -for ac_header in sys/stat.h sys/stream.h +for ac_header in sys/stat.h sys/stream.h sys/stropts.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" @@ -18183,7 +19445,23 @@ done -for ac_header in sys/stropts.h sys/sysctl.h sys/syssgi.h sys/systune.h +# sys/sysctl.h depends on sys/param.h on OpenBSD - Bug 1576 +for ac_header in sys/sysctl.h +do : + ac_fn_c_check_header_compile "$LINENO" "sys/sysctl.h" "ac_cv_header_sys_sysctl_h" "#if defined HAVE_SYS_PARAM_H +# include +#endif +" +if test "x$ac_cv_header_sys_sysctl_h" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SYS_SYSCTL_H 1 +_ACEOF + +fi + +done + +for ac_header in sys/syssgi.h sys/systune.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" @@ -18701,92 +19979,6 @@ ;; esac -# -# following block goes away in 4.2.5 -# -# AM_C_PROTOTYPES gives us ansi2knr -case "$build" in - *-*-solaris2*) - # Assume that solaris2 is Ansi C... - ;; - *) - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for function prototypes" >&5 -$as_echo_n "checking for function prototypes... " >&6; } -if test "$ac_cv_prog_cc_c89" != no; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - -$as_echo "#define PROTOTYPES 1" >>confdefs.h - - -$as_echo "#define __PROTOTYPES 1" >>confdefs.h - -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -if test "$ac_cv_prog_cc_stdc" != no; then - U= ANSI2KNR= -else - U=_ ANSI2KNR=./ansi2knr -fi -# Ensure some checks needed by ansi2knr itself. - -for ac_header in string.h -do : - ac_fn_c_check_header_mongrel "$LINENO" "string.h" "ac_cv_header_string_h" "$ac_includes_default" -if test "x$ac_cv_header_string_h" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_STRING_H 1 -_ACEOF - -fi - -done - - - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if C compiler permits function prototypes" >&5 -$as_echo_n "checking if C compiler permits function prototypes... " >&6; } -if test "${ac_cv_have_prototypes+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -extern int foo (short); -int foo(short i) { return i; } -int -main () -{ - -int i; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_have_prototypes=yes -else - ac_cv_have_prototypes=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_prototypes" >&5 -$as_echo "$ac_cv_have_prototypes" >&6; } -if test "$ac_cv_have_prototypes" = yes; then - -$as_echo "#define HAVE_PROTOTYPES 1" >>confdefs.h - -fi -# -# end block -# - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 $as_echo_n "checking for an ANSI C-conforming const... " >&6; } if test "${ac_cv_c_const+set}" = set; then : @@ -19304,38 +20496,6 @@ fi -# -# Look for in_port_t. -# -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for in_port_t" >&5 -$as_echo_n "checking for in_port_t... " >&6; } -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -#include -#include -int -main () -{ -in_port_t port = 25; return (0); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - -$as_echo "#define ISC_PLATFORM_NEEDPORTT 1" >>confdefs.h - - -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a fallback value for HZ" >&5 $as_echo_n "checking for a fallback value for HZ... " >&6; } if test "${ac_cv_var_default_hz+set}" = set; then : @@ -19378,6 +20538,9 @@ *-*-sunos4*) ac_cv_var_override_hz=yes ;; + *-*-kfreebsd*) + ac_cv_var_override_hz=yes + ;; esac fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_override_hz" >&5 @@ -19423,10 +20586,44 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_rt_msghdr" >&5 $as_echo "$ac_cv_struct_rt_msghdr" >&6; } -if test $ac_cv_struct_rt_msghdr = yes; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct rtattr" >&5 +$as_echo_n "checking for struct rtattr... " >&6; } +if test "${ac_cv_struct_rtattr+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +#include +#include +int +main () +{ +struct rtattr p; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_struct_rtattr=yes +else + ac_cv_struct_rtattr=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_rtattr" >&5 +$as_echo "$ac_cv_struct_rtattr" >&6; } + +if test $ac_cv_struct_rt_msghdr = yes -o $ac_cv_struct_rtattr = yes; then $as_echo "#define HAS_ROUTING_SOCKET 1" >>confdefs.h + if test $ac_cv_struct_rtattr = yes; then + +$as_echo "#define HAVE_RTNETLINK 1" >>confdefs.h + + fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking struct sigaction for sa_sigaction" >&5 @@ -19508,237 +20705,292 @@ fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking struct sockaddr for sa_len" >&5 -$as_echo_n "checking struct sockaddr for sa_len... " >&6; } -if test "${ac_cv_struct_sockaddr_has_sa_len+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct sockaddr_storage" >&5 +$as_echo_n "checking for struct sockaddr_storage... " >&6; } +if test "${ntp_cv_sockaddr_storage+set}" = set; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif + int main () { -extern struct sockaddr *ps; -return ps->sa_len; + struct sockaddr_storage n; + ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_struct_sockaddr_has_sa_len=yes + ntp_cv_sockaddr_storage="yes" else - ac_cv_struct_sockaddr_has_sa_len=no + ntp_cv_sockaddr_storage="no" + fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_sockaddr_has_sa_len" >&5 -$as_echo "$ac_cv_struct_sockaddr_has_sa_len" >&6; } -if test $ac_cv_struct_sockaddr_has_sa_len = yes; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_sockaddr_storage" >&5 +$as_echo "$ntp_cv_sockaddr_storage" >&6; } +case "$ntp_cv_sockaddr_storage" in + yes) -$as_echo "#define HAVE_SA_LEN_IN_STRUCT_SOCKADDR 1" >>confdefs.h +$as_echo "#define HAVE_STRUCT_SOCKADDR_STORAGE 1" >>confdefs.h -fi +esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct sockaddr_storage" >&5 -$as_echo_n "checking for struct sockaddr_storage... " >&6; } -if test "${ac_cv_struct_sockaddr_storage+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_storage.ss_family" >&5 +$as_echo_n "checking for sockaddr_storage.ss_family... " >&6; } +if test "${ntp_cv_have_ss_family+set}" = set; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include -#include + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif int main () { -struct sockaddr_storage n; + struct sockaddr_storage s; + s.ss_family = 1; + ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_struct_sockaddr_storage=yes + ntp_cv_have_ss_family="yes" else - ac_cv_struct_sockaddr_storage=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ntp_cv_have_ss_family="no" fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_sockaddr_storage" >&5 -$as_echo "$ac_cv_struct_sockaddr_storage" >&6; } -if test $ac_cv_struct_sockaddr_storage = yes; then +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -$as_echo "#define HAVE_STRUCT_SOCKADDR_STORAGE 1" >>confdefs.h fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_have_ss_family" >&5 +$as_echo "$ntp_cv_have_ss_family" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ss_family field in struct sockaddr_storage" >&5 -$as_echo_n "checking for ss_family field in struct sockaddr_storage... " >&6; } -if test "${ac_cv_have_ss_family_in_struct_ss+set}" = set; then : +case "$ntp_cv_have_ss_family" in + no) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_storage.__ss_family" >&5 +$as_echo_n "checking for sockaddr_storage.__ss_family... " >&6; } +if test "${ntp_cv_have___ss_family+set}" = set; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif int main () { - struct sockaddr_storage s; s.ss_family = 1; + + struct sockaddr_storage s; + s.__ss_family = 1; + ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_have_ss_family_in_struct_ss="yes" + ntp_cv_have___ss_family="yes" else - ac_cv_have_ss_family_in_struct_ss="no" + ntp_cv_have___ss_family="no" + fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_ss_family_in_struct_ss" >&5 -$as_echo "$ac_cv_have_ss_family_in_struct_ss" >&6; } -if test "x$ac_cv_have_ss_family_in_struct_ss" = "xyes" ; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_have___ss_family" >&5 +$as_echo "$ntp_cv_have___ss_family" >&6; } + case "$ntp_cv_have___ss_family" in + yes) -$as_echo "#define HAVE_SS_FAMILY_IN_SS 1" >>confdefs.h +$as_echo "#define HAVE___SS_FAMILY_IN_SS 1" >>confdefs.h -else - # Hack around a problem... - # HMS: This is $host because we need the -D if we are building *for* it. - # HMS: 061029: Now that we separate the ss_* checks this is causing - # a problem - disable it until we get to the bottom of it. - case "$host" in - XXX*-*-hpux11.11) CPPFLAGS="$CPPFLAGS -D_NETINET_IN6_H" - ;; esac -fi +esac + -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for __ss_family field in struct sockaddr_storage" >&5 -$as_echo_n "checking for __ss_family field in struct sockaddr_storage... " >&6; } -if test "${ac_cv_have___ss_family_in_struct_ss+set}" = set; then : + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_storage.ss_len" >&5 +$as_echo_n "checking for sockaddr_storage.ss_len... " >&6; } +if test "${ntp_cv_have_ss_len+set}" = set; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif int main () { - struct sockaddr_storage s; s.__ss_family = 1; + + struct sockaddr_storage s; + s.ss_len = 1; + ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_have___ss_family_in_struct_ss="yes" + ntp_cv_have_ss_len="yes" else - ac_cv_have___ss_family_in_struct_ss="no" + ntp_cv_have_ss_len="no" fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have___ss_family_in_struct_ss" >&5 -$as_echo "$ac_cv_have___ss_family_in_struct_ss" >&6; } -if test "x$ac_cv_have___ss_family_in_struct_ss" = "xyes" ; then - -$as_echo "#define HAVE___SS_FAMILY_IN_SS 1" >>confdefs.h fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_have_ss_len" >&5 +$as_echo "$ntp_cv_have_ss_len" >&6; } - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ss_len field in struct sockaddr_storage" >&5 -$as_echo_n "checking for ss_len field in struct sockaddr_storage... " >&6; } -if test "${ac_cv_have_ss_len_in_struct_ss+set}" = set; then : +case "$ntp_cv_have_ss_len" in + no) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_storage.__ss_len" >&5 +$as_echo_n "checking for sockaddr_storage.__ss_len... " >&6; } +if test "${ntp_cv_have___ss_len+set}" = set; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif int main () { - struct sockaddr_storage s; s.ss_len = 1; + + struct sockaddr_storage s; + s.__ss_len = 1; + ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_have_ss_len_in_struct_ss="yes" + ntp_cv_have___ss_len="yes" else - ac_cv_have_ss_len_in_struct_ss="no" + ntp_cv_have___ss_len="no" + fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_ss_len_in_struct_ss" >&5 -$as_echo "$ac_cv_have_ss_len_in_struct_ss" >&6; } -if test "x$ac_cv_have_ss_len_in_struct_ss" = "xyes" ; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_have___ss_len" >&5 +$as_echo "$ntp_cv_have___ss_len" >&6; } + case "$ntp_cv_have___ss_len" in + yes) + +$as_echo "#define HAVE___SS_LEN_IN_SS 1" >>confdefs.h -$as_echo "#define HAVE_SS_LEN_IN_SS 1" >>confdefs.h + esac +esac -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for __ss_len field in struct sockaddr_storage" >&5 -$as_echo_n "checking for __ss_len field in struct sockaddr_storage... " >&6; } -if test "${ac_cv_have___ss_len_in_struct_ss+set}" = set; then : + +# +# Look for in_port_t. +# +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for in_port_t" >&5 +$as_echo_n "checking for in_port_t... " >&6; } +if test "${isc_cv_have_in_port_t+set}" = set; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include + #include + #include int main () { - struct sockaddr_storage s; s.__ss_len = 1; + + in_port_t port = 25; + return (0); + ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_have___ss_len_in_struct_ss="yes" + isc_cv_have_in_port_t=yes else - ac_cv_have___ss_len_in_struct_ss="no" + isc_cv_have_in_port_t=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have___ss_len_in_struct_ss" >&5 -$as_echo "$ac_cv_have___ss_len_in_struct_ss" >&6; } -if test "x$ac_cv_have___ss_len_in_struct_ss" = "xyes" ; then - -$as_echo "#define HAVE___SS_LEN_IN_SS 1" >>confdefs.h fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_have_in_port_t" >&5 +$as_echo "$isc_cv_have_in_port_t" >&6; } +case "$isc_cv_have_in_port_t" in + no) +$as_echo "#define ISC_PLATFORM_NEEDPORTT 1" >>confdefs.h +esac case "$ac_cv_header_machine_soundcard_h$ac_cv_header_sys_soundcard_h" in *yes*) @@ -20213,7 +21465,64 @@ # this conditional will need to change. Maybe use AC_TRY_RUN # instead to try to set the time to itself and check errno. ;; - *) for ac_func in clock_gettime clock_settime + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5 +$as_echo_n "checking for library containing clock_gettime... " >&6; } +if test "${ac_cv_search_clock_gettime+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char clock_gettime (); +int +main () +{ +return clock_gettime (); + ; + return 0; +} +_ACEOF +for ac_lib in '' rt; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_clock_gettime=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if test "${ac_cv_search_clock_gettime+set}" = set; then : + break +fi +done +if test "${ac_cv_search_clock_gettime+set}" = set; then : + +else + ac_cv_search_clock_gettime=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5 +$as_echo "$ac_cv_search_clock_gettime" >&6; } +ac_res=$ac_cv_search_clock_gettime +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + + for ac_func in clock_gettime clock_settime do : as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" @@ -20571,6 +21880,62 @@ ;; esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_ntop" >&5 +$as_echo_n "checking for library containing inet_ntop... " >&6; } +if test "${ac_cv_search_inet_ntop+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char inet_ntop (); +int +main () +{ +return inet_ntop (); + ; + return 0; +} +_ACEOF +for ac_lib in '' resolv; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib -lsocket -lnsl $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_inet_ntop=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if test "${ac_cv_search_inet_ntop+set}" = set; then : + break +fi +done +if test "${ac_cv_search_inet_ntop+set}" = set; then : + +else + ac_cv_search_inet_ntop=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_ntop" >&5 +$as_echo "$ac_cv_search_inet_ntop" >&6; } +ac_res=$ac_cv_search_inet_ntop +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + ac_fn_c_check_func "$LINENO" "inet_ntop" "ac_cv_func_inet_ntop" if test "x$ac_cv_func_inet_ntop" = x""yes; then : @@ -20589,16 +21954,22 @@ fi -ac_fn_c_check_func "$LINENO" "inet_aton" "ac_cv_func_inet_aton" -if test "x$ac_cv_func_inet_aton" = x""yes; then : - -else - -$as_echo "#define ISC_PLATFORM_NEEDATON 1" >>confdefs.h +case "$ac_cv_header_kvm_h" in + yes) + for ac_func in kvm_open +do : + ac_fn_c_check_func "$LINENO" "kvm_open" "ac_cv_func_kvm_open" +if test "x$ac_cv_func_kvm_open" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_KVM_OPEN 1 +_ACEOF fi +done -for ac_func in K_open kvm_open memcpy memmove memset + ;; +esac +for ac_func in memcpy memmove memset do : as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" @@ -21069,14 +22440,8 @@ #include "l_stdlib.h" -#ifdef HAVE_PROTOTYPES -#define P(x) x -#else -#define P(x) () -#endif - extern void *base; -extern sortfunc P((const void *, const void *)); +extern sortfunc (const void *, const void *); int sortfunc(a, b) const void *a; const void *b; { return 0; } @@ -21236,16 +22601,11 @@ #ifdef HAVE_UNISTD_H # include #endif -#ifdef HAVE_PROTOTYPES -#define P(x) x -#else -#define P(x) () -#endif int main () { -extern int syscall P((int, ...)); +extern int syscall (int, ...); ; return 0; } @@ -21595,39 +22955,50 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need a ctty for F_SETOWN" >&5 $as_echo_n "checking if we need a ctty for F_SETOWN... " >&6; } -if test "${ac_cv_func_ctty_for_f_setown+set}" = set; then : +if test "${ntp_cv_func_ctty_for_f_setown+set}" = set; then : $as_echo_n "(cached) " >&6 else - case "$host" in - *-*-bsdi[23]*) - ans=yes - ;; - *-*-freebsd*) - ans=yes - ;; - *-*-netbsd*3.[0-8]*|*-*-netbsd*[0-2].*|*-*-netbsd*3.99.[0-7]) - ans=yes - ;; - *-*-openbsd*) - ans=yes - ;; - *-*-osf*) - ans=yes - ;; - *-*-darwin*) - ans=yes - ;; - *) ans=no - ;; -esac -ac_cv_func_ctty_for_f_setown=$ans + + case "$host" in + *-*-bsdi23*) + ans=yes + ;; + *-*-freebsd*) + ans=yes + ;; + # NetBSD versions prior to 3.99.8 require a CTTY for F_SETOWN, + # while later versions will fail a ioctl(TIOCSCTTY, 0) call in + # some cases and so should not have USE_FSETOWNCTTY. "netbsd" + # in $host may be followed by "aout", "ecoff", or "elf". + *-*-netbsd*a-z3.0-8*|*-*-netbsd*a-z0-2.*|*-*-netbsd*a-z3.99.0-7) + ans=yes + ;; + *-*-netbsd3.0-8*|*-*-netbsd0-2.*|*-*-netbsd3.99.0-7) + ans=yes + ;; + *-*-openbsd*) + ans=yes + ;; + *-*-osf*) + ans=yes + ;; + *-*-darwin*) + ans=yes + ;; + *) + ans=no + esac + ntp_cv_func_ctty_for_f_setown=$ans + + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_ctty_for_f_setown" >&5 -$as_echo "$ac_cv_func_ctty_for_f_setown" >&6; } -case "$ac_cv_func_ctty_for_f_setown" in +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_func_ctty_for_f_setown" >&5 +$as_echo "$ntp_cv_func_ctty_for_f_setown" >&6; } +case "$ntp_cv_func_ctty_for_f_setown" in yes) + $as_echo "#define USE_FSETOWNCTTY 1" >>confdefs.h - ;; + esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the OS fails to clear cached routes when more specific routes become available" >&5 @@ -21793,6 +23164,9 @@ *-*-unicosmp*) ans=no ;; + *-*-kfreebsd*) + ans=no + ;; esac ;; esac @@ -21904,6 +23278,9 @@ *-*-unicosmp*) ans=no ;; + *-*-kfreebsd*) + ans=no + ;; *) ans=yes ;; esac @@ -21964,6 +23341,9 @@ *-*-unicosmp*) ans=no ;; + *-*-kfreebsd*) + ans=no + ;; *) ans=yes ;; esac @@ -22091,8 +23471,8 @@ ;; esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we're including debugging code" >&5 -$as_echo_n "checking if we're including debugging code... " >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we're including ntpd debugging code" >&5 +$as_echo_n "checking if we're including ntpd debugging code... " >&6; } # Check whether --enable-debugging was given. if test "${enable_debugging+set}" = set; then : enableval=$enable_debugging; ntp_ok=$enableval @@ -22143,8 +23523,8 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 $as_echo "$ans" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if ntpd will retry on permanent DNS errors" >&5 -$as_echo_n "checking if ntpd will retry on permanent DNS errors... " >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if ntpd will retry permanent DNS failures" >&5 +$as_echo_n "checking if ntpd will retry permanent DNS failures... " >&6; } # Check whether --enable-ignore-dns-errors was given. if test "${enable_ignore_dns_errors+set}" = set; then : enableval=$enable_ignore_dns_errors; ans=$enableval @@ -22162,6 +23542,25 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 $as_echo "$ans" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if ntpd will use the deferred DNS lookup path" >&5 +$as_echo_n "checking if ntpd will use the deferred DNS lookup path... " >&6; } +# Check whether --enable-force-defer-DNS was given. +if test "${enable_force_defer_DNS+set}" = set; then : + enableval=$enable_force_defer_DNS; ans=$enableval +else + ans=no + +fi + +case "$ans" in + yes) + +$as_echo "#define FORCE_DEFER_DNS 1" >>confdefs.h + +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have the tty_clk line discipline/streams module" >&5 $as_echo_n "checking if we have the tty_clk line discipline/streams module... " >&6; } if test "${ac_cv_var_tty_clk+set}" = set; then : @@ -22195,61 +23594,78 @@ ;; esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for kernel multicast support" >&5 -$as_echo_n "checking for kernel multicast support... " >&6; } -if test "${ac_cv_var_mcast+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for multicast IP support" >&5 +$as_echo_n "checking for multicast IP support... " >&6; } +if test "${ntp_cv_multicast+set}" = set; then : $as_echo_n "(cached) " >&6 else - ac_cv_var_mcast=no - case "$host" in - i386-sequent-sysv4) ;; - *) cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + ntp_cv_multicast=no + case "$host" in + i386-sequent-sysv4) + ;; + *) + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#ifdef IP_ADD_MEMBERSHIP - yes -#endif + #ifdef HAVE_NETINET_IN_H + #include + #endif + +int +main () +{ + + struct ip_mreq ipmr; + ipmr.imr_interface.s_addr = 0; + + + ; + return 0; +} _ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then : - ac_cv_var_mcast=yes +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_multicast=yes fi -rm -f conftest* - ;; - esac +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + esac + + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_mcast" >&5 -$as_echo "$ac_cv_var_mcast" >&6; } -case "$ac_cv_var_mcast" in +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_multicast" >&5 +$as_echo "$ntp_cv_multicast" >&6; } + +case "$ntp_cv_multicast" in yes) $as_echo "#define MCAST 1" >>confdefs.h - { $as_echo "$as_me:${as_lineno-$LINENO}: checking arg type needed for IP*_MULTICAST_LOOP for setsockopt()" >&5 -$as_echo_n "checking arg type needed for IP*_MULTICAST_LOOP for setsockopt()... " >&6; } -if test "${ac_cv_var_typeof_ip_multicast_loop+set}" = set; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking arg type needed for setsockopt() IP*_MULTICAST_LOOP" >&5 +$as_echo_n "checking arg type needed for setsockopt() IP*_MULTICAST_LOOP... " >&6; } +if test "${ntp_cv_typeof_ip_multicast_loop+set}" = set; then : $as_echo_n "(cached) " >&6 else - case "$host" in - *-*-netbsd*|*-*-*linux*) - ac_cv_var_typeof_ip_multicast_loop=u_int - ;; - *-*-winnt*) - ac_cv_var_typeof_ip_multicast_loop=BOOL - ;; - *) ac_cv_var_typeof_ip_multicast_loop=u_char - ;; - esac + + case "$host" in + *-*-netbsd*|*-*-*linux*) + ntp_cv_typeof_ip_multicast_loop=u_int + ;; + *-*-winnt*) + ntp_cv_typeof_ip_multicast_loop=BOOL + ;; + *) + ntp_cv_typeof_ip_multicast_loop=u_char + esac + + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_typeof_ip_multicast_loop" >&5 -$as_echo "$ac_cv_var_typeof_ip_multicast_loop" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_typeof_ip_multicast_loop" >&5 +$as_echo "$ntp_cv_typeof_ip_multicast_loop" >&6; } cat >>confdefs.h <<_ACEOF -#define TYPEOF_IP_MULTICAST_LOOP $ac_cv_var_typeof_ip_multicast_loop +#define TYPEOF_IP_MULTICAST_LOOP $ntp_cv_typeof_ip_multicast_loop _ACEOF - ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking availability of ntp_{adj,get}time()" >&5 @@ -23807,16 +25223,12 @@ MAKE_LIBPARSE=libparse.a # HMS: check_y2k trips the 34 year problem now... false && MAKE_CHECK_Y2K=check_y2k - -$as_echo "#define PPS_SAMPLE 1" >>confdefs.h - - $as_echo "#define CLOCK_ATOM 1" >>confdefs.h - ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 $as_echo "$ans" >&6; } + # AC_SUBST(RSAOBJS) # AC_SUBST(RSASRCS) # AC_SUBST(RSADIR) @@ -23828,6 +25240,8 @@ + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openssl library directory" >&5 $as_echo_n "checking for openssl library directory... " >&6; } @@ -23844,7 +25258,7 @@ case "$ans" in no) ;; yes) # Look in: - ans="/usr/lib /usr/lib/openssl /usr/sfw/lib /usr/local/lib /usr/local/ssl/lib" + ans="/usr/lib /usr/lib/openssl /usr/sfw/lib /usr/local/lib /usr/local/ssl/lib /lib" ;; *) # Look where they said ;; @@ -23920,6 +25334,8 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 $as_echo "$ans" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we will use crypto" >&5 +$as_echo_n "checking if we will use crypto... " >&6; } # Check whether --with-crypto was given. if test "${with_crypto+set}" = set; then : @@ -23929,45 +25345,115 @@ fi case "$ans" in - no) ;; + no) + ;; yes|openssl) if test -z "$OPENSSL_LIB" -o -z "$OPENSSL_INC" then ans=no else - # We have OpenSSL inc/lib - use them. - ans=openssl - CPPFLAGS="$CPPFLAGS -I$OPENSSL_INC" - LDFLAGS="$LDFLAGS -L$OPENSSL_LIB" - case "$need_dash_r" in - 1) LDFLAGS="$LDFLAGS -R$OPENSSL_LIB" - ;; - esac - LCRYPTO=-lcrypto + ans=yes + fi +esac +ntp_openssl=$ans +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } + +case "$ntp_openssl" in + yes) + # We have OpenSSL inc/lib - use them. + CPPFLAGS="$CPPFLAGS -I$OPENSSL_INC" + LDFLAGS="$LDFLAGS -L$OPENSSL_LIB" + case "$need_dash_r" in + 1) LDFLAGS="$LDFLAGS -R$OPENSSL_LIB" + esac + LCRYPTO=-lcrypto $as_echo "#define OPENSSL /**/" >>confdefs.h - for ac_func in EVP_md2 EVP_mdc2 -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +esac + +# +# Older OpenSSL headers have a number of callback prototypes inside +# other function prototypes which trigger copious warnings with gcc's +# -Wstrict-prototypes, which is included in -Wall. +# +# An example: +# +# int i2d_RSA_NET(const RSA *a, unsigned char **pp, +# int (*cb)(), int sgckey); +# ^^^^^^^^^^^ +# +# +# +openssl_triggers_warnings=unknown +SAVED_CFLAGS="$CFLAGS" + +case "$GCC$ntp_openssl" in + yesyes) + CFLAGS="$CFLAGS -Werror" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + /* see if -Werror breaks gcc */ _ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + gcc_handles_Werror=yes +else + gcc_handles_Werror=no fi -done +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + case "$gcc_handles_Werror" in + no) + # if this gcc doesn't do -Werror go ahead and use + # -Wstrict-prototypes. + openssl_triggers_warnings=yes + ;; + yes) + CFLAGS="$CFLAGS -Wstrict-prototypes" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - fi + #include "openssl/asn1_mac.h" + #include "openssl/bn.h" + #include "openssl/err.h" + #include "openssl/evp.h" + #include "openssl/pem.h" + #include "openssl/rand.h" + #include "openssl/x509v3.h" + +int +main () +{ + /* empty body */ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + openssl_triggers_warnings=no +else + openssl_triggers_warnings=yes + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + esac + case "$openssl_triggers_warnings" in + yes) + CFLAGS="$SAVED_CFLAGS -Wno-strict-prototypes" + ;; + *) + CFLAGS="$SAVED_CFLAGS -Wstrict-prototypes" + esac ;; + yesno) + # gcc without OpenSSL + CFLAGS="$SAVED_CFLAGS -Wstrict-prototypes" esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for the level of crypto support" >&5 -$as_echo_n "checking for the level of crypto support... " >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to compile with ElectricFence" >&5 $as_echo_n "checking if we want to compile with ElectricFence... " >&6; } @@ -24047,6 +25533,18 @@ sparc-*-solaris2*) ans=parsesolaris MAKE_PARSEKMODULE=parse + for ac_header in strings.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "strings.h" "ac_cv_header_strings_h" "$ac_includes_default" +if test "x$ac_cv_header_strings_h" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_STRINGS_H 1 +_ACEOF + +fi + +done + ;; esac ;; @@ -24713,7 +26211,7 @@ # be better to simply remove the hunk above, I did not want # to remove it if there is hope it will be used again. # -unset ac_cv_make_tickadj +$as_unset ac_cv_make_tickadj { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want and can make the tickadj utility" >&5 $as_echo_n "checking if we want and can make the tickadj utility... " >&6; } @@ -24793,6 +26291,128 @@ esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to build ntpsnmpd" >&5 +$as_echo_n "checking if we want to build ntpsnmpd... " >&6; } + +# Check whether --with-ntpsnmpd was given. +if test "${with_ntpsnmpd+set}" = set; then : + withval=$with_ntpsnmpd; ans=$withval +else + case "$PATH_NET_SNMP_CONFIG" in + /*) ans=yes ;; + *) ans=no ;; + esac +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } + +case "$ans" in + yes) + case "$PATH_NET_SNMP_CONFIG" in + /*) + SNMP_LIBS=`$PATH_NET_SNMP_CONFIG --agent-libs` + + # HMS: we really want to separate CPPFLAGS and CFLAGS + foo=`$PATH_NET_SNMP_CONFIG --cflags` + SNMP_CPPFLAGS= + SNMP_CFLAGS= + for i in $foo; do + case "$i" in + -D*|-U*|-I*) + SNMP_CPPFLAGS="$SNMP_CPPFLAGS $i" + ;; + *) SNMP_CFLAGS="$SNMP_CFLAGS $i" + ;; + esac + done + + + + save_CFLAGS=$CFLAGS + save_CPPFLAGS=$CPPFLAGS + save_LIBS=$LIBS + CFLAGS=$SNMP_CFLAGS + CPPFLAGS=$SNMP_CPPFLAGS + + ac_fn_c_check_header_mongrel "$LINENO" "net-snmp/net-snmp-config.h" "ac_cv_header_net_snmp_net_snmp_config_h" "$ac_includes_default" +if test "x$ac_cv_header_net_snmp_net_snmp_config_h" = x""yes; then : + MAKE_NTPSNMPD=ntpsnmpd +else + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: net-snmp-config present but net-snmp headers are not available!" >&5 +$as_echo "$as_me: WARNING: net-snmp-config present but net-snmp headers are not available!" >&2;} +fi + + + + # Do this last, as we're messing up LIBS. + + # check -lnetsnmp for netsnmp_daemonize + LIBS=`$PATH_NET_SNMP_CONFIG --libs` + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for netsnmp_daemonize in -lnetsnmp" >&5 +$as_echo_n "checking for netsnmp_daemonize in -lnetsnmp... " >&6; } +if test "${ac_cv_lib_netsnmp_netsnmp_daemonize+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lnetsnmp $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char netsnmp_daemonize (); +int +main () +{ +return netsnmp_daemonize (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_netsnmp_netsnmp_daemonize=yes +else + ac_cv_lib_netsnmp_netsnmp_daemonize=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_netsnmp_netsnmp_daemonize" >&5 +$as_echo "$ac_cv_lib_netsnmp_netsnmp_daemonize" >&6; } +if test "x$ac_cv_lib_netsnmp_netsnmp_daemonize" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_LIBNETSNMP 1 +_ACEOF + + LIBS="-lnetsnmp $LIBS" + +else + +$as_echo "#define NEED_NETSNMP_DAEMONIZE 1" >>confdefs.h + +fi + + + CFLAGS=$save_CFLAGS + CPPFLAGS=$save_CPPFLAGS + LIBS=$save_LIBS + + ;; + *) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Cannot build ntpsnmpd as desired - net-snmp-config cannot be found" >&5 +$as_echo "$as_me: WARNING: Cannot build ntpsnmpd as desired - net-snmp-config cannot be found" >&2;} + ;; + esac + ;; +esac + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should always slew the time" >&5 $as_echo_n "checking if we should always slew the time... " >&6; } @@ -24999,6 +26619,29 @@ esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want new session key behavior" >&5 +$as_echo_n "checking if we want new session key behavior... " >&6; } + +# Check whether --enable-bug1243-fix was given. +if test "${enable_bug1243_fix+set}" = set; then : + enableval=$enable_bug1243_fix; ans=$enableval +else + ans=yes + +fi + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } + +case "$ans" in + no) + +$as_echo "#define DISABLE_BUG1243_FIX 1" >>confdefs.h + +esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should use the IRIG sawtooth filter" >&5 $as_echo_n "checking if we should use the IRIG sawtooth filter... " >&6; } @@ -25079,10 +26722,8 @@ case "$ntp_signd_path" in '') - wintime_default=no ;; *) - wintime_default=yes $as_echo "#define HAVE_NTP_SIGND /**/" >>confdefs.h @@ -25094,30 +26735,6 @@ esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want the windows symmetric client hack" >&5 -$as_echo_n "checking if we want the windows symmetric client hack... " >&6; } - -# default is no, unless --enable-ntp-signd was given -ans=$wintime_default -unset wintime_default - -# Check whether --enable-wintime was given. -if test "${enable_wintime+set}" = set; then : - enableval=$enable_wintime; ans=$enableval -fi - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } - -case "$ans" in - yes) - -$as_echo "#define WINTIME /**/" >>confdefs.h - -esac - - for ac_header in sys/clockctl.h do : ac_fn_c_check_header_mongrel "$LINENO" "sys/clockctl.h" "ac_cv_header_sys_clockctl_h" "$ac_includes_default" @@ -25184,16 +26801,18 @@ case "$ac_cv_header_sys_capability_h$ac_cv_header_sys_prctl_h" in yesyes) - ntp_have_linuxcaps=yes + case "$host" in + mips-sgi-irix*) + ntp_have_linuxcaps=no + ;; + *) ntp_have_linuxcaps=yes + ;; + esac ;; *) ntp_have_linuxcaps=no esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_have_linuxcaps" >&5 -$as_echo "$ntp_have_linuxcaps" >&6; } - - # Check whether --enable-linuxcaps was given. if test "${enable_linuxcaps+set}" = set; then : enableval=$enable_linuxcaps; ntp_have_linuxcaps=$enableval @@ -25201,6 +26820,8 @@ fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_have_linuxcaps" >&5 +$as_echo "$ntp_have_linuxcaps" >&6; } case "$ntp_have_linuxcaps" in yes) @@ -25210,7 +26831,6 @@ LIBS="$LIBS -lcap" esac - case "$ntp_use_dev_clockctl$ntp_have_linuxcaps" in *yes*) @@ -25252,7 +26872,42 @@ # ISC stuff # -if test $ac_cv_struct_sockaddr_has_sa_len = yes; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking struct sockaddr for sa_len" >&5 +$as_echo_n "checking struct sockaddr for sa_len... " >&6; } +if test "${isc_cv_platform_havesalen+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + #include + +int +main () +{ + + extern struct sockaddr *ps; + return ps->sa_len; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + isc_cv_platform_havesalen=yes +else + isc_cv_platform_havesalen=no + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_platform_havesalen" >&5 +$as_echo "$isc_cv_platform_havesalen" >&6; } +if test $isc_cv_platform_havesalen = yes; then $as_echo "#define ISC_PLATFORM_HAVESALEN /**/" >>confdefs.h @@ -25334,6 +26989,7 @@ fi + case "$use_kame" in no) ;; @@ -25511,7 +27167,7 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for in6addr_any" >&5 $as_echo_n "checking for in6addr_any... " >&6; } -if test "${ac_cv_have_in6addr_any+set}" = set; then : +if test "${isc_cv_have_in6addr_any+set}" = set; then : $as_echo_n "(cached) " >&6 else @@ -25538,20 +27194,21 @@ } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_have_in6addr_any=yes +if ac_fn_c_try_link "$LINENO"; then : + isc_cv_have_in6addr_any=yes else - ac_cv_have_in6addr_any=no + isc_cv_have_in6addr_any=no fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_in6addr_any" >&5 -$as_echo "$ac_cv_have_in6addr_any" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_have_in6addr_any" >&5 +$as_echo "$isc_cv_have_in6addr_any" >&6; } -case "$ac_cv_have_in6addr_any" in +case "$isc_cv_have_in6addr_any" in no) $as_echo "#define ISC_PLATFORM_NEEDIN6ADDRANY /**/" >>confdefs.h @@ -25689,6 +27346,34 @@ esac +### + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want the saveconfig mechanism" >&5 +$as_echo_n "checking if we want the saveconfig mechanism... " >&6; } +# Check whether --enable-saveconfig was given. +if test "${enable_saveconfig+set}" = set; then : + enableval=$enable_saveconfig; ntp_ok=$enableval +else + ntp_ok=yes +fi + +ntp_saveconfig_enabled=0 +if test "$ntp_ok" = "yes"; then + ntp_saveconfig_enabled=1 + +$as_echo "#define SAVECONFIG 1" >>confdefs.h + +fi + if test x$ntp_saveconfig_enabled = x1; then + SAVECONFIG_ENABLED_TRUE= + SAVECONFIG_ENABLED_FALSE='#' +else + SAVECONFIG_ENABLED_TRUE='#' + SAVECONFIG_ENABLED_FALSE= +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } ### @@ -25735,6 +27420,8 @@ ac_config_files="$ac_config_files ntpq/Makefile" +ac_config_files="$ac_config_files ntpsnmpd/Makefile" + ac_config_files="$ac_config_files parseutil/Makefile" ac_config_files="$ac_config_files scripts/Makefile" @@ -25764,6 +27451,8 @@ ac_config_files="$ac_config_files util/Makefile" + + subdirs="$subdirs sntp" @@ -25884,6 +27573,10 @@ as_fn_error "conditional \"am__fastdepCC\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi +if test -z "${VPATH_HACK_TRUE}" && test -z "${VPATH_HACK_FALSE}"; then + as_fn_error "conditional \"VPATH_HACK\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi if test -z "${INSTALL_LIBOPTS_TRUE}" && test -z "${INSTALL_LIBOPTS_FALSE}"; then as_fn_error "conditional \"INSTALL_LIBOPTS\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 @@ -25892,7 +27585,19 @@ as_fn_error "conditional \"NEED_LIBOPTS\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi +if test -z "${NTP_CROSSCOMPILE_TRUE}" && test -z "${NTP_CROSSCOMPILE_FALSE}"; then + as_fn_error "conditional \"NTP_CROSSCOMPILE\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${NTP_BINSUBDIR_IS_BIN_TRUE}" && test -z "${NTP_BINSUBDIR_IS_BIN_FALSE}"; then + as_fn_error "conditional \"NTP_BINSUBDIR_IS_BIN\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${SAVECONFIG_ENABLED_TRUE}" && test -z "${SAVECONFIG_ENABLED_FALSE}"; then + as_fn_error "conditional \"SAVECONFIG_ENABLED\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi : ${CONFIG_STATUS=./config.status} ac_write_fail=0 @@ -26301,7 +28006,7 @@ # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by ntp $as_me 4.2.4p8, which was +This file was extended by ntp $as_me 4.2.6p2, which was generated by GNU Autoconf 2.65. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -26367,7 +28072,7 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ -ntp config.status 4.2.4p8 +ntp config.status 4.2.6p2 configured by $0, generated by GNU Autoconf 2.65, with options \\"\$ac_cs_config\\" @@ -26508,6 +28213,7 @@ "ntpdc/Makefile") CONFIG_FILES="$CONFIG_FILES ntpdc/Makefile" ;; "ntpdc/nl.pl") CONFIG_FILES="$CONFIG_FILES ntpdc/nl.pl" ;; "ntpq/Makefile") CONFIG_FILES="$CONFIG_FILES ntpq/Makefile" ;; + "ntpsnmpd/Makefile") CONFIG_FILES="$CONFIG_FILES ntpsnmpd/Makefile" ;; "parseutil/Makefile") CONFIG_FILES="$CONFIG_FILES parseutil/Makefile" ;; "scripts/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/Makefile" ;; "scripts/calc_tickadj") CONFIG_FILES="$CONFIG_FILES scripts/calc_tickadj" ;; diff -urN src/contrib/ntp/configure.ac src.ntp/contrib/ntp/configure.ac --- src/contrib/ntp/configure.ac 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/configure.ac 2010-06-19 08:40:31.000000000 +0200 @@ -1,15 +1,46 @@ dnl -*-fundamental-*- dnl Process this file with autoconf to produce a configure script. m4_include([version.m4]) -AC_INIT(ntp, VERSION_NUMBER) +AC_PREREQ(2.61) +AC_INIT([ntp], [VERSION_NUMBER]) +AC_CONFIG_MACRO_DIR([m4]) +AC_CONFIG_AUX_DIR([.]) + +# Increment ntp_configure_cache_version by one for each change to +# configure.ac or .m4 files which invalidates cached values from +# previous versions. +# +# If the change affects cache variables used only by the main NTP +# configure.ac, then only its version number should be bumped, while +# the subdir configure.ac version numbers should be unchanged. The +# same is true for a test/variable that is used only by one subdir +# being changed incompatibly; only that subdir's cache version needs +# bumping. +# +# If a change affects variables shared by all NTP configure scripts, +# please bump the version numbers of all three. If you are not sure, +# the safe choice is to bump all three on any cache-invalidating change. +# +# In order to avoid the risk of version stamp collision between -stable +# and -dev branches, do not simply increment the version, instead use +# the date YYYYMMDD optionally with -HHMM if there is more than one +# bump in a day. + +ntp_configure_cache_version=20091117 + +# When the cache version of config.cache and configure do not +# match, NTP_CACHEVERSION will flush the cache. + +NTP_CACHEVERSION([main], [$ntp_configure_cache_version]) + AM_INIT_AUTOMAKE +AC_CANONICAL_BUILD AC_CANONICAL_HOST dnl the 'build' machine is where we run configure and compile dnl the 'host' machine is where the resulting stuff runs. AC_DEFINE_UNQUOTED(STR_SYSTEM, "$host", [canonical system (cpu-vendor-os) of where we should run]) AM_CONFIG_HEADER([config.h]) dnl AC_ARG_PROGRAM -AC_PREREQ(2.53) ac_cv_var_atom_ok=no ac_cv_var_oncore_ok=no @@ -33,22 +64,25 @@ # Ralf Wildenhues: With per-target flags we need CC_C_O # AM_PROG_CC_C_O supersets AC_PROG_CC_C_O AM_PROG_CC_C_O -AC_PROG_CC_STDC AC_PROG_CPP +AC_PROG_YACC + +# AC_PROG_CC_STDC has two functions. It attempts to find a compiler +# capable of C99, or failing that, for C89. CC is set afterward with +# the selected invocation, such as "gcc --std=gnu99". Also, the +# ac_cv_prog_cc_stdc variable is no if the compiler selected for CC +# does not accept C89. + +AC_PROG_CC_STDC + +case "$ac_cv_prog_cc_stdc" in + no) + AC_MSG_WARN([ANSI C89/ISO C90 is the minimum to compile NTP ] + [version 4.2.5 and higher.]) +esac # HMS: These need to be moved to AM_CPPFLAGS and/or AM_CFLAGS case "$host" in - *-*-amigaos) - CFLAGS="$CFLAGS -Dfork=vfork -DSYS_AMIGA" - ;; - *-*-hpux10.*) # at least for hppa2.0-hp-hpux10.20 - case "$GCC" in - yes) - ;; - *) CFLAGS="$CFLAGS -Wp,-H18816" - ;; - esac - ;; *-pc-cygwin*) CFLAGS="$CFLAGS -DSYS_CYGWIN32" ;; @@ -74,7 +108,9 @@ ;; esac -AMU_OS_CFLAGS +NTP_OS_CFLAGS +NTP_DIR_SEP +NTP_VPATH_HACK # NTP has (so far) been relying on leading-edge autogen. # Therefore, by default: @@ -91,6 +127,8 @@ esac LIBOPTS_CHECK(libopts) +AC_FUNC_FORK + AC_CACHE_CHECK( [if $CC can handle @%:@warning], ac_cv_cpp_warning, @@ -124,7 +162,7 @@ ] ) CFLAGS="$SAVED_CFLAGS_AC" - unset SAVED_CFLAGS_AC + $as_unset SAVED_CFLAGS_AC # # $ac_cv_gcc_Wstrict_overflow is tested later to add the # flag to CFLAGS. @@ -148,14 +186,15 @@ ] ) CFLAGS="$SAVED_CFLAGS_AC" - unset SAVED_CFLAGS_AC + $as_unset SAVED_CFLAGS_AC # # $ac_cv_gcc_Winit_self is tested later to add the # flag to CFLAGS. # esac - +# Expose a cross-compilation indicator to makefiles +AM_CONDITIONAL(NTP_CROSSCOMPILE, test $build != $host) AC_MSG_CHECKING([for bin subdirectory]) AC_ARG_WITH(binsubdir, @@ -172,25 +211,21 @@ ;; esac AC_MSG_RESULT($use_binsubdir) + BINSUBDIR=$use_binsubdir AC_SUBST(BINSUBDIR) +AM_CONDITIONAL(NTP_BINSUBDIR_IS_BIN, test "bin" = "$BINSUBDIR") -AC_MSG_CHECKING([if we want to use arlib]) -AC_ARG_WITH(arlib, - AC_HELP_STRING([--with-arlib], [- Compile the async resolver library?]), +AC_MSG_CHECKING([for deprecated --with-arlib]) +AC_ARG_WITH([arlib], + AC_HELP_STRING([--with-arlib], [- deprecated, arlib not distributed]), [ans=$withval], [ans=no]) AC_MSG_RESULT([$ans]) -if test -d $srcdir/arlib -then - case "$ans" in - yes) - ARLIB_DIR=arlib - AC_CONFIG_SUBDIRS(arlib) - ;; - esac -fi -AC_SUBST(ARLIB_DIR) +case "$ans" in + yes) + AC_MSG_WARN([Please do not use --with-arlib, arlib is no longer included. In the future, --with-arlib will not be recognized.]) +esac AC_ARG_WITH(rpath, AC_HELP_STRING([--without-rpath], [s Disable auto-added -R linker paths]), @@ -224,23 +259,6 @@ ;; esac - -case "$build" in - $host) - ;; - *) case "$host" in - *-*-vxworks*) - # Quick and dirty sanity check - case "$VX_KERNEL" in - '') AC_MSG_ERROR(Please follow the directions in html/build/hints/vxworks.html!) - ;; - esac - CFLAGS="$CFLAGS -DSYS_VXWORKS" - ;; - esac - ;; -esac - dnl we need to check for cross compile tools for vxWorks here AC_PROG_AWK AC_PROG_MAKE_SET @@ -259,16 +277,6 @@ CFLAGS="$CFLAGS -Wmissing-prototypes" CFLAGS="$CFLAGS -Wpointer-arith" CFLAGS="$CFLAGS -Wshadow" - # - # OpenSSL has a number of callback prototypes - # inside other function prototypes which trigger - # warnings with -Wstrict-prototypes, such as: - # - # int i2d_RSA_NET(const RSA *a, unsigned char **pp, - # int (*cb)(), int sgckey); - # ^^^^^^^^^^^ - # - CFLAGS="$CFLAGS -Wno-strict-prototypes" # CFLAGS="$CFLAGS -Wtraditional" # CFLAGS="$CFLAGS -Wwrite-strings" case "$ac_cv_gcc_Winit_self" in @@ -277,28 +285,9 @@ esac case "$ac_cv_gcc_Wstrict_overflow" in yes) - #not yet: CFLAGS="$CFLAGS -Wstrict-overflow" + CFLAGS="$CFLAGS -Wstrict-overflow" esac - ;; -esac - -case "$host" in - *-next-nextstep3) - CFLAGS="$CFLAGS -posix" - ;; -dnl This is currently commented out by bor. -dnl The new versions of ReliantUNIX round adjtime() interval down -dnl to 1/100s (system tick). This makes tickadj actually useless. -dnl So, I'd better not use additional flags. -dnl I leave it here just in case anybody has better idea -dnl mips-sni-sysv4* ) -dnl # -dnl # Add flags for 64 bit file access to enable tickadj to access /dev/kmem -dnl # -dnl if getconf _LFS_CFLAGS > /dev/null 2>&1 ; then -dnl CFLAGS="$CFLAGS `getconf _LFS_CFLAGS`" -dnl fi -dnl ;; + # -W[no-]strict-prototypes is added later depending on OpenSSL esac ac_busted_vpath_in_make=no @@ -345,7 +334,32 @@ AC_PATH_PROG(PATH_SH, sh) AC_PATH_PROG(PATH_PERL, perl) -hs_ULONG_CONST # remove for 4.2.5 +AC_ARG_WITH(net-snmp-config, + AC_HELP_STRING([--with-net-snmp-config], [+ =net-snmp-config]), +[ans=$withval], [ans=yes]) +case "$ans" in + no) ;; + yes) + ans=net-snmp-config + ;; + /*) ;; + */*) + AC_MSG_ERROR([--with-net-snmp-config takes either a name or an absolute path]) + ;; + *) + ;; +esac +PROG_NET_SNMP_CONFIG=$ans +AC_MSG_CHECKING([for net-snmp-config path]) +case "$PROG_NET_SNMP_CONFIG" in + no) ;; + /*) + PATH_NET_SNMP_CONFIG=$PROG_NET_SNMP_CONFIG + ;; + *) AC_PATH_PROG([PATH_NET_SNMP_CONFIG], [$PROG_NET_SNMP_CONFIG]) + ;; +esac +AC_MSG_RESULT([$PATH_NET_SNMP_CONFIG]) case "$host" in *-*-vxworks*) @@ -369,50 +383,36 @@ AC_SEARCH_LIBS([MD5Init], [md5 md]) AC_CHECK_FUNCS(MD5Init) -# following block becomes on 4.2.5: NTP_LINEEDITLIBS -dnl HMS: What a hack... -AC_CHECK_HEADERS(readline/history.h readline/readline.h) -case "$ac_cv_header_readline_history_h$ac_cv_header_readline_readline_h" in - *no*) ;; - *) save_LIBS=$LIBS - LIBS= - # Ralf Wildenhues: either unset ... or cache READLINE_LIBS - unset ac_cv_lib_readline_readline - AC_CHECK_LIB(readline, readline, , - AC_MSG_NOTICE([Trying again with -lcurses]) - unset ac_cv_lib_readline_readline - AC_CHECK_LIB(readline, readline, - LIBS="-lreadline -lcurses $LIBS" - AC_DEFINE(HAVE_LIBREADLINE) - AC_DEFINE(HAVE_LIBCURSES, , [Do we have the curses library?]), - AC_CHECK_LIB(edit, readline, - LIBS="-ledit -lcurses" - AC_DEFINE(HAVE_LIBEDIT, , [Do we have the edit library?]) - AC_DEFINE(HAVE_LIBCURSES, , [Do we have the curses library?]) - , , -lcurses) - , -lcurses)) - READLINE_LIBS=$LIBS - AC_SUBST(READLINE_LIBS) - LIBS=$save_LIBS - ;; -esac +NTP_LINEEDITLIBS dnl Digital UNIX V4.0 and Solaris 7 have POSIX.1c functions in -lrt dnl Solaris 2.6 only has -lposix4; in Solaris 7, this is a symlink to -lrt, dnl so only use one of them. Linux (glibc-2.1.2 and -2.2.2, at least) dnl does Strange Things with extra processes using the Posix-compatibility dnl real-time library, so we don't want to use it. +dnl +dnl 081118 Harlan got tired of looking for a way to get the sched*() +dnl functions to link OK with either cc or gcc. case "$host" in *-*-*linux*) ;; + *-*-osf4*) ;; + *-*-osf5*) ;; *) AC_CHECK_LIB(rt, sched_setscheduler, , AC_CHECK_LIB(posix4, sched_setscheduler)) ;; esac -AC_CHECK_FUNC(setsockopt, , - [AC_SEARCH_LIBS([setsockopt], [socket xnet])]) +AC_SEARCH_LIBS([setsockopt], [socket xnet]) +AC_SEARCH_LIBS([res_init], [resolv], , , [-lsocket -lnsl]) +case "$host" in + *-*-darwin*) + AC_CHECK_LIB([resolv],[res_9_init]) + ;; +esac +AC_HEADER_RESOLV +AC_CHECK_FUNCS(res_init __res_init) AC_HEADER_STDC AC_CHECK_HEADERS(bstring.h) @@ -424,22 +424,17 @@ case "$ac_cv_lib_dns_sd_DNSServiceRegister" in yes) LIBS="-ldns_sd $LIBS" ;; esac -AC_CHECK_HEADERS(errno.h fcntl.h ieeefp.h math.h) +AC_CHECK_HEADERS(errno.h fcntl.h ieeefp.h kvm.h math.h) -# HMS: Lame, but fast. -if test -f /etc/redhat-release -then - : -else - AC_CHECK_HEADERS(md5.h, [], [], +AC_CHECK_HEADERS(md5.h, [], [], [#if HAVE_SYS_TYPES_H #include #endif ]) -fi AC_CHECK_HEADERS(memory.h netdb.h poll.h) AC_CHECK_HEADERS(sched.h sgtty.h stdlib.h string.h termio.h) AC_CHECK_HEADERS(termios.h timepps.h timex.h unistd.h) + case "$host" in *-*-aix*) AC_CHECK_HEADERS(utmpx.h) @@ -450,6 +445,21 @@ ;; *) AC_CHECK_HEADERS(utmp.h utmpx.h) ;; esac + +# +# On Suns only (so far) getpass() truncates the typed password to 8 +# characters, but getpassphrase() allows up to 257. Most systems' +# getpass() does not truncate, at least not so as to affect ntpq and +# ntpdc password prompts. +# +# So check for getpassphrase(), but only on Sun operating systems. +# + +case "$host" in + *-*-sunos*|*-*-solaris*) + AC_CHECK_FUNCS(getpassphrase) +esac + AC_CHECK_HEADERS(arpa/nameser.h) AC_CHECK_HEADERS(sys/socket.h) AC_CHECK_HEADERS(net/if.h, [], [], @@ -537,8 +547,13 @@ *) AC_CHECK_HEADERS(machine/soundcard.h sys/soundcard.h) ;; esac -AC_CHECK_HEADERS(sys/stat.h sys/stream.h) -AC_CHECK_HEADERS(sys/stropts.h sys/sysctl.h sys/syssgi.h sys/systune.h) +AC_CHECK_HEADERS(sys/stat.h sys/stream.h sys/stropts.h) +# sys/sysctl.h depends on sys/param.h on OpenBSD - Bug 1576 +AC_CHECK_HEADERS(sys/sysctl.h, [], [], +[#if defined HAVE_SYS_PARAM_H +# include +#endif]) +AC_CHECK_HEADERS(sys/syssgi.h sys/systune.h) AC_CHECK_HEADERS(sys/termios.h sys/time.h sys/signal.h) AC_EGREP_CPP(yes, [#if HAVE_SYS_TIME_H @@ -661,31 +676,6 @@ ;; esac -# -# following block goes away in 4.2.5 -# -# AM_C_PROTOTYPES gives us ansi2knr -case "$build" in - *-*-solaris2*) - # Assume that solaris2 is Ansi C... - ;; - *) - AM_C_PROTOTYPES - ;; -esac -AC_CACHE_CHECK(if C compiler permits function prototypes, ac_cv_have_prototypes, -[AC_TRY_COMPILE([ -extern int foo (short); -int foo(short i) { return i; }],[ -int i;], ac_cv_have_prototypes=yes, ac_cv_have_prototypes=no) -]) -if test "$ac_cv_have_prototypes" = yes; then - AC_DEFINE(HAVE_PROTOTYPES, 1, [Are function prototypes OK?]) -fi -# -# end block -# - AC_C_CONST AC_C_BIGENDIAN AC_TYPE_SIGNAL @@ -724,20 +714,6 @@ AC_DEFINE(HAVE_TYPE_U_INT64_T, 1, [Does u_int64_t exist?]) fi -# -# Look for in_port_t. -# -AC_MSG_CHECKING([for in_port_t]) -AC_TRY_COMPILE([ -#include -#include ], -[in_port_t port = 25; return (0);], - [AC_MSG_RESULT(yes) - ], - [AC_MSG_RESULT(no) - AC_DEFINE(ISC_PLATFORM_NEEDPORTT, 1, [Do we need our own in_port_t?]) - ]) - AC_CACHE_CHECK([for a fallback value for HZ], ac_cv_var_default_hz, [ac_cv_var_default_hz=100 case "$host" in @@ -765,6 +741,9 @@ *-*-sunos4*) ac_cv_var_override_hz=yes ;; + *-*-kfreebsd*) + ac_cv_var_override_hz=yes + ;; esac]) case "$ac_cv_var_override_hz" in yes) @@ -805,8 +784,20 @@ ac_cv_struct_rt_msghdr=no) ]) -if test $ac_cv_struct_rt_msghdr = yes; then +AC_CACHE_CHECK([for struct rtattr], ac_cv_struct_rtattr, +[AC_TRY_COMPILE([ +#include +#include ], +[struct rtattr p;], + ac_cv_struct_rtattr=yes, + ac_cv_struct_rtattr=no) +]) + +if test $ac_cv_struct_rt_msghdr = yes -o $ac_cv_struct_rtattr = yes; then AC_DEFINE(HAS_ROUTING_SOCKET, 1, [Do we have a routing socket (struct rt_msghdr)?]) + if test $ac_cv_struct_rtattr = yes; then + AC_DEFINE(HAVE_RTNETLINK, 1, [Do we have Linux routing socket?]) + fi fi AC_CACHE_CHECK( @@ -846,117 +837,198 @@ AC_DEFINE(HAVE_STRUCT_PPSCLOCKEV, 1, [Does a system header define struct ppsclockev?]) fi -AC_CACHE_CHECK([struct sockaddr for sa_len], ac_cv_struct_sockaddr_has_sa_len, -[AC_TRY_COMPILE([ -#include -#include ],[ -extern struct sockaddr *ps; -return ps->sa_len;], - ac_cv_struct_sockaddr_has_sa_len=yes, - ac_cv_struct_sockaddr_has_sa_len=no) -]) -if test $ac_cv_struct_sockaddr_has_sa_len = yes; then - AC_DEFINE(HAVE_SA_LEN_IN_STRUCT_SOCKADDR, 1, [Should be obvious...]) -fi - -AC_CACHE_CHECK([for struct sockaddr_storage], ac_cv_struct_sockaddr_storage, -[AC_TRY_COMPILE([ -#include -#include -#include -],[ -struct sockaddr_storage n;], - ac_cv_struct_sockaddr_storage=yes, - ac_cv_struct_sockaddr_storage=no) -]) -if test $ac_cv_struct_sockaddr_storage = yes; then +AC_CACHE_CHECK( + [for struct sockaddr_storage], + ntp_cv_sockaddr_storage, + [ + AC_TRY_COMPILE( + [ + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif + ], + [ + struct sockaddr_storage n; + ], + [ntp_cv_sockaddr_storage="yes"], + [ntp_cv_sockaddr_storage="no"] + ) + ] +) +case "$ntp_cv_sockaddr_storage" in + yes) AC_DEFINE(HAVE_STRUCT_SOCKADDR_STORAGE, 1, [Does a system header define struct sockaddr_storage?]) -fi +esac -AC_CACHE_CHECK([for ss_family field in struct sockaddr_storage], - ac_cv_have_ss_family_in_struct_ss, [ +AC_CACHE_CHECK( + [for sockaddr_storage.ss_family], + ntp_cv_have_ss_family, + [ AC_TRY_COMPILE( - [ -#include -#include - ], - [ struct sockaddr_storage s; s.ss_family = 1; ], - [ ac_cv_have_ss_family_in_struct_ss="yes" ], - [ ac_cv_have_ss_family_in_struct_ss="no" ], + [ + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif + ], + [ + struct sockaddr_storage s; + s.ss_family = 1; + ], + [ntp_cv_have_ss_family="yes"], + [ntp_cv_have_ss_family="no"] ) -]) -if test "x$ac_cv_have_ss_family_in_struct_ss" = "xyes" ; then - AC_DEFINE(HAVE_SS_FAMILY_IN_SS, 1, [Does struct sockaddr_storage have ss_family?]) -else - # Hack around a problem... - # HMS: This is $host because we need the -D if we are building *for* it. - # HMS: 061029: Now that we separate the ss_* checks this is causing - # a problem - disable it until we get to the bottom of it. - case "$host" in - XXX*-*-hpux11.11) CPPFLAGS="$CPPFLAGS -D_NETINET_IN6_H" - ;; - esac -fi + ] +) -AC_CACHE_CHECK([for __ss_family field in struct sockaddr_storage], - ac_cv_have___ss_family_in_struct_ss, [ - AC_TRY_COMPILE( +case "$ntp_cv_have_ss_family" in + no) + AC_CACHE_CHECK( + [for sockaddr_storage.__ss_family], + ntp_cv_have___ss_family, + [ + AC_TRY_COMPILE( [ -#include -#include + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif ], - [ struct sockaddr_storage s; s.__ss_family = 1; ], - [ ac_cv_have___ss_family_in_struct_ss="yes" ], - [ ac_cv_have___ss_family_in_struct_ss="no" ] - ) -]) -if test "x$ac_cv_have___ss_family_in_struct_ss" = "xyes" ; then + [ + struct sockaddr_storage s; + s.__ss_family = 1; + ], + [ntp_cv_have___ss_family="yes"], + [ntp_cv_have___ss_family="no"] + ) + ] + ) + case "$ntp_cv_have___ss_family" in + yes) AC_DEFINE(HAVE___SS_FAMILY_IN_SS, 1, [Does struct sockaddr_storage have __ss_family?]) -fi + esac +esac -AH_VERBATIM([X_HAVE_SS_FAMILY_IN_SS], -[/* Handle ss_family */ -#if !defined(HAVE_SS_FAMILY_IN_SS) && defined(HAVE___SS_FAMILY_IN_SS) -# define ss_family __ss_family -#endif /* !defined(HAVE_SS_FAMILY_IN_SS) && defined(HAVE_SA_FAMILY_IN_SS) */]) +AH_VERBATIM( + [HAVE___SS_FAMILY_IN_SS_VERBATIM], + [ + /* Handle sockaddr_storage.__ss_family */ + #ifdef HAVE___SS_FAMILY_IN_SS + # define ss_family __ss_family + #endif /* HAVE___SS_FAMILY_IN_SS */ + ] +) -AC_CACHE_CHECK([for ss_len field in struct sockaddr_storage], - ac_cv_have_ss_len_in_struct_ss, [ +AC_CACHE_CHECK( + [for sockaddr_storage.ss_len], + ntp_cv_have_ss_len, + [ AC_TRY_COMPILE( - [ -#include -#include - ], - [ struct sockaddr_storage s; s.ss_len = 1; ], - [ ac_cv_have_ss_len_in_struct_ss="yes" ], - [ ac_cv_have_ss_len_in_struct_ss="no" ], + [ + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif + ], + [ + struct sockaddr_storage s; + s.ss_len = 1; + ], + [ntp_cv_have_ss_len="yes"], + [ntp_cv_have_ss_len="no"] ) -]) -if test "x$ac_cv_have_ss_len_in_struct_ss" = "xyes" ; then - AC_DEFINE(HAVE_SS_LEN_IN_SS, 1, [Does struct sockaddr_storage have ss_len?]) -fi + ] +) -AC_CACHE_CHECK([for __ss_len field in struct sockaddr_storage], - ac_cv_have___ss_len_in_struct_ss, [ - AC_TRY_COMPILE( +case "$ntp_cv_have_ss_len" in + no) + AC_CACHE_CHECK( + [for sockaddr_storage.__ss_len], + ntp_cv_have___ss_len, + [ + AC_TRY_COMPILE( [ -#include -#include + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif ], - [ struct sockaddr_storage s; s.__ss_len = 1; ], - [ ac_cv_have___ss_len_in_struct_ss="yes" ], - [ ac_cv_have___ss_len_in_struct_ss="no" ] - ) -]) -if test "x$ac_cv_have___ss_len_in_struct_ss" = "xyes" ; then + [ + struct sockaddr_storage s; + s.__ss_len = 1; + ], + [ntp_cv_have___ss_len="yes"], + [ntp_cv_have___ss_len="no"] + ) + ] + ) + case "$ntp_cv_have___ss_len" in + yes) AC_DEFINE(HAVE___SS_LEN_IN_SS, 1, [Does struct sockaddr_storage have __ss_len?]) -fi + esac +esac + +AH_VERBATIM( + [HAVE___SS_LEN_IN_SS_VERBATIM], + [ + /* Handle sockaddr_storage.__ss_len */ + #ifdef HAVE___SS_LEN_IN_SS + # define ss_len __ss_len + #endif /* HAVE___SS_LEN_IN_SS */ + ] +) -AH_VERBATIM([X_HAVE_SS_LEN_IN_SS], -[/* Handle ss_len */ -#if !defined(HAVE_SS_LEN_IN_SS) && defined(HAVE___SS_LEN_IN_SS) -# define ss_len __ss_len -#endif /* !defined(HAVE_SS_LEN_IN_SS) && defined(HAVE_SA_LEN_IN_SS) */]) +# +# Look for in_port_t. +# +AC_CACHE_CHECK( + [for in_port_t], + isc_cv_have_in_port_t, + [ + AC_TRY_COMPILE( + [ + #include + #include + ], + [ + in_port_t port = 25; + return (0); + ], + [isc_cv_have_in_port_t=yes], + [isc_cv_have_in_port_t=no] + ) + ] +) +case "$isc_cv_have_in_port_t" in + no) + AC_DEFINE(ISC_PLATFORM_NEEDPORTT, 1, [Declare in_port_t?]) +esac case "$ac_cv_header_machine_soundcard_h$ac_cv_header_sys_soundcard_h" in *yes*) @@ -1093,7 +1165,9 @@ # this conditional will need to change. Maybe use AC_TRY_RUN # instead to try to set the time to itself and check errno. ;; - *) AC_CHECK_FUNCS(clock_gettime clock_settime) + *) + AC_SEARCH_LIBS([clock_gettime], [rt]) + AC_CHECK_FUNCS([clock_gettime clock_settime]) ;; esac AC_CHECK_FUNCS(daemon) @@ -1209,10 +1283,15 @@ ;; esac +AC_SEARCH_LIBS([inet_ntop], [resolv], , , [-lsocket -lnsl]) AC_CHECK_FUNC(inet_ntop, [], [AC_DEFINE(ISC_PLATFORM_NEEDNTOP, 1, [ISC: provide inet_ntop()])]) AC_CHECK_FUNC(inet_pton, [], [AC_DEFINE(ISC_PLATFORM_NEEDPTON, 1, [ISC: provide inet_pton()])]) -AC_CHECK_FUNC(inet_aton, [], [AC_DEFINE(ISC_PLATFORM_NEEDATON, 1, [ISC: provide inet_aton()])]) -AC_CHECK_FUNCS(K_open kvm_open memcpy memmove memset) +case "$ac_cv_header_kvm_h" in + yes) + AC_CHECK_FUNCS(kvm_open) + ;; +esac +AC_CHECK_FUNCS(memcpy memmove memset) case "$host" in *-*-sco3.2v5.0.*) # Just stubs. Idiots. @@ -1385,14 +1464,8 @@ [AC_TRY_COMPILE([ #include "l_stdlib.h" -#ifdef HAVE_PROTOTYPES -#define P(x) x -#else -#define P(x) () -#endif - extern void *base; -extern sortfunc P((const void *, const void *)); +extern sortfunc (const void *, const void *); int sortfunc(a, b) const void *a; const void *b; { return 0; } @@ -1468,13 +1541,8 @@ #ifdef HAVE_UNISTD_H # include #endif -#ifdef HAVE_PROTOTYPES -#define P(x) x -#else -#define P(x) () -#endif ], - [extern int syscall P((int, ...));], + [extern int syscall (int, ...);], ac_cv_decl_syscall=yes, ac_cv_decl_syscall=no)]) case "$ac_cv_decl_syscall" in yes) AC_DEFINE(DECL_SYSCALL, 1, [Declare syscall()?]) ;; @@ -1640,32 +1708,45 @@ yes) AC_DEFINE(UDP_BACKWARDS_SETOWN, 1, [Do we set process groups with -pid?]) ;; esac -AC_CACHE_CHECK([if we need a ctty for F_SETOWN], ac_cv_func_ctty_for_f_setown, -[[case "$host" in - *-*-bsdi[23]*) - ans=yes - ;; - *-*-freebsd*) - ans=yes - ;; - *-*-netbsd*3.[0-8]*|*-*-netbsd*[0-2].*|*-*-netbsd*3.99.[0-7]) - ans=yes - ;; - *-*-openbsd*) - ans=yes - ;; - *-*-osf*) - ans=yes - ;; - *-*-darwin*) - ans=yes - ;; - *) ans=no - ;; -esac -ac_cv_func_ctty_for_f_setown=$ans]]) -case "$ac_cv_func_ctty_for_f_setown" in - yes) AC_DEFINE(USE_FSETOWNCTTY, 1, [Must we have a CTTY for fsetown?]) ;; +AC_CACHE_CHECK( + [if we need a ctty for F_SETOWN], + ntp_cv_func_ctty_for_f_setown, + [ + case "$host" in + *-*-bsdi[23]*) + ans=yes + ;; + *-*-freebsd*) + ans=yes + ;; + # NetBSD versions prior to 3.99.8 require a CTTY for F_SETOWN, + # while later versions will fail a ioctl(TIOCSCTTY, 0) call in + # some cases and so should not have USE_FSETOWNCTTY. "netbsd" + # in $host may be followed by "aout", "ecoff", or "elf". + *-*-netbsd*[a-z]3.[0-8]*|*-*-netbsd*[a-z][0-2].*|*-*-netbsd*[a-z]3.99.[0-7]) + ans=yes + ;; + *-*-netbsd3.[0-8]*|*-*-netbsd[0-2].*|*-*-netbsd3.99.[0-7]) + ans=yes + ;; + *-*-openbsd*) + ans=yes + ;; + *-*-osf*) + ans=yes + ;; + *-*-darwin*) + ans=yes + ;; + *) + ans=no + esac + ntp_cv_func_ctty_for_f_setown=$ans + ] +) +case "$ntp_cv_func_ctty_for_f_setown" in + yes) + AC_DEFINE(USE_FSETOWNCTTY, 1, [Must we have a CTTY for fsetown?]) esac AC_CACHE_CHECK([if the OS fails to clear cached routes when more specific routes become available], ac_cv_os_routeupdates, @@ -1781,6 +1862,9 @@ *-*-unicosmp*) ans=no ;; + *-*-kfreebsd*) + ans=no + ;; esac ;; esac @@ -1849,6 +1933,9 @@ *-*-unicosmp*) ans=no ;; + *-*-kfreebsd*) + ans=no + ;; *) ans=yes ;; esac @@ -1900,6 +1987,9 @@ *-*-unicosmp*) ans=no ;; + *-*-kfreebsd*) + ans=no + ;; *) ans=yes ;; esac @@ -1979,12 +2069,12 @@ yes) AC_DEFINE(NO_PARENB_IGNPAR, 1, [Is there a problem using PARENB and IGNPAR (IRIX)?]) ;; esac -AC_MSG_CHECKING([if we're including debugging code]) +AC_MSG_CHECKING([if we're including ntpd debugging code]) AC_ARG_ENABLE(debugging, - AC_HELP_STRING([--enable-debugging], [+ include debugging code]), + AC_HELP_STRING([--enable-debugging], [+ include ntpd debugging code]), [ntp_ok=$enableval], [ntp_ok=yes]) if test "$ntp_ok" = "yes"; then - AC_DEFINE(DEBUG, 1, [Enable debugging?]) + AC_DEFINE(DEBUG, 1, [Enable ntpd debugging code?]) fi AC_MSG_RESULT($ntp_ok) @@ -2010,7 +2100,7 @@ AC_DEFINE_UNQUOTED(DSTMINUTES, $ans, [The number of minutes in a DST adjustment]) AC_MSG_RESULT([$ans]) -AC_MSG_CHECKING([[if ntpd will retry on permanent DNS errors]]) +AC_MSG_CHECKING([[if ntpd will retry permanent DNS failures]]) AC_ARG_ENABLE( [ignore-dns-errors], AS_HELP_STRING( @@ -2026,6 +2116,22 @@ esac AC_MSG_RESULT([$ans]) +AC_MSG_CHECKING([if ntpd will use the deferred DNS lookup path]) +AC_ARG_ENABLE( + [force-defer-DNS], + AS_HELP_STRING( + [--enable-force-defer-DNS], + [- force all DNS lookups to take the deferred path] + ), + [ans=$enableval], + [ans=no] +) +case "$ans" in + yes) + AC_DEFINE(FORCE_DEFER_DNS, 1, [Force deferred DNS lookups?]) +esac +AC_MSG_RESULT([$ans]) + AC_CACHE_CHECK([if we have the tty_clk line discipline/streams module], ac_cv_var_tty_clk, [case "$ac_cv_header_sys_clkdefs_h$ac_cv_hdr_def_tiocdcdtimestamp" in @@ -2043,36 +2149,57 @@ yes) AC_DEFINE(PPS, 1, [Do we have the ppsclock streams module?]) ;; esac -AC_CACHE_CHECK([for kernel multicast support], ac_cv_var_mcast, - [ac_cv_var_mcast=no - case "$host" in - i386-sequent-sysv4) ;; - *) AC_EGREP_CPP(yes, - [#include -#ifdef IP_ADD_MEMBERSHIP - yes -#endif - ], ac_cv_var_mcast=yes) ;; - esac]) -case "$ac_cv_var_mcast" in - yes) - AC_DEFINE(MCAST, 1, [Does the kernel support multicasting IP?]) - AC_CACHE_CHECK([[arg type needed for IP*_MULTICAST_LOOP for setsockopt()]], - ac_cv_var_typeof_ip_multicast_loop, - [case "$host" in - *-*-netbsd*|*-*-*linux*) - ac_cv_var_typeof_ip_multicast_loop=u_int - ;; - *-*-winnt*) - ac_cv_var_typeof_ip_multicast_loop=BOOL - ;; - *) ac_cv_var_typeof_ip_multicast_loop=u_char +AC_CACHE_CHECK( + [for multicast IP support], + ntp_cv_multicast, + [ + ntp_cv_multicast=no + case "$host" in + i386-sequent-sysv4) ;; - esac]) - AC_DEFINE_UNQUOTED(TYPEOF_IP_MULTICAST_LOOP, - $ac_cv_var_typeof_ip_multicast_loop, - [What type to use for setsockopt]) - ;; + *) + AC_COMPILE_IFELSE( + AC_LANG_PROGRAM( + [ + #ifdef HAVE_NETINET_IN_H + #include + #endif + ], + [ + struct ip_mreq ipmr; + ipmr.imr_interface.s_addr = 0; + ] + ), + [ntp_cv_multicast=yes], + [] + ) + esac + ] +) + +case "$ntp_cv_multicast" in + yes) + AC_DEFINE(MCAST, 1, [Does the target support multicast IP?]) + AC_CACHE_CHECK( + [[arg type needed for setsockopt() IP*_MULTICAST_LOOP]], + ntp_cv_typeof_ip_multicast_loop, + [ + case "$host" in + *-*-netbsd*|*-*-*linux*) + ntp_cv_typeof_ip_multicast_loop=u_int + ;; + *-*-winnt*) + ntp_cv_typeof_ip_multicast_loop=BOOL + ;; + *) + ntp_cv_typeof_ip_multicast_loop=u_char + esac + ] + ) + AC_DEFINE_UNQUOTED([TYPEOF_IP_MULTICAST_LOOP], + $ntp_cv_typeof_ip_multicast_loop, + [What type to use for setsockopt] + ) esac AC_CACHE_CHECK([[availability of ntp_{adj,get}time()]], ac_cv_var_ntp_syscalls, @@ -3109,12 +3236,11 @@ MAKE_LIBPARSE=libparse.a # HMS: check_y2k trips the 34 year problem now... false && MAKE_CHECK_Y2K=check_y2k - AC_DEFINE(PPS_SAMPLE, 1, [PPS auxiliary interface for ATOM?]) - AC_DEFINE(CLOCK_ATOM) ;; esac AC_MSG_RESULT([$ans]) + # AC_SUBST(RSAOBJS) # AC_SUBST(RSASRCS) # AC_SUBST(RSADIR) @@ -3122,116 +3248,7 @@ # AC_SUBST(LIBRSAREF) # AC_SUBST(MAKE_LIBRSAREF) -AC_SUBST(OPENSSL) -AC_SUBST(OPENSSL_INC) -AC_SUBST(OPENSSL_LIB) - -AC_MSG_CHECKING([for openssl library directory]) -AC_ARG_WITH(openssl-libdir, - AC_HELP_STRING([--with-openssl-libdir], [+ =/something/reasonable]), -[ans=$withval], -[case "$build" in - $host) ans=yes ;; - *) ans=no ;; -esac]) -case "$ans" in - no) ;; - yes) # Look in: - ans="/usr/lib /usr/lib/openssl /usr/sfw/lib /usr/local/lib /usr/local/ssl/lib" - ;; - *) # Look where they said - ;; -esac -case "$ans" in - no) ;; - *) # Look for libcrypto.a and libssl.a: - for i in $ans no - do - case "$host" in - *-*-darwin*) - test -f $i/libcrypto.dylib -a -f $i/libssl.dylib && break - ;; - *) - test -f $i/libcrypto.so -a -f $i/libssl.so && break - test -f $i/libcrypto.a -a -f $i/libssl.a && break - ;; - esac - done - case "$i" in - no) - ans=no - OPENSSL_LIB= - ;; - *) ans=$i - OPENSSL_LIB=$ans - ;; - esac - ;; -esac -AC_MSG_RESULT([$ans]) - -AC_MSG_CHECKING([for openssl include directory]) -AC_ARG_WITH(openssl-incdir, - AC_HELP_STRING([--with-openssl-incdir], [+ =/something/reasonable]), -[ans=$withval], -[case "$build" in - $host) ans=yes ;; - *) ans=no ;; -esac]) -case "$ans" in - no) ;; - yes) # look in: - ans="/usr/include /usr/sfw/include /usr/local/include /usr/local/ssl/include" - ;; - *) # Look where they said - ;; -esac -case "$ans" in - no) ;; - *) # look for openssl/opensslconf.h: - for i in $ans no - do - test -f $i/openssl/opensslconf.h && break - done - case "$i" in - no) - ans=no - OPENSSL_INC= - ;; - *) ans=$i - OPENSSL_INC=$ans - ;; - esac - ;; -esac -AC_MSG_RESULT([$ans]) - -AC_ARG_WITH(crypto, - AC_HELP_STRING([--with-crypto], [+ =openssl]), -[ans=$withval], [ans=yes]) -case "$ans" in - no) ;; - yes|openssl) - if test -z "$OPENSSL_LIB" -o -z "$OPENSSL_INC" - then - ans=no - else - # We have OpenSSL inc/lib - use them. - ans=openssl - CPPFLAGS="$CPPFLAGS -I$OPENSSL_INC" - LDFLAGS="$LDFLAGS -L$OPENSSL_LIB" - case "$need_dash_r" in - 1) LDFLAGS="$LDFLAGS -R$OPENSSL_LIB" - ;; - esac - AC_SUBST(LCRYPTO, [-lcrypto]) - AC_DEFINE(OPENSSL, , [Use OpenSSL?]) - AC_CHECK_FUNCS(EVP_md2 EVP_mdc2) - fi - ;; -esac -AC_MSG_CHECKING(for the level of crypto support) -AC_MSG_RESULT([$ans]) +NTP_OPENSSL AC_MSG_CHECKING([if we want to compile with ElectricFence]) AC_ARG_WITH(electricfence, @@ -3297,6 +3314,7 @@ sparc-*-solaris2*) ans=parsesolaris MAKE_PARSEKMODULE=parse + AC_CHECK_HEADERS([strings.h]) ;; esac ;; @@ -3885,7 +3903,7 @@ # be better to simply remove the hunk above, I did not want # to remove it if there is hope it will be used again. # -unset ac_cv_make_tickadj +$as_unset ac_cv_make_tickadj AC_CACHE_CHECK([if we want and can make the tickadj utility], ac_cv_make_tickadj, ac_cv_make_tickadj=yes) @@ -3950,6 +3968,68 @@ esac +AC_MSG_CHECKING([if we want to build ntpsnmpd]) +AC_ARG_WITH(ntpsnmpd, + AC_HELP_STRING([--with-ntpsnmpd], [s Build ntpsnmpd MIB agent?]), + [ans=$withval], + [case "$PATH_NET_SNMP_CONFIG" in + /*) ans=yes ;; + *) ans=no ;; + esac]) +AC_MSG_RESULT($ans) + +case "$ans" in + yes) + case "$PATH_NET_SNMP_CONFIG" in + /*) + SNMP_LIBS=`$PATH_NET_SNMP_CONFIG --agent-libs` + AC_SUBST(SNMP_LIBS) + # HMS: we really want to separate CPPFLAGS and CFLAGS + foo=`$PATH_NET_SNMP_CONFIG --cflags` + SNMP_CPPFLAGS= + SNMP_CFLAGS= + for i in $foo; do + case "$i" in + -D*|-U*|-I*) + SNMP_CPPFLAGS="$SNMP_CPPFLAGS $i" + ;; + *) SNMP_CFLAGS="$SNMP_CFLAGS $i" + ;; + esac + done + AC_SUBST(SNMP_CPPFLAGS) + AC_SUBST(SNMP_CFLAGS) + + save_CFLAGS=$CFLAGS + save_CPPFLAGS=$CPPFLAGS + save_LIBS=$LIBS + CFLAGS=$SNMP_CFLAGS + CPPFLAGS=$SNMP_CPPFLAGS + + AC_CHECK_HEADER([net-snmp/net-snmp-config.h], [MAKE_NTPSNMPD=ntpsnmpd], + [AC_MSG_WARN([net-snmp-config present but net-snmp headers are not available!])]) + + # Do this last, as we're messing up LIBS. + + # check -lnetsnmp for netsnmp_daemonize + LIBS=`$PATH_NET_SNMP_CONFIG --libs` + AC_CHECK_LIB([netsnmp], [netsnmp_daemonize], [], + [AC_DEFINE([NEED_NETSNMP_DAEMONIZE], [1], + [We need to provide netsnmp_daemonize()])]) + + CFLAGS=$save_CFLAGS + CPPFLAGS=$save_CPPFLAGS + LIBS=$save_LIBS + + ;; + *) AC_MSG_WARN([Cannot build ntpsnmpd as desired - net-snmp-config cannot be found]) + ;; + esac + ;; +esac +AC_SUBST(MAKE_NTPSNMPD) + + AC_MSG_CHECKING([if we should always slew the time]) # target-specific defaults @@ -4146,6 +4226,26 @@ esac +AC_MSG_CHECKING([if we want new session key behavior]) + +AC_ARG_ENABLE( + [bug1243-fix], + AC_HELP_STRING( + [--enable-bug1243-fix], + [+ use unmodified autokey session keys] + ), + [ans=$enableval], + [ans=yes] +) + +AC_MSG_RESULT([$ans]) + +case "$ans" in + no) + AC_DEFINE([DISABLE_BUG1243_FIX], 1, [use old autokey session key behavior?]) +esac + + AC_MSG_CHECKING([if we should use the IRIG sawtooth filter]) case "$host" in @@ -4198,8 +4298,8 @@ AC_ARG_ENABLE( [ntp-signd], AC_HELP_STRING( - [--enable-ntp-signd], - [- Provide support for Samba's signing daemon, =/var/run/ntp_signd] + [--enable-ntp-signd], + [- Provide support for Samba's signing daemon, =/var/run/ntp_signd] ), [ans=$enableval], [ans=no] @@ -4220,38 +4320,13 @@ case "$ntp_signd_path" in '') - wintime_default=no ;; *) - wintime_default=yes AC_DEFINE(HAVE_NTP_SIGND, ,[Do we want support for Samba's signing daemon?]) AC_DEFINE_UNQUOTED(NTP_SIGND_PATH, "$ntp_signd_path", [Path to sign daemon rendezvous socket]) esac -AC_MSG_CHECKING([if we want the windows symmetric client hack]) - -# default is no, unless --enable-ntp-signd was given -ans=$wintime_default -unset wintime_default - -AC_ARG_ENABLE( - [wintime], - AC_HELP_STRING( - [--enable-wintime], - [- Provide the windows symmetric client hack] - ), - [ans=$enableval], -) - -AC_MSG_RESULT([$ans]) - -case "$ans" in - yes) - AC_DEFINE(WINTIME, ,[Do we want the windows symmetric client hack?]) -esac - - AC_CHECK_HEADERS(sys/clockctl.h) case "$host" in @@ -4264,7 +4339,7 @@ AC_ARG_ENABLE( [clockctl], - AC_HELP_STRING( + AS_HELP_STRING( [--enable-clockctl], [s Use /dev/clockctl for non-root clock control] ), @@ -4283,35 +4358,38 @@ case "$ac_cv_header_sys_capability_h$ac_cv_header_sys_prctl_h" in yesyes) - ntp_have_linuxcaps=yes + case "$host" in + mips-sgi-irix*) + ntp_have_linuxcaps=no + ;; + *) ntp_have_linuxcaps=yes + ;; + esac ;; *) ntp_have_linuxcaps=no esac -AC_MSG_RESULT([$ntp_have_linuxcaps]) - - AC_ARG_ENABLE( [linuxcaps], - AC_HELP_STRING( + AS_HELP_STRING( [--enable-linuxcaps], [+ Use Linux capabilities for non-root clock control] ), [ntp_have_linuxcaps=$enableval] ) +AC_MSG_RESULT([$ntp_have_linuxcaps]) case "$ntp_have_linuxcaps" in yes) - AC_DEFINE(HAVE_LINUX_CAPABILITIES, ,[[Do we have Linux capabilities?]]) + AC_DEFINE(HAVE_LINUX_CAPABILITIES, ,[Do we have Linux capabilities?]) LIBS="$LIBS -lcap" esac - case "$ntp_use_dev_clockctl$ntp_have_linuxcaps" in *yes*) - AC_DEFINE(HAVE_DROPROOT, ,[[Can we drop root privileges?]]) + AC_DEFINE(HAVE_DROPROOT, ,[Can we drop root privileges?]) esac @@ -4324,7 +4402,7 @@ AC_CHECK_FUNC( [setppriv], - AC_DEFINE(HAVE_SOLARIS_PRIVS, ,[[Are Solaris privileges available?]]) + AC_DEFINE(HAVE_SOLARIS_PRIVS, ,[Are Solaris privileges available?]) ) @@ -4332,8 +4410,26 @@ # ISC stuff # -if test $ac_cv_struct_sockaddr_has_sa_len = yes; then - AC_DEFINE(ISC_PLATFORM_HAVESALEN, ,[ISC: struct sockaddr as sa_len?]) +AC_CACHE_CHECK( + [struct sockaddr for sa_len], + isc_cv_platform_havesalen, + [ + AC_TRY_COMPILE( + [ + #include + #include + ], + [ + extern struct sockaddr *ps; + return ps->sa_len; + ], + [isc_cv_platform_havesalen=yes], + [isc_cv_platform_havesalen=no] + ) + ] +) +if test $isc_cv_platform_havesalen = yes; then + AC_DEFINE(ISC_PLATFORM_HAVESALEN, ,[struct sockaddr has sa_len?]) fi AC_ARG_ENABLE(ipv6, AC_HELP_STRING([--enable-ipv6], [s use IPv6?])) @@ -4384,6 +4480,7 @@ [AC_HELP_STRING([--with-kame], [- =/usr/local/v6])], use_kame="$withval", use_kame="no") + case "$use_kame" in no) ;; @@ -4517,9 +4614,9 @@ AC_CACHE_CHECK( [for in6addr_any], - ac_cv_have_in6addr_any, + isc_cv_have_in6addr_any, [ - AC_COMPILE_IFELSE( + AC_LINK_IFELSE( [ AC_LANG_PROGRAM( [ @@ -4535,13 +4632,13 @@ ] ) ], - [ac_cv_have_in6addr_any=yes], - [ac_cv_have_in6addr_any=no] + [isc_cv_have_in6addr_any=yes], + [isc_cv_have_in6addr_any=no] ) ] ) -case "$ac_cv_have_in6addr_any" in +case "$isc_cv_have_in6addr_any" in no) AC_DEFINE(ISC_PLATFORM_NEEDIN6ADDRANY, , [missing in6addr_any?]) esac @@ -4627,6 +4724,19 @@ AC_DEFINE(HAVE_IFLIST_SYSCTL,1,[have iflist_sysctl?]) esac +### + +AC_MSG_CHECKING([if we want the saveconfig mechanism]) +AC_ARG_ENABLE(saveconfig, + AC_HELP_STRING([--enable-saveconfig], [+ saveconfig mechanism]), + [ntp_ok=$enableval], [ntp_ok=yes]) +ntp_saveconfig_enabled=0 +if test "$ntp_ok" = "yes"; then + ntp_saveconfig_enabled=1 + AC_DEFINE(SAVECONFIG, 1, [saveconfig mechanism]) +fi +AM_CONDITIONAL([SAVECONFIG_ENABLED], [test x$ntp_saveconfig_enabled = x1]) +AC_MSG_RESULT($ntp_ok) ### @@ -4647,6 +4757,7 @@ AC_CONFIG_FILES(ntpdc/Makefile) AC_CONFIG_FILES(ntpdc/nl.pl, [chmod +x ntpdc/nl.pl]) AC_CONFIG_FILES(ntpq/Makefile) +AC_CONFIG_FILES(ntpsnmpd/Makefile) AC_CONFIG_FILES(parseutil/Makefile) AC_CONFIG_FILES(scripts/Makefile) AC_CONFIG_FILES(scripts/calc_tickadj, [chmod +x scripts/calc_tickadj]) diff -urN src/contrib/ntp/deps-ver src.ntp/contrib/ntp/deps-ver --- src/contrib/ntp/deps-ver 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/deps-ver 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1 @@ +Fri Nov 13 17:21:31 UTC 2009 diff -urN src/contrib/ntp/depsver.mf src.ntp/contrib/ntp/depsver.mf --- src/contrib/ntp/depsver.mf 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/depsver.mf 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,67 @@ +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + ..) \ + cd .. && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + *) \ + echo 'Fatal: depsver.mf Automake fragment limited' \ + 'to immediate subdirectories.' && \ + echo "top_builddir: $(top_builddir)" && \ + echo "subdir: $(subdir)" && \ + exit 1 \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(DEPDIR)/deps-ver + @touch $@ + +BUILT_SOURCES += .deps-ver +CLEANFILES += .deps-ver + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# diff -urN src/contrib/ntp/dot.emacs src.ntp/contrib/ntp/dot.emacs --- src/contrib/ntp/dot.emacs 1999-12-09 14:01:03.000000000 +0100 +++ src.ntp/contrib/ntp/dot.emacs 2009-12-09 08:36:36.000000000 +0100 @@ -1,13 +1,14 @@ -;; This is how Dave Mills likes to see the code formatted. +;; This is how Dave Mills likes to see the NTP code formatted. (defconst ntp-c-style - '((c-basic-offset . 8) + '((c-basic-offset . 8) + (fill-column . 72) (c-offsets-alist . ((arglist-intro . +) (case-label . *) (statement-case-intro . *) (statement-cont . *) (substatement-open . 0)))) - "Dave L. Mills; programming style for use with ntp") + "David L. Mills; NTP code indentation style") (defun ntp-c-mode-common-hook () ;; add ntp c style diff -urN src/contrib/ntp/flock-build src.ntp/contrib/ntp/flock-build --- src/contrib/ntp/flock-build 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/flock-build 2010-02-16 12:17:55.000000000 +0100 @@ -1,14 +1,32 @@ #! /bin/sh +IAM=`hostname || uname -n` +MYNAME=`IFS=. ; set $IAM ; echo $1` + +case "$1" in + '--one'|'-1') + shift + FB_FIRSTONLY=1 + LIST=$MYNAME + ;; + *) + FB_FIRSTONLY=0 +esac + BUILD_ARGS="$@" PARSE="--enable-parse-clocks" #PARSE= STD="--enable-simulator" -case "$SIMUL" in - '') PARALLEL_BUILDS=1 - ;; - *) PARALLEL_BUILDS=$SIMUL +case "$SIMUL::$FB_FIRSTONLY" in + ::*) + PARALLEL_BUILDS=1 + ;; + *::0) + PARALLEL_BUILDS=$SIMUL + ;; + *) + PARALLEL_BUILDS=1 esac case "$PARALLEL_BUILDS" in @@ -30,7 +48,6 @@ # Campus: # * baldwin sparc-sun-solaris2.10 # * bridgeport sparc-sun-solaris2.10 -# * cowbird freebsd-6.1 # * malarky sparc-sun-solaris2.10 # * pogo sparc-sun-solaris2.10 # * rackety freebsd-6.1 @@ -42,7 +59,7 @@ SIG=`perl -e 'print rand'` case "$LIST" in - '') LIST="baldwin bridgeport cowbird malarky pogo rackety" ;; + '') LIST="malarky rackety" ;; esac for i in $LIST @@ -51,56 +68,61 @@ [ -f .buildkey-$i ] && SKIPTHIS=1 case "$SKIPTHIS" in 1) - echo flock-build running on $i? check LIST, skipping - ;; - 0) - echo $i - echo $SIG > .buildkey-$i - case "1" in - 0) - ssh $i "cd $c_d ; ./build $SIG $PARSE $STD $BUILD_ARGS" & - ssh $i "cd $c_d ; ./build $SIG $PARSE $STD --without-crypto $BUILD_ARGS" & - ssh $i "cd $c_d ; ./build $SIG $STD --disable-all-clocks $BUILD_ARGS" & - ;; - 1) - cat > .flockbuild-$i-$SIG < .buildkey-$i + case "1" in + 0) + ssh $i "cd $c_d ; ./build $SIG $PARSE $STD $BUILD_ARGS" & + ssh $i "cd $c_d ; ./build $SIG $PARSE $STD --without-crypto $BUILD_ARGS" & + ssh $i "cd $c_d ; ./build $SIG $STD --disable-all-clocks $BUILD_ARGS" & + ;; + 1) + cat > .flockbuild-$i-$SIG <<-ENDQUOT + #!/bin/sh + + # script uses job control and expects to be invoked + # in a ssh session started with the -tt option, + # which forces a pseudo-tty to be used. + + cd $c_d + COUNT=0 + + ./build $SIG $PARSE $STD $BUILD_ARGS & + + COUNT=\`expr \$COUNT + 1\` + echo \`date -u '+%H:%M:%S'\` $i started build \$COUNT of 4 + [ 0 -lt \`expr \$COUNT % $PARALLEL_BUILDS\` ] || wait + + case $FB_FIRSTONLY in + '0') + ./build $SIG $PARSE $STD --disable-debugging $BUILD_ARGS & + + COUNT=\`expr \$COUNT + 1\` + echo \`date -u '+%H:%M:%S'\` $i started build \$COUNT of 4 + [ 0 -lt \`expr \$COUNT % $PARALLEL_BUILDS\` ] || wait + + ./build $SIG $PARSE $STD --without-crypto $BUILD_ARGS & + + COUNT=\`expr \$COUNT + 1\` + echo \`date -u '+%H:%M:%S'\` $i started build \$COUNT of 4 + [ 0 -lt \`expr \$COUNT % $PARALLEL_BUILDS\` ] || wait + + ./build $SIG $STD --disable-all-clocks $BUILD_ARGS & + + COUNT=\`expr \$COUNT + 1\` + echo \`date -u '+%H:%M:%S'\` $i started build \$COUNT of 4 + wait + esac + echo \`date -u '+%H:%M:%S'\` $i flock-build $c_d done. + rm .buildkey-$i ENDQUOT - chmod +x .flockbuild-$i-$SIG - ssh -tt $i "$c_d/.flockbuild-$i-$SIG ; \ - rm $c_d/.flockbuild-$i-$SIG" 2>/dev/null & - esac + chmod +x .flockbuild-$i-$SIG + ssh -tt $i "$c_d/.flockbuild-$i-$SIG ; \ + rm $c_d/.flockbuild-$i-$SIG" 2>/dev/null & + esac esac done echo `date -u '+%H:%M:%S'` flock-build launched diff -urN src/contrib/ntp/html/accopt.html src.ntp/contrib/ntp/html/accopt.html --- src/contrib/ntp/html/accopt.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/accopt.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,73 +0,0 @@ - - - - - - - - Access Control Options - - - - -

Access Control Options

- giffrom Pogo, Walt Kelly -

The skunk watches for intruders and sprays.

-

Last update: 18:35 UTC Thursday, July 28, 2005

-
-

Related Links

- -

Table of Contents

- -
-

Access Control Support

- The ntpd daemon implements a general purpose address/mask based restriction list. The list contains address/match entries sorted first by increasing address values and and then by increasing mask values. A match occurs when the bitwise AND of the mask and the packet source address is equal to the bitwise AND of the mask and address in the list. The list is searched in order with the last match found defining the restriction flags associated with the entry. Additional information and examples can be found in the Notes on Configuring NTP and Setting up a NTP Subnet page. -

The restriction facility was implemented in conformance with the access policies for the original NSFnet backbone time servers. Later the facility was expanded to deflect cryptographic and clogging attacks. While this facility may be useful for keeping unwanted or broken or malicious clients from congesting innocent servers, it should not be considered an alternative to the NTP authentication facilities. Source address based restrictions are easily circumvented by a determined cracker.

-

Clients can be denied service because they are explicitly included in the restrict list created by the restrict command or implicitly as the result of cryptographic or rate limit violations. Cryptographic violations include certificate or identity verification failure; rate limit violations generally result from defective NTP implementations that send packets at abusive rates. Some violations cause denied service only for the offending packet, others cause denied service for a timed period and others cause the denied service for an indefinate period. When a client or network is denied access for an indefinate period, the only way at present to remove the restrictions is by restarting the server.

-

The Kiss-of-Death Packet

-

Ordinarily, packets denied service are simply dropped with no further action except incrementing statistics counters. Sometimes a more proactive response is needed, such as a server message that explicitly requests the client to stop sending and leave a message for the system operator. A special packet format has been created for this purpose called the "kiss-o'-death" (KoD) packet. KoD packets have the leap bits set unsynchronized and stratum set to zero and the reference identifier field set to a four-byte ASCII code. If the noserve or notrust flag of the matching restrict list entry is set, the code is "DENY"; if the limited flag is set and the rate limit is exceeded, the code is "RATE". Finally, if a cryptographic violation occurs, the code is "CRYP".

-

A client receiving a KoD performs a set of sanity checks to minimize security exposure, then updates the stratum and reference identifier peer variables, sets the access denied (TEST4) bit in the peer flash variable and sends a message to the log. As long as the TEST4 bit is set, the client will send no further packets to the server. The only way at present to recover from this condition is to restart the protocol at both the client and server. This happens automatically at the client when the association times out. It will happen at the server only if the server operator cooperates.

-

Access Control Commands

-
-
discard [ average avg ][ minimum min ] [ monitor prob ] -
Set the parameters of the limited facility which protects the server from client abuse. The average subcommand specifies the minimum average packet spacing, while the minimum subcommand specifies the minimum packet spacing. Packets that violate these minima are discarded and a kiss-o'-death packet returned if enabled. The default minimum average and minimum are 5 and 2, respectively. The monitor subcommand specifies the probability of discard for packets that overflow the rate-control window. -
restrict address [mask mask] [flag][...] -
The address argument expressed in dotted-quad form is the address of a host or network. Alternatively, the address argument can be a valid host DNS name. The mask argument expressed in dotted-quad form defaults to 255.255.255.255, meaning that the address is treated as the address of an individual host. A default entry (address 0.0.0.0, mask 0.0.0.0) is always included and is always the first entry in the list. Note that text string default, with no mask option, may be used to indicate the default entry. -
In the current implementation, flag always restricts access, i.e., an entry with no flags indicates that free access to the server is to be given. The flags are not orthogonal, in that more restrictive flags will often make less restrictive ones redundant. The flags can generally be classed into two catagories, those which restrict time service and those which restrict informational queries and attempts to do run-time reconfiguration of the server. One or more of the following flags may be specified: -
-
ignore -
Deny packets of all kinds, including ntpq and ntpdc queries. -
kod -
If this flag is set when an access violation occurs, a kiss-o'-death (KoD) packet is sent. KoD packets are rate limited to no more than one per second. If another KoD packet occurs within one second after the last one, the packet is dropped -
limited -
Deny service if the packet spacing violates the lower limits specified in the discard command. A history of clients is kept using the monitoring capability of ntpd. Thus, monitoring is always active as long as there is a restriction entry with the limited flag. -
lowpriotrap -
Declare traps set by matching hosts to be low priority. The number of traps a server can maintain is limited (the current limit is 3). Traps are usually assigned on a first come, first served basis, with later trap requestors being denied service. This flag modifies the assignment algorithm by allowing low priority traps to be overridden by later requests for normal priority traps. -
nomodify -
Deny ntpq and ntpdc queries which attempt to modify the state of the server (i.e., run time reconfiguration). Queries which return information are permitted. -
noquery -
Deny ntpq and ntpdc queries. Time service is not affected. -
nopeer -
Deny packets which would result in mobilizing a new association.  This includes broadcast, symmetric-active and manycast client packets when a configured association does not exist. -
noserve -
Deny all packets except ntpq and ntpdc queries. -
notrap -
Decline to provide mode 6 control message trap service to matching hosts. The trap service is a subsystem of the ntpdq control message protocol which is intended for use by remote event logging programs. -
notrust -
Deny packets unless the packet is cryptographically authenticated. -
ntpport -
This is actually a match algorithm modifier, rather than a restriction flag. Its presence causes the restriction entry to be matched only if the source port in the packet is the standard NTP UDP port (123). Both ntpport and non-ntpport may be specified. The ntpport is considered more specific and is sorted later in the list. -
version -
Deny packets that do not match the current NTP version. -
-
Default restriction list entries with the flags ignore, interface, ntpport, for each of the local host's interface addresses are inserted into the table at startup to prevent the server from attempting to synchronize to its own time. A default entry is also always present, though if it is otherwise unconfigured; no flags are associated with the default entry (i.e., everything besides your own NTP server is unrestricted). -
-
- - - - \ No newline at end of file diff -urN src/contrib/ntp/html/assoc.html src.ntp/contrib/ntp/html/assoc.html --- src/contrib/ntp/html/assoc.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/assoc.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,59 +0,0 @@ - - - - - - - - Association Management - - - - -

Association Management

- giffrom Alice's Adventures in Wonderland, Lewis Carroll -

Make sure who your friends are.

-

Last update: 18:35 UTC Thursday, July 28, 2005

-
-

Related Links

- -

Table of Contents

- -
-

Association Modes

-

NTP Version 4 (NTPv4) incorporates new features and refinements to the NTP Version 3 (NTPv3) algorithms; however, it continues the tradition of backwards compatibility with older versions. A number of new operating modes for automatic server discovery and improved accuracy in occasionally connected networks are provided. Following is an overview of the new features; additional information is available on the Configuration Options and Authentication Options pages and in the papers, reports, memoranda and briefings at www.ntp.org.

-

There are two types of associations: persistent associations, which result from configuration file commands, and ephemeral associations, which result from protocol operations described below. A persistent association is never demobilized, although it may become dormant when the associated server becomes unreachable. An ephemeral association is mobilized when a message arrives from a server; for instance, a symmetric passive association is mobilized upon arrival of a symmetric active message. A broadcast client association is mobilized upon arrival of a broadcast server message, while a Manycast client association is mobilized upon arrival of a Manycast server message.

-

Ordinarily, successful mobilization of an ephemeral association requires the server to be cryptographically authenticated to the dependent client. This can be done using either symmetric-key or public-key cryptography, as described in the Authentication Options page. The cryptographic means insure an unbroken chain of trust between the dependent client and the primary servers at the root of the synchronization subnet. We call this chain the provenance of the client and define new vocabulary as to proventicate a client or provide proventic credentials. Once mobilized, ephemeral associations are demobilized when either (a) the server becomes unreachable or (b) the server refreshes the key media without notifying the client.

-

There are three principal modes of operation: client/server, symmetric active/passive and broadcast. In addition, there are two modes using IP multicast support: multicast and manycast. These modes are selected based on the scope of service, intended flow of time and proventic values and means of configuration. Following is a summary of the operations in each mode.

-

Client/Server Mode

-

Client/server mode is probably the most common configuration in the Internet today. It operates in the classic remote-procedure-call (RPC) paradigm with stateless servers. In this mode a client sends a request to the server and expects a reply at some future time. In some contexts this would be described as a "pull" operation, in that the client pulls the time and proventic values from the server. A client is configured in client mode using the server (sic) command and specifying the server IPv4 or IPv6 DNS name or address; the server requires no prior configuration. The original NTPv3 authentication scheme is applicable in this mode, as well as the new NTPv4 Autokey proventication scheme. In addition, two burst modes described below can be used in appropriate cases.

-

Symmetric Active/Passive Mode

-

Symmetric active/passive mode is intended for configurations were a clique of low-stratum peers operate as mutual backups for each other. Each peer operates with one or more primary reference sources, such as a radio clock, or a subset of secondary servers known to be reliable and proventicated. Should one of the peers lose all reference sources or simply cease operation, the other peers will automatically reconfigure so that time and proventication values can flow from the surviving peers to all the others in the clique. In some contexts this would be described as a "push-pull" operation, in that the peer either pulls or pushes the time and proventic values depending on the particular configuration.

-

Symmetric peers operate with their sources in some NTP mode and with each other in symmetric mode. A peer is configured in symmetric active mode using the peer command and specifying the other peer IPv4 or IPv6 DNS name or address. The other peer can also be configured in symmetric active mode in a similar way. However, if the other peer is not specifically configured in this way, a symmetric passive association is mobilized upon arrival of a symmetric active message. Since an intruder can impersonate a symmetric active peer and inject false time values, symmetric mode should always be cryptographically validated. The original NTPv3 authentication scheme is applicable in this mode, as well as the new NTPv4 Autokey proventication scheme.

-

Broadcast/Multicast Modes

-

IPv4 broadcast mode in both NTPv3 and NTPv4 is limited to directly connected subnets such as Ethernets which support broadcast technology. Ordinarily, this technology does not operate beyond the first hop router or gateway. In IPv6 and where service is intended beyond the local subnet, IP multicasting can be used where supported by the operating system and the routers support the Internet Group Management Protocol (IGMP). Most current kernels and available routers do support IP multicast technology, although service providers are sometimes reluctant to deploy it.

-

IPv4 broadcast mode is intended for configurations involving one or a few servers and a possibly very large client population on the same subnet. A broadcast server is configured using the broadcast command and a IPv4 local subnet broadcast address. A broadcast client is configured using the broadcastclient command, in which case it responds to broadcast messages received on any interface. Since an intruder can impersonate a broadcast server and inject false time values, this mode should always be cryptographically validated. The original NTPv3 authentication scheme is applicable in this mode, as well as the new NTPv4 Autokey proventication scheme.

-

The server generates broadcast messages continuously at intervals specified by the minpoll keyword and with a time-to-live span specified by the ttl keyword. A broadcast client responds to the first message received by waiting a short interval to avoid implosion at the server. Then, the client polls the server in burst mode in order to quickly set the host clock and validate the source. This normally results in a volley of eight client/server cycles at 2-s intervals during which both the synchronization and cryptographic protocols run concurrently. Following the volley, the client computes the offset between the apparent broadcast time and the (unicast) client time. This offset is used to compensate for the propagation time between the broadcast server and client. Once the offset is computed, the server continues as before and the client sends no further messages. If for some reason the broadcast server does not respond to client messages, the client will time out the volley and continue in listen-only mode with a default propagation delay.

-

Multicasting

-

Multicasting can be used to extend the scope of a timekeeping subnet in two ways: multicasting and manycasting. A general discussion of IP multicast technology is beyond the scope of this page. In simple terms a host or router sending to a IPv4 or IPv6 multicast group address expects all hosts or routers listening on this address to receive the message. There is no intrinsic limit on the number of senders or receivers and senders can be receivers and vice versa. The IANA has assigned multicast group address IPv4 224.0.1.1 and IPv6 FF05::101 (site local) to NTP, but these addresses should be used only where the multicast span can be reliably constrained to protect neighbor networks. In general, administratively scoped IPv4 group addresses should be used, as described in RFC-2365, or GLOP group addresses, as described in RFC-2770.

-

A multicast server is configured using the broadcast command, but with a multicast group address instead of a broadcast address. A multicast client is configured using the multicastclient command with a multicast group address. However, there is a subtle difference between IPv4 broadcasting and multicasting. IPv4 broadcasting is specific to each interface and local subnet address. If more than one interface is attached to a machine, a separate broadcast command applies to each one separately. This provides a way to limit exposure in a firewall, for example. For IPv6 the same distinction can be made using link-local prefix FF02 for each interface and site-local FF05 for all interfacesl.

-

IP multicasting is a different paradigm. By design, multicast messages travel from the sender via a shortest-path or shared tree to the receivers, which may require these messages emit from one or all interfaces, but carry a common source address. However, it is possible to configure multiple multicast group addresses using multiple broadcast or multicastclient commands. Other than these particulars, multicast messages are processed just like broadcast messages. Note that the calibration feature in broadcast mode is extremely important, since IP multicast messages can travel far different paths through the IP routing fabric than ordinary IP unicast messages.

-

Manycasting

-

Manycasting is a automatic discovery and configuration paradigm new to NTPv4. It is intended as a means for a multicast client to troll the nearby network neighborhood to find cooperating manycast servers, validate them using cryptographic means and evaluate their time values with respect to other servers that might be lurking in the vicinity. The intended result is that each manycast client mobilizes client associations with some number of the "best" of the nearby anycast servers, yet automatically reconfigures to sustain this number of servers should one or another fail. Additional information is on the Automatic NTP Configuration Options page.

-

Burst Modes

-

There are two burst modes where a single poll event triggers a burst of eight packets at 2-s intervals instead of the usual one. The burst mode sends a burst when the server is reachable, while the iburst mode sends a burst when the server is unreachable. Each mode is independently of the other and both can be used if necessary. The calldelay command can be used to increase the interval between the first and second packets in the burst in order to allow a modem to complete a call. Received server packets update the clock filter, which selects the best (most accurate) time values. When the last packet in the burst is sent, the next received packet updates the system variables and sets the system clock in the usual manner, as if only a single client/server cycle had occurred. The result is not only a rapid and reliable setting of the system clock, but a considerable reduction in network jitter.

-

The iburst keyword is used where it is important to set the clock quickly when an association is first mobilized or first becomes reachable or when the network attachment requires an initial calling or training procedure. The burst is initiated only when the server first becomes reachable and results in good accuracy with intermittent connections typical of PPP and ISDN services. Outlyers due to initial dial-up delays, etc., are avoided and the client sets the clock within a few seconds after the first message.

-

The burst keyword can be configured in cases of excessive network jitter or when the network attachment requires an initial calling or training procedure. The burst is initiated at each poll interval when the server is reachable. The burst does produce additional network overhead and can cause trouble if used indiscriminately. It should only be used where the poll interval is expected to settle to values at or above 1024 s.

-
- - - - \ No newline at end of file diff -urN src/contrib/ntp/html/audio.html src.ntp/contrib/ntp/html/audio.html --- src/contrib/ntp/html/audio.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/audio.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,148 +0,0 @@ - - - - - - - - Reference Clock Audio Drivers - - - - -

Reference Clock Audio Drivers

- jpgICOM R-72 shortwave receiver and Sure audio mixer -

Last update: 18:36 UTC Thursday, July 28, 2005

-
-

Related Links

- -

Table of Contents

- -
-

Sound Card Drivers

-

There are some applications in which the computer time can be disciplined to an audio signal, rather than a serial timecode and communications port or special purpose bus peripheral. This is useful in such cases where the audio signal is sent over a telephone circuit, for example, or received directly from a shortwave receiver. In such cases the audio signal can be connected via an ordinary sound card or baseboard audio codec. The suite of NTP reference clock drivers currently includes three drivers suitable for these applications. They include a driver for the Inter Range Instrumentation Group (IRIG) signals produced by many radio clocks and timing devices, another for the Canadian time/frequency radio station CHU and a third for the NIST time/frequency radio stations WWV and WWVH. The radio drivers are designed to work with ordinary inexpensive shortwave radios and may be one of the least expensive ways to build a good primary time server.

-

All three drivers make ample use of sophisticated digital signal processing algorithms designed to efficiently extract timing signals from noise and interference. The radio station drivers in particular implement optimum linear demodulation and decoding techniques, including maximum likelihood and soft-decision methods. The documentation page for each driver contains an in-depth discussion on the algorithms and performance expectations. In some cases the algorithms are further analyzed, modelled and evaluated in a technical report.

-

Currently, the audio drivers work with with Sun operating systems and audio codecs, including SunOS 4.1.3 and Solaris from 2.6 and probably all others in between. They also work with FreeBSD from 4.1 with compatible sound card. In fact, the interface is quite generic and support for other systems, in particular the various Unix generics, should not be difficult. Volunteers are solicited.

-

The audio drivers include a number of common features designed to groom input signals, suppress spikes and normalize signal levels. An automatic gain control (AGC) feature provides protection against overdriven or underdriven input signals. It is designed to maintain adequate demodulator signal amplitude while avoiding occasional noise spikes. In order to assure reliable operation, the signal level must be in the range where the audio gain control is effective. In general, this means the input signal level must be such as to cause the AGC to set the gain somewhere in the middle of the range from 0 to 255, as indicated in the timecode displayed by the ntpq program.

-

The drivers operate by disciplining a logical clock based on the codec sample clock to the audio signal as received. This is done by stuffing or slipping samples as required to maintain exact frequency to the order of 0.1 PPM. In order for the driver to reliably lock on the audio signal, the sample clock frequency tolerance must be less than 250 PPM (.025 percent) for the IRIG driver and half that for the radio drivers. The largest error observed so far is about 60 PPM, but it is possible some sound cards or codecs may exceed that value.

-

The drivers include provisions to select the input port and to monitor the input signal. The fudge flag 2 selects the microphone port if set to zero or the line-in port if set to one. It does not seem useful to specify the compact disc player port. The fudge flag 3 enables the input signal monitor using the previously selected output port and output gain. Both of these flags can be set in the configuration file or remotely using the ntpdc utility program.

-

Shortwave Radio Drivers

-

The WWV/H and CHU audio drivers require an external shortwave radio with the radio output - speaker or headphone jack - connected to either the microphone or line-in port on the computer. There is some degree of art in setting up the radio and antenna and getting the setup to work. While the drivers are highly sophisticated and efficient in extracting timing signals from noise and interference, it always helps to have as clear a signal as possible.

-

The most important factor affecting the radio signal is the antenna. It need not be long - even 15 feet is enough if it is located outside of a metal frame building, preferably on the roof, and away from metallic objects. An ordinary CB whip mounted on a PVC pipe and wooden X-frame on the roof should work well with most portable radios, as they are optimized for small antennas.

-

The radio need not be located near the computer; in fact, it generally works better if the radio is outside the near field of computers and other electromagnetic noisemakers. It can be in the elevator penthouse connected by house wiring, which can also be used to power the radio. A couple of center-tapped audio transformers will minimize noise pickup and provide phantom power to the radio with return via the building ground.

-

The WWV/H and CHU transmitters operate on several frequencies simultaneously, so that in most parts of North America at least one frequency supports propagation to the receiver location at any given hour. While both drivers support the ICOM CI-V radio interface and can tune the radio automatically, computer-tunable radios are expensive and probably not cost effective compared to a GPS receiver. So, the radio frequency must usually be fixed and chosen by compromise.

-

Shortwave (3-30 MHz) radio propagation phenomena are well known to shortwave enthusiasts. The phenomena generally obey the following rules:

-
    -
  • The optimum frequency is higher in daytime than nighttime, stays high longer on summer days and low longer on winter nights. -
  • Transitions between daytime and nightime conditions generally occur somewhat after sunrise and sunset at the midpoint of the path from transmitter to receiver. -
  • Ambient noise (static) on the lower frequencies follows the thunderstorm season, so is higher on summer afternoons and evenings. -
  • The lower frequency bands are best for shorter distances, while the higher bands are best for longer distances. -
  • The optimum frequencies are higher at the peak of the 11-year sunspot cycle and lower at the trough. The current sunspot cycle should peak in the first couple of years beginning the century. -
-

The best way to choose a frequency is to listen at various times over the day and determine the best highest (daytime) and lowest (nighttime) frequencies. Then, assuming one is available, choose the highest frequency between these frequencies. This strategy assumes that the high frequency is more problematic than the low, that the low frequency probably comes with severe multipath and static, and insures that probably twice a day the chosen frequency will work. For instance, on the east coast the best compromise CHU frequency is probably 7335 kHz and the best WWV frequency is probably 15 MHz.

-

Autotune Modes

-

The shortwave drivers include support for an optional autotune function compatible with ICOM receivers and transceivers. The mode keyword of the server configuration command specifies the ICOM ID select code in decimal. A missing or zero argument disables the CI-V interface. Since all ICOM select codes are less than 128, the high order bit of the code is used by the driver to specify the baud rate. If this bit is not set, the rate is 9600 bps for the newer radios; if set, the rate is 1200 bps for the older radios. Following are the ID select codes for the known radios.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
RadioHexDecimalRadioHexDecimal
7060x4e787750x4670
706MKIIG0x58887810x2638
7250x28409700x2e46
7260x3048R710x1A26
7350x044R720x3250
7460x66102R750x5a90
7510x1c28R70000x088
756PROII0x64100R71000x3452
7610x1e30R85000x4a74
7650x2c44R90000x2a42
-

Setup and Debugging Aids

-

The audio drivers include extensive setup and debugging support to help hook up the audio signals and monitor the driver operations. The documentation page for each driver describes the various messages that can be produced either in real time or written to the clockstats file for later analysis. Of particular help in verifying signal connections and compatibility is a provision to monitor the signal via headphones or speaker.

-

Connecting radios and IRIG devices to the computer and verifying correct configuration is somewhat of a black art. The signals have to be connected to the correct ports and the signal level maintained within tolerances. Some radios have recorder outputs which produce a line level signal not affected by the volume control. These signals can be connected to the line-in port on the computer. If the level is too low, connect to the microphone-in port instead. If the radio does not have a recorder output, connect the headphone or speaker output to the line-in port and adjust the volume control so the driver indicates comfortably above the minimum specified and the AGC level somewhere in the middle of the range 0-255. IRIG signals are usually much larger than radio outputs, usually in the range to several volts and may even overload the line-in port. In such cases an attenuator must be used to reduce the signal level below the overload point.

-

It is very easy to underdrive or overdrive the audio codec, in which case the drivers will not synchronize to the signal. The drivers use fudge flag2 to enable audio monitoring of the input signal. This is useful during setup to confirm the signal is actually reaching the audio codec and generally free of hum and interference. This feature is not intended for regular use, since it does increase the processor load on the system. Note that the speaker volume must be set before the driver is started.

-

The drivers write a synthesized timecode to the clockstats file each time the clock is set or verified and at other times if verbose monitoring is enabled. The format includes several fixed-length fields defining the UTC time to the millisecond, together with additional variable-length fields specific to each driver. The data include the intervals since the clock was last set or verified, the audio gain and various state variables and counters specific to each driver.

-
- - - - \ No newline at end of file diff -urN src/contrib/ntp/html/authopt.html src.ntp/contrib/ntp/html/authopt.html --- src/contrib/ntp/html/authopt.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/authopt.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,155 +0,0 @@ - - - - - - - - Authentication Options - - - - -

Authentication Options

- giffrom Alice's Adventures in Wonderland, Lewis Carroll -

Our resident cryptographer; now you see him, now you don't.

-

Last update: 01:29 UTC Wednesday, September 13, 2006

-
-

Related Links

- -

Table of Contents

- -
-

Authentication Support

-

Authentication support allows the NTP client to verify that the server is in fact known and trusted and not an intruder intending accidentally or on purpose to masquerade as that server. The NTPv3 specification RFC-1305 defines a scheme which provides cryptographic authentication of received NTP packets. Originally, this was done using the Data Encryption Standard (DES) algorithm operating in Cipher Block Chaining (CBC) mode, commonly called DES-CBC. Subsequently, this was replaced by the RSA Message Digest 5 (MD5) algorithm using a private key, commonly called keyed-MD5. Either algorithm computes a message digest, or one-way hash, which can be used to verify the server has the correct private key and key identifier.

-

NTPv4 retains the NTPv3 scheme, properly described as symmetric key cryptography, and, in addition, provides a new Autokey scheme based on public key cryptography. Public key cryptography is generally considered more secure than symmetric key cryptography, since the security is based on a private value which is generated by each host and never revealed. With the exception of the group key described later, all key distribution and management functions involve only public values, which considerably simplifies key distribution and storage. Public key management is based on X.509 certificates, which can be provided by commercial services or produced by utility programs in the OpenSSL software library or the NTPv4 distribution.

-

While the algorithms for symmetric key cryptography are included in the NTPv4 distribution, public key cryptography requires the OpenSSL software library to be installed before building the NTP distribution. This library is available from http://www.openssl.org and can be installed using the procedures outlined in the Building and Installing the Distribution page. Once installed, the configure and build process automatically detects the library and links the library routines required.

-

Authentication is configured separately for each association using the key or autokey subcommand on the peer, server, broadcast and manycastclient configuration commands as described in the Configuration Options page. The authentication options described below specify the locations of the key files, if other than default, which symmetric keys are trusted and the interval between various operations, if other than default.

-

Authentication is always enabled, although ineffective if not configured as described below. If a NTP packet arrives including a message authentication code (MAC), it is accepted only if it passes all cryptographic checks. The checks require correct key ID, key value and message digest. If the packet has been modified in any way or replayed by an intruder, it will fail one or more of these checks and be discarded. Furthermore, the Autokey scheme requires a preliminary protocol exchange to obtain the server certificate, verify its credentials and initialize the protocol

-

The auth flag controls whether new associations or remote configuration commands require cryptographic authentication. This flag can be set or reset by the enable and disable commands and also by remote configuration commands sent by a ntpdc program running on another machine. If this flag is enabled, which is the default case, new broadcast/manycast client and symmetric passive associations and remote configuration commands must be cryptographically authenticated using either symmetric key or public key cryptography. If this flag is disabled, these operations are effective even if not cryptographic authenticated. It should be understood that operating with the auth flag disabled invites a significant vulnerability where a rogue hacker can masquerade as a truechimer and seriously disrupt system timekeeping. It is important to note that this flag has no purpose other than to allow or disallow a new association in response to new broadcast and symmetric active messages and remote configuration commands and, in particular, the flag has no effect on the authentication process itself.

-

The security model and protocol schemes for both symmetric key and public key cryptography are summarized below; further details are in the briefings, papers and reports at the NTP project page linked from www.ntp.org.

-

Symmetric Key Cryptography

- - The original RFC-1305 specification allows any one of possibly 65,534 keys, each distinguished by a 32-bit key identifier, to authenticate an association. The servers and clients involved must agree on the key and key identifier to authenticate NTP packets. Keys and related information are specified in a key file, usually called ntp.keys, which must be distributed and stored using secure means beyond the scope of the NTP protocol itself. Besides the keys used for ordinary NTP associations, additional keys can be used as passwords for the ntpq and ntpdc utility programs. Ordinarily, the ntp.keys file is generated by the ntp-keygen program. -

When ntpd is first started, it reads the key file specified in the keys configuration command and installs the keys in the key cache. However, individual keys must be activated with the trustedkey command before use. This allows, for instance, the installation of possibly several batches of keys and then activating or deactivating each batch remotely using ntpdc. This also provides a revocation capability that can be used if a key becomes compromised. The requestkey command selects the key used as the password for the ntpdc utility, while the controlkey command selects the key used as the password for the ntpq utility.

-

Public Key Cryptography

-

NTPv4 supports the original NTPv3 symmetric key scheme described in RFC-1305 and in addition the Autokey protocol, which is based on public key cryptography. The Autokey Version 2 protocol described on the Autokey Protocol page verifies packet integrity using MD5 message digests and verifies the source with digital signatures and any of several digest/signature schemes. Optional identity schemes described on the Identity Schemes page and based on cryptographic challenge/response algorithms are also available. Using these schemes provides strong security against replay with or without modification, spoofing, masquerade and most forms of clogging attacks.

-

The Autokey protocol has several modes of operation corresponding to the various NTP modes supported. Most modes use a special cookie which can be computed independently by the client and server, but encrypted in transmission. All modes use in addition a variant of the S-KEY scheme, in which a pseudo-random key list is generated and used in reverse order. These schemes are described along with an executive summary, current status, briefing slides and reading list on the Autonomous Authentication page.

-

The specific cryptographic environment used by Autokey servers and clients is determined by a set of files and soft links generated by the ntp-keygen program. This includes a required host key file, required host certificate file and optional sign key file, leapsecond file and identity scheme files. The digest/signature scheme is specified in the X.509 certificate along with the matching sign key. There are several schemes available in the OpenSSL software library, each identified by a specific string such as md5WithRSAEncryption, which stands for the MD5 message digest with RSA encryption scheme. The current NTP distribution supports all the schemes in the OpenSSL library, including those based on RSA and DSA digital signatures.

-

NTP secure groups can be used to define cryptographic compartments and security hierarchies. It is important that every host in the group be able to construct a certificate trail to one or more trusted hosts in the same group. Each group host runs the Autokey protocol to obtain the certificates for all hosts along the trail to one or more trusted hosts. This requires the configuration file in all hosts to be engineered so that, even under anticipated failure conditions, the NTP subnet will form such that every group host can find a trail to at least one trusted host.

-

Naming and Addressing

-

It is important to note that Autokey does not use DNS to resolve addresses, since DNS can't be completely trusted until the name servers have synchronized clocks. The cryptographic name used by Autokey to bind the host identity credentials and cryptographic values must be independent of interface, network and any other naming convention. The name appears in the host certificate in either or both the subject and issuer fields, so protection against DNS compromise is essential.

-

By convention, the name of an Autokey host is the name returned by the Unix gethostname() system call or equivalent in other systems. By the system design model, there are no provisions to allow alternate names or aliases. However, this is not to say that DNS aliases, different names for each interface, etc., are constrained in any way.

-

It is also important to note that Autokey verifies authenticity using the host name, network address and public keys, all of which are bound together by the protocol specifically to deflect masquerade attacks. For this reason Autokey includes the source and destinatino IP addresses in message digest computations and so the same addresses must be available at both the server and client. For this reason operation with network address translation schemes is not possible. This reflects the intended robust security model where government and corporate NTP servers are operated outside firewall perimeters.

-

Configuration

-

Autokey has an intimidating number of options, most of which are not necessary in typical scenarios. The simplest configuration consists of a subnet with one or more servers at the same low stratum acting as trusted hosts and with dependent clients at higher strata and sharing a single secure group and identity scheme. Each trusted host generates a host key, trusted certificate and group key. Each client generates a host key, normal certificate and installs the group key of each trusted host using secure means and renames it as the name of the trusted host.

-

For example, trusted host Alice generates keys using

-

ntp-keygen -H -T -I -p xyz

-

where H specifies a new host key, T the trusted certificate, I the IFF identity scheme and p the password used to encrypt the private key files. The group key file is ntpkey_IFFpar_alice.filestamp, where filestamp represents the NTP time in seconds when the file was generated.

-

Host Bob generate keys using

-

ntp-keygen -H -p abc

-

where abc is different for each group host. The trusted host generates a password-protected group key using

-

ntp-keygen -q xyz -p abc -e >temp

-

where xyz is the trusted host password, abc is the password supplied by the client and temp is a temporary file. This file is transmitted to Bob using secure means and renamed to the fully qualified host name for Alice preceded by the string ntpkey_iff_.

-

Operation

-

A specific combination of authentication scheme (none, symmetric key, public key) and identity scheme is called a cryptotype, although not all combinations are compatible. There may be management configurations where the clients, servers and peers may not all support the same cryptotypes. A secure NTPv4 subnet can be configured in many ways while keeping in mind the principles explained above and in this section. Note however that some cryptotype combinations may successfully interoperate with each other, but may not represent good security practice.

-

The cryptotype of an association is determined at the time of mobilization, either at configuration time or some time later when a message of appropriate cryptotype arrives. When mobilized by a server or peer configuration command and no key or autokey subcommands are present, the association is not authenticated; if the key subcommand is present, the association is authenticated using the symmetric key ID specified; if the autokey subcommand is present, the association is authenticated using Autokey.

-

Key Management

-

The cryptographic values used by the Autokey protocol are incorporated as a set of files generated by the ntp-keygen utility program, including symmetric key, host key and public certificate files, as well as sign key, identity parameters and leapseconds files. Alternatively, host and sign keys and certificate files can be generated by the OpenSSL utilities and certificates can be imported from public certificate authorities. Note that symmetric keys are necessary for the ntpq and ntpdc utility programs. The remaining files are necessary only for the Autokey protocol.

-

Certificates imported from OpenSSL or public certificate authorities have certian limitations. The certificate should be in ASN.1 syntax, X.509 Version 3 format and encoded in PEM, which is the same format used by OpenSSL. The overall length of the certificate encoded in ASN.1 must not exceed 1024 bytes. The subject distinguished name field (CN) is the fully qualified name of the host on which it is used; the remaining subject fields are ignored. The certificate extension fields must not contain either a subject key identifier or a issuer key identifier field; however, an extended key usage field for a trusted host must contain the value trustRoot;. Other extension fields are ignored.

-

Authentication Commands

-
-
autokey [logsec] -
Specifies the interval between regenerations of the session key list used with the Autokey protocol. Note that the size of the key list for each association depends on this interval and the current poll interval. The default value is 12 (4096 s or about 1.1 hours). For poll intervals above the specified interval, a session key list with a single entry will be regenerated for every message sent. -
controlkey key -
Specifies the key identifier to use with the ntpq utility, which uses the standard protocol defined in RFC-1305. The key argument is the key identifier for a trusted key, where the value can be in the range 1 to 65,534, inclusive. -
crypto [cert file] [leap file] [randfile file] [host file] [sign file] [ident scheme] [iffpar file] [gqpar file] [mvpar file] [pw password] -
This command requires the OpenSSL library. It activates public key cryptography, selects the message digest and signature encryption scheme and loads the required private and public values described above. If one or more files are left unspecified, the default names are used as described above. Unless the complete path and name of the file are specified, the location of a file is relative to the keys directory specified in the keysdir command or default /usr/local/etc. Following are the subcommands: -
-
cert file -
Specifies the location of the required host public certificate file. This overrides the link ntpkey_cert_hostname in the keys directory. - -
gqpar file -
Specifies the location of the client GQ parameters file. This overrides the link ntpkey_gq_hostname in the keys directory. - -
host file -
Specifies the location of the required host key file. This overrides the link ntpkey_key_hostname in the keys directory. -
ident scheme -
Requests the server identity scheme, which can be IFF, GQ or MV. This is used when the host will not be a server for a dependent client.
iffpar file -
Specifies the location of the optional IFF parameters file.This overrides the link ntpkey_iff_hostname in the keys directory. -
leap file -
Specifies the location of the client leapsecond file. This overrides the link ntpkey_leap in the keys directory. -
mv -
Requests the MV server identity scheme. -
mvpar file -
Specifies the location of the client MV parameters file. This overrides the link ntpkey_mv_hostname in the keys directory. -
pw password -
Specifies the password to decrypt files containing private keys and identity parameters. This is required only if these files have been encrypted. -
randfile file -
Specifies the location of the random seed file used by the OpenSSL library. The defaults are described in the main text above. -
sign file -
Specifies the location of the optional sign key file. This overrides the link ntpkey_sign_hostname in the keys directory. If this file is not found, the host key is also the sign key. -
-
keys keyfile -
Specifies the complete path and location of the MD5 key file containing the keys and key identifiers used by ntpd, ntpq and ntpdc when operating with symmetric key cryptography. This is the same operation as the -k command line option. -
keysdir path -
This command specifies the default directory path for cryptographic keys, parameters and certificates. The default is /usr/local/etc/. -
requestkey key -
Specifies the key identifier to use with the ntpdc utility program, which uses a proprietary protocol specific to this implementation of ntpd. The key argument is a key identifier for the trusted key, where the value can be in the range 1 to 65,534, inclusive. -
revoke [logsec] -
Specifies the interval between re-randomization of certain cryptographic values used by the Autokey scheme, as a power of 2 in seconds. These values need to be updated frequently in order to deflect brute-force attacks on the algorithms of the scheme; however, updating some values is a relatively expensive operation. The default interval is 16 (65,536 s or about 18 hours). For poll intervals above the specified interval, the values will be updated for every message sent. -
trustedkey key [...] -
Specifies the key identifiers which are trusted for the purposes of authenticating peers with symmetric key cryptography, as well as keys used by the ntpq and ntpdc programs. The authentication procedures require that both the local and remote servers share the same key and key identifier for this purpose, although different keys can be used with different servers. The key arguments are 32-bit unsigned integers with values from 1 to 65,534. -
-

Error Codes

-

Errors can occur due to mismatched configurations, unexpected restarts, expired certificates and unfriendly people. In most cases the protocol state machine recovers automatically by retransmission, timeout and restart, where necessary. Some errors are due to mismatched keys, digest schemes or identity schemes and must be corrected by installing the correct media and/or correcting the configuration file. One of the most common errors is expired certificates, which must be regenerated and signed at least once per year using the ntp-keygen program.

-

The following error codes are reported via the NTP control and monitoring protocol trap mechanism.

-
-
101 (bad field format or length) -
The packet has invalid version, length or format. -
102 (bad timestamp) -
The packet timestamp is the same or older than the most recent received. This could be due to a replay or a server clock time step. -
103 (bad filestamp) -
The packet filestamp is the same or older than the most recent received. This could be due to a replay or a key file generation error. -
104 (bad or missing public key) -
The public key is missing, has incorrect format or is an unsupported type. -
105 (unsupported digest type) -
The server requires an unsupported digest/signature scheme. -
106 (unsupported identity type)
The client or server has requested an identity scheme the other does not support.
107 (bad signature length) -
The signature length does not match the current public key. -
108 (signature not verified) -
The message fails the signature check. It could be bogus or signed by a different private key. -
109 (certificate not verified) -
The certificate is invalid or signed with the wrong key.
110 (host certificate expired)
The old server certificate has expired.
111 (bad or missing cookie) -
The cookie is missing, corrupted or bogus. -
112 (bad or missing leapseconds table) -
The leapseconds table is missing, corrupted or bogus. -
113 (bad or missing certificate) -
The certificate is missing, corrupted or bogus. -
114 (bad or missing group key)
The identity key is missing, corrupt or bogus. - -
115 (protocol error) -
The protocol state machine has wedged due to unexpected restart -
116 (server certificate expired) -
The old server certificate has expired. -
-

Files

-

See the ntp-keygen page.

-

Leapseconds Table

-

The NIST provides a file documenting the epoch for all historic occasions of leap second insertion since 1972. The leapsecond table shows each epoch of insertion along with the offset of International Atomic Time (TAI) with respect to Coordinated Universal Time (UTC), as disseminated by NTP. The table can be obtained directly from NIST national time servers using ftp as the ASCII file pub/leap-seconds.

-

While not strictly a security function, the Autokey protocol provides means to securely retrieve the leapsecond table from a server or peer. Servers load the leapsecond table directly from the file specified in the crypto command, with default ntpkey_leap, while clients can obtain the table indirectly from the servers using the Autokey protocol. Once loaded, the table can be provided on request to other clients and servers.

-
- - - - \ No newline at end of file diff -urN src/contrib/ntp/html/build/build.html src.ntp/contrib/ntp/html/build/build.html --- src/contrib/ntp/html/build/build.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/build.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,83 +0,0 @@ - - - - - - - Building and Installing the Distribution - - - - -

Building and Installing the Distribution

- giffrom Pogo, Walt Kelly -

For putting out compiler fires.

-

Last update: 03:06 AM UTC Monday, October 13, 2003

-
-

Related Links

- -

Table of Contents

- -
-

Building and Installing the Distribution

-

As a practical matter, every computer architecture and operating system version seems to be different than any other. The device drivers may be different, the input/output system may be idiosyncratic and the libraries may have different semantics. It is not possible in a software distribution such as this one to support every individual system with a common set of binaries, even with the same system but different versions. Therefore, it is necessary to individually configure the software build for each system and version, both at compile time and at run time. In almost all cases, these procedures are completely automatic and all the newbie user need do is type "configure", "make" and "install" in that order and the autoconfigure system does the rest. There are some exceptions, as noted below and on the Hints and Kinks page.

-

If available, the OpenSSL library from http://www.openssl.org is used to support public key cryptography. The library must be built and installed prior to building NTPv4. The procedures for doing that are included in the OpenSSL documentation. The library is found during the normal NTPv4 configure phase and the interface routines compiled automatically. Only the libcrypto.a library and associated header files are used. If the library is not available or disabled, this step is not required.

-

Building and Installing under Unix

-

Make sure that you have all necessary tools for building executables. These tools include cc/gcc, make, awk, sed, tr, sh, grep, egrep and a few others. Not all of these tools exist in the standard distribution of modern Unix versions (compilers are likely to be an add-on product). If this is the case, consider using the GNU tools and gcc compiler. For a successful build, all of these tools should be accessible via the current path.

-

The first thing to do is uncompress the distribution and extract the source tree. In the distribution base directory use the ./configure command to perform an automatic configuration procedure. This command inspects the hardware and software environment and tests for the presence of system header files and the contents of these files to determine if certain features are present. When one or more of these features are present, the code is compiled to use them; if not, no special code is compiled. However, even if the code is compiled to use these features, the code does a special test at run time to see if one or more are actually present and avoids using them if not present. In such cases a warning message is sent to the system log, but the daemon should still work properly.

-

The default build normally includes the debugging code, which can be useful in diagnosing problems found in initial test, and all reference clock drivers known to work with each machine and operating system. Unless memory space is at a premium, this is a sensible strategy and greatly simplifies debugging and support. If you need to delete either the debugging code or one or all reference clock drivers to save space, see the Configuration Options page.

-

If your site supports multiple architectures and uses NFS to share files, you can use a single source tree to compile executables for all architectures. While running on a target architecture machine and in the distribution base directory create a subdirectory using a command like mkdir A.`config.guess`, which will create an architecture-specific directory with name peculiar to the architecture and operating system. Then change to this directory and emit a ../configure command. The remaining steps are the same whether building in the base directory or in the subdirectory.

-

Compilation

-

Use the make command to compile all source modules, construct the libraries and link the distribution. Expect few or no warnings using cc and a moderate level of warnings using gcc. Note: On some Unix platforms gcc may show quite a few complaints about system header files and type inconsistencies, especially with pointer variables. This is usually the case when the system header files are not up to ANSI standards or gcc expectations, when gcc is not installed properly, or when operating system updates and patches are applied and gcc is not reinstalled. While the autoconfigure process is quite thorough, the Unix programming cultures of the various workstation makers still remain idiosyncratic.

-

Installation

-

As root, use the make install command to install the binaries in the destination directory. Most commonly, these programs are installed in /usr/local/bin, but this can be overridden during configuration. You must of course have write permission on the install in the destination directory. This includes the following programs:

- -

If the precision time kernel modifications are present, the following program is installed:

- -

If the public key authentication functions are present, the following program is installed:

- -

In some systems that include the capability to edit kernel variables, the following program is installed:

- -

Cryptographic support, both symmetric and public key, requires one or more key files, commonly installed in /usr/local/etc. Public key cryptography requires a random seed file, usually called .rnd, installed in a dark place such as the root directory or /etc. Directions for generating keys is on the Authentication Options page.

-

Configuration

-

You are now ready to configure the daemon and start it. You will need to create a NTP configuration file ntp.conf and a cryptographic key file ntp.keys. The latter file is necessary only for remote configuration support, if needed. Newbies should see the Quick Start page for orientation. Seasoned veterans can start with the ntpd - Network Time Protocol (NTP) daemon page and move on to the specific configuration option pages from there. A tutorial on NTP subnet design and configuration options is in the Notes on Configuring NTP and Setting up a NTP Subnet page.

-

If You Have Problems

-

If you have problems peculiar to the particular hardware and software environment (e.g. operating system-specific issues), browse the Hints and Kinks page. For other problems a tutorial on debugging technique is in the NTP Debugging Technique page. As always, the first line of general assistance is the NTP web site www.ntp.org and the FAQ resident there. Requests for assistance of a general nature and of interest to other timekeepers should be sent to the NTP newsgroup comp.protocols.time.ntp. Bug reports of a specific nature should be sent to bugs@ntp.org. Bug reports of a specific nature on features implemented by the programmer corps mentioned in the Copyright page should be sent directly to the implementor listed in that page, with copy to bugs@ntp.org.

-

Please include the version of the source distribution (e.g., ntp-4.0.70a) in your bug report, as well as billboards from the relevant utility programs and debug trace, if available. Please include the output of config.guess in your bug report. It will look something like:

-

pdp11-dec-fuzzos3.4

-

Additional make commands

-
-
make clean -
Cleans out object files, programs and temporary files. -
make distclean -
Does the work of clean, but cleans out all directories in preparation for a new distribution release. -
make dist -
Does the work of make distclean, but constructs compressed tar files for distribution. You must have GNU automake to perform this function. -
-

Building and Installing under Windows NT

-

See hints/winnt.htm for directions to compile the sources and install the executables.

-
- - - - \ No newline at end of file diff -urN src/contrib/ntp/html/build/config.html src.ntp/contrib/ntp/html/build/config.html --- src/contrib/ntp/html/build/config.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/config.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,168 +0,0 @@ - - - - - - - Configuration Options - - - - -

Configuration Options

- giffrom Pogo, Walt Kelly -

Gnu autoconfigure tools are in the backpack.

-

Last update: 12:56 AM UTC Saturday, March 20, 2004

-
-

Table of Contents

- -
-

Basic Configuration Options - the configure utility

-

The following options are for compiling and installing a working version of the NTP distribution. In most cases, the build process is completely automatic. In some cases where memory space is at a premium, or the binaries are to be installed in a different place, it is possible to tailor the configuration to remove such features as reference clock driver support, debugging support, and so forth.

-

Configuration options are specified as arguments to the configure script. Following is a summary of the current options, as of the 4.0.99m version:

-

Usage: configure [options] [host]
-

-

Options

-

[defaults in brackets after descriptions] Configuration:

-
- --cache-file=FILE      cache test results in FILE
- --help                 print this message
- --no-create            do not create output files
- --quiet, --silent      do not print `checking...' messages
- --version              print the version of autoconf that created
-configure
-
-

Directory and File Names

-
- --prefix=PREFIX        install architecture-independent files in PREFIX [/usr/local]
- --exec-prefix=EPREFIX  install architecture-dependent files in EPREFIX [same as prefix]
- --bindir=DIR           user executables in DIR [EPREFIX/bin]
- --sbindir=DIR          system admin executables in DIR [EPREFIX/sbin]
- --libexecdir=DIR       program executables in DIR [EPREFIX/libexec]
- --datadir=DIR          read-only architecture-independent data in DIR [PREFIX/share]
- --sysconfdir=DIR       read-only single-machine data in DIR [PREFIX/etc]
- --sharedstatedir=DIR   modifiable architecture-independent data in DIR [PREFIX/com]
- --localstatedir=DIR    modifiable single-machine data in DIR [PREFIX/var]
- --libdir=DIR           object code libraries in DIR [EPREFIX/lib]
- --includedir=DIR       C header files in DIR [PREFIX/include]
- --oldincludedir=DIR    C header files for non-gcc in DIR [/usr/include]
- --infodir=DIR          info documentation in DIR [PREFIX/info]
- --mandir=DIR           man documentation in DIR [PREFIX/man]
- --srcdir=DIR           find the sources in DIR [configure dir or ..]
- --x-includes=DIR       X include files are in DIR
- --x-libraries=DIR      X library files are in DIR
- --program-prefix=PREFIX           prepend PREFIX to installed program names
- --program-suffix=SUFFIX           append SUFFIX to installed program names
- --program-transform-name=PROGRAM  run sed PROGRAM on installed program names
-
-

Host Type

-
- --build=BUILD          configure for building on BUILD [BUILD=HOST]
- --host=HOST            configure for HOST [guessed]
- --target=TARGET        configure for TARGET [TARGET=HOST]
-
-

Optional Packages

-
- --with-PACKAGE[=ARG]   use PACKAGE [ARG=yes]
- --without-PACKAGE      do not use PACKAGE (same as --with-PACKAGE=no)
-
- openssl-libdir=DIR     OpenSSL object code libraries in DIR [/usr/lib/usr/local/lib/usr/local/ssl/lib]
- openssl-incdir=DIR     OpenSSL header files in DIR [/usr/include/usr/local/include/usr/local/ssl/include]
- crypto=autokey         Use autokey cryptography
- crypto=rsaref          Use the RSAREF library
- electricfence          Compile with ElectricFence malloc debugger
-
-

Optional Features

-
- --disable-FEATURE      do not include FEATURE (same as
- --enable-FEATURE=no)
- --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
-
- accurate-adjtime       The adjtime() call is accurate
- clockctl               use /dev/clockctl (non root control of system clock)
- debugging              Include debugging code [enable]
- des                    Include support for DES keys [enable]
- dst-minutes=VALUE      Minutes per DST adjustment [60]
- gdt-surveying          Include GDT survey code [disable]
- hourly-todr-sync       If we should sync TODR hourly
- kernel-fll-bug         If we should avoid a (Solaris) kernel FLL bug
- kmem                   Read /dev/kmem for 'tick' and/or 'tickadj'
- md5                    Include support for MD5 keys [enable]
- ntpdate-step           If ntpdate should step the time
- slew-always            Always slew the time
- step-slew              Step and slew the time
- tick=VALUE             Force a value for 'tick'
- tickadj=VALUE          Force a value for 'tickadj'
- udp-wildcard           Use UDP wildcard delivery
-
-

Radio Clocks

-

(these are ordinarily enabled, if supported by the machine and operating system):

-
- all-clocks             Include drivers for all suitable non-PARSE clocks [enable]
- ACTS                   NIST dialup clock
- ARBITER                Arbiter 1088A/B GPS receiver
- ARCRON_MSF             Arcron MSF receiver
- AS2201                 Austron 2200A or 2201A GPS receiver
- ATOM                   ATOM PPS interface
- AUDIO-CHU              CHU audio decoder
- BANCOMM                Datum/Bancomm BC635/VME interface (requires an explicit --enable-BANCOMM request)
- CHRONOLOG              Chrono-log K-series WWVB receiver
- CHU                    CHU modem decoder
- DATUM                  Datum Programmable Time System
- DUMBCLOCK              Dumb generic hh:mm:ss local clock
- FG                     Forum Graphic GPS
- GPSVME                 TrueTime GPS receiver with VME interface (requires an explicit --enable-GPSVME request)
- HEATH                  HeathKit GC-1000 Most Accurate Clock
- HOPFPCI                HOPF 6039 PCI board
- HOPFSERIAL             HOPF serial clock device
- HPGPS                  HP 58503A GPS Time & Frequency receiver
- IRIG                   IRIG (Audio) Clock
- JUPITER                Rockwell Jupiter GPS receiver
- LEITCH                 Leitch CSD 5300 Master Clock System Driver
- LOCAL-CLOCK            Local clock driver
- MSFEES                 EES M201 MSF receiver
- MX4200                 Magnavox MX4200 GPS receiver
- NMEA                   NMEA GPS receiver
- ONCORE                 Motorola VP/UT Oncore GPS receiver
- PALISADE               Palisade clock
- PCF                    Conrad parallel port radio clock
- PST                    PST/Traconex 1020 WWV/H receiver
- PTBACTS                PTB dialup clock support
- SHM                    Clock attached through shared memory (requires an explicit --enable-SHM request)
- SPECTRACOM             Spectracom 8170/Netclock/2 WWVB receiver
- TRAK                   TRAK 8810 GPS station clock
- TPRO                   KSI/Odetics TPRO/S IRIG Interface
- TRUETIME               Kinemetrics/TrueTime (generic) receiver
- ULINK                  Ultralink WWVB receiver
- USNO                   US Naval Observatory dialup clock
- WWV                    WWV audio receiver
-
-

PARSE Clocks

-
- parse-clocks           Include drivers for all suitable PARSE clocks [enable]
- COMPUTIME              Diem Computime Radio Clock
- DCF7000                ELV/DCF7000 Clock
- HOPF6021               HOPF 6021 Radio Clock support
- MEINBERG               Meinberg clocks
- RAWDCF                 DCF77 raw time code
- RCC8000                RCC 8000 Radio Clock support
- SCHMID                 SCHMID DCF77 clock support
- TRIMTAIP               Trimble GPS/TAIP Protocol
- TRIMTSIP               Trimble GPS/TSIP Protocol
- VARITEXT               VARITEXT clock
- WHARTON                Wharton 400A Series clock
-
-
- - - - \ No newline at end of file diff -urN src/contrib/ntp/html/build/hints/a-ux src.ntp/contrib/ntp/html/build/hints/a-ux --- src/contrib/ntp/html/build/hints/a-ux 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/a-ux 1970-01-01 01:00:00.000000000 +0100 @@ -1,195 +0,0 @@ -------------- -INTRODUCTION: -------------- -Last revision: 06-Jul-1994 - -Included in this distribution of XNTP V3 is a configuration file suitable -for use under Apple's A/UX Version 3.x.x There is also one for A/UX 2.0.1 -but it has not been fully tested. To make the executables follow the steps -outlined below. - -*** NOTE: You must have gcc installed to successfully compile the current -distribution; the native cc supplied with A/UX will NOT correctly compile -this source. See the FAQ in comp.unix.aux for places to obtain gcc from -and how to install it. - ----------------------- -MAKING XNTPD FOR A/UX: ----------------------- - -First, you need to create the makefiles (after you've downloaded the -source, of course): - - % make clean - % make refconf - -After that, you should edit Config.local to make sure that BINDIR is -correct for where you wish the programs to be "installed". The default -(and what I use) is /usr/local/etc. Make sure that DEFS_LOCAL and -CLOCKDEFS are commented out! Presently, only the LOCAL_CLOCK/REFCLOCK -clock is used and supported. - - -After this is done (you should be told that your system is A/UX 3), make -'xntpd' (the options to 'gcc' are held in compilers/aux3.gcc): - - % make - -I do not normally use the `make install' option and so have not verified its -compatibility with A/UX. Rather, I pull out each of the executables and -place them in the locally appropriate locations. - ---------------- -STARTING XNTPD: ---------------- - -At this point you need to set things up so that 'xntpd' is started upon -boot-up. You can do this in 1 of 2 ways: either add entries in /etc/inittab -or, more ideally, create and use an /etc/rc.local file. Since rc.local is -what I recommend, here's how you do it: - -By default, A/UX doesn't have rc.local, so you'll need to add the following to -/etc/inittab: - - net6:2:wait:/etc/syslogd # set to "wait" to run a syslog daemon -+ jmj0:2:wait:/etc/rc.local 1>/dev/syscon 2>&1 # Local stuff - dbg2::wait:/etc/telinit v # turn off init's verbose mode - -Now, the look of a sample /etc/rc.local is as follows: - - #!/bin/sh - : - : rc.local - : - # @(#)Copyright Apple Computer 1987 Version 1.17 of rc.sh on 91/11/08 15:56:21 (ATT 1.12) - - - # Push line discipline/set the device so it will print - /etc/line_sane 1 - echo " " - echo "Entering rc.local..." - - set `/bin/who -r` - if [ "$7" = 2 ] - then - /bin/echo " now setting the time..." - /usr/local/etc/ntpdate -s -b - sleep 5 - # - # start up 'xntpd' if we want - # - if [ -f /etc/ntp.conf ] - then - /bin/echo " setting tick and tickadj..." - /usr/local/etc/tickadj -t 16672 -a 54 - sleep 5 - /bin/echo " starting xntpd..." - /usr/local/etc/xntpd <&- > /dev/null 2>&1 - sleep 5 - fi - # - fi - - echo "Leaving rc.local..." - -There are a few things to notice about the above: - - o When run, 'ntpdate' forces your clock to the time returned by the - host(s) specified by (you'll need to replace this - be the IP address(es) of your timehosts. This is good since it gets - things close to start off with. You can use more than one time - server. - - o 'tickadj' is also called. This does two things: changes the - default value of 'tick' (which the the amount of time, in ms, that - is added to the clock every 1/60 seconds) and changes the value - of 'tickadj' which the the amount that is added or subtracted - from 'tickadj' when adjtime() is called. - - Now Mac clocks are pretty bad and tend to be slow. Sooo, instead of - having A/UX add the default of 16666ms every 1/60th of a second, you - may want it to add more (or less) so that it keeps better time. The - above value works for me but your "best" value may be different and - will likely require some fooling around to find the best value. As a - general rule of thumb, if you see 'xntpd' make a lot of negative clock - adjustments, then your clock is fast and you'll need to _decrease_ - the value of 'tick'. If your adjustments are positive, then you need - to increase 'tick'. To make a guess on how fast/slow your clock is, - use 'ntpdate' to sync your clock. Now watch 'xntpd' and see how it - operates. If, for example, it resets your clock by 1 second every 30 - minutes, then your clock is (1/(30*60)) is about 0.056% off and you'll - need to adjust 'tick' by 16666*0.00056 or about 9 (i.e. 'tick' should - be ~16675 if slow or ~16657 if fast) - - A/UX's default value of 'tickadj' is 1666 which is too big for - 'xntpd'... so it also needs to be adjusted. I like using larger - values then the recommended value of 9 for 'tickadj' (although not - anything near as big as 1666) since this allows for quick slews - when adjusting the clock. Even with semi-large values of 'tickadj' - (~200), getting 5ms (1/200 s) accuracy is easy. - - -Finally, before A/UX and 'xntpd' will work happily together, you need to -patch the kernel. This is due to the fact that A/UX attempts to keep the -UNIX-software clock and the Mac-hardware clock in sync. Neither the h/w or -the s/w clock are too accurate. Also, 'xntpd' will be attempting to adjust -the software clock as well, so having A/UX muck around with it is asking -for headaches. What you therefore need to do is tell the kernel _not_ to -sync the s/w clock with the h/w one. This is done using 'adb'. The -following is a shell script that will do the patch for you: - - #! /bin/sh - adb -w /unix < -Newsgroups: comp.protocols.time.ntp -to: mills@udel.edu -return-receipt-to: rocky@panix.com -Subject: time and AIX 3.2.5 raw tty bug - -This posting isn't strictly about NTP, any program that may stop the -clock or set the clock backwards is subject to the AIX 3.2.5 bug. - -On AIX 3.2.5, there is a bug in the tty driver for a raw device which -may crash the box under certain conditions: basically a read() on a -raw tty in effect, a character was read but not as many as specified -by VMIN when a read timeout occurred. VTIME specifies the timeout. See -the AIX manual page on termios.h or that include file. for Information -on VMIN (or MIN) VTIME (or TIME). - -A remedy other than to not use raw tty's is to apply patch U435110. - -Details of the problem report follow. - -> ABSTRACT: -> IX43779: TRAP IN PSX_TIMEO -> -> ORIGINATING DETAILS: -> Stacktrace shows: -> IAR: 01460214 posixdd:psx_timeo + 8bf4: ti 4,r12,0x0 -> *LR: 014601a0 posixdd:psx_timeo + 8b80 -> 00212c60: 014604f4 posixdd:psx_timer + 8ed4 -> 00212cc0: 0144b74c ttydd:tty_do_offlevel + 4284 -> 00212d20: 000216fc .i_offlevel + 8c -> 00212d70: 00021d78 .i_softint + c8 -> 00001004: 00008714 .finish_interrupt + 80 -> -> RESPONDER SUMMARY: -> AIX asserted in psx_timeo(). Reason for the assert was that -> the current time was behind psx_ctime. Since this state -> can occur when the current time is changed after a character -> is received but before the VTIME interbyte timer pops, we -> should not assert on this. -> -> RESPONDER CONCLUSION: -> Removed the requirement that current time > psx_ctime by -> adding a new L_ntimersub macro that is used instead of the -> ntimersub macro in time.h. Also added a test for (current -> time - psx_ctime) being negative, in that case we do not -> adjust the new timeout. -> -> Reported to Correct a PTF in Error: NO -> Reported as a Highly pervasive problem: NO -> -> PE Apar?: NoPE -> Hiper Apar?: NoHiper -> Status: CLOSED PER -> Component Name: AIX V3 FOR RS/6 -> Version: 320 -> Component ID: 575603001 -> Submitted: 94/05/03 -> Closed: 94/05/05 -> ChangeTeam: TX2527 -> -> APAR FIXED BY: U431696 U432151 U432844 U432870 U432979 -> U433049 U433081 U433459 U433876 U433906 U434598 U434453 -> U434672 U434737 U435110 - diff -urN src/contrib/ntp/html/build/hints/bsdi src.ntp/contrib/ntp/html/build/hints/bsdi --- src/contrib/ntp/html/build/hints/bsdi 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/bsdi 1970-01-01 01:00:00.000000000 +0100 @@ -1,65 +0,0 @@ -hints/bsdi - -Author: Bdale Garbee, bdale@gag.com -Last revision: 27Oct94 (Paul Vixie) - -Included in this distribution of XNTP is a configuration file suitable -for use with BSDI's BSD/OS 1.1 (formerly BSD/386 1.1). On this system, -the "cc" command is GCC 1.4x rather than PCC or GCC 2.x. It is imperative -that "cc" be used since it predefines the symbol __bsdi__; if you want to -use another compiler you will need to add -D__bsdi__ to catch the various -#ifdef's required for this system. - -The Kinemetrics/Truetime GPS-TM/TMD driver is known to work on this system. -The GPS-805 and GOES should also work fine. Hell, they should all work fine -but it's hard to test very many locally. - -Due to BNR2's strict interpretation of POSIX and XNTP's use of SIGIO, BSD/OS -can only handle one refclock per daemon. We're working this out with the -system architects. - -The config file is machine/bsdi, and the following steps should be all that -are required to install and use the bits. - -Note that you will need GNU sed; the version supplied with BSD/OS 1.1 loops -endlessly during "make refconf". Likewise you should get GNU make, which -the instructions below assume that you have put in /usr/local/bin/gnumake. - -To build the software: - - rm -f Config.local - gnumake refconf - gnumake MAKE=gnumake - -To install the software: - - gnumake install - - This will place all of the executables in /usr/local/etc. The config - file is expected to be /usr/local/etc/xntp.conf and the key file for - the optional authentication is /etc/ntp.keys. - - Craft a config file and a key file, and put them in the right places. - There is information on how to do this elsewhere in the documentation, - the only thing I'll mention is that I put the drift file in - /var/log/ntp.drift, and the authdelay on my 486DX/50 system is - 0.000064. Your mileage will vary, learn to use the authspeed tools - if you're going to authenticate. - - In the file /etc/rc.local, make sure that the invocation of ntpd is - commented out, and add an invocation of xntpd. Here's what I'm using: - - echo -n 'starting local daemons:' - - if [ -f /etc/ntp.keys -a -f /usr/local/etc/xntp.conf ]; then - echo -n ' xntpd'; /usr/local/etc/xntpd - fi - - #XXX# echo -n ' ntpd'; /usr/libexec/ntpd -t - -At this point, you should be good to go. Try running /usr/local/etc/xntpd and -using ntpq or xntpdc to see if things are working, then pay attention the next -time you reboot to make sure that xntpd is being invoked, and use ntpq or -xntpdc again to make sure all is well. - -Enjoy! diff -urN src/contrib/ntp/html/build/hints/changes src.ntp/contrib/ntp/html/build/hints/changes --- src/contrib/ntp/html/build/hints/changes 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/changes 1970-01-01 01:00:00.000000000 +0100 @@ -1,13 +0,0 @@ -Ulrich Windl (xntpd/refclock_parse.c): - - Added support to supply power from RS232 with CLOCK_RAWDCF. - Known to work with Linux 1.2. - - Made Linux ignore parity errors with CLOCK_RAWDCF. - -Ulrich Windl (parse/util/dcfd.c): - - Removed conflicting prototype for Linux (sscanf) - - Corrected spelling error - - Made Linux ignore parity errors. - - Added support to supply power from RS232 with CLOCK_RAWDCF. - -Ulrich Windl (parse/util/testdcf.c): - - Made Linux ignore parity errors. diff -urN src/contrib/ntp/html/build/hints/decosf1 src.ntp/contrib/ntp/html/build/hints/decosf1 --- src/contrib/ntp/html/build/hints/decosf1 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/decosf1 1970-01-01 01:00:00.000000000 +0100 @@ -1,40 +0,0 @@ -Some major changes were necessary to make xntp v3 run on the DEC Alpha -hardware running DEC OSF/1. All "long" and "u_long" declarations and -casts in the code were changed to "LONG" and "U_LONG" and a new header -file (include/ntp_types.h) was added. The new header file defines -LONG as int and U_LONG as u_int for the Alpha hardware and as long -and u_long for anything else. A couple of #ifs where changed in -ntpq and xntpdc to get the result of a signal defined correctly. The -Config.decosf1 file built the programs here with no problems. - -I don't have a radio clock here, so none of that code has been tested. -I have run xntpd, xntpdc, xntpres, ntpq, ntpdate, and tickadj under -DEC OSF/1 v1.2-2 (BL10). - -Mike Iglesias Internet: iglesias@draco.acs.uci.edu -University of California, Irvine BITNET: iglesias@uci -Office of Academic Computing uucp: ...!ucbvax!ucivax!iglesias -Distributed Computing Support phone: (714) 856-6926 - -Support for NTP Version 2 is included with the current OSF/1 release. If -you are upgrading to NTP Version 3 with this distribution, you should not -use the xntpd or ntpq programs that come with the OSF/1 release. The -older programs should be replaced by the newer programs of the same name, -either in situ or via a link to a tranquil spot like /usr/local/bin. The -make install script in the this distribution don't work due to a silly -install program incompatibility, so you will need to copy the programs by -hand. - -Don't use the setup utility to install or configure the xntpd installation, -as it will cheerfully clobber your painstakingly crafted ntp.conf program. -However, assuming you put this file in /etc/ntp.conf, you can use the -/sbin/init.d/xntpd script to start and stop the daemon. - -This distribution compiles with nominal mumur with the stock cc compiler -that comes with OSF/1. - -Dave Mills -Electrical Engineering Department -Unibergisty of Delabunch -mills@udel.edu - diff -urN src/contrib/ntp/html/build/hints/decosf2 src.ntp/contrib/ntp/html/build/hints/decosf2 --- src/contrib/ntp/html/build/hints/decosf2 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/decosf2 1970-01-01 01:00:00.000000000 +0100 @@ -1,54 +0,0 @@ -Problems with DEC OSF/1 V2.0 - -Compilation using gcc fails with ntp_config.c. The problem is an apparent -error in the /usr/include/sys/procset.h and /usr/include/sys/wait.h -include files. - -cowbird:/usr/include/sys# diff -c wait.h.orig wait.h -*** wait.h.orig Tue Feb 22 02:41:38 1994 ---- wait.h Thu Aug 25 14:52:57 1994 -*************** -*** 298,304 **** - #else - - _BEGIN_CPLUSPLUS -! extern int waitid(idtype_t, id_t, siginfo_t *, int); - _END_CPLUSPLUS - #endif /* _NO_PROTO */ - ---- 298,304 ---- - #else - - _BEGIN_CPLUSPLUS -! extern int waitid(idtype_t, pid_t, siginfo_t *, int); - _END_CPLUSPLUS - #endif /* _NO_PROTO */ - -cowbird:/usr/include/sys# diff -c procset.h.orig procset.h -*** procset.h.orig Tue Feb 22 02:41:44 1994 ---- procset.h Thu Aug 25 14:43:52 1994 -*************** -*** 86,95 **** - */ - - idtype_t p_lidtype; /* The id type for the left set. */ -! id_t p_lid; /* The id for the left set. */ - - idtype_t p_ridtype; /* The id type of for right set. */ -! id_t p_rid; /* The id of the right set. */ - } procset_t; - - ---- 86,95 ---- - */ - - idtype_t p_lidtype; /* The id type for the left set. */ -! pid_t p_lid; /* The id for the left set. */ - - idtype_t p_ridtype; /* The id type of for right set. */ -! pid_t p_rid; /* The id of the right set. */ - } procset_t; - -Also, if using gcc from the freeware disk, either replace syscall.h -in the directory /usr/local/lib/gcc-lib/alpha-dec-osf1/2.3.3/include -or replace with a link to /usr/include/sys/syscall.h. diff -urN src/contrib/ntp/html/build/hints/freebsd src.ntp/contrib/ntp/html/build/hints/freebsd --- src/contrib/ntp/html/build/hints/freebsd 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/freebsd 1970-01-01 01:00:00.000000000 +0100 @@ -1,15 +0,0 @@ -If you are compiling under FreeBSD and see messages in the syslogs that -indicate that the ntpd process is trying to use unavailable sched_ -calls, it means you are running a kernel that does not have the POSIX -scheduling calls enabled. - -You have two choices: - -- Ignore the messages - -- Generate a new kernel, where the kernel configuration file contains - the lines: - - options "P1003_1B" - options "_KPOSIX_PRIORITY_SCHEDULING" - options "_KPOSIX_VERSION=199309L" diff -urN src/contrib/ntp/html/build/hints/hpux src.ntp/contrib/ntp/html/build/hints/hpux --- src/contrib/ntp/html/build/hints/hpux 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/hpux 1970-01-01 01:00:00.000000000 +0100 @@ -1,158 +0,0 @@ -Last update: Sun Mar 13 15:05:31 PST 1994 - -This file hopefully describes the whatever and however of how to get xntp -running on hpux 7.0 and later s300. s400, s700, and s800. - -First off, all the standard disclaimers hold here ... HP doesn't have anthing -to do with this stuff. I fool with it in my spare time because we use it and -because I like to. We just happen to have a lot of HP machines around here :-) -Xntpd has been in use here for several years and has a fair amount of mileage -on various HP platforms within the company. I can't really guarantee bug fixes -but I'd certainly like to hear about bugs and I won't hestitate to look at -any fixes sent to me. - -Now lets talk OS. If you don't have 7.0 or later, pretty much hang it up now. -This stuff has run here on pretty much everything from 8.0 upward on s300, -s700, and s800. It is known to run on 7.0 s300/s400 but all reports are -from the field and not my personal experience. - -If you are lucky enough to have a s300 or s400 with 9.03, then you no longer -have to worry about adjtimed as HP-UX now has adjtime(2). The rest of you -will have to wait on 10.0 which will have adjtime(2) and a supported though -a bit older version of xntpd. - -Next, let me explain a bit about how this stuff works on HP-UX's that do not -have adjtime(2). The directory adjtime contains libadjtime.a and the adjtimed -daemon. Instead of the adjtime(2) system call, we use a library routine to -talk to adjtimed thru message queues. Adjtimed munges into /dev/kmem and -causes the clock to skew properly as needed. PLEASE NOTE that the adjtime -code provided here is NOT a general replacement for adjtime(2) ... use of -this adjtime(3)/adjtimed(8) other than with xntpd may yield very odd results. - -What to do to get this stuff running ? - - * If you are running an OS less than 10.0 or do not have a s300/s400 - with 9.03 or better - -> cd machines - -> vi hpux - -> (change -DSYS_HPUX=? to match whatever you are running [7,8,9]) - -> cd .. - - * Say "make makeconfig" - - * Say "make", sit back for a few minutes. - - * cd authstuff - * Say "./authcert < certdata" and check the output. Every line should - end with "OK" ... if not, we got trouble. - * Now try "./authspeed auth.samplekeys". What we want to - remember here is the "authentication delay in CPU time" - * cd .. - - * Say "make install" - - * I'd suggest reading the xntp docs about now :-) ... seriously !! - - * One thing I have added to this version of xntpd is a way to select - config files if you are sharing /usr/local thru NFS or whatever. - If the file /usr/local/etc/xntp.conf happens to be a directory, the - files in that directory are searched until a match is found. The - rules for a match are: - - 1. Our hostname - 2. default. (as in default.375 or default.850) - 3. default - - * Ok, make sure adjtimed is running (just start it up for now with - "/usr/local/etc/adjtimed"). Using -z as an option will get you - a usage message. - - * Now start up xntpd and watch it work. - - * Make sure that adjtimed gets started at boot right before xntpd. - We do this in /etc/netbsdsrc. They must both run as root !! - -Possible problems ? - - * On some 320's and 835's we have had to run adjtimed with "-p 45" or - so to get rid of syslog messages about "last adjust did not finish". - - * At 9.0, there is a problem with DIAGMON (patch available from the - response center) which causes it to delete the message queue that - adjtimed/xntpd use to communicate. (see next note for result) - - * Xntpd has been known to get really ticked off when adjtime() fails - which is usually only while running the emulation code on HP-UX. - When it gets mad, it usually jumps the clock into never never land. - Possible reasons for this are adjtimed being killed or just never - started or adjtimed being completely swapped out on a really busy - machine (newer adjtimed try to lock themselves in memory to prevent - this one). - -Anything else ... just drop me a line at ken@sdd.hp.com - -Received: from louie.udel.edu by huey.udel.edu id aa14418; 15 Jun 95 9:19 EDT -Received: from host5.colby.edu (host-05.colby.edu) by host-04.colby.edu with ESMTP (1.37.109.15/Colby 1.1) - id AA165442355; Thu, 15 Jun 1995 09:19:16 -0400 -Received: by host5.colby.edu (1.37.109.15/Colby 1.1) - id AA056252339; Thu, 15 Jun 1995 09:18:59 -0400 -Date: Thu, 15 Jun 1995 09:18:59 -0400 (EDT) -From: "Jeff A. Earickson" -To: Mills@huey.udel.edu -Subject: More minor bugs in xntp3.4s -In-Reply-To: <9506150022.aa12727@huey.udel.edu> -Message-Id: -Mime-Version: 1.0 -Content-Type: TEXT/PLAIN; charset=US-ASCII - -Dave, - After reading the hpux hints file, I realized I didn't install or -start adjtimed. In the course of doing this, I discovered that: - ---> $(TOP) is not defined in adjtime/Makefile, so "make install" can't - find the install.sh script. - ---> "make install" from the main Makefile never goes into the adjtime - directory, so I added the following two lines into the install - target of the main Makefile: - - @echo installing from adjtime - @cd adjtime && $(MAKE) $(MFLAGS) MFLAGS="$(MFLAGS)" MAKE="$(MAKE)" install - -This twiddle may not be right for all systems, but it got adjtimed -installed for me. - - You might also want to add to the hpux hints file that one way to -fire things up at boot time is to add the following lines to the localrc -function of /etc/rc: - - #---daemons for Network Time Protocol (version 3.4s) - #---note that adjtimed is only needed for HP-UX 9.X, not 10.0 - #---adjtimed must be running or xntpd won't work right... - if [ -x /usr/local/bin/adjtimed ]; then - /usr/local/bin/adjtimed -r & echo -n ' adjtimed' - if [ -x /usr/local/bin/xntpd ]; then - /usr/local/bin/xntpd & echo -n ' xntpd' - fi - fi - -I discovered that the "-r" option of adjtimed is needed to clear out any -trash from a previous execution of it. Otherwise adjtimed quietly dies -and leaves xntpd in the lurch... - -Thanks for the help. - -** Jeff A. Earickson, Ph.D PHONE: 207-872-3659 -** Senior UNIX Sysadmin, Information Technology EMAIL: jaearick@colby.edu -** Colby College, 4214 Mayflower Hill, FAX: 207-872-3555 -** Waterville ME, 04901-8842 - -On Thu, 15 Jun 1995 Mills@huey.udel.edu wrote: - -> Jeff, -> -> Read the hpux file in the hints directory. -> -> Dave -> - diff -urN src/contrib/ntp/html/build/hints/linux src.ntp/contrib/ntp/html/build/hints/linux --- src/contrib/ntp/html/build/hints/linux 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/linux 1970-01-01 01:00:00.000000000 +0100 @@ -1,5 +0,0 @@ -The kernel PLL interface is broken, I know. -Update RSN. - - Torsten - (duwe@informatik.uni-erlangen.de) diff -urN src/contrib/ntp/html/build/hints/mpeix src.ntp/contrib/ntp/html/build/hints/mpeix --- src/contrib/ntp/html/build/hints/mpeix 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/mpeix 1970-01-01 01:00:00.000000000 +0100 @@ -1,50 +0,0 @@ -HP e3000 MPE/iX NTP Hints - May 29, 2001 ----------------------------------------- - -NTP was first ported to MPE several years ago, but those diffs were never -submitted back to the official NTP distribution. For more information about -that deprecated port, please see http://www.bixby.org/mark/xntpix.html. - -NTP was re-ported to MPE in May 2001. What follows are hints learned from -working with NTP 4.0.99k23. For additional information about NTP on MPE, -please see http://jazz.external.hp.com/src/hp_freeware/ntp/. - -MPE lacks the clock-related APIs expected by NTP, so adjtime(), gettimeofday(), -and settimeofday() all had to be implemented from scratch by calling -privileged, undocumented internal OS functions. - -Unfortunately the implementation of adjtime() has exposed a sub-second accuracy -bug when slewing the system time. This bug is documented in SR 5003462838, and -exists on all current versions of MPE. It has not been fixed at the time of -this writing. The adjtime() code may possibly need to be altered if/when this -bug is fixed. - -This bug has a side-effect whereby the ntpd daemon will screw up the hardware -PDC clock time by many minutes if used for continuous clock adjustments or in -the one-time -q mode. But note that you can safely run ntpd in order to become -a time server if you include "disable ntp" in the ntp.conf configuration file. - -The one-time clock adjustment functionality of ntpdate and ntp_timeset is not -affected by this bug side-effect. You can safely use these commands to alter -your system time with reasonable accuracy. - -The only reference clock that has been tested on MPE is the local clock. So -building NTP with --disable-all-clocks --enable-LOCAL_CLOCK is strongly -recommended. - -NTP makes use of Privileged Mode (PM) capability in order to bind to the NTP -network port (123) and to access the low-level clock functions. - -NTP was ported using the gcc compiler. Attempting to use the HP C/iX compiler -is not recommended and has not been tested. - -Please note that NTP is not an HP product and is NOT supported by HP. The best -place for asking MPE-specific questions about NTP is the HP3000-L mailing list -at http://raven.utc.edu/Archives/hp3000-l.html or the associated Usenet -newsgroup of comp.sys.hp.mpe. - -The original author of this port is: - -Mark Bixby -HP CSY MPE Internet & Interoperability Engineer -mark_bixby@hp.com diff -urN src/contrib/ntp/html/build/hints/netbsd src.ntp/contrib/ntp/html/build/hints/netbsd --- src/contrib/ntp/html/build/hints/netbsd 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/netbsd 1970-01-01 01:00:00.000000000 +0100 @@ -1,37 +0,0 @@ -Starting with NetBSD-1.6, it is possible to delegate the system clock -control to a non root user. This enable running ntpd in a chroot -jail under a non privilegied UID/GID, using ntpd -i and -u flags. - -The delegation is done through the clockctl(4) pseudodevice driver. -This driver makes privilegied system calls such as ntp_adjtime(2) -available through ioctl(2) on the /dev/clockctl device. If a user -is able to write to /dev/clockctl, then (s)he can control the system -clock. - -In order to use this feature, make sure that: - -1) Your kernel is compiled with the following option: -pseudo-device clockctl -This is true for GENERIC kernels on most ports. Please check -http://wwW.netbsd.org/Documentation/kernel/ -if you need information about building a kernel. - -2) You have a ntpd user on your system. Here is the /etc/master.passwd -entry for ntpd user on NetBSD-1.6: -ntpd:*:15:15::0:0:& pseudo-user:/var/chroot/ntpd:/sbin/nologin -And here is the /etc/group entry for group 15: -ntpd:*:15: - -3) /dev/clockctl exists and is writtable by user ntpd. Default -NetBSD-1.6 setting is: -crw-rw---- 1 root ntpd 61, 0 Apr 1 2002 /dev/clockctl -Major device number and date is likely to be different on your system. -If you need to create the device, issue the following command: -cd /dev && ./MAKEDEV clockctl - -Here is an example of how to run ntpd chrooted in /var/chroot/ntpd, -running with ntpd UID and ntpd GID: -ntpd -i /var/chroot/ntpd -u ntpd:ntpd -Note that -i and -u options are enabled at configure time if your -system supports system clock control by an unprivilegied user. If this -is not the case, then the -i and -u options will not be available. diff -urN src/contrib/ntp/html/build/hints/notes-xntp-v3 src.ntp/contrib/ntp/html/build/hints/notes-xntp-v3 --- src/contrib/ntp/html/build/hints/notes-xntp-v3 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/notes-xntp-v3 1970-01-01 01:00:00.000000000 +0100 @@ -1,119 +0,0 @@ -Notes for NTP Version 3 - -This version operates in much the same manner as Version 2 with the -following changes and additions: - -1. The protocol machinery operates in conformance with the RFC1305 NTP - Version 3 specification. The most visible characteristic of this - version is that the poll intervals for all polls, even selected - ones, is significantly increased. This is especially desirable when - serving a large client population. This implementation supports - previous versions as non-configured peers; for version-2 configured - peers a "version 2" keyword should be included on the "peer" line. - -2. The configuration file has a new keyword: statfile , where - is the name of a statistics file." When present, each clock - update generates an entry of the form: - - . - - where is the modified Julian day, . is the time of - day, is the peer address and is the peer status. - The , and are the measured offset, delay and - dispersion, respectively, of the peer clock relative to the local - clock. About once per day the current file is closed and a new one - created with names ., where starts at one and - increments for each new generation. - -3. A number of additional platforms are supported. See ./Config file - for details. - -4. A driver for the TrueTime 468DC GOES Synchronized Clock is - included. This driver (refclock_goes.c) should also work for other - TrueTime radio clocks, since all use the same format. - -5. A replacement driver for the Spectracom 8170 WWVB Synchronized - Clock is included. This driver (refclock_wwvb.c) (a) does not - require a 1-pulse-per-second signal, (b) supports both format 0 - (original 8170) and format 2 (Netclock/2 and upgraded 8170), (c) - can be connected to more than one computer and (d) automatically - compensates for all serial baud rates. - -6. A driver for the German time/frequency station DCF77 is included. - This requires a special STREAMS module. - -7. In Version 2 special line-discipline modules were required for the - CHU and WWVB drivers. This code continues to work in Version 3, - although it is no longer needed for the WWVB driver. However, this - code does not work under STREAMS, as used in SunOS 4.1.1. - Equivalent STREAMS modules are supplied with Version 3. - -8. Support for an external 1-pulse-per-second (pps) signal is - provided. The signal is connected to a serial port (see - xntpd/ntp_loopfilter.c for details). When present the leading edge - of the pulse establishes the on-time epoch within an interval - established by the selected radio clock or other NTP time server. - Use of the pps is indicated when the tattletale displayed by ntpq - changes from "*" to "o". - -9. The clock-selection and poll-update procedures have been modified - slightly in order to achieve better performance on high speed LANs - with compromise in performance on typical WANs. - -10. In order to comply with U.S. Commerce Department regulations, the DES - encryption routine lib/authdes.c cannot be exported. For exportable - versions of this distribution a DES-encrypted version of this routine - lib/authdes.c.des is included along with an unencrypted version - lib/authdes.c.export, which allows normal operation, but without the - NTP authentication feature. Further information is available in the - lib/authdes.c.export file. - -11. As an alternative to the DES-based authentication mechanism, an - implementation of the RSA Message Digest 5 algorithm is provided. - (see applicable copyright information in the library files). - -12. A driver for the Magnavox MX4200 GPS clock. - -13. A STREAMS module which captures carrier-detect data-lead transitions to - connect a precision source of 1-pps, yet avoid the ugly overhead in the - usual STREAMS processing. See the ppsclock subdirectory. - -14. Support for the Apple A/UX operating system and enhanced support for the - Hewlet-Packard HP/UX operating system. See the various README and Config - files for further information. - -See the COPYRIGHT file for authors and copyright information. Note that some -modules in this distribution contain copyright information that supersedes -the copyright information in that file. - -If I missed something or neglected to give due credit, please advise. - -David L. Mills -University of Delaware -31 May 1992, amended 23 July 1992, 25 October 1992 - -Bugs and notes - -A bug in the original tty_clk_STREAMS.c module has been fixed. - -The poll-interval randomization feature of poll_update (in -xntpd/ntp_proto.c) has been extended to apply when the poll interval is -increased, as well as reduced. This spreads the update messages in time -and helps avoid unpleasant bursts of messages. - -In the clock_select algorithm the peers selected for combining are -limited to those survivors at the lowest stratum, not the entire list. -This helps avoid whiplash when large numbers of peers are at the same -stratum. - -The number formerly displayed by ntpq as "compliance" is now the time -constant of integration. - -The DNS resolver xntpd/ntp_intres.c is now integrated into xntpd, making -configuration of multiple hosts easier. - -System and peer event are now written to the system log at priority -LOG_INFO. - -The leap-second code was fixed to avoid broadcasting leap warnings on -all except the last day of June and December. diff -urN src/contrib/ntp/html/build/hints/parse src.ntp/contrib/ntp/html/build/hints/parse --- src/contrib/ntp/html/build/hints/parse 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/parse 1970-01-01 01:00:00.000000000 +0100 @@ -1,105 +0,0 @@ -Compilation: - Usual thing: rm -f Config.local ; make for vanilla - make refconf for reference clock (e. g. DCF77) - -Directory contents: - - hints/PARSE - this file - - xntpd/refclock_parse.c - - reference clock support for DCF77/GPS in xntp - parse/parse.c - - Reference clock data parser framework - parse/parse_conf.c - - parser configuration (clock types) - parse/clk_meinberg.c - - Meinberg clock formats (DCF U/A 31, PZF 535, GPS166) - parse/clk_schmid.c - - Schmid receiver (DCF77) - parse/clk_rawdcf.c - - 100/200ms pulses via 50 Baud line (DCF77) - parse/clk_dcf7000.c - - ELV DCF7000 (DCF77) - parse/clk_trimble.c - - Trimble SV6 GPS receiver - - If you want to add new clock types please check - with kardel informatik.uni-erlangen.de. These files - implement the conversion of RS232 data streams into - timing information used by refclock_parse.c which is - mostly generic except for NTP configuration constants. - - parse/Makefile.kernel - - *SIMPLE* makefile to build a loadable STREAMS - module for SunOS 4.x / SunOS 5.x systems - - parse/parsestreams.c - - SUN Streams module (loadable) for radio clocks - This streams module is designed for SunOS 4.1.X. - - parse/parsesolaris.c - - SUN Streams module (loadable) for radio clocks. - This streams module is designed for SunOS 5.x - Beware this is still new - so it might crash - your machine (we have seen it working, though). - - parse/parsetest.c - - simple test program for STREAMS module. Its so simple, - that it doesn't even set TTY-modes, thus they got to - be correct on startup - works for Meinberg receivers - - parse/testdcf.c - - test program for raw DCF77 (100/200ms pulses) - receivers - - include/parse.h - interface to "parse" module and more - include/parse_conf.h - - interface to "parse" configuration - - include/sys/parsestreams.h - - STREAMS specific definitions - - scripts/support - - scripts (perl & sh) for statistics and rc startup - the startup scripts are used in Erlangen for - starting the daemon on a variety of Suns and HPs - and for Reference Clock startup on Suns - These scripts may or may not be helpful to you. - -Supported clocks: - Meinberg DCF U/A 31 - Meinberg PZF535/TCXO (Software revision PZFUERL 4.6) - Meinberg PZF535/OCXO (Software revision PZFUERL 4.6) - Meinberg GPS166 (Software version for Uni-Erlangen) - ELV DCF7000 (not recommended - casual/emergency use only) - Conrad DCF77 receiver (email: time@informatik.uni-erlangen.de) - + level converter - TimeBrick (email: time@informatik.uni-erlangen.de) - Schmid Receiver Kit - Trimble SV6 GPS receiver - -Addresses: - Meinberg Funkuhren - Auf der Landwehr 22 - 31812 Bad Pyrmont - Germany - Tel.: 05281/20 18 - FAX: 05281/60 81 80 - - ELV Kundenservice - Postfach 1000 - 26787 Leer - Germany - Tel.: 0491/60 08 88 - - Walter Schmidt - Eichwisrain 14 - 8634 Hombrechtikon - Switzerland - -If you have problems mail to: - - time@informatik.uni-erlangen.de - -We'll help (conditions permitting) - diff -urN src/contrib/ntp/html/build/hints/refclocks src.ntp/contrib/ntp/html/build/hints/refclocks --- src/contrib/ntp/html/build/hints/refclocks 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/refclocks 1970-01-01 01:00:00.000000000 +0100 @@ -1,35 +0,0 @@ -This is a short overview for the reference clocks currently supported -by xntp V3. (Ultimate wisdom can be obtained from xntpd/refclock_*.c -this file was derived from that information - unfortunately some comments -in the files tend to get stale - so use with caution) - -Refclock address Type -127.127.0.x no clock (fails to configure) -127.127.1.x local clock - use local clock as reference -127.127.2.x no clock (fails to configure) -127.127.3.x PSTI 1010/1020 WWV Clock -127.127.4.x SPECTRACOM WWVB receiver 8170 and Netclock/2 -127.127.5.x Kinimetric Truetime 468-DC GOES receiver -127.127.6.x IRIG audio decode (Sun & modified BSD audio driver) -127.127.7.x CHU Timecode (via normal receiver & Bell 103 modem) -127.127.8.x PARSE (generic driver for a bunch of DCF/GPS clocks - can be extended for other clocks too) - 8.0-3 Meinberg PZF535/TCXO - 8.4-7 Meinberg PZF535/OCXO - 8.8-11 Meinberg DCF U/A 31 - 8.12-15 ELV DCF7000 - 8.16-19 Walter Schmid DCF receiver (Kit) - 8.20-23 Conrad DCF77 receiver module + level converter (Kit) - 8.24-27 TimeBrick (limited availability ask - time@informatik.uni-erlangen.de) - 8.28-31 Meinberg GPS166 - 8.32-35 Trimble SV6 GPS receiver -127.127.9.x MX4200 GPS receiver -127.127.10.x Austron 2201A GPS Timing Receiver -127.127.11.x Kinemetrics Truetime OM-DC OMEGA Receiver -127.127.12.x KSI/Odetecs TPRO-S IRIG-B / TPRO-SAT GPS -127.127.13.x Leitch: CSD 5300 Master Clock System Driver -127.127.14.x MSFEES -127/127.15.x TrueTime GPS/TM-TMD -127.127.16.x Bancomm GPS/IRIG Ticktock -127.127.17.x Datum Programmable Time System diff -urN src/contrib/ntp/html/build/hints/rs6000 src.ntp/contrib/ntp/html/build/hints/rs6000 --- src/contrib/ntp/html/build/hints/rs6000 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/rs6000 1970-01-01 01:00:00.000000000 +0100 @@ -1,56 +0,0 @@ -15.7.1993 -xntp3 compiles now again on AIX. I have disabled prototyping and added -the switch -D_NO_PROTO which disables prototyping in the system include -files. - -Matthias Ernst maer@nmr.lpc.ethz.ch --------------------------------------------------------------------------------- -Xntp version 3 now support the cc compiler for AIX. -The Config.aix will now use cc by default. You can still compile xntp -with the bsd compiler by changing "COMP= cc" to "COMP= bsdcc" and -and removing the "-DSTUPID_SIGNAL" option from the "DEFS" option. - -xntp and tickadj was also modified so that the value of tickadj is read -form the kernel and can be set by tickadj. For now I would not set -tickadj below 40 us. - -Bill Jones -jones@chpc.utexas.edu -------------------------------------------------------------------------------- - -This is a modified version of xntp version 3 for the RS6000. It works for -AIX 3.2 and these are the same changes as have been applied tothe version 2 -implementation of xntp. It works fine for us but I have not tested all of -the features, especially the local clock support for the RS6000 is not tested -at all. - -Matthias Ernst, ETH-Zuerich, Switzerland - maer@nmr.lpc.ethz.ch - --------------------------------------------------------------------------------- - -Here the original README.rs6000 for the version 2 implementation: - -A hacked version of xntp for the IBM RS/6000 under AIX 3.1 can be found -in xntp.rs6000.tar.Z. [ if still available at all - Frank Kardel 93/12/3 ] - -This will not work on older versions of AIX due to a kernel bug; to find -out whether you have the kernel bug, compile and run testrs6000.c (see -comments in the code for instructions). - -xntp and testrs6000 require "bsdcc" to compile. This is simply another -entry point into the xlc compiler with various options set for BSD -compatibility. If your system does not have bsdcc, do the following: - -link /bin/bsdcc to /bin/xlc - -put the following into /etc/xlc.cfg: - -* BSD compatibility -bsdcc: use = DEFLT - crt = /lib/crt0.o - mcrt = /lib/mcrt0.o - gcrt = /lib/gcrt0.o - libraries = -lbsd, -lc - proflibs = -L/lib/profiled,-L/usr/lib/profiled - options = -H512,-T512, -qlanglvl=extended, -qnoro, -D_BSD, -D_NONSTD_TYPES, -D_NO_PROTO, -tp,-B/lib/ - diff -urN src/contrib/ntp/html/build/hints/sco.html src.ntp/contrib/ntp/html/build/hints/sco.html --- src/contrib/ntp/html/build/hints/sco.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/sco.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,24 +0,0 @@ - - - - - - SCO Unix hints - - - - -

SCO Unix hints

-

Older SCO Unix versions

-

NTP 4.0.x does not run on SCO Unix prior to version 3.2.5.0.0. If you need NTP on an older SCO Unix system and don't mind to modify your kernel, use 3.5.91 which has patches for SCO Unix 3.2.4.x. Apply the kernel modifications as described in XNTP on SCO 3.2.4.2.

-

Compiling NTP

-

Delete the old SCO supplied NTP programs using the "custom" utility. Run the NTP configure program with CFLAGS="-b elf -K processor-type" for best results.

-

Running NTP

-

Run "tickadj -As" after every reboot to set the variables "clock_drift" and "track_rtc" to the right values.

-

Run "ntpd" with a high negative nice-value, i.e. "nice --19 ntpd" for best results.

-

More information

-

More information on the way SCO Unix and NTP interact can be found in NTP on SCO Unix, which includes links to precompiled versions of NTP.

-

Kees Hendrikse, January 1999

- - - \ No newline at end of file diff -urN src/contrib/ntp/html/build/hints/sgi src.ntp/contrib/ntp/html/build/hints/sgi --- src/contrib/ntp/html/build/hints/sgi 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/sgi 1970-01-01 01:00:00.000000000 +0100 @@ -1,74 +0,0 @@ -adjtime, tick and tickadj: --------------------------- - -The SGI value for HZ is 100 under Irix 4, with the system clock running -in nominal mode (ftimer off), so the value for tick is 10000 usec. -Tickadj is a bit more tricky because of the behaviour of adjtime(), -which seems to try to perform the correction over 100-200 seconds, with -a rate limit of 0.04 secs/sec for large corrections. Corrections of -less than 0.017 seconds generally complete in less than a second, -however. - -Some measured rates are as follows: - - Delta Rate (sec/sec) - - > 1 0.04 - 0.75 0.04 - 0.6 0.004 - 0.5 0.004 - 0.4 0.0026 - 0.3 0.0026 - 0.2 0.0013 - 0.1 0.0015 - 0.05 0.0015 - 0.02 0.0003 - 0.01 0.015 -Strange. Anyway, since adjtime will complete adjustments of less than -17msec in less than a second, whether the fast clock is on or off, I -have used a value of 150usec/tick for the tickadj value. - -Fast clock: ------------ - -I get smoother timekeeping if I turn on the fast clock, thereby making -the clock tick at 1kHz rather than 100Hz. With the fast clock off, I -see a sawtooth clock offset with an amplitude of 5msec. With it on, -the amplitude drops to 0.5msec (surprise!). This may be a consequence -of having a local reference clock which spits out the time at exactly -one-second intervals - I am probably seeing sampling aliasing between -that and the machine clock. This may all be irrelevant for machines -without a local reference clock. Fiddling with the fast clock doesn't -seem to compromise the above choices for tick and tickadj. - -I use the "ftimer" program to switch the fast clock on when the system -goes into multiuser mode, but you can set the "fastclock" flag in -/usr/sysgen/master.d/kernel to have it on by default. See ftimer(1). - -timetrim: ---------- - -Irix has a kernel variable called timetrim which adjusts the system -time increment, effectively trimming the clock frequency. Xntpd could -use this rather than adjtime() to do it's frequency trimming, but I -haven't the time to explore this. There is a utility program, -"timetrim", in the util directory which allows manipulation of the -timetrim value in both SGI and xntpd native units. You can fiddle with -default timetrim value in /usr/sysgen/master.d/kernel, but I think -that's ugly. I just use xntpd to figure out the right value for -timetrim for a particular CPU and then set it using "timetrim" when -going to multiuser mode. - -Serial I/O latency: -------------------- - -If you use a local clock on an RS-232 line, look into the kernel -configuration stuff with regard to improving the input latency (check -out /usr/sysgen/master.d/[sduart|cdsio]). I have a Kinemetrics OM-DC -hooked onto /dev/ttyd2 (the second CPU board RS-232 port) on an SGI -Crimson, and setting the duart_rsrv_duration flag to 0 improves things -a bit. - - -12 Jan 93 -Steve Clift, CSIRO Marine Labs, Hobart, Australia (clift@ml.csiro.au) diff -urN src/contrib/ntp/html/build/hints/solaris-dosynctodr.html src.ntp/contrib/ntp/html/build/hints/solaris-dosynctodr.html --- src/contrib/ntp/html/build/hints/solaris-dosynctodr.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/solaris-dosynctodr.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,321 +0,0 @@ - - - - - - - -Symptoms and Resolutions Article 19195 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- Home * Buy * My Sun(sm)sun.com Global Sections
- - - - Sun Microsystemsgif
- - - - - - - - - - - - - - - - - - -
Search SunSolve

-
- -Advanced Search
- -Product Search
- -Search Tips
- -
sopkoEdit
-
Contents Of SunSolve
- - - - - - - - -All Public Patches
- -Submit a Service Order
- -Diagnostic Tools
- -Support Docs.
- -Y2K Central
- -Security Information
-
-
  - -

------
- - Marked Docs.
- - Notifications
- - Low Graphics
- - SunSolve Servers
- - About SunSolve
- - Contact Us
- - Site Map
- - Articles
- - Home
- - Help
-
- - - -

-
-
- - - - - - - - - - - -
-
-[ Printer Friendly Page ] -[ Was this document useful? Yes or No ]
Notify if Document Changes ] -[ Mark Document for Download ]
View/Edit Notifications ] -[ View/Edit Marked Documents ]

- - -
Jump to
- - - - - - - - - - - - - -
SRDB ID Synopsis Date
19195 Upgraded to 2.6, using xntpd, but the system clock is drifting. Worked fine 4 Sep 1999

- - -
Problem DescriptionTop
-
Ever since upgrading to Solaris 2.6, the system clock has been drifting and
-there are messages like 'synchronisation lost', 'Previous time adjustment
-didn''t complete' and 'time reset (step)' a lot in the /var/adm/messages 
-file. The system either was previously working fine with the freeware
-xntpd or the configuration was copied from another system that was 
-using the freeware version.
--- 23-Apr-99 08:22 US/Eastern --
- -
Problem SolutionTop
-
The common lore for setting up xntpd on Solaris using
-the freeware version included the warning to set the 
-kernel variable dosynctodr to 0 in the /etc/system 
-file thus: set dosynctodr=0
-
-When using NTP on Solaris 2.6 or later, the kernel 
-variable MUST be left at the default value of 1. Prior 
-to 2.6 this variable controlled whether or not to rein  
-in the softclock using the hardware clock, with the result 
-that NTP and the hardware clock would fight for control of 
-the soft clock; thus before 2.6 you had to set dosynctodr 
-to 0. At 2.6, every system call that adjusts the softclock 
-also sets the hard clock, thus while NTP controls the soft 
-clock, the hard clock is also controlled. Setting 
-dosynctodr to 0 reverts the behavior back to the pre 2.6 
-defaulkt behavior, having exactly the opposite effect 
-as that intended.
-
-Do not set dosynctodr to 0.
- - - - - - - - - - -
Product AreaBundled Network
ProductNTP
OSSolaris 2.6
HardwareUltra 2
Document Contentwith freeware xntpd.

-
Top

-
- - - - - - - - - -
  -
-
- -
-
- - [ Edit Account ] - [ Patches ] - [ Submit a Service Order ]
- [ Diagnostic Tools ] - [ Support Docs. ] - [ Y2K Central ] - [ Security Information ]
- [ SunSolve Servers ] - [ About SunSolve ] - [ Contact Us ] - [ Site Map ] - [ Articles ] - [ Home ] - [ Help ] -
-
- - - -My Sun -Home -Buy - - - - -Java Technologies -Products and Solutions -Support, Education, and Consulting -Technology and Research -For Developers -Corporate Information - - - - - -SunSolve Online(tm) - - - - - -
-
- -
-Copyright 1994-1999 Sun Microsystems, Inc., 901 San Antonio Road, Palo Alto, CA 94303 USA. -
-All rights reserved. -Legal Terms. -Privacy Policy. -
-
- - - -
- - - - diff -urN src/contrib/ntp/html/build/hints/solaris.html src.ntp/contrib/ntp/html/build/hints/solaris.html --- src/contrib/ntp/html/build/hints/solaris.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/solaris.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,144 +0,0 @@ - - -Solaris hints and kinks - - - -Information on compiling and executing ntpd under Solaris. -
-Last Updated: Sun Jun 21 01:32:18 EDT 1998, -John Hawkinson, - <jhawk@MIT.EDU> -

-If you're not running Solaris 2.5.1 or later, it is likely -that you will have problems; upgrading would be a really good plan. -

-

All Solaris versions

-

- We have a report that says starting with Solaris 2.6 we should leave - dosynctodr alone. - Here is the report. -

-Proper operation of ntp under Solaris may require setting the kernel -variable dosynctodr to zero (meaning "do not synchronize the clock -to the hardware time-of-day clock"). This can be done with the -tickadj utility: -

-tickadj -s -
-If you prefer, it can also be done with the native Solaris kernel debugger: -
-echo dosynctodr/W0 | adb -k -w /dev/ksyms /dev/mem -
-

-Or, it can also be set by adding a line to /etc/system: -

-set dosynctodr = 0 -
-

-Instead of the tick kernel variable, which many operating -systems use to control microseconds added to the system time every -clock tick (c.f. Dealing -with Frequency Tolerance Violations), Solaris has the variables -nsec_per_tick and usec_per_tick. -

-nsec_per_tick and usec_per_tick control the number of -nanoseconds and microseconds, respectively, added to the system clock -each clock interrupt. Enterprising souls may set these based on -information collected by ntpd in the /etc/ntp.drift file -to correct for individual hardware variations. -

-On UltraSPARC systems, nsec_per_tick and usec_per_tick -are ignored in favor of the cpu_tick_freq variable, which -should be automatically be determined by the PROM in an accurate -fashion. -

-In general, the same ntp binaries should not be used across multiple -operating system releases. There is enough variation in the core operating -system support for timekeeping that a rebuild of ntpd for the idiosyncracies -of your specific operating system version is advisable. -

-It is recommended that ntp be started via a script like this one, installed in -/etc/init.d/ntpd with a symbol link from -/etc/rc2.d/S99ntpd. - -

Solaris 2.6

-

-Solaris 2.6 adds support for kernel PLL timekeeping, but breaks this -support in such a fashion that using it worse than not. This is SUN Bug ID 4095849, and it is not yet -fixed as of June 1998. -

-

Solaris 2.5 and 2.5.1

-

-On UltraSPARC systems, calculation of cpu_tick_freq is broken -such that values that are off by significant amounts may be used -instead. This unfortunately means that ntpd may have severe problems -keeping synchronization. This is SUN Bug ID -4023118. Bryan Cantrill of Sun -posted patchfreq, a workaround script, -to comp.protocols.time.ntp in March of 1997. -

-


-

OLD DATA

-I can't vouch for the accuracy the information below this -rule. It may be significantly dated or incorrect. -

-

-

Solaris 2.2

-

-Solaris 2.2 and later contain completely re-written clock code to -provide high resolution microsecond timers. A benefit of the -re-written clock code is that adjtime does not round off its -adjustments, so ntp does not have to compensate for this -rounding. Under Solaris 2.2 and later, ntp #define's -ADJTIME_IS_ACCURATE, and does not look for the tickadj -kernel variable. -

-

Solaris 2.1

-(This originally written by William L. Jones <jones@chpc.utexas.edu>) -

-Solaris 2.1 contains fairly traditional clock code, with tick -and tickadj. -

-Since settimeofday under Solaris 2.1 only sets the seconds part of timeval -care must be used in starting xntpd. I suggest the following start -up script: -

-tickadj -s -a 1000 -
ntpdate -v server1 server2 -
sleep 20 -
ntpdate -v server1 server2 -
sleep 20 -
tickadj -a 200 -
xntpd -
- -The first tickadj turns of the time of day clock and sets the tick -adjust value to 1 millisecond. This will insure that an adjtime value -of at most 2 seconds will complete in 20 seconds. -

-The first ntpdate will set the time to within two seconds -using settimeofday or it will adjust time using adjtime. -

-The first sleep insures the adjtime has completed for the first ntpdate. -

-The second ntpdate will use adjtime to set the time of day since the -clock should be within 2 seconds of the correct time. -

-The second tickadj set the tick adjust system value to 5 microseconds. -

-The second sleeps insure that adjtime will complete before starting -the next xntpd. -

-I tried running with a tickadj of 5 microseconds with out much success. -200 microseconds seems to work well. -

-


-Prior versions of this file had major text contributed by: - -
  • Denny Gentry <denny@eng.sun.com> -
  • - - diff -urN src/contrib/ntp/html/build/hints/solaris.xtra.4023118 src.ntp/contrib/ntp/html/build/hints/solaris.xtra.4023118 --- src/contrib/ntp/html/build/hints/solaris.xtra.4023118 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/solaris.xtra.4023118 1970-01-01 01:00:00.000000000 +0100 @@ -1,36 +0,0 @@ - Bug Id: 4023118 - Category: kernel - Subcategory: other - State: integrated - Synopsis: sun4u doesn't keep accurate time - Description: - -[ bmc, 12/20/96 ] - -The clock on a sun4u drifts unacceptably. On a typical 143 mHz Ultra, -the clock took 1.0001350 seconds to count 1 second. While this may seem -trivial, it adds up quickly. In this case, the TOD chip will have to -pull the clock forward by 2 seconds every 4 hours and 7 minutes. -This drift rate is so high, that the clock is close to being too broken -for NTP to guarantee correctness (in order for NTP's mechanism to work, -it must be assured that the local clock drifts no more than 20 ms in 64 -seconds; this particular 143 mHz Ultra will drift by nearly 9 ms in that -period). This problem has been reproduced on virtually all sun4u -classes. - -The fundamental problem lies in the kernel's perception of ticks per -second. The PROM is responsible for determining this figure exactly, -and the kernel extracts it into the variable cpu_tick_freq. On sun4u's, -this number is disconcertingly round: 143000000, 167000000, 248000000, -etc. Indeed, a simple experiment revealed that these numbers were -quite far from the actual ticks per second. Typical was the 143 mHz -Ultra which was discovered to tick around 142,980,806 (+/- 10) times -per second. - - Work around: - - Integrated in releases: s297_27 - Duplicate of: - Patch id: - See also: - Summary: diff -urN src/contrib/ntp/html/build/hints/solaris.xtra.4095849 src.ntp/contrib/ntp/html/build/hints/solaris.xtra.4095849 --- src/contrib/ntp/html/build/hints/solaris.xtra.4095849 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/html/build/hints/solaris.xtra.4095849 1970-01-01 01:00:00.000000000 +0100 @@ -1,74 +0,0 @@ - Bug Id: 4095849 - Category: kernel - Subcategory: syscall - State: evaluated - Synopsis: time_constant value >6 with PLL in use leads to integer divide - zero trap panic - Description: -If the time_constant parameter is 7 or higher, and the phase-lock looping model -is in use, the system will take a "integer divide zero trap" panic in -the clock routine as soon as the time_offset becomes non-zero. - -time_constant defaults to 0. The only place it is set is in the ntp_adjtime -system call, from the 'constant' element of the timex structure argument. - - Work around: -Never set the constant element of the timex structure passed to ntp_adjtime to -a value larger than 6. - -satish.mynam@Eng 1998-04-30 -1. Use Sun's version of NTP software instead of PD version. This problem -is not seen with Sun's NTP version (which is mostly eqivalent to PD NTP 3.4 -plus some Sun's local functionality futures). - -2. Workaround for the public domain NTP version ONLY: - ===================================================== -The workaround for public domain NTP version is to disable the -KERNEL_PLL from the NTP code. This way ntp_Adjtime() system call is -totally bypassed without sacrificing any of the functionality of the -NTP. The only hit you might see is the way kernel precision timminig -is done without the PLL algorithm in the kernel. - - The easiest way to disable ntp_adjtime option is(without changing - any makefiles or other config files) to disable the KERNEL_PLL - value in the ./config.h file. - -After doing a ./configure for probing for all the necessary tools(compilers, -os version, libraries), please comment out KERNEL_PLL macro in -the ./config.h file. This will disable the KERNEL_PLL part of the source -code and the newly obtained xntpd is just similar to the old one but it -does not use ntp_adjtime() system call. This prevents it from panic'ng -the kernel. - -/*#define KERNEL_PLL 1*/ - -I complied a new xntpd binary this way and it does nothave any ntp_adjtime() -related stuff. - -Default: -======= -/net/divya/export/home/mynam/public_domain/ntp/xntp3-5.92/xntpd>strings -xntpd | -grep ntp_adjtime -354:adj_frequency: ntp_adjtime failed: %m -357:loop_config: ntp_adjtime() failed: %m -435:get_kernel_info: ntp_adjtime() failed: %m - -With KERNEL_PLL disabled in config.h file --======================= - -/net/divya/export/home/mynam/public_domain/ntp/xntp3-5.92/xntpd>strings -xntpd.nopll | grep ntp_adjtime - - Integrated in releases: - Duplicate of: - Patch id: - See also: 4133517 - Summary: -If the time_constant parameter is 7 or higher, and the phase-lock looping model -is in use, the system will take a "integer divide zero trap" panic in -the clock routine as soon as the time_offset becomes non-zero. - -time_constant defaults to 0. The only place it is set is in the ntp_adjtime -system call, from the 'constant' element of the timex structure argument. ----------------------------------------------------------------------------- diff -urN src/contrib/ntp/html/build/hints/solaris.xtra.S99ntpd src.ntp/contrib/ntp/html/build/hints/solaris.xtra.S99ntpd --- src/contrib/ntp/html/build/hints/solaris.xtra.S99ntpd 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/solaris.xtra.S99ntpd 1970-01-01 01:00:00.000000000 +0100 @@ -1,21 +0,0 @@ -#!/bin/sh -if [ $1 = "start" ]; then - if [ -x /usr/local/bin/xntpd ]; then - echo "Starting NTP daemon, takes about 1 minute... " - # dosynctodr may need to be left alone as of with Solaris 2.6 - # The following line is unnecessary if you turn off - # dosynctodr in /etc/system. - /usr/local/bin/tickadj -s - /usr/local/bin/ntpdate -v server1 server2 - sleep 5 - /usr/local/bin/xntpd - fi -else - if [ $1 = "stop" ]; then - pid=`/usr/bin/ps -e | /usr/bin/grep xntpd | /usr/bin/sed -e 's/^ *//' -e 's/ .*//'` - if [ "${pid}" != "" ]; then - echo "Stopping Network Time Protocol daemon " - /usr/bin/kill ${pid} - fi - fi -fi diff -urN src/contrib/ntp/html/build/hints/solaris.xtra.patchfreq src.ntp/contrib/ntp/html/build/hints/solaris.xtra.patchfreq --- src/contrib/ntp/html/build/hints/solaris.xtra.patchfreq 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/solaris.xtra.patchfreq 1970-01-01 01:00:00.000000000 +0100 @@ -1,85 +0,0 @@ -#!/bin/ksh - -# -# File: patchfreq -# Author: Bryan Cantrill (bmc@eng.sun.com), Solaris Performance -# Modified: Sat Apr 26 04:00:59 PDT 1997 -# -# This is a little script to patch a 5.5 or 5.5.1 kernel to get around -# the cpu_tick_freq inaccuracy. Before running this script, one must -# know the true frequency of one's CPU; this can be derived by NTP, -# or by observing the clock relative to the time-of-day chip over a -# long period of time (the TOD will pull system time when it drifts -# by more than two seconds). -# -# Patching a kernel can render a machine unbootable; do not run this -# script unless you are prepared to accept that possibility. It -# is advisable to have a backout path (e.g. net booting, an alternate -# boot disk, an installation CD) should your machine fail to boot. -# -# This is not a product of Sun Microsystems, and is provided "as is", -# without warranty of any kind expressed or implied including, but not -# limited to, the suitability of this script for any purpose. -# - -if [ $# -eq 0 ]; then - echo "Usage: $0 cpu_tick_freq [ alternate_kernel ]" - exit 1 -fi - -cpu_tick_freq=$1 -kernel=/platform/sun4u/kernel/unix - -if [ $# -eq 2 ]; then - kernel=$2 -fi - -if [ ! -w $kernel ]; then - echo "$0: Cannot open $kernel for writing." - exit 1 -fi - -arch=`echo utsname+404?s | adb $kernel | cut -d: -f2` - -if [ ! $arch = "sun4u" ]; then - echo "Patch only applies to sun4u" - exit 1 -fi - -rel=`echo utsname+202?s | adb $kernel | cut -d: -f2` - -if [ ! $rel = "5.5" ] && [ ! $rel = "5.5.1" ]; then - echo "Patch only applies to 5.5 or 5.5.1..." - exit 1 -fi - -nop="1000000" # nop -store_mask="ffffe000" # mask out low 13 bits -store="da256000" # st %o5, [%l5 + offset] - -instr=`echo setcpudelay+34?X | adb $kernel | cut -d: -f 2 | nawk '{ print $1 }'` - -if [ $instr = $nop ]; then - echo "Instruction already patched..." -else - let masked="(16#$store_mask & 16#$instr) - 16#$store" - if [ $masked -ne 0 ]; then - echo "Couldn't find instruction to patch; aborting." - exit 1 - fi - - if ! echo setcpudelay+34?W $nop | adb -w $kernel 1> /dev/null - then - echo "adb returned an unexpected error; aborting." - fi -fi - -echo "Patching cpu_tick_freq to $cpu_tick_freq..." - -if ! echo cpu_tick_freq?W 0t$cpu_tick_freq | adb -w $kernel 1> /dev/null; then - echo "adb returned an unexpected error; aborting." - exit 1 -fi - -echo "$kernel successfully patched." -exit 0 diff -urN src/contrib/ntp/html/build/hints/sun4 src.ntp/contrib/ntp/html/build/hints/sun4 --- src/contrib/ntp/html/build/hints/sun4 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/sun4 1970-01-01 01:00:00.000000000 +0100 @@ -1,15 +0,0 @@ -Notes on CPU clock oscillator tolerance with SunOS 4.1.1 and 4.1.3 - -A bug in SunOS 4.1.1 results in the kernel time losing 1 microsecond -per tick of the system clock. The bug was fixed (bugid 1094383) for -SunOS 4.1.1 and corrected in SunOS 4.1.3. The easiest way to fix this -is to replace the 4.1.1 binary clock.o with the corresponding 4.1.3 -binary. Without this change it is necessary to use the tickadj program -included in this distribution with the -t 9999 option. - -The tickadj option will work in all cases except when the kernel has -been modified to correct the CPU clock oscillator frequency using a -1-pps signal from a precision source. The bugfix must be installed for -this wrinkle to work properly. - -Dave Mills (mills@udel.edu) diff -urN src/contrib/ntp/html/build/hints/svr4-dell src.ntp/contrib/ntp/html/build/hints/svr4-dell --- src/contrib/ntp/html/build/hints/svr4-dell 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/svr4-dell 1970-01-01 01:00:00.000000000 +0100 @@ -1,8 +0,0 @@ -Notes on the DELL SVR4. - -You should use -DSETTIMEOFDAY_BROKEN. - -Philip.Gladstone@mail.citicorp.com - -(XXX But there is no checking for SETTIMEOFDAY_BROKEN in the code) - diff -urN src/contrib/ntp/html/build/hints/svr4_package src.ntp/contrib/ntp/html/build/hints/svr4_package --- src/contrib/ntp/html/build/hints/svr4_package 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/svr4_package 1970-01-01 01:00:00.000000000 +0100 @@ -1,33 +0,0 @@ -Date: Wed, 12 Apr 1995 12:42:03 +0100 -Message-ID: <513.797686923@concurrent.co.uk> -From: Andy Chittenden - -Dave - -Here is a uuencoded, compressed tar file. The only file I've -changed is Makefile - I've included the full file rather than diffs. -There are some new files as well: - - xntp shell script that starts up ntp during boot up - (the packaging stuff creates links to it so it comes - up at run level 2). As with all svr4 start/stop - scripts, it takes one parameter which is either - start or stop. It assumes that ntp.conf is in - /etc/inet/ntp.conf (where it should be on svr4 - machines). - prototype describes the file contents of the package. - You might like to review its contents to - see whether you want to include any other - files or remove some. NB I've made the man - pages go into 1m as they should on svr4. - preinstall runs before installation takes place. It - ensures that ntp is down if it is up before - installing a replacement package - postinstall starts up ntp after package installation. - preremove brings down ntp before removing the package. - -You create a package using "make package". This creates a file -called xntp.pkg. To install this package, you use -"pkgadd -d `pwd`/xntp.pkg xntp". This will start up ntp if -/etc/inet/ntp.conf exists. If you don't want the package anymore, use -"pkgrm xntp". I have tested this on Solaris 2.4. diff -urN src/contrib/ntp/html/build/hints/todo src.ntp/contrib/ntp/html/build/hints/todo --- src/contrib/ntp/html/build/hints/todo 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/todo 1970-01-01 01:00:00.000000000 +0100 @@ -1,4 +0,0 @@ -Ulrich Windl : - Any change in a source file in the lib directory causes all files to - be recompiled (because the objects are removed). Add a better rule for - make to update the library. Maybe just remove "-rm -f $?". diff -urN src/contrib/ntp/html/build/hints/vxworks.html src.ntp/contrib/ntp/html/build/hints/vxworks.html --- src/contrib/ntp/html/build/hints/vxworks.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/vxworks.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,82 +0,0 @@ - - - - - - vxWorks Port of NTP - - - - -

    VxWorks port of NTP

    -

    Creating a port for vxWorks posed some problems. This port may help as a starting point for similar ports to real-time OS's and other embeddable kernels, particularly where main() is not allowed, and where the configure scripts need to be altered.

    -

    Configuration issues

    -

    I decided to do as little invasive surgery as possible on the NTP code, so I brought the vxWorks header tree in line with the standard unix tree. The following changes were needed, as a side effect these changes will allow for easy porting of other autoconfigure enabled code.

    -

    Where I have 386 you will need to put in your target type. The vxWorks tree entry point is /usr/wind. If these are the same for your system, you should be able to cut and paste the changes.

    -

    WARNING: Check you are not overwriting files, before entering the following: there should be no conflict, but check first...

    -

    export CC="cc386 -nostdlib -m486 -DCPU=I80486 -I/usr/wind/target/h"
    - export RANLIB=ranlib386
    - export AR=ar386
    - export VX_KERNEL=/usr/wind/target/config/ims_std_bsp/vxWorks
    - cd /usr/wind/target/sys
    - ln -s ../signal.h
    - ln -s ../time.h
    - ln -s socket.h sockio.h
    - ln -s ../selectLib.h select.h
    - ln -s ../timers.h
    - touch file.h param.h resource.h utsname.h var.h ../netdb.h ../a.out.h ../termios.h
    - echo " ******ADD #include \"sys/times.h\" to sys/time.h "

    -

    The configure script must be changed in the following way to get the linking tests to work, once in the correct directory issue the following commands:
    - sed -e 's%main.*()%vxmain()%' configure > configure.vxnew
    - mv configure.vxnew configure
    - chmod 755 configure

    -

    The new version 4 of NTP requires some maths functions so it links in the maths library (-lm) in the ntpd Makefile.am change the line "ntpd_LDADD = $(LDADD) -lm" by removing the "-lm".
    - You are now ready to compile

    -


    - The configure.in file needed to be altered to allow for a host-target configuration to take place.

    -
      -
    • The define SYS_VXWORKS was added to the compilation flags. -
    • Little endianess is set if the target is of type iX86. -
    • The size of char, integer, long values are all set. If Wind River ever changes these values they will need to be updated. -
    • clock_settime() is defined to be used for setting the clock. -
    • The Linking flags have -r added to allow for relinking into the vxWorks kernel -
    -

    Unfortunately I have had to make use of the ntp_machine.h file to add in the checks that would have been checked at linking stage by autoconf, a better method should be devised.

    -
      -
    • There is now a NO_MAIN_ALLOWED define that simulates command line args, this allows the use of the normal startup sysntax. -
    • POSIX timers have been added. -
    • Structures normally found in netdb.h have been added with, the corresponding code is in machines.c . Where possible the defines for these have been kept non-vxWorks specific. -
    -

    Unfortunately there are still quite a few SYS_VXWORKS type defines in the source, but I have eliminated as many as possible. You have the choice of using the usrtime.a library avaliable from the vxworks archives or forgoing adjtime() and using the clock_[get|set]time().The ntp_machine.h file clearly marks how to do this.

    -

    Compilation issues

    -

    You will need autoconf and automake ... available free from the gnu archives worldwide.

    -

    The variable arch is the target architecture (e.g. i486)

    -

    mkdir A.vxworks (or whatever....)
    - cd A.vxworks
    - ../configure --target=arch-wrs-vxworks [any other options]
    - make

    -

    Options I normally use are the --disable-all-clocks --enable-LOCAL-CLOCK flags. The program should proceed to compile without problem. The daemon ntpd, ntpdate, ntptrace, ntpdc, ntpq programs and of course the libraries are all fully ported. The other utilities are not, but they should be easy to port.

    -

    Running the software

    -

    Load in the various files, call them in the normal vxWorks function type manner. Here are some examples. Refer to the man pages for further information.

    -

    ld < ntpdate/ntpdate
    - ld < ntpd/ntpd
    - ld < ntptrace/ntptrace
    - ld < ntpq/ntpq
    - ld < ntpdc/ntpdc
    - ntpdate ("-b", "192.168.0.245")
    - sp(ntpd, "-c", "/export/home/casey/ntp/ntp.conf")
    - ntpdc("-c", "monlist", "192.168.0.244")
    - ntpq("-c", "peers", "192.168.0.244")
    - ntptrace("192.168.0.244")
    -

    -

    Bugs and such

    -

    Should you happen across any bugs, please let me know, or better yet fix them and submit a patch. Remember to make you patch general for Vxworks, not just for your particular architecture. CCII Systems (Pty) Ltd, my ex employers, sponsored the time to this port. Please let me know how it goes, I would be most interested in offsets and configurations.

    -


    -

    -

    Casey Crellin
    - casey@csc.co.za

    -


    -

    - - - \ No newline at end of file diff -urN src/contrib/ntp/html/build/hints/winnt.html src.ntp/contrib/ntp/html/build/hints/winnt.html --- src/contrib/ntp/html/build/hints/winnt.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints/winnt.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,281 +0,0 @@ - - - - - - - NTP on Windows NT - - - - -

    NTP 4.x for Windows NT

    - -

    Introduction

    - The NTP 4 distribution runs as service on Windows NT 4.0, Windows 2000, Windows XP, - Windows .NET Server 2003. It will NOT run on Windows 95, 98, ME, etc. - The binaries work on multi-processor systems. This port has not been tested - on the Alpha platform. This release now uses OpenSSL for authentication. - IPv6 is not implemented yet for Win32 platforms. -

    Authentication Keys

    - With this release ntp-keygen is supported. See the - ntp keygen documentation for details on how to use ntp-keygen. -

    - ntpd can now use the generated keys in the same way as on Unix platforms. Please - refer to the Authentication Options for details - on how to use these. -

    NOTE: ntpd and ntp-keygen both use OpenSSL which requires a random - character file called .rnd by default. Both of these programs will automatically - generate this file if they are not found. The programs will look for an - environmental variable called RANDFILE and use that for the name of the - random character file if the variable exists. If it does not exist it will look for an environmental - variable called HOME and use that directory to search for a filed called .rnd - in that directory. Finally, if neither RANDFILE nor HOME exists it will look - in C:\ for a .rnd file. In each case it will search for and create the file - if the environmental variable exists or in the C:\ directory if it doesn't. - Note that ntpd normally runs as a service so that the only way that it will - have either RANDFILE or HOME defined is if it is a System environmental - variable or if the service is run under a specific account name and that - account has one of those variables defined. Otherwise it will use the file - "c:\.rnd". This was done so that OpenSSL will work normally on Win32 systems. - This obviates the need to ship the OpenSSL.exe file and explain how to - generate the .rnd file. A future version may change this behavior. - -

    Refer to Compiling Requirements and Instructions for how to compile the program.

    -

    Reference Clocks

    - Reference clock support under Windows NT is tricky because the IO functions are - so much different. Some of the clock types have been built into the ntpd executable - and should work but have not been tested by the ntp project. If you have a clock - that runs on Win32 and the driver is there but not implemented on Win32 you will have - make the required configuration changes in config.h and then build ntpd from source - and test it. The following reference clocks are known to work and are supported - by Windows NT: -

    Type 1 Undisciplined Local Clock (LOCAL)
    - Type 29 Trimble Navigation Palisade GPS (GPS_PALISADE)

    -

    Functions Supported

    - All NTP functions are supported with some constraints. See the TODO list below. - Note that the ntptrace executable is not supported and you should use the PERL script - version instead. -

    Accuracy

    - Greg Brackley has implemented a fantastic interpolation scheme that improves the precision of the NTP clock - using a realtime thread (is that poetic or what!) which captures a tick count from the 8253 counter after each - OS tick. The count is used to interpolate the time between operating system ticks. -

    On a typical 200+ MHz system NTP achieves a precision of about 5 microseconds and synchronizes the clock - to +/-500 microseconds using the Trimble Palisade as UTC reference. - This allows distributed applications to use the 10 milliseconds ticks available to them with high confidence.

    -

    Binaries

    - Recent InstallShield based executable versions of NTP for Windows NT (intel) are available from: - -

    ToDo

    - These tasks are in no particular order of priority. -
      -
    • Create a proper install/uninstall program -
    • Add sntp to the list of supported programs -
    • Add support for Visual C++ 7.0 or later (.NET) -
    • Add IPv6 support -
    • See if precision can be improved by using CPU cycle counter for tick interpolation. -
    • Make precision time available to applications using NTP_GETTIME API -
    -

    Compiling Requirements

    -
      -
    • Windows NT 4.0 Windows 2000, Windows XP, or Windows.NET Server 2003 -
    • Microsoft Visual C++ 6.0. NOTE: VC++ 7.0 (aka .NET) is not yet supported - but will probably work fine. -
    • Some way of uncompressing and untarring the gzipped tar file. -
    • OpenSSL must be built on the box before building NTP. Additional steps would - be required to not use OpenSSL. -
    -

    Compiling Instructions

    -
      -
    1. Unpack and build OpenSSL according to the OpenSSL instructions for building on - Windows. An environment variable named OPENSSL must be set up to specify the base path - of the OpenSSL directory to be used to build the NTP package - (e.g. OPENSSL=C:\openssl-0.9.8b). -
    2. Unpack the ntp-*.tar.gz archive using utilities such as WinZip. -
    3. Open the .\ports\winnt\ntp.dsw Visual C workspace -
    4. Batch build all projects -
    5. The built binaries can be found in the port\winnt\bin\Release subdirectory -
    6. In addition you will need to install the OpenSSL libeay32.dll -
    7. If you are shipping binaries in a kit it is strongly recommended that you - ship this file (winnt.html) along with the binaries. -
    -

    Configuration File

    - The default NTP configuration file path is %SystemRoot%\system32\drivers\etc\. (%SystemRoot% - is an environmental variable that can be determined by typing "set" at the "Command Prompt" - or from the "System" icon in the "Control Panel").
    - Refer to your system environment and create your ntp.conf file in the directory - corresponding to your system  installation.
    - The older <WINDIR>\ntp.conf is still supported but you will get a log entry reporting that - the first file wasn't found. -

    Installation Instructions

    - The instsrv program in the instsrv subdirectory of the distribution can be used to install 'ntpd' as - a service and start automatically at boot time. Instsrv is automatically compiled with the rest of the distribution - if you followed the steps above. -
      -
    1. Start a command prompt and enter "instsrv.exe <pathname_for_ntpd.exe>" -
    2. Clicking on the "Services" icon in the "Control Panel" will display the list of - currently installed services in a dialog box. The NetworkTimeProtocol service should show up in this list. - Select it in the list and hit the "Start" button in the dialog box. The NTP service should start. -
    3. You can also stop and start the service by typing net start|stop NetworkTimeProtocol at the DOS prompt. -
    4. View the event log by clicking on the "Event Viewer" icon in the "Administrative Tools" - group, there should be several successful startup messages from NTP. NTP will keep running and restart - automatically when the machine is rebooted. -
    - You can change the start mode (automatic/manual) and other startup parameters corresponding to the NTP service - in the "Services" dialog box if you wish. -

    Removing NTP

    - You can also use instsrv to delete the NTP service by entering: "instsrv.exe remove" -

    Command Line Parameters and Registry Entries

    - Unlike the Unix environment, there is no clean way to run 'ntpdate' and reset the clock before starting 'ntpd' at boot time.
    - NTP will step the clock up to 1000 seconds by default. While there is no reason that the system clock should be that much off - during bootup if 'ntpd' was running before, you may wish to override this default and/or pass other command line directives. -

    Use the registry editor to edit the value for the ntpd executable under LocalMachine\System\CurrentControlSet\Services\NTP.

    -

    Add the -g option to the ImagePath key, behind "%INSTALLDIR>\ntpd.exe". This will force NTP to accept - large time errors (including 1.1.1980 00:00)

    -

    Bug Reports

    - Send questions to news://comp.protocols.time.ntp - and bug reports should be entered in Bugzilla on the - NTP Web site. -

    Change Log

    -

    Last revision 2 July 2003  Version 4.2.0

    - by Danny Mayer (mayer@ntp.org>) -

    Significant Changes:

    - This latest release of NTP constitutes a major upgrade to its ability to build and - run on Windows platforms and should now build and run cleanly. More importantly it - is now able to support all authentication in the same way as Unix boxes. This does - require the usage of OpenSSL which is now a prerequisite for build on Windows. - ntp-keygen is now supported and builds on Win32 platforms. - -

    Last revision 16 February 1999  Version 4.0.99e.

    - by Sven Dietrich (sven_dietrich@trimble.com) -

    Significant Changes:

    -
      -
    • Perl 5 is no longer needed to compile NTP. The configuration script which creates version.c - with the current date and time was modified by Frederick Czajka [w2k@austin.rr.com] so that Perl - is no longer required. -
    -

    Last revision 15 November 1999  Version 4.0.98f.

    - by Sven Dietrich (sven_dietrich@trimble.com) -

    Significant Changes:

    -
      -
    • Fixed I/O problem delaying packet responses which resulted in no-replys to NTPQ and others. -
    • The default configuration file path is <WINDIR>\system32\drivers\etc\ntp.conf. - The old <WINDIR>\ntp.conf is still supported but you will get a log entry reporting - that the first file wasn't found. The NTP 3.x legacy ntp.ini file is no longer supported. -
    - Known Problems / TODO: -
      -
    • MD5 and name resolution do not yet get along. If you define MD5, you cannot use DNS names, only IP numbers. -
    -

    Last revision 27 July 1999  Version 4.0.95.

    - This version compiles under WINNT with Visual C 6.0. -

    Greg Brackley and Sven Dietrich

    -

    Significant changes:
    - -Visual Studio v6.0 support
    - -Winsock 2.0 support
    - -Use of I/O completion ports for sockets and comm port I/O
    - -Removed the use of multimedia timers (from ntpd, others need removing)
    - -Use of waitable timers (with user mode APC) and performance counters to fake getting a better time
    - -Trimble Palisade NTP Reference Clock support
    - -General cleanup, prototyping of functions
    - -Moved receiver buffer code to a separate module (removed unused members from the recvbuff struct)
    - -Moved io signal code to a separate module

    -

    Last revision:  20-Oct-1996

    - This version corrects problems with building the XNTP
    - version 3.5-86 distribution under Windows NT. -

    The following files were modified:
    -  blddbg.bat
    -  bldrel.bat
    -  include\ntp_machine.h
    -  xntpd\ntp_unixclock.c
    -  xntpd\ntp_refclock.c
    -  scripts\wininstall\build.bat
    -  scripts\wininstall\setup.rul
    -  scripts\wininstall\readme.nt
    -  scripts\wininstall\distrib\ntpog.wri
    -  html\hints\winnt (this file)

    -

    In order to build the entire Windows NT distribution you
    - need to modify the file scripts\wininstall\build.bat
    - with the installation directory of the InstallShield
    - software.  Then, simply type "bldrel" for non-debug
    - or "blddbg" for debug executables.

    -

    Greg Schueman
    -     <schueman@acm.org>

    -

    Last revision:  07-May-1996

    - This set of changes fixes all known bugs, and it includes
    - several major enhancements. -

    Many changes have been made both to the build environment as
    - well as the code.  There is no longer an ntp.mak file, instead
    - there is a buildntall.bat file that will build the entire
    - release in one shot.  The batch file requires Perl.  Perl
    - is easily available from the NT Resource Kit or on the Net.

    -

    The multiple interface support was adapted from Larry Kahn's
    - work on the BIND NT port.  I have not been able to test it
    - adequately as I only have NT servers with one network
    - interfaces on which to test.

    -

    Enhancements:
    - * Event Logging now works correctly.
    - * Version numbers now work (requires Perl during build)
    - * Support for multiple network interface cards (untested)
    - * NTP.CONF now default, but supports ntp.ini if not found
    - * Installation procedure automated.
    - * All paths now allow environment variables such as %windir%

    -

    Bug fixes:
    - * INSTSRV replaced, works correctly
    - * Cleaned up many warnings
    - * Corrected use of an uninitialized variable in XNTPD
    - * Fixed ntpdate -b option
    - * Fixed ntpdate to accept names as well as IP addresses
    -         (Winsock WSAStartup was called after a gethostbyname())
    - * Fixed problem with "longjmp" in xntpdc/ntpdc.c that
    -         caused a software exception on doing a Control-C in xntpdc.
    -  A Cntrl-C now terminates the program.

    -

    See below for more detail:

    -

          Note: SIGINT is not supported for any Win32 application including
    -       Windows NT and Windows 95. When a CTRL+C interrupt occurs, Win32
    -       operating systems generate a new thread to specifically handle that
    -       interrupt. This can cause a single-thread application such as UNIX,
    -       to become multithreaded, resulting in unexpected behavior.
    -  

    -

    Possible enhancements and things left to do:
    - * Reference clock drivers for NT (at least Local Clock support)
    - * Control Panel Applet
    - * InstallShield based installation, like NT BIND has
    - * Integration with NT Performance Monitor
    - * SNMP integration
    - * Fully test multiple interface support
    -  

    -

    Known problems:
    - *       bug in ntptrace - if no Stratum 1 servers are available,
    -                 such as on an - IntraNet, the application crashes.

    -

    Last revision:  12-Apr-1995

    - This NTPv3 distribution includes a sample configuration file and the project
    - makefiles for WindowsNT 3.5 platform using Microsoft Visual C++ 2.0 compiler.
    - Also included is a small routine to install the NTP daemon as a "service"
    - on a WindowsNT box. Besides xntpd, the utilities that have been ported are
    - ntpdate and xntpdc. The port to WindowsNT 3.5 has been tested using a Bancomm
    - TimeServe2000 GPS receiver clock that acts as a strata 1 NTP server with no
    - authentication (it has not been tested with any refclock drivers compiled in).
    - Following are the known flaws in this port:
    - 1) currently, I do not know of a way in NT to get information about multiple
    -    network interface cards. The current port uses just one socket bound to
    -    INADDR_ANY address. Therefore when dealing with a multihomed NT time server,
    -    clients should point to the default address on the server (otherwise the
    -    reply is not guaranteed to come from the same interface to which the
    -    request was sent). Working with Microsoft to get this resolved.
    - 2) There is some problem with "longjmp" in xntpdc/ntpdc.c that causes a
    -    software exception on doing a Control-C in xntpdc. Be patient!
    - 3) The error messages logged by xntpd currently contain only the numerical
    -    error code. Corresponding error message string has to be looked up in
    -    "Books Online" on Visual C++ 2.0 under the topic "Numerical List of Error
    -    Codes". -

    Last HTML Update: November 17, 1999
    - Sven_Dietrich@Trimble.COM

    - - - diff -urN src/contrib/ntp/html/build/hints.html src.ntp/contrib/ntp/html/build/hints.html --- src/contrib/ntp/html/build/hints.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/hints.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,23 +0,0 @@ - - - - - - Hints and Kinks - - - - -

    Hints and Kinks

    - gif from Alice's Adventures in Wonderland, Lewis Carroll -

    Mother in law has all the answers.

    -

    Last update: 12:56 AM UTC Saturday, March 20, 2004

    -
    -
    -

    This is an index for a set of troubleshooting notes contained in individual text files in the ./hints directory. They were supplied by various volunteers in the form of mail messages, patches or just plain word of mouth. Each note applies to a specific computer and operating system and gives information found useful in setting up the NTP distribution or site configuration. The notes are very informal and subject to errors; no attempt has been made to verify the accuracy of the information contained in them.

    -

    Additions or corrections to this list or the information contained in the notes is solicited. The most useful submissions include the name of the computer manufacturer (and model numbers where appropriate), operating system (specific version(s) where appropriate), problem description, problem solution and submitter's name and electric address. If the submitter is willing to continue debate on the problem, please so advise. See the directory listing.

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/build/patches.html src.ntp/contrib/ntp/html/build/patches.html --- src/contrib/ntp/html/build/patches.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/patches.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,36 +0,0 @@ - - - - - - Patching Procedures - - - - -

    Patching Procedures

    - gif rom Alice's Adventures in Wonderland, Lewis Carroll -

    The Mad Hatter needs patches.

    -

    Last update: 12:56 AM UTC Saturday, March 20, 2004

    -
    -
    -

    A distribution so widely used as this one eventually develops numerous barnacles as the result of porting to new systems, idiosyncratic new features and just plain bugs. In order to help keep order and make maintenance bearable, we ask that proposed changes to the distribution be submitted in the following form.

    -
      -
    1. Please submit patches to bugs@mail.ntp.org in the form of either unified-diffs (diff -u) or context-diffs (diff -c). -
    2. Please include the output from config.guess in the description of your patch. If config.guess does not produce any output for your machine, please fix that, too! -
    3. Please base the patch on the root directory of the distribution. The preferred procedure here is to copy your patch to the root directory and mumble -

      patch -p <your_patch>

      -
    4. Please avoid patching the RCS subdirectories; better yet, clean them out before submitting patches. -
    5. If you have whole new files, as well as patches, wrap the files and patches in a shell script. If you need to compress it, use either GNU gzip or the stock Unix compress utility. -
    6. Don't forget the documentation that may be affected by the patch. Send us patches for the ./htm files as well. -
    7. We would be glad to include your name, electric address and descriptive phrase in the Copyright page, if you wish. -
    -

    Prior to ntp3-5.83 (releases up to and including ntp3.5f) a complete patch history back to the dark ages was kept in the ./patches directory, which might have been helpful to see if the same problem occurred in another port, etc. Patches were saved in that directory with file name in the form patch.nnn, where nnn was approaching 200. All patches in that directory have been made; so, if yours was there, it was in the distribution.

    -

    Since we have been getting multple patches for some bugs, plus many changes are implemented locally, no two maintainers here use the same tools, and since we're not using any bug-tracking software or even source code control, there is currently no tracking of specific changes.

    -

    The best way to see what's changed between two distributions is to run a diff against them.

    -

    Thanks for your contribution and happy chime.

    -
    - - - - diff -urN src/contrib/ntp/html/build/porting.html src.ntp/contrib/ntp/html/build/porting.html --- src/contrib/ntp/html/build/porting.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/porting.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,40 +0,0 @@ - - - - - - Porting Hints - - - - -

    Porting Hints

    - giffrom The Wizard of Oz, L. Frank Baum -

    Porting Dorothy in Oz -

    -

    Last update: 12:56 AM UTC Saturday, March 20, 2004

    -
    -
    -

    NOTE: The following procedures have been replaced by GNU automake and autoconfigure. This page is to be updated in the next release.

    -

    Porting to a new machine or operating system ordinarily requires updating the ./machines directory and the ./compilers directories in order to define the build environment and autoconfigure means. You will probably have to modify the ntp_machines.h file and "l_stdlib.h" files as well. The two most famous trouble spots are the I/O code in ./ntpd/ntp_io.c and the clock adjustment code in ./ntpd/ntp_unixclock.c.

    -

    These are the rules so that older bsd systems and the POSIX standard system can coexist together.

    -
      -
    1. If you use select then include "ntp_select.h". select is not standard, since it is very system dependent as to where it is defined. The logic to include the right system dependent include file is in "ntp_select.h". -
    2. Always use POSIX definition of strings. Include "ntp_string.h" instead of <string.h>. -
    3. Always include "ntp_malloc.h" if you use malloc. -
    4. Always include "ntp_io.h" instead of <sys/file.h> or <fnctl.h> to get O_* flags. -
    5. Always include "ntp_if.h" instead of <net/if.h>. -
    6. Always include "ntp_stdlib.h" instead of <stdlib.h>. -
    7. Define any special defines needed for a system in ./include/ntp_machine.h based on system identifier. This file is included by the "ntp_types.h" file and should always be placed first after the <> defines. -
    8. Define any special library prototypes left over from the system library and include files in the "l_stdlib.h" file. This file is included by the "ntp_stdlib.h" file and should ordinarily be placed last in the includes list. -
    9. Don't define a include file by the same name as a system include file. -
    -

    "l_stdlib.h" can contain any extra definitions that are needed so that gcc will shut up. They should be controlled by a system identifier and there should be a separate section for each system. Really this will make it easier to maintain.

    -

    See include/ntp_machines.h for the various compile time options.

    -

    When you are satisfied the port works and that other ports are not adversely affected, please send patches for the system files you have changed, as well as any documentation that should be updated, including the advice herein.

    -

    Good luck.

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/build/quick.html src.ntp/contrib/ntp/html/build/quick.html --- src/contrib/ntp/html/build/quick.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/quick.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,30 +0,0 @@ - - - - - - - Quick Start - - - - -

    Quick Start

    - gifFAX test image for SATNET (1979). -

    The baby panda was scanned at University College London and used as a FAX test image for a demonstration of the DARPA Atlantic SATNET Program and the first transatlantic Internet connection in 1978. The computing system used for that demonstration was called the Fuzzball . As it happened, this was also the first Internet multimedia presentation and the first to use NTP in regular operation. The image was widely copied and used for testing purpose throughout much of the 1980s.

    -

    Last update: 01:01 AM UTC Saturday, March 20, 2004

    -
    -
    -

    For the rank amateur the sheer volume of the documentation collection must be intimidating. However, it doesn't take much to fly the ntpd daemon with a simple configuration where a workstation needs to synchronize to some server elsewhere in the Internet. The first thing that needs to be done is to build the distribution for the particular workstation and install in the usual place. The Building and Installing the Distribution page describes how to do this.

    -

    While it is possible that certain configurations do not need a configuration file, most do require one. The file, called by default /etc/ntp.conf, need only contain one line specifying a remote server, for instance

    -

    server foo.bar.com

    -

    Choosing an appropriate remote server is somewhat of a black art, but a suboptimal choice is seldom a problem. There are about two dozen public time servers operated by National Institutes of Science and Technology (NIST), US Naval Observatory (USNO), Canadian Metrology Centre (CMC) and many others available on the Internet. Lists of public primary and secondary NTP servers maintained on the Public NTP TIme Servers page, which is updated frequently.The lists are sorted by country and, in the case of the US, by state. Usually, the best choice is the nearest in geographical terms, but the terms of engagement specified in each list entry should be carefully respected.

    -

    During operation ntpd measures and corrects for incidental clock frequency error and writes the current value to a file called by default /etc/ntp.drift. If ntpd is stopped and restarted, it initializes the frequency from this file. In this way the potentially lengthy interval to relearn the frequency error is avoided.

    -

    That's all there is to it, unless some problem in network connectivity or local operating system configuration occurs. The most common problem is some firewall between the workstation and server. System administrators should understand NTP uses UDP port 123 as both the source and destination port and that NTP does not involve any operating system interaction other than to set the system clock. While almost all modern Unix systems have included NTP and UDP port 123 defined in the services file, this should be checked if ntpd fails to come up at all.

    -

    The best way to confirm NTP is working is using the ntpq utility, although the ntpdc utility may be useful in extreme cases. See the documentation pages for further information. In the most extreme cases the -d option on the ntpd command line results in a blow-by-blow trace of the daemon operations. While the trace output can be cryptic, to say the least, it gives a general idea of what the program is doing and, in particular, details the arriving and departing packets and detected errors, if present.

    -

    Sometimes the ntpd. behavior may seem to violate the Principle of Least Astonishment, but there are good reasons for this. See the Network Time Protocol (NTP) daemon page for revealing insights. See this page and its dependencies for additional configuration and control options. The Notes on Configuring NTP and Setting up a NTP Subnet page contains an extended discussion of these options.

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/build/scripts/footer.txt src.ntp/contrib/ntp/html/build/scripts/footer.txt --- src/contrib/ntp/html/build/scripts/footer.txt 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/scripts/footer.txt 1970-01-01 01:00:00.000000000 +0100 @@ -1,7 +0,0 @@ -document.write("\ -\ -\ -\ -
    gif\ -Home Pagegif\ -Contacts
    ") \ No newline at end of file diff -urN src/contrib/ntp/html/build/scripts/links10.txt src.ntp/contrib/ntp/html/build/scripts/links10.txt --- src/contrib/ntp/html/build/scripts/links10.txt 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/scripts/links10.txt 1970-01-01 01:00:00.000000000 +0100 @@ -1,5 +0,0 @@ -document.write("") \ No newline at end of file diff -urN src/contrib/ntp/html/build/scripts/links11.txt src.ntp/contrib/ntp/html/build/scripts/links11.txt --- src/contrib/ntp/html/build/scripts/links11.txt 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/scripts/links11.txt 1970-01-01 01:00:00.000000000 +0100 @@ -1,5 +0,0 @@ -document.write("") \ No newline at end of file diff -urN src/contrib/ntp/html/build/scripts/links12.txt src.ntp/contrib/ntp/html/build/scripts/links12.txt --- src/contrib/ntp/html/build/scripts/links12.txt 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/scripts/links12.txt 1970-01-01 01:00:00.000000000 +0100 @@ -1,5 +0,0 @@ -document.write("") \ No newline at end of file diff -urN src/contrib/ntp/html/build/scripts/links7.txt src.ntp/contrib/ntp/html/build/scripts/links7.txt --- src/contrib/ntp/html/build/scripts/links7.txt 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/scripts/links7.txt 1970-01-01 01:00:00.000000000 +0100 @@ -1,5 +0,0 @@ -document.write("") \ No newline at end of file diff -urN src/contrib/ntp/html/build/scripts/links8.txt src.ntp/contrib/ntp/html/build/scripts/links8.txt --- src/contrib/ntp/html/build/scripts/links8.txt 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/scripts/links8.txt 1970-01-01 01:00:00.000000000 +0100 @@ -1,6 +0,0 @@ -document.write("") \ No newline at end of file diff -urN src/contrib/ntp/html/build/scripts/links9.txt src.ntp/contrib/ntp/html/build/scripts/links9.txt --- src/contrib/ntp/html/build/scripts/links9.txt 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/scripts/links9.txt 1970-01-01 01:00:00.000000000 +0100 @@ -1,7 +0,0 @@ -document.write("") \ No newline at end of file diff -urN src/contrib/ntp/html/build/scripts/style.css src.ntp/contrib/ntp/html/build/scripts/style.css --- src/contrib/ntp/html/build/scripts/style.css 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/build/scripts/style.css 1970-01-01 01:00:00.000000000 +0100 @@ -1,64 +0,0 @@ -body {background: #FDF1E1; - color: #006600; - font-family: "verdana", sans-serif; - text-align: justify; - margin-left: 5px;} - -p, h4, hr, li {margin-top: .6em; margin-bottom: .6em} -li.inline {text-align: left; margin-top: 0; margin-bottom: 0} - -ul, dl, ol, {margin-top: .6em; margin-bottom: .6em; margin-left 5em} - -dt {margin-top: .6em} -dd {margin-bottom: .6em} - -div.header {text-align: center; - font-style: italic;} - -div.footer {text-align: center; - font-size: 60%;} - -img.cell {align: left;} - -td.sidebar {width: 40px; align: center; valign: top;} -img.sidebar {align: center; margin-top: 5px;} -h4.sidebar {align: center;} - -p.top {background: #FDF1E1; - color: #006600; - position: absolute; - margin-left: -90px; - text-align: center;} - -a:link.sidebar {background: transparent; - color: #990033; - font-weight: bold;} - -a:visited.sidebar {background: transparent; - color: #990033; - font-weight: bold;} - -a:hover.sidebar {background: #FDF1E1; - color: #006600;} - -img {margin: 5px;} - -div {text-align: center;} - -h1 {text-align: center; - font-size: 250%;} - -caption {background: #EEEEEE; - color: #339999;} - -tx {text-align: center;} - -th {background: #FFFFCC; - color: #006600; - text-align: center; - text-decoration: underline; - padding-top: 5px;} - -th.caption {background: #EEEEEE; - color: #006600; - text-align: center;} \ No newline at end of file diff -urN src/contrib/ntp/html/clockopt.html src.ntp/contrib/ntp/html/clockopt.html --- src/contrib/ntp/html/clockopt.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/clockopt.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,68 +0,0 @@ - - - - - - - - Reference Clock Options - - - - -

    Reference Clock Options

    - gif -

    See the radios, all in a row.

    -

    Last update: 18:37 UTC Thursday, July 28, 2005

    -
    -

    Related Links

    - -

    Table of Contents

    - -
    -

    Reference Clock Support

    -

    The NTP Version 4 daemon supports some three dozen different radio, satellite and modem reference clocks plus a special pseudo-clock used for backup or when no other clock source is available. Detailed descriptions of individual device drivers and options can be found in the Reference Clock Drivers page. Additional information can be found in the pages linked there, including the Debugging Hints for Reference Clock Drivers and How To Write a Reference Clock Driver pages. In addition, support for a PPS signal is available as described in Pulse-per-second (PPS) Signal Interfacing page. Many drivers support special line discipline/streams modules which can significantly improve the accuracy using the driver. These are described in the Line Disciplines and Streams Drivers page.

    -

    A reference clock will generally (though not always) be a radio timecode receiver which is synchronized to a source of standard time such as the services offered by the NRC in Canada and NIST and USNO in the US. The interface between the computer and the timecode receiver is device dependent, but is usually a serial port. A device driver specific to each reference clock must be selected and compiled in the distribution; however, most common radio, satellite and modem clocks are included by default. Note that an attempt to configure a reference clock when the driver has not been compiled or the hardware port has not been appropriately configured results in a scalding remark to the system log file, but is otherwise non hazardous.

    -

    For the purposes of configuration, ntpd treats reference clocks in a manner analogous to normal NTP peers as much as possible. Reference clocks are identified by a syntactically correct but invalid IP address, in order to distinguish them from normal NTP peers. Reference clock addresses are of the form 127.127.t.u, where t is an integer denoting the clock type and u indicates the unit number in the range 0-3. While it may seem overkill, it is in fact sometimes useful to configure multiple reference clocks of the same type, in which case the unit numbers must be unique.

    -

    The server command is used to configure a reference clock, where the address argument in that command is the clock address. The key, version and ttl options are not used for reference clock support. The mode option is added for reference clock support, as described below. The prefer option can be useful to persuade the server to cherish a reference clock with somewhat more enthusiasm than other reference clocks or peers. Further information on this option can be found in the Mitigation Rules and the prefer Keyword page. The minpoll and maxpoll options have meaning only for selected clock drivers. See the individual clock driver document pages for additional information.

    -

    The fudge command is used to provide additional information for individual clock drivers and normally follows immediately after the server command. The address argument specifies the clock address. The refid and stratum options control can be used to override the defaults for the device. There are two optional device-dependent time offsets and four flags that can be included in the fudge command as well.

    -

    The stratum number of a reference clock is by default zero. Since the ntpd daemon adds one to the stratum of each peer, a primary server ordinarily displays an external stratum of one. In order to provide engineered backups, it is often useful to specify the reference clock stratum as greater than zero. The stratum option is used for this purpose. Also, in cases involving both a reference clock and a pulse-per-second (PPS) discipline signal, it is useful to specify the reference clock identifier as other than the default, depending on the driver. The refid option is used for this purpose. Except where noted, these options apply to all clock drivers.

    -

    Reference Clock Commands

    -
    -
    server 127.127.t.u [prefer] [mode int] [minpoll int] [maxpoll int] -
    This command can be used to configure reference clocks in special ways. The options are interpreted as follows: -
    -
    prefer -
    Marks the reference clock as preferred. All other things being equal, this host will be chosen for synchronization among a set of correctly operating hosts. See the Mitigation Rules and the prefer Keyword page for further information. -
    mode int -
    Specifies a mode number which is interpreted in a device-specific fashion. For instance, it selects a dialing protocol in the ACTS driver and a device subtype in the parse drivers. -
    minpoll int -
    maxpoll int -
    These options specify the minimum and maximum polling interval for reference clock messages in seconds, interpreted as dual logarithms (2 ^ x). For most directly connected reference clocks, both minpoll and maxpoll default to 6 (2^16 = 64 s). For modem reference clocks, minpoll defaults to 10 (2^10 = 1024 s = 17.1 m) and maxpoll defaults to 14 (2^14 = 16384 s = 4.5 h). The allowable range is 4 (16 s) to 17 (36.4 h) inclusive. -
    -
    fudge 127.127.t.u [time1 sec] [time2 sec] [stratum int] [refid string] [mode int] [flag1 0|1] [flag2 0|1] [flag3 0|1] [flag4 0|1] -
    This command can be used to configure reference clocks in special ways. It must immediately follow the server command which configures the driver. Note that the same capability is possible at run time using the ntpdc program. The options are interpreted as follows: -
    -
    time1 sec -
    Specifies a constant to be added to the time offset produced by the driver, a fixed-point decimal number in seconds. This is used as a calibration constant to adjust the nominal time offset of a particular clock to agree with an external standard, such as a precision PPS signal. It also provides a way to correct a systematic error or bias due to serial port or operating system latencies, different cable lengths or receiver internal delay. The specified offset is in addition to the propagation delay provided by other means, such as internal DIPswitches. Where a calibration for an individual system and driver is available, an approximate correction is noted in the driver documentation pages. -
    Note: in order to facilitate calibration when more than one radio clock or PPS signal is supported, a special calibration feature is available. It takes the form of an argument to the enable command described in the Miscellaneous Options page and operates as described in the Reference Clock Drivers page. -
    time2 secs -
    Specifies a fixed-point decimal number in seconds, which is interpreted in a driver-dependent way. See the descriptions of specific drivers in the reference clock drivers page. -
    stratum int -
    Specifies the stratum number assigned to the driver, an integer between 0 and 15. This number overrides the default stratum number ordinarily assigned by the driver itself, usually zero. -
    refid string -
    Specifies an ASCII string of from one to four characters which defines the reference identifier used by the driver. This string overrides the default identifier ordinarily assigned by the driver itself. -
    mode int -
    Specifies a mode number which is interpreted in a device-specific fashion. For instance, it selects a dialing protocol in the ACTS driver and a device subtype in the parse drivers. -
    flag1 flag2 flag3 flag4 -
    These four flags are used for customizing the clock driver. The interpretation of these values, and whether they are used at all, is a function of the particular clock driver. However, by convention flag4 is used to enable recording monitoring data to the clockstats file configured with the filegen command. Further information on the filegen command can be found in the Monitoring Options page. -
    -
    -
    - - - - diff -urN src/contrib/ntp/html/confopt.html src.ntp/contrib/ntp/html/confopt.html --- src/contrib/ntp/html/confopt.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/confopt.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,82 +0,0 @@ - - - - - - - - Server Options - - - - -

    Server Options

    - giffrom Pogo, Walt Kelly -

    The chicken is getting configuration advice.

    -

    Last update: 20:57 UTC Monday, October 10, 2005

    -
    -

    Related Links

    - -

    Table of Contents

    - -
    -

    Following is a description of the configuration commands in NTPv4. There are two classes of commands, configuration commands that configure an association with a remote server, peer or reference clock, and auxilliary commands that specify environmental variables that control various related operations.

    -

    Configuration Commands

    -

    The various modes are determined by the command keyword and the required IP address. Addresses are classed by type as (s) a remote server or peer (IPv4 class A, B and C), (b) the broadcast address of a local interface, (m) a multicast address (IPv4 class D), or (r) a reference clock address (127.127.x.x). The options that can be used with these commands are listed below.

    -

    If the Basic Socket Interface Extensions for IPv6 (RFC-2553) is detected, support for the IPv6 address family is generated in addition to the default support of the IPv4 address family. IPv6 addresses can be identified by the presence of colons ":" in the address field. IPv6 addresses can be used almost everywhere where IPv4 addresses can be used, with the exception of reference clock addresses, which are always IPv4. Note that in contexts where a host name is expected, a -4 qualifier preceding the host name forces DNS resolution to the IPv4 namespace, while a -6 qualifier forces DNS resolution to the IPv6 namespace.

    -

    There are three types of associations: persistent, preemptable and ephemeral. Persistent associations are mobilized by a configuration command and never demobilized. Preemptable associations, which are new to NTPv4, are mobilized by a configuration command which includes the prempt flag and are demobilized by timeout or error. Ephemeral associations are mobilized upon arrival of designated messages and demobilized by timeout or error.

    -
    -
    server address [options ...]
    - peer address [options ...]
    - broadcast address [options ...]

    - manycastclient address [options ...] -
    These four commands specify the time server name or address to be used and the mode in which to operate. The address can be either a DNS name or a IP address in dotted-quad notation. Additional information on association behavior can be found in the Association Management page. -
    -
    server -
    For type s and r addresses (only), this command normally mobilizes a persistent client mode association with the specified remote server or local reference clock. If the preempt flag is specified, a preemptable association is mobilized instead. In client mode the client clock can synchronize to the remote server or local reference clock, but the remote server can never be synchronized to the client clock. This command should NOT be used for type b or m addresses.
    peer -
    For type s addresses (only), this command mobilizes a persistent symmetric-active mode association with the specified remote peer. In this mode the local clock can be synchronized to the remote peer or the remote peer can be synchronized to the local clock. This is useful in a network of servers where, depending on various failure scenarios, either the local or remote peer may be the better source of time. This command should NOT be used for type b, m or r addresses. -
    broadcast -
    For type b and m addresses (only), this command mobilizes a persistent broadcast mode association. Multiple commands can be used to specify multiple local broadcast interfaces (subnets) and/or multiple multicast groups. Note that local broadcast messages go only to the interface associated with the subnet specified, but multicast messages go to all interfaces. -
    In broadcast mode the local server sends periodic broadcast messages to a client population at the address specified, which is usually the broadcast address on (one of) the local network(s) or a multicast address assigned to NTP. The IANA has assigned the multicast group address IPv4 224.0.1.1 and IPv6 ff05::101 (site local) exclusively to NTP, but other nonconflicting addresses can be used to contain the messages within administrative boundaries. Ordinarily, this specification applies only to the local server operating as a sender; for operation as a broadcast client, see the broadcastclient or multicastclient commands below. -
    manycastclient -
    For type m addresses (only), this command mobilizes a preemptable manycast client mode association for the multicast group address specified. In this mode a specific address must be supplied which matches the address used on the manycastserver command for the designated manycast servers. The NTP multicast address 224.0.1.1 assigned by the IANA should NOT be used, unless specific means are taken to avoid spraying large areas of the Internet with these messages and causing a possibly massive implosion of replies at the sender. -
    The manycastclient command specifies that the host is to operate in client mode with the remote servers that are discovered as the result of broadcast/multicast messages. The client broadcasts a request message to the group address associated with the specified address and specifically enabled servers respond to these messages. The client selects the servers providing the best time and continues as with the server command. The remaining servers are discarded as if never heard. -
    -
    -

    Command Options

    -
    -
    autokey -
    All packets sent to and received from the server or peer are to include authentication fields encrypted using the autokey scheme described in the Authentication Options page. This option is valid with all commands.
    burst -
    When the server is reachable, send a burst of eight packets instead of the usual one. The packet spacing is normally 2 s; however, the spacing between the first and second packets can be changed with the calldelay command to allow additional time for a modem or ISDN call to complete. This option is valid with only the server command and is a recommended option with this command when the maxpoll option is 11 or greater.
    iburst -
    When the server is unreachable, send a burst of eight packets instead of the usual one. The packet spacing is normally 2 s; however, the spacing between the first and second packets can be changed with the calldelay command to allow additional time for a modem or ISDN call to complete. This option is valid with only the server command and is a recommended option with this command.
    key key -
    All packets sent to and received from the server or peer are to include authentication fields encrypted using the specified key identifier with values from 1 to 65534, inclusive. The default is to include no encryption field. This option is valid with all commands.
    minpoll minpoll
    - maxpoll maxpoll -
    These options specify the minimum and maximum poll intervals for NTP messages, in seconds as a power of two. The maximum poll interval defaults to 10 (1,024 s), but can be increased by the maxpoll option to an upper limit of 17 (36.4 h). The minimum poll interval defaults to 6 (64 s), but can be decreased by the minpoll option to a lower limit of 4 (16 s). These option are valid only with the server and peer commands.
    noselect -
    Marks the server as unused, except for display purposes. The server is discarded by the selection algorithm. This option is valid only with the server and peer commands.
    preempt -
    Specifies the association as preemptable rather than the default persistent. This option is valied only with the server command.
    prefer -
    Marks the server as preferred. All other things being equal, this host will be chosen for synchronization among a set of correctly operating hosts. See the Mitigation Rules and the prefer Keyword page for further information. This option is valid only with the server and peer commands.
    true -
    Force the association to assume truechimer status; that is, always survive the selection and clustering algorithms. This option can be used with any association, but is most useful for reference clocks with large jitter on the serial port and precision pulse-per-second (PPS) signals. Caution: this option defeats the algorithms designed to cast out falsetickers and can allow these sources to set the system clock. This option is valid only with the server and peer commands.
    ttl ttl -
    This option is used only with broadcast server and manycast client modes. It specifies the time-to-live ttl to use on broadcast server and multicast server and the maximum ttl for the expanding ring search with manycast client packets. Selection of the proper value, which defaults to 127, is something of a black art and should be coordinated with the network administrator. -
    version version -
    Specifies the version number to be used for outgoing NTP packets. Versions 1-4 are the choices, with version 4 the default. This option is valid only with the server, peer and broadcast commands. -
    -

    Auxilliary Commands

    -
    -
    broadcastclient [novolley] -
    This command enables reception of broadcast server messages to any local interface (type b) address. Ordinarily, upon receiving a message for the first time, the broadcast client measures the nominal server propagation delay using a brief client/server exchange with the server, after which it continues in listen-only mode. If the novolley keyword is present, the exchange is not used and the value specified in the broadcastdelay command is used or, if the broadcastdelay command is not used, the default 4.0 ms. Note that, in order to avoid accidental or malicious disruption in this mode, both the server and client should operate using symmetric key or public key authentication as described in the Authentication Options page. Note that the novolley keyword is incompatible with public key authentication.
    manycastserver address [...] -
    This command enables reception of manycast client messages to the multicast group address(es) (type m) specified. At least one address is required. The NTP multicast address 224.0.1.1 assigned by the IANA should NOT be used, unless specific means are taken to limit the span of the reply and avoid a possibly massive implosion at the original sender. Note that, in order to avoid accidental or malicious disruption in this mode, both the server and client should operate using symmetric key or public key authentication as described in the Authentication Options page. -
    multicastclient address [...] -
    This command enables reception of multicast server messages to the multicast group address(es) (type m) specified. Upon receiving a message for the first time, the multicast client measures the nominal server propagation delay using a brief client/server exchange with the server, then enters the broadcast client mode, in which it synchronizes to succeeding multicast messages. Note that, in order to avoid accidental or malicious disruption in this mode, both the server and client should operate using symmetric key or public key authentication as described in the Authentication Options page. -
    -

    Bugs

    -

    The syntax checking is not picky; some combinations of ridiculous and even hilarious options and modes may not be detected.

    -
    - - - - diff -urN src/contrib/ntp/html/copyright.html src.ntp/contrib/ntp/html/copyright.html --- src/contrib/ntp/html/copyright.html 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/html/copyright.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,96 +0,0 @@ - - - - - - - Copyright Notice - - - - -

    Copyright Notice

    - jpg "Clone me," says Dolly sheepishly -

    Last update: 20:31 UTC Saturday, January 06, 2007

    -
    -
    -

    The following copyright notice applies to all files collectively called the Network Time Protocol Version 4 Distribution. Unless specifically declared otherwise in an individual file, this notice applies as if the text was explicitly included in the file.
    -

    -
    -***********************************************************************
    -*                                                                     *
    -* Copyright (c) David L. Mills 1992-2009                              *
    -*                                                                     *
    -* Permission to use, copy, modify, and distribute this software and   *
    -* its documentation for any purpose with or without fee is hereby     *
    -* granted, provided that the above copyright notice appears in all    *
    -* copies and that both the copyright notice and this permission       *
    -* notice appear in supporting documentation, and that the name        *
    -* University of Delaware not be used in advertising or publicity      *
    -* pertaining to distribution of the software without specific,        *
    -* written prior permission. The University of Delaware makes no       *
    -* representations about the suitability this software for any         *
    -* purpose. It is provided "as is" without express or implied          *
    -* warranty.                                                           *
    -*                                                                     *
    -***********************************************************************
    -
    -

    The following individuals contributed in part to the Network Time Protocol Distribution Version 4 and are acknowledged as authors of this work.

    -
      -
    1. Mark Andrews <mark_andrews@isc.org> Leitch atomic clock controller -
    2. Bernd Altmeier <altmeier@atlsoft.de> hopf Elektronik serial line and PCI-bus devices -
    3. Viraj Bais <vbais@mailman1.intel.com> and Clayton Kirkwood <kirkwood@striderfm.intel.com> port to WindowsNT 3.5 -
    4. Michael Barone <michael,barone@lmco.com> GPSVME fixes -
    5. Jean-Francois Boudreault <Jean-Francois.Boudreault@viagenie.qc.ca>IPv6 support -
    6. Karl Berry <karl@owl.HQ.ileaf.com> syslog to file option -
    7. Greg Brackley <greg.brackley@bigfoot.com> Major rework of WINNT port. Clean up recvbuf and iosignal code into separate modules. -
    8. Marc Brett <Marc.Brett@westgeo.com> Magnavox GPS clock driver -
    9. Piete Brooks <Piete.Brooks@cl.cam.ac.uk> MSF clock driver, Trimble PARSE support -
    10. Reg Clemens <reg@dwf.com> Oncore driver (Current maintainer) -
    11. Steve Clift <clift@ml.csiro.au> OMEGA clock driver -
    12. Casey Crellin <casey@csc.co.za> vxWorks (Tornado) port and help with target configuration -
    13. Sven Dietrich <sven_dietrich@trimble.com> Palisade reference clock driver, NT adj. residuals, integrated Greg's Winnt port. -
    14. John A. Dundas III <dundas@salt.jpl.nasa.gov> Apple A/UX port -
    15. Torsten Duwe <duwe@immd4.informatik.uni-erlangen.de> Linux port -
    16. Dennis Ferguson <dennis@mrbill.canet.ca> foundation code for NTP Version 2 as specified in RFC-1119 -
    17. John Hay <jhay@@icomtek.csir.co.za> IPv6 support and testing -
    18. Glenn Hollinger <glenn@herald.usask.ca> GOES clock driver -
    19. Mike Iglesias <iglesias@uci.edu> DEC Alpha port -
    20. Jim Jagielski <jim@jagubox.gsfc.nasa.gov> A/UX port -
    21. Jeff Johnson <jbj@chatham.usdesign.com> massive prototyping overhaul -
    22. Hans Lambermont <Hans.Lambermont@nl.origin-it.com> or <H.Lambermont@chello.nl> ntpsweep -
    23. Poul-Henning Kamp <phk@FreeBSD.ORG> Oncore driver (Original author) -
    24. Frank Kardel <kardel (at) ntp (dot) org> PARSE <GENERIC> driver (>14 reference clocks), STREAMS modules for PARSE, support scripts, syslog cleanup, dynamic interface handling -
    25. William L. Jones <jones@hermes.chpc.utexas.edu> RS/6000 AIX modifications, HPUX modifications -
    26. Dave Katz <dkatz@cisco.com> RS/6000 AIX port -
    27. Craig Leres <leres@ee.lbl.gov> 4.4BSD port, ppsclock, Magnavox GPS clock driver -
    28. George Lindholm <lindholm@ucs.ubc.ca> SunOS 5.1 port -
    29. Louis A. Mamakos <louie@ni.umd.edu> MD5-based authentication -
    30. Lars H. Mathiesen <thorinn@diku.dk> adaptation of foundation code for Version 3 as specified in RFC-1305 -
    31. Danny Mayer <mayer@ntp.org>Network I/O, Windows Port, Code Maintenance -
    32. David L. Mills <mills@udel.edu> Version 4 foundation: clock discipline, authentication, precision kernel; clock drivers: Spectracom, Austron, Arbiter, Heath, ATOM, ACTS, KSI/Odetics; audio clock drivers: CHU, WWV/H, IRIG -
    33. Wolfgang Moeller <moeller@gwdgv1.dnet.gwdg.de> VMS port -
    34. Jeffrey Mogul <mogul@pa.dec.com> ntptrace utility -
    35. Tom Moore <tmoore@fievel.daytonoh.ncr.com> i386 svr4 port -
    36. Kamal A Mostafa <kamal@whence.com> SCO OpenServer port -
    37. Derek Mulcahy <derek@toybox.demon.co.uk> and Damon Hart-Davis <d@hd.org> ARCRON MSF clock driver -
    38. Rainer Pruy <Rainer.Pruy@informatik.uni-erlangen.de> monitoring/trap scripts, statistics file handling -
    39. Dirce Richards <dirce@zk3.dec.com> Digital UNIX V4.0 port -
    40. Wilfredo Sánchez <wsanchez@apple.com> added support for NetInfo -
    41. Nick Sayer <mrapple@quack.kfu.com> SunOS streams modules -
    42. Jack Sasportas <jack@innovativeinternet.com> Saved a Lot of space on the stuff in the html/pic/ subdirectory -
    43. Ray Schnitzler <schnitz@unipress.com> Unixware1 port -
    44. Michael Shields <shields@tembel.org> USNO clock driver -
    45. Jeff Steinman <jss@pebbles.jpl.nasa.gov> Datum PTS clock driver -
    46. Harlan Stenn <harlan@pfcs.com> GNU automake/autoconfigure makeover, various other bits (see the ChangeLog) -
    47. Kenneth Stone <ken@sdd.hp.com> HP-UX port -
    48. Ajit Thyagarajan <ajit@ee.udel.edu>IP multicast/anycast support -
    49. Tomoaki TSURUOKA <tsuruoka@nc.fukuoka-u.ac.jp>TRAK clock driver -
    50. Paul A Vixie <vixie@vix.com> TrueTime GPS driver, generic TrueTime clock driver -
    51. Ulrich Windl <Ulrich.Windl@rz.uni-regensburg.de> corrected and validated HTML documents according to the HTML DTD -
    -
    - - - - diff -urN src/contrib/ntp/html/debug.html src.ntp/contrib/ntp/html/debug.html --- src/contrib/ntp/html/debug.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/debug.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,172 +0,0 @@ - - - - - - - - NTP Debugging Techniques - - - - -

    NTP Debugging Techniques

    - giffrom Pogo, Walt Kelly -

    We make house calls and bring our own bugs.

    -

    Last update: 18:38 UTC Thursday, July 28, 2005

    -
    -

    More Help

    - -
    -

    Once the NTP software distribution has been compiled and installed and the configuration file constructed, the next step is to verify correct operation and fix any bugs that may result. Usually, the command line that starts the daemon is included in the system startup file, so it is executed only at system boot time; however, the daemon can be stopped and restarted from root at any time. Usually, no command-line arguments are required, unless special actions described in the ntpd - Network Time Protocol (NTP) daemon page are required. Once started, the daemon will begin sending and receiving messages, as specified in the configuration file.

    -

    Initial Startup

    -

    When started for the first time, the frequency file, usually called ntp.drift, has not yet been created. The daemon switches to a special training routine designed to quickly determine the system clock frequency offset of the particular machine. The routine first measures the current clock offset and sets the clock, then continues for up to twenty minutes before measuring the clock offset, which might involve setting the clock again. The two measurements are used to compute the initial frequency offset and the daemon continues in regular operation, during which the frequency offset is continuously updated. Once each hour the daemon writes the current frequency offset to the ntp.drift file. When restarted after that, the daemon reads the frequency offset from the ntp.drift file and avoids the training routine.

    -

    Note that the daemon requires at least four packet exchanges when first started in any case. This is required in order for the mitigation algorithms to insure valid and accurate measurements and defend against network delay spikes and accidental or malicious errors induced by the servers selected in the configuration file. It normally takes less than four minutes to set the clock when first started, but this can be reduced to less than ten seconds with the iburst configuration option.

    -

    The best way to verify correct operation is using the ntpq - standard NTP query program and ntpdc - special NTP query program utility programs, either on the server itself or from another machine elsewhere in the network. The ntpq program implements the management functions specified in the NTP specification RFC-1305, Appendix A. The ntpdc program implements additional functions not provided in the standard. Both programs can be used to inspect the state variables defined in the specification and, in the case of ntpdc, additional ones intended for serious debugging. In addition, the ntpdc program can be used to selectively reconfigure and enable or disable some functions while the daemon is running.

    -

    In extreme cases with elusive bugs, the daemon can operate in two modes, depending on the presence of the -d command-line debug switch. If not present, the daemon detaches from the controlling terminal and proceeds autonomously. If one or more -d switches are present, the daemon does not detach and generates special output useful for debugging. In general, interpretation of this output requires reference to the sources. However, a single -d does produce only mildly cryptic output and can be very useful in finding problems with configuration and network troubles. With a little experience, the volume of output can be reduced by piping the output to grep and specifying the keyword of the trace you want to see.

    -

    Some problems are immediately apparent when the daemon first starts running. The most common of these are the lack of a UDP port for NTP (123) in the Unix /etc/services file (or equivalent in some systems). Note that NTP does not use TCP in any form. Also note that NTP requires 123 for both source and destination ports. These facts should be pointed out to firewall administrators.

    -

    Other problems are apparent in the system log, which ordinarily shows the startup banner, some cryptic initialization data and the computed precision value. Error messages at startup and during regular operation are sent to the system log. In real emergencies the daemon will sent a terminal error message to the system log and then cease operation.

    -

    The next most common problem is incorrect DNS names. Check that each DNS name used in the configuration file exists and that the address responds to the Unix ping command. The Unix traceroute or Windows tracert utility can be used to verify a partial or complete path exists. Most problems reported to the NTP newsgroup are not NTP problems, but problems with the network or firewall configuration.

    -

    When first started, the daemon polls the servers listed in the configuration file at 64-s intervals. In order to allow a sufficient number of samples for the NTP algorithms to reliably discriminate between truechimer servers and possible falsetickers, at least four valid messages from at least one server or peer listed in the configuration file is required before the daemon can set the clock. However, if the difference between the client time and server time is greater than the panic threshold, which defaults to 1000 s, the daemon sends a message to the system log and shuts down without setting the clock. It is necessary to set the local clock to within the panic threshold first, either manually by eyeball and wristwatch and the Unix date command, or by the ntpdate or ntpd -q commands. The panic threshold can be changed by the tinker panic command discribed on the Miscellaneous Options page. The panic threshold can be disabled for the first measurement by the -g command line option described on the ntpd - Network Time Protocol (NTP) daemon page.

    -

    If the difference between local time and server time is less than the panic threshold but greater than the step threshold, which defaults to 128 ms, the daemon will perform a step adjustment; otherwise, it will gradually slew the clock to the nominal time. Step adjustments are extremely rare in ordinary operation, usually as the result of reboot or hardware failure. The step threshold can be changed to 300 s using the -x command line option described on the ntpd page. This is usually sufficient to avoid a step after reboot or when the operator has set the system clock to within five minutes by eyeball-and-wristwatch. In extreme cases the step threshold can be changed by the tinker step command discribed on the Miscellaneous Options page. If set to zero, the clock will never be stepped; however, users should understand the implications for doing this in a distributed data network where all processing must be tightly synchronized. See the NTP Timescale and Leap Seconds page for further information. If a step adjustment is made, the clock discipline algorithm will start all over again, requiring another round of at least four messages as before. This is necessary so that all servers and peers operate on the same set of time values.

    -

    The clock discipline algorithm is designed to avoid large noise spikes that might occur on a congested network or access line. If an offset sample exceeds the step threshold, it is ignored and a timer started. If a later sample is below the step threshold, the counter is reset and operation continues normally. However, if the counter is greater than the stepout interval, which defaults to 900 s, the next sample will step the time as directed. The stepout threshold can be changed by the tinker stepout command discribed on the Miscellaneous Options page.

    -

    If for some reason the hardware clock oscillator frequency error is very large, say over 400 PPM, the time offset when the daemon is started for the first time may increase over time until exceeding the step threshold, which requires a frequency adjustment and another step correction. However, due to provisions that reduce vulnerability to noise spikes, the second correction will not be done until after the stepout threshold. When the frequency error is very large, it may take a number of cycles like this until converging to the nominal frequency correction and writing the ntp.drift file. If the frequency error is over 500 PPM, convergence will never occur and occasional step adjustments will occur indefinitely.

    -

    Verifying Correct Operation

    -

    After starting the daemon, run the ntpq program using the -n switch, which will avoid possible distractions due to name resolution problems. Use the pe command to display a billboard showing the status of configured peers and possibly other clients poking the daemon. After operating for a few minutes, the display should be something like:

    -
    -ntpq> pe
    -     remote      refid       st t when poll reach delay offset jitter
    -=====================================================================
    --isipc6.cairn.ne .GPS1.        1 u  18  64  377  65.592 -5.891  0.044
    -+saicpc-isiepc2. pogo.udel.edu 2 u 241 128  370  10.477 -0.117  0.067
    -+uclpc.cairn.net pogo.udel.edu 2 u  37  64  177 212.111 -0.551  0.187
    -*pogo.udel.edu   .GPS1.        1 u  95 128  377   0.607  0.123  0.027
    -
    -

    The host names or addresses shown in the remote column correspond to the server and peer entries listed in the configuration file; however, the DNS names might not agree if the names listed are not the canonical DNS names. IPv4 addresses are shown in dotted quad notation, while IPv6 addresses are shown alarmingly. The refid column shows the current source of synchronization, while the st column reveals the stratum, t the type (u = unicast, m = multicast, l = local, - = don't know), and poll the poll interval in seconds. The when column shows the time since the peer was last heard in seconds, while the reach column shows the status of the reachability register (see RFC-1305) in octal. The remaining entries show the latest delay, offset and jitter in milliseconds. Note that in NTP Version 4 what used to be the dispersion column has been replaced by the jitter column.

    -

    As per the NTP specification RFC-1305, when the stratum is between 0 and 15 for a NTP server, the refid field shows the server DNS name or, if not found, the IP address in dotted-quad. When the stratum is any value for a reference clock, this field shows the identification string assigned to the clock. However, until the client has synchronized to a server, or when the stratum for a NTP server is 0 (appears as 16 in the billboards), the status cannot be determined. As a help in debugging, the refid field is set to a four-character string called the kiss code. The current kiss codes are as as follows.

    -

    Peer Kiss Codes

    -

    ACST

    -
    -
    The association belongs to a anycast server. -
    AUTH -
    Server authentication failed. Please wait while the association is restarted. -
    AUTO -
    Autokey sequence failed. Please wait while the association is restarted. -
    BCST -
    The association belongs to a broadcast server. -
    CRYP -
    Cryptographic authentication or identification failed. The details should be in the system log file or the cryptostats statistics file, if configured. No further messages will be sent to the server. -
    DENY -
    Access denied by remote server. No further messages will be sent to the server. -
    DROP -
    Lost peer in symmetric mode. Please wait while the association is restarted. -
    RSTR -
    Access denied due to local policy. No further messages will be sent to the server. -
    INIT -
    The association has not yet synchronized for the first time. -
    MCST -
    The association belongs to a manycast server. -
    NKEY -
    No key found. Either the key was never installed or is not trusted. -
    RATE -
    Rate exceeded. The server has temporarily denied access because the client exceeded the rate threshold. -
    RMOT -
    Somebody is tinkering with the association from a remote host running ntpdc. Not to worry unless some rascal has stolen your keys. -
    STEP -
    A step change in system time has occurred, but the association has not yet resynchronized. -
    -

    System Kiss Codes

    -
    -
    INIT -
    The system clock has not yet synchronized for the first time. -
    STEP -
    A step change in system time has occurred, but the system clock has not yet resynchronized. -
    -

    The tattletale symbol at the left margin displays the synchronization status of each peer. The currently selected peer is marked *, while additional peers designated acceptable for synchronization are marked +. Peers marked * and + are included in the weighted average computation to set the local clock; the data produced by peers marked with other symbols are discarded. See the ntpq page for the meaning of these symbols.

    -

    Additional details for each peer separately can be determined by the following procedure. First, use the as command to display an index of association identifiers, such as

    -
    -ntpq> as
    -ind assID status  conf reach auth condition  last_event cnt
    -===========================================================
    -  1 50252  f314   yes   yes   ok    outlyer   reachable  1
    -  2 50253  f414   yes   yes   ok   candidat   reachable  1
    -  3 50254  f414   yes   yes   ok   candidat   reachable  1
    -  4 50255  f614   yes   yes   ok   sys.peer   reachable  1
    -
    -

    Each line in this billboard is associated with the corresponding line in the pe billboard above. The assID shows the unique identifier for each mobilized association, while the status column shows the peer status word in hex, as defined in the NTP specification. Next, use the rv command and the respective assID identifier to display a detailed synopsis for the selected peer, such as

    -
    -ntpq> rv 50253
    -status=f414 reach, conf, auth, sel_candidat, 1 event, event_reach,
    -srcadr=saicpc-isiepc2.cairn.net, srcport=123, dstadr=140.173.1.46,
    -dstport=123, keyid=3816249004, stratum=2, precision=-27,
    -rootdelay=10.925, rootdispersion=12.848, refid=pogo.udel.edu,
    -reftime=bd11b225.133e1437  Sat, Jul  8 2000 13:59:01.075, delay=10.550,
    -offset=-1.357, jitter=0.074, dispersion=1.444, reach=377, valid=7,
    -hmode=1, pmode=1, hpoll=6, ppoll=7, leap=00, flash=00 ok,
    -org=bd11b23c.01385836  Sat, Jul  8 2000 13:59:24.004,
    -rec=bd11b23c.02dc8fb8  Sat, Jul  8 2000 13:59:24.011,
    -xmt=bd11b21a.ac34c1a8  Sat, Jul  8 2000 13:58:50.672,
    -filtdelay=   10.45  10.50  10.63  10.40  10.48  10.43  10.49  11.26,
    -filtoffset=  -1.18  -1.26  -1.26  -1.35  -1.35  -1.42  -1.54  -1.81,
    -filtdisp=     0.51   1.47   2.46   3.45   4.40   5.34   6.33   7.28,
    -hostname="miro.time.saic.com", signature=md5WithRSAEncryption, flags=0x83f01, initsequence=61, initkey=0x287b649c,
    -timestamp=3172053041
    -
    -

    A detailed explanation of the fields in this billboard are beyond the scope of this discussion; however, most variables defined in the NTP Version 3 specification RFC-1305 are available along with others defined for NTPv4 on the ntpq page. This particular example was chosen to illustrate probably the most complex configuration involving symmetric modes and public-key cryptography. As the result of debugging experience, the names and values of these variables may change from time to time.

    -

    A useful indicator of miscellaneous problems is the flash value, which reveals the state of the various sanity tests on incoming packets. There are currently 12 bits, one for each test, numbered from the right, which is for test 1. If the test fails, the corresponding bit is set to one and zero otherwise. If any bit is set following each processing step, the packet is discarded. The meaning of each test is described on the ntpq page.

    -

    The three lines identified as filtdelay, filtoffset and filtdisp reveal the roundtrip delay, clock offset and dispersion for each of the last eight measurement rounds, all in milliseconds. Note that the dispersion, which is an estimate of the error, increases as the age of the sample increases. From these data, it is usually possible to determine the incidence of severe packet loss, network congestion, and unstable local clock oscillators. There are no hard and fast rules here, since every case is unique; however, if one or more of the rounds show large values or change radically from one round to another, the network is probably congested or lossy.

    -

    Once the daemon has set the local clock, it will continuously track the discrepancy between local time and NTP time and adjust the local clock accordingly. There are two components of this adjustment, time and frequency. These adjustments are automatically determined by the clock discipline algorithm, which functions as a hybrid phase/frequency feedback loop. The behavior of this algorithm is carefully controlled to minimize residual errors due to network jitter and frequency variations of the local clock hardware oscillator that normally occur in practice. However, when started for the first time, the algorithm may take some time to converge on the intrinsic frequency error of the host machine.

    -

    The state of the local clock itself can be determined using the rv command (without the argument), such as

    -
    -ntpq> rv
    -status=0644 leap_none, sync_ntp, 4 events, event_peer/strat_chg,
    -version="ntpd 4.0.99j4-r Fri Jul  7 23:38:17 GMT 2000 (1)",
    -processor="i386", system="FreeBSD3.4-RELEASE", leap=00, stratum=2,
    -precision=-27, rootdelay=0.552, rootdispersion=12.532, peer=50255,
    -refid=pogo.udel.edu,
    -reftime=bd11b220.ac89f40a  Sat, Jul  8 2000 13:58:56.673, poll=6,
    -clock=bd11b225.ee201472  Sat, Jul  8 2000 13:59:01.930, state=4,
    -phase=0.179, frequency=44.298, jitter=0.022, stability=0.001,
    -hostname="barnstable.udel.edu", signature=md5WithRSAEncryption,
    -flags=0x80011, hostkey=3171372095, refresh=3172016539
    -cert="grundoon.udel.edu grundoon.udel.edu 0x3 3233600829"
    -cert="whimsy.udel.edu whimsy.udel.edu 0x5 3233682156"
    -
    -

    An explanation about most of these variables is in the RFC-1305 specification. The most useful ones include clock, which shows when the clock was last adjusted, and reftime, which shows when the server clock of refid was last adjusted. The version, processor and system values are very helpful when included in bug reports. The mean millisecond time offset (phase) and deviation (jitter) monitor the clock quality, while the mean PPM frequency offset (frequency) and deviation (stability) monitor the clock stability and serve as a useful diagnostic tool. It has been the experience of NTP operators over the years that these data represent useful environment and hardware alarms. If the motherboard fan freezes up or some hardware bit sticks, the system clock is usually the first to notice it.

    -

    Among the new variables added for NTP Version 4 are the hostname, signature, flags, hostkey, refresh and cert, which are used for the Autokey public-key cryptography described on the Authentication Options page. The numeric values show the filestamps, in NTP seconds, that the associated media files were created. These are useful in diagnosing problems with cryptographic key consistency and ordering principles.

    -

    When nothing seems to happen in the pe billboard after some minutes, there may be a network problem. One common network problem is an access controlled router on the path to the selected peer or an access controlled server using methods described on the Access Control Options page. Another common problem is that the server is down or running in unsynchronized mode due to a local problem. Use the ntpq program to spy on the server variables in the same way you can spy on your own.

    -

    Normally, the daemon will adjust the local clock in small steps in such a way that system and user programs are unaware of its operation. The adjustment process operates continuously unless the apparent clock error exceeds the step threshold for a period longer than the stepout threshold, which for most Internet paths is a very rare event. If the event is simply an outlyer due to an occasional network delay spike, the correction is simply discarded; however, if the apparent time error persists for longer than the stepout threshold of about 17 minutes, the local clock is stepped or slewed to the new value as directed. This behavior is designed to resist errors due to severely congested network paths, as well as errors due to confused radio clocks upon the epoch of a leap second.

    -

    Large Frequency Errors

    -

    The frequency tolerance of computer clock oscillators can vary widely, which can put a strain on the daemon's ability to compensate for the intrinsic frequency error. While the daemon can handle frequency errors up to 500 parts-per-million (PPM), or 43 seconds per day, values much above 100 PPM reduce the headroom and increase the time to learn the particular value and record it in the ntp.drift file. In extreme cases before the particular oscillator frequency error has been determined, the residual system time offsets can sweep from one extreme to the other of the 128-ms tracking window only for the behavior to repeat at 900-s intervals until the measurements have converged.

    -

    In order to determine if excessive frequency error is a problem, observe the nominal filtoffset values for a number of rounds and divide by the poll interval. If the result is something approaching 500 PPM, there is a good chance that NTP will not work properly until the frequency error is reduced by some means. A common cause is the hardware time-of-year (TOY) clock chip, which must be disabled when NTP disciplines the software clock. For some systems this can be done using the tickadj utility and the -s command line argument. For other systems this can be done using a command in the system startup file.

    -

    If the TOY chip is not the cause, the problem may be that the hardware clock frequency may simply be too slow or two fast. In some systems this might require tweaking a trimmer capacitor on the motherboard. For other systems the clock frequency can be adjusted in increments of 100 PPM using the tickadj utility and the -t command line argument. Note that the tickadj alters certain kernel variables and, while the utility attempts to figure out an acceptable way to do this, there are many cases where tickadj is incompatible with a running kernel.

    -

    Access Controls

    -

    Provisions are included in ntpd for access controls which deflect unwanted traffic from selected hosts or networks. The controls described on the Access Control Options include detailed packet filter operations based on source address and address mask. Normally, filtered packets are dropped without notice other than to increment tally counters. However, the server can be configured to send a "kiss-o'-death" (KOD) packet to the client either when explicitly configured or when cryptographic authentication fails for some reason. The client association is permanently disabled, the access denied bit (TEST4) is set in the flash variable and a message is sent to the system log.

    -

    The access control provisions include a limit on the packet rate from a host or network. If an incoming packet exceeds the limit, it is dropped and a KOD sent to the source. If this occurs after the client association has synchronized, the association is not disabled, but a message is sent to the system log. See the Access Control Options page for further informatin.

    -

    Large Delay Variations

    -

    In some reported scenarios an access line may show low to moderate network delays during some period of the day and moderate to high delays during other periods. Often the delay on one direction of transmission dominates, which can result in large time offset errors, sometimes in the range up to a few seconds. It is not usually convenient to run ntpd throughout the day in such scenarios, since this could result in several time steps, especially if the condition persists for greater than the stepout threshold.

    -

    Specific provisions have been built into ntpd to cope with these problems. The scheme is called "huff-'n-puff and is described on the Miscellaneous Options page. An alternative approach in such scenarios is first to calibrate the local clock frequency error by running ntpd in continuous mode during the quiet interval and let it write the frequency to the ntp.drift file. Then, run ntpd -q from a cron job each day at some time in the quiet interval. In systems with the nanokernel or microkernel performance enhancements, including Solaris, Tru64, Linux and FreeBSD, the kernel continuously disciplines the frequency so that the residual correction produced by ntpd is usually less than a few milliseconds.

    -

    Cryptographic Authentication

    -

    Reliable source authentication requires the use of symmetric key or public key cryptography, as described on the Authentication Options page. In symmetric key cryptography servers and clients share session keys contained in a secret key file In public key cryptography, which requires the OpenSSL software library, the server has a private key, never shared, and a public key with unrestricted distribution. The cryptographic media required are produced by the ntp-keygen program.

    -

    Problems with symmetric key authentication are usually due to mismatched keys or improper use of the trustedkey command. A simple way to check for problems is to use the trace facility, which is enabled using the ntpd -d command line. As each packet is received a trace line is displayed which shows the authentication status in the auth field. A status of 1 indicates the packet was successful authenticated; otherwise it has failed.

    -

    A common misconception is the implication of the auth bit in the enable and disable commands. This bit does not affect authentication in any way other than to enable or disable mobilization of a new persistent association in broadcast/multicast client, manycast client or symmetric passive modes. If enabled, which is the default, these associations require authentication; if not, an association is mobilized even if not authenticated. Users are cautioned that running with authentication disabled is very dangerous, since an intruder can easily strike up an association and inject false time values.

    -

    Public key cryptography is supported in NTPv4 using the Autokey protocol, which is described in briefings on the NTP Project page linked from www.ntp.org. Development of this protocol is mature and the ntpd implementation is basically complete. Autokey version 2, which is the latest and current version, includes provisions to hike certificate trails, operate as certificate authorities and verify identity using challenge/response identification schemes. Further details of the protocol are on the Authentication Options page. Common problems with configuration and key generation are mismatched key files, broken links and missing or broken random seed file.

    -

    As in the symmetric key cryptography case, the trace facility is a good way to verify correct operation. A statistics file cryptostats records protocol transactions and error messages. The daemon requires a random seed file, public/private key file and a valid certificate file; otherwise it exits immediately with a message to the system log. As each file is loaded a trace message appears with its filestamp. There are a number of checks to insure that only consistent data are used and that the certificate is valid. When the protocol is in operation a number of checks are done to verify the server has the expected credentials and its filestamps and timestamps are consistent. Errors found are reported using NTP control and monitoring protocol traps with extended trap codes shown in the Authentication Options page.

    -

    To assist debugging every NTP extension field is displayed in the trace along with the Autokey operation code. Every extension field carrying a verified signature is identified and displayed along with filestamp and timestamp where meaningful. In all except broadcast/multicast client mode, correct operation of the protocol is confirmed by the absence of extension fields and an auth value of one. It is normal in broadcast/multicast client mode that the broadcast server use one extension field to show the host name, status word and association ID.

    -

    Debugging Checklist

    -

    If the ntpq or ntpdc programs do not show that messages are being received by the daemon or that received messages do not result in correct synchronization, verify the following:

    -
      -
    1. Verify the /etc/services file host machine is configured to accept UDP packets on the NTP port 123. NTP is specifically designed to use UDP and does not respond to TCP. -
    2. Check the system log for ntpd messages about configuration errors, name-lookup failures or initialization problems. Common system log messages are summarized on the ntpd System Log Messages page. Check to be sure that only one copy of ntpd is running. -
    3. Verify using ping or other utility that packets actually do make the round trip between the client and server. Verify using nslookup or other utility that the DNS server names do exist and resolve to valid Internet addresses. -
    4. Check that the remote NTP server is up and running. The usual evidence that it is not is a Connection refused message. -
    5. Using the ntpdc program, verify that the packets received and packets sent counters are incrementing. If the sent counter does not increment and the configuration file includes configured servers, something may be wrong in the host network or interface configuration. If this counter does increment, but the received counter does not increment, something may be wrong in the network or the server NTP daemon may not be running or the server itself may be down or not responding. -
    6. If both the sent and received counters do increment, but the reach values in the pe billboard with ntpq continues to show zero, received packets are probably being discarded for some reason. If this is the case, the cause should be evident from the flash variable as discussed above and on the ntpq page. It could be that the server has disabled access for the client address, in which case the refid field in the ntpq pe billboard will show a kiss code. See earlier on this page for a list of kiss codes and their meaning. -
    7. If the reach values in the pe billboard show the servers are alive and responding, note the tattletale symbols at the left margin, which indicate the status of each server resulting from the various grooming and mitigation algorithms. The interpretation of these symbols is discussed on the ntpq page. After a few minutes of operation, one or another of the reachable server candidates should show a * tattletale symbol. If this doesn't happen, the intersection algorithm, which classifies the servers as truechimers or falsetickers, may be unable to find a majority of truechimers among the server population. -
    8. If all else fails, see the FAQ and/or the discussion and briefings at the NTP Project page. -
    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver1.html src.ntp/contrib/ntp/html/drivers/driver1.html --- src/contrib/ntp/html/drivers/driver1.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver1.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,65 +0,0 @@ - - - - - - - - Undisciplined Local Clock - - - - -

    Undisciplined Local Clock

    -
    -

    Synopsis

    -

    Address: 127.127.1.u
    - Reference ID: LCL
    - Driver ID: LOCAL

    -

    Description

    -

    This driver is intended for use in an isolated network where no external source of synchronization such as a radio clock or modem is available. It allows a designated time server to act as a primary server to provide synchronization to other clients on the network. Pick a machine that has a good clock oscillator (Digital machines are good, Sun machines are not) and configure it with this driver. Set the clock using the best means available, like eyeball-and-wristwatch. Then, point all the other machines at this one or use broadcast (not multicast) mode to distribute time.

    -

    Another application for this driver is if a particular server clock is to be used as the clock of last resort when all other normal synchronization sources have gone away. This is especially useful if that server has an ovenized oscillator. For this you would configure this driver at a stratum greater than any other likely sources of time (say 3 or 4) to prevent the server taking over when legitimate sources are still available.

    -

    A third application for this driver is when an external discipline source is available, such as the NIST lockclock program, which synchronizes the local clock via a telephone modem and the NIST Automated Computer Time Service (ACTS), or the Digital Time Synchronization Service (DTSS), which runs on DCE machines. In this case the stratum should be set at zero, indicating a bona fide stratum-1 source. In the case of DTSS, the local clock can have a rather large jitter, depending on the interval between corrections and the intrinsic frequency error of the clock oscillator. In extreme cases, this can cause clients to exceed the 128-ms slew window and drop off the NTP subnet.

    -

    In the case where a NTP time server is synchronized to some device or protocol that is not external to the NTP daemon itself, some means should be provided to pass such things as error and health values to the NTP daemon for dissemination to its clients. If this is not done, there is a very real danger that the device or protocol could fail and with no means to tell NTP clients of the mishap. When ordinary Unix system calls like adjtime() are used to discipline the kernel clock, there is no obvious way this can be done without modifying the code for each case. However, when a modified kernel with the ntp_adjtime() system call  is available, that routine can be used for the same purpose as the adjtime() routine and in addition provided with the estimated error, maximum error, and leap-indicator values. This is the preferred way to synchronize the kernel clock and pass information to the NTP clients.

    -

    In the default mode the behavior of the clock selection algorithm is modified when this driver is in use. The algorithm is designed so that this driver will never be selected unless no other discipline source is available. This can be overridden with the prefer keyword of the server configuration command, in which case only this driver will be selected for synchronization and all other discipline sources will be ignored. This behavior is intended for use when an external discipline source controls the system clock. See the Mitigation Rules and the prefer Keyword page for a detailed description of the exact behavior.

    -

    The stratum for this driver is set at 5 by default, but can be changed by the fudge configuration command and/or the ntpdc utility. The reference ID is LCL by default, but can be changed using the same mechanisms. *NEVER* configure this driver to operate at a stratum which might possibly disrupt a client with access to a bona fide primary server, unless the local clock oscillator is reliably disciplined by another source. *NEVER NEVER* configure a server which might devolve to an undisciplined local clock to use multicast mode.

    -

    This driver provides a mechanism to trim the local clock in both time and frequency, as well as a way to manipulate the leap bits. The fudge time1 parameter adjusts the time (in seconds) and the fudge time2 parameter adjusts the frequency (in parts per million). Both parameters are additive and operate only once; that is, each command (as from ntpdc) adds signed increments in time or frequency to the nominal local clock time and frequency.

    -

    Operation with an External Reference Source

    -

    There are special provisions for this driver to operate in conjunction with an external reference source, such as the LOCKCLOCK scheme used by the NIST time servers. In such schemes the system clock is disciplined by a source external to NTP, in the LOCKCLOCK case an ACTS telephone modem. To support LOCKCLOCK the NTP distribution should be built with the --enable-nist parameter in the configuration phase of the build procedure. This changes the system behavior as follows:

    -
      -
    1. The system clock is not disciplined in any way other than to call the ntp_adjtime() system call to obtain the kernel leap code, which becomes the driver leap code and. If the kernel leap code is 11 (not synchronized), the driver stratum is infinity; otherwise the stratum is set by the stratum subcommand on the fudge command applying to the driver. -
    2. The NTP algorithms operate in the normal fashion with this driver and possibly other drivers and servers; however, the local clock driver as the prefer peer will always be selected, even if declared falseticker by the selection algorithm or fails to survive the clustering algorithm. -
    3. If the driver leap code is 11, the system leap code is 11, system stratum infinity and system reference identifier DOWN. This provides a definitive status condition to dependent clients. -
    -

    The local clock driver should be configured something like this:

    -

    server 127.127.1.1 prefer

    -

    fudge 127.127.1.1 stratum 0 refid NIST

    -

    The prefer keyword forces the driver to discipline the clock, even if other servers are configured and running correctly. This is convenient when a number of servers watch each other for monitoring and statistics gathering. In particular, the peerstats data and sysstats data can be collected at each server, aggregated for daily or weekly reports and sent by electric mail to a monitoring site. In addition, the full suite of cryptographic authentication algorithms is avialable to other servers and dependent clients.

    -

    Monitor Data

    -

    No filegen clockstats monitor data are produced by this driver.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Specifies the frequency offset calibration factor, in parts per million, with default 0.0. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 3. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default LCL. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Not used by this driver. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Not used by this driver. -
    -

    Additional Information

    -

    Reference Clock Drivers

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver10.html src.ntp/contrib/ntp/html/drivers/driver10.html --- src/contrib/ntp/html/drivers/driver10.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver10.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,53 +0,0 @@ - - - - - - - - Austron 2200A/2201A GPS Receivers - - - - -

    Austron 2200A/2201A GPS Receivers

    -
    -

    Synopsis

    -

    Address: 127.127.10.u
    - Reference ID: GPS
    - Driver ID: GPS_AS2201
    - Serial Port: /dev/gpsu; 9600 baud, 8-bits, no parity
    - Features: tty_clk

    -

    Description

    -

    This driver supports the Austron 2200A/2201A GPS/LORAN Synchronized Clock and Timing Receiver connected via a serial port. It supports several special features of the clock, including the Input Buffer Module, Output Buffer Module, IRIG-B Interface Module and LORAN Assist Module. It requires the RS232 Buffered Serial Interface module for communication with the driver. For operation with multiple computers, it requires the ppsclock streams module described in the Line Disciplines and Streams Modules page. The streams module requires a gadget box and 1-PPS level converter, such as described in the Pulse-per-second (PPS) Signal Interfacing page.

    -

    For use with a single computer, the receiver can be connected directly to the receiver. For use with multiple computers, one of them is connected directly to the receiver and generates the polling messages. The other computers just listen to the receiver output directly or through a buffer amplifier. For computers that just listen, fudge flag2 must be set and the ppsclock streams module configured on each of them.

    -

    This receiver is capable of a comprehensive and large volume of statistics and operational data. The specific data collection commands and attributes are embedded in the driver source code; however, the collection process can be enabled or disabled using the flag4 flag. If set, collection is enabled; if not, which is the default, it is disabled. A comprehensive suite of data reduction and summary scripts is in the ./scripts/stats directory

    - of the ntp3 distribution. -

    Monitor Data

    -

    When enabled by the flag4 fudge flag, every received timecode is written as-is to the clockstats file.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default GPS. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Set for computers that listen-only. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Enable verbose clockstats recording if set. -
    -

    Additional Information

    -

    Reference Clock Drivers

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver11.html src.ntp/contrib/ntp/html/drivers/driver11.html --- src/contrib/ntp/html/drivers/driver11.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver11.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,87 +0,0 @@ - - - - - - - - Arbiter 1088A/B GPS Receiver - - - - -

    Arbiter 1088A/B GPS Receiver

    -
    -

    Synopsis

    -

    Address: 127.127.11.u
    - Reference ID: GPS
    - Driver ID: GPS_ARBITER
    - Serial Port: /dev/gpsu; 9600 baud, 8-bits, no parity
    - Features: tty_clk

    -

    -

    Description

    -

    -

    This driver supports the Arbiter 1088A/B Satellite Controlled Clock. The claimed accuracy of this clock is 100 ns relative to the PPS output when receiving four or more satellites.

    -

    The receiver should be configured before starting the NTP daemon, in order to establish reliable position and operating conditions. It does not initiate surveying or hold mode. For use with NTP, the daylight savings time feature should be disables (D0 command) and the broadcast mode set to operate in UTC (BU command).

    -

    The timecode format supported by this driver is selected by the poll sequence B5, which initiates a line in the following format to be repeated once per second until turned off by the B0 command.

    -

    Format B5 (24 ASCII printing characters):

    -
    <cr><lf>i yy ddd hh:mm:ss.000bbb
    -
    -on-time = <cr>
    -i = synchronization flag (' ' = locked, '?' = unlocked)
    -yy = year of century
    -ddd = day of year
    -hh:mm:ss = hours, minutes, seconds
    -.000 = fraction of second (not used)
    -bbb = tailing spaces for fill
    -

    The alarm condition is indicated by a '?' at i, which indicates the receiver is not synchronized. In normal operation, a line consisting of the timecode followed by the time quality character (TQ) followed by the receiver status string (SR) is written to the clockstats file.

    -

    The time quality character is encoded in IEEE P1344 standard:

    -

    Format TQ (IEEE P1344 estimated worst-case time quality)

    -
    0       clock locked, maximum accuracy
    -F       clock failure, time not reliable
    -4       clock unlocked, accuracy < 1 us
    -5       clock unlocked, accuracy < 10 us
    -6       clock unlocked, accuracy < 100 us
    -7       clock unlocked, accuracy < 1 ms
    -8       clock unlocked, accuracy < 10 ms
    -9       clock unlocked, accuracy < 100 ms
    -A       clock unlocked, accuracy < 1 s
    -B       clock unlocked, accuracy < 10 s
    -

    The status string is encoded as follows:

    -

    Format SR (25 ASCII printing characters)

    -
    V=vv S=ss T=t P=pdop E=ee
    -
    -vv = satellites visible
    -ss = relative signal strength
    -t = satellites tracked
    -pdop = position dilution of precision (meters)
    -ee = hardware errors
    -

    A three-stage median filter is used to reduce jitter and provide a dispersion measure. The driver makes no attempt to correct for the intrinsic jitter of the radio itself.

    -

    Monitor Data

    -

    When enabled by the flag4 fudge flag, an additional line containing the latitude, longitude, elevation and optional deviation data is written to the clockstats file. The deviation data operates with an external pulse-per-second (PPS) input, such as a cesium oscillator or another radio clock. The PPS input should be connected to the B event channel and the radio initialized for deviation data on that channel. The deviation data consists of the mean offset and standard deviation of the external PPS signal relative the GPS signal, both in microseconds over the last 16 seconds.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default GPS. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Not used by this driver. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Enable verbose clockstats recording if set. -
    -

    Additional Information

    -

    Reference Clock Drivers

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver12.html src.ntp/contrib/ntp/html/drivers/driver12.html --- src/contrib/ntp/html/drivers/driver12.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver12.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,49 +0,0 @@ - - - - - - - - KSI/Odetics TPRO/S IRIG Interface - - - - -

    KSI/Odetics TPRO/S IRIG Interface

    -
    -

    Synopsis

    -

    Address: 127.127.12.u
    - Reference ID: IRIG
    - Driver ID: IRIG_TPRO
    - TPRO Device: /dev/tprou
    - Requires: KSI/Odetics device driver, /usr/include/sys/tpro.h header file

    -

    Description

    -

    This driver supports the KSI/Odetics TPRO and TPRO-SAT IRIG-B Decoder, which is a module connected directly to the SBus of a Sun workstation. The module works with the IRIG-B signal generated by several radio clocks, including those made by Arbiter, Austron, Odetics, Spectracom and TrueTime, among others, although it is generally an add- on option. In the case of the TPRO-SAT, the module is an integral part of a GPS receiver, which serves as the primary timing source.

    -

    Using the TPRO interface as a NTP reference clock provides precision time only to ntpd and its clients. With suitable kernel modifications, it is possible to use the TPRO as the CPU system clock, avoiding errors introduced by the CPU clock oscillator wander. See the A Kernel Model for Precision Timekeeping page for further details.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default IRIG. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Not used by this driver. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Not used by this driver. -
    -

    Additional Information

    -

    Reference Clock Drivers

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver16.html src.ntp/contrib/ntp/html/drivers/driver16.html --- src/contrib/ntp/html/drivers/driver16.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver16.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,31 +0,0 @@ - - - - - - - - - Bancomm bc635VME Time and Frequency Processor - - - - -

    bc635VME/bc350VXI Time and Frequency Processor

    -
    -

    Synopsis

    -

    Address: 127.127.16.u
    - Reference ID: BTFP
    - Driver ID: GPS_BANCOMM
    - Bancomm Device /dev/btfp0
    - Requires: Bancomm bc635 TFP device module driver for SunOS 4.x/SunOS 5.x

    -

    Description

    -

    This is the clock driver for the Bancomm bc635VME Time and Frequency Processor. It requires the BANCOMM bc635VME bc350VXI Time and Frequency Processor Module Driver for SunOS 4.x/SunOS 5.x UNIX Systems.

    -

    Most of this code is originally from refclock_bancomm.c with thanks. It has been modified and tested on an UltraSparc IIi-cEngine running Solaris 2.6. A port for HPUX is not available henceforth.

    -

    Additional Information

    -

    Reference Clock Drivers

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver18.html src.ntp/contrib/ntp/html/drivers/driver18.html --- src/contrib/ntp/html/drivers/driver18.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver18.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,82 +0,0 @@ - - - - - - - - NIST Modem Time Service - - - - -

    Automated Computer Time Service (ACTS)

    -
    -

    Synopsis

    -

    Address: 127.127.18.u
    - Reference ID: NIST | USNO | PTB | WWVB
    - Driver ID: ACTS_MODEM
    - Serial Port: /dev/actsu; 9600 baud, 8-bits, no parity
    - Features: tty_clk
    - Requires: /usr/include/sys/termios.h header file with modem control and a dial-out (cua) device.

    -

    Description

    -

    This driver supports the US (NIST and USNO) and European (PTB (Germany), NPL (UK), etc.) modem time services, as well as Spectracom GPS and WWVB receivers connected via a modem. The driver periodically dials a number from a telephone list, receives the timecode data and calculates the local clock correction. It is designed primarily for backup when neither a radio clock nor connectivity to Internet time servers are available. It can also be configured to operate full period.

    -

    For best results the indicated time must be corrected for the modem and telephone circuit propagation delays, which can reach 200 ms or more. For the NIST service, corrections are determined automatically by measuring the roundtrip delay of echoed characters. With this service the absolute accuracy is typically a millisecond or two. Corrections for the other services must be determined by other means. With these services variations from call to call and between messages during a call are typically a few milliseconds, occasionally higher.

    -

    This driver requires a 9600-bps modem with a Hayes-compatible command set and control over the modem data terminal ready (DTR) control line. The actual line speed ranges from 1200 bps with USNO to 14,400 bps with NIST. The modem setup string is hard-coded in the driver and may require changes for nonstandard modems or special circumstances.

    -

    There are three modes of operation selected by the mode keyword in the server configuration command. In manual mode (2) the calling program is initiated by setting fudge flag1. This can be done manually using ntpdc, or by a cron job. In auto mode (0) flag1 is set at each poll event. In backup mode (1) flag1 is set at each poll event, but only if no other synchronization sources are available.

    -

    When flag1 is set, the calling program dials the first number in the list specified by the phone command. If the call fails for any reason, the program dials the second number and so on. The phone number is specified by the Hayes ATDT prefix followed by the number itself, including the prefix and long-distance digits and delay code, if necessary. The flag1 is reset and the calling program terminated if (a) valid clock update has been determined, (b) no more numbers remain in the list, (c) a device fault or timeout occurs or (d) fudge flag1 is reset manually using ntpdc.

    -

    The driver automatically recognizes the message format of each modem time service. It selects the parsing algorithm depending on the message length. There is some hazard should the message be corrupted. However, the data format is checked carefully and only if all checks succeed is the message accepted. Corrupted lines are discarded without complaint. Once the service is known, the reference identifier for the driver is set to NIST, USNO, PTB or WWVB as appropriate.

    -

    Ordinarily, the serial port is connected to a modem; however, if fudge flag3 is set, it can be connected directly to a Spectracom WWV or GPS radio for testing or calibration. The Spectracom radio can be connected via a modem if the radio is connfigured to send time codes continuoulsly at 1-s intervals. In principle, fudge flag2 enables port locking, allowing the modem to be shared when not in use by this driver. At least on Solaris with the current NTP I/O routines, this results in lots of ugly error messages.

    -

    The minpoll and maxpoll keywords of the server configuration command can be used to limit the intervals between calls. The recommended settings are 12 (1.1 hours) for minpoll and 17 (36 hours) for maxpoll. Ordinarily, the poll interval will start at minpoll and ramp up to maxpoll in a day or two.

    -

    US Phone Numbers and Formats

    -

    Note: Phone numbers include the entire Hayes modem command, including the ATDT and other control codes as may be necessary. For most cases only the ATDT may be necessary.

    -

    National Institute of Science and Technology (NIST)

    -

    Phone: (303) 494-4774 (Boulder, CO); (808) 335-4721 (Hawaii)

    -

    Data Format

    -

    National Institute of Standards and Technology
    - Telephone Time Service, Generator 3B
    - Enter question mark "?" for HELP
    - MJD YR MO DA H M S ST S UT1 msADV <OTM>
    - 47999 90-04-18 21:39:15 50 0 +.1 045.0 UTC(NIST) *
    - 47999 90-04-18 21:39:16 50 0 +.1 045.0 UTC(NIST) #
    - ...

    -

    MJD, YR, ST, UT1 and UTC(NIST) are not used by this driver. The <OTM> on-time character "*" changes to "#" when the delay correction is valid.

    -

    US Naval Observatory (USNO)

    -

    Phone: (202) 762-1594 (Washington, DC); (719) 567-6742 (Boulder, CO)

    -

    Data Format (two lines, repeating at one-second intervals)

    -

    jjjjj nnn hhmmss UTC

    -

    * on-time character for previous timecode message
    - jjjjj modified Julian day number (not used)
    - nnn day of year
    - hhmmss second of day

    -

    European Phone Numbers and Formats

    -

    Spectracom GPS and WWVB Receivers

    -

    If a modem is connected to a Spectracom receiver, this driver will call it and retrieve the time in one of two formats, 0 and 2. Ordinarily, the receiver requires a T in order to return the timecode. As this driver does not send data via the modem, it must either be configured in continuous mode or be polled by another local driver.

    -

    Monitor Data

    -

    The received timecode is written as-is to the clockstats file along with the Hayes connection and hangup commands and result codes.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Set by the driver to (one of) NIST, USNO, PTB or WWVB. -
    flag1 0 | 1 -
    Initiate a call if 1. Automatically reset by program. -
    flag2 0 | 1 -
    Enables port locking if 1, disables if 0 (default). -
    flag3 0 | 1 -
    Enables direct connection if 1, or modem if 0 (default). If set, the driver will send a single character 'T' at every poll event. -
    flag4 0 | 1 -
    Not used by this driver. -
    -

    Additional Information

    -

    Reference Clock Drivers 

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver19.html src.ntp/contrib/ntp/html/drivers/driver19.html --- src/contrib/ntp/html/drivers/driver19.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver19.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,59 +0,0 @@ - - - - - - - - Heath WWV/WWVH Receiver - - - - -

    Heath WWV/WWVH Receiver

    -
    -

    Synopsis

    -

    Address: 127.127.19.u
    - Reference ID: WWV
    - Driver ID: WWV_HEATH
    - Serial Port: /dev/heathu; 1200 baud, 8-bits, no parity
    - Features: tty_clk
    - Requires: /usr/include/sys/termios.h header file with modem control

    -

    Description

    -

    This driver supports the Heath GC-1000 Most Accurate Clock, with RS232C Output Accessory. This is a WWV/WWVH receiver somewhat less robust than other supported receivers. Its claimed accuracy is 100 ms when actually synchronized to the broadcast signal, but this doesn't happen even most of the time, due to propagation conditions, ambient noise sources, etc. When not synchronized, the accuracy is at the whim of the internal clock oscillator, which can wander into the sunset without warning. Since the indicated precision is 100 ms, expect a host synchronized only to this thing to wander to and fro, occasionally being rudely stepped when the offset exceeds the default CLOCK_MAX of 128 ms.

    -

    The internal DIPswitches should be set to operate at 1200 baud in MANUAL mode and the current year. The external DIPswitches should be set to GMT and 24-hour format. It is very important that the year be set correctly in the DIPswitches; otherwise, the day of year will be incorrect after 28 April of a normal or leap year.

    -

    In MANUAL mode the clock responds to a rising edge of the request to send (RTS) modem control line by sending the timecode. Therefore, it is necessary that the operating system implement the TIOCMBIC and TIOCMBIS ioctl system calls and TIOCM_RTS control bit. Present restrictions require the use of a POSIX-compatible programming interface, although other interfaces may work as well.

    -

    The clock message consists of 23 ASCII printing characters in the following format:

    -
    hh:mm:ss.f     dd/mm/yr<cr>
    -
    -hh:mm:ss.f = hours, minutes, seconds
    -f = deciseconds ('?' when out of spec)
    -dd/mm/yr = day, month, year
    -

    The alarm condition is indicated by '?', rather than a digit, at A. Note that 0?:??:??.? is displayed before synchronization is first established and hh:mm:ss.? once synchronization is established and then lost again for about a day.

    -

    A fudge time1 value of .07 s appears to center the clock offset residuals.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default WWV. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Not used by this driver. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Not used by this driver -
    - Additional Information -

    Reference Clock Drivers 

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver2.html src.ntp/contrib/ntp/html/drivers/driver2.html --- src/contrib/ntp/html/drivers/driver2.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver2.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,67 +0,0 @@ - - - - - - - - Trak 8820 GPS Receiver - - - - -

    Trak 8820 GPS Receiver

    -
    -

    Synopsis

    -

    Address: 127.127.2.u
    - Reference ID: GPS
    - Driver ID: GPS_TRAK
    - Serial Port: /dev/traku; 9600 baud, 8-bits, no parity
    - Features: tty_clk

    -

    Description

    -

    This driver supports the Trak 8820 GPS Station Clock. The claimed accuracy at the 1-PPS output is 200-300 ns relative to the broadcast signal; however, in most cases the actual accuracy is limited by the precision of the timecode and the latencies of the serial interface and operating system.

    -

    For best accuracy, this radio requires the tty_clk line discipline, which captures a timestamp at the * on-time character of the timecode. Using this discipline the jitter is in the order of 1 ms and systematic error about 0.5 ms. If unavailable, the buffer timestamp is used, which is captured at the \r ending the timecode message. This introduces a systematic error of 23 character times, or about 24 ms at 9600 bps, together with a jitter well over 8 ms on Sun IPC-class machines.

    -

    Using the menus, the radio should be set for 9600 bps, one stop bit and no parity. It should be set to operate in computer (no echo) mode. The timecode format includes neither the year nor leap-second warning.

    -

    In operation, this driver sends a RQTS\r request to the radio at initialization in order to put it in continuous time output mode. The radio then sends the following message once each second:

    -
    *RQTS U,ddd:hh:mm:ss.0,q<cr><lf>
    -on-time = '*'
    -ddd = day of year
    -hh:mm:ss = hours, minutes, seconds
    -q = quality indicator (phase error), 0-6:
    -     0 > 20 us
    -     6 > 10 us
    -     5 > 1 us
    -     4 > 100 ns
    -     3 > 10 ns
    -     2 < 10 ns
    - The alarm condition is indicated by 0 at Q, which means the radio has a phase error greater than 20 us relative to the broadcast time. The absence of year, DST and leap-second warning in this format is also alarmed. -

    The continuous time mode is disabled using the RQTX\r request, following which the radio sends a RQTX DONE<cr><lf> response. In the normal mode, other control and status requests are effective, including the leap-second status request RQLS<cr>. The radio responds with RQLS yy,mm,dd<cr><lf>, where yy,mm,dd are the year, month and day. Presumably, this gives the epoch of the next leap second, RQLS 00,00,00 if none is specified in the GPS message. Specified in this form, the information is generally useless and is ignored by the driver.

    -

    Monitor Data

    -

    When enabled by the flag4 fudge flag, every received timecode is written as-is to the clockstats file.

    -

    Fudge Factors

    -

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default GPS. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Not used by this driver. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Not used by this driver. -

    Additional Information

    -

    Reference Clock Drivers

    -
    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver20.html src.ntp/contrib/ntp/html/drivers/driver20.html --- src/contrib/ntp/html/drivers/driver20.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver20.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,91 +0,0 @@ - - - - - - - - Generic NMEA GPS Receiver - - - - -

    Generic NMEA GPS Receiver

    -
    -

    Synopsis

    -

    Address: 127.127.20.u
    - Reference ID: GPS
    - Driver ID: GPS_NMEA
    - Serial Port: /dev/gpsu; 4800 baud, 8-bits, no parity
    - Serial Port: /dev/gpsu; symlink to server:port (for nmead) Features: tty_clk

    -

    Description

    -

    This driver supports GPS receivers with the $GPRMC NMEA output string by default.  Alternately the $GPGGA or $GPGLL may be selected.

    -

    The driver expects the receiver to be set up to transmit a $GPRMC message every second.

    -

    The accuracy depend on the receiver used. Inexpesive GPS models are available with a claimed PPS signal accuracy of 1 ms or better relative to the broadcast signal. However, in most cases the actual accuracy is limited by the precision of the timecode and the latencies of the serial interface and operating system.

    -

    If the Operating System supports the PPSAPI, RFC-2783, it will be used.
     

    -

    The various GPS sentences that this driver recognises look like this:
    - (others quietly ignored)

    -
    $GPRMC,POS_UTC,POS_STAT,LAT,LAT_REF,LON,LON_REF,SPD,HDG,DATE,MAG_VAR,MAG_REF*CC<cr><lf>
    -$GPGLL,LAT,LAT_REF,LONG,LONG_REF,POS_UTC,POS_STAT*CC<cr><lf>
    -$GPGGA,POS_UTC,LAT,LAT_REF,LONG,LONG_REF,FIX_MODE,SAT_USED,HDOP,ALT,ALT_UNIT,GEO,G_UNIT,D_AGE,D_REF*CC<cr><lf>
    -
    -  POS_UTC  - UTC of position. Hours, minutes and seconds [fraction (opt.)]. (hhmmss[.fff])
    -  POS_STAT - Position status. (A = Data valid, V = Data invalid)
    -  LAT      - Latitude (llll.ll)
    -  LAT_REF  - Latitude direction. (N = North, S = South)
    -  LON      - Longitude (yyyyy.yy)
    -  LON_REF  - Longitude direction (E = East, W = West)
    -  SPD      - Speed over ground. (knots) (x.x)
    -  HDG      - Heading/track made good (degrees True) (x.x)
    -  DATE     - Date (ddmmyy)
    -  MAG_VAR  - Magnetic variation (degrees) (x.x)
    -  MAG_REF  - Magnetic variation (E = East, W = West)
    -  FIX_MODE - Position Fix Mode ( 0 = Invalid, >0 = Valid)
    -  SAT_USED - Number Satellites used in solution
    -  HDOP     - Horizontal Dilution of Precision
    -  ALT      - Antenna Altitude
    -  ALT_UNIT - Altitude Units (Metres/Feet)
    -  GEO      - Geoid/Elipsoid separation
    -  G_UNIT   - Geoid units (M/F)
    -  D_AGE    - Age of last DGPS Fix
    -  D_REF    - Reference ID of DGPS station
    -  CC       - Checksum (optional)
    -  <cr><lf> - Sentence terminator.
    - Alternate GPS sentences (other than $GPRMC - the default) may be enabled by setting the relevent bits of 'mode' in the server configuration line
     * server 127.127.20.x mode X
        bit 0 - enables RMC    ( value = 1)
        bit 1 - enables GGA    ( value = 2)
        bit 2 - enables GLL      ( value = 4)
    - multiple sentences may be selected
    -

    The driver will send a $PMOTG,RMC,0000*1D<cr><lf> message each time a $GPRMC string is needed. This is not needed on most GPS receivers because they automatically send the $GPRMC string every second and will only work on GPS receivers that understand the $PMOTG string. Others will just ignore it.

    -

    Setting up the Garmin GPS-25XL

    - Switch off all output with by sending it the following string. -
    "$PGRMO,,2<cr><lf>"
    -

    Now switch only $GPRMC on by sending it the following string.

    -
    "$PGRMO,GPRMC,1<cr><lf>"
    -

    On some systems the PPS signal isn't switched on by default. It can be switched on by sending the following string.

    -
    "$PGRMC,,,,,,,,,,,,2<cr><lf>"
    -

    Monitor Data

    -

    The GPS sentence(s) that is used is written to the clockstats file.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default GPS. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Specifies the PPS signal on-time edge: 0 for assert (default), 1 for clear. -
    flag3 0 | 1 -
    Controls the kernel PPS discipline: 0 for disable (default), 1 for enable. -
    flag4 0 | 1 -
    Not used by this driver. -
    -

    Additional Information

    -

    Reference Clock Drivers

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver22.html src.ntp/contrib/ntp/html/drivers/driver22.html --- src/contrib/ntp/html/drivers/driver22.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver22.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,60 +0,0 @@ - - - - - - - - PPS Clock Discipline - - - - -

    PPS Clock Discipline

    -
    -

    Synopsis

    -

    Address: 127.127.22.u
    - Reference ID: PPS
    - Driver ID: PPS
    - Serial or Parallel Port: /dev/ppsu
    - Requires: PPSAPI interface

    -

    Note: This driver supersedes an older one of the same name. The older driver operated with several somewhat archaic signal interface devices, required intricate configuration and was poorly documented. This driver operates only with the PPSAPI interface proposed as an IETF standard. Note also that the pps configuration command has been obsoleted by this driver.

    -

    Description

    -

    This driver furnishes an interface for the pulse-per-second (PPS) signal produced by a cesium clock, radio clock or related devices. It can be used to augment the serial timecode generated by a GPS receiver, for example. It can be used to remove accumulated jitter and re-time a secondary server when synchronized to a primary server over a congested, wide-area network and before redistributing the time to local clients. The driver includes extensive signal sanity checks and grooming algorithms. A range gate and frequency discriminator reject noise and signals with incorrect frequency. A multiple-stage median filter rejects jitter due to hardware interrupt and operating system latencies. A trimmed-mean algorithm determines the best time samples. With typical workstations and processing loads, the incidental jitter can be reduced to a few microseconds.

    -

    While this driver can discipline the time and frequency relative to the PPS source, it cannot number the seconds. For this purpose an auxiliary source is required, ordinarily a radio clock operated as a primary reference (stratum 1) source; however, another NTP time server can be used as well. For this purpose, the auxiliary source should be specified as the prefer peer, as described in the Mitigation Rules and the prefer Keyword page.

    -

    The driver requires the PPSAPI interface1, which is a proposed IETF standard. The interface consists of the timepps.h header file and associated kernel support. Support for this interface is included in current versions of Solaris, FreeBSD and Linux and proprietary versions of Tru64 (Alpha) and SunOS. See the Pulse-per-second (PPS) Signal Interfacing page for further information.

    -

    The PPS source can be connected via a serial or parallel port, depending on the hardware and operating system. A serial port can be dedicated to the PPS source or shared with another device; however, if dedicated the data leads should not be connected, as noise or unexpected signals can cause ntpd to exit.

    -

    A radio clock is usually connected via a serial port and the PPS source connected via a level converter to the data carrier detect (DCD) pin (DB-9 pin 1, DB-25 pin 8) of the same connector. In some systems where a parallel port and driver are available, the PPS signal can be connected directly to the ACK pin (pin 10) of the connector. Whether the PPS signal is connected via a dedicated port or shared with another device, the driver opens the device /dev/pps%d, where %d is the unit number. As with other drivers, links can be used to redirect the logical name to the actual physical device.

    -

    The driver normally operates like any other driver and uses the same mitigation algorithms and PLL/FLL clock discipline incorporated in the daemon. If kernel PLL/FLL support is available, the kernel PLL/FLL clock discipline can be used instead. The default behavior is not to use the kernel PPS clock discipline, even if present. This driver incorporates a good deal of signal processing to reduce jitter using the median filter and trimmed average algorithms in the driver interface. As the result, performance with minpoll and maxpoll configured at the minimum 4 (16s) is generally better than the kernel PPS discipline. However, fudge flag 3 can be used to enable the kernel PPS discipline if necessary.

    -

    Note that the PPS source is considered valid only if the auxiliary source is the prefer peer, is reachable and is selectable to discipline the system clock. By default the stratum assigned to the PPS source is automatically determined. If the auxiliary source is unreachable or inoperative, the stratum is set to 16. Otherwise it is set to the stratum specified by the fudge stratum command, if present, or the auxiliary source stratum if not present. Please note the temptation to masquerade as a primary server by forcing the stratum to zero is decidedly dangerous, as it invites timing loops.

    -

    The mode keyword of the server command can be used to set the PPSAPI mode bits which determine the capture edge and echo options. See the /usr/include/sys/timepps.h header file for the bit definitions, which must be converted to their decimal equivalents. This overrides the fudge flag2 option.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default PPS. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Specifies the PPS signal on-time edge: 0 for assert (default), 1 for clear. -
    flag3 0 | 1 -
    Controls the kernel PPS discipline: 0 for disable (default), 1 for enable. -
    flag4 0 | 1 -
    Not used by this driver. -
    -

    Additional Information

    -

    Reference Clock Drivers

    -

    Reference

    -
      -
    1. Mogul, J., D. Mills, J. Brittenson, J. Stone and U. Windl. Pulse-per-second API for Unix-like operating systems, version 1. Request for Comments RFC-2783, Internet Engineering Task Force, March 2000, 31 pp. -
    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver26.html src.ntp/contrib/ntp/html/drivers/driver26.html --- src/contrib/ntp/html/drivers/driver26.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver26.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,53 +0,0 @@ - - - - - - - - Hewlett Packard 58503A GPS Receiver and HP Z3801A - - - - -

    Hewlett Packard 58503A GPS Receiver and HP Z3801A

    -
    -

    Synopsis

    -

    Address: 127.127.26.u
    - Reference ID: GPS
    - Driver ID: GPS_HP
    - Serial Port: /dev/hpgpsu; 9600 baud, 8-bits, no parity, 19200 baud 7-bits, odd parity for the HP Z3801A

    -

    Description

    -

    This driver supports the HP 58503A Time and Frequency Reference Receiver and HP Z3801A GPS Receiver. They use HP SmartClock (TM) to implement an Enhanced GPS receiver. The receiver accuracy when locked to GPS in normal operation is better than 1 usec. The accuracy when operating in holdover is typically better than 10 us per day. It receiver should be operated with factory default settings. Initial driver operation: expects the receiver to be already locked to GPS, configured and able to output timecode format 2 messages.

    -

    The driver uses the poll sequence :PTIME:TCODE? to get a response from the receiver. The receiver responds with a timecode string of ASCII printing characters, followed by a <cr><lf>, followed by a prompt string issued by the receiver, in the following format:

    -
    T#yyyymmddhhmmssMFLRVcc<cr><lf>scpi >
    - The driver processes the response at the <cr> and <lf>, so what the driver sees is the prompt from the previous poll, followed by this timecode. The prompt from the current poll is (usually) left unread until the next poll. So (except on the very first poll) the driver sees this: -
    scpi >T#yyyymmddhhmmssMFLRVcc<cr><lf>
    -

    The T is the on-time character, at 980 msec. before the next 1PPS edge. The # is the timecode format type. We look for format 2. Without any of the CLK or PPS stuff, then, the receiver buffer timestamp at the <cr> is 24 characters later, which is about 25 msec. at 9600 bps, so the first approximation for fudge time1 is nominally -0.955 seconds. This number probably needs adjusting for each machine / OS type, so far: -0.955000 on an HP 9000 Model 712/80 HP-UX 9.05 -0.953175 on an HP 9000 Model 370 HP-UX 9.10

    -This driver will probably work with the 58503B and 59551A if they are setup appropriately.

    -To use an HP Z3801A, specify mode 1 on the server config line to setup the right line paramters.

    -The timekeeping portion of HP's business has been sold to Symmetricom.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default GPS. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Not used by this driver. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Not used by this driver. -
    -
    - - - - diff -urN src/contrib/ntp/html/drivers/driver27.html src.ntp/contrib/ntp/html/drivers/driver27.html --- src/contrib/ntp/html/drivers/driver27.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver27.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,247 +0,0 @@ - - - - - - - - Arcron MSF Receiver - - - - -

    Arcron MSF Receiver

    -
    -

    Synopsis

    -

    Address: 127.127.27.u
    - Reference ID: MSFa / MSF / DCF / WWVB
    - Driver ID: MSF_ARCRON
    - Serial Port: /dev/arcu; 300 baud, 8-bits, 2-stop, no parity
    - Features: tty_clk

    -

    Description

    -

    This driver supports the Arcron MSF, DCF and WWVB receivers. The clock reports its ID as "MSFa'', "MSF'', "DCF'' or "WWVB'' to indicate the time source.

    -

    This documentation describes v1.3 (2003/2/21) of the source and has been tested against ntpd 4.1.0 on linux x86. Changes from v1.1 and v1.2 include patches to work with the new ntp-4 code, clock support for DCF and WWVB configurable via mode flag, an option to ignore resync request (for those of us at the fringes of the WWVB signal, for instance), averaging of the signal quality poll and several bug fixes, code cleanup and standardizations. In all other respects, the driver works as per v1.1 if a mode is not specified.

    -

    To use the alternate modes, the mode flag must be specified. If the mode flag is 0, or unspecified, the original MSF version is assumed. This should assure backwards compatibility and should not break existing setups.

    -

    The previous documentation described version V1.1 (1997/06/23) of the source and had been tested (amongst others) against ntpd3-5.90 on Solaris-1 (SunOS 4.1.3_U1 on an SS1 serving as a router and firewall) and against ntpd3-5.90 on Solaris-2.5 (on a SS1+ and TurboSPARC 170MHz). That code will claimed increased stability, reduced jitter and more efficiency (fewer context switches) with the tty_clk discipline/STREAMS module installed, but this has not been tested. For a to-do list see the comments at the start of the code.

    -

    This code has been significantly slimmed down since the V1.0 version, roughly halving the memory footprint of its code and data.

    -

    This driver is designed to allow the unit to run from batteries as designed, for something approaching the 2.5 years expected in the usual stand-alone mode, but no battery-life measurements have been taken.

    -

    Much of this code is originally from the other refclock driver files with thanks. The code was originally made to work with the clock by Derek Mulcahy, with modifications by Damon Hart-Davis. Thanks also to Lyndon David for some of the specifications of the clock. Paul Alfille added support for the WWVB clock. Christopher Price added enhanced support for the MSF, DCF and WWVB clocks.

    -

    There is support for a Tcl/Tk monitor written by Derek Mulcahy that examines the output stats; see the ARC Rugby MSF Receiver page for more details and the code. Information on the WWVB version is available from Atomic Time as their Atomic Time PC.

    -

    Look at the notes at the start of the code for further information; some of the more important details follow.

    -

    The driver interrogates the clock at each poll (ie every 64s by default) for a timestamp. The clock responds at the start of the next second (with the start bit of the first byte being on-time). In the default or original MSF mode, the time is in `local' format, including the daylight savings adjustment when it is in effect. The driver code converts the time back to UTC. In modes 1-3 the driver can be configured for UTC or local time depending on the setting of flag1.

    -

    The clock claims to be accurate to within about 20ms of the broadcast time, and given the low data transmission speed from clock to host, and the fact that the clock is not in continuous sync with MSF, it seems sensible to set the `precision' of this clock to -5 or -4, -4 being used in this code, which builds in a reported dispersion of over 63ms (ie says ``This clock is not very good.''). You can improve the reported precision to -4 (and thus reduce the base dispersion to about 31ms) by setting the fudge flag3 to 1.

    -

    Even a busy and slow IP link can yield lower dispersions than this from polls of primary time servers on the Internet, which reinforces the idea that this clock should be used as a backup in case of problems with such an IP link, or in the unfortunate event of failure of more accurate sources such as GPS.

    -

    By default this clock reports itself to be at stratum 2 rather than the usual stratum 0 for a refclock, because it is not really suited to be used as other than a backup source. The stratum reported can be changed with the stratum directive to be whatever you like. After careful monitoring of your clock, and appropriate choice of the time1 fudge factor to remove systematic errors in the clock's reported time, you might fudge the clock to stratum 1 to allow a stratum-2 secondary server to sync to it.

    -

    In default mode, the driver code arranges to resync the clock to MSF at intervals of a little less than an hour (deliberately avoiding the same time each hour to avoid any systematic problems with the signal or host). Whilst resyncing, the driver supplements the normal polls for time from the clock with polls for the reception signal quality reported by the clock. If the signal quality is too low (0--2 out of a range of 0--5), we chose not to trust the clock until the next resync (which we bring forward by about half an hour). If we don't catch the resync, and so don't know the signal quality, we do trust the clock (because this would generally be when the signal is very good and a resync happens quickly), but we still bring the next resync forward and reduce the reported precision (and thus increase reported dispersion).

    -

    If we force resyncs to MSF too often we will needlessly exhaust the batteries the unit runs from. During clock resync this driver tries to take enough time samples to avoid ntpd losing sync in case this clock is the current peer. By default the clock would only resync to MSF about once per day, which would almost certainly not be acceptable for NTP purposes.

    -

    The driver does not force an immediate resync of the clock to MSF when it starts up to avoid excessive battery drain in case ntpd is going to be repeatedly restarted for any reason, and also to allow enough samples of the clock to be taken for ntpd to sync immediately to this clock (and not remain unsynchronised or to sync briefly to another configured peer, only to hop back in a few poll times, causing unnecessary disturbance). This behaviour should not cause problems because the driver will not accept the timestamps from the clock if the status flag delivered with the time code indicates that the last resync attempt was unsuccessful, so the initial timestamps will be close to reality, even if with up to a day's clock drift in the worst case (the clock by default resyncs to MSF once per day).

    -

    When alternate modes 1-3 are selected, the driver can be configured to ignore the resync requests by setting flag2 to 1. This allows clocks at the fringe of the signal to resync at night when signals are stronger.

    -

    The clock has a peculiar RS232 arrangement where the transmit lines are powered from the receive lines, presumably to minimise battery drain. This arrangement has two consequences:

    -
      -
    • Your RS232 interface must drive both +ve and -ve -
    • You must (in theory) wait for an echo and a further 10ms between characters -
    -

    This driver, running on standard Sun and x86 hardware, seems to work fine; note the use of the send_slow() routine to queue up command characters to be sent once every two seconds.

    -

    Three commands are sent to the clock by this driver. Each command consists of a single letter (of which only the bottom four bits are significant), followed by a CR (ASCII 13). Each character sent to the clock should be followed by a delay to allow the unit to echo the character, and then by a further 10ms. Following the echo of the command string, there may be a response (ie in the case of the g and o commands below), which in the case of the o command may be delayed by up to 1 second so as the start bit of the first byte of the response can arrive on time. The commands and their responses are:

    -
    -
    g CR -
    Request for signal quality. Answer only valid during (late part of) resync to MSF signal. The response consists of two characters as follows: -
      -
      -
      bit 7 -
      parity -
      bit 6 -
      always 0 -
      bit 5 -
      always 1 -
      bit 4 -
      always 1 -
      bit 3 -
      always 0 -
      bit 2 -
      always 0 -
      bit 1 -
      always 1 -
      bit 0 -
      = 0 if no reception attempt at the moment, = 1 if reception attempt (ie resync) in progress -
      -
      -
      bit 7 -
      parity -
      bit 6 -
      always 0 -
      bit 5 -
      always 1 -
      bit 4 -
      always 1 -
      bit 3 -
      always 0 -
      bit 2--0 -
      reception signal quality in the range 0--5 (very poor to very good); if in the range 0--2 no successful reception is to be expected. The reported value drops to zero when not resyncing, ie when first returned byte is not `3'. -
      -
    -
    h CR -
    Request to resync to signal. Can take up from about 30s to 360s. Drains batteries so should not be used excessively. After this the clock time and date should be correct and the phase within 20ms of time as transmitted from the source signal (remember to allow for propagation time). By default the clock resyncs once per day in the late evening/early morning (presumably to catch transitions to/from daylight saving time quickly). This driver code, by default, resyncs at least once per hour to minimise clock wander. -
    o CR -
    Request timestamp. Start bit of first byte of response is on-time, so may be delayed up to 1 second. Note that the driver will convert time to GMT, if required. The response data is as follows: -
      -
    1. hours tens (hours range from 00 to 23) -
    2. hours units -
    3. minutes tens (minutes range from 00 to 59) -
    4. minutes units -
    5. seconds tens (seconds presumed to range from 00 to 60 to allow for leap second) -
    6. seconds units -
    7. day of week 1 (Monday) to 7 (Sunday) -
    8. day of month tens (day ranges from 01 to 31) -
    9. day of month units -
    10. month tens (months range from 01 to 12) -
    11. month units -
    12. year tens (years range from 00 to 99) -
    13. year units -
    14. BST/UTC status (Ignored in WWVB version) -
      -
      bit 7 -
      parity -
      bit 6 -
      always 0 -
      bit 5 -
      always 1 -
      bit 4 -
      always 1 -
      bit 3 -
      (MSF) always 0
      - (WWVB) Leap year indicator bit
      - 0 = non-leap year
      - 1 = leap year -
      bit 2 -
      = (MSF) 1 if UTC is in effect (reverse of bit 1)
      - (WWVB) Leap second warning bit -
      bit 1 -
      = (MSF)1 if BST is in effect (reverse of bit 2)
      - = (WWVB) 0 if ST is in effect, 1 if DST is in effect, 1 if transition from ST with bit 0 is set to 0 -
      bit 0 -
      = (MSF)1 if BST/UTC change pending
      - = (WWVB) 0 if ST is in effect, 1 if DST is in effect, 0 if transition from DST with bit 1 is set to 0 -
      -
    15. clock status -
      -
      bit 7 -
      parity -
      bit 6 -
      always 0 -
      bit 5 -
      always 1 -
      bit 4 -
      always 1 -
      bit 3 -
      = 1 if low battery is detected -
      bit 2 -
      = 1 if last resync failed (though officially undefined for the MSF clock, officially defined for WWVB) -
      bit 1 -
      = 1 if at least one reception attempt was successful
      - (MSF) since 0230
      - (DCF) since 0300
      - (WWVB) resets if not successful between 0300-0400 -
      bit 0 -
      = 1 if the clock has valid time---reset to zero when clock is reset (eg at power-up), and set to 1 after first successful resync attempt. -
      -
    -

    The driver only accepts time from the clock if the bottom three bits of the status byte are 011 or flag2 is set to 1 to ignore resync requests. For the MSF clock, if the UK parliament decides to move us to +0100/+0200 time as opposed to the current +0000/+0100 time, it is not clear what effect that will have on the time broadcast by MSF, and therefore on this driver's usefulness.

    -
    -

    A typical ntp.conf configuration file for this driver might be:

    -
    # hostname(n) means we expect (n) to be the stratum at which hostname runs.
    -
    -#------------------------------------------------------------------------------
    -# SYNCHRONISATION PARTNERS
    -# ========================
    -
    -# Default configuration (Original MSF mode)s...
    -server 127.127.27.0 mode 333 # ARCRON MSF radio clock
    -# Fudge stratum and other features as required.
    -# ADJUST time1 VALUE FOR YOUR HOST, CLOCK AND LOCATION!
    -fudge 127.127.27.0 stratum 1 time1 0.016 flag3 1
    -# WWVB users should change that line to:
    -server 127.127.27.0 mode 3 # ARCRON WWVB radio clock
    -fudge 127.127.27.0 stratum 1 time1 0.030 flag1 1 flag3 1
    -
    -peer 11.22.33.9 # tick(1--2).
    -peer 11.22.33.4 # tock(3), boot/NFS server.
    -
    -# This shouldn't get swept away unless left untouched for a long time.
    -driftfile /var/tmp/ntp.drift
    -
    -#------------------------------------------------------------------------------
    -# RESTRICTIONS
    -# ============
    -
    -# By default, don't trust and don't allow modifications.  Ignore in fact.
    -restrict default ignore notrust nomodify
    -
    -# Allow others in our subnet to check us out...
    -restrict 11.22.33.0 mask 255.255.255.0 nomodify notrust
    -
    -# Trust our peers for time.  Don't trust others in case they are insane.
    -restrict 127.127.27.0 nomodify
    -restrict 11.22.33.4 nomodify
    -restrict 11.22.33.9 nomodify
    -
    -# Allow anything from the local host.
    -restrict 127.0.0.1
    - There are a few #defines in the code that you might wish to play with: -
    -
    ARCRON_KEEN -
    With this defined, the code is relatively trusting of the clock, and assumes that you will have the clock as one of a few time sources, so will bend over backwards to use the time from the clock when available and avoid ntpd dropping sync from the clock where possible. You may wish to undefine this, especially if you have better sources of time or your reception is ropey. However, there are many checks built in even with this flag defined. -
    ARCRON_MULTIPLE_SAMPLES -
    When is defined, we regard each character in the returned timecode as at a known delay from the start of the second, and use the smallest (most negative) offset implied by any such character, ie with the smallest kernel-induced display, and use that. This helps to reduce jitter and spikes. -
    ARCRON_LEAPSECOND_KEEN -
    When is defined, we try to do a resync to MSF as soon as possible in the first hour of the morning of the first day of the first and seventh months, ie just after a leap-second insertion or deletion would happen if it is going to. This should help compensate for the fact that this clock does not continuously sample MSF, which compounds the fact that MSF itself gives no warning of an impending leap-second event. This code did not seem functional at the leap-second insertion of 30th June 1997 so is by default disabled. -
    PRECISION -
    Currently set to -4, but you may wish to set it to -5 if you are more conservative, or to -6 if you have particularly good experience with the clock and you live on the edge. Note that the flag3 fudge value will improve the reported dispersion one notch if clock signal quality is known good. So maybe just leave this alone. -
    -

    Monitor Data

    -

    Each timecode is written to the clockstats file with a signal quality value appended (`0'--`5' as reported by the clock, or `6' for unknown).

    -

    Each resync and result (plus gaining or losing MSF sync) is logged to the system log at level LOG_NOTICE; note that each resync drains the unit's batteries, so the syslog entry seems justified.

    -

    Syslog entries are of the form:

    -
    May 10 10:15:24 oolong ntpd[615]: ARCRON: unit 0: sending resync command
    -May 10 10:17:32 oolong ntpd[615]: ARCRON: sync finished, signal quality 5: OK, will use clock
    -May 10 11:13:01 oolong ntpd[615]: ARCRON: unit 0: sending resync command
    -May 10 11:14:06 oolong ntpd[615]: ARCRON: sync finished, signal quality -1: UNKNOWN, will use clock anyway
    -May 10 11:41:49 oolong ntpd[615]: ARCRON: unit 0: sending resync command
    -May 10 11:43:57 oolong ntpd[615]: ARCRON: sync finished, signal quality 5: OK, will use clock
    -May 10 12:39:26 oolong ntpd[615]: ARCRON: unit 0: sending resync command
    -May 10 12:41:34 oolong ntpd[615]: ARCRON: sync finished, signal quality 3: OK, will use clock
    -

    Fudge Factors

    -

    -
    -
    mode 0 | 1 | 2 | 3 -
    Specifies the clock hardware model. This parameter is optional, it defaults to the original mode of operation. -
    Supported modes of operation: -
    0 - Default, Original MSF -
    1 - Updated MSF -
    2 - New DCF77 -
    3 - New WWVB -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. On a Sun SparcStation 1 running SunOS 4.1.3_U1, with the receiver in London, a value of 0.020 (20ms) seems to be appropriate. -
    time2 time -
    Not currently used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 2. It is suggested that the clock be not be fudged higher than stratum 1 so that it is used a backup time source rather than a primary when more accurate sources are available. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default MSFa. When used in modes 1-3, the driver will report either MSF, DCF, or WWVB respectively. -
    flag1 0 | 1 -
    (Modes 1-3) If set to 0 (the default), the clock is set to UTC time. If set to 1, the clock is set to localtime. -
    flag2 0 | 1 -
    (Modes 1-3) If set to 0 (the default), the clock will be forced to resync approximately every hour. If set to 1, the clock will resync per normal operations (approximately midnight). -
    flag3 0 | 1 -
    If set to 1, better precision is reported (and thus lower dispersion) while clock's received signal quality is known to be good. -
    flag4 0 | 1 -
    Not used by this driver. -
    -

    Additional Information

    -

    Reference Clock Drivers
    - ARC Rugby MSF Receiver

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver28.html src.ntp/contrib/ntp/html/drivers/driver28.html --- src/contrib/ntp/html/drivers/driver28.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver28.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,76 +0,0 @@ - - - - - - - - Shared memoy Driver - - - - -

    Shared Memory Driver

    -
    -

    Synopsis

    -

    Address: 127.127.28.u
    - Reference ID: SHM
    - Driver ID: SHM

    -

    Description

    -

    This driver receives its reference clock info from a shared memory-segment. The shared memory-segment is created with owner-only access for unit 0 and 1, and world access for unit 2 and 3

    -

    Structure of shared memory-segment

    -
    struct shmTime {
    -  int    mode; /* 0 - if valid set
    -                *       use values, 
    -                *       clear valid
    -                * 1 - if valid set 
    -                *       if count before and after read of 
    -                *       values is equal,
    -                *         use values 
    -                *       clear valid
    -                */
    -  int    count;
    -  time_t clockTimeStampSec;      /* external clock */
    -  int    clockTimeStampUSec;     /* external clock */
    -  time_t receiveTimeStampSec;    /* internal clock, when external value was received */
    -  int    receiveTimeStampUSec;   /* internal clock, when external value was received */
    -  int    leap;
    -  int    precision;
    -  int    nsamples;
    -  int    valid;
    -  int    dummy[10]; 
    -};
    -

    Operation mode=0

    -

    When the poll-method of the driver is called, the valid-flag of the shared memory-segment is checked:

    -

    If set, the values in the record (clockTimeStampSec, clockTimeStampUSec, receiveTimeStampSec, receiveTimeStampUSec, leap, precision) are passed to ntp, and the valid-flag is cleared.

    -

    If not set, a timeout is reported to ntp, nothing else happend

    -

    Operation mode=1

    -

    When the poll-method of the driver is called, the valid-flag of the shared memory-segment is checked:

    -

    If set, the count-field of the record is remembered, and the values in the record (clockTimeStampSec, clockTimeStampUSec, receiveTimeStampSec, receiveTimeStampUSec, leap, precision) are read. Then, the remembered count is compared to the count now in the record. If both are equal, the values read from the record are passed to ntp. If they differ, another process has modified the record while it was read out (was not able to produce this case), and failure is reported to ntp. The valid flag is cleared.

    -

    If not set, a timeout is reported to ntp, nothing else happend

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default SHM. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Not used by this driver. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Not used by this driver. -

    Additional Information

    -

    Reference Clock Drivers

    -
    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver29.html src.ntp/contrib/ntp/html/drivers/driver29.html --- src/contrib/ntp/html/drivers/driver29.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver29.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,776 +0,0 @@ - - - - - - - Trimble Palisade Receiver - - - - -

    Trimble Palisade Receiver -
    -

    -

    gif

    -

    Synopsis

    - - - - - - - - - - - - - - - - - - - - - -
    -
    - Address: 
    -
    127.127.29.u
    -
    - Reference ID:
    -
    GPS
    -
    - Driver ID:
    -
    GPS_PALISADE
    -
    - Serial Port:
    -
    /dev/palisadeu
    -
    - Serial I/O:
    -
    9600 baud, 8-bits, 1-stop, odd parity
    -

    Description

    - The refclock_palisade driver supports Trimble Navigation's Palisade Smart Antenna GPS receiver.
    - Additional software and information about the Palisade GPS is available from: http://www.trimble.com/oem/ntp.
    - Latest NTP driver source, executables and documentation is maintained at: ftp://ftp.trimble.com/pub/ntp -

    This documentation describes version 7.12 of the GPS Firmware and version 2.46 (July 15, 1999) and later, of the driver source.
     

    -

    Operating System Compatibility

    - The Palisade driver has been tested on the following software and hardware platforms:
      -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    PlatformOperating SystemNTP SourcesAccuracy
    i386 (PC) LinuxNTP Distribution10 us
    i386 (PC) Windows NTftp://ftp.trimble.com/pub/ntp1 ms
    SUNSolaris 2.xNTP Distribution50 us
    Hewlett-PackardHPUX 9, 10, 11http://us-support.external.hp.com50 us
    VariousFree BSDNTP Distribution20 us
    -
    -

    GPS Receiver

    - The Palisade GPS receiver is an 8-channel smart antenna, housing the GPS receiver, antenna and interface in a single unit, and is designed for rooftop deployment in static timing applications. -

    Palisade generates a PPS synchronized to UTC within +/- 100 ns.  The Palisade's external event input with 40 nanosecond resolution is utilized by the Palisade NTP driver for asynchronous precision time transfer.

    -

    No user initialization of the receiver is required. This driver is compatible with the following versions of Palisade:
     

    -
    - - - - - - - - - - - - - - - - - - - - - -
    -
    - Version
    -
    -
    - Event Input
    -
    -
    - Trimble Part Number
    -
    -
    - 7.02
    -
    -
    - No
    -
    -
    - 26664-00
    -
    -
    - 7.02E
    -
    -
    - Yes
    -
    -
    - 26664-10
    -
    -
    - 7.12
    -
    -
    - Yes
    -
    -
    - 38158-00
    -
    -
    -
    -
    - Note: When using Palisade 26664-00, you must set fudge flag2 to 1 in ntp.conf. See configuration. -
    -
    -

    GPS Installation

    - A location with unobstructed view of the horizon is recommended. Palisade is designed to be securely mounted atop standard 3/4 inch threaded pipe. -

    The 12 conductor (dia. 10 mm)  power and I/O cable must be routed from the rooftop site to the NTP server and properly strain relieved.

    -

    GPS Connection

    - The Palisade is equipped with dual (A & B) RS-422 serial interfaces and a differential TTL PPS output. An RS-232 / RS-422 Interface Module is supplied with the Palisade NTP Synchronization Kit. Palisade port A must be connected to the NTP host server. Maximum antenna cable length is 500 meters. See the pinouts table for detailed connection Information. -

    Palisade's port B provides a TSIP (Trimble Standard Interface Protocol) interface for diagnostics, configuration, and monitoring. Port B and the PPS output are not currently used by the Palisade NTP reference clock driver.
     

    -
    -
    -

    O/S Serial Port Configuration

    - The driver attempts to open the device /dev/palisadeu where u is the NTP refclock unit number as defined by the LSB of the refclock address.  Valid refclock unit numbers are 0 - 3. -

    The user is expected to provide a symbolic link to an available serial port device.  This is typically performed by a command such as:

    -
    - ln -s /dev/ttyS0 /dev/palisade0
    - Windows NT does not support symbolic links to device files. COMx: is used by the driver, based on the refclock unit number, where unit 1 corresponds to COM1: and unit 3 corresponds to COM3:
      -

    NTP Configuration

    - Palisade NTP configuration file "ntp.conf" with event polling:
    - #------------------------------------------------------------------------------
    - # The Primary reference
    - server 127.127.29.0 # Trimble Palisade GPS Refclock Unit #0
    - peer terrapin.csc.ncsu.edu # internet server
    - # Drift file for expedient re-synchronization after downtime or reboot.
    - driftfile /etc/ntp.drift
    - #------------------------------------------------------------------------------ -

    Configuration without event polling:
    - #------------------------------------------------------------------------------
    - # The Primary reference
    - server 127.127.29.0 # Trimble Palisade GPS (Stratum 1).
    - # Set packet delay
    - fudge 127.127.29.0 time1 0.020
    - # and set flag2 to turn off event polling.
    - fudge 127.127.29.0 flag2 1
    - #------------------------------------------------------------------------------
     

    -

    Time Transfer and Polling

    - Time transfer to the NTP host is performed via the Palisade's comprehensive time packet output. The time packets are output once per second, and whenever an event timestamp is requested. -

    The driver requests an event time stamp at the end of each polling interval, by pulsing the RTS (request to send) line on the serial port. The Palisade GPS responds with a time stamped event packet.

    -

    Time stamps are reported by the Palisade with respect to UTC time. The GPS receiver must download UTC offset information from GPS satellites. After an initial UTC download, the receiver will always start with correct UTC offset information.
     

    -

    Run NTP in Debugging Mode

    - The following procedure is recommended for installing and testing a Palisade NTP driver: -
      -
    1. Perform initial checkout procedures. Place the GPS receiver outdoors; with clear view of the sky. Allow the receiver to obtain an UTC almanac. -
    2. Verify presence of timing packets by observing the 1 Hz (PPS) led on the interface module. It should flash once per second. -
    3. Connect Palisade's port A to the NTP host. -
    4. Configure NTP and the serial I/O port on the host system. -
    5. Initially use fudge flag2 in ntp.conf, to disable event polling (see configuration). -
    6. Run NTP in debug mode (-d -d), to observe Palisade_receive events. -
    7. The driver reports the tracking status of the receiver. Make sure it is tracking several satellites. -
    8. Remove fudge flag2 and restart ntpd in debug mode to observe palisade_receive events. -
    9. If event polling fails, verify the connections and that the host hardware supports RTS control. -
    -

    Event Logging

    - System and Event log entries are generated by NTP to report significant system events. Administrators should monitor the system log to observe NTP error messages. Log entries generated by the Palisade NTP reference clock driver will be of the form: -
    -
    Nov 14 16:16:21 terrapin ntpd[1127]: Palisade #0: message
    -
    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. If event capture is not used, time1 should be set to 20 milliseconds to correct serial line and operating system delays incurred in capturing time stamps from the synchronous packets. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, GPS. -
    flag2 0 | 1 -
    When set to 1, driver does not use hardware event capture. The synchronous packet output by the receiver at the beginning of each second is time stamped by the driver. If triggering the event pulse fails, the driver falls back to this mode automatically. -
    -

    Mode Parameter

    -
    -
    mode number -
    The mode parameter to the server command specifies the specific hardware this driver is for. The default is 0 for a normal Trimble Palisade. The only other option at this time is 1 for a Endrun Praecis in Trimble emulation mode. -
    -

    DEFINEs

    - The following constants are defined in the driver source code. These defines may be modified to improve performance or adapt to new operating systems.
      -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    LabelDefinitionDefault Value
    DEVICEThe serial port device to be used by the driver/dev/palisadeu
    PRECISIONAccuracy of time transfer1 microsecond
    CURRENT_UTCValid GPS - UTC offset13
    SPEED232Host RS-232 baud rateB9600
    TRMB_MINPOLL Minimum polling interval5 (32 seconds)
    TRMB_MAXPOLLMaximum interval between polls7 (128 seconds)
    -
    -

    Data Format

    - Palisade port A can output two synchronous time packets. The NTP driver can use either packet for synchronization. Packets are formatted as follows: -

    Packet 8F-AD (Primary NTP Packet)

    -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    ByteItemTypeMeaning
    0Sub-Packet IDBYTESubcode 0xAD
    1 - 2Event CountINTEGERExternal event count recorded (0 = PPS)
    3 - 10Fractional SecondDOUBLETime elapsed in current second (s)
    11HourBYTEHour (0 - 23)
    12MinuteBYTEMinute (0 - 59)
    13SecondBYTESecond (0 - 59; 60 = leap)
    14DayBYTEDate (1 - 31)
    15MonthBYTEMonth (1 - 12)
    16 - 17YearINTEGERYear (4 digit)
    18Receiver StatusBYTETracking Status
    19UTC FlagsBYTELeap Second Flags
    20ReservedBYTEContains 0xFF
    21ReservedBYTEContains 0xFF
    -
    -
    -

    Leap Second Flag Definition:

    Bit 0:  (1) UTC Time is available
    - Bits 1 - 3: Undefined
    Bit 4:  (1) Leap Scheduled: Leap second pending asserted by GPS control segment.
    Bit 5:  (1) Leap Pending: set 24 hours before, until beginning of leap second.
    Bit 6:  (1) GPS Leap Warning: 6 hours before until 6 hours after leap event
    Bit 7:  (1) Leap In Progress. Only set during the leap second. -

    Tracking Status Flag Definitions:

    -
    -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    CodeMeaningAccuracyReceiver Mode
    0Receiver is Navigating+/- 1 usSelf Survey
    1Static 1 Sat. Timing Mode +/- 1 us1-D Timing
    2Approximate Time20 - 50 msAcquisition
    3StartupN/AInitialization
    4StartupN/AInitialization
    5Dilution of Position too High 5 ppmSelf Survey
    6Static 1 Sat. Timing: Sat. not usable5 ppm1-D Timing
    7No Satellites UsableN/ASelf Survey
    8Only 1 Satellite Usable20 - 50 msSelf Survey
    9Only 2 Satellite Usable20 - 50 msSelf Survey
    10Only 3 Satellites Usable20 - 50 msSelf Survey
    11Invalid SolutionN/AError
    12Differential Corrections N/AN/A
    13Overdetermined Fixes+/- 100 nsTiming Steady State
    -
    -

    Packet 8F-0B (Comprehensive Timing Packet)

    -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    ByteItemTypeMeaning
    0Sub-Packet IDBYTESubcode 0x0B
    1 - 2Event CountINTEGERExternal event count recorded (0 = PPS)
    3 - 10UTC / GPS TOWDOUBLEUTC / GPS time of week (seconds)
    11DateBYTEDay of Month
    12MonthBYTEMonth of Event
    13 - 14YearINTYear of event
    15Receiver ModeBYTEReceiver operating dimensions: 
    0: Horizontal (2D) 
    1: Full Position (3D) 
    2: Single Satellite (0D) 
    3: Automatic (2D / 3D) 
    4: DGPS reference 
    5: Clock hold (2D) 
    - 6: Over determined Clock
    15 - 17UTC OffsetINTEGERUTC Offset value (seconds)
    18 - 25Oscillator BiasDOUBLEOscillator BIAS (meters)
    26 - 33Oscillator Drift RateDOUBLEOscillator Drift (meters / second)
    34 - 37Bias UncertaintySINGLEOscillator bias uncertainty (meters)
    38 - 41Drift UncertaintySINGLEOscillator bias rate uncertainty (m / sec)
    42 - 49LatitudeDOUBLELatitude in radians
    50 - 57LongitudeDOUBLELongitude in radians
    58 - 65AltitudeDOUBLEAltitude above mean sea level, in meters
    66 - 73Satellite IDBYTESV Id No. of tracked satellites
    -
    -

    Pinouts

    - The following connections are required when connecting Palisade with a host:
     
      -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    DescriptionHostPalisade 
    Port ADB-9DB-25RS-232RS-422Palisade Pin
    Receive Data 23<-->GreenGreen / Blue8 (T-) & 10 (T+)
    Request to Send74<-->GrayGray / White6 (R-) & 7 (R+)
    Signal Ground57<-->BlackBlack9 (GND)
    Port B
    Receive Data 23<-->BrownBrown / Yellow4 (T-) & 5 (T+)
    Transmit Data32<-->VioletOrange/ Violet2 (R-) & 3 (R+)
    Signal Ground57<-->BlackBlack9 (GND)
    -
    -
    - Note: If driving the RS-422 inputs on the Palisade single ended, i.e. using the Green and Gray connections only, does not work on all serial ports. Use of the Palisade NTP Synchronization Interface Module is recommended.
    -
    - The 12 pin connector pinout definition:
    - Face the round 12 pin connector at the end of the cable, with the notch turned upwards.
    - Pin 1 is to the left of the notch. Pins 2 - 8 wrap around the bottom, counterclockwise to pin 9 on the right of the notch. Pin 10 is just below the notch. Pins 10 (top), 11 (bottom left) and 12 (bottom right) form a triangle in the center of the connector.
    -
    - Pinouts for the Palisade NTP host adapter (Trimble PN 37070) DB-25 M connector are as follows:
    -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    DB-25MConductor PalisadeDescription
    Red1Power
    Black9Ground
    9Black/White12PPS -
    10 Green8Transmit Port A (T-)
    11 Brown4Transmit Port B (T-)
    12 Gray7Receive Port A (R+)
    13Orange3Receive Port B (R+)
    21Orange/White11PPS +
    22Blue10Transmit Port A (T+)
    23Yellow5Transmit Port B (T+)
    24White6Receive Port A (R-)
    25Violet2Receive Port B (R-)
    -
    -

    -
    -

    Questions or Comments:
    - Sven Dietrich
    - Trimble Navigation Ltd.

    -

    (last updated July 29, 1999)

    -
    - - ; - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver3.html src.ntp/contrib/ntp/html/drivers/driver3.html --- src/contrib/ntp/html/drivers/driver3.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver3.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,76 +0,0 @@ - - - - - - - - PSTI/Traconex 1020 WWV/WWVH Receiver - - - - -

    PSTI/Traconex 1020 WWV/WWVH Receiver

    -
    -

    Synopsis

    -

    Address: 127.127.3.u
    - Reference ID: WWV
    - Driver ID: WWV_PST
    - Serial Port: /dev/wwvu; 9600 baud, 8-bits, no parity
    - Features: tty_clk

    -

    Description

    -

    This driver supports the PSTI 1010 and Traconex 1020 WWV/WWVH Receivers. No specific claim of accuracy is made for these receiver, but actual experience suggests that 10 ms would be a conservative assumption.

    -

    The dipswitches should be set for 9600 bps line speed, 24-hour day-of-year format and UTC time zone. Automatic correction for DST should be disabled. It is very important that the year be set correctly in the DIP-switches; otherwise, the day of year will be incorrect after 28 April of a normal or leap year. As the there are only four dipswitches to set the year and the base value of zero correspondes to 1986, years beyond 2001 recycle with the value of zero corresponding to 2002. The propagation delay DIP-switches should be set according to the distance from the transmitter for both WWV and WWVH, as described in the instructions. While the delay can be set only to within 11 ms, the fudge time1 parameter can be used for vernier corrections.

    -

    Using the poll sequence QTQDQM, the response timecode is in three sections totalling 50 ASCII printing characters, as concatenated by the driver, in the following format:

    -
    -ahh:mm:ss.fffs<cr> yy/dd/mm/ddd<cr>
    -frdzycchhSSFTttttuuxx<cr>
    -
    -on-time = first <cr>
    -hh:mm:ss.fff = hours, minutes, seconds, milliseconds
    -a = AM/PM indicator (' ' for 24-hour mode)
    -yy = year (from DIPswitches)
    -dd/mm/ddd = day of month, month, day of year
    -s = daylight-saving indicator (' ' for 24-hour mode)
    -f = frequency enable (O = all frequencies enabled)
    -r = baud rate (3 = 1200, 6 = 9600)
    -d = features indicator (@ = month/day display enabled)
    -z = time zone (0 = UTC)
    -y = year (5 = 91)
    -cc = WWV propagation delay (52 = 22 ms)
    -hh = WWVH propagation delay (81 = 33 ms)
    -SS = status (80 or 82 = operating correctly)
    -F = current receive frequency (4 = 15 MHz)
    -T = transmitter (C = WWV, H = WWVH)
    -tttt = time since last update (0000 = minutes)
    -uu = flush character (03 = ^c)
    -xx = 94 (unknown)
    -

    The alarm condition is indicated by other than 8 at a, which occurs during initial synchronization and when received signal is lost for an extended period; unlock condition is indicated by other than 0000 in the tttt subfield.

    -

    Monitor Data

    -

    When enabled by the flag4 fudge flag, every received timecode is written as-is to the clockstats file.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default WWV. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Not used by this driver. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Not used by this driver. -
    -

    Additional Information

    -

    Reference Clock Drivers

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver30.html src.ntp/contrib/ntp/html/drivers/driver30.html --- src/contrib/ntp/html/drivers/driver30.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver30.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,83 +0,0 @@ - - - - - - - - Motorola Oncore GPS Receiver - - - - -

    Motorola Oncore GPS receiver

    -
    -

    Synopsis

    -

    Address: 127.127.30.u
    - Reference ID: GPS
    - Driver ID: ONCORE
    - Serial Port: /dev/oncore.serial.u;  9600 baud, 8-bits, no parity.
    - PPS Port: /dev/oncore.pps.uPPS_CAPTUREASSERT required,  PPS_OFFSETASSERT supported.
    - Configuration File: ntp.oncore, or ntp.oncore.u, or ntp.oncoreu, in /etc/ntp or /etc.

    -

    Description

    -

    This driver supports most models of the Motorola Oncore GPS receivers (Basic, PVT6, VP, UT, UT+, GT, GT+, SL, M12, M12+T), as long as they support the Motorola Binary Protocol.

    -

    The interesting versions of the Oncore are the VP, the UT+, the "Remote" which is a prepackaged UT+, and the M12 Timing. The VP is no longer available new, and the UT, GT, and SL are at end-of-life. The Motorola evaluation kit can be recommended. It interfaces to a PC straightaway, using the serial (DCD) or parallel port for PPS input and packs the receiver in a nice and sturdy box. Less expensive interface kits are available from TAPR and Synergy.
     

    -
    - - - - - - - - - - - -
    gifgifgif
    -
    - UT+ oncore
    -
    -
    - Evaluation kit
    -
    -
    - Oncore Remote
    -
    -
    -

    The driver requires a standard PPS interface for the pulse-per-second output from the receiver. The serial data stream alone does not provide precision time stamps (0-50msec variance, according to the manual), whereas the PPS output is precise down to 50 nsec (1 sigma) for the VP/UT models and 25 nsec for the M12 Timing. If you do not have the PPS signal available, then you should probably be using the NMEA driver rather than the Oncore driver. Most of these are available on-line

    -

    The driver will use the "position hold" mode with user provided coordinates, the receivers built-in site-survey, or a similar algorithm implemented in this driver to determine the antenna position.

    -

    Monitor Data

    - The driver always puts a lot of useful information on the clockstats file, and when run with debugging can be quite chatty on stdout. When first starting to use the driver you should definitely review the information written to the clockstats file to verify that the driver is running correctly. -

    In addition, on platforms supporting Shared Memory, all of the messages received from the Oncore receiver are made available in shared memory for use by other programs. See the Oncore-SHMEM manual page for information on how to use this option. For either debugging or using the SHMEM option, an Oncore Reference Manual for the specific receiver in use will be required.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default GPS. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Not used by this driver. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Not used by this driver. -
    -

    Additional Information

    -

    The driver was initially developed on FreeBSD, and has since been tested on Linux, SunOS and Solaris.

    -

    Configuration

    -

    There is a driver specific configuration file ntp.oncore (or ntp.oncore.u or ntp.oncoreu if you must distinguish between more than one Oncore receiver) that contains information on the startup mode, the location of the GPS receiver, an offset of the PPS signal from zero, and the cable delay. The offset shifts the PPS signal to avoid interrupt pileups `on' the second, and adjusts the timestamp accordingly. See the driver source for information on this file. The default with no file is: no delay, no offset, and a site survey is done to get the location of the gps receiver.

    -

    The following three options can be set in the driver specific configuration file only if the driver is using the PPSAPI. The edge of the PPS signal that is `on-time' can be set with the keywords [ASSERT/CLEAR] and the word HARDPPS will cause the PPS signal to control the kernel PLL.

    -

    Performance

    -

    Really good. With the VP/UT+, the generated PPS pulse is referenced to UTC(GPS) with better than 50 nsec (1 sigma) accuracy. The limiting factor will be the timebase of the computer and the precision with which you can timestamp the rising flank of the PPS signal. Using FreeBSD, a FPGA based Timecounter/PPS interface, and an ovenized quartz oscillator, that performance has been reproduced. For more details on this aspect: Sub-Microsecond timekeeping under FreeBSD.

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver31.html src.ntp/contrib/ntp/html/drivers/driver31.html --- src/contrib/ntp/html/drivers/driver31.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver31.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,58 +0,0 @@ - - - - - - - - Rockwell Jupiter GPS Receiver - - - - -

    Rockwell Jupiter GPS receiver

    -
    -

    Synopsis

    -

    Address: 127.127.31.u
    - Reference ID: GPS
    - Driver ID: JUPITER
    - Serial Port: /dev/gpsu;  9600 baud, 8-bits, no parity.

    -

    Description

    -

    This driver supports at least some models of the Rockwell Jupiter GPS receivers (Jupiter 11, Jupiter-T), they must at least support the Zodiac Binary Protocol.

    -

    The driver requires a standard PPS interface for the pulse-per-second output from the receiver. The serial data stream alone does not provide precision time stamps, whereas the PPS output is precise down to 40 ns (1 sigma) for the Jupiter 11 and 25 ns (1 sigma) for Jupiter-T according to the documentation. If you do not have the PPS signal available, then you should probably not be using the Jupiter receiver as a time source. This driver requires a PPS signal and the time output from Jupiter receivers is not predictable in NMEA mode; the reported time can take one second steps.

    -

    Monitor Data

    -

    The driver always puts a lot of useful information on the clockstats file, and when run with debugging can be quite chatty on stdout. When first starting to use the driver you should definitely review the information written to the clockstats file to verify that the driver is running correctly.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. Should be left at zero. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default GPS. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Specifies the mobility of the GPS receiver: 0 for walking (default), 1 for driving. -
    flag3 0 | 1 -
    Specifies the PPS signal on-time edge: 0 for assert (default), 1 for clear. -
    flag4 0 | 1 -
    Not used by this driver. -
    -

    Additional Information

    -

    The driver was resurrected from a sorry state using the Windows NT port and a Jupiter 11, and has since seen little testing on other platforms. On Windows there exist a barrier though, as there is no publicly available PPSAPI implementation, at least not to my knowledge. However, there has been one success report using Linux 2.4.20 and PPSkit 2.1.1.

    -

    The Jupiter receivers seem to have quite a few names. They are referred to at least as Rockwell receivers, Navman receivers, Zodiac receivers, Conexant receivers and SiRF Technology receivers. Rockwell seems to be the original and most commonly used name and Navman seems to be the current supplier.

    -

    Configuration

    -

    The edge of the PPS signal that is `on-time' can be set with flag2. There is currently no way to cause the PPS signal to control the kernel PLL.

    -

    Performance

    -

    The performance is largely unexplored. I have achieved submillisecond stability using a Jupiter 11, but the poor result is more than likely due to the proprietary PPSAPI implementation or Windows itself.

    -

    This driver does not handle leap seconds.

    -
    - - - - - -= \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver32.html src.ntp/contrib/ntp/html/drivers/driver32.html --- src/contrib/ntp/html/drivers/driver32.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver32.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,38 +0,0 @@ - - - - - - - Chrono-log K-series WWVB receiver - - - - -

    Chrono-log K-series WWVB receiver

    -
    -

    Synopsis

    -

    Address: 127.127.32.u
    - Reference ID: CHRONOLOG
    - Driver ID: CHRONOLOG
    - Serial Port: /dev/chronologu; 2400 bps, 8-bits, no parity
    -
    - Features: (none)

    -

    Description

    -

    This driver supports the Chrono-log K-series WWVB receiver. This is a very old receiver without provisions for leap seconds, quality codes, etc. It assumes output in the local time zone, and that the C library mktime()/localtime() routines will correctly convert back and forth between local and UTC. There is a hack in the driver for permitting UTC, but it has not been tested.

    -

    Most of this code is originally from refclock_wwvb.c with thanks. It has been so mangled that wwvb is not a recognizable ancestor.

    -
    -Timecode format: Y yy/mm/ddCLZhh:mm:ssCL
    -Y - year/month/date line indicator
    -yy/mm/dd -- two-digit year/month/day
    -C - \r (carriage return)
    -L - \n (newline)
    -Z - timestamp indicator
    -hh:mm:ss - local time
    -
    - Last modified: Sun Feb 14 11:57:27 EST 1999 -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver33.html src.ntp/contrib/ntp/html/drivers/driver33.html --- src/contrib/ntp/html/drivers/driver33.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver33.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,35 +0,0 @@ - - - - - - - Dumb Clock - - - - -

    Dumb Clock

    -
    -

    Synopsis

    -

    Address: 127.127.33.u
    - Reference ID: DUMBCLOCK
    - Driver ID: DUMBCLOCK
    - Serial Port: /dev/dumbclocku; 9600 bps, 8-bits, no parity
    - Features: (none)

    -

    Description

    -

    This driver supports a dumb ASCII clock that only emits localtime at a reliable interval. This has no provisions for leap seconds, quality codes, etc. It assumes output in the local time zone, and that the C library mktime()/localtime() routines will correctly convert back and forth between local and UTC.

    -

    Most of this code is originally from refclock_wwvb.c with thanks. It has been so mangled that wwvb is not a recognizable ancestor.

    -
    -Timecode format: hh:mm:ssCL
    -hh:mm:ss - local time
    -C - \r (carriage return)
    -L - \n (newline)
    -
    -
    - Last modified: Sun Feb 14 12:07:01 EST 1999 -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver34.html src.ntp/contrib/ntp/html/drivers/driver34.html --- src/contrib/ntp/html/drivers/driver34.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver34.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,117 +0,0 @@ - - - - - - Ultralink Clock - -

    Ultralink Clock

    -
    -

    Synopsis

    - Address: 127.127.34.u
    - Reference ID: WWVB
    - Driver ID: ULINK
    - Serial Port: /dev/wwvbu; 9600 bps, 8-bits, no parity
    -
    - Features: (none) -

    Description

    -

    This driver supports the Ultralink Model 325 (replacement for Model 320) RS-232 powered WWVB receiver. PDF specs available on http://www.ulio.com/. This driver also supports the Model 320, 330,331,332 decoders in both polled or continous time code mode.
    - Leap second and quality are supported.

    -

    Most of this code is originally from refclock_wwvb.c with thanks. Any mistakes are mine. Any improvements are welcome.

    -
    -
      The Model 325 timecode format is:
    - 
    -   <cr><lf>RQ_1C00LYYYY+DDDUTCS_HH:MM:SSL+5
    - 
    -  where:
    - 
    -  R = Signal readability indicator, ranging from R1 to R5  
    -  Q	R1 is unreadable, R5 is best reception
    -  _ = Space
    -  1 = prev. received data bit, values: 0, 1 ,M or ? unknown
    -  C = Signal reception from (C)olorado or (H)awaii
    -  0 = Hours since last WWVB time and flag code update, values
    -  0	00 to 99 (hopefully always 00)
    -  L = HEX A5 if receiver is locked to WWVB, Space if not
    -  YYYY = Year from 2000 to 2099
    -  + = '+' if current year is a leap year, else ' '
    -  DDD = current day in the year from 1 to 365/366
    -  UTC = timezone (always UTC)
    -  S = Daylight savings indicator, (S)TD, (D)ST, (O) transition
    -      into DST, (I) transition out of DST
    -  _ = Space
    -  HH = UTC hour 0 to 23
    -  : = Time delimiter, ':' if synced, Space if not
    -  MM = Minutes of current hour from 0 to 59
    -  : = Time delimiter, ':' if synced, Space if not
    -  SS = Seconds of current minute from 0 to 59
    -  mm = 10's milliseconds of the current second from 00 to 99
    -  L  = Leap second pending at end of month, (I)nsert, (D)elete
    -       or Space
    -  +5 = UT1 correction, +/- .1 sec increments
    - 
    -

    Note that Model 325 reports a very similar output like Model 33X series. The driver for this clock is similar to Model 33X behavior. On a unmodified new ULM325 clock, the polling flag (flag1 =1) needs to be set.

    -
    -
      The Model 320 timecode format is:
    - 
    -   <cr><lf>SQRYYYYDDD+HH:MM:SS.mmLT<cr>
    - 
    -  where:
    - 
    -  S = 'S' -- sync'd in last hour, '0'-'9' - hours x 10 since last update, else '?'
    -  Q = Number of correlating time-frames, from 0 to 5
    -  R = 'R' -- reception in progress, 'N' -- Noisy reception, ' ' -- standby mode
    -  YYYY = year from 1990 to 2089
    -  DDD = current day from 1 to 366
    -  + = '+' if current year is a leap year, else ' '
    -  HH = UTC hour 0 to 23
    -  MM = Minutes of current hour from 0 to 59
    -  SS = Seconds of current minute from 0 to 59
    -  mm = 10's milliseconds of the current second from 00 to 99
    -  L  = Leap second pending at end of month -- 'I' = inset, 'D'=delete
    -  T  = DST <-> STD transition indicators
    - 
    -

    Note that this driver does not do anything with the T flag.

    -

    The M320 also has a 'U' command which returns UT1 correction information. It is not used in this driver.

    -
    -
      The Model 33x timecode format is:
    -
    -    S9+D 00 YYYY+DDDUTCS HH:MM:SSl+5
    -
    -  Where:
    -
    -  S =    sync indicator S insync N not in sync
    -         the sync flag is WWVB decoder sync
    -         nothing to do with time being correct
    -  9+ =   signal level 0 thru 9+ If over 9 indicated as 9+
    -  D  =   data bit ( fun to watch but useless ;-)
    -  space
    -  00 =   hours since last GOOD WWVB frame sync
    -  space
    -  YYYY = current year
    -  +  =   leap year indicator
    -  DDD =  day of year
    -  UTC =  timezone (always UTC)
    -  S  =   daylight savings indicator
    -  space
    -  HH  =  hours
    -  :  =   This is the REAL in sync indicator (: = insync)
    -  MM  =  minutes
    -  :  =   : = in sync ? = NOT in sync
    -  SS  =  seconds
    -  L  =   leap second flag
    -  +5 =   UT1 correction (sign + digit ))
    - 
    -

    This driver ignores UT1 correction,DST indicator,Leap year and signal level.

    -
    -

    Fudge factors

    -

    flag1 polling enable (1=poll 0=no poll)

    -
    -
    mail
    - Last modified: Mon Mar 8 10:12:08 PST 2004 -
    - - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver35.html src.ntp/contrib/ntp/html/drivers/driver35.html --- src/contrib/ntp/html/drivers/driver35.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver35.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,48 +0,0 @@ - - - - - - - Conrad parallel port radio clock - - - - -

    Conrad parallel port radio clock

    -
    -

    Synopsis

    -

    Address: 127.127.35.u
    - Reference ID: PCF
    - Driver ID: PCF
    - Parallel Port: /dev/pcfclocks/u or /dev/pcfclocku

    -

    Description

    -

    This driver supports the parallel port radio clock sold by Conrad Electronic under order numbers 967602 and 642002. This clock is put between a parallel port and your printer. It receives the legal German time, which is either CET or CEST, from the DCF77 transmitter and uses it to set its internal quartz clock. The DCF77 transmitter is located near to Frankfurt/Main and covers a radius of more than 1500 kilometers.

    -

    The pcfclock device driver is required in order to use this reference clock driver. Currently device drivers for Linux and FreeBSD are available.

    -

    This driver uses C library functions to convert the received timecode to UTC and thus requires that the local timezone be CET or CEST. If your server is not located in Central Europe you have to set the environment variable TZ to CET before starting ntpd.

    -

    Monitor Data

    -

    Each timecode is written to the clockstats file in the format YYYY MM DD HH MI SS.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.1725. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default PCF. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    If set to 1, the radio clock's synchronisation status bit is ignored, ie the timecode is used without a check. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Not used by this driver. -
    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver36.html src.ntp/contrib/ntp/html/drivers/driver36.html --- src/contrib/ntp/html/drivers/driver36.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver36.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,146 +0,0 @@ - - - - - - - - Radio WWV/H Audio Demodulator/Decoder - - - - -

    Radio WWV/H Audio Demodulator/Decoder

    -
    -

    Synopsis

    - Address: 127.127.36.u
    - Reference ID: WVf or WHf
    - Driver ID: WWV_AUDIO
    - Autotune Port: /dev/icom; 1200/9600 baud, 8-bits, no parity
    - Audio Device: /dev/audio and /dev/audioctl -

    Description

    - This driver synchronizes the computer time using data encoded in shortwave radio transmissions from NIST time/frequency stations WWV in Ft. Collins, CO, and WWVH in Kauai, HI. Transmissions are made continuously on 2.5, 5, 10 and 15 MHz from both stations and on 20 MHz from WWV. An ordinary shortwave receiver can be tuned manually to one of these frequencies or, in the case of ICOM receivers, the receiver can be tuned automatically by the driver as propagation conditions change throughout the day and season. The performance of this driver when tracking one of the stations is ordinarily better than 1 ms in time with frequency drift less than 0.1 PPM when not tracking any station.

    The demodulation and decoding algorithms used by this driver are based on a machine language program developed for the TAPR DSP93 DSP unit, which uses the TI 320C25 DSP chip. The analysis, design and performance of the program running on this unit is described in: Mills, D.L. A precision radio clock for WWV transmissions. Electrical Engineering Report 97-8-1, University of Delaware, August 1997, 25 pp. Available from www.eecis.udel.edu/~mills/reports.htm. For use in this driver, the original program was rebuilt in the C language and adapted to the NTP driver interface. The algorithms have been modified to improve performance, especially under weak signal conditions and to provide an automatic frequency and station selection feature.

    -

    This driver incorporates several features in common with other audio drivers such as described in the Radio CHU Audio Demodulator/Decoder and the IRIG Audio Decoder pages. They include automatic gain control (AGC), selectable audio codec port and signal monitoring capabilities. For a discussion of these common features, as well as a guide to hookup, debugging and monitoring, see the Reference Clock Audio Drivers page.

    -

    The WWV signal format is described in NIST Special Publication 432 (Revised 1990). It consists of three elements, a 5-ms, 1000-Hz pulse, which occurs at the beginning of each second, a 800-ms, 1000-Hz pulse, which occurs at the beginning of each minute, and a pulse-width modulated 100-Hz subcarrier for the data bits, one bit per second. The WWVH format is identical, except that the 1000-Hz pulses are sent at 1200 Hz. Each minute encodes nine BCD digits for the time of century plus seven bits for the daylight savings time (DST) indicator, leap warning indicator and DUT1 correction.

    -

    Program Architecture

    -

    As in the original program, the clock discipline is modelled as a Markov process, with probabilistic state transitions corresponding to a conventional clock and the probabilities of received decimal digits. The result is a performance level which results in very high accuracy and reliability, even under conditions when the minute beep of the signal, normally its most prominent feature, can barely be detected by ear using a communications receiver.

    -

    The analog audio signal from the shortwave radio is sampled at 8000 Hz and converted to digital representation. The 1000/1200-Hz pulses and 100-Hz subcarrier are first separated using two IIR filters, a 600-Hz bandpass filter centered on 1100 Hz and a 150-Hz lowpass filter. The minute synch pulse is extracted using an 800-ms synchronous matched filter and pulse grooming logic which discriminates between WWV and WWVH signals and noise. The second synch pulse is extracted using a 5-ms FIR matched filter and 8000-stage comb filter.

    -

    The phase of the 100-Hz subcarrier relative to the second synch pulse is fixed at the transmitter; however, the audio stage in many radios affects the phase response at 100 Hz in unpredictable ways. The driver adjusts for each radio using two 170-ms synchronous matched filters. The I (in-phase) filter is used to demodulate the subcarrier envelope, while the Q (quadrature-phase) filter is used in a tracking loop to discipline the codec sample clock and thus the demodulator phase.

    -

    A bipolar data signal is determined from the matched filter I and Q channels using a pulse-width discriminator. The discriminator samples the I channel at 15 ms (n), 200 ms (s1) and 500 ms (s0), and the envelope (RMS I and Q channels) at 200 ms (e1) and the end of the second (e0). The bipolar data signal is expressed s1 - 2s0 - n. Note that, since the signals s0 and s1 include the noise n, this term cancels out. The data bit SNR is calculated as 20 log10(e1 / e0). If the driver has not synchronized to the minute pulse, or if the data bit amplitude e1 or SNR are below thresholds, the bit is considered invalid and the bipolar signal is forced to zero.

    -

    The bipolar signal is exponentially averaged in a set of 60 accumulators, one for each second, to determine the semi-static miscellaneous bits, such as DST indicator, leap second warning and DUT1 correction. In this design a data average value larger than a positive threshold is interpreted as +1 (hit) and a value smaller than a negative threshold as a -1 (miss). Values between the two thresholds, which can occur due to signal fades, are interpreted as an erasure and result in no change of indication.

    -

    The BCD digit in each digit position of the timecode is represented as four data bits. The bits are correlated with the bits corresponding to each of the valid decimal digits in this position. If any of the four bits are invalid, the correlated value for all digits in this position is assumed zero. In either case, the values for all digits are exponentially averaged in a likelihood vector associated with this position. The digit associated with the maximum over all averaged values then becomes the maximum likelihood selection for this position and the ratio of the maximum over the next lower value represents the digit SNR.

    -

    The decoding matrix contains nine row vectors, one for each digit position. Each row vector includes the maximum likelihood digit, likelihood vector and other related data. The maximum likelihood digit for each of the nine digit positions becomes the maximum likelihood time of the century. A built-in transition function implements a conventional clock with decimal digits that count the minutes, hours, days and years, as corrected for leap seconds and leap years. The counting operation also rotates the likelihood vector corresponding to each digit as it advances. Thus, once the clock is set, each clock digit should correspond to the maximum likelihood digit as transmitted.

    -

    Each row of the decoding matrix also includes a compare counter and the most recently determined maximum likelihood digit. If a digit likelihood exceeds the decision level and compares with previous digits for a number of successive minutes in any row, the maximum likelihood digit replaces the clock digit in that row. When this condition is true for all rows and the second epoch has been reliably determined, the clock is set (or verified if it has already been set) and delivers correct time to the integral second. The fraction within the second is derived from the logical master clock, which runs at 8000 Hz and drives all system timing functions.

    -

    The logical master clock is derived from the audio codec clock. Its frequency is disciplined by a frequency-lock loop (FLL) which operates independently of the data recovery functions. At averaging intervals determined by the measured jitter, the frequency error is calculated as the difference between the most recent and the current second epoch divided by the interval. The sample clock frequency is then corrected by this amount. When first started, the frequency averaging interval is eight seconds, in order to compensate for intrinsic codec clock frequency offsets up to 125 PPM. Under most conditions, the averaging interval doubles in stages from the initial value to over 1000 seconds, which results in an ultimate frequency precision of 0.125 PPM, or about 11 ms/day.

    -

    It is important that the logical clock frequency is stable and accurately determined, since in most applications the shortwave radio will be tuned to a fixed frequency where WWV or WWVH signals are not available throughout the day. In addition, in some parts of the US, especially on the west coast, signals from either or both WWV and WWVH may be available at different times or even at the same time. Since the propagation times from either station are almost always different, each station must be reliably identified before attempting to set the clock.

    -

    Reliable station identification requires accurate discrimination between very weak signals in noise and noise alone. The driver very aggresively soaks up every scrap of signal information, but has to be careful to avoid making pseudo-sense of noise alone. The signal quality metric depends on the minute pulse amplitude and SNR measured in second 0 of the minute, together with the data subcarrier amplitude and SNR measured in second 1. If all four values are above defined thresholds a hit is declared, otherwise a miss. The number of hits declared in the last six minutes by each station represents the high order bits of the metric value, while the current minute pulse amplitude repressents the low order bits. The resulting value is then scaled from zero to 100 for use as a quality indicator. It is used by the autotune function described below and reported in the timecode string.

    -

    Performance

    -

    It is the intent of the design that the accuracy and stability of the indicated time be limited only by the characteristics of the ionospheric propagation medium. Conventional wisdom is that synchronization via the HF medium is good only to a millisecond under the best propagation conditions. The performance of the NTP daemon disciplined by the driver is clearly better than this, even under marginal conditions. Ordinarily, with marginal to good signals and a frequency averaging interval of 1024 s, the frequency is stabilized within 0.1 PPM and the time within 0.5 ms. The frequency stability characteristic is highly important, since the clock may have to free-run for several hours before reacquiring the WWV/H signal.

    -

    The expected accuracy over a typical day was determined using the DSP93 and an oscilloscope and cesium oscillator calibrated with a GPS receiver. With marginal signals and allowing 15 minutes for initial synchronization and frequency compensation, the time accuracy determined from the WWV/H second synch pulse was reliably within 125 ms. In the particular DSP93 used for program development, the uncorrected CPU clock frequency offset was 45.8±0.1 PPM. Over the first hour after initial synchronization, the clock frequency drifted about 1 PPM as the frequency averaging interval increased to the maximum 1024 s. Once reaching the maximum, the frequency wandered over the day up to 1 PPM, but it is not clear whether this is due to the stability of the DSP93 clock oscillator or the changing height of the ionosphere. Once the frequency had stabilized and after loss of the WWV/H signal, the frequency drift was less than 0.5 PPM, which is equivalent to 1.8 ms/h or 43 ms/d. This resulted in a step phase correction up to several milliseconds when the signal returned.

    -

    The measured propagation delay from the WWV transmitter at Boulder, CO, to the receiver at Newark, DE, is 23.5±0.1 ms. This is measured to the peak of the pulse after the second synch comb filter and includes components due to the ionospheric propagation delay, nominally 8.9 ms, communications receiver delay and program delay. The propagation delay can be expected to change about 0.2 ms over the day, as the result of changing ionosphere height. The DSP93 program delay was measured at 5.5 ms, most of which is due to the 400-Hz bandpass filter and 5-ms matched filter. Similar delays can be expected of this driver.

    -

    Program Operation

    The driver begins operation immediately upon startup. It first searches for one or both of the stations WWV and WWVH and attempts to acquire minute synch. This may take some fits and starts, as the driver expects to see several consecutive minutes with good signals and low jitter. If the autotune function is active, the driver will rotate over all five frequencies and both WWV and WWVH stations until at least three good minutes are found.

    When a minute synch candidate has been found, the driver acquires second synch, which can take up to several minutes, depending on signal quality. At the same time the driver accumulates likelihood values for the unit (seconds) digit of the nine digits of the timecode, plus the seven miscellaneous bits included in the WWV/H transmission format. When a good unit digit has been found, the driver accumlates likelihood values for the remaining eight digits of the timecode. When three repetitions of all nine digits have decoded correctly, which normally takes 15 minutes with good signals, and up to 40 minutes when buried in noise, and the second synch has been acquired, the clock is set (or verified) and is selectable to discipline the system clock.

    -

    Once the clock is set, it continues to provide correct timecodes, even if all signals are losst. The time is considered correct as long as the second synch amplitude and SNR are above specified thresholds and jitter is below threshold. As long as the clock is set or verified, the system clock offsets are provided once each minute to the reference clock interface, where they are processed using the same algorithms used with other local reference clocks and remote servers. Using these algorithms, the system clock can in principle be disciplined to a much finer resolution than the 125-ms sample interval would suggest, although the ultimate accuracy is probably limited by propagation delay variations as the ionspheric height varies throughout the day and night.

    -

    The codec clock frequency is disciplined during times when WWV/H signals are available. The algorithm refines the frequency offset using increasingly longer averaging intervals to 1024 s, where the precision is about 0.1 PPM. With good signals, it takes well over two hours to reach this degree of precision; however, it can take many more hours than this in case of marginal signals. Once reaching the limit, the algorithm will follow frequency variations due to temperature fluctuations and ionospheric height variations.

    -

    It may happen as the hours progress around the clock that WWV and WWVH signals may appear alone, together or not at all. When the driver has mitigated which station and frequency is best, it sets the reference identifier to the string WVf for WWV and WHf for WWVH, where f is the frequency in megahertz. If the propagation delays have been properly set with the fudge time1 (WWV) and fudge time2 (WWVH) commands in the configuration file, handover from one station to the other is seamless.

    -

    Once the clock has been set for the first time, it will appear reachable and selectable to discipline the system clock. Operation continues as long as the signal quality from at least one station on at least one frequency is acceptable. A consequence of this design is that, once the clock is set, the time and frequency are disciplined only by the second synch pulse and the clock digits themselves are driven by the clock state machine. If for some reason the state machine drifts to the wrong second, it would never reresynchronize. To protect against this most unlikely situation, if after two days with no signals, the clock is considered unset and resumes the synchronization procedure from the beginning.

    -

    However, as long as the clock has once been set correctly and allowed to converge to the intrinsic codec clock frequency, it will continue to read correctly even during the holdover interval, but with increasing dispersion. Assuming the clock frequency can be disciplined within 1 PPM, it can coast without signals for several days without exceeding the NTP step threshold of 128 ms. During such periods the root dispersion increases at 5 ms per second, which makes the driver appear less likely for selection as time goes on. Eventually, when the dispersion due all causes exceeds 1 s, it is no longer suitable for synchronization.

    -

    To work well, the driver needs a shortwave receiver with good audio response at 100 Hz. Most shortwave and communications receivers roll off the audio response below 250 Hz, so this can be a problem, especially with receivers using DSP technology, since DSP filters can have very fast rolloff outside the passband. Some DSP transceivers, in particular the ICOM 775, have a programmable low frequency cutoff which can be set as low as 80 Hz. However, this particular radio has a strong low frequency buzz at about 10 Hz which appears in the audio output and can affect data recovery under marginal conditions. Although not tested, it would seem very likely that a cheap shortwave receiver could function just as well as an expensive communications receiver.

    -

    Autotune

    -

    The driver includes provisions to automatically tune the radio in response to changing radio propagation conditions throughout the day and night. The radio interface is compatible with the ICOM CI-V standard, which is a bidirectional serial bus operating at TTL levels. The bus can be connected to a serial port using a level converter such as the CT-17.

    -

    Each ICOM radio is assigned a unique 8-bit ID select code, usually expressed in hex format. To activate the CI-V interface, the mode keyword of the server configuration command specifies a nonzero select code in decimal format. A table of ID select codes for the known ICOM radios is given on the Reference Clock Audio Drivers page. A missing mode keyword or a zero argument leaves the interface disabled.

    -

    If specified, the driver will attempt to open the device /dev/icom and, if successful will activate the autotune function and tune the radio to each operating frequency in turn while attempting to acquire minute synch from either WWV or WWVH. However, the driver is liberal in what it assumes of the configuration. If the /dev/icom link is not present or the open fails or the CI-V bus or radio is inoperative, the driver quietly gives up with no harm done.

    -

    Once acquiring minute synch, the driver operates as described above to set the clock. However, during seconds 59, 0 and 1 of each minute it tunes the radio to one of the five broadcast frequencies to measure the minute synch pulse amplitude and SNR in second 0 and data pulse amplitude and SNR in second 1 to update the signal metric. In principle, the data pulse in second 58 is usable, but the AGC in most radios is not fast enough for a reliable measurement. Each of the five frequencies are probed in a five-minute rotation to build a database of current propagation conditions for all signals that can be heard at the time. At the end of each probe a mitigation procedure scans the database and retunes the radio to the best frequency and station found. For this to work well, the radio should be set for a fast AGC recovery time. This is most important while tracking a strong signal, which is normally the case, and then probing another frequency, which may have much weaker signals.

    -

    At the end of each probe, the frequency and station with the maximum metric is chosen, with ties going first to the highest frequency and then to WWV in order. A station is considered valid only if the metric is above a specified threshold' if below, the rotating probes continue until a valid station is found.

    -
    -
    -

    Diagnostics

    -

    The autotune process produces diagnostic information along with the timecode. This is very useful for evaluating the performance of the algorithms, as well as radio propagation conditions in general. The message is produced once each minute for each frequency in turn after minute synch has been acquired.

    -

    wwv5 status agc epoch secamp/secsnr datamp/datsnr wwv wwvh

    -

    where the fields after the wwv5 identifier are: status contains status bits, agc audio gain, epoch second epoch, secamp/secsnr second pulse ampliture/SNR, and wwv and wwvh are two sets of fields, one each for WWV and WWVH. Each of the two fields has the format

    -

    ident score metric minamp/minsnr

    -

    where ident encodes the station (WV for WWV, WH for WWVH) and frequency (2, 5, 10, 15 or 20), score 32-bit shift register recording the hits (1) and misses (0) of the last 32 probes (hits and misses enter from the right), metric is described above, and minamp/minsnr minute pulse ampliture/SNR. An example is:

    -

    wwv5 000d 111 5753 3967/20.1 3523/10.2 WV20 bdeff 100 8348/30.0 WH20 0000 1 22/-12.4

    -

    There are several other messages that can occur; these are documented in the source listing.

    -

    Debugging Aids

    -

    The most convenient way to track the driver status is using the ntpq program and the clockvar command. This displays the last determined timecode and related status and error counters, even when the driver is not disciplining the system clock. If the debugging trace feature (-d on the ntpd command line)is enabled, the driver produces detailed status messages as it operates. If the fudge flag 4 is set, these messages are written to the clockstats file. All messages produced by this driver have the prefix wwv for convenient filtering with the Unix grep command.

    -

    Monitor Data

    - - When enabled by the filegen facility, every received timecode is written to the clockstats file in the following format: -

    sq yyyy ddd hh:mm:ss ld du lset agc ident metric errs freq avg
    - s
    synch indicator (? or space) - q quality character (see below) - yyyy Gregorian year - ddd day of year - hh hour of day - mm minute of hour - l leap second warning L - d DST state S, D, I, O
    - dut DUT sign and magnitude - lset minutes since last set - agc audio gain - ident station identifier and frequency - metric signal metric (0-100) - errs data bit errors in last minute - freq codec frequency offset (PPM) - avg frequency averaging interval (s) -

    - The fields beginning with year and extending through dut are decoded from the received data and are in fixed-length format. The agc and lset fields, as well as the following driver-dependent fields, are in variable-length format. -
    -
    s -
    The synch indicator is initially ? before the clock is set, but turns to space when all nine digits of the timecode are correctly set and the decoder is synchronized to the station within 125 ms. -
    q -
    The quality character is a four-bit hexadecimal code showing which alarms have been raised. Each bit is associated with a specific alarm condition according to the following: -
    -
    0x8 -
    synch alarm. The decoder is not synchronized to the station within 125 ms. -
    0x4 -
    Digit error alarm. Less than nine decimal digits were found in the last minute.
    0x2 -
    Error alarm. More than 40 data bit errors were found in the last minute.
    0x1 -
    Compare alarm. A maximum likelihood digit failed to agree with the current associated clock digit in the last minute.
    It is important to note that one or more of the above alarms does not necessarily indicate a clock error, but only that the decoder has detected a condition that may result in an error. However, the local clock update is not suppressed if any alarm bits are set other than a synch alarm.
    yyyy ddd hh:mm:ss -
    The timecode format itself is self explanatory. Since the driver latches the on-time epoch directly from the second synch pulse, the seconds fraction is always zero. Although the transmitted timecode includes only the year of century, the Gregorian year is augmented by 2000.
    l -
    The leap second warning is normally space, but changes to L if a leap second is to occur at the end of the month of June or December. -
    d -
    The DST state is S or D when standard time or daylight time is in effect, respectively. The state is I or O when daylight time is about to go into effect or out of effect, respectively. -
    dut -
    The DUT sign and magnitude shows the current UT1 offset relative to the displayed UTC time, in deciseconds. -
    lset -
    Before the clock is set, the interval since last set is the number of minutes since the driver was started; after the clock is set, this is number of minutes since the decoder was last synchronized to the station within 125 ms. -
    agc -
    The audio gain shows the current codec gain setting in the range 0 to 255. Ordinarily, the receiver audio gain control should be set for a value midway in this range. -
    ident -
    The station identifier shows the station, WVf for WWV or WHf for WWVH, and frequency f being tracked. If neither station is heard on any frequency, the reference identifier shows NONE. -
    metric -
    The signal metric described above from 0 (no signal) to 100 (best). -
    errs -
    The bit error counter is useful to determine the quality of the data signal received in the most recent minute. It is normal to drop a couple of data bits under good signal conditions and increasing numbers as conditions worsen. While the decoder performs moderately well even with half the bits are in error in any minute, usually by that point the metric drops below threshold and the decoder switches to a different frequency.
    freq -
    The frequency offset is the current estimate of the codec frequency offset to within 0.1 PPM. This may wander a bit over the day due to local temperature fluctuations and propagation conditions. -
    avgt -
    The averaging time is the interval between frequency updates in powers of two to a maximum of 1024 s. Attainment of the maximum indicates the driver is operating at the best possible resolution in time and frequency. -
    -

    An example timecode is:

    -

    0 2000 006 22:36:00 S +3 1 115 WV20 86 5 66.4 1024

    -

    Here the clock has been set and no alarms are raised. The year, day and time are displayed along with no leap warning, standard time and DUT +0.3 s. The clock was set on the last minute, the AGC is safely in the middle ot the range 0-255, and the receiver is tracking WWV on 20 MHz. Good receiving conditions prevail, as indicated by the metric 86 and 5 bit errors during the last minute. The current frequency is 66.4 PPM and the averaging interval is 1024 s, indicating the maximum precision available.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the propagation delay for WWV (40:40:49.0N 105:02:27.0W), in seconds and fraction, with default 0.0. -
    time2 time -
    Specifies the propagation delay for WWVH (21:59:26.0N 159:46:00.0W), in seconds and fraction, with default 0.0. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Ordinarily, this field specifies the driver reference identifier; however, the driver sets the reference identifier automatically as described above. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Specifies the microphone port if set to zero or the line-in port if set to one. It does not seem useful to specify the compact disc player port. -
    flag3 0 | 1 -
    Enables audio monitoring of the input signal. For this purpose, the speaker volume must be set before the driver is started. -
    flag4 0 | 1 -
    Enable verbose clockstats recording if set. -
    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver37.html src.ntp/contrib/ntp/html/drivers/driver37.html --- src/contrib/ntp/html/drivers/driver37.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver37.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,51 +0,0 @@ - - - - - - - Forum Graphic GPS Dating station - - - - -

    Forum Graphic GPS Dating station

    -
    -

    Synopsis

    -

    Address: 127.127.37.u
    - Reference ID: GPS
    - Driver ID: GPS
    - Parallel Port: /dev/fgclocku

    -

    Description

    -

    This driver supports the Forum Graphic GPS Dating station sold by EMR company.

    -

    Unfortunately sometime FG GPS start continues reporting of the same date. The only way to fix this problem is GPS power cycling and ntpd restart after GPS power-up.

    -

    After Jan,10 2000 my FG GPS unit start send a wrong answer after 10:00am till 11:00am. It repeat hour value in result string twice. I wroite a small code to avoid such problem. Unfortunately I have no second FG GPS unit to evaluate this problem. Please let me know if your GPS has no problems after Y2K.

    -

    -

    Monitor Data

    -

    Each timecode is written to the clockstats file in the format YYYY YD HH MI SS.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default FG. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Not used by this driver. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Not used by this driver. -
    -
    -
    Dmitry Smirnov (das@amt.ru)
    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver38.html src.ntp/contrib/ntp/html/drivers/driver38.html --- src/contrib/ntp/html/drivers/driver38.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver38.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,131 +0,0 @@ - - - - - - - hopf clock drivers by ATLSoft - - - - -

    hopf Serial Line Receivers (6021 and  kompatible)

    -
    -

    Synopsis

    - - - - - -
    - - - - - - - - - - - - - - - - - - - - - -
    -
    - Address:  
    -
    127.127.38.X
    -
    - Reference ID:  
    -
    .hopf. (default), GPS, DCF
    -
    - Driver ID:  
    -
    HOPF_S
    -
    - Serial Port:  
    -
    /dev/hopfclockX
    -
    - Serial I/O:  
    -
    9600 baud, 8-bits, 1-stop, no parity
    -
    gif
    -
    -

    Description

    -

    The refclock_hopf_serial driver supports hopf electronic receivers with serial Interface kompatibel 6021.
    -

    -

    Additional software and information about the software drivers is available from: http://www.ATLSoft.de/ntp.
    -

    -

    Latest NTP driver source, executables and documentation is maintained at: http://www.ATLSoft.de/ntp

    -
    -

    Operating System Compatibility

    -

    The hopf clock driver has been tested on the following software and hardware platforms:
     

    - - - - - - - - - - - - - - - -
    -
    - - -
    -

    Platform

    -
    -

    Operating System

    -
    -

    i386 (PC) 

    -
    -

    Linux

    -
    -

    i386 (PC) 

    -
    -

    Windows NT

    -
    -

    i386 (PC) 

    -
    Windows 2000
    -
    -

    O/S Serial Port Configuration

    - The driver attempts to open the device /dev/hopfclockX where X is the NTP refclock unit number as defined by the LSB of the refclock address.  Valid refclock unit numbers are 0 - 3. -

    The user is expected to provide a symbolic link to an available serial port device.  This is typically performed by a command such as:

    -
    - ln -s /dev/ttyS0 /dev/hopfclock0
    Windows NT does not support symbolic links to device files. 
    - COMx: is used by the driver, based on the refclock unit number, where unit 1 corresponds to COM1: and unit 3 corresponds to COM3:
      -
    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. Should be set to 20 milliseconds to correct serial line and operating system delays incurred in capturing time stamps from the synchronous packets. -
    refid string -
    Specifies the driver reference identifier, GPS or DCF. -
    flag1 0 | 1 -
    When set to 1, driver sync's even if only crystal driven. -
    -
    -

    Data Format

    -

    as specified in clock manual under pt. [ Data String for NTP ( Network Time Protocol ) ]

    -
    -

    Questions or Comments:

    -

    Bernd Altmeier
    Ing.-Büro für Software www.ATLSoft.de

    -

    (last updated 02/28/2001)
     

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver39.html src.ntp/contrib/ntp/html/drivers/driver39.html --- src/contrib/ntp/html/drivers/driver39.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver39.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,113 +0,0 @@ - - - - - - - hopf clock drivers by ATLSoft - - - - -

    hopf PCI-Bus Receiver (6039 GPS/DCF77)

    -
    -
    -
    - - - - - -
    -

    Synopsis

    - - - - - - - - - - - - - -
    -
    - Address:  
    -
    127.127.39.X
    -
    - Reference ID:  
    -
    .hopf. (default), GPS, DCF
    -
    - Driver ID:  
    -
    HOPF_P
    -
    gif
    -
    -
    -
    -

    Description

    - The refclock_hopf_pci driver supports the hopf PCI-bus interface 6039 GPS/DCF77.
    - Additional software and information about the software drivers maybe available from: http://www.ATLSoft.de/ntp.
    - Latest NTP driver source, executables and documentation is maintained at: http://www.ATLSoft.de/ntp -
    -

    Operating System Compatibility

    -

    The hopf clock driver has been tested on the following software and hardware platforms:
     

    - - - - - - - - - - - - - - - -
    -
    - - -
    -

    Platform

    -
    -

    Operating System

    -
    -

    i386 (PC) 

    -
    -

    Linux

    -
    -

    i386 (PC) 

    -
    -

    Windows NT

    -
    -

    i386 (PC) 

    -
    Windows 2000
    -
    -

    O/S System Configuration

    -

    UNIX

    - The driver attempts to open the device /dev/hopf6039 . The device entry will be made by the installation process of the kernel module for the PCI-bus board. The driver sources belongs to the delivery equipment of the PCI-board. -

    Windows NT/2000

    -

    The driver attempts to open the device by calling the function "OpenHopfDevice()". This function will be installed by the Device Driver for the PCI-bus board. The driver belongs to the delivery equipment of the PCI-board.

    -
    -

    Fudge Factors

    -
    -
    refid string -
    Specifies the driver reference identifier, GPS or DCF. -
    flag1 0 | 1 -
    When set to 1, driver sync's even if only crystal driven. -
    -
    -

    Questions or Comments:

    -

    Bernd Altmeier
    Ing.-Büro für Software www.ATLSoft.de

    -

    (last updated 03/02/2001)
     

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver4.html src.ntp/contrib/ntp/html/drivers/driver4.html --- src/contrib/ntp/html/drivers/driver4.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver4.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,66 +0,0 @@ - - - - - - - Spectracom 8170 and Netclock/2 WWVB Receivers - - - - -

    Spectracom 8170 and Netclock/2 WWVB Receivers

    -
    -

    Synopsis

    - Address: 127.127.4.u
    - Reference ID: WWVB
    - Driver ID: WWVB_SPEC
    - Serial Port: /dev/wwvbu; 9600 baud, 8-bits, no parity
    - Features: tty_clk -

    Description

    -

    This driver supports all known Spectracom radio and satellite clocks, including the Model 8170 and Netclock/2 WWVB Synchronized Clocks and the Netclock/GPS GPS Master Clock. The claimed accuracy of the WWVB clocks is 100 usec relative to the broadcast signal. These clocks have proven a reliable source of time, except in some parts of the country with high levels of conducted RF interference. WIth the GPS clock the claimed accuracy is 130 ns. However, in most cases the actual accuracy is limited by the precision of the timecode and the latencies of the serial interface and operating system.

    -

    The DIPswitches on these clocks should be set to 24-hour display, AUTO DST off, data format 0 or 2 (see below) and baud rate 9600. If this clock is used as the source for the IRIG Audio Decoder (refclock_irig.c in this distribution), set the DIPswitches for AM IRIG output and IRIG format 1 (IRIG B with signature control).

    -

    There are two timecode formats used by these clocks. Format 0, which is available with all clocks, and format 2, which is available with all clocks except the original (unmodified) Model 8170.

    -

    Format 0 (22 ASCII printing characters):
    - <cr><lf>i ddd hh:mm:ss TZ=zz<cr><lf>

    -

    on-time = first <cr>
    - i = synchronization flag (' ' = in synch, '?' = out synch)
    - hh:mm:ss = hours, minutes, seconds

    -

    The alarm condition is indicated by other than ' ' at i, which occurs during initial synchronization and when received signal is lost for about ten hours.

    -

    Format 2 (24 ASCII printing characters):
    - lt;cr>lf>iqyy ddd hh:mm:ss.fff ld

    -

    on-time = <cr>
    - i = synchronization flag (' ' = in synch, '?' = out synch)
    - q = quality indicator (' ' = locked, 'A'...'D' = unlocked)
    - yy = year (as broadcast)
    - ddd = day of year
    - hh:mm:ss.fff = hours, minutes, seconds, milliseconds

    -

    The alarm condition is indicated by other than ' ' at i, which occurs during initial synchronization and when received signal is lost for about ten hours. The unlock condition is indicated by other than ' ' at q.

    -

    The q is normally ' ' when the time error is less than 1 ms and a character in the set A...D when the time error is less than 10, 100, 500 and greater than 500 ms respectively. The l is normally ' ', but is set to L early in the month of an upcoming UTC leap second and reset to ' ' on the first day of the following month. The d is set to S for standard time S, I on the day preceding a switch to daylight time, D for daylight time and O on the day preceding a switch to standard time. The start bit of the first <cr> is synchronized to the indicated time as returned.

    -

    This driver does not need to be told which format is in use - it figures out which one from the length of the message. A three-stage median filter is used to reduce jitter and provide a dispersion measure. The driver makes no attempt to correct for the intrinsic jitter of the radio itself, which is a known problem with the older radios.

    -

    Monitor Data

    -

    The driver writes each timecode as received to the clockstats file. When enabled by the flag4 fudge flag, a table of quality data maintained internally by the Netclock/2 is retrieved and written to the clockstats file when the first timecode message of a new dayis received.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default WWVB. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Not used by this driver. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Enable verbose clockstats recording if set. -
    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver40.html src.ntp/contrib/ntp/html/drivers/driver40.html --- src/contrib/ntp/html/drivers/driver40.html 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/html/drivers/driver40.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,189 +0,0 @@ - - - - - - - - - JJY Receivers - - - - - - -

    JJY Receivers

    -
    -

    Synopsis

    - Address: 127.127.40.u
    - Reference ID: JJY
    - Driver ID: JJY
    - Serial Port: /dev/jjyu; 9600|4800(See corresponding receiver) baud, 8-bits, no parity, 1 stop bit -

    Description

    -

    This driver supports the following JJY receivers sold in Japan.

    -
      -
    • Tristate Ltd. JJY01 http://www.tristate.ne.jp/ (Japanese only)
      -
      -
      NTP configuration ( ntp.conf )
      -
      -

      server   127.127.40.X   mode 1

      -
      -
      -
      RS-232C
      -
      -

      9600 Baud

      -
      -
      -
      Time code format
      -

      - - - - - - - - - - - - - - - - -
      Command --> Reply
      date<CR><LF> --> YYYY/MM/DD WWW<CR><LF>
      stim<CR><LF> --> HH:MM:SS<CR><LF>
      -
      -
      -
      -
    • C-DEX Co.,Ltd. JST2000 http://www.c-dex.co.jp/ (Japanese only)
      -
      -
      NTP configuration ( ntp.conf )
      -
      -

      server   127.127.40.X   mode 2

      -
      -
      -
      RS-232C
      -
      -

      9600 Baud

      -
      -
      -
      Time code format
      -

      - - - - - - - - - - - -
      Command --> Reply
      <ENQ>1J<ETX> --> <STX>JYYMMDD HHMMSSS<ETX>
      -
      -
      -
      -
    • -

      Echo Keisokuki Co.,Ltd. LT-2000 http://www.clock.co.jp/ (Japanese only)

      -
      -
      NTP configuration ( ntp.conf )
      -
      -

      server   127.127.40.X   mode 3

      -
      -
      -
      RS-232C
      -
      -

      9600 Baud

      -
      -
      -
      Time code format
      -

      - - - - - - - - - - - - - - - - - - - - - -
      Command --> Reply
      C --> ( Mode 2 : Continuous )
      ( Every second before 0.5 second )YYMMDDWHHMMSS<ST1><ST2><ST3><ST4><CR>
      # --> ( Mode 1 : Request&Send )
      -
      -
      -
      -
    • -

      CITIZEN T.I.C. CO.,LTD. JJY-200 http://www.tic-citizen.co.jp/ (Japanese only)

      -
      -
      NTP configuration ( ntp.conf )
      -
      -

      server   127.127.40.X   mode 4

      -
      -
      -
      RS-232C
      -
      -

      4800 Baud

      -
      -
      -
      Time code format
      -

      - - - - - - - - - - - -
      Command --> Reply
      ( Every second )'XX YY/MM/DD W HH:MM:SS<CR>
      -
      -
      -
      -
    -

    JJY is the radio station which transmites the JST (Japan Standard Time) in long wave radio. The station JJY is operated by the National Institute of Information and Communications Technology. An operating announcement and some information are avaiable from http://www.nict.go.jp/ (English and Japanese) and http://jjy.nict.go.jp/ (English and Japanese)

    -

    The user is expected to provide a symbolic link to an available serial port device. This is typically performed by a command such as:

    -

    ln -s /dev/ttyS0 /dev/jjy0

    -

    Windows NT does not support symbolic links to device files. COMX: is the unit used by the driver, based on the refclock unit number, where unit 1 corresponds to COM1: and unit 3 corresponds to COM3:

    -

    Monitor Data

    -

    The driver writes each timecode as received to the clockstats file.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default JJY. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Not used by this driver. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Not used by this driver. -
    -
    - - - - diff -urN src/contrib/ntp/html/drivers/driver42.html src.ntp/contrib/ntp/html/drivers/driver42.html --- src/contrib/ntp/html/drivers/driver42.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver42.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,30 +0,0 @@ - - - - - - - Zyfer GPStarplus Receiver - - - - -

    Zyfer GPStarplus Receiver

    -
    -

    Synopsis

    - Address: 127.127.42.u
    - Reference ID: GPS
    - Driver ID: Zyfer GPStarplus
    - Serial Port: /dev/zyferu; 9600 baud, 8-bits, no parity
    - Features: (none) -

    Description

    -

    This driver supports the Zyfer GPStarplus receiver.

    -

    The receiver has a DB15 port on the back which has input TxD and RxD lines for configuration and control, and a separate TxD line for the once-per-second timestamp.

    -

    Additionally, there are BNC connectors on the back for things like PPS and IRIG output.

    -

    Additional Information

    -

    Reference Clock Drivers

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver43.html src.ntp/contrib/ntp/html/drivers/driver43.html --- src/contrib/ntp/html/drivers/driver43.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver43.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,65 +0,0 @@ - - - - - - - RIPE NCC interface for Trimble Palisade - - - - -

    RIPE NCC interface for Trimble Palisade

    -
    - Trimble Acutime 2000 -

    Synopsis

    - Address: 127.127.43.u
    - Reference ID: RIPENCC
    - Driver ID: RIPENCC -

    Description

    -

    This is a special driver developed to be used in conjuction with the RIPE NCC clock card in the RIPE NCC Test Traffic Measurements project.

    -

    Why this driver?

    -

    The reason why we created a seperated driver for an antenna for which already a (vendor supplied) driver exist is a design decision. To be more specific, the standard Trimble interface uses a 12 pin connector. The cable sold by Trimble to connect to this wire is a very thick cable. Certainly not something you wish to run for several 100 meters through your building. And if you wanted to run it for 100 meters, you always would have to really run the cable, and didn't have the option to use existing wiring.
    -

    -

    This is where we wanted more flexibility. We wanted to be able to use existing wiring in buildings. That leaded us to CAT-5(UTP) which only gives us 8 wires. Therefor we decided to redesing the use of the Trimble antenna. The Trimble supports two modes: EVENT driver and PPS mode. The default is to use the EVENT mode which needs all 12 wires. We only use the PPS timestamps for which we have enough with 8 wires. For our purposes this is more than fine.

    - More information about the project can be found on the Test Traffic Measurements website. RIPE NCC clock card -

    RIPE NCC clock card

    -

    The card is very a simple PCI card. The only feature on the bus it uses is the power supply. It uses this power supply to power the Trimble GPS antenna.

    -

    The card basicly just is a RS422 to RS232 converter. It gets the Trimble's RS422 signal on a RJ45 connector and transforms that to RS232 on a DIN9 connector. This connector should be loopbacked on the back of the machine to the serial port. As said, the card doesn't do any PCI data transfers.

    -

    The schematics of the interface card is available here: gps_interface_schematic.pdf. You are free to create this card yourself as long as you give some credit or reference to us. Note that we don't sell these cards on a commercial basis, but for interested parties we do have some spares to share.

    -

    -

    Monitor Data

    -

    In the filegen clockstats file the following (example) data is collected:

    -
    -52445 41931.275 127.127.40.0 U1 20.6.2002 11:38:51 13 11
    -52445 41931.395 127.127.40.0 C1 20062002 113851 6  364785 110.2 450 6.7 13 5222.374737 N 0453.268013 E 48  7 11 0 1 -14 20 0 -25
    -52445 41931.465 127.127.40.0 S1 07 1 1 02 59.3 291.5 39.3
    -52445 41931.485 127.127.40.0 S1 11 2 1 02 59.9 138.0 60.2
    -52445 41931.525 127.127.40.0 S1 01 4 1 02 48.4 185.7 28.3
    -52445 41931.555 127.127.40.0 S1 14 5 2 02 32.7  41.0 15.4
    -52445 41931.585 127.127.40.0 S1 20 6 1 02 59.9 256.6 78.0
    -52445 41931.615 127.127.40.0 S1 25 8 2 00  0.0  86.6 20.1
    -
    -

    This is in the form of:

    -
    -All output lines consist of a prefix and a message, the prefix is:
    -[days since epoch] [sec.ms since start of day] [peer address] 
    -
    -And all individual messages:
    -
    -*Primary UTC time packet:
    -U1 [date] [time] [trackstat] [utcflags]
    -
    -*Comprehensive time packet:
    -C1 [date] [time] [mode] [bias] [biasunc] [rate] [rateunc] [utcoff] [latitude] [longtitude] [alt] [vis sat](x8)
    -
    -*Tracking status packet:
    -S1 [prn] [channel] [aqflag] [ephstat] [snr] [azinuth] [elevation]
    -
    -

    Additional Information

    -

    Reference Clock Drivers

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver44.html src.ntp/contrib/ntp/html/drivers/driver44.html --- src/contrib/ntp/html/drivers/driver44.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver44.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,88 +0,0 @@ - - - - - - NeoClock4X - - - - - -

    NeoClock4X - DCF77 / TDF serial line receiver
    -

    -
    -

    Synopsis

    - - - - - - - -
    - - - - - - - - - - - - - - - - - - - -
    Adress
    -
    127.127.44.u
    -
    Reference ID
    -
    neol
    -
    Driver ID
    -
    NEOCLK4X
    -
    Serial Port
    -
    /dev/neoclock4x-u
    -
    -
    -
    NeoClock4X - DCF77 receiver
    -
    -
    -

    Description

    - The refclock_neoclock4x driver supports the NeoClock4X receiver available from Linum Software GmbH. The receiver is available as a DCF77 or TDF receiver. Both receivers have the same output string. For more information about the NeoClock4X receiver please visit http://www.linux-funkuhr.de.   -
    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor with the default value off 0.16958333 seconds. This offset is used  to correct serial line and operating system delays incurred in capturing time stamps. If you want to fudge the time1 offset ALWAYS add a value off 0.16958333. This is neccessary to compensate to delay that is caused by transmit the timestamp at 2400 Baud. If you want to compensate the delay that the DCF77 or TDF radio signal takes to travel to your site simply add the needed millisecond delay to the given value. Note that the time here is given in seconds. -
    Default setting is 0.16958333 seconds.
    -
    -
    -
    time2 time -
    Not used by this driver. -
    -
    -
    flag1 0 | 1 -
    When set to 1 the driver will feed ntp with timestampe even if the radio signal is lost. In this case an internal backup clock generates the timestamps. This is ok as long as the receiver is synced once since the receiver is able to keep time for a long period. -
    Default setting is 0 = don't synchronize to CMOS clock. -
    flag2 0 | 1 -
    You can allow the NeoClock4X driver to use the quartz clock even if it is never synchronized to a radio clock. This is usally not a good idea if you want preceise timestamps since the CMOS clock is maybe not adjusted to a dst status change. So PLEASE switch this only on if you now what you're doing. -
    Default setting is 0 = don't synchronize to unsynchronized CMOS clock. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    It is recommended to allow extensive logging while you setup the NeoClock4X receiver. If you activate flag4 every received data is logged. You should turn off flag4 as soon as the clock works as expected to reduce logfile cluttering. -
    Default setting is 0 = don't log received data and converted utc time. -
    -
    - Please send any comments or question to neoclock4x@linum.com. -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver5.html src.ntp/contrib/ntp/html/drivers/driver5.html --- src/contrib/ntp/html/drivers/driver5.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver5.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,72 +0,0 @@ - - - - - - - TrueTime GPS/GOES/OMEGA Receivers - - - - -

    TrueTime GPS/GOES/OMEGA Receivers

    -
    -

    Synopsis

    - Address: 127.127.5.u
    - Reference ID: GPS, OMEGA, GOES
    - Driver ID: TRUETIME
    - Serial Port: /dev/trueu; 9600 baud, 8-bits, no parity
    - Features: tty_clk -

    Description

    -

    This driver supports several models models of Kinemetrics/TrueTime timing receivers, including 468-DC MK III GOES Synchronized Clock, GPS- DC MK III and GPS/TM-TMD GPS Synchronized Clock, XL-DC (a 151-602-210, reported by the driver as a GPS/TM-TMD), GPS-800 TCU (an 805-957 with the RS232 Talker/Listener module), OM-DC OMEGA Synchronized Clock, and very likely others in the same model family that use the same timecode formats.

    -

    Most of this code is originally from refclock_wwvb.c with thanks. It has been so mangled that wwvb is not a recognizable ancestor.

    -

    Timcode format: ADDD:HH:MM:SSQCL A - control A (this is stripped before we see it) Q - Quality indication (see below) C - Carriage return L - Line feed Quality codes indicate possible error of

    -
    -
    468-DC GOES Receiver
    - GPS-TM/TMD Receiver -
    ? +/- 500 milliseconds # +/- 50 milliseconds
    - * +/- 5 milliseconds . +/- 1 millisecond
    - space less than 1 millisecond -
    OM-DC OMEGA Receiver: -
    > +/- 5 seconds
    - ? +/- 500 milliseconds # +/- 50 milliseconds
    - * +/- 5 milliseconds . +/- 1 millisecond
    - A-H less than 1 millisecond. Character indicates which station is being received as follows
    - A = Norway, B = Liberia, C = Hawaii, D = North Dakota, E = La Reunion, F = Argentina, G = Australia, H = Japan
    - The carriage return start bit begins on 0 seconds and extends to 1 bit time. -
    -

    Notes on 468-DC and OMEGA receiver:

    -

    Send the clock a R or C and once per second a timestamp will appear. Send a R to get the satellite position once (GOES only).

    -

    Notes on the 468-DC receiver:

    -

    Since the old east/west satellite locations are only historical, you can't set your clock propagation delay settings correctly and still use automatic mode. The manual says to use a compromise when setting the switches. This results in significant errors. The solution; use fudge time1 and time2 to incorporate corrections. If your clock is set for 50 and it should be 58 for using the west and 46 for using the east, use the line

    -

    fudge 127.127.5.0 time1 +0.008 time2 -0.004

    -

    This corrects the 4 milliseconds advance and 8 milliseconds retard needed. The software will ask the clock which satellite it sees.

    -

    The PCL720 from PC Labs has an Intel 8253 look-alike, as well as a bunch of TTL input and output pins, all brought out to the back panel. If you wire a PPS signal (such as the TTL PPS coming out of a GOES or other Kinemetrics/Truetime clock) to the 8253's GATE0, and then also wire the 8253's OUT0 to the PCL720's INPUT3.BIT0, then we can read CTR0 to get the number of microseconds since the last PPS upward edge, mediated by reading OUT0 to find out if the counter has wrapped around (this happens if more than 65535us (65ms) elapses between the PPS event and our being called.)

    -

    Monitor Data

    -

    When enabled by the flag4 fudge flag, every received timecode is written as-is to the clockstats file.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, to be used for the West satellite, with default 0.0. -
    time2 time -
    . Specifies the time offset calibration factor, in seconds and fraction, to be used for the East satellite, with default 0.0. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default TRUE. -
    flag1 0 | 1 -
    Silence the clock side of ntpd, just reading the clock without trying to write to it. -
    flag2 0 | 1 -
    Generate a debug file /tmp/true%d. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Not used by this driver. -
    -

    Additional Information

    -

    Reference Clock Drivers

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver6.html src.ntp/contrib/ntp/html/drivers/driver6.html --- src/contrib/ntp/html/drivers/driver6.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver6.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,92 +0,0 @@ - - - - - - - - IRIG Audio Decoder - - - - -

    IRIG Audio Decoder

    -
    -

    Synopsis

    - Address: 127.127.6.u
    - Reference ID: IRIG
    - Driver ID: IRIG_AUDIO
    - Audio Device: /dev/audio and /dev/audioctl -

    Note: This driver supersedes an older one of the same name, address and ID which required replacing the original kernel audio driver with another which worked only on older Sun SPARC architectures and SunOS operating systems. The new driver requires no modification of the operating system and works on FreeBSD, SunOS and Solaris. While it is generic and likely portable to other systems, it is somewhat slower than the original, since the extensive signal conditioning, filtering and decoding is done in user space, not kernel space.

    -

    Description

    -

    This driver supports the Inter-Range Instrumentation Group (IRIG) standard time distribution signal using the audio codec native to some workstations. This signal is generated by several radio clocks, including those made by Arbiter, Austron, Bancomm, Odetics, Spectracom and TrueTime, among others, although it is often an add-on option. The signal is connected via an optional attenuator box and cable to either the microphone or line-in port. The driver receives, demodulates and decodes the IRIG-B and IRIG-E signal formats using internal filters designed to reduce the effects of noise and interference.

    -

    This driver incorporates several features in common with other audio drivers such as described in the Radio CHU Audio Demodulator/Decoder and the Radio WWV/H Audio Demodulator/Decoder pages. They include automatic gain control (AGC), selectable audio codec port and signal monitoring capabilities. For a discussion of these common features, as well as a guide to hookup, debugging and monitoring, see the Reference Clock Audio Drivers page.

    -

    The IRIG signal format uses an amplitude-modulated carrier with pulse-width modulated data bits. For IRIG-B, the carrier frequency is 1000 Hz and bit rate 100 b/s; for IRIG-E, the carrier frequenchy is 100 Hz and bit rate 10 b/s. While IRIG-B provides the best accuracy, generally within a few tens of microseconds relative to IRIG time, it can also generate a significant load on the processor with older workstations. Generally, the accuracy with IRIG-E is about ten times worse than IRIG-B, but the processor load is ten times less.

    -

    The program processes 8000-Hz m-law companded samples using separate signal filters for IRIG-B and IRIG-E, a comb filter, envelope detector and automatic threshold corrector. Cycle crossings relative to the corrected slice level determine the width of each pulse and its value - zero, one or position identifier. The data encode 20 BCD digits which determine the second, minute, hour and day of the year and sometimes the year and synchronization condition. The comb filter exponentially averages the corresponding samples of successive baud intervals in order to reliably identify the reference carrier cycle. A type-II phase-lock loop (PLL) performs additional integration and interpolation to accurately determine the zero crossing of that cycle, which determines the reference timestamp. A pulse-width discriminator demodulates the data pulses, which are then encoded as the BCD digits of the timecode. The timecode and reference timestamp are updated once each second with IRIG-B (ten seconds with IRIG-E) and local clock offset samples saved for later processing. At poll intervals of 64 s, the saved samples are processed by a trimmed-mean filter and used to update the system clock.

    -

    Infinite impulse response (IIR) filters are used with both IRIG-B and IRIG-E formats. An 800-Hz highpass filter is used for IRIG-B and a 130-Hz lowpass filter for IRIG-E. These are intended for use with noisy signals, such as might be received over a telephone line or radio circuit, or when interfering signals may be present in the audio passband. The driver determines which IRIG format is in use by sampling the amplitude of each filter output and selecting the one with maximum signal. An automatic gain control feature provides protection against overdriven or underdriven input signal amplitudes. It is designed to maintain adequate demodulator signal amplitude while avoiding occasional noise spikes. In order to assure reliable capture, the decompanded input signal amplitude must be greater than 100 units and the codec sample frequency error less than 250 PPM (.025 percent).

    -

    The program performs a number of error checks to protect against overdriven or underdriven input signal levels, incorrect signal format or improper hardware configuration. The specific checks are detailed later in this page. Note that additional checks are done elsewhere in the reference clock interface routines.

    -

    Unlike other drivers, which can have multiple instantiations, this one supports only one. It does not seem likely that more than one audio codec would be useful in a single machine. More than one would probably chew up too much CPU time anyway.

    -

    IRIG-B Timecode Format

    -

    The 100 elements of the IRIG timecode are numbered from 0 through 99. Position identifiers occur at elements 0, 9, 19 and every ten thereafter to 99. The control function (CF) elements begin at element 50 (CF 1) and extend to element 78 (CF 27). The straight-binary-seconds (SBS) field, which encodes the seconds of the UTC day, begins at element 80 (CF 28) and extends to element 97 (CF 44). The encoding of elements 50 (CF 1) through 78 (CF 27) is device dependent. This driver presently decodes the CF elements, but does nothing with them.

    -

    Where feasible, the IRIG signal source should be operated with signature control so that, if the signal is lost or mutilated, the source produces an unmodulated signal, rather than possibly random digits. The driver will automatically reject the data and declare itself unsynchronized in this case. Some devices, in particular Spectracom radio/satellite clocks, provide additional year and status indication in the format:

    -
    -     Element   CF        Function
    -     -------------------------------------
    -     55        6         time sync status
    -     60-63     10-13     BCD year units
    -     65-68     15-18     BCD year tens
    -
    - Other devices set these elements to zero. -

    Performance and Horror Stories

    -

    The m-law companded data format allows considerable latitude in signal levels; however, an automatic gain control (AGC) function is implemented to further compensate for varying input signal levels and to avoid signal distortion. For proper operation, the IRIG signal source should be configured for analog signal levels, NOT digital TTL levels.

    -

    The accuracy of the system clock synchronized to the IRIG-B source with this driver and the ntpd daemon is 10-20 ms with a Sun UltraSPARC II running Solaris 2.6 and maybe twice that with a Sun SPARC IPC running SunOS 4.1.3. Be however acutely aware that the accuracy with Solaris 2.8 and presumably beyond has seriously degraded to the order of several milliseconds. The Sun kernel driver has a sawtooth modulation with amplitude over 5 ms peak-peak and period 5.5 s. The crafty IRIG driver uses a transverse filter to remove the modulation and something called a botttom-fisher to remove incidental positive spikes especially prevalent with Sun Blade 1000 and possibly other systems. The result is nominal accuracy and jitter something less than 0.5 ms, but the this is still far inferior to the performance with older systems.

    -

    The processor resources consumed by the daemon can be significant, ranging from about 1.2 percent on the faster UltraSPARC II to 38 percent on the slower SPARC IPC. However, the overall timing accuracy is limited by the resolution and stability of the CPU clock oscillator and the interval between clock corrections, which is 64 s with this driver. This performance, while probably the best that can be achieved by the daemon itself, can be improved with assist from the PPS discipline as described elsewhere in this documentation.

    -

    Autotune

    -

    The driver includes provisions to automatically tune the radio in response to changing radio propagation conditions throughout the day and night. The radio interface is compatible with the ICOM CI-V standard, which is a bidirectional serial bus operating at TTL levels. The bus can be connected to a serial port using a level converter such as the CT-17.

    -

    Each ICOM radio is assigned a unique 8-bit ID select code, usually expressed in hex format. To activate the CI-V interface, the mode keyword of the server configuration command specifies a nonzero select code in decimal format. A table of ID select codes for the known ICOM radios is given on the Reference Clock Audio Drivers page. A missing mode keyword or a zero argument leaves the interface disabled.

    -

    If specified, the driver will attempt to open the device /dev/icom and, if successful will activate the autotune function and tune the radio to each operating frequency in turn while attempting to acquire minute sync from CHU. However, the driver is liberal in what it assumes of the configuration. If the /dev/icom link is not present or the open fails or the CI-V bus or radio is inoperative, the driver quietly gives up with no harm done.

    -

    Monitor Data

    - The timecode format used for debugging and data recording includes data helpful in diagnosing problems with the IRIG signal and codec connections. With debugging enabled (-d on the ntpd command line), the driver produces one line for each timecode in the following format: -

    00 1 98 23 19:26:52 721 143 0.694 47 20 0.083 66.5 3094572411.00027

    -

    The first field containes the error flags in hex, where the hex bits are interpreted as below. This is followed by the IRIG status indicator, year of century, day of year and time of day. The status indicator and year are not produced by some IRIG devices. Following these fields are the carrier amplitude (0-8100), codec gain (0-255), field phase (0-79), time constant (2-20), modulation index (0-1), carrier phase error (0±0.5) and carrier frequency error (PPM). The last field is the on-time timestamp in NTP format. The fraction part is a good indicator of how well the driver is doing. With an UltrSPARC 30, this is normally within a few tens of microseconds relative to the IRIG-B signal and within a few hundred microseconds with IRIG-E.

    -

    The error flags are defined as follows in hex:

    -
    -
    x01 -
    Low signal. The carrier amplitude is less than 100 units. This is usually the result of no signal or wrong input port. -
    x02 -
    Frequency error. The codec frequency error is greater than 250 PPM. This may be due to wrong signal format or (rarely) defective codec. -
    x04 -
    Modulation error. The IRIG modulation index is less than 0.5. This is usually the result of an overdriven codec, wrong signal format or wrong input port. -
    x08 -
    Frame synch error. The decoder frame does not match the IRIG frame. This is usually the result of an overdriven codec, wrong signal format or noisy IRIG signal. It may also be the result of an IRIG signature check which indicates a failure of the IRIG signal synchronization source. -
    x10 -
    Data bit error. The data bit length is out of tolerance. This is usually the result of an overdriven codec, wrong signal format or noisy IRIG signal. -
    x20 -
    Seconds numbering discrepancy. The decoder second does not match the IRIG second. This is usually the result of an overdriven codec, wrong signal format or noisy IRIG signal. -
    x40 -
    Codec error (overrun). The machine is not fast enough to keep up with the codec. -
    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default IRIG. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Specifies the microphone port if set to zero or the line-in port if set to one. It does not seem useful to specify the compact disc player port. -
    flag3 0 | 1 -
    Enables audio monitoring of the input signal. For this purpose, the speaker volume must be set before the driver is started. -
    flag4 0 | 1 -
    Enable verbose clockstats recording if set. -
    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver7.html src.ntp/contrib/ntp/html/drivers/driver7.html --- src/contrib/ntp/html/drivers/driver7.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver7.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,234 +0,0 @@ - - - - - - - - Radio CHU Audio Demodulator/Decoder - - - - -

    Radio CHU Audio Demodulator/Decoder

    -
    -

    Synopsis

    - Address: 127.127.7.u
    - Reference ID: CHU
    - Driver ID: CHU
    - Modem Port: /dev/chuu; 300 baud, 8-bits, no parity
    - Autotune Port: /dev/icom; 1200/9600 baud, 8-bits, no parity
    - Audio Device: /dev/chu_audio and /dev/audioctl -

    Description

    -

    This driver synchronizes the computer time using data encoded in radio transmissions from Canadian time/frequency station CHU in Ottawa, Ontario. It replaces an earlier one, built by Dennis Ferguson in 1988, which required a special line discipline to preprocessed the signal. The new driver includes more powerful algorithms implemented directly in the driver and requires no preprocessing.

    -

    CHU transmissions are made continuously on 3330 kHz, 7335 kHz and 14670 kHz in upper sideband, compatible AM mode. An ordinary shortwave receiver can be tuned manually to one of these frequencies or, in the case of ICOM receivers, the receiver can be tuned automatically as propagation conditions change throughout the day and night. The performance of this driver when tracking the station is ordinarily better than 1 ms in time with frequency drift less than 0.5 PPM when not tracking the station.

    -

    While there are currently no known commercial CHU receivers, a simple but effective receiver/demodulator can be constructed from an ordinary shortwave receiver and Bell 103 compatible, 300-b/s modem or modem chip, as described on the Pulse-per-second (PPS) Signal Interfacing page. The driver can use the modem to receive the radio signal and demodulate the data or, if available, the driver can use the audio codec of the Sun workstation or another with compatible audio interface. In the latter case, the driver implements the modem using DSP routines, so the radio can be connected directly to either the microphone or line input port.

    -

    This driver incorporates several features in common with other audio drivers such as described in the Radio WWV/H Audio Demodulator/Decoder and the IRIG Audio Decoder pages. They include automatic gain control (AGC), selectable audio codec port and signal monitoring capabilities. For a discussion of these common features, as well as a guide to hookup, debugging and monitoring, see the Reference Clock Audio Drivers page.

    -

    Ordinarily, the driver poll interval is set to 14 (about 4.5 h), although this can be changed with configuration commands. As long as the clock is set or verified at least once during this interval, the NTP algorithms will consider the source reachable and selectable to discipline the system clock. However, if this does not happen for eight poll intervals, the algorithms will consider the source unreachable and some other source will be chosen (if available) to discipline the system clock.

    -

    The decoding algorithms process the data using maximum-likelihood techniques which exploit the considerable degree of redundancy available in each broadcast message or burst. As described below, every character is sent twice and, in the case of format A bursts, the burst is sent eight times every minute. In the case of format B bursts, which are sent once each minute, the burst is considered correct only if every character matches its repetition in the burst. In the case of format A messages, a majority decoder requires at least six repetitions for each digit in the timecode and more than half of the repetitions decode to the same digit. Every character in every burst provides an independent timestamp upon arrival with a potential total of over 60 timestamps for each minute.

    -

    A timecode in the format described below is assembled when all bursts have been received in the minute. The timecode is considered valid and the clock set when at least one valid format B burst has been decoded and the above requirements are met. The yyyy year field in the timecode indicates whether a valid format B burst has been received. Upon startup, this field is initialized at zero; when a valid format B burst is received, it is set to the current Gregorian year. The q quality character field in the timecode indicates whether a valid timecode has been determined. If any of the high order three bits of this character are set, the timecode is invalid.

    -

    Once the clock has been set for the first time, it will appear reachable and selectable to discipline the system clock, even if the broadcast signal is lost. Since the signals are almost always available during some period of the day and the NTP clock discipline algorithms are designed to work well even in this case, it is unlikely that the system clock could drift more than a few tens of milliseconds during periods of signal loss. To protect against this most unlikely situation, if after four days with no signals, the clock is considered unset and resumes the synchronization procedure from the beginning.

    -

    The last three fields in the timecode are useful in assessing the quality of the radio channel during the most recent minute bursts were received. The bcnt field shows the number of format A bursts in the range 1-8. The dist field shows the majority decoder distance, or the minimum number of sample repetitions for each digit of the timecode in the range 0-16. The tsmp field shows the number of timestamps determined in the range 0-60. For a valid timecode, bcnt must be at least 3, dist must be greater than bcnt and tsmp must be at least 20.

    -

    Program Operation

    -

    The program consists of four major parts: the DSP modem, maximum likelihood UART, burst assembler and majority decoder. The DSP modem demodulates Bell 103 modem answer-frequency signals; that is, frequency-shift keyed (FSK) tones of 2225 Hz (mark) and 2025 Hz (space). This is done using a 4th-order IIR filter and limiter/discriminator with 500-Hz bandpass centered on 2125 Hz and followed by a FIR raised-cosine lowpass filter optimized for the 300-b/s data rate. Alternately, the driver can be compiled to delete the modem and input 300 b/s data directly from an external modem via a serial port.

    -

    The maximum likelihood UART is implemented using a set of eight 11-stage shift registers, one for each of eight phases of the 300-b/s bit clock. At each phase a new baseband signal value from the DSP modem is shifted into the corresponding register and the maximum and minimum over all 11 samples computed. This establishes a slice level midway between the maximum and minimum over all stages. For each stage, a signal level above this level is a mark (1) and below is a space (0). A quality metric is calculated for each register with respect to the slice level and the a-priori signal consisting of a mark bit (previous stop bit), space (start) bit, eight arbitrary information bits and the first of the two mark (stop) bits.

    -

    The shift registers are processed in round-robin order as each modem value arrives until one of them shows a valid framing pattern consisting of a mark bit, space bit, eight arbitrary data bits and a mark bit. When found, the data bits from the register with the best metric is chosen as the maximum likelihood character and the UART begins to process the next character.

    -

    The burst assembler processes characters either from the maximum likelihood UART or directly from the serial port as configured. A burst begins when a character is received and is processed after a timeout interval when no characters are received. If the interval between characters is greater than two characters, but less than the timeout interval, the burst is rejected as a runt and a new burst begun. As each character is received, a timestamp is captured and saved for later processing.

    -

    A valid burst consists of ten characters in two replicated five-character blocks. A format B block contains the year and other information in ten hexadecimal digits. A format A block contains the timecode in ten decimal digits, the first of which is a framing code (6). The burst assembler must deal with cases where the first character of a format A burst is lost or is noise. This is done using the framing code to correct the phase, either one character early or one character late.

    -

    The burst distance is incremented by one for each bit in the first block that matches the corresponding bit in the second block and decremented by one otherwise. In a format B burst the second block is bit-inverted relative to the first, so a perfect burst of five 8-bit characters has distance -40. In a format A block the two blocks are identical, so a perfect burst has distance +40. Format B bursts must be perfect to be acceptable; however, format A bursts, which are further processed by the majority decoder, are acceptable if the distance is at least 28.

    -

    Each minute of transmission includes eight format A bursts containing two timecodes for each second from 31 through 39. The majority decoder uses a decoding matrix of ten rows, one for each digit position in the timecode, and 16 columns, one for each 4-bit code combination that might be decoded at that position. In order to use the character timestamps, it is necessary to reliably determine the second number of each burst. In a valid burst, the last digit of the two timecodes in the block must match and the value must be in the range 2-9 and greater than in the previous burst.

    -

    As each hex digit of a valid burst is processed, the value at the row corresponding to the digit position in the timecode and column corresponding to the code found at that position is incremented. At the end of each minute of transmission, each row of the decoding matrix encodes the number of occurrences of each code found at the corresponding position of the timecode. However, the first digit (framing code) is always 6, the ninth (second tens) is always 3 and the last (second units) changes for each burst, so are not used.

    -

    The maximum over all occurrences at each timecode digit position is the distance for that position and the corresponding code is the maximum likelihood candidate. If the distance is zero, the decoder assumes a miss; if the distance is not more than half the total number of occurrences, the decoder assumes a soft error; if two different codes with the same distance are found, the decoder assumes a hard error. In all these cases the decoder encodes a non-decimal character which will later cause a format error when the timecode is reformatted. The decoding distance is defined as the minimum distance over the first nine digits; the tenth digit varies over the seconds and is uncounted.

    -

    The result of the majority decoder is a nine-digit timecode representing the maximum likelihood candidate for the transmitted timecode in that minute. Note that the second and fraction within the minute are always zero and that the actual reference point to calculate timestamp offsets is backdated to the first second of the minute. At this point the timecode block is reformatted and the year, days, hours and minutes extracted along with other information from the format B burst, including DST state, DUT1 correction and leap warning. The reformatting operation checks the timecode for invalid code combinations that might have been left by the majority decoder and rejects the entire timecode if found.

    -

    If the timecode is valid, it is passed to the reference clock interface along with the backdated timestamp offsets accumulated over the minute. A perfect set of nine bursts could generate as many as 90 timestamps, but the maximum the interface can handle is 60. These are processed by the interface using a median filter and trimmed-mean average, so the resulting system clock correction is usually much better than would otherwise be the case with radio noise, UART jitter and occasional burst errors.

    -

    Autotune

    -

    The driver includes provisions to automatically tune the radio in response to changing radio propagation conditions throughout the day and night. The radio interface is compatible with the ICOM CI-V standard, which is a bidirectional serial bus operating at TTL levels. The bus can be connected to a standard serial port using a level converter such as the CT-17.

    -

    Each ICOM radio is assigned a unique 8-bit ID select code, usually expressed in hex format. To activate the CI-V interface, the mode keyword of the server configuration command specifies a nonzero select code in decimal format. A table of ID select codes for the known ICOM radios is given below. Since all ICOM select codes are less than 128, the high order bit of the code is used by the driver to specify the baud rate. If this bit is not set, the rate is 9600 bps for the newer radios; if set, the rate is 1200 bps for the older radios. A missing mode keyword or a zero argument leaves the interface disabled.

    -

    If specified, the driver will attempt to open the device /dev/icom and, if successful will tune the radio to 3.330 MHz. If after five minutes at this frequency not more than two format A bursts have been received for any minute, the driver will tune to 7.335 MHz, then to 14.670 MHz, then return to 3.330 MHz and continue in this cycle. However, the driver is liberal in what it assumes of the configuration. If the /dev/icom link is not present or the open fails or the CI-V bus or radio is inoperative, the driver quietly gives up with no harm done.

    -

    Radio Broadcast Format

    -

    The CHU time broadcast includes an audio signal compatible with the Bell 103 modem standard (mark = 2225 Hz, space = 2025 Hz). It consist of nine, ten-character bursts transmitted at 300 b/s and beginning each second from second 31 to second 39 of the minute. Each character consists of eight data bits plus one start bit and two stop bits to encode two hex digits. The burst data consist of five characters (ten hex digits) followed by a repeat of these characters. In format A, the characters are repeated in the same polarity; in format B, the characters are repeated in the opposite polarity.

    -

    Format A bursts are sent at seconds 32 through 39 of the minute in hex digits

    -

    6dddhhmmss6dddhhmmss

    -

    The first ten digits encode a frame marker (6) followed by the day (ddd), hour (hh), minute (mm) and second (ss). Since format A bursts are sent during the third decade of seconds the tens digit of ss is always 3. The driver uses this to determine correct burst synchronization. These digits are then repeated with the same polarity.

    -

    Format B bursts are sent at second 31 of the minute in hex digits

    -

    xdyyyyttaaxdyyyyttaa

    -

    The first ten digits encode a code (x described below) followed by the DUT1 (d in deciseconds), Gregorian year (yyyy), difference TAI - UTC (tt) and daylight time indicator (aa) peculiar to Canada. These digits are then repeated with inverted polarity.

    -

    The x is coded

    -
    -
    1 -
    Sign of DUT (0 = +)/dd> -
    2 -
    Leap second warning. One second will be added. -
    4 -
    Leap second warning. One second will be subtracted. This is not likely to happen in our universe. -
    8 -
    Even parity bit for this nibble. -
    -

    By design, the last stop bit of the last character in the burst coincides with 0.5 second. Since characters have 11 bits and are transmitted at 300 b/s, the last stop bit of the first character coincides with 0.5 - 10 * 11/300 = 0.133 second. Depending on the UART, character interrupts can vary somewhere between the beginning of bit 9 and end of bit 11. These eccentricities can be corrected along with the radio propagation delay using the fudge time1 variable.

    -

    Debugging Aids

    -

    The most convenient way to track the program status is using the ntpq program and the clockvar command. This displays the last determined timecode and related status and error counters, even when the program is not discipline the system clock. If the debugging trace feature (-d on the ntpd command line)is enabled, the program produces detailed status messages as it operates. If the fudge flag 4 is set, these messages are written to the clockstats file. All messages produced by this driver have the prefix chu for convenient filtering with the Unix grep command.

    -

    With debugging enabled the driver produces messages in the following formats:

    -

    A format chuA message is produced for each format A burst received in seconds 32 through 39 of the minute:

    -

    chuA n b s code

    -

    where n is the number of characters in the burst (0-11), b the burst distance (0-40), s the synchronization distance (0-40) and code the burst characters as received. Note that the hex digits in each character are reversed and the last ten digits inverted, so the burst

    -

    11 40 1091891300ef6e76ecff

    -

    is interpreted as containing 11 characters with burst distance 40. The nibble-swapped timecode shows DUT1 +0.1 second, year 1998 and TAI -UTC 31 seconds.

    -

    A format chuB message is produced for each format B burst received in second 31 of the minute:

    -

    chuB n b f s m code

    -

    where n is the number of characters in the burst (0-11), b the burst distance (0-40), f the field alignment (-1, 0, 1), sthe synchronization distance (0-16), mthe burst number (2-9) and code the burst characters as received. Note that the hex digits in each character are reversed, so the burst

    -

    10 38 0 16 9 06851292930685129293

    -

    is interpreted as containing 11 characters with burst distance 38, field alignment 0, synchronization distance 16 and burst number 9. The nibble-swapped timecode shows day 58, hour 21, minute 29 and second 39.

    -

    If the CI-V interface for ICOM radios is active, a debug level greater than 1 will produce a trace of the CI-V command and response messages. Interpretation of these messages requires knowledge of the CI-V protocol, which is beyond the scope of this document.

    -

    Monitor Data

    - When enabled by the filegen facility, every received timecode is written to the clockstats file in the following format: -
    -        sq yy ddd hh:mm:ss.fff ld dut lset agc rfrq bcnt dist tsmp
    -
    -        s       sync indicator
    -        q       quality character
    -        yyyy    Gregorian year
    -        ddd     day of year
    -        hh      hour of day
    -        mm      minute of hour
    -        ss      second of minute
    -        fff     millisecond of second
    -        l       leap second warning
    -        d       DST state
    -        dut     DUT sign and magnitude in deciseconds
    -        lset    minutes since last set
    -        agc     audio gain (0-255)
    -        rfrq    radio frequency
    -        bcnt    burst count
    -        dist    decoding distance
    -        tsmp    timestamps captured
    -
    - The fields beginning with year and extending through dut are decoded from the received data and are in fixed-length format. The agc and lset fields, as well as the following driver-dependent fields, are in variable-length format. -
    -
    s -
    The sync indicator is initially ? before the clock is set, but turns to space when the clock is correctly set. -
    q -
    The quality character is a four-bit hexadecimal code showing which alarms have been raised during the most recent minute. Each bit is associated with a specific alarm condition according to the following: -
    -
    8 -
    Decoder alarm. A majority of repetitions for at least one digit of the timecode fails to agree. -
    4 -
    Timestamp alarm. Fewer than 20 timestamps have been determined. -
    2 -
    Format alarm. The majority timecode contains invalid bit combinations. -
    1 -
    Frame alarm. A framing or format error occurred on at least one burst during the minute. -
    -

    It is important to note that one or more of the above alarms does not necessarily indicate a clock error, but only that the decoder has detected a condition that may in future result in an error.

    -
    yyyy ddd hh:mm:ss.fff -
    The timecode format itself is self explanatory. Note that the Gregorian year is decoded directly from the transmitted timecode. -
    l -
    The leap second warning is normally space, but changes to L if a leap second is to occur at the end of the month of June or December. -
    d -
    The DST code for Canada encodes the state for all provinces. -
    dut -
    The DUT sign and magnitude shows the current UT1 offset relative to the displayed UTC time, in deciseconds. -
    lset -
    Before the clock is set, the interval since last set is the number of minutes since the program was started; after the clock is set, this is number of minutes since the time was last verified relative to the broadcast signal. -
    agc -
    The audio gain shows the current codec gain setting in the range 0 to 255. Ordinarily, the receiver audio gain control or IRIG level control should be set for a value midway in this range. -
    rfrq -
    The current radio frequency, if the CI-V interface is active, or 'X' if not. -
    bcnt -
    The number of format A bursts received during the most recent minute bursts were received. -
    dist -
    The minimum decoding distance determined during the most recent minute bursts were received. -
    tsmp -
    The number of timestamps determined during the most recent minute bursts were received. -
    -

    Modes

    -

    The mode keyword of the server configuration command specifies the ICOM ID select code. A missing or zero argument disables the CI-V interface. Following are the ID select codes for the known radios.

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    RadioHexDecimalRadioHexDecimal
    IC7250x2840IC7810x2638
    IC7260x3048R70000x088
    IC7350x044R710x1A26
    IC7510x1c28R71000x3452
    IC7610x1e30R720x3250
    IC7650x2c44R85000x4a74
    IC7750x4668R90000x2a42
    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the propagation delay for CHU (45:18N 75:45N), in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default CHU. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    When the audio driver is compiled, this flag selects the audio input port, where 0 is the mike port (default) and 1 is the line-in port. It does not seem useful to select the compact disc player port. -
    flag3 0 | 1 -
    When the audio driver is compiled, this flag enables audio monitoring of the input signal. For this purpose, the speaker volume must be set before the driver is started. -
    flag4 0 | 1 -
    Enable verbose clockstats recording if set. -
    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/driver8.html src.ntp/contrib/ntp/html/drivers/driver8.html --- src/contrib/ntp/html/drivers/driver8.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver8.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,279 +0,0 @@ - - - - - - - Generic Reference Driver - - - - -

    Generic Reference Driver

    -
    -

    Synopsis

    - Address: 127.127.8.u
    - Reference ID: PARSE
    - Driver ID: GENERIC
    - Serial Port: /dev/refclock-u; TTY mode according to clock type
    - PPS device: /dev/refclockpps-u; alternate PPS device (if not available via the serial port) -

    Description

    - The PARSE driver supports 20 different clock types/configurations. PARSE is actually a multi-clock driver.
    -
    -

    The actual receiver status is mapped into various synchronization states generally used by receivers. The driver is configured to interpret the time codes of Meinberg DCF77 AM receivers, DCF77 FM receivers, Meinberg GPS16x/17x receivers, Trimble SV6 GPS, ELV DCF7000, Schmid, Wharton 400A and low cost receivers (see list below).

    -

    The reference clock support in NTP contains the necessary configuration tables for those receivers. In addition to supporting several different clock types and up to 4 devices, the processing of a PPS signal is also provided as a configuration option. The PPS configuration option uses the receiver-generated time stamps for feeding the PPS loopfilter control for much finer clock synchronization.

    -

    CAUTION: The PPS configuration option is different from the hardware PPS signal, which is also supported (see below), as it controls the way ntpd is synchronized to the reference clock, while the hardware PPS signal controls the way time offsets are determined.

    -

    The use of the PPS option requires receivers with an accuracy of better than 1ms.

    -

    Timecode variables listed by ntpq (8)

    -

    The ntpq program can read and display several clock variables. These hold the following information:

    -
    -
    refclock_format
    -
    A qualification of the decoded time code format.
    -
    refclock_states
    -
    The overall running time and the accumulated times for the clock event states.
    -
    refclock_status
    -
    Lists the currently active receiver flags. Additional feature flags for the receiver are optionally listed in parentheses.
    -
    refclock_time
    -
    The local time with the offset to UTC (format HHMM).
    -
    timecode
    -
    The actual time code.
    -
    -

    If PPS information is present, additional variables are available:

    -
    -
    refclock_ppsskew
    -
    The difference between the RS-232-derived timestamp and the PPS timestamp.
    -
    refclock_ppstime
    -
    The PPS timestamp.
    -
    -

    Supported Devices

    -

    Currently, nineteen clock types (devices /dev/refclock-0 - /dev/refclock-3) are supported by the PARSE driver.
    - A note on the implementations:

    -
      -
    • These implementations were mainly done without actual access to the hardware, thus not all implementations provide full support. The development was done with the help of many kind souls who had the hardware and kindly lent me their time and patience during the development and debugging cycle. Thus for continued support and quality, direct access to the receivers is a big help. Nevertheless I am not prepared to buy these reference clocks - donations to (kardel <AT> ntp.org) are welcome as long as they work within Europe 8-). -

      Verified implementations are:

      -
        -
      • RAWDCF variants -

        These variants have been tested for correct decoding with my own homegrown receivers. Interfacing with specific commercial products may involve some fiddling with cables. In particular, commercial RAWDCF receivers have a seemingly unlimited number of ways to draw power from the RS-232 port and to encode the DCF77 datastream. You are mainly on your own here unless I have a sample of the receiver.

        -
      • Meinberg clocks -

        These implementations have been verified by the Meinberg people themselves and I have access to one of these clocks.

        -
      -
    -

    The pictures below have been taken from and are linked to the vendors' web pages.

    - -
      -
    • server 127.127.8.0-3 mode 0 -

      Meinberg PZF5xx receiver family (FM demodulation/TCXO / 50μs)
      -

      - -
    • server 127.127.8.0-3 mode 1 -

      Meinberg PZF5xx receiver family (FM demodulation/OCXO / 50μs)
      - Image PZF511
      -

      - -
    • server 127.127.8.0-3 mode 2 -

      Meinberg DCF C51 receiver and similar (AM demodulation / 4ms)
      - Image C51
      -

      -

      This mode expects the Meinberg standard time string format with 9600/7E2.

      -

      Note: mode 2 must also be used for Meinberg PCI cards under Linux, e.g. the GPS PCI card or the DCF77 PCI card. Please note the Meinberg Linux driver must be installed. That driver emulates a refclock device in order to allow ntpd to access those cards. For details, please refer to the README file that comes with the Meinberg driver package.
      -

      - -
    • server 127.127.8.0-3 mode 3 -

      ELV DCF7000 (sloppy AM demodulation / 50ms)
      -

      - -
    • server 127.127.8.0-3 mode 4 -

      Walter Schmid DCF receiver Kit (AM demodulation / 1ms)
      -

      - -
    • server 127.127.8.0-3 mode 5 -

      RAW DCF77 100/200ms pulses (Conrad DCF77 receiver module / 5ms)
      -

      - -
    • server 127.127.8.0-3 mode 6 -

      RAW DCF77 100/200ms pulses (TimeBrick DCF77 receiver module / 5ms)
      -

      - -
    • server 127.127.8.0-3 mode 7 -

      Meinberg GPS16x/GPS17x receivers (GPS / <<1μs)
      - Image GPS167
      -

      -

      This mode expects either the University of Erlangen time string format or the Meinberg standard time string format at 19200/8N1.

      -

      The University of Erlangen format is preferred. Newer Meinberg GPS receivers can be configured to transmit that format; for older devices, a special firmware version may be available.

      -

      In this mode some additional GPS receiver status information is also read. However, this requires a point-to-point connection. Mode 18 should be used if the device is accessed by a multidrop connection.

      -

      Note: mode 7 must not be used with Meinberg PCI cards; use mode 2 instead.
      -

      - -
    • server 127.127.8.0-3 mode 8 -

      IGEL clock
      - Image IGEL clock
      -

      - -
    • server 127.127.8.0-3 mode 9 -

      Trimble SVeeSix GPS receiver TAIP protocol (GPS / <<1μs)
      -

      - -
    • server 127.127.8.0-3 mode 10 -

      Trimble SVeeSix GPS receiver TSIP protocol (GPS / <<1μs) (no kernel support yet)
      - Image SVeeSix-CM3
      - Image Lassen-SK8
      -

      - -
    • server 127.127.8.0-3 mode 11 -

      Radiocode Clocks Ltd RCC 8000 Intelligent Off-Air Master Clock support
      -

      - -
    • server 127.127.8.0-3 mode 12 -

      HOPF Funkuhr 6021
      - Image DCF77 Interface Board
      -

      - -
    • server 127.127.8.0-3 mode 13 -

      Diem's Computime Radio Clock
      -

      - -
    • server 127.127.8.0-3 mode 14 -

      RAWDCF receiver (DTR=high/RTS=low)
      -

      - -
    • server 127.127.8.0-3 mode 15 -

      WHARTON 400A Series Clocks with a 404.2 Serial Interface
      -

      - -
    • server 127.127.8.0-3 mode 16 -

      RAWDCF receiver (DTR=low/RTS=high)
      -

      - -
    • server 127.127.8.0-3 mode 17 -

      VARITEXT Receiver (MSF)
      -

      - -
    • server 127.127.8.0-3 mode 18 -

      Meinberg GPS16x/GPS17x receivers (GPS / <<1μs)
      -

      -

      This mode works without additional data communication (version, GPS status etc.) and thus should be used with multidrop, heterogeneous multiclient operation.

      -

      Note: mode 18 must not be used with Meinberg PCI cards, use mode 2 instead.
      -

      -
    • server 127.127.8.0-3 mode 19 -

      Gude Analog- und Digitalsystem GmbH 'Expert mouseCLOCK USB v2.0'
      -

      - -
    -

    Actual data formats and setup requirements of the various clocks can be found in NTP PARSE clock data formats.

    -

    Operation

    -

    The reference clock support software carefully monitors the state transitions of the receiver. All state changes and exceptional events (such as loss of time code transmission) are logged via the syslog facility. Every hour a summary of the accumulated times for the clock states is listed via syslog.

    -

    PPS support is only available when the receiver is completely synchronized. The receiver is believed to deliver correct time for an additional period of time after losing synchronization, unless a disruption in time code transmission is detected (possible power loss). The trust period is dependent on the receiver oscillator and thus is a function of clock type.

    -

    Raw DCF77 pulses can be fed via a level converter to the RXD pin of an RS-232 serial port (pin 3 of a 25-pin connector or pin 2 of a 9-pin connector). The telegrams are decoded and used for synchronization. DCF77 AM receivers can be bought for as little as $25. The accuracy is dependent on the receiver and is somewhere between 2ms (expensive) and 10ms (cheap). Synchronization ceases when reception of the DCF77 signal deteriorates, since no backup oscillator is available as usually found in other reference clock receivers. So it is important to have a good place for the DCF77 antenna. During transmitter shutdowns you are out of luck unless you have other NTP servers with alternate time sources available.

    -

    In addition to the PPS loopfilter control, a true PPS hardware signal can be utilized via the PPSAPI interface. PPS pulses are usually fed via a level converter to the DCD pin of an RS-232 serial port (pin 8 of a 25-pin connector or pin 1 of a 9-pin connector). To select PPS support, the mode parameter is the mode value as above plus 128. If 128 is not added to the mode value, PPS will be detected to be available but will not be used. -

    -

    Hardware PPS support
    -

    -

    For PPS to be used, add 128 to the mode parameter.

    -

    If the PPS signal is fed in from a device different from the device providing the serial communication (/dev/refclock-{0..3}), this device is configured as /dev/refclockpps-{0..3}. This allows the PPS information to be fed in e.g. via the parallel port (if supported by the underlying operation system) and the date/time telegrams to be handled via the serial port.

    -

    Monitor Data

    -

    Clock state statistics are written hourly to the syslog service. Online information can be found by examining the clock variables via the ntpq cv command.
    - Some devices have quite extensive additional information (GPS16x/GPS17x, Trimble). The driver reads out much of the internal GPS data - and makes it accessible via clock variables. To find out about additional variable names, query for the clock_var_list variable on - a specific clock association as shown below. -

    -

    First let ntpq display the table of associations:

    -
    -  ntpq> as
    -  ind assID status  conf reach auth condition  last_event cnt
    -  ===========================================================
    -    1 19556  9154   yes   yes  none falsetick   reachable  5
    -    2 19557  9435   yes   yes  none  candidat  clock expt  3
    -    3 19558  9714   yes   yes  none  pps.peer   reachable  1
    -		
    -

    Then switch to raw output. This may be required because of display limitations in ntpq/ntpd - so large lists need to be retrieved in several queries.

    -
    -  ntpq> raw
    -  Output set to raw
    -		
    -

    Use the cv command to read the list of clock variables of a selected association:

    -
    -  ntpq> cv 19557 clock_var_list
    -		
    -

    The long output of the command above looks similar to:

    -
    -  assID=19557 status=0x0000,
    -  clock_var_list="type,timecode,poll,noreply,badformat,baddata,fudgetime1,
    -  fudgetime2,stratum,refid,flags,device,clock_var_list,refclock_time,refclock_status,
    -  refclock_format,refclock_states,refclock_id,refclock_iomode,refclock_driver_version,
    -  meinberg_gps_status,gps_utc_correction,gps_message,meinberg_antenna_status,gps_tot_51,
    -  gps_tot_63,gps_t0a,gps_cfg[1],gps_health[1],gps_cfg[2],gps_health[2],gps_cfg[3],
    -  gps_health[3],gps_cfg[4],gps_health[4],gps_cfg[5]"
    -		
    -

    Then use the cv command again to list selected clock variables. The following command must be entered as a single line:

    -
    -  ntpq> cv 19557 refclock_status,refclock_format,refclock_states,refclock_id,
    -  refclock_iomode,refclock_driver_version,meinberg_gps_status,gps_utc_correction,
    -  gps_message,meinberg_antenna_status,gps_tot_51,gps_tot_63,gps_t0a,gps_cfg[1],
    -  gps_health[1],gps_cfg[2],gps_health[2],gps_cfg[3],gps_health[3],gps_cfg[4],
    -  gps_health[4],gps_cfg[5]
    -		
    -

    The output of the command above is wrapped around depending on the screen width and looks similar to:

    -
    -  status=0x0003,
    -  refclock_status="UTC DISPLAY; TIME CODE; PPS; POSITION; (LEAP INDICATION;
    -  PPS SIGNAL; POSITION)",
    -  refclock_format="Meinberg GPS Extended",
    -  refclock_states="*NOMINAL: 21:21:36 (99.99%); FAULT: 00:00:03 (0.00%);
    -  running time: 21:21:39",
    -  refclock_id="GPS", refclock_iomode="normal",
    -  refclock_driver_version="refclock_parse.c,v 4.77 2006/08/05 07:44:49
    -  kardel RELEASE_20060805_A",
    -  meinberg_gps_status="[0x0000] <OK>",
    -  gps_utc_correction="current correction 14 sec, last correction
    -  on c7619a00.00000000  Sun, Jan  1 2006  0:00:00.000",
    -  gps_message="/PFU3SOP-4WG14EPU0V1KA",
    -  meinberg_antenna_status="RECONNECTED on 2006-07-18 08:13:20.0000000 (+0000)
    -  UTC CORR, LOCAL TIME, reconnect clockoffset +0.0000000 s,
    -  disconnect time 0000-00-00 00:00:00.0000000 (+0000) ",
    -  gps_tot_51="week 1400 + 3 days + 42300.0000000 sec",
    -  gps_tot_63="week 1400 + 3 days + 42294.0000000 sec",
    -  gps_t0a="week 1400 + 5 days + 71808.0000000 sec",
    -  gps_cfg[1]="[0x9] BLOCK II", gps_health[1]="[0x0] OK;SIGNAL OK",
    -  gps_cfg[2]="[0x0] BLOCK I", gps_health[2]="[0x3f] PARITY;MULTIPLE ERRS",
    -  gps_cfg[3]="[0x9] BLOCK II", gps_health[3]="[0x0] OK;SIGNAL OK",
    -  gps_cfg[4]="[0x9] BLOCK II", gps_health[6]="[0x0] OK;SIGNAL OK",
    -  gps_cfg[5]="[0x9] BLOCK II"
    -		
    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction. The default value depends on the clock type. -
    time2 time -
    - If flag1 is 0, time2 specifies the offset of the PPS signal from the actual time (PPS fine tuning). -
    - If flag1 is 1, time2 specifies the number of seconds a receiver with a premium local oscillator can be trusted after losing synchronisation. -
    stratum stratum -
    The stratum for this reference clock. -
    refid refid -
    The refid for this reference clock. -
    -
    -
    flag1 { 0 | 1 } -
    If 0, the fudge factor time2 refers to the PPS offset. -
    If 1, time2 refers to the TRUST TIME. -
    flag2 { 0 | 1 } -
    If flag2 is 1, sample PPS on CLEAR instead of on ASSERT. -
    flag3 { 0 | 1 } -
    If flag3 is 1, link kernel PPS tracking to this refclock instance. -
    flag4 { 0 | 1 } -
    Delete next leap second instead of adding it. (You'll need to wait a bit for that to happen 8-) -
    - Note about auxiliary Sun STREAMS modules (SunOS and Solaris):
    -
    -
    The timecode of these receivers can be sampled via a STREAMS module in the kernel. (The STREAMS module has been designed for use with Sun systems under SunOS 4.1.x or Solaris 2.3 - 2.8. It can be linked directly into the kernel or loaded via the loadable driver mechanism.) This STREAMS module can be adapted to convert different time code formats. Nowadays the PPSAPI mechanism is usually used. -
    -

    Making your own PARSE clocks

    -

    The parse clock mechanism deviates from the way other NTP reference clocks work. For a short description of how to build parse reference clocks, see making PARSE clocks.

    -

    Additional Information

    -

    Reference Clock Drivers

    -
    - - - - diff -urN src/contrib/ntp/html/drivers/driver9.html src.ntp/contrib/ntp/html/drivers/driver9.html --- src/contrib/ntp/html/drivers/driver9.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/driver9.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,58 +0,0 @@ - - - - - - - - Magnavox MX4200 GPS Receiver - - - - -

    Magnavox MX4200 GPS Receiver

    -
    -

    Synopsis

    - Address: 127.127.9.u
    - Reference ID: GPS
    - Driver ID: GPS_MX4200
    - Serial Port: /dev/gpsu; 4800 baud, 8-bits, no parity
    - Features: ppsclock (required) -

    Description

    -

    This driver supports the Magnavox MX4200 Navigation Receiver adapted to precision timing applications. It requires the ppsclock line discipline or streams module described in the Line Disciplines and Streams Modules page. It also requires a level converter such as described in the Pulse-per-second (PPS) Signal Interfacing page.

    -

    This driver supports all compatible receivers such as the 6-channel MX4200, MX4200D, and the 12-channel MX9212, MX9012R, MX9112.

    -

    Leica MX9400N Navigator Leica Geosystems acquired the Magnavox commercial GPS technology business in February of 1994. They now market and support former Magnavox GPS products such as the MX4200 and its successors.

    -
    -

    Leica MX9400N Navigator.

    -

    Operating Modes

    -

    This driver supports two modes of operation, static and mobile, controlled by clock flag 2.

    -

    In static mode (the default) the driver assumes that the GPS antenna is in a fixed location. The receiver is initially placed in a "Static, 3D Nav" mode, where latitude, longitude, elevation and time are calculated for a fixed station. An average position is calculated from this data. After 24 hours, the receiver is placed into a "Known Position" mode, initialized with the calculated position, and then solves only for time.

    -

    In mobile mode, the driver assumes the GPS antenna is mounted on a moving platform such as a car, ship, or aircraft. The receiver is placed in "Dynamic, 3D Nav" mode and solves for position, altitude and time while moving. No position averaging is performed.

    -

    Monitor Data

    -

    The driver writes each timecode as received to the clockstats file. Documentation for the NMEA-0183 proprietary sentences produced by the MX4200 can be found in MX4200 Receiver Data Format.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default GPS. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Assume GPS receiver is on a mobile platform if set. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Not used by this driver. -
    -

    Additional Information

    -

    Reference Clock Drivers 

    -
    - - - - \ No newline at end of file Files src/contrib/ntp/html/drivers/icons/home.gif and src.ntp/contrib/ntp/html/drivers/icons/home.gif differ Files src/contrib/ntp/html/drivers/icons/mail2.gif and src.ntp/contrib/ntp/html/drivers/icons/mail2.gif differ diff -urN src/contrib/ntp/html/drivers/oncore-shmem.html src.ntp/contrib/ntp/html/drivers/oncore-shmem.html --- src/contrib/ntp/html/drivers/oncore-shmem.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/oncore-shmem.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,161 +0,0 @@ - - - - - - - ONCORE - SHMEM - - - - -

    Motorola ONCORE - The Shared Memory Interface

    -
    -

    Introduction

    -

    In NMEA mode, the Oncore GPS receiver provides the user with the same information as other GPS receivers. In BINARY mode, it can provide a lot of additional information.

    -

    In particular, you can ask for satellite positions, satellite health, signal levels, the ephemeris and the almanac, and you can set many operational parameters. In the case of the VP, you can get the pseudorange corrections necessary to act as a DGPS base station, and you can see the raw satellite data messages themselves.

    -

    When using the Oncore GPS receiver with NTP, this additional information is usually not available since the receiver is only talking to the oncore driver in NTPD. To make this information available for use in other programs, (say graphic displays of satellites positions, plots of SA, etc.), a shared memory interface (SHMEM) has been added to the refclock_oncore driver on those operating systems that support shared memory.

    -

    To make use of this information you will need an Oncore Reference Manual for the Oncore GPS receiver that you have. The Manual for the VP only exists as a paper document, the UT+/GT+/M12 manuals are available as a pdf documents at Synergy .

    -

    This interface was written by Poul-Henning Kamp (phk@FreeBSD.org), and modified by Reg Clemens (reg@dwf.com). The interface is known to work in FreeBSD, Linux, and Solaris.

    -

    Activating the Interface

    -

    Although the Shared Memory Interface will be compiled into the Oncore driver on those systems where Shared Memory is supported, to activate this interface you must include a STATUS or SHMEM line in the /etc/ntp.oncore data file that looks like

    -
    -        STATUS < file_name >
    - - or
    - - SHMEM < file_name > -
    - Thus a line like -
    -        SHMEM /var/adm/ntpstats/ONCORE
    -
    -

    would be acceptable. This file name will be used to access the Shared Memory.

    -

    In addition, one the two keywords Posn2D and Posn3D can be added to see @@Ea records containing the 2D or 3D position of the station (see below). Thus to activate the interface, and see 3D positions, something like

    -
    -        SHMEM /var/adm/ntpstats/ONCORE
    -        Posn3D
    -
    -

    would be required.

    -

    Storage of Messages in Shared Memory

    -

    With the shared memory interface, the oncore driver (refclock_oncore) allocates space for all of the messages that it is configured to receive, and then puts each message in the appropriate slot in shared memory as it arrives from the receiver. Since there is no easy way for a client program to know when the shared memory has been updated, a sequence number is associated with each message, and is incremented when a new message arrives. With the sequence number it is easy to check through the shared memory segment for messages that have changed.

    -

    The Oncore binary messages are kept in their full length, as described in the Reference manual, that is everything from the @@ prefix thru the <checksum><CR><LF>.

    -

    The data starts at location ONE of SHMEM (NOT location ZERO).

    -

    The messages are stacked in a series of variable length structures, that look like

    -
    -        struct message {
    -                u_int   length;
    -                u_char  sequence;
    -                u_char  message[length];
    -        }
    -
    -

    if something like that were legal. That is, there are two bytes (caution, these may NOT be aligned with word boundaries, so the field needs to be treated as a pair of u_char), that contains the length of the next message. This is followed by a u_char sequence number, that is incremented whenever a new message of this type is received. This is followed by 'length' characters of the actual message.

    -

    The next structure starts immediately following the last char of the previous message (no alignment). Thus, each structure starts a distance of 'length+3' from the previous structure.

    -

    Following the last structure, is a u_int containing a zero length to indicate the end of the data.

    -

    The messages are recognized by reading the headers in the data itself, viz @@Ea or whatever.

    -

    There are two special cases.

    -

    (1) The almanac takes a total of 34 submessages all starting with @@Cb.
    - 35 slots are allocated in shared memory. Each @@Cb message is initially placed in the first of these locations, and then later it is moved to the appropriate location for that submessage. The submessages can be distinguished by the first two characters following the @@Cb header, and new data is received only when the almanac changes.

    -

    (2) The @@Ea message contains the calculated location of the antenna, and is received once per second. However, when in timekeeping mode, the receiver is normally put in 0D mode, with the position fixed, to get better accuracy. In 0D mode no position is calculated.

    -

    When the SHMEM option is active, and if one of Posn2D or Posn3D is specified, one @@Ea record is hijacked each 15s, and the receiver is put back in 2D/3D mode so the the current location can be determined (for position determination, or for tracking SA). The timekeeping code is careful NOT to use the time associated with this (less accurate) 2D/3D tick in its timekeeping functions.

    -

    Following the initial @@Ea message are 3 additional slots for a total of four. As with the almanac, the first gets filled each time a new record becomes available, later in the code, the message is distributed to the appropriate slot. The additional slots are for messages containing 0D, 2D and 3D positions. These messages can be distinguished by different bit patterns in the last data byte of the record.

    -

    Opening the Shared Memory File

    -

    The shared memory segment is accessed through a file name given on a SHMEM card in the /etc/ntp.oncore input file. The following code could be used to open the Shared Memory Segment:

    -
    -        char *Buf, *file;
    -        int size, fd;
    -        struct stat statbuf;
    -
    -        file = "/var/adm/ntpstats/ONCORE";  /* the file name on my ACCESS card */
    -        if ((fd=open(file, O_RDONLY)) < 0) {
    -                fprintf(stderr, "Cant open %s\n", file);
    -                exit(1);
    -        }
    -
    -        if (stat(file, &statbuf) < 0) {
    -                fprintf(stderr, "Cant stat %s\n", file);
    -                exit(1);
    -        }
    -
    -        size = statbuf.st_size;
    -        if ((Buf=mmap(0, size, PROT_READ, MAP_SHARED, fd, (off_t) 0)) < 0) {
    -                fprintf(stderr, "MMAP failed\n");
    -                exit(1);
    -        }
    -
    -

    Accessing the data

    -

    The following code shows how to get to the individual records.

    -
    -        void    oncore_msg_Ea(), oncore_msg_As(), oncore_msg_Bb();
    -
    -        struct Msg {
    -            char         c[5];
    -            unsigned int seq;
    -            void         (*go_to)(uchar *);
    -        };
    -
    -        struct Msg Hdr[] = { {"@@Bb", 0, &oncore_msg_Bb},
    -                             {"@@Ea", 0, &oncore_msg_Ea},
    -                             {"@@As", 0, &oncore_msg_As}};
    -
    -        void
    -        read_data()
    -        {
    -            int     i, j, k, n, iseq, jseq;
    -            uchar   *cp, *cp1;
    -
    -
    -            for(cp=Buf+1; (n = 256*(*cp) + *(cp+1)) != 0;  cp+=(n+3)) {
    -                for (k=0; k < sizeof(Hdr)/sizeof(Hdr[0]);  k++) {
    -                    if (!strncmp(cp+3, Hdr[k].c, 4)) {      /* am I interested? */
    -                        iseq = *(cp+2);
    -                        jseq = Hdr[k].seq;
    -                        Hdr[k].seq = iseq;
    -                        if (iseq > jseq) {              /* has it changed? */
    -                            /* verify checksum */
    -                            j = 0;
    -                            cp1 = cp+3;             /* points to start of oncore response */
    -                            for (i=2; i < n-3; i++)
    -                                j ^= cp1[i];
    -                            if (j == cp1[n-3]) {    /* good checksum */
    -                                    Hdr[k].go_to(cp1);
    -                            } else {
    -                                fprintf(stderr, "Bad Checksum for %s\n", Hdr[k].c);
    -                                break;
    -                            }
    -                        }
    -                    }
    -                }
    -                if (!strncmp(cp+3, "@@Ea", 4))
    -                    cp += 3*(n+3);
    -                if (!strncmp(cp+3, "@@Cb", 4))
    -                    cp += 34*(n+3);
    -            }
    -        }
    -
    -        oncore_msg_Bb(uchar *buf)
    -        {
    -                /* process Bb messages */
    -        }
    -
    -        oncore_msg_Ea(uchar *buf)
    -        {
    -                /* process Ea messages */
    -        }
    -
    -        oncore_msg_As(uchar *buf)
    -        {
    -                /* process As messages */
    -        }
    -
    -

    The structure Hdr contains the Identifying string for each of the messages that we want to examine, and the name of a program to call when a new message of that type is arrives. The loop can be run every few seconds to check for new data.

    -

    Examples

    -

    There are two complete examples available. The first plots satellite positions and the station position as affected by SA, and keeps track of the mean station position, so you can run it for periods of days to get a better station position. The second shows the effective horizon by watching satellite tracks. The examples will be found in the GNU-zipped tar file ftp://ftp.udel.edu/pub/ntp/software/OncorePlot.tar.gz.

    -

    Try the new interface, enjoy.

    -
    -
    Reg.Clemens (reg@dwf.com), Poul-Henning Kamp (phk@FreeBSD.org)
    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/scripts/footer.txt src.ntp/contrib/ntp/html/drivers/scripts/footer.txt --- src/contrib/ntp/html/drivers/scripts/footer.txt 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/scripts/footer.txt 1970-01-01 01:00:00.000000000 +0100 @@ -1,7 +0,0 @@ -document.write("\ -\ -\ -\ -
    gif\ -Home Pagegif\ -Contacts
    ") \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/scripts/style.css src.ntp/contrib/ntp/html/drivers/scripts/style.css --- src/contrib/ntp/html/drivers/scripts/style.css 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/scripts/style.css 1970-01-01 01:00:00.000000000 +0100 @@ -1,64 +0,0 @@ -body {background: #FDF1E1; - color: #006600; - font-family: "verdana", sans-serif; - text-align: justify; - margin-left: 5px;} - -p, h4, hr, li {margin-top: .6em; margin-bottom: .6em} -li.inline {text-align: left; margin-top: 0; margin-bottom: 0} - -ul, dl, ol, {margin-top: .6em; margin-bottom: .6em; margin-left 5em} - -dt {margin-top: .6em} -dd {margin-bottom: .6em} - -div.header {text-align: center; - font-style: italic;} - -div.footer {text-align: center; - font-size: 60%;} - -img.cell {align: left;} - -td.sidebar {width: 40px; align: center; valign: top;} -img.sidebar {align: center; margin-top: 5px;} -h4.sidebar {align: center;} - -p.top {background: #FDF1E1; - color: #006600; - position: absolute; - margin-left: -90px; - text-align: center;} - -a:link.sidebar {background: transparent; - color: #990033; - font-weight: bold;} - -a:visited.sidebar {background: transparent; - color: #990033; - font-weight: bold;} - -a:hover.sidebar {background: #FDF1E1; - color: #006600;} - -img {margin: 5px;} - -div {text-align: center;} - -h1 {text-align: center; - font-size: 250%;} - -caption {background: #EEEEEE; - color: #339999;} - -tx {text-align: center;} - -th {background: #FFFFCC; - color: #006600; - text-align: center; - text-decoration: underline; - padding-top: 5px;} - -th.caption {background: #EEEEEE; - color: #006600; - text-align: center;} \ No newline at end of file diff -urN src/contrib/ntp/html/drivers/tf582_4.html src.ntp/contrib/ntp/html/drivers/tf582_4.html --- src/contrib/ntp/html/drivers/tf582_4.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/drivers/tf582_4.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,71 +0,0 @@ - - - - - - - - PTB Modem Time Service - - - - -

    European Automated Computer Time Services

    -
    -

    Several European countries use the following message data format:

    -

    Data format
    - 0000000000111111111122222222223333333333444444444455555555556666666666777777777 7
    - 0123456789012345678901234567890123456789012345678901234567890123456789012345678 9
    - 1995-01-23 20:58:51 MEZ 10402303260219950123195849740+40000500 *
    - A B C D EF G H IJ K L M N O P Q R S T U V W XY Z<CR><LF>
    - A year
    - B month
    - C day
    - D hour
    - E : normally
    - A for DST to ST switch first hour
    - B for DST to ST switch second hour if not marked in H
    - F minute
    - G second
    - H timezone
    - I day of week
    - J week of year
    - K day of year
    - L month for next ST/DST changes
    - M day
    - N hour
    - O UTC year
    - P UTC month
    - Q UTC day
    - R UTC hour
    - S UTC minute
    - T modified julian day (MJD)
    - U DUT1
    - V direction and month if leap second
    - W signal delay (assumed/measured)
    - X sequence number for additional text line in Y
    - Y additional text
    - Z on time marker (* - assumed delay / # measured delay)
    - <CR>!<LF> ! is second change !
    -

    -

    This format is an ITU-R Recommendation (ITU-R TF583.4) and is now available from the primary timing centres of the following countries: Austria, Belgium, Germany, Italy, The Netherlands, Poland, Portugal, Romania, Spain, Sweden, Switzerland, Turkey and United Kingdom. Some examples are:

    - -
    -

    Additional Information

    -

    Reference Clock Drivers

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/extern.html src.ntp/contrib/ntp/html/extern.html --- src/contrib/ntp/html/extern.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/extern.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,33 +0,0 @@ - - - - - - - - External Clock Discipline and the Local Clock Driver - - - - -

    External Clock Discipline and the Local Clock Driver

    -

    Last update: 18:38 UTC Thursday, July 28, 2005

    -
    -

    The NTPv4 implementation includes provisions for an external clock, where the system clock is implemented by some external hardware device. One implementation might take the form of a bus peripheral with a high resolution counter disciplined by a GPS receiver, for example. Another implementation might involve another synchronization protocol, such as the Digital Time Synchronization Service (DTSS), where the system time is disciplined to this protocol and NTP clients of the server obtain synchronization indirectly via the server. A third implementation might be a completely separate clock discipline algorithm and synchronization protocol, such as the Lockclock algorithm used with NIST Automated Computer Time Service (ACTS) modem synchronized time.

    -

    When external clocks are used in conjunction with NTP service, some way needs to be provided for the external clock driver and NTP daemon ntpd to communicate and determine which discipline is in control. This is necessary in order to provide backup, for instance if the external clock or protocol were to fail and synchronization service fall back to other means, such as a local reference clock or another NTP server. In addition, when the external clock and driver are in control, some means needs to be provided for the clock driver to pass on status information and error statistics to the NTP daemon.

    -

    Control and monitoring functions for the external clock and driver are implemented using the Local Clock (type 1) driver and the ntp_adjtime() system call. This system call is implemented by special kernel provisions included in the kernel of several operating systems, including Solaris, Tru64, FreeBSD and Linux, and possibly others. When the external clock is disabled or not implemented, the system call is used to pass time and frequency information, as well as error statistics, to the kernel. Besides disciplining the system time, the same interface can be used by other applications to determine the operating parameters of the discipline.

    -

    When the external clock is enabled, ntpd does not discipline the system clock, nor does it maintain the error statistics. In this case, the external clock and driver do this using mechanisms unknown to ntpd; however, in this case the kernel state variables are retrieved at 64-s intervals by the Local Clock driver and used by the clock selection and mitigation algorithms to determine the system variables presented to other NTP clients and peers. In this way, downstream clients and servers in the NTP subnet can make an intelligent choice when more than one server is available.

    -

    In order to implement a reliable mitigation between ordinary NTP sources and the external clock source, a protocol is necessary between the local clock driver and the external clock driver. This is implemented using Boolean variables and certain bits in the kernel clock status word. The Boolean variables include the following:

    -

    ntp_enable. set/reset by the enable command. enables ntp clock discipline

    -

    ntp_control. set during initial configuration if kernel support is available

    -

    kern_enable Set/reset by the enable command

    -

    If the kern_enable switch is set, the daemon computes the offset, frequency, maximum error, estimated error, time constand and status bits, then provides them to the kernel via ntp_adjtime(). If this switch is not set, these values are not passed to the kernel; however, the daemon retrieves their present values and uses them in place of the values computed by the daemon.

    -

    The pps_update bit set in the protocol routine if the prefer peer has survived and has offset less than 128 ms; otherwise set to zero.

    -

    The pps_control Updated to the current time by kernel support if the PPS signal is enabled and working correctly. Set to zero in the adjust routine if the interval since the last update exceeds 120 s.

    -

    The ntp_enable and kern_enable are set by the configuration module. Normally, both switches default on, so the daemon can control the time and the kernel discipline can be used, if available. The pps_update switch is set by the protocol module when it believes the PPS provider source is legitimate and operating within nominals. The ntp_control switch is set during configuration by interrogating the kernel. If both the kern_enable and ntp_control switches are set, the daemon disciplines the clock via the kernel and the internal daemon discipline is disabled.

    -

    The external clock driver controls the system time and clock selection in the following way. Normally, the driver adjusts the kernel time using the ntp_adjtime() system call in the same way as the daemon. In the case where the kernel discipline is to be used intact, the clock offset is provided in this call and the loop operates as specified. In the case where the driver steers only the frequency, the offset is specified as zero.

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/gadget.html src.ntp/contrib/ntp/html/gadget.html --- src/contrib/ntp/html/gadget.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/gadget.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,33 +0,0 @@ - - - - - - - Gadget Box PPS Level Converter and CHU Modem - - - - -

    Gadget Box PPS Level Converter and CHU Modem

    - gifA Gadget Box built by Chuck Hanavin -

    Related Links

    -

    - -
    -

    -

    table of Contents

    - -
    -

    Introduction

    -

    Many radio clocks used as a primary reference source for NTP servers produce a pulse-per-second (PPS) signal that can be used to improve accuracy to a high degree. However, the signals produced are usually incompatible with the modem interface signals on the serial ports used to connect the signal to the host. The gadget box consists of a handful of electronic components assembled in a small aluminum box. It includes level converters and a optional radio modem designed to decode the radio timecode signals transmitted by the Canadian time and frequency station CHU. A complete set of schematics, PCB artwork, drill templates can be obrtained via the web from ftp.udel.edu as gadget.tar.Z.

    -

    The gadget box is assembled in a 5"x3"x2" aluminum minibox containing the level converter and modem circuitry. It includes two subcircuits. One of these converts a TTL positive edge into a fixed-width pulse at EIA levels and is for use with a timecode receiver or oscillator including a TTL PPS output. The other converts the timecode modulation broadcast by Canadian time/frequency standard station CHU into a 300-bps serial character stream at EIA levels and is for use with the Radio CHU Audio Demodulator/Decoder driver.

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/groups.html src.ntp/contrib/ntp/html/groups.html --- src/contrib/ntp/html/groups.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/groups.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,47 +0,0 @@ - - - - - - - - Trusted Hosts and Groups - - - - -

    Trusted Hosts and Groups

    - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

    Alice holds the key.

    -

    Last update: 00:12 UTC Tuesday, November 08, 2005

    -
    -

    Related Links

    - -

    Table of Contents

    - -
    -

    Trusted Hosts and Groups

    -

    Each cryptographic configuration involves selection of a signature scheme and identification scheme, called a cryptotype, as explained in the Authentication Options page. The default cryptotype uses RSA encryption, MD5 message digest and TC identification. First, configure a NTP subnet including one or more low-stratum trusted hosts from which all other hosts derive synchronization directly or indirectly. Trusted hosts have trusted certificates; all other hosts have nontrusted certificates. These hosts will automatically and dynamically build authoritative certificate trails to one or more trusted hosts. A trusted group is the set of all hosts that have, directly or indirectly, a certificate trail ending at a trusted host. The trail is defined by static configuration file entries or dynamic means described on the Automatic NTP Configuration Options page.

    -

    On each trusted host as root, change to the keys directory. To insure a fresh fileset, remove all ntpkey files. Then run ntp-keygen -T to generate keys and a trusted certificate. On all other hosts do the same, but leave off the -T flag to generate keys and nontrusted certificates. When complete, start the NTP daemons beginning at the lowest stratum and working up the tree. It may take some time for Autokey to instantiate the certificate trails throughout the subnet, but setting up the environment is completely automatic.

    -

    If it is necessary to use a different sign key or different digest/signature scheme than the default, run ntp-keygen with the -S type option, where type is either RSA or DSA. The most often need to do this is when a DSA-signed certificate is used. If it is necessary to use a different certificate scheme than the default, run ntp-keygen with the -c scheme option and selected scheme as needed. If ntp-keygen is run again without these options, it generates a new certificate using the same scheme and sign key.

    -

    After setting up the environment it is advisable to update certificates from time to time, if only to extend the validity interval. Simply run ntp-keygen with the same flags as before to generate new certificates using existing keys. However, if the host or sign key is changed, ntpd should be restarted. When ntpd is restarted, it loads any new files and restarts the protocol. Other dependent hosts will continue as usual until signatures are refreshed, at which time the protocol is restarted.

    -

    Identity Schemes

    -

    As mentioned on the Autonomous Authentication page, the default TC identity scheme is vulnerable to a middleman attack. However, there are more secure identity schemes available, including PC, IFF, GQ and MV described on the Identification Schemes page. These schemes are based on a TA, one or more trusted hosts and some number of nontrusted hosts. Trusted hosts prove identity using values provided by the TA, while the remaining hosts prove identity using values provided by a trusted host and certificate trails that end on that host. The name of a trusted host is also the name of its sugroup and also the subject and issuer name on its trusted certificate. The TA is not necessarily a trusted host in this sense, but often is.

    -

    In some schemes there are separate keys for servers and clients. A server can also be a client of another server, but a client can never be a server for another client. In general, trusted hosts and nontrusted hosts that operate as both server and client have parameter files that contain both server and client keys. Hosts that operate only as clients have key files that contain only client keys.

    -

    The PC scheme supports only one trusted host in the group. On trusted host alice run ntp-keygen -P -p password to generate the host key file ntpkey_RSAkey_alice.filestamp and trusted private certificate file ntpkey_RSA-MD5_cert_alice.filestamp. Copy both files to all group hosts; they replace the files which would be generated in other schemes. On each host bob install a soft link from the generic name ntpkey_host_bob to the host key file and soft link ntpkey_cert_bob to the private certificate file. Note the generic links are on bob, but point to files generated by trusted host alice. In this scheme it is not possible to refresh either the keys or certificates without copying them to all other hosts in the group.

    -

    For the IFF scheme proceed as in the TC scheme to generate keys and certificates for all group hosts, then for every trusted host in the group, generate the IFF parameter file. On trusted host alice run ntp-keygen -T -I -p password to produce her parameter file ntpkey_IFFpar_alice.filestamp, which includes both server and client keys. Copy this file to all group hosts that operate as both servers and clients and install a soft link from the generic ntpkey_iff_alice to this file. If there are no hosts restricted to operate only as clients, there is nothing further to do. As the IFF scheme is independent of keys and certificates, these files can be refreshed as needed.

    -

    If a rogue client has the parameter file, it could masquerade as a legitimate server and present a middleman threat. To eliminate this threat, the client keys can be extracted from the parameter file and distributed to all restricted clients. After generating the parameter file, on alice run ntp-keygen -e and pipe the output to a file or mail program. Copy or mail this file to all restricted clients. On these clients install a soft link from the generic ntpkey_iff_alice to this file. To further protect the integrity of the keys, each file can be encrypted with a secret password.

    -

    For the GQ scheme proceed as in the TC scheme to generate keys and certificates for all group hosts, then for every trusted host in the group, generate the IFF parameter file. On trusted host alice run ntp-keygen -T -G -p password to produce her parameter file ntpkey_GQpar_alice.filestamp, which includes both server and client keys. Copy this file to all group hosts and install a soft link from the generic ntpkey_gq_alice to this file. In addition, on each host bob install a soft link from generic ntpkey_gq_bob to this file. As the GQ scheme updates the GQ parameters file and certificate at the same time, keys and certificates can be regenerated as needed.

    -

    For the MV scheme, proceed as in the TC scheme to generate keys and certificates for all group hosts. For illustration assume trish is the TA, alice one of several trusted hosts and bob one of her clients. On TA trish run ntp-keygen -V n -p password, where n is the number of revokable keys (typically 5) to produce the parameter file ntpkeys_MVpar_trish.filestamp and client key files ntpkeys_MVkeyd_trish.filestamp where d is the key number (0 < d < n). Copy the parameter file to alice and install a soft link from the generic ntpkey_mv_alice to this file. Copy one of the client key files to alice for later distribution to her clients. It doesn't matter which client key file goes to alice, since they all work the same way. Alice copies the client key file to all of her cliens. On client bob install a soft link from generic ntpkey_mvkey_bob to the client key file. As the MV scheme is independent of keys and certificates, these files can be refreshed as needed.

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/howto.html src.ntp/contrib/ntp/html/howto.html --- src/contrib/ntp/html/howto.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/howto.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,109 +0,0 @@ - - - - - - - - How to Write a Reference Clock Driver - - - - -

    How to Write a Reference Clock Driver

    - giffrom Pogo, Walt Kelly -

    You need a little magic.

    -

    Last update: 18:39 UTC Thursday, July 28, 2005

    -
    -

    Related Links

    - -

    Table of Contents

    - -
    -

    Description

    -

    NTP reference clock support maintains the fiction that the clock is actually an ordinary peer in the NTP tradition, but operating at a synthetic stratum of zero. The entire suite of algorithms used to filter the received data, select the best clocks or peers and combine them to produce a system clock correction operate just like ordinary NTP peers. In this way, defective clocks can be detected and removed from the peer population. As no packets are exchanged with a reference clock; however, the transmit, receive and packet procedures are replaced with separate code to simulate them.

    -

    It is important to understand how the NTP clock driver interface works. The driver assumes three timescales: standard time maintained by a distant laboratory such as USNO or NIST, reference time maintained by the external radio and the system time maintained by NTP. The radio synchronizes reference time and frequency to standard time via radio, satellite or modem. As the transmission means may not always be reliable, most radios continue to provide clock updates for some time after signal loss using an internal reference oscillator. In such cases the radio may or may not reveal the time since last synchronized and/or the estimated time error.

    -

    All three timescales run only in Coordinated Universal Time (UTC), 24-hour format, and are not adjusted for local timezone or standard/daylight time. The local timezone, standard/daylight indicator and year, if provided, are ignored. However, it is important to determine whether a leap second is to be inserted in the UTC timescale in the near future so NTP can insert it in the system timescale at the appropriate epoch.

    -

    The NTP clock driver synchronizes the system time and frequency to the radio via serial or parallel port, PPS signal or other means. The driver routinely checks the radio timecode string or status indicators to determine whether it is operating correctly or not. If it is, the driver decodes the radio timecode in days, hours, minutes, seconds and nanoseconds and provides these data with the NTP receive timestamp corresponding to the on-time epoch of the timecode. The driver interface computes the difference between the timecode time and NTP timestamp and saves the difference in a circular buffer for later processing. Once each poll interval, usually 64 s, the driver provides ancillary data including leap bits and last reference time to the interface. The interface processes the circular buffer using a median/trimmed mean algorithm to extract the best estimate and provides this and the ancillary data to the clock filter as with ordinary NTP peers.

    -

    The audio drivers are designed to look like a typical external radio in that the reference oscillator is derived from the audio codec oscillator and separate from the system clock oscillator. In the WWV and IRIG drivers, the codec oscillator is disciplined in frequency to the standard timescale via radio or local sources and can be assumed to have the same reliability and accuracy as an external radio. In these cases the driver continues to provide updates to the clock filter even if the WWV or IRIG signals are lost. However, the interface is provided the last reference time when the signals were received and increases the dispersion as expected with an ordinary peer.

    -

    The best way to understand how the clock drivers work is to study the ntp_refclock.c module and one of the drivers already implemented, such as refclock_wwvb.c. Routines refclock_transmit() and refclock_receive() maintain the peer variables in a state analogous to a network peer and pass received data on through the clock filters. Routines refclock_peer() and refclock_unpeer() initialize and terminate reference clock associations, should this ever be necessary. A set of utility routines is included to open serial devices, process sample data, edit input lines to extract embedded timestamps and to perform various debugging functions.

    -

    The main interface used by these routines is the refclockproc structure, which contains for most drivers the decimal equivalents of the year, day, month, hour, second and nanosecond decoded from the radio timecode. Additional information includes the receive timestamp, reference timestamp, exception reports, statistics tallies, etc. The support routines are passed a pointer to the peer structure, which is used for all peer-specific processing and contains a pointer to the refclockproc structure, which in turn contains a pointer to the unit structure, if used. For legacy purposes, a table typeunit[type][unit] contains the peer structure pointer for each configured clock type and unit. This structure should not be used for new implementations.

    -

    The reference clock interface supports auxiliary functions to support in-stream timestamping, pulse-per-second (PPS) interfacing and precision time kernel support. In most cases the drivers do not need to be aware of them, since they are detected at autoconfigure time and loaded automatically when the device is opened. These include the tty_clk STREAMS module and ppsapi PPS interface described in the Line Disciplines and Streams Modules page. The tty_clk module reduces latency errors due to the operating system and serial port code in slower systems. The ppsapi PPS interface replaces the ppsclock STREAMS module and is expected to become the IETF standard cross-platform interface for PPS signals. In either case, the PPS signal can be connected via a level converter/pulse generator described in the Pulse-per-second (PPS) Signal Interfacing page.

    -

    Radio and modem reference clocks by convention have addresses in the form 127.127.t.u, where t is the clock type and u in the range 0-3 is used to distinguish multiple instances of clocks of the same type. Most clocks require a serial or parallel port or special bus peripheral. The particular device is normally specified by adding a soft link /dev/devicedd to the particular hardware device involved, where d corresponds to the unit number.

    -

    By convention, reference clock drivers are named in the form refclock_xxxx.c, where xxxx is a unique string. Each driver is assigned a unique type number, long-form driver name, short-form driver name and device name. The existing assignments are in the Reference Clock Drivers page and its dependencies. All drivers supported by the particular hardware and operating system are automatically detected in the autoconfigure phase and conditionally compiled. They are configured when the daemon is started according to the configuration file, as described in the Configuration Options page.

    -

    The standard clock driver interface includes a set of common support routines some of which do such things as start and stop the device, open the serial port, and establish special functions such as PPS signal support. Other routines read and write data to the device and process time values. Most drivers need only a little customizing code to, for instance, transform idiosyncratic timecode formats to standard form, poll the device as necessary, and handle exception conditions. A standard interface is available for remote debugging and monitoring programs, such as ntpq and ntpdc, as well as the filegen facility, which can be used to record device status on a continuous basis.

    -

    The general organization of a typical clock driver includes a receive-interrupt routine to read a timecode from the I/O buffer and convert to internal format, generally in days, hours, minutes, seconds and fraction. Some timecode formats include provisions for leap-second warning and determine the clock hardware and software health. The interrupt routine then calls refclock_process() with these data and the timestamp captured at the on-time character of the timecode. This routine saves each sample as received in a circular buffer, which can store from a few up to 60 samples, in cases where the timecodes arrive one per second.

    -

    The refclock_transmit() routine in the interface is called by the system at intervals defined by the poll interval in the peer structure, generally 64 s. This routine in turn calls the transmit poll routine in the driver. In the intended design, the driver calls the refclock_receive() to process the offset samples that have accumulated since the last poll and produce the final offset and variance. The samples are processed by recursively discarding median outlyers until about 60 percent of samples remain, then averaging the surviving samples. When a reference clock must be explicitly polled to produce a timecode, the driver can reset the poll interval so that the poll routine is called a specified number of times at 1-s intervals.

    -

    The interface code and this documentation have been developed over some time and required not a little hard work converting old drivers, etc. Should you find success writing a driver for a new radio or modem service, please consider contributing it to the common good. Send the driver file itself and patches for the other files to Dave Mills (mills@udel.edu).

    -

    Conventions, Fudge Factors and Flags

    -

    Most drivers support manual or automatic calibration for systematic offset bias using values encoded in the fudge configuration command. By convention, the time1 value defines the calibration offset in seconds. For those drivers that support statistics collection using the filegen utility and the clockstats file, the flag4 switch enables the utility. When a PPS signal is available, a special automatic calibration facility is provided. If the flag1 switch is set and the PPS signal is actively disciplining the system time, the calibration value is automatically adjusted to maintain a residual offset of zero. Should the PPS signal or the prefer peer fail, the adjustment is frozen and the remaining drivers continue to discipline the system clock with a minimum of residual error.

    -

    Files Which Need to be Changed

    -

    A new reference clock implementation needs to supply, in addition to the driver itself, several changes to existing files.

    -
    -
    ./include/ntp.h -
    The reference clock type defines are used in many places. Each driver is assigned a unique type number. Unused numbers are clearly marked in the list. A unique REFCLK_xxxx identification code should be recorded in the list opposite its assigned type number. -
    ./libntp/clocktypes.c -
    The ./libntp/clktype array is used by certain display functions. A unique short-form name of the driver should be entered together with its assigned identification code. -
    ./ntpd/ntp_control.c -
    The clocktypes array is used for certain control message displays functions. It should be initialized with the reference clock class assigned to the driver, as per the NTP specification RFC-1305. See the ./include/ntp_control.h header file for the assigned classes. -
    ./ntpd/refclock_conf.c -
    This file contains a list of external structure definitions which are conditionally defined. A new set of entries should be installed similar to those already in the table. The refclock_conf array is a set of pointers to transfer vectors in the individual drivers. The external name of the transfer vector should be initialized in correspondence with the type number. -
    ./configure.in -
    This is a configuration file used by the autoconfigure scheme. Add lines similar to the following: -
    -  AC_MSG_CHECKING(FOO clock_description)
    -  AC_ARG_ENABLE(FOO,
    -      AC_HELP_STRING([--enable-FOO], [x clock_description]),
    -      [ntp_ok=$enableval], [ntp_ok=$ntp_eac])
    -  if test "$ntp_ok" = "yes"; then
    -      ntp_refclock=yes
    -      AC_DEFINE(CLOCK_FOO, 1, [Foo clock?])
    -  fi
    -  AC_MSG_RESULT($ntp_ok)
    -
    -
    (Note that $ntp_eac is the value from --{dis,en}able-all-clocks for non-PARSE clocks and $ntp_eacp is the value from --{dis,en}able-parse-clocks for PARSE clocks. See the documentation on the autoconf and automake tools from the GNU distributions.) -
    ./ntpd/Makefile.am -
    This is the makefile prototype used by the autoconfigure scheme. Add the driver file name to the entries already in the ntpd_SOURCES list. -
    Do the following sequence of commands: -
    -  autoreconf
    -  configure
    -
    -
    or simply run make, which will do this command sequence automatically. -
    -

    Interface Routine Overview

    -
    -
    refclock_newpeer - initialize and start a reference clock -
    This routine allocates and initializes the interface structure which supports a reference clock in the form of an ordinary NTP peer. A driver-specific support routine completes the initialization, if used. Default peer variables which identify the clock and establish its reference ID and stratum are set here. It returns one if success and zero if the clock address is invalid or already running, insufficient resources are available or the driver declares a bum rap. -
    refclock_unpeer - shut down a clock -
    This routine is used to shut down a clock and return its resources to the system. -
    refclock_transmit - simulate the transmit procedure -
    This routine implements the NTP transmit procedure for a reference clock. This provides a mechanism to call the driver at the NTP poll interval, as well as provides a reachability mechanism to detect a broken radio or other madness. -
    refclock_sample - process a pile of samples from the clock -
    This routine converts the timecode in the form days, hours, minutes, seconds, milliseconds/microseconds to internal timestamp format. It then calculates the difference from the receive timestamp and assembles the samples in a shift register. It implements a recursive median filter to suppress spikes in the data, as well as determine a rough dispersion estimate. A configuration constant time adjustment fudgetime1 can be added to the final offset to compensate for various systematic errors. The routine returns one if success and zero if failure due to invalid timecode data or very noisy offsets. -
    Note that no provision is included for the year, as provided by some (but not all) radio clocks. Ordinarily, the year is implicit in the Unix file system and hardware/software clock support, so this is ordinarily not a problem. Nevertheless, the absence of the year should be considered more a bug than a feature and may be supported in future. -
    refclock_receive - simulate the receive and packet procedures -
    This routine simulates the NTP receive and packet procedures for a reference clock. This provides a mechanism in which the ordinary NTP filter, selection and combining algorithms can be used to suppress misbehaving radios and to mitigate between them when more than one is available for backup. -
    refclock_gtlin - groom next input line and extract timestamp -
    This routine processes the timecode received from the clock and removes the parity bit and control characters. If a timestamp is present in the timecode, as produced by the tty_clk line discipline/streams module, it returns that as the timestamp; otherwise, it returns the buffer timestamp. The routine return code is the number of characters in the line. -
    refclock_open - open serial port for reference clock -
    This routine opens a serial port for I/O and sets default options. It returns the file descriptor if success and zero if failure. -
    refclock_ioctl - set serial port control functions -
    This routine attempts to hide the internal, system-specific details of serial ports. It can handle POSIX (termios), SYSV (termio) and BSD (sgtty) interfaces with varying degrees of success. The routine sets up the tty_clk, chu_clk and ppsclock streams module/line discipline, if compiled in the daemon and requested in the call. The routine returns one if success and zero if failure. -
    refclock_control - set and/or return clock values -
    This routine is used mainly for debugging. It returns designated values from the interface structure that can be displayed using ntpdc and the clockstat command. It can also be used to initialize configuration variables, such as fudgetimes, fudgevalues, reference ID and stratum. -
    refclock_buginfo - return debugging info -
    This routine is used mainly for debugging. It returns designated values from the interface structure that can be displayed using ntpdc and the clkbug command. -
    -
    -
    - gif
    -
    - - - - \ No newline at end of file Files src/contrib/ntp/html/icons/home.gif and src.ntp/contrib/ntp/html/icons/home.gif differ Files src/contrib/ntp/html/icons/mail2.gif and src.ntp/contrib/ntp/html/icons/mail2.gif differ diff -urN src/contrib/ntp/html/index.html src.ntp/contrib/ntp/html/index.html --- src/contrib/ntp/html/index.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/index.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,101 +0,0 @@ - - - - - - - - The Network Time Protocol (NTP) Distribution - - - - -

    The Network Time Protocol (NTP) Distribution

    - gifP.T. Bridgeport Bear; from Pogo, Walt Kelly -

    Pleased to meet you.

    -

    Last update: 18:39 UTC Thursday, July 28, 2005

    -
    -

    Related Links

    - -
    -

    Table of Contents

    - -
    -

    Introduction

    -

    Note: The software contained in this distribution is available without charge under the conditions set forth in the Copyright Notice.

    -

    The Network Time Protocol (NTP) is used to synchronize the time of a computer client or server to another server or reference time source, such as a radio or satellite receiver or modem. It provides accuracies typically within a millisecond on LANs and up to a few tens of milliseconds on WANs relative to Coordinated Universal Time (UTC) via a Global Positioning Service (GPS) receiver, for example. Typical NTP configurations utilize multiple redundant servers and diverse network paths in order to achieve high accuracy and reliability.

    -

    This software release implements NTP Version 4 (NTPv4), but is in general backwards compatible with previous versions except NTP Version 1, support for which is no longer viable. NTPv4 includes support for both symmetric key and public key cryptography to prevent accidental or malicious protocol attacks, as well as automatic server discovery using IP multicast means. This release includes full support for the IPv6 address family, where the operating system supports it, as well as the default IPv4 address family. Either or both families can be used at the same time on the same machine.

    -

    Background information on computer network time synchronization can be found on the Executive Summary - Computer Network Time Synchronization page. Discussion on protocol conformance issues and interoperability with previous NTP versions can be found on the Protocol Conformance Statement page. Discussion on how NTP reckons the time can be found on the NTP Timescale and Leap Seconds page. Background information, bibliography and briefing slides suitable for presentations can be found on the Network Time Synchronization Project page. Additional information can be found at the NTP web site www.ntp.org. Please send bug reports to <bugs@mail.ntp.org>.

    -

    Building and Installing NTP

    -

    NTP supports Unix and Windows (XP, NT4 and 2000) systems. The Building and Installing the Distribution page presents an overview of the procedures for compiling the distribution and installing it on a typical client or server. The build procedures inspect the system hardware and software environment and automatically select the appropriate options for that environment. While these procedures work with most computers and operating systems marketed today, exceptions requiring manual intervention do exist, as documented on the Configuration Options and Release Notes pages.

    -

    Bringing up a NTP primary server requires a radio or satellite receiver or modem. The distribution includes hardware drivers for some forty radio and satellite clocks and modem services. A list of supported drivers is given on the Reference Clock Drivers page. It is also possible to use an otherwise undisciplined machine as a primary or backup server, as described on the Undisciplined Local Clock page. For most popular workstations marketed by Sun, Silicon Graphics and Hewlett Packard, as well as widely available Unix clones such as FreeBSD and Linux, the automatic build procedures select all drivers that run on the target machine. While this increases the size of the executable binary somewhat, individual drivers can be included or excluded using the configure utility documented in the Configuration Options page.

    -

    Some programs included in this distribution use cryptographic algorithms to verify authenticity and credentials. Where local security policy permits relatively weak symmetric key cryptography, the required software is included in this distribution. However, where local policy requires stronger public key cryptography, additional software not in this distribution is required. This distribution uses the OpenSSL library available from http://www.openssl.org. This library is also used by the Secure Shell facility, so is often already installed on Unix workstations and servers. It includes support for most message digest and digital signature algorithms used in the industry, as well as X.509 certificate generation, signing and verification.

    -

    While public key cryptography is optional but highly recommended for all NTP operations, it is required for the NTPv4 Autokey protocol described on the Autonomous Authentication page and is an integral component of the generic automatic configuration scheme described on the Autonomous Configuration page. In addition, access can be restricted in various ways described on the Access Control Options page.

    -

    Configuring Clients and Servers

    -

    NTP is by its very nature a complex distributed network application and can be configured and used for a great many widely divergent timekeeping scenarios. The documentation presented on these pages attempts to cover the entire suite of configuration, operation and maintenance facilities which this distribution supports. However, most applications will need only a few of these facilities. If this is the case, the Quick Start page may be useful to get a simple workstation on the air with an existing server.

    -

    However, in order to participate in the existing NTP synchronization subnet and obtain accurate, reliable time, it is usually necessary to construct an appropriate configuration file, commonly called ntp.conf, which establishes the servers and/or external receivers or modems to be used by this particular machine. Directions for constructing this file are in the Notes on Configuring NTP and Setting up a NTP Subnet page. However, in many common cases involving simple network topologies and workstations, the configuration data can be specified entirely on the command line for the ntpd - Network Time Protocol (NTP) daemon.

    -

    The most important factor in providing accurate, reliable time is the selection of modes and servers to be used in the configuration file. A discussion on the available modes is on the Association Management page. NTP support for one or more computers is normally engineered as part of the existing public NTP synchronization subnet. The public subnet consists of a multiply redundant hierarchy of servers and clients, with each level in the hierarchy identified by stratum number. Primary servers operate at stratum one and provide synchronization to secondary servers operating at stratum two and so on to higher strata. In this hierarchy, clients are simply servers that have no dependents.

    -

    Configuring a corporate or campus NTP subnet can be an engineering challenge. NTP contains many features designed to survive system and network failures, software bugs, clock errors and hacker attacks. Surviving these hazards requires intricate design of the timekeeping network using good principles of server redundancy and path diversity. The Manycast mode, new to NTPv4, is designed to track the current server and network states and adjust the client/server configuration for the best available accuracy and reliability. More information on the Manycast mode is on the Athentication Options and Automatic NTP Configuration Options pages.

    -

    The NTP subnet in early 2003 includes well over a hundred public primary (stratum 1) servers synchronized directly to UTC by radio, satellite or modem and located in every continent of the globe, including Antarctica. Normally, client workstations and servers with a relatively small number of clients do not synchronize to primary servers. There are well over a hundred public secondary (stratum 2) servers synchronized to the primary servers and providing synchronization to a total well over 100,000 clients and servers in the Internet. The current lists are maintained on the Information on Time and Frequency Services page, which is updated frequently. There are thousands upon thousands of private primary and secondary servers not normally available to the public, many hiding behind firewalls. Clients are strongly discouraged against using these servers, since they sometimes hide in little ghettos behind dinky links to the outside world and unwanted traffic can bring up expensive ISDN lines, causing much grief and frustration. There are defensive means described on the Access Control Options page, including the Kiss-of-Death packet.

    -

    Resolving Problems

    -

    Like other things Internet, the NTP synchronization subnets tend to be large and devilishly intricate, with many opportunities for misconfiguration and network problems. The NTP engineering model is specifically designed to help isolate and repair such problems using an integrated management protocol, together with a suite of monitoring and debugging tools. There is an optional statistics data recording facility which can be used to record normal and aberrant operation, log problems to the system log facility, and retain records of client access. The NTP Debugging Techniques and Hints and Kinks pages contain useful information for identifying problems and devising solutions. In extreme cases, problems can be detected through the use of the ntpdsim - Network Time Protocol (NTP) simulator included in this software distribution.

    -

    Users are requested to report bugs, offer suggestions and contribute additions to this distribution. The Patching Procedures page suggests procedures which greatly simplify distribution updates, while the Porting Hints page suggest ways to make porting this code to new hardware and operating systems easier. Additional information on reference clock driver construction and debugging can be found in the Debugging Hints for Reference Clock Drivers page.

    -

    Program Manual Pages

    - -

    Supporting Documentation

    - -

    Background Information

    - -

    Application Notes

    - -
    -
    - gif
    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/kern.html src.ntp/contrib/ntp/html/kern.html --- src/contrib/ntp/html/kern.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/kern.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,34 +0,0 @@ - - - - - - - - Kernel Model for Precision Timekeeping - - - - -

    Kernel Model for Precision Timekeeping

    -

    gif from Pogo, Walt Kelly

    -

    Alice touched the kernel and it exploded.

    -

    Last update: 18:40 UTC Thursday, July 28, 2005

    -
    -

    Related Links

    - -
    -

    The technical report [2], which is a major revision and update of RFC-1589 [3], describes an engineering model for a precision time-of-day function for a generic operating system. The model is based on the principles of disciplined oscillators using phase-lock loops (PLL) and frequency-lock loops (FLL) often found in the engineering literature. The model uses a hybrid PLL/FLL discipline algorithm implemented in the kernel. The algorithm, which is very similar to the algorithm implemented in the NTP daemon, provides automatic time and frequency steering with update intervals from a few seconds to tens of minutes.

    -

    The hybrid PLL/FLL code described in [2] is included in Solaris and Digital/Compaq/HP Tru64. It includes two system calls ntp_gettime() and ntp_adjtime() and can discipline the system clock with microsecond resolution. However, newer hardware and kernels with the same system calls can discipline the clock with nanosecond resolution. The new code described in [1] is available for Linux, FreeBSD, SunOS and Tru64; however, only the Linux and FreeBSD implementations, which do not include licensed code, are readily available. The software and documentation, including a simulator used to verify correct behavior, but not involving licensed code, is available at nanokernel.tar.gz.

    -

    The model also changes the way the system clock is adjusted in time and frequency relative to an external precision timing source, such as described in the Pulse-per-second (PPS) Signal Interfacing page. The NTP software daemon uses the PPS to provide synchronization limited in principle only by the accuracy and stability of the external timing source.

    -

    References

    -
      -
    1. Mills, D.L., and P.-H. Kamp. The nanokernel. Proc. Precision Time and Time Interval (PTTI) Applications and Planning Meeting (Reston VA, November 2000). Paper: PostScript | PDF, Slides: HTML | PostScript | PDF | PowerPoint -
    2. Mills, D.L. Unix kernel modifications for precision time synchronization. Electrical Engineering Department Report 94-10-1, University of Delaware, October 1994, 24 pp. Abstract: PostScript | PDF, Body: PostScript | PDF -
    3. Mills, D.L. A kernel model for precision timekeeping. Network Working Group Report RFC-1589, University of Delaware, March 1994. 31 pp. ASCII -
    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/keygen.html src.ntp/contrib/ntp/html/keygen.html --- src/contrib/ntp/html/keygen.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/keygen.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,116 +0,0 @@ - - - - - - - - ntp-keygen - generate public and private keys - - - - -

    ntp-keygen - generate public and private keys

    - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

    Alice holds the key.

    -

    Last update: 22:32 UTC Monday, November 07, 2005

    -
    -

    Related Links

    - -

    Table of Contents

    - -
    -

    Synopsis

    -

    ntp-keygen [ -deGgHIMnPT ] [ -c [RSA-MD2 | RSA-MD5 | RSA-SHA | RSA-SHA1 | RSA-MDC2 | RSA-RIPEMD160 | DSA-SHA | DSA-SHA1 ] ] [ -i name ] [ -p password ] [ -S [ RSA | DSA ] ] [ -s name ] [ -v nkeys ]

    -

    Description

    -

    This program generates cryptographic data files used by the NTPv4 authentication and identification schemes. It generates MD5 key files used in symmetric key cryptography. In addition, if the OpenSSL software library has been installed, it generates keys, certificate and identity files used in public key cryptography. These files are used for cookie encryption, digital signature and challenge/response identification algorithms compatible with the Internet standard security infrastructure.

    -

    By default, files are not encrypted by ntp-keygen. The -p password option specifies the write password and -q password option the read password for previously encrypted files. The ntp-keygen program prompts for the password if it reads an encrypted file and the password is missing or incorrect. If an encrypted file is read successfully and no write password is specified, the read password is used as the write password by default.

    -

    The ntpd configuration command crypto pw password specifies the read password for previously encrypted files. The daemon expires on the spot if the password is missing or incorrect. For convenience, if a file has been previously encrypted, the default read password is the name of the host running the program. If the previous write password is specified as the host name, these files can be read by that host with no explicit password.

    -

    All files are in PEM-encoded printable ASCII format, so they can be embedded as MIME attachments in mail to other sites and certificate authorities. File names begin with the prefix ntpkey_ and end with the postfix _hostname.filestamp, where hostname is usually the string returned by the Unix gethostname() routine, and filestamp is the NTP seconds when the file was generated, in decimal digits. This both guarantees uniqueness and simplifies maintenance procedures, since all files can be quickly removed by a rm ntpkey* command or all files generated at a specific time can be removed by a rm *filestamp command. To further reduce the risk of misconfiguration, the first two lines of a file contain the file name and generation date and time as comments.

    -

    All files are installed by default in the keys directory /usr/local/etc, which is normally in a shared filesystem in NFS-mounted networks. The actual location of the keys directory and each file can be overridden by configuration commands, but this is not recommended. Normally, the files for each host are generated by that host and used only by that host, although exceptions exist as noted later on this page.

    -

    Normally, files containing private values, including the host key, sign key and identification parameters, are permitted root read/write-only; while others containing public values are permitted world readable. Alternatively, files containing private values can be encrypted and these files permitted world readable, which simplifies maintenance in shared file systems. Since uniqueness is insured by the hostname and file name extensions, the files for a NFS server and dependent clients can all be installed in the same shared directory.

    -

    The recommended practice is to keep the file name extensions when installing a file and to install a soft link from the generic names specified elsewhere on this page to the generated files. This allows new file generations to be activated simply by changing the link. If a link is present, ntpd follows it to the file name to extract the filestamp. If a link is not present, ntpd extracts the filestamp from the file itself. This allows clients to verify that the file and generation times are always current. The ntp-keygen program uses the same extension for all files generated at one time, so each generation is distinct and can be readily recognized in monitoring data.

    -

    Running the program

    -

    The safest way to run the ntp-keygen program is logged in directly as root. The recommended procedure is change to the keys directory, usually /ust/local/etc, then run the program. When run for the first time, or if all ntpkey files have been removed, the program generates a RSA host key file and matching RSA-MD5 certificate file, which is all that is necessary in many cases. The program also generates soft links from the generic names to the respective files. If run again, the program uses the same host key file, but generates a new certificate file and link.

    -

    The host key is used to encrypt the cookie when required and so must be RSA type. By default, the host key is also the sign key used to encrypt signatures. When necessary, a different sign key can be specified and this can be either RSA or DSA type. By default, the message digest type is MD5, but any combination of sign key type and message digest type supported by the OpenSSL library can be specified, including those using the MD2, MD5, SHA, SHA1, MDC2 and RIPE160 message digest algorithms. However, the scheme specified in the certificate must be compatible with the sign key. Certificates using any digest algorithm are compatible with RSA sign keys; however, only SHA and SHA1 certificates are compatible with DSA sign keys.

    -

    Private/public key files and certificates are compatible with other OpenSSL applications and very likely other libraries as well. Certificates or certificate requests derived from them should be compatible with extant industry practice, although some users might find the interpretation of X509v3 extension fields somewhat liberal. However, the identification parameter files, although encoded as the other files, are probably not compatible with anything other than Autokey.

    -

    Running the program as other than root and using the Unix su command to assume root may not work properly, since by default the OpenSSL library looks for the random seed file .rnd in the user home directory. However, there should be only one .rnd, most conveniently in the root directory, so it is convenient to define the $RANDFILE environment variable used by the OpenSSL library as the path to /.rnd.

    -

    Installing the keys as root might not work in NFS-mounted shared file systems, as NFS clients may not be able to write to the shared keys directory, even as root. In this case, NFS clients can specify the files in another directory such as /etc using the keysdir command. There is no need for one client to read the keys and certificates of other clients or servers, as these data are obtained automatically by the Autokey protocol.

    -

    Ordinarily, cryptographic files are generated by the host that uses them, but it is possible for a trusted agent (TA) to generate these files for other hosts; however, in such cases files should always be encrypted. The subject name and trusted name default to the hostname of the host generating the files, but can be changed by command line options. It is convenient to designate the owner name and trusted name as the subject and issuer fields, respectively, of the certificate. The owner name is also used for the host and sign key files, while the trusted name is used for the identity files.

    -

    Trusted Hosts and Groups

    -

    Each cryptographic configuration involves selection of a signature scheme and identification scheme, called a cryptotype, as explained in the Authentication Options page. The default cryptotype uses RSA encryption, MD5 message digest and TC identification. First, configure a NTP subnet including one or more low-stratum trusted hosts from which all other hosts derive synchronization directly or indirectly. Trusted hosts have trusted certificates; all other hosts have nontrusted certificates. These hosts will automatically and dynamically build authoritative certificate trails to one or more trusted hosts. A trusted group is the set of all hosts that have, directly or indirectly, a certificate trail ending at a trusted host. The trail is defined by static configuration file entries or dynamic means described on the Automatic NTP Configuration Options page.

    -

    On each trusted host as root, change to the keys directory. To insure a fresh fileset, remove all ntpkey files. Then run ntp-keygen -T to generate keys and a trusted certificate. On all other hosts do the same, but leave off the -T flag to generate keys and nontrusted certificates. When complete, start the NTP daemons beginning at the lowest stratum and working up the tree. It may take some time for Autokey to instantiate the certificate trails throughout the subnet, but setting up the environment is completely automatic.

    -

    If it is necessary to use a different sign key or different digest/signature scheme than the default, run ntp-keygen with the -S type option, where type is either RSA or DSA. The most often need to do this is when a DSA-signed certificate is used. If it is necessary to use a different certificate scheme than the default, run ntp-keygen with the -c scheme option and selected scheme as needed. If ntp-keygen is run again without these options, it generates a new certificate using the same scheme and sign key.

    -

    After setting up the environment it is advisable to update certificates from time to time, if only to extend the validity interval. Simply run ntp-keygen with the same flags as before to generate new certificates using existing keys. However, if the host or sign key is changed, ntpd should be restarted. When ntpd is restarted, it loads any new files and restarts the protocol. Other dependent hosts will continue as usual until signatures are refreshed, at which time the protocol is restarted.

    -

    Identity Schemes

    -

    As mentioned on the Autonomous Authentication page, the default TC identity scheme is vulnerable to a middleman attack. However, there are more secure identity schemes available, including PC, IFF, GQ and MV described on the Identification Schemes page. These schemes are based on a TA, one or more trusted hosts and some number of nontrusted hosts. Trusted hosts prove identity using values provided by the TA, while the remaining hosts prove identity using values provided by a trusted host and certificate trails that end on that host. The name of a trusted host is also the name of its sugroup and also the subject and issuer name on its trusted certificate. The TA is not necessarily a trusted host in this sense, but often is.

    -

    In some schemes there are separate keys for servers and clients. A server can also be a client of another server, but a client can never be a server for another client. In general, trusted hosts and nontrusted hosts that operate as both server and client have parameter files that contain both server and client keys. Hosts that operate only as clients have key files that contain only client keys.

    -

    The PC scheme supports only one trusted host in the group. On trusted host alice run ntp-keygen -P -p password to generate the host key file ntpkey_RSAkey_alice.filestamp and trusted private certificate file ntpkey_RSA-MD5_cert_alice.filestamp. Copy both files to all group hosts; they replace the files which would be generated in other schemes. On each host bob install a soft link from the generic name ntpkey_host_bob to the host key file and soft link ntpkey_cert_bob to the private certificate file. Note the generic links are on bob, but point to files generated by trusted host alice. In this scheme it is not possible to refresh either the keys or certificates without copying them to all other hosts in the group.

    -

    For the IFF scheme proceed as in the TC scheme to generate keys and certificates for all group hosts, then for every trusted host in the group, generate the IFF parameter file. On trusted host alice run ntp-keygen -T -I -p password to produce her parameter file ntpkey_IFFpar_alice.filestamp, which includes both server and client keys. Copy this file to all group hosts that operate as both servers and clients and install a soft link from the generic ntpkey_iff_alice to this file. If there are no hosts restricted to operate only as clients, there is nothing further to do. As the IFF scheme is independent of keys and certificates, these files can be refreshed as needed.

    -

    If a rogue client has the parameter file, it could masquerade as a legitimate server and present a middleman threat. To eliminate this threat, the client keys can be extracted from the parameter file and distributed to all restricted clients. After generating the parameter file, on alice run ntp-keygen -e and pipe the output to a file or mail program. Copy or mail this file to all restricted clients. On these clients install a soft link from the generic ntpkey_iff_alice to this file. To further protect the integrity of the keys, each file can be encrypted with a secret password.

    -

    For the GQ scheme proceed as in the TC scheme to generate keys and certificates for all group hosts, then for every trusted host in the group, generate the IFF parameter file. On trusted host alice run ntp-keygen -T -G -p password to produce her parameter file ntpkey_GQpar_alice.filestamp, which includes both server and client keys. Copy this file to all group hosts and install a soft link from the generic ntpkey_gq_alice to this file. In addition, on each host bob install a soft link from generic ntpkey_gq_bob to this file. As the GQ scheme updates the GQ parameters file and certificate at the same time, keys and certificates can be regenerated as needed.

    -

    For the MV scheme, proceed as in the TC scheme to generate keys and certificates for all group hosts. For illustration assume trish is the TA, alice one of several trusted hosts and bob one of her clients. On TA trish run ntp-keygen -V n -p password, where n is the number of revokable keys (typically 5) to produce the parameter file ntpkeys_MVpar_trish.filestamp and client key files ntpkeys_MVkeyd_trish.filestamp where d is the key number (0 < d < n). Copy the parameter file to alice and install a soft link from the generic ntpkey_mv_alice to this file. Copy one of the client key files to alice for later distribution to her clients. It doesn't matter which client key file goes to alice, since they all work the same way. Alice copies the client key file to all of her cliens. On client bob install a soft link from generic ntpkey_mvkey_bob to the client key file. As the MV scheme is independent of keys and certificates, these files can be refreshed as needed.

    -

    Command Line Options

    -
    -
    -c [ RSA-MD2 | RSA-MD5 | RSA-SHA | RSA-SHA1 | RSA-MDC2 | RSA-RIPEMD160 | DSA-SHA | DSA-SHA1 ] -
    Select certificate message digest/signature encryption scheme. Note that RSA schemes must be used with a RSA sign key and DSA schemes must be used with a DSA sign key. The default without this option is RSA-MD5. -
    -d -
    Enable debugging. This option displays the cryptographic data produced in eye-friendly billboards. -
    -e -
    Write the IFF client keys to the standard output. This is intended for automatic key distribution by mail. -
    -G -
    Generate parameters and keys for the GQ identification scheme, obsoleting any that may exist. -
    -g -
    Generate keys for the GQ identification scheme using the existing GQ parameters. If the GQ parameters do not yet exist, create them first. -
    -H -
    Generate new host keys, obsoleting any that may exist. -
    -I -
    Generate parameters for the IFF identification scheme, obsoleting any that may exist. -
    -i name -
    Set the suject name to name. This is used as the subject field in certificates and in the file name for host and sign keys. -
    -M -
    Generate MD5 keys, obsoleting any that may exist. -
    -P -
    Generate a private certificate. By default, the program generates public certificates. -
    -p password -
    Encrypt generated files containing private data with password and the DES-CBC algorithm. -
    -q -
    Set the password for reading files to password. -
    -S [ RSA | DSA ] -
    Generate a new sign key of the designated type, obsoleting any that may exist. By default, the program uses the host key as the sign key. -
    -s name -
    Set the issuer name to name. This is used for the issuer field in certificates and in the file name for identity files. -
    -T -
    Generate a trusted certificate. By default, the program generates a non-trusted certificate. -
    -V nkeys -
    Generate parameters and keys for the Mu-Varadharajan (MV) identification scheme. -
    -

    Random Seed File

    -

    All cryptographically sound key generation schemes must have means to randomize the entropy seed used to initialize the internal pseudo-random number generator used by the library routines. The OpenSSL library uses a designated random seed file for this purpose. The file must be available when starting the NTP daemon and ntp-keygen program. If a site supports OpenSSL or its companion OpenSSH, it is very likely that means to do this are already available.

    -

    It is important to understand that entropy must be evolved for each generation, for otherwise the random number sequence would be predictable. Various means dependent on external events, such as keystroke intervals, can be used to do this and some systems have built-in entropy sources. Suitable means are described in the OpenSSL software documentation, but are outside the scope of this page.

    -

    The entropy seed used by the OpenSSL library is contained in a file, usually called .rnd, which must be available when starting the NTP daemon or the ntp-keygen program. The NTP daemon will first look for the file using the path specified by the randfile subcommand of the crypto configuration command. If not specified in this way, or when starting the ntp-keygen program, the OpenSSL library will look for the file using the path specified by the RANDFILE environment variable in the user home directory, whether root or some other user. If the RANDFILE environment variable is not present, the library will look for the .rnd file in the user home directory. If the file is not available or cannot be written, the daemon exits with a message to the system log and the program exits with a suitable error message.

    -

    Cryptographic Data Files

    -

    All other file formats begin with two lines. The first contains the file name, including the generated host name and filestamp. The second contains the datestamp in conventional Unix date format. Lines beginning with # are considered comments and ignored by the ntp-keygen program and ntpd daemon. Cryptographic values are encoded first using ASN.1 rules, then encrypted if necessary, and finally written PEM-encoded printable ASCII format preceded and followed by MIME content identifier lines.

    -

    The format of the symmetric keys file is somewhat different than the other files in the interest of backward compatibility. Since DES-CBC is deprecated in NTPv4, the only key format of interest is MD5 alphanumeric strings. Following hte heard the keys are entered one per line in the format

    -

    keyno type key

    -

    where keyno is a positive integer in the range 1-65,535, type is the string MD5 defining the key format and key is the key itself, which is a printable ASCII string 16 characters or less in length. Each character is chosen from the 93 printable characters in the range 0x21 through 0x7f excluding space and the '#' character.

    -

    Note that the keys used by the ntpq and ntpdc programs are checked against passwords requested by the programs and entered by hand, so it is generally appropriate to specify these keys in human readable ASCII format.

    -

    The ntp-keygen program generates a MD5 symmetric keys file ntpkey_MD5key_hostname.filestamp. Since the file contains private shared keys, it should be visible only to root and distributed by secure means to other subnet hosts. The NTP daemon loads the file ntp.keys, so ntp-keygen installs a soft link from this name to the generated file. Subsequently, similar soft links must be installed by manual or automated means on the other subnet hosts. While this file is not used with the Autokey Version 2 protocol, it is needed to authenticate some remote configuration commands used by the ntpq and ntpdc utilities.

    -

    Bugs

    -

    It can take quite a while to generate some cryptographic values, from one to several minutes with modern architectures such as UltraSPARC and up to tens of minutes to an hour with older architectures such as SPARC IPC.

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/ldisc.html src.ntp/contrib/ntp/html/ldisc.html --- src/contrib/ntp/html/ldisc.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/ldisc.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,47 +0,0 @@ - - - - - - - Line Disciplines and Streams Modules - - - - -

    Line Disciplines and Streams Modules

    -

    Last update: 18:40 UTC Thursday, July 28, 2005

    -

    Related Links

    - -
    -

    Description

    -

    Most radio and modem clocks used for a primary (stratum-1) NTP server utilize serial ports operating at speeds of 9600 baud or greater. The intrinsic delay and jitter contributed by the serial port hardware and software driver can accumulate up to a millisecond in newer Unix systems and tens of milliseconds in older ones. In order to reduce the effects of delay and jitter, a set of special line disciplines, stream modules and operating system calls (ioctls) can be configured in some Unix kernels. These routines intercept special characters or signals provided by the radio or modem clock and save a timestamp for later processing.

    -

    The routines provide two important functions. Some insert a timestamp in the receive data stream upon occurance of a designated character or characters at the serial interface. This can be used to timestamp an on-time character produced by a radio clock, for example. Other routines support an application program interface for pulse-per-second (PPS) signals generated by some radio clocks and laboratory instruments. These routines are normally accessed through the PPSAPI application program interface described below.

    -

    The routines can be compiled in the kernel in older BSD-derived systems, or installed as System V streams modules and either compiled in the kernel or dynamically loaded when required. In either case, they require minor changes in some kernel files and in the NTP daemon ntpd. The streams modules can be pushed and popped from the streams stack using conventional System V streams program primitives. Note that some Unix kernels do not support line disciplines and some do not support System V streams. The routines described here are known to work correctly with the Unix kernels called out in the descriptions, but have not been tested for other kernels.

    -

    tty_clk Line Discipline/Streams Module

    -

    This routine intercepts characters received from the serial port and passes unchanged all except a set of designated characters to the generic serial port discipline. For each of the exception characters, the character is inserted in the receiver buffer followed by a local timestamp in Unix timeval format. Both select() and SIGIO are supported by the routine. Support for this routine is automatically detected during the NTP build process and interface code compiled as necessary.

    -

    There are two versions of the tty_clk routine. The tty_clk.c line discipline is designed for older BSD systems and is compiled in the kernel. The tty_clk_STREAMS.c is designed for System V streams, in which case it can be either compiled in the kernel or dynamically loaded. Since these programs are small, unobtrusive, and do nothing unless specifically enabled by an application program, it probably doesn't matter which version is chosen. Instructions on how to configure and build a kernel supporting either of these routines is in the README file in the ./kernel directory.

    -

    The tty_clk routine defines a new ioctl CLK_SETSTR, which takes a pointer to a string of no more than 32 characters. Until the first CLK_SETSTR is performed, the routine will simply pass through characters. Once it is passed a string by CLK_SETSTR, any character in that string will be immediately followed by a timestamp in Unix timeval format. You can change the string whenever you want by doing another CLK_SETSTR. The character must be an exact, 8 bit match. The character '\000' cannot, be used, as it is the string terminator. Passing an empty string to CLK_SETSTR turns off timestamping. Passing NULL may produce surprising results.

    -

    TIOCDCDTIMESTAMP ioctl in FreeBSD

    -

    This ioctl is included in FreeBSD 2.2 and later. It causes a timestamp to be inserted in the serial port receive data stream when the data carrier detect (DCD) signal is asserted. This is useful for those radio clocks that indicate the on-time epoch by means of a modem control signal. It is not recommended that this be used for PPS timestamps, as this function is available using the PPS application program interface included in FreeBSD 3.4 and later.

    -

    The TIOCDCDTIMESTAMP ioctl() is detected and compiled automatically on FreeBSD systems if available. With FreeBSD 2.2 the measured delay between activation of the DCD signal and the time the timestamp is captured on a 66MHz 486DX2 is 19 ms and on a 100MHz Pentium is 6 ms.

    -

    ppsclockStreams Module (depredated)

    -

    This routine is a streams module which causes a timestamp to be captured when the DCD signal is asserted. It is normally used in connection with a PPS signal generated by some radio clocks. However, it is normally used only by the PPSAPI interface and SunOS 4.1.3 and should be avoided in other contexts. Instructions on how to configure and build a kernel supporting either of these routines is in the README file in the ./kernel directory.

    -

    The ppsclock streams module implements the CIOGETEV ioctl, which takes a pointer to the structure

    -
    -struct ppsclockev {
    -     struct timeval tv;
    -     u_int serial;
    -};
    -
    -

    The ppsclock module is pushed on the streams stack of the serial port connected to the DCD line. At each positive-going edge of the PPS signal, the routine latches the current local timestamp and increments a counter. At each CIOGETEV ioctl call, the current values of the timestamp and counter are returned in the ppsclockev structure.

    -

    TIOCSPPS and TIOCGETPPSEV ioctls in Solaris

    -

    These ioctls are included in Solaris 2.4 and later. They implement the same function as the ppsclock streams module, but are implemented as integrated system calls independent of the streams facility. They are normally used in connection with a pulse-per-second (PPS) signal generated by some radio clocks. However, these ioctls are normally used only by the PPSAPI interface and should be avoided in other contexts. See the Sun documentation for the calling sequence and return values.

    -

    Users are cautioned that these ioctls function improperly in Solaris versions prior to 2.8 with patch Generic_108528-02.

    -

    tty_chu Line Discipline/Streams Module (depredated)

    -

    This routine is a special purpose line discipline for receiving a special timecode broadcast by Canadian time and frequency standard station CHU. It has been removed from the distribution since its function has been replaced by the Radio CHU Audio Demodulator/Decoder (type 7) clock driver.

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/manyopt.html src.ntp/contrib/ntp/html/manyopt.html --- src/contrib/ntp/html/manyopt.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/manyopt.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,83 +0,0 @@ - - - - - - - - Automatic NTP Configuration Options - - - - -

    Automatic NTP Configuration Options

    - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

    Make sure who your friends are.

    -

    Last update: 20:55 UTC Tuesday, October 11, 2005

    -
    -

    Related Links

    - -

    Table of Contents

    - -
    -

    Broadcasting

    -

    Broadcasting is the simplest way to provide automatic server discovery. It uses the multi-destination paradigm, where the subnet spanning tree is constructed automatically, either by the switches in an Ethernet LAN or the DVMRP or PIM protocols when spanning multiple networks.

    -

    A broadcast or multicast server is mobilized by the broadcast configuration command. The addresses can be either from the IPv4 broadcast/mulitcast address family or the IPv6 address family. Multiple broadcast server associations can be specified for a single host.

    -

    A host is enabled for broadcast reception using the broadcastclient configuration command, with or without the novolley option. Upon receiving the first message from a broadcast server, the client mobilizes an ephemeral client association and exchanges a volley of client/server messages in order to quickly authenticate the source, set the clock and measure the propagation delay, then reverts to listen-only mode. A multicast client is mobilized in the same way using the multicastclient configuration command and specified multicast group address.

    -

    Broadcasting can be used with either symmetric key or public key cryptography. Public key cryptography offers the best protection against compromised keys and is generally considered stronger. By default, either of these two means is required, but this can be overridden by the disable auth command.

    -

    In both broadcast and multicast client operations the client association is demobilized in case of error or timeout due to loss of server or connectivity.

    -

    Manycasting

    -

    Manycasting is a automatic discovery and configuration paradigm new to NTPv4. It is intended as a means for a client to troll the nearby network neighborhood to find cooperating servers, validate them using cryptographic means and evaluate their time values with respect to other servers that might be lurking in the vicinity. The intended result is that each client mobilizes associations with a given number of the "best" nearby servers, yet automatically reconfigures to sustain this number of servers should one or another fail.

    -

    Note that the manycast paradigm does not coincide with the anycast paradigm described in RFC-1546, which is designed to find a single server from a clique of servers providing the same service. The manycast paradigm is designed to find a plurality of redundant servers satisfying defined optimality criteria.

    -

    Manycasting can be used with either symmetric key or public key cryptography. Public key cryptography offers the best protection against compromised keys and is generally considered stronger. By default, either of these two means is required, but this can be overridden by the disable auth command.

    -

    A manycast client association is configured using the manycastclient configuration command, which is similar to the server configuration command, but with a broadcast or multicast address. Depending on address family. The manycast client sends ordinary client mode messages, but with a broadcast address rather than a unicast address. It sends only if less than a given threshold of servers have been found and then only at the minimum feasible rate and minimum feasible time-to-live (TTL) hops. There can be as many manycast client associations as different broadcast addresses, each one serving as a template for a future unicast client/server association.

    -

    Manycast servers configured with the manycastserver command listen on the specified broadcast address for manycast client messages. If a manycast server is in scope of the current TTL and is itself synchronized to a valid source and operating at a stratum level equal to or lower than the manycast client, it replies to the manycast client message with an ordinary unicast server message.

    -

    The manycast client receiving this message mobilizes a preemptable client association according to the matching manycast client template, but only if cryptographically authenticated and the server stratum is less than or equal to the client stratum. The client runs the NTP mitigation algorithms, which act to demobilize all but a threshold number of associations according to stratum and synchronization distance. The surviving associations then continue in ordinary client/server mode.

    -

    If for some reason the number of available servers falls below the threshold, the manycast client resumes sending broadcast messages. The polling strategy is designed to reduce as much as possible the volume of broadcast messages and the effects of implosion due to near-simultaneous arrival of manycast server messages. The strategy is determined by the tos and ttl configuration commands described below.

    -

    It is possible and frequently useful to configure a host as both manycast client and manycast server. A number of hosts configured this way and sharing a common group address will automatically organize themselves in an optimum configuration based on stratum and synchronization distance.

    -

    For example, consider an NTP subnet of two primary servers and several secondary servers and a number of dependent clients. With twoAll servers and clients have identical configuration files including both multicastclient and multicastserver commands using, for instance, multicast group address 239.1.1.1. Each primary server configuration file must include commands for the primary reference source such as a GPS receiver.

    -

    The remaining configuration files for all secondary servers and clients have the same contents, except for the tos command, which is specific for each stratum level. For stratum 1 and stratum 2 servers, that command is not necessary. For stratum 3 and above servers the tos floor value is set to the intended stratum number. Thus, all stratum 3 configuration files use tos floor 3, all stratum 4 files use tos floor 4 and so forth.

    -

    Once operations have stabilized, the primary servers will find the primary reference source and each other, since they both operate at the same stratum (1), but not with any secondary server or client, since these operate at a higher stratum. The secondary servers will find the servers at the same stratum level. If one of the primary servers loses its GPS receiver, it will continue to operate as a client and other clients will time out the corresponding association and re-associate accordingly.

    -

    Orphan Mode

    -

    Sometimes it is necessary to operate an NTP subnet in isolation, because a local reference clock is unavailable or connectivity to the Internet is not provided. In such cases it may be necessary that the subnet servers and clients remain synchronized to a common timescale, not necessarily the UTC timescale. Previously, this function was provided by the local clock driver, which could be configured for a server that could be reached, directly or indirectly from all other servers and clients in the subnet.

    -

    There are many disadvantages using the local clock driver: multiple source redundancy is not possible and the subnet is vulnerable to single-point failures. Orphan mode is intended to replace the need for the local clock driver. It operates in subnet configurations in all modes, including broadcast, and multiple servers and clients and handles seamless switching as primary sources fail and recover.

    -

    A server or client is enabled for orphan mode using the tos orphan stratum command, where stratum is some stratum less than 16 and greater than any anticipated stratum that might occur with ordinary Internet servers. This is the same consideration that guides the local clock driver stratum.

    -

    As long as the stratum of any orphan is less than the orphan stratum, the servers and clients operate in the normal way. However, if the stratum equals or exceeds this stratum, the server or client is considered an orphan. If under these conditions a host has no sources of the same or lower stratum, it is designated an orphan parent; otherwise, it is considered an orphan child. Orphan parents show offset zero, root delay zero and reference ID 127.0.0.1, which of course is the Unix loopback address. Orphan children show the mitigated offset of their servers, root delay randomized over a moderate range and reference ID of their system peer. An important distinction is that the entire subnet operates at the same orphan stratum and that the order of preference is the root delay, not the stratum and root distance as usual.

    -

    For the most flexible and reliable operation, all servers and clients in the subnet should include the orphan command in the configuration file and with the same orphan stratum. This provides mutual redundancy and diversity for all NTP modes of operation, including broadcast.

    -

    For example, consider the case where several campus secondary (stratum 2) servers are configured for public Internet primary servers and with each other using symmetric modes. These servers provide synchronization with a number of department servers using broadcast mode, where each of these servers is configured as both a broadcast server and broadcast client. Individual workstations on the department LAN are configured as broadcast clients only. All servers (not necessarily the clients) have the orphan 5 command, for example.

    -

    In normal operation all servers and clients operate below stratum 5, so operate with the subnet configuration determined by stratum and root distance. If all sources are lost at any stratum level, the server or client continues operation as orphan parent. However, if sources at the orphan stratum are found, the host synchronizes to the source with lowest root delay. Since orphan root delay is determined randomly at startup, loops are avoided, even in broadcast modes where multiple servers are available.

    -

    Server Discovery Options

    -
    -
    tos [ ceiling ceiling | cohort {0 | 1} | floor floor | orphan orphan | maxdistance maxdistance | minclock minclock | minsane minsane ] -
    This command affects the clock selection and clustering algorithms. It can be used to select the quality and quantity of peers used to synchronize the system clock and is most useful in manycast mode. The variables operate as follows: -
    beacon beacon -
    The manycast server sends packets at intervals of 64 s if less than maxclock servers are available. Otherwise, it sends packets at the beacon interval in seconds. The default is 3600 s.
    ceiling ceiling -
    Servers with stratum at or above ceiling will be discarded if there are at least minclock peers remaining. This value defaults to 15, but can be changed to any number from 1 to 15. -
    cohort { 0 | 1 } -
    This is a binary flag which enables (0) or disables (1) manycast server replies to manycast clients with the same stratum level. This is useful to reduce implosions where large numbers of clients with the same stratum level are present. The default is to enable these replies. -
    floor floor -
    Peers with strata below floor will be discarded if there are at least minclock peers remaining. This value defaults to 1, but can be changed to any number from 1 to 15. -
    orphan stratum -
    If stratum is set at some value less than 16 a special orphan mode is enterred when no outside source of synchronization is available. To use orphan mode a number of participants are identically configured both as broadcast client and as broadcast server. One or more participants are configured to use an outside source, either a reference clock or another Internet server. When the source or sources fail, the system stratum is set at stratum and a leader is elected to serve as the reference source. When an outside source of synchronization is again available, the orphan mode is disabled.
    mindist mindistance -
    The slection algorithm normally pads each intersection a minimum of one millisecond to avoid needless classification. In some cases, such as reference clocks with high jitter and a PPS signal, it is useful to increase the padding. This command can be used for that purpose. As a general rule, set the mindistance to the maximum expected offset plus the maxiumum expected jitter, in seconds. -
    maxdist maxdistance -
    The selection algorithm accumulates a number of packets before setting the clock in order to use the best data available. The number is determined by the synchronization distance for each association and a limit called the distance threshold. The synchronization distance starts at 16, then drops by a factor of about two as each packet is received. The default distance threshold is 1.0, which usually results in four packets. Setting maxdistance to some value between 1 and 16 can be used to change the number of packets required. For instance, setting it to 16 will set the clock on the first packet received; howver, setting it to this value essentially disables the mitigation and grooming algorithms. -
    minclock minclock -
    The clustering algorithm repeatedly casts out outlyer associations until no more than minclock associations remain. This value defaults to 3, but can be changed to any number from 1 to the number of configured sources. -
    minsane minsane -
    This is the minimum number of candidates available to the clock selection algorithm in order to produce one or more truechimers for the clustering algorithm. If fewer than this number are available, the clock is undisciplined and allowed to run free. The default is 1 for legacy purposes. However, according to principles of Byzantine agreement, minsane should be at least 4 in order to detect and discard a single falseticker. -
    - -
    ttl hop ... -
    This command specifies a list of TTL values in increasing order. up to 8 values can be specified. In manycast mode these values are used in turn in an expanding-ring search. The default is eight multiples of 32 starting at 31. -
    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/measure.html src.ntp/contrib/ntp/html/measure.html --- src/contrib/ntp/html/measure.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/measure.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,23 +0,0 @@ - - - - - - - Time and Time Interval Measurement with Application to Computer and Network Performance Evaluation - - - - -

    Time and Time Interval Measurement with Application to Computer and Network Performance Evaluation

    -

    Last update: 18:41 UTC Thursday, July 28, 2005

    -
    -

    The technical memorandum: Time and Time Interval Measurement with Application to Computer and Network Performance Evaluation(PostScript) describes a number of techniques for conducting experiments typical of computer network and transmission systems engineering.

    -

    In most experiments in which time is involved, it is necessary to develop estimates of time, frequency and measurement errors from a series of time measurements between the clocks of a number of computers and ancillary devices interconnected by some kind of computer network. However, time is not a physical quantity, such as mass, nor can it be measured relative to an absolute frame of reference, such as velocity. The only way to measure time in our universe is to compare the reading of one clock, which runs according to its own timescale, with another clock, which runs according to a given timescale, at some given instant or epoch. The errors arise from the precision of time comparisons and the accuracy of frequency estimates between the timescales involved.

    -

    The usual data collected during a performance run of some experiment might include time offsets, time delays, frequency offsets and various error statistics. While time offsets between two clocks can be measured directly, frequency offsets can be estimated only from two or more time offsets made over some time interval in the experiment. In practice, a sequence of time comparisons can be performed over the lifetime of the experiment and the instantaneous frequency estimated either in real time with a recurrence relation, or retrospectively with a polynomial fit to the data.

    -

    Estimating time and frequency errors in real time has been studied by a distinct subspecies of physicists who have made a career of the technology involved. Various means including autoregressive models, Kalman filters and simple weighted-average algorithms are used extensively by national standards laboratories to model cesium-clock ensembles. These techniques have been adapted to computer network and transmission engineering problems as well. This memorandum explores issues in performing experiments of this type and summarizes various techniques found useful in practice.

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/miscopt.html src.ntp/contrib/ntp/html/miscopt.html --- src/contrib/ntp/html/miscopt.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/miscopt.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,123 +0,0 @@ - - - - - - - Miscellaneous Options - - - - -

    Miscellaneous Options

    - giffrom Pogo, Walt Kelly -

    We have three, now looking for more.

    -

    Last update: 18:50 UTC Monday, January 09, 2006

    -
    -

    Related Links

    - -
    -
    -
    broadcastdelay seconds -
    The broadcast and multicast modes require a special calibration to determine the network delay between the local and remote servers. Ordinarily, this is done automatically by the initial protocol exchanges between the client and server. In some cases, the calibration procedure may fail due to network or server access controls, for example. This command specifies the default delay to be used under these circumstances. Typically (for Ethernet), a number between 0.003 and 0.007 seconds is appropriate. The default when this command is not used is 0.004 seconds. -
    calldelay delay -
    This option controls the delay in seconds between the first and second packets sent in burst or iburst mode to allow additional time for a modem or ISDN call to complete. -
    driftfile driftfile [ - minutes [ tolerance ] ] -
    This command specifies the complete path and name of the file used to record the frequency of the local clock oscillator. This is the same operation as the -f command linke option. If the file exists, it is read at startup in order to set the initial frequency and then updated once per hour with the current frequency computed by the daemon. If the file name is specified, but the file itself does not exist, the starts with an initial frequency of zero and creates the file when writing it for the first time. If this command is not given, the daemon will always start with an initial frequency of zero. -

    The file format consists of a single line containing a single floating point number, which records the frequency offset measured in parts-per-million (PPM). The file is updated by first writing the current drift value into a temporary file and then renaming this file to replace the old version. This implies that ntpd must have write permission for the directory the drift file is located in, and that file system links, symbolic or otherwise, should be avoided.

    - -

    The two optional values determine how often the file is written, and -are particuarly useful when is it desirable to avoid spinning up the -disk unnecessarily. The parameter minutes is how often the file will be written. If omitted or less -than 1, the interval will be 60 minutes (one hour). The parameter tolerance is the -threshold to skip writing the new value. If the new value is within -tolerance percent of the last value written (compared out to 3 -decimal places), the write will be -skipped. The default is 0.0, which means that the write will occur -unless the current and previous values are the same. A tolerance of -.1 equates roughly to a difference in the 2nd decimal place.

    -
    enable [ auth | bclient | calibrate | kernel | monitor | ntp | pps | stats]
    - disable [ auth | bclient | calibrate | kernel | monitor | ntp | pps | stats ] -
    Provides a way to enable or disable various system options. Flags not mentioned are unaffected. Note that all of these flags can be controlled remotely using the ntpdc utility program. -
    -
    auth -
    Enables the server to synchronize with unconfigured peers only if the peer has been correctly authenticated using either public key or private key cryptography. The default for this flag is enable. -
    bclient -
    Enables the server to listen for a message from a broadcast or multicast server, as in the multicastclient command with default address. The default for this flag is disable. -
    calibrate -
    Enables the calibrate feature for reference clocks. The default for this flag is disable. -
    kernel -
    Enables the kernel time discipline, if available. The default for this flag is enable if support is available, otherwise disable. -
    monitor -
    Enables the monitoring facility. See the ntpdc program and the monlist command or further information. The default for this flag is enable. -
    ntp -
    Enables time and frequency discipline. In effect, this switch opens and closes the feedback loop, which is useful for testing. The default for this flag is enable. -
    pps -
    Enables the pulse-per-second (PPS) signal when frequency and time is disciplined by the precision time kernel modifications. See the A Kernel Model for Precision Timekeeping page for further information. The default for this flag is disable. -
    stats -
    Enables the statistics facility. See the Monitoring Options page for further information. The default for this flag is disable -
    -
    includefile includefile -
    This command allows additional configuration commands to be included from a separate file. Include files may be nested to a depth of five; upon reaching the end of any include file, command processing resumes in the previous configuration file. This option is useful for sites that run ntpd on multiple hosts, with (mostly) common options (e.g., a restriction list). -
    logconfig configkeyword -
    This command controls the amount and type of output written to the system syslog facility or the alternate logfile log file. All configkeyword keywords can be prefixed with =, + and -, where = sets the syslogmask, + adds and - removes messages. syslog messages can be controlled in four classes (clock, peer, sys and sync). Within these classes four types of messages can be controlled: informational messages (info), event messages (events), statistics messages (statistics) and status messages (status). -

    Configuration keywords are formed by concatenating the message class with the event class. The all prefix can be used instead of a message class. A message class may also be followed by the all keyword to enable/disable all messages of the respective message class. By default, logconfig output is set to allsync. -

    Thus, a minimal log configuration could look like this:

    -

    logconfig=syncstatus +sysevents

    -
    -
    -

    This would just list the synchronizations state of ntpd and the major system events. For a simple reference server, the following minimum message configuration could be useful:

    - -
    - -
    -

    logconfig=allsync +allclock

    -
    -
    -

    This configuration will list all clock information and synchronization information. All other events and messages about peers, system events and so on is suppressed.

    - -
    -
    logfile logfile -
    -
    -

    This command specifies the location of an alternate log file to be used instead of the default system syslog facility. This is the same operation as the -l command line option.

    - -
    -
    phone dial1 dial2 ... -
    -
    This command is used in conjunction with the ACTS modem driver (type 18). The arguments consist of a maximum of 10 telephone numbers used to dial USNO, NIST or European time services. The Hayes command ATDT is normally prepended to the number, which can contain other modem control codes as well. -
    -
    setvar variable [default] -
    This command adds an additional system variable. These variables can be used to distribute additional information such as the access policy. If the variable of the form name = value is followed by the default keyword, the variable will be listed as part of the default system variables (ntpq rv command). These additional variables serve informational purposes only. They are not related to the protocol other that they can be listed. The known protocol variables will always override any variables defined via the setvar mechanism. There are three special variables that contain the names of all variable of the same group. The sys_var_list holds the names of all system variables. The peer_var_list holds the names of all peer variables and the clock_var_list holds the names of the reference clock variables. -
    tinker [ allan allan | dispersion dispersion | freq freq | huffpuff huffpuff | panic panic | step step | stepout stepout ] -
    This command can be used to alter several system variables in very exceptional circumstances. It should occur in the configuration file before any other configuration options. The default values of these variables have been carefully optimized for a wide range of network speeds and reliability expectations. In general, they interact in intricate ways that are hard to predict and some combinations can result in some very nasty behavior. Very rarely is it necessary to change the default values; but, some folks can't resist twisting the knobs anyway and this command is for them. Emphasis added: twisters are on their own and can expect no help from the support group. -

    The variables operate as follows:

    -
    -
    allan allan -
    The argument becomes the new value for the Allan intercept, which is a parameter of the PLL/FLL clock discipline algorithm. The value is in seconds with default 1500 s, which is appropriate for most computer clocks.
    dispersion dispersion -
    The argument becomes the new value for the dispersion increase rate, normally .000015 s/s. -
    freq freq -
    The argument becomes the initial value of the frequency offset in parts-per-million. This overrides the value in the frequency file, if present, and avoids the initial training state if it is not. -
    huffpuff huffpuff -
    The argument becomes the new value for the experimental huff-n'-puff filter span, which determines the most recent interval the algorithm will search for a minimum delay. The lower limit is 900 s (15 m), but a more reasonable value is 7200 (2 hours). There is no default, since the filter is not enabled unless this command is given. -
    panic panic -
    The argument is the panic threshold, by default 1000 s. If set to zero, the panic sanity check is disabled and a clock offset of any value will be accepted. -
    step step -
    The argument is the step threshold, by default 0.128 s. It can be set to any positive number in seconds. If set to zero, step adjustments will never occur. Note: The kernel time discipline is disabled if the step threshold is set to zero or greater than the default. -
    stepout stepout -
    The argument is the stepout timeout, by default 900 s. It can be set to any positive number in seconds. If set to zero, the stepout pulses will not be suppressed. -
    -
    trap host_address [port port_number] [interface interface_address] -
    This command configures a trap receiver at the given host address and port number for sending messages with the specified local interface address. If the port number is unspecified, a value of 18447 is used. If the interface address is not specified, the message is sent with a source address of the local interface the message is sent through. Note that on a multihomed host the interface used may vary from time to time with routing changes. -

    The trap receiver will generally log event messages and other information from the server in a log file. While such monitor programs may also request their own trap dynamically, configuring a trap receiver will ensure that no messages are lost when the server is started.

    -
    ttl hop ... -
    This command specifies a list of TTL values in increasing order. up to 8 values can be specified. In manycast mode these values are used in turn in an expanding-ring search. The default is eight multiples of 32 starting at 31. -
    -

    Files

    - ntp.drift frequency compensation (PPM) -
    - - - - diff -urN src/contrib/ntp/html/monopt.html src.ntp/contrib/ntp/html/monopt.html --- src/contrib/ntp/html/monopt.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/monopt.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,132 +0,0 @@ - - - - - - - - Monitoring Options - - - - -

    Monitoring Options

    - giffrom Pogo, Walt Kelly -

    The pig watches the logs.

    -

    Last update: 00:40 UTC Sunday, December 24, 2006

    -
    -

    Related Links

    - -
    - ntpd includes a comprehensive monitoring facility suitable for continuous, long term recording of server and client timekeeping performance. See the statistics command below for a listing and example of each type of statistics currently supported. Statistic files are managed using file generation sets and scripts in the ./scripts directory of this distribution. Using these facilities and Unix cron jobs, the datacan be automatically summarized and archived for retrospective analysis. -

    Monitoring Commands

    -
    -
    statistics name [...] -
    Enables writing of statistics records. Currently, six kinds of namestatistics are supported. -
    -
    clockstats -
    Enables recording of clock driver statistics information. Each update received from a clock driver appends a line of the following form to the file generation set named clockstats: -
    49213 525.624 127.127.4.1 93 226 00:08:29.606 D -
    The first two fields show the date (Modified Julian Day) and time (seconds and fraction past UTC midnight). The next field shows the clock address in dotted-quad notation, The final field shows the last timecode received from the clock in decoded ASCII format, where meaningful. In some clock drivers a good deal of additional information can be gathered and displayed as well. See information specific to each clock for further details. -
    cryptostats -
    This option requires the OpenSSL cryptographic software library. It enables recording of cryptographic public key protocol information. Each message received by the protocol module appends a line of the following form to the file generation set named cryptostats: -
    49213 525.624 127.127.4.1 message -
    The first two fields show the date (Modified Julian Day) and time (seconds and fraction past UTC midnight). The next field shows the peer address in dotted-quad notation, The final message field includes the message type and certain ancillary information. See the Authentication Options page for further information. -
    loopstats -
    Enables recording of loop filter statistics information. Each update of the local clock outputs a line of the following form to the file generation set named loopstats: -
    50935 75440.031 0.000006019 13.778190 0.000351733 0.0133806 6 -
    The first two fields show the date (Modified Julian Day) and time (seconds and fraction past UTC midnight). The next five fields show time offset (seconds), frequency offset (parts per million - PPM), RMS jitter (seconds), Allan deviation (PPM) and clock discipline time constant. -
    peerstats -
    Enables recording of peer statistics information. This includes statistics records of all peers of a NTP server and of special signals, where present and configured. Each valid update appends a line of the following form to the current element of a file generation set named peerstats: -
    48773 10847.650 127.127.4.1 9714 -0.001605376 0.000000000 0.001424877 0.000958674 -
    The first two fields show the date (Modified Julian Day) and time (seconds and fraction past UTC midnight). The next two fields show the peer address in dotted-quad notation and status, respectively. The status field is encoded in hex in the format described in Appendix B of the NTP specification RFC 1305. The final four fields show the offset, delay, dispersion and RMS jitter, all in seconds. -
    rawstats -
    Enables recording of raw-timestamp statistics information. This includes statistics records of all peers of a NTP server and of special signals, where present and configured. Each NTP message received from a peer or clock driver appends a line of the following form to the file generation set named rawstats: -
    50928 2132.543 128.4.1.1 128.4.1.20 3102453281.584327000 3102453281.58622800031 02453332.540806000 3102453332.541458000 -
    The first two fields show the date (Modified Julian Day) and time (seconds and fraction past UTC midnight). The next two fields show the remote peer or clock address followed by the local address in dotted-quad notation, The final four fields show the originate, receive, transmit and final NTP timestamps in order. The timestamp values are as received and before processing by the various data smoothing and mitigation algorithms. -
    sysstats -
    Enables recording of ntpd statistics counters on a periodic basis. Each hour a line of the following form is appended to the file generation set named sysstats: -
    50928 2132.543 36000 81965 0 9546 56 71793 512 540 10 147 -
    The first two fields show the date (Modified Julian Day) and time (seconds and fraction past UTC midnight). The remaining ten fields show the statistics counter values accumulated since the last generated line. -
    -
    Time since restart 36000 -
    Time in hours since the system was last rebooted. -
    Packets received 81965 -
    Total number of packets received. -
    Packets processed 0 -
    Number of packets received in response to previous packets sent -
    Current version 9546 -
    Number of packets matching the current NTP version. -
    Previous version 56 -
    Number of packets matching the previous NTP version. -
    Bad version 71793 -
    Number of packets matching neither NTP version. -
    Access denied 512 -
    Number of packets denied access for any reason. -
    Bad length or format 540 -
    Number of packets with invalid length, format or port number. -
    Bad authentication 10 -
    Number of packets not verified as authentic. -
    Rate exceeded 147 -
    Number of packets discarded due to rate limitation. -
    -
    timingstats -
    ONLY available when the deamon is compiled with process time debugging support (--enable-debug-timing - costs performance). Enables recording of ntpd processing time information for various selected code paths: -
    53876 36.920 10.0.3.5 1 0.000014592 input processing delay -
    The first two fields show the date (Modified Julian Day) and time (seconds and fraction past UTC midnight). The next field is a potential peer address, - or -REFCLOCK- depending on the associated io source. Then an event count for the number of processed events in the code path follows. The fifth field is the total time spend for the events. The rest of the line denotes the code path description (see source for more information). -
    statsdir directory_path -
    Indicates the full path of a directory where statistics files should be created (see below). This keyword allows the (otherwise constant) filegen filename prefix to be modified for file generation sets, which is useful for handling statistics logs. -
    filegen name [file filename] [type typename] [link | nolink] [enable | disable] -
    Configures setting of generation file set name. Generation file sets provide a means for handling files that are continuously growing during the lifetime of a server. Server statistics are a typical example for such files. Generation file sets provide access to a set of files used to store the actual data. At any time at most one element of the set is being written to. The type given specifies when and how data will be directed to a new element of the set. This way, information stored in elements of a file set that are currently unused are available for administrational operations without the risk of disturbing the operation of ntpd. (Most important: they can be removed to free space for new data produced.) -
    Note that this command can be sent from the ntpdc program running at a remote location. -
    -
    name -
    This is the type of the statistics records, as shown in the statistics command. -
    -
    file filename -
    -
    This is the file name for the statistics records. Filenames of set members are built from three concatenated elements prefix, filename and suffix: -
    -
    prefix -
    This is a constant filename path. It is not subject to modifications via the filegen option. It is defined by the server, usually specified as a compile-time constant. It may, however, be configurable for individual file generation sets via other commands. For example, the prefix used with loopstats and peerstats generation can be configured using the statsdir option explained above. -
    filename -
    This string is directly concatenated to the prefix mentioned above (no intervening / (slash)). This can be modified using the file argument to the filegen statement. No .. elements are allowed in this component to prevent filenames referring to parts outside the filesystem hierarchy denoted by prefix. -
    suffix -
    This part is reflects individual elements of a file set. It is generated according to the type of a file set. -
    -
    -
    type typename -
    -
    A file generation set is characterized by its type. The following types are supported: -
    -
    none -
    The file set is actually a single plain file. -
    pid -
    One element of file set is used per incarnation of a ntpd server. This type does not perform any changes to file set members during runtime, however it provides an easy way of separating files belonging to different ntpd server incarnations. The set member filename is built by appending a . (dot) to concatenated prefix and filename strings, and appending the decimal representation of the process ID of the ntpd server process. -
    day -
    One file generation set element is created per day. A day is defined as the period between 00:00 and 24:00 UTC. The file set member suffix consists of a . (dot) and a day specification in the form YYYYMMdd. YYYY is a 4-digit year number (e.g., 1992). MM is a two digit month number. dd is a two digit day number. Thus, all information written at 10 December 1992 would end up in a file named prefix filename.19921210. -
    week -
    Any file set member contains data related to a certain week of a year. The term week is defined by computing day-of-year modulo 7. Elements of such a file generation set are distinguished by appending the following suffix to the file set filename base: A dot, a 4-digit year number, the letter W, and a 2-digit week number. For example, information from January, 10th 1992 would end up in a file with suffix .1992W1. -
    month -
    One generation file set element is generated per month. The file name suffix consists of a dot, a 4-digit year number, and a 2-digit month. -
    year -
    One generation file element is generated per year. The filename suffix consists of a dot and a 4 digit year number. -
    age -
    This type of file generation sets changes to a new element of the file set every 24 hours of server operation. The filename suffix consists of a dot, the letter a, and an 8-digit number. This number is taken to be the number of seconds the server is running at the start of the corresponding 24-hour period. Information is only written to a file generation by specifying enable; output is prevented by specifying disable. -
    -
    -
    link | nolink -
    -
    It is convenient to be able to access the current element of a file generation set by a fixed name. This feature is enabled by specifying link and disabled using nolink. If link is specified, a hard link from the current file set element to a file without suffix is created. When there is already a file with this name and the number of links of this file is one, it is renamed appending a dot, the letter C, and the pid of the ntpd server process. When the number of links is greater than one, the file is unlinked. This allows the current file to be accessed by a constant name. -
    -
    enable | disable -
    -
    Enables or disables the recording function. -
    -
    -
    - -
    - - - diff -urN src/contrib/ntp/html/msyslog.html src.ntp/contrib/ntp/html/msyslog.html --- src/contrib/ntp/html/msyslog.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/msyslog.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,122 +0,0 @@ - - - - - - ntpd System Log Messages - - - -

    ntpd System Log Messages

    - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

    The mushroom knows all the error codes, which is more than most of us do.

    -

    Last update: 19:24 UTC Saturday, October 01, 2005

    -
    -

    Related Links

    -

    -

    -
    -

    You have come here because you found a cryptic message in the system log. This page by no means lists all messages that might be found, since new ones come and old ones go. Generally, however, the most common ones will be found here. They are listed by program module and log severity code in bold: LOG_ERR, LOG_NOTICE and LOG_INFO.

    -

    Most of the time LOG_ERR messages are fatal, but often ntpd limps onward in the hopes of discovering more errors. The LOG_NOTICE messages usually mean the time has changed or some other condition that probably should be noticed. The LOG_INFO messages usually say something about the system operations, but do not affect the time.

    -

    In the following a '?' character stands for text in the message. The meaning should be clear from context.

    -

    Protocol Module

    -

    LOG_ERR

    -
    -
    buffer overflow ? - -
    Fatal error. An input packet is too long for processing. -
    -

    LOG_NOTICE

    -
    -
    no reply; clock not set -
    In ntpdate mode no servers have been found. The server(s) and/or network may be down. Standard debugging procedures apply. -

    LOG_INFO

    -
    proto_config: illegal item ?, value ? -
    Program error. Please report to bugs@ntp.org. -
    pps sync enabled -
    The PPS signal has been detected and enabled. -
    transmit: encryption key ? not found -
    The encryption key is not defined or not trusted. -
    precision = ? usec -
    This reports the precision measured for this machine. -
    using 10ms tick adjustments -
    Gotcha for some machines with dirty rotten clock hardware. -
    no servers reachable -
    The system clock is running on internal batteries. The server(s) and/or network may be down. -
    -

    Clock Discipline Module

    -

    LOG_ERR

    -
    -
    time correction of ? seconds exceeds sanity limit (?); set clock manually to the correct UTC time. -
    Fatal error. Better do what it says, then restart the daemon. Be advised NTP and Unix know nothing about local time zones. The clock must be set to Coordinated Universal Time (UTC). Believe it; by international agreement abbreviations are in French and descriptions are in English. -
    sigaction() fails to save SIGSYS trap: ?
    -
    sigaction() fails to restore SIGSYS trap: ? -
    Program error. Please report to bugs@ntp.org. -
    -

    LOG_NOTICE

    -
    -
    frequency error ? exceeds tolerance 500 PPM -
    The hardware clock frequency error exceeds the rate the kernel can correct. This could be a hardware or a kernel problem. -
    time slew ? s -
    The time error exceeds the step threshold and is being slewed to the correct time. You may have to wait a very long time. -
    time reset ? s -
    The time error exceeds the step threshold and has been reset to the correct time. Computer scientists don't like this, but they can set the ntpd -x option and wait forever. -
    kernel time sync disabled ? -
    The kernel reports an error. See the codes in the timex.h file. -
    pps sync disabled -
    The PPS signal has died, probably due to a dead radio, broken wire or loose connector. -
    -

    LOG_INFO

    -
    -
    kernel time sync status ? -
    For information only. See the codes in the timex.h file. -
    -

    Cryptographic Module

    -

    LOG_ERR

    -
    -
    cert_parse ?
    -
    cert_sign ?
    -
    crypto_cert ?
    -
    crypto_encrypt ?
    -
    crypto_gq ?
    -
    crypto_iff ?
    -
    crypto_key ?
    -
    crypto_mv ?
    -
    crypto_setup ?
    -
    make_keys ? -
    Usually fatal errors. These messages display error codes returned from the OpenSSL library. See the OpenSSL documentation for explanation. -
    crypto_setup: certificate ? is trusted, but not self signed.
    -
    crypto_setup: certificate ? not for this host
    -
    crypto_setup: certificate file ? not found or corrupt
    -
    crypto_setup: host key file ? not found or corrupt
    -
    crypto_setup: host key is not RSA key type
    -
    crypto_setup: random seed file ? not found
    -
    rypto_setup: random seed file not specified -
    Fatal errors. These messages show problems during the initialization procedure. -
    -

    LOG_INFO

    -
    -
    cert_parse: expired ?
    -
    cert_parse: invalid issuer ?
    -
    cert_parse: invalid signature ?
    -
    cert_parse: invalid subject ? -
    There is a problem with a certificate. Operation cannot proceed untill the problem is fixed. If the certificate is local, it can be regenerated using the ntp-keygen program. If it is held somewhere else, it must be fixed by the holder. -
    crypto_?: defective key
    -
    crypto_?: invalid filestamp
    -
    crypto_?: missing challenge
    -
    crypto_?: scheme unavailable -
    There is a problem with the identity scheme. Operation cannot proceed untill the problem is fixed. Usually errors are due to misconfiguration or an orphan association. If the latter, ntpd will usually time out and recover by itself. -
    crypto_cert: wrong PEM type ? -
    The certificate does not have MIME type CERTIFICATE. You are probably using the wrong type from OpenSSL or an external certificate authority. -
    crypto_ident: no compatible identity scheme found -
    Configuration error. The server and client identity schemes are incompatible. -
    crypto_tai: kernel TAI update failed -
    The kernel does not support this function. You may need a new kernel or patch. -
    crypto_tai: leapseconds file ? error ? -
    The leapseconds file is corrupt. Obtain the latest file from time.nist.gov. -
    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/mx4200data.html src.ntp/contrib/ntp/html/mx4200data.html --- src/contrib/ntp/html/mx4200data.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/mx4200data.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,1074 +0,0 @@ - - - - - MX4200 Receiver Data Format - - - - -

    MX4200 Receiver Data Format

    -
    -

    Table of Contents

    - -
    -

    Control Port Sentences

    -

    The Control (CDU) Port is used to initialize, monitor, and control the receiver. The structure of the control port sentences is based on the NMEA-0183 Standard for Interfacing Marine Electronics Navigation Devices (version 1.5). For more details, please refer to the NMEA-0183 Specification available from the National Marine Electronics Association.

    -

    Reserved characters are used to indicate the beginning and the end of records in the data stream, and to delimit data fields within a sentence. Only printable ASCII characters (Hex 20 through 7F) may be used in a sentence. Table 2 lists the reserved characters and defines their usage. Table 1 illustrates the general Magnavox proprietary NMEA sentence format.

    -

    Table 1. Magnavox Proprietary NMEA Sentence Format

    - $PMVXG,XXX,...................*CK -

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    CharacterMeaning
    $Sentence Start Character
    PSpecial ID (P = Proprietary)
    MVXOriginator ID (MVX = Magnavox)
    GInterface ID (G = GPS)
    XXXSentence Type
    ...Data
    *Optional Checksum Field Delimiter
    CKOptional Checksum
    -

    Table 2. NMEA Sentence Reserved Characters

    - - - - - - - - - - - - - - - - - - - - - - - - - - -
    CharacterHex ValueUsage
    $24Start of Sentence Identifier
    {cr}{lf}0D 0AEnd of Sentence Identifier
    ,2CSentence Delimiter
    *2AOptional Checksum Field Delimiter
    -

    Following the start character $, are five characters which constitute the block label of the sentence. For Magnavox proprietary sentences, this label is always PMVXG. The next field after the block label is the sentence type, consisting of three decimal digits.

    -

    The data, delimited by commas, follows the sentence type. Note that the receiver uses a free-format parsing algorithm, so you need not send the exact number of characters shown in the examples. You will need to use the commas to determine how many bytes of data need to be retrieved.

    -

    The notation CK shown in Table 1 symbolically indicates the optional checksum in the examples. The checksum is computed by exclusive-ORing all of the bytes between the $ and the * characters. The $, * and the checksum are not included in the checksum computation.

    -

    Checksums are optional for Control Port input sentences, but are highly recommended to limit the effects of communication errors. Magnavox receivers always generate checksums for Control Port output sentences.

    -

    ASCII data characters are transmitted in the following format:

    - - - - - - - - - - - - - -
    Data Bits8 (msb always 0)
    ParityNone
    Stop Bits1
    -

    NULL fields are fields which do not contain any data. They would appear as two commas together in the sentence format, except for the final field. Some Magnavox proprietary sentences require that the format contain NULL fields. mandatory NULL fields are identified by an '*' next to the respective field.

    -
    -

    Control Port Input Sentences

    - These are the subset of the MX4200 control port input sentences sent by the NTP driver to the GPS receiver. -
    -

    $PMVXG,000

    -

    Initialization/Mode Control - Part A

    - Initializes the time, position and antenna height of the MX4200. -

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    FieldDescriptionUnitsFormatDefaultRange
    1Day Int 1-31
    2Month Int 1-12
    3Year Int 1991-9999
    4GMT TimeHHMMSSInt 000000-235959
    5WGS-84 LatitudeDDMM.MMMMFloat0.00 - 8959.9999
    6North/South Indicator CharNN,S
    7WGS-84 LongitudeDDDMM.MMMMFloat0.00 - 17959.9999
    8East/West Indicator CharEE,W
    9Altitude (height above Mean Sea Level) in meters (WGS-84)MetersFloat0.0+/-99999.0
    10Not Used    
    - Example:
    - $PMVXG,000,,,,,,,,,,*48
    - $PMVXG,000,,,,,5128.4651,N,00020.0715,W,58.04,*4F -
    -

    $PMVXG,001

    -

    Initialization/Mode Control - Part B

    - Specifies various navigation parameters: Altitude aiding, acceleration DOP limits, and satellite elevation limits. -

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    FieldDescriptionUnitsFormatDefaultRange
    *1Constrain Altitude Int10=3D Only
    - 1=Auto
    - 2=2D Only
    2Not Used    
    *3Horizontal Acceleration Factorm/sec^2Float1.00.5-10.0
    *4Not Used    
    *5VDOP Limit Int101-9999
    *6HDOP Limit Int101-9999
    7Elevation LimitDegInt50-90
    8Time Output Mode CharUU=UTC
    - L=Local Time
    9Local Time OffsetHHMMInt0+/- 0-2359
    - Example:
    - $PMVXG,001,3,,0.1,0.1,10,10,5,U,0*06 -
    -

    $PMVXG,007

    -

    Control Port Output Configuration

    - This message enables or disables output of the specified sentence and defines the output rate. The user sends this message for each sentence that the receiver is to output. -

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    FieldDescriptionUnitsFormatDefaultRange
    1Control Port Output Block Label Char  
    2Clear Current Output List Int 0=No
    - 1=Yes
    3Add/Delete Sentence from List Int 1=Append
    - 2=Delete
    4Not Used    
    5Sentence Output RateSecInt 1-9999
    6# digits of Precision for CGA and GLL sentences Int22-4
    7Not Used    
    8Not Used    
    - Example:
    - $PMVXG,007,022,0,1,,1,,,*4F -
    -

    $PMVXG,023

    -

    Time Recovery Configuration

    - This message is used to enable/disable the time recovery feature of the receiver. The time synchronization for the 1PPS output is specified in addition to a user time bias and an error tolerance for a valid pulse. This record is accepted in units configured for time recovery. If the back panel contains a 1PPS outlet, the receiver is a time recovery unit. -

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    FieldDescriptionUnitsFormatDefaultRange
    *1Time Recovery Mode CharDD=Dynamic
    - S=Static
    - K=Known Position
    - N=No Time Recovery
    2Time Synchronization CharGU=UTC
    - G=GPS
    3Time Mark Mode CharAA=Always
    - V=Valid Pulses Only
    4Maximum Time ErrorNsecInt10050-1000
    5User Time BiasNsecInt0+/- 99999
    6ASCII Time Message Control Int00=No Output
    - 1=830 to Control Port
    - 2=830 to Equipment Port
    7Known Pos PRN Int01-32
    - 0=Track All Sats
    - Example:
    - $PMVXG,023,S,U,A,500,0,1,*16 -
    -

    $CDGPQ,YYY

    -

    Query From a Remote Device / Request to Output a Sentence

    - Enables the controller to request a one-time transmission of a specific block label. To output messages at a periodic rate, refer to input sentence $PMVXG,007. -

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    FieldDescriptionUnitsFormatDefaultRange
    1:CDID of Remote Device Char (See NMEA-0183)
    2:GPGPS Char (See NMEA-0183)
    3:QQuery Char (See NMEA-0183)
    4:YYYLabel of Desired Sentence Char Any Valid NMEA or Magnavox Sentence Type
    - Example:
    - $CDGPQ,030*5E -
    -

    Control Port Output Sentences

    - These are the subset of the MX4200 control port output sentences recognized by the NTP driver. -
    -

    $PMVXG,000

    -

    Receiver Status

    - Returns the current status of the receiver including the operating mode, number of satellites visible, and the number of satellites being tracked. -

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    FieldDescriptionUnitsFormatRange
    1Current Receiver Status CharACQ=Reacquisition
    - ALT=Constellation Selection
    - IAC=Initial Acquisition
    - IDL=Idle, No Satellites
    - NAV=Navigating
    - STS=Search The Sky
    - TRK=Tracking
    2Number of Satellites that should be Visible Int0-12
    3Number of Satellites being Tracked Int0-12
    4Time since Last NavigationHHMMInt0-2359
    5Initialization Status Int0=Waiting for Initialization
    - 1=Initialization Complete
    - Example:
    - $PMVXG,000,TRK,3,3,0122,1*19 -
    -

    $PMVXG,021

    -

    Position, Height, Velocity

    - This sentence gives the receiver position, height, navigation mode and velocity north/east. This sentence is intended for post analysis applications. -

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    FieldDescriptionUnitsFormatRange
    1UTC Measurement TimeSeconds into the weekFloat0-604800.00
    2WGS-84 LatitudeDDMM.MMMMFloat0-89.9999
    3North/South Indicator CharN, S
    4WGS-84 LongitudeDDDMM.MMMMFloat0-179.9999
    5East/West Indicator CharE, W
    6Altitude (MSL)MetersFloat 
    7Geoidal HeightMetersFloat 
    8Velocity EastM/SecFloat 
    9Velocity NorthM/SecFloat 
    10Navigation Mode IntNavigating
    - 1=Position From a Remote Device
    - 2=2D
    - 3=3D
    - 4=2D differential
    - 5=3D differential
    - Not Navigating
    - 51=Too Few Satellites
    - 52=DOPs too large
    - 53=Position STD too large
    - 54=Velocity STD too large
    - 55=Too many iterations for velocity
    - 56=Too many iterations for position
    - 57=3 Sat Startup failed
    - Example:
    - $PMVXG,021,142244.00,5128.4744,N,00020.0593,W,00054.4,0047.4,0000.1,-000.2,03*66 -
    -

    $PMVXG,022

    -

    DOPs

    - This sentence reports the DOP (Dilution Of Precision) values actually used in the measurement processing corresponding to the satellites listed. The satellites are listed in receiver channel order. Fields 11-16 are output only on 12-channel receivers. -

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    FieldDescriptionUnitsFormatRange
    1UTC Measurement TimeSeconds into the weekFloat0-604800.00
    2East DOP (EDOP) Float 
    3North DOP (NDOP) Float 
    4Vertical DOP (VDOP) Float 
    5PRN on Channel #1 Int1-32
    6PRN on Channel #2 Int1-32
    7PRN on Channel #3 Int1-32
    8PRN on Channel #4 Int1-32
    9PRN on Channel #5 Int1-32
    10PRN on Channel #6 Int1-32
    11PRN on Channel #7 Int1-32
    12PRN on Channel #8 Int1-32
    13PRN on Channel #9 Int1-32
    14PRN on Channel #10 Int1-32
    15PRN on Channel #11 Int1-32
    16PRN on Channel #12 Int1-32
    - Example:
    - $PMVXG,022,142243.00,00.7,00.8,01.9,27,26,10,09,13,23*77 -
    -

    $PMVXG,030

    -

    Software Configuration

    - This sentence contains the navigation processor and baseband firmware version numbers. -

    - - - - - - - - - - - - - - - - - - - - - - -
    FieldDescriptionUnitsFormatRange
    1Nav Processor Version Number Char 
    2Baseband Firmware Version Number Char 
    - Example:
    - $PMVXG,030,DA35,015 -
    -

    $PMVXG,101

    -

    Control Sentence Accept/Reject

    - This sentence is returned (on the Control Port) for every $PMVXG and $XXGPQ sentence that is received. -

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    FieldDescriptionUnitsFormatRange
    1Sentence ID Char 
    2Accept/Reject Status Int0=Sentence Accepted
    - 1=Bad Checksum
    - 2=Illegal Value
    - 3=Unrecognized ID
    - 4=Wrong # of fields
    - 5=Required Data Field Missing
    - 6=Requested Sentence Unavailable
    3Bad Field Index Int 
    4Requested Sentence ID (If field #1 = GPQ) Char 
    - Example:
    - $PMVXG,101,GPQ,0,,030*0D -
    -

    $PMVXG,523

    -

    Time Recovery Configuration

    - This sentence contains the configuration of the time recovery function of the receiver. -

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    FieldDescriptionUnitsFormatRange
    1Time Recovery Mode CharD=Dynamic
    - S=Static
    - K=Known Position
    - N=No Time Recovery
    2Time Synchronization CharU=UTC Time
    - G=GPS Time
    3Time Mark Mode CharA=Always Output Time Pulse
    - V=Only when Valid
    4Maximum Time Error for which a time mark will be considered validNsecInt 
    5User Time BiasNsecInt 
    6Time Message Control Int0=No Message
    - 1=830 to Control Port
    - 2=830 to Equipment Port
    7Not Used   
    - Example:
    - $PMVXG,523,S,U,A,0500,000000,1,0*23 -
    -

    $PMVXG,830

    -

    Time Recovery Results

    - This sentence is output approximately 1 second preceding the 1PPS output. It indicates the exact time of the next pulse, whether or not the time mark will be valid (based on operator-specified error tolerance), the time to which the pulse is synchronized, the receiver operating mode, and the time error of the last 1PPS output. The leap second flag (Field #11) is not output by older receivers. -

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    FieldDescriptionUnitsFormatRange
    1Time Mark Valid CharT=Valid
    - F=Not Valid
    2Year Int1993-
    3Month Int1-12
    4DayNsecInt1-31
    5TimeHH:MM:SSInt00:00:00-23:59:59
    6Time Synchronization CharU=UTC
    - G=GPS
    7Operating Mode CharD=Dynamic
    - S=Static
    - K=Known Position
    8Oscillator Offset - estimate of oscillator frequency errorPPBInt 
    9Time Mark Error of last pulseNsecInt 
    10User Time BiasNsecInt 
    11Leap Second Flag - indicates that a leap second will occur. This value is usually zero except during the week prior to a leap second occurrence, when this value will be set to +/-1. A value of +1 indicates that GPS time will be 1 second further ahead of UTC time. Int-1,0,1
    - Example:
    - $PMVXG,830,T,1998,10,12,15:30:46,U,S,000298,00003,000000,01*02 -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/notes.html src.ntp/contrib/ntp/html/notes.html --- src/contrib/ntp/html/notes.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/notes.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,280 +0,0 @@ - - - - - - - - Notes on setting up a NTP subnet - - - - -

    Notes on setting up a NTP subnet

    - gifFrom NBS Special Publication 432 (out of print) -

    Last update: 18:44 UTC Thursday, July 28, 2005

    -
    -
    -

    Introduction

    -

    This document is a collection of notes concerning the use of ntpd and related programs, and on coping with the Network Time Protocol (NTP) in general. It is a major rewrite and update of an earlier document written by Dennis Ferguson of the University of Toronto and includes many changes and additions resulting from the NTP Version 3 specification and new Version 4 implementation features. It supersedes earlier documents, which should no longer be used for new configurations.

    -

    ntpd includes a complete implementation of the NTP Version 3 specification, as defined in:

    -
      -
    • Mills, D.L. Network Time Protocol (Version 3) specification, implementation and analysis. Network Working Group Report RFC-1305, University of Delaware, March 1992, 113 pp. Abstract: PostScript | PDF, Body: PostScript | PDF, Appendices: PostScript | PDF -
    -

    Additional features have are described for NTP Version 4 Release Notes. It also retains compatibility with both NTP Version 2, as defined in RFC-1119, and NTP Version 1, as defined in RFC-1059, although this compatibility is sometimes strained and only semiautomatic. In order to support in principle the ultimate precision of about 232 picoseconds in the NTP specification, ntpd uses NTP timestamp format for external communication and double precision floating point arithmetic internally. ntpd fully implements NTP Versions 2 and 3 authentication and in addition Version 4 autokey. It supports the NTP mode-6 control message facility along with a private mode-7 control- message facility used to remotely reconfigure the system and monitor a considerable amount of internal detail. As extensions to the specification, a flexible address-and-mask restriction facility has been included.

    -

    The code is biased towards the needs of a busy time server with numerous, often hundreds, of clients and other servers. Tables are hashed to allow efficient handling of many associations, though at the expense of additional overhead when the number of associations is small. Many fancy features have been included to permit efficient management and monitoring of a busy primary server, features which are probably excess baggage for a high stratum client. In such cases, a stripped-down version of the protocol, the Simple Network Time Protocol (SNTP) can be used. SNTP and NTP servers and clients can interwork in most situations, as described in: Mills, D.L. Simple Network Time Protocol (SNTP). Network Working Group Report RFC-2030, University of Delaware, October 1996, 14 pp. (ASCII).

    -

    The code was written with near demonic attention to details which can affect precision and as a consequence should be able to make good use of high performance, special purpose hardware such as precision oscillators and radio clocks. The present code supports a number of radio clocks, including those for the WWV, CHU, WWVB, MSF, DCF77, GOES and GPS radio and satellite time services and USNO, ACTS and PTB modem time services. It also supports the IRIG-B and IRIG-E signal format connected via an audio codec. The server methodically avoids the use of Unix-specific library routines where possible by implementing local versions, in order to aid in porting the code to perverse Unix and non-Unix platforms.

    -

    While this implementation conforms in most respects to the NTP Version 3 specification RFC-1305, a number of improvements have been made which are described in the conformance statement in the NTP Protocol Conformance Statement page. It has been specifically tuned to achieve the highest accuracy possible on whatever hardware and operating-system platform is available. In general, its precision and stability are limited only by the characteristics of the onboard clock source used by the hardware and operating system, usually an uncompensated crystal oscillator. On modern RISC-based processors connected directly to radio clocks via serial-asynchronous interfaces, the accuracy is usually limited by the radio clock and interface to the order of a millisecond or less. The code includes special features to support a pulse-per-second (PPS) signal and/or an IRIG-B signal generated by some radio clocks. When used in conjunction with a suitable hardware level converter, the accuracy can be improved to a few tens of microseconds. Further improvement is possible using an outboard, stabilized frequency source, in which the accuracy and stability are limited only by the characteristics of that source.

    -

    The NTP Version 4 distribution includes, in addition to the daemon itself (ntpd), several utility programs, including two remote-monitoring programs (ntpq, ntpdc), a remote clock-setting program similar to the Unix rdate program (ntpdate), a traceback utility useful to discover suitable synchronization sources (ntptrace), and various programs used to configure the local platform and calibrate the intrinsic errors. NTP has been ported to a large number of platforms, including most RISC and CISC workstations and mainframes manufactured today. Example configuration files for many models of these machines are included in the distribution. While in most cases the standard version of the implementation runs with no hardware or operating system modifications, not all features of the distribution are available on all platforms. For instance, a special feature allowing Sun workstations to achieve accuracies in the order of 100 microseconds requires some minor changes and additions to the kernel and input/output support.

    -

    There are, however, several drawbacks to all of this. ntpd is quite fat. This is rotten if your intended platform for the daemon is memory limited. ntpd uses SIGIO for all input, a facility which appears to not enjoy universal support and whose use seems to exercise the parts of your vendors' kernels which are most likely to have been done poorly. The code is unforgiving in the face of kernel problems which affect performance, and generally requires that you repair the problems in order to achieve acceptable performance. The code has a distinctly experimental flavour and contains features which could charitably be termed failed experiments, but which have not been completely hacked out. Much was learned from the addition of support for a variety of radio clocks, with the result that some radio clock drivers could use some rewriting.

    -

    How NTP Works

    -

    The approach used by NTP to achieve reliable time synchronization from a set of possibly unreliable remote time servers is somewhat different than other protocols. In particular, NTP does not attempt to synchronize clocks to each other. Rather, each server attempts to synchronize to Universal Coordinated Time (UTC) using the best available source and available transmission paths to that source. This is a fine point which is worth understanding. A group of NTP-synchronized clocks may be close to each other in time, but this is not a consequence of the clocks in the group having synchronized to each other, but rather because each clock has synchronized closely to UTC via the best source it has access to. As such, trying to synchronize a set of clocks to a set of servers whose time is not in mutual agreement may not result in any sort of useful synchronization of the clocks, even if you don't care about UTC. However, in networks isolated from UTC sources, provisions can made to nominate one of them as a phantom UTC source.

    -

    NTP operates on the premise that there is one true standard time, and that if several servers which claim synchronization to standard time disagree about what that time is, then one or more of them must be broken. There is no attempt to resolve differences more gracefully since the premise is that substantial differences cannot exist. In essence, NTP expects that the time being distributed from the root of the synchronization subnet will be derived from some external source of UTC (e.g., a radio clock). This makes it somewhat inconvenient (though by no means impossible) to synchronize hosts together without a reliable source of UTC to synchronize them to. If your network is isolated and you cannot access other people's servers across the Internet, a radio clock may make a good investment.

    -

    Time is distributed through a hierarchy of NTP servers, with each server adopting a stratum which indicates how far away from an external source of UTC it is operating at. Stratum-1 servers, which are at the top of the pile (or bottom, depending on your point of view), have access to some external time source, usually a radio clock synchronized to time signal broadcasts from radio stations which explicitly provide a standard time service. A stratum-2 server is one which is currently obtaining time from a stratum-1 server, a stratum-3 server gets its time from a stratum-2 server, and so on. To avoid long lived synchronization loops the number of strata is limited to 15.

    -

    Each client in the synchronization subnet (which may also be a server for other, higher stratum clients) chooses exactly one of the available servers to synchronize to, usually from among the lowest stratum servers it has access to. This is, however, not always an optimal configuration, for indeed NTP operates under another premise as well, that each server's time should be viewed with a certain amount of distrust. NTP really prefers to have access to several sources of lower stratum time (at least three) since it can then apply an agreement algorithm to detect insanity on the part of any one of these. Normally, when all servers are in agreement, NTP will choose the best of these, where "best" is defined in terms of lowest stratum, closest (in terms of network delay) and claimed precision, along with several other considerations. The implication is that, while one should aim to provide each client with three or more sources of lower stratum time, several of these will only be providing backup service and may be of lesser quality in terms of network delay and stratum (i.e., a same-stratum peer which receives time from lower stratum sources the local server doesn't access directly can also provide good backup service).

    -

    Finally, there is the issue of association modes. There are a number of modes in which NTP servers can associate with each other, with the mode of each server in the pair indicating the behaviour the other server can expect from it. In particular, when configuring a server to obtain time from other servers, there is a choice of two modes which may be used. Configuring an association in symmetric-active mode (usually indicated by a peer declaration in the configuration file) indicates to the remote server that one wishes to obtain time from the remote server and that one is also willing to supply time to the remote server if need be. This mode is appropriate in configurations involving a number of redundant time servers interconnected via diverse network paths, which is presently the case for most stratum-1 and stratum-2 servers on the Internet today. Configuring an association in client mode (usually indicated by a server declaration in the configuration file) indicates that one wishes to obtain time from the remote server, but that one is not willing to provide time to the remote server. This mode is appropriate for file-server and workstation clients that do not provide synchronization to other local clients. Client mode is also useful for boot-date-setting programs and the like, which really have no time to provide and which don't retain state about associations over the longer term.

    -

    Where the requirements in accuracy and reliability are modest, clients can be configured to use broadcast and/or multicast modes. These modes are not normally utilized by servers with dependent clients. The advantage of these modes is that clients do not need to be configured for a specific server, so that all clients operating can use the same configuration file. Broadcast mode requires a broadcast server on the same subnet, while multicast mode requires support for IP multicast on the client machine, as well as connectivity via the MBONE to a multicast server. Since broadcast messages are not propagated by routers, only those broadcast servers on the same subnet will be used. There is at present no way to select which of possibly many multicast servers will be used, since all operate on the same group address.

    -

    Where the maximum accuracy and reliability provided by NTP are needed, clients and servers operate in either client/server or symmetric modes. Symmetric modes are most often used between two or more servers operating as a mutually redundant group. In these modes, the servers in the group members arrange the synchronization paths for maximum performance, depending on network jitter and propagation delay. If one or more of the group members fail, the remaining members automatically reconfigure as required. Dependent clients and servers normally operate in client/server mode, in which a client or dependent server can be synchronized to a group member, but no group member can synchronize to the client or dependent server. This provides protection against malfunctions or protocol attacks.

    -

    Servers that provide synchronization to a sizeable population of clients normally operate as a group of three or more mutually redundant servers, each operating with three or more stratum-one or stratum-two servers in client-server modes, as well as all other members of the group in symmetric modes. This provides protection against malfunctions in which one or more servers fail to operate or provide incorrect time. The NTP algorithms have been specifically engineered to resist attacks where some fraction of the configured synchronization sources accidently or purposely provide incorrect time. In these cases a special voting procedure is used to identify spurious sources and discard their data.

    -

    Configuring Your Subnet

    - At startup time the ntpd daemon running on a host reads the initial configuration information from a file, usually /etc/ntp.conf, unless a different name has been specified at compile time. Putting something in this file which will enable the host to obtain time from somewhere else is usually the first big hurdle after installation of the software itself, which is described in the Building and Installing the Distribution page. At its simplest, what you need to do in the configuration file is declare the servers that the daemon should poll for time synchronization. In principle, no such list is needed if some other time server operating in broadcast/multicast mode is available, which requires the client to operate in a broadcastclient mode. -

    In the case of a workstation operating in an enterprise network for a public or private organization, there is often an administrative department that coordinates network services, including NTP. Where available, the addresses of appropriate servers can be provided by that department. However, if this infrastructure is not available, it is necessary to explore some portion of the existing NTP subnet now running in the Internet. There are at present many thousands of time servers running NTP in the Internet, a significant number of which are willing to provide a public time- synchronization service. Some of these are listed in the list of public time servers, which can be accessed via the NTP web page. These data are updated on a regular basis using information provided voluntarily by various site administrators. There are other ways to explore the nearby subnet using the ntptrace and ntpdc programs.

    -

    It is vital to carefully consider the issues of robustness and reliability when selecting the sources of synchronization. Normally, not less than three sources should be available, preferably selected to avoid common points of failure. It is usually better to choose sources which are likely to be "close" to you in terms of network topology, though you shouldn't worry overly about this if you are unable to determine who is close and who isn't. Normally, it is much more serious when a server becomes faulty and delivers incorrect time than when it simply stops operating, since an NTP-synchronized host normally can coast for hours or even days without its clock accumulating serious error approaching a second, for instance. Selecting at least three sources from different operating administrations, where possible, is the minimum recommended, although a lesser number could provide acceptable service with a degraded degree of robustness.

    -

    Normally, it is not considered good practice for a single workstation to request synchronization from a primary (stratum-1) time server. At present, these servers provide synchronization for hundreds of clients in many cases and could, along with the network access paths, become seriously overloaded if large numbers of workstation clients requested synchronization directly. Therefore, workstations located in sparsely populated administrative domains with no local synchronization infrastructure should request synchronization from nearby stratum-2 servers instead. In most cases the keepers of those servers in the lists of public servers provide unrestricted access without prior permission; however, in all cases it is considered polite to notify the administrator listed in the file upon commencement of regular service. In all cases the access mode and notification requirements listed in the file must be respected. Under no conditions should servers not in these lists be used without prior permission, as to do so can create severe problems in the local infrastructure, especially in cases of dial-up access to the Internet.

    -

    In the case of a gateway or file server providing service to a significant number of workstations or file servers in an enterprise network it is even more important to provide multiple, redundant sources of synchronization and multiple, diversity-routed, network access paths. The preferred configuration is at least three administratively coordinated time servers providing service throughout the administrative domain including campus networks and subnetworks. Each of these should obtain service from at least two different outside sources of synchronization, preferably via different gateways and access paths. These sources should all operate at the same stratum level, which is one less than the stratum level to be used by the local time servers themselves. In addition, each of these time servers should peer with all of the other time servers in the local administrative domain at the stratum level used by the local time servers, as well as at least one (different) outside source at this level. This configuration results in the use of six outside sources at a lower stratum level (toward the primary source of synchronization, usually a radio clock), plus three outside sources at the same stratum level, for a total of nine outside sources of synchronization. While this may seem excessive, the actual load on network resources is minimal, since the interval between polling messages exchanged between peers usually ratchets back to no more than one message every 17 minutes.

    -

    The stratum level to be used by the local time servers is an engineering choice. As a matter of policy, and in order to reduce the load on the primary servers, it is desirable to use the highest stratum consistent with reliable, accurate time synchronization throughout the administrative domain. In the case of enterprise networks serving hundreds or thousands of client file servers and workstations, conventional practice is to obtain service from stratum-1 primary servers listed for public access. When choosing sources away from the primary sources, the particular synchronization path in use at any time can be verified using the ntptrace program included in this distribution. It is important to avoid loops and possible common points of failure when selecting these sources. Note that, while NTP detects and rejects loops involving neighboring servers, it does not detect loops involving intervening servers. In the unlikely case that all primary sources of synchronization are lost throughout the subnet, the remaining servers on that subnet can form temporary loops and, if the loss continues for an interval of many hours, the servers will drop off the subnet and free-run with respect to their internal (disciplined) timing sources. After some period with no outside timing source (currently one day), a host will declare itself unsynchronized and provide this information to local application programs.

    -

    In many cases the purchase of one or more radio clocks is justified, in which cases good engineering practice is to use the configurations described above anyway and connect the radio clock to one of the local servers. This server is then encouraged to participate in a special primary-server subnetwork in which each radio-equipped server peers with several other similarly equipped servers. In this way the radio-equipped server may provide synchronization, as well as receive synchronization, should the local or remote radio clock(s) fail or become faulty. ntpd treats attached radio clock(s) in the same way as other servers and applies the same criteria and algorithms to the time indications, so can detect when the radio fails or becomes faulty and switch to alternate sources of synchronization. It is strongly advised, and in practice for most primary servers today, to employ the authentication or access-control features of the NTP specification in order to protect against hostile intruders and possible destabilization of the time service. Using this or similar strategies, the remaining hosts in the same administrative domain can be synchronized to the three (or more) selected time servers. Assuming these servers are synchronized directly to stratum-1 sources and operate normally as stratum-2, the next level away from the primary source of synchronization, for instance various campus file servers, will operate at stratum 3 and dependent workstations at stratum 4. Engineered correctly, such a subnet will survive all but the most exotic failures or even hostile penetrations of the various, distributed timekeeping resources.

    -

    The above arrangement should provide very good, robust time service with a minimum of traffic to distant servers and with manageable loads on the local servers. While it is theoretically possible to extend the synchronization subnet to even higher strata, this is seldom justified and can make the maintenance of configuration files unmanageable. Serving time to a higher stratum peer is very inexpensive in terms of the load on the lower stratum server if the latter is located on the same concatenated LAN. When justified by the accuracy expectations, NTP can be operated in broadcast and multicast modes, so that clients need only listen for periodic broadcasts and do not need to send anything.

    -

    When planning your network you might, beyond this, keep in mind a few generic don'ts, in particular:

    -
      -
    • Don't synchronize a local time server to another peer at the same stratum, unless the latter is receiving time from lower stratum sources the former doesn't talk to directly. This minimizes the occurrence of common points of failure, but does not eliminate them in cases where the usual chain of associations to the primary sources of synchronization are disrupted due to failures. -

    • -
    • Don't configure peer associations with higher stratum servers. Let the higher strata configure lower stratum servers, but not the reverse. This greatly simplifies configuration file maintenance, since there is usually much greater configuration churn in the high stratum clients such as personal workstations. -

    • -
    • Don't synchronize more than one time server in a particular administrative domain to the same time server outside that domain. Such a practice invites common points of failure, as well as raises the possibility of massive abuse, should the configuration file be automatically distributed do a large number of clients. -
    - There are many useful exceptions to these rules. When in doubt, however, follow them. -

    Configuring Your Server or Client

    -

    As mentioned previously, the configuration file is usually called /etc/ntp.conf. This is an ASCII file conforming to the usual comment and whitespace conventions. A working configuration file might look like (in this and other examples, do not copy this directly):

    -
    -     # peer configuration for host whimsy
    -     # (expected to operate at stratum 2)
    -
    -     server rackety.udel.edu
    -     server umd1.umd.edu
    -     server lilben.tn.cornell.edu
    -
    -     driftfile /etc/ntp.drift
    -
    - (Note the use of host names, although host addresses in dotted-quad notation can also be used. It is always preferable to use names rather than addresses, since over time the addresses can change, while the names seldom change.) -

    This particular host is expected to operate as a client at stratum 2 by virtue of the server keyword and the fact that two of the three servers declared (the first two) have radio clocks and usually run at stratum 1. The third server in the list has no radio clock, but is known to maintain associations with a number of stratum 1 peers and usually operates at stratum 2. Of particular importance with the last host is that it maintains associations with peers besides the two stratum 1 peers mentioned. This can be verified using the ntpq program mentioned above. When configured using the server keyword, this host can receive synchronization from any of the listed servers, but can never provide synchronization to them.

    -

    Unless restricted using facilities described later, this host can provide synchronization to dependent clients, which do not have to be listed in the configuration file. Associations maintained for these clients are transitory and result in no persistent state in the host. These clients are normally not visible using the ntpq program included in the distribution; however, ntpd includes a monitoring feature (described later) which caches a minimal amount of client information useful for debugging administrative purposes.

    -

    A time server expected to both receive synchronization from another server, as well as to provide synchronization to it, is declared using the peer keyword instead of the server keyword. In all other aspects the server operates the same in either mode and can provide synchronization to dependent clients or other peers. If a local source of UTC time is available, it is considered good engineering practice to declare time servers outside the administrative domain as peer and those inside as server in order to provide redundancy in the global Internet, while minimizing the possibility of instability within the domain itself. A time server in one domain can in principle heal another domain temporarily isolated from all other sources of synchronization. However, it is probably unwise for a casual workstation to bridge fragments of the local domain which have become temporarily isolated.

    -

    Note the inclusion of a driftfile declaration. One of the things the NTP daemon does when it is first started is to compute the error in the intrinsic frequency of the clock on the computer it is running on. It usually takes about a day or so after the daemon is started to compute a good estimate of this (and it needs a good estimate to synchronize closely to its server). Once the initial value is computed, it will change only by relatively small amounts during the course of continued operation. The driftfile declaration indicates to the daemon the name of a file where it may store the current value of the frequency error so that, if the daemon is stopped and restarted, it can reinitialize itself to the previous estimate and avoid the day's worth of time it will take to recompute the frequency estimate. Since this is a desirable feature, a driftfile declaration should always be included in the configuration file.

    -

    An implication in the above is that, should ntpd be stopped for some reason, the local platform time will diverge from UTC by an amount that depends on the intrinsic error of the clock oscillator and the time since last synchronized. In view of the length of time necessary to refine the frequency estimate, every effort should be made to operate the daemon on a continuous basis and minimize the intervals when for some reason it is not running.

    -

    Configuring NTP with NetInfo

    - If NetInfo support is compiled into NTP, you can opt to configure NTP in your NetInfo domain. NTP will look in the NetInfo directory /locations/ntp for property/value pairs which are equivalent to the lines in the configuration file described above. Each configuration keyword may have a corresponding property in NetInfo. Each value for a given property is treated as arguments to that property, similar to a line in the configuration file. -

    For example, the configuration shown in the configuration file above can be duplicated in NetInfo by adding a property "server" with values "rackety.udel.edu", "umd1.umd.edu", and "lilben.tn.cornell.edu"; and a property "driftfile" with the single value "/etc/ntp.drift".

    -

    Values may contain multiple tokens similar to the arguments available in the configuration file. For example, to use mimsy.mil as an NTP version 1 time server, you would add a value "mimsy.mil version 1" to the "server" property.

    -

    Ntp4 Versus Previous Versions

    - There are several items of note when dealing with a mixture of ntp4 and previous distributions of NTP Version 2 (ntpd) and NTP Version 1 (ntp3.4). The ntp4 implementation conforms to the NTP Version 3 specification RFC-1305 and, in addition, contains additional features documented in the Release Notes page. As such, by default when no additional information is available concerning the preferences of the peer, ntpd claims to be version 4 in the packets that it sends from configured associations. The version subcommand of the server, peer, broadcast and manycastclient command can be used to change the default. In unconfigured (ephemeral) associaitons, the daemon always replies in the same version as the request. -

    An NTP implementation conforming to a previous version specification ordinarily discards packets from a later version. However, in most respects documented in RFC-1305, The version 2 implementation is compatible with the version 3 algorithms and protocol. The version 1 implementation contains most of the version 2 algorithms, but without important features for clock selection and robustness. Nevertheless, in most respects the NTP versions are backwards compatible. The sticky part here is that, when a previous version implementation receives a packet claiming to be from a version 4 server, it discards it without further processing. Hence there is a danger that in some situations synchronization with previous versions will fail.

    -

    The trouble occurs when an previous version is to be included in an ntpd configuration file. With no further indication, ntpd will send packets claiming to be version 4 when it polls. To get around this, ntpd allows a qualifier to be added to configuration entries to indicate which version to use when polling. Hence the entries

    -
    -     # specify NTP version 1
    -
    -     server mimsy.mil version
    -1     # server running ntpd version 1
    -     server apple.com version
    -2     # server running ntpd version 2
    -
    - will cause version 1 packets to be sent to the host mimsy.mil and version 2 packets to be sent to apple.com. If you are testing ntpd against previous version servers you will need to be careful about this. Note that, as indicated in the RFC-1305 specification, there is no longer support for the original NTP specification, once called NTP Version 0. -

    Traffic Monitoring

    - ntpd handles peers whose stratum is higher than the stratum of the local server and polls using client mode by a fast path which minimizes the work done in responding to their polls, and normally retains no memory of these pollers. Sometimes, however, it is interesting to be able to determine who is polling the server, and how often, as well as who has been sending other types of queries to the server. -

    To allow this, ntpd implements a traffic monitoring facility which records the source address and a minimal amount of other information from each packet which is received by the server. This feature is normally enabled, but can be disabled if desired using the configuration file entry:

    -
    -     # disable monitoring feature
    -     disable monitor
    -
    - The recorded information can be displayed using the ntpdc query program, described briefly below. -

    Address-and-Mask Restrictions

    - The address-and-mask configuration facility supported by ntpd is quite flexible and general, but is not an integral part of the NTP Version 3 specification. The major drawback is that, while the internal implementation is very nice, the user interface is not. For this reason it is probably worth doing an example here. Briefly, the facility works as follows. There is an internal list, each entry of which holds an address, a mask and a set of flags. On receipt of a packet, the source address of the packet is compared to each entry in the list, with a match being posted when the following is true: -
    -     (source_addr & mask) == (address &
    -mask)
    -
    - A particular source address may match several list entries. In this case the entry with the most one bits in the mask is chosen. The flags associated with this entry are used to control the access. -

    In the current implementation the flags always add restrictions. In effect, an entry with no flags set leaves matching hosts unrestricted. An entry can be added to the internal list using a restrict declaration. The flags associated with the entry are specified textually. For example, the notrust flag indicates that hosts matching this entry, while treated normally in other respects, shouldn't be trusted to provide synchronization even if otherwise so enabled. The nomodify flag indicates that hosts matching this entry should not be allowed to do run-time configuration. There are many more flags, see the ntpd page.

    -

    Now the example. Suppose you are running the server on a host whose address is 128.100.100.7. You would like to ensure that run time reconfiguration requests can only be made from the local host and that the server only ever synchronizes to one of a pair of off-campus servers or, failing that, a time source on net 128.100. The following entries in the configuration file would implement this policy:

    -
    -     # by default, don't trust and don't allow
    -modifications
    -
    -     restrict default notrust nomodify
    -
    -     # these guys are trusted for time, but no
    -modifications allowed
    -
    -     restrict 128.100.0.0 mask 255.255.0.0 nomodify
    -     restrict 128.8.10.1 nomodify
    -     restrict 192.35.82.50 nomodify
    -
    -     # the local addresses are unrestricted
    -
    -     restrict 128.100.100.7
    -     restrict 127.0.0.1
    -
    - The first entry is the default entry, which all hosts match and hence which provides the default set of flags. The next three entries indicate that matching hosts will only have the nomodify flag set and hence will be trusted for time. If the mask isn't specified in the restrict keyword, it defaults to 255.255.255.255. Note that the address 128.100.100.7 matches three entries in the table, the default entry (mask 0.0.0.0), the entry for net 128.100 (mask 255.255.0.0) and the entry for the host itself (mask 255.255.255.255). As expected, the flags for the host are derived from the last entry since the mask has the most bits set. -

    The only other thing worth mentioning is that the restrict declarations apply to packets from all hosts, including those that are configured elsewhere in the configuration file and even including your clock pseudopeer(s), if any. Hence, if you specify a default set of restrictions which you don't wish to be applied to your configured peers, you must remove those restrictions for the configured peers with additional restrict declarations mentioning each peer separately.

    -

    Authentication

    - ntpd supports the optional authentication procedure specified in the NTP Version 2 and 3 specifications. Briefly, when an association runs in authenticated mode, each packet transmitted has appended to it a 32-bit key ID and a 64/128-bit cryptographic checksum of the packet contents computed using either the Data Encryption Standard (DES) or Message Digest (MD5) algorithms. Note that, while either of these algorithms provide sufficient protection from message- modification attacks, distribution of the former algorithm implementation is restricted to the U.S. and Canada, while the latter presently is free from such restrictions. For this reason, the DES algorithm is not included in the current distribution. Directions for obtaining it in other countries is in the Building and Installing the Distribution page. With either algorithm the receiving peer recomputes the checksum and compares it with the one included in the packet. For this to work, the peers must share at least one encryption key and, furthermore, must associate the shared key with the same key ID. -

    This facility requires some minor modifications to the basic packet processing procedures, as required by the specification. These modifications are enabled by the enable auth configuration declaration, which is currently the default. In authenticated mode, peers which send unauthenticated packets, peers which send authenticated packets which the local server is unable to decrypt and peers which send authenticated packets encrypted using a key we don't trust are all marked untrustworthy and unsuitable for synchronization. Note that, while the server may know many keys (identified by many key IDs), it is possible to declare only a subset of these as trusted. This allows the server to share keys with a client which requires authenticated time and which trusts the server, but which is not trusted by the server. Also, some additional configuration language is required to specify the key ID to be used to authenticate each configured peer association. Hence, for a server running in authenticated mode, the configuration file might look similar to the following:

    -
    -     # peer configuration for 128.100.100.7
    -     # (expected to operate at stratum 2)
    -     # fully authenticated this time
    -
    -     peer 128.100.49.105 key 22 #
    -suzuki.ccie.utoronto.ca
    -     peer 128.8.10.1 key 4    #
    -umd1.umd.edu
    -     peer 192.35.82.50 key 6  #
    -lilben.tn.cornell.edu
    -
    -     keys /usr/local/etc/ntp.keys  # path for
    -key file
    -     trustedkey 1 2 14 15     #
    -define trusted keys
    -     requestkey
    -15            #
    -key (7) for accessing server variables
    -     controlkey
    -15            #
    -key (6) for accessing server variables
    -
    -     authdelay
    -0.000094       # authentication delay
    -(Sun4c/50 IPX)
    -
    - There are a couple of previously unmentioned things in here. The keys line specifies the path to the keys file (see below and the ntpd document page for details of the file format). The trustedkey declaration identifies those keys that are known to be uncompromised; the remainder presumably represent the expired or possibly compromised keys. Both sets of keys must be declared by key identifier in the ntp.keys file described below. This provides a way to retire old keys while minimizing the frequency of delicate key-distribution procedures. The requestkey line establishes the key to be used for mode-6 control messages as specified in RFC-1305 and used by the ntpq utility program, while the controlkey line establishes the key to be used for mode-7 private control messages used by the ntpdc utility program. These keys are used to prevent unauthorized modification of daemon variables. -

    Ordinarily, the authentication delay; that is, the processing time taken between the freezing of a transmit timestamp and the actual transmission of the packet when authentication is enabled (i.e. more or less the time it takes for the DES or MD5 routine to encrypt a single block) is computed automatically by the daemon. If necessary, the delay can be overridden by the authdelay line, which is used as a correction for the transmit timestamp.

    - Additional utility programs included in the ./authstuff directory can be used to generate random keys, certify implementation correctness and display sample keys. As a general rule, keys should be chosen randomly, except possibly the request and control keys, which must be entered by the user as a password. -

    The ntp.keys file contains the list of keys and associated key IDs the server knows about (for obvious reasons this file is better left unreadable by anyone except root). The contents of this file might look like:

    -
    -     # ntp keys file (ntp.keys)
    -     1    N   
    -29233E0461ECD6AE    # DES key in NTP format
    -     2    M   
    -RIrop8KPPvQvYotM    # md5 key as an ASCII random string
    -     14   M   
    -sundial           
    -;  # md5 key as an ASCII string
    -     15   A   
    -sundial           
    -;  # DES key as an ASCII string
    -
    -     # the following 3 keys are identical
    -
    -     10   A    SeCReT
    -     10   N   
    -d3e54352e5548080
    -     10   S   
    -a7cb86a4cba80101
    -
    - In the keys file the first token on each line indicates the key ID, the second token the format of the key and the third the key itself. There are four key formats. An A indicates a DES key written as a 1- to-8 character string in 7-bit ASCII representation, with each character standing for a key octet (like a Unix password). An S indicates a DES key written as a hex number in the DES standard format, with the low order bit (LSB) of each octet being the (odd) parity bit. An N indicates a DES key again written as a hex number, but in NTP standard format with the high order bit of each octet being the (odd) parity bit (confusing enough?). An M indicates an MD5 key written as a 1-to-31 character ASCII string in the A format. Note that, because of the simple tokenizing routine, the characters ' ', '#', '\t', '\n' and '\0' can't be used in either a DES or MD5 ASCII key. Everything else is fair game, though. Key 0 (zero) is used for special purposes and should not appear in this file. -

    The big trouble with the authentication facility is the keys file. It is a maintenance headache and a security problem. This should be fixed some day. Presumably, this whole bag of worms goes away if/when a generic security regime for the Internet is established. An alternative with NTP Version 4 is the autokey feature, which uses random session keys and public-key cryptography and avoids the key file entirely. While this feature is not completely finished yet, details can be found in the Release Notes page.

    -

    Query Programs

    - Three utility query programs are included with the distribution, ntpq, ntptrace and ntpdc. ntpq is a handy program which sends queries and receives responses using NTP standard mode-6 control messages. Since it uses the standard control protocol specified in RFC- 1305, it may be used with NTP Version 2 and Version 3 implementations for both Unix and Fuzzball, but not Version 1 implementations. It is most useful to query remote NTP implementations to assess timekeeping accuracy and expose bugs in configuration or operation. -

    ntptrace can be used to display the current synchronization path from a selected host through possibly intervening servers to the primary source of synchronization, usually a radio clock. It works with both version 2 and version 3 servers, but not version 1.

    -

    ntpdc is a horrid program which uses NTP private mode-7 control messages to query local or remote servers. The format and contents of these messages are specific to this version of ntpd and some older versions. The program does allow inspection of a wide variety of internal counters and other state data, and hence does make a pretty good debugging tool, even if it is frustrating to use. The other thing of note about ntpdc is that it provides a user interface to the run time reconfiguration facility. See the respective document pages for details on the use of these programs.

    -

    Run-Time Reconfiguration

    - ntpd was written specifically to allow its configuration to be fully modifiable at run time. Indeed, the only way to configure the server is at run time. The configuration file is read only after the rest of the server has been initialized into a running default-configured state. This facility was included not so much for the benefit of Unix, where it is handy but not strictly essential, but rather for dedicated platforms where the feature is more important for maintenance. Nevertheless, run time configuration works very nicely for Unix servers as well. -

    Nearly all of the things it is possible to configure in the configuration file may be altered via NTP mode-7 messages using the ntpdc program. Mode-6 messages may also provide some limited configuration functionality (though the only thing you can currently do with mode-6 messages is set the leap-second warning bits) and the ntpq program provides generic support for the latter. The leap bits that can be set in the leap_warning variable (up to one month ahead) and in the leap_indication variable have a slightly different encoding than the usual interpretation:

    -
    -       
    -Value           Action
    -
    -        
    -00            
    -p; The daemon passes the leap bits of its
    -            
    -           
    -synchronisation source (usual mode of operation)
    -
    -        01/10   A leap
    -second is added/deleted
    -
    -        
    -11            
    -p; Leap information from the synchronization source
    -            
    -            is
    -ignored (thus LEAP_NOWARNING is passed on)
    -
    - Mode-6 and mode-7 messages which would modify the configuration of the server are required to be authenticated using standard NTP authentication. To enable the facilities one must, in addition to specifying the location of a keys file, indicate in the configuration file the key IDs to be used for authenticating reconfiguration commands. Hence the following fragment might be added to a configuration file to enable the mode-6 (ntpq) and mode-7 (ntpdc) facilities in the daemon: -
    -     # specify mode-6 and mode-7 trusted keys
    -
    -     requestkey 65535    # for mode-7
    -requests
    -     controlkey 65534    # for mode-6
    -requests
    -
    - If the requestkey and/or the controlkey configuration declarations are omitted from the configuration file, the corresponding run-time reconfiguration facility is disabled. -

    The query programs require the user to specify a key ID and a key to use for authenticating requests to be sent. The key ID provided should be the same as the one mentioned in the configuration file, while the key should match that corresponding to the key ID in the keys file. As the query programs prompt for the key as a password, it is useful to make the request and control authentication keys typeable (in ASCII format) from the keyboard.

    -

    Name Resolution

    - ntpd includes the capability to specify host names requiring resolution in peer and server declarations in the configuration file. However, in some outposts of the Internet, name resolution is unreliable and the interface to the Unix resolver routines is synchronous. The hangups and delays resulting from name-resolver clanking can be unacceptable once the NTP server is running (and remember it is up and running before the configuration file is read). However, it is advantageous to resolve time server names, since their addresses are occasionally changed. -

    In order to prevent configuration delays due to the name resolver, the daemon runs the name resolution process in parallel with the main daemon code. When the daemon comes across a peer or server entry with a non-numeric host address, it records the relevant information in a temporary file and continues on. When the end of the configuration file has been reached and one or more entries requiring name resolution have been found, the server runs the name resolver from the temporary file. The server then continues on normally but with the offending peers/servers omitted from its configuration.

    -

    As each name is resolved, it configures the associated entry into the server using the same mode-7 run time reconfiguration facility that ntpdc uses. If temporary resolver failures occur, the resolver will periodically retry the requests until a definite response is received. The program will continue to run until all entries have been resolved.

    -

    Dealing with Frequency Tolerance Violations (tickadj and Friends)

    - The NTP Version 3 specification RFC-1305 calls for a maximum oscillator frequency tolerance of +-100 parts-per-million (PPM), which is representative of those components suitable for use in relatively inexpensive workstation platforms. For those platforms meeting this tolerance, NTP will automatically compensate for the frequency errors of the individual oscillator and no further adjustments are required, either to the configuration file or to various kernel variables. For the NTP Version 4 release, this tolerance has been increased to +-500 PPM. -

    However, in the case of certain notorious platforms, in particular Sun 4.1.1 systems, the performance can be improved by adjusting the values of certain kernel variables; in particular, tick and tickadj. The variable tick is the increment in microseconds added to the system time on each interval- timer interrupt, while the variable tickadj is used by the time adjustment code as a slew rate, in microseconds per tick. When the time is being adjusted via a call to the system routine adjtime(), the kernel increases or reduces tick by tickadj microseconds per tick until the specified adjustment has been completed. Unfortunately, in most Unix implementations the tick increment must be either zero or plus/minus exactly tickadj microseconds, meaning that adjustments are truncated to be an integral multiple of tickadj (this latter behaviour is a misfeature, and is the only reason the tickadj code needs to concern itself with the internal implementation of tickadj at all). In addition, the stock Unix implementation considers it an error to request another adjustment before a prior one has completed.

    -

    Thus, to make very sure it avoids problems related to the roundoff, the tickadj program can be used to adjust the values of tick and tickadj. This ensures that all adjustments given to adjtime() are an even multiple of tickadj microseconds and computes the largest adjustment that can be completed in the adjustment interval (using both the value of tick and the value of tickadj) so it can avoid exceeding this limit. It is important to note that not all systems will allow inspection or modification of kernel variables other than at system build time. It is also important to know that, with the current NTP tolerances, it is rarely necessary to make these changes, but in many cases they will substantially improve the general accuracy of the time service.

    -

    Unfortunately, the value of tickadj set by default is almost always too large for ntpd. NTP operates by continuously making small adjustments to the clock, usually at one-second intervals. If tickadj is set too large, the adjustments will disappear in the roundoff; while, if tickadj is too small, NTP will have difficulty if it needs to make an occasional large adjustment. While the daemon itself will read the kernel's values of these variables, it will not change the values, even if they are unsuitable. You must do this yourself before the daemon is started using the tickadj program included in the ./util directory of the distribution. Note that the latter program will also compute an optimal value of tickadj for NTP use based on the kernel's value of tick.

    -

    The tickadj program can reset several other kernel variables if asked. It can change the value of tick if asked. This is handy to compensate for kernel bugs which cause the clock to run with a very large frequency error, as with SunOS 4.1.1 systems. It can also be used to set the value of the kernel dosynctodr variable to zero. This variable controls whether to synchronize the system clock to the time-of-day clock, something you really don't want to be happen when ntpd is trying to keep it under control. In some systems, such as recent Sun Solaris kernels, the dosynctodr variable is the only one that can be changed by the tickadj program. In this and other modern kernels, it is not necessary to change the other variables in any case.

    -

    We have a report that says starting with Solaris 2.6 we should leave dosynctodr alone.

    -

    In order to maintain reasonable correctness bounds, as well as reasonably good accuracy with acceptable polling intervals, ntpd will complain if the frequency error is greater than 500 PPM. For machines with a value of tick in the 10-ms range, a change of one in the value of tick will change the frequency by about 100 PPM. In order to determine the value of tick for a particular CPU, disconnect the machine from all sources of time (dosynctodr = 0) and record its actual time compared to an outside source (eyeball-and-wristwatch will do) over a day or more. Multiply the time change over the day by 0.116 and add or subtract the result to tick, depending on whether the CPU is fast or slow. An example call to tickadj useful on SunOS 4.1.1 is:

    -
    -     tickadj -t 9999 -a 5 -s
    -
    - which sets tick 100 PPM fast, tickadj to 5 microseconds and turns off the clock/calendar chip fiddle. This line can be added to the rc.local configuration file to automatically set the kernel variables at boot time. -

    All this stuff about diddling kernel variables so the NTP daemon will work is really silly. If vendors would ship machines with clocks that kept reasonable time and would make their adjtime() system call apply the slew it is given exactly, independent of the value of tickadj, all this could go away. This is in fact the case on many current Unix systems.

    -

    Tuning Your Subnet

    - There are several parameters available for tuning the NTP subnet for maximum accuracy and minimum jitter. One of these is the prefer configuration declaration described in Mitigation Rules and the prefer Keyword documentation page. When more than one eligible server exists, the NTP clock-selection and combining algorithms act to winnow out all except the "best" set of servers using several criteria based on differences between the readings of different servers and between successive readings of the same server. The result is usually a set of surviving servers that are apparently statistically equivalent in accuracy, jitter and stability. The population of survivors remaining in this set depends on the individual server characteristics measured during the selection process and may vary from time to time as the result of normal statistical variations. In LANs with high speed RISC-based time servers, the population can become somewhat unstable, with individual servers popping in and out of the surviving population, generally resulting in a regime called clockhopping. -

    When only the smallest residual jitter can be tolerated, it may be convenient to elect one of the servers at each stratum level as the preferred one using the keyword prefer on the configuration declaration for the selected server:

    -
    -     # preferred server declaration
    -
    -     peer rackety.udel.edu prefer   
    -# preferred server
    -
    - The preferred server will always be included in the surviving population, regardless of its characteristics and as long as it survives preliminary sanity checks and validation procedures. -

    The most useful application of the prefer keyword is in high speed LANs equipped with precision radio clocks, such as a GPS receiver. In order to insure robustness, the hosts need to include outside peers as well as the GPS-equipped server; however, as long as that server is running, the synchronization preference should be that server. The keyword should normally be used in all cases in order to prefer an attached radio clock. It is probably inadvisable to use this keyword for peers outside the LAN, since it interferes with the carefully crafted judgement of the selection and combining algorithms.

    -

    Provisions for Leap Seconds and Accuracy Metrics

    - ntpd understands leap seconds and will attempt to take appropriate action when one occurs. In principle, every host running ntpd will insert a leap second in the local timescale in precise synchronization with UTC. This requires that the leap-warning bits be activated some time prior to the occurrence of a leap second at the primary (stratum 1) servers. Subsequently, these bits are propagated throughout the subnet depending on these servers by the NTP protocol itself and automatically implemented by ntpd and the time- conversion routines of each host. The implementation is independent of the idiosyncrasies of the particular radio clock, which vary widely among the various devices, as long as the idiosyncratic behavior does not last for more than about 20 minutes following the leap. Provisions are included to modify the behavior in cases where this cannot be guaranteed. While provisions for leap seconds have been carefully crafted so that correct timekeeping immediately before, during and after the occurrence of a leap second is scrupulously correct, stock Unix systems are mostly inept in responding to the available information. This caveat goes also for the maximum-error and statistical-error bounds carefully calculated for all clients and servers, which could be very useful for application programs needing to calibrate the delays and offsets to achieve a near- simultaneous commit procedure, for example. While this information is maintained in the ntpd data structures, there is at present no way for application programs to access it. This may be a topic for further development. -

    Clock Support Overview

    - ntpd was designed to support radio (and other external) clocks and does some parts of this function with utmost care. Clocks are treated by the protocol as ordinary NTP peers, even to the point of referring to them with an (invalid) IP host address. Clock addresses are of the form 127.127.t.u, where t specifies the particular type of clock (i.e., refers to a particular clock driver) and u is a unit number whose interpretation is clock-driver dependent. This is analogous to the use of major and minor device numbers by Unix and permits multiple instantiations of clocks of the same type on the same server, should such magnificent redundancy be required. -

    Because clocks look much like peers, both configuration file syntax and run time reconfiguration commands can be used to control clocks in the same way as ordinary peers. Clocks are configured via server declarations in the configuration file, can be started and stopped using ntpdc and are subject to address-and-mask restrictions much like a normal peer, should this stretch of imagination ever be useful. As a concession to the need to sometimes transmit additional information to clock drivers, an additional configuration file is available: the fudge statement. This enables one to specify the values of two time quantities, two integral values and two flags, the use of which is dependent on the particular clock driver. For example, to configure a PST radio clock which can be accessed through the serial device /dev/pst1, with propagation delays to WWV and WWVH of 7.5 and 26.5 milliseconds, respectively, on a machine with an imprecise system clock and with the driver set to disbelieve the radio clock once it has gone 30 minutes without an update, one might use the following configuration file entries:

    -
    -     # radio clock fudge fiddles
    -     server 127.127.3.1
    -     fudge 127.127.3.1 time1 0.0075 time2 0.0265
    -     fudge 127.127.3.1 value2 30 flag1 1
    -
    - Additional information on the interpretation of these data with respect to various radio clock drivers is given in the Reference Clock Drivers document page and in the individual driver documents accessible via that page. -

    Towards the Ultimate Tick

    - This section considers issues in providing precision time synchronization in NTP subnets which need the highest quality time available in the present technology. These issues are important in subnets supporting real-time services such as distributed multimedia conferencing and wide-area experiment control and monitoring. -

    In the Internet of today synchronization paths often span continents and oceans with moderate to high variations in delay due to traffic spasms. NTP is specifically designed to minimize timekeeping jitter due to delay variations using intricately crafted filtering and selection algorithms; however, in cases where these variations are as much as a second or more, the residual jitter following these algorithms may still be excessive. Sometimes, as in the case of some isolated NTP subnets where a local source of precision time is available, such as a PPS signal produced by a calibrated cesium clock, it is possible to remove the jitter and retime the local clock oscillator of the NTP server. This has turned out to be a useful feature to improve the synchronization quality of time distributed in remote places where radio clocks are not available. In these cases special features of the distribution are used together with the PPS signal to provide a jitter-free timing signal, while NTP itself is used to provide the coarse timing and resolve the seconds numbering.

    -

    Most available radio clocks can provide time to an accuracy in the order of milliseconds, depending on propagation conditions, local noise levels and so forth. However, as a practical matter, all clocks can occasionally display errors significantly exceeding nominal specifications. Usually, the algorithms used by NTP for ordinary network peers, as well as radio clock peers will detect and discard these errors as discrepancies between the disciplined local clock oscillator and the decoded time message produced by the radio clock. Some radio clocks can produce a special PPS signal which can be interfaced to the server platform in a number of ways and used to substantially improve the (disciplined) clock oscillator jitter and wander characteristics by at least an order of magnitude. Using these features it is possible to achieve accuracies in the order of a few tens of microseconds with a fast RISC- based platform.

    -

    There are three ways to implement PPS support, depending on the radio clock model, platform model and serial line interface. These are described in detail in the application notes mentioned in the The Network Time Protocol (NTP) Distribution document page. Each of these requires circuitry to convert the TTL signal produced by most clocks to the EIA levels used by most serial interfaces. The Pulse-per-second (PPS) Signal Interfacing page describes a device designed to do this. Besides being useful for this purpose, this device includes an inexpensive modem designed for use with the Canadian CHU time/frequency radio station.

    -

    In order to select the appropriate implementation, it is important to understand the underlying PPS mechanism used by ntpd. The PPS support depends on a continuous source of PPS pulses used to calculate an offset within +-500 milliseconds relative to the local clock. The serial timecode produced by the radio or the time determined by NTP in absence of the radio is used to adjust the local clock within +-128 milliseconds of the actual time. As long as the local clock is within this interval the PPS support is used to discipline the local clock and the timecode used only to verify that the local clock is in fact within the interval. Outside this interval the PPS support is disabled and the timecode used directly to control the local clock.

    -

    Parting Shots

    - There are several undocumented programs which can be useful in unusual cases. They can be found in the ./clockstuff and ./authstuff directories of the distribution. One of these is the propdelay program, which can compute high frequency radio propagation delays between any two points whose latitude and longitude are known. The program understands something about the phenomena which allow high frequency radio propagation to occur, and will generally provide a better estimate than a calculation based on the great circle distance. Other programs of interest include clktest, which allows one to exercise the generic clock line discipline, and chutest, which runs the basic reduction algorithms used by the daemon on data received from a serial port.  -
    -
    - gif
    -
    - - - - diff -urN src/contrib/ntp/html/ntp_conf.html src.ntp/contrib/ntp/html/ntp_conf.html --- src/contrib/ntp/html/ntp_conf.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/ntp_conf.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,173 +0,0 @@ - - - - - - - - Configuration File Definition (Advanced) - - - - -

    Configuration File Definition (Advanced)

    - giffrom Pogo, Walt Kelly -

    A typical NTP monitoring packet

    -

    Last update: 19:46 UTC Friday, June 16, 2006

    -
    -
    -

    Table of Contents

    - -

    Synopsis

    -

    The NTP configuration process is driven by a phrase-structure grammar which is used to specify the format of the configuration commands and the actions needed to build an abstract syntax tree (AST). The grammar is fed to a parser generator (Bison) which produces a parser for the configuration file.

    -

    The generated parser is used to parse an NTP configuration file and check it for syntax and semantic errors. The result of the parse is an AST, which contains a representation of the various commands and options. This AST is then traversed to set up the NTP daemon to the correct configuration.

    -

    This document is intended for developers who wish to modify the configuration code and/or add configuration commands and options. It contains a description of the files used in the configuration process as well as guidelines on how to construct them.

    -

    Files

    -

    A brief description of the files used by the configuration code is given below:

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    FileDescription
    ntp_config.yThis file is a Bison source file that contains the phrase-structure grammar and the actions that need to be performed to generate an AST.
    ntp_config.cThis file contains the major chunk of the configuration code. It contains all the functions that are called for building the AST as well as the functions that are needed for traversing the AST.
    ntp_config.hThis file is the header file for ntp_config.c. It mainly contains the structure definitions needed to build the AST.
    ntp_scanner.cThis file contains the code for a simple lexical analyzer. This file is directly included into the ntp_config.c file since this code is only used by the configuration code. The most important function in this file is yylex, which is called by the generated parser to get the next token on the input line.
    ntp_data_structures.cThis file contains a generic implementation of a priority queue and a simple queue. This code can be used to create a queue for any structure.
    ntp_data_structures.hThis header file contains the structure declarations and function prototypes needed to use the data structures defined in ntp_data_structures.c. This file forms the public interface of the data structures.
    ntp_config.tab.cThis file is generated by Bison from the ntp_config.y file. This file is also included directly into the configuration code.
    -

    High-Level Description

    -

    A high-level description of the configuration process showing where all the files fit in is given below:

    -

    JPEG

    -

    The scanner reads in an NTP configuration file and converts it into tokens. The Bison generated parser reads these tokens and converts them into an AST. The AST traverser consists of a set of functions that configure parts of NTP on the basis of what is on the tree. A more detailed description of these parts and the files used is given below:

    -

    Detailed Description

    -
    -
    ntp_scanner.c -
    This file contains the scanner. The scanner is a small program that converts an input NTP configuration file into a set of tokens that correspond to lexemes in the input. Lexemes are strings in the input, delimited by whitespace and/or special characters. Tokens are basically unique integers that represent these lexemes. A different token is generated for each reserved word and special character in the input. There are two main functions in the public interface of this file: -
    int yylex() -
    This function is called yylex for historical reasons; lex is a program that takes a set of regular expressions and generates a scanner that returns tokens corresponding to those regular expressions. The name of the generated function is called yylex. We aren't using lex because it requires linking against an external library and we didn't want to increase the compile-time requirements of NTP. -
    History lessons aside, this function basically checks to see if the next input character is a special character as defined in the array char special_char[]. (The function int is_special(char ch), can be used for this.) If yes, the special character is returned as the token. If not, a set of characters is read until the next whitespace or special character is encountered. This set of characters forms the lexeme; yylex then checks whether this lexeme is an integer, a double, an IP address or a reserved word. If yes, the corresponding token is returned. If not, a token for a string is returned as the default token. -
    struct state *create_keyword_scanner(struct key_tok *keyword_list) -
    This function takes a list of (keyword, token) pairs and converts them into a trie that can recognize the keywords (reserved words). Every time the scanner reads a lexeme, it compares it against the list of reserved words. If it finds a match, it returns the corresponding token for that keyword. -
    ntp_data_structures.c -
    This file contains an implementation of a generic priority queue and FIFO queue. By generic, we mean that these queues can hold element of any type (integers, user-defined structs, etc.), provided that these elements are allocated on the heap using the function void *get_node(size_t size). Note that the prototype for this function is exactly the same as that of malloc and that it can be used in the exact same way. Behind the scenes, get_node calls malloc to allocate size plus some extra memory needed for bookkeeping. The allocated memory can be freed using the function void free_node (void *my_node). In addition to these two functions, the public interface of this file contains the following functions: -
    queue *create_priority_queue(int (*get_order)(void *, void*)) -
    This function creates a priority queue in which the order of the elements is determined by the get_order function that is passed as input to the priority queue. The get_order function should return positive if the priority of the first element is less than the priority of the second element. -
    queue *create_queue(void) -
    This function creates a FIFO queue. It basically calls the create_priority_queue function with the get_fifo_order function as its argument. -
    void destroy_queue(queue *my_queue) -
    This function deletes my_queue and frees up all the memory allocated to it an its elements. -
    int empty(queue *my_queue) -
    This function checks to see if my_queue is empty. Returns true if my_queue does not have any elements, else it returns false. -
    queue *enqueue(queue *my_queue, void *my_node) -
    This function adds an element, my_node, to a queue, my_queue. my_node must be allocated on the heap using the get_node function instead of malloc. -
    void *dequeue(queue *my_queue) -
    This function returns the element at the front of the queue. This element will be element with the highest priority. -
    int get_no_of_elements(queue *my_queue) -
    This function returns the number of elements in my_queue. -
    void append_queue(queue *q1, queue *q2) -
    This function adds all the elements of q2 to q1. The queue q2 is destroyed in the process. -
    ntp_config.y -
    This file is structured as a standard Bison file and consists of three main parts, separated by %%: -
    -
      -
    1. The prologue and bison declarations: This section contains a list of the terminal symbols, the non-terminal symbols and the types of these symbols.
    2. The rules section: This section contains a description of the actual phrase-structure rules that are used to parse the configuration commands. Each rule consists of a left-hand side (LHS), a right-hand side (RHS) and an optional action. As is standard with phrase-structure grammars, the LHS consists of a single non-terminal symbol. The RHS can contain both terminal and non-terminal symbols, while the optional action can consist of any arbitrary C code. -
    3. The epilogue: This section is left empty on purpose. It is traditionally used to code the support functions needed to build the ASTs Since, we have moved all the support functions to ntp_config.c, this section is left empty. -
    -

    Prologue and Bison Declarations

    -

    All the terminal symbols (also known as tokens) have to be declared in the prologue section. Note that terminals and non-terminals may have values associated with them and these values have types. (More on this later). An unnamed union has to be declared with all the possible types at the start of the prologue section. For example, we declare the following union at the start of the ntp_config.y file:

    -

    %union {
    -     char *String;
    -     double Double;
    -     int Integer;
    -     void *VoidPtr;
    -     queue *Queue;
    -     struct attr_val *Attr_val;
    -     struct address_node *Address_node;
    -     struct setvar_node *Set_var;
    -     /* Simulation types */
    -     server_info *Sim_server;
    -     script_info *Sim_script;
    - }

    -

    Some tokens may not have any types. For example, tokens that correspond to reserved words do not usually have types as they simply indicate that a reserved word has been read in the input file. Such tokens have to be declared as follows:

    -

    %token T_Discard
    - %token T_Dispersion

    -

    Other tokens do have types. For example, a T_Double token is returned by the scanner whenever it sees a floating-point double in the configuration file. The value associated with the token is the actual number that was read in the configuration file and its type (after conversion) is double. Hence, the token T_Double will have to be declared as follows in the prologue of ntp_config.y file:

    -

    %token <Double> T_Double

    -

    Note that the declaration given in the angled brackets is not double but Double, which is the name of the variable given in the %union {} declaration above.

    -

    Finally, non-terminal symbols may also have values associated with them, which have types. This is because Bison allows non-terminal symbols to have actions associated with them. Actions may be thought of as small functions which get executed whenever the RHS of a non-terminal is detected. The return values of these functions are the values associated with the non-terminals. The types of the non-terminals are specified with a %type declaration as shown below:

    -

    %type <Queue> address_list
    - %type <Integer> boolean

    -

    The %type declaration may be omitted for non-terminals that do not return any value and do not have type information associated with them.

    -

    The Rules Section

    -

    The rule section only consists of phrase-structure grammar rules. Each rule typically has the following format:

    -

    LHS : RHS [{ Actions }]
    -     ;

    -

    where LHS consists of a single non-terminal symbol and the RHS consists of one or more terminal and non-terminal symbols. The Actions are optional and may consist of any number of arbitrary C statements. Note that Bison can only process LALR(1) grammars, which imposes additional restrictions on the kind of rules that can be specified. Examples of rules are shown below:

    -

    orphan_mode_command
    -     : T_Tos tos_option_list
    -         { append_queue(my_config.orphan_cmds, $2); }
    -     ;

    -

    tos_option_list
    -     : tos_option_list tos_option { $$ = enqueue($1, $2); }
    -     | tos_option { $$ = enqueue_in_new_queue($1); }
    -     ;

    -

    The $n notation, where n is an integer, is used to refer to the value of a terminal or non-terminal symbol. All terminals and non-terminal symbols within a particular rule are numbered (starting from 1) according to the order in which they appear within the RHS of a rule. $$ is used to refer to the value of the LHS terminal symbol - it is used to return a value for the non-terminal symbol specified in the LHS of the rule.

    -

    Invoking Bison

    -

    Bison needs to be invoked in order to convert the ntp_config.y file into a C source file. To invoke Bison, simply enter the command:

    -

    bison ntp_config.y

    -

    at the command prompt. If no errors are detected, an ntp_config.tab.c file will be generated by default. This generated file can be directly included into the ntp_config.c file.

    -

    If Bison report shift-reduce errors or reduce-reduce errors, it means that the grammar specified using the rules in not LALR(1). To debug such a grammar, invoke Bison with a -v switch, as shown below. This will generate a ntp_config.output file, which will contain a description of the generated state machine, together with a list of states that have shift-reduce/reduce-reduce conflicts. You can then change the rules to remove such conflicts.

    -

    bison -v ntp_config.y

    -

    For more information, refer to the Bison manual.

    -

    ntp_config.c

    -

    This file contains the major chunk of the configuration code including all the support functions needed for building and traversing the ASTs. As such, most of the functions in this file can be divided into two groups:

    -
      -
    1. Functions that have a create_ prefix. These functions are used to build a node of the AST. -
    2. Functions that have a config_ prefix. These functions are used to traverse the AST and configure NTP according to the nodes present on the tree. -
    -

    Guidelines for Adding Configuration Commands

    -

    The following steps may be used to add a new configuration command to the NTP reference implementation:

    -
      -
    1. Write phrase-structure grammar rules for the syntax of the new command. Add these rules to the rules section of the ntp_config.y file. -
    2. Write the action to be performed on recognizing the rules. These actions will be used to build the AST. -
    3. If new reserved words are needed, add these to the struct key_tok keyword_list[]structure in the ntp_config.c file. This will allow the scanner to recognize these reserved words and generate the desired tokens on recognizing them. -
    4. Specify the types of all the terminals and non-terminal symbols in the prologue section of the ntp_config.c file. -
    5. Write a function with a config_ prefix that will be executed for this new command. Make sure this function is called in the config_ntpd()function. -
    -
    -
    Sachin Kamboj
    - - - - diff -urN src/contrib/ntp/html/ntpd.html src.ntp/contrib/ntp/html/ntpd.html --- src/contrib/ntp/html/ntpd.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/ntpd.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,185 +0,0 @@ - - - - - - - - ntpd - Network Time Protocol (NTP) daemon - - - - -

    ntpd - Network Time Protocol (NTP) daemon

    - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

    The mushroom knows all the command line options.

    -

    Last update: 18:44 UTC Thursday, July 28, 2005

    -
    -

    Related Links

    - -

    Table of Contents

    - -
    -

    Synopsis

    - ntpd [ -46aAbdDgLmnNqx ] [ -c conffile ] [ -f driftfile ] [ -i jaildir ] [ -k keyfile ] [ -l logfile ] [ -p pidfile ] [ -P priority ] [ -r broadcastdelay ] [ -s statsdir ] [ -t key ] [ -u user[:group] ] [ -U interface_update_interval ] [ -v variable ] [ -V variable ] -

    Description

    -

    The ntpd program is an operating system daemon which sets and maintains the system time of day in synchronism with Internet standard time servers. It is a complete implementation of the Network Time Protocol (NTP) version 4, but also retains compatibility with version 3, as defined by RFC-1305, and version 1 and 2, as defined by RFC-1059 and RFC-1119, respectively. ntpd does most computations in 64-bit floating point arithmetic and does relatively clumsy 64-bit fixed point operations only when necessary to preserve the ultimate precision, about 232 picoseconds. While the ultimate precision is not achievable with ordinary workstations and networks of today, it may be required with future gigahertz CPU clocks and gigabit LANs.

    -

    How NTP Operates

    -

    The ntpd program operates by exchanging messages with one or more configured servers at designated poll intervals. When started, whether for the first or subsequent times, the program requires several exchanges from the majority of these servers so the signal processing and mitigation algorithms can accumulate and groom the data and set the clock. In order to protect the network from bursts, the initial poll interval for each server is delayed an interval randomized over a few seconds. At the default initial poll interval of 64s, several minutes can elapse before the clock is set. The initial delay to set the clock can be reduced using the iburst keyword with the server configuration command, as described on the Configuration Options page.

    -

    Most operating systems and hardware of today incorporate a time-of-year (TOY) chip to maintain the time during periods when the power is off. When the machine is booted, the chip is used to initialize the operating system time. After the machine has synchronized to a NTP server, the operating system corrects the chip from time to time. In case there is no TOY chip or for some reason its time is more than 1000s from the server time, ntpd assumes something must be terribly wrong and the only reliable action is for the operator to intervene and set the clock by hand. This causes ntpd to exit with a panic message to the system log. The -g option overrides this check and the clock will be set to the server time regardless of the chip time. However, and to protect against broken hardware, such as when the CMOS battery fails or the clock counter becomes defective, once the clock has been set, an error greater than 1000s will cause ntpd to exit anyway.

    -

    Under ordinary conditions, ntpd adjusts the clock in small steps so that the timescale is effectively continuous and without discontinuities. Under conditions of extreme network congestion, the roundtrip delay jitter can exceed three seconds and the synchronization distance, which is equal to one-half the roundtrip delay plus error budget terms, can become very large. The ntpd algorithms discard sample offsets exceeding 128 ms, unless the interval during which no sample offset is less than 128 ms exceeds 900s. The first sample after that, no matter what the offset, steps the clock to the indicated time. In practice this reduces the false alarm rate where the clock is stepped in error to a vanishingly low incidence.

    -

    As the result of this behavior, once the clock has been set, it very rarely strays more than 128 ms, even under extreme cases of network path congestion and jitter. Sometimes, in particular when ntpd is first started, the error might exceed 128 ms. This may on occasion cause the clock to be set backwards if the local clock time is more than 128 s in the future relative to the server. In some applications, this behavior may be unacceptable. If the -x option is included on the command line, the clock will never be stepped and only slew corrections will be used.

    -

    The issues should be carefully explored before deciding to use the -x option. The maximum slew rate possible is limited to 500 parts-per-million (PPM) as a consequence of the correctness principles on which the NTP protocol and algorithm design are based. As a result, the local clock can take a long time to converge to an acceptable offset, about 2,000 s for each second the clock is outside the acceptable range. During this interval the local clock will not be consistent with any other network clock and the system cannot be used for distributed applications that require correctly synchronized network time.

    -

    In spite of the above precautions, sometimes when large frequency errors are present the resulting time offsets stray outside the 128-ms range and an eventual step or slew time correction is required. If following such a correction the frequency error is so large that the first sample is outside the acceptable range, ntpd enters the same state as when the ntp.drift file is not present. The intent of this behavior is to quickly correct the frequency and restore operation to the normal tracking mode. In the most extreme cases (time.ien.it comes to mind), there may be occasional step/slew corrections and subsequent frequency corrections. It helps in these cases to use the burst keyword when configuring the server.

    -

    Frequency Discipline

    -

    The ntpd behavior at startup depends on whether the frequency file, usually ntp.drift, exists. This file contains the latest estimate of clock frequency error. When the ntpd is started and the file does not exist, the ntpd enters a special mode designed to quickly adapt to the particular system clock oscillator time and frequency error. This takes approximately 15 minutes, after which the time and frequency are set to nominal values and the ntpd enters normal mode, where the time and frequency are continuously tracked relative to the server. After one hour the frequency file is created and the current frequency offset written to it. When the ntpd is started and the file does exist, the ntpd frequency is initialized from the file and enters normal mode immediately. After that the current frequency offset is written to the file at hourly intervals.

    -

    Operating Modes

    -

    ntpd can operate in any of several modes, including symmetric active/passive, client/server broadcast/multicast and manycast, as described in the Association Management page. It normally operates continuously while monitoring for small changes in frequency and trimming the clock for the ultimate precision. However, it can operate in a one-time mode where the time is set from an external server and frequency is set from a previously recorded frequency file. A broadcast/multicast or manycast client can discover remote servers, compute server-client propagation delay correction factors and configure itself automatically. This makes it possible to deploy a fleet of workstations without specifying configuration details specific to the local environment.

    -

    By default, ntpd runs in continuous mode where each of possibly several external servers is polled at intervals determined by an intricate state machine. The state machine measures the incidental roundtrip delay jitter and oscillator frequency wander and determines the best poll interval using a heuristic algorithm. Ordinarily, and in most operating environments, the state machine will start with 64s intervals and eventually increase in steps to 1024s. A small amount of random variation is introduced in order to avoid bunching at the servers. In addition, should a server become unreachable for some time, the poll interval is increased in steps to 1024s in order to reduce network overhead.

    -

    In some cases it may not be practical for ntpd to run continuously. A common workaround has been to run the ntpdate program from a cron job at designated times. However, this program does not have the crafted signal processing, error checking and mitigation algorithms of ntpd. The -q option is intended for this purpose. Setting this option will cause ntpd to exit just after setting the clock for the first time. The procedure for initially setting the clock is the same as in continuous mode; most applications will probably want to specify the iburst keyword with the server configuration command. With this keyword a volley of messages are exchanged to groom the data and the clock is set in about 10 s. If nothing is heard after a couple of minutes, the daemon times out and exits. After a suitable period of mourning, the ntpdate program may be retired.

    -

    When kernel support is available to discipline the clock frequency, which is the case for stock Solaris, Tru64, Linux and FreeBSD, a useful feature is available to discipline the clock frequency. First, ntpd is run in continuous mode with selected servers in order to measure and record the intrinsic clock frequency offset in the frequency file. It may take some hours for the frequency and offset to settle down. Then the ntpd is stopped and run in one-time mode as required. At each startup, the frequency is read from the file and initializes the kernel frequency.

    -

    Poll Interval Control

    -

    This version of NTP includes an intricate state machine to reduce the network load while maintaining a quality of synchronization consistent with the observed jitter and wander. There are a number of ways to tailor the operation in order enhance accuracy by reducing the interval or to reduce network overhead by increasing it. However, the user is advised to carefully consider the consequences of changing the poll adjustment range from the default minimum of 64 s to the default maximum of 1,024 s. The default minimum can be changed with the tinker minpoll command to a value not less than 16 s. This value is used for all configured associations, unless overridden by the minpoll option on the configuration command. Note that most device drivers will not operate properly if the poll interval is less than 64 s and that the broadcast server and manycast client associations will also use the default, unless overridden.

    -

    In some cases involving dial up or toll services, it may be useful to increase the minimum interval to a few tens of minutes and maximum interval to a day or so. Under normal operation conditions, once the clock discipline loop has stabilized the interval will be increased in steps from the minimum to the maximum. However, this assumes the intrinsic clock frequency error is small enough for the discipline loop correct it. The capture range of the loop is 500 PPM at an interval of 64s decreasing by a factor of two for each doubling of interval. At a minimum of 1,024 s, for example, the capture range is only 31 PPM. If the intrinsic error is greater than this, the drift file ntp.drift will have to be specially tailored to reduce the residual error below this limit. Once this is done, the drift file is automatically updated once per hour and is available to initialize the frequency on subsequent daemon restarts.

    -

    The huff-n'-puff Filter

    -

    In scenarios where a considerable amount of data are to be downloaded or uploaded over telephone modems, timekeeping quality can be seriously degraded. This occurs because the differential delays on the two directions of transmission can be quite large. In many cases the apparent time errors are so large as to exceed the step threshold and a step correction can occur during and after the data transfer is in progress.

    -

    The huff-n'-puff filter is designed to correct the apparent time offset in these cases. It depends on knowledge of the propagation delay when no other traffic is present. In common scenarios this occurs during other than work hours. The filter maintains a shift register that remembers the minimum delay over the most recent interval measured usually in hours. Under conditions of severe delay, the filter corrects the apparent offset using the sign of the offset and the difference between the apparent delay and minimum delay. The name of the filter reflects the negative (huff) and positive (puff) correction, which depends on the sign of the offset.

    -

    The filter is activated by the tinker command and huffpuff keyword, as described in the Miscellaneous Options page.

    -

    Notes

    -

    If NetInfo support is built into ntpd, then ntpd will attempt to read its configuration from the NetInfo if the default ntp.conf file cannot be read and no file is specified by the -c option.

    -

    In contexts where a host name is expected, a -4 qualifier preceding the host name forces DNS resolution to the IPv4 namespace, while a -6 qualifier forces DNS resolution to the IPv6 namespace.

    -

    Various internal ntpd variables can be displayed and configuration options altered while the ntpd is running using the ntpq and ntpdc utility programs.

    -

    When ntpd starts it looks at the value of umask, and if zero ntpd will set the umask to 022.

    -

    Command Line Options

    -
    -
    -a -
    Require cryptographic authentication for broadcast client, multicast client and symmetric passive associations. This is the default. -
    -A -
    Do not require cryptographic authentication for broadcast client, multicast client and symmetric passive associations. This is almost never a good idea. -
    -b -
    Enable the client to synchronize to broadcast servers. -
    -c conffile -
    Specify the name and path of the configuration file, default /etc/ntp.conf. -
    -d -
    Specify debugging mode. This option may occur more than once, with each occurrence indicating greater detail of display. -
    -D level -
    Specify debugging level directly. -
    -f driftfile -
    Specify the name and path of the frequency file, default /etc/ntp.drift. This is the same operation as the driftfile driftfile configuration command. -
    -g -
    Normally, ntpd exits with a message to the system log if the offset exceeds the panic threshold, which is 1000 s by default. This option allows the time to be set to any value without restriction; however, this can happen only once. If the threshold is exceeded after that, ntpd will exit with a message to the system log. This option can be used with the -q and -x options. See the tinker command for other options. -
    -i jaildir -
    Chroot the server to the directory jaildir. This option also implies that the server attempts to drop root privileges at startup (otherwise, chroot gives very little additional security), and it is only available if the OS supports to run the server without full root privileges. You may need to also specify a -u option. -
    -k keyfile -
    Specify the name and path of the symmetric key file, default /etc/ntp.keys. This is the same operation as the keys keyfile configuration command. -
    -l logfile -
    Specify the name and path of the log file. The default is the system log file. This is the same operation as the logfile logfile configuration command. -
    -L -
    Do not listen to virtual IPs. The default is to listen. -
    -n -
    Don't fork. -
    -N -
    To the extent permitted by the operating system, run the ntpd at the highest priority. -
    -p pidfile -
    Specify the name and path of the file used to record the ntpd process ID. This is the same operation as the pidfile pidfile configuration command. -
    -P priority -
    To the extent permitted by the operating system, run the ntpd at the specified priority. -
    -q -
    Exit the ntpd just after the first time the clock is set. This behavior mimics that of the ntpdate program, which is to be retired. The -g and -x options can be used with this option. Note: The kernel time discipline is disabled with this option. -
    -r broadcastdelay -
    Specify the default propagation delay from the broadcast/multicast server to this client. This is necessary only if the delay cannot be computed automatically by the protocol. -
    -s statsdir -
    Specify the directory path for files created by the statistics facility. This is the same operation as the statsdir statsdir configuration command. -
    -t key -
    Add a key number to the trusted key list. This option can occur more than once. -
    -u user[:group] -
    Specify a user, and optionally a group, to switch to. This option is only available if the OS supports to run the server without full root privileges. Currently, this option is supported under NetBSD (configure with --enable-clockctl) and Linux (configure with --enable-linuxcaps). -
    -U interface update interval -
    Number of seconds to wait between interface list scans to pick up new and delete network interface. Set to 0 to disable dynamic interface list updating. The default is to scan every 5 minutes.
    -
    -v variable -
    -V variable -
    Add a system variable listed by default. -
    -x -
    Normally, the time is slewed if the offset is less than the step threshold, which is 128 ms by default, and stepped if above the threshold. This option sets the threshold to 600 s, which is well within the accuracy window to set the clock manually. Note: Since the slew rate of typical Unix kernels is limited to 0.5 ms/s, each second of adjustment requires an amortization interval of 2000 s. Thus, an adjustment as much as 600 s will take almost 14 days to complete. This option can be used with the -g and -q options. See the tinker command for other options. Note: The kernel time discipline is disabled with this option. -
    -

    The Configuration File

    -

    Ordinarily, ntpd reads the ntp.conf configuration file at startup time in order to determine the synchronization sources and operating modes. It is also possible to specify a working, although limited, configuration entirely on the command line, obviating the need for a configuration file. This may be particularly useful when the local host is to be configured as a broadcast/multicast client, with all peers being determined by listening to broadcasts at run time.

    -

    Usually, the configuration file is installed in the /etc directory, but could be installed elsewhere (see the -c conffile command line option). The file format is similar to other Unix configuration files - comments begin with a # character and extend to the end of the line; blank lines are ignored.

    -

    Configuration commands consist of an initial keyword followed by a list of arguments, some of which may be optional, separated by whitespace. Commands may not be continued over multiple lines. Arguments may be host names, host addresses written in numeric, dotted-quad form, integers, floating point numbers (when specifying times in seconds) and text strings. Optional arguments are delimited by [ ] in the following descriptions, while alternatives are separated by |. The notation [ ... ] means an optional, indefinite repetition of the last item before the [ ... ].

    -

    Configuration Options

    -

    Server Options
    - Authentication Options
    - Monitoring Options
    - Access Control Options
    - Automatic NTP Configuration Options
    - Reference Clock Options
    - Miscellaneous Options

    -

    Files

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    FileDefaultOptionCommand
    configuration file/etc/ntp.conf-cnone
    frequency file/etc/ntp.drift-fdriftfile
    process ID filenone-ppidfile
    log filesystem log-llogfile
    include filenonenoneincludefile
    statistics path/var/NTP-sstatsdir
    keys path/usr/local/etc-kkeysdir
    -
    - - - - diff -urN src/contrib/ntp/html/ntpdate.html src.ntp/contrib/ntp/html/ntpdate.html --- src/contrib/ntp/html/ntpdate.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/ntpdate.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,72 +0,0 @@ - - - - - - - - ntpdate - set the date and time via NTP - - - - -

    ntpdate - set the date and time via NTP

    - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

    I told you it was eyeball and wristwatch.

    -

    Last update: 18:44 UTC Thursday, July 28, 2005

    -
    -
    -

    Disclaimer: The functionality of this program is now available in the ntpd program. See the -q command line option in the ntpd - Network Time Protocol (NTP) daemon page. After a suitable period of mourning, the ntpdate program is to be retired from this distribution

    -

    Synopsis

    - ntpdate [ -bBdoqsuv ] [ -a key ] [ -e authdelay ] [ -k keyfile ] [ -o version ] [ -p samples ] [ -t timeout ] server [ ... ] -

    Description

    - ntpdate sets the local date and time by polling the Network Time Protocol (NTP) server(s) given as the server arguments to determine the correct time. It must be run as root on the local host. A number of samples are obtained from each of the servers specified and a subset of the NTP clock filter and selection algorithms are applied to select the best of these. Note that the accuracy and reliability of ntpdate depends on the number of servers, the number of polls each time it is run and the interval between runs. -

    ntpdate can be run manually as necessary to set the host clock, or it can be run from the host startup script to set the clock at boot time. This is useful in some cases to set the clock initially before starting the NTP daemon ntpd. It is also possible to run ntpdate from a cron script. However, it is important to note that ntpdate with contrived cron scripts is no substitute for the NTP daemon, which uses sophisticated algorithms to maximize accuracy and reliability while minimizing resource use. Finally, since ntpdate does not discipline the host clock frequency as does ntpd, the accuracy using ntpdate is limited.

    -

    Time adjustments are made by ntpdate in one of two ways. If ntpdate determines the clock is in error more than 0.5 second it will simply step the time by calling the system settimeofday() routine. If the error is less than 0.5 seconds, it will slew the time by calling the system adjtime() routine. The latter technique is less disruptive and more accurate when the error is small, and works quite well when ntpdate is run by cron every hour or two.

    -

    ntpdate will decline to set the date if an NTP server daemon (e.g., ntpd) is running on the same host. When running ntpdate on a regular basis from cron as an alternative to running a daemon, doing so once every hour or two will result in precise enough timekeeping to avoid stepping the clock.

    -

    Note that in contexts where a host name is expected, a -4 qualifier preceding the host name forces DNS resolution to the IPv4 namespace, while a -6 qualifier forces DNS resolution to the IPv6 namespace.

    -

    If NetInfo support is compiled into ntpdate, then the server argument is optional if ntpdate can find a time server in the NetInfo configuration for ntpd.

    -

    Command Line Options

    -
    -
    -4 -
    Force DNS resolution of following host names on the command line to the IPv4 namespace. -
    -6 -
    Force DNS resolution of following host names on the command line to the IPv6 namespace. -
    -a key -
    Enable the authentication function and specify the key identifier to be used for authentication as the argument keyntpdate. The keys and key identifiers must match in both the client and server key files. The default is to disable the authentication function. -
    -B -
    Force the time to always be slewed using the adjtime() system call, even if the measured offset is greater than +-128 ms. The default is to step the time using settimeofday() if the offset is greater than +-128 ms. Note that, if the offset is much greater than +-128 ms in this case, that it can take a long time (hours) to slew the clock to the correct value. During this time. the host should not be used to synchronize clients. -
    -b -
    Force the time to be stepped using the settimeofday() system call, rather than slewed (default) using the adjtime() system call. This option should be used when called from a startup file at boot time. -
    -d -
    Enable the debugging mode, in which ntpdate will go through all the steps, but not adjust the local clock. Information useful for general debugging will also be printed. -
    -e authdelay -
    Specify the processing delay to perform an authentication function as the value authdelay, in seconds and fraction (see ntpd for details). This number is usually small enough to be negligible for most purposes, though specifying a value may improve timekeeping on very slow CPU's. -
    -k keyfile -
    Specify the path for the authentication key file as the string keyfile. The default is /etc/ntp.keys. This file should be in the format described in ntpd. -
    -o version -
    Specify the NTP version for outgoing packets as the integer version, which can be 1 or 2. The default is 3. This allows ntpdate to be used with older NTP versions. -
    -p samples -
    Specify the number of samples to be acquired from each server as the integer samples, with values from 1 to 8 inclusive. The default is 4. -
    -q -
    Query only - don't set the clock. -
    -s -
    Divert logging output from the standard output (default) to the system syslog facility. This is designed primarily for convenience of cron scripts. -
    -t timeout -
    Specify the maximum time waiting for a server response as the value timeout, in seconds and fraction. The value is is rounded to a multiple of 0.2 seconds. The default is 1 second, a value suitable for polling across a LAN. -
    -u -
    Direct ntpdate to use an unprivileged port or outgoing packets. This is most useful when behind a firewall that blocks incoming traffic to privileged ports, and you want to synchronise with hosts beyond the firewall. Note that the -d option always uses unprivileged ports. -
    -v -
    Be verbose. This option will cause ntpdate's version identification string to be logged. -
    -

    Diagnostics

    - ntpdate's exit status is zero if it finds a server and updates the clock, and nonzero otherwise. -

    Files

    - /etc/ntp.keys - encryption keys used by ntpdate. -

    Bugs

    - The slew adjustment is actually 50% larger than the measured offset, since this (it is argued) will tend to keep a badly drifting clock more accurate. This is probably not a good idea and may cause a troubling hunt for some values of the kernel variables tick and tickadj.  -
    - - - - diff -urN src/contrib/ntp/html/ntpdc.html src.ntp/contrib/ntp/html/ntpdc.html --- src/contrib/ntp/html/ntpdc.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/ntpdc.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,215 +0,0 @@ - - - - - - - - ntpdc - special NTP query program - - - - -

    ntpdc - special NTP query program

    - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

    This program is a big puppy.

    -

    Last update: 04:11 AM UTC Monday, November 27, 2006

    -
    -

    More Help

    - -
    -

    Synopsis

    - ntpdc [ -ilnps ] [ -c command ] [ host ] [ ... ] -

    Description

    - ntpdc is used to query the ntpd daemon about its current state and to request changes in that state. The program may be run either in interactive mode or controlled using command line arguments. Extensive state and statistics information is available through the ntpdc interface. In addition, nearly all the configuration options which can be specified at startup using ntpd's configuration file may also be specified at run time using ntpdc. -

    If one or more request options are included on the command line when ntpdc is executed, each of the requests will be sent to the NTP servers running on each of the hosts given as command line arguments, or on localhost by default. If no request options are given, ntpdc will attempt to read commands from the standard input and execute these on the NTP server running on the first host given on the command line, again defaulting to localhost when no other host is specified. ntpdc will prompt for commands if the standard input is a terminal device.

    -

    ntpdc uses NTP mode 7 packets to communicate with the NTP server, and hence can be used to query any compatible server on the network which permits it. Note that since NTP is a UDP protocol this communication will be somewhat unreliable, especially over large distances in terms of network topology. ntpdc makes no attempt to retransmit requests, and will time requests out if the remote host is not heard from within a suitable timeout time.

    -

    The operation of ntpdc are specific to the particular implementation of the ntpd daemon and can be expected to work only with this and maybe some previous versions of the daemon. Requests from a remote ntpdc program which affect the state of the local server must be authenticated, which requires both the remote program and local server share a common key and key identifier.

    -

    Note that in contexts where a host name is expected, a -4 qualifier preceding the host name forces DNS resolution to the IPv4 namespace, while a -6 qualifier forces DNS resolution to the IPv6 namespace.

    -

    Command Line Options

    -

    Specifying a command line option other than -i or -n will cause the specified query (queries) to be sent to the indicated host(s) immediately. Otherwise, ntpdc will attempt to read interactive format commands from the standard input.

    -
    -
    -4 -
    Force DNS resolution of following host names on the command line to the IPv4 namespace. -
    -6 -
    Force DNS resolution of following host names on the command line to the IPv6 namespace. -
    -c command -
    The following argument is interpreted as an interactive format command and is added to the list of commands to be executed on the specified host(s). Multiple -c options may be given. -
    -i -
    Force ntpdc to operate in interactive mode. Prompts will be written to the standard output and commands read from the standard input. -
    -l -
    Obtain a list of peers which are known to the server(s). This switch is equivalent to -c listpeers. -
    -n -
    Output all host addresses in dotted-quad numeric format rather than converting to the canonical host names. -
    -p -
    Print a list of the peers known to the server as well as a summary of their state. This is equivalent to -c peers. -
    -s -
    Print a list of the peers known to the server as well as a summary of their state, but in a slightly different format than the -p switch. This is equivalent to -c dmpeers. -
    -

    Interactive Commands

    -

    Interactive format commands consist of a keyword followed by zero to four arguments. Only enough characters of the full keyword to uniquely identify the command need be typed. The output of a command is normally sent to the standard output, but optionally the output of individual commands may be sent to a file by appending a <, followed by a file name, to the command line.

    -

    A number of interactive format commands are executed entirely within the ntpdc program itself and do not result in NTP mode 7 requests being sent to a server. These are described following.

    -
    -
    ? [ command_keyword ]
    - help [ command_keyword ] -
    A ? by itself will print a list of all the command keywords known to this incarnation of ntpq. A ? followed by a command keyword will print function and usage information about the command. This command is probably a better source of information about ntpq than this manual page. -
    delay milliseconds -
    Specify a time interval to be added to timestamps included in requests which require authentication. This is used to enable (unreliable) server reconfiguration over long delay network paths or between machines whose clocks are unsynchronized. Actually the server does not now require timestamps in authenticated requests, so this command may be obsolete. -
    host hostname -
    Set the host to which future queries will be sent. Hostname may be either a host name or a numeric address. -
    hostnames [ yes | no ] -
    If yes is specified, host names are printed in information displays. If no is specified, numeric addresses are printed instead. The default is yes, unless modified using the command line -n switch. -
    keyid keyid -
    This command allows the specification of a - key number to be used to authenticate configuration - requests from ntpdc to the host(s). This must - correspond to a key number which the host/server has - been configured to use for this purpose (server - options: trustedkey, and - requestkey). If authentication is not - enabled on the host(s) for ntpdc - commands, the command - "keyid 0" should be given; otherwise the - keyid of the next subsequent addpeer/addserver/broadcast - command will - be used. -
    quit -
    Exit ntpdc. -
    passwd -
    This command prompts you to type in a password (which will not be echoed) which will be used to authenticate configuration requests. The password must correspond to the key configured for use by the NTP server for this purpose if such requests are to be successful. -
    timeout milliseconds -
    Specify a timeout period for responses to server queries. The default is about 8000 milliseconds. Note that since ntpdc retries each query once after a timeout, the total waiting time for a timeout will be twice the timeout value set. -
    -

    Control Message Commands

    -

    Query commands result in NTP mode 7 packets containing requests for information being sent to the server. These are read-only commands in that they make no modification of the server configuration state.

    -
    -
    listpeers -
    Obtains and prints a brief list of the peers for which the server is maintaining state. These should include all configured peer associations as well as those peers whose stratum is such that they are considered by the server to be possible future synchronization candidates. -
    peers -
    Obtains a list of peers for which the server is maintaining state, along with a summary of that state. Summary information includes the address of the remote peer, the local interface address (0.0.0.0 if a local address has yet to be determined), the stratum of the remote peer (a stratum of 16 indicates the remote peer is unsynchronized), the polling interval, in seconds, the reachability register, in octal, and the current estimated delay, offset and dispersion of the peer, all in seconds. -

    The character in the left margin indicates the mode this peer entry is operating in. A + denotes symmetric active, a - indicates symmetric passive, a = means the remote server is being polled in client mode, a ^ indicates that the server is broadcasting to this address, a ~ denotes that the remote peer is sending broadcasts and a * marks the peer the server is currently synchronizing to.

    -

    The contents of the host field may be one of four forms. It may be a host name, an IP address, a reference clock implementation name with its parameter or REFCLK(implementation number, parameter). On hostnames no only IP-addresses will be displayed.

    -
    dmpeers -
    A slightly different peer summary list. Identical to the output of the peers command, except for the character in the leftmost column. Characters only appear beside peers which were included in the final stage of the clock selection algorithm. A . indicates that this peer was cast off in the falseticker detection, while a + indicates that the peer made it through. A * denotes the peer the server is currently synchronizing with. -
    showpeer peer_address [...] -
    Shows a detailed display of the current peer variables for one or more peers. Most of these values are described in the NTP Version 2 specification. -
    pstats peer_address [...] -
    Show per-peer statistic counters associated with the specified peer(s). -
    clockinfo clock_peer_address [...] -
    Obtain and print information concerning a peer clock. The values obtained provide information on the setting of fudge factors and other clock performance information. -
    kerninfo -
    Obtain and print kernel phase-lock loop operating parameters. This information is available only if the kernel has been specially modified for a precision timekeeping function. -
    loopinfo [ oneline | multiline ] -
    Print the values of selected loop filter variables. The loop filter is the part of NTP which deals with adjusting the local system clock. The offset is the last offset given to the loop filter by the packet processing code. The frequency is the frequency error of the local clock in parts-per-million (ppm). The time_const controls the stiffness of the phase-lock loop and thus the speed at which it can adapt to oscillator drift. The watchdog timer value is the number of seconds which have elapsed since the last sample offset was given to the loop filter. The oneline and multiline options specify the format in which this information is to be printed, with multiline as the default. -
    sysinfo -
    Print a variety of system state variables, i.e., state related to the local server. All except the last four lines are described in the NTP Version 3 specification, RFC-1305. -

    The system flags show various system flags, some of which can be set and cleared by the enable and disable configuration commands, respectively. These are the auth, bclient, monitor, pll, pps and stats flags. See the ntpd documentation for the meaning of these flags. There are two additional flags which are read only, the kernel_pll and kernel_pps. These flags indicate the synchronization status when the precision time kernel modifications are in use. The kernel_pll indicates that the local clock is being disciplined by the kernel, while the kernel_pps indicates the kernel discipline is provided by the PPS signal.

    -

    The stability is the residual frequency error remaining after the system frequency correction is applied and is intended for maintenance and debugging. In most architectures, this value will initially decrease from as high as 500 ppm to a nominal value in the range .01 to 0.1 ppm. If it remains high for some time after starting the daemon, something may be wrong with the local clock, or the value of the kernel variable tick may be incorrect.

    -

    The broadcastdelay shows the default broadcast delay, as set by the broadcastdelay configuration command.

    -

    The authdelay shows the default authentication delay, as set by the authdelay configuration command.

    -
    sysstats -
    Print statistics counters maintained in the protocol module. -
    memstats -
    Print statistics counters related to memory allocation code. -
    iostats -
    Print statistics counters maintained in the input-output module. -
    timerstats -
    Print statistics counters maintained in the timer/event queue support code. -
    reslist -
    Obtain and print the server's restriction list. This list is (usually) printed in sorted order and may help to understand how the restrictions are applied. -
    ifstats -
    List interface statistics for interfaces used by ntpd for network communication.
    -
    ifreload -
    Force rescan of current system interfaces. Outputs interface statistics for interfaces that could possibly change. Marks unchanged interfaces with ., added interfaces with + and deleted interfaces with -.
    -
    monlist [ version ] -
    Obtain and print traffic counts collected and maintained by the monitor facility. The version number should not normally need to be specified. -
    clkbug clock_peer_address [...] -
    Obtain debugging information for a reference clock driver. This information is provided only by some clock drivers and is mostly undecodable without a copy of the driver source in hand. -
    -

    Runtime Configuration Requests

    -

    All requests which cause state changes in the server are authenticated by the server using a configured NTP key (the facility can also be disabled by the server by not configuring a key). The key number and the corresponding key must also be made known to ntpdc. This can be done using the keyid and passwd commands, the latter of which will prompt at the terminal for a password to use as the encryption key. You will also be prompted automatically for both the key number and password the first time a command which would result in an authenticated request to the server is given. Authentication not only provides verification that the requester has permission to make such changes, but also gives an extra degree of protection again transmission errors.

    -

    Authenticated requests always include a timestamp in the packet data, which is included in the computation of the authentication code. This timestamp is compared by the server to its receive time stamp. If they differ by more than a small amount the request is rejected. This is done for two reasons. First, it makes simple replay attacks on the server, by someone who might be able to overhear traffic on your LAN, much more difficult. Second, it makes it more difficult to request configuration changes to your server from topologically remote hosts. While the reconfiguration facility will work well with a server on the local host, and may work adequately between time-synchronized hosts on the same LAN, it will work very poorly for more distant hosts. As such, if reasonable passwords are chosen, care is taken in the distribution and protection of keys and appropriate source address restrictions are applied, the run time reconfiguration facility should provide an adequate level of security.

    -

    The following commands all make authenticated requests.

    -
    -
    addpeer peer_address [ - keyid ] [ version ] [ - minpoll# | prefer | iburst | burst | minpoll - N | maxpoll N [...] ] -
    addpeer peer_address [ - prefer | iburst | burst | minpoll - N | maxpoll N | keyid - N | version N [...] ] -
    Add a configured peer association at the - given address and operating in symmetric - active mode. Note that an existing association - with the same peer may be deleted when this - command is executed, or may simply be - converted to conform to the new configuration, - as appropriate. If the keyid - is nonzero, all outgoing packets to - the remote server will have an authentication - field attached encrypted with this key. If the - value is 0 (or not given) no authentication - will be done. If ntpdc's key number has not - yet been set (e.g., by the keyid - command), it will be set to this value. - The version# can be 1 through 4 and defaults to 3. The remaining - options are either a numeric value for minpoll or - literals prefer, iburst, - burst, minpoll N, - keyid N, version N, or - maxpoll N (where N is a numeric value), and have the action as specified in the - peer configuration file command of - ntpd. See the Server Options page for further information. - Each flag (or its absence) replaces the - previous setting. The prefer keyword indicates a preferred peer (and thus will be used primarily for clock synchronisation if possible). The preferred peer also determines the validity of the PPS signal - if the preferred peer is suitable for synchronisation so is the PPS signal. -
    addserver peer_address [ - keyid ] [ version ] [ - minpoll# | prefer | iburst | burst | minpoll - N | maxpoll N [...] ] -
    addserver peer_address [ - prefer | iburst | burst | minpoll - N | maxpoll N | keyid - N | version N [...] ] -
    Identical to the addpeer command, except that the operating mode is client. -
    broadcast peer_address [ - keyid ] [ version ] [ prefer ] -
    Identical to the addpeer command, except - that the operating mode is broadcast. In this - case a valid non-zero key identifier and key are required. The peer_address parameter can be the broadcast address of the local network or a multicast group address assigned to NTP. If a multicast address, a multicast-capable kernel is required. -
    unconfig peer_address [...] -
    This command causes the configured bit to be removed from the specified peer(s). In many cases this will cause the peer association to be deleted. When appropriate, however, the association may persist in an unconfigured mode if the remote peer is willing to continue on in this fashion. -
    fudge peer_address [ time1 ] [ time2 ] [ stratum ] [ refid ] -
    This command provides a way to set certain data for a reference clock. See the source listing for further information. -
    enable [ auth | bclient | calibrate | kernel | monitor | ntp | pps | stats]
    - disable [ auth | bclient | calibrate | kernel | monitor | ntp | pps | stats] -
    These commands operate in the same way as the enable and disable configuration file commands of ntpd. See the Miscellaneous Options page for further information. -
    restrict address mask flag [ flag ] -
    This command operates in the same way as the restrict configuration file commands of ntpd. -
    unrestrict address mask flag [ flag ] -
    Unrestrict the matching entry from the restrict list. -
    delrestrict address mask [ ntpport ] -
    Delete the matching entry from the restrict list. -
    readkeys -
    Causes the current set of authentication keys to be purged and a new set to be obtained by rereading the keys file (which must have been specified in the ntpd configuration file). This allows encryption keys to be changed without restarting the server. -
    trustedkey keyid [...] -
    untrustedkey keyid [...] -
    These commands operate in the same way as the trustedkey and untrustedkey configuration file commands of ntpd. -
    authinfo -
    Returns information concerning the authentication module, including known keys and counts of encryptions and decryptions which have been done. -
    traps -
    Display the traps set in the server. See the source listing for further information. -
    addtrap [ address [ port ] [ interface ] -
    Set a trap for asynchronous messages. See the source listing for further information. -
    clrtrap [ address [ port ] [ interface] -
    Clear a trap for asynchronous messages. See the source listing for further information. -
    reset -
    Clear the statistics counters in various modules of the server. See the source listing for further information. -
    -

    Bugs

    -

    ntpdc is a crude hack. Much of the information it shows is deadly boring and could only be loved by its implementer. The program was designed so that new (and temporary) features were easy to hack in, at great expense to the program's ease of use. Despite this, the program is occasionally useful.

    -
    - - - - diff -urN src/contrib/ntp/html/ntpdsim.html src.ntp/contrib/ntp/html/ntpdsim.html --- src/contrib/ntp/html/ntpdsim.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/ntpdsim.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,73 +0,0 @@ - - - - - - - - ntpdsim - Network Time Protocol (NTP) simulator - - - - -

    ntpdsim - Network Time Protocol (NTP) simulator

    - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

    The mushroom knows all the command line options.

    -

    Last update: 20:07 UTC Friday, June 16, 2006

    -
    -

    Related Links

    - -

    Table of Contents

    - -
    -

    Synopsis

    - ntpdsim [ -B bdly ] [ -C snse ] [ -O clk_time ] [ -S sim_time ] [ -T ferr ] [ -W fsne ] [ -Y ndly ] [ -X pdly ] -

    Description

    -

    The ntpdsim program is an adaptation of the ntpd operating system daemon. The program operates as a discrete time simulator using specified systematic and random driving sources. It includes all the mitigation and discipline algorithms of the actual daemon, but with the packet I/O and system clock algorithms driven by simulation. Most functions of the real ntpd remain intact, including the monitoring, statistics recording, trace and host name resolution features. Further information on the simulator is on the NTP Discrete Event Simulator page.

    -

    The simulator is most useful to study NTP behavior in response to time and/or frequency transients under specific conditions of network jitter and oscillator wander. For this purpose the daemon can be driven by pseudorandom jitter and wander sample sequences characteristic of real networks and oscillators. The jitter generator produces samples from a Poisson distribution, while the wander generator produces samples from a Guassian distribution.

    -

    The easiest way to use this program is to create a ntpstats directory, configuration file ntp.conf and frequency file ntp.drift and test shell test.sh in the base directory. The ntp.drift file and ntpstats directory can be empty to start. The test.sh script can contain something like

    -
    rm ./ntpstats/*
    -ntpdsim -O 0.1 -C .001 -T 400 -W 1 -c ./ntp.conf,
    -
    -

    which starts the simulator with a time offset 100 ms, network jitter 1 ms, frequency offset 400 PPM and oscillator wander 1 PPM/s. These parameters represent typical conditions with modern workstations on a Ethernet LAN. The ntp.conf file should contain something like

    -
    disable kernel
    -server pogo
    -driftfile ./ntp.drift
    -statsdir ./ntpstats/
    -filegen loopstats type day enable
    -filegen peerstats type day enable
    -
    -

    Command Line Options

    -
    -
    Note: The NTP development team is moving to the use of a syntax-directed configuration file design. When complete these options will be replaced by a new one. Most of the ntpd command line options apply also to ntpdsim. In addition, the following command line options apply to ntpdsim. -
    -B bdly -
    Specify beep delay (3600) s. -
    -C snse -
    Specify network jitter parameter (0) s. -
    -O clk_time -
    Specify initial time offset (0) s. -
    -S sim_time -
    Specify simulation duration (86400) s. -
    -T ferr -
    Specify initial frequency offset (0) PPM. -
    -W fnse -
    Specify oscillator wander parameter (0) PPM/s. -
    -Y ndly -
    Specify network propagation delay (.001) s. -
    -Z pdly -
    Specify server processing delay (.001) s. -
    -

    Files

    - /etc/ntp.conf - the default name of the configuration file
    - /etc/ntp.drift - the default name of the drift file
    - /etc/ntp.keys - the default name of the key file -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/ntpdsim_new.html src.ntp/contrib/ntp/html/ntpdsim_new.html --- src/contrib/ntp/html/ntpdsim_new.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/ntpdsim_new.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,102 +0,0 @@ - - - - - - - - ntpdsim - Network Time Protocol (NTP) simulator - - - - -

    ntpdsim - Network Time Protocol (NTP) simulator

    - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

    The mushroom knows all the command line options.

    -

    Last update: 21:32 UTC Friday, June 16, 2006

    -
    -

    Related Links

    - -

    Table of Contents

    - -

    Description

    -

    The ntpdsim program is used to simulate and study the behavior of an NTP daemon that derives its time from a number of different simulated time sources (servers). Each simulated server can be configured to have a different time offset, frequency offset, propagation delay, processing delay, network jitter and oscillator wander.

    -

    The ntpdsim program runs all the same selection, mitigation, and discipline algorithms as the actual ntpd daemon at the client. (It actually uses the same code). However, the input/output routines and servers are simulated. That is, instead of sending the client messages over the network to the actual servers, the client messages are intercepted by the ntpdsim program, which then generates the replies to those messages. The reply messages are carefully "inserted" into the input queue of the client at the right time according to the specified server properties (like propagation delay).

    -

    Each simulated server runs according to a specified script that describes the server properties at a particular time. Each script consists of a series of consecutive acts. Each act runs for a particular duration and specifies the frequency offset, propagation delay, processing delay, network jitter and oscillator wander of the server for that duration. Once the duration of an act expires, the simulated server reconfigures itself according to the properties specified in the next act.

    -

    Configuration

    -

    The ntpdsim program is configured by providing a configuration file at startup. The crux of the simulator configuration is specified using a simulate command, the syntax of which is given below. Note that all time quantities are in seconds and all frequency quantities are in parts per million (PPM):

    -

    <simulate_command> ::= simulate { <init_statement_list> <server_list> }
    - <init_statement_list> ::= <init_statement_list> <init_statement> | <init_statement>
    - <init_statement> ::= beep_delay = <number> | simulation_duration = <number>
    - <server_list> ::= <server_list> <server> | <server>
    - <server_list> ::= server = <address> { server_offset = <number> <act_list> }
    - <act_list> ::= <act_list> <act> | <act>
    - <act> ::= duration = <number> { <act_stmt_list> }
    - <act_stmt_list> ::= <act_stmt_list> <act_stmt> | <act_stmt>
    - <act_stmt> ::= freq_offset = <number> | wander = <number> | jitter = <number> | prop_delay = <number> | proc_delay = <number>

    -

    In addition to the simulate command, other standard NTP configuration commands can be specified. These commands have the same meaning as in the ntpd configuration. Note that newlines are not significant within the simulate command even though they are used to mark the end of a normal NTP configuration command.

    -

    Sample Configuration File

    -

    A sample ntpdsim configuration file is given below. It specifies two simulated servers, each of which has two acts.

    -
    -    # Client configuration 
    -    disable kernel
    -    server pogo
    -    driftfile ./ntp.drift
    -    statsdir ./ntpstats/
    -    filegen loopstats type day enable
    -    filegen peerstats type day enable
    -
    -    # Simulation configuration
    -    simulate {
    -        simulation_duration = 86400
    -        beep_delay = 3600
    -
    -        # Server 1
    -	server = louie.udel.edu {
    -	    server_offset = 0 
    -            duration = 50000 {
    -		freq_offset = 400
    -		wander = 1.0
    -		jitter = 0.001
    -		prop_delay = 0.001
    -		proc_delay = 0.001
    -	    }
    -            duration = 6400 {
    -		freq_offset = 200
    -		wander = 1.0
    -		jitter = 0.001
    -		prop_delay = 0.001
    -		proc_delay = 0.001
    -	    }
    -	}
    -
    -        # Server 2
    -	server = baldwin.udel.edu {
    -	    server_offset = 0.02
    -	    duration = 10000 {
    -		freq_offset = 400
    -		wander = 1.0
    -		jitter = 0.001
    -		prop_delay = 0.5
    -		proc_delay = 0.001
    -	    }
    -	    duration = 60000 {
    -		freq_offset = 200
    -		wander = 1.0
    -		jitter = 0.05
    -		prop_delay = 0.005
    -		proc_delay = 0.001
    -	    }
    -	}
    -    }
    -  
    -
    -
    Sachin Kamboj
    - - - - diff -urN src/contrib/ntp/html/ntpq.html src.ntp/contrib/ntp/html/ntpq.html --- src/contrib/ntp/html/ntpq.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/ntpq.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,264 +0,0 @@ - - - - - - - - ntpq - standard NTP query program - - - - -

    ntpq - standard NTP query program

    - giffrom Pogo, Walt Kelly -

    A typical NTP monitoring packet

    -

    Last update: 18:45 UTC Thursday, July 28, 2005

    -
    -

    More Help

    - -
    -

    Synopsis

    - ntpq [-inp] [-c command] [host] [...] -

    Description

    -

    The ntpq utility program is used to monitor NTP daemon ntpd operations and determine performance. It uses the standard NTP mode 6 control message formats defined in Appendix B of the NTPv3 specification RFC1305. The same formats are used in NTPv4, although some of the variables have changed and new ones added. The description on this page is for the NTPv4 variables.

    -

    The program can be run either in interactive mode or controlled using command line arguments. Requests to read and write arbitrary variables can be assembled, with raw and pretty-printed output options being available. The ntpq can also obtain and print a list of peers in a common format by sending multiple queries to the server.

    -

    If one or more request options is included on the command line when ntpq is executed, each of the requests will be sent to the NTP servers running on each of the hosts given as command line arguments, or on localhost by default. If no request options are given, ntpq will attempt to read commands from the standard input and execute these on the NTP server running on the first host given on the command line, again defaulting to localhost when no other host is specified. ntpqwill prompt for commands if the standard input is a terminal device.

    -

    ntpq uses NTP mode 6 packets to communicate with the NTP server, and hence can be used to query any compatible server on the network which permits it. Note that since NTP is a UDP protocol this communication will be somewhat unreliable, especially over large distances in terms of network topology. ntpq makes one attempt to retransmit requests, and will time requests out if the remote host is not heard from within a suitable timeout time.

    -

    Note that in contexts where a host name is expected, a -4 qualifier preceding the host name forces DNS resolution to the IPv4 namespace, while a -6 qualifier forces DNS resolution to the IPv6 namespace.

    -

    For examples and usage, see the NTP Debugging Techniques page.

    -

    Command line options are described following. Specifying a command line option other than -i or -n will cause the specified query (queries) to be sent to the indicated host(s) immediately. Otherwise, ntpq will attempt to read interactive format commands from the standard input.

    -
    -
    -4 -
    Force DNS resolution of following host names on the command line to the IPv4 namespace. -
    -6 -
    Force DNS resolution of following host names on the command line to the IPv6 namespace. -
    -c -
    The following argument is interpreted as an interactive format command and is added to the list of commands to be executed on the specified host(s). Multiple -c options may be given. -
    -d -
    Turn on debugging mode. -
    -i -
    Force ntpq to operate in interactive mode. Prompts will be written to the standard output and commands read from the standard input. -
    -n -
    Output all host addresses in dotted-quad numeric format rather than converting to the canonical host names. -
    -p -
    Print a list of the peers known to the server as well as a summary of their state. This is equivalent to the peers interactive command. -
    -

    Internal Commands

    -

    Interactive format commands consist of a keyword followed by zero to four arguments. Only enough characters of the full keyword to uniquely identify the command need be typed. The output of a command is normally sent to the standard output, but optionally the output of individual commands may be sent to a file by appending a >, followed by a file name, to the command line. A number of interactive format commands are executed entirely within the ntpq program itself and do not result in NTP mode 6 requests being sent to a server. These are described following.

    -
    -
    ? [command_keyword]
    - helpl [command_keyword] -
    A ? by itself will print a list of all the command keywords known to this incarnation of ntpq. A ? followed by a command keyword will print function and usage information about the command. This command is probably a better source of information about ntpq than this manual page. -
    addvars variable_name [ = value] [...]
    - rmvars variable_name [...]
    - clearvars -
    The data carried by NTP mode 6 messages consists of a list of items of the form variable_name = value, where the = value is ignored, and can be omitted, in requests to the server to read variables. ntpq maintains an internal list in which data to be included in control messages can be assembled, and sent using the readlist and writelist commands described below. The addvars command allows variables and their optional values to be added to the list. If more than one variable is to be added, the list should be comma-separated and not contain white space. The rmvars command can be used to remove individual variables from the list, while the clearlist command removes all variables from the list. -
    cooked -
    Causes output from query commands to be "cooked", so that variables which are recognized by ntpq will have their values reformatted for human consumption. Variables which ntpq thinks should have a decodable value but didn't are marked with a trailing ?. -
    debug more | less | off -
    Turns internal query program debugging on and off. -
    delay milliseconds -
    Specify a time interval to be added to timestamps included in requests which require authentication. This is used to enable (unreliable) server reconfiguration over long delay network paths or between machines whose clocks are unsynchronized. Actually the server does not now require timestamps in authenticated requests, so this command may be obsolete. -
    host hostname -
    Set the host to which future queries will be sent. Hostname may be either a host name or a numeric address. -
    hostnames [yes | no] -
    If yes is specified, host names are printed in information displays. If no is specified, numeric addresses are printed instead. The default is yes, unless modified using the command line -n switch. -
    keyid keyid -
    This command specifies the key number to be used to authenticate configuration requests. This must correspond to a key number the server has been configured to use for this purpose. -
    ntpversion 1 | 2 | 3 | 4 -
    Sets the NTP version number which ntpq claims in packets. Defaults to 2, Note that mode 6 control messages (and modes, for that matter) didn't exist in NTP version 1. -
    passwd -
    This command prompts for a password (which will not be echoed) which will be used to authenticate configuration requests. The password must correspond to the key configured for NTP server for this purpose. -
    quit -
    Exit ntpq. -
    raw -
    Causes all output from query commands is printed as received from the remote server. The only formating/interpretation done on the data is to transform nonascii data into a printable (but barely understandable) form. -
    timeout millseconds -
    Specify a timeout period for responses to server queries. The default is about 5000 milliseconds. Note that since ntpq retries each query once after a timeout, the total waiting time for a timeout will be twice the timeout value set. -
    -

    Control Message Commands

    -

    Each association known to an NTP server has a 16 bit integer association identifier. NTP control messages which carry peer variables must identify the peer the values correspond to by including its association ID. An association ID of 0 is special, and indicates the variables are system variables, whose names are drawn from a separate name space.

    -

    Control message commands result in one or more NTP mode 6 messages being sent to the server, and cause the data returned to be printed in some format. Most commands currently implemented send a single message and expect a single response. The current exceptions are the peers command, which will send a preprogrammed series of messages to obtain the data it needs, and the mreadlist and mreadvar commands, which will iterate over a range of associations.

    -
    -
    associations -
    Obtains and prints a list of association identifiers and peer statuses for in-spec peers of the server being queried. The list is printed in columns. The first of these is an index numbering the associations from 1 for internal use, the second the actual association identifier returned by the server and the third the status word for the peer. This is followed by a number of columns containing data decoded from the status word. See the peers command for a decode of the condition field. Note that the data returned by the associations command is cached internally in ntpq. The index is then of use when dealing with stupid servers which use association identifiers which are hard for humans to type, in that for any subsequent commands which require an association identifier as an argument, the form &index may be used as an alternative. -
    clockvar [assocID] [variable_name [ = value [...]] [...] -
    cv [assocID] [variable_name [ = value [...] ][...] -
    Requests that a list of the server's clock variables be sent. Servers which have a radio clock or other external synchronization will respond positively to this. If the association identifier is omitted or zero the request is for the variables of the system clock and will generally get a positive response from all servers with a clock. If the server treats clocks as pseudo-peers, and hence can possibly have more than one clock connected at once, referencing the appropriate peer association ID will show the variables of a particular clock. Omitting the variable list will cause the server to return a default variable display. -
    lassociations -
    Obtains and prints a list of association identifiers and peer statuses for all associations for which the server is maintaining state. This command differs from the associations command only for servers which retain state for out-of-spec client associations (i.e., fuzzballs). Such associations are normally omitted from the display when the associations command is used, but are included in the output of lassociations. -
    lpassociations -
    Print data for all associations, including out-of-spec client associations, from the internally cached list of associations. This command differs from passociations only when dealing with fuzzballs. -
    lpeers -
    Like R peers, except a summary of all associations for which the server is maintaining state is printed. This can produce a much longer list of peers from fuzzball servers. -
    mreadlist assocID assocID
    - mrl assocID assocID -
    Like the readlist command, except the query is done for each of a range of (nonzero) association IDs. This range is determined from the association list cached by the most recent associations command. -
    mreadvar assocID assocID [ variable_name [ = value[ ... ]
    - mrv assocID assocID [ variable_name [ = value[ ... ] -
    Like the readvar command, except the query is done for each of a range of (nonzero) association IDs. This range is determined from the association list cached by the most recent associations command. -
    opeers -
    An old form of the peers command with the reference ID replaced by the local interface address. -
    passociations -
    Displays association data concerning in-spec peers from the internally cached list of associations. This command performs identically to the associations except that it displays the internally stored data rather than making a new query. -
    peers -
    Obtains a current list peers of the server, along with a summary of each peer's state. Summary information includes the address of the remote peer, the reference ID (0.0.0.0 if this is unknown), the stratum of the remote peer, the type of the peer (local, unicast, multicast or broadcast), when the last packet was received, the polling interval, in seconds, the reachability register, in octal, and the current estimated delay, offset and dispersion of the peer, all in milliseconds. The character at the left margin of each line shows the synchronization status of the association and is a valuable diagnostic tool. The encoding and meaning of this character, called the tally code, is given later in this page. -
    pstatus assocID -
    Sends a read status request to the server for the given association. The names and values of the peer variables returned will be printed. Note that the status word from the header is displayed preceding the variables, both in hexadecimal and in pidgeon English. -
    readlist [ assocID ]
    - rl [ assocID ] -
    Requests that the values of the variables in the internal variable list be returned by the server. If the association ID is omitted or is 0 the variables are assumed to be system variables. Otherwise they are treated as peer variables. If the internal variable list is empty a request is sent without data, which should induce the remote server to return a default display. -
    readvar assocID variable_name [ = value ] [ ...]
    - rv assocID [ variable_name [ = value ] [...] -
    Requests that the values of the specified variables be returned by the server by sending a read variables request. If the association ID is omitted or is given as zero the variables are system variables, otherwise they are peer variables and the values returned will be those of the corresponding peer. Omitting the variable list will send a request with no data which should induce the server to return a default display. The encoding and meaning of the variables derived from NTPv3 is given in RFC-1305; the encoding and meaning of the additional NTPv4 variables are given later in this page. -
    writevar assocID variable_name [ = value [ ...] -
    Like the readvar request, except the specified variables are written instead of read. -
    writelist [ assocID ] -
    Like the readlist request, except the internal list variables are written instead of read. -
    -

    Tally Codes

    -

    The character in the left margin in the peers billboard, called the tally code, shows the fate of each association in the clock selection process. Following is a list of these characters, the pigeon used in the rv command, and a short explanation of the condition revealed.

    -
    -
    space reject -
    The peer is discarded as unreachable, synchronized to this server (synch loop) or outrageous synchronization distance. -
    x  falsetick -
    The peer is discarded by the intersection algorithm as a falseticker. -
    .  excess -
    The peer is discarded as not among the first ten peers sorted by synchronization distance and so is probably a poor candidate for further consideration. -
    -  outlyer -
    The peer is discarded by the clustering algorithm as an outlyer. -
    +  candidat -
    The peer is a survivor and a candidate for the combining algorithm. -
    #  selected -
    The peer is a survivor, but not among the first six peers sorted by synchronization distance. If the association is ephemeral, it may be demobilized to conserve resources. -
    *  sys.peer -
    The peer has been declared the system peer and lends its variables to the system variables. -
    o  pps.peer -
    The peer has been declared the system peer and lends its variables to thesystem variables. However, the actual system synchronization is derived from a pulse-per-second (PPS) signal, either indirectly via the PPS reference clock driver or directly via kernel interface. -
    -

    System Variables

    -

    The status, leap, stratum, precision, rootdelay, rootdispersion, refid, reftime, poll, offset, and frequency variables are described in RFC-1305 specification. Additional NTPv4 system variables include the following.

    -
    -
    version -
    Everything you might need to know about the software version and generation time. -
    processor -
    The processor and kernel identification string. -
    system -
    The operating system version and release identifier. -
    state -
    The state of the clock discipline state machine. The values are described in the architecture briefing on the NTP Project page linked from www.ntp.org. -
    peer -
    The internal integer used to identify the association currently designated the system peer. -
    jitter -
    The estimated time error of the system clock measured as an exponential average of RMS time differences. -
    stability -
    The estimated frequency stability of the system clock measured as an exponential average of RMS frequency differences. -
    -

    When the NTPv4 daemon is compiled with the OpenSSL software library, additional system variables are displayed, including some or all of the following, depending on the particular dance:

    -
    -
    flags -
    The current flags word bits and message digest algorithm identifier (NID) in hex format. The high order 16 bits of the four-byte word contain the NID from the OpenSSL ligrary, while the low-order bits are interpreted as follows: -
    -
    -
    0x01 -
    autokey enabled -
    0x02 -
    NIST leapseconds file loaded -
    0x10 -
    PC identity scheme -
    0x20 -
    IFF identity scheme -
    0x40 -
    GQ identity scheme -
    -
    hostname -
    The name of the host as returned by the Unix gethostname() library function. -
    hostkey -
    The NTP filestamp of the host key file. -
    cert -
    A list of certificates held by the host. Each entry includes the subject, issuer, flags and NTP filestamp in order. The bits are interpreted as follows: -
    -
    -
    0x01 -
    certificate has been signed by the server -
    0x02 -
    certificate is trusted -
    0x04 -
    certificate is private -
    0x08 -
    certificate contains errors and should not be trusted -
    -
    leapseconds -
    The NTP filestamp of the NIST leapseconds file. -
    refresh -
    The NTP timestamp when the host public cryptographic values were refreshed and signed. -
    signature -
    The host digest/signature scheme name from the OpenSSL library. -
    tai -
    The TAI-UTC offset in seconds obtained from the NIST leapseconds table. -
    -

    Peer Variables

    -

    The status, srcadr, srcport, dstadr, dstport, leap, stratum, precision, rootdelay, rootdispersion, readh, hmode, pmode, hpoll, ppoll, offset, delay, dspersion, reftime variables are described in the RFC-1305 specification, as are the timestamps org, rec and xmt. Additional NTPv4 system variables include the following.

    -
    -
    flash -
    The flash code for the most recent packet received. The encoding and meaning of these codes is given later in this page. -
    jitter -
    The estimated time error of the peer clock measured as an exponential average of RMS time differences. -
    unreach -
    The value of the counter which records the number of poll intervals since the last valid packet was received. -
    -

    When the NTPv4 daemon is compiled with the OpenSSL software library, additional peer variables are displayed, including the following:

    -
    -
    flags -
    The current flag bits. This word is the server host status word with additional bits used by the Autokey state machine. See the source code for the bit encoding. -
    hostname -
    The server host name. -
    initkey key -
    The initial key used by the key list generator in the Autokey protocol. -
    initsequence index -
    The initial index used by the key list generator in the Autokey protocol. -
    signature -
    The server message digest/signature scheme name from the OpenSSL software library. -
    timestamp time -
    The NTP timestamp when the last Autokey key list was generated and signed. -
    -

    Flash Codes

    -

    The flash code is a valuable debugging aid displayed in the peer variables list. It shows the results of the original sanity checks defined in the NTP specification RFC-1305 and additional ones added in NTPv4. There are 12 tests designated TEST1 through TEST12. The tests are performed in a certain order designed to gain maximum diagnostic information while protecting against accidental or malicious errors. The flash variable is initialized to zero as each packet is received. If after each set of tests one or more bits are set, the packet is discarded.

    -

    Tests TEST1 through TEST3 check the packet timestamps from which the offset and delay are calculated. If any bits are set, the packet is discarded; otherwise, the packet header variables are saved. TEST4 and TEST5 are associated with access control and cryptographic authentication. If any bits are set, the packet is discarded immediately with nothing changed.

    -

    Tests TEST6 through TEST8 check the health of the server. If any bits are set, the packet is discarded; otherwise, the offset and delay relative to the server are calculated and saved. TEST9 checks the health of the association itself. If any bits are set, the packet is discarded; otherwise, the saved variables are passed to the clock filter and mitigation algorithms.

    -

    Tests TEST10 through TEST12 check the authentication state using Autokey public-key cryptography, as described in the Authentication Options page. If any bits are set and the association has previously been marked reachable, the packet is discarded; otherwise, the originate and receive timestamps are saved, as required by the NTP protocol, and processing continues.

    -

    The flash bits for each test are defined as follows.

    -
    -
    0x001 TEST1 -
    Duplicate packet. The packet is at best a casual retransmission and at worst a malicious replay. -
    0x002 TEST2 -
    Bogus packet. The packet is not a reply to a message previously sent. This can happen when the NTP daemon is restarted and before somebody else notices. -
    0x004 TEST3 -
    Unsynchronized. One or more timestamp fields are invalid. This normally happens when the first packet from a peer is received. -
    0x008 TEST4 -
    Access is denied. See the Access Control Options page. -
    0x010 TEST5 -
    Cryptographic authentication fails. See the Authentication Options page. -
    0x020TEST6 -
    The server is unsynchronized. Wind up its clock first. -
    0x040 TEST7 -
    The server stratum is at the maximum than 15. It is probably unsynchronized and its clock needs to be wound up. -
    0x080 TEST8 -
    Either the root delay or dispersion is greater than one second, which is highly unlikely unless the peer is unsynchronized to Mars. -
    0x100 TEST9 -
    Either the peer delay or dispersion is greater than one second, which is higly unlikely unless the peer is on Mars. -
    0x200 TEST10 -
    The autokey protocol has detected an authentication failure. See the Authentication Options page. -
    0x400 TEST11 -
    The autokey protocol has not verified the server or peer is proventic and has valid public key credentials. See the Authentication Options page. -
    0x800 TEST12 -
    A protocol or configuration error has occurred in the public key algorithms or a possible intrusion event has been detected. See the Authentication Options page. -
    -

    Bugs

    -

    The peers command is non-atomic and may occasionally result in spurious error messages about invalid associations occurring and terminating the command. The timeout time is a fixed constant, which means you wait a long time for timeouts since it assumes sort of a worst case. The program should improve the timeout estimate as it sends queries to a particular host, but doesn't.

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/ntptime.html src.ntp/contrib/ntp/html/ntptime.html --- src/contrib/ntp/html/ntptime.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/ntptime.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,48 +0,0 @@ - - - - - - - - ntptime - read kernel time variables - - - - -

    ntptime - read kernel time variables

    - giffrom Pogo, Walt Kelly -

    The turtle has been swimming in the kernel.

    -

    Last update: 18:46 UTC Thursday, July 28, 2005

    -
    -
    -

    Synopsis

    - ntptime [ -chr ] [ -e est_error ] [ -f frequency ] [ -m max_error ] [ -o offset ] [ -s status ] [ -t time_constant] -

    Description

    -

    This program is useful only with special kernels described in the A Kernel Model for Precision Timekeeping page. It reads and displays time-related kernel variables using the ntp_gettime() system call. A similar display can be obtained using the ntpdc program and kerninfo command.

    -

    Options

    -
    -
    -c -
    Display the execution time of ntptime itself. -
    -e est_error -
    Specify estimated error, in microseconds. -
    -f frequency -
    Specify frequency offset, in parts per million. -
    -h -
    Display help information. -
    -m max_error -
    Specify max possible errors, in microseconds. -
    -o offset -
    Specify clock offset, in microseconds. -
    -r -
    Display Unix and NTP times in raw format. -
    -s status -
    Specify clock status. Better know what you are doing. -
    -t time_constant -
    Specify time constant, an integer in the range 0-10. -
    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/ntptrace.html src.ntp/contrib/ntp/html/ntptrace.html --- src/contrib/ntp/html/ntptrace.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/ntptrace.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,49 +0,0 @@ - - - - - - - - ntptrace - trace a chain of NTP servers back to the primary source - - - - -

    ntptrace - trace a chain of NTP servers back to the primary source

    - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

    The rabbit knows the way back.

    -

    Last update: 18:47 UTC Thursday, July 28, 2005

    -
    -
    -

    Synopsis

    - ntptrace [ -vdn ] [ -r retries ] [ -t timeout ] [ server ] -

    Description

    -

    ntptrace determines where a given Network Time Protocol (NTP) server gets its time from, and follows the chain of NTP servers back to their master time source. If given no arguments, it starts with localhost. Here is an example of the output from ntptrace:

    -
    -% ntptrace
    -localhost: stratum 4, offset 0.0019529, synch distance 0.144135
    -server2ozo.com: stratum 2, offset 0.0124263, synch distance 0.115784
    -usndh.edu: stratum 1, offset 0.0019298, synch distance 0.011993, refid 'WWVB'
    -
    -

    On each line, the fields are (left to right): the host name, the host stratum, the time offset between that host and the local host (as measured by ntptrace; this is why it is not always zero for "localhost"), the host synchronization distance, and (only for stratum-1 servers) the reference clock ID. All times are given in seconds. Note that the stratum is the server hop count to the primary source, while the synchronization distance is the estimated error relative to the primary source. These terms are precisely defined in RFC-1305.

    -

    Options

    -
    -
    -d -
    Turns on some debugging output. -
    -n -
    Turns off the printing of host names; instead, host IP addresses are given. This may be useful if a nameserver is down. -
    -r retries -
    Sets the number of retransmission attempts for each host (default = 5). -
    -t timeout -
    Sets the retransmission timeout (in seconds) (default = 2). -
    -v -
    Prints verbose information about the NTP servers. -
    -

    Bugs

    -

    This program makes no attempt to improve accuracy by doing multiple samples.

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/parsedata.html src.ntp/contrib/ntp/html/parsedata.html --- src/contrib/ntp/html/parsedata.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/parsedata.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,349 +0,0 @@ - - - - - - - - NTP PARSE clock data formats - - - - -

    NTP PARSE clock data formats

    -

    The parse driver currently supports several clocks with different query mechanisms. In order for you to find a sample that might be similar to a clock you might want to integrate into parse I'll sum up the major features of the clocks (this information is distributed in the parse/clk_*.c and ntpd/refclock_parse.c files).

    -
    -

    Meinberg clocks

    -
    -Meinberg: start=<STX>, end=<ETX>, sync on start
    -      pattern="\2D:  .  .  ;T: ;U:  .  .  ;    \3"
    -      pattern="\2  .  .  ;  ;   :  :  ;        \3"
    -      pattern="\2  .  .  ;  ;   :  :  ;    :  ;        ;   .         .       "
    -
    -

    Meinberg is a German manufacturer of time code receivers. Those clocks have a pretty common output format in the stock version. In order to support NTP Meinberg was so kind to produce some special versions of the firmware for the use with NTP. So, if you are going to use a Meinberg clock please ask whether there is a special Uni Erlangen version. You can reach Meinberg via the Web. Information can also be ordered via eMail from info@meinberg.de

    -

    General characteristics:
    - Meinberg clocks primarily output pulse per second and a describing ASCII string. This string can be produced in two modes: either upon the reception of a question mark or every second. NTP uses the latter mechanism. DCF77 AM clocks have a limited accuracy of a few milliseconds. The DCF77 PZF5xx variants provide higher accuracy and have a pretty good relationship between RS232 time code and the PPS signal. Except for early versions of the old GPS166 receiver type, Meinberg GPS receivers have a very good timing relationship between the datagram and the pulse. The beginning of the start bit of the first character has basically the same accuracy as the PPS signal, plus a jitter of up to 1 bit time depending on the selected baud rate, i.e. 52 μs @ 19200. PPS support should always be used, if possible, in order to yield the highest possible accuracy.

    -

    The preferred tty setting for Meinberg DCF77 receivers is 9600/7E2:

    -
    -		CFLAG		(B9600|CS7|PARENB|CREAD|HUPCL)
    -		IFLAG		(IGNBRK|IGNPAR|ISTRIP)
    -		OFLAG		0
    -		LFLAG		0
    -        
    -

    The tty setting for Meinberg GPS16x/17x receivers is 19200/8N1:

    -
    -		CFLAG		(B19200|CS8|PARENB|CREAD|HUPCL)
    -		IFLAG		(IGNBRK|IGNPAR|ISTRIP)
    -		OFLAG		0
    -		LFLAG		0
    -        
    -

    All clocks should be run at datagram once per second.

    -

    Format of the Meinberg standard time string:

    -
    -        <STX>D:dd.mm.yy;T:w;U:hh.mm.ss;uvxy<ETX>
    -    pos:  0  000000001111111111222222222233  3
    -          1  234567890123456789012345678901  2
    -
    -    <STX>         = start-of-text, ASCII code 0x02
    -    dd.mm.yy      = day of month, month, year of the century, separated by dots
    -    w             = day of week (1..7, Monday = 1)
    -    hh:mm:ss      = hour, minute, second, separated by dots
    -    u             = '#' for GPS receivers: time is not synchronized
    -                           '#' for older PZF5xx receivers: no correlation, not synchronized
    -                           '#' for other devices: never sync'ed since powerup
    -                           ' ' if nothing of the above applies
    -    v             = '*' for GPS receivers: position has not been verified
    -                           '*' for other devices: freewheeling based on internal quartz
    -                           ' ' if nothing of the above applies
    -    x             = 'U' if UTC time is transmitted
    -                           'S' if daylight saving time is active
    -                           ' ' if nothing of the above applies
    -    y             = '!' during the hour preceding start or end of daylight saving time
    -                           'A' during the hour preceding a leap second
    -                           ' ' if nothing of the above applies
    -    <ETX>         = end-of-text, ASCII code 0x03
    -
    -

    Format of the Uni Erlangen time string for PZF5xx receivers:

    -
    -        <STX>dd.mm.yy; w; hh:mm:ss; tuvxyza<ETX>
    -    pos:  0  000000001111111111222222222233  3
    -          1  234567890123456789012345678901  2
    -
    -    <STX>         = start-of-text, ASCII code 0x02
    -    dd.mm.yy      = day of month, month, year of the century, separated by dots
    -    w             = day of week (1..7, Monday = 1)
    -    hh:mm:ss      = hour, minute, second, separated by colons
    -
    -    t             = 'U' if UTC time is transmitted, else ' '
    -    u             = '#' for older PZF5xx receivers: no correlation, not synchronized
    -                           '#' for PZF511 and newer: never sync'ed since powerup
    -                           ' ' if nothing of the above applies
    -    v             = '*' if freewheeling based on internal quartz, else ' '
    -    x             = 'S' if daylight saving time is active, else ' '
    -    y             = '!' during the hour preceding start or end of daylight saving time, else ' '
    -    z             = 'A' during the hour preceding a leap second, else ' '
    -    a             = 'R' alternate antenna (reminiscent of PZF5xx), usually ' ' for GPS receivers
    -    <ETX>         = end-of-text, ASCII code 0x03
    -
    -

    Format of the Uni Erlangen time string for GPS16x/GPS17x receivers:

    -
    -        <STX>dd.mm.yy; w; hh:mm:ss; +uu:uu; uvxyzab; ll.lllln lll.lllle hhhhm<ETX>
    -    pos:  0  0000000011111111112222222222333333333344444444445555555555666666  6
    -          1  2345678901234567890123456789012345678901234567890123456789012345  6
    -
    -    <STX>         = start-of-text, ASCII code 0x02
    -    dd.mm.yy      = day of month, month, year of the century, separated by dots
    -    w             = day of week (1..7, Monday = 1)
    -    hh:mm:ss      = hour, minute, second, separated by colons
    -    +uu:uu        = offset to UTC in hours and minutes, preceded by + or -
    -    u             = '#' if time is not synchronized, else ' '
    -    v             = '*' if position has not been verified, else ' '
    -    x             = 'S' if daylight saving time is active, else ' '
    -    y             = '!' during the hour preceding start or end of daylight saving time, else ' '
    -    z             = 'A' during the hour preceding a leap second, else ' '
    -    a             = 'R' alternate antenna (reminiscent of PZF5xx), usually ' ' for GPS receivers
    -    b             = 'L' during a leap second, i.e. if the seconds field is 60, else ' '
    -    ll.lllln      = position latitude in degrees, 'n' can actually be 'N' or 'S', i.e. North or South
    -    lll.lllle     = position longitude in degrees, 'e' can actually be 'E' or 'W', i.e. East or West
    -    hhhh          = position altitude in meters, always followed by 'm'
    -    <ETX>         = end-of-text, ASCII code 0x03
    -
    -

    Examples for Uni Erlangen strings from GPS receivers:

    -
    -        \x02 09.07.93; 5; 08:48:26; +00:00;        ; 49.5736N  11.0280E  373m \x03
    -        \x02 08.11.06; 3; 14:39:39; +00:00;        ; 51.9828N   9.2258E  176m \x03
    -
    -

    The Uni Erlangen formats should be used preferably. Newer Meinberg GPS receivers can be configured to transmit that format, for older devices there may be a special firmware version available.

    -

    For the Meinberg parse look into clk_meinberg.c

    -
    -

    Raw DCF77 Data via serial line

    -

    RAWDCF: end=TIMEOUT>1.5s, sync each char (any char),generate psuedo time codes, fixed format

    -

    direct DCF77 code input

    -

    In Europe it is relatively easy/cheap the receive the german time code transmitter DCF77. The simplest version to process its signal is to feed the 100/200ms pulse of the demodulated AM signal via a level converter to an RS232 port at 50Baud. parse/clk_rawdcf.c holds all necessary decoding logic for the time code which is transmitted each minute for one minute. A bit of the time code is sent once a second.

    -
    -	The preferred tty setting is:
    -		CFLAG           (B50|CS8|CREAD|CLOCAL)
    -		IFLAG		0
    -		OFLAG		0
    - 		LFLAG		0
    -
    -

    DCF77 raw time code

    -

    From "Zur Zeit", Physikalisch-Technische Bundesanstalt (PTB), Braunschweig und Berlin, März 1989
    -

    -

    Timecode transmission:

    -
    -	AM:
    -
    -	time marks are send every second except for the second before the
    -	next minute mark
    -	time marks consist of a reduction of transmitter power to 25%
    -	of the nominal level
    -	the falling edge is the time indication (on time)
    -	time marks of a 100ms duration constitute a logical 0
    -	time marks of a 200ms duration constitute a logical 1
    -
    -

    see the spec. (basically a (non-)inverted psuedo random phase shift) encoding:

    -
    -	FM:
    -
    -	Second	Contents
    -	0  - 10	AM: free, FM: 0
    -	11 - 14	free
    -	15		R     - alternate antenna
    -	16		A1    - expect zone change (1 hour before)
    -	17 - 18	Z1,Z2 - time zone
    -		 0  0 illegal
    -		 0  1 MEZ  (MET)
    -		 1  0 MESZ (MED, MET DST)
    -		 1  1 illegal
    -	19	A2    - expect leap insertion/deletion (1 hour before)
    -	20	S     - start of time code (1)
    -	21 - 24	M1    - BCD (lsb first) Minutes
    -	25 - 27	M10   - BCD (lsb first) 10 Minutes
    -	28	P1    - Minute Parity (even)
    -	29 - 32	H1    - BCD (lsb first) Hours
    -	33 - 34	H10   - BCD (lsb first) 10 Hours
    -	35	P2    - Hour Parity (even)
    -	36 - 39	D1    - BCD (lsb first) Days
    -	40 - 41	D10   - BCD (lsb first) 10 Days
    -	42 - 44	DW    - BCD (lsb first) day of week (1: Monday -> 7: Sunday)
    -	45 - 49	MO1   - BCD (lsb first) Month
    -	50	MO10  - 10 Months
    -	51 - 53	Y1    - BCD (lsb first) Years
    -	54 - 57	Y10   - BCD (lsb first) 10 Years
    -	58 	P3    - Date Parity (even)
    -	59	      - usually missing (minute indication), except for leap insertion
    -
    -
    -

    Schmid clock

    -

    Schmid clock: needs poll, binary input, end='\xFC', sync start

    -

    The Schmid clock is a DCF77 receiver that sends a binary time code at the reception of a flag byte. The contents if the flag byte determined the time code format. The binary time code is delimited by the byte 0xFC.

    -
    -	TTY setup is:
    -		CFLAG		(B1200|CS8|CREAD|CLOCAL)
    -		IFLAG		0
    -		OFLAG		0
    - 		LFLAG		0
    -
    -
    -

    The command to Schmid's DCF77 clock is a single byte; each bit allows the user to select some part of the time string, as follows (the output for the lsb is sent first).

    -
    -	Bit 0:	time in MEZ, 4 bytes *binary, not BCD*; hh.mm.ss.tenths
    -	Bit 1:	date 3 bytes *binary, not BCD: dd.mm.yy
    -	Bit 2:	week day, 1 byte (unused here)
    -	Bit 3:	time zone, 1 byte, 0=MET, 1=MEST. (unused here)
    -	Bit 4:	clock status, 1 byte,	0=time invalid,
    -					1=time from crystal backup,
    -					3=time from DCF77
    -	Bit 5:	transmitter status, 1 byte,
    -					bit 0: backup antenna
    -					bit 1: time zone change within 1h
    -					bit 3,2: TZ 01=MEST, 10=MET
    -					bit 4: leap second will be
    -						added within one hour
    -					bits 5-7: Zero
    -	Bit 6:	time in backup mode, units of 5 minutes (unused here)
    -
    -
    -

    Trimble SV6 ASCII time code (TAIP)

    -

    Trimble SV6: needs poll, ascii timecode, start='>', end='<', query='>QTM<', eol='<'

    -

    Trimble SV6 is a GPS receiver with PPS output. It needs to be polled. It also need a special tty mode setup (EOL='<').

    -
    -	TTY setup is:
    -		CFLAG            (B4800|CS8|CREAD)
    -		IFLAG            (BRKINT|IGNPAR|ISTRIP|ICRNL|IXON)
    -		OFLAG            (OPOST|ONLCR)
    -		LFLAG            (ICANON|ECHOK)
    -
    -

    Special flags are:

    -
    		PARSE_F_PPSPPS	    - use CIOGETEV for PPS time stamping
    -		PARSE_F_PPSONSECOND - the time code is not related to
    -				      the PPS pulse (so use the time code
    -				      only for the second epoch)
    -
    -	Timecode
    -	0000000000111111111122222222223333333	/ char
    -	0123456789012345678901234567890123456	\ posn
    -	>RTMhhmmssdddDDMMYYYYoodnnvrrrrr;*xx<	Actual
    -	----33445566600112222BB7__-_____--99-	Parse
    -	>RTM                      1     ;*  < 	Check
    -
    -
    -

    ELV DCF7000

    -

    ELV DCF7000: end='\r', pattern=" - - - - - - - \r"

    -

    The ELV DCF7000 is a cheap DCF77 receiver sending each second a time code (though not very precise!) delimited by '`r'

    -
    -	Timecode
    -	  YY-MM-DD-HH-MM-SS-FF\r
    -
    -		FF&0x1	- DST
    -		FF&0x2	- DST switch warning
    -		FF&0x4  - unsynchronised
    -
    -
    -

    HOPF 6021 und Kompatible

    -

    HOPF Funkuhr 6021 mit serieller Schnittstelle Created by F.Schnekenbuehl <frank@comsys.dofn.de> from clk_rcc8000.c Nortel DASA Network Systems GmbH, Department: ND250 A Joint venture of Daimler-Benz Aerospace and Nortel.

    -
    - hopf Funkuhr 6021 
    -      used with 9600,8N1,
    -      UTC via serial line
    -      "Sekundenvorlauf" ON
    -      ETX zum Sekundenvorlauf ON
    -      dataformat 6021
    -      output time and date
    -      transmit with control characters
    -      transmit evry second
    - 
    -

    Type 6021 Serial Output format

    -
    -      000000000011111111 / char
    -      012345678901234567 \ position
    -      sABHHMMSSDDMMYYnre  Actual
    -       C4110046231195     Parse
    -      s              enr  Check
    -
    -  s = STX (0x02), e = ETX (0x03)
    -  n = NL  (0x0A), r = CR  (0x0D)
    -
    -  A B - Status and weekday
    - 
    -  A - Status
    -
    -      8 4 2 1
    -      x x x 0  - no announcement
    -      x x x 1  - Summertime - wintertime - summertime announcement
    -      x x 0 x  - Wintertime
    -      x x 1 x  - Summertime
    -      0 0 x x  - Time/Date invalid
    -      0 1 x x  - Internal clock used 
    -      1 0 x x  - Radio clock
    -      1 1 x x  - Radio clock highprecision
    -
    -  B - 8 4 2 1
    -      0 x x x  - MESZ/MEZ
    -      1 x x x  - UTC
    -      x 0 0 1  - Monday
    -      x 0 1 0  - Tuesday
    -      x 0 1 1  - Wednesday
    -      x 1 0 0  - Thursday
    -      x 1 0 1  - Friday
    -      x 1 1 0  - Saturday
    -      x 1 1 1  - Sunday
    -
    -
    -

    Diem Computime Clock

    -

    The Computime receiver sends a datagram in the following format every minute

    -
       
    -   Timestamp	T:YY:MM:MD:WD:HH:MM:SSCRLF 
    -   Pos          0123456789012345678901 2 3
    -		0000000000111111111122 2 2
    -   Parse        T:  :  :  :  :  :  :  \r\n
    -   
    -   T	Startcharacter "T" specifies start of the timestamp 
    -   YY	Year MM	Month 1-12 
    -   MD	Day of the month 
    -   WD	Day of week 
    -   HH	Hour 
    -   MM   Minute 
    -   SS   Second
    -   CR   Carriage return 
    -   LF   Linefeed
    -
    -
    -

    WHARTON 400A Series Clock with a 404.2 Serial interface

    -

    The WHARTON 400A Series clock is able to send date/time serial messages in 7 output formats. We use format 1 here because it is the shortest. We set up the clock to send a datagram every second. For use with this driver, the WHARTON 400A Series clock must be set-up as follows :

    -
    -  					Programmable	Selected
    -  					Option No	Option
    -	BST or CET display		3		9 or 11
    -	No external controller		7		0
    -	Serial Output Format 1		9		1
    -	Baud rate 9600 bps		10		96
    -	Bit length 8 bits		11		8
    -	Parity even			12		E
    -
    -

    WHARTON 400A Series output format 1 is as follows :

    -
    -   Timestamp	STXssmmhhDDMMYYSETX
    -   Pos		0  12345678901234
    -  		0  00000000011111
    -  
    -   STX	start transmission (ASCII 0x02)
    -   ETX	end transmission (ASCII 0x03)
    -   ss	Second expressed in reversed decimal (units then tens)
    -   mm	Minute expressed in reversed decimal
    -   hh	Hour expressed in reversed decimal
    -   DD	Day of month expressed in reversed decimal
    -   MM	Month expressed in reversed decimal (January is 1)
    -   YY	Year (without century) expressed in reversed decimal
    -   S	Status byte : 0x30 +
    -		bit 0	0 = MSF source		1 = DCF source
    -		bit 1	0 = Winter time		1 = Summer time
    -		bit 2	0 = not synchronised	1 = synchronised
    -		bit 3	0 = no early warning	1 = early warning
    -
    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/parsenew.html src.ntp/contrib/ntp/html/parsenew.html --- src/contrib/ntp/html/parsenew.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/parsenew.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,198 +0,0 @@ - - - - - - - Making PARSE Clocks - - - - -

    How to build new PARSE clocks

    -

    Here is an attempt to sketch out what you need to do in order to add another clock to the parse driver: Currently the implementation is being cleaned up - so not all information in here is completely correct. Refer to the included code where in doubt.

    -

    Prerequisites:

    -
      -
    • Does the system you want the clock connect to have the include files termio.h or termios.h ? (You need that for the parse driver) -
    -

    What to do:

    -

    Make a conversion module (libparse/clk_*.c)

    -
      -
    1. What ist the time code format ? -
        -
      • find year, month, day, hour, minute, second, status (synchronised or not), possibly time zone information (you need to give the offset to UTC) You will have to convert the data from a string into a struct clocktime: -
        -      struct clocktime                /* clock time broken up from time code */
        -      {
        -	long day;
        -	long month;
        -	long year;
        -	long hour;
        -	long minute;
        -	long second;
        -	long usecond;
        -	long utcoffset;       /* in seconds */
        -	time_t utcoffset;     /* true utc time instead of date/time */
        -	long flags;           /* current clock status */
        -      };
        -
        -

        Conversion is usually simple and straight forward. For the flags following values can be OR'ed together:

        -
        -     PARSEB_ANNOUNCE           switch time zone warning (informational only)
        -     PARSEB_POWERUP            no synchronisation - clock confused (must set then)
        -     PARSEB_NOSYNC             timecode currently not confirmed (must set then)
        -                               usually on reception error when there is still a
        -                               chance the the generated time is still ok.
        -
        -     PARSEB_DST                DST in effect (informational only)
        -     PARSEB_UTC                timecode contains UTC time (informational only)
        -     PARSEB_LEAPADD            LEAP addition warning (prior to leap happening - must set when imminent)
        -			       also used for time code that do not encode the
        -			       direction (as this is currently the default).
        -     PARSEB_LEAPDEL            LEAP deletion warning (prior to leap happening - must set when imminent)
        -     PARSEB_ALTERNATE          backup transmitter (informational only)
        -     PARSEB_POSITION           geographic position available (informational only)
        -     PARSEB_LEAPSECOND         actual leap second (this time code is the leap
        -                               second - informational only)
        -
        -

        These are feature flags denoting items that are supported by the clock:

        -
        -     PARSEB_S_LEAP             supports LEAP - might set PARSEB_LEAP
        -     PARSEB_S_ANTENNA          supports ANTENNA - might set PARSEB_ALTERNATE
        -     PARSEB_S_PPS              supports PPS time stamping
        -     PARSEB_S_POSITION         supports position information (GPS)
        -   
        -

        If the utctime field is non zero this value will be take as time code value. This allows for conversion routines that already have the utc time value. The utctime field gives the seconds since Jan 1st 1970, 0:00:00. The useconds field gives the respective usec value. The fields for date and time (down to second resolution) will be ignored.

        -

        Conversion is done in the cvt_* routine in parse/clk_*.c files. look in them for examples. The basic structure is:

        -
        -     struct clockformat <yourclock>_format = {
        -       lots of fields for you to fill out (see below)
        -     };
        -
        -     static cvt_<yourclock>()
        -       ...
        -     {
        -       if (<I do not recognize my time code>) {
        -         return CVT_NONE;
        -       } else {
        -         if (<conversion into clockformat is ok>) {
        -           <set all necessary flags>;
        -           return CVT_OK;
        -         } else {
        -           return CVT_FAIL|CVT_BADFMT;
        -         }
        -       }
        -
        -

        The struct clockformat is the interface to the rest of the parse driver - it holds all information necessary for finding the clock message and doing the appropriate time stamping.

        -
        -struct clockformat
        -{
        -  u_long (*input)();
        -  /* input routine - your routine - cvt_<yourclock> */
        -  u_long (*convert)();
        -  /* conversion routine - your routine - cvt_<yourclock> */
        -  /* routine for handling RS232 sync events (time stamps) - usually sync_simple */
        -  u_long (*syncpps)(); 
        -  /* PPS input routine - usually pps_one */
        -  void           *data;
        -  /* local parameters - any parameters/data/configuration info your conversion
        -     routine might need */
        -  char           *name;
        -  /* clock format name - Name of the time code */
        -  unsigned short  length;
        -  /* maximum length of data packet for your clock format */
        -  u_long   flags;
        - /* information for the parser what to look for */
        -};
        -
        -

        The above should have given you some hints on how to build a clk_*.c file with the time code conversion. See the examples and pick a clock closest to yours and tweak the code to match your clock.

        -

        In order to make your clk_*.c file usable a reference to the clockformat structure must be put into parse_conf.c.

        -
      -
    2. TTY setup and initialisation/configuration will be done in ntpd/refclock_parse.c. -
        -
      • Find out the exact tty settings for your clock (baud rate, parity, stop bits, character size, ...) and note them in terms of termio*.h c_cflag macros. -
      • in ntpd/refclock_parse.c fill out a new the struct clockinfo element (that allocates a new "IP" address - see comments) (see all the other clocks for example) -
        -   struct clockinfo
        -     {
        -      u_long  cl_flags;             /* operation flags (io modes) */
        -	 PARSE_F_PPSPPS       use loopfilter PPS code (CIOGETEV)
        -	 PARSE_F_PPSONSECOND  PPS pulses are on second
        -	 usually flags stay 0 as they are used only for special setups
        -
        -    void  (*cl_poll)();           /* active poll routine */
        -         The routine to call when the clock needs data sent to it in order to
        -         get a time code from the clock (e.g. Trimble clock)
        -
        -    int   (*cl_init)();           /* active poll init routine */
        -         The routine to call for very special initializations.
        -
        -    void  (*cl_event)();          /* special event handling (e.g. reset clock) */
        -         What to do, when an event happens - used to re-initialize clocks on timeout.
        -
        -    void  (*cl_end)();            /* active poll end routine */
        -         The routine to call to undo any special initialisation (free memory/timers)
        -
        -    void   *cl_data;              /* local data area for "poll" mechanism */
        -         local data for polling routines
        -
        -    u_fp    cl_rootdelay;         /* rootdelay */
        -         NTP rootdelay estimate (usually 0)
        -
        -	     u_long  cl_basedelay;         /* current offset - unsigned l_fp
        -                                              fractional part (fraction) by
        -                                              which the RS232 time code is
        -                                              delayed from the actual time. */
        -
        -    u_long  cl_ppsdelay;          /* current PPS offset - unsigned l_fp fractional
        -         time (fraction) by which the PPS time stamp is delayed (usually 0)
        -   part */
        -
        -    char   *cl_id;                /* ID code (usually "DCF") */
        -         Refclock id - (max 4 chars)
        -
        -    char   *cl_description;       /* device name */
        -         Name of this device.
        -
        -    char   *cl_format;            /* fixed format */
        -         If the data format cann not ne detected automatically this is the name
        -	 as in clk_*.c clockformat.
        -
        -    u_char  cl_type;              /* clock type (ntp control) */
        -         Type if clock as in clock status word (ntp control messages) - usually 0
        -	 
        -    u_long  cl_maxunsync;         /* time to trust oscillator after losing synch
        -  */
        -         seconds a clock can be trusted after losing synchronisation.
        -
        -    u_long  cl_speed;             /* terminal input & output baudrate */
        -    u_long  cl_cflag;             /* terminal io flags */
        -    u_long  cl_iflag;             /* terminal io flags */
        -    u_long  cl_oflag;             /* terminal io flags */
        -    u_long  cl_lflag;             /* terminal io flags */
        -         termio*.h tty modes.
        -
        -    u_long  cl_samples;           /* samples for median filter */
        -    u_long  cl_keep;              /* samples for median filter to keep */
        -         median filter parameters - smoothing and rejection of bad samples
        -  } clockinfo[] = {
        -  ...,<other clocks>,...
        -  { < your parameters> },
        -  };
        -
        -
        -
      -
    -

    Well, this is very sketchy, i know. But I hope it helps a little bit. The best way is to look which clock comes closest to your and tweak that code.

    -

    Two sorts of clocks are used with parse. Clocks that automatically send their time code (once a second) do not need entries in the poll routines because they send the data all the time. The second sort are the clocks that need a command sent to them in order to reply with a time code (like the Trimble clock).

    -

    For questions: kardel - - acm.org.

    -

    Please include an exact description on how your clock works. (initialisation, TTY modes, strings to be sent to it, responses received from the clock).

    -
    - - - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/pps.html src.ntp/contrib/ntp/html/pps.html --- src/contrib/ntp/html/pps.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/pps.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,41 +0,0 @@ - - - - - - - - Pulse-per-second (PPS) Signal Interfacing - - - - -

    Pulse-per-second (PPS) Signal Interfacing

    - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

    Alice is trying to find the PPS signal connector.

    -

    Last update: 18:48 UTC Thursday, July 28, 2005

    -
    -

    Related Links

    - -
    -

    Some radio clocks and related timekeeping gear have a pulse-per-second (PPS) signal that can be used to discipline the system clock to a high degree of precision, typically to the order less than 10 ms in time and 0.01 parts-per-million (PPM) in frequency. This page describes the hardware and software necessar for NTP to use this signal.

    - gifA Gadget Box built by Chuck Hanavin
    -

    Gadget Box

    -

    The PPS signal can be connected in either of two ways: via the data carrier detector (DCD) pin of a serial port or via the acknowledge (ACK) pin of a parallel port, depending on the hardware and operating system. Note that NTP no longer supports connection via the data leads of a serial port. However, the PPS signal levels are usually incompatible with serial port levels. The gadget box consists of a handful of electronic components assembled in a small aluminum box. It includes level converters and a optional modem designed to decode the radio timecode signals transmitted by Canadian time and frequency station CHU. This can be used with the Radio CHU Audio Demodulator/Decoder. A complete set of schematics, PCB artwork and drill templates can be obrtained via the web at gadget.tar.Z.

    -

    Operating System Support 

    -

    Both the serial and parallel port connection require operating system support, which is available in only a few operating systems, including FreeBSD, Linux (with PPSkit patch) and Solaris. Support on an experimental basis is available for several other systems, including SunOS and HP/Compaq/Digital Tru64. The PPSAPI application program interface defined in [1] is the only interface currently supported. Older PPS interfaces based on the ppsclock and tty_clk streams modules are no longer supported. As the PPSAPI is expected to become an IETF cross-platform standard, it should be used by new applications.

    -

    The entire PPS interface functionality is currently provided by inline code in the timepps.h header file. While not all implementations support the full PPSAPI specification, they do support all the functions required for the PPS driver described next. The FreeBSD, Linux and Solaris implementations can be used with the stock kernels provided with those systems; however, the Tru64 and SunOS kernels require additional functions not provided in the stock kernels. Solaris users are cautioned that these functions operate improperly in Solaris versions prior to 2.8 with patch Generic_108528-02. Header files for other systems can be found via the web at nanokernel.tar.gz.

    -

    PPS Driver

    -

    In the preferred mode of operation, PPS signals are processed by the PPS Clock Discipline driver and other clock drivers which might be involved need not know or care about them. In some cases where there is no other driver, time might be obtained from remote NTP servers via the network and local PPS signals, for instance from a calibrated cesium oscillator, used to stabilize the frequency and remove network jitter. Note that the pps configuration command has been obsoleted by this driver.

    -

    The PPS driver operates in conjunction with a preferred peer, as described in the Mitigation Rules and the prefer Keyword page. One of the drivers described in the Reference Clock Drivers page or another NTP server furnishes the coarse timing and disambiguates the seconds numbering of the PPS signal itself. The NTP daemon mitigates between the clock driver or NTP server and the PPS driver as described in that page in order to provide the most accurate time, while respecting the various types of equipment failures that could happen.

    -

    Some Unix system kernels support a PPS signal directly, as described in the A Kernel Model for Precision Timekeeping page. Specifically, the PPS driver can be used to direct the PPS signal to the kernel for use as a discipline source for both time and frequency. The presence of the kernel support is automatically detected during the NTP build process and supporting code automatically compiled. Note that the PPS driver does not normally enable the PPS kernel code, since performance is generally better without it. However, this code can be enabled by a driver fudge flag if necessary.

    -

    Some configurations may include multiple radio clocks with individual PPS outputs. In some PPSAPI designs multiple PPS signals can be connected to multiple instances of the PPS driver. In such cases the NTP mitigation and grooming algorithms operate with all the radio timecodes and PPS signals to develop the highest degree of redundancy and survivability.

    -

    Reference

    -
      -
    1. Mogul, J., D. Mills, J. Brittenson, J. Stone and U. Windl. Pulse-per-second API for Unix-like operating systems, version 1. Request for Comments RFC-2783, Internet Engineering Task Force, March 2000, 31 pp. ASCII -
    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/prefer.html src.ntp/contrib/ntp/html/prefer.html --- src/contrib/ntp/html/prefer.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/prefer.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,72 +0,0 @@ - - - - - - - Mitigation Rules and the prefer Keyword - - - - -

    Mitigation Rules and the prefer Keyword

    - gif from Alice's Adventures in Wonderland, Lewis Carroll -

    Listen carefully to what I say; it is very complicated.

    -

    Last update: 18:49 UTC Thursday, July 28, 2005

    -
    -

    Related Links

    - -

    Table of Contents

    - -
    -

    Introduction

    -

    The mechanics of the NTP algorithms which select the best data sample from each available server and the best subset of the server population have been finely crafted to resist network jitter, faults in the network or server operations, and to deliver the best possible accuracy. Most of the time these algorithms do a good job without requiring explicit manual tailoring of the configuration file. However, there are times when the accuracy can be improved by some careful tailoring. The following sections explain how to do this using explicit configuration items and special signals, when available, that are generated by some radio clocks and laboratory instruments.

    -

    In order to provide robust backup sources, primary (stratum-1) servers are usually operated in a diversity configuration, in which the server operates with a number of remote servers in addition to one or more radio or modem clocks. In these configurations the suite of algorithms used in NTP to refine the data from each peer separately and to select and combine the data from a number of servers and clocks. As the result of these algorithms, a set of survivors are identified which can presumably provide the most reliable and accurate time. Ordinarily, the individual clock offsets of the survivors are combined on a weighted average basis to produce an offset used to control the system clock.

    -

    However, because of small but significant systematic time offsets between the survivors, it is in general not possible to achieve the lowest jitter and highest stability in these configurations. This happens because the selection algorithm tends to clockhop between survivors of substantially the same quality, but showing small systematic offsets between them. In addition, there are a number of configurations involving pulse-per-second (PPS) signals, modem backup services and other special cases, so that a set of mitigation rules becomes necessary to select a single peer from among the survivors. These rules are based on a set of special characteristics of the various remote servers and reference clock drivers specified in the configuration file.

    -

    The prefer Peer

    -

    The mitigation rules are designed to provide an intelligent selection between various sources of substantially the same statistical quality without compromising the normal operation of the NTP algorithms. While they have been implemented in NTP Version 4 and will be incorporated in the NTP Version 4 specification when published, they are not in the NTP Version 3 specification RFC-1305. The rules are based on the concept of prefer peer, which is specified by including the prefer keyword with the associated server or peer command in the configuration file. This keyword can be used with any server or peer, but is most commonly used with a radio clock. While the rules do not forbid it, it does not seem useful to designate more than one peer as preferred, since the additional complexities to mitigate among them do not seem justified from on-air experience.

    -

    The prefer scheme works on the set of peers that have survived the sanity checks and intersection algorithms of the clock selection procedures. Ordinarily, the members of this set can be considered truechimers and any one of them could in principle provide correct time; however, due to various error contributions, not all can provide the most accurate and stable time. The job of the clustering algorithm, which is invoked at this point, is to select the best subset of the survivors providing the least variance in the combined ensemble average, compared to the variance in each member of the subset separately. The detailed operation of the clustering algorithm, which is given in RFC-1305, is beyond the scope of discussion here. It operates in rounds, where a survivor, presumably the worst of the lot, is discarded in each round until one of several termination conditions is met. An example terminating condition is when the number of survivors is about to be reduced below three.

    -

    In the prefer scheme the clustering algorithm is modified so that the prefer peer is never discarded; on the contrary, its potential removal becomes a termination condition. If the original algorithm were about to toss out the prefer peer, the algorithm terminates immediately. The prefer peer can still be discarded by the sanity checks and intersection algorithm, of course, but it will always survive the clustering algorithm. If it does not survive or for some reason it fails to provide updates, it will eventually become unreachable and the clock selection will remitigate to select the next best source.

    -

    Along with this behavior, the clock selection procedures are modified so that the combining algorithm is not used when a prefer peer is present. Instead, the offset of the prefer peer is used exclusively as the synchronization source. In the usual case involving a radio clock and a flock of remote stratum-1 peers, and with the radio clock designated a prefer peer, the result is that the high quality radio time disciplines the server clock as long as the radio itself remains operational and with valid time, as determined from the remote peers, sanity checks and intersection algorithm.

    -

    Peer Classification

    -

    In order to understand the effects of the various intricate schemes involved, it is necessary to understand some arcane details on how the algorithms decide on a synchronization source when more than one source is available. This is done on the basis of a set of explicit mitigation rules, which define special classes of remote serves and local radio clocks as a function of configuration declarations and clock driver type:

    -
      -
    1. The prefer peer is designated using the prefer keyword with the server or peer commands. All other things being equal, this peer will be selected for synchronization over all other survivors of the clock selection procedures. -
    2. When a PPS signal is connected via the PPS Clock Discipline driver (type 22), this is called the PPS peer. This driver provides precision clock corrections only within one second, so is always operated in conjunction with another server or radio clock driver, which provides the seconds numbering. The PPS peer is active only under conditions explained below. -
    3. When the Undisciplined Local Clock driver (type 1) is configured, this is called the local clock peer. This is used either as a backup reference source (stratum greater than zero), should all other synchronization sources fail, or as the primary reference source (stratum zero) in cases where the kernel time is disciplined by some other means of synchronization, such as the NIST lockclock scheme, or another synchronization protocol, such as the Digital Time Synchronization Service (DTSS). -
    4. When a modem driver such as the Automated Computer Time Service driver (type 18) is configured, this is called the modem peer. This is used either as a backup reference source, should all other primary sources fail, or as the (only) primary reference source. -
    5. Where support is available, the PPS signal may be processed directly by the kernel, as described in the A Kernel Model for Precision Timekeeping page. This is called the kernel discipline. The PPS signal can discipline the kernel in both frequency and time. The frequency discipline is active as long as the PPS interface device and signal itself is operating correctly, as determined by the kernel algorithms. The time discipline is active only under conditions explained below. -
    -

    Reference clock drivers operate in the manner described in the Reference Clock Drivers page and its dependencies. The drivers are ordinarily operated at stratum zero, so that as the result of ordinary NTP operations, the server itself operates at stratum one, as required by the NTP specification. In some cases described below, the driver is intentionally operated at an elevated stratum, so that it will be selected only if no other survivor is present with a lower stratum. In the case of the PPS peer or kernel time discipline, these sources appear active only if the prefer peer has survived the intersection and clustering algorithms, as described below, and its clock offset relative to the current local clock is less than a specified value, currently 128 ms.

    -

    The modem clock drivers are a special case. Ordinarily, the update interval between modem calls to synchronize the system clock is many times longer than the interval between polls of either a remote server or local radio clock. In order to provide the best stability, the operation of the clock discipline algorithm changes gradually from a phase-lock mode at the shorter update intervals to a frequency-lock mode at the longer update intervals. If remote servers or local radio clocks together with a modem peer operate in the same client, the following things can happen.

    -

    First the clock selection algorithm can select one or more remote servers or local radio clocks and the clock discipline algorithm will optimize for the shorter update intervals. Then, the selection algorithm can select the modem peer, which requires a much different optimization. The intent in the design is to allow the modem peer to control the system clock either when no other source is available or, if the modem peer happens to be marked as prefer, then it always controls the clock, as long as it passes the sanity checks and intersection algorithm. There still is room for suboptimal operation in this scheme, since a noise spike can still cause a clockhop either way. Nevertheless, the optimization function is slow to adapt, so that a clockhop or two does not cause much harm.

    -

    The local clock driver is another special case. Normally, this driver is eligible for selection only if no other source is available. When selected, vernier adjustments introduced via the configuration file or remotely using the ntpdc program can be used to trim the local clock frequency and time. However, if the local clock driver is designated the prefer peer, this driver is always selected and all other sources are ignored. This behavior is intended for use when the kernel time is controlled by some means external to NTP, such as the NIST lockclock algorithm or another time synchronization protocol such as DTSS. In this case the only way to disable the local clock driver is to mark it unsynchronized using the leap indicator bits. In the case of modified kernels with the ntp_adjtime() system call, this can be done automatically if the external synchronization protocol uses it to discipline the kernel time.

    -

    Mitigation Rules

    -

    The mitigation rules apply in the intersection and clustering algorithms described in the NTP specification. The intersection algorithm first scans all peers with a persistent association and includes only those that satisfy specified sanity checks. In addition to the checks required by the specification, the mitigation rules require either the local-clock peer or modem peer to be included only if marked as the prefer peer. The intersection algorithm operates on the included population to select only those peers believed to represent the correct time. If one or more peers survive the algorithm, processing continues in the clustering algorithm. Otherwise, if there is a modem peer, it is declared the only survivor; otherwise, if there is a local-clock peer, it is declared the only survivor. Processing then continues in the clustering algorithm.

    -

    The clustering algorithm repeatedly discards outlyers in order to reduce the residual jitter in the survivor population. As required by the NTP specification, these operations continue until either a specified minimum number of survivors remain or the minimum select dispersion of the population is greater than the maximum peer dispersion of any member. The mitigation rules require an additional terminating condition which stops these operations at the point where the prefer peer is about to be discarded.

    -

    The mitigation rules establish the choice of system peer, which determines the stratum, reference identifier and several other system variables which are visible to clients of the server. In addition, they establish which source or combination of sources control the local clock.

    -
      -
    1. If there is a prefer peer and it is the local-clock peer or the modem peer; or, if there is a prefer peer and the kernel time discipline is active, choose the prefer peer as the system peer and its offset as the system clock offset. If the prefer peer is the local-clock peer, an offset can be calculated by the driver to produce a frequency offset in order to correct for systematic frequency errors. In case a source other than NTP is controlling the system clock, corrections determined by NTP can be ignored by using the disable pll in the configuration file. If the prefer peer is the modem peer, it must be the primary source for the reasons noted above. If the kernel time discipline is active, the system clock offset is ignored and the corrections handled directly by the kernel. -
    2. If the above is not the case and there is a PPS peer, then choose it as the system peer and its offset as the system clock offset. -
    3. If the above is not the case and there is a prefer peer (not the local-clock or modem peer in this case), then choose it as the system peer and its offset as the system clock offset. -
    4. If the above is not the case and the peer previously chosen as the system peer is in the surviving population, then choose it as the system peer and average its offset along with the other survivors to determine the system clock offset. This behavior is designed to avoid excess jitter due to clockhopping, when switching the system peer would not materially improve the time accuracy. -
    5. If the above is not the case, then choose the first candidate in the list of survivors ranked in order of synchronization distance and average its offset along with the other survivors to determine the system clock offset. This is the default case and the only case considered in the current NTP specification. -
    -

    Using the Pulse-per-Second (PPS) Signal

    -

    Most radio clocks are connected using a serial port operating at speeds of 9600 bps or higher. The accuracy using typical timecode formats, where the on-time epoch is indicated by a designated ASCII character, like carriage-return <cr>, is limited to a millisecond or two. However, some radios produce a PPS signal which can be used to improve the accuracy with typical workstation servers to the order of microseconds. The details of how this can be accomplished are discussed in the Pulse-per-second (PPS) Signal Interfacing page. The following paragraphs discuss how the PPS signal is affected by the mitigation rules.

    -

    First, it should be pointed out that the PPS signal is inherently ambiguous, in that it provides a precise seconds epoch, but does not provide a way to number the seconds. In principle and most commonly, another source of synchronization, either the timecode from an associated radio clock, or even one or more remote NTP servers, is available to perform that function. In all cases, a specific, configured peer or server must be designated as associated with the PPS signal. This is done using the prefer keyword as described previously. The PPS signal can be associated in this way with any peer, but is most commonly used with the radio clock generating the PPS signal.

    -

    The PPS signal can be used in two ways to discipline the local clock, one using a special PPS driver described in the PPS Clock Discipline page, the other using PPS signal support in the kernel, as described in the A Kernel Model for Precision Timekeeping page. In either case, the signal must be present and within nominal jitter and wander error tolerances. In addition, the associated prefer peer must have survived the sanity checks and intersection algorithms and the dispersion settled below 1 s. This insures that the radio clock hardware is operating correctly and that, presumably, the PPS signal is operating correctly as well. Second, the absolute offset of the local clock from that peer must be less than 128 ms, or well within the 0.5-s unambiguous range of the PPS signal itself. In the case of the PPS driver, the time offsets generated from the PPS signal are propagated via the clock filter to the clock selection procedures just like any other peer. Should these pass the sanity checks and intersection algorithms, they will show up along with the offsets of the prefer peer itself. Note that, unlike the prefer peer, the PPS peer samples are not protected from discard by the clustering algorithm. These complicated procedures insure that the PPS offsets developed in this way are the most accurate, reliable available for synchronization.

    -

    The PPS peer remains active as long as it survives the intersection algorithm and the prefer peer is reachable; however, like any other clock driver, it runs a reachability algorithm on the PPS signal itself. If for some reason the signal fails or displays gross errors, the PPS peer will either become unreachable or stray out of the survivor population. In this case the clock selection remitigates as described above.

    -

    When kernel support for the PPS signal is available, the PPS signal is interfaced to the kernel serial driver code via a modem control lead. As the PPS signal is derived from external equipment, cables, etc., which sometimes fail, a good deal of error checking is done in the kernel to detect signal failure and excessive noise. The way in which the mitigation rules affect the kernel discipline is as follows.

    -

    PPS support requires the PPS driver (type 22) and PPSAPI interface described in the Pulse-per-second (PPS) Signal Interfacing page. In order to operate, the prefer peer must be designated and the kernel support enabled by the enable pps command in the configuration file and the signal must be present and within nominal jitter and wander error tolerances. In the NTP daemon, the PPS discipline is active only when the prefer peer is among the survivors of the clustering algorithm, and its absolute offset is within 128 ms, as determined by the PPS driver. Under these conditions the kernel disregards updates produced by the NTP daemon and uses its internal PPS source instead. The kernel maintains a watchdog timer for the PPS signal; if the signal has not been heard or is out of tolerance for more than some interval, currently two minutes, the kernel discipline is declared inoperable and operation continues as if it were not present.

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/rdebug.html src.ntp/contrib/ntp/html/rdebug.html --- src/contrib/ntp/html/rdebug.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/rdebug.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,32 +0,0 @@ - - - - - - - Debugging Reference Clock Drivers - - - - -

    Debugging Reference Clock Drivers

    - giffrom The Wizard of Oz, L. Frank Baum -

    Call the girls and the'll sweep your bugs.

    -

    Last update: 18:49 UTC Thursday, July 28, 2005

    -
    -

    Related Links

    - -

    More Help

    - -
    -

    The ntpq and ntpdc utility programs can be used to debug reference clocks, either on the server itself or from another machine elsewhere in the network. The server is compiled, installed and started using the configuration file described in the ntpd page and its dependencies. If the clock appears in the ntpq utility and pe command, no errors have occurred and the daemon has started, opened the devices specified and waiting for peers and radios to come up. If not, the first thing to look for are error messages on the system log. These are usually due to improper configuration, missing links or multiple instances of the daemon.

    -

    It normally takes a minute or so for evidence to appear that the clock is running and the driver is operating correctly. The first indication is a nonzero value in the reach column in the pe billboard. If nothing appears after a few minutes, the next step is to be sure the RS232 messages, if used, are getting to and from the clock. The most reliable way to do this is with an RS232 tester and to look for data flashes as the driver polls the clock and/or as data arrive from the clock. Our experience is that the overwhelming fraction of problems occurring during installation are due to problems such as miswired connectors or improperly configured device links at this stage.

    -

    If RS232 messages are getting to and from the clock, the variables of interest can be inspected using the ntpq program and various commands described on the documentation page. First, use the pe and as commands to display billboards showing the peer configuration and association IDs for all peers, including the radio clock. The assigned clock address should appear in the pe billboard and the association ID for it at the same relative line position in the as billboard.

    -

    Additional information is available with the rv and clockvar commands, which take as argument the association ID shown in the as billboard. The rv command with no argument shows the system variables, while the rv command with association ID argument shows the peer variables for the clock, as well as other peers of interest. The clockvar command with argument shows the peer variables specific to reference clock peers, including the clock status, device name, last received timecode (if relevant), and various event counters. In addition, a subset of the fudge parameters is included. The poll and error counters in the clockvar billboard are useful debugging aids. The poll counts the poll messages sent to the clock, while the noreply, badformat and baddate count various errors. Check the timecode to be sure it matches what the driver expects. This may require consulting the clock hardware reference manual, which is probably pretty dusty at this stage.

    -

    The ntpdc utility program can be used for detailed inspection of the clock driver status. The most useful are the clockstat and clkbug commands described in the document page. While these commands permit getting quite personal with the particular driver involved, their use is seldom necessary, unless an implementation bug shows up. If all else fails, turn on the debugging trace using two -d flags in the ntpd startup command line. Most drivers will dump status at every received message in this case. While the displayed trace can be intimidating, this provides the most detailed and revealing indicator of how the driver and clock are performing and where bugs might lurk.

    -

    Most drivers write a message to the clockstats file as each timecode or surrogate is received from the radio clock. By convention, this is the last ASCII timecode (or ASCII gloss of a binary-coded one) received from the radio clock. This file is managed by the filegen facility described in the ntpd page and requires specific commands in the configuration file. This forms a highly useful record to discover anomalies during regular operation of the clock. The scripts included in the ./scripts/stats directory can be run from a cron job to collect and summarize these data on a daily or weekly basis. The summary files have proven inspirational to detect infrequent misbehavior due to clock implementation bugs in some radios.

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/refclock.html src.ntp/contrib/ntp/html/refclock.html --- src/contrib/ntp/html/refclock.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/refclock.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,103 +0,0 @@ - - - - - - - - Reference Clock Drivers - - - - -

    Reference Clock Drivers

    - gifMaster Time Facility at the UDel Internet Research Laboratory -

    Last update: 13:06 UTC Wednesday, August 10, 2005

    -
    -

    Related Links

    - -

    Pulse-Per-Second Interfacing Links

    -

    - -

    -

    Audio Driver Links

    -

    - -

    -

    Table of Contents

    - -
    -

    Reference Clock Drivers

    -

    Support for most of the commonly available radio and modem reference clocks is included in the default configuration of the NTP daemon for Unix ntpd. Individual clocks can be activated by configuration file commands, specifically the server and fudge commands described in the ntpd program manual page. The following discussion presents Information on how to select and configure the device drivers in a running Unix system.

    -

    Many radio reference clocks can be set to display local time as adjusted for timezone and daylight saving mode. For use with NTP the clock must be set for Coordinated Universal Time (UTC) only. Ordinarily, these adjustments are performed by the kernel, so the fact that the clock runs on UTC will be transparent to the user.

    -

    Radio and modem clocks by convention have addresses in the form 127.127.t.u, where t is the clock type and u is a unit number in the range 0-3 used to distinguish multiple instances of clocks of the same type. Most of these clocks require support in the form of a serial port or special bus peripheral, but some can work directly from the audio codec found in some workstations. The particular device is normally specified by adding a soft link /dev/deviceu to the particular hardware device involved, where u correspond to the unit number above.

    -

    Most clock drivers communicate with the reference clock using a serial port, usually at 9600 bps. There are several application program interfaces (API) used in the various Unix and NT systems, most of which can be detected at configuration time. Thus, it is important that the NTP daemon and utilities be compiled on the target system or clone. In some cases special features are available, such as timestamping in the kernel or pulse-per-second (PPS) interface. In most cases these features can be detected at configuration time as well; however, the kernel may have to be recompiled in order for them to work.

    -

    The audio drivers are a special case. These include support for the NIST time/frequency stations WWV and WWVH, the Canadian time/frequency station CHU and generic IRIG signals. Currently, support for the Solaris and SunOS audio API is included in the distribution. It is left to the volunteer corps to extend this support to other systems. Further information on hookup, debugging and monitoring is given in the Audio Drivers page.

    -

    The local clock driver is also a special case. A server configured with this driver can operate as a primary server to synchronize other clients when no other external synchronization sources are available. If the server is connected directly or indirectly to the public Internet, there is some danger that it can adversely affect the operation of unrelated clients. Carefully read the Undisciplined Local Clock page and respect the stratum limit.

    -

    The local clock driver also supports an external synchronization source such as a high resolution counter disciplined by a GPS receiver, for example. Further information is on the External Clock Discipline and the Local Clock Driver page.

    -

    Driver Calibration

    -

    Some drivers depending on longwave and shortwave radio services need to know the radio propagation time from the transmitter to the receiver, which can amount to some tens of milliseconds. This must be calculated for each specific receiver location and requires the geographic coordinates of both the transmitter and receiver. The transmitter coordinates for various radio services are given in the Time and Frequency Standard Station Information page. Receiver coordinates can be obtained or estimated from various sources. The actual calculations are beyond the scope of this document.

    -

    When more than one clock driver is supported, it is often the case that each shows small systematic offset differences relative to the rest. To reduce the effects of jitter when switching from one driver to the another, it is useful to calibrate the drivers to a common ensemble offset. The enable calibrate configuration command in the Miscellaneous Options page is useful for this purpose. The calibration function can also be enabled and disabled using the ntpdc program utility.

    -

    Most clock drivers use the time1 value specified in the fudge configuration command to provide the calibration correction when this cannot be provided by the clock or interface. When the calibration function is enabled, the time1 value is automatically adjusted to match the offset of the remote server or local clock driver selected for synchronization. Ordinarily, the NTP selection algorithm chooses the best from among all sources, usually the best radio clock determined on the basis of stratum, synchronization distance and jitter. The calibration function adjusts the time1 values for all clock drivers except this source so that their indicated offsets tend to zero. If the selected source is the kernel PPS discipline, the fudge time1 values for all clock drivers are adjusted.

    -

    The adjustment function is an exponential average designed to improve accuracy, so the function takes some time to converge. The recommended procedure is to enable the function, let it run for an hour or so, then edit the configuration file using the time1 values displayed by the ntpq utility and clockvar command. Finally, disable the calibration function to avoid possible future disruptions due to misbehaving clocks or drivers.

    -

    Performance Enhancements

    -

    In general, performance can be improved, especially when more than one clock driver is supported, to use the prefer peer function described in the Mitigation Rules and the prefer Keyword page. The prefer peer is ordinarily designated the remote peer or local clock driver which provides the best quality time. All other things equal, only the prefer peer source is used to discipline the system clock and jitter-producing "clockhopping" between sources is avoided. This is valuable when more than one clock driver is present and especially valuable when the PPS clock driver (type 22) is used. Support for PPS signals is summarized in the Pulse-per-second (PPS) Signal Interfacing page.

    -

    Where the highest performance is required, generally better than one millisecond, additional hardware and/or software functions may be required. Kernel modifications for precision time are described in the A Kernel Model for Precision Timekeeping page. Special line discipline and streams modules for use in capturing precision timestamps are described in the Line Disciplines and Streams Drivers page.

    -

    Comprehensive List of Clock Drivers

    -

    Following is a list showing the type and title of each driver currently implemented. The compile-time identifier for each is shown in parentheses. Click on a selected type for specific description and configuration documentation, including the clock address, reference ID, driver ID, device name and serial line speed, and features (line disciplines, etc.). For those drivers without specific documentation, please contact the author listed in the Copyright Notice page.

    -
      -
    • Type 1 Undisciplined Local Clock (LOCAL) -
    • Type 2 Trak 8820 GPS Receiver (GPS_TRAK) -
    • Type 3 PSTI/Traconex 1020 WWV/WWVH Receiver (WWV_PST) -
    • Type 4 Spectracom WWVB and GPS Receivers (WWVB_SPEC) -
    • Type 5 TrueTime GPS/GOES/OMEGA Receivers (TRUETIME) -
    • Type 6 IRIG Audio Decoder (IRIG_AUDIO) -
    • Type 7 Radio CHU Audio Demodulator/Decoder (CHU) -
    • Type 8 Generic Reference Driver (PARSE) -
    • Type 9 Magnavox MX4200 GPS Receiver (GPS_MX4200) -
    • Type 10 Austron 2200A/2201A GPS Receivers (GPS_AS2201) -
    • Type 11 Arbiter 1088A/B GPS Receiver (GPS_ARBITER) -
    • Type 12 KSI/Odetics TPRO/S IRIG Interface (IRIG_TPRO) -
    • Type 13 Leitch CSD 5300 Master Clock Controller (ATOM_LEITCH) -
    • Type 14 EES M201 MSF Receiver (MSF_EES) -
    • Type 15 reserved -
    • Type 16 Bancomm GPS/IRIG Receiver (GPS_BANCOMM) -
    • Type 17 Datum Precision Time System (GPS_DATUM) -
    • Type 18 Automated Computer Time Service (ACTS_MODEM) -
    • Type 19 Heath WWV/WWVH Receiver (WWV_HEATH) -
    • Type 20 Generic NMEA GPS Receiver (NMEA) -
    • Type 21 TrueTime GPS-VME Interface (GPS_VME) -
    • Type 22 PPS Clock Discipline (PPS) -
    • Type 23 reserved -
    • Type 24 reserved -
    • Type 25 reserved -
    • Type 26 Hewlett Packard 58503A GPS Receiver (GPS_HP) -
    • Type 27 Arcron MSF Receiver (MSF_ARCRON) -
    • Type 28 Shared Memory Driver (SHM) -
    • Type 29 Trimble Navigation Palisade GPS (GPS_PALISADE) -
    • Type 30 Motorola UT Oncore GPS GPS_ONCORE) -
    • Type 31 Rockwell Jupiter GPS (GPS_JUPITER) -
    • Type 32 Chrono-log K-series WWVB receiver (CHRONOLOG) -
    • Type 33 Dumb Clock (DUMBCLOCK) -
    • Type 34 Ultralink WWVB Receivers (ULINK) -
    • Type 35 Conrad Parallel Port Radio Clock (PCF) -
    • Type 36 Radio WWV/H Audio Demodulator/Decoder (WWV) -
    • Type 37 Forum Graphic GPS Dating station (FG) -
    • Type 38 hopf GPS/DCF77 6021/komp for Serial Line (HOPF_S) -
    • Type 39 hopf GPS/DCF77 6039 for PCI-Bus (HOPF_P) -
    • Type 40 JJY Receivers (JJY) -
    • Type 41 TrueTime 560 IRIG-B Decoder -
    • Type 42 Zyfer GPStarplus Receiver -
    • Type 43 RIPE NCC interface for Trimble Palisade -
    • Type 44 NeoClock4X - DCF77 / TDF serial line -
    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/release.html src.ntp/contrib/ntp/html/release.html --- src/contrib/ntp/html/release.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/release.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,70 +0,0 @@ - - - - - - - - NTP Version 4 Release Notes - - - - -

    NTP Version 4 Release Notes

    - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

    The rabbit toots to make sure you read this

    -

    Last update: 19:17 UTC Monday, October 10, 2005

    - .
    -
    -

    NTP Version 4 Release Notes

    -

    This release of the NTP Version 4 (NTPv4) daemon for Unix, VMS and Windows incorporates new features and refinements to the NTP Version 3 (NTPv3) algorithms. However, it continues the tradition of retaining backwards compatibility with older versions, including NTPv3 and NTPv2, but not NTPv1. Support for NTPv1 has been discontinued because of certain security vulnerabilities. The NTPv4 version has been under development for quite a while and isn't finished yet. In fact, quite a number of NTPv4 features have already been retrofitted in the older NTPv3, although this version is not actively maintained by the NTPv4 developer corps.

    -

    The code compiles and runs properly in all test host configurations available to the developer corps, including Sun Microsystems, Digital/Compaq, Hewlett Packard, FreeBSD and Linux. Other volunteers have verified it works in IRIX and Windows NT and XP. We invite comments and corrections about the various architectures, operating systems and hardware complement that can't be verified by the developer corps. Of particular interest are other Windows versions, VMS and various reference clock drivers. As always, corrections and bugfixes are warmly received, especially in the form of context diffs sent to bugs@ntp.org.

    -

    This release has been compiled and tested on many systems, including SunOS 4.1.3, Solaris 2.5.1-2.10, Alpha Tru64 4.0-5.1, Ultrix 4.4, Linux 2.4.2, FreeBSD 4.5-5.3 and HP-UX 10.02. It has been compiled and tested by others on Windows NT4, 2000 and XP, but not yet on other Windows versions or for VMS. There are several new features apparently incompatible with Linux systems, including some modes used with the Autokey protocol. The developer corps looks for help elsewhere to resolve these differences.

    -

    This note summarizes the differences between this software release of NTPv4, called ntp-4.x.x, and the previous NTPv3 version, called xntp3-5.x.x. Additional information on protocol compatibility details is on the Protocol Conformance Statement page.

    -

    New Features

    -
      -
    1. Support for the IPv6 addressing family is included in this distribution. If the Basic Socket Interface Extensions for IPv6 (RFC-2553) is detected, support for the IPv6 address family is generated in addition to the default support for the IPv4 address family. Combination IPv6 and IPv4 configurations have been successfully tested in all protocol modes supported by NTP and using both symmetric and public key (Autokey) cryptography. However, users should note that IPv6 support is new and we have not had a lot of experience with it in various operational scenarios and local infrastructure environments. As always, feedback is welcome. -
    2. Most calculations are now done using 64-bit floating double format, rather than 64-bit fixed point format. The motivation for this is to reduce size, improve speed and avoid messy bounds checking. Workstations of today are much faster than when the original NTP version was designed in the early 1980s, and it is rare to find a processor architecture that does not support floating double. The fixed point format is still used with raw timestamps, in order to retain the full precision of about 212 picoseconds. However, the algorithms which process raw timestamps all produce fixed point differences before converting to floating double. The differences are ordinarily quite small so can be expressed without loss of accuracy in this format. - -
    3. The clock discipline algorithm has been redesigned to improve accuracy, reduce the impact of network jitter and allow increased in poll intervals to well over one day with only moderate sacrifice in accuracy. -
    -
      -
        -
      • A new feature called huffpuff maximizes accuracy in cases of highly asymmetric network delays typical of ISDN and modem access circuits. -
      • The NTPv4 design allows clients to increase the poll intervals even when synchronized directly to the server. In NTPv3 the poll interval in such cases was clamped to the minimum, usually 64 s. For those servers with hundreds of clients, the new design can dramatically reduce the network load, especially when large numbers of potential clients, as in national laboratory services. -
      • A scheme designed to reduce "clockhopping" when the choice of servers changes frequently as the result of comparatively insignificant quality changes. -
      -
    -
      -
    1. This release includes support for the nanokernel precision time kernel support, which is now in stock FreeBSD and optional Linux kernels. If a precision time source such as a GPS timing receiver or cesium clock is available, kernel timekeeping can be improved to the order of one microsecond. The older microtime kernel for Digital/Compaq/HP Tru64, Digital Ultrix, as well as Sun Microsystems SunOS and Solaris, continues to be supported. -
    2. This release includes support for Autokey public-key cryptography, which is the preferred scheme for authenticating servers to clients. Autokey Version 2 uses NTP header extension fields and protocols as described on the NTP project page linked from www.ntp.org. This release includes support for additional message digest and digital signature schemes supported by the OpenSSL software library, as well as new identity schemes based on cryptographic challenge/responce algorithms. The new design greatly simplifies key generation and distribution and provides orderly key refreshment. Security procedures and media formats are consistent with industry standard X.509 Version 3 certificates and authority procedures. Specific improvements to the protocol include a reduction in the number of messages required and a method to protect the cookie used in client/server mode against disclosure. Additional information about Autokey cryptography is contained in the Authentication Options page and links from there. See also the new cryptostats monitoring statistics file in the Monitoring Options page. -
    3. This release includes support for a discrete event simulator (DES), which allows the NTP algorithms to be tested in an embedded environment with systematic and pseudorandom network delay and oscillator wander distributions. This has been used to verify correct operation under conditions of extreme error and misconfiguration. See the ntpdsim - Network Time Protocol (NTP) simulator page. -
    4. NTPv4 includes two new association modes which in most applications can avoid per-host configuration altogether. Both of these are based on IP multicast technology and Autokey cryptography. They provide automatic discovery, configuration and authentication of servers and clients without identifying servers or clients in advance. In multicast mode a server sends a message at fixed intervals using specified multicast group addresses, while clients listen on these addresses. -

      Upon receiving the the first message, a client exchanges several messages with the server in order to calibrate the multicast propagation delay between the client and server and run the authentication protocol. In manycast mode a client sends a message to a specified multicast group address and expects one or more servers to reply. Using engineered algorithms, the client selects an appropriate subset of servers from the messages received and continues an ordinary client/server campaign. The manycast scheme can provide somewhat better accuracy than the multicast scheme at the price of additional network overhead. See the Automatic NTP Configuration Options page for further information.

      -
    5. This release includes support for the orphan mode, which replaces the local clock driver for most configurations. The local clock driver provides a synchronization source for networks not connected to the public Internet or reference clock driver. However, it does not opperate with multiple sources nor multiple failures. The orphan mode provides an automatic, subnet-wide synchronization feature with multiple sources. It can be used in isolated networks or in Internet subnets where the servers or Internet connection have failed. See the Automatic NTP Configuration Options page for further information.
    6. This release includes support for preemptable servers, which are provisionally mobilized in manycast mode or by participants in the pool scheme. Manycast mode is described in these notes. In the pool scheme multiple client associations are mobilized for a designated DNS name such as pool.ntp.org. The DNS resolver randomizes replies over a set of volunteer service providers. The NTP mitigation algorithms select the best three from among the set and demobilizes the excess. See the Automatic NTP Configuration Options page for further information.
    7. There are two burst mode features available where special conditions apply. One of these is enabled by the iburst keyword in the server configuration command. It is intended for cases where it is important to set the clock quickly when an association is first mobilized. The other is enabled by the burst keyword in the server configuration command. It is intended for cases where the network attachment requires an initial calling or training procedure. See the Association Management page for further information. -
    8. The reference clock driver interface is smaller, more rational and more accurate. Support for pulse-per-second (PPS) signals has been extended to all drivers as an intrinsic function. Most of the drivers in NTPv3 have been converted to the NTPv4 interface and continue to operate as before. New drivers have been added for several GPS receivers now on the market for a total of 44 drivers. Audio drivers for the Canadian standard time and frequency station CHU, the US standard time and frequency stations WWV/H and for IRIG signals have been updated and capabilities added to allow direct connection of these signals to a Sun or FreeBSD audio port. See the Reference Clock Audio Drivers page for further information. -
    9. In all except a very few cases, all timing intervals are randomized, so that the tendency for NTPv3 to self-synchronize and bunch messages, especially with a large number of configured associations, is minimized. -
    10. In NTPv3 a large number of weeds and useless code had grown over the years since the original NTPv1 code was implemented almost twenty years ago. Using a powerful weedwacker, much of the shrubbery has been removed, with effect a substantial reduction in size of almost 40 percent. -
    11. The entire distribution has been converted to gnu automake, which should greatly ease the task of porting to new and different programming environments, as well as reduce the incidence of bugs due to improper handling of idiosyncratic kernel functions. Version control is provided by Bitkeeper using an online repository at www.ntp.org. -
    12. Several new options have been added for the ntpd command line. For the inveterate knob twiddlers several of the more important performance variables can be changed to fit actual or perceived special conditions. In particular, the tos command can be used to limit the accepted stratum range, specify minimum dispersion increment and maximum selection theshold, and activate orphan mode. -
    13. The ntpd daemon can be operated in a one-time mode similar to ntpdate, which program is headed for retirement. See the ntpd - Network Time Protocol (NTP) daemon page for the new features. -
    -

    Nasty Surprises

    -

    There are a few things different about this release that have changed since the latest NTP Version 3 release. Following are a few things to worry about:

    -
      -
    1. When both IPv4 and IPv6 address families are in use, the host's resolver library may not choose the intended address family if a server has an IPv4 and IPv6 address associated with the same DNS name. The solution is to use the IPv4 or IPv6 address directly in such cases or use another DNS name that resolves to the intended address family. Older versions of ntpdc will only show the IPv4 associations with the peers and other simular commands. Older versions of ntpq will show 0.0.0.0 for IPv6 associations with the peers and other simular commands. -
    2. There is a minor change to the reference ID field of the NTP packet header when operating with IPv6 associations. In IPv4 associations this field contains the 32-bit IPv4 address of the server, in order to detect and avoid loops. In IPv6 associations this field contains the first 32-bits of a MD5 hash formed from the address (IPv4 or IPv6) each of the configured associations. Normally, this detail would not be of concern; however, the ntptrace program originally depended on that field in order to display a server traceback to the primary reference source. This program has now been replaced by a script that does the same function, but does not depend on the reference ID field. The ntpdc utility now uses a special version number to communicate with the ntpd server. The server uses this version number to select which address family to used in reply packets. The ntpdc program falls back to the older version behavior when communicating with older NTP versions. -
    3. As required by Defense Trade Regulations (DTR), the cryptographic routines supporting the Data Encryption Standard (DES) have been removed from the base distribution of NTPv3. For NTPv4 a new interface has been implemented for the OpenSSL cryptographic library, which is widely available on the web at www.openssl.org. This library replaces the library formerly available from RSA Laboratories. Besides being somewhat faster and more widely available, the OpenSSL library supports many additional cryptographic algorithms, which are now selectable at run time. Directions for using OpenSSL are in the Building and Installing the Distribution page. -
    4. As the result of the above, the ./authstuff directory, intended as a development and testing aid for porting cryptographic routines to exotic architectures, has been removed. Testing and conformance validation tools are in the OpenSSL software distrbution. -
    5. The NTPv4 enable and disable commands have a few changes in the arguments. See the ntpd Miscellaneous Options page for details. Note that the authenticate command has been removed. -
    6. To help reduce the level of spurious network traffic due to obsolete configuration files, a special control message called the kiss-o'-death packet has been implemented. If enabled and a packet is denied service or exceeds the client limits, a compliant server will send this message to the client. A compliant client will cease further transmission and send a message to the system log. See the Authentication Options page for further information. -
    7. The tty_clk and ppsclock pulse-per-second (PPS) line discipline/streams modules are no longer supported. The PPS function is now handled by the PPS Clock Discipline driver, which uses the new PPSAPI application program interface adopted by the IETF. Note that the pps configuration file command has been obsoleted by the driver. See the Pulse-per-second (PPS) Signal Interfacing page for further information. -
    8. Support for the NTPv1 symmetric mode has been discontinued, since it hasn't worked for years. Support continues for the NTPv1 client mode, which is used in some SNTP clients. -
    9. The precision time support in stock Solaris 2.6 has bugs that were fixed in 2.7. A patch is available that fixes the 2.6 bugs. The 2.6 PPS kernel discipline has been disabled by default. For testing, the kernel can be enabled using the enable kernel command either in the configuration file or via ntpdc. -
    10. The HTML documentation has been partially updated. However, most of the NTPv3 documentation continues to apply to NTPv4. Until a comprehensive update happens, what you see is what you get. We are always happy to accept comments, corrections and bug reports. However, we are most thrilled upon receipt of patches to fix the dang bugs. Please send bug reports to bugs@ntp.org, not the individual members on the team. -
    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/scripts/footer.txt src.ntp/contrib/ntp/html/scripts/footer.txt --- src/contrib/ntp/html/scripts/footer.txt 2004-07-20 17:01:11.000000000 +0200 +++ src.ntp/contrib/ntp/html/scripts/footer.txt 1970-01-01 01:00:00.000000000 +0100 @@ -1,7 +0,0 @@ -document.write("\ -\ -\ -\ -
    gif\ -Home Pagegif\ -Contacts
    ") \ No newline at end of file diff -urN src/contrib/ntp/html/scripts/links10.txt src.ntp/contrib/ntp/html/scripts/links10.txt --- src/contrib/ntp/html/scripts/links10.txt 2004-07-20 17:01:12.000000000 +0200 +++ src.ntp/contrib/ntp/html/scripts/links10.txt 1970-01-01 01:00:00.000000000 +0100 @@ -1,5 +0,0 @@ -document.write("") \ No newline at end of file diff -urN src/contrib/ntp/html/scripts/links11.txt src.ntp/contrib/ntp/html/scripts/links11.txt --- src/contrib/ntp/html/scripts/links11.txt 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/scripts/links11.txt 1970-01-01 01:00:00.000000000 +0100 @@ -1,7 +0,0 @@ -document.write("") \ No newline at end of file diff -urN src/contrib/ntp/html/scripts/links12.txt src.ntp/contrib/ntp/html/scripts/links12.txt --- src/contrib/ntp/html/scripts/links12.txt 2004-07-20 17:01:12.000000000 +0200 +++ src.ntp/contrib/ntp/html/scripts/links12.txt 1970-01-01 01:00:00.000000000 +0100 @@ -1,5 +0,0 @@ -document.write("") \ No newline at end of file diff -urN src/contrib/ntp/html/scripts/links7.txt src.ntp/contrib/ntp/html/scripts/links7.txt --- src/contrib/ntp/html/scripts/links7.txt 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/scripts/links7.txt 1970-01-01 01:00:00.000000000 +0100 @@ -1,6 +0,0 @@ -document.write("") \ No newline at end of file diff -urN src/contrib/ntp/html/scripts/links8.txt src.ntp/contrib/ntp/html/scripts/links8.txt --- src/contrib/ntp/html/scripts/links8.txt 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/scripts/links8.txt 1970-01-01 01:00:00.000000000 +0100 @@ -1,6 +0,0 @@ -document.write("") \ No newline at end of file diff -urN src/contrib/ntp/html/scripts/links9.txt src.ntp/contrib/ntp/html/scripts/links9.txt --- src/contrib/ntp/html/scripts/links9.txt 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/scripts/links9.txt 1970-01-01 01:00:00.000000000 +0100 @@ -1,8 +0,0 @@ -document.write("") \ No newline at end of file diff -urN src/contrib/ntp/html/scripts/style.css src.ntp/contrib/ntp/html/scripts/style.css --- src/contrib/ntp/html/scripts/style.css 2004-07-20 17:01:12.000000000 +0200 +++ src.ntp/contrib/ntp/html/scripts/style.css 1970-01-01 01:00:00.000000000 +0100 @@ -1,64 +0,0 @@ -body {background: #FDF1E1; - color: #006600; - font-family: "verdana", sans-serif; - text-align: justify; - margin-left: 5px;} - -p, h4, hr, li {margin-top: .6em; margin-bottom: .6em} -li.inline {text-align: left; margin-top: 0; margin-bottom: 0} - -ul, dl, ol, {margin-top: .6em; margin-bottom: .6em; margin-left 5em} - -dt {margin-top: .6em} -dd {margin-bottom: .6em} - -div.header {text-align: center; - font-style: italic;} - -div.footer {text-align: center; - font-size: 60%;} - -img.cell {align: left;} - -td.sidebar {width: 40px; align: center; valign: top;} -img.sidebar {align: center; margin-top: 5px;} -h4.sidebar {align: center;} - -p.top {background: #FDF1E1; - color: #006600; - position: absolute; - margin-left: -90px; - text-align: center;} - -a:link.sidebar {background: transparent; - color: #990033; - font-weight: bold;} - -a:visited.sidebar {background: transparent; - color: #990033; - font-weight: bold;} - -a:hover.sidebar {background: #FDF1E1; - color: #006600;} - -img {margin: 5px;} - -div {text-align: center;} - -h1 {text-align: center; - font-size: 250%;} - -caption {background: #EEEEEE; - color: #339999;} - -tx {text-align: center;} - -th {background: #FFFFCC; - color: #006600; - text-align: center; - text-decoration: underline; - padding-top: 5px;} - -th.caption {background: #EEEEEE; - color: #006600; - text-align: center;} \ No newline at end of file diff -urN src/contrib/ntp/html/sntp.html src.ntp/contrib/ntp/html/sntp.html --- src/contrib/ntp/html/sntp.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/sntp.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,57 +0,0 @@ - - - - - - - Simple Network Time Protocol (SNTP) Client - - - - -

    Simple Network Time Protocol (SNTP) Client

    - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

    S is for snakeoil

    -

    Last update: 18:50 UTC Thursday, July 28, 2005

    -
    -
    -

    Synopsis

    - sntp [{-h --help -?}][{ -v -V -W }][{-r -a}][-P prompt][-e minerr][-E maxerr][-c count][-d delay][address(es)] -

    Description

    -

    This program is a Simple Network Time Protocol (SNTP) client that can be used to query a Network TIme Protocol (NTP) server and display the time offset of the system clock relative to the server clock. Run as root it can correct the system clock to this offset as well. It can be run as an interactive command or from a script by a cron job. The program implements the SNTP protocol defined in RFC-2030, which is a subset of the NTP protocol defined in RFC-1305, but does not provide the sanity checks, access controls, security functions and mitigation algorithms as in the full NTP implementation.

    -

    While this program can do other things, including operation as a primitive server, some of these things are truly dangerous in a ubiquitous public time server network. A full disclosure is in the man page in the ./sntp directory, but be truly advised RFC-2030 specifically forbids a SNTP client to operate as a server for other NTP or SNTP clients. If such operation is contemplated, do not allow access by clients on the public Internet.

    -

    By default, sntp writes the local date and time (i.e., not UTC) to the standard output in the format

    -

    1996 Oct 15 20:17:25.123 + 4.567 +/- 0.089 secs,

    -

    where the + 4.567 +/- 0.089 secs indicates the time offset and error bound of the system clock relative to the server clock.

    -

    If a NTP server address is explicitly specified, the program sends a single message to the server and waits up to delay seconds for a unicast server message. Otherwise, it sends no message and waits up to delay seconds for a broadcast server message.

    -

    Options

    -

    sntp recognizes the following options:

    -
    -
    -h, --help -
    displays usage information. -
    -v -
    writes diagnostic messages and a limited amount of tracing to standard error. The -v, -V and -W give increasing levels of detail. -
    -r -
    steps the system clock to the correct time by the Unix settimeofday system call. Requires root priviledge. -
    -a -
    slews the system clock to the correct time by the Unix adjtime system call. Requires root priviledge. -
    -e minerr -
    sets the minimum offset to minerr seconds. Measured offsets less than this are ignored. Acceptable values are from 0.001 to 1 with default 0.1 if unicast mode and 0.5 for broadcast mode. -
    -E maxerr -
    sets the maximum offset to maxerr seconds. Measured offsets greater than this are ignored. Acceptable values are from 1 to 60 with default 5. -
    -P prompt -
    sets the maximum automatic offset to maxerr seconds. Acceptable values are from 1 to 3600 or no, with default 30. If the program is being run interactively, measured offsets greater than this will prompt the user for confirmation. Specifying no will disable this and the correction will be made regardless. -
    -c count -
    sets the maximum number of NTP packets required to count. Acceptable values are from 1 to 25 in unicast mode and 5 to 25 in broadcast mode. The default is 5 in either mode. -
    -d delay -
    sets the maximum waiting time in broadcast mode to delay seconds. Acceptable values are from 1 to 3600, with default 15 in unicast mode and 300 in broadcast mode. -
    -

    Return Value

    -

    The program returns an exit status of zero for success and non-zero otherwise.

    -

    Author

    -

    sntp was developed by N.M. Maclaren of the University of Cambridge Computing Service.

    -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/html/tickadj.html src.ntp/contrib/ntp/html/tickadj.html --- src/contrib/ntp/html/tickadj.html 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/html/tickadj.html 1970-01-01 01:00:00.000000000 +0100 @@ -1,49 +0,0 @@ - - - - - - - - tickadj - set time-related kernel variables - - - - -

    tickadj - set time-related kernel variables

    -

    Last update: 18:50 UTC Thursday, July 28, 2005

    -
    -

    Synopsis

    - tickadj [ -Aqs ] [ -a tickadj ] [ -t tick ] -

    Description

    -

    The tickadj program reads, and optionally modifies, several timekeeping-related variables in older kernels that do not have support for precision ttimekeeping, including HP-UX, SunOS, Ultrix, SGI and probably others. Those machines provide means to patch the kernel /dev/kmem. Newer machines with precision time support, including Solaris, Tru64, FreeBSD and Linux (with PPSkit patch) should NOT use the program. The particular variables that can be changed with tickadj include tick, which is the number of microseconds added to the system time for a clock interrupt, tickadj, which sets the slew rate and resolution used by the adjtime system call, and dosynctodr, which indicates to the kernels on some machines whether they should internally adjust the system clock to keep it in line with time-of-day clock or not.

    -

    By default, with no arguments, tickadj reads the variables of interest in the kernel and displays them. At the same time, it determines an "optimal" value for the value of the tickadj variable if the intent is to run the ntpd Network Time Protocol (NTP) daemon, and prints this as well. Since the operation of tickadj when reading the kernel mimics the operation of similar parts of the ntpd program fairly closely, this can be useful when debugging problems with ntpd.

    -

    Note that tickadj should be run with some caution when being used for the first time on different types of machines. The operations which tickadj tries to perform are not guaranteed to work on all Unix machines and may in rare cases cause the kernel to crash.

    -

    Command Line Options

    -
    -
    -a tickadj -
    Set the kernel variable tickadj to the value tickadjspecified. -
    -A -
    Set the kernel variable tickadj to an internally computed "optimal" value. -
    -t tick -
    Set the kernel variable tick to the value tick specified. -
    -s -
    Set the kernel variable dosynctodr to zero, which disables the hardware time-of-year clock, a prerequisite for running the ntpd daemon under SunOS4. -
    -q -
    Normally, tickadj is quite verbose about what it is doing. The -q flag tells it to shut up about everything except errors. -
    -

    Files

    -
    -/vmunix
    -
    -/unix
    -
    -/dev/kmem
    -
    -

    Bugs

    - Fiddling with kernel variables at run time as a part of ordinary operations is a hideous practice which is only necessary to make up for deficiencies in the implementation of adjtime in many kernels and/or brokenness of the system clock in some vendors' kernels. It would be much better if the kernels were fixed and the tickadj program went away. -
    - - - - \ No newline at end of file diff -urN src/contrib/ntp/include/Makefile.am src.ntp/contrib/ntp/include/Makefile.am --- src/contrib/ntp/include/Makefile.am 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/Makefile.am 2009-12-25 10:03:41.000000000 +0100 @@ -1,63 +1,71 @@ -#AUTOMAKE_OPTIONS = ../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr +NULL = +AUTOMAKE_OPTIONS = ETAGS_ARGS = $(srcdir)/Makefile.am -EXTRA_DIST = autogen-version.def copyright.def debug-opt.def homerc.def version.def +EXTRA_DIST = autogen-version.def copyright.def debug-opt.def homerc.def version.def version.texi SUBDIRS = isc -noinst_HEADERS = \ - adjtime.h \ - audio.h \ - ascii.h \ - audio.h \ - binio.h \ - global.h \ - gps.h \ - hopf6039.h \ - icom.h \ - ieee754io.h \ - iosignal.h \ - l_stdlib.h \ - mbg_gps166.h \ - mx4200.h \ - ntif.h \ - ntp.h \ - ntp_calendar.h \ - ntp_cmdargs.h \ - ntp_config.h \ - ntp_control.h \ - ntp_crypto.h \ - ntp_datum.h \ - ntp_debug.h \ - ntp_filegen.h \ - ntp_fp.h \ - ntp_if.h \ - ntp_io.h \ - ntp_machine.h \ - ntp_malloc.h \ - ntp_md5.h \ - ntp_proto.h \ - ntp_random.h \ - ntp_refclock.h \ - ntp_request.h \ - ntp_rfc2553.h \ - ntp_select.h \ - ntp_sprintf.h \ - ntp_stdlib.h \ - ntp_string.h \ - ntp_syscall.h \ - ntp_syslog.h \ - ntp_tty.h \ - ntp_types.h \ - ntp_unixtime.h \ - ntpd.h \ - ntpsim.h \ - parse.h \ - parse_conf.h \ - recvbuff.h \ - rsa_md5.h \ +noinst_HEADERS = \ + adjtime.h \ + audio.h \ + ascii.h \ + audio.h \ + binio.h \ + gps.h \ + hopf6039.h \ + icom.h \ + ieee754io.h \ + iosignal.h \ + l_stdlib.h \ + lib_strbuf.h \ + mbg_gps166.h \ + mx4200.h \ + ntif.h \ + ntp.h \ + ntp_assert.h \ + ntp_calendar.h \ + ntp_cmdargs.h \ + ntp_config.h \ + ntp_control.h \ + ntp_crypto.h \ + ntp_data_structures.h \ + ntp_datum.h \ + ntp_debug.h \ + ntp_filegen.h \ + ntp_fp.h \ + ntp_if.h \ + ntp_intres.h \ + ntp_io.h \ + ntp_lineedit.h \ + ntp_lists.h \ + ntp_machine.h \ + ntp_malloc.h \ + ntp_md5.h \ + ntp_net.h \ + ntp_proto.h \ + ntp_random.h \ + ntp_refclock.h \ + ntp_request.h \ + ntp_rfc2553.h \ + ntp_select.h \ + ntp_sprintf.h \ + ntp_stdlib.h \ + ntp_string.h \ + ntp_syscall.h \ + ntp_syslog.h \ + ntp_tty.h \ + ntp_types.h \ + ntp_unixtime.h \ + ntpd.h \ + ntpsim.h \ + parse.h \ + parse_conf.h \ + recvbuff.h \ + refclock_atom.h \ + ssl_applink.c \ timepps-SCO.h \ timepps-Solaris.h \ timepps-SunOS.h \ - trimble.h + trimble.h \ + $(NULL) diff -urN src/contrib/ntp/include/Makefile.in src.ntp/contrib/ntp/include/Makefile.in --- src/contrib/ntp/include/Makefile.in 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/include/Makefile.in 2010-07-09 04:21:31.000000000 +0200 @@ -40,7 +40,11 @@ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ + $(top_srcdir)/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/m4/ntp_openssl.m4 \ + $(top_srcdir)/m4/ntp_vpathhack.m4 \ $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ @@ -96,7 +100,6 @@ ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -117,6 +120,7 @@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EF_LIBS = @EF_LIBS@ EF_PROGS = @EF_PROGS@ EGREP = @EGREP@ @@ -148,6 +152,7 @@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ @@ -164,18 +169,22 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ PATH_SEPARATOR = @PATH_SEPARATOR@ PATH_SH = @PATH_SH@ PROPDELAY = @PROPDELAY@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ VERSION = @VERSION@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ @@ -227,67 +236,74 @@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ - -#AUTOMAKE_OPTIONS = ../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr +NULL = +AUTOMAKE_OPTIONS = ETAGS_ARGS = $(srcdir)/Makefile.am -EXTRA_DIST = autogen-version.def copyright.def debug-opt.def homerc.def version.def +EXTRA_DIST = autogen-version.def copyright.def debug-opt.def homerc.def version.def version.texi SUBDIRS = isc noinst_HEADERS = \ - adjtime.h \ - audio.h \ - ascii.h \ - audio.h \ - binio.h \ - global.h \ - gps.h \ - hopf6039.h \ - icom.h \ - ieee754io.h \ - iosignal.h \ - l_stdlib.h \ - mbg_gps166.h \ - mx4200.h \ - ntif.h \ - ntp.h \ - ntp_calendar.h \ - ntp_cmdargs.h \ - ntp_config.h \ - ntp_control.h \ - ntp_crypto.h \ - ntp_datum.h \ - ntp_debug.h \ - ntp_filegen.h \ - ntp_fp.h \ - ntp_if.h \ - ntp_io.h \ - ntp_machine.h \ - ntp_malloc.h \ - ntp_md5.h \ - ntp_proto.h \ - ntp_random.h \ - ntp_refclock.h \ - ntp_request.h \ - ntp_rfc2553.h \ - ntp_select.h \ - ntp_sprintf.h \ - ntp_stdlib.h \ - ntp_string.h \ - ntp_syscall.h \ - ntp_syslog.h \ - ntp_tty.h \ - ntp_types.h \ - ntp_unixtime.h \ - ntpd.h \ - ntpsim.h \ - parse.h \ - parse_conf.h \ - recvbuff.h \ - rsa_md5.h \ + adjtime.h \ + audio.h \ + ascii.h \ + audio.h \ + binio.h \ + gps.h \ + hopf6039.h \ + icom.h \ + ieee754io.h \ + iosignal.h \ + l_stdlib.h \ + lib_strbuf.h \ + mbg_gps166.h \ + mx4200.h \ + ntif.h \ + ntp.h \ + ntp_assert.h \ + ntp_calendar.h \ + ntp_cmdargs.h \ + ntp_config.h \ + ntp_control.h \ + ntp_crypto.h \ + ntp_data_structures.h \ + ntp_datum.h \ + ntp_debug.h \ + ntp_filegen.h \ + ntp_fp.h \ + ntp_if.h \ + ntp_intres.h \ + ntp_io.h \ + ntp_lineedit.h \ + ntp_lists.h \ + ntp_machine.h \ + ntp_malloc.h \ + ntp_md5.h \ + ntp_net.h \ + ntp_proto.h \ + ntp_random.h \ + ntp_refclock.h \ + ntp_request.h \ + ntp_rfc2553.h \ + ntp_select.h \ + ntp_sprintf.h \ + ntp_stdlib.h \ + ntp_string.h \ + ntp_syscall.h \ + ntp_syslog.h \ + ntp_tty.h \ + ntp_types.h \ + ntp_unixtime.h \ + ntpd.h \ + ntpsim.h \ + parse.h \ + parse_conf.h \ + recvbuff.h \ + refclock_atom.h \ + ssl_applink.c \ timepps-SCO.h \ timepps-Solaris.h \ timepps-SunOS.h \ - trimble.h + trimble.h \ + $(NULL) all: all-recursive diff -urN src/contrib/ntp/include/audio.h src.ntp/contrib/ntp/include/audio.h --- src/contrib/ntp/include/audio.h 2004-07-20 17:01:13.000000000 +0200 +++ src.ntp/contrib/ntp/include/audio.h 2009-12-09 08:36:35.000000000 +0100 @@ -9,6 +9,6 @@ /* * Function prototypes */ -int audio_init P((char *, int, int)); -int audio_gain P((int, int, int)); -void audio_show P((void)); +int audio_init (char *, int, int); +int audio_gain (int, int, int); +void audio_show (void); diff -urN src/contrib/ntp/include/binio.h src.ntp/contrib/ntp/include/binio.h --- src/contrib/ntp/include/binio.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/binio.h 2009-12-09 08:36:36.000000000 +0100 @@ -37,15 +37,15 @@ #include "ntp_stdlib.h" -long get_lsb_short P((unsigned char **)); -void put_lsb_short P((unsigned char **, long)); -long get_lsb_long P((unsigned char **)); -void put_lsb_long P((unsigned char **, long)); +long get_lsb_short (unsigned char **); +void put_lsb_short (unsigned char **, long); +long get_lsb_long (unsigned char **); +void put_lsb_long (unsigned char **, long); -long get_msb_short P((unsigned char **)); -void put_msb_short P((unsigned char **, long)); -long get_msb_long P((unsigned char **)); -void put_msb_long P((unsigned char **, long)); +long get_msb_short (unsigned char **); +void put_msb_short (unsigned char **, long); +long get_msb_long (unsigned char **); +void put_msb_long (unsigned char **, long); #endif /* diff -urN src/contrib/ntp/include/copyright.def src.ntp/contrib/ntp/include/copyright.def --- src/contrib/ntp/include/copyright.def 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/include/copyright.def 2010-01-24 11:01:46.000000000 +0100 @@ -1,7 +1,7 @@ /* -*- Mode: Text -*- */ copyright = { - date = "1970-2009"; + date = "1970-2010"; owner = "David L. Mills and/or others"; eaddr = "http://bugs.ntp.org, bugs@ntp.org"; type = note; @@ -16,3 +16,5 @@ eval VERSION=\`sed -e 's/.*,\\[//' -e 's/\\].*//' < ../version.m4\` [ -z "${VERSION}" ] && echo "Cannot determine VERSION" && kill -TERM $AG_pid echo $VERSION`; + +version-value = ''; /* Don't use -v as a shortcut for --version */ diff -urN src/contrib/ntp/include/debug-opt.def src.ntp/contrib/ntp/include/debug-opt.def --- src/contrib/ntp/include/debug-opt.def 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/debug-opt.def 2009-12-09 08:36:35.000000000 +0100 @@ -11,7 +11,6 @@ name = debug-level; value = d; max = NOLIMIT; - ifdef = DEBUG; nopreset; descrip = "Increase output debug message level"; doc = <<- _EndOfDoc_ @@ -23,7 +22,6 @@ name = set-debug-level; value = D; max = NOLIMIT; - ifdef = DEBUG; descrip = "Set the output debug message level"; arg-type = string; flag-code = 'DESC(DEBUG_LEVEL).optOccCt = atoi( pOptDesc->pzLastArg );'; diff -urN src/contrib/ntp/include/global.h src.ntp/contrib/ntp/include/global.h --- src/contrib/ntp/include/global.h 2001-08-29 16:35:10.000000000 +0200 +++ src.ntp/contrib/ntp/include/global.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,54 +0,0 @@ -/* GLOBAL.H - RSAREF types and constants */ - -/* Copyright (C) RSA Laboratories, a division of RSA Data Security, - Inc., created 1991. All rights reserved. - */ - -/* - * Note: the modifications are necessary for little-endian machines - */ -#include "ntp_types.h" /* local modification */ - -#ifndef _GLOBAL_H_ -#define _GLOBAL_H_ 1 - -/* PROTOTYPES should be set to one if and only if the compiler supports - function argument prototyping. - The following makes PROTOTYPES default to 1 if it has not already been - defined as 0 with C compiler flags. - */ -#ifdef HAVE_PROTOTYPES -#define PROTOTYPES 1 -#endif - -/* POINTER defines a generic pointer type */ -typedef unsigned char *POINTER; - -/* UINT2 defines a two byte word */ -typedef unsigned short int UINT2; - -/* UINT4 defines a four byte word */ -typedef u_int32 UINT4; /* local modification */ - -/* BYTE defines a unsigned character */ -typedef unsigned char BYTE; /* local modification for RSAEuro */ - -#ifndef NULL_PTR -#define NULL_PTR ((POINTER)0) -#endif - -#ifndef UNUSED_ARG -#define UNUSED_ARG(x) x = *(&x); -#endif - -/* PROTO_LIST is defined depending on how PROTOTYPES is defined above. - If using PROTOTYPES, then PROTO_LIST returns the list, otherwise it - returns an empty list. - */ -#if PROTOTYPES -#define PROTO_LIST(list) list -#else -#define PROTO_LIST(list) () -#endif - -#endif /* end _GLOBAL_H_ */ diff -urN src/contrib/ntp/include/icom.h src.ntp/contrib/ntp/include/icom.h --- src/contrib/ntp/include/icom.h 2000-01-28 15:51:33.000000000 +0100 +++ src.ntp/contrib/ntp/include/icom.h 2009-12-09 08:36:37.000000000 +0100 @@ -83,5 +83,5 @@ /* * Function prototypes */ -int icom_init P((char *, int, int)); -int icom_freq P((int, int, double)); +int icom_init (char *, int, int); +int icom_freq (int, int, double); diff -urN src/contrib/ntp/include/ieee754io.h src.ntp/contrib/ntp/include/ieee754io.h --- src/contrib/ntp/include/ieee754io.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/ieee754io.h 2009-12-09 08:36:36.000000000 +0100 @@ -52,8 +52,8 @@ #define IEEE_OFFSETS 8 /* number of byte positions */ typedef unsigned char offsets_t[IEEE_OFFSETS]; -int fetch_ieee754 P((unsigned char **bufp, int size, l_fp *lfpp, offsets_t offsets)); -int put_ieee754 P((unsigned char **bufpp, int size, l_fp *lfpp, offsets_t offsets)); +int fetch_ieee754 (unsigned char **bufp, int size, l_fp *lfpp, offsets_t offsets); +int put_ieee754 (unsigned char **bufpp, int size, l_fp *lfpp, offsets_t offsets); #endif /* diff -urN src/contrib/ntp/include/iosignal.h src.ntp/contrib/ntp/include/iosignal.h --- src/contrib/ntp/include/iosignal.h 1999-12-09 14:01:07.000000000 +0100 +++ src.ntp/contrib/ntp/include/iosignal.h 2009-12-09 08:36:36.000000000 +0100 @@ -4,15 +4,15 @@ #include "ntp_refclock.h" #if defined(HAVE_SIGNALED_IO) -extern void block_sigio P((void)); -extern void unblock_sigio P((void)); -extern int init_clock_sig P((struct refclockio *)); -extern void init_socket_sig P((int)); -extern void set_signal P((void)); -RETSIGTYPE sigio_handler P((int)); +extern void block_sigio (void); +extern void unblock_sigio (void); +extern int init_clock_sig (struct refclockio *); +extern void init_socket_sig (int); +extern void set_signal (void); +RETSIGTYPE sigio_handler (int); -# define BLOCKIO() ((void) block_sigio()) -# define UNBLOCKIO() ((void) unblock_sigio()) +# define BLOCKIO() block_sigio() +# define UNBLOCKIO() unblock_sigio() #else diff -urN src/contrib/ntp/include/isc/Makefile.am src.ntp/contrib/ntp/include/isc/Makefile.am --- src/contrib/ntp/include/isc/Makefile.am 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/Makefile.am 2009-12-09 08:36:36.000000000 +0100 @@ -1,37 +1,7 @@ -#AUTOMAKE_OPTIONS = ../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr +NULL = +AUTOMAKE_OPTIONS = ETAGS_ARGS = $(srcdir)/Makefile.am -#EXTRA_DIST = TAGS -noinst_HEADERS = \ - app.h \ - assertions.h \ - boolean.h \ - buffer.h \ - error.h \ - formatcheck.h \ - int.h \ - interfaceiter.h \ - ipv6.h \ - lang.h \ - lib.h \ - list.h \ - magic.h \ - mem.h \ - msgcat.h \ - msgs.h \ - mutex.h \ - net.h \ - netaddr.h \ - netscope.h \ - offset.h \ - once.h \ - platform.h \ - print.h \ - result.h \ - region.h \ - sockaddr.h \ - strerror.h \ - string.h \ - types.h \ - util.h +noinst_HEADERS = \ + mem.h \ + $(NULL) diff -urN src/contrib/ntp/include/isc/Makefile.in src.ntp/contrib/ntp/include/isc/Makefile.in --- src/contrib/ntp/include/isc/Makefile.in 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/include/isc/Makefile.in 2010-07-09 04:21:31.000000000 +0200 @@ -40,7 +40,11 @@ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ + $(top_srcdir)/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/m4/ntp_openssl.m4 \ + $(top_srcdir)/m4/ntp_vpathhack.m4 \ $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ @@ -58,7 +62,6 @@ ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -79,6 +82,7 @@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EF_LIBS = @EF_LIBS@ EF_PROGS = @EF_PROGS@ EGREP = @EGREP@ @@ -110,6 +114,7 @@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ @@ -126,18 +131,22 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ PATH_SEPARATOR = @PATH_SEPARATOR@ PATH_SH = @PATH_SH@ PROPDELAY = @PROPDELAY@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ VERSION = @VERSION@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ @@ -189,43 +198,12 @@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ - -#AUTOMAKE_OPTIONS = ../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr +NULL = +AUTOMAKE_OPTIONS = ETAGS_ARGS = $(srcdir)/Makefile.am -#EXTRA_DIST = TAGS noinst_HEADERS = \ - app.h \ - assertions.h \ - boolean.h \ - buffer.h \ - error.h \ - formatcheck.h \ - int.h \ - interfaceiter.h \ - ipv6.h \ - lang.h \ - lib.h \ - list.h \ - magic.h \ - mem.h \ - msgcat.h \ - msgs.h \ - mutex.h \ - net.h \ - netaddr.h \ - netscope.h \ - offset.h \ - once.h \ - platform.h \ - print.h \ - result.h \ - region.h \ - sockaddr.h \ - strerror.h \ - string.h \ - types.h \ - util.h + mem.h \ + $(NULL) all: all-am diff -urN src/contrib/ntp/include/isc/app.h src.ntp/contrib/ntp/include/isc/app.h --- src/contrib/ntp/include/isc/app.h 2004-07-20 17:01:16.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/app.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,212 +0,0 @@ -/* - * Copyright (C) 1999-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: app.h,v 1.1 2001/07/06 19:50:03 gson Exp $ */ - -#ifndef ISC_APP_H -#define ISC_APP_H 1 - -/***** - ***** Module Info - *****/ - -/* - * ISC Application Support - * - * Dealing with program termination can be difficult, especially in a - * multithreaded program. The routines in this module help coordinate - * the shutdown process. They are used as follows by the initial (main) - * thread of the application: - * - * isc_app_start(); Call very early in main(), before - * any other threads have been created. - * - * isc_app_run(); This will post any on-run events, - * and then block until application - * shutdown is requested. A shutdown - * request is made by calling - * isc_app_shutdown(), or by sending - * SIGINT or SIGTERM to the process. - * After isc_app_run() returns, the - * application should shutdown itself. - * - * isc_app_finish(); Call very late in main(). - * - * Applications that want to use SIGHUP/isc_app_reload() to trigger reloading - * should check the result of isc_app_run() and call the reload routine if - * the result is ISC_R_RELOAD. They should then call isc_app_run() again - * to resume waiting for reload or termination. - * - * Use of this module is not required. In particular, isc_app_start() is - * NOT an ISC library initialization routine. - * - * MP: - * Clients must ensure that isc_app_start(), isc_app_run(), and - * isc_app_finish() are called at most once. isc_app_shutdown() - * is safe to use by any thread (provided isc_app_start() has been - * called previously). - * - * Reliability: - * No anticipated impact. - * - * Resources: - * None. - * - * Security: - * No anticipated impact. - * - * Standards: - * None. - */ - -#include -#include -#include - -typedef isc_event_t isc_appevent_t; - -#define ISC_APPEVENT_FIRSTEVENT (ISC_EVENTCLASS_APP + 0) -#define ISC_APPEVENT_SHUTDOWN (ISC_EVENTCLASS_APP + 1) -#define ISC_APPEVENT_LASTEVENT (ISC_EVENTCLASS_APP + 65535) - -ISC_LANG_BEGINDECLS - -isc_result_t -isc_app_start(void); -/* - * Start an ISC library application. - * - * Notes: - * This call should be made before any other ISC library call, and as - * close to the beginning of the application as possible. - */ - -isc_result_t -isc_app_onrun(isc_mem_t *mctx, isc_task_t *task, isc_taskaction_t action, - void *arg); -/* - * Request delivery of an event when the application is run. - * - * Requires: - * isc_app_start() has been called. - * - * Returns: - * ISC_R_SUCCESS - * ISC_R_NOMEMORY - */ - -isc_result_t -isc_app_run(void); -/* - * Run an ISC library application. - * - * Notes: - * The caller (typically the initial thread of an application) will - * block until shutdown is requested. When the call returns, the - * caller should start shutting down the application. - * - * Requires: - * isc_app_start() has been called. - * - * Ensures: - * Any events requested via isc_app_onrun() will have been posted (in - * FIFO order) before isc_app_run() blocks. - * - * Returns: - * ISC_R_SUCCESS Shutdown has been requested. - * ISC_R_RELOAD Reload has been requested. - */ - -isc_result_t -isc_app_shutdown(void); -/* - * Request application shutdown. - * - * Notes: - * It is safe to call isc_app_shutdown() multiple times. Shutdown will - * only be triggered once. - * - * Requires: - * isc_app_run() has been called. - * - * Returns: - * ISC_R_SUCCESS - * ISC_R_UNEXPECTED - */ - -isc_result_t -isc_app_reload(void); -/* - * Request application reload. - * - * Requires: - * isc_app_run() has been called. - * - * Returns: - * ISC_R_SUCCESS - * ISC_R_UNEXPECTED - */ - -void -isc_app_finish(void); -/* - * Finish an ISC library application. - * - * Notes: - * This call should be made at or near the end of main(). - * - * Requires: - * isc_app_start() has been called. - * - * Ensures: - * Any resources allocated by isc_app_start() have been released. - */ - -void -isc_app_block(void); -/* - * Indicate that a blocking operation will be performed. - * - * Notes: - * If a blocking operation is in process, a call to isc_app_shutdown() - * or an external signal will abort the program, rather than allowing - * clean shutdown. This is primarily useful for reading user input. - * - * Requires: - * isc_app_start() has been called. - * No other blocking operations are in progress. - */ - -void -isc_app_unblock(void); -/* - * Indicate that a blocking operation is complete. - * - * Notes: - * When a blocking operation has completed, return the program to a - * state where a call to isc_app_shutdown() or an external signal will - * shutdown normally. - * - * Requires: - * isc_app_start() has been called. - * isc_app_block() has been called by the same thread. - */ - - -ISC_LANG_ENDDECLS - -#endif /* ISC_APP_H */ diff -urN src/contrib/ntp/include/isc/assertions.h src.ntp/contrib/ntp/include/isc/assertions.h --- src/contrib/ntp/include/isc/assertions.h 2004-07-20 17:01:16.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/assertions.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,120 +0,0 @@ -/* - * Copyright (C) 1997-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* - * $Id: assertions.h,v 1.17 2001/07/12 05:58:21 mayer Exp $ - */ - -#ifndef ISC_ASSERTIONS_H -#define ISC_ASSERTIONS_H 1 - -#include -#include - -ISC_LANG_BEGINDECLS - -typedef enum { - isc_assertiontype_require, - isc_assertiontype_ensure, - isc_assertiontype_insist, - isc_assertiontype_invariant -} isc_assertiontype_t; - -typedef void (*isc_assertioncallback_t)(const char *, int, isc_assertiontype_t, - const char *); - -LIBISC_EXTERNAL_DATA extern isc_assertioncallback_t isc_assertion_failed; - -void -isc_assertion_setcallback(isc_assertioncallback_t); - -const char * -isc_assertion_typetotext(isc_assertiontype_t type); - -#ifdef ISC_CHECK_ALL -#define ISC_CHECK_REQUIRE 1 -#define ISC_CHECK_ENSURE 1 -#define ISC_CHECK_INSIST 1 -#define ISC_CHECK_INVARIANT 1 -#endif - -#ifdef ISC_CHECK_NONE -#define ISC_CHECK_REQUIRE 0 -#define ISC_CHECK_ENSURE 0 -#define ISC_CHECK_INSIST 0 -#define ISC_CHECK_INVARIANT 0 -#endif - -#ifndef ISC_CHECK_REQUIRE -#define ISC_CHECK_REQUIRE 1 -#endif - -#ifndef ISC_CHECK_ENSURE -#define ISC_CHECK_ENSURE 1 -#endif - -#ifndef ISC_CHECK_INSIST -#define ISC_CHECK_INSIST 1 -#endif - -#ifndef ISC_CHECK_INVARIANT -#define ISC_CHECK_INVARIANT 1 -#endif - -#if ISC_CHECK_REQUIRE != 0 -#define ISC_REQUIRE(cond) \ - ((void) ((cond) || \ - ((isc_assertion_failed)(__FILE__, __LINE__, \ - isc_assertiontype_require, \ - #cond), 0))) -#else -#define ISC_REQUIRE(cond) ((void) 0) -#endif /* ISC_CHECK_REQUIRE */ - -#if ISC_CHECK_ENSURE != 0 -#define ISC_ENSURE(cond) \ - ((void) ((cond) || \ - ((isc_assertion_failed)(__FILE__, __LINE__, \ - isc_assertiontype_ensure, \ - #cond), 0))) -#else -#define ISC_ENSURE(cond) ((void) 0) -#endif /* ISC_CHECK_ENSURE */ - -#if ISC_CHECK_INSIST != 0 -#define ISC_INSIST(cond) \ - ((void) ((cond) || \ - ((isc_assertion_failed)(__FILE__, __LINE__, \ - isc_assertiontype_insist, \ - #cond), 0))) -#else -#define ISC_INSIST(cond) ((void) 0) -#endif /* ISC_CHECK_INSIST */ - -#if ISC_CHECK_INVARIANT != 0 -#define ISC_INVARIANT(cond) \ - ((void) ((cond) || \ - ((isc_assertion_failed)(__FILE__, __LINE__, \ - isc_assertiontype_invariant, \ - #cond), 0))) -#else -#define ISC_INVARIANT(cond) ((void) 0) -#endif /* ISC_CHECK_INVARIANT */ - -ISC_LANG_ENDDECLS - -#endif /* ISC_ASSERTIONS_H */ diff -urN src/contrib/ntp/include/isc/boolean.h src.ntp/contrib/ntp/include/isc/boolean.h --- src/contrib/ntp/include/isc/boolean.h 2004-07-20 17:01:16.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/boolean.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,29 +0,0 @@ -/* - * Copyright (C) 1998-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: boolean.h,v 1.12 2001/01/09 21:56:45 bwelling Exp $ */ - -#ifndef ISC_BOOLEAN_H -#define ISC_BOOLEAN_H 1 - -typedef enum { isc_boolean_false = 0, isc_boolean_true = 1 } isc_boolean_t; - -#define ISC_FALSE isc_boolean_false -#define ISC_TRUE isc_boolean_true -#define ISC_TF(x) ((x) ? ISC_TRUE : ISC_FALSE) - -#endif /* ISC_BOOLEAN_H */ diff -urN src/contrib/ntp/include/isc/buffer.h src.ntp/contrib/ntp/include/isc/buffer.h --- src/contrib/ntp/include/isc/buffer.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/buffer.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,800 +0,0 @@ -/* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") - * Copyright (C) 1998-2002 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH - * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY - * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM - * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE - * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: buffer.h,v 1.39.12.2 2004/03/08 09:04:51 marka Exp $ */ - -#ifndef ISC_BUFFER_H -#define ISC_BUFFER_H 1 - -/***** - ***** Module Info - *****/ - -/* - * Buffers - * - * A buffer is a region of memory, together with a set of related subregions. - * Buffers are used for parsing and I/O operations. - * - * The 'used region' and the 'available' region are disjoint, and their - * union is the buffer's region. The used region extends from the beginning - * of the buffer region to the last used byte. The available region - * extends from one byte greater than the last used byte to the end of the - * buffer's region. The size of the used region can be changed using various - * buffer commands. Initially, the used region is empty. - * - * The used region is further subdivided into two disjoint regions: the - * 'consumed region' and the 'remaining region'. The union of these two - * regions is the used region. The consumed region extends from the beginning - * of the used region to the byte before the 'current' offset (if any). The - * 'remaining' region the current pointer to the end of the used - * region. The size of the consumed region can be changed using various - * buffer commands. Initially, the consumed region is empty. - * - * The 'active region' is an (optional) subregion of the remaining region. - * It extends from the current offset to an offset in the remaining region - * that is selected with isc_buffer_setactive(). Initially, the active region - * is empty. If the current offset advances beyond the chosen offset, the - * active region will also be empty. - * - * /------------entire length---------------\ - * /----- used region -----\/-- available --\ - * +----------------------------------------+ - * | consumed | remaining | | - * +----------------------------------------+ - * a b c d e - * - * a == base of buffer. - * b == current pointer. Can be anywhere between a and d. - * c == active pointer. Meaningful between b and d. - * d == used pointer. - * e == length of buffer. - * - * a-e == entire length of buffer. - * a-d == used region. - * a-b == consumed region. - * b-d == remaining region. - * b-c == optional active region. - * - * The following invariants are maintained by all routines: - * - * length > 0 - * - * base is a valid pointer to length bytes of memory - * - * 0 <= used <= length - * - * 0 <= current <= used - * - * 0 <= active <= used - * (although active < current implies empty active region) - * - * MP: - * Buffers have no synchronization. Clients must ensure exclusive - * access. - * - * Reliability: - * No anticipated impact. - * - * Resources: - * Memory: 1 pointer + 6 unsigned integers per buffer. - * - * Security: - * No anticipated impact. - * - * Standards: - * None. - */ - -/*** - *** Imports - ***/ - -#include -#include -#include - -/* - * To make many functions be inline macros (via #define) define this. - * If it is undefined, a function will be used. - */ -#define ISC_BUFFER_USEINLINE - -ISC_LANG_BEGINDECLS - -/*** - *** Magic numbers - ***/ -#define ISC_BUFFER_MAGIC 0x42756621U /* Buf!. */ -#define ISC_BUFFER_VALID(b) ISC_MAGIC_VALID(b, ISC_BUFFER_MAGIC) - -/* - * The following macros MUST be used only on valid buffers. It is the - * caller's responsibility to ensure this by using the ISC_BUFFER_VALID - * check above, or by calling another isc_buffer_*() function (rather than - * another macro.) - */ - -/* - * Fundamental buffer elements. (A through E in the introductory comment.) - */ -#define isc_buffer_base(b) ((void *)(b)->base) /*a*/ -#define isc_buffer_current(b) \ - ((void *)((unsigned char *)(b)->base + (b)->current)) /*b*/ -#define isc_buffer_active(b) \ - ((void *)((unsigned char *)(b)->base + (b)->active)) /*c*/ -#define isc_buffer_used(b) \ - ((void *)((unsigned char *)(b)->base + (b)->used)) /*d*/ -#define isc_buffer_length(b) ((b)->length) /*e*/ - -/* - * Derived lengths. (Described in the introductory comment.) - */ -#define isc_buffer_usedlength(b) ((b)->used) /* d-a */ -#define isc_buffer_consumedlength(b) ((b)->current) /* b-a */ -#define isc_buffer_remaininglength(b) ((b)->used - (b)->current) /* d-b */ -#define isc_buffer_activelength(b) ((b)->active - (b)->current) /* c-b */ -#define isc_buffer_availablelength(b) ((b)->length - (b)->used) /* e-d */ - -/* - * Note that the buffer structure is public. This is principally so buffer - * operations can be implemented using macros. Applications are strongly - * discouraged from directly manipulating the structure. - */ - -struct isc_buffer { - unsigned int magic; - void *base; - /* The following integers are byte offsets from 'base'. */ - unsigned int length; - unsigned int used; - unsigned int current; - unsigned int active; - /* linkable */ - ISC_LINK(isc_buffer_t) link; - /* private internal elements */ - isc_mem_t *mctx; -}; - -/*** - *** Functions - ***/ - -isc_result_t -isc_buffer_allocate(isc_mem_t *mctx, isc_buffer_t **dynbuffer, - unsigned int length); -/* - * Allocate a dynamic linkable buffer which has "length" bytes in the - * data region. - * - * Requires: - * "mctx" is valid. - * - * "dynbuffer" is non-NULL, and "*dynbuffer" is NULL. - * - * Returns: - * ISC_R_SUCCESS - success - * ISC_R_NOMEMORY - no memory available - * - * Note: - * Changing the buffer's length field is not permitted. - */ - -void -isc_buffer_free(isc_buffer_t **dynbuffer); -/* - * Release resources allocated for a dynamic buffer. - * - * Requires: - * "dynbuffer" is not NULL. - * - * "*dynbuffer" is a valid dynamic buffer. - * - * Ensures: - * "*dynbuffer" will be NULL on return, and all memory associated with - * the dynamic buffer is returned to the memory context used in - * isc_buffer_allocate(). - */ - -void -isc__buffer_init(isc_buffer_t *b, const void *base, unsigned int length); -/* - * Make 'b' refer to the 'length'-byte region starting at base. - * - * Requires: - * - * 'length' > 0 - * - * 'base' is a pointer to a sequence of 'length' bytes. - * - */ - -void -isc__buffer_invalidate(isc_buffer_t *b); -/* - * Make 'b' an invalid buffer. - * - * Requires: - * 'b' is a valid buffer. - * - * Ensures: - * If assertion checking is enabled, future attempts to use 'b' without - * calling isc_buffer_init() on it will cause an assertion failure. - */ - -void -isc__buffer_region(isc_buffer_t *b, isc_region_t *r); -/* - * Make 'r' refer to the region of 'b'. - * - * Requires: - * - * 'b' is a valid buffer. - * - * 'r' points to a region structure. - */ - -void -isc__buffer_usedregion(isc_buffer_t *b, isc_region_t *r); -/* - * Make 'r' refer to the used region of 'b'. - * - * Requires: - * - * 'b' is a valid buffer. - * - * 'r' points to a region structure. - */ - -void -isc__buffer_availableregion(isc_buffer_t *b, isc_region_t *r); -/* - * Make 'r' refer to the available region of 'b'. - * - * Requires: - * - * 'b' is a valid buffer. - * - * 'r' points to a region structure. - */ - -void -isc__buffer_add(isc_buffer_t *b, unsigned int n); -/* - * Increase the 'used' region of 'b' by 'n' bytes. - * - * Requires: - * - * 'b' is a valid buffer - * - * used + n <= length - * - */ - -void -isc__buffer_subtract(isc_buffer_t *b, unsigned int n); -/* - * Decrease the 'used' region of 'b' by 'n' bytes. - * - * Requires: - * - * 'b' is a valid buffer - * - * used >= n - * - */ - -void -isc__buffer_clear(isc_buffer_t *b); -/* - * Make the used region empty. - * - * Requires: - * - * 'b' is a valid buffer - * - * Ensures: - * - * used = 0 - * - */ - -void -isc__buffer_consumedregion(isc_buffer_t *b, isc_region_t *r); -/* - * Make 'r' refer to the consumed region of 'b'. - * - * Requires: - * - * 'b' is a valid buffer. - * - * 'r' points to a region structure. - */ - -void -isc__buffer_remainingregion(isc_buffer_t *b, isc_region_t *r); -/* - * Make 'r' refer to the remaining region of 'b'. - * - * Requires: - * - * 'b' is a valid buffer. - * - * 'r' points to a region structure. - */ - -void -isc__buffer_activeregion(isc_buffer_t *b, isc_region_t *r); -/* - * Make 'r' refer to the active region of 'b'. - * - * Requires: - * - * 'b' is a valid buffer. - * - * 'r' points to a region structure. - */ - -void -isc__buffer_setactive(isc_buffer_t *b, unsigned int n); -/* - * Sets the end of the active region 'n' bytes after current. - * - * Requires: - * - * 'b' is a valid buffer. - * - * current + n <= used - */ - -void -isc__buffer_first(isc_buffer_t *b); -/* - * Make the consumed region empty. - * - * Requires: - * - * 'b' is a valid buffer - * - * Ensures: - * - * current == 0 - * - */ - -void -isc__buffer_forward(isc_buffer_t *b, unsigned int n); -/* - * Increase the 'consumed' region of 'b' by 'n' bytes. - * - * Requires: - * - * 'b' is a valid buffer - * - * current + n <= used - * - */ - -void -isc__buffer_back(isc_buffer_t *b, unsigned int n); -/* - * Decrease the 'consumed' region of 'b' by 'n' bytes. - * - * Requires: - * - * 'b' is a valid buffer - * - * n <= current - * - */ - -void -isc_buffer_compact(isc_buffer_t *b); -/* - * Compact the used region by moving the remaining region so it occurs - * at the start of the buffer. The used region is shrunk by the size of - * the consumed region, and the consumed region is then made empty. - * - * Requires: - * - * 'b' is a valid buffer - * - * Ensures: - * - * current == 0 - * - * The size of the used region is now equal to the size of the remaining - * region (as it was before the call). The contents of the used region - * are those of the remaining region (as it was before the call). - */ - -isc_uint8_t -isc_buffer_getuint8(isc_buffer_t *b); -/* - * Read an unsigned 8-bit integer from 'b' and return it. - * - * Requires: - * - * 'b' is a valid buffer. - * - * The length of the available region of 'b' is at least 1. - * - * Ensures: - * - * The current pointer in 'b' is advanced by 1. - * - * Returns: - * - * A 8-bit unsigned integer. - */ - -void -isc__buffer_putuint8(isc_buffer_t *b, isc_uint8_t val); -/* - * Store an unsigned 8-bit integer from 'val' into 'b'. - * - * Requires: - * 'b' is a valid buffer. - * - * The length of the unused region of 'b' is at least 1. - * - * Ensures: - * The used pointer in 'b' is advanced by 1. - */ - -isc_uint16_t -isc_buffer_getuint16(isc_buffer_t *b); -/* - * Read an unsigned 16-bit integer in network byte order from 'b', convert - * it to host byte order, and return it. - * - * Requires: - * - * 'b' is a valid buffer. - * - * The length of the available region of 'b' is at least 2. - * - * Ensures: - * - * The current pointer in 'b' is advanced by 2. - * - * Returns: - * - * A 16-bit unsigned integer. - */ - -void -isc__buffer_putuint16(isc_buffer_t *b, isc_uint16_t val); -/* - * Store an unsigned 16-bit integer in host byte order from 'val' - * into 'b' in network byte order. - * - * Requires: - * 'b' is a valid buffer. - * - * The length of the unused region of 'b' is at least 2. - * - * Ensures: - * The used pointer in 'b' is advanced by 2. - */ - -isc_uint32_t -isc_buffer_getuint32(isc_buffer_t *b); -/* - * Read an unsigned 32-bit integer in network byte order from 'b', convert - * it to host byte order, and return it. - * - * Requires: - * - * 'b' is a valid buffer. - * - * The length of the available region of 'b' is at least 4. - * - * Ensures: - * - * The current pointer in 'b' is advanced by 4. - * - * Returns: - * - * A 32-bit unsigned integer. - */ - -void -isc__buffer_putuint32(isc_buffer_t *b, isc_uint32_t val); -/* - * Store an unsigned 32-bit integer in host byte order from 'val' - * into 'b' in network byte order. - * - * Requires: - * 'b' is a valid buffer. - * - * The length of the unused region of 'b' is at least 4. - * - * Ensures: - * The used pointer in 'b' is advanced by 4. - */ - -void -isc__buffer_putmem(isc_buffer_t *b, const unsigned char *base, - unsigned int length); -/* - * Copy 'length' bytes of memory at 'base' into 'b'. - * - * Requires: - * 'b' is a valid buffer. - * - * 'base' points to 'length' bytes of valid memory. - * - */ - -void -isc__buffer_putstr(isc_buffer_t *b, const char *source); -/* - * Copy 'source' into 'b', not including terminating NUL. - * - * Requires: - * 'b' is a valid buffer. - * - * 'source' to be a valid NULL terminated string. - * - * strlen(source) <= isc_buffer_available(b) - */ - -isc_result_t -isc_buffer_copyregion(isc_buffer_t *b, const isc_region_t *r); -/* - * Copy the contents of 'r' into 'b'. - * - * Requires: - * 'b' is a valid buffer. - * - * 'r' is a valid region. - * - * Returns: - * - * ISC_R_SUCCESS - * ISC_R_NOSPACE The available region of 'b' is not - * big enough. - */ - -ISC_LANG_ENDDECLS - -/* - * Inline macro versions of the functions. These should never be called - * directly by an application, but will be used by the functions within - * buffer.c. The callers should always use "isc_buffer_*()" names, never - * ones beginning with "isc__" - */ - -/* - * XXXDCL Something more could be done with initializing buffers that - * point to const data. For example, a new function, isc_buffer_initconst, - * could be used, and a new boolean flag in the buffer structure could - * indicate whether the buffer was initialized with that function. - * (isc_bufer_init itself would be reprototyped to *not* have its "base" - * parameter be const.) Then if the boolean were true, the isc_buffer_put* - * functions could assert a contractual requirement for a non-const buffer. - * One drawback is that the isc_buffer_* functions (macros) that return - * pointers would still need to return non-const pointers to avoid compiler - * warnings, so it would be up to code that uses them to have to deal - * with the possibility that the buffer was initialized as const -- - * a problem that they *already* have to deal with but have absolutely - * no ability to. With a new isc_buffer_isconst() function returning - * true/false, they could at least assert a contractual requirement for - * non-const buffers when needed. - */ -#define ISC__BUFFER_INIT(_b, _base, _length) \ - do { \ - union { \ - const void * konst; \ - void * var; \ - } _u; \ - _u.konst = (_base); \ - (_b)->base = _u.var; \ - (_b)->length = (_length); \ - (_b)->used = 0; \ - (_b)->current = 0; \ - (_b)->active = 0; \ - (_b)->mctx = NULL; \ - ISC_LINK_INIT(_b, link); \ - (_b)->magic = ISC_BUFFER_MAGIC; \ - } while (0) - -#define ISC__BUFFER_INVALIDATE(_b) \ - do { \ - (_b)->magic = 0; \ - (_b)->base = NULL; \ - (_b)->length = 0; \ - (_b)->used = 0; \ - (_b)->current = 0; \ - (_b)->active = 0; \ - } while (0) - -#define ISC__BUFFER_REGION(_b, _r) \ - do { \ - (_r)->base = (_b)->base; \ - (_r)->length = (_b)->length; \ - } while (0) - -#define ISC__BUFFER_USEDREGION(_b, _r) \ - do { \ - (_r)->base = (_b)->base; \ - (_r)->length = (_b)->used; \ - } while (0) - -#define ISC__BUFFER_AVAILABLEREGION(_b, _r) \ - do { \ - (_r)->base = isc_buffer_used(_b); \ - (_r)->length = isc_buffer_availablelength(_b); \ - } while (0) - -#define ISC__BUFFER_ADD(_b, _n) \ - do { \ - (_b)->used += (_n); \ - } while (0) - -#define ISC__BUFFER_SUBTRACT(_b, _n) \ - do { \ - (_b)->used -= (_n); \ - if ((_b)->current > (_b)->used) \ - (_b)->current = (_b)->used; \ - if ((_b)->active > (_b)->used) \ - (_b)->active = (_b)->used; \ - } while (0) - -#define ISC__BUFFER_CLEAR(_b) \ - do { \ - (_b)->used = 0; \ - (_b)->current = 0; \ - (_b)->active = 0; \ - } while (0) - -#define ISC__BUFFER_CONSUMEDREGION(_b, _r) \ - do { \ - (_r)->base = (_b)->base; \ - (_r)->length = (_b)->current; \ - } while (0) - -#define ISC__BUFFER_REMAININGREGION(_b, _r) \ - do { \ - (_r)->base = isc_buffer_current(_b); \ - (_r)->length = isc_buffer_remaininglength(_b); \ - } while (0) - -#define ISC__BUFFER_ACTIVEREGION(_b, _r) \ - do { \ - if ((_b)->current < (_b)->active) { \ - (_r)->base = isc_buffer_current(_b); \ - (_r)->length = isc_buffer_activelength(_b); \ - } else { \ - (_r)->base = NULL; \ - (_r)->length = 0; \ - } \ - } while (0) - -#define ISC__BUFFER_SETACTIVE(_b, _n) \ - do { \ - (_b)->active = (_b)->current + (_n); \ - } while (0) - -#define ISC__BUFFER_FIRST(_b) \ - do { \ - (_b)->current = 0; \ - } while (0) - -#define ISC__BUFFER_FORWARD(_b, _n) \ - do { \ - (_b)->current += (_n); \ - } while (0) - -#define ISC__BUFFER_BACK(_b, _n) \ - do { \ - (_b)->current -= (_n); \ - } while (0) - -#define ISC__BUFFER_PUTMEM(_b, _base, _length) \ - do { \ - memcpy(isc_buffer_used(_b), (_base), (_length)); \ - (_b)->used += (_length); \ - } while (0) - -#define ISC__BUFFER_PUTSTR(_b, _source) \ - do { \ - unsigned int _length; \ - unsigned char *_cp; \ - _length = strlen(_source); \ - _cp = isc_buffer_used(_b); \ - memcpy(_cp, (_source), _length); \ - (_b)->used += (_length); \ - } while (0) - -#define ISC__BUFFER_PUTUINT8(_b, _val) \ - do { \ - unsigned char *_cp; \ - isc_uint8_t _val2 = (_val); \ - _cp = isc_buffer_used(_b); \ - (_b)->used++; \ - _cp[0] = _val2 & 0x00ff; \ - } while (0) - -#define ISC__BUFFER_PUTUINT16(_b, _val) \ - do { \ - unsigned char *_cp; \ - isc_uint16_t _val2 = (_val); \ - _cp = isc_buffer_used(_b); \ - (_b)->used += 2; \ - _cp[0] = (unsigned char)((_val2 & 0xff00U) >> 8); \ - _cp[1] = (unsigned char)(_val2 & 0x00ffU); \ - } while (0) - -#define ISC__BUFFER_PUTUINT32(_b, _val) \ - do { \ - unsigned char *_cp; \ - isc_uint32_t _val2 = (_val); \ - _cp = isc_buffer_used(_b); \ - (_b)->used += 4; \ - _cp[0] = (unsigned char)((_val2 & 0xff000000) >> 24); \ - _cp[1] = (unsigned char)((_val2 & 0x00ff0000) >> 16); \ - _cp[2] = (unsigned char)((_val2 & 0x0000ff00) >> 8); \ - _cp[3] = (unsigned char)((_val2 & 0x000000ff)); \ - } while (0) - -#if defined(ISC_BUFFER_USEINLINE) -#define isc_buffer_init ISC__BUFFER_INIT -#define isc_buffer_invalidate ISC__BUFFER_INVALIDATE -#define isc_buffer_region ISC__BUFFER_REGION -#define isc_buffer_usedregion ISC__BUFFER_USEDREGION -#define isc_buffer_availableregion ISC__BUFFER_AVAILABLEREGION -#define isc_buffer_add ISC__BUFFER_ADD -#define isc_buffer_subtract ISC__BUFFER_SUBTRACT -#define isc_buffer_clear ISC__BUFFER_CLEAR -#define isc_buffer_consumedregion ISC__BUFFER_CONSUMEDREGION -#define isc_buffer_remainingregion ISC__BUFFER_REMAININGREGION -#define isc_buffer_activeregion ISC__BUFFER_ACTIVEREGION -#define isc_buffer_setactive ISC__BUFFER_SETACTIVE -#define isc_buffer_first ISC__BUFFER_FIRST -#define isc_buffer_forward ISC__BUFFER_FORWARD -#define isc_buffer_back ISC__BUFFER_BACK -#define isc_buffer_putmem ISC__BUFFER_PUTMEM -#define isc_buffer_putstr ISC__BUFFER_PUTSTR -#define isc_buffer_putuint8 ISC__BUFFER_PUTUINT8 -#define isc_buffer_putuint16 ISC__BUFFER_PUTUINT16 -#define isc_buffer_putuint32 ISC__BUFFER_PUTUINT32 -#else -#define isc_buffer_init isc__buffer_init -#define isc_buffer_invalidate isc__buffer_invalidate -#define isc_buffer_region isc__buffer_region -#define isc_buffer_usedregion isc__buffer_usedregion -#define isc_buffer_availableregion isc__buffer_availableregion -#define isc_buffer_add isc__buffer_add -#define isc_buffer_subtract isc__buffer_subtract -#define isc_buffer_clear isc__buffer_clear -#define isc_buffer_consumedregion isc__buffer_consumedregion -#define isc_buffer_remainingregion isc__buffer_remainingregion -#define isc_buffer_activeregion isc__buffer_activeregion -#define isc_buffer_setactive isc__buffer_setactive -#define isc_buffer_first isc__buffer_first -#define isc_buffer_forward isc__buffer_forward -#define isc_buffer_back isc__buffer_back -#define isc_buffer_putmem isc__buffer_putmem -#define isc_buffer_putstr isc__buffer_putstr -#define isc_buffer_putuint8 isc__buffer_putuint8 -#define isc_buffer_putuint16 isc__buffer_putuint16 -#define isc_buffer_putuint32 isc__buffer_putuint32 -#endif - -#endif /* ISC_BUFFER_H */ diff -urN src/contrib/ntp/include/isc/error.h src.ntp/contrib/ntp/include/isc/error.h --- src/contrib/ntp/include/isc/error.h 2004-07-20 17:01:16.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/error.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,55 +0,0 @@ -/* - * Copyright (C) 1998-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: error.h,v 1.13 2001/01/09 21:56:51 bwelling Exp $ */ - -#ifndef ISC_ERROR_H -#define ISC_ERROR_H 1 - -#include - -#include -#include - -ISC_LANG_BEGINDECLS - -typedef void (*isc_errorcallback_t)(const char *, int, const char *, va_list); - -void -isc_error_setunexpected(isc_errorcallback_t); - -void -isc_error_setfatal(isc_errorcallback_t); - -void -isc_error_unexpected(const char *, int, const char *, ...) - ISC_FORMAT_PRINTF(3, 4); - -void -isc_error_fatal(const char *, int, const char *, ...) - ISC_FORMAT_PRINTF(3, 4); - -void -isc_error_runtimecheck(const char *, int, const char *); - -#define ISC_ERROR_RUNTIMECHECK(cond) \ - ((void) ((cond) || \ - ((isc_error_runtimecheck)(__FILE__, __LINE__, #cond), 0))) - -ISC_LANG_ENDDECLS - -#endif /* ISC_ERROR_H */ diff -urN src/contrib/ntp/include/isc/formatcheck.h src.ntp/contrib/ntp/include/isc/formatcheck.h --- src/contrib/ntp/include/isc/formatcheck.h 2004-07-20 17:01:16.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/formatcheck.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,34 +0,0 @@ -/* - * Copyright (C) 2000, 2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: formatcheck.h,v 1.6 2001/01/09 21:56:55 bwelling Exp $ */ - -#ifndef ISC_FORMATCHECK_H -#define ISC_FORMATCHECK_H 1 - -/* - * fmt is the location of the format string parameter. - * args is the location of the first argument (or 0 for no argument checking). - * Note: the first parameter is 1, not 0. - */ -#ifdef __GNUC__ -#define ISC_FORMAT_PRINTF(fmt, args) __attribute__((__format__(__printf__, fmt, args))) -#else -#define ISC_FORMAT_PRINTF(fmt, args) -#endif - -#endif /* ISC_FORMATCHECK_H */ diff -urN src/contrib/ntp/include/isc/int.h src.ntp/contrib/ntp/include/isc/int.h --- src/contrib/ntp/include/isc/int.h 2004-07-20 17:01:16.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/int.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,53 +0,0 @@ -/* - * Copyright (C) 1999-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: int.h,v 1.11 2001/01/09 21:58:39 bwelling Exp $ */ - -#ifndef ISC_INT_H -#define ISC_INT_H 1 - -typedef char isc_int8_t; -typedef unsigned char isc_uint8_t; -typedef short isc_int16_t; -typedef unsigned short isc_uint16_t; -typedef int isc_int32_t; -typedef unsigned int isc_uint32_t; -typedef long long isc_int64_t; -typedef unsigned long long isc_uint64_t; - -#define ISC_INT8_MIN -128 -#define ISC_INT8_MAX 127 -#define ISC_UINT8_MAX 255 - -#define ISC_INT16_MIN -32768 -#define ISC_INT16_MAX 32767 -#define ISC_UINT16_MAX 65535 - -/* - * Note that "int" is 32 bits on all currently supported Unix-like operating - * systems, but "long" can be either 32 bits or 64 bits, thus the 32 bit - * constants are not qualified with "L". - */ -#define ISC_INT32_MIN -2147483648 -#define ISC_INT32_MAX 2147483647 -#define ISC_UINT32_MAX 4294967295U - -#define ISC_INT64_MIN -9223372036854775808LL -#define ISC_INT64_MAX 9223372036854775807LL -#define ISC_UINT64_MAX 18446744073709551615ULL - -#endif /* ISC_INT_H */ diff -urN src/contrib/ntp/include/isc/interfaceiter.h src.ntp/contrib/ntp/include/isc/interfaceiter.h --- src/contrib/ntp/include/isc/interfaceiter.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/interfaceiter.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,139 +0,0 @@ -/* - * Copyright (C) 1999-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: interfaceiter.h,v 1.10 2001/01/09 21:57:01 bwelling Exp $ */ - -#ifndef ISC_INTERFACEITER_H -#define ISC_INTERFACEITER_H 1 - -/***** - ***** Module Info - *****/ - -/* - * Interface iterator - * - * Iterate over the list of network interfaces. - * - * Interfaces whose address family is not supported are ignored and never - * returned by the iterator. Interfaces whose netmask, interface flags, - * or similar cannot be obtained are also ignored, and the failure is logged. - * - * Standards: - * The API for scanning varies greatly among operating systems. - * This module attempts to hide the differences. - */ - -/*** - *** Imports - ***/ - -#include -#include -#include - -/* - * Public structure describing a network interface. - */ - -struct isc_interface { - char name[32]; /* Interface name, null-terminated. */ - unsigned int af; /* Address family. */ - isc_netaddr_t address; /* Local address. */ - isc_netaddr_t netmask; /* Network mask. */ - isc_netaddr_t broadcast; /* Broadcast address. */ - isc_netaddr_t dstaddress; /* Destination address - (point-to-point only). */ - isc_uint32_t flags; /* Flags; see below. */ - unsigned int ifindex; /* Interface Index */ - unsigned int scopeid; /* Scope id for Multicasting */ -}; - -/* Interface flags. */ - -#define INTERFACE_F_UP 0x00000001U /* Interface is up */ -#define INTERFACE_F_POINTTOPOINT 0x00000002U /*this is point-to-point interface*/ -#define INTERFACE_F_LOOPBACK 0x00000004U /* this is loopback interface */ -#define INTERFACE_F_BROADCAST 0x00000008U /* Broadcast is supported */ -#define INTERFACE_F_MULTICAST 0x00000010U /* multicast is supported */ - -/*** - *** Functions - ***/ - -ISC_LANG_BEGINDECLS - -isc_result_t -isc_interfaceiter_create(isc_mem_t *mctx, isc_interfaceiter_t **iterp); -/* - * Create an iterator for traversing the operating system's list - * of network interfaces. - * - * Returns: - * ISC_R_SUCCESS - * ISC_R_NOMEMORY - * Various network-related errors - */ - -isc_result_t -isc_interfaceiter_first(isc_interfaceiter_t *iter); -/* - * Position the iterator on the first interface. - * - * Returns: - * ISC_R_SUCCESS Success. - * ISC_R_NOMORE There are no interfaces. - */ - -isc_result_t -isc_interfaceiter_current(isc_interfaceiter_t *iter, - isc_interface_t *ifdata); -/* - * Get information about the interface the iterator is currently - * positioned at and store it at *ifdata. - * - * Requires: - * The iterator has been successfully positioned using - * isc_interface_iter_first() / isc_interface_iter_next(). - * - * Returns: - * ISC_R_SUCCESS Success. - */ - -isc_result_t -isc_interfaceiter_next(isc_interfaceiter_t *iter); -/* - * Position the iterator on the next interface. - * - * Requires: - * The iterator has been successfully positioned using - * isc_interface_iter_first() / isc_interface_iter_next(). - * - * Returns: - * ISC_R_SUCCESS Success. - * ISC_R_NOMORE There are no more interfaces. - */ - -void -isc_interfaceiter_destroy(isc_interfaceiter_t **iterp); -/* - * Destroy the iterator. - */ - -ISC_LANG_ENDDECLS - -#endif /* ISC_INTERFACEITER_H */ diff -urN src/contrib/ntp/include/isc/ipv6.h src.ntp/contrib/ntp/include/isc/ipv6.h --- src/contrib/ntp/include/isc/ipv6.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/ipv6.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,155 +0,0 @@ -/* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") - * Copyright (C) 1999-2002 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH - * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY - * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM - * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE - * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: ipv6.h,v 1.17.12.4 2004/03/09 05:21:09 marka Exp $ */ - -#ifndef ISC_IPV6_H -#define ISC_IPV6_H 1 - -/* - * Also define LWRES_IPV6_H to keep it from being included if liblwres is - * being used, or redefinition errors will occur. - */ -#define LWRES_IPV6_H 1 - -/***** - ***** Module Info - *****/ - -/* - * IPv6 definitions for systems which do not support IPv6. - * - * MP: - * No impact. - * - * Reliability: - * No anticipated impact. - * - * Resources: - * N/A. - * - * Security: - * No anticipated impact. - * - * Standards: - * RFC 2553. - */ - -/*** - *** Imports. - ***/ - -#include -#include - -/* - * We probably don't need this on NTP - */ -#ifdef ISC_ONLY_IPV6 -/*** - *** Types. - ***/ - -struct in6_addr { - union { - isc_uint8_t _S6_u8[16]; - isc_uint16_t _S6_u16[8]; - isc_uint32_t _S6_u32[4]; - } _S6_un; -}; -#define s6_addr _S6_un._S6_u8 -#define s6_addr8 _S6_un._S6_u8 -#define s6_addr16 _S6_un._S6_u16 -#define s6_addr32 _S6_un._S6_u32 - -#define IN6ADDR_ANY_INIT {{ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 }} -#define IN6ADDR_LOOPBACK_INIT {{ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }} - -LIBISC_EXTERNAL_DATA extern const struct in6_addr in6addr_any; -LIBISC_EXTERNAL_DATA extern const struct in6_addr in6addr_loopback; - -struct sockaddr_in6 { -#ifdef ISC_PLATFORM_HAVESALEN - isc_uint8_t sin6_len; - isc_uint8_t sin6_family; -#else - isc_uint16_t sin6_family; -#endif - isc_uint16_t sin6_port; - isc_uint32_t sin6_flowinfo; - struct in6_addr sin6_addr; - isc_uint32_t sin6_scope_id; -}; - -#ifdef ISC_PLATFORM_HAVESALEN -#define SIN6_LEN 1 -#endif - -/* - * Unspecified - */ -#ifndef IN6_IS_ADDR_UNSPECIFIED -#define IN6_IS_ADDR_UNSPECIFIED(a) \ - (((a)->s6_addr32[0] == 0) && \ - ((a)->s6_addr32[1] == 0) && \ - ((a)->s6_addr32[2] == 0) && \ - ((a)->s6_addr32[3] == 0)) -#endif -/* - * Loopback - */ -#define IN6_IS_ADDR_LOOPBACK(a) \ - (((a)->s6_addr32[0] == 0) && \ - ((a)->s6_addr32[1] == 0) && \ - ((a)->s6_addr32[2] == 0) && \ - ((a)->s6_addr32[3] == htonl(1))) - -/* - * IPv4 compatible - */ -#define IN6_IS_ADDR_V4COMPAT(a) \ - (((a)->s6_addr32[0] == 0) && \ - ((a)->s6_addr32[1] == 0) && \ - ((a)->s6_addr32[2] == 0) && \ - ((a)->s6_addr32[3] != 0) && \ - ((a)->s6_addr32[3] != htonl(1))) - -/* - * Mapped - */ -#define IN6_IS_ADDR_V4MAPPED(a) \ - (((a)->s6_addr32[0] == 0) && \ - ((a)->s6_addr32[1] == 0) && \ - ((a)->s6_addr32[2] == htonl(0x0000ffff))) - -/* - * Multicast - */ -#ifndef IN6_IS_ADDR_MULTICAST -#define IN6_IS_ADDR_MULTICAST(a) \ - ((a)->s6_addr8[0] == 0xffU) -#endif -/* - * Unicast link / site local. - */ -#define IN6_IS_ADDR_LINKLOCAL(a) \ - (((a)->s6_addr[0] == 0xfe) && (((a)->s6_addr[1] & 0xc0) == 0x80)) -#define IN6_IS_ADDR_SITELOCAL(a) \ - (((a)->s6_addr[0] == 0xfe) && (((a)->s6_addr[1] & 0xc0) == 0xc0)) - -#endif /* ISC_ONLY_IPV6 */ -#endif /* ISC_IPV6_H */ diff -urN src/contrib/ntp/include/isc/lang.h src.ntp/contrib/ntp/include/isc/lang.h --- src/contrib/ntp/include/isc/lang.h 2004-07-20 17:01:16.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/lang.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,31 +0,0 @@ -/* - * Copyright (C) 1999-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: lang.h,v 1.6 2001/01/09 21:57:03 bwelling Exp $ */ - -#ifndef ISC_LANG_H -#define ISC_LANG_H 1 - -#ifdef __cplusplus -#define ISC_LANG_BEGINDECLS extern "C" { -#define ISC_LANG_ENDDECLS } -#else -#define ISC_LANG_BEGINDECLS -#define ISC_LANG_ENDDECLS -#endif - -#endif /* ISC_LANG_H */ diff -urN src/contrib/ntp/include/isc/lib.h src.ntp/contrib/ntp/include/isc/lib.h --- src/contrib/ntp/include/isc/lib.h 2004-07-20 17:01:16.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/lib.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,39 +0,0 @@ -/* - * Copyright (C) 1999-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: lib.h,v 1.7 2001/11/19 03:08:25 mayer Exp $ */ - -#ifndef ISC_LIB_H -#define ISC_LIB_H 1 - -#include -#include - -ISC_LANG_BEGINDECLS - -LIBISC_EXTERNAL_DATA extern isc_msgcat_t *isc_msgcat; - -void -isc_lib_initmsgcat(void); -/* - * Initialize the ISC library's message catalog, isc_msgcat, if it - * has not already been initialized. - */ - -ISC_LANG_ENDDECLS - -#endif /* ISC_LIB_H */ diff -urN src/contrib/ntp/include/isc/list.h src.ntp/contrib/ntp/include/isc/list.h --- src/contrib/ntp/include/isc/list.h 2004-07-20 17:01:16.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/list.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,180 +0,0 @@ -/* - * Copyright (C) 1997-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: list.h,v 1.19 2002/05/09 07:09:30 marka Exp $ */ - -#ifndef ISC_LIST_H -#define ISC_LIST_H 1 -#include -#include - -#ifdef ISC_LIST_CHECKINIT -#define ISC_LINK_INSIST(x) ISC_INSIST(x) -#else -#define ISC_LINK_INSIST(x) -#endif - -#define ISC_LIST(type) struct { type *head, *tail; } -#define ISC_LIST_INIT(list) \ - do { (list).head = NULL; (list).tail = NULL; } while (0) - -#define ISC_LINK(type) struct { type *prev, *next; } -#define ISC_LINK_INIT_TYPE(elt, link, type) \ - do { \ - (elt)->link.prev = (type *)(-1); \ - (elt)->link.next = (type *)(-1); \ - } while (0) -#define ISC_LINK_INIT(elt, link) \ - ISC_LINK_INIT_TYPE(elt, link, void) -#define ISC_LINK_LINKED(elt, link) ((void *)((elt)->link.prev) != (void *)(-1)) - -#define ISC_LIST_HEAD(list) ((list).head) -#define ISC_LIST_TAIL(list) ((list).tail) -#define ISC_LIST_EMPTY(list) ISC_TF((list).head == NULL) - -#define __ISC_LIST_PREPENDUNSAFE(list, elt, link) \ - do { \ - if ((list).head != NULL) \ - (list).head->link.prev = (elt); \ - else \ - (list).tail = (elt); \ - (elt)->link.prev = NULL; \ - (elt)->link.next = (list).head; \ - (list).head = (elt); \ - } while (0) - -#define ISC_LIST_PREPEND(list, elt, link) \ - do { \ - ISC_LINK_INSIST(!ISC_LINK_LINKED(elt, link)); \ - __ISC_LIST_PREPENDUNSAFE(list, elt, link); \ - } while (0) - -#define ISC_LIST_INITANDPREPEND(list, elt, link) \ - __ISC_LIST_PREPENDUNSAFE(list, elt, link) - -#define __ISC_LIST_APPENDUNSAFE(list, elt, link) \ - do { \ - if ((list).tail != NULL) \ - (list).tail->link.next = (elt); \ - else \ - (list).head = (elt); \ - (elt)->link.prev = (list).tail; \ - (elt)->link.next = NULL; \ - (list).tail = (elt); \ - } while (0) - -#define ISC_LIST_APPEND(list, elt, link) \ - do { \ - ISC_LINK_INSIST(!ISC_LINK_LINKED(elt, link)); \ - __ISC_LIST_APPENDUNSAFE(list, elt, link); \ - } while (0) - -#define ISC_LIST_INITANDAPPEND(list, elt, link) \ - __ISC_LIST_APPENDUNSAFE(list, elt, link) - -#define __ISC_LIST_UNLINKUNSAFE_TYPE(list, elt, link, type) \ - do { \ - if ((elt)->link.next != NULL) \ - (elt)->link.next->link.prev = (elt)->link.prev; \ - else \ - (list).tail = (elt)->link.prev; \ - if ((elt)->link.prev != NULL) \ - (elt)->link.prev->link.next = (elt)->link.next; \ - else \ - (list).head = (elt)->link.next; \ - (elt)->link.prev = (type *)(-1); \ - (elt)->link.next = (type *)(-1); \ - } while (0) - -#define __ISC_LIST_UNLINKUNSAFE(list, elt, link) \ - __ISC_LIST_UNLINKUNSAFE_TYPE(list, elt, link, void) - -#define ISC_LIST_UNLINK_TYPE(list, elt, link, type) \ - do { \ - ISC_LINK_INSIST(ISC_LINK_LINKED(elt, link)); \ - __ISC_LIST_UNLINKUNSAFE_TYPE(list, elt, link, type); \ - } while (0) -#define ISC_LIST_UNLINK(list, elt, link) \ - ISC_LIST_UNLINK_TYPE(list, elt, link, void) - -#define ISC_LIST_PREV(elt, link) ((elt)->link.prev) -#define ISC_LIST_NEXT(elt, link) ((elt)->link.next) - -#define __ISC_LIST_INSERTBEFOREUNSAFE(list, before, elt, link) \ - do { \ - if ((before)->link.prev == NULL) \ - ISC_LIST_PREPEND(list, elt, link); \ - else { \ - (elt)->link.prev = (before)->link.prev; \ - (before)->link.prev = (elt); \ - (elt)->link.prev->link.next = (elt); \ - (elt)->link.next = (before); \ - } \ - } while (0) - -#define ISC_LIST_INSERTBEFORE(list, before, elt, link) \ - do { \ - ISC_LINK_INSIST(ISC_LINK_LINKED(before, link)); \ - ISC_LINK_INSIST(!ISC_LINK_LINKED(elt, link)); \ - __ISC_LIST_INSERTBEFOREUNSAFE(list, before, elt, link); \ - } while (0) - -#define __ISC_LIST_INSERTAFTERUNSAFE(list, after, elt, link) \ - do { \ - if ((after)->link.next == NULL) \ - ISC_LIST_APPEND(list, elt, link); \ - else { \ - (elt)->link.next = (after)->link.next; \ - (after)->link.next = (elt); \ - (elt)->link.next->link.prev = (elt); \ - (elt)->link.prev = (after); \ - } \ - } while (0) - -#define ISC_LIST_INSERTAFTER(list, after, elt, link) \ - do { \ - ISC_LINK_INSIST(ISC_LINK_LINKED(after, link)); \ - ISC_LINK_INSIST(!ISC_LINK_LINKED(elt, link)); \ - __ISC_LIST_INSERTAFTERUNSAFE(list, after, elt, link); \ - } while (0) - -#define ISC_LIST_APPENDLIST(list1, list2, link) \ - do { \ - if (ISC_LIST_EMPTY(list1)) \ - (list1) = (list2); \ - else if (!ISC_LIST_EMPTY(list2)) { \ - (list1).tail->link.next = (list2).head; \ - (list2).head->link.prev = (list1).tail; \ - (list1).tail = (list2).tail; \ - } \ - (list2).head = NULL; \ - (list2).tail = NULL; \ - } while (0) - -#define ISC_LIST_ENQUEUE(list, elt, link) ISC_LIST_APPEND(list, elt, link) -#define __ISC_LIST_ENQUEUEUNSAFE(list, elt, link) \ - __ISC_LIST_APPENDUNSAFE(list, elt, link) -#define ISC_LIST_DEQUEUE(list, elt, link) \ - ISC_LIST_UNLINK_TYPE(list, elt, link, void) -#define ISC_LIST_DEQUEUE_TYPE(list, elt, link, type) \ - ISC_LIST_UNLINK_TYPE(list, elt, link, type) -#define __ISC_LIST_DEQUEUEUNSAFE(list, elt, link) \ - __ISC_LIST_UNLINKUNSAFE_TYPE(list, elt, link, void) -#define __ISC_LIST_DEQUEUEUNSAFE_TYPE(list, elt, link, type) \ - __ISC_LIST_UNLINKUNSAFE_TYPE(list, elt, link, type) - -#endif /* ISC_LIST_H */ diff -urN src/contrib/ntp/include/isc/magic.h src.ntp/contrib/ntp/include/isc/magic.h --- src/contrib/ntp/include/isc/magic.h 2004-07-20 17:01:16.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/magic.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,40 +0,0 @@ -/* - * Copyright (C) 1999-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: magic.h,v 1.11 2001/01/09 21:57:10 bwelling Exp $ */ - -#ifndef ISC_MAGIC_H -#define ISC_MAGIC_H 1 - -typedef struct { - unsigned int magic; -} isc__magic_t; - - -/* - * To use this macro the magic number MUST be the first thing in the - * structure, and MUST be of type "unsigned int". - * - * The intent of this is to allow magic numbers to be checked even though - * the object is otherwise opaque. - */ -#define ISC_MAGIC_VALID(a,b) (((a) != NULL) && \ - (((const isc__magic_t *)(a))->magic == (b))) - -#define ISC_MAGIC(a, b, c, d) ((a) << 24 | (b) << 16 | (c) << 8 | (d)) - -#endif /* ISC_MAGIC_H */ diff -urN src/contrib/ntp/include/isc/mem.h src.ntp/contrib/ntp/include/isc/mem.h --- src/contrib/ntp/include/isc/mem.h 2004-07-20 17:01:16.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/mem.h 2009-12-09 08:36:37.000000000 +0100 @@ -1,31 +1,55 @@ /* + * libntp local override of isc/mem.h to stub it out. + * + * include/isc is searched before any of the lib/isc include + * directories and should be used only for replacement NTP headers + * overriding headers of the same name under lib/isc. + * + * NOTE: this assumes the system malloc is thread-safe and does + * not use any normal lib/isc locking. + */ + +/* + * Copyright (C) 2004-2009 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1997-2001 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: mem.h,v 1.58 2001/09/07 00:51:51 marka Exp $ */ +/* $Id: mem.h,v 1.78.120.3 2009/02/11 03:07:01 jinmei Exp $ */ #ifndef ISC_MEM_H #define ISC_MEM_H 1 #include + +#include +#include +#include #include +#include + +#include + -void * -isc_mem_get(isc_mem_t *, size_t); -void -isc_mem_put(isc_mem_t *, void *, size_t); +#define isc_mem_get(c, cnt) emalloc((cnt)) +#define isc_mem_allocate(c, cnt) emalloc((cnt)) +#define isc_mem_reallocate(c, mem, cnt) erealloc((mem), (cnt)) +#define isc_mem_put(c, mem, cnt) free((mem)) +#define isc_mem_free(c, mem) free((mem)) +#define isc_mem_strdup(c, str) estrdup((str)) +#define isc_mem_attach(src, ptgt) do { *(ptgt) = (src); } while (0) +#define isc_mem_detach(c) ((void)(c)) +#define isc_mem_printallactive(s) fprintf(s, "isc_mem_printallactive() stubbed.\n") #endif /* ISC_MEM_H */ diff -urN src/contrib/ntp/include/isc/msgcat.h src.ntp/contrib/ntp/include/isc/msgcat.h --- src/contrib/ntp/include/isc/msgcat.h 2004-07-20 17:01:17.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/msgcat.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,132 +0,0 @@ -/* - * Copyright (C) 1999-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: msgcat.h,v 1.8 2001/01/09 21:57:13 bwelling Exp $ */ - -#ifndef ISC_MSGCAT_H -#define ISC_MSGCAT_H 1 - -/***** - ***** Module Info - *****/ - -/* - * ISC Message Catalog - * - * Message catalogs aid internationalization of applications by allowing - * messages to be retrieved from locale-specific files instead of - * hardwiring them into the application. This allows translations of - * messages appropriate to the locale to be supplied without recompiling - * the application. - * - * Notes: - * It's very important that message catalogs work, even if only the - * default_text can be used. - * - * MP: - * The caller must ensure appropriate synchronization of - * isc_msgcat_open() and isc_msgcat_close(). isc_msgcat_get() - * ensures appropriate synchronization. - * - * Reliability: - * No anticipated impact. - * - * Resources: - * - * - * Security: - * No anticipated impact. - * - * Standards: - * None. - */ - -/***** - ***** Imports - *****/ - -#include -#include - -ISC_LANG_BEGINDECLS - -/***** - ***** Methods - *****/ - -void -isc_msgcat_open(const char *name, isc_msgcat_t **msgcatp); -/* - * Open a message catalog. - * - * Notes: - * - * If memory cannot be allocated or other failures occur, *msgcatp - * will be set to NULL. If a NULL msgcat is given to isc_msgcat_get(), - * the default_text will be returned, ensuring that some message text - * will be available, no matter what's going wrong. - * - * Requires: - * - * 'name' is a valid string. - * - * msgcatp != NULL && *msgcatp == NULL - */ - -void -isc_msgcat_close(isc_msgcat_t **msgcatp); -/* - * Close a message catalog. - * - * Notes: - * - * Any string pointers returned by prior calls to isc_msgcat_get() are - * invalid after isc_msgcat_close() has been called and must not be - * used. - * - * Requires: - * - * *msgcatp is a valid message catalog or is NULL. - * - * Ensures: - * - * All resources associated with the message catalog are released. - * - * *msgcatp == NULL - */ - -const char * -isc_msgcat_get(isc_msgcat_t *msgcat, int set, int message, - const char *default_text); -/* - * Get message 'message' from message set 'set' in 'msgcat'. If it - * is not available, use 'default_text'. - * - * Requires: - * - * 'msgcat' is a valid message catalog or is NULL. - * - * set > 0 - * - * message > 0 - * - * 'default_text' is a valid string. - */ - -ISC_LANG_ENDDECLS - -#endif /* ISC_MSGCAT_H */ diff -urN src/contrib/ntp/include/isc/msgs.h src.ntp/contrib/ntp/include/isc/msgs.h --- src/contrib/ntp/include/isc/msgs.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/msgs.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,183 +0,0 @@ -/* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") - * Copyright (C) 2000-2003 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH - * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY - * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM - * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE - * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: msgs.h,v 1.5.2.2.8.3 2004/03/06 08:14:44 marka Exp $ */ - -#ifndef ISC_MSGS_H -#define ISC_MSGS_H 1 - -#include /* Provide isc_msgcat global variable. */ -#include /* Provide isc_msgcat_*() functions. */ - -/* - * Message sets, named per source file, excepting "GENERAL". - * IMPORTANT: The original list is alphabetical, but any new sets must - * be added to the end. - */ -#define ISC_MSGSET_GENERAL 1 -/* ISC_RESULT_RESULTSET 2 */ /* XXX */ -/* ISC_RESULT_UNAVAILABLESET 3 */ /* XXX */ -#define ISC_MSGSET_APP 4 -#define ISC_MSGSET_COMMANDLINE 5 -#define ISC_MSGSET_ENTROPY 6 -#define ISC_MSGSET_IFITERIOCTL 7 -#define ISC_MSGSET_IFITERSYSCTL 8 -#define ISC_MSGSET_LEX 9 -#define ISC_MSGSET_LOG 10 -#define ISC_MSGSET_MEM 11 -#define ISC_MSGSET_NETADDR 12 -#define ISC_MSGSET_PRINT 13 -#define ISC_MSGSET_RESULT 14 -#define ISC_MSGSET_RWLOCK 15 -#define ISC_MSGSET_SOCKADDR 16 -#define ISC_MSGSET_SOCKET 17 -#define ISC_MSGSET_TASK 18 -#define ISC_MSGSET_TIMER 19 -#define ISC_MSGSET_UTIL 20 -#define ISC_MSGSET_IFITERGETIFADDRS 21 - -/* - * Message numbers. They are only required to be unique per message set, - * but are unique throughout the entire catalog to not be as confusing when - * debugging. - * - * The initial numbering was done by multiply by 100 the set number the - * message appears in then adding the incremental message number. - */ -#define ISC_MSG_FAILED 101 /* "failed" */ -#define ISC_MSG_SUCCEEDED 102 /* Compatible with "failed" */ -#define ISC_MSG_SUCCESS 103 /* More usual way to say "success" */ -#define ISC_MSG_STARTING 104 /* As in "daemon: starting" */ -#define ISC_MSG_STOPING 105 /* As in "daemon: stopping" */ -#define ISC_MSG_ENTERING 106 /* As in "some_subr: entering" */ -#define ISC_MSG_EXITING 107 /* As in "some_subr: exiting" */ -#define ISC_MSG_CALLING 108 /* As in "calling some_subr()" */ -#define ISC_MSG_RETURNED 109 /* As in "some_subr: returned " */ -#define ISC_MSG_FATALERROR 110 /* "fatal error" */ -#define ISC_MSG_SHUTTINGDOWN 111 /* "shutting down" */ -#define ISC_MSG_RUNNING 112 /* "running" */ -#define ISC_MSG_WAIT 113 /* "wait" */ -#define ISC_MSG_WAITUNTIL 114 /* "waituntil" */ - -#define ISC_MSG_SIGNALSETUP 201 /* "handle_signal() %d setup: %s" */ - -#define ISC_MSG_ILLEGALOPT 301 /* "illegal option" */ -#define ISC_MSG_OPTNEEDARG 302 /* "option requires an argument" */ - -#define ISC_MSG_ENTROPYSTATS 401 /* "Entropy pool %p: refcnt %u ..." */ - -#define ISC_MSG_MAKESCANSOCKET 501 /* "making interface scan socket: %s" */ -#define ISC_MSG_GETIFCONFIG 502 /* "get interface configuration: %s" */ -#define ISC_MSG_BUFFERMAX 503 /* "... maximum buffer size exceeded" */ -#define ISC_MSG_GETDESTADDR 504 /* "%s: getting destination address: %s" */ -#define ISC_MSG_GETNETMASK 505 /* "%s: getting netmask: %s" */ - -#define ISC_MSG_GETIFLISTSIZE 601 /* "getting interface list size: ..." */ -#define ISC_MSG_GETIFLIST 602 /* "getting interface list: ..." */ -#define ISC_MSG_UNEXPECTEDTYPE 603 /* "... unexpected ... message type" */ - -#define ISC_MSG_UNEXPECTEDSTATE 701 /* "Unexpected state %d" */ - -#define ISC_MSG_BADTIME 801 /* "Bad 00 99:99:99.999 " */ -#define ISC_MSG_LEVEL 802 /* "level %d: " */ - -#define ISC_MSG_ADDTRACE 901 /* "add %p size %u " */ -#define ISC_MSG_DELTRACE 902 /* "del %p size %u " */ -#define ISC_MSG_POOLSTATS 903 /* "[Pool statistics]\n" */ -#define ISC_MSG_POOLNAME 904 /* "name" */ -#define ISC_MSG_POOLSIZE 905 /* "size" */ -#define ISC_MSG_POOLMAXALLOC 906 /* "maxalloc" */ -#define ISC_MSG_POOLALLOCATED 907 /* "allocated" */ -#define ISC_MSG_POOLFREECOUNT 908 /* "freecount" */ -#define ISC_MSG_POOLFREEMAX 909 /* "freemax" */ -#define ISC_MSG_POOLFILLCOUNT 910 /* "fillcount" */ -#define ISC_MSG_POOLGETS 911 /* "gets" */ -#define ISC_MSG_DUMPALLOC 912 /* "DUMP OF ALL OUTSTANDING MEMORY ..." */ -#define ISC_MSG_NONE 913 /* "\tNone.\n" */ -#define ISC_MSG_PTRFILELINE 914 /* "\tptr %p file %s line %u\n" */ - -#define ISC_MSG_UNKNOWNADDR 1001 /* "" */ - -#define ISC_MSG_NOLONGDBL 1104 /* "long doubles are not supported" */ - -#define ISC_MSG_PRINTLOCK 1201 /* "rwlock %p thread %lu ..." */ -#define ISC_MSG_READ 1202 /* "read" */ -#define ISC_MSG_WRITE 1203 /* "write" */ -#define ISC_MSG_READING 1204 /* "reading" */ -#define ISC_MSG_WRITING 1205 /* "writing" */ -#define ISC_MSG_PRELOCK 1206 /* "prelock" */ -#define ISC_MSG_POSTLOCK 1207 /* "postlock" */ -#define ISC_MSG_PREUNLOCK 1208 /* "preunlock" */ -#define ISC_MSG_POSTUNLOCK 1209 /* "postunlock" */ - -#define ISC_MSG_UNKNOWNFAMILY 1301 /* "unknown address family: %d" */ - -#define ISC_MSG_WRITEFAILED 1401 /* "write() failed during watcher ..." */ -#define ISC_MSG_READFAILED 1402 /* "read() failed during watcher ... " */ -#define ISC_MSG_PROCESSCMSG 1403 /* "processing cmsg %p" */ -#define ISC_MSG_IFRECEIVED 1404 /* "interface received on ifindex %u" */ -#define ISC_MSG_SENDTODATA 1405 /* "sendto pktinfo data, ifindex %u" */ -#define ISC_MSG_DOIORECV 1406 /* "doio_recv: recvmsg(%d) %d bytes ..." */ -#define ISC_MSG_PKTRECV 1407 /* "packet received correctly" */ -#define ISC_MSG_DESTROYING 1408 /* "destroying" */ -#define ISC_MSG_CREATED 1409 /* "created" */ -#define ISC_MSG_ACCEPTLOCK 1410 /* "internal_accept called, locked ..." */ -#define ISC_MSG_ACCEPTEDCXN 1411 /* "accepted connection, new socket %p" */ -#define ISC_MSG_INTERNALRECV 1412 /* "internal_recv: task %p got event %p" */ -#define ISC_MSG_INTERNALSEND 1413 /* "internal_send: task %p got event %p" */ -#define ISC_MSG_WATCHERMSG 1414 /* "watcher got message %d" */ -#define ISC_MSG_SOCKETSREMAIN 1415 /* "sockets exist" */ -#define ISC_MSG_PKTINFOPROVIDED 1416 /* "pktinfo structure provided, ..." */ -#define ISC_MSG_BOUND 1417 /* "bound" */ -#define ISC_MSG_ACCEPTRETURNED 1418 /* accept() returned %d/%s */ -#define ISC_MSG_TOOMANYFDS 1419 /* %s: too many open file descriptors */ -#define ISC_MSG_ZEROPORT 1420 /* dropping source port zero packet */ -#define ISC_MSG_FILTER 1420 /* setsockopt(SO_ACCEPTFILTER): %s */ - -#define ISC_MSG_AWAKE 1502 /* "awake" */ -#define ISC_MSG_WORKING 1503 /* "working" */ -#define ISC_MSG_EXECUTE 1504 /* "execute action" */ -#define ISC_MSG_EMPTY 1505 /* "empty" */ -#define ISC_MSG_DONE 1506 /* "done" */ -#define ISC_MSG_QUANTUM 1507 /* "quantum" */ - -#define ISC_MSG_SCHEDULE 1601 /* "schedule" */ -#define ISC_MSG_SIGNALSCHED 1602 /* "signal (schedule)" */ -#define ISC_MSG_SIGNALDESCHED 1603 /* "signal (deschedule)" */ -#define ISC_MSG_SIGNALDESTROY 1604 /* "signal (destroy)" */ -#define ISC_MSG_IDLERESCHED 1605 /* "idle reschedule" */ -#define ISC_MSG_EVENTNOTALLOC 1606 /* "couldn't allocate event" */ -#define ISC_MSG_SCHEDFAIL 1607 /* "couldn't schedule timer: %u" */ -#define ISC_MSG_POSTING 1608 /* "posting" */ -#define ISC_MSG_WAKEUP 1609 /* "wakeup" */ - -#define ISC_MSG_LOCK 1701 /* "LOCK" */ -#define ISC_MSG_LOCKING 1702 /* "LOCKING" */ -#define ISC_MSG_LOCKED 1703 /* "LOCKED" */ -#define ISC_MSG_UNLOCKED 1704 /* "UNLOCKED" */ -#define ISC_MSG_RWLOCK 1705 /* "RWLOCK" */ -#define ISC_MSG_RWLOCKED 1706 /* "RWLOCKED" */ -#define ISC_MSG_RWUNLOCK 1707 /* "RWUNLOCK" */ -#define ISC_MSG_BROADCAST 1708 /* "BROADCAST" */ -#define ISC_MSG_SIGNAL 1709 /* "SIGNAL" */ -#define ISC_MSG_UTILWAIT 1710 /* "WAIT" */ -#define ISC_MSG_WAITED 1711 /* "WAITED" */ - -#define ISC_MSG_GETIFADDRS 1801 /* "getting interface addresses: ..." */ - - -#endif /* ISC_MSGS_H */ diff -urN src/contrib/ntp/include/isc/mutex.h src.ntp/contrib/ntp/include/isc/mutex.h --- src/contrib/ntp/include/isc/mutex.h 2004-07-20 17:01:17.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/mutex.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,39 +0,0 @@ -/* - * Copyright (C) 2000, 2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: mutex.h,v 1.3 2001/01/09 21:57:55 bwelling Exp $ */ - -#ifndef ISC_MUTEX_H -#define ISC_MUTEX_H 1 - -#include /* for ISC_R_ codes */ - -typedef int isc_mutex_t; - -#define isc_mutex_init(mp) \ - (*(mp) = 0, ISC_R_SUCCESS) -#define isc_mutex_lock(mp) \ - ((*(mp))++ == 0 ? ISC_R_SUCCESS : ISC_R_UNEXPECTED) -#define isc_mutex_unlock(mp) \ - (--(*(mp)) == 0 ? ISC_R_SUCCESS : ISC_R_UNEXPECTED) -#define isc_mutex_trylock(mp) \ - (*(mp) == 0 ? ((*(mp))++, ISC_R_SUCCESS) : ISC_R_LOCKBUSY) -#define isc_mutex_destroy(mp) \ - (*(mp) == 0 ? (*(mp) = -1, ISC_R_SUCCESS) : ISC_R_UNEXPECTED) -#define isc_mutex_stats(fp) - -#endif /* ISC_MUTEX_H */ diff -urN src/contrib/ntp/include/isc/net.h src.ntp/contrib/ntp/include/isc/net.h --- src/contrib/ntp/include/isc/net.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/net.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,329 +0,0 @@ -/* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") - * Copyright (C) 1999-2003 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH - * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY - * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM - * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE - * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: net.h,v 1.31.2.2.10.8 2004/04/29 01:31:23 marka Exp $ */ - -#ifndef ISC_NET_H -#define ISC_NET_H 1 - -/***** - ***** Module Info - *****/ - -/* - * Basic Networking Types - * - * This module is responsible for defining the following basic networking - * types: - * - * struct in_addr - * struct in6_addr - * struct in6_pktinfo - * struct sockaddr - * struct sockaddr_in - * struct sockaddr_in6 - * in_port_t - * - * It ensures that the AF_ and PF_ macros are defined. - * - * It declares ntoh[sl]() and hton[sl](). - * - * It declares inet_aton(), inet_ntop(), and inet_pton(). - * - * It ensures that INADDR_LOOPBACK, INADDR_ANY, IN6ADDR_ANY_INIT, - * in6addr_any, and in6addr_loopback are available. - * - * It ensures that IN_MULTICAST() is available to check for multicast - * addresses. - * - * MP: - * No impact. - * - * Reliability: - * No anticipated impact. - * - * Resources: - * N/A. - * - * Security: - * No anticipated impact. - * - * Standards: - * BSD Socket API - * RFC 2553 - */ - -/*** - *** Imports. - ***/ -#include - -#include -#include /* Contractual promise. */ - -#include - -#include /* Contractual promise. */ -#include /* Contractual promise. */ -#ifdef ISC_PLATFORM_NEEDNETINETIN6H -#include /* Required on UnixWare. */ -#endif -#ifdef ISC_PLATFORM_NEEDNETINET6IN6H -#include /* Required on BSD/OS for in6_pktinfo. */ -#endif - -#ifndef ISC_PLATFORM_HAVEIPV6 -#include /* Contractual promise. */ -#endif - -#include -#include - -#ifdef ISC_PLATFORM_HAVEINADDR6 -#define in6_addr in_addr6 /* Required for pre RFC2133 implementations. */ -#endif - -#ifdef ISC_PLATFORM_HAVEIPV6 -/* - * Required for some pre RFC2133 implementations. - * IN6ADDR_ANY_INIT and IN6ADDR_LOOPBACK_INIT were added in - * draft-ietf-ipngwg-bsd-api-04.txt or draft-ietf-ipngwg-bsd-api-05.txt. - * If 's6_addr' is defined then assume that there is a union and three - * levels otherwise assume two levels required. - */ -#ifndef IN6ADDR_ANY_INIT -#ifdef s6_addr -#define IN6ADDR_ANY_INIT { { { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 } } } -#else -#define IN6ADDR_ANY_INIT { { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 } } -#endif -#endif - -#ifndef IN6ADDR_LOOPBACK_INIT -#ifdef s6_addr -#define IN6ADDR_LOOPBACK_INIT { { { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 } } } -#else -#define IN6ADDR_LOOPBACK_INIT { { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 } } -#endif -#endif - -#ifndef IN6_IS_ADDR_V4MAPPED -#define IN6_IS_ADDR_V4MAPPED(x) \ - (memcmp((x)->s6_addr, in6addr_any.s6_addr, 10) == 0 && \ - (x)->s6_addr[10] == 0xff && (x)->s6_addr[11] == 0xff) -#endif - -#ifndef IN6_IS_ADDR_V4COMPAT -#define IN6_IS_ADDR_V4COMPAT(x) \ - (memcmp((x)->s6_addr, in6addr_any.s6_addr, 12) == 0 && \ - ((x)->s6_addr[12] != 0 || (x)->s6_addr[13] != 0 || \ - (x)->s6_addr[14] != 0 || \ - ((x)->s6_addr[15] != 0 && (x)->s6_addr[15] != 1))) -#endif - -#ifndef IN6_IS_ADDR_MULTICAST -#define IN6_IS_ADDR_MULTICAST(a) ((a)->s6_addr[0] == 0xff) -#endif - -#ifndef IN6_IS_ADDR_LINKLOCAL -#define IN6_IS_ADDR_LINKLOCAL(a) \ - (((a)->s6_addr[0] == 0xfe) && (((a)->s6_addr[1] & 0xc0) == 0x80)) -#endif - -#ifndef IN6_IS_ADDR_SITELOCAL -#define IN6_IS_ADDR_SITELOCAL(a) \ - (((a)->s6_addr[0] == 0xfe) && (((a)->s6_addr[1] & 0xc0) == 0xc0)) -#endif - - -#ifndef IN6_IS_ADDR_LOOPBACK -#define IN6_IS_ADDR_LOOPBACK(x) \ - (memcmp((x)->s6_addr, in6addr_loopback.s6_addr, 16) == 0) -#endif -#endif - -#ifndef AF_INET6 -#define AF_INET6 99 -#endif - -#ifndef PF_INET6 -#define PF_INET6 AF_INET6 -#endif - -#ifndef INADDR_LOOPBACK -#define INADDR_LOOPBACK 0x7f000001UL -#endif - -#if 0 -#ifndef ISC_PLATFORM_HAVEIN6PKTINFO -struct in6_pktinfo { - struct in6_addr ipi6_addr; /* src/dst IPv6 address */ - unsigned int ipi6_ifindex; /* send/recv interface index */ -}; -#endif -#endif - -/* - * Cope with a missing in6addr_any and in6addr_loopback. - */ -#if defined(ISC_PLATFORM_HAVEIPV6) && defined(ISC_PLATFORM_NEEDIN6ADDRANY) -extern const struct in6_addr isc_net_in6addrany; -#define in6addr_any isc_net_in6addrany -#endif - -#if defined(ISC_PLATFORM_HAVEIPV6) && defined(ISC_PLATFORM_NEEDIN6ADDRLOOPBACK) -extern const struct in6_addr isc_net_in6addrloop; -#define in6addr_loopback isc_net_in6addrloop -#endif - -/* - * Fix UnixWare 7.1.1's broken IN6_IS_ADDR_* definitions. - */ -#ifdef ISC_PLATFORM_FIXIN6ISADDR -#undef IN6_IS_ADDR_GEOGRAPHIC -#define IN6_IS_ADDR_GEOGRAPHIC(a) (((a)->S6_un.S6_l[0] & 0xE0) == 0x80) -#undef IN6_IS_ADDR_IPX -#define IN6_IS_ADDR_IPX(a) (((a)->S6_un.S6_l[0] & 0xFE) == 0x04) -#undef IN6_IS_ADDR_LINKLOCAL -#define IN6_IS_ADDR_LINKLOCAL(a) (((a)->S6_un.S6_l[0] & 0xC0FF) == 0x80FE) -#undef IN6_IS_ADDR_MULTICAST -#define IN6_IS_ADDR_MULTICAST(a) (((a)->S6_un.S6_l[0] & 0xFF) == 0xFF) -#undef IN6_IS_ADDR_NSAP -#define IN6_IS_ADDR_NSAP(a) (((a)->S6_un.S6_l[0] & 0xFE) == 0x02) -#undef IN6_IS_ADDR_PROVIDER -#define IN6_IS_ADDR_PROVIDER(a) (((a)->S6_un.S6_l[0] & 0xE0) == 0x40) -#undef IN6_IS_ADDR_SITELOCAL -#define IN6_IS_ADDR_SITELOCAL(a) (((a)->S6_un.S6_l[0] & 0xC0FF) == 0xC0FE) -#endif /* ISC_PLATFORM_FIXIN6ISADDR */ - -/* - * Ensure type in_port_t is defined. - */ -#ifdef ISC_PLATFORM_NEEDPORTT -typedef isc_uint16_t in_port_t; -#endif - -/* - * If this system does not have MSG_TRUNC (as returned from recvmsg()) - * ISC_PLATFORM_RECVOVERFLOW will be defined. This will enable the MSG_TRUNC - * faking code in socket.c. - */ -#ifndef MSG_TRUNC -#define ISC_PLATFORM_RECVOVERFLOW -#endif - -#define ISC__IPADDR(x) ((isc_uint32_t)htonl((isc_uint32_t)(x))) - -#define ISC_IPADDR_ISMULTICAST(i) \ - (((isc_uint32_t)(i) & ISC__IPADDR(0xf0000000)) \ - == ISC__IPADDR(0xe0000000)) - -#define ISC_IPADDR_ISEXPERIMENTAL(i) \ - (((isc_uint32_t)(i) & ISC__IPADDR(0xf0000000)) \ - == ISC__IPADDR(0xf0000000)) - -/*** - *** Functions. - ***/ - -ISC_LANG_BEGINDECLS - -isc_result_t -isc_net_probeipv4(void); -/* - * Check if the system's kernel supports IPv4. - * - * Returns: - * - * ISC_R_SUCCESS IPv4 is supported. - * ISC_R_NOTFOUND IPv4 is not supported. - * ISC_R_DISABLED IPv4 is disabled. - * ISC_R_UNEXPECTED - */ - -isc_result_t -isc_net_probeipv6(void); -/* - * Check if the system's kernel supports IPv6. - * - * Returns: - * - * ISC_R_SUCCESS IPv6 is supported. - * ISC_R_NOTFOUND IPv6 is not supported. - * ISC_R_DISABLED IPv6 is disabled. - * ISC_R_UNEXPECTED - */ - -isc_result_t -isc_net_probe_ipv6only(void); -/* - * Check if the system's kernel supports the IPV6_V6ONLY socket option. - * - * Returns: - * - * ISC_R_SUCCESS the option is supported for both TCP and UDP. - * ISC_R_NOTFOUND IPv6 itself or the option is not supported. - * ISC_R_UNEXPECTED - */ - -isc_result_t -isc_net_probe_ipv6pktinfo(void); -/* - * Check if the system's kernel supports the IPV6_(RECV)PKTINFO socket option - * for UDP sockets. - * - * Returns: - * - * ISC_R_SUCCESS the option is supported. - * ISC_R_NOTFOUND IPv6 itself or the option is not supported. - * ISC_R_UNEXPECTED - */ - -void -isc_net_disableipv4(void); - -void -isc_net_disableipv6(void); - -void -isc_net_enableipv4(void); - -void -isc_net_enableipv6(void); - -#ifdef ISC_PLATFORM_NEEDNTOP -const char * -isc_net_ntop(int af, const void *src, char *dst, size_t size); -#define inet_ntop isc_net_ntop -#endif - -#ifdef ISC_PLATFORM_NEEDPTON -int -isc_net_pton(int af, const char *src, void *dst); -#undef inet_pton -#define inet_pton isc_net_pton -#endif - -#ifdef ISC_PLATFORM_NEEDATON -int -isc_net_aton(const char *cp, struct in_addr *addr); -#define inet_aton isc_net_aton -#endif - -ISC_LANG_ENDDECLS - -#endif /* ISC_NET_H */ diff -urN src/contrib/ntp/include/isc/netaddr.h src.ntp/contrib/ntp/include/isc/netaddr.h --- src/contrib/ntp/include/isc/netaddr.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/netaddr.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,149 +0,0 @@ -/* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") - * Copyright (C) 1998-2002 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH - * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY - * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM - * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE - * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: netaddr.h,v 1.18.12.7 2004/03/08 09:04:52 marka Exp $ */ - -#ifndef ISC_NETADDR_H -#define ISC_NETADDR_H 1 - -#include -#include -#include - -ISC_LANG_BEGINDECLS - -struct isc_netaddr { - unsigned int family; - union { - struct in_addr in; - struct in6_addr in6; - } type; - isc_uint32_t zone; -}; - -isc_boolean_t -isc_netaddr_equal(const isc_netaddr_t *a, const isc_netaddr_t *b); - -isc_boolean_t -isc_netaddr_eqprefix(const isc_netaddr_t *a, const isc_netaddr_t *b, - unsigned int prefixlen); -/* - * Compare the 'prefixlen' most significant bits of the network - * addresses 'a' and 'b'. Return ISC_TRUE if they are equal, - * ISC_FALSE if not. - */ - -isc_result_t -isc_netaddr_masktoprefixlen(const isc_netaddr_t *s, unsigned int *lenp); -/* - * Convert a netmask in 's' into a prefix length in '*lenp'. - * The mask should consist of zero or more '1' bits in the most - * most significant part of the address, followed by '0' bits. - * If this is not the case, ISC_R_MASKNONCONTIG is returned. - * - * Returns: - * ISC_R_SUCCESS - * ISC_R_MASKNONCONTIG - */ - -isc_result_t -isc_netaddr_totext(const isc_netaddr_t *netaddr, isc_buffer_t *target); -/* - * Append a text representation of 'sockaddr' to the buffer 'target'. - * The text is NOT null terminated. Handles IPv4 and IPv6 addresses. - * - * Returns: - * ISC_R_SUCCESS - * ISC_R_NOSPACE The text or the null termination did not fit. - * ISC_R_FAILURE Unspecified failure - */ - -void -isc_netaddr_format(const isc_netaddr_t *na, char *array, unsigned int size); -/* - * Format a human-readable representation of the network address '*na' - * into the character array 'array', which is of size 'size'. - * The resulting string is guaranteed to be null-terminated. - */ - -#define ISC_NETADDR_FORMATSIZE \ - sizeof("xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:XXX.XXX.XXX.XXX") -/* - * Minimum size of array to pass to isc_netaddr_format(). - */ - -void -isc_netaddr_fromsockaddr(isc_netaddr_t *netaddr, const isc_sockaddr_t *source); - -void -isc_netaddr_fromin(isc_netaddr_t *netaddr, const struct in_addr *ina); - -void -isc_netaddr_fromin6(isc_netaddr_t *netaddr, const struct in6_addr *ina6); - -void -isc_netaddr_setzone(isc_netaddr_t *netaddr, isc_uint32_t zone); - -isc_uint32_t -isc_netaddr_getzone(const isc_netaddr_t *netaddr); - -void -isc_netaddr_any(isc_netaddr_t *netaddr); -/* - * Return the IPv4 wildcard address. - */ - -void -isc_netaddr_any6(isc_netaddr_t *netaddr); -/* - * Return the IPv6 wildcard address. - */ - -isc_boolean_t -isc_netaddr_ismulticast(isc_netaddr_t *na); -/* - * Returns ISC_TRUE if the address is a multicast address. - */ - -isc_boolean_t -isc_netaddr_isexperimental(isc_netaddr_t *na); -/* - * Returns ISC_TRUE if the address is a experimental (CLASS E) address. - */ - -isc_boolean_t -isc_netaddr_islinklocal(isc_netaddr_t *na); -/* - * Returns ISC_TRUE if the address is a link local address. - */ - -isc_boolean_t -isc_netaddr_issitelocal(isc_netaddr_t *na); -/* - * Returns ISC_TRUE if the address is a site local address. - */ - -void -isc_netaddr_fromv4mapped(isc_netaddr_t *t, const isc_netaddr_t *s); -/* - * Convert an IPv6 v4mapped address into an IPv4 address. - */ - - -ISC_LANG_ENDDECLS - -#endif /* ISC_NETADDR_H */ diff -urN src/contrib/ntp/include/isc/netscope.h src.ntp/contrib/ntp/include/isc/netscope.h --- src/contrib/ntp/include/isc/netscope.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/netscope.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,40 +0,0 @@ -/* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") - * Copyright (C) 2002 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH - * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY - * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM - * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE - * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: netscope.h,v 1.4.142.5 2004/03/08 09:04:52 marka Exp $ */ - -#ifndef ISC_NETSCOPE_H -#define ISC_NETSCOPE_H 1 - -ISC_LANG_BEGINDECLS - -/* - * Convert a string of an IPv6 scope zone to zone index. If the conversion - * succeeds, 'zoneid' will store the index value. - * XXXJT: when a standard interface for this purpose is defined, - * we should use it. - * - * Returns: - * ISC_R_SUCCESS: conversion succeeds - * ISC_R_FAILURE: conversion fails - */ -isc_result_t -isc_netscope_pton(int af, char *scopename, void *addr, isc_uint32_t *zoneid); - -ISC_LANG_ENDDECLS - -#endif /* ISC_NETADDR_H */ diff -urN src/contrib/ntp/include/isc/offset.h src.ntp/contrib/ntp/include/isc/offset.h --- src/contrib/ntp/include/isc/offset.h 2004-07-20 17:01:17.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/offset.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,44 +0,0 @@ -/* - * Copyright (C) 2000, 2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: offset.h,v 1.10 2001/01/09 21:58:43 bwelling Exp $ */ - -#ifndef ISC_OFFSET_H -#define ISC_OFFSET_H 1 - -/* - * File offsets are operating-system dependent. - */ -#include /* Required for CHAR_BIT. */ -#include - -typedef off_t isc_offset_t; - -/* - * POSIX says "Additionally, blkcnt_t and off_t are extended signed integral - * types", so the maximum value is all 1s except for the high bit. - * This definition is more complex than it really needs to be because it was - * crafted to keep both the SunOS 5.6 and the HP/UX 11 compilers quiet about - * integer overflow. For example, though this is equivalent to just left - * shifting 1 to the high bit and then inverting the bits, the SunOS compiler - * is unhappy about shifting a positive "1" to negative in a signed integer. - */ -#define ISC_OFFSET_MAXIMUM \ - (~(((off_t)-1 >> (sizeof(off_t) * CHAR_BIT - 1)) \ - << (sizeof(off_t) * CHAR_BIT - 1))) - -#endif /* ISC_OFFSET_H */ diff -urN src/contrib/ntp/include/isc/once.h src.ntp/contrib/ntp/include/isc/once.h --- src/contrib/ntp/include/isc/once.h 2004-07-20 17:01:17.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/once.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,32 +0,0 @@ -/* - * Copyright (C) 2000, 2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: once.h,v 1.3 2001/01/09 21:57:56 bwelling Exp $ */ - -#ifndef ISC_ONCE_H -#define ISC_ONCE_H 1 - -#include - -typedef isc_boolean_t isc_once_t; - -#define ISC_ONCE_INIT ISC_FALSE - -#define isc_once_do(op, f) \ - (!*(op) ? (f(), *(op) = ISC_TRUE, ISC_R_SUCCESS) : ISC_R_SUCCESS) - -#endif /* ISC_ONCE_H */ diff -urN src/contrib/ntp/include/isc/platform.h src.ntp/contrib/ntp/include/isc/platform.h --- src/contrib/ntp/include/isc/platform.h 2004-07-20 17:01:17.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/platform.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,40 +0,0 @@ -/* - * Copyright (C) 1999-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: platform.h.in,v 1.28 2001/11/19 03:08:26 mayer Exp $ */ - -#ifndef ISC_PLATFORM_H -#define ISC_PLATFORM_H 1 - - -#ifndef ISC_PLATFORM_USEDECLSPEC -#define LIBISC_EXTERNAL_DATA -#define LIBDNS_EXTERNAL_DATA -#define LIBISCCC_EXTERNAL_DATA -#define LIBISCCFG_EXTERNAL_DATA -#define LIBBIND9_EXTERNAL_DATA -#endif /* ISC_PLATFORM_USEDECLSPEC */ - -/* - * Tell emacs to use C mode for this file. - * - * Local Variables: - * mode: c - * End: - */ - -#endif /* ISC_PLATFORM_H */ diff -urN src/contrib/ntp/include/isc/print.h src.ntp/contrib/ntp/include/isc/print.h --- src/contrib/ntp/include/isc/print.h 2004-07-20 17:01:17.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/print.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,69 +0,0 @@ -/* - * Copyright (C) 1999-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: print.h,v 1.17 2001/02/27 02:19:33 gson Exp $ */ - -#ifndef ISC_PRINT_H -#define ISC_PRINT_H 1 - -/*** - *** Imports - ***/ - -#include /* Required for ISC_FORMAT_PRINTF() macro. */ -#include -#include - -/* - * This block allows lib/isc/print.c to be cleanly compiled even if - * the platform does not need it. The standard Makefile will still - * not compile print.c or archive print.o, so this is just to make test - * compilation ("make print.o") easier. - */ -#if !defined(ISC_PLATFORM_NEEDVSNPRINTF) && defined(ISC__PRINT_SOURCE) -#define ISC_PLATFORM_NEEDVSNPRINTF -#endif - -/*** - *** Macros - ***/ -#define ISC_PRINT_QUADFORMAT ISC_PLATFORM_QUADFORMAT - -/*** - *** Functions - ***/ - -#ifdef ISC_PLATFORM_NEEDVSNPRINTF -#include -#include - -ISC_LANG_BEGINDECLS - -int -isc_print_vsnprintf(char *str, size_t size, const char *format, va_list ap) - ISC_FORMAT_PRINTF(3, 0); -#define vsnprintf isc_print_vsnprintf - -int -isc_print_snprintf(char *str, size_t size, const char *format, ...) - ISC_FORMAT_PRINTF(3, 4); -#define snprintf isc_print_snprintf - -ISC_LANG_ENDDECLS -#endif /* ISC_PLATFORM_NEEDVSNPRINTF */ - -#endif /* ISC_PRINT_H */ diff -urN src/contrib/ntp/include/isc/region.h src.ntp/contrib/ntp/include/isc/region.h --- src/contrib/ntp/include/isc/region.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/region.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,95 +0,0 @@ -/* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") - * Copyright (C) 1998-2002 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH - * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY - * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM - * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE - * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: region.h,v 1.16.12.3 2004/03/08 09:04:53 marka Exp $ */ - -#ifndef ISC_REGION_H -#define ISC_REGION_H 1 - -#include - -struct isc_region { - unsigned char * base; - unsigned int length; -}; - -struct isc_textregion { - char * base; - unsigned int length; -}; - -/* XXXDCL questionable ... bears discussion. we have been putting off - * discussing the region api. - */ -struct isc_constregion { - const void * base; - unsigned int length; -}; - -struct isc_consttextregion { - const char * base; - unsigned int length; -}; - -/* - * The region structure is not opaque, and is usually directly manipulated. - * Some macros are defined below for convenience. - */ - -#define isc_region_consume(r,l) \ - do { \ - isc_region_t *_r = (r); \ - unsigned int _l = (l); \ - INSIST(_r->length >= _l); \ - _r->base += _l; \ - _r->length -= _l; \ - } while (0) - -#define isc_textregion_consume(r,l) \ - do { \ - isc_textregion_t *_r = (r); \ - unsigned int _l = (l); \ - INSIST(_r->length >= _l); \ - _r->base += _l; \ - _r->length -= _l; \ - } while (0) - -#define isc_constregion_consume(r,l) \ - do { \ - isc_constregion_t *_r = (r); \ - unsigned int _l = (l); \ - INSIST(_r->length >= _l); \ - _r->base += _l; \ - _r->length -= _l; \ - } while (0) - -int -isc_region_compare(isc_region_t *r1, isc_region_t *r2); -/* - * Compares the contents of two regions - * - * Requires: - * 'r1' is a valid region - * 'r2' is a valid region - * - * Returns: - * < 0 if r1 is lexicographically less than r2 - * = 0 if r1 is lexicographically identical to r2 - * > 0 if r1 is lexicographically greater than r2 - */ - -#endif /* ISC_REGION_H */ diff -urN src/contrib/ntp/include/isc/result.h src.ntp/contrib/ntp/include/isc/result.h --- src/contrib/ntp/include/isc/result.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/result.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,106 +0,0 @@ -/* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") - * Copyright (C) 1998-2001, 2003 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH - * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY - * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM - * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE - * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: result.h,v 1.57.2.2.8.5 2004/05/15 03:46:13 jinmei Exp $ */ - -#ifndef ISC_RESULT_H -#define ISC_RESULT_H 1 - -#include -#include - -#define ISC_R_SUCCESS 0 /* success */ -#define ISC_R_NOMEMORY 1 /* out of memory */ -#define ISC_R_TIMEDOUT 2 /* timed out */ -#define ISC_R_NOTHREADS 3 /* no available threads */ -#define ISC_R_ADDRNOTAVAIL 4 /* address not available */ -#define ISC_R_ADDRINUSE 5 /* address in use */ -#define ISC_R_NOPERM 6 /* permission denied */ -#define ISC_R_NOCONN 7 /* no pending connections */ -#define ISC_R_NETUNREACH 8 /* network unreachable */ -#define ISC_R_HOSTUNREACH 9 /* host unreachable */ -#define ISC_R_NETDOWN 10 /* network down */ -#define ISC_R_HOSTDOWN 11 /* host down */ -#define ISC_R_CONNREFUSED 12 /* connection refused */ -#define ISC_R_NORESOURCES 13 /* not enough free resources */ -#define ISC_R_EOF 14 /* end of file */ -#define ISC_R_BOUND 15 /* socket already bound */ -#define ISC_R_RELOAD 16 /* reload */ -#define ISC_R_LOCKBUSY 17 /* lock busy */ -#define ISC_R_EXISTS 18 /* already exists */ -#define ISC_R_NOSPACE 19 /* ran out of space */ -#define ISC_R_CANCELED 20 /* operation canceled */ -#define ISC_R_NOTBOUND 21 /* socket is not bound */ -#define ISC_R_SHUTTINGDOWN 22 /* shutting down */ -#define ISC_R_NOTFOUND 23 /* not found */ -#define ISC_R_UNEXPECTEDEND 24 /* unexpected end of input */ -#define ISC_R_FAILURE 25 /* generic failure */ -#define ISC_R_IOERROR 26 /* I/O error */ -#define ISC_R_NOTIMPLEMENTED 27 /* not implemented */ -#define ISC_R_UNBALANCED 28 /* unbalanced parentheses */ -#define ISC_R_NOMORE 29 /* no more */ -#define ISC_R_INVALIDFILE 30 /* invalid file */ -#define ISC_R_BADBASE64 31 /* bad base64 encoding */ -#define ISC_R_UNEXPECTEDTOKEN 32 /* unexpected token */ -#define ISC_R_QUOTA 33 /* quota reached */ -#define ISC_R_UNEXPECTED 34 /* unexpected error */ -#define ISC_R_ALREADYRUNNING 35 /* already running */ -#define ISC_R_IGNORE 36 /* ignore */ -#define ISC_R_MASKNONCONTIG 37 /* addr mask not contiguous */ -#define ISC_R_FILENOTFOUND 38 /* file not found */ -#define ISC_R_FILEEXISTS 39 /* file already exists */ -#define ISC_R_NOTCONNECTED 40 /* socket is not connected */ -#define ISC_R_RANGE 41 /* out of range */ -#define ISC_R_NOENTROPY 42 /* out of entropy */ -#define ISC_R_MULTICAST 43 /* invalid use of multicast */ -#define ISC_R_NOTFILE 44 /* not a file */ -#define ISC_R_NOTDIRECTORY 45 /* not a directory */ -#define ISC_R_QUEUEFULL 46 /* queue is full */ -#define ISC_R_FAMILYMISMATCH 47 /* address family mismatch */ -#define ISC_R_FAMILYNOSUPPORT 48 /* AF not supported */ -#define ISC_R_BADHEX 49 /* bad hex encoding */ -#define ISC_R_TOOMANYOPENFILES 50 /* too many open files */ -#define ISC_R_NOTBLOCKING 51 /* not blocking */ -#define ISC_R_UNBALANCEDQUOTES 52 /* unbalanced quotes */ -#define ISC_R_INPROGRESS 53 /* operation in progress */ -#define ISC_R_CONNECTIONRESET 54 /* connection reset */ -#define ISC_R_SOFTQUOTA 55 /* soft quota reached */ -#define ISC_R_BADNUMBER 56 /* not a valid number */ -#define ISC_R_DISABLED 57 /* disabled */ -#define ISC_R_MAXSIZE 58 /* max size */ -#define ISC_R_BADADDRESSFORM 59 /* invalid address format */ - -/* - * Not a result code: the number of results. - */ -#define ISC_R_NRESULTS 60 - -ISC_LANG_BEGINDECLS - -const char * -isc_result_totext(isc_result_t); -/* - * Convert an isc_result_t into a string message describing the result. - */ - -isc_result_t -isc_result_register(unsigned int base, unsigned int nresults, - const char **text, isc_msgcat_t *msgcat, int set); - -ISC_LANG_ENDDECLS - -#endif /* ISC_RESULT_H */ diff -urN src/contrib/ntp/include/isc/sockaddr.h src.ntp/contrib/ntp/include/isc/sockaddr.h --- src/contrib/ntp/include/isc/sockaddr.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/sockaddr.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,202 +0,0 @@ -/* - * Copyright (C) 1998-2002 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: sockaddr.h,v 1.39 2002/04/03 06:38:36 marka Exp $ */ - -#ifndef ISC_SOCKADDR_H -#define ISC_SOCKADDR_H 1 - -#include -#include -#include - -struct isc_sockaddr { - union { - struct sockaddr sa; - struct sockaddr_in sin; - struct sockaddr_in6 sin6; - } type; - unsigned int length; /* XXXRTH beginning? */ - ISC_LINK(struct isc_sockaddr) link; -}; - -typedef ISC_LIST(struct isc_sockaddr) isc_sockaddrlist_t; - -ISC_LANG_BEGINDECLS - -isc_boolean_t -isc_sockaddr_equal(const isc_sockaddr_t *a, const isc_sockaddr_t *b); -/* - * Return ISC_TRUE iff the socket addresses 'a' and 'b' are equal. - */ - -isc_boolean_t -isc_sockaddr_eqaddr(const isc_sockaddr_t *a, const isc_sockaddr_t *b); -/* - * Return ISC_TRUE iff the address parts of the socket addresses - * 'a' and 'b' are equal, ignoring the ports. - */ - -isc_boolean_t -isc_sockaddr_eqaddrprefix(const isc_sockaddr_t *a, const isc_sockaddr_t *b, - unsigned int prefixlen); -/* - * Return ISC_TRUE iff the most significant 'prefixlen' bits of the - * socket addresses 'a' and 'b' are equal, ignoring the ports. - */ - -unsigned int -isc_sockaddr_hash(const isc_sockaddr_t *sockaddr, isc_boolean_t address_only); -/* - * Return a hash value for the socket address 'sockaddr'. If 'address_only' - * is ISC_TRUE, the hash value will not depend on the port. - * - * IPv6 addresses containing mapped IPv4 addresses generate the same hash - * value as the equivalent IPv4 address. - */ - -void -isc_sockaddr_any(isc_sockaddr_t *sockaddr); -/* - * Return the IPv4 wildcard address. - */ - -void -isc_sockaddr_any6(isc_sockaddr_t *sockaddr); -/* - * Return the IPv6 wildcard address. - */ - -void -isc_sockaddr_anyofpf(isc_sockaddr_t *sockaddr, int family); -/* - * Set '*sockaddr' to the wildcard address of protocol family - * 'family'. - * - * Requires: - * 'family' is AF_INET or AF_INET6. - */ - -void -isc_sockaddr_fromin(isc_sockaddr_t *sockaddr, const struct in_addr *ina, - in_port_t port); -/* - * Construct an isc_sockaddr_t from an IPv4 address and port. - */ - -void -isc_sockaddr_fromin6(isc_sockaddr_t *sockaddr, const struct in6_addr *ina6, - in_port_t port); -/* - * Construct an isc_sockaddr_t from an IPv6 address and port. - */ - -void -isc_sockaddr_v6fromin(isc_sockaddr_t *sockaddr, const struct in_addr *ina, - in_port_t port); -/* - * Construct an IPv6 isc_sockaddr_t representing a mapped IPv4 address. - */ - -void -isc_sockaddr_fromnetaddr(isc_sockaddr_t *sockaddr, const isc_netaddr_t *na, - in_port_t port); -/* - * Construct an isc_sockaddr_t from an isc_netaddr_t and port. - */ - -int -isc_sockaddr_pf(const isc_sockaddr_t *sockaddr); -/* - * Get the protocol family of 'sockaddr'. - * - * Requires: - * - * 'sockaddr' is a valid sockaddr with an address family of AF_INET - * or AF_INET6. - * - * Returns: - * - * The protocol family of 'sockaddr', e.g. PF_INET or PF_INET6. - */ - -void -isc_sockaddr_setport(isc_sockaddr_t *sockaddr, in_port_t port); -/* - * Set the port of 'sockaddr' to 'port'. - */ - -in_port_t -isc_sockaddr_getport(isc_sockaddr_t *sockaddr); -/* - * Get the port stored in 'sockaddr'. - */ - -isc_result_t -isc_sockaddr_totext(const isc_sockaddr_t *sockaddr, isc_buffer_t *target); -/* - * Append a text representation of 'sockaddr' to the buffer 'target'. - * The text will include both the IP address (v4 or v6) and the port. - * The text is null terminated, but the terminating null is not - * part of the buffer's used region. - * - * Returns: - * ISC_R_SUCCESS - * ISC_R_NOSPACE The text or the null termination did not fit. - */ - -void -isc_sockaddr_format(const isc_sockaddr_t *sa, char *array, unsigned int size); -/* - * Format a human-readable representation of the socket address '*sa' - * into the character array 'array', which is of size 'size'. - * The resulting string is guaranteed to be null-terminated. - */ - -isc_boolean_t -isc_sockaddr_ismulticast(isc_sockaddr_t *sa); -/* - * Returns ISC_TRUE if the address is a multicast address. - */ - -isc_boolean_t -isc_sockaddr_isexperimental(isc_sockaddr_t *sa); -/* - * Returns ISC_TRUE if the address is a experimental (CLASS E) address. - */ - -isc_boolean_t -isc_sockaddr_islinklocal(isc_sockaddr_t *sa); -/* - * Returns ISC_TRUE if the address is a link local addresss. - */ - -isc_boolean_t -isc_sockaddr_issitelocal(isc_sockaddr_t *sa); -/* - * Returns ISC_TRUE if the address is a sitelocal address. - */ - -#define ISC_SOCKADDR_FORMATSIZE \ - sizeof("xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:XXX.XXX.XXX.XXX#YYYYY") -/* - * Minimum size of array to pass to isc_sockaddr_format(). - */ - -ISC_LANG_ENDDECLS - -#endif /* ISC_SOCKADDR_H */ diff -urN src/contrib/ntp/include/isc/strerror.h src.ntp/contrib/ntp/include/isc/strerror.h --- src/contrib/ntp/include/isc/strerror.h 2004-07-20 17:01:17.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/strerror.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,42 +0,0 @@ -/* - * Copyright (C) 2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: strerror.h,v 1.3 2001/11/20 01:45:47 gson Exp $ */ - -#ifndef ISC_STRERROR_H -#define ISC_STRERROR_H - -#include - -#include - -ISC_LANG_BEGINDECLS - -#define ISC_STRERRORSIZE 128 - -/* - * Provide a thread safe wrapper to strerrror(). - * - * Requires: - * 'buf' to be non NULL. - */ -void -isc__strerror(int num, char *buf, size_t bufsize); - -ISC_LANG_ENDDECLS - -#endif /* ISC_STRERROR_H */ diff -urN src/contrib/ntp/include/isc/string.h src.ntp/contrib/ntp/include/isc/string.h --- src/contrib/ntp/include/isc/string.h 2004-07-20 17:01:17.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/string.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,56 +0,0 @@ -/* - * Copyright (C) 2000, 2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: string.h,v 1.9 2001/01/09 21:57:37 bwelling Exp $ */ - -#ifndef ISC_STRING_H -#define ISC_STRING_H 1 - -#include - -#include -#include -#include - -ISC_LANG_BEGINDECLS - -isc_uint64_t -isc_string_touint64(char *source, char **endp, int base); -/* - * Convert the string pointed to by 'source' to isc_uint64_t. - * - * On successful conversion 'endp' points to the first character - * after conversion is complete. - * - * 'base': 0 or 2..36 - * - * If base is 0 the base is computed from the string type. - * - * On error 'endp' points to 'source'. - */ - - -char * -isc_string_separate(char **stringp, const char *delim); - -#ifdef ISC_PLATFORM_NEEDSTRSEP -#define strsep isc_string_separate -#endif - -ISC_LANG_ENDDECLS - -#endif /* ISC_STRING_H */ diff -urN src/contrib/ntp/include/isc/types.h src.ntp/contrib/ntp/include/isc/types.h --- src/contrib/ntp/include/isc/types.h 2004-07-20 17:01:17.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/types.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,102 +0,0 @@ -/* - * Copyright (C) 1999-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: types.h,v 1.33 2002/07/19 03:39:44 marka Exp $ */ - -#ifndef ISC_TYPES_H -#define ISC_TYPES_H 1 - -/* - * OS-specific types, from the OS-specific include directories. - */ -#include -#include - -/* - * XXXDCL should isc_boolean_t be moved here, requiring an explicit include - * of when ISC_TRUE/ISC_FALSE/ISC_TF() are desired? - */ -#include -/* - * XXXDCL This is just for ISC_LIST and ISC_LINK, but gets all of the other - * list macros too. - */ -#include - -/*** - *** Core Types. Alphabetized by defined type. - ***/ - -typedef struct isc_bitstring isc_bitstring_t; -typedef struct isc_buffer isc_buffer_t; -typedef ISC_LIST(isc_buffer_t) isc_bufferlist_t; -typedef struct isc_constregion isc_constregion_t; -typedef struct isc_consttextregion isc_consttextregion_t; -typedef struct isc_entropy isc_entropy_t; -typedef struct isc_entropysource isc_entropysource_t; -typedef struct isc_event isc_event_t; -typedef ISC_LIST(isc_event_t) isc_eventlist_t; -typedef unsigned int isc_eventtype_t; -typedef isc_uint32_t isc_fsaccess_t; -typedef struct isc_interface isc_interface_t; -typedef struct isc_interfaceiter isc_interfaceiter_t; -typedef struct isc_interval isc_interval_t; -typedef struct isc_lex isc_lex_t; -typedef struct isc_log isc_log_t; -typedef struct isc_logcategory isc_logcategory_t; -typedef struct isc_logconfig isc_logconfig_t; -typedef struct isc_logmodule isc_logmodule_t; -typedef struct isc_mem isc_mem_t; -typedef struct isc_mempool isc_mempool_t; -typedef struct isc_msgcat isc_msgcat_t; -typedef struct isc_ondestroy isc_ondestroy_t; -typedef struct isc_netaddr isc_netaddr_t; -typedef struct isc_quota isc_quota_t; -typedef struct isc_random isc_random_t; -typedef struct isc_ratelimiter isc_ratelimiter_t; -typedef struct isc_region isc_region_t; -typedef isc_uint64_t isc_resourcevalue_t; -typedef unsigned int isc_result_t; -typedef struct isc_rwlock isc_rwlock_t; -typedef struct isc_sockaddr isc_sockaddr_t; -typedef struct isc_socket isc_socket_t; -typedef struct isc_socketevent isc_socketevent_t; -typedef struct isc_socketmgr isc_socketmgr_t; -typedef struct isc_symtab isc_symtab_t; -typedef struct isc_task isc_task_t; -typedef ISC_LIST(isc_task_t) isc_tasklist_t; -typedef struct isc_taskmgr isc_taskmgr_t; -typedef struct isc_textregion isc_textregion_t; -typedef struct isc_time isc_time_t; -typedef struct isc_timer isc_timer_t; -typedef struct isc_timermgr isc_timermgr_t; - -typedef void (*isc_taskaction_t)(isc_task_t *, isc_event_t *); - -typedef enum { - isc_resource_coresize = 1, - isc_resource_cputime, - isc_resource_datasize, - isc_resource_filesize, - isc_resource_lockedmemory, - isc_resource_openfiles, - isc_resource_processes, - isc_resource_residentsize, - isc_resource_stacksize -} isc_resource_t; - -#endif /* ISC_TYPES_H */ diff -urN src/contrib/ntp/include/isc/util.h src.ntp/contrib/ntp/include/isc/util.h --- src/contrib/ntp/include/isc/util.h 2004-07-20 17:01:17.000000000 +0200 +++ src.ntp/contrib/ntp/include/isc/util.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,225 +0,0 @@ -/* - * Copyright (C) 1998-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: util.h,v 1.23 2001/11/30 01:59:38 gson Exp $ */ - -#ifndef ISC_UTIL_H -#define ISC_UTIL_H 1 - -/* - * NOTE: - * - * This file is not to be included from any (or other) library - * files. - * - * Including this file puts several macros in your name space that are - * not protected (as all the other ISC functions/macros do) by prepending - * ISC_ or isc_ to the name. - */ - -/*** - *** General Macros. - ***/ - -/* - * Use this to hide unused function arguments. - * - * int - * foo(char *bar) - * { - * UNUSED(bar); - * } - */ -#define UNUSED(x) (void)(x) - -#define ISC_MAX(a, b) ((a) > (b) ? (a) : (b)) -#define ISC_MIN(a, b) ((a) < (b) ? (a) : (b)) - -/* - * Use this to remove the const qualifier of a variable to assign it to - * a non-const variable or pass it as a non-const function argument ... - * but only when you are sure it won't then be changed! - * This is necessary to sometimes shut up some compilers - * (as with gcc -Wcast-qual) when there is just no other good way to avoid the - * situation. - */ -#define DE_CONST(konst, var) \ - do { \ - union { const void *k; void *v; } _u; \ - _u.k = konst; \ - var = _u.v; \ - } while (0) - -/* - * Use this in translation units that would otherwise be empty, to - * suppress compiler warnings. - */ -#define EMPTY_TRANSLATION_UNIT static void isc__empty(void) { isc__empty(); } - -/* - * We use macros instead of calling the routines directly because - * the capital letters make the locking stand out. - * - * We RUNTIME_CHECK for success since in general there's no way - * for us to continue if they fail. - */ - -#ifdef ISC_UTIL_TRACEON -#define ISC_UTIL_TRACE(a) a -#include /* Required for fprintf/stderr when tracing. */ -#include /* Required for isc_msgcat when tracing. */ -#else -#define ISC_UTIL_TRACE(a) -#endif - -#include /* Contractual promise. */ - -#define LOCK(lp) do { \ - ISC_UTIL_TRACE(fprintf(stderr, "%s %p %s %d\n", \ - isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ - ISC_MSG_LOCKING, "LOCKING"), \ - (lp), __FILE__, __LINE__)); \ - RUNTIME_CHECK(isc_mutex_lock((lp)) == ISC_R_SUCCESS); \ - ISC_UTIL_TRACE(fprintf(stderr, "%s %p %s %d\n", \ - isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ - ISC_MSG_LOCKED, "LOCKED"), \ - (lp), __FILE__, __LINE__)); \ - } while (0) -#define UNLOCK(lp) do { \ - RUNTIME_CHECK(isc_mutex_unlock((lp)) == ISC_R_SUCCESS); \ - ISC_UTIL_TRACE(fprintf(stderr, "%s %p %s %d\n", \ - isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ - ISC_MSG_UNLOCKED, "UNLOCKED"), \ - (lp), __FILE__, __LINE__)); \ - } while (0) -#define ISLOCKED(lp) (1) -#define DESTROYLOCK(lp) \ - RUNTIME_CHECK(isc_mutex_destroy((lp)) == ISC_R_SUCCESS) - - -#define BROADCAST(cvp) do { \ - ISC_UTIL_TRACE(fprintf(stderr, "%s %p %s %d\n", \ - isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ - ISC_MSG_BROADCAST, "BROADCAST"),\ - (cvp), __FILE__, __LINE__)); \ - RUNTIME_CHECK(isc_condition_broadcast((cvp)) == ISC_R_SUCCESS); \ - } while (0) -#define SIGNAL(cvp) do { \ - ISC_UTIL_TRACE(fprintf(stderr, "%s %p %s %d\n", \ - isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ - ISC_MSG_SIGNAL, "SIGNAL"), \ - (cvp), __FILE__, __LINE__)); \ - RUNTIME_CHECK(isc_condition_signal((cvp)) == ISC_R_SUCCESS); \ - } while (0) -#define WAIT(cvp, lp) do { \ - ISC_UTIL_TRACE(fprintf(stderr, "%s %p %s %p %s %d\n", \ - isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ - ISC_MSG_UTILWAIT, "WAIT"), \ - (cvp), \ - isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ - ISC_MSG_LOCK, "LOCK"), \ - (lp), __FILE__, __LINE__)); \ - RUNTIME_CHECK(isc_condition_wait((cvp), (lp)) == ISC_R_SUCCESS); \ - ISC_UTIL_TRACE(fprintf(stderr, "%s %p %s %p %s %d\n", \ - isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ - ISC_MSG_WAITED, "WAITED"), \ - (cvp), \ - isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ - ISC_MSG_LOCKED, "LOCKED"), \ - (lp), __FILE__, __LINE__)); \ - } while (0) - -/* - * isc_condition_waituntil can return ISC_R_TIMEDOUT, so we - * don't RUNTIME_CHECK the result. - * - * XXX Also, can't really debug this then... - */ - -#define WAITUNTIL(cvp, lp, tp) \ - isc_condition_waituntil((cvp), (lp), (tp)) - -#define RWLOCK(lp, t) do { \ - ISC_UTIL_TRACE(fprintf(stderr, "%s %p, %d %s %d\n", \ - isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ - ISC_MSG_RWLOCK, "RWLOCK"), \ - (lp), (t), __FILE__, __LINE__)); \ - RUNTIME_CHECK(isc_rwlock_lock((lp), (t)) == ISC_R_SUCCESS); \ - ISC_UTIL_TRACE(fprintf(stderr, "%s %p, %d %s %d\n", \ - isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ - ISC_MSG_RWLOCKED, "RWLOCKED"), \ - (lp), (t), __FILE__, __LINE__)); \ - } while (0) -#define RWUNLOCK(lp, t) do { \ - ISC_UTIL_TRACE(fprintf(stderr, "%s %p, %d %s %d\n", \ - isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ - ISC_MSG_RWUNLOCK, "RWUNLOCK"), \ - (lp), (t), __FILE__, __LINE__)); \ - RUNTIME_CHECK(isc_rwlock_unlock((lp), (t)) == ISC_R_SUCCESS); \ - } while (0) - -#define DESTROYMUTEXBLOCK(bp, n) \ - RUNTIME_CHECK(isc_mutexblock_destroy((bp), (n)) == ISC_R_SUCCESS) - -/* - * List Macros. - */ -#include /* Contractual promise. */ - -#define LIST(type) ISC_LIST(type) -#define INIT_LIST(type) ISC_LIST_INIT(type) -#define LINK(type) ISC_LINK(type) -#define INIT_LINK(elt, link) ISC_LINK_INIT(elt, link) -#define HEAD(list) ISC_LIST_HEAD(list) -#define TAIL(list) ISC_LIST_TAIL(list) -#define EMPTY(list) ISC_LIST_EMPTY(list) -#define PREV(elt, link) ISC_LIST_PREV(elt, link) -#define NEXT(elt, link) ISC_LIST_NEXT(elt, link) -#define APPEND(list, elt, link) ISC_LIST_APPEND(list, elt, link) -#define PREPEND(list, elt, link) ISC_LIST_PREPEND(list, elt, link) -#define UNLINK(list, elt, link) ISC_LIST_UNLINK(list, elt, link) -#define ENQUEUE(list, elt, link) ISC_LIST_APPEND(list, elt, link) -#define DEQUEUE(list, elt, link) ISC_LIST_UNLINK(list, elt, link) -#define INSERTBEFORE(li, b, e, ln) ISC_LIST_INSERTBEFORE(li, b, e, ln) -#define INSERTAFTER(li, a, e, ln) ISC_LIST_INSERTAFTER(li, a, e, ln) -#define APPENDLIST(list1, list2, link) ISC_LIST_APPENDLIST(list1, list2, link) - -/* - * Assertions - */ -#include /* Contractual promise. */ - -#define REQUIRE(e) ISC_REQUIRE(e) -#define ENSURE(e) ISC_ENSURE(e) -#define INSIST(e) ISC_INSIST(e) -#define INVARIANT(e) ISC_INVARIANT(e) - -/* - * Errors - */ -#include /* Contractual promise. */ - -#define UNEXPECTED_ERROR isc_error_unexpected -#define FATAL_ERROR isc_error_fatal -#define RUNTIME_CHECK(cond) ISC_ERROR_RUNTIMECHECK(cond) - -/* - * Time - */ -#define TIME_NOW(tp) RUNTIME_CHECK(isc_time_now((tp)) == ISC_R_SUCCESS) - -#endif /* ISC_UTIL_H */ diff -urN src/contrib/ntp/include/l_stdlib.h src.ntp/contrib/ntp/include/l_stdlib.h --- src/contrib/ntp/include/l_stdlib.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/l_stdlib.h 2009-12-09 08:36:35.000000000 +0100 @@ -14,15 +14,8 @@ # include #endif -#if defined(__STDC__) || defined(HAVE_STDARG_H) -# include -#else -# include -#endif - -#ifdef HAVE_SYS_TYPES_H -# include -#endif +#include +#include /* Needed for speed_t. */ #ifdef HAVE_TERMIOS_H @@ -40,195 +33,195 @@ #ifdef DECL_ADJTIME_0 struct timeval; -extern int adjtime P((struct timeval *, struct timeval *)); +extern int adjtime (struct timeval *, struct timeval *); #endif #ifdef DECL_BCOPY_0 #ifndef bcopy -extern void bcopy P((const char *, char *, int)); +extern void bcopy (const char *, char *, int); #endif #endif #ifdef DECL_BZERO_0 #ifndef bzero -extern void bzero P((char *, int)); +extern void bzero (char *, int); #endif #endif #ifdef DECL_CFSETISPEED_0 struct termios; -extern int cfsetispeed P((struct termios *, speed_t)); -extern int cfsetospeed P((struct termios *, speed_t)); +extern int cfsetispeed (struct termios *, speed_t); +extern int cfsetospeed (struct termios *, speed_t); #endif -extern char * getpass P((const char *)); +extern char * getpass (const char *); #ifdef DECL_HSTRERROR_0 -extern const char * hstrerror P((int)); +extern const char * hstrerror (int); #endif #ifdef DECL_INET_NTOA_0 struct in_addr; -extern char * inet_ntoa P((struct in_addr)); +extern char * inet_ntoa (struct in_addr); #endif #ifdef DECL_IOCTL_0 -extern int ioctl P((int, u_long, char *)); +extern int ioctl (int, u_long, char *); #endif #ifdef DECL_IPC_0 struct sockaddr; -extern int bind P((int, struct sockaddr *, int)); -extern int connect P((int, struct sockaddr *, int)); -extern int recv P((int, char *, int, int)); -extern int recvfrom P((int, char *, int, int, struct sockaddr *, int *)); -extern int send P((int, char *, int, int)); -extern int sendto P((int, char *, int, int, struct sockaddr *, int)); -extern int setsockopt P((int, int, int, char *, int)); -extern int socket P((int, int, int)); +extern int bind (int, struct sockaddr *, int); +extern int connect (int, struct sockaddr *, int); +extern int recv (int, char *, int, int); +extern int recvfrom (int, char *, int, int, struct sockaddr *, int *); +extern int send (int, char *, int, int); +extern int sendto (int, char *, int, int, struct sockaddr *, int); +extern int setsockopt (int, int, int, char *, int); +extern int socket (int, int, int); #endif #ifdef DECL_MEMMOVE_0 -extern void * memmove P((void *, const void *, size_t)); +extern void * memmove (void *, const void *, size_t); #endif #ifdef DECL_MEMSET_0 -extern char * memset P((char *, int, int)); +extern char * memset (char *, int, int); #endif #ifdef DECL_MKSTEMP_0 -extern int mkstemp P((char *)); +extern int mkstemp (char *); #endif #ifdef DECL_MKTEMP_0 -extern char *mktemp P((char *)); +extern char *mktemp (char *); #endif #ifdef DECL_NLIST_0 struct nlist; -extern int nlist P((const char *, struct nlist *)); +extern int nlist (const char *, struct nlist *); #endif #ifdef DECL_PLOCK_0 -extern int plock P((int)); +extern int plock (int); #endif #ifdef DECL_RENAME_0 -extern int rename P((const char *, const char *)); +extern int rename (const char *, const char *); #endif #ifdef DECL_SELECT_0 #ifdef _ntp_select_h -extern int select P((int, fd_set *, fd_set *, fd_set *, struct timeval *)); +extern int select (int, fd_set *, fd_set *, fd_set *, struct timeval *); #endif #endif #ifdef DECL_SETITIMER_0 struct itimerval; -extern int setitimer P((int , struct itimerval *, struct itimerval *)); +extern int setitimer (int , struct itimerval *, struct itimerval *); #endif #ifdef PRIO_PROCESS #ifdef DECL_SETPRIORITY_0 -extern int setpriority P((int, int, int)); +extern int setpriority (int, int, int); #endif #ifdef DECL_SETPRIORITY_1 -extern int setpriority P((int, id_t, int)); +extern int setpriority (int, id_t, int); #endif #endif #ifdef DECL_SIGVEC_0 struct sigvec; -extern int sigvec P((int, struct sigvec *, struct sigvec *)); +extern int sigvec (int, struct sigvec *, struct sigvec *); #endif #ifndef HAVE_SNPRINTF /* PRINTFLIKE3 */ -extern int snprintf P((char *, size_t, const char *, ...)); +extern int snprintf (char *, size_t, const char *, ...); #endif /* HMS: does this need further protection? */ #ifndef HAVE_VSNPRINTF -extern int vsnprintf P((char *, size_t, const char *, va_list)); +extern int vsnprintf (char *, size_t, const char *, va_list); #endif #ifdef DECL_STDIO_0 #if defined(FILE) || defined(BUFSIZ) -extern int _flsbuf P((int, FILE *)); -extern int _filbuf P((FILE *)); -extern int fclose P((FILE *)); -extern int fflush P((FILE *)); -extern int fprintf P((FILE *, const char *, ...)); -extern int fscanf P((FILE *, const char *, ...)); -extern int fputs P((const char *, FILE *)); -extern int fputc P((int, FILE *)); -extern int fread P((char *, int, int, FILE *)); -extern void perror P((const char *)); -extern int printf P((const char *, ...)); -extern int setbuf P((FILE *, char *)); +extern int _flsbuf (int, FILE *); +extern int _filbuf (FILE *); +extern int fclose (FILE *); +extern int fflush (FILE *); +extern int fprintf (FILE *, const char *, ...); +extern int fscanf (FILE *, const char *, ...); +extern int fputs (const char *, FILE *); +extern int fputc (int, FILE *); +extern int fread (char *, int, int, FILE *); +extern void perror (const char *); +extern int printf (const char *, ...); +extern int setbuf (FILE *, char *); # ifdef HAVE_SETLINEBUF -extern int setlinebuf P((FILE *)); +extern int setlinebuf (FILE *); # endif -extern int setvbuf P((FILE *, char *, int, int)); -extern int scanf P((const char *, ...)); -extern int sscanf P((const char *, const char *, ...)); -extern int vfprintf P((FILE *, const char *, ...)); -extern int vsprintf P((char *, const char *, ...)); +extern int setvbuf (FILE *, char *, int, int); +extern int scanf (const char *, ...); +extern int sscanf (const char *, const char *, ...); +extern int vfprintf (FILE *, const char *, ...); +extern int vsprintf (char *, const char *, ...); #endif #endif #ifdef DECL_STIME_0 -extern int stime P((const time_t *)); +extern int stime (const time_t *); #endif #ifdef DECL_STIME_1 -extern int stime P((long *)); +extern int stime (long *); #endif #ifdef DECL_STRERROR_0 -extern char * strerror P((int errnum)); +extern char * strerror (int errnum); #endif #ifdef DECL_STRTOL_0 -extern long strtol P((const char *, char **, int)); +extern long strtol (const char *, char **, int); #endif #ifdef DECL_SYSCALL -extern int syscall P((int, ...)); +extern int syscall (int, ...); #endif #ifdef DECL_SYSLOG_0 -extern void closelog P((void)); +extern void closelog (void); #ifndef LOG_DAEMON -extern void openlog P((const char *, int)); +extern void openlog (const char *, int); #else -extern void openlog P((const char *, int, int)); +extern void openlog (const char *, int, int); #endif -extern int setlogmask P((int)); -extern void syslog P((int, const char *, ...)); +extern int setlogmask (int); +extern void syslog (int, const char *, ...); #endif #ifdef DECL_TIME_0 -extern time_t time P((time_t *)); +extern time_t time (time_t *); #endif #ifdef DECL_TIMEOFDAY_0 #ifdef SYSV_TIMEOFDAY -extern int gettimeofday P((struct timeval *)); -extern int settimeofday P((struct timeval *)); +extern int gettimeofday (struct timeval *); +extern int settimeofday (struct timeval *); #else /* not SYSV_TIMEOFDAY */ struct timezone; -extern int gettimeofday P((struct timeval *, struct timezone *)); -extern int settimeofday P((struct timeval *, void *)); +extern int gettimeofday (struct timeval *, struct timezone *); +extern int settimeofday (struct timeval *, void *); #endif /* not SYSV_TIMEOFDAY */ #endif #ifdef DECL_TOLOWER_0 -extern int tolower P((int)); +extern int tolower (int); #endif #ifdef DECL_TOUPPER_0 -extern int toupper P((int)); +extern int toupper (int); #endif /* @@ -242,265 +235,4 @@ extern int h_errno; #endif -/*******************************************************/ - -#if 0 -/* - * Unprotoyped library functions for SunOS 4.x.x - */ -#ifdef SYS_SUNOS4 -extern void closelog P((void)); -extern void openlog P((char *, int, int)); -extern void syslog P((int, char *, ...)); -extern int setlogmask P((int)); - -extern char * getpass P((char *)); - -extern int setpriority P((int ,int ,int)); - -extern long strtol P((char *, char **, int)); - -#if !defined(NTP_POSIX_SOURCE) -extern int atoi P((char *)); -extern int dup2 P((int, int)); -extern int execve P((char *, char **,char **)); -extern int fork P((void)); -extern int getdtablesize P((void)); -extern int qsort (void *, int , int, - int P((*compar)(void *, void *))); -extern int setpgrp P((int, int)); -extern void bcopy P((const char *, char *, int)); -#endif - -#ifndef bzero /* XXX macro prototyping clash */ -extern void bzero P((char *, int)); -extern int bcmp P((char *, char *, int)); -extern void bcopy P((const char *, char *, int)); -#endif -extern char *mktemp P((char *)); - -extern int tolower P((int)); - -extern int isatty P((int)); - -extern unsigned sleep P((unsigned )); -extern unsigned int alarm P((unsigned int)); -extern int pause P((void)); - -extern int getpid P((void)); -extern int getppid P((void)); - -extern int close P((int)); -extern int ioctl P((int, int, char *)); -extern int rename P((char *, char *)); -#if 0 -extern int read P((int, void *, size_t)); -extern int write P((int, const void *, size_t)); -#endif -extern int unlink P((const char *)); -extern int link P((const char *, const char *)); - -#ifdef FILE -extern int fclose P((FILE *)); -extern int fflush P((FILE *)); -extern int fprintf P((FILE *, char *, ...)); -extern int fscanf P((FILE *, char *, ...)); -extern int fputs P((char *, FILE *)); -extern int fputc P((char, FILE *)); -extern int fread P((char *, int, int, FILE *)); -extern int printf P((char *, ...)); -extern int setbuf P((FILE *, char *)); -extern int setvbuf P((FILE *, char *, int, int)); -extern int scanf P((char *, ...)); -extern int sscanf P((char *, char *, ...)); -extern int vsprintf P((char *, char *, ...)); -extern int _flsbuf P((int, FILE *)); -extern int _filbuf P((FILE *)); -extern void perror P((char *)); -#ifdef HAVE_SETLINEBUF -extern int setlinebuf P((FILE *)); -#endif -#endif - -#ifdef _ntp_string_h -#ifdef NTP_POSIX_SOURCE /* these are builtins */ -#ifndef NTP_NEED_BOPS /* but may be emulated by bops */ -extern char *memcpy P(()); -extern char *memset P(()); -extern int memcmp P(()); -#endif -#endif -#endif - -#ifdef _sys_socket_h -extern int bind P((int, struct sockaddr *, int)); -extern int connect P((int, struct sockaddr *, int)); -extern int sendto P((int, char *, int, int, struct sockaddr *, int)); -extern int setsockopt P((int, int, int, char *, int)); -extern int socket P((int, int, int)); -extern int recvfrom P((int, char *, int, int, struct sockaddr *, int *)); -#endif /* _sys_socket_h */ - -#ifdef _ntp_select_h -extern int select P((int, fd_set *, fd_set *, fd_set *, struct timeval *)); -#endif - -#ifdef _sys_time_h -extern int adjtime P((struct timeval *, struct timeval *)); -extern int setitimer P((int , struct itimerval *, struct itimerval *)); -#ifdef SYSV_TIMEOFDAY -extern int gettimeofday P((struct timeval *)); -extern int settimeofday P((struct timeval *)); -#else /* ! SYSV_TIMEOFDAY */ -extern int gettimeofday P((struct timeval *, struct timezone *)); -extern int settimeofday P((struct timeval *, struct timezone *)); -#endif /* SYSV_TIMEOFDAY */ -#endif /* _sys_time_h */ - -#ifdef __time_h -extern time_t time P((time_t *)); -#endif - -#ifdef __setjmp_h -extern int setjmp P((jmp_buf)); -extern void longjmp P((jmp_buf, int)); -#endif - -#ifdef _sys_resource_h -extern int getrusage P((int, struct rusage *)); -#endif - -#ifdef _nlist_h -extern int nlist P((char *, struct nlist *)); -#endif - -#endif /* SYS_SUNOS4 */ - -/* - * Unprototyped library functions for DEC OSF/1 - */ -#ifdef SYS_DECOSF1 -#ifndef _MACHINE_ENDIAN_H_ -#define _MACHINE_ENDIAN_H_ -extern u_short htons P((u_short)); -extern u_short ntohs P((u_short)); -extern u_int32 htonl P((u_int32)); -extern u_int32 ntohl P((u_int32)); -#endif /* _MACHINE_ENDIAN_H_ */ - -/* -extern char * getpass P((char *)); -*/ -extern char * mktemp P((char *)); -#ifndef SYS_IX86OSF1 -extern int ioctl P((int, u_long, char *)); -extern void bzero P((char *, int)); -#endif - -#ifdef SOCK_DGRAM -extern int bind P((int, const struct sockaddr *, int)); -extern int connect P((int, const struct sockaddr *, int)); -extern int socket P((int, int, int)); -extern int sendto P((int, const void *, int, int, const struct sockaddr *, int)); -extern int setsockopt P((int, int, int, const void *, int)); -extern int recvfrom P((int, void *, int, int, struct sockaddr *, int *)); -#endif /* SOCK_STREAM */ - -#ifdef _ntp_select_h -extern int select P((int, fd_set *, fd_set *, fd_set *, struct timeval *)); -#endif - -#endif /* DECOSF1 */ - -/* - * Unprototyped library functions for Ultrix - */ -#ifdef SYS_ULTRIX -extern int close P((int)); -extern char * getpass P((char *)); -extern int getpid P((void)); -extern int ioctl P((int, int, char *)); -extern char *mktemp P((char *)); -extern int unlink P((const char *)); -extern int link P((const char *, const char *)); - -extern void closelog P((void)); -extern void syslog P((int, char *, ...)); -#ifndef LOG_DAEMON -extern void openlog P((char *, int)); -#else -extern void openlog P((char *, int, int)); -#endif - -extern int setpriority P((int ,int ,int )); - -#ifdef SOCK_DGRAM -extern int bind P((int, struct sockaddr *, int)); -extern int connect P((int, struct sockaddr *, int)); -extern int socket P((int, int, int)); -extern int sendto P((int, char *, int, int, struct sockaddr *, int)); -extern int setsockopt P((int, int, int, char *, int)); -extern int recvfrom P((int, char *, int, int, struct sockaddr *, int *)); -#endif /* SOCK_STREAM */ - -#ifdef _TIME_H_ -extern int gettimeofday P((struct timeval *, struct timezone *)); -extern int settimeofday P((struct timeval *, struct timezone *)); -extern int adjtime P((struct timeval *, struct timeval *)); -extern int select P((int, fd_set *, fd_set *, fd_set *, struct timeval *)); -extern int setitimer P((int , struct itimerval *, struct itimerval *)); -#endif /* _TIME_H_ */ - -#ifdef N_UNDF -extern int nlist P((char *, struct nlist *)); -#endif - -#ifndef bzero /* XXX macro prototyping clash */ -extern void bzero P((char *, int)); -extern int bcmp P((char *, char *, int)); -extern void bcopy P((const char *, char *, int)); -#endif - -#ifndef NTP_POSIX_SOURCE -extern int atoi P((char *)); -extern void bzero P((char *, int)); -extern int bcmp P((char *, char *, int)); -extern void bcopy P((const char *, char *, int)); -extern int execve P((char *, char **,char **)); -extern int fork P((void)); -extern int getdtablesize P((void)); -extern int ran P((void)); -#ifdef _TIME_H_ -extern int gettimeofday P((struct timeval *, struct timezone *)); -extern int settimeofday P((struct timeval *, struct timezone *)); -#endif -#endif - -#ifdef _RESOURCE_H_ -extern int getrusage P((int, struct rusage *)); -#endif - -#endif /* SYS_ULTRIX */ - -#if defined(__convex__) -extern char * getpass P((char *)); -#endif - -#ifdef SYS_IRIX4 -extern char * getpass P((char *)); -#endif /* IRIX4 */ - -#ifdef SYS_VAX -extern char * getpass P((char *)); -#endif /* VAX */ - -#ifdef SYS_DOMAINOS -extern char * getpass P((char *)); -#endif /* SYS_DOMAINOS */ - -#ifdef SYS_BSD -#define IN_CLASSD(i) (((long)(i) & 0xf0000000) == 0xe0000000) -#endif - -#endif /* 0 */ #endif /* l_stdlib_h */ diff -urN src/contrib/ntp/include/lib_strbuf.h src.ntp/contrib/ntp/include/lib_strbuf.h --- src/contrib/ntp/include/lib_strbuf.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/include/lib_strbuf.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,28 @@ +/* + * lib_strbuf.h - definitions for routines which use the common string buffers + */ + +#include + +/* + * Sizes of things + */ +#define LIB_NUMBUFS 200 +#define LIB_BUFLENGTH 80 + +/* + * Macro to get a pointer to the next buffer + */ +#define LIB_GETBUF(buf) \ + do { \ + if (!lib_inited) \ + init_lib(); \ + buf = &lib_stringbuf[lib_nextbuf][0]; \ + if (++lib_nextbuf >= LIB_NUMBUFS) \ + lib_nextbuf = 0; \ + memset(buf, 0, LIB_BUFLENGTH); \ + } while (0) + +extern char lib_stringbuf[LIB_NUMBUFS][LIB_BUFLENGTH]; +extern int lib_nextbuf; +extern int lib_inited; diff -urN src/contrib/ntp/include/mbg_gps166.h src.ntp/contrib/ntp/include/mbg_gps166.h --- src/contrib/ntp/include/mbg_gps166.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/mbg_gps166.h 2010-02-09 11:01:24.000000000 +0100 @@ -391,7 +391,7 @@ l_fp A0; /* ± Clock Correction Coefficient 0 [sec] */ l_fp A1; /* ± Clock Correction Coefficient 1 [sec/sec] */ - ushort WNlsf; /* week number of nearest leap second */ + u_short WNlsf; /* week number of nearest leap second */ short DNt; /* the day number at the end of which LS is inserted */ char delta_tls; /* */ char delta_tlsf; /* */ @@ -524,31 +524,31 @@ } IONO; -void mbg_tm_str P((char **, TM *, int)); -void mbg_tgps_str P((char **, T_GPS *, int)); -void get_mbg_header P((unsigned char **, GPS_MSG_HDR *)); -void put_mbg_header P((unsigned char **, GPS_MSG_HDR *)); -void get_mbg_sw_rev P((unsigned char **, SW_REV *)); -void get_mbg_ascii_msg P((unsigned char **, ASCII_MSG *)); -void get_mbg_svno P((unsigned char **, SVNO *)); -void get_mbg_health P((unsigned char **, HEALTH *)); -void get_mbg_cfg P((unsigned char **, CFG *)); -void get_mbg_tgps P((unsigned char **, T_GPS *)); -void get_mbg_tm P((unsigned char **, TM *)); -void get_mbg_ttm P((unsigned char **, TTM *)); -void get_mbg_synth P((unsigned char **, SYNTH *)); -void get_mbg_tzdl P((unsigned char **, TZDL *)); -void get_mbg_antinfo P((unsigned char **, ANT_INFO *)); -void get_mbg_cfgh P((unsigned char **, CFGH *)); -void get_mbg_utc P((unsigned char **, UTC *)); -void get_mbg_lla P((unsigned char **, LLA)); -void get_mbg_xyz P((unsigned char **, XYZ)); -void get_mbg_portparam P((unsigned char **, PORT_PARM *)); -void get_mbg_eph P((unsigned char **, EPH *)); -void get_mbg_alm P((unsigned char **, ALM *)); -void get_mbg_iono P((unsigned char **, IONO *)); +void mbg_tm_str (char **, TM *, int); +void mbg_tgps_str (char **, T_GPS *, int); +void get_mbg_header (unsigned char **, GPS_MSG_HDR *); +void put_mbg_header (unsigned char **, GPS_MSG_HDR *); +void get_mbg_sw_rev (unsigned char **, SW_REV *); +void get_mbg_ascii_msg (unsigned char **, ASCII_MSG *); +void get_mbg_svno (unsigned char **, SVNO *); +void get_mbg_health (unsigned char **, HEALTH *); +void get_mbg_cfg (unsigned char **, CFG *); +void get_mbg_tgps (unsigned char **, T_GPS *); +void get_mbg_tm (unsigned char **, TM *); +void get_mbg_ttm (unsigned char **, TTM *); +void get_mbg_synth (unsigned char **, SYNTH *); +void get_mbg_tzdl (unsigned char **, TZDL *); +void get_mbg_antinfo (unsigned char **, ANT_INFO *); +void get_mbg_cfgh (unsigned char **, CFGH *); +void get_mbg_utc (unsigned char **, UTC *); +void get_mbg_lla (unsigned char **, LLA); +void get_mbg_xyz (unsigned char **, XYZ); +void get_mbg_portparam (unsigned char **, PORT_PARM *); +void get_mbg_eph (unsigned char **, EPH *); +void get_mbg_alm (unsigned char **, ALM *); +void get_mbg_iono (unsigned char **, IONO *); -unsigned long mbg_csum P((unsigned char *, unsigned int)); +unsigned long mbg_csum (unsigned char *, unsigned int); #endif /* diff -urN src/contrib/ntp/include/ntp.h src.ntp/contrib/ntp/include/ntp.h --- src/contrib/ntp/include/ntp.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/ntp.h 2010-04-18 10:05:39.000000000 +0200 @@ -4,15 +4,19 @@ #ifndef NTP_H #define NTP_H -#include "ntp_types.h" +#include #include + +#include +#include +#include #ifdef OPENSSL -#include "ntp_crypto.h" +#include #endif /* OPENSSL */ #include +#include #include -#include /* * Calendar arithmetic - contributed by G. Healton @@ -103,14 +107,13 @@ /* * Poll interval parameters */ -#define NTP_UNREACH 24 /* poll unreach threshold */ -#define NTP_MINPOLL 4 /* log2 min poll interval (16 s) */ +#define NTP_UNREACH 10 /* poll unreach threshold */ +#define NTP_MINPOLL 3 /* log2 min poll interval (8 s) */ #define NTP_MINDPOLL 6 /* log2 default min poll (64 s) */ #define NTP_MAXDPOLL 10 /* log2 default max poll (~17 m) */ #define NTP_MAXPOLL 17 /* log2 max poll interval (~36 h) */ -#define NTP_BURST 8 /* packets in burst */ -#define BURST_DELAY 2 /* interburst delay (s) */ -#define RESP_DELAY 1 /* crypto response delay (s) */ +#define NTP_RETRY 3 /* max packet retries */ +#define NTP_MINPKT 1 /* log2 min interburst interval (2 s) */ /* * Clock filter algorithm tuning parameters @@ -125,20 +128,20 @@ #define NTP_MINCLOCK 3 /* min survivors */ #define NTP_MAXCLOCK 10 /* max candidates */ #define NTP_MAXASSOC 50 /* max associations */ -#define MINDISPERSE .005 /* min dispersion increment */ -#define MAXDISTANCE 1. /* max root distance (select threshold) */ +#define MINDISPERSE .001 /* min distance */ +#define MAXDISTANCE 1.5 /* max root distance (select threshold) */ #define CLOCK_SGATE 3. /* popcorn spike gate */ #define HUFFPUFF 900 /* huff-n'-puff sample interval (s) */ #define MAXHOP 2 /* anti-clockhop threshold */ #define MAX_TTL 8 /* max ttl mapping vector size */ #define BEACON 7200 /* manycast beacon interval */ -#define NTP_MAXEXTEN 1024 /* max extension field size */ +#define NTP_MAXEXTEN 2048 /* max extension field size */ /* * Miscellaneous stuff */ #define NTP_MAXKEY 65535 /* max authentication key number */ - +#define KEY_TYPE_MD5 NID_md5 /* MD5 digest NID */ /* * Limits of things */ @@ -153,7 +156,7 @@ * dispersion component (frequency error plus precision). The frequency * error component is computed as CLOCK_PHI times the difference between * the epoch of the time measurement and the reference time. The - * precision componen is computed as the square root of the mean of the + * precision component is computed as the square root of the mean of the * squares of a zero-mean, uniform distribution of unit maximum * amplitude. Whether this makes statistical sense may be arguable. */ @@ -167,34 +170,34 @@ #define EVENT_TIMEOUT 0 /* one second, that is */ + /* * The interface structure is used to hold the addresses and socket * numbers of each of the interfaces we are using. */ struct interface { - SOCKET fd; /* socket this is opened on */ - SOCKET bfd; /* socket for receiving broadcasts */ - struct sockaddr_storage sin; /* interface address */ - struct sockaddr_storage bcast; /* broadcast address */ - struct sockaddr_storage mask; /* interface mask */ - char name[32]; /* name of interface */ - short family; /* Address family */ - int flags; /* interface flags */ - int last_ttl; /* last TTL specified */ - u_int32 addr_refid; /* IPv4 addr or IPv6 hash */ - int num_mcast; /* No. of IP addresses in multicast socket */ - u_long starttime; /* current_time as of creation of interface structure */ - volatile long received; /* number of incoming packets */ - long sent; /* number of outgoing packets */ - long notsent; /* number of send failures */ - u_int scopeid; /* Scope used for Multicasting */ - u_int ifindex; /* interface index */ - u_int ifnum; /* sequential interface instance count */ - u_char phase; /* phase in update cycle */ - isc_boolean_t ignore_packets; /* Specify whether the packet should be ignored */ - ISC_LIST(struct peer) peers; /* list of peers for the interface */ - u_int peercnt; /* number of peers referencinf this interface - informational only */ - ISC_LINK(struct interface) link; /* interface list */ + struct interface *link; /* interface list link */ + SOCKET fd; /* socket this is opened on */ + SOCKET bfd; /* socket for receiving broadcasts */ + sockaddr_u sin; /* interface address */ + sockaddr_u bcast; /* broadcast address */ + sockaddr_u mask; /* interface mask */ + char name[32]; /* name of interface */ + u_short family; /* Address family */ + u_short phase; /* phase in update cycle */ + int flags; /* interface flags */ + int last_ttl; /* last TTL specified */ + u_int32 addr_refid; /* IPv4 addr or IPv6 hash */ + int num_mcast; /* No. of IP addresses in multicast socket */ + u_long starttime; /* current_time as of creation of interface structure */ + volatile long received; /* number of incoming packets */ + long sent; /* number of outgoing packets */ + long notsent; /* number of send failures */ + u_int scopeid; /* Scope used for Multicasting */ + u_int ifnum; /* sequential interface instance count */ + isc_boolean_t ignore_packets; /* listen-read-drop this? */ + struct peer *peers; /* list of peers for the interface */ + u_int peercnt; /* peers referencing this interface */ }; /* @@ -207,8 +210,9 @@ #define INT_MULTICAST 0x010 /* can multicast out this interface */ #define INT_BCASTOPEN 0x020 /* broadcast socket is open */ #define INT_MCASTOPEN 0x040 /* multicasting enabled */ -#define INT_WILDCARD 0x080 /* wildcard interface - usually skipped */ -#define INT_MCASTIF 0x100 /* bound directly to MCAST address */ +#define INT_WILDCARD 0x080 /* wildcard interface - usually skipped */ +#define INT_MCASTIF 0x100 /* bound directly to MCAST address */ + /* * Define flasher bits (tests 1 through 11 in packet procedure) * These reveal the state at the last grumble from the peer and are @@ -221,11 +225,11 @@ #define TEST2 0x0002 /* bogus packet */ #define TEST3 0x0004 /* protocol unsynchronized */ #define TEST4 0x0008 /* access denied */ -#define TEST5 0x0010 /* authentication error */ +#define TEST5 0x0010 /* bad authentication */ #define TEST6 0x0020 /* bad synch or stratum */ -#define TEST7 0x0040 /* bad header data */ -#define TEST8 0x0080 /* autokey error */ -#define TEST9 0x0100 /* crypto error */ +#define TEST7 0x0040 /* bad header */ +#define TEST8 0x0080 /* bad autokey */ +#define TEST9 0x0100 /* bad crypto */ #define PKT_TEST_MASK (TEST1 | TEST2 | TEST3 | TEST4 | TEST5 |\ TEST6 | TEST7 | TEST8 | TEST9) /* @@ -238,24 +242,16 @@ #define PEER_TEST_MASK (TEST10 | TEST11 | TEST12 | TEST13) /* - * Authentication codes - */ -#define AUTH_NONE 0 /* no authentication */ -#define AUTH_OK 1 /* authentication OK */ -#define AUTH_ERROR 2 /* authentication error */ -#define AUTH_CRYPTO 3 /* crypto-NAK */ - -/* * The peer structure. Holds state information relating to the guys * we are peering with. Most of this stuff is from section 3.2 of the * spec. */ struct peer { - struct peer *next; /* pointer to next association */ + struct peer *next; /* link pointer in peer hash */ struct peer *ass_next; /* link pointer in associd hash */ - struct sockaddr_storage srcadr; /* address of remote host */ - struct interface *dstadr; /* pointer to address on local host */ - ISC_LINK(struct peer) ilink; /* interface link list */ + struct peer *ilink; /* list of peers for interface */ + sockaddr_u srcadr; /* address of remote host */ + struct interface *dstadr; /* local address (interface) */ associd_t associd; /* association ID */ u_char version; /* version number */ u_char hmode; /* local association mode */ @@ -264,7 +260,6 @@ u_char maxpoll; /* max poll interval */ u_int flags; /* association flags */ u_char cast_flags; /* additional flags */ - u_int flash; /* protocol error test tally bits */ u_char last_event; /* last peer error code */ u_char num_events; /* number of error events */ u_char ttl; /* ttl/refclock mode */ @@ -287,8 +282,8 @@ u_char stratum; /* remote stratum */ u_char ppoll; /* remote poll interval */ s_char precision; /* remote clock precision */ - double rootdelay; /* roundtrip delay to primary clock */ - double rootdispersion; /* dispersion to primary clock */ + double rootdelay; /* roundtrip delay to primary source */ + double rootdisp; /* dispersion to primary source */ u_int32 refid; /* remote reference ID */ l_fp reftime; /* update epoch */ @@ -297,22 +292,25 @@ */ keyid_t keyid; /* current key ID */ #ifdef OPENSSL -#define clear_to_zero assoc +#define clear_to_zero opcode + u_int32 opcode; /* last request opcode */ associd_t assoc; /* peer association ID */ u_int32 crypto; /* peer status word */ EVP_PKEY *pkey; /* public key */ const EVP_MD *digest; /* message digest algorithm */ char *subject; /* certificate subject name */ char *issuer; /* certificate issuer name */ + struct cert_info *xinfo; /* issuer certificate */ keyid_t pkeyid; /* previous key ID */ + keyid_t hcookie; /* host cookie */ keyid_t pcookie; /* peer cookie */ - EVP_PKEY *ident_pkey; /* identity key */ - tstamp_t fstamp; /* identity filestamp */ - BIGNUM *iffval; /* IFF/GQ challenge */ - BIGNUM *grpkey; /* GQ group key */ - struct value cookval; /* cookie values */ + const struct pkey_info *ident_pkey; /* identity key */ + BIGNUM *iffval; /* identity challenge (IFF, GQ, MV) */ + const BIGNUM *grpkey; /* identity challenge key (GQ) */ + struct value cookval; /* receive cookie values */ struct value recval; /* receive autokey values */ struct exten *cmmd; /* extension pointer */ + u_long refresh; /* next refresh epoch */ /* * Variables used by authenticated server @@ -321,7 +319,6 @@ int keynumber; /* current key number */ struct value encrypt; /* send encrypt values */ struct value sndval; /* send autokey values */ - struct value tai_leap; /* send leapsecond table */ #else /* OPENSSL */ #define clear_to_zero status #endif /* OPENSSL */ @@ -331,33 +328,51 @@ */ u_char status; /* peer status */ u_char reach; /* reachability register */ + int flash; /* protocol error test tally bits */ u_long epoch; /* reference epoch */ - u_int burst; /* packets remaining in burst */ - u_int filter_nextpt; /* index into filter shift register */ + int burst; /* packets remaining in burst */ + int retry; /* retry counter */ + int flip; /* interleave mode control */ + int filter_nextpt; /* index into filter shift register */ double filter_delay[NTP_SHIFT]; /* delay shift register */ double filter_offset[NTP_SHIFT]; /* offset shift register */ double filter_disp[NTP_SHIFT]; /* dispersion shift register */ u_long filter_epoch[NTP_SHIFT]; /* epoch shift register */ u_char filter_order[NTP_SHIFT]; /* filter sort index */ - l_fp org; /* originate time stamp */ l_fp rec; /* receive time stamp */ l_fp xmt; /* transmit time stamp */ + l_fp dst; /* destination timestamp */ + l_fp aorg; /* origin timestamp */ + l_fp borg; /* alternate origin timestamp */ double offset; /* peer clock offset */ double delay; /* peer roundtrip delay */ double jitter; /* peer jitter (squares) */ double disp; /* peer dispersion */ - double estbdelay; /* clock offset to broadcast server */ + double xleave; /* interleave delay */ + double bias; /* bias for NIC asymmetry */ + + /* + * Variables used to correct for packet length and asymmetry. + */ + double t21; /* outbound packet delay */ + int t21_bytes; /* outbound packet length */ + int t21_last; /* last outbound packet length */ + double r21; /* outbound data rate */ + double t34; /* inbound packet delay */ + int t34_bytes; /* inbound packet length */ + double r34; /* inbound data rate */ /* * End of clear-to-zero area */ u_long update; /* receive epoch */ - u_int unreach; /* unreachable count */ -#define end_clear_to_zero unreach +#define end_clear_to_zero update + int unreach; /* watchdog counter */ + int throttle; /* rate control */ u_long outdate; /* send time last packet */ u_long nextdate; /* send time next packet */ u_long nextaction; /* peer local activity timeout (refclocks) */ - void (*action) P((struct peer *)); /* action timeout function */ + void (*action) (struct peer *); /* action timeout function */ /* * Statistic counters @@ -368,12 +383,12 @@ u_long sent; /* packets sent */ u_long received; /* packets received */ - u_long processed; /* packets processed by the protocol */ - u_long badauth; /* packets cryptosum failed */ - u_long bogusorg; /* packets bogus origin */ - u_long oldpkt; /* packets duplicate packet */ - u_long seldisptoolarge; /* packets dispersion too large */ - u_long selbroken; /* not used */ + u_long processed; /* packets processed */ + u_long badauth; /* bad authentication (TEST5) */ + u_long bogusorg; /* bogus origin (TEST2, TEST3) */ + u_long oldpkt; /* old duplicate (TEST1) */ + u_long seldisptoolarge; /* bad header (TEST6, TEST7) */ + u_long selbroken; /* KoD received */ }; /* @@ -419,20 +434,23 @@ * Values for peer.flags */ #define FLAG_CONFIG 0x0001 /* association was configured */ -#define FLAG_AUTHENABLE 0x0002 /* authentication required */ +#define FLAG_PREEMPT 0x0002 /* preemptable association */ #define FLAG_AUTHENTIC 0x0004 /* last message was authentic */ -#define FLAG_SKEY 0x0008 /* autokey authentication */ -#define FLAG_MCAST 0x0010 /* multicast client mode */ -#define FLAG_REFCLOCK 0x0020 /* this is actually a reference clock */ -#define FLAG_SYSPEER 0x0040 /* this is one of the selected peers */ -#define FLAG_PREFER 0x0080 /* this is the preferred peer */ -#define FLAG_BURST 0x0100 /* burst mode */ -#define FLAG_IBURST 0x0200 /* initial burst mode */ -#define FLAG_NOSELECT 0x0400 /* never select */ -#define FLAG_ASSOC 0x0800 /* autokey request */ -#define FLAG_FIXPOLL 0x1000 /* stick at minpoll */ -#define FLAG_TRUE 0x2000 /* select truechimer */ -#define FLAG_PREEMPT 0x4000 /* preemptable association */ +#define FLAG_REFCLOCK 0x0008 /* this is actually a reference clock */ +#define FLAG_SYSPEER 0x0010 /* system peer */ +#define FLAG_PREFER 0x0020 /* prefer peer */ +#define FLAG_BURST 0x0040 /* burst mode */ +#define FLAG_PPS 0x0080 /* steered by PPS */ +#define FLAG_IBURST 0x0100 /* initial burst mode */ +#define FLAG_NOSELECT 0x0200 /* never select */ +#define FLAG_TRUE 0x0400 /* force truechimer */ +#define FLAG_SKEY 0x0800 /* autokey authentication */ +#define FLAG_XLEAVE 0x1000 /* interleaved protocol */ +#define FLAG_XB 0x2000 /* interleaved broadcast */ +#define FLAG_XBOGUS 0x4000 /* interleaved bogus packet */ +#ifdef OPENSSL +#define FLAG_ASSOC 0x8000 /* autokey request */ +#endif /* OPENSSL */ /* * Definitions for the clear() routine. We use memset() to clear @@ -502,86 +520,6 @@ #define REFCLK_NEOCLOCK4X 44 /* NeoClock4X DCF77 or TDF receiver */ #define REFCLK_MAX 44 /* NeoClock4X DCF77 or TDF receiver */ - /* - * Macro for sockaddr_storage structures operations - */ -#define SOCKCMP(sock1, sock2) \ - (((struct sockaddr_storage *)sock1)->ss_family \ - == ((struct sockaddr_storage *)sock2)->ss_family ? \ - ((struct sockaddr_storage *)sock1)->ss_family == AF_INET ? \ - memcmp(&((struct sockaddr_in *)sock1)->sin_addr, \ - &((struct sockaddr_in *)sock2)->sin_addr, \ - sizeof(struct in_addr)) == 0 : \ - memcmp(&((struct sockaddr_in6 *)sock1)->sin6_addr, \ - &((struct sockaddr_in6 *)sock2)->sin6_addr, \ - sizeof(struct in6_addr)) == 0 : \ - 0) - -#define SOCKNUL(sock1) \ - (((struct sockaddr_storage *)sock1)->ss_family == AF_INET ? \ - (((struct sockaddr_in *)sock1)->sin_addr.s_addr == 0) : \ - (IN6_IS_ADDR_UNSPECIFIED(&((struct sockaddr_in6 *)sock1)->sin6_addr))) - -#define SOCKLEN(sock) \ - (((struct sockaddr_storage *)sock)->ss_family == AF_INET ? \ - (sizeof(struct sockaddr_in)) : (sizeof(struct sockaddr_in6))) - -#define ANYSOCK(sock) \ - memset(((struct sockaddr_storage *)sock), 0, \ - sizeof(struct sockaddr_storage)) - -#define ANY_INTERFACE_CHOOSE(sock) \ - (((struct sockaddr_storage *)sock)->ss_family == AF_INET ? \ - any_interface : any6_interface) - -/* - * We tell reference clocks from real peers by giving the reference - * clocks an address of the form 127.127.t.u, where t is the type and - * u is the unit number. We define some of this here since we will need - * some sanity checks to make sure this address isn't interpretted as - * that of a normal peer. - */ -#define REFCLOCK_ADDR 0x7f7f0000 /* 127.127.0.0 */ -#define REFCLOCK_MASK 0xffff0000 /* 255.255.0.0 */ - -#define ISREFCLOCKADR(srcadr) ((SRCADR(srcadr) & REFCLOCK_MASK) \ - == REFCLOCK_ADDR) - -/* - * Macro for checking for invalid addresses. This is really, really - * gross, but is needed so no one configures a host on net 127 now that - * we're encouraging it the the configuration file. - */ -#define LOOPBACKADR 0x7f000001 -#define LOOPNETMASK 0xff000000 - -#define ISBADADR(srcadr) (((SRCADR(srcadr) & LOOPNETMASK) \ - == (LOOPBACKADR & LOOPNETMASK)) \ - && (SRCADR(srcadr) != LOOPBACKADR)) - -/* - * Utilities for manipulating addresses and port numbers - */ -#define NSRCADR(src) (((struct sockaddr_in *)src)->sin_addr.s_addr) /* address in net byte order */ -#define NSRCPORT(src) (((struct sockaddr_in *)src)->sin_port) /* port in net byte order */ -#define SRCADR(src) (ntohl(NSRCADR((src)))) /* address in host byte order */ -#define SRCPORT(src) (ntohs(NSRCPORT((src)))) /* host port */ - -#define CAST_V4(src) ((struct sockaddr_in *)&(src)) -#define CAST_V6(src) ((struct sockaddr_in6 *)&(src)) -#define GET_INADDR(src) (CAST_V4(src)->sin_addr.s_addr) -#define GET_INADDR6(src) (CAST_V6(src)->sin6_addr) - -#define SET_HOSTMASK(addr, family) \ - do { \ - memset((char *)(addr), 0, sizeof(struct sockaddr_storage)); \ - (addr)->ss_family = (family); \ - if ((family) == AF_INET) \ - GET_INADDR(*(addr)) = 0xffffffff; \ - else \ - memset(&GET_INADDR6(*(addr)), 0xff, \ - sizeof(struct in6_addr)); \ - } while(0) /* * NTP packet format. The mac field is optional. It isn't really @@ -592,30 +530,30 @@ * and must be converted (except the mac, which isn't, really). */ struct pkt { - u_char li_vn_mode; /* leap indicator, version and mode */ + u_char li_vn_mode; /* peer leap indicator */ u_char stratum; /* peer stratum */ u_char ppoll; /* peer poll interval */ s_char precision; /* peer clock precision */ - u_fp rootdelay; /* distance to primary clock */ - u_fp rootdispersion; /* clock dispersion */ - u_int32 refid; /* reference clock ID */ - l_fp reftime; /* time peer clock was last updated */ + u_fp rootdelay; /* roundtrip delay to primary source */ + u_fp rootdisp; /* dispersion to primary source*/ + u_int32 refid; /* reference id */ + l_fp reftime; /* last update time */ l_fp org; /* originate time stamp */ l_fp rec; /* receive time stamp */ l_fp xmt; /* transmit time stamp */ -#define LEN_PKT_NOMAC 12 * sizeof(u_int32) /* min header length */ -#define LEN_PKT_MAC LEN_PKT_NOMAC + sizeof(u_int32) -#define MIN_MAC_LEN 3 * sizeof(u_int32) /* DES */ -#define MAX_MAC_LEN 5 * sizeof(u_int32) /* MD5 */ +#define LEN_PKT_NOMAC (12 * sizeof(u_int32)) /* min header length */ +#define MIN_MAC_LEN (1 * sizeof(u_int32)) /* crypto_NAK */ +#define MAX_MD5_LEN (5 * sizeof(u_int32)) /* MD5 */ +#define MAX_MAC_LEN (6 * sizeof(u_int32)) /* SHA */ /* * The length of the packet less MAC must be a multiple of 64 - * with an RSA modulus and Diffie-Hellman prime of 64 octets + * with an RSA modulus and Diffie-Hellman prime of 256 octets * and maximum host name of 128 octets, the maximum autokey * command is 152 octets and maximum autokey response is 460 * octets. A packet can contain no more than one command and one - * response, so the maximum total extension field length is 672 + * response, so the maximum total extension field length is 864 * octets. But, to handle humungus certificates, the bank must * be broke. */ @@ -661,33 +599,53 @@ * System event codes */ #define EVNT_UNSPEC 0 /* unspecified */ -#define EVNT_SYSRESTART 1 /* system restart */ -#define EVNT_SYSFAULT 2 /* wsystem or hardware fault */ -#define EVNT_SYNCCHG 3 /* new leap or synch change */ -#define EVNT_PEERSTCHG 4 /* new source or stratum */ -#define EVNT_CLOCKRESET 5 /* clock reset */ -#define EVNT_BADDATETIM 6 /* invalid time or date */ -#define EVNT_CLOCKEXCPT 7 /* reference clock exception */ +#define EVNT_NSET 1 /* freq not set */ +#define EVNT_FSET 2 /* freq set */ +#define EVNT_SPIK 3 /* spike detect */ +#define EVNT_FREQ 4 /* freq mode */ +#define EVNT_SYNC 5 /* clock sync */ +#define EVNT_SYSRESTART 6 /* restart */ +#define EVNT_SYSFAULT 7 /* panic stop */ +#define EVNT_NOPEER 8 /* no sys peer */ +#define EVNT_ARMED 9 /* leap armed */ +#define EVNT_DISARMED 10 /* leap disarmed */ +#define EVNT_LEAP 11 /* leap event */ +#define EVNT_CLOCKRESET 12 /* clock step */ +#define EVNT_KERN 13 /* kernel event */ +#define EVNT_TAI 14 /* TAI */ +#define EVNT_LEAPVAL 15 /* stale leapsecond values */ +#define EVNT_CLKHOP 16 /* clockhop */ /* * Peer event codes */ -#define EVNT_PEERIPERR (1 | PEER_EVENT) /* IP error */ -#define EVNT_PEERAUTH (2 | PEER_EVENT) /* authentication failure */ -#define EVNT_UNREACH (3 | PEER_EVENT) /* change to unreachable */ -#define EVNT_REACH (4 | PEER_EVENT) /* change to reachable */ -#define EVNT_PEERCLOCK (5 | PEER_EVENT) /* clock exception */ +#define PEVNT_MOBIL (1 | PEER_EVENT) /* mobilize */ +#define PEVNT_DEMOBIL (2 | PEER_EVENT) /* demobilize */ +#define PEVNT_UNREACH (3 | PEER_EVENT) /* unreachable */ +#define PEVNT_REACH (4 | PEER_EVENT) /* reachable */ +#define PEVNT_RESTART (5 | PEER_EVENT) /* restart */ +#define PEVNT_REPLY (6 | PEER_EVENT) /* no reply */ +#define PEVNT_RATE (7 | PEER_EVENT) /* rate exceeded */ +#define PEVNT_DENY (8 | PEER_EVENT) /* access denied */ +#define PEVNT_ARMED (9 | PEER_EVENT) /* leap armed */ +#define PEVNT_NEWPEER (10 | PEER_EVENT) /* sys peer */ +#define PEVNT_CLOCK (11 | PEER_EVENT) /* clock event */ +#define PEVNT_AUTH (12 | PEER_EVENT) /* bad auth */ +#define PEVNT_POPCORN (13 | PEER_EVENT) /* popcorn */ +#define PEVNT_XLEAVE (14 | PEER_EVENT) /* interleave mode */ +#define PEVNT_XERR (15 | PEER_EVENT) /* interleave error */ +#define PEVNT_TAI (16 | PEER_EVENT) /* TAI */ /* * Clock event codes */ #define CEVNT_NOMINAL 0 /* unspecified */ -#define CEVNT_TIMEOUT 1 /* poll timeout */ -#define CEVNT_BADREPLY 2 /* bad reply format */ -#define CEVNT_FAULT 3 /* hardware or software fault */ -#define CEVNT_PROP 4 /* propagation failure */ -#define CEVNT_BADDATE 5 /* bad date format or value */ -#define CEVNT_BADTIME 6 /* bad time format or value */ +#define CEVNT_TIMEOUT 1 /* no reply */ +#define CEVNT_BADREPLY 2 /* bad format */ +#define CEVNT_FAULT 3 /* fault */ +#define CEVNT_PROP 4 /* bad signal */ +#define CEVNT_BADDATE 5 /* bad date */ +#define CEVNT_BADTIME 6 /* bad time */ #define CEVNT_MAX CEVNT_BADTIME /* @@ -705,12 +663,6 @@ #define NTP_HASH_ADDR(src) sock_hash(src) /* - * How we randomize polls. The poll interval is a power of two. We chose - * a random interval which is this value plus-minus one second. - */ -#define RANDPOLL(x) ((1 << (x)) - 1 + (ntp_random() & 0x3)) - -/* * min, min3 and max. Makes it easier to transliterate the spec without * thinking about it. */ @@ -763,6 +715,8 @@ #define LOOP_HUFFPUFF 9 /* set huff-n'-puff filter length */ #define LOOP_FREQ 10 /* set initial frequency */ #define LOOP_KERN_CLEAR 11 /* reset kernel pll parameters */ +#define LOOP_CODEC 12 /* set audio codec frequency */ +#define LOOP_LEAP 13 /* insert leap after second 23:59 */ /* * Configuration items for the stats printer @@ -770,13 +724,13 @@ #define STATS_FREQ_FILE 1 /* configure drift file */ #define STATS_STATSDIR 2 /* directory prefix for stats files */ #define STATS_PID_FILE 3 /* configure ntpd PID file */ +#define STATS_LEAP_FILE 4 /* configure ntpd leapseconds file */ #define MJD_1900 15020 /* MJD for 1 Jan 1900 */ /* * Default parameters. We use these in the absence of something better. */ -#define DEFBROADDELAY 4e-3 /* default broadcast offset */ #define INADDR_NTP 0xe0000101 /* NTP multicast address 224.0.1.1 */ /* @@ -786,16 +740,17 @@ struct mon_data *hash_next; /* next structure in hash list */ struct mon_data *mru_next; /* next structure in MRU list */ struct mon_data *mru_prev; /* previous structure in MRU list */ - u_long drop_count; /* dropped due RESLIMIT*/ - double avg_interval; /* average interpacket interval */ - u_long lasttime; /* interval since last packet */ - u_long count; /* total packet count */ - struct sockaddr_storage rmtadr; /* address of remote host */ + int flags; /* restrict flags */ + int leak; /* leaky bucket accumulator */ + int count; /* total packet count */ + u_long firsttime; /* first time found */ + u_long lasttime; /* last time found */ + sockaddr_u rmtadr; /* address of remote host */ struct interface *interface; /* interface on which this arrived */ - u_short rmtport; /* remote port last came from */ - u_char mode; /* mode of incoming packet */ - u_char version; /* version of incoming packet */ - u_char cast_flags; /* flags MDF_?CAST */ + u_short rmtport; /* remote port last came from */ + u_char mode; /* packet mode */ + u_char version; /* packet version */ + u_char cast_flags; /* flags MDF_?CAST */ }; /* @@ -818,57 +773,65 @@ /* * Structure used for restrictlist entries */ -struct restrictlist { - struct restrictlist *next; /* link to next entry */ - u_int32 addr; /* Ipv4 host address (host byte order) */ - u_int32 mask; /* Ipv4 mask for address (host byte order) */ - u_long count; /* number of packets matched */ - u_short flags; /* accesslist flags */ - u_short mflags; /* match flags */ -}; - -struct restrictlist6 { - struct restrictlist6 *next; /* link to next entry */ - struct in6_addr addr6; /* Ipv6 host address */ - struct in6_addr mask6; /* Ipv6 mask address */ - u_long count; /* number of packets matched */ - u_short flags; /* accesslist flags */ - u_short mflags; /* match flags */ +typedef struct res_addr4_tag { + u_int32 addr; /* IPv4 addr (host order) */ + u_int32 mask; /* IPv4 mask (host order) */ +} res_addr4; + +typedef struct res_addr6_tag { + struct in6_addr addr; /* IPv6 addr (net order) */ + struct in6_addr mask; /* IPv6 mask (net order) */ +} res_addr6; + +typedef struct restrict_u_tag restrict_u; +struct restrict_u_tag { + restrict_u * link; /* link to next entry */ + u_int32 count; /* number of packets matched */ + u_short flags; /* accesslist flags */ + u_short mflags; /* match flags */ + union { /* variant starting here */ + res_addr4 v4; + res_addr6 v6; + } u; }; +#define V4_SIZEOF_RESTRICT_U (offsetof(restrict_u, u) \ + + sizeof(res_addr4)) +#define V6_SIZEOF_RESTRICT_U (offsetof(restrict_u, u) \ + + sizeof(res_addr6)) /* * Access flags */ -#define RES_IGNORE 0x001 /* ignore packet */ -#define RES_DONTSERVE 0x002 /* access denied */ -#define RES_DONTTRUST 0x004 /* authentication required */ -#define RES_VERSION 0x008 /* version mismatch */ -#define RES_NOPEER 0x010 /* new association denied */ -#define RES_LIMITED 0x020 /* packet rate exceeded */ - +#define RES_IGNORE 0x0001 /* ignore packet */ +#define RES_DONTSERVE 0x0002 /* access denied */ +#define RES_DONTTRUST 0x0004 /* authentication required */ +#define RES_VERSION 0x0008 /* version mismatch */ +#define RES_NOPEER 0x0010 /* new association denied */ +#define RES_LIMITED 0x0020 /* packet rate exceeded */ #define RES_FLAGS (RES_IGNORE | RES_DONTSERVE |\ RES_DONTTRUST | RES_VERSION |\ RES_NOPEER | RES_LIMITED) -#define RES_NOQUERY 0x040 /* mode 6/7 packet denied */ -#define RES_NOMODIFY 0x080 /* mode 6/7 modify denied */ -#define RES_NOTRAP 0x100 /* mode 6/7 set trap denied */ -#define RES_LPTRAP 0x200 /* mode 6/7 low priority trap */ - -#define RES_DEMOBILIZE 0x400 /* send kiss of death packet */ -#define RES_TIMEOUT 0x800 /* timeout this entry */ +#define RES_NOQUERY 0x0040 /* mode 6/7 packet denied */ +#define RES_NOMODIFY 0x0080 /* mode 6/7 modify denied */ +#define RES_NOTRAP 0x0100 /* mode 6/7 set trap denied */ +#define RES_LPTRAP 0x0200 /* mode 6/7 low priority trap */ + +#define RES_KOD 0x0400 /* send kiss of death packet */ +#define RES_MSSNTP 0x0800 /* enable MS-SNTP authentication */ +#define RES_TIMEOUT 0x1000 /* timeout this entry */ #define RES_ALLFLAGS (RES_FLAGS | RES_NOQUERY |\ RES_NOMODIFY | RES_NOTRAP |\ - RES_LPTRAP | RES_DEMOBILIZE |\ - RES_TIMEOUT) + RES_LPTRAP | RES_KOD |\ + RES_MSSNTP | RES_TIMEOUT) /* * Match flags */ -#define RESM_INTERFACE 0x1 /* this is an interface */ -#define RESM_NTPONLY 0x2 /* match ntp port only */ +#define RESM_INTERFACE 0x1000 /* this is an interface */ +#define RESM_NTPONLY 0x2000 /* match ntp port only */ /* * Restriction configuration ops diff -urN src/contrib/ntp/include/ntp_assert.h src.ntp/contrib/ntp/include/ntp_assert.h --- src/contrib/ntp/include/ntp_assert.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/include/ntp_assert.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,60 @@ +/* + * ntp_assert.h - design by contract stuff + * + * example: + * + * int foo(char *a) { + * int result; + * int value; + * + * NTP_REQUIRE(a != NULL); + * ... + * bar(&value); + * NTP_INSIST(value > 2); + * ... + * + * NTP_ENSURE(result != 12); + * return result; + * } + * + * open question: when would we use NTP_INVARIANT()? + */ + +#ifndef NTP_ASSERT_H +#define NTP_ASSERT_H + +# ifdef CALYSTO + +extern void calysto_assume(unsigned char cnd); /* assume this always holds */ +extern void calysto_assert(unsigned char cnd); /* check whether this holds */ +#define NTP_REQUIRE(x) calysto_assert(x) +#define NTP_INSIST(x) calysto_assume(x) /* DLH calysto_assert()? */ +#define NTP_INVARIANT(x) calysto_assume(x) +#define NTP_ENSURE(x) calysto_assert(x) + +# elif defined(__COVERITY__) + +/* + * Coverity has special knowledge that assert(x) terminates the process + * if x is not true. Rather than teach it about our assertion macros, + * just use the one it knows about for Coverity Prevent scans. This + * means our assertion code (and ISC's) escapes Coverity analysis, but + * that seems to be a reasonable trade-off. + */ + +#define NTP_REQUIRE(x) assert(x) +#define NTP_INSIST(x) assert(x) +#define NTP_INVARIANT(x) assert(x) +#define NTP_ENSURE(x) assert(x) + +# else /* neither Coverity nor Calysto */ + +#include "isc/assertions.h" + +#define NTP_REQUIRE(x) ISC_REQUIRE(x) +#define NTP_INSIST(x) ISC_INSIST(x) +#define NTP_INVARIANT(x) ISC_INVARIANT(x) +#define NTP_ENSURE(x) ISC_ENSURE(x) + +# endif /* neither Coverity nor Calysto */ +#endif /* NTP_ASSERT_H */ diff -urN src/contrib/ntp/include/ntp_calendar.h src.ntp/contrib/ntp/include/ntp_calendar.h --- src/contrib/ntp/include/ntp_calendar.h 1999-12-09 14:01:07.000000000 +0100 +++ src.ntp/contrib/ntp/include/ntp_calendar.h 2009-12-09 08:36:35.000000000 +0100 @@ -7,13 +7,13 @@ #include "ntp_types.h" struct calendar { - u_short year; /* year (A.D.) */ + u_short year; /* year (A.D.) */ u_short yearday; /* day of year, 1 = January 1 */ - u_char month; /* month, 1 = January */ + u_char month; /* month, 1 = January */ u_char monthday; /* day of month */ - u_char hour; /* hour of day, midnight = 0 */ - u_char minute; /* minute of hour */ - u_char second; /* second of minute */ + u_char hour; /* hour of day, midnight = 0 */ + u_char minute; /* minute of hour */ + u_char second; /* second of minute */ }; /* @@ -44,7 +44,7 @@ #define DAYSPERYEAR (365) /* days per year */ #define SECSPERDAY (SECSPERMIN*MINSPERHR*HRSPERDAY) -#define SECSPERYEAR (365 * SECSPERDAY) /* regular year */ +#define SECSPERYEAR (365 * SECSPERDAY) /* regular year */ #define SECSPERLEAPYEAR (366 * SECSPERDAY) /* leap year */ #define MAR1900 ((JAN+FEB) * SECSPERDAY) /* no leap year in 1900 */ @@ -56,9 +56,9 @@ * Gross hacks. I have illicit knowlege that there won't be overflows * here, the compiler often can't tell this. */ -#define TIMES60(val) ((((val)<<4) - (val))<<2) /* *(16 - 1) * 4 */ +#define TIMES60(val) ((((val)<<4) - (val))<<2) /* *(16 - 1) * 4 */ #define TIMES24(val) (((val)<<4) + ((val)<<3)) /* *16 + *8 */ -#define TIMES7(val) (((val)<<3) - (val)) /* *8 - *1 */ +#define TIMES7(val) (((val)<<3) - (val)) /* *8 - *1 */ #define TIMESDPERC(val) (((val)<<10) + ((val)<<8) \ + ((val)<<7) + ((val)<<5) \ + ((val)<<4) + ((val)<<2) + (val)) /* *big* hack */ @@ -78,8 +78,8 @@ #define JANFEBLEAP ((JAN+FEBLEAP) * SECSPERDAY) -extern void caljulian P((u_long, struct calendar *)); -extern u_long caltontp P((const struct calendar *)); +extern void caljulian (u_long, struct calendar *); +extern u_long caltontp (const struct calendar *); /* * Additional support stuff for Ed Rheingold's calendrical calculations @@ -87,26 +87,26 @@ /* * Start day of NTP time as days past the imaginary date 12/1/1 BC. - * P((This is the beginning of the Christian Era, or BCE.)) + * (This is the beginning of the Christian Era, or BCE.) */ -#define DAY_NTP_STARTS 693596 +#define DAY_NTP_STARTS 693596 /* * The Gregorian calendar is based on a 400 year cycle. This is the number * of days in each cycle. */ -#define GREGORIAN_CYCLE_DAYS 146097 +#define GREGORIAN_CYCLE_DAYS 146097 /* * Days in a normal 100 year leap year calendar. We lose a leap year day * in years evenly divisible by 100 but not by 400. */ -#define GREGORIAN_NORMAL_CENTURY_DAYS 36524 +#define GREGORIAN_NORMAL_CENTURY_DAYS 36524 /* * Days in a normal 4 year leap year calendar cycle. */ -#define GREGORIAN_NORMAL_LEAP_CYCLE_DAYS 1461 +#define GREGORIAN_NORMAL_LEAP_CYCLE_DAYS 1461 -#define is_leapyear(y) (y%4 == 0 && !(y%100 == 0 && !(y%400 == 0))) +#define is_leapyear(y) (!((y) % 4) && !(!((y) % 100) && (y) % 400)) #endif diff -urN src/contrib/ntp/include/ntp_cmdargs.h src.ntp/contrib/ntp/include/ntp_cmdargs.h --- src/contrib/ntp/include/ntp_cmdargs.h 2001-08-29 16:35:10.000000000 +0200 +++ src.ntp/contrib/ntp/include/ntp_cmdargs.h 2009-12-09 08:36:36.000000000 +0100 @@ -1,4 +1,4 @@ #include "ntp_types.h" -extern void getstartup P((int, char **)); -extern void getCmdOpts P((int, char **)); +extern void getstartup (int, char **); +extern void getCmdOpts (int, char **); diff -urN src/contrib/ntp/include/ntp_config.h src.ntp/contrib/ntp/include/ntp_config.h --- src/contrib/ntp/include/ntp_config.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/ntp_config.h 2010-04-18 10:05:39.000000000 +0200 @@ -1,3 +1,11 @@ +#ifndef NTP_CONFIG_H +#define NTP_CONFIG_H + +#include "ntp_machine.h" +#include "ntp_data_structures.h" +#include "ntpsim.h" + + /* * Configuration file name */ @@ -11,171 +19,227 @@ # endif /* SYS_WINNT */ #endif /* not CONFIG_FILE */ -/* - * Types of entries we understand. - */ -#define CONFIG_UNKNOWN 0 - -/* - * Command keywords - */ -#define CONFIG_PEER 1 -#define CONFIG_SERVER 2 -#define CONFIG_AUTOMAX 3 -#define CONFIG_DRIFTFILE 4 -#define CONFIG_BROADCAST 5 -#define CONFIG_BROADCASTCLIENT 6 -#define CONFIG_AUTHENTICATE 7 -#define CONFIG_KEYS 8 -#define CONFIG_REVOKE 9 -#define CONFIG_CDELAY 10 -#define CONFIG_RESTRICT 11 -#define CONFIG_BDELAY 12 -#define CONFIG_TRUSTEDKEY 13 -#define CONFIG_REQUESTKEY 14 -#define CONFIG_CONTROLKEY 15 -#define CONFIG_TRAP 16 -#define CONFIG_FUDGE 17 -#define CONFIG_TINKER 18 -#define CONFIG_STATSDIR 19 -#define CONFIG_FILEGEN 20 -#define CONFIG_STATISTICS 21 -#define CONFIG_PIDFILE 22 -#define CONFIG_SETVAR 23 -#define CONFIG_DISCARD 24 -#define CONFIG_ADJ 25 -#define CONFIG_MULTICASTCLIENT 26 -#define CONFIG_ENABLE 27 -#define CONFIG_DISABLE 28 -#define CONFIG_PHONE 29 -#define CONFIG_LOGFILE 30 -#define CONFIG_LOGCONFIG 31 -#define CONFIG_MANYCASTCLIENT 32 -#define CONFIG_MANYCASTSERVER 33 -#define CONFIG_TOS 34 -#define CONFIG_TTL 35 -#define CONFIG_INCLUDEFILE 36 -#define CONFIG_KEYSDIR 37 -#define CONFIG_END 38 -#ifdef OPENSSL -#define CONFIG_CRYPTO 39 -#endif /* OPENSSL */ - -/* - * "peer", "server", "broadcast" modifier keywords - */ -#define CONF_MOD_VERSION 1 -#define CONF_MOD_KEY 2 -#define CONF_MOD_MINPOLL 3 -#define CONF_MOD_MAXPOLL 4 -#define CONF_MOD_PREFER 5 -#define CONF_MOD_BURST 6 -#define CONF_MOD_IBURST 7 -#define CONF_MOD_SKEY 8 -#define CONF_MOD_TTL 9 -#define CONF_MOD_MODE 10 -#define CONF_MOD_NOSELECT 11 -#define CONF_MOD_TRUE 12 -#define CONF_MOD_PREEMPT 13 -#define CONF_MOD_DYNAMIC 14 - -/* - * "restrict" modifier keywords - */ -#define CONF_RES_MASK 1 -#define CONF_RES_IGNORE 2 -#define CONF_RES_NOSERVE 3 -#define CONF_RES_NOTRUST 4 -#define CONF_RES_NOQUERY 5 -#define CONF_RES_NOMODIFY 6 -#define CONF_RES_NOPEER 7 -#define CONF_RES_NOTRAP 8 -#define CONF_RES_LPTRAP 9 -#define CONF_RES_NTPPORT 10 -#define CONF_RES_LIMITED 11 -#define CONF_RES_VERSION 12 -#define CONF_RES_DEMOBILIZE 13 - -/* - * "trap" modifier keywords - */ -#define CONF_TRAP_PORT 1 -#define CONF_TRAP_INTERFACE 2 - -/* - * "fudge" modifier keywords - */ -#define CONF_FDG_TIME1 1 -#define CONF_FDG_TIME2 2 -#define CONF_FDG_STRATUM 3 -#define CONF_FDG_REFID 4 -#define CONF_FDG_FLAG1 5 -#define CONF_FDG_FLAG2 6 -#define CONF_FDG_FLAG3 7 -#define CONF_FDG_FLAG4 8 - -/* - * "filegen" modifier keywords - */ -#define CONF_FGEN_FILE 1 -#define CONF_FGEN_TYPE 2 -#define CONF_FGEN_FLAG_LINK 3 -#define CONF_FGEN_FLAG_NOLINK 4 -#define CONF_FGEN_FLAG_ENABLE 5 -#define CONF_FGEN_FLAG_DISABLE 6 - -/* - * "discard" modifier keywords - */ -#define CONF_DISCARD_AVERAGE 1 -#define CONF_DISCARD_MINIMUM 2 -#define CONF_DISCARD_MONITOR 3 - -/* - * "tinker" modifier keywords - */ -#define CONF_CLOCK_MAX 1 -#define CONF_CLOCK_PANIC 2 -#define CONF_CLOCK_PHI 3 -#define CONF_CLOCK_MINSTEP 4 -#define CONF_CLOCK_ALLAN 5 -#define CONF_CLOCK_HUFFPUFF 6 -#define CONF_CLOCK_FREQ 7 +#ifdef HAVE_IPTOS_SUPPORT +/* + * "qos" modified keywords + */ +#define CONF_QOS_LOWDELAY 1 +#define CONF_QOS_THROUGHPUT 2 +#define CONF_QOS_RELIABILITY 3 +#define CONF_QOS_MINCOST 4 + +#ifdef IPTOS_PREC_INTERNETCONTROL +#define CONF_QOS_CS0 5 +#define CONF_QOS_CS1 6 +#define CONF_QOS_CS2 7 +#define CONF_QOS_CS3 8 +#define CONF_QOS_CS4 9 +#define CONF_QOS_CS5 10 +#define CONF_QOS_CS6 11 +#define CONF_QOS_CS7 12 +#endif /* IPTOS_PREC_INTERNETCONTROL */ + +#endif /* HAVE_IPTOS_SUPPORT */ + + +/* + * We keep config trees around for possible saveconfig use. When + * built with configure --disable-saveconfig, and when built with + * debugging enabled, include the free_config_*() routines. In the + * DEBUG case, they are used in an atexit() cleanup routine to make + * postmortem leak check reports more interesting. + */ +#if !defined(FREE_CFG_T) && (!defined(SAVECONFIG) || defined(DEBUG)) +#define FREE_CFG_T +#endif + +/* Limits */ +#define MAXLINE 1024 + +/* Configuration sources */ + +#define CONF_SOURCE_FILE 0 +#define CONF_SOURCE_NTPQ 1 + + +/* Structure for storing an attribute-value pair */ +struct attr_val { + int attr; + union val { + double d; + int i; + u_int u; + char * s; + void * p; + } value; + int type; +}; + +/* Structure for nodes on the syntax tree */ +struct address_node { + char *address; + int type; +}; + +struct restrict_node { + struct address_node *addr; + struct address_node *mask; + queue *flags; + int line_no; +}; + +struct peer_node { + int host_mode; + struct address_node *addr; + queue *peerflags; + int minpoll; + int maxpoll; + int ttl; + int peerversion; + int peerkey; + double bias; +}; + +struct unpeer_node { + u_int assocID; + struct address_node * addr; +}; + +struct auth_node { + int control_key; + int cryptosw; + queue *crypto_cmd_list; + char *keys; + char *keysdir; + int request_key; + int revoke; + queue *trusted_key_list; + char *ntp_signd_socket; +}; + +struct filegen_node { + int filegen_token; + queue * options; +}; + +struct setvar_node { + char * var; + char * val; + int isdefault; +}; + +typedef struct nic_rule_node_tag { + int match_class; + char *if_name; /* interface name or numeric address */ + int action; +} nic_rule_node; + +struct addr_opts_node { + struct address_node *addr; + queue *options; +}; + +struct sim_node { + queue *init_opts; + queue *servers; +}; + + +/* The syntax tree */ +struct config_tree { + struct config_tree *link; + + struct attr_val source; + time_t timestamp; + + queue *peers; + queue *unpeers; + + /* Other Modes */ + int broadcastclient; + queue *manycastserver; + queue *multicastclient; + + queue *orphan_cmds; + + /* Monitoring Configuration */ + queue *stats_list; + char *stats_dir; + queue *filegen_opts; + + /* Access Control Configuration */ + queue *discard_opts; + queue *restrict_opts; + + queue *fudge; + queue *tinker; + queue *enable_opts; + queue *disable_opts; + struct auth_node auth; + + queue *logconfig; + queue *qos; + queue *phone; + queue *setvar; + queue *ttl; + queue *trap; + queue *vars; + queue *nic_rules; + + struct sim_node *sim_details; +}; + + +/* Structure for holding a remote configuration command */ +struct REMOTE_CONFIG_INFO { + char buffer[MAXLINE]; + char err_msg[MAXLINE]; + int pos; + int err_pos; + int no_errors; +}; + +/* get text from T_ tokens */ +const char * token_name(int token); + +struct peer_node *create_peer_node(int hmode, + struct address_node *addr, + queue *options); +struct unpeer_node *create_unpeer_node(struct address_node *addr); +struct address_node *create_address_node(char *addr, int type); +void destroy_address_node(struct address_node *my_node); +queue *enqueue_in_new_queue(void *my_node); +struct attr_val *create_attr_dval(int attr, double value); +struct attr_val *create_attr_ival(int attr, int value); +struct attr_val *create_attr_shorts(int, ntp_u_int16_t, ntp_u_int16_t); +struct attr_val *create_attr_sval(int attr, char *s); +struct attr_val *create_attr_pval(int attr, void *s); +struct filegen_node *create_filegen_node(int filegen_token, queue *options); +void **create_pval(void *val); +struct restrict_node *create_restrict_node(struct address_node *addr, + struct address_node *mask, + queue *flags, int line_no); +int *create_ival(int val); +struct addr_opts_node *create_addr_opts_node(struct address_node *addr, + queue *options); +struct sim_node *create_sim_node(queue *init_opts, queue *servers); +struct setvar_node *create_setvar_node(char *var, char *val, + int isdefault); +nic_rule_node *create_nic_rule_node(int match_class, char *if_name, + int action); + +script_info *create_sim_script_info(double duration, + queue *script_queue); +server_info *create_sim_server(struct address_node *addr, + double server_offset, queue *script); + +extern struct REMOTE_CONFIG_INFO remote_config; +void config_remotely(sockaddr_u *); + +#ifdef SAVECONFIG +int dump_config_tree(struct config_tree *ptree, FILE *df, int comment); +int dump_all_config_trees(FILE *df, int comment); +#endif -/* - * "tos" modifier keywords - */ -#define CONF_TOS_MINCLOCK 1 -#define CONF_TOS_MAXCLOCK 2 -#define CONF_TOS_MINSANE 3 -#define CONF_TOS_FLOOR 4 -#define CONF_TOS_CEILING 5 -#define CONF_TOS_COHORT 6 -#define CONF_TOS_MINDISP 7 -#define CONF_TOS_MAXDIST 8 -#define CONF_TOS_MAXHOP 9 -#define CONF_TOS_BEACON 10 -#define CONF_TOS_ORPHAN 11 -#ifdef OPENSSL -/* - * "crypto" modifier keywords - */ -#define CONF_CRYPTO_RSA 1 -#define CONF_CRYPTO_SIGN 2 -#define CONF_CRYPTO_LEAP 3 -#define CONF_CRYPTO_CERT 4 -#define CONF_CRYPTO_RAND 5 -#define CONF_CRYPTO_KEYS 6 -#define CONF_CRYPTO_IDENT 7 -#define CONF_CRYPTO_IFFPAR 8 -#define CONF_CRYPTO_GQPAR 9 -#define CONF_CRYPTO_MVPAR 10 -#define CONF_CRYPTO_PW 11 -#endif /* OPENSSL */ - -/* - * Address selection, IPv4 or IPv6 - */ -#define CONF_ADDR_IPV4 1 -#define CONF_ADDR_IPV6 2 +#endif /* !defined(NTP_CONFIG_H) */ diff -urN src/contrib/ntp/include/ntp_control.h src.ntp/contrib/ntp/include/ntp_control.h --- src/contrib/ntp/include/ntp_control.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/ntp_control.h 2009-12-09 08:36:36.000000000 +0100 @@ -45,30 +45,31 @@ /* * Opcodes */ -#define CTL_OP_UNSPEC 0 -#define CTL_OP_READSTAT 1 -#define CTL_OP_READVAR 2 -#define CTL_OP_WRITEVAR 3 -#define CTL_OP_READCLOCK 4 -#define CTL_OP_WRITECLOCK 5 -#define CTL_OP_SETTRAP 6 -#define CTL_OP_ASYNCMSG 7 -#define CTL_OP_UNSETTRAP 31 +#define CTL_OP_UNSPEC 0 /* unspeciffied */ +#define CTL_OP_READSTAT 1 /* read status */ +#define CTL_OP_READVAR 2 /* read variables */ +#define CTL_OP_WRITEVAR 3 /* write variables */ +#define CTL_OP_READCLOCK 4 /* read clock variables */ +#define CTL_OP_WRITECLOCK 5 /* write clock variables */ +#define CTL_OP_SETTRAP 6 /* set trap address */ +#define CTL_OP_ASYNCMSG 7 /* asynchronous message */ +#define CTL_OP_CONFIGURE 8 /* runtime configuration */ +#define CTL_OP_SAVECONFIG 9 /* save config to file */ +#define CTL_OP_UNSETTRAP 31 /* unset trap */ /* * {En,De}coding of the system status word */ -#define CTL_SST_TS_UNSPEC 0 /* time source unspecified */ -#define CTL_SST_TS_ATOM 1 /* time source calibrated atomic */ -#define CTL_SST_TS_LF 2 /* time source VLF or LF radio */ -#define CTL_SST_TS_HF 3 /* time source HF radio */ -#define CTL_SST_TS_UHF 4 /* time source UHF radio */ -#define CTL_SST_TS_LOCAL 5 /* time source LOCAL */ -#define CTL_SST_TS_NTP 6 /* time source NTP */ -#define CTL_SST_TS_UDPTIME 7 /* time source UDP/TIME */ -#define CTL_SST_TS_WRSTWTCH 8 /* time source is wristwatch */ -#define CTL_SST_TS_TELEPHONE 9 /* time source is telephone modem */ -#define CTL_SST_TS_PPS 0x20 /* time source is PPS signal */ +#define CTL_SST_TS_UNSPEC 0 /* unspec */ +#define CTL_SST_TS_ATOM 1 /* pps */ +#define CTL_SST_TS_LF 2 /* lf radio */ +#define CTL_SST_TS_HF 3 /* hf radio */ +#define CTL_SST_TS_UHF 4 /* uhf radio */ +#define CTL_SST_TS_LOCAL 5 /* local */ +#define CTL_SST_TS_NTP 6 /* ntp */ +#define CTL_SST_TS_UDPTIME 7 /* other */ +#define CTL_SST_TS_WRSTWTCH 8 /* wristwatch */ +#define CTL_SST_TS_TELEPHONE 9 /* telephone */ #define CTL_SYS_MAXEVENTS 15 @@ -90,14 +91,14 @@ #define CTL_PST_AUTHENABLE 0x40 #define CTL_PST_AUTHENTIC 0x20 #define CTL_PST_REACH 0x10 -#define CTL_PST_UNSPEC 0x08 +#define CTL_PST_BCAST 0x08 #define CTL_PST_SEL_REJECT 0 /* reject */ #define CTL_PST_SEL_SANE 1 /* x falsetick */ #define CTL_PST_SEL_CORRECT 2 /* . excess */ #define CTL_PST_SEL_SELCAND 3 /* - outlyer */ -#define CTL_PST_SEL_SYNCCAND 4 /* + candidat */ -#define CTL_PST_SEL_DISTSYSPEER 5 /* # selected */ +#define CTL_PST_SEL_SYNCCAND 4 /* + candidate */ +#define CTL_PST_SEL_EXCESS 5 /* # backup */ #define CTL_PST_SEL_SYSPEER 6 /* * sys.peer */ #define CTL_PST_SEL_PPS 7 /* o pps.peer */ @@ -154,31 +155,32 @@ #define CS_REFTIME 7 #define CS_POLL 8 #define CS_PEERID 9 -#define CS_STATE 10 -#define CS_OFFSET 11 -#define CS_DRIFT 12 -#define CS_JITTER 13 -#define CS_ERROR 14 -#define CS_CLOCK 15 -#define CS_PROCESSOR 16 -#define CS_SYSTEM 17 -#define CS_VERSION 18 -#define CS_STABIL 19 -#define CS_VARLIST 20 +#define CS_OFFSET 10 +#define CS_DRIFT 11 +#define CS_JITTER 12 +#define CS_ERROR 13 +#define CS_CLOCK 14 +#define CS_PROCESSOR 15 +#define CS_SYSTEM 16 +#define CS_VERSION 17 +#define CS_STABIL 18 +#define CS_VARLIST 19 +#define CS_TAI 20 +#define CS_LEAPTAB 21 +#define CS_LEAPEND 22 +#define CS_RATE 23 #ifdef OPENSSL -#define CS_FLAGS 21 -#define CS_HOST 22 -#define CS_PUBLIC 23 -#define CS_CERTIF 24 -#define CS_REVTIME 25 -#define CS_LEAPTAB 26 -#define CS_TAI 27 -#define CS_DIGEST 28 -#define CS_IDENT 29 -#define CS_REVOKE 30 -#define CS_MAXCODE CS_REVOKE +#define CS_FLAGS 24 +#define CS_HOST 25 +#define CS_PUBLIC 26 +#define CS_CERTIF 27 +#define CS_SIGNATURE 28 +#define CS_REVTIME 29 +#define CS_GROUP 30 +#define CS_DIGEST 31 +#define CS_MAXCODE CS_DIGEST #else -#define CS_MAXCODE CS_VARLIST +#define CS_MAXCODE CS_RATE #endif /* OPENSSL */ /* @@ -221,18 +223,21 @@ #define CP_FLASH 35 #define CP_TTL 36 #define CP_VARLIST 37 +#define CP_IN 38 +#define CP_OUT 39 +#define CP_RATE 40 +#define CP_BIAS 41 #ifdef OPENSSL -#define CP_FLAGS 38 -#define CP_HOST 39 -#define CP_VALID 40 -#define CP_INITSEQ 41 -#define CP_INITKEY 42 -#define CP_INITTSP 43 -#define CP_DIGEST 44 -#define CP_IDENT 45 -#define CP_MAXCODE CP_IDENT +#define CP_FLAGS 42 +#define CP_HOST 43 +#define CP_VALID 44 +#define CP_INITSEQ 45 +#define CP_INITKEY 46 +#define CP_INITTSP 47 +#define CP_SIGNATURE 48 +#define CP_MAXCODE CP_SIGNATURE #else -#define CP_MAXCODE CP_VARLIST +#define CP_MAXCODE CP_BIAS #endif /* OPENSSL */ /* @@ -251,7 +256,6 @@ #define CC_FLAGS 11 #define CC_DEVICE 12 #define CC_VARLIST 13 - #define CC_MAXCODE CC_VARLIST /* @@ -259,7 +263,7 @@ * ntp_request.c wants to see this. */ struct ctl_trap { - struct sockaddr_storage tr_addr;/* address of trap recipient */ + sockaddr_u tr_addr; /* address of trap recipient */ struct interface *tr_localaddr; /* interface to send this through */ u_long tr_settime; /* time trap was set */ u_long tr_count; /* async messages sent to this guy */ diff -urN src/contrib/ntp/include/ntp_crypto.h src.ntp/contrib/ntp/include/ntp_crypto.h --- src/contrib/ntp/include/ntp_crypto.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/ntp_crypto.h 2009-12-09 08:36:36.000000000 +0100 @@ -1,8 +1,27 @@ /* * ntp_crypto.h - definitions for cryptographic operations */ +#ifndef NTP_CRYPTO_H +#define NTP_CRYPTO_H + +/* + * Configuration codes (also needed for parser without OPENSSL) + */ +#define CRYPTO_CONF_NONE 0 /* nothing doing */ +#define CRYPTO_CONF_PRIV 1 /* host keys file name */ +#define CRYPTO_CONF_SIGN 2 /* signature keys file name */ +#define CRYPTO_CONF_CERT 3 /* certificate file name */ +#define CRYPTO_CONF_RAND 4 /* random seed file name */ +#define CRYPTO_CONF_IFFPAR 5 /* IFF parameters file name */ +#define CRYPTO_CONF_GQPAR 6 /* GQ parameters file name */ +#define CRYPTO_CONF_MVPAR 7 /* MV parameters file name */ +#define CRYPTO_CONF_PW 8 /* private key password */ +#define CRYPTO_CONF_IDENT 9 /* specify identity scheme */ +#define CRYPTO_CONF_NID 10 /* specify digest name */ + #ifdef OPENSSL #include "openssl/evp.h" + /* * The following bits are set by the CRYPTO_ASSOC message from * the server and are not modified by the client. @@ -20,13 +39,14 @@ * The following bits are used by the client during the protocol * exchange. */ -#define CRYPTO_FLAG_VALID 0x0100 /* public key verified */ +#define CRYPTO_FLAG_CERT 0x0100 /* public key verified */ #define CRYPTO_FLAG_VRFY 0x0200 /* identity verified */ #define CRYPTO_FLAG_PROV 0x0400 /* signature verified */ -#define CRYPTO_FLAG_AGREE 0x0800 /* cookie verifed */ +#define CRYPTO_FLAG_COOK 0x0800 /* cookie verifed */ #define CRYPTO_FLAG_AUTO 0x1000 /* autokey verified */ #define CRYPTO_FLAG_SIGN 0x2000 /* certificate signed */ -#define CRYPTO_FLAG_LEAP 0x4000 /* leapseconds table verified */ +#define CRYPTO_FLAG_LEAP 0x4000 /* leapsecond values verified */ +#define CRYPTO_FLAG_ALL 0x7f00 /* all mask */ /* * Flags used for certificate management @@ -48,7 +68,7 @@ #define CRYPTO_CERT CRYPTO_CMD(2) /* certificate */ #define CRYPTO_COOK CRYPTO_CMD(3) /* cookie value */ #define CRYPTO_AUTO CRYPTO_CMD(4) /* autokey values */ -#define CRYPTO_TAI CRYPTO_CMD(5) /* leapseconds table */ +#define CRYPTO_LEAP CRYPTO_CMD(5) /* leapsecond values */ #define CRYPTO_SIGN CRYPTO_CMD(6) /* certificate sign */ #define CRYPTO_IFF CRYPTO_CMD(7) /* IFF identity scheme */ #define CRYPTO_GQ CRYPTO_CMD(8) /* GQ identity scheme */ @@ -72,37 +92,20 @@ #define XEVNT_VFY XEVNT_CMD(9) /* certificate not verified */ #define XEVNT_PER XEVNT_CMD(10) /* host certificate expired */ #define XEVNT_CKY XEVNT_CMD(11) /* bad or missing cookie */ -#define XEVNT_DAT XEVNT_CMD(12) /* bad or missing leapseconds table */ +#define XEVNT_DAT XEVNT_CMD(12) /* bad or missing leapseconds */ #define XEVNT_CRT XEVNT_CMD(13) /* bad or missing certificate */ #define XEVNT_ID XEVNT_CMD(14) /* bad or missing group key */ #define XEVNT_ERR XEVNT_CMD(15) /* protocol error */ -#define XEVNT_SRV XEVNT_CMD(16) /* server certificate expired */ - -/* - * Configuration codes - */ -#define CRYPTO_CONF_NONE 0 /* nothing doing */ -#define CRYPTO_CONF_PRIV 1 /* host keys file name */ -#define CRYPTO_CONF_SIGN 2 /* signature keys file name */ -#define CRYPTO_CONF_LEAP 3 /* leapseconds table file name */ -#define CRYPTO_CONF_KEYS 4 /* keys directory path */ -#define CRYPTO_CONF_CERT 5 /* certificate file name */ -#define CRYPTO_CONF_RAND 6 /* random seed file name */ -#define CRYPTO_CONF_TRST 7 /* specify trust */ -#define CRYPTO_CONF_IFFPAR 8 /* IFF parameters file name */ -#define CRYPTO_CONF_GQPAR 9 /* GQ parameters file name */ -#define CRYPTO_CONF_MVPAR 10 /* GQ parameters file name */ -#define CRYPTO_CONF_PW 11 /* private key password */ -#define CRYPTO_CONF_IDENT 12 /* specify identity scheme */ /* * Miscellaneous crypto stuff */ #define NTP_MAXSESSION 100 /* maximum session key list entries */ -#define NTP_AUTOMAX 13 /* log2 default max session key life */ -#define KEY_REVOKE 16 /* log2 default key revoke timeout */ -#define NTP_MAXEXTEN 1024 /* maximum extension field size */ -#define TAI_1972 10 /* initial TAI offset (s) */ +#define NTP_MAXEXTEN 2048 /* maximum extension field size */ +#define NTP_AUTOMAX 12 /* default key list timeout (log2 s) */ +#define KEY_REVOKE 17 /* default key revoke timeout (log2 s) */ +#define NTP_REFRESH 19 /* default restart timeout (log2 s) */ +#define NTP_MAXKEY 65535 /* maximum symmetric key ID */ /* * The autokey structure holds the values used to authenticate key IDs. @@ -154,17 +157,27 @@ tstamp_t last; /* not valid after */ char *subject; /* subject common name */ char *issuer; /* issuer common name */ - u_char *grpkey; /* GQ group key */ - u_int grplen; /* GQ group key length */ + BIGNUM *grpkey; /* GQ group key */ struct value cert; /* certificate/value */ }; /* + * The keys info/value structure + */ +struct pkey_info { + struct pkey_info *link; /* forward link */ + EVP_PKEY *pkey; /* generic key */ + char *name; /* file name */ + tstamp_t fstamp; /* filestamp */ +}; + +/* * Cryptographic values */ -extern char *keysdir; /* crypto keys directory */ extern u_int crypto_flags; /* status word */ +extern int crypto_nid; /* digest nid */ extern struct value hostval; /* host name/value */ extern struct cert_info *cinfo; /* host certificate information */ extern struct value tai_leap; /* leapseconds table */ #endif /* OPENSSL */ +#endif /* NTP_CRYPTO_H */ diff -urN src/contrib/ntp/include/ntp_data_structures.h src.ntp/contrib/ntp/include/ntp_data_structures.h --- src/contrib/ntp/include/ntp_data_structures.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/include/ntp_data_structures.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,53 @@ +/* ntp_data_structures.h + * + * This file contains the structures and function prototypes for the data + * structures used by the ntp configuration code and the discrete event + * simulator. + * + * Written By: Sachin Kamboj + * University of Delaware + * Newark, DE 19711 + * Copyright (c) 2006 + */ + +#ifndef __NTP_DATA_STRUCTURES_H__ +#define __NTP_DATA_STRUCTURES_H__ + + +/* Structures for storing a priority queue + * --------------------------------------- + */ + +typedef struct node { + union { + struct node *next; + double d; + } nodeu; +} node; +#define node_next nodeu.next + +typedef struct Queue { + int (*get_order)(void *, void *); + node *front; + int no_of_elements; +} queue; + + +/* FUNCTION PROTOTYPES + * ------------------- + */ +queue *create_priority_queue(int (*get_order)(void *, void *)); +void destroy_queue(queue *my_queue); +void *get_node(size_t size); +void free_node(void *my_node); +void *next_node(void *my_node); +int empty(queue *my_queue); +void *queue_head(queue *my_queue); +queue *enqueue(queue *my_queue, void *my_node); +void *dequeue(queue *my_queue); +int get_no_of_elements(queue *my_queue); +void append_queue(queue *q1, queue *q2); +int get_fifo_order(void *el1, void *el2); +queue *create_queue(void); + +#endif diff -urN src/contrib/ntp/include/ntp_filegen.h src.ntp/contrib/ntp/include/ntp_filegen.h --- src/contrib/ntp/include/ntp_filegen.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/ntp_filegen.h 2009-12-09 08:36:36.000000000 +0100 @@ -35,17 +35,20 @@ /* without this, open is suppressed */ typedef struct FILEGEN - { - FILE *fp; /* file referring to current generation */ - char *prefix; /* filename prefix and basename to be used*/ - char *basename; /* for constructing filename of generation file */ +{ + FILE * fp; /* file referring to current generation */ + const char * prefix; /* filename prefix and basename to be used*/ + char * basename; /* for constructing filename of generation file */ /* WARNING: must be malloced !!! will be fed to free()*/ - u_long id; /* id of current generation */ - u_char type; /* type of file generation */ - u_char flag; /* flags modifying processing of file generation */ - } FILEGEN; + u_long id; /* id of current generation */ + u_char type; /* type of file generation */ + u_char flag; /* flags modifying processing of file generation */ +} FILEGEN; -extern void filegen_setup P((FILEGEN *, u_long)); -extern void filegen_config P((FILEGEN *, char *, u_int, u_int)); -extern FILEGEN *filegen_get P((char *)); -extern void filegen_register P((char *, const char *, FILEGEN *)); +extern void filegen_setup (FILEGEN *, u_long); +extern void filegen_config (FILEGEN *, const char *, u_int, u_int); +extern FILEGEN *filegen_get (const char *); +extern void filegen_register (const char *, const char *, FILEGEN *); +#ifdef DEBUG +extern void filegen_unregister(char *); +#endif diff -urN src/contrib/ntp/include/ntp_fp.h src.ntp/contrib/ntp/include/ntp_fp.h --- src/contrib/ntp/include/ntp_fp.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/ntp_fp.h 2009-12-09 08:36:35.000000000 +0100 @@ -5,12 +5,6 @@ #ifndef NTP_FP_H #define NTP_FP_H -#include -#include -#include - -#include "ntp_rfc2553.h" - #include "ntp_types.h" /* @@ -340,40 +334,38 @@ /* * Prototypes */ -extern char * dofptoa P((u_fp, int, short, int)); -extern char * dolfptoa P((u_long, u_long, int, short, int)); +extern char * dofptoa (u_fp, int, short, int); +extern char * dolfptoa (u_long, u_long, int, short, int); -extern int atolfp P((const char *, l_fp *)); -extern int buftvtots P((const char *, l_fp *)); -extern char * fptoa P((s_fp, short)); -extern char * fptoms P((s_fp, short)); -extern int hextolfp P((const char *, l_fp *)); -extern void gpstolfp P((int, int, unsigned long, l_fp *)); -extern int mstolfp P((const char *, l_fp *)); -extern char * prettydate P((l_fp *)); -extern char * gmprettydate P((l_fp *)); -extern char * uglydate P((l_fp *)); -extern void mfp_mul P((int32 *, u_int32 *, int32, u_int32, int32, u_int32)); - -extern void get_systime P((l_fp *)); -extern int step_systime P((double)); -extern int adj_systime P((double)); - -extern struct tm * ntp2unix_tm P((u_long ntp, int local)); - -#define lfptoa(_fpv, _ndec) mfptoa((_fpv)->l_ui, (_fpv)->l_uf, (_ndec)) -#define lfptoms(_fpv, _ndec) mfptoms((_fpv)->l_ui, (_fpv)->l_uf, (_ndec)) - -#define stoa(_sin) socktoa((_sin)) -#define stohost(_sin) socktohost((_sin)) - -#define ntoa(_sin) stoa(_sin) -#define ntohost(_sin) stohost(_sin) - -#define ufptoa(_fpv, _ndec) dofptoa((_fpv), 0, (_ndec), 0) -#define ufptoms(_fpv, _ndec) dofptoa((_fpv), 0, (_ndec), 1) -#define ulfptoa(_fpv, _ndec) dolfptoa((_fpv)->l_ui, (_fpv)->l_uf, 0, (_ndec), 0) -#define ulfptoms(_fpv, _ndec) dolfptoa((_fpv)->l_ui, (_fpv)->l_uf, 0, (_ndec), 1) -#define umfptoa(_fpi, _fpf, _ndec) dolfptoa((_fpi), (_fpf), 0, (_ndec), 0) +extern int atolfp (const char *, l_fp *); +extern int buftvtots (const char *, l_fp *); +extern char * fptoa (s_fp, short); +extern char * fptoms (s_fp, short); +extern int hextolfp (const char *, l_fp *); +extern void gpstolfp (int, int, unsigned long, l_fp *); +extern int mstolfp (const char *, l_fp *); +extern char * prettydate (l_fp *); +extern char * gmprettydate (l_fp *); +extern char * uglydate (l_fp *); +extern void mfp_mul (int32 *, u_int32 *, int32, u_int32, int32, u_int32); + +extern void get_systime (l_fp *); +extern int step_systime (double); +extern int adj_systime (double); + +extern struct tm * ntp2unix_tm (u_long ntp, int local); + +#define lfptoa(fpv, ndec) mfptoa((fpv)->l_ui, (fpv)->l_uf, (ndec)) +#define lfptoms(fpv, ndec) mfptoms((fpv)->l_ui, (fpv)->l_uf, (ndec)) + +#define stoa(addr) socktoa(addr) +#define ntoa(addr) stoa(addr) +#define stohost(addr) socktohost(addr) + +#define ufptoa(fpv, ndec) dofptoa((fpv), 0, (ndec), 0) +#define ufptoms(fpv, ndec) dofptoa((fpv), 0, (ndec), 1) +#define ulfptoa(fpv, ndec) dolfptoa((fpv)->l_ui, (fpv)->l_uf, 0, (ndec), 0) +#define ulfptoms(fpv, ndec) dolfptoa((fpv)->l_ui, (fpv)->l_uf, 0, (ndec), 1) +#define umfptoa(fpi, fpf, ndec) dolfptoa((fpi), (fpf), 0, (ndec), 0) #endif /* NTP_FP_H */ diff -urN src/contrib/ntp/include/ntp_intres.h src.ntp/contrib/ntp/include/ntp_intres.h --- src/contrib/ntp/include/ntp_intres.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/include/ntp_intres.h 2009-12-25 10:03:40.000000000 +0100 @@ -0,0 +1,14 @@ +#ifndef NTP_INTRES_H +#define NTP_INTRES_H + +/* + * Some systems do not support fork() and don't have an alternate + * threads implementation of ntp_intres. Such systems are limited + * to using numeric IP addresses. + */ +#if defined(VMS) || defined (SYS_VXWORKS) || \ + (!defined(HAVE_WORKING_FORK) && !defined(SYS_WINNT)) +#define NO_INTRES +#endif + +#endif /* !defined(NTP_INTRES_H) */ diff -urN src/contrib/ntp/include/ntp_io.h src.ntp/contrib/ntp/include/ntp_io.h --- src/contrib/ntp/include/ntp_io.h 2004-07-20 17:01:14.000000000 +0200 +++ src.ntp/contrib/ntp/include/ntp_io.h 2009-12-09 08:36:36.000000000 +0100 @@ -1,5 +1,5 @@ -#if !defined _NTP_IO_H -#define _NTP_IO_H +#ifndef NTP_IO_H +#define NTP_IO_H /* * POSIX says use to get O_* symbols and * SEEK_SET symbol form . @@ -8,9 +8,7 @@ # include #endif -#ifdef HAVE_SYS_TYPES_H -# include -#endif +#include #ifdef HAVE_UNISTD_H # include #endif @@ -30,6 +28,17 @@ # include "win32_io.h" #endif +#include +#include + +#if HAVE_NETINET_IN_H && HAVE_NETINET_IP_H +#include +# if HAVE_NETINET_IN_SYSTM_H +# include +# endif +#include +#endif + /* * Define FNDELAY and FASYNC using O_NONBLOCK and O_ASYNC if we need * to (and can). This is here initially for QNX, but may help for @@ -47,4 +56,34 @@ # endif #endif -#endif + +/* + * NIC rule match types + */ +typedef enum { + MATCH_ALL, + MATCH_IPV4, + MATCH_IPV6, + MATCH_WILDCARD, + MATCH_IFNAME, + MATCH_IFADDR +} nic_rule_match; + + +/* + * NIC rule actions + */ +typedef enum { + ACTION_LISTEN, + ACTION_IGNORE, + ACTION_DROP +} nic_rule_action; + + +isc_boolean_t get_broadcastclient_flag(void); +isc_boolean_t is_ip_address(const char *, isc_netaddr_t *); +extern void sau_from_netaddr(sockaddr_u *, const isc_netaddr_t *); +extern void add_nic_rule(nic_rule_match match_type, const char *if_name, + int prefixlen, nic_rule_action action); + +#endif /* NTP_IO_H */ diff -urN src/contrib/ntp/include/ntp_lineedit.h src.ntp/contrib/ntp/include/ntp_lineedit.h --- src/contrib/ntp/include/ntp_lineedit.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/include/ntp_lineedit.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,13 @@ + +/* + * ntp_lineedit.h - generic interface to various line editing libs + */ + +int ntp_readline_init(const char *prompt); +void ntp_readline_uninit(void); + +/* + * strings returned by ntp_readline go home to free() + */ +char * ntp_readline(int *pcount); + diff -urN src/contrib/ntp/include/ntp_lists.h src.ntp/contrib/ntp/include/ntp_lists.h --- src/contrib/ntp/include/ntp_lists.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/include/ntp_lists.h 2010-04-18 10:05:39.000000000 +0200 @@ -0,0 +1,257 @@ +/* + * ntp_lists.h - linked lists common code + * + * SLIST: singly-linked lists + * ========================== + * + * These macros implement a simple singly-linked list template. Both + * the listhead and per-entry next fields are declared as pointers to + * the list entry struct type. Initialization to NULL is typically + * implicit (for globals and statics) or handled by zeroing of the + * containing structure. + * + * The name of the next link field is passed as an argument to allow + * membership in several lists at once using multiple next link fields. + * + * When possible, placing the link field first in the entry structure + * allows slightly smaller code to be generated on some platforms. + * + * LINK_SLIST(listhead, pentry, nextlink) + * add entry at head + * + * LINK_TAIL_SLIST(listhead, pentry, nextlink, entrytype) + * add entry at tail + * + * LINK_SORT_SLIST(listhead, pentry, beforecur, nextlink, entrytype) + * add entry in sorted order. beforecur is an expression comparing + * pentry with the current list entry. The current entry can be + * referenced within beforecur as L_S_S_CUR(), which is short for + * LINK_SORT_SLIST_CUR(). beforecur is nonzero if pentry sorts + * before L_S_S_CUR(). + * + * UNLINK_HEAD_SLIST(punlinked, listhead, nextlink) + * unlink first entry and point punlinked to it, or set punlinked + * to NULL if the list is empty. + * + * UNLINK_SLIST(punlinked, listhead, ptounlink, nextlink, entrytype) + * unlink entry pointed to by ptounlink. punlinked is set to NULL + * if the entry is not found on the list, otherwise it is set to + * ptounlink. + * + * UNLINK_EXPR_SLIST(punlinked, listhead, expr, nextlink, entrytype) + * unlink entry where expression expr is nonzero. expr can refer + * to the entry being tested using UNLINK_EXPR_SLIST_CURRENT(), + * alias U_E_S_CUR(). See the implementation of UNLINK_SLIST() + * below for an example. + * punlinked is pointed to the removed entry or NULL if none + * satisfy expr. + * + * DLIST: doubly-linked lists + * ========================== + * + * Elements on DLISTs always have non-NULL forward and back links, + * because both link chains are circular. The beginning/end is marked + * by the listhead, which is the same type as elements for simplicity. + * An empty list's listhead has both links set to its own address. + * + * + */ +#ifndef NTP_LISTS_H +#define NTP_LISTS_H + +#ifndef TRUE +# define TRUE 1 +# define NTP_LISTS_UNDEF_TRUE +#endif + +#define LINK_SLIST(listhead, pentry, nextlink) \ +do { \ + (pentry)->nextlink = (listhead); \ + (listhead) = (pentry); \ +} while (0) + +#define LINK_TAIL_SLIST(listhead, pentry, nextlink, entrytype) \ +do { \ + entrytype **pptail; \ + \ + pptail = &(listhead); \ + while (*pptail != NULL) \ + pptail = &((*pptail)->nextlink); \ + \ + (pentry)->nextlink = NULL; \ + *pptail = (pentry); \ +} while (0) + +#define LINK_SORT_SLIST_CURRENT() (*ppentry) +#define L_S_S_CUR() LINK_SORT_SLIST_CURRENT() + +#define LINK_SORT_SLIST(listhead, pentry, beforecur, nextlink, \ + entrytype) \ +do { \ + entrytype **ppentry; \ + \ + ppentry = &(listhead); \ + while (*ppentry != NULL) { \ + if (beforecur) { \ + (pentry)->nextlink = *ppentry; \ + *ppentry = (pentry); \ + break; \ + } \ + ppentry = &((*ppentry)->nextlink); \ + if (NULL == *ppentry) { \ + (pentry)->nextlink = NULL; \ + *ppentry = (pentry); \ + break; \ + } \ + } \ +} while (0) + +#define UNLINK_HEAD_SLIST(punlinked, listhead, nextlink) \ +do { \ + (punlinked) = (listhead); \ + if (NULL != (punlinked)) { \ + (listhead) = (punlinked)->nextlink; \ + (punlinked)->nextlink = NULL; \ + } \ +} while (0) + +#define UNLINK_EXPR_SLIST_CURRENT() (*ppentry) +#define U_E_S_CUR() UNLINK_EXPR_SLIST_CURRENT() + +#define UNLINK_EXPR_SLIST(punlinked, listhead, expr, nextlink, \ + entrytype) \ +do { \ + entrytype **ppentry; \ + \ + ppentry = &(listhead); \ + \ + while (!(expr)) \ + if ((*ppentry)->nextlink != NULL) \ + ppentry = &((*ppentry)->nextlink); \ + else { \ + ppentry = NULL; \ + break; \ + } \ + \ + if (ppentry != NULL) { \ + (punlinked) = *ppentry; \ + *ppentry = (punlinked)->nextlink; \ + (punlinked)->nextlink = NULL; \ + } else \ + (punlinked) = NULL; \ +} while (0) + +#define UNLINK_SLIST(punlinked, listhead, ptounlink, nextlink, \ + entrytype) \ + UNLINK_EXPR_SLIST(punlinked, listhead, (ptounlink) == \ + U_E_S_CUR(), nextlink, entrytype) + +#define CHECK_SLIST(listhead, nextlink, entrytype) \ +do { \ + entrytype *pentry; \ + \ + for (pentry = (listhead); \ + pentry != NULL; \ + pentry = pentry->nextlink){ \ + NTP_INSIST(pentry != pentry->nextlink); \ + NTP_INSIST((listhead) != pentry->nextlink); \ + } \ +} while (0) + +/* + * DLIST + */ +#define DECL_DLIST_LINK(entrytype, link) \ +struct { \ + entrytype * b; \ + entrytype * f; \ +} link + +#define INIT_DLIST(listhead, link) \ +do { \ + (listhead).link.f = &(listhead); \ + (listhead).link.b = &(listhead); \ +} while (0) + +#define HEAD_DLIST(listhead, link) \ + ( \ + (&(listhead) != (listhead).link.f) \ + ? (listhead).link.f \ + : NULL \ + ) + +#define TAIL_DLIST(listhead, link) \ + ( \ + (&(listhead) != (listhead).link.b) \ + ? (listhead).link.b \ + : NULL \ + ) + +#define NEXT_DLIST(listhead, entry, link) \ + ( \ + (&(listhead) != (entry)->link.f) \ + ? (entry)->link.f \ + : NULL \ + ) + +#define PREV_DLIST(listhead, entry, link) \ + ( \ + (&(listhead) != (entry)->link.b) \ + ? (entry)->link.b \ + : NULL \ + ) + +#define LINK_DLIST(listhead, pentry, link) \ +do { \ + (pentry)->link.f = (listhead).link.f; \ + (pentry)->link.b = &(listhead); \ + (listhead).link.f->link.b = (pentry); \ + (listhead).link.f = (pentry); \ +} while (0) + +#define LINK_TAIL_DLIST(listhead, pentry, link) \ +do { \ + (pentry)->link.b = (listhead).link.b; \ + (pentry)->link.f = &(listhead); \ + (listhead).link.b->link.f = (pentry); \ + (listhead).link.b = (pentry); \ +} while (0) + +#define UNLINK_DLIST(ptounlink, link) \ +do { \ + (ptounlink)->link.b->link.f = (ptounlink)->link.f; \ + (ptounlink)->link.f->link.b = (ptounlink)->link.b; \ + (ptounlink)->link.b = NULL; \ + (ptounlink)->link.f = NULL; \ +} while (0) + +#define ITER_DLIST_BEGIN(listhead, iter, link, entrytype) \ +{ \ + entrytype *i_dl_nextiter; \ + \ + for ((iter) = (listhead).link.f; \ + (iter) != &(listhead) \ + && ((i_dl_nextiter = (iter)->link.f), TRUE); \ + (iter) = i_dl_nextiter) { +#define ITER_DLIST_END() \ + } \ +} + +#define REV_ITER_DLIST_BEGIN(listhead, iter, link, entrytype) \ +{ \ + entrytype *i_dl_nextiter; \ + \ + for ((iter) = (listhead).link.b; \ + (iter) != &(listhead) \ + && ((i_dl_nextiter = (iter)->link.b), TRUE); \ + (iter) = i_dl_nextiter) { +#define REV_ITER_DLIST_END() \ + } \ +} + + +#ifdef NTP_LISTS_UNDEF_TRUE +# undef TRUE +#endif + +#endif /* NTP_LISTS_H */ diff -urN src/contrib/ntp/include/ntp_machine.h src.ntp/contrib/ntp/include/ntp_machine.h --- src/contrib/ntp/include/ntp_machine.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/ntp_machine.h 2009-12-09 08:36:36.000000000 +0100 @@ -2,8 +2,8 @@ * Collect all machine dependent idiosyncrasies in one place. */ -#ifndef __ntp_machine -#define __ntp_machine +#ifndef NTP_MACHINE_H +#define NTP_MACHINE_H #ifdef HAVE_CONFIG_H # include @@ -74,24 +74,12 @@ MISC - HAVE_PROTOTYPES - Prototype functions DOSYNCTODR - Resync TODR clock every hour. RETSIGTYPE - Define signal function type. NO_SIGNED_CHAR_DECL - No "signed char" see include/ntp.h LOCK_PROCESS - Have plock. */ -/* - * Set up for prototyping (duplicated from ntp_types.h) - */ -#ifndef P -#if defined(__STDC__) || defined(HAVE_PROTOTYPES) -#define P(x) x -#else /* not __STDC__ and not HAVE_PROTOTYPES */ -#define P(x) () -#endif /* not __STDC__ and not HAVE_PROTOTYPES */ -#endif /* P */ - #if !defined(HAVE_NTP_ADJTIME) && defined(HAVE___ADJTIMEX) # define ntp_adjtime __adjtimex #endif @@ -239,55 +227,13 @@ * make them macros for everyone else */ #ifndef SYS_WINNT -# define SOCKET int +typedef int SOCKET; # define INVALID_SOCKET -1 # define SOCKET_ERROR -1 -# define closesocket close +# define closesocket(fd) close(fd) #endif -/* - * Windows NT - */ -#if defined(SYS_WINNT) -# if !defined(HAVE_CONFIG_H) || !defined(__config) -# include -# endif /* HAVE_CONFIG_H) */ -# include -# include -# include - -# define ifreq _INTERFACE_INFO -# define ifr_flags iiFlags -# define ifr_addr iiAddress.AddressIn -# define ifr_broadaddr iiBroadcastAddress.AddressIn -# define ifr_mask iiNetmask.AddressIn -# define zz_family sin_family - -# define S_IFREG _S_IFREG -# define stat _stat -# define isascii __isascii -# define isatty _isatty -# define mktemp _mktemp -# define unlink _unlink -# define fileno _fileno -# define write _write -#ifndef close -# define close _close -#endif -# undef interface -# include -#define getpid _getpid -/* - * Defining registers are not a good idea on Windows - * This gets rid of the usage - */ -#ifndef register -# define register -#endif - typedef char *caddr_t; -# define vsnprintf _vsnprintf -#endif /* SYS_WINNT */ -int ntp_set_tod P((struct timeval *tvp, void *tzp)); +int ntp_set_tod (struct timeval *tvp, void *tzp); #if defined (SYS_CYGWIN32) #include @@ -326,7 +272,7 @@ #include "taskLib.h" #include "time.h" -extern int sysClkRateGet P(()); +extern int sysClkRateGet (); /* usrtime.h * Bob Herlien's excellent time code find it at: @@ -335,14 +281,14 @@ * adjtime() too ... casey */ /* -extern int gettimeofday P(( struct timeval *tp, struct timezone *tzp )); -extern int settimeofday P((struct timeval *, struct timezone *)); -extern int adjtime P(( struct timeval *delta, struct timeval *olddelta )); +extern int gettimeofday ( struct timeval *tp, struct timezone *tzp ); +extern int settimeofday (struct timeval *, struct timezone *); +extern int adjtime ( struct timeval *delta, struct timeval *olddelta ); */ /* in machines.c */ -extern void sleep P((int seconds)); -extern void alarm P((int seconds)); +extern void sleep (int seconds); +extern void alarm (int seconds); /* machines.c */ @@ -382,10 +328,10 @@ #define TRY_AGAIN 2 -struct hostent *gethostbyname P((char * netnum)); -struct hostent *gethostbyaddr P((char * netnum, int size, int addr_type)); +struct hostent *gethostbyname (char * netnum); +struct hostent *gethostbyaddr (char * netnum, int size, int addr_type); /* type is the protocol */ -struct servent *getservbyname P((char *name, char *type)); +struct servent *getservbyname (char *name, char *type); #endif /* NO_NETDB */ #ifdef NO_MAIN_ALLOWED @@ -515,8 +461,7 @@ #if !defined(HAVE_ATT_NICE) \ && !defined(HAVE_BSD_NICE) \ - && !defined(HAVE_NO_NICE) \ - && !defined(SYS_WINNT) + && !defined(HAVE_NO_NICE) #include "ERROR: You must define one of the HAVE_xx_NICE defines!" #endif @@ -544,7 +489,7 @@ #endif #ifndef HAVE_TIMEGM -extern time_t timegm P((struct tm *)); +extern time_t timegm (struct tm *); #endif #ifdef HAVE_SYSV_TTYS @@ -587,4 +532,4 @@ BYTE_ORDER_NOT_DEFINED_FOR_AUTHENTICATION #endif -#endif /* __ntp_machine */ +#endif /* NTP_MACHINE_H */ diff -urN src/contrib/ntp/include/ntp_malloc.h src.ntp/contrib/ntp/include/ntp_malloc.h --- src/contrib/ntp/include/ntp_malloc.h 1999-12-09 14:01:08.000000000 +0100 +++ src.ntp/contrib/ntp/include/ntp_malloc.h 2009-12-09 08:36:37.000000000 +0100 @@ -1,8 +1,8 @@ /* * Define malloc and friends. */ -#ifndef _ntp_malloc_h -#define _ntp_malloc_h +#ifndef NTP_MALLOC_H +#define NTP_MALLOC_H #ifdef HAVE_CONFIG_H # include @@ -10,10 +10,10 @@ #ifdef HAVE_STDLIB_H # include -#else /* HAVE_STDLIB_H */ +#else # ifdef HAVE_MALLOC_H # include # endif -#endif /* HAVE_STDLIB_H */ +#endif -#endif /* _ntp_malloc_h */ +#endif /* NTP_MALLOC_H */ diff -urN src/contrib/ntp/include/ntp_md5.h src.ntp/contrib/ntp/include/ntp_md5.h --- src/contrib/ntp/include/ntp_md5.h 2004-07-20 17:01:16.000000000 +0200 +++ src.ntp/contrib/ntp/include/ntp_md5.h 2010-05-11 09:46:54.000000000 +0200 @@ -1,9 +1,29 @@ /* * ntp_md5.h: deal with md5.h headers + * + * Use the system MD5 if available, otherwise libisc's. */ - -#ifdef HAVE_MD5_H +#if defined HAVE_MD5_H && defined HAVE_MD5INIT # include #else -# include "rsa_md5.h" +# include "isc/md5.h" + typedef isc_md5_t MD5_CTX; +# define MD5Init(c) isc_md5_init(c) +# define MD5Update(c, p, s) isc_md5_update(c, p, s) +# define MD5Final(d, c) isc_md5_final((c), (d)) /* swapped */ +#endif + +/* + * Provide OpenSSL-alike MD5 API if we're not using OpenSSL + */ +#ifndef OPENSSL + typedef MD5_CTX EVP_MD_CTX; +# define EVP_get_digestbynid(t) NULL +# define EVP_DigestInit(c, dt) MD5Init(c) +# define EVP_DigestUpdate(c, p, s) MD5Update(c, p, s) +# define EVP_DigestFinal(c, d, pdl) \ + do { \ + MD5Final((d), (c)); \ + *(pdl) = 16; \ + } while (0) #endif diff -urN src/contrib/ntp/include/ntp_net.h src.ntp/contrib/ntp/include/ntp_net.h --- src/contrib/ntp/include/ntp_net.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/include/ntp_net.h 2010-04-18 10:05:39.000000000 +0200 @@ -0,0 +1,228 @@ +/* + * ntp_net.h - definitions for NTP network stuff + */ + +#ifndef NTP_NET_H +#define NTP_NET_H + +#include +#ifdef HAVE_SYS_SOCKET_H +#include +#endif +#ifdef HAVE_NETINET_IN_H +#include +#endif + +#include "ntp_rfc2553.h" + +typedef union { + struct sockaddr sa; + struct sockaddr_in sa4; + struct sockaddr_in6 sa6; +} sockaddr_u; + +/* + * Utilities for manipulating sockaddr_u v4/v6 unions + */ +#define SOCK_ADDR4(psau) ((psau)->sa4.sin_addr) +#define SOCK_ADDR6(psau) ((psau)->sa6.sin6_addr) + +#define PSOCK_ADDR4(psau) (&SOCK_ADDR4(psau)) +#define PSOCK_ADDR6(psau) (&SOCK_ADDR6(psau)) + +#define AF(psau) ((psau)->sa.sa_family) + +#define IS_IPV4(psau) (AF_INET == AF(psau)) +#define IS_IPV6(psau) (AF_INET6 == AF(psau)) + +/* sockaddr_u v4 address in network byte order */ +#define NSRCADR(psau) (SOCK_ADDR4(psau).s_addr) + +/* sockaddr_u v4 address in host byte order */ +#define SRCADR(psau) (ntohl(NSRCADR(psau))) + +/* sockaddr_u v6 address in network byte order */ +#define NSRCADR6(psau) (SOCK_ADDR6(psau).s6_addr) + +/* assign sockaddr_u v4 address from host byte order */ +#define SET_ADDR4(psau, addr4) (NSRCADR(psau) = htonl(addr4)) + +/* assign sockaddr_u v4 address from network byte order */ +#define SET_ADDR4N(psau, addr4n) (NSRCADR(psau) = (addr4n)); + +/* assign sockaddr_u v6 address from network byte order */ +#define SET_ADDR6N(psau, s6_addr) \ + (SOCK_ADDR6(psau) = (s6_addr)) + +/* sockaddr_u v4/v6 port in network byte order */ +#define NSRCPORT(psau) ((psau)->sa4.sin_port) + +/* sockaddr_u v4/v6 port in host byte order */ +#define SRCPORT(psau) (ntohs(NSRCPORT(psau))) + +/* assign sockaddr_u v4/v6 port from host byte order */ +#define SET_PORT(psau, port) (NSRCPORT(psau) = htons(port)) + +/* sockaddr_u v6 scope */ +#define SCOPE_VAR(psau) ((psau)->sa6.sin6_scope_id) + +#ifdef ISC_PLATFORM_HAVESCOPEID +/* v4/v6 scope (always zero for v4) */ +# define SCOPE(psau) (IS_IPV4(psau) \ + ? 0 \ + : SCOPE_VAR(psau)) + +/* are two v6 sockaddr_u scopes equal? */ +# define SCOPE_EQ(psau1, psau2) \ + (SCOPE_VAR(psau1) == SCOPE_VAR(psau2)) + +/* assign scope if supported */ +# define SET_SCOPE(psau, s) \ + do \ + if (IS_IPV6(psau)) \ + SCOPE_VAR(psau) = (s); \ + while (0) +#else /* ISC_PLATFORM_HAVESCOPEID not defined */ +# define SCOPE(psau) (0) +# define SCOPE_EQ(psau1, psau2) (1) +# define SET_SCOPE(psau, s) do { } while (0) +#endif /* ISC_PLATFORM_HAVESCOPEID */ + +/* v4/v6 is multicast address */ +#define IS_MCAST(psau) \ + (IS_IPV4(psau) \ + ? IN_CLASSD(SRCADR(psau)) \ + : IN6_IS_ADDR_MULTICAST(PSOCK_ADDR6(psau))) + +#define SIZEOF_INADDR(fam) \ + ((AF_INET == (fam)) \ + ? sizeof(struct in_addr) \ + : sizeof(struct in6_addr)) + +#define SIZEOF_SOCKADDR(fam) \ + ((AF_INET == (fam)) \ + ? sizeof(struct sockaddr_in) \ + : sizeof(struct sockaddr_in6)) + +#define SOCKLEN(psau) \ + (IS_IPV4(psau) \ + ? sizeof((psau)->sa4) \ + : sizeof((psau)->sa6)) + +#define ZERO_SOCK(psau) \ + memset((psau), 0, sizeof(*(psau))) + +/* blast a byte value across sockaddr_u v6 address */ +#define MEMSET_ADDR6(psau, v) \ + memset((psau)->sa6.sin6_addr.s6_addr, (v), \ + sizeof((psau)->sa6.sin6_addr.s6_addr)) + +#define SET_ONESMASK(psau) \ + do { \ + if (IS_IPV6(psau)) \ + MEMSET_ADDR6((psau), 0xff); \ + else \ + NSRCADR(psau) = 0xffffffff; \ + } while(0) + +/* zero sockaddr_u, fill in family and all-ones (host) mask */ +#define SET_HOSTMASK(psau, family) \ + do { \ + ZERO_SOCK(psau); \ + AF(psau) = (family); \ + SET_ONESMASK(psau); \ + } while (0) + +/* + * compare two in6_addr returning negative, 0, or positive. + * ADDR6_CMP is negative if *pin6A is lower than *pin6B, zero if they + * are equal, positive if *pin6A is higher than *pin6B. IN6ADDR_ANY + * is the lowest address (128 zero bits). + */ +#define ADDR6_CMP(pin6A, pin6B) \ + memcmp((pin6A)->s6_addr, (pin6B)->s6_addr, \ + sizeof(pin6A)->s6_addr) + +/* compare two in6_addr for equality only */ +#if !defined(SYS_WINNT) || !defined(in_addr6) +#define ADDR6_EQ(pin6A, pin6B) \ + (!ADDR6_CMP(pin6A, pin6B)) +#else +#define ADDR6_EQ(pin6A, pin6B) \ + IN6_ADDR_EQUAL(pin6A, pin6B) +#endif + +/* compare a in6_addr with socket address */ +#define S_ADDR6_EQ(psau, pin6) \ + ADDR6_EQ(&(psau)->sa6.sin6_addr, pin6) + +/* are two sockaddr_u's addresses equal? (port excluded) */ +#define SOCK_EQ(psau1, psau2) \ + ((AF(psau1) != AF(psau2)) \ + ? 0 \ + : IS_IPV4(psau1) \ + ? (NSRCADR(psau1) == NSRCADR(psau2)) \ + : (S_ADDR6_EQ((psau1), PSOCK_ADDR6(psau2)) \ + && SCOPE_EQ((psau1), (psau2)))) + +/* are two sockaddr_u's addresses and ports equal? */ +#define ADDR_PORT_EQ(psau1, psau2) \ + ((NSRCPORT(psau1) != NSRCPORT(psau2) \ + ? 0 \ + : SOCK_EQ((psau1), (psau2)))) + +/* is sockaddr_u address unspecified? */ +#define SOCK_UNSPEC(psau) \ + (IS_IPV4(psau) \ + ? !NSRCADR(psau) \ + : IN6_IS_ADDR_UNSPECIFIED(PSOCK_ADDR6(psau))) + +/* just how unspecified do you mean? (scope 0/unspec too) */ +#define SOCK_UNSPEC_S(psau) \ + (SOCK_UNSPEC(psau) && !SCOPE(psau)) + +/* choose a default net interface (struct interface) for v4 or v6 */ +#define ANY_INTERFACE_BYFAM(family) \ + ((AF_INET == family) \ + ? any_interface \ + : any6_interface) + +/* choose a default interface for addresses' protocol (addr family) */ +#define ANY_INTERFACE_CHOOSE(psau) \ + ANY_INTERFACE_BYFAM(AF(psau)) + + +/* + * We tell reference clocks from real peers by giving the reference + * clocks an address of the form 127.127.t.u, where t is the type and + * u is the unit number. We define some of this here since we will need + * some sanity checks to make sure this address isn't interpretted as + * that of a normal peer. + */ +#define REFCLOCK_ADDR 0x7f7f0000 /* 127.127.0.0 */ +#define REFCLOCK_MASK 0xffff0000 /* 255.255.0.0 */ + +#ifdef REFCLOCK +#define ISREFCLOCKADR(srcadr) \ + (IS_IPV4(srcadr) && \ + (SRCADR(srcadr) & REFCLOCK_MASK) == REFCLOCK_ADDR) +#else +#define ISREFCLOCKADR(srcadr) (0) +#endif + +/* + * Macro for checking for invalid addresses. This is really, really + * gross, but is needed so no one configures a host on net 127 now that + * we're encouraging it the the configuration file. + */ +#define LOOPBACKADR 0x7f000001 +#define LOOPNETMASK 0xff000000 + +#define ISBADADR(srcadr) \ + (IS_IPV4(srcadr) \ + && ((SRCADR(srcadr) & LOOPNETMASK) \ + == (LOOPBACKADR & LOOPNETMASK)) \ + && SRCADR(srcadr) != LOOPBACKADR) + + +#endif /* NTP_NET_H */ diff -urN src/contrib/ntp/include/ntp_random.h src.ntp/contrib/ntp/include/ntp_random.h --- src/contrib/ntp/include/ntp_random.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/ntp_random.h 2009-12-09 08:36:35.000000000 +0100 @@ -1,14 +1,14 @@ #include -long ntp_random P((void)); -void ntp_srandom P((unsigned long)); -void ntp_srandomdev P((void)); -char * ntp_initstate P((unsigned long, /* seed for R.N.G. */ +long ntp_random (void); +void ntp_srandom (unsigned long); +void ntp_srandomdev (void); +char * ntp_initstate (unsigned long, /* seed for R.N.G. */ char *, /* pointer to state array */ long /* # bytes of state info */ - )); -char * ntp_setstate P((char *)); /* pointer to state array */ + ); +char * ntp_setstate (char *); /* pointer to state array */ diff -urN src/contrib/ntp/include/ntp_refclock.h src.ntp/contrib/ntp/include/ntp_refclock.h --- src/contrib/ntp/include/ntp_refclock.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/ntp_refclock.h 2009-12-09 08:36:35.000000000 +0100 @@ -123,14 +123,14 @@ */ struct refclockio { struct refclockio *next; /* link to next structure */ - void (*clock_recv) P((struct recvbuf *)); /* completion routine */ - int (*io_input) P((struct recvbuf *)); /* input routine - + void (*clock_recv) (struct recvbuf *); /* completion routine */ + int (*io_input) (struct recvbuf *); /* input routine - to avoid excessive buffer use due to small bursts of refclock input data */ caddr_t srcclock; /* pointer to clock structure */ int datalen; /* lenth of data */ - SOCKET fd; /* file descriptor */ + int fd; /* file descriptor */ u_long recvcount; /* count of receive completions */ }; @@ -185,7 +185,7 @@ const char *clockdesc; /* clock description */ char a_lastcode[BMAX]; /* last timecode received */ - u_short lencode; /* length of last timecode */ + int lencode; /* length of last timecode */ int year; /* year of eternity */ int day; /* day of year */ @@ -231,14 +231,14 @@ #define NOFLAGS 0 /* flag for null flags */ struct refclock { - int (*clock_start) P((int, struct peer *)); - void (*clock_shutdown) P((int, struct peer *)); - void (*clock_poll) P((int, struct peer *)); - void (*clock_control) P((int, struct refclockstat *, - struct refclockstat *, struct peer *)); - void (*clock_init) P((void)); - void (*clock_buginfo) P((int, struct refclockbug *, struct peer *)); - void (*clock_timer) P((int, struct peer *)); + int (*clock_start) (int, struct peer *); + void (*clock_shutdown) (int, struct peer *); + void (*clock_poll) (int, struct peer *); + void (*clock_control) (int, struct refclockstat *, + struct refclockstat *, struct peer *); + void (*clock_init) (void); + void (*clock_buginfo) (int, struct refclockbug *, struct peer *); + void (*clock_timer) (int, struct peer *); }; /* @@ -247,27 +247,28 @@ /* * auxiliary PPS interface (implemented by refclock_atom()) */ -extern int pps_sample P((l_fp *)); -extern int io_addclock_simple P((struct refclockio *)); -extern int io_addclock P((struct refclockio *)); -extern void io_closeclock P((struct refclockio *)); +extern int pps_sample (l_fp *); +extern int io_addclock_simple (struct refclockio *); +extern int io_addclock (struct refclockio *); +extern void io_closeclock (struct refclockio *); #ifdef REFCLOCK -extern void refclock_buginfo P((struct sockaddr_storage *, - struct refclockbug *)); -extern void refclock_control P((struct sockaddr_storage *, +extern void refclock_buginfo (sockaddr_u *, + struct refclockbug *); +extern void refclock_control (sockaddr_u *, struct refclockstat *, - struct refclockstat *)); -extern int refclock_open P((char *, u_int, u_int)); -extern int refclock_setup P((int, u_int, u_int)); -extern void refclock_timer P((struct peer *)); -extern void refclock_transmit P((struct peer *)); -extern int refclock_ioctl P((int, u_int)); -extern int refclock_process P((struct refclockproc *)); -extern void refclock_process_offset P((struct refclockproc *, l_fp, l_fp, double)); -extern void refclock_report P((struct peer *, int)); -extern int refclock_gtlin P((struct recvbuf *, char *, int, l_fp *)); -extern int refclock_gtraw P((struct recvbuf *, char *, int, l_fp *)); + struct refclockstat *); +extern int refclock_open (char *, u_int, u_int); +extern int refclock_setup (int, u_int, u_int); +extern void refclock_timer (struct peer *); +extern void refclock_transmit (struct peer *); +extern int refclock_ioctl (int, u_int); +extern int refclock_process (struct refclockproc *); +extern int refclock_process_f (struct refclockproc *, double); +extern void refclock_process_offset (struct refclockproc *, l_fp, l_fp, double); +extern void refclock_report (struct peer *, int); +extern int refclock_gtlin (struct recvbuf *, char *, int, l_fp *); +extern int refclock_gtraw (struct recvbuf *, char *, int, l_fp *); #endif /* REFCLOCK */ #endif /* NTP_REFCLOCK_H */ diff -urN src/contrib/ntp/include/ntp_request.h src.ntp/contrib/ntp/include/ntp_request.h --- src/contrib/ntp/include/ntp_request.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/ntp_request.h 2009-12-09 08:36:35.000000000 +0100 @@ -2,10 +2,12 @@ * ntp_request.h - definitions for the ntpd remote query facility */ -#ifndef _NTP_REQUEST_H -#define _NTP_REQUEST_H +#ifndef NTP_REQUEST_H +#define NTP_REQUEST_H +#include "stddef.h" #include "ntp_types.h" +#include "recvbuff.h" /* * A mode 7 packet is used exchanging data between an NTP server @@ -133,8 +135,8 @@ char data[MAXFILENAME + 48]; /* data area [32 prev](176 byte max) */ /* struct conf_peer must fit */ l_fp tstamp; /* time stamp, for authentication */ - keyid_t keyid; /* encryption key */ - char mac[MAX_MAC_LEN-sizeof(u_int32)]; /* (optional) 8 byte auth code */ + keyid_t keyid; /* (optional) encryption key */ + char mac[MAX_MAC_LEN-sizeof(keyid_t)]; /* (optional) auth code */ }; /* @@ -143,23 +145,24 @@ */ struct req_pkt_tail { l_fp tstamp; /* time stamp, for authentication */ - keyid_t keyid; /* encryption key */ - char mac[MAX_MAC_LEN-sizeof(u_int32)]; /* (optional) 8 byte auth code */ + keyid_t keyid; /* (optional) encryption key */ + char mac[MAX_MAC_LEN-sizeof(keyid_t)]; /* (optional) auth code */ }; -/* - * Input packet lengths. One with the mac, one without. - */ -#define REQ_LEN_HDR 8 /* 4 * u_char + 2 * u_short */ -#define REQ_LEN_MAC (sizeof(struct req_pkt)) -#define REQ_LEN_NOMAC (sizeof(struct req_pkt) - MAX_MAC_LEN) +/* MODE_PRIVATE request packet header length before optional items. */ +#define REQ_LEN_HDR (offsetof(struct req_pkt, data)) +/* MODE_PRIVATE request packet fixed length without MAC. */ +#define REQ_LEN_NOMAC (offsetof(struct req_pkt, keyid)) +/* MODE_PRIVATE req_pkt_tail minimum size (16 octet digest) */ +#define REQ_TAIL_MIN \ + (sizeof(struct req_pkt_tail) - (MAX_MAC_LEN - MAX_MD5_LEN)) /* - * A response packet. The length here is variable, this is a - * maximally sized one. Note that this implementation doesn't + * A MODE_PRIVATE response packet. The length here is variable, this + * is a maximally sized one. Note that this implementation doesn't * authenticate responses. */ -#define RESP_HEADER_SIZE (8) +#define RESP_HEADER_SIZE (offsetof(struct resp_pkt, data)) #define RESP_DATA_SIZE (500) struct resp_pkt { @@ -381,7 +384,7 @@ u_int32 pkeyid; /* unused */ u_int32 refid; /* peer.refid */ u_int32 timer; /* peer.timer */ - s_fp rootdelay; /* peer.distance */ + s_fp rootdelay; /* peer.delay */ u_fp rootdispersion; /* peer.dispersion */ l_fp reftime; /* peer.reftime */ l_fp org; /* peer.org */ @@ -465,7 +468,7 @@ u_char leap; /* system leap bits */ u_char stratum; /* our stratum */ s_char precision; /* local clock precision */ - s_fp rootdelay; /* distance from sync source */ + s_fp rootdelay; /* delay from sync source */ u_fp rootdispersion; /* dispersion from sync source */ u_int32 refid; /* reference ID of sync source */ l_fp reftime; /* system reference time */ @@ -667,7 +670,7 @@ struct info_monitor_1 { u_int32 lasttime; /* last packet from this host */ u_int32 firsttime; /* first time we received a packet */ - u_int32 lastdrop; /* last time we rejected a packet due to client limitation policy */ + u_int32 restr; /* restrict bits (was named lastdrop) */ u_int32 count; /* count of packets received */ u_int32 addr; /* host address V4 style */ u_int32 daddr; /* destination host address */ @@ -688,7 +691,7 @@ struct info_monitor { u_int32 lasttime; /* last packet from this host */ u_int32 firsttime; /* first time we received a packet */ - u_int32 lastdrop; /* last time we rejected a packet due to client limitation policy */ + u_int32 restr; /* restrict bits (was named lastdrop) */ u_int32 count; /* count of packets received */ u_int32 addr; /* host address */ u_short port; /* port number of last reception */ @@ -700,7 +703,7 @@ }; /* - * Structure used for returning monitor data (old format + * Structure used for returning monitor data (old format) */ struct old_info_monitor { u_int32 lasttime; /* last packet from this host */ @@ -923,4 +926,10 @@ associd_t associd; /* association ID */ char hostname[NTP_MAXHOSTNAME]; /* hostname */ }; + +/* + * function declarations + */ +int get_packet_mode(struct recvbuf *rbufp); /* Return packet mode */ + #endif /* NTP_REQUEST_H */ diff -urN src/contrib/ntp/include/ntp_rfc2553.h src.ntp/contrib/ntp/include/ntp_rfc2553.h --- src/contrib/ntp/include/ntp_rfc2553.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/ntp_rfc2553.h 2009-12-09 08:36:36.000000000 +0100 @@ -65,47 +65,46 @@ /* * Compatability shims with the rfc2553 API to simplify ntp. */ -#ifndef _NTP_RFC2553_H_ -#define _NTP_RFC2553_H_ +#ifndef NTP_RFC2553_H +#define NTP_RFC2553_H /* * Ensure that we include the configuration file before we check * for IPV6 */ #include - #include +#include #include "ntp_types.h" -/* - * Don't include any additional IPv6 definitions - * We are defining our own here. - */ -#define ISC_IPV6_H 1 /* * If various macros are not defined we need to define them */ #ifndef AF_INET6 -#define AF_INET6 AF_MAX -#define PF_INET6 AF_INET6 +# define AF_INET6 AF_MAX +# define PF_INET6 AF_INET6 #endif #if !defined(_SS_MAXSIZE) && !defined(_SS_ALIGNSIZE) -#define _SS_MAXSIZE 128 -#define _SS_ALIGNSIZE (sizeof(ntp_uint64_t)) -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR -#define _SS_PAD1SIZE (_SS_ALIGNSIZE - sizeof(u_char) - sizeof(ntp_u_int8_t)) -#define _SS_PAD2SIZE (_SS_MAXSIZE - sizeof(u_char) - sizeof(ntp_u_int8_t) - \ +# define _SS_MAXSIZE 128 +# define _SS_ALIGNSIZE (sizeof(ntp_uint64_t)) +# ifdef ISC_PLATFORM_HAVESALEN +# define _SS_PAD1SIZE (_SS_ALIGNSIZE - sizeof(u_char) - sizeof(ntp_u_int8_t)) +# define _SS_PAD2SIZE (_SS_MAXSIZE - sizeof(u_char) - sizeof(ntp_u_int8_t) - \ _SS_PAD1SIZE - _SS_ALIGNSIZE) -#else -#define _SS_PAD1SIZE (_SS_ALIGNSIZE - sizeof(short)) -#define _SS_PAD2SIZE (_SS_MAXSIZE - sizeof(short) - \ +# else +# define _SS_PAD1SIZE (_SS_ALIGNSIZE - sizeof(short)) +# define _SS_PAD2SIZE (_SS_MAXSIZE - sizeof(short) - \ _SS_PAD1SIZE - _SS_ALIGNSIZE) -#endif /* HAVE_SA_LEN_IN_STRUCT_SOCKADDR */ +# endif /* ISC_PLATFORM_HAVESALEN */ +#endif + +#ifndef INET6_ADDRSTRLEN +# define INET6_ADDRSTRLEN 46 /* max len of IPv6 addr in ascii */ #endif /* @@ -115,7 +114,7 @@ #ifndef HAVE_STRUCT_SOCKADDR_STORAGE struct sockaddr_storage { -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR +#ifdef ISC_PLATFORM_HAVESALEN ntp_u_int8_t ss_len; /* address length */ ntp_u_int8_t ss_family; /* address family */ #else @@ -135,7 +134,7 @@ /* * Flag values for getaddrinfo() */ -#ifndef AI_NUMERICHOST +#ifndef AI_PASSIVE #define AI_PASSIVE 0x00000001 /* get address to use bind() */ #define AI_CANONNAME 0x00000002 /* fill ai_canonname */ #define AI_NUMERICHOST 0x00000004 /* prevent name resolution */ @@ -144,90 +143,16 @@ (AI_PASSIVE | AI_CANONNAME | AI_NUMERICHOST | AI_ADDRCONFIG) #define AI_ADDRCONFIG 0x00000400 /* only if any address is assigned */ -#endif +#endif /* !AI_PASSIVE */ -#ifndef ISC_PLATFORM_HAVEIPV6 -/* - * Definition of some useful macros to handle IP6 addresses - */ -#ifdef ISC_PLATFORM_NEEDIN6ADDRANY -#ifdef SYS_WINNT -#define IN6ADDR_ANY_INIT {{ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 }} -#else -#define IN6ADDR_ANY_INIT \ - {{{ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, \ - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }}} -#endif +#ifndef AI_NUMERICHOST /* such as AIX 4.3 */ +#define AI_NUMERICHOST 0 #endif +#ifndef ISC_PLATFORM_HAVEIPV6 -/* - * IPv6 address - */ #ifdef SYS_WINNT -#define in6_addr in_addr6 -#else - -struct in6_addr { - union { - ntp_u_int8_t __u6_addr8[16]; - ntp_u_int16_t __u6_addr16[8]; - ntp_u_int32_t __u6_addr32[4]; - } __u6_addr; /* 128-bit IP6 address */ -}; - -#define s6_addr __u6_addr.__u6_addr8 -#endif - -#if defined(ISC_PLATFORM_HAVEIPV6) && defined(ISC_PLATFORM_NEEDIN6ADDRANY) -extern const struct in6_addr in6addr_any; -#endif - -#define SIN6_LEN -#ifndef HAVE_SOCKADDR_IN6 -struct sockaddr_in6 { -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - ntp_u_int8_t sin6_len; /* length of this struct(sa_family_t)*/ - ntp_u_int8_t sin6_family; /* AF_INET6 (sa_family_t) */ -#else - short sin6_family; /* AF_INET6 (sa_family_t) */ -#endif - ntp_u_int16_t sin6_port; /* Transport layer port # (in_port_t)*/ - ntp_u_int32_t sin6_flowinfo; /* IP6 flow information */ - struct in6_addr sin6_addr; /* IP6 address */ - ntp_u_int32_t sin6_scope_id; /* scope zone index */ -}; -#endif - -/* - * Unspecified - */ -#ifndef IN6_IS_ADDR_UNSPECIFIED -#define IN6_IS_ADDR_UNSPECIFIED(a) \ - ((*(const ntp_u_int32_t *)(const void *)(&(a)->s6_addr[0]) == 0) && \ - (*(const ntp_u_int32_t *)(const void *)(&(a)->s6_addr[4]) == 0) && \ - (*(const ntp_u_int32_t *)(const void *)(&(a)->s6_addr[8]) == 0) && \ - (*(const ntp_u_int32_t *)(const void *)(&(a)->s6_addr[12]) == 0)) -#endif -/* - * Multicast - */ -#ifndef IN6_IS_ADDR_MULTICAST -#define IN6_IS_ADDR_MULTICAST(a) ((a)->s6_addr[0] == 0xff) -#endif -/* - * Unicast link / site local. - */ -#ifndef IN6_IS_ADDR_LINKLOCAL -#define IN6_IS_ADDR_LINKLOCAL(a) (\ -(*((u_long *)((a)->s6_addr) ) == 0xfe) && \ -((*((u_long *)((a)->s6_addr) + 1) & 0xc0) == 0x80)) -#endif - -#ifndef IN6_IS_ADDR_SITELOCAL -#define IN6_IS_ADDR_SITELOCAL(a) (\ -(*((u_long *)((a)->s6_addr) ) == 0xfe) && \ -((*((u_long *)((a)->s6_addr) + 1) & 0xc0) == 0xc0)) +# define in6_addr in_addr6 #endif struct addrinfo { @@ -260,12 +185,12 @@ #define EAI_MAX 14 -int getaddrinfo P((const char *, const char *, - const struct addrinfo *, struct addrinfo **)); -int getnameinfo P((const struct sockaddr *, u_int, char *, - size_t, char *, size_t, int)); -void freeaddrinfo P((struct addrinfo *)); -char *gai_strerror P((int)); +int getaddrinfo (const char *, const char *, + const struct addrinfo *, struct addrinfo **); +int getnameinfo (const struct sockaddr *, u_int, char *, + size_t, char *, size_t, int); +void freeaddrinfo (struct addrinfo *); +char *gai_strerror (int); /* * Constants for getnameinfo() @@ -287,6 +212,17 @@ #define NI_WITHSCOPEID 0x00000020 #endif -#endif /* ISC_PLATFORM_HAVEIPV6 */ +#endif /* !ISC_PLATFORM_HAVEIPV6 */ + +/* + * Set up some macros to look for IPv6 and IPv6 multicast + */ + +#if defined(ISC_PLATFORM_HAVEIPV6) && defined(WANT_IPV6) +# define INCLUDE_IPV6_SUPPORT +# if defined(IPV6_JOIN_GROUP) && defined(IPV6_LEAVE_GROUP) +# define INCLUDE_IPV6_MULTICAST_SUPPORT +# endif /* IPV6 Multicast Support */ +#endif /* IPv6 Support */ -#endif /* !_NTP_RFC2553_H_ */ +#endif /* !NTP_RFC2553_H */ diff -urN src/contrib/ntp/include/ntp_select.h src.ntp/contrib/ntp/include/ntp_select.h --- src/contrib/ntp/include/ntp_select.h 1999-12-09 14:01:08.000000000 +0100 +++ src.ntp/contrib/ntp/include/ntp_select.h 2009-12-09 08:36:36.000000000 +0100 @@ -1,8 +1,8 @@ /* * Not all machines define FD_SET in sys/types.h */ -#ifndef _ntp_select_h -#define _ntp_select_h +#ifndef NTP_SELECT_H +#define NTP_SELECT_H /* Was: (defined(RS6000)||defined(SYS_PTX))&&!defined(_BSD) */ /* Could say: !defined(FD_SET) && defined(HAVE_SYS_SELECT_H) */ @@ -11,13 +11,13 @@ #include #else #include -extern int select P((int width, fd_set *pReadFds, fd_set *pWriteFds, - fd_set *pExceptFds, struct timeval *pTimeOut)); +extern int select (int width, fd_set *pReadFds, fd_set *pWriteFds, + fd_set *pExceptFds, struct timeval *pTimeOut); #endif #endif -#if !defined(FD_SET) && !defined(SYS_WINNT) +#if !defined(FD_SET) #define NFDBITS 32 #define FD_SETSIZE 32 #define FD_SET(n, p) ((p)->fds_bits[(n)/NFDBITS] |= (1 << ((n) % NFDBITS))) @@ -32,4 +32,9 @@ } fd_set; #endif -#endif /* _ntp_select_h */ +#ifdef SYS_WINNT +/* ports/winnt/libntp/setpriority.c */ +extern void InitSockets(void); +#endif + +#endif /* NTP_SELECT_H */ diff -urN src/contrib/ntp/include/ntp_stdlib.h src.ntp/contrib/ntp/include/ntp_stdlib.h --- src/contrib/ntp/include/ntp_stdlib.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/ntp_stdlib.h 2010-06-03 08:05:26.000000000 +0200 @@ -1,13 +1,21 @@ /* * ntp_stdlib.h - Prototypes for NTP lib. */ +#ifndef NTP_STDLIB_H +#define NTP_STDLIB_H + #include +#ifdef HAVE_SYS_SOCKET_H #include -#include "ntp_rfc2553.h" +#endif +#include "l_stdlib.h" +#include "ntp_rfc2553.h" #include "ntp_types.h" #include "ntp_string.h" -#include "l_stdlib.h" +#include "ntp_net.h" +#include "ntp_syslog.h" + /* * Handle gcc __attribute__ if available. @@ -25,84 +33,92 @@ # endif #endif -#if defined(__STDC__) || defined(HAVE_STDARG_H) -# include -extern void msyslog P((int, const char *, ...)) - __attribute__((__format__(__printf__, 2, 3))); -extern void netsyslog P((int, const char *, ...)) +extern void msyslog (int, const char *, ...) __attribute__((__format__(__printf__, 2, 3))); + +/* + * When building without OpenSSL, use a few macros of theirs to + * minimize source differences in NTP. + */ +#ifndef OPENSSL +#define NID_md5 4 /* from openssl/objects.h */ +/* from openssl/evp.h */ +#define EVP_MAX_MD_SIZE 64 /* longest known is SHA512 */ +#endif + +/* authkeys.c */ +extern void auth_delkeys (void); +extern int auth_havekey (keyid_t); +extern int authdecrypt (keyid_t, u_int32 *, int, int); +extern int authencrypt (keyid_t, u_int32 *, int); +extern int authhavekey (keyid_t); +extern int authistrusted (keyid_t); +extern int authreadkeys (const char *); +extern void authtrust (keyid_t, u_long); +extern int authusekey (keyid_t, int, const u_char *); + +extern u_long calyearstart (u_long); +extern const char *clockname (int); +extern int clocktime (int, int, int, int, int, u_long, u_long *, u_int32 *); +#if !defined(_MSC_VER) || !defined(_DEBUG) +extern void * emalloc (size_t); +extern void * erealloc (void *, size_t); +extern char * estrdup (const char *); #else -# include -extern void msyslog P(()); -extern void netsyslog P(()); -#endif - -extern void auth_delkeys P((void)); -extern int auth_havekey P((keyid_t)); -extern int authdecrypt P((keyid_t, u_int32 *, int, int)); -extern int authencrypt P((keyid_t, u_int32 *, int)); -extern int authhavekey P((keyid_t)); -extern int authistrusted P((keyid_t)); -extern int authreadkeys P((const char *)); -extern void authtrust P((keyid_t, u_long)); -extern int authusekey P((keyid_t, int, const u_char *)); - -extern u_long calyearstart P((u_long)); -extern const char *clockname P((int)); -extern int clocktime P((int, int, int, int, int, u_long, u_long *, u_int32 *)); -#if defined SYS_WINNT && defined DEBUG -# define emalloc(_c) debug_emalloc(_c, __FILE__, __LINE__) -extern void * debug_emalloc P((u_int, char *, int)); -#else -extern void * emalloc P((u_int)); +extern void * debug_erealloc (void *, size_t, const char *, int); +#define emalloc(c) debug_erealloc(NULL, (c), __FILE__, __LINE__) +#define erealloc(p, c) debug_erealloc((p), (c), __FILE__, __LINE__) +extern char * debug_estrdup (const char *, const char *, int); +#define estrdup(s) debug_estrdup((s), __FILE__, __LINE__) #endif -extern int ntp_getopt P((int, char **, const char *)); -extern void init_auth P((void)); -extern void init_lib P((void)); -extern struct savekey *auth_findkey P((keyid_t)); -extern int auth_moremem P((void)); -extern int ymd2yd P((int, int, int)); - -extern int MD5authdecrypt P((u_char *, u_int32 *, int, int)); -extern int MD5authencrypt P((u_char *, u_int32 *, int)); -extern void MD5auth_setkey P((keyid_t, const u_char *, const int)); -extern u_int32 addr2refid P((struct sockaddr_storage *)); - -extern int atoint P((const char *, long *)); -extern int atouint P((const char *, u_long *)); -extern int hextoint P((const char *, u_long *)); -extern char * humandate P((u_long)); -extern char * humanlogtime P((void)); -extern char * inttoa P((long)); -extern char * mfptoa P((u_long, u_long, short)); -extern char * mfptoms P((u_long, u_long, short)); -extern const char * modetoa P((int)); -extern const char * eventstr P((int)); -extern const char * ceventstr P((int)); -extern char * statustoa P((int, int)); -extern const char * sysstatstr P((int)); -extern const char * peerstatstr P((int)); -extern const char * clockstatstr P((int)); -extern struct sockaddr_storage* netof P((struct sockaddr_storage*)); -extern char * numtoa P((u_int32)); -extern char * numtohost P((u_int32)); -extern char * socktoa P((struct sockaddr_storage *)); -extern char * socktohost P((struct sockaddr_storage *)); -extern int octtoint P((const char *, u_long *)); -extern u_long ranp2 P((int)); -extern char * refnumtoa P((struct sockaddr_storage *)); -extern int tsftomsu P((u_long, int)); -extern char * uinttoa P((u_long)); - -extern int decodenetnum P((const char *, struct sockaddr_storage *)); - -extern const char * FindConfig P((const char *)); - -extern void signal_no_reset P((int, RETSIGTYPE (*func)(int))); - -extern void getauthkeys P((const char *)); -extern void auth_agekeys P((void)); -extern void rereadkeys P((void)); +extern int ntp_getopt (int, char **, const char *); +extern void init_auth (void); +extern void init_lib (void); +extern struct savekey *auth_findkey (keyid_t); +extern int auth_moremem (void); +extern int ymd2yd (int, int, int); + +/* a_md5encrypt.c */ +extern int MD5authdecrypt (int, u_char *, u_int32 *, int, int); +extern int MD5authencrypt (int, u_char *, u_int32 *, int); +extern void MD5auth_setkey (keyid_t, int, const u_char *, const int); +extern u_int32 addr2refid (sockaddr_u *); + + +extern int atoint (const char *, long *); +extern int atouint (const char *, u_long *); +extern int hextoint (const char *, u_long *); +extern char * humanlogtime (void); +extern char * inttoa (long); +extern char * mfptoa (u_long, u_long, short); +extern char * mfptoms (u_long, u_long, short); +extern const char * modetoa (int); +extern const char * eventstr (int); +extern const char * ceventstr (int); +extern char * statustoa (int, int); +extern const char * sysstatstr (int); +extern const char * peerstatstr (int); +extern const char * clockstatstr (int); +extern sockaddr_u * netof (sockaddr_u *); +extern char * numtoa (u_int32); +extern char * numtohost (u_int32); +extern char * socktoa (sockaddr_u *); +extern char * socktohost (sockaddr_u *); +extern int octtoint (const char *, u_long *); +extern u_long ranp2 (int); +extern char * refnumtoa (sockaddr_u *); +extern int tsftomsu (u_long, int); +extern char * uinttoa (u_long); + +extern int decodenetnum (const char *, sockaddr_u *); + +extern const char * FindConfig (const char *); + +extern void signal_no_reset (int, RETSIGTYPE (*func)(int)); + +extern void getauthkeys (const char *); +extern void auth_agekeys (void); +extern void rereadkeys (void); /* * Variable declarations for libntp. @@ -129,18 +145,51 @@ */ extern keyid_t cache_keyid; /* key identifier */ extern u_char * cache_key; /* key pointer */ +extern int cache_type; /* key type */ extern u_int cache_keylen; /* key length */ /* getopt.c */ extern char * ntp_optarg; /* global argument pointer */ extern int ntp_optind; /* global argv index */ +/* lib_strbuf.c */ +extern int ipv4_works; +extern int ipv6_works; + /* machines.c */ -extern const char *set_tod_using; +typedef void (*pset_tod_using)(const char *); +extern pset_tod_using set_tod_using; -/* mexit.c */ -#if defined SYS_WINNT || defined SYS_CYGWIN32 -extern HANDLE hServDoneEvent; +/* ssl_init.c */ +#ifdef OPENSSL +extern void ssl_init (void); +extern void ssl_check_version (void); +extern int ssl_init_done; +#define INIT_SSL() \ + do { \ + if (!ssl_init_done) \ + ssl_init(); \ + } while (0) +#else /* !OPENSSL follows */ +#define INIT_SSL() do {} while (0) +#endif +extern int keytype_from_text (const char *, size_t *); +extern const char *keytype_name (int); +extern char * getpass_keytype (int); + + +/* lib/isc/win32/strerror.c + * + * To minimize Windows-specific changes to the rest of the NTP code, + * particularly reference clocks, we hijack calls to strerror() to deal + * with our mixture of error codes from the C runtime (open, write) + * and Windows (sockets, serial ports). This is an ugly hack because + * both use the lowest values differently, but particularly for ntpd, + * it's not a problem. + */ +#ifdef NTP_REDEFINE_STRERROR +#define strerror(e) ntp_strerror(e) +extern char * ntp_strerror (int e); #endif /* systime.c */ @@ -148,3 +197,5 @@ /* version.c */ extern const char *Version; /* version declaration */ + +#endif /* NTP_STDLIB_H */ diff -urN src/contrib/ntp/include/ntp_string.h src.ntp/contrib/ntp/include/ntp_string.h --- src/contrib/ntp/include/ntp_string.h 1999-12-09 14:01:08.000000000 +0100 +++ src.ntp/contrib/ntp/include/ntp_string.h 2009-12-09 08:36:35.000000000 +0100 @@ -36,13 +36,20 @@ #endif /* STDC_HEADERS */ #ifdef NTP_NEED_BOPS -# define memcmp(a,b,c) bcmp(a,b,(int)c) -# define memmove(t,f,c) bcopy(f,t,(int)c) -# define memcpy(t,f,c) bcopy(f,t,(int)c) -# define memset(a,x,c) if (x == 0x00) bzero(a,(int)c); else ntp_memset((char*)a,x,c) -void ntp_memset P((char *, int, int)); +#ifdef HAVE_STRINGS_H +# include /* bcmp, bcopy, bzero */ +#endif +void ntp_memset (char *, int, int); + +#define memcmp(a, b, c) bcmp(a, b, (int)(c)) +#define memmove(t, f, c) bcopy(f, t, (int)(c)) +#define memcpy(t, f, c) bcopy(f, t, (int)(c)) +#define memset(a, x, c) if (0 == (x)) \ + bzero(a, (int)(c)); \ + else \ + ntp_memset((char *)(a), x, c) #endif /* NTP_NEED_BOPS */ #endif /* _ntp_string_h */ diff -urN src/contrib/ntp/include/ntp_syscall.h src.ntp/contrib/ntp/include/ntp_syscall.h --- src/contrib/ntp/include/ntp_syscall.h 2002-11-04 20:35:50.000000000 +0100 +++ src.ntp/contrib/ntp/include/ntp_syscall.h 2009-12-09 08:36:37.000000000 +0100 @@ -20,10 +20,19 @@ # define ntp_gettime(t) syscall(SYS_ntp_gettime, (t)) #else /* !NTP_SYSCALLS_STD */ # ifdef HAVE___ADJTIMEX -extern int __adjtimex P((struct timex *)); +extern int __adjtimex (struct timex *); # define ntp_adjtime(t) __adjtimex((t)) +#ifndef HAVE_STRUCT_NTPTIMEVAL +struct ntptimeval +{ + struct timeval time; /* current time (ro) */ + long int maxerror; /* maximum error (us) (ro) */ + long int esterror; /* estimated error (us) (ro) */ +}; +#endif + static inline int ntp_gettime( struct ntptimeval *ntv diff -urN src/contrib/ntp/include/ntp_types.h src.ntp/contrib/ntp/include/ntp_types.h --- src/contrib/ntp/include/ntp_types.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/ntp_types.h 2009-12-09 08:36:35.000000000 +0100 @@ -4,12 +4,12 @@ * as int and u_int. * For 32 bit systems, define them as long and u_long */ +#ifndef NTP_TYPES_H +#define NTP_TYPES_H + #include #include "ntp_machine.h" -#ifndef _NTP_TYPES_ -#define _NTP_TYPES_ - /* * This is another naming conflict. * On NetBSD for MAC the macro "mac" is defined as 1 @@ -23,15 +23,16 @@ #endif /* - * Set up for prototyping + * used to quiet compiler warnings + */ +#ifndef UNUSED_ARG +#define UNUSED_ARG(arg) ((void)(arg)) +#endif + +/* + * COUNTOF(array) - size of array in elements */ -#ifndef P -#if defined(__STDC__) || defined(HAVE_PROTOTYPES) -#define P(x) x -#else /* not __STDC__ and not HAVE_PROTOTYPES */ -#define P(x) () -#endif /* not __STDC__ and HAVE_PROTOTYPES */ -#endif /* P */ +#define COUNTOF(arr) (sizeof(arr) / sizeof((arr)[0])) /* * VMS DECC (v4.1), {u_char,u_short,u_long} are only in SOCKET.H, @@ -55,15 +56,15 @@ # endif #else /* not sizeof(int) == 4 */ # if (SIZEOF_LONG == 4) -# else /* not sizeof(long) == 4 */ # ifndef int32 # define int32 long # endif # ifndef u_int32 # define u_int32 unsigned long # endif +# else /* not sizeof(long) == 4 */ +# include "Bletch: what's 32 bits on this machine?" # endif /* not sizeof(long) == 4 */ -# include "Bletch: what's 32 bits on this machine?" #endif /* not sizeof(int) == 4 */ typedef u_char ntp_u_int8_t; @@ -76,5 +77,29 @@ typedef u_int32 keyid_t; /* cryptographic key ID */ typedef u_int32 tstamp_t; /* NTP seconds timestamp */ -#endif /* _NTP_TYPES_ */ +/* + * On Unix struct sock_timeval is equivalent to struct timeval. + * On Windows built with 64-bit time_t, sock_timeval.tv_sec is a long + * as required by Windows' socket() interface timeout argument, while + * timeval.tv_sec is time_t for the more common use as a UTC time + * within NTP. + */ +#ifndef SYS_WINNT +#define sock_timeval timeval +#endif + +/* + * On Unix open() works for tty (serial) devices just fine, while on + * Windows refclock serial devices are opened using CreateFile, a lower + * level than the CRT-provided descriptors, because the C runtime lacks + * tty APIs. For refclocks which wish to use open() as well as or + * instead of refclock_open(), tty_open() is equivalent to open() on + * Unix and implemented in the Windows port similarly to + * refclock_open(). + */ +#ifndef SYS_WINNT +#define tty_open(f, a, m) open(f, a, m) +#endif + +#endif /* NTP_TYPES_H */ diff -urN src/contrib/ntp/include/ntp_unixtime.h src.ntp/contrib/ntp/include/ntp_unixtime.h --- src/contrib/ntp/include/ntp_unixtime.h 2004-07-20 17:01:15.000000000 +0200 +++ src.ntp/contrib/ntp/include/ntp_unixtime.h 2009-12-09 08:36:35.000000000 +0100 @@ -136,6 +136,3 @@ #define MSUTOTSF(msu, tsf) \ (tsf) = msutotsfhi[((msu) >> 5) & 0x1f] + msutotsflo[(msu) & 0x1f] - -extern char * tvtoa P((const struct timeval *)); -extern char * utvtoa P((const struct timeval *)); diff -urN src/contrib/ntp/include/ntpd.h src.ntp/contrib/ntp/include/ntpd.h --- src/contrib/ntp/include/ntpd.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/ntpd.h 2010-04-18 10:05:39.000000000 +0200 @@ -11,22 +11,23 @@ #include "ntp_refclock.h" #include "recvbuff.h" - -/* ntp_config.c */ -extern void getconfig P((int, char **)); - /* ntp_config.c */ -extern void ctl_clr_stats P((void)); -extern int ctlclrtrap P((struct sockaddr_storage *, struct interface *, int)); -extern u_short ctlpeerstatus P((struct peer *)); -extern int ctlsettrap P((struct sockaddr_storage *, struct interface *, int, int)); -extern u_short ctlsysstatus P((void)); -extern void init_control P((void)); -extern void process_control P((struct recvbuf *, int)); -extern void report_event P((int, struct peer *)); -extern double fabs P((double)); -extern double sqrt P((double)); +#define TAI_1972 10 /* initial TAI offset (s) */ +extern char *keysdir; /* crypto keys and leaptable directory */ +extern char * saveconfigdir; /* ntpq saveconfig output directory */ + +extern void getconfig (int, char **); +extern void ctl_clr_stats (void); +extern int ctlclrtrap (sockaddr_u *, struct interface *, int); +extern u_short ctlpeerstatus (struct peer *); +extern int ctlsettrap (sockaddr_u *, struct interface *, int, int); +extern u_short ctlsysstatus (void); +extern void init_control (void); +extern void init_logging (char const *, int); +extern void setup_logfile (void); +extern void process_control (struct recvbuf *, int); +extern void report_event (int, struct peer *, const char *); /* ntp_control.c */ /* @@ -52,120 +53,112 @@ #define WO (CAN_WRITE) #define RW (CAN_READ|CAN_WRITE) -extern char * add_var P((struct ctl_var **, u_long, u_short)); -extern void free_varlist P((struct ctl_var *)); -extern void set_var P((struct ctl_var **, const char *, u_long, u_short)); -extern void set_sys_var P((const char *, u_long, u_short)); +extern char * add_var (struct ctl_var **, u_long, u_short); +extern void free_varlist (struct ctl_var *); +extern void set_var (struct ctl_var **, const char *, u_long, u_short); +extern void set_sys_var (const char *, u_long, u_short); /* ntp_intres.c */ -extern void ntp_res_name P((struct sockaddr_storage, u_short)); -extern void ntp_res_recv P((void)); -extern void ntp_intres P((void)); +extern void ntp_res_name (sockaddr_u, u_short); +extern void ntp_res_recv (void); +extern void ntp_intres (void); +#ifdef SYS_WINNT +extern unsigned WINAPI ntp_intres_thread (void *); +#endif /* ntp_io.c */ typedef struct interface_info { - struct interface *interface; - u_char action; + struct interface * interface; + u_char action; } interface_info_t; -typedef void (*interface_receiver_t)(void *, interface_info_t *); +typedef void (*interface_receiver_t) (void *, interface_info_t *); -extern volatile int disable_dynamic_updates; +extern int disable_dynamic_updates; -extern void interface_enumerate P((interface_receiver_t, void *)); -extern struct interface *findinterface P((struct sockaddr_storage *)); -extern struct interface *findbcastinter P((struct sockaddr_storage *)); -extern void enable_broadcast P((struct interface *, struct sockaddr_storage *)); -extern void enable_multicast_if P((struct interface *, struct sockaddr_storage *)); -extern void interface_dump P((struct interface *)); - -extern void interface_update P((interface_receiver_t, void *)); -extern void init_io P((void)); -extern void input_handler P((l_fp *)); -extern void io_clr_stats P((void)); -extern void io_setbclient P((void)); -extern void io_unsetbclient P((void)); -extern void io_multicast_add P((struct sockaddr_storage)); -extern void io_multicast_del P((struct sockaddr_storage)); -extern void kill_asyncio P((int)); -extern void sendpkt P((struct sockaddr_storage *, struct interface *, int, struct pkt *, int)); +extern void interface_enumerate (interface_receiver_t, void *); +extern struct interface *findinterface (sockaddr_u *); +extern struct interface *findbcastinter(sockaddr_u *); +extern void enable_broadcast (struct interface *, sockaddr_u *); +extern void enable_multicast_if (struct interface *, sockaddr_u *); +extern void interface_update (interface_receiver_t, void *); + +extern void init_io (void); +extern void io_open_sockets (void); +extern void input_handler (l_fp *); +extern void io_clr_stats (void); +extern void io_setbclient (void); +extern void io_unsetbclient (void); +extern void io_multicast_add(sockaddr_u *); +extern void io_multicast_del(sockaddr_u *); +extern void sendpkt (sockaddr_u *, struct interface *, int, struct pkt *, int); +#ifndef SYS_WINNT +extern void kill_asyncio (int); +#endif #ifdef DEBUG -extern void collect_timing P((struct recvbuf *, const char *, int, l_fp *)); +extern void collect_timing (struct recvbuf *, const char *, int, l_fp *); #endif #ifdef HAVE_SIGNALED_IO -extern void wait_for_signal P((void)); -extern void unblock_io_and_alarm P((void)); -extern void block_io_and_alarm P((void)); -#define UNBLOCK_IO_AND_ALARM() unblock_io_and_alarm() -#define BLOCK_IO_AND_ALARM() block_io_and_alarm() +extern void wait_for_signal (void); +extern void unblock_io_and_alarm (void); +extern void block_io_and_alarm (void); +#define UNBLOCK_IO_AND_ALARM() unblock_io_and_alarm() +#define BLOCK_IO_AND_ALARM() block_io_and_alarm() #else #define UNBLOCK_IO_AND_ALARM() #define BLOCK_IO_AND_ALARM() #endif -/* ntp_leap.c */ -extern void init_leap P((void)); -extern void leap_process P((void)); -extern int leap_setleap P((int, int)); -/* - * there seems to be a bug in the IRIX 4 compiler which prevents - * u_char from beeing used in prototyped functions. - * This is also true AIX compiler. - * So give up and define it to be int. WLJ - */ -extern int leap_actual P((int)); - /* ntp_loopfilter.c */ -extern void init_loopfilter P((void)); -extern int local_clock P((struct peer *, double)); -extern void adj_host_clock P((void)); -extern void loop_config P((int, double)); -extern void huffpuff P((void)); +extern void init_loopfilter(void); +extern int local_clock(struct peer *, double); +extern void adj_host_clock(void); +extern void loop_config(int, double); +extern void huffpuff(void); extern u_long sys_clocktime; -extern u_long sys_tai; +extern u_int sys_tai; /* ntp_monitor.c */ -extern void init_mon P((void)); -extern void mon_start P((int)); -extern void mon_stop P((int)); -extern int ntp_monitor P((struct recvbuf *)); -extern void ntp_monclearinterface P((struct interface *interface)); +extern void init_mon (void); +extern void mon_start (int); +extern void mon_stop (int); +extern int ntp_monitor (struct recvbuf *, int); +extern void ntp_monclearinterface (struct interface *interface); /* ntp_peer.c */ -extern void init_peer P((void)); -extern struct peer *findexistingpeer P((struct sockaddr_storage *, struct peer *, int)); -extern struct peer *findpeer P((struct sockaddr_storage *, struct interface *, int, int *)); -extern struct peer *findpeerbyassoc P((u_int)); -extern void set_peerdstadr P((struct peer *peer, struct interface *interface)); -extern struct peer *newpeer P((struct sockaddr_storage *, struct interface *, int, int, int, int, u_int, u_char, int, keyid_t)); -extern void peer_all_reset P((void)); -extern void peer_clr_stats P((void)); -extern struct peer *peer_config P((struct sockaddr_storage *, struct interface *, int, int, int, int, u_int, int, keyid_t, u_char *)); -extern void peer_reset P((struct peer *)); -extern int peer_unconfig P((struct sockaddr_storage *, struct interface *, int)); -extern void refresh_all_peerinterfaces P((void)); -extern void unpeer P((struct peer *)); -extern void clear_all P((void)); - -#ifdef OPENSSL -extern void expire_all P((void)); -#endif /* OPENSSL */ -extern struct peer *findmanycastpeer P((struct recvbuf *)); +extern void init_peer (void); +extern struct peer *findexistingpeer (sockaddr_u *, struct peer *, int); +extern struct peer *findpeer (sockaddr_u *, struct interface *, int, int *); +extern struct peer *findpeerbyassoc (u_int); +extern void set_peerdstadr (struct peer *peer, struct interface *interface); +extern struct peer *newpeer (sockaddr_u *, struct interface *, int, int, int, int, u_int, u_char, int, keyid_t); +extern void peer_all_reset (void); +extern void peer_clr_stats (void); +extern struct peer *peer_config (sockaddr_u *, struct interface *, int, int, int, int, u_int, int, keyid_t, u_char *); +extern void peer_reset (struct peer *); +extern void refresh_all_peerinterfaces (void); +extern void unpeer (struct peer *); +extern void clear_all (void); +extern int score_all (struct peer *); +extern struct peer *findmanycastpeer (struct recvbuf *); /* ntp_crypto.c */ #ifdef OPENSSL -extern int crypto_recv P((struct peer *, struct recvbuf *)); -extern int crypto_xmit P((struct pkt *, struct sockaddr_storage *, int, struct exten *, keyid_t)); -extern keyid_t session_key P((struct sockaddr_storage *, struct sockaddr_storage *, keyid_t, keyid_t, u_long)); -extern int make_keylist P((struct peer *, struct interface *)); -extern void key_expire P((struct peer *)); -extern void crypto_update P((void)); -extern void crypto_config P((int, char *)); -extern void crypto_setup P((void)); -extern u_int crypto_ident P((struct peer *)); -extern struct exten *crypto_args P((struct peer *, u_int, char *)); -extern int crypto_public P((struct peer *, u_char *, u_int)); -extern void value_free P((struct value *)); +extern int crypto_recv (struct peer *, struct recvbuf *); +extern int crypto_xmit (struct peer *, struct pkt *, + struct recvbuf *, int, + struct exten *, keyid_t); +extern keyid_t session_key (sockaddr_u *, sockaddr_u *, keyid_t, + keyid_t, u_long); +extern int make_keylist (struct peer *, struct interface *); +extern void key_expire (struct peer *); +extern void crypto_update (void); +extern void crypto_config (int, char *); +extern void crypto_setup (void); +extern u_int crypto_ident (struct peer *); +extern struct exten *crypto_args (struct peer *, u_int, associd_t, char *); +extern int crypto_public (struct peer *, u_char *, u_int); +extern void value_free (struct value *); extern char *iffpar_file; extern EVP_PKEY *iffpar_pkey; extern char *gqpar_file; @@ -176,13 +169,20 @@ #endif /* OPENSSL */ /* ntp_proto.c */ -extern void transmit P((struct peer *)); -extern void receive P((struct recvbuf *)); -extern void peer_crypto_clear P((struct peer *peer)); -extern void peer_clear P((struct peer *, char *)); -extern void process_packet P((struct peer *, struct pkt *)); -extern void clock_select P((void)); -extern void kod_proto P((void)); +extern void transmit (struct peer *); +extern void receive (struct recvbuf *); +extern void peer_clear (struct peer *, char *); +extern void process_packet (struct peer *, struct pkt *, u_int); +extern void clock_select (void); + +extern int leap_tai; /* TAI at next leap */ +extern u_long leap_sec; /* next scheduled leap from file */ +extern u_long leap_peers; /* next scheduled leap from peers */ +extern u_long leapsec; /* seconds to next leap */ +extern u_long leap_expire; /* leap information expiration */ +extern int sys_orphan; +extern double sys_mindisp; +extern double sys_maxdist; /* * there seems to be a bug in the IRIX 4 compiler which prevents @@ -190,65 +190,71 @@ * This is also true AIX compiler. * So give up and define it to be int. WLJ */ -extern void poll_update P((struct peer *, int)); +extern void poll_update (struct peer *, int); -extern void clear P((struct peer *)); -extern void clock_filter P((struct peer *, double, double, double)); -extern void init_proto P((void)); -extern void proto_config P((int, u_long, double, struct sockaddr_storage*)); -extern void proto_clr_stats P((void)); +extern void clear (struct peer *); +extern void clock_filter (struct peer *, double, double, double); +extern void init_proto (void); +extern void proto_config (int, u_long, double, sockaddr_u *); +extern void proto_clr_stats (void); #ifdef REFCLOCK /* ntp_refclock.c */ -extern int refclock_newpeer P((struct peer *)); -extern void refclock_unpeer P((struct peer *)); -extern void refclock_receive P((struct peer *)); -extern void refclock_transmit P((struct peer *)); -extern void init_refclock P((void)); +extern int refclock_newpeer (struct peer *); +extern void refclock_unpeer (struct peer *); +extern void refclock_receive (struct peer *); +extern void refclock_transmit (struct peer *); +extern void init_refclock (void); #endif /* REFCLOCK */ /* ntp_request.c */ -extern void init_request P((void)); -extern void process_private P((struct recvbuf *, int)); +extern void init_request (void); +extern void process_private (struct recvbuf *, int); /* ntp_restrict.c */ -extern void init_restrict P((void)); -extern int restrictions P((struct sockaddr_storage *, int)); -extern void hack_restrict P((int, struct sockaddr_storage *, struct sockaddr_storage *, int, int)); +extern void init_restrict (void); +extern u_short restrictions (sockaddr_u *); +extern void hack_restrict (int, sockaddr_u *, sockaddr_u *, u_short, u_short); /* ntp_timer.c */ -extern void init_timer P((void)); -extern void reinit_timer P((void)); -extern void timer P((void)); -extern void timer_clr_stats P((void)); -extern void timer_interfacetimeout P((u_long)); +extern void init_timer (void); +extern void reinit_timer (void); +extern void timer (void); +extern void timer_clr_stats (void); +extern void timer_interfacetimeout (u_long); extern volatile int interface_interval; - #ifdef OPENSSL -extern char *sys_hostname; -extern l_fp sys_revoketime; +extern char *sys_hostname; /* host name */ +extern char *sys_groupname; /* group name */ +extern char *group_name; /* group name */ +extern u_long sys_revoke; /* keys revoke timeout */ +extern u_long sys_automax; /* session key timeout */ #endif /* OPENSSL */ /* ntp_util.c */ -extern void init_util P((void)); -extern void write_stats P((void)); -extern void stats_config P((int, const char *)); -extern void record_peer_stats P((struct sockaddr_storage *, int, double, double, double, double)); -extern void record_loop_stats P((double, double, double, double, int)); -extern void record_clock_stats P((struct sockaddr_storage *, const char *)); -extern void record_raw_stats P((struct sockaddr_storage *, struct sockaddr_storage *, l_fp *, l_fp *, l_fp *, l_fp *)); -extern void record_sys_stats P((void)); -extern void record_crypto_stats P((struct sockaddr_storage *, const char *)); +extern void init_util (void); +extern void write_stats (void); +extern void stats_config (int, const char *); +extern void record_peer_stats (sockaddr_u *, int, double, double, double, double); +extern void record_proto_stats (char *); +extern void record_loop_stats (double, double, double, double, int); +extern void record_clock_stats (sockaddr_u *, const char *); +extern void record_raw_stats (sockaddr_u *, sockaddr_u *, l_fp *, l_fp *, l_fp *, l_fp *); +extern u_long leap_month(u_long); +extern void record_crypto_stats (sockaddr_u *, const char *); #ifdef DEBUG -extern void record_timing_stats P((const char *)); +extern void record_timing_stats (const char *); #endif -extern int sock_hash P((struct sockaddr_storage *)); +extern u_short sock_hash (sockaddr_u *); +extern char * fstostr(time_t); /* NTP timescale seconds */ extern double old_drift; +extern int drift_file_sw; +extern double wander_threshold; +extern double wander_resid; /* * Variable declarations for ntpd. */ - /* ntp_config.c */ extern char const * progname; extern char *sys_phone[]; /* ACTS phone numbers */ @@ -256,6 +262,20 @@ extern int config_priority_override; extern int config_priority; #endif +extern char *ntp_signd_socket; +extern struct config_tree *cfg_tree_history; + +#ifdef BC_LIST_FRAMEWORK_NOT_YET_USED +/* + * backwards compatibility flags + */ +typedef struct bc_entry_tag { + int token; + int enabled; +} bc_entry; + +extern bc_entry bc_list[]; +#endif /* ntp_control.c */ extern int num_ctl_traps; @@ -282,6 +302,8 @@ /* ntp_intres.c */ extern keyid_t req_keyid; /* request keyid */ +extern int req_keytype; /* OpenSSL NID such as NID_md5 */ +extern size_t req_hashlen; /* digest size for req_keytype */ extern char * req_file; /* name of the file with configuration info */ #ifdef SYS_WINNT extern HANDLE ResolverEventHandle; @@ -322,7 +344,7 @@ extern double clock_panic; /* max offset before panic (s) */ extern double clock_phi; /* dispersion rate (s/s) */ extern double clock_minstep; /* step timeout (s) */ -extern u_long pps_control; /* last pps sample time */ +extern double clock_codec; /* codec frequency */ #ifdef KERNEL_PLL extern int pll_status; /* status bits for kernel pll */ #endif /* KERNEL_PLL */ @@ -348,8 +370,9 @@ extern int tc_counter; /* poll-adjust counter */ extern u_long last_time; /* time of last clock update (s) */ extern double last_offset; /* last clock offset (s) */ -extern double allan_xpt; /* Allan intercept (s) */ +extern u_char allan_xpt; /* Allan intercept (log2 s) */ extern double clock_jitter; /* clock jitter (s) */ +extern double sys_offset; /* system offset (s) */ extern double sys_jitter; /* system jitter (s) */ /* ntp_monitor.c */ @@ -381,16 +404,13 @@ * specification. */ extern u_char sys_leap; /* system leap indicator */ -extern u_char sys_stratum; /* stratum of system */ +extern u_char sys_stratum; /* system stratum */ extern s_char sys_precision; /* local clock precision */ -extern double sys_rootdelay; /* distance to current sync source */ -extern double sys_rootdispersion; /* dispersion of system clock */ -extern u_int32 sys_refid; /* reference source for local clock */ -extern l_fp sys_reftime; /* time we were last updated */ -extern struct peer *sys_peer; /* our current peer */ -extern struct peer *sys_pps; /* our current PPS peer */ -extern struct peer *sys_prefer; /* our cherished peer */ -extern u_long sys_automax; /* maximum session key lifetime */ +extern double sys_rootdelay; /* roundtrip delay to primary source */ +extern double sys_rootdisp; /* dispersion to primary source */ +extern u_int32 sys_refid; /* reference id */ +extern l_fp sys_reftime; /* last update time */ +extern struct peer *sys_peer; /* current peer */ /* * Nonspecified system state variables. @@ -405,23 +425,24 @@ extern int sys_minsane; /* minimum candidates */ extern int sys_floor; /* cluster stratum floor */ extern int sys_ceiling; /* cluster stratum ceiling */ -extern u_char sys_ttl[]; /* ttl mapping vector */ +extern u_char sys_ttl[MAX_TTL]; /* ttl mapping vector */ extern int sys_ttlmax; /* max ttl mapping vector index */ -extern int leap_next; /* leap consensus */ /* * Statistics counters */ -extern u_long sys_stattime; /* time when we started recording */ +extern u_long sys_stattime; /* time since reset */ +extern u_long sys_received; /* packets received */ +extern u_long sys_processed; /* packets for this host */ extern u_long sys_restricted; /* restricted packets */ -extern u_long sys_oldversionpkt; /* old version packets */ -extern u_long sys_newversionpkt; /* new version packets */ -extern u_long sys_unknownversion; /* don't know version packets */ +extern u_long sys_newversion; /* current version */ +extern u_long sys_oldversion; /* old version */ +extern u_long sys_restricted; /* access denied */ extern u_long sys_badlength; /* bad length or format */ -extern u_long sys_processed; /* packets processed */ extern u_long sys_badauth; /* bad authentication */ -extern u_long sys_limitrejected; /* rate limit exceeded */ -extern u_long sys_received; /* packets received */ +extern u_long sys_declined; /* declined */ +extern u_long sys_limitrejected; /* rate exceeded */ +extern u_long sys_kodsent; /* KoD sent */ /* ntp_refclock.c */ #ifdef REFCLOCK @@ -434,15 +455,14 @@ extern keyid_t info_auth_keyid; /* keyid used to authenticate requests */ /* ntp_restrict.c */ -extern struct restrictlist *restrictlist; /* the ipv4 restriction list */ -extern struct restrictlist6 *restrictlist6; /* the ipv6 restriction list */ -extern u_long res_min_interval; -extern u_long res_avg_interval; -extern u_long mon_age; /* monitor preempt age */ +extern restrict_u * restrictlist4; /* IPv4 restriction list */ +extern restrict_u * restrictlist6; /* IPv6 restriction list */ +extern int ntp_minpkt; +extern int ntp_minpoll; +extern int mon_age; /* monitor preempt age */ /* ntp_timer.c */ extern volatile int alarm_flag; /* alarm flag */ -extern u_char sys_revoke; /* keys revoke timeout (log2 s) */ extern volatile u_long alarm_overflow; extern u_long current_time; /* current time (s) */ extern u_long timer_timereset; @@ -462,7 +482,7 @@ extern int droproot; /* flag: try to drop root privileges after startup */ extern char *user; /* user to switch to */ extern char *group; /* group to switch to */ -extern char *chrootdir; /* directory to chroot to */ +extern const char *chrootdir; /* directory to chroot to */ #endif /* refclock_conf.c */ @@ -470,3 +490,15 @@ extern struct refclock *refclock_conf[]; /* refclock configuration table */ extern u_char num_refclock_conf; #endif + +/* ntp_signd.c */ +#ifdef HAVE_NTP_SIGND +extern void +send_via_ntp_signd( + struct recvbuf *rbufp, /* receive packet pointer */ + int xmode, + keyid_t xkeyid, + int flags, + struct pkt *xpkt + ); +#endif diff -urN src/contrib/ntp/include/ntpsim.h src.ntp/contrib/ntp/include/ntpsim.h --- src/contrib/ntp/include/ntpsim.h 2004-07-20 17:01:16.000000000 +0200 +++ src.ntp/contrib/ntp/include/ntpsim.h 2010-01-24 11:01:45.000000000 +0100 @@ -1,13 +1,21 @@ -/* - * ntpsim.h - Prototypes for ntpsim +/* ntpsim.h + * + * The header file for the ntp discrete event simulator. + * + * Written By: Sachin Kamboj + * University of Delaware + * Newark, DE 19711 + * Copyright (c) 2006 */ -#ifndef __ntpsim_h -#define __ntpsim_h +#ifndef NTPSIM_H +#define NTPSIM_H #include #include +#ifdef HAVE_SYS_SOCKET_H #include +#endif #include #include "ntp_syslog.h" #include "ntp_fp.h" @@ -19,75 +27,117 @@ #include "ntp_io.h" #include "ntp_stdlib.h" -#define PI 3.1415926535 +#include "ntp_data_structures.h" + +/* CONSTANTS */ -/* - * ntpsim declarations +#ifdef PI +# undef PI +#endif +#define PI 3.1415926535 /* The world's most famous constant */ +#define SIM_TIME 86400 /* end simulation time */ +#define NET_DLY .001 /* network delay */ +#define PROC_DLY .001 /* processing delay */ +#define BEEP_DLY 3600 /* beep interval (s) */ + + +/* Discrete Event Queue + * -------------------- + * The NTP simulator is a discrete event simulator. + * + * Central to this simulator is an event queue which is a priority queue + * in which the "priority" is given by the time of arrival of the event. + * + * A discrete set of events can happen and are stored in the queue to arrive + * at a particular time. */ + +/* Possible Discrete Events */ + typedef enum { - BEEP, CLOCK, TIMER, PACKET + BEEP, /* Event to record simulator stats */ + CLOCK, /* Event to advance the clock to the specified time */ + TIMER, /* Event that designates a timer interrupt. */ + PACKET /* Event that designates arrival of a packet */ } funcTkn; + +/* Event information */ + typedef struct { - double time; - union { - struct pkt evnt_pkt; - struct recvbuf evnt_buf; - } buffer; + double time; /* Time at which event occurred */ + funcTkn function; /* Type of event that occured */ + union { + struct pkt evnt_pkt; + struct recvbuf evnt_buf; + } buffer; /* Other data associated with the event */ #define ntp_pkt buffer.evnt_pkt #define rcv_buf buffer.evnt_buf - funcTkn function; } Event; -typedef struct List { - Event event; - struct List *next; -} *Queue; - -typedef struct nde { - double time; /* simulation time */ - double sim_time; /* end simulation time */ - double ntp_time; /* client disciplined time */ - double adj; /* remaining time correction */ - double slew; /* correction slew rate */ - - double clk_time; /* server time */ - double ferr; /* frequency errort */ - double fnse; /* random walk noise */ - double ndly; /* network delay */ - double snse; /* phase noise */ - double pdly; /* processing delay */ - double bdly; /* beep interval */ - - double last_time; /* last clock read time */ - Queue events; /* Node Event Queue */ - struct recvbuf *rbuflist; /* Node Receive Buffer */ -} Node; -/* - * Function prototypes - */ -int ntpsim P((int argc, char *argv[])); -Event event P((double, funcTkn)); -Queue queue P((Event, Queue )); -Node node P((void)); -void push P((Event, Queue *)); -Event pop P((Queue *)); -void ndbeep P((Node *, Event)); -void ndeclk P((Node *, Event)); -void ntptmr P((Node *, Event)); -void netpkt P((Node *, Event)); -int srvr_rply P((Node *, struct sockaddr_storage *, - struct interface *, struct pkt *)); -double gauss P((double, double)); -double poisson P((double, double)); -int node_clock P((Node *, double)); -void abortsim P((char *)); +/* Server Script Information */ -/* - * The global Node - */ -Node ntp_node; +typedef struct { + double duration; + double freq_offset; + double wander; + double jitter; + double prop_delay; + double proc_delay; +} script_info; -#endif + +/* Server Structures */ + +typedef struct { + double server_time; /* Server time */ + sockaddr_u *addr; /* Server Address */ + queue *script; /* Server Script */ + script_info *curr_script; /* Current Script */ +} server_info; + + +/* Simulation control information */ + +typedef struct Sim_Info { + double sim_time; /* Time in the simulation */ + double end_time; /* Time at which simulation needs to be ended */ + double beep_delay; /* Delay between simulation "beeps" at which + simulation stats are recorded. */ + int num_of_servers; /* Number of servers in the simulation */ + server_info *servers; /* Pointer to array of servers */ +} sim_info; + + +/* Local Clock (Client) Variables */ + +typedef struct Local_Clock_Info { + double local_time; /* Client disciplined time */ + double adj; /* Remaining time correction */ + double slew; /* Correction Slew Rate */ + double last_read_time; /* Last time the clock was read */ +} local_clock_info; + +extern local_clock_info simclock; /* Local Clock Variables */ +extern sim_info simulation; /* Simulation Control Variables */ + +/* Function Prototypes */ + +int ntpsim (int argc, char *argv[]); +Event *event (double t, funcTkn f); +void sim_event_timer (Event *e); +int simulate_server (sockaddr_u *serv_addr, + struct interface *inter, + struct pkt *rpkt); +void sim_update_clocks (Event *e); +void sim_event_recv_packet (Event *e); +void sim_event_beep (Event *e); +void abortsim (char *errmsg); +double gauss (double, double); +double poisson (double, double); +int yyparse (void); +void create_server_associations (void); + +#endif /* NTPSIM_H */ diff -urN src/contrib/ntp/include/parse.h src.ntp/contrib/ntp/include/parse.h --- src/contrib/ntp/include/parse.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/parse.h 2009-12-09 08:36:37.000000000 +0100 @@ -58,11 +58,11 @@ #endif #ifdef PARSEKERNEL #ifndef _KERNEL -extern caddr_t kmem_alloc P((unsigned int)); -extern caddr_t kmem_free P((caddr_t, unsigned int)); -extern unsigned int splx P((unsigned int)); -extern unsigned int splhigh P((void)); -extern unsigned int splclock P((void)); +extern caddr_t kmem_alloc (unsigned int); +extern caddr_t kmem_free (caddr_t, unsigned int); +extern unsigned int splx (unsigned int); +extern unsigned int splhigh (void); +extern unsigned int splclock (void); #define MALLOC(_X_) (char *)kmem_alloc(_X_) #define FREE(_X_, _Y_) kmem_free((caddr_t)_X_, _Y_) #else @@ -340,12 +340,12 @@ struct clockformat { /* special input protocol - implies fixed format */ - u_long (*input) P((parse_t *, unsigned int, timestamp_t *)); + u_long (*input) (parse_t *, unsigned int, timestamp_t *); /* conversion routine */ - u_long (*convert) P((unsigned char *, int, struct format *, clocktime_t *, void *)); + u_long (*convert) (unsigned char *, int, struct format *, clocktime_t *, void *); /* routine for handling RS232 sync events (time stamps) */ /* PPS input routine */ - u_long (*syncpps) P((parse_t *, int, timestamp_t *)); + u_long (*syncpps) (parse_t *, int, timestamp_t *); /* time code synthesizer */ void *data; /* local parameters */ @@ -359,30 +359,30 @@ /* * parse interface */ -extern int parse_ioinit P((parse_t *)); -extern void parse_ioend P((parse_t *)); -extern int parse_ioread P((parse_t *, unsigned int, timestamp_t *)); -extern int parse_iopps P((parse_t *, int, timestamp_t *)); -extern void parse_iodone P((parse_t *)); -extern int parse_timecode P((parsectl_t *, parse_t *)); -extern int parse_getfmt P((parsectl_t *, parse_t *)); -extern int parse_setfmt P((parsectl_t *, parse_t *)); -extern int parse_setcs P((parsectl_t *, parse_t *)); - -extern unsigned int parse_restart P((parse_t *, unsigned int)); -extern unsigned int parse_addchar P((parse_t *, unsigned int)); -extern unsigned int parse_end P((parse_t *)); - -extern int Strok P((const unsigned char *, const unsigned char *)); -extern int Stoi P((const unsigned char *, long *, int)); - -extern time_t parse_to_unixtime P((clocktime_t *, u_long *)); -extern u_long updatetimeinfo P((parse_t *, u_long)); -extern void syn_simple P((parse_t *, timestamp_t *, struct format *, u_long)); -extern u_long pps_simple P((parse_t *, int, timestamp_t *)); -extern u_long pps_one P((parse_t *, int, timestamp_t *)); -extern u_long pps_zero P((parse_t *, int, timestamp_t *)); -extern int parse_timedout P((parse_t *, timestamp_t *, struct timeval *)); +extern int parse_ioinit (parse_t *); +extern void parse_ioend (parse_t *); +extern int parse_ioread (parse_t *, unsigned int, timestamp_t *); +extern int parse_iopps (parse_t *, int, timestamp_t *); +extern void parse_iodone (parse_t *); +extern int parse_timecode (parsectl_t *, parse_t *); +extern int parse_getfmt (parsectl_t *, parse_t *); +extern int parse_setfmt (parsectl_t *, parse_t *); +extern int parse_setcs (parsectl_t *, parse_t *); + +extern unsigned int parse_restart (parse_t *, unsigned int); +extern unsigned int parse_addchar (parse_t *, unsigned int); +extern unsigned int parse_end (parse_t *); + +extern int Strok (const unsigned char *, const unsigned char *); +extern int Stoi (const unsigned char *, long *, int); + +extern time_t parse_to_unixtime (clocktime_t *, u_long *); +extern u_long updatetimeinfo (parse_t *, u_long); +extern void syn_simple (parse_t *, timestamp_t *, struct format *, u_long); +extern u_long pps_simple (parse_t *, int, timestamp_t *); +extern u_long pps_one (parse_t *, int, timestamp_t *); +extern u_long pps_zero (parse_t *, int, timestamp_t *); +extern int parse_timedout (parse_t *, timestamp_t *, struct timeval *); #endif diff -urN src/contrib/ntp/include/recvbuff.h src.ntp/contrib/ntp/include/recvbuff.h --- src/contrib/ntp/include/recvbuff.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/recvbuff.h 2009-12-09 08:36:37.000000000 +0100 @@ -1,5 +1,5 @@ -#if !defined __recvbuff_h -#define __recvbuff_h +#ifndef RECVBUFF_H +#define RECVBUFF_H #ifdef HAVE_CONFIG_H # include @@ -7,9 +7,8 @@ #include "ntp.h" #include "ntp_fp.h" -#include "ntp_types.h" +#include "ntp_lists.h" -#include #include /* @@ -29,7 +28,7 @@ /* Return the event which is set when items are added to the full list */ -extern HANDLE get_recv_buff_event P((void)); +extern HANDLE get_recv_buff_event (void); #else # define RECV_BLOCK_IO() # define RECV_UNBLOCK_IO() @@ -52,41 +51,40 @@ typedef struct recvbuf recvbuf_t; struct recvbuf { - ISC_LINK(recvbuf_t) link; + ISC_LINK(recvbuf_t) link; /* next in list */ union { - struct sockaddr_storage X_recv_srcadr; + sockaddr_u X_recv_srcadr; caddr_t X_recv_srcclock; struct peer *X_recv_peer; } X_from_where; #define recv_srcadr X_from_where.X_recv_srcadr #define recv_srcclock X_from_where.X_recv_srcclock #define recv_peer X_from_where.X_recv_peer -#if defined HAVE_IO_COMPLETION_PORT - WSABUF wsabuff; +#ifndef HAVE_IO_COMPLETION_PORT + sockaddr_u srcadr; /* where packet came from */ #else - struct sockaddr_storage srcadr; /* where packet came from */ + int recv_srcadr_len; /* filled in on completion */ #endif - int src_addr_len; /* source address length */ struct interface *dstadr; /* interface datagram arrived thru */ SOCKET fd; /* fd on which it was received */ int msg_flags; /* Flags received about the packet */ l_fp recv_time; /* time of arrival */ - void (*receiver) P((struct recvbuf *)); /* routine to receive buffer */ + void (*receiver) (struct recvbuf *); /* routine to receive buffer */ int recv_length; /* number of octets received */ union { struct pkt X_recv_pkt; u_char X_recv_buffer[RX_BUFF_SIZE]; } recv_space; - int used; #define recv_pkt recv_space.X_recv_pkt #define recv_buffer recv_space.X_recv_buffer + int used; /* reference count */ }; -extern void init_recvbuff P((int)); +extern void init_recvbuff (int); /* freerecvbuf - make a single recvbuf available for reuse */ -extern void freerecvbuf P((struct recvbuf *)); +extern void freerecvbuf (struct recvbuf *); /* Get a free buffer (typically used so an async * read can directly place data into the buffer @@ -94,30 +92,29 @@ * The buffer is removed from the free list. Make sure * you put it back with freerecvbuf() or */ -extern struct recvbuf *get_free_recv_buffer P((void)); /* signal safe - no malloc */ -extern struct recvbuf *get_free_recv_buffer_alloc P((void)); /* signal unsafe - may malloc */ +extern struct recvbuf *get_free_recv_buffer (void); /* signal safe - no malloc */ +extern struct recvbuf *get_free_recv_buffer_alloc (void); /* signal unsafe - may malloc */ /* Add a buffer to the full list */ -extern void add_full_recv_buffer P((struct recvbuf *)); +extern void add_full_recv_buffer (struct recvbuf *); -/*extern void process_recv_buffers P((void)); */ +/*extern void process_recv_buffers (void); */ /* number of recvbufs on freelist */ -extern u_long free_recvbuffs P((void)); -extern u_long full_recvbuffs P((void)); -extern u_long total_recvbuffs P((void)); -extern u_long lowater_additions P((void)); +extern u_long free_recvbuffs (void); +extern u_long full_recvbuffs (void); +extern u_long total_recvbuffs (void); +extern u_long lowater_additions (void); /* Returns the next buffer in the full list. * */ -extern struct recvbuf *get_full_recv_buffer P((void)); +extern struct recvbuf *get_full_recv_buffer (void); /* * Checks to see if there are buffers to process */ -extern isc_boolean_t has_full_recv_buffer P((void)); - -#endif /* defined __recvbuff_h */ +extern isc_boolean_t has_full_recv_buffer (void); +#endif /* RECVBUFF_H */ diff -urN src/contrib/ntp/include/refclock_atom.h src.ntp/contrib/ntp/include/refclock_atom.h --- src/contrib/ntp/include/refclock_atom.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/include/refclock_atom.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,15 @@ +/* + * Definitions for the atom driver and its friends + */ +#define NANOSECOND 1000000000 /* one second (ns) */ +#define RANGEGATE 500000 /* range gate (ns) */ + +struct refclock_atom { + pps_handle_t handle; + pps_params_t pps_params; + struct timespec ts; +}; + +extern int refclock_ppsapi(int, struct refclock_atom *); +extern int refclock_params(int, struct refclock_atom *); +extern int refclock_pps(struct peer *, struct refclock_atom *, int); diff -urN src/contrib/ntp/include/rsa_md5.h src.ntp/contrib/ntp/include/rsa_md5.h --- src/contrib/ntp/include/rsa_md5.h 2004-07-20 17:01:16.000000000 +0200 +++ src.ntp/contrib/ntp/include/rsa_md5.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,51 +0,0 @@ -/* MD5.H - header file for MD5C.C - */ - -/* Copyright (C) 1991-2, RSA Data Security, Inc. Created 1991. All - rights reserved. - - License to copy and use this software is granted provided that it - is identified as the "RSA Data Security, Inc. MD5 Message-Digest - Algorithm" in all material mentioning or referencing this software - or this function. - - License is also granted to make and use derivative works provided - that such works are identified as "derived from the RSA Data - Security, Inc. MD5 Message-Digest Algorithm" in all material - mentioning or referencing the derived work. - - RSA Data Security, Inc. makes no representations concerning either - the merchantability of this software or the suitability of this - software for any particular purpose. It is provided "as is" - without express or implied warranty of any kind. - - These notices must be retained in any copies of any part of this - documentation and/or software. - */ - -#ifndef _MD5_H_ -#define _MD5_H_ 1 - -#ifdef __cplusplus -extern "C" { -#endif - -/*#include "global.h" */ - -/* MD5 context. */ -typedef struct { - UINT4 state[4]; /* state (ABCD) */ - UINT4 count[2]; /* number of bits, modulo 2^64 (lsb first) */ - unsigned char buffer[64]; /* input buffer */ -} MD5_CTX; - -void MD5Init PROTO_LIST ((MD5_CTX *)); -void MD5Update PROTO_LIST - ((MD5_CTX *, unsigned char *, unsigned int)); -void MD5Final PROTO_LIST ((unsigned char [16], MD5_CTX *)); - -#ifdef __cplusplus -} -#endif - -#endif diff -urN src/contrib/ntp/include/ssl_applink.c src.ntp/contrib/ntp/include/ssl_applink.c --- src/contrib/ntp/include/ssl_applink.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/include/ssl_applink.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,74 @@ +/* + * include/ssl_applink.c -- common NTP code for openssl/applink.c + * + * Each program which uses OpenSSL should include this file in _one_ + * of its source files and call ssl_applink() before any OpenSSL + * functions. + */ + +#if defined(OPENSSL) && defined(SYS_WINNT) +# ifdef _MSC_VER +# pragma warning(push) +# pragma warning(disable: 4152) +# endif +# include +# ifdef _MSC_VER +# pragma warning(pop) +# endif +#endif + +#if defined(OPENSSL) && defined(_MSC_VER) && defined(_DEBUG) +#define WRAP_DBG_MALLOC +#endif + +#ifdef WRAP_DBG_MALLOC +void *wrap_dbg_malloc(size_t s, const char *f, int l); +void *wrap_dbg_realloc(void *p, size_t s, const char *f, int l); +void wrap_dbg_free(void *p); +#endif + + +#if defined(OPENSSL) && defined(SYS_WINNT) +void ssl_applink(void); + +void +ssl_applink(void) +{ +#ifdef WRAP_DBG_MALLOC + CRYPTO_set_mem_ex_functions(wrap_dbg_malloc, wrap_dbg_realloc, wrap_dbg_free); +#else + CRYPTO_malloc_init(); +#endif +} +#else /* !OPENSSL || !SYS_WINNT */ +#define ssl_applink() do {} while (0) +#endif + + +#ifdef WRAP_DBG_MALLOC +/* + * OpenSSL malloc overriding uses different parameters + * for DEBUG malloc/realloc/free (lacking block type). + * Simple wrappers convert. + */ +void *wrap_dbg_malloc(size_t s, const char *f, int l) +{ + void *ret; + + ret = _malloc_dbg(s, _NORMAL_BLOCK, f, l); + return ret; +} + +void *wrap_dbg_realloc(void *p, size_t s, const char *f, int l) +{ + void *ret; + + ret = _realloc_dbg(p, s, _NORMAL_BLOCK, f, l); + return ret; +} + +void wrap_dbg_free(void *p) +{ + _free_dbg(p, _NORMAL_BLOCK); +} +#endif /* WRAP_DBG_MALLOC */ diff -urN src/contrib/ntp/include/timepps-Solaris.h src.ntp/contrib/ntp/include/timepps-Solaris.h --- src/contrib/ntp/include/timepps-Solaris.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/timepps-Solaris.h 2009-12-09 08:36:35.000000000 +0100 @@ -1,6 +1,6 @@ /*********************************************************************** * * - * Copyright (c) David L. Mills 1999-2000 * + * Copyright (c) David L. Mills 1999-2009 * * * * Permission to use, copy, modify, and distribute this software and * * its documentation for any purpose and without fee is hereby * @@ -178,20 +178,39 @@ #define assert_offset_ntpfp assert_off_tu.ntpfp #define clear_offset_ntpfp clear_off_tu.ntpfp +/* addition of NTP fixed-point format */ + +#define NTPFP_M_ADD(r_i, r_f, a_i, a_f) /* r += a */ \ + do { \ + register u_int32 lo_tmp; \ + register u_int32 hi_tmp; \ + \ + lo_tmp = ((r_f) & 0xffff) + ((a_f) & 0xffff); \ + hi_tmp = (((r_f) >> 16) & 0xffff) + (((a_f) >> 16) & 0xffff); \ + if (lo_tmp & 0x10000) \ + hi_tmp++; \ + (r_f) = ((hi_tmp & 0xffff) << 16) | (lo_tmp & 0xffff); \ + \ + (r_i) += (a_i); \ + if (hi_tmp & 0x10000) \ + (r_i)++; \ + } while (0) + +#define NTPFP_L_ADDS(r, a) NTPFP_M_ADD((r)->integral, (r)->fractional, \ + (int)(a)->integral, (a)->fractional) + /* * The following definitions are architecture-dependent */ #define PPS_CAP (PPS_CAPTUREASSERT | PPS_OFFSETASSERT | PPS_TSFMT_TSPEC | PPS_TSFMT_NTPFP) -#define PPS_RO (PPS_CANWAIT | PPS_CANPOLL | PPS_TSFMT_TSPEC | PPS_TSFMT_NTPFP) +#define PPS_RO (PPS_CANWAIT | PPS_CANPOLL) typedef struct { int filedes; /* file descriptor */ pps_params_t params; /* PPS parameters set by user */ } pps_unit_t; -typedef pps_unit_t* pps_handle_t; /* pps handlebars */ - /* *------ Here begins the implementation-specific part! ------ */ @@ -199,6 +218,13 @@ #include /* + * pps handlebars, which are required to be an opaque scalar. This + * implementation uses the handle as a pointer so it must be large + * enough. uintptr_t is as large as a pointer. + */ +typedef uintptr_t pps_handle_t; + +/* * create PPS handle from file descriptor */ @@ -208,6 +234,7 @@ pps_handle_t *handle /* returned handle */ ) { + pps_unit_t *punit; int one = 1; /* @@ -228,16 +255,18 @@ * Allocate and initialize default unit structure. */ - *handle = malloc(sizeof(pps_unit_t)); - if (!(*handle)) { - errno = EBADF; + punit = malloc(sizeof(*punit)); + if (NULL == punit) { + errno = ENOMEM; return (-1); /* what, no memory? */ } - memset(*handle, 0, sizeof(pps_unit_t)); - (*handle)->filedes = filedes; - (*handle)->params.api_version = PPS_API_VERS_1; - (*handle)->params.mode = PPS_CAPTUREASSERT | PPS_TSFMT_TSPEC; + memset(punit, 0, sizeof(*punit)); + punit->filedes = filedes; + punit->params.api_version = PPS_API_VERS_1; + punit->params.mode = PPS_CAPTUREASSERT | PPS_TSFMT_TSPEC; + + *handle = (pps_handle_t)punit; return (0); } @@ -250,6 +279,8 @@ pps_handle_t handle ) { + pps_unit_t *punit; + /* * Check for valid arguments and detach PPS signal. */ @@ -258,7 +289,8 @@ errno = EBADF; return (-1); /* bad handle */ } - free(handle); + punit = (pps_unit_t *)handle; + free(punit); return (0); } @@ -272,7 +304,8 @@ const pps_params_t *params ) { - int mode, mode_in; + pps_unit_t * punit; + int mode, mode_in; /* * Check for valid arguments and set parameters. */ @@ -302,14 +335,42 @@ */ mode_in = params->mode; + punit = (pps_unit_t *)handle; + + /* + * Only one of the time formats may be selected + * if a nonzero assert offset is supplied. + */ + if ((mode_in & (PPS_TSFMT_TSPEC | PPS_TSFMT_NTPFP)) == + (PPS_TSFMT_TSPEC | PPS_TSFMT_NTPFP)) { + + if (punit->params.assert_offset.tv_sec || + punit->params.assert_offset.tv_nsec) { + + errno = EINVAL; + return(-1); + } + + /* + * If no offset was specified but both time + * format flags are used consider it harmless + * but turn off PPS_TSFMT_NTPFP so getparams + * will not show both formats lit. + */ + mode_in &= ~PPS_TSFMT_NTPFP; + } /* turn off read-only bits */ mode_in &= ~PPS_RO; - /* test remaining bits, should only have captureassert and/or offsetassert */ + /* + * test remaining bits, should only have captureassert, + * offsetassert, and/or timestamp format bits. + */ - if (mode_in & ~(PPS_CAPTUREASSERT | PPS_OFFSETASSERT)) { + if (mode_in & ~(PPS_CAPTUREASSERT | PPS_OFFSETASSERT | + PPS_TSFMT_TSPEC | PPS_TSFMT_NTPFP)) { errno = EOPNOTSUPP; return(-1); } @@ -318,10 +379,10 @@ * ok, ready to go. */ - mode = handle->params.mode; - memcpy(&handle->params, params, sizeof(pps_params_t)); - handle->params.api_version = PPS_API_VERS_1; - handle->params.mode = mode | mode_in; + mode = punit->params.mode; + memcpy(&punit->params, params, sizeof(punit->params)); + punit->params.api_version = PPS_API_VERS_1; + punit->params.mode = mode | mode_in; return (0); } @@ -335,6 +396,8 @@ pps_params_t *params ) { + pps_unit_t * punit; + /* * Check for valid arguments and get parameters. */ @@ -349,11 +412,12 @@ return (-1); /* bad argument */ } - memcpy(params, &handle->params, sizeof(pps_params_t)); + punit = (pps_unit_t *)handle; + memcpy(params, &punit->params, sizeof(params)); return (0); } -/* ( +/* * get capabilities for handle */ @@ -397,7 +461,8 @@ u_int serial; } ev; - pps_info_t infobuf; + pps_info_t infobuf; + pps_unit_t * punit; /* * Check for valid arguments and fetch timestamps @@ -419,56 +484,58 @@ */ memset(&infobuf, 0, sizeof(infobuf)); + punit = (pps_unit_t *)handle; /* * if not captureassert, nothing to return. */ - if (!handle->params.mode & PPS_CAPTUREASSERT) { - memcpy(ppsinfo, &infobuf, sizeof(pps_info_t)); + if (!punit->params.mode & PPS_CAPTUREASSERT) { + memcpy(ppsinfo, &infobuf, sizeof(*ppsinfo)); return (0); } - if (ioctl(handle->filedes, TIOCGPPSEV, (caddr_t) &ev) < 0) { + if (ioctl(punit->filedes, TIOCGPPSEV, (caddr_t) &ev) < 0) { perror("time_pps_fetch:"); errno = EOPNOTSUPP; return(-1); } - /* - * Apply offsets as specified. Note that only assert timestamps - * are captured by this interface. - */ - infobuf.assert_sequence = ev.serial; infobuf.assert_timestamp.tv_sec = ev.tv.tv_sec; infobuf.assert_timestamp.tv_nsec = ev.tv.tv_usec * 1000; - if (handle->params.mode & PPS_OFFSETASSERT) { - infobuf.assert_timestamp.tv_sec += handle->params.assert_offset.tv_sec; - infobuf.assert_timestamp.tv_nsec += handle->params.assert_offset.tv_nsec; - PPS_NORMALIZE(infobuf.assert_timestamp); - } - /* - * Translate to specified format + * Translate to specified format then apply offset */ switch (tsformat) { case PPS_TSFMT_TSPEC: - break; /* timespec format requires no translation */ + /* timespec format requires no conversion */ + if (punit->params.mode & PPS_OFFSETASSERT) { + infobuf.assert_timestamp.tv_sec += + punit->params.assert_offset.tv_sec; + infobuf.assert_timestamp.tv_nsec += + punit->params.assert_offset.tv_nsec; + PPS_NORMALIZE(infobuf.assert_timestamp); + } + break; - case PPS_TSFMT_NTPFP: /* NTP format requires conversion to fraction form */ + case PPS_TSFMT_NTPFP: + /* NTP format requires conversion to fraction form */ PPS_TSPECTONTP(infobuf.assert_timestamp_ntpfp); - break; + if (punit->params.mode & PPS_OFFSETASSERT) + NTPFP_L_ADDS(&infobuf.assert_timestamp_ntpfp, + &punit->params.assert_offset_ntpfp); + break; default: errno = EINVAL; return (-1); } - infobuf.current_mode = handle->params.mode; - memcpy(ppsinfo, &infobuf, sizeof(pps_info_t)); + infobuf.current_mode = punit->params.mode; + memcpy(ppsinfo, &infobuf, sizeof(*ppsinfo)); return (0); } @@ -480,7 +547,8 @@ time_pps_kcbind( pps_handle_t handle, const int kernel_consumer, - const int edge, const int tsformat + const int edge, + const int tsformat ) { /* diff -urN src/contrib/ntp/include/trimble.h src.ntp/contrib/ntp/include/trimble.h --- src/contrib/ntp/include/trimble.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/include/trimble.h 2009-12-09 08:36:37.000000000 +0100 @@ -132,7 +132,7 @@ extern cmd_info_t trimble_rcmds[]; extern cmd_info_t trimble_scmds[]; -extern cmd_info_t *trimble_convert P((unsigned int cmd, cmd_info_t *tbl)); +extern cmd_info_t *trimble_convert (unsigned int cmd, cmd_info_t *tbl); #endif /* diff -urN src/contrib/ntp/include/version.def src.ntp/contrib/ntp/include/version.def --- src/contrib/ntp/include/version.def 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/include/version.def 2010-07-09 04:23:23.000000000 +0200 @@ -1 +1 @@ -version = '4.2.4p8'; +version = '4.2.6p2'; diff -urN src/contrib/ntp/include/version.texi src.ntp/contrib/ntp/include/version.texi --- src/contrib/ntp/include/version.texi 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/include/version.texi 2010-07-09 04:23:23.000000000 +0200 @@ -0,0 +1,3 @@ +@set UPDATED 09 July 2010 +@set EDITION 4.2.6p2 +@set VERSION 4.2.6p2 diff -urN src/contrib/ntp/kernel/Makefile.am src.ntp/contrib/ntp/kernel/Makefile.am --- src/contrib/ntp/kernel/Makefile.am 1999-12-09 14:01:17.000000000 +0100 +++ src.ntp/contrib/ntp/kernel/Makefile.am 2009-12-09 08:36:35.000000000 +0100 @@ -1,5 +1,5 @@ #AUTOMAKE_OPTIONS = ../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr +AUTOMAKE_OPTIONS = SUBDIRS = sys ETAGS_ARGS = Makefile.am EXTRA_DIST = chuinit.c clkinit.c tty_chu.c tty_chu_STREAMS.c tty_clk.c tty_clk_STREAMS.c diff -urN src/contrib/ntp/kernel/Makefile.in src.ntp/contrib/ntp/kernel/Makefile.in --- src/contrib/ntp/kernel/Makefile.in 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/kernel/Makefile.in 2010-07-09 04:21:31.000000000 +0200 @@ -38,7 +38,11 @@ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ + $(top_srcdir)/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/m4/ntp_openssl.m4 \ + $(top_srcdir)/m4/ntp_vpathhack.m4 \ $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ @@ -93,7 +97,6 @@ ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -114,6 +117,7 @@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EF_LIBS = @EF_LIBS@ EF_PROGS = @EF_PROGS@ EGREP = @EGREP@ @@ -145,6 +149,7 @@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ @@ -161,18 +166,22 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ PATH_SEPARATOR = @PATH_SEPARATOR@ PATH_SH = @PATH_SH@ PROPDELAY = @PROPDELAY@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ VERSION = @VERSION@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ @@ -226,7 +235,7 @@ top_srcdir = @top_srcdir@ #AUTOMAKE_OPTIONS = ../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr +AUTOMAKE_OPTIONS = SUBDIRS = sys ETAGS_ARGS = Makefile.am EXTRA_DIST = chuinit.c clkinit.c tty_chu.c tty_chu_STREAMS.c tty_clk.c tty_clk_STREAMS.c diff -urN src/contrib/ntp/kernel/sys/Makefile.am src.ntp/contrib/ntp/kernel/sys/Makefile.am --- src/contrib/ntp/kernel/sys/Makefile.am 2004-07-20 17:01:19.000000000 +0200 +++ src.ntp/contrib/ntp/kernel/sys/Makefile.am 2009-12-09 08:36:35.000000000 +0100 @@ -1,5 +1,5 @@ #AUTOMAKE_OPTIONS = ../../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../../util/ansi2knr +AUTOMAKE_OPTIONS = noinst_HEADERS = bsd_audioirig.h chudefs.h clkdefs.h i8253.h parsestreams.h \ pcl720.h ppsclock.h timex.h tpro.h tt560_api.h #EXTRA_DIST= TAGS diff -urN src/contrib/ntp/kernel/sys/Makefile.in src.ntp/contrib/ntp/kernel/sys/Makefile.in --- src/contrib/ntp/kernel/sys/Makefile.in 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/kernel/sys/Makefile.in 2010-07-09 04:21:32.000000000 +0200 @@ -40,7 +40,11 @@ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ + $(top_srcdir)/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/m4/ntp_openssl.m4 \ + $(top_srcdir)/m4/ntp_vpathhack.m4 \ $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ @@ -58,7 +62,6 @@ ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -79,6 +82,7 @@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EF_LIBS = @EF_LIBS@ EF_PROGS = @EF_PROGS@ EGREP = @EGREP@ @@ -110,6 +114,7 @@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ @@ -126,18 +131,22 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ PATH_SEPARATOR = @PATH_SEPARATOR@ PATH_SH = @PATH_SH@ PROPDELAY = @PROPDELAY@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ VERSION = @VERSION@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ @@ -191,7 +200,7 @@ top_srcdir = @top_srcdir@ #AUTOMAKE_OPTIONS = ../../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../../util/ansi2knr +AUTOMAKE_OPTIONS = noinst_HEADERS = bsd_audioirig.h chudefs.h clkdefs.h i8253.h parsestreams.h \ pcl720.h ppsclock.h timex.h tpro.h tt560_api.h diff -urN src/contrib/ntp/lib/isc/alpha/include/isc/atomic.h src.ntp/contrib/ntp/lib/isc/alpha/include/isc/atomic.h --- src/contrib/ntp/lib/isc/alpha/include/isc/atomic.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/alpha/include/isc/atomic.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,184 @@ +/* + * Copyright (C) 2005, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: atomic.h,v 1.5.332.2 2009/04/08 06:47:32 tbox Exp $ */ + +/* + * This code was written based on FreeBSD's kernel source whose copyright + * follows: + */ + +/*- + * Copyright (c) 1998 Doug Rabson + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $FreeBSD: src/sys/alpha/include/atomic.h,v 1.18.6.1 2004/09/13 21:52:04 wilko Exp $ + */ + +#ifndef ISC_ATOMIC_H +#define ISC_ATOMIC_H 1 + +#include +#include + +#ifdef ISC_PLATFORM_USEOSFASM +#include + +#pragma intrinsic(asm) + +/* + * This routine atomically increments the value stored in 'p' by 'val', and + * returns the previous value. Memory access ordering around this function + * can be critical, so we add explicit memory block instructions at the + * beginning and the end of it (same for other functions). + */ +static inline isc_int32_t +isc_atomic_xadd(isc_int32_t *p, isc_int32_t val) { + return (asm("mb;" + "1:" + "ldl_l %t0, 0(%a0);" /* load old value */ + "mov %t0, %v0;" /* copy the old value */ + "addl %t0, %a1, %t0;" /* calculate new value */ + "stl_c %t0, 0(%a0);" /* attempt to store */ + "beq %t0, 1b;" /* spin if failed */ + "mb;", + p, val)); +} + +/* + * This routine atomically stores the value 'val' in 'p'. + */ +static inline void +isc_atomic_store(isc_int32_t *p, isc_int32_t val) { + (void)asm("mb;" + "1:" + "ldl_l %t0, 0(%a0);" /* load old value */ + "mov %a1, %t0;" /* value to store */ + "stl_c %t0, 0(%a0);" /* attempt to store */ + "beq %t0, 1b;" /* spin if failed */ + "mb;", + p, val); +} + +/* + * This routine atomically replaces the value in 'p' with 'val', if the + * original value is equal to 'cmpval'. The original value is returned in any + * case. + */ +static inline isc_int32_t +isc_atomic_cmpxchg(isc_int32_t *p, isc_int32_t cmpval, isc_int32_t val) { + + return(asm("mb;" + "1:" + "ldl_l %t0, 0(%a0);" /* load old value */ + "mov %t0, %v0;" /* copy the old value */ + "cmpeq %t0, %a1, %t0;" /* compare */ + "beq %t0, 2f;" /* exit if not equal */ + "mov %a2, %t0;" /* value to store */ + "stl_c %t0, 0(%a0);" /* attempt to store */ + "beq %t0, 1b;" /* if it failed, spin */ + "2:" + "mb;", + p, cmpval, val)); +} +#elif defined (ISC_PLATFORM_USEGCCASM) +static inline isc_int32_t +isc_atomic_xadd(isc_int32_t *p, isc_int32_t val) { + isc_int32_t temp, prev; + + __asm__ volatile( + "mb;" + "1:" + "ldl_l %0, %1;" /* load old value */ + "mov %0, %2;" /* copy the old value */ + "addl %0, %3, %0;" /* calculate new value */ + "stl_c %0, %1;" /* attempt to store */ + "beq %0, 1b;" /* spin if failed */ + "mb;" + : "=&r"(temp), "+m"(*p), "=&r"(prev) + : "r"(val) + : "memory"); + + return (prev); +} + +static inline void +isc_atomic_store(isc_int32_t *p, isc_int32_t val) { + isc_int32_t temp; + + __asm__ volatile( + "mb;" + "1:" + "ldl_l %0, %1;" /* load old value */ + "mov %2, %0;" /* value to store */ + "stl_c %0, %1;" /* attempt to store */ + "beq %0, 1b;" /* if it failed, spin */ + "mb;" + : "=&r"(temp), "+m"(*p) + : "r"(val) + : "memory"); +} + +static inline isc_int32_t +isc_atomic_cmpxchg(isc_int32_t *p, isc_int32_t cmpval, isc_int32_t val) { + isc_int32_t temp, prev; + + __asm__ volatile( + "mb;" + "1:" + "ldl_l %0, %1;" /* load old value */ + "mov %0, %2;" /* copy the old value */ + "cmpeq %0, %3, %0;" /* compare */ + "beq %0, 2f;" /* exit if not equal */ + "mov %4, %0;" /* value to store */ + "stl_c %0, %1;" /* attempt to store */ + "beq %0, 1b;" /* if it failed, spin */ + "2:" + "mb;" + : "=&r"(temp), "+m"(*p), "=&r"(prev) + : "r"(cmpval), "r"(val) + : "memory"); + + return (prev); +} +#else + +#error "unsupported compiler. disable atomic ops by --disable-atomic" + +#endif + +#endif /* ISC_ATOMIC_H */ diff -urN src/contrib/ntp/lib/isc/api src.ntp/contrib/ntp/lib/isc/api --- src/contrib/ntp/lib/isc/api 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/api 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,3 @@ +LIBINTERFACE = 51 +LIBREVISION = 1 +LIBAGE = 1 diff -urN src/contrib/ntp/lib/isc/assertions.c src.ntp/contrib/ntp/lib/isc/assertions.c --- src/contrib/ntp/lib/isc/assertions.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/assertions.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,97 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1997-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: assertions.c,v 1.23 2008/10/15 23:47:31 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include + +#include +#include + +/*% + * Forward. + */ +/* coverity[+kill] */ +static void +default_callback(const char *, int, isc_assertiontype_t, const char *); + +/*% + * Public. + */ + +LIBISC_EXTERNAL_DATA isc_assertioncallback_t isc_assertion_failed = + default_callback; + +/*% Set callback. */ +void +isc_assertion_setcallback(isc_assertioncallback_t cb) { + if (cb == NULL) + isc_assertion_failed = default_callback; + else + isc_assertion_failed = cb; +} + +/*% Type to Text */ +const char * +isc_assertion_typetotext(isc_assertiontype_t type) { + const char *result; + + /* + * These strings have purposefully not been internationalized + * because they are considered to essentially be keywords of + * the ISC development environment. + */ + switch (type) { + case isc_assertiontype_require: + result = "REQUIRE"; + break; + case isc_assertiontype_ensure: + result = "ENSURE"; + break; + case isc_assertiontype_insist: + result = "INSIST"; + break; + case isc_assertiontype_invariant: + result = "INVARIANT"; + break; + default: + result = NULL; + } + return (result); +} + +/* + * Private. + */ + +static void +default_callback(const char *file, int line, isc_assertiontype_t type, + const char *cond) +{ + fprintf(stderr, "%s:%d: %s(%s) %s.\n", + file, line, isc_assertion_typetotext(type), cond, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + fflush(stderr); + abort(); + /* NOTREACHED */ +} diff -urN src/contrib/ntp/lib/isc/base32.c src.ntp/contrib/ntp/lib/isc/base32.c --- src/contrib/ntp/lib/isc/base32.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/base32.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,371 @@ +/* + * Copyright (C) 2008, 2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: base32.c,v 1.3.116.2 2009/01/18 23:47:41 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include +#include +#include +#include + +#define RETERR(x) do { \ + isc_result_t _r = (x); \ + if (_r != ISC_R_SUCCESS) \ + return (_r); \ + } while (0) + + +/*@{*/ +/*! + * These static functions are also present in lib/dns/rdata.c. I'm not + * sure where they should go. -- bwelling + */ +static isc_result_t +str_totext(const char *source, isc_buffer_t *target); + +static isc_result_t +mem_tobuffer(isc_buffer_t *target, void *base, unsigned int length); + +/*@}*/ + +static const char base32[] = + "ABCDEFGHIJKLMNOPQRSTUVWXYZ234567=abcdefghijklmnopqrstuvwxyz234567"; +static const char base32hex[] = + "0123456789ABCDEFGHIJKLMNOPQRSTUV=0123456789abcdefghijklmnopqrstuv"; + +static isc_result_t +base32_totext(isc_region_t *source, int wordlength, const char *wordbreak, + isc_buffer_t *target, const char base[]) +{ + char buf[9]; + unsigned int loops = 0; + + if (wordlength >= 0 && wordlength < 8) + wordlength = 8; + + memset(buf, 0, sizeof(buf)); + while (source->length > 0) { + buf[0] = base[((source->base[0]>>3)&0x1f)]; /* 5 + */ + if (source->length == 1) { + buf[1] = base[(source->base[0]<<2)&0x1c]; + buf[2] = buf[3] = buf[4] = '='; + buf[5] = buf[6] = buf[7] = '='; + RETERR(str_totext(buf, target)); + break; + } + buf[1] = base[((source->base[0]<<2)&0x1c)| /* 3 = 8 */ + ((source->base[1]>>6)&0x03)]; /* 2 + */ + buf[2] = base[((source->base[1]>>1)&0x1f)]; /* 5 + */ + if (source->length == 2) { + buf[3] = base[(source->base[1]<<4)&0x10]; + buf[4] = buf[5] = buf[6] = buf[7] = '='; + RETERR(str_totext(buf, target)); + break; + } + buf[3] = base[((source->base[1]<<4)&0x10)| /* 1 = 8 */ + ((source->base[2]>>4)&0x0f)]; /* 4 + */ + if (source->length == 3) { + buf[4] = base[(source->base[2]<<1)&0x1e]; + buf[5] = buf[6] = buf[7] = '='; + RETERR(str_totext(buf, target)); + break; + } + buf[4] = base[((source->base[2]<<1)&0x1e)| /* 4 = 8 */ + ((source->base[3]>>7)&0x01)]; /* 1 + */ + buf[5] = base[((source->base[3]>>2)&0x1f)]; /* 5 + */ + if (source->length == 4) { + buf[6] = base[(source->base[3]<<3)&0x18]; + buf[7] = '='; + RETERR(str_totext(buf, target)); + break; + } + buf[6] = base[((source->base[3]<<3)&0x18)| /* 2 = 8 */ + ((source->base[4]>>5)&0x07)]; /* 3 + */ + buf[7] = base[source->base[4]&0x1f]; /* 5 = 8 */ + RETERR(str_totext(buf, target)); + isc_region_consume(source, 5); + + loops++; + if (source->length != 0 && wordlength >= 0 && + (int)((loops + 1) * 8) >= wordlength) + { + loops = 0; + RETERR(str_totext(wordbreak, target)); + } + } + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_base32_totext(isc_region_t *source, int wordlength, + const char *wordbreak, isc_buffer_t *target) +{ + return (base32_totext(source, wordlength, wordbreak, target, base32)); +} + +isc_result_t +isc_base32hex_totext(isc_region_t *source, int wordlength, + const char *wordbreak, isc_buffer_t *target) +{ + return (base32_totext(source, wordlength, wordbreak, target, + base32hex)); +} + +/*% + * State of a base32 decoding process in progress. + */ +typedef struct { + int length; /*%< Desired length of binary data or -1 */ + isc_buffer_t *target; /*%< Buffer for resulting binary data */ + int digits; /*%< Number of buffered base32 digits */ + isc_boolean_t seen_end; /*%< True if "=" end marker seen */ + int val[8]; + const char *base; /*%< Which encoding we are using */ + int seen_32; /*%< Number of significant bytes if non zero */ +} base32_decode_ctx_t; + +static inline void +base32_decode_init(base32_decode_ctx_t *ctx, int length, + const char base[], isc_buffer_t *target) +{ + ctx->digits = 0; + ctx->seen_end = ISC_FALSE; + ctx->seen_32 = 0; + ctx->length = length; + ctx->target = target; + ctx->base = base; +} + +static inline isc_result_t +base32_decode_char(base32_decode_ctx_t *ctx, int c) { + char *s; + unsigned int last; + + if (ctx->seen_end) + return (ISC_R_BADBASE32); + if ((s = strchr(ctx->base, c)) == NULL) + return (ISC_R_BADBASE32); + last = s - ctx->base; + /* + * Handle lower case. + */ + if (last > 32) + last -= 33; + /* + * Check that padding is contiguous. + */ + if (last != 32 && ctx->seen_32 != 0) + return (ISC_R_BADBASE32); + /* + * Check that padding starts at the right place and that + * bits that should be zero are. + * Record how many significant bytes in answer (seen_32). + */ + if (last == 32 && ctx->seen_32 == 0) + switch (ctx->digits) { + case 0: + case 1: + return (ISC_R_BADBASE32); + case 2: + if ((ctx->val[1]&0x03) != 0) + return (ISC_R_BADBASE32); + ctx->seen_32 = 1; + break; + case 3: + return (ISC_R_BADBASE32); + case 4: + if ((ctx->val[3]&0x0f) != 0) + return (ISC_R_BADBASE32); + ctx->seen_32 = 3; + break; + case 5: + if ((ctx->val[4]&0x01) != 0) + return (ISC_R_BADBASE32); + ctx->seen_32 = 3; + break; + case 6: + return (ISC_R_BADBASE32); + case 7: + if ((ctx->val[6]&0x07) != 0) + return (ISC_R_BADBASE32); + ctx->seen_32 = 4; + break; + } + /* + * Zero fill pad values. + */ + ctx->val[ctx->digits++] = (last == 32) ? 0 : last; + + if (ctx->digits == 8) { + int n = 5; + unsigned char buf[5]; + + if (ctx->seen_32 != 0) { + ctx->seen_end = ISC_TRUE; + n = ctx->seen_32; + } + buf[0] = (ctx->val[0]<<3)|(ctx->val[1]>>2); + buf[1] = (ctx->val[1]<<6)|(ctx->val[2]<<1)|(ctx->val[3]>>4); + buf[2] = (ctx->val[3]<<4)|(ctx->val[4]>>1); + buf[3] = (ctx->val[4]<<7)|(ctx->val[5]<<2)|(ctx->val[6]>>3); + buf[4] = (ctx->val[6]<<5)|(ctx->val[7]); + RETERR(mem_tobuffer(ctx->target, buf, n)); + if (ctx->length >= 0) { + if (n > ctx->length) + return (ISC_R_BADBASE32); + else + ctx->length -= n; + } + ctx->digits = 0; + } + return (ISC_R_SUCCESS); +} + +static inline isc_result_t +base32_decode_finish(base32_decode_ctx_t *ctx) { + if (ctx->length > 0) + return (ISC_R_UNEXPECTEDEND); + if (ctx->digits != 0) + return (ISC_R_BADBASE32); + return (ISC_R_SUCCESS); +} + +static isc_result_t +base32_tobuffer(isc_lex_t *lexer, const char base[], isc_buffer_t *target, + int length) +{ + base32_decode_ctx_t ctx; + isc_textregion_t *tr; + isc_token_t token; + isc_boolean_t eol; + + base32_decode_init(&ctx, length, base, target); + + while (!ctx.seen_end && (ctx.length != 0)) { + unsigned int i; + + if (length > 0) + eol = ISC_FALSE; + else + eol = ISC_TRUE; + RETERR(isc_lex_getmastertoken(lexer, &token, + isc_tokentype_string, eol)); + if (token.type != isc_tokentype_string) + break; + tr = &token.value.as_textregion; + for (i = 0; i < tr->length; i++) + RETERR(base32_decode_char(&ctx, tr->base[i])); + } + if (ctx.length < 0 && !ctx.seen_end) + isc_lex_ungettoken(lexer, &token); + RETERR(base32_decode_finish(&ctx)); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_base32_tobuffer(isc_lex_t *lexer, isc_buffer_t *target, int length) { + return (base32_tobuffer(lexer, base32, target, length)); +} + +isc_result_t +isc_base32hex_tobuffer(isc_lex_t *lexer, isc_buffer_t *target, int length) { + return (base32_tobuffer(lexer, base32hex, target, length)); +} + +static isc_result_t +base32_decodestring(const char *cstr, const char base[], isc_buffer_t *target) { + base32_decode_ctx_t ctx; + + base32_decode_init(&ctx, -1, base, target); + for (;;) { + int c = *cstr++; + if (c == '\0') + break; + if (c == ' ' || c == '\t' || c == '\n' || c== '\r') + continue; + RETERR(base32_decode_char(&ctx, c)); + } + RETERR(base32_decode_finish(&ctx)); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_base32_decodestring(const char *cstr, isc_buffer_t *target) { + return (base32_decodestring(cstr, base32, target)); +} + +isc_result_t +isc_base32hex_decodestring(const char *cstr, isc_buffer_t *target) { + return (base32_decodestring(cstr, base32hex, target)); +} + +static isc_result_t +base32_decoderegion(isc_region_t *source, const char base[], isc_buffer_t *target) { + base32_decode_ctx_t ctx; + + base32_decode_init(&ctx, -1, base, target); + while (source->length != 0) { + int c = *source->base; + RETERR(base32_decode_char(&ctx, c)); + isc_region_consume(source, 1); + } + RETERR(base32_decode_finish(&ctx)); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_base32_decoderegion(isc_region_t *source, isc_buffer_t *target) { + return (base32_decoderegion(source, base32, target)); +} + +isc_result_t +isc_base32hex_decoderegion(isc_region_t *source, isc_buffer_t *target) { + return (base32_decoderegion(source, base32hex, target)); +} + +static isc_result_t +str_totext(const char *source, isc_buffer_t *target) { + unsigned int l; + isc_region_t region; + + isc_buffer_availableregion(target, ®ion); + l = strlen(source); + + if (l > region.length) + return (ISC_R_NOSPACE); + + memcpy(region.base, source, l); + isc_buffer_add(target, l); + return (ISC_R_SUCCESS); +} + +static isc_result_t +mem_tobuffer(isc_buffer_t *target, void *base, unsigned int length) { + isc_region_t tr; + + isc_buffer_availableregion(target, &tr); + if (length > tr.length) + return (ISC_R_NOSPACE); + memcpy(tr.base, base, length); + isc_buffer_add(target, length); + return (ISC_R_SUCCESS); +} diff -urN src/contrib/ntp/lib/isc/base64.c src.ntp/contrib/ntp/lib/isc/base64.c --- src/contrib/ntp/lib/isc/base64.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/base64.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,250 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: base64.c,v 1.32 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include +#include +#include + +#define RETERR(x) do { \ + isc_result_t _r = (x); \ + if (_r != ISC_R_SUCCESS) \ + return (_r); \ + } while (0) + + +/*@{*/ +/*! + * These static functions are also present in lib/dns/rdata.c. I'm not + * sure where they should go. -- bwelling + */ +static isc_result_t +str_totext(const char *source, isc_buffer_t *target); + +static isc_result_t +mem_tobuffer(isc_buffer_t *target, void *base, unsigned int length); + +static const char base64[] = + "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="; +/*@}*/ + +isc_result_t +isc_base64_totext(isc_region_t *source, int wordlength, + const char *wordbreak, isc_buffer_t *target) +{ + char buf[5]; + unsigned int loops = 0; + + if (wordlength < 4) + wordlength = 4; + + memset(buf, 0, sizeof(buf)); + while (source->length > 2) { + buf[0] = base64[(source->base[0]>>2)&0x3f]; + buf[1] = base64[((source->base[0]<<4)&0x30)| + ((source->base[1]>>4)&0x0f)]; + buf[2] = base64[((source->base[1]<<2)&0x3c)| + ((source->base[2]>>6)&0x03)]; + buf[3] = base64[source->base[2]&0x3f]; + RETERR(str_totext(buf, target)); + isc_region_consume(source, 3); + + loops++; + if (source->length != 0 && + (int)((loops + 1) * 4) >= wordlength) + { + loops = 0; + RETERR(str_totext(wordbreak, target)); + } + } + if (source->length == 2) { + buf[0] = base64[(source->base[0]>>2)&0x3f]; + buf[1] = base64[((source->base[0]<<4)&0x30)| + ((source->base[1]>>4)&0x0f)]; + buf[2] = base64[((source->base[1]<<2)&0x3c)]; + buf[3] = '='; + RETERR(str_totext(buf, target)); + } else if (source->length == 1) { + buf[0] = base64[(source->base[0]>>2)&0x3f]; + buf[1] = base64[((source->base[0]<<4)&0x30)]; + buf[2] = buf[3] = '='; + RETERR(str_totext(buf, target)); + } + return (ISC_R_SUCCESS); +} + +/*% + * State of a base64 decoding process in progress. + */ +typedef struct { + int length; /*%< Desired length of binary data or -1 */ + isc_buffer_t *target; /*%< Buffer for resulting binary data */ + int digits; /*%< Number of buffered base64 digits */ + isc_boolean_t seen_end; /*%< True if "=" end marker seen */ + int val[4]; +} base64_decode_ctx_t; + +static inline void +base64_decode_init(base64_decode_ctx_t *ctx, int length, isc_buffer_t *target) +{ + ctx->digits = 0; + ctx->seen_end = ISC_FALSE; + ctx->length = length; + ctx->target = target; +} + +static inline isc_result_t +base64_decode_char(base64_decode_ctx_t *ctx, int c) { + char *s; + + if (ctx->seen_end) + return (ISC_R_BADBASE64); + if ((s = strchr(base64, c)) == NULL) + return (ISC_R_BADBASE64); + ctx->val[ctx->digits++] = s - base64; + if (ctx->digits == 4) { + int n; + unsigned char buf[3]; + if (ctx->val[0] == 64 || ctx->val[1] == 64) + return (ISC_R_BADBASE64); + if (ctx->val[2] == 64 && ctx->val[3] != 64) + return (ISC_R_BADBASE64); + /* + * Check that bits that should be zero are. + */ + if (ctx->val[2] == 64 && (ctx->val[1] & 0xf) != 0) + return (ISC_R_BADBASE64); + /* + * We don't need to test for ctx->val[2] != 64 as + * the bottom two bits of 64 are zero. + */ + if (ctx->val[3] == 64 && (ctx->val[2] & 0x3) != 0) + return (ISC_R_BADBASE64); + n = (ctx->val[2] == 64) ? 1 : + (ctx->val[3] == 64) ? 2 : 3; + if (n != 3) { + ctx->seen_end = ISC_TRUE; + if (ctx->val[2] == 64) + ctx->val[2] = 0; + if (ctx->val[3] == 64) + ctx->val[3] = 0; + } + buf[0] = (ctx->val[0]<<2)|(ctx->val[1]>>4); + buf[1] = (ctx->val[1]<<4)|(ctx->val[2]>>2); + buf[2] = (ctx->val[2]<<6)|(ctx->val[3]); + RETERR(mem_tobuffer(ctx->target, buf, n)); + if (ctx->length >= 0) { + if (n > ctx->length) + return (ISC_R_BADBASE64); + else + ctx->length -= n; + } + ctx->digits = 0; + } + return (ISC_R_SUCCESS); +} + +static inline isc_result_t +base64_decode_finish(base64_decode_ctx_t *ctx) { + if (ctx->length > 0) + return (ISC_R_UNEXPECTEDEND); + if (ctx->digits != 0) + return (ISC_R_BADBASE64); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_base64_tobuffer(isc_lex_t *lexer, isc_buffer_t *target, int length) { + base64_decode_ctx_t ctx; + isc_textregion_t *tr; + isc_token_t token; + isc_boolean_t eol; + + base64_decode_init(&ctx, length, target); + + while (!ctx.seen_end && (ctx.length != 0)) { + unsigned int i; + + if (length > 0) + eol = ISC_FALSE; + else + eol = ISC_TRUE; + RETERR(isc_lex_getmastertoken(lexer, &token, + isc_tokentype_string, eol)); + if (token.type != isc_tokentype_string) + break; + tr = &token.value.as_textregion; + for (i = 0; i < tr->length; i++) + RETERR(base64_decode_char(&ctx, tr->base[i])); + } + if (ctx.length < 0 && !ctx.seen_end) + isc_lex_ungettoken(lexer, &token); + RETERR(base64_decode_finish(&ctx)); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_base64_decodestring(const char *cstr, isc_buffer_t *target) { + base64_decode_ctx_t ctx; + + base64_decode_init(&ctx, -1, target); + for (;;) { + int c = *cstr++; + if (c == '\0') + break; + if (c == ' ' || c == '\t' || c == '\n' || c== '\r') + continue; + RETERR(base64_decode_char(&ctx, c)); + } + RETERR(base64_decode_finish(&ctx)); + return (ISC_R_SUCCESS); +} + +static isc_result_t +str_totext(const char *source, isc_buffer_t *target) { + unsigned int l; + isc_region_t region; + + isc_buffer_availableregion(target, ®ion); + l = strlen(source); + + if (l > region.length) + return (ISC_R_NOSPACE); + + memcpy(region.base, source, l); + isc_buffer_add(target, l); + return (ISC_R_SUCCESS); +} + +static isc_result_t +mem_tobuffer(isc_buffer_t *target, void *base, unsigned int length) { + isc_region_t tr; + + isc_buffer_availableregion(target, &tr); + if (length > tr.length) + return (ISC_R_NOSPACE); + memcpy(tr.base, base, length); + isc_buffer_add(target, length); + return (ISC_R_SUCCESS); +} diff -urN src/contrib/ntp/lib/isc/bitstring.c src.ntp/contrib/ntp/lib/isc/bitstring.c --- src/contrib/ntp/lib/isc/bitstring.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/bitstring.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,127 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: bitstring.c,v 1.17 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include + +#include +#include +#include + +#define DIV8(x) ((x) >> 3) +#define MOD8(x) ((x) & 0x00000007U) +#define OCTETS(n) (((n) + 7) >> 3) +#define PADDED(n) ((((n) + 7) >> 3) << 3) +#define BITSET(bs, n) (((bs)->data[DIV8(n)] & \ + (1 << (7 - MOD8(n)))) != 0) +#define SETBIT(bs, n) (bs)->data[DIV8(n)] |= (1 << (7 - MOD8(n))) +#define CLEARBIT(bs, n) (bs)->data[DIV8(n)] &= ~(1 << (7 - MOD8(n))) + +#define BITSTRING_MAGIC ISC_MAGIC('B', 'S', 't', 'r') +#define VALID_BITSTRING(b) ISC_MAGIC_VALID(b, BITSTRING_MAGIC) + +void +isc_bitstring_init(isc_bitstring_t *bitstring, unsigned char *data, + unsigned int length, unsigned int size, isc_boolean_t lsb0) +{ + /* + * Make 'bitstring' refer to the bitstring of 'size' bits starting + * at 'data'. 'length' bits of the bitstring are valid. If 'lsb0' + * is set then, bit 0 refers to the least significant bit of the + * bitstring. Otherwise bit 0 is the most significant bit. + */ + + REQUIRE(bitstring != NULL); + REQUIRE(data != NULL); + REQUIRE(length <= size); + + bitstring->magic = BITSTRING_MAGIC; + bitstring->data = data; + bitstring->length = length; + bitstring->size = size; + bitstring->lsb0 = lsb0; +} + +void +isc_bitstring_invalidate(isc_bitstring_t *bitstring) { + + /* + * Invalidate 'bitstring'. + */ + + REQUIRE(VALID_BITSTRING(bitstring)); + + bitstring->magic = 0; + bitstring->data = NULL; + bitstring->length = 0; + bitstring->size = 0; + bitstring->lsb0 = ISC_FALSE; +} + +void +isc_bitstring_copy(isc_bitstring_t *source, unsigned int sbitpos, + isc_bitstring_t *target, unsigned int tbitpos, + unsigned int n) +{ + unsigned int tlast; + + /* + * Starting at bit 'sbitpos', copy 'n' bits from 'source' to + * the 'n' bits of 'target' starting at 'tbitpos'. + */ + + REQUIRE(VALID_BITSTRING(source)); + REQUIRE(VALID_BITSTRING(target)); + REQUIRE(source->lsb0 == target->lsb0); + if (source->lsb0) { + REQUIRE(sbitpos <= source->length); + sbitpos = PADDED(source->size) - sbitpos; + REQUIRE(sbitpos >= n); + sbitpos -= n; + } else + REQUIRE(sbitpos + n <= source->length); + tlast = tbitpos + n; + if (target->lsb0) { + REQUIRE(tbitpos <= target->length); + tbitpos = PADDED(target->size) - tbitpos; + REQUIRE(tbitpos >= n); + tbitpos -= n; + } else + REQUIRE(tlast <= target->size); + + if (tlast > target->length) + target->length = tlast; + + /* + * This is far from optimal... + */ + + while (n > 0) { + if (BITSET(source, sbitpos)) + SETBIT(target, tbitpos); + else + CLEARBIT(target, tbitpos); + sbitpos++; + tbitpos++; + n--; + } +} diff -urN src/contrib/ntp/lib/isc/buffer.c src.ntp/contrib/ntp/lib/isc/buffer.c --- src/contrib/ntp/lib/isc/buffer.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/buffer.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: buffer.c,v 1.49 2008/09/25 04:02:39 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include +#include +#include + +void +isc__buffer_init(isc_buffer_t *b, const void *base, unsigned int length) { + /* + * Make 'b' refer to the 'length'-byte region starting at 'base'. + * XXXDCL see the comment in buffer.h about base being const. + */ + + REQUIRE(b != NULL); + + ISC__BUFFER_INIT(b, base, length); +} + +void +isc__buffer_initnull(isc_buffer_t *b) { + /* + * Initialize a new buffer which has no backing store. This can + * later be grown as needed and swapped in place. + */ + + ISC__BUFFER_INIT(b, NULL, 0); +} + +void +isc_buffer_reinit(isc_buffer_t *b, void *base, unsigned int length) { + /* + * Re-initialize the buffer enough to reconfigure the base of the + * buffer. We will swap in the new buffer, after copying any + * data we contain into the new buffer and adjusting all of our + * internal pointers. + * + * The buffer must not be smaller than the length of the original + * buffer. + */ + REQUIRE(b->length <= length); + REQUIRE(base != NULL); + + (void)memmove(base, b->base, b->length); + b->base = base; + b->length = length; +} + +void +isc__buffer_invalidate(isc_buffer_t *b) { + /* + * Make 'b' an invalid buffer. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(!ISC_LINK_LINKED(b, link)); + REQUIRE(b->mctx == NULL); + + ISC__BUFFER_INVALIDATE(b); +} + +void +isc__buffer_region(isc_buffer_t *b, isc_region_t *r) { + /* + * Make 'r' refer to the region of 'b'. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(r != NULL); + + ISC__BUFFER_REGION(b, r); +} + +void +isc__buffer_usedregion(isc_buffer_t *b, isc_region_t *r) { + /* + * Make 'r' refer to the used region of 'b'. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(r != NULL); + + ISC__BUFFER_USEDREGION(b, r); +} + +void +isc__buffer_availableregion(isc_buffer_t *b, isc_region_t *r) { + /* + * Make 'r' refer to the available region of 'b'. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(r != NULL); + + ISC__BUFFER_AVAILABLEREGION(b, r); +} + +void +isc__buffer_add(isc_buffer_t *b, unsigned int n) { + /* + * Increase the 'used' region of 'b' by 'n' bytes. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used + n <= b->length); + + ISC__BUFFER_ADD(b, n); +} + +void +isc__buffer_subtract(isc_buffer_t *b, unsigned int n) { + /* + * Decrease the 'used' region of 'b' by 'n' bytes. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used >= n); + + ISC__BUFFER_SUBTRACT(b, n); +} + +void +isc__buffer_clear(isc_buffer_t *b) { + /* + * Make the used region empty. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + + ISC__BUFFER_CLEAR(b); +} + +void +isc__buffer_consumedregion(isc_buffer_t *b, isc_region_t *r) { + /* + * Make 'r' refer to the consumed region of 'b'. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(r != NULL); + + ISC__BUFFER_CONSUMEDREGION(b, r); +} + +void +isc__buffer_remainingregion(isc_buffer_t *b, isc_region_t *r) { + /* + * Make 'r' refer to the remaining region of 'b'. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(r != NULL); + + ISC__BUFFER_REMAININGREGION(b, r); +} + +void +isc__buffer_activeregion(isc_buffer_t *b, isc_region_t *r) { + /* + * Make 'r' refer to the active region of 'b'. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(r != NULL); + + ISC__BUFFER_ACTIVEREGION(b, r); +} + +void +isc__buffer_setactive(isc_buffer_t *b, unsigned int n) { + /* + * Sets the end of the active region 'n' bytes after current. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->current + n <= b->used); + + ISC__BUFFER_SETACTIVE(b, n); +} + +void +isc__buffer_first(isc_buffer_t *b) { + /* + * Make the consumed region empty. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + + ISC__BUFFER_FIRST(b); +} + +void +isc__buffer_forward(isc_buffer_t *b, unsigned int n) { + /* + * Increase the 'consumed' region of 'b' by 'n' bytes. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->current + n <= b->used); + + ISC__BUFFER_FORWARD(b, n); +} + +void +isc__buffer_back(isc_buffer_t *b, unsigned int n) { + /* + * Decrease the 'consumed' region of 'b' by 'n' bytes. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(n <= b->current); + + ISC__BUFFER_BACK(b, n); +} + +void +isc_buffer_compact(isc_buffer_t *b) { + unsigned int length; + void *src; + + /* + * Compact the used region by moving the remaining region so it occurs + * at the start of the buffer. The used region is shrunk by the size + * of the consumed region, and the consumed region is then made empty. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + + src = isc_buffer_current(b); + length = isc_buffer_remaininglength(b); + (void)memmove(b->base, src, (size_t)length); + + if (b->active > b->current) + b->active -= b->current; + else + b->active = 0; + b->current = 0; + b->used = length; +} + +isc_uint8_t +isc_buffer_getuint8(isc_buffer_t *b) { + unsigned char *cp; + isc_uint8_t result; + + /* + * Read an unsigned 8-bit integer from 'b' and return it. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used - b->current >= 1); + + cp = isc_buffer_current(b); + b->current += 1; + result = ((isc_uint8_t)(cp[0])); + + return (result); +} + +void +isc__buffer_putuint8(isc_buffer_t *b, isc_uint8_t val) { + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used + 1 <= b->length); + + ISC__BUFFER_PUTUINT8(b, val); +} + +isc_uint16_t +isc_buffer_getuint16(isc_buffer_t *b) { + unsigned char *cp; + isc_uint16_t result; + + /* + * Read an unsigned 16-bit integer in network byte order from 'b', + * convert it to host byte order, and return it. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used - b->current >= 2); + + cp = isc_buffer_current(b); + b->current += 2; + result = ((unsigned int)(cp[0])) << 8; + result |= ((unsigned int)(cp[1])); + + return (result); +} + +void +isc__buffer_putuint16(isc_buffer_t *b, isc_uint16_t val) { + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used + 2 <= b->length); + + ISC__BUFFER_PUTUINT16(b, val); +} + +void +isc__buffer_putuint24(isc_buffer_t *b, isc_uint32_t val) { + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used + 3 <= b->length); + + ISC__BUFFER_PUTUINT24(b, val); +} + +isc_uint32_t +isc_buffer_getuint32(isc_buffer_t *b) { + unsigned char *cp; + isc_uint32_t result; + + /* + * Read an unsigned 32-bit integer in network byte order from 'b', + * convert it to host byte order, and return it. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used - b->current >= 4); + + cp = isc_buffer_current(b); + b->current += 4; + result = ((unsigned int)(cp[0])) << 24; + result |= ((unsigned int)(cp[1])) << 16; + result |= ((unsigned int)(cp[2])) << 8; + result |= ((unsigned int)(cp[3])); + + return (result); +} + +void +isc__buffer_putuint32(isc_buffer_t *b, isc_uint32_t val) { + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used + 4 <= b->length); + + ISC__BUFFER_PUTUINT32(b, val); +} + +isc_uint64_t +isc_buffer_getuint48(isc_buffer_t *b) { + unsigned char *cp; + isc_uint64_t result; + + /* + * Read an unsigned 48-bit integer in network byte order from 'b', + * convert it to host byte order, and return it. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used - b->current >= 6); + + cp = isc_buffer_current(b); + b->current += 6; + result = ((isc_int64_t)(cp[0])) << 40; + result |= ((isc_int64_t)(cp[1])) << 32; + result |= ((isc_int64_t)(cp[2])) << 24; + result |= ((isc_int64_t)(cp[3])) << 16; + result |= ((isc_int64_t)(cp[4])) << 8; + result |= ((isc_int64_t)(cp[5])); + + return (result); +} + +void +isc__buffer_putuint48(isc_buffer_t *b, isc_uint64_t val) { + isc_uint16_t valhi; + isc_uint32_t vallo; + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used + 6 <= b->length); + + valhi = (isc_uint16_t)(val >> 32); + vallo = (isc_uint32_t)(val & 0xFFFFFFFF); + ISC__BUFFER_PUTUINT16(b, valhi); + ISC__BUFFER_PUTUINT32(b, vallo); +} + +void +isc__buffer_putmem(isc_buffer_t *b, const unsigned char *base, + unsigned int length) +{ + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used + length <= b->length); + + ISC__BUFFER_PUTMEM(b, base, length); +} + +void +isc__buffer_putstr(isc_buffer_t *b, const char *source) { + unsigned int l; + unsigned char *cp; + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(source != NULL); + + /* + * Do not use ISC__BUFFER_PUTSTR(), so strlen is only done once. + */ + l = strlen(source); + + REQUIRE(l <= isc_buffer_availablelength(b)); + + cp = isc_buffer_used(b); + memcpy(cp, source, l); + b->used += l; +} + +isc_result_t +isc_buffer_copyregion(isc_buffer_t *b, const isc_region_t *r) { + unsigned char *base; + unsigned int available; + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(r != NULL); + + /* + * XXXDCL + */ + base = isc_buffer_used(b); + available = isc_buffer_availablelength(b); + if (r->length > available) + return (ISC_R_NOSPACE); + memcpy(base, r->base, r->length); + b->used += r->length; + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_buffer_allocate(isc_mem_t *mctx, isc_buffer_t **dynbuffer, + unsigned int length) +{ + isc_buffer_t *dbuf; + + REQUIRE(dynbuffer != NULL); + REQUIRE(*dynbuffer == NULL); + + dbuf = isc_mem_get(mctx, length + sizeof(isc_buffer_t)); + if (dbuf == NULL) + return (ISC_R_NOMEMORY); + + isc_buffer_init(dbuf, ((unsigned char *)dbuf) + sizeof(isc_buffer_t), + length); + dbuf->mctx = mctx; + + *dynbuffer = dbuf; + + return (ISC_R_SUCCESS); +} + +void +isc_buffer_free(isc_buffer_t **dynbuffer) { + unsigned int real_length; + isc_buffer_t *dbuf; + isc_mem_t *mctx; + + REQUIRE(dynbuffer != NULL); + REQUIRE(ISC_BUFFER_VALID(*dynbuffer)); + REQUIRE((*dynbuffer)->mctx != NULL); + + dbuf = *dynbuffer; + *dynbuffer = NULL; /* destroy external reference */ + + real_length = dbuf->length + sizeof(isc_buffer_t); + mctx = dbuf->mctx; + dbuf->mctx = NULL; + isc_buffer_invalidate(dbuf); + + isc_mem_put(mctx, dbuf, real_length); +} diff -urN src/contrib/ntp/lib/isc/bufferlist.c src.ntp/contrib/ntp/lib/isc/bufferlist.c --- src/contrib/ntp/lib/isc/bufferlist.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/bufferlist.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,64 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: bufferlist.c,v 1.17 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include + +#include +#include +#include + +unsigned int +isc_bufferlist_usedcount(isc_bufferlist_t *bl) { + isc_buffer_t *buffer; + unsigned int length; + + REQUIRE(bl != NULL); + + length = 0; + buffer = ISC_LIST_HEAD(*bl); + while (buffer != NULL) { + REQUIRE(ISC_BUFFER_VALID(buffer)); + length += isc_buffer_usedlength(buffer); + buffer = ISC_LIST_NEXT(buffer, link); + } + + return (length); +} + +unsigned int +isc_bufferlist_availablecount(isc_bufferlist_t *bl) { + isc_buffer_t *buffer; + unsigned int length; + + REQUIRE(bl != NULL); + + length = 0; + buffer = ISC_LIST_HEAD(*bl); + while (buffer != NULL) { + REQUIRE(ISC_BUFFER_VALID(buffer)); + length += isc_buffer_availablelength(buffer); + buffer = ISC_LIST_NEXT(buffer, link); + } + + return (length); +} diff -urN src/contrib/ntp/lib/isc/commandline.c src.ntp/contrib/ntp/lib/isc/commandline.c --- src/contrib/ntp/lib/isc/commandline.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/commandline.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,225 @@ +/* + * Portions Copyright (C) 2004, 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * Portions Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* + * Copyright (c) 1987, 1993, 1994 + * The Regents of the University of California. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +/* $Id: commandline.c,v 1.22 2008/09/25 04:02:39 tbox Exp $ */ + +/*! \file + * This file was adapted from the NetBSD project's source tree, RCS ID: + * NetBSD: getopt.c,v 1.15 1999/09/20 04:39:37 lukem Exp + * + * The primary change has been to rename items to the ISC namespace + * and format in the ISC coding style. + */ + +/* + * \author Principal Authors: Computer Systems Research Group at UC Berkeley + * \author Principal ISC caretaker: DCL + */ + +#include + +#include + +#include +#include +#include +#include + +/*% Index into parent argv vector. */ +LIBISC_EXTERNAL_DATA int isc_commandline_index = 1; +/*% Character checked for validity. */ +LIBISC_EXTERNAL_DATA int isc_commandline_option; +/*% Argument associated with option. */ +LIBISC_EXTERNAL_DATA char *isc_commandline_argument; +/*% For printing error messages. */ +LIBISC_EXTERNAL_DATA char *isc_commandline_progname; +/*% Print error messages. */ +LIBISC_EXTERNAL_DATA isc_boolean_t isc_commandline_errprint = ISC_TRUE; +/*% Reset processing. */ +LIBISC_EXTERNAL_DATA isc_boolean_t isc_commandline_reset = ISC_TRUE; + +static char endopt = '\0'; + +#define BADOPT '?' +#define BADARG ':' +#define ENDOPT &endopt + +/*! + * getopt -- + * Parse argc/argv argument vector. + */ +int +isc_commandline_parse(int argc, char * const *argv, const char *options) { + static char *place = ENDOPT; + char *option; /* Index into *options of option. */ + + REQUIRE(argc >= 0 && argv != NULL && options != NULL); + + /* + * Update scanning pointer, either because a reset was requested or + * the previous argv was finished. + */ + if (isc_commandline_reset || *place == '\0') { + if (isc_commandline_reset) { + isc_commandline_index = 1; + isc_commandline_reset = ISC_FALSE; + } + + if (isc_commandline_progname == NULL) + isc_commandline_progname = argv[0]; + + if (isc_commandline_index >= argc || + *(place = argv[isc_commandline_index]) != '-') { + /* + * Index out of range or points to non-option. + */ + place = ENDOPT; + return (-1); + } + + if (place[1] != '\0' && *++place == '-' && place[1] == '\0') { + /* + * Found '--' to signal end of options. Advance + * index to next argv, the first non-option. + */ + isc_commandline_index++; + place = ENDOPT; + return (-1); + } + } + + isc_commandline_option = *place++; + option = strchr(options, isc_commandline_option); + + /* + * Ensure valid option has been passed as specified by options string. + * '-:' is never a valid command line option because it could not + * distinguish ':' from the argument specifier in the options string. + */ + if (isc_commandline_option == ':' || option == NULL) { + if (*place == '\0') + isc_commandline_index++; + + if (isc_commandline_errprint && *options != ':') + fprintf(stderr, "%s: %s -- %c\n", + isc_commandline_progname, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_COMMANDLINE, + ISC_MSG_ILLEGALOPT, + "illegal option"), + isc_commandline_option); + + return (BADOPT); + } + + if (*++option != ':') { + /* + * Option does not take an argument. + */ + isc_commandline_argument = NULL; + + /* + * Skip to next argv if at the end of the current argv. + */ + if (*place == '\0') + ++isc_commandline_index; + + } else { + /* + * Option needs an argument. + */ + if (*place != '\0') + /* + * Option is in this argv, -D1 style. + */ + isc_commandline_argument = place; + + else if (argc > ++isc_commandline_index) + /* + * Option is next argv, -D 1 style. + */ + isc_commandline_argument = argv[isc_commandline_index]; + + else { + /* + * Argument needed, but no more argv. + */ + place = ENDOPT; + + /* + * Silent failure with "missing argument" return + * when ':' starts options string, per historical spec. + */ + if (*options == ':') + return (BADARG); + + if (isc_commandline_errprint) + fprintf(stderr, "%s: %s -- %c\n", + isc_commandline_progname, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_COMMANDLINE, + ISC_MSG_OPTNEEDARG, + "option requires " + "an argument"), + isc_commandline_option); + + return (BADOPT); + } + + place = ENDOPT; + + /* + * Point to argv that follows argument. + */ + isc_commandline_index++; + } + + return (isc_commandline_option); +} diff -urN src/contrib/ntp/lib/isc/entropy.c src.ntp/contrib/ntp/lib/isc/entropy.c --- src/contrib/ntp/lib/isc/entropy.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/entropy.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,1274 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: entropy.c,v 1.18.332.2 2009/01/18 23:47:41 tbox Exp $ */ + +/*! \file + * \brief + * This is the system independent part of the entropy module. It is + * compiled via inclusion from the relevant OS source file, ie, + * \link unix/entropy.c unix/entropy.c \endlink or win32/entropy.c. + * + * \author Much of this code is modeled after the NetBSD /dev/random implementation, + * written by Michael Graff . + */ + +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + + +#define ENTROPY_MAGIC ISC_MAGIC('E', 'n', 't', 'e') +#define SOURCE_MAGIC ISC_MAGIC('E', 'n', 't', 's') + +#define VALID_ENTROPY(e) ISC_MAGIC_VALID(e, ENTROPY_MAGIC) +#define VALID_SOURCE(s) ISC_MAGIC_VALID(s, SOURCE_MAGIC) + +/*** + *** "constants." Do not change these unless you _really_ know what + *** you are doing. + ***/ + +/*% + * Size of entropy pool in 32-bit words. This _MUST_ be a power of 2. + */ +#define RND_POOLWORDS 128 +/*% Pool in bytes. */ +#define RND_POOLBYTES (RND_POOLWORDS * 4) +/*% Pool in bits. */ +#define RND_POOLBITS (RND_POOLWORDS * 32) + +/*% + * Number of bytes returned per hash. This must be true: + * threshold * 2 <= digest_size_in_bytes + */ +#define RND_ENTROPY_THRESHOLD 10 +#define THRESHOLD_BITS (RND_ENTROPY_THRESHOLD * 8) + +/*% + * Size of the input event queue in samples. + */ +#define RND_EVENTQSIZE 32 + +/*% + * The number of times we'll "reseed" for pseudorandom seeds. This is an + * extremely weak pseudorandom seed. If the caller is using lots of + * pseudorandom data and they cannot provide a stronger random source, + * there is little we can do other than hope they're smart enough to + * call _adddata() with something better than we can come up with. + */ +#define RND_INITIALIZE 128 + +/*% Entropy Pool */ +typedef struct { + isc_uint32_t cursor; /*%< current add point in the pool */ + isc_uint32_t entropy; /*%< current entropy estimate in bits */ + isc_uint32_t pseudo; /*%< bits extracted in pseudorandom */ + isc_uint32_t rotate; /*%< how many bits to rotate by */ + isc_uint32_t pool[RND_POOLWORDS]; /*%< random pool data */ +} isc_entropypool_t; + +struct isc_entropy { + unsigned int magic; + isc_mem_t *mctx; + isc_mutex_t lock; + unsigned int refcnt; + isc_uint32_t initialized; + isc_uint32_t initcount; + isc_entropypool_t pool; + unsigned int nsources; + isc_entropysource_t *nextsource; + ISC_LIST(isc_entropysource_t) sources; +}; + +/*% Sample Queue */ +typedef struct { + isc_uint32_t last_time; /*%< last time recorded */ + isc_uint32_t last_delta; /*%< last delta value */ + isc_uint32_t last_delta2; /*%< last delta2 value */ + isc_uint32_t nsamples; /*%< number of samples filled in */ + isc_uint32_t *samples; /*%< the samples */ + isc_uint32_t *extra; /*%< extra samples added in */ +} sample_queue_t; + +typedef struct { + sample_queue_t samplequeue; +} isc_entropysamplesource_t; + +typedef struct { + isc_boolean_t start_called; + isc_entropystart_t startfunc; + isc_entropyget_t getfunc; + isc_entropystop_t stopfunc; + void *arg; + sample_queue_t samplequeue; +} isc_cbsource_t; + +typedef struct { + FILESOURCE_HANDLE_TYPE handle; +} isc_entropyfilesource_t; + +struct isc_entropysource { + unsigned int magic; + unsigned int type; + isc_entropy_t *ent; + isc_uint32_t total; /*%< entropy from this source */ + ISC_LINK(isc_entropysource_t) link; + char name[32]; + isc_boolean_t bad; + isc_boolean_t warn_keyboard; + isc_keyboard_t kbd; + union { + isc_entropysamplesource_t sample; + isc_entropyfilesource_t file; + isc_cbsource_t callback; + isc_entropyusocketsource_t usocket; + } sources; +}; + +#define ENTROPY_SOURCETYPE_SAMPLE 1 /*%< Type is a sample source */ +#define ENTROPY_SOURCETYPE_FILE 2 /*%< Type is a file source */ +#define ENTROPY_SOURCETYPE_CALLBACK 3 /*%< Type is a callback source */ +#define ENTROPY_SOURCETYPE_USOCKET 4 /*%< Type is a Unix socket source */ + +/*@{*/ +/*% + * The random pool "taps" + */ +#define TAP1 99 +#define TAP2 59 +#define TAP3 31 +#define TAP4 9 +#define TAP5 7 +/*@}*/ + +/*@{*/ +/*% + * Declarations for function provided by the system dependent sources that + * include this file. + */ +static void +fillpool(isc_entropy_t *, unsigned int, isc_boolean_t); + +static int +wait_for_sources(isc_entropy_t *); + +static void +destroyfilesource(isc_entropyfilesource_t *source); + +static void +destroyusocketsource(isc_entropyusocketsource_t *source); + +/*@}*/ + +static void +samplequeue_release(isc_entropy_t *ent, sample_queue_t *sq) { + REQUIRE(sq->samples != NULL); + REQUIRE(sq->extra != NULL); + + isc_mem_put(ent->mctx, sq->samples, RND_EVENTQSIZE * 4); + isc_mem_put(ent->mctx, sq->extra, RND_EVENTQSIZE * 4); + sq->samples = NULL; + sq->extra = NULL; +} + +static isc_result_t +samplesource_allocate(isc_entropy_t *ent, sample_queue_t *sq) { + sq->samples = isc_mem_get(ent->mctx, RND_EVENTQSIZE * 4); + if (sq->samples == NULL) + return (ISC_R_NOMEMORY); + + sq->extra = isc_mem_get(ent->mctx, RND_EVENTQSIZE * 4); + if (sq->extra == NULL) { + isc_mem_put(ent->mctx, sq->samples, RND_EVENTQSIZE * 4); + sq->samples = NULL; + return (ISC_R_NOMEMORY); + } + + sq->nsamples = 0; + + return (ISC_R_SUCCESS); +} + +/*% + * Add in entropy, even when the value we're adding in could be + * very large. + */ +static inline void +add_entropy(isc_entropy_t *ent, isc_uint32_t entropy) { + /* clamp input. Yes, this must be done. */ + entropy = ISC_MIN(entropy, RND_POOLBITS); + /* Add in the entropy we already have. */ + entropy += ent->pool.entropy; + /* Clamp. */ + ent->pool.entropy = ISC_MIN(entropy, RND_POOLBITS); +} + +/*% + * Decrement the amount of entropy the pool has. + */ +static inline void +subtract_entropy(isc_entropy_t *ent, isc_uint32_t entropy) { + entropy = ISC_MIN(entropy, ent->pool.entropy); + ent->pool.entropy -= entropy; +} + +/*! + * Add in entropy, even when the value we're adding in could be + * very large. + */ +static inline void +add_pseudo(isc_entropy_t *ent, isc_uint32_t pseudo) { + /* clamp input. Yes, this must be done. */ + pseudo = ISC_MIN(pseudo, RND_POOLBITS * 8); + /* Add in the pseudo we already have. */ + pseudo += ent->pool.pseudo; + /* Clamp. */ + ent->pool.pseudo = ISC_MIN(pseudo, RND_POOLBITS * 8); +} + +/*! + * Decrement the amount of pseudo the pool has. + */ +static inline void +subtract_pseudo(isc_entropy_t *ent, isc_uint32_t pseudo) { + pseudo = ISC_MIN(pseudo, ent->pool.pseudo); + ent->pool.pseudo -= pseudo; +} + +/*! + * Add one word to the pool, rotating the input as needed. + */ +static inline void +entropypool_add_word(isc_entropypool_t *rp, isc_uint32_t val) { + /* + * Steal some values out of the pool, and xor them into the + * word we were given. + * + * Mix the new value into the pool using xor. This will + * prevent the actual values from being known to the caller + * since the previous values are assumed to be unknown as well. + */ + val ^= rp->pool[(rp->cursor + TAP1) & (RND_POOLWORDS - 1)]; + val ^= rp->pool[(rp->cursor + TAP2) & (RND_POOLWORDS - 1)]; + val ^= rp->pool[(rp->cursor + TAP3) & (RND_POOLWORDS - 1)]; + val ^= rp->pool[(rp->cursor + TAP4) & (RND_POOLWORDS - 1)]; + val ^= rp->pool[(rp->cursor + TAP5) & (RND_POOLWORDS - 1)]; + rp->pool[rp->cursor++] ^= + ((val << rp->rotate) | (val >> (32 - rp->rotate))); + + /* + * If we have looped around the pool, increment the rotate + * variable so the next value will get xored in rotated to + * a different position. + * Increment by a value that is relatively prime to the word size + * to try to spread the bits throughout the pool quickly when the + * pool is empty. + */ + if (rp->cursor == RND_POOLWORDS) { + rp->cursor = 0; + rp->rotate = (rp->rotate + 7) & 31; + } +} + +/*! + * Add a buffer's worth of data to the pool. + * + * Requires that the lock is held on the entropy pool. + */ +static void +entropypool_adddata(isc_entropy_t *ent, void *p, unsigned int len, + isc_uint32_t entropy) +{ + isc_uint32_t val; + unsigned long addr; + isc_uint8_t *buf; + + addr = (unsigned long)p; + buf = p; + + if ((addr & 0x03U) != 0U) { + val = 0; + switch (len) { + case 3: + val = *buf++; + len--; + case 2: + val = val << 8 | *buf++; + len--; + case 1: + val = val << 8 | *buf++; + len--; + } + + entropypool_add_word(&ent->pool, val); + } + + for (; len > 3; len -= 4) { + val = *((isc_uint32_t *)buf); + + entropypool_add_word(&ent->pool, val); + buf += 4; + } + + if (len != 0) { + val = 0; + switch (len) { + case 3: + val = *buf++; + case 2: + val = val << 8 | *buf++; + case 1: + val = val << 8 | *buf++; + } + + entropypool_add_word(&ent->pool, val); + } + + add_entropy(ent, entropy); + subtract_pseudo(ent, entropy); +} + +static inline void +reseed(isc_entropy_t *ent) { + isc_time_t t; + pid_t pid; + + if (ent->initcount == 0) { + pid = getpid(); + entropypool_adddata(ent, &pid, sizeof(pid), 0); + pid = getppid(); + entropypool_adddata(ent, &pid, sizeof(pid), 0); + } + + /*! + * After we've reseeded 100 times, only add new timing info every + * 50 requests. This will keep us from using lots and lots of + * CPU just to return bad pseudorandom data anyway. + */ + if (ent->initcount > 100) + if ((ent->initcount % 50) != 0) + return; + + TIME_NOW(&t); + entropypool_adddata(ent, &t, sizeof(t), 0); + ent->initcount++; +} + +static inline unsigned int +estimate_entropy(sample_queue_t *sq, isc_uint32_t t) { + isc_int32_t delta; + isc_int32_t delta2; + isc_int32_t delta3; + + /*! + * If the time counter has overflowed, calculate the real difference. + * If it has not, it is simpler. + */ + if (t < sq->last_time) + delta = UINT_MAX - sq->last_time + t; + else + delta = sq->last_time - t; + + if (delta < 0) + delta = -delta; + + /* + * Calculate the second and third order differentials + */ + delta2 = sq->last_delta - delta; + if (delta2 < 0) + delta2 = -delta2; + + delta3 = sq->last_delta2 - delta2; + if (delta3 < 0) + delta3 = -delta3; + + sq->last_time = t; + sq->last_delta = delta; + sq->last_delta2 = delta2; + + /* + * If any delta is 0, we got no entropy. If all are non-zero, we + * might have something. + */ + if (delta == 0 || delta2 == 0 || delta3 == 0) + return 0; + + /* + * We could find the smallest delta and claim we got log2(delta) + * bits, but for now return that we found 1 bit. + */ + return 1; +} + +static unsigned int +crunchsamples(isc_entropy_t *ent, sample_queue_t *sq) { + unsigned int ns; + unsigned int added; + + if (sq->nsamples < 6) + return (0); + + added = 0; + sq->last_time = sq->samples[0]; + sq->last_delta = 0; + sq->last_delta2 = 0; + + /* + * Prime the values by adding in the first 4 samples in. This + * should completely initialize the delta calculations. + */ + for (ns = 0; ns < 4; ns++) + (void)estimate_entropy(sq, sq->samples[ns]); + + for (ns = 4; ns < sq->nsamples; ns++) + added += estimate_entropy(sq, sq->samples[ns]); + + entropypool_adddata(ent, sq->samples, sq->nsamples * 4, added); + entropypool_adddata(ent, sq->extra, sq->nsamples * 4, 0); + + /* + * Move the last 4 samples into the first 4 positions, and start + * adding new samples from that point. + */ + for (ns = 0; ns < 4; ns++) { + sq->samples[ns] = sq->samples[sq->nsamples - 4 + ns]; + sq->extra[ns] = sq->extra[sq->nsamples - 4 + ns]; + } + + sq->nsamples = 4; + + return (added); +} + +static unsigned int +get_from_callback(isc_entropysource_t *source, unsigned int desired, + isc_boolean_t blocking) +{ + isc_entropy_t *ent = source->ent; + isc_cbsource_t *cbs = &source->sources.callback; + unsigned int added; + unsigned int got; + isc_result_t result; + + if (desired == 0) + return (0); + + if (source->bad) + return (0); + + if (!cbs->start_called && cbs->startfunc != NULL) { + result = cbs->startfunc(source, cbs->arg, blocking); + if (result != ISC_R_SUCCESS) + return (0); + cbs->start_called = ISC_TRUE; + } + + added = 0; + result = ISC_R_SUCCESS; + while (desired > 0 && result == ISC_R_SUCCESS) { + result = cbs->getfunc(source, cbs->arg, blocking); + if (result == ISC_R_QUEUEFULL) { + got = crunchsamples(ent, &cbs->samplequeue); + added += got; + desired -= ISC_MIN(got, desired); + result = ISC_R_SUCCESS; + } else if (result != ISC_R_SUCCESS && + result != ISC_R_NOTBLOCKING) + source->bad = ISC_TRUE; + + } + + return (added); +} + +/* + * Extract some number of bytes from the random pool, decreasing the + * estimate of randomness as each byte is extracted. + * + * Do this by stiring the pool and returning a part of hash as randomness. + * Note that no secrets are given away here since parts of the hash are + * xored together before returned. + * + * Honor the request from the caller to only return good data, any data, + * etc. + */ +isc_result_t +isc_entropy_getdata(isc_entropy_t *ent, void *data, unsigned int length, + unsigned int *returned, unsigned int flags) +{ + unsigned int i; + isc_sha1_t hash; + unsigned char digest[ISC_SHA1_DIGESTLENGTH]; + isc_uint32_t remain, deltae, count, total; + isc_uint8_t *buf; + isc_boolean_t goodonly, partial, blocking; + + REQUIRE(VALID_ENTROPY(ent)); + REQUIRE(data != NULL); + REQUIRE(length > 0); + + goodonly = ISC_TF((flags & ISC_ENTROPY_GOODONLY) != 0); + partial = ISC_TF((flags & ISC_ENTROPY_PARTIAL) != 0); + blocking = ISC_TF((flags & ISC_ENTROPY_BLOCKING) != 0); + + REQUIRE(!partial || returned != NULL); + + LOCK(&ent->lock); + + remain = length; + buf = data; + total = 0; + while (remain != 0) { + count = ISC_MIN(remain, RND_ENTROPY_THRESHOLD); + + /* + * If we are extracting good data only, make certain we + * have enough data in our pool for this pass. If we don't, + * get some, and fail if we can't, and partial returns + * are not ok. + */ + if (goodonly) { + unsigned int fillcount; + + fillcount = ISC_MAX(remain * 8, count * 8); + + /* + * If, however, we have at least THRESHOLD_BITS + * of entropy in the pool, don't block here. It is + * better to drain the pool once in a while and + * then refill it than it is to constantly keep the + * pool full. + */ + if (ent->pool.entropy >= THRESHOLD_BITS) + fillpool(ent, fillcount, ISC_FALSE); + else + fillpool(ent, fillcount, blocking); + + /* + * Verify that we got enough entropy to do one + * extraction. If we didn't, bail. + */ + if (ent->pool.entropy < THRESHOLD_BITS) { + if (!partial) + goto zeroize; + else + goto partial_output; + } + } else { + /* + * If we've extracted half our pool size in bits + * since the last refresh, try to refresh here. + */ + if (ent->initialized < THRESHOLD_BITS) + fillpool(ent, THRESHOLD_BITS, blocking); + else + fillpool(ent, 0, ISC_FALSE); + + /* + * If we've not initialized with enough good random + * data, seed with our crappy code. + */ + if (ent->initialized < THRESHOLD_BITS) + reseed(ent); + } + + isc_sha1_init(&hash); + isc_sha1_update(&hash, (void *)(ent->pool.pool), + RND_POOLBYTES); + isc_sha1_final(&hash, digest); + + /* + * Stir the extracted data (all of it) back into the pool. + */ + entropypool_adddata(ent, digest, ISC_SHA1_DIGESTLENGTH, 0); + + for (i = 0; i < count; i++) + buf[i] = digest[i] ^ digest[i + RND_ENTROPY_THRESHOLD]; + + buf += count; + remain -= count; + + deltae = count * 8; + deltae = ISC_MIN(deltae, ent->pool.entropy); + total += deltae; + subtract_entropy(ent, deltae); + add_pseudo(ent, count * 8); + } + + partial_output: + memset(digest, 0, sizeof(digest)); + + if (returned != NULL) + *returned = (length - remain); + + UNLOCK(&ent->lock); + + return (ISC_R_SUCCESS); + + zeroize: + /* put the entropy we almost extracted back */ + add_entropy(ent, total); + memset(data, 0, length); + memset(digest, 0, sizeof(digest)); + if (returned != NULL) + *returned = 0; + + UNLOCK(&ent->lock); + + return (ISC_R_NOENTROPY); +} + +static void +isc_entropypool_init(isc_entropypool_t *pool) { + pool->cursor = RND_POOLWORDS - 1; + pool->entropy = 0; + pool->pseudo = 0; + pool->rotate = 0; + memset(pool->pool, 0, RND_POOLBYTES); +} + +static void +isc_entropypool_invalidate(isc_entropypool_t *pool) { + pool->cursor = 0; + pool->entropy = 0; + pool->pseudo = 0; + pool->rotate = 0; + memset(pool->pool, 0, RND_POOLBYTES); +} + +isc_result_t +isc_entropy_create(isc_mem_t *mctx, isc_entropy_t **entp) { + isc_result_t result; + isc_entropy_t *ent; + + REQUIRE(mctx != NULL); + REQUIRE(entp != NULL && *entp == NULL); + + ent = isc_mem_get(mctx, sizeof(isc_entropy_t)); + if (ent == NULL) + return (ISC_R_NOMEMORY); + + /* + * We need a lock. + */ + result = isc_mutex_init(&ent->lock); + if (result != ISC_R_SUCCESS) + goto errout; + + /* + * From here down, no failures will/can occur. + */ + ISC_LIST_INIT(ent->sources); + ent->nextsource = NULL; + ent->nsources = 0; + ent->mctx = NULL; + isc_mem_attach(mctx, &ent->mctx); + ent->refcnt = 1; + ent->initialized = 0; + ent->initcount = 0; + ent->magic = ENTROPY_MAGIC; + + isc_entropypool_init(&ent->pool); + + *entp = ent; + return (ISC_R_SUCCESS); + + errout: + isc_mem_put(mctx, ent, sizeof(isc_entropy_t)); + + return (result); +} + +/*! + * Requires "ent" be locked. + */ +static void +destroysource(isc_entropysource_t **sourcep) { + isc_entropysource_t *source; + isc_entropy_t *ent; + isc_cbsource_t *cbs; + + source = *sourcep; + *sourcep = NULL; + ent = source->ent; + + ISC_LIST_UNLINK(ent->sources, source, link); + ent->nextsource = NULL; + REQUIRE(ent->nsources > 0); + ent->nsources--; + + switch (source->type) { + case ENTROPY_SOURCETYPE_FILE: + if (! source->bad) + destroyfilesource(&source->sources.file); + break; + case ENTROPY_SOURCETYPE_USOCKET: + if (! source->bad) + destroyusocketsource(&source->sources.usocket); + break; + case ENTROPY_SOURCETYPE_SAMPLE: + samplequeue_release(ent, &source->sources.sample.samplequeue); + break; + case ENTROPY_SOURCETYPE_CALLBACK: + cbs = &source->sources.callback; + if (cbs->start_called && cbs->stopfunc != NULL) { + cbs->stopfunc(source, cbs->arg); + cbs->start_called = ISC_FALSE; + } + samplequeue_release(ent, &cbs->samplequeue); + break; + } + + memset(source, 0, sizeof(isc_entropysource_t)); + + isc_mem_put(ent->mctx, source, sizeof(isc_entropysource_t)); +} + +static inline isc_boolean_t +destroy_check(isc_entropy_t *ent) { + isc_entropysource_t *source; + + if (ent->refcnt > 0) + return (ISC_FALSE); + + source = ISC_LIST_HEAD(ent->sources); + while (source != NULL) { + switch (source->type) { + case ENTROPY_SOURCETYPE_FILE: + case ENTROPY_SOURCETYPE_USOCKET: + break; + default: + return (ISC_FALSE); + } + source = ISC_LIST_NEXT(source, link); + } + + return (ISC_TRUE); +} + +static void +destroy(isc_entropy_t **entp) { + isc_entropy_t *ent; + isc_entropysource_t *source; + isc_mem_t *mctx; + + REQUIRE(entp != NULL && *entp != NULL); + ent = *entp; + *entp = NULL; + + LOCK(&ent->lock); + + REQUIRE(ent->refcnt == 0); + + /* + * Here, detach non-sample sources. + */ + source = ISC_LIST_HEAD(ent->sources); + while (source != NULL) { + switch(source->type) { + case ENTROPY_SOURCETYPE_FILE: + case ENTROPY_SOURCETYPE_USOCKET: + destroysource(&source); + break; + } + source = ISC_LIST_HEAD(ent->sources); + } + + /* + * If there are other types of sources, we've found a bug. + */ + REQUIRE(ISC_LIST_EMPTY(ent->sources)); + + mctx = ent->mctx; + + isc_entropypool_invalidate(&ent->pool); + + UNLOCK(&ent->lock); + + DESTROYLOCK(&ent->lock); + + memset(ent, 0, sizeof(isc_entropy_t)); + isc_mem_put(mctx, ent, sizeof(isc_entropy_t)); + isc_mem_detach(&mctx); +} + +void +isc_entropy_destroysource(isc_entropysource_t **sourcep) { + isc_entropysource_t *source; + isc_entropy_t *ent; + isc_boolean_t killit; + + REQUIRE(sourcep != NULL); + REQUIRE(VALID_SOURCE(*sourcep)); + + source = *sourcep; + *sourcep = NULL; + + ent = source->ent; + REQUIRE(VALID_ENTROPY(ent)); + + LOCK(&ent->lock); + + destroysource(&source); + + killit = destroy_check(ent); + + UNLOCK(&ent->lock); + + if (killit) + destroy(&ent); +} + +isc_result_t +isc_entropy_createcallbacksource(isc_entropy_t *ent, + isc_entropystart_t start, + isc_entropyget_t get, + isc_entropystop_t stop, + void *arg, + isc_entropysource_t **sourcep) +{ + isc_result_t result; + isc_entropysource_t *source; + isc_cbsource_t *cbs; + + REQUIRE(VALID_ENTROPY(ent)); + REQUIRE(get != NULL); + REQUIRE(sourcep != NULL && *sourcep == NULL); + + LOCK(&ent->lock); + + source = isc_mem_get(ent->mctx, sizeof(isc_entropysource_t)); + if (source == NULL) { + result = ISC_R_NOMEMORY; + goto errout; + } + source->bad = ISC_FALSE; + + cbs = &source->sources.callback; + + result = samplesource_allocate(ent, &cbs->samplequeue); + if (result != ISC_R_SUCCESS) + goto errout; + + cbs->start_called = ISC_FALSE; + cbs->startfunc = start; + cbs->getfunc = get; + cbs->stopfunc = stop; + cbs->arg = arg; + + /* + * From here down, no failures can occur. + */ + source->magic = SOURCE_MAGIC; + source->type = ENTROPY_SOURCETYPE_CALLBACK; + source->ent = ent; + source->total = 0; + memset(source->name, 0, sizeof(source->name)); + ISC_LINK_INIT(source, link); + + /* + * Hook it into the entropy system. + */ + ISC_LIST_APPEND(ent->sources, source, link); + ent->nsources++; + + *sourcep = source; + + UNLOCK(&ent->lock); + return (ISC_R_SUCCESS); + + errout: + if (source != NULL) + isc_mem_put(ent->mctx, source, sizeof(isc_entropysource_t)); + + UNLOCK(&ent->lock); + + return (result); +} + +void +isc_entropy_stopcallbacksources(isc_entropy_t *ent) { + isc_entropysource_t *source; + isc_cbsource_t *cbs; + + REQUIRE(VALID_ENTROPY(ent)); + + LOCK(&ent->lock); + + source = ISC_LIST_HEAD(ent->sources); + while (source != NULL) { + if (source->type == ENTROPY_SOURCETYPE_CALLBACK) { + cbs = &source->sources.callback; + if (cbs->start_called && cbs->stopfunc != NULL) { + cbs->stopfunc(source, cbs->arg); + cbs->start_called = ISC_FALSE; + } + } + + source = ISC_LIST_NEXT(source, link); + } + + UNLOCK(&ent->lock); +} + +isc_result_t +isc_entropy_createsamplesource(isc_entropy_t *ent, + isc_entropysource_t **sourcep) +{ + isc_result_t result; + isc_entropysource_t *source; + sample_queue_t *sq; + + REQUIRE(VALID_ENTROPY(ent)); + REQUIRE(sourcep != NULL && *sourcep == NULL); + + LOCK(&ent->lock); + + source = isc_mem_get(ent->mctx, sizeof(isc_entropysource_t)); + if (source == NULL) { + result = ISC_R_NOMEMORY; + goto errout; + } + + sq = &source->sources.sample.samplequeue; + result = samplesource_allocate(ent, sq); + if (result != ISC_R_SUCCESS) + goto errout; + + /* + * From here down, no failures can occur. + */ + source->magic = SOURCE_MAGIC; + source->type = ENTROPY_SOURCETYPE_SAMPLE; + source->ent = ent; + source->total = 0; + memset(source->name, 0, sizeof(source->name)); + ISC_LINK_INIT(source, link); + + /* + * Hook it into the entropy system. + */ + ISC_LIST_APPEND(ent->sources, source, link); + ent->nsources++; + + *sourcep = source; + + UNLOCK(&ent->lock); + return (ISC_R_SUCCESS); + + errout: + if (source != NULL) + isc_mem_put(ent->mctx, source, sizeof(isc_entropysource_t)); + + UNLOCK(&ent->lock); + + return (result); +} + +/*! + * Add a sample, and return ISC_R_SUCCESS if the queue has become full, + * ISC_R_NOENTROPY if it has space remaining, and ISC_R_NOMORE if the + * queue was full when this function was called. + */ +static isc_result_t +addsample(sample_queue_t *sq, isc_uint32_t sample, isc_uint32_t extra) { + if (sq->nsamples >= RND_EVENTQSIZE) + return (ISC_R_NOMORE); + + sq->samples[sq->nsamples] = sample; + sq->extra[sq->nsamples] = extra; + sq->nsamples++; + + if (sq->nsamples >= RND_EVENTQSIZE) + return (ISC_R_QUEUEFULL); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_entropy_addsample(isc_entropysource_t *source, isc_uint32_t sample, + isc_uint32_t extra) +{ + isc_entropy_t *ent; + sample_queue_t *sq; + unsigned int entropy; + isc_result_t result; + + REQUIRE(VALID_SOURCE(source)); + + ent = source->ent; + + LOCK(&ent->lock); + + sq = &source->sources.sample.samplequeue; + result = addsample(sq, sample, extra); + if (result == ISC_R_QUEUEFULL) { + entropy = crunchsamples(ent, sq); + add_entropy(ent, entropy); + } + + UNLOCK(&ent->lock); + + return (result); +} + +isc_result_t +isc_entropy_addcallbacksample(isc_entropysource_t *source, isc_uint32_t sample, + isc_uint32_t extra) +{ + sample_queue_t *sq; + isc_result_t result; + + REQUIRE(VALID_SOURCE(source)); + REQUIRE(source->type == ENTROPY_SOURCETYPE_CALLBACK); + + sq = &source->sources.callback.samplequeue; + result = addsample(sq, sample, extra); + + return (result); +} + +void +isc_entropy_putdata(isc_entropy_t *ent, void *data, unsigned int length, + isc_uint32_t entropy) +{ + REQUIRE(VALID_ENTROPY(ent)); + + LOCK(&ent->lock); + + entropypool_adddata(ent, data, length, entropy); + + if (ent->initialized < THRESHOLD_BITS) + ent->initialized = THRESHOLD_BITS; + + UNLOCK(&ent->lock); +} + +static void +dumpstats(isc_entropy_t *ent, FILE *out) { + fprintf(out, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_ENTROPY, + ISC_MSG_ENTROPYSTATS, + "Entropy pool %p: refcnt %u cursor %u," + " rotate %u entropy %u pseudo %u nsources %u" + " nextsource %p initialized %u initcount %u\n"), + ent, ent->refcnt, + ent->pool.cursor, ent->pool.rotate, + ent->pool.entropy, ent->pool.pseudo, + ent->nsources, ent->nextsource, ent->initialized, + ent->initcount); +} + +/* + * This function ignores locking. Use at your own risk. + */ +void +isc_entropy_stats(isc_entropy_t *ent, FILE *out) { + REQUIRE(VALID_ENTROPY(ent)); + + LOCK(&ent->lock); + dumpstats(ent, out); + UNLOCK(&ent->lock); +} + +unsigned int +isc_entropy_status(isc_entropy_t *ent) { + unsigned int estimate; + + LOCK(&ent->lock); + estimate = ent->pool.entropy; + UNLOCK(&ent->lock); + + return estimate; +} + +void +isc_entropy_attach(isc_entropy_t *ent, isc_entropy_t **entp) { + REQUIRE(VALID_ENTROPY(ent)); + REQUIRE(entp != NULL && *entp == NULL); + + LOCK(&ent->lock); + + ent->refcnt++; + *entp = ent; + + UNLOCK(&ent->lock); +} + +void +isc_entropy_detach(isc_entropy_t **entp) { + isc_entropy_t *ent; + isc_boolean_t killit; + + REQUIRE(entp != NULL && VALID_ENTROPY(*entp)); + ent = *entp; + *entp = NULL; + + LOCK(&ent->lock); + + REQUIRE(ent->refcnt > 0); + ent->refcnt--; + + killit = destroy_check(ent); + + UNLOCK(&ent->lock); + + if (killit) + destroy(&ent); +} + +static isc_result_t +kbdstart(isc_entropysource_t *source, void *arg, isc_boolean_t blocking) { + /* + * The intent of "first" is to provide a warning message only once + * during the run of a program that might try to gather keyboard + * entropy multiple times. + */ + static isc_boolean_t first = ISC_TRUE; + + UNUSED(arg); + + if (! blocking) + return (ISC_R_NOENTROPY); + + if (first) { + if (source->warn_keyboard) + fprintf(stderr, "You must use the keyboard to create " + "entropy, since your system is lacking\n" + "/dev/random (or equivalent)\n\n"); + first = ISC_FALSE; + } + fprintf(stderr, "start typing:\n"); + + return (isc_keyboard_open(&source->kbd)); +} + +static void +kbdstop(isc_entropysource_t *source, void *arg) { + + UNUSED(arg); + + if (! isc_keyboard_canceled(&source->kbd)) + fprintf(stderr, "stop typing.\r\n"); + + (void)isc_keyboard_close(&source->kbd, 3); +} + +static isc_result_t +kbdget(isc_entropysource_t *source, void *arg, isc_boolean_t blocking) { + isc_result_t result; + isc_time_t t; + isc_uint32_t sample; + isc_uint32_t extra; + unsigned char c; + + UNUSED(arg); + + if (!blocking) + return (ISC_R_NOTBLOCKING); + + result = isc_keyboard_getchar(&source->kbd, &c); + if (result != ISC_R_SUCCESS) + return (result); + + TIME_NOW(&t); + + sample = isc_time_nanoseconds(&t); + extra = c; + + result = isc_entropy_addcallbacksample(source, sample, extra); + if (result != ISC_R_SUCCESS) { + fprintf(stderr, "\r\n"); + return (result); + } + + fprintf(stderr, "."); + fflush(stderr); + + return (result); +} + +isc_result_t +isc_entropy_usebestsource(isc_entropy_t *ectx, isc_entropysource_t **source, + const char *randomfile, int use_keyboard) +{ + isc_result_t result; + isc_result_t final_result = ISC_R_NOENTROPY; + isc_boolean_t userfile = ISC_TRUE; + + REQUIRE(VALID_ENTROPY(ectx)); + REQUIRE(source != NULL && *source == NULL); + REQUIRE(use_keyboard == ISC_ENTROPY_KEYBOARDYES || + use_keyboard == ISC_ENTROPY_KEYBOARDNO || + use_keyboard == ISC_ENTROPY_KEYBOARDMAYBE); + +#ifdef PATH_RANDOMDEV + if (randomfile == NULL) { + randomfile = PATH_RANDOMDEV; + userfile = ISC_FALSE; + } +#endif + + if (randomfile != NULL && use_keyboard != ISC_ENTROPY_KEYBOARDYES) { + result = isc_entropy_createfilesource(ectx, randomfile); + if (result == ISC_R_SUCCESS && + use_keyboard == ISC_ENTROPY_KEYBOARDMAYBE) + use_keyboard = ISC_ENTROPY_KEYBOARDNO; + if (result != ISC_R_SUCCESS && userfile) + return (result); + + final_result = result; + } + + if (use_keyboard != ISC_ENTROPY_KEYBOARDNO) { + result = isc_entropy_createcallbacksource(ectx, kbdstart, + kbdget, kbdstop, + NULL, source); + if (result == ISC_R_SUCCESS) + (*source)->warn_keyboard = + ISC_TF(use_keyboard == + ISC_ENTROPY_KEYBOARDMAYBE); + + if (final_result != ISC_R_SUCCESS) + final_result = result; + } + + /* + * final_result is ISC_R_SUCCESS if at least one source of entropy + * could be started, otherwise it is the error from the most recently + * failed operation (or ISC_R_NOENTROPY if PATH_RANDOMDEV is not + * defined and use_keyboard is ISC_ENTROPY_KEYBOARDNO). + */ + return (final_result); +} diff -urN src/contrib/ntp/lib/isc/error.c src.ntp/contrib/ntp/lib/isc/error.c --- src/contrib/ntp/lib/isc/error.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/error.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,106 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: error.c,v 1.21 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include + +#include +#include + +/*% Default unexpected callback. */ +static void +default_unexpected_callback(const char *, int, const char *, va_list) + ISC_FORMAT_PRINTF(3, 0); + +/*% Default fatal callback. */ +static void +default_fatal_callback(const char *, int, const char *, va_list) + ISC_FORMAT_PRINTF(3, 0); + +/*% unexpected_callback */ +static isc_errorcallback_t unexpected_callback = default_unexpected_callback; +static isc_errorcallback_t fatal_callback = default_fatal_callback; + +void +isc_error_setunexpected(isc_errorcallback_t cb) { + if (cb == NULL) + unexpected_callback = default_unexpected_callback; + else + unexpected_callback = cb; +} + +void +isc_error_setfatal(isc_errorcallback_t cb) { + if (cb == NULL) + fatal_callback = default_fatal_callback; + else + fatal_callback = cb; +} + +void +isc_error_unexpected(const char *file, int line, const char *format, ...) { + va_list args; + + va_start(args, format); + (unexpected_callback)(file, line, format, args); + va_end(args); +} + +void +isc_error_fatal(const char *file, int line, const char *format, ...) { + va_list args; + + va_start(args, format); + (fatal_callback)(file, line, format, args); + va_end(args); + abort(); +} + +void +isc_error_runtimecheck(const char *file, int line, const char *expression) { + isc_error_fatal(file, line, "RUNTIME_CHECK(%s) %s", expression, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); +} + +static void +default_unexpected_callback(const char *file, int line, const char *format, + va_list args) +{ + fprintf(stderr, "%s:%d: ", file, line); + vfprintf(stderr, format, args); + fprintf(stderr, "\n"); + fflush(stderr); +} + +static void +default_fatal_callback(const char *file, int line, const char *format, + va_list args) +{ + fprintf(stderr, "%s:%d: %s: ", file, line, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FATALERROR, "fatal error")); + vfprintf(stderr, format, args); + fprintf(stderr, "\n"); + fflush(stderr); +} diff -urN src/contrib/ntp/lib/isc/event.c src.ntp/contrib/ntp/lib/isc/event.c --- src/contrib/ntp/lib/isc/event.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/event.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,88 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: event.c,v 1.21 2007/06/19 23:47:17 tbox Exp $ */ + +/*! + * \file + * \author Principal Author: Bob Halley + */ + +#include + +#include +#include +#include + +/*** + *** Events. + ***/ + +static void +destroy(isc_event_t *event) { + isc_mem_t *mctx = event->ev_destroy_arg; + + isc_mem_put(mctx, event, event->ev_size); +} + +isc_event_t * +isc_event_allocate(isc_mem_t *mctx, void *sender, isc_eventtype_t type, + isc_taskaction_t action, const void *arg, size_t size) +{ + isc_event_t *event; + void *deconst_arg; + + REQUIRE(size >= sizeof(struct isc_event)); + REQUIRE(action != NULL); + + event = isc_mem_get(mctx, size); + if (event == NULL) + return (NULL); + + /* + * Removing the const attribute from "arg" is the best of two + * evils here. If the event->ev_arg member is made const, then + * it affects a great many users of the task/event subsystem + * which are not passing in an "arg" which starts its life as + * const. Changing isc_event_allocate() and isc_task_onshutdown() + * to not have "arg" prototyped as const (which is quite legitimate, + * because neither of those functions modify arg) can cause + * compiler whining anytime someone does want to use a const + * arg that they themselves never modify, such as with + * gcc -Wwrite-strings and using a string "arg". + */ + DE_CONST(arg, deconst_arg); + + ISC_EVENT_INIT(event, size, 0, NULL, type, action, deconst_arg, + sender, destroy, mctx); + + return (event); +} + +void +isc_event_free(isc_event_t **eventp) { + isc_event_t *event; + + REQUIRE(eventp != NULL); + event = *eventp; + REQUIRE(event != NULL); + + if (event->ev_destroy != NULL) + (event->ev_destroy)(event); + + *eventp = NULL; +} diff -urN src/contrib/ntp/lib/isc/fsaccess.c src.ntp/contrib/ntp/lib/isc/fsaccess.c --- src/contrib/ntp/lib/isc/fsaccess.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/fsaccess.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,102 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: fsaccess.c,v 1.10 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file + * \brief + * This file contains the OS-independent functionality of the API. + */ +#include +#include +#include + +/*! + * Shorthand. Maybe ISC__FSACCESS_PERMISSIONBITS should not even be in + * . Could check consistency with sizeof(isc_fsaccess_t) + * and the number of bits in each function. + */ +#define STEP (ISC__FSACCESS_PERMISSIONBITS) +#define GROUP (STEP) +#define OTHER (STEP * 2) + +void +isc_fsaccess_add(int trustee, int permission, isc_fsaccess_t *access) { + REQUIRE(trustee <= 0x7); + REQUIRE(permission <= 0xFF); + + if ((trustee & ISC_FSACCESS_OWNER) != 0) + *access |= permission; + + if ((trustee & ISC_FSACCESS_GROUP) != 0) + *access |= (permission << GROUP); + + if ((trustee & ISC_FSACCESS_OTHER) != 0) + *access |= (permission << OTHER); +} + +void +isc_fsaccess_remove(int trustee, int permission, isc_fsaccess_t *access) { + REQUIRE(trustee <= 0x7); + REQUIRE(permission <= 0xFF); + + + if ((trustee & ISC_FSACCESS_OWNER) != 0) + *access &= ~permission; + + if ((trustee & ISC_FSACCESS_GROUP) != 0) + *access &= ~(permission << GROUP); + + if ((trustee & ISC_FSACCESS_OTHER) != 0) + *access &= ~(permission << OTHER); +} + +static isc_result_t +check_bad_bits(isc_fsaccess_t access, isc_boolean_t is_dir) { + isc_fsaccess_t bits; + + /* + * Check for disallowed user bits. + */ + if (is_dir) + bits = ISC_FSACCESS_READ | + ISC_FSACCESS_WRITE | + ISC_FSACCESS_EXECUTE; + else + bits = ISC_FSACCESS_CREATECHILD | + ISC_FSACCESS_ACCESSCHILD | + ISC_FSACCESS_DELETECHILD | + ISC_FSACCESS_LISTDIRECTORY; + + /* + * Set group bad bits. + */ + bits |= bits << STEP; + /* + * Set other bad bits. + */ + bits |= bits << STEP; + + if ((access & bits) != 0) { + if (is_dir) + return (ISC_R_NOTFILE); + else + return (ISC_R_NOTDIRECTORY); + } + + return (ISC_R_SUCCESS); +} diff -urN src/contrib/ntp/lib/isc/hash.c src.ntp/contrib/ntp/lib/isc/hash.c --- src/contrib/ntp/lib/isc/hash.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/hash.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,390 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: hash.c,v 1.13.332.3 2009/05/07 23:47:12 tbox Exp $ */ + +/*! \file + * Some portion of this code was derived from universal hash function + * libraries of Rice University. +\section license UH Universal Hashing Library + +Copyright ((c)) 2002, Rice University +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: + + * Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + * Redistributions in binary form must reproduce the above + copyright notice, this list of conditions and the following + disclaimer in the documentation and/or other materials provided + with the distribution. + + * Neither the name of Rice University (RICE) nor the names of its + contributors may be used to endorse or promote products derived + from this software without specific prior written permission. + + +This software is provided by RICE and the contributors on an "as is" +basis, without any representations or warranties of any kind, express +or implied including, but not limited to, representations or +warranties of non-infringement, merchantability or fitness for a +particular purpose. In no event shall RICE or contributors be liable +for any direct, indirect, incidental, special, exemplary, or +consequential damages (including, but not limited to, procurement of +substitute goods or services; loss of use, data, or profits; or +business interruption) however caused and on any theory of liability, +whether in contract, strict liability, or tort (including negligence +or otherwise) arising in any way out of the use of this software, even +if advised of the possibility of such damage. +*/ + +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#define HASH_MAGIC ISC_MAGIC('H', 'a', 's', 'h') +#define VALID_HASH(h) ISC_MAGIC_VALID((h), HASH_MAGIC) + +/*% + * A large 32-bit prime number that specifies the range of the hash output. + */ +#define PRIME32 0xFFFFFFFB /* 2^32 - 5 */ + +/*@{*/ +/*% + * Types of random seed and hash accumulator. Perhaps they can be system + * dependent. + */ +typedef isc_uint32_t hash_accum_t; +typedef isc_uint16_t hash_random_t; +/*@}*/ + +/*% isc hash structure */ +struct isc_hash { + unsigned int magic; + isc_mem_t *mctx; + isc_mutex_t lock; + isc_boolean_t initialized; + isc_refcount_t refcnt; + isc_entropy_t *entropy; /*%< entropy source */ + unsigned int limit; /*%< upper limit of key length */ + size_t vectorlen; /*%< size of the vector below */ + hash_random_t *rndvector; /*%< random vector for universal hashing */ +}; + +static isc_mutex_t createlock; +static isc_once_t once = ISC_ONCE_INIT; +static isc_hash_t *hash = NULL; + +static unsigned char maptolower[] = { + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, + 0x40, 0x61, 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, + 0x68, 0x69, 0x6a, 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, + 0x70, 0x71, 0x72, 0x73, 0x74, 0x75, 0x76, 0x77, + 0x78, 0x79, 0x7a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, + 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, + 0x68, 0x69, 0x6a, 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, + 0x70, 0x71, 0x72, 0x73, 0x74, 0x75, 0x76, 0x77, + 0x78, 0x79, 0x7a, 0x7b, 0x7c, 0x7d, 0x7e, 0x7f, + 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, + 0x88, 0x89, 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f, + 0x90, 0x91, 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, + 0x98, 0x99, 0x9a, 0x9b, 0x9c, 0x9d, 0x9e, 0x9f, + 0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, + 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, + 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, + 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, 0xde, 0xdf, + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, + 0xf0, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, + 0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0xfd, 0xfe, 0xff +}; + +isc_result_t +isc_hash_ctxcreate(isc_mem_t *mctx, isc_entropy_t *entropy, + unsigned int limit, isc_hash_t **hctxp) +{ + isc_result_t result; + isc_hash_t *hctx; + size_t vlen; + hash_random_t *rv; + hash_accum_t overflow_limit; + + REQUIRE(mctx != NULL); + REQUIRE(hctxp != NULL && *hctxp == NULL); + + /* + * Overflow check. Since our implementation only does a modulo + * operation at the last stage of hash calculation, the accumulator + * must not overflow. + */ + overflow_limit = + 1 << (((sizeof(hash_accum_t) - sizeof(hash_random_t))) * 8); + if (overflow_limit < (limit + 1) * 0xff) + return (ISC_R_RANGE); + + hctx = isc_mem_get(mctx, sizeof(isc_hash_t)); + if (hctx == NULL) + return (ISC_R_NOMEMORY); + + vlen = sizeof(hash_random_t) * (limit + 1); + rv = isc_mem_get(mctx, vlen); + if (rv == NULL) { + result = ISC_R_NOMEMORY; + goto errout; + } + + /* + * We need a lock. + */ + result = isc_mutex_init(&hctx->lock); + if (result != ISC_R_SUCCESS) + goto errout; + + /* + * From here down, no failures will/can occur. + */ + hctx->magic = HASH_MAGIC; + hctx->mctx = NULL; + isc_mem_attach(mctx, &hctx->mctx); + hctx->initialized = ISC_FALSE; + result = isc_refcount_init(&hctx->refcnt, 1); + if (result != ISC_R_SUCCESS) + goto cleanup_lock; + hctx->entropy = NULL; + hctx->limit = limit; + hctx->vectorlen = vlen; + hctx->rndvector = rv; + + if (entropy != NULL) + isc_entropy_attach(entropy, &hctx->entropy); + + *hctxp = hctx; + return (ISC_R_SUCCESS); + + cleanup_lock: + DESTROYLOCK(&hctx->lock); + errout: + isc_mem_put(mctx, hctx, sizeof(isc_hash_t)); + if (rv != NULL) + isc_mem_put(mctx, rv, vlen); + + return (result); +} + +static void +initialize_lock(void) { + RUNTIME_CHECK(isc_mutex_init(&createlock) == ISC_R_SUCCESS); +} + +isc_result_t +isc_hash_create(isc_mem_t *mctx, isc_entropy_t *entropy, size_t limit) { + isc_result_t result = ISC_R_SUCCESS; + + REQUIRE(mctx != NULL); + INSIST(hash == NULL); + + RUNTIME_CHECK(isc_once_do(&once, initialize_lock) == ISC_R_SUCCESS); + + LOCK(&createlock); + + if (hash == NULL) + result = isc_hash_ctxcreate(mctx, entropy, limit, &hash); + + UNLOCK(&createlock); + + return (result); +} + +void +isc_hash_ctxinit(isc_hash_t *hctx) { + isc_result_t result; + + LOCK(&hctx->lock); + + if (hctx->initialized == ISC_TRUE) + goto out; + + if (hctx->entropy) { + result = isc_entropy_getdata(hctx->entropy, + hctx->rndvector, hctx->vectorlen, + NULL, 0); + INSIST(result == ISC_R_SUCCESS); + } else { + isc_uint32_t pr; + unsigned int i, copylen; + unsigned char *p; + + p = (unsigned char *)hctx->rndvector; + for (i = 0; i < hctx->vectorlen; i += copylen, p += copylen) { + isc_random_get(&pr); + if (i + sizeof(pr) <= hctx->vectorlen) + copylen = sizeof(pr); + else + copylen = hctx->vectorlen - i; + + memcpy(p, &pr, copylen); + } + INSIST(p == (unsigned char *)hctx->rndvector + + hctx->vectorlen); + } + + hctx->initialized = ISC_TRUE; + + out: + UNLOCK(&hctx->lock); +} + +void +isc_hash_init() { + INSIST(hash != NULL && VALID_HASH(hash)); + + isc_hash_ctxinit(hash); +} + +void +isc_hash_ctxattach(isc_hash_t *hctx, isc_hash_t **hctxp) { + REQUIRE(VALID_HASH(hctx)); + REQUIRE(hctxp != NULL && *hctxp == NULL); + + isc_refcount_increment(&hctx->refcnt, NULL); + *hctxp = hctx; +} + +static void +destroy(isc_hash_t **hctxp) { + isc_hash_t *hctx; + isc_mem_t *mctx; + + REQUIRE(hctxp != NULL && *hctxp != NULL); + hctx = *hctxp; + *hctxp = NULL; + + LOCK(&hctx->lock); + + isc_refcount_destroy(&hctx->refcnt); + + mctx = hctx->mctx; + if (hctx->entropy != NULL) + isc_entropy_detach(&hctx->entropy); + if (hctx->rndvector != NULL) + isc_mem_put(mctx, hctx->rndvector, hctx->vectorlen); + + UNLOCK(&hctx->lock); + + DESTROYLOCK(&hctx->lock); + + memset(hctx, 0, sizeof(isc_hash_t)); + isc_mem_put(mctx, hctx, sizeof(isc_hash_t)); + isc_mem_detach(&mctx); +} + +void +isc_hash_ctxdetach(isc_hash_t **hctxp) { + isc_hash_t *hctx; + unsigned int refs; + + REQUIRE(hctxp != NULL && VALID_HASH(*hctxp)); + hctx = *hctxp; + + isc_refcount_decrement(&hctx->refcnt, &refs); + if (refs == 0) + destroy(&hctx); + + *hctxp = NULL; +} + +void +isc_hash_destroy() { + unsigned int refs; + + INSIST(hash != NULL && VALID_HASH(hash)); + + isc_refcount_decrement(&hash->refcnt, &refs); + INSIST(refs == 0); + + destroy(&hash); +} + +static inline unsigned int +hash_calc(isc_hash_t *hctx, const unsigned char *key, unsigned int keylen, + isc_boolean_t case_sensitive) +{ + hash_accum_t partial_sum = 0; + hash_random_t *p = hctx->rndvector; + unsigned int i = 0; + + /* Make it sure that the hash context is initialized. */ + if (hctx->initialized == ISC_FALSE) + isc_hash_ctxinit(hctx); + + if (case_sensitive) { + for (i = 0; i < keylen; i++) + partial_sum += key[i] * (hash_accum_t)p[i]; + } else { + for (i = 0; i < keylen; i++) + partial_sum += maptolower[key[i]] * (hash_accum_t)p[i]; + } + + partial_sum += p[i]; + + return ((unsigned int)(partial_sum % PRIME32)); +} + +unsigned int +isc_hash_ctxcalc(isc_hash_t *hctx, const unsigned char *key, + unsigned int keylen, isc_boolean_t case_sensitive) +{ + REQUIRE(hctx != NULL && VALID_HASH(hctx)); + REQUIRE(keylen <= hctx->limit); + + return (hash_calc(hctx, key, keylen, case_sensitive)); +} + +unsigned int +isc_hash_calc(const unsigned char *key, unsigned int keylen, + isc_boolean_t case_sensitive) +{ + INSIST(hash != NULL && VALID_HASH(hash)); + REQUIRE(keylen <= hash->limit); + + return (hash_calc(hash, key, keylen, case_sensitive)); +} diff -urN src/contrib/ntp/lib/isc/heap.c src.ntp/contrib/ntp/lib/isc/heap.c --- src/contrib/ntp/lib/isc/heap.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/heap.c 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,262 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1997-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: heap.c,v 1.37 2007/10/19 17:15:53 explorer Exp $ */ + +/*! \file + * Heap implementation of priority queues adapted from the following: + * + * \li "Introduction to Algorithms," Cormen, Leiserson, and Rivest, + * MIT Press / McGraw Hill, 1990, ISBN 0-262-03141-8, chapter 7. + * + * \li "Algorithms," Second Edition, Sedgewick, Addison-Wesley, 1988, + * ISBN 0-201-06673-4, chapter 11. + */ + +#include + +#include +#include +#include +#include /* Required for memcpy. */ +#include + +/*@{*/ +/*% + * Note: to make heap_parent and heap_left easy to compute, the first + * element of the heap array is not used; i.e. heap subscripts are 1-based, + * not 0-based. The parent is index/2, and the left-child is index*2. + * The right child is index*2+1. + */ +#define heap_parent(i) ((i) >> 1) +#define heap_left(i) ((i) << 1) +/*@}*/ + +#define SIZE_INCREMENT 1024 + +#define HEAP_MAGIC ISC_MAGIC('H', 'E', 'A', 'P') +#define VALID_HEAP(h) ISC_MAGIC_VALID(h, HEAP_MAGIC) + +/*% + * When the heap is in a consistent state, the following invariant + * holds true: for every element i > 1, heap_parent(i) has a priority + * higher than or equal to that of i. + */ +#define HEAPCONDITION(i) ((i) == 1 || \ + ! heap->compare(heap->array[(i)], \ + heap->array[heap_parent(i)])) + +/*% ISC heap structure. */ +struct isc_heap { + unsigned int magic; + isc_mem_t * mctx; + unsigned int size; + unsigned int size_increment; + unsigned int last; + void **array; + isc_heapcompare_t compare; + isc_heapindex_t index; +}; + +isc_result_t +isc_heap_create(isc_mem_t *mctx, isc_heapcompare_t compare, + isc_heapindex_t index, unsigned int size_increment, + isc_heap_t **heapp) +{ + isc_heap_t *heap; + + REQUIRE(heapp != NULL && *heapp == NULL); + REQUIRE(compare != NULL); + + heap = isc_mem_get(mctx, sizeof(*heap)); + if (heap == NULL) + return (ISC_R_NOMEMORY); + heap->magic = HEAP_MAGIC; + heap->mctx = mctx; + heap->size = 0; + if (size_increment == 0) + heap->size_increment = SIZE_INCREMENT; + else + heap->size_increment = size_increment; + heap->last = 0; + heap->array = NULL; + heap->compare = compare; + heap->index = index; + + *heapp = heap; + + return (ISC_R_SUCCESS); +} + +void +isc_heap_destroy(isc_heap_t **heapp) { + isc_heap_t *heap; + + REQUIRE(heapp != NULL); + heap = *heapp; + REQUIRE(VALID_HEAP(heap)); + + if (heap->array != NULL) + isc_mem_put(heap->mctx, heap->array, + heap->size * sizeof(void *)); + heap->magic = 0; + isc_mem_put(heap->mctx, heap, sizeof(*heap)); + + *heapp = NULL; +} + +static isc_boolean_t +resize(isc_heap_t *heap) { + void **new_array; + size_t new_size; + + REQUIRE(VALID_HEAP(heap)); + + new_size = heap->size + heap->size_increment; + new_array = isc_mem_get(heap->mctx, new_size * sizeof(void *)); + if (new_array == NULL) + return (ISC_FALSE); + if (heap->array != NULL) { + memcpy(new_array, heap->array, heap->size * sizeof(void *)); + isc_mem_put(heap->mctx, heap->array, + heap->size * sizeof(void *)); + } + heap->size = new_size; + heap->array = new_array; + + return (ISC_TRUE); +} + +static void +float_up(isc_heap_t *heap, unsigned int i, void *elt) { + unsigned int p; + + for (p = heap_parent(i) ; + i > 1 && heap->compare(elt, heap->array[p]) ; + i = p, p = heap_parent(i)) { + heap->array[i] = heap->array[p]; + if (heap->index != NULL) + (heap->index)(heap->array[i], i); + } + heap->array[i] = elt; + if (heap->index != NULL) + (heap->index)(heap->array[i], i); + + INSIST(HEAPCONDITION(i)); +} + +static void +sink_down(isc_heap_t *heap, unsigned int i, void *elt) { + unsigned int j, size, half_size; + size = heap->last; + half_size = size / 2; + while (i <= half_size) { + /* Find the smallest of the (at most) two children. */ + j = heap_left(i); + if (j < size && heap->compare(heap->array[j+1], + heap->array[j])) + j++; + if (heap->compare(elt, heap->array[j])) + break; + heap->array[i] = heap->array[j]; + if (heap->index != NULL) + (heap->index)(heap->array[i], i); + i = j; + } + heap->array[i] = elt; + if (heap->index != NULL) + (heap->index)(heap->array[i], i); + + INSIST(HEAPCONDITION(i)); +} + +isc_result_t +isc_heap_insert(isc_heap_t *heap, void *elt) { + unsigned int i; + + REQUIRE(VALID_HEAP(heap)); + + i = ++heap->last; + if (heap->last >= heap->size && !resize(heap)) + return (ISC_R_NOMEMORY); + + float_up(heap, i, elt); + + return (ISC_R_SUCCESS); +} + +void +isc_heap_delete(isc_heap_t *heap, unsigned int index) { + void *elt; + isc_boolean_t less; + + REQUIRE(VALID_HEAP(heap)); + REQUIRE(index >= 1 && index <= heap->last); + + if (index == heap->last) { + heap->array[heap->last] = NULL; + heap->last--; + } else { + elt = heap->array[heap->last]; + heap->array[heap->last] = NULL; + heap->last--; + + less = heap->compare(elt, heap->array[index]); + heap->array[index] = elt; + if (less) + float_up(heap, index, heap->array[index]); + else + sink_down(heap, index, heap->array[index]); + } +} + +void +isc_heap_increased(isc_heap_t *heap, unsigned int index) { + REQUIRE(VALID_HEAP(heap)); + REQUIRE(index >= 1 && index <= heap->last); + + float_up(heap, index, heap->array[index]); +} + +void +isc_heap_decreased(isc_heap_t *heap, unsigned int index) { + REQUIRE(VALID_HEAP(heap)); + REQUIRE(index >= 1 && index <= heap->last); + + sink_down(heap, index, heap->array[index]); +} + +void * +isc_heap_element(isc_heap_t *heap, unsigned int index) { + REQUIRE(VALID_HEAP(heap)); + REQUIRE(index >= 1); + + if (index <= heap->last) + return (heap->array[index]); + return (NULL); +} + +void +isc_heap_foreach(isc_heap_t *heap, isc_heapaction_t action, void *uap) { + unsigned int i; + + REQUIRE(VALID_HEAP(heap)); + REQUIRE(action != NULL); + + for (i = 1 ; i <= heap->last ; i++) + (action)(heap->array[i], uap); +} diff -urN src/contrib/ntp/lib/isc/hex.c src.ntp/contrib/ntp/lib/isc/hex.c --- src/contrib/ntp/lib/isc/hex.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/hex.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,201 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: hex.c,v 1.20 2008/09/25 04:02:39 tbox Exp $ */ + +/*! \file */ + +#include + +#include + +#include +#include +#include +#include +#include + +#define RETERR(x) do { \ + isc_result_t _r = (x); \ + if (_r != ISC_R_SUCCESS) \ + return (_r); \ + } while (0) + + +/* + * BEW: These static functions are copied from lib/dns/rdata.c. + */ +static isc_result_t +str_totext(const char *source, isc_buffer_t *target); + +static isc_result_t +mem_tobuffer(isc_buffer_t *target, void *base, unsigned int length); + +static const char hex[] = "0123456789ABCDEF"; + +isc_result_t +isc_hex_totext(isc_region_t *source, int wordlength, + const char *wordbreak, isc_buffer_t *target) +{ + char buf[3]; + unsigned int loops = 0; + + if (wordlength < 2) + wordlength = 2; + + memset(buf, 0, sizeof(buf)); + while (source->length > 0) { + buf[0] = hex[(source->base[0] >> 4) & 0xf]; + buf[1] = hex[(source->base[0]) & 0xf]; + RETERR(str_totext(buf, target)); + isc_region_consume(source, 1); + + loops++; + if (source->length != 0 && + (int)((loops + 1) * 2) >= wordlength) + { + loops = 0; + RETERR(str_totext(wordbreak, target)); + } + } + return (ISC_R_SUCCESS); +} + +/*% + * State of a hex decoding process in progress. + */ +typedef struct { + int length; /*%< Desired length of binary data or -1 */ + isc_buffer_t *target; /*%< Buffer for resulting binary data */ + int digits; /*%< Number of buffered hex digits */ + int val[2]; +} hex_decode_ctx_t; + +static inline void +hex_decode_init(hex_decode_ctx_t *ctx, int length, isc_buffer_t *target) +{ + ctx->digits = 0; + ctx->length = length; + ctx->target = target; +} + +static inline isc_result_t +hex_decode_char(hex_decode_ctx_t *ctx, int c) { + char *s; + + if ((s = strchr(hex, toupper(c))) == NULL) + return (ISC_R_BADHEX); + ctx->val[ctx->digits++] = s - hex; + if (ctx->digits == 2) { + unsigned char num; + + num = (ctx->val[0] << 4) + (ctx->val[1]); + RETERR(mem_tobuffer(ctx->target, &num, 1)); + if (ctx->length >= 0) { + if (ctx->length == 0) + return (ISC_R_BADHEX); + else + ctx->length -= 1; + } + ctx->digits = 0; + } + return (ISC_R_SUCCESS); +} + +static inline isc_result_t +hex_decode_finish(hex_decode_ctx_t *ctx) { + if (ctx->length > 0) + return (ISC_R_UNEXPECTEDEND); + if (ctx->digits != 0) + return (ISC_R_BADHEX); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_hex_tobuffer(isc_lex_t *lexer, isc_buffer_t *target, int length) { + hex_decode_ctx_t ctx; + isc_textregion_t *tr; + isc_token_t token; + isc_boolean_t eol; + + hex_decode_init(&ctx, length, target); + + while (ctx.length != 0) { + unsigned int i; + + if (length > 0) + eol = ISC_FALSE; + else + eol = ISC_TRUE; + RETERR(isc_lex_getmastertoken(lexer, &token, + isc_tokentype_string, eol)); + if (token.type != isc_tokentype_string) + break; + tr = &token.value.as_textregion; + for (i = 0; i < tr->length; i++) + RETERR(hex_decode_char(&ctx, tr->base[i])); + } + if (ctx.length < 0) + isc_lex_ungettoken(lexer, &token); + RETERR(hex_decode_finish(&ctx)); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_hex_decodestring(const char *cstr, isc_buffer_t *target) { + hex_decode_ctx_t ctx; + + hex_decode_init(&ctx, -1, target); + for (;;) { + int c = *cstr++; + if (c == '\0') + break; + if (c == ' ' || c == '\t' || c == '\n' || c== '\r') + continue; + RETERR(hex_decode_char(&ctx, c)); + } + RETERR(hex_decode_finish(&ctx)); + return (ISC_R_SUCCESS); +} + +static isc_result_t +str_totext(const char *source, isc_buffer_t *target) { + unsigned int l; + isc_region_t region; + + isc_buffer_availableregion(target, ®ion); + l = strlen(source); + + if (l > region.length) + return (ISC_R_NOSPACE); + + memcpy(region.base, source, l); + isc_buffer_add(target, l); + return (ISC_R_SUCCESS); +} + +static isc_result_t +mem_tobuffer(isc_buffer_t *target, void *base, unsigned int length) { + isc_region_t tr; + + isc_buffer_availableregion(target, &tr); + if (length > tr.length) + return (ISC_R_NOSPACE); + memcpy(tr.base, base, length); + isc_buffer_add(target, length); + return (ISC_R_SUCCESS); +} diff -urN src/contrib/ntp/lib/isc/hmacmd5.c src.ntp/contrib/ntp/lib/isc/hmacmd5.c --- src/contrib/ntp/lib/isc/hmacmd5.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/hmacmd5.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,118 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: hmacmd5.c,v 1.14 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file + * This code implements the HMAC-MD5 keyed hash algorithm + * described in RFC2104. + */ + +#include "config.h" + +#include +#include +#include +#include +#include +#include + +#define PADLEN 64 +#define IPAD 0x36 +#define OPAD 0x5C + +/*! + * Start HMAC-MD5 process. Initialize an md5 context and digest the key. + */ +void +isc_hmacmd5_init(isc_hmacmd5_t *ctx, const unsigned char *key, + unsigned int len) +{ + unsigned char ipad[PADLEN]; + int i; + + memset(ctx->key, 0, sizeof(ctx->key)); + if (len > sizeof(ctx->key)) { + isc_md5_t md5ctx; + isc_md5_init(&md5ctx); + isc_md5_update(&md5ctx, key, len); + isc_md5_final(&md5ctx, ctx->key); + } else + memcpy(ctx->key, key, len); + + isc_md5_init(&ctx->md5ctx); + memset(ipad, IPAD, sizeof(ipad)); + for (i = 0; i < PADLEN; i++) + ipad[i] ^= ctx->key[i]; + isc_md5_update(&ctx->md5ctx, ipad, sizeof(ipad)); +} + +void +isc_hmacmd5_invalidate(isc_hmacmd5_t *ctx) { + isc_md5_invalidate(&ctx->md5ctx); + memset(ctx->key, 0, sizeof(ctx->key)); +} + +/*! + * Update context to reflect the concatenation of another buffer full + * of bytes. + */ +void +isc_hmacmd5_update(isc_hmacmd5_t *ctx, const unsigned char *buf, + unsigned int len) +{ + isc_md5_update(&ctx->md5ctx, buf, len); +} + +/*! + * Compute signature - finalize MD5 operation and reapply MD5. + */ +void +isc_hmacmd5_sign(isc_hmacmd5_t *ctx, unsigned char *digest) { + unsigned char opad[PADLEN]; + int i; + + isc_md5_final(&ctx->md5ctx, digest); + + memset(opad, OPAD, sizeof(opad)); + for (i = 0; i < PADLEN; i++) + opad[i] ^= ctx->key[i]; + + isc_md5_init(&ctx->md5ctx); + isc_md5_update(&ctx->md5ctx, opad, sizeof(opad)); + isc_md5_update(&ctx->md5ctx, digest, ISC_MD5_DIGESTLENGTH); + isc_md5_final(&ctx->md5ctx, digest); + isc_hmacmd5_invalidate(ctx); +} + +/*! + * Verify signature - finalize MD5 operation and reapply MD5, then + * compare to the supplied digest. + */ +isc_boolean_t +isc_hmacmd5_verify(isc_hmacmd5_t *ctx, unsigned char *digest) { + return (isc_hmacmd5_verify2(ctx, digest, ISC_MD5_DIGESTLENGTH)); +} + +isc_boolean_t +isc_hmacmd5_verify2(isc_hmacmd5_t *ctx, unsigned char *digest, size_t len) { + unsigned char newdigest[ISC_MD5_DIGESTLENGTH]; + + REQUIRE(len <= ISC_MD5_DIGESTLENGTH); + isc_hmacmd5_sign(ctx, newdigest); + return (ISC_TF(memcmp(digest, newdigest, len) == 0)); +} diff -urN src/contrib/ntp/lib/isc/hmacsha.c src.ntp/contrib/ntp/lib/isc/hmacsha.c --- src/contrib/ntp/lib/isc/hmacsha.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/hmacsha.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,438 @@ +/* + * Copyright (C) 2005-2007 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: hmacsha.c,v 1.8 2007/08/27 03:27:53 marka Exp $ */ + +/* + * This code implements the HMAC-SHA1, HMAC-SHA224, HMAC-SHA256, HMAC-SHA384 + * and HMAC-SHA512 keyed hash algorithm described in RFC 2104 and + * draft-ietf-dnsext-tsig-sha-01.txt. + */ + +#include "config.h" + +#include +#include +#include +#include +#include +#include +#include + +#define IPAD 0x36 +#define OPAD 0x5C + +/* + * Start HMAC-SHA1 process. Initialize an sha1 context and digest the key. + */ +void +isc_hmacsha1_init(isc_hmacsha1_t *ctx, const unsigned char *key, + unsigned int len) +{ + unsigned char ipad[ISC_SHA1_BLOCK_LENGTH]; + unsigned int i; + + memset(ctx->key, 0, sizeof(ctx->key)); + if (len > sizeof(ctx->key)) { + isc_sha1_t sha1ctx; + isc_sha1_init(&sha1ctx); + isc_sha1_update(&sha1ctx, key, len); + isc_sha1_final(&sha1ctx, ctx->key); + } else + memcpy(ctx->key, key, len); + + isc_sha1_init(&ctx->sha1ctx); + memset(ipad, IPAD, sizeof(ipad)); + for (i = 0; i < ISC_SHA1_BLOCK_LENGTH; i++) + ipad[i] ^= ctx->key[i]; + isc_sha1_update(&ctx->sha1ctx, ipad, sizeof(ipad)); +} + +void +isc_hmacsha1_invalidate(isc_hmacsha1_t *ctx) { + isc_sha1_invalidate(&ctx->sha1ctx); + memset(ctx->key, 0, sizeof(ctx->key)); + memset(ctx, 0, sizeof(ctx)); +} + +/* + * Update context to reflect the concatenation of another buffer full + * of bytes. + */ +void +isc_hmacsha1_update(isc_hmacsha1_t *ctx, const unsigned char *buf, + unsigned int len) +{ + isc_sha1_update(&ctx->sha1ctx, buf, len); +} + +/* + * Compute signature - finalize SHA1 operation and reapply SHA1. + */ +void +isc_hmacsha1_sign(isc_hmacsha1_t *ctx, unsigned char *digest, size_t len) { + unsigned char opad[ISC_SHA1_BLOCK_LENGTH]; + unsigned char newdigest[ISC_SHA1_DIGESTLENGTH]; + unsigned int i; + + REQUIRE(len <= ISC_SHA1_DIGESTLENGTH); + isc_sha1_final(&ctx->sha1ctx, newdigest); + + memset(opad, OPAD, sizeof(opad)); + for (i = 0; i < ISC_SHA1_BLOCK_LENGTH; i++) + opad[i] ^= ctx->key[i]; + + isc_sha1_init(&ctx->sha1ctx); + isc_sha1_update(&ctx->sha1ctx, opad, sizeof(opad)); + isc_sha1_update(&ctx->sha1ctx, newdigest, ISC_SHA1_DIGESTLENGTH); + isc_sha1_final(&ctx->sha1ctx, newdigest); + isc_hmacsha1_invalidate(ctx); + memcpy(digest, newdigest, len); + memset(newdigest, 0, sizeof(newdigest)); +} + +/* + * Verify signature - finalize SHA1 operation and reapply SHA1, then + * compare to the supplied digest. + */ +isc_boolean_t +isc_hmacsha1_verify(isc_hmacsha1_t *ctx, unsigned char *digest, size_t len) { + unsigned char newdigest[ISC_SHA1_DIGESTLENGTH]; + + REQUIRE(len <= ISC_SHA1_DIGESTLENGTH); + isc_hmacsha1_sign(ctx, newdigest, ISC_SHA1_DIGESTLENGTH); + return (ISC_TF(memcmp(digest, newdigest, len) == 0)); +} + +/* + * Start HMAC-SHA224 process. Initialize an sha224 context and digest the key. + */ +void +isc_hmacsha224_init(isc_hmacsha224_t *ctx, const unsigned char *key, + unsigned int len) +{ + unsigned char ipad[ISC_SHA224_BLOCK_LENGTH]; + unsigned int i; + + memset(ctx->key, 0, sizeof(ctx->key)); + if (len > sizeof(ctx->key)) { + isc_sha224_t sha224ctx; + isc_sha224_init(&sha224ctx); + isc_sha224_update(&sha224ctx, key, len); + isc_sha224_final(ctx->key, &sha224ctx); + } else + memcpy(ctx->key, key, len); + + isc_sha224_init(&ctx->sha224ctx); + memset(ipad, IPAD, sizeof(ipad)); + for (i = 0; i < ISC_SHA224_BLOCK_LENGTH; i++) + ipad[i] ^= ctx->key[i]; + isc_sha224_update(&ctx->sha224ctx, ipad, sizeof(ipad)); +} + +void +isc_hmacsha224_invalidate(isc_hmacsha224_t *ctx) { + memset(ctx->key, 0, sizeof(ctx->key)); + memset(ctx, 0, sizeof(ctx)); +} + +/* + * Update context to reflect the concatenation of another buffer full + * of bytes. + */ +void +isc_hmacsha224_update(isc_hmacsha224_t *ctx, const unsigned char *buf, + unsigned int len) +{ + isc_sha224_update(&ctx->sha224ctx, buf, len); +} + +/* + * Compute signature - finalize SHA224 operation and reapply SHA224. + */ +void +isc_hmacsha224_sign(isc_hmacsha224_t *ctx, unsigned char *digest, size_t len) { + unsigned char opad[ISC_SHA224_BLOCK_LENGTH]; + unsigned char newdigest[ISC_SHA224_DIGESTLENGTH]; + unsigned int i; + + REQUIRE(len <= ISC_SHA224_DIGESTLENGTH); + isc_sha224_final(newdigest, &ctx->sha224ctx); + + memset(opad, OPAD, sizeof(opad)); + for (i = 0; i < ISC_SHA224_BLOCK_LENGTH; i++) + opad[i] ^= ctx->key[i]; + + isc_sha224_init(&ctx->sha224ctx); + isc_sha224_update(&ctx->sha224ctx, opad, sizeof(opad)); + isc_sha224_update(&ctx->sha224ctx, newdigest, ISC_SHA224_DIGESTLENGTH); + isc_sha224_final(newdigest, &ctx->sha224ctx); + memcpy(digest, newdigest, len); + memset(newdigest, 0, sizeof(newdigest)); +} + +/* + * Verify signature - finalize SHA224 operation and reapply SHA224, then + * compare to the supplied digest. + */ +isc_boolean_t +isc_hmacsha224_verify(isc_hmacsha224_t *ctx, unsigned char *digest, size_t len) { + unsigned char newdigest[ISC_SHA224_DIGESTLENGTH]; + + REQUIRE(len <= ISC_SHA224_DIGESTLENGTH); + isc_hmacsha224_sign(ctx, newdigest, ISC_SHA224_DIGESTLENGTH); + return (ISC_TF(memcmp(digest, newdigest, len) == 0)); +} + +/* + * Start HMAC-SHA256 process. Initialize an sha256 context and digest the key. + */ +void +isc_hmacsha256_init(isc_hmacsha256_t *ctx, const unsigned char *key, + unsigned int len) +{ + unsigned char ipad[ISC_SHA256_BLOCK_LENGTH]; + unsigned int i; + + memset(ctx->key, 0, sizeof(ctx->key)); + if (len > sizeof(ctx->key)) { + isc_sha256_t sha256ctx; + isc_sha256_init(&sha256ctx); + isc_sha256_update(&sha256ctx, key, len); + isc_sha256_final(ctx->key, &sha256ctx); + } else + memcpy(ctx->key, key, len); + + isc_sha256_init(&ctx->sha256ctx); + memset(ipad, IPAD, sizeof(ipad)); + for (i = 0; i < ISC_SHA256_BLOCK_LENGTH; i++) + ipad[i] ^= ctx->key[i]; + isc_sha256_update(&ctx->sha256ctx, ipad, sizeof(ipad)); +} + +void +isc_hmacsha256_invalidate(isc_hmacsha256_t *ctx) { + memset(ctx->key, 0, sizeof(ctx->key)); + memset(ctx, 0, sizeof(ctx)); +} + +/* + * Update context to reflect the concatenation of another buffer full + * of bytes. + */ +void +isc_hmacsha256_update(isc_hmacsha256_t *ctx, const unsigned char *buf, + unsigned int len) +{ + isc_sha256_update(&ctx->sha256ctx, buf, len); +} + +/* + * Compute signature - finalize SHA256 operation and reapply SHA256. + */ +void +isc_hmacsha256_sign(isc_hmacsha256_t *ctx, unsigned char *digest, size_t len) { + unsigned char opad[ISC_SHA256_BLOCK_LENGTH]; + unsigned char newdigest[ISC_SHA256_DIGESTLENGTH]; + unsigned int i; + + REQUIRE(len <= ISC_SHA256_DIGESTLENGTH); + isc_sha256_final(newdigest, &ctx->sha256ctx); + + memset(opad, OPAD, sizeof(opad)); + for (i = 0; i < ISC_SHA256_BLOCK_LENGTH; i++) + opad[i] ^= ctx->key[i]; + + isc_sha256_init(&ctx->sha256ctx); + isc_sha256_update(&ctx->sha256ctx, opad, sizeof(opad)); + isc_sha256_update(&ctx->sha256ctx, newdigest, ISC_SHA256_DIGESTLENGTH); + isc_sha256_final(newdigest, &ctx->sha256ctx); + memcpy(digest, newdigest, len); + memset(newdigest, 0, sizeof(newdigest)); +} + +/* + * Verify signature - finalize SHA256 operation and reapply SHA256, then + * compare to the supplied digest. + */ +isc_boolean_t +isc_hmacsha256_verify(isc_hmacsha256_t *ctx, unsigned char *digest, size_t len) { + unsigned char newdigest[ISC_SHA256_DIGESTLENGTH]; + + REQUIRE(len <= ISC_SHA256_DIGESTLENGTH); + isc_hmacsha256_sign(ctx, newdigest, ISC_SHA256_DIGESTLENGTH); + return (ISC_TF(memcmp(digest, newdigest, len) == 0)); +} + +/* + * Start HMAC-SHA384 process. Initialize an sha384 context and digest the key. + */ +void +isc_hmacsha384_init(isc_hmacsha384_t *ctx, const unsigned char *key, + unsigned int len) +{ + unsigned char ipad[ISC_SHA384_BLOCK_LENGTH]; + unsigned int i; + + memset(ctx->key, 0, sizeof(ctx->key)); + if (len > sizeof(ctx->key)) { + isc_sha384_t sha384ctx; + isc_sha384_init(&sha384ctx); + isc_sha384_update(&sha384ctx, key, len); + isc_sha384_final(ctx->key, &sha384ctx); + } else + memcpy(ctx->key, key, len); + + isc_sha384_init(&ctx->sha384ctx); + memset(ipad, IPAD, sizeof(ipad)); + for (i = 0; i < ISC_SHA384_BLOCK_LENGTH; i++) + ipad[i] ^= ctx->key[i]; + isc_sha384_update(&ctx->sha384ctx, ipad, sizeof(ipad)); +} + +void +isc_hmacsha384_invalidate(isc_hmacsha384_t *ctx) { + memset(ctx->key, 0, sizeof(ctx->key)); + memset(ctx, 0, sizeof(ctx)); +} + +/* + * Update context to reflect the concatenation of another buffer full + * of bytes. + */ +void +isc_hmacsha384_update(isc_hmacsha384_t *ctx, const unsigned char *buf, + unsigned int len) +{ + isc_sha384_update(&ctx->sha384ctx, buf, len); +} + +/* + * Compute signature - finalize SHA384 operation and reapply SHA384. + */ +void +isc_hmacsha384_sign(isc_hmacsha384_t *ctx, unsigned char *digest, size_t len) { + unsigned char opad[ISC_SHA384_BLOCK_LENGTH]; + unsigned char newdigest[ISC_SHA384_DIGESTLENGTH]; + unsigned int i; + + REQUIRE(len <= ISC_SHA384_DIGESTLENGTH); + isc_sha384_final(newdigest, &ctx->sha384ctx); + + memset(opad, OPAD, sizeof(opad)); + for (i = 0; i < ISC_SHA384_BLOCK_LENGTH; i++) + opad[i] ^= ctx->key[i]; + + isc_sha384_init(&ctx->sha384ctx); + isc_sha384_update(&ctx->sha384ctx, opad, sizeof(opad)); + isc_sha384_update(&ctx->sha384ctx, newdigest, ISC_SHA384_DIGESTLENGTH); + isc_sha384_final(newdigest, &ctx->sha384ctx); + memcpy(digest, newdigest, len); + memset(newdigest, 0, sizeof(newdigest)); +} + +/* + * Verify signature - finalize SHA384 operation and reapply SHA384, then + * compare to the supplied digest. + */ +isc_boolean_t +isc_hmacsha384_verify(isc_hmacsha384_t *ctx, unsigned char *digest, size_t len) { + unsigned char newdigest[ISC_SHA384_DIGESTLENGTH]; + + REQUIRE(len <= ISC_SHA384_DIGESTLENGTH); + isc_hmacsha384_sign(ctx, newdigest, ISC_SHA384_DIGESTLENGTH); + return (ISC_TF(memcmp(digest, newdigest, len) == 0)); +} + +/* + * Start HMAC-SHA512 process. Initialize an sha512 context and digest the key. + */ +void +isc_hmacsha512_init(isc_hmacsha512_t *ctx, const unsigned char *key, + unsigned int len) +{ + unsigned char ipad[ISC_SHA512_BLOCK_LENGTH]; + unsigned int i; + + memset(ctx->key, 0, sizeof(ctx->key)); + if (len > sizeof(ctx->key)) { + isc_sha512_t sha512ctx; + isc_sha512_init(&sha512ctx); + isc_sha512_update(&sha512ctx, key, len); + isc_sha512_final(ctx->key, &sha512ctx); + } else + memcpy(ctx->key, key, len); + + isc_sha512_init(&ctx->sha512ctx); + memset(ipad, IPAD, sizeof(ipad)); + for (i = 0; i < ISC_SHA512_BLOCK_LENGTH; i++) + ipad[i] ^= ctx->key[i]; + isc_sha512_update(&ctx->sha512ctx, ipad, sizeof(ipad)); +} + +void +isc_hmacsha512_invalidate(isc_hmacsha512_t *ctx) { + memset(ctx->key, 0, sizeof(ctx->key)); + memset(ctx, 0, sizeof(ctx)); +} + +/* + * Update context to reflect the concatenation of another buffer full + * of bytes. + */ +void +isc_hmacsha512_update(isc_hmacsha512_t *ctx, const unsigned char *buf, + unsigned int len) +{ + isc_sha512_update(&ctx->sha512ctx, buf, len); +} + +/* + * Compute signature - finalize SHA512 operation and reapply SHA512. + */ +void +isc_hmacsha512_sign(isc_hmacsha512_t *ctx, unsigned char *digest, size_t len) { + unsigned char opad[ISC_SHA512_BLOCK_LENGTH]; + unsigned char newdigest[ISC_SHA512_DIGESTLENGTH]; + unsigned int i; + + REQUIRE(len <= ISC_SHA512_DIGESTLENGTH); + isc_sha512_final(newdigest, &ctx->sha512ctx); + + memset(opad, OPAD, sizeof(opad)); + for (i = 0; i < ISC_SHA512_BLOCK_LENGTH; i++) + opad[i] ^= ctx->key[i]; + + isc_sha512_init(&ctx->sha512ctx); + isc_sha512_update(&ctx->sha512ctx, opad, sizeof(opad)); + isc_sha512_update(&ctx->sha512ctx, newdigest, ISC_SHA512_DIGESTLENGTH); + isc_sha512_final(newdigest, &ctx->sha512ctx); + memcpy(digest, newdigest, len); + memset(newdigest, 0, sizeof(newdigest)); +} + +/* + * Verify signature - finalize SHA512 operation and reapply SHA512, then + * compare to the supplied digest. + */ +isc_boolean_t +isc_hmacsha512_verify(isc_hmacsha512_t *ctx, unsigned char *digest, size_t len) { + unsigned char newdigest[ISC_SHA512_DIGESTLENGTH]; + + REQUIRE(len <= ISC_SHA512_DIGESTLENGTH); + isc_hmacsha512_sign(ctx, newdigest, ISC_SHA512_DIGESTLENGTH); + return (ISC_TF(memcmp(digest, newdigest, len) == 0)); +} diff -urN src/contrib/ntp/lib/isc/httpd.c src.ntp/contrib/ntp/lib/isc/httpd.c --- src/contrib/ntp/lib/isc/httpd.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/httpd.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,987 @@ +/* + * Copyright (C) 2006-2008 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: httpd.c,v 1.16 2008/08/08 05:06:49 marka Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include +#include +#include +#include +#include + +#include + +/*% + * TODO: + * + * o Put in better checks to make certain things are passed in correctly. + * This includes a magic number for externally-visible structures, + * checking for NULL-ness before dereferencing, etc. + * o Make the URL processing external functions which will fill-in a buffer + * structure we provide, or return an error and we will render a generic + * page and close the client. + */ + +#define MSHUTTINGDOWN(cm) ((cm->flags & ISC_HTTPDMGR_FLAGSHUTTINGDOWN) != 0) +#define MSETSHUTTINGDOWN(cm) (cm->flags |= ISC_HTTPDMGR_FLAGSHUTTINGDOWN) + +#ifdef DEBUG_HTTPD +#define ENTER(x) do { fprintf(stderr, "ENTER %s\n", (x)); } while (0) +#define EXIT(x) do { fprintf(stderr, "EXIT %s\n", (x)); } while (0) +#define NOTICE(x) do { fprintf(stderr, "NOTICE %s\n", (x)); } while (0) +#else +#define ENTER(x) do { } while(0) +#define EXIT(x) do { } while(0) +#define NOTICE(x) do { } while(0) +#endif + +#define HTTP_RECVLEN 1024 +#define HTTP_SENDGROW 1024 +#define HTTP_SEND_MAXLEN 10240 + +/*% + * HTTP urls. These are the URLs we manage, and the function to call to + * provide the data for it. We pass in the base url (so the same function + * can handle multiple requests), and a structure to fill in to return a + * result to the client. We also pass in a pointer to be filled in for + * the data cleanup function. + */ +struct isc_httpdurl { + char *url; + isc_httpdaction_t *action; + void *action_arg; + ISC_LINK(isc_httpdurl_t) link; +}; + +#define HTTPD_CLOSE 0x0001 /* Got a Connection: close header */ +#define HTTPD_FOUNDHOST 0x0002 /* Got a Host: header */ + +/*% http client */ +struct isc_httpd { + isc_httpdmgr_t *mgr; /*%< our parent */ + ISC_LINK(isc_httpd_t) link; + unsigned int state; + isc_socket_t *sock; + + /*% + * Received data state. + */ + char recvbuf[HTTP_RECVLEN]; /*%< receive buffer */ + isc_uint32_t recvlen; /*%< length recv'd */ + unsigned int method; + char *url; + char *querystring; + char *protocol; + + /* + * Flags on the httpd client. + */ + int flags; + + /*% + * Transmit data state. + * + * This is the data buffer we will transmit. + * + * This free function pointer is filled in by the rendering function + * we call. The free function is called after the data is transmitted + * to the client. + * + * The bufflist is the list of buffers we are currently transmitting. + * The headerdata is where we render our headers to. If we run out of + * space when rendering a header, we will change the size of our + * buffer. We will not free it until we are finished, and will + * allocate an additional HTTP_SENDGROW bytes per header space grow. + * + * We currently use two buffers total, one for the headers (which + * we manage) and another for the client to fill in (which it manages, + * it provides the space for it, etc) -- we will pass that buffer + * structure back to the caller, who is responsible for managing the + * space it may have allocated as backing store for it. This second + * buffer is bodybuffer, and we only allocate the buffer itself, not + * the backing store. + */ + isc_bufferlist_t bufflist; + char *headerdata; /*%< send header buf */ + unsigned int headerlen; /*%< current header buffer size */ + isc_buffer_t headerbuffer; + + const char *mimetype; + unsigned int retcode; + const char *retmsg; + isc_buffer_t bodybuffer; + isc_httpdfree_t *freecb; + void *freecb_arg; +}; + +/*% lightweight socket manager for httpd output */ +struct isc_httpdmgr { + isc_mem_t *mctx; + isc_socket_t *sock; /*%< listening socket */ + isc_task_t *task; /*%< owning task */ + isc_timermgr_t *timermgr; + + isc_httpdclientok_t *client_ok; /*%< client validator */ + isc_httpdondestroy_t *ondestroy; /*%< cleanup callback */ + void *cb_arg; /*%< argument for the above */ + + unsigned int flags; + ISC_LIST(isc_httpd_t) running; /*%< running clients */ + + isc_mutex_t lock; + + ISC_LIST(isc_httpdurl_t) urls; /*%< urls we manage */ + isc_httpdaction_t *render_404; +}; + +/*% + * HTTP methods. + */ +#define ISC_HTTPD_METHODUNKNOWN 0 +#define ISC_HTTPD_METHODGET 1 +#define ISC_HTTPD_METHODPOST 2 + +/*% + * Client states. + * + * _IDLE The client is not doing anything at all. This state should + * only occur just after creation, and just before being + * destroyed. + * + * _RECV The client is waiting for data after issuing a socket recv(). + * + * _RECVDONE Data has been received, and is being processed. + * + * _SEND All data for a response has completed, and a reply was + * sent via a socket send() call. + * + * _SENDDONE Send is completed. + * + * Badly formatted state table: + * + * IDLE -> RECV when client has a recv() queued. + * + * RECV -> RECVDONE when recvdone event received. + * + * RECVDONE -> SEND if the data for a reply is at hand. + * + * SEND -> RECV when a senddone event was received. + * + * At any time -> RECV on error. If RECV fails, the client will + * self-destroy, closing the socket and freeing memory. + */ +#define ISC_HTTPD_STATEIDLE 0 +#define ISC_HTTPD_STATERECV 1 +#define ISC_HTTPD_STATERECVDONE 2 +#define ISC_HTTPD_STATESEND 3 +#define ISC_HTTPD_STATESENDDONE 4 + +#define ISC_HTTPD_ISRECV(c) ((c)->state == ISC_HTTPD_STATERECV) +#define ISC_HTTPD_ISRECVDONE(c) ((c)->state == ISC_HTTPD_STATERECVDONE) +#define ISC_HTTPD_ISSEND(c) ((c)->state == ISC_HTTPD_STATESEND) +#define ISC_HTTPD_ISSENDDONE(c) ((c)->state == ISC_HTTPD_STATESENDDONE) + +/*% + * Overall magic test that means we're not idle. + */ +#define ISC_HTTPD_SETRECV(c) ((c)->state = ISC_HTTPD_STATERECV) +#define ISC_HTTPD_SETRECVDONE(c) ((c)->state = ISC_HTTPD_STATERECVDONE) +#define ISC_HTTPD_SETSEND(c) ((c)->state = ISC_HTTPD_STATESEND) +#define ISC_HTTPD_SETSENDDONE(c) ((c)->state = ISC_HTTPD_STATESENDDONE) + +static void isc_httpd_accept(isc_task_t *, isc_event_t *); +static void isc_httpd_recvdone(isc_task_t *, isc_event_t *); +static void isc_httpd_senddone(isc_task_t *, isc_event_t *); +static void destroy_client(isc_httpd_t **); +static isc_result_t process_request(isc_httpd_t *, int); +static void httpdmgr_destroy(isc_httpdmgr_t *); +static isc_result_t grow_headerspace(isc_httpd_t *); +static void reset_client(isc_httpd_t *httpd); +static isc_result_t render_404(const char *, const char *, + void *, + unsigned int *, const char **, + const char **, isc_buffer_t *, + isc_httpdfree_t **, void **); + +static void +destroy_client(isc_httpd_t **httpdp) +{ + isc_httpd_t *httpd = *httpdp; + isc_httpdmgr_t *httpdmgr = httpd->mgr; + + *httpdp = NULL; + + LOCK(&httpdmgr->lock); + + isc_socket_detach(&httpd->sock); + ISC_LIST_UNLINK(httpdmgr->running, httpd, link); + + if (httpd->headerlen > 0) + isc_mem_put(httpdmgr->mctx, httpd->headerdata, + httpd->headerlen); + + isc_mem_put(httpdmgr->mctx, httpd, sizeof(isc_httpd_t)); + + UNLOCK(&httpdmgr->lock); + + httpdmgr_destroy(httpdmgr); +} + +isc_result_t +isc_httpdmgr_create(isc_mem_t *mctx, isc_socket_t *sock, isc_task_t *task, + isc_httpdclientok_t *client_ok, + isc_httpdondestroy_t *ondestroy, void *cb_arg, + isc_timermgr_t *tmgr, isc_httpdmgr_t **httpdp) +{ + isc_result_t result; + isc_httpdmgr_t *httpd; + + REQUIRE(mctx != NULL); + REQUIRE(sock != NULL); + REQUIRE(task != NULL); + REQUIRE(tmgr != NULL); + REQUIRE(httpdp != NULL && *httpdp == NULL); + + httpd = isc_mem_get(mctx, sizeof(isc_httpdmgr_t)); + if (httpd == NULL) + return (ISC_R_NOMEMORY); + + result = isc_mutex_init(&httpd->lock); + if (result != ISC_R_SUCCESS) { + isc_mem_put(mctx, httpd, sizeof(isc_httpdmgr_t)); + return (result); + } + httpd->mctx = NULL; + isc_mem_attach(mctx, &httpd->mctx); + httpd->sock = NULL; + isc_socket_attach(sock, &httpd->sock); + httpd->task = NULL; + isc_task_attach(task, &httpd->task); + httpd->timermgr = tmgr; /* XXXMLG no attach function? */ + httpd->client_ok = client_ok; + httpd->ondestroy = ondestroy; + httpd->cb_arg = cb_arg; + + ISC_LIST_INIT(httpd->running); + ISC_LIST_INIT(httpd->urls); + + /* XXXMLG ignore errors on isc_socket_listen() */ + result = isc_socket_listen(sock, SOMAXCONN); + if (result != ISC_R_SUCCESS) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_socket_listen() failed: %s", + isc_result_totext(result)); + goto cleanup; + } + + (void)isc_socket_filter(sock, "httpready"); + + result = isc_socket_accept(sock, task, isc_httpd_accept, httpd); + if (result != ISC_R_SUCCESS) + goto cleanup; + + httpd->render_404 = render_404; + + *httpdp = httpd; + return (ISC_R_SUCCESS); + + cleanup: + isc_task_detach(&httpd->task); + isc_socket_detach(&httpd->sock); + isc_mem_detach(&httpd->mctx); + isc_mutex_destroy(&httpd->lock); + isc_mem_put(mctx, httpd, sizeof(isc_httpdmgr_t)); + return (result); +} + +static void +httpdmgr_destroy(isc_httpdmgr_t *httpdmgr) +{ + isc_mem_t *mctx; + isc_httpdurl_t *url; + + ENTER("httpdmgr_destroy"); + + LOCK(&httpdmgr->lock); + + if (!MSHUTTINGDOWN(httpdmgr)) { + NOTICE("httpdmgr_destroy not shutting down yet"); + UNLOCK(&httpdmgr->lock); + return; + } + + /* + * If all clients are not shut down, don't do anything yet. + */ + if (!ISC_LIST_EMPTY(httpdmgr->running)) { + NOTICE("httpdmgr_destroy clients still active"); + UNLOCK(&httpdmgr->lock); + return; + } + + NOTICE("httpdmgr_destroy detaching socket, task, and timermgr"); + + isc_socket_detach(&httpdmgr->sock); + isc_task_detach(&httpdmgr->task); + httpdmgr->timermgr = NULL; + + /* + * Clear out the list of all actions we know about. Just free the + * memory. + */ + url = ISC_LIST_HEAD(httpdmgr->urls); + while (url != NULL) { + isc_mem_free(httpdmgr->mctx, url->url); + ISC_LIST_UNLINK(httpdmgr->urls, url, link); + isc_mem_put(httpdmgr->mctx, url, sizeof(isc_httpdurl_t)); + url = ISC_LIST_HEAD(httpdmgr->urls); + } + + UNLOCK(&httpdmgr->lock); + isc_mutex_destroy(&httpdmgr->lock); + + if (httpdmgr->ondestroy != NULL) + (httpdmgr->ondestroy)(httpdmgr->cb_arg); + + mctx = httpdmgr->mctx; + isc_mem_putanddetach(&mctx, httpdmgr, sizeof(isc_httpdmgr_t)); + + EXIT("httpdmgr_destroy"); +} + +#define LENGTHOK(s) (httpd->recvbuf - (s) < (int)httpd->recvlen) +#define BUFLENOK(s) (httpd->recvbuf - (s) < HTTP_RECVLEN) + +static isc_result_t +process_request(isc_httpd_t *httpd, int length) +{ + char *s; + char *p; + int delim; + + ENTER("request"); + + httpd->recvlen += length; + + httpd->recvbuf[httpd->recvlen] = 0; + + /* + * If we don't find a blank line in our buffer, return that we need + * more data. + */ + s = strstr(httpd->recvbuf, "\r\n\r\n"); + delim = 1; + if (s == NULL) { + s = strstr(httpd->recvbuf, "\n\n"); + delim = 2; + } + if (s == NULL) + return (ISC_R_NOTFOUND); + + /* + * Determine if this is a POST or GET method. Any other values will + * cause an error to be returned. + */ + if (strncmp(httpd->recvbuf, "GET ", 4) == 0) { + httpd->method = ISC_HTTPD_METHODGET; + p = httpd->recvbuf + 4; + } else if (strncmp(httpd->recvbuf, "POST ", 5) == 0) { + httpd->method = ISC_HTTPD_METHODPOST; + p = httpd->recvbuf + 5; + } else { + return (ISC_R_RANGE); + } + + /* + * From now on, p is the start of our buffer. + */ + + /* + * Extract the URL. + */ + s = p; + while (LENGTHOK(s) && BUFLENOK(s) && + (*s != '\n' && *s != '\r' && *s != '\0' && *s != ' ')) + s++; + if (!LENGTHOK(s)) + return (ISC_R_NOTFOUND); + if (!BUFLENOK(s)) + return (ISC_R_NOMEMORY); + *s = 0; + + /* + * Make the URL relative. + */ + if ((strncmp(p, "http:/", 6) == 0) + || (strncmp(p, "https:/", 7) == 0)) { + /* Skip first / */ + while (*p != '/' && *p != 0) + p++; + if (*p == 0) + return (ISC_R_RANGE); + p++; + /* Skip second / */ + while (*p != '/' && *p != 0) + p++; + if (*p == 0) + return (ISC_R_RANGE); + p++; + /* Find third / */ + while (*p != '/' && *p != 0) + p++; + if (*p == 0) { + p--; + *p = '/'; + } + } + + httpd->url = p; + p = s + delim; + s = p; + + /* + * Now, see if there is a ? mark in the URL. If so, this is + * part of the query string, and we will split it from the URL. + */ + httpd->querystring = strchr(httpd->url, '?'); + if (httpd->querystring != NULL) { + *(httpd->querystring) = 0; + httpd->querystring++; + } + + /* + * Extract the HTTP/1.X protocol. We will bounce on anything but + * HTTP/1.1 for now. + */ + while (LENGTHOK(s) && BUFLENOK(s) && + (*s != '\n' && *s != '\r' && *s != '\0')) + s++; + if (!LENGTHOK(s)) + return (ISC_R_NOTFOUND); + if (!BUFLENOK(s)) + return (ISC_R_NOMEMORY); + *s = 0; + if ((strncmp(p, "HTTP/1.0", 8) != 0) + && (strncmp(p, "HTTP/1.1", 8) != 0)) + return (ISC_R_RANGE); + httpd->protocol = p; + p = s + 1; + s = p; + + if (strstr(s, "Connection: close") != NULL) + httpd->flags |= HTTPD_CLOSE; + + if (strstr(s, "Host: ") != NULL) + httpd->flags |= HTTPD_FOUNDHOST; + + /* + * Standards compliance hooks here. + */ + if (strcmp(httpd->protocol, "HTTP/1.1") == 0 + && ((httpd->flags & HTTPD_FOUNDHOST) == 0)) + return (ISC_R_RANGE); + + EXIT("request"); + + return (ISC_R_SUCCESS); +} + +static void +isc_httpd_accept(isc_task_t *task, isc_event_t *ev) +{ + isc_result_t result; + isc_httpdmgr_t *httpdmgr = ev->ev_arg; + isc_httpd_t *httpd; + isc_region_t r; + isc_socket_newconnev_t *nev = (isc_socket_newconnev_t *)ev; + isc_sockaddr_t peeraddr; + + ENTER("accept"); + + LOCK(&httpdmgr->lock); + if (MSHUTTINGDOWN(httpdmgr)) { + NOTICE("accept shutting down, goto out"); + goto out; + } + + if (nev->result == ISC_R_CANCELED) { + NOTICE("accept canceled, goto out"); + goto out; + } + + if (nev->result != ISC_R_SUCCESS) { + /* XXXMLG log failure */ + NOTICE("accept returned failure, goto requeue"); + goto requeue; + } + + (void)isc_socket_getpeername(nev->newsocket, &peeraddr); + if (httpdmgr->client_ok != NULL && + !(httpdmgr->client_ok)(&peeraddr, httpdmgr->cb_arg)) { + isc_socket_detach(&nev->newsocket); + goto requeue; + } + + httpd = isc_mem_get(httpdmgr->mctx, sizeof(isc_httpd_t)); + if (httpd == NULL) { + /* XXXMLG log failure */ + NOTICE("accept failed to allocate memory, goto requeue"); + isc_socket_detach(&nev->newsocket); + goto requeue; + } + + httpd->mgr = httpdmgr; + ISC_LINK_INIT(httpd, link); + ISC_LIST_APPEND(httpdmgr->running, httpd, link); + ISC_HTTPD_SETRECV(httpd); + httpd->sock = nev->newsocket; + isc_socket_setname(httpd->sock, "httpd", NULL); + httpd->flags = 0; + + /* + * Initialize the buffer for our headers. + */ + httpd->headerdata = isc_mem_get(httpdmgr->mctx, HTTP_SENDGROW); + if (httpd->headerdata == NULL) { + isc_mem_put(httpdmgr->mctx, httpd, sizeof(isc_httpd_t)); + isc_socket_detach(&nev->newsocket); + goto requeue; + } + httpd->headerlen = HTTP_SENDGROW; + isc_buffer_init(&httpd->headerbuffer, httpd->headerdata, + httpd->headerlen); + + ISC_LIST_INIT(httpd->bufflist); + + isc_buffer_initnull(&httpd->bodybuffer); + reset_client(httpd); + + r.base = (unsigned char *)httpd->recvbuf; + r.length = HTTP_RECVLEN - 1; + result = isc_socket_recv(httpd->sock, &r, 1, task, isc_httpd_recvdone, + httpd); + NOTICE("accept queued recv on socket"); + + requeue: + result = isc_socket_accept(httpdmgr->sock, task, isc_httpd_accept, + httpdmgr); + if (result != ISC_R_SUCCESS) { + /* XXXMLG what to do? Log failure... */ + NOTICE("accept could not reaccept due to failure"); + } + + out: + UNLOCK(&httpdmgr->lock); + + httpdmgr_destroy(httpdmgr); + + isc_event_free(&ev); + + EXIT("accept"); +} + +static isc_result_t +render_404(const char *url, const char *querystring, + void *arg, + unsigned int *retcode, const char **retmsg, + const char **mimetype, isc_buffer_t *b, + isc_httpdfree_t **freecb, void **freecb_args) +{ + static char msg[] = "No such URL."; + + UNUSED(url); + UNUSED(querystring); + UNUSED(arg); + + *retcode = 404; + *retmsg = "No such URL"; + *mimetype = "text/plain"; + isc_buffer_reinit(b, msg, strlen(msg)); + isc_buffer_add(b, strlen(msg)); + *freecb = NULL; + *freecb_args = NULL; + + return (ISC_R_SUCCESS); +} + +static void +isc_httpd_recvdone(isc_task_t *task, isc_event_t *ev) +{ + isc_region_t r; + isc_result_t result; + isc_httpd_t *httpd = ev->ev_arg; + isc_socketevent_t *sev = (isc_socketevent_t *)ev; + isc_httpdurl_t *url; + isc_time_t now; + char datebuf[32]; /* Only need 30, but safety first */ + + ENTER("recv"); + + INSIST(ISC_HTTPD_ISRECV(httpd)); + + if (sev->result != ISC_R_SUCCESS) { + NOTICE("recv destroying client"); + destroy_client(&httpd); + goto out; + } + + result = process_request(httpd, sev->n); + if (result == ISC_R_NOTFOUND) { + if (httpd->recvlen >= HTTP_RECVLEN - 1) { + destroy_client(&httpd); + goto out; + } + r.base = (unsigned char *)httpd->recvbuf + httpd->recvlen; + r.length = HTTP_RECVLEN - httpd->recvlen - 1; + result = isc_socket_recv(httpd->sock, &r, 1, task, + isc_httpd_recvdone, httpd); + goto out; + } else if (result != ISC_R_SUCCESS) { + destroy_client(&httpd); + goto out; + } + + ISC_HTTPD_SETSEND(httpd); + + /* + * XXXMLG Call function here. Provide an add-header function + * which will append the common headers to a response we generate. + */ + isc_buffer_initnull(&httpd->bodybuffer); + isc_time_now(&now); + isc_time_formathttptimestamp(&now, datebuf, sizeof(datebuf)); + url = ISC_LIST_HEAD(httpd->mgr->urls); + while (url != NULL) { + if (strcmp(httpd->url, url->url) == 0) + break; + url = ISC_LIST_NEXT(url, link); + } + if (url == NULL) + result = httpd->mgr->render_404(httpd->url, httpd->querystring, + NULL, + &httpd->retcode, + &httpd->retmsg, + &httpd->mimetype, + &httpd->bodybuffer, + &httpd->freecb, + &httpd->freecb_arg); + else + result = url->action(httpd->url, httpd->querystring, + url->action_arg, + &httpd->retcode, &httpd->retmsg, + &httpd->mimetype, &httpd->bodybuffer, + &httpd->freecb, &httpd->freecb_arg); + if (result != ISC_R_SUCCESS) { + destroy_client(&httpd); + goto out; + } + + isc_httpd_response(httpd); + isc_httpd_addheader(httpd, "Content-Type", httpd->mimetype); + isc_httpd_addheader(httpd, "Date", datebuf); + isc_httpd_addheader(httpd, "Expires", datebuf); + isc_httpd_addheader(httpd, "Last-Modified", datebuf); + isc_httpd_addheader(httpd, "Pragma: no-cache", NULL); + isc_httpd_addheader(httpd, "Cache-Control: no-cache", NULL); + isc_httpd_addheader(httpd, "Server: libisc", NULL); + isc_httpd_addheaderuint(httpd, "Content-Length", + isc_buffer_usedlength(&httpd->bodybuffer)); + isc_httpd_endheaders(httpd); /* done */ + + ISC_LIST_APPEND(httpd->bufflist, &httpd->headerbuffer, link); + /* + * Link the data buffer into our send queue, should we have any data + * rendered into it. If no data is present, we won't do anything + * with the buffer. + */ + if (isc_buffer_length(&httpd->bodybuffer) > 0) + ISC_LIST_APPEND(httpd->bufflist, &httpd->bodybuffer, link); + + result = isc_socket_sendv(httpd->sock, &httpd->bufflist, task, + isc_httpd_senddone, httpd); + + out: + isc_event_free(&ev); + EXIT("recv"); +} + +void +isc_httpdmgr_shutdown(isc_httpdmgr_t **httpdmgrp) +{ + isc_httpdmgr_t *httpdmgr; + isc_httpd_t *httpd; + httpdmgr = *httpdmgrp; + *httpdmgrp = NULL; + + ENTER("isc_httpdmgr_shutdown"); + + LOCK(&httpdmgr->lock); + + MSETSHUTTINGDOWN(httpdmgr); + + isc_socket_cancel(httpdmgr->sock, httpdmgr->task, ISC_SOCKCANCEL_ALL); + + httpd = ISC_LIST_HEAD(httpdmgr->running); + while (httpd != NULL) { + isc_socket_cancel(httpd->sock, httpdmgr->task, + ISC_SOCKCANCEL_ALL); + httpd = ISC_LIST_NEXT(httpd, link); + } + + UNLOCK(&httpdmgr->lock); + + EXIT("isc_httpdmgr_shutdown"); +} + +static isc_result_t +grow_headerspace(isc_httpd_t *httpd) +{ + char *newspace; + unsigned int newlen; + isc_region_t r; + + newlen = httpd->headerlen + HTTP_SENDGROW; + if (newlen > HTTP_SEND_MAXLEN) + return (ISC_R_NOSPACE); + + newspace = isc_mem_get(httpd->mgr->mctx, newlen); + if (newspace == NULL) + return (ISC_R_NOMEMORY); + isc_buffer_region(&httpd->headerbuffer, &r); + isc_buffer_reinit(&httpd->headerbuffer, newspace, newlen); + + isc_mem_put(httpd->mgr->mctx, r.base, r.length); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_httpd_response(isc_httpd_t *httpd) +{ + isc_result_t result; + unsigned int needlen; + + needlen = strlen(httpd->protocol) + 1; /* protocol + space */ + needlen += 3 + 1; /* room for response code, always 3 bytes */ + needlen += strlen(httpd->retmsg) + 2; /* return msg + CRLF */ + + if (isc_buffer_availablelength(&httpd->headerbuffer) < needlen) { + result = grow_headerspace(httpd); + if (result != ISC_R_SUCCESS) + return (result); + } + + sprintf(isc_buffer_used(&httpd->headerbuffer), "%s %03d %s\r\n", + httpd->protocol, httpd->retcode, httpd->retmsg); + isc_buffer_add(&httpd->headerbuffer, needlen); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_httpd_addheader(isc_httpd_t *httpd, const char *name, + const char *val) +{ + isc_result_t result; + unsigned int needlen; + + needlen = strlen(name); /* name itself */ + if (val != NULL) + needlen += 2 + strlen(val); /* : and val */ + needlen += 2; /* CRLF */ + + if (isc_buffer_availablelength(&httpd->headerbuffer) < needlen) { + result = grow_headerspace(httpd); + if (result != ISC_R_SUCCESS) + return (result); + } + + if (val != NULL) + sprintf(isc_buffer_used(&httpd->headerbuffer), + "%s: %s\r\n", name, val); + else + sprintf(isc_buffer_used(&httpd->headerbuffer), + "%s\r\n", name); + + isc_buffer_add(&httpd->headerbuffer, needlen); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_httpd_endheaders(isc_httpd_t *httpd) +{ + isc_result_t result; + + if (isc_buffer_availablelength(&httpd->headerbuffer) < 2) { + result = grow_headerspace(httpd); + if (result != ISC_R_SUCCESS) + return (result); + } + + sprintf(isc_buffer_used(&httpd->headerbuffer), "\r\n"); + isc_buffer_add(&httpd->headerbuffer, 2); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_httpd_addheaderuint(isc_httpd_t *httpd, const char *name, int val) { + isc_result_t result; + unsigned int needlen; + char buf[sizeof "18446744073709551616"]; + + sprintf(buf, "%d", val); + + needlen = strlen(name); /* name itself */ + needlen += 2 + strlen(buf); /* : and val */ + needlen += 2; /* CRLF */ + + if (isc_buffer_availablelength(&httpd->headerbuffer) < needlen) { + result = grow_headerspace(httpd); + if (result != ISC_R_SUCCESS) + return (result); + } + + sprintf(isc_buffer_used(&httpd->headerbuffer), + "%s: %s\r\n", name, buf); + + isc_buffer_add(&httpd->headerbuffer, needlen); + + return (ISC_R_SUCCESS); +} + +static void +isc_httpd_senddone(isc_task_t *task, isc_event_t *ev) +{ + isc_httpd_t *httpd = ev->ev_arg; + isc_region_t r; + isc_result_t result; + isc_socketevent_t *sev = (isc_socketevent_t *)ev; + + ENTER("senddone"); + INSIST(ISC_HTTPD_ISSEND(httpd)); + + /* + * First, unlink our header buffer from the socket's bufflist. This + * is sort of an evil hack, since we know our buffer will be there, + * and we know it's address, so we can just remove it directly. + */ + NOTICE("senddone unlinked header"); + ISC_LIST_UNLINK(sev->bufferlist, &httpd->headerbuffer, link); + + /* + * We will always want to clean up our receive buffer, even if we + * got an error on send or we are shutting down. + * + * We will pass in the buffer only if there is data in it. If + * there is no data, we will pass in a NULL. + */ + if (httpd->freecb != NULL) { + isc_buffer_t *b = NULL; + if (isc_buffer_length(&httpd->bodybuffer) > 0) + b = &httpd->bodybuffer; + httpd->freecb(b, httpd->freecb_arg); + NOTICE("senddone free callback performed"); + } + if (ISC_LINK_LINKED(&httpd->bodybuffer, link)) { + ISC_LIST_UNLINK(sev->bufferlist, &httpd->bodybuffer, link); + NOTICE("senddone body buffer unlinked"); + } + + if (sev->result != ISC_R_SUCCESS) { + destroy_client(&httpd); + goto out; + } + + if ((httpd->flags & HTTPD_CLOSE) != 0) { + destroy_client(&httpd); + goto out; + } + + ISC_HTTPD_SETRECV(httpd); + + NOTICE("senddone restarting recv on socket"); + + reset_client(httpd); + + r.base = (unsigned char *)httpd->recvbuf; + r.length = HTTP_RECVLEN - 1; + result = isc_socket_recv(httpd->sock, &r, 1, task, isc_httpd_recvdone, + httpd); + +out: + isc_event_free(&ev); + EXIT("senddone"); +} + +static void +reset_client(isc_httpd_t *httpd) +{ + /* + * Catch errors here. We MUST be in RECV mode, and we MUST NOT have + * any outstanding buffers. If we have buffers, we have a leak. + */ + INSIST(ISC_HTTPD_ISRECV(httpd)); + INSIST(!ISC_LINK_LINKED(&httpd->headerbuffer, link)); + INSIST(!ISC_LINK_LINKED(&httpd->bodybuffer, link)); + + httpd->recvbuf[0] = 0; + httpd->recvlen = 0; + httpd->method = ISC_HTTPD_METHODUNKNOWN; + httpd->url = NULL; + httpd->querystring = NULL; + httpd->protocol = NULL; + httpd->flags = 0; + + isc_buffer_clear(&httpd->headerbuffer); + isc_buffer_invalidate(&httpd->bodybuffer); +} + +isc_result_t +isc_httpdmgr_addurl(isc_httpdmgr_t *httpdmgr, const char *url, + isc_httpdaction_t *func, void *arg) +{ + isc_httpdurl_t *item; + + if (url == NULL) { + httpdmgr->render_404 = func; + return (ISC_R_SUCCESS); + } + + item = isc_mem_get(httpdmgr->mctx, sizeof(isc_httpdurl_t)); + if (item == NULL) + return (ISC_R_NOMEMORY); + + item->url = isc_mem_strdup(httpdmgr->mctx, url); + if (item->url == NULL) { + isc_mem_put(httpdmgr->mctx, item, sizeof(isc_httpdurl_t)); + return (ISC_R_NOMEMORY); + } + + item->action = func; + item->action_arg = arg; + ISC_LINK_INIT(item, link); + ISC_LIST_APPEND(httpdmgr->urls, item, link); + + return (ISC_R_SUCCESS); +} diff -urN src/contrib/ntp/lib/isc/ia64/include/isc/atomic.h src.ntp/contrib/ntp/lib/isc/ia64/include/isc/atomic.h --- src/contrib/ntp/lib/isc/ia64/include/isc/atomic.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/ia64/include/isc/atomic.h 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,100 @@ +/* + * Copyright (C) 2006, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: atomic.h,v 1.4.326.2 2009/02/06 23:47:11 tbox Exp $ */ + +#ifndef ISC_ATOMIC_H +#define ISC_ATOMIC_H 1 + +#include +#include + +#ifdef ISC_PLATFORM_USEGCCASM +/* + * This routine atomically increments the value stored in 'p' by 'val', and + * returns the previous value. + * + * Open issue: can 'fetchadd' make the code faster for some particular values + * (e.g., 1 and -1)? + */ +static inline isc_int32_t +isc_atomic_xadd(isc_int32_t *p, isc_int32_t val) +#ifdef __GNUC__ +__attribute__ ((unused)) +#endif +{ + isc_int32_t prev, swapped; + + for (prev = *(volatile isc_int32_t *)p; ; prev = swapped) { + swapped = prev + val; + __asm__ volatile( + "mov ar.ccv=%2;" + "cmpxchg4.acq %0=%4,%3,ar.ccv" + : "=r" (swapped), "=m" (*p) + : "r" (prev), "r" (swapped), "m" (*p) + : "memory"); + if (swapped == prev) + break; + } + + return (prev); +} + +/* + * This routine atomically stores the value 'val' in 'p'. + */ +static inline void +isc_atomic_store(isc_int32_t *p, isc_int32_t val) +#ifdef __GNUC__ +__attribute__ ((unused)) +#endif +{ + __asm__ volatile( + "st4.rel %0=%1" + : "=m" (*p) + : "r" (val) + : "memory" + ); +} + +/* + * This routine atomically replaces the value in 'p' with 'val', if the + * original value is equal to 'cmpval'. The original value is returned in any + * case. + */ +static inline isc_int32_t +isc_atomic_cmpxchg(isc_int32_t *p, isc_int32_t cmpval, isc_int32_t val) +#ifdef __GNUC__ +__attribute__ ((unused)) +#endif +{ + isc_int32_t ret; + + __asm__ volatile( + "mov ar.ccv=%2;" + "cmpxchg4.acq %0=%4,%3,ar.ccv" + : "=r" (ret), "=m" (*p) + : "r" (cmpval), "r" (val), "m" (*p) + : "memory"); + + return (ret); +} +#else /* !ISC_PLATFORM_USEGCCASM */ + +#error "unsupported compiler. disable atomic ops by --disable-atomic" + +#endif +#endif /* ISC_ATOMIC_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/app.h src.ntp/contrib/ntp/lib/isc/include/isc/app.h --- src/contrib/ntp/lib/isc/include/isc/app.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/app.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,212 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: app.h,v 1.8 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_APP_H +#define ISC_APP_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/app.h + * \brief ISC Application Support + * + * Dealing with program termination can be difficult, especially in a + * multithreaded program. The routines in this module help coordinate + * the shutdown process. They are used as follows by the initial (main) + * thread of the application: + * + *\li isc_app_start(); Call very early in main(), before + * any other threads have been created. + * + *\li isc_app_run(); This will post any on-run events, + * and then block until application + * shutdown is requested. A shutdown + * request is made by calling + * isc_app_shutdown(), or by sending + * SIGINT or SIGTERM to the process. + * After isc_app_run() returns, the + * application should shutdown itself. + * + *\li isc_app_finish(); Call very late in main(). + * + * Applications that want to use SIGHUP/isc_app_reload() to trigger reloading + * should check the result of isc_app_run() and call the reload routine if + * the result is ISC_R_RELOAD. They should then call isc_app_run() again + * to resume waiting for reload or termination. + * + * Use of this module is not required. In particular, isc_app_start() is + * NOT an ISC library initialization routine. + * + * \li MP: + * Clients must ensure that isc_app_start(), isc_app_run(), and + * isc_app_finish() are called at most once. isc_app_shutdown() + * is safe to use by any thread (provided isc_app_start() has been + * called previously). + * + * \li Reliability: + * No anticipated impact. + * + * \li Resources: + * None. + * + * \li Security: + * No anticipated impact. + * + * \li Standards: + * None. + */ + +#include +#include +#include + +typedef isc_event_t isc_appevent_t; + +#define ISC_APPEVENT_FIRSTEVENT (ISC_EVENTCLASS_APP + 0) +#define ISC_APPEVENT_SHUTDOWN (ISC_EVENTCLASS_APP + 1) +#define ISC_APPEVENT_LASTEVENT (ISC_EVENTCLASS_APP + 65535) + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_app_start(void); +/*!< + * \brief Start an ISC library application. + * + * Notes: + * This call should be made before any other ISC library call, and as + * close to the beginning of the application as possible. + */ + +isc_result_t +isc_app_onrun(isc_mem_t *mctx, isc_task_t *task, isc_taskaction_t action, + void *arg); +/*!< + * \brief Request delivery of an event when the application is run. + * + * Requires: + * isc_app_start() has been called. + * + * Returns: + * ISC_R_SUCCESS + * ISC_R_NOMEMORY + */ + +isc_result_t +isc_app_run(void); +/*!< + * \brief Run an ISC library application. + * + * Notes: + *\li The caller (typically the initial thread of an application) will + * block until shutdown is requested. When the call returns, the + * caller should start shutting down the application. + * + * Requires: + *\li isc_app_start() has been called. + * + * Ensures: + *\li Any events requested via isc_app_onrun() will have been posted (in + * FIFO order) before isc_app_run() blocks. + * + * Returns: + *\li ISC_R_SUCCESS Shutdown has been requested. + *\li ISC_R_RELOAD Reload has been requested. + */ + +isc_result_t +isc_app_shutdown(void); +/*!< + * \brief Request application shutdown. + * + * Notes: + *\li It is safe to call isc_app_shutdown() multiple times. Shutdown will + * only be triggered once. + * + * Requires: + *\li isc_app_run() has been called. + * + * Returns: + *\li ISC_R_SUCCESS + *\li ISC_R_UNEXPECTED + */ + +isc_result_t +isc_app_reload(void); +/*!< + * \brief Request application reload. + * + * Requires: + *\li isc_app_run() has been called. + * + * Returns: + *\li ISC_R_SUCCESS + *\li ISC_R_UNEXPECTED + */ + +void +isc_app_finish(void); +/*!< + * \brief Finish an ISC library application. + * + * Notes: + *\li This call should be made at or near the end of main(). + * + * Requires: + *\li isc_app_start() has been called. + * + * Ensures: + *\li Any resources allocated by isc_app_start() have been released. + */ + +void +isc_app_block(void); +/*!< + * \brief Indicate that a blocking operation will be performed. + * + * Notes: + *\li If a blocking operation is in process, a call to isc_app_shutdown() + * or an external signal will abort the program, rather than allowing + * clean shutdown. This is primarily useful for reading user input. + * + * Requires: + * \li isc_app_start() has been called. + * \li No other blocking operations are in progress. + */ + +void +isc_app_unblock(void); +/*!< + * \brief Indicate that a blocking operation is complete. + * + * Notes: + * \li When a blocking operation has completed, return the program to a + * state where a call to isc_app_shutdown() or an external signal will + * shutdown normally. + * + * Requires: + * \li isc_app_start() has been called. + * \li isc_app_block() has been called by the same thread. + */ + + +ISC_LANG_ENDDECLS + +#endif /* ISC_APP_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/assertions.h src.ntp/contrib/ntp/lib/isc/include/isc/assertions.h --- src/contrib/ntp/lib/isc/include/isc/assertions.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/assertions.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,124 @@ +/* + * Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1997-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* + * $Id: assertions.h,v 1.26 2008/10/15 23:47:31 tbox Exp $ + */ +/*! \file isc/assertions.h + */ + +#ifndef ISC_ASSERTIONS_H +#define ISC_ASSERTIONS_H 1 + +#include +#include + +ISC_LANG_BEGINDECLS + +/*% isc assertion type */ +typedef enum { + isc_assertiontype_require, + isc_assertiontype_ensure, + isc_assertiontype_insist, + isc_assertiontype_invariant +} isc_assertiontype_t; + +typedef void (*isc_assertioncallback_t)(const char *, int, isc_assertiontype_t, + const char *); + +/* coverity[+kill] */ +LIBISC_EXTERNAL_DATA extern isc_assertioncallback_t isc_assertion_failed; + +void +isc_assertion_setcallback(isc_assertioncallback_t); + +const char * +isc_assertion_typetotext(isc_assertiontype_t type); + +#if defined(ISC_CHECK_ALL) || defined(__COVERITY__) +#define ISC_CHECK_REQUIRE 1 +#define ISC_CHECK_ENSURE 1 +#define ISC_CHECK_INSIST 1 +#define ISC_CHECK_INVARIANT 1 +#endif + +#if defined(ISC_CHECK_NONE) && !defined(__COVERITY__) +#define ISC_CHECK_REQUIRE 0 +#define ISC_CHECK_ENSURE 0 +#define ISC_CHECK_INSIST 0 +#define ISC_CHECK_INVARIANT 0 +#endif + +#ifndef ISC_CHECK_REQUIRE +#define ISC_CHECK_REQUIRE 1 +#endif + +#ifndef ISC_CHECK_ENSURE +#define ISC_CHECK_ENSURE 1 +#endif + +#ifndef ISC_CHECK_INSIST +#define ISC_CHECK_INSIST 1 +#endif + +#ifndef ISC_CHECK_INVARIANT +#define ISC_CHECK_INVARIANT 1 +#endif + +#if ISC_CHECK_REQUIRE != 0 +#define ISC_REQUIRE(cond) \ + ((void) ((cond) || \ + ((isc_assertion_failed)(__FILE__, __LINE__, \ + isc_assertiontype_require, \ + #cond), 0))) +#else +#define ISC_REQUIRE(cond) ((void) 0) +#endif /* ISC_CHECK_REQUIRE */ + +#if ISC_CHECK_ENSURE != 0 +#define ISC_ENSURE(cond) \ + ((void) ((cond) || \ + ((isc_assertion_failed)(__FILE__, __LINE__, \ + isc_assertiontype_ensure, \ + #cond), 0))) +#else +#define ISC_ENSURE(cond) ((void) 0) +#endif /* ISC_CHECK_ENSURE */ + +#if ISC_CHECK_INSIST != 0 +#define ISC_INSIST(cond) \ + ((void) ((cond) || \ + ((isc_assertion_failed)(__FILE__, __LINE__, \ + isc_assertiontype_insist, \ + #cond), 0))) +#else +#define ISC_INSIST(cond) ((void) 0) +#endif /* ISC_CHECK_INSIST */ + +#if ISC_CHECK_INVARIANT != 0 +#define ISC_INVARIANT(cond) \ + ((void) ((cond) || \ + ((isc_assertion_failed)(__FILE__, __LINE__, \ + isc_assertiontype_invariant, \ + #cond), 0))) +#else +#define ISC_INVARIANT(cond) ((void) 0) +#endif /* ISC_CHECK_INVARIANT */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_ASSERTIONS_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/base32.h src.ntp/contrib/ntp/lib/isc/include/isc/base32.h --- src/contrib/ntp/lib/isc/include/isc/base32.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/base32.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,128 @@ +/* + * Copyright (C) 2008 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: base32.h,v 1.3 2008/09/25 04:02:39 tbox Exp $ */ + +#ifndef ISC_BASE32_H +#define ISC_BASE32_H 1 + +/*! \file */ + +/* + * Routines for manipulating base 32 and base 32 hex encoded data. + * Based on RFC 4648. + * + * Base 32 hex preserves the sort order of data when it is encoded / + * decoded. + */ + +#include +#include + +ISC_LANG_BEGINDECLS + +/*** + *** Functions + ***/ + +isc_result_t +isc_base32_totext(isc_region_t *source, int wordlength, + const char *wordbreak, isc_buffer_t *target); +isc_result_t +isc_base32hex_totext(isc_region_t *source, int wordlength, + const char *wordbreak, isc_buffer_t *target); +/*!< + * \brief Convert data into base32 encoded text. + * + * Notes: + *\li The base32 encoded text in 'target' will be divided into + * words of at most 'wordlength' characters, separated by + * the 'wordbreak' string. No parentheses will surround + * the text. + * + * Requires: + *\li 'source' is a region containing binary data + *\li 'target' is a text buffer containing available space + *\li 'wordbreak' points to a null-terminated string of + * zero or more whitespace characters + * + * Ensures: + *\li target will contain the base32 encoded version of the data + * in source. The 'used' pointer in target will be advanced as + * necessary. + */ + +isc_result_t +isc_base32_decodestring(const char *cstr, isc_buffer_t *target); +isc_result_t +isc_base32hex_decodestring(const char *cstr, isc_buffer_t *target); +/*!< + * \brief Decode a null-terminated base32 string. + * + * Requires: + *\li 'cstr' is non-null. + *\li 'target' is a valid buffer. + * + * Returns: + *\li #ISC_R_SUCCESS -- the entire decoded representation of 'cstring' + * fit in 'target'. + *\li #ISC_R_BADBASE32 -- 'cstr' is not a valid base32 encoding. + * + * Other error returns are any possible error code from: + *\li isc_lex_create(), + *\li isc_lex_openbuffer(), + *\li isc_base32_tobuffer(). + */ + +isc_result_t +isc_base32_tobuffer(isc_lex_t *lexer, isc_buffer_t *target, int length); +isc_result_t +isc_base32hex_tobuffer(isc_lex_t *lexer, isc_buffer_t *target, int length); +/*!< + * \brief Convert base32 encoded text from a lexer context into data. + * + * Requires: + *\li 'lex' is a valid lexer context + *\li 'target' is a buffer containing binary data + *\li 'length' is an integer + * + * Ensures: + *\li target will contain the data represented by the base32 encoded + * string parsed by the lexer. No more than length bytes will be read, + * if length is positive. The 'used' pointer in target will be + * advanced as necessary. + */ + +isc_result_t +isc_base32_decoderegion(isc_region_t *source, isc_buffer_t *target); +isc_result_t +isc_base32hex_decoderegion(isc_region_t *source, isc_buffer_t *target); +/*!< + * \brief Decode a packed (no white space permitted) base32 region. + * + * Requires: + *\li 'source' is a valid region. + *\li 'target' is a valid buffer. + * + * Returns: + *\li #ISC_R_SUCCESS -- the entire decoded representation of 'cstring' + * fit in 'target'. + *\li #ISC_R_BADBASE32 -- 'source' is not a valid base32 encoding. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_BASE32_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/base64.h src.ntp/contrib/ntp/lib/isc/include/isc/base64.h --- src/contrib/ntp/lib/isc/include/isc/base64.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/base64.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,99 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: base64.h,v 1.22 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_BASE64_H +#define ISC_BASE64_H 1 + +/*! \file isc/base64.h */ + +#include +#include + +ISC_LANG_BEGINDECLS + +/*** + *** Functions + ***/ + +isc_result_t +isc_base64_totext(isc_region_t *source, int wordlength, + const char *wordbreak, isc_buffer_t *target); +/*!< + * \brief Convert data into base64 encoded text. + * + * Notes: + *\li The base64 encoded text in 'target' will be divided into + * words of at most 'wordlength' characters, separated by + * the 'wordbreak' string. No parentheses will surround + * the text. + * + * Requires: + *\li 'source' is a region containing binary data + *\li 'target' is a text buffer containing available space + *\li 'wordbreak' points to a null-terminated string of + * zero or more whitespace characters + * + * Ensures: + *\li target will contain the base64 encoded version of the data + * in source. The 'used' pointer in target will be advanced as + * necessary. + */ + +isc_result_t +isc_base64_decodestring(const char *cstr, isc_buffer_t *target); +/*!< + * \brief Decode a null-terminated base64 string. + * + * Requires: + *\li 'cstr' is non-null. + *\li 'target' is a valid buffer. + * + * Returns: + *\li #ISC_R_SUCCESS -- the entire decoded representation of 'cstring' + * fit in 'target'. + *\li #ISC_R_BADBASE64 -- 'cstr' is not a valid base64 encoding. + * + * Other error returns are any possible error code from: + *\li isc_lex_create(), + *\li isc_lex_openbuffer(), + *\li isc_base64_tobuffer(). + */ + +isc_result_t +isc_base64_tobuffer(isc_lex_t *lexer, isc_buffer_t *target, int length); +/*!< + * \brief Convert base64 encoded text from a lexer context into data. + * + * Requires: + *\li 'lex' is a valid lexer context + *\li 'target' is a buffer containing binary data + *\li 'length' is an integer + * + * Ensures: + *\li target will contain the data represented by the base64 encoded + * string parsed by the lexer. No more than length bytes will be read, + * if length is positive. The 'used' pointer in target will be + * advanced as necessary. + */ + + + +ISC_LANG_ENDDECLS + +#endif /* ISC_BASE64_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/bitstring.h src.ntp/contrib/ntp/lib/isc/include/isc/bitstring.h --- src/contrib/ntp/lib/isc/include/isc/bitstring.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/bitstring.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,157 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: bitstring.h,v 1.14 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_BITSTRING_H +#define ISC_BITSTRING_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/bitstring.h + * + * \brief Bitstring manipulation functions. + * + * A bitstring is a packed array of bits, stored in a contiguous + * sequence of octets. The "most significant bit" (msb) of a bitstring + * is the high bit of the first octet. The "least significant bit" of a + * bitstring is the low bit of the last octet. + * + * Two bit numbering schemes are supported, "msb0" and "lsb0". + * + * In the "msb0" scheme, bit number 0 designates the most significant bit, + * and any padding bits required to make the bitstring a multiple of 8 bits + * long are added to the least significant end of the last octet. + * + * In the "lsb0" scheme, bit number 0 designates the least significant bit, + * and any padding bits required to make the bitstring a multiple of 8 bits + * long are added to the most significant end of the first octet. + * + * E.g., consider the bitstring "11010001111". This bitstring is 11 bits + * long and will take two octets. Let "p" denote a pad bit. In the msb0 + * encoding, it would be + * + * \verbatim + * Octet 0 Octet 1 + * | + * 1 1 0 1 0 0 0 1 | 1 1 1 p p p p p + * ^ | ^ + * | | + * bit 0 bit 15 + * \endverbatim + * + * In the lsb0 encoding, it would be + * + * \verbatim + * Octet 0 Octet 1 + * | + * p p p p p 1 1 0 | 1 0 0 0 1 1 1 1 + * ^ | ^ + * | | + * bit 15 bit 0 + * \endverbatim + */ + +/*** + *** Imports + ***/ + +#include +#include + +ISC_LANG_BEGINDECLS + +/*** + *** Types + ***/ + +struct isc_bitstring { + unsigned int magic; + unsigned char * data; + unsigned int length; + unsigned int size; + isc_boolean_t lsb0; +}; + +/*** + *** Functions + ***/ + +void +isc_bitstring_init(isc_bitstring_t *bitstring, unsigned char *data, + unsigned int length, unsigned int size, isc_boolean_t lsb0); +/*!< + * \brief Make 'bitstring' refer to the bitstring of 'size' bits starting + * at 'data'. 'length' bits of the bitstring are valid. If 'lsb0' + * is set then, bit 0 refers to the least significant bit of the + * bitstring. Otherwise bit 0 is the most significant bit. + * + * Requires: + * + *\li 'bitstring' points to a isc_bitstring_t. + * + *\li 'data' points to an array of unsigned char large enough to hold + * 'size' bits. + * + *\li 'length' <= 'size'. + * + * Ensures: + * + *\li 'bitstring' is a valid bitstring. + */ + +void +isc_bitstring_invalidate(isc_bitstring_t *bitstring); +/*!< + * \brief Invalidate 'bitstring'. + * + * Requires: + * + *\li 'bitstring' is a valid bitstring. + * + * Ensures: + * + *\li 'bitstring' is not a valid bitstring. + */ + +void +isc_bitstring_copy(isc_bitstring_t *source, unsigned int sbitpos, + isc_bitstring_t *target, unsigned int tbitpos, + unsigned int n); +/*!< + * \brief Starting at bit 'sbitpos', copy 'n' bits from 'source' to + * the 'n' bits of 'target' starting at 'tbitpos'. + * + * Requires: + * + *\li 'source' and target are valid bitstrings with the same lsb0 setting. + * + *\li 'sbitpos' + 'n' is less than or equal to the length of 'source'. + * + *\li 'tbitpos' + 'n' is less than or equal to the size of 'target'. + * + * Ensures: + * + *\li The specified bits have been copied, and the length of 'target' + * adjusted (if required). + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_BITSTRING_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/boolean.h src.ntp/contrib/ntp/lib/isc/include/isc/boolean.h --- src/contrib/ntp/lib/isc/include/isc/boolean.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/boolean.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: boolean.h,v 1.19 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_BOOLEAN_H +#define ISC_BOOLEAN_H 1 + +/*! \file isc/boolean.h */ + +typedef enum { isc_boolean_false = 0, isc_boolean_true = 1 } isc_boolean_t; + +#define ISC_FALSE isc_boolean_false +#define ISC_TRUE isc_boolean_true +#define ISC_TF(x) ((x) ? ISC_TRUE : ISC_FALSE) + +#endif /* ISC_BOOLEAN_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/buffer.h src.ntp/contrib/ntp/lib/isc/include/isc/buffer.h --- src/contrib/ntp/lib/isc/include/isc/buffer.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/buffer.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,904 @@ +/* + * Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: buffer.h,v 1.53 2008/09/25 04:02:39 tbox Exp $ */ + +#ifndef ISC_BUFFER_H +#define ISC_BUFFER_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/buffer.h + * + * \brief A buffer is a region of memory, together with a set of related subregions. + * Buffers are used for parsing and I/O operations. + * + * The 'used region' and the 'available' region are disjoint, and their + * union is the buffer's region. The used region extends from the beginning + * of the buffer region to the last used byte. The available region + * extends from one byte greater than the last used byte to the end of the + * buffer's region. The size of the used region can be changed using various + * buffer commands. Initially, the used region is empty. + * + * The used region is further subdivided into two disjoint regions: the + * 'consumed region' and the 'remaining region'. The union of these two + * regions is the used region. The consumed region extends from the beginning + * of the used region to the byte before the 'current' offset (if any). The + * 'remaining' region the current pointer to the end of the used + * region. The size of the consumed region can be changed using various + * buffer commands. Initially, the consumed region is empty. + * + * The 'active region' is an (optional) subregion of the remaining region. + * It extends from the current offset to an offset in the remaining region + * that is selected with isc_buffer_setactive(). Initially, the active region + * is empty. If the current offset advances beyond the chosen offset, the + * active region will also be empty. + * + * \verbatim + * /------------entire length---------------\ + * /----- used region -----\/-- available --\ + * +----------------------------------------+ + * | consumed | remaining | | + * +----------------------------------------+ + * a b c d e + * + * a == base of buffer. + * b == current pointer. Can be anywhere between a and d. + * c == active pointer. Meaningful between b and d. + * d == used pointer. + * e == length of buffer. + * + * a-e == entire length of buffer. + * a-d == used region. + * a-b == consumed region. + * b-d == remaining region. + * b-c == optional active region. + *\endverbatim + * + * The following invariants are maintained by all routines: + * + *\code + * length > 0 + * + * base is a valid pointer to length bytes of memory + * + * 0 <= used <= length + * + * 0 <= current <= used + * + * 0 <= active <= used + * (although active < current implies empty active region) + *\endcode + * + * \li MP: + * Buffers have no synchronization. Clients must ensure exclusive + * access. + * + * \li Reliability: + * No anticipated impact. + * + * \li Resources: + * Memory: 1 pointer + 6 unsigned integers per buffer. + * + * \li Security: + * No anticipated impact. + * + * \li Standards: + * None. + */ + +/*** + *** Imports + ***/ + +#include +#include +#include + +/*! + * To make many functions be inline macros (via \#define) define this. + * If it is undefined, a function will be used. + */ +/* #define ISC_BUFFER_USEINLINE */ + +ISC_LANG_BEGINDECLS + +/*@{*/ +/*! + *** Magic numbers + ***/ +#define ISC_BUFFER_MAGIC 0x42756621U /* Buf!. */ +#define ISC_BUFFER_VALID(b) ISC_MAGIC_VALID(b, ISC_BUFFER_MAGIC) +/*@}*/ + +/* + * The following macros MUST be used only on valid buffers. It is the + * caller's responsibility to ensure this by using the ISC_BUFFER_VALID + * check above, or by calling another isc_buffer_*() function (rather than + * another macro.) + */ + +/*@{*/ +/*! + * Fundamental buffer elements. (A through E in the introductory comment.) + */ +#define isc_buffer_base(b) ((void *)(b)->base) /*a*/ +#define isc_buffer_current(b) \ + ((void *)((unsigned char *)(b)->base + (b)->current)) /*b*/ +#define isc_buffer_active(b) \ + ((void *)((unsigned char *)(b)->base + (b)->active)) /*c*/ +#define isc_buffer_used(b) \ + ((void *)((unsigned char *)(b)->base + (b)->used)) /*d*/ +#define isc_buffer_length(b) ((b)->length) /*e*/ +/*@}*/ + +/*@{*/ +/*! + * Derived lengths. (Described in the introductory comment.) + */ +#define isc_buffer_usedlength(b) ((b)->used) /* d-a */ +#define isc_buffer_consumedlength(b) ((b)->current) /* b-a */ +#define isc_buffer_remaininglength(b) ((b)->used - (b)->current) /* d-b */ +#define isc_buffer_activelength(b) ((b)->active - (b)->current) /* c-b */ +#define isc_buffer_availablelength(b) ((b)->length - (b)->used) /* e-d */ +/*@}*/ + +/*! + * Note that the buffer structure is public. This is principally so buffer + * operations can be implemented using macros. Applications are strongly + * discouraged from directly manipulating the structure. + */ + +struct isc_buffer { + unsigned int magic; + void *base; + /*@{*/ + /*! The following integers are byte offsets from 'base'. */ + unsigned int length; + unsigned int used; + unsigned int current; + unsigned int active; + /*@}*/ + /*! linkable */ + ISC_LINK(isc_buffer_t) link; + /*! private internal elements */ + isc_mem_t *mctx; +}; + +/*** + *** Functions + ***/ + +isc_result_t +isc_buffer_allocate(isc_mem_t *mctx, isc_buffer_t **dynbuffer, + unsigned int length); +/*!< + * \brief Allocate a dynamic linkable buffer which has "length" bytes in the + * data region. + * + * Requires: + *\li "mctx" is valid. + * + *\li "dynbuffer" is non-NULL, and "*dynbuffer" is NULL. + * + * Returns: + *\li ISC_R_SUCCESS - success + *\li ISC_R_NOMEMORY - no memory available + * + * Note: + *\li Changing the buffer's length field is not permitted. + */ + +void +isc_buffer_free(isc_buffer_t **dynbuffer); +/*!< + * \brief Release resources allocated for a dynamic buffer. + * + * Requires: + *\li "dynbuffer" is not NULL. + * + *\li "*dynbuffer" is a valid dynamic buffer. + * + * Ensures: + *\li "*dynbuffer" will be NULL on return, and all memory associated with + * the dynamic buffer is returned to the memory context used in + * isc_buffer_allocate(). + */ + +void +isc__buffer_init(isc_buffer_t *b, const void *base, unsigned int length); +/*!< + * \brief Make 'b' refer to the 'length'-byte region starting at base. + * + * Requires: + * + *\li 'length' > 0 + * + *\li 'base' is a pointer to a sequence of 'length' bytes. + * + */ + +void +isc__buffer_initnull(isc_buffer_t *b); +/*!< + *\brief Initialize a buffer 'b' with a null data and zero length/ + */ + +void +isc_buffer_reinit(isc_buffer_t *b, void *base, unsigned int length); +/*!< + * \brief Make 'b' refer to the 'length'-byte region starting at base. + * Any existing data will be copied. + * + * Requires: + * + *\li 'length' > 0 AND length >= previous length + * + *\li 'base' is a pointer to a sequence of 'length' bytes. + * + */ + +void +isc__buffer_invalidate(isc_buffer_t *b); +/*!< + * \brief Make 'b' an invalid buffer. + * + * Requires: + *\li 'b' is a valid buffer. + * + * Ensures: + *\li If assertion checking is enabled, future attempts to use 'b' without + * calling isc_buffer_init() on it will cause an assertion failure. + */ + +void +isc__buffer_region(isc_buffer_t *b, isc_region_t *r); +/*!< + * \brief Make 'r' refer to the region of 'b'. + * + * Requires: + * + *\li 'b' is a valid buffer. + * + *\li 'r' points to a region structure. + */ + +void +isc__buffer_usedregion(isc_buffer_t *b, isc_region_t *r); +/*!< + * \brief Make 'r' refer to the used region of 'b'. + * + * Requires: + * + *\li 'b' is a valid buffer. + * + *\li 'r' points to a region structure. + */ + +void +isc__buffer_availableregion(isc_buffer_t *b, isc_region_t *r); +/*!< + * \brief Make 'r' refer to the available region of 'b'. + * + * Requires: + * + *\li 'b' is a valid buffer. + * + *\li 'r' points to a region structure. + */ + +void +isc__buffer_add(isc_buffer_t *b, unsigned int n); +/*!< + * \brief Increase the 'used' region of 'b' by 'n' bytes. + * + * Requires: + * + *\li 'b' is a valid buffer + * + *\li used + n <= length + * + */ + +void +isc__buffer_subtract(isc_buffer_t *b, unsigned int n); +/*!< + * \brief Decrease the 'used' region of 'b' by 'n' bytes. + * + * Requires: + * + *\li 'b' is a valid buffer + * + *\li used >= n + * + */ + +void +isc__buffer_clear(isc_buffer_t *b); +/*!< + * \brief Make the used region empty. + * + * Requires: + * + *\li 'b' is a valid buffer + * + * Ensures: + * + *\li used = 0 + * + */ + +void +isc__buffer_consumedregion(isc_buffer_t *b, isc_region_t *r); +/*!< + * \brief Make 'r' refer to the consumed region of 'b'. + * + * Requires: + * + *\li 'b' is a valid buffer. + * + *\li 'r' points to a region structure. + */ + +void +isc__buffer_remainingregion(isc_buffer_t *b, isc_region_t *r); +/*!< + * \brief Make 'r' refer to the remaining region of 'b'. + * + * Requires: + * + *\li 'b' is a valid buffer. + * + *\li 'r' points to a region structure. + */ + +void +isc__buffer_activeregion(isc_buffer_t *b, isc_region_t *r); +/*!< + * \brief Make 'r' refer to the active region of 'b'. + * + * Requires: + * + *\li 'b' is a valid buffer. + * + *\li 'r' points to a region structure. + */ + +void +isc__buffer_setactive(isc_buffer_t *b, unsigned int n); +/*!< + * \brief Sets the end of the active region 'n' bytes after current. + * + * Requires: + * + *\li 'b' is a valid buffer. + * + *\li current + n <= used + */ + +void +isc__buffer_first(isc_buffer_t *b); +/*!< + * \brief Make the consumed region empty. + * + * Requires: + * + *\li 'b' is a valid buffer + * + * Ensures: + * + *\li current == 0 + * + */ + +void +isc__buffer_forward(isc_buffer_t *b, unsigned int n); +/*!< + * \brief Increase the 'consumed' region of 'b' by 'n' bytes. + * + * Requires: + * + *\li 'b' is a valid buffer + * + *\li current + n <= used + * + */ + +void +isc__buffer_back(isc_buffer_t *b, unsigned int n); +/*!< + * \brief Decrease the 'consumed' region of 'b' by 'n' bytes. + * + * Requires: + * + *\li 'b' is a valid buffer + * + *\li n <= current + * + */ + +void +isc_buffer_compact(isc_buffer_t *b); +/*!< + * \brief Compact the used region by moving the remaining region so it occurs + * at the start of the buffer. The used region is shrunk by the size of + * the consumed region, and the consumed region is then made empty. + * + * Requires: + * + *\li 'b' is a valid buffer + * + * Ensures: + * + *\li current == 0 + * + *\li The size of the used region is now equal to the size of the remaining + * region (as it was before the call). The contents of the used region + * are those of the remaining region (as it was before the call). + */ + +isc_uint8_t +isc_buffer_getuint8(isc_buffer_t *b); +/*!< + * \brief Read an unsigned 8-bit integer from 'b' and return it. + * + * Requires: + * + *\li 'b' is a valid buffer. + * + *\li The length of the available region of 'b' is at least 1. + * + * Ensures: + * + *\li The current pointer in 'b' is advanced by 1. + * + * Returns: + * + *\li A 8-bit unsigned integer. + */ + +void +isc__buffer_putuint8(isc_buffer_t *b, isc_uint8_t val); +/*!< + * \brief Store an unsigned 8-bit integer from 'val' into 'b'. + * + * Requires: + *\li 'b' is a valid buffer. + * + *\li The length of the unused region of 'b' is at least 1. + * + * Ensures: + *\li The used pointer in 'b' is advanced by 1. + */ + +isc_uint16_t +isc_buffer_getuint16(isc_buffer_t *b); +/*!< + * \brief Read an unsigned 16-bit integer in network byte order from 'b', convert + * it to host byte order, and return it. + * + * Requires: + * + *\li 'b' is a valid buffer. + * + *\li The length of the available region of 'b' is at least 2. + * + * Ensures: + * + *\li The current pointer in 'b' is advanced by 2. + * + * Returns: + * + *\li A 16-bit unsigned integer. + */ + +void +isc__buffer_putuint16(isc_buffer_t *b, isc_uint16_t val); +/*!< + * \brief Store an unsigned 16-bit integer in host byte order from 'val' + * into 'b' in network byte order. + * + * Requires: + *\li 'b' is a valid buffer. + * + *\li The length of the unused region of 'b' is at least 2. + * + * Ensures: + *\li The used pointer in 'b' is advanced by 2. + */ + +isc_uint32_t +isc_buffer_getuint32(isc_buffer_t *b); +/*!< + * \brief Read an unsigned 32-bit integer in network byte order from 'b', convert + * it to host byte order, and return it. + * + * Requires: + * + *\li 'b' is a valid buffer. + * + *\li The length of the available region of 'b' is at least 4. + * + * Ensures: + * + *\li The current pointer in 'b' is advanced by 4. + * + * Returns: + * + *\li A 32-bit unsigned integer. + */ + +void +isc__buffer_putuint32(isc_buffer_t *b, isc_uint32_t val); +/*!< + * \brief Store an unsigned 32-bit integer in host byte order from 'val' + * into 'b' in network byte order. + * + * Requires: + *\li 'b' is a valid buffer. + * + *\li The length of the unused region of 'b' is at least 4. + * + * Ensures: + *\li The used pointer in 'b' is advanced by 4. + */ + +isc_uint64_t +isc_buffer_getuint48(isc_buffer_t *b); +/*!< + * \brief Read an unsigned 48-bit integer in network byte order from 'b', + * convert it to host byte order, and return it. + * + * Requires: + * + *\li 'b' is a valid buffer. + * + *\li The length of the available region of 'b' is at least 6. + * + * Ensures: + * + *\li The current pointer in 'b' is advanced by 6. + * + * Returns: + * + *\li A 48-bit unsigned integer (stored in a 64-bit integer). + */ + +void +isc__buffer_putuint48(isc_buffer_t *b, isc_uint64_t val); +/*!< + * \brief Store an unsigned 48-bit integer in host byte order from 'val' + * into 'b' in network byte order. + * + * Requires: + *\li 'b' is a valid buffer. + * + *\li The length of the unused region of 'b' is at least 6. + * + * Ensures: + *\li The used pointer in 'b' is advanced by 6. + */ + +void +isc__buffer_putuint24(isc_buffer_t *b, isc_uint32_t val); +/*!< + * Store an unsigned 24-bit integer in host byte order from 'val' + * into 'b' in network byte order. + * + * Requires: + *\li 'b' is a valid buffer. + * + * The length of the unused region of 'b' is at least 3. + * + * Ensures: + *\li The used pointer in 'b' is advanced by 3. + */ + +void +isc__buffer_putmem(isc_buffer_t *b, const unsigned char *base, + unsigned int length); +/*!< + * \brief Copy 'length' bytes of memory at 'base' into 'b'. + * + * Requires: + *\li 'b' is a valid buffer. + * + *\li 'base' points to 'length' bytes of valid memory. + * + */ + +void +isc__buffer_putstr(isc_buffer_t *b, const char *source); +/*!< + * \brief Copy 'source' into 'b', not including terminating NUL. + * + * Requires: + *\li 'b' is a valid buffer. + * + *\li 'source' to be a valid NULL terminated string. + * + *\li strlen(source) <= isc_buffer_available(b) + */ + +isc_result_t +isc_buffer_copyregion(isc_buffer_t *b, const isc_region_t *r); +/*!< + * \brief Copy the contents of 'r' into 'b'. + * + * Requires: + *\li 'b' is a valid buffer. + * + *\li 'r' is a valid region. + * + * Returns: + * + *\li ISC_R_SUCCESS + *\li ISC_R_NOSPACE The available region of 'b' is not + * big enough. + */ + +ISC_LANG_ENDDECLS + +/* + * Inline macro versions of the functions. These should never be called + * directly by an application, but will be used by the functions within + * buffer.c. The callers should always use "isc_buffer_*()" names, never + * ones beginning with "isc__" + */ + +/*! \note + * XXXDCL Something more could be done with initializing buffers that + * point to const data. For example, a new function, isc_buffer_initconst, + * could be used, and a new boolean flag in the buffer structure could + * indicate whether the buffer was initialized with that function. + * (isc_bufer_init itself would be reprototyped to *not* have its "base" + * parameter be const.) Then if the boolean were true, the isc_buffer_put* + * functions could assert a contractual requirement for a non-const buffer. + * One drawback is that the isc_buffer_* functions (macros) that return + * pointers would still need to return non-const pointers to avoid compiler + * warnings, so it would be up to code that uses them to have to deal + * with the possibility that the buffer was initialized as const -- + * a problem that they *already* have to deal with but have absolutely + * no ability to. With a new isc_buffer_isconst() function returning + * true/false, they could at least assert a contractual requirement for + * non-const buffers when needed. + */ +#define ISC__BUFFER_INIT(_b, _base, _length) \ + do { \ + union { \ + const void * konst; \ + void * var; \ + } _u; \ + _u.konst = (_base); \ + (_b)->base = _u.var; \ + (_b)->length = (_length); \ + (_b)->used = 0; \ + (_b)->current = 0; \ + (_b)->active = 0; \ + (_b)->mctx = NULL; \ + ISC_LINK_INIT(_b, link); \ + (_b)->magic = ISC_BUFFER_MAGIC; \ + } while (0) + +#define ISC__BUFFER_INITNULL(_b) ISC__BUFFER_INIT(_b, NULL, 0) + +#define ISC__BUFFER_INVALIDATE(_b) \ + do { \ + (_b)->magic = 0; \ + (_b)->base = NULL; \ + (_b)->length = 0; \ + (_b)->used = 0; \ + (_b)->current = 0; \ + (_b)->active = 0; \ + } while (0) + +#define ISC__BUFFER_REGION(_b, _r) \ + do { \ + (_r)->base = (_b)->base; \ + (_r)->length = (_b)->length; \ + } while (0) + +#define ISC__BUFFER_USEDREGION(_b, _r) \ + do { \ + (_r)->base = (_b)->base; \ + (_r)->length = (_b)->used; \ + } while (0) + +#define ISC__BUFFER_AVAILABLEREGION(_b, _r) \ + do { \ + (_r)->base = isc_buffer_used(_b); \ + (_r)->length = isc_buffer_availablelength(_b); \ + } while (0) + +#define ISC__BUFFER_ADD(_b, _n) \ + do { \ + (_b)->used += (_n); \ + } while (0) + +#define ISC__BUFFER_SUBTRACT(_b, _n) \ + do { \ + (_b)->used -= (_n); \ + if ((_b)->current > (_b)->used) \ + (_b)->current = (_b)->used; \ + if ((_b)->active > (_b)->used) \ + (_b)->active = (_b)->used; \ + } while (0) + +#define ISC__BUFFER_CLEAR(_b) \ + do { \ + (_b)->used = 0; \ + (_b)->current = 0; \ + (_b)->active = 0; \ + } while (0) + +#define ISC__BUFFER_CONSUMEDREGION(_b, _r) \ + do { \ + (_r)->base = (_b)->base; \ + (_r)->length = (_b)->current; \ + } while (0) + +#define ISC__BUFFER_REMAININGREGION(_b, _r) \ + do { \ + (_r)->base = isc_buffer_current(_b); \ + (_r)->length = isc_buffer_remaininglength(_b); \ + } while (0) + +#define ISC__BUFFER_ACTIVEREGION(_b, _r) \ + do { \ + if ((_b)->current < (_b)->active) { \ + (_r)->base = isc_buffer_current(_b); \ + (_r)->length = isc_buffer_activelength(_b); \ + } else { \ + (_r)->base = NULL; \ + (_r)->length = 0; \ + } \ + } while (0) + +#define ISC__BUFFER_SETACTIVE(_b, _n) \ + do { \ + (_b)->active = (_b)->current + (_n); \ + } while (0) + +#define ISC__BUFFER_FIRST(_b) \ + do { \ + (_b)->current = 0; \ + } while (0) + +#define ISC__BUFFER_FORWARD(_b, _n) \ + do { \ + (_b)->current += (_n); \ + } while (0) + +#define ISC__BUFFER_BACK(_b, _n) \ + do { \ + (_b)->current -= (_n); \ + } while (0) + +#define ISC__BUFFER_PUTMEM(_b, _base, _length) \ + do { \ + memcpy(isc_buffer_used(_b), (_base), (_length)); \ + (_b)->used += (_length); \ + } while (0) + +#define ISC__BUFFER_PUTSTR(_b, _source) \ + do { \ + unsigned int _length; \ + unsigned char *_cp; \ + _length = strlen(_source); \ + _cp = isc_buffer_used(_b); \ + memcpy(_cp, (_source), _length); \ + (_b)->used += (_length); \ + } while (0) + +#define ISC__BUFFER_PUTUINT8(_b, _val) \ + do { \ + unsigned char *_cp; \ + isc_uint8_t _val2 = (_val); \ + _cp = isc_buffer_used(_b); \ + (_b)->used++; \ + _cp[0] = _val2 & 0x00ff; \ + } while (0) + +#define ISC__BUFFER_PUTUINT16(_b, _val) \ + do { \ + unsigned char *_cp; \ + isc_uint16_t _val2 = (_val); \ + _cp = isc_buffer_used(_b); \ + (_b)->used += 2; \ + _cp[0] = (unsigned char)((_val2 & 0xff00U) >> 8); \ + _cp[1] = (unsigned char)(_val2 & 0x00ffU); \ + } while (0) + +#define ISC__BUFFER_PUTUINT24(_b, _val) \ + do { \ + unsigned char *_cp; \ + isc_uint32_t _val2 = (_val); \ + _cp = isc_buffer_used(_b); \ + (_b)->used += 3; \ + _cp[0] = (unsigned char)((_val2 & 0xff0000U) >> 16); \ + _cp[1] = (unsigned char)((_val2 & 0xff00U) >> 8); \ + _cp[2] = (unsigned char)(_val2 & 0x00ffU); \ + } while (0) + +#define ISC__BUFFER_PUTUINT32(_b, _val) \ + do { \ + unsigned char *_cp; \ + isc_uint32_t _val2 = (_val); \ + _cp = isc_buffer_used(_b); \ + (_b)->used += 4; \ + _cp[0] = (unsigned char)((_val2 & 0xff000000) >> 24); \ + _cp[1] = (unsigned char)((_val2 & 0x00ff0000) >> 16); \ + _cp[2] = (unsigned char)((_val2 & 0x0000ff00) >> 8); \ + _cp[3] = (unsigned char)((_val2 & 0x000000ff)); \ + } while (0) + +#if defined(ISC_BUFFER_USEINLINE) +#define isc_buffer_init ISC__BUFFER_INIT +#define isc_buffer_initnull ISC__BUFFER_INITNULL +#define isc_buffer_invalidate ISC__BUFFER_INVALIDATE +#define isc_buffer_region ISC__BUFFER_REGION +#define isc_buffer_usedregion ISC__BUFFER_USEDREGION +#define isc_buffer_availableregion ISC__BUFFER_AVAILABLEREGION +#define isc_buffer_add ISC__BUFFER_ADD +#define isc_buffer_subtract ISC__BUFFER_SUBTRACT +#define isc_buffer_clear ISC__BUFFER_CLEAR +#define isc_buffer_consumedregion ISC__BUFFER_CONSUMEDREGION +#define isc_buffer_remainingregion ISC__BUFFER_REMAININGREGION +#define isc_buffer_activeregion ISC__BUFFER_ACTIVEREGION +#define isc_buffer_setactive ISC__BUFFER_SETACTIVE +#define isc_buffer_first ISC__BUFFER_FIRST +#define isc_buffer_forward ISC__BUFFER_FORWARD +#define isc_buffer_back ISC__BUFFER_BACK +#define isc_buffer_putmem ISC__BUFFER_PUTMEM +#define isc_buffer_putstr ISC__BUFFER_PUTSTR +#define isc_buffer_putuint8 ISC__BUFFER_PUTUINT8 +#define isc_buffer_putuint16 ISC__BUFFER_PUTUINT16 +#define isc_buffer_putuint24 ISC__BUFFER_PUTUINT24 +#define isc_buffer_putuint32 ISC__BUFFER_PUTUINT32 +#else +#define isc_buffer_init isc__buffer_init +#define isc_buffer_initnull isc__buffer_initnull +#define isc_buffer_invalidate isc__buffer_invalidate +#define isc_buffer_region isc__buffer_region +#define isc_buffer_usedregion isc__buffer_usedregion +#define isc_buffer_availableregion isc__buffer_availableregion +#define isc_buffer_add isc__buffer_add +#define isc_buffer_subtract isc__buffer_subtract +#define isc_buffer_clear isc__buffer_clear +#define isc_buffer_consumedregion isc__buffer_consumedregion +#define isc_buffer_remainingregion isc__buffer_remainingregion +#define isc_buffer_activeregion isc__buffer_activeregion +#define isc_buffer_setactive isc__buffer_setactive +#define isc_buffer_first isc__buffer_first +#define isc_buffer_forward isc__buffer_forward +#define isc_buffer_back isc__buffer_back +#define isc_buffer_putmem isc__buffer_putmem +#define isc_buffer_putstr isc__buffer_putstr +#define isc_buffer_putuint8 isc__buffer_putuint8 +#define isc_buffer_putuint16 isc__buffer_putuint16 +#define isc_buffer_putuint24 isc__buffer_putuint24 +#define isc_buffer_putuint32 isc__buffer_putuint32 +#endif + +/* + * No inline method for this one (yet). + */ +#define isc_buffer_putuint48 isc__buffer_putuint48 + +#endif /* ISC_BUFFER_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/bufferlist.h src.ntp/contrib/ntp/lib/isc/include/isc/bufferlist.h --- src/contrib/ntp/lib/isc/include/isc/bufferlist.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/bufferlist.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,86 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: bufferlist.h,v 1.17 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_BUFFERLIST_H +#define ISC_BUFFERLIST_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/bufferlist.h + * + * + *\brief Buffer lists have no synchronization. Clients must ensure exclusive + * access. + * + * \li Reliability: + * No anticipated impact. + + * \li Security: + * No anticipated impact. + * + * \li Standards: + * None. + */ + +/*** + *** Imports + ***/ + +#include +#include + +ISC_LANG_BEGINDECLS + +/*** + *** Functions + ***/ + +unsigned int +isc_bufferlist_usedcount(isc_bufferlist_t *bl); +/*!< + * \brief Return the length of the sum of all used regions of all buffers in + * the buffer list 'bl' + * + * Requires: + * + *\li 'bl' is not NULL. + * + * Returns: + *\li sum of all used regions' lengths. + */ + +unsigned int +isc_bufferlist_availablecount(isc_bufferlist_t *bl); +/*!< + * \brief Return the length of the sum of all available regions of all buffers in + * the buffer list 'bl' + * + * Requires: + * + *\li 'bl' is not NULL. + * + * Returns: + *\li sum of all available regions' lengths. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_BUFFERLIST_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/commandline.h src.ntp/contrib/ntp/lib/isc/include/isc/commandline.h --- src/contrib/ntp/lib/isc/include/isc/commandline.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/commandline.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,50 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: commandline.h,v 1.16 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_COMMANDLINE_H +#define ISC_COMMANDLINE_H 1 + +/*! \file isc/commandline.h */ + +#include +#include +#include + +/*% Index into parent argv vector. */ +LIBISC_EXTERNAL_DATA extern int isc_commandline_index; +/*% Character checked for validity. */ +LIBISC_EXTERNAL_DATA extern int isc_commandline_option; +/*% Argument associated with option. */ +LIBISC_EXTERNAL_DATA extern char *isc_commandline_argument; +/*% For printing error messages. */ +LIBISC_EXTERNAL_DATA extern char *isc_commandline_progname; +/*% Print error message. */ +LIBISC_EXTERNAL_DATA extern isc_boolean_t isc_commandline_errprint; +/*% Reset getopt. */ +LIBISC_EXTERNAL_DATA extern isc_boolean_t isc_commandline_reset; + +ISC_LANG_BEGINDECLS + +/*% parse command line */ +int +isc_commandline_parse(int argc, char * const *argv, const char *options); + +ISC_LANG_ENDDECLS + +#endif /* ISC_COMMANDLINE_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/entropy.h src.ntp/contrib/ntp/lib/isc/include/isc/entropy.h --- src/contrib/ntp/lib/isc/include/isc/entropy.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/entropy.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,314 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: entropy.h,v 1.32.332.2 2009/01/18 23:47:41 tbox Exp $ */ + +#ifndef ISC_ENTROPY_H +#define ISC_ENTROPY_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/entropy.h + * \brief The entropy API + * + * \li MP: + * The entropy object is locked internally. All callbacks into + * application-provided functions (for setup, gathering, and + * shutdown of sources) are guaranteed to be called with the + * entropy API lock held. This means these functions are + * not permitted to call back into the entropy API. + * + * \li Reliability: + * No anticipated impact. + * + * \li Resources: + * A buffer, used as an entropy pool. + * + * \li Security: + * While this code is believed to implement good entropy gathering + * and distribution, it has not been reviewed by a cryptographic + * expert. + * Since the added entropy is only as good as the sources used, + * this module could hand out bad data and never know it. + * + * \li Standards: + * None. + */ + +/*** + *** Imports + ***/ + +#include + +#include +#include + +/*@{*/ +/*% Entropy callback function. */ +typedef isc_result_t (*isc_entropystart_t)(isc_entropysource_t *source, + void *arg, isc_boolean_t blocking); +typedef isc_result_t (*isc_entropyget_t)(isc_entropysource_t *source, + void *arg, isc_boolean_t blocking); +typedef void (*isc_entropystop_t)(isc_entropysource_t *source, void *arg); +/*@}*/ + +/*** + *** Flags. + ***/ + +/*! + * \brief + * Extract only "good" data; return failure if there is not enough + * data available and there are no sources which we can poll to get + * data, or those sources are empty. + * + * + */ +#define ISC_ENTROPY_GOODONLY 0x00000001U +/*! + * \brief + * Extract as much good data as possible, but if there isn't enough + * at hand, return what is available. This flag only makes sense + * when used with _GOODONLY. + */ +#define ISC_ENTROPY_PARTIAL 0x00000002U +/*! + * \brief + * Block the task until data is available. This is contrary to the + * ISC task system, where tasks should never block. However, if + * this is a special purpose application where blocking a task is + * acceptable (say, an offline zone signer) this flag may be set. + * This flag only makes sense when used with _GOODONLY, and will + * block regardless of the setting for _PARTIAL. + */ +#define ISC_ENTROPY_BLOCKING 0x00000004U + +/*! + * \brief + * Estimate the amount of entropy contained in the sample pool. + * If this is not set, the source will be gathered and periodically + * mixed into the entropy pool, but no increment in contained entropy + * will be assumed. This flag only makes sense on sample sources. + */ +#define ISC_ENTROPYSOURCE_ESTIMATE 0x00000001U + +/* + * For use with isc_entropy_usebestsource(). + */ +/*! + * \brief + * Use the keyboard as the only entropy source. + */ +#define ISC_ENTROPY_KEYBOARDYES 1 +/*! + * \brief + * Never use the keyboard as an entropy source. + */ +#define ISC_ENTROPY_KEYBOARDNO 2 +/*! + * \brief + * Use the keyboard as an entropy source only if opening the + * random device fails. + */ +#define ISC_ENTROPY_KEYBOARDMAYBE 3 + +ISC_LANG_BEGINDECLS + +/*** + *** Functions + ***/ + +isc_result_t +isc_entropy_create(isc_mem_t *mctx, isc_entropy_t **entp); +/*!< + * \brief Create a new entropy object. + */ + +void +isc_entropy_attach(isc_entropy_t *ent, isc_entropy_t **entp); +/*!< + * Attaches to an entropy object. + */ + +void +isc_entropy_detach(isc_entropy_t **entp); +/*!< + * \brief Detaches from an entropy object. + */ + +isc_result_t +isc_entropy_createfilesource(isc_entropy_t *ent, const char *fname); +/*!< + * \brief Create a new entropy source from a file. + * + * The file is assumed to contain good randomness, and will be mixed directly + * into the pool with every byte adding 8 bits of entropy. + * + * The file will be put into non-blocking mode, so it may be a device file, + * such as /dev/random. /dev/urandom should not be used here if it can + * be avoided, since it will always provide data even if it isn't good. + * We will make as much pseudorandom data as we need internally if our + * caller asks for it. + * + * If we hit end-of-file, we will stop reading from this source. Callers + * who require strong random data will get failure when our pool drains. + * The file will never be opened/read again once EOF is reached. + */ + +void +isc_entropy_destroysource(isc_entropysource_t **sourcep); +/*!< + * \brief Removes an entropy source from the entropy system. + */ + +isc_result_t +isc_entropy_createsamplesource(isc_entropy_t *ent, + isc_entropysource_t **sourcep); +/*!< + * \brief Create an entropy source that consists of samples. Each sample is added + * to the source via isc_entropy_addsamples(), below. + */ + +isc_result_t +isc_entropy_createcallbacksource(isc_entropy_t *ent, + isc_entropystart_t start, + isc_entropyget_t get, + isc_entropystop_t stop, + void *arg, + isc_entropysource_t **sourcep); +/*!< + * \brief Create an entropy source that is polled via a callback. + * + * This would + * be used when keyboard input is used, or a GUI input method. It can + * also be used to hook in any external entropy source. + * + * Samples are added via isc_entropy_addcallbacksample(), below. + * _addcallbacksample() is the only function which may be called from + * within an entropy API callback function. + */ + +void +isc_entropy_stopcallbacksources(isc_entropy_t *ent); +/*!< + * \brief Call the stop functions for callback sources that have had their + * start functions called. + */ + +/*@{*/ +isc_result_t +isc_entropy_addcallbacksample(isc_entropysource_t *source, isc_uint32_t sample, + isc_uint32_t extra); +isc_result_t +isc_entropy_addsample(isc_entropysource_t *source, isc_uint32_t sample, + isc_uint32_t extra); +/*!< + * \brief Add a sample to the sample source. + * + * The sample MUST be a timestamp + * that increases over time, with the exception of wrap-around for + * extremely high resolution timers which will quickly wrap-around + * a 32-bit integer. + * + * The "extra" parameter is used only to add a bit more unpredictable + * data. It is not used other than included in the hash of samples. + * + * When in an entropy API callback function, _addcallbacksource() must be + * used. At all other times, _addsample() must be used. + */ +/*@}*/ + +isc_result_t +isc_entropy_getdata(isc_entropy_t *ent, void *data, unsigned int length, + unsigned int *returned, unsigned int flags); +/*!< + * \brief Extract data from the entropy pool. This may load the pool from various + * sources. + * + * Do this by stiring the pool and returning a part of hash as randomness. + * Note that no secrets are given away here since parts of the hash are + * xored together before returned. + * + * Honor the request from the caller to only return good data, any data, + * etc. + */ + +void +isc_entropy_putdata(isc_entropy_t *ent, void *data, unsigned int length, + isc_uint32_t entropy); +/*!< + * \brief Add "length" bytes in "data" to the entropy pool, incrementing the pool's + * entropy count by "entropy." + * + * These bytes will prime the pseudorandom portion even no entropy is actually + * added. + */ + +void +isc_entropy_stats(isc_entropy_t *ent, FILE *out); +/*!< + * \brief Dump some (trivial) stats to the stdio stream "out". + */ + +unsigned int +isc_entropy_status(isc_entropy_t *end); +/* + * Returns the number of bits the pool currently contains. This is just + * an estimate. + */ + +isc_result_t +isc_entropy_usebestsource(isc_entropy_t *ectx, isc_entropysource_t **source, + const char *randomfile, int use_keyboard); +/*!< + * \brief Use whatever source of entropy is best. + * + * Notes: + *\li If "randomfile" is not NULL, open it with + * isc_entropy_createfilesource(). + * + *\li If "randomfile" is NULL and the system's random device was detected + * when the program was configured and built, open that device with + * isc_entropy_createfilesource(). + * + *\li If "use_keyboard" is #ISC_ENTROPY_KEYBOARDYES, then always open + * the keyboard as an entropy source (possibly in addition to + * "randomfile" or the random device). + * + *\li If "use_keyboard" is #ISC_ENTROPY_KEYBOARDMAYBE, open the keyboard only + * if opening the random file/device fails. A message will be + * printed describing the need for keyboard input. + * + *\li If "use_keyboard" is #ISC_ENTROPY_KEYBOARDNO, the keyboard will + * never be opened. + * + * Returns: + *\li #ISC_R_SUCCESS if at least one source of entropy could be started. + * + *\li #ISC_R_NOENTROPY if use_keyboard is #ISC_ENTROPY_KEYBOARDNO and + * there is no random device pathname compiled into the program. + * + *\li A return code from isc_entropy_createfilesource() or + * isc_entropy_createcallbacksource(). + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_ENTROPY_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/error.h src.ntp/contrib/ntp/lib/isc/include/isc/error.h --- src/contrib/ntp/lib/isc/include/isc/error.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/error.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,62 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: error.h,v 1.20 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_ERROR_H +#define ISC_ERROR_H 1 + +/*! \file isc/error.h */ + +#include + +#include +#include + +ISC_LANG_BEGINDECLS + +typedef void (*isc_errorcallback_t)(const char *, int, const char *, va_list); + +/*% set unexpected error */ +void +isc_error_setunexpected(isc_errorcallback_t); + +/*% set fatal error */ +void +isc_error_setfatal(isc_errorcallback_t); + +/*% unexpected error */ +void +isc_error_unexpected(const char *, int, const char *, ...) + ISC_FORMAT_PRINTF(3, 4); + +/*% fatal error */ +void +isc_error_fatal(const char *, int, const char *, ...) + ISC_FORMAT_PRINTF(3, 4); + +/*% runtimecheck error */ +void +isc_error_runtimecheck(const char *, int, const char *); + +#define ISC_ERROR_RUNTIMECHECK(cond) \ + ((void) ((cond) || \ + ((isc_error_runtimecheck)(__FILE__, __LINE__, #cond), 0))) + +ISC_LANG_ENDDECLS + +#endif /* ISC_ERROR_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/event.h src.ntp/contrib/ntp/lib/isc/include/isc/event.h --- src/contrib/ntp/lib/isc/include/isc/event.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/event.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,121 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: event.h,v 1.34 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_EVENT_H +#define ISC_EVENT_H 1 + +/*! \file isc/event.h */ + +#include +#include + +/***** + ***** Events. + *****/ + +typedef void (*isc_eventdestructor_t)(isc_event_t *); + +#define ISC_EVENT_COMMON(ltype) \ + size_t ev_size; \ + unsigned int ev_attributes; \ + void * ev_tag; \ + isc_eventtype_t ev_type; \ + isc_taskaction_t ev_action; \ + void * ev_arg; \ + void * ev_sender; \ + isc_eventdestructor_t ev_destroy; \ + void * ev_destroy_arg; \ + ISC_LINK(ltype) ev_link + +/*% + * Attributes matching a mask of 0x000000ff are reserved for the task library's + * definition. Attributes of 0xffffff00 may be used by the application + * or non-ISC libraries. + */ +#define ISC_EVENTATTR_NOPURGE 0x00000001 + +/*% + * The ISC_EVENTATTR_CANCELED attribute is intended to indicate + * that an event is delivered as a result of a canceled operation + * rather than successful completion, by mutual agreement + * between the sender and receiver. It is not set or used by + * the task system. + */ +#define ISC_EVENTATTR_CANCELED 0x00000002 + +#define ISC_EVENT_INIT(event, sz, at, ta, ty, ac, ar, sn, df, da) \ +do { \ + (event)->ev_size = (sz); \ + (event)->ev_attributes = (at); \ + (event)->ev_tag = (ta); \ + (event)->ev_type = (ty); \ + (event)->ev_action = (ac); \ + (event)->ev_arg = (ar); \ + (event)->ev_sender = (sn); \ + (event)->ev_destroy = (df); \ + (event)->ev_destroy_arg = (da); \ + ISC_LINK_INIT((event), ev_link); \ +} while (0) + +/*% + * This structure is public because "subclassing" it may be useful when + * defining new event types. + */ +struct isc_event { + ISC_EVENT_COMMON(struct isc_event); +}; + +#define ISC_EVENTTYPE_FIRSTEVENT 0x00000000 +#define ISC_EVENTTYPE_LASTEVENT 0xffffffff + +#define ISC_EVENT_PTR(p) ((isc_event_t **)(void *)(p)) + +ISC_LANG_BEGINDECLS + +isc_event_t * +isc_event_allocate(isc_mem_t *mctx, void *sender, isc_eventtype_t type, + isc_taskaction_t action, const void *arg, size_t size); +/*%< + * Allocate an event structure. + * + * Allocate and initialize in a structure with initial elements + * defined by: + * + * \code + * struct { + * ISC_EVENT_COMMON(struct isc_event); + * ... + * }; + * \endcode + * + * Requires: + *\li 'size' >= sizeof(struct isc_event) + *\li 'action' to be non NULL + * + * Returns: + *\li a pointer to a initialized structure of the requested size. + *\li NULL if unable to allocate memory. + */ + +void +isc_event_free(isc_event_t **); + +ISC_LANG_ENDDECLS + +#endif /* ISC_EVENT_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/eventclass.h src.ntp/contrib/ntp/lib/isc/include/isc/eventclass.h --- src/contrib/ntp/lib/isc/include/isc/eventclass.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/eventclass.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,53 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: eventclass.h,v 1.18 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_EVENTCLASS_H +#define ISC_EVENTCLASS_H 1 + +/*! \file isc/eventclass.h + ***** Registry of Predefined Event Type Classes + *****/ + +/*% + * An event class is an unsigned 16 bit number. Each class may contain up + * to 65536 events. An event type is formed by adding the event number + * within the class to the class number. + * + */ + +#define ISC_EVENTCLASS(eclass) ((eclass) << 16) + +/*@{*/ +/*! + * Classes < 1024 are reserved for ISC use. + * Event classes >= 1024 and <= 65535 are reserved for application use. + */ + +#define ISC_EVENTCLASS_TASK ISC_EVENTCLASS(0) +#define ISC_EVENTCLASS_TIMER ISC_EVENTCLASS(1) +#define ISC_EVENTCLASS_SOCKET ISC_EVENTCLASS(2) +#define ISC_EVENTCLASS_FILE ISC_EVENTCLASS(3) +#define ISC_EVENTCLASS_DNS ISC_EVENTCLASS(4) +#define ISC_EVENTCLASS_APP ISC_EVENTCLASS(5) +#define ISC_EVENTCLASS_OMAPI ISC_EVENTCLASS(6) +#define ISC_EVENTCLASS_RATELIMITER ISC_EVENTCLASS(7) +#define ISC_EVENTCLASS_ISCCC ISC_EVENTCLASS(8) +/*@}*/ + +#endif /* ISC_EVENTCLASS_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/file.h src.ntp/contrib/ntp/lib/isc/include/isc/file.h --- src/contrib/ntp/lib/isc/include/isc/file.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/file.h 2009-12-09 08:36:44.000000000 +0100 @@ -0,0 +1,256 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: file.h,v 1.33.332.2 2009/01/18 23:47:41 tbox Exp $ */ + +#ifndef ISC_FILE_H +#define ISC_FILE_H 1 + +/*! \file isc/file.h */ + +#include + +#include +#include + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_file_settime(const char *file, isc_time_t *time); + +isc_result_t +isc_file_getmodtime(const char *file, isc_time_t *time); +/*!< + * \brief Get the time of last modification of a file. + * + * Notes: + *\li The time that is set is relative to the (OS-specific) epoch, as are + * all isc_time_t structures. + * + * Requires: + *\li file != NULL. + *\li time != NULL. + * + * Ensures: + *\li If the file could not be accessed, 'time' is unchanged. + * + * Returns: + *\li #ISC_R_SUCCESS + * Success. + *\li #ISC_R_NOTFOUND + * No such file exists. + *\li #ISC_R_INVALIDFILE + * The path specified was not usable by the operating system. + *\li #ISC_R_NOPERM + * The file's metainformation could not be retrieved because + * permission was denied to some part of the file's path. + *\li #ISC_R_EIO + * Hardware error interacting with the filesystem. + *\li #ISC_R_UNEXPECTED + * Something totally unexpected happened. + * + */ + +isc_result_t +isc_file_mktemplate(const char *path, char *buf, size_t buflen); +/*!< + * \brief Generate a template string suitable for use with isc_file_openunique(). + * + * Notes: + *\li This function is intended to make creating temporary files + * portable between different operating systems. + * + *\li The path is prepended to an implementation-defined string and + * placed into buf. The string has no path characters in it, + * and its maximum length is 14 characters plus a NUL. Thus + * buflen should be at least strlen(path) + 15 characters or + * an error will be returned. + * + * Requires: + *\li buf != NULL. + * + * Ensures: + *\li If result == #ISC_R_SUCCESS: + * buf contains a string suitable for use as the template argument + * to isc_file_openunique(). + * + *\li If result != #ISC_R_SUCCESS: + * buf is unchanged. + * + * Returns: + *\li #ISC_R_SUCCESS Success. + *\li #ISC_R_NOSPACE buflen indicates buf is too small for the catenation + * of the path with the internal template string. + */ + + +isc_result_t +isc_file_openunique(char *templet, FILE **fp); +/*!< + * \brief Create and open a file with a unique name based on 'templet'. + * + * Notes: + *\li 'template' is a reserved work in C++. If you want to complain + * about the spelling of 'templet', first look it up in the + * Merriam-Webster English dictionary. (http://www.m-w.com/) + * + *\li This function works by using the template to generate file names. + * The template must be a writable string, as it is modified in place. + * Trailing X characters in the file name (full file name on Unix, + * basename on Win32 -- eg, tmp-XXXXXX vs XXXXXX.tmp, respectively) + * are replaced with ASCII characters until a non-existent filename + * is found. If the template does not include pathname information, + * the files in the working directory of the program are searched. + * + *\li isc_file_mktemplate is a good, portable way to get a template. + * + * Requires: + *\li 'fp' is non-NULL and '*fp' is NULL. + * + *\li 'template' is non-NULL, and of a form suitable for use by + * the system as described above. + * + * Ensures: + *\li If result is #ISC_R_SUCCESS: + * *fp points to an stream opening in stdio's "w+" mode. + * + *\li If result is not #ISC_R_SUCCESS: + * *fp is NULL. + * + * No file is open. Even if one was created (but unable + * to be reopened as a stdio FILE pointer) then it has been + * removed. + * + *\li This function does *not* ensure that the template string has not been + * modified, even if the operation was unsuccessful. + * + * Returns: + *\li #ISC_R_SUCCESS + * Success. + *\li #ISC_R_EXISTS + * No file with a unique name could be created based on the + * template. + *\li #ISC_R_INVALIDFILE + * The path specified was not usable by the operating system. + *\li #ISC_R_NOPERM + * The file could not be created because permission was denied + * to some part of the file's path. + *\li #ISC_R_IOERROR + * Hardware error interacting with the filesystem. + *\li #ISC_R_UNEXPECTED + * Something totally unexpected happened. + */ + +isc_result_t +isc_file_remove(const char *filename); +/*!< + * \brief Remove the file named by 'filename'. + */ + +isc_result_t +isc_file_rename(const char *oldname, const char *newname); +/*!< + * \brief Rename the file 'oldname' to 'newname'. + */ + +isc_boolean_t +isc_file_exists(const char *pathname); +/*!< + * \brief Return #ISC_TRUE if the calling process can tell that the given file exists. + * Will not return true if the calling process has insufficient privileges + * to search the entire path. + */ + +isc_boolean_t +isc_file_isabsolute(const char *filename); +/*!< + * \brief Return #ISC_TRUE if the given file name is absolute. + */ + +isc_boolean_t +isc_file_iscurrentdir(const char *filename); +/*!< + * \brief Return #ISC_TRUE if the given file name is the current directory ("."). + */ + +isc_boolean_t +isc_file_ischdiridempotent(const char *filename); +/*%< + * Return #ISC_TRUE if calling chdir(filename) multiple times will give + * the same result as calling it once. + */ + +const char * +isc_file_basename(const char *filename); +/*%< + * Return the final component of the path in the file name. + */ + +isc_result_t +isc_file_progname(const char *filename, char *buf, size_t buflen); +/*!< + * \brief Given an operating system specific file name "filename" + * referring to a program, return the canonical program name. + * + * + * Any directory prefix or executable file name extension (if + * used on the OS in case) is stripped. On systems where program + * names are case insensitive, the name is canonicalized to all + * lower case. The name is written to 'buf', an array of 'buflen' + * chars, and null terminated. + * + * Returns: + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOSPACE The name did not fit in 'buf'. + */ + +isc_result_t +isc_file_template(const char *path, const char *templet, char *buf, + size_t buflen); +/*%< + * Create an OS specific template using 'path' to define the directory + * 'templet' to describe the filename and store the result in 'buf' + * such that path can be renamed to buf atomically. + */ + +isc_result_t +isc_file_renameunique(const char *file, char *templet); +/*%< + * Rename 'file' using 'templet' as a template for the new file name. + */ + +isc_result_t +isc_file_absolutepath(const char *filename, char *path, size_t pathlen); +/*%< + * Given a file name, return the fully qualified path to the file. + */ + +/* + * XXX We should also have a isc_file_writeeopen() function + * for safely open a file in a publicly writable directory + * (see write_open() in BIND 8's ns_config.c). + */ + +isc_result_t +isc_file_truncate(const char *filename, isc_offset_t size); +/*%< + * Truncate/extend the file specified to 'size' bytes. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_FILE_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/formatcheck.h src.ntp/contrib/ntp/lib/isc/include/isc/formatcheck.h --- src/contrib/ntp/lib/isc/include/isc/formatcheck.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/formatcheck.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,40 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: formatcheck.h,v 1.13 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_FORMATCHECK_H +#define ISC_FORMATCHECK_H 1 + +/*! \file isc/formatcheck.h */ + +/*% + * ISC_FORMAT_PRINTF(). + * + * \li fmt is the location of the format string parameter. + * \li args is the location of the first argument (or 0 for no argument checking). + * + * Note: + * \li The first parameter is 1, not 0. + */ +#ifdef __GNUC__ +#define ISC_FORMAT_PRINTF(fmt, args) __attribute__((__format__(__printf__, fmt, args))) +#else +#define ISC_FORMAT_PRINTF(fmt, args) +#endif + +#endif /* ISC_FORMATCHECK_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/fsaccess.h src.ntp/contrib/ntp/lib/isc/include/isc/fsaccess.h --- src/contrib/ntp/lib/isc/include/isc/fsaccess.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/fsaccess.h 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,178 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: fsaccess.h,v 1.14.332.2 2009/01/18 23:47:41 tbox Exp $ */ + +#ifndef ISC_FSACCESS_H +#define ISC_FSACCESS_H 1 + +/*! \file isc/fsaccess.h + * \brief The ISC filesystem access module encapsulates the setting of file + * and directory access permissions into one API that is meant to be + * portable to multiple operating systems. + * + * The two primary operating system flavors that are initially accommodated + * are POSIX and Windows NT 4.0 and later. The Windows NT access model is + * considerable more flexible than POSIX's model (as much as I am loathe to + * admit it), and so the ISC API has a higher degree of complexity than would + * be needed to simply address POSIX's needs. + * + * The full breadth of NT's flexibility is not available either, for the + * present time. Much of it is to provide compatibility with what Unix + * programmers are expecting. This is also due to not yet really needing all + * of the functionality of an NT system (or, for that matter, a POSIX system) + * in BIND9, and so resolving how to handle the various incompatibilities has + * been a purely theoretical exercise with no operational experience to + * indicate how flawed the thinking may be. + * + * Some of the more notable dumbing down of NT for this API includes: + * + *\li Each of FILE_READ_DATA and FILE_READ_EA are set with #ISC_FSACCESS_READ. + * + * \li All of FILE_WRITE_DATA, FILE_WRITE_EA and FILE_APPEND_DATA are + * set with #ISC_FSACCESS_WRITE. FILE_WRITE_ATTRIBUTES is not set + * so as to be consistent with Unix, where only the owner of the file + * or the superuser can change the attributes/mode of a file. + * + * \li Both of FILE_ADD_FILE and FILE_ADD_SUBDIRECTORY are set with + * #ISC_FSACCESS_CREATECHILD. This is similar to setting the WRITE + * permission on a Unix directory. + * + * \li SYNCHRONIZE is always set for files and directories, unless someone + * can give me a reason why this is a bad idea. + * + * \li READ_CONTROL and FILE_READ_ATTRIBUTES are always set; this is + * consistent with Unix, where any file or directory can be stat()'d + * unless the directory path disallows complete access somewhere along + * the way. + * + * \li WRITE_DAC is only set for the owner. This too is consistent with + * Unix, and is tighter security than allowing anyone else to be + * able to set permissions. + * + * \li DELETE is only set for the owner. On Unix the ability to delete + * a file is controlled by the directory permissions, but it isn't + * currently clear to me what happens on NT if the directory has + * FILE_DELETE_CHILD set but a file within it does not have DELETE + * set. Always setting DELETE on the file/directory for the owner + * gives maximum flexibility to the owner without exposing the + * file to deletion by others. + * + * \li WRITE_OWNER is never set. This too is consistent with Unix, + * and is also tighter security than allowing anyone to change the + * ownership of the file apart from the superu..ahem, Administrator. + * + * \li Inheritance is set to NO_INHERITANCE. + * + * Unix's dumbing down includes: + * + * \li The sticky bit cannot be set. + * + * \li setuid and setgid cannot be set. + * + * \li Only regular files and directories can be set. + * + * The rest of this comment discusses a few of the incompatibilities + * between the two systems that need more thought if this API is to + * be extended to accommodate them. + * + * The Windows standard access right "DELETE" doesn't have a direct + * equivalent in the Unix world, so it isn't clear what should be done + * with it. + * + * The Unix sticky bit is not supported. While NT does have a concept + * of allowing users to create files in a directory but not delete or + * rename them, it does not have a concept of allowing them to be deleted + * if they are owned by the user trying to delete/rename. While it is + * probable that something could be cobbled together in NT 5 with inheritance, + * it can't really be done in NT 4 as a single property that you could + * set on a directory. You'd need to coordinate something with file creation + * so that every file created had DELETE set for the owner but noone else. + * + * On Unix systems, setting #ISC_FSACCESS_LISTDIRECTORY sets READ. + * ... setting either #ISC_FSACCESS_CREATECHILD or #ISC_FSACCESS_DELETECHILD + * sets WRITE. + * ... setting #ISC_FSACCESS_ACCESSCHILD sets EXECUTE. + * + * On NT systems, setting #ISC_FSACCESS_LISTDIRECTORY sets FILE_LIST_DIRECTORY. + * ... setting #ISC_FSACCESS_CREATECHILD sets FILE_CREATE_CHILD independently. + * ... setting #ISC_FSACCESS_DELETECHILD sets FILE_DELETE_CHILD independently. + * ... setting #ISC_FSACCESS_ACCESSCHILD sets FILE_TRAVERSE. + * + * Unresolved: XXXDCL + * \li What NT access right controls the ability to rename a file? + * \li How does DELETE work? If a directory has FILE_DELETE_CHILD but a + * file or directory within it does not have DELETE, is that file + * or directory deletable? + * \li To implement isc_fsaccess_get(), mapping an existing Unix permission + * mode_t back to an isc_fsaccess_t is pretty trivial; however, mapping + * an NT DACL could be impossible to do in a responsible way. + * \li Similarly, trying to implement the functionality of being able to + * say "add group writability to whatever permissions already exist" + * could be tricky on NT because of the order-of-entry issue combined + * with possibly having one or more matching ACEs already explicitly + * granting or denying access. Because this functionality is + * not yet needed by the ISC, no code has been written to try to + * solve this problem. + */ + +#include +#include + +/* + * Trustees. + */ +#define ISC_FSACCESS_OWNER 0x1 /*%< User account. */ +#define ISC_FSACCESS_GROUP 0x2 /*%< Primary group owner. */ +#define ISC_FSACCESS_OTHER 0x4 /*%< Not the owner or the group owner. */ +#define ISC_FSACCESS_WORLD 0x7 /*%< User, Group, Other. */ + +/* + * Types of permission. + */ +#define ISC_FSACCESS_READ 0x00000001 /*%< File only. */ +#define ISC_FSACCESS_WRITE 0x00000002 /*%< File only. */ +#define ISC_FSACCESS_EXECUTE 0x00000004 /*%< File only. */ +#define ISC_FSACCESS_CREATECHILD 0x00000008 /*%< Dir only. */ +#define ISC_FSACCESS_DELETECHILD 0x00000010 /*%< Dir only. */ +#define ISC_FSACCESS_LISTDIRECTORY 0x00000020 /*%< Dir only. */ +#define ISC_FSACCESS_ACCESSCHILD 0x00000040 /*%< Dir only. */ + +/*% + * Adding any permission bits beyond 0x200 would mean typedef'ing + * isc_fsaccess_t as isc_uint64_t, and redefining this value to + * reflect the new range of permission types, Probably to 21 for + * maximum flexibility. The number of bits has to accommodate all of + * the permission types, and three full sets of them have to fit + * within an isc_fsaccess_t. + */ +#define ISC__FSACCESS_PERMISSIONBITS 10 + +ISC_LANG_BEGINDECLS + +void +isc_fsaccess_add(int trustee, int permission, isc_fsaccess_t *access); + +void +isc_fsaccess_remove(int trustee, int permission, isc_fsaccess_t *access); + +isc_result_t +isc_fsaccess_set(const char *path, isc_fsaccess_t access); + +ISC_LANG_ENDDECLS + +#endif /* ISC_FSACCESS_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/hash.h src.ntp/contrib/ntp/lib/isc/include/isc/hash.h --- src/contrib/ntp/lib/isc/include/isc/hash.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/hash.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,185 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: hash.h,v 1.10.332.2 2009/01/18 23:47:41 tbox Exp $ */ + +#ifndef ISC_HASH_H +#define ISC_HASH_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/hash.h + * + * \brief The hash API + * provides an unpredictable hash value for variable length data. + * A hash object contains a random vector (which is hidden from clients + * of this API) to make the actual hash value unpredictable. + * + * The algorithm used in the API guarantees the probability of hash + * collision; in the current implementation, as long as the values stored + * in the random vector are unpredictable, the probability of hash + * collision between arbitrary two different values is at most 1/2^16. + * + * Although the API is generic about the hash keys, it mainly expects + * DNS names (and sometimes IPv4/v6 addresses) as inputs. It has an + * upper limit of the input length, and may run slow to calculate the + * hash values for large inputs. + * + * This API is designed to be general so that it can provide multiple + * different hash contexts that have different random vectors. However, + * it should be typical to have a single context for an entire system. + * To support such cases, the API also provides a single-context mode. + * + * \li MP: + * The hash object is almost read-only. Once the internal random vector + * is initialized, no write operation will occur, and there will be no + * need to lock the object to calculate actual hash values. + * + * \li Reliability: + * In some cases this module uses low-level data copy to initialize the + * random vector. Errors in this part are likely to crash the server or + * corrupt memory. + * + * \li Resources: + * A buffer, used as a random vector for calculating hash values. + * + * \li Security: + * This module intends to provide unpredictable hash values in + * adversarial environments in order to avoid denial of service attacks + * to hash buckets. + * Its unpredictability relies on the quality of entropy to build the + * random vector. + * + * \li Standards: + * None. + */ + +/*** + *** Imports + ***/ + +#include + +/*** + *** Functions + ***/ +ISC_LANG_BEGINDECLS + +isc_result_t +isc_hash_ctxcreate(isc_mem_t *mctx, isc_entropy_t *entropy, unsigned int limit, + isc_hash_t **hctx); +isc_result_t +isc_hash_create(isc_mem_t *mctx, isc_entropy_t *entropy, size_t limit); +/*!< + * \brief Create a new hash object. + * + * isc_hash_ctxcreate() creates a different object. + * + * isc_hash_create() creates a module-internal object to support the + * single-context mode. It should be called only once. + * + * 'entropy' must be NULL or a valid entropy object. If 'entropy' is NULL, + * pseudo random values will be used to build the random vector, which may + * weaken security. + * + * 'limit' specifies the maximum number of hash keys. If it is too large, + * these functions may fail. + */ + +void +isc_hash_ctxattach(isc_hash_t *hctx, isc_hash_t **hctxp); +/*!< + * \brief Attach to a hash object. + * + * This function is only necessary for the multiple-context mode. + */ + +void +isc_hash_ctxdetach(isc_hash_t **hctxp); +/*!< + * \brief Detach from a hash object. + * + * This function is for the multiple-context mode, and takes a valid + * hash object as an argument. + */ + +void +isc_hash_destroy(void); +/*!< + * \brief This function is for the single-context mode, and is expected to be used + * as a counterpart of isc_hash_create(). + * + * A valid module-internal hash object must have been created, and this + * function should be called only once. + */ + +/*@{*/ +void +isc_hash_ctxinit(isc_hash_t *hctx); +void +isc_hash_init(void); +/*!< + * \brief Initialize a hash object. + * + * It fills in the random vector with a proper + * source of entropy, which is typically from the entropy object specified + * at the creation. Thus, it is desirable to call these functions after + * initializing the entropy object with some good entropy sources. + * + * These functions should be called before the first hash calculation. + * + * isc_hash_ctxinit() is for the multiple-context mode, and takes a valid hash + * object as an argument. + * + * isc_hash_init() is for the single-context mode. A valid module-internal + * hash object must have been created, and this function should be called only + * once. + */ +/*@}*/ + +/*@{*/ +unsigned int +isc_hash_ctxcalc(isc_hash_t *hctx, const unsigned char *key, + unsigned int keylen, isc_boolean_t case_sensitive); +unsigned int +isc_hash_calc(const unsigned char *key, unsigned int keylen, + isc_boolean_t case_sensitive); +/*!< + * \brief Calculate a hash value. + * + * isc_hash_ctxinit() is for the multiple-context mode, and takes a valid hash + * object as an argument. + * + * isc_hash_init() is for the single-context mode. A valid module-internal + * hash object must have been created. + * + * 'key' is the hash key, which is a variable length buffer. + * + * 'keylen' specifies the key length, which must not be larger than the limit + * specified for the corresponding hash object. + * + * 'case_sensitive' specifies whether the hash key should be treated as + * case_sensitive values. It should typically be ISC_FALSE if the hash key + * is a DNS name. + */ +/*@}*/ + +ISC_LANG_ENDDECLS + +#endif /* ISC_HASH_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/heap.h src.ntp/contrib/ntp/lib/isc/include/isc/heap.h --- src/contrib/ntp/lib/isc/include/isc/heap.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/heap.h 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,170 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1997-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: heap.h,v 1.24.332.2 2009/01/18 23:47:41 tbox Exp $ */ + +#ifndef ISC_HEAP_H +#define ISC_HEAP_H 1 + +/*! \file isc/heap.h */ + +#include +#include + +ISC_LANG_BEGINDECLS + +/*% + * The comparison function returns ISC_TRUE if the first argument has + * higher priority than the second argument, and ISC_FALSE otherwise. + */ +typedef isc_boolean_t (*isc_heapcompare_t)(void *, void *); + +/*% + * The index function allows the client of the heap to receive a callback + * when an item's index number changes. This allows it to maintain + * sync with its external state, but still delete itself, since deletions + * from the heap require the index be provided. + */ +typedef void (*isc_heapindex_t)(void *, unsigned int); + +/*% + * The heapaction function is used when iterating over the heap. + * + * NOTE: The heap structure CANNOT BE MODIFIED during the call to + * isc_heap_foreach(). + */ +typedef void (*isc_heapaction_t)(void *, void *); + +typedef struct isc_heap isc_heap_t; + +isc_result_t +isc_heap_create(isc_mem_t *mctx, isc_heapcompare_t compare, + isc_heapindex_t index, unsigned int size_increment, + isc_heap_t **heapp); +/*!< + * \brief Create a new heap. The heap is implemented using a space-efficient + * storage method. When the heap elements are deleted space is not freed + * but will be reused when new elements are inserted. + * + * Requires: + *\li "mctx" is valid. + *\li "compare" is a function which takes two void * arguments and + * returns ISC_TRUE if the first argument has a higher priority than + * the second, and ISC_FALSE otherwise. + *\li "index" is a function which takes a void *, and an unsigned int + * argument. This function will be called whenever an element's + * index value changes, so it may continue to delete itself from the + * heap. This option may be NULL if this functionality is unneeded. + *\li "size_increment" is a hint about how large the heap should grow + * when resizing is needed. If this is 0, a default size will be + * used, which is currently 1024, allowing space for an additional 1024 + * heap elements to be inserted before adding more space. + *\li "heapp" is not NULL, and "*heap" is NULL. + * + * Returns: + *\li ISC_R_SUCCESS - success + *\li ISC_R_NOMEMORY - insufficient memory + */ + +void +isc_heap_destroy(isc_heap_t **heapp); +/*!< + * \brief Destroys a heap. + * + * Requires: + *\li "heapp" is not NULL and "*heap" points to a valid isc_heap_t. + */ + +isc_result_t +isc_heap_insert(isc_heap_t *heap, void *elt); +/*!< + * \brief Inserts a new element into a heap. + * + * Requires: + *\li "heapp" is not NULL and "*heap" points to a valid isc_heap_t. + */ + +void +isc_heap_delete(isc_heap_t *heap, unsigned int index); +/*!< + * \brief Deletes an element from a heap, by element index. + * + * Requires: + *\li "heapp" is not NULL and "*heap" points to a valid isc_heap_t. + *\li "index" is a valid element index, as provided by the "index" callback + * provided during heap creation. + */ + +void +isc_heap_increased(isc_heap_t *heap, unsigned int index); +/*!< + * \brief Indicates to the heap that an element's priority has increased. + * This function MUST be called whenever an element has increased in priority. + * + * Requires: + *\li "heapp" is not NULL and "*heap" points to a valid isc_heap_t. + *\li "index" is a valid element index, as provided by the "index" callback + * provided during heap creation. + */ + +void +isc_heap_decreased(isc_heap_t *heap, unsigned int index); +/*!< + * \brief Indicates to the heap that an element's priority has decreased. + * This function MUST be called whenever an element has decreased in priority. + * + * Requires: + *\li "heapp" is not NULL and "*heap" points to a valid isc_heap_t. + *\li "index" is a valid element index, as provided by the "index" callback + * provided during heap creation. + */ + +void * +isc_heap_element(isc_heap_t *heap, unsigned int index); +/*!< + * \brief Returns the element for a specific element index. + * + * Requires: + *\li "heapp" is not NULL and "*heap" points to a valid isc_heap_t. + *\li "index" is a valid element index, as provided by the "index" callback + * provided during heap creation. + * + * Returns: + *\li A pointer to the element for the element index. + */ + +void +isc_heap_foreach(isc_heap_t *heap, isc_heapaction_t action, void *uap); +/*!< + * \brief Iterate over the heap, calling an action for each element. The + * order of iteration is not sorted. + * + * Requires: + *\li "heapp" is not NULL and "*heap" points to a valid isc_heap_t. + *\li "action" is not NULL, and is a function which takes two arguments. + * The first is a void *, representing the element, and the second is + * "uap" as provided to isc_heap_foreach. + *\li "uap" is a caller-provided argument, and may be NULL. + * + * Note: + *\li The heap structure CANNOT be modified during this iteration. The only + * safe function to call while iterating the heap is isc_heap_element(). + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_HEAP_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/hex.h src.ntp/contrib/ntp/lib/isc/include/isc/hex.h --- src/contrib/ntp/lib/isc/include/isc/hex.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/hex.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,98 @@ +/* + * Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: hex.h,v 1.13 2008/09/25 04:02:39 tbox Exp $ */ + +#ifndef ISC_HEX_H +#define ISC_HEX_H 1 + +/*! \file isc/hex.h */ + +#include +#include + +ISC_LANG_BEGINDECLS + +/*** + *** Functions + ***/ + +isc_result_t +isc_hex_totext(isc_region_t *source, int wordlength, + const char *wordbreak, isc_buffer_t *target); +/*!< + * \brief Convert data into hex encoded text. + * + * Notes: + *\li The hex encoded text in 'target' will be divided into + * words of at most 'wordlength' characters, separated by + * the 'wordbreak' string. No parentheses will surround + * the text. + * + * Requires: + *\li 'source' is a region containing binary data + *\li 'target' is a text buffer containing available space + *\li 'wordbreak' points to a null-terminated string of + * zero or more whitespace characters + * + * Ensures: + *\li target will contain the hex encoded version of the data + * in source. The 'used' pointer in target will be advanced as + * necessary. + */ + +isc_result_t +isc_hex_decodestring(const char *cstr, isc_buffer_t *target); +/*!< + * \brief Decode a null-terminated hex string. + * + * Requires: + *\li 'cstr' is non-null. + *\li 'target' is a valid buffer. + * + * Returns: + *\li #ISC_R_SUCCESS -- the entire decoded representation of 'cstring' + * fit in 'target'. + *\li #ISC_R_BADHEX -- 'cstr' is not a valid hex encoding. + * + * Other error returns are any possible error code from: + * isc_lex_create(), + * isc_lex_openbuffer(), + * isc_hex_tobuffer(). + */ + +isc_result_t +isc_hex_tobuffer(isc_lex_t *lexer, isc_buffer_t *target, int length); +/*!< + * \brief Convert hex encoded text from a lexer context into data. + * + * Requires: + *\li 'lex' is a valid lexer context + *\li 'target' is a buffer containing binary data + *\li 'length' is an integer + * + * Ensures: + *\li target will contain the data represented by the hex encoded + * string parsed by the lexer. No more than length bytes will be read, + * if length is positive. The 'used' pointer in target will be + * advanced as necessary. + */ + + +ISC_LANG_ENDDECLS + +#endif /* ISC_HEX_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/hmacmd5.h src.ntp/contrib/ntp/lib/isc/include/isc/hmacmd5.h --- src/contrib/ntp/lib/isc/include/isc/hmacmd5.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/hmacmd5.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,63 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: hmacmd5.h,v 1.12 2007/06/19 23:47:18 tbox Exp $ */ + +/*! \file isc/hmacmd5.h + * \brief This is the header file for the HMAC-MD5 keyed hash algorithm + * described in RFC2104. + */ + +#ifndef ISC_HMACMD5_H +#define ISC_HMACMD5_H 1 + +#include +#include +#include + +#define ISC_HMACMD5_KEYLENGTH 64 + +typedef struct { + isc_md5_t md5ctx; + unsigned char key[ISC_HMACMD5_KEYLENGTH]; +} isc_hmacmd5_t; + +ISC_LANG_BEGINDECLS + +void +isc_hmacmd5_init(isc_hmacmd5_t *ctx, const unsigned char *key, + unsigned int len); + +void +isc_hmacmd5_invalidate(isc_hmacmd5_t *ctx); + +void +isc_hmacmd5_update(isc_hmacmd5_t *ctx, const unsigned char *buf, + unsigned int len); + +void +isc_hmacmd5_sign(isc_hmacmd5_t *ctx, unsigned char *digest); + +isc_boolean_t +isc_hmacmd5_verify(isc_hmacmd5_t *ctx, unsigned char *digest); + +isc_boolean_t +isc_hmacmd5_verify2(isc_hmacmd5_t *ctx, unsigned char *digest, size_t len); + +ISC_LANG_ENDDECLS + +#endif /* ISC_HMACMD5_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/hmacsha.h src.ntp/contrib/ntp/lib/isc/include/isc/hmacsha.h --- src/contrib/ntp/lib/isc/include/isc/hmacsha.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/hmacsha.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,156 @@ +/* + * Copyright (C) 2005-2007 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: hmacsha.h,v 1.7 2007/06/19 23:47:18 tbox Exp $ */ + +/*! \file isc/hmacsha.h + * This is the header file for the HMAC-SHA1, HMAC-SHA224, HMAC-SHA256, + * HMAC-SHA334 and HMAC-SHA512 hash algorithm described in RFC 2104. + */ + +#ifndef ISC_HMACSHA_H +#define ISC_HMACSHA_H 1 + +#include +#include +#include +#include + +#define ISC_HMACSHA1_KEYLENGTH ISC_SHA1_BLOCK_LENGTH +#define ISC_HMACSHA224_KEYLENGTH ISC_SHA224_BLOCK_LENGTH +#define ISC_HMACSHA256_KEYLENGTH ISC_SHA256_BLOCK_LENGTH +#define ISC_HMACSHA384_KEYLENGTH ISC_SHA384_BLOCK_LENGTH +#define ISC_HMACSHA512_KEYLENGTH ISC_SHA512_BLOCK_LENGTH + +typedef struct { + isc_sha1_t sha1ctx; + unsigned char key[ISC_HMACSHA1_KEYLENGTH]; +} isc_hmacsha1_t; + +typedef struct { + isc_sha224_t sha224ctx; + unsigned char key[ISC_HMACSHA224_KEYLENGTH]; +} isc_hmacsha224_t; + +typedef struct { + isc_sha256_t sha256ctx; + unsigned char key[ISC_HMACSHA256_KEYLENGTH]; +} isc_hmacsha256_t; + +typedef struct { + isc_sha384_t sha384ctx; + unsigned char key[ISC_HMACSHA384_KEYLENGTH]; +} isc_hmacsha384_t; + +typedef struct { + isc_sha512_t sha512ctx; + unsigned char key[ISC_HMACSHA512_KEYLENGTH]; +} isc_hmacsha512_t; + +ISC_LANG_BEGINDECLS + +void +isc_hmacsha1_init(isc_hmacsha1_t *ctx, const unsigned char *key, + unsigned int len); + +void +isc_hmacsha1_invalidate(isc_hmacsha1_t *ctx); + +void +isc_hmacsha1_update(isc_hmacsha1_t *ctx, const unsigned char *buf, + unsigned int len); + +void +isc_hmacsha1_sign(isc_hmacsha1_t *ctx, unsigned char *digest, size_t len); + +isc_boolean_t +isc_hmacsha1_verify(isc_hmacsha1_t *ctx, unsigned char *digest, size_t len); + + +void +isc_hmacsha224_init(isc_hmacsha224_t *ctx, const unsigned char *key, + unsigned int len); + +void +isc_hmacsha224_invalidate(isc_hmacsha224_t *ctx); + +void +isc_hmacsha224_update(isc_hmacsha224_t *ctx, const unsigned char *buf, + unsigned int len); + +void +isc_hmacsha224_sign(isc_hmacsha224_t *ctx, unsigned char *digest, size_t len); + +isc_boolean_t +isc_hmacsha224_verify(isc_hmacsha224_t *ctx, unsigned char *digest, size_t len); + + +void +isc_hmacsha256_init(isc_hmacsha256_t *ctx, const unsigned char *key, + unsigned int len); + +void +isc_hmacsha256_invalidate(isc_hmacsha256_t *ctx); + +void +isc_hmacsha256_update(isc_hmacsha256_t *ctx, const unsigned char *buf, + unsigned int len); + +void +isc_hmacsha256_sign(isc_hmacsha256_t *ctx, unsigned char *digest, size_t len); + +isc_boolean_t +isc_hmacsha256_verify(isc_hmacsha256_t *ctx, unsigned char *digest, size_t len); + + +void +isc_hmacsha384_init(isc_hmacsha384_t *ctx, const unsigned char *key, + unsigned int len); + +void +isc_hmacsha384_invalidate(isc_hmacsha384_t *ctx); + +void +isc_hmacsha384_update(isc_hmacsha384_t *ctx, const unsigned char *buf, + unsigned int len); + +void +isc_hmacsha384_sign(isc_hmacsha384_t *ctx, unsigned char *digest, size_t len); + +isc_boolean_t +isc_hmacsha384_verify(isc_hmacsha384_t *ctx, unsigned char *digest, size_t len); + + +void +isc_hmacsha512_init(isc_hmacsha512_t *ctx, const unsigned char *key, + unsigned int len); + +void +isc_hmacsha512_invalidate(isc_hmacsha512_t *ctx); + +void +isc_hmacsha512_update(isc_hmacsha512_t *ctx, const unsigned char *buf, + unsigned int len); + +void +isc_hmacsha512_sign(isc_hmacsha512_t *ctx, unsigned char *digest, size_t len); + +isc_boolean_t +isc_hmacsha512_verify(isc_hmacsha512_t *ctx, unsigned char *digest, size_t len); + +ISC_LANG_ENDDECLS + +#endif /* ISC_HMACSHA_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/httpd.h src.ntp/contrib/ntp/lib/isc/include/isc/httpd.h --- src/contrib/ntp/lib/isc/include/isc/httpd.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/httpd.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,64 @@ +/* + * Copyright (C) 2006-2008 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: httpd.h,v 1.9 2008/08/08 05:06:49 marka Exp $ */ + +#ifndef ISC_HTTPD_H +#define ISC_HTTPD_H 1 + +/*! \file */ + +#include +#include +#include +#include +#include + +#define HTTPD_EVENTCLASS ISC_EVENTCLASS(4300) +#define HTTPD_SHUTDOWN (HTTPD_EVENTCLASS + 0x0001) + +#define ISC_HTTPDMGR_FLAGSHUTTINGDOWN 0x00000001 + +/* + * Create a new http daemon which will send, once every time period, + * a http-like header followed by HTTP data. + */ +isc_result_t +isc_httpdmgr_create(isc_mem_t *mctx, isc_socket_t *sock, isc_task_t *task, + isc_httpdclientok_t *client_ok, + isc_httpdondestroy_t *ondestory, void *cb_arg, + isc_timermgr_t *tmgr, isc_httpdmgr_t **httpdp); + +void +isc_httpdmgr_shutdown(isc_httpdmgr_t **httpdp); + +isc_result_t +isc_httpdmgr_addurl(isc_httpdmgr_t *httpdmgr, const char *url, + isc_httpdaction_t *func, void *arg); + +isc_result_t +isc_httpd_response(isc_httpd_t *httpd); + +isc_result_t +isc_httpd_addheader(isc_httpd_t *httpd, const char *name, + const char *val); + +isc_result_t +isc_httpd_addheaderuint(isc_httpd_t *httpd, const char *name, int val); + +isc_result_t isc_httpd_endheaders(isc_httpd_t *httpd); + +#endif /* ISC_HTTPD_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/interfaceiter.h src.ntp/contrib/ntp/lib/isc/include/isc/interfaceiter.h --- src/contrib/ntp/lib/isc/include/isc/interfaceiter.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/interfaceiter.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,136 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: interfaceiter.h,v 1.17 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_INTERFACEITER_H +#define ISC_INTERFACEITER_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/interfaceiter.h + * \brief Iterates over the list of network interfaces. + * + * Interfaces whose address family is not supported are ignored and never + * returned by the iterator. Interfaces whose netmask, interface flags, + * or similar cannot be obtained are also ignored, and the failure is logged. + * + * Standards: + * The API for scanning varies greatly among operating systems. + * This module attempts to hide the differences. + */ + +/*** + *** Imports + ***/ + +#include +#include +#include + +/*! + * \brief Public structure describing a network interface. + */ + +struct isc_interface { + char name[32]; /*%< Interface name, null-terminated. */ + unsigned int af; /*%< Address family. */ + isc_netaddr_t address; /*%< Local address. */ + isc_netaddr_t netmask; /*%< Network mask. */ + isc_netaddr_t broadcast; /*&< Broadcast address. */ + isc_netaddr_t dstaddress; /*%< Destination address (point-to-point only). */ + isc_uint32_t flags; /*%< Flags; see INTERFACE flags. */ +}; + +/*@{*/ +/*! Interface flags. */ + +#define INTERFACE_F_UP 0x00000001U +#define INTERFACE_F_POINTTOPOINT 0x00000002U +#define INTERFACE_F_LOOPBACK 0x00000004U +#define INTERFACE_F_BROADCAST 0x00000008U +#define INTERFACE_F_MULTICAST 0x00000010U +/*@}*/ + +/*** + *** Functions + ***/ + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_interfaceiter_create(isc_mem_t *mctx, isc_interfaceiter_t **iterp); +/*!< + * \brief Create an iterator for traversing the operating system's list + * of network interfaces. + * + * Returns: + *\li #ISC_R_SUCCESS + * \li #ISC_R_NOMEMORY + *\li Various network-related errors + */ + +isc_result_t +isc_interfaceiter_first(isc_interfaceiter_t *iter); +/*!< + * \brief Position the iterator on the first interface. + * + * Returns: + *\li #ISC_R_SUCCESS Success. + *\li #ISC_R_NOMORE There are no interfaces. + */ + +isc_result_t +isc_interfaceiter_current(isc_interfaceiter_t *iter, + isc_interface_t *ifdata); +/*!< + * \brief Get information about the interface the iterator is currently + * positioned at and store it at *ifdata. + * + * Requires: + *\li The iterator has been successfully positioned using + * isc_interface_iter_first() / isc_interface_iter_next(). + * + * Returns: + *\li #ISC_R_SUCCESS Success. + */ + +isc_result_t +isc_interfaceiter_next(isc_interfaceiter_t *iter); +/*!< + * \brief Position the iterator on the next interface. + * + * Requires: + * \li The iterator has been successfully positioned using + * isc_interface_iter_first() / isc_interface_iter_next(). + * + * Returns: + *\li #ISC_R_SUCCESS Success. + *\li #ISC_R_NOMORE There are no more interfaces. + */ + +void +isc_interfaceiter_destroy(isc_interfaceiter_t **iterp); +/*!< + * \brief Destroy the iterator. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_INTERFACEITER_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/ipv6.h src.ntp/contrib/ntp/lib/isc/include/isc/ipv6.h --- src/contrib/ntp/lib/isc/include/isc/ipv6.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/ipv6.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,148 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: ipv6.h,v 1.24 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_IPV6_H +#define ISC_IPV6_H 1 + +/*! + * Also define LWRES_IPV6_H to keep it from being included if liblwres is + * being used, or redefinition errors will occur. + */ +#define LWRES_IPV6_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/ipv6.h + * \brief IPv6 definitions for systems which do not support IPv6. + * + * \li MP: + * No impact. + * + * \li Reliability: + * No anticipated impact. + * + * \li Resources: + * N/A. + * + * \li Security: + * No anticipated impact. + * + * \li Standards: + * RFC2553. + */ + +/*** + *** Imports. + ***/ + +#include +#include + +/*** + *** Types. + ***/ + +struct in6_addr { + union { + isc_uint8_t _S6_u8[16]; + isc_uint16_t _S6_u16[8]; + isc_uint32_t _S6_u32[4]; + } _S6_un; +}; +#define s6_addr _S6_un._S6_u8 +#define s6_addr8 _S6_un._S6_u8 +#define s6_addr16 _S6_un._S6_u16 +#define s6_addr32 _S6_un._S6_u32 + +#define IN6ADDR_ANY_INIT {{{ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 }}} +#define IN6ADDR_LOOPBACK_INIT {{{ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }}} + +LIBISC_EXTERNAL_DATA extern const struct in6_addr in6addr_any; +LIBISC_EXTERNAL_DATA extern const struct in6_addr in6addr_loopback; + +struct sockaddr_in6 { +#ifdef ISC_PLATFORM_HAVESALEN + isc_uint8_t sin6_len; + isc_uint8_t sin6_family; +#else + isc_uint16_t sin6_family; +#endif + isc_uint16_t sin6_port; + isc_uint32_t sin6_flowinfo; + struct in6_addr sin6_addr; + isc_uint32_t sin6_scope_id; +}; + +#ifdef ISC_PLATFORM_HAVESALEN +#define SIN6_LEN 1 +#endif + +/*% + * Unspecified + */ +#define IN6_IS_ADDR_UNSPECIFIED(a) \ + (((a)->s6_addr32[0] == 0) && \ + ((a)->s6_addr32[1] == 0) && \ + ((a)->s6_addr32[2] == 0) && \ + ((a)->s6_addr32[3] == 0)) + +/*% + * Loopback + */ +#define IN6_IS_ADDR_LOOPBACK(a) \ + (((a)->s6_addr32[0] == 0) && \ + ((a)->s6_addr32[1] == 0) && \ + ((a)->s6_addr32[2] == 0) && \ + ((a)->s6_addr32[3] == htonl(1))) + +/*% + * IPv4 compatible + */ +#define IN6_IS_ADDR_V4COMPAT(a) \ + (((a)->s6_addr32[0] == 0) && \ + ((a)->s6_addr32[1] == 0) && \ + ((a)->s6_addr32[2] == 0) && \ + ((a)->s6_addr32[3] != 0) && \ + ((a)->s6_addr32[3] != htonl(1))) + +/*% + * Mapped + */ +#define IN6_IS_ADDR_V4MAPPED(a) \ + (((a)->s6_addr32[0] == 0) && \ + ((a)->s6_addr32[1] == 0) && \ + ((a)->s6_addr32[2] == htonl(0x0000ffff))) + +/*% + * Multicast + */ +#define IN6_IS_ADDR_MULTICAST(a) \ + ((a)->s6_addr8[0] == 0xffU) + +/*% + * Unicast link / site local. + */ +#define IN6_IS_ADDR_LINKLOCAL(a) \ + (((a)->s6_addr[0] == 0xfe) && (((a)->s6_addr[1] & 0xc0) == 0x80)) +#define IN6_IS_ADDR_SITELOCAL(a) \ + (((a)->s6_addr[0] == 0xfe) && (((a)->s6_addr[1] & 0xc0) == 0xc0)) + +#endif /* ISC_IPV6_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/iterated_hash.h src.ntp/contrib/ntp/lib/isc/include/isc/iterated_hash.h --- src/contrib/ntp/lib/isc/include/isc/iterated_hash.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/iterated_hash.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,47 @@ +/* + * Copyright (C) 2008 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: iterated_hash.h,v 1.3 2008/09/25 04:02:39 tbox Exp $ */ + +#ifndef ISC_ITERATED_HASH_H +#define ISC_ITERATED_HASH_H 1 + +#include +#include + +/* + * The maximal hash length that can be encoded it a name + * using base32hex. floor(255/8)*5 + */ +#define NSEC3_MAX_HASH_LENGTH 155 + +/* + * The maximum has that can be encoded in a single label using + * base32hex. floor(63/8)*5 + */ +#define NSEC3_MAX_LABEL_HASH 35 + +ISC_LANG_BEGINDECLS + +int isc_iterated_hash(unsigned char out[NSEC3_MAX_HASH_LENGTH], + unsigned int hashalg, int iterations, + const unsigned char *salt, int saltlength, + const unsigned char *in, int inlength); + + +ISC_LANG_ENDDECLS + +#endif /* ISC_ITERATED_HASH_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/lang.h src.ntp/contrib/ntp/lib/isc/include/isc/lang.h --- src/contrib/ntp/lib/isc/include/isc/lang.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/lang.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: lang.h,v 1.13 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_LANG_H +#define ISC_LANG_H 1 + +/*! \file isc/lang.h */ + +#ifdef __cplusplus +#define ISC_LANG_BEGINDECLS extern "C" { +#define ISC_LANG_ENDDECLS } +#else +#define ISC_LANG_BEGINDECLS +#define ISC_LANG_ENDDECLS +#endif + +#endif /* ISC_LANG_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/lex.h src.ntp/contrib/ntp/lib/isc/include/isc/lex.h --- src/contrib/ntp/lib/isc/include/isc/lex.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/lex.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,431 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: lex.h,v 1.37 2008/05/30 23:47:01 tbox Exp $ */ + +#ifndef ISC_LEX_H +#define ISC_LEX_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/lex.h + * \brief The "lex" module provides a lightweight tokenizer. It can operate + * on files or buffers, and can handle "include". It is designed for + * parsing of DNS master files and the BIND configuration file, but + * should be general enough to tokenize other things, e.g. HTTP. + * + * \li MP: + * No synchronization is provided. Clients must ensure exclusive + * access. + * + * \li Reliability: + * No anticipated impact. + * + * \li Resources: + * TBS + * + * \li Security: + * No anticipated impact. + * + * \li Standards: + * None. + */ + +/*** + *** Imports + ***/ + +#include + +#include +#include +#include + +ISC_LANG_BEGINDECLS + +/*** + *** Options + ***/ + +/*@{*/ +/*! + * Various options for isc_lex_gettoken(). + */ + +#define ISC_LEXOPT_EOL 0x01 /*%< Want end-of-line token. */ +#define ISC_LEXOPT_EOF 0x02 /*%< Want end-of-file token. */ +#define ISC_LEXOPT_INITIALWS 0x04 /*%< Want initial whitespace. */ +#define ISC_LEXOPT_NUMBER 0x08 /*%< Recognize numbers. */ +#define ISC_LEXOPT_QSTRING 0x10 /*%< Recognize qstrings. */ +/*@}*/ + +/*@{*/ +/*! + * The ISC_LEXOPT_DNSMULTILINE option handles the processing of '(' and ')' in + * the DNS master file format. If this option is set, then the + * ISC_LEXOPT_INITIALWS and ISC_LEXOPT_EOL options will be ignored when + * the paren count is > 0. To use this option, '(' and ')' must be special + * characters. + */ +#define ISC_LEXOPT_DNSMULTILINE 0x20 /*%< Handle '(' and ')'. */ +#define ISC_LEXOPT_NOMORE 0x40 /*%< Want "no more" token. */ + +#define ISC_LEXOPT_CNUMBER 0x80 /*%< Recognize octal and hex. */ +#define ISC_LEXOPT_ESCAPE 0x100 /*%< Recognize escapes. */ +#define ISC_LEXOPT_QSTRINGMULTILINE 0x200 /*%< Allow multiline "" strings */ +#define ISC_LEXOPT_OCTAL 0x400 /*%< Expect a octal number. */ +/*@}*/ +/*@{*/ +/*! + * Various commenting styles, which may be changed at any time with + * isc_lex_setcomments(). + */ + +#define ISC_LEXCOMMENT_C 0x01 +#define ISC_LEXCOMMENT_CPLUSPLUS 0x02 +#define ISC_LEXCOMMENT_SHELL 0x04 +#define ISC_LEXCOMMENT_DNSMASTERFILE 0x08 +/*@}*/ + +/*** + *** Types + ***/ + +/*! Lex */ + +typedef char isc_lexspecials_t[256]; + +/* Tokens */ + +typedef enum { + isc_tokentype_unknown = 0, + isc_tokentype_string = 1, + isc_tokentype_number = 2, + isc_tokentype_qstring = 3, + isc_tokentype_eol = 4, + isc_tokentype_eof = 5, + isc_tokentype_initialws = 6, + isc_tokentype_special = 7, + isc_tokentype_nomore = 8 +} isc_tokentype_t; + +typedef union { + char as_char; + unsigned long as_ulong; + isc_region_t as_region; + isc_textregion_t as_textregion; + void * as_pointer; +} isc_tokenvalue_t; + +typedef struct isc_token { + isc_tokentype_t type; + isc_tokenvalue_t value; +} isc_token_t; + +/*** + *** Functions + ***/ + +isc_result_t +isc_lex_create(isc_mem_t *mctx, size_t max_token, isc_lex_t **lexp); +/*%< + * Create a lexer. + * + * 'max_token' is a hint of the number of bytes in the largest token. + * + * Requires: + *\li '*lexp' is a valid lexer. + * + *\li max_token > 0. + * + * Ensures: + *\li On success, *lexp is attached to the newly created lexer. + * + * Returns: + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY + */ + +void +isc_lex_destroy(isc_lex_t **lexp); +/*%< + * Destroy the lexer. + * + * Requires: + *\li '*lexp' is a valid lexer. + * + * Ensures: + *\li *lexp == NULL + */ + +unsigned int +isc_lex_getcomments(isc_lex_t *lex); +/*%< + * Return the current lexer commenting styles. + * + * Requires: + *\li 'lex' is a valid lexer. + * + * Returns: + *\li The commenting sytles which are currently allowed. + */ + +void +isc_lex_setcomments(isc_lex_t *lex, unsigned int comments); +/*%< + * Set allowed lexer commenting styles. + * + * Requires: + *\li 'lex' is a valid lexer. + * + *\li 'comments' has meaningful values. + */ + +void +isc_lex_getspecials(isc_lex_t *lex, isc_lexspecials_t specials); +/*%< + * Put the current list of specials into 'specials'. + * + * Requires: + *\li 'lex' is a valid lexer. + */ + +void +isc_lex_setspecials(isc_lex_t *lex, isc_lexspecials_t specials); +/*!< + * The characters in 'specials' are returned as tokens. Along with + * whitespace, they delimit strings and numbers. + * + * Note: + *\li Comment processing takes precedence over special character + * recognition. + * + * Requires: + *\li 'lex' is a valid lexer. + */ + +isc_result_t +isc_lex_openfile(isc_lex_t *lex, const char *filename); +/*%< + * Open 'filename' and make it the current input source for 'lex'. + * + * Requires: + *\li 'lex' is a valid lexer. + * + *\li filename is a valid C string. + * + * Returns: + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY Out of memory + *\li #ISC_R_NOTFOUND File not found + *\li #ISC_R_NOPERM No permission to open file + *\li #ISC_R_FAILURE Couldn't open file, not sure why + *\li #ISC_R_UNEXPECTED + */ + +isc_result_t +isc_lex_openstream(isc_lex_t *lex, FILE *stream); +/*%< + * Make 'stream' the current input source for 'lex'. + * + * Requires: + *\li 'lex' is a valid lexer. + * + *\li 'stream' is a valid C stream. + * + * Returns: + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY Out of memory + */ + +isc_result_t +isc_lex_openbuffer(isc_lex_t *lex, isc_buffer_t *buffer); +/*%< + * Make 'buffer' the current input source for 'lex'. + * + * Requires: + *\li 'lex' is a valid lexer. + * + *\li 'buffer' is a valid buffer. + * + * Returns: + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY Out of memory + */ + +isc_result_t +isc_lex_close(isc_lex_t *lex); +/*%< + * Close the most recently opened object (i.e. file or buffer). + * + * Returns: + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMORE No more input sources + */ + +isc_result_t +isc_lex_gettoken(isc_lex_t *lex, unsigned int options, isc_token_t *tokenp); +/*%< + * Get the next token. + * + * Requires: + *\li 'lex' is a valid lexer. + * + *\li 'lex' has an input source. + * + *\li 'options' contains valid options. + * + *\li '*tokenp' is a valid pointer. + * + * Returns: + *\li #ISC_R_SUCCESS + *\li #ISC_R_UNEXPECTEDEND + *\li #ISC_R_NOMEMORY + * + * These two results are returned only if their corresponding lexer + * options are not set. + * + *\li #ISC_R_EOF End of input source + *\li #ISC_R_NOMORE No more input sources + */ + +isc_result_t +isc_lex_getmastertoken(isc_lex_t *lex, isc_token_t *token, + isc_tokentype_t expect, isc_boolean_t eol); +/*%< + * Get the next token from a DNS master file type stream. This is a + * convenience function that sets appropriate options and handles quoted + * strings and end of line correctly for master files. It also ungets + * unexpected tokens. + * + * Requires: + *\li 'lex' is a valid lexer. + * + *\li 'token' is a valid pointer + * + * Returns: + * + * \li any return code from isc_lex_gettoken(). + */ + +isc_result_t +isc_lex_getoctaltoken(isc_lex_t *lex, isc_token_t *token, isc_boolean_t eol); +/*%< + * Get the next token from a DNS master file type stream. This is a + * convenience function that sets appropriate options and handles end + * of line correctly for master files. It also ungets unexpected tokens. + * + * Requires: + *\li 'lex' is a valid lexer. + * + *\li 'token' is a valid pointer + * + * Returns: + * + * \li any return code from isc_lex_gettoken(). + */ + +void +isc_lex_ungettoken(isc_lex_t *lex, isc_token_t *tokenp); +/*%< + * Unget the current token. + * + * Requires: + *\li 'lex' is a valid lexer. + * + *\li 'lex' has an input source. + * + *\li 'tokenp' points to a valid token. + * + *\li There is no ungotten token already. + */ + +void +isc_lex_getlasttokentext(isc_lex_t *lex, isc_token_t *tokenp, isc_region_t *r); +/*%< + * Returns a region containing the text of the last token returned. + * + * Requires: + *\li 'lex' is a valid lexer. + * + *\li 'lex' has an input source. + * + *\li 'tokenp' points to a valid token. + * + *\li A token has been gotten and not ungotten. + */ + +char * +isc_lex_getsourcename(isc_lex_t *lex); +/*%< + * Return the input source name. + * + * Requires: + *\li 'lex' is a valid lexer. + * + * Returns: + * \li source name or NULL if no current source. + *\li result valid while current input source exists. + */ + + +unsigned long +isc_lex_getsourceline(isc_lex_t *lex); +/*%< + * Return the input source line number. + * + * Requires: + *\li 'lex' is a valid lexer. + * + * Returns: + *\li Current line number or 0 if no current source. + */ + +isc_result_t +isc_lex_setsourcename(isc_lex_t *lex, const char *name); +/*%< + * Assigns a new name to the input source. + * + * Requires: + * + * \li 'lex' is a valid lexer. + * + * Returns: + * \li #ISC_R_SUCCESS + * \li #ISC_R_NOMEMORY + * \li #ISC_R_NOTFOUND - there are no sources. + */ + +isc_boolean_t +isc_lex_isfile(isc_lex_t *lex); +/*%< + * Return whether the current input source is a file. + * + * Requires: + *\li 'lex' is a valid lexer. + * + * Returns: + * \li #ISC_TRUE if the current input is a file, + *\li #ISC_FALSE otherwise. + */ + + +ISC_LANG_ENDDECLS + +#endif /* ISC_LEX_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/lfsr.h src.ntp/contrib/ntp/lib/isc/include/isc/lfsr.h --- src/contrib/ntp/lib/isc/include/isc/lfsr.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/lfsr.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,130 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: lfsr.h,v 1.17 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_LFSR_H +#define ISC_LFSR_H 1 + +/*! \file isc/lfsr.h */ + +#include +#include + +typedef struct isc_lfsr isc_lfsr_t; + +/*% + * This function is called when reseeding is needed. It is allowed to + * modify any state in the LFSR in any way it sees fit OTHER THAN "bits". + * + * It MUST set "count" to a new value or the lfsr will never reseed again. + * + * Also, a reseed will never occur in the middle of an extraction. This + * is purely an optimization, and is probably what one would want. + */ +typedef void (*isc_lfsrreseed_t)(isc_lfsr_t *, void *); + +/*% + * The members of this structure can be used by the application, but care + * needs to be taken to not change state once the lfsr is in operation. + */ +struct isc_lfsr { + isc_uint32_t state; /*%< previous state */ + unsigned int bits; /*%< length */ + isc_uint32_t tap; /*%< bit taps */ + unsigned int count; /*%< reseed count (in BITS!) */ + isc_lfsrreseed_t reseed; /*%< reseed function */ + void *arg; /*%< reseed function argument */ +}; + +ISC_LANG_BEGINDECLS + + +void +isc_lfsr_init(isc_lfsr_t *lfsr, isc_uint32_t state, unsigned int bits, + isc_uint32_t tap, unsigned int count, + isc_lfsrreseed_t reseed, void *arg); +/*%< + * Initialize an LFSR. + * + * Note: + * + *\li Putting untrusted values into this function will cause the LFSR to + * generate (perhaps) non-maximal length sequences. + * + * Requires: + * + *\li lfsr != NULL + * + *\li 8 <= bits <= 32 + * + *\li tap != 0 + */ + +void +isc_lfsr_generate(isc_lfsr_t *lfsr, void *data, unsigned int count); +/*%< + * Returns "count" bytes of data from the LFSR. + * + * Requires: + * + *\li lfsr be valid. + * + *\li data != NULL. + * + *\li count > 0. + */ + +void +isc_lfsr_skip(isc_lfsr_t *lfsr, unsigned int skip); +/*%< + * Skip "skip" states. + * + * Requires: + * + *\li lfsr be valid. + */ + +isc_uint32_t +isc_lfsr_generate32(isc_lfsr_t *lfsr1, isc_lfsr_t *lfsr2); +/*%< + * Given two LFSRs, use the current state from each to skip entries in the + * other. The next states are then xor'd together and returned. + * + * WARNING: + * + *\li This function is used only for very, very low security data, such + * as DNS message IDs where it is desired to have an unpredictable + * stream of bytes that are harder to predict than a simple flooding + * attack. + * + * Notes: + * + *\li Since the current state from each of the LFSRs is used to skip + * state in the other, it is important that no state be leaked + * from either LFSR. + * + * Requires: + * + *\li lfsr1 and lfsr2 be valid. + * + *\li 1 <= skipbits <= 31 + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_LFSR_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/lib.h src.ntp/contrib/ntp/lib/isc/include/isc/lib.h --- src/contrib/ntp/lib/isc/include/isc/lib.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/lib.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,41 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: lib.h,v 1.14 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_LIB_H +#define ISC_LIB_H 1 + +/*! \file isc/lib.h */ + +#include +#include + +ISC_LANG_BEGINDECLS + +LIBISC_EXTERNAL_DATA extern isc_msgcat_t *isc_msgcat; + +void +isc_lib_initmsgcat(void); +/*!< + * \brief Initialize the ISC library's message catalog, isc_msgcat, if it + * has not already been initialized. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_LIB_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/list.h src.ntp/contrib/ntp/lib/isc/include/isc/list.h --- src/contrib/ntp/lib/isc/include/isc/list.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/list.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,184 @@ +/* + * Copyright (C) 2004, 2006, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1997-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: list.h,v 1.24 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_LIST_H +#define ISC_LIST_H 1 +#include +#include + +#ifdef ISC_LIST_CHECKINIT +#define ISC_LINK_INSIST(x) ISC_INSIST(x) +#else +#define ISC_LINK_INSIST(x) +#endif + +#define ISC_LIST(type) struct { type *head, *tail; } +#define ISC_LIST_INIT(list) \ + do { (list).head = NULL; (list).tail = NULL; } while (0) + +#define ISC_LINK(type) struct { type *prev, *next; } +#define ISC_LINK_INIT_TYPE(elt, link, type) \ + do { \ + (elt)->link.prev = (type *)(-1); \ + (elt)->link.next = (type *)(-1); \ + } while (0) +#define ISC_LINK_INIT(elt, link) \ + ISC_LINK_INIT_TYPE(elt, link, void) +#define ISC_LINK_LINKED(elt, link) ((void *)((elt)->link.prev) != (void *)(-1)) + +#define ISC_LIST_HEAD(list) ((list).head) +#define ISC_LIST_TAIL(list) ((list).tail) +#define ISC_LIST_EMPTY(list) ISC_TF((list).head == NULL) + +#define __ISC_LIST_PREPENDUNSAFE(list, elt, link) \ + do { \ + if ((list).head != NULL) \ + (list).head->link.prev = (elt); \ + else \ + (list).tail = (elt); \ + (elt)->link.prev = NULL; \ + (elt)->link.next = (list).head; \ + (list).head = (elt); \ + } while (0) + +#define ISC_LIST_PREPEND(list, elt, link) \ + do { \ + ISC_LINK_INSIST(!ISC_LINK_LINKED(elt, link)); \ + __ISC_LIST_PREPENDUNSAFE(list, elt, link); \ + } while (0) + +#define ISC_LIST_INITANDPREPEND(list, elt, link) \ + __ISC_LIST_PREPENDUNSAFE(list, elt, link) + +#define __ISC_LIST_APPENDUNSAFE(list, elt, link) \ + do { \ + if ((list).tail != NULL) \ + (list).tail->link.next = (elt); \ + else \ + (list).head = (elt); \ + (elt)->link.prev = (list).tail; \ + (elt)->link.next = NULL; \ + (list).tail = (elt); \ + } while (0) + +#define ISC_LIST_APPEND(list, elt, link) \ + do { \ + ISC_LINK_INSIST(!ISC_LINK_LINKED(elt, link)); \ + __ISC_LIST_APPENDUNSAFE(list, elt, link); \ + } while (0) + +#define ISC_LIST_INITANDAPPEND(list, elt, link) \ + __ISC_LIST_APPENDUNSAFE(list, elt, link) + +#define __ISC_LIST_UNLINKUNSAFE_TYPE(list, elt, link, type) \ + do { \ + if ((elt)->link.next != NULL) \ + (elt)->link.next->link.prev = (elt)->link.prev; \ + else { \ + ISC_INSIST((list).tail == (elt)); \ + (list).tail = (elt)->link.prev; \ + } \ + if ((elt)->link.prev != NULL) \ + (elt)->link.prev->link.next = (elt)->link.next; \ + else { \ + ISC_INSIST((list).head == (elt)); \ + (list).head = (elt)->link.next; \ + } \ + (elt)->link.prev = (type *)(-1); \ + (elt)->link.next = (type *)(-1); \ + } while (0) + +#define __ISC_LIST_UNLINKUNSAFE(list, elt, link) \ + __ISC_LIST_UNLINKUNSAFE_TYPE(list, elt, link, void) + +#define ISC_LIST_UNLINK_TYPE(list, elt, link, type) \ + do { \ + ISC_LINK_INSIST(ISC_LINK_LINKED(elt, link)); \ + __ISC_LIST_UNLINKUNSAFE_TYPE(list, elt, link, type); \ + } while (0) +#define ISC_LIST_UNLINK(list, elt, link) \ + ISC_LIST_UNLINK_TYPE(list, elt, link, void) + +#define ISC_LIST_PREV(elt, link) ((elt)->link.prev) +#define ISC_LIST_NEXT(elt, link) ((elt)->link.next) + +#define __ISC_LIST_INSERTBEFOREUNSAFE(list, before, elt, link) \ + do { \ + if ((before)->link.prev == NULL) \ + ISC_LIST_PREPEND(list, elt, link); \ + else { \ + (elt)->link.prev = (before)->link.prev; \ + (before)->link.prev = (elt); \ + (elt)->link.prev->link.next = (elt); \ + (elt)->link.next = (before); \ + } \ + } while (0) + +#define ISC_LIST_INSERTBEFORE(list, before, elt, link) \ + do { \ + ISC_LINK_INSIST(ISC_LINK_LINKED(before, link)); \ + ISC_LINK_INSIST(!ISC_LINK_LINKED(elt, link)); \ + __ISC_LIST_INSERTBEFOREUNSAFE(list, before, elt, link); \ + } while (0) + +#define __ISC_LIST_INSERTAFTERUNSAFE(list, after, elt, link) \ + do { \ + if ((after)->link.next == NULL) \ + ISC_LIST_APPEND(list, elt, link); \ + else { \ + (elt)->link.next = (after)->link.next; \ + (after)->link.next = (elt); \ + (elt)->link.next->link.prev = (elt); \ + (elt)->link.prev = (after); \ + } \ + } while (0) + +#define ISC_LIST_INSERTAFTER(list, after, elt, link) \ + do { \ + ISC_LINK_INSIST(ISC_LINK_LINKED(after, link)); \ + ISC_LINK_INSIST(!ISC_LINK_LINKED(elt, link)); \ + __ISC_LIST_INSERTAFTERUNSAFE(list, after, elt, link); \ + } while (0) + +#define ISC_LIST_APPENDLIST(list1, list2, link) \ + do { \ + if (ISC_LIST_EMPTY(list1)) \ + (list1) = (list2); \ + else if (!ISC_LIST_EMPTY(list2)) { \ + (list1).tail->link.next = (list2).head; \ + (list2).head->link.prev = (list1).tail; \ + (list1).tail = (list2).tail; \ + } \ + (list2).head = NULL; \ + (list2).tail = NULL; \ + } while (0) + +#define ISC_LIST_ENQUEUE(list, elt, link) ISC_LIST_APPEND(list, elt, link) +#define __ISC_LIST_ENQUEUEUNSAFE(list, elt, link) \ + __ISC_LIST_APPENDUNSAFE(list, elt, link) +#define ISC_LIST_DEQUEUE(list, elt, link) \ + ISC_LIST_UNLINK_TYPE(list, elt, link, void) +#define ISC_LIST_DEQUEUE_TYPE(list, elt, link, type) \ + ISC_LIST_UNLINK_TYPE(list, elt, link, type) +#define __ISC_LIST_DEQUEUEUNSAFE(list, elt, link) \ + __ISC_LIST_UNLINKUNSAFE_TYPE(list, elt, link, void) +#define __ISC_LIST_DEQUEUEUNSAFE_TYPE(list, elt, link, type) \ + __ISC_LIST_UNLINKUNSAFE_TYPE(list, elt, link, type) + +#endif /* ISC_LIST_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/log.h src.ntp/contrib/ntp/lib/isc/include/isc/log.h --- src/contrib/ntp/lib/isc/include/isc/log.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/log.h 2009-12-09 08:36:44.000000000 +0100 @@ -0,0 +1,914 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: log.h,v 1.54.332.5 2009/02/16 02:04:05 marka Exp $ */ + +#ifndef ISC_LOG_H +#define ISC_LOG_H 1 + +/*! \file isc/log.h */ + +#include +#include +#include /* XXXDCL NT */ + +#include +#include +#include +#include + +/*@{*/ +/*! + * \brief Severity levels, patterned after Unix's syslog levels. + * + */ +#define ISC_LOG_DEBUG(level) (level) +/*! + * #ISC_LOG_DYNAMIC can only be used for defining channels with + * isc_log_createchannel(), not to specify a level in isc_log_write(). + */ +#define ISC_LOG_DYNAMIC 0 +#define ISC_LOG_INFO (-1) +#define ISC_LOG_NOTICE (-2) +#define ISC_LOG_WARNING (-3) +#define ISC_LOG_ERROR (-4) +#define ISC_LOG_CRITICAL (-5) +/*@}*/ + +/*@{*/ +/*! + * \brief Destinations. + */ +#define ISC_LOG_TONULL 1 +#define ISC_LOG_TOSYSLOG 2 +#define ISC_LOG_TOFILE 3 +#define ISC_LOG_TOFILEDESC 4 +/*@}*/ + +/*@{*/ +/*% + * Channel flags. + */ +#define ISC_LOG_PRINTTIME 0x0001 +#define ISC_LOG_PRINTLEVEL 0x0002 +#define ISC_LOG_PRINTCATEGORY 0x0004 +#define ISC_LOG_PRINTMODULE 0x0008 +#define ISC_LOG_PRINTTAG 0x0010 +#define ISC_LOG_PRINTALL 0x001F +#define ISC_LOG_DEBUGONLY 0x1000 +#define ISC_LOG_OPENERR 0x8000 /* internal */ +/*@}*/ + +/*@{*/ +/*! + * \brief Other options. + * + * XXXDCL INFINITE doesn't yet work. Arguably it isn't needed, but + * since I am intend to make large number of versions work efficiently, + * INFINITE is going to be trivial to add to that. + */ +#define ISC_LOG_ROLLINFINITE (-1) +#define ISC_LOG_ROLLNEVER (-2) +/*@}*/ + +/*! + * \brief Used to name the categories used by a library. + * + * An array of isc_logcategory + * structures names each category, and the id value is initialized by calling + * isc_log_registercategories. + */ +struct isc_logcategory { + const char *name; + unsigned int id; +}; + +/*% + * Similar to isc_logcategory, but for all the modules a library defines. + */ +struct isc_logmodule { + const char *name; + unsigned int id; +}; + +/*% + * The isc_logfile structure is initialized as part of an isc_logdestination + * before calling isc_log_createchannel(). + * + * When defining an #ISC_LOG_TOFILE + * channel the name, versions and maximum_size should be set before calling + * isc_log_createchannel(). To define an #ISC_LOG_TOFILEDESC channel set only + * the stream before the call. + * + * Setting maximum_size to zero implies no maximum. + */ +typedef struct isc_logfile { + FILE *stream; /*%< Initialized to NULL for #ISC_LOG_TOFILE. */ + const char *name; /*%< NULL for #ISC_LOG_TOFILEDESC. */ + int versions; /* >= 0, #ISC_LOG_ROLLNEVER, #ISC_LOG_ROLLINFINITE. */ + /*% + * stdio's ftell is standardized to return a long, which may well not + * be big enough for the largest file supportable by the operating + * system (though it is _probably_ big enough for the largest log + * anyone would want). st_size returned by fstat should be typedef'd + * to a size large enough for the largest possible file on a system. + */ + isc_offset_t maximum_size; + isc_boolean_t maximum_reached; /*%< Private. */ +} isc_logfile_t; + +/*% + * Passed to isc_log_createchannel to define the attributes of either + * a stdio or a syslog log. + */ +typedef union isc_logdestination { + isc_logfile_t file; + int facility; /* XXXDCL NT */ +} isc_logdestination_t; + +/*@{*/ +/*% + * The built-in categories of libisc. + * + * Each library registering categories should provide library_LOGCATEGORY_name + * definitions with indexes into its isc_logcategory structure corresponding to + * the order of the names. + */ +LIBISC_EXTERNAL_DATA extern isc_logcategory_t isc_categories[]; +LIBISC_EXTERNAL_DATA extern isc_log_t *isc_lctx; +LIBISC_EXTERNAL_DATA extern isc_logmodule_t isc_modules[]; +/*@}*/ + +/*@{*/ +/*% + * Do not log directly to DEFAULT. Use another category. When in doubt, + * use GENERAL. + */ +#define ISC_LOGCATEGORY_DEFAULT (&isc_categories[0]) +#define ISC_LOGCATEGORY_GENERAL (&isc_categories[1]) +/*@}*/ + +#define ISC_LOGMODULE_SOCKET (&isc_modules[0]) +#define ISC_LOGMODULE_TIME (&isc_modules[1]) +#define ISC_LOGMODULE_INTERFACE (&isc_modules[2]) +#define ISC_LOGMODULE_TIMER (&isc_modules[3]) +#define ISC_LOGMODULE_FILE (&isc_modules[4]) + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_log_create(isc_mem_t *mctx, isc_log_t **lctxp, isc_logconfig_t **lcfgp); +/*%< + * Establish a new logging context, with default channels. + * + * Notes: + *\li isc_log_create() calls isc_logconfig_create(), so see its comment + * below for more information. + * + * Requires: + *\li mctx is a valid memory context. + *\li lctxp is not null and *lctxp is null. + *\li lcfgp is null or lcfgp is not null and *lcfgp is null. + * + * Ensures: + *\li *lctxp will point to a valid logging context if all of the necessary + * memory was allocated, or NULL otherwise. + *\li *lcfgp will point to a valid logging configuration if all of the + * necessary memory was allocated, or NULL otherwise. + *\li On failure, no additional memory is allocated. + * + * Returns: + *\li #ISC_R_SUCCESS Success + *\li #ISC_R_NOMEMORY Resource limit: Out of memory + */ + +isc_result_t +isc_logconfig_create(isc_log_t *lctx, isc_logconfig_t **lcfgp); +/*%< + * Create the data structure that holds all of the configurable information + * about where messages are actually supposed to be sent -- the information + * that could changed based on some configuration file, as opposed to the + * the category/module specification of isc_log_[v]write[1] that is compiled + * into a program, or the debug_level which is dynamic state information. + * + * Notes: + *\li It is necessary to specify the logging context the configuration + * will be used with because the number of categories and modules + * needs to be known in order to set the configuration. However, + * the configuration is not used by the logging context until the + * isc_logconfig_use function is called. + * + *\li The memory context used for operations that allocate memory for + * the configuration is that of the logging context, as specified + * in the isc_log_create call. + * + *\li Four default channels are established: + *\verbatim + * default_syslog + * - log to syslog's daemon facility #ISC_LOG_INFO or higher + * default_stderr + * - log to stderr #ISC_LOG_INFO or higher + * default_debug + * - log to stderr #ISC_LOG_DEBUG dynamically + * null + * - log nothing + *\endverbatim + * + * Requires: + *\li lctx is a valid logging context. + *\li lcftp is not null and *lcfgp is null. + * + * Ensures: + *\li *lcfgp will point to a valid logging context if all of the necessary + * memory was allocated, or NULL otherwise. + *\li On failure, no additional memory is allocated. + * + * Returns: + *\li #ISC_R_SUCCESS Success + *\li #ISC_R_NOMEMORY Resource limit: Out of memory + */ + +isc_logconfig_t * +isc_logconfig_get(isc_log_t *lctx); +/*%< + * Returns a pointer to the configuration currently in use by the log context. + * + * Requires: + *\li lctx is a valid context. + * + * Ensures: + *\li The configuration pointer is non-null. + * + * Returns: + *\li The configuration pointer. + */ + +isc_result_t +isc_logconfig_use(isc_log_t *lctx, isc_logconfig_t *lcfg); +/*%< + * Associate a new configuration with a logging context. + * + * Notes: + *\li This is thread safe. The logging context will lock a mutex + * before attempting to swap in the new configuration, and isc_log_doit + * (the internal function used by all of isc_log_[v]write[1]) locks + * the same lock for the duration of its use of the configuration. + * + * Requires: + *\li lctx is a valid logging context. + *\li lcfg is a valid logging configuration. + *\li lctx is the same configuration given to isc_logconfig_create + * when the configuration was created. + * + * Ensures: + *\li Future calls to isc_log_write will use the new configuration. + * + * Returns: + *\li #ISC_R_SUCCESS Success + *\li #ISC_R_NOMEMORY Resource limit: Out of memory + */ + +void +isc_log_destroy(isc_log_t **lctxp); +/*%< + * Deallocate the memory associated with a logging context. + * + * Requires: + *\li *lctx is a valid logging context. + * + * Ensures: + *\li All of the memory associated with the logging context is returned + * to the free memory pool. + * + *\li Any open files are closed. + * + *\li The logging context is marked as invalid. + */ + +void +isc_logconfig_destroy(isc_logconfig_t **lcfgp); +/*%< + * Destroy a logging configuration. + * + * Notes: + *\li This function cannot be used directly with the return value of + * isc_logconfig_get, because a logging context must always have + * a valid configuration associated with it. + * + * Requires: + *\li lcfgp is not null and *lcfgp is a valid logging configuration. + *\li The logging configuration is not in use by an existing logging context. + * + * Ensures: + *\li All memory allocated for the configuration is freed. + * + *\li The configuration is marked as invalid. + */ + +void +isc_log_registercategories(isc_log_t *lctx, isc_logcategory_t categories[]); +/*%< + * Identify logging categories a library will use. + * + * Notes: + *\li A category should only be registered once, but no mechanism enforces + * this rule. + * + *\li The end of the categories array is identified by a NULL name. + * + *\li Because the name is used by #ISC_LOG_PRINTCATEGORY, it should not + * be altered or destroyed after isc_log_registercategories(). + * + *\li Because each element of the categories array is used by + * isc_log_categorybyname, it should not be altered or destroyed + * after registration. + * + *\li The value of the id integer in each structure is overwritten + * by this function, and so id need not be initialized to any particular + * value prior to the function call. + * + *\li A subsequent call to isc_log_registercategories with the same + * logging context (but new categories) will cause the last + * element of the categories array from the prior call to have + * its "name" member changed from NULL to point to the new + * categories array, and its "id" member set to UINT_MAX. + * + * Requires: + *\li lctx is a valid logging context. + *\li categories != NULL. + *\li categories[0].name != NULL. + * + * Ensures: + * \li There are references to each category in the logging context, + * so they can be used with isc_log_usechannel() and isc_log_write(). + */ + +void +isc_log_registermodules(isc_log_t *lctx, isc_logmodule_t modules[]); +/*%< + * Identify logging categories a library will use. + * + * Notes: + *\li A module should only be registered once, but no mechanism enforces + * this rule. + * + *\li The end of the modules array is identified by a NULL name. + * + *\li Because the name is used by #ISC_LOG_PRINTMODULE, it should not + * be altered or destroyed after isc_log_registermodules(). + * + *\li Because each element of the modules array is used by + * isc_log_modulebyname, it should not be altered or destroyed + * after registration. + * + *\li The value of the id integer in each structure is overwritten + * by this function, and so id need not be initialized to any particular + * value prior to the function call. + * + *\li A subsequent call to isc_log_registermodules with the same + * logging context (but new modules) will cause the last + * element of the modules array from the prior call to have + * its "name" member changed from NULL to point to the new + * modules array, and its "id" member set to UINT_MAX. + * + * Requires: + *\li lctx is a valid logging context. + *\li modules != NULL. + *\li modules[0].name != NULL; + * + * Ensures: + *\li Each module has a reference in the logging context, so they can be + * used with isc_log_usechannel() and isc_log_write(). + */ + +isc_result_t +isc_log_createchannel(isc_logconfig_t *lcfg, const char *name, + unsigned int type, int level, + const isc_logdestination_t *destination, + unsigned int flags); +/*%< + * Specify the parameters of a logging channel. + * + * Notes: + *\li The name argument is copied to memory in the logging context, so + * it can be altered or destroyed after isc_log_createchannel(). + * + *\li Defining a very large number of channels will have a performance + * impact on isc_log_usechannel(), since the names are searched + * linearly until a match is made. This same issue does not affect + * isc_log_write, however. + * + *\li Channel names can be redefined; this is primarily useful for programs + * that want their own definition of default_syslog, default_debug + * and default_stderr. + * + *\li Any channel that is redefined will not affect logging that was + * already directed to its original definition, _except_ for the + * default_stderr channel. This case is handled specially so that + * the default logging category can be changed by redefining + * default_stderr. (XXXDCL Though now that I think of it, the default + * logging category can be changed with only one additional function + * call by defining a new channel and then calling isc_log_usechannel() + * for #ISC_LOGCATEGORY_DEFAULT.) + * + *\li Specifying #ISC_LOG_PRINTTIME or #ISC_LOG_PRINTTAG for syslog is allowed, + * but probably not what you wanted to do. + * + * #ISC_LOG_DEBUGONLY will mark the channel as usable only when the + * debug level of the logging context (see isc_log_setdebuglevel) + * is non-zero. + * + * Requires: + *\li lcfg is a valid logging configuration. + * + *\li name is not NULL. + * + *\li type is #ISC_LOG_TOSYSLOG, #ISC_LOG_TOFILE, #ISC_LOG_TOFILEDESC or + * #ISC_LOG_TONULL. + * + *\li destination is not NULL unless type is #ISC_LOG_TONULL. + * + *\li level is >= #ISC_LOG_CRITICAL (the most negative logging level). + * + *\li flags does not include any bits aside from the ISC_LOG_PRINT* bits + * or #ISC_LOG_DEBUGONLY. + * + * Ensures: + *\li #ISC_R_SUCCESS + * A channel with the given name is usable with + * isc_log_usechannel(). + * + *\li #ISC_R_NOMEMORY or #ISC_R_UNEXPECTED + * No additional memory is being used by the logging context. + * Any channel that previously existed with the given name + * is not redefined. + * + * Returns: + *\li #ISC_R_SUCCESS Success + *\li #ISC_R_NOMEMORY Resource limit: Out of memory + *\li #ISC_R_UNEXPECTED type was out of range and REQUIRE() + * was disabled. + */ + +isc_result_t +isc_log_usechannel(isc_logconfig_t *lcfg, const char *name, + const isc_logcategory_t *category, + const isc_logmodule_t *module); +/*%< + * Associate a named logging channel with a category and module that + * will use it. + * + * Notes: + *\li The name is searched for linearly in the set of known channel names + * until a match is found. (Note the performance impact of a very large + * number of named channels.) When multiple channels of the same + * name are defined, the most recent definition is found. + * + *\li Specifying a very large number of channels for a category will have + * a moderate impact on performance in isc_log_write(), as each + * call looks up the category for the start of a linked list, which + * it follows all the way to the end to find matching modules. The + * test for matching modules is integral, though. + * + *\li If category is NULL, then the channel is associated with the indicated + * module for all known categories (including the "default" category). + * + *\li If module is NULL, then the channel is associated with every module + * that uses that category. + * + *\li Passing both category and module as NULL would make every log message + * use the indicated channel. + * + * \li Specifying a channel that is #ISC_LOG_TONULL for a category/module pair + * has no effect on any other channels associated with that pair, + * regardless of ordering. Thus you cannot use it to "mask out" one + * category/module pair when you have specified some other channel that + * is also used by that category/module pair. + * + * Requires: + *\li lcfg is a valid logging configuration. + * + *\li category is NULL or has an id that is in the range of known ids. + * + * module is NULL or has an id that is in the range of known ids. + * + * Ensures: + *\li #ISC_R_SUCCESS + * The channel will be used by the indicated category/module + * arguments. + * + *\li #ISC_R_NOMEMORY + * If assignment for a specific category has been requested, + * the channel has not been associated with the indicated + * category/module arguments and no additional memory is + * used by the logging context. + * If assignment for all categories has been requested + * then _some_ may have succeeded (starting with category + * "default" and progressing through the order of categories + * passed to isc_log_registercategories()) and additional memory + * is being used by whatever assignments succeeded. + * + * Returns: + *\li #ISC_R_SUCCESS Success + *\li #ISC_R_NOMEMORY Resource limit: Out of memory + */ + +/* Attention: next four comments PRECEED code */ +/*! + * \brief + * Write a message to the log channels. + * + * Notes: + *\li Log messages containing natural language text should be logged with + * isc_log_iwrite() to allow for localization. + * + *\li lctx can be NULL; this is allowed so that programs which use + * libraries that use the ISC logging system are not required to + * also use it. + * + *\li The format argument is a printf(3) string, with additional arguments + * as necessary. + * + * Requires: + *\li lctx is a valid logging context. + * + *\li The category and module arguments must have ids that are in the + * range of known ids, as established by isc_log_registercategories() + * and isc_log_registermodules(). + * + *\li level != #ISC_LOG_DYNAMIC. ISC_LOG_DYNAMIC is used only to define + * channels, and explicit debugging level must be identified for + * isc_log_write() via ISC_LOG_DEBUG(level). + * + *\li format != NULL. + * + * Ensures: + *\li The log message is written to every channel associated with the + * indicated category/module pair. + * + * Returns: + *\li Nothing. Failure to log a message is not construed as a + * meaningful error. + */ +void +isc_log_write(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + const char *format, ...) + +ISC_FORMAT_PRINTF(5, 6); + +/*% + * Write a message to the log channels. + * + * Notes: + *\li lctx can be NULL; this is allowed so that programs which use + * libraries that use the ISC logging system are not required to + * also use it. + * + *\li The format argument is a printf(3) string, with additional arguments + * as necessary. + * + * Requires: + *\li lctx is a valid logging context. + * + *\li The category and module arguments must have ids that are in the + * range of known ids, as established by isc_log_registercategories() + * and isc_log_registermodules(). + * + *\li level != #ISC_LOG_DYNAMIC. ISC_LOG_DYNAMIC is used only to define + * channels, and explicit debugging level must be identified for + * isc_log_write() via ISC_LOG_DEBUG(level). + * + *\li format != NULL. + * + * Ensures: + *\li The log message is written to every channel associated with the + * indicated category/module pair. + * + * Returns: + *\li Nothing. Failure to log a message is not construed as a + * meaningful error. + */ +void +isc_log_vwrite(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + const char *format, va_list args) + +ISC_FORMAT_PRINTF(5, 0); + +/*% + * Write a message to the log channels, pruning duplicates that occur within + * a configurable amount of seconds (see isc_log_[sg]etduplicateinterval). + * This function is otherwise identical to isc_log_write(). + */ +void +isc_log_write1(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, const char *format, ...) + +ISC_FORMAT_PRINTF(5, 6); + +/*% + * Write a message to the log channels, pruning duplicates that occur within + * a configurable amount of seconds (see isc_log_[sg]etduplicateinterval). + * This function is otherwise identical to isc_log_vwrite(). + */ +void +isc_log_vwrite1(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, const char *format, + va_list args) + +ISC_FORMAT_PRINTF(5, 0); + +/*% + * These are four internationalized versions of the isc_log_[v]write[1] + * functions. + * + * The only difference is that they take arguments for a message + * catalog, message set, and message number, all immediately preceding the + * format argument. The format argument becomes the default text, a la + * isc_msgcat_get. If the message catalog is NULL, no lookup is attempted + * for a message -- which makes the message set and message number irrelevant, + * and the non-internationalized call should have probably been used instead. + * + * Yes, that means there are now *eight* interfaces to logging a message. + * Sheesh. Make the madness stop! + */ +/*@{*/ +void +isc_log_iwrite(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + isc_msgcat_t *msgcat, int msgset, int message, + const char *format, ...) +ISC_FORMAT_PRINTF(8, 9); + +void +isc_log_ivwrite(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + isc_msgcat_t *msgcat, int msgset, int message, + const char *format, va_list args) +ISC_FORMAT_PRINTF(8, 0); + +void +isc_log_iwrite1(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + isc_msgcat_t *msgcat, int msgset, int message, + const char *format, ...) +ISC_FORMAT_PRINTF(8, 9); + +void +isc_log_ivwrite1(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + isc_msgcat_t *msgcat, int msgset, int message, + const char *format, va_list args) +ISC_FORMAT_PRINTF(8, 0); +/*@}*/ + +void +isc_log_setdebuglevel(isc_log_t *lctx, unsigned int level); +/*%< + * Set the debugging level used for logging. + * + * Notes: + *\li Setting the debugging level to 0 disables debugging log messages. + * + * Requires: + *\li lctx is a valid logging context. + * + * Ensures: + *\li The debugging level is set to the requested value. + */ + +unsigned int +isc_log_getdebuglevel(isc_log_t *lctx); +/*%< + * Get the current debugging level. + * + * Notes: + *\li This is provided so that a program can have a notion of + * "increment debugging level" or "decrement debugging level" + * without needing to keep track of what the current level is. + * + *\li A return value of 0 indicates that debugging messages are disabled. + * + * Requires: + *\li lctx is a valid logging context. + * + * Ensures: + *\li The current logging debugging level is returned. + */ + +isc_boolean_t +isc_log_wouldlog(isc_log_t *lctx, int level); +/*%< + * Determine whether logging something to 'lctx' at 'level' would + * actually cause something to be logged somewhere. + * + * If #ISC_FALSE is returned, it is guaranteed that nothing would + * be logged, allowing the caller to omit unnecessary + * isc_log_write() calls and possible message preformatting. + */ + +void +isc_log_setduplicateinterval(isc_logconfig_t *lcfg, unsigned int interval); +/*%< + * Set the interval over which duplicate log messages will be ignored + * by isc_log_[v]write1(), in seconds. + * + * Notes: + *\li Increasing the duplicate interval from X to Y will not necessarily + * filter out duplicates of messages logged in Y - X seconds since the + * increase. (Example: Message1 is logged at midnight. Message2 + * is logged at 00:01:00, when the interval is only 30 seconds, causing + * Message1 to be expired from the log message history. Then the interval + * is increased to 3000 (five minutes) and at 00:04:00 Message1 is logged + * again. It will appear the second time even though less than five + * passed since the first occurrence. + * + * Requires: + *\li lctx is a valid logging context. + */ + +unsigned int +isc_log_getduplicateinterval(isc_logconfig_t *lcfg); +/*%< + * Get the current duplicate filtering interval. + * + * Requires: + *\li lctx is a valid logging context. + * + * Returns: + *\li The current duplicate filtering interval. + */ + +isc_result_t +isc_log_settag(isc_logconfig_t *lcfg, const char *tag); +/*%< + * Set the program name or other identifier for #ISC_LOG_PRINTTAG. + * + * Requires: + *\li lcfg is a valid logging configuration. + * + * Notes: + *\li If this function has not set the tag to a non-NULL, non-empty value, + * then the #ISC_LOG_PRINTTAG channel flag will not print anything. + * Unlike some implementations of syslog on Unix systems, you *must* set + * the tag in order to get it logged. It is not implicitly derived from + * the program name (which is pretty impossible to infer portably). + * + *\li Setting the tag to NULL or the empty string will also cause the + * #ISC_LOG_PRINTTAG channel flag to not print anything. If tag equals the + * empty string, calls to isc_log_gettag will return NULL. + * + * Returns: + *\li #ISC_R_SUCCESS Success + *\li #ISC_R_NOMEMORY Resource Limit: Out of memory + * + * XXXDCL when creating a new isc_logconfig_t, it might be nice if the tag + * of the currently active isc_logconfig_t was inherited. this does not + * currently happen. + */ + +char * +isc_log_gettag(isc_logconfig_t *lcfg); +/*%< + * Get the current identifier printed with #ISC_LOG_PRINTTAG. + * + * Requires: + *\li lcfg is a valid logging configuration. + * + * Notes: + *\li Since isc_log_settag() will not associate a zero-length string + * with the logging configuration, attempts to do so will cause + * this function to return NULL. However, a determined programmer + * will observe that (currently) a tag of length greater than zero + * could be set, and then modified to be zero length. + * + * Returns: + *\li A pointer to the current identifier, or NULL if none has been set. + */ + +void +isc_log_opensyslog(const char *tag, int options, int facility); +/*%< + * Initialize syslog logging. + * + * Notes: + *\li XXXDCL NT + * This is currently equivalent to openlog(), but is not going to remain + * that way. In the meantime, the arguments are all identical to + * those used by openlog(3), as follows: + * + * \code + * tag: The string to use in the position of the program + * name in syslog messages. Most (all?) syslogs + * will use basename(argv[0]) if tag is NULL. + * + * options: LOG_CONS, LOG_PID, LOG_NDELAY ... whatever your + * syslog supports. + * + * facility: The default syslog facility. This is irrelevant + * since isc_log_write will ALWAYS use the channel's + * declared facility. + * \endcode + * + *\li Zero effort has been made (yet) to accommodate systems with openlog() + * that only takes two arguments, or to identify valid syslog + * facilities or options for any given architecture. + * + *\li It is necessary to call isc_log_opensyslog() to initialize + * syslogging on machines which do not support network connections to + * syslogd because they require a Unix domain socket to be used. Since + * this is a chore to determine at run-time, it is suggested that it + * always be called by programs using the ISC logging system. + * + * Requires: + *\li Nothing. + * + * Ensures: + *\li openlog() is called to initialize the syslog system. + */ + +void +isc_log_closefilelogs(isc_log_t *lctx); +/*%< + * Close all open files used by #ISC_LOG_TOFILE channels. + * + * Notes: + *\li This function is provided for programs that want to use their own + * log rolling mechanism rather than the one provided internally. + * For example, a program that wanted to keep daily logs would define + * a channel which used #ISC_LOG_ROLLNEVER, then once a day would + * rename the log file and call isc_log_closefilelogs(). + * + *\li #ISC_LOG_TOFILEDESC channels are unaffected. + * + * Requires: + *\li lctx is a valid context. + * + * Ensures: + *\li The open files are closed and will be reopened when they are + * next needed. + */ + +isc_logcategory_t * +isc_log_categorybyname(isc_log_t *lctx, const char *name); +/*%< + * Find a category by its name. + * + * Notes: + *\li The string name of a category is not required to be unique. + * + * Requires: + *\li lctx is a valid context. + *\li name is not NULL. + * + * Returns: + *\li A pointer to the _first_ isc_logcategory_t structure used by "name". + * + *\li NULL if no category exists by that name. + */ + +isc_logmodule_t * +isc_log_modulebyname(isc_log_t *lctx, const char *name); +/*%< + * Find a module by its name. + * + * Notes: + *\li The string name of a module is not required to be unique. + * + * Requires: + *\li lctx is a valid context. + *\li name is not NULL. + * + * Returns: + *\li A pointer to the _first_ isc_logmodule_t structure used by "name". + * + *\li NULL if no module exists by that name. + */ + +void +isc_log_setcontext(isc_log_t *lctx); +/*%< + * Sets the context used by the libisc for logging. + * + * Requires: + *\li lctx be a valid context. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_LOG_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/magic.h src.ntp/contrib/ntp/lib/isc/include/isc/magic.h --- src/contrib/ntp/lib/isc/include/isc/magic.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/magic.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,41 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: magic.h,v 1.18 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_MAGIC_H +#define ISC_MAGIC_H 1 + +/*! \file isc/magic.h */ + +typedef struct { + unsigned int magic; +} isc__magic_t; + + +/*% + * To use this macro the magic number MUST be the first thing in the + * structure, and MUST be of type "unsigned int". + * The intent of this is to allow magic numbers to be checked even though + * the object is otherwise opaque. + */ +#define ISC_MAGIC_VALID(a,b) (((a) != NULL) && \ + (((const isc__magic_t *)(a))->magic == (b))) + +#define ISC_MAGIC(a, b, c, d) ((a) << 24 | (b) << 16 | (c) << 8 | (d)) + +#endif /* ISC_MAGIC_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/md5.h src.ntp/contrib/ntp/lib/isc/include/isc/md5.h --- src/contrib/ntp/lib/isc/include/isc/md5.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/md5.h 2009-12-09 08:36:44.000000000 +0100 @@ -0,0 +1,73 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: md5.h,v 1.16 2007/06/19 23:47:18 tbox Exp $ */ + +/*! \file isc/md5.h + * \brief This is the header file for the MD5 message-digest algorithm. + * + * The algorithm is due to Ron Rivest. This code was + * written by Colin Plumb in 1993, no copyright is claimed. + * This code is in the public domain; do with it what you wish. + * + * Equivalent code is available from RSA Data Security, Inc. + * This code has been tested against that, and is equivalent, + * except that you don't need to include two pages of legalese + * with every copy. + * + * To compute the message digest of a chunk of bytes, declare an + * MD5Context structure, pass it to MD5Init, call MD5Update as + * needed on buffers full of bytes, and then call MD5Final, which + * will fill a supplied 16-byte array with the digest. + * + * Changed so as no longer to depend on Colin Plumb's `usual.h' + * header definitions; now uses stuff from dpkg's config.h + * - Ian Jackson . + * Still in the public domain. + */ + +#ifndef ISC_MD5_H +#define ISC_MD5_H 1 + +#include +#include + +#define ISC_MD5_DIGESTLENGTH 16U + +typedef struct { + isc_uint32_t buf[4]; + isc_uint32_t bytes[2]; + isc_uint32_t in[16]; +} isc_md5_t; + +ISC_LANG_BEGINDECLS + +void +isc_md5_init(isc_md5_t *ctx); + +void +isc_md5_invalidate(isc_md5_t *ctx); + +void +isc_md5_update(isc_md5_t *ctx, const unsigned char *buf, unsigned int len); + +void +isc_md5_final(isc_md5_t *ctx, unsigned char *digest); + +ISC_LANG_ENDDECLS + +#endif /* ISC_MD5_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/mem.h src.ntp/contrib/ntp/lib/isc/include/isc/mem.h --- src/contrib/ntp/lib/isc/include/isc/mem.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/mem.h 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,629 @@ +/* + * Copyright (C) 2004-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1997-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: mem.h,v 1.78.120.3 2009/02/11 03:07:01 jinmei Exp $ */ + +#ifndef ISC_MEM_H +#define ISC_MEM_H 1 + +/*! \file isc/mem.h */ + +#include + +#include +#include +#include +#include +#include + +ISC_LANG_BEGINDECLS + +#define ISC_MEM_LOWATER 0 +#define ISC_MEM_HIWATER 1 +typedef void (*isc_mem_water_t)(void *, int); + +typedef void * (*isc_memalloc_t)(void *, size_t); +typedef void (*isc_memfree_t)(void *, void *); + +/*% + * Define ISC_MEM_DEBUG=1 to make all functions that free memory + * set the pointer being freed to NULL after being freed. + * This is the default; set ISC_MEM_DEBUG=0 to disable it. + */ +#ifndef ISC_MEM_DEBUG +#define ISC_MEM_DEBUG 1 +#endif + +/*% + * Define ISC_MEM_TRACKLINES=1 to turn on detailed tracing of memory + * allocation and freeing by file and line number. + */ +#ifndef ISC_MEM_TRACKLINES +#define ISC_MEM_TRACKLINES 1 +#endif + +/*% + * Define ISC_MEM_CHECKOVERRUN=1 to turn on checks for using memory outside + * the requested space. This will increase the size of each allocation. + */ +#ifndef ISC_MEM_CHECKOVERRUN +#define ISC_MEM_CHECKOVERRUN 1 +#endif + +/*% + * Define ISC_MEM_FILL=1 to fill each block of memory returned to the system + * with the byte string '0xbe'. This helps track down uninitialized pointers + * and the like. On freeing memory, the space is filled with '0xde' for + * the same reasons. + */ +#ifndef ISC_MEM_FILL +#define ISC_MEM_FILL 1 +#endif + +/*% + * Define ISC_MEMPOOL_NAMES=1 to make memory pools store a symbolic + * name so that the leaking pool can be more readily identified in + * case of a memory leak. + */ +#ifndef ISC_MEMPOOL_NAMES +#define ISC_MEMPOOL_NAMES 1 +#endif + +LIBISC_EXTERNAL_DATA extern unsigned int isc_mem_debugging; +/*@{*/ +#define ISC_MEM_DEBUGTRACE 0x00000001U +#define ISC_MEM_DEBUGRECORD 0x00000002U +#define ISC_MEM_DEBUGUSAGE 0x00000004U +#define ISC_MEM_DEBUGSIZE 0x00000008U +#define ISC_MEM_DEBUGCTX 0x00000010U +#define ISC_MEM_DEBUGALL 0x0000001FU +/*!< + * The variable isc_mem_debugging holds a set of flags for + * turning certain memory debugging options on or off at + * runtime. It is initialized to the value ISC_MEM_DEGBUGGING, + * which is 0 by default but may be overridden at compile time. + * The following flags can be specified: + * + * \li #ISC_MEM_DEBUGTRACE + * Log each allocation and free to isc_lctx. + * + * \li #ISC_MEM_DEBUGRECORD + * Remember each allocation, and match them up on free. + * Crash if a free doesn't match an allocation. + * + * \li #ISC_MEM_DEBUGUSAGE + * If a hi_water mark is set, print the maximum inuse memory + * every time it is raised once it exceeds the hi_water mark. + * + * \li #ISC_MEM_DEBUGSIZE + * Check the size argument being passed to isc_mem_put() matches + * that passed to isc_mem_get(). + * + * \li #ISC_MEM_DEBUGCTX + * Check the mctx argument being passed to isc_mem_put() matches + * that passed to isc_mem_get(). + */ +/*@}*/ + +#if ISC_MEM_TRACKLINES +#define _ISC_MEM_FILELINE , __FILE__, __LINE__ +#define _ISC_MEM_FLARG , const char *, int +#else +#define _ISC_MEM_FILELINE +#define _ISC_MEM_FLARG +#endif + +/*! + * Define ISC_MEM_USE_INTERNAL_MALLOC=1 to use the internal malloc() + * implementation in preference to the system one. The internal malloc() + * is very space-efficient, and quite fast on uniprocessor systems. It + * performs poorly on multiprocessor machines. + * JT: we can overcome the performance issue on multiprocessor machines + * by carefully separating memory contexts. + */ + +#ifndef ISC_MEM_USE_INTERNAL_MALLOC +#define ISC_MEM_USE_INTERNAL_MALLOC 1 +#endif + +/* + * Flags for isc_mem_create2()calls. + */ +#define ISC_MEMFLAG_NOLOCK 0x00000001 /* no lock is necessary */ +#define ISC_MEMFLAG_INTERNAL 0x00000002 /* use internal malloc */ +#if ISC_MEM_USE_INTERNAL_MALLOC +#define ISC_MEMFLAG_DEFAULT ISC_MEMFLAG_INTERNAL +#else +#define ISC_MEMFLAG_DEFAULT 0 +#endif + + +#define isc_mem_get(c, s) isc__mem_get((c), (s) _ISC_MEM_FILELINE) +#define isc_mem_allocate(c, s) isc__mem_allocate((c), (s) _ISC_MEM_FILELINE) +#define isc_mem_reallocate(c, p, s) isc__mem_reallocate((c), (p), (s) _ISC_MEM_FILELINE) +#define isc_mem_strdup(c, p) isc__mem_strdup((c), (p) _ISC_MEM_FILELINE) +#define isc_mempool_get(c) isc__mempool_get((c) _ISC_MEM_FILELINE) + +/*% + * isc_mem_putanddetach() is a convenience function for use where you + * have a structure with an attached memory context. + * + * Given: + * + * \code + * struct { + * ... + * isc_mem_t *mctx; + * ... + * } *ptr; + * + * isc_mem_t *mctx; + * + * isc_mem_putanddetach(&ptr->mctx, ptr, sizeof(*ptr)); + * \endcode + * + * is the equivalent of: + * + * \code + * mctx = NULL; + * isc_mem_attach(ptr->mctx, &mctx); + * isc_mem_detach(&ptr->mctx); + * isc_mem_put(mctx, ptr, sizeof(*ptr)); + * isc_mem_detach(&mctx); + * \endcode + */ + +#if ISC_MEM_DEBUG +#define isc_mem_put(c, p, s) \ + do { \ + isc__mem_put((c), (p), (s) _ISC_MEM_FILELINE); \ + (p) = NULL; \ + } while (0) +#define isc_mem_putanddetach(c, p, s) \ + do { \ + isc__mem_putanddetach((c), (p), (s) _ISC_MEM_FILELINE); \ + (p) = NULL; \ + } while (0) +#define isc_mem_free(c, p) \ + do { \ + isc__mem_free((c), (p) _ISC_MEM_FILELINE); \ + (p) = NULL; \ + } while (0) +#define isc_mempool_put(c, p) \ + do { \ + isc__mempool_put((c), (p) _ISC_MEM_FILELINE); \ + (p) = NULL; \ + } while (0) +#else +#define isc_mem_put(c, p, s) isc__mem_put((c), (p), (s) _ISC_MEM_FILELINE) +#define isc_mem_putanddetach(c, p, s) \ + isc__mem_putanddetach((c), (p), (s) _ISC_MEM_FILELINE) +#define isc_mem_free(c, p) isc__mem_free((c), (p) _ISC_MEM_FILELINE) +#define isc_mempool_put(c, p) isc__mempool_put((c), (p) _ISC_MEM_FILELINE) +#endif + +/*@{*/ +isc_result_t +isc_mem_create(size_t max_size, size_t target_size, + isc_mem_t **mctxp); + +isc_result_t +isc_mem_create2(size_t max_size, size_t target_size, + isc_mem_t **mctxp, unsigned int flags); + +isc_result_t +isc_mem_createx(size_t max_size, size_t target_size, + isc_memalloc_t memalloc, isc_memfree_t memfree, + void *arg, isc_mem_t **mctxp); + +isc_result_t +isc_mem_createx2(size_t max_size, size_t target_size, + isc_memalloc_t memalloc, isc_memfree_t memfree, + void *arg, isc_mem_t **mctxp, unsigned int flags); + +/*!< + * \brief Create a memory context. + * + * 'max_size' and 'target_size' are tuning parameters. When + * ISC_MEMFLAG_INTERNAL is set, allocations smaller than 'max_size' + * will be satisfied by getting blocks of size 'target_size' from the + * system allocator and breaking them up into pieces; larger allocations + * will use the system allocator directly. If 'max_size' and/or + * 'target_size' are zero, default values will be * used. When + * ISC_MEMFLAG_INTERNAL is not set, 'target_size' is ignored. + * + * 'max_size' is also used to size the statistics arrays and the array + * used to record active memory when ISC_MEM_DEBUGRECORD is set. Settin + * 'max_size' too low can have detrimental effects on performance. + * + * A memory context created using isc_mem_createx() will obtain + * memory from the system by calling 'memalloc' and 'memfree', + * passing them the argument 'arg'. A memory context created + * using isc_mem_create() will use the standard library malloc() + * and free(). + * + * If ISC_MEMFLAG_NOLOCK is set in 'flags', the corresponding memory context + * will be accessed without locking. The user who creates the context must + * ensure there be no race. Since this can be a source of bug, it is generally + * inadvisable to use this flag unless the user is very sure about the race + * condition and the access to the object is highly performance sensitive. + * + * Requires: + * mctxp != NULL && *mctxp == NULL */ +/*@}*/ + +/*@{*/ +void +isc_mem_attach(isc_mem_t *, isc_mem_t **); +void +isc_mem_detach(isc_mem_t **); +/*!< + * \brief Attach to / detach from a memory context. + * + * This is intended for applications that use multiple memory contexts + * in such a way that it is not obvious when the last allocations from + * a given context has been freed and destroying the context is safe. + * + * Most applications do not need to call these functions as they can + * simply create a single memory context at the beginning of main() + * and destroy it at the end of main(), thereby guaranteeing that it + * is not destroyed while there are outstanding allocations. + */ +/*@}*/ + +void +isc_mem_destroy(isc_mem_t **); +/*%< + * Destroy a memory context. + */ + +isc_result_t +isc_mem_ondestroy(isc_mem_t *ctx, + isc_task_t *task, + isc_event_t **event); +/*%< + * Request to be notified with an event when a memory context has + * been successfully destroyed. + */ + +void +isc_mem_stats(isc_mem_t *mctx, FILE *out); +/*%< + * Print memory usage statistics for 'mctx' on the stream 'out'. + */ + +void +isc_mem_setdestroycheck(isc_mem_t *mctx, + isc_boolean_t on); +/*%< + * If 'on' is ISC_TRUE, 'mctx' will check for memory leaks when + * destroyed and abort the program if any are present. + */ + +/*@{*/ +void +isc_mem_setquota(isc_mem_t *, size_t); +size_t +isc_mem_getquota(isc_mem_t *); +/*%< + * Set/get the memory quota of 'mctx'. This is a hard limit + * on the amount of memory that may be allocated from mctx; + * if it is exceeded, allocations will fail. + */ +/*@}*/ + +size_t +isc_mem_inuse(isc_mem_t *mctx); +/*%< + * Get an estimate of the number of memory in use in 'mctx', in bytes. + * This includes quantization overhead, but does not include memory + * allocated from the system but not yet used. + */ + +void +isc_mem_setwater(isc_mem_t *mctx, isc_mem_water_t water, void *water_arg, + size_t hiwater, size_t lowater); +/*%< + * Set high and low water marks for this memory context. + * + * When the memory usage of 'mctx' exceeds 'hiwater', + * '(water)(water_arg, #ISC_MEM_HIWATER)' will be called. 'water' needs to + * call isc_mem_waterack() with #ISC_MEM_HIWATER to acknowledge the state + * change. 'water' may be called multiple times. + * + * When the usage drops below 'lowater', 'water' will again be called, this + * time with #ISC_MEM_LOWATER. 'water' need to calls isc_mem_waterack() with + * #ISC_MEM_LOWATER to acknowledge the change. + * + * static void + * water(void *arg, int mark) { + * struct foo *foo = arg; + * + * LOCK(&foo->marklock); + * if (foo->mark != mark) { + * foo->mark = mark; + * .... + * isc_mem_waterack(foo->mctx, mark); + * } + * UNLOCK(&foo->marklock); + * } + * + * If 'water' is NULL then 'water_arg', 'hi_water' and 'lo_water' are + * ignored and the state is reset. + * + * Requires: + * + * 'water' is not NULL. + * hi_water >= lo_water + */ + +void +isc_mem_waterack(isc_mem_t *ctx, int mark); +/*%< + * Called to acknowledge changes in signaled by calls to 'water'. + */ + +void +isc_mem_printactive(isc_mem_t *mctx, FILE *file); +/*%< + * Print to 'file' all active memory in 'mctx'. + * + * Requires ISC_MEM_DEBUGRECORD to have been set. + */ + +void +isc_mem_printallactive(FILE *file); +/*%< + * Print to 'file' all active memory in all contexts. + * + * Requires ISC_MEM_DEBUGRECORD to have been set. + */ + +void +isc_mem_checkdestroyed(FILE *file); +/*%< + * Check that all memory contexts have been destroyed. + * Prints out those that have not been. + * Fatally fails if there are still active contexts. + */ + +unsigned int +isc_mem_references(isc_mem_t *ctx); +/*%< + * Return the current reference count. + */ + +void +isc_mem_setname(isc_mem_t *ctx, const char *name, void *tag); +/*%< + * Name 'ctx'. + * + * Notes: + * + *\li Only the first 15 characters of 'name' will be copied. + * + *\li 'tag' is for debugging purposes only. + * + * Requires: + * + *\li 'ctx' is a valid ctx. + */ + +const char * +isc_mem_getname(isc_mem_t *ctx); +/*%< + * Get the name of 'ctx', as previously set using isc_mem_setname(). + * + * Requires: + *\li 'ctx' is a valid ctx. + * + * Returns: + *\li A non-NULL pointer to a null-terminated string. + * If the ctx has not been named, the string is + * empty. + */ + +void * +isc_mem_gettag(isc_mem_t *ctx); +/*%< + * Get the tag value for 'task', as previously set using isc_mem_setname(). + * + * Requires: + *\li 'ctx' is a valid ctx. + * + * Notes: + *\li This function is for debugging purposes only. + * + * Requires: + *\li 'ctx' is a valid task. + */ + +#ifdef HAVE_LIBXML2 +void +isc_mem_renderxml(xmlTextWriterPtr writer); +/*%< + * Render all contexts' statistics and status in XML for writer. + */ +#endif /* HAVE_LIBXML2 */ + +/* + * Memory pools + */ + +isc_result_t +isc_mempool_create(isc_mem_t *mctx, size_t size, isc_mempool_t **mpctxp); +/*%< + * Create a memory pool. + * + * Requires: + *\li mctx is a valid memory context. + *\li size > 0 + *\li mpctxp != NULL and *mpctxp == NULL + * + * Defaults: + *\li maxalloc = UINT_MAX + *\li freemax = 1 + *\li fillcount = 1 + * + * Returns: + *\li #ISC_R_NOMEMORY -- not enough memory to create pool + *\li #ISC_R_SUCCESS -- all is well. + */ + +void +isc_mempool_destroy(isc_mempool_t **mpctxp); +/*%< + * Destroy a memory pool. + * + * Requires: + *\li mpctxp != NULL && *mpctxp is a valid pool. + *\li The pool has no un"put" allocations outstanding + */ + +void +isc_mempool_setname(isc_mempool_t *mpctx, const char *name); +/*%< + * Associate a name with a memory pool. At most 15 characters may be used. + * + * Requires: + *\li mpctx is a valid pool. + *\li name != NULL; + */ + +void +isc_mempool_associatelock(isc_mempool_t *mpctx, isc_mutex_t *lock); +/*%< + * Associate a lock with this memory pool. + * + * This lock is used when getting or putting items using this memory pool, + * and it is also used to set or get internal state via the isc_mempool_get*() + * and isc_mempool_set*() set of functions. + * + * Multiple pools can each share a single lock. For instance, if "manager" + * type object contained pools for various sizes of events, and each of + * these pools used a common lock. Note that this lock must NEVER be used + * by other than mempool routines once it is given to a pool, since that can + * easily cause double locking. + * + * Requires: + * + *\li mpctpx is a valid pool. + * + *\li lock != NULL. + * + *\li No previous lock is assigned to this pool. + * + *\li The lock is initialized before calling this function via the normal + * means of doing that. + */ + +/* + * The following functions get/set various parameters. Note that due to + * the unlocked nature of pools these are potentially random values unless + * the imposed externally provided locking protocols are followed. + * + * Also note that the quota limits will not always take immediate effect. + * For instance, setting "maxalloc" to a number smaller than the currently + * allocated count is permitted. New allocations will be refused until + * the count drops below this threshold. + * + * All functions require (in addition to other requirements): + * mpctx is a valid memory pool + */ + +unsigned int +isc_mempool_getfreemax(isc_mempool_t *mpctx); +/*%< + * Returns the maximum allowed size of the free list. + */ + +void +isc_mempool_setfreemax(isc_mempool_t *mpctx, unsigned int limit); +/*%< + * Sets the maximum allowed size of the free list. + */ + +unsigned int +isc_mempool_getfreecount(isc_mempool_t *mpctx); +/*%< + * Returns current size of the free list. + */ + +unsigned int +isc_mempool_getmaxalloc(isc_mempool_t *mpctx); +/*!< + * Returns the maximum allowed number of allocations. + */ + +void +isc_mempool_setmaxalloc(isc_mempool_t *mpctx, unsigned int limit); +/*%< + * Sets the maximum allowed number of allocations. + * + * Additional requirements: + *\li limit > 0 + */ + +unsigned int +isc_mempool_getallocated(isc_mempool_t *mpctx); +/*%< + * Returns the number of items allocated from this pool. + */ + +unsigned int +isc_mempool_getfillcount(isc_mempool_t *mpctx); +/*%< + * Returns the number of items allocated as a block from the parent memory + * context when the free list is empty. + */ + +void +isc_mempool_setfillcount(isc_mempool_t *mpctx, unsigned int limit); +/*%< + * Sets the fillcount. + * + * Additional requirements: + *\li limit > 0 + */ + + +/* + * Pseudo-private functions for use via macros. Do not call directly. + */ +void * +isc__mem_get(isc_mem_t *, size_t _ISC_MEM_FLARG); +void +isc__mem_putanddetach(isc_mem_t **, void *, + size_t _ISC_MEM_FLARG); +void +isc__mem_put(isc_mem_t *, void *, size_t _ISC_MEM_FLARG); +void * +isc__mem_allocate(isc_mem_t *, size_t _ISC_MEM_FLARG); +void * +isc__mem_reallocate(isc_mem_t *, void *, size_t _ISC_MEM_FLARG); +void +isc__mem_free(isc_mem_t *, void * _ISC_MEM_FLARG); +char * +isc__mem_strdup(isc_mem_t *, const char *_ISC_MEM_FLARG); +void * +isc__mempool_get(isc_mempool_t * _ISC_MEM_FLARG); +void +isc__mempool_put(isc_mempool_t *, void * _ISC_MEM_FLARG); + +ISC_LANG_ENDDECLS + +#endif /* ISC_MEM_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/msgcat.h src.ntp/contrib/ntp/lib/isc/include/isc/msgcat.h --- src/contrib/ntp/lib/isc/include/isc/msgcat.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/msgcat.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,131 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: msgcat.h,v 1.13 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_MSGCAT_H +#define ISC_MSGCAT_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/msgcat.h + * \brief The ISC Message Catalog + * aids internationalization of applications by allowing + * messages to be retrieved from locale-specific files instead of + * hardwiring them into the application. This allows translations of + * messages appropriate to the locale to be supplied without recompiling + * the application. + * + * Notes: + *\li It's very important that message catalogs work, even if only the + * default_text can be used. + * + * MP: + *\li The caller must ensure appropriate synchronization of + * isc_msgcat_open() and isc_msgcat_close(). isc_msgcat_get() + * ensures appropriate synchronization. + * + * Reliability: + *\li No anticipated impact. + * + * Resources: + *\li TBS + * + * \li Security: + * No anticipated impact. + * + * \li Standards: + * None. + */ + +/***** + ***** Imports + *****/ + +#include +#include + +ISC_LANG_BEGINDECLS + +/***** + ***** Methods + *****/ + +void +isc_msgcat_open(const char *name, isc_msgcat_t **msgcatp); +/*%< + * Open a message catalog. + * + * Notes: + * + *\li If memory cannot be allocated or other failures occur, *msgcatp + * will be set to NULL. If a NULL msgcat is given to isc_msgcat_get(), + * the default_text will be returned, ensuring that some message text + * will be available, no matter what's going wrong. + * + * Requires: + * + *\li 'name' is a valid string. + * + *\li msgcatp != NULL && *msgcatp == NULL + */ + +void +isc_msgcat_close(isc_msgcat_t **msgcatp); +/*%< + * Close a message catalog. + * + * Notes: + * + *\li Any string pointers returned by prior calls to isc_msgcat_get() are + * invalid after isc_msgcat_close() has been called and must not be + * used. + * + * Requires: + * + *\li *msgcatp is a valid message catalog or is NULL. + * + * Ensures: + * + *\li All resources associated with the message catalog are released. + * + *\li *msgcatp == NULL + */ + +const char * +isc_msgcat_get(isc_msgcat_t *msgcat, int set, int message, + const char *default_text); +/*%< + * Get message 'message' from message set 'set' in 'msgcat'. If it + * is not available, use 'default_text'. + * + * Requires: + * + *\li 'msgcat' is a valid message catalog or is NULL. + * + *\li set > 0 + * + *\li message > 0 + * + *\li 'default_text' is a valid string. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_MSGCAT_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/msgs.h src.ntp/contrib/ntp/lib/isc/include/isc/msgs.h --- src/contrib/ntp/lib/isc/include/isc/msgs.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/msgs.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,195 @@ +/* + * Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: msgs.h,v 1.17 2008/08/08 06:28:59 tbox Exp $ */ + +#ifndef ISC_MSGS_H +#define ISC_MSGS_H 1 + +/*! \file isc/msgs.h */ + +#include /* Provide isc_msgcat global variable. */ +#include /* Provide isc_msgcat_*() functions. */ + +/*@{*/ +/*! + * \brief Message sets, named per source file, excepting "GENERAL". + * + * IMPORTANT: The original list is alphabetical, but any new sets must + * be added to the end. + */ +#define ISC_MSGSET_GENERAL 1 +/* ISC_RESULT_RESULTSET 2 */ /* XXX */ +/* ISC_RESULT_UNAVAILABLESET 3 */ /* XXX */ +#define ISC_MSGSET_APP 4 +#define ISC_MSGSET_COMMANDLINE 5 +#define ISC_MSGSET_ENTROPY 6 +#define ISC_MSGSET_IFITERIOCTL 7 +#define ISC_MSGSET_IFITERSYSCTL 8 +#define ISC_MSGSET_LEX 9 +#define ISC_MSGSET_LOG 10 +#define ISC_MSGSET_MEM 11 +#define ISC_MSGSET_NETADDR 12 +#define ISC_MSGSET_PRINT 13 +#define ISC_MSGSET_RESULT 14 +#define ISC_MSGSET_RWLOCK 15 +#define ISC_MSGSET_SOCKADDR 16 +#define ISC_MSGSET_SOCKET 17 +#define ISC_MSGSET_TASK 18 +#define ISC_MSGSET_TIMER 19 +#define ISC_MSGSET_UTIL 20 +#define ISC_MSGSET_IFITERGETIFADDRS 21 +/*@}*/ + +/*@{*/ +/*! + * Message numbers + * are only required to be unique per message set, + * but are unique throughout the entire catalog to not be as confusing when + * debugging. + * + * The initial numbering was done by multiply by 100 the set number the + * message appears in then adding the incremental message number. + */ +#define ISC_MSG_FAILED 101 /*%< "failed" */ +#define ISC_MSG_SUCCEEDED 102 /*%< Compatible with "failed" */ +#define ISC_MSG_SUCCESS 103 /*%< More usual way to say "success" */ +#define ISC_MSG_STARTING 104 /*%< As in "daemon: starting" */ +#define ISC_MSG_STOPING 105 /*%< As in "daemon: stopping" */ +#define ISC_MSG_ENTERING 106 /*%< As in "some_subr: entering" */ +#define ISC_MSG_EXITING 107 /*%< As in "some_subr: exiting" */ +#define ISC_MSG_CALLING 108 /*%< As in "calling some_subr()" */ +#define ISC_MSG_RETURNED 109 /*%< As in "some_subr: returned " */ +#define ISC_MSG_FATALERROR 110 /*%< "fatal error" */ +#define ISC_MSG_SHUTTINGDOWN 111 /*%< "shutting down" */ +#define ISC_MSG_RUNNING 112 /*%< "running" */ +#define ISC_MSG_WAIT 113 /*%< "wait" */ +#define ISC_MSG_WAITUNTIL 114 /*%< "waituntil" */ + +#define ISC_MSG_SIGNALSETUP 201 /*%< "handle_signal() %d setup: %s" */ + +#define ISC_MSG_ILLEGALOPT 301 /*%< "illegal option" */ +#define ISC_MSG_OPTNEEDARG 302 /*%< "option requires an argument" */ + +#define ISC_MSG_ENTROPYSTATS 401 /*%< "Entropy pool %p: refcnt %u ..." */ + +#define ISC_MSG_MAKESCANSOCKET 501 /*%< "making interface scan socket: %s" */ +#define ISC_MSG_GETIFCONFIG 502 /*%< "get interface configuration: %s" */ +#define ISC_MSG_BUFFERMAX 503 /*%< "... maximum buffer size exceeded" */ +#define ISC_MSG_GETDESTADDR 504 /*%< "%s: getting destination address: %s" */ +#define ISC_MSG_GETNETMASK 505 /*%< "%s: getting netmask: %s" */ +#define ISC_MSG_GETBCSTADDR 506 /*%< "%s: getting broadcast address: %s" */ + +#define ISC_MSG_GETIFLISTSIZE 601 /*%< "getting interface list size: ..." */ +#define ISC_MSG_GETIFLIST 602 /*%< "getting interface list: ..." */ +#define ISC_MSG_UNEXPECTEDTYPE 603 /*%< "... unexpected ... message type" */ + +#define ISC_MSG_UNEXPECTEDSTATE 701 /*%< "Unexpected state %d" */ + +#define ISC_MSG_BADTIME 801 /*%< "Bad 00 99:99:99.999 " */ +#define ISC_MSG_LEVEL 802 /*%< "level %d: " */ + +#define ISC_MSG_ADDTRACE 901 /*%< "add %p size %u " */ +#define ISC_MSG_DELTRACE 902 /*%< "del %p size %u " */ +#define ISC_MSG_POOLSTATS 903 /*%< "[Pool statistics]\n" */ +#define ISC_MSG_POOLNAME 904 /*%< "name" */ +#define ISC_MSG_POOLSIZE 905 /*%< "size" */ +#define ISC_MSG_POOLMAXALLOC 906 /*%< "maxalloc" */ +#define ISC_MSG_POOLALLOCATED 907 /*%< "allocated" */ +#define ISC_MSG_POOLFREECOUNT 908 /*%< "freecount" */ +#define ISC_MSG_POOLFREEMAX 909 /*%< "freemax" */ +#define ISC_MSG_POOLFILLCOUNT 910 /*%< "fillcount" */ +#define ISC_MSG_POOLGETS 911 /*%< "gets" */ +#define ISC_MSG_DUMPALLOC 912 /*%< "DUMP OF ALL OUTSTANDING MEMORY ..." */ +#define ISC_MSG_NONE 913 /*%< "\tNone.\n" */ +#define ISC_MSG_PTRFILELINE 914 /*%< "\tptr %p file %s line %u\n" */ + +#define ISC_MSG_UNKNOWNADDR 1001 /*%< "" */ + +#define ISC_MSG_NOLONGDBL 1104 /*%< "long doubles are not supported" */ + +#define ISC_MSG_PRINTLOCK 1201 /*%< "rwlock %p thread %lu ..." */ +#define ISC_MSG_READ 1202 /*%< "read" */ +#define ISC_MSG_WRITE 1203 /*%< "write" */ +#define ISC_MSG_READING 1204 /*%< "reading" */ +#define ISC_MSG_WRITING 1205 /*%< "writing" */ +#define ISC_MSG_PRELOCK 1206 /*%< "prelock" */ +#define ISC_MSG_POSTLOCK 1207 /*%< "postlock" */ +#define ISC_MSG_PREUNLOCK 1208 /*%< "preunlock" */ +#define ISC_MSG_POSTUNLOCK 1209 /*%< "postunlock" */ + +#define ISC_MSG_UNKNOWNFAMILY 1301 /*%< "unknown address family: %d" */ + +#define ISC_MSG_WRITEFAILED 1401 /*%< "write() failed during watcher ..." */ +#define ISC_MSG_READFAILED 1402 /*%< "read() failed during watcher ... " */ +#define ISC_MSG_PROCESSCMSG 1403 /*%< "processing cmsg %p" */ +#define ISC_MSG_IFRECEIVED 1404 /*%< "interface received on ifindex %u" */ +#define ISC_MSG_SENDTODATA 1405 /*%< "sendto pktinfo data, ifindex %u" */ +#define ISC_MSG_DOIORECV 1406 /*%< "doio_recv: recvmsg(%d) %d bytes ..." */ +#define ISC_MSG_PKTRECV 1407 /*%< "packet received correctly" */ +#define ISC_MSG_DESTROYING 1408 /*%< "destroying" */ +#define ISC_MSG_CREATED 1409 /*%< "created" */ +#define ISC_MSG_ACCEPTLOCK 1410 /*%< "internal_accept called, locked ..." */ +#define ISC_MSG_ACCEPTEDCXN 1411 /*%< "accepted connection, new socket %p" */ +#define ISC_MSG_INTERNALRECV 1412 /*%< "internal_recv: task %p got event %p" */ +#define ISC_MSG_INTERNALSEND 1413 /*%< "internal_send: task %p got event %p" */ +#define ISC_MSG_WATCHERMSG 1414 /*%< "watcher got message %d" */ +#define ISC_MSG_SOCKETSREMAIN 1415 /*%< "sockets exist" */ +#define ISC_MSG_PKTINFOPROVIDED 1416 /*%< "pktinfo structure provided, ..." */ +#define ISC_MSG_BOUND 1417 /*%< "bound" */ +#define ISC_MSG_ACCEPTRETURNED 1418 /*%< accept() returned %d/%s */ +#define ISC_MSG_TOOMANYFDS 1419 /*%< %s: too many open file descriptors */ +#define ISC_MSG_ZEROPORT 1420 /*%< dropping source port zero packet */ +#define ISC_MSG_FILTER 1421 /*%< setsockopt(SO_ACCEPTFILTER): %s */ + +#define ISC_MSG_TOOMANYHANDLES 1422 /*%< %s: too many open WSA event handles: %s */ + + +#define ISC_MSG_AWAKE 1502 /*%< "awake" */ +#define ISC_MSG_WORKING 1503 /*%< "working" */ +#define ISC_MSG_EXECUTE 1504 /*%< "execute action" */ +#define ISC_MSG_EMPTY 1505 /*%< "empty" */ +#define ISC_MSG_DONE 1506 /*%< "done" */ +#define ISC_MSG_QUANTUM 1507 /*%< "quantum" */ + +#define ISC_MSG_SCHEDULE 1601 /*%< "schedule" */ +#define ISC_MSG_SIGNALSCHED 1602 /*%< "signal (schedule)" */ +#define ISC_MSG_SIGNALDESCHED 1603 /*%< "signal (deschedule)" */ +#define ISC_MSG_SIGNALDESTROY 1604 /*%< "signal (destroy)" */ +#define ISC_MSG_IDLERESCHED 1605 /*%< "idle reschedule" */ +#define ISC_MSG_EVENTNOTALLOC 1606 /*%< "couldn't allocate event" */ +#define ISC_MSG_SCHEDFAIL 1607 /*%< "couldn't schedule timer: %u" */ +#define ISC_MSG_POSTING 1608 /*%< "posting" */ +#define ISC_MSG_WAKEUP 1609 /*%< "wakeup" */ + +#define ISC_MSG_LOCK 1701 /*%< "LOCK" */ +#define ISC_MSG_LOCKING 1702 /*%< "LOCKING" */ +#define ISC_MSG_LOCKED 1703 /*%< "LOCKED" */ +#define ISC_MSG_UNLOCKED 1704 /*%< "UNLOCKED" */ +#define ISC_MSG_RWLOCK 1705 /*%< "RWLOCK" */ +#define ISC_MSG_RWLOCKED 1706 /*%< "RWLOCKED" */ +#define ISC_MSG_RWUNLOCK 1707 /*%< "RWUNLOCK" */ +#define ISC_MSG_BROADCAST 1708 /*%< "BROADCAST" */ +#define ISC_MSG_SIGNAL 1709 /*%< "SIGNAL" */ +#define ISC_MSG_UTILWAIT 1710 /*%< "WAIT" */ +#define ISC_MSG_WAITED 1711 /*%< "WAITED" */ + +#define ISC_MSG_GETIFADDRS 1801 /*%< "getting interface addresses: ..." */ + +/*@}*/ + +#endif /* ISC_MSGS_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/mutexblock.h src.ntp/contrib/ntp/lib/isc/include/isc/mutexblock.h --- src/contrib/ntp/lib/isc/include/isc/mutexblock.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/mutexblock.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,71 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: mutexblock.h,v 1.17 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_MUTEXBLOCK_H +#define ISC_MUTEXBLOCK_H 1 + +/*! \file isc/mutexblock.h */ + +#include +#include +#include + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_mutexblock_init(isc_mutex_t *block, unsigned int count); +/*%< + * Initialize a block of locks. If an error occurs all initialized locks + * will be destroyed, if possible. + * + * Requires: + * + *\li block != NULL + * + *\li count > 0 + * + * Returns: + * + *\li Any code isc_mutex_init() can return is a valid return for this + * function. + */ + +isc_result_t +isc_mutexblock_destroy(isc_mutex_t *block, unsigned int count); +/*%< + * Destroy a block of locks. + * + * Requires: + * + *\li block != NULL + * + *\li count > 0 + * + *\li Each lock in the block be initialized via isc_mutex_init() or + * the whole block was initialized via isc_mutex_initblock(). + * + * Returns: + * + *\li Any code isc_mutex_init() can return is a valid return for this + * function. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_MUTEXBLOCK_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/netaddr.h src.ntp/contrib/ntp/lib/isc/include/isc/netaddr.h --- src/contrib/ntp/lib/isc/include/isc/netaddr.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/netaddr.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,180 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: netaddr.h,v 1.35.332.2 2009/01/18 23:47:41 tbox Exp $ */ + +#ifndef ISC_NETADDR_H +#define ISC_NETADDR_H 1 + +/*! \file isc/netaddr.h */ + +#include +#include +#include + +#ifdef ISC_PLATFORM_HAVESYSUNH +#include +#include +#endif + +ISC_LANG_BEGINDECLS + +struct isc_netaddr { + unsigned int family; + union { + struct in_addr in; + struct in6_addr in6; +#ifdef ISC_PLATFORM_HAVESYSUNH + char un[sizeof(((struct sockaddr_un *)0)->sun_path)]; +#endif + } type; + isc_uint32_t zone; +}; + +isc_boolean_t +isc_netaddr_equal(const isc_netaddr_t *a, const isc_netaddr_t *b); + +/*%< + * Compare network addresses 'a' and 'b'. Return #ISC_TRUE if + * they are equal, #ISC_FALSE if not. + */ + +isc_boolean_t +isc_netaddr_eqprefix(const isc_netaddr_t *a, const isc_netaddr_t *b, + unsigned int prefixlen); +/*%< + * Compare the 'prefixlen' most significant bits of the network + * addresses 'a' and 'b'. If 'b''s scope is zero then 'a''s scope is + * ignored. Return #ISC_TRUE if they are equal, #ISC_FALSE if not. + */ + +isc_result_t +isc_netaddr_masktoprefixlen(const isc_netaddr_t *s, unsigned int *lenp); +/*%< + * Convert a netmask in 's' into a prefix length in '*lenp'. + * The mask should consist of zero or more '1' bits in the most + * most significant part of the address, followed by '0' bits. + * If this is not the case, #ISC_R_MASKNONCONTIG is returned. + * + * Returns: + *\li #ISC_R_SUCCESS + *\li #ISC_R_MASKNONCONTIG + */ + +isc_result_t +isc_netaddr_totext(const isc_netaddr_t *netaddr, isc_buffer_t *target); +/*%< + * Append a text representation of 'sockaddr' to the buffer 'target'. + * The text is NOT null terminated. Handles IPv4 and IPv6 addresses. + * + * Returns: + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOSPACE The text or the null termination did not fit. + *\li #ISC_R_FAILURE Unspecified failure + */ + +void +isc_netaddr_format(const isc_netaddr_t *na, char *array, unsigned int size); +/*%< + * Format a human-readable representation of the network address '*na' + * into the character array 'array', which is of size 'size'. + * The resulting string is guaranteed to be null-terminated. + */ + +#define ISC_NETADDR_FORMATSIZE \ + sizeof("xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:XXX.XXX.XXX.XXX%SSSSSSSSSS") +/*%< + * Minimum size of array to pass to isc_netaddr_format(). + */ + +void +isc_netaddr_fromsockaddr(isc_netaddr_t *netaddr, const isc_sockaddr_t *source); + +void +isc_netaddr_fromin(isc_netaddr_t *netaddr, const struct in_addr *ina); + +void +isc_netaddr_fromin6(isc_netaddr_t *netaddr, const struct in6_addr *ina6); + +isc_result_t +isc_netaddr_frompath(isc_netaddr_t *netaddr, const char *path); + +void +isc_netaddr_setzone(isc_netaddr_t *netaddr, isc_uint32_t zone); + +isc_uint32_t +isc_netaddr_getzone(const isc_netaddr_t *netaddr); + +void +isc_netaddr_any(isc_netaddr_t *netaddr); +/*%< + * Return the IPv4 wildcard address. + */ + +void +isc_netaddr_any6(isc_netaddr_t *netaddr); +/*%< + * Return the IPv6 wildcard address. + */ + +isc_boolean_t +isc_netaddr_ismulticast(isc_netaddr_t *na); +/*%< + * Returns ISC_TRUE if the address is a multicast address. + */ + +isc_boolean_t +isc_netaddr_isexperimental(isc_netaddr_t *na); +/*%< + * Returns ISC_TRUE if the address is a experimental (CLASS E) address. + */ + +isc_boolean_t +isc_netaddr_islinklocal(isc_netaddr_t *na); +/*%< + * Returns #ISC_TRUE if the address is a link local address. + */ + +isc_boolean_t +isc_netaddr_issitelocal(isc_netaddr_t *na); +/*%< + * Returns #ISC_TRUE if the address is a site local address. + */ + +void +isc_netaddr_fromv4mapped(isc_netaddr_t *t, const isc_netaddr_t *s); +/*%< + * Convert an IPv6 v4mapped address into an IPv4 address. + */ + +isc_result_t +isc_netaddr_prefixok(const isc_netaddr_t *na, unsigned int prefixlen); +/* + * Test whether the netaddr 'na' and 'prefixlen' are consistant. + * e.g. prefixlen within range. + * na does not have bits set which are not covered by the prefixlen. + * + * Returns: + * ISC_R_SUCCESS + * ISC_R_RANGE prefixlen out of range + * ISC_R_NOTIMPLEMENTED unsupported family + * ISC_R_FAILURE extra bits. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_NETADDR_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/netscope.h src.ntp/contrib/ntp/lib/isc/include/isc/netscope.h --- src/contrib/ntp/lib/isc/include/isc/netscope.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/netscope.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,43 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: netscope.h,v 1.11 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_NETSCOPE_H +#define ISC_NETSCOPE_H 1 + +/*! \file isc/netscope.h */ + +ISC_LANG_BEGINDECLS + +/*% + * Convert a string of an IPv6 scope zone to zone index. If the conversion + * succeeds, 'zoneid' will store the index value. + * + * XXXJT: when a standard interface for this purpose is defined, + * we should use it. + * + * Returns: + * \li ISC_R_SUCCESS: conversion succeeds + * \li ISC_R_FAILURE: conversion fails + */ +isc_result_t +isc_netscope_pton(int af, char *scopename, void *addr, isc_uint32_t *zoneid); + +ISC_LANG_ENDDECLS + +#endif /* ISC_NETADDR_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/ondestroy.h src.ntp/contrib/ntp/lib/isc/include/isc/ondestroy.h --- src/contrib/ntp/lib/isc/include/isc/ondestroy.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/ondestroy.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,116 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: ondestroy.h,v 1.14 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_ONDESTROY_H +#define ISC_ONDESTROY_H 1 + +#include +#include + +ISC_LANG_BEGINDECLS + +/*! \file isc/ondestroy.h + * ondestroy handling. + * + * Any class ``X'' of objects that wants to send out notifications + * on its destruction should declare a field of type isc_ondestroy_t + * (call it 'ondest'). + * + * \code + * typedef struct { + * ... + * isc_ondestroy_t ondest; + * ... + * } X; + * \endcode + * + * When an object ``A'' of type X is created + * it must initialize the field ondest with a call to + * + * \code + * isc_ondestroy_init(&A->ondest). + * \endcode + * + * X should also provide a registration function for third-party + * objects to call to register their interest in being told about + * the destruction of a particular instance of X. + * + * \code + * isc_result_t + * X_ondestroy(X *instance, isc_task_t *task, + * isc_event_t **eventp) { + * return(isc_ondestroy_register(&instance->ondest, task,eventp)); + * } + * \endcode + * + * Note: locking of the ondestory structure embedded inside of X, is + * X's responsibility. + * + * When an instance of X is destroyed, a call to isc_ondestroy_notify() + * sends the notifications: + * + * \code + * X *instance; + * isc_ondestroy_t ondest = instance->ondest; + * + * ... completely cleanup 'instance' here... + * + * isc_ondestroy_notify(&ondest, instance); + * \endcode + * + * + * see lib/dns/zone.c for an ifdef'd-out example. + */ + +struct isc_ondestroy { + unsigned int magic; + isc_eventlist_t events; +}; + +void +isc_ondestroy_init(isc_ondestroy_t *ondest); +/*%< + * Initialize the on ondest structure. *must* be called before first call + * to isc_ondestroy_register(). + */ + +isc_result_t +isc_ondestroy_register(isc_ondestroy_t *ondest, isc_task_t *task, + isc_event_t **eventp); + +/*%< + * Stores task and *eventp away inside *ondest. Ownership of **event is + * taken from the caller (and *eventp is set to NULL). The task is attached + * to. + */ + +void +isc_ondestroy_notify(isc_ondestroy_t *ondest, void *sender); +/*%< + * Dispatches the event(s) to the task(s) that were given in + * isc_ondestroy_register call(s) (done via calls to + * isc_task_sendanddetach()). Before dispatch, the sender value of each + * event structure is set to the value of the sender paramater. The + * internal structures of the ondest parameter are cleaned out, so no other + * cleanup is needed. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_ONDESTROY_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/os.h src.ntp/contrib/ntp/lib/isc/include/isc/os.h --- src/contrib/ntp/lib/isc/include/isc/os.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/os.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,38 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: os.h,v 1.12 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_OS_H +#define ISC_OS_H 1 + +/*! \file isc/os.h */ + +#include + +ISC_LANG_BEGINDECLS + +unsigned int +isc_os_ncpus(void); +/*%< + * Return the number of CPUs available on the system, or 1 if this cannot + * be determined. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_OS_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/parseint.h src.ntp/contrib/ntp/lib/isc/include/isc/parseint.h --- src/contrib/ntp/lib/isc/include/isc/parseint.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/parseint.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,64 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001, 2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: parseint.h,v 1.9 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_PARSEINT_H +#define ISC_PARSEINT_H 1 + +#include +#include + +/*! \file isc/parseint.h + * \brief Parse integers, in a saner way than atoi() or strtoul() do. + */ + +/*** + *** Functions + ***/ + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_parse_uint32(isc_uint32_t *uip, const char *string, int base); + +isc_result_t +isc_parse_uint16(isc_uint16_t *uip, const char *string, int base); + +isc_result_t +isc_parse_uint8(isc_uint8_t *uip, const char *string, int base); +/*%< + * Parse the null-terminated string 'string' containing a base 'base' + * integer, storing the result in '*uip'. + * The base is interpreted + * as in strtoul(). Unlike strtoul(), leading whitespace, minus or + * plus signs are not accepted, and all errors (including overflow) + * are reported uniformly through the return value. + * + * Requires: + *\li 'string' points to a null-terminated string + *\li 0 <= 'base' <= 36 + * + * Returns: + *\li #ISC_R_SUCCESS + *\li #ISC_R_BADNUMBER The string is not numeric (in the given base) + *\li #ISC_R_RANGE The number is not representable as the requested type. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_PARSEINT_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/platform.h src.ntp/contrib/ntp/lib/isc/include/isc/platform.h --- src/contrib/ntp/lib/isc/include/isc/platform.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/platform.h 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,40 @@ +/* + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM + * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL + * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING + * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, + * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION + * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: platform.h.in,v 1.28 2001/11/19 03:08:26 mayer Exp $ */ + +#ifndef ISC_PLATFORM_H +#define ISC_PLATFORM_H 1 + + +#ifndef ISC_PLATFORM_USEDECLSPEC +#define LIBISC_EXTERNAL_DATA +#define LIBDNS_EXTERNAL_DATA +#define LIBISCCC_EXTERNAL_DATA +#define LIBISCCFG_EXTERNAL_DATA +#define LIBBIND9_EXTERNAL_DATA +#endif /* ISC_PLATFORM_USEDECLSPEC */ + +/* + * Tell emacs to use C mode for this file. + * + * Local Variables: + * mode: c + * End: + */ + +#endif /* ISC_PLATFORM_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/platform.h.in src.ntp/contrib/ntp/lib/isc/include/isc/platform.h.in --- src/contrib/ntp/lib/isc/include/isc/platform.h.in 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/platform.h.in 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,339 @@ +/* + * Copyright (C) 2004-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: platform.h.in,v 1.48.84.2 2009/02/16 23:47:15 tbox Exp $ */ + +#ifndef ISC_PLATFORM_H +#define ISC_PLATFORM_H 1 + +/*! \file */ + +/***** + ***** Platform-dependent defines. + *****/ + +/*** + *** Network. + ***/ + +/*! \brief + * Define if this system needs the header file included + * for full IPv6 support (pretty much only UnixWare). + */ +@ISC_PLATFORM_NEEDNETINETIN6H@ + +/*! \brief + * Define if this system needs the header file included + * to support in6_pkinfo (pretty much only BSD/OS). + */ +@ISC_PLATFORM_NEEDNETINET6IN6H@ + +/*! \brief + * If sockaddrs on this system have an sa_len field, ISC_PLATFORM_HAVESALEN + * will be defined. + */ +@ISC_PLATFORM_HAVESALEN@ + +/*! \brief + * If this system has the IPv6 structure definitions, ISC_PLATFORM_HAVEIPV6 + * will be defined. + */ +@ISC_PLATFORM_HAVEIPV6@ + +/*! \brief + * If this system is missing in6addr_any, ISC_PLATFORM_NEEDIN6ADDRANY will + * be defined. + */ +@ISC_PLATFORM_NEEDIN6ADDRANY@ + +/*! \brief + * If this system is missing in6addr_loopback, ISC_PLATFORM_NEEDIN6ADDRLOOPBACK + * will be defined. + */ +@ISC_PLATFORM_NEEDIN6ADDRLOOPBACK@ + +/*! \brief + * If this system has in6_pktinfo, ISC_PLATFORM_HAVEIN6PKTINFO will be + * defined. + */ +@ISC_PLATFORM_HAVEIN6PKTINFO@ + +/*! \brief + * If this system has in_addr6, rather than in6_addr, ISC_PLATFORM_HAVEINADDR6 + * will be defined. + */ +@ISC_PLATFORM_HAVEINADDR6@ + +/*! \brief + * If this system has sin6_scope_id, ISC_PLATFORM_HAVESCOPEID will be defined. + */ +@ISC_PLATFORM_HAVESCOPEID@ + +/*! \brief + * If this system needs inet_ntop(), ISC_PLATFORM_NEEDNTOP will be defined. + */ +@ISC_PLATFORM_NEEDNTOP@ + +/*! \brief + * If this system needs inet_pton(), ISC_PLATFORM_NEEDPTON will be defined. + */ +@ISC_PLATFORM_NEEDPTON@ + +/*! \brief + * If this system needs in_port_t, ISC_PLATFORM_NEEDPORTT will be defined. + */ +@ISC_PLATFORM_NEEDPORTT@ + +/*! \brief + * Define if the system has struct lifconf which is a extended struct ifconf + * for IPv6. + */ +@ISC_PLATFORM_HAVELIFCONF@ + +/*! \brief + * Define if the system has struct if_laddrconf which is a extended struct + * ifconf for IPv6. + */ +@ISC_PLATFORM_HAVEIF_LADDRCONF@ + +/*! \brief + * Define if the system has struct if_laddrreq. + */ +@ISC_PLATFORM_HAVEIF_LADDRREQ@ + +/*! \brief + * Define either ISC_PLATFORM_BSD44MSGHDR or ISC_PLATFORM_BSD43MSGHDR. + */ +@ISC_PLATFORM_MSGHDRFLAVOR@ + +/*! \brief + * Define if the system supports if_nametoindex. + */ +@ISC_PLATFORM_HAVEIFNAMETOINDEX@ + +/*! \brief + * Define on some UnixWare systems to fix erroneous definitions of various + * IN6_IS_ADDR_* macros. + */ +@ISC_PLATFORM_FIXIN6ISADDR@ + +/*! \brief + * Define if the system supports kqueue multiplexing + */ +@ISC_PLATFORM_HAVEKQUEUE@ + +/*! \brief + * Define if the system supports epoll multiplexing + */ +@ISC_PLATFORM_HAVEEPOLL@ + +/*! \brief + * Define if the system supports /dev/poll multiplexing + */ +@ISC_PLATFORM_HAVEDEVPOLL@ + +/* + *** Printing. + ***/ + +/*! \brief + * If this system needs vsnprintf() and snprintf(), ISC_PLATFORM_NEEDVSNPRINTF + * will be defined. + */ +@ISC_PLATFORM_NEEDVSNPRINTF@ + +/*! \brief + * If this system need a modern sprintf() that returns (int) not (char*). + */ +@ISC_PLATFORM_NEEDSPRINTF@ + +/*! \brief + * The printf format string modifier to use with isc_uint64_t values. + */ +@ISC_PLATFORM_QUADFORMAT@ + +/*** + *** String functions. + ***/ +/* + * If the system needs strsep(), ISC_PLATFORM_NEEDSTRSEP will be defined. + */ +@ISC_PLATFORM_NEEDSTRSEP@ + +/* + * If the system needs strlcpy(), ISC_PLATFORM_NEEDSTRLCPY will be defined. + */ +@ISC_PLATFORM_NEEDSTRLCPY@ + +/* + * If the system needs strlcat(), ISC_PLATFORM_NEEDSTRLCAT will be defined. + */ +@ISC_PLATFORM_NEEDSTRLCAT@ + +/* + * Define if this system needs strtoul. + */ +@ISC_PLATFORM_NEEDSTRTOUL@ + +/* + * Define if this system needs memmove. + */ +@ISC_PLATFORM_NEEDMEMMOVE@ + +/*** + *** Miscellaneous. + ***/ + +/* + * Defined if we are using threads. + */ +@ISC_PLATFORM_USETHREADS@ + +/* + * Defined if unistd.h does not cause fd_set to be delared. + */ +@ISC_PLATFORM_NEEDSYSSELECTH@ + +/* + * Defined to or for how to include + * the GSSAPI header. + */ +@ISC_PLATFORM_GSSAPIHEADER@ + +/* + * Type used for resource limits. + */ +@ISC_PLATFORM_RLIMITTYPE@ + +/* + * Define if your compiler supports "long long int". + */ +@ISC_PLATFORM_HAVELONGLONG@ + +/* + * Define if PTHREAD_ONCE_INIT should be surrounded by braces to + * prevent compiler warnings (such as with gcc on Solaris 2.8). + */ +@ISC_PLATFORM_BRACEPTHREADONCEINIT@ + +/* + * Used to control how extern data is linked; needed for Win32 platforms. + */ +@ISC_PLATFORM_USEDECLSPEC@ + +/* + * Define if the platform has . + */ +@ISC_PLATFORM_HAVESYSUNH@ + +/* + * If the "xadd" operation is available on this architecture, + * ISC_PLATFORM_HAVEXADD will be defined. + */ +@ISC_PLATFORM_HAVEXADD@ + +/* + * If the "xaddq" operation (64bit xadd) is available on this architecture, + * ISC_PLATFORM_HAVEXADDQ will be defined. + */ +@ISC_PLATFORM_HAVEXADDQ@ + +/* + * If the "atomic swap" operation is available on this architecture, + * ISC_PLATFORM_HAVEATOMICSTORE" will be defined. + */ +@ISC_PLATFORM_HAVEATOMICSTORE@ + +/* + * If the "compare-and-exchange" operation is available on this architecture, + * ISC_PLATFORM_HAVECMPXCHG will be defined. + */ +@ISC_PLATFORM_HAVECMPXCHG@ + +/* + * Define if gcc ASM extension is available + */ +@ISC_PLATFORM_USEGCCASM@ + +/* + * Define if Tru64 style ASM syntax must be used. + */ +@ISC_PLATFORM_USEOSFASM@ + +/* + * Define if the standard __asm function must be used. + */ +@ISC_PLATFORM_USESTDASM@ + +/* + * Define if the platform has . + */ +@ISC_PLATFORM_HAVESTRINGSH@ + +/*** + *** Windows dll support. + ***/ + +/* + * Define if MacOS style of PPC assembly must be used. + * e.g. "r6", not "6", for register six. + */ +@ISC_PLATFORM_USEMACASM@ + +#ifndef ISC_PLATFORM_USEDECLSPEC +#define LIBISC_EXTERNAL_DATA +#define LIBDNS_EXTERNAL_DATA +#define LIBISCCC_EXTERNAL_DATA +#define LIBISCCFG_EXTERNAL_DATA +#define LIBBIND9_EXTERNAL_DATA +#else /*! \brief ISC_PLATFORM_USEDECLSPEC */ +#ifdef LIBISC_EXPORTS +#define LIBISC_EXTERNAL_DATA __declspec(dllexport) +#else +#define LIBISC_EXTERNAL_DATA __declspec(dllimport) +#endif +#ifdef LIBDNS_EXPORTS +#define LIBDNS_EXTERNAL_DATA __declspec(dllexport) +#else +#define LIBDNS_EXTERNAL_DATA __declspec(dllimport) +#endif +#ifdef LIBISCCC_EXPORTS +#define LIBISCCC_EXTERNAL_DATA __declspec(dllexport) +#else +#define LIBISCCC_EXTERNAL_DATA __declspec(dllimport) +#endif +#ifdef LIBISCCFG_EXPORTS +#define LIBISCCFG_EXTERNAL_DATA __declspec(dllexport) +#else +#define LIBISCCFG_EXTERNAL_DATA __declspec(dllimport) +#endif +#ifdef LIBBIND9_EXPORTS +#define LIBBIND9_EXTERNAL_DATA __declspec(dllexport) +#else +#define LIBBIND9_EXTERNAL_DATA __declspec(dllimport) +#endif +#endif /*! \brief ISC_PLATFORM_USEDECLSPEC */ + +/* + * Tell emacs to use C mode for this file. + * + * Local Variables: + * mode: c + * End: + */ + +#endif /* ISC_PLATFORM_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/portset.h src.ntp/contrib/ntp/lib/isc/include/isc/portset.h --- src/contrib/ntp/lib/isc/include/isc/portset.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/portset.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,141 @@ +/* + * Copyright (C) 2008, 2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: portset.h,v 1.3.90.2 2009/01/18 23:47:41 tbox Exp $ */ + +/*! \file isc/portset.h + * \brief Transport Protocol Port Manipulation Module + * + * This module provides simple utilities to handle a set of transport protocol + * (UDP or TCP) port numbers, e.g., for creating an ACL list. An isc_portset_t + * object is an opaque instance of a port set, for which the user can add or + * remove a specific port or a range of consecutive ports. This object is + * expected to be used as a temporary work space only, and does not protect + * simultaneous access from multiple threads. Therefore it must not be stored + * in a place that can be accessed from multiple threads. + */ + +#ifndef ISC_PORTSET_H +#define ISC_PORTSET_H 1 + +/*** + *** Imports + ***/ + +#include + +/*** + *** Functions + ***/ + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_portset_create(isc_mem_t *mctx, isc_portset_t **portsetp); +/*%< + * Create a port set and initialize it as an empty set. + * + * Requires: + *\li 'mctx' to be valid. + *\li 'portsetp' to be non NULL and '*portsetp' to be NULL; + * + * Returns: + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY + */ + +void +isc_portset_destroy(isc_mem_t *mctx, isc_portset_t **portsetp); +/*%< + * Destroy a port set. + * + * Requires: + *\li 'mctx' to be valid and must be the same context given when the port set + * was created. + *\li '*portsetp' to be a valid set. + */ + +isc_boolean_t +isc_portset_isset(isc_portset_t *portset, in_port_t port); +/*%< + * Test whether the given port is stored in the portset. + * + * Requires: + *\li 'portset' to be a valid set. + * + * Returns + * \li #ISC_TRUE if the port is found, ISC_FALSE otherwise. + */ + +unsigned int +isc_portset_nports(isc_portset_t *portset); +/*%< + * Provides the number of ports stored in the given portset. + * + * Requires: + *\li 'portset' to be a valid set. + * + * Returns + * \li the number of ports stored in portset. + */ + +void +isc_portset_add(isc_portset_t *portset, in_port_t port); +/*%< + * Add the given port to the portset. The port may or may not be stored in + * the portset. + * + * Requires: + *\li 'portlist' to be valid. + */ + +void +isc_portset_remove(isc_portset_t *portset, in_port_t port); +/*%< + * Remove the given port to the portset. The port may or may not be stored in + * the portset. + * + * Requires: + *\li 'portlist' to be valid. + */ + +void +isc_portset_addrange(isc_portset_t *portset, in_port_t port_lo, + in_port_t port_hi); +/*%< + * Add a subset of [port_lo, port_hi] (inclusive) to the portset. Ports in the + * subset may or may not be stored in portset. + * + * Requires: + *\li 'portlist' to be valid. + *\li port_lo <= port_hi + */ + +void +isc_portset_removerange(isc_portset_t *portset, in_port_t port_lo, + in_port_t port_hi); +/*%< + * Subtract a subset of [port_lo, port_hi] (inclusive) from the portset. Ports + * in the subset may or may not be stored in portset. + * + * Requires: + *\li 'portlist' to be valid. + *\li port_lo <= port_hi + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_NETADDR_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/print.h src.ntp/contrib/ntp/lib/isc/include/isc/print.h --- src/contrib/ntp/lib/isc/include/isc/print.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/print.h 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,87 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: print.h,v 1.26 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_PRINT_H +#define ISC_PRINT_H 1 + +/*! \file isc/print.h */ + +/*** + *** Imports + ***/ + +#include /* Required for ISC_FORMAT_PRINTF() macro. */ +#include +#include + +/*! + * This block allows lib/isc/print.c to be cleanly compiled even if + * the platform does not need it. The standard Makefile will still + * not compile print.c or archive print.o, so this is just to make test + * compilation ("make print.o") easier. + */ +#if !defined(ISC_PLATFORM_NEEDVSNPRINTF) && defined(ISC__PRINT_SOURCE) +#define ISC_PLATFORM_NEEDVSNPRINTF +#endif + +#if !defined(ISC_PLATFORM_NEEDSPRINTF) && defined(ISC__PRINT_SOURCE) +#define ISC_PLATFORM_NEEDSPRINTF +#endif + +/*** + *** Macros + ***/ +#define ISC_PRINT_QUADFORMAT ISC_PLATFORM_QUADFORMAT + +/*** + *** Functions + ***/ + +#ifdef ISC_PLATFORM_NEEDVSNPRINTF +#include +#include +#endif +#ifdef ISC_PLATFORM_NEEDSPRINTF +#include +#endif + + +ISC_LANG_BEGINDECLS + +#ifdef ISC_PLATFORM_NEEDVSNPRINTF +int +isc_print_vsnprintf(char *str, size_t size, const char *format, va_list ap) + ISC_FORMAT_PRINTF(3, 0); +#define vsnprintf isc_print_vsnprintf + +int +isc_print_snprintf(char *str, size_t size, const char *format, ...) + ISC_FORMAT_PRINTF(3, 4); +#define snprintf isc_print_snprintf +#endif /* ISC_PLATFORM_NEEDVSNPRINTF */ + +#ifdef ISC_PLATFORM_NEEDSPRINTF +int +isc_print_sprintf(char *str, const char *format, ...) ISC_FORMAT_PRINTF(2, 3); +#define sprintf isc_print_sprintf +#endif + +ISC_LANG_ENDDECLS + +#endif /* ISC_PRINT_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/quota.h src.ntp/contrib/ntp/lib/isc/include/isc/quota.h --- src/contrib/ntp/lib/isc/include/isc/quota.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/quota.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,119 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: quota.h,v 1.16 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_QUOTA_H +#define ISC_QUOTA_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/quota.h + * + * \brief The isc_quota_t object is a simple helper object for implementing + * quotas on things like the number of simultaneous connections to + * a server. It keeps track of the amount of quota in use, and + * encapsulates the locking necessary to allow multiple tasks to + * share a quota. + */ + +/*** + *** Imports. + ***/ + +#include +#include +#include + +/***** + ***** Types. + *****/ + +ISC_LANG_BEGINDECLS + +/*% isc_quota structure */ +struct isc_quota { + isc_mutex_t lock; /*%< Locked by lock. */ + int max; + int used; + int soft; +}; + +isc_result_t +isc_quota_init(isc_quota_t *quota, int max); +/*%< + * Initialize a quota object. + * + * Returns: + * ISC_R_SUCCESS + * Other error Lock creation failed. + */ + +void +isc_quota_destroy(isc_quota_t *quota); +/*%< + * Destroy a quota object. + */ + +void +isc_quota_soft(isc_quota_t *quota, int soft); +/*%< + * Set a soft quota. + */ + +void +isc_quota_max(isc_quota_t *quota, int max); +/*%< + * Re-set a maximum quota. + */ + +isc_result_t +isc_quota_reserve(isc_quota_t *quota); +/*%< + * Attempt to reserve one unit of 'quota'. + * + * Returns: + * \li #ISC_R_SUCCESS Success + * \li #ISC_R_SOFTQUOTA Success soft quota reached + * \li #ISC_R_QUOTA Quota is full + */ + +void +isc_quota_release(isc_quota_t *quota); +/*%< + * Release one unit of quota. + */ + +isc_result_t +isc_quota_attach(isc_quota_t *quota, isc_quota_t **p); +/*%< + * Like isc_quota_reserve, and also attaches '*p' to the + * quota if successful (ISC_R_SUCCESS or ISC_R_SOFTQUOTA). + */ + +void +isc_quota_detach(isc_quota_t **p); +/*%< + * Like isc_quota_release, and also detaches '*p' from the + * quota. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_QUOTA_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/radix.h src.ntp/contrib/ntp/lib/isc/include/isc/radix.h --- src/contrib/ntp/lib/isc/include/isc/radix.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/radix.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,240 @@ +/* + * Copyright (C) 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: radix.h,v 1.11.44.2 2008/12/24 23:47:02 tbox Exp $ */ + +/* + * This source was adapted from MRT's RCS Ids: + * Id: radix.h,v 1.6 1999/08/03 03:32:53 masaki Exp + * Id: mrt.h,v 1.57.2.6 1999/12/28 23:41:27 labovit Exp + * Id: defs.h,v 1.5.2.2 2000/01/15 14:19:16 masaki Exp + */ + +#include +#include +#include +#include +#include + +#include + +#ifndef _RADIX_H +#define _RADIX_H + +#define NETADDR_TO_PREFIX_T(na,pt,bits) \ + do { \ + memset(&(pt), 0, sizeof(pt)); \ + if((na) != NULL) { \ + (pt).family = (na)->family; \ + (pt).bitlen = (bits); \ + if ((pt).family == AF_INET6) { \ + memcpy(&(pt).add.sin6, &(na)->type.in6, \ + ((bits)+7)/8); \ + } else \ + memcpy(&(pt).add.sin, &(na)->type.in, \ + ((bits)+7)/8); \ + } else { \ + (pt).family = AF_UNSPEC; \ + (pt).bitlen = 0; \ + } \ + isc_refcount_init(&(pt).refcount, 0); \ + } while(0) + +typedef struct isc_prefix { + unsigned int family; /* AF_INET | AF_INET6, or AF_UNSPEC for "any" */ + unsigned int bitlen; /* 0 for "any" */ + isc_refcount_t refcount; + union { + struct in_addr sin; + struct in6_addr sin6; + } add; +} isc_prefix_t; + +typedef void (*isc_radix_destroyfunc_t)(void *); +typedef void (*isc_radix_processfunc_t)(isc_prefix_t *, void **); + +#define isc_prefix_tochar(prefix) ((char *)&(prefix)->add.sin) +#define isc_prefix_touchar(prefix) ((u_char *)&(prefix)->add.sin) + +#define BIT_TEST(f, b) ((f) & (b)) + +/* + * We need "first match" when we search the radix tree to preserve + * compatibility with the existing ACL implementation. Radix trees + * naturally lend themselves to "best match". In order to get "first match" + * behavior, we keep track of the order in which entries are added to the + * tree--and when a search is made, we find all matching entries, and + * return the one that was added first. + * + * An IPv4 prefix and an IPv6 prefix may share a radix tree node if they + * have the same length and bit pattern (e.g., 127/8 and 7f::/8). To + * disambiguate between them, node_num and data are two-element arrays; + * node_num[0] and data[0] are used for IPv4 addresses, node_num[1] + * and data[1] for IPv6 addresses. The only exception is a prefix of + * 0/0 (aka "any" or "none"), which is always stored as IPv4 but matches + * IPv6 addresses too. + */ + +#define ISC_IS6(family) ((family) == AF_INET6 ? 1 : 0) +typedef struct isc_radix_node { + isc_uint32_t bit; /* bit length of the prefix */ + isc_prefix_t *prefix; /* who we are in radix tree */ + struct isc_radix_node *l, *r; /* left and right children */ + struct isc_radix_node *parent; /* may be used */ + void *data[2]; /* pointers to IPv4 and IPV6 data */ + int node_num[2]; /* which node this was in the tree, + or -1 for glue nodes */ +} isc_radix_node_t; + +#define RADIX_TREE_MAGIC ISC_MAGIC('R','d','x','T'); +#define RADIX_TREE_VALID(a) ISC_MAGIC_VALID(a, RADIX_TREE_MAGIC); + +typedef struct isc_radix_tree { + unsigned int magic; + isc_mem_t *mctx; + isc_radix_node_t *head; + isc_uint32_t maxbits; /* for IP, 32 bit addresses */ + int num_active_node; /* for debugging purposes */ + int num_added_node; /* total number of nodes */ +} isc_radix_tree_t; + +isc_result_t +isc_radix_search(isc_radix_tree_t *radix, isc_radix_node_t **target, + isc_prefix_t *prefix); +/*%< + * Search 'radix' for the best match to 'prefix'. + * Return the node found in '*target'. + * + * Requires: + * \li 'radix' to be valid. + * \li 'target' is not NULL and "*target" is NULL. + * \li 'prefix' to be valid. + * + * Returns: + * \li ISC_R_NOTFOUND + * \li ISC_R_SUCCESS + */ + +isc_result_t +isc_radix_insert(isc_radix_tree_t *radix, isc_radix_node_t **target, + isc_radix_node_t *source, isc_prefix_t *prefix); +/*%< + * Insert 'source' or 'prefix' into the radix tree 'radix'. + * Return the node added in 'target'. + * + * Requires: + * \li 'radix' to be valid. + * \li 'target' is not NULL and "*target" is NULL. + * \li 'prefix' to be valid or 'source' to be non NULL and contain + * a valid prefix. + * + * Returns: + * \li ISC_R_NOMEMORY + * \li ISC_R_SUCCESS + */ + +void +isc_radix_remove(isc_radix_tree_t *radix, isc_radix_node_t *node); +/*%< + * Remove the node 'node' from the radix tree 'radix'. + * + * Requires: + * \li 'radix' to be valid. + * \li 'node' to be valid. + */ + +isc_result_t +isc_radix_create(isc_mem_t *mctx, isc_radix_tree_t **target, int maxbits); +/*%< + * Create a radix tree with a maximum depth of 'maxbits'; + * + * Requires: + * \li 'mctx' to be valid. + * \li 'target' to be non NULL and '*target' to be NULL. + * \li 'maxbits' to be less than or equal to RADIX_MAXBITS. + * + * Returns: + * \li ISC_R_NOMEMORY + * \li ISC_R_SUCCESS + */ + +void +isc_radix_destroy(isc_radix_tree_t *radix, isc_radix_destroyfunc_t func); +/*%< + * Destroy a radix tree optionally calling 'func' to clean up node data. + * + * Requires: + * \li 'radix' to be valid. + */ + +void +isc_radix_process(isc_radix_tree_t *radix, isc_radix_processfunc_t func); +/*%< + * Walk a radix tree calling 'func' to process node data. + * + * Requires: + * \li 'radix' to be valid. + * \li 'func' to point to a function. + */ + +#define RADIX_MAXBITS 128 +#define RADIX_NBIT(x) (0x80 >> ((x) & 0x7f)) +#define RADIX_NBYTE(x) ((x) >> 3) + +#define RADIX_DATA_GET(node, type) (type *)((node)->data) +#define RADIX_DATA_SET(node, value) ((node)->data = (void *)(value)) + +#define RADIX_WALK(Xhead, Xnode) \ + do { \ + isc_radix_node_t *Xstack[RADIX_MAXBITS+1]; \ + isc_radix_node_t **Xsp = Xstack; \ + isc_radix_node_t *Xrn = (Xhead); \ + while ((Xnode = Xrn)) { \ + if (Xnode->prefix) + +#define RADIX_WALK_ALL(Xhead, Xnode) \ +do { \ + isc_radix_node_t *Xstack[RADIX_MAXBITS+1]; \ + isc_radix_node_t **Xsp = Xstack; \ + isc_radix_node_t *Xrn = (Xhead); \ + while ((Xnode = Xrn)) { \ + if (1) + +#define RADIX_WALK_BREAK { \ + if (Xsp != Xstack) { \ + Xrn = *(--Xsp); \ + } else { \ + Xrn = (radix_node_t *) 0; \ + } \ + continue; } + +#define RADIX_WALK_END \ + if (Xrn->l) { \ + if (Xrn->r) { \ + *Xsp++ = Xrn->r; \ + } \ + Xrn = Xrn->l; \ + } else if (Xrn->r) { \ + Xrn = Xrn->r; \ + } else if (Xsp != Xstack) { \ + Xrn = *(--Xsp); \ + } else { \ + Xrn = (isc_radix_node_t *) 0; \ + } \ + } \ + } while (0) + +#endif /* _RADIX_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/random.h src.ntp/contrib/ntp/lib/isc/include/isc/random.h --- src/contrib/ntp/lib/isc/include/isc/random.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/random.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,62 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: random.h,v 1.18.332.2 2009/01/18 23:47:41 tbox Exp $ */ + +#ifndef ISC_RANDOM_H +#define ISC_RANDOM_H 1 + +#include +#include + +/*! \file isc/random.h + * \brief Implements a random state pool which will let the caller return a + * series of possibly non-reproducible random values. + * + * Note that the + * strength of these numbers is not all that high, and should not be + * used in cryptography functions. It is useful for jittering values + * a bit here and there, such as timeouts, etc. + */ + +ISC_LANG_BEGINDECLS + +void +isc_random_seed(isc_uint32_t seed); +/*%< + * Set the initial seed of the random state. + */ + +void +isc_random_get(isc_uint32_t *val); +/*%< + * Get a random value. + * + * Requires: + * val != NULL. + */ + +isc_uint32_t +isc_random_jitter(isc_uint32_t max, isc_uint32_t jitter); +/*%< + * Get a random value between (max - jitter) and (max). + * This is useful for jittering timer values. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_RANDOM_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/ratelimiter.h src.ntp/contrib/ntp/lib/isc/include/isc/ratelimiter.h --- src/contrib/ntp/lib/isc/include/isc/ratelimiter.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/ratelimiter.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,134 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: ratelimiter.h,v 1.21.332.2 2009/01/18 23:47:41 tbox Exp $ */ + +#ifndef ISC_RATELIMITER_H +#define ISC_RATELIMITER_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/ratelimiter.h + * \brief A rate limiter is a mechanism for dispatching events at a limited + * rate. This is intended to be used when sending zone maintenance + * SOA queries, NOTIFY messages, etc. + */ + +/*** + *** Imports. + ***/ + +#include +#include + +ISC_LANG_BEGINDECLS + +/***** + ***** Functions. + *****/ + +isc_result_t +isc_ratelimiter_create(isc_mem_t *mctx, isc_timermgr_t *timermgr, + isc_task_t *task, isc_ratelimiter_t **ratelimiterp); +/*%< + * Create a rate limiter. The execution interval is initially undefined. + */ + +isc_result_t +isc_ratelimiter_setinterval(isc_ratelimiter_t *rl, isc_interval_t *interval); +/*!< + * Set the minimum interval between event executions. + * The interval value is copied, so the caller need not preserve it. + * + * Requires: + * '*interval' is a nonzero interval. + */ + +void +isc_ratelimiter_setpertic(isc_ratelimiter_t *rl, isc_uint32_t perint); +/*%< + * Set the number of events processed per interval timer tick. + * If 'perint' is zero it is treated as 1. + */ + +isc_result_t +isc_ratelimiter_enqueue(isc_ratelimiter_t *rl, isc_task_t *task, + isc_event_t **eventp); +/*%< + * Queue an event for rate-limited execution. + * + * This is similar + * to doing an isc_task_send() to the 'task', except that the + * execution may be delayed to achieve the desired rate of + * execution. + * + * '(*eventp)->ev_sender' is used to hold the task. The caller + * must ensure that the task exists until the event is delivered. + * + * Requires: + *\li An interval has been set by calling + * isc_ratelimiter_setinterval(). + * + *\li 'task' to be non NULL. + *\li '(*eventp)->ev_sender' to be NULL. + */ + +void +isc_ratelimiter_shutdown(isc_ratelimiter_t *ratelimiter); +/*%< + * Shut down a rate limiter. + * + * Ensures: + *\li All events that have not yet been + * dispatched to the task are dispatched immediately with + * the #ISC_EVENTATTR_CANCELED bit set in ev_attributes. + * + *\li Further attempts to enqueue events will fail with + * #ISC_R_SHUTTINGDOWN. + * + *\li The rate limiter is no longer attached to its task. + */ + +void +isc_ratelimiter_attach(isc_ratelimiter_t *source, isc_ratelimiter_t **target); +/*%< + * Attach to a rate limiter. + */ + +void +isc_ratelimiter_detach(isc_ratelimiter_t **ratelimiterp); +/*%< + * Detach from a rate limiter. + */ + +isc_result_t +isc_ratelimiter_stall(isc_ratelimiter_t *rl); +/*%< + * Stall event processing. + */ + +isc_result_t +isc_ratelimiter_release(isc_ratelimiter_t *rl); +/*%< + * Release a stalled rate limiter. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_RATELIMITER_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/refcount.h src.ntp/contrib/ntp/lib/isc/include/isc/refcount.h --- src/contrib/ntp/lib/isc/include/isc/refcount.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/refcount.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,233 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: refcount.h,v 1.15 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_REFCOUNT_H +#define ISC_REFCOUNT_H 1 + +#include +#include +#include +#include +#include +#include + +/*! \file isc/refcount.h + * \brief Implements a locked reference counter. + * + * These functions may actually be + * implemented using macros, and implementations of these macros are below. + * The isc_refcount_t type should not be accessed directly, as its contents + * depend on the implementation. + */ + +ISC_LANG_BEGINDECLS + +/* + * Function prototypes + */ + +/* + * isc_result_t + * isc_refcount_init(isc_refcount_t *ref, unsigned int n); + * + * Initialize the reference counter. There will be 'n' initial references. + * + * Requires: + * ref != NULL + */ + +/* + * void + * isc_refcount_destroy(isc_refcount_t *ref); + * + * Destroys a reference counter. + * + * Requires: + * ref != NULL + * The number of references is 0. + */ + +/* + * void + * isc_refcount_increment(isc_refcount_t *ref, unsigned int *targetp); + * isc_refcount_increment0(isc_refcount_t *ref, unsigned int *targetp); + * + * Increments the reference count, returning the new value in targetp if it's + * not NULL. The reference counter typically begins with the initial counter + * of 1, and will be destroyed once the counter reaches 0. Thus, + * isc_refcount_increment() additionally requires the previous counter be + * larger than 0 so that an error which violates the usage can be easily + * caught. isc_refcount_increment0() does not have this restriction. + * + * Requires: + * ref != NULL. + */ + +/* + * void + * isc_refcount_decrement(isc_refcount_t *ref, unsigned int *targetp); + * + * Decrements the reference count, returning the new value in targetp if it's + * not NULL. + * + * Requires: + * ref != NULL. + */ + + +/* + * Sample implementations + */ +#ifdef ISC_PLATFORM_USETHREADS +#ifdef ISC_PLATFORM_HAVEXADD + +#define ISC_REFCOUNT_HAVEATOMIC 1 + +typedef struct isc_refcount { + isc_int32_t refs; +} isc_refcount_t; + +#define isc_refcount_destroy(rp) (REQUIRE((rp)->refs == 0)) +#define isc_refcount_current(rp) ((unsigned int)((rp)->refs)) + +#define isc_refcount_increment0(rp, tp) \ + do { \ + unsigned int *_tmp = (unsigned int *)(tp); \ + isc_int32_t prev; \ + prev = isc_atomic_xadd(&(rp)->refs, 1); \ + if (_tmp != NULL) \ + *_tmp = prev + 1; \ + } while (0) + +#define isc_refcount_increment(rp, tp) \ + do { \ + unsigned int *_tmp = (unsigned int *)(tp); \ + isc_int32_t prev; \ + prev = isc_atomic_xadd(&(rp)->refs, 1); \ + REQUIRE(prev > 0); \ + if (_tmp != NULL) \ + *_tmp = prev + 1; \ + } while (0) + +#define isc_refcount_decrement(rp, tp) \ + do { \ + unsigned int *_tmp = (unsigned int *)(tp); \ + isc_int32_t prev; \ + prev = isc_atomic_xadd(&(rp)->refs, -1); \ + REQUIRE(prev > 0); \ + if (_tmp != NULL) \ + *_tmp = prev - 1; \ + } while (0) + +#else /* ISC_PLATFORM_HAVEXADD */ + +typedef struct isc_refcount { + int refs; + isc_mutex_t lock; +} isc_refcount_t; + +/*% Destroys a reference counter. */ +#define isc_refcount_destroy(rp) \ + do { \ + REQUIRE((rp)->refs == 0); \ + DESTROYLOCK(&(rp)->lock); \ + } while (0) + +#define isc_refcount_current(rp) ((unsigned int)((rp)->refs)) + +/*% Increments the reference count, returning the new value in targetp if it's not NULL. */ +#define isc_refcount_increment0(rp, tp) \ + do { \ + unsigned int *_tmp = (unsigned int *)(tp); \ + LOCK(&(rp)->lock); \ + ++((rp)->refs); \ + if (_tmp != NULL) \ + *_tmp = ((rp)->refs); \ + UNLOCK(&(rp)->lock); \ + } while (0) + +#define isc_refcount_increment(rp, tp) \ + do { \ + unsigned int *_tmp = (unsigned int *)(tp); \ + LOCK(&(rp)->lock); \ + REQUIRE((rp)->refs > 0); \ + ++((rp)->refs); \ + if (_tmp != NULL) \ + *_tmp = ((rp)->refs); \ + UNLOCK(&(rp)->lock); \ + } while (0) + +/*% Decrements the reference count, returning the new value in targetp if it's not NULL. */ +#define isc_refcount_decrement(rp, tp) \ + do { \ + unsigned int *_tmp = (unsigned int *)(tp); \ + LOCK(&(rp)->lock); \ + REQUIRE((rp)->refs > 0); \ + --((rp)->refs); \ + if (_tmp != NULL) \ + *_tmp = ((rp)->refs); \ + UNLOCK(&(rp)->lock); \ + } while (0) + +#endif /* ISC_PLATFORM_HAVEXADD */ +#else /* ISC_PLATFORM_USETHREADS */ + +typedef struct isc_refcount { + int refs; +} isc_refcount_t; + +#define isc_refcount_destroy(rp) (REQUIRE((rp)->refs == 0)) +#define isc_refcount_current(rp) ((unsigned int)((rp)->refs)) + +#define isc_refcount_increment0(rp, tp) \ + do { \ + unsigned int *_tmp = (unsigned int *)(tp); \ + int _n = ++(rp)->refs; \ + if (_tmp != NULL) \ + *_tmp = _n; \ + } while (0) + +#define isc_refcount_increment(rp, tp) \ + do { \ + unsigned int *_tmp = (unsigned int *)(tp); \ + int _n; \ + REQUIRE((rp)->refs > 0); \ + _n = ++(rp)->refs; \ + if (_tmp != NULL) \ + *_tmp = _n; \ + } while (0) + +#define isc_refcount_decrement(rp, tp) \ + do { \ + unsigned int *_tmp = (unsigned int *)(tp); \ + int _n; \ + REQUIRE((rp)->refs > 0); \ + _n = --(rp)->refs; \ + if (_tmp != NULL) \ + *_tmp = _n; \ + } while (0) + +#endif /* ISC_PLATFORM_USETHREADS */ + +isc_result_t +isc_refcount_init(isc_refcount_t *ref, unsigned int n); + +ISC_LANG_ENDDECLS + +#endif /* ISC_REFCOUNT_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/region.h src.ntp/contrib/ntp/lib/isc/include/isc/region.h --- src/contrib/ntp/lib/isc/include/isc/region.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/region.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,99 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: region.h,v 1.25 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_REGION_H +#define ISC_REGION_H 1 + +/*! \file isc/region.h */ + +#include + +struct isc_region { + unsigned char * base; + unsigned int length; +}; + +struct isc_textregion { + char * base; + unsigned int length; +}; + +/* XXXDCL questionable ... bears discussion. we have been putting off + * discussing the region api. + */ +struct isc_constregion { + const void * base; + unsigned int length; +}; + +struct isc_consttextregion { + const char * base; + unsigned int length; +}; + +/*@{*/ +/*! + * The region structure is not opaque, and is usually directly manipulated. + * Some macros are defined below for convenience. + */ + +#define isc_region_consume(r,l) \ + do { \ + isc_region_t *_r = (r); \ + unsigned int _l = (l); \ + INSIST(_r->length >= _l); \ + _r->base += _l; \ + _r->length -= _l; \ + } while (0) + +#define isc_textregion_consume(r,l) \ + do { \ + isc_textregion_t *_r = (r); \ + unsigned int _l = (l); \ + INSIST(_r->length >= _l); \ + _r->base += _l; \ + _r->length -= _l; \ + } while (0) + +#define isc_constregion_consume(r,l) \ + do { \ + isc_constregion_t *_r = (r); \ + unsigned int _l = (l); \ + INSIST(_r->length >= _l); \ + _r->base += _l; \ + _r->length -= _l; \ + } while (0) +/*@}*/ + +int +isc_region_compare(isc_region_t *r1, isc_region_t *r2); +/*%< + * Compares the contents of two regions + * + * Requires: + *\li 'r1' is a valid region + *\li 'r2' is a valid region + * + * Returns: + *\li < 0 if r1 is lexicographically less than r2 + *\li = 0 if r1 is lexicographically identical to r2 + *\li > 0 if r1 is lexicographically greater than r2 + */ + +#endif /* ISC_REGION_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/resource.h src.ntp/contrib/ntp/lib/isc/include/isc/resource.h --- src/contrib/ntp/lib/isc/include/isc/resource.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/resource.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,97 @@ +/* + * Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: resource.h,v 1.13 2008/07/11 23:47:09 tbox Exp $ */ + +#ifndef ISC_RESOURCE_H +#define ISC_RESOURCE_H 1 + +/*! \file isc/resource.h */ + +#include +#include + +#define ISC_RESOURCE_UNLIMITED ((isc_resourcevalue_t)ISC_UINT64_MAX) + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_resource_setlimit(isc_resource_t resource, isc_resourcevalue_t value); +/*%< + * Set the maximum limit for a system resource. + * + * Notes: + *\li If 'value' exceeds the maximum possible on the operating system, + * it is silently limited to that maximum -- or to "infinity", if + * the operating system has that concept. #ISC_RESOURCE_UNLIMITED + * can be used to explicitly ask for the maximum. + * + * Requires: + *\li 'resource' is a valid member of the isc_resource_t enumeration. + * + * Returns: + *\li #ISC_R_SUCCESS Success. + *\li #ISC_R_NOTIMPLEMENTED 'resource' is not a type known by the OS. + *\li #ISC_R_NOPERM The calling process did not have adequate permission + * to change the resource limit. + */ + +isc_result_t +isc_resource_getlimit(isc_resource_t resource, isc_resourcevalue_t *value); +/*%< + * Get the maximum limit for a system resource. + * + * Notes: + *\li 'value' is set to the maximum limit. + * + *\li #ISC_RESOURCE_UNLIMITED is the maximum value of isc_resourcevalue_t. + * + *\li On many (all?) Unix systems, RLIM_INFINITY is a valid value that is + * significantly less than #ISC_RESOURCE_UNLIMITED, but which in practice + * behaves the same. + * + *\li The current ISC libdns configuration file parser assigns a value + * of ISC_UINT32_MAX for a size_spec of "unlimited" and ISC_UNIT32_MAX - 1 + * for "default", the latter of which is supposed to represent "the + * limit that was in force when the server started". Since these are + * valid values in the middle of the range of isc_resourcevalue_t, + * there is the possibility for confusion over what exactly those + * particular values are supposed to represent in a particular context -- + * discrete integral values or generalized concepts. + * + * Requires: + *\li 'resource' is a valid member of the isc_resource_t enumeration. + * + * Returns: + *\li #ISC_R_SUCCESS Success. + *\li #ISC_R_NOTIMPLEMENTED 'resource' is not a type known by the OS. + */ + +isc_result_t +isc_resource_getcurlimit(isc_resource_t resource, isc_resourcevalue_t *value); +/*%< + * Same as isc_resource_getlimit(), but returns the current (soft) limit. + * + * Returns: + *\li #ISC_R_SUCCESS Success. + *\li #ISC_R_NOTIMPLEMENTED 'resource' is not a type known by the OS. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_RESOURCE_H */ + diff -urN src/contrib/ntp/lib/isc/include/isc/result.h src.ntp/contrib/ntp/lib/isc/include/isc/result.h --- src/contrib/ntp/lib/isc/include/isc/result.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/result.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,107 @@ +/* + * Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: result.h,v 1.71 2008/09/25 04:02:39 tbox Exp $ */ + +#ifndef ISC_RESULT_H +#define ISC_RESULT_H 1 + +/*! \file isc/result.h */ + +#include +#include + +#define ISC_R_SUCCESS 0 /*%< success */ +#define ISC_R_NOMEMORY 1 /*%< out of memory */ +#define ISC_R_TIMEDOUT 2 /*%< timed out */ +#define ISC_R_NOTHREADS 3 /*%< no available threads */ +#define ISC_R_ADDRNOTAVAIL 4 /*%< address not available */ +#define ISC_R_ADDRINUSE 5 /*%< address in use */ +#define ISC_R_NOPERM 6 /*%< permission denied */ +#define ISC_R_NOCONN 7 /*%< no pending connections */ +#define ISC_R_NETUNREACH 8 /*%< network unreachable */ +#define ISC_R_HOSTUNREACH 9 /*%< host unreachable */ +#define ISC_R_NETDOWN 10 /*%< network down */ +#define ISC_R_HOSTDOWN 11 /*%< host down */ +#define ISC_R_CONNREFUSED 12 /*%< connection refused */ +#define ISC_R_NORESOURCES 13 /*%< not enough free resources */ +#define ISC_R_EOF 14 /*%< end of file */ +#define ISC_R_BOUND 15 /*%< socket already bound */ +#define ISC_R_RELOAD 16 /*%< reload */ +#define ISC_R_LOCKBUSY 17 /*%< lock busy */ +#define ISC_R_EXISTS 18 /*%< already exists */ +#define ISC_R_NOSPACE 19 /*%< ran out of space */ +#define ISC_R_CANCELED 20 /*%< operation canceled */ +#define ISC_R_NOTBOUND 21 /*%< socket is not bound */ +#define ISC_R_SHUTTINGDOWN 22 /*%< shutting down */ +#define ISC_R_NOTFOUND 23 /*%< not found */ +#define ISC_R_UNEXPECTEDEND 24 /*%< unexpected end of input */ +#define ISC_R_FAILURE 25 /*%< generic failure */ +#define ISC_R_IOERROR 26 /*%< I/O error */ +#define ISC_R_NOTIMPLEMENTED 27 /*%< not implemented */ +#define ISC_R_UNBALANCED 28 /*%< unbalanced parentheses */ +#define ISC_R_NOMORE 29 /*%< no more */ +#define ISC_R_INVALIDFILE 30 /*%< invalid file */ +#define ISC_R_BADBASE64 31 /*%< bad base64 encoding */ +#define ISC_R_UNEXPECTEDTOKEN 32 /*%< unexpected token */ +#define ISC_R_QUOTA 33 /*%< quota reached */ +#define ISC_R_UNEXPECTED 34 /*%< unexpected error */ +#define ISC_R_ALREADYRUNNING 35 /*%< already running */ +#define ISC_R_IGNORE 36 /*%< ignore */ +#define ISC_R_MASKNONCONTIG 37 /*%< addr mask not contiguous */ +#define ISC_R_FILENOTFOUND 38 /*%< file not found */ +#define ISC_R_FILEEXISTS 39 /*%< file already exists */ +#define ISC_R_NOTCONNECTED 40 /*%< socket is not connected */ +#define ISC_R_RANGE 41 /*%< out of range */ +#define ISC_R_NOENTROPY 42 /*%< out of entropy */ +#define ISC_R_MULTICAST 43 /*%< invalid use of multicast */ +#define ISC_R_NOTFILE 44 /*%< not a file */ +#define ISC_R_NOTDIRECTORY 45 /*%< not a directory */ +#define ISC_R_QUEUEFULL 46 /*%< queue is full */ +#define ISC_R_FAMILYMISMATCH 47 /*%< address family mismatch */ +#define ISC_R_FAMILYNOSUPPORT 48 /*%< AF not supported */ +#define ISC_R_BADHEX 49 /*%< bad hex encoding */ +#define ISC_R_TOOMANYOPENFILES 50 /*%< too many open files */ +#define ISC_R_NOTBLOCKING 51 /*%< not blocking */ +#define ISC_R_UNBALANCEDQUOTES 52 /*%< unbalanced quotes */ +#define ISC_R_INPROGRESS 53 /*%< operation in progress */ +#define ISC_R_CONNECTIONRESET 54 /*%< connection reset */ +#define ISC_R_SOFTQUOTA 55 /*%< soft quota reached */ +#define ISC_R_BADNUMBER 56 /*%< not a valid number */ +#define ISC_R_DISABLED 57 /*%< disabled */ +#define ISC_R_MAXSIZE 58 /*%< max size */ +#define ISC_R_BADADDRESSFORM 59 /*%< invalid address format */ +#define ISC_R_BADBASE32 60 /*%< bad base32 encoding */ + +/*% Not a result code: the number of results. */ +#define ISC_R_NRESULTS 61 + +ISC_LANG_BEGINDECLS + +const char * +isc_result_totext(isc_result_t); +/*%< + * Convert an isc_result_t into a string message describing the result. + */ + +isc_result_t +isc_result_register(unsigned int base, unsigned int nresults, + const char **text, isc_msgcat_t *msgcat, int set); + +ISC_LANG_ENDDECLS + +#endif /* ISC_RESULT_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/resultclass.h src.ntp/contrib/ntp/lib/isc/include/isc/resultclass.h --- src/contrib/ntp/lib/isc/include/isc/resultclass.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/resultclass.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,50 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: resultclass.h,v 1.18 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_RESULTCLASS_H +#define ISC_RESULTCLASS_H 1 + + +/*! \file isc/resultclass.h + * \brief Registry of Predefined Result Type Classes + * + * A result class number is an unsigned 16 bit number. Each class may + * contain up to 65536 results. A result code is formed by adding the + * result number within the class to the class number multiplied by 65536. + * + * Classes < 1024 are reserved for ISC use. + * Result classes >= 1024 and <= 65535 are reserved for application use. + */ + +#define ISC_RESULTCLASS_FROMNUM(num) ((num) << 16) +#define ISC_RESULTCLASS_TONUM(rclass) ((rclass) >> 16) +#define ISC_RESULTCLASS_SIZE 65536 +#define ISC_RESULTCLASS_INCLASS(rclass, result) \ + ((rclass) == ((result) & 0xFFFF0000)) + + +#define ISC_RESULTCLASS_ISC ISC_RESULTCLASS_FROMNUM(0) +#define ISC_RESULTCLASS_DNS ISC_RESULTCLASS_FROMNUM(1) +#define ISC_RESULTCLASS_DST ISC_RESULTCLASS_FROMNUM(2) +#define ISC_RESULTCLASS_DNSRCODE ISC_RESULTCLASS_FROMNUM(3) +#define ISC_RESULTCLASS_OMAPI ISC_RESULTCLASS_FROMNUM(4) +#define ISC_RESULTCLASS_ISCCC ISC_RESULTCLASS_FROMNUM(5) + + +#endif /* ISC_RESULTCLASS_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/rwlock.h src.ntp/contrib/ntp/lib/isc/include/isc/rwlock.h --- src/contrib/ntp/lib/isc/include/isc/rwlock.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/rwlock.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,135 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: rwlock.h,v 1.28 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_RWLOCK_H +#define ISC_RWLOCK_H 1 + +/*! \file isc/rwlock.h */ + +#include +#include +#include +#include + +ISC_LANG_BEGINDECLS + +typedef enum { + isc_rwlocktype_none = 0, + isc_rwlocktype_read, + isc_rwlocktype_write +} isc_rwlocktype_t; + +#ifdef ISC_PLATFORM_USETHREADS +#if defined(ISC_PLATFORM_HAVEXADD) && defined(ISC_PLATFORM_HAVECMPXCHG) +#define ISC_RWLOCK_USEATOMIC 1 +#endif + +struct isc_rwlock { + /* Unlocked. */ + unsigned int magic; + isc_mutex_t lock; + +#if defined(ISC_PLATFORM_HAVEXADD) && defined(ISC_PLATFORM_HAVECMPXCHG) + /* + * When some atomic instructions with hardware assistance are + * available, rwlock will use those so that concurrent readers do not + * interfere with each other through mutex as long as no writers + * appear, massively reducing the lock overhead in the typical case. + * + * The basic algorithm of this approach is the "simple + * writer-preference lock" shown in the following URL: + * http://www.cs.rochester.edu/u/scott/synchronization/pseudocode/rw.html + * but our implementation does not rely on the spin lock unlike the + * original algorithm to be more portable as a user space application. + */ + + /* Read or modified atomically. */ + isc_int32_t write_requests; + isc_int32_t write_completions; + isc_int32_t cnt_and_flag; + + /* Locked by lock. */ + isc_condition_t readable; + isc_condition_t writeable; + unsigned int readers_waiting; + + /* Locked by rwlock itself. */ + unsigned int write_granted; + + /* Unlocked. */ + unsigned int write_quota; + +#else /* ISC_PLATFORM_HAVEXADD && ISC_PLATFORM_HAVECMPXCHG */ + + /*%< Locked by lock. */ + isc_condition_t readable; + isc_condition_t writeable; + isc_rwlocktype_t type; + + /*% The number of threads that have the lock. */ + unsigned int active; + + /*% + * The number of lock grants made since the lock was last switched + * from reading to writing or vice versa; used in determining + * when the quota is reached and it is time to switch. + */ + unsigned int granted; + + unsigned int readers_waiting; + unsigned int writers_waiting; + unsigned int read_quota; + unsigned int write_quota; + isc_rwlocktype_t original; +#endif /* ISC_PLATFORM_HAVEXADD && ISC_PLATFORM_HAVECMPXCHG */ +}; +#else /* ISC_PLATFORM_USETHREADS */ +struct isc_rwlock { + unsigned int magic; + isc_rwlocktype_t type; + unsigned int active; +}; +#endif /* ISC_PLATFORM_USETHREADS */ + + +isc_result_t +isc_rwlock_init(isc_rwlock_t *rwl, unsigned int read_quota, + unsigned int write_quota); + +isc_result_t +isc_rwlock_lock(isc_rwlock_t *rwl, isc_rwlocktype_t type); + +isc_result_t +isc_rwlock_trylock(isc_rwlock_t *rwl, isc_rwlocktype_t type); + +isc_result_t +isc_rwlock_unlock(isc_rwlock_t *rwl, isc_rwlocktype_t type); + +isc_result_t +isc_rwlock_tryupgrade(isc_rwlock_t *rwl); + +void +isc_rwlock_downgrade(isc_rwlock_t *rwl); + +void +isc_rwlock_destroy(isc_rwlock_t *rwl); + +ISC_LANG_ENDDECLS + +#endif /* ISC_RWLOCK_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/serial.h src.ntp/contrib/ntp/lib/isc/include/isc/serial.h --- src/contrib/ntp/lib/isc/include/isc/serial.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/serial.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,75 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: serial.h,v 1.16.332.2 2009/01/18 23:47:41 tbox Exp $ */ + +#ifndef ISC_SERIAL_H +#define ISC_SERIAL_H 1 + +#include +#include + +/*! \file isc/serial.h + * \brief Implement 32 bit serial space arithmetic comparison functions. + * Note: Undefined results are returned as ISC_FALSE. + */ + +/*** + *** Functions + ***/ + +ISC_LANG_BEGINDECLS + +isc_boolean_t +isc_serial_lt(isc_uint32_t a, isc_uint32_t b); +/*%< + * Return true if 'a' < 'b' otherwise false. + */ + +isc_boolean_t +isc_serial_gt(isc_uint32_t a, isc_uint32_t b); +/*%< + * Return true if 'a' > 'b' otherwise false. + */ + +isc_boolean_t +isc_serial_le(isc_uint32_t a, isc_uint32_t b); +/*%< + * Return true if 'a' <= 'b' otherwise false. + */ + +isc_boolean_t +isc_serial_ge(isc_uint32_t a, isc_uint32_t b); +/*%< + * Return true if 'a' >= 'b' otherwise false. + */ + +isc_boolean_t +isc_serial_eq(isc_uint32_t a, isc_uint32_t b); +/*%< + * Return true if 'a' == 'b' otherwise false. + */ + +isc_boolean_t +isc_serial_ne(isc_uint32_t a, isc_uint32_t b); +/*%< + * Return true if 'a' != 'b' otherwise false. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_SERIAL_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/sha1.h src.ntp/contrib/ntp/lib/isc/include/isc/sha1.h --- src/contrib/ntp/lib/isc/include/isc/sha1.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/sha1.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,59 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +#ifndef ISC_SHA1_H +#define ISC_SHA1_H 1 + +/* $Id: sha1.h,v 1.17 2007/06/19 23:47:18 tbox Exp $ */ + +/* $NetBSD: sha1.h,v 1.2 1998/05/29 22:55:44 thorpej Exp $ */ + +/*! \file isc/sha1.h + * \brief SHA-1 in C + * \author By Steve Reid + * \note 100% Public Domain + */ + +#include +#include + +#define ISC_SHA1_DIGESTLENGTH 20U +#define ISC_SHA1_BLOCK_LENGTH 64U + +typedef struct { + isc_uint32_t state[5]; + isc_uint32_t count[2]; + unsigned char buffer[ISC_SHA1_BLOCK_LENGTH]; +} isc_sha1_t; + +ISC_LANG_BEGINDECLS + +void +isc_sha1_init(isc_sha1_t *ctx); + +void +isc_sha1_invalidate(isc_sha1_t *ctx); + +void +isc_sha1_update(isc_sha1_t *ctx, const unsigned char *data, unsigned int len); + +void +isc_sha1_final(isc_sha1_t *ctx, unsigned char *digest); + +ISC_LANG_ENDDECLS + +#endif /* ISC_SHA1_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/sha2.h src.ntp/contrib/ntp/lib/isc/include/isc/sha2.h --- src/contrib/ntp/lib/isc/include/isc/sha2.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/sha2.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,132 @@ +/* + * Copyright (C) 2005-2007 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: sha2.h,v 1.9 2007/06/19 23:47:18 tbox Exp $ */ + +/* $FreeBSD: src/sys/crypto/sha2/sha2.h,v 1.1.2.1 2001/07/03 11:01:36 ume Exp $ */ +/* $KAME: sha2.h,v 1.3 2001/03/12 08:27:48 itojun Exp $ */ + +/* + * sha2.h + * + * Version 1.0.0beta1 + * + * Written by Aaron D. Gifford + * + * Copyright 2000 Aaron D. Gifford. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the copyright holder nor the names of contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) AND CONTRIBUTOR(S) ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR(S) OR CONTRIBUTOR(S) BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + */ + +#ifndef ISC_SHA2_H +#define ISC_SHA2_H + +#include +#include + +/*** SHA-224/256/384/512 Various Length Definitions ***********************/ + +#define ISC_SHA224_BLOCK_LENGTH 64U +#define ISC_SHA224_DIGESTLENGTH 28U +#define ISC_SHA224_DIGESTSTRINGLENGTH (ISC_SHA224_DIGESTLENGTH * 2 + 1) +#define ISC_SHA256_BLOCK_LENGTH 64U +#define ISC_SHA256_DIGESTLENGTH 32U +#define ISC_SHA256_DIGESTSTRINGLENGTH (ISC_SHA256_DIGESTLENGTH * 2 + 1) +#define ISC_SHA384_BLOCK_LENGTH 128 +#define ISC_SHA384_DIGESTLENGTH 48U +#define ISC_SHA384_DIGESTSTRINGLENGTH (ISC_SHA384_DIGESTLENGTH * 2 + 1) +#define ISC_SHA512_BLOCK_LENGTH 128U +#define ISC_SHA512_DIGESTLENGTH 64U +#define ISC_SHA512_DIGESTSTRINGLENGTH (ISC_SHA512_DIGESTLENGTH * 2 + 1) + + +ISC_LANG_BEGINDECLS + +/*** SHA-256/384/512 Context Structures *******************************/ + +/* + * Keep buffer immediately after bitcount to preserve alignment. + */ +typedef struct { + isc_uint32_t state[8]; + isc_uint64_t bitcount; + isc_uint8_t buffer[ISC_SHA256_BLOCK_LENGTH]; +} isc_sha256_t; + +/* + * Keep buffer immediately after bitcount to preserve alignment. + */ +typedef struct { + isc_uint64_t state[8]; + isc_uint64_t bitcount[2]; + isc_uint8_t buffer[ISC_SHA512_BLOCK_LENGTH]; +} isc_sha512_t; + +typedef isc_sha256_t isc_sha224_t; +typedef isc_sha512_t isc_sha384_t; + +/*** SHA-224/256/384/512 Function Prototypes ******************************/ + +void isc_sha224_init (isc_sha224_t *); +void isc_sha224_update (isc_sha224_t *, const isc_uint8_t *, size_t); +void isc_sha224_final (isc_uint8_t[ISC_SHA224_DIGESTLENGTH], isc_sha224_t *); +char *isc_sha224_end (isc_sha224_t *, char[ISC_SHA224_DIGESTSTRINGLENGTH]); +char *isc_sha224_data (const isc_uint8_t *, size_t, char[ISC_SHA224_DIGESTSTRINGLENGTH]); + +void isc_sha256_init (isc_sha256_t *); +void isc_sha256_update (isc_sha256_t *, const isc_uint8_t *, size_t); +void isc_sha256_final (isc_uint8_t[ISC_SHA256_DIGESTLENGTH], isc_sha256_t *); +char *isc_sha256_end (isc_sha256_t *, char[ISC_SHA256_DIGESTSTRINGLENGTH]); +char *isc_sha256_data (const isc_uint8_t *, size_t, char[ISC_SHA256_DIGESTSTRINGLENGTH]); + +void isc_sha384_init (isc_sha384_t *); +void isc_sha384_update (isc_sha384_t *, const isc_uint8_t *, size_t); +void isc_sha384_final (isc_uint8_t[ISC_SHA384_DIGESTLENGTH], isc_sha384_t *); +char *isc_sha384_end (isc_sha384_t *, char[ISC_SHA384_DIGESTSTRINGLENGTH]); +char *isc_sha384_data (const isc_uint8_t *, size_t, char[ISC_SHA384_DIGESTSTRINGLENGTH]); + +void isc_sha512_init (isc_sha512_t *); +void isc_sha512_update (isc_sha512_t *, const isc_uint8_t *, size_t); +void isc_sha512_final (isc_uint8_t[ISC_SHA512_DIGESTLENGTH], isc_sha512_t *); +char *isc_sha512_end (isc_sha512_t *, char[ISC_SHA512_DIGESTSTRINGLENGTH]); +char *isc_sha512_data (const isc_uint8_t *, size_t, char[ISC_SHA512_DIGESTSTRINGLENGTH]); + +ISC_LANG_ENDDECLS + +#endif /* ISC_SHA2_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/sockaddr.h src.ntp/contrib/ntp/lib/isc/include/isc/sockaddr.h --- src/contrib/ntp/lib/isc/include/isc/sockaddr.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/sockaddr.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,241 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: sockaddr.h,v 1.55.332.2 2009/01/18 23:47:41 tbox Exp $ */ + +#ifndef ISC_SOCKADDR_H +#define ISC_SOCKADDR_H 1 + +/*! \file isc/sockaddr.h */ + +#include +#include +#include +#ifdef ISC_PLATFORM_HAVESYSUNH +#include +#endif + +struct isc_sockaddr { + union { + struct sockaddr sa; + struct sockaddr_in sin; + struct sockaddr_in6 sin6; +#ifdef ISC_PLATFORM_HAVESYSUNH + struct sockaddr_un sunix; +#endif + } type; + unsigned int length; /* XXXRTH beginning? */ + ISC_LINK(struct isc_sockaddr) link; +}; + +typedef ISC_LIST(struct isc_sockaddr) isc_sockaddrlist_t; + +#define ISC_SOCKADDR_CMPADDR 0x0001 /*%< compare the address + * sin_addr/sin6_addr */ +#define ISC_SOCKADDR_CMPPORT 0x0002 /*%< compare the port + * sin_port/sin6_port */ +#define ISC_SOCKADDR_CMPSCOPE 0x0004 /*%< compare the scope + * sin6_scope */ +#define ISC_SOCKADDR_CMPSCOPEZERO 0x0008 /*%< when comparing scopes + * zero scopes always match */ + +ISC_LANG_BEGINDECLS + +isc_boolean_t +isc_sockaddr_compare(const isc_sockaddr_t *a, const isc_sockaddr_t *b, + unsigned int flags); +/*%< + * Compare the elements of the two address ('a' and 'b') as specified + * by 'flags' and report if they are equal or not. + * + * 'flags' is set from ISC_SOCKADDR_CMP*. + */ + +isc_boolean_t +isc_sockaddr_equal(const isc_sockaddr_t *a, const isc_sockaddr_t *b); +/*%< + * Return ISC_TRUE iff the socket addresses 'a' and 'b' are equal. + */ + +isc_boolean_t +isc_sockaddr_eqaddr(const isc_sockaddr_t *a, const isc_sockaddr_t *b); +/*%< + * Return ISC_TRUE iff the address parts of the socket addresses + * 'a' and 'b' are equal, ignoring the ports. + */ + +isc_boolean_t +isc_sockaddr_eqaddrprefix(const isc_sockaddr_t *a, const isc_sockaddr_t *b, + unsigned int prefixlen); +/*%< + * Return ISC_TRUE iff the most significant 'prefixlen' bits of the + * socket addresses 'a' and 'b' are equal, ignoring the ports. + * If 'b''s scope is zero then 'a''s scope will be ignored. + */ + +unsigned int +isc_sockaddr_hash(const isc_sockaddr_t *sockaddr, isc_boolean_t address_only); +/*%< + * Return a hash value for the socket address 'sockaddr'. If 'address_only' + * is ISC_TRUE, the hash value will not depend on the port. + * + * IPv6 addresses containing mapped IPv4 addresses generate the same hash + * value as the equivalent IPv4 address. + */ + +void +isc_sockaddr_any(isc_sockaddr_t *sockaddr); +/*%< + * Return the IPv4 wildcard address. + */ + +void +isc_sockaddr_any6(isc_sockaddr_t *sockaddr); +/*%< + * Return the IPv6 wildcard address. + */ + +void +isc_sockaddr_anyofpf(isc_sockaddr_t *sockaddr, int family); +/*%< + * Set '*sockaddr' to the wildcard address of protocol family + * 'family'. + * + * Requires: + * \li 'family' is AF_INET or AF_INET6. + */ + +void +isc_sockaddr_fromin(isc_sockaddr_t *sockaddr, const struct in_addr *ina, + in_port_t port); +/*%< + * Construct an isc_sockaddr_t from an IPv4 address and port. + */ + +void +isc_sockaddr_fromin6(isc_sockaddr_t *sockaddr, const struct in6_addr *ina6, + in_port_t port); +/*%< + * Construct an isc_sockaddr_t from an IPv6 address and port. + */ + +void +isc_sockaddr_v6fromin(isc_sockaddr_t *sockaddr, const struct in_addr *ina, + in_port_t port); +/*%< + * Construct an IPv6 isc_sockaddr_t representing a mapped IPv4 address. + */ + +void +isc_sockaddr_fromnetaddr(isc_sockaddr_t *sockaddr, const isc_netaddr_t *na, + in_port_t port); +/*%< + * Construct an isc_sockaddr_t from an isc_netaddr_t and port. + */ + +int +isc_sockaddr_pf(const isc_sockaddr_t *sockaddr); +/*%< + * Get the protocol family of 'sockaddr'. + * + * Requires: + * + *\li 'sockaddr' is a valid sockaddr with an address family of AF_INET + * or AF_INET6. + * + * Returns: + * + *\li The protocol family of 'sockaddr', e.g. PF_INET or PF_INET6. + */ + +void +isc_sockaddr_setport(isc_sockaddr_t *sockaddr, in_port_t port); +/*%< + * Set the port of 'sockaddr' to 'port'. + */ + +in_port_t +isc_sockaddr_getport(const isc_sockaddr_t *sockaddr); +/*%< + * Get the port stored in 'sockaddr'. + */ + +isc_result_t +isc_sockaddr_totext(const isc_sockaddr_t *sockaddr, isc_buffer_t *target); +/*%< + * Append a text representation of 'sockaddr' to the buffer 'target'. + * The text will include both the IP address (v4 or v6) and the port. + * The text is null terminated, but the terminating null is not + * part of the buffer's used region. + * + * Returns: + * \li ISC_R_SUCCESS + * \li ISC_R_NOSPACE The text or the null termination did not fit. + */ + +void +isc_sockaddr_format(const isc_sockaddr_t *sa, char *array, unsigned int size); +/*%< + * Format a human-readable representation of the socket address '*sa' + * into the character array 'array', which is of size 'size'. + * The resulting string is guaranteed to be null-terminated. + */ + +isc_boolean_t +isc_sockaddr_ismulticast(const isc_sockaddr_t *sa); +/*%< + * Returns #ISC_TRUE if the address is a multicast address. + */ + +isc_boolean_t +isc_sockaddr_isexperimental(const isc_sockaddr_t *sa); +/* + * Returns ISC_TRUE if the address is a experimental (CLASS E) address. + */ + +isc_boolean_t +isc_sockaddr_islinklocal(const isc_sockaddr_t *sa); +/*%< + * Returns ISC_TRUE if the address is a link local address. + */ + +isc_boolean_t +isc_sockaddr_issitelocal(const isc_sockaddr_t *sa); +/*%< + * Returns ISC_TRUE if the address is a sitelocal address. + */ + +isc_result_t +isc_sockaddr_frompath(isc_sockaddr_t *sockaddr, const char *path); +/* + * Create a UNIX domain sockaddr that refers to path. + * + * Returns: + * \li ISC_R_NOSPACE + * \li ISC_R_NOTIMPLEMENTED + * \li ISC_R_SUCCESS + */ + +#define ISC_SOCKADDR_FORMATSIZE \ + sizeof("xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:XXX.XXX.XXX.XXX%SSSSSSSSSS#YYYYY") +/*%< + * Minimum size of array to pass to isc_sockaddr_format(). + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_SOCKADDR_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/socket.h src.ntp/contrib/ntp/lib/isc/include/isc/socket.h --- src/contrib/ntp/lib/isc/include/isc/socket.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/socket.h 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,1007 @@ +/* + * Copyright (C) 2004-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: socket.h,v 1.85.58.3 2009/01/29 22:40:35 jinmei Exp $ */ + +#ifndef ISC_SOCKET_H +#define ISC_SOCKET_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/socket.h + * \brief Provides TCP and UDP sockets for network I/O. The sockets are event + * sources in the task system. + * + * When I/O completes, a completion event for the socket is posted to the + * event queue of the task which requested the I/O. + * + * \li MP: + * The module ensures appropriate synchronization of data structures it + * creates and manipulates. + * Clients of this module must not be holding a socket's task's lock when + * making a call that affects that socket. Failure to follow this rule + * can result in deadlock. + * The caller must ensure that isc_socketmgr_destroy() is called only + * once for a given manager. + * + * \li Reliability: + * No anticipated impact. + * + * \li Resources: + * TBS + * + * \li Security: + * No anticipated impact. + * + * \li Standards: + * None. + */ + +/*** + *** Imports + ***/ + +#include +#include +#include +#include +#include +#include +#include +#include + +ISC_LANG_BEGINDECLS + +/*** + *** Constants + ***/ + +/*% + * Maximum number of buffers in a scatter/gather read/write. The operating + * system in use must support at least this number (plus one on some.) + */ +#define ISC_SOCKET_MAXSCATTERGATHER 8 + +/*% + * In isc_socket_bind() set socket option SO_REUSEADDR prior to calling + * bind() if a non zero port is specified (AF_INET and AF_INET6). + */ +#define ISC_SOCKET_REUSEADDRESS 0x01U + +/*% + * Statistics counters. Used as isc_statscounter_t values. + */ +enum { + isc_sockstatscounter_udp4open = 0, + isc_sockstatscounter_udp6open = 1, + isc_sockstatscounter_tcp4open = 2, + isc_sockstatscounter_tcp6open = 3, + isc_sockstatscounter_unixopen = 4, + + isc_sockstatscounter_udp4openfail = 5, + isc_sockstatscounter_udp6openfail = 6, + isc_sockstatscounter_tcp4openfail = 7, + isc_sockstatscounter_tcp6openfail = 8, + isc_sockstatscounter_unixopenfail = 9, + + isc_sockstatscounter_udp4close = 10, + isc_sockstatscounter_udp6close = 11, + isc_sockstatscounter_tcp4close = 12, + isc_sockstatscounter_tcp6close = 13, + isc_sockstatscounter_unixclose = 14, + isc_sockstatscounter_fdwatchclose = 15, + + isc_sockstatscounter_udp4bindfail = 16, + isc_sockstatscounter_udp6bindfail = 17, + isc_sockstatscounter_tcp4bindfail = 18, + isc_sockstatscounter_tcp6bindfail = 19, + isc_sockstatscounter_unixbindfail = 20, + isc_sockstatscounter_fdwatchbindfail = 21, + + isc_sockstatscounter_udp4connect = 22, + isc_sockstatscounter_udp6connect = 23, + isc_sockstatscounter_tcp4connect = 24, + isc_sockstatscounter_tcp6connect = 25, + isc_sockstatscounter_unixconnect = 26, + isc_sockstatscounter_fdwatchconnect = 27, + + isc_sockstatscounter_udp4connectfail = 28, + isc_sockstatscounter_udp6connectfail = 29, + isc_sockstatscounter_tcp4connectfail = 30, + isc_sockstatscounter_tcp6connectfail = 31, + isc_sockstatscounter_unixconnectfail = 32, + isc_sockstatscounter_fdwatchconnectfail = 33, + + isc_sockstatscounter_tcp4accept = 34, + isc_sockstatscounter_tcp6accept = 35, + isc_sockstatscounter_unixaccept = 36, + + isc_sockstatscounter_tcp4acceptfail = 37, + isc_sockstatscounter_tcp6acceptfail = 38, + isc_sockstatscounter_unixacceptfail = 39, + + isc_sockstatscounter_udp4sendfail = 40, + isc_sockstatscounter_udp6sendfail = 41, + isc_sockstatscounter_tcp4sendfail = 42, + isc_sockstatscounter_tcp6sendfail = 43, + isc_sockstatscounter_unixsendfail = 44, + isc_sockstatscounter_fdwatchsendfail = 45, + + isc_sockstatscounter_udp4recvfail = 46, + isc_sockstatscounter_udp6recvfail = 47, + isc_sockstatscounter_tcp4recvfail = 48, + isc_sockstatscounter_tcp6recvfail = 49, + isc_sockstatscounter_unixrecvfail = 50, + isc_sockstatscounter_fdwatchrecvfail = 51, + + isc_sockstatscounter_max = 52 +}; + +/*** + *** Types + ***/ + +struct isc_socketevent { + ISC_EVENT_COMMON(isc_socketevent_t); + isc_result_t result; /*%< OK, EOF, whatever else */ + unsigned int minimum; /*%< minimum i/o for event */ + unsigned int n; /*%< bytes read or written */ + unsigned int offset; /*%< offset into buffer list */ + isc_region_t region; /*%< for single-buffer i/o */ + isc_bufferlist_t bufferlist; /*%< list of buffers */ + isc_sockaddr_t address; /*%< source address */ + isc_time_t timestamp; /*%< timestamp of packet recv */ + struct in6_pktinfo pktinfo; /*%< ipv6 pktinfo */ + isc_uint32_t attributes; /*%< see below */ + isc_eventdestructor_t destroy; /*%< original destructor */ +}; + +typedef struct isc_socket_newconnev isc_socket_newconnev_t; +struct isc_socket_newconnev { + ISC_EVENT_COMMON(isc_socket_newconnev_t); + isc_socket_t * newsocket; + isc_result_t result; /*%< OK, EOF, whatever else */ + isc_sockaddr_t address; /*%< source address */ +}; + +typedef struct isc_socket_connev isc_socket_connev_t; +struct isc_socket_connev { + ISC_EVENT_COMMON(isc_socket_connev_t); + isc_result_t result; /*%< OK, EOF, whatever else */ +}; + +/*@{*/ +/*! + * _ATTACHED: Internal use only. + * _TRUNC: Packet was truncated on receive. + * _CTRUNC: Packet control information was truncated. This can + * indicate that the packet is not complete, even though + * all the data is valid. + * _TIMESTAMP: The timestamp member is valid. + * _PKTINFO: The pktinfo member is valid. + * _MULTICAST: The UDP packet was received via a multicast transmission. + */ +#define ISC_SOCKEVENTATTR_ATTACHED 0x80000000U /* internal */ +#define ISC_SOCKEVENTATTR_TRUNC 0x00800000U /* public */ +#define ISC_SOCKEVENTATTR_CTRUNC 0x00400000U /* public */ +#define ISC_SOCKEVENTATTR_TIMESTAMP 0x00200000U /* public */ +#define ISC_SOCKEVENTATTR_PKTINFO 0x00100000U /* public */ +#define ISC_SOCKEVENTATTR_MULTICAST 0x00080000U /* public */ +/*@}*/ + +#define ISC_SOCKEVENT_ANYEVENT (0) +#define ISC_SOCKEVENT_RECVDONE (ISC_EVENTCLASS_SOCKET + 1) +#define ISC_SOCKEVENT_SENDDONE (ISC_EVENTCLASS_SOCKET + 2) +#define ISC_SOCKEVENT_NEWCONN (ISC_EVENTCLASS_SOCKET + 3) +#define ISC_SOCKEVENT_CONNECT (ISC_EVENTCLASS_SOCKET + 4) + +/* + * Internal events. + */ +#define ISC_SOCKEVENT_INTR (ISC_EVENTCLASS_SOCKET + 256) +#define ISC_SOCKEVENT_INTW (ISC_EVENTCLASS_SOCKET + 257) + +typedef enum { + isc_sockettype_udp = 1, + isc_sockettype_tcp = 2, + isc_sockettype_unix = 3, + isc_sockettype_fdwatch = 4 +} isc_sockettype_t; + +/*@{*/ +/*! + * How a socket should be shutdown in isc_socket_shutdown() calls. + */ +#define ISC_SOCKSHUT_RECV 0x00000001 /*%< close read side */ +#define ISC_SOCKSHUT_SEND 0x00000002 /*%< close write side */ +#define ISC_SOCKSHUT_ALL 0x00000003 /*%< close them all */ +/*@}*/ + +/*@{*/ +/*! + * What I/O events to cancel in isc_socket_cancel() calls. + */ +#define ISC_SOCKCANCEL_RECV 0x00000001 /*%< cancel recv */ +#define ISC_SOCKCANCEL_SEND 0x00000002 /*%< cancel send */ +#define ISC_SOCKCANCEL_ACCEPT 0x00000004 /*%< cancel accept */ +#define ISC_SOCKCANCEL_CONNECT 0x00000008 /*%< cancel connect */ +#define ISC_SOCKCANCEL_ALL 0x0000000f /*%< cancel everything */ +/*@}*/ + +/*@{*/ +/*! + * Flags for isc_socket_send() and isc_socket_recv() calls. + */ +#define ISC_SOCKFLAG_IMMEDIATE 0x00000001 /*%< send event only if needed */ +#define ISC_SOCKFLAG_NORETRY 0x00000002 /*%< drop failed UDP sends */ +/*@}*/ + +/*@{*/ +/*! + * Flags for fdwatchcreate. + */ +#define ISC_SOCKFDWATCH_READ 0x00000001 /*%< watch for readable */ +#define ISC_SOCKFDWATCH_WRITE 0x00000002 /*%< watch for writable */ +/*@}*/ + +/*** + *** Socket and Socket Manager Functions + *** + *** Note: all Ensures conditions apply only if the result is success for + *** those functions which return an isc_result. + ***/ + +isc_result_t +isc_socket_fdwatchcreate(isc_socketmgr_t *manager, + int fd, + int flags, + isc_sockfdwatch_t callback, + void *cbarg, + isc_task_t *task, + isc_socket_t **socketp); +/*%< + * Create a new file descriptor watch socket managed by 'manager'. + * + * Note: + * + *\li 'fd' is the already-opened file descriptor. + *\li This function is not available on Windows. + *\li The callback function is called "in-line" - this means the function + * needs to return as fast as possible, as all other I/O will be suspended + * until the callback completes. + * + * Requires: + * + *\li 'manager' is a valid manager + * + *\li 'socketp' is a valid pointer, and *socketp == NULL + * + *\li 'fd' be opened. + * + * Ensures: + * + * '*socketp' is attached to the newly created fdwatch socket + * + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY + *\li #ISC_R_NORESOURCES + *\li #ISC_R_UNEXPECTED + */ + +isc_result_t +isc_socket_create(isc_socketmgr_t *manager, + int pf, + isc_sockettype_t type, + isc_socket_t **socketp); +/*%< + * Create a new 'type' socket managed by 'manager'. + * + * For isc_sockettype_fdwatch sockets you should use isc_socket_fdwatchcreate() + * rather than isc_socket_create(). + * + * Note: + * + *\li 'pf' is the desired protocol family, e.g. PF_INET or PF_INET6. + * + * Requires: + * + *\li 'manager' is a valid manager + * + *\li 'socketp' is a valid pointer, and *socketp == NULL + * + *\li 'type' is not isc_sockettype_fdwatch + * + * Ensures: + * + * '*socketp' is attached to the newly created socket + * + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY + *\li #ISC_R_NORESOURCES + *\li #ISC_R_UNEXPECTED + */ + +void +isc_socket_cancel(isc_socket_t *sock, isc_task_t *task, + unsigned int how); +/*%< + * Cancel pending I/O of the type specified by "how". + * + * Note: if "task" is NULL, then the cancel applies to all tasks using the + * socket. + * + * Requires: + * + * \li "socket" is a valid socket + * + * \li "task" is NULL or a valid task + * + * "how" is a bitmask describing the type of cancelation to perform. + * The type ISC_SOCKCANCEL_ALL will cancel all pending I/O on this + * socket. + * + * \li ISC_SOCKCANCEL_RECV: + * Cancel pending isc_socket_recv() calls. + * + * \li ISC_SOCKCANCEL_SEND: + * Cancel pending isc_socket_send() and isc_socket_sendto() calls. + * + * \li ISC_SOCKCANCEL_ACCEPT: + * Cancel pending isc_socket_accept() calls. + * + * \li ISC_SOCKCANCEL_CONNECT: + * Cancel pending isc_socket_connect() call. + */ + +void +isc_socket_shutdown(isc_socket_t *sock, unsigned int how); +/*%< + * Shutdown 'socket' according to 'how'. + * + * Requires: + * + * \li 'socket' is a valid socket. + * + * \li 'task' is NULL or is a valid task. + * + * \li If 'how' is 'ISC_SOCKSHUT_RECV' or 'ISC_SOCKSHUT_ALL' then + * + * The read queue must be empty. + * + * No further read requests may be made. + * + * \li If 'how' is 'ISC_SOCKSHUT_SEND' or 'ISC_SOCKSHUT_ALL' then + * + * The write queue must be empty. + * + * No further write requests may be made. + */ + +void +isc_socket_attach(isc_socket_t *sock, isc_socket_t **socketp); +/*%< + * Attach *socketp to socket. + * + * Requires: + * + * \li 'socket' is a valid socket. + * + * \li 'socketp' points to a NULL socket. + * + * Ensures: + * + * \li *socketp is attached to socket. + */ + +void +isc_socket_detach(isc_socket_t **socketp); +/*%< + * Detach *socketp from its socket. + * + * Requires: + * + * \li 'socketp' points to a valid socket. + * + * \li If '*socketp' is the last reference to the socket, + * then: + * + * There must be no pending I/O requests. + * + * Ensures: + * + * \li *socketp is NULL. + * + * \li If '*socketp' is the last reference to the socket, + * then: + * + * The socket will be shutdown (both reading and writing) + * for all tasks. + * + * All resources used by the socket have been freed + */ + +isc_result_t +isc_socket_open(isc_socket_t *sock); +/*%< + * Open a new socket file descriptor of the given socket structure. It simply + * opens a new descriptor; all of the other parameters including the socket + * type are inherited from the existing socket. This function is provided to + * avoid overhead of destroying and creating sockets when many short-lived + * sockets are frequently opened and closed. When the efficiency is not an + * issue, it should be safer to detach the unused socket and re-create a new + * one. This optimization may not be available for some systems, in which + * case this function will return ISC_R_NOTIMPLEMENTED and must not be used. + * + * isc_socket_open() should not be called on sockets created by + * isc_socket_fdwatchcreate(). + * + * Requires: + * + * \li there must be no other reference to this socket. + * + * \li 'socket' is a valid and previously closed by isc_socket_close() + * + * \li 'sock->type' is not isc_sockettype_fdwatch + * + * Returns: + * Same as isc_socket_create(). + * \li ISC_R_NOTIMPLEMENTED + */ + +isc_result_t +isc_socket_close(isc_socket_t *sock); +/*%< + * Close a socket file descriptor of the given socket structure. This function + * is provided as an alternative to destroying an unused socket when overhead + * destroying/re-creating sockets can be significant, and is expected to be + * used with isc_socket_open(). This optimization may not be available for some + * systems, in which case this function will return ISC_R_NOTIMPLEMENTED and + * must not be used. + * + * isc_socket_close() should not be called on sockets created by + * isc_socket_fdwatchcreate(). + * + * Requires: + * + * \li The socket must have a valid descriptor. + * + * \li There must be no other reference to this socket. + * + * \li There must be no pending I/O requests. + * + * \li 'sock->type' is not isc_sockettype_fdwatch + * + * Returns: + * \li #ISC_R_NOTIMPLEMENTED + */ + +isc_result_t +isc_socket_bind(isc_socket_t *sock, isc_sockaddr_t *addressp, + unsigned int options); +/*%< + * Bind 'socket' to '*addressp'. + * + * Requires: + * + * \li 'socket' is a valid socket + * + * \li 'addressp' points to a valid isc_sockaddr. + * + * Returns: + * + * \li ISC_R_SUCCESS + * \li ISC_R_NOPERM + * \li ISC_R_ADDRNOTAVAIL + * \li ISC_R_ADDRINUSE + * \li ISC_R_BOUND + * \li ISC_R_UNEXPECTED + */ + +isc_result_t +isc_socket_filter(isc_socket_t *sock, const char *filter); +/*%< + * Inform the kernel that it should perform accept filtering. + * If filter is NULL the current filter will be removed.:w + */ + +isc_result_t +isc_socket_listen(isc_socket_t *sock, unsigned int backlog); +/*%< + * Set listen mode on the socket. After this call, the only function that + * can be used (other than attach and detach) is isc_socket_accept(). + * + * Notes: + * + * \li 'backlog' is as in the UNIX system call listen() and may be + * ignored by non-UNIX implementations. + * + * \li If 'backlog' is zero, a reasonable system default is used, usually + * SOMAXCONN. + * + * Requires: + * + * \li 'socket' is a valid, bound TCP socket or a valid, bound UNIX socket. + * + * Returns: + * + * \li ISC_R_SUCCESS + * \li ISC_R_UNEXPECTED + */ + +isc_result_t +isc_socket_accept(isc_socket_t *sock, + isc_task_t *task, isc_taskaction_t action, const void *arg); +/*%< + * Queue accept event. When a new connection is received, the task will + * get an ISC_SOCKEVENT_NEWCONN event with the sender set to the listen + * socket. The new socket structure is sent inside the isc_socket_newconnev_t + * event type, and is attached to the task 'task'. + * + * REQUIRES: + * \li 'socket' is a valid TCP socket that isc_socket_listen() was called + * on. + * + * \li 'task' is a valid task + * + * \li 'action' is a valid action + * + * RETURNS: + * \li ISC_R_SUCCESS + * \li ISC_R_NOMEMORY + * \li ISC_R_UNEXPECTED + */ + +isc_result_t +isc_socket_connect(isc_socket_t *sock, isc_sockaddr_t *addressp, + isc_task_t *task, isc_taskaction_t action, + const void *arg); +/*%< + * Connect 'socket' to peer with address *saddr. When the connection + * succeeds, or when an error occurs, a CONNECT event with action 'action' + * and arg 'arg' will be posted to the event queue for 'task'. + * + * Requires: + * + * \li 'socket' is a valid TCP socket + * + * \li 'addressp' points to a valid isc_sockaddr + * + * \li 'task' is a valid task + * + * \li 'action' is a valid action + * + * Returns: + * + * \li ISC_R_SUCCESS + * \li ISC_R_NOMEMORY + * \li ISC_R_UNEXPECTED + * + * Posted event's result code: + * + * \li ISC_R_SUCCESS + * \li ISC_R_TIMEDOUT + * \li ISC_R_CONNREFUSED + * \li ISC_R_NETUNREACH + * \li ISC_R_UNEXPECTED + */ + +isc_result_t +isc_socket_getpeername(isc_socket_t *sock, isc_sockaddr_t *addressp); +/*%< + * Get the name of the peer connected to 'socket'. + * + * Requires: + * + * \li 'socket' is a valid TCP socket. + * + * Returns: + * + * \li ISC_R_SUCCESS + * \li ISC_R_TOOSMALL + * \li ISC_R_UNEXPECTED + */ + +isc_result_t +isc_socket_getsockname(isc_socket_t *sock, isc_sockaddr_t *addressp); +/*%< + * Get the name of 'socket'. + * + * Requires: + * + * \li 'socket' is a valid socket. + * + * Returns: + * + * \li ISC_R_SUCCESS + * \li ISC_R_TOOSMALL + * \li ISC_R_UNEXPECTED + */ + +/*@{*/ +isc_result_t +isc_socket_recv(isc_socket_t *sock, isc_region_t *region, + unsigned int minimum, + isc_task_t *task, isc_taskaction_t action, const void *arg); +isc_result_t +isc_socket_recvv(isc_socket_t *sock, isc_bufferlist_t *buflist, + unsigned int minimum, + isc_task_t *task, isc_taskaction_t action, const void *arg); + +isc_result_t +isc_socket_recv2(isc_socket_t *sock, isc_region_t *region, + unsigned int minimum, isc_task_t *task, + isc_socketevent_t *event, unsigned int flags); + +/*! + * Receive from 'socket', storing the results in region. + * + * Notes: + * + *\li Let 'length' refer to the length of 'region' or to the sum of all + * available regions in the list of buffers '*buflist'. + * + *\li If 'minimum' is non-zero and at least that many bytes are read, + * the completion event will be posted to the task 'task.' If minimum + * is zero, the exact number of bytes requested in the region must + * be read for an event to be posted. This only makes sense for TCP + * connections, and is always set to 1 byte for UDP. + * + *\li The read will complete when the desired number of bytes have been + * read, if end-of-input occurs, or if an error occurs. A read done + * event with the given 'action' and 'arg' will be posted to the + * event queue of 'task'. + * + *\li The caller may not modify 'region', the buffers which are passed + * into this function, or any data they refer to until the completion + * event is received. + * + *\li For isc_socket_recvv(): + * On successful completion, '*buflist' will be empty, and the list of + * all buffers will be returned in the done event's 'bufferlist' + * member. On error return, '*buflist' will be unchanged. + * + *\li For isc_socket_recv2(): + * 'event' is not NULL, and the non-socket specific fields are + * expected to be initialized. + * + *\li For isc_socket_recv2(): + * The only defined value for 'flags' is ISC_SOCKFLAG_IMMEDIATE. If + * set and the operation completes, the return value will be + * ISC_R_SUCCESS and the event will be filled in and not sent. If the + * operation does not complete, the return value will be + * ISC_R_INPROGRESS and the event will be sent when the operation + * completes. + * + * Requires: + * + *\li 'socket' is a valid, bound socket. + * + *\li For isc_socket_recv(): + * 'region' is a valid region + * + *\li For isc_socket_recvv(): + * 'buflist' is non-NULL, and '*buflist' contain at least one buffer. + * + *\li 'task' is a valid task + * + *\li For isc_socket_recv() and isc_socket_recvv(): + * action != NULL and is a valid action + * + *\li For isc_socket_recv2(): + * event != NULL + * + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_INPROGRESS + *\li #ISC_R_NOMEMORY + *\li #ISC_R_UNEXPECTED + * + * Event results: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_UNEXPECTED + *\li XXX needs other net-type errors + */ +/*@}*/ + +/*@{*/ +isc_result_t +isc_socket_send(isc_socket_t *sock, isc_region_t *region, + isc_task_t *task, isc_taskaction_t action, const void *arg); +isc_result_t +isc_socket_sendto(isc_socket_t *sock, isc_region_t *region, + isc_task_t *task, isc_taskaction_t action, const void *arg, + isc_sockaddr_t *address, struct in6_pktinfo *pktinfo); +isc_result_t +isc_socket_sendv(isc_socket_t *sock, isc_bufferlist_t *buflist, + isc_task_t *task, isc_taskaction_t action, const void *arg); +isc_result_t +isc_socket_sendtov(isc_socket_t *sock, isc_bufferlist_t *buflist, + isc_task_t *task, isc_taskaction_t action, const void *arg, + isc_sockaddr_t *address, struct in6_pktinfo *pktinfo); +isc_result_t +isc_socket_sendto2(isc_socket_t *sock, isc_region_t *region, + isc_task_t *task, + isc_sockaddr_t *address, struct in6_pktinfo *pktinfo, + isc_socketevent_t *event, unsigned int flags); + +/*! + * Send the contents of 'region' to the socket's peer. + * + * Notes: + * + *\li Shutting down the requestor's task *may* result in any + * still pending writes being dropped or completed, depending on the + * underlying OS implementation. + * + *\li If 'action' is NULL, then no completion event will be posted. + * + *\li The caller may not modify 'region', the buffers which are passed + * into this function, or any data they refer to until the completion + * event is received. + * + *\li For isc_socket_sendv() and isc_socket_sendtov(): + * On successful completion, '*buflist' will be empty, and the list of + * all buffers will be returned in the done event's 'bufferlist' + * member. On error return, '*buflist' will be unchanged. + * + *\li For isc_socket_sendto2(): + * 'event' is not NULL, and the non-socket specific fields are + * expected to be initialized. + * + *\li For isc_socket_sendto2(): + * The only defined values for 'flags' are ISC_SOCKFLAG_IMMEDIATE + * and ISC_SOCKFLAG_NORETRY. + * + *\li If ISC_SOCKFLAG_IMMEDIATE is set and the operation completes, the + * return value will be ISC_R_SUCCESS and the event will be filled + * in and not sent. If the operation does not complete, the return + * value will be ISC_R_INPROGRESS and the event will be sent when + * the operation completes. + * + *\li ISC_SOCKFLAG_NORETRY can only be set for UDP sockets. If set + * and the send operation fails due to a transient error, the send + * will not be retried and the error will be indicated in the event. + * Using this option along with ISC_SOCKFLAG_IMMEDIATE allows the caller + * to specify a region that is allocated on the stack. + * + * Requires: + * + *\li 'socket' is a valid, bound socket. + * + *\li For isc_socket_send(): + * 'region' is a valid region + * + *\li For isc_socket_sendv() and isc_socket_sendtov(): + * 'buflist' is non-NULL, and '*buflist' contain at least one buffer. + * + *\li 'task' is a valid task + * + *\li For isc_socket_sendv(), isc_socket_sendtov(), isc_socket_send(), and + * isc_socket_sendto(): + * action == NULL or is a valid action + * + *\li For isc_socket_sendto2(): + * event != NULL + * + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_INPROGRESS + *\li #ISC_R_NOMEMORY + *\li #ISC_R_UNEXPECTED + * + * Event results: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_UNEXPECTED + *\li XXX needs other net-type errors + */ +/*@}*/ + +isc_result_t +isc_socketmgr_create(isc_mem_t *mctx, isc_socketmgr_t **managerp); + +isc_result_t +isc_socketmgr_create2(isc_mem_t *mctx, isc_socketmgr_t **managerp, + unsigned int maxsocks); +/*%< + * Create a socket manager. If "maxsocks" is non-zero, it specifies the + * maximum number of sockets that the created manager should handle. + * isc_socketmgr_create() is equivalent of isc_socketmgr_create2() with + * "maxsocks" being zero. + * + * Notes: + * + *\li All memory will be allocated in memory context 'mctx'. + * + * Requires: + * + *\li 'mctx' is a valid memory context. + * + *\li 'managerp' points to a NULL isc_socketmgr_t. + * + * Ensures: + * + *\li '*managerp' is a valid isc_socketmgr_t. + * + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY + *\li #ISC_R_UNEXPECTED + *\li #ISC_R_NOTIMPLEMENTED + */ + +isc_result_t +isc_socketmgr_getmaxsockets(isc_socketmgr_t *manager, unsigned int *nsockp); +/*%< + * Returns in "*nsockp" the maximum number of sockets this manager may open. + * + * Requires: + * + *\li '*manager' is a valid isc_socketmgr_t. + *\li 'nsockp' is not NULL. + * + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOTIMPLEMENTED + */ + +void +isc_socketmgr_setstats(isc_socketmgr_t *manager, isc_stats_t *stats); +/*%< + * Set a general socket statistics counter set 'stats' for 'manager'. + * + * Requires: + * \li 'manager' is valid, hasn't opened any socket, and doesn't have + * stats already set. + * + *\li stats is a valid statistics supporting socket statistics counters + * (see above). + */ + +void +isc_socketmgr_destroy(isc_socketmgr_t **managerp); +/*%< + * Destroy a socket manager. + * + * Notes: + * + *\li This routine blocks until there are no sockets left in the manager, + * so if the caller holds any socket references using the manager, it + * must detach them before calling isc_socketmgr_destroy() or it will + * block forever. + * + * Requires: + * + *\li '*managerp' is a valid isc_socketmgr_t. + * + *\li All sockets managed by this manager are fully detached. + * + * Ensures: + * + *\li *managerp == NULL + * + *\li All resources used by the manager have been freed. + */ + +isc_sockettype_t +isc_socket_gettype(isc_socket_t *sock); +/*%< + * Returns the socket type for "sock." + * + * Requires: + * + *\li "sock" is a valid socket. + */ + +/*@{*/ +isc_boolean_t +isc_socket_isbound(isc_socket_t *sock); + +void +isc_socket_ipv6only(isc_socket_t *sock, isc_boolean_t yes); +/*%< + * If the socket is an IPv6 socket set/clear the IPV6_IPV6ONLY socket + * option if the host OS supports this option. + * + * Requires: + *\li 'sock' is a valid socket. + */ +/*@}*/ + +void +isc_socket_cleanunix(isc_sockaddr_t *addr, isc_boolean_t active); + +/*%< + * Cleanup UNIX domain sockets in the file-system. If 'active' is true + * then just unlink the socket. If 'active' is false try to determine + * if there is a listener of the socket or not. If no listener is found + * then unlink socket. + * + * Prior to unlinking the path is tested to see if it a socket. + * + * Note: there are a number of race conditions which cannot be avoided + * both in the filesystem and any application using UNIX domain + * sockets (e.g. socket is tested between bind() and listen(), + * the socket is deleted and replaced in the file-system between + * stat() and unlink()). + */ + +isc_result_t +isc_socket_permunix(isc_sockaddr_t *sockaddr, isc_uint32_t perm, + isc_uint32_t owner, isc_uint32_t group); +/*%< + * Set ownership and file permissions on the UNIX domain socket. + * + * Note: On Solaris and SunOS this secures the directory containing + * the socket as Solaris and SunOS do not honour the filesystem + * permissions on the socket. + * + * Requires: + * \li 'sockaddr' to be a valid UNIX domain sockaddr. + * + * Returns: + * \li #ISC_R_SUCCESS + * \li #ISC_R_FAILURE + */ + +void isc_socket_setname(isc_socket_t *socket, const char *name, void *tag); +/*%< + * Set the name and optional tag for a socket. This allows tracking of the + * owner or purpose for this socket, and is useful for tracing and statistics + * reporting. + */ + +const char *isc_socket_getname(isc_socket_t *socket); +/*%< + * Get the name associated with a socket, if any. + */ + +void *isc_socket_gettag(isc_socket_t *socket); +/*%< + * Get the tag associated with a socket, if any. + */ + +void +isc__socketmgr_setreserved(isc_socketmgr_t *mgr, isc_uint32_t); +/*%< + * Temporary. For use by named only. + */ + +#ifdef HAVE_LIBXML2 + +void +isc_socketmgr_renderxml(isc_socketmgr_t *mgr, xmlTextWriterPtr writer); +/*%< + * Render internal statistics and other state into the XML document. + */ + +#endif /* HAVE_LIBXML2 */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_SOCKET_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/stats.h src.ntp/contrib/ntp/lib/isc/include/isc/stats.h --- src/contrib/ntp/lib/isc/include/isc/stats.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/stats.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,121 @@ +/* + * Copyright (C) 2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: stats.h,v 1.4.2.2 2009/01/29 23:47:44 tbox Exp $ */ + +#ifndef ISC_STATS_H +#define ISC_STATS_H 1 + +/*! \file isc/stats.h */ + +#include + +ISC_LANG_BEGINDECLS + +/*%< + * Flag(s) for isc_stats_dump(). + */ +#define ISC_STATSDUMP_VERBOSE 0x00000001 /*%< dump 0-value counters */ + +/*%< + * Dump callback type. + */ +typedef void (*isc_stats_dumper_t)(isc_statscounter_t, isc_uint64_t, void *); + +isc_result_t +isc_stats_create(isc_mem_t *mctx, isc_stats_t **statsp, int ncounters); +/*%< + * Create a statistics counter structure of general type. It counts a general + * set of counters indexed by an ID between 0 and ncounters -1. + * + * Requires: + *\li 'mctx' must be a valid memory context. + * + *\li 'statsp' != NULL && '*statsp' == NULL. + * + * Returns: + *\li ISC_R_SUCCESS -- all ok + * + *\li anything else -- failure + */ + +void +isc_stats_attach(isc_stats_t *stats, isc_stats_t **statsp); +/*%< + * Attach to a statistics set. + * + * Requires: + *\li 'stats' is a valid isc_stats_t. + * + *\li 'statsp' != NULL && '*statsp' == NULL + */ + +void +isc_stats_detach(isc_stats_t **statsp); +/*%< + * Detaches from the statistics set. + * + * Requires: + *\li 'statsp' != NULL and '*statsp' is a valid isc_stats_t. + */ + +int +isc_stats_ncounters(isc_stats_t *stats); +/*%< + * Returns the number of counters contained in stats. + * + * Requires: + *\li 'stats' is a valid isc_stats_t. + * + */ + +void +isc_stats_increment(isc_stats_t *stats, isc_statscounter_t counter); +/*%< + * Increment the counter-th counter of stats. + * + * Requires: + *\li 'stats' is a valid isc_stats_t. + * + *\li counter is less than the maximum available ID for the stats specified + * on creation. + */ + +void +isc_stats_decrement(isc_stats_t *stats, isc_statscounter_t counter); +/*%< + * Decrement the counter-th counter of stats. + * + * Requires: + *\li 'stats' is a valid isc_stats_t. + */ + +void +isc_stats_dump(isc_stats_t *stats, isc_stats_dumper_t dump_fn, void *arg, + unsigned int options); +/*%< + * Dump the current statistics counters in a specified way. For each counter + * in stats, dump_fn is called with its current value and the given argument + * arg. By default counters that have a value of 0 is skipped; if options has + * the ISC_STATSDUMP_VERBOSE flag, even such counters are dumped. + * + * Requires: + *\li 'stats' is a valid isc_stats_t. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_STATS_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/stdio.h src.ntp/contrib/ntp/lib/isc/include/isc/stdio.h --- src/contrib/ntp/lib/isc/include/isc/stdio.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/stdio.h 2009-12-09 08:36:44.000000000 +0100 @@ -0,0 +1,77 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: stdio.h,v 1.13 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_STDIO_H +#define ISC_STDIO_H 1 + +/*! \file isc/stdio.h */ + +/*% + * These functions are wrappers around the corresponding stdio functions. + * + * They return a detailed error code in the form of an an isc_result_t. ANSI C + * does not guarantee that stdio functions set errno, hence these functions + * must use platform dependent methods (e.g., the POSIX errno) to construct the + * error code. + */ + +#include + +#include +#include + +ISC_LANG_BEGINDECLS + +/*% Open */ +isc_result_t +isc_stdio_open(const char *filename, const char *mode, FILE **fp); + +/*% Close */ +isc_result_t +isc_stdio_close(FILE *f); + +/*% Seek */ +isc_result_t +isc_stdio_seek(FILE *f, long offset, int whence); + +/*% Read */ +isc_result_t +isc_stdio_read(void *ptr, size_t size, size_t nmemb, FILE *f, + size_t *nret); + +/*% Write */ +isc_result_t +isc_stdio_write(const void *ptr, size_t size, size_t nmemb, FILE *f, + size_t *nret); + +/*% Flush */ +isc_result_t +isc_stdio_flush(FILE *f); + +isc_result_t +isc_stdio_sync(FILE *f); +/*%< + * Invoke fsync() on the file descriptor underlying an stdio stream, or an + * equivalent system-dependent operation. Note that this function has no + * direct counterpart in the stdio library. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_STDIO_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/stdlib.h src.ntp/contrib/ntp/lib/isc/include/isc/stdlib.h --- src/contrib/ntp/lib/isc/include/isc/stdlib.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/stdlib.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,40 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: stdlib.h,v 1.8 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_STDLIB_H +#define ISC_STDLIB_H 1 + +/*! \file isc/stdlib.h */ + +#include + +#include +#include + +#ifdef ISC_PLATFORM_NEEDSTRTOUL +#define strtoul isc_strtoul +#endif + +ISC_LANG_BEGINDECLS + +unsigned long isc_strtoul(const char *, char **, int); + +ISC_LANG_ENDDECLS + +#endif diff -urN src/contrib/ntp/lib/isc/include/isc/string.h src.ntp/contrib/ntp/lib/isc/include/isc/string.h --- src/contrib/ntp/lib/isc/include/isc/string.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/string.h 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,231 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: string.h,v 1.23 2007/09/13 04:48:16 each Exp $ */ + +#ifndef ISC_STRING_H +#define ISC_STRING_H 1 + +/*! \file isc/string.h */ + +#include +#include +#include +#include +#include + +#include + +#ifdef ISC_PLATFORM_HAVESTRINGSH +#include +#endif + +#define ISC_STRING_MAGIC 0x5e + +ISC_LANG_BEGINDECLS + +isc_uint64_t +isc_string_touint64(char *source, char **endp, int base); +/*%< + * Convert the string pointed to by 'source' to isc_uint64_t. + * + * On successful conversion 'endp' points to the first character + * after conversion is complete. + * + * 'base': 0 or 2..36 + * + * If base is 0 the base is computed from the string type. + * + * On error 'endp' points to 'source'. + */ + +isc_result_t +isc_string_copy(char *target, size_t size, const char *source); +/* + * Copy the string pointed to by 'source' to 'target' which is a + * pointer to a string of at least 'size' bytes. + * + * Requires: + * 'target' is a pointer to a char[] of at least 'size' bytes. + * 'size' an integer > 0. + * 'source' == NULL or points to a NUL terminated string. + * + * Ensures: + * If result == ISC_R_SUCCESS + * 'target' will be a NUL terminated string of no more + * than 'size' bytes (including NUL). + * + * If result == ISC_R_NOSPACE + * 'target' is undefined. + * + * Returns: + * ISC_R_SUCCESS -- 'source' was successfully copied to 'target'. + * ISC_R_NOSPACE -- 'source' could not be copied since 'target' + * is too small. + */ + +void +isc_string_copy_truncate(char *target, size_t size, const char *source); +/* + * Copy the string pointed to by 'source' to 'target' which is a + * pointer to a string of at least 'size' bytes. + * + * Requires: + * 'target' is a pointer to a char[] of at least 'size' bytes. + * 'size' an integer > 0. + * 'source' == NULL or points to a NUL terminated string. + * + * Ensures: + * 'target' will be a NUL terminated string of no more + * than 'size' bytes (including NUL). + */ + +isc_result_t +isc_string_append(char *target, size_t size, const char *source); +/* + * Append the string pointed to by 'source' to 'target' which is a + * pointer to a NUL terminated string of at least 'size' bytes. + * + * Requires: + * 'target' is a pointer to a NUL terminated char[] of at + * least 'size' bytes. + * 'size' an integer > 0. + * 'source' == NULL or points to a NUL terminated string. + * + * Ensures: + * If result == ISC_R_SUCCESS + * 'target' will be a NUL terminated string of no more + * than 'size' bytes (including NUL). + * + * If result == ISC_R_NOSPACE + * 'target' is undefined. + * + * Returns: + * ISC_R_SUCCESS -- 'source' was successfully appended to 'target'. + * ISC_R_NOSPACE -- 'source' could not be appended since 'target' + * is too small. + */ + +void +isc_string_append_truncate(char *target, size_t size, const char *source); +/* + * Append the string pointed to by 'source' to 'target' which is a + * pointer to a NUL terminated string of at least 'size' bytes. + * + * Requires: + * 'target' is a pointer to a NUL terminated char[] of at + * least 'size' bytes. + * 'size' an integer > 0. + * 'source' == NULL or points to a NUL terminated string. + * + * Ensures: + * 'target' will be a NUL terminated string of no more + * than 'size' bytes (including NUL). + */ + +isc_result_t +isc_string_printf(char *target, size_t size, const char *format, ...) + ISC_FORMAT_PRINTF(3, 4); +/* + * Print 'format' to 'target' which is a pointer to a string of at least + * 'size' bytes. + * + * Requires: + * 'target' is a pointer to a char[] of at least 'size' bytes. + * 'size' an integer > 0. + * 'format' == NULL or points to a NUL terminated string. + * + * Ensures: + * If result == ISC_R_SUCCESS + * 'target' will be a NUL terminated string of no more + * than 'size' bytes (including NUL). + * + * If result == ISC_R_NOSPACE + * 'target' is undefined. + * + * Returns: + * ISC_R_SUCCESS -- 'format' was successfully printed to 'target'. + * ISC_R_NOSPACE -- 'format' could not be printed to 'target' since it + * is too small. + */ + +void +isc_string_printf_truncate(char *target, size_t size, const char *format, ...) + ISC_FORMAT_PRINTF(3, 4); +/* + * Print 'format' to 'target' which is a pointer to a string of at least + * 'size' bytes. + * + * Requires: + * 'target' is a pointer to a char[] of at least 'size' bytes. + * 'size' an integer > 0. + * 'format' == NULL or points to a NUL terminated string. + * + * Ensures: + * 'target' will be a NUL terminated string of no more + * than 'size' bytes (including NUL). + */ + + +char * +isc_string_regiondup(isc_mem_t *mctx, const isc_region_t *source); +/* + * Copy the region pointed to by r to a NUL terminated string + * allocated from the memory context pointed to by mctx. + * + * The result should be deallocated using isc_mem_free() + * + * Requires: + * 'mctx' is a point to a valid memory context. + * 'source' is a pointer to a valid region. + * + * Returns: + * a pointer to a NUL terminated string or + * NULL if memory for the copy could not be allocated + * + */ + +char * +isc_string_separate(char **stringp, const char *delim); + +#ifdef ISC_PLATFORM_NEEDSTRSEP +#define strsep isc_string_separate +#endif + +#ifdef ISC_PLATFORM_NEEDMEMMOVE +#define memmove(a,b,c) bcopy(b,a,c) +#endif + +size_t +isc_string_strlcpy(char *dst, const char *src, size_t size); + + +#ifdef ISC_PLATFORM_NEEDSTRLCPY +#define strlcpy isc_string_strlcpy +#endif + + +size_t +isc_string_strlcat(char *dst, const char *src, size_t size); + +#ifdef ISC_PLATFORM_NEEDSTRLCAT +#define strlcat isc_string_strlcat +#endif + +ISC_LANG_ENDDECLS + +#endif /* ISC_STRING_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/symtab.h src.ntp/contrib/ntp/lib/isc/include/isc/symtab.h --- src/contrib/ntp/lib/isc/include/isc/symtab.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/symtab.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,131 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1996-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: symtab.h,v 1.24.332.2 2009/01/18 23:47:41 tbox Exp $ */ + +#ifndef ISC_SYMTAB_H +#define ISC_SYMTAB_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/symtab.h + * \brief Provides a simple memory-based symbol table. + * + * Keys are C strings, and key comparisons are case-insensitive. A type may + * be specified when looking up, defining, or undefining. A type value of + * 0 means "match any type"; any other value will only match the given + * type. + * + * It's possible that a client will attempt to define a + * tuple when a tuple with the given key and type already exists in the table. + * What to do in this case is specified by the client. Possible policies are: + * + *\li #isc_symexists_reject Disallow the define, returning #ISC_R_EXISTS + *\li #isc_symexists_replace Replace the old value with the new. The + * undefine action (if provided) will be called + * with the old tuple. + *\li #isc_symexists_add Add the new tuple, leaving the old tuple in + * the table. Subsequent lookups will retrieve + * the most-recently-defined tuple. + * + * A lookup of a key using type 0 will return the most-recently defined + * symbol with that key. An undefine of a key using type 0 will undefine the + * most-recently defined symbol with that key. Trying to define a key with + * type 0 is illegal. + * + * The symbol table library does not make a copy the key field, so the + * caller must ensure that any key it passes to isc_symtab_define() will not + * change until it calls isc_symtab_undefine() or isc_symtab_destroy(). + * + * A user-specified action will be called (if provided) when a symbol is + * undefined. It can be used to free memory associated with keys and/or + * values. + * + * \li MP: + * The callers of this module must ensure any required synchronization. + * + * \li Reliability: + * No anticipated impact. + * + * \li Resources: + * TBS + * + * \li Security: + * No anticipated impact. + * + * \li Standards: + * None. + */ + +/*** + *** Imports. + ***/ + +#include +#include + +/* + *** Symbol Tables. + ***/ +/*% Symbol table value. */ +typedef union isc_symvalue { + void * as_pointer; + const void * as_cpointer; + int as_integer; + unsigned int as_uinteger; +} isc_symvalue_t; + +typedef void (*isc_symtabaction_t)(char *key, unsigned int type, + isc_symvalue_t value, void *userarg); +/*% Symbol table exists. */ +typedef enum { + isc_symexists_reject = 0, /*%< Disallow the define */ + isc_symexists_replace = 1, /*%< Replace the old value with the new */ + isc_symexists_add = 2 /*%< Add the new tuple */ +} isc_symexists_t; + +ISC_LANG_BEGINDECLS + +/*% Create a symbol table. */ +isc_result_t +isc_symtab_create(isc_mem_t *mctx, unsigned int size, + isc_symtabaction_t undefine_action, void *undefine_arg, + isc_boolean_t case_sensitive, isc_symtab_t **symtabp); + +/*% Destroy a symbol table. */ +void +isc_symtab_destroy(isc_symtab_t **symtabp); + +/*% Lookup a symbol table. */ +isc_result_t +isc_symtab_lookup(isc_symtab_t *symtab, const char *key, unsigned int type, + isc_symvalue_t *value); + +/*% Define a symbol table. */ +isc_result_t +isc_symtab_define(isc_symtab_t *symtab, const char *key, unsigned int type, + isc_symvalue_t value, isc_symexists_t exists_policy); + +/*% Undefine a symbol table. */ +isc_result_t +isc_symtab_undefine(isc_symtab_t *symtab, const char *key, unsigned int type); + +ISC_LANG_ENDDECLS + +#endif /* ISC_SYMTAB_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/task.h src.ntp/contrib/ntp/lib/isc/include/isc/task.h --- src/contrib/ntp/lib/isc/include/isc/task.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/task.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,624 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: task.h,v 1.61.332.2 2009/01/18 23:47:41 tbox Exp $ */ + +#ifndef ISC_TASK_H +#define ISC_TASK_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/task.h + * \brief The task system provides a lightweight execution context, which is + * basically an event queue. + + * When a task's event queue is non-empty, the + * task is runnable. A small work crew of threads, typically one per CPU, + * execute runnable tasks by dispatching the events on the tasks' event + * queues. Context switching between tasks is fast. + * + * \li MP: + * The module ensures appropriate synchronization of data structures it + * creates and manipulates. + * The caller must ensure that isc_taskmgr_destroy() is called only + * once for a given manager. + * + * \li Reliability: + * No anticipated impact. + * + * \li Resources: + * TBS + * + * \li Security: + * No anticipated impact. + * + * \li Standards: + * None. + * + * \section purge Purging and Unsending + * + * Events which have been queued for a task but not delivered may be removed + * from the task's event queue by purging or unsending. + * + * With both types, the caller specifies a matching pattern that selects + * events based upon their sender, type, and tag. + * + * Purging calls isc_event_free() on the matching events. + * + * Unsending returns a list of events that matched the pattern. + * The caller is then responsible for them. + * + * Consumers of events should purge, not unsend. + * + * Producers of events often want to remove events when the caller indicates + * it is no longer interested in the object, e.g. by canceling a timer. + * Sometimes this can be done by purging, but for some event types, the + * calls to isc_event_free() cause deadlock because the event free routine + * wants to acquire a lock the caller is already holding. Unsending instead + * of purging solves this problem. As a general rule, producers should only + * unsend events which they have sent. + */ + + +/*** + *** Imports. + ***/ + +#include +#include +#include +#include +#include + +#define ISC_TASKEVENT_FIRSTEVENT (ISC_EVENTCLASS_TASK + 0) +#define ISC_TASKEVENT_SHUTDOWN (ISC_EVENTCLASS_TASK + 1) +#define ISC_TASKEVENT_LASTEVENT (ISC_EVENTCLASS_TASK + 65535) + +/***** + ***** Tasks. + *****/ + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_task_create(isc_taskmgr_t *manager, unsigned int quantum, + isc_task_t **taskp); +/*%< + * Create a task. + * + * Notes: + * + *\li If 'quantum' is non-zero, then only that many events can be dispatched + * before the task must yield to other tasks waiting to execute. If + * quantum is zero, then the default quantum of the task manager will + * be used. + * + *\li The 'quantum' option may be removed from isc_task_create() in the + * future. If this happens, isc_task_getquantum() and + * isc_task_setquantum() will be provided. + * + * Requires: + * + *\li 'manager' is a valid task manager. + * + *\li taskp != NULL && *taskp == NULL + * + * Ensures: + * + *\li On success, '*taskp' is bound to the new task. + * + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY + *\li #ISC_R_UNEXPECTED + *\li #ISC_R_SHUTTINGDOWN + */ + +void +isc_task_attach(isc_task_t *source, isc_task_t **targetp); +/*%< + * Attach *targetp to source. + * + * Requires: + * + *\li 'source' is a valid task. + * + *\li 'targetp' points to a NULL isc_task_t *. + * + * Ensures: + * + *\li *targetp is attached to source. + */ + +void +isc_task_detach(isc_task_t **taskp); +/*%< + * Detach *taskp from its task. + * + * Requires: + * + *\li '*taskp' is a valid task. + * + * Ensures: + * + *\li *taskp is NULL. + * + *\li If '*taskp' is the last reference to the task, the task is idle (has + * an empty event queue), and has not been shutdown, the task will be + * shutdown. + * + *\li If '*taskp' is the last reference to the task and + * the task has been shutdown, + * all resources used by the task will be freed. + */ + +void +isc_task_send(isc_task_t *task, isc_event_t **eventp); +/*%< + * Send '*event' to 'task'. + * + * Requires: + * + *\li 'task' is a valid task. + *\li eventp != NULL && *eventp != NULL. + * + * Ensures: + * + *\li *eventp == NULL. + */ + +void +isc_task_sendanddetach(isc_task_t **taskp, isc_event_t **eventp); +/*%< + * Send '*event' to '*taskp' and then detach '*taskp' from its + * task. + * + * Requires: + * + *\li '*taskp' is a valid task. + *\li eventp != NULL && *eventp != NULL. + * + * Ensures: + * + *\li *eventp == NULL. + * + *\li *taskp == NULL. + * + *\li If '*taskp' is the last reference to the task, the task is + * idle (has an empty event queue), and has not been shutdown, + * the task will be shutdown. + * + *\li If '*taskp' is the last reference to the task and + * the task has been shutdown, + * all resources used by the task will be freed. + */ + + +unsigned int +isc_task_purgerange(isc_task_t *task, void *sender, isc_eventtype_t first, + isc_eventtype_t last, void *tag); +/*%< + * Purge events from a task's event queue. + * + * Requires: + * + *\li 'task' is a valid task. + * + *\li last >= first + * + * Ensures: + * + *\li Events in the event queue of 'task' whose sender is 'sender', whose + * type is >= first and <= last, and whose tag is 'tag' will be purged, + * unless they are marked as unpurgable. + * + *\li A sender of NULL will match any sender. A NULL tag matches any + * tag. + * + * Returns: + * + *\li The number of events purged. + */ + +unsigned int +isc_task_purge(isc_task_t *task, void *sender, isc_eventtype_t type, + void *tag); +/*%< + * Purge events from a task's event queue. + * + * Notes: + * + *\li This function is equivalent to + * + *\code + * isc_task_purgerange(task, sender, type, type, tag); + *\endcode + * + * Requires: + * + *\li 'task' is a valid task. + * + * Ensures: + * + *\li Events in the event queue of 'task' whose sender is 'sender', whose + * type is 'type', and whose tag is 'tag' will be purged, unless they + * are marked as unpurgable. + * + *\li A sender of NULL will match any sender. A NULL tag matches any + * tag. + * + * Returns: + * + *\li The number of events purged. + */ + +isc_boolean_t +isc_task_purgeevent(isc_task_t *task, isc_event_t *event); +/*%< + * Purge 'event' from a task's event queue. + * + * XXXRTH: WARNING: This method may be removed before beta. + * + * Notes: + * + *\li If 'event' is on the task's event queue, it will be purged, + * unless it is marked as unpurgeable. 'event' does not have to be + * on the task's event queue; in fact, it can even be an invalid + * pointer. Purging only occurs if the event is actually on the task's + * event queue. + * + * \li Purging never changes the state of the task. + * + * Requires: + * + *\li 'task' is a valid task. + * + * Ensures: + * + *\li 'event' is not in the event queue for 'task'. + * + * Returns: + * + *\li #ISC_TRUE The event was purged. + *\li #ISC_FALSE The event was not in the event queue, + * or was marked unpurgeable. + */ + +unsigned int +isc_task_unsendrange(isc_task_t *task, void *sender, isc_eventtype_t first, + isc_eventtype_t last, void *tag, isc_eventlist_t *events); +/*%< + * Remove events from a task's event queue. + * + * Requires: + * + *\li 'task' is a valid task. + * + *\li last >= first. + * + *\li *events is a valid list. + * + * Ensures: + * + *\li Events in the event queue of 'task' whose sender is 'sender', whose + * type is >= first and <= last, and whose tag is 'tag' will be dequeued + * and appended to *events. + * + *\li A sender of NULL will match any sender. A NULL tag matches any + * tag. + * + * Returns: + * + *\li The number of events unsent. + */ + +unsigned int +isc_task_unsend(isc_task_t *task, void *sender, isc_eventtype_t type, + void *tag, isc_eventlist_t *events); +/*%< + * Remove events from a task's event queue. + * + * Notes: + * + *\li This function is equivalent to + * + *\code + * isc_task_unsendrange(task, sender, type, type, tag, events); + *\endcode + * + * Requires: + * + *\li 'task' is a valid task. + * + *\li *events is a valid list. + * + * Ensures: + * + *\li Events in the event queue of 'task' whose sender is 'sender', whose + * type is 'type', and whose tag is 'tag' will be dequeued and appended + * to *events. + * + * Returns: + * + *\li The number of events unsent. + */ + +isc_result_t +isc_task_onshutdown(isc_task_t *task, isc_taskaction_t action, + const void *arg); +/*%< + * Send a shutdown event with action 'action' and argument 'arg' when + * 'task' is shutdown. + * + * Notes: + * + *\li Shutdown events are posted in LIFO order. + * + * Requires: + * + *\li 'task' is a valid task. + * + *\li 'action' is a valid task action. + * + * Ensures: + * + *\li When the task is shutdown, shutdown events requested with + * isc_task_onshutdown() will be appended to the task's event queue. + * + + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY + *\li #ISC_R_TASKSHUTTINGDOWN Task is shutting down. + */ + +void +isc_task_shutdown(isc_task_t *task); +/*%< + * Shutdown 'task'. + * + * Notes: + * + *\li Shutting down a task causes any shutdown events requested with + * isc_task_onshutdown() to be posted (in LIFO order). The task + * moves into a "shutting down" mode which prevents further calls + * to isc_task_onshutdown(). + * + *\li Trying to shutdown a task that has already been shutdown has no + * effect. + * + * Requires: + * + *\li 'task' is a valid task. + * + * Ensures: + * + *\li Any shutdown events requested with isc_task_onshutdown() have been + * posted (in LIFO order). + */ + +void +isc_task_destroy(isc_task_t **taskp); +/*%< + * Destroy '*taskp'. + * + * Notes: + * + *\li This call is equivalent to: + * + *\code + * isc_task_shutdown(*taskp); + * isc_task_detach(taskp); + *\endcode + * + * Requires: + * + * '*taskp' is a valid task. + * + * Ensures: + * + *\li Any shutdown events requested with isc_task_onshutdown() have been + * posted (in LIFO order). + * + *\li *taskp == NULL + * + *\li If '*taskp' is the last reference to the task, + * all resources used by the task will be freed. + */ + +void +isc_task_setname(isc_task_t *task, const char *name, void *tag); +/*%< + * Name 'task'. + * + * Notes: + * + *\li Only the first 15 characters of 'name' will be copied. + * + *\li Naming a task is currently only useful for debugging purposes. + * + * Requires: + * + *\li 'task' is a valid task. + */ + +const char * +isc_task_getname(isc_task_t *task); +/*%< + * Get the name of 'task', as previously set using isc_task_setname(). + * + * Notes: + *\li This function is for debugging purposes only. + * + * Requires: + *\li 'task' is a valid task. + * + * Returns: + *\li A non-NULL pointer to a null-terminated string. + * If the task has not been named, the string is + * empty. + * + */ + +void * +isc_task_gettag(isc_task_t *task); +/*%< + * Get the tag value for 'task', as previously set using isc_task_settag(). + * + * Notes: + *\li This function is for debugging purposes only. + * + * Requires: + *\li 'task' is a valid task. + */ + +isc_result_t +isc_task_beginexclusive(isc_task_t *task); +/*%< + * Request exclusive access for 'task', which must be the calling + * task. Waits for any other concurrently executing tasks to finish their + * current event, and prevents any new events from executing in any of the + * tasks sharing a task manager with 'task'. + * + * The exclusive access must be relinquished by calling + * isc_task_endexclusive() before returning from the current event handler. + * + * Requires: + *\li 'task' is the calling task. + * + * Returns: + *\li #ISC_R_SUCCESS The current task now has exclusive access. + *\li #ISC_R_LOCKBUSY Another task has already requested exclusive + * access. + */ + +void +isc_task_endexclusive(isc_task_t *task); +/*%< + * Relinquish the exclusive access obtained by isc_task_beginexclusive(), + * allowing other tasks to execute. + * + * Requires: + *\li 'task' is the calling task, and has obtained + * exclusive access by calling isc_task_spl(). + */ + +void +isc_task_getcurrenttime(isc_task_t *task, isc_stdtime_t *t); +/*%< + * Provide the most recent timestamp on the task. The timestamp is considered + * as the "current time" in the second-order granularity. + * + * Requires: + *\li 'task' is a valid task. + *\li 't' is a valid non NULL pointer. + * + * Ensures: + *\li '*t' has the "current time". + */ + +/***** + ***** Task Manager. + *****/ + +isc_result_t +isc_taskmgr_create(isc_mem_t *mctx, unsigned int workers, + unsigned int default_quantum, isc_taskmgr_t **managerp); +/*%< + * Create a new task manager. + * + * Notes: + * + *\li 'workers' in the number of worker threads to create. In general, + * the value should be close to the number of processors in the system. + * The 'workers' value is advisory only. An attempt will be made to + * create 'workers' threads, but if at least one thread creation + * succeeds, isc_taskmgr_create() may return ISC_R_SUCCESS. + * + *\li If 'default_quantum' is non-zero, then it will be used as the default + * quantum value when tasks are created. If zero, then an implementation + * defined default quantum will be used. + * + * Requires: + * + *\li 'mctx' is a valid memory context. + * + *\li workers > 0 + * + *\li managerp != NULL && *managerp == NULL + * + * Ensures: + * + *\li On success, '*managerp' will be attached to the newly created task + * manager. + * + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY + *\li #ISC_R_NOTHREADS No threads could be created. + *\li #ISC_R_UNEXPECTED An unexpected error occurred. + */ + +void +isc_taskmgr_destroy(isc_taskmgr_t **managerp); +/*%< + * Destroy '*managerp'. + * + * Notes: + * + *\li Calling isc_taskmgr_destroy() will shutdown all tasks managed by + * *managerp that haven't already been shutdown. The call will block + * until all tasks have entered the done state. + * + *\li isc_taskmgr_destroy() must not be called by a task event action, + * because it would block forever waiting for the event action to + * complete. An event action that wants to cause task manager shutdown + * should request some non-event action thread of execution to do the + * shutdown, e.g. by signaling a condition variable or using + * isc_app_shutdown(). + * + *\li Task manager references are not reference counted, so the caller + * must ensure that no attempt will be made to use the manager after + * isc_taskmgr_destroy() returns. + * + * Requires: + * + *\li '*managerp' is a valid task manager. + * + *\li isc_taskmgr_destroy() has not be called previously on '*managerp'. + * + * Ensures: + * + *\li All resources used by the task manager, and any tasks it managed, + * have been freed. + */ + +#ifdef HAVE_LIBXML2 + +void +isc_taskmgr_renderxml(isc_taskmgr_t *mgr, xmlTextWriterPtr writer); + +#endif + +ISC_LANG_ENDDECLS + +#endif /* ISC_TASK_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/taskpool.h src.ntp/contrib/ntp/lib/isc/include/isc/taskpool.h --- src/contrib/ntp/lib/isc/include/isc/taskpool.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/taskpool.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,105 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: taskpool.h,v 1.15 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_TASKPOOL_H +#define ISC_TASKPOOL_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/taskpool.h + * \brief A task pool is a mechanism for sharing a small number of tasks + * among a large number of objects such that each object is + * assigned a unique task, but each task may be shared by several + * objects. + * + * Task pools are used to let objects that can exist in large + * numbers (e.g., zones) use tasks for synchronization without + * the memory overhead and unfair scheduling competition that + * could result from creating a separate task for each object. + */ + + +/*** + *** Imports. + ***/ + +#include +#include + +ISC_LANG_BEGINDECLS + +/***** + ***** Types. + *****/ + +typedef struct isc_taskpool isc_taskpool_t; + +/***** + ***** Functions. + *****/ + +isc_result_t +isc_taskpool_create(isc_taskmgr_t *tmgr, isc_mem_t *mctx, + unsigned int ntasks, unsigned int quantum, + isc_taskpool_t **poolp); +/*%< + * Create a task pool of "ntasks" tasks, each with quantum + * "quantum". + * + * Requires: + * + *\li 'tmgr' is a valid task manager. + * + *\li 'mctx' is a valid memory context. + * + *\li poolp != NULL && *poolp == NULL + * + * Ensures: + * + *\li On success, '*taskp' points to the new task pool. + * + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY + *\li #ISC_R_UNEXPECTED + */ + +void +isc_taskpool_gettask(isc_taskpool_t *pool, unsigned int hash, + isc_task_t **targetp); +/*%< + * Attach to the task corresponding to the hash value "hash". + */ + +void +isc_taskpool_destroy(isc_taskpool_t **poolp); +/*%< + * Destroy a task pool. The tasks in the pool are detached but not + * shut down. + * + * Requires: + * \li '*poolp' is a valid task pool. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_TASKPOOL_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/timer.h src.ntp/contrib/ntp/lib/isc/include/isc/timer.h --- src/contrib/ntp/lib/isc/include/isc/timer.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/timer.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,344 @@ +/* + * Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: timer.h,v 1.40 2008/06/23 23:47:11 tbox Exp $ */ + +#ifndef ISC_TIMER_H +#define ISC_TIMER_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/timer.h + * \brief Provides timers which are event sources in the task system. + * + * Three types of timers are supported: + * + *\li 'ticker' timers generate a periodic tick event. + * + *\li 'once' timers generate an idle timeout event if they are idle for too + * long, and generate a life timeout event if their lifetime expires. + * They are used to implement both (possibly expiring) idle timers and + * 'one-shot' timers. + * + *\li 'limited' timers generate a periodic tick event until they reach + * their lifetime when they generate a life timeout event. + * + *\li 'inactive' timers generate no events. + * + * Timers can change type. It is typical to create a timer as + * an 'inactive' timer and then change it into a 'ticker' or + * 'once' timer. + * + *\li MP: + * The module ensures appropriate synchronization of data structures it + * creates and manipulates. + * Clients of this module must not be holding a timer's task's lock when + * making a call that affects that timer. Failure to follow this rule + * can result in deadlock. + * The caller must ensure that isc_timermgr_destroy() is called only + * once for a given manager. + * + * \li Reliability: + * No anticipated impact. + * + * \li Resources: + * TBS + * + * \li Security: + * No anticipated impact. + * + * \li Standards: + * None. + */ + + +/*** + *** Imports + ***/ + +#include +#include +#include +#include +#include + +ISC_LANG_BEGINDECLS + +/*** + *** Types + ***/ + +/*% Timer Type */ +typedef enum { + isc_timertype_ticker = 0, /*%< Ticker */ + isc_timertype_once = 1, /*%< Once */ + isc_timertype_limited = 2, /*%< Limited */ + isc_timertype_inactive = 3 /*%< Inactive */ +} isc_timertype_t; + +typedef struct isc_timerevent { + struct isc_event common; + isc_time_t due; +} isc_timerevent_t; + +#define ISC_TIMEREVENT_FIRSTEVENT (ISC_EVENTCLASS_TIMER + 0) +#define ISC_TIMEREVENT_TICK (ISC_EVENTCLASS_TIMER + 1) +#define ISC_TIMEREVENT_IDLE (ISC_EVENTCLASS_TIMER + 2) +#define ISC_TIMEREVENT_LIFE (ISC_EVENTCLASS_TIMER + 3) +#define ISC_TIMEREVENT_LASTEVENT (ISC_EVENTCLASS_TIMER + 65535) + +/*** + *** Timer and Timer Manager Functions + *** + *** Note: all Ensures conditions apply only if the result is success for + *** those functions which return an isc_result_t. + ***/ + +isc_result_t +isc_timer_create(isc_timermgr_t *manager, + isc_timertype_t type, + isc_time_t *expires, + isc_interval_t *interval, + isc_task_t *task, + isc_taskaction_t action, + const void *arg, + isc_timer_t **timerp); +/*%< + * Create a new 'type' timer managed by 'manager'. The timers parameters + * are specified by 'expires' and 'interval'. Events will be posted to + * 'task' and when dispatched 'action' will be called with 'arg' as the + * arg value. The new timer is returned in 'timerp'. + * + * Notes: + * + *\li For ticker timers, the timer will generate a 'tick' event every + * 'interval' seconds. The value of 'expires' is ignored. + * + *\li For once timers, 'expires' specifies the time when a life timeout + * event should be generated. If 'expires' is 0 (the epoch), then no life + * timeout will be generated. 'interval' specifies how long the timer + * can be idle before it generates an idle timeout. If 0, then no + * idle timeout will be generated. + * + *\li If 'expires' is NULL, the epoch will be used. + * + * If 'interval' is NULL, the zero interval will be used. + * + * Requires: + * + *\li 'manager' is a valid manager + * + *\li 'task' is a valid task + * + *\li 'action' is a valid action + * + *\li 'expires' points to a valid time, or is NULL. + * + *\li 'interval' points to a valid interval, or is NULL. + * + *\li type == isc_timertype_inactive || + * ('expires' and 'interval' are not both 0) + * + *\li 'timerp' is a valid pointer, and *timerp == NULL + * + * Ensures: + * + *\li '*timerp' is attached to the newly created timer + * + *\li The timer is attached to the task + * + *\li An idle timeout will not be generated until at least Now + the + * timer's interval if 'timer' is a once timer with a non-zero + * interval. + * + * Returns: + * + *\li Success + *\li No memory + *\li Unexpected error + */ + +isc_result_t +isc_timer_reset(isc_timer_t *timer, + isc_timertype_t type, + isc_time_t *expires, + isc_interval_t *interval, + isc_boolean_t purge); +/*%< + * Change the timer's type, expires, and interval values to the given + * values. If 'purge' is TRUE, any pending events from this timer + * are purged from its task's event queue. + * + * Notes: + * + *\li If 'expires' is NULL, the epoch will be used. + * + *\li If 'interval' is NULL, the zero interval will be used. + * + * Requires: + * + *\li 'timer' is a valid timer + * + *\li The same requirements that isc_timer_create() imposes on 'type', + * 'expires' and 'interval' apply. + * + * Ensures: + * + *\li An idle timeout will not be generated until at least Now + the + * timer's interval if 'timer' is a once timer with a non-zero + * interval. + * + * Returns: + * + *\li Success + *\li No memory + *\li Unexpected error + */ + +isc_result_t +isc_timer_touch(isc_timer_t *timer); +/*%< + * Set the last-touched time of 'timer' to the current time. + * + * Requires: + * + *\li 'timer' is a valid once timer. + * + * Ensures: + * + *\li An idle timeout will not be generated until at least Now + the + * timer's interval if 'timer' is a once timer with a non-zero + * interval. + * + * Returns: + * + *\li Success + *\li Unexpected error + */ + +void +isc_timer_attach(isc_timer_t *timer, isc_timer_t **timerp); +/*%< + * Attach *timerp to timer. + * + * Requires: + * + *\li 'timer' is a valid timer. + * + *\li 'timerp' points to a NULL timer. + * + * Ensures: + * + *\li *timerp is attached to timer. + */ + +void +isc_timer_detach(isc_timer_t **timerp); +/*%< + * Detach *timerp from its timer. + * + * Requires: + * + *\li 'timerp' points to a valid timer. + * + * Ensures: + * + *\li *timerp is NULL. + * + *\li If '*timerp' is the last reference to the timer, + * then: + * + *\code + * The timer will be shutdown + * + * The timer will detach from its task + * + * All resources used by the timer have been freed + * + * Any events already posted by the timer will be purged. + * Therefore, if isc_timer_detach() is called in the context + * of the timer's task, it is guaranteed that no more + * timer event callbacks will run after the call. + *\endcode + */ + +isc_timertype_t +isc_timer_gettype(isc_timer_t *timer); +/*%< + * Return the timer type. + * + * Requires: + * + *\li 'timer' to be a valid timer. + */ + +isc_result_t +isc_timermgr_create(isc_mem_t *mctx, isc_timermgr_t **managerp); +/*%< + * Create a timer manager. + * + * Notes: + * + *\li All memory will be allocated in memory context 'mctx'. + * + * Requires: + * + *\li 'mctx' is a valid memory context. + * + *\li 'managerp' points to a NULL isc_timermgr_t. + * + * Ensures: + * + *\li '*managerp' is a valid isc_timermgr_t. + * + * Returns: + * + *\li Success + *\li No memory + *\li Unexpected error + */ + +void +isc_timermgr_destroy(isc_timermgr_t **managerp); +/*%< + * Destroy a timer manager. + * + * Notes: + * + *\li This routine blocks until there are no timers left in the manager, + * so if the caller holds any timer references using the manager, it + * must detach them before calling isc_timermgr_destroy() or it will + * block forever. + * + * Requires: + * + *\li '*managerp' is a valid isc_timermgr_t. + * + * Ensures: + * + *\li *managerp == NULL + * + *\li All resources used by the manager have been freed. + */ + +void isc_timermgr_poke(isc_timermgr_t *m); + +ISC_LANG_ENDDECLS + +#endif /* ISC_TIMER_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/types.h src.ntp/contrib/ntp/lib/isc/include/isc/types.h --- src/contrib/ntp/lib/isc/include/isc/types.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/types.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,124 @@ +/* + * Copyright (C) 2004-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: types.h,v 1.46.84.2 2009/01/29 23:47:44 tbox Exp $ */ + +#ifndef ISC_TYPES_H +#define ISC_TYPES_H 1 + +/*! \file isc/types.h + * \brief + * OS-specific types, from the OS-specific include directories. + */ +#include +#include + +/* + * XXXDCL should isc_boolean_t be moved here, requiring an explicit include + * of when ISC_TRUE/ISC_FALSE/ISC_TF() are desired? + */ +#include +/* + * XXXDCL This is just for ISC_LIST and ISC_LINK, but gets all of the other + * list macros too. + */ +#include + +/* Core Types. Alphabetized by defined type. */ + +typedef struct isc_bitstring isc_bitstring_t; /*%< Bitstring */ +typedef struct isc_buffer isc_buffer_t; /*%< Buffer */ +typedef ISC_LIST(isc_buffer_t) isc_bufferlist_t; /*%< Buffer List */ +typedef struct isc_constregion isc_constregion_t; /*%< Const region */ +typedef struct isc_consttextregion isc_consttextregion_t; /*%< Const Text Region */ +typedef struct isc_entropy isc_entropy_t; /*%< Entropy */ +typedef struct isc_entropysource isc_entropysource_t; /*%< Entropy Source */ +typedef struct isc_event isc_event_t; /*%< Event */ +typedef ISC_LIST(isc_event_t) isc_eventlist_t; /*%< Event List */ +typedef unsigned int isc_eventtype_t; /*%< Event Type */ +typedef isc_uint32_t isc_fsaccess_t; /*%< FS Access */ +typedef struct isc_hash isc_hash_t; /*%< Hash */ +typedef struct isc_httpd isc_httpd_t; /*%< HTTP client */ +typedef void (isc_httpdfree_t)(isc_buffer_t *, void *); /*%< HTTP free function */ +typedef struct isc_httpdmgr isc_httpdmgr_t; /*%< HTTP manager */ +typedef struct isc_httpdurl isc_httpdurl_t; /*%< HTTP URL */ +typedef void (isc_httpdondestroy_t)(void *); /*%< Callback on destroying httpd */ +typedef struct isc_interface isc_interface_t; /*%< Interface */ +typedef struct isc_interfaceiter isc_interfaceiter_t; /*%< Interface Iterator */ +typedef struct isc_interval isc_interval_t; /*%< Interval */ +typedef struct isc_lex isc_lex_t; /*%< Lex */ +typedef struct isc_log isc_log_t; /*%< Log */ +typedef struct isc_logcategory isc_logcategory_t; /*%< Log Category */ +typedef struct isc_logconfig isc_logconfig_t; /*%< Log Configuration */ +typedef struct isc_logmodule isc_logmodule_t; /*%< Log Module */ +typedef struct isc_mem isc_mem_t; /*%< Memory */ +typedef struct isc_mempool isc_mempool_t; /*%< Memory Pool */ +typedef struct isc_msgcat isc_msgcat_t; /*%< Message Catalog */ +typedef struct isc_ondestroy isc_ondestroy_t; /*%< On Destroy */ +typedef struct isc_netaddr isc_netaddr_t; /*%< Net Address */ +typedef struct isc_portset isc_portset_t; /*%< Port Set */ +typedef struct isc_quota isc_quota_t; /*%< Quota */ +typedef struct isc_random isc_random_t; /*%< Random */ +typedef struct isc_ratelimiter isc_ratelimiter_t; /*%< Rate Limiter */ +typedef struct isc_region isc_region_t; /*%< Region */ +typedef isc_uint64_t isc_resourcevalue_t; /*%< Resource Value */ +typedef unsigned int isc_result_t; /*%< Result */ +typedef struct isc_rwlock isc_rwlock_t; /*%< Read Write Lock */ +typedef struct isc_sockaddr isc_sockaddr_t; /*%< Socket Address */ +typedef struct isc_socket isc_socket_t; /*%< Socket */ +typedef struct isc_socketevent isc_socketevent_t; /*%< Socket Event */ +typedef struct isc_socketmgr isc_socketmgr_t; /*%< Socket Manager */ +typedef struct isc_stats isc_stats_t; /*%< Statistics */ +typedef int isc_statscounter_t; /*%< Statistics Counter */ +typedef struct isc_symtab isc_symtab_t; /*%< Symbol Table */ +typedef struct isc_task isc_task_t; /*%< Task */ +typedef ISC_LIST(isc_task_t) isc_tasklist_t; /*%< Task List */ +typedef struct isc_taskmgr isc_taskmgr_t; /*%< Task Manager */ +typedef struct isc_textregion isc_textregion_t; /*%< Text Region */ +typedef struct isc_time isc_time_t; /*%< Time */ +typedef struct isc_timer isc_timer_t; /*%< Timer */ +typedef struct isc_timermgr isc_timermgr_t; /*%< Timer Manager */ + +typedef void (*isc_taskaction_t)(isc_task_t *, isc_event_t *); +typedef int (*isc_sockfdwatch_t)(isc_task_t *, isc_socket_t *, void *); + +/* The following cannot be listed alphabetically due to forward reference */ +typedef isc_result_t (isc_httpdaction_t)(const char *url, + const char *querystring, + void *arg, + unsigned int *retcode, + const char **retmsg, + const char **mimetype, + isc_buffer_t *body, + isc_httpdfree_t **freecb, + void **freecb_args); +typedef isc_boolean_t (isc_httpdclientok_t)(const isc_sockaddr_t *, void *); + +/*% Resource */ +typedef enum { + isc_resource_coresize = 1, + isc_resource_cputime, + isc_resource_datasize, + isc_resource_filesize, + isc_resource_lockedmemory, + isc_resource_openfiles, + isc_resource_processes, + isc_resource_residentsize, + isc_resource_stacksize +} isc_resource_t; + +#endif /* ISC_TYPES_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/util.h src.ntp/contrib/ntp/lib/isc/include/isc/util.h --- src/contrib/ntp/lib/isc/include/isc/util.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/util.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,233 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: util.h,v 1.30 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_UTIL_H +#define ISC_UTIL_H 1 + +/*! \file isc/util.h + * NOTE: + * + * This file is not to be included from any (or other) library + * files. + * + * \brief + * Including this file puts several macros in your name space that are + * not protected (as all the other ISC functions/macros do) by prepending + * ISC_ or isc_ to the name. + */ + +/*** + *** General Macros. + ***/ + +/*% + * Use this to hide unused function arguments. + * \code + * int + * foo(char *bar) + * { + * UNUSED(bar); + * } + * \endcode + */ +#define UNUSED(x) (void)(x) + +#define ISC_MAX(a, b) ((a) > (b) ? (a) : (b)) +#define ISC_MIN(a, b) ((a) < (b) ? (a) : (b)) + +/*% + * Use this to remove the const qualifier of a variable to assign it to + * a non-const variable or pass it as a non-const function argument ... + * but only when you are sure it won't then be changed! + * This is necessary to sometimes shut up some compilers + * (as with gcc -Wcast-qual) when there is just no other good way to avoid the + * situation. + */ +#define DE_CONST(konst, var) \ + do { \ + union { const void *k; void *v; } _u; \ + _u.k = konst; \ + var = _u.v; \ + } while (0) + +/*% + * Use this in translation units that would otherwise be empty, to + * suppress compiler warnings. + */ +#define EMPTY_TRANSLATION_UNIT static void isc__empty(void) { isc__empty(); } + +/*% + * We use macros instead of calling the routines directly because + * the capital letters make the locking stand out. + * We RUNTIME_CHECK for success since in general there's no way + * for us to continue if they fail. + */ + +#ifdef ISC_UTIL_TRACEON +#define ISC_UTIL_TRACE(a) a +#include /* Required for fprintf/stderr when tracing. */ +#include /* Required for isc_msgcat when tracing. */ +#else +#define ISC_UTIL_TRACE(a) +#endif + +#include /* Contractual promise. */ + +#define LOCK(lp) do { \ + ISC_UTIL_TRACE(fprintf(stderr, "%s %p %s %d\n", \ + isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ + ISC_MSG_LOCKING, "LOCKING"), \ + (lp), __FILE__, __LINE__)); \ + RUNTIME_CHECK(isc_mutex_lock((lp)) == ISC_R_SUCCESS); \ + ISC_UTIL_TRACE(fprintf(stderr, "%s %p %s %d\n", \ + isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ + ISC_MSG_LOCKED, "LOCKED"), \ + (lp), __FILE__, __LINE__)); \ + } while (0) +#define UNLOCK(lp) do { \ + RUNTIME_CHECK(isc_mutex_unlock((lp)) == ISC_R_SUCCESS); \ + ISC_UTIL_TRACE(fprintf(stderr, "%s %p %s %d\n", \ + isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ + ISC_MSG_UNLOCKED, "UNLOCKED"), \ + (lp), __FILE__, __LINE__)); \ + } while (0) +#define ISLOCKED(lp) (1) +#define DESTROYLOCK(lp) \ + RUNTIME_CHECK(isc_mutex_destroy((lp)) == ISC_R_SUCCESS) + + +#define BROADCAST(cvp) do { \ + ISC_UTIL_TRACE(fprintf(stderr, "%s %p %s %d\n", \ + isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ + ISC_MSG_BROADCAST, "BROADCAST"),\ + (cvp), __FILE__, __LINE__)); \ + RUNTIME_CHECK(isc_condition_broadcast((cvp)) == ISC_R_SUCCESS); \ + } while (0) +#define SIGNAL(cvp) do { \ + ISC_UTIL_TRACE(fprintf(stderr, "%s %p %s %d\n", \ + isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ + ISC_MSG_SIGNAL, "SIGNAL"), \ + (cvp), __FILE__, __LINE__)); \ + RUNTIME_CHECK(isc_condition_signal((cvp)) == ISC_R_SUCCESS); \ + } while (0) +#define WAIT(cvp, lp) do { \ + ISC_UTIL_TRACE(fprintf(stderr, "%s %p %s %p %s %d\n", \ + isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ + ISC_MSG_UTILWAIT, "WAIT"), \ + (cvp), \ + isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ + ISC_MSG_LOCK, "LOCK"), \ + (lp), __FILE__, __LINE__)); \ + RUNTIME_CHECK(isc_condition_wait((cvp), (lp)) == ISC_R_SUCCESS); \ + ISC_UTIL_TRACE(fprintf(stderr, "%s %p %s %p %s %d\n", \ + isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ + ISC_MSG_WAITED, "WAITED"), \ + (cvp), \ + isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ + ISC_MSG_LOCKED, "LOCKED"), \ + (lp), __FILE__, __LINE__)); \ + } while (0) + +/* + * isc_condition_waituntil can return ISC_R_TIMEDOUT, so we + * don't RUNTIME_CHECK the result. + * + * XXX Also, can't really debug this then... + */ + +#define WAITUNTIL(cvp, lp, tp) \ + isc_condition_waituntil((cvp), (lp), (tp)) + +#define RWLOCK(lp, t) do { \ + ISC_UTIL_TRACE(fprintf(stderr, "%s %p, %d %s %d\n", \ + isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ + ISC_MSG_RWLOCK, "RWLOCK"), \ + (lp), (t), __FILE__, __LINE__)); \ + RUNTIME_CHECK(isc_rwlock_lock((lp), (t)) == ISC_R_SUCCESS); \ + ISC_UTIL_TRACE(fprintf(stderr, "%s %p, %d %s %d\n", \ + isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ + ISC_MSG_RWLOCKED, "RWLOCKED"), \ + (lp), (t), __FILE__, __LINE__)); \ + } while (0) +#define RWUNLOCK(lp, t) do { \ + ISC_UTIL_TRACE(fprintf(stderr, "%s %p, %d %s %d\n", \ + isc_msgcat_get(isc_msgcat, ISC_MSGSET_UTIL, \ + ISC_MSG_RWUNLOCK, "RWUNLOCK"), \ + (lp), (t), __FILE__, __LINE__)); \ + RUNTIME_CHECK(isc_rwlock_unlock((lp), (t)) == ISC_R_SUCCESS); \ + } while (0) + +#define DESTROYMUTEXBLOCK(bp, n) \ + RUNTIME_CHECK(isc_mutexblock_destroy((bp), (n)) == ISC_R_SUCCESS) + +/* + * List Macros. + */ +#include /* Contractual promise. */ + +#define LIST(type) ISC_LIST(type) +#define INIT_LIST(type) ISC_LIST_INIT(type) +#define LINK(type) ISC_LINK(type) +#define INIT_LINK(elt, link) ISC_LINK_INIT(elt, link) +#define HEAD(list) ISC_LIST_HEAD(list) +#define TAIL(list) ISC_LIST_TAIL(list) +#define EMPTY(list) ISC_LIST_EMPTY(list) +#define PREV(elt, link) ISC_LIST_PREV(elt, link) +#define NEXT(elt, link) ISC_LIST_NEXT(elt, link) +#define APPEND(list, elt, link) ISC_LIST_APPEND(list, elt, link) +#define PREPEND(list, elt, link) ISC_LIST_PREPEND(list, elt, link) +#define UNLINK(list, elt, link) ISC_LIST_UNLINK(list, elt, link) +#define ENQUEUE(list, elt, link) ISC_LIST_APPEND(list, elt, link) +#define DEQUEUE(list, elt, link) ISC_LIST_UNLINK(list, elt, link) +#define INSERTBEFORE(li, b, e, ln) ISC_LIST_INSERTBEFORE(li, b, e, ln) +#define INSERTAFTER(li, a, e, ln) ISC_LIST_INSERTAFTER(li, a, e, ln) +#define APPENDLIST(list1, list2, link) ISC_LIST_APPENDLIST(list1, list2, link) + +/* + * Assertions + */ +#include /* Contractual promise. */ + +/*% Require Assertion */ +#define REQUIRE(e) ISC_REQUIRE(e) +/*% Ensure Assertion */ +#define ENSURE(e) ISC_ENSURE(e) +/*% Insist Assertion */ +#define INSIST(e) ISC_INSIST(e) +/*% Invariant Assertion */ +#define INVARIANT(e) ISC_INVARIANT(e) + +/* + * Errors + */ +#include /* Contractual promise. */ + +/*% Unexpected Error */ +#define UNEXPECTED_ERROR isc_error_unexpected +/*% Fatal Error */ +#define FATAL_ERROR isc_error_fatal +/*% Runtime Check */ +#define RUNTIME_CHECK(cond) ISC_ERROR_RUNTIMECHECK(cond) + +/*% + * Time + */ +#define TIME_NOW(tp) RUNTIME_CHECK(isc_time_now((tp)) == ISC_R_SUCCESS) + +#endif /* ISC_UTIL_H */ diff -urN src/contrib/ntp/lib/isc/include/isc/version.h src.ntp/contrib/ntp/lib/isc/include/isc/version.h --- src/contrib/ntp/lib/isc/include/isc/version.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/version.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,28 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: version.h,v 1.9 2007/06/19 23:47:18 tbox Exp $ */ + +/*! \file isc/version.h */ + +#include + +LIBISC_EXTERNAL_DATA extern const char isc_version[]; + +LIBISC_EXTERNAL_DATA extern const unsigned int isc_libinterface; +LIBISC_EXTERNAL_DATA extern const unsigned int isc_librevision; +LIBISC_EXTERNAL_DATA extern const unsigned int isc_libage; diff -urN src/contrib/ntp/lib/isc/include/isc/xml.h src.ntp/contrib/ntp/lib/isc/include/isc/xml.h --- src/contrib/ntp/lib/isc/include/isc/xml.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/include/isc/xml.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,41 @@ +/* + * Copyright (C) 2006, 2007 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: xml.h,v 1.4 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_XML_H +#define ISC_XML_H 1 + +/* + * This file is here mostly to make it easy to add additional libxml header + * files as needed across all the users of this file. Rather than place + * these libxml includes in each file, one include makes it easy to handle + * the ifdef as well as adding the ability to add additional functions + * which may be useful. + */ + +#ifdef HAVE_LIBXML2 +#include +#include +#endif + +#define ISC_XMLCHAR (const xmlChar *) + +#define ISC_XML_RENDERCONFIG 0x00000001 /* render config data */ +#define ISC_XML_RENDERSTATS 0x00000002 /* render stats */ +#define ISC_XML_RENDERALL 0x000000ff /* render everything */ + +#endif /* ISC_XML_H */ diff -urN src/contrib/ntp/lib/isc/inet_aton.c src.ntp/contrib/ntp/lib/isc/inet_aton.c --- src/contrib/ntp/lib/isc/inet_aton.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/inet_aton.c 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,196 @@ +/* + * Portions Copyright (C) 2004, 2005, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Portions Copyright (C) 1996-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* + * Copyright (c) 1983, 1990, 1993 + * The Regents of the University of California. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +/* + * Portions Copyright (c) 1993 by Digital Equipment Corporation. + * + * Permission to use, copy, modify, and distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies, and that + * the name of Digital Equipment Corporation not be used in advertising or + * publicity pertaining to distribution of the document or software without + * specific, written prior permission. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND DIGITAL EQUIPMENT CORP. DISCLAIMS ALL + * WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL DIGITAL EQUIPMENT + * CORPORATION BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL + * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR + * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS + * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS + * SOFTWARE. + */ +/*! \file */ + +#if defined(LIBC_SCCS) && !defined(lint) +static char sccsid[] = "@(#)inet_addr.c 8.1 (Berkeley) 6/17/93"; +static char rcsid[] = "$Id: inet_aton.c,v 1.21.332.2 2009/03/05 23:47:03 tbox Exp $"; +#endif /* LIBC_SCCS and not lint */ + +#include + +#include +#include /* Required for NULL. */ + +#include +#include + +/*% + * Check whether "cp" is a valid ascii representation + * of an Internet address and convert to a binary address. + * Returns 1 if the address is valid, 0 if not. + * This replaces inet_addr, the return value from which + * cannot distinguish between failure and a local broadcast address. + */ +int +isc_net_aton(const char *cp, struct in_addr *addr) { + unsigned long val; + int base, n; + unsigned char c; + isc_uint8_t parts[4]; + isc_uint8_t *pp = parts; + int digit; + + c = *cp; + for (;;) { + /* + * Collect number up to ``.''. + * Values are specified as for C: + * 0x=hex, 0=octal, isdigit=decimal. + */ + if (!isdigit(c & 0xff)) + return (0); + val = 0; base = 10; digit = 0; + if (c == '0') { + c = *++cp; + if (c == 'x' || c == 'X') + base = 16, c = *++cp; + else { + base = 8; + digit = 1; + } + } + for (;;) { + /* + * isascii() is valid for all integer values, and + * when it is true, c is known to be in scope + * for isdigit(). No cast necessary. Similar + * comment applies for later ctype uses. + */ + if (isascii(c) && isdigit(c)) { + if (base == 8 && (c == '8' || c == '9')) + return (0); + val = (val * base) + (c - '0'); + c = *++cp; + digit = 1; + } else if (base == 16 && isascii(c) && isxdigit(c)) { + val = (val << 4) | + (c + 10 - (islower(c) ? 'a' : 'A')); + c = *++cp; + digit = 1; + } else + break; + } + if (c == '.') { + /* + * Internet format: + * a.b.c.d + * a.b.c (with c treated as 16 bits) + * a.b (with b treated as 24 bits) + */ + if (pp >= parts + 3 || val > 0xffU) + return (0); + *pp++ = (isc_uint8_t)val; + c = *++cp; + } else + break; + } + /* + * Check for trailing characters. + */ + if (c != '\0' && (!isascii(c) || !isspace(c))) + return (0); + /* + * Did we get a valid digit? + */ + if (!digit) + return (0); + /* + * Concoct the address according to + * the number of parts specified. + */ + n = pp - parts + 1; + switch (n) { + case 1: /* a -- 32 bits */ + break; + + case 2: /* a.b -- 8.24 bits */ + if (val > 0xffffffU) + return (0); + val |= parts[0] << 24; + break; + + case 3: /* a.b.c -- 8.8.16 bits */ + if (val > 0xffffU) + return (0); + val |= (parts[0] << 24) | (parts[1] << 16); + break; + + case 4: /* a.b.c.d -- 8.8.8.8 bits */ + if (val > 0xffU) + return (0); + val |= (parts[0] << 24) | (parts[1] << 16) | (parts[2] << 8); + break; + } + if (addr != NULL) + addr->s_addr = htonl(val); + + return (1); +} diff -urN src/contrib/ntp/lib/isc/inet_ntop.c src.ntp/contrib/ntp/lib/isc/inet_ntop.c --- src/contrib/ntp/lib/isc/inet_ntop.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/inet_ntop.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,202 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1996-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/*! \file */ + +#if defined(LIBC_SCCS) && !defined(lint) +static char rcsid[] = + "$Id: inet_ntop.c,v 1.19 2007/06/19 23:47:17 tbox Exp $"; +#endif /* LIBC_SCCS and not lint */ + +#include + +#include +#include +#include + +#include +#include + +#include "ntp_sprintf.h" /* NTP local change, helps SunOS 4 */ + +#define NS_INT16SZ 2 +#define NS_IN6ADDRSZ 16 + +/* + * WARNING: Don't even consider trying to compile this on a system where + * sizeof(int) < 4. sizeof(int) > 4 is fine; all the world's not a VAX. + */ + +static const char *inet_ntop4(const unsigned char *src, char *dst, + size_t size); + +#ifdef AF_INET6 +static const char *inet_ntop6(const unsigned char *src, char *dst, + size_t size); +#endif + +/*! char * + * isc_net_ntop(af, src, dst, size) + * convert a network format address to presentation format. + * \return + * pointer to presentation format address (`dst'), or NULL (see errno). + * \author + * Paul Vixie, 1996. + */ +const char * +isc_net_ntop(int af, const void *src, char *dst, size_t size) +{ + switch (af) { + case AF_INET: + return (inet_ntop4(src, dst, size)); +#ifdef AF_INET6 + case AF_INET6: + return (inet_ntop6(src, dst, size)); +#endif + default: + errno = EAFNOSUPPORT; + return (NULL); + } + /* NOTREACHED */ +} + +/*! const char * + * inet_ntop4(src, dst, size) + * format an IPv4 address + * \return + * `dst' (as a const) + * \note + * (1) uses no statics + * \note + * (2) takes a unsigned char* not an in_addr as input + * \author + * Paul Vixie, 1996. + */ +static const char * +inet_ntop4(const unsigned char *src, char *dst, size_t size) +{ + static const char *fmt = "%u.%u.%u.%u"; + char tmp[sizeof("255.255.255.255")]; + + /* NTP local change to use SNPRINTF() macro for SunOS4 compat */ + if (SNPRINTF((tmp, sizeof(tmp), fmt, src[0], src[1], src[2], + src[3])) >= size) + { + errno = ENOSPC; + return (NULL); + } + strcpy(dst, tmp); + + return (dst); +} + +/*! const char * + * isc_inet_ntop6(src, dst, size) + * convert IPv6 binary address into presentation (printable) format + * \author + * Paul Vixie, 1996. + */ +#ifdef AF_INET6 +static const char * +inet_ntop6(const unsigned char *src, char *dst, size_t size) +{ + /* + * Note that int32_t and int16_t need only be "at least" large enough + * to contain a value of the specified size. On some systems, like + * Crays, there is no such thing as an integer variable with 16 bits. + * Keep this in mind if you think this function should have been coded + * to use pointer overlays. All the world's not a VAX. + */ + char tmp[sizeof("ffff:ffff:ffff:ffff:ffff:ffff:255.255.255.255")], *tp; + struct { int base, len; } best, cur; + unsigned int words[NS_IN6ADDRSZ / NS_INT16SZ]; + int i; + + /* + * Preprocess: + * Copy the input (bytewise) array into a wordwise array. + * Find the longest run of 0x00's in src[] for :: shorthanding. + */ + memset(words, '\0', sizeof(words)); + for (i = 0; i < NS_IN6ADDRSZ; i++) + words[i / 2] |= (src[i] << ((1 - (i % 2)) << 3)); + best.base = -1; + cur.base = -1; + for (i = 0; i < (NS_IN6ADDRSZ / NS_INT16SZ); i++) { + if (words[i] == 0) { + if (cur.base == -1) + cur.base = i, cur.len = 1; + else + cur.len++; + } else { + if (cur.base != -1) { + if (best.base == -1 || cur.len > best.len) + best = cur; + cur.base = -1; + } + } + } + if (cur.base != -1) { + if (best.base == -1 || cur.len > best.len) + best = cur; + } + if (best.base != -1 && best.len < 2) + best.base = -1; + + /* + * Format the result. + */ + tp = tmp; + for (i = 0; i < (NS_IN6ADDRSZ / NS_INT16SZ); i++) { + /* Are we inside the best run of 0x00's? */ + if (best.base != -1 && i >= best.base && + i < (best.base + best.len)) { + if (i == best.base) + *tp++ = ':'; + continue; + } + /* Are we following an initial run of 0x00s or any real hex? */ + if (i != 0) + *tp++ = ':'; + /* Is this address an encapsulated IPv4? */ + if (i == 6 && best.base == 0 && + (best.len == 6 || (best.len == 5 && words[5] == 0xffff))) { + if (!inet_ntop4(src+12, tp, + sizeof(tmp) - (tp - tmp))) + return (NULL); + tp += strlen(tp); + break; + } + tp += SPRINTF((tp, "%x", words[i])); /* NTP local change */ + } + /* Was it a trailing run of 0x00's? */ + if (best.base != -1 && (best.base + best.len) == + (NS_IN6ADDRSZ / NS_INT16SZ)) + *tp++ = ':'; + *tp++ = '\0'; + + /* + * Check for overflow, copy, and we're done. + */ + if ((size_t)(tp - tmp) > size) { + errno = ENOSPC; + return (NULL); + } + strcpy(dst, tmp); + return (dst); +} +#endif /* AF_INET6 */ diff -urN src/contrib/ntp/lib/isc/inet_pton.c src.ntp/contrib/ntp/lib/isc/inet_pton.c --- src/contrib/ntp/lib/isc/inet_pton.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/inet_pton.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,214 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1996-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/*! \file */ + +#if defined(LIBC_SCCS) && !defined(lint) +static char rcsid[] = + "$Id: inet_pton.c,v 1.19 2007/06/19 23:47:17 tbox Exp $"; +#endif /* LIBC_SCCS and not lint */ + +#include + +#include +#include + +#include + +/*% INT16 Size */ +#define NS_INT16SZ 2 +/*% IPv4 Address Size */ +#define NS_INADDRSZ 4 +/*% IPv6 Address Size */ +#define NS_IN6ADDRSZ 16 + +/* + * WARNING: Don't even consider trying to compile this on a system where + * sizeof(int) < 4. sizeof(int) > 4 is fine; all the world's not a VAX. + */ + +static int inet_pton4(const char *src, unsigned char *dst); +static int inet_pton6(const char *src, unsigned char *dst); + +/*% + * convert from presentation format (which usually means ASCII printable) + * to network format (which is usually some kind of binary format). + * \return + * 1 if the address was valid for the specified address family + * 0 if the address wasn't valid (`dst' is untouched in this case) + * -1 if some other error occurred (`dst' is untouched in this case, too) + * \author + * Paul Vixie, 1996. + */ +int +isc_net_pton(int af, const char *src, void *dst) { + switch (af) { + case AF_INET: + return (inet_pton4(src, dst)); + case AF_INET6: + return (inet_pton6(src, dst)); + default: + errno = EAFNOSUPPORT; + return (-1); + } + /* NOTREACHED */ +} + +/*!\fn static int inet_pton4(const char *src, unsigned char *dst) + * \brief + * like inet_aton() but without all the hexadecimal and shorthand. + * \return + * 1 if `src' is a valid dotted quad, else 0. + * \note + * does not touch `dst' unless it's returning 1. + * \author + * Paul Vixie, 1996. + */ +static int +inet_pton4(const char *src, unsigned char *dst) { + static const char digits[] = "0123456789"; + int saw_digit, octets, ch; + unsigned char tmp[NS_INADDRSZ], *tp; + + saw_digit = 0; + octets = 0; + *(tp = tmp) = 0; + while ((ch = *src++) != '\0') { + const char *pch; + + if ((pch = strchr(digits, ch)) != NULL) { + unsigned int new = *tp * 10 + (pch - digits); + + if (saw_digit && *tp == 0) + return (0); + if (new > 255) + return (0); + *tp = new; + if (!saw_digit) { + if (++octets > 4) + return (0); + saw_digit = 1; + } + } else if (ch == '.' && saw_digit) { + if (octets == 4) + return (0); + *++tp = 0; + saw_digit = 0; + } else + return (0); + } + if (octets < 4) + return (0); + memcpy(dst, tmp, NS_INADDRSZ); + return (1); +} + +/*% + * convert presentation level address to network order binary form. + * \return + * 1 if `src' is a valid [RFC1884 2.2] address, else 0. + * \note + * (1) does not touch `dst' unless it's returning 1. + * \note + * (2) :: in a full address is silently ignored. + * \author + * inspired by Mark Andrews. + * \author + * Paul Vixie, 1996. + */ +static int +inet_pton6(const char *src, unsigned char *dst) { + static const char xdigits_l[] = "0123456789abcdef", + xdigits_u[] = "0123456789ABCDEF"; + unsigned char tmp[NS_IN6ADDRSZ], *tp, *endp, *colonp; + const char *xdigits, *curtok; + int ch, seen_xdigits; + unsigned int val; + + memset((tp = tmp), '\0', NS_IN6ADDRSZ); + endp = tp + NS_IN6ADDRSZ; + colonp = NULL; + /* Leading :: requires some special handling. */ + if (*src == ':') + if (*++src != ':') + return (0); + curtok = src; + seen_xdigits = 0; + val = 0; + while ((ch = *src++) != '\0') { + const char *pch; + + if ((pch = strchr((xdigits = xdigits_l), ch)) == NULL) + pch = strchr((xdigits = xdigits_u), ch); + if (pch != NULL) { + val <<= 4; + val |= (pch - xdigits); + if (++seen_xdigits > 4) + return (0); + continue; + } + if (ch == ':') { + curtok = src; + if (!seen_xdigits) { + if (colonp) + return (0); + colonp = tp; + continue; + } + if (tp + NS_INT16SZ > endp) + return (0); + *tp++ = (unsigned char) (val >> 8) & 0xff; + *tp++ = (unsigned char) val & 0xff; + seen_xdigits = 0; + val = 0; + continue; + } + if (ch == '.' && ((tp + NS_INADDRSZ) <= endp) && + inet_pton4(curtok, tp) > 0) { + tp += NS_INADDRSZ; + seen_xdigits = 0; + break; /* '\0' was seen by inet_pton4(). */ + } + return (0); + } + if (seen_xdigits) { + if (tp + NS_INT16SZ > endp) + return (0); + *tp++ = (unsigned char) (val >> 8) & 0xff; + *tp++ = (unsigned char) val & 0xff; + } + if (colonp != NULL) { + /* + * Since some memmove()'s erroneously fail to handle + * overlapping regions, we'll do the shift by hand. + */ + const int n = tp - colonp; + int i; + + if (tp == endp) + return (0); + for (i = 1; i <= n; i++) { + endp[- i] = colonp[n - i]; + colonp[n - i] = 0; + } + tp = endp; + } + if (tp != endp) + return (0); + memcpy(dst, tmp, NS_IN6ADDRSZ); + return (1); +} diff -urN src/contrib/ntp/lib/isc/iterated_hash.c src.ntp/contrib/ntp/lib/isc/iterated_hash.c --- src/contrib/ntp/lib/isc/iterated_hash.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/iterated_hash.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,48 @@ +/* + * Copyright (C) 2006, 2008, 2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: iterated_hash.c,v 1.4.48.2 2009/02/18 23:47:12 tbox Exp $ */ + +#include "config.h" + +#include + +#include +#include + +int +isc_iterated_hash(unsigned char out[ISC_SHA1_DIGESTLENGTH], + unsigned int hashalg, int iterations, + const unsigned char *salt, int saltlength, + const unsigned char *in, int inlength) +{ + isc_sha1_t ctx; + int n = 0; + + if (hashalg != 1) + return (0); + + do { + isc_sha1_init(&ctx); + isc_sha1_update(&ctx, in, inlength); + isc_sha1_update(&ctx, salt, saltlength); + isc_sha1_final(&ctx, out); + in = out; + inlength = ISC_SHA1_DIGESTLENGTH; + } while (n++ < iterations); + + return (ISC_SHA1_DIGESTLENGTH); +} diff -urN src/contrib/ntp/lib/isc/lex.c src.ntp/contrib/ntp/lib/isc/lex.c --- src/contrib/ntp/lib/isc/lex.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/lex.c 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,959 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: lex.c,v 1.86 2007/09/17 09:56:29 shane Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +typedef struct inputsource { + isc_result_t result; + isc_boolean_t is_file; + isc_boolean_t need_close; + isc_boolean_t at_eof; + isc_buffer_t * pushback; + unsigned int ignored; + void * input; + char * name; + unsigned long line; + unsigned long saved_line; + ISC_LINK(struct inputsource) link; +} inputsource; + +#define LEX_MAGIC ISC_MAGIC('L', 'e', 'x', '!') +#define VALID_LEX(l) ISC_MAGIC_VALID(l, LEX_MAGIC) + +struct isc_lex { + /* Unlocked. */ + unsigned int magic; + isc_mem_t * mctx; + size_t max_token; + char * data; + unsigned int comments; + isc_boolean_t comment_ok; + isc_boolean_t last_was_eol; + unsigned int paren_count; + unsigned int saved_paren_count; + isc_lexspecials_t specials; + LIST(struct inputsource) sources; +}; + +static inline isc_result_t +grow_data(isc_lex_t *lex, size_t *remainingp, char **currp, char **prevp) { + char *new; + + new = isc_mem_get(lex->mctx, lex->max_token * 2 + 1); + if (new == NULL) + return (ISC_R_NOMEMORY); + memcpy(new, lex->data, lex->max_token + 1); + *currp = new + (*currp - lex->data); + if (*prevp != NULL) + *prevp = new + (*prevp - lex->data); + isc_mem_put(lex->mctx, lex->data, lex->max_token + 1); + lex->data = new; + *remainingp += lex->max_token; + lex->max_token *= 2; + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_lex_create(isc_mem_t *mctx, size_t max_token, isc_lex_t **lexp) { + isc_lex_t *lex; + + /* + * Create a lexer. + */ + + REQUIRE(lexp != NULL && *lexp == NULL); + REQUIRE(max_token > 0U); + + lex = isc_mem_get(mctx, sizeof(*lex)); + if (lex == NULL) + return (ISC_R_NOMEMORY); + lex->data = isc_mem_get(mctx, max_token + 1); + if (lex->data == NULL) { + isc_mem_put(mctx, lex, sizeof(*lex)); + return (ISC_R_NOMEMORY); + } + lex->mctx = mctx; + lex->max_token = max_token; + lex->comments = 0; + lex->comment_ok = ISC_TRUE; + lex->last_was_eol = ISC_TRUE; + lex->paren_count = 0; + lex->saved_paren_count = 0; + memset(lex->specials, 0, 256); + INIT_LIST(lex->sources); + lex->magic = LEX_MAGIC; + + *lexp = lex; + + return (ISC_R_SUCCESS); +} + +void +isc_lex_destroy(isc_lex_t **lexp) { + isc_lex_t *lex; + + /* + * Destroy the lexer. + */ + + REQUIRE(lexp != NULL); + lex = *lexp; + REQUIRE(VALID_LEX(lex)); + + while (!EMPTY(lex->sources)) + RUNTIME_CHECK(isc_lex_close(lex) == ISC_R_SUCCESS); + if (lex->data != NULL) + isc_mem_put(lex->mctx, lex->data, lex->max_token + 1); + lex->magic = 0; + isc_mem_put(lex->mctx, lex, sizeof(*lex)); + + *lexp = NULL; +} + +unsigned int +isc_lex_getcomments(isc_lex_t *lex) { + /* + * Return the current lexer commenting styles. + */ + + REQUIRE(VALID_LEX(lex)); + + return (lex->comments); +} + +void +isc_lex_setcomments(isc_lex_t *lex, unsigned int comments) { + /* + * Set allowed lexer commenting styles. + */ + + REQUIRE(VALID_LEX(lex)); + + lex->comments = comments; +} + +void +isc_lex_getspecials(isc_lex_t *lex, isc_lexspecials_t specials) { + /* + * Put the current list of specials into 'specials'. + */ + + REQUIRE(VALID_LEX(lex)); + + memcpy(specials, lex->specials, 256); +} + +void +isc_lex_setspecials(isc_lex_t *lex, isc_lexspecials_t specials) { + /* + * The characters in 'specials' are returned as tokens. Along with + * whitespace, they delimit strings and numbers. + */ + + REQUIRE(VALID_LEX(lex)); + + memcpy(lex->specials, specials, 256); +} + +static inline isc_result_t +new_source(isc_lex_t *lex, isc_boolean_t is_file, isc_boolean_t need_close, + void *input, const char *name) +{ + inputsource *source; + isc_result_t result; + + source = isc_mem_get(lex->mctx, sizeof(*source)); + if (source == NULL) + return (ISC_R_NOMEMORY); + source->result = ISC_R_SUCCESS; + source->is_file = is_file; + source->need_close = need_close; + source->at_eof = ISC_FALSE; + source->input = input; + source->name = isc_mem_strdup(lex->mctx, name); + if (source->name == NULL) { + isc_mem_put(lex->mctx, source, sizeof(*source)); + return (ISC_R_NOMEMORY); + } + source->pushback = NULL; + result = isc_buffer_allocate(lex->mctx, &source->pushback, + lex->max_token); + if (result != ISC_R_SUCCESS) { + isc_mem_free(lex->mctx, source->name); + isc_mem_put(lex->mctx, source, sizeof(*source)); + return (result); + } + source->ignored = 0; + source->line = 1; + ISC_LIST_INITANDPREPEND(lex->sources, source, link); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_lex_openfile(isc_lex_t *lex, const char *filename) { + isc_result_t result; + FILE *stream = NULL; + + /* + * Open 'filename' and make it the current input source for 'lex'. + */ + + REQUIRE(VALID_LEX(lex)); + + result = isc_stdio_open(filename, "r", &stream); + if (result != ISC_R_SUCCESS) + return (result); + + result = new_source(lex, ISC_TRUE, ISC_TRUE, stream, filename); + if (result != ISC_R_SUCCESS) + (void)fclose(stream); + return (result); +} + +isc_result_t +isc_lex_openstream(isc_lex_t *lex, FILE *stream) { + char name[128]; + + /* + * Make 'stream' the current input source for 'lex'. + */ + + REQUIRE(VALID_LEX(lex)); + + snprintf(name, sizeof(name), "stream-%p", stream); + + return (new_source(lex, ISC_TRUE, ISC_FALSE, stream, name)); +} + +isc_result_t +isc_lex_openbuffer(isc_lex_t *lex, isc_buffer_t *buffer) { + char name[128]; + + /* + * Make 'buffer' the current input source for 'lex'. + */ + + REQUIRE(VALID_LEX(lex)); + + snprintf(name, sizeof(name), "buffer-%p", buffer); + + return (new_source(lex, ISC_FALSE, ISC_FALSE, buffer, name)); +} + +isc_result_t +isc_lex_close(isc_lex_t *lex) { + inputsource *source; + + /* + * Close the most recently opened object (i.e. file or buffer). + */ + + REQUIRE(VALID_LEX(lex)); + + source = HEAD(lex->sources); + if (source == NULL) + return (ISC_R_NOMORE); + + ISC_LIST_UNLINK(lex->sources, source, link); + if (source->is_file) { + if (source->need_close) + (void)fclose((FILE *)(source->input)); + } + isc_mem_free(lex->mctx, source->name); + isc_buffer_free(&source->pushback); + isc_mem_put(lex->mctx, source, sizeof(*source)); + + return (ISC_R_SUCCESS); +} + +typedef enum { + lexstate_start, + lexstate_crlf, + lexstate_string, + lexstate_number, + lexstate_maybecomment, + lexstate_ccomment, + lexstate_ccommentend, + lexstate_eatline, + lexstate_qstring +} lexstate; + +#define IWSEOL (ISC_LEXOPT_INITIALWS | ISC_LEXOPT_EOL) + +static void +pushback(inputsource *source, int c) { + REQUIRE(source->pushback->current > 0); + if (c == EOF) { + source->at_eof = ISC_FALSE; + return; + } + source->pushback->current--; + if (c == '\n') + source->line--; +} + +static isc_result_t +pushandgrow(isc_lex_t *lex, inputsource *source, int c) { + if (isc_buffer_availablelength(source->pushback) == 0) { + isc_buffer_t *tbuf = NULL; + unsigned int oldlen; + isc_region_t used; + isc_result_t result; + + oldlen = isc_buffer_length(source->pushback); + result = isc_buffer_allocate(lex->mctx, &tbuf, oldlen * 2); + if (result != ISC_R_SUCCESS) + return (result); + isc_buffer_usedregion(source->pushback, &used); + result = isc_buffer_copyregion(tbuf, &used); + INSIST(result == ISC_R_SUCCESS); + tbuf->current = source->pushback->current; + isc_buffer_free(&source->pushback); + source->pushback = tbuf; + } + isc_buffer_putuint8(source->pushback, (isc_uint8_t)c); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_lex_gettoken(isc_lex_t *lex, unsigned int options, isc_token_t *tokenp) { + inputsource *source; + int c; + isc_boolean_t done = ISC_FALSE; + isc_boolean_t no_comments = ISC_FALSE; + isc_boolean_t escaped = ISC_FALSE; + lexstate state = lexstate_start; + lexstate saved_state = lexstate_start; + isc_buffer_t *buffer; + FILE *stream; + char *curr, *prev; + size_t remaining; + isc_uint32_t as_ulong; + unsigned int saved_options; + isc_result_t result; + + /* + * Get the next token. + */ + + REQUIRE(VALID_LEX(lex)); + source = HEAD(lex->sources); + REQUIRE(tokenp != NULL); + + if (source == NULL) { + if ((options & ISC_LEXOPT_NOMORE) != 0) { + tokenp->type = isc_tokentype_nomore; + return (ISC_R_SUCCESS); + } + return (ISC_R_NOMORE); + } + + if (source->result != ISC_R_SUCCESS) + return (source->result); + + lex->saved_paren_count = lex->paren_count; + source->saved_line = source->line; + + if (isc_buffer_remaininglength(source->pushback) == 0 && + source->at_eof) + { + if ((options & ISC_LEXOPT_DNSMULTILINE) != 0 && + lex->paren_count != 0) { + lex->paren_count = 0; + return (ISC_R_UNBALANCED); + } + if ((options & ISC_LEXOPT_EOF) != 0) { + tokenp->type = isc_tokentype_eof; + return (ISC_R_SUCCESS); + } + return (ISC_R_EOF); + } + + isc_buffer_compact(source->pushback); + + saved_options = options; + if ((options & ISC_LEXOPT_DNSMULTILINE) != 0 && lex->paren_count > 0) + options &= ~IWSEOL; + + curr = lex->data; + *curr = '\0'; + + prev = NULL; + remaining = lex->max_token; + +#ifdef HAVE_FLOCKFILE + if (source->is_file) + flockfile(source->input); +#endif + + do { + if (isc_buffer_remaininglength(source->pushback) == 0) { + if (source->is_file) { + stream = source->input; + +#if defined(HAVE_FLOCKFILE) && defined(HAVE_GETCUNLOCKED) + c = getc_unlocked(stream); +#else + c = getc(stream); +#endif + if (c == EOF) { + if (ferror(stream)) { + source->result = ISC_R_IOERROR; + result = source->result; + goto done; + } + source->at_eof = ISC_TRUE; + } + } else { + buffer = source->input; + + if (buffer->current == buffer->used) { + c = EOF; + source->at_eof = ISC_TRUE; + } else { + c = *((char *)buffer->base + + buffer->current); + buffer->current++; + } + } + if (c != EOF) { + source->result = pushandgrow(lex, source, c); + if (source->result != ISC_R_SUCCESS) { + result = source->result; + goto done; + } + } + } + + if (!source->at_eof) { + if (state == lexstate_start) + /* Token has not started yet. */ + source->ignored = + isc_buffer_consumedlength(source->pushback); + c = isc_buffer_getuint8(source->pushback); + } else { + c = EOF; + } + + if (c == '\n') + source->line++; + + if (lex->comment_ok && !no_comments) { + if (!escaped && c == ';' && + ((lex->comments & ISC_LEXCOMMENT_DNSMASTERFILE) + != 0)) { + saved_state = state; + state = lexstate_eatline; + no_comments = ISC_TRUE; + continue; + } else if (c == '/' && + (lex->comments & + (ISC_LEXCOMMENT_C| + ISC_LEXCOMMENT_CPLUSPLUS)) != 0) { + saved_state = state; + state = lexstate_maybecomment; + no_comments = ISC_TRUE; + continue; + } else if (c == '#' && + ((lex->comments & ISC_LEXCOMMENT_SHELL) + != 0)) { + saved_state = state; + state = lexstate_eatline; + no_comments = ISC_TRUE; + continue; + } + } + + no_read: + /* INSIST(c == EOF || (c >= 0 && c <= 255)); */ + switch (state) { + case lexstate_start: + if (c == EOF) { + lex->last_was_eol = ISC_FALSE; + if ((options & ISC_LEXOPT_DNSMULTILINE) != 0 && + lex->paren_count != 0) { + lex->paren_count = 0; + result = ISC_R_UNBALANCED; + goto done; + } + if ((options & ISC_LEXOPT_EOF) == 0) { + result = ISC_R_EOF; + goto done; + } + tokenp->type = isc_tokentype_eof; + done = ISC_TRUE; + } else if (c == ' ' || c == '\t') { + if (lex->last_was_eol && + (options & ISC_LEXOPT_INITIALWS) + != 0) { + lex->last_was_eol = ISC_FALSE; + tokenp->type = isc_tokentype_initialws; + tokenp->value.as_char = c; + done = ISC_TRUE; + } + } else if (c == '\n') { + if ((options & ISC_LEXOPT_EOL) != 0) { + tokenp->type = isc_tokentype_eol; + done = ISC_TRUE; + } + lex->last_was_eol = ISC_TRUE; + } else if (c == '\r') { + if ((options & ISC_LEXOPT_EOL) != 0) + state = lexstate_crlf; + } else if (c == '"' && + (options & ISC_LEXOPT_QSTRING) != 0) { + lex->last_was_eol = ISC_FALSE; + no_comments = ISC_TRUE; + state = lexstate_qstring; + } else if (lex->specials[c]) { + lex->last_was_eol = ISC_FALSE; + if ((c == '(' || c == ')') && + (options & ISC_LEXOPT_DNSMULTILINE) != 0) { + if (c == '(') { + if (lex->paren_count == 0) + options &= ~IWSEOL; + lex->paren_count++; + } else { + if (lex->paren_count == 0) { + result = ISC_R_UNBALANCED; + goto done; + } + lex->paren_count--; + if (lex->paren_count == 0) + options = + saved_options; + } + continue; + } + tokenp->type = isc_tokentype_special; + tokenp->value.as_char = c; + done = ISC_TRUE; + } else if (isdigit((unsigned char)c) && + (options & ISC_LEXOPT_NUMBER) != 0) { + lex->last_was_eol = ISC_FALSE; + if ((options & ISC_LEXOPT_OCTAL) != 0 && + (c == '8' || c == '9')) + state = lexstate_string; + else + state = lexstate_number; + goto no_read; + } else { + lex->last_was_eol = ISC_FALSE; + state = lexstate_string; + goto no_read; + } + break; + case lexstate_crlf: + if (c != '\n') + pushback(source, c); + tokenp->type = isc_tokentype_eol; + done = ISC_TRUE; + lex->last_was_eol = ISC_TRUE; + break; + case lexstate_number: + if (c == EOF || !isdigit((unsigned char)c)) { + if (c == ' ' || c == '\t' || c == '\r' || + c == '\n' || c == EOF || + lex->specials[c]) { + int base; + if ((options & ISC_LEXOPT_OCTAL) != 0) + base = 8; + else if ((options & ISC_LEXOPT_CNUMBER) != 0) + base = 0; + else + base = 10; + pushback(source, c); + + result = isc_parse_uint32(&as_ulong, + lex->data, + base); + if (result == ISC_R_SUCCESS) { + tokenp->type = + isc_tokentype_number; + tokenp->value.as_ulong = + as_ulong; + } else if (result == ISC_R_BADNUMBER) { + isc_tokenvalue_t *v; + + tokenp->type = + isc_tokentype_string; + v = &(tokenp->value); + v->as_textregion.base = + lex->data; + v->as_textregion.length = + lex->max_token - + remaining; + } else + goto done; + done = ISC_TRUE; + continue; + } else if (!(options & ISC_LEXOPT_CNUMBER) || + ((c != 'x' && c != 'X') || + (curr != &lex->data[1]) || + (lex->data[0] != '0'))) { + /* Above test supports hex numbers */ + state = lexstate_string; + } + } else if ((options & ISC_LEXOPT_OCTAL) != 0 && + (c == '8' || c == '9')) { + state = lexstate_string; + } + if (remaining == 0U) { + result = grow_data(lex, &remaining, + &curr, &prev); + if (result != ISC_R_SUCCESS) + goto done; + } + INSIST(remaining > 0U); + *curr++ = c; + *curr = '\0'; + remaining--; + break; + case lexstate_string: + /* + * EOF needs to be checked before lex->specials[c] + * as lex->specials[EOF] is not a good idea. + */ + if (c == '\r' || c == '\n' || c == EOF || + (!escaped && + (c == ' ' || c == '\t' || lex->specials[c]))) { + pushback(source, c); + if (source->result != ISC_R_SUCCESS) { + result = source->result; + goto done; + } + tokenp->type = isc_tokentype_string; + tokenp->value.as_textregion.base = lex->data; + tokenp->value.as_textregion.length = + lex->max_token - remaining; + done = ISC_TRUE; + continue; + } + if ((options & ISC_LEXOPT_ESCAPE) != 0) + escaped = (!escaped && c == '\\') ? + ISC_TRUE : ISC_FALSE; + if (remaining == 0U) { + result = grow_data(lex, &remaining, + &curr, &prev); + if (result != ISC_R_SUCCESS) + goto done; + } + INSIST(remaining > 0U); + *curr++ = c; + *curr = '\0'; + remaining--; + break; + case lexstate_maybecomment: + if (c == '*' && + (lex->comments & ISC_LEXCOMMENT_C) != 0) { + state = lexstate_ccomment; + continue; + } else if (c == '/' && + (lex->comments & ISC_LEXCOMMENT_CPLUSPLUS) != 0) { + state = lexstate_eatline; + continue; + } + pushback(source, c); + c = '/'; + no_comments = ISC_FALSE; + state = saved_state; + goto no_read; + case lexstate_ccomment: + if (c == EOF) { + result = ISC_R_UNEXPECTEDEND; + goto done; + } + if (c == '*') + state = lexstate_ccommentend; + break; + case lexstate_ccommentend: + if (c == EOF) { + result = ISC_R_UNEXPECTEDEND; + goto done; + } + if (c == '/') { + /* + * C-style comments become a single space. + * We do this to ensure that a comment will + * act as a delimiter for strings and + * numbers. + */ + c = ' '; + no_comments = ISC_FALSE; + state = saved_state; + goto no_read; + } else if (c != '*') + state = lexstate_ccomment; + break; + case lexstate_eatline: + if ((c == '\n') || (c == EOF)) { + no_comments = ISC_FALSE; + state = saved_state; + goto no_read; + } + break; + case lexstate_qstring: + if (c == EOF) { + result = ISC_R_UNEXPECTEDEND; + goto done; + } + if (c == '"') { + if (escaped) { + escaped = ISC_FALSE; + /* + * Overwrite the preceding backslash. + */ + INSIST(prev != NULL); + *prev = '"'; + } else { + tokenp->type = isc_tokentype_qstring; + tokenp->value.as_textregion.base = + lex->data; + tokenp->value.as_textregion.length = + lex->max_token - remaining; + no_comments = ISC_FALSE; + done = ISC_TRUE; + } + } else { + if (c == '\n' && !escaped && + (options & ISC_LEXOPT_QSTRINGMULTILINE) == 0) { + pushback(source, c); + result = ISC_R_UNBALANCEDQUOTES; + goto done; + } + if (c == '\\' && !escaped) + escaped = ISC_TRUE; + else + escaped = ISC_FALSE; + if (remaining == 0U) { + result = grow_data(lex, &remaining, + &curr, &prev); + if (result != ISC_R_SUCCESS) + goto done; + } + INSIST(remaining > 0U); + prev = curr; + *curr++ = c; + *curr = '\0'; + remaining--; + } + break; + default: + FATAL_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_LEX, + ISC_MSG_UNEXPECTEDSTATE, + "Unexpected state %d"), + state); + /* Does not return. */ + } + + } while (!done); + + result = ISC_R_SUCCESS; + done: +#ifdef HAVE_FLOCKFILE + if (source->is_file) + funlockfile(source->input); +#endif + return (result); +} + +isc_result_t +isc_lex_getmastertoken(isc_lex_t *lex, isc_token_t *token, + isc_tokentype_t expect, isc_boolean_t eol) +{ + unsigned int options = ISC_LEXOPT_EOL | ISC_LEXOPT_EOF | + ISC_LEXOPT_DNSMULTILINE | ISC_LEXOPT_ESCAPE; + isc_result_t result; + + if (expect == isc_tokentype_qstring) + options |= ISC_LEXOPT_QSTRING; + else if (expect == isc_tokentype_number) + options |= ISC_LEXOPT_NUMBER; + result = isc_lex_gettoken(lex, options, token); + if (result == ISC_R_RANGE) + isc_lex_ungettoken(lex, token); + if (result != ISC_R_SUCCESS) + return (result); + + if (eol && ((token->type == isc_tokentype_eol) || + (token->type == isc_tokentype_eof))) + return (ISC_R_SUCCESS); + if (token->type == isc_tokentype_string && + expect == isc_tokentype_qstring) + return (ISC_R_SUCCESS); + if (token->type != expect) { + isc_lex_ungettoken(lex, token); + if (token->type == isc_tokentype_eol || + token->type == isc_tokentype_eof) + return (ISC_R_UNEXPECTEDEND); + if (expect == isc_tokentype_number) + return (ISC_R_BADNUMBER); + return (ISC_R_UNEXPECTEDTOKEN); + } + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_lex_getoctaltoken(isc_lex_t *lex, isc_token_t *token, isc_boolean_t eol) +{ + unsigned int options = ISC_LEXOPT_EOL | ISC_LEXOPT_EOF | + ISC_LEXOPT_DNSMULTILINE | ISC_LEXOPT_ESCAPE| + ISC_LEXOPT_NUMBER | ISC_LEXOPT_OCTAL; + isc_result_t result; + + result = isc_lex_gettoken(lex, options, token); + if (result == ISC_R_RANGE) + isc_lex_ungettoken(lex, token); + if (result != ISC_R_SUCCESS) + return (result); + + if (eol && ((token->type == isc_tokentype_eol) || + (token->type == isc_tokentype_eof))) + return (ISC_R_SUCCESS); + if (token->type != isc_tokentype_number) { + isc_lex_ungettoken(lex, token); + if (token->type == isc_tokentype_eol || + token->type == isc_tokentype_eof) + return (ISC_R_UNEXPECTEDEND); + return (ISC_R_BADNUMBER); + } + return (ISC_R_SUCCESS); +} + +void +isc_lex_ungettoken(isc_lex_t *lex, isc_token_t *tokenp) { + inputsource *source; + /* + * Unget the current token. + */ + + REQUIRE(VALID_LEX(lex)); + source = HEAD(lex->sources); + REQUIRE(source != NULL); + REQUIRE(tokenp != NULL); + REQUIRE(isc_buffer_consumedlength(source->pushback) != 0 || + tokenp->type == isc_tokentype_eof); + + UNUSED(tokenp); + + isc_buffer_first(source->pushback); + lex->paren_count = lex->saved_paren_count; + source->line = source->saved_line; + source->at_eof = ISC_FALSE; +} + +void +isc_lex_getlasttokentext(isc_lex_t *lex, isc_token_t *tokenp, isc_region_t *r) +{ + inputsource *source; + + REQUIRE(VALID_LEX(lex)); + source = HEAD(lex->sources); + REQUIRE(source != NULL); + REQUIRE(tokenp != NULL); + REQUIRE(isc_buffer_consumedlength(source->pushback) != 0 || + tokenp->type == isc_tokentype_eof); + + UNUSED(tokenp); + + INSIST(source->ignored <= isc_buffer_consumedlength(source->pushback)); + r->base = (unsigned char *)isc_buffer_base(source->pushback) + + source->ignored; + r->length = isc_buffer_consumedlength(source->pushback) - + source->ignored; +} + + +char * +isc_lex_getsourcename(isc_lex_t *lex) { + inputsource *source; + + REQUIRE(VALID_LEX(lex)); + source = HEAD(lex->sources); + + if (source == NULL) + return (NULL); + + return (source->name); +} + +unsigned long +isc_lex_getsourceline(isc_lex_t *lex) { + inputsource *source; + + REQUIRE(VALID_LEX(lex)); + source = HEAD(lex->sources); + + if (source == NULL) + return (0); + + return (source->line); +} + + +isc_result_t +isc_lex_setsourcename(isc_lex_t *lex, const char *name) { + inputsource *source; + char *newname; + + REQUIRE(VALID_LEX(lex)); + source = HEAD(lex->sources); + + if (source == NULL) + return(ISC_R_NOTFOUND); + newname = isc_mem_strdup(lex->mctx, name); + if (newname == NULL) + return (ISC_R_NOMEMORY); + isc_mem_free(lex->mctx, source->name); + source->name = newname; + return (ISC_R_SUCCESS); +} + +isc_boolean_t +isc_lex_isfile(isc_lex_t *lex) { + inputsource *source; + + REQUIRE(VALID_LEX(lex)); + + source = HEAD(lex->sources); + + if (source == NULL) + return (ISC_FALSE); + + return (source->is_file); +} diff -urN src/contrib/ntp/lib/isc/lfsr.c src.ntp/contrib/ntp/lib/isc/lfsr.c --- src/contrib/ntp/lib/isc/lfsr.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/lfsr.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,161 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: lfsr.c,v 1.20 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include + +#include +#include +#include + +#define VALID_LFSR(x) (x != NULL) + +void +isc_lfsr_init(isc_lfsr_t *lfsr, isc_uint32_t state, unsigned int bits, + isc_uint32_t tap, unsigned int count, + isc_lfsrreseed_t reseed, void *arg) +{ + REQUIRE(VALID_LFSR(lfsr)); + REQUIRE(8 <= bits && bits <= 32); + REQUIRE(tap != 0); + + lfsr->state = state; + lfsr->bits = bits; + lfsr->tap = tap; + lfsr->count = count; + lfsr->reseed = reseed; + lfsr->arg = arg; + + if (count == 0 && reseed != NULL) + reseed(lfsr, arg); + if (lfsr->state == 0) + lfsr->state = 0xffffffffU >> (32 - lfsr->bits); +} + +/*! + * Return the next state of the lfsr. + */ +static inline isc_uint32_t +lfsr_generate(isc_lfsr_t *lfsr) +{ + + /* + * If the previous state is zero, we must fill it with something + * here, or we will begin to generate an extremely predictable output. + * + * First, give the reseed function a crack at it. If the state is + * still 0, set it to all ones. + */ + if (lfsr->state == 0) { + if (lfsr->reseed != NULL) + lfsr->reseed(lfsr, lfsr->arg); + if (lfsr->state == 0) + lfsr->state = 0xffffffffU >> (32 - lfsr->bits); + } + + if (lfsr->state & 0x01) { + lfsr->state = (lfsr->state >> 1) ^ lfsr->tap; + return (1); + } else { + lfsr->state >>= 1; + return (0); + } +} + +void +isc_lfsr_generate(isc_lfsr_t *lfsr, void *data, unsigned int count) +{ + unsigned char *p; + unsigned int bit; + unsigned int byte; + + REQUIRE(VALID_LFSR(lfsr)); + REQUIRE(data != NULL); + REQUIRE(count > 0); + + p = data; + byte = count; + + while (byte--) { + *p = 0; + for (bit = 0; bit < 7; bit++) { + *p |= lfsr_generate(lfsr); + *p <<= 1; + } + *p |= lfsr_generate(lfsr); + p++; + } + + if (lfsr->count != 0 && lfsr->reseed != NULL) { + if (lfsr->count <= count * 8) + lfsr->reseed(lfsr, lfsr->arg); + else + lfsr->count -= (count * 8); + } +} + +static inline isc_uint32_t +lfsr_skipgenerate(isc_lfsr_t *lfsr, unsigned int skip) +{ + while (skip--) + (void)lfsr_generate(lfsr); + + (void)lfsr_generate(lfsr); + + return (lfsr->state); +} + +/* + * Skip "skip" states in "lfsr". + */ +void +isc_lfsr_skip(isc_lfsr_t *lfsr, unsigned int skip) +{ + REQUIRE(VALID_LFSR(lfsr)); + + while (skip--) + (void)lfsr_generate(lfsr); +} + +/* + * Skip states in lfsr1 and lfsr2 using the other's current state. + * Return the final state of lfsr1 ^ lfsr2. + */ +isc_uint32_t +isc_lfsr_generate32(isc_lfsr_t *lfsr1, isc_lfsr_t *lfsr2) +{ + isc_uint32_t state1, state2; + isc_uint32_t skip1, skip2; + + REQUIRE(VALID_LFSR(lfsr1)); + REQUIRE(VALID_LFSR(lfsr2)); + + skip1 = lfsr1->state & 0x01; + skip2 = lfsr2->state & 0x01; + + /* cross-skip. */ + state1 = lfsr_skipgenerate(lfsr1, skip2); + state2 = lfsr_skipgenerate(lfsr2, skip1); + + return (state1 ^ state2); +} diff -urN src/contrib/ntp/lib/isc/lib.c src.ntp/contrib/ntp/lib/isc/lib.c --- src/contrib/ntp/lib/isc/lib.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/lib.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,79 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: lib.c,v 1.14 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include + +#include +#include +#include + +/*** + *** Globals + ***/ + +LIBISC_EXTERNAL_DATA isc_msgcat_t * isc_msgcat = NULL; + + +/*** + *** Private + ***/ + +static isc_once_t msgcat_once = ISC_ONCE_INIT; + + +/*** + *** Functions + ***/ + +static void +open_msgcat(void) { + isc_msgcat_open("libisc.cat", &isc_msgcat); +} + +void +isc_lib_initmsgcat(void) { + isc_result_t result; + + /*! + * Initialize the ISC library's message catalog, isc_msgcat, if it + * has not already been initialized. + */ + + result = isc_once_do(&msgcat_once, open_msgcat); + if (result != ISC_R_SUCCESS) { + /* + * Normally we'd use RUNTIME_CHECK() or FATAL_ERROR(), but + * we can't do that here, since they might call us! + * (Note that the catalog might be open anyway, so we might + * as well try to provide an internationalized message.) + */ + fprintf(stderr, "%s:%d: %s: isc_once_do() %s.\n", + __FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FATALERROR, "fatal error"), + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + abort(); + } +} diff -urN src/contrib/ntp/lib/isc/log.c src.ntp/contrib/ntp/lib/isc/log.c --- src/contrib/ntp/lib/isc/log.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/log.c 2009-12-09 08:36:44.000000000 +0100 @@ -0,0 +1,1762 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: log.c,v 1.94.332.5 2009/02/16 02:04:05 marka Exp $ */ + +/*! \file + * \author Principal Authors: DCL */ + +#include + +#include +#include +#include +#include + +#include /* dev_t FreeBSD 2.1 */ + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#define LCTX_MAGIC ISC_MAGIC('L', 'c', 't', 'x') +#define VALID_CONTEXT(lctx) ISC_MAGIC_VALID(lctx, LCTX_MAGIC) + +#define LCFG_MAGIC ISC_MAGIC('L', 'c', 'f', 'g') +#define VALID_CONFIG(lcfg) ISC_MAGIC_VALID(lcfg, LCFG_MAGIC) + +/* + * XXXDCL make dynamic? + */ +#define LOG_BUFFER_SIZE (8 * 1024) + +#ifndef PATH_MAX +#define PATH_MAX 1024 /* AIX and others don't define this. */ +#endif + +/*! + * This is the structure that holds each named channel. A simple linked + * list chains all of the channels together, so an individual channel is + * found by doing strcmp()s with the names down the list. Their should + * be no performance penalty from this as it is expected that the number + * of named channels will be no more than a dozen or so, and name lookups + * from the head of the list are only done when isc_log_usechannel() is + * called, which should also be very infrequent. + */ +typedef struct isc_logchannel isc_logchannel_t; + +struct isc_logchannel { + char * name; + unsigned int type; + int level; + unsigned int flags; + isc_logdestination_t destination; + ISC_LINK(isc_logchannel_t) link; +}; + +/*! + * The logchannellist structure associates categories and modules with + * channels. First the appropriate channellist is found based on the + * category, and then each structure in the linked list is checked for + * a matching module. It is expected that the number of channels + * associated with any given category will be very short, no more than + * three or four in the more unusual cases. + */ +typedef struct isc_logchannellist isc_logchannellist_t; + +struct isc_logchannellist { + const isc_logmodule_t * module; + isc_logchannel_t * channel; + ISC_LINK(isc_logchannellist_t) link; +}; + +/*! + * This structure is used to remember messages for pruning via + * isc_log_[v]write1(). + */ +typedef struct isc_logmessage isc_logmessage_t; + +struct isc_logmessage { + char * text; + isc_time_t time; + ISC_LINK(isc_logmessage_t) link; +}; + +/*! + * The isc_logconfig structure is used to store the configurable information + * about where messages are actually supposed to be sent -- the information + * that could changed based on some configuration file, as opposed to the + * the category/module specification of isc_log_[v]write[1] that is compiled + * into a program, or the debug_level which is dynamic state information. + */ +struct isc_logconfig { + unsigned int magic; + isc_log_t * lctx; + ISC_LIST(isc_logchannel_t) channels; + ISC_LIST(isc_logchannellist_t) *channellists; + unsigned int channellist_count; + unsigned int duplicate_interval; + int highest_level; + char * tag; + isc_boolean_t dynamic; +}; + +/*! + * This isc_log structure provides the context for the isc_log functions. + * The log context locks itself in isc_log_doit, the internal backend to + * isc_log_write. The locking is necessary both to provide exclusive access + * to the buffer into which the message is formatted and to guard against + * competing threads trying to write to the same syslog resource. (On + * some systems, such as BSD/OS, stdio is thread safe but syslog is not.) + * Unfortunately, the lock cannot guard against a _different_ logging + * context in the same program competing for syslog's attention. Thus + * There Can Be Only One, but this is not enforced. + * XXXDCL enforce it? + * + * Note that the category and module information is not locked. + * This is because in the usual case, only one isc_log_t is ever created + * in a program, and the category/module registration happens only once. + * XXXDCL it might be wise to add more locking overall. + */ +struct isc_log { + /* Not locked. */ + unsigned int magic; + isc_mem_t * mctx; + isc_logcategory_t * categories; + unsigned int category_count; + isc_logmodule_t * modules; + unsigned int module_count; + int debug_level; + isc_mutex_t lock; + /* Locked by isc_log lock. */ + isc_logconfig_t * logconfig; + char buffer[LOG_BUFFER_SIZE]; + ISC_LIST(isc_logmessage_t) messages; +}; + +/*! + * Used when ISC_LOG_PRINTLEVEL is enabled for a channel. + */ +static const char *log_level_strings[] = { + "debug", + "info", + "notice", + "warning", + "error", + "critical" +}; + +/*! + * Used to convert ISC_LOG_* priorities into syslog priorities. + * XXXDCL This will need modification for NT. + */ +static const int syslog_map[] = { + LOG_DEBUG, + LOG_INFO, + LOG_NOTICE, + LOG_WARNING, + LOG_ERR, + LOG_CRIT +}; + +/*! + * When adding new categories, a corresponding ISC_LOGCATEGORY_foo + * definition needs to be added to . + * + * The default category is provided so that the internal default can + * be overridden. Since the default is always looked up as the first + * channellist in the log context, it must come first in isc_categories[]. + */ +LIBISC_EXTERNAL_DATA isc_logcategory_t isc_categories[] = { + { "default", 0 }, /* "default" must come first. */ + { "general", 0 }, + { NULL, 0 } +}; + +/*! + * See above comment for categories on LIBISC_EXTERNAL_DATA, and apply it to modules. + */ +LIBISC_EXTERNAL_DATA isc_logmodule_t isc_modules[] = { + { "socket", 0 }, + { "time", 0 }, + { "interface", 0 }, + { "timer", 0 }, + { "file", 0 }, + { NULL, 0 } +}; + +/*! + * This essentially constant structure must be filled in at run time, + * because its channel member is pointed to a channel that is created + * dynamically with isc_log_createchannel. + */ +static isc_logchannellist_t default_channel; + +/*! + * libisc logs to this context. + */ +LIBISC_EXTERNAL_DATA isc_log_t *isc_lctx = NULL; + +/*! + * Forward declarations. + */ +static isc_result_t +assignchannel(isc_logconfig_t *lcfg, unsigned int category_id, + const isc_logmodule_t *module, isc_logchannel_t *channel); + +static isc_result_t +sync_channellist(isc_logconfig_t *lcfg); + +static isc_result_t +greatest_version(isc_logchannel_t *channel, int *greatest); + +static isc_result_t +roll_log(isc_logchannel_t *channel); + +static void +isc_log_doit(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, isc_boolean_t write_once, + isc_msgcat_t *msgcat, int msgset, int msg, + const char *format, va_list args) + ISC_FORMAT_PRINTF(9, 0); + +/*@{*/ +/*! + * Convenience macros. + */ + +#define FACILITY(channel) (channel->destination.facility) +#define FILE_NAME(channel) (channel->destination.file.name) +#define FILE_STREAM(channel) (channel->destination.file.stream) +#define FILE_VERSIONS(channel) (channel->destination.file.versions) +#define FILE_MAXSIZE(channel) (channel->destination.file.maximum_size) +#define FILE_MAXREACHED(channel) (channel->destination.file.maximum_reached) + +/*@}*/ +/**** + **** Public interfaces. + ****/ + +/* + * Establish a new logging context, with default channels. + */ +isc_result_t +isc_log_create(isc_mem_t *mctx, isc_log_t **lctxp, isc_logconfig_t **lcfgp) { + isc_log_t *lctx; + isc_logconfig_t *lcfg = NULL; + isc_result_t result; + + REQUIRE(mctx != NULL); + REQUIRE(lctxp != NULL && *lctxp == NULL); + REQUIRE(lcfgp == NULL || *lcfgp == NULL); + + lctx = isc_mem_get(mctx, sizeof(*lctx)); + if (lctx != NULL) { + lctx->mctx = mctx; + lctx->categories = NULL; + lctx->category_count = 0; + lctx->modules = NULL; + lctx->module_count = 0; + lctx->debug_level = 0; + + ISC_LIST_INIT(lctx->messages); + + result = isc_mutex_init(&lctx->lock); + if (result != ISC_R_SUCCESS) { + isc_mem_put(mctx, lctx, sizeof(*lctx)); + return (result); + } + + /* + * Normally setting the magic number is the last step done + * in a creation function, but a valid log context is needed + * by isc_log_registercategories and isc_logconfig_create. + * If either fails, the lctx is destroyed and not returned + * to the caller. + */ + lctx->magic = LCTX_MAGIC; + + isc_log_registercategories(lctx, isc_categories); + isc_log_registermodules(lctx, isc_modules); + result = isc_logconfig_create(lctx, &lcfg); + + } else + result = ISC_R_NOMEMORY; + + if (result == ISC_R_SUCCESS) + result = sync_channellist(lcfg); + + if (result == ISC_R_SUCCESS) { + lctx->logconfig = lcfg; + + *lctxp = lctx; + if (lcfgp != NULL) + *lcfgp = lcfg; + + } else { + if (lcfg != NULL) + isc_logconfig_destroy(&lcfg); + if (lctx != NULL) + isc_log_destroy(&lctx); + } + + return (result); +} + +isc_result_t +isc_logconfig_create(isc_log_t *lctx, isc_logconfig_t **lcfgp) { + isc_logconfig_t *lcfg; + isc_logdestination_t destination; + isc_result_t result = ISC_R_SUCCESS; + int level = ISC_LOG_INFO; + + REQUIRE(lcfgp != NULL && *lcfgp == NULL); + REQUIRE(VALID_CONTEXT(lctx)); + + lcfg = isc_mem_get(lctx->mctx, sizeof(*lcfg)); + + if (lcfg != NULL) { + lcfg->lctx = lctx; + lcfg->channellists = NULL; + lcfg->channellist_count = 0; + lcfg->duplicate_interval = 0; + lcfg->highest_level = level; + lcfg->tag = NULL; + lcfg->dynamic = ISC_FALSE; + + ISC_LIST_INIT(lcfg->channels); + + /* + * Normally the magic number is the last thing set in the + * structure, but isc_log_createchannel() needs a valid + * config. If the channel creation fails, the lcfg is not + * returned to the caller. + */ + lcfg->magic = LCFG_MAGIC; + + } else + result = ISC_R_NOMEMORY; + + /* + * Create the default channels: + * default_syslog, default_stderr, default_debug and null. + */ + if (result == ISC_R_SUCCESS) { + destination.facility = LOG_DAEMON; + result = isc_log_createchannel(lcfg, "default_syslog", + ISC_LOG_TOSYSLOG, level, + &destination, 0); + } + + if (result == ISC_R_SUCCESS) { + destination.file.stream = stderr; + destination.file.name = NULL; + destination.file.versions = ISC_LOG_ROLLNEVER; + destination.file.maximum_size = 0; + result = isc_log_createchannel(lcfg, "default_stderr", + ISC_LOG_TOFILEDESC, + level, + &destination, + ISC_LOG_PRINTTIME); + } + + if (result == ISC_R_SUCCESS) { + /* + * Set the default category's channel to default_stderr, + * which is at the head of the channels list because it was + * just created. + */ + default_channel.channel = ISC_LIST_HEAD(lcfg->channels); + + destination.file.stream = stderr; + destination.file.name = NULL; + destination.file.versions = ISC_LOG_ROLLNEVER; + destination.file.maximum_size = 0; + result = isc_log_createchannel(lcfg, "default_debug", + ISC_LOG_TOFILEDESC, + ISC_LOG_DYNAMIC, + &destination, + ISC_LOG_PRINTTIME); + } + + if (result == ISC_R_SUCCESS) + result = isc_log_createchannel(lcfg, "null", + ISC_LOG_TONULL, + ISC_LOG_DYNAMIC, + NULL, 0); + + if (result == ISC_R_SUCCESS) + *lcfgp = lcfg; + + else + if (lcfg != NULL) + isc_logconfig_destroy(&lcfg); + + return (result); +} + +isc_logconfig_t * +isc_logconfig_get(isc_log_t *lctx) { + REQUIRE(VALID_CONTEXT(lctx)); + + ENSURE(lctx->logconfig != NULL); + + return (lctx->logconfig); +} + +isc_result_t +isc_logconfig_use(isc_log_t *lctx, isc_logconfig_t *lcfg) { + isc_logconfig_t *old_cfg; + isc_result_t result; + + REQUIRE(VALID_CONTEXT(lctx)); + REQUIRE(VALID_CONFIG(lcfg)); + REQUIRE(lcfg->lctx == lctx); + + /* + * Ensure that lcfg->channellist_count == lctx->category_count. + * They won't be equal if isc_log_usechannel has not been called + * since any call to isc_log_registercategories. + */ + result = sync_channellist(lcfg); + if (result != ISC_R_SUCCESS) + return (result); + + LOCK(&lctx->lock); + + old_cfg = lctx->logconfig; + lctx->logconfig = lcfg; + + UNLOCK(&lctx->lock); + + isc_logconfig_destroy(&old_cfg); + + return (ISC_R_SUCCESS); +} + +void +isc_log_destroy(isc_log_t **lctxp) { + isc_log_t *lctx; + isc_logconfig_t *lcfg; + isc_mem_t *mctx; + isc_logmessage_t *message; + + REQUIRE(lctxp != NULL && VALID_CONTEXT(*lctxp)); + + lctx = *lctxp; + mctx = lctx->mctx; + + if (lctx->logconfig != NULL) { + lcfg = lctx->logconfig; + lctx->logconfig = NULL; + isc_logconfig_destroy(&lcfg); + } + + DESTROYLOCK(&lctx->lock); + + while ((message = ISC_LIST_HEAD(lctx->messages)) != NULL) { + ISC_LIST_UNLINK(lctx->messages, message, link); + + isc_mem_put(mctx, message, + sizeof(*message) + strlen(message->text) + 1); + } + + lctx->buffer[0] = '\0'; + lctx->debug_level = 0; + lctx->categories = NULL; + lctx->category_count = 0; + lctx->modules = NULL; + lctx->module_count = 0; + lctx->mctx = NULL; + lctx->magic = 0; + + isc_mem_put(mctx, lctx, sizeof(*lctx)); + + *lctxp = NULL; +} + +void +isc_logconfig_destroy(isc_logconfig_t **lcfgp) { + isc_logconfig_t *lcfg; + isc_mem_t *mctx; + isc_logchannel_t *channel; + isc_logchannellist_t *item; + char *filename; + unsigned int i; + + REQUIRE(lcfgp != NULL && VALID_CONFIG(*lcfgp)); + + lcfg = *lcfgp; + + /* + * This function cannot be called with a logconfig that is in + * use by a log context. + */ + REQUIRE(lcfg->lctx != NULL && lcfg->lctx->logconfig != lcfg); + + mctx = lcfg->lctx->mctx; + + while ((channel = ISC_LIST_HEAD(lcfg->channels)) != NULL) { + ISC_LIST_UNLINK(lcfg->channels, channel, link); + + if (channel->type == ISC_LOG_TOFILE) { + /* + * The filename for the channel may have ultimately + * started its life in user-land as a const string, + * but in isc_log_createchannel it gets copied + * into writable memory and is not longer truly const. + */ + DE_CONST(FILE_NAME(channel), filename); + isc_mem_free(mctx, filename); + + if (FILE_STREAM(channel) != NULL) + (void)fclose(FILE_STREAM(channel)); + } + + isc_mem_free(mctx, channel->name); + isc_mem_put(mctx, channel, sizeof(*channel)); + } + + for (i = 0; i < lcfg->channellist_count; i++) + while ((item = ISC_LIST_HEAD(lcfg->channellists[i])) != NULL) { + ISC_LIST_UNLINK(lcfg->channellists[i], item, link); + isc_mem_put(mctx, item, sizeof(*item)); + } + + if (lcfg->channellist_count > 0) + isc_mem_put(mctx, lcfg->channellists, + lcfg->channellist_count * + sizeof(ISC_LIST(isc_logchannellist_t))); + + lcfg->dynamic = ISC_FALSE; + if (lcfg->tag != NULL) + isc_mem_free(lcfg->lctx->mctx, lcfg->tag); + lcfg->tag = NULL; + lcfg->highest_level = 0; + lcfg->duplicate_interval = 0; + lcfg->magic = 0; + + isc_mem_put(mctx, lcfg, sizeof(*lcfg)); + + *lcfgp = NULL; +} + +void +isc_log_registercategories(isc_log_t *lctx, isc_logcategory_t categories[]) { + isc_logcategory_t *catp; + + REQUIRE(VALID_CONTEXT(lctx)); + REQUIRE(categories != NULL && categories[0].name != NULL); + + /* + * XXXDCL This somewhat sleazy situation of using the last pointer + * in one category array to point to the next array exists because + * this registration function returns void and I didn't want to have + * change everything that used it by making it return an isc_result_t. + * It would need to do that if it had to allocate memory to store + * pointers to each array passed in. + */ + if (lctx->categories == NULL) + lctx->categories = categories; + + else { + /* + * Adjust the last (NULL) pointer of the already registered + * categories to point to the incoming array. + */ + for (catp = lctx->categories; catp->name != NULL; ) + if (catp->id == UINT_MAX) + /* + * The name pointer points to the next array. + * Ick. + */ + DE_CONST(catp->name, catp); + else + catp++; + + catp->name = (void *)categories; + catp->id = UINT_MAX; + } + + /* + * Update the id number of the category with its new global id. + */ + for (catp = categories; catp->name != NULL; catp++) + catp->id = lctx->category_count++; +} + +isc_logcategory_t * +isc_log_categorybyname(isc_log_t *lctx, const char *name) { + isc_logcategory_t *catp; + + REQUIRE(VALID_CONTEXT(lctx)); + REQUIRE(name != NULL); + + for (catp = lctx->categories; catp->name != NULL; ) + if (catp->id == UINT_MAX) + /* + * catp is neither modified nor returned to the + * caller, so removing its const qualifier is ok. + */ + DE_CONST(catp->name, catp); + else { + if (strcmp(catp->name, name) == 0) + return (catp); + catp++; + } + + return (NULL); +} + +void +isc_log_registermodules(isc_log_t *lctx, isc_logmodule_t modules[]) { + isc_logmodule_t *modp; + + REQUIRE(VALID_CONTEXT(lctx)); + REQUIRE(modules != NULL && modules[0].name != NULL); + + /* + * XXXDCL This somewhat sleazy situation of using the last pointer + * in one category array to point to the next array exists because + * this registration function returns void and I didn't want to have + * change everything that used it by making it return an isc_result_t. + * It would need to do that if it had to allocate memory to store + * pointers to each array passed in. + */ + if (lctx->modules == NULL) + lctx->modules = modules; + + else { + /* + * Adjust the last (NULL) pointer of the already registered + * modules to point to the incoming array. + */ + for (modp = lctx->modules; modp->name != NULL; ) + if (modp->id == UINT_MAX) + /* + * The name pointer points to the next array. + * Ick. + */ + DE_CONST(modp->name, modp); + else + modp++; + + modp->name = (void *)modules; + modp->id = UINT_MAX; + } + + /* + * Update the id number of the module with its new global id. + */ + for (modp = modules; modp->name != NULL; modp++) + modp->id = lctx->module_count++; +} + +isc_logmodule_t * +isc_log_modulebyname(isc_log_t *lctx, const char *name) { + isc_logmodule_t *modp; + + REQUIRE(VALID_CONTEXT(lctx)); + REQUIRE(name != NULL); + + for (modp = lctx->modules; modp->name != NULL; ) + if (modp->id == UINT_MAX) + /* + * modp is neither modified nor returned to the + * caller, so removing its const qualifier is ok. + */ + DE_CONST(modp->name, modp); + else { + if (strcmp(modp->name, name) == 0) + return (modp); + modp++; + } + + return (NULL); +} + +isc_result_t +isc_log_createchannel(isc_logconfig_t *lcfg, const char *name, + unsigned int type, int level, + const isc_logdestination_t *destination, + unsigned int flags) +{ + isc_logchannel_t *channel; + isc_mem_t *mctx; + + REQUIRE(VALID_CONFIG(lcfg)); + REQUIRE(name != NULL); + REQUIRE(type == ISC_LOG_TOSYSLOG || type == ISC_LOG_TOFILE || + type == ISC_LOG_TOFILEDESC || type == ISC_LOG_TONULL); + REQUIRE(destination != NULL || type == ISC_LOG_TONULL); + REQUIRE(level >= ISC_LOG_CRITICAL); + REQUIRE((flags & + (unsigned int)~(ISC_LOG_PRINTALL | ISC_LOG_DEBUGONLY)) == 0); + + /* XXXDCL find duplicate names? */ + + mctx = lcfg->lctx->mctx; + + channel = isc_mem_get(mctx, sizeof(*channel)); + if (channel == NULL) + return (ISC_R_NOMEMORY); + + channel->name = isc_mem_strdup(mctx, name); + if (channel->name == NULL) { + isc_mem_put(mctx, channel, sizeof(*channel)); + return (ISC_R_NOMEMORY); + } + + channel->type = type; + channel->level = level; + channel->flags = flags; + ISC_LINK_INIT(channel, link); + + switch (type) { + case ISC_LOG_TOSYSLOG: + FACILITY(channel) = destination->facility; + break; + + case ISC_LOG_TOFILE: + /* + * The file name is copied because greatest_version wants + * to scribble on it, so it needs to be definitely in + * writable memory. + */ + FILE_NAME(channel) = + isc_mem_strdup(mctx, destination->file.name); + FILE_STREAM(channel) = NULL; + FILE_VERSIONS(channel) = destination->file.versions; + FILE_MAXSIZE(channel) = destination->file.maximum_size; + FILE_MAXREACHED(channel) = ISC_FALSE; + break; + + case ISC_LOG_TOFILEDESC: + FILE_NAME(channel) = NULL; + FILE_STREAM(channel) = destination->file.stream; + FILE_MAXSIZE(channel) = 0; + FILE_VERSIONS(channel) = ISC_LOG_ROLLNEVER; + break; + + case ISC_LOG_TONULL: + /* Nothing. */ + break; + + default: + isc_mem_put(mctx, channel->name, strlen(channel->name) + 1); + isc_mem_put(mctx, channel, sizeof(*channel)); + return (ISC_R_UNEXPECTED); + } + + ISC_LIST_PREPEND(lcfg->channels, channel, link); + + /* + * If default_stderr was redefined, make the default category + * point to the new default_stderr. + */ + if (strcmp(name, "default_stderr") == 0) + default_channel.channel = channel; + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_log_usechannel(isc_logconfig_t *lcfg, const char *name, + const isc_logcategory_t *category, + const isc_logmodule_t *module) +{ + isc_log_t *lctx; + isc_logchannel_t *channel; + isc_result_t result = ISC_R_SUCCESS; + unsigned int i; + + REQUIRE(VALID_CONFIG(lcfg)); + REQUIRE(name != NULL); + + lctx = lcfg->lctx; + + REQUIRE(category == NULL || category->id < lctx->category_count); + REQUIRE(module == NULL || module->id < lctx->module_count); + + for (channel = ISC_LIST_HEAD(lcfg->channels); channel != NULL; + channel = ISC_LIST_NEXT(channel, link)) + if (strcmp(name, channel->name) == 0) + break; + + if (channel == NULL) + return (ISC_R_NOTFOUND); + + if (category != NULL) + result = assignchannel(lcfg, category->id, module, channel); + + else + /* + * Assign to all categories. Note that this includes + * the default channel. + */ + for (i = 0; i < lctx->category_count; i++) { + result = assignchannel(lcfg, i, module, channel); + if (result != ISC_R_SUCCESS) + break; + } + + return (result); +} + +void +isc_log_write(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, const char *format, ...) +{ + va_list args; + + /* + * Contract checking is done in isc_log_doit(). + */ + + va_start(args, format); + isc_log_doit(lctx, category, module, level, ISC_FALSE, + NULL, 0, 0, format, args); + va_end(args); +} + +void +isc_log_vwrite(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + const char *format, va_list args) +{ + /* + * Contract checking is done in isc_log_doit(). + */ + isc_log_doit(lctx, category, module, level, ISC_FALSE, + NULL, 0, 0, format, args); +} + +void +isc_log_write1(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, const char *format, ...) +{ + va_list args; + + /* + * Contract checking is done in isc_log_doit(). + */ + + va_start(args, format); + isc_log_doit(lctx, category, module, level, ISC_TRUE, + NULL, 0, 0, format, args); + va_end(args); +} + +void +isc_log_vwrite1(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + const char *format, va_list args) +{ + /* + * Contract checking is done in isc_log_doit(). + */ + isc_log_doit(lctx, category, module, level, ISC_TRUE, + NULL, 0, 0, format, args); +} + +void +isc_log_iwrite(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + isc_msgcat_t *msgcat, int msgset, int msg, + const char *format, ...) +{ + va_list args; + + /* + * Contract checking is done in isc_log_doit(). + */ + + va_start(args, format); + isc_log_doit(lctx, category, module, level, ISC_FALSE, + msgcat, msgset, msg, format, args); + va_end(args); +} + +void +isc_log_ivwrite(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + isc_msgcat_t *msgcat, int msgset, int msg, + const char *format, va_list args) +{ + /* + * Contract checking is done in isc_log_doit(). + */ + isc_log_doit(lctx, category, module, level, ISC_FALSE, + msgcat, msgset, msg, format, args); +} + +void +isc_log_iwrite1(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + isc_msgcat_t *msgcat, int msgset, int msg, + const char *format, ...) +{ + va_list args; + + /* + * Contract checking is done in isc_log_doit(). + */ + + va_start(args, format); + isc_log_doit(lctx, category, module, level, ISC_TRUE, + msgcat, msgset, msg, format, args); + va_end(args); +} + +void +isc_log_ivwrite1(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + isc_msgcat_t *msgcat, int msgset, int msg, + const char *format, va_list args) +{ + /* + * Contract checking is done in isc_log_doit(). + */ + isc_log_doit(lctx, category, module, level, ISC_TRUE, + msgcat, msgset, msg, format, args); +} + +void +isc_log_setcontext(isc_log_t *lctx) { + isc_lctx = lctx; +} + +void +isc_log_setdebuglevel(isc_log_t *lctx, unsigned int level) { + isc_logchannel_t *channel; + + REQUIRE(VALID_CONTEXT(lctx)); + + LOCK(&lctx->lock); + + lctx->debug_level = level; + /* + * Close ISC_LOG_DEBUGONLY channels if level is zero. + */ + if (lctx->debug_level == 0) + for (channel = ISC_LIST_HEAD(lctx->logconfig->channels); + channel != NULL; + channel = ISC_LIST_NEXT(channel, link)) + if (channel->type == ISC_LOG_TOFILE && + (channel->flags & ISC_LOG_DEBUGONLY) != 0 && + FILE_STREAM(channel) != NULL) { + (void)fclose(FILE_STREAM(channel)); + FILE_STREAM(channel) = NULL; + } + UNLOCK(&lctx->lock); +} + +unsigned int +isc_log_getdebuglevel(isc_log_t *lctx) { + REQUIRE(VALID_CONTEXT(lctx)); + + return (lctx->debug_level); +} + +void +isc_log_setduplicateinterval(isc_logconfig_t *lcfg, unsigned int interval) { + REQUIRE(VALID_CONFIG(lcfg)); + + lcfg->duplicate_interval = interval; +} + +unsigned int +isc_log_getduplicateinterval(isc_logconfig_t *lcfg) { + REQUIRE(VALID_CONTEXT(lcfg)); + + return (lcfg->duplicate_interval); +} + +isc_result_t +isc_log_settag(isc_logconfig_t *lcfg, const char *tag) { + REQUIRE(VALID_CONFIG(lcfg)); + + if (tag != NULL && *tag != '\0') { + if (lcfg->tag != NULL) + isc_mem_free(lcfg->lctx->mctx, lcfg->tag); + lcfg->tag = isc_mem_strdup(lcfg->lctx->mctx, tag); + if (lcfg->tag == NULL) + return (ISC_R_NOMEMORY); + + } else { + if (lcfg->tag != NULL) + isc_mem_free(lcfg->lctx->mctx, lcfg->tag); + lcfg->tag = NULL; + } + + return (ISC_R_SUCCESS); +} + +char * +isc_log_gettag(isc_logconfig_t *lcfg) { + REQUIRE(VALID_CONFIG(lcfg)); + + return (lcfg->tag); +} + +/* XXXDCL NT -- This interface will assuredly be changing. */ +void +isc_log_opensyslog(const char *tag, int options, int facility) { + (void)openlog(tag, options, facility); +} + +void +isc_log_closefilelogs(isc_log_t *lctx) { + isc_logchannel_t *channel; + + REQUIRE(VALID_CONTEXT(lctx)); + + LOCK(&lctx->lock); + for (channel = ISC_LIST_HEAD(lctx->logconfig->channels); + channel != NULL; + channel = ISC_LIST_NEXT(channel, link)) + + if (channel->type == ISC_LOG_TOFILE && + FILE_STREAM(channel) != NULL) { + (void)fclose(FILE_STREAM(channel)); + FILE_STREAM(channel) = NULL; + } + UNLOCK(&lctx->lock); +} + +/**** + **** Internal functions + ****/ + +static isc_result_t +assignchannel(isc_logconfig_t *lcfg, unsigned int category_id, + const isc_logmodule_t *module, isc_logchannel_t *channel) +{ + isc_logchannellist_t *new_item; + isc_log_t *lctx; + isc_result_t result; + + REQUIRE(VALID_CONFIG(lcfg)); + + lctx = lcfg->lctx; + + REQUIRE(category_id < lctx->category_count); + REQUIRE(module == NULL || module->id < lctx->module_count); + REQUIRE(channel != NULL); + + /* + * Ensure lcfg->channellist_count == lctx->category_count. + */ + result = sync_channellist(lcfg); + if (result != ISC_R_SUCCESS) + return (result); + + new_item = isc_mem_get(lctx->mctx, sizeof(*new_item)); + if (new_item == NULL) + return (ISC_R_NOMEMORY); + + new_item->channel = channel; + new_item->module = module; + ISC_LIST_INITANDPREPEND(lcfg->channellists[category_id], + new_item, link); + + /* + * Remember the highest logging level set by any channel in the + * logging config, so isc_log_doit() can quickly return if the + * message is too high to be logged by any channel. + */ + if (channel->type != ISC_LOG_TONULL) { + if (lcfg->highest_level < channel->level) + lcfg->highest_level = channel->level; + if (channel->level == ISC_LOG_DYNAMIC) + lcfg->dynamic = ISC_TRUE; + } + + return (ISC_R_SUCCESS); +} + +/* + * This would ideally be part of isc_log_registercategories(), except then + * that function would have to return isc_result_t instead of void. + */ +static isc_result_t +sync_channellist(isc_logconfig_t *lcfg) { + unsigned int bytes; + isc_log_t *lctx; + void *lists; + + REQUIRE(VALID_CONFIG(lcfg)); + + lctx = lcfg->lctx; + + REQUIRE(lctx->category_count != 0); + + if (lctx->category_count == lcfg->channellist_count) + return (ISC_R_SUCCESS); + + bytes = lctx->category_count * sizeof(ISC_LIST(isc_logchannellist_t)); + + lists = isc_mem_get(lctx->mctx, bytes); + + if (lists == NULL) + return (ISC_R_NOMEMORY); + + memset(lists, 0, bytes); + + if (lcfg->channellist_count != 0) { + bytes = lcfg->channellist_count * + sizeof(ISC_LIST(isc_logchannellist_t)); + memcpy(lists, lcfg->channellists, bytes); + isc_mem_put(lctx->mctx, lcfg->channellists, bytes); + } + + lcfg->channellists = lists; + lcfg->channellist_count = lctx->category_count; + + return (ISC_R_SUCCESS); +} + +static isc_result_t +greatest_version(isc_logchannel_t *channel, int *greatestp) { + /* XXXDCL HIGHLY NT */ + char *basename, *digit_end; + const char *dirname; + int version, greatest = -1; + unsigned int basenamelen; + isc_dir_t dir; + isc_result_t result; + char sep = '/'; +#ifdef _WIN32 + char *basename2; +#endif + + REQUIRE(channel->type == ISC_LOG_TOFILE); + + /* + * It is safe to DE_CONST the file.name because it was copied + * with isc_mem_strdup in isc_log_createchannel. + */ + basename = strrchr(FILE_NAME(channel), sep); +#ifdef _WIN32 + basename2 = strrchr(FILE_NAME(channel), '\\'); + if ((basename != NULL && basename2 != NULL && basename2 > basename) || + (basename == NULL && basename2 != NULL)) { + basename = basename2; + sep = '\\'; + } +#endif + if (basename != NULL) { + *basename++ = '\0'; + dirname = FILE_NAME(channel); + } else { + DE_CONST(FILE_NAME(channel), basename); + dirname = "."; + } + basenamelen = strlen(basename); + + isc_dir_init(&dir); + result = isc_dir_open(&dir, dirname); + + /* + * Replace the file separator if it was taken out. + */ + if (basename != FILE_NAME(channel)) + *(basename - 1) = sep; + + /* + * Return if the directory open failed. + */ + if (result != ISC_R_SUCCESS) + return (result); + + while (isc_dir_read(&dir) == ISC_R_SUCCESS) { + if (dir.entry.length > basenamelen && + strncmp(dir.entry.name, basename, basenamelen) == 0 && + dir.entry.name[basenamelen] == '.') { + + version = strtol(&dir.entry.name[basenamelen + 1], + &digit_end, 10); + if (*digit_end == '\0' && version > greatest) + greatest = version; + } + } + isc_dir_close(&dir); + + *greatestp = ++greatest; + + return (ISC_R_SUCCESS); +} + +static isc_result_t +roll_log(isc_logchannel_t *channel) { + int i, n, greatest; + char current[PATH_MAX + 1]; + char new[PATH_MAX + 1]; + const char *path; + isc_result_t result; + + /* + * Do nothing (not even excess version trimming) if ISC_LOG_ROLLNEVER + * is specified. Apparently complete external control over the log + * files is desired. + */ + if (FILE_VERSIONS(channel) == ISC_LOG_ROLLNEVER) + return (ISC_R_SUCCESS); + + path = FILE_NAME(channel); + + /* + * Set greatest_version to the greatest existing version + * (not the maximum requested version). This is 1 based even + * though the file names are 0 based, so an oldest log of log.1 + * is a greatest_version of 2. + */ + result = greatest_version(channel, &greatest); + if (result != ISC_R_SUCCESS) + return (result); + + /* + * Now greatest should be set to the highest version number desired. + * Since the highest number is one less than FILE_VERSIONS(channel) + * when not doing infinite log rolling, greatest will need to be + * decremented when it is equal to -- or greater than -- + * FILE_VERSIONS(channel). When greatest is less than + * FILE_VERSIONS(channel), it is already suitable for use as + * the maximum version number. + */ + + if (FILE_VERSIONS(channel) == ISC_LOG_ROLLINFINITE || + FILE_VERSIONS(channel) > greatest) + ; /* Do nothing. */ + else + /* + * When greatest is >= FILE_VERSIONS(channel), it needs to + * be reduced until it is FILE_VERSIONS(channel) - 1. + * Remove any excess logs on the way to that value. + */ + while (--greatest >= FILE_VERSIONS(channel)) { + n = snprintf(current, sizeof(current), "%s.%d", + path, greatest); + if (n >= (int)sizeof(current) || n < 0) + result = ISC_R_NOSPACE; + else + result = isc_file_remove(current); + if (result != ISC_R_SUCCESS && + result != ISC_R_FILENOTFOUND) + syslog(LOG_ERR, + "unable to remove log file '%s.%d': %s", + path, greatest, + isc_result_totext(result)); + } + + for (i = greatest; i > 0; i--) { + result = ISC_R_SUCCESS; + n = snprintf(current, sizeof(current), "%s.%d", path, i - 1); + if (n >= (int)sizeof(current) || n < 0) + result = ISC_R_NOSPACE; + if (result == ISC_R_SUCCESS) { + n = snprintf(new, sizeof(new), "%s.%d", path, i); + if (n >= (int)sizeof(new) || n < 0) + result = ISC_R_NOSPACE; + } + if (result == ISC_R_SUCCESS) + result = isc_file_rename(current, new); + if (result != ISC_R_SUCCESS && + result != ISC_R_FILENOTFOUND) + syslog(LOG_ERR, + "unable to rename log file '%s.%d' to " + "'%s.%d': %s", path, i - 1, path, i, + isc_result_totext(result)); + } + + if (FILE_VERSIONS(channel) != 0) { + n = snprintf(new, sizeof(new), "%s.0", path); + if (n >= (int)sizeof(new) || n < 0) + result = ISC_R_NOSPACE; + else + result = isc_file_rename(path, new); + if (result != ISC_R_SUCCESS && + result != ISC_R_FILENOTFOUND) + syslog(LOG_ERR, + "unable to rename log file '%s' to '%s.0': %s", + path, path, isc_result_totext(result)); + } else { + result = isc_file_remove(path); + if (result != ISC_R_SUCCESS && + result != ISC_R_FILENOTFOUND) + syslog(LOG_ERR, "unable to remove log file '%s': %s", + path, isc_result_totext(result)); + } + + return (ISC_R_SUCCESS); +} + +static isc_result_t +isc_log_open(isc_logchannel_t *channel) { + struct stat statbuf; + isc_boolean_t regular_file; + isc_boolean_t roll = ISC_FALSE; + isc_result_t result = ISC_R_SUCCESS; + const char *path; + + REQUIRE(channel->type == ISC_LOG_TOFILE); + REQUIRE(FILE_STREAM(channel) == NULL); + + path = FILE_NAME(channel); + + REQUIRE(path != NULL && *path != '\0'); + + /* + * Determine type of file; only regular files will be + * version renamed, and only if the base file exists + * and either has no size limit or has reached its size limit. + */ + if (stat(path, &statbuf) == 0) { + regular_file = S_ISREG(statbuf.st_mode) ? ISC_TRUE : ISC_FALSE; + /* XXXDCL if not regular_file complain? */ + if ((FILE_MAXSIZE(channel) == 0 && + FILE_VERSIONS(channel) != ISC_LOG_ROLLNEVER) || + (FILE_MAXSIZE(channel) > 0 && + statbuf.st_size >= FILE_MAXSIZE(channel))) + roll = regular_file; + } else if (errno == ENOENT) + regular_file = ISC_TRUE; + else + result = ISC_R_INVALIDFILE; + + /* + * Version control. + */ + if (result == ISC_R_SUCCESS && roll) { + if (FILE_VERSIONS(channel) == ISC_LOG_ROLLNEVER) + return (ISC_R_MAXSIZE); + result = roll_log(channel); + if (result != ISC_R_SUCCESS) { + if ((channel->flags & ISC_LOG_OPENERR) == 0) { + syslog(LOG_ERR, + "isc_log_open: roll_log '%s' " + "failed: %s", + FILE_NAME(channel), + isc_result_totext(result)); + channel->flags |= ISC_LOG_OPENERR; + } + return (result); + } + } + + result = isc_stdio_open(path, "a", &FILE_STREAM(channel)); + + return (result); +} + +isc_boolean_t +isc_log_wouldlog(isc_log_t *lctx, int level) { + /* + * Try to avoid locking the mutex for messages which can't + * possibly be logged to any channels -- primarily debugging + * messages that the debug level is not high enough to print. + * + * If the level is (mathematically) less than or equal to the + * highest_level, or if there is a dynamic channel and the level is + * less than or equal to the debug level, the main loop must be + * entered to see if the message should really be output. + * + * NOTE: this is UNLOCKED access to the logconfig. However, + * the worst thing that can happen is that a bad decision is made + * about returning without logging, and that's not a big concern, + * because that's a risk anyway if the logconfig is being + * dynamically changed. + */ + + if (lctx == NULL || lctx->logconfig == NULL) + return (ISC_FALSE); + + return (ISC_TF(level <= lctx->logconfig->highest_level || + (lctx->logconfig->dynamic && + level <= lctx->debug_level))); +} + +static void +isc_log_doit(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, isc_boolean_t write_once, + isc_msgcat_t *msgcat, int msgset, int msg, + const char *format, va_list args) +{ + int syslog_level; + char time_string[64]; + char level_string[24]; + const char *iformat; + struct stat statbuf; + isc_boolean_t matched = ISC_FALSE; + isc_boolean_t printtime, printtag; + isc_boolean_t printcategory, printmodule, printlevel; + isc_logconfig_t *lcfg; + isc_logchannel_t *channel; + isc_logchannellist_t *category_channels; + isc_result_t result; + + REQUIRE(lctx == NULL || VALID_CONTEXT(lctx)); + REQUIRE(category != NULL); + REQUIRE(module != NULL); + REQUIRE(level != ISC_LOG_DYNAMIC); + REQUIRE(format != NULL); + + /* + * Programs can use libraries that use this logging code without + * wanting to do any logging, thus the log context is allowed to + * be non-existent. + */ + if (lctx == NULL) + return; + + REQUIRE(category->id < lctx->category_count); + REQUIRE(module->id < lctx->module_count); + + if (! isc_log_wouldlog(lctx, level)) + return; + + if (msgcat != NULL) + iformat = isc_msgcat_get(msgcat, msgset, msg, format); + else + iformat = format; + + time_string[0] = '\0'; + level_string[0] = '\0'; + + LOCK(&lctx->lock); + + lctx->buffer[0] = '\0'; + + lcfg = lctx->logconfig; + + category_channels = ISC_LIST_HEAD(lcfg->channellists[category->id]); + + /* + * XXXDCL add duplicate filtering? (To not write multiple times to + * the same source via various channels). + */ + do { + /* + * If the channel list end was reached and a match was made, + * everything is finished. + */ + if (category_channels == NULL && matched) + break; + + if (category_channels == NULL && ! matched && + category_channels != ISC_LIST_HEAD(lcfg->channellists[0])) + /* + * No category/module pair was explicitly configured. + * Try the category named "default". + */ + category_channels = + ISC_LIST_HEAD(lcfg->channellists[0]); + + if (category_channels == NULL && ! matched) + /* + * No matching module was explicitly configured + * for the category named "default". Use the internal + * default channel. + */ + category_channels = &default_channel; + + if (category_channels->module != NULL && + category_channels->module != module) { + category_channels = ISC_LIST_NEXT(category_channels, + link); + continue; + } + + matched = ISC_TRUE; + + channel = category_channels->channel; + category_channels = ISC_LIST_NEXT(category_channels, link); + + if (((channel->flags & ISC_LOG_DEBUGONLY) != 0) && + lctx->debug_level == 0) + continue; + + if (channel->level == ISC_LOG_DYNAMIC) { + if (lctx->debug_level < level) + continue; + } else if (channel->level < level) + continue; + + if ((channel->flags & ISC_LOG_PRINTTIME) != 0 && + time_string[0] == '\0') { + isc_time_t isctime; + + TIME_NOW(&isctime); + isc_time_formattimestamp(&isctime, time_string, + sizeof(time_string)); + } + + if ((channel->flags & ISC_LOG_PRINTLEVEL) != 0 && + level_string[0] == '\0') { + if (level < ISC_LOG_CRITICAL) + snprintf(level_string, sizeof(level_string), + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_LOG, + ISC_MSG_LEVEL, + "level %d: "), + level); + else if (level > ISC_LOG_DYNAMIC) + snprintf(level_string, sizeof(level_string), + "%s %d: ", log_level_strings[0], + level); + else + snprintf(level_string, sizeof(level_string), + "%s: ", log_level_strings[-level]); + } + + /* + * Only format the message once. + */ + if (lctx->buffer[0] == '\0') { + (void)vsnprintf(lctx->buffer, sizeof(lctx->buffer), + iformat, args); + + /* + * Check for duplicates. + */ + if (write_once) { + isc_logmessage_t *message, *new; + isc_time_t oldest; + isc_interval_t interval; + + isc_interval_set(&interval, + lcfg->duplicate_interval, 0); + + /* + * 'oldest' is the age of the oldest messages + * which fall within the duplicate_interval + * range. + */ + TIME_NOW(&oldest); + if (isc_time_subtract(&oldest, &interval, &oldest) + != ISC_R_SUCCESS) + /* + * Can't effectively do the checking + * without having a valid time. + */ + message = NULL; + else + message =ISC_LIST_HEAD(lctx->messages); + + while (message != NULL) { + if (isc_time_compare(&message->time, + &oldest) < 0) { + /* + * This message is older + * than the duplicate_interval, + * so it should be dropped from + * the history. + * + * Setting the interval to be + * to be longer will obviously + * not cause the expired + * message to spring back into + * existence. + */ + new = ISC_LIST_NEXT(message, + link); + + ISC_LIST_UNLINK(lctx->messages, + message, link); + + isc_mem_put(lctx->mctx, + message, + sizeof(*message) + 1 + + strlen(message->text)); + + message = new; + continue; + } + + /* + * This message is in the duplicate + * filtering interval ... + */ + if (strcmp(lctx->buffer, message->text) + == 0) { + /* + * ... and it is a duplicate. + * Unlock the mutex and + * get the hell out of Dodge. + */ + UNLOCK(&lctx->lock); + return; + } + + message = ISC_LIST_NEXT(message, link); + } + + /* + * It wasn't in the duplicate interval, + * so add it to the message list. + */ + new = isc_mem_get(lctx->mctx, + sizeof(isc_logmessage_t) + + strlen(lctx->buffer) + 1); + if (new != NULL) { + /* + * Put the text immediately after + * the struct. The strcpy is safe. + */ + new->text = (char *)(new + 1); + strcpy(new->text, lctx->buffer); + + TIME_NOW(&new->time); + + ISC_LIST_APPEND(lctx->messages, + new, link); + } + } + } + + printtime = ISC_TF((channel->flags & ISC_LOG_PRINTTIME) + != 0); + printtag = ISC_TF((channel->flags & ISC_LOG_PRINTTAG) + != 0 && lcfg->tag != NULL); + printcategory = ISC_TF((channel->flags & ISC_LOG_PRINTCATEGORY) + != 0); + printmodule = ISC_TF((channel->flags & ISC_LOG_PRINTMODULE) + != 0); + printlevel = ISC_TF((channel->flags & ISC_LOG_PRINTLEVEL) + != 0); + + switch (channel->type) { + case ISC_LOG_TOFILE: + if (FILE_MAXREACHED(channel)) { + /* + * If the file can be rolled, OR + * If the file no longer exists, OR + * If the file is less than the maximum size, + * (such as if it had been renamed and + * a new one touched, or it was truncated + * in place) + * ... then close it to trigger reopening. + */ + if (FILE_VERSIONS(channel) != + ISC_LOG_ROLLNEVER || + (stat(FILE_NAME(channel), &statbuf) != 0 && + errno == ENOENT) || + statbuf.st_size < FILE_MAXSIZE(channel)) { + (void)fclose(FILE_STREAM(channel)); + FILE_STREAM(channel) = NULL; + FILE_MAXREACHED(channel) = ISC_FALSE; + } else + /* + * Eh, skip it. + */ + break; + } + + if (FILE_STREAM(channel) == NULL) { + result = isc_log_open(channel); + if (result != ISC_R_SUCCESS && + result != ISC_R_MAXSIZE && + (channel->flags & ISC_LOG_OPENERR) == 0) { + syslog(LOG_ERR, + "isc_log_open '%s' failed: %s", + FILE_NAME(channel), + isc_result_totext(result)); + channel->flags |= ISC_LOG_OPENERR; + } + if (result != ISC_R_SUCCESS) + break; + channel->flags &= ~ISC_LOG_OPENERR; + } + /* FALLTHROUGH */ + + case ISC_LOG_TOFILEDESC: + fprintf(FILE_STREAM(channel), "%s%s%s%s%s%s%s%s%s%s\n", + printtime ? time_string : "", + printtime ? " " : "", + printtag ? lcfg->tag : "", + printtag ? ": " : "", + printcategory ? category->name : "", + printcategory ? ": " : "", + printmodule ? (module != NULL ? module->name + : "no_module") + : "", + printmodule ? ": " : "", + printlevel ? level_string : "", + lctx->buffer); + + fflush(FILE_STREAM(channel)); + + /* + * If the file now exceeds its maximum size + * threshold, note it so that it will not be logged + * to any more. + */ + if (FILE_MAXSIZE(channel) > 0) { + INSIST(channel->type == ISC_LOG_TOFILE); + + /* XXXDCL NT fstat/fileno */ + /* XXXDCL complain if fstat fails? */ + if (fstat(fileno(FILE_STREAM(channel)), + &statbuf) >= 0 && + statbuf.st_size > FILE_MAXSIZE(channel)) + FILE_MAXREACHED(channel) = ISC_TRUE; + } + + break; + + case ISC_LOG_TOSYSLOG: + if (level > 0) + syslog_level = LOG_DEBUG; + else if (level < ISC_LOG_CRITICAL) + syslog_level = LOG_CRIT; + else + syslog_level = syslog_map[-level]; + + (void)syslog(FACILITY(channel) | syslog_level, + "%s%s%s%s%s%s%s%s%s%s", + printtime ? time_string : "", + printtime ? " " : "", + printtag ? lcfg->tag : "", + printtag ? ": " : "", + printcategory ? category->name : "", + printcategory ? ": " : "", + printmodule ? (module != NULL ? module->name + : "no_module") + : "", + printmodule ? ": " : "", + printlevel ? level_string : "", + lctx->buffer); + break; + + case ISC_LOG_TONULL: + break; + + } + + } while (1); + + UNLOCK(&lctx->lock); +} diff -urN src/contrib/ntp/lib/isc/md5.c src.ntp/contrib/ntp/lib/isc/md5.c --- src/contrib/ntp/lib/isc/md5.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/md5.c 2009-12-09 08:36:44.000000000 +0100 @@ -0,0 +1,251 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: md5.c,v 1.14 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file + * This code implements the MD5 message-digest algorithm. + * The algorithm is due to Ron Rivest. This code was + * written by Colin Plumb in 1993, no copyright is claimed. + * This code is in the public domain; do with it what you wish. + * + * Equivalent code is available from RSA Data Security, Inc. + * This code has been tested against that, and is equivalent, + * except that you don't need to include two pages of legalese + * with every copy. + * + * To compute the message digest of a chunk of bytes, declare an + * MD5Context structure, pass it to MD5Init, call MD5Update as + * needed on buffers full of bytes, and then call MD5Final, which + * will fill a supplied 16-byte array with the digest. + */ + +#include "config.h" + +#include +#include +#include +#include +#include + +static void +byteSwap(isc_uint32_t *buf, unsigned words) +{ + unsigned char *p = (unsigned char *)buf; + + do { + *buf++ = (isc_uint32_t)((unsigned)p[3] << 8 | p[2]) << 16 | + ((unsigned)p[1] << 8 | p[0]); + p += 4; + } while (--words); +} + +/*! + * Start MD5 accumulation. Set bit count to 0 and buffer to mysterious + * initialization constants. + */ +void +isc_md5_init(isc_md5_t *ctx) { + ctx->buf[0] = 0x67452301; + ctx->buf[1] = 0xefcdab89; + ctx->buf[2] = 0x98badcfe; + ctx->buf[3] = 0x10325476; + + ctx->bytes[0] = 0; + ctx->bytes[1] = 0; +} + +void +isc_md5_invalidate(isc_md5_t *ctx) { + memset(ctx, 0, sizeof(isc_md5_t)); +} + +/*@{*/ +/*! The four core functions - F1 is optimized somewhat */ + +/* #define F1(x, y, z) (x & y | ~x & z) */ +#define F1(x, y, z) (z ^ (x & (y ^ z))) +#define F2(x, y, z) F1(z, x, y) +#define F3(x, y, z) (x ^ y ^ z) +#define F4(x, y, z) (y ^ (x | ~z)) +/*@}*/ + +/*! This is the central step in the MD5 algorithm. */ +#define MD5STEP(f,w,x,y,z,in,s) \ + (w += f(x,y,z) + in, w = (w<>(32-s)) + x) + +/*! + * The core of the MD5 algorithm, this alters an existing MD5 hash to + * reflect the addition of 16 longwords of new data. MD5Update blocks + * the data and converts bytes into longwords for this routine. + */ +static void +transform(isc_uint32_t buf[4], isc_uint32_t const in[16]) { + register isc_uint32_t a, b, c, d; + + a = buf[0]; + b = buf[1]; + c = buf[2]; + d = buf[3]; + + MD5STEP(F1, a, b, c, d, in[0] + 0xd76aa478, 7); + MD5STEP(F1, d, a, b, c, in[1] + 0xe8c7b756, 12); + MD5STEP(F1, c, d, a, b, in[2] + 0x242070db, 17); + MD5STEP(F1, b, c, d, a, in[3] + 0xc1bdceee, 22); + MD5STEP(F1, a, b, c, d, in[4] + 0xf57c0faf, 7); + MD5STEP(F1, d, a, b, c, in[5] + 0x4787c62a, 12); + MD5STEP(F1, c, d, a, b, in[6] + 0xa8304613, 17); + MD5STEP(F1, b, c, d, a, in[7] + 0xfd469501, 22); + MD5STEP(F1, a, b, c, d, in[8] + 0x698098d8, 7); + MD5STEP(F1, d, a, b, c, in[9] + 0x8b44f7af, 12); + MD5STEP(F1, c, d, a, b, in[10] + 0xffff5bb1, 17); + MD5STEP(F1, b, c, d, a, in[11] + 0x895cd7be, 22); + MD5STEP(F1, a, b, c, d, in[12] + 0x6b901122, 7); + MD5STEP(F1, d, a, b, c, in[13] + 0xfd987193, 12); + MD5STEP(F1, c, d, a, b, in[14] + 0xa679438e, 17); + MD5STEP(F1, b, c, d, a, in[15] + 0x49b40821, 22); + + MD5STEP(F2, a, b, c, d, in[1] + 0xf61e2562, 5); + MD5STEP(F2, d, a, b, c, in[6] + 0xc040b340, 9); + MD5STEP(F2, c, d, a, b, in[11] + 0x265e5a51, 14); + MD5STEP(F2, b, c, d, a, in[0] + 0xe9b6c7aa, 20); + MD5STEP(F2, a, b, c, d, in[5] + 0xd62f105d, 5); + MD5STEP(F2, d, a, b, c, in[10] + 0x02441453, 9); + MD5STEP(F2, c, d, a, b, in[15] + 0xd8a1e681, 14); + MD5STEP(F2, b, c, d, a, in[4] + 0xe7d3fbc8, 20); + MD5STEP(F2, a, b, c, d, in[9] + 0x21e1cde6, 5); + MD5STEP(F2, d, a, b, c, in[14] + 0xc33707d6, 9); + MD5STEP(F2, c, d, a, b, in[3] + 0xf4d50d87, 14); + MD5STEP(F2, b, c, d, a, in[8] + 0x455a14ed, 20); + MD5STEP(F2, a, b, c, d, in[13] + 0xa9e3e905, 5); + MD5STEP(F2, d, a, b, c, in[2] + 0xfcefa3f8, 9); + MD5STEP(F2, c, d, a, b, in[7] + 0x676f02d9, 14); + MD5STEP(F2, b, c, d, a, in[12] + 0x8d2a4c8a, 20); + + MD5STEP(F3, a, b, c, d, in[5] + 0xfffa3942, 4); + MD5STEP(F3, d, a, b, c, in[8] + 0x8771f681, 11); + MD5STEP(F3, c, d, a, b, in[11] + 0x6d9d6122, 16); + MD5STEP(F3, b, c, d, a, in[14] + 0xfde5380c, 23); + MD5STEP(F3, a, b, c, d, in[1] + 0xa4beea44, 4); + MD5STEP(F3, d, a, b, c, in[4] + 0x4bdecfa9, 11); + MD5STEP(F3, c, d, a, b, in[7] + 0xf6bb4b60, 16); + MD5STEP(F3, b, c, d, a, in[10] + 0xbebfbc70, 23); + MD5STEP(F3, a, b, c, d, in[13] + 0x289b7ec6, 4); + MD5STEP(F3, d, a, b, c, in[0] + 0xeaa127fa, 11); + MD5STEP(F3, c, d, a, b, in[3] + 0xd4ef3085, 16); + MD5STEP(F3, b, c, d, a, in[6] + 0x04881d05, 23); + MD5STEP(F3, a, b, c, d, in[9] + 0xd9d4d039, 4); + MD5STEP(F3, d, a, b, c, in[12] + 0xe6db99e5, 11); + MD5STEP(F3, c, d, a, b, in[15] + 0x1fa27cf8, 16); + MD5STEP(F3, b, c, d, a, in[2] + 0xc4ac5665, 23); + + MD5STEP(F4, a, b, c, d, in[0] + 0xf4292244, 6); + MD5STEP(F4, d, a, b, c, in[7] + 0x432aff97, 10); + MD5STEP(F4, c, d, a, b, in[14] + 0xab9423a7, 15); + MD5STEP(F4, b, c, d, a, in[5] + 0xfc93a039, 21); + MD5STEP(F4, a, b, c, d, in[12] + 0x655b59c3, 6); + MD5STEP(F4, d, a, b, c, in[3] + 0x8f0ccc92, 10); + MD5STEP(F4, c, d, a, b, in[10] + 0xffeff47d, 15); + MD5STEP(F4, b, c, d, a, in[1] + 0x85845dd1, 21); + MD5STEP(F4, a, b, c, d, in[8] + 0x6fa87e4f, 6); + MD5STEP(F4, d, a, b, c, in[15] + 0xfe2ce6e0, 10); + MD5STEP(F4, c, d, a, b, in[6] + 0xa3014314, 15); + MD5STEP(F4, b, c, d, a, in[13] + 0x4e0811a1, 21); + MD5STEP(F4, a, b, c, d, in[4] + 0xf7537e82, 6); + MD5STEP(F4, d, a, b, c, in[11] + 0xbd3af235, 10); + MD5STEP(F4, c, d, a, b, in[2] + 0x2ad7d2bb, 15); + MD5STEP(F4, b, c, d, a, in[9] + 0xeb86d391, 21); + + buf[0] += a; + buf[1] += b; + buf[2] += c; + buf[3] += d; +} + +/*! + * Update context to reflect the concatenation of another buffer full + * of bytes. + */ +void +isc_md5_update(isc_md5_t *ctx, const unsigned char *buf, unsigned int len) { + isc_uint32_t t; + + /* Update byte count */ + + t = ctx->bytes[0]; + if ((ctx->bytes[0] = t + len) < t) + ctx->bytes[1]++; /* Carry from low to high */ + + t = 64 - (t & 0x3f); /* Space available in ctx->in (at least 1) */ + if (t > len) { + memcpy((unsigned char *)ctx->in + 64 - t, buf, len); + return; + } + /* First chunk is an odd size */ + memcpy((unsigned char *)ctx->in + 64 - t, buf, t); + byteSwap(ctx->in, 16); + transform(ctx->buf, ctx->in); + buf += t; + len -= t; + + /* Process data in 64-byte chunks */ + while (len >= 64) { + memcpy(ctx->in, buf, 64); + byteSwap(ctx->in, 16); + transform(ctx->buf, ctx->in); + buf += 64; + len -= 64; + } + + /* Handle any remaining bytes of data. */ + memcpy(ctx->in, buf, len); +} + +/*! + * Final wrapup - pad to 64-byte boundary with the bit pattern + * 1 0* (64-bit count of bits processed, MSB-first) + */ +void +isc_md5_final(isc_md5_t *ctx, unsigned char *digest) { + int count = ctx->bytes[0] & 0x3f; /* Number of bytes in ctx->in */ + unsigned char *p = (unsigned char *)ctx->in + count; + + /* Set the first char of padding to 0x80. There is always room. */ + *p++ = 0x80; + + /* Bytes of padding needed to make 56 bytes (-8..55) */ + count = 56 - 1 - count; + + if (count < 0) { /* Padding forces an extra block */ + memset(p, 0, count + 8); + byteSwap(ctx->in, 16); + transform(ctx->buf, ctx->in); + p = (unsigned char *)ctx->in; + count = 56; + } + memset(p, 0, count); + byteSwap(ctx->in, 14); + + /* Append length in bits and transform */ + ctx->in[14] = ctx->bytes[0] << 3; + ctx->in[15] = ctx->bytes[1] << 3 | ctx->bytes[0] >> 29; + transform(ctx->buf, ctx->in); + + byteSwap(ctx->buf, 4); + memcpy(digest, ctx->buf, 16); + memset(ctx, 0, sizeof(isc_md5_t)); /* In case it's sensitive */ +} diff -urN src/contrib/ntp/lib/isc/mem.c src.ntp/contrib/ntp/lib/isc/mem.c --- src/contrib/ntp/lib/isc/mem.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/mem.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,2205 @@ +/* + * Copyright (C) 2004-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1997-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: mem.c,v 1.145.120.4 2009/02/16 03:17:05 marka Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include + +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#define MCTXLOCK(m, l) if (((m)->flags & ISC_MEMFLAG_NOLOCK) == 0) LOCK(l) +#define MCTXUNLOCK(m, l) if (((m)->flags & ISC_MEMFLAG_NOLOCK) == 0) UNLOCK(l) + +#ifndef ISC_MEM_DEBUGGING +#define ISC_MEM_DEBUGGING 0 +#endif +LIBISC_EXTERNAL_DATA unsigned int isc_mem_debugging = ISC_MEM_DEBUGGING; + +/* + * Constants. + */ + +#define DEF_MAX_SIZE 1100 +#define DEF_MEM_TARGET 4096 +#define ALIGNMENT_SIZE 8U /*%< must be a power of 2 */ +#define NUM_BASIC_BLOCKS 64 /*%< must be > 1 */ +#define TABLE_INCREMENT 1024 +#define DEBUGLIST_COUNT 1024 + +/* + * Types. + */ +#if ISC_MEM_TRACKLINES +typedef struct debuglink debuglink_t; +struct debuglink { + ISC_LINK(debuglink_t) link; + const void *ptr[DEBUGLIST_COUNT]; + unsigned int size[DEBUGLIST_COUNT]; + const char *file[DEBUGLIST_COUNT]; + unsigned int line[DEBUGLIST_COUNT]; + unsigned int count; +}; + +#define FLARG_PASS , file, line +#define FLARG , const char *file, int line +#else +#define FLARG_PASS +#define FLARG +#endif + +typedef struct element element; +struct element { + element * next; +}; + +typedef struct { + /*! + * This structure must be ALIGNMENT_SIZE bytes. + */ + union { + size_t size; + isc_mem_t *ctx; + char bytes[ALIGNMENT_SIZE]; + } u; +} size_info; + +struct stats { + unsigned long gets; + unsigned long totalgets; + unsigned long blocks; + unsigned long freefrags; +}; + +#define MEM_MAGIC ISC_MAGIC('M', 'e', 'm', 'C') +#define VALID_CONTEXT(c) ISC_MAGIC_VALID(c, MEM_MAGIC) + +#if ISC_MEM_TRACKLINES +typedef ISC_LIST(debuglink_t) debuglist_t; +#endif + +/* List of all active memory contexts. */ + +static ISC_LIST(isc_mem_t) contexts; +static isc_once_t once = ISC_ONCE_INIT; +static isc_mutex_t lock; + +/*% + * Total size of lost memory due to a bug of external library. + * Locked by the global lock. + */ +static isc_uint64_t totallost; + +struct isc_mem { + unsigned int magic; + isc_ondestroy_t ondestroy; + unsigned int flags; + isc_mutex_t lock; + isc_memalloc_t memalloc; + isc_memfree_t memfree; + void * arg; + size_t max_size; + isc_boolean_t checkfree; + struct stats * stats; + unsigned int references; + char name[16]; + void * tag; + size_t quota; + size_t total; + size_t inuse; + size_t maxinuse; + size_t hi_water; + size_t lo_water; + isc_boolean_t hi_called; + isc_mem_water_t water; + void * water_arg; + ISC_LIST(isc_mempool_t) pools; + unsigned int poolcnt; + + /* ISC_MEMFLAG_INTERNAL */ + size_t mem_target; + element ** freelists; + element * basic_blocks; + unsigned char ** basic_table; + unsigned int basic_table_count; + unsigned int basic_table_size; + unsigned char * lowest; + unsigned char * highest; + +#if ISC_MEM_TRACKLINES + debuglist_t * debuglist; + unsigned int debuglistcnt; +#endif + + unsigned int memalloc_failures; + ISC_LINK(isc_mem_t) link; +}; + +#define MEMPOOL_MAGIC ISC_MAGIC('M', 'E', 'M', 'p') +#define VALID_MEMPOOL(c) ISC_MAGIC_VALID(c, MEMPOOL_MAGIC) + +struct isc_mempool { + /* always unlocked */ + unsigned int magic; /*%< magic number */ + isc_mutex_t *lock; /*%< optional lock */ + isc_mem_t *mctx; /*%< our memory context */ + /*%< locked via the memory context's lock */ + ISC_LINK(isc_mempool_t) link; /*%< next pool in this mem context */ + /*%< optionally locked from here down */ + element *items; /*%< low water item list */ + size_t size; /*%< size of each item on this pool */ + unsigned int maxalloc; /*%< max number of items allowed */ + unsigned int allocated; /*%< # of items currently given out */ + unsigned int freecount; /*%< # of items on reserved list */ + unsigned int freemax; /*%< # of items allowed on free list */ + unsigned int fillcount; /*%< # of items to fetch on each fill */ + /*%< Stats only. */ + unsigned int gets; /*%< # of requests to this pool */ + /*%< Debugging only. */ +#if ISC_MEMPOOL_NAMES + char name[16]; /*%< printed name in stats reports */ +#endif +}; + +/* + * Private Inline-able. + */ + +#if ! ISC_MEM_TRACKLINES +#define ADD_TRACE(a, b, c, d, e) +#define DELETE_TRACE(a, b, c, d, e) +#else +#define ADD_TRACE(a, b, c, d, e) \ + do { \ + if ((isc_mem_debugging & (ISC_MEM_DEBUGTRACE | \ + ISC_MEM_DEBUGRECORD)) != 0 && \ + b != NULL) \ + add_trace_entry(a, b, c, d, e); \ + } while (0) +#define DELETE_TRACE(a, b, c, d, e) delete_trace_entry(a, b, c, d, e) + +static void +print_active(isc_mem_t *ctx, FILE *out); + +/*! + * mctx must be locked. + */ +static inline void +add_trace_entry(isc_mem_t *mctx, const void *ptr, unsigned int size + FLARG) +{ + debuglink_t *dl; + unsigned int i; + + if ((isc_mem_debugging & ISC_MEM_DEBUGTRACE) != 0) + fprintf(stderr, isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_ADDTRACE, + "add %p size %u " + "file %s line %u mctx %p\n"), + ptr, size, file, line, mctx); + + if (mctx->debuglist == NULL) + return; + + if (size > mctx->max_size) + size = mctx->max_size; + + dl = ISC_LIST_HEAD(mctx->debuglist[size]); + while (dl != NULL) { + if (dl->count == DEBUGLIST_COUNT) + goto next; + for (i = 0; i < DEBUGLIST_COUNT; i++) { + if (dl->ptr[i] == NULL) { + dl->ptr[i] = ptr; + dl->size[i] = size; + dl->file[i] = file; + dl->line[i] = line; + dl->count++; + return; + } + } + next: + dl = ISC_LIST_NEXT(dl, link); + } + + dl = malloc(sizeof(debuglink_t)); + INSIST(dl != NULL); + + ISC_LINK_INIT(dl, link); + for (i = 1; i < DEBUGLIST_COUNT; i++) { + dl->ptr[i] = NULL; + dl->size[i] = 0; + dl->file[i] = NULL; + dl->line[i] = 0; + } + + dl->ptr[0] = ptr; + dl->size[0] = size; + dl->file[0] = file; + dl->line[0] = line; + dl->count = 1; + + ISC_LIST_PREPEND(mctx->debuglist[size], dl, link); + mctx->debuglistcnt++; +} + +static inline void +delete_trace_entry(isc_mem_t *mctx, const void *ptr, unsigned int size, + const char *file, unsigned int line) +{ + debuglink_t *dl; + unsigned int i; + + if ((isc_mem_debugging & ISC_MEM_DEBUGTRACE) != 0) + fprintf(stderr, isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_DELTRACE, + "del %p size %u " + "file %s line %u mctx %p\n"), + ptr, size, file, line, mctx); + + if (mctx->debuglist == NULL) + return; + + if (size > mctx->max_size) + size = mctx->max_size; + + dl = ISC_LIST_HEAD(mctx->debuglist[size]); + while (dl != NULL) { + for (i = 0; i < DEBUGLIST_COUNT; i++) { + if (dl->ptr[i] == ptr) { + dl->ptr[i] = NULL; + dl->size[i] = 0; + dl->file[i] = NULL; + dl->line[i] = 0; + + INSIST(dl->count > 0); + dl->count--; + if (dl->count == 0) { + ISC_LIST_UNLINK(mctx->debuglist[size], + dl, link); + free(dl); + } + return; + } + } + dl = ISC_LIST_NEXT(dl, link); + } + + /* + * If we get here, we didn't find the item on the list. We're + * screwed. + */ + INSIST(dl != NULL); +} +#endif /* ISC_MEM_TRACKLINES */ + +static inline size_t +rmsize(size_t size) { + /* + * round down to ALIGNMENT_SIZE + */ + return (size & (~(ALIGNMENT_SIZE - 1))); +} + +static inline size_t +quantize(size_t size) { + /*! + * Round up the result in order to get a size big + * enough to satisfy the request and be aligned on ALIGNMENT_SIZE + * byte boundaries. + */ + + if (size == 0U) + return (ALIGNMENT_SIZE); + return ((size + ALIGNMENT_SIZE - 1) & (~(ALIGNMENT_SIZE - 1))); +} + +static inline isc_boolean_t +more_basic_blocks(isc_mem_t *ctx) { + void *new; + unsigned char *curr, *next; + unsigned char *first, *last; + unsigned char **table; + unsigned int table_size; + size_t increment; + int i; + + /* Require: we hold the context lock. */ + + /* + * Did we hit the quota for this context? + */ + increment = NUM_BASIC_BLOCKS * ctx->mem_target; + if (ctx->quota != 0U && ctx->total + increment > ctx->quota) + return (ISC_FALSE); + + INSIST(ctx->basic_table_count <= ctx->basic_table_size); + if (ctx->basic_table_count == ctx->basic_table_size) { + table_size = ctx->basic_table_size + TABLE_INCREMENT; + table = (ctx->memalloc)(ctx->arg, + table_size * sizeof(unsigned char *)); + if (table == NULL) { + ctx->memalloc_failures++; + return (ISC_FALSE); + } + if (ctx->basic_table_size != 0) { + memcpy(table, ctx->basic_table, + ctx->basic_table_size * + sizeof(unsigned char *)); + (ctx->memfree)(ctx->arg, ctx->basic_table); + } + ctx->basic_table = table; + ctx->basic_table_size = table_size; + } + + new = (ctx->memalloc)(ctx->arg, NUM_BASIC_BLOCKS * ctx->mem_target); + if (new == NULL) { + ctx->memalloc_failures++; + return (ISC_FALSE); + } + ctx->total += increment; + ctx->basic_table[ctx->basic_table_count] = new; + ctx->basic_table_count++; + + curr = new; + next = curr + ctx->mem_target; + for (i = 0; i < (NUM_BASIC_BLOCKS - 1); i++) { + ((element *)curr)->next = (element *)next; + curr = next; + next += ctx->mem_target; + } + /* + * curr is now pointing at the last block in the + * array. + */ + ((element *)curr)->next = NULL; + first = new; + last = first + NUM_BASIC_BLOCKS * ctx->mem_target - 1; + if (first < ctx->lowest || ctx->lowest == NULL) + ctx->lowest = first; + if (last > ctx->highest) + ctx->highest = last; + ctx->basic_blocks = new; + + return (ISC_TRUE); +} + +static inline isc_boolean_t +more_frags(isc_mem_t *ctx, size_t new_size) { + int i, frags; + size_t total_size; + void *new; + unsigned char *curr, *next; + + /*! + * Try to get more fragments by chopping up a basic block. + */ + + if (ctx->basic_blocks == NULL) { + if (!more_basic_blocks(ctx)) { + /* + * We can't get more memory from the OS, or we've + * hit the quota for this context. + */ + /* + * XXXRTH "At quota" notification here. + */ + return (ISC_FALSE); + } + } + + total_size = ctx->mem_target; + new = ctx->basic_blocks; + ctx->basic_blocks = ctx->basic_blocks->next; + frags = total_size / new_size; + ctx->stats[new_size].blocks++; + ctx->stats[new_size].freefrags += frags; + /* + * Set up a linked-list of blocks of size + * "new_size". + */ + curr = new; + next = curr + new_size; + total_size -= new_size; + for (i = 0; i < (frags - 1); i++) { + ((element *)curr)->next = (element *)next; + curr = next; + next += new_size; + total_size -= new_size; + } + /* + * Add the remaining fragment of the basic block to a free list. + */ + total_size = rmsize(total_size); + if (total_size > 0U) { + ((element *)next)->next = ctx->freelists[total_size]; + ctx->freelists[total_size] = (element *)next; + ctx->stats[total_size].freefrags++; + } + /* + * curr is now pointing at the last block in the + * array. + */ + ((element *)curr)->next = NULL; + ctx->freelists[new_size] = new; + + return (ISC_TRUE); +} + +static inline void * +mem_getunlocked(isc_mem_t *ctx, size_t size) { + size_t new_size = quantize(size); + void *ret; + + if (size >= ctx->max_size || new_size >= ctx->max_size) { + /* + * memget() was called on something beyond our upper limit. + */ + if (ctx->quota != 0U && ctx->total + size > ctx->quota) { + ret = NULL; + goto done; + } + ret = (ctx->memalloc)(ctx->arg, size); + if (ret == NULL) { + ctx->memalloc_failures++; + goto done; + } + ctx->total += size; + ctx->inuse += size; + ctx->stats[ctx->max_size].gets++; + ctx->stats[ctx->max_size].totalgets++; + /* + * If we don't set new_size to size, then the + * ISC_MEM_FILL code might write over bytes we + * don't own. + */ + new_size = size; + goto done; + } + + /* + * If there are no blocks in the free list for this size, get a chunk + * of memory and then break it up into "new_size"-sized blocks, adding + * them to the free list. + */ + if (ctx->freelists[new_size] == NULL && !more_frags(ctx, new_size)) + return (NULL); + + /* + * The free list uses the "rounded-up" size "new_size". + */ + ret = ctx->freelists[new_size]; + ctx->freelists[new_size] = ctx->freelists[new_size]->next; + + /* + * The stats[] uses the _actual_ "size" requested by the + * caller, with the caveat (in the code above) that "size" >= the + * max. size (max_size) ends up getting recorded as a call to + * max_size. + */ + ctx->stats[size].gets++; + ctx->stats[size].totalgets++; + ctx->stats[new_size].freefrags--; + ctx->inuse += new_size; + + done: + +#if ISC_MEM_FILL + if (ret != NULL) + memset(ret, 0xbe, new_size); /* Mnemonic for "beef". */ +#endif + + return (ret); +} + +#if ISC_MEM_FILL && ISC_MEM_CHECKOVERRUN +static inline void +check_overrun(void *mem, size_t size, size_t new_size) { + unsigned char *cp; + + cp = (unsigned char *)mem; + cp += size; + while (size < new_size) { + INSIST(*cp == 0xbe); + cp++; + size++; + } +} +#endif + +static inline void +mem_putunlocked(isc_mem_t *ctx, void *mem, size_t size) { + size_t new_size = quantize(size); + + if (size == ctx->max_size || new_size >= ctx->max_size) { + /* + * memput() called on something beyond our upper limit. + */ +#if ISC_MEM_FILL + memset(mem, 0xde, size); /* Mnemonic for "dead". */ +#endif + (ctx->memfree)(ctx->arg, mem); + INSIST(ctx->stats[ctx->max_size].gets != 0U); + ctx->stats[ctx->max_size].gets--; + INSIST(size <= ctx->total); + ctx->inuse -= size; + ctx->total -= size; + return; + } + +#if ISC_MEM_FILL +#if ISC_MEM_CHECKOVERRUN + check_overrun(mem, size, new_size); +#endif + memset(mem, 0xde, new_size); /* Mnemonic for "dead". */ +#endif + + /* + * The free list uses the "rounded-up" size "new_size". + */ + ((element *)mem)->next = ctx->freelists[new_size]; + ctx->freelists[new_size] = (element *)mem; + + /* + * The stats[] uses the _actual_ "size" requested by the + * caller, with the caveat (in the code above) that "size" >= the + * max. size (max_size) ends up getting recorded as a call to + * max_size. + */ + INSIST(ctx->stats[size].gets != 0U); + ctx->stats[size].gets--; + ctx->stats[new_size].freefrags++; + ctx->inuse -= new_size; +} + +/*! + * Perform a malloc, doing memory filling and overrun detection as necessary. + */ +static inline void * +mem_get(isc_mem_t *ctx, size_t size) { + char *ret; + +#if ISC_MEM_CHECKOVERRUN + size += 1; +#endif + + ret = (ctx->memalloc)(ctx->arg, size); + if (ret == NULL) + ctx->memalloc_failures++; + +#if ISC_MEM_FILL + if (ret != NULL) + memset(ret, 0xbe, size); /* Mnemonic for "beef". */ +#else +# if ISC_MEM_CHECKOVERRUN + if (ret != NULL) + ret[size-1] = 0xbe; +# endif +#endif + + return (ret); +} + +/*! + * Perform a free, doing memory filling and overrun detection as necessary. + */ +static inline void +mem_put(isc_mem_t *ctx, void *mem, size_t size) { +#if ISC_MEM_CHECKOVERRUN + INSIST(((unsigned char *)mem)[size] == 0xbe); +#endif +#if ISC_MEM_FILL + memset(mem, 0xde, size); /* Mnemonic for "dead". */ +#else + UNUSED(size); +#endif + (ctx->memfree)(ctx->arg, mem); +} + +/*! + * Update internal counters after a memory get. + */ +static inline void +mem_getstats(isc_mem_t *ctx, size_t size) { + ctx->total += size; + ctx->inuse += size; + + if (size > ctx->max_size) { + ctx->stats[ctx->max_size].gets++; + ctx->stats[ctx->max_size].totalgets++; + } else { + ctx->stats[size].gets++; + ctx->stats[size].totalgets++; + } +} + +/*! + * Update internal counters after a memory put. + */ +static inline void +mem_putstats(isc_mem_t *ctx, void *ptr, size_t size) { + UNUSED(ptr); + + INSIST(ctx->inuse >= size); + ctx->inuse -= size; + + if (size > ctx->max_size) { + INSIST(ctx->stats[ctx->max_size].gets > 0U); + ctx->stats[ctx->max_size].gets--; + } else { + INSIST(ctx->stats[size].gets > 0U); + ctx->stats[size].gets--; + } +} + +/* + * Private. + */ + +static void * +default_memalloc(void *arg, size_t size) { + UNUSED(arg); + if (size == 0U) + size = 1; + return (malloc(size)); +} + +static void +default_memfree(void *arg, void *ptr) { + UNUSED(arg); + free(ptr); +} + +static void +initialize_action(void) { + RUNTIME_CHECK(isc_mutex_init(&lock) == ISC_R_SUCCESS); + ISC_LIST_INIT(contexts); + totallost = 0; +} + +/* + * Public. + */ + +isc_result_t +isc_mem_createx(size_t init_max_size, size_t target_size, + isc_memalloc_t memalloc, isc_memfree_t memfree, void *arg, + isc_mem_t **ctxp) +{ + return (isc_mem_createx2(init_max_size, target_size, memalloc, memfree, + arg, ctxp, ISC_MEMFLAG_DEFAULT)); + +} + +isc_result_t +isc_mem_createx2(size_t init_max_size, size_t target_size, + isc_memalloc_t memalloc, isc_memfree_t memfree, void *arg, + isc_mem_t **ctxp, unsigned int flags) +{ + isc_mem_t *ctx; + isc_result_t result; + + REQUIRE(ctxp != NULL && *ctxp == NULL); + REQUIRE(memalloc != NULL); + REQUIRE(memfree != NULL); + + INSIST((ALIGNMENT_SIZE & (ALIGNMENT_SIZE - 1)) == 0); + + RUNTIME_CHECK(isc_once_do(&once, initialize_action) == ISC_R_SUCCESS); + + ctx = (memalloc)(arg, sizeof(*ctx)); + if (ctx == NULL) + return (ISC_R_NOMEMORY); + + if ((flags & ISC_MEMFLAG_NOLOCK) == 0) { + result = isc_mutex_init(&ctx->lock); + if (result != ISC_R_SUCCESS) { + (memfree)(arg, ctx); + return (result); + } + } + + if (init_max_size == 0U) + ctx->max_size = DEF_MAX_SIZE; + else + ctx->max_size = init_max_size; + ctx->flags = flags; + ctx->references = 1; + memset(ctx->name, 0, sizeof(ctx->name)); + ctx->tag = NULL; + ctx->quota = 0; + ctx->total = 0; + ctx->inuse = 0; + ctx->maxinuse = 0; + ctx->hi_water = 0; + ctx->lo_water = 0; + ctx->hi_called = ISC_FALSE; + ctx->water = NULL; + ctx->water_arg = NULL; + ctx->magic = MEM_MAGIC; + isc_ondestroy_init(&ctx->ondestroy); + ctx->memalloc = memalloc; + ctx->memfree = memfree; + ctx->arg = arg; + ctx->stats = NULL; + ctx->checkfree = ISC_TRUE; +#if ISC_MEM_TRACKLINES + ctx->debuglist = NULL; + ctx->debuglistcnt = 0; +#endif + ISC_LIST_INIT(ctx->pools); + ctx->poolcnt = 0; + ctx->freelists = NULL; + ctx->basic_blocks = NULL; + ctx->basic_table = NULL; + ctx->basic_table_count = 0; + ctx->basic_table_size = 0; + ctx->lowest = NULL; + ctx->highest = NULL; + + ctx->stats = (memalloc)(arg, + (ctx->max_size+1) * sizeof(struct stats)); + if (ctx->stats == NULL) { + result = ISC_R_NOMEMORY; + goto error; + } + memset(ctx->stats, 0, (ctx->max_size + 1) * sizeof(struct stats)); + + if ((flags & ISC_MEMFLAG_INTERNAL) != 0) { + if (target_size == 0U) + ctx->mem_target = DEF_MEM_TARGET; + else + ctx->mem_target = target_size; + ctx->freelists = (memalloc)(arg, ctx->max_size * + sizeof(element *)); + if (ctx->freelists == NULL) { + result = ISC_R_NOMEMORY; + goto error; + } + memset(ctx->freelists, 0, + ctx->max_size * sizeof(element *)); + } + +#if ISC_MEM_TRACKLINES + if ((isc_mem_debugging & ISC_MEM_DEBUGRECORD) != 0) { + unsigned int i; + + ctx->debuglist = (memalloc)(arg, + (ctx->max_size+1) * sizeof(debuglist_t)); + if (ctx->debuglist == NULL) { + result = ISC_R_NOMEMORY; + goto error; + } + for (i = 0; i <= ctx->max_size; i++) + ISC_LIST_INIT(ctx->debuglist[i]); + } +#endif + + ctx->memalloc_failures = 0; + + LOCK(&lock); + ISC_LIST_INITANDAPPEND(contexts, ctx, link); + UNLOCK(&lock); + + *ctxp = ctx; + return (ISC_R_SUCCESS); + + error: + if (ctx != NULL) { + if (ctx->stats != NULL) + (memfree)(arg, ctx->stats); + if (ctx->freelists != NULL) + (memfree)(arg, ctx->freelists); +#if ISC_MEM_TRACKLINES + if (ctx->debuglist != NULL) + (ctx->memfree)(ctx->arg, ctx->debuglist); +#endif /* ISC_MEM_TRACKLINES */ + if ((ctx->flags & ISC_MEMFLAG_NOLOCK) == 0) + DESTROYLOCK(&ctx->lock); + (memfree)(arg, ctx); + } + + return (result); +} + +isc_result_t +isc_mem_create(size_t init_max_size, size_t target_size, + isc_mem_t **ctxp) +{ + return (isc_mem_createx2(init_max_size, target_size, + default_memalloc, default_memfree, NULL, + ctxp, ISC_MEMFLAG_DEFAULT)); +} + +isc_result_t +isc_mem_create2(size_t init_max_size, size_t target_size, + isc_mem_t **ctxp, unsigned int flags) +{ + return (isc_mem_createx2(init_max_size, target_size, + default_memalloc, default_memfree, NULL, + ctxp, flags)); +} + +static void +destroy(isc_mem_t *ctx) { + unsigned int i; + isc_ondestroy_t ondest; + + ctx->magic = 0; + + LOCK(&lock); + ISC_LIST_UNLINK(contexts, ctx, link); + totallost += ctx->inuse; + UNLOCK(&lock); + + INSIST(ISC_LIST_EMPTY(ctx->pools)); + +#if ISC_MEM_TRACKLINES + if (ctx->debuglist != NULL) { + if (ctx->checkfree) { + for (i = 0; i <= ctx->max_size; i++) { + if (!ISC_LIST_EMPTY(ctx->debuglist[i])) + print_active(ctx, stderr); + INSIST(ISC_LIST_EMPTY(ctx->debuglist[i])); + } + } else { + debuglink_t *dl; + + for (i = 0; i <= ctx->max_size; i++) + for (dl = ISC_LIST_HEAD(ctx->debuglist[i]); + dl != NULL; + dl = ISC_LIST_HEAD(ctx->debuglist[i])) { + ISC_LIST_UNLINK(ctx->debuglist[i], + dl, link); + free(dl); + } + } + (ctx->memfree)(ctx->arg, ctx->debuglist); + } +#endif + INSIST(ctx->references == 0); + + if (ctx->checkfree) { + for (i = 0; i <= ctx->max_size; i++) { +#if ISC_MEM_TRACKLINES + if (ctx->stats[i].gets != 0U) + print_active(ctx, stderr); +#endif + INSIST(ctx->stats[i].gets == 0U); + } + } + + (ctx->memfree)(ctx->arg, ctx->stats); + + if ((ctx->flags & ISC_MEMFLAG_INTERNAL) != 0) { + for (i = 0; i < ctx->basic_table_count; i++) + (ctx->memfree)(ctx->arg, ctx->basic_table[i]); + (ctx->memfree)(ctx->arg, ctx->freelists); + if (ctx->basic_table != NULL) + (ctx->memfree)(ctx->arg, ctx->basic_table); + } + + ondest = ctx->ondestroy; + + if ((ctx->flags & ISC_MEMFLAG_NOLOCK) == 0) + DESTROYLOCK(&ctx->lock); + (ctx->memfree)(ctx->arg, ctx); + + isc_ondestroy_notify(&ondest, ctx); +} + +void +isc_mem_attach(isc_mem_t *source, isc_mem_t **targetp) { + REQUIRE(VALID_CONTEXT(source)); + REQUIRE(targetp != NULL && *targetp == NULL); + + MCTXLOCK(source, &source->lock); + source->references++; + MCTXUNLOCK(source, &source->lock); + + *targetp = source; +} + +void +isc_mem_detach(isc_mem_t **ctxp) { + isc_mem_t *ctx; + isc_boolean_t want_destroy = ISC_FALSE; + + REQUIRE(ctxp != NULL); + ctx = *ctxp; + REQUIRE(VALID_CONTEXT(ctx)); + + MCTXLOCK(ctx, &ctx->lock); + INSIST(ctx->references > 0); + ctx->references--; + if (ctx->references == 0) + want_destroy = ISC_TRUE; + MCTXUNLOCK(ctx, &ctx->lock); + + if (want_destroy) + destroy(ctx); + + *ctxp = NULL; +} + +/* + * isc_mem_putanddetach() is the equivalent of: + * + * mctx = NULL; + * isc_mem_attach(ptr->mctx, &mctx); + * isc_mem_detach(&ptr->mctx); + * isc_mem_put(mctx, ptr, sizeof(*ptr); + * isc_mem_detach(&mctx); + */ + +void +isc__mem_putanddetach(isc_mem_t **ctxp, void *ptr, size_t size FLARG) { + isc_mem_t *ctx; + isc_boolean_t want_destroy = ISC_FALSE; + size_info *si; + size_t oldsize; + + REQUIRE(ctxp != NULL); + ctx = *ctxp; + REQUIRE(VALID_CONTEXT(ctx)); + REQUIRE(ptr != NULL); + + /* + * Must be before mem_putunlocked() as ctxp is usually within + * [ptr..ptr+size). + */ + *ctxp = NULL; + + if ((isc_mem_debugging & (ISC_MEM_DEBUGSIZE|ISC_MEM_DEBUGCTX)) != 0) { + if ((isc_mem_debugging & ISC_MEM_DEBUGSIZE) != 0) { + si = &(((size_info *)ptr)[-1]); + oldsize = si->u.size - ALIGNMENT_SIZE; + if ((isc_mem_debugging & ISC_MEM_DEBUGCTX) != 0) + oldsize -= ALIGNMENT_SIZE; + INSIST(oldsize == size); + } + isc__mem_free(ctx, ptr FLARG_PASS); + + MCTXLOCK(ctx, &ctx->lock); + ctx->references--; + if (ctx->references == 0) + want_destroy = ISC_TRUE; + MCTXUNLOCK(ctx, &ctx->lock); + if (want_destroy) + destroy(ctx); + + return; + } + + if ((ctx->flags & ISC_MEMFLAG_INTERNAL) != 0) { + MCTXLOCK(ctx, &ctx->lock); + mem_putunlocked(ctx, ptr, size); + } else { + mem_put(ctx, ptr, size); + MCTXLOCK(ctx, &ctx->lock); + mem_putstats(ctx, ptr, size); + } + + DELETE_TRACE(ctx, ptr, size, file, line); + INSIST(ctx->references > 0); + ctx->references--; + if (ctx->references == 0) + want_destroy = ISC_TRUE; + + MCTXUNLOCK(ctx, &ctx->lock); + + if (want_destroy) + destroy(ctx); +} + +void +isc_mem_destroy(isc_mem_t **ctxp) { + isc_mem_t *ctx; + + /* + * This routine provides legacy support for callers who use mctxs + * without attaching/detaching. + */ + + REQUIRE(ctxp != NULL); + ctx = *ctxp; + REQUIRE(VALID_CONTEXT(ctx)); + + MCTXLOCK(ctx, &ctx->lock); +#if ISC_MEM_TRACKLINES + if (ctx->references != 1) + print_active(ctx, stderr); +#endif + REQUIRE(ctx->references == 1); + ctx->references--; + MCTXUNLOCK(ctx, &ctx->lock); + + destroy(ctx); + + *ctxp = NULL; +} + +isc_result_t +isc_mem_ondestroy(isc_mem_t *ctx, isc_task_t *task, isc_event_t **event) { + isc_result_t res; + + MCTXLOCK(ctx, &ctx->lock); + res = isc_ondestroy_register(&ctx->ondestroy, task, event); + MCTXUNLOCK(ctx, &ctx->lock); + + return (res); +} + + +void * +isc__mem_get(isc_mem_t *ctx, size_t size FLARG) { + void *ptr; + isc_boolean_t call_water = ISC_FALSE; + + REQUIRE(VALID_CONTEXT(ctx)); + + if ((isc_mem_debugging & (ISC_MEM_DEBUGSIZE|ISC_MEM_DEBUGCTX)) != 0) + return (isc__mem_allocate(ctx, size FLARG_PASS)); + + if ((ctx->flags & ISC_MEMFLAG_INTERNAL) != 0) { + MCTXLOCK(ctx, &ctx->lock); + ptr = mem_getunlocked(ctx, size); + } else { + ptr = mem_get(ctx, size); + MCTXLOCK(ctx, &ctx->lock); + if (ptr != NULL) + mem_getstats(ctx, size); + } + + ADD_TRACE(ctx, ptr, size, file, line); + if (ctx->hi_water != 0U && !ctx->hi_called && + ctx->inuse > ctx->hi_water) { + call_water = ISC_TRUE; + } + if (ctx->inuse > ctx->maxinuse) { + ctx->maxinuse = ctx->inuse; + if (ctx->hi_water != 0U && ctx->inuse > ctx->hi_water && + (isc_mem_debugging & ISC_MEM_DEBUGUSAGE) != 0) + fprintf(stderr, "maxinuse = %lu\n", + (unsigned long)ctx->inuse); + } + MCTXUNLOCK(ctx, &ctx->lock); + + if (call_water) + (ctx->water)(ctx->water_arg, ISC_MEM_HIWATER); + + return (ptr); +} + +void +isc__mem_put(isc_mem_t *ctx, void *ptr, size_t size FLARG) +{ + isc_boolean_t call_water = ISC_FALSE; + size_info *si; + size_t oldsize; + + REQUIRE(VALID_CONTEXT(ctx)); + REQUIRE(ptr != NULL); + + if ((isc_mem_debugging & (ISC_MEM_DEBUGSIZE|ISC_MEM_DEBUGCTX)) != 0) { + if ((isc_mem_debugging & ISC_MEM_DEBUGSIZE) != 0) { + si = &(((size_info *)ptr)[-1]); + oldsize = si->u.size - ALIGNMENT_SIZE; + if ((isc_mem_debugging & ISC_MEM_DEBUGCTX) != 0) + oldsize -= ALIGNMENT_SIZE; + INSIST(oldsize == size); + } + isc__mem_free(ctx, ptr FLARG_PASS); + return; + } + + if ((ctx->flags & ISC_MEMFLAG_INTERNAL) != 0) { + MCTXLOCK(ctx, &ctx->lock); + mem_putunlocked(ctx, ptr, size); + } else { + mem_put(ctx, ptr, size); + MCTXLOCK(ctx, &ctx->lock); + mem_putstats(ctx, ptr, size); + } + + DELETE_TRACE(ctx, ptr, size, file, line); + + /* + * The check against ctx->lo_water == 0 is for the condition + * when the context was pushed over hi_water but then had + * isc_mem_setwater() called with 0 for hi_water and lo_water. + */ + if (ctx->hi_called && + (ctx->inuse < ctx->lo_water || ctx->lo_water == 0U)) { + if (ctx->water != NULL) + call_water = ISC_TRUE; + } + MCTXUNLOCK(ctx, &ctx->lock); + + if (call_water) + (ctx->water)(ctx->water_arg, ISC_MEM_LOWATER); +} + +void +isc_mem_waterack(isc_mem_t *ctx, int flag) { + REQUIRE(VALID_CONTEXT(ctx)); + + MCTXLOCK(ctx, &ctx->lock); + if (flag == ISC_MEM_LOWATER) + ctx->hi_called = ISC_FALSE; + else if (flag == ISC_MEM_HIWATER) + ctx->hi_called = ISC_TRUE; + MCTXUNLOCK(ctx, &ctx->lock); +} + +#if ISC_MEM_TRACKLINES +static void +print_active(isc_mem_t *mctx, FILE *out) { + if (mctx->debuglist != NULL) { + debuglink_t *dl; + unsigned int i, j; + const char *format; + isc_boolean_t found; + + fprintf(out, "%s", isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_DUMPALLOC, + "Dump of all outstanding " + "memory allocations:\n")); + found = ISC_FALSE; + format = isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_PTRFILELINE, + "\tptr %p size %u file %s line %u\n"); + for (i = 0; i <= mctx->max_size; i++) { + dl = ISC_LIST_HEAD(mctx->debuglist[i]); + + if (dl != NULL) + found = ISC_TRUE; + + while (dl != NULL) { + for (j = 0; j < DEBUGLIST_COUNT; j++) + if (dl->ptr[j] != NULL) + fprintf(out, format, + dl->ptr[j], + dl->size[j], + dl->file[j], + dl->line[j]); + dl = ISC_LIST_NEXT(dl, link); + } + } + if (!found) + fprintf(out, "%s", isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_NONE, "\tNone.\n")); + } +} +#endif + +/* + * Print the stats[] on the stream "out" with suitable formatting. + */ +void +isc_mem_stats(isc_mem_t *ctx, FILE *out) { + size_t i; + const struct stats *s; + const isc_mempool_t *pool; + + REQUIRE(VALID_CONTEXT(ctx)); + MCTXLOCK(ctx, &ctx->lock); + + for (i = 0; i <= ctx->max_size; i++) { + s = &ctx->stats[i]; + + if (s->totalgets == 0U && s->gets == 0U) + continue; + fprintf(out, "%s%5lu: %11lu gets, %11lu rem", + (i == ctx->max_size) ? ">=" : " ", + (unsigned long) i, s->totalgets, s->gets); + if ((ctx->flags & ISC_MEMFLAG_INTERNAL) != 0 && + (s->blocks != 0U || s->freefrags != 0U)) + fprintf(out, " (%lu bl, %lu ff)", + s->blocks, s->freefrags); + fputc('\n', out); + } + + /* + * Note that since a pool can be locked now, these stats might be + * somewhat off if the pool is in active use at the time the stats + * are dumped. The link fields are protected by the isc_mem_t's + * lock, however, so walking this list and extracting integers from + * stats fields is always safe. + */ + pool = ISC_LIST_HEAD(ctx->pools); + if (pool != NULL) { + fprintf(out, "%s", isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_POOLSTATS, + "[Pool statistics]\n")); + fprintf(out, "%15s %10s %10s %10s %10s %10s %10s %10s %1s\n", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_POOLNAME, "name"), + isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_POOLSIZE, "size"), + isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_POOLMAXALLOC, "maxalloc"), + isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_POOLALLOCATED, "allocated"), + isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_POOLFREECOUNT, "freecount"), + isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_POOLFREEMAX, "freemax"), + isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_POOLFILLCOUNT, "fillcount"), + isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_POOLGETS, "gets"), + "L"); + } + while (pool != NULL) { + fprintf(out, "%15s %10lu %10u %10u %10u %10u %10u %10u %s\n", + pool->name, (unsigned long) pool->size, pool->maxalloc, + pool->allocated, pool->freecount, pool->freemax, + pool->fillcount, pool->gets, + (pool->lock == NULL ? "N" : "Y")); + pool = ISC_LIST_NEXT(pool, link); + } + +#if ISC_MEM_TRACKLINES + print_active(ctx, out); +#endif + + MCTXUNLOCK(ctx, &ctx->lock); +} + +/* + * Replacements for malloc() and free() -- they implicitly remember the + * size of the object allocated (with some additional overhead). + */ + +static void * +isc__mem_allocateunlocked(isc_mem_t *ctx, size_t size) { + size_info *si; + + size += ALIGNMENT_SIZE; + if ((isc_mem_debugging & ISC_MEM_DEBUGCTX) != 0) + size += ALIGNMENT_SIZE; + + if ((ctx->flags & ISC_MEMFLAG_INTERNAL) != 0) + si = mem_getunlocked(ctx, size); + else + si = mem_get(ctx, size); + + if (si == NULL) + return (NULL); + if ((isc_mem_debugging & ISC_MEM_DEBUGCTX) != 0) { + si->u.ctx = ctx; + si++; + } + si->u.size = size; + return (&si[1]); +} + +void * +isc__mem_allocate(isc_mem_t *ctx, size_t size FLARG) { + size_info *si; + isc_boolean_t call_water = ISC_FALSE; + + REQUIRE(VALID_CONTEXT(ctx)); + + if ((ctx->flags & ISC_MEMFLAG_INTERNAL) != 0) { + MCTXLOCK(ctx, &ctx->lock); + si = isc__mem_allocateunlocked(ctx, size); + } else { + si = isc__mem_allocateunlocked(ctx, size); + MCTXLOCK(ctx, &ctx->lock); + if (si != NULL) + mem_getstats(ctx, si[-1].u.size); + } + +#if ISC_MEM_TRACKLINES + ADD_TRACE(ctx, si, si[-1].u.size, file, line); +#endif + if (ctx->hi_water != 0U && !ctx->hi_called && + ctx->inuse > ctx->hi_water) { + ctx->hi_called = ISC_TRUE; + call_water = ISC_TRUE; + } + if (ctx->inuse > ctx->maxinuse) { + ctx->maxinuse = ctx->inuse; + if (ctx->hi_water != 0U && ctx->inuse > ctx->hi_water && + (isc_mem_debugging & ISC_MEM_DEBUGUSAGE) != 0) + fprintf(stderr, "maxinuse = %lu\n", + (unsigned long)ctx->inuse); + } + MCTXUNLOCK(ctx, &ctx->lock); + + if (call_water) + (ctx->water)(ctx->water_arg, ISC_MEM_HIWATER); + + return (si); +} + +void * +isc__mem_reallocate(isc_mem_t *ctx, void *ptr, size_t size FLARG) { + void *new_ptr = NULL; + size_t oldsize, copysize; + + REQUIRE(VALID_CONTEXT(ctx)); + + /* + * This function emulates the realloc(3) standard library function: + * - if size > 0, allocate new memory; and if ptr is non NULL, copy + * as much of the old contents to the new buffer and free the old one. + * Note that when allocation fails the original pointer is intact; + * the caller must free it. + * - if size is 0 and ptr is non NULL, simply free the given ptr. + * - this function returns: + * pointer to the newly allocated memory, or + * NULL if allocation fails or doesn't happen. + */ + if (size > 0U) { + new_ptr = isc__mem_allocate(ctx, size FLARG_PASS); + if (new_ptr != NULL && ptr != NULL) { + oldsize = (((size_info *)ptr)[-1]).u.size; + INSIST(oldsize >= ALIGNMENT_SIZE); + oldsize -= ALIGNMENT_SIZE; + copysize = oldsize > size ? size : oldsize; + memcpy(new_ptr, ptr, copysize); + isc__mem_free(ctx, ptr FLARG_PASS); + } + } else if (ptr != NULL) + isc__mem_free(ctx, ptr FLARG_PASS); + + return (new_ptr); +} + +void +isc__mem_free(isc_mem_t *ctx, void *ptr FLARG) { + size_info *si; + size_t size; + isc_boolean_t call_water= ISC_FALSE; + + REQUIRE(VALID_CONTEXT(ctx)); + REQUIRE(ptr != NULL); + + if ((isc_mem_debugging & ISC_MEM_DEBUGCTX) != 0) { + si = &(((size_info *)ptr)[-2]); + REQUIRE(si->u.ctx == ctx); + size = si[1].u.size; + } else { + si = &(((size_info *)ptr)[-1]); + size = si->u.size; + } + + if ((ctx->flags & ISC_MEMFLAG_INTERNAL) != 0) { + MCTXLOCK(ctx, &ctx->lock); + mem_putunlocked(ctx, si, size); + } else { + mem_put(ctx, si, size); + MCTXLOCK(ctx, &ctx->lock); + mem_putstats(ctx, si, size); + } + + DELETE_TRACE(ctx, ptr, size, file, line); + + /* + * The check against ctx->lo_water == 0 is for the condition + * when the context was pushed over hi_water but then had + * isc_mem_setwater() called with 0 for hi_water and lo_water. + */ + if (ctx->hi_called && + (ctx->inuse < ctx->lo_water || ctx->lo_water == 0U)) { + ctx->hi_called = ISC_FALSE; + + if (ctx->water != NULL) + call_water = ISC_TRUE; + } + MCTXUNLOCK(ctx, &ctx->lock); + + if (call_water) + (ctx->water)(ctx->water_arg, ISC_MEM_LOWATER); +} + + +/* + * Other useful things. + */ + +char * +isc__mem_strdup(isc_mem_t *mctx, const char *s FLARG) { + size_t len; + char *ns; + + REQUIRE(VALID_CONTEXT(mctx)); + REQUIRE(s != NULL); + + len = strlen(s); + + ns = isc__mem_allocate(mctx, len + 1 FLARG_PASS); + + if (ns != NULL) + strncpy(ns, s, len + 1); + + return (ns); +} + +void +isc_mem_setdestroycheck(isc_mem_t *ctx, isc_boolean_t flag) { + REQUIRE(VALID_CONTEXT(ctx)); + MCTXLOCK(ctx, &ctx->lock); + + ctx->checkfree = flag; + + MCTXUNLOCK(ctx, &ctx->lock); +} + +/* + * Quotas + */ + +void +isc_mem_setquota(isc_mem_t *ctx, size_t quota) { + REQUIRE(VALID_CONTEXT(ctx)); + MCTXLOCK(ctx, &ctx->lock); + + ctx->quota = quota; + + MCTXUNLOCK(ctx, &ctx->lock); +} + +size_t +isc_mem_getquota(isc_mem_t *ctx) { + size_t quota; + + REQUIRE(VALID_CONTEXT(ctx)); + MCTXLOCK(ctx, &ctx->lock); + + quota = ctx->quota; + + MCTXUNLOCK(ctx, &ctx->lock); + + return (quota); +} + +size_t +isc_mem_inuse(isc_mem_t *ctx) { + size_t inuse; + + REQUIRE(VALID_CONTEXT(ctx)); + MCTXLOCK(ctx, &ctx->lock); + + inuse = ctx->inuse; + + MCTXUNLOCK(ctx, &ctx->lock); + + return (inuse); +} + +void +isc_mem_setwater(isc_mem_t *ctx, isc_mem_water_t water, void *water_arg, + size_t hiwater, size_t lowater) +{ + isc_boolean_t callwater = ISC_FALSE; + isc_mem_water_t oldwater; + void *oldwater_arg; + + REQUIRE(VALID_CONTEXT(ctx)); + REQUIRE(hiwater >= lowater); + + MCTXLOCK(ctx, &ctx->lock); + oldwater = ctx->water; + oldwater_arg = ctx->water_arg; + if (water == NULL) { + callwater = ctx->hi_called; + ctx->water = NULL; + ctx->water_arg = NULL; + ctx->hi_water = 0; + ctx->lo_water = 0; + ctx->hi_called = ISC_FALSE; + } else { + if (ctx->hi_called && + (ctx->water != water || ctx->water_arg != water_arg || + ctx->inuse < lowater || lowater == 0U)) + callwater = ISC_TRUE; + ctx->water = water; + ctx->water_arg = water_arg; + ctx->hi_water = hiwater; + ctx->lo_water = lowater; + ctx->hi_called = ISC_FALSE; + } + MCTXUNLOCK(ctx, &ctx->lock); + + if (callwater && oldwater != NULL) + (oldwater)(oldwater_arg, ISC_MEM_LOWATER); +} + +void +isc_mem_setname(isc_mem_t *ctx, const char *name, void *tag) { + REQUIRE(VALID_CONTEXT(ctx)); + + LOCK(&ctx->lock); + memset(ctx->name, 0, sizeof(ctx->name)); + strncpy(ctx->name, name, sizeof(ctx->name) - 1); + ctx->tag = tag; + UNLOCK(&ctx->lock); +} + +const char * +isc_mem_getname(isc_mem_t *ctx) { + REQUIRE(VALID_CONTEXT(ctx)); + + return (ctx->name); +} + +void * +isc_mem_gettag(isc_mem_t *ctx) { + REQUIRE(VALID_CONTEXT(ctx)); + + return (ctx->tag); +} + +/* + * Memory pool stuff + */ + +isc_result_t +isc_mempool_create(isc_mem_t *mctx, size_t size, isc_mempool_t **mpctxp) { + isc_mempool_t *mpctx; + + REQUIRE(VALID_CONTEXT(mctx)); + REQUIRE(size > 0U); + REQUIRE(mpctxp != NULL && *mpctxp == NULL); + + /* + * Allocate space for this pool, initialize values, and if all works + * well, attach to the memory context. + */ + mpctx = isc_mem_get(mctx, sizeof(isc_mempool_t)); + if (mpctx == NULL) + return (ISC_R_NOMEMORY); + + mpctx->magic = MEMPOOL_MAGIC; + mpctx->lock = NULL; + mpctx->mctx = mctx; + mpctx->size = size; + mpctx->maxalloc = UINT_MAX; + mpctx->allocated = 0; + mpctx->freecount = 0; + mpctx->freemax = 1; + mpctx->fillcount = 1; + mpctx->gets = 0; +#if ISC_MEMPOOL_NAMES + mpctx->name[0] = 0; +#endif + mpctx->items = NULL; + + *mpctxp = mpctx; + + MCTXLOCK(mctx, &mctx->lock); + ISC_LIST_INITANDAPPEND(mctx->pools, mpctx, link); + mctx->poolcnt++; + MCTXUNLOCK(mctx, &mctx->lock); + + return (ISC_R_SUCCESS); +} + +void +isc_mempool_setname(isc_mempool_t *mpctx, const char *name) { + REQUIRE(name != NULL); + +#if ISC_MEMPOOL_NAMES + if (mpctx->lock != NULL) + LOCK(mpctx->lock); + + strncpy(mpctx->name, name, sizeof(mpctx->name) - 1); + mpctx->name[sizeof(mpctx->name) - 1] = '\0'; + + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); +#else + UNUSED(mpctx); + UNUSED(name); +#endif +} + +void +isc_mempool_destroy(isc_mempool_t **mpctxp) { + isc_mempool_t *mpctx; + isc_mem_t *mctx; + isc_mutex_t *lock; + element *item; + + REQUIRE(mpctxp != NULL); + mpctx = *mpctxp; + REQUIRE(VALID_MEMPOOL(mpctx)); +#if ISC_MEMPOOL_NAMES + if (mpctx->allocated > 0) + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_mempool_destroy(): mempool %s " + "leaked memory", + mpctx->name); +#endif + REQUIRE(mpctx->allocated == 0); + + mctx = mpctx->mctx; + + lock = mpctx->lock; + + if (lock != NULL) + LOCK(lock); + + /* + * Return any items on the free list + */ + MCTXLOCK(mctx, &mctx->lock); + while (mpctx->items != NULL) { + INSIST(mpctx->freecount > 0); + mpctx->freecount--; + item = mpctx->items; + mpctx->items = item->next; + + if ((mctx->flags & ISC_MEMFLAG_INTERNAL) != 0) { + mem_putunlocked(mctx, item, mpctx->size); + } else { + mem_put(mctx, item, mpctx->size); + mem_putstats(mctx, item, mpctx->size); + } + } + MCTXUNLOCK(mctx, &mctx->lock); + + /* + * Remove our linked list entry from the memory context. + */ + MCTXLOCK(mctx, &mctx->lock); + ISC_LIST_UNLINK(mctx->pools, mpctx, link); + mctx->poolcnt--; + MCTXUNLOCK(mctx, &mctx->lock); + + mpctx->magic = 0; + + isc_mem_put(mpctx->mctx, mpctx, sizeof(isc_mempool_t)); + + if (lock != NULL) + UNLOCK(lock); + + *mpctxp = NULL; +} + +void +isc_mempool_associatelock(isc_mempool_t *mpctx, isc_mutex_t *lock) { + REQUIRE(VALID_MEMPOOL(mpctx)); + REQUIRE(mpctx->lock == NULL); + REQUIRE(lock != NULL); + + mpctx->lock = lock; +} + +void * +isc__mempool_get(isc_mempool_t *mpctx FLARG) { + element *item; + isc_mem_t *mctx; + unsigned int i; + + REQUIRE(VALID_MEMPOOL(mpctx)); + + mctx = mpctx->mctx; + + if (mpctx->lock != NULL) + LOCK(mpctx->lock); + + /* + * Don't let the caller go over quota + */ + if (mpctx->allocated >= mpctx->maxalloc) { + item = NULL; + goto out; + } + + /* + * if we have a free list item, return the first here + */ + item = mpctx->items; + if (item != NULL) { + mpctx->items = item->next; + INSIST(mpctx->freecount > 0); + mpctx->freecount--; + mpctx->gets++; + mpctx->allocated++; + goto out; + } + + /* + * We need to dip into the well. Lock the memory context here and + * fill up our free list. + */ + MCTXLOCK(mctx, &mctx->lock); + for (i = 0; i < mpctx->fillcount; i++) { + if ((mctx->flags & ISC_MEMFLAG_INTERNAL) != 0) { + item = mem_getunlocked(mctx, mpctx->size); + } else { + item = mem_get(mctx, mpctx->size); + if (item != NULL) + mem_getstats(mctx, mpctx->size); + } + if (item == NULL) + break; + item->next = mpctx->items; + mpctx->items = item; + mpctx->freecount++; + } + MCTXUNLOCK(mctx, &mctx->lock); + + /* + * If we didn't get any items, return NULL. + */ + item = mpctx->items; + if (item == NULL) + goto out; + + mpctx->items = item->next; + mpctx->freecount--; + mpctx->gets++; + mpctx->allocated++; + + out: + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); + +#if ISC_MEM_TRACKLINES + if (item != NULL) { + MCTXLOCK(mctx, &mctx->lock); + ADD_TRACE(mctx, item, mpctx->size, file, line); + MCTXUNLOCK(mctx, &mctx->lock); + } +#endif /* ISC_MEM_TRACKLINES */ + + return (item); +} + +void +isc__mempool_put(isc_mempool_t *mpctx, void *mem FLARG) { + isc_mem_t *mctx; + element *item; + + REQUIRE(VALID_MEMPOOL(mpctx)); + REQUIRE(mem != NULL); + + mctx = mpctx->mctx; + + if (mpctx->lock != NULL) + LOCK(mpctx->lock); + + INSIST(mpctx->allocated > 0); + mpctx->allocated--; + +#if ISC_MEM_TRACKLINES + MCTXLOCK(mctx, &mctx->lock); + DELETE_TRACE(mctx, mem, mpctx->size, file, line); + MCTXUNLOCK(mctx, &mctx->lock); +#endif /* ISC_MEM_TRACKLINES */ + + /* + * If our free list is full, return this to the mctx directly. + */ + if (mpctx->freecount >= mpctx->freemax) { + if ((mctx->flags & ISC_MEMFLAG_INTERNAL) != 0) { + MCTXLOCK(mctx, &mctx->lock); + mem_putunlocked(mctx, mem, mpctx->size); + MCTXUNLOCK(mctx, &mctx->lock); + } else { + mem_put(mctx, mem, mpctx->size); + MCTXLOCK(mctx, &mctx->lock); + mem_putstats(mctx, mem, mpctx->size); + MCTXUNLOCK(mctx, &mctx->lock); + } + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); + return; + } + + /* + * Otherwise, attach it to our free list and bump the counter. + */ + mpctx->freecount++; + item = (element *)mem; + item->next = mpctx->items; + mpctx->items = item; + + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); +} + +/* + * Quotas + */ + +void +isc_mempool_setfreemax(isc_mempool_t *mpctx, unsigned int limit) { + REQUIRE(VALID_MEMPOOL(mpctx)); + + if (mpctx->lock != NULL) + LOCK(mpctx->lock); + + mpctx->freemax = limit; + + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); +} + +unsigned int +isc_mempool_getfreemax(isc_mempool_t *mpctx) { + unsigned int freemax; + + REQUIRE(VALID_MEMPOOL(mpctx)); + + if (mpctx->lock != NULL) + LOCK(mpctx->lock); + + freemax = mpctx->freemax; + + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); + + return (freemax); +} + +unsigned int +isc_mempool_getfreecount(isc_mempool_t *mpctx) { + unsigned int freecount; + + REQUIRE(VALID_MEMPOOL(mpctx)); + + if (mpctx->lock != NULL) + LOCK(mpctx->lock); + + freecount = mpctx->freecount; + + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); + + return (freecount); +} + +void +isc_mempool_setmaxalloc(isc_mempool_t *mpctx, unsigned int limit) { + REQUIRE(limit > 0); + + REQUIRE(VALID_MEMPOOL(mpctx)); + + if (mpctx->lock != NULL) + LOCK(mpctx->lock); + + mpctx->maxalloc = limit; + + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); +} + +unsigned int +isc_mempool_getmaxalloc(isc_mempool_t *mpctx) { + unsigned int maxalloc; + + REQUIRE(VALID_MEMPOOL(mpctx)); + + if (mpctx->lock != NULL) + LOCK(mpctx->lock); + + maxalloc = mpctx->maxalloc; + + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); + + return (maxalloc); +} + +unsigned int +isc_mempool_getallocated(isc_mempool_t *mpctx) { + unsigned int allocated; + + REQUIRE(VALID_MEMPOOL(mpctx)); + + if (mpctx->lock != NULL) + LOCK(mpctx->lock); + + allocated = mpctx->allocated; + + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); + + return (allocated); +} + +void +isc_mempool_setfillcount(isc_mempool_t *mpctx, unsigned int limit) { + REQUIRE(limit > 0); + REQUIRE(VALID_MEMPOOL(mpctx)); + + if (mpctx->lock != NULL) + LOCK(mpctx->lock); + + mpctx->fillcount = limit; + + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); +} + +unsigned int +isc_mempool_getfillcount(isc_mempool_t *mpctx) { + unsigned int fillcount; + + REQUIRE(VALID_MEMPOOL(mpctx)); + + if (mpctx->lock != NULL) + LOCK(mpctx->lock); + + fillcount = mpctx->fillcount; + + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); + + return (fillcount); +} + +void +isc_mem_printactive(isc_mem_t *ctx, FILE *file) { + + REQUIRE(VALID_CONTEXT(ctx)); + REQUIRE(file != NULL); + +#if !ISC_MEM_TRACKLINES + UNUSED(ctx); + UNUSED(file); +#else + print_active(ctx, file); +#endif +} + +void +isc_mem_printallactive(FILE *file) { +#if !ISC_MEM_TRACKLINES + UNUSED(file); +#else + isc_mem_t *ctx; + + RUNTIME_CHECK(isc_once_do(&once, initialize_action) == ISC_R_SUCCESS); + + LOCK(&lock); + for (ctx = ISC_LIST_HEAD(contexts); + ctx != NULL; + ctx = ISC_LIST_NEXT(ctx, link)) { + fprintf(file, "context: %p\n", ctx); + print_active(ctx, file); + } + UNLOCK(&lock); +#endif +} + +void +isc_mem_checkdestroyed(FILE *file) { + + RUNTIME_CHECK(isc_once_do(&once, initialize_action) == ISC_R_SUCCESS); + + LOCK(&lock); + if (!ISC_LIST_EMPTY(contexts)) { +#if ISC_MEM_TRACKLINES + isc_mem_t *ctx; + + for (ctx = ISC_LIST_HEAD(contexts); + ctx != NULL; + ctx = ISC_LIST_NEXT(ctx, link)) { + fprintf(file, "context: %p\n", ctx); + print_active(ctx, file); + } + fflush(file); +#endif + INSIST(0); + } + UNLOCK(&lock); +} + +unsigned int +isc_mem_references(isc_mem_t *ctx) { + unsigned int references; + REQUIRE(VALID_CONTEXT(ctx)); + + MCTXLOCK(ctx, &ctx->lock); + references = ctx->references; + MCTXUNLOCK(ctx, &ctx->lock); + + return (references); +} + +#ifdef HAVE_LIBXML2 + +typedef struct summarystat { + isc_uint64_t total; + isc_uint64_t inuse; + isc_uint64_t blocksize; + isc_uint64_t contextsize; +} summarystat_t; + +static void +renderctx(isc_mem_t *ctx, summarystat_t *summary, xmlTextWriterPtr writer) { + REQUIRE(VALID_CONTEXT(ctx)); + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "context"); + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "id"); + xmlTextWriterWriteFormatString(writer, "%p", ctx); + xmlTextWriterEndElement(writer); /* id */ + + if (ctx->name[0] != 0) { + xmlTextWriterStartElement(writer, ISC_XMLCHAR "name"); + xmlTextWriterWriteFormatString(writer, "%s", ctx->name); + xmlTextWriterEndElement(writer); /* name */ + } + + REQUIRE(VALID_CONTEXT(ctx)); + MCTXLOCK(ctx, &ctx->lock); + + summary->contextsize += sizeof(*ctx) + + (ctx->max_size + 1) * sizeof(struct stats) + + ctx->max_size * sizeof(element *) + + ctx->basic_table_count * sizeof(char *); +#if ISC_MEM_TRACKLINES + if (ctx->debuglist != NULL) { + summary->contextsize += + (ctx->max_size + 1) * sizeof(debuglist_t) + + ctx->debuglistcnt * sizeof(debuglink_t); + } +#endif + xmlTextWriterStartElement(writer, ISC_XMLCHAR "references"); + xmlTextWriterWriteFormatString(writer, "%d", ctx->references); + xmlTextWriterEndElement(writer); /* references */ + + summary->total += ctx->total; + xmlTextWriterStartElement(writer, ISC_XMLCHAR "total"); + xmlTextWriterWriteFormatString(writer, "%" ISC_PRINT_QUADFORMAT "u", + (isc_uint64_t)ctx->total); + xmlTextWriterEndElement(writer); /* total */ + + summary->inuse += ctx->inuse; + xmlTextWriterStartElement(writer, ISC_XMLCHAR "inuse"); + xmlTextWriterWriteFormatString(writer, "%" ISC_PRINT_QUADFORMAT "u", + (isc_uint64_t)ctx->inuse); + xmlTextWriterEndElement(writer); /* inuse */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "maxinuse"); + xmlTextWriterWriteFormatString(writer, "%" ISC_PRINT_QUADFORMAT "u", + (isc_uint64_t)ctx->maxinuse); + xmlTextWriterEndElement(writer); /* maxinuse */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "blocksize"); + if ((ctx->flags & ISC_MEMFLAG_INTERNAL) != 0) { + summary->blocksize += ctx->basic_table_count * + NUM_BASIC_BLOCKS * ctx->mem_target; + xmlTextWriterWriteFormatString(writer, + "%" ISC_PRINT_QUADFORMAT "u", + (isc_uint64_t) + ctx->basic_table_count * + NUM_BASIC_BLOCKS * + ctx->mem_target); + } else + xmlTextWriterWriteFormatString(writer, "%s", "-"); + xmlTextWriterEndElement(writer); /* blocksize */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "pools"); + xmlTextWriterWriteFormatString(writer, "%u", ctx->poolcnt); + xmlTextWriterEndElement(writer); /* pools */ + summary->contextsize += ctx->poolcnt * sizeof(isc_mempool_t); + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "hiwater"); + xmlTextWriterWriteFormatString(writer, "%" ISC_PRINT_QUADFORMAT "u", + (isc_uint64_t)ctx->hi_water); + xmlTextWriterEndElement(writer); /* hiwater */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "lowater"); + xmlTextWriterWriteFormatString(writer, "%" ISC_PRINT_QUADFORMAT "u", + (isc_uint64_t)ctx->lo_water); + xmlTextWriterEndElement(writer); /* lowater */ + + MCTXUNLOCK(ctx, &ctx->lock); + + xmlTextWriterEndElement(writer); /* context */ +} + +void +isc_mem_renderxml(xmlTextWriterPtr writer) { + isc_mem_t *ctx; + summarystat_t summary; + isc_uint64_t lost; + + memset(&summary, 0, sizeof(summary)); + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "contexts"); + + RUNTIME_CHECK(isc_once_do(&once, initialize_action) == ISC_R_SUCCESS); + + LOCK(&lock); + lost = totallost; + for (ctx = ISC_LIST_HEAD(contexts); + ctx != NULL; + ctx = ISC_LIST_NEXT(ctx, link)) { + renderctx(ctx, &summary, writer); + } + UNLOCK(&lock); + + xmlTextWriterEndElement(writer); /* contexts */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "summary"); + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "TotalUse"); + xmlTextWriterWriteFormatString(writer, "%" ISC_PRINT_QUADFORMAT "u", + summary.total); + xmlTextWriterEndElement(writer); /* TotalUse */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "InUse"); + xmlTextWriterWriteFormatString(writer, "%" ISC_PRINT_QUADFORMAT "u", + summary.inuse); + xmlTextWriterEndElement(writer); /* InUse */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "BlockSize"); + xmlTextWriterWriteFormatString(writer, "%" ISC_PRINT_QUADFORMAT "u", + summary.blocksize); + xmlTextWriterEndElement(writer); /* BlockSize */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "ContextSize"); + xmlTextWriterWriteFormatString(writer, "%" ISC_PRINT_QUADFORMAT "u", + summary.contextsize); + xmlTextWriterEndElement(writer); /* ContextSize */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "Lost"); + xmlTextWriterWriteFormatString(writer, "%" ISC_PRINT_QUADFORMAT "u", + lost); + xmlTextWriterEndElement(writer); /* Lost */ + + xmlTextWriterEndElement(writer); /* summary */ +} + +#endif /* HAVE_LIBXML2 */ diff -urN src/contrib/ntp/lib/isc/mips/include/isc/atomic.h src.ntp/contrib/ntp/lib/isc/mips/include/isc/atomic.h --- src/contrib/ntp/lib/isc/mips/include/isc/atomic.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/mips/include/isc/atomic.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,98 @@ +/* + * Copyright (C) 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: atomic.h,v 1.3 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_ATOMIC_H +#define ISC_ATOMIC_H 1 + +#include +#include + +#ifdef ISC_PLATFORM_USEGCCASM +/* + * This routine atomically increments the value stored in 'p' by 'val', and + * returns the previous value. + */ +static inline isc_int32_t +isc_atomic_xadd(isc_int32_t *p, int val) { + isc_int32_t orig; + + /* add is a cheat, since MIPS has no mov instruction */ + __asm__ volatile ( + "1:" + "ll $3, %1\n" + "add %0, $0, $3\n" + "add $3, $3, %2\n" + "sc $3, %1\n" + "beq $3, 0, 1b" + : "=&r"(orig) + : "m"(*p), "r"(val) + : "memory", "$3" + ); + + return (orig); +} + +/* + * This routine atomically stores the value 'val' in 'p'. + */ +static inline void +isc_atomic_store(isc_int32_t *p, isc_int32_t val) { + __asm__ volatile ( + "1:" + "ll $3, %0\n" + "add $3, $0, %1\n" + "sc $3, %0\n" + "beq $3, 0, 1b" + : + : "m"(*p), "r"(val) + : "memory", "$3" + ); +} + +/* + * This routine atomically replaces the value in 'p' with 'val', if the + * original value is equal to 'cmpval'. The original value is returned in any + * case. + */ +static inline isc_int32_t +isc_atomic_cmpxchg(isc_int32_t *p, int cmpval, int val) { + isc_int32_t orig; + + __asm__ volatile( + "1:" + "ll $3, %1\n" + "add %0, $0, $3\n" + "bne $3, %2, 2f\n" + "add $3, $0, %3\n" + "sc $3, %1\n" + "beq $3, 0, 1b\n" + "2:" + : "=&r"(orig) + : "m"(*p), "r"(cmpval), "r"(val) + : "memory", "$3" + ); + + return (orig); +} + +#else /* !ISC_PLATFORM_USEGCCASM */ + +#error "unsupported compiler. disable atomic ops by --disable-atomic" + +#endif +#endif /* ISC_ATOMIC_H */ diff -urN src/contrib/ntp/lib/isc/mutexblock.c src.ntp/contrib/ntp/lib/isc/mutexblock.c --- src/contrib/ntp/lib/isc/mutexblock.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/mutexblock.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,59 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: mutexblock.c,v 1.20 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include + +isc_result_t +isc_mutexblock_init(isc_mutex_t *block, unsigned int count) { + isc_result_t result; + unsigned int i; + + for (i = 0; i < count; i++) { + result = isc_mutex_init(&block[i]); + if (result != ISC_R_SUCCESS) { + i--; + while (i > 0) { + DESTROYLOCK(&block[i]); + i--; + } + return (result); + } + } + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_mutexblock_destroy(isc_mutex_t *block, unsigned int count) { + isc_result_t result; + unsigned int i; + + for (i = 0; i < count; i++) { + result = isc_mutex_destroy(&block[i]); + if (result != ISC_R_SUCCESS) + return (result); + } + + return (ISC_R_SUCCESS); +} diff -urN src/contrib/ntp/lib/isc/netaddr.c src.ntp/contrib/ntp/lib/isc/netaddr.c --- src/contrib/ntp/lib/isc/netaddr.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/netaddr.c 2010-01-24 11:01:47.000000000 +0100 @@ -0,0 +1,436 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: netaddr.c,v 1.38 2007/06/18 23:47:44 tbox Exp $ */ + +/*! \file */ + +#include + +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +isc_boolean_t +isc_netaddr_equal(const isc_netaddr_t *a, const isc_netaddr_t *b) { + REQUIRE(a != NULL && b != NULL); + + if (a->family != b->family) + return (ISC_FALSE); + + if (a->zone != b->zone) + return (ISC_FALSE); + + switch (a->family) { + case AF_INET: + if (a->type.in.s_addr != b->type.in.s_addr) + return (ISC_FALSE); + break; + case AF_INET6: + if (memcmp(&a->type.in6, &b->type.in6, + sizeof(a->type.in6)) != 0 || + a->zone != b->zone) + return (ISC_FALSE); + break; +#ifdef ISC_PLATFORM_HAVESYSUNH + case AF_UNIX: + if (strcmp(a->type.un, b->type.un) != 0) + return (ISC_FALSE); + break; +#endif + default: + return (ISC_FALSE); + } + return (ISC_TRUE); +} + +isc_boolean_t +isc_netaddr_eqprefix(const isc_netaddr_t *a, const isc_netaddr_t *b, + unsigned int prefixlen) +{ + const unsigned char *pa, *pb; + unsigned int ipabytes; /* Length of whole IP address in bytes */ + unsigned int nbytes; /* Number of significant whole bytes */ + unsigned int nbits; /* Number of significant leftover bits */ + + REQUIRE(a != NULL && b != NULL); + + if (a->family != b->family) + return (ISC_FALSE); + + if (a->zone != b->zone && b->zone != 0) + return (ISC_FALSE); + + switch (a->family) { + case AF_INET: + pa = (const unsigned char *) &a->type.in; + pb = (const unsigned char *) &b->type.in; + ipabytes = 4; + break; + case AF_INET6: + pa = (const unsigned char *) &a->type.in6; + pb = (const unsigned char *) &b->type.in6; + ipabytes = 16; + break; + default: + pa = pb = NULL; /* Avoid silly compiler warning. */ + ipabytes = 0; /* Ditto. */ + return (ISC_FALSE); + } + + /* + * Don't crash if we get a pattern like 10.0.0.1/9999999. + */ + if (prefixlen > ipabytes * 8) + prefixlen = ipabytes * 8; + + nbytes = prefixlen / 8; + nbits = prefixlen % 8; + + if (nbytes > 0) { + if (memcmp(pa, pb, nbytes) != 0) + return (ISC_FALSE); + } + if (nbits > 0) { + unsigned int bytea, byteb, mask; + INSIST(nbytes < ipabytes); + INSIST(nbits < 8); + bytea = pa[nbytes]; + byteb = pb[nbytes]; + mask = (0xFF << (8-nbits)) & 0xFF; + if ((bytea & mask) != (byteb & mask)) + return (ISC_FALSE); + } + return (ISC_TRUE); +} + +isc_result_t +isc_netaddr_totext(const isc_netaddr_t *netaddr, isc_buffer_t *target) { + char abuf[sizeof("xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:255.255.255.255")]; + char zbuf[sizeof("%4294967295")]; + unsigned int alen; + int zlen; + const char *r; + const void *type; + + REQUIRE(netaddr != NULL); + + switch (netaddr->family) { + case AF_INET: + type = &netaddr->type.in; + break; + case AF_INET6: + type = &netaddr->type.in6; + break; +#ifdef ISC_PLATFORM_HAVESYSUNH + case AF_UNIX: + alen = strlen(netaddr->type.un); + if (alen > isc_buffer_availablelength(target)) + return (ISC_R_NOSPACE); + isc_buffer_putmem(target, + (const unsigned char *)(netaddr->type.un), + alen); + return (ISC_R_SUCCESS); +#endif + default: + return (ISC_R_FAILURE); + } + r = inet_ntop(netaddr->family, type, abuf, sizeof(abuf)); + if (r == NULL) + return (ISC_R_FAILURE); + + alen = strlen(abuf); + INSIST(alen < sizeof(abuf)); + + zlen = 0; + if (netaddr->family == AF_INET6 && netaddr->zone != 0) { + zlen = snprintf(zbuf, sizeof(zbuf), "%%%u", netaddr->zone); + if (zlen < 0) + return (ISC_R_FAILURE); + INSIST((unsigned int)zlen < sizeof(zbuf)); + } + + if (alen + zlen > isc_buffer_availablelength(target)) + return (ISC_R_NOSPACE); + + isc_buffer_putmem(target, (unsigned char *)abuf, alen); + isc_buffer_putmem(target, (unsigned char *)zbuf, zlen); + + return (ISC_R_SUCCESS); +} + +void +isc_netaddr_format(const isc_netaddr_t *na, char *array, unsigned int size) { + isc_result_t result; + isc_buffer_t buf; + + isc_buffer_init(&buf, array, size); + result = isc_netaddr_totext(na, &buf); + + /* + * Null terminate. + */ + if (result == ISC_R_SUCCESS) { + if (isc_buffer_availablelength(&buf) >= 1) + isc_buffer_putuint8(&buf, 0); + else + result = ISC_R_NOSPACE; + } + + if (result != ISC_R_SUCCESS) { + snprintf(array, size, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_NETADDR, + ISC_MSG_UNKNOWNADDR, + ""), + na->family); + array[size - 1] = '\0'; + } +} + + +isc_result_t +isc_netaddr_prefixok(const isc_netaddr_t *na, unsigned int prefixlen) { + static const unsigned char zeros[16]; + unsigned int nbits, nbytes, ipbytes; + const unsigned char *p; + + switch (na->family) { + case AF_INET: + p = (const unsigned char *) &na->type.in; + ipbytes = 4; + if (prefixlen > 32) + return (ISC_R_RANGE); + break; + case AF_INET6: + p = (const unsigned char *) &na->type.in6; + ipbytes = 16; + if (prefixlen > 128) + return (ISC_R_RANGE); + break; + default: + ipbytes = 0; + return (ISC_R_NOTIMPLEMENTED); + } + nbytes = prefixlen / 8; + nbits = prefixlen % 8; + if (nbits != 0) { + if ((p[nbytes] & (0xff>>nbits)) != 0U) + return (ISC_R_FAILURE); + nbytes++; + } + if (memcmp(p + nbytes, zeros, ipbytes - nbytes) != 0) + return (ISC_R_FAILURE); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_netaddr_masktoprefixlen(const isc_netaddr_t *s, unsigned int *lenp) { + unsigned int nbits, nbytes, ipbytes, i; + const unsigned char *p; + + switch (s->family) { + case AF_INET: + p = (const unsigned char *) &s->type.in; + ipbytes = 4; + break; + case AF_INET6: + p = (const unsigned char *) &s->type.in6; + ipbytes = 16; + break; + default: + ipbytes = 0; + return (ISC_R_NOTIMPLEMENTED); + } + nbytes = nbits = 0; + for (i = 0; i < ipbytes; i++) { + if (p[i] != 0xFF) + break; + } + nbytes = i; + if (i < ipbytes) { + unsigned int c = p[nbytes]; + while ((c & 0x80) != 0 && nbits < 8) { + c <<= 1; nbits++; + } + if ((c & 0xFF) != 0) + return (ISC_R_MASKNONCONTIG); + i++; + } + for (; i < ipbytes; i++) { + if (p[i] != 0) + return (ISC_R_MASKNONCONTIG); + i++; + } + *lenp = nbytes * 8 + nbits; + return (ISC_R_SUCCESS); +} + +void +isc_netaddr_fromin(isc_netaddr_t *netaddr, const struct in_addr *ina) { + memset(netaddr, 0, sizeof(*netaddr)); + netaddr->family = AF_INET; + netaddr->type.in = *ina; +} + +void +isc_netaddr_fromin6(isc_netaddr_t *netaddr, const struct in6_addr *ina6) { + memset(netaddr, 0, sizeof(*netaddr)); + netaddr->family = AF_INET6; + netaddr->type.in6 = *ina6; +} + +isc_result_t +isc_netaddr_frompath(isc_netaddr_t *netaddr, const char *path) { +#ifdef ISC_PLATFORM_HAVESYSUNH + if (strlen(path) > sizeof(netaddr->type.un) - 1) + return (ISC_R_NOSPACE); + + memset(netaddr, 0, sizeof(*netaddr)); + netaddr->family = AF_UNIX; + strcpy(netaddr->type.un, path); + netaddr->zone = 0; + return (ISC_R_SUCCESS); +#else + UNUSED(netaddr); + UNUSED(path); + return (ISC_R_NOTIMPLEMENTED); +#endif +} + + +void +isc_netaddr_setzone(isc_netaddr_t *netaddr, isc_uint32_t zone) { + /* we currently only support AF_INET6. */ + REQUIRE(netaddr->family == AF_INET6); + + netaddr->zone = zone; +} + +isc_uint32_t +isc_netaddr_getzone(const isc_netaddr_t *netaddr) { + return (netaddr->zone); +} + +void +isc_netaddr_fromsockaddr(isc_netaddr_t *t, const isc_sockaddr_t *s) { + int family = s->type.sa.sa_family; + t->family = family; + switch (family) { + case AF_INET: + t->type.in = s->type.sin.sin_addr; + t->zone = 0; + break; + case AF_INET6: + memcpy(&t->type.in6, &s->type.sin6.sin6_addr, 16); +#ifdef ISC_PLATFORM_HAVESCOPEID + t->zone = s->type.sin6.sin6_scope_id; +#else + t->zone = 0; +#endif + break; +#ifdef ISC_PLATFORM_HAVESYSUNH + case AF_UNIX: + memcpy(t->type.un, s->type.sunix.sun_path, sizeof(t->type.un)); + t->zone = 0; + break; +#endif + default: + INSIST(0); + } +} + +void +isc_netaddr_any(isc_netaddr_t *netaddr) { + memset(netaddr, 0, sizeof(*netaddr)); + netaddr->family = AF_INET; + netaddr->type.in.s_addr = INADDR_ANY; +} + +void +isc_netaddr_any6(isc_netaddr_t *netaddr) { + memset(netaddr, 0, sizeof(*netaddr)); + netaddr->family = AF_INET6; + netaddr->type.in6 = in6addr_any; +} + +isc_boolean_t +isc_netaddr_ismulticast(isc_netaddr_t *na) { + switch (na->family) { + case AF_INET: + return (ISC_TF(ISC_IPADDR_ISMULTICAST(na->type.in.s_addr))); + case AF_INET6: + return (ISC_TF(IN6_IS_ADDR_MULTICAST(&na->type.in6))); + default: + return (ISC_FALSE); /* XXXMLG ? */ + } +} + +isc_boolean_t +isc_netaddr_isexperimental(isc_netaddr_t *na) { + switch (na->family) { + case AF_INET: + return (ISC_TF(ISC_IPADDR_ISEXPERIMENTAL(na->type.in.s_addr))); + default: + return (ISC_FALSE); /* XXXMLG ? */ + } +} + +isc_boolean_t +isc_netaddr_islinklocal(isc_netaddr_t *na) { + switch (na->family) { + case AF_INET: + return (ISC_FALSE); + case AF_INET6: + return (ISC_TF(IN6_IS_ADDR_LINKLOCAL(&na->type.in6))); + default: + return (ISC_FALSE); + } +} + +isc_boolean_t +isc_netaddr_issitelocal(isc_netaddr_t *na) { + switch (na->family) { + case AF_INET: + return (ISC_FALSE); + case AF_INET6: + return (ISC_TF(IN6_IS_ADDR_SITELOCAL(&na->type.in6))); + default: + return (ISC_FALSE); + } +} + +void +isc_netaddr_fromv4mapped(isc_netaddr_t *t, const isc_netaddr_t *s) { + isc_netaddr_t *src; + + DE_CONST(s, src); /* Must come before IN6_IS_ADDR_V4MAPPED. */ + + REQUIRE(s->family == AF_INET6); + REQUIRE(IN6_IS_ADDR_V4MAPPED(&src->type.in6)); + + memset(t, 0, sizeof(*t)); + t->family = AF_INET; + memcpy(&t->type.in, (char *)&src->type.in6 + 12, 4); + return; +} diff -urN src/contrib/ntp/lib/isc/netscope.c src.ntp/contrib/ntp/lib/isc/netscope.c --- src/contrib/ntp/lib/isc/netscope.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/netscope.c 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,76 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/*! \file */ + +#if defined(LIBC_SCCS) && !defined(lint) +static char rcsid[] = + "$Id: netscope.c,v 1.13 2007/06/19 23:47:17 tbox Exp $"; +#endif /* LIBC_SCCS and not lint */ + +#include + +#include +#include +#include +#include + +isc_result_t +isc_netscope_pton(int af, char *scopename, void *addr, isc_uint32_t *zoneid) { + char *ep; +#ifdef ISC_PLATFORM_HAVEIFNAMETOINDEX + unsigned int ifid; +#endif + struct in6_addr *in6; + isc_uint32_t zone; + isc_uint64_t llz; + + /* at this moment, we only support AF_INET6 */ + if (af != AF_INET6) + return (ISC_R_FAILURE); + + in6 = (struct in6_addr *)addr; + + /* + * Basically, "names" are more stable than numeric IDs in terms of + * renumbering, and are more preferred. However, since there is no + * standard naming convention and APIs to deal with the names. Thus, + * we only handle the case of link-local addresses, for which we use + * interface names as link names, assuming one to one mapping between + * interfaces and links. + */ +#ifdef ISC_PLATFORM_HAVEIFNAMETOINDEX + if (IN6_IS_ADDR_LINKLOCAL(in6) && + (ifid = if_nametoindex((const char *)scopename)) != 0) + zone = (isc_uint32_t)ifid; + else { +#endif + llz = isc_string_touint64(scopename, &ep, 10); + if (ep == scopename) + return (ISC_R_FAILURE); + + /* check overflow */ + zone = (isc_uint32_t)(llz & 0xffffffffUL); + if (zone != llz) + return (ISC_R_FAILURE); +#ifdef ISC_PLATFORM_HAVEIFNAMETOINDEX + } +#endif + + *zoneid = zone; + return (ISC_R_SUCCESS); +} diff -urN src/contrib/ntp/lib/isc/nls/msgcat.c src.ntp/contrib/ntp/lib/isc/nls/msgcat.c --- src/contrib/ntp/lib/isc/nls/msgcat.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/nls/msgcat.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,131 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: msgcat.c,v 1.18 2007/06/19 23:47:18 tbox Exp $ */ + +/*! \file msgcat.c + * + * \author Principal Author: Bob Halley + */ + +#include + +#include +#include + +#include +#include +#include + +#ifdef HAVE_CATGETS +#include /* Required for nl_catd. */ +#endif + +/* + * Implementation Notes: + * + * We use malloc() and free() instead of isc_mem_get() and isc_mem_put() + * because we don't want to require a memory context to be specified + * in order to use a message catalog. + */ + +struct isc_msgcat { + unsigned int magic; +#ifdef HAVE_CATGETS + nl_catd catalog; +#endif +}; + +#define MSGCAT_MAGIC ISC_MAGIC('M', 'C', 'a', 't') +#define VALID_MSGCAT(m) ISC_MAGIC_VALID(m, MSGCAT_MAGIC) + +void +isc_msgcat_open(const char *name, isc_msgcat_t **msgcatp) { + isc_msgcat_t *msgcat; + + /* + * Open a message catalog. + */ + + REQUIRE(name != NULL); + REQUIRE(msgcatp != NULL && *msgcatp == NULL); + + msgcat = malloc(sizeof(*msgcat)); + if (msgcat == NULL) { + *msgcatp = NULL; + return; + } + +#ifdef HAVE_CATGETS + /* + * We don't check if catopen() fails because we don't care. + * If it does fail, then when we call catgets(), it will use + * the default string. + */ + msgcat->catalog = catopen(name, 0); +#endif + msgcat->magic = MSGCAT_MAGIC; + + *msgcatp = msgcat; +} + +void +isc_msgcat_close(isc_msgcat_t **msgcatp) { + isc_msgcat_t *msgcat; + + /* + * Close a message catalog. + */ + + REQUIRE(msgcatp != NULL); + msgcat = *msgcatp; + REQUIRE(VALID_MSGCAT(msgcat) || msgcat == NULL); + + if (msgcat != NULL) { +#ifdef HAVE_CATGETS + if (msgcat->catalog != (nl_catd)(-1)) + (void)catclose(msgcat->catalog); +#endif + msgcat->magic = 0; + free(msgcat); + } + + *msgcatp = NULL; +} + +const char * +isc_msgcat_get(isc_msgcat_t *msgcat, int set, int message, + const char *default_text) +{ + /* + * Get message 'message' from message set 'set' in 'msgcat'. If it + * is not available, use 'default'. + */ + + REQUIRE(VALID_MSGCAT(msgcat) || msgcat == NULL); + REQUIRE(set > 0); + REQUIRE(message > 0); + REQUIRE(default_text != NULL); + +#ifdef HAVE_CATGETS + if (msgcat == NULL) + return (default_text); + return (catgets(msgcat->catalog, set, message, default_text)); +#else + return (default_text); +#endif +} diff -urN src/contrib/ntp/lib/isc/noatomic/include/isc/atomic.h src.ntp/contrib/ntp/lib/isc/noatomic/include/isc/atomic.h --- src/contrib/ntp/lib/isc/noatomic/include/isc/atomic.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/noatomic/include/isc/atomic.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,24 @@ +/* + * Copyright (C) 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: atomic.h,v 1.4 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_ATOMIC_H +#define ISC_ATOMIC_H 1 + +/* This file is inherently empty. */ + +#endif /* ISC_ATOMIC_H */ diff -urN src/contrib/ntp/lib/isc/nothreads/condition.c src.ntp/contrib/ntp/lib/isc/nothreads/condition.c --- src/contrib/ntp/lib/isc/nothreads/condition.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/nothreads/condition.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,24 @@ +/* + * Copyright (C) 2004, 2006, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: condition.c,v 1.10 2007/06/19 23:47:18 tbox Exp $ */ + +#include + +#include + +EMPTY_TRANSLATION_UNIT diff -urN src/contrib/ntp/lib/isc/nothreads/include/isc/condition.h src.ntp/contrib/ntp/lib/isc/nothreads/include/isc/condition.h --- src/contrib/ntp/lib/isc/nothreads/include/isc/condition.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/nothreads/include/isc/condition.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,59 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: condition.h,v 1.6 2007/06/19 23:47:18 tbox Exp $ */ + +/* + * This provides a limited subset of the isc_condition_t + * functionality for use by single-threaded programs that + * need to block waiting for events. Only a single + * call to isc_condition_wait() may be blocked at any given + * time, and the _waituntil and _broadcast functions are not + * supported. This is intended primarily for use by the omapi + * library, and may go away once omapi goes away. Use for + * other purposes is strongly discouraged. + */ + +#ifndef ISC_CONDITION_H +#define ISC_CONDITION_H 1 + +#include + +typedef int isc_condition_t; + +isc_result_t isc__nothread_wait_hack(isc_condition_t *cp, isc_mutex_t *mp); +isc_result_t isc__nothread_signal_hack(isc_condition_t *cp); + +#define isc_condition_init(cp) \ + (*(cp) = 0, ISC_R_SUCCESS) + +#define isc_condition_wait(cp, mp) \ + isc__nothread_wait_hack(cp, mp) + +#define isc_condition_waituntil(cp, mp, tp) \ + ((void)(cp), (void)(mp), (void)(tp), ISC_R_NOTIMPLEMENTED) + +#define isc_condition_signal(cp) \ + isc__nothread_signal_hack(cp) + +#define isc_condition_broadcast(cp) \ + ((void)(cp), ISC_R_NOTIMPLEMENTED) + +#define isc_condition_destroy(cp) \ + (*(cp) == 0 ? (*(cp) = -1, ISC_R_SUCCESS) : ISC_R_UNEXPECTED) + +#endif /* ISC_CONDITION_H */ diff -urN src/contrib/ntp/lib/isc/nothreads/include/isc/mutex.h src.ntp/contrib/ntp/lib/isc/nothreads/include/isc/mutex.h --- src/contrib/ntp/lib/isc/nothreads/include/isc/mutex.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/nothreads/include/isc/mutex.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,39 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: mutex.h,v 1.6 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_MUTEX_H +#define ISC_MUTEX_H 1 + +#include /* for ISC_R_ codes */ + +typedef int isc_mutex_t; + +#define isc_mutex_init(mp) \ + (*(mp) = 0, ISC_R_SUCCESS) +#define isc_mutex_lock(mp) \ + ((*(mp))++ == 0 ? ISC_R_SUCCESS : ISC_R_UNEXPECTED) +#define isc_mutex_unlock(mp) \ + (--(*(mp)) == 0 ? ISC_R_SUCCESS : ISC_R_UNEXPECTED) +#define isc_mutex_trylock(mp) \ + (*(mp) == 0 ? ((*(mp))++, ISC_R_SUCCESS) : ISC_R_LOCKBUSY) +#define isc_mutex_destroy(mp) \ + (*(mp) == 0 ? (*(mp) = -1, ISC_R_SUCCESS) : ISC_R_UNEXPECTED) +#define isc_mutex_stats(fp) + +#endif /* ISC_MUTEX_H */ diff -urN src/contrib/ntp/lib/isc/nothreads/include/isc/once.h src.ntp/contrib/ntp/lib/isc/nothreads/include/isc/once.h --- src/contrib/ntp/lib/isc/nothreads/include/isc/once.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/nothreads/include/isc/once.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: once.h,v 1.6 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_ONCE_H +#define ISC_ONCE_H 1 + +#include + +typedef isc_boolean_t isc_once_t; + +#define ISC_ONCE_INIT ISC_FALSE + +#define isc_once_do(op, f) \ + (!*(op) ? (f(), *(op) = ISC_TRUE, ISC_R_SUCCESS) : ISC_R_SUCCESS) + +#endif /* ISC_ONCE_H */ diff -urN src/contrib/ntp/lib/isc/nothreads/include/isc/thread.h src.ntp/contrib/ntp/lib/isc/nothreads/include/isc/thread.h --- src/contrib/ntp/lib/isc/nothreads/include/isc/thread.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/nothreads/include/isc/thread.h 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,35 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: thread.h,v 1.6 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_THREAD_H +#define ISC_THREAD_H 1 + +#include +#include + +ISC_LANG_BEGINDECLS + +void +isc_thread_setconcurrency(unsigned int level); + +#define isc_thread_self() ((unsigned long)0) + +ISC_LANG_ENDDECLS + +#endif /* ISC_THREAD_H */ diff -urN src/contrib/ntp/lib/isc/nothreads/mutex.c src.ntp/contrib/ntp/lib/isc/nothreads/mutex.c --- src/contrib/ntp/lib/isc/nothreads/mutex.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/nothreads/mutex.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,25 @@ +/* + * Copyright (C) 2004, 2006, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: mutex.c,v 1.10 2007/06/19 23:47:18 tbox Exp $ */ + +#include + +#include + +EMPTY_TRANSLATION_UNIT + diff -urN src/contrib/ntp/lib/isc/nothreads/thread.c src.ntp/contrib/ntp/lib/isc/nothreads/thread.c --- src/contrib/ntp/lib/isc/nothreads/thread.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/nothreads/thread.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,28 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: thread.c,v 1.5 2007/06/19 23:47:18 tbox Exp $ */ + +#include + +#include +#include + +void +isc_thread_setconcurrency(unsigned int level) { + UNUSED(level); +} diff -urN src/contrib/ntp/lib/isc/ondestroy.c src.ntp/contrib/ntp/lib/isc/ondestroy.c --- src/contrib/ntp/lib/isc/ondestroy.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/ondestroy.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,85 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: ondestroy.c,v 1.16 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include + +#include +#include +#include +#include +#include + +#define ONDESTROY_MAGIC ISC_MAGIC('D', 'e', 'S', 't') +#define VALID_ONDESTROY(s) ISC_MAGIC_VALID(s, ONDESTROY_MAGIC) + +void +isc_ondestroy_init(isc_ondestroy_t *ondest) { + ondest->magic = ONDESTROY_MAGIC; + ISC_LIST_INIT(ondest->events); +} + +isc_result_t +isc_ondestroy_register(isc_ondestroy_t *ondest, isc_task_t *task, + isc_event_t **eventp) +{ + isc_event_t *theevent; + isc_task_t *thetask = NULL; + + REQUIRE(VALID_ONDESTROY(ondest)); + REQUIRE(task != NULL); + REQUIRE(eventp != NULL); + + theevent = *eventp; + + REQUIRE(theevent != NULL); + + isc_task_attach(task, &thetask); + + theevent->ev_sender = thetask; + + ISC_LIST_APPEND(ondest->events, theevent, ev_link); + + return (ISC_R_SUCCESS); +} + +void +isc_ondestroy_notify(isc_ondestroy_t *ondest, void *sender) { + isc_event_t *eventp; + isc_task_t *task; + + REQUIRE(VALID_ONDESTROY(ondest)); + + eventp = ISC_LIST_HEAD(ondest->events); + while (eventp != NULL) { + ISC_LIST_UNLINK(ondest->events, eventp, ev_link); + + task = eventp->ev_sender; + eventp->ev_sender = sender; + + isc_task_sendanddetach(&task, &eventp); + + eventp = ISC_LIST_HEAD(ondest->events); + } +} + + diff -urN src/contrib/ntp/lib/isc/parseint.c src.ntp/contrib/ntp/lib/isc/parseint.c --- src/contrib/ntp/lib/isc/parseint.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/parseint.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,72 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: parseint.c,v 1.8 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include + +#include +#include +#include + +isc_result_t +isc_parse_uint32(isc_uint32_t *uip, const char *string, int base) { + unsigned long n; + char *e; + if (! isalnum((unsigned char)(string[0]))) + return (ISC_R_BADNUMBER); + errno = 0; + n = strtoul(string, &e, base); + if (*e != '\0') + return (ISC_R_BADNUMBER); + if (n == ULONG_MAX && errno == ERANGE) + return (ISC_R_RANGE); + *uip = n; + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_parse_uint16(isc_uint16_t *uip, const char *string, int base) { + isc_uint32_t val; + isc_result_t result; + result = isc_parse_uint32(&val, string, base); + if (result != ISC_R_SUCCESS) + return (result); + if (val > 0xFFFF) + return (ISC_R_RANGE); + *uip = (isc_uint16_t) val; + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_parse_uint8(isc_uint8_t *uip, const char *string, int base) { + isc_uint32_t val; + isc_result_t result; + result = isc_parse_uint32(&val, string, base); + if (result != ISC_R_SUCCESS) + return (result); + if (val > 0xFF) + return (ISC_R_RANGE); + *uip = (isc_uint8_t) val; + return (ISC_R_SUCCESS); +} diff -urN src/contrib/ntp/lib/isc/portset.c src.ntp/contrib/ntp/lib/isc/portset.c --- src/contrib/ntp/lib/isc/portset.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/portset.c 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,143 @@ +/* + * Copyright (C) 2008 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: portset.c,v 1.4 2008/06/24 23:24:35 marka Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include +#include +#include + +#define ISC_PORTSET_BUFSIZE (65536 / (sizeof(isc_uint32_t) * 8)) + +/*% + * Internal representation of portset. It's an array of 32-bit integers, each + * bit corresponding to a single port in the ascending order. For example, + * the second most significant bit of buf[0] corresponds to port 1. + */ +struct isc_portset { + unsigned int nports; /*%< number of ports in the set */ + isc_uint32_t buf[ISC_PORTSET_BUFSIZE]; +}; + +static inline isc_boolean_t +portset_isset(isc_portset_t *portset, in_port_t port) { + return (ISC_TF((portset->buf[port >> 5] & (1 << (port & 31))) != 0)); +} + +static inline void +portset_add(isc_portset_t *portset, in_port_t port) { + if (!portset_isset(portset, port)) { + portset->nports++; + portset->buf[port >> 5] |= (1 << (port & 31)); + } +} + +static inline void +portset_remove(isc_portset_t *portset, in_port_t port) { + if (portset_isset(portset, port)) { + portset->nports--; + portset->buf[port >> 5] &= ~(1 << (port & 31)); + } +} + +isc_result_t +isc_portset_create(isc_mem_t *mctx, isc_portset_t **portsetp) { + isc_portset_t *portset; + + REQUIRE(portsetp != NULL && *portsetp == NULL); + + portset = isc_mem_get(mctx, sizeof(*portset)); + if (portset == NULL) + return (ISC_R_NOMEMORY); + + /* Make the set 'empty' by default */ + memset(portset, 0, sizeof(*portset)); + *portsetp = portset; + + return (ISC_R_SUCCESS); +} + +void +isc_portset_destroy(isc_mem_t *mctx, isc_portset_t **portsetp) { + isc_portset_t *portset; + + REQUIRE(portsetp != NULL); + portset = *portsetp; + + isc_mem_put(mctx, portset, sizeof(*portset)); +} + +isc_boolean_t +isc_portset_isset(isc_portset_t *portset, in_port_t port) { + REQUIRE(portset != NULL); + + return (portset_isset(portset, port)); +} + +unsigned int +isc_portset_nports(isc_portset_t *portset) { + REQUIRE(portset != NULL); + + return (portset->nports); +} + +void +isc_portset_add(isc_portset_t *portset, in_port_t port) { + REQUIRE(portset != NULL); + + portset_add(portset, port); +} + +void +isc_portset_remove(isc_portset_t *portset, in_port_t port) { + portset_remove(portset, port); +} + +void +isc_portset_addrange(isc_portset_t *portset, in_port_t port_lo, + in_port_t port_hi) +{ + in_port_t p; + + REQUIRE(portset != NULL); + REQUIRE(port_lo <= port_hi); + + p = port_lo; + do { + portset_add(portset, p); + } while (p++ < port_hi); +} + +void +isc_portset_removerange(isc_portset_t *portset, in_port_t port_lo, + in_port_t port_hi) +{ + in_port_t p; + + REQUIRE(portset != NULL); + REQUIRE(port_lo <= port_hi); + + p = port_lo; + do { + portset_remove(portset, p); + } while (p++ < port_hi); +} diff -urN src/contrib/ntp/lib/isc/powerpc/include/isc/atomic.h src.ntp/contrib/ntp/lib/isc/powerpc/include/isc/atomic.h --- src/contrib/ntp/lib/isc/powerpc/include/isc/atomic.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/powerpc/include/isc/atomic.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,160 @@ +/* + * Copyright (C) 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: atomic.h,v 1.6 2007/06/18 23:47:47 tbox Exp $ */ + +#ifndef ISC_ATOMIC_H +#define ISC_ATOMIC_H 1 + +#include +#include + +/*!\file + * static inline isc_int32_t + * isc_atomic_xadd(isc_int32_t *p, isc_int32_t val); + * + * This routine atomically increments the value stored in 'p' by 'val', and + * returns the previous value. + * + * static inline void + * isc_atomic_store(void *p, isc_int32_t val); + * + * This routine atomically stores the value 'val' in 'p'. + * + * static inline isc_int32_t + * isc_atomic_cmpxchg(isc_int32_t *p, isc_int32_t cmpval, isc_int32_t val); + * + * This routine atomically replaces the value in 'p' with 'val', if the + * original value is equal to 'cmpval'. The original value is returned in any + * case. + */ + +#if defined(_AIX) + +#include + +#define isc_atomic_xadd(p, v) fetch_and_add(p, v) +#define isc_atomic_store(p, v) _clear_lock(p, v) + +#ifdef __GNUC__ +static inline int +#else +static int +#endif +isc_atomic_cmpxchg(atomic_p p, int old, int new) { + int orig = old; + +#ifdef __GNUC__ + asm("ics"); +#else + __isync(); +#endif + if (compare_and_swap(p, &orig, new)) + return (old); + return (orig); +} + +#elif defined(ISC_PLATFORM_USEGCCASM) || defined(ISC_PLATFORM_USEMACASM) +static inline isc_int32_t +isc_atomic_xadd(isc_int32_t *p, isc_int32_t val) { + isc_int32_t orig; + + __asm__ volatile ( +#ifdef ISC_PLATFORM_USEMACASM + "1:" + "lwarx r6, 0, %1\n" + "mr %0, r6\n" + "add r6, r6, %2\n" + "stwcx. r6, 0, %1\n" + "bne- 1b" +#else + "1:" + "lwarx 6, 0, %1\n" + "mr %0, 6\n" + "add 6, 6, %2\n" + "stwcx. 6, 0, %1\n" + "bne- 1b" +#endif + : "=&r"(orig) + : "r"(p), "r"(val) + : "r6", "memory" + ); + + return (orig); +} + +static inline void +isc_atomic_store(void *p, isc_int32_t val) { + __asm__ volatile ( +#ifdef ISC_PLATFORM_USEMACASM + "1:" + "lwarx r6, 0, %0\n" + "lwz r6, %1\n" + "stwcx. r6, 0, %0\n" + "bne- 1b" +#else + "1:" + "lwarx 6, 0, %0\n" + "lwz 6, %1\n" + "stwcx. 6, 0, %0\n" + "bne- 1b" +#endif + : + : "r"(p), "m"(val) + : "r6", "memory" + ); +} + +static inline isc_int32_t +isc_atomic_cmpxchg(isc_int32_t *p, isc_int32_t cmpval, isc_int32_t val) { + isc_int32_t orig; + + __asm__ volatile ( +#ifdef ISC_PLATFORM_USEMACASM + "1:" + "lwarx r6, 0, %1\n" + "mr %0,r6\n" + "cmpw r6, %2\n" + "bne 2f\n" + "mr r6, %3\n" + "stwcx. r6, 0, %1\n" + "bne- 1b\n" + "2:" +#else + "1:" + "lwarx 6, 0, %1\n" + "mr %0,6\n" + "cmpw 6, %2\n" + "bne 2f\n" + "mr 6, %3\n" + "stwcx. 6, 0, %1\n" + "bne- 1b\n" + "2:" +#endif + : "=&r" (orig) + : "r"(p), "r"(cmpval), "r"(val) + : "r6", "memory" + ); + + return (orig); +} + +#else + +#error "unsupported compiler. disable atomic ops by --disable-atomic" + +#endif +#endif /* ISC_ATOMIC_H */ diff -urN src/contrib/ntp/lib/isc/print.c src.ntp/contrib/ntp/lib/isc/print.c --- src/contrib/ntp/lib/isc/print.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/print.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,624 @@ +/* + * Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: print.c,v 1.35 2008/02/18 23:46:59 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include /* for sprintf() */ +#include /* for strlen() */ + +#define ISC__PRINT_SOURCE /* Used to get the isc_print_* prototypes. */ + +#include +#include +#include +#include +#include +#include + +int +isc_print_sprintf(char *str, const char *format, ...) { + va_list ap; + + va_start(ap, format); + vsprintf(str, format, ap); + va_end(ap); + return (strlen(str)); +} + +/*! + * Return length of string that would have been written if not truncated. + */ + +int +isc_print_snprintf(char *str, size_t size, const char *format, ...) { + va_list ap; + int ret; + + va_start(ap, format); + ret = vsnprintf(str, size, format, ap); + va_end(ap); + return (ret); + +} + +/*! + * Return length of string that would have been written if not truncated. + */ + +int +isc_print_vsnprintf(char *str, size_t size, const char *format, va_list ap) { + int h; + int l; + int q; + int alt; + int zero; + int left; + int plus; + int space; + int neg; + isc_int64_t tmpi; + isc_uint64_t tmpui; + unsigned long width; + unsigned long precision; + unsigned int length; + char buf[1024]; + char c; + void *v; + char *save = str; + const char *cp; + const char *head; + int count = 0; + int pad; + int zeropad; + int dot; + double dbl; +#ifdef HAVE_LONG_DOUBLE + long double ldbl; +#endif + char fmt[32]; + + INSIST(str != NULL); + INSIST(format != NULL); + + while (*format != '\0') { + if (*format != '%') { + if (size > 1) { + *str++ = *format; + size--; + } + count++; + format++; + continue; + } + format++; + + /* + * Reset flags. + */ + dot = neg = space = plus = left = zero = alt = h = l = q = 0; + width = precision = 0; + head = ""; + length = pad = zeropad = 0; + + do { + if (*format == '#') { + alt = 1; + format++; + } else if (*format == '-') { + left = 1; + zero = 0; + format++; + } else if (*format == ' ') { + if (!plus) + space = 1; + format++; + } else if (*format == '+') { + plus = 1; + space = 0; + format++; + } else if (*format == '0') { + if (!left) + zero = 1; + format++; + } else + break; + } while (1); + + /* + * Width. + */ + if (*format == '*') { + width = va_arg(ap, int); + format++; + } else if (isdigit((unsigned char)*format)) { + char *e; + width = strtoul(format, &e, 10); + format = e; + } + + /* + * Precision. + */ + if (*format == '.') { + format++; + dot = 1; + if (*format == '*') { + precision = va_arg(ap, int); + format++; + } else if (isdigit((unsigned char)*format)) { + char *e; + precision = strtoul(format, &e, 10); + format = e; + } + } + + switch (*format) { + case '\0': + continue; + case '%': + if (size > 1) { + *str++ = *format; + size--; + } + count++; + break; + case 'q': + q = 1; + format++; + goto doint; + case 'h': + h = 1; + format++; + goto doint; + case 'l': + l = 1; + format++; + if (*format == 'l') { + q = 1; + format++; + } + goto doint; + case 'n': + case 'i': + case 'd': + case 'o': + case 'u': + case 'x': + case 'X': + doint: + if (precision != 0) + zero = 0; + switch (*format) { + case 'n': + if (h) { + short int *p; + p = va_arg(ap, short *); + REQUIRE(p != NULL); + *p = str - save; + } else if (l) { + long int *p; + p = va_arg(ap, long *); + REQUIRE(p != NULL); + *p = str - save; + } else { + int *p; + p = va_arg(ap, int *); + REQUIRE(p != NULL); + *p = str - save; + } + break; + case 'i': + case 'd': + if (q) + tmpi = va_arg(ap, isc_int64_t); + else if (l) + tmpi = va_arg(ap, long int); + else + tmpi = va_arg(ap, int); + if (tmpi < 0) { + head = "-"; + tmpui = -tmpi; + } else { + if (plus) + head = "+"; + else if (space) + head = " "; + else + head = ""; + tmpui = tmpi; + } + if (tmpui <= 0xffffffffU) + sprintf(buf, "%lu", + (unsigned long)tmpui); + else { + unsigned long mid; + unsigned long lo; + unsigned long hi; + lo = tmpui % 1000000000; + tmpui /= 1000000000; + mid = tmpui % 1000000000; + hi = tmpui / 1000000000; + if (hi != 0) + sprintf(buf, "%lu", hi); + else + buf[0] = '\n'; + sprintf(buf + strlen(buf), "%lu", mid); + sprintf(buf + strlen(buf), "%lu", lo); + } + goto printint; + case 'o': + if (q) + tmpui = va_arg(ap, isc_uint64_t); + else if (l) + tmpui = va_arg(ap, long int); + else + tmpui = va_arg(ap, int); + if (tmpui <= 0xffffffffU) + sprintf(buf, alt ? "%#lo" : "%lo", + (unsigned long)tmpui); + else { + unsigned long mid; + unsigned long lo; + unsigned long hi; + lo = tmpui % 010000000000; + tmpui /= 010000000000; + mid = tmpui % 010000000000; + hi = tmpui / 010000000000; + if (hi != 0) { + sprintf(buf, + alt ? "%#lo" : "%lo", + hi); + sprintf(buf + strlen(buf), + "%lo", mid); + } else + sprintf(buf, + alt ? "%#lo" : "%lo", + mid); + sprintf(buf + strlen(buf), "%lo", lo); + } + goto printint; + case 'u': + if (q) + tmpui = va_arg(ap, isc_uint64_t); + else if (l) + tmpui = va_arg(ap, unsigned long int); + else + tmpui = va_arg(ap, unsigned int); + if (tmpui <= 0xffffffffU) + sprintf(buf, "%lu", + (unsigned long)tmpui); + else { + unsigned long mid; + unsigned long lo; + unsigned long hi; + lo = tmpui % 1000000000; + tmpui /= 1000000000; + mid = tmpui % 1000000000; + hi = tmpui / 1000000000; + if (hi != 0) + sprintf(buf, "%lu", hi); + else + buf[0] = '\n'; + sprintf(buf + strlen(buf), "%lu", mid); + sprintf(buf + strlen(buf), "%lu", lo); + } + goto printint; + case 'x': + if (q) + tmpui = va_arg(ap, isc_uint64_t); + else if (l) + tmpui = va_arg(ap, unsigned long int); + else + tmpui = va_arg(ap, unsigned int); + if (alt) { + head = "0x"; + if (precision > 2) + precision -= 2; + } + if (tmpui <= 0xffffffffU) + sprintf(buf, "%lx", + (unsigned long)tmpui); + else { + unsigned long hi = tmpui>>32; + unsigned long lo = tmpui & 0xffffffff; + sprintf(buf, "%lx", hi); + sprintf(buf + strlen(buf), "%lx", lo); + } + goto printint; + case 'X': + if (q) + tmpui = va_arg(ap, isc_uint64_t); + else if (l) + tmpui = va_arg(ap, unsigned long int); + else + tmpui = va_arg(ap, unsigned int); + if (alt) { + head = "0X"; + if (precision > 2) + precision -= 2; + } + if (tmpui <= 0xffffffffU) + sprintf(buf, "%lX", + (unsigned long)tmpui); + else { + unsigned long hi = tmpui>>32; + unsigned long lo = tmpui & 0xffffffff; + sprintf(buf, "%lX", hi); + sprintf(buf + strlen(buf), "%lX", lo); + } + goto printint; + printint: + if (precision != 0 || width != 0) { + length = strlen(buf); + if (length < precision) + zeropad = precision - length; + else if (length < width && zero) + zeropad = width - length; + if (width != 0) { + pad = width - length - + zeropad - strlen(head); + if (pad < 0) + pad = 0; + } + } + count += strlen(head) + strlen(buf) + pad + + zeropad; + if (!left) { + while (pad > 0 && size > 1) { + *str++ = ' '; + size--; + pad--; + } + } + cp = head; + while (*cp != '\0' && size > 1) { + *str++ = *cp++; + size--; + } + while (zeropad > 0 && size > 1) { + *str++ = '0'; + size--; + zeropad--; + } + cp = buf; + while (*cp != '\0' && size > 1) { + *str++ = *cp++; + size--; + } + while (pad > 0 && size > 1) { + *str++ = ' '; + size--; + pad--; + } + break; + default: + break; + } + break; + case 's': + cp = va_arg(ap, char *); + REQUIRE(cp != NULL); + + if (precision != 0) { + /* + * cp need not be NULL terminated. + */ + const char *tp; + unsigned long n; + + n = precision; + tp = cp; + while (n != 0 && *tp != '\0') + n--, tp++; + length = precision - n; + } else { + length = strlen(cp); + } + if (width != 0) { + pad = width - length; + if (pad < 0) + pad = 0; + } + count += pad + length; + if (!left) + while (pad > 0 && size > 1) { + *str++ = ' '; + size--; + pad--; + } + if (precision != 0) + while (precision > 0 && *cp != '\0' && + size > 1) { + *str++ = *cp++; + size--; + precision--; + } + else + while (*cp != '\0' && size > 1) { + *str++ = *cp++; + size--; + } + while (pad > 0 && size > 1) { + *str++ = ' '; + size--; + pad--; + } + break; + case 'c': + c = va_arg(ap, int); + if (width > 0) { + count += width; + width--; + if (left) { + *str++ = c; + size--; + } + while (width-- > 0 && size > 1) { + *str++ = ' '; + size--; + } + if (!left && size > 1) { + *str++ = c; + size--; + } + } else { + count++; + if (size > 1) { + *str++ = c; + size--; + } + } + break; + case 'p': + v = va_arg(ap, void *); + sprintf(buf, "%p", v); + length = strlen(buf); + if (precision > length) + zeropad = precision - length; + if (width > 0) { + pad = width - length - zeropad; + if (pad < 0) + pad = 0; + } + count += length + pad + zeropad; + if (!left) + while (pad > 0 && size > 1) { + *str++ = ' '; + size--; + pad--; + } + cp = buf; + if (zeropad > 0 && buf[0] == '0' && + (buf[1] == 'x' || buf[1] == 'X')) { + if (size > 1) { + *str++ = *cp++; + size--; + } + if (size > 1) { + *str++ = *cp++; + size--; + } + while (zeropad > 0 && size > 1) { + *str++ = '0'; + size--; + zeropad--; + } + } + while (*cp != '\0' && size > 1) { + *str++ = *cp++; + size--; + } + while (pad > 0 && size > 1) { + *str++ = ' '; + size--; + pad--; + } + break; + case 'D': /*deprecated*/ + INSIST("use %ld instead of %D" == NULL); + case 'O': /*deprecated*/ + INSIST("use %lo instead of %O" == NULL); + case 'U': /*deprecated*/ + INSIST("use %lu instead of %U" == NULL); + + case 'L': +#ifdef HAVE_LONG_DOUBLE + l = 1; +#else + INSIST("long doubles are not supported" == NULL); +#endif + /*FALLTHROUGH*/ + case 'e': + case 'E': + case 'f': + case 'g': + case 'G': + if (!dot) + precision = 6; + /* + * IEEE floating point. + * MIN 2.2250738585072014E-308 + * MAX 1.7976931348623157E+308 + * VAX floating point has a smaller range than IEEE. + * + * precisions > 324 don't make much sense. + * if we cap the precision at 512 we will not + * overflow buf. + */ + if (precision > 512) + precision = 512; + sprintf(fmt, "%%%s%s.%lu%s%c", alt ? "#" : "", + plus ? "+" : space ? " " : "", + precision, l ? "L" : "", *format); + switch (*format) { + case 'e': + case 'E': + case 'f': + case 'g': + case 'G': +#ifdef HAVE_LONG_DOUBLE + if (l) { + ldbl = va_arg(ap, long double); + sprintf(buf, fmt, ldbl); + } else +#endif + { + dbl = va_arg(ap, double); + sprintf(buf, fmt, dbl); + } + length = strlen(buf); + if (width > 0) { + pad = width - length; + if (pad < 0) + pad = 0; + } + count += length + pad; + if (!left) + while (pad > 0 && size > 1) { + *str++ = ' '; + size--; + pad--; + } + cp = buf; + while (*cp != ' ' && size > 1) { + *str++ = *cp++; + size--; + } + while (pad > 0 && size > 1) { + *str++ = ' '; + size--; + pad--; + } + break; + default: + continue; + } + break; + default: + continue; + } + format++; + } + if (size > 0) + *str = '\0'; + return (count); +} diff -urN src/contrib/ntp/lib/isc/pthreads/condition.c src.ntp/contrib/ntp/lib/isc/pthreads/condition.c --- src/contrib/ntp/lib/isc/pthreads/condition.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/pthreads/condition.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,74 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: condition.c,v 1.36 2007/06/19 23:47:18 tbox Exp $ */ + +/*! \file */ + +#include + +#include + +#include +#include +#include +#include +#include +#include + +isc_result_t +isc_condition_waituntil(isc_condition_t *c, isc_mutex_t *m, isc_time_t *t) { + int presult; + isc_result_t result; + struct timespec ts; + char strbuf[ISC_STRERRORSIZE]; + + REQUIRE(c != NULL && m != NULL && t != NULL); + + /* + * POSIX defines a timespec's tv_sec as time_t. + */ + result = isc_time_secondsastimet(t, &ts.tv_sec); + if (result != ISC_R_SUCCESS) + return (result); + + /*! + * POSIX defines a timespec's tv_nsec as long. isc_time_nanoseconds + * ensures its return value is < 1 billion, which will fit in a long. + */ + ts.tv_nsec = (long)isc_time_nanoseconds(t); + + do { +#if ISC_MUTEX_PROFILE + presult = pthread_cond_timedwait(c, &m->mutex, &ts); +#else + presult = pthread_cond_timedwait(c, m, &ts); +#endif + if (presult == 0) + return (ISC_R_SUCCESS); + if (presult == ETIMEDOUT) + return (ISC_R_TIMEDOUT); + } while (presult == EINTR); + + isc__strerror(presult, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "pthread_cond_timedwait() %s %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_RETURNED, "returned"), + strbuf); + return (ISC_R_UNEXPECTED); +} diff -urN src/contrib/ntp/lib/isc/pthreads/include/isc/condition.h src.ntp/contrib/ntp/lib/isc/pthreads/include/isc/condition.h --- src/contrib/ntp/lib/isc/pthreads/include/isc/condition.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/pthreads/include/isc/condition.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,65 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: condition.h,v 1.26 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_CONDITION_H +#define ISC_CONDITION_H 1 + +/*! \file */ + +#include +#include +#include +#include + +typedef pthread_cond_t isc_condition_t; + +#define isc_condition_init(cp) \ + ((pthread_cond_init((cp), NULL) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) + +#if ISC_MUTEX_PROFILE +#define isc_condition_wait(cp, mp) \ + ((pthread_cond_wait((cp), &((mp)->mutex)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) +#else +#define isc_condition_wait(cp, mp) \ + ((pthread_cond_wait((cp), (mp)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) +#endif + +#define isc_condition_signal(cp) \ + ((pthread_cond_signal((cp)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) + +#define isc_condition_broadcast(cp) \ + ((pthread_cond_broadcast((cp)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) + +#define isc_condition_destroy(cp) \ + ((pthread_cond_destroy((cp)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_condition_waituntil(isc_condition_t *, isc_mutex_t *, isc_time_t *); + +ISC_LANG_ENDDECLS + +#endif /* ISC_CONDITION_H */ diff -urN src/contrib/ntp/lib/isc/pthreads/include/isc/mutex.h src.ntp/contrib/ntp/lib/isc/pthreads/include/isc/mutex.h --- src/contrib/ntp/lib/isc/pthreads/include/isc/mutex.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/pthreads/include/isc/mutex.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,145 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: mutex.h,v 1.30 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_MUTEX_H +#define ISC_MUTEX_H 1 + +/*! \file */ + +#include +#include + +#include +#include /* for ISC_R_ codes */ + +ISC_LANG_BEGINDECLS + +/*! + * Supply mutex attributes that enable deadlock detection + * (helpful when debugging). This is system dependent and + * currently only supported on NetBSD. + */ +#if ISC_MUTEX_DEBUG && defined(__NetBSD__) && defined(PTHREAD_MUTEX_ERRORCHECK) +extern pthread_mutexattr_t isc__mutex_attrs; +#define ISC__MUTEX_ATTRS &isc__mutex_attrs +#else +#define ISC__MUTEX_ATTRS NULL +#endif + +/* XXX We could do fancier error handling... */ + +/*! + * Define ISC_MUTEX_PROFILE to turn on profiling of mutexes by line. When + * enabled, isc_mutex_stats() can be used to print a table showing the + * number of times each type of mutex was locked and the amount of time + * waiting to obtain the lock. + */ +#ifndef ISC_MUTEX_PROFILE +#define ISC_MUTEX_PROFILE 0 +#endif + +#if ISC_MUTEX_PROFILE +typedef struct isc_mutexstats isc_mutexstats_t; + +typedef struct { + pthread_mutex_t mutex; /*%< The actual mutex. */ + isc_mutexstats_t * stats; /*%< Mutex statistics. */ +} isc_mutex_t; +#else +typedef pthread_mutex_t isc_mutex_t; +#endif + + +#if ISC_MUTEX_PROFILE +#define isc_mutex_init(mp) \ + isc_mutex_init_profile((mp), __FILE__, __LINE__) +#else +#if ISC_MUTEX_DEBUG && defined(PTHREAD_MUTEX_ERRORCHECK) +#define isc_mutex_init(mp) \ + isc_mutex_init_errcheck((mp)) +#else +#define isc_mutex_init(mp) \ + isc__mutex_init((mp), __FILE__, __LINE__) +isc_result_t isc__mutex_init(isc_mutex_t *mp, const char *file, unsigned int line); +#endif +#endif + +#if ISC_MUTEX_PROFILE +#define isc_mutex_lock(mp) \ + isc_mutex_lock_profile((mp), __FILE__, __LINE__) +#else +#define isc_mutex_lock(mp) \ + ((pthread_mutex_lock((mp)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) +#endif + +#if ISC_MUTEX_PROFILE +#define isc_mutex_unlock(mp) \ + isc_mutex_unlock_profile((mp), __FILE__, __LINE__) +#else +#define isc_mutex_unlock(mp) \ + ((pthread_mutex_unlock((mp)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) +#endif + +#if ISC_MUTEX_PROFILE +#define isc_mutex_trylock(mp) \ + ((pthread_mutex_trylock((&(mp)->mutex)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_LOCKBUSY) +#else +#define isc_mutex_trylock(mp) \ + ((pthread_mutex_trylock((mp)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_LOCKBUSY) +#endif + +#if ISC_MUTEX_PROFILE +#define isc_mutex_destroy(mp) \ + ((pthread_mutex_destroy((&(mp)->mutex)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) +#else +#define isc_mutex_destroy(mp) \ + ((pthread_mutex_destroy((mp)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) +#endif + +#if ISC_MUTEX_PROFILE +#define isc_mutex_stats(fp) isc_mutex_statsprofile(fp); +#else +#define isc_mutex_stats(fp) +#endif + +#if ISC_MUTEX_PROFILE + +isc_result_t +isc_mutex_init_profile(isc_mutex_t *mp, const char * _file, int _line); +isc_result_t +isc_mutex_lock_profile(isc_mutex_t *mp, const char * _file, int _line); +isc_result_t +isc_mutex_unlock_profile(isc_mutex_t *mp, const char * _file, int _line); + +void +isc_mutex_statsprofile(FILE *fp); + +isc_result_t +isc_mutex_init_errcheck(isc_mutex_t *mp); + +#endif /* ISC_MUTEX_PROFILE */ + +ISC_LANG_ENDDECLS +#endif /* ISC_MUTEX_H */ diff -urN src/contrib/ntp/lib/isc/pthreads/include/isc/once.h src.ntp/contrib/ntp/lib/isc/pthreads/include/isc/once.h --- src/contrib/ntp/lib/isc/pthreads/include/isc/once.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/pthreads/include/isc/once.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,50 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: once.h,v 1.13 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_ONCE_H +#define ISC_ONCE_H 1 + +/*! \file */ + +#include + +#include +#include + +typedef pthread_once_t isc_once_t; + +#ifdef ISC_PLATFORM_BRACEPTHREADONCEINIT +/*! + * This accomodates systems that define PTHRAD_ONCE_INIT improperly. + */ +#define ISC_ONCE_INIT { PTHREAD_ONCE_INIT } +#else +/*! + * This is the usual case. + */ +#define ISC_ONCE_INIT PTHREAD_ONCE_INIT +#endif + +/* XXX We could do fancier error handling... */ + +#define isc_once_do(op, f) \ + ((pthread_once((op), (f)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) + +#endif /* ISC_ONCE_H */ diff -urN src/contrib/ntp/lib/isc/pthreads/include/isc/thread.h src.ntp/contrib/ntp/lib/isc/pthreads/include/isc/thread.h --- src/contrib/ntp/lib/isc/pthreads/include/isc/thread.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/pthreads/include/isc/thread.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,60 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: thread.h,v 1.26 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_THREAD_H +#define ISC_THREAD_H 1 + +/*! \file */ + +#include + +#include +#include + +ISC_LANG_BEGINDECLS + +typedef pthread_t isc_thread_t; +typedef void * isc_threadresult_t; +typedef void * isc_threadarg_t; +typedef isc_threadresult_t (*isc_threadfunc_t)(isc_threadarg_t); +typedef pthread_key_t isc_thread_key_t; + +isc_result_t +isc_thread_create(isc_threadfunc_t, isc_threadarg_t, isc_thread_t *); + +void +isc_thread_setconcurrency(unsigned int level); + +/* XXX We could do fancier error handling... */ + +#define isc_thread_join(t, rp) \ + ((pthread_join((t), (rp)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) + +#define isc_thread_self \ + (unsigned long)pthread_self + +#define isc_thread_key_create pthread_key_create +#define isc_thread_key_getspecific pthread_getspecific +#define isc_thread_key_setspecific pthread_setspecific +#define isc_thread_key_delete pthread_key_delete + +ISC_LANG_ENDDECLS + +#endif /* ISC_THREAD_H */ diff -urN src/contrib/ntp/lib/isc/pthreads/mutex.c src.ntp/contrib/ntp/lib/isc/pthreads/mutex.c --- src/contrib/ntp/lib/isc/pthreads/mutex.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/pthreads/mutex.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,272 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: mutex.c,v 1.16 2008/04/04 23:47:01 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include +#include + +#include +#include +#include + +#if ISC_MUTEX_PROFILE + +/*@{*/ +/*% Operations on timevals; adapted from FreeBSD's sys/time.h */ +#define timevalclear(tvp) ((tvp)->tv_sec = (tvp)->tv_usec = 0) +#define timevaladd(vvp, uvp) \ + do { \ + (vvp)->tv_sec += (uvp)->tv_sec; \ + (vvp)->tv_usec += (uvp)->tv_usec; \ + if ((vvp)->tv_usec >= 1000000) { \ + (vvp)->tv_sec++; \ + (vvp)->tv_usec -= 1000000; \ + } \ + } while (0) +#define timevalsub(vvp, uvp) \ + do { \ + (vvp)->tv_sec -= (uvp)->tv_sec; \ + (vvp)->tv_usec -= (uvp)->tv_usec; \ + if ((vvp)->tv_usec < 0) { \ + (vvp)->tv_sec--; \ + (vvp)->tv_usec += 1000000; \ + } \ + } while (0) + +/*@}*/ + +#define ISC_MUTEX_MAX_LOCKERS 32 + +typedef struct { + const char * file; + int line; + unsigned count; + struct timeval locked_total; + struct timeval wait_total; +} isc_mutexlocker_t; + +struct isc_mutexstats { + const char * file; /*%< File mutex was created in. */ + int line; /*%< Line mutex was created on. */ + unsigned count; + struct timeval lock_t; + struct timeval locked_total; + struct timeval wait_total; + isc_mutexlocker_t * cur_locker; + isc_mutexlocker_t lockers[ISC_MUTEX_MAX_LOCKERS]; +}; + +#ifndef ISC_MUTEX_PROFTABLESIZE +#define ISC_MUTEX_PROFTABLESIZE (16 * 1024) +#endif +static isc_mutexstats_t stats[ISC_MUTEX_PROFTABLESIZE]; +static int stats_next = 0; +static isc_boolean_t stats_init = ISC_FALSE; +static pthread_mutex_t statslock = PTHREAD_MUTEX_INITIALIZER; + + +isc_result_t +isc_mutex_init_profile(isc_mutex_t *mp, const char *file, int line) { + int i, err; + + err = pthread_mutex_init(&mp->mutex, NULL); + if (err == ENOMEM) + return (ISC_R_NOMEMORY); + if (err != 0) + return (ISC_R_UNEXPECTED); + + RUNTIME_CHECK(pthread_mutex_lock(&statslock) == 0); + + if (stats_init == ISC_FALSE) + stats_init = ISC_TRUE; + + /* + * If all statistics entries have been used, give up and trigger an + * assertion failure. There would be no other way to deal with this + * because we'd like to keep record of all locks for the purpose of + * debugging and the number of necessary locks is unpredictable. + * If this failure is triggered while debugging, named should be + * rebuilt with an increased ISC_MUTEX_PROFTABLESIZE. + */ + RUNTIME_CHECK(stats_next < ISC_MUTEX_PROFTABLESIZE); + mp->stats = &stats[stats_next++]; + + RUNTIME_CHECK(pthread_mutex_unlock(&statslock) == 0); + + mp->stats->file = file; + mp->stats->line = line; + mp->stats->count = 0; + timevalclear(&mp->stats->locked_total); + timevalclear(&mp->stats->wait_total); + for (i = 0; i < ISC_MUTEX_MAX_LOCKERS; i++) { + mp->stats->lockers[i].file = NULL; + mp->stats->lockers[i].line = 0; + mp->stats->lockers[i].count = 0; + timevalclear(&mp->stats->lockers[i].locked_total); + timevalclear(&mp->stats->lockers[i].wait_total); + } + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_mutex_lock_profile(isc_mutex_t *mp, const char *file, int line) { + struct timeval prelock_t; + struct timeval postlock_t; + isc_mutexlocker_t *locker = NULL; + int i; + + gettimeofday(&prelock_t, NULL); + + if (pthread_mutex_lock(&mp->mutex) != 0) + return (ISC_R_UNEXPECTED); + + gettimeofday(&postlock_t, NULL); + mp->stats->lock_t = postlock_t; + + timevalsub(&postlock_t, &prelock_t); + + mp->stats->count++; + timevaladd(&mp->stats->wait_total, &postlock_t); + + for (i = 0; i < ISC_MUTEX_MAX_LOCKERS; i++) { + if (mp->stats->lockers[i].file == NULL) { + locker = &mp->stats->lockers[i]; + locker->file = file; + locker->line = line; + break; + } else if (mp->stats->lockers[i].file == file && + mp->stats->lockers[i].line == line) { + locker = &mp->stats->lockers[i]; + break; + } + } + + if (locker != NULL) { + locker->count++; + timevaladd(&locker->wait_total, &postlock_t); + } + + mp->stats->cur_locker = locker; + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_mutex_unlock_profile(isc_mutex_t *mp, const char *file, int line) { + struct timeval unlock_t; + + UNUSED(file); + UNUSED(line); + + if (mp->stats->cur_locker != NULL) { + gettimeofday(&unlock_t, NULL); + timevalsub(&unlock_t, &mp->stats->lock_t); + timevaladd(&mp->stats->locked_total, &unlock_t); + timevaladd(&mp->stats->cur_locker->locked_total, &unlock_t); + mp->stats->cur_locker = NULL; + } + + return ((pthread_mutex_unlock((&mp->mutex)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED); +} + + +void +isc_mutex_statsprofile(FILE *fp) { + isc_mutexlocker_t *locker; + int i, j; + + fprintf(fp, "Mutex stats (in us)\n"); + for (i = 0; i < stats_next; i++) { + fprintf(fp, "%-12s %4d: %10u %lu.%06lu %lu.%06lu\n", + stats[i].file, stats[i].line, stats[i].count, + stats[i].locked_total.tv_sec, + stats[i].locked_total.tv_usec, + stats[i].wait_total.tv_sec, + stats[i].wait_total.tv_usec + ); + for (j = 0; j < ISC_MUTEX_MAX_LOCKERS; j++) { + locker = &stats[i].lockers[j]; + if (locker->file == NULL) + continue; + fprintf(fp, " %-11s %4d: %10u %lu.%06lu %lu.%06lu\n", + locker->file, locker->line, locker->count, + locker->locked_total.tv_sec, + locker->locked_total.tv_usec, + locker->wait_total.tv_sec, + locker->wait_total.tv_usec + ); + } + } +} + +#endif /* ISC_MUTEX_PROFILE */ + +#if ISC_MUTEX_DEBUG && defined(PTHREAD_MUTEX_ERRORCHECK) +isc_result_t +isc_mutex_init_errcheck(isc_mutex_t *mp) +{ + pthread_mutexattr_t attr; + int err; + + if (pthread_mutexattr_init(&attr) != 0) + return (ISC_R_UNEXPECTED); + + if (pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_ERRORCHECK) != 0) + return (ISC_R_UNEXPECTED); + + err = pthread_mutex_init(mp, &attr) != 0) + if (err == ENOMEM) + return (ISC_R_NOMEMORY); + return ((err == 0) ? ISC_R_SUCCESS : ISC_R_UNEXPECTED); +} +#endif + +#if ISC_MUTEX_DEBUG && defined(__NetBSD__) && defined(PTHREAD_MUTEX_ERRORCHECK) +pthread_mutexattr_t isc__mutex_attrs = { + PTHREAD_MUTEX_ERRORCHECK, /* m_type */ + 0 /* m_flags, which appears to be unused. */ +}; +#endif + +#if !(ISC_MUTEX_DEBUG && defined(PTHREAD_MUTEX_ERRORCHECK)) && !ISC_MUTEX_PROFILE +isc_result_t +isc__mutex_init(isc_mutex_t *mp, const char *file, unsigned int line) { + char strbuf[ISC_STRERRORSIZE]; + isc_result_t result = ISC_R_SUCCESS; + int err; + + err = pthread_mutex_init(mp, ISC__MUTEX_ATTRS); + if (err == ENOMEM) + return (ISC_R_NOMEMORY); + if (err != 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(file, line, "isc_mutex_init() failed: %s", + strbuf); + result = ISC_R_UNEXPECTED; + } + return (result); +} +#endif diff -urN src/contrib/ntp/lib/isc/pthreads/thread.c src.ntp/contrib/ntp/lib/isc/pthreads/thread.c --- src/contrib/ntp/lib/isc/pthreads/thread.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/pthreads/thread.c 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,76 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: thread.c,v 1.17 2007/06/19 23:47:18 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include + +#ifndef THREAD_MINSTACKSIZE +#define THREAD_MINSTACKSIZE (64U * 1024) +#endif + +isc_result_t +isc_thread_create(isc_threadfunc_t func, isc_threadarg_t arg, + isc_thread_t *thread) +{ + pthread_attr_t attr; + size_t stacksize; + int ret; + + pthread_attr_init(&attr); + +#if defined(HAVE_PTHREAD_ATTR_GETSTACKSIZE) && \ + defined(HAVE_PTHREAD_ATTR_SETSTACKSIZE) + ret = pthread_attr_getstacksize(&attr, &stacksize); + if (ret != 0) + return (ISC_R_UNEXPECTED); + + if (stacksize < THREAD_MINSTACKSIZE) { + ret = pthread_attr_setstacksize(&attr, THREAD_MINSTACKSIZE); + if (ret != 0) + return (ISC_R_UNEXPECTED); + } +#endif + +#if defined(PTHREAD_SCOPE_SYSTEM) && defined(NEED_PTHREAD_SCOPE_SYSTEM) + ret = pthread_attr_setscope(&attr, PTHREAD_SCOPE_SYSTEM); + if (ret != 0) + return (ISC_R_UNEXPECTED); +#endif + + ret = pthread_create(thread, &attr, func, arg); + if (ret != 0) + return (ISC_R_UNEXPECTED); + + pthread_attr_destroy(&attr); + + return (ISC_R_SUCCESS); +} + +void +isc_thread_setconcurrency(unsigned int level) { +#if defined(CALL_PTHREAD_SETCONCURRENCY) + (void)pthread_setconcurrency(level); +#else + UNUSED(level); +#endif +} diff -urN src/contrib/ntp/lib/isc/quota.c src.ntp/contrib/ntp/lib/isc/quota.c --- src/contrib/ntp/lib/isc/quota.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/quota.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,101 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: quota.c,v 1.18 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include + +#include +#include + +isc_result_t +isc_quota_init(isc_quota_t *quota, int max) { + quota->max = max; + quota->used = 0; + quota->soft = 0; + return (isc_mutex_init("a->lock)); +} + +void +isc_quota_destroy(isc_quota_t *quota) { + INSIST(quota->used == 0); + quota->max = 0; + quota->used = 0; + quota->soft = 0; + DESTROYLOCK("a->lock); +} + +void +isc_quota_soft(isc_quota_t *quota, int soft) { + LOCK("a->lock); + quota->soft = soft; + UNLOCK("a->lock); +} + +void +isc_quota_max(isc_quota_t *quota, int max) { + LOCK("a->lock); + quota->max = max; + UNLOCK("a->lock); +} + +isc_result_t +isc_quota_reserve(isc_quota_t *quota) { + isc_result_t result; + LOCK("a->lock); + if (quota->max == 0 || quota->used < quota->max) { + if (quota->soft == 0 || quota->used < quota->soft) + result = ISC_R_SUCCESS; + else + result = ISC_R_SOFTQUOTA; + quota->used++; + } else + result = ISC_R_QUOTA; + UNLOCK("a->lock); + return (result); +} + +void +isc_quota_release(isc_quota_t *quota) { + LOCK("a->lock); + INSIST(quota->used > 0); + quota->used--; + UNLOCK("a->lock); +} + +isc_result_t +isc_quota_attach(isc_quota_t *quota, isc_quota_t **p) +{ + isc_result_t result; + INSIST(p != NULL && *p == NULL); + result = isc_quota_reserve(quota); + if (result == ISC_R_SUCCESS || result == ISC_R_SOFTQUOTA) + *p = quota; + return (result); +} + +void +isc_quota_detach(isc_quota_t **p) +{ + INSIST(p != NULL && *p != NULL); + isc_quota_release(*p); + *p = NULL; +} diff -urN src/contrib/ntp/lib/isc/radix.c src.ntp/contrib/ntp/lib/isc/radix.c --- src/contrib/ntp/lib/isc/radix.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/radix.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,706 @@ +/* + * Copyright (C) 2007-2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: radix.c,v 1.20.36.3 2009/01/18 23:47:41 tbox Exp $ */ + +/* + * This source was adapted from MRT's RCS Ids: + * Id: radix.c,v 1.10.2.1 1999/11/29 05:16:24 masaki Exp + * Id: prefix.c,v 1.37.2.9 2000/03/10 02:53:19 labovit Exp + */ + +#include + +#include +#include +#include +#include + +static isc_result_t +_new_prefix(isc_mem_t *mctx, isc_prefix_t **target, int family, + void *dest, int bitlen); + +static void +_deref_prefix(isc_mem_t *mctx, isc_prefix_t *prefix); + +static isc_result_t +_ref_prefix(isc_mem_t *mctx, isc_prefix_t **target, isc_prefix_t *prefix); + +static int +_comp_with_mask(void *addr, void *dest, u_int mask); + +static void +_clear_radix(isc_radix_tree_t *radix, isc_radix_destroyfunc_t func); + +static isc_result_t +_new_prefix(isc_mem_t *mctx, isc_prefix_t **target, int family, void *dest, + int bitlen) +{ + isc_prefix_t *prefix; + + REQUIRE(target != NULL); + + if (family != AF_INET6 && family != AF_INET && family != AF_UNSPEC) + return (ISC_R_NOTIMPLEMENTED); + + prefix = isc_mem_get(mctx, sizeof(isc_prefix_t)); + if (prefix == NULL) + return (ISC_R_NOMEMORY); + + if (family == AF_INET6) { + prefix->bitlen = (bitlen >= 0) ? bitlen : 128; + memcpy(&prefix->add.sin6, dest, 16); + } else { + /* AF_UNSPEC is "any" or "none"--treat it as AF_INET */ + prefix->bitlen = (bitlen >= 0) ? bitlen : 32; + memcpy(&prefix->add.sin, dest, 4); + } + + prefix->family = family; + + isc_refcount_init(&prefix->refcount, 1); + + *target = prefix; + return (ISC_R_SUCCESS); +} + +static void +_deref_prefix(isc_mem_t *mctx, isc_prefix_t *prefix) { + int refs; + + if (prefix == NULL) + return; + + isc_refcount_decrement(&prefix->refcount, &refs); + + if (refs <= 0) { + isc_refcount_destroy(&prefix->refcount); + isc_mem_put(mctx, prefix, sizeof(isc_prefix_t)); + } +} + +static isc_result_t +_ref_prefix(isc_mem_t *mctx, isc_prefix_t **target, isc_prefix_t *prefix) { + INSIST(prefix != NULL); + INSIST((prefix->family == AF_INET && prefix->bitlen <= 32) || + (prefix->family == AF_INET6 && prefix->bitlen <= 128) || + (prefix->family == AF_UNSPEC && prefix->bitlen == 0)); + REQUIRE(target != NULL && *target == NULL); + + /* + * If this prefix is a static allocation, copy it into new memory. + * (Note, the refcount still has to be destroyed by the calling + * routine.) + */ + if (isc_refcount_current(&prefix->refcount) == 0) { + isc_result_t ret; + ret = _new_prefix(mctx, target, prefix->family, + &prefix->add, prefix->bitlen); + return ret; + } + + isc_refcount_increment(&prefix->refcount, NULL); + + *target = prefix; + return (ISC_R_SUCCESS); +} + +static int +_comp_with_mask(void *addr, void *dest, u_int mask) { + + /* Mask length of zero matches everything */ + if (mask == 0) + return (1); + + if (memcmp(addr, dest, mask / 8) == 0) { + int n = mask / 8; + int m = ((~0) << (8 - (mask % 8))); + + if ((mask % 8) == 0 || + (((u_char *)addr)[n] & m) == (((u_char *)dest)[n] & m)) + return (1); + } + return (0); +} + +isc_result_t +isc_radix_create(isc_mem_t *mctx, isc_radix_tree_t **target, int maxbits) { + isc_radix_tree_t *radix; + + REQUIRE(target != NULL && *target == NULL); + + radix = isc_mem_get(mctx, sizeof(isc_radix_tree_t)); + if (radix == NULL) + return (ISC_R_NOMEMORY); + + radix->mctx = mctx; + radix->maxbits = maxbits; + radix->head = NULL; + radix->num_active_node = 0; + radix->num_added_node = 0; + RUNTIME_CHECK(maxbits <= RADIX_MAXBITS); /* XXX */ + radix->magic = RADIX_TREE_MAGIC; + *target = radix; + return (ISC_R_SUCCESS); +} + +/* + * if func is supplied, it will be called as func(node->data) + * before deleting the node + */ + +static void +_clear_radix(isc_radix_tree_t *radix, isc_radix_destroyfunc_t func) { + + REQUIRE(radix != NULL); + + if (radix->head != NULL) { + + isc_radix_node_t *Xstack[RADIX_MAXBITS+1]; + isc_radix_node_t **Xsp = Xstack; + isc_radix_node_t *Xrn = radix->head; + + while (Xrn != NULL) { + isc_radix_node_t *l = Xrn->l; + isc_radix_node_t *r = Xrn->r; + + if (Xrn->prefix != NULL) { + _deref_prefix(radix->mctx, Xrn->prefix); + if (func != NULL && (Xrn->data[0] != NULL || + Xrn->data[1] != NULL)) + func(Xrn->data); + } else { + INSIST(Xrn->data[0] == NULL && + Xrn->data[1] == NULL); + } + + isc_mem_put(radix->mctx, Xrn, sizeof(*Xrn)); + radix->num_active_node--; + + if (l != NULL) { + if (r != NULL) { + *Xsp++ = r; + } + Xrn = l; + } else if (r != NULL) { + Xrn = r; + } else if (Xsp != Xstack) { + Xrn = *(--Xsp); + } else { + Xrn = NULL; + } + } + } + RUNTIME_CHECK(radix->num_active_node == 0); +} + + +void +isc_radix_destroy(isc_radix_tree_t *radix, isc_radix_destroyfunc_t func) +{ + REQUIRE(radix != NULL); + _clear_radix(radix, func); + isc_mem_put(radix->mctx, radix, sizeof(*radix)); +} + + +/* + * func will be called as func(node->prefix, node->data) + */ +void +isc_radix_process(isc_radix_tree_t *radix, isc_radix_processfunc_t func) +{ + isc_radix_node_t *node; + + REQUIRE(func != NULL); + + RADIX_WALK(radix->head, node) { + func(node->prefix, node->data); + } RADIX_WALK_END; +} + + +isc_result_t +isc_radix_search(isc_radix_tree_t *radix, isc_radix_node_t **target, + isc_prefix_t *prefix) +{ + isc_radix_node_t *node; + isc_radix_node_t *stack[RADIX_MAXBITS + 1]; + u_char *addr; + isc_uint32_t bitlen; + int tfamily = -1; + int cnt = 0; + + REQUIRE(radix != NULL); + REQUIRE(prefix != NULL); + REQUIRE(target != NULL && *target == NULL); + RUNTIME_CHECK(prefix->bitlen <= radix->maxbits); + + *target = NULL; + + if (radix->head == NULL) { + return (ISC_R_NOTFOUND); + } + + node = radix->head; + addr = isc_prefix_touchar(prefix); + bitlen = prefix->bitlen; + + while (node->bit < bitlen) { + if (node->prefix) + stack[cnt++] = node; + + if (BIT_TEST(addr[node->bit >> 3], 0x80 >> (node->bit & 0x07))) + node = node->r; + else + node = node->l; + + if (node == NULL) + break; + } + + if (node && node->prefix) + stack[cnt++] = node; + + while (--cnt >= 0) { + node = stack[cnt]; + + if (_comp_with_mask(isc_prefix_tochar(node->prefix), + isc_prefix_tochar(prefix), + node->prefix->bitlen)) { + if (node->node_num[ISC_IS6(prefix->family)] != -1 && + ((*target == NULL) || + (*target)->node_num[ISC_IS6(tfamily)] > + node->node_num[ISC_IS6(prefix->family)])) { + *target = node; + tfamily = prefix->family; + } + } + } + + if (*target == NULL) { + return (ISC_R_NOTFOUND); + } else { + return (ISC_R_SUCCESS); + } +} + +isc_result_t +isc_radix_insert(isc_radix_tree_t *radix, isc_radix_node_t **target, + isc_radix_node_t *source, isc_prefix_t *prefix) +{ + isc_radix_node_t *node, *new_node, *parent, *glue = NULL; + u_char *addr, *test_addr; + isc_uint32_t bitlen, fam, check_bit, differ_bit; + isc_uint32_t i, j, r; + isc_result_t result; + + REQUIRE(radix != NULL); + REQUIRE(target != NULL && *target == NULL); + REQUIRE(prefix != NULL || (source != NULL && source->prefix != NULL)); + RUNTIME_CHECK(prefix == NULL || prefix->bitlen <= radix->maxbits); + + if (prefix == NULL) + prefix = source->prefix; + + INSIST(prefix != NULL); + + bitlen = prefix->bitlen; + fam = prefix->family; + + if (radix->head == NULL) { + node = isc_mem_get(radix->mctx, sizeof(isc_radix_node_t)); + if (node == NULL) + return (ISC_R_NOMEMORY); + node->bit = bitlen; + node->node_num[0] = node->node_num[1] = -1; + node->prefix = NULL; + result = _ref_prefix(radix->mctx, &node->prefix, prefix); + if (result != ISC_R_SUCCESS) { + isc_mem_put(radix->mctx, node, + sizeof(isc_radix_node_t)); + return (result); + } + node->parent = NULL; + node->l = node->r = NULL; + if (source != NULL) { + /* + * If source is non-NULL, then we're merging in a + * node from an existing radix tree. To keep + * the node_num values consistent, the calling + * function will add the total number of nodes + * added to num_added_node at the end of + * the merge operation--we don't do it here. + */ + if (source->node_num[0] != -1) + node->node_num[0] = radix->num_added_node + + source->node_num[0]; + if (source->node_num[1] != -1) + node->node_num[1] = radix->num_added_node + + source->node_num[1]; + node->data[0] = source->data[0]; + node->data[1] = source->data[1]; + } else { + if (fam == AF_UNSPEC) { + /* "any" or "none" */ + node->node_num[0] = node->node_num[1] = + ++radix->num_added_node; + } else { + node->node_num[ISC_IS6(fam)] = + ++radix->num_added_node; + } + node->data[0] = NULL; + node->data[1] = NULL; + } + radix->head = node; + radix->num_active_node++; + *target = node; + return (ISC_R_SUCCESS); + } + + addr = isc_prefix_touchar(prefix); + node = radix->head; + + while (node->bit < bitlen || node->prefix == NULL) { + if (node->bit < radix->maxbits && + BIT_TEST(addr[node->bit >> 3], 0x80 >> (node->bit & 0x07))) + { + if (node->r == NULL) + break; + node = node->r; + } else { + if (node->l == NULL) + break; + node = node->l; + } + + INSIST(node != NULL); + } + + INSIST(node->prefix != NULL); + + test_addr = isc_prefix_touchar(node->prefix); + /* Find the first bit different. */ + check_bit = (node->bit < bitlen) ? node->bit : bitlen; + differ_bit = 0; + for (i = 0; i*8 < check_bit; i++) { + if ((r = (addr[i] ^ test_addr[i])) == 0) { + differ_bit = (i + 1) * 8; + continue; + } + /* I know the better way, but for now. */ + for (j = 0; j < 8; j++) { + if (BIT_TEST (r, (0x80 >> j))) + break; + } + /* Must be found. */ + INSIST(j < 8); + differ_bit = i * 8 + j; + break; + } + + if (differ_bit > check_bit) + differ_bit = check_bit; + + parent = node->parent; + while (parent != NULL && parent->bit >= differ_bit) { + node = parent; + parent = node->parent; + } + + if (differ_bit == bitlen && node->bit == bitlen) { + if (node->prefix != NULL) { + /* Set node_num only if it hasn't been set before */ + if (source != NULL) { + /* Merging node */ + if (node->node_num[0] == -1 && + source->node_num[0] != -1) { + node->node_num[0] = + radix->num_added_node + + source->node_num[0]; + node->data[0] = source->data[0]; + } + if (node->node_num[1] == -1 && + source->node_num[0] != -1) { + node->node_num[1] = + radix->num_added_node + + source->node_num[1]; + node->data[1] = source->data[1]; + } + } else { + if (fam == AF_UNSPEC) { + /* "any" or "none" */ + int next = radix->num_added_node + 1; + if (node->node_num[0] == -1) { + node->node_num[0] = next; + radix->num_added_node = next; + } + if (node->node_num[1] == -1) { + node->node_num[1] = next; + radix->num_added_node = next; + } + } else { + if (node->node_num[ISC_IS6(fam)] == -1) + node->node_num[ISC_IS6(fam)] + = ++radix->num_added_node; + } + } + *target = node; + return (ISC_R_SUCCESS); + } else { + result = + _ref_prefix(radix->mctx, &node->prefix, prefix); + if (result != ISC_R_SUCCESS) + return (result); + } + INSIST(node->data[0] == NULL && node->node_num[0] == -1 && + node->data[1] == NULL && node->node_num[1] == -1); + if (source != NULL) { + /* Merging node */ + if (source->node_num[0] != -1) { + node->node_num[0] = radix->num_added_node + + source->node_num[0]; + node->data[0] = source->data[0]; + } + if (source->node_num[1] != -1) { + node->node_num[1] = radix->num_added_node + + source->node_num[1]; + node->data[1] = source->data[1]; + } + } else { + if (fam == AF_UNSPEC) { + /* "any" or "none" */ + node->node_num[0] = node->node_num[1] = + ++radix->num_added_node; + } else { + node->node_num[ISC_IS6(fam)] = + ++radix->num_added_node; + } + } + *target = node; + return (ISC_R_SUCCESS); + } + + new_node = isc_mem_get(radix->mctx, sizeof(isc_radix_node_t)); + if (new_node == NULL) + return (ISC_R_NOMEMORY); + if (node->bit != differ_bit && bitlen != differ_bit) { + glue = isc_mem_get(radix->mctx, sizeof(isc_radix_node_t)); + if (glue == NULL) { + isc_mem_put(radix->mctx, new_node, + sizeof(isc_radix_node_t)); + return (ISC_R_NOMEMORY); + } + } + new_node->bit = bitlen; + new_node->prefix = NULL; + result = _ref_prefix(radix->mctx, &new_node->prefix, prefix); + if (result != ISC_R_SUCCESS) { + isc_mem_put(radix->mctx, new_node, sizeof(isc_radix_node_t)); + if (glue != NULL) + isc_mem_put(radix->mctx, glue, + sizeof(isc_radix_node_t)); + return (result); + } + new_node->parent = NULL; + new_node->l = new_node->r = NULL; + new_node->node_num[0] = new_node->node_num[1] = -1; + radix->num_active_node++; + + if (source != NULL) { + /* Merging node */ + if (source->node_num[0] != -1) + new_node->node_num[0] = radix->num_added_node + + source->node_num[0]; + if (source->node_num[1] != -1) + new_node->node_num[1] = radix->num_added_node + + source->node_num[1]; + new_node->data[0] = source->data[0]; + new_node->data[1] = source->data[1]; + } else { + if (fam == AF_UNSPEC) { + /* "any" or "none" */ + new_node->node_num[0] = new_node->node_num[1] = + ++radix->num_added_node; + } else { + new_node->node_num[ISC_IS6(fam)] = + ++radix->num_added_node; + } + new_node->data[0] = NULL; + new_node->data[1] = NULL; + } + + if (node->bit == differ_bit) { + INSIST(glue == NULL); + new_node->parent = node; + if (node->bit < radix->maxbits && + BIT_TEST(addr[node->bit >> 3], 0x80 >> (node->bit & 0x07))) + { + INSIST(node->r == NULL); + node->r = new_node; + } else { + INSIST(node->l == NULL); + node->l = new_node; + } + *target = new_node; + return (ISC_R_SUCCESS); + } + + if (bitlen == differ_bit) { + INSIST(glue == NULL); + if (bitlen < radix->maxbits && + BIT_TEST(test_addr[bitlen >> 3], 0x80 >> (bitlen & 0x07))) { + new_node->r = node; + } else { + new_node->l = node; + } + new_node->parent = node->parent; + if (node->parent == NULL) { + INSIST(radix->head == node); + radix->head = new_node; + } else if (node->parent->r == node) { + node->parent->r = new_node; + } else { + node->parent->l = new_node; + } + node->parent = new_node; + } else { + INSIST(glue != NULL); + glue->bit = differ_bit; + glue->prefix = NULL; + glue->parent = node->parent; + glue->data[0] = glue->data[1] = NULL; + glue->node_num[0] = glue->node_num[1] = -1; + radix->num_active_node++; + if (differ_bit < radix->maxbits && + BIT_TEST(addr[differ_bit>>3], 0x80 >> (differ_bit & 07))) { + glue->r = new_node; + glue->l = node; + } else { + glue->r = node; + glue->l = new_node; + } + new_node->parent = glue; + + if (node->parent == NULL) { + INSIST(radix->head == node); + radix->head = glue; + } else if (node->parent->r == node) { + node->parent->r = glue; + } else { + node->parent->l = glue; + } + node->parent = glue; + } + + *target = new_node; + return (ISC_R_SUCCESS); +} + +void +isc_radix_remove(isc_radix_tree_t *radix, isc_radix_node_t *node) { + isc_radix_node_t *parent, *child; + + REQUIRE(radix != NULL); + REQUIRE(node != NULL); + + if (node->r && node->l) { + /* + * This might be a placeholder node -- have to check and + * make sure there is a prefix associated with it! + */ + if (node->prefix != NULL) + _deref_prefix(radix->mctx, node->prefix); + + node->prefix = NULL; + node->data[0] = node->data[1] = NULL; + return; + } + + if (node->r == NULL && node->l == NULL) { + parent = node->parent; + _deref_prefix(radix->mctx, node->prefix); + isc_mem_put(radix->mctx, node, sizeof(*node)); + radix->num_active_node--; + + if (parent == NULL) { + INSIST(radix->head == node); + radix->head = NULL; + return; + } + + if (parent->r == node) { + parent->r = NULL; + child = parent->l; + } else { + INSIST(parent->l == node); + parent->l = NULL; + child = parent->r; + } + + if (parent->prefix) + return; + + /* We need to remove parent too. */ + + if (parent->parent == NULL) { + INSIST(radix->head == parent); + radix->head = child; + } else if (parent->parent->r == parent) { + parent->parent->r = child; + } else { + INSIST(parent->parent->l == parent); + parent->parent->l = child; + } + child->parent = parent->parent; + isc_mem_put(radix->mctx, parent, sizeof(*parent)); + radix->num_active_node--; + return; + } + + if (node->r) { + child = node->r; + } else { + INSIST(node->l != NULL); + child = node->l; + } + parent = node->parent; + child->parent = parent; + + _deref_prefix(radix->mctx, node->prefix); + isc_mem_put(radix->mctx, node, sizeof(*node)); + radix->num_active_node--; + + if (parent == NULL) { + INSIST(radix->head == node); + radix->head = child; + return; + } + + if (parent->r == node) { + parent->r = child; + } else { + INSIST(parent->l == node); + parent->l = child; + } +} + +/* +Local Variables: +c-basic-offset: 4 +indent-tabs-mode: t +End: +*/ diff -urN src/contrib/ntp/lib/isc/random.c src.ntp/contrib/ntp/lib/isc/random.c --- src/contrib/ntp/lib/isc/random.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/random.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,104 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: random.c,v 1.25 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include /* Required for time(). */ +#ifdef HAVE_SYS_TYPES_H +#include +#endif +#ifdef HAVE_UNISTD_H +#include +#endif + +#include +#include +#include +#include +#include + +static isc_once_t once = ISC_ONCE_INIT; + +static void +initialize_rand(void) +{ +#ifndef HAVE_ARC4RANDOM + unsigned int pid = getpid(); + + /* + * The low bits of pid generally change faster. + * Xor them with the high bits of time which change slowly. + */ + pid = ((pid << 16) & 0xffff0000) | ((pid >> 16) & 0xffff); + + srand(time(NULL) ^ pid); +#endif +} + +static void +initialize(void) +{ + RUNTIME_CHECK(isc_once_do(&once, initialize_rand) == ISC_R_SUCCESS); +} + +void +isc_random_seed(isc_uint32_t seed) +{ + initialize(); + +#ifndef HAVE_ARC4RANDOM + srand(seed); +#else + arc4random_addrandom((u_char *) &seed, sizeof(isc_uint32_t)); +#endif +} + +void +isc_random_get(isc_uint32_t *val) +{ + REQUIRE(val != NULL); + + initialize(); + +#ifndef HAVE_ARC4RANDOM + /* + * rand()'s lower bits are not random. + * rand()'s upper bit is zero. + */ + *val = ((rand() >> 4) & 0xffff) | ((rand() << 12) & 0xffff0000); +#else + *val = arc4random(); +#endif +} + +isc_uint32_t +isc_random_jitter(isc_uint32_t max, isc_uint32_t jitter) { + REQUIRE(jitter < max); + if (jitter == 0) + return (max); + else +#ifndef HAVE_ARC4RANDOM + return (max - rand() % jitter); +#else + return (max - arc4random() % jitter); +#endif +} diff -urN src/contrib/ntp/lib/isc/ratelimiter.c src.ntp/contrib/ntp/lib/isc/ratelimiter.c --- src/contrib/ntp/lib/isc/ratelimiter.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/ratelimiter.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,328 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: ratelimiter.c,v 1.25 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include +#include +#include +#include + +typedef enum { + isc_ratelimiter_stalled = 0, + isc_ratelimiter_ratelimited = 1, + isc_ratelimiter_idle = 2, + isc_ratelimiter_shuttingdown = 3 +} isc_ratelimiter_state_t; + +struct isc_ratelimiter { + isc_mem_t * mctx; + isc_mutex_t lock; + int refs; + isc_task_t * task; + isc_timer_t * timer; + isc_interval_t interval; + isc_uint32_t pertic; + isc_ratelimiter_state_t state; + isc_event_t shutdownevent; + ISC_LIST(isc_event_t) pending; +}; + +#define ISC_RATELIMITEREVENT_SHUTDOWN (ISC_EVENTCLASS_RATELIMITER + 1) + +static void +ratelimiter_tick(isc_task_t *task, isc_event_t *event); + +static void +ratelimiter_shutdowncomplete(isc_task_t *task, isc_event_t *event); + +isc_result_t +isc_ratelimiter_create(isc_mem_t *mctx, isc_timermgr_t *timermgr, + isc_task_t *task, isc_ratelimiter_t **ratelimiterp) +{ + isc_result_t result; + isc_ratelimiter_t *rl; + INSIST(ratelimiterp != NULL && *ratelimiterp == NULL); + + rl = isc_mem_get(mctx, sizeof(*rl)); + if (rl == NULL) + return ISC_R_NOMEMORY; + rl->mctx = mctx; + rl->refs = 1; + rl->task = task; + isc_interval_set(&rl->interval, 0, 0); + rl->timer = NULL; + rl->pertic = 1; + rl->state = isc_ratelimiter_idle; + ISC_LIST_INIT(rl->pending); + + result = isc_mutex_init(&rl->lock); + if (result != ISC_R_SUCCESS) + goto free_mem; + result = isc_timer_create(timermgr, isc_timertype_inactive, + NULL, NULL, rl->task, ratelimiter_tick, + rl, &rl->timer); + if (result != ISC_R_SUCCESS) + goto free_mutex; + + /* + * Increment the reference count to indicate that we may + * (soon) have events outstanding. + */ + rl->refs++; + + ISC_EVENT_INIT(&rl->shutdownevent, + sizeof(isc_event_t), + 0, NULL, ISC_RATELIMITEREVENT_SHUTDOWN, + ratelimiter_shutdowncomplete, rl, rl, NULL, NULL); + + *ratelimiterp = rl; + return (ISC_R_SUCCESS); + +free_mutex: + DESTROYLOCK(&rl->lock); +free_mem: + isc_mem_put(mctx, rl, sizeof(*rl)); + return (result); +} + +isc_result_t +isc_ratelimiter_setinterval(isc_ratelimiter_t *rl, isc_interval_t *interval) { + isc_result_t result = ISC_R_SUCCESS; + LOCK(&rl->lock); + rl->interval = *interval; + /* + * If the timer is currently running, change its rate. + */ + if (rl->state == isc_ratelimiter_ratelimited) { + result = isc_timer_reset(rl->timer, isc_timertype_ticker, NULL, + &rl->interval, ISC_FALSE); + } + UNLOCK(&rl->lock); + return (result); +} + +void +isc_ratelimiter_setpertic(isc_ratelimiter_t *rl, isc_uint32_t pertic) { + if (pertic == 0) + pertic = 1; + rl->pertic = pertic; +} + +isc_result_t +isc_ratelimiter_enqueue(isc_ratelimiter_t *rl, isc_task_t *task, + isc_event_t **eventp) +{ + isc_result_t result = ISC_R_SUCCESS; + isc_event_t *ev; + + REQUIRE(eventp != NULL && *eventp != NULL); + REQUIRE(task != NULL); + ev = *eventp; + REQUIRE(ev->ev_sender == NULL); + + LOCK(&rl->lock); + if (rl->state == isc_ratelimiter_ratelimited || + rl->state == isc_ratelimiter_stalled) { + isc_event_t *ev = *eventp; + ev->ev_sender = task; + ISC_LIST_APPEND(rl->pending, ev, ev_link); + *eventp = NULL; + } else if (rl->state == isc_ratelimiter_idle) { + result = isc_timer_reset(rl->timer, isc_timertype_ticker, NULL, + &rl->interval, ISC_FALSE); + if (result == ISC_R_SUCCESS) { + ev->ev_sender = task; + rl->state = isc_ratelimiter_ratelimited; + } + } else { + INSIST(rl->state == isc_ratelimiter_shuttingdown); + result = ISC_R_SHUTTINGDOWN; + } + UNLOCK(&rl->lock); + if (*eventp != NULL && result == ISC_R_SUCCESS) + isc_task_send(task, eventp); + return (result); +} + +static void +ratelimiter_tick(isc_task_t *task, isc_event_t *event) { + isc_result_t result = ISC_R_SUCCESS; + isc_ratelimiter_t *rl = (isc_ratelimiter_t *)event->ev_arg; + isc_event_t *p; + isc_uint32_t pertic; + + UNUSED(task); + + isc_event_free(&event); + + pertic = rl->pertic; + while (pertic != 0) { + pertic--; + LOCK(&rl->lock); + p = ISC_LIST_HEAD(rl->pending); + if (p != NULL) { + /* + * There is work to do. Let's do it after unlocking. + */ + ISC_LIST_UNLINK(rl->pending, p, ev_link); + } else { + /* + * No work left to do. Stop the timer so that we don't + * waste resources by having it fire periodically. + */ + result = isc_timer_reset(rl->timer, + isc_timertype_inactive, + NULL, NULL, ISC_FALSE); + RUNTIME_CHECK(result == ISC_R_SUCCESS); + rl->state = isc_ratelimiter_idle; + pertic = 0; /* Force the loop to exit. */ + } + UNLOCK(&rl->lock); + if (p != NULL) { + isc_task_t *evtask = p->ev_sender; + isc_task_send(evtask, &p); + } + INSIST(p == NULL); + } +} + +void +isc_ratelimiter_shutdown(isc_ratelimiter_t *rl) { + isc_event_t *ev; + isc_task_t *task; + LOCK(&rl->lock); + rl->state = isc_ratelimiter_shuttingdown; + (void)isc_timer_reset(rl->timer, isc_timertype_inactive, + NULL, NULL, ISC_FALSE); + while ((ev = ISC_LIST_HEAD(rl->pending)) != NULL) { + ISC_LIST_UNLINK(rl->pending, ev, ev_link); + ev->ev_attributes |= ISC_EVENTATTR_CANCELED; + task = ev->ev_sender; + isc_task_send(task, &ev); + } + isc_timer_detach(&rl->timer); + /* + * Send an event to our task. The delivery of this event + * indicates that no more timer events will be delivered. + */ + ev = &rl->shutdownevent; + isc_task_send(rl->task, &ev); + + UNLOCK(&rl->lock); +} + +static void +ratelimiter_shutdowncomplete(isc_task_t *task, isc_event_t *event) { + isc_ratelimiter_t *rl = (isc_ratelimiter_t *)event->ev_arg; + + UNUSED(task); + + isc_ratelimiter_detach(&rl); +} + +static void +ratelimiter_free(isc_ratelimiter_t *rl) { + DESTROYLOCK(&rl->lock); + isc_mem_put(rl->mctx, rl, sizeof(*rl)); +} + +void +isc_ratelimiter_attach(isc_ratelimiter_t *source, isc_ratelimiter_t **target) { + REQUIRE(source != NULL); + REQUIRE(target != NULL && *target == NULL); + + LOCK(&source->lock); + REQUIRE(source->refs > 0); + source->refs++; + INSIST(source->refs > 0); + UNLOCK(&source->lock); + *target = source; +} + +void +isc_ratelimiter_detach(isc_ratelimiter_t **rlp) { + isc_ratelimiter_t *rl = *rlp; + isc_boolean_t free_now = ISC_FALSE; + + LOCK(&rl->lock); + REQUIRE(rl->refs > 0); + rl->refs--; + if (rl->refs == 0) + free_now = ISC_TRUE; + UNLOCK(&rl->lock); + + if (free_now) + ratelimiter_free(rl); + + *rlp = NULL; +} + +isc_result_t +isc_ratelimiter_stall(isc_ratelimiter_t *rl) { + isc_result_t result = ISC_R_SUCCESS; + + LOCK(&rl->lock); + switch (rl->state) { + case isc_ratelimiter_shuttingdown: + result = ISC_R_SHUTTINGDOWN; + break; + case isc_ratelimiter_ratelimited: + result = isc_timer_reset(rl->timer, isc_timertype_inactive, + NULL, NULL, ISC_FALSE); + RUNTIME_CHECK(result == ISC_R_SUCCESS); + case isc_ratelimiter_idle: + case isc_ratelimiter_stalled: + rl->state = isc_ratelimiter_stalled; + break; + } + UNLOCK(&rl->lock); + return (result); +} + +isc_result_t +isc_ratelimiter_release(isc_ratelimiter_t *rl) { + isc_result_t result = ISC_R_SUCCESS; + + LOCK(&rl->lock); + switch (rl->state) { + case isc_ratelimiter_shuttingdown: + result = ISC_R_SHUTTINGDOWN; + break; + case isc_ratelimiter_stalled: + if (!ISC_LIST_EMPTY(rl->pending)) { + result = isc_timer_reset(rl->timer, + isc_timertype_ticker, NULL, + &rl->interval, ISC_FALSE); + if (result == ISC_R_SUCCESS) + rl->state = isc_ratelimiter_ratelimited; + } else + rl->state = isc_ratelimiter_idle; + break; + case isc_ratelimiter_ratelimited: + case isc_ratelimiter_idle: + break; + } + UNLOCK(&rl->lock); + return (result); +} diff -urN src/contrib/ntp/lib/isc/refcount.c src.ntp/contrib/ntp/lib/isc/refcount.c --- src/contrib/ntp/lib/isc/refcount.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/refcount.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,37 @@ +/* + * Copyright (C) 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: refcount.c,v 1.5 2007/06/19 23:47:17 tbox Exp $ */ + +#include + +#include + +#include +#include +#include + +isc_result_t +isc_refcount_init(isc_refcount_t *ref, unsigned int n) { + REQUIRE(ref != NULL); + + ref->refs = n; +#if defined(ISC_PLATFORM_USETHREADS) && !defined(ISC_PLATFORM_HAVEXADD) + return (isc_mutex_init(&ref->lock)); +#else + return (ISC_R_SUCCESS); +#endif +} diff -urN src/contrib/ntp/lib/isc/region.c src.ntp/contrib/ntp/lib/isc/region.c --- src/contrib/ntp/lib/isc/region.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/region.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,45 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: region.c,v 1.7 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include + +#include +#include + +int +isc_region_compare(isc_region_t *r1, isc_region_t *r2) { + unsigned int l; + int result; + + REQUIRE(r1 != NULL); + REQUIRE(r2 != NULL); + + l = (r1->length < r2->length) ? r1->length : r2->length; + + if ((result = memcmp(r1->base, r2->base, l)) != 0) + return ((result < 0) ? -1 : 1); + else + return ((r1->length == r2->length) ? 0 : + (r1->length < r2->length) ? -1 : 1); +} diff -urN src/contrib/ntp/lib/isc/result.c src.ntp/contrib/ntp/lib/isc/result.c --- src/contrib/ntp/lib/isc/result.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/result.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,213 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: result.c,v 1.71 2008/09/25 04:02:39 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include + +#include +#include +#include +#include +#include +#include + +typedef struct resulttable { + unsigned int base; + unsigned int last; + const char ** text; + isc_msgcat_t * msgcat; + int set; + ISC_LINK(struct resulttable) link; +} resulttable; + +static const char *text[ISC_R_NRESULTS] = { + "success", /*%< 0 */ + "out of memory", /*%< 1 */ + "timed out", /*%< 2 */ + "no available threads", /*%< 3 */ + "address not available", /*%< 4 */ + "address in use", /*%< 5 */ + "permission denied", /*%< 6 */ + "no pending connections", /*%< 7 */ + "network unreachable", /*%< 8 */ + "host unreachable", /*%< 9 */ + "network down", /*%< 10 */ + "host down", /*%< 11 */ + "connection refused", /*%< 12 */ + "not enough free resources", /*%< 13 */ + "end of file", /*%< 14 */ + "socket already bound", /*%< 15 */ + "reload", /*%< 16 */ + "lock busy", /*%< 17 */ + "already exists", /*%< 18 */ + "ran out of space", /*%< 19 */ + "operation canceled", /*%< 20 */ + "socket is not bound", /*%< 21 */ + "shutting down", /*%< 22 */ + "not found", /*%< 23 */ + "unexpected end of input", /*%< 24 */ + "failure", /*%< 25 */ + "I/O error", /*%< 26 */ + "not implemented", /*%< 27 */ + "unbalanced parentheses", /*%< 28 */ + "no more", /*%< 29 */ + "invalid file", /*%< 30 */ + "bad base64 encoding", /*%< 31 */ + "unexpected token", /*%< 32 */ + "quota reached", /*%< 33 */ + "unexpected error", /*%< 34 */ + "already running", /*%< 35 */ + "ignore", /*%< 36 */ + "address mask not contiguous", /*%< 37 */ + "file not found", /*%< 38 */ + "file already exists", /*%< 39 */ + "socket is not connected", /*%< 40 */ + "out of range", /*%< 41 */ + "out of entropy", /*%< 42 */ + "invalid use of multicast address", /*%< 43 */ + "not a file", /*%< 44 */ + "not a directory", /*%< 45 */ + "queue is full", /*%< 46 */ + "address family mismatch", /*%< 47 */ + "address family not supported", /*%< 48 */ + "bad hex encoding", /*%< 49 */ + "too many open files", /*%< 50 */ + "not blocking", /*%< 51 */ + "unbalanced quotes", /*%< 52 */ + "operation in progress", /*%< 53 */ + "connection reset", /*%< 54 */ + "soft quota reached", /*%< 55 */ + "not a valid number", /*%< 56 */ + "disabled", /*%< 57 */ + "max size", /*%< 58 */ + "invalid address format", /*%< 59 */ + "bad base32 encoding", /*%< 60 */ +}; + +#define ISC_RESULT_RESULTSET 2 +#define ISC_RESULT_UNAVAILABLESET 3 + +static isc_once_t once = ISC_ONCE_INIT; +static ISC_LIST(resulttable) tables; +static isc_mutex_t lock; + +static isc_result_t +register_table(unsigned int base, unsigned int nresults, const char **text, + isc_msgcat_t *msgcat, int set) +{ + resulttable *table; + + REQUIRE(base % ISC_RESULTCLASS_SIZE == 0); + REQUIRE(nresults <= ISC_RESULTCLASS_SIZE); + REQUIRE(text != NULL); + + /* + * We use malloc() here because we we want to be able to use + * isc_result_totext() even if there is no memory context. + */ + table = malloc(sizeof(*table)); + if (table == NULL) + return (ISC_R_NOMEMORY); + table->base = base; + table->last = base + nresults - 1; + table->text = text; + table->msgcat = msgcat; + table->set = set; + ISC_LINK_INIT(table, link); + + LOCK(&lock); + + ISC_LIST_APPEND(tables, table, link); + + UNLOCK(&lock); + + return (ISC_R_SUCCESS); +} + +static void +initialize_action(void) { + isc_result_t result; + + RUNTIME_CHECK(isc_mutex_init(&lock) == ISC_R_SUCCESS); + ISC_LIST_INIT(tables); + + result = register_table(ISC_RESULTCLASS_ISC, ISC_R_NRESULTS, text, + isc_msgcat, ISC_RESULT_RESULTSET); + if (result != ISC_R_SUCCESS) + UNEXPECTED_ERROR(__FILE__, __LINE__, + "register_table() %s: %u", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed"), + result); +} + +static void +initialize(void) { + isc_lib_initmsgcat(); + RUNTIME_CHECK(isc_once_do(&once, initialize_action) == ISC_R_SUCCESS); +} + +const char * +isc_result_totext(isc_result_t result) { + resulttable *table; + const char *text, *default_text; + int index; + + initialize(); + + LOCK(&lock); + + text = NULL; + for (table = ISC_LIST_HEAD(tables); + table != NULL; + table = ISC_LIST_NEXT(table, link)) { + if (result >= table->base && result <= table->last) { + index = (int)(result - table->base); + default_text = table->text[index]; + /* + * Note: we use 'index + 1' as the message number + * instead of index because isc_msgcat_get() requires + * the message number to be > 0. + */ + text = isc_msgcat_get(table->msgcat, table->set, + index + 1, default_text); + break; + } + } + if (text == NULL) + text = isc_msgcat_get(isc_msgcat, ISC_RESULT_UNAVAILABLESET, + 1, "(result code text not available)"); + + UNLOCK(&lock); + + return (text); +} + +isc_result_t +isc_result_register(unsigned int base, unsigned int nresults, + const char **text, isc_msgcat_t *msgcat, int set) +{ + initialize(); + + return (register_table(base, nresults, text, msgcat, set)); +} diff -urN src/contrib/ntp/lib/isc/rwlock.c src.ntp/contrib/ntp/lib/isc/rwlock.c --- src/contrib/ntp/lib/isc/rwlock.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/rwlock.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,808 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: rwlock.c,v 1.44.332.2 2009/01/18 23:47:41 tbox Exp $ */ + +/*! \file */ + +#include + +#include + +#include +#include +#include +#include +#include +#include + +#define RWLOCK_MAGIC ISC_MAGIC('R', 'W', 'L', 'k') +#define VALID_RWLOCK(rwl) ISC_MAGIC_VALID(rwl, RWLOCK_MAGIC) + +#ifdef ISC_PLATFORM_USETHREADS + +#ifndef RWLOCK_DEFAULT_READ_QUOTA +#define RWLOCK_DEFAULT_READ_QUOTA 4 +#endif + +#ifndef RWLOCK_DEFAULT_WRITE_QUOTA +#define RWLOCK_DEFAULT_WRITE_QUOTA 4 +#endif + +#ifdef ISC_RWLOCK_TRACE +#include /* Required for fprintf/stderr. */ +#include /* Required for isc_thread_self(). */ + +static void +print_lock(const char *operation, isc_rwlock_t *rwl, isc_rwlocktype_t type) { + fprintf(stderr, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_PRINTLOCK, + "rwlock %p thread %lu %s(%s): %s, %u active, " + "%u granted, %u rwaiting, %u wwaiting\n"), + rwl, isc_thread_self(), operation, + (type == isc_rwlocktype_read ? + isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_READ, "read") : + isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_WRITE, "write")), + (rwl->type == isc_rwlocktype_read ? + isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_READING, "reading") : + isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_WRITING, "writing")), + rwl->active, rwl->granted, rwl->readers_waiting, + rwl->writers_waiting); +} +#endif + +isc_result_t +isc_rwlock_init(isc_rwlock_t *rwl, unsigned int read_quota, + unsigned int write_quota) +{ + isc_result_t result; + + REQUIRE(rwl != NULL); + + /* + * In case there's trouble initializing, we zero magic now. If all + * goes well, we'll set it to RWLOCK_MAGIC. + */ + rwl->magic = 0; + +#if defined(ISC_PLATFORM_HAVEXADD) && defined(ISC_PLATFORM_HAVECMPXCHG) + rwl->write_requests = 0; + rwl->write_completions = 0; + rwl->cnt_and_flag = 0; + rwl->readers_waiting = 0; + rwl->write_granted = 0; + if (read_quota != 0) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "read quota is not supported"); + } + if (write_quota == 0) + write_quota = RWLOCK_DEFAULT_WRITE_QUOTA; + rwl->write_quota = write_quota; +#else + rwl->type = isc_rwlocktype_read; + rwl->original = isc_rwlocktype_none; + rwl->active = 0; + rwl->granted = 0; + rwl->readers_waiting = 0; + rwl->writers_waiting = 0; + if (read_quota == 0) + read_quota = RWLOCK_DEFAULT_READ_QUOTA; + rwl->read_quota = read_quota; + if (write_quota == 0) + write_quota = RWLOCK_DEFAULT_WRITE_QUOTA; + rwl->write_quota = write_quota; +#endif + + result = isc_mutex_init(&rwl->lock); + if (result != ISC_R_SUCCESS) + return (result); + + result = isc_condition_init(&rwl->readable); + if (result != ISC_R_SUCCESS) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_condition_init(readable) %s: %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed"), + isc_result_totext(result)); + result = ISC_R_UNEXPECTED; + goto destroy_lock; + } + result = isc_condition_init(&rwl->writeable); + if (result != ISC_R_SUCCESS) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_condition_init(writeable) %s: %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed"), + isc_result_totext(result)); + result = ISC_R_UNEXPECTED; + goto destroy_rcond; + } + + rwl->magic = RWLOCK_MAGIC; + + return (ISC_R_SUCCESS); + + destroy_rcond: + (void)isc_condition_destroy(&rwl->readable); + destroy_lock: + DESTROYLOCK(&rwl->lock); + + return (result); +} + +void +isc_rwlock_destroy(isc_rwlock_t *rwl) { + REQUIRE(VALID_RWLOCK(rwl)); + +#if defined(ISC_PLATFORM_HAVEXADD) && defined(ISC_PLATFORM_HAVECMPXCHG) + REQUIRE(rwl->write_requests == rwl->write_completions && + rwl->cnt_and_flag == 0 && rwl->readers_waiting == 0); +#else + LOCK(&rwl->lock); + REQUIRE(rwl->active == 0 && + rwl->readers_waiting == 0 && + rwl->writers_waiting == 0); + UNLOCK(&rwl->lock); +#endif + + rwl->magic = 0; + (void)isc_condition_destroy(&rwl->readable); + (void)isc_condition_destroy(&rwl->writeable); + DESTROYLOCK(&rwl->lock); +} + +#if defined(ISC_PLATFORM_HAVEXADD) && defined(ISC_PLATFORM_HAVECMPXCHG) + +/* + * When some architecture-dependent atomic operations are available, + * rwlock can be more efficient than the generic algorithm defined below. + * The basic algorithm is described in the following URL: + * http://www.cs.rochester.edu/u/scott/synchronization/pseudocode/rw.html + * + * The key is to use the following integer variables modified atomically: + * write_requests, write_completions, and cnt_and_flag. + * + * write_requests and write_completions act as a waiting queue for writers + * in order to ensure the FIFO order. Both variables begin with the initial + * value of 0. When a new writer tries to get a write lock, it increments + * write_requests and gets the previous value of the variable as a "ticket". + * When write_completions reaches the ticket number, the new writer can start + * writing. When the writer completes its work, it increments + * write_completions so that another new writer can start working. If the + * write_requests is not equal to write_completions, it means a writer is now + * working or waiting. In this case, a new readers cannot start reading, or + * in other words, this algorithm basically prefers writers. + * + * cnt_and_flag is a "lock" shared by all readers and writers. This integer + * variable is a kind of structure with two members: writer_flag (1 bit) and + * reader_count (31 bits). The writer_flag shows whether a writer is working, + * and the reader_count shows the number of readers currently working or almost + * ready for working. A writer who has the current "ticket" tries to get the + * lock by exclusively setting the writer_flag to 1, provided that the whole + * 32-bit is 0 (meaning no readers or writers working). On the other hand, + * a new reader tries to increment the "reader_count" field provided that + * the writer_flag is 0 (meaning there is no writer working). + * + * If some of the above operations fail, the reader or the writer sleeps + * until the related condition changes. When a working reader or writer + * completes its work, some readers or writers are sleeping, and the condition + * that suspended the reader or writer has changed, it wakes up the sleeping + * readers or writers. + * + * As already noted, this algorithm basically prefers writers. In order to + * prevent readers from starving, however, the algorithm also introduces the + * "writer quota" (Q). When Q consecutive writers have completed their work, + * suspending readers, the last writer will wake up the readers, even if a new + * writer is waiting. + * + * Implementation specific note: due to the combination of atomic operations + * and a mutex lock, ordering between the atomic operation and locks can be + * very sensitive in some cases. In particular, it is generally very important + * to check the atomic variable that requires a reader or writer to sleep after + * locking the mutex and before actually sleeping; otherwise, it could be very + * likely to cause a deadlock. For example, assume "var" is a variable + * atomically modified, then the corresponding code would be: + * if (var == need_sleep) { + * LOCK(lock); + * if (var == need_sleep) + * WAIT(cond, lock); + * UNLOCK(lock); + * } + * The second check is important, since "var" is protected by the atomic + * operation, not by the mutex, and can be changed just before sleeping. + * (The first "if" could be omitted, but this is also important in order to + * make the code efficient by avoiding the use of the mutex unless it is + * really necessary.) + */ + +#define WRITER_ACTIVE 0x1 +#define READER_INCR 0x2 + +isc_result_t +isc_rwlock_lock(isc_rwlock_t *rwl, isc_rwlocktype_t type) { + isc_int32_t cntflag; + + REQUIRE(VALID_RWLOCK(rwl)); + +#ifdef ISC_RWLOCK_TRACE + print_lock(isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_PRELOCK, "prelock"), rwl, type); +#endif + + if (type == isc_rwlocktype_read) { + if (rwl->write_requests != rwl->write_completions) { + /* there is a waiting or active writer */ + LOCK(&rwl->lock); + if (rwl->write_requests != rwl->write_completions) { + rwl->readers_waiting++; + WAIT(&rwl->readable, &rwl->lock); + rwl->readers_waiting--; + } + UNLOCK(&rwl->lock); + } + + cntflag = isc_atomic_xadd(&rwl->cnt_and_flag, READER_INCR); + while (1) { + if ((rwl->cnt_and_flag & WRITER_ACTIVE) == 0) + break; + + /* A writer is still working */ + LOCK(&rwl->lock); + rwl->readers_waiting++; + if ((rwl->cnt_and_flag & WRITER_ACTIVE) != 0) + WAIT(&rwl->readable, &rwl->lock); + rwl->readers_waiting--; + UNLOCK(&rwl->lock); + + /* + * Typically, the reader should be able to get a lock + * at this stage: + * (1) there should have been no pending writer when + * the reader was trying to increment the + * counter; otherwise, the writer should be in + * the waiting queue, preventing the reader from + * proceeding to this point. + * (2) once the reader increments the counter, no + * more writer can get a lock. + * Still, it is possible another writer can work at + * this point, e.g. in the following scenario: + * A previous writer unlocks the writer lock. + * This reader proceeds to point (1). + * A new writer appears, and gets a new lock before + * the reader increments the counter. + * The reader then increments the counter. + * The previous writer notices there is a waiting + * reader who is almost ready, and wakes it up. + * So, the reader needs to confirm whether it can now + * read explicitly (thus we loop). Note that this is + * not an infinite process, since the reader has + * incremented the counter at this point. + */ + } + + /* + * If we are temporarily preferred to writers due to the writer + * quota, reset the condition (race among readers doesn't + * matter). + */ + rwl->write_granted = 0; + } else { + isc_int32_t prev_writer; + + /* enter the waiting queue, and wait for our turn */ + prev_writer = isc_atomic_xadd(&rwl->write_requests, 1); + while (rwl->write_completions != prev_writer) { + LOCK(&rwl->lock); + if (rwl->write_completions != prev_writer) { + WAIT(&rwl->writeable, &rwl->lock); + UNLOCK(&rwl->lock); + continue; + } + UNLOCK(&rwl->lock); + break; + } + + while (1) { + cntflag = isc_atomic_cmpxchg(&rwl->cnt_and_flag, 0, + WRITER_ACTIVE); + if (cntflag == 0) + break; + + /* Another active reader or writer is working. */ + LOCK(&rwl->lock); + if (rwl->cnt_and_flag != 0) + WAIT(&rwl->writeable, &rwl->lock); + UNLOCK(&rwl->lock); + } + + INSIST((rwl->cnt_and_flag & WRITER_ACTIVE) != 0); + rwl->write_granted++; + } + +#ifdef ISC_RWLOCK_TRACE + print_lock(isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_POSTLOCK, "postlock"), rwl, type); +#endif + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_rwlock_trylock(isc_rwlock_t *rwl, isc_rwlocktype_t type) { + isc_int32_t cntflag; + + REQUIRE(VALID_RWLOCK(rwl)); + +#ifdef ISC_RWLOCK_TRACE + print_lock(isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_PRELOCK, "prelock"), rwl, type); +#endif + + if (type == isc_rwlocktype_read) { + /* If a writer is waiting or working, we fail. */ + if (rwl->write_requests != rwl->write_completions) + return (ISC_R_LOCKBUSY); + + /* Otherwise, be ready for reading. */ + cntflag = isc_atomic_xadd(&rwl->cnt_and_flag, READER_INCR); + if ((cntflag & WRITER_ACTIVE) != 0) { + /* + * A writer is working. We lose, and cancel the read + * request. + */ + cntflag = isc_atomic_xadd(&rwl->cnt_and_flag, + -READER_INCR); + /* + * If no other readers are waiting and we've suspended + * new writers in this short period, wake them up. + */ + if (cntflag == READER_INCR && + rwl->write_completions != rwl->write_requests) { + LOCK(&rwl->lock); + BROADCAST(&rwl->writeable); + UNLOCK(&rwl->lock); + } + + return (ISC_R_LOCKBUSY); + } + } else { + /* Try locking without entering the waiting queue. */ + cntflag = isc_atomic_cmpxchg(&rwl->cnt_and_flag, 0, + WRITER_ACTIVE); + if (cntflag != 0) + return (ISC_R_LOCKBUSY); + + /* + * XXXJT: jump into the queue, possibly breaking the writer + * order. + */ + (void)isc_atomic_xadd(&rwl->write_completions, -1); + + rwl->write_granted++; + } + +#ifdef ISC_RWLOCK_TRACE + print_lock(isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_POSTLOCK, "postlock"), rwl, type); +#endif + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_rwlock_tryupgrade(isc_rwlock_t *rwl) { + isc_int32_t prevcnt; + + REQUIRE(VALID_RWLOCK(rwl)); + + /* Try to acquire write access. */ + prevcnt = isc_atomic_cmpxchg(&rwl->cnt_and_flag, + READER_INCR, WRITER_ACTIVE); + /* + * There must have been no writer, and there must have been at least + * one reader. + */ + INSIST((prevcnt & WRITER_ACTIVE) == 0 && + (prevcnt & ~WRITER_ACTIVE) != 0); + + if (prevcnt == READER_INCR) { + /* + * We are the only reader and have been upgraded. + * Now jump into the head of the writer waiting queue. + */ + (void)isc_atomic_xadd(&rwl->write_completions, -1); + } else + return (ISC_R_LOCKBUSY); + + return (ISC_R_SUCCESS); + +} + +void +isc_rwlock_downgrade(isc_rwlock_t *rwl) { + isc_int32_t prev_readers; + + REQUIRE(VALID_RWLOCK(rwl)); + + /* Become an active reader. */ + prev_readers = isc_atomic_xadd(&rwl->cnt_and_flag, READER_INCR); + /* We must have been a writer. */ + INSIST((prev_readers & WRITER_ACTIVE) != 0); + + /* Complete write */ + (void)isc_atomic_xadd(&rwl->cnt_and_flag, -WRITER_ACTIVE); + (void)isc_atomic_xadd(&rwl->write_completions, 1); + + /* Resume other readers */ + LOCK(&rwl->lock); + if (rwl->readers_waiting > 0) + BROADCAST(&rwl->readable); + UNLOCK(&rwl->lock); +} + +isc_result_t +isc_rwlock_unlock(isc_rwlock_t *rwl, isc_rwlocktype_t type) { + isc_int32_t prev_cnt; + + REQUIRE(VALID_RWLOCK(rwl)); + +#ifdef ISC_RWLOCK_TRACE + print_lock(isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_PREUNLOCK, "preunlock"), rwl, type); +#endif + + if (type == isc_rwlocktype_read) { + prev_cnt = isc_atomic_xadd(&rwl->cnt_and_flag, -READER_INCR); + + /* + * If we're the last reader and any writers are waiting, wake + * them up. We need to wake up all of them to ensure the + * FIFO order. + */ + if (prev_cnt == READER_INCR && + rwl->write_completions != rwl->write_requests) { + LOCK(&rwl->lock); + BROADCAST(&rwl->writeable); + UNLOCK(&rwl->lock); + } + } else { + isc_boolean_t wakeup_writers = ISC_TRUE; + + /* + * Reset the flag, and (implicitly) tell other writers + * we are done. + */ + (void)isc_atomic_xadd(&rwl->cnt_and_flag, -WRITER_ACTIVE); + (void)isc_atomic_xadd(&rwl->write_completions, 1); + + if (rwl->write_granted >= rwl->write_quota || + rwl->write_requests == rwl->write_completions || + (rwl->cnt_and_flag & ~WRITER_ACTIVE) != 0) { + /* + * We have passed the write quota, no writer is + * waiting, or some readers are almost ready, pending + * possible writers. Note that the last case can + * happen even if write_requests != write_completions + * (which means a new writer in the queue), so we need + * to catch the case explicitly. + */ + LOCK(&rwl->lock); + if (rwl->readers_waiting > 0) { + wakeup_writers = ISC_FALSE; + BROADCAST(&rwl->readable); + } + UNLOCK(&rwl->lock); + } + + if (rwl->write_requests != rwl->write_completions && + wakeup_writers) { + LOCK(&rwl->lock); + BROADCAST(&rwl->writeable); + UNLOCK(&rwl->lock); + } + } + +#ifdef ISC_RWLOCK_TRACE + print_lock(isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_POSTUNLOCK, "postunlock"), + rwl, type); +#endif + + return (ISC_R_SUCCESS); +} + +#else /* ISC_PLATFORM_HAVEXADD && ISC_PLATFORM_HAVECMPXCHG */ + +static isc_result_t +doit(isc_rwlock_t *rwl, isc_rwlocktype_t type, isc_boolean_t nonblock) { + isc_boolean_t skip = ISC_FALSE; + isc_boolean_t done = ISC_FALSE; + isc_result_t result = ISC_R_SUCCESS; + + REQUIRE(VALID_RWLOCK(rwl)); + + LOCK(&rwl->lock); + +#ifdef ISC_RWLOCK_TRACE + print_lock(isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_PRELOCK, "prelock"), rwl, type); +#endif + + if (type == isc_rwlocktype_read) { + if (rwl->readers_waiting != 0) + skip = ISC_TRUE; + while (!done) { + if (!skip && + ((rwl->active == 0 || + (rwl->type == isc_rwlocktype_read && + (rwl->writers_waiting == 0 || + rwl->granted < rwl->read_quota))))) + { + rwl->type = isc_rwlocktype_read; + rwl->active++; + rwl->granted++; + done = ISC_TRUE; + } else if (nonblock) { + result = ISC_R_LOCKBUSY; + done = ISC_TRUE; + } else { + skip = ISC_FALSE; + rwl->readers_waiting++; + WAIT(&rwl->readable, &rwl->lock); + rwl->readers_waiting--; + } + } + } else { + if (rwl->writers_waiting != 0) + skip = ISC_TRUE; + while (!done) { + if (!skip && rwl->active == 0) { + rwl->type = isc_rwlocktype_write; + rwl->active = 1; + rwl->granted++; + done = ISC_TRUE; + } else if (nonblock) { + result = ISC_R_LOCKBUSY; + done = ISC_TRUE; + } else { + skip = ISC_FALSE; + rwl->writers_waiting++; + WAIT(&rwl->writeable, &rwl->lock); + rwl->writers_waiting--; + } + } + } + +#ifdef ISC_RWLOCK_TRACE + print_lock(isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_POSTLOCK, "postlock"), rwl, type); +#endif + + UNLOCK(&rwl->lock); + + return (result); +} + +isc_result_t +isc_rwlock_lock(isc_rwlock_t *rwl, isc_rwlocktype_t type) { + return (doit(rwl, type, ISC_FALSE)); +} + +isc_result_t +isc_rwlock_trylock(isc_rwlock_t *rwl, isc_rwlocktype_t type) { + return (doit(rwl, type, ISC_TRUE)); +} + +isc_result_t +isc_rwlock_tryupgrade(isc_rwlock_t *rwl) { + isc_result_t result = ISC_R_SUCCESS; + + REQUIRE(VALID_RWLOCK(rwl)); + LOCK(&rwl->lock); + REQUIRE(rwl->type == isc_rwlocktype_read); + REQUIRE(rwl->active != 0); + + /* If we are the only reader then succeed. */ + if (rwl->active == 1) { + rwl->original = (rwl->original == isc_rwlocktype_none) ? + isc_rwlocktype_read : isc_rwlocktype_none; + rwl->type = isc_rwlocktype_write; + } else + result = ISC_R_LOCKBUSY; + + UNLOCK(&rwl->lock); + return (result); +} + +void +isc_rwlock_downgrade(isc_rwlock_t *rwl) { + + REQUIRE(VALID_RWLOCK(rwl)); + LOCK(&rwl->lock); + REQUIRE(rwl->type == isc_rwlocktype_write); + REQUIRE(rwl->active == 1); + + rwl->type = isc_rwlocktype_read; + rwl->original = (rwl->original == isc_rwlocktype_none) ? + isc_rwlocktype_write : isc_rwlocktype_none; + /* + * Resume processing any read request that were blocked when + * we upgraded. + */ + if (rwl->original == isc_rwlocktype_none && + (rwl->writers_waiting == 0 || rwl->granted < rwl->read_quota) && + rwl->readers_waiting > 0) + BROADCAST(&rwl->readable); + + UNLOCK(&rwl->lock); +} + +isc_result_t +isc_rwlock_unlock(isc_rwlock_t *rwl, isc_rwlocktype_t type) { + + REQUIRE(VALID_RWLOCK(rwl)); + LOCK(&rwl->lock); + REQUIRE(rwl->type == type); + + UNUSED(type); + +#ifdef ISC_RWLOCK_TRACE + print_lock(isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_PREUNLOCK, "preunlock"), rwl, type); +#endif + + INSIST(rwl->active > 0); + rwl->active--; + if (rwl->active == 0) { + if (rwl->original != isc_rwlocktype_none) { + rwl->type = rwl->original; + rwl->original = isc_rwlocktype_none; + } + if (rwl->type == isc_rwlocktype_read) { + rwl->granted = 0; + if (rwl->writers_waiting > 0) { + rwl->type = isc_rwlocktype_write; + SIGNAL(&rwl->writeable); + } else if (rwl->readers_waiting > 0) { + /* Does this case ever happen? */ + BROADCAST(&rwl->readable); + } + } else { + if (rwl->readers_waiting > 0) { + if (rwl->writers_waiting > 0 && + rwl->granted < rwl->write_quota) { + SIGNAL(&rwl->writeable); + } else { + rwl->granted = 0; + rwl->type = isc_rwlocktype_read; + BROADCAST(&rwl->readable); + } + } else if (rwl->writers_waiting > 0) { + rwl->granted = 0; + SIGNAL(&rwl->writeable); + } else { + rwl->granted = 0; + } + } + } + INSIST(rwl->original == isc_rwlocktype_none); + +#ifdef ISC_RWLOCK_TRACE + print_lock(isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_POSTUNLOCK, "postunlock"), + rwl, type); +#endif + + UNLOCK(&rwl->lock); + + return (ISC_R_SUCCESS); +} + +#endif /* ISC_PLATFORM_HAVEXADD && ISC_PLATFORM_HAVECMPXCHG */ +#else /* ISC_PLATFORM_USETHREADS */ + +isc_result_t +isc_rwlock_init(isc_rwlock_t *rwl, unsigned int read_quota, + unsigned int write_quota) +{ + REQUIRE(rwl != NULL); + + UNUSED(read_quota); + UNUSED(write_quota); + + rwl->type = isc_rwlocktype_read; + rwl->active = 0; + rwl->magic = RWLOCK_MAGIC; + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_rwlock_lock(isc_rwlock_t *rwl, isc_rwlocktype_t type) { + REQUIRE(VALID_RWLOCK(rwl)); + + if (type == isc_rwlocktype_read) { + if (rwl->type != isc_rwlocktype_read && rwl->active != 0) + return (ISC_R_LOCKBUSY); + rwl->type = isc_rwlocktype_read; + rwl->active++; + } else { + if (rwl->active != 0) + return (ISC_R_LOCKBUSY); + rwl->type = isc_rwlocktype_write; + rwl->active = 1; + } + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_rwlock_trylock(isc_rwlock_t *rwl, isc_rwlocktype_t type) { + return (isc_rwlock_lock(rwl, type)); +} + +isc_result_t +isc_rwlock_tryupgrade(isc_rwlock_t *rwl) { + isc_result_t result = ISC_R_SUCCESS; + + REQUIRE(VALID_RWLOCK(rwl)); + REQUIRE(rwl->type == isc_rwlocktype_read); + REQUIRE(rwl->active != 0); + + /* If we are the only reader then succeed. */ + if (rwl->active == 1) + rwl->type = isc_rwlocktype_write; + else + result = ISC_R_LOCKBUSY; + return (result); +} + +void +isc_rwlock_downgrade(isc_rwlock_t *rwl) { + + REQUIRE(VALID_RWLOCK(rwl)); + REQUIRE(rwl->type == isc_rwlocktype_write); + REQUIRE(rwl->active == 1); + + rwl->type = isc_rwlocktype_read; +} + +isc_result_t +isc_rwlock_unlock(isc_rwlock_t *rwl, isc_rwlocktype_t type) { + REQUIRE(VALID_RWLOCK(rwl)); + REQUIRE(rwl->type == type); + + UNUSED(type); + + INSIST(rwl->active > 0); + rwl->active--; + + return (ISC_R_SUCCESS); +} + +void +isc_rwlock_destroy(isc_rwlock_t *rwl) { + REQUIRE(rwl != NULL); + REQUIRE(rwl->active == 0); + rwl->magic = 0; +} + +#endif /* ISC_PLATFORM_USETHREADS */ diff -urN src/contrib/ntp/lib/isc/serial.c src.ntp/contrib/ntp/lib/isc/serial.c --- src/contrib/ntp/lib/isc/serial.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/serial.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,59 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: serial.c,v 1.12 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include + +isc_boolean_t +isc_serial_lt(isc_uint32_t a, isc_uint32_t b) { + /* + * Undefined => ISC_FALSE + */ + if (a == (b ^ 0x80000000U)) + return (ISC_FALSE); + return (((isc_int32_t)(a - b) < 0) ? ISC_TRUE : ISC_FALSE); +} + +isc_boolean_t +isc_serial_gt(isc_uint32_t a, isc_uint32_t b) { + return (((isc_int32_t)(a - b) > 0) ? ISC_TRUE : ISC_FALSE); +} + +isc_boolean_t +isc_serial_le(isc_uint32_t a, isc_uint32_t b) { + return ((a == b) ? ISC_TRUE : isc_serial_lt(a, b)); +} + +isc_boolean_t +isc_serial_ge(isc_uint32_t a, isc_uint32_t b) { + return ((a == b) ? ISC_TRUE : isc_serial_gt(a, b)); +} + +isc_boolean_t +isc_serial_eq(isc_uint32_t a, isc_uint32_t b) { + return ((a == b) ? ISC_TRUE : ISC_FALSE); +} + +isc_boolean_t +isc_serial_ne(isc_uint32_t a, isc_uint32_t b) { + return ((a != b) ? ISC_TRUE : ISC_FALSE); +} diff -urN src/contrib/ntp/lib/isc/sha1.c src.ntp/contrib/ntp/lib/isc/sha1.c --- src/contrib/ntp/lib/isc/sha1.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/sha1.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,315 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: sha1.c,v 1.18 2007/06/19 23:47:17 tbox Exp $ */ + +/* $NetBSD: sha1.c,v 1.5 2000/01/22 22:19:14 mycroft Exp $ */ +/* $OpenBSD: sha1.c,v 1.9 1997/07/23 21:12:32 kstailey Exp $ */ + +/*! \file + * SHA-1 in C + * \author By Steve Reid + * 100% Public Domain + * \verbatim + * Test Vectors (from FIPS PUB 180-1) + * "abc" + * A9993E36 4706816A BA3E2571 7850C26C 9CD0D89D + * "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq" + * 84983E44 1C3BD26E BAAE4AA1 F95129E5 E54670F1 + * A million repetitions of "a" + * 34AA973C D4C4DAA4 F61EEB2B DBAD2731 6534016F + * \endverbatim + */ + +#include "config.h" + +#include +#include +#include +#include +#include + +#define rol(value, bits) (((value) << (bits)) | ((value) >> (32 - (bits)))) + +/*@{*/ +/*! + * blk0() and blk() perform the initial expand. + * I got the idea of expanding during the round function from SSLeay + */ +#if !defined(WORDS_BIGENDIAN) +# define blk0(i) \ + (block->l[i] = (rol(block->l[i], 24) & 0xFF00FF00) \ + | (rol(block->l[i], 8) & 0x00FF00FF)) +#else +# define blk0(i) block->l[i] +#endif +#define blk(i) \ + (block->l[i & 15] = rol(block->l[(i + 13) & 15] \ + ^ block->l[(i + 8) & 15] \ + ^ block->l[(i + 2) & 15] \ + ^ block->l[i & 15], 1)) + +/*@}*/ +/*@{*/ +/*! + * (R0+R1), R2, R3, R4 are the different operations (rounds) used in SHA1 + */ +#define R0(v,w,x,y,z,i) \ + z += ((w & (x ^ y)) ^ y) + blk0(i) + 0x5A827999 + rol(v, 5); \ + w = rol(w, 30); +#define R1(v,w,x,y,z,i) \ + z += ((w & (x ^ y)) ^ y) + blk(i) + 0x5A827999 + rol(v, 5); \ + w = rol(w, 30); +#define R2(v,w,x,y,z,i) \ + z += (w ^ x ^ y) + blk(i) + 0x6ED9EBA1 + rol(v, 5); \ + w = rol(w, 30); +#define R3(v,w,x,y,z,i) \ + z += (((w | x) & y) | (w & x)) + blk(i) + 0x8F1BBCDC + rol(v, 5); \ + w = rol(w, 30); +#define R4(v,w,x,y,z,i) \ + z += (w ^ x ^ y) + blk(i) + 0xCA62C1D6 + rol(v, 5); \ + w = rol(w, 30); + +/*@}*/ + +typedef union { + unsigned char c[64]; + unsigned int l[16]; +} CHAR64LONG16; + +#ifdef __sparc_v9__ +static void do_R01(isc_uint32_t *a, isc_uint32_t *b, isc_uint32_t *c, + isc_uint32_t *d, isc_uint32_t *e, CHAR64LONG16 *); +static void do_R2(isc_uint32_t *a, isc_uint32_t *b, isc_uint32_t *c, + isc_uint32_t *d, isc_uint32_t *e, CHAR64LONG16 *); +static void do_R3(isc_uint32_t *a, isc_uint32_t *b, isc_uint32_t *c, + isc_uint32_t *d, isc_uint32_t *e, CHAR64LONG16 *); +static void do_R4(isc_uint32_t *a, isc_uint32_t *b, isc_uint32_t *c, + isc_uint32_t *d, isc_uint32_t *e, CHAR64LONG16 *); + +#define nR0(v,w,x,y,z,i) R0(*v,*w,*x,*y,*z,i) +#define nR1(v,w,x,y,z,i) R1(*v,*w,*x,*y,*z,i) +#define nR2(v,w,x,y,z,i) R2(*v,*w,*x,*y,*z,i) +#define nR3(v,w,x,y,z,i) R3(*v,*w,*x,*y,*z,i) +#define nR4(v,w,x,y,z,i) R4(*v,*w,*x,*y,*z,i) + +static void +do_R01(isc_uint32_t *a, isc_uint32_t *b, isc_uint32_t *c, isc_uint32_t *d, + isc_uint32_t *e, CHAR64LONG16 *block) +{ + nR0(a,b,c,d,e, 0); nR0(e,a,b,c,d, 1); nR0(d,e,a,b,c, 2); + nR0(c,d,e,a,b, 3); nR0(b,c,d,e,a, 4); nR0(a,b,c,d,e, 5); + nR0(e,a,b,c,d, 6); nR0(d,e,a,b,c, 7); nR0(c,d,e,a,b, 8); + nR0(b,c,d,e,a, 9); nR0(a,b,c,d,e,10); nR0(e,a,b,c,d,11); + nR0(d,e,a,b,c,12); nR0(c,d,e,a,b,13); nR0(b,c,d,e,a,14); + nR0(a,b,c,d,e,15); nR1(e,a,b,c,d,16); nR1(d,e,a,b,c,17); + nR1(c,d,e,a,b,18); nR1(b,c,d,e,a,19); +} + +static void +do_R2(isc_uint32_t *a, isc_uint32_t *b, isc_uint32_t *c, isc_uint32_t *d, + isc_uint32_t *e, CHAR64LONG16 *block) +{ + nR2(a,b,c,d,e,20); nR2(e,a,b,c,d,21); nR2(d,e,a,b,c,22); + nR2(c,d,e,a,b,23); nR2(b,c,d,e,a,24); nR2(a,b,c,d,e,25); + nR2(e,a,b,c,d,26); nR2(d,e,a,b,c,27); nR2(c,d,e,a,b,28); + nR2(b,c,d,e,a,29); nR2(a,b,c,d,e,30); nR2(e,a,b,c,d,31); + nR2(d,e,a,b,c,32); nR2(c,d,e,a,b,33); nR2(b,c,d,e,a,34); + nR2(a,b,c,d,e,35); nR2(e,a,b,c,d,36); nR2(d,e,a,b,c,37); + nR2(c,d,e,a,b,38); nR2(b,c,d,e,a,39); +} + +static void +do_R3(isc_uint32_t *a, isc_uint32_t *b, isc_uint32_t *c, isc_uint32_t *d, + isc_uint32_t *e, CHAR64LONG16 *block) +{ + nR3(a,b,c,d,e,40); nR3(e,a,b,c,d,41); nR3(d,e,a,b,c,42); + nR3(c,d,e,a,b,43); nR3(b,c,d,e,a,44); nR3(a,b,c,d,e,45); + nR3(e,a,b,c,d,46); nR3(d,e,a,b,c,47); nR3(c,d,e,a,b,48); + nR3(b,c,d,e,a,49); nR3(a,b,c,d,e,50); nR3(e,a,b,c,d,51); + nR3(d,e,a,b,c,52); nR3(c,d,e,a,b,53); nR3(b,c,d,e,a,54); + nR3(a,b,c,d,e,55); nR3(e,a,b,c,d,56); nR3(d,e,a,b,c,57); + nR3(c,d,e,a,b,58); nR3(b,c,d,e,a,59); +} + +static void +do_R4(isc_uint32_t *a, isc_uint32_t *b, isc_uint32_t *c, isc_uint32_t *d, + isc_uint32_t *e, CHAR64LONG16 *block) +{ + nR4(a,b,c,d,e,60); nR4(e,a,b,c,d,61); nR4(d,e,a,b,c,62); + nR4(c,d,e,a,b,63); nR4(b,c,d,e,a,64); nR4(a,b,c,d,e,65); + nR4(e,a,b,c,d,66); nR4(d,e,a,b,c,67); nR4(c,d,e,a,b,68); + nR4(b,c,d,e,a,69); nR4(a,b,c,d,e,70); nR4(e,a,b,c,d,71); + nR4(d,e,a,b,c,72); nR4(c,d,e,a,b,73); nR4(b,c,d,e,a,74); + nR4(a,b,c,d,e,75); nR4(e,a,b,c,d,76); nR4(d,e,a,b,c,77); + nR4(c,d,e,a,b,78); nR4(b,c,d,e,a,79); +} +#endif + +/*! + * Hash a single 512-bit block. This is the core of the algorithm. + */ +static void +transform(isc_uint32_t state[5], const unsigned char buffer[64]) { + isc_uint32_t a, b, c, d, e; + CHAR64LONG16 *block; + CHAR64LONG16 workspace; + + INSIST(buffer != NULL); + INSIST(state != NULL); + + block = &workspace; + (void)memcpy(block, buffer, 64); + + /* Copy context->state[] to working vars */ + a = state[0]; + b = state[1]; + c = state[2]; + d = state[3]; + e = state[4]; + +#ifdef __sparc_v9__ + do_R01(&a, &b, &c, &d, &e, block); + do_R2(&a, &b, &c, &d, &e, block); + do_R3(&a, &b, &c, &d, &e, block); + do_R4(&a, &b, &c, &d, &e, block); +#else + /* 4 rounds of 20 operations each. Loop unrolled. */ + R0(a,b,c,d,e, 0); R0(e,a,b,c,d, 1); R0(d,e,a,b,c, 2); R0(c,d,e,a,b, 3); + R0(b,c,d,e,a, 4); R0(a,b,c,d,e, 5); R0(e,a,b,c,d, 6); R0(d,e,a,b,c, 7); + R0(c,d,e,a,b, 8); R0(b,c,d,e,a, 9); R0(a,b,c,d,e,10); R0(e,a,b,c,d,11); + R0(d,e,a,b,c,12); R0(c,d,e,a,b,13); R0(b,c,d,e,a,14); R0(a,b,c,d,e,15); + R1(e,a,b,c,d,16); R1(d,e,a,b,c,17); R1(c,d,e,a,b,18); R1(b,c,d,e,a,19); + R2(a,b,c,d,e,20); R2(e,a,b,c,d,21); R2(d,e,a,b,c,22); R2(c,d,e,a,b,23); + R2(b,c,d,e,a,24); R2(a,b,c,d,e,25); R2(e,a,b,c,d,26); R2(d,e,a,b,c,27); + R2(c,d,e,a,b,28); R2(b,c,d,e,a,29); R2(a,b,c,d,e,30); R2(e,a,b,c,d,31); + R2(d,e,a,b,c,32); R2(c,d,e,a,b,33); R2(b,c,d,e,a,34); R2(a,b,c,d,e,35); + R2(e,a,b,c,d,36); R2(d,e,a,b,c,37); R2(c,d,e,a,b,38); R2(b,c,d,e,a,39); + R3(a,b,c,d,e,40); R3(e,a,b,c,d,41); R3(d,e,a,b,c,42); R3(c,d,e,a,b,43); + R3(b,c,d,e,a,44); R3(a,b,c,d,e,45); R3(e,a,b,c,d,46); R3(d,e,a,b,c,47); + R3(c,d,e,a,b,48); R3(b,c,d,e,a,49); R3(a,b,c,d,e,50); R3(e,a,b,c,d,51); + R3(d,e,a,b,c,52); R3(c,d,e,a,b,53); R3(b,c,d,e,a,54); R3(a,b,c,d,e,55); + R3(e,a,b,c,d,56); R3(d,e,a,b,c,57); R3(c,d,e,a,b,58); R3(b,c,d,e,a,59); + R4(a,b,c,d,e,60); R4(e,a,b,c,d,61); R4(d,e,a,b,c,62); R4(c,d,e,a,b,63); + R4(b,c,d,e,a,64); R4(a,b,c,d,e,65); R4(e,a,b,c,d,66); R4(d,e,a,b,c,67); + R4(c,d,e,a,b,68); R4(b,c,d,e,a,69); R4(a,b,c,d,e,70); R4(e,a,b,c,d,71); + R4(d,e,a,b,c,72); R4(c,d,e,a,b,73); R4(b,c,d,e,a,74); R4(a,b,c,d,e,75); + R4(e,a,b,c,d,76); R4(d,e,a,b,c,77); R4(c,d,e,a,b,78); R4(b,c,d,e,a,79); +#endif + + /* Add the working vars back into context.state[] */ + state[0] += a; + state[1] += b; + state[2] += c; + state[3] += d; + state[4] += e; + + /* Wipe variables */ + a = b = c = d = e = 0; +} + + +/*! + * isc_sha1_init - Initialize new context + */ +void +isc_sha1_init(isc_sha1_t *context) +{ + INSIST(context != NULL); + + /* SHA1 initialization constants */ + context->state[0] = 0x67452301; + context->state[1] = 0xEFCDAB89; + context->state[2] = 0x98BADCFE; + context->state[3] = 0x10325476; + context->state[4] = 0xC3D2E1F0; + context->count[0] = 0; + context->count[1] = 0; +} + +void +isc_sha1_invalidate(isc_sha1_t *context) { + memset(context, 0, sizeof(isc_sha1_t)); +} + +/*! + * Run your data through this. + */ +void +isc_sha1_update(isc_sha1_t *context, const unsigned char *data, + unsigned int len) +{ + unsigned int i, j; + + INSIST(context != 0); + INSIST(data != 0); + + j = context->count[0]; + if ((context->count[0] += len << 3) < j) + context->count[1] += (len >> 29) + 1; + j = (j >> 3) & 63; + if ((j + len) > 63) { + (void)memcpy(&context->buffer[j], data, (i = 64 - j)); + transform(context->state, context->buffer); + for (; i + 63 < len; i += 64) + transform(context->state, &data[i]); + j = 0; + } else { + i = 0; + } + + (void)memcpy(&context->buffer[j], &data[i], len - i); +} + + +/*! + * Add padding and return the message digest. + */ + +static const unsigned char final_200 = 128; +static const unsigned char final_0 = 0; + +void +isc_sha1_final(isc_sha1_t *context, unsigned char *digest) { + unsigned int i; + unsigned char finalcount[8]; + + INSIST(digest != 0); + INSIST(context != 0); + + for (i = 0; i < 8; i++) { + /* Endian independent */ + finalcount[i] = (unsigned char) + ((context->count[(i >= 4 ? 0 : 1)] + >> ((3 - (i & 3)) * 8)) & 255); + } + + isc_sha1_update(context, &final_200, 1); + while ((context->count[0] & 504) != 448) + isc_sha1_update(context, &final_0, 1); + /* The next Update should cause a transform() */ + isc_sha1_update(context, finalcount, 8); + + if (digest) { + for (i = 0; i < 20; i++) + digest[i] = (unsigned char) + ((context->state[i >> 2] + >> ((3 - (i & 3)) * 8)) & 255); + } + + memset(context, 0, sizeof(isc_sha1_t)); +} diff -urN src/contrib/ntp/lib/isc/sha2.c src.ntp/contrib/ntp/lib/isc/sha2.c --- src/contrib/ntp/lib/isc/sha2.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/sha2.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,1234 @@ +/* + * Copyright (C) 2005-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: sha2.c,v 1.13.332.2 2009/01/18 23:47:41 tbox Exp $ */ + +/* $FreeBSD: src/sys/crypto/sha2/sha2.c,v 1.2.2.2 2002/03/05 08:36:47 ume Exp $ */ +/* $KAME: sha2.c,v 1.8 2001/11/08 01:07:52 itojun Exp $ */ + +/* + * sha2.c + * + * Version 1.0.0beta1 + * + * Written by Aaron D. Gifford + * + * Copyright 2000 Aaron D. Gifford. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the copyright holder nor the names of contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) AND CONTRIBUTOR(S) ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR(S) OR CONTRIBUTOR(S) BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + */ + + +#include + +#include +#include +#include +#include + +/* + * UNROLLED TRANSFORM LOOP NOTE: + * You can define SHA2_UNROLL_TRANSFORM to use the unrolled transform + * loop version for the hash transform rounds (defined using macros + * later in this file). Either define on the command line, for example: + * + * cc -DISC_SHA2_UNROLL_TRANSFORM -o sha2 sha2.c sha2prog.c + * + * or define below: + * + * \#define ISC_SHA2_UNROLL_TRANSFORM + * + */ + +/*** SHA-256/384/512 Machine Architecture Definitions *****************/ +/* + * BYTE_ORDER NOTE: + * + * Please make sure that your system defines BYTE_ORDER. If your + * architecture is little-endian, make sure it also defines + * LITTLE_ENDIAN and that the two (BYTE_ORDER and LITTLE_ENDIAN) are + * equivalent. + * + * If your system does not define the above, then you can do so by + * hand like this: + * + * \#define LITTLE_ENDIAN 1234 + * \#define BIG_ENDIAN 4321 + * + * And for little-endian machines, add: + * + * \#define BYTE_ORDER LITTLE_ENDIAN + * + * Or for big-endian machines: + * + * \#define BYTE_ORDER BIG_ENDIAN + * + * The FreeBSD machine this was written on defines BYTE_ORDER + * appropriately by including (which in turn includes + * where the appropriate definitions are actually + * made). + */ +#if !defined(BYTE_ORDER) || (BYTE_ORDER != LITTLE_ENDIAN && BYTE_ORDER != BIG_ENDIAN) +#ifndef BYTE_ORDER +#ifndef BIG_ENDIAN +#define BIG_ENDIAN 4321 +#endif +#ifndef LITTLE_ENDIAN +#define LITTLE_ENDIAN 1234 +#endif +#ifdef WORDS_BIGENDIAN +#define BYTE_ORDER BIG_ENDIAN +#else +#define BYTE_ORDER LITTLE_ENDIAN +#endif +#else +#error Define BYTE_ORDER to be equal to either LITTLE_ENDIAN or BIG_ENDIAN +#endif +#endif + +/*** SHA-256/384/512 Various Length Definitions ***********************/ +/* NOTE: Most of these are in sha2.h */ +#define ISC_SHA256_SHORT_BLOCK_LENGTH (ISC_SHA256_BLOCK_LENGTH - 8) +#define ISC_SHA384_SHORT_BLOCK_LENGTH (ISC_SHA384_BLOCK_LENGTH - 16) +#define ISC_SHA512_SHORT_BLOCK_LENGTH (ISC_SHA512_BLOCK_LENGTH - 16) + + +/*** ENDIAN REVERSAL MACROS *******************************************/ +#if BYTE_ORDER == LITTLE_ENDIAN +#define REVERSE32(w,x) { \ + isc_uint32_t tmp = (w); \ + tmp = (tmp >> 16) | (tmp << 16); \ + (x) = ((tmp & 0xff00ff00UL) >> 8) | ((tmp & 0x00ff00ffUL) << 8); \ +} +#ifdef WIN32 +#define REVERSE64(w,x) { \ + isc_uint64_t tmp = (w); \ + tmp = (tmp >> 32) | (tmp << 32); \ + tmp = ((tmp & 0xff00ff00ff00ff00UL) >> 8) | \ + ((tmp & 0x00ff00ff00ff00ffUL) << 8); \ + (x) = ((tmp & 0xffff0000ffff0000UL) >> 16) | \ + ((tmp & 0x0000ffff0000ffffUL) << 16); \ +} +#else +#define REVERSE64(w,x) { \ + isc_uint64_t tmp = (w); \ + tmp = (tmp >> 32) | (tmp << 32); \ + tmp = ((tmp & 0xff00ff00ff00ff00ULL) >> 8) | \ + ((tmp & 0x00ff00ff00ff00ffULL) << 8); \ + (x) = ((tmp & 0xffff0000ffff0000ULL) >> 16) | \ + ((tmp & 0x0000ffff0000ffffULL) << 16); \ +} +#endif +#endif /* BYTE_ORDER == LITTLE_ENDIAN */ + +/* + * Macro for incrementally adding the unsigned 64-bit integer n to the + * unsigned 128-bit integer (represented using a two-element array of + * 64-bit words): + */ +#define ADDINC128(w,n) { \ + (w)[0] += (isc_uint64_t)(n); \ + if ((w)[0] < (n)) { \ + (w)[1]++; \ + } \ +} + +/*** THE SIX LOGICAL FUNCTIONS ****************************************/ +/* + * Bit shifting and rotation (used by the six SHA-XYZ logical functions: + * + * NOTE: The naming of R and S appears backwards here (R is a SHIFT and + * S is a ROTATION) because the SHA-256/384/512 description document + * (see http://csrc.nist.gov/cryptval/shs/sha256-384-512.pdf) uses this + * same "backwards" definition. + */ +/* Shift-right (used in SHA-256, SHA-384, and SHA-512): */ +#define R(b,x) ((x) >> (b)) +/* 32-bit Rotate-right (used in SHA-256): */ +#define S32(b,x) (((x) >> (b)) | ((x) << (32 - (b)))) +/* 64-bit Rotate-right (used in SHA-384 and SHA-512): */ +#define S64(b,x) (((x) >> (b)) | ((x) << (64 - (b)))) + +/* Two of six logical functions used in SHA-256, SHA-384, and SHA-512: */ +#define Ch(x,y,z) (((x) & (y)) ^ ((~(x)) & (z))) +#define Maj(x,y,z) (((x) & (y)) ^ ((x) & (z)) ^ ((y) & (z))) + +/* Four of six logical functions used in SHA-256: */ +#define Sigma0_256(x) (S32(2, (x)) ^ S32(13, (x)) ^ S32(22, (x))) +#define Sigma1_256(x) (S32(6, (x)) ^ S32(11, (x)) ^ S32(25, (x))) +#define sigma0_256(x) (S32(7, (x)) ^ S32(18, (x)) ^ R(3 , (x))) +#define sigma1_256(x) (S32(17, (x)) ^ S32(19, (x)) ^ R(10, (x))) + +/* Four of six logical functions used in SHA-384 and SHA-512: */ +#define Sigma0_512(x) (S64(28, (x)) ^ S64(34, (x)) ^ S64(39, (x))) +#define Sigma1_512(x) (S64(14, (x)) ^ S64(18, (x)) ^ S64(41, (x))) +#define sigma0_512(x) (S64( 1, (x)) ^ S64( 8, (x)) ^ R( 7, (x))) +#define sigma1_512(x) (S64(19, (x)) ^ S64(61, (x)) ^ R( 6, (x))) + +/*** INTERNAL FUNCTION PROTOTYPES *************************************/ +/* NOTE: These should not be accessed directly from outside this + * library -- they are intended for private internal visibility/use + * only. + */ +void isc_sha512_last(isc_sha512_t *); +void isc_sha256_transform(isc_sha256_t *, const isc_uint32_t*); +void isc_sha512_transform(isc_sha512_t *, const isc_uint64_t*); + + +/*** SHA-XYZ INITIAL HASH VALUES AND CONSTANTS ************************/ +/* Hash constant words K for SHA-224 and SHA-256: */ +static const isc_uint32_t K256[64] = { + 0x428a2f98UL, 0x71374491UL, 0xb5c0fbcfUL, 0xe9b5dba5UL, + 0x3956c25bUL, 0x59f111f1UL, 0x923f82a4UL, 0xab1c5ed5UL, + 0xd807aa98UL, 0x12835b01UL, 0x243185beUL, 0x550c7dc3UL, + 0x72be5d74UL, 0x80deb1feUL, 0x9bdc06a7UL, 0xc19bf174UL, + 0xe49b69c1UL, 0xefbe4786UL, 0x0fc19dc6UL, 0x240ca1ccUL, + 0x2de92c6fUL, 0x4a7484aaUL, 0x5cb0a9dcUL, 0x76f988daUL, + 0x983e5152UL, 0xa831c66dUL, 0xb00327c8UL, 0xbf597fc7UL, + 0xc6e00bf3UL, 0xd5a79147UL, 0x06ca6351UL, 0x14292967UL, + 0x27b70a85UL, 0x2e1b2138UL, 0x4d2c6dfcUL, 0x53380d13UL, + 0x650a7354UL, 0x766a0abbUL, 0x81c2c92eUL, 0x92722c85UL, + 0xa2bfe8a1UL, 0xa81a664bUL, 0xc24b8b70UL, 0xc76c51a3UL, + 0xd192e819UL, 0xd6990624UL, 0xf40e3585UL, 0x106aa070UL, + 0x19a4c116UL, 0x1e376c08UL, 0x2748774cUL, 0x34b0bcb5UL, + 0x391c0cb3UL, 0x4ed8aa4aUL, 0x5b9cca4fUL, 0x682e6ff3UL, + 0x748f82eeUL, 0x78a5636fUL, 0x84c87814UL, 0x8cc70208UL, + 0x90befffaUL, 0xa4506cebUL, 0xbef9a3f7UL, 0xc67178f2UL +}; + +/* Initial hash value H for SHA-224: */ +static const isc_uint32_t sha224_initial_hash_value[8] = { + 0xc1059ed8UL, + 0x367cd507UL, + 0x3070dd17UL, + 0xf70e5939UL, + 0xffc00b31UL, + 0x68581511UL, + 0x64f98fa7UL, + 0xbefa4fa4UL +}; + +/* Initial hash value H for SHA-256: */ +static const isc_uint32_t sha256_initial_hash_value[8] = { + 0x6a09e667UL, + 0xbb67ae85UL, + 0x3c6ef372UL, + 0xa54ff53aUL, + 0x510e527fUL, + 0x9b05688cUL, + 0x1f83d9abUL, + 0x5be0cd19UL +}; + +#ifdef WIN32 +/* Hash constant words K for SHA-384 and SHA-512: */ +static const isc_uint64_t K512[80] = { + 0x428a2f98d728ae22UL, 0x7137449123ef65cdUL, + 0xb5c0fbcfec4d3b2fUL, 0xe9b5dba58189dbbcUL, + 0x3956c25bf348b538UL, 0x59f111f1b605d019UL, + 0x923f82a4af194f9bUL, 0xab1c5ed5da6d8118UL, + 0xd807aa98a3030242UL, 0x12835b0145706fbeUL, + 0x243185be4ee4b28cUL, 0x550c7dc3d5ffb4e2UL, + 0x72be5d74f27b896fUL, 0x80deb1fe3b1696b1UL, + 0x9bdc06a725c71235UL, 0xc19bf174cf692694UL, + 0xe49b69c19ef14ad2UL, 0xefbe4786384f25e3UL, + 0x0fc19dc68b8cd5b5UL, 0x240ca1cc77ac9c65UL, + 0x2de92c6f592b0275UL, 0x4a7484aa6ea6e483UL, + 0x5cb0a9dcbd41fbd4UL, 0x76f988da831153b5UL, + 0x983e5152ee66dfabUL, 0xa831c66d2db43210UL, + 0xb00327c898fb213fUL, 0xbf597fc7beef0ee4UL, + 0xc6e00bf33da88fc2UL, 0xd5a79147930aa725UL, + 0x06ca6351e003826fUL, 0x142929670a0e6e70UL, + 0x27b70a8546d22ffcUL, 0x2e1b21385c26c926UL, + 0x4d2c6dfc5ac42aedUL, 0x53380d139d95b3dfUL, + 0x650a73548baf63deUL, 0x766a0abb3c77b2a8UL, + 0x81c2c92e47edaee6UL, 0x92722c851482353bUL, + 0xa2bfe8a14cf10364UL, 0xa81a664bbc423001UL, + 0xc24b8b70d0f89791UL, 0xc76c51a30654be30UL, + 0xd192e819d6ef5218UL, 0xd69906245565a910UL, + 0xf40e35855771202aUL, 0x106aa07032bbd1b8UL, + 0x19a4c116b8d2d0c8UL, 0x1e376c085141ab53UL, + 0x2748774cdf8eeb99UL, 0x34b0bcb5e19b48a8UL, + 0x391c0cb3c5c95a63UL, 0x4ed8aa4ae3418acbUL, + 0x5b9cca4f7763e373UL, 0x682e6ff3d6b2b8a3UL, + 0x748f82ee5defb2fcUL, 0x78a5636f43172f60UL, + 0x84c87814a1f0ab72UL, 0x8cc702081a6439ecUL, + 0x90befffa23631e28UL, 0xa4506cebde82bde9UL, + 0xbef9a3f7b2c67915UL, 0xc67178f2e372532bUL, + 0xca273eceea26619cUL, 0xd186b8c721c0c207UL, + 0xeada7dd6cde0eb1eUL, 0xf57d4f7fee6ed178UL, + 0x06f067aa72176fbaUL, 0x0a637dc5a2c898a6UL, + 0x113f9804bef90daeUL, 0x1b710b35131c471bUL, + 0x28db77f523047d84UL, 0x32caab7b40c72493UL, + 0x3c9ebe0a15c9bebcUL, 0x431d67c49c100d4cUL, + 0x4cc5d4becb3e42b6UL, 0x597f299cfc657e2aUL, + 0x5fcb6fab3ad6faecUL, 0x6c44198c4a475817UL +}; + +/* Initial hash value H for SHA-384: */ +static const isc_uint64_t sha384_initial_hash_value[8] = { + 0xcbbb9d5dc1059ed8UL, + 0x629a292a367cd507UL, + 0x9159015a3070dd17UL, + 0x152fecd8f70e5939UL, + 0x67332667ffc00b31UL, + 0x8eb44a8768581511UL, + 0xdb0c2e0d64f98fa7UL, + 0x47b5481dbefa4fa4UL +}; + +/* Initial hash value H for SHA-512: */ +static const isc_uint64_t sha512_initial_hash_value[8] = { + 0x6a09e667f3bcc908U, + 0xbb67ae8584caa73bUL, + 0x3c6ef372fe94f82bUL, + 0xa54ff53a5f1d36f1UL, + 0x510e527fade682d1UL, + 0x9b05688c2b3e6c1fUL, + 0x1f83d9abfb41bd6bUL, + 0x5be0cd19137e2179UL +}; +#else +/* Hash constant words K for SHA-384 and SHA-512: */ +static const isc_uint64_t K512[80] = { + 0x428a2f98d728ae22ULL, 0x7137449123ef65cdULL, + 0xb5c0fbcfec4d3b2fULL, 0xe9b5dba58189dbbcULL, + 0x3956c25bf348b538ULL, 0x59f111f1b605d019ULL, + 0x923f82a4af194f9bULL, 0xab1c5ed5da6d8118ULL, + 0xd807aa98a3030242ULL, 0x12835b0145706fbeULL, + 0x243185be4ee4b28cULL, 0x550c7dc3d5ffb4e2ULL, + 0x72be5d74f27b896fULL, 0x80deb1fe3b1696b1ULL, + 0x9bdc06a725c71235ULL, 0xc19bf174cf692694ULL, + 0xe49b69c19ef14ad2ULL, 0xefbe4786384f25e3ULL, + 0x0fc19dc68b8cd5b5ULL, 0x240ca1cc77ac9c65ULL, + 0x2de92c6f592b0275ULL, 0x4a7484aa6ea6e483ULL, + 0x5cb0a9dcbd41fbd4ULL, 0x76f988da831153b5ULL, + 0x983e5152ee66dfabULL, 0xa831c66d2db43210ULL, + 0xb00327c898fb213fULL, 0xbf597fc7beef0ee4ULL, + 0xc6e00bf33da88fc2ULL, 0xd5a79147930aa725ULL, + 0x06ca6351e003826fULL, 0x142929670a0e6e70ULL, + 0x27b70a8546d22ffcULL, 0x2e1b21385c26c926ULL, + 0x4d2c6dfc5ac42aedULL, 0x53380d139d95b3dfULL, + 0x650a73548baf63deULL, 0x766a0abb3c77b2a8ULL, + 0x81c2c92e47edaee6ULL, 0x92722c851482353bULL, + 0xa2bfe8a14cf10364ULL, 0xa81a664bbc423001ULL, + 0xc24b8b70d0f89791ULL, 0xc76c51a30654be30ULL, + 0xd192e819d6ef5218ULL, 0xd69906245565a910ULL, + 0xf40e35855771202aULL, 0x106aa07032bbd1b8ULL, + 0x19a4c116b8d2d0c8ULL, 0x1e376c085141ab53ULL, + 0x2748774cdf8eeb99ULL, 0x34b0bcb5e19b48a8ULL, + 0x391c0cb3c5c95a63ULL, 0x4ed8aa4ae3418acbULL, + 0x5b9cca4f7763e373ULL, 0x682e6ff3d6b2b8a3ULL, + 0x748f82ee5defb2fcULL, 0x78a5636f43172f60ULL, + 0x84c87814a1f0ab72ULL, 0x8cc702081a6439ecULL, + 0x90befffa23631e28ULL, 0xa4506cebde82bde9ULL, + 0xbef9a3f7b2c67915ULL, 0xc67178f2e372532bULL, + 0xca273eceea26619cULL, 0xd186b8c721c0c207ULL, + 0xeada7dd6cde0eb1eULL, 0xf57d4f7fee6ed178ULL, + 0x06f067aa72176fbaULL, 0x0a637dc5a2c898a6ULL, + 0x113f9804bef90daeULL, 0x1b710b35131c471bULL, + 0x28db77f523047d84ULL, 0x32caab7b40c72493ULL, + 0x3c9ebe0a15c9bebcULL, 0x431d67c49c100d4cULL, + 0x4cc5d4becb3e42b6ULL, 0x597f299cfc657e2aULL, + 0x5fcb6fab3ad6faecULL, 0x6c44198c4a475817ULL +}; + +/* Initial hash value H for SHA-384: */ +static const isc_uint64_t sha384_initial_hash_value[8] = { + 0xcbbb9d5dc1059ed8ULL, + 0x629a292a367cd507ULL, + 0x9159015a3070dd17ULL, + 0x152fecd8f70e5939ULL, + 0x67332667ffc00b31ULL, + 0x8eb44a8768581511ULL, + 0xdb0c2e0d64f98fa7ULL, + 0x47b5481dbefa4fa4ULL +}; + +/* Initial hash value H for SHA-512: */ +static const isc_uint64_t sha512_initial_hash_value[8] = { + 0x6a09e667f3bcc908ULL, + 0xbb67ae8584caa73bULL, + 0x3c6ef372fe94f82bULL, + 0xa54ff53a5f1d36f1ULL, + 0x510e527fade682d1ULL, + 0x9b05688c2b3e6c1fULL, + 0x1f83d9abfb41bd6bULL, + 0x5be0cd19137e2179ULL +}; +#endif + +/* + * Constant used by SHA256/384/512_End() functions for converting the + * digest to a readable hexadecimal character string: + */ +static const char *sha2_hex_digits = "0123456789abcdef"; + + + +/*** SHA-224: *********************************************************/ +void +isc_sha224_init(isc_sha224_t *context) { + if (context == (isc_sha256_t *)0) { + return; + } + memcpy(context->state, sha224_initial_hash_value, + ISC_SHA256_DIGESTLENGTH); + memset(context->buffer, 0, ISC_SHA256_BLOCK_LENGTH); + context->bitcount = 0; +} + +void +isc_sha224_update(isc_sha224_t *context, const isc_uint8_t* data, size_t len) { + isc_sha256_update((isc_sha256_t *)context, data, len); +} + +void +isc_sha224_final(isc_uint8_t digest[], isc_sha224_t *context) { + isc_uint8_t sha256_digest[ISC_SHA256_DIGESTLENGTH]; + isc_sha256_final(sha256_digest, (isc_sha256_t *)context); + memcpy(digest, sha256_digest, ISC_SHA224_DIGESTLENGTH); + memset(sha256_digest, 0, ISC_SHA256_DIGESTLENGTH); +} + +char * +isc_sha224_end(isc_sha224_t *context, char buffer[]) { + isc_uint8_t digest[ISC_SHA224_DIGESTLENGTH], *d = digest; + unsigned int i; + + /* Sanity check: */ + REQUIRE(context != (isc_sha224_t *)0); + + if (buffer != (char*)0) { + isc_sha224_final(digest, context); + + for (i = 0; i < ISC_SHA224_DIGESTLENGTH; i++) { + *buffer++ = sha2_hex_digits[(*d & 0xf0) >> 4]; + *buffer++ = sha2_hex_digits[*d & 0x0f]; + d++; + } + *buffer = (char)0; + } else { + memset(context, 0, sizeof(context)); + } + memset(digest, 0, ISC_SHA224_DIGESTLENGTH); + return buffer; +} + +char* +isc_sha224_data(const isc_uint8_t *data, size_t len, + char digest[ISC_SHA224_DIGESTSTRINGLENGTH]) +{ + isc_sha224_t context; + + isc_sha224_init(&context); + isc_sha224_update(&context, data, len); + return (isc_sha224_end(&context, digest)); +} + +/*** SHA-256: *********************************************************/ +void +isc_sha256_init(isc_sha256_t *context) { + if (context == (isc_sha256_t *)0) { + return; + } + memcpy(context->state, sha256_initial_hash_value, + ISC_SHA256_DIGESTLENGTH); + memset(context->buffer, 0, ISC_SHA256_BLOCK_LENGTH); + context->bitcount = 0; +} + +#ifdef ISC_SHA2_UNROLL_TRANSFORM + +/* Unrolled SHA-256 round macros: */ + +#if BYTE_ORDER == LITTLE_ENDIAN + +#define ROUND256_0_TO_15(a,b,c,d,e,f,g,h) \ + REVERSE32(*data++, W256[j]); \ + T1 = (h) + Sigma1_256(e) + Ch((e), (f), (g)) + \ + K256[j] + W256[j]; \ + (d) += T1; \ + (h) = T1 + Sigma0_256(a) + Maj((a), (b), (c)); \ + j++ + + +#else /* BYTE_ORDER == LITTLE_ENDIAN */ + +#define ROUND256_0_TO_15(a,b,c,d,e,f,g,h) \ + T1 = (h) + Sigma1_256(e) + Ch((e), (f), (g)) + \ + K256[j] + (W256[j] = *data++); \ + (d) += T1; \ + (h) = T1 + Sigma0_256(a) + Maj((a), (b), (c)); \ + j++ + +#endif /* BYTE_ORDER == LITTLE_ENDIAN */ + +#define ROUND256(a,b,c,d,e,f,g,h) \ + s0 = W256[(j+1)&0x0f]; \ + s0 = sigma0_256(s0); \ + s1 = W256[(j+14)&0x0f]; \ + s1 = sigma1_256(s1); \ + T1 = (h) + Sigma1_256(e) + Ch((e), (f), (g)) + K256[j] + \ + (W256[j&0x0f] += s1 + W256[(j+9)&0x0f] + s0); \ + (d) += T1; \ + (h) = T1 + Sigma0_256(a) + Maj((a), (b), (c)); \ + j++ + +void isc_sha256_transform(isc_sha256_t *context, const isc_uint32_t* data) { + isc_uint32_t a, b, c, d, e, f, g, h, s0, s1; + isc_uint32_t T1, *W256; + int j; + + W256 = (isc_uint32_t*)context->buffer; + + /* Initialize registers with the prev. intermediate value */ + a = context->state[0]; + b = context->state[1]; + c = context->state[2]; + d = context->state[3]; + e = context->state[4]; + f = context->state[5]; + g = context->state[6]; + h = context->state[7]; + + j = 0; + do { + /* Rounds 0 to 15 (unrolled): */ + ROUND256_0_TO_15(a,b,c,d,e,f,g,h); + ROUND256_0_TO_15(h,a,b,c,d,e,f,g); + ROUND256_0_TO_15(g,h,a,b,c,d,e,f); + ROUND256_0_TO_15(f,g,h,a,b,c,d,e); + ROUND256_0_TO_15(e,f,g,h,a,b,c,d); + ROUND256_0_TO_15(d,e,f,g,h,a,b,c); + ROUND256_0_TO_15(c,d,e,f,g,h,a,b); + ROUND256_0_TO_15(b,c,d,e,f,g,h,a); + } while (j < 16); + + /* Now for the remaining rounds to 64: */ + do { + ROUND256(a,b,c,d,e,f,g,h); + ROUND256(h,a,b,c,d,e,f,g); + ROUND256(g,h,a,b,c,d,e,f); + ROUND256(f,g,h,a,b,c,d,e); + ROUND256(e,f,g,h,a,b,c,d); + ROUND256(d,e,f,g,h,a,b,c); + ROUND256(c,d,e,f,g,h,a,b); + ROUND256(b,c,d,e,f,g,h,a); + } while (j < 64); + + /* Compute the current intermediate hash value */ + context->state[0] += a; + context->state[1] += b; + context->state[2] += c; + context->state[3] += d; + context->state[4] += e; + context->state[5] += f; + context->state[6] += g; + context->state[7] += h; + + /* Clean up */ + a = b = c = d = e = f = g = h = T1 = 0; +} + +#else /* ISC_SHA2_UNROLL_TRANSFORM */ + +void +isc_sha256_transform(isc_sha256_t *context, const isc_uint32_t* data) { + isc_uint32_t a, b, c, d, e, f, g, h, s0, s1; + isc_uint32_t T1, T2, *W256; + int j; + + W256 = (isc_uint32_t*)context->buffer; + + /* Initialize registers with the prev. intermediate value */ + a = context->state[0]; + b = context->state[1]; + c = context->state[2]; + d = context->state[3]; + e = context->state[4]; + f = context->state[5]; + g = context->state[6]; + h = context->state[7]; + + j = 0; + do { +#if BYTE_ORDER == LITTLE_ENDIAN + /* Copy data while converting to host byte order */ + REVERSE32(*data++,W256[j]); + /* Apply the SHA-256 compression function to update a..h */ + T1 = h + Sigma1_256(e) + Ch(e, f, g) + K256[j] + W256[j]; +#else /* BYTE_ORDER == LITTLE_ENDIAN */ + /* Apply the SHA-256 compression function to update a..h with copy */ + T1 = h + Sigma1_256(e) + Ch(e, f, g) + K256[j] + (W256[j] = *data++); +#endif /* BYTE_ORDER == LITTLE_ENDIAN */ + T2 = Sigma0_256(a) + Maj(a, b, c); + h = g; + g = f; + f = e; + e = d + T1; + d = c; + c = b; + b = a; + a = T1 + T2; + + j++; + } while (j < 16); + + do { + /* Part of the message block expansion: */ + s0 = W256[(j+1)&0x0f]; + s0 = sigma0_256(s0); + s1 = W256[(j+14)&0x0f]; + s1 = sigma1_256(s1); + + /* Apply the SHA-256 compression function to update a..h */ + T1 = h + Sigma1_256(e) + Ch(e, f, g) + K256[j] + + (W256[j&0x0f] += s1 + W256[(j+9)&0x0f] + s0); + T2 = Sigma0_256(a) + Maj(a, b, c); + h = g; + g = f; + f = e; + e = d + T1; + d = c; + c = b; + b = a; + a = T1 + T2; + + j++; + } while (j < 64); + + /* Compute the current intermediate hash value */ + context->state[0] += a; + context->state[1] += b; + context->state[2] += c; + context->state[3] += d; + context->state[4] += e; + context->state[5] += f; + context->state[6] += g; + context->state[7] += h; + + /* Clean up */ + a = b = c = d = e = f = g = h = T1 = T2 = 0; +} + +#endif /* ISC_SHA2_UNROLL_TRANSFORM */ + +void +isc_sha256_update(isc_sha256_t *context, const isc_uint8_t *data, size_t len) { + unsigned int freespace, usedspace; + + if (len == 0U) { + /* Calling with no data is valid - we do nothing */ + return; + } + + /* Sanity check: */ + REQUIRE(context != (isc_sha256_t *)0 && data != (isc_uint8_t*)0); + + usedspace = (unsigned int)((context->bitcount >> 3) % + ISC_SHA256_BLOCK_LENGTH); + if (usedspace > 0) { + /* Calculate how much free space is available in the buffer */ + freespace = ISC_SHA256_BLOCK_LENGTH - usedspace; + + if (len >= freespace) { + /* Fill the buffer completely and process it */ + memcpy(&context->buffer[usedspace], data, freespace); + context->bitcount += freespace << 3; + len -= freespace; + data += freespace; + isc_sha256_transform(context, + (isc_uint32_t*)context->buffer); + } else { + /* The buffer is not yet full */ + memcpy(&context->buffer[usedspace], data, len); + context->bitcount += len << 3; + /* Clean up: */ + usedspace = freespace = 0; + return; + } + } + while (len >= ISC_SHA256_BLOCK_LENGTH) { + /* Process as many complete blocks as we can */ + memcpy(context->buffer, data, ISC_SHA256_BLOCK_LENGTH); + isc_sha256_transform(context, (isc_uint32_t*)context->buffer); + context->bitcount += ISC_SHA256_BLOCK_LENGTH << 3; + len -= ISC_SHA256_BLOCK_LENGTH; + data += ISC_SHA256_BLOCK_LENGTH; + } + if (len > 0U) { + /* There's left-overs, so save 'em */ + memcpy(context->buffer, data, len); + context->bitcount += len << 3; + } + /* Clean up: */ + usedspace = freespace = 0; +} + +void +isc_sha256_final(isc_uint8_t digest[], isc_sha256_t *context) { + isc_uint32_t *d = (isc_uint32_t*)digest; + unsigned int usedspace; + + /* Sanity check: */ + REQUIRE(context != (isc_sha256_t *)0); + + /* If no digest buffer is passed, we don't bother doing this: */ + if (digest != (isc_uint8_t*)0) { + usedspace = (unsigned int)((context->bitcount >> 3) % + ISC_SHA256_BLOCK_LENGTH); +#if BYTE_ORDER == LITTLE_ENDIAN + /* Convert FROM host byte order */ + REVERSE64(context->bitcount,context->bitcount); +#endif + if (usedspace > 0) { + /* Begin padding with a 1 bit: */ + context->buffer[usedspace++] = 0x80; + + if (usedspace <= ISC_SHA256_SHORT_BLOCK_LENGTH) { + /* Set-up for the last transform: */ + memset(&context->buffer[usedspace], 0, + ISC_SHA256_SHORT_BLOCK_LENGTH - usedspace); + } else { + if (usedspace < ISC_SHA256_BLOCK_LENGTH) { + memset(&context->buffer[usedspace], 0, + ISC_SHA256_BLOCK_LENGTH - + usedspace); + } + /* Do second-to-last transform: */ + isc_sha256_transform(context, + (isc_uint32_t*)context->buffer); + + /* And set-up for the last transform: */ + memset(context->buffer, 0, + ISC_SHA256_SHORT_BLOCK_LENGTH); + } + } else { + /* Set-up for the last transform: */ + memset(context->buffer, 0, ISC_SHA256_SHORT_BLOCK_LENGTH); + + /* Begin padding with a 1 bit: */ + *context->buffer = 0x80; + } + /* Set the bit count: */ + *(isc_uint64_t*)&context->buffer[ISC_SHA256_SHORT_BLOCK_LENGTH] = context->bitcount; + + /* Final transform: */ + isc_sha256_transform(context, (isc_uint32_t*)context->buffer); + +#if BYTE_ORDER == LITTLE_ENDIAN + { + /* Convert TO host byte order */ + int j; + for (j = 0; j < 8; j++) { + REVERSE32(context->state[j],context->state[j]); + *d++ = context->state[j]; + } + } +#else + memcpy(d, context->state, ISC_SHA256_DIGESTLENGTH); +#endif + } + + /* Clean up state data: */ + memset(context, 0, sizeof(context)); + usedspace = 0; +} + +char * +isc_sha256_end(isc_sha256_t *context, char buffer[]) { + isc_uint8_t digest[ISC_SHA256_DIGESTLENGTH], *d = digest; + unsigned int i; + + /* Sanity check: */ + REQUIRE(context != (isc_sha256_t *)0); + + if (buffer != (char*)0) { + isc_sha256_final(digest, context); + + for (i = 0; i < ISC_SHA256_DIGESTLENGTH; i++) { + *buffer++ = sha2_hex_digits[(*d & 0xf0) >> 4]; + *buffer++ = sha2_hex_digits[*d & 0x0f]; + d++; + } + *buffer = (char)0; + } else { + memset(context, 0, sizeof(context)); + } + memset(digest, 0, ISC_SHA256_DIGESTLENGTH); + return buffer; +} + +char * +isc_sha256_data(const isc_uint8_t* data, size_t len, + char digest[ISC_SHA256_DIGESTSTRINGLENGTH]) +{ + isc_sha256_t context; + + isc_sha256_init(&context); + isc_sha256_update(&context, data, len); + return (isc_sha256_end(&context, digest)); +} + + +/*** SHA-512: *********************************************************/ +void +isc_sha512_init(isc_sha512_t *context) { + if (context == (isc_sha512_t *)0) { + return; + } + memcpy(context->state, sha512_initial_hash_value, + ISC_SHA512_DIGESTLENGTH); + memset(context->buffer, 0, ISC_SHA512_BLOCK_LENGTH); + context->bitcount[0] = context->bitcount[1] = 0; +} + +#ifdef ISC_SHA2_UNROLL_TRANSFORM + +/* Unrolled SHA-512 round macros: */ +#if BYTE_ORDER == LITTLE_ENDIAN + +#define ROUND512_0_TO_15(a,b,c,d,e,f,g,h) \ + REVERSE64(*data++, W512[j]); \ + T1 = (h) + Sigma1_512(e) + Ch((e), (f), (g)) + \ + K512[j] + W512[j]; \ + (d) += T1, \ + (h) = T1 + Sigma0_512(a) + Maj((a), (b), (c)), \ + j++ + + +#else /* BYTE_ORDER == LITTLE_ENDIAN */ + +#define ROUND512_0_TO_15(a,b,c,d,e,f,g,h) \ + T1 = (h) + Sigma1_512(e) + Ch((e), (f), (g)) + \ + K512[j] + (W512[j] = *data++); \ + (d) += T1; \ + (h) = T1 + Sigma0_512(a) + Maj((a), (b), (c)); \ + j++ + +#endif /* BYTE_ORDER == LITTLE_ENDIAN */ + +#define ROUND512(a,b,c,d,e,f,g,h) \ + s0 = W512[(j+1)&0x0f]; \ + s0 = sigma0_512(s0); \ + s1 = W512[(j+14)&0x0f]; \ + s1 = sigma1_512(s1); \ + T1 = (h) + Sigma1_512(e) + Ch((e), (f), (g)) + K512[j] + \ + (W512[j&0x0f] += s1 + W512[(j+9)&0x0f] + s0); \ + (d) += T1; \ + (h) = T1 + Sigma0_512(a) + Maj((a), (b), (c)); \ + j++ + +void isc_sha512_transform(isc_sha512_t *context, const isc_uint64_t* data) { + isc_uint64_t a, b, c, d, e, f, g, h, s0, s1; + isc_uint64_t T1, *W512 = (isc_uint64_t*)context->buffer; + int j; + + /* Initialize registers with the prev. intermediate value */ + a = context->state[0]; + b = context->state[1]; + c = context->state[2]; + d = context->state[3]; + e = context->state[4]; + f = context->state[5]; + g = context->state[6]; + h = context->state[7]; + + j = 0; + do { + ROUND512_0_TO_15(a,b,c,d,e,f,g,h); + ROUND512_0_TO_15(h,a,b,c,d,e,f,g); + ROUND512_0_TO_15(g,h,a,b,c,d,e,f); + ROUND512_0_TO_15(f,g,h,a,b,c,d,e); + ROUND512_0_TO_15(e,f,g,h,a,b,c,d); + ROUND512_0_TO_15(d,e,f,g,h,a,b,c); + ROUND512_0_TO_15(c,d,e,f,g,h,a,b); + ROUND512_0_TO_15(b,c,d,e,f,g,h,a); + } while (j < 16); + + /* Now for the remaining rounds up to 79: */ + do { + ROUND512(a,b,c,d,e,f,g,h); + ROUND512(h,a,b,c,d,e,f,g); + ROUND512(g,h,a,b,c,d,e,f); + ROUND512(f,g,h,a,b,c,d,e); + ROUND512(e,f,g,h,a,b,c,d); + ROUND512(d,e,f,g,h,a,b,c); + ROUND512(c,d,e,f,g,h,a,b); + ROUND512(b,c,d,e,f,g,h,a); + } while (j < 80); + + /* Compute the current intermediate hash value */ + context->state[0] += a; + context->state[1] += b; + context->state[2] += c; + context->state[3] += d; + context->state[4] += e; + context->state[5] += f; + context->state[6] += g; + context->state[7] += h; + + /* Clean up */ + a = b = c = d = e = f = g = h = T1 = 0; +} + +#else /* ISC_SHA2_UNROLL_TRANSFORM */ + +void +isc_sha512_transform(isc_sha512_t *context, const isc_uint64_t* data) { + isc_uint64_t a, b, c, d, e, f, g, h, s0, s1; + isc_uint64_t T1, T2, *W512 = (isc_uint64_t*)context->buffer; + int j; + + /* Initialize registers with the prev. intermediate value */ + a = context->state[0]; + b = context->state[1]; + c = context->state[2]; + d = context->state[3]; + e = context->state[4]; + f = context->state[5]; + g = context->state[6]; + h = context->state[7]; + + j = 0; + do { +#if BYTE_ORDER == LITTLE_ENDIAN + /* Convert TO host byte order */ + REVERSE64(*data++, W512[j]); + /* Apply the SHA-512 compression function to update a..h */ + T1 = h + Sigma1_512(e) + Ch(e, f, g) + K512[j] + W512[j]; +#else /* BYTE_ORDER == LITTLE_ENDIAN */ + /* Apply the SHA-512 compression function to update a..h with copy */ + T1 = h + Sigma1_512(e) + Ch(e, f, g) + K512[j] + (W512[j] = *data++); +#endif /* BYTE_ORDER == LITTLE_ENDIAN */ + T2 = Sigma0_512(a) + Maj(a, b, c); + h = g; + g = f; + f = e; + e = d + T1; + d = c; + c = b; + b = a; + a = T1 + T2; + + j++; + } while (j < 16); + + do { + /* Part of the message block expansion: */ + s0 = W512[(j+1)&0x0f]; + s0 = sigma0_512(s0); + s1 = W512[(j+14)&0x0f]; + s1 = sigma1_512(s1); + + /* Apply the SHA-512 compression function to update a..h */ + T1 = h + Sigma1_512(e) + Ch(e, f, g) + K512[j] + + (W512[j&0x0f] += s1 + W512[(j+9)&0x0f] + s0); + T2 = Sigma0_512(a) + Maj(a, b, c); + h = g; + g = f; + f = e; + e = d + T1; + d = c; + c = b; + b = a; + a = T1 + T2; + + j++; + } while (j < 80); + + /* Compute the current intermediate hash value */ + context->state[0] += a; + context->state[1] += b; + context->state[2] += c; + context->state[3] += d; + context->state[4] += e; + context->state[5] += f; + context->state[6] += g; + context->state[7] += h; + + /* Clean up */ + a = b = c = d = e = f = g = h = T1 = T2 = 0; +} + +#endif /* ISC_SHA2_UNROLL_TRANSFORM */ + +void isc_sha512_update(isc_sha512_t *context, const isc_uint8_t *data, size_t len) { + unsigned int freespace, usedspace; + + if (len == 0U) { + /* Calling with no data is valid - we do nothing */ + return; + } + + /* Sanity check: */ + REQUIRE(context != (isc_sha512_t *)0 && data != (isc_uint8_t*)0); + + usedspace = (unsigned int)((context->bitcount[0] >> 3) % + ISC_SHA512_BLOCK_LENGTH); + if (usedspace > 0) { + /* Calculate how much free space is available in the buffer */ + freespace = ISC_SHA512_BLOCK_LENGTH - usedspace; + + if (len >= freespace) { + /* Fill the buffer completely and process it */ + memcpy(&context->buffer[usedspace], data, freespace); + ADDINC128(context->bitcount, freespace << 3); + len -= freespace; + data += freespace; + isc_sha512_transform(context, + (isc_uint64_t*)context->buffer); + } else { + /* The buffer is not yet full */ + memcpy(&context->buffer[usedspace], data, len); + ADDINC128(context->bitcount, len << 3); + /* Clean up: */ + usedspace = freespace = 0; + return; + } + } + while (len >= ISC_SHA512_BLOCK_LENGTH) { + /* Process as many complete blocks as we can */ + memcpy(context->buffer, data, ISC_SHA512_BLOCK_LENGTH); + isc_sha512_transform(context, (isc_uint64_t*)context->buffer); + ADDINC128(context->bitcount, ISC_SHA512_BLOCK_LENGTH << 3); + len -= ISC_SHA512_BLOCK_LENGTH; + data += ISC_SHA512_BLOCK_LENGTH; + } + if (len > 0U) { + /* There's left-overs, so save 'em */ + memcpy(context->buffer, data, len); + ADDINC128(context->bitcount, len << 3); + } + /* Clean up: */ + usedspace = freespace = 0; +} + +void isc_sha512_last(isc_sha512_t *context) { + unsigned int usedspace; + + usedspace = (unsigned int)((context->bitcount[0] >> 3) % + ISC_SHA512_BLOCK_LENGTH); +#if BYTE_ORDER == LITTLE_ENDIAN + /* Convert FROM host byte order */ + REVERSE64(context->bitcount[0],context->bitcount[0]); + REVERSE64(context->bitcount[1],context->bitcount[1]); +#endif + if (usedspace > 0) { + /* Begin padding with a 1 bit: */ + context->buffer[usedspace++] = 0x80; + + if (usedspace <= ISC_SHA512_SHORT_BLOCK_LENGTH) { + /* Set-up for the last transform: */ + memset(&context->buffer[usedspace], 0, + ISC_SHA512_SHORT_BLOCK_LENGTH - usedspace); + } else { + if (usedspace < ISC_SHA512_BLOCK_LENGTH) { + memset(&context->buffer[usedspace], 0, + ISC_SHA512_BLOCK_LENGTH - usedspace); + } + /* Do second-to-last transform: */ + isc_sha512_transform(context, + (isc_uint64_t*)context->buffer); + + /* And set-up for the last transform: */ + memset(context->buffer, 0, ISC_SHA512_BLOCK_LENGTH - 2); + } + } else { + /* Prepare for final transform: */ + memset(context->buffer, 0, ISC_SHA512_SHORT_BLOCK_LENGTH); + + /* Begin padding with a 1 bit: */ + *context->buffer = 0x80; + } + /* Store the length of input data (in bits): */ + *(isc_uint64_t*)&context->buffer[ISC_SHA512_SHORT_BLOCK_LENGTH] = context->bitcount[1]; + *(isc_uint64_t*)&context->buffer[ISC_SHA512_SHORT_BLOCK_LENGTH+8] = context->bitcount[0]; + + /* Final transform: */ + isc_sha512_transform(context, (isc_uint64_t*)context->buffer); +} + +void isc_sha512_final(isc_uint8_t digest[], isc_sha512_t *context) { + isc_uint64_t *d = (isc_uint64_t*)digest; + + /* Sanity check: */ + REQUIRE(context != (isc_sha512_t *)0); + + /* If no digest buffer is passed, we don't bother doing this: */ + if (digest != (isc_uint8_t*)0) { + isc_sha512_last(context); + + /* Save the hash data for output: */ +#if BYTE_ORDER == LITTLE_ENDIAN + { + /* Convert TO host byte order */ + int j; + for (j = 0; j < 8; j++) { + REVERSE64(context->state[j],context->state[j]); + *d++ = context->state[j]; + } + } +#else + memcpy(d, context->state, ISC_SHA512_DIGESTLENGTH); +#endif + } + + /* Zero out state data */ + memset(context, 0, sizeof(context)); +} + +char * +isc_sha512_end(isc_sha512_t *context, char buffer[]) { + isc_uint8_t digest[ISC_SHA512_DIGESTLENGTH], *d = digest; + unsigned int i; + + /* Sanity check: */ + REQUIRE(context != (isc_sha512_t *)0); + + if (buffer != (char*)0) { + isc_sha512_final(digest, context); + + for (i = 0; i < ISC_SHA512_DIGESTLENGTH; i++) { + *buffer++ = sha2_hex_digits[(*d & 0xf0) >> 4]; + *buffer++ = sha2_hex_digits[*d & 0x0f]; + d++; + } + *buffer = (char)0; + } else { + memset(context, 0, sizeof(context)); + } + memset(digest, 0, ISC_SHA512_DIGESTLENGTH); + return buffer; +} + +char * +isc_sha512_data(const isc_uint8_t *data, size_t len, + char digest[ISC_SHA512_DIGESTSTRINGLENGTH]) +{ + isc_sha512_t context; + + isc_sha512_init(&context); + isc_sha512_update(&context, data, len); + return (isc_sha512_end(&context, digest)); +} + + +/*** SHA-384: *********************************************************/ +void +isc_sha384_init(isc_sha384_t *context) { + if (context == (isc_sha384_t *)0) { + return; + } + memcpy(context->state, sha384_initial_hash_value, + ISC_SHA512_DIGESTLENGTH); + memset(context->buffer, 0, ISC_SHA384_BLOCK_LENGTH); + context->bitcount[0] = context->bitcount[1] = 0; +} + +void +isc_sha384_update(isc_sha384_t *context, const isc_uint8_t* data, size_t len) { + isc_sha512_update((isc_sha512_t *)context, data, len); +} + +void +isc_sha384_final(isc_uint8_t digest[], isc_sha384_t *context) { + isc_uint64_t *d = (isc_uint64_t*)digest; + + /* Sanity check: */ + REQUIRE(context != (isc_sha384_t *)0); + + /* If no digest buffer is passed, we don't bother doing this: */ + if (digest != (isc_uint8_t*)0) { + isc_sha512_last((isc_sha512_t *)context); + + /* Save the hash data for output: */ +#if BYTE_ORDER == LITTLE_ENDIAN + { + /* Convert TO host byte order */ + int j; + for (j = 0; j < 6; j++) { + REVERSE64(context->state[j],context->state[j]); + *d++ = context->state[j]; + } + } +#else + memcpy(d, context->state, ISC_SHA384_DIGESTLENGTH); +#endif + } + + /* Zero out state data */ + memset(context, 0, sizeof(context)); +} + +char * +isc_sha384_end(isc_sha384_t *context, char buffer[]) { + isc_uint8_t digest[ISC_SHA384_DIGESTLENGTH], *d = digest; + unsigned int i; + + /* Sanity check: */ + REQUIRE(context != (isc_sha384_t *)0); + + if (buffer != (char*)0) { + isc_sha384_final(digest, context); + + for (i = 0; i < ISC_SHA384_DIGESTLENGTH; i++) { + *buffer++ = sha2_hex_digits[(*d & 0xf0) >> 4]; + *buffer++ = sha2_hex_digits[*d & 0x0f]; + d++; + } + *buffer = (char)0; + } else { + memset(context, 0, sizeof(context)); + } + memset(digest, 0, ISC_SHA384_DIGESTLENGTH); + return buffer; +} + +char* +isc_sha384_data(const isc_uint8_t *data, size_t len, + char digest[ISC_SHA384_DIGESTSTRINGLENGTH]) +{ + isc_sha384_t context; + + isc_sha384_init(&context); + isc_sha384_update(&context, data, len); + return (isc_sha384_end(&context, digest)); +} diff -urN src/contrib/ntp/lib/isc/sockaddr.c src.ntp/contrib/ntp/lib/isc/sockaddr.c --- src/contrib/ntp/lib/isc/sockaddr.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/sockaddr.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,503 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: sockaddr.c,v 1.70 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include + +isc_boolean_t +isc_sockaddr_equal(const isc_sockaddr_t *a, const isc_sockaddr_t *b) { + return (isc_sockaddr_compare(a, b, ISC_SOCKADDR_CMPADDR| + ISC_SOCKADDR_CMPPORT| + ISC_SOCKADDR_CMPSCOPE)); +} + +isc_boolean_t +isc_sockaddr_eqaddr(const isc_sockaddr_t *a, const isc_sockaddr_t *b) { + return (isc_sockaddr_compare(a, b, ISC_SOCKADDR_CMPADDR| + ISC_SOCKADDR_CMPSCOPE)); +} + +isc_boolean_t +isc_sockaddr_compare(const isc_sockaddr_t *a, const isc_sockaddr_t *b, + unsigned int flags) +{ + REQUIRE(a != NULL && b != NULL); + + if (a->length != b->length) + return (ISC_FALSE); + + /* + * We don't just memcmp because the sin_zero field isn't always + * zero. + */ + + if (a->type.sa.sa_family != b->type.sa.sa_family) + return (ISC_FALSE); + switch (a->type.sa.sa_family) { + case AF_INET: + if ((flags & ISC_SOCKADDR_CMPADDR) != 0 && + memcmp(&a->type.sin.sin_addr, &b->type.sin.sin_addr, + sizeof(a->type.sin.sin_addr)) != 0) + return (ISC_FALSE); + if ((flags & ISC_SOCKADDR_CMPPORT) != 0 && + a->type.sin.sin_port != b->type.sin.sin_port) + return (ISC_FALSE); + break; + case AF_INET6: + if ((flags & ISC_SOCKADDR_CMPADDR) != 0 && + memcmp(&a->type.sin6.sin6_addr, &b->type.sin6.sin6_addr, + sizeof(a->type.sin6.sin6_addr)) != 0) + return (ISC_FALSE); +#ifdef ISC_PLATFORM_HAVESCOPEID + /* + * If ISC_SOCKADDR_CMPSCOPEZERO is set then don't return + * ISC_FALSE if one of the scopes in zero. + */ + if ((flags & ISC_SOCKADDR_CMPSCOPE) != 0 && + a->type.sin6.sin6_scope_id != b->type.sin6.sin6_scope_id && + ((flags & ISC_SOCKADDR_CMPSCOPEZERO) == 0 || + (a->type.sin6.sin6_scope_id != 0 && + b->type.sin6.sin6_scope_id != 0))) + return (ISC_FALSE); +#endif + if ((flags & ISC_SOCKADDR_CMPPORT) != 0 && + a->type.sin6.sin6_port != b->type.sin6.sin6_port) + return (ISC_FALSE); + break; + default: + if (memcmp(&a->type, &b->type, a->length) != 0) + return (ISC_FALSE); + } + return (ISC_TRUE); +} + +isc_boolean_t +isc_sockaddr_eqaddrprefix(const isc_sockaddr_t *a, const isc_sockaddr_t *b, + unsigned int prefixlen) +{ + isc_netaddr_t na, nb; + isc_netaddr_fromsockaddr(&na, a); + isc_netaddr_fromsockaddr(&nb, b); + return (isc_netaddr_eqprefix(&na, &nb, prefixlen)); +} + +isc_result_t +isc_sockaddr_totext(const isc_sockaddr_t *sockaddr, isc_buffer_t *target) { + isc_result_t result; + isc_netaddr_t netaddr; + char pbuf[sizeof("65000")]; + unsigned int plen; + isc_region_t avail; + + REQUIRE(sockaddr != NULL); + + /* + * Do the port first, giving us the opportunity to check for + * unsupported address families before calling + * isc_netaddr_fromsockaddr(). + */ + switch (sockaddr->type.sa.sa_family) { + case AF_INET: + snprintf(pbuf, sizeof(pbuf), "%u", ntohs(sockaddr->type.sin.sin_port)); + break; + case AF_INET6: + snprintf(pbuf, sizeof(pbuf), "%u", ntohs(sockaddr->type.sin6.sin6_port)); + break; +#ifdef ISC_PLAFORM_HAVESYSUNH + case AF_UNIX: + plen = strlen(sockaddr->type.sunix.sun_path); + if (plen >= isc_buffer_availablelength(target)) + return (ISC_R_NOSPACE); + + isc_buffer_putmem(target, sockaddr->type.sunix.sun_path, plen); + + /* + * Null terminate after used region. + */ + isc_buffer_availableregion(target, &avail); + INSIST(avail.length >= 1); + avail.base[0] = '\0'; + + return (ISC_R_SUCCESS); +#endif + default: + return (ISC_R_FAILURE); + } + + plen = strlen(pbuf); + INSIST(plen < sizeof(pbuf)); + + isc_netaddr_fromsockaddr(&netaddr, sockaddr); + result = isc_netaddr_totext(&netaddr, target); + if (result != ISC_R_SUCCESS) + return (result); + + if (1 + plen + 1 > isc_buffer_availablelength(target)) + return (ISC_R_NOSPACE); + + isc_buffer_putmem(target, (const unsigned char *)"#", 1); + isc_buffer_putmem(target, (const unsigned char *)pbuf, plen); + + /* + * Null terminate after used region. + */ + isc_buffer_availableregion(target, &avail); + INSIST(avail.length >= 1); + avail.base[0] = '\0'; + + return (ISC_R_SUCCESS); +} + +void +isc_sockaddr_format(const isc_sockaddr_t *sa, char *array, unsigned int size) { + isc_result_t result; + isc_buffer_t buf; + + isc_buffer_init(&buf, array, size); + result = isc_sockaddr_totext(sa, &buf); + if (result != ISC_R_SUCCESS) { + /* + * The message is the same as in netaddr.c. + */ + snprintf(array, size, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_NETADDR, + ISC_MSG_UNKNOWNADDR, + ""), + sa->type.sa.sa_family); + array[size - 1] = '\0'; + } +} + +unsigned int +isc_sockaddr_hash(const isc_sockaddr_t *sockaddr, isc_boolean_t address_only) { + unsigned int length = 0; + const unsigned char *s = NULL; + unsigned int h = 0; + unsigned int g; + unsigned int p = 0; + const struct in6_addr *in6; + + REQUIRE(sockaddr != NULL); + + switch (sockaddr->type.sa.sa_family) { + case AF_INET: + s = (const unsigned char *)&sockaddr->type.sin.sin_addr; + p = ntohs(sockaddr->type.sin.sin_port); + length = sizeof(sockaddr->type.sin.sin_addr.s_addr); + break; + case AF_INET6: + in6 = &sockaddr->type.sin6.sin6_addr; + if (IN6_IS_ADDR_V4MAPPED(in6)) { + s = (const unsigned char *)&in6[12]; + length = sizeof(sockaddr->type.sin.sin_addr.s_addr); + } else { + s = (const unsigned char *)in6; + length = sizeof(sockaddr->type.sin6.sin6_addr); + } + p = ntohs(sockaddr->type.sin6.sin6_port); + break; + default: + UNEXPECTED_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_SOCKADDR, + ISC_MSG_UNKNOWNFAMILY, + "unknown address family: %d"), + (int)sockaddr->type.sa.sa_family); + s = (const unsigned char *)&sockaddr->type; + length = sockaddr->length; + p = 0; + } + + h = isc_hash_calc(s, length, ISC_TRUE); + if (!address_only) { + g = isc_hash_calc((const unsigned char *)&p, sizeof(p), + ISC_TRUE); + h = h ^ g; /* XXX: we should concatenate h and p first */ + } + + return (h); +} + +void +isc_sockaddr_any(isc_sockaddr_t *sockaddr) +{ + memset(sockaddr, 0, sizeof(*sockaddr)); + sockaddr->type.sin.sin_family = AF_INET; +#ifdef ISC_PLATFORM_HAVESALEN + sockaddr->type.sin.sin_len = sizeof(sockaddr->type.sin); +#endif + sockaddr->type.sin.sin_addr.s_addr = INADDR_ANY; + sockaddr->type.sin.sin_port = 0; + sockaddr->length = sizeof(sockaddr->type.sin); + ISC_LINK_INIT(sockaddr, link); +} + +void +isc_sockaddr_any6(isc_sockaddr_t *sockaddr) +{ + memset(sockaddr, 0, sizeof(*sockaddr)); + sockaddr->type.sin6.sin6_family = AF_INET6; +#ifdef ISC_PLATFORM_HAVESALEN + sockaddr->type.sin6.sin6_len = sizeof(sockaddr->type.sin6); +#endif + sockaddr->type.sin6.sin6_addr = in6addr_any; + sockaddr->type.sin6.sin6_port = 0; + sockaddr->length = sizeof(sockaddr->type.sin6); + ISC_LINK_INIT(sockaddr, link); +} + +void +isc_sockaddr_fromin(isc_sockaddr_t *sockaddr, const struct in_addr *ina, + in_port_t port) +{ + memset(sockaddr, 0, sizeof(*sockaddr)); + sockaddr->type.sin.sin_family = AF_INET; +#ifdef ISC_PLATFORM_HAVESALEN + sockaddr->type.sin.sin_len = sizeof(sockaddr->type.sin); +#endif + sockaddr->type.sin.sin_addr = *ina; + sockaddr->type.sin.sin_port = htons(port); + sockaddr->length = sizeof(sockaddr->type.sin); + ISC_LINK_INIT(sockaddr, link); +} + +void +isc_sockaddr_anyofpf(isc_sockaddr_t *sockaddr, int pf) { + switch (pf) { + case AF_INET: + isc_sockaddr_any(sockaddr); + break; + case AF_INET6: + isc_sockaddr_any6(sockaddr); + break; + default: + INSIST(0); + } +} + +void +isc_sockaddr_fromin6(isc_sockaddr_t *sockaddr, const struct in6_addr *ina6, + in_port_t port) +{ + memset(sockaddr, 0, sizeof(*sockaddr)); + sockaddr->type.sin6.sin6_family = AF_INET6; +#ifdef ISC_PLATFORM_HAVESALEN + sockaddr->type.sin6.sin6_len = sizeof(sockaddr->type.sin6); +#endif + sockaddr->type.sin6.sin6_addr = *ina6; + sockaddr->type.sin6.sin6_port = htons(port); + sockaddr->length = sizeof(sockaddr->type.sin6); + ISC_LINK_INIT(sockaddr, link); +} + +void +isc_sockaddr_v6fromin(isc_sockaddr_t *sockaddr, const struct in_addr *ina, + in_port_t port) +{ + memset(sockaddr, 0, sizeof(*sockaddr)); + sockaddr->type.sin6.sin6_family = AF_INET6; +#ifdef ISC_PLATFORM_HAVESALEN + sockaddr->type.sin6.sin6_len = sizeof(sockaddr->type.sin6); +#endif + sockaddr->type.sin6.sin6_addr.s6_addr[10] = 0xff; + sockaddr->type.sin6.sin6_addr.s6_addr[11] = 0xff; + memcpy(&sockaddr->type.sin6.sin6_addr.s6_addr[12], ina, 4); + sockaddr->type.sin6.sin6_port = htons(port); + sockaddr->length = sizeof(sockaddr->type.sin6); + ISC_LINK_INIT(sockaddr, link); +} + +int +isc_sockaddr_pf(const isc_sockaddr_t *sockaddr) { + + /* + * Get the protocol family of 'sockaddr'. + */ + +#if (AF_INET == PF_INET && AF_INET6 == PF_INET6) + /* + * Assume that PF_xxx == AF_xxx for all AF and PF. + */ + return (sockaddr->type.sa.sa_family); +#else + switch (sockaddr->type.sa.sa_family) { + case AF_INET: + return (PF_INET); + case AF_INET6: + return (PF_INET6); + default: + FATAL_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKADDR, + ISC_MSG_UNKNOWNFAMILY, + "unknown address family: %d"), + (int)sockaddr->type.sa.sa_family); + } +#endif +} + +void +isc_sockaddr_fromnetaddr(isc_sockaddr_t *sockaddr, const isc_netaddr_t *na, + in_port_t port) +{ + memset(sockaddr, 0, sizeof(*sockaddr)); + sockaddr->type.sin.sin_family = (short)na->family; + switch (na->family) { + case AF_INET: + sockaddr->length = sizeof(sockaddr->type.sin); +#ifdef ISC_PLATFORM_HAVESALEN + sockaddr->type.sin.sin_len = sizeof(sockaddr->type.sin); +#endif + sockaddr->type.sin.sin_addr = na->type.in; + sockaddr->type.sin.sin_port = htons(port); + break; + case AF_INET6: + sockaddr->length = sizeof(sockaddr->type.sin6); +#ifdef ISC_PLATFORM_HAVESALEN + sockaddr->type.sin6.sin6_len = sizeof(sockaddr->type.sin6); +#endif + memcpy(&sockaddr->type.sin6.sin6_addr, &na->type.in6, 16); +#ifdef ISC_PLATFORM_HAVESCOPEID + sockaddr->type.sin6.sin6_scope_id = isc_netaddr_getzone(na); +#endif + sockaddr->type.sin6.sin6_port = htons(port); + break; + default: + INSIST(0); + } + ISC_LINK_INIT(sockaddr, link); +} + +void +isc_sockaddr_setport(isc_sockaddr_t *sockaddr, in_port_t port) { + switch (sockaddr->type.sa.sa_family) { + case AF_INET: + sockaddr->type.sin.sin_port = htons(port); + break; + case AF_INET6: + sockaddr->type.sin6.sin6_port = htons(port); + break; + default: + FATAL_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKADDR, + ISC_MSG_UNKNOWNFAMILY, + "unknown address family: %d"), + (int)sockaddr->type.sa.sa_family); + } +} + +in_port_t +isc_sockaddr_getport(const isc_sockaddr_t *sockaddr) { + in_port_t port = 0; + + switch (sockaddr->type.sa.sa_family) { + case AF_INET: + port = ntohs(sockaddr->type.sin.sin_port); + break; + case AF_INET6: + port = ntohs(sockaddr->type.sin6.sin6_port); + break; + default: + FATAL_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKADDR, + ISC_MSG_UNKNOWNFAMILY, + "unknown address family: %d"), + (int)sockaddr->type.sa.sa_family); + } + + return (port); +} + +isc_boolean_t +isc_sockaddr_ismulticast(const isc_sockaddr_t *sockaddr) { + isc_netaddr_t netaddr; + + if (sockaddr->type.sa.sa_family == AF_INET || + sockaddr->type.sa.sa_family == AF_INET6) { + isc_netaddr_fromsockaddr(&netaddr, sockaddr); + return (isc_netaddr_ismulticast(&netaddr)); + } + return (ISC_FALSE); +} + +isc_boolean_t +isc_sockaddr_isexperimental(const isc_sockaddr_t *sockaddr) { + isc_netaddr_t netaddr; + + if (sockaddr->type.sa.sa_family == AF_INET) { + isc_netaddr_fromsockaddr(&netaddr, sockaddr); + return (isc_netaddr_isexperimental(&netaddr)); + } + return (ISC_FALSE); +} + +isc_boolean_t +isc_sockaddr_issitelocal(const isc_sockaddr_t *sockaddr) { + isc_netaddr_t netaddr; + + if (sockaddr->type.sa.sa_family == AF_INET6) { + isc_netaddr_fromsockaddr(&netaddr, sockaddr); + return (isc_netaddr_issitelocal(&netaddr)); + } + return (ISC_FALSE); +} + +isc_boolean_t +isc_sockaddr_islinklocal(const isc_sockaddr_t *sockaddr) { + isc_netaddr_t netaddr; + + if (sockaddr->type.sa.sa_family == AF_INET6) { + isc_netaddr_fromsockaddr(&netaddr, sockaddr); + return (isc_netaddr_islinklocal(&netaddr)); + } + return (ISC_FALSE); +} + +isc_result_t +isc_sockaddr_frompath(isc_sockaddr_t *sockaddr, const char *path) { +#ifdef ISC_PLATFORM_HAVESYSUNH + if (strlen(path) >= sizeof(sockaddr->type.sunix.sun_path)) + return (ISC_R_NOSPACE); + memset(sockaddr, 0, sizeof(*sockaddr)); + sockaddr->length = sizeof(sockaddr->type.sunix); + sockaddr->type.sunix.sun_family = AF_UNIX; +#ifdef ISC_PLATFORM_HAVESALEN + sockaddr->type.sunix.sun_len = + (unsigned char)sizeof(sockaddr->type.sunix); +#endif + strcpy(sockaddr->type.sunix.sun_path, path); + return (ISC_R_SUCCESS); +#else + UNUSED(sockaddr); + UNUSED(path); + return (ISC_R_NOTIMPLEMENTED); +#endif +} diff -urN src/contrib/ntp/lib/isc/sparc64/include/isc/atomic.h src.ntp/contrib/ntp/lib/isc/sparc64/include/isc/atomic.h --- src/contrib/ntp/lib/isc/sparc64/include/isc/atomic.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/sparc64/include/isc/atomic.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,127 @@ +/* + * Copyright (C) 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: atomic.h,v 1.5 2007/06/19 23:47:18 tbox Exp $ */ + +/* + * This code was written based on FreeBSD's kernel source whose copyright + * follows: + */ + +/*- + * Copyright (c) 1998 Doug Rabson. + * Copyright (c) 2001 Jake Burkholder. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * from: FreeBSD: src/sys/i386/include/atomic.h,v 1.20 2001/02/11 + * $FreeBSD: src/sys/sparc64/include/atomic.h,v 1.8 2004/05/22 00:52:16 marius Exp $ + */ + +#ifndef ISC_ATOMIC_H +#define ISC_ATOMIC_H 1 + +#include +#include + +#define ASI_P 0x80 /* Primary Address Space Identifier */ + +#ifdef ISC_PLATFORM_USEGCCASM + +/* + * This routine atomically increments the value stored in 'p' by 'val', and + * returns the previous value. + */ +static inline isc_int32_t +isc_atomic_xadd(isc_int32_t *p, isc_int32_t val) { + isc_int32_t prev, swapped; + + for (prev = *(volatile isc_int32_t *)p; ; prev = swapped) { + swapped = prev + val; + __asm__ volatile( + "casa [%1] %2, %3, %0" + : "+r"(swapped) + : "r"(p), "n"(ASI_P), "r"(prev)); + if (swapped == prev) + break; + } + + return (prev); +} + +/* + * This routine atomically stores the value 'val' in 'p'. + */ +static inline void +isc_atomic_store(isc_int32_t *p, isc_int32_t val) { + isc_int32_t prev, swapped; + + for (prev = *(volatile isc_int32_t *)p; ; prev = swapped) { + swapped = val; + __asm__ volatile( + "casa [%1] %2, %3, %0" + : "+r"(swapped) + : "r"(p), "n"(ASI_P), "r"(prev) + : "memory"); + if (swapped == prev) + break; + } +} + +/* + * This routine atomically replaces the value in 'p' with 'val', if the + * original value is equal to 'cmpval'. The original value is returned in any + * case. + */ +static inline isc_int32_t +isc_atomic_cmpxchg(isc_int32_t *p, isc_int32_t cmpval, isc_int32_t val) { + isc_int32_t temp = val; + + __asm__ volatile( + "casa [%1] %2, %3, %0" + : "+r"(temp) + : "r"(p), "n"(ASI_P), "r"(cmpval)); + + return (temp); +} + +#else /* ISC_PLATFORM_USEGCCASM */ + +#error "unsupported compiler. disable atomic ops by --disable-atomic" + +#endif /* ISC_PLATFORM_USEGCCASM */ + +#endif /* ISC_ATOMIC_H */ diff -urN src/contrib/ntp/lib/isc/stats.c src.ntp/contrib/ntp/lib/isc/stats.c --- src/contrib/ntp/lib/isc/stats.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/stats.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,326 @@ +/* + * Copyright (C) 2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: stats.c,v 1.3.6.2 2009/01/29 23:47:44 tbox Exp $ */ + +/*! \file */ + +#include + +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#define ISC_STATS_MAGIC ISC_MAGIC('S', 't', 'a', 't') +#define ISC_STATS_VALID(x) ISC_MAGIC_VALID(x, ISC_STATS_MAGIC) + +#ifndef ISC_STATS_USEMULTIFIELDS +#if defined(ISC_RWLOCK_USEATOMIC) && defined(ISC_PLATFORM_HAVEXADD) && !defined(ISC_PLATFORM_HAVEXADDQ) +#define ISC_STATS_USEMULTIFIELDS 1 +#else +#define ISC_STATS_USEMULTIFIELDS 0 +#endif +#endif /* ISC_STATS_USEMULTIFIELDS */ + +#if ISC_STATS_USEMULTIFIELDS +typedef struct { + isc_uint32_t hi; + isc_uint32_t lo; +} isc_stat_t; +#else +typedef isc_uint64_t isc_stat_t; +#endif + +struct isc_stats { + /*% Unlocked */ + unsigned int magic; + isc_mem_t *mctx; + int ncounters; + + isc_mutex_t lock; + unsigned int references; /* locked by lock */ + + /*% + * Locked by counterlock or unlocked if efficient rwlock is not + * available. + */ +#ifdef ISC_RWLOCK_USEATOMIC + isc_rwlock_t counterlock; +#endif + isc_stat_t *counters; + + /*% + * We don't want to lock the counters while we are dumping, so we first + * copy the current counter values into a local array. This buffer + * will be used as the copy destination. It's allocated on creation + * of the stats structure so that the dump operation won't fail due + * to memory allocation failure. + * XXX: this approach is weird for non-threaded build because the + * additional memory and the copy overhead could be avoided. We prefer + * simplicity here, however, under the assumption that this function + * should be only rarely called. + */ + isc_uint64_t *copiedcounters; +}; + +static isc_result_t +create_stats(isc_mem_t *mctx, int ncounters, isc_stats_t **statsp) { + isc_stats_t *stats; + isc_result_t result = ISC_R_SUCCESS; + + REQUIRE(statsp != NULL && *statsp == NULL); + + stats = isc_mem_get(mctx, sizeof(*stats)); + if (stats == NULL) + return (ISC_R_NOMEMORY); + + result = isc_mutex_init(&stats->lock); + if (result != ISC_R_SUCCESS) + goto clean_stats; + + stats->counters = isc_mem_get(mctx, sizeof(isc_stat_t) * ncounters); + if (stats->counters == NULL) { + result = ISC_R_NOMEMORY; + goto clean_mutex; + } + stats->copiedcounters = isc_mem_get(mctx, + sizeof(isc_uint64_t) * ncounters); + if (stats->copiedcounters == NULL) { + result = ISC_R_NOMEMORY; + goto clean_counters; + } + +#ifdef ISC_RWLOCK_USEATOMIC + result = isc_rwlock_init(&stats->counterlock, 0, 0); + if (result != ISC_R_SUCCESS) + goto clean_copiedcounters; +#endif + + stats->references = 1; + memset(stats->counters, 0, sizeof(isc_stat_t) * ncounters); + stats->mctx = NULL; + isc_mem_attach(mctx, &stats->mctx); + stats->ncounters = ncounters; + stats->magic = ISC_STATS_MAGIC; + + *statsp = stats; + + return (result); + +clean_counters: + isc_mem_put(mctx, stats->counters, sizeof(isc_stat_t) * ncounters); + +#ifdef ISC_RWLOCK_USEATOMIC +clean_copiedcounters: + isc_mem_put(mctx, stats->copiedcounters, + sizeof(isc_stat_t) * ncounters); +#endif + +clean_mutex: + DESTROYLOCK(&stats->lock); + +clean_stats: + isc_mem_put(mctx, stats, sizeof(*stats)); + + return (result); +} + +void +isc_stats_attach(isc_stats_t *stats, isc_stats_t **statsp) { + REQUIRE(ISC_STATS_VALID(stats)); + REQUIRE(statsp != NULL && *statsp == NULL); + + LOCK(&stats->lock); + stats->references++; + UNLOCK(&stats->lock); + + *statsp = stats; +} + +void +isc_stats_detach(isc_stats_t **statsp) { + isc_stats_t *stats; + + REQUIRE(statsp != NULL && ISC_STATS_VALID(*statsp)); + + stats = *statsp; + *statsp = NULL; + + LOCK(&stats->lock); + stats->references--; + UNLOCK(&stats->lock); + + if (stats->references == 0) { + isc_mem_put(stats->mctx, stats->copiedcounters, + sizeof(isc_stat_t) * stats->ncounters); + isc_mem_put(stats->mctx, stats->counters, + sizeof(isc_stat_t) * stats->ncounters); + DESTROYLOCK(&stats->lock); +#ifdef ISC_RWLOCK_USEATOMIC + isc_rwlock_destroy(&stats->counterlock); +#endif + isc_mem_putanddetach(&stats->mctx, stats, sizeof(*stats)); + } +} + +int +isc_stats_ncounters(isc_stats_t *stats) { + REQUIRE(ISC_STATS_VALID(stats)); + + return (stats->ncounters); +} + +static inline void +incrementcounter(isc_stats_t *stats, int counter) { + isc_int32_t prev; + +#ifdef ISC_RWLOCK_USEATOMIC + /* + * We use a "read" lock to prevent other threads from reading the + * counter while we "writing" a counter field. The write access itself + * is protected by the atomic operation. + */ + isc_rwlock_lock(&stats->counterlock, isc_rwlocktype_read); +#endif + +#if ISC_STATS_USEMULTIFIELDS + prev = isc_atomic_xadd((isc_int32_t *)&stats->counters[counter].lo, 1); + /* + * If the lower 32-bit field overflows, increment the higher field. + * Note that it's *theoretically* possible that the lower field + * overlaps again before the higher field is incremented. It doesn't + * matter, however, because we don't read the value until + * isc_stats_copy() is called where the whole process is protected + * by the write (exclusive) lock. + */ + if (prev == (isc_int32_t)0xffffffff) + isc_atomic_xadd((isc_int32_t *)&stats->counters[counter].hi, 1); +#elif defined(ISC_PLATFORM_HAVEXADDQ) + UNUSED(prev); + isc_atomic_xaddq((isc_int64_t *)&stats->counters[counter], 1); +#else + UNUSED(prev); + stats->counters[counter]++; +#endif + +#ifdef ISC_RWLOCK_USEATOMIC + isc_rwlock_unlock(&stats->counterlock, isc_rwlocktype_read); +#endif +} + +static inline void +decrementcounter(isc_stats_t *stats, int counter) { + isc_int32_t prev; + +#ifdef ISC_RWLOCK_USEATOMIC + isc_rwlock_lock(&stats->counterlock, isc_rwlocktype_read); +#endif + +#if ISC_STATS_USEMULTIFIELDS + prev = isc_atomic_xadd((isc_int32_t *)&stats->counters[counter].lo, -1); + if (prev == 0) + isc_atomic_xadd((isc_int32_t *)&stats->counters[counter].hi, + -1); +#elif defined(ISC_PLATFORM_HAVEXADDQ) + UNUSED(prev); + isc_atomic_xaddq((isc_int64_t *)&stats->counters[counter], -1); +#else + UNUSED(prev); + stats->counters[counter]--; +#endif + +#ifdef ISC_RWLOCK_USEATOMIC + isc_rwlock_unlock(&stats->counterlock, isc_rwlocktype_read); +#endif +} + +static void +copy_counters(isc_stats_t *stats) { + int i; + +#ifdef ISC_RWLOCK_USEATOMIC + /* + * We use a "write" lock before "reading" the statistics counters as + * an exclusive lock. + */ + isc_rwlock_lock(&stats->counterlock, isc_rwlocktype_write); +#endif + +#if ISC_STATS_USEMULTIFIELDS + for (i = 0; i < stats->ncounters; i++) { + stats->copiedcounters[i] = + (isc_uint64_t)(stats->counters[i].hi) << 32 | + stats->counters[i].lo; + } +#else + UNUSED(i); + memcpy(stats->copiedcounters, stats->counters, + stats->ncounters * sizeof(isc_stat_t)); +#endif + +#ifdef ISC_RWLOCK_USEATOMIC + isc_rwlock_unlock(&stats->counterlock, isc_rwlocktype_write); +#endif +} + +isc_result_t +isc_stats_create(isc_mem_t *mctx, isc_stats_t **statsp, int ncounters) { + REQUIRE(statsp != NULL && *statsp == NULL); + + return (create_stats(mctx, ncounters, statsp)); +} + +void +isc_stats_increment(isc_stats_t *stats, isc_statscounter_t counter) { + REQUIRE(ISC_STATS_VALID(stats)); + REQUIRE(counter < stats->ncounters); + + incrementcounter(stats, (int)counter); +} + +void +isc_stats_decrement(isc_stats_t *stats, isc_statscounter_t counter) { + REQUIRE(ISC_STATS_VALID(stats)); + REQUIRE(counter < stats->ncounters); + + decrementcounter(stats, (int)counter); +} + +void +isc_stats_dump(isc_stats_t *stats, isc_stats_dumper_t dump_fn, + void *arg, unsigned int options) +{ + int i; + + REQUIRE(ISC_STATS_VALID(stats)); + + copy_counters(stats); + + for (i = 0; i < stats->ncounters; i++) { + if ((options & ISC_STATSDUMP_VERBOSE) == 0 && + stats->copiedcounters[i] == 0) + continue; + dump_fn((isc_statscounter_t)i, stats->copiedcounters[i], arg); + } +} diff -urN src/contrib/ntp/lib/isc/string.c src.ntp/contrib/ntp/lib/isc/string.c --- src/contrib/ntp/lib/isc/string.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/string.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,270 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: string.c,v 1.20 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include + +#include +#include +#include +#include +#include + +static char digits[] = "0123456789abcdefghijklmnoprstuvwxyz"; + +isc_uint64_t +isc_string_touint64(char *source, char **end, int base) { + isc_uint64_t tmp; + isc_uint64_t overflow; + char *s = source; + char *o; + char c; + + if ((base < 0) || (base == 1) || (base > 36)) { + *end = source; + return (0); + } + + while (*s != 0 && isascii(*s&0xff) && isspace(*s&0xff)) + s++; + if (*s == '+' /* || *s == '-' */) + s++; + if (base == 0) { + if (*s == '0' && (*(s+1) == 'X' || *(s+1) == 'x')) { + s += 2; + base = 16; + } else if (*s == '0') + base = 8; + else + base = 10; + } + if (*s == 0) { + *end = source; + return (0); + } + overflow = ~0; + overflow /= base; + tmp = 0; + + while ((c = *s) != 0) { + c = tolower(c&0xff); + /* end ? */ + if ((o = strchr(digits, c)) == NULL) { + *end = s; + return (tmp); + } + /* end ? */ + if ((o - digits) >= base) { + *end = s; + return (tmp); + } + /* overflow ? */ + if (tmp > overflow) { + *end = source; + return (0); + } + tmp *= base; + /* overflow ? */ + if ((tmp + (o - digits)) < tmp) { + *end = source; + return (0); + } + tmp += o - digits; + s++; + } + *end = s; + return (tmp); +} + +isc_result_t +isc_string_copy(char *target, size_t size, const char *source) { + REQUIRE(size > 0U); + + if (strlcpy(target, source, size) >= size) { + memset(target, ISC_STRING_MAGIC, size); + return (ISC_R_NOSPACE); + } + + ENSURE(strlen(target) < size); + + return (ISC_R_SUCCESS); +} + +void +isc_string_copy_truncate(char *target, size_t size, const char *source) { + REQUIRE(size > 0U); + + strlcpy(target, source, size); + + ENSURE(strlen(target) < size); +} + +isc_result_t +isc_string_append(char *target, size_t size, const char *source) { + REQUIRE(size > 0U); + REQUIRE(strlen(target) < size); + + if (strlcat(target, source, size) >= size) { + memset(target, ISC_STRING_MAGIC, size); + return (ISC_R_NOSPACE); + } + + ENSURE(strlen(target) < size); + + return (ISC_R_SUCCESS); +} + +void +isc_string_append_truncate(char *target, size_t size, const char *source) { + REQUIRE(size > 0U); + REQUIRE(strlen(target) < size); + + strlcat(target, source, size); + + ENSURE(strlen(target) < size); +} + +isc_result_t +isc_string_printf(char *target, size_t size, const char *format, ...) { + va_list args; + size_t n; + + REQUIRE(size > 0U); + + va_start(args, format); + n = vsnprintf(target, size, format, args); + va_end(args); + + if (n >= size) { + memset(target, ISC_STRING_MAGIC, size); + return (ISC_R_NOSPACE); + } + + ENSURE(strlen(target) < size); + + return (ISC_R_SUCCESS); +} + +void +isc_string_printf_truncate(char *target, size_t size, const char *format, ...) { + va_list args; + size_t n; + + REQUIRE(size > 0U); + + va_start(args, format); + n = vsnprintf(target, size, format, args); + va_end(args); + + ENSURE(strlen(target) < size); +} + +char * +isc_string_regiondup(isc_mem_t *mctx, const isc_region_t *source) { + char *target; + + REQUIRE(mctx != NULL); + REQUIRE(source != NULL); + + target = (char *) isc_mem_allocate(mctx, source->length + 1); + if (target != NULL) { + memcpy(source->base, target, source->length); + target[source->length] = '\0'; + } + + return (target); +} + +char * +isc_string_separate(char **stringp, const char *delim) { + char *string = *stringp; + char *s; + const char *d; + char sc, dc; + + if (string == NULL) + return (NULL); + + for (s = string; (sc = *s) != '\0'; s++) + for (d = delim; (dc = *d) != '\0'; d++) + if (sc == dc) { + *s++ = '\0'; + *stringp = s; + return (string); + } + *stringp = NULL; + return (string); +} + +size_t +isc_string_strlcpy(char *dst, const char *src, size_t size) +{ + char *d = dst; + const char *s = src; + size_t n = size; + + /* Copy as many bytes as will fit */ + if (n != 0U && --n != 0U) { + do { + if ((*d++ = *s++) == 0) + break; + } while (--n != 0U); + } + + /* Not enough room in dst, add NUL and traverse rest of src */ + if (n == 0U) { + if (size != 0U) + *d = '\0'; /* NUL-terminate dst */ + while (*s++) + ; + } + + return(s - src - 1); /* count does not include NUL */ +} + +size_t +isc_string_strlcat(char *dst, const char *src, size_t size) +{ + char *d = dst; + const char *s = src; + size_t n = size; + size_t dlen; + + /* Find the end of dst and adjust bytes left but don't go past end */ + while (n-- != 0U && *d != '\0') + d++; + dlen = d - dst; + n = size - dlen; + + if (n == 0U) + return(dlen + strlen(s)); + while (*s != '\0') { + if (n != 1U) { + *d++ = *s; + n--; + } + s++; + } + *d = '\0'; + + return(dlen + (s - src)); /* count does not include NUL */ +} diff -urN src/contrib/ntp/lib/isc/strtoul.c src.ntp/contrib/ntp/lib/isc/strtoul.c --- src/contrib/ntp/lib/isc/strtoul.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/strtoul.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,129 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* + * Copyright (c) 1990, 1993 + * The Regents of the University of California. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +/*! \file */ +#if defined(LIBC_SCCS) && !defined(lint) +static char sccsid[] = "@(#)strtoul.c 8.1 (Berkeley) 6/4/93"; +#endif /* LIBC_SCCS and not lint */ + +/* $Id: strtoul.c,v 1.7 2007/06/19 23:47:17 tbox Exp $ */ + +#include + +#include +#include +#include + +#include +#include + +/*! + * Convert a string to an unsigned long integer. + * + * Ignores `locale' stuff. Assumes that the upper and lower case + * alphabets and digits are each contiguous. + */ +unsigned long +isc_strtoul(const char *nptr, char **endptr, int base) { + const char *s = nptr; + unsigned long acc; + unsigned char c; + unsigned long cutoff; + int neg = 0, any, cutlim; + + /* + * See strtol for comments as to the logic used. + */ + do { + c = *s++; + } while (isspace(c)); + if (c == '-') { + neg = 1; + c = *s++; + } else if (c == '+') + c = *s++; + if ((base == 0 || base == 16) && + c == '0' && (*s == 'x' || *s == 'X')) { + c = s[1]; + s += 2; + base = 16; + } + if (base == 0) + base = c == '0' ? 8 : 10; + cutoff = (unsigned long)ULONG_MAX / (unsigned long)base; + cutlim = (unsigned long)ULONG_MAX % (unsigned long)base; + for (acc = 0, any = 0;; c = *s++) { + if (!isascii(c)) + break; + if (isdigit(c)) + c -= '0'; + else if (isalpha(c)) + c -= isupper(c) ? 'A' - 10 : 'a' - 10; + else + break; + if (c >= base) + break; + if (any < 0 || acc > cutoff || (acc == cutoff && c > cutlim)) + any = -1; + else { + any = 1; + acc *= base; + acc += c; + } + } + if (any < 0) { + acc = ULONG_MAX; + errno = ERANGE; + } else if (neg) + acc = -acc; + if (endptr != 0) + DE_CONST(any ? s - 1 : nptr, *endptr); + return (acc); +} diff -urN src/contrib/ntp/lib/isc/symtab.c src.ntp/contrib/ntp/lib/isc/symtab.c --- src/contrib/ntp/lib/isc/symtab.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/symtab.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,252 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1996-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: symtab.c,v 1.30 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include + +#include +#include +#include +#include +#include + +typedef struct elt { + char * key; + unsigned int type; + isc_symvalue_t value; + LINK(struct elt) link; +} elt_t; + +typedef LIST(elt_t) eltlist_t; + +#define SYMTAB_MAGIC ISC_MAGIC('S', 'y', 'm', 'T') +#define VALID_SYMTAB(st) ISC_MAGIC_VALID(st, SYMTAB_MAGIC) + +struct isc_symtab { + /* Unlocked. */ + unsigned int magic; + isc_mem_t * mctx; + unsigned int size; + eltlist_t * table; + isc_symtabaction_t undefine_action; + void * undefine_arg; + isc_boolean_t case_sensitive; +}; + +isc_result_t +isc_symtab_create(isc_mem_t *mctx, unsigned int size, + isc_symtabaction_t undefine_action, + void *undefine_arg, + isc_boolean_t case_sensitive, + isc_symtab_t **symtabp) +{ + isc_symtab_t *symtab; + unsigned int i; + + REQUIRE(mctx != NULL); + REQUIRE(symtabp != NULL && *symtabp == NULL); + REQUIRE(size > 0); /* Should be prime. */ + + symtab = (isc_symtab_t *)isc_mem_get(mctx, sizeof(*symtab)); + if (symtab == NULL) + return (ISC_R_NOMEMORY); + symtab->table = (eltlist_t *)isc_mem_get(mctx, + size * sizeof(eltlist_t)); + if (symtab->table == NULL) { + isc_mem_put(mctx, symtab, sizeof(*symtab)); + return (ISC_R_NOMEMORY); + } + for (i = 0; i < size; i++) + INIT_LIST(symtab->table[i]); + symtab->mctx = mctx; + symtab->size = size; + symtab->undefine_action = undefine_action; + symtab->undefine_arg = undefine_arg; + symtab->case_sensitive = case_sensitive; + symtab->magic = SYMTAB_MAGIC; + + *symtabp = symtab; + + return (ISC_R_SUCCESS); +} + +void +isc_symtab_destroy(isc_symtab_t **symtabp) { + isc_symtab_t *symtab; + unsigned int i; + elt_t *elt, *nelt; + + REQUIRE(symtabp != NULL); + symtab = *symtabp; + REQUIRE(VALID_SYMTAB(symtab)); + + for (i = 0; i < symtab->size; i++) { + for (elt = HEAD(symtab->table[i]); elt != NULL; elt = nelt) { + nelt = NEXT(elt, link); + if (symtab->undefine_action != NULL) + (symtab->undefine_action)(elt->key, + elt->type, + elt->value, + symtab->undefine_arg); + isc_mem_put(symtab->mctx, elt, sizeof(*elt)); + } + } + isc_mem_put(symtab->mctx, symtab->table, + symtab->size * sizeof(eltlist_t)); + symtab->magic = 0; + isc_mem_put(symtab->mctx, symtab, sizeof(*symtab)); + + *symtabp = NULL; +} + +static inline unsigned int +hash(const char *key, isc_boolean_t case_sensitive) { + const char *s; + unsigned int h = 0; + int c; + + /* + * This hash function is similar to the one Ousterhout + * uses in Tcl. + */ + + if (case_sensitive) { + for (s = key; *s != '\0'; s++) { + h += (h << 3) + *s; + } + } else { + for (s = key; *s != '\0'; s++) { + c = *s; + c = tolower((unsigned char)c); + h += (h << 3) + c; + } + } + + return (h); +} + +#define FIND(s, k, t, b, e) \ + b = hash((k), (s)->case_sensitive) % (s)->size; \ + if ((s)->case_sensitive) { \ + for (e = HEAD((s)->table[b]); e != NULL; e = NEXT(e, link)) { \ + if (((t) == 0 || e->type == (t)) && \ + strcmp(e->key, (k)) == 0) \ + break; \ + } \ + } else { \ + for (e = HEAD((s)->table[b]); e != NULL; e = NEXT(e, link)) { \ + if (((t) == 0 || e->type == (t)) && \ + strcasecmp(e->key, (k)) == 0) \ + break; \ + } \ + } + +isc_result_t +isc_symtab_lookup(isc_symtab_t *symtab, const char *key, unsigned int type, + isc_symvalue_t *value) +{ + unsigned int bucket; + elt_t *elt; + + REQUIRE(VALID_SYMTAB(symtab)); + REQUIRE(key != NULL); + + FIND(symtab, key, type, bucket, elt); + + if (elt == NULL) + return (ISC_R_NOTFOUND); + + if (value != NULL) + *value = elt->value; + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_symtab_define(isc_symtab_t *symtab, const char *key, unsigned int type, + isc_symvalue_t value, isc_symexists_t exists_policy) +{ + unsigned int bucket; + elt_t *elt; + + REQUIRE(VALID_SYMTAB(symtab)); + REQUIRE(key != NULL); + REQUIRE(type != 0); + + FIND(symtab, key, type, bucket, elt); + + if (exists_policy != isc_symexists_add && elt != NULL) { + if (exists_policy == isc_symexists_reject) + return (ISC_R_EXISTS); + INSIST(exists_policy == isc_symexists_replace); + UNLINK(symtab->table[bucket], elt, link); + if (symtab->undefine_action != NULL) + (symtab->undefine_action)(elt->key, elt->type, + elt->value, + symtab->undefine_arg); + } else { + elt = (elt_t *)isc_mem_get(symtab->mctx, sizeof(*elt)); + if (elt == NULL) + return (ISC_R_NOMEMORY); + ISC_LINK_INIT(elt, link); + } + + /* + * Though the "key" can be const coming in, it is not stored as const + * so that the calling program can easily have writable access to + * it in its undefine_action function. In the event that it *was* + * truly const coming in and then the caller modified it anyway ... + * well, don't do that! + */ + DE_CONST(key, elt->key); + elt->type = type; + elt->value = value; + + /* + * We prepend so that the most recent definition will be found. + */ + PREPEND(symtab->table[bucket], elt, link); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_symtab_undefine(isc_symtab_t *symtab, const char *key, unsigned int type) { + unsigned int bucket; + elt_t *elt; + + REQUIRE(VALID_SYMTAB(symtab)); + REQUIRE(key != NULL); + + FIND(symtab, key, type, bucket, elt); + + if (elt == NULL) + return (ISC_R_NOTFOUND); + + if (symtab->undefine_action != NULL) + (symtab->undefine_action)(elt->key, elt->type, + elt->value, symtab->undefine_arg); + UNLINK(symtab->table[bucket], elt, link); + isc_mem_put(symtab->mctx, elt, sizeof(*elt)); + + return (ISC_R_SUCCESS); +} diff -urN src/contrib/ntp/lib/isc/task.c src.ntp/contrib/ntp/lib/isc/task.c --- src/contrib/ntp/lib/isc/task.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/task.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,1376 @@ +/* + * Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: task.c,v 1.107 2008/03/27 23:46:57 tbox Exp $ */ + +/*! \file + * \author Principal Author: Bob Halley + */ + +/* + * XXXRTH Need to document the states a task can be in, and the rules + * for changing states. + */ + +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#ifndef ISC_PLATFORM_USETHREADS +#include "task_p.h" +#endif /* ISC_PLATFORM_USETHREADS */ + +#ifdef ISC_TASK_TRACE +#define XTRACE(m) fprintf(stderr, "task %p thread %lu: %s\n", \ + task, isc_thread_self(), (m)) +#define XTTRACE(t, m) fprintf(stderr, "task %p thread %lu: %s\n", \ + (t), isc_thread_self(), (m)) +#define XTHREADTRACE(m) fprintf(stderr, "thread %lu: %s\n", \ + isc_thread_self(), (m)) +#else +#define XTRACE(m) +#define XTTRACE(t, m) +#define XTHREADTRACE(m) +#endif + +/*** + *** Types. + ***/ + +typedef enum { + task_state_idle, task_state_ready, task_state_running, + task_state_done +} task_state_t; + +#ifdef HAVE_LIBXML2 +static const char *statenames[] = { + "idle", "ready", "running", "done", +}; +#endif + +#define TASK_MAGIC ISC_MAGIC('T', 'A', 'S', 'K') +#define VALID_TASK(t) ISC_MAGIC_VALID(t, TASK_MAGIC) + +struct isc_task { + /* Not locked. */ + unsigned int magic; + isc_taskmgr_t * manager; + isc_mutex_t lock; + /* Locked by task lock. */ + task_state_t state; + unsigned int references; + isc_eventlist_t events; + isc_eventlist_t on_shutdown; + unsigned int quantum; + unsigned int flags; + isc_stdtime_t now; + char name[16]; + void * tag; + /* Locked by task manager lock. */ + LINK(isc_task_t) link; + LINK(isc_task_t) ready_link; +}; + +#define TASK_F_SHUTTINGDOWN 0x01 + +#define TASK_SHUTTINGDOWN(t) (((t)->flags & TASK_F_SHUTTINGDOWN) \ + != 0) + +#define TASK_MANAGER_MAGIC ISC_MAGIC('T', 'S', 'K', 'M') +#define VALID_MANAGER(m) ISC_MAGIC_VALID(m, TASK_MANAGER_MAGIC) + +struct isc_taskmgr { + /* Not locked. */ + unsigned int magic; + isc_mem_t * mctx; + isc_mutex_t lock; +#ifdef ISC_PLATFORM_USETHREADS + unsigned int workers; + isc_thread_t * threads; +#endif /* ISC_PLATFORM_USETHREADS */ + /* Locked by task manager lock. */ + unsigned int default_quantum; + LIST(isc_task_t) tasks; + isc_tasklist_t ready_tasks; +#ifdef ISC_PLATFORM_USETHREADS + isc_condition_t work_available; + isc_condition_t exclusive_granted; +#endif /* ISC_PLATFORM_USETHREADS */ + unsigned int tasks_running; + isc_boolean_t exclusive_requested; + isc_boolean_t exiting; +#ifndef ISC_PLATFORM_USETHREADS + unsigned int refs; +#endif /* ISC_PLATFORM_USETHREADS */ +}; + +#define DEFAULT_TASKMGR_QUANTUM 10 +#define DEFAULT_DEFAULT_QUANTUM 5 +#define FINISHED(m) ((m)->exiting && EMPTY((m)->tasks)) + +#ifndef ISC_PLATFORM_USETHREADS +static isc_taskmgr_t *taskmgr = NULL; +#endif /* ISC_PLATFORM_USETHREADS */ + +/*** + *** Tasks. + ***/ + +static void +task_finished(isc_task_t *task) { + isc_taskmgr_t *manager = task->manager; + + REQUIRE(EMPTY(task->events)); + REQUIRE(EMPTY(task->on_shutdown)); + REQUIRE(task->references == 0); + REQUIRE(task->state == task_state_done); + + XTRACE("task_finished"); + + LOCK(&manager->lock); + UNLINK(manager->tasks, task, link); +#ifdef ISC_PLATFORM_USETHREADS + if (FINISHED(manager)) { + /* + * All tasks have completed and the + * task manager is exiting. Wake up + * any idle worker threads so they + * can exit. + */ + BROADCAST(&manager->work_available); + } +#endif /* ISC_PLATFORM_USETHREADS */ + UNLOCK(&manager->lock); + + DESTROYLOCK(&task->lock); + task->magic = 0; + isc_mem_put(manager->mctx, task, sizeof(*task)); +} + +isc_result_t +isc_task_create(isc_taskmgr_t *manager, unsigned int quantum, + isc_task_t **taskp) +{ + isc_task_t *task; + isc_boolean_t exiting; + isc_result_t result; + + REQUIRE(VALID_MANAGER(manager)); + REQUIRE(taskp != NULL && *taskp == NULL); + + task = isc_mem_get(manager->mctx, sizeof(*task)); + if (task == NULL) + return (ISC_R_NOMEMORY); + XTRACE("isc_task_create"); + task->manager = manager; + result = isc_mutex_init(&task->lock); + if (result != ISC_R_SUCCESS) { + isc_mem_put(manager->mctx, task, sizeof(*task)); + return (result); + } + task->state = task_state_idle; + task->references = 1; + INIT_LIST(task->events); + INIT_LIST(task->on_shutdown); + task->quantum = quantum; + task->flags = 0; + task->now = 0; + memset(task->name, 0, sizeof(task->name)); + task->tag = NULL; + INIT_LINK(task, link); + INIT_LINK(task, ready_link); + + exiting = ISC_FALSE; + LOCK(&manager->lock); + if (!manager->exiting) { + if (task->quantum == 0) + task->quantum = manager->default_quantum; + APPEND(manager->tasks, task, link); + } else + exiting = ISC_TRUE; + UNLOCK(&manager->lock); + + if (exiting) { + DESTROYLOCK(&task->lock); + isc_mem_put(manager->mctx, task, sizeof(*task)); + return (ISC_R_SHUTTINGDOWN); + } + + task->magic = TASK_MAGIC; + *taskp = task; + + return (ISC_R_SUCCESS); +} + +void +isc_task_attach(isc_task_t *source, isc_task_t **targetp) { + + /* + * Attach *targetp to source. + */ + + REQUIRE(VALID_TASK(source)); + REQUIRE(targetp != NULL && *targetp == NULL); + + XTTRACE(source, "isc_task_attach"); + + LOCK(&source->lock); + source->references++; + UNLOCK(&source->lock); + + *targetp = source; +} + +static inline isc_boolean_t +task_shutdown(isc_task_t *task) { + isc_boolean_t was_idle = ISC_FALSE; + isc_event_t *event, *prev; + + /* + * Caller must be holding the task's lock. + */ + + XTRACE("task_shutdown"); + + if (! TASK_SHUTTINGDOWN(task)) { + XTRACE(isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_SHUTTINGDOWN, "shutting down")); + task->flags |= TASK_F_SHUTTINGDOWN; + if (task->state == task_state_idle) { + INSIST(EMPTY(task->events)); + task->state = task_state_ready; + was_idle = ISC_TRUE; + } + INSIST(task->state == task_state_ready || + task->state == task_state_running); + /* + * Note that we post shutdown events LIFO. + */ + for (event = TAIL(task->on_shutdown); + event != NULL; + event = prev) { + prev = PREV(event, ev_link); + DEQUEUE(task->on_shutdown, event, ev_link); + ENQUEUE(task->events, event, ev_link); + } + } + + return (was_idle); +} + +static inline void +task_ready(isc_task_t *task) { + isc_taskmgr_t *manager = task->manager; + + REQUIRE(VALID_MANAGER(manager)); + REQUIRE(task->state == task_state_ready); + + XTRACE("task_ready"); + + LOCK(&manager->lock); + + ENQUEUE(manager->ready_tasks, task, ready_link); +#ifdef ISC_PLATFORM_USETHREADS + SIGNAL(&manager->work_available); +#endif /* ISC_PLATFORM_USETHREADS */ + + UNLOCK(&manager->lock); +} + +static inline isc_boolean_t +task_detach(isc_task_t *task) { + + /* + * Caller must be holding the task lock. + */ + + REQUIRE(task->references > 0); + + XTRACE("detach"); + + task->references--; + if (task->references == 0 && task->state == task_state_idle) { + INSIST(EMPTY(task->events)); + /* + * There are no references to this task, and no + * pending events. We could try to optimize and + * either initiate shutdown or clean up the task, + * depending on its state, but it's easier to just + * make the task ready and allow run() or the event + * loop to deal with shutting down and termination. + */ + task->state = task_state_ready; + return (ISC_TRUE); + } + + return (ISC_FALSE); +} + +void +isc_task_detach(isc_task_t **taskp) { + isc_task_t *task; + isc_boolean_t was_idle; + + /* + * Detach *taskp from its task. + */ + + REQUIRE(taskp != NULL); + task = *taskp; + REQUIRE(VALID_TASK(task)); + + XTRACE("isc_task_detach"); + + LOCK(&task->lock); + was_idle = task_detach(task); + UNLOCK(&task->lock); + + if (was_idle) + task_ready(task); + + *taskp = NULL; +} + +static inline isc_boolean_t +task_send(isc_task_t *task, isc_event_t **eventp) { + isc_boolean_t was_idle = ISC_FALSE; + isc_event_t *event; + + /* + * Caller must be holding the task lock. + */ + + REQUIRE(eventp != NULL); + event = *eventp; + REQUIRE(event != NULL); + REQUIRE(event->ev_type > 0); + REQUIRE(task->state != task_state_done); + + XTRACE("task_send"); + + if (task->state == task_state_idle) { + was_idle = ISC_TRUE; + INSIST(EMPTY(task->events)); + task->state = task_state_ready; + } + INSIST(task->state == task_state_ready || + task->state == task_state_running); + ENQUEUE(task->events, event, ev_link); + *eventp = NULL; + + return (was_idle); +} + +void +isc_task_send(isc_task_t *task, isc_event_t **eventp) { + isc_boolean_t was_idle; + + /* + * Send '*event' to 'task'. + */ + + REQUIRE(VALID_TASK(task)); + + XTRACE("isc_task_send"); + + /* + * We're trying hard to hold locks for as short a time as possible. + * We're also trying to hold as few locks as possible. This is why + * some processing is deferred until after the lock is released. + */ + LOCK(&task->lock); + was_idle = task_send(task, eventp); + UNLOCK(&task->lock); + + if (was_idle) { + /* + * We need to add this task to the ready queue. + * + * We've waited until now to do it because making a task + * ready requires locking the manager. If we tried to do + * this while holding the task lock, we could deadlock. + * + * We've changed the state to ready, so no one else will + * be trying to add this task to the ready queue. The + * only way to leave the ready state is by executing the + * task. It thus doesn't matter if events are added, + * removed, or a shutdown is started in the interval + * between the time we released the task lock, and the time + * we add the task to the ready queue. + */ + task_ready(task); + } +} + +void +isc_task_sendanddetach(isc_task_t **taskp, isc_event_t **eventp) { + isc_boolean_t idle1, idle2; + isc_task_t *task; + + /* + * Send '*event' to '*taskp' and then detach '*taskp' from its + * task. + */ + + REQUIRE(taskp != NULL); + task = *taskp; + REQUIRE(VALID_TASK(task)); + + XTRACE("isc_task_sendanddetach"); + + LOCK(&task->lock); + idle1 = task_send(task, eventp); + idle2 = task_detach(task); + UNLOCK(&task->lock); + + /* + * If idle1, then idle2 shouldn't be true as well since we're holding + * the task lock, and thus the task cannot switch from ready back to + * idle. + */ + INSIST(!(idle1 && idle2)); + + if (idle1 || idle2) + task_ready(task); + + *taskp = NULL; +} + +#define PURGE_OK(event) (((event)->ev_attributes & ISC_EVENTATTR_NOPURGE) == 0) + +static unsigned int +dequeue_events(isc_task_t *task, void *sender, isc_eventtype_t first, + isc_eventtype_t last, void *tag, + isc_eventlist_t *events, isc_boolean_t purging) +{ + isc_event_t *event, *next_event; + unsigned int count = 0; + + REQUIRE(VALID_TASK(task)); + REQUIRE(last >= first); + + XTRACE("dequeue_events"); + + /* + * Events matching 'sender', whose type is >= first and <= last, and + * whose tag is 'tag' will be dequeued. If 'purging', matching events + * which are marked as unpurgable will not be dequeued. + * + * sender == NULL means "any sender", and tag == NULL means "any tag". + */ + + LOCK(&task->lock); + + for (event = HEAD(task->events); event != NULL; event = next_event) { + next_event = NEXT(event, ev_link); + if (event->ev_type >= first && event->ev_type <= last && + (sender == NULL || event->ev_sender == sender) && + (tag == NULL || event->ev_tag == tag) && + (!purging || PURGE_OK(event))) { + DEQUEUE(task->events, event, ev_link); + ENQUEUE(*events, event, ev_link); + count++; + } + } + + UNLOCK(&task->lock); + + return (count); +} + +unsigned int +isc_task_purgerange(isc_task_t *task, void *sender, isc_eventtype_t first, + isc_eventtype_t last, void *tag) +{ + unsigned int count; + isc_eventlist_t events; + isc_event_t *event, *next_event; + + /* + * Purge events from a task's event queue. + */ + + XTRACE("isc_task_purgerange"); + + ISC_LIST_INIT(events); + + count = dequeue_events(task, sender, first, last, tag, &events, + ISC_TRUE); + + for (event = HEAD(events); event != NULL; event = next_event) { + next_event = NEXT(event, ev_link); + isc_event_free(&event); + } + + /* + * Note that purging never changes the state of the task. + */ + + return (count); +} + +unsigned int +isc_task_purge(isc_task_t *task, void *sender, isc_eventtype_t type, + void *tag) +{ + /* + * Purge events from a task's event queue. + */ + + XTRACE("isc_task_purge"); + + return (isc_task_purgerange(task, sender, type, type, tag)); +} + +isc_boolean_t +isc_task_purgeevent(isc_task_t *task, isc_event_t *event) { + isc_event_t *curr_event, *next_event; + + /* + * Purge 'event' from a task's event queue. + * + * XXXRTH: WARNING: This method may be removed before beta. + */ + + REQUIRE(VALID_TASK(task)); + + /* + * If 'event' is on the task's event queue, it will be purged, + * unless it is marked as unpurgeable. 'event' does not have to be + * on the task's event queue; in fact, it can even be an invalid + * pointer. Purging only occurs if the event is actually on the task's + * event queue. + * + * Purging never changes the state of the task. + */ + + LOCK(&task->lock); + for (curr_event = HEAD(task->events); + curr_event != NULL; + curr_event = next_event) { + next_event = NEXT(curr_event, ev_link); + if (curr_event == event && PURGE_OK(event)) { + DEQUEUE(task->events, curr_event, ev_link); + break; + } + } + UNLOCK(&task->lock); + + if (curr_event == NULL) + return (ISC_FALSE); + + isc_event_free(&curr_event); + + return (ISC_TRUE); +} + +unsigned int +isc_task_unsendrange(isc_task_t *task, void *sender, isc_eventtype_t first, + isc_eventtype_t last, void *tag, + isc_eventlist_t *events) +{ + /* + * Remove events from a task's event queue. + */ + + XTRACE("isc_task_unsendrange"); + + return (dequeue_events(task, sender, first, last, tag, events, + ISC_FALSE)); +} + +unsigned int +isc_task_unsend(isc_task_t *task, void *sender, isc_eventtype_t type, + void *tag, isc_eventlist_t *events) +{ + /* + * Remove events from a task's event queue. + */ + + XTRACE("isc_task_unsend"); + + return (dequeue_events(task, sender, type, type, tag, events, + ISC_FALSE)); +} + +isc_result_t +isc_task_onshutdown(isc_task_t *task, isc_taskaction_t action, const void *arg) +{ + isc_boolean_t disallowed = ISC_FALSE; + isc_result_t result = ISC_R_SUCCESS; + isc_event_t *event; + + /* + * Send a shutdown event with action 'action' and argument 'arg' when + * 'task' is shutdown. + */ + + REQUIRE(VALID_TASK(task)); + REQUIRE(action != NULL); + + event = isc_event_allocate(task->manager->mctx, + NULL, + ISC_TASKEVENT_SHUTDOWN, + action, + arg, + sizeof(*event)); + if (event == NULL) + return (ISC_R_NOMEMORY); + + LOCK(&task->lock); + if (TASK_SHUTTINGDOWN(task)) { + disallowed = ISC_TRUE; + result = ISC_R_SHUTTINGDOWN; + } else + ENQUEUE(task->on_shutdown, event, ev_link); + UNLOCK(&task->lock); + + if (disallowed) + isc_mem_put(task->manager->mctx, event, sizeof(*event)); + + return (result); +} + +void +isc_task_shutdown(isc_task_t *task) { + isc_boolean_t was_idle; + + /* + * Shutdown 'task'. + */ + + REQUIRE(VALID_TASK(task)); + + LOCK(&task->lock); + was_idle = task_shutdown(task); + UNLOCK(&task->lock); + + if (was_idle) + task_ready(task); +} + +void +isc_task_destroy(isc_task_t **taskp) { + + /* + * Destroy '*taskp'. + */ + + REQUIRE(taskp != NULL); + + isc_task_shutdown(*taskp); + isc_task_detach(taskp); +} + +void +isc_task_setname(isc_task_t *task, const char *name, void *tag) { + + /* + * Name 'task'. + */ + + REQUIRE(VALID_TASK(task)); + + LOCK(&task->lock); + memset(task->name, 0, sizeof(task->name)); + strncpy(task->name, name, sizeof(task->name) - 1); + task->tag = tag; + UNLOCK(&task->lock); +} + +const char * +isc_task_getname(isc_task_t *task) { + return (task->name); +} + +void * +isc_task_gettag(isc_task_t *task) { + return (task->tag); +} + +void +isc_task_getcurrenttime(isc_task_t *task, isc_stdtime_t *t) { + REQUIRE(VALID_TASK(task)); + REQUIRE(t != NULL); + + LOCK(&task->lock); + + *t = task->now; + + UNLOCK(&task->lock); +} + +/*** + *** Task Manager. + ***/ +static void +dispatch(isc_taskmgr_t *manager) { + isc_task_t *task; +#ifndef ISC_PLATFORM_USETHREADS + unsigned int total_dispatch_count = 0; + isc_tasklist_t ready_tasks; +#endif /* ISC_PLATFORM_USETHREADS */ + + REQUIRE(VALID_MANAGER(manager)); + + /* + * Again we're trying to hold the lock for as short a time as possible + * and to do as little locking and unlocking as possible. + * + * In both while loops, the appropriate lock must be held before the + * while body starts. Code which acquired the lock at the top of + * the loop would be more readable, but would result in a lot of + * extra locking. Compare: + * + * Straightforward: + * + * LOCK(); + * ... + * UNLOCK(); + * while (expression) { + * LOCK(); + * ... + * UNLOCK(); + * + * Unlocked part here... + * + * LOCK(); + * ... + * UNLOCK(); + * } + * + * Note how if the loop continues we unlock and then immediately lock. + * For N iterations of the loop, this code does 2N+1 locks and 2N+1 + * unlocks. Also note that the lock is not held when the while + * condition is tested, which may or may not be important, depending + * on the expression. + * + * As written: + * + * LOCK(); + * while (expression) { + * ... + * UNLOCK(); + * + * Unlocked part here... + * + * LOCK(); + * ... + * } + * UNLOCK(); + * + * For N iterations of the loop, this code does N+1 locks and N+1 + * unlocks. The while expression is always protected by the lock. + */ + +#ifndef ISC_PLATFORM_USETHREADS + ISC_LIST_INIT(ready_tasks); +#endif + LOCK(&manager->lock); + while (!FINISHED(manager)) { +#ifdef ISC_PLATFORM_USETHREADS + /* + * For reasons similar to those given in the comment in + * isc_task_send() above, it is safe for us to dequeue + * the task while only holding the manager lock, and then + * change the task to running state while only holding the + * task lock. + */ + while ((EMPTY(manager->ready_tasks) || + manager->exclusive_requested) && + !FINISHED(manager)) + { + XTHREADTRACE(isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_WAIT, "wait")); + WAIT(&manager->work_available, &manager->lock); + XTHREADTRACE(isc_msgcat_get(isc_msgcat, + ISC_MSGSET_TASK, + ISC_MSG_AWAKE, "awake")); + } +#else /* ISC_PLATFORM_USETHREADS */ + if (total_dispatch_count >= DEFAULT_TASKMGR_QUANTUM || + EMPTY(manager->ready_tasks)) + break; +#endif /* ISC_PLATFORM_USETHREADS */ + XTHREADTRACE(isc_msgcat_get(isc_msgcat, ISC_MSGSET_TASK, + ISC_MSG_WORKING, "working")); + + task = HEAD(manager->ready_tasks); + if (task != NULL) { + unsigned int dispatch_count = 0; + isc_boolean_t done = ISC_FALSE; + isc_boolean_t requeue = ISC_FALSE; + isc_boolean_t finished = ISC_FALSE; + isc_event_t *event; + + INSIST(VALID_TASK(task)); + + /* + * Note we only unlock the manager lock if we actually + * have a task to do. We must reacquire the manager + * lock before exiting the 'if (task != NULL)' block. + */ + DEQUEUE(manager->ready_tasks, task, ready_link); + manager->tasks_running++; + UNLOCK(&manager->lock); + + LOCK(&task->lock); + INSIST(task->state == task_state_ready); + task->state = task_state_running; + XTRACE(isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_RUNNING, "running")); + isc_stdtime_get(&task->now); + do { + if (!EMPTY(task->events)) { + event = HEAD(task->events); + DEQUEUE(task->events, event, ev_link); + + /* + * Execute the event action. + */ + XTRACE(isc_msgcat_get(isc_msgcat, + ISC_MSGSET_TASK, + ISC_MSG_EXECUTE, + "execute action")); + if (event->ev_action != NULL) { + UNLOCK(&task->lock); + (event->ev_action)(task,event); + LOCK(&task->lock); + } + dispatch_count++; +#ifndef ISC_PLATFORM_USETHREADS + total_dispatch_count++; +#endif /* ISC_PLATFORM_USETHREADS */ + } + + if (task->references == 0 && + EMPTY(task->events) && + !TASK_SHUTTINGDOWN(task)) { + isc_boolean_t was_idle; + + /* + * There are no references and no + * pending events for this task, + * which means it will not become + * runnable again via an external + * action (such as sending an event + * or detaching). + * + * We initiate shutdown to prevent + * it from becoming a zombie. + * + * We do this here instead of in + * the "if EMPTY(task->events)" block + * below because: + * + * If we post no shutdown events, + * we want the task to finish. + * + * If we did post shutdown events, + * will still want the task's + * quantum to be applied. + */ + was_idle = task_shutdown(task); + INSIST(!was_idle); + } + + if (EMPTY(task->events)) { + /* + * Nothing else to do for this task + * right now. + */ + XTRACE(isc_msgcat_get(isc_msgcat, + ISC_MSGSET_TASK, + ISC_MSG_EMPTY, + "empty")); + if (task->references == 0 && + TASK_SHUTTINGDOWN(task)) { + /* + * The task is done. + */ + XTRACE(isc_msgcat_get( + isc_msgcat, + ISC_MSGSET_TASK, + ISC_MSG_DONE, + "done")); + finished = ISC_TRUE; + task->state = task_state_done; + } else + task->state = task_state_idle; + done = ISC_TRUE; + } else if (dispatch_count >= task->quantum) { + /* + * Our quantum has expired, but + * there is more work to be done. + * We'll requeue it to the ready + * queue later. + * + * We don't check quantum until + * dispatching at least one event, + * so the minimum quantum is one. + */ + XTRACE(isc_msgcat_get(isc_msgcat, + ISC_MSGSET_TASK, + ISC_MSG_QUANTUM, + "quantum")); + task->state = task_state_ready; + requeue = ISC_TRUE; + done = ISC_TRUE; + } + } while (!done); + UNLOCK(&task->lock); + + if (finished) + task_finished(task); + + LOCK(&manager->lock); + manager->tasks_running--; +#ifdef ISC_PLATFORM_USETHREADS + if (manager->exclusive_requested && + manager->tasks_running == 1) { + SIGNAL(&manager->exclusive_granted); + } +#endif /* ISC_PLATFORM_USETHREADS */ + if (requeue) { + /* + * We know we're awake, so we don't have + * to wakeup any sleeping threads if the + * ready queue is empty before we requeue. + * + * A possible optimization if the queue is + * empty is to 'goto' the 'if (task != NULL)' + * block, avoiding the ENQUEUE of the task + * and the subsequent immediate DEQUEUE + * (since it is the only executable task). + * We don't do this because then we'd be + * skipping the exit_requested check. The + * cost of ENQUEUE is low anyway, especially + * when you consider that we'd have to do + * an extra EMPTY check to see if we could + * do the optimization. If the ready queue + * were usually nonempty, the 'optimization' + * might even hurt rather than help. + */ +#ifdef ISC_PLATFORM_USETHREADS + ENQUEUE(manager->ready_tasks, task, + ready_link); +#else + ENQUEUE(ready_tasks, task, ready_link); +#endif + } + } + } +#ifndef ISC_PLATFORM_USETHREADS + ISC_LIST_APPENDLIST(manager->ready_tasks, ready_tasks, ready_link); +#endif + UNLOCK(&manager->lock); +} + +#ifdef ISC_PLATFORM_USETHREADS +static isc_threadresult_t +#ifdef _WIN32 +WINAPI +#endif +run(void *uap) { + isc_taskmgr_t *manager = uap; + + XTHREADTRACE(isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_STARTING, "starting")); + + dispatch(manager); + + XTHREADTRACE(isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_EXITING, "exiting")); + + return ((isc_threadresult_t)0); +} +#endif /* ISC_PLATFORM_USETHREADS */ + +static void +manager_free(isc_taskmgr_t *manager) { + isc_mem_t *mctx; + +#ifdef ISC_PLATFORM_USETHREADS + (void)isc_condition_destroy(&manager->exclusive_granted); + (void)isc_condition_destroy(&manager->work_available); + isc_mem_free(manager->mctx, manager->threads); +#endif /* ISC_PLATFORM_USETHREADS */ + DESTROYLOCK(&manager->lock); + manager->magic = 0; + mctx = manager->mctx; + isc_mem_put(mctx, manager, sizeof(*manager)); + isc_mem_detach(&mctx); +} + +isc_result_t +isc_taskmgr_create(isc_mem_t *mctx, unsigned int workers, + unsigned int default_quantum, isc_taskmgr_t **managerp) +{ + isc_result_t result; + unsigned int i, started = 0; + isc_taskmgr_t *manager; + + /* + * Create a new task manager. + */ + + REQUIRE(workers > 0); + REQUIRE(managerp != NULL && *managerp == NULL); + +#ifndef ISC_PLATFORM_USETHREADS + UNUSED(i); + UNUSED(started); + UNUSED(workers); + + if (taskmgr != NULL) { + taskmgr->refs++; + *managerp = taskmgr; + return (ISC_R_SUCCESS); + } +#endif /* ISC_PLATFORM_USETHREADS */ + + manager = isc_mem_get(mctx, sizeof(*manager)); + if (manager == NULL) + return (ISC_R_NOMEMORY); + manager->magic = TASK_MANAGER_MAGIC; + manager->mctx = NULL; + result = isc_mutex_init(&manager->lock); + if (result != ISC_R_SUCCESS) + goto cleanup_mgr; + +#ifdef ISC_PLATFORM_USETHREADS + manager->workers = 0; + manager->threads = isc_mem_allocate(mctx, + workers * sizeof(isc_thread_t)); + if (manager->threads == NULL) { + result = ISC_R_NOMEMORY; + goto cleanup_lock; + } + if (isc_condition_init(&manager->work_available) != ISC_R_SUCCESS) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_condition_init() %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + result = ISC_R_UNEXPECTED; + goto cleanup_threads; + } + if (isc_condition_init(&manager->exclusive_granted) != ISC_R_SUCCESS) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_condition_init() %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + result = ISC_R_UNEXPECTED; + goto cleanup_workavailable; + } +#endif /* ISC_PLATFORM_USETHREADS */ + if (default_quantum == 0) + default_quantum = DEFAULT_DEFAULT_QUANTUM; + manager->default_quantum = default_quantum; + INIT_LIST(manager->tasks); + INIT_LIST(manager->ready_tasks); + manager->tasks_running = 0; + manager->exclusive_requested = ISC_FALSE; + manager->exiting = ISC_FALSE; + + isc_mem_attach(mctx, &manager->mctx); + +#ifdef ISC_PLATFORM_USETHREADS + LOCK(&manager->lock); + /* + * Start workers. + */ + for (i = 0; i < workers; i++) { + if (isc_thread_create(run, manager, + &manager->threads[manager->workers]) == + ISC_R_SUCCESS) { + manager->workers++; + started++; + } + } + UNLOCK(&manager->lock); + + if (started == 0) { + manager_free(manager); + return (ISC_R_NOTHREADS); + } + isc_thread_setconcurrency(workers); +#else /* ISC_PLATFORM_USETHREADS */ + manager->refs = 1; + taskmgr = manager; +#endif /* ISC_PLATFORM_USETHREADS */ + + *managerp = manager; + + return (ISC_R_SUCCESS); + +#ifdef ISC_PLATFORM_USETHREADS + cleanup_workavailable: + (void)isc_condition_destroy(&manager->work_available); + cleanup_threads: + isc_mem_free(mctx, manager->threads); + cleanup_lock: + DESTROYLOCK(&manager->lock); +#endif + cleanup_mgr: + isc_mem_put(mctx, manager, sizeof(*manager)); + return (result); +} + +void +isc_taskmgr_destroy(isc_taskmgr_t **managerp) { + isc_taskmgr_t *manager; + isc_task_t *task; + unsigned int i; + + /* + * Destroy '*managerp'. + */ + + REQUIRE(managerp != NULL); + manager = *managerp; + REQUIRE(VALID_MANAGER(manager)); + +#ifndef ISC_PLATFORM_USETHREADS + UNUSED(i); + + if (manager->refs > 1) { + manager->refs--; + *managerp = NULL; + return; + } +#endif /* ISC_PLATFORM_USETHREADS */ + + XTHREADTRACE("isc_taskmgr_destroy"); + /* + * Only one non-worker thread may ever call this routine. + * If a worker thread wants to initiate shutdown of the + * task manager, it should ask some non-worker thread to call + * isc_taskmgr_destroy(), e.g. by signalling a condition variable + * that the startup thread is sleeping on. + */ + + /* + * Unlike elsewhere, we're going to hold this lock a long time. + * We need to do so, because otherwise the list of tasks could + * change while we were traversing it. + * + * This is also the only function where we will hold both the + * task manager lock and a task lock at the same time. + */ + + LOCK(&manager->lock); + + /* + * Make sure we only get called once. + */ + INSIST(!manager->exiting); + manager->exiting = ISC_TRUE; + + /* + * Post shutdown event(s) to every task (if they haven't already been + * posted). + */ + for (task = HEAD(manager->tasks); + task != NULL; + task = NEXT(task, link)) { + LOCK(&task->lock); + if (task_shutdown(task)) + ENQUEUE(manager->ready_tasks, task, ready_link); + UNLOCK(&task->lock); + } +#ifdef ISC_PLATFORM_USETHREADS + /* + * Wake up any sleeping workers. This ensures we get work done if + * there's work left to do, and if there are already no tasks left + * it will cause the workers to see manager->exiting. + */ + BROADCAST(&manager->work_available); + UNLOCK(&manager->lock); + + /* + * Wait for all the worker threads to exit. + */ + for (i = 0; i < manager->workers; i++) + (void)isc_thread_join(manager->threads[i], NULL); +#else /* ISC_PLATFORM_USETHREADS */ + /* + * Dispatch the shutdown events. + */ + UNLOCK(&manager->lock); + while (isc__taskmgr_ready()) + (void)isc__taskmgr_dispatch(); + if (!ISC_LIST_EMPTY(manager->tasks)) + isc_mem_printallactive(stderr); + INSIST(ISC_LIST_EMPTY(manager->tasks)); +#endif /* ISC_PLATFORM_USETHREADS */ + + manager_free(manager); + + *managerp = NULL; +} + +#ifndef ISC_PLATFORM_USETHREADS +isc_boolean_t +isc__taskmgr_ready(void) { + if (taskmgr == NULL) + return (ISC_FALSE); + return (ISC_TF(!ISC_LIST_EMPTY(taskmgr->ready_tasks))); +} + +isc_result_t +isc__taskmgr_dispatch(void) { + isc_taskmgr_t *manager = taskmgr; + + if (taskmgr == NULL) + return (ISC_R_NOTFOUND); + + dispatch(manager); + + return (ISC_R_SUCCESS); +} + +#endif /* ISC_PLATFORM_USETHREADS */ + +isc_result_t +isc_task_beginexclusive(isc_task_t *task) { +#ifdef ISC_PLATFORM_USETHREADS + isc_taskmgr_t *manager = task->manager; + REQUIRE(task->state == task_state_running); + LOCK(&manager->lock); + if (manager->exclusive_requested) { + UNLOCK(&manager->lock); + return (ISC_R_LOCKBUSY); + } + manager->exclusive_requested = ISC_TRUE; + while (manager->tasks_running > 1) { + WAIT(&manager->exclusive_granted, &manager->lock); + } + UNLOCK(&manager->lock); +#else + UNUSED(task); +#endif + return (ISC_R_SUCCESS); +} + +void +isc_task_endexclusive(isc_task_t *task) { +#ifdef ISC_PLATFORM_USETHREADS + isc_taskmgr_t *manager = task->manager; + REQUIRE(task->state == task_state_running); + LOCK(&manager->lock); + REQUIRE(manager->exclusive_requested); + manager->exclusive_requested = ISC_FALSE; + BROADCAST(&manager->work_available); + UNLOCK(&manager->lock); +#else + UNUSED(task); +#endif +} + +#ifdef HAVE_LIBXML2 + +void +isc_taskmgr_renderxml(isc_taskmgr_t *mgr, xmlTextWriterPtr writer) +{ + isc_task_t *task; + + LOCK(&mgr->lock); + + /* + * Write out the thread-model, and some details about each depending + * on which type is enabled. + */ + xmlTextWriterStartElement(writer, ISC_XMLCHAR "thread-model"); +#ifdef ISC_PLATFORM_USETHREADS + xmlTextWriterStartElement(writer, ISC_XMLCHAR "type"); + xmlTextWriterWriteString(writer, ISC_XMLCHAR "threaded"); + xmlTextWriterEndElement(writer); /* type */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "worker-threads"); + xmlTextWriterWriteFormatString(writer, "%d", mgr->workers); + xmlTextWriterEndElement(writer); /* worker-threads */ +#else /* ISC_PLATFORM_USETHREADS */ + xmlTextWriterStartElement(writer, ISC_XMLCHAR "type"); + xmlTextWriterWriteString(writer, ISC_XMLCHAR "non-threaded"); + xmlTextWriterEndElement(writer); /* type */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "references"); + xmlTextWriterWriteFormatString(writer, "%d", mgr->refs); + xmlTextWriterEndElement(writer); /* references */ +#endif /* ISC_PLATFORM_USETHREADS */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "default-quantum"); + xmlTextWriterWriteFormatString(writer, "%d", mgr->default_quantum); + xmlTextWriterEndElement(writer); /* default-quantum */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "tasks-running"); + xmlTextWriterWriteFormatString(writer, "%d", mgr->tasks_running); + xmlTextWriterEndElement(writer); /* tasks-running */ + + xmlTextWriterEndElement(writer); /* thread-model */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "tasks"); + task = ISC_LIST_HEAD(mgr->tasks); + while (task != NULL) { + LOCK(&task->lock); + xmlTextWriterStartElement(writer, ISC_XMLCHAR "task"); + + if (task->name[0] != 0) { + xmlTextWriterStartElement(writer, ISC_XMLCHAR "name"); + xmlTextWriterWriteFormatString(writer, "%s", + task->name); + xmlTextWriterEndElement(writer); /* name */ + } + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "references"); + xmlTextWriterWriteFormatString(writer, "%d", task->references); + xmlTextWriterEndElement(writer); /* references */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "id"); + xmlTextWriterWriteFormatString(writer, "%p", task); + xmlTextWriterEndElement(writer); /* id */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "state"); + xmlTextWriterWriteFormatString(writer, "%s", + statenames[task->state]); + xmlTextWriterEndElement(writer); /* state */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "quantum"); + xmlTextWriterWriteFormatString(writer, "%d", task->quantum); + xmlTextWriterEndElement(writer); /* quantum */ + + xmlTextWriterEndElement(writer); + + UNLOCK(&task->lock); + task = ISC_LIST_NEXT(task, link); + } + xmlTextWriterEndElement(writer); /* tasks */ + + UNLOCK(&mgr->lock); +} +#endif /* HAVE_LIBXML2 */ diff -urN src/contrib/ntp/lib/isc/task_p.h src.ntp/contrib/ntp/lib/isc/task_p.h --- src/contrib/ntp/lib/isc/task_p.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/task_p.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: task_p.h,v 1.11 2007/06/19 23:47:17 tbox Exp $ */ + +#ifndef ISC_TASK_P_H +#define ISC_TASK_P_H + +/*! \file */ + +isc_boolean_t +isc__taskmgr_ready(void); + +isc_result_t +isc__taskmgr_dispatch(void); + +#endif /* ISC_TASK_P_H */ diff -urN src/contrib/ntp/lib/isc/taskpool.c src.ntp/contrib/ntp/lib/isc/taskpool.c --- src/contrib/ntp/lib/isc/taskpool.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/taskpool.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,96 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: taskpool.c,v 1.18 2007/06/18 23:47:44 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include + +/*** + *** Types. + ***/ + +struct isc_taskpool { + isc_mem_t * mctx; + unsigned int ntasks; + isc_task_t ** tasks; +}; +/*** + *** Functions. + ***/ + +isc_result_t +isc_taskpool_create(isc_taskmgr_t *tmgr, isc_mem_t *mctx, + unsigned int ntasks, unsigned int quantum, + isc_taskpool_t **poolp) +{ + unsigned int i; + isc_taskpool_t *pool; + isc_result_t result; + + INSIST(ntasks > 0); + pool = isc_mem_get(mctx, sizeof(*pool)); + if (pool == NULL) + return (ISC_R_NOMEMORY); + pool->mctx = mctx; + pool->ntasks = ntasks; + pool->tasks = isc_mem_get(mctx, ntasks * sizeof(isc_task_t *)); + if (pool->tasks == NULL) { + isc_mem_put(mctx, pool, sizeof(*pool)); + return (ISC_R_NOMEMORY); + } + for (i = 0; i < ntasks; i++) + pool->tasks[i] = NULL; + for (i = 0; i < ntasks; i++) { + result = isc_task_create(tmgr, quantum, &pool->tasks[i]); + if (result != ISC_R_SUCCESS) { + isc_taskpool_destroy(&pool); + return (result); + } + isc_task_setname(pool->tasks[i], "taskpool", NULL); + } + *poolp = pool; + return (ISC_R_SUCCESS); +} + +void isc_taskpool_gettask(isc_taskpool_t *pool, unsigned int hash, + isc_task_t **targetp) +{ + isc_task_attach(pool->tasks[hash % pool->ntasks], targetp); +} + +void +isc_taskpool_destroy(isc_taskpool_t **poolp) { + unsigned int i; + isc_taskpool_t *pool = *poolp; + for (i = 0; i < pool->ntasks; i++) { + if (pool->tasks[i] != NULL) { + isc_task_detach(&pool->tasks[i]); + } + } + isc_mem_put(pool->mctx, pool->tasks, + pool->ntasks * sizeof(isc_task_t *)); + isc_mem_put(pool->mctx, pool, sizeof(*pool)); + *poolp = NULL; +} + + diff -urN src/contrib/ntp/lib/isc/timer.c src.ntp/contrib/ntp/lib/isc/timer.c --- src/contrib/ntp/lib/isc/timer.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/timer.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,933 @@ +/* + * Copyright (C) 2004, 2005, 2007-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: timer.c,v 1.84.58.4 2009/01/23 23:47:21 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#ifndef ISC_PLATFORM_USETHREADS +#include "timer_p.h" +#endif /* ISC_PLATFORM_USETHREADS */ + +#ifdef ISC_TIMER_TRACE +#define XTRACE(s) fprintf(stderr, "%s\n", (s)) +#define XTRACEID(s, t) fprintf(stderr, "%s %p\n", (s), (t)) +#define XTRACETIME(s, d) fprintf(stderr, "%s %u.%09u\n", (s), \ + (d).seconds, (d).nanoseconds) +#define XTRACETIME2(s, d, n) fprintf(stderr, "%s %u.%09u %u.%09u\n", (s), \ + (d).seconds, (d).nanoseconds, (n).seconds, (n).nanoseconds) +#define XTRACETIMER(s, t, d) fprintf(stderr, "%s %p %u.%09u\n", (s), (t), \ + (d).seconds, (d).nanoseconds) +#else +#define XTRACE(s) +#define XTRACEID(s, t) +#define XTRACETIME(s, d) +#define XTRACETIME2(s, d, n) +#define XTRACETIMER(s, t, d) +#endif /* ISC_TIMER_TRACE */ + +#define TIMER_MAGIC ISC_MAGIC('T', 'I', 'M', 'R') +#define VALID_TIMER(t) ISC_MAGIC_VALID(t, TIMER_MAGIC) + +struct isc_timer { + /*! Not locked. */ + unsigned int magic; + isc_timermgr_t * manager; + isc_mutex_t lock; + /*! Locked by timer lock. */ + unsigned int references; + isc_time_t idle; + /*! Locked by manager lock. */ + isc_timertype_t type; + isc_time_t expires; + isc_interval_t interval; + isc_task_t * task; + isc_taskaction_t action; + void * arg; + unsigned int index; + isc_time_t due; + LINK(isc_timer_t) link; +}; + +#define TIMER_MANAGER_MAGIC ISC_MAGIC('T', 'I', 'M', 'M') +#define VALID_MANAGER(m) ISC_MAGIC_VALID(m, TIMER_MANAGER_MAGIC) + +struct isc_timermgr { + /* Not locked. */ + unsigned int magic; + isc_mem_t * mctx; + isc_mutex_t lock; + /* Locked by manager lock. */ + isc_boolean_t done; + LIST(isc_timer_t) timers; + unsigned int nscheduled; + isc_time_t due; +#ifdef ISC_PLATFORM_USETHREADS + isc_condition_t wakeup; + isc_thread_t thread; +#else /* ISC_PLATFORM_USETHREADS */ + unsigned int refs; +#endif /* ISC_PLATFORM_USETHREADS */ + isc_heap_t * heap; +}; + +#ifndef ISC_PLATFORM_USETHREADS +/*! + * If threads are not in use, there can be only one. + */ +static isc_timermgr_t *timermgr = NULL; +#endif /* ISC_PLATFORM_USETHREADS */ + +static inline isc_result_t +schedule(isc_timer_t *timer, isc_time_t *now, isc_boolean_t signal_ok) { + isc_result_t result; + isc_timermgr_t *manager; + isc_time_t due; + int cmp; +#ifdef ISC_PLATFORM_USETHREADS + isc_boolean_t timedwait; +#endif + + /*! + * Note: the caller must ensure locking. + */ + + REQUIRE(timer->type != isc_timertype_inactive); + +#ifndef ISC_PLATFORM_USETHREADS + UNUSED(signal_ok); +#endif /* ISC_PLATFORM_USETHREADS */ + + manager = timer->manager; + +#ifdef ISC_PLATFORM_USETHREADS + /*! + * If the manager was timed wait, we may need to signal the + * manager to force a wakeup. + */ + timedwait = ISC_TF(manager->nscheduled > 0 && + isc_time_seconds(&manager->due) != 0); +#endif + + /* + * Compute the new due time. + */ + if (timer->type != isc_timertype_once) { + result = isc_time_add(now, &timer->interval, &due); + if (result != ISC_R_SUCCESS) + return (result); + if (timer->type == isc_timertype_limited && + isc_time_compare(&timer->expires, &due) < 0) + due = timer->expires; + } else { + if (isc_time_isepoch(&timer->idle)) + due = timer->expires; + else if (isc_time_isepoch(&timer->expires)) + due = timer->idle; + else if (isc_time_compare(&timer->idle, &timer->expires) < 0) + due = timer->idle; + else + due = timer->expires; + } + + /* + * Schedule the timer. + */ + + if (timer->index > 0) { + /* + * Already scheduled. + */ + cmp = isc_time_compare(&due, &timer->due); + timer->due = due; + switch (cmp) { + case -1: + isc_heap_increased(manager->heap, timer->index); + break; + case 1: + isc_heap_decreased(manager->heap, timer->index); + break; + case 0: + /* Nothing to do. */ + break; + } + } else { + timer->due = due; + result = isc_heap_insert(manager->heap, timer); + if (result != ISC_R_SUCCESS) { + INSIST(result == ISC_R_NOMEMORY); + return (ISC_R_NOMEMORY); + } + manager->nscheduled++; + } + + XTRACETIMER(isc_msgcat_get(isc_msgcat, ISC_MSGSET_TIMER, + ISC_MSG_SCHEDULE, "schedule"), timer, due); + + /* + * If this timer is at the head of the queue, we need to ensure + * that we won't miss it if it has a more recent due time than + * the current "next" timer. We do this either by waking up the + * run thread, or explicitly setting the value in the manager. + */ +#ifdef ISC_PLATFORM_USETHREADS + + /* + * This is a temporary (probably) hack to fix a bug on tru64 5.1 + * and 5.1a. Sometimes, pthread_cond_timedwait() doesn't actually + * return when the time expires, so here, we check to see if + * we're 15 seconds or more behind, and if we are, we signal + * the dispatcher. This isn't such a bad idea as a general purpose + * watchdog, so perhaps we should just leave it in here. + */ + if (signal_ok && timedwait) { + isc_interval_t fifteen; + isc_time_t then; + + isc_interval_set(&fifteen, 15, 0); + result = isc_time_add(&manager->due, &fifteen, &then); + + if (result == ISC_R_SUCCESS && + isc_time_compare(&then, now) < 0) { + SIGNAL(&manager->wakeup); + signal_ok = ISC_FALSE; + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_TIMER, ISC_LOG_WARNING, + "*** POKED TIMER ***"); + } + } + + if (timer->index == 1 && signal_ok) { + XTRACE(isc_msgcat_get(isc_msgcat, ISC_MSGSET_TIMER, + ISC_MSG_SIGNALSCHED, + "signal (schedule)")); + SIGNAL(&manager->wakeup); + } +#else /* ISC_PLATFORM_USETHREADS */ + if (timer->index == 1 && + isc_time_compare(&timer->due, &manager->due) < 0) + manager->due = timer->due; +#endif /* ISC_PLATFORM_USETHREADS */ + + return (ISC_R_SUCCESS); +} + +static inline void +deschedule(isc_timer_t *timer) { + isc_boolean_t need_wakeup = ISC_FALSE; + isc_timermgr_t *manager; + + /* + * The caller must ensure locking. + */ + + manager = timer->manager; + if (timer->index > 0) { + if (timer->index == 1) + need_wakeup = ISC_TRUE; + isc_heap_delete(manager->heap, timer->index); + timer->index = 0; + INSIST(manager->nscheduled > 0); + manager->nscheduled--; +#ifdef ISC_PLATFORM_USETHREADS + if (need_wakeup) { + XTRACE(isc_msgcat_get(isc_msgcat, ISC_MSGSET_TIMER, + ISC_MSG_SIGNALDESCHED, + "signal (deschedule)")); + SIGNAL(&manager->wakeup); + } +#endif /* ISC_PLATFORM_USETHREADS */ + } +} + +static void +destroy(isc_timer_t *timer) { + isc_timermgr_t *manager = timer->manager; + + /* + * The caller must ensure it is safe to destroy the timer. + */ + + LOCK(&manager->lock); + + (void)isc_task_purgerange(timer->task, + timer, + ISC_TIMEREVENT_FIRSTEVENT, + ISC_TIMEREVENT_LASTEVENT, + NULL); + deschedule(timer); + UNLINK(manager->timers, timer, link); + + UNLOCK(&manager->lock); + + isc_task_detach(&timer->task); + DESTROYLOCK(&timer->lock); + timer->magic = 0; + isc_mem_put(manager->mctx, timer, sizeof(*timer)); +} + +isc_result_t +isc_timer_create(isc_timermgr_t *manager, isc_timertype_t type, + isc_time_t *expires, isc_interval_t *interval, + isc_task_t *task, isc_taskaction_t action, const void *arg, + isc_timer_t **timerp) +{ + isc_timer_t *timer; + isc_result_t result; + isc_time_t now; + + /* + * Create a new 'type' timer managed by 'manager'. The timers + * parameters are specified by 'expires' and 'interval'. Events + * will be posted to 'task' and when dispatched 'action' will be + * called with 'arg' as the arg value. The new timer is returned + * in 'timerp'. + */ + + REQUIRE(VALID_MANAGER(manager)); + REQUIRE(task != NULL); + REQUIRE(action != NULL); + if (expires == NULL) + expires = isc_time_epoch; + if (interval == NULL) + interval = isc_interval_zero; + REQUIRE(type == isc_timertype_inactive || + !(isc_time_isepoch(expires) && isc_interval_iszero(interval))); + REQUIRE(timerp != NULL && *timerp == NULL); + REQUIRE(type != isc_timertype_limited || + !(isc_time_isepoch(expires) || isc_interval_iszero(interval))); + + /* + * Get current time. + */ + if (type != isc_timertype_inactive) { + TIME_NOW(&now); + } else { + /* + * We don't have to do this, but it keeps the compiler from + * complaining about "now" possibly being used without being + * set, even though it will never actually happen. + */ + isc_time_settoepoch(&now); + } + + + timer = isc_mem_get(manager->mctx, sizeof(*timer)); + if (timer == NULL) + return (ISC_R_NOMEMORY); + + timer->manager = manager; + timer->references = 1; + + if (type == isc_timertype_once && !isc_interval_iszero(interval)) { + result = isc_time_add(&now, interval, &timer->idle); + if (result != ISC_R_SUCCESS) { + isc_mem_put(manager->mctx, timer, sizeof(*timer)); + return (result); + } + } else + isc_time_settoepoch(&timer->idle); + + timer->type = type; + timer->expires = *expires; + timer->interval = *interval; + timer->task = NULL; + isc_task_attach(task, &timer->task); + timer->action = action; + /* + * Removing the const attribute from "arg" is the best of two + * evils here. If the timer->arg member is made const, then + * it affects a great many recipients of the timer event + * which did not pass in an "arg" that was truly const. + * Changing isc_timer_create() to not have "arg" prototyped as const, + * though, can cause compilers warnings for calls that *do* + * have a truly const arg. The caller will have to carefully + * keep track of whether arg started as a true const. + */ + DE_CONST(arg, timer->arg); + timer->index = 0; + result = isc_mutex_init(&timer->lock); + if (result != ISC_R_SUCCESS) { + isc_task_detach(&timer->task); + isc_mem_put(manager->mctx, timer, sizeof(*timer)); + return (result); + } + ISC_LINK_INIT(timer, link); + timer->magic = TIMER_MAGIC; + + LOCK(&manager->lock); + + /* + * Note we don't have to lock the timer like we normally would because + * there are no external references to it yet. + */ + + if (type != isc_timertype_inactive) + result = schedule(timer, &now, ISC_TRUE); + else + result = ISC_R_SUCCESS; + if (result == ISC_R_SUCCESS) + APPEND(manager->timers, timer, link); + + UNLOCK(&manager->lock); + + if (result != ISC_R_SUCCESS) { + timer->magic = 0; + DESTROYLOCK(&timer->lock); + isc_task_detach(&timer->task); + isc_mem_put(manager->mctx, timer, sizeof(*timer)); + return (result); + } + + *timerp = timer; + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_timer_reset(isc_timer_t *timer, isc_timertype_t type, + isc_time_t *expires, isc_interval_t *interval, + isc_boolean_t purge) +{ + isc_time_t now; + isc_timermgr_t *manager; + isc_result_t result; + + /* + * Change the timer's type, expires, and interval values to the given + * values. If 'purge' is ISC_TRUE, any pending events from this timer + * are purged from its task's event queue. + */ + + REQUIRE(VALID_TIMER(timer)); + manager = timer->manager; + REQUIRE(VALID_MANAGER(manager)); + if (expires == NULL) + expires = isc_time_epoch; + if (interval == NULL) + interval = isc_interval_zero; + REQUIRE(type == isc_timertype_inactive || + !(isc_time_isepoch(expires) && isc_interval_iszero(interval))); + REQUIRE(type != isc_timertype_limited || + !(isc_time_isepoch(expires) || isc_interval_iszero(interval))); + + /* + * Get current time. + */ + if (type != isc_timertype_inactive) { + TIME_NOW(&now); + } else { + /* + * We don't have to do this, but it keeps the compiler from + * complaining about "now" possibly being used without being + * set, even though it will never actually happen. + */ + isc_time_settoepoch(&now); + } + + manager = timer->manager; + + LOCK(&manager->lock); + LOCK(&timer->lock); + + if (purge) + (void)isc_task_purgerange(timer->task, + timer, + ISC_TIMEREVENT_FIRSTEVENT, + ISC_TIMEREVENT_LASTEVENT, + NULL); + timer->type = type; + timer->expires = *expires; + timer->interval = *interval; + if (type == isc_timertype_once && !isc_interval_iszero(interval)) { + result = isc_time_add(&now, interval, &timer->idle); + } else { + isc_time_settoepoch(&timer->idle); + result = ISC_R_SUCCESS; + } + + if (result == ISC_R_SUCCESS) { + if (type == isc_timertype_inactive) { + deschedule(timer); + result = ISC_R_SUCCESS; + } else + result = schedule(timer, &now, ISC_TRUE); + } + + UNLOCK(&timer->lock); + UNLOCK(&manager->lock); + + return (result); +} + +isc_timertype_t +isc_timer_gettype(isc_timer_t *timer) { + isc_timertype_t t; + + REQUIRE(VALID_TIMER(timer)); + + LOCK(&timer->lock); + t = timer->type; + UNLOCK(&timer->lock); + + return (t); +} + +isc_result_t +isc_timer_touch(isc_timer_t *timer) { + isc_result_t result; + isc_time_t now; + + /* + * Set the last-touched time of 'timer' to the current time. + */ + + REQUIRE(VALID_TIMER(timer)); + + LOCK(&timer->lock); + + /* + * We'd like to + * + * REQUIRE(timer->type == isc_timertype_once); + * + * but we cannot without locking the manager lock too, which we + * don't want to do. + */ + + TIME_NOW(&now); + result = isc_time_add(&now, &timer->interval, &timer->idle); + + UNLOCK(&timer->lock); + + return (result); +} + +void +isc_timer_attach(isc_timer_t *timer, isc_timer_t **timerp) { + /* + * Attach *timerp to timer. + */ + + REQUIRE(VALID_TIMER(timer)); + REQUIRE(timerp != NULL && *timerp == NULL); + + LOCK(&timer->lock); + timer->references++; + UNLOCK(&timer->lock); + + *timerp = timer; +} + +void +isc_timer_detach(isc_timer_t **timerp) { + isc_timer_t *timer; + isc_boolean_t free_timer = ISC_FALSE; + + /* + * Detach *timerp from its timer. + */ + + REQUIRE(timerp != NULL); + timer = *timerp; + REQUIRE(VALID_TIMER(timer)); + + LOCK(&timer->lock); + REQUIRE(timer->references > 0); + timer->references--; + if (timer->references == 0) + free_timer = ISC_TRUE; + UNLOCK(&timer->lock); + + if (free_timer) + destroy(timer); + + *timerp = NULL; +} + +static void +dispatch(isc_timermgr_t *manager, isc_time_t *now) { + isc_boolean_t done = ISC_FALSE, post_event, need_schedule; + isc_timerevent_t *event; + isc_eventtype_t type = 0; + isc_timer_t *timer; + isc_result_t result; + isc_boolean_t idle; + + /*! + * The caller must be holding the manager lock. + */ + + while (manager->nscheduled > 0 && !done) { + timer = isc_heap_element(manager->heap, 1); + INSIST(timer->type != isc_timertype_inactive); + if (isc_time_compare(now, &timer->due) >= 0) { + if (timer->type == isc_timertype_ticker) { + type = ISC_TIMEREVENT_TICK; + post_event = ISC_TRUE; + need_schedule = ISC_TRUE; + } else if (timer->type == isc_timertype_limited) { + int cmp; + cmp = isc_time_compare(now, &timer->expires); + if (cmp >= 0) { + type = ISC_TIMEREVENT_LIFE; + post_event = ISC_TRUE; + need_schedule = ISC_FALSE; + } else { + type = ISC_TIMEREVENT_TICK; + post_event = ISC_TRUE; + need_schedule = ISC_TRUE; + } + } else if (!isc_time_isepoch(&timer->expires) && + isc_time_compare(now, + &timer->expires) >= 0) { + type = ISC_TIMEREVENT_LIFE; + post_event = ISC_TRUE; + need_schedule = ISC_FALSE; + } else { + idle = ISC_FALSE; + + LOCK(&timer->lock); + if (!isc_time_isepoch(&timer->idle) && + isc_time_compare(now, + &timer->idle) >= 0) { + idle = ISC_TRUE; + } + UNLOCK(&timer->lock); + if (idle) { + type = ISC_TIMEREVENT_IDLE; + post_event = ISC_TRUE; + need_schedule = ISC_FALSE; + } else { + /* + * Idle timer has been touched; + * reschedule. + */ + XTRACEID(isc_msgcat_get(isc_msgcat, + ISC_MSGSET_TIMER, + ISC_MSG_IDLERESCHED, + "idle reschedule"), + timer); + post_event = ISC_FALSE; + need_schedule = ISC_TRUE; + } + } + + if (post_event) { + XTRACEID(isc_msgcat_get(isc_msgcat, + ISC_MSGSET_TIMER, + ISC_MSG_POSTING, + "posting"), timer); + /* + * XXX We could preallocate this event. + */ + event = (isc_timerevent_t *)isc_event_allocate(manager->mctx, + timer, + type, + timer->action, + timer->arg, + sizeof(*event)); + + if (event != NULL) { + event->due = timer->due; + isc_task_send(timer->task, + ISC_EVENT_PTR(&event)); + } else + UNEXPECTED_ERROR(__FILE__, __LINE__, "%s", + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_TIMER, + ISC_MSG_EVENTNOTALLOC, + "couldn't " + "allocate event")); + } + + timer->index = 0; + isc_heap_delete(manager->heap, 1); + manager->nscheduled--; + + if (need_schedule) { + result = schedule(timer, now, ISC_FALSE); + if (result != ISC_R_SUCCESS) + UNEXPECTED_ERROR(__FILE__, __LINE__, + "%s: %u", + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_TIMER, + ISC_MSG_SCHEDFAIL, + "couldn't schedule " + "timer"), + result); + } + } else { + manager->due = timer->due; + done = ISC_TRUE; + } + } +} + +#ifdef ISC_PLATFORM_USETHREADS +static isc_threadresult_t +#ifdef _WIN32 /* XXXDCL */ +WINAPI +#endif +run(void *uap) { + isc_timermgr_t *manager = uap; + isc_time_t now; + isc_result_t result; + + LOCK(&manager->lock); + while (!manager->done) { + TIME_NOW(&now); + + XTRACETIME(isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_RUNNING, + "running"), now); + + dispatch(manager, &now); + + if (manager->nscheduled > 0) { + XTRACETIME2(isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_WAITUNTIL, + "waituntil"), + manager->due, now); + result = WAITUNTIL(&manager->wakeup, &manager->lock, &manager->due); + INSIST(result == ISC_R_SUCCESS || + result == ISC_R_TIMEDOUT); + } else { + XTRACETIME(isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_WAIT, "wait"), now); + WAIT(&manager->wakeup, &manager->lock); + } + XTRACE(isc_msgcat_get(isc_msgcat, ISC_MSGSET_TIMER, + ISC_MSG_WAKEUP, "wakeup")); + } + UNLOCK(&manager->lock); + + return ((isc_threadresult_t)0); +} +#endif /* ISC_PLATFORM_USETHREADS */ + +static isc_boolean_t +sooner(void *v1, void *v2) { + isc_timer_t *t1, *t2; + + t1 = v1; + t2 = v2; + REQUIRE(VALID_TIMER(t1)); + REQUIRE(VALID_TIMER(t2)); + + if (isc_time_compare(&t1->due, &t2->due) < 0) + return (ISC_TRUE); + return (ISC_FALSE); +} + +static void +set_index(void *what, unsigned int index) { + isc_timer_t *timer; + + timer = what; + REQUIRE(VALID_TIMER(timer)); + + timer->index = index; +} + +isc_result_t +isc_timermgr_create(isc_mem_t *mctx, isc_timermgr_t **managerp) { + isc_timermgr_t *manager; + isc_result_t result; + + /* + * Create a timer manager. + */ + + REQUIRE(managerp != NULL && *managerp == NULL); + +#ifndef ISC_PLATFORM_USETHREADS + if (timermgr != NULL) { + timermgr->refs++; + *managerp = timermgr; + return (ISC_R_SUCCESS); + } +#endif /* ISC_PLATFORM_USETHREADS */ + + manager = isc_mem_get(mctx, sizeof(*manager)); + if (manager == NULL) + return (ISC_R_NOMEMORY); + + manager->magic = TIMER_MANAGER_MAGIC; + manager->mctx = NULL; + manager->done = ISC_FALSE; + INIT_LIST(manager->timers); + manager->nscheduled = 0; + isc_time_settoepoch(&manager->due); + manager->heap = NULL; + result = isc_heap_create(mctx, sooner, set_index, 0, &manager->heap); + if (result != ISC_R_SUCCESS) { + INSIST(result == ISC_R_NOMEMORY); + isc_mem_put(mctx, manager, sizeof(*manager)); + return (ISC_R_NOMEMORY); + } + result = isc_mutex_init(&manager->lock); + if (result != ISC_R_SUCCESS) { + isc_heap_destroy(&manager->heap); + isc_mem_put(mctx, manager, sizeof(*manager)); + return (result); + } + isc_mem_attach(mctx, &manager->mctx); +#ifdef ISC_PLATFORM_USETHREADS + if (isc_condition_init(&manager->wakeup) != ISC_R_SUCCESS) { + isc_mem_detach(&manager->mctx); + DESTROYLOCK(&manager->lock); + isc_heap_destroy(&manager->heap); + isc_mem_put(mctx, manager, sizeof(*manager)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_condition_init() %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + return (ISC_R_UNEXPECTED); + } + if (isc_thread_create(run, manager, &manager->thread) != + ISC_R_SUCCESS) { + isc_mem_detach(&manager->mctx); + (void)isc_condition_destroy(&manager->wakeup); + DESTROYLOCK(&manager->lock); + isc_heap_destroy(&manager->heap); + isc_mem_put(mctx, manager, sizeof(*manager)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_thread_create() %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + return (ISC_R_UNEXPECTED); + } +#else /* ISC_PLATFORM_USETHREADS */ + manager->refs = 1; + timermgr = manager; +#endif /* ISC_PLATFORM_USETHREADS */ + + *managerp = manager; + + return (ISC_R_SUCCESS); +} + +void +isc_timermgr_poke(isc_timermgr_t *manager) { +#ifdef ISC_PLATFORM_USETHREADS + REQUIRE(VALID_MANAGER(manager)); + + SIGNAL(&manager->wakeup); +#else + UNUSED(manager); +#endif +} + +void +isc_timermgr_destroy(isc_timermgr_t **managerp) { + isc_timermgr_t *manager; + isc_mem_t *mctx; + + /* + * Destroy a timer manager. + */ + + REQUIRE(managerp != NULL); + manager = *managerp; + REQUIRE(VALID_MANAGER(manager)); + + LOCK(&manager->lock); + +#ifndef ISC_PLATFORM_USETHREADS + if (manager->refs > 1) { + manager->refs--; + UNLOCK(&manager->lock); + *managerp = NULL; + return; + } + + isc__timermgr_dispatch(); +#endif /* ISC_PLATFORM_USETHREADS */ + + REQUIRE(EMPTY(manager->timers)); + manager->done = ISC_TRUE; + +#ifdef ISC_PLATFORM_USETHREADS + XTRACE(isc_msgcat_get(isc_msgcat, ISC_MSGSET_TIMER, + ISC_MSG_SIGNALDESTROY, "signal (destroy)")); + SIGNAL(&manager->wakeup); +#endif /* ISC_PLATFORM_USETHREADS */ + + UNLOCK(&manager->lock); + +#ifdef ISC_PLATFORM_USETHREADS + /* + * Wait for thread to exit. + */ + if (isc_thread_join(manager->thread, NULL) != ISC_R_SUCCESS) + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_thread_join() %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); +#endif /* ISC_PLATFORM_USETHREADS */ + + /* + * Clean up. + */ +#ifdef ISC_PLATFORM_USETHREADS + (void)isc_condition_destroy(&manager->wakeup); +#endif /* ISC_PLATFORM_USETHREADS */ + DESTROYLOCK(&manager->lock); + isc_heap_destroy(&manager->heap); + manager->magic = 0; + mctx = manager->mctx; + isc_mem_put(mctx, manager, sizeof(*manager)); + isc_mem_detach(&mctx); + + *managerp = NULL; +} + +#ifndef ISC_PLATFORM_USETHREADS +isc_result_t +isc__timermgr_nextevent(isc_time_t *when) { + if (timermgr == NULL || timermgr->nscheduled == 0) + return (ISC_R_NOTFOUND); + *when = timermgr->due; + return (ISC_R_SUCCESS); +} + +void +isc__timermgr_dispatch(void) { + isc_time_t now; + if (timermgr == NULL) + return; + TIME_NOW(&now); + dispatch(timermgr, &now); +} +#endif /* ISC_PLATFORM_USETHREADS */ diff -urN src/contrib/ntp/lib/isc/timer_p.h src.ntp/contrib/ntp/lib/isc/timer_p.h --- src/contrib/ntp/lib/isc/timer_p.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/timer_p.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: timer_p.h,v 1.10 2007/06/19 23:47:17 tbox Exp $ */ + +#ifndef ISC_TIMER_P_H +#define ISC_TIMER_P_H + +/*! \file */ + +isc_result_t +isc__timermgr_nextevent(isc_time_t *when); + +void +isc__timermgr_dispatch(void); + +#endif /* ISC_TIMER_P_H */ diff -urN src/contrib/ntp/lib/isc/unix/app.c src.ntp/contrib/ntp/lib/isc/unix/app.c --- src/contrib/ntp/lib/isc/unix/app.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/app.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,684 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: app.c,v 1.60 2008/10/15 03:41:17 marka Exp $ */ + +/*! \file */ + +#include + +#include /* Openserver 5.0.6A and FD_SETSIZE */ +#include + +#include +#include +#include +#include +#include +#include +#ifdef HAVE_EPOLL +#include +#endif + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#ifdef ISC_PLATFORM_USETHREADS +#include +#else /* ISC_PLATFORM_USETHREADS */ +#include "../timer_p.h" +#include "../task_p.h" +#include "socket_p.h" +#endif /* ISC_PLATFORM_USETHREADS */ + +static isc_eventlist_t on_run; +static isc_mutex_t lock; +static isc_boolean_t shutdown_requested = ISC_FALSE; +static isc_boolean_t running = ISC_FALSE; +/*! + * We assume that 'want_shutdown' can be read and written atomically. + */ +static volatile isc_boolean_t want_shutdown = ISC_FALSE; +/* + * We assume that 'want_reload' can be read and written atomically. + */ +static volatile isc_boolean_t want_reload = ISC_FALSE; + +static isc_boolean_t blocked = ISC_FALSE; +#ifdef ISC_PLATFORM_USETHREADS +static pthread_t blockedthread; +#endif /* ISC_PLATFORM_USETHREADS */ + +#ifdef HAVE_LINUXTHREADS +/*! + * Linux has sigwait(), but it appears to prevent signal handlers from + * running, even if they're not in the set being waited for. This makes + * it impossible to get the default actions for SIGILL, SIGSEGV, etc. + * Instead of messing with it, we just use sigsuspend() instead. + */ +#undef HAVE_SIGWAIT +/*! + * We need to remember which thread is the main thread... + */ +static pthread_t main_thread; +#endif + +#ifndef HAVE_SIGWAIT +static void +exit_action(int arg) { + UNUSED(arg); + want_shutdown = ISC_TRUE; +} + +static void +reload_action(int arg) { + UNUSED(arg); + want_reload = ISC_TRUE; +} +#endif + +static isc_result_t +handle_signal(int sig, void (*handler)(int)) { + struct sigaction sa; + char strbuf[ISC_STRERRORSIZE]; + + memset(&sa, 0, sizeof(sa)); + sa.sa_handler = handler; + + if (sigfillset(&sa.sa_mask) != 0 || + sigaction(sig, &sa, NULL) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_APP, + ISC_MSG_SIGNALSETUP, + "handle_signal() %d setup: %s"), + sig, strbuf); + return (ISC_R_UNEXPECTED); + } + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_app_start(void) { + isc_result_t result; + int presult; + sigset_t sset; + char strbuf[ISC_STRERRORSIZE]; + + /* + * Start an ISC library application. + */ + +#ifdef NEED_PTHREAD_INIT + /* + * BSDI 3.1 seg faults in pthread_sigmask() if we don't do this. + */ + presult = pthread_init(); + if (presult != 0) { + isc__strerror(presult, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_app_start() pthread_init: %s", strbuf); + return (ISC_R_UNEXPECTED); + } +#endif + +#ifdef HAVE_LINUXTHREADS + main_thread = pthread_self(); +#endif + + result = isc_mutex_init(&lock); + if (result != ISC_R_SUCCESS) + return (result); + +#ifndef HAVE_SIGWAIT + /* + * Install do-nothing handlers for SIGINT and SIGTERM. + * + * We install them now because BSDI 3.1 won't block + * the default actions, regardless of what we do with + * pthread_sigmask(). + */ + result = handle_signal(SIGINT, exit_action); + if (result != ISC_R_SUCCESS) + return (result); + result = handle_signal(SIGTERM, exit_action); + if (result != ISC_R_SUCCESS) + return (result); +#endif + + /* + * Always ignore SIGPIPE. + */ + result = handle_signal(SIGPIPE, SIG_IGN); + if (result != ISC_R_SUCCESS) + return (result); + + /* + * On Solaris 2, delivery of a signal whose action is SIG_IGN + * will not cause sigwait() to return. We may have inherited + * unexpected actions for SIGHUP, SIGINT, and SIGTERM from our parent + * process (e.g, Solaris cron). Set an action of SIG_DFL to make + * sure sigwait() works as expected. Only do this for SIGTERM and + * SIGINT if we don't have sigwait(), since a different handler is + * installed above. + */ + result = handle_signal(SIGHUP, SIG_DFL); + if (result != ISC_R_SUCCESS) + return (result); + +#ifdef HAVE_SIGWAIT + result = handle_signal(SIGTERM, SIG_DFL); + if (result != ISC_R_SUCCESS) + return (result); + result = handle_signal(SIGINT, SIG_DFL); + if (result != ISC_R_SUCCESS) + return (result); +#endif + +#ifdef ISC_PLATFORM_USETHREADS + /* + * Block SIGHUP, SIGINT, SIGTERM. + * + * If isc_app_start() is called from the main thread before any other + * threads have been created, then the pthread_sigmask() call below + * will result in all threads having SIGHUP, SIGINT and SIGTERM + * blocked by default, ensuring that only the thread that calls + * sigwait() for them will get those signals. + */ + if (sigemptyset(&sset) != 0 || + sigaddset(&sset, SIGHUP) != 0 || + sigaddset(&sset, SIGINT) != 0 || + sigaddset(&sset, SIGTERM) != 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_app_start() sigsetops: %s", strbuf); + return (ISC_R_UNEXPECTED); + } + presult = pthread_sigmask(SIG_BLOCK, &sset, NULL); + if (presult != 0) { + isc__strerror(presult, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_app_start() pthread_sigmask: %s", + strbuf); + return (ISC_R_UNEXPECTED); + } +#else /* ISC_PLATFORM_USETHREADS */ + /* + * Unblock SIGHUP, SIGINT, SIGTERM. + * + * If we're not using threads, we need to make sure that SIGHUP, + * SIGINT and SIGTERM are not inherited as blocked from the parent + * process. + */ + if (sigemptyset(&sset) != 0 || + sigaddset(&sset, SIGHUP) != 0 || + sigaddset(&sset, SIGINT) != 0 || + sigaddset(&sset, SIGTERM) != 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_app_start() sigsetops: %s", strbuf); + return (ISC_R_UNEXPECTED); + } + presult = sigprocmask(SIG_UNBLOCK, &sset, NULL); + if (presult != 0) { + isc__strerror(presult, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_app_start() sigprocmask: %s", strbuf); + return (ISC_R_UNEXPECTED); + } +#endif /* ISC_PLATFORM_USETHREADS */ + + ISC_LIST_INIT(on_run); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_app_onrun(isc_mem_t *mctx, isc_task_t *task, isc_taskaction_t action, + void *arg) +{ + isc_event_t *event; + isc_task_t *cloned_task = NULL; + isc_result_t result; + + LOCK(&lock); + + if (running) { + result = ISC_R_ALREADYRUNNING; + goto unlock; + } + + /* + * Note that we store the task to which we're going to send the event + * in the event's "sender" field. + */ + isc_task_attach(task, &cloned_task); + event = isc_event_allocate(mctx, cloned_task, ISC_APPEVENT_SHUTDOWN, + action, arg, sizeof(*event)); + if (event == NULL) { + result = ISC_R_NOMEMORY; + goto unlock; + } + + ISC_LIST_APPEND(on_run, event, ev_link); + + result = ISC_R_SUCCESS; + + unlock: + UNLOCK(&lock); + + return (result); +} + +#ifndef ISC_PLATFORM_USETHREADS +/*! + * Event loop for nonthreaded programs. + */ +static isc_result_t +evloop(void) { + isc_result_t result; + while (!want_shutdown) { + int n; + isc_time_t when, now; + struct timeval tv, *tvp; + isc_socketwait_t *swait; + isc_boolean_t readytasks; + isc_boolean_t call_timer_dispatch = ISC_FALSE; + + readytasks = isc__taskmgr_ready(); + if (readytasks) { + tv.tv_sec = 0; + tv.tv_usec = 0; + tvp = &tv; + call_timer_dispatch = ISC_TRUE; + } else { + result = isc__timermgr_nextevent(&when); + if (result != ISC_R_SUCCESS) + tvp = NULL; + else { + isc_uint64_t us; + + TIME_NOW(&now); + us = isc_time_microdiff(&when, &now); + if (us == 0) + call_timer_dispatch = ISC_TRUE; + tv.tv_sec = us / 1000000; + tv.tv_usec = us % 1000000; + tvp = &tv; + } + } + + swait = NULL; + n = isc__socketmgr_waitevents(tvp, &swait); + + if (n == 0 || call_timer_dispatch) { + /* + * We call isc__timermgr_dispatch() only when + * necessary, in order to reduce overhead. If the + * select() call indicates a timeout, we need the + * dispatch. Even if not, if we set the 0-timeout + * for the select() call, we need to check the timer + * events. In the 'readytasks' case, there may be no + * timeout event actually, but there is no other way + * to reduce the overhead. + * Note that we do not have to worry about the case + * where a new timer is inserted during the select() + * call, since this loop only runs in the non-thread + * mode. + */ + isc__timermgr_dispatch(); + } + if (n > 0) + (void)isc__socketmgr_dispatch(swait); + (void)isc__taskmgr_dispatch(); + + if (want_reload) { + want_reload = ISC_FALSE; + return (ISC_R_RELOAD); + } + } + return (ISC_R_SUCCESS); +} + +/* + * This is a gross hack to support waiting for condition + * variables in nonthreaded programs in a limited way; + * see lib/isc/nothreads/include/isc/condition.h. + * We implement isc_condition_wait() by entering the + * event loop recursively until the want_shutdown flag + * is set by isc_condition_signal(). + */ + +/*! + * \brief True if we are currently executing in the recursive + * event loop. + */ +static isc_boolean_t in_recursive_evloop = ISC_FALSE; + +/*! + * \brief True if we are exiting the event loop as the result of + * a call to isc_condition_signal() rather than a shutdown + * or reload. + */ +static isc_boolean_t signalled = ISC_FALSE; + +isc_result_t +isc__nothread_wait_hack(isc_condition_t *cp, isc_mutex_t *mp) { + isc_result_t result; + + UNUSED(cp); + UNUSED(mp); + + INSIST(!in_recursive_evloop); + in_recursive_evloop = ISC_TRUE; + + INSIST(*mp == 1); /* Mutex must be locked on entry. */ + --*mp; + + result = evloop(); + if (result == ISC_R_RELOAD) + want_reload = ISC_TRUE; + if (signalled) { + want_shutdown = ISC_FALSE; + signalled = ISC_FALSE; + } + + ++*mp; + in_recursive_evloop = ISC_FALSE; + return (ISC_R_SUCCESS); +} + +isc_result_t +isc__nothread_signal_hack(isc_condition_t *cp) { + + UNUSED(cp); + + INSIST(in_recursive_evloop); + + want_shutdown = ISC_TRUE; + signalled = ISC_TRUE; + return (ISC_R_SUCCESS); +} + +#endif /* ISC_PLATFORM_USETHREADS */ + +isc_result_t +isc_app_run(void) { + int result; + isc_event_t *event, *next_event; + isc_task_t *task; +#ifdef ISC_PLATFORM_USETHREADS + sigset_t sset; + char strbuf[ISC_STRERRORSIZE]; +#ifdef HAVE_SIGWAIT + int sig; +#endif +#endif /* ISC_PLATFORM_USETHREADS */ + +#ifdef HAVE_LINUXTHREADS + REQUIRE(main_thread == pthread_self()); +#endif + + LOCK(&lock); + + if (!running) { + running = ISC_TRUE; + + /* + * Post any on-run events (in FIFO order). + */ + for (event = ISC_LIST_HEAD(on_run); + event != NULL; + event = next_event) { + next_event = ISC_LIST_NEXT(event, ev_link); + ISC_LIST_UNLINK(on_run, event, ev_link); + task = event->ev_sender; + event->ev_sender = NULL; + isc_task_sendanddetach(&task, &event); + } + + } + + UNLOCK(&lock); + +#ifndef HAVE_SIGWAIT + /* + * Catch SIGHUP. + * + * We do this here to ensure that the signal handler is installed + * (i.e. that it wasn't a "one-shot" handler). + */ + result = handle_signal(SIGHUP, reload_action); + if (result != ISC_R_SUCCESS) + return (ISC_R_SUCCESS); +#endif + +#ifdef ISC_PLATFORM_USETHREADS + /* + * There is no danger if isc_app_shutdown() is called before we wait + * for signals. Signals are blocked, so any such signal will simply + * be made pending and we will get it when we call sigwait(). + */ + + while (!want_shutdown) { +#ifdef HAVE_SIGWAIT + /* + * Wait for SIGHUP, SIGINT, or SIGTERM. + */ + if (sigemptyset(&sset) != 0 || + sigaddset(&sset, SIGHUP) != 0 || + sigaddset(&sset, SIGINT) != 0 || + sigaddset(&sset, SIGTERM) != 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_app_run() sigsetops: %s", strbuf); + return (ISC_R_UNEXPECTED); + } + +#ifndef HAVE_UNIXWARE_SIGWAIT + result = sigwait(&sset, &sig); + if (result == 0) { + if (sig == SIGINT || + sig == SIGTERM) + want_shutdown = ISC_TRUE; + else if (sig == SIGHUP) + want_reload = ISC_TRUE; + } + +#else /* Using UnixWare sigwait semantics. */ + sig = sigwait(&sset); + if (sig >= 0) { + if (sig == SIGINT || + sig == SIGTERM) + want_shutdown = ISC_TRUE; + else if (sig == SIGHUP) + want_reload = ISC_TRUE; + } + +#endif /* HAVE_UNIXWARE_SIGWAIT */ +#else /* Don't have sigwait(). */ + /* + * Listen for all signals. + */ + if (sigemptyset(&sset) != 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_app_run() sigsetops: %s", strbuf); + return (ISC_R_UNEXPECTED); + } + result = sigsuspend(&sset); +#endif /* HAVE_SIGWAIT */ + + if (want_reload) { + want_reload = ISC_FALSE; + return (ISC_R_RELOAD); + } + + if (want_shutdown && blocked) + exit(1); + } + +#else /* ISC_PLATFORM_USETHREADS */ + + (void)isc__taskmgr_dispatch(); + + result = evloop(); + if (result != ISC_R_SUCCESS) + return (result); + +#endif /* ISC_PLATFORM_USETHREADS */ + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_app_shutdown(void) { + isc_boolean_t want_kill = ISC_TRUE; + char strbuf[ISC_STRERRORSIZE]; + + LOCK(&lock); + + REQUIRE(running); + + if (shutdown_requested) + want_kill = ISC_FALSE; + else + shutdown_requested = ISC_TRUE; + + UNLOCK(&lock); + + if (want_kill) { +#ifdef HAVE_LINUXTHREADS + int result; + + result = pthread_kill(main_thread, SIGTERM); + if (result != 0) { + isc__strerror(result, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_app_shutdown() pthread_kill: %s", + strbuf); + return (ISC_R_UNEXPECTED); + } +#else + if (kill(getpid(), SIGTERM) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_app_shutdown() kill: %s", strbuf); + return (ISC_R_UNEXPECTED); + } +#endif + } + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_app_reload(void) { + isc_boolean_t want_kill = ISC_TRUE; + char strbuf[ISC_STRERRORSIZE]; + + LOCK(&lock); + + REQUIRE(running); + + /* + * Don't send the reload signal if we're shutting down. + */ + if (shutdown_requested) + want_kill = ISC_FALSE; + + UNLOCK(&lock); + + if (want_kill) { +#ifdef HAVE_LINUXTHREADS + int result; + + result = pthread_kill(main_thread, SIGHUP); + if (result != 0) { + isc__strerror(result, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_app_reload() pthread_kill: %s", + strbuf); + return (ISC_R_UNEXPECTED); + } +#else + if (kill(getpid(), SIGHUP) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_app_reload() kill: %s", strbuf); + return (ISC_R_UNEXPECTED); + } +#endif + } + + return (ISC_R_SUCCESS); +} + +void +isc_app_finish(void) { + DESTROYLOCK(&lock); +} + +void +isc_app_block(void) { +#ifdef ISC_PLATFORM_USETHREADS + sigset_t sset; +#endif /* ISC_PLATFORM_USETHREADS */ + REQUIRE(running); + REQUIRE(!blocked); + + blocked = ISC_TRUE; +#ifdef ISC_PLATFORM_USETHREADS + blockedthread = pthread_self(); + RUNTIME_CHECK(sigemptyset(&sset) == 0 && + sigaddset(&sset, SIGINT) == 0 && + sigaddset(&sset, SIGTERM) == 0); + RUNTIME_CHECK(pthread_sigmask(SIG_UNBLOCK, &sset, NULL) == 0); +#endif /* ISC_PLATFORM_USETHREADS */ +} + +void +isc_app_unblock(void) { +#ifdef ISC_PLATFORM_USETHREADS + sigset_t sset; +#endif /* ISC_PLATFORM_USETHREADS */ + + REQUIRE(running); + REQUIRE(blocked); + + blocked = ISC_FALSE; + +#ifdef ISC_PLATFORM_USETHREADS + REQUIRE(blockedthread == pthread_self()); + + RUNTIME_CHECK(sigemptyset(&sset) == 0 && + sigaddset(&sset, SIGINT) == 0 && + sigaddset(&sset, SIGTERM) == 0); + RUNTIME_CHECK(pthread_sigmask(SIG_BLOCK, &sset, NULL) == 0); +#endif /* ISC_PLATFORM_USETHREADS */ +} diff -urN src/contrib/ntp/lib/isc/unix/dir.c src.ntp/contrib/ntp/lib/isc/unix/dir.c --- src/contrib/ntp/lib/isc/unix/dir.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/dir.c 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,251 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: dir.c,v 1.25.332.3 2009/02/16 23:47:15 tbox Exp $ */ + +/*! \file + * \author Principal Authors: DCL */ + +#include + +#include +#include + +#include +#include +#include + +#include +#include +#include +#include + +#include "errno2result.h" + +#define ISC_DIR_MAGIC ISC_MAGIC('D', 'I', 'R', '*') +#define VALID_DIR(dir) ISC_MAGIC_VALID(dir, ISC_DIR_MAGIC) + +void +isc_dir_init(isc_dir_t *dir) { + REQUIRE(dir != NULL); + + dir->entry.name[0] = '\0'; + dir->entry.length = 0; + + dir->handle = NULL; + + dir->magic = ISC_DIR_MAGIC; +} + +/*! + * \brief Allocate workspace and open directory stream. If either one fails, + * NULL will be returned. + */ +isc_result_t +isc_dir_open(isc_dir_t *dir, const char *dirname) { + char *p; + isc_result_t result = ISC_R_SUCCESS; + + REQUIRE(VALID_DIR(dir)); + REQUIRE(dirname != NULL); + + /* + * Copy directory name. Need to have enough space for the name, + * a possible path separator, the wildcard, and the final NUL. + */ + if (strlen(dirname) + 3 > sizeof(dir->dirname)) + /* XXXDCL ? */ + return (ISC_R_NOSPACE); + strcpy(dir->dirname, dirname); + + /* + * Append path separator, if needed, and "*". + */ + p = dir->dirname + strlen(dir->dirname); + if (dir->dirname < p && *(p - 1) != '/') + *p++ = '/'; + *p++ = '*'; + *p++ = '\0'; + + /* + * Open stream. + */ + dir->handle = opendir(dirname); + + if (dir->handle == NULL) + return isc__errno2result(errno); + + return (result); +} + +/*! + * \brief Return previously retrieved file or get next one. + + * Unix's dirent has + * separate open and read functions, but the Win32 and DOS interfaces open + * the dir stream and reads the first file in one operation. + */ +isc_result_t +isc_dir_read(isc_dir_t *dir) { + struct dirent *entry; + + REQUIRE(VALID_DIR(dir) && dir->handle != NULL); + + /* + * Fetch next file in directory. + */ + entry = readdir(dir->handle); + + if (entry == NULL) + return (ISC_R_NOMORE); + + /* + * Make sure that the space for the name is long enough. + */ + if (sizeof(dir->entry.name) <= strlen(entry->d_name)) + return (ISC_R_UNEXPECTED); + + strcpy(dir->entry.name, entry->d_name); + + /* + * Some dirents have d_namlen, but it is not portable. + */ + dir->entry.length = strlen(entry->d_name); + + return (ISC_R_SUCCESS); +} + +/*! + * \brief Close directory stream. + */ +void +isc_dir_close(isc_dir_t *dir) { + REQUIRE(VALID_DIR(dir) && dir->handle != NULL); + + (void)closedir(dir->handle); + dir->handle = NULL; +} + +/*! + * \brief Reposition directory stream at start. + */ +isc_result_t +isc_dir_reset(isc_dir_t *dir) { + REQUIRE(VALID_DIR(dir) && dir->handle != NULL); + + rewinddir(dir->handle); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_dir_chdir(const char *dirname) { + /*! + * \brief Change the current directory to 'dirname'. + */ + + REQUIRE(dirname != NULL); + + if (chdir(dirname) < 0) + return (isc__errno2result(errno)); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_dir_chroot(const char *dirname) { + + REQUIRE(dirname != NULL); + +#ifdef HAVE_CHROOT + if (chroot(dirname) < 0 || chdir("/") < 0) + return (isc__errno2result(errno)); + + return (ISC_R_SUCCESS); +#else + return (ISC_R_NOTIMPLEMENTED); +#endif +} + +isc_result_t +isc_dir_createunique(char *templet) { + isc_result_t result; + char *x; + char *p; + int i; + int pid; + + REQUIRE(templet != NULL); + + /*! + * \brief mkdtemp is not portable, so this emulates it. + */ + + pid = getpid(); + + /* + * Replace trailing Xs with the process-id, zero-filled. + */ + for (x = templet + strlen(templet) - 1; *x == 'X' && x >= templet; + x--, pid /= 10) + *x = pid % 10 + '0'; + + x++; /* Set x to start of ex-Xs. */ + + do { + i = mkdir(templet, 0700); + if (i == 0 || errno != EEXIST) + break; + + /* + * The BSD algorithm. + */ + p = x; + while (*p != '\0') { + if (isdigit(*p & 0xff)) + *p = 'a'; + else if (*p != 'z') + ++*p; + else { + /* + * Reset character and move to next. + */ + *p++ = 'a'; + continue; + } + + break; + } + + if (*p == '\0') { + /* + * Tried all combinations. errno should already + * be EEXIST, but ensure it is anyway for + * isc__errno2result(). + */ + errno = EEXIST; + break; + } + } while (1); + + if (i == -1) + result = isc__errno2result(errno); + else + result = ISC_R_SUCCESS; + + return (result); +} diff -urN src/contrib/ntp/lib/isc/unix/entropy.c src.ntp/contrib/ntp/lib/isc/unix/entropy.c --- src/contrib/ntp/lib/isc/unix/entropy.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/entropy.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,605 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: entropy.c,v 1.80.332.2 2009/02/16 23:47:15 tbox Exp $ */ + +/* \file unix/entropy.c + * \brief + * This is the system dependent part of the ISC entropy API. + */ + +#include + +#include /* Openserver 5.0.6A and FD_SETSIZE */ +#include +#include +#include +#include +#include + +#ifdef HAVE_NANOSLEEP +#include +#endif +#include + +#include +#include + +#ifdef ISC_PLATFORM_NEEDSYSSELECTH +#include +#endif + +#include "errno2result.h" + +/*% + * There is only one variable in the entropy data structures that is not + * system independent, but pulling the structure that uses it into this file + * ultimately means pulling several other independent structures here also to + * resolve their interdependencies. Thus only the problem variable's type + * is defined here. + */ +#define FILESOURCE_HANDLE_TYPE int + +typedef struct { + int handle; + enum { + isc_usocketsource_disconnected, + isc_usocketsource_connecting, + isc_usocketsource_connected, + isc_usocketsource_ndesired, + isc_usocketsource_wrote, + isc_usocketsource_reading + } status; + size_t sz_to_recv; +} isc_entropyusocketsource_t; + +#include "../entropy.c" + +static unsigned int +get_from_filesource(isc_entropysource_t *source, isc_uint32_t desired) { + isc_entropy_t *ent = source->ent; + unsigned char buf[128]; + int fd = source->sources.file.handle; + ssize_t n, ndesired; + unsigned int added; + + if (source->bad) + return (0); + + desired = desired / 8 + (((desired & 0x07) > 0) ? 1 : 0); + + added = 0; + while (desired > 0) { + ndesired = ISC_MIN(desired, sizeof(buf)); + n = read(fd, buf, ndesired); + if (n < 0) { + if (errno == EAGAIN || errno == EINTR) + goto out; + goto err; + } + if (n == 0) + goto err; + + entropypool_adddata(ent, buf, n, n * 8); + added += n * 8; + desired -= n; + } + goto out; + + err: + (void)close(fd); + source->sources.file.handle = -1; + source->bad = ISC_TRUE; + + out: + return (added); +} + +static unsigned int +get_from_usocketsource(isc_entropysource_t *source, isc_uint32_t desired) { + isc_entropy_t *ent = source->ent; + unsigned char buf[128]; + int fd = source->sources.usocket.handle; + ssize_t n = 0, ndesired; + unsigned int added; + size_t sz_to_recv = source->sources.usocket.sz_to_recv; + + if (source->bad) + return (0); + + desired = desired / 8 + (((desired & 0x07) > 0) ? 1 : 0); + + added = 0; + while (desired > 0) { + ndesired = ISC_MIN(desired, sizeof(buf)); + eagain_loop: + + switch ( source->sources.usocket.status ) { + case isc_usocketsource_ndesired: + buf[0] = ndesired; + if ((n = sendto(fd, buf, 1, 0, NULL, 0)) < 0) { + if (errno == EWOULDBLOCK || errno == EINTR || + errno == ECONNRESET) + goto out; + goto err; + } + INSIST(n == 1); + source->sources.usocket.status = + isc_usocketsource_wrote; + goto eagain_loop; + + case isc_usocketsource_connecting: + case isc_usocketsource_connected: + buf[0] = 1; + buf[1] = ndesired; + if ((n = sendto(fd, buf, 2, 0, NULL, 0)) < 0) { + if (errno == EWOULDBLOCK || errno == EINTR || + errno == ECONNRESET) + goto out; + goto err; + } + if (n == 1) { + source->sources.usocket.status = + isc_usocketsource_ndesired; + goto eagain_loop; + } + INSIST(n == 2); + source->sources.usocket.status = + isc_usocketsource_wrote; + /*FALLTHROUGH*/ + + case isc_usocketsource_wrote: + if (recvfrom(fd, buf, 1, 0, NULL, NULL) != 1) { + if (errno == EAGAIN) { + /* + * The problem of EAGAIN (try again + * later) is a major issue on HP-UX. + * Solaris actually tries the recvfrom + * call again, while HP-UX just dies. + * This code is an attempt to let the + * entropy pool fill back up (at least + * that's what I think the problem is.) + * We go to eagain_loop because if we + * just "break", then the "desired" + * amount gets borked. + */ +#ifdef HAVE_NANOSLEEP + struct timespec ts; + + ts.tv_sec = 0; + ts.tv_nsec = 1000000; + nanosleep(&ts, NULL); +#else + usleep(1000); +#endif + goto eagain_loop; + } + if (errno == EWOULDBLOCK || errno == EINTR) + goto out; + goto err; + } + source->sources.usocket.status = + isc_usocketsource_reading; + sz_to_recv = buf[0]; + source->sources.usocket.sz_to_recv = sz_to_recv; + if (sz_to_recv > sizeof(buf)) + goto err; + /*FALLTHROUGH*/ + + case isc_usocketsource_reading: + if (sz_to_recv != 0U) { + n = recv(fd, buf, sz_to_recv, 0); + if (n < 0) { + if (errno == EWOULDBLOCK || + errno == EINTR) + goto out; + goto err; + } + } else + n = 0; + break; + + default: + goto err; + } + + if ((size_t)n != sz_to_recv) + source->sources.usocket.sz_to_recv -= n; + else + source->sources.usocket.status = + isc_usocketsource_connected; + + if (n == 0) + goto out; + + entropypool_adddata(ent, buf, n, n * 8); + added += n * 8; + desired -= n; + } + goto out; + + err: + close(fd); + source->bad = ISC_TRUE; + source->sources.usocket.status = isc_usocketsource_disconnected; + source->sources.usocket.handle = -1; + + out: + return (added); +} + +/* + * Poll each source, trying to get data from it to stuff into the entropy + * pool. + */ +static void +fillpool(isc_entropy_t *ent, unsigned int desired, isc_boolean_t blocking) { + unsigned int added; + unsigned int remaining; + unsigned int needed; + unsigned int nsource; + isc_entropysource_t *source; + + REQUIRE(VALID_ENTROPY(ent)); + + needed = desired; + + /* + * This logic is a little strange, so an explanation is in order. + * + * If needed is 0, it means we are being asked to "fill to whatever + * we think is best." This means that if we have at least a + * partially full pool (say, > 1/4th of the pool) we probably don't + * need to add anything. + * + * Also, we will check to see if the "pseudo" count is too high. + * If it is, try to mix in better data. Too high is currently + * defined as 1/4th of the pool. + * + * Next, if we are asked to add a specific bit of entropy, make + * certain that we will do so. Clamp how much we try to add to + * (DIGEST_SIZE * 8 < needed < POOLBITS - entropy). + * + * Note that if we are in a blocking mode, we will only try to + * get as much data as we need, not as much as we might want + * to build up. + */ + if (needed == 0) { + REQUIRE(!blocking); + + if ((ent->pool.entropy >= RND_POOLBITS / 4) + && (ent->pool.pseudo <= RND_POOLBITS / 4)) + return; + + needed = THRESHOLD_BITS * 4; + } else { + needed = ISC_MAX(needed, THRESHOLD_BITS); + needed = ISC_MIN(needed, RND_POOLBITS); + } + + /* + * In any case, clamp how much we need to how much we can add. + */ + needed = ISC_MIN(needed, RND_POOLBITS - ent->pool.entropy); + + /* + * But wait! If we're not yet initialized, we need at least + * THRESHOLD_BITS + * of randomness. + */ + if (ent->initialized < THRESHOLD_BITS) + needed = ISC_MAX(needed, THRESHOLD_BITS - ent->initialized); + + /* + * Poll each file source to see if we can read anything useful from + * it. XXXMLG When where are multiple sources, we should keep a + * record of which one we last used so we can start from it (or the + * next one) to avoid letting some sources build up entropy while + * others are always drained. + */ + + added = 0; + remaining = needed; + if (ent->nextsource == NULL) { + ent->nextsource = ISC_LIST_HEAD(ent->sources); + if (ent->nextsource == NULL) + return; + } + source = ent->nextsource; + again_file: + for (nsource = 0; nsource < ent->nsources; nsource++) { + unsigned int got; + + if (remaining == 0) + break; + + got = 0; + + switch ( source->type ) { + case ENTROPY_SOURCETYPE_FILE: + got = get_from_filesource(source, remaining); + break; + + case ENTROPY_SOURCETYPE_USOCKET: + got = get_from_usocketsource(source, remaining); + break; + } + + added += got; + + remaining -= ISC_MIN(remaining, got); + + source = ISC_LIST_NEXT(source, link); + if (source == NULL) + source = ISC_LIST_HEAD(ent->sources); + } + ent->nextsource = source; + + if (blocking && remaining != 0) { + int fds; + + fds = wait_for_sources(ent); + if (fds > 0) + goto again_file; + } + + /* + * Here, if there are bits remaining to be had and we can block, + * check to see if we have a callback source. If so, call them. + */ + source = ISC_LIST_HEAD(ent->sources); + while ((remaining != 0) && (source != NULL)) { + unsigned int got; + + got = 0; + + if (source->type == ENTROPY_SOURCETYPE_CALLBACK) + got = get_from_callback(source, remaining, blocking); + + added += got; + remaining -= ISC_MIN(remaining, got); + + if (added >= needed) + break; + + source = ISC_LIST_NEXT(source, link); + } + + /* + * Mark as initialized if we've added enough data. + */ + if (ent->initialized < THRESHOLD_BITS) + ent->initialized += added; +} + +static int +wait_for_sources(isc_entropy_t *ent) { + isc_entropysource_t *source; + int maxfd, fd; + int cc; + fd_set reads; + fd_set writes; + + maxfd = -1; + FD_ZERO(&reads); + FD_ZERO(&writes); + + source = ISC_LIST_HEAD(ent->sources); + while (source != NULL) { + if (source->type == ENTROPY_SOURCETYPE_FILE) { + fd = source->sources.file.handle; + if (fd >= 0) { + maxfd = ISC_MAX(maxfd, fd); + FD_SET(fd, &reads); + } + } + if (source->type == ENTROPY_SOURCETYPE_USOCKET) { + fd = source->sources.usocket.handle; + if (fd >= 0) { + switch (source->sources.usocket.status) { + case isc_usocketsource_disconnected: + break; + case isc_usocketsource_connecting: + case isc_usocketsource_connected: + case isc_usocketsource_ndesired: + maxfd = ISC_MAX(maxfd, fd); + FD_SET(fd, &writes); + break; + case isc_usocketsource_wrote: + case isc_usocketsource_reading: + maxfd = ISC_MAX(maxfd, fd); + FD_SET(fd, &reads); + break; + } + } + } + source = ISC_LIST_NEXT(source, link); + } + + if (maxfd < 0) + return (-1); + + cc = select(maxfd + 1, &reads, &writes, NULL, NULL); + if (cc < 0) + return (-1); + + return (cc); +} + +static void +destroyfilesource(isc_entropyfilesource_t *source) { + (void)close(source->handle); +} + +static void +destroyusocketsource(isc_entropyusocketsource_t *source) { + close(source->handle); +} + +/* + * Make a fd non-blocking + */ +static isc_result_t +make_nonblock(int fd) { + int ret; + int flags; + char strbuf[ISC_STRERRORSIZE]; +#ifdef USE_FIONBIO_IOCTL + int on = 1; + + ret = ioctl(fd, FIONBIO, (char *)&on); +#else + flags = fcntl(fd, F_GETFL, 0); + flags |= PORT_NONBLOCK; + ret = fcntl(fd, F_SETFL, flags); +#endif + + if (ret == -1) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, +#ifdef USE_FIONBIO_IOCTL + "ioctl(%d, FIONBIO, &on): %s", fd, +#else + "fcntl(%d, F_SETFL, %d): %s", fd, flags, +#endif + strbuf); + + return (ISC_R_UNEXPECTED); + } + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_entropy_createfilesource(isc_entropy_t *ent, const char *fname) { + int fd; + struct stat _stat; + isc_boolean_t is_usocket = ISC_FALSE; + isc_boolean_t is_connected = ISC_FALSE; + isc_result_t ret; + isc_entropysource_t *source; + + REQUIRE(VALID_ENTROPY(ent)); + REQUIRE(fname != NULL); + + LOCK(&ent->lock); + + if (stat(fname, &_stat) < 0) { + ret = isc__errno2result(errno); + goto errout; + } + /* + * Solaris 2.5.1 does not have support for sockets (S_IFSOCK), + * but it does return type S_IFIFO (the OS believes that + * the socket is a fifo). This may be an issue if we tell + * the program to look at an actual FIFO as its source of + * entropy. + */ +#if defined(S_ISSOCK) + if (S_ISSOCK(_stat.st_mode)) + is_usocket = ISC_TRUE; +#endif +#if defined(S_ISFIFO) && defined(sun) + if (S_ISFIFO(_stat.st_mode)) + is_usocket = ISC_TRUE; +#endif + if (is_usocket) + fd = socket(PF_UNIX, SOCK_STREAM, 0); + else + fd = open(fname, O_RDONLY | PORT_NONBLOCK, 0); + + if (fd < 0) { + ret = isc__errno2result(errno); + goto errout; + } + + ret = make_nonblock(fd); + if (ret != ISC_R_SUCCESS) + goto closefd; + + if (is_usocket) { + struct sockaddr_un sname; + + memset(&sname, 0, sizeof(sname)); + sname.sun_family = AF_UNIX; + strncpy(sname.sun_path, fname, sizeof(sname.sun_path)); + sname.sun_path[sizeof(sname.sun_path)-1] = '0'; +#ifdef ISC_PLATFORM_HAVESALEN +#if !defined(SUN_LEN) +#define SUN_LEN(su) \ + (sizeof(*(su)) - sizeof((su)->sun_path) + strlen((su)->sun_path)) +#endif + sname.sun_len = SUN_LEN(&sname); +#endif + + if (connect(fd, (struct sockaddr *) &sname, + sizeof(struct sockaddr_un)) < 0) { + if (errno != EINPROGRESS) { + ret = isc__errno2result(errno); + goto closefd; + } + } else + is_connected = ISC_TRUE; + } + + source = isc_mem_get(ent->mctx, sizeof(isc_entropysource_t)); + if (source == NULL) { + ret = ISC_R_NOMEMORY; + goto closefd; + } + + /* + * From here down, no failures can occur. + */ + source->magic = SOURCE_MAGIC; + source->ent = ent; + source->total = 0; + source->bad = ISC_FALSE; + memset(source->name, 0, sizeof(source->name)); + ISC_LINK_INIT(source, link); + if (is_usocket) { + source->sources.usocket.handle = fd; + if (is_connected) + source->sources.usocket.status = + isc_usocketsource_connected; + else + source->sources.usocket.status = + isc_usocketsource_connecting; + source->sources.usocket.sz_to_recv = 0; + source->type = ENTROPY_SOURCETYPE_USOCKET; + } else { + source->sources.file.handle = fd; + source->type = ENTROPY_SOURCETYPE_FILE; + } + + /* + * Hook it into the entropy system. + */ + ISC_LIST_APPEND(ent->sources, source, link); + ent->nsources++; + + UNLOCK(&ent->lock); + return (ISC_R_SUCCESS); + + closefd: + (void)close(fd); + + errout: + UNLOCK(&ent->lock); + + return (ret); +} diff -urN src/contrib/ntp/lib/isc/unix/errno2result.c src.ntp/contrib/ntp/lib/isc/unix/errno2result.c --- src/contrib/ntp/lib/isc/unix/errno2result.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/errno2result.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,123 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: errno2result.c,v 1.17 2007/06/19 23:47:18 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include + +#include "errno2result.h" + +/*% + * Convert a POSIX errno value into an isc_result_t. The + * list of supported errno values is not complete; new users + * of this function should add any expected errors that are + * not already there. + */ +isc_result_t +isc__errno2result(int posixerrno) { + char strbuf[ISC_STRERRORSIZE]; + + switch (posixerrno) { + case ENOTDIR: + case ELOOP: + case EINVAL: /* XXX sometimes this is not for files */ + case ENAMETOOLONG: + case EBADF: + return (ISC_R_INVALIDFILE); + case ENOENT: + return (ISC_R_FILENOTFOUND); + case EACCES: + case EPERM: + return (ISC_R_NOPERM); + case EEXIST: + return (ISC_R_FILEEXISTS); + case EIO: + return (ISC_R_IOERROR); + case ENOMEM: + return (ISC_R_NOMEMORY); + case ENFILE: + case EMFILE: + return (ISC_R_TOOMANYOPENFILES); + case EPIPE: +#ifdef ECONNRESET + case ECONNRESET: +#endif +#ifdef ECONNABORTED + case ECONNABORTED: +#endif + return (ISC_R_CONNECTIONRESET); +#ifdef ENOTCONN + case ENOTCONN: + return (ISC_R_NOTCONNECTED); +#endif +#ifdef ETIMEDOUT + case ETIMEDOUT: + return (ISC_R_TIMEDOUT); +#endif +#ifdef ENOBUFS + case ENOBUFS: + return (ISC_R_NORESOURCES); +#endif +#ifdef EAFNOSUPPORT + case EAFNOSUPPORT: + return (ISC_R_FAMILYNOSUPPORT); +#endif +#ifdef ENETDOWN + case ENETDOWN: + return (ISC_R_NETDOWN); +#endif +#ifdef EHOSTDOWN + case EHOSTDOWN: + return (ISC_R_HOSTDOWN); +#endif +#ifdef ENETUNREACH + case ENETUNREACH: + return (ISC_R_NETUNREACH); +#endif +#ifdef EHOSTUNREACH + case EHOSTUNREACH: + return (ISC_R_HOSTUNREACH); +#endif +#ifdef EADDRINUSE + case EADDRINUSE: + return (ISC_R_ADDRINUSE); +#endif + case EADDRNOTAVAIL: + return (ISC_R_ADDRNOTAVAIL); + case ECONNREFUSED: + return (ISC_R_CONNREFUSED); + default: + isc__strerror(posixerrno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "unable to convert errno " + "to isc_result: %d: %s", + posixerrno, strbuf); + /* + * XXXDCL would be nice if perhaps this function could + * return the system's error string, so the caller + * might have something more descriptive than "unexpected + * error" to log with. + */ + return (ISC_R_UNEXPECTED); + } +} diff -urN src/contrib/ntp/lib/isc/unix/errno2result.h src.ntp/contrib/ntp/lib/isc/unix/errno2result.h --- src/contrib/ntp/lib/isc/unix/errno2result.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/errno2result.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,39 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: errno2result.h,v 1.12 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef UNIX_ERRNO2RESULT_H +#define UNIX_ERRNO2RESULT_H 1 + +/*! \file */ + +/* XXXDCL this should be moved to lib/isc/include/isc/errno2result.h. */ + +#include /* Provides errno. */ + +#include +#include + +ISC_LANG_BEGINDECLS + +isc_result_t +isc__errno2result(int posixerrno); + +ISC_LANG_ENDDECLS + +#endif /* UNIX_ERRNO2RESULT_H */ diff -urN src/contrib/ntp/lib/isc/unix/file.c src.ntp/contrib/ntp/lib/isc/unix/file.c --- src/contrib/ntp/lib/isc/unix/file.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/file.c 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,444 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* + * Portions Copyright (c) 1987, 1993 + * The Regents of the University of California. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +/* $Id: file.c,v 1.51.332.2 2009/02/16 23:47:15 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include +#include +#include /* Required for utimes on some platforms. */ +#include /* Required for mkstemp on NetBSD. */ + + +#include +#include + +#include +#include +#include +#include +#include +#include +#include + +#include "errno2result.h" + +/* + * XXXDCL As the API for accessing file statistics undoubtedly gets expanded, + * it might be good to provide a mechanism that allows for the results + * of a previous stat() to be used again without having to do another stat, + * such as perl's mechanism of using "_" in place of a file name to indicate + * that the results of the last stat should be used. But then you get into + * annoying MP issues. BTW, Win32 has stat(). + */ +static isc_result_t +file_stats(const char *file, struct stat *stats) { + isc_result_t result = ISC_R_SUCCESS; + + REQUIRE(file != NULL); + REQUIRE(stats != NULL); + + if (stat(file, stats) != 0) + result = isc__errno2result(errno); + + return (result); +} + +isc_result_t +isc_file_getmodtime(const char *file, isc_time_t *time) { + isc_result_t result; + struct stat stats; + + REQUIRE(file != NULL); + REQUIRE(time != NULL); + + result = file_stats(file, &stats); + + if (result == ISC_R_SUCCESS) + /* + * XXXDCL some operating systems provide nanoseconds, too, + * such as BSD/OS via st_mtimespec. + */ + isc_time_set(time, stats.st_mtime, 0); + + return (result); +} + +isc_result_t +isc_file_settime(const char *file, isc_time_t *time) { + struct timeval times[2]; + + REQUIRE(file != NULL && time != NULL); + + /* + * tv_sec is at least a 32 bit quantity on all platforms we're + * dealing with, but it is signed on most (all?) of them, + * so we need to make sure the high bit isn't set. This unfortunately + * loses when either: + * * tv_sec becomes a signed 64 bit integer but long is 32 bits + * and isc_time_seconds > LONG_MAX, or + * * isc_time_seconds is changed to be > 32 bits but long is 32 bits + * and isc_time_seconds has at least 33 significant bits. + */ + times[0].tv_sec = times[1].tv_sec = (long)isc_time_seconds(time); + + /* + * Here is the real check for the high bit being set. + */ + if ((times[0].tv_sec & + (1ULL << (sizeof(times[0].tv_sec) * CHAR_BIT - 1))) != 0) + return (ISC_R_RANGE); + + /* + * isc_time_nanoseconds guarantees a value that divided by 1000 will + * fit into the minimum possible size tv_usec field. Unfortunately, + * we don't know what that type is so can't cast directly ... but + * we can at least cast to signed so the IRIX compiler shuts up. + */ + times[0].tv_usec = times[1].tv_usec = + (isc_int32_t)(isc_time_nanoseconds(time) / 1000); + + if (utimes(file, times) < 0) + return (isc__errno2result(errno)); + + return (ISC_R_SUCCESS); +} + +#undef TEMPLATE +#define TEMPLATE "tmp-XXXXXXXXXX" /*%< 14 characters. */ + +isc_result_t +isc_file_mktemplate(const char *path, char *buf, size_t buflen) { + return (isc_file_template(path, TEMPLATE, buf, buflen)); +} + +isc_result_t +isc_file_template(const char *path, const char *templet, char *buf, + size_t buflen) { + char *s; + + REQUIRE(path != NULL); + REQUIRE(templet != NULL); + REQUIRE(buf != NULL); + + s = strrchr(templet, '/'); + if (s != NULL) + templet = s + 1; + + s = strrchr(path, '/'); + + if (s != NULL) { + if ((s - path + 1 + strlen(templet) + 1) > buflen) + return (ISC_R_NOSPACE); + + strncpy(buf, path, s - path + 1); + buf[s - path + 1] = '\0'; + strcat(buf, templet); + } else { + if ((strlen(templet) + 1) > buflen) + return (ISC_R_NOSPACE); + + strcpy(buf, templet); + } + + return (ISC_R_SUCCESS); +} + +static char alphnum[] = + "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"; + +isc_result_t +isc_file_renameunique(const char *file, char *templet) { + char *x; + char *cp; + isc_uint32_t which; + + REQUIRE(file != NULL); + REQUIRE(templet != NULL); + + cp = templet; + while (*cp != '\0') + cp++; + if (cp == templet) + return (ISC_R_FAILURE); + + x = cp--; + while (cp >= templet && *cp == 'X') { + isc_random_get(&which); + *cp = alphnum[which % (sizeof(alphnum) - 1)]; + x = cp--; + } + while (link(file, templet) == -1) { + if (errno != EEXIST) + return (isc__errno2result(errno)); + for (cp = x;;) { + char *t; + if (*cp == '\0') + return (ISC_R_FAILURE); + t = strchr(alphnum, *cp); + if (t == NULL || *++t == '\0') + *cp++ = alphnum[0]; + else { + *cp = *t; + break; + } + } + } + if (unlink(file) < 0) + if (errno != ENOENT) + return (isc__errno2result(errno)); + return (ISC_R_SUCCESS); +} + + +isc_result_t +isc_file_openunique(char *templet, FILE **fp) { + int fd; + FILE *f; + isc_result_t result = ISC_R_SUCCESS; + char *x; + char *cp; + isc_uint32_t which; + int mode; + + REQUIRE(templet != NULL); + REQUIRE(fp != NULL && *fp == NULL); + + cp = templet; + while (*cp != '\0') + cp++; + if (cp == templet) + return (ISC_R_FAILURE); + + x = cp--; + while (cp >= templet && *cp == 'X') { + isc_random_get(&which); + *cp = alphnum[which % (sizeof(alphnum) - 1)]; + x = cp--; + } + + mode = S_IWUSR|S_IRUSR|S_IRGRP|S_IWGRP|S_IROTH|S_IWOTH; + + while ((fd = open(templet, O_RDWR|O_CREAT|O_EXCL, mode)) == -1) { + if (errno != EEXIST) + return (isc__errno2result(errno)); + for (cp = x;;) { + char *t; + if (*cp == '\0') + return (ISC_R_FAILURE); + t = strchr(alphnum, *cp); + if (t == NULL || *++t == '\0') + *cp++ = alphnum[0]; + else { + *cp = *t; + break; + } + } + } + f = fdopen(fd, "w+"); + if (f == NULL) { + result = isc__errno2result(errno); + if (remove(templet) < 0) { + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_FILE, ISC_LOG_ERROR, + "remove '%s': failed", templet); + } + (void)close(fd); + } else + *fp = f; + + return (result); +} + +isc_result_t +isc_file_remove(const char *filename) { + int r; + + REQUIRE(filename != NULL); + + r = unlink(filename); + if (r == 0) + return (ISC_R_SUCCESS); + else + return (isc__errno2result(errno)); +} + +isc_result_t +isc_file_rename(const char *oldname, const char *newname) { + int r; + + REQUIRE(oldname != NULL); + REQUIRE(newname != NULL); + + r = rename(oldname, newname); + if (r == 0) + return (ISC_R_SUCCESS); + else + return (isc__errno2result(errno)); +} + +isc_boolean_t +isc_file_exists(const char *pathname) { + struct stat stats; + + REQUIRE(pathname != NULL); + + return (ISC_TF(file_stats(pathname, &stats) == ISC_R_SUCCESS)); +} + +isc_boolean_t +isc_file_isabsolute(const char *filename) { + REQUIRE(filename != NULL); + return (ISC_TF(filename[0] == '/')); +} + +isc_boolean_t +isc_file_iscurrentdir(const char *filename) { + REQUIRE(filename != NULL); + return (ISC_TF(filename[0] == '.' && filename[1] == '\0')); +} + +isc_boolean_t +isc_file_ischdiridempotent(const char *filename) { + REQUIRE(filename != NULL); + if (isc_file_isabsolute(filename)) + return (ISC_TRUE); + if (isc_file_iscurrentdir(filename)) + return (ISC_TRUE); + return (ISC_FALSE); +} + +const char * +isc_file_basename(const char *filename) { + char *s; + + REQUIRE(filename != NULL); + + s = strrchr(filename, '/'); + if (s == NULL) + return (filename); + + return (s + 1); +} + +isc_result_t +isc_file_progname(const char *filename, char *buf, size_t buflen) { + const char *base; + size_t len; + + REQUIRE(filename != NULL); + REQUIRE(buf != NULL); + + base = isc_file_basename(filename); + len = strlen(base) + 1; + + if (len > buflen) + return (ISC_R_NOSPACE); + memcpy(buf, base, len); + + return (ISC_R_SUCCESS); +} + +/* + * Put the absolute name of the current directory into 'dirname', which is + * a buffer of at least 'length' characters. End the string with the + * appropriate path separator, such that the final product could be + * concatenated with a relative pathname to make a valid pathname string. + */ +static isc_result_t +dir_current(char *dirname, size_t length) { + char *cwd; + isc_result_t result = ISC_R_SUCCESS; + + REQUIRE(dirname != NULL); + REQUIRE(length > 0U); + + cwd = getcwd(dirname, length); + + if (cwd == NULL) { + if (errno == ERANGE) + result = ISC_R_NOSPACE; + else + result = isc__errno2result(errno); + } else { + if (strlen(dirname) + 1 == length) + result = ISC_R_NOSPACE; + else if (dirname[1] != '\0') + strcat(dirname, "/"); + } + + return (result); +} + +isc_result_t +isc_file_absolutepath(const char *filename, char *path, size_t pathlen) { + isc_result_t result; + result = dir_current(path, pathlen); + if (result != ISC_R_SUCCESS) + return (result); + if (strlen(path) + strlen(filename) + 1 > pathlen) + return (ISC_R_NOSPACE); + strcat(path, filename); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_file_truncate(const char *filename, isc_offset_t size) { + isc_result_t result = ISC_R_SUCCESS; + + if (truncate(filename, size) < 0) + result = isc__errno2result(errno); + return (result); +} diff -urN src/contrib/ntp/lib/isc/unix/fsaccess.c src.ntp/contrib/ntp/lib/isc/unix/fsaccess.c --- src/contrib/ntp/lib/isc/unix/fsaccess.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/fsaccess.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,93 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: fsaccess.c,v 1.13 2007/06/19 23:47:18 tbox Exp $ */ + +#include + +#include +#include + +#include + +#include "errno2result.h" + +/*! \file + * \brief + * The OS-independent part of the API is in lib/isc. + */ +#include "../fsaccess.c" + +isc_result_t +isc_fsaccess_set(const char *path, isc_fsaccess_t access) { + struct stat statb; + mode_t mode; + isc_boolean_t is_dir = ISC_FALSE; + isc_fsaccess_t bits; + isc_result_t result; + + if (stat(path, &statb) != 0) + return (isc__errno2result(errno)); + + if ((statb.st_mode & S_IFDIR) != 0) + is_dir = ISC_TRUE; + else if ((statb.st_mode & S_IFREG) == 0) + return (ISC_R_INVALIDFILE); + + result = check_bad_bits(access, is_dir); + if (result != ISC_R_SUCCESS) + return (result); + + /* + * Done with checking bad bits. Set mode_t. + */ + mode = 0; + +#define SET_AND_CLEAR1(modebit) \ + if ((access & bits) != 0) { \ + mode |= modebit; \ + access &= ~bits; \ + } +#define SET_AND_CLEAR(user, group, other) \ + SET_AND_CLEAR1(user); \ + bits <<= STEP; \ + SET_AND_CLEAR1(group); \ + bits <<= STEP; \ + SET_AND_CLEAR1(other); + + bits = ISC_FSACCESS_READ | ISC_FSACCESS_LISTDIRECTORY; + + SET_AND_CLEAR(S_IRUSR, S_IRGRP, S_IROTH); + + bits = ISC_FSACCESS_WRITE | + ISC_FSACCESS_CREATECHILD | + ISC_FSACCESS_DELETECHILD; + + SET_AND_CLEAR(S_IWUSR, S_IWGRP, S_IWOTH); + + bits = ISC_FSACCESS_EXECUTE | + ISC_FSACCESS_ACCESSCHILD; + + SET_AND_CLEAR(S_IXUSR, S_IXGRP, S_IXOTH); + + INSIST(access == 0); + + if (chmod(path, mode) < 0) + return (isc__errno2result(errno)); + + return (ISC_R_SUCCESS); +} diff -urN src/contrib/ntp/lib/isc/unix/ifiter_getifaddrs.c src.ntp/contrib/ntp/lib/isc/unix/ifiter_getifaddrs.c --- src/contrib/ntp/lib/isc/unix/ifiter_getifaddrs.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/ifiter_getifaddrs.c 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,247 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: ifiter_getifaddrs.c,v 1.11 2008/03/20 23:47:00 tbox Exp $ */ + +/*! \file + * \brief + * Obtain the list of network interfaces using the getifaddrs(3) library. + */ + +#include + +/*% Iterator Magic */ +#define IFITER_MAGIC ISC_MAGIC('I', 'F', 'I', 'G') +/*% Valid Iterator */ +#define VALID_IFITER(t) ISC_MAGIC_VALID(t, IFITER_MAGIC) + +#ifdef __linux +static isc_boolean_t seenv6 = ISC_FALSE; +#endif + +/*% Iterator structure */ +struct isc_interfaceiter { + unsigned int magic; /*%< Magic number. */ + isc_mem_t *mctx; + void *buf; /*%< (unused) */ + unsigned int bufsize; /*%< (always 0) */ + struct ifaddrs *ifaddrs; /*%< List of ifaddrs */ + struct ifaddrs *pos; /*%< Ptr to current ifaddr */ + isc_interface_t current; /*%< Current interface data. */ + isc_result_t result; /*%< Last result code. */ +#ifdef __linux + FILE * proc; + char entry[ISC_IF_INET6_SZ]; + isc_result_t valid; +#endif +}; + +isc_result_t +isc_interfaceiter_create(isc_mem_t *mctx, isc_interfaceiter_t **iterp) { + isc_interfaceiter_t *iter; + isc_result_t result; + char strbuf[ISC_STRERRORSIZE]; + + REQUIRE(mctx != NULL); + REQUIRE(iterp != NULL); + REQUIRE(*iterp == NULL); + + iter = isc_mem_get(mctx, sizeof(*iter)); + if (iter == NULL) + return (ISC_R_NOMEMORY); + + iter->mctx = mctx; + iter->buf = NULL; + iter->bufsize = 0; + iter->ifaddrs = NULL; +#ifdef __linux + /* + * Only open "/proc/net/if_inet6" if we have never seen a IPv6 + * address returned by getifaddrs(). + */ + if (!seenv6) + iter->proc = fopen("/proc/net/if_inet6", "r"); + else + iter->proc = NULL; + iter->valid = ISC_R_FAILURE; +#endif + + if (getifaddrs(&iter->ifaddrs) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_IFITERGETIFADDRS, + ISC_MSG_GETIFADDRS, + "getting interface " + "addresses: getifaddrs: %s"), + strbuf); + result = ISC_R_UNEXPECTED; + goto failure; + } + + /* + * A newly created iterator has an undefined position + * until isc_interfaceiter_first() is called. + */ + iter->pos = NULL; + iter->result = ISC_R_FAILURE; + + iter->magic = IFITER_MAGIC; + *iterp = iter; + return (ISC_R_SUCCESS); + + failure: +#ifdef __linux + if (iter->proc != NULL) + fclose(iter->proc); +#endif + if (iter->ifaddrs != NULL) /* just in case */ + freeifaddrs(iter->ifaddrs); + isc_mem_put(mctx, iter, sizeof(*iter)); + return (result); +} + +/* + * Get information about the current interface to iter->current. + * If successful, return ISC_R_SUCCESS. + * If the interface has an unsupported address family, + * return ISC_R_IGNORE. + */ + +static isc_result_t +internal_current(isc_interfaceiter_t *iter) { + struct ifaddrs *ifa; + int family; + unsigned int namelen; + + REQUIRE(VALID_IFITER(iter)); + + ifa = iter->pos; + +#ifdef __linux + if (iter->pos == NULL) + return (linux_if_inet6_current(iter)); +#endif + + INSIST(ifa != NULL); + INSIST(ifa->ifa_name != NULL); + + if (ifa->ifa_addr == NULL) + return (ISC_R_IGNORE); + + family = ifa->ifa_addr->sa_family; + if (family != AF_INET && family != AF_INET6) + return (ISC_R_IGNORE); + +#ifdef __linux + if (family == AF_INET6) + seenv6 = ISC_TRUE; +#endif + + memset(&iter->current, 0, sizeof(iter->current)); + + namelen = strlen(ifa->ifa_name); + if (namelen > sizeof(iter->current.name) - 1) + namelen = sizeof(iter->current.name) - 1; + + memset(iter->current.name, 0, sizeof(iter->current.name)); + memcpy(iter->current.name, ifa->ifa_name, namelen); + + iter->current.flags = 0; + + if ((ifa->ifa_flags & IFF_UP) != 0) + iter->current.flags |= INTERFACE_F_UP; + + if ((ifa->ifa_flags & IFF_POINTOPOINT) != 0) + iter->current.flags |= INTERFACE_F_POINTTOPOINT; + + if ((ifa->ifa_flags & IFF_LOOPBACK) != 0) + iter->current.flags |= INTERFACE_F_LOOPBACK; + + if ((ifa->ifa_flags & IFF_BROADCAST) != 0) + iter->current.flags |= INTERFACE_F_BROADCAST; + +#ifdef IFF_MULTICAST + if ((ifa->ifa_flags & IFF_MULTICAST) != 0) + iter->current.flags |= INTERFACE_F_MULTICAST; +#endif + + iter->current.af = family; + + get_addr(family, &iter->current.address, ifa->ifa_addr, ifa->ifa_name); + + if (ifa->ifa_netmask != NULL) + get_addr(family, &iter->current.netmask, ifa->ifa_netmask, + ifa->ifa_name); + + if (ifa->ifa_dstaddr != NULL && + (iter->current.flags & INTERFACE_F_POINTTOPOINT) != 0) + get_addr(family, &iter->current.dstaddress, ifa->ifa_dstaddr, + ifa->ifa_name); + + if (ifa->ifa_broadaddr != NULL && + (iter->current.flags & INTERFACE_F_BROADCAST) != 0) + get_addr(family, &iter->current.broadcast, ifa->ifa_broadaddr, + ifa->ifa_name); + + return (ISC_R_SUCCESS); +} + +/* + * Step the iterator to the next interface. Unlike + * isc_interfaceiter_next(), this may leave the iterator + * positioned on an interface that will ultimately + * be ignored. Return ISC_R_NOMORE if there are no more + * interfaces, otherwise ISC_R_SUCCESS. + */ +static isc_result_t +internal_next(isc_interfaceiter_t *iter) { + + if (iter->pos != NULL) + iter->pos = iter->pos->ifa_next; + if (iter->pos == NULL) { +#ifdef __linux + if (!seenv6) + return (linux_if_inet6_next(iter)); +#endif + return (ISC_R_NOMORE); + } + + return (ISC_R_SUCCESS); +} + +static void +internal_destroy(isc_interfaceiter_t *iter) { + +#ifdef __linux + if (iter->proc != NULL) + fclose(iter->proc); + iter->proc = NULL; +#endif + if (iter->ifaddrs) + freeifaddrs(iter->ifaddrs); + iter->ifaddrs = NULL; +} + +static +void internal_first(isc_interfaceiter_t *iter) { + +#ifdef __linux + linux_if_inet6_first(iter); +#endif + iter->pos = iter->ifaddrs; +} diff -urN src/contrib/ntp/lib/isc/unix/ifiter_ioctl.c src.ntp/contrib/ntp/lib/isc/unix/ifiter_ioctl.c --- src/contrib/ntp/lib/isc/unix/ifiter_ioctl.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/ifiter_ioctl.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,1007 @@ +/* + * Copyright (C) 2004-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: ifiter_ioctl.c,v 1.60.120.2 2009/01/18 23:47:41 tbox Exp $ */ + +/*! \file + * \brief + * Obtain the list of network interfaces using the SIOCGLIFCONF ioctl. + * See netintro(4). + */ + +#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) +#ifdef ISC_PLATFORM_HAVEIF_LADDRCONF +#define lifc_len iflc_len +#define lifc_buf iflc_buf +#define lifc_req iflc_req +#define LIFCONF if_laddrconf +#else +#define ISC_HAVE_LIFC_FAMILY 1 +#define ISC_HAVE_LIFC_FLAGS 1 +#define LIFCONF lifconf +#endif + +#ifdef ISC_PLATFORM_HAVEIF_LADDRREQ +#define lifr_addr iflr_addr +#define lifr_name iflr_name +#define lifr_dstaddr iflr_dstaddr +#define lifr_broadaddr iflr_broadaddr +#define lifr_flags iflr_flags +#define lifr_index iflr_index +#define ss_family sa_family +#define LIFREQ if_laddrreq +#else +#define LIFREQ lifreq +#endif +#endif + +#define IFITER_MAGIC ISC_MAGIC('I', 'F', 'I', 'T') +#define VALID_IFITER(t) ISC_MAGIC_VALID(t, IFITER_MAGIC) + +struct isc_interfaceiter { + unsigned int magic; /* Magic number. */ + isc_mem_t *mctx; + int mode; + int socket; + struct ifconf ifc; + void *buf; /* Buffer for sysctl data. */ + unsigned int bufsize; /* Bytes allocated. */ + unsigned int pos; /* Current offset in + SIOCGIFCONF data */ +#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) + int socket6; + struct LIFCONF lifc; + void *buf6; /* Buffer for sysctl data. */ + unsigned int bufsize6; /* Bytes allocated. */ + unsigned int pos6; /* Current offset in + SIOCGLIFCONF data */ + isc_result_t result6; /* Last result code. */ + isc_boolean_t first6; +#endif +#ifdef HAVE_TRUCLUSTER + int clua_context; /* Cluster alias context */ + isc_boolean_t clua_done; + struct sockaddr clua_sa; +#endif +#ifdef __linux + FILE * proc; + char entry[ISC_IF_INET6_SZ]; + isc_result_t valid; +#endif + isc_interface_t current; /* Current interface data. */ + isc_result_t result; /* Last result code. */ +}; + +#ifdef HAVE_TRUCLUSTER +#include +#include +#endif + + +/*% + * Size of buffer for SIOCGLIFCONF, in bytes. We assume no sane system + * will have more than a megabyte of interface configuration data. + */ +#define IFCONF_BUFSIZE_INITIAL 4096 +#define IFCONF_BUFSIZE_MAX 1048576 + +#ifdef __linux +#ifndef IF_NAMESIZE +# ifdef IFNAMSIZ +# define IF_NAMESIZE IFNAMSIZ +# else +# define IF_NAMESIZE 16 +# endif +#endif +#endif + +static isc_result_t +getbuf4(isc_interfaceiter_t *iter) { + char strbuf[ISC_STRERRORSIZE]; + + iter->bufsize = IFCONF_BUFSIZE_INITIAL; + + for (;;) { + iter->buf = isc_mem_get(iter->mctx, iter->bufsize); + if (iter->buf == NULL) + return (ISC_R_NOMEMORY); + + memset(&iter->ifc.ifc_len, 0, sizeof(iter->ifc.ifc_len)); + iter->ifc.ifc_len = iter->bufsize; + iter->ifc.ifc_buf = iter->buf; + /* + * Ignore the HP/UX warning about "integer overflow during + * conversion". It comes from its own macro definition, + * and is really hard to shut up. + */ + if (ioctl(iter->socket, SIOCGIFCONF, (char *)&iter->ifc) + == -1) { + if (errno != EINVAL) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_IFITERIOCTL, + ISC_MSG_GETIFCONFIG, + "get interface " + "configuration: %s"), + strbuf); + goto unexpected; + } + /* + * EINVAL. Retry with a bigger buffer. + */ + } else { + /* + * The ioctl succeeded. + * Some OS's just return what will fit rather + * than set EINVAL if the buffer is too small + * to fit all the interfaces in. If + * ifc.lifc_len is too near to the end of the + * buffer we will grow it just in case and + * retry. + */ + if (iter->ifc.ifc_len + 2 * sizeof(struct ifreq) + < iter->bufsize) + break; + } + if (iter->bufsize >= IFCONF_BUFSIZE_MAX) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_IFITERIOCTL, + ISC_MSG_BUFFERMAX, + "get interface " + "configuration: " + "maximum buffer " + "size exceeded")); + goto unexpected; + } + isc_mem_put(iter->mctx, iter->buf, iter->bufsize); + + iter->bufsize *= 2; + } + return (ISC_R_SUCCESS); + + unexpected: + isc_mem_put(iter->mctx, iter->buf, iter->bufsize); + iter->buf = NULL; + return (ISC_R_UNEXPECTED); +} + +#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) +static isc_result_t +getbuf6(isc_interfaceiter_t *iter) { + char strbuf[ISC_STRERRORSIZE]; + isc_result_t result; + + iter->bufsize6 = IFCONF_BUFSIZE_INITIAL; + + for (;;) { + iter->buf6 = isc_mem_get(iter->mctx, iter->bufsize6); + if (iter->buf6 == NULL) + return (ISC_R_NOMEMORY); + + memset(&iter->lifc, 0, sizeof(iter->lifc)); +#ifdef ISC_HAVE_LIFC_FAMILY + iter->lifc.lifc_family = AF_INET6; +#endif +#ifdef ISC_HAVE_LIFC_FLAGS + iter->lifc.lifc_flags = 0; +#endif + iter->lifc.lifc_len = iter->bufsize6; + iter->lifc.lifc_buf = iter->buf6; + /* + * Ignore the HP/UX warning about "integer overflow during + * conversion". It comes from its own macro definition, + * and is really hard to shut up. + */ + if (ioctl(iter->socket6, SIOCGLIFCONF, (char *)&iter->lifc) + == -1) { +#ifdef __hpux + /* + * IPv6 interface scanning is not available on all + * kernels w/ IPv6 sockets. + */ + if (errno == ENOENT) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_INTERFACE, + ISC_LOG_DEBUG(1), + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_IFITERIOCTL, + ISC_MSG_GETIFCONFIG, + "get interface " + "configuration: %s"), + strbuf); + result = ISC_R_FAILURE; + goto cleanup; + } +#endif + if (errno != EINVAL) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_IFITERIOCTL, + ISC_MSG_GETIFCONFIG, + "get interface " + "configuration: %s"), + strbuf); + result = ISC_R_UNEXPECTED; + goto cleanup; + } + /* + * EINVAL. Retry with a bigger buffer. + */ + } else { + /* + * The ioctl succeeded. + * Some OS's just return what will fit rather + * than set EINVAL if the buffer is too small + * to fit all the interfaces in. If + * ifc.ifc_len is too near to the end of the + * buffer we will grow it just in case and + * retry. + */ + if (iter->lifc.lifc_len + 2 * sizeof(struct LIFREQ) + < iter->bufsize6) + break; + } + if (iter->bufsize6 >= IFCONF_BUFSIZE_MAX) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_IFITERIOCTL, + ISC_MSG_BUFFERMAX, + "get interface " + "configuration: " + "maximum buffer " + "size exceeded")); + result = ISC_R_UNEXPECTED; + goto cleanup; + } + isc_mem_put(iter->mctx, iter->buf6, iter->bufsize6); + + iter->bufsize6 *= 2; + } + + if (iter->lifc.lifc_len != 0) + iter->mode = 6; + return (ISC_R_SUCCESS); + + cleanup: + isc_mem_put(iter->mctx, iter->buf6, iter->bufsize6); + iter->buf6 = NULL; + return (result); +} +#endif + +isc_result_t +isc_interfaceiter_create(isc_mem_t *mctx, isc_interfaceiter_t **iterp) { + isc_interfaceiter_t *iter; + isc_result_t result; + char strbuf[ISC_STRERRORSIZE]; + + REQUIRE(mctx != NULL); + REQUIRE(iterp != NULL); + REQUIRE(*iterp == NULL); + + iter = isc_mem_get(mctx, sizeof(*iter)); + if (iter == NULL) + return (ISC_R_NOMEMORY); + + iter->mctx = mctx; + iter->mode = 4; + iter->buf = NULL; + iter->pos = (unsigned int) -1; +#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) + iter->buf6 = NULL; + iter->pos6 = (unsigned int) -1; + iter->result6 = ISC_R_NOMORE; + iter->socket6 = -1; + iter->first6 = ISC_FALSE; +#endif + + /* + * Get the interface configuration, allocating more memory if + * necessary. + */ + +#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) + result = isc_net_probeipv6(); + if (result == ISC_R_SUCCESS) { + /* + * Create an unbound datagram socket to do the SIOCGLIFCONF + * ioctl on. HP/UX requires an AF_INET6 socket for + * SIOCGLIFCONF to get IPv6 addresses. + */ + if ((iter->socket6 = socket(AF_INET6, SOCK_DGRAM, 0)) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_IFITERIOCTL, + ISC_MSG_MAKESCANSOCKET, + "making interface " + "scan socket: %s"), + strbuf); + result = ISC_R_UNEXPECTED; + goto socket6_failure; + } + result = iter->result6 = getbuf6(iter); + if (result != ISC_R_NOTIMPLEMENTED && result != ISC_R_SUCCESS) + goto ioctl6_failure; + } +#endif + if ((iter->socket = socket(AF_INET, SOCK_DGRAM, 0)) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_IFITERIOCTL, + ISC_MSG_MAKESCANSOCKET, + "making interface " + "scan socket: %s"), + strbuf); + result = ISC_R_UNEXPECTED; + goto socket_failure; + } + result = getbuf4(iter); + if (result != ISC_R_SUCCESS) + goto ioctl_failure; + + /* + * A newly created iterator has an undefined position + * until isc_interfaceiter_first() is called. + */ +#ifdef HAVE_TRUCLUSTER + iter->clua_context = -1; + iter->clua_done = ISC_TRUE; +#endif +#ifdef __linux + iter->proc = fopen("/proc/net/if_inet6", "r"); + iter->valid = ISC_R_FAILURE; +#endif + iter->result = ISC_R_FAILURE; + + iter->magic = IFITER_MAGIC; + *iterp = iter; + return (ISC_R_SUCCESS); + + ioctl_failure: + if (iter->buf != NULL) + isc_mem_put(mctx, iter->buf, iter->bufsize); + (void) close(iter->socket); + + socket_failure: +#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) + if (iter->buf6 != NULL) + isc_mem_put(mctx, iter->buf6, iter->bufsize6); + ioctl6_failure: + if (iter->socket6 != -1) + (void) close(iter->socket6); + socket6_failure: +#endif + + isc_mem_put(mctx, iter, sizeof(*iter)); + return (result); +} + +#ifdef HAVE_TRUCLUSTER +static void +get_inaddr(isc_netaddr_t *dst, struct in_addr *src) { + dst->family = AF_INET; + memcpy(&dst->type.in, src, sizeof(struct in_addr)); +} + +static isc_result_t +internal_current_clusteralias(isc_interfaceiter_t *iter) { + struct clua_info ci; + if (clua_getaliasinfo(&iter->clua_sa, &ci) != CLUA_SUCCESS) + return (ISC_R_IGNORE); + memset(&iter->current, 0, sizeof(iter->current)); + iter->current.af = iter->clua_sa.sa_family; + memset(iter->current.name, 0, sizeof(iter->current.name)); + sprintf(iter->current.name, "clua%d", ci.aliasid); + iter->current.flags = INTERFACE_F_UP; + get_inaddr(&iter->current.address, &ci.addr); + get_inaddr(&iter->current.netmask, &ci.netmask); + return (ISC_R_SUCCESS); +} +#endif + +/* + * Get information about the current interface to iter->current. + * If successful, return ISC_R_SUCCESS. + * If the interface has an unsupported address family, or if + * some operation on it fails, return ISC_R_IGNORE to make + * the higher-level iterator code ignore it. + */ + +static isc_result_t +internal_current4(isc_interfaceiter_t *iter) { + struct ifreq *ifrp; + struct ifreq ifreq; + int family; + char strbuf[ISC_STRERRORSIZE]; +#if !defined(ISC_PLATFORM_HAVEIF_LADDRREQ) && defined(SIOCGLIFADDR) + struct lifreq lifreq; +#else + char sabuf[256]; +#endif + int i, bits, prefixlen; + + REQUIRE(VALID_IFITER(iter)); + + if (iter->ifc.ifc_len == 0 || + iter->pos == (unsigned int)iter->ifc.ifc_len) { +#ifdef __linux + return (linux_if_inet6_current(iter)); +#else + return (ISC_R_NOMORE); +#endif + } + + INSIST( iter->pos < (unsigned int) iter->ifc.ifc_len); + + ifrp = (struct ifreq *)((char *) iter->ifc.ifc_req + iter->pos); + + memset(&ifreq, 0, sizeof(ifreq)); + memcpy(&ifreq, ifrp, sizeof(ifreq)); + + family = ifreq.ifr_addr.sa_family; +#if defined(ISC_PLATFORM_HAVEIPV6) + if (family != AF_INET && family != AF_INET6) +#else + if (family != AF_INET) +#endif + return (ISC_R_IGNORE); + + memset(&iter->current, 0, sizeof(iter->current)); + iter->current.af = family; + + INSIST(sizeof(ifreq.ifr_name) <= sizeof(iter->current.name)); + memset(iter->current.name, 0, sizeof(iter->current.name)); + memcpy(iter->current.name, ifreq.ifr_name, sizeof(ifreq.ifr_name)); + + get_addr(family, &iter->current.address, + (struct sockaddr *)&ifrp->ifr_addr, ifreq.ifr_name); + + /* + * If the interface does not have a address ignore it. + */ + switch (family) { + case AF_INET: + if (iter->current.address.type.in.s_addr == htonl(INADDR_ANY)) + return (ISC_R_IGNORE); + break; + case AF_INET6: + if (memcmp(&iter->current.address.type.in6, &in6addr_any, + sizeof(in6addr_any)) == 0) + return (ISC_R_IGNORE); + break; + } + + /* + * Get interface flags. + */ + + iter->current.flags = 0; + + /* + * Ignore the HP/UX warning about "integer overflow during + * conversion. It comes from its own macro definition, + * and is really hard to shut up. + */ + if (ioctl(iter->socket, SIOCGIFFLAGS, (char *) &ifreq) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "%s: getting interface flags: %s", + ifreq.ifr_name, strbuf); + return (ISC_R_IGNORE); + } + + if ((ifreq.ifr_flags & IFF_UP) != 0) + iter->current.flags |= INTERFACE_F_UP; + +#ifdef IFF_POINTOPOINT + if ((ifreq.ifr_flags & IFF_POINTOPOINT) != 0) + iter->current.flags |= INTERFACE_F_POINTTOPOINT; +#endif + + if ((ifreq.ifr_flags & IFF_LOOPBACK) != 0) + iter->current.flags |= INTERFACE_F_LOOPBACK; + + if ((ifreq.ifr_flags & IFF_BROADCAST) != 0) + iter->current.flags |= INTERFACE_F_BROADCAST; + +#ifdef IFF_MULTICAST + if ((ifreq.ifr_flags & IFF_MULTICAST) != 0) + iter->current.flags |= INTERFACE_F_MULTICAST; +#endif + + if (family == AF_INET) + goto inet; + +#if !defined(ISC_PLATFORM_HAVEIF_LADDRREQ) && defined(SIOCGLIFADDR) + memset(&lifreq, 0, sizeof(lifreq)); + memcpy(lifreq.lifr_name, iter->current.name, sizeof(lifreq.lifr_name)); + memcpy(&lifreq.lifr_addr, &iter->current.address.type.in6, + sizeof(iter->current.address.type.in6)); + + if (ioctl(iter->socket, SIOCGLIFADDR, &lifreq) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "%s: getting interface address: %s", + ifreq.ifr_name, strbuf); + return (ISC_R_IGNORE); + } + prefixlen = lifreq.lifr_addrlen; +#else + isc_netaddr_format(&iter->current.address, sabuf, sizeof(sabuf)); + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_INTERFACE, + ISC_LOG_INFO, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_IFITERIOCTL, + ISC_MSG_GETIFCONFIG, + "prefix length for %s is unknown " + "(assume 128)"), sabuf); + prefixlen = 128; +#endif + + /* + * Netmask already zeroed. + */ + iter->current.netmask.family = family; + for (i = 0; i < 16; i++) { + if (prefixlen > 8) { + bits = 0; + prefixlen -= 8; + } else { + bits = 8 - prefixlen; + prefixlen = 0; + } + iter->current.netmask.type.in6.s6_addr[i] = (~0 << bits) & 0xff; + } + return (ISC_R_SUCCESS); + + inet: + if (family != AF_INET) + return (ISC_R_IGNORE); +#ifdef IFF_POINTOPOINT + /* + * If the interface is point-to-point, get the destination address. + */ + if ((iter->current.flags & INTERFACE_F_POINTTOPOINT) != 0) { + /* + * Ignore the HP/UX warning about "integer overflow during + * conversion. It comes from its own macro definition, + * and is really hard to shut up. + */ + if (ioctl(iter->socket, SIOCGIFDSTADDR, (char *)&ifreq) + < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_IFITERIOCTL, + ISC_MSG_GETDESTADDR, + "%s: getting " + "destination address: %s"), + ifreq.ifr_name, strbuf); + return (ISC_R_IGNORE); + } + get_addr(family, &iter->current.dstaddress, + (struct sockaddr *)&ifreq.ifr_dstaddr, ifreq.ifr_name); + } +#endif + + if ((iter->current.flags & INTERFACE_F_BROADCAST) != 0) { + /* + * Ignore the HP/UX warning about "integer overflow during + * conversion. It comes from its own macro definition, + * and is really hard to shut up. + */ + if (ioctl(iter->socket, SIOCGIFBRDADDR, (char *)&ifreq) + < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_IFITERIOCTL, + ISC_MSG_GETBCSTADDR, + "%s: getting " + "broadcast address: %s"), + ifreq.ifr_name, strbuf); + return (ISC_R_IGNORE); + } + get_addr(family, &iter->current.broadcast, + (struct sockaddr *)&ifreq.ifr_broadaddr, ifreq.ifr_name); + } + + /* + * Get the network mask. + */ + memset(&ifreq, 0, sizeof(ifreq)); + memcpy(&ifreq, ifrp, sizeof(ifreq)); + /* + * Ignore the HP/UX warning about "integer overflow during + * conversion. It comes from its own macro definition, + * and is really hard to shut up. + */ + if (ioctl(iter->socket, SIOCGIFNETMASK, (char *)&ifreq) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_IFITERIOCTL, + ISC_MSG_GETNETMASK, + "%s: getting netmask: %s"), + ifreq.ifr_name, strbuf); + return (ISC_R_IGNORE); + } + get_addr(family, &iter->current.netmask, + (struct sockaddr *)&ifreq.ifr_addr, ifreq.ifr_name); + return (ISC_R_SUCCESS); +} + +#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) +static isc_result_t +internal_current6(isc_interfaceiter_t *iter) { + struct LIFREQ *ifrp; + struct LIFREQ lifreq; + int family; + char strbuf[ISC_STRERRORSIZE]; + int fd; + + REQUIRE(VALID_IFITER(iter)); + if (iter->result6 != ISC_R_SUCCESS) + return (iter->result6); + REQUIRE(iter->pos6 < (unsigned int) iter->lifc.lifc_len); + + ifrp = (struct LIFREQ *)((char *) iter->lifc.lifc_req + iter->pos6); + + memset(&lifreq, 0, sizeof(lifreq)); + memcpy(&lifreq, ifrp, sizeof(lifreq)); + + family = lifreq.lifr_addr.ss_family; +#ifdef ISC_PLATFORM_HAVEIPV6 + if (family != AF_INET && family != AF_INET6) +#else + if (family != AF_INET) +#endif + return (ISC_R_IGNORE); + + memset(&iter->current, 0, sizeof(iter->current)); + iter->current.af = family; + + INSIST(sizeof(lifreq.lifr_name) <= sizeof(iter->current.name)); + memset(iter->current.name, 0, sizeof(iter->current.name)); + memcpy(iter->current.name, lifreq.lifr_name, sizeof(lifreq.lifr_name)); + + get_addr(family, &iter->current.address, + (struct sockaddr *)&lifreq.lifr_addr, lifreq.lifr_name); + + /* + * NTP local change + * enable_multicast_if() requires scopeid for setsockopt, + * so associate address with their corresponding ifindex. + */ + if (family == AF_INET6) + isc_netaddr_setzone(&iter->current.address, + (isc_uint32_t)lifreq.lifr_index); + + /* + * If the interface does not have a address ignore it. + */ + switch (family) { + case AF_INET: + if (iter->current.address.type.in.s_addr == htonl(INADDR_ANY)) + return (ISC_R_IGNORE); + break; + case AF_INET6: + if (memcmp(&iter->current.address.type.in6, &in6addr_any, + sizeof(in6addr_any)) == 0) + return (ISC_R_IGNORE); + break; + } + + /* + * Get interface flags. + */ + + iter->current.flags = 0; + + if (family == AF_INET6) + fd = iter->socket6; + else + fd = iter->socket; + + /* + * Ignore the HP/UX warning about "integer overflow during + * conversion. It comes from its own macro definition, + * and is really hard to shut up. + */ + if (ioctl(fd, SIOCGLIFFLAGS, (char *) &lifreq) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "%s: getting interface flags: %s", + lifreq.lifr_name, strbuf); + return (ISC_R_IGNORE); + } + + if ((lifreq.lifr_flags & IFF_UP) != 0) + iter->current.flags |= INTERFACE_F_UP; + +#ifdef IFF_POINTOPOINT + if ((lifreq.lifr_flags & IFF_POINTOPOINT) != 0) + iter->current.flags |= INTERFACE_F_POINTTOPOINT; +#endif + + if ((lifreq.lifr_flags & IFF_LOOPBACK) != 0) + iter->current.flags |= INTERFACE_F_LOOPBACK; + + if ((lifreq.lifr_flags & IFF_BROADCAST) != 0) { + iter->current.flags |= INTERFACE_F_BROADCAST; + } + +#ifdef IFF_MULTICAST + if ((lifreq.lifr_flags & IFF_MULTICAST) != 0) { + iter->current.flags |= INTERFACE_F_MULTICAST; + } +#endif + +#ifdef IFF_POINTOPOINT + /* + * If the interface is point-to-point, get the destination address. + */ + if ((iter->current.flags & INTERFACE_F_POINTTOPOINT) != 0) { + /* + * Ignore the HP/UX warning about "integer overflow during + * conversion. It comes from its own macro definition, + * and is really hard to shut up. + */ + if (ioctl(fd, SIOCGLIFDSTADDR, (char *)&lifreq) + < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_IFITERIOCTL, + ISC_MSG_GETDESTADDR, + "%s: getting " + "destination address: %s"), + lifreq.lifr_name, strbuf); + return (ISC_R_IGNORE); + } + get_addr(family, &iter->current.dstaddress, + (struct sockaddr *)&lifreq.lifr_dstaddr, + lifreq.lifr_name); + } +#endif + +#ifdef SIOCGLIFBRDADDR + if ((iter->current.flags & INTERFACE_F_BROADCAST) != 0) { + /* + * Ignore the HP/UX warning about "integer overflow during + * conversion. It comes from its own macro definition, + * and is really hard to shut up. + */ + if (ioctl(iter->socket, SIOCGLIFBRDADDR, (char *)&lifreq) + < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_IFITERIOCTL, + ISC_MSG_GETBCSTADDR, + "%s: getting " + "broadcast address: %s"), + lifreq.lifr_name, strbuf); + return (ISC_R_IGNORE); + } + get_addr(family, &iter->current.broadcast, + (struct sockaddr *)&lifreq.lifr_broadaddr, + lifreq.lifr_name); + } +#endif /* SIOCGLIFBRDADDR */ + + /* + * Get the network mask. Netmask already zeroed. + */ + memset(&lifreq, 0, sizeof(lifreq)); + memcpy(&lifreq, ifrp, sizeof(lifreq)); + +#ifdef lifr_addrlen + /* + * Special case: if the system provides lifr_addrlen member, the + * netmask of an IPv6 address can be derived from the length, since + * an IPv6 address always has a contiguous mask. + */ + if (family == AF_INET6) { + int i, bits; + + iter->current.netmask.family = family; + for (i = 0; i < lifreq.lifr_addrlen; i += 8) { + bits = lifreq.lifr_addrlen - i; + bits = (bits < 8) ? (8 - bits) : 0; + iter->current.netmask.type.in6.s6_addr[i / 8] = + (~0 << bits) & 0xff; + } + + return (ISC_R_SUCCESS); + } +#endif + + /* + * Ignore the HP/UX warning about "integer overflow during + * conversion. It comes from its own macro definition, + * and is really hard to shut up. + */ + if (ioctl(fd, SIOCGLIFNETMASK, (char *)&lifreq) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_IFITERIOCTL, + ISC_MSG_GETNETMASK, + "%s: getting netmask: %s"), + lifreq.lifr_name, strbuf); + return (ISC_R_IGNORE); + } + get_addr(family, &iter->current.netmask, + (struct sockaddr *)&lifreq.lifr_addr, lifreq.lifr_name); + + return (ISC_R_SUCCESS); +} +#endif + +static isc_result_t +internal_current(isc_interfaceiter_t *iter) { +#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) + if (iter->mode == 6) { + iter->result6 = internal_current6(iter); + if (iter->result6 != ISC_R_NOMORE) + return (iter->result6); + } +#endif +#ifdef HAVE_TRUCLUSTER + if (!iter->clua_done) + return(internal_current_clusteralias(iter)); +#endif + return (internal_current4(iter)); +} + +/* + * Step the iterator to the next interface. Unlike + * isc_interfaceiter_next(), this may leave the iterator + * positioned on an interface that will ultimately + * be ignored. Return ISC_R_NOMORE if there are no more + * interfaces, otherwise ISC_R_SUCCESS. + */ +static isc_result_t +internal_next4(isc_interfaceiter_t *iter) { +#ifdef ISC_PLATFORM_HAVESALEN + struct ifreq *ifrp; +#endif + + if (iter->pos < (unsigned int) iter->ifc.ifc_len) { +#ifdef ISC_PLATFORM_HAVESALEN + ifrp = (struct ifreq *)((char *) iter->ifc.ifc_req + iter->pos); + + if (ifrp->ifr_addr.sa_len > sizeof(struct sockaddr)) + iter->pos += sizeof(ifrp->ifr_name) + + ifrp->ifr_addr.sa_len; + else +#endif + iter->pos += sizeof(struct ifreq); + + } else { + INSIST(iter->pos == (unsigned int) iter->ifc.ifc_len); +#ifdef __linux + return (linux_if_inet6_next(iter)); +#else + return (ISC_R_NOMORE); +#endif + } + return (ISC_R_SUCCESS); +} + +#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) +static isc_result_t +internal_next6(isc_interfaceiter_t *iter) { +#ifdef ISC_PLATFORM_HAVESALEN + struct LIFREQ *ifrp; +#endif + + if (iter->result6 != ISC_R_SUCCESS && iter->result6 != ISC_R_IGNORE) + return (iter->result6); + + REQUIRE(iter->pos6 < (unsigned int) iter->lifc.lifc_len); + +#ifdef ISC_PLATFORM_HAVESALEN + ifrp = (struct LIFREQ *)((char *) iter->lifc.lifc_req + iter->pos6); + + if (ifrp->lifr_addr.sa_len > sizeof(struct sockaddr)) + iter->pos6 += sizeof(ifrp->lifr_name) + ifrp->lifr_addr.sa_len; + else +#endif + iter->pos6 += sizeof(struct LIFREQ); + + if (iter->pos6 >= (unsigned int) iter->lifc.lifc_len) + return (ISC_R_NOMORE); + + return (ISC_R_SUCCESS); +} +#endif + +static isc_result_t +internal_next(isc_interfaceiter_t *iter) { +#ifdef HAVE_TRUCLUSTER + int clua_result; +#endif +#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) + if (iter->mode == 6) { + iter->result6 = internal_next6(iter); + if (iter->result6 != ISC_R_NOMORE) + return (iter->result6); + if (iter->first6) { + iter->first6 = ISC_FALSE; + return (ISC_R_SUCCESS); + } + } +#endif +#ifdef HAVE_TRUCLUSTER + if (!iter->clua_done) { + clua_result = clua_getaliasaddress(&iter->clua_sa, + &iter->clua_context); + if (clua_result != CLUA_SUCCESS) + iter->clua_done = ISC_TRUE; + return (ISC_R_SUCCESS); + } +#endif + return (internal_next4(iter)); +} + +static void +internal_destroy(isc_interfaceiter_t *iter) { + (void) close(iter->socket); +#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) + if (iter->socket6 != -1) + (void) close(iter->socket6); + if (iter->buf6 != NULL) { + isc_mem_put(iter->mctx, iter->buf6, iter->bufsize6); + } +#endif +#ifdef __linux + if (iter->proc != NULL) + fclose(iter->proc); +#endif +} + +static +void internal_first(isc_interfaceiter_t *iter) { +#ifdef HAVE_TRUCLUSTER + int clua_result; +#endif + iter->pos = 0; +#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) + iter->pos6 = 0; + if (iter->result6 == ISC_R_NOMORE) + iter->result6 = ISC_R_SUCCESS; + iter->first6 = ISC_TRUE; +#endif +#ifdef HAVE_TRUCLUSTER + iter->clua_context = 0; + clua_result = clua_getaliasaddress(&iter->clua_sa, + &iter->clua_context); + iter->clua_done = ISC_TF(clua_result != CLUA_SUCCESS); +#endif +#ifdef __linux + linux_if_inet6_first(iter); +#endif +} diff -urN src/contrib/ntp/lib/isc/unix/ifiter_sysctl.c src.ntp/contrib/ntp/lib/isc/unix/ifiter_sysctl.c --- src/contrib/ntp/lib/isc/unix/ifiter_sysctl.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/ifiter_sysctl.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,315 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: ifiter_sysctl.c,v 1.25 2007/06/19 23:47:18 tbox Exp $ */ + +/*! \file + * \brief + * Obtain the list of network interfaces using sysctl. + * See TCP/IP Illustrated Volume 2, sections 19.8, 19.14, + * and 19.16. + */ + +#include +#include + +#include +#include + +/* XXX what about Alpha? */ +#ifdef sgi +#define ROUNDUP(a) ((a) > 0 ? \ + (1 + (((a) - 1) | (sizeof(__uint64_t) - 1))) : \ + sizeof(__uint64_t)) +#else +#define ROUNDUP(a) ((a) > 0 ? (1 + (((a) - 1) | (sizeof(long) - 1))) \ + : sizeof(long)) +#endif + +#define IFITER_MAGIC ISC_MAGIC('I', 'F', 'I', 'S') +#define VALID_IFITER(t) ISC_MAGIC_VALID(t, IFITER_MAGIC) + +struct isc_interfaceiter { + unsigned int magic; /* Magic number. */ + isc_mem_t *mctx; + void *buf; /* Buffer for sysctl data. */ + unsigned int bufsize; /* Bytes allocated. */ + unsigned int bufused; /* Bytes used. */ + unsigned int pos; /* Current offset in + sysctl data. */ + isc_interface_t current; /* Current interface data. */ + isc_result_t result; /* Last result code. */ +}; + +static int mib[6] = { + CTL_NET, + PF_ROUTE, + 0, + 0, /* Any address family. */ + NET_RT_IFLIST, + 0 /* Flags. */ +}; + +isc_result_t +isc_interfaceiter_create(isc_mem_t *mctx, isc_interfaceiter_t **iterp) { + isc_interfaceiter_t *iter; + isc_result_t result; + size_t bufsize; + size_t bufused; + char strbuf[ISC_STRERRORSIZE]; + + REQUIRE(mctx != NULL); + REQUIRE(iterp != NULL); + REQUIRE(*iterp == NULL); + + iter = isc_mem_get(mctx, sizeof(*iter)); + if (iter == NULL) + return (ISC_R_NOMEMORY); + + iter->mctx = mctx; + iter->buf = 0; + + /* + * Determine the amount of memory needed. + */ + bufsize = 0; + if (sysctl(mib, 6, NULL, &bufsize, NULL, (size_t) 0) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_IFITERSYSCTL, + ISC_MSG_GETIFLISTSIZE, + "getting interface " + "list size: sysctl: %s"), + strbuf); + result = ISC_R_UNEXPECTED; + goto failure; + } + iter->bufsize = bufsize; + + iter->buf = isc_mem_get(iter->mctx, iter->bufsize); + if (iter->buf == NULL) { + result = ISC_R_NOMEMORY; + goto failure; + } + + bufused = bufsize; + if (sysctl(mib, 6, iter->buf, &bufused, NULL, (size_t) 0) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_IFITERSYSCTL, + ISC_MSG_GETIFLIST, + "getting interface list: " + "sysctl: %s"), + strbuf); + result = ISC_R_UNEXPECTED; + goto failure; + } + iter->bufused = bufused; + INSIST(iter->bufused <= iter->bufsize); + + /* + * A newly created iterator has an undefined position + * until isc_interfaceiter_first() is called. + */ + iter->pos = (unsigned int) -1; + iter->result = ISC_R_FAILURE; + + iter->magic = IFITER_MAGIC; + *iterp = iter; + return (ISC_R_SUCCESS); + + failure: + if (iter->buf != NULL) + isc_mem_put(mctx, iter->buf, iter->bufsize); + isc_mem_put(mctx, iter, sizeof(*iter)); + return (result); +} + +/* + * Get information about the current interface to iter->current. + * If successful, return ISC_R_SUCCESS. + * If the interface has an unsupported address family, + * return ISC_R_IGNORE. In case of other failure, + * return ISC_R_UNEXPECTED. + */ + +static isc_result_t +internal_current(isc_interfaceiter_t *iter) { + struct ifa_msghdr *ifam, *ifam_end; + + REQUIRE(VALID_IFITER(iter)); + REQUIRE (iter->pos < (unsigned int) iter->bufused); + + ifam = (struct ifa_msghdr *) ((char *) iter->buf + iter->pos); + ifam_end = (struct ifa_msghdr *) ((char *) iter->buf + iter->bufused); + + if (ifam->ifam_type == RTM_IFINFO) { + struct if_msghdr *ifm = (struct if_msghdr *) ifam; + struct sockaddr_dl *sdl = (struct sockaddr_dl *) (ifm + 1); + unsigned int namelen; + + memset(&iter->current, 0, sizeof(iter->current)); + + namelen = sdl->sdl_nlen; + if (namelen > sizeof(iter->current.name) - 1) + namelen = sizeof(iter->current.name) - 1; + + memset(iter->current.name, 0, sizeof(iter->current.name)); + memcpy(iter->current.name, sdl->sdl_data, namelen); + + iter->current.flags = 0; + + if ((ifam->ifam_flags & IFF_UP) != 0) + iter->current.flags |= INTERFACE_F_UP; + + if ((ifam->ifam_flags & IFF_POINTOPOINT) != 0) + iter->current.flags |= INTERFACE_F_POINTTOPOINT; + + if ((ifam->ifam_flags & IFF_LOOPBACK) != 0) + iter->current.flags |= INTERFACE_F_LOOPBACK; + + if ((ifam->ifam_flags & IFF_BROADCAST) != 0) + iter->current.flags |= INTERFACE_F_BROADCAST; + +#ifdef IFF_MULTICAST + if ((ifam->ifam_flags & IFF_MULTICAST) != 0) + iter->current.flags |= INTERFACE_F_MULTICAST; +#endif + + /* + * This is not an interface address. + * Force another iteration. + */ + return (ISC_R_IGNORE); + } else if (ifam->ifam_type == RTM_NEWADDR) { + int i; + int family; + struct sockaddr *mask_sa = NULL; + struct sockaddr *addr_sa = NULL; + struct sockaddr *dst_sa = NULL; + + struct sockaddr *sa = (struct sockaddr *)(ifam + 1); + family = sa->sa_family; + + for (i = 0; i < RTAX_MAX; i++) + { + if ((ifam->ifam_addrs & (1 << i)) == 0) + continue; + + INSIST(sa < (struct sockaddr *) ifam_end); + + switch (i) { + case RTAX_NETMASK: /* Netmask */ + mask_sa = sa; + break; + case RTAX_IFA: /* Interface address */ + addr_sa = sa; + break; + case RTAX_BRD: /* Broadcast or destination address */ + dst_sa = sa; + break; + } +#ifdef ISC_PLATFORM_HAVESALEN + sa = (struct sockaddr *)((char*)(sa) + + ROUNDUP(sa->sa_len)); +#else +#ifdef sgi + /* + * Do as the contributed SGI code does. + */ + sa = (struct sockaddr *)((char*)(sa) + + ROUNDUP(_FAKE_SA_LEN_DST(sa))); +#else + /* XXX untested. */ + sa = (struct sockaddr *)((char*)(sa) + + ROUNDUP(sizeof(struct sockaddr))); +#endif +#endif + } + + if (addr_sa == NULL) + return (ISC_R_IGNORE); + + family = addr_sa->sa_family; + if (family != AF_INET && family != AF_INET6) + return (ISC_R_IGNORE); + + iter->current.af = family; + + get_addr(family, &iter->current.address, addr_sa, + iter->current.name); + + if (mask_sa != NULL) + get_addr(family, &iter->current.netmask, mask_sa, + iter->current.name); + + if (dst_sa != NULL && + (iter->current.flags & INTERFACE_F_POINTTOPOINT) != 0) + get_addr(family, &iter->current.dstaddress, dst_sa, + iter->current.name); + + if (dst_sa != NULL && + (iter->current.flags & INTERFACE_F_BROADCAST) != 0) + get_addr(family, &iter->current.broadcast, dst_sa, + iter->current.name); + + return (ISC_R_SUCCESS); + } else { + printf(isc_msgcat_get(isc_msgcat, ISC_MSGSET_IFITERSYSCTL, + ISC_MSG_UNEXPECTEDTYPE, + "warning: unexpected interface list " + "message type\n")); + return (ISC_R_IGNORE); + } +} + +/* + * Step the iterator to the next interface. Unlike + * isc_interfaceiter_next(), this may leave the iterator + * positioned on an interface that will ultimately + * be ignored. Return ISC_R_NOMORE if there are no more + * interfaces, otherwise ISC_R_SUCCESS. + */ +static isc_result_t +internal_next(isc_interfaceiter_t *iter) { + struct ifa_msghdr *ifam; + REQUIRE (iter->pos < (unsigned int) iter->bufused); + + ifam = (struct ifa_msghdr *) ((char *) iter->buf + iter->pos); + + iter->pos += ifam->ifam_msglen; + + if (iter->pos >= iter->bufused) + return (ISC_R_NOMORE); + + return (ISC_R_SUCCESS); +} + +static void +internal_destroy(isc_interfaceiter_t *iter) { + UNUSED(iter); /* Unused. */ + /* + * Do nothing. + */ +} + +static +void internal_first(isc_interfaceiter_t *iter) { + iter->pos = 0; +} diff -urN src/contrib/ntp/lib/isc/unix/include/isc/dir.h src.ntp/contrib/ntp/lib/isc/unix/include/isc/dir.h --- src/contrib/ntp/lib/isc/unix/include/isc/dir.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/include/isc/dir.h 2009-12-09 08:36:44.000000000 +0100 @@ -0,0 +1,94 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: dir.h,v 1.21 2007/06/19 23:47:19 tbox Exp $ */ + +/* Principal Authors: DCL */ + +#ifndef ISC_DIR_H +#define ISC_DIR_H 1 + +/*! \file */ + +#include /* Required on some systems. */ +#include + +#include +#include + +#define ISC_DIR_NAMEMAX 256 +#define ISC_DIR_PATHMAX 1024 + +/*% Directory Entry */ +typedef struct isc_direntry { + /*! + * Ideally, this should be NAME_MAX, but AIX does not define it by + * default and dynamically allocating the space based on pathconf() + * complicates things undesirably, as does adding special conditionals + * just for AIX. So a comfortably sized buffer is chosen instead. + */ + char name[ISC_DIR_NAMEMAX]; + unsigned int length; +} isc_direntry_t; + +/*% Directory */ +typedef struct isc_dir { + unsigned int magic; + /*! + * As with isc_direntry_t->name, making this "right" for all systems + * is slightly problematic because AIX does not define PATH_MAX. + */ + char dirname[ISC_DIR_PATHMAX]; + isc_direntry_t entry; + DIR * handle; +} isc_dir_t; + +ISC_LANG_BEGINDECLS + +void +isc_dir_init(isc_dir_t *dir); + +isc_result_t +isc_dir_open(isc_dir_t *dir, const char *dirname); + +isc_result_t +isc_dir_read(isc_dir_t *dir); + +isc_result_t +isc_dir_reset(isc_dir_t *dir); + +void +isc_dir_close(isc_dir_t *dir); + +isc_result_t +isc_dir_chdir(const char *dirname); + +isc_result_t +isc_dir_chroot(const char *dirname); + +isc_result_t +isc_dir_createunique(char *templet); +/*!< + * Use a templet (such as from isc_file_mktemplate()) to create a uniquely + * named, empty directory. The templet string is modified in place. + * If result == ISC_R_SUCCESS, it is the name of the directory that was + * created. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_DIR_H */ diff -urN src/contrib/ntp/lib/isc/unix/include/isc/int.h src.ntp/contrib/ntp/lib/isc/unix/include/isc/int.h --- src/contrib/ntp/lib/isc/unix/include/isc/int.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/include/isc/int.h 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,55 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: int.h,v 1.16 2007/06/19 23:47:19 tbox Exp $ */ + +#ifndef ISC_INT_H +#define ISC_INT_H 1 + +/*! \file */ + +typedef char isc_int8_t; +typedef unsigned char isc_uint8_t; +typedef short isc_int16_t; +typedef unsigned short isc_uint16_t; +typedef int isc_int32_t; +typedef unsigned int isc_uint32_t; +typedef long long isc_int64_t; +typedef unsigned long long isc_uint64_t; + +#define ISC_INT8_MIN -128 +#define ISC_INT8_MAX 127 +#define ISC_UINT8_MAX 255 + +#define ISC_INT16_MIN -32768 +#define ISC_INT16_MAX 32767 +#define ISC_UINT16_MAX 65535 + +/*% + * Note that "int" is 32 bits on all currently supported Unix-like operating + * systems, but "long" can be either 32 bits or 64 bits, thus the 32 bit + * constants are not qualified with "L". + */ +#define ISC_INT32_MIN -2147483648 +#define ISC_INT32_MAX 2147483647 +#define ISC_UINT32_MAX 4294967295U + +#define ISC_INT64_MIN -9223372036854775808LL +#define ISC_INT64_MAX 9223372036854775807LL +#define ISC_UINT64_MAX 18446744073709551615ULL + +#endif /* ISC_INT_H */ diff -urN src/contrib/ntp/lib/isc/unix/include/isc/keyboard.h src.ntp/contrib/ntp/lib/isc/unix/include/isc/keyboard.h --- src/contrib/ntp/lib/isc/unix/include/isc/keyboard.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/include/isc/keyboard.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,52 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: keyboard.h,v 1.11 2007/06/19 23:47:19 tbox Exp $ */ + +#ifndef ISC_KEYBOARD_H +#define ISC_KEYBOARD_H 1 + +/*! \file */ + +#include + +#include +#include + +ISC_LANG_BEGINDECLS + +typedef struct { + int fd; + struct termios saved_mode; + isc_result_t result; +} isc_keyboard_t; + +isc_result_t +isc_keyboard_open(isc_keyboard_t *keyboard); + +isc_result_t +isc_keyboard_close(isc_keyboard_t *keyboard, unsigned int sleepseconds); + +isc_result_t +isc_keyboard_getchar(isc_keyboard_t *keyboard, unsigned char *cp); + +isc_boolean_t +isc_keyboard_canceled(isc_keyboard_t *keyboard); + +ISC_LANG_ENDDECLS + +#endif /* ISC_KEYBOARD_H */ diff -urN src/contrib/ntp/lib/isc/unix/include/isc/net.h src.ntp/contrib/ntp/lib/isc/unix/include/isc/net.h --- src/contrib/ntp/lib/isc/unix/include/isc/net.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/include/isc/net.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,364 @@ +/* + * Copyright (C) 2004, 2005, 2007-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: net.h,v 1.48.84.2 2009/02/16 23:47:15 tbox Exp $ */ + +#ifndef ISC_NET_H +#define ISC_NET_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file + * \brief + * Basic Networking Types + * + * This module is responsible for defining the following basic networking + * types: + * + *\li struct in_addr + *\li struct in6_addr + *\li struct in6_pktinfo + *\li struct sockaddr + *\li struct sockaddr_in + *\li struct sockaddr_in6 + *\li in_port_t + * + * It ensures that the AF_ and PF_ macros are defined. + * + * It declares ntoh[sl]() and hton[sl](). + * + * It declares inet_aton(), inet_ntop(), and inet_pton(). + * + * It ensures that #INADDR_LOOPBACK, #INADDR_ANY, #IN6ADDR_ANY_INIT, + * in6addr_any, and in6addr_loopback are available. + * + * It ensures that IN_MULTICAST() is available to check for multicast + * addresses. + * + * MP: + *\li No impact. + * + * Reliability: + *\li No anticipated impact. + * + * Resources: + *\li N/A. + * + * Security: + *\li No anticipated impact. + * + * Standards: + *\li BSD Socket API + *\li RFC2553 + */ + +/*** + *** Imports. + ***/ +#include + +#include +#include /* Contractual promise. */ + +#include + +#include /* Contractual promise. */ +#include /* Contractual promise. */ +#ifdef ISC_PLATFORM_NEEDNETINETIN6H +#include /* Required on UnixWare. */ +#endif +#ifdef ISC_PLATFORM_NEEDNETINET6IN6H +#include /* Required on BSD/OS for in6_pktinfo. */ +#endif + +#ifndef ISC_PLATFORM_HAVEIPV6 +#include /* Contractual promise. */ +#endif + +#include +#include + +#ifdef ISC_PLATFORM_HAVEINADDR6 +#define in6_addr in_addr6 /*%< Required for pre RFC2133 implementations. */ +#endif + +#ifdef ISC_PLATFORM_HAVEIPV6 +#ifndef IN6ADDR_ANY_INIT +#ifdef s6_addr +/*% + * Required for some pre RFC2133 implementations. + * IN6ADDR_ANY_INIT and IN6ADDR_LOOPBACK_INIT were added in + * draft-ietf-ipngwg-bsd-api-04.txt or draft-ietf-ipngwg-bsd-api-05.txt. + * If 's6_addr' is defined then assume that there is a union and three + * levels otherwise assume two levels required. + */ +#define IN6ADDR_ANY_INIT { { { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 } } } +#else +#define IN6ADDR_ANY_INIT { { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 } } +#endif +#endif + +#ifndef IN6ADDR_LOOPBACK_INIT +#ifdef s6_addr +/*% IPv6 address loopback init */ +#define IN6ADDR_LOOPBACK_INIT { { { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 } } } +#else +#define IN6ADDR_LOOPBACK_INIT { { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 } } +#endif +#endif + +#ifndef IN6_IS_ADDR_V4MAPPED +/*% Is IPv6 address V4 mapped? */ +#define IN6_IS_ADDR_V4MAPPED(x) \ + (memcmp((x)->s6_addr, in6addr_any.s6_addr, 10) == 0 && \ + (x)->s6_addr[10] == 0xff && (x)->s6_addr[11] == 0xff) +#endif + +#ifndef IN6_IS_ADDR_V4COMPAT +/*% Is IPv6 address V4 compatible? */ +#define IN6_IS_ADDR_V4COMPAT(x) \ + (memcmp((x)->s6_addr, in6addr_any.s6_addr, 12) == 0 && \ + ((x)->s6_addr[12] != 0 || (x)->s6_addr[13] != 0 || \ + (x)->s6_addr[14] != 0 || \ + ((x)->s6_addr[15] != 0 && (x)->s6_addr[15] != 1))) +#endif + +#ifndef IN6_IS_ADDR_MULTICAST +/*% Is IPv6 address multicast? */ +#define IN6_IS_ADDR_MULTICAST(a) ((a)->s6_addr[0] == 0xff) +#endif + +#ifndef IN6_IS_ADDR_LINKLOCAL +/*% Is IPv6 address linklocal? */ +#define IN6_IS_ADDR_LINKLOCAL(a) \ + (((a)->s6_addr[0] == 0xfe) && (((a)->s6_addr[1] & 0xc0) == 0x80)) +#endif + +#ifndef IN6_IS_ADDR_SITELOCAL +/*% is IPv6 address sitelocal? */ +#define IN6_IS_ADDR_SITELOCAL(a) \ + (((a)->s6_addr[0] == 0xfe) && (((a)->s6_addr[1] & 0xc0) == 0xc0)) +#endif + + +#ifndef IN6_IS_ADDR_LOOPBACK +/*% is IPv6 address loopback? */ +#define IN6_IS_ADDR_LOOPBACK(x) \ + (memcmp((x)->s6_addr, in6addr_loopback.s6_addr, 16) == 0) +#endif +#endif + +#ifndef AF_INET6 +/*% IPv6 */ +#define AF_INET6 99 +#endif + +#ifndef PF_INET6 +/*% IPv6 */ +#define PF_INET6 AF_INET6 +#endif + +#ifndef INADDR_LOOPBACK +/*% inaddr loopback */ +#define INADDR_LOOPBACK 0x7f000001UL +#endif + +#ifndef ISC_PLATFORM_HAVEIN6PKTINFO +/*% IPv6 packet info */ +struct in6_pktinfo { + struct in6_addr ipi6_addr; /*%< src/dst IPv6 address */ + unsigned int ipi6_ifindex; /*%< send/recv interface index */ +}; +#endif + +#if defined(ISC_PLATFORM_NEEDIN6ADDRANY) +extern const struct in6_addr isc_net_in6addrany; +/*% + * Cope with a missing in6addr_any and in6addr_loopback. + */ +#define in6addr_any isc_net_in6addrany +#endif + +#if defined(ISC_PLATFORM_HAVEIPV6) && defined(ISC_PLATFORM_NEEDIN6ADDRLOOPBACK) +extern const struct in6_addr isc_net_in6addrloop; +#define in6addr_loopback isc_net_in6addrloop +#endif + +#ifdef ISC_PLATFORM_FIXIN6ISADDR +#undef IN6_IS_ADDR_GEOGRAPHIC +/*! + * \brief + * Fix UnixWare 7.1.1's broken IN6_IS_ADDR_* definitions. + */ +#define IN6_IS_ADDR_GEOGRAPHIC(a) (((a)->S6_un.S6_l[0] & 0xE0) == 0x80) +#undef IN6_IS_ADDR_IPX +#define IN6_IS_ADDR_IPX(a) (((a)->S6_un.S6_l[0] & 0xFE) == 0x04) +#undef IN6_IS_ADDR_LINKLOCAL +#define IN6_IS_ADDR_LINKLOCAL(a) (((a)->S6_un.S6_l[0] & 0xC0FF) == 0x80FE) +#undef IN6_IS_ADDR_MULTICAST +#define IN6_IS_ADDR_MULTICAST(a) (((a)->S6_un.S6_l[0] & 0xFF) == 0xFF) +#undef IN6_IS_ADDR_NSAP +#define IN6_IS_ADDR_NSAP(a) (((a)->S6_un.S6_l[0] & 0xFE) == 0x02) +#undef IN6_IS_ADDR_PROVIDER +#define IN6_IS_ADDR_PROVIDER(a) (((a)->S6_un.S6_l[0] & 0xE0) == 0x40) +#undef IN6_IS_ADDR_SITELOCAL +#define IN6_IS_ADDR_SITELOCAL(a) (((a)->S6_un.S6_l[0] & 0xC0FF) == 0xC0FE) +#endif /* ISC_PLATFORM_FIXIN6ISADDR */ + +#ifdef ISC_PLATFORM_NEEDPORTT +/*% + * Ensure type in_port_t is defined. + */ +typedef isc_uint16_t in_port_t; +#endif + +#ifndef MSG_TRUNC +/*% + * If this system does not have MSG_TRUNC (as returned from recvmsg()) + * ISC_PLATFORM_RECVOVERFLOW will be defined. This will enable the MSG_TRUNC + * faking code in socket.c. + */ +#define ISC_PLATFORM_RECVOVERFLOW +#endif + +/*% IP address. */ +#define ISC__IPADDR(x) ((isc_uint32_t)htonl((isc_uint32_t)(x))) + +/*% Is IP address multicast? */ +#define ISC_IPADDR_ISMULTICAST(i) \ + (((isc_uint32_t)(i) & ISC__IPADDR(0xf0000000)) \ + == ISC__IPADDR(0xe0000000)) + +#define ISC_IPADDR_ISEXPERIMENTAL(i) \ + (((isc_uint32_t)(i) & ISC__IPADDR(0xf0000000)) \ + == ISC__IPADDR(0xf0000000)) + +/*** + *** Functions. + ***/ + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_net_probeipv4(void); +/*%< + * Check if the system's kernel supports IPv4. + * + * Returns: + * + *\li #ISC_R_SUCCESS IPv4 is supported. + *\li #ISC_R_NOTFOUND IPv4 is not supported. + *\li #ISC_R_DISABLED IPv4 is disabled. + *\li #ISC_R_UNEXPECTED + */ + +isc_result_t +isc_net_probeipv6(void); +/*%< + * Check if the system's kernel supports IPv6. + * + * Returns: + * + *\li #ISC_R_SUCCESS IPv6 is supported. + *\li #ISC_R_NOTFOUND IPv6 is not supported. + *\li #ISC_R_DISABLED IPv6 is disabled. + *\li #ISC_R_UNEXPECTED + */ + +isc_result_t +isc_net_probe_ipv6only(void); +/*%< + * Check if the system's kernel supports the IPV6_V6ONLY socket option. + * + * Returns: + * + *\li #ISC_R_SUCCESS the option is supported for both TCP and UDP. + *\li #ISC_R_NOTFOUND IPv6 itself or the option is not supported. + *\li #ISC_R_UNEXPECTED + */ + +isc_result_t +isc_net_probe_ipv6pktinfo(void); +/* + * Check if the system's kernel supports the IPV6_(RECV)PKTINFO socket option + * for UDP sockets. + * + * Returns: + * + * \li #ISC_R_SUCCESS the option is supported. + * \li #ISC_R_NOTFOUND IPv6 itself or the option is not supported. + * \li #ISC_R_UNEXPECTED + */ + +void +isc_net_disableipv4(void); + +void +isc_net_disableipv6(void); + +void +isc_net_enableipv4(void); + +void +isc_net_enableipv6(void); + +isc_result_t +isc_net_probeunix(void); +/* + * Returns whether UNIX domain sockets are supported. + */ + +isc_result_t +isc_net_getudpportrange(int af, in_port_t *low, in_port_t *high); +/*%< + * Returns system's default range of ephemeral UDP ports, if defined. + * If the range is not available or unknown, ISC_NET_PORTRANGELOW and + * ISC_NET_PORTRANGEHIGH will be returned. + * + * Requires: + * + *\li 'low' and 'high' must be non NULL. + * + * Returns: + * + *\li *low and *high will be the ports specifying the low and high ends of + * the range. + */ + +#ifdef ISC_PLATFORM_NEEDNTOP +const char * +isc_net_ntop(int af, const void *src, char *dst, size_t size); +#define inet_ntop isc_net_ntop +#endif + +#ifdef ISC_PLATFORM_NEEDPTON +int +isc_net_pton(int af, const char *src, void *dst); +#undef inet_pton +#define inet_pton isc_net_pton +#endif + +int +isc_net_aton(const char *cp, struct in_addr *addr); +#undef inet_aton +#define inet_aton isc_net_aton + +ISC_LANG_ENDDECLS + +#endif /* ISC_NET_H */ diff -urN src/contrib/ntp/lib/isc/unix/include/isc/netdb.h src.ntp/contrib/ntp/lib/isc/unix/include/isc/netdb.h --- src/contrib/ntp/lib/isc/unix/include/isc/netdb.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/include/isc/netdb.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,57 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: netdb.h,v 1.11 2007/06/19 23:47:19 tbox Exp $ */ + +#ifndef ISC_NETDB_H +#define ISC_NETDB_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file + * \brief + * Portable netdb.h support. + * + * This module is responsible for defining the getby APIs. + * + * MP: + *\li No impact. + * + * Reliability: + *\li No anticipated impact. + * + * Resources: + *\li N/A. + * + * Security: + *\li No anticipated impact. + * + * Standards: + *\li BSD API + */ + +/*** + *** Imports. + ***/ + +#include + +#include + +#endif /* ISC_NETDB_H */ diff -urN src/contrib/ntp/lib/isc/unix/include/isc/offset.h src.ntp/contrib/ntp/lib/isc/unix/include/isc/offset.h --- src/contrib/ntp/lib/isc/unix/include/isc/offset.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/include/isc/offset.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,46 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: offset.h,v 1.15.332.2 2009/02/16 23:47:15 tbox Exp $ */ + +#ifndef ISC_OFFSET_H +#define ISC_OFFSET_H 1 + +/*! \file + * \brief + * File offsets are operating-system dependent. + */ +#include /* Required for CHAR_BIT. */ +#include +#include /* For Linux Standard Base. */ + +typedef off_t isc_offset_t; + +/*% + * POSIX says "Additionally, blkcnt_t and off_t are extended signed integral + * types", so the maximum value is all 1s except for the high bit. + * This definition is more complex than it really needs to be because it was + * crafted to keep both the SunOS 5.6 and the HP/UX 11 compilers quiet about + * integer overflow. For example, though this is equivalent to just left + * shifting 1 to the high bit and then inverting the bits, the SunOS compiler + * is unhappy about shifting a positive "1" to negative in a signed integer. + */ +#define ISC_OFFSET_MAXIMUM \ + (~(((off_t)-1 >> (sizeof(off_t) * CHAR_BIT - 1)) \ + << (sizeof(off_t) * CHAR_BIT - 1))) + +#endif /* ISC_OFFSET_H */ diff -urN src/contrib/ntp/lib/isc/unix/include/isc/stat.h src.ntp/contrib/ntp/lib/isc/unix/include/isc/stat.h --- src/contrib/ntp/lib/isc/unix/include/isc/stat.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/include/isc/stat.h 2009-12-09 08:36:44.000000000 +0100 @@ -0,0 +1,52 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: stat.h,v 1.5 2007/06/19 23:47:19 tbox Exp $ */ + +#ifndef ISC_STAT_H +#define ISC_STAT_H 1 + +/***** + ***** Module Info + *****/ + +/* + * Portable netdb.h support. + * + * This module is responsible for defining S_IS??? macros. + * + * MP: + * No impact. + * + * Reliability: + * No anticipated impact. + * + * Resources: + * N/A. + * + * Security: + * No anticipated impact. + * + */ + +/*** + *** Imports. + ***/ + +#include +#include + +#endif /* ISC_STAT_H */ diff -urN src/contrib/ntp/lib/isc/unix/include/isc/stdtime.h src.ntp/contrib/ntp/lib/isc/unix/include/isc/stdtime.h --- src/contrib/ntp/lib/isc/unix/include/isc/stdtime.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/include/isc/stdtime.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,60 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: stdtime.h,v 1.14 2007/06/19 23:47:19 tbox Exp $ */ + +#ifndef ISC_STDTIME_H +#define ISC_STDTIME_H 1 + +/*! \file */ + +#include +#include + +/*% + * It's public information that 'isc_stdtime_t' is an unsigned integral type. + * Applications that want maximum portability should not assume anything + * about its size. + */ +typedef isc_uint32_t isc_stdtime_t; +/* + * isc_stdtime32_t is a 32-bit version of isc_stdtime_t. A variable of this + * type should only be used as an opaque integer (e.g.,) to compare two + * time values. + */ +typedef isc_uint32_t isc_stdtime32_t; + +ISC_LANG_BEGINDECLS +/* */ +void +isc_stdtime_get(isc_stdtime_t *t); +/*%< + * Set 't' to the number of seconds since 00:00:00 UTC, January 1, 1970. + * + * Requires: + * + *\li 't' is a valid pointer. + */ + +#define isc_stdtime_convert32(t, t32p) (*(t32p) = t) +/* + * Convert the standard time to its 32-bit version. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_STDTIME_H */ diff -urN src/contrib/ntp/lib/isc/unix/include/isc/strerror.h src.ntp/contrib/ntp/lib/isc/unix/include/isc/strerror.h --- src/contrib/ntp/lib/isc/unix/include/isc/strerror.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/include/isc/strerror.h 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,45 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: strerror.h,v 1.8.332.2 2009/02/16 23:47:15 tbox Exp $ */ + +#ifndef ISC_STRERROR_H +#define ISC_STRERROR_H + +/*! \file */ + +#include + +#include + +ISC_LANG_BEGINDECLS + +/*% String Error Size */ +#define ISC_STRERRORSIZE 128 + +/*% + * Provide a thread safe wrapper to strerror(). + * + * Requires: + * 'buf' to be non NULL. + */ +void +isc__strerror(int num, char *buf, size_t bufsize); + +ISC_LANG_ENDDECLS + +#endif /* ISC_STRERROR_H */ diff -urN src/contrib/ntp/lib/isc/unix/include/isc/syslog.h src.ntp/contrib/ntp/lib/isc/unix/include/isc/syslog.h --- src/contrib/ntp/lib/isc/unix/include/isc/syslog.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/include/isc/syslog.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,47 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: syslog.h,v 1.7 2007/06/19 23:47:19 tbox Exp $ */ + +#ifndef ISC_SYSLOG_H +#define ISC_SYSLOG_H 1 + +/*! \file */ + +#include +#include + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_syslog_facilityfromstring(const char *str, int *facilityp); +/*%< + * Convert 'str' to the appropriate syslog facility constant. + * + * Requires: + * + *\li 'str' is not NULL + *\li 'facilityp' is not NULL + * + * Returns: + * \li #ISC_R_SUCCESS + * \li #ISC_R_NOTFOUND + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_SYSLOG_H */ diff -urN src/contrib/ntp/lib/isc/unix/include/isc/time.h src.ntp/contrib/ntp/lib/isc/unix/include/isc/time.h --- src/contrib/ntp/lib/isc/unix/include/isc/time.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/include/isc/time.h 2009-12-09 08:36:44.000000000 +0100 @@ -0,0 +1,334 @@ +/* + * Copyright (C) 2004-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: time.h,v 1.38.56.2 2009/01/05 23:47:23 tbox Exp $ */ + +#ifndef ISC_TIME_H +#define ISC_TIME_H 1 + +/*! \file */ + +#include +#include + +/*** + *** Intervals + ***/ + +/*! + * \brief + * The contents of this structure are private, and MUST NOT be accessed + * directly by callers. + * + * The contents are exposed only to allow callers to avoid dynamic allocation. + */ +struct isc_interval { + unsigned int seconds; + unsigned int nanoseconds; +}; + +extern isc_interval_t *isc_interval_zero; + +ISC_LANG_BEGINDECLS + +void +isc_interval_set(isc_interval_t *i, + unsigned int seconds, unsigned int nanoseconds); +/*%< + * Set 'i' to a value representing an interval of 'seconds' seconds and + * 'nanoseconds' nanoseconds, suitable for use in isc_time_add() and + * isc_time_subtract(). + * + * Requires: + * + *\li 't' is a valid pointer. + *\li nanoseconds < 1000000000. + */ + +isc_boolean_t +isc_interval_iszero(const isc_interval_t *i); +/*%< + * Returns ISC_TRUE iff. 'i' is the zero interval. + * + * Requires: + * + *\li 'i' is a valid pointer. + */ + +/*** + *** Absolute Times + ***/ + +/*% + * The contents of this structure are private, and MUST NOT be accessed + * directly by callers. + * + * The contents are exposed only to allow callers to avoid dynamic allocation. + */ + +struct isc_time { + unsigned int seconds; + unsigned int nanoseconds; +}; + +extern isc_time_t *isc_time_epoch; + +void +isc_time_set(isc_time_t *t, unsigned int seconds, unsigned int nanoseconds); +/*%< + * Set 't' to a value which represents the given number of seconds and + * nanoseconds since 00:00:00 January 1, 1970, UTC. + * + * Notes: + *\li The Unix version of this call is equivalent to: + *\code + * isc_time_settoepoch(t); + * isc_interval_set(i, seconds, nanoseconds); + * isc_time_add(t, i, t); + *\endcode + * + * Requires: + *\li 't' is a valid pointer. + *\li nanoseconds < 1000000000. + */ + +void +isc_time_settoepoch(isc_time_t *t); +/*%< + * Set 't' to the time of the epoch. + * + * Notes: + *\li The date of the epoch is platform-dependent. + * + * Requires: + * + *\li 't' is a valid pointer. + */ + +isc_boolean_t +isc_time_isepoch(const isc_time_t *t); +/*%< + * Returns ISC_TRUE iff. 't' is the epoch ("time zero"). + * + * Requires: + * + *\li 't' is a valid pointer. + */ + +isc_result_t +isc_time_now(isc_time_t *t); +/*%< + * Set 't' to the current absolute time. + * + * Requires: + * + *\li 't' is a valid pointer. + * + * Returns: + * + *\li Success + *\li Unexpected error + * Getting the time from the system failed. + *\li Out of range + * The time from the system is too large to be represented + * in the current definition of isc_time_t. + */ + +isc_result_t +isc_time_nowplusinterval(isc_time_t *t, const isc_interval_t *i); +/*%< + * Set *t to the current absolute time + i. + * + * Note: + *\li This call is equivalent to: + * + *\code + * isc_time_now(t); + * isc_time_add(t, i, t); + *\endcode + * + * Requires: + * + *\li 't' and 'i' are valid pointers. + * + * Returns: + * + *\li Success + *\li Unexpected error + * Getting the time from the system failed. + *\li Out of range + * The interval added to the time from the system is too large to + * be represented in the current definition of isc_time_t. + */ + +int +isc_time_compare(const isc_time_t *t1, const isc_time_t *t2); +/*%< + * Compare the times referenced by 't1' and 't2' + * + * Requires: + * + *\li 't1' and 't2' are valid pointers. + * + * Returns: + * + *\li -1 t1 < t2 (comparing times, not pointers) + *\li 0 t1 = t2 + *\li 1 t1 > t2 + */ + +isc_result_t +isc_time_add(const isc_time_t *t, const isc_interval_t *i, isc_time_t *result); +/*%< + * Add 'i' to 't', storing the result in 'result'. + * + * Requires: + * + *\li 't', 'i', and 'result' are valid pointers. + * + * Returns: + *\li Success + *\li Out of range + * The interval added to the time is too large to + * be represented in the current definition of isc_time_t. + */ + +isc_result_t +isc_time_subtract(const isc_time_t *t, const isc_interval_t *i, + isc_time_t *result); +/*%< + * Subtract 'i' from 't', storing the result in 'result'. + * + * Requires: + * + *\li 't', 'i', and 'result' are valid pointers. + * + * Returns: + *\li Success + *\li Out of range + * The interval is larger than the time since the epoch. + */ + +isc_uint64_t +isc_time_microdiff(const isc_time_t *t1, const isc_time_t *t2); +/*%< + * Find the difference in microseconds between time t1 and time t2. + * t2 is the subtrahend of t1; ie, difference = t1 - t2. + * + * Requires: + * + *\li 't1' and 't2' are valid pointers. + * + * Returns: + *\li The difference of t1 - t2, or 0 if t1 <= t2. + */ + +isc_uint32_t +isc_time_seconds(const isc_time_t *t); +/*%< + * Return the number of seconds since the epoch stored in a time structure. + * + * Requires: + * + *\li 't' is a valid pointer. + */ + +isc_result_t +isc_time_secondsastimet(const isc_time_t *t, time_t *secondsp); +/*%< + * Ensure the number of seconds in an isc_time_t is representable by a time_t. + * + * Notes: + *\li The number of seconds stored in an isc_time_t might be larger + * than the number of seconds a time_t is able to handle. Since + * time_t is mostly opaque according to the ANSI/ISO standard + * (essentially, all you can be sure of is that it is an arithmetic type, + * not even necessarily integral), it can be tricky to ensure that + * the isc_time_t is in the range a time_t can handle. Use this + * function in place of isc_time_seconds() any time you need to set a + * time_t from an isc_time_t. + * + * Requires: + *\li 't' is a valid pointer. + * + * Returns: + *\li Success + *\li Out of range + */ + +isc_uint32_t +isc_time_nanoseconds(const isc_time_t *t); +/*%< + * Return the number of nanoseconds stored in a time structure. + * + * Notes: + *\li This is the number of nanoseconds in excess of the number + * of seconds since the epoch; it will always be less than one + * full second. + * + * Requires: + *\li 't' is a valid pointer. + * + * Ensures: + *\li The returned value is less than 1*10^9. + */ + +void +isc_time_formattimestamp(const isc_time_t *t, char *buf, unsigned int len); +/*%< + * Format the time 't' into the buffer 'buf' of length 'len', + * using a format like "30-Aug-2000 04:06:47.997" and the local time zone. + * If the text does not fit in the buffer, the result is indeterminate, + * but is always guaranteed to be null terminated. + * + * Requires: + *\li 'len' > 0 + *\li 'buf' points to an array of at least len chars + * + */ + +void +isc_time_formathttptimestamp(const isc_time_t *t, char *buf, unsigned int len); +/*%< + * Format the time 't' into the buffer 'buf' of length 'len', + * using a format like "Mon, 30 Aug 2000 04:06:47 GMT" + * If the text does not fit in the buffer, the result is indeterminate, + * but is always guaranteed to be null terminated. + * + * Requires: + *\li 'len' > 0 + *\li 'buf' points to an array of at least len chars + * + */ + +void +isc_time_formatISO8601(const isc_time_t *t, char *buf, unsigned int len); +/*%< + * Format the time 't' into the buffer 'buf' of length 'len', + * using the ISO8601 format: "yyyy-mm-ddThh:mm:ssZ" + * If the text does not fit in the buffer, the result is indeterminate, + * but is always guaranteed to be null terminated. + * + * Requires: + *\li 'len' > 0 + *\li 'buf' points to an array of at least len chars + * + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_TIME_H */ diff -urN src/contrib/ntp/lib/isc/unix/interfaceiter.c src.ntp/contrib/ntp/lib/isc/unix/interfaceiter.c --- src/contrib/ntp/lib/isc/unix/interfaceiter.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/interfaceiter.c 2010-06-12 08:13:53.000000000 +0200 @@ -0,0 +1,341 @@ +/* + * Copyright (C) 2004, 2005, 2007-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: interfaceiter.c,v 1.44.120.2 2009/02/16 23:47:15 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include +#ifdef HAVE_SYS_SOCKIO_H +#include /* Required for ifiter_ioctl.c. */ +#endif + +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +/* Must follow . */ +#ifdef HAVE_NET_IF6_H +#include +#endif +#include + +/* Common utility functions */ + +/*% + * Extract the network address part from a "struct sockaddr". + * \brief + * The address family is given explicitly + * instead of using src->sa_family, because the latter does not work + * for copying a network mask obtained by SIOCGIFNETMASK (it does + * not have a valid address family). + */ + +static void +get_addr(unsigned int family, isc_netaddr_t *dst, struct sockaddr *src, + char *ifname) +{ + struct sockaddr_in6 *sa6; + +#if !defined(ISC_PLATFORM_HAVEIFNAMETOINDEX) || \ + !defined(ISC_PLATFORM_HAVESCOPEID) + UNUSED(ifname); +#endif + + /* clear any remaining value for safety */ + memset(dst, 0, sizeof(*dst)); + + dst->family = family; + switch (family) { + case AF_INET: + memcpy(&dst->type.in, + &((struct sockaddr_in *) src)->sin_addr, + sizeof(struct in_addr)); + break; + case AF_INET6: + sa6 = (struct sockaddr_in6 *)src; + memcpy(&dst->type.in6, &sa6->sin6_addr, + sizeof(struct in6_addr)); +#ifdef ISC_PLATFORM_HAVESCOPEID + if (sa6->sin6_scope_id != 0) + isc_netaddr_setzone(dst, sa6->sin6_scope_id); + else { + /* + * BSD variants embed scope zone IDs in the 128bit + * address as a kernel internal form. Unfortunately, + * the embedded IDs are not hidden from applications + * when getting access to them by sysctl or ioctl. + * We convert the internal format to the pure address + * part and the zone ID part. + * Since multicast addresses should not appear here + * and they cannot be distinguished from netmasks, + * we only consider unicast link-local addresses. + */ + if (IN6_IS_ADDR_LINKLOCAL(&sa6->sin6_addr)) { + isc_uint16_t zone16; + + memcpy(&zone16, &sa6->sin6_addr.s6_addr[2], + sizeof(zone16)); + zone16 = ntohs(zone16); + if (zone16 != 0) { + /* the zone ID is embedded */ + isc_netaddr_setzone(dst, + (isc_uint32_t)zone16); + dst->type.in6.s6_addr[2] = 0; + dst->type.in6.s6_addr[3] = 0; +#ifdef ISC_PLATFORM_HAVEIFNAMETOINDEX + } else if (ifname != NULL) { + unsigned int zone; + + /* + * sin6_scope_id is still not provided, + * but the corresponding interface name + * is know. Use the interface ID as + * the link ID. + */ + zone = if_nametoindex(ifname); + if (zone != 0) { + isc_netaddr_setzone(dst, + (isc_uint32_t)zone); + } +#endif + } + } + } +#endif + break; + default: + INSIST(0); + break; + } +} + +/* + * Include system-dependent code. + */ + +#ifdef __linux +#define ISC_IF_INET6_SZ \ + sizeof("00000000000000000000000000000001 01 80 10 80 XXXXXXloXXXXXXXX\n") +static isc_result_t linux_if_inet6_next(isc_interfaceiter_t *); +static isc_result_t linux_if_inet6_current(isc_interfaceiter_t *); +static void linux_if_inet6_first(isc_interfaceiter_t *iter); +#endif + +#if HAVE_GETIFADDRS +#include "ifiter_getifaddrs.c" +#elif HAVE_IFLIST_SYSCTL +#include "ifiter_sysctl.c" +#else +#include "ifiter_ioctl.c" +#endif + +#ifdef __linux +static void +linux_if_inet6_first(isc_interfaceiter_t *iter) { + if (iter->proc != NULL) { + rewind(iter->proc); + (void)linux_if_inet6_next(iter); + } else + iter->valid = ISC_R_NOMORE; +} + +static isc_result_t +linux_if_inet6_next(isc_interfaceiter_t *iter) { + if (iter->proc != NULL && + fgets(iter->entry, sizeof(iter->entry), iter->proc) != NULL) + iter->valid = ISC_R_SUCCESS; + else + iter->valid = ISC_R_NOMORE; + return (iter->valid); +} + +static isc_result_t +linux_if_inet6_current(isc_interfaceiter_t *iter) { + char address[33]; + char name[IF_NAMESIZE+1]; + char strbuf[ISC_STRERRORSIZE]; + struct in6_addr addr6; + int ifindex, prefix, scope, flags; + struct ifreq ifreq; + int res; + unsigned int i; + + if (iter->valid != ISC_R_SUCCESS) + return (iter->valid); + if (iter->proc == NULL) { + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_INTERFACE, ISC_LOG_ERROR, + "/proc/net/if_inet6:iter->proc == NULL"); + return (ISC_R_FAILURE); + } + + res = sscanf(iter->entry, "%32[a-f0-9] %x %x %x %x %16s\n", + address, &ifindex, &prefix, &scope, &flags, name); + if (res != 6) { + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_INTERFACE, ISC_LOG_ERROR, + "/proc/net/if_inet6:sscanf() -> %d (expected 6)", + res); + return (ISC_R_FAILURE); + } + if (strlen(address) != 32) { + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_INTERFACE, ISC_LOG_ERROR, + "/proc/net/if_inet6:strlen(%s) != 32", address); + return (ISC_R_FAILURE); + } + for (i = 0; i < 16; i++) { + unsigned char byte; + static const char hex[] = "0123456789abcdef"; + byte = ((strchr(hex, address[i * 2]) - hex) << 4) | + (strchr(hex, address[i * 2 + 1]) - hex); + addr6.s6_addr[i] = byte; + } + iter->current.af = AF_INET6; + iter->current.flags = 0; + memset(&ifreq, 0, sizeof(ifreq)); + INSIST(sizeof(ifreq.ifr_name) <= sizeof(iter->current.name)); + strncpy(ifreq.ifr_name, name, sizeof(ifreq.ifr_name)); + + if (ioctl(iter->socket, SIOCGIFFLAGS, (char *) &ifreq) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "%s: getting interface flags: %s", + ifreq.ifr_name, strbuf); + return (ISC_R_IGNORE); + } + + if ((ifreq.ifr_flags & IFF_UP) != 0) + iter->current.flags |= INTERFACE_F_UP; +#ifdef IFF_POINTOPOINT + if ((ifreq.ifr_flags & IFF_POINTOPOINT) != 0) + iter->current.flags |= INTERFACE_F_POINTTOPOINT; +#endif + if ((ifreq.ifr_flags & IFF_LOOPBACK) != 0) + iter->current.flags |= INTERFACE_F_LOOPBACK; + if ((ifreq.ifr_flags & IFF_BROADCAST) != 0) + iter->current.flags |= INTERFACE_F_BROADCAST; +#ifdef IFF_MULTICAST + if ((ifreq.ifr_flags & IFF_MULTICAST) != 0) + iter->current.flags |= INTERFACE_F_MULTICAST; +#endif + + isc_netaddr_fromin6(&iter->current.address, &addr6); + if (isc_netaddr_islinklocal(&iter->current.address)) { + isc_netaddr_setzone(&iter->current.address, + (isc_uint32_t)ifindex); + } + for (i = 0; i < 16; i++) { + if (prefix > 8) { + addr6.s6_addr[i] = 0xff; + prefix -= 8; + } else { + addr6.s6_addr[i] = (0xff << (8 - prefix)) & 0xff; + prefix = 0; + } + } + isc_netaddr_fromin6(&iter->current.netmask, &addr6); + strncpy(iter->current.name, name, sizeof(iter->current.name)); + return (ISC_R_SUCCESS); +} +#endif + +/* + * The remaining code is common to the sysctl and ioctl case. + */ + +isc_result_t +isc_interfaceiter_current(isc_interfaceiter_t *iter, + isc_interface_t *ifdata) +{ + REQUIRE(iter->result == ISC_R_SUCCESS); + memcpy(ifdata, &iter->current, sizeof(*ifdata)); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_interfaceiter_first(isc_interfaceiter_t *iter) { + isc_result_t result; + + REQUIRE(VALID_IFITER(iter)); + + internal_first(iter); + for (;;) { + result = internal_current(iter); + if (result != ISC_R_IGNORE) + break; + result = internal_next(iter); + if (result != ISC_R_SUCCESS) + break; + } + iter->result = result; + return (result); +} + +isc_result_t +isc_interfaceiter_next(isc_interfaceiter_t *iter) { + isc_result_t result; + + REQUIRE(VALID_IFITER(iter)); + REQUIRE(iter->result == ISC_R_SUCCESS); + + for (;;) { + result = internal_next(iter); + if (result != ISC_R_SUCCESS) + break; + result = internal_current(iter); + if (result != ISC_R_IGNORE) + break; + } + iter->result = result; + return (result); +} + +void +isc_interfaceiter_destroy(isc_interfaceiter_t **iterp) +{ + isc_interfaceiter_t *iter; + REQUIRE(iterp != NULL); + iter = *iterp; + REQUIRE(VALID_IFITER(iter)); + + internal_destroy(iter); + if (iter->buf != NULL) + isc_mem_put(iter->mctx, iter->buf, iter->bufsize); + + iter->magic = 0; + isc_mem_put(iter->mctx, iter, sizeof(*iter)); + *iterp = NULL; +} diff -urN src/contrib/ntp/lib/isc/unix/ipv6.c src.ntp/contrib/ntp/lib/isc/unix/ipv6.c --- src/contrib/ntp/lib/isc/unix/ipv6.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/ipv6.c 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,27 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: ipv6.c,v 1.14 2007/06/19 23:47:18 tbox Exp $ */ + +/*! \file */ + +#include + +#include + +const struct in6_addr in6addr_any = IN6ADDR_ANY_INIT; +const struct in6_addr in6addr_loopback = IN6ADDR_LOOPBACK_INIT; diff -urN src/contrib/ntp/lib/isc/unix/keyboard.c src.ntp/contrib/ntp/lib/isc/unix/keyboard.c --- src/contrib/ntp/lib/isc/unix/keyboard.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/keyboard.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,126 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: keyboard.c,v 1.13 2007/06/19 23:47:18 tbox Exp $ */ + +#include + +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include + +#include +#include + +isc_result_t +isc_keyboard_open(isc_keyboard_t *keyboard) { + int fd; + isc_result_t ret; + struct termios current_mode; + + REQUIRE(keyboard != NULL); + + fd = open("/dev/tty", O_RDONLY, 0); + if (fd < 0) + return (ISC_R_IOERROR); + + keyboard->fd = fd; + + if (tcgetattr(fd, &keyboard->saved_mode) < 0) { + ret = ISC_R_IOERROR; + goto errout; + } + + current_mode = keyboard->saved_mode; + + current_mode.c_iflag &= + ~(IGNBRK|BRKINT|PARMRK|ISTRIP|INLCR|IGNCR|ICRNL|IXON); + current_mode.c_oflag &= ~OPOST; + current_mode.c_lflag &= ~(ECHO|ECHONL|ICANON|ISIG|IEXTEN); + current_mode.c_cflag &= ~(CSIZE|PARENB); + current_mode.c_cflag |= CS8; + + current_mode.c_cc[VMIN] = 1; + current_mode.c_cc[VTIME] = 0; + if (tcsetattr(fd, TCSAFLUSH, ¤t_mode) < 0) { + ret = ISC_R_IOERROR; + goto errout; + } + + keyboard->result = ISC_R_SUCCESS; + + return (ISC_R_SUCCESS); + + errout: + close (fd); + + return (ret); +} + +isc_result_t +isc_keyboard_close(isc_keyboard_t *keyboard, unsigned int sleeptime) { + REQUIRE(keyboard != NULL); + + if (sleeptime > 0 && keyboard->result != ISC_R_CANCELED) + (void)sleep(sleeptime); + + (void)tcsetattr(keyboard->fd, TCSAFLUSH, &keyboard->saved_mode); + (void)close(keyboard->fd); + + keyboard->fd = -1; + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_keyboard_getchar(isc_keyboard_t *keyboard, unsigned char *cp) { + ssize_t cc; + unsigned char c; + cc_t *controlchars; + + REQUIRE(keyboard != NULL); + REQUIRE(cp != NULL); + + cc = read(keyboard->fd, &c, 1); + if (cc < 0) { + keyboard->result = ISC_R_IOERROR; + return (keyboard->result); + } + + controlchars = keyboard->saved_mode.c_cc; + if (c == controlchars[VINTR] || c == controlchars[VQUIT]) { + keyboard->result = ISC_R_CANCELED; + return (keyboard->result); + } + + *cp = c; + + return (ISC_R_SUCCESS); +} + +isc_boolean_t +isc_keyboard_canceled(isc_keyboard_t *keyboard) { + return (ISC_TF(keyboard->result == ISC_R_CANCELED)); +} diff -urN src/contrib/ntp/lib/isc/unix/net.c src.ntp/contrib/ntp/lib/isc/unix/net.c --- src/contrib/ntp/lib/isc/unix/net.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/net.c 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,525 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: net.c,v 1.40 2008/07/04 05:52:31 each Exp $ */ + +#include + +#include + +#if defined(HAVE_SYS_SYSCTL_H) +#if defined(HAVE_SYS_PARAM_H) +#include +#endif +#include +#endif + +#include +#include + +#include +#include +#include +#include +#include +#include +#include + +/*% + * Definitions about UDP port range specification. This is a total mess of + * portability variants: some use sysctl (but the sysctl names vary), some use + * system-specific interfaces, some have the same interface for IPv4 and IPv6, + * some separate them, etc... + */ + +/*% + * The last resort defaults: use all non well known port space + */ +#ifndef ISC_NET_PORTRANGELOW +#define ISC_NET_PORTRANGELOW 1024 +#endif /* ISC_NET_PORTRANGELOW */ +#ifndef ISC_NET_PORTRANGEHIGH +#define ISC_NET_PORTRANGEHIGH 65535 +#endif /* ISC_NET_PORTRANGEHIGH */ + +#ifdef HAVE_SYSCTLBYNAME + +/*% + * sysctl variants + */ +#if defined(__FreeBSD__) || defined(__APPLE__) || defined(__DragonFly__) +#define USE_SYSCTL_PORTRANGE +#define SYSCTL_V4PORTRANGE_LOW "net.inet.ip.portrange.hifirst" +#define SYSCTL_V4PORTRANGE_HIGH "net.inet.ip.portrange.hilast" +#define SYSCTL_V6PORTRANGE_LOW "net.inet.ip.portrange.hifirst" +#define SYSCTL_V6PORTRANGE_HIGH "net.inet.ip.portrange.hilast" +#endif + +#ifdef __NetBSD__ +#define USE_SYSCTL_PORTRANGE +#define SYSCTL_V4PORTRANGE_LOW "net.inet.ip.anonportmin" +#define SYSCTL_V4PORTRANGE_HIGH "net.inet.ip.anonportmax" +#define SYSCTL_V6PORTRANGE_LOW "net.inet6.ip6.anonportmin" +#define SYSCTL_V6PORTRANGE_HIGH "net.inet6.ip6.anonportmax" +#endif + +#else /* !HAVE_SYSCTLBYNAME */ + +#ifdef __OpenBSD__ +#define USE_SYSCTL_PORTRANGE +#define SYSCTL_V4PORTRANGE_LOW { CTL_NET, PF_INET, IPPROTO_IP, \ + IPCTL_IPPORT_HIFIRSTAUTO } +#define SYSCTL_V4PORTRANGE_HIGH { CTL_NET, PF_INET, IPPROTO_IP, \ + IPCTL_IPPORT_HILASTAUTO } +/* Same for IPv6 */ +#define SYSCTL_V6PORTRANGE_LOW SYSCTL_V4PORTRANGE_LOW +#define SYSCTL_V6PORTRANGE_HIGH SYSCTL_V4PORTRANGE_HIGH +#endif + +#endif /* HAVE_SYSCTLBYNAME */ + +#if defined(ISC_PLATFORM_NEEDIN6ADDRANY) +const struct in6_addr isc_net_in6addrany = IN6ADDR_ANY_INIT; +#endif + +#if defined(ISC_PLATFORM_HAVEIPV6) + +# if defined(ISC_PLATFORM_NEEDIN6ADDRLOOPBACK) +const struct in6_addr isc_net_in6addrloop = IN6ADDR_LOOPBACK_INIT; +# endif + +# if defined(WANT_IPV6) +static isc_once_t once_ipv6only = ISC_ONCE_INIT; +# endif + +# if defined(ISC_PLATFORM_HAVEIN6PKTINFO) +static isc_once_t once_ipv6pktinfo = ISC_ONCE_INIT; +# endif +#endif /* ISC_PLATFORM_HAVEIPV6 */ + +static isc_once_t once = ISC_ONCE_INIT; + +static isc_result_t ipv4_result = ISC_R_NOTFOUND; +static isc_result_t ipv6_result = ISC_R_NOTFOUND; +static isc_result_t unix_result = ISC_R_NOTFOUND; +static isc_result_t ipv6only_result = ISC_R_NOTFOUND; +static isc_result_t ipv6pktinfo_result = ISC_R_NOTFOUND; + +static isc_result_t +try_proto(int domain) { + int s; + isc_result_t result = ISC_R_SUCCESS; + char strbuf[ISC_STRERRORSIZE]; + + s = socket(domain, SOCK_STREAM, 0); + if (s == -1) { + switch (errno) { +#ifdef EAFNOSUPPORT + case EAFNOSUPPORT: +#endif +#ifdef EPROTONOSUPPORT + case EPROTONOSUPPORT: +#endif +#ifdef EINVAL + case EINVAL: +#endif + return (ISC_R_NOTFOUND); + default: + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "socket() %s: %s", + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + return (ISC_R_UNEXPECTED); + } + } + +#ifdef ISC_PLATFORM_HAVEIPV6 +#ifdef WANT_IPV6 +#ifdef ISC_PLATFORM_HAVEIN6PKTINFO + if (domain == PF_INET6) { + struct sockaddr_in6 sin6; + GETSOCKNAME_SOCKLEN_TYPE len; /* NTP local change */ + + /* + * Check to see if IPv6 is broken, as is common on Linux. + */ + len = sizeof(sin6); + if (getsockname(s, (struct sockaddr *)&sin6, &len) < 0) + { + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + "retrieving the address of an IPv6 " + "socket from the kernel failed."); + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + "IPv6 is not supported."); + result = ISC_R_NOTFOUND; + } else { + if (len == sizeof(struct sockaddr_in6)) + result = ISC_R_SUCCESS; + else { + isc_log_write(isc_lctx, + ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, + ISC_LOG_ERROR, + "IPv6 structures in kernel and " + "user space do not match."); + isc_log_write(isc_lctx, + ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, + ISC_LOG_ERROR, + "IPv6 is not supported."); + result = ISC_R_NOTFOUND; + } + } + } +#endif +#endif +#endif + + (void)close(s); + + return (result); +} + +static void +initialize_action(void) { + ipv4_result = try_proto(PF_INET); +#ifdef ISC_PLATFORM_HAVEIPV6 +#ifdef WANT_IPV6 +#ifdef ISC_PLATFORM_HAVEIN6PKTINFO + ipv6_result = try_proto(PF_INET6); +#endif +#endif +#endif +#ifdef ISC_PLATFORM_HAVESYSUNH + unix_result = try_proto(PF_UNIX); +#endif +} + +static void +initialize(void) { + RUNTIME_CHECK(isc_once_do(&once, initialize_action) == ISC_R_SUCCESS); +} + +isc_result_t +isc_net_probeipv4(void) { + initialize(); + return (ipv4_result); +} + +isc_result_t +isc_net_probeipv6(void) { + initialize(); + return (ipv6_result); +} + +isc_result_t +isc_net_probeunix(void) { + initialize(); + return (unix_result); +} + +#ifdef ISC_PLATFORM_HAVEIPV6 +#ifdef WANT_IPV6 +static void +try_ipv6only(void) { +#ifdef IPV6_V6ONLY + int s, on; + char strbuf[ISC_STRERRORSIZE]; +#endif + isc_result_t result; + + result = isc_net_probeipv6(); + if (result != ISC_R_SUCCESS) { + ipv6only_result = result; + return; + } + +#ifndef IPV6_V6ONLY + ipv6only_result = ISC_R_NOTFOUND; + return; +#else + /* check for TCP sockets */ + s = socket(PF_INET6, SOCK_STREAM, 0); + if (s == -1) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "socket() %s: %s", + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + ipv6only_result = ISC_R_UNEXPECTED; + return; + } + + on = 1; + if (setsockopt(s, IPPROTO_IPV6, IPV6_V6ONLY, &on, sizeof(on)) < 0) { + ipv6only_result = ISC_R_NOTFOUND; + goto close; + } + + close(s); + + /* check for UDP sockets */ + s = socket(PF_INET6, SOCK_DGRAM, 0); + if (s == -1) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "socket() %s: %s", + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + ipv6only_result = ISC_R_UNEXPECTED; + return; + } + + on = 1; + if (setsockopt(s, IPPROTO_IPV6, IPV6_V6ONLY, &on, sizeof(on)) < 0) { + ipv6only_result = ISC_R_NOTFOUND; + goto close; + } + + close(s); + + ipv6only_result = ISC_R_SUCCESS; + +close: + close(s); + return; +#endif /* IPV6_V6ONLY */ +} + +static void +initialize_ipv6only(void) { + RUNTIME_CHECK(isc_once_do(&once_ipv6only, + try_ipv6only) == ISC_R_SUCCESS); +} +#endif /* WANT_IPV6 */ + +#ifdef ISC_PLATFORM_HAVEIN6PKTINFO +static void +try_ipv6pktinfo(void) { + int s, on; + char strbuf[ISC_STRERRORSIZE]; + isc_result_t result; + int optname; + + result = isc_net_probeipv6(); + if (result != ISC_R_SUCCESS) { + ipv6pktinfo_result = result; + return; + } + + /* we only use this for UDP sockets */ + s = socket(PF_INET6, SOCK_DGRAM, IPPROTO_UDP); + if (s == -1) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "socket() %s: %s", + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + ipv6pktinfo_result = ISC_R_UNEXPECTED; + return; + } + +#ifdef IPV6_RECVPKTINFO + optname = IPV6_RECVPKTINFO; +#else + optname = IPV6_PKTINFO; +#endif + on = 1; + if (setsockopt(s, IPPROTO_IPV6, optname, &on, sizeof(on)) < 0) { + ipv6pktinfo_result = ISC_R_NOTFOUND; + goto close; + } + + close(s); + ipv6pktinfo_result = ISC_R_SUCCESS; + +close: + close(s); + return; +} + +static void +initialize_ipv6pktinfo(void) { + RUNTIME_CHECK(isc_once_do(&once_ipv6pktinfo, + try_ipv6pktinfo) == ISC_R_SUCCESS); +} +#endif /* ISC_PLATFORM_HAVEIN6PKTINFO */ +#endif /* ISC_PLATFORM_HAVEIPV6 */ + +isc_result_t +isc_net_probe_ipv6only(void) { +#ifdef ISC_PLATFORM_HAVEIPV6 +#ifdef WANT_IPV6 + initialize_ipv6only(); +#else + ipv6only_result = ISC_R_NOTFOUND; +#endif +#endif + return (ipv6only_result); +} + +isc_result_t +isc_net_probe_ipv6pktinfo(void) { +#ifdef ISC_PLATFORM_HAVEIPV6 +#ifdef ISC_PLATFORM_HAVEIN6PKTINFO +#ifdef WANT_IPV6 + initialize_ipv6pktinfo(); +#else + ipv6pktinfo_result = ISC_R_NOTFOUND; +#endif +#endif +#endif + return (ipv6pktinfo_result); +} + +#if defined(USE_SYSCTL_PORTRANGE) +#if defined(HAVE_SYSCTLBYNAME) +static isc_result_t +getudpportrange_sysctl(int af, in_port_t *low, in_port_t *high) { + int port_low, port_high; + size_t portlen; + const char *sysctlname_lowport, *sysctlname_hiport; + + if (af == AF_INET) { + sysctlname_lowport = SYSCTL_V4PORTRANGE_LOW; + sysctlname_hiport = SYSCTL_V4PORTRANGE_HIGH; + } else { + sysctlname_lowport = SYSCTL_V6PORTRANGE_LOW; + sysctlname_hiport = SYSCTL_V6PORTRANGE_HIGH; + } + portlen = sizeof(portlen); + if (sysctlbyname(sysctlname_lowport, &port_low, &portlen, + NULL, 0) < 0) { + return (ISC_R_FAILURE); + } + portlen = sizeof(portlen); + if (sysctlbyname(sysctlname_hiport, &port_high, &portlen, + NULL, 0) < 0) { + return (ISC_R_FAILURE); + } + if ((port_low & ~0xffff) != 0 || (port_high & ~0xffff) != 0) + return (ISC_R_RANGE); + + *low = (in_port_t)port_low; + *high = (in_port_t)port_high; + + return (ISC_R_SUCCESS); +} +#else /* !HAVE_SYSCTLBYNAME */ +static isc_result_t +getudpportrange_sysctl(int af, in_port_t *low, in_port_t *high) { + int mib_lo4[4] = SYSCTL_V4PORTRANGE_LOW; + int mib_hi4[4] = SYSCTL_V4PORTRANGE_HIGH; + int mib_lo6[4] = SYSCTL_V6PORTRANGE_LOW; + int mib_hi6[4] = SYSCTL_V6PORTRANGE_HIGH; + int *mib_lo, *mib_hi, miblen; + int port_low, port_high; + size_t portlen; + + if (af == AF_INET) { + mib_lo = mib_lo4; + mib_hi = mib_hi4; + miblen = sizeof(mib_lo4) / sizeof(mib_lo4[0]); + } else { + mib_lo = mib_lo6; + mib_hi = mib_hi6; + miblen = sizeof(mib_lo6) / sizeof(mib_lo6[0]); + } + + portlen = sizeof(portlen); + if (sysctl(mib_lo, miblen, &port_low, &portlen, NULL, 0) < 0) { + return (ISC_R_FAILURE); + } + + portlen = sizeof(portlen); + if (sysctl(mib_hi, miblen, &port_high, &portlen, NULL, 0) < 0) { + return (ISC_R_FAILURE); + } + + if ((port_low & ~0xffff) != 0 || (port_high & ~0xffff) != 0) + return (ISC_R_RANGE); + + *low = (in_port_t) port_low; + *high = (in_port_t) port_high; + + return (ISC_R_SUCCESS); +} +#endif /* HAVE_SYSCTLBYNAME */ +#endif /* USE_SYSCTL_PORTRANGE */ + +isc_result_t +isc_net_getudpportrange(int af, in_port_t *low, in_port_t *high) { + int result = ISC_R_FAILURE; + + REQUIRE(low != NULL && high != NULL); + +#if defined(USE_SYSCTL_PORTRANGE) + result = getudpportrange_sysctl(af, low, high); +#else + UNUSED(af); +#endif + + if (result != ISC_R_SUCCESS) { + *low = ISC_NET_PORTRANGELOW; + *high = ISC_NET_PORTRANGEHIGH; + } + + return (ISC_R_SUCCESS); /* we currently never fail in this function */ +} + +void +isc_net_disableipv4(void) { + initialize(); + if (ipv4_result == ISC_R_SUCCESS) + ipv4_result = ISC_R_DISABLED; +} + +void +isc_net_disableipv6(void) { + initialize(); + if (ipv6_result == ISC_R_SUCCESS) + ipv6_result = ISC_R_DISABLED; +} + +void +isc_net_enableipv4(void) { + initialize(); + if (ipv4_result == ISC_R_DISABLED) + ipv4_result = ISC_R_SUCCESS; +} + +void +isc_net_enableipv6(void) { + initialize(); + if (ipv6_result == ISC_R_DISABLED) + ipv6_result = ISC_R_SUCCESS; +} diff -urN src/contrib/ntp/lib/isc/unix/os.c src.ntp/contrib/ntp/lib/isc/unix/os.c --- src/contrib/ntp/lib/isc/unix/os.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/os.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,94 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: os.c,v 1.18 2007/06/19 23:47:18 tbox Exp $ */ + +#include + +#include + + +#ifdef HAVE_SYSCONF + +#include + +#ifndef __hpux +static inline long +sysconf_ncpus(void) { +#if defined(_SC_NPROCESSORS_ONLN) + return sysconf((_SC_NPROCESSORS_ONLN)); +#elif defined(_SC_NPROC_ONLN) + return sysconf((_SC_NPROC_ONLN)); +#else + return (0); +#endif +} +#endif +#endif /* HAVE_SYSCONF */ + + +#ifdef __hpux + +#include + +static inline int +hpux_ncpus(void) { + struct pst_dynamic psd; + if (pstat_getdynamic(&psd, sizeof(psd), 1, 0) != -1) + return (psd.psd_proc_cnt); + else + return (0); +} + +#endif /* __hpux */ + +#if defined(HAVE_SYS_SYSCTL_H) && defined(HAVE_SYSCTLBYNAME) +#include /* for FreeBSD */ +#include /* for NetBSD */ +#include + +static int +sysctl_ncpus(void) { + int ncpu, result; + size_t len; + + len = sizeof(ncpu); + result = sysctlbyname("hw.ncpu", &ncpu, &len , 0, 0); + if (result != -1) + return (ncpu); + return (0); +} +#endif + +unsigned int +isc_os_ncpus(void) { + long ncpus = 0; + +#ifdef __hpux + ncpus = hpux_ncpus(); +#elif defined(HAVE_SYSCONF) + ncpus = sysconf_ncpus(); +#endif +#if defined(HAVE_SYS_SYSCTL_H) && defined(HAVE_SYSCTLBYNAME) + if (ncpus <= 0) + ncpus = sysctl_ncpus(); +#endif + if (ncpus <= 0) + ncpus = 1; + + return ((unsigned int)ncpus); +} diff -urN src/contrib/ntp/lib/isc/unix/resource.c src.ntp/contrib/ntp/lib/isc/unix/resource.c --- src/contrib/ntp/lib/isc/unix/resource.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/resource.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,231 @@ +/* + * Copyright (C) 2004, 2007-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: resource.c,v 1.21.66.2 2009/02/13 23:47:39 tbox Exp $ */ + +#include + +#include +#include /* Required on some systems for . */ +#include + +#include +#include +#include +#include + +#ifdef __linux__ +#include /* To get the large NR_OPEN. */ +#endif + +#if defined(__hpux) && defined(HAVE_SYS_DYNTUNE_H) +#include +#endif + +#include "errno2result.h" + +static isc_result_t +resource2rlim(isc_resource_t resource, int *rlim_resource) { + isc_result_t result = ISC_R_SUCCESS; + + switch (resource) { + case isc_resource_coresize: + *rlim_resource = RLIMIT_CORE; + break; + case isc_resource_cputime: + *rlim_resource = RLIMIT_CPU; + break; + case isc_resource_datasize: + *rlim_resource = RLIMIT_DATA; + break; + case isc_resource_filesize: + *rlim_resource = RLIMIT_FSIZE; + break; + case isc_resource_lockedmemory: +#ifdef RLIMIT_MEMLOCK + *rlim_resource = RLIMIT_MEMLOCK; +#else + result = ISC_R_NOTIMPLEMENTED; +#endif + break; + case isc_resource_openfiles: +#ifdef RLIMIT_NOFILE + *rlim_resource = RLIMIT_NOFILE; +#else + result = ISC_R_NOTIMPLEMENTED; +#endif + break; + case isc_resource_processes: +#ifdef RLIMIT_NPROC + *rlim_resource = RLIMIT_NPROC; +#else + result = ISC_R_NOTIMPLEMENTED; +#endif + break; + case isc_resource_residentsize: +#ifdef RLIMIT_RSS + *rlim_resource = RLIMIT_RSS; +#else + result = ISC_R_NOTIMPLEMENTED; +#endif + break; + case isc_resource_stacksize: + *rlim_resource = RLIMIT_STACK; + break; + default: + /* + * This test is not very robust if isc_resource_t + * changes, but generates a clear assertion message. + */ + REQUIRE(resource >= isc_resource_coresize && + resource <= isc_resource_stacksize); + + result = ISC_R_RANGE; + break; + } + + return (result); +} + +isc_result_t +isc_resource_setlimit(isc_resource_t resource, isc_resourcevalue_t value) { + struct rlimit rl; + ISC_PLATFORM_RLIMITTYPE rlim_value; + int unixresult; + int unixresource; + isc_result_t result; + + result = resource2rlim(resource, &unixresource); + if (result != ISC_R_SUCCESS) + return (result); + + if (value == ISC_RESOURCE_UNLIMITED) + rlim_value = RLIM_INFINITY; + + else { + /* + * isc_resourcevalue_t was chosen as an unsigned 64 bit + * integer so that it could contain the maximum range of + * reasonable values. Unfortunately, this exceeds the typical + * range on Unix systems. Ensure the range of + * ISC_PLATFORM_RLIMITTYPE is not overflowed. + */ + isc_resourcevalue_t rlim_max; + isc_boolean_t rlim_t_is_signed = + ISC_TF(((double)(ISC_PLATFORM_RLIMITTYPE)-1) < 0); + + if (rlim_t_is_signed) + rlim_max = ~((ISC_PLATFORM_RLIMITTYPE)1 << + (sizeof(ISC_PLATFORM_RLIMITTYPE) * 8 - 1)); + else + rlim_max = (ISC_PLATFORM_RLIMITTYPE)-1; + + if (value > rlim_max) + value = rlim_max; + + rlim_value = value; + } + + rl.rlim_cur = rl.rlim_max = rlim_value; + unixresult = setrlimit(unixresource, &rl); + + if (unixresult == 0) + return (ISC_R_SUCCESS); + +#if defined(OPEN_MAX) && defined(__APPLE__) + /* + * The Darwin kernel doesn't accept RLIM_INFINITY for rlim_cur; the + * maximum possible value is OPEN_MAX. BIND8 used to use + * sysconf(_SC_OPEN_MAX) for such a case, but this value is much + * smaller than OPEN_MAX and is not really effective. + */ + if (resource == isc_resource_openfiles && rlim_value == RLIM_INFINITY) { + rl.rlim_cur = OPEN_MAX; + unixresult = setrlimit(unixresource, &rl); + if (unixresult == 0) + return (ISC_R_SUCCESS); + } +#elif defined(__linux__) +#ifndef NR_OPEN +#define NR_OPEN (1024*1024) +#endif + + /* + * Some Linux kernels don't accept RLIM_INFINIT; the maximum + * possible value is the NR_OPEN defined in linux/fs.h. + */ + if (resource == isc_resource_openfiles && rlim_value == RLIM_INFINITY) { + rl.rlim_cur = rl.rlim_max = NR_OPEN; + unixresult = setrlimit(unixresource, &rl); + if (unixresult == 0) + return (ISC_R_SUCCESS); + } +#elif defined(__hpux) && defined(HAVE_SYS_DYNTUNE_H) + if (resource == isc_resource_openfiles && rlim_value == RLIM_INFINITY) { + uint64_t maxfiles; + if (gettune("maxfiles_lim", &maxfiles) == 0) { + rl.rlim_cur = rl.rlim_max = maxfiles; + unixresult = setrlimit(unixresource, &rl); + if (unixresult == 0) + return (ISC_R_SUCCESS); + } + } +#endif + if (resource == isc_resource_openfiles && rlim_value == RLIM_INFINITY) { + if (getrlimit(unixresource, &rl) == 0) { + rl.rlim_cur = rl.rlim_max; + unixresult = setrlimit(unixresource, &rl); + if (unixresult == 0) + return (ISC_R_SUCCESS); + } + } + return (isc__errno2result(errno)); +} + +isc_result_t +isc_resource_getlimit(isc_resource_t resource, isc_resourcevalue_t *value) { + int unixresult; + int unixresource; + struct rlimit rl; + isc_result_t result; + + result = resource2rlim(resource, &unixresource); + if (result == ISC_R_SUCCESS) { + unixresult = getrlimit(unixresource, &rl); + INSIST(unixresult == 0); + *value = rl.rlim_max; + } + + return (result); +} + +isc_result_t +isc_resource_getcurlimit(isc_resource_t resource, isc_resourcevalue_t *value) { + int unixresult; + int unixresource; + struct rlimit rl; + isc_result_t result; + + result = resource2rlim(resource, &unixresource); + if (result == ISC_R_SUCCESS) { + unixresult = getrlimit(unixresource, &rl); + INSIST(unixresult == 0); + *value = rl.rlim_cur; + } + + return (result); +} diff -urN src/contrib/ntp/lib/isc/unix/socket.c src.ntp/contrib/ntp/lib/isc/unix/socket.c --- src/contrib/ntp/lib/isc/unix/socket.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/socket.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,5550 @@ +/* + * Copyright (C) 2004-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: socket.c,v 1.308.12.8 2009/04/18 01:29:26 jinmei Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#ifdef ISC_PLATFORM_HAVESYSUNH +#include +#endif +#ifdef ISC_PLATFORM_HAVEKQUEUE +#include +#endif +#ifdef ISC_PLATFORM_HAVEEPOLL +#include +#endif +#ifdef ISC_PLATFORM_HAVEDEVPOLL +#include +#endif + +#include "errno2result.h" + +#ifndef ISC_PLATFORM_USETHREADS +#include "socket_p.h" +#endif /* ISC_PLATFORM_USETHREADS */ + +#if defined(SO_BSDCOMPAT) && defined(__linux__) +#include +#endif + +/*% + * Choose the most preferable multiplex method. + */ +#ifdef ISC_PLATFORM_HAVEKQUEUE +#define USE_KQUEUE +#elif defined (ISC_PLATFORM_HAVEEPOLL) +#define USE_EPOLL +#elif defined (ISC_PLATFORM_HAVEDEVPOLL) +#define USE_DEVPOLL +typedef struct { + unsigned int want_read : 1, + want_write : 1; +} pollinfo_t; +#else +#define USE_SELECT +#endif /* ISC_PLATFORM_HAVEKQUEUE */ + +#ifndef ISC_PLATFORM_USETHREADS +#if defined(USE_KQUEUE) || defined(USE_EPOLL) || defined(USE_DEVPOLL) +struct isc_socketwait { + int nevents; +}; +#elif defined (USE_SELECT) +struct isc_socketwait { + fd_set *readset; + fd_set *writeset; + int nfds; + int maxfd; +}; +#endif /* USE_KQUEUE */ +#endif /* !ISC_PLATFORM_USETHREADS */ + +/*% + * Maximum number of allowable open sockets. This is also the maximum + * allowable socket file descriptor. + * + * Care should be taken before modifying this value for select(): + * The API standard doesn't ensure select() accept more than (the system default + * of) FD_SETSIZE descriptors, and the default size should in fact be fine in + * the vast majority of cases. This constant should therefore be increased only + * when absolutely necessary and possible, i.e., the server is exhausting all + * available file descriptors (up to FD_SETSIZE) and the select() function + * and FD_xxx macros support larger values than FD_SETSIZE (which may not + * always by true, but we keep using some of them to ensure as much + * portability as possible). Note also that overall server performance + * may be rather worsened with a larger value of this constant due to + * inherent scalability problems of select(). + * + * As a special note, this value shouldn't have to be touched if + * this is a build for an authoritative only DNS server. + */ +#ifndef ISC_SOCKET_MAXSOCKETS +#if defined(USE_KQUEUE) || defined(USE_EPOLL) || defined(USE_DEVPOLL) +#define ISC_SOCKET_MAXSOCKETS 4096 +#elif defined(USE_SELECT) +#define ISC_SOCKET_MAXSOCKETS FD_SETSIZE +#endif /* USE_KQUEUE... */ +#endif /* ISC_SOCKET_MAXSOCKETS */ + +#ifdef USE_SELECT +/*% + * Mac OS X needs a special definition to support larger values in select(). + * We always define this because a larger value can be specified run-time. + */ +#ifdef __APPLE__ +#define _DARWIN_UNLIMITED_SELECT +#endif /* __APPLE__ */ +#endif /* USE_SELECT */ + +#ifdef ISC_SOCKET_USE_POLLWATCH +/*% + * If this macro is defined, enable workaround for a Solaris /dev/poll kernel + * bug: DP_POLL ioctl could keep sleeping even if socket I/O is possible for + * some of the specified FD. The idea is based on the observation that it's + * likely for a busy server to keep receiving packets. It specifically works + * as follows: the socket watcher is first initialized with the state of + * "poll_idle". While it's in the idle state it keeps sleeping until a socket + * event occurs. When it wakes up for a socket I/O event, it moves to the + * poll_active state, and sets the poll timeout to a short period + * (ISC_SOCKET_POLLWATCH_TIMEOUT msec). If timeout occurs in this state, the + * watcher goes to the poll_checking state with the same timeout period. + * In this state, the watcher tries to detect whether this is a break + * during intermittent events or the kernel bug is triggered. If the next + * polling reports an event within the short period, the previous timeout is + * likely to be a kernel bug, and so the watcher goes back to the active state. + * Otherwise, it moves to the idle state again. + * + * It's not clear whether this is a thread-related bug, but since we've only + * seen this with threads, this workaround is used only when enabling threads. + */ + +typedef enum { poll_idle, poll_active, poll_checking } pollstate_t; + +#ifndef ISC_SOCKET_POLLWATCH_TIMEOUT +#define ISC_SOCKET_POLLWATCH_TIMEOUT 10 +#endif /* ISC_SOCKET_POLLWATCH_TIMEOUT */ +#endif /* ISC_SOCKET_USE_POLLWATCH */ + +/*% + * Size of per-FD lock buckets. + */ +#ifdef ISC_PLATFORM_USETHREADS +#define FDLOCK_COUNT 1024 +#define FDLOCK_ID(fd) ((fd) % FDLOCK_COUNT) +#else +#define FDLOCK_COUNT 1 +#define FDLOCK_ID(fd) 0 +#endif /* ISC_PLATFORM_USETHREADS */ + +/*% + * Maximum number of events communicated with the kernel. There should normally + * be no need for having a large number. + */ +#if defined(USE_KQUEUE) || defined(USE_EPOLL) || defined(USE_DEVPOLL) +#ifndef ISC_SOCKET_MAXEVENTS +#define ISC_SOCKET_MAXEVENTS 64 +#endif +#endif + +/*% + * Some systems define the socket length argument as an int, some as size_t, + * some as socklen_t. This is here so it can be easily changed if needed. + */ +#ifndef ISC_SOCKADDR_LEN_T +#define ISC_SOCKADDR_LEN_T unsigned int +#endif + +/*% + * Define what the possible "soft" errors can be. These are non-fatal returns + * of various network related functions, like recv() and so on. + * + * For some reason, BSDI (and perhaps others) will sometimes return <0 + * from recv() but will have errno==0. This is broken, but we have to + * work around it here. + */ +#define SOFT_ERROR(e) ((e) == EAGAIN || \ + (e) == EWOULDBLOCK || \ + (e) == EINTR || \ + (e) == 0) + +#define DLVL(x) ISC_LOGCATEGORY_GENERAL, ISC_LOGMODULE_SOCKET, ISC_LOG_DEBUG(x) + +/*!< + * DLVL(90) -- Function entry/exit and other tracing. + * DLVL(70) -- Socket "correctness" -- including returning of events, etc. + * DLVL(60) -- Socket data send/receive + * DLVL(50) -- Event tracing, including receiving/sending completion events. + * DLVL(20) -- Socket creation/destruction. + */ +#define TRACE_LEVEL 90 +#define CORRECTNESS_LEVEL 70 +#define IOEVENT_LEVEL 60 +#define EVENT_LEVEL 50 +#define CREATION_LEVEL 20 + +#define TRACE DLVL(TRACE_LEVEL) +#define CORRECTNESS DLVL(CORRECTNESS_LEVEL) +#define IOEVENT DLVL(IOEVENT_LEVEL) +#define EVENT DLVL(EVENT_LEVEL) +#define CREATION DLVL(CREATION_LEVEL) + +typedef isc_event_t intev_t; + +#define SOCKET_MAGIC ISC_MAGIC('I', 'O', 'i', 'o') +#define VALID_SOCKET(t) ISC_MAGIC_VALID(t, SOCKET_MAGIC) + +/*! + * IPv6 control information. If the socket is an IPv6 socket we want + * to collect the destination address and interface so the client can + * set them on outgoing packets. + */ +#ifdef ISC_PLATFORM_HAVEIN6PKTINFO +#ifndef USE_CMSG +#define USE_CMSG 1 +#endif +#endif + +/*% + * NetBSD and FreeBSD can timestamp packets. XXXMLG Should we have + * a setsockopt() like interface to request timestamps, and if the OS + * doesn't do it for us, call gettimeofday() on every UDP receive? + */ +#ifdef SO_TIMESTAMP +#ifndef USE_CMSG +#define USE_CMSG 1 +#endif +#endif + +/*% + * The size to raise the receive buffer to (from BIND 8). + */ +#define RCVBUFSIZE (32*1024) + +/*% + * The number of times a send operation is repeated if the result is EINTR. + */ +#define NRETRIES 10 + +struct isc_socket { + /* Not locked. */ + unsigned int magic; + isc_socketmgr_t *manager; + isc_mutex_t lock; + isc_sockettype_t type; + const isc_statscounter_t *statsindex; + + /* Locked by socket lock. */ + ISC_LINK(isc_socket_t) link; + unsigned int references; + int fd; + int pf; + char name[16]; + void * tag; + + ISC_LIST(isc_socketevent_t) send_list; + ISC_LIST(isc_socketevent_t) recv_list; + ISC_LIST(isc_socket_newconnev_t) accept_list; + isc_socket_connev_t *connect_ev; + + /* + * Internal events. Posted when a descriptor is readable or + * writable. These are statically allocated and never freed. + * They will be set to non-purgable before use. + */ + intev_t readable_ev; + intev_t writable_ev; + + isc_sockaddr_t peer_address; /* remote address */ + + unsigned int pending_recv : 1, + pending_send : 1, + pending_accept : 1, + listener : 1, /* listener socket */ + connected : 1, + connecting : 1, /* connect pending */ + bound : 1; /* bound to local addr */ + +#ifdef ISC_NET_RECVOVERFLOW + unsigned char overflow; /* used for MSG_TRUNC fake */ +#endif + + char *recvcmsgbuf; + ISC_SOCKADDR_LEN_T recvcmsgbuflen; + char *sendcmsgbuf; + ISC_SOCKADDR_LEN_T sendcmsgbuflen; + + void *fdwatcharg; + isc_sockfdwatch_t fdwatchcb; + int fdwatchflags; + isc_task_t *fdwatchtask; +}; + +#define SOCKET_MANAGER_MAGIC ISC_MAGIC('I', 'O', 'm', 'g') +#define VALID_MANAGER(m) ISC_MAGIC_VALID(m, SOCKET_MANAGER_MAGIC) + +struct isc_socketmgr { + /* Not locked. */ + unsigned int magic; + isc_mem_t *mctx; + isc_mutex_t lock; + isc_mutex_t *fdlock; + isc_stats_t *stats; +#ifdef USE_KQUEUE + int kqueue_fd; + int nevents; + struct kevent *events; +#endif /* USE_KQUEUE */ +#ifdef USE_EPOLL + int epoll_fd; + int nevents; + struct epoll_event *events; +#endif /* USE_EPOLL */ +#ifdef USE_DEVPOLL + int devpoll_fd; + int nevents; + struct pollfd *events; +#endif /* USE_DEVPOLL */ +#ifdef USE_SELECT + int fd_bufsize; +#endif /* USE_SELECT */ + unsigned int maxsocks; +#ifdef ISC_PLATFORM_USETHREADS + int pipe_fds[2]; +#endif + + /* Locked by fdlock. */ + isc_socket_t **fds; + int *fdstate; +#ifdef USE_DEVPOLL + pollinfo_t *fdpollinfo; +#endif + + /* Locked by manager lock. */ + ISC_LIST(isc_socket_t) socklist; +#ifdef USE_SELECT + fd_set *read_fds; + fd_set *read_fds_copy; + fd_set *write_fds; + fd_set *write_fds_copy; + int maxfd; +#endif /* USE_SELECT */ + int reserved; /* unlocked */ +#ifdef ISC_PLATFORM_USETHREADS + isc_thread_t watcher; + isc_condition_t shutdown_ok; +#else /* ISC_PLATFORM_USETHREADS */ + unsigned int refs; +#endif /* ISC_PLATFORM_USETHREADS */ +}; + +#ifndef ISC_PLATFORM_USETHREADS +static isc_socketmgr_t *socketmgr = NULL; +#endif /* ISC_PLATFORM_USETHREADS */ + +#define CLOSED 0 /* this one must be zero */ +#define MANAGED 1 +#define CLOSE_PENDING 2 + +/* + * send() and recv() iovec counts + */ +#define MAXSCATTERGATHER_SEND (ISC_SOCKET_MAXSCATTERGATHER) +#ifdef ISC_NET_RECVOVERFLOW +# define MAXSCATTERGATHER_RECV (ISC_SOCKET_MAXSCATTERGATHER + 1) +#else +# define MAXSCATTERGATHER_RECV (ISC_SOCKET_MAXSCATTERGATHER) +#endif + +static void send_recvdone_event(isc_socket_t *, isc_socketevent_t **); +static void send_senddone_event(isc_socket_t *, isc_socketevent_t **); +static void free_socket(isc_socket_t **); +static isc_result_t allocate_socket(isc_socketmgr_t *, isc_sockettype_t, + isc_socket_t **); +static void destroy(isc_socket_t **); +static void internal_accept(isc_task_t *, isc_event_t *); +static void internal_connect(isc_task_t *, isc_event_t *); +static void internal_recv(isc_task_t *, isc_event_t *); +static void internal_send(isc_task_t *, isc_event_t *); +static void internal_fdwatch_write(isc_task_t *, isc_event_t *); +static void internal_fdwatch_read(isc_task_t *, isc_event_t *); +static void process_cmsg(isc_socket_t *, struct msghdr *, isc_socketevent_t *); +static void build_msghdr_send(isc_socket_t *, isc_socketevent_t *, + struct msghdr *, struct iovec *, size_t *); +static void build_msghdr_recv(isc_socket_t *, isc_socketevent_t *, + struct msghdr *, struct iovec *, size_t *); +#ifdef ISC_PLATFORM_USETHREADS +static isc_boolean_t process_ctlfd(isc_socketmgr_t *manager); +#endif + +#define SELECT_POKE_SHUTDOWN (-1) +#define SELECT_POKE_NOTHING (-2) +#define SELECT_POKE_READ (-3) +#define SELECT_POKE_ACCEPT (-3) /*%< Same as _READ */ +#define SELECT_POKE_WRITE (-4) +#define SELECT_POKE_CONNECT (-4) /*%< Same as _WRITE */ +#define SELECT_POKE_CLOSE (-5) + +#define SOCK_DEAD(s) ((s)->references == 0) + +/*% + * Shortcut index arrays to get access to statistics counters. + */ +enum { + STATID_OPEN = 0, + STATID_OPENFAIL = 1, + STATID_CLOSE = 2, + STATID_BINDFAIL = 3, + STATID_CONNECTFAIL = 4, + STATID_CONNECT = 5, + STATID_ACCEPTFAIL = 6, + STATID_ACCEPT = 7, + STATID_SENDFAIL = 8, + STATID_RECVFAIL = 9 +}; +static const isc_statscounter_t upd4statsindex[] = { + isc_sockstatscounter_udp4open, + isc_sockstatscounter_udp4openfail, + isc_sockstatscounter_udp4close, + isc_sockstatscounter_udp4bindfail, + isc_sockstatscounter_udp4connectfail, + isc_sockstatscounter_udp4connect, + -1, + -1, + isc_sockstatscounter_udp4sendfail, + isc_sockstatscounter_udp4recvfail +}; +static const isc_statscounter_t upd6statsindex[] = { + isc_sockstatscounter_udp6open, + isc_sockstatscounter_udp6openfail, + isc_sockstatscounter_udp6close, + isc_sockstatscounter_udp6bindfail, + isc_sockstatscounter_udp6connectfail, + isc_sockstatscounter_udp6connect, + -1, + -1, + isc_sockstatscounter_udp6sendfail, + isc_sockstatscounter_udp6recvfail +}; +static const isc_statscounter_t tcp4statsindex[] = { + isc_sockstatscounter_tcp4open, + isc_sockstatscounter_tcp4openfail, + isc_sockstatscounter_tcp4close, + isc_sockstatscounter_tcp4bindfail, + isc_sockstatscounter_tcp4connectfail, + isc_sockstatscounter_tcp4connect, + isc_sockstatscounter_tcp4acceptfail, + isc_sockstatscounter_tcp4accept, + isc_sockstatscounter_tcp4sendfail, + isc_sockstatscounter_tcp4recvfail +}; +static const isc_statscounter_t tcp6statsindex[] = { + isc_sockstatscounter_tcp6open, + isc_sockstatscounter_tcp6openfail, + isc_sockstatscounter_tcp6close, + isc_sockstatscounter_tcp6bindfail, + isc_sockstatscounter_tcp6connectfail, + isc_sockstatscounter_tcp6connect, + isc_sockstatscounter_tcp6acceptfail, + isc_sockstatscounter_tcp6accept, + isc_sockstatscounter_tcp6sendfail, + isc_sockstatscounter_tcp6recvfail +}; +static const isc_statscounter_t unixstatsindex[] = { + isc_sockstatscounter_unixopen, + isc_sockstatscounter_unixopenfail, + isc_sockstatscounter_unixclose, + isc_sockstatscounter_unixbindfail, + isc_sockstatscounter_unixconnectfail, + isc_sockstatscounter_unixconnect, + isc_sockstatscounter_unixacceptfail, + isc_sockstatscounter_unixaccept, + isc_sockstatscounter_unixsendfail, + isc_sockstatscounter_unixrecvfail +}; +static const isc_statscounter_t fdwatchstatsindex[] = { + -1, + -1, + isc_sockstatscounter_fdwatchclose, + isc_sockstatscounter_fdwatchbindfail, + isc_sockstatscounter_fdwatchconnectfail, + isc_sockstatscounter_fdwatchconnect, + -1, + -1, + isc_sockstatscounter_fdwatchsendfail, + isc_sockstatscounter_fdwatchrecvfail +}; + +static void +manager_log(isc_socketmgr_t *sockmgr, + isc_logcategory_t *category, isc_logmodule_t *module, int level, + const char *fmt, ...) ISC_FORMAT_PRINTF(5, 6); +static void +manager_log(isc_socketmgr_t *sockmgr, + isc_logcategory_t *category, isc_logmodule_t *module, int level, + const char *fmt, ...) +{ + char msgbuf[2048]; + va_list ap; + + if (! isc_log_wouldlog(isc_lctx, level)) + return; + + va_start(ap, fmt); + vsnprintf(msgbuf, sizeof(msgbuf), fmt, ap); + va_end(ap); + + isc_log_write(isc_lctx, category, module, level, + "sockmgr %p: %s", sockmgr, msgbuf); +} + +static void +socket_log(isc_socket_t *sock, isc_sockaddr_t *address, + isc_logcategory_t *category, isc_logmodule_t *module, int level, + isc_msgcat_t *msgcat, int msgset, int message, + const char *fmt, ...) ISC_FORMAT_PRINTF(9, 10); +static void +socket_log(isc_socket_t *sock, isc_sockaddr_t *address, + isc_logcategory_t *category, isc_logmodule_t *module, int level, + isc_msgcat_t *msgcat, int msgset, int message, + const char *fmt, ...) +{ + char msgbuf[2048]; + char peerbuf[ISC_SOCKADDR_FORMATSIZE]; + va_list ap; + + if (! isc_log_wouldlog(isc_lctx, level)) + return; + + va_start(ap, fmt); + vsnprintf(msgbuf, sizeof(msgbuf), fmt, ap); + va_end(ap); + + if (address == NULL) { + isc_log_iwrite(isc_lctx, category, module, level, + msgcat, msgset, message, + "socket %p: %s", sock, msgbuf); + } else { + isc_sockaddr_format(address, peerbuf, sizeof(peerbuf)); + isc_log_iwrite(isc_lctx, category, module, level, + msgcat, msgset, message, + "socket %p %s: %s", sock, peerbuf, msgbuf); + } +} + +#if defined(_AIX) && defined(ISC_NET_BSD44MSGHDR) && \ + defined(USE_CMSG) && defined(IPV6_RECVPKTINFO) +/* + * AIX has a kernel bug where IPV6_RECVPKTINFO gets cleared by + * setting IPV6_V6ONLY. + */ +static void +FIX_IPV6_RECVPKTINFO(isc_socket_t *sock) +{ + char strbuf[ISC_STRERRORSIZE]; + int on = 1; + + if (sock->pf != AF_INET6 || sock->type != isc_sockettype_udp) + return; + + if (setsockopt(sock->fd, IPPROTO_IPV6, IPV6_RECVPKTINFO, + (void *)&on, sizeof(on)) < 0) { + + UNEXPECTED_ERROR(__FILE__, __LINE__, + "setsockopt(%d, IPV6_RECVPKTINFO) " + "%s: %s", sock->fd, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + } +} +#else +#define FIX_IPV6_RECVPKTINFO(sock) (void)0 +#endif + +/*% + * Increment socket-related statistics counters. + */ +static inline void +inc_stats(isc_stats_t *stats, isc_statscounter_t counterid) { + REQUIRE(counterid != -1); + + if (stats != NULL) + isc_stats_increment(stats, counterid); +} + +static inline isc_result_t +watch_fd(isc_socketmgr_t *manager, int fd, int msg) { + isc_result_t result = ISC_R_SUCCESS; + +#ifdef USE_KQUEUE + struct kevent evchange; + + memset(&evchange, 0, sizeof(evchange)); + if (msg == SELECT_POKE_READ) + evchange.filter = EVFILT_READ; + else + evchange.filter = EVFILT_WRITE; + evchange.flags = EV_ADD; + evchange.ident = fd; + if (kevent(manager->kqueue_fd, &evchange, 1, NULL, 0, NULL) != 0) + result = isc__errno2result(errno); + + return (result); +#elif defined(USE_EPOLL) + struct epoll_event event; + + if (msg == SELECT_POKE_READ) + event.events = EPOLLIN; + else + event.events = EPOLLOUT; + event.data.fd = fd; + if (epoll_ctl(manager->epoll_fd, EPOLL_CTL_ADD, fd, &event) == -1 && + errno != EEXIST) { + result = isc__errno2result(errno); + } + + return (result); +#elif defined(USE_DEVPOLL) + struct pollfd pfd; + int lockid = FDLOCK_ID(fd); + + memset(&pfd, 0, sizeof(pfd)); + if (msg == SELECT_POKE_READ) + pfd.events = POLLIN; + else + pfd.events = POLLOUT; + pfd.fd = fd; + pfd.revents = 0; + LOCK(&manager->fdlock[lockid]); + if (write(manager->devpoll_fd, &pfd, sizeof(pfd)) == -1) + result = isc__errno2result(errno); + else { + if (msg == SELECT_POKE_READ) + manager->fdpollinfo[fd].want_read = 1; + else + manager->fdpollinfo[fd].want_write = 1; + } + UNLOCK(&manager->fdlock[lockid]); + + return (result); +#elif defined(USE_SELECT) + LOCK(&manager->lock); + if (msg == SELECT_POKE_READ) + FD_SET(fd, manager->read_fds); + if (msg == SELECT_POKE_WRITE) + FD_SET(fd, manager->write_fds); + UNLOCK(&manager->lock); + + return (result); +#endif +} + +static inline isc_result_t +unwatch_fd(isc_socketmgr_t *manager, int fd, int msg) { + isc_result_t result = ISC_R_SUCCESS; + +#ifdef USE_KQUEUE + struct kevent evchange; + + memset(&evchange, 0, sizeof(evchange)); + if (msg == SELECT_POKE_READ) + evchange.filter = EVFILT_READ; + else + evchange.filter = EVFILT_WRITE; + evchange.flags = EV_DELETE; + evchange.ident = fd; + if (kevent(manager->kqueue_fd, &evchange, 1, NULL, 0, NULL) != 0) + result = isc__errno2result(errno); + + return (result); +#elif defined(USE_EPOLL) + struct epoll_event event; + + if (msg == SELECT_POKE_READ) + event.events = EPOLLIN; + else + event.events = EPOLLOUT; + event.data.fd = fd; + if (epoll_ctl(manager->epoll_fd, EPOLL_CTL_DEL, fd, &event) == -1 && + errno != ENOENT) { + char strbuf[ISC_STRERRORSIZE]; + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "epoll_ctl(DEL), %d: %s", fd, strbuf); + result = ISC_R_UNEXPECTED; + } + return (result); +#elif defined(USE_DEVPOLL) + struct pollfd pfds[2]; + size_t writelen = sizeof(pfds[0]); + int lockid = FDLOCK_ID(fd); + + memset(pfds, 0, sizeof(pfds)); + pfds[0].events = POLLREMOVE; + pfds[0].fd = fd; + + /* + * Canceling read or write polling via /dev/poll is tricky. Since it + * only provides a way of canceling per FD, we may need to re-poll the + * socket for the other operation. + */ + LOCK(&manager->fdlock[lockid]); + if (msg == SELECT_POKE_READ && + manager->fdpollinfo[fd].want_write == 1) { + pfds[1].events = POLLOUT; + pfds[1].fd = fd; + writelen += sizeof(pfds[1]); + } + if (msg == SELECT_POKE_WRITE && + manager->fdpollinfo[fd].want_read == 1) { + pfds[1].events = POLLIN; + pfds[1].fd = fd; + writelen += sizeof(pfds[1]); + } + + if (write(manager->devpoll_fd, pfds, writelen) == -1) + result = isc__errno2result(errno); + else { + if (msg == SELECT_POKE_READ) + manager->fdpollinfo[fd].want_read = 0; + else + manager->fdpollinfo[fd].want_write = 0; + } + UNLOCK(&manager->fdlock[lockid]); + + return (result); +#elif defined(USE_SELECT) + LOCK(&manager->lock); + if (msg == SELECT_POKE_READ) + FD_CLR(fd, manager->read_fds); + else if (msg == SELECT_POKE_WRITE) + FD_CLR(fd, manager->write_fds); + UNLOCK(&manager->lock); + + return (result); +#endif +} + +static void +wakeup_socket(isc_socketmgr_t *manager, int fd, int msg) { + isc_result_t result; + int lockid = FDLOCK_ID(fd); + + /* + * This is a wakeup on a socket. If the socket is not in the + * process of being closed, start watching it for either reads + * or writes. + */ + + INSIST(fd >= 0 && fd < (int)manager->maxsocks); + + if (msg == SELECT_POKE_CLOSE) { + /* No one should be updating fdstate, so no need to lock it */ + INSIST(manager->fdstate[fd] == CLOSE_PENDING); + manager->fdstate[fd] = CLOSED; + (void)unwatch_fd(manager, fd, SELECT_POKE_READ); + (void)unwatch_fd(manager, fd, SELECT_POKE_WRITE); + (void)close(fd); + return; + } + + LOCK(&manager->fdlock[lockid]); + if (manager->fdstate[fd] == CLOSE_PENDING) { + UNLOCK(&manager->fdlock[lockid]); + + /* + * We accept (and ignore) any error from unwatch_fd() as we are + * closing the socket, hoping it doesn't leave dangling state in + * the kernel. + * Note that unwatch_fd() must be called after releasing the + * fdlock; otherwise it could cause deadlock due to a lock order + * reversal. + */ + (void)unwatch_fd(manager, fd, SELECT_POKE_READ); + (void)unwatch_fd(manager, fd, SELECT_POKE_WRITE); + return; + } + if (manager->fdstate[fd] != MANAGED) { + UNLOCK(&manager->fdlock[lockid]); + return; + } + UNLOCK(&manager->fdlock[lockid]); + + /* + * Set requested bit. + */ + result = watch_fd(manager, fd, msg); + if (result != ISC_R_SUCCESS) { + /* + * XXXJT: what should we do? Ignoring the failure of watching + * a socket will make the application dysfunctional, but there + * seems to be no reasonable recovery process. + */ + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + "failed to start watching FD (%d): %s", + fd, isc_result_totext(result)); + } +} + +#ifdef ISC_PLATFORM_USETHREADS +/* + * Poke the select loop when there is something for us to do. + * The write is required (by POSIX) to complete. That is, we + * will not get partial writes. + */ +static void +select_poke(isc_socketmgr_t *mgr, int fd, int msg) { + int cc; + int buf[2]; + char strbuf[ISC_STRERRORSIZE]; + + buf[0] = fd; + buf[1] = msg; + + do { + cc = write(mgr->pipe_fds[1], buf, sizeof(buf)); +#ifdef ENOSR + /* + * Treat ENOSR as EAGAIN but loop slowly as it is + * unlikely to clear fast. + */ + if (cc < 0 && errno == ENOSR) { + sleep(1); + errno = EAGAIN; + } +#endif + } while (cc < 0 && SOFT_ERROR(errno)); + + if (cc < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + FATAL_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_WRITEFAILED, + "write() failed " + "during watcher poke: %s"), + strbuf); + } + + INSIST(cc == sizeof(buf)); +} + +/* + * Read a message on the internal fd. + */ +static void +select_readmsg(isc_socketmgr_t *mgr, int *fd, int *msg) { + int buf[2]; + int cc; + char strbuf[ISC_STRERRORSIZE]; + + cc = read(mgr->pipe_fds[0], buf, sizeof(buf)); + if (cc < 0) { + *msg = SELECT_POKE_NOTHING; + *fd = -1; /* Silence compiler. */ + if (SOFT_ERROR(errno)) + return; + + isc__strerror(errno, strbuf, sizeof(strbuf)); + FATAL_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_READFAILED, + "read() failed " + "during watcher poke: %s"), + strbuf); + + return; + } + INSIST(cc == sizeof(buf)); + + *fd = buf[0]; + *msg = buf[1]; +} +#else /* ISC_PLATFORM_USETHREADS */ +/* + * Update the state of the socketmgr when something changes. + */ +static void +select_poke(isc_socketmgr_t *manager, int fd, int msg) { + if (msg == SELECT_POKE_SHUTDOWN) + return; + else if (fd >= 0) + wakeup_socket(manager, fd, msg); + return; +} +#endif /* ISC_PLATFORM_USETHREADS */ + +/* + * Make a fd non-blocking. + */ +static isc_result_t +make_nonblock(int fd) { + int ret; + int flags; + char strbuf[ISC_STRERRORSIZE]; +#ifdef USE_FIONBIO_IOCTL + int on = 1; + + ret = ioctl(fd, FIONBIO, (char *)&on); +#else + flags = fcntl(fd, F_GETFL, 0); + flags |= PORT_NONBLOCK; + ret = fcntl(fd, F_SETFL, flags); +#endif + + if (ret == -1) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, +#ifdef USE_FIONBIO_IOCTL + "ioctl(%d, FIONBIO, &on): %s", fd, +#else + "fcntl(%d, F_SETFL, %d): %s", fd, flags, +#endif + strbuf); + + return (ISC_R_UNEXPECTED); + } + + return (ISC_R_SUCCESS); +} + +#ifdef USE_CMSG +/* + * Not all OSes support advanced CMSG macros: CMSG_LEN and CMSG_SPACE. + * In order to ensure as much portability as possible, we provide wrapper + * functions of these macros. + * Note that cmsg_space() could run slow on OSes that do not have + * CMSG_SPACE. + */ +static inline ISC_SOCKADDR_LEN_T +cmsg_len(ISC_SOCKADDR_LEN_T len) { +#ifdef CMSG_LEN + return (CMSG_LEN(len)); +#else + ISC_SOCKADDR_LEN_T hdrlen; + + /* + * Cast NULL so that any pointer arithmetic performed by CMSG_DATA + * is correct. + */ + hdrlen = (ISC_SOCKADDR_LEN_T)CMSG_DATA(((struct cmsghdr *)NULL)); + return (hdrlen + len); +#endif +} + +static inline ISC_SOCKADDR_LEN_T +cmsg_space(ISC_SOCKADDR_LEN_T len) { +#ifdef CMSG_SPACE + return (CMSG_SPACE(len)); +#else + struct msghdr msg; + struct cmsghdr *cmsgp; + /* + * XXX: The buffer length is an ad-hoc value, but should be enough + * in a practical sense. + */ + char dummybuf[sizeof(struct cmsghdr) + 1024]; + + memset(&msg, 0, sizeof(msg)); + msg.msg_control = dummybuf; + msg.msg_controllen = sizeof(dummybuf); + + cmsgp = (struct cmsghdr *)dummybuf; + cmsgp->cmsg_len = cmsg_len(len); + + cmsgp = CMSG_NXTHDR(&msg, cmsgp); + if (cmsgp != NULL) + return ((char *)cmsgp - (char *)msg.msg_control); + else + return (0); +#endif +} +#endif /* USE_CMSG */ + +/* + * Process control messages received on a socket. + */ +static void +process_cmsg(isc_socket_t *sock, struct msghdr *msg, isc_socketevent_t *dev) { +#ifdef USE_CMSG + struct cmsghdr *cmsgp; +#ifdef ISC_PLATFORM_HAVEIN6PKTINFO + struct in6_pktinfo *pktinfop; +#endif +#ifdef SO_TIMESTAMP + struct timeval *timevalp; +#endif +#endif + + /* + * sock is used only when ISC_NET_BSD44MSGHDR and USE_CMSG are defined. + * msg and dev are used only when ISC_NET_BSD44MSGHDR is defined. + * They are all here, outside of the CPP tests, because it is + * more consistent with the usual ISC coding style. + */ + UNUSED(sock); + UNUSED(msg); + UNUSED(dev); + +#ifdef ISC_NET_BSD44MSGHDR + +#ifdef MSG_TRUNC + if ((msg->msg_flags & MSG_TRUNC) == MSG_TRUNC) + dev->attributes |= ISC_SOCKEVENTATTR_TRUNC; +#endif + +#ifdef MSG_CTRUNC + if ((msg->msg_flags & MSG_CTRUNC) == MSG_CTRUNC) + dev->attributes |= ISC_SOCKEVENTATTR_CTRUNC; +#endif + +#ifndef USE_CMSG + return; +#else + if (msg->msg_controllen == 0U || msg->msg_control == NULL) + return; + +#ifdef SO_TIMESTAMP + timevalp = NULL; +#endif +#ifdef ISC_PLATFORM_HAVEIN6PKTINFO + pktinfop = NULL; +#endif + + cmsgp = CMSG_FIRSTHDR(msg); + while (cmsgp != NULL) { + socket_log(sock, NULL, TRACE, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_PROCESSCMSG, + "processing cmsg %p", cmsgp); + +#ifdef ISC_PLATFORM_HAVEIN6PKTINFO + if (cmsgp->cmsg_level == IPPROTO_IPV6 + && cmsgp->cmsg_type == IPV6_PKTINFO) { + + pktinfop = (struct in6_pktinfo *)CMSG_DATA(cmsgp); + memcpy(&dev->pktinfo, pktinfop, + sizeof(struct in6_pktinfo)); + dev->attributes |= ISC_SOCKEVENTATTR_PKTINFO; + socket_log(sock, NULL, TRACE, + isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_IFRECEIVED, + "interface received on ifindex %u", + dev->pktinfo.ipi6_ifindex); + if (IN6_IS_ADDR_MULTICAST(&pktinfop->ipi6_addr)) + dev->attributes |= ISC_SOCKEVENTATTR_MULTICAST; + goto next; + } +#endif + +#ifdef SO_TIMESTAMP + if (cmsgp->cmsg_level == SOL_SOCKET + && cmsgp->cmsg_type == SCM_TIMESTAMP) { + timevalp = (struct timeval *)CMSG_DATA(cmsgp); + dev->timestamp.seconds = timevalp->tv_sec; + dev->timestamp.nanoseconds = timevalp->tv_usec * 1000; + dev->attributes |= ISC_SOCKEVENTATTR_TIMESTAMP; + goto next; + } +#endif + + next: + cmsgp = CMSG_NXTHDR(msg, cmsgp); + } +#endif /* USE_CMSG */ + +#endif /* ISC_NET_BSD44MSGHDR */ +} + +/* + * Construct an iov array and attach it to the msghdr passed in. This is + * the SEND constructor, which will use the used region of the buffer + * (if using a buffer list) or will use the internal region (if a single + * buffer I/O is requested). + * + * Nothing can be NULL, and the done event must list at least one buffer + * on the buffer linked list for this function to be meaningful. + * + * If write_countp != NULL, *write_countp will hold the number of bytes + * this transaction can send. + */ +static void +build_msghdr_send(isc_socket_t *sock, isc_socketevent_t *dev, + struct msghdr *msg, struct iovec *iov, size_t *write_countp) +{ + unsigned int iovcount; + isc_buffer_t *buffer; + isc_region_t used; + size_t write_count; + size_t skip_count; + + memset(msg, 0, sizeof(*msg)); + + if (!sock->connected) { + msg->msg_name = (void *)&dev->address.type.sa; + msg->msg_namelen = dev->address.length; + } else { + msg->msg_name = NULL; + msg->msg_namelen = 0; + } + + buffer = ISC_LIST_HEAD(dev->bufferlist); + write_count = 0; + iovcount = 0; + + /* + * Single buffer I/O? Skip what we've done so far in this region. + */ + if (buffer == NULL) { + write_count = dev->region.length - dev->n; + iov[0].iov_base = (void *)(dev->region.base + dev->n); + iov[0].iov_len = write_count; + iovcount = 1; + + goto config; + } + + /* + * Multibuffer I/O. + * Skip the data in the buffer list that we have already written. + */ + skip_count = dev->n; + while (buffer != NULL) { + REQUIRE(ISC_BUFFER_VALID(buffer)); + if (skip_count < isc_buffer_usedlength(buffer)) + break; + skip_count -= isc_buffer_usedlength(buffer); + buffer = ISC_LIST_NEXT(buffer, link); + } + + while (buffer != NULL) { + INSIST(iovcount < MAXSCATTERGATHER_SEND); + + isc_buffer_usedregion(buffer, &used); + + if (used.length > 0) { + iov[iovcount].iov_base = (void *)(used.base + + skip_count); + iov[iovcount].iov_len = used.length - skip_count; + write_count += (used.length - skip_count); + skip_count = 0; + iovcount++; + } + buffer = ISC_LIST_NEXT(buffer, link); + } + + INSIST(skip_count == 0U); + + config: + msg->msg_iov = iov; + msg->msg_iovlen = iovcount; + +#ifdef ISC_NET_BSD44MSGHDR + msg->msg_control = NULL; + msg->msg_controllen = 0; + msg->msg_flags = 0; +#if defined(USE_CMSG) && defined(ISC_PLATFORM_HAVEIN6PKTINFO) + if ((sock->type == isc_sockettype_udp) + && ((dev->attributes & ISC_SOCKEVENTATTR_PKTINFO) != 0)) { + struct cmsghdr *cmsgp; + struct in6_pktinfo *pktinfop; + + socket_log(sock, NULL, TRACE, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_SENDTODATA, + "sendto pktinfo data, ifindex %u", + dev->pktinfo.ipi6_ifindex); + + msg->msg_controllen = cmsg_space(sizeof(struct in6_pktinfo)); + INSIST(msg->msg_controllen <= sock->sendcmsgbuflen); + msg->msg_control = (void *)sock->sendcmsgbuf; + + cmsgp = (struct cmsghdr *)sock->sendcmsgbuf; + cmsgp->cmsg_level = IPPROTO_IPV6; + cmsgp->cmsg_type = IPV6_PKTINFO; + cmsgp->cmsg_len = cmsg_len(sizeof(struct in6_pktinfo)); + pktinfop = (struct in6_pktinfo *)CMSG_DATA(cmsgp); + memcpy(pktinfop, &dev->pktinfo, sizeof(struct in6_pktinfo)); + } +#endif /* USE_CMSG && ISC_PLATFORM_HAVEIPV6 */ +#else /* ISC_NET_BSD44MSGHDR */ + msg->msg_accrights = NULL; + msg->msg_accrightslen = 0; +#endif /* ISC_NET_BSD44MSGHDR */ + + if (write_countp != NULL) + *write_countp = write_count; +} + +/* + * Construct an iov array and attach it to the msghdr passed in. This is + * the RECV constructor, which will use the available region of the buffer + * (if using a buffer list) or will use the internal region (if a single + * buffer I/O is requested). + * + * Nothing can be NULL, and the done event must list at least one buffer + * on the buffer linked list for this function to be meaningful. + * + * If read_countp != NULL, *read_countp will hold the number of bytes + * this transaction can receive. + */ +static void +build_msghdr_recv(isc_socket_t *sock, isc_socketevent_t *dev, + struct msghdr *msg, struct iovec *iov, size_t *read_countp) +{ + unsigned int iovcount; + isc_buffer_t *buffer; + isc_region_t available; + size_t read_count; + + memset(msg, 0, sizeof(struct msghdr)); + + if (sock->type == isc_sockettype_udp) { + memset(&dev->address, 0, sizeof(dev->address)); +#ifdef BROKEN_RECVMSG + if (sock->pf == AF_INET) { + msg->msg_name = (void *)&dev->address.type.sin; + msg->msg_namelen = sizeof(dev->address.type.sin6); + } else if (sock->pf == AF_INET6) { + msg->msg_name = (void *)&dev->address.type.sin6; + msg->msg_namelen = sizeof(dev->address.type.sin6); +#ifdef ISC_PLATFORM_HAVESYSUNH + } else if (sock->pf == AF_UNIX) { + msg->msg_name = (void *)&dev->address.type.sunix; + msg->msg_namelen = sizeof(dev->address.type.sunix); +#endif + } else { + msg->msg_name = (void *)&dev->address.type.sa; + msg->msg_namelen = sizeof(dev->address.type); + } +#else + msg->msg_name = (void *)&dev->address.type.sa; + msg->msg_namelen = sizeof(dev->address.type); +#endif +#ifdef ISC_NET_RECVOVERFLOW + /* If needed, steal one iovec for overflow detection. */ + maxiov--; +#endif + } else { /* TCP */ + msg->msg_name = NULL; + msg->msg_namelen = 0; + dev->address = sock->peer_address; + } + + buffer = ISC_LIST_HEAD(dev->bufferlist); + read_count = 0; + + /* + * Single buffer I/O? Skip what we've done so far in this region. + */ + if (buffer == NULL) { + read_count = dev->region.length - dev->n; + iov[0].iov_base = (void *)(dev->region.base + dev->n); + iov[0].iov_len = read_count; + iovcount = 1; + + goto config; + } + + /* + * Multibuffer I/O. + * Skip empty buffers. + */ + while (buffer != NULL) { + REQUIRE(ISC_BUFFER_VALID(buffer)); + if (isc_buffer_availablelength(buffer) != 0) + break; + buffer = ISC_LIST_NEXT(buffer, link); + } + + iovcount = 0; + while (buffer != NULL) { + INSIST(iovcount < MAXSCATTERGATHER_RECV); + + isc_buffer_availableregion(buffer, &available); + + if (available.length > 0) { + iov[iovcount].iov_base = (void *)(available.base); + iov[iovcount].iov_len = available.length; + read_count += available.length; + iovcount++; + } + buffer = ISC_LIST_NEXT(buffer, link); + } + + config: + + /* + * If needed, set up to receive that one extra byte. Note that + * we know there is at least one iov left, since we stole it + * at the top of this function. + */ +#ifdef ISC_NET_RECVOVERFLOW + if (sock->type == isc_sockettype_udp) { + iov[iovcount].iov_base = (void *)(&sock->overflow); + iov[iovcount].iov_len = 1; + iovcount++; + } +#endif + + msg->msg_iov = iov; + msg->msg_iovlen = iovcount; + +#ifdef ISC_NET_BSD44MSGHDR + msg->msg_control = NULL; + msg->msg_controllen = 0; + msg->msg_flags = 0; +#if defined(USE_CMSG) + if (sock->type == isc_sockettype_udp) { + msg->msg_control = sock->recvcmsgbuf; + msg->msg_controllen = sock->recvcmsgbuflen; + } +#endif /* USE_CMSG */ +#else /* ISC_NET_BSD44MSGHDR */ + msg->msg_accrights = NULL; + msg->msg_accrightslen = 0; +#endif /* ISC_NET_BSD44MSGHDR */ + + if (read_countp != NULL) + *read_countp = read_count; +} + +static void +set_dev_address(isc_sockaddr_t *address, isc_socket_t *sock, + isc_socketevent_t *dev) +{ + if (sock->type == isc_sockettype_udp) { + if (address != NULL) + dev->address = *address; + else + dev->address = sock->peer_address; + } else if (sock->type == isc_sockettype_tcp) { + INSIST(address == NULL); + dev->address = sock->peer_address; + } +} + +static void +destroy_socketevent(isc_event_t *event) { + isc_socketevent_t *ev = (isc_socketevent_t *)event; + + INSIST(ISC_LIST_EMPTY(ev->bufferlist)); + + (ev->destroy)(event); +} + +static isc_socketevent_t * +allocate_socketevent(isc_socket_t *sock, isc_eventtype_t eventtype, + isc_taskaction_t action, const void *arg) +{ + isc_socketevent_t *ev; + + ev = (isc_socketevent_t *)isc_event_allocate(sock->manager->mctx, + sock, eventtype, + action, arg, + sizeof(*ev)); + + if (ev == NULL) + return (NULL); + + ev->result = ISC_R_UNEXPECTED; + ISC_LINK_INIT(ev, ev_link); + ISC_LIST_INIT(ev->bufferlist); + ev->region.base = NULL; + ev->n = 0; + ev->offset = 0; + ev->attributes = 0; + ev->destroy = ev->ev_destroy; + ev->ev_destroy = destroy_socketevent; + + return (ev); +} + +#if defined(ISC_SOCKET_DEBUG) +static void +dump_msg(struct msghdr *msg) { + unsigned int i; + + printf("MSGHDR %p\n", msg); + printf("\tname %p, namelen %ld\n", msg->msg_name, + (long) msg->msg_namelen); + printf("\tiov %p, iovlen %ld\n", msg->msg_iov, + (long) msg->msg_iovlen); + for (i = 0; i < (unsigned int)msg->msg_iovlen; i++) + printf("\t\t%d\tbase %p, len %ld\n", i, + msg->msg_iov[i].iov_base, + (long) msg->msg_iov[i].iov_len); +#ifdef ISC_NET_BSD44MSGHDR + printf("\tcontrol %p, controllen %ld\n", msg->msg_control, + (long) msg->msg_controllen); +#endif +} +#endif + +#define DOIO_SUCCESS 0 /* i/o ok, event sent */ +#define DOIO_SOFT 1 /* i/o ok, soft error, no event sent */ +#define DOIO_HARD 2 /* i/o error, event sent */ +#define DOIO_EOF 3 /* EOF, no event sent */ + +static int +doio_recv(isc_socket_t *sock, isc_socketevent_t *dev) { + int cc; + struct iovec iov[MAXSCATTERGATHER_RECV]; + size_t read_count; + size_t actual_count; + struct msghdr msghdr; + isc_buffer_t *buffer; + int recv_errno; + char strbuf[ISC_STRERRORSIZE]; + + build_msghdr_recv(sock, dev, &msghdr, iov, &read_count); + +#if defined(ISC_SOCKET_DEBUG) + dump_msg(&msghdr); +#endif + + cc = recvmsg(sock->fd, &msghdr, 0); + recv_errno = errno; + +#if defined(ISC_SOCKET_DEBUG) + dump_msg(&msghdr); +#endif + + if (cc < 0) { + if (SOFT_ERROR(recv_errno)) + return (DOIO_SOFT); + + if (isc_log_wouldlog(isc_lctx, IOEVENT_LEVEL)) { + isc__strerror(recv_errno, strbuf, sizeof(strbuf)); + socket_log(sock, NULL, IOEVENT, + isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_DOIORECV, + "doio_recv: recvmsg(%d) %d bytes, err %d/%s", + sock->fd, cc, recv_errno, strbuf); + } + +#define SOFT_OR_HARD(_system, _isc) \ + if (recv_errno == _system) { \ + if (sock->connected) { \ + dev->result = _isc; \ + inc_stats(sock->manager->stats, \ + sock->statsindex[STATID_RECVFAIL]); \ + return (DOIO_HARD); \ + } \ + return (DOIO_SOFT); \ + } +#define ALWAYS_HARD(_system, _isc) \ + if (recv_errno == _system) { \ + dev->result = _isc; \ + inc_stats(sock->manager->stats, \ + sock->statsindex[STATID_RECVFAIL]); \ + return (DOIO_HARD); \ + } + + SOFT_OR_HARD(ECONNREFUSED, ISC_R_CONNREFUSED); + SOFT_OR_HARD(ENETUNREACH, ISC_R_NETUNREACH); + SOFT_OR_HARD(EHOSTUNREACH, ISC_R_HOSTUNREACH); + SOFT_OR_HARD(EHOSTDOWN, ISC_R_HOSTDOWN); + /* HPUX 11.11 can return EADDRNOTAVAIL. */ + SOFT_OR_HARD(EADDRNOTAVAIL, ISC_R_ADDRNOTAVAIL); + ALWAYS_HARD(ENOBUFS, ISC_R_NORESOURCES); + /* + * HPUX returns EPROTO and EINVAL on receiving some ICMP/ICMPv6 + * errors. + */ +#ifdef EPROTO + SOFT_OR_HARD(EPROTO, ISC_R_HOSTUNREACH); +#endif + SOFT_OR_HARD(EINVAL, ISC_R_HOSTUNREACH); + +#undef SOFT_OR_HARD +#undef ALWAYS_HARD + + dev->result = isc__errno2result(recv_errno); + inc_stats(sock->manager->stats, + sock->statsindex[STATID_RECVFAIL]); + return (DOIO_HARD); + } + + /* + * On TCP, zero length reads indicate EOF, while on + * UDP, zero length reads are perfectly valid, although + * strange. + */ + if ((sock->type == isc_sockettype_tcp) && (cc == 0)) + return (DOIO_EOF); + + if (sock->type == isc_sockettype_udp) { + dev->address.length = msghdr.msg_namelen; + if (isc_sockaddr_getport(&dev->address) == 0) { + if (isc_log_wouldlog(isc_lctx, IOEVENT_LEVEL)) { + socket_log(sock, &dev->address, IOEVENT, + isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_ZEROPORT, + "dropping source port zero packet"); + } + return (DOIO_SOFT); + } + } + + socket_log(sock, &dev->address, IOEVENT, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_PKTRECV, + "packet received correctly"); + + /* + * Overflow bit detection. If we received MORE bytes than we should, + * this indicates an overflow situation. Set the flag in the + * dev entry and adjust how much we read by one. + */ +#ifdef ISC_NET_RECVOVERFLOW + if ((sock->type == isc_sockettype_udp) && ((size_t)cc > read_count)) { + dev->attributes |= ISC_SOCKEVENTATTR_TRUNC; + cc--; + } +#endif + + /* + * If there are control messages attached, run through them and pull + * out the interesting bits. + */ + if (sock->type == isc_sockettype_udp) + process_cmsg(sock, &msghdr, dev); + + /* + * update the buffers (if any) and the i/o count + */ + dev->n += cc; + actual_count = cc; + buffer = ISC_LIST_HEAD(dev->bufferlist); + while (buffer != NULL && actual_count > 0U) { + REQUIRE(ISC_BUFFER_VALID(buffer)); + if (isc_buffer_availablelength(buffer) <= actual_count) { + actual_count -= isc_buffer_availablelength(buffer); + isc_buffer_add(buffer, + isc_buffer_availablelength(buffer)); + } else { + isc_buffer_add(buffer, actual_count); + actual_count = 0; + break; + } + buffer = ISC_LIST_NEXT(buffer, link); + if (buffer == NULL) { + INSIST(actual_count == 0U); + } + } + + /* + * If we read less than we expected, update counters, + * and let the upper layer poke the descriptor. + */ + if (((size_t)cc != read_count) && (dev->n < dev->minimum)) + return (DOIO_SOFT); + + /* + * Full reads are posted, or partials if partials are ok. + */ + dev->result = ISC_R_SUCCESS; + return (DOIO_SUCCESS); +} + +/* + * Returns: + * DOIO_SUCCESS The operation succeeded. dev->result contains + * ISC_R_SUCCESS. + * + * DOIO_HARD A hard or unexpected I/O error was encountered. + * dev->result contains the appropriate error. + * + * DOIO_SOFT A soft I/O error was encountered. No senddone + * event was sent. The operation should be retried. + * + * No other return values are possible. + */ +static int +doio_send(isc_socket_t *sock, isc_socketevent_t *dev) { + int cc; + struct iovec iov[MAXSCATTERGATHER_SEND]; + size_t write_count; + struct msghdr msghdr; + char addrbuf[ISC_SOCKADDR_FORMATSIZE]; + int attempts = 0; + int send_errno; + char strbuf[ISC_STRERRORSIZE]; + + build_msghdr_send(sock, dev, &msghdr, iov, &write_count); + + resend: + cc = sendmsg(sock->fd, &msghdr, 0); + send_errno = errno; + + /* + * Check for error or block condition. + */ + if (cc < 0) { + if (send_errno == EINTR && ++attempts < NRETRIES) + goto resend; + + if (SOFT_ERROR(send_errno)) + return (DOIO_SOFT); + +#define SOFT_OR_HARD(_system, _isc) \ + if (send_errno == _system) { \ + if (sock->connected) { \ + dev->result = _isc; \ + inc_stats(sock->manager->stats, \ + sock->statsindex[STATID_SENDFAIL]); \ + return (DOIO_HARD); \ + } \ + return (DOIO_SOFT); \ + } +#define ALWAYS_HARD(_system, _isc) \ + if (send_errno == _system) { \ + dev->result = _isc; \ + inc_stats(sock->manager->stats, \ + sock->statsindex[STATID_SENDFAIL]); \ + return (DOIO_HARD); \ + } + + SOFT_OR_HARD(ECONNREFUSED, ISC_R_CONNREFUSED); + ALWAYS_HARD(EACCES, ISC_R_NOPERM); + ALWAYS_HARD(EAFNOSUPPORT, ISC_R_ADDRNOTAVAIL); + ALWAYS_HARD(EADDRNOTAVAIL, ISC_R_ADDRNOTAVAIL); + ALWAYS_HARD(EHOSTUNREACH, ISC_R_HOSTUNREACH); +#ifdef EHOSTDOWN + ALWAYS_HARD(EHOSTDOWN, ISC_R_HOSTUNREACH); +#endif + ALWAYS_HARD(ENETUNREACH, ISC_R_NETUNREACH); + ALWAYS_HARD(ENOBUFS, ISC_R_NORESOURCES); + ALWAYS_HARD(EPERM, ISC_R_HOSTUNREACH); + ALWAYS_HARD(EPIPE, ISC_R_NOTCONNECTED); + ALWAYS_HARD(ECONNRESET, ISC_R_CONNECTIONRESET); + +#undef SOFT_OR_HARD +#undef ALWAYS_HARD + + /* + * The other error types depend on whether or not the + * socket is UDP or TCP. If it is UDP, some errors + * that we expect to be fatal under TCP are merely + * annoying, and are really soft errors. + * + * However, these soft errors are still returned as + * a status. + */ + isc_sockaddr_format(&dev->address, addrbuf, sizeof(addrbuf)); + isc__strerror(send_errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, "internal_send: %s: %s", + addrbuf, strbuf); + dev->result = isc__errno2result(send_errno); + inc_stats(sock->manager->stats, + sock->statsindex[STATID_SENDFAIL]); + return (DOIO_HARD); + } + + if (cc == 0) { + inc_stats(sock->manager->stats, + sock->statsindex[STATID_SENDFAIL]); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "doio_send: send() %s 0", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_RETURNED, "returned")); + } + + /* + * If we write less than we expected, update counters, poke. + */ + dev->n += cc; + if ((size_t)cc != write_count) + return (DOIO_SOFT); + + /* + * Exactly what we wanted to write. We're done with this + * entry. Post its completion event. + */ + dev->result = ISC_R_SUCCESS; + return (DOIO_SUCCESS); +} + +/* + * Kill. + * + * Caller must ensure that the socket is not locked and no external + * references exist. + */ +static void +closesocket(isc_socketmgr_t *manager, isc_socket_t *sock, int fd) { + isc_sockettype_t type = sock->type; + int lockid = FDLOCK_ID(fd); + + /* + * No one has this socket open, so the watcher doesn't have to be + * poked, and the socket doesn't have to be locked. + */ + LOCK(&manager->fdlock[lockid]); + manager->fds[fd] = NULL; + if (type == isc_sockettype_fdwatch) + manager->fdstate[fd] = CLOSED; + else + manager->fdstate[fd] = CLOSE_PENDING; + UNLOCK(&manager->fdlock[lockid]); + if (type == isc_sockettype_fdwatch) { + /* + * The caller may close the socket once this function returns, + * and `fd' may be reassigned for a new socket. So we do + * unwatch_fd() here, rather than defer it via select_poke(). + * Note: this may complicate data protection among threads and + * may reduce performance due to additional locks. One way to + * solve this would be to dup() the watched descriptor, but we + * take a simpler approach at this moment. + */ + (void)unwatch_fd(manager, fd, SELECT_POKE_READ); + (void)unwatch_fd(manager, fd, SELECT_POKE_WRITE); + } else + select_poke(manager, fd, SELECT_POKE_CLOSE); + + inc_stats(manager->stats, sock->statsindex[STATID_CLOSE]); + + /* + * update manager->maxfd here (XXX: this should be implemented more + * efficiently) + */ +#ifdef USE_SELECT + LOCK(&manager->lock); + if (manager->maxfd == fd) { + int i; + + manager->maxfd = 0; + for (i = fd - 1; i >= 0; i--) { + lockid = FDLOCK_ID(i); + + LOCK(&manager->fdlock[lockid]); + if (manager->fdstate[i] == MANAGED) { + manager->maxfd = i; + UNLOCK(&manager->fdlock[lockid]); + break; + } + UNLOCK(&manager->fdlock[lockid]); + } +#ifdef ISC_PLATFORM_USETHREADS + if (manager->maxfd < manager->pipe_fds[0]) + manager->maxfd = manager->pipe_fds[0]; +#endif + } + UNLOCK(&manager->lock); +#endif /* USE_SELECT */ +} + +static void +destroy(isc_socket_t **sockp) { + int fd; + isc_socket_t *sock = *sockp; + isc_socketmgr_t *manager = sock->manager; + + socket_log(sock, NULL, CREATION, isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_DESTROYING, "destroying"); + + INSIST(ISC_LIST_EMPTY(sock->accept_list)); + INSIST(ISC_LIST_EMPTY(sock->recv_list)); + INSIST(ISC_LIST_EMPTY(sock->send_list)); + INSIST(sock->connect_ev == NULL); + REQUIRE(sock->fd == -1 || sock->fd < (int)manager->maxsocks); + + if (sock->fd >= 0) { + fd = sock->fd; + sock->fd = -1; + closesocket(manager, sock, fd); + } + + LOCK(&manager->lock); + + ISC_LIST_UNLINK(manager->socklist, sock, link); + +#ifdef ISC_PLATFORM_USETHREADS + if (ISC_LIST_EMPTY(manager->socklist)) + SIGNAL(&manager->shutdown_ok); +#endif /* ISC_PLATFORM_USETHREADS */ + + UNLOCK(&manager->lock); + + free_socket(sockp); +} + +static isc_result_t +allocate_socket(isc_socketmgr_t *manager, isc_sockettype_t type, + isc_socket_t **socketp) +{ + isc_socket_t *sock; + isc_result_t result; + ISC_SOCKADDR_LEN_T cmsgbuflen; + + sock = isc_mem_get(manager->mctx, sizeof(*sock)); + + if (sock == NULL) + return (ISC_R_NOMEMORY); + + result = ISC_R_UNEXPECTED; + + sock->magic = 0; + sock->references = 0; + + sock->manager = manager; + sock->type = type; + sock->fd = -1; + sock->statsindex = NULL; + + ISC_LINK_INIT(sock, link); + + sock->recvcmsgbuf = NULL; + sock->sendcmsgbuf = NULL; + + /* + * set up cmsg buffers + */ + cmsgbuflen = 0; +#if defined(USE_CMSG) && defined(ISC_PLATFORM_HAVEIN6PKTINFO) + cmsgbuflen = cmsg_space(sizeof(struct in6_pktinfo)); +#endif +#if defined(USE_CMSG) && defined(SO_TIMESTAMP) + cmsgbuflen += cmsg_space(sizeof(struct timeval)); +#endif + sock->recvcmsgbuflen = cmsgbuflen; + if (sock->recvcmsgbuflen != 0U) { + sock->recvcmsgbuf = isc_mem_get(manager->mctx, cmsgbuflen); + if (sock->recvcmsgbuf == NULL) + goto error; + } + + cmsgbuflen = 0; +#if defined(USE_CMSG) && defined(ISC_PLATFORM_HAVEIN6PKTINFO) + cmsgbuflen = cmsg_space(sizeof(struct in6_pktinfo)); +#endif + sock->sendcmsgbuflen = cmsgbuflen; + if (sock->sendcmsgbuflen != 0U) { + sock->sendcmsgbuf = isc_mem_get(manager->mctx, cmsgbuflen); + if (sock->sendcmsgbuf == NULL) + goto error; + } + + memset(sock->name, 0, sizeof(sock->name)); + sock->tag = NULL; + + /* + * set up list of readers and writers to be initially empty + */ + ISC_LIST_INIT(sock->recv_list); + ISC_LIST_INIT(sock->send_list); + ISC_LIST_INIT(sock->accept_list); + sock->connect_ev = NULL; + sock->pending_recv = 0; + sock->pending_send = 0; + sock->pending_accept = 0; + sock->listener = 0; + sock->connected = 0; + sock->connecting = 0; + sock->bound = 0; + + /* + * initialize the lock + */ + result = isc_mutex_init(&sock->lock); + if (result != ISC_R_SUCCESS) { + sock->magic = 0; + goto error; + } + + /* + * Initialize readable and writable events + */ + ISC_EVENT_INIT(&sock->readable_ev, sizeof(intev_t), + ISC_EVENTATTR_NOPURGE, NULL, ISC_SOCKEVENT_INTR, + NULL, sock, sock, NULL, NULL); + ISC_EVENT_INIT(&sock->writable_ev, sizeof(intev_t), + ISC_EVENTATTR_NOPURGE, NULL, ISC_SOCKEVENT_INTW, + NULL, sock, sock, NULL, NULL); + + sock->magic = SOCKET_MAGIC; + *socketp = sock; + + return (ISC_R_SUCCESS); + + error: + if (sock->recvcmsgbuf != NULL) + isc_mem_put(manager->mctx, sock->recvcmsgbuf, + sock->recvcmsgbuflen); + if (sock->sendcmsgbuf != NULL) + isc_mem_put(manager->mctx, sock->sendcmsgbuf, + sock->sendcmsgbuflen); + isc_mem_put(manager->mctx, sock, sizeof(*sock)); + + return (result); +} + +/* + * This event requires that the various lists be empty, that the reference + * count be 1, and that the magic number is valid. The other socket bits, + * like the lock, must be initialized as well. The fd associated must be + * marked as closed, by setting it to -1 on close, or this routine will + * also close the socket. + */ +static void +free_socket(isc_socket_t **socketp) { + isc_socket_t *sock = *socketp; + + INSIST(sock->references == 0); + INSIST(VALID_SOCKET(sock)); + INSIST(!sock->connecting); + INSIST(!sock->pending_recv); + INSIST(!sock->pending_send); + INSIST(!sock->pending_accept); + INSIST(ISC_LIST_EMPTY(sock->recv_list)); + INSIST(ISC_LIST_EMPTY(sock->send_list)); + INSIST(ISC_LIST_EMPTY(sock->accept_list)); + INSIST(!ISC_LINK_LINKED(sock, link)); + + if (sock->recvcmsgbuf != NULL) + isc_mem_put(sock->manager->mctx, sock->recvcmsgbuf, + sock->recvcmsgbuflen); + if (sock->sendcmsgbuf != NULL) + isc_mem_put(sock->manager->mctx, sock->sendcmsgbuf, + sock->sendcmsgbuflen); + + sock->magic = 0; + + DESTROYLOCK(&sock->lock); + + isc_mem_put(sock->manager->mctx, sock, sizeof(*sock)); + + *socketp = NULL; +} + +#ifdef SO_BSDCOMPAT +/* + * This really should not be necessary to do. Having to workout + * which kernel version we are on at run time so that we don't cause + * the kernel to issue a warning about us using a deprecated socket option. + * Such warnings should *never* be on by default in production kernels. + * + * We can't do this a build time because executables are moved between + * machines and hence kernels. + * + * We can't just not set SO_BSDCOMAT because some kernels require it. + */ + +static isc_once_t bsdcompat_once = ISC_ONCE_INIT; +isc_boolean_t bsdcompat = ISC_TRUE; + +static void +clear_bsdcompat(void) { +#ifdef __linux__ + struct utsname buf; + char *endp; + long int major; + long int minor; + + uname(&buf); /* Can only fail if buf is bad in Linux. */ + + /* Paranoia in parsing can be increased, but we trust uname(). */ + major = strtol(buf.release, &endp, 10); + if (*endp == '.') { + minor = strtol(endp+1, &endp, 10); + if ((major > 2) || ((major == 2) && (minor >= 4))) { + bsdcompat = ISC_FALSE; + } + } +#endif /* __linux __ */ +} +#endif + +static isc_result_t +opensocket(isc_socketmgr_t *manager, isc_socket_t *sock) { + char strbuf[ISC_STRERRORSIZE]; + const char *err = "socket"; + int tries = 0; +#if defined(USE_CMSG) || defined(SO_BSDCOMPAT) + int on = 1; +#endif +#if defined(SO_RCVBUF) + ISC_SOCKADDR_LEN_T optlen; + int size; +#endif + + again: + switch (sock->type) { + case isc_sockettype_udp: + sock->fd = socket(sock->pf, SOCK_DGRAM, IPPROTO_UDP); + break; + case isc_sockettype_tcp: + sock->fd = socket(sock->pf, SOCK_STREAM, IPPROTO_TCP); + break; + case isc_sockettype_unix: + sock->fd = socket(sock->pf, SOCK_STREAM, 0); + break; + case isc_sockettype_fdwatch: + /* + * We should not be called for isc_sockettype_fdwatch sockets. + */ + INSIST(0); + break; + } + if (sock->fd == -1 && errno == EINTR && tries++ < 42) + goto again; + +#ifdef F_DUPFD + /* + * Leave a space for stdio and TCP to work in. + */ + if (manager->reserved != 0 && sock->type == isc_sockettype_udp && + sock->fd >= 0 && sock->fd < manager->reserved) { + int new, tmp; + new = fcntl(sock->fd, F_DUPFD, manager->reserved); + tmp = errno; + (void)close(sock->fd); + errno = tmp; + sock->fd = new; + err = "isc_socket_create: fcntl/reserved"; + } else if (sock->fd >= 0 && sock->fd < 20) { + int new, tmp; + new = fcntl(sock->fd, F_DUPFD, 20); + tmp = errno; + (void)close(sock->fd); + errno = tmp; + sock->fd = new; + err = "isc_socket_create: fcntl"; + } +#endif + + if (sock->fd >= (int)manager->maxsocks) { + (void)close(sock->fd); + isc_log_iwrite(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_TOOMANYFDS, + "socket: file descriptor exceeds limit (%d/%u)", + sock->fd, manager->maxsocks); + return (ISC_R_NORESOURCES); + } + + if (sock->fd < 0) { + switch (errno) { + case EMFILE: + case ENFILE: + isc__strerror(errno, strbuf, sizeof(strbuf)); + isc_log_iwrite(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_TOOMANYFDS, + "%s: %s", err, strbuf); + /* fallthrough */ + case ENOBUFS: + return (ISC_R_NORESOURCES); + + case EPROTONOSUPPORT: + case EPFNOSUPPORT: + case EAFNOSUPPORT: + /* + * Linux 2.2 (and maybe others) return EINVAL instead of + * EAFNOSUPPORT. + */ + case EINVAL: + return (ISC_R_FAMILYNOSUPPORT); + + default: + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "%s() %s: %s", err, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + return (ISC_R_UNEXPECTED); + } + } + + if (make_nonblock(sock->fd) != ISC_R_SUCCESS) { + (void)close(sock->fd); + return (ISC_R_UNEXPECTED); + } + +#ifdef SO_BSDCOMPAT + RUNTIME_CHECK(isc_once_do(&bsdcompat_once, + clear_bsdcompat) == ISC_R_SUCCESS); + if (sock->type != isc_sockettype_unix && bsdcompat && + setsockopt(sock->fd, SOL_SOCKET, SO_BSDCOMPAT, + (void *)&on, sizeof(on)) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "setsockopt(%d, SO_BSDCOMPAT) %s: %s", + sock->fd, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed"), + strbuf); + /* Press on... */ + } +#endif + +#ifdef SO_NOSIGPIPE + if (setsockopt(sock->fd, SOL_SOCKET, SO_NOSIGPIPE, + (void *)&on, sizeof(on)) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "setsockopt(%d, SO_NOSIGPIPE) %s: %s", + sock->fd, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed"), + strbuf); + /* Press on... */ + } +#endif + +#if defined(USE_CMSG) || defined(SO_RCVBUF) + if (sock->type == isc_sockettype_udp) { + +#if defined(USE_CMSG) +#if defined(SO_TIMESTAMP) + if (setsockopt(sock->fd, SOL_SOCKET, SO_TIMESTAMP, + (void *)&on, sizeof(on)) < 0 + && errno != ENOPROTOOPT) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "setsockopt(%d, SO_TIMESTAMP) %s: %s", + sock->fd, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + /* Press on... */ + } +#endif /* SO_TIMESTAMP */ + +#if defined(ISC_PLATFORM_HAVEIPV6) + if (sock->pf == AF_INET6 && sock->recvcmsgbuflen == 0U) { + /* + * Warn explicitly because this anomaly can be hidden + * in usual operation (and unexpectedly appear later). + */ + UNEXPECTED_ERROR(__FILE__, __LINE__, + "No buffer available to receive " + "IPv6 destination"); + } +#ifdef ISC_PLATFORM_HAVEIN6PKTINFO +#ifdef IPV6_RECVPKTINFO + /* RFC 3542 */ + if ((sock->pf == AF_INET6) + && (setsockopt(sock->fd, IPPROTO_IPV6, IPV6_RECVPKTINFO, + (void *)&on, sizeof(on)) < 0)) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "setsockopt(%d, IPV6_RECVPKTINFO) " + "%s: %s", sock->fd, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + } +#else + /* RFC 2292 */ + if ((sock->pf == AF_INET6) + && (setsockopt(sock->fd, IPPROTO_IPV6, IPV6_PKTINFO, + (void *)&on, sizeof(on)) < 0)) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "setsockopt(%d, IPV6_PKTINFO) %s: %s", + sock->fd, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + } +#endif /* IPV6_RECVPKTINFO */ +#endif /* ISC_PLATFORM_HAVEIN6PKTINFO */ +#ifdef IPV6_USE_MIN_MTU /* RFC 3542, not too common yet*/ + /* use minimum MTU */ + if (sock->pf == AF_INET6) { + (void)setsockopt(sock->fd, IPPROTO_IPV6, + IPV6_USE_MIN_MTU, + (void *)&on, sizeof(on)); + } +#endif +#endif /* ISC_PLATFORM_HAVEIPV6 */ +#endif /* defined(USE_CMSG) */ + +#if defined(IP_MTU_DISCOVER) && defined(IP_PMTUDISC_DONT) + /* + * Turn off Path MTU discovery on IPv4/UDP sockets. + */ + if (sock->pf == AF_INET) { + int action = IP_PMTUDISC_DONT; + (void)setsockopt(sock->fd, IPPROTO_IP, IP_MTU_DISCOVER, + &action, sizeof(action)); + } +#endif +#if defined(IP_DONTFRAG) + /* + * Turn off Path MTU discovery on IPv4/UDP sockets. + */ + if (sock->pf == AF_INET) { + int off = 0; + (void)setsockopt(sock->fd, IPPROTO_IP, IP_DONTFRAG, + &off, sizeof(off)); + } +#endif + +#if defined(SO_RCVBUF) + optlen = sizeof(size); + if (getsockopt(sock->fd, SOL_SOCKET, SO_RCVBUF, + (void *)&size, &optlen) >= 0 && + size < RCVBUFSIZE) { + size = RCVBUFSIZE; + if (setsockopt(sock->fd, SOL_SOCKET, SO_RCVBUF, + (void *)&size, sizeof(size)) == -1) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "setsockopt(%d, SO_RCVBUF, %d) %s: %s", + sock->fd, size, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + } + } +#endif + } +#endif /* defined(USE_CMSG) || defined(SO_RCVBUF) */ + + inc_stats(manager->stats, sock->statsindex[STATID_OPEN]); + + return (ISC_R_SUCCESS); +} + +/*% + * Create a new 'type' socket managed by 'manager'. Events + * will be posted to 'task' and when dispatched 'action' will be + * called with 'arg' as the arg value. The new socket is returned + * in 'socketp'. + */ +isc_result_t +isc_socket_create(isc_socketmgr_t *manager, int pf, isc_sockettype_t type, + isc_socket_t **socketp) +{ + isc_socket_t *sock = NULL; + isc_result_t result; + int lockid; + + REQUIRE(VALID_MANAGER(manager)); + REQUIRE(socketp != NULL && *socketp == NULL); + REQUIRE(type != isc_sockettype_fdwatch); + + result = allocate_socket(manager, type, &sock); + if (result != ISC_R_SUCCESS) + return (result); + + switch (sock->type) { + case isc_sockettype_udp: + sock->statsindex = + (pf == AF_INET) ? upd4statsindex : upd6statsindex; + break; + case isc_sockettype_tcp: + sock->statsindex = + (pf == AF_INET) ? tcp4statsindex : tcp6statsindex; + break; + case isc_sockettype_unix: + sock->statsindex = unixstatsindex; + break; + default: + INSIST(0); + } + + sock->pf = pf; + result = opensocket(manager, sock); + if (result != ISC_R_SUCCESS) { + inc_stats(manager->stats, sock->statsindex[STATID_OPENFAIL]); + free_socket(&sock); + return (result); + } + + sock->references = 1; + *socketp = sock; + + /* + * Note we don't have to lock the socket like we normally would because + * there are no external references to it yet. + */ + + lockid = FDLOCK_ID(sock->fd); + LOCK(&manager->fdlock[lockid]); + manager->fds[sock->fd] = sock; + manager->fdstate[sock->fd] = MANAGED; +#ifdef USE_DEVPOLL + INSIST(sock->manager->fdpollinfo[sock->fd].want_read == 0 && + sock->manager->fdpollinfo[sock->fd].want_write == 0); +#endif + UNLOCK(&manager->fdlock[lockid]); + + LOCK(&manager->lock); + ISC_LIST_APPEND(manager->socklist, sock, link); +#ifdef USE_SELECT + if (manager->maxfd < sock->fd) + manager->maxfd = sock->fd; +#endif + UNLOCK(&manager->lock); + + socket_log(sock, NULL, CREATION, isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_CREATED, "created"); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_socket_open(isc_socket_t *sock) { + isc_result_t result; + + REQUIRE(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + REQUIRE(sock->references == 1); + REQUIRE(sock->type != isc_sockettype_fdwatch); + UNLOCK(&sock->lock); + /* + * We don't need to retain the lock hereafter, since no one else has + * this socket. + */ + REQUIRE(sock->fd == -1); + + result = opensocket(sock->manager, sock); + if (result != ISC_R_SUCCESS) + sock->fd = -1; + + if (result == ISC_R_SUCCESS) { + int lockid = FDLOCK_ID(sock->fd); + + LOCK(&sock->manager->fdlock[lockid]); + sock->manager->fds[sock->fd] = sock; + sock->manager->fdstate[sock->fd] = MANAGED; +#ifdef USE_DEVPOLL + INSIST(sock->manager->fdpollinfo[sock->fd].want_read == 0 && + sock->manager->fdpollinfo[sock->fd].want_write == 0); +#endif + UNLOCK(&sock->manager->fdlock[lockid]); + +#ifdef USE_SELECT + LOCK(&sock->manager->lock); + if (sock->manager->maxfd < sock->fd) + sock->manager->maxfd = sock->fd; + UNLOCK(&sock->manager->lock); +#endif + } + + return (result); +} + +/* + * Create a new 'type' socket managed by 'manager'. Events + * will be posted to 'task' and when dispatched 'action' will be + * called with 'arg' as the arg value. The new socket is returned + * in 'socketp'. + */ +isc_result_t +isc_socket_fdwatchcreate(isc_socketmgr_t *manager, int fd, int flags, + isc_sockfdwatch_t callback, void *cbarg, + isc_task_t *task, isc_socket_t **socketp) +{ + isc_socket_t *sock = NULL; + isc_result_t result; + int lockid; + + REQUIRE(VALID_MANAGER(manager)); + REQUIRE(socketp != NULL && *socketp == NULL); + + result = allocate_socket(manager, isc_sockettype_fdwatch, &sock); + if (result != ISC_R_SUCCESS) + return (result); + + sock->fd = fd; + sock->fdwatcharg = cbarg; + sock->fdwatchcb = callback; + sock->fdwatchflags = flags; + sock->fdwatchtask = task; + sock->statsindex = fdwatchstatsindex; + + sock->references = 1; + *socketp = sock; + + /* + * Note we don't have to lock the socket like we normally would because + * there are no external references to it yet. + */ + + lockid = FDLOCK_ID(sock->fd); + LOCK(&manager->fdlock[lockid]); + manager->fds[sock->fd] = sock; + manager->fdstate[sock->fd] = MANAGED; + UNLOCK(&manager->fdlock[lockid]); + + LOCK(&manager->lock); + ISC_LIST_APPEND(manager->socklist, sock, link); +#ifdef USE_SELECT + if (manager->maxfd < sock->fd) + manager->maxfd = sock->fd; +#endif + UNLOCK(&manager->lock); + + if (flags & ISC_SOCKFDWATCH_READ) + select_poke(sock->manager, sock->fd, SELECT_POKE_READ); + if (flags & ISC_SOCKFDWATCH_WRITE) + select_poke(sock->manager, sock->fd, SELECT_POKE_WRITE); + + socket_log(sock, NULL, CREATION, isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_CREATED, "fdwatch-created"); + + return (ISC_R_SUCCESS); +} + +/* + * Attach to a socket. Caller must explicitly detach when it is done. + */ +void +isc_socket_attach(isc_socket_t *sock, isc_socket_t **socketp) { + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(socketp != NULL && *socketp == NULL); + + LOCK(&sock->lock); + sock->references++; + UNLOCK(&sock->lock); + + *socketp = sock; +} + +/* + * Dereference a socket. If this is the last reference to it, clean things + * up by destroying the socket. + */ +void +isc_socket_detach(isc_socket_t **socketp) { + isc_socket_t *sock; + isc_boolean_t kill_socket = ISC_FALSE; + + REQUIRE(socketp != NULL); + sock = *socketp; + REQUIRE(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + REQUIRE(sock->references > 0); + sock->references--; + if (sock->references == 0) + kill_socket = ISC_TRUE; + UNLOCK(&sock->lock); + + if (kill_socket) + destroy(&sock); + + *socketp = NULL; +} + +isc_result_t +isc_socket_close(isc_socket_t *sock) { + int fd; + isc_socketmgr_t *manager; + isc_sockettype_t type; + + REQUIRE(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + + REQUIRE(sock->references == 1); + REQUIRE(sock->type != isc_sockettype_fdwatch); + REQUIRE(sock->fd >= 0 && sock->fd < (int)sock->manager->maxsocks); + + INSIST(!sock->connecting); + INSIST(!sock->pending_recv); + INSIST(!sock->pending_send); + INSIST(!sock->pending_accept); + INSIST(ISC_LIST_EMPTY(sock->recv_list)); + INSIST(ISC_LIST_EMPTY(sock->send_list)); + INSIST(ISC_LIST_EMPTY(sock->accept_list)); + INSIST(sock->connect_ev == NULL); + + manager = sock->manager; + type = sock->type; + fd = sock->fd; + sock->fd = -1; + memset(sock->name, 0, sizeof(sock->name)); + sock->tag = NULL; + sock->listener = 0; + sock->connected = 0; + sock->connecting = 0; + sock->bound = 0; + isc_sockaddr_any(&sock->peer_address); + + UNLOCK(&sock->lock); + + closesocket(manager, sock, fd); + + return (ISC_R_SUCCESS); +} + +/* + * I/O is possible on a given socket. Schedule an event to this task that + * will call an internal function to do the I/O. This will charge the + * task with the I/O operation and let our select loop handler get back + * to doing something real as fast as possible. + * + * The socket and manager must be locked before calling this function. + */ +static void +dispatch_recv(isc_socket_t *sock) { + intev_t *iev; + isc_socketevent_t *ev; + isc_task_t *sender; + + INSIST(!sock->pending_recv); + + if (sock->type != isc_sockettype_fdwatch) { + ev = ISC_LIST_HEAD(sock->recv_list); + if (ev == NULL) + return; + socket_log(sock, NULL, EVENT, NULL, 0, 0, + "dispatch_recv: event %p -> task %p", + ev, ev->ev_sender); + sender = ev->ev_sender; + } else { + sender = sock->fdwatchtask; + } + + sock->pending_recv = 1; + iev = &sock->readable_ev; + + sock->references++; + iev->ev_sender = sock; + if (sock->type == isc_sockettype_fdwatch) + iev->ev_action = internal_fdwatch_read; + else + iev->ev_action = internal_recv; + iev->ev_arg = sock; + + isc_task_send(sender, (isc_event_t **)&iev); +} + +static void +dispatch_send(isc_socket_t *sock) { + intev_t *iev; + isc_socketevent_t *ev; + isc_task_t *sender; + + INSIST(!sock->pending_send); + + if (sock->type != isc_sockettype_fdwatch) { + ev = ISC_LIST_HEAD(sock->send_list); + if (ev == NULL) + return; + socket_log(sock, NULL, EVENT, NULL, 0, 0, + "dispatch_send: event %p -> task %p", + ev, ev->ev_sender); + sender = ev->ev_sender; + } else { + sender = sock->fdwatchtask; + } + + sock->pending_send = 1; + iev = &sock->writable_ev; + + sock->references++; + iev->ev_sender = sock; + if (sock->type == isc_sockettype_fdwatch) + iev->ev_action = internal_fdwatch_write; + else + iev->ev_action = internal_send; + iev->ev_arg = sock; + + isc_task_send(sender, (isc_event_t **)&iev); +} + +/* + * Dispatch an internal accept event. + */ +static void +dispatch_accept(isc_socket_t *sock) { + intev_t *iev; + isc_socket_newconnev_t *ev; + + INSIST(!sock->pending_accept); + + /* + * Are there any done events left, or were they all canceled + * before the manager got the socket lock? + */ + ev = ISC_LIST_HEAD(sock->accept_list); + if (ev == NULL) + return; + + sock->pending_accept = 1; + iev = &sock->readable_ev; + + sock->references++; /* keep socket around for this internal event */ + iev->ev_sender = sock; + iev->ev_action = internal_accept; + iev->ev_arg = sock; + + isc_task_send(ev->ev_sender, (isc_event_t **)&iev); +} + +static void +dispatch_connect(isc_socket_t *sock) { + intev_t *iev; + isc_socket_connev_t *ev; + + iev = &sock->writable_ev; + + ev = sock->connect_ev; + INSIST(ev != NULL); /* XXX */ + + INSIST(sock->connecting); + + sock->references++; /* keep socket around for this internal event */ + iev->ev_sender = sock; + iev->ev_action = internal_connect; + iev->ev_arg = sock; + + isc_task_send(ev->ev_sender, (isc_event_t **)&iev); +} + +/* + * Dequeue an item off the given socket's read queue, set the result code + * in the done event to the one provided, and send it to the task it was + * destined for. + * + * If the event to be sent is on a list, remove it before sending. If + * asked to, send and detach from the socket as well. + * + * Caller must have the socket locked if the event is attached to the socket. + */ +static void +send_recvdone_event(isc_socket_t *sock, isc_socketevent_t **dev) { + isc_task_t *task; + + task = (*dev)->ev_sender; + + (*dev)->ev_sender = sock; + + if (ISC_LINK_LINKED(*dev, ev_link)) + ISC_LIST_DEQUEUE(sock->recv_list, *dev, ev_link); + + if (((*dev)->attributes & ISC_SOCKEVENTATTR_ATTACHED) + == ISC_SOCKEVENTATTR_ATTACHED) + isc_task_sendanddetach(&task, (isc_event_t **)dev); + else + isc_task_send(task, (isc_event_t **)dev); +} + +/* + * See comments for send_recvdone_event() above. + * + * Caller must have the socket locked if the event is attached to the socket. + */ +static void +send_senddone_event(isc_socket_t *sock, isc_socketevent_t **dev) { + isc_task_t *task; + + INSIST(dev != NULL && *dev != NULL); + + task = (*dev)->ev_sender; + (*dev)->ev_sender = sock; + + if (ISC_LINK_LINKED(*dev, ev_link)) + ISC_LIST_DEQUEUE(sock->send_list, *dev, ev_link); + + if (((*dev)->attributes & ISC_SOCKEVENTATTR_ATTACHED) + == ISC_SOCKEVENTATTR_ATTACHED) + isc_task_sendanddetach(&task, (isc_event_t **)dev); + else + isc_task_send(task, (isc_event_t **)dev); +} + +/* + * Call accept() on a socket, to get the new file descriptor. The listen + * socket is used as a prototype to create a new isc_socket_t. The new + * socket has one outstanding reference. The task receiving the event + * will be detached from just after the event is delivered. + * + * On entry to this function, the event delivered is the internal + * readable event, and the first item on the accept_list should be + * the done event we want to send. If the list is empty, this is a no-op, + * so just unlock and return. + */ +static void +internal_accept(isc_task_t *me, isc_event_t *ev) { + isc_socket_t *sock; + isc_socketmgr_t *manager; + isc_socket_newconnev_t *dev; + isc_task_t *task; + ISC_SOCKADDR_LEN_T addrlen; + int fd; + isc_result_t result = ISC_R_SUCCESS; + char strbuf[ISC_STRERRORSIZE]; + const char *err = "accept"; + + UNUSED(me); + + sock = ev->ev_sender; + INSIST(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + socket_log(sock, NULL, TRACE, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_ACCEPTLOCK, + "internal_accept called, locked socket"); + + manager = sock->manager; + INSIST(VALID_MANAGER(manager)); + + INSIST(sock->listener); + INSIST(sock->pending_accept == 1); + sock->pending_accept = 0; + + INSIST(sock->references > 0); + sock->references--; /* the internal event is done with this socket */ + if (sock->references == 0) { + UNLOCK(&sock->lock); + destroy(&sock); + return; + } + + /* + * Get the first item off the accept list. + * If it is empty, unlock the socket and return. + */ + dev = ISC_LIST_HEAD(sock->accept_list); + if (dev == NULL) { + UNLOCK(&sock->lock); + return; + } + + /* + * Try to accept the new connection. If the accept fails with + * EAGAIN or EINTR, simply poke the watcher to watch this socket + * again. Also ignore ECONNRESET, which has been reported to + * be spuriously returned on Linux 2.2.19 although it is not + * a documented error for accept(). ECONNABORTED has been + * reported for Solaris 8. The rest are thrown in not because + * we have seen them but because they are ignored by other + * daemons such as BIND 8 and Apache. + */ + + addrlen = sizeof(dev->newsocket->peer_address.type); + memset(&dev->newsocket->peer_address.type, 0, addrlen); + fd = accept(sock->fd, &dev->newsocket->peer_address.type.sa, + (void *)&addrlen); + +#ifdef F_DUPFD + /* + * Leave a space for stdio to work in. + */ + if (fd >= 0 && fd < 20) { + int new, tmp; + new = fcntl(fd, F_DUPFD, 20); + tmp = errno; + (void)close(fd); + errno = tmp; + fd = new; + err = "accept/fcntl"; + } +#endif + + if (fd < 0) { + if (SOFT_ERROR(errno)) + goto soft_error; + switch (errno) { + case ENFILE: + case EMFILE: + isc_log_iwrite(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_TOOMANYFDS, + "%s: too many open file descriptors", + err); + goto soft_error; + + case ENOBUFS: + case ENOMEM: + case ECONNRESET: + case ECONNABORTED: + case EHOSTUNREACH: + case EHOSTDOWN: + case ENETUNREACH: + case ENETDOWN: + case ECONNREFUSED: +#ifdef EPROTO + case EPROTO: +#endif +#ifdef ENONET + case ENONET: +#endif + goto soft_error; + default: + break; + } + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "internal_accept: %s() %s: %s", err, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + fd = -1; + result = ISC_R_UNEXPECTED; + } else { + if (addrlen == 0U) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "internal_accept(): " + "accept() failed to return " + "remote address"); + + (void)close(fd); + goto soft_error; + } else if (dev->newsocket->peer_address.type.sa.sa_family != + sock->pf) + { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "internal_accept(): " + "accept() returned peer address " + "family %u (expected %u)", + dev->newsocket->peer_address. + type.sa.sa_family, + sock->pf); + (void)close(fd); + goto soft_error; + } else if (fd >= (int)manager->maxsocks) { + isc_log_iwrite(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_TOOMANYFDS, + "accept: " + "file descriptor exceeds limit (%d/%u)", + fd, manager->maxsocks); + (void)close(fd); + goto soft_error; + } + } + + if (fd != -1) { + dev->newsocket->peer_address.length = addrlen; + dev->newsocket->pf = sock->pf; + } + + /* + * Pull off the done event. + */ + ISC_LIST_UNLINK(sock->accept_list, dev, ev_link); + + /* + * Poke watcher if there are more pending accepts. + */ + if (!ISC_LIST_EMPTY(sock->accept_list)) + select_poke(sock->manager, sock->fd, SELECT_POKE_ACCEPT); + + UNLOCK(&sock->lock); + + if (fd != -1 && (make_nonblock(fd) != ISC_R_SUCCESS)) { + (void)close(fd); + fd = -1; + result = ISC_R_UNEXPECTED; + } + + /* + * -1 means the new socket didn't happen. + */ + if (fd != -1) { + int lockid = FDLOCK_ID(fd); + + LOCK(&manager->fdlock[lockid]); + manager->fds[fd] = dev->newsocket; + manager->fdstate[fd] = MANAGED; + UNLOCK(&manager->fdlock[lockid]); + + LOCK(&manager->lock); + ISC_LIST_APPEND(manager->socklist, dev->newsocket, link); + + dev->newsocket->fd = fd; + dev->newsocket->bound = 1; + dev->newsocket->connected = 1; + + /* + * Save away the remote address + */ + dev->address = dev->newsocket->peer_address; + +#ifdef USE_SELECT + if (manager->maxfd < fd) + manager->maxfd = fd; +#endif + + socket_log(sock, &dev->newsocket->peer_address, CREATION, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_ACCEPTEDCXN, + "accepted connection, new socket %p", + dev->newsocket); + + UNLOCK(&manager->lock); + + inc_stats(manager->stats, sock->statsindex[STATID_ACCEPT]); + } else { + inc_stats(manager->stats, sock->statsindex[STATID_ACCEPTFAIL]); + dev->newsocket->references--; + free_socket(&dev->newsocket); + } + + /* + * Fill in the done event details and send it off. + */ + dev->result = result; + task = dev->ev_sender; + dev->ev_sender = sock; + + isc_task_sendanddetach(&task, ISC_EVENT_PTR(&dev)); + return; + + soft_error: + select_poke(sock->manager, sock->fd, SELECT_POKE_ACCEPT); + UNLOCK(&sock->lock); + + inc_stats(manager->stats, sock->statsindex[STATID_ACCEPTFAIL]); + return; +} + +static void +internal_recv(isc_task_t *me, isc_event_t *ev) { + isc_socketevent_t *dev; + isc_socket_t *sock; + + INSIST(ev->ev_type == ISC_SOCKEVENT_INTR); + + sock = ev->ev_sender; + INSIST(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + socket_log(sock, NULL, IOEVENT, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_INTERNALRECV, + "internal_recv: task %p got event %p", me, ev); + + INSIST(sock->pending_recv == 1); + sock->pending_recv = 0; + + INSIST(sock->references > 0); + sock->references--; /* the internal event is done with this socket */ + if (sock->references == 0) { + UNLOCK(&sock->lock); + destroy(&sock); + return; + } + + /* + * Try to do as much I/O as possible on this socket. There are no + * limits here, currently. + */ + dev = ISC_LIST_HEAD(sock->recv_list); + while (dev != NULL) { + switch (doio_recv(sock, dev)) { + case DOIO_SOFT: + goto poke; + + case DOIO_EOF: + /* + * read of 0 means the remote end was closed. + * Run through the event queue and dispatch all + * the events with an EOF result code. + */ + do { + dev->result = ISC_R_EOF; + send_recvdone_event(sock, &dev); + dev = ISC_LIST_HEAD(sock->recv_list); + } while (dev != NULL); + goto poke; + + case DOIO_SUCCESS: + case DOIO_HARD: + send_recvdone_event(sock, &dev); + break; + } + + dev = ISC_LIST_HEAD(sock->recv_list); + } + + poke: + if (!ISC_LIST_EMPTY(sock->recv_list)) + select_poke(sock->manager, sock->fd, SELECT_POKE_READ); + + UNLOCK(&sock->lock); +} + +static void +internal_send(isc_task_t *me, isc_event_t *ev) { + isc_socketevent_t *dev; + isc_socket_t *sock; + + INSIST(ev->ev_type == ISC_SOCKEVENT_INTW); + + /* + * Find out what socket this is and lock it. + */ + sock = (isc_socket_t *)ev->ev_sender; + INSIST(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + socket_log(sock, NULL, IOEVENT, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_INTERNALSEND, + "internal_send: task %p got event %p", me, ev); + + INSIST(sock->pending_send == 1); + sock->pending_send = 0; + + INSIST(sock->references > 0); + sock->references--; /* the internal event is done with this socket */ + if (sock->references == 0) { + UNLOCK(&sock->lock); + destroy(&sock); + return; + } + + /* + * Try to do as much I/O as possible on this socket. There are no + * limits here, currently. + */ + dev = ISC_LIST_HEAD(sock->send_list); + while (dev != NULL) { + switch (doio_send(sock, dev)) { + case DOIO_SOFT: + goto poke; + + case DOIO_HARD: + case DOIO_SUCCESS: + send_senddone_event(sock, &dev); + break; + } + + dev = ISC_LIST_HEAD(sock->send_list); + } + + poke: + if (!ISC_LIST_EMPTY(sock->send_list)) + select_poke(sock->manager, sock->fd, SELECT_POKE_WRITE); + + UNLOCK(&sock->lock); +} + +static void +internal_fdwatch_write(isc_task_t *me, isc_event_t *ev) { + isc_socket_t *sock; + int more_data; + + INSIST(ev->ev_type == ISC_SOCKEVENT_INTW); + + /* + * Find out what socket this is and lock it. + */ + sock = (isc_socket_t *)ev->ev_sender; + INSIST(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + socket_log(sock, NULL, IOEVENT, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_INTERNALSEND, + "internal_fdwatch_write: task %p got event %p", me, ev); + + INSIST(sock->pending_send == 1); + + UNLOCK(&sock->lock); + more_data = (sock->fdwatchcb)(me, sock, sock->fdwatcharg); + LOCK(&sock->lock); + + sock->pending_send = 0; + + INSIST(sock->references > 0); + sock->references--; /* the internal event is done with this socket */ + if (sock->references == 0) { + UNLOCK(&sock->lock); + destroy(&sock); + return; + } + + if (more_data) + select_poke(sock->manager, sock->fd, SELECT_POKE_WRITE); + + UNLOCK(&sock->lock); +} + +static void +internal_fdwatch_read(isc_task_t *me, isc_event_t *ev) { + isc_socket_t *sock; + int more_data; + + INSIST(ev->ev_type == ISC_SOCKEVENT_INTR); + + /* + * Find out what socket this is and lock it. + */ + sock = (isc_socket_t *)ev->ev_sender; + INSIST(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + socket_log(sock, NULL, IOEVENT, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_INTERNALRECV, + "internal_fdwatch_read: task %p got event %p", me, ev); + + INSIST(sock->pending_recv == 1); + + UNLOCK(&sock->lock); + more_data = (sock->fdwatchcb)(me, sock, sock->fdwatcharg); + LOCK(&sock->lock); + + sock->pending_recv = 0; + + INSIST(sock->references > 0); + sock->references--; /* the internal event is done with this socket */ + if (sock->references == 0) { + UNLOCK(&sock->lock); + destroy(&sock); + return; + } + + if (more_data) + select_poke(sock->manager, sock->fd, SELECT_POKE_READ); + + UNLOCK(&sock->lock); +} + +/* + * Process read/writes on each fd here. Avoid locking + * and unlocking twice if both reads and writes are possible. + */ +static void +process_fd(isc_socketmgr_t *manager, int fd, isc_boolean_t readable, + isc_boolean_t writeable) +{ + isc_socket_t *sock; + isc_boolean_t unlock_sock; + isc_boolean_t unwatch_read = ISC_FALSE, unwatch_write = ISC_FALSE; + int lockid = FDLOCK_ID(fd); + + /* + * If the socket is going to be closed, don't do more I/O. + */ + LOCK(&manager->fdlock[lockid]); + if (manager->fdstate[fd] == CLOSE_PENDING) { + UNLOCK(&manager->fdlock[lockid]); + + (void)unwatch_fd(manager, fd, SELECT_POKE_READ); + (void)unwatch_fd(manager, fd, SELECT_POKE_WRITE); + return; + } + + sock = manager->fds[fd]; + unlock_sock = ISC_FALSE; + if (readable) { + if (sock == NULL) { + unwatch_read = ISC_TRUE; + goto check_write; + } + unlock_sock = ISC_TRUE; + LOCK(&sock->lock); + if (!SOCK_DEAD(sock)) { + if (sock->listener) + dispatch_accept(sock); + else + dispatch_recv(sock); + } + unwatch_read = ISC_TRUE; + } +check_write: + if (writeable) { + if (sock == NULL) { + unwatch_write = ISC_TRUE; + goto unlock_fd; + } + if (!unlock_sock) { + unlock_sock = ISC_TRUE; + LOCK(&sock->lock); + } + if (!SOCK_DEAD(sock)) { + if (sock->connecting) + dispatch_connect(sock); + else + dispatch_send(sock); + } + unwatch_write = ISC_TRUE; + } + if (unlock_sock) + UNLOCK(&sock->lock); + + unlock_fd: + UNLOCK(&manager->fdlock[lockid]); + if (unwatch_read) + (void)unwatch_fd(manager, fd, SELECT_POKE_READ); + if (unwatch_write) + (void)unwatch_fd(manager, fd, SELECT_POKE_WRITE); + +} + +#ifdef USE_KQUEUE +static isc_boolean_t +process_fds(isc_socketmgr_t *manager, struct kevent *events, int nevents) { + int i; + isc_boolean_t readable, writable; + isc_boolean_t done = ISC_FALSE; +#ifdef ISC_PLATFORM_USETHREADS + isc_boolean_t have_ctlevent = ISC_FALSE; +#endif + + if (nevents == manager->nevents) { + /* + * This is not an error, but something unexpected. If this + * happens, it may indicate the need for increasing + * ISC_SOCKET_MAXEVENTS. + */ + manager_log(manager, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_INFO, + "maximum number of FD events (%d) received", + nevents); + } + + for (i = 0; i < nevents; i++) { + REQUIRE(events[i].ident < manager->maxsocks); +#ifdef ISC_PLATFORM_USETHREADS + if (events[i].ident == (uintptr_t)manager->pipe_fds[0]) { + have_ctlevent = ISC_TRUE; + continue; + } +#endif + readable = ISC_TF(events[i].filter == EVFILT_READ); + writable = ISC_TF(events[i].filter == EVFILT_WRITE); + process_fd(manager, events[i].ident, readable, writable); + } + +#ifdef ISC_PLATFORM_USETHREADS + if (have_ctlevent) + done = process_ctlfd(manager); +#endif + + return (done); +} +#elif defined(USE_EPOLL) +static isc_boolean_t +process_fds(isc_socketmgr_t *manager, struct epoll_event *events, int nevents) { + int i; + isc_boolean_t done = ISC_FALSE; +#ifdef ISC_PLATFORM_USETHREADS + isc_boolean_t have_ctlevent = ISC_FALSE; +#endif + + if (nevents == manager->nevents) { + manager_log(manager, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_INFO, + "maximum number of FD events (%d) received", + nevents); + } + + for (i = 0; i < nevents; i++) { + REQUIRE(events[i].data.fd < (int)manager->maxsocks); +#ifdef ISC_PLATFORM_USETHREADS + if (events[i].data.fd == manager->pipe_fds[0]) { + have_ctlevent = ISC_TRUE; + continue; + } +#endif + if ((events[i].events & EPOLLERR) != 0 || + (events[i].events & EPOLLHUP) != 0) { + /* + * epoll does not set IN/OUT bits on an erroneous + * condition, so we need to try both anyway. This is a + * bit inefficient, but should be okay for such rare + * events. Note also that the read or write attempt + * won't block because we use non-blocking sockets. + */ + events[i].events |= (EPOLLIN | EPOLLOUT); + } + process_fd(manager, events[i].data.fd, + (events[i].events & EPOLLIN) != 0, + (events[i].events & EPOLLOUT) != 0); + } + +#ifdef ISC_PLATFORM_USETHREADS + if (have_ctlevent) + done = process_ctlfd(manager); +#endif + + return (done); +} +#elif defined(USE_DEVPOLL) +static isc_boolean_t +process_fds(isc_socketmgr_t *manager, struct pollfd *events, int nevents) { + int i; + isc_boolean_t done = ISC_FALSE; +#ifdef ISC_PLATFORM_USETHREADS + isc_boolean_t have_ctlevent = ISC_FALSE; +#endif + + if (nevents == manager->nevents) { + manager_log(manager, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_INFO, + "maximum number of FD events (%d) received", + nevents); + } + + for (i = 0; i < nevents; i++) { + REQUIRE(events[i].fd < (int)manager->maxsocks); +#ifdef ISC_PLATFORM_USETHREADS + if (events[i].fd == manager->pipe_fds[0]) { + have_ctlevent = ISC_TRUE; + continue; + } +#endif + process_fd(manager, events[i].fd, + (events[i].events & POLLIN) != 0, + (events[i].events & POLLOUT) != 0); + } + +#ifdef ISC_PLATFORM_USETHREADS + if (have_ctlevent) + done = process_ctlfd(manager); +#endif + + return (done); +} +#elif defined(USE_SELECT) +static void +process_fds(isc_socketmgr_t *manager, int maxfd, + fd_set *readfds, fd_set *writefds) +{ + int i; + + REQUIRE(maxfd <= (int)manager->maxsocks); + + for (i = 0; i < maxfd; i++) { +#ifdef ISC_PLATFORM_USETHREADS + if (i == manager->pipe_fds[0] || i == manager->pipe_fds[1]) + continue; +#endif /* ISC_PLATFORM_USETHREADS */ + process_fd(manager, i, FD_ISSET(i, readfds), + FD_ISSET(i, writefds)); + } +} +#endif + +#ifdef ISC_PLATFORM_USETHREADS +static isc_boolean_t +process_ctlfd(isc_socketmgr_t *manager) { + int msg, fd; + + for (;;) { + select_readmsg(manager, &fd, &msg); + + manager_log(manager, IOEVENT, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_WATCHERMSG, + "watcher got message %d " + "for socket %d"), msg, fd); + + /* + * Nothing to read? + */ + if (msg == SELECT_POKE_NOTHING) + break; + + /* + * Handle shutdown message. We really should + * jump out of this loop right away, but + * it doesn't matter if we have to do a little + * more work first. + */ + if (msg == SELECT_POKE_SHUTDOWN) + return (ISC_TRUE); + + /* + * This is a wakeup on a socket. Look + * at the event queue for both read and write, + * and decide if we need to watch on it now + * or not. + */ + wakeup_socket(manager, fd, msg); + } + + return (ISC_FALSE); +} + +/* + * This is the thread that will loop forever, always in a select or poll + * call. + * + * When select returns something to do, track down what thread gets to do + * this I/O and post the event to it. + */ +static isc_threadresult_t +watcher(void *uap) { + isc_socketmgr_t *manager = uap; + isc_boolean_t done; + int ctlfd; + int cc; +#ifdef USE_KQUEUE + const char *fnname = "kevent()"; +#elif defined (USE_EPOLL) + const char *fnname = "epoll_wait()"; +#elif defined(USE_DEVPOLL) + const char *fnname = "ioctl(DP_POLL)"; + struct dvpoll dvp; +#elif defined (USE_SELECT) + const char *fnname = "select()"; + int maxfd; +#endif + char strbuf[ISC_STRERRORSIZE]; +#ifdef ISC_SOCKET_USE_POLLWATCH + pollstate_t pollstate = poll_idle; +#endif + + /* + * Get the control fd here. This will never change. + */ + ctlfd = manager->pipe_fds[0]; + done = ISC_FALSE; + while (!done) { + do { +#ifdef USE_KQUEUE + cc = kevent(manager->kqueue_fd, NULL, 0, + manager->events, manager->nevents, NULL); +#elif defined(USE_EPOLL) + cc = epoll_wait(manager->epoll_fd, manager->events, + manager->nevents, -1); +#elif defined(USE_DEVPOLL) + dvp.dp_fds = manager->events; + dvp.dp_nfds = manager->nevents; +#ifndef ISC_SOCKET_USE_POLLWATCH + dvp.dp_timeout = -1; +#else + if (pollstate == poll_idle) + dvp.dp_timeout = -1; + else + dvp.dp_timeout = ISC_SOCKET_POLLWATCH_TIMEOUT; +#endif /* ISC_SOCKET_USE_POLLWATCH */ + cc = ioctl(manager->devpoll_fd, DP_POLL, &dvp); +#elif defined(USE_SELECT) + LOCK(&manager->lock); + memcpy(manager->read_fds_copy, manager->read_fds, + manager->fd_bufsize); + memcpy(manager->write_fds_copy, manager->write_fds, + manager->fd_bufsize); + maxfd = manager->maxfd + 1; + UNLOCK(&manager->lock); + + cc = select(maxfd, manager->read_fds_copy, + manager->write_fds_copy, NULL, NULL); +#endif /* USE_KQUEUE */ + + if (cc < 0 && !SOFT_ERROR(errno)) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + FATAL_ERROR(__FILE__, __LINE__, + "%s %s: %s", fnname, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), strbuf); + } + +#if defined(USE_DEVPOLL) && defined(ISC_SOCKET_USE_POLLWATCH) + if (cc == 0) { + if (pollstate == poll_active) + pollstate = poll_checking; + else if (pollstate == poll_checking) + pollstate = poll_idle; + } else if (cc > 0) { + if (pollstate == poll_checking) { + /* + * XXX: We'd like to use a more + * verbose log level as it's actually an + * unexpected event, but the kernel bug + * reportedly happens pretty frequently + * (and it can also be a false positive) + * so it would be just too noisy. + */ + manager_log(manager, + ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, + ISC_LOG_DEBUG(1), + "unexpected POLL timeout"); + } + pollstate = poll_active; + } +#endif + } while (cc < 0); + +#if defined(USE_KQUEUE) || defined (USE_EPOLL) || defined (USE_DEVPOLL) + done = process_fds(manager, manager->events, cc); +#elif defined(USE_SELECT) + process_fds(manager, maxfd, manager->read_fds_copy, + manager->write_fds_copy); + + /* + * Process reads on internal, control fd. + */ + if (FD_ISSET(ctlfd, manager->read_fds_copy)) + done = process_ctlfd(manager); +#endif + } + + manager_log(manager, TRACE, "%s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_EXITING, "watcher exiting")); + + return ((isc_threadresult_t)0); +} +#endif /* ISC_PLATFORM_USETHREADS */ + +void +isc__socketmgr_setreserved(isc_socketmgr_t *manager, isc_uint32_t reserved) { + + REQUIRE(VALID_MANAGER(manager)); + + manager->reserved = reserved; +} + +/* + * Create a new socket manager. + */ + +static isc_result_t +setup_watcher(isc_mem_t *mctx, isc_socketmgr_t *manager) { + isc_result_t result; +#if defined(USE_KQUEUE) || defined(USE_EPOLL) || defined(USE_DEVPOLL) + char strbuf[ISC_STRERRORSIZE]; +#endif + +#ifdef USE_KQUEUE + manager->nevents = ISC_SOCKET_MAXEVENTS; + manager->events = isc_mem_get(mctx, sizeof(struct kevent) * + manager->nevents); + if (manager->events == NULL) + return (ISC_R_NOMEMORY); + manager->kqueue_fd = kqueue(); + if (manager->kqueue_fd == -1) { + result = isc__errno2result(errno); + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "kqueue %s: %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed"), + strbuf); + isc_mem_put(mctx, manager->events, + sizeof(struct kevent) * manager->nevents); + return (result); + } + +#ifdef ISC_PLATFORM_USETHREADS + result = watch_fd(manager, manager->pipe_fds[0], SELECT_POKE_READ); + if (result != ISC_R_SUCCESS) { + close(manager->kqueue_fd); + isc_mem_put(mctx, manager->events, + sizeof(struct kevent) * manager->nevents); + return (result); + } +#endif /* ISC_PLATFORM_USETHREADS */ +#elif defined(USE_EPOLL) + manager->nevents = ISC_SOCKET_MAXEVENTS; + manager->events = isc_mem_get(mctx, sizeof(struct epoll_event) * + manager->nevents); + if (manager->events == NULL) + return (ISC_R_NOMEMORY); + manager->epoll_fd = epoll_create(manager->nevents); + if (manager->epoll_fd == -1) { + result = isc__errno2result(errno); + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "epoll_create %s: %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed"), + strbuf); + isc_mem_put(mctx, manager->events, + sizeof(struct epoll_event) * manager->nevents); + return (result); + } +#ifdef ISC_PLATFORM_USETHREADS + result = watch_fd(manager, manager->pipe_fds[0], SELECT_POKE_READ); + if (result != ISC_R_SUCCESS) { + close(manager->epoll_fd); + isc_mem_put(mctx, manager->events, + sizeof(struct epoll_event) * manager->nevents); + return (result); + } +#endif /* ISC_PLATFORM_USETHREADS */ +#elif defined(USE_DEVPOLL) + /* + * XXXJT: /dev/poll seems to reject large numbers of events, + * so we should be careful about redefining ISC_SOCKET_MAXEVENTS. + */ + manager->nevents = ISC_SOCKET_MAXEVENTS; + manager->events = isc_mem_get(mctx, sizeof(struct pollfd) * + manager->nevents); + if (manager->events == NULL) + return (ISC_R_NOMEMORY); + /* + * Note: fdpollinfo should be able to support all possible FDs, so + * it must have maxsocks entries (not nevents). + */ + manager->fdpollinfo = isc_mem_get(mctx, sizeof(pollinfo_t) * + manager->maxsocks); + if (manager->fdpollinfo == NULL) { + isc_mem_put(mctx, manager->events, + sizeof(pollinfo_t) * manager->maxsocks); + return (ISC_R_NOMEMORY); + } + memset(manager->fdpollinfo, 0, sizeof(pollinfo_t) * manager->maxsocks); + manager->devpoll_fd = open("/dev/poll", O_RDWR); + if (manager->devpoll_fd == -1) { + result = isc__errno2result(errno); + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "open(/dev/poll) %s: %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed"), + strbuf); + isc_mem_put(mctx, manager->events, + sizeof(struct pollfd) * manager->nevents); + isc_mem_put(mctx, manager->fdpollinfo, + sizeof(pollinfo_t) * manager->maxsocks); + return (result); + } +#ifdef ISC_PLATFORM_USETHREADS + result = watch_fd(manager, manager->pipe_fds[0], SELECT_POKE_READ); + if (result != ISC_R_SUCCESS) { + close(manager->devpoll_fd); + isc_mem_put(mctx, manager->events, + sizeof(struct pollfd) * manager->nevents); + isc_mem_put(mctx, manager->fdpollinfo, + sizeof(pollinfo_t) * manager->maxsocks); + return (result); + } +#endif /* ISC_PLATFORM_USETHREADS */ +#elif defined(USE_SELECT) + UNUSED(result); + +#if ISC_SOCKET_MAXSOCKETS > FD_SETSIZE + /* + * Note: this code should also cover the case of MAXSOCKETS <= + * FD_SETSIZE, but we separate the cases to avoid possible portability + * issues regarding howmany() and the actual representation of fd_set. + */ + manager->fd_bufsize = howmany(manager->maxsocks, NFDBITS) * + sizeof(fd_mask); +#else + manager->fd_bufsize = sizeof(fd_set); +#endif + + manager->read_fds = NULL; + manager->read_fds_copy = NULL; + manager->write_fds = NULL; + manager->write_fds_copy = NULL; + + manager->read_fds = isc_mem_get(mctx, manager->fd_bufsize); + if (manager->read_fds != NULL) + manager->read_fds_copy = isc_mem_get(mctx, manager->fd_bufsize); + if (manager->read_fds_copy != NULL) + manager->write_fds = isc_mem_get(mctx, manager->fd_bufsize); + if (manager->write_fds != NULL) { + manager->write_fds_copy = isc_mem_get(mctx, + manager->fd_bufsize); + } + if (manager->write_fds_copy == NULL) { + if (manager->write_fds != NULL) { + isc_mem_put(mctx, manager->write_fds, + manager->fd_bufsize); + } + if (manager->read_fds_copy != NULL) { + isc_mem_put(mctx, manager->read_fds_copy, + manager->fd_bufsize); + } + if (manager->read_fds != NULL) { + isc_mem_put(mctx, manager->read_fds, + manager->fd_bufsize); + } + return (ISC_R_NOMEMORY); + } + memset(manager->read_fds, 0, manager->fd_bufsize); + memset(manager->write_fds, 0, manager->fd_bufsize); + +#ifdef ISC_PLATFORM_USETHREADS + (void)watch_fd(manager, manager->pipe_fds[0], SELECT_POKE_READ); + manager->maxfd = manager->pipe_fds[0]; +#else /* ISC_PLATFORM_USETHREADS */ + manager->maxfd = 0; +#endif /* ISC_PLATFORM_USETHREADS */ +#endif /* USE_KQUEUE */ + + return (ISC_R_SUCCESS); +} + +static void +cleanup_watcher(isc_mem_t *mctx, isc_socketmgr_t *manager) { +#ifdef ISC_PLATFORM_USETHREADS + isc_result_t result; + + result = unwatch_fd(manager, manager->pipe_fds[0], SELECT_POKE_READ); + if (result != ISC_R_SUCCESS) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "epoll_ctl(DEL) %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + } +#endif /* ISC_PLATFORM_USETHREADS */ + +#ifdef USE_KQUEUE + close(manager->kqueue_fd); + isc_mem_put(mctx, manager->events, + sizeof(struct kevent) * manager->nevents); +#elif defined(USE_EPOLL) + close(manager->epoll_fd); + isc_mem_put(mctx, manager->events, + sizeof(struct epoll_event) * manager->nevents); +#elif defined(USE_DEVPOLL) + close(manager->devpoll_fd); + isc_mem_put(mctx, manager->events, + sizeof(struct pollfd) * manager->nevents); + isc_mem_put(mctx, manager->fdpollinfo, + sizeof(pollinfo_t) * manager->maxsocks); +#elif defined(USE_SELECT) + if (manager->read_fds != NULL) + isc_mem_put(mctx, manager->read_fds, manager->fd_bufsize); + if (manager->read_fds_copy != NULL) + isc_mem_put(mctx, manager->read_fds_copy, manager->fd_bufsize); + if (manager->write_fds != NULL) + isc_mem_put(mctx, manager->write_fds, manager->fd_bufsize); + if (manager->write_fds_copy != NULL) + isc_mem_put(mctx, manager->write_fds_copy, manager->fd_bufsize); +#endif /* USE_KQUEUE */ +} + +isc_result_t +isc_socketmgr_create(isc_mem_t *mctx, isc_socketmgr_t **managerp) { + return (isc_socketmgr_create2(mctx, managerp, 0)); +} + +isc_result_t +isc_socketmgr_create2(isc_mem_t *mctx, isc_socketmgr_t **managerp, + unsigned int maxsocks) +{ + int i; + isc_socketmgr_t *manager; +#ifdef ISC_PLATFORM_USETHREADS + char strbuf[ISC_STRERRORSIZE]; +#endif + isc_result_t result; + + REQUIRE(managerp != NULL && *managerp == NULL); + +#ifndef ISC_PLATFORM_USETHREADS + if (socketmgr != NULL) { + /* Don't allow maxsocks to be updated */ + if (maxsocks > 0 && socketmgr->maxsocks != maxsocks) + return (ISC_R_EXISTS); + + socketmgr->refs++; + *managerp = socketmgr; + return (ISC_R_SUCCESS); + } +#endif /* ISC_PLATFORM_USETHREADS */ + + if (maxsocks == 0) + maxsocks = ISC_SOCKET_MAXSOCKETS; + + manager = isc_mem_get(mctx, sizeof(*manager)); + if (manager == NULL) + return (ISC_R_NOMEMORY); + + /* zero-clear so that necessary cleanup on failure will be easy */ + memset(manager, 0, sizeof(*manager)); + manager->maxsocks = maxsocks; + manager->reserved = 0; + manager->fds = isc_mem_get(mctx, + manager->maxsocks * sizeof(isc_socket_t *)); + if (manager->fds == NULL) { + result = ISC_R_NOMEMORY; + goto free_manager; + } + manager->fdstate = isc_mem_get(mctx, manager->maxsocks * sizeof(int)); + if (manager->fdstate == NULL) { + result = ISC_R_NOMEMORY; + goto free_manager; + } + manager->stats = NULL; + + manager->magic = SOCKET_MANAGER_MAGIC; + manager->mctx = NULL; + memset(manager->fds, 0, manager->maxsocks * sizeof(isc_socket_t *)); + ISC_LIST_INIT(manager->socklist); + result = isc_mutex_init(&manager->lock); + if (result != ISC_R_SUCCESS) + goto free_manager; + manager->fdlock = isc_mem_get(mctx, FDLOCK_COUNT * sizeof(isc_mutex_t)); + if (manager->fdlock == NULL) { + result = ISC_R_NOMEMORY; + goto cleanup_lock; + } + for (i = 0; i < FDLOCK_COUNT; i++) { + result = isc_mutex_init(&manager->fdlock[i]); + if (result != ISC_R_SUCCESS) { + while (--i >= 0) + DESTROYLOCK(&manager->fdlock[i]); + isc_mem_put(mctx, manager->fdlock, + FDLOCK_COUNT * sizeof(isc_mutex_t)); + manager->fdlock = NULL; + goto cleanup_lock; + } + } + +#ifdef ISC_PLATFORM_USETHREADS + if (isc_condition_init(&manager->shutdown_ok) != ISC_R_SUCCESS) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_condition_init() %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + result = ISC_R_UNEXPECTED; + goto cleanup_lock; + } + + /* + * Create the special fds that will be used to wake up the + * select/poll loop when something internal needs to be done. + */ + if (pipe(manager->pipe_fds) != 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "pipe() %s: %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed"), + strbuf); + result = ISC_R_UNEXPECTED; + goto cleanup_condition; + } + + RUNTIME_CHECK(make_nonblock(manager->pipe_fds[0]) == ISC_R_SUCCESS); +#if 0 + RUNTIME_CHECK(make_nonblock(manager->pipe_fds[1]) == ISC_R_SUCCESS); +#endif +#else /* ISC_PLATFORM_USETHREADS */ + manager->refs = 1; +#endif /* ISC_PLATFORM_USETHREADS */ + + /* + * Set up initial state for the select loop + */ + result = setup_watcher(mctx, manager); + if (result != ISC_R_SUCCESS) + goto cleanup; + memset(manager->fdstate, 0, manager->maxsocks * sizeof(int)); +#ifdef ISC_PLATFORM_USETHREADS + /* + * Start up the select/poll thread. + */ + if (isc_thread_create(watcher, manager, &manager->watcher) != + ISC_R_SUCCESS) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_thread_create() %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + cleanup_watcher(mctx, manager); + result = ISC_R_UNEXPECTED; + goto cleanup; + } +#endif /* ISC_PLATFORM_USETHREADS */ + isc_mem_attach(mctx, &manager->mctx); + +#ifndef ISC_PLATFORM_USETHREADS + socketmgr = manager; +#endif /* ISC_PLATFORM_USETHREADS */ + *managerp = manager; + + return (ISC_R_SUCCESS); + +cleanup: +#ifdef ISC_PLATFORM_USETHREADS + (void)close(manager->pipe_fds[0]); + (void)close(manager->pipe_fds[1]); +#endif /* ISC_PLATFORM_USETHREADS */ + +#ifdef ISC_PLATFORM_USETHREADS +cleanup_condition: + (void)isc_condition_destroy(&manager->shutdown_ok); +#endif /* ISC_PLATFORM_USETHREADS */ + + +cleanup_lock: + if (manager->fdlock != NULL) { + for (i = 0; i < FDLOCK_COUNT; i++) + DESTROYLOCK(&manager->fdlock[i]); + } + DESTROYLOCK(&manager->lock); + +free_manager: + if (manager->fdlock != NULL) { + isc_mem_put(mctx, manager->fdlock, + FDLOCK_COUNT * sizeof(isc_mutex_t)); + } + if (manager->fdstate != NULL) { + isc_mem_put(mctx, manager->fdstate, + manager->maxsocks * sizeof(int)); + } + if (manager->fds != NULL) { + isc_mem_put(mctx, manager->fds, + manager->maxsocks * sizeof(isc_socket_t *)); + } + isc_mem_put(mctx, manager, sizeof(*manager)); + + return (result); +} + +isc_result_t +isc_socketmgr_getmaxsockets(isc_socketmgr_t *manager, unsigned int *nsockp) { + REQUIRE(VALID_MANAGER(manager)); + REQUIRE(nsockp != NULL); + + *nsockp = manager->maxsocks; + + return (ISC_R_SUCCESS); +} + +void +isc_socketmgr_setstats(isc_socketmgr_t *manager, isc_stats_t *stats) { + REQUIRE(VALID_MANAGER(manager)); + REQUIRE(ISC_LIST_EMPTY(manager->socklist)); + REQUIRE(manager->stats == NULL); + REQUIRE(isc_stats_ncounters(stats) == isc_sockstatscounter_max); + + isc_stats_attach(stats, &manager->stats); +} + +void +isc_socketmgr_destroy(isc_socketmgr_t **managerp) { + isc_socketmgr_t *manager; + int i; + isc_mem_t *mctx; + + /* + * Destroy a socket manager. + */ + + REQUIRE(managerp != NULL); + manager = *managerp; + REQUIRE(VALID_MANAGER(manager)); + +#ifndef ISC_PLATFORM_USETHREADS + if (manager->refs > 1) { + manager->refs--; + *managerp = NULL; + return; + } +#endif /* ISC_PLATFORM_USETHREADS */ + + LOCK(&manager->lock); + +#ifdef ISC_PLATFORM_USETHREADS + /* + * Wait for all sockets to be destroyed. + */ + while (!ISC_LIST_EMPTY(manager->socklist)) { + manager_log(manager, CREATION, "%s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_SOCKETSREMAIN, + "sockets exist")); + WAIT(&manager->shutdown_ok, &manager->lock); + } +#else /* ISC_PLATFORM_USETHREADS */ + /* + * Hope all sockets have been destroyed. + */ + if (!ISC_LIST_EMPTY(manager->socklist)) { + manager_log(manager, CREATION, "%s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_SOCKETSREMAIN, + "sockets exist")); + INSIST(0); + } +#endif /* ISC_PLATFORM_USETHREADS */ + + UNLOCK(&manager->lock); + + /* + * Here, poke our select/poll thread. Do this by closing the write + * half of the pipe, which will send EOF to the read half. + * This is currently a no-op in the non-threaded case. + */ + select_poke(manager, 0, SELECT_POKE_SHUTDOWN); + +#ifdef ISC_PLATFORM_USETHREADS + /* + * Wait for thread to exit. + */ + if (isc_thread_join(manager->watcher, NULL) != ISC_R_SUCCESS) + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_thread_join() %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); +#endif /* ISC_PLATFORM_USETHREADS */ + + /* + * Clean up. + */ + cleanup_watcher(manager->mctx, manager); + +#ifdef ISC_PLATFORM_USETHREADS + (void)close(manager->pipe_fds[0]); + (void)close(manager->pipe_fds[1]); + (void)isc_condition_destroy(&manager->shutdown_ok); +#endif /* ISC_PLATFORM_USETHREADS */ + + for (i = 0; i < (int)manager->maxsocks; i++) + if (manager->fdstate[i] == CLOSE_PENDING) /* no need to lock */ + (void)close(i); + + isc_mem_put(manager->mctx, manager->fds, + manager->maxsocks * sizeof(isc_socket_t *)); + isc_mem_put(manager->mctx, manager->fdstate, + manager->maxsocks * sizeof(int)); + + if (manager->stats != NULL) + isc_stats_detach(&manager->stats); + + if (manager->fdlock != NULL) { + for (i = 0; i < FDLOCK_COUNT; i++) + DESTROYLOCK(&manager->fdlock[i]); + isc_mem_put(manager->mctx, manager->fdlock, + FDLOCK_COUNT * sizeof(isc_mutex_t)); + } + DESTROYLOCK(&manager->lock); + manager->magic = 0; + mctx= manager->mctx; + isc_mem_put(mctx, manager, sizeof(*manager)); + + isc_mem_detach(&mctx); + + *managerp = NULL; +} + +static isc_result_t +socket_recv(isc_socket_t *sock, isc_socketevent_t *dev, isc_task_t *task, + unsigned int flags) +{ + int io_state; + isc_boolean_t have_lock = ISC_FALSE; + isc_task_t *ntask = NULL; + isc_result_t result = ISC_R_SUCCESS; + + dev->ev_sender = task; + + if (sock->type == isc_sockettype_udp) { + io_state = doio_recv(sock, dev); + } else { + LOCK(&sock->lock); + have_lock = ISC_TRUE; + + if (ISC_LIST_EMPTY(sock->recv_list)) + io_state = doio_recv(sock, dev); + else + io_state = DOIO_SOFT; + } + + switch (io_state) { + case DOIO_SOFT: + /* + * We couldn't read all or part of the request right now, so + * queue it. + * + * Attach to socket and to task + */ + isc_task_attach(task, &ntask); + dev->attributes |= ISC_SOCKEVENTATTR_ATTACHED; + + if (!have_lock) { + LOCK(&sock->lock); + have_lock = ISC_TRUE; + } + + /* + * Enqueue the request. If the socket was previously not being + * watched, poke the watcher to start paying attention to it. + */ + if (ISC_LIST_EMPTY(sock->recv_list) && !sock->pending_recv) + select_poke(sock->manager, sock->fd, SELECT_POKE_READ); + ISC_LIST_ENQUEUE(sock->recv_list, dev, ev_link); + + socket_log(sock, NULL, EVENT, NULL, 0, 0, + "socket_recv: event %p -> task %p", + dev, ntask); + + if ((flags & ISC_SOCKFLAG_IMMEDIATE) != 0) + result = ISC_R_INPROGRESS; + break; + + case DOIO_EOF: + dev->result = ISC_R_EOF; + /* fallthrough */ + + case DOIO_HARD: + case DOIO_SUCCESS: + if ((flags & ISC_SOCKFLAG_IMMEDIATE) == 0) + send_recvdone_event(sock, &dev); + break; + } + + if (have_lock) + UNLOCK(&sock->lock); + + return (result); +} + +isc_result_t +isc_socket_recvv(isc_socket_t *sock, isc_bufferlist_t *buflist, + unsigned int minimum, isc_task_t *task, + isc_taskaction_t action, const void *arg) +{ + isc_socketevent_t *dev; + isc_socketmgr_t *manager; + unsigned int iocount; + isc_buffer_t *buffer; + + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(buflist != NULL); + REQUIRE(!ISC_LIST_EMPTY(*buflist)); + REQUIRE(task != NULL); + REQUIRE(action != NULL); + + manager = sock->manager; + REQUIRE(VALID_MANAGER(manager)); + + iocount = isc_bufferlist_availablecount(buflist); + REQUIRE(iocount > 0); + + INSIST(sock->bound); + + dev = allocate_socketevent(sock, ISC_SOCKEVENT_RECVDONE, action, arg); + if (dev == NULL) { + return (ISC_R_NOMEMORY); + } + + /* + * UDP sockets are always partial read + */ + if (sock->type == isc_sockettype_udp) + dev->minimum = 1; + else { + if (minimum == 0) + dev->minimum = iocount; + else + dev->minimum = minimum; + } + + /* + * Move each buffer from the passed in list to our internal one. + */ + buffer = ISC_LIST_HEAD(*buflist); + while (buffer != NULL) { + ISC_LIST_DEQUEUE(*buflist, buffer, link); + ISC_LIST_ENQUEUE(dev->bufferlist, buffer, link); + buffer = ISC_LIST_HEAD(*buflist); + } + + return (socket_recv(sock, dev, task, 0)); +} + +isc_result_t +isc_socket_recv(isc_socket_t *sock, isc_region_t *region, unsigned int minimum, + isc_task_t *task, isc_taskaction_t action, const void *arg) +{ + isc_socketevent_t *dev; + isc_socketmgr_t *manager; + + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(action != NULL); + + manager = sock->manager; + REQUIRE(VALID_MANAGER(manager)); + + INSIST(sock->bound); + + dev = allocate_socketevent(sock, ISC_SOCKEVENT_RECVDONE, action, arg); + if (dev == NULL) + return (ISC_R_NOMEMORY); + + return (isc_socket_recv2(sock, region, minimum, task, dev, 0)); +} + +isc_result_t +isc_socket_recv2(isc_socket_t *sock, isc_region_t *region, + unsigned int minimum, isc_task_t *task, + isc_socketevent_t *event, unsigned int flags) +{ + event->ev_sender = sock; + event->result = ISC_R_UNEXPECTED; + ISC_LIST_INIT(event->bufferlist); + event->region = *region; + event->n = 0; + event->offset = 0; + event->attributes = 0; + + /* + * UDP sockets are always partial read. + */ + if (sock->type == isc_sockettype_udp) + event->minimum = 1; + else { + if (minimum == 0) + event->minimum = region->length; + else + event->minimum = minimum; + } + + return (socket_recv(sock, event, task, flags)); +} + +static isc_result_t +socket_send(isc_socket_t *sock, isc_socketevent_t *dev, isc_task_t *task, + isc_sockaddr_t *address, struct in6_pktinfo *pktinfo, + unsigned int flags) +{ + int io_state; + isc_boolean_t have_lock = ISC_FALSE; + isc_task_t *ntask = NULL; + isc_result_t result = ISC_R_SUCCESS; + + dev->ev_sender = task; + + set_dev_address(address, sock, dev); + if (pktinfo != NULL) { + dev->attributes |= ISC_SOCKEVENTATTR_PKTINFO; + dev->pktinfo = *pktinfo; + + if (!isc_sockaddr_issitelocal(&dev->address) && + !isc_sockaddr_islinklocal(&dev->address)) { + socket_log(sock, NULL, TRACE, isc_msgcat, + ISC_MSGSET_SOCKET, ISC_MSG_PKTINFOPROVIDED, + "pktinfo structure provided, ifindex %u " + "(set to 0)", pktinfo->ipi6_ifindex); + + /* + * Set the pktinfo index to 0 here, to let the + * kernel decide what interface it should send on. + */ + dev->pktinfo.ipi6_ifindex = 0; + } + } + + if (sock->type == isc_sockettype_udp) + io_state = doio_send(sock, dev); + else { + LOCK(&sock->lock); + have_lock = ISC_TRUE; + + if (ISC_LIST_EMPTY(sock->send_list)) + io_state = doio_send(sock, dev); + else + io_state = DOIO_SOFT; + } + + switch (io_state) { + case DOIO_SOFT: + /* + * We couldn't send all or part of the request right now, so + * queue it unless ISC_SOCKFLAG_NORETRY is set. + */ + if ((flags & ISC_SOCKFLAG_NORETRY) == 0) { + isc_task_attach(task, &ntask); + dev->attributes |= ISC_SOCKEVENTATTR_ATTACHED; + + if (!have_lock) { + LOCK(&sock->lock); + have_lock = ISC_TRUE; + } + + /* + * Enqueue the request. If the socket was previously + * not being watched, poke the watcher to start + * paying attention to it. + */ + if (ISC_LIST_EMPTY(sock->send_list) && + !sock->pending_send) + select_poke(sock->manager, sock->fd, + SELECT_POKE_WRITE); + ISC_LIST_ENQUEUE(sock->send_list, dev, ev_link); + + socket_log(sock, NULL, EVENT, NULL, 0, 0, + "socket_send: event %p -> task %p", + dev, ntask); + + if ((flags & ISC_SOCKFLAG_IMMEDIATE) != 0) + result = ISC_R_INPROGRESS; + break; + } + + case DOIO_HARD: + case DOIO_SUCCESS: + if ((flags & ISC_SOCKFLAG_IMMEDIATE) == 0) + send_senddone_event(sock, &dev); + break; + } + + if (have_lock) + UNLOCK(&sock->lock); + + return (result); +} + +isc_result_t +isc_socket_send(isc_socket_t *sock, isc_region_t *region, + isc_task_t *task, isc_taskaction_t action, const void *arg) +{ + /* + * REQUIRE() checking is performed in isc_socket_sendto(). + */ + return (isc_socket_sendto(sock, region, task, action, arg, NULL, + NULL)); +} + +isc_result_t +isc_socket_sendto(isc_socket_t *sock, isc_region_t *region, + isc_task_t *task, isc_taskaction_t action, const void *arg, + isc_sockaddr_t *address, struct in6_pktinfo *pktinfo) +{ + isc_socketevent_t *dev; + isc_socketmgr_t *manager; + + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(region != NULL); + REQUIRE(task != NULL); + REQUIRE(action != NULL); + + manager = sock->manager; + REQUIRE(VALID_MANAGER(manager)); + + INSIST(sock->bound); + + dev = allocate_socketevent(sock, ISC_SOCKEVENT_SENDDONE, action, arg); + if (dev == NULL) { + return (ISC_R_NOMEMORY); + } + + dev->region = *region; + + return (socket_send(sock, dev, task, address, pktinfo, 0)); +} + +isc_result_t +isc_socket_sendv(isc_socket_t *sock, isc_bufferlist_t *buflist, + isc_task_t *task, isc_taskaction_t action, const void *arg) +{ + return (isc_socket_sendtov(sock, buflist, task, action, arg, NULL, + NULL)); +} + +isc_result_t +isc_socket_sendtov(isc_socket_t *sock, isc_bufferlist_t *buflist, + isc_task_t *task, isc_taskaction_t action, const void *arg, + isc_sockaddr_t *address, struct in6_pktinfo *pktinfo) +{ + isc_socketevent_t *dev; + isc_socketmgr_t *manager; + unsigned int iocount; + isc_buffer_t *buffer; + + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(buflist != NULL); + REQUIRE(!ISC_LIST_EMPTY(*buflist)); + REQUIRE(task != NULL); + REQUIRE(action != NULL); + + manager = sock->manager; + REQUIRE(VALID_MANAGER(manager)); + + iocount = isc_bufferlist_usedcount(buflist); + REQUIRE(iocount > 0); + + dev = allocate_socketevent(sock, ISC_SOCKEVENT_SENDDONE, action, arg); + if (dev == NULL) { + return (ISC_R_NOMEMORY); + } + + /* + * Move each buffer from the passed in list to our internal one. + */ + buffer = ISC_LIST_HEAD(*buflist); + while (buffer != NULL) { + ISC_LIST_DEQUEUE(*buflist, buffer, link); + ISC_LIST_ENQUEUE(dev->bufferlist, buffer, link); + buffer = ISC_LIST_HEAD(*buflist); + } + + return (socket_send(sock, dev, task, address, pktinfo, 0)); +} + +isc_result_t +isc_socket_sendto2(isc_socket_t *sock, isc_region_t *region, + isc_task_t *task, + isc_sockaddr_t *address, struct in6_pktinfo *pktinfo, + isc_socketevent_t *event, unsigned int flags) +{ + REQUIRE((flags & ~(ISC_SOCKFLAG_IMMEDIATE|ISC_SOCKFLAG_NORETRY)) == 0); + if ((flags & ISC_SOCKFLAG_NORETRY) != 0) + REQUIRE(sock->type == isc_sockettype_udp); + event->ev_sender = sock; + event->result = ISC_R_UNEXPECTED; + ISC_LIST_INIT(event->bufferlist); + event->region = *region; + event->n = 0; + event->offset = 0; + event->attributes = 0; + + return (socket_send(sock, event, task, address, pktinfo, flags)); +} + +void +isc_socket_cleanunix(isc_sockaddr_t *sockaddr, isc_boolean_t active) { +#ifdef ISC_PLATFORM_HAVESYSUNH + int s; + struct stat sb; + char strbuf[ISC_STRERRORSIZE]; + + if (sockaddr->type.sa.sa_family != AF_UNIX) + return; + +#ifndef S_ISSOCK +#if defined(S_IFMT) && defined(S_IFSOCK) +#define S_ISSOCK(mode) ((mode & S_IFMT)==S_IFSOCK) +#elif defined(_S_IFMT) && defined(S_IFSOCK) +#define S_ISSOCK(mode) ((mode & _S_IFMT)==S_IFSOCK) +#endif +#endif + +#ifndef S_ISFIFO +#if defined(S_IFMT) && defined(S_IFIFO) +#define S_ISFIFO(mode) ((mode & S_IFMT)==S_IFIFO) +#elif defined(_S_IFMT) && defined(S_IFIFO) +#define S_ISFIFO(mode) ((mode & _S_IFMT)==S_IFIFO) +#endif +#endif + +#if !defined(S_ISFIFO) && !defined(S_ISSOCK) +#error You need to define S_ISFIFO and S_ISSOCK as appropriate for your platform. See . +#endif + +#ifndef S_ISFIFO +#define S_ISFIFO(mode) 0 +#endif + +#ifndef S_ISSOCK +#define S_ISSOCK(mode) 0 +#endif + + if (active) { + if (stat(sockaddr->type.sunix.sun_path, &sb) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + "isc_socket_cleanunix: stat(%s): %s", + sockaddr->type.sunix.sun_path, strbuf); + return; + } + if (!(S_ISSOCK(sb.st_mode) || S_ISFIFO(sb.st_mode))) { + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + "isc_socket_cleanunix: %s: not a socket", + sockaddr->type.sunix.sun_path); + return; + } + if (unlink(sockaddr->type.sunix.sun_path) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + "isc_socket_cleanunix: unlink(%s): %s", + sockaddr->type.sunix.sun_path, strbuf); + } + return; + } + + s = socket(AF_UNIX, SOCK_STREAM, 0); + if (s < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_WARNING, + "isc_socket_cleanunix: socket(%s): %s", + sockaddr->type.sunix.sun_path, strbuf); + return; + } + + if (stat(sockaddr->type.sunix.sun_path, &sb) < 0) { + switch (errno) { + case ENOENT: /* We exited cleanly last time */ + break; + default: + isc__strerror(errno, strbuf, sizeof(strbuf)); + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_WARNING, + "isc_socket_cleanunix: stat(%s): %s", + sockaddr->type.sunix.sun_path, strbuf); + break; + } + goto cleanup; + } + + if (!(S_ISSOCK(sb.st_mode) || S_ISFIFO(sb.st_mode))) { + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_WARNING, + "isc_socket_cleanunix: %s: not a socket", + sockaddr->type.sunix.sun_path); + goto cleanup; + } + + if (connect(s, (struct sockaddr *)&sockaddr->type.sunix, + sizeof(sockaddr->type.sunix)) < 0) { + switch (errno) { + case ECONNREFUSED: + case ECONNRESET: + if (unlink(sockaddr->type.sunix.sun_path) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, + ISC_LOG_WARNING, + "isc_socket_cleanunix: " + "unlink(%s): %s", + sockaddr->type.sunix.sun_path, + strbuf); + } + break; + default: + isc__strerror(errno, strbuf, sizeof(strbuf)); + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_WARNING, + "isc_socket_cleanunix: connect(%s): %s", + sockaddr->type.sunix.sun_path, strbuf); + break; + } + } + cleanup: + close(s); +#else + UNUSED(sockaddr); + UNUSED(active); +#endif +} + +isc_result_t +isc_socket_permunix(isc_sockaddr_t *sockaddr, isc_uint32_t perm, + isc_uint32_t owner, isc_uint32_t group) +{ +#ifdef ISC_PLATFORM_HAVESYSUNH + isc_result_t result = ISC_R_SUCCESS; + char strbuf[ISC_STRERRORSIZE]; + char path[sizeof(sockaddr->type.sunix.sun_path)]; +#ifdef NEED_SECURE_DIRECTORY + char *slash; +#endif + + REQUIRE(sockaddr->type.sa.sa_family == AF_UNIX); + INSIST(strlen(sockaddr->type.sunix.sun_path) < sizeof(path)); + strcpy(path, sockaddr->type.sunix.sun_path); + +#ifdef NEED_SECURE_DIRECTORY + slash = strrchr(path, '/'); + if (slash != NULL) { + if (slash != path) + *slash = '\0'; + else + strcpy(path, "/"); + } else + strcpy(path, "."); +#endif + + if (chmod(path, perm) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + "isc_socket_permunix: chmod(%s, %d): %s", + path, perm, strbuf); + result = ISC_R_FAILURE; + } + if (chown(path, owner, group) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + "isc_socket_permunix: chown(%s, %d, %d): %s", + path, owner, group, + strbuf); + result = ISC_R_FAILURE; + } + return (result); +#else + UNUSED(sockaddr); + UNUSED(perm); + UNUSED(owner); + UNUSED(group); + return (ISC_R_NOTIMPLEMENTED); +#endif +} + +isc_result_t +isc_socket_bind(isc_socket_t *sock, isc_sockaddr_t *sockaddr, + unsigned int options) { + char strbuf[ISC_STRERRORSIZE]; + int on = 1; + + LOCK(&sock->lock); + + INSIST(!sock->bound); + + if (sock->pf != sockaddr->type.sa.sa_family) { + UNLOCK(&sock->lock); + return (ISC_R_FAMILYMISMATCH); + } + /* + * Only set SO_REUSEADDR when we want a specific port. + */ +#ifdef AF_UNIX + if (sock->pf == AF_UNIX) + goto bind_socket; +#endif + if ((options & ISC_SOCKET_REUSEADDRESS) != 0 && + isc_sockaddr_getport(sockaddr) != (in_port_t)0 && + setsockopt(sock->fd, SOL_SOCKET, SO_REUSEADDR, (void *)&on, + sizeof(on)) < 0) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "setsockopt(%d) %s", sock->fd, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + /* Press on... */ + } +#ifdef AF_UNIX + bind_socket: +#endif + if (bind(sock->fd, &sockaddr->type.sa, sockaddr->length) < 0) { + inc_stats(sock->manager->stats, + sock->statsindex[STATID_BINDFAIL]); + + UNLOCK(&sock->lock); + switch (errno) { + case EACCES: + return (ISC_R_NOPERM); + case EADDRNOTAVAIL: + return (ISC_R_ADDRNOTAVAIL); + case EADDRINUSE: + return (ISC_R_ADDRINUSE); + case EINVAL: + return (ISC_R_BOUND); + default: + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, "bind: %s", + strbuf); + return (ISC_R_UNEXPECTED); + } + } + + socket_log(sock, sockaddr, TRACE, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_BOUND, "bound"); + sock->bound = 1; + + UNLOCK(&sock->lock); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_socket_filter(isc_socket_t *sock, const char *filter) { +#ifdef SO_ACCEPTFILTER + char strbuf[ISC_STRERRORSIZE]; + struct accept_filter_arg afa; +#else + UNUSED(sock); + UNUSED(filter); +#endif + + REQUIRE(VALID_SOCKET(sock)); + +#ifdef SO_ACCEPTFILTER + bzero(&afa, sizeof(afa)); + strncpy(afa.af_name, filter, sizeof(afa.af_name)); + if (setsockopt(sock->fd, SOL_SOCKET, SO_ACCEPTFILTER, + &afa, sizeof(afa)) == -1) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + socket_log(sock, NULL, CREATION, isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_FILTER, "setsockopt(SO_ACCEPTFILTER): %s", + strbuf); + return (ISC_R_FAILURE); + } + return (ISC_R_SUCCESS); +#else + return (ISC_R_NOTIMPLEMENTED); +#endif +} + +/* + * Set up to listen on a given socket. We do this by creating an internal + * event that will be dispatched when the socket has read activity. The + * watcher will send the internal event to the task when there is a new + * connection. + * + * Unlike in read, we don't preallocate a done event here. Every time there + * is a new connection we'll have to allocate a new one anyway, so we might + * as well keep things simple rather than having to track them. + */ +isc_result_t +isc_socket_listen(isc_socket_t *sock, unsigned int backlog) { + char strbuf[ISC_STRERRORSIZE]; + + REQUIRE(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + + REQUIRE(!sock->listener); + REQUIRE(sock->bound); + REQUIRE(sock->type == isc_sockettype_tcp || + sock->type == isc_sockettype_unix); + + if (backlog == 0) + backlog = SOMAXCONN; + + if (listen(sock->fd, (int)backlog) < 0) { + UNLOCK(&sock->lock); + isc__strerror(errno, strbuf, sizeof(strbuf)); + + UNEXPECTED_ERROR(__FILE__, __LINE__, "listen: %s", strbuf); + + return (ISC_R_UNEXPECTED); + } + + sock->listener = 1; + + UNLOCK(&sock->lock); + return (ISC_R_SUCCESS); +} + +/* + * This should try to do aggressive accept() XXXMLG + */ +isc_result_t +isc_socket_accept(isc_socket_t *sock, + isc_task_t *task, isc_taskaction_t action, const void *arg) +{ + isc_socket_newconnev_t *dev; + isc_socketmgr_t *manager; + isc_task_t *ntask = NULL; + isc_socket_t *nsock; + isc_result_t result; + isc_boolean_t do_poke = ISC_FALSE; + + REQUIRE(VALID_SOCKET(sock)); + manager = sock->manager; + REQUIRE(VALID_MANAGER(manager)); + + LOCK(&sock->lock); + + REQUIRE(sock->listener); + + /* + * Sender field is overloaded here with the task we will be sending + * this event to. Just before the actual event is delivered the + * actual ev_sender will be touched up to be the socket. + */ + dev = (isc_socket_newconnev_t *) + isc_event_allocate(manager->mctx, task, ISC_SOCKEVENT_NEWCONN, + action, arg, sizeof(*dev)); + if (dev == NULL) { + UNLOCK(&sock->lock); + return (ISC_R_NOMEMORY); + } + ISC_LINK_INIT(dev, ev_link); + + result = allocate_socket(manager, sock->type, &nsock); + if (result != ISC_R_SUCCESS) { + isc_event_free(ISC_EVENT_PTR(&dev)); + UNLOCK(&sock->lock); + return (result); + } + + /* + * Attach to socket and to task. + */ + isc_task_attach(task, &ntask); + nsock->references++; + nsock->statsindex = sock->statsindex; + + dev->ev_sender = ntask; + dev->newsocket = nsock; + + /* + * Poke watcher here. We still have the socket locked, so there + * is no race condition. We will keep the lock for such a short + * bit of time waking it up now or later won't matter all that much. + */ + if (ISC_LIST_EMPTY(sock->accept_list)) + do_poke = ISC_TRUE; + + ISC_LIST_ENQUEUE(sock->accept_list, dev, ev_link); + + if (do_poke) + select_poke(manager, sock->fd, SELECT_POKE_ACCEPT); + + UNLOCK(&sock->lock); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_socket_connect(isc_socket_t *sock, isc_sockaddr_t *addr, + isc_task_t *task, isc_taskaction_t action, const void *arg) +{ + isc_socket_connev_t *dev; + isc_task_t *ntask = NULL; + isc_socketmgr_t *manager; + int cc; + char strbuf[ISC_STRERRORSIZE]; + + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(addr != NULL); + REQUIRE(task != NULL); + REQUIRE(action != NULL); + + manager = sock->manager; + REQUIRE(VALID_MANAGER(manager)); + REQUIRE(addr != NULL); + + if (isc_sockaddr_ismulticast(addr)) + return (ISC_R_MULTICAST); + + LOCK(&sock->lock); + + REQUIRE(!sock->connecting); + + dev = (isc_socket_connev_t *)isc_event_allocate(manager->mctx, sock, + ISC_SOCKEVENT_CONNECT, + action, arg, + sizeof(*dev)); + if (dev == NULL) { + UNLOCK(&sock->lock); + return (ISC_R_NOMEMORY); + } + ISC_LINK_INIT(dev, ev_link); + + /* + * Try to do the connect right away, as there can be only one + * outstanding, and it might happen to complete. + */ + sock->peer_address = *addr; + cc = connect(sock->fd, &addr->type.sa, addr->length); + if (cc < 0) { + /* + * HP-UX "fails" to connect a UDP socket and sets errno to + * EINPROGRESS if it's non-blocking. We'd rather regard this as + * a success and let the user detect it if it's really an error + * at the time of sending a packet on the socket. + */ + if (sock->type == isc_sockettype_udp && errno == EINPROGRESS) { + cc = 0; + goto success; + } + if (SOFT_ERROR(errno) || errno == EINPROGRESS) + goto queue; + + switch (errno) { +#define ERROR_MATCH(a, b) case a: dev->result = b; goto err_exit; + ERROR_MATCH(EACCES, ISC_R_NOPERM); + ERROR_MATCH(EADDRNOTAVAIL, ISC_R_ADDRNOTAVAIL); + ERROR_MATCH(EAFNOSUPPORT, ISC_R_ADDRNOTAVAIL); + ERROR_MATCH(ECONNREFUSED, ISC_R_CONNREFUSED); + ERROR_MATCH(EHOSTUNREACH, ISC_R_HOSTUNREACH); +#ifdef EHOSTDOWN + ERROR_MATCH(EHOSTDOWN, ISC_R_HOSTUNREACH); +#endif + ERROR_MATCH(ENETUNREACH, ISC_R_NETUNREACH); + ERROR_MATCH(ENOBUFS, ISC_R_NORESOURCES); + ERROR_MATCH(EPERM, ISC_R_HOSTUNREACH); + ERROR_MATCH(EPIPE, ISC_R_NOTCONNECTED); + ERROR_MATCH(ECONNRESET, ISC_R_CONNECTIONRESET); +#undef ERROR_MATCH + } + + sock->connected = 0; + + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, "%d/%s", errno, strbuf); + + UNLOCK(&sock->lock); + inc_stats(sock->manager->stats, + sock->statsindex[STATID_CONNECTFAIL]); + isc_event_free(ISC_EVENT_PTR(&dev)); + return (ISC_R_UNEXPECTED); + + err_exit: + sock->connected = 0; + isc_task_send(task, ISC_EVENT_PTR(&dev)); + + UNLOCK(&sock->lock); + inc_stats(sock->manager->stats, + sock->statsindex[STATID_CONNECTFAIL]); + return (ISC_R_SUCCESS); + } + + /* + * If connect completed, fire off the done event. + */ + success: + if (cc == 0) { + sock->connected = 1; + sock->bound = 1; + dev->result = ISC_R_SUCCESS; + isc_task_send(task, ISC_EVENT_PTR(&dev)); + + UNLOCK(&sock->lock); + + inc_stats(sock->manager->stats, + sock->statsindex[STATID_CONNECT]); + + return (ISC_R_SUCCESS); + } + + queue: + + /* + * Attach to task. + */ + isc_task_attach(task, &ntask); + + sock->connecting = 1; + + dev->ev_sender = ntask; + + /* + * Poke watcher here. We still have the socket locked, so there + * is no race condition. We will keep the lock for such a short + * bit of time waking it up now or later won't matter all that much. + */ + if (sock->connect_ev == NULL) + select_poke(manager, sock->fd, SELECT_POKE_CONNECT); + + sock->connect_ev = dev; + + UNLOCK(&sock->lock); + return (ISC_R_SUCCESS); +} + +/* + * Called when a socket with a pending connect() finishes. + */ +static void +internal_connect(isc_task_t *me, isc_event_t *ev) { + isc_socket_t *sock; + isc_socket_connev_t *dev; + isc_task_t *task; + int cc; + ISC_SOCKADDR_LEN_T optlen; + char strbuf[ISC_STRERRORSIZE]; + char peerbuf[ISC_SOCKADDR_FORMATSIZE]; + + UNUSED(me); + INSIST(ev->ev_type == ISC_SOCKEVENT_INTW); + + sock = ev->ev_sender; + INSIST(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + + /* + * When the internal event was sent the reference count was bumped + * to keep the socket around for us. Decrement the count here. + */ + INSIST(sock->references > 0); + sock->references--; + if (sock->references == 0) { + UNLOCK(&sock->lock); + destroy(&sock); + return; + } + + /* + * Has this event been canceled? + */ + dev = sock->connect_ev; + if (dev == NULL) { + INSIST(!sock->connecting); + UNLOCK(&sock->lock); + return; + } + + INSIST(sock->connecting); + sock->connecting = 0; + + /* + * Get any possible error status here. + */ + optlen = sizeof(cc); + if (getsockopt(sock->fd, SOL_SOCKET, SO_ERROR, + (void *)&cc, (void *)&optlen) < 0) + cc = errno; + else + errno = cc; + + if (errno != 0) { + /* + * If the error is EAGAIN, just re-select on this + * fd and pretend nothing strange happened. + */ + if (SOFT_ERROR(errno) || errno == EINPROGRESS) { + sock->connecting = 1; + select_poke(sock->manager, sock->fd, + SELECT_POKE_CONNECT); + UNLOCK(&sock->lock); + + return; + } + + inc_stats(sock->manager->stats, + sock->statsindex[STATID_CONNECTFAIL]); + + /* + * Translate other errors into ISC_R_* flavors. + */ + switch (errno) { +#define ERROR_MATCH(a, b) case a: dev->result = b; break; + ERROR_MATCH(EACCES, ISC_R_NOPERM); + ERROR_MATCH(EADDRNOTAVAIL, ISC_R_ADDRNOTAVAIL); + ERROR_MATCH(EAFNOSUPPORT, ISC_R_ADDRNOTAVAIL); + ERROR_MATCH(ECONNREFUSED, ISC_R_CONNREFUSED); + ERROR_MATCH(EHOSTUNREACH, ISC_R_HOSTUNREACH); +#ifdef EHOSTDOWN + ERROR_MATCH(EHOSTDOWN, ISC_R_HOSTUNREACH); +#endif + ERROR_MATCH(ENETUNREACH, ISC_R_NETUNREACH); + ERROR_MATCH(ENOBUFS, ISC_R_NORESOURCES); + ERROR_MATCH(EPERM, ISC_R_HOSTUNREACH); + ERROR_MATCH(EPIPE, ISC_R_NOTCONNECTED); + ERROR_MATCH(ETIMEDOUT, ISC_R_TIMEDOUT); + ERROR_MATCH(ECONNRESET, ISC_R_CONNECTIONRESET); +#undef ERROR_MATCH + default: + dev->result = ISC_R_UNEXPECTED; + isc_sockaddr_format(&sock->peer_address, peerbuf, + sizeof(peerbuf)); + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "internal_connect: connect(%s) %s", + peerbuf, strbuf); + } + } else { + inc_stats(sock->manager->stats, + sock->statsindex[STATID_CONNECT]); + dev->result = ISC_R_SUCCESS; + sock->connected = 1; + sock->bound = 1; + } + + sock->connect_ev = NULL; + + UNLOCK(&sock->lock); + + task = dev->ev_sender; + dev->ev_sender = sock; + isc_task_sendanddetach(&task, ISC_EVENT_PTR(&dev)); +} + +isc_result_t +isc_socket_getpeername(isc_socket_t *sock, isc_sockaddr_t *addressp) { + isc_result_t result; + + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(addressp != NULL); + + LOCK(&sock->lock); + + if (sock->connected) { + *addressp = sock->peer_address; + result = ISC_R_SUCCESS; + } else { + result = ISC_R_NOTCONNECTED; + } + + UNLOCK(&sock->lock); + + return (result); +} + +isc_result_t +isc_socket_getsockname(isc_socket_t *sock, isc_sockaddr_t *addressp) { + ISC_SOCKADDR_LEN_T len; + isc_result_t result; + char strbuf[ISC_STRERRORSIZE]; + + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(addressp != NULL); + + LOCK(&sock->lock); + + if (!sock->bound) { + result = ISC_R_NOTBOUND; + goto out; + } + + result = ISC_R_SUCCESS; + + len = sizeof(addressp->type); + if (getsockname(sock->fd, &addressp->type.sa, (void *)&len) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, "getsockname: %s", + strbuf); + result = ISC_R_UNEXPECTED; + goto out; + } + addressp->length = (unsigned int)len; + + out: + UNLOCK(&sock->lock); + + return (result); +} + +/* + * Run through the list of events on this socket, and cancel the ones + * queued for task "task" of type "how". "how" is a bitmask. + */ +void +isc_socket_cancel(isc_socket_t *sock, isc_task_t *task, unsigned int how) { + + REQUIRE(VALID_SOCKET(sock)); + + /* + * Quick exit if there is nothing to do. Don't even bother locking + * in this case. + */ + if (how == 0) + return; + + LOCK(&sock->lock); + + /* + * All of these do the same thing, more or less. + * Each will: + * o If the internal event is marked as "posted" try to + * remove it from the task's queue. If this fails, mark it + * as canceled instead, and let the task clean it up later. + * o For each I/O request for that task of that type, post + * its done event with status of "ISC_R_CANCELED". + * o Reset any state needed. + */ + if (((how & ISC_SOCKCANCEL_RECV) == ISC_SOCKCANCEL_RECV) + && !ISC_LIST_EMPTY(sock->recv_list)) { + isc_socketevent_t *dev; + isc_socketevent_t *next; + isc_task_t *current_task; + + dev = ISC_LIST_HEAD(sock->recv_list); + + while (dev != NULL) { + current_task = dev->ev_sender; + next = ISC_LIST_NEXT(dev, ev_link); + + if ((task == NULL) || (task == current_task)) { + dev->result = ISC_R_CANCELED; + send_recvdone_event(sock, &dev); + } + dev = next; + } + } + + if (((how & ISC_SOCKCANCEL_SEND) == ISC_SOCKCANCEL_SEND) + && !ISC_LIST_EMPTY(sock->send_list)) { + isc_socketevent_t *dev; + isc_socketevent_t *next; + isc_task_t *current_task; + + dev = ISC_LIST_HEAD(sock->send_list); + + while (dev != NULL) { + current_task = dev->ev_sender; + next = ISC_LIST_NEXT(dev, ev_link); + + if ((task == NULL) || (task == current_task)) { + dev->result = ISC_R_CANCELED; + send_senddone_event(sock, &dev); + } + dev = next; + } + } + + if (((how & ISC_SOCKCANCEL_ACCEPT) == ISC_SOCKCANCEL_ACCEPT) + && !ISC_LIST_EMPTY(sock->accept_list)) { + isc_socket_newconnev_t *dev; + isc_socket_newconnev_t *next; + isc_task_t *current_task; + + dev = ISC_LIST_HEAD(sock->accept_list); + while (dev != NULL) { + current_task = dev->ev_sender; + next = ISC_LIST_NEXT(dev, ev_link); + + if ((task == NULL) || (task == current_task)) { + + ISC_LIST_UNLINK(sock->accept_list, dev, + ev_link); + + dev->newsocket->references--; + free_socket(&dev->newsocket); + + dev->result = ISC_R_CANCELED; + dev->ev_sender = sock; + isc_task_sendanddetach(¤t_task, + ISC_EVENT_PTR(&dev)); + } + + dev = next; + } + } + + /* + * Connecting is not a list. + */ + if (((how & ISC_SOCKCANCEL_CONNECT) == ISC_SOCKCANCEL_CONNECT) + && sock->connect_ev != NULL) { + isc_socket_connev_t *dev; + isc_task_t *current_task; + + INSIST(sock->connecting); + sock->connecting = 0; + + dev = sock->connect_ev; + current_task = dev->ev_sender; + + if ((task == NULL) || (task == current_task)) { + sock->connect_ev = NULL; + + dev->result = ISC_R_CANCELED; + dev->ev_sender = sock; + isc_task_sendanddetach(¤t_task, + ISC_EVENT_PTR(&dev)); + } + } + + UNLOCK(&sock->lock); +} + +isc_sockettype_t +isc_socket_gettype(isc_socket_t *sock) { + REQUIRE(VALID_SOCKET(sock)); + + return (sock->type); +} + +isc_boolean_t +isc_socket_isbound(isc_socket_t *sock) { + isc_boolean_t val; + + LOCK(&sock->lock); + val = ((sock->bound) ? ISC_TRUE : ISC_FALSE); + UNLOCK(&sock->lock); + + return (val); +} + +void +isc_socket_ipv6only(isc_socket_t *sock, isc_boolean_t yes) { +#if defined(IPV6_V6ONLY) + int onoff = yes ? 1 : 0; +#else + UNUSED(yes); + UNUSED(sock); +#endif + + REQUIRE(VALID_SOCKET(sock)); + +#ifdef IPV6_V6ONLY + if (sock->pf == AF_INET6) { + if (setsockopt(sock->fd, IPPROTO_IPV6, IPV6_V6ONLY, + (void *)&onoff, sizeof(int)) < 0) { + char strbuf[ISC_STRERRORSIZE]; + + UNEXPECTED_ERROR(__FILE__, __LINE__, + "setsockopt(%d, IPV6_V6ONLY) " + "%s: %s", sock->fd, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + } + } + FIX_IPV6_RECVPKTINFO(sock); /* AIX */ +#endif +} + +#ifndef ISC_PLATFORM_USETHREADS +/* In our assumed scenario, we can simply use a single static object. */ +static isc_socketwait_t swait_private; + +int +isc__socketmgr_waitevents(struct timeval *tvp, isc_socketwait_t **swaitp) { + int n; +#ifdef USE_KQUEUE + struct timespec ts, *tsp; +#endif +#ifdef USE_EPOLL + int timeout; +#endif +#ifdef USE_DEVPOLL + struct dvpoll dvp; +#endif + + REQUIRE(swaitp != NULL && *swaitp == NULL); + + if (socketmgr == NULL) + return (0); + +#ifdef USE_KQUEUE + if (tvp != NULL) { + ts.tv_sec = tvp->tv_sec; + ts.tv_nsec = tvp->tv_usec * 1000; + tsp = &ts; + } else + tsp = NULL; + swait_private.nevents = kevent(socketmgr->kqueue_fd, NULL, 0, + socketmgr->events, socketmgr->nevents, + tsp); + n = swait_private.nevents; +#elif defined(USE_EPOLL) + if (tvp != NULL) + timeout = tvp->tv_sec * 1000 + (tvp->tv_usec + 999) / 1000; + else + timeout = -1; + swait_private.nevents = epoll_wait(socketmgr->epoll_fd, + socketmgr->events, + socketmgr->nevents, timeout); + n = swait_private.nevents; +#elif defined(USE_DEVPOLL) + dvp.dp_fds = socketmgr->events; + dvp.dp_nfds = socketmgr->nevents; + if (tvp != NULL) { + dvp.dp_timeout = tvp->tv_sec * 1000 + + (tvp->tv_usec + 999) / 1000; + } else + dvp.dp_timeout = -1; + swait_private.nevents = ioctl(socketmgr->devpoll_fd, DP_POLL, &dvp); + n = swait_private.nevents; +#elif defined(USE_SELECT) + memcpy(socketmgr->read_fds_copy, socketmgr->read_fds, + socketmgr->fd_bufsize); + memcpy(socketmgr->write_fds_copy, socketmgr->write_fds, + socketmgr->fd_bufsize); + + swait_private.readset = socketmgr->read_fds_copy; + swait_private.writeset = socketmgr->write_fds_copy; + swait_private.maxfd = socketmgr->maxfd + 1; + + n = select(swait_private.maxfd, swait_private.readset, + swait_private.writeset, NULL, tvp); +#endif + + *swaitp = &swait_private; + return (n); +} + +isc_result_t +isc__socketmgr_dispatch(isc_socketwait_t *swait) { + REQUIRE(swait == &swait_private); + + if (socketmgr == NULL) + return (ISC_R_NOTFOUND); + +#if defined(USE_KQUEUE) || defined(USE_EPOLL) || defined(USE_DEVPOLL) + (void)process_fds(socketmgr, socketmgr->events, swait->nevents); + return (ISC_R_SUCCESS); +#elif defined(USE_SELECT) + process_fds(socketmgr, swait->maxfd, swait->readset, swait->writeset); + return (ISC_R_SUCCESS); +#endif +} +#endif /* ISC_PLATFORM_USETHREADS */ + +void +isc_socket_setname(isc_socket_t *socket, const char *name, void *tag) { + + /* + * Name 'socket'. + */ + + REQUIRE(VALID_SOCKET(socket)); + + LOCK(&socket->lock); + memset(socket->name, 0, sizeof(socket->name)); + strncpy(socket->name, name, sizeof(socket->name) - 1); + socket->tag = tag; + UNLOCK(&socket->lock); +} + +const char * +isc_socket_getname(isc_socket_t *socket) { + return (socket->name); +} + +void * +isc_socket_gettag(isc_socket_t *socket) { + return (socket->tag); +} + +#ifdef HAVE_LIBXML2 + +static const char * +_socktype(isc_sockettype_t type) +{ + if (type == isc_sockettype_udp) + return ("udp"); + else if (type == isc_sockettype_tcp) + return ("tcp"); + else if (type == isc_sockettype_unix) + return ("unix"); + else if (type == isc_sockettype_fdwatch) + return ("fdwatch"); + else + return ("not-initialized"); +} + +void +isc_socketmgr_renderxml(isc_socketmgr_t *mgr, xmlTextWriterPtr writer) +{ + isc_socket_t *sock; + char peerbuf[ISC_SOCKADDR_FORMATSIZE]; + isc_sockaddr_t addr; + ISC_SOCKADDR_LEN_T len; + + LOCK(&mgr->lock); + +#ifndef ISC_PLATFORM_USETHREADS + xmlTextWriterStartElement(writer, ISC_XMLCHAR "references"); + xmlTextWriterWriteFormatString(writer, "%d", mgr->refs); + xmlTextWriterEndElement(writer); +#endif + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "sockets"); + sock = ISC_LIST_HEAD(mgr->socklist); + while (sock != NULL) { + LOCK(&sock->lock); + xmlTextWriterStartElement(writer, ISC_XMLCHAR "socket"); + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "id"); + xmlTextWriterWriteFormatString(writer, "%p", sock); + xmlTextWriterEndElement(writer); + + if (sock->name[0] != 0) { + xmlTextWriterStartElement(writer, ISC_XMLCHAR "name"); + xmlTextWriterWriteFormatString(writer, "%s", + sock->name); + xmlTextWriterEndElement(writer); /* name */ + } + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "references"); + xmlTextWriterWriteFormatString(writer, "%d", sock->references); + xmlTextWriterEndElement(writer); + + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "type", + ISC_XMLCHAR _socktype(sock->type)); + + if (sock->connected) { + isc_sockaddr_format(&sock->peer_address, peerbuf, + sizeof(peerbuf)); + xmlTextWriterWriteElement(writer, + ISC_XMLCHAR "peer-address", + ISC_XMLCHAR peerbuf); + } + + len = sizeof(addr); + if (getsockname(sock->fd, &addr.type.sa, (void *)&len) == 0) { + isc_sockaddr_format(&addr, peerbuf, sizeof(peerbuf)); + xmlTextWriterWriteElement(writer, + ISC_XMLCHAR "local-address", + ISC_XMLCHAR peerbuf); + } + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "states"); + if (sock->pending_recv) + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "state", + ISC_XMLCHAR "pending-receive"); + if (sock->pending_send) + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "state", + ISC_XMLCHAR "pending-send"); + if (sock->pending_accept) + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "state", + ISC_XMLCHAR "pending_accept"); + if (sock->listener) + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "state", + ISC_XMLCHAR "listener"); + if (sock->connected) + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "state", + ISC_XMLCHAR "connected"); + if (sock->connecting) + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "state", + ISC_XMLCHAR "connecting"); + if (sock->bound) + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "state", + ISC_XMLCHAR "bound"); + + xmlTextWriterEndElement(writer); /* states */ + + xmlTextWriterEndElement(writer); /* socket */ + + UNLOCK(&sock->lock); + sock = ISC_LIST_NEXT(sock, link); + } + xmlTextWriterEndElement(writer); /* sockets */ + + UNLOCK(&mgr->lock); +} +#endif /* HAVE_LIBXML2 */ diff -urN src/contrib/ntp/lib/isc/unix/socket_p.h src.ntp/contrib/ntp/lib/isc/unix/socket_p.h --- src/contrib/ntp/lib/isc/unix/socket_p.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/socket_p.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: socket_p.h,v 1.13 2008/06/23 23:47:11 tbox Exp $ */ + +#ifndef ISC_SOCKET_P_H +#define ISC_SOCKET_P_H + +/*! \file */ + +#ifdef ISC_PLATFORM_NEEDSYSSELECTH +#include +#endif + +typedef struct isc_socketwait isc_socketwait_t; +int isc__socketmgr_waitevents(struct timeval *, isc_socketwait_t **); +isc_result_t isc__socketmgr_dispatch(isc_socketwait_t *); +#endif /* ISC_SOCKET_P_H */ diff -urN src/contrib/ntp/lib/isc/unix/stdio.c src.ntp/contrib/ntp/lib/isc/unix/stdio.c --- src/contrib/ntp/lib/isc/unix/stdio.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/stdio.c 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,117 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: stdio.c,v 1.8 2007/06/19 23:47:18 tbox Exp $ */ + +#include + +#include +#include + +#include + +#include "errno2result.h" + +isc_result_t +isc_stdio_open(const char *filename, const char *mode, FILE **fp) { + FILE *f; + + f = fopen(filename, mode); + if (f == NULL) + return (isc__errno2result(errno)); + *fp = f; + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_stdio_close(FILE *f) { + int r; + + r = fclose(f); + if (r == 0) + return (ISC_R_SUCCESS); + else + return (isc__errno2result(errno)); +} + +isc_result_t +isc_stdio_seek(FILE *f, long offset, int whence) { + int r; + + r = fseek(f, offset, whence); + if (r == 0) + return (ISC_R_SUCCESS); + else + return (isc__errno2result(errno)); +} + +isc_result_t +isc_stdio_read(void *ptr, size_t size, size_t nmemb, FILE *f, size_t *nret) { + isc_result_t result = ISC_R_SUCCESS; + size_t r; + + clearerr(f); + r = fread(ptr, size, nmemb, f); + if (r != nmemb) { + if (feof(f)) + result = ISC_R_EOF; + else + result = isc__errno2result(errno); + } + if (nret != NULL) + *nret = r; + return (result); +} + +isc_result_t +isc_stdio_write(const void *ptr, size_t size, size_t nmemb, FILE *f, + size_t *nret) +{ + isc_result_t result = ISC_R_SUCCESS; + size_t r; + + clearerr(f); + r = fwrite(ptr, size, nmemb, f); + if (r != nmemb) + result = isc__errno2result(errno); + if (nret != NULL) + *nret = r; + return (result); +} + +isc_result_t +isc_stdio_flush(FILE *f) { + int r; + + r = fflush(f); + if (r == 0) + return (ISC_R_SUCCESS); + else + return (isc__errno2result(errno)); +} + +isc_result_t +isc_stdio_sync(FILE *f) { + int r; + + r = fsync(fileno(f)); + if (r == 0) + return (ISC_R_SUCCESS); + else + return (isc__errno2result(errno)); +} + diff -urN src/contrib/ntp/lib/isc/unix/stdtime.c src.ntp/contrib/ntp/lib/isc/unix/stdtime.c --- src/contrib/ntp/lib/isc/unix/stdtime.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/stdtime.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,86 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: stdtime.c,v 1.19 2007/06/19 23:47:18 tbox Exp $ */ + +/*! \file */ + +#include + +#include /* NULL */ +#include /* NULL */ +#include + +#include + +#include +#include + +#ifndef ISC_FIX_TV_USEC +#define ISC_FIX_TV_USEC 1 +#endif + +#define US_PER_S 1000000 + +#if ISC_FIX_TV_USEC +static inline void +fix_tv_usec(struct timeval *tv) { + isc_boolean_t fixed = ISC_FALSE; + + if (tv->tv_usec < 0) { + fixed = ISC_TRUE; + do { + tv->tv_sec -= 1; + tv->tv_usec += US_PER_S; + } while (tv->tv_usec < 0); + } else if (tv->tv_usec >= US_PER_S) { + fixed = ISC_TRUE; + do { + tv->tv_sec += 1; + tv->tv_usec -= US_PER_S; + } while (tv->tv_usec >=US_PER_S); + } + /* + * Call syslog directly as we are called from the logging functions. + */ + if (fixed) + (void)syslog(LOG_ERR, "gettimeofday returned bad tv_usec: corrected"); +} +#endif + +void +isc_stdtime_get(isc_stdtime_t *t) { + struct timeval tv; + + /* + * Set 't' to the number of seconds since 00:00:00 UTC, January 1, + * 1970. + */ + + REQUIRE(t != NULL); + + RUNTIME_CHECK(gettimeofday(&tv, NULL) != -1); + +#if ISC_FIX_TV_USEC + fix_tv_usec(&tv); + INSIST(tv.tv_usec >= 0); +#else + INSIST(tv.tv_usec >= 0 && tv.tv_usec < US_PER_S); +#endif + + *t = (unsigned int)tv.tv_sec; +} diff -urN src/contrib/ntp/lib/isc/unix/strerror.c src.ntp/contrib/ntp/lib/isc/unix/strerror.c --- src/contrib/ntp/lib/isc/unix/strerror.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/strerror.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,76 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: strerror.c,v 1.8.332.2 2009/02/16 23:47:15 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include + +#include +#include +#include +#include +#include + +#include "l_stdlib.h" /* NTP local change */ + +#ifdef HAVE_STRERROR +/*% + * We need to do this this way for profiled locks. + */ +static isc_mutex_t isc_strerror_lock; +static void init_lock(void) { + RUNTIME_CHECK(isc_mutex_init(&isc_strerror_lock) == ISC_R_SUCCESS); +} +#else +extern const char * const sys_errlist[]; +extern const int sys_nerr; +#endif + +void +isc__strerror(int num, char *buf, size_t size) { +#ifdef HAVE_STRERROR + char *msg; + unsigned int unum = (unsigned int)num; + static isc_once_t once = ISC_ONCE_INIT; + + REQUIRE(buf != NULL); + + RUNTIME_CHECK(isc_once_do(&once, init_lock) == ISC_R_SUCCESS); + + LOCK(&isc_strerror_lock); + msg = strerror(num); + if (msg != NULL) + snprintf(buf, size, "%s", msg); + else + snprintf(buf, size, "Unknown error: %u", unum); + UNLOCK(&isc_strerror_lock); +#else + unsigned int unum = (unsigned int)num; + + REQUIRE(buf != NULL); + + if (num >= 0 && num < sys_nerr) + snprintf(buf, size, "%s", sys_errlist[num]); + else + snprintf(buf, size, "Unknown error: %u", unum); +#endif +} diff -urN src/contrib/ntp/lib/isc/unix/syslog.c src.ntp/contrib/ntp/lib/isc/unix/syslog.c --- src/contrib/ntp/lib/isc/unix/syslog.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/syslog.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,84 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: syslog.c,v 1.8 2007/09/13 04:45:18 each Exp $ */ + +/*! \file */ + +#include + +#include +#include + +#include +#include +#include +#include + +static struct dsn_c_pvt_sfnt { + int val; + const char *strval; +} facilities[] = { + { LOG_KERN, "kern" }, + { LOG_USER, "user" }, + { LOG_MAIL, "mail" }, + { LOG_DAEMON, "daemon" }, + { LOG_AUTH, "auth" }, + { LOG_SYSLOG, "syslog" }, + { LOG_LPR, "lpr" }, +#ifdef LOG_NEWS + { LOG_NEWS, "news" }, +#endif +#ifdef LOG_UUCP + { LOG_UUCP, "uucp" }, +#endif +#ifdef LOG_CRON + { LOG_CRON, "cron" }, +#endif +#ifdef LOG_AUTHPRIV + { LOG_AUTHPRIV, "authpriv" }, +#endif +#ifdef LOG_FTP + { LOG_FTP, "ftp" }, +#endif + { LOG_LOCAL0, "local0"}, + { LOG_LOCAL1, "local1"}, + { LOG_LOCAL2, "local2"}, + { LOG_LOCAL3, "local3"}, + { LOG_LOCAL4, "local4"}, + { LOG_LOCAL5, "local5"}, + { LOG_LOCAL6, "local6"}, + { LOG_LOCAL7, "local7"}, + { 0, NULL } +}; + +isc_result_t +isc_syslog_facilityfromstring(const char *str, int *facilityp) { + int i; + + REQUIRE(str != NULL); + REQUIRE(facilityp != NULL); + + for (i = 0; facilities[i].strval != NULL; i++) { + if (strcasecmp(facilities[i].strval, str) == 0) { + *facilityp = facilities[i].val; + return (ISC_R_SUCCESS); + } + } + return (ISC_R_NOTFOUND); + +} diff -urN src/contrib/ntp/lib/isc/unix/time.c src.ntp/contrib/ntp/lib/isc/unix/time.c --- src/contrib/ntp/lib/isc/unix/time.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/unix/time.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,438 @@ +/* + * Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: time.c,v 1.56 2008/02/15 23:46:51 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include +#include + +#include /* Required for struct timeval on some platforms. */ + +#include +#include +#include +#include +#include +#include + +#define NS_PER_S 1000000000 /*%< Nanoseconds per second. */ +#define NS_PER_US 1000 /*%< Nanoseconds per microsecond. */ +#define US_PER_S 1000000 /*%< Microseconds per second. */ + +/* + * All of the INSIST()s checks of nanoseconds < NS_PER_S are for + * consistency checking of the type. In lieu of magic numbers, it + * is the best we've got. The check is only performed on functions which + * need an initialized type. + */ + +#ifndef ISC_FIX_TV_USEC +#define ISC_FIX_TV_USEC 1 +#endif + +/*% + *** Intervals + ***/ + +static isc_interval_t zero_interval = { 0, 0 }; +isc_interval_t *isc_interval_zero = &zero_interval; + +#if ISC_FIX_TV_USEC +static inline void +fix_tv_usec(struct timeval *tv) { + isc_boolean_t fixed = ISC_FALSE; + + if (tv->tv_usec < 0) { + fixed = ISC_TRUE; + do { + tv->tv_sec -= 1; + tv->tv_usec += US_PER_S; + } while (tv->tv_usec < 0); + } else if (tv->tv_usec >= US_PER_S) { + fixed = ISC_TRUE; + do { + tv->tv_sec += 1; + tv->tv_usec -= US_PER_S; + } while (tv->tv_usec >=US_PER_S); + } + /* + * Call syslog directly as was are called from the logging functions. + */ + if (fixed) + (void)syslog(LOG_ERR, "gettimeofday returned bad tv_usec: corrected"); +} +#endif + +void +isc_interval_set(isc_interval_t *i, + unsigned int seconds, unsigned int nanoseconds) +{ + REQUIRE(i != NULL); + REQUIRE(nanoseconds < NS_PER_S); + + i->seconds = seconds; + i->nanoseconds = nanoseconds; +} + +isc_boolean_t +isc_interval_iszero(const isc_interval_t *i) { + REQUIRE(i != NULL); + INSIST(i->nanoseconds < NS_PER_S); + + if (i->seconds == 0 && i->nanoseconds == 0) + return (ISC_TRUE); + + return (ISC_FALSE); +} + + +/*** + *** Absolute Times + ***/ + +static isc_time_t epoch = { 0, 0 }; +isc_time_t *isc_time_epoch = &epoch; + +void +isc_time_set(isc_time_t *t, unsigned int seconds, unsigned int nanoseconds) { + REQUIRE(t != NULL); + REQUIRE(nanoseconds < NS_PER_S); + + t->seconds = seconds; + t->nanoseconds = nanoseconds; +} + +void +isc_time_settoepoch(isc_time_t *t) { + REQUIRE(t != NULL); + + t->seconds = 0; + t->nanoseconds = 0; +} + +isc_boolean_t +isc_time_isepoch(const isc_time_t *t) { + REQUIRE(t != NULL); + INSIST(t->nanoseconds < NS_PER_S); + + if (t->seconds == 0 && t->nanoseconds == 0) + return (ISC_TRUE); + + return (ISC_FALSE); +} + + +isc_result_t +isc_time_now(isc_time_t *t) { + struct timeval tv; + char strbuf[ISC_STRERRORSIZE]; + + REQUIRE(t != NULL); + + if (gettimeofday(&tv, NULL) == -1) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, "%s", strbuf); + return (ISC_R_UNEXPECTED); + } + + /* + * Does POSIX guarantee the signedness of tv_sec and tv_usec? If not, + * then this test will generate warnings for platforms on which it is + * unsigned. In any event, the chances of any of these problems + * happening are pretty much zero, but since the libisc library ensures + * certain things to be true ... + */ +#if ISC_FIX_TV_USEC + fix_tv_usec(&tv); + if (tv.tv_sec < 0) + return (ISC_R_UNEXPECTED); +#else + if (tv.tv_sec < 0 || tv.tv_usec < 0 || tv.tv_usec >= US_PER_S) + return (ISC_R_UNEXPECTED); +#endif + + /* + * Ensure the tv_sec value fits in t->seconds. + */ + if (sizeof(tv.tv_sec) > sizeof(t->seconds) && + ((tv.tv_sec | (unsigned int)-1) ^ (unsigned int)-1) != 0U) + return (ISC_R_RANGE); + + t->seconds = tv.tv_sec; + t->nanoseconds = tv.tv_usec * NS_PER_US; + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_time_nowplusinterval(isc_time_t *t, const isc_interval_t *i) { + struct timeval tv; + char strbuf[ISC_STRERRORSIZE]; + + REQUIRE(t != NULL); + REQUIRE(i != NULL); + INSIST(i->nanoseconds < NS_PER_S); + + if (gettimeofday(&tv, NULL) == -1) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, "%s", strbuf); + return (ISC_R_UNEXPECTED); + } + + /* + * Does POSIX guarantee the signedness of tv_sec and tv_usec? If not, + * then this test will generate warnings for platforms on which it is + * unsigned. In any event, the chances of any of these problems + * happening are pretty much zero, but since the libisc library ensures + * certain things to be true ... + */ +#if ISC_FIX_TV_USEC + fix_tv_usec(&tv); + if (tv.tv_sec < 0) + return (ISC_R_UNEXPECTED); +#else + if (tv.tv_sec < 0 || tv.tv_usec < 0 || tv.tv_usec >= US_PER_S) + return (ISC_R_UNEXPECTED); +#endif + + /* + * Ensure the resulting seconds value fits in the size of an + * unsigned int. (It is written this way as a slight optimization; + * note that even if both values == INT_MAX, then when added + * and getting another 1 added below the result is UINT_MAX.) + */ + if ((tv.tv_sec > INT_MAX || i->seconds > INT_MAX) && + ((long long)tv.tv_sec + i->seconds > UINT_MAX)) + return (ISC_R_RANGE); + + t->seconds = tv.tv_sec + i->seconds; + t->nanoseconds = tv.tv_usec * NS_PER_US + i->nanoseconds; + if (t->nanoseconds >= NS_PER_S) { + t->seconds++; + t->nanoseconds -= NS_PER_S; + } + + return (ISC_R_SUCCESS); +} + +int +isc_time_compare(const isc_time_t *t1, const isc_time_t *t2) { + REQUIRE(t1 != NULL && t2 != NULL); + INSIST(t1->nanoseconds < NS_PER_S && t2->nanoseconds < NS_PER_S); + + if (t1->seconds < t2->seconds) + return (-1); + if (t1->seconds > t2->seconds) + return (1); + if (t1->nanoseconds < t2->nanoseconds) + return (-1); + if (t1->nanoseconds > t2->nanoseconds) + return (1); + return (0); +} + +isc_result_t +isc_time_add(const isc_time_t *t, const isc_interval_t *i, isc_time_t *result) +{ + REQUIRE(t != NULL && i != NULL && result != NULL); + INSIST(t->nanoseconds < NS_PER_S && i->nanoseconds < NS_PER_S); + + /* + * Ensure the resulting seconds value fits in the size of an + * unsigned int. (It is written this way as a slight optimization; + * note that even if both values == INT_MAX, then when added + * and getting another 1 added below the result is UINT_MAX.) + */ + if ((t->seconds > INT_MAX || i->seconds > INT_MAX) && + ((long long)t->seconds + i->seconds > UINT_MAX)) + return (ISC_R_RANGE); + + result->seconds = t->seconds + i->seconds; + result->nanoseconds = t->nanoseconds + i->nanoseconds; + if (result->nanoseconds >= NS_PER_S) { + result->seconds++; + result->nanoseconds -= NS_PER_S; + } + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_time_subtract(const isc_time_t *t, const isc_interval_t *i, + isc_time_t *result) +{ + REQUIRE(t != NULL && i != NULL && result != NULL); + INSIST(t->nanoseconds < NS_PER_S && i->nanoseconds < NS_PER_S); + + if ((unsigned int)t->seconds < i->seconds || + ((unsigned int)t->seconds == i->seconds && + t->nanoseconds < i->nanoseconds)) + return (ISC_R_RANGE); + + result->seconds = t->seconds - i->seconds; + if (t->nanoseconds >= i->nanoseconds) + result->nanoseconds = t->nanoseconds - i->nanoseconds; + else { + result->nanoseconds = NS_PER_S - i->nanoseconds + + t->nanoseconds; + result->seconds--; + } + + return (ISC_R_SUCCESS); +} + +isc_uint64_t +isc_time_microdiff(const isc_time_t *t1, const isc_time_t *t2) { + isc_uint64_t i1, i2, i3; + + REQUIRE(t1 != NULL && t2 != NULL); + INSIST(t1->nanoseconds < NS_PER_S && t2->nanoseconds < NS_PER_S); + + i1 = (isc_uint64_t)t1->seconds * NS_PER_S + t1->nanoseconds; + i2 = (isc_uint64_t)t2->seconds * NS_PER_S + t2->nanoseconds; + + if (i1 <= i2) + return (0); + + i3 = i1 - i2; + + /* + * Convert to microseconds. + */ + i3 = (i1 - i2) / NS_PER_US; + + return (i3); +} + +isc_uint32_t +isc_time_seconds(const isc_time_t *t) { + REQUIRE(t != NULL); + INSIST(t->nanoseconds < NS_PER_S); + + return ((isc_uint32_t)t->seconds); +} + +isc_result_t +isc_time_secondsastimet(const isc_time_t *t, time_t *secondsp) { + isc_uint64_t i; + time_t seconds; + + REQUIRE(t != NULL); + INSIST(t->nanoseconds < NS_PER_S); + + /* + * Ensure that the number of seconds represented by t->seconds + * can be represented by a time_t. Since t->seconds is an unsigned + * int and since time_t is mostly opaque, this is trickier than + * it seems. (This standardized opaqueness of time_t is *very* + * frustrating; time_t is not even limited to being an integral + * type.) + * + * The mission, then, is to avoid generating any kind of warning + * about "signed versus unsigned" while trying to determine if the + * the unsigned int t->seconds is out range for tv_sec, which is + * pretty much only true if time_t is a signed integer of the same + * size as the return value of isc_time_seconds. + * + * The use of the 64 bit integer ``i'' takes advantage of C's + * conversion rules to either zero fill or sign extend the widened + * type. + * + * Solaris 5.6 gives this warning about the left shift: + * warning: integer overflow detected: op "<<" + * if the U(nsigned) qualifier is not on the 1. + */ + seconds = (time_t)t->seconds; + + INSIST(sizeof(unsigned int) == sizeof(isc_uint32_t)); + INSIST(sizeof(time_t) >= sizeof(isc_uint32_t)); + + if (sizeof(time_t) == sizeof(isc_uint32_t) && /* Same size. */ + (time_t)0.5 != 0.5 && /* Not a floating point type. */ + (i = (time_t)-1) != 4294967295u && /* Is signed. */ + (seconds & + (1U << (sizeof(time_t) * CHAR_BIT - 1))) != 0U) { /* Negative. */ + /* + * This UNUSED() is here to shut up the IRIX compiler: + * variable "i" was set but never used + * when the value of i *was* used in the third test. + * (Let's hope the compiler got the actual test right.) + */ + UNUSED(i); + return (ISC_R_RANGE); + } + + *secondsp = seconds; + + return (ISC_R_SUCCESS); +} + +isc_uint32_t +isc_time_nanoseconds(const isc_time_t *t) { + REQUIRE(t != NULL); + + ENSURE(t->nanoseconds < NS_PER_S); + + return ((isc_uint32_t)t->nanoseconds); +} + +void +isc_time_formattimestamp(const isc_time_t *t, char *buf, unsigned int len) { + time_t now; + unsigned int flen; + + REQUIRE(len > 0); + + now = (time_t) t->seconds; + flen = strftime(buf, len, "%d-%b-%Y %X", localtime(&now)); + INSIST(flen < len); + if (flen != 0) + snprintf(buf + flen, len - flen, + ".%03u", t->nanoseconds / 1000000); + else + snprintf(buf, len, "99-Bad-9999 99:99:99.999"); +} + +void +isc_time_formathttptimestamp(const isc_time_t *t, char *buf, unsigned int len) { + time_t now; + unsigned int flen; + + REQUIRE(len > 0); + + now = (time_t)t->seconds; + flen = strftime(buf, len, "%a, %d %b %Y %H:%M:%S GMT", gmtime(&now)); + INSIST(flen < len); +} + +void +isc_time_formatISO8601(const isc_time_t *t, char *buf, unsigned int len) { + time_t now; + unsigned int flen; + + REQUIRE(len > 0); + + now = (time_t)t->seconds; + flen = strftime(buf, len, "%Y-%m-%dT%H:%M:%SZ", gmtime(&now)); + INSIST(flen < len); +} diff -urN src/contrib/ntp/lib/isc/version.c src.ntp/contrib/ntp/lib/isc/version.c --- src/contrib/ntp/lib/isc/version.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/version.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,28 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: version.c,v 1.15 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +const char isc_version[] = VERSION; + +const unsigned int isc_libinterface = LIBINTERFACE; +const unsigned int isc_librevision = LIBREVISION; +const unsigned int isc_libage = LIBAGE; diff -urN src/contrib/ntp/lib/isc/x86_32/include/isc/atomic.h src.ntp/contrib/ntp/lib/isc/x86_32/include/isc/atomic.h --- src/contrib/ntp/lib/isc/x86_32/include/isc/atomic.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/x86_32/include/isc/atomic.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,176 @@ +/* + * Copyright (C) 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: atomic.h,v 1.10 2008/01/24 23:47:00 tbox Exp $ */ + +#ifndef ISC_ATOMIC_H +#define ISC_ATOMIC_H 1 + +#include +#include + +#ifdef ISC_PLATFORM_USEGCCASM +/* + * This routine atomically increments the value stored in 'p' by 'val', and + * returns the previous value. + */ +static __inline__ isc_int32_t +isc_atomic_xadd(isc_int32_t *p, isc_int32_t val) { + isc_int32_t prev = val; + + __asm__ volatile( +#ifdef ISC_PLATFORM_USETHREADS + "lock;" +#endif + "xadd %0, %1" + :"=q"(prev) + :"m"(*p), "0"(prev) + :"memory", "cc"); + + return (prev); +} + +#ifdef ISC_PLATFORM_HAVEXADDQ +static __inline__ isc_int64_t +isc_atomic_xaddq(isc_int64_t *p, isc_int64_t val) { + isc_int64_t prev = val; + + __asm__ volatile( +#ifdef ISC_PLATFORM_USETHREADS + "lock;" +#endif + "xaddq %0, %1" + :"=q"(prev) + :"m"(*p), "0"(prev) + :"memory", "cc"); + + return (prev); +} +#endif /* ISC_PLATFORM_HAVEXADDQ */ + +/* + * This routine atomically stores the value 'val' in 'p'. + */ +static __inline__ void +isc_atomic_store(isc_int32_t *p, isc_int32_t val) { + __asm__ volatile( +#ifdef ISC_PLATFORM_USETHREADS + /* + * xchg should automatically lock memory, but we add it + * explicitly just in case (it at least doesn't harm) + */ + "lock;" +#endif + + "xchgl %1, %0" + : + : "r"(val), "m"(*p) + : "memory"); +} + +/* + * This routine atomically replaces the value in 'p' with 'val', if the + * original value is equal to 'cmpval'. The original value is returned in any + * case. + */ +static __inline__ isc_int32_t +isc_atomic_cmpxchg(isc_int32_t *p, isc_int32_t cmpval, isc_int32_t val) { + __asm__ volatile( +#ifdef ISC_PLATFORM_USETHREADS + "lock;" +#endif + "cmpxchgl %1, %2" + : "=a"(cmpval) + : "r"(val), "m"(*p), "a"(cmpval) + : "memory"); + + return (cmpval); +} + +#elif defined(ISC_PLATFORM_USESTDASM) +/* + * The followings are "generic" assembly code which implements the same + * functionality in case the gcc extension cannot be used. It should be + * better to avoid inlining below, since we directly refer to specific + * positions of the stack frame, which would not actually point to the + * intended address in the embedded mnemonic. + */ +#include /* for 'UNUSED' macro */ + +static isc_int32_t +isc_atomic_xadd(isc_int32_t *p, isc_int32_t val) { + UNUSED(p); + UNUSED(val); + + __asm ( + "movl 8(%ebp), %ecx\n" + "movl 12(%ebp), %edx\n" +#ifdef ISC_PLATFORM_USETHREADS + "lock;" +#endif + "xadd %edx, (%ecx)\n" + + /* + * set the return value directly in the register so that we + * can avoid guessing the correct position in the stack for a + * local variable. + */ + "movl %edx, %eax" + ); +} + +static void +isc_atomic_store(isc_int32_t *p, isc_int32_t val) { + UNUSED(p); + UNUSED(val); + + __asm ( + "movl 8(%ebp), %ecx\n" + "movl 12(%ebp), %edx\n" +#ifdef ISC_PLATFORM_USETHREADS + "lock;" +#endif + "xchgl (%ecx), %edx\n" + ); +} + +static isc_int32_t +isc_atomic_cmpxchg(isc_int32_t *p, isc_int32_t cmpval, isc_int32_t val) { + UNUSED(p); + UNUSED(cmpval); + UNUSED(val); + + __asm ( + "movl 8(%ebp), %ecx\n" + "movl 12(%ebp), %eax\n" /* must be %eax for cmpxchgl */ + "movl 16(%ebp), %edx\n" +#ifdef ISC_PLATFORM_USETHREADS + "lock;" +#endif + + /* + * If (%ecx) == %eax then (%ecx) := %edx. + % %eax is set to old (%ecx), which will be the return value. + */ + "cmpxchgl %edx, (%ecx)" + ); +} +#else /* !ISC_PLATFORM_USEGCCASM && !ISC_PLATFORM_USESTDASM */ + +#error "unsupported compiler. disable atomic ops by --disable-atomic" + +#endif +#endif /* ISC_ATOMIC_H */ diff -urN src/contrib/ntp/lib/isc/x86_64/include/isc/atomic.h src.ntp/contrib/ntp/lib/isc/x86_64/include/isc/atomic.h --- src/contrib/ntp/lib/isc/x86_64/include/isc/atomic.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/lib/isc/x86_64/include/isc/atomic.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,123 @@ +/* + * Copyright (C) 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: atomic.h,v 1.6 2008/01/24 23:47:00 tbox Exp $ */ + +#ifndef ISC_ATOMIC_H +#define ISC_ATOMIC_H 1 + +#include +#include + +#ifdef ISC_PLATFORM_USEGCCASM + +/* We share the gcc-version with x86_32 */ +#error "impossible case. check build configuration" + +#elif defined(ISC_PLATFORM_USESTDASM) +/* + * The followings are "generic" assembly code which implements the same + * functionality in case the gcc extension cannot be used. It should be + * better to avoid inlining below, since we directly refer to specific + * registers for arguments, which would not actually correspond to the + * intended address or value in the embedded mnemonic. + */ +#include /* for 'UNUSED' macro */ + +static isc_int32_t +isc_atomic_xadd(isc_int32_t *p, isc_int32_t val) { + UNUSED(p); + UNUSED(val); + + __asm ( + "movq %rdi, %rdx\n" + "movl %esi, %eax\n" +#ifdef ISC_PLATFORM_USETHREADS + "lock;" +#endif + "xadd %eax, (%rdx)\n" + /* + * XXX: assume %eax will be used as the return value. + */ + ); +} + +#ifdef ISC_PLATFORM_HAVEXADDQ +static isc_int64_t +isc_atomic_xaddq(isc_int64_t *p, isc_int64_t val) { + UNUSED(p); + UNUSED(val); + + __asm ( + "movq %rdi, %rdx\n" + "movq %rsi, %rax\n" +#ifdef ISC_PLATFORM_USETHREADS + "lock;" +#endif + "xaddq %rax, (%rdx)\n" + /* + * XXX: assume %rax will be used as the return value. + */ + ); +} +#endif + +static void +isc_atomic_store(isc_int32_t *p, isc_int32_t val) { + UNUSED(p); + UNUSED(val); + + __asm ( + "movq %rdi, %rax\n" + "movl %esi, %edx\n" +#ifdef ISC_PLATFORM_USETHREADS + "lock;" +#endif + "xchgl (%rax), %edx\n" + /* + * XXX: assume %rax will be used as the return value. + */ + ); +} + +static isc_int32_t +isc_atomic_cmpxchg(isc_int32_t *p, isc_int32_t cmpval, isc_int32_t val) { + UNUSED(p); + UNUSED(cmpval); + UNUSED(val); + + __asm ( + "movl %edx, %ecx\n" + "movl %esi, %eax\n" + "movq %rdi, %rdx\n" + +#ifdef ISC_PLATFORM_USETHREADS + "lock;" +#endif + /* + * If (%rdi) == %eax then (%rdi) := %edx. + * %eax is set to old (%ecx), which will be the return value. + */ + "cmpxchgl %ecx, (%rdx)" + ); +} + +#else /* !ISC_PLATFORM_USEGCCASM && !ISC_PLATFORM_USESTDASM */ + +#error "unsupported compiler. disable atomic ops by --disable-atomic" + +#endif +#endif /* ISC_ATOMIC_H */ diff -urN src/contrib/ntp/libisc/assertions.c src.ntp/contrib/ntp/libisc/assertions.c --- src/contrib/ntp/libisc/assertions.c 2004-07-20 17:01:17.000000000 +0200 +++ src.ntp/contrib/ntp/libisc/assertions.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,93 +0,0 @@ -/* - * Copyright (C) 1997-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: assertions.c,v 1.16 2001/07/16 03:52:05 mayer Exp $ */ - -#include - -#include -#include - -#include -#include - -/* - * Forward. - */ - -static void -default_callback(const char *, int, isc_assertiontype_t, const char *); - -/* - * Public. - */ - -LIBISC_EXTERNAL_DATA isc_assertioncallback_t isc_assertion_failed = - default_callback; - -void -isc_assertion_setcallback(isc_assertioncallback_t cb) { - if (cb == NULL) - isc_assertion_failed = default_callback; - else - isc_assertion_failed = cb; -} - -const char * -isc_assertion_typetotext(isc_assertiontype_t type) { - const char *result; - - /* - * These strings have purposefully not been internationalized - * because they are considered to essentially be keywords of - * the ISC development environment. - */ - switch (type) { - case isc_assertiontype_require: - result = "REQUIRE"; - break; - case isc_assertiontype_ensure: - result = "ENSURE"; - break; - case isc_assertiontype_insist: - result = "INSIST"; - break; - case isc_assertiontype_invariant: - result = "INVARIANT"; - break; - default: - result = NULL; - } - return (result); -} - -/* - * Private. - */ - -static void -default_callback(const char *file, int line, isc_assertiontype_t type, - const char *cond) -{ - fprintf(stderr, "%s:%d: %s(%s) %s.\n", - file, line, isc_assertion_typetotext(type), cond, - isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, - ISC_MSG_FAILED, "failed")); - fflush(stderr); - abort(); - /* NOTREACHED */ -} diff -urN src/contrib/ntp/libisc/error.c src.ntp/contrib/ntp/libisc/error.c --- src/contrib/ntp/libisc/error.c 2004-07-20 17:01:17.000000000 +0200 +++ src.ntp/contrib/ntp/libisc/error.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,101 +0,0 @@ -/* - * Copyright (C) 1998-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: error.c,v 1.16 2001/08/08 22:54:49 gson Exp $ */ - -#include - -#include -#include - -#include -#include - -static void -default_unexpected_callback(const char *, int, const char *, va_list) - ISC_FORMAT_PRINTF(3, 0); - -static void -default_fatal_callback(const char *, int, const char *, va_list) - ISC_FORMAT_PRINTF(3, 0); - -static isc_errorcallback_t unexpected_callback = default_unexpected_callback; -static isc_errorcallback_t fatal_callback = default_fatal_callback; - -void -isc_error_setunexpected(isc_errorcallback_t cb) { - if (cb == NULL) - unexpected_callback = default_unexpected_callback; - else - unexpected_callback = cb; -} - -void -isc_error_setfatal(isc_errorcallback_t cb) { - if (cb == NULL) - fatal_callback = default_fatal_callback; - else - fatal_callback = cb; -} - -void -isc_error_unexpected(const char *file, int line, const char *format, ...) { - va_list args; - - va_start(args, format); - (unexpected_callback)(file, line, format, args); - va_end(args); -} - -void -isc_error_fatal(const char *file, int line, const char *format, ...) { - va_list args; - - va_start(args, format); - (fatal_callback)(file, line, format, args); - va_end(args); - abort(); -} - -void -isc_error_runtimecheck(const char *file, int line, const char *expression) { - isc_error_fatal(file, line, "RUNTIME_CHECK(%s) %s", expression, - isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, - ISC_MSG_FAILED, "failed")); -} - -static void -default_unexpected_callback(const char *file, int line, const char *format, - va_list args) -{ - fprintf(stderr, "%s:%d: ", file, line); - vfprintf(stderr, format, args); - fprintf(stderr, "\n"); - fflush(stderr); -} - -static void -default_fatal_callback(const char *file, int line, const char *format, - va_list args) -{ - fprintf(stderr, "%s:%d: %s: ", file, line, - isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, - ISC_MSG_FATALERROR, "fatal error")); - vfprintf(stderr, format, args); - fprintf(stderr, "\n"); - fflush(stderr); -} diff -urN src/contrib/ntp/libisc/ifiter_getifaddrs.c src.ntp/contrib/ntp/libisc/ifiter_getifaddrs.c --- src/contrib/ntp/libisc/ifiter_getifaddrs.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libisc/ifiter_getifaddrs.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,191 +0,0 @@ -/* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") - * Copyright (C) 2003 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH - * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY - * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM - * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE - * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: ifiter_getifaddrs.c,v 1.2.68.3 2004/03/06 08:14:59 marka Exp $ */ - -/* - * Obtain the list of network interfaces using the getifaddrs(3) library. - */ - -#include - -#define IFITER_MAGIC ISC_MAGIC('I', 'F', 'I', 'G') -#define VALID_IFITER(t) ISC_MAGIC_VALID(t, IFITER_MAGIC) - -struct isc_interfaceiter { - unsigned int magic; /* Magic number. */ - isc_mem_t *mctx; - void *buf; /* (unused) */ - unsigned int bufsize; /* (always 0) */ - struct ifaddrs *ifaddrs; /* List of ifaddrs */ - struct ifaddrs *pos; /* Ptr to current ifaddr */ - isc_interface_t current; /* Current interface data. */ - isc_result_t result; /* Last result code. */ -}; - -isc_result_t -isc_interfaceiter_create(isc_mem_t *mctx, isc_interfaceiter_t **iterp) { - isc_interfaceiter_t *iter; - isc_result_t result; - char strbuf[ISC_STRERRORSIZE]; - - REQUIRE(iterp != NULL); - REQUIRE(*iterp == NULL); - - iter = isc_mem_get(mctx, sizeof(*iter)); - if (iter == NULL) - return (ISC_R_NOMEMORY); - - iter->mctx = mctx; - iter->buf = NULL; - iter->bufsize = 0; - iter->ifaddrs = NULL; - - if (getifaddrs(&iter->ifaddrs) < 0) { - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, - ISC_MSGSET_IFITERGETIFADDRS, - ISC_MSG_GETIFADDRS, - "getting interface " - "addresses: getifaddrs: %s"), - strbuf); - result = ISC_R_UNEXPECTED; - goto failure; - } - - /* - * A newly created iterator has an undefined position - * until isc_interfaceiter_first() is called. - */ - iter->pos = NULL; - iter->result = ISC_R_FAILURE; - - iter->magic = IFITER_MAGIC; - *iterp = iter; - return (ISC_R_SUCCESS); - - failure: - if (iter->ifaddrs != NULL) /* just in case */ - freeifaddrs(iter->ifaddrs); - isc_mem_put(mctx, iter, sizeof(*iter)); - return (result); -} - -/* - * Get information about the current interface to iter->current. - * If successful, return ISC_R_SUCCESS. - * If the interface has an unsupported address family, - * return ISC_R_IGNORE. - */ - -static isc_result_t -internal_current(isc_interfaceiter_t *iter) { - struct ifaddrs *ifa; - int family; - unsigned int namelen; - - REQUIRE(VALID_IFITER(iter)); - - ifa = iter->pos; - - INSIST(ifa != NULL); - INSIST(ifa->ifa_name != NULL); - INSIST(ifa->ifa_addr != NULL); - - family = ifa->ifa_addr->sa_family; - if (family != AF_INET && family != AF_INET6) - return (ISC_R_IGNORE); - - memset(&iter->current, 0, sizeof(iter->current)); - - namelen = strlen(ifa->ifa_name); - if (namelen > sizeof(iter->current.name) - 1) - namelen = sizeof(iter->current.name) - 1; - - memset(iter->current.name, 0, sizeof(iter->current.name)); - memcpy(iter->current.name, ifa->ifa_name, namelen); - - iter->current.flags = 0; - - if ((ifa->ifa_flags & IFF_UP) != 0) - iter->current.flags |= INTERFACE_F_UP; - - if ((ifa->ifa_flags & IFF_POINTOPOINT) != 0) - iter->current.flags |= INTERFACE_F_POINTTOPOINT; - - if ((ifa->ifa_flags & IFF_LOOPBACK) != 0) - iter->current.flags |= INTERFACE_F_LOOPBACK; - - if ((ifa->ifa_flags & IFF_BROADCAST) != 0) { - iter->current.flags |= INTERFACE_F_BROADCAST; - } - -#ifdef IFF_MULTICAST - if ((ifa->ifa_flags & IFF_MULTICAST) != 0) { - iter->current.flags |= INTERFACE_F_MULTICAST; - } -#endif - iter->current.af = family; - - get_addr(family, &iter->current.address, ifa->ifa_addr, ifa->ifa_name); - - if (ifa->ifa_netmask != NULL) - get_addr(family, &iter->current.netmask, ifa->ifa_netmask, - ifa->ifa_name); - - if (ifa->ifa_dstaddr != NULL && - (iter->current.flags & INTERFACE_F_POINTTOPOINT) != 0) - get_addr(family, &iter->current.dstaddress, ifa->ifa_dstaddr, - ifa->ifa_name); - - if (ifa->ifa_broadaddr != NULL && - (iter->current.flags & INTERFACE_F_BROADCAST) != 0) - get_addr(family, &iter->current.broadcast, ifa->ifa_broadaddr, - ifa->ifa_name); - - return (ISC_R_SUCCESS); -} - -/* - * Step the iterator to the next interface. Unlike - * isc_interfaceiter_next(), this may leave the iterator - * positioned on an interface that will ultimately - * be ignored. Return ISC_R_NOMORE if there are no more - * interfaces, otherwise ISC_R_SUCCESS. - */ -static isc_result_t -internal_next(isc_interfaceiter_t *iter) { - iter->pos = iter->pos->ifa_next; - - if (iter->pos == NULL) - return (ISC_R_NOMORE); - - return (ISC_R_SUCCESS); -} - -static void -internal_destroy(isc_interfaceiter_t *iter) { - if (iter->ifaddrs) - freeifaddrs(iter->ifaddrs); - iter->ifaddrs = NULL; -} - -static -void internal_first(isc_interfaceiter_t *iter) { - iter->pos = iter->ifaddrs; -} diff -urN src/contrib/ntp/libisc/ifiter_ioctl.c src.ntp/contrib/ntp/libisc/ifiter_ioctl.c --- src/contrib/ntp/libisc/ifiter_ioctl.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libisc/ifiter_ioctl.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,1118 +0,0 @@ -/* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") - * Copyright (C) 1999-2003 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH - * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY - * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM - * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE - * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: ifiter_ioctl.c,v 1.19.2.5.2.14 2004/06/22 04:40:23 marka Exp $ */ - -/* - * Obtain the list of network interfaces using the SIOCGLIFCONF ioctl. - * See netintro(4). - */ - -#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) -#ifdef ISC_PLATFORM_HAVEIF_LADDRCONF -#define lifc_len iflc_len -#define lifc_buf iflc_buf -#define lifc_req iflc_req -#define LIFCONF if_laddrconf -#else -#define ISC_HAVE_LIFC_FAMILY 1 -#define ISC_HAVE_LIFC_FLAGS 1 -#define LIFCONF lifconf -#endif - -#ifdef ISC_PLATFORM_HAVEIF_LADDRREQ -#define lifr_addr iflr_addr -#define lifr_name iflr_name -#define lifr_dstaddr iflr_dstaddr -#define lifr_broadaddr iflr_broadaddr -#define lifr_flags iflr_flags -#define lifr_index iflr_index -#define ss_family sa_family -#define LIFREQ if_laddrreq -#else -#define LIFREQ lifreq -#endif -#endif - -#define IFITER_MAGIC ISC_MAGIC('I', 'F', 'I', 'T') -#define VALID_IFITER(t) ISC_MAGIC_VALID(t, IFITER_MAGIC) - -#define ISC_IF_INET6_SZ \ - sizeof("00000000000000000000000000000001 01 80 10 80 XXXXXXloXXXXXXXX\n") - -struct isc_interfaceiter { - unsigned int magic; /* Magic number. */ - isc_mem_t *mctx; - int mode; - int socket; - struct ifconf ifc; - void *buf; /* Buffer for sysctl data. */ - unsigned int bufsize; /* Bytes allocated. */ - unsigned int pos; /* Current offset in - SIOCGIFCONF data */ -#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) - int socket6; - struct LIFCONF lifc; - void *buf6; /* Buffer for sysctl data. */ - unsigned int bufsize6; /* Bytes allocated. */ - unsigned int pos6; /* Current offset in - SIOCGLIFCONF data */ - isc_result_t result6; /* Last result code. */ - isc_boolean_t first6; -#endif -#ifdef HAVE_TRUCLUSTER - int clua_context; /* Cluster alias context */ - isc_boolean_t clua_done; - struct sockaddr clua_sa; -#endif -#ifdef __linux - FILE * proc; - char entry[ISC_IF_INET6_SZ]; - isc_result_t valid; - isc_boolean_t first; -#endif - isc_interface_t current; /* Current interface data. */ - isc_result_t result; /* Last result code. */ -}; - -#ifdef HAVE_TRUCLUSTER -#include -#include -#endif - - -/* - * Size of buffer for SIOCGLIFCONF, in bytes. We assume no sane system - * will have more than a megabyte of interface configuration data. - */ -#define IFCONF_BUFSIZE_INITIAL 4096 -#define IFCONF_BUFSIZE_MAX 1048576 - -#ifdef __linux -#ifndef IF_NAMESIZE -# ifdef IFNAMSIZ -# define IF_NAMESIZE IFNAMSIZ -# else -# define IF_NAMESIZE 16 -# endif -#endif -#endif - -static isc_result_t -getbuf4(isc_interfaceiter_t *iter) { - char strbuf[ISC_STRERRORSIZE]; - - iter->bufsize = IFCONF_BUFSIZE_INITIAL; - - for (;;) { - iter->buf = isc_mem_get(iter->mctx, iter->bufsize); - if (iter->buf == NULL) - return (ISC_R_NOMEMORY); - - memset(&iter->ifc.ifc_len, 0, sizeof(iter->ifc.ifc_len)); - iter->ifc.ifc_len = iter->bufsize; - iter->ifc.ifc_buf = iter->buf; - /* - * Ignore the HP/UX warning about "integer overflow during - * conversion". It comes from its own macro definition, - * and is really hard to shut up. - */ - if (ioctl(iter->socket, SIOCGIFCONF, (char *)&iter->ifc) - == -1) { - if (errno != EINVAL) { - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, - ISC_MSGSET_IFITERIOCTL, - ISC_MSG_GETIFCONFIG, - "get interface " - "configuration: %s"), - strbuf); - goto unexpected; - } - /* - * EINVAL. Retry with a bigger buffer. - */ - } else { - /* - * The ioctl succeeded. - * Some OS's just return what will fit rather - * than set EINVAL if the buffer is too small - * to fit all the interfaces in. If - * ifc.lifc_len is too near to the end of the - * buffer we will grow it just in case and - * retry. - */ - if (iter->ifc.ifc_len + 2 * sizeof(struct ifreq) - < iter->bufsize) - break; - } - if (iter->bufsize >= IFCONF_BUFSIZE_MAX) { - UNEXPECTED_ERROR(__FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, - ISC_MSGSET_IFITERIOCTL, - ISC_MSG_BUFFERMAX, - "get interface " - "configuration: " - "maximum buffer " - "size exceeded")); - goto unexpected; - } - isc_mem_put(iter->mctx, iter->buf, iter->bufsize); - - iter->bufsize *= 2; - } - return (ISC_R_SUCCESS); - - unexpected: - isc_mem_put(iter->mctx, iter->buf, iter->bufsize); - iter->buf = NULL; - return (ISC_R_UNEXPECTED); -} - -#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) -static isc_result_t -getbuf6(isc_interfaceiter_t *iter) { - char strbuf[ISC_STRERRORSIZE]; - isc_result_t result; - - iter->bufsize6 = IFCONF_BUFSIZE_INITIAL; - - for (;;) { - iter->buf6 = isc_mem_get(iter->mctx, iter->bufsize6); - if (iter->buf6 == NULL) - return (ISC_R_NOMEMORY); - - memset(&iter->lifc, 0, sizeof(iter->lifc)); -#ifdef ISC_HAVE_LIFC_FAMILY - iter->lifc.lifc_family = AF_INET6; -#endif -#ifdef ISC_HAVE_LIFC_FLAGS - iter->lifc.lifc_flags = 0; -#endif - iter->lifc.lifc_len = iter->bufsize6; - iter->lifc.lifc_buf = iter->buf6; - /* - * Ignore the HP/UX warning about "integer overflow during - * conversion". It comes from its own macro definition, - * and is really hard to shut up. - */ - if (ioctl(iter->socket6, SIOCGLIFCONF, (char *)&iter->lifc) - == -1) { -#ifdef __hpux - /* - * IPv6 interface scanning is not available on all - * kernels w/ IPv6 sockets. - */ - if (errno == ENOENT) { - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, - ISC_MSGSET_IFITERIOCTL, - ISC_MSG_GETIFCONFIG, - "get interface " - "configuration: %s"), - strbuf); - result = ISC_R_FAILURE; - goto cleanup; - } -#endif - if (errno != EINVAL) { - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, - ISC_MSGSET_IFITERIOCTL, - ISC_MSG_GETIFCONFIG, - "get interface " - "configuration: %s"), - strbuf); - result = ISC_R_UNEXPECTED; - goto cleanup; - } - /* - * EINVAL. Retry with a bigger buffer. - */ - } else { - /* - * The ioctl succeeded. - * Some OS's just return what will fit rather - * than set EINVAL if the buffer is too small - * to fit all the interfaces in. If - * ifc.ifc_len is too near to the end of the - * buffer we will grow it just in case and - * retry. - */ - if (iter->lifc.lifc_len + 2 * sizeof(struct LIFREQ) - < iter->bufsize6) - break; - } - if (iter->bufsize6 >= IFCONF_BUFSIZE_MAX) { - UNEXPECTED_ERROR(__FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, - ISC_MSGSET_IFITERIOCTL, - ISC_MSG_BUFFERMAX, - "get interface " - "configuration: " - "maximum buffer " - "size exceeded")); - result = ISC_R_UNEXPECTED; - goto cleanup; - } - isc_mem_put(iter->mctx, iter->buf6, iter->bufsize6); - - iter->bufsize6 *= 2; - } - - if (iter->lifc.lifc_len != 0) - iter->mode = 6; - return (ISC_R_SUCCESS); - - cleanup: - isc_mem_put(iter->mctx, iter->buf6, iter->bufsize6); - iter->buf6 = NULL; - return (result); -} -#endif - -isc_result_t -isc_interfaceiter_create(isc_mem_t *mctx, isc_interfaceiter_t **iterp) { - isc_interfaceiter_t *iter; - isc_result_t result; - char strbuf[ISC_STRERRORSIZE]; - - REQUIRE(iterp != NULL); - REQUIRE(*iterp == NULL); - - iter = isc_mem_get(mctx, sizeof(*iter)); - if (iter == NULL) - return (ISC_R_NOMEMORY); - - iter->mctx = mctx; - iter->mode = 4; - iter->buf = NULL; - iter->pos = (unsigned int) -1; -#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) - iter->buf6 = NULL; - iter->pos6 = (unsigned int) -1; - iter->result6 = ISC_R_NOMORE; - iter->socket6 = -1; - iter->first6 = ISC_FALSE; -#endif - - /* - * Get the interface configuration, allocating more memory if - * necessary. - */ - -#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) - result = isc_net_probeipv6(); - if (result == ISC_R_SUCCESS) { - /* - * Create an unbound datagram socket to do the SIOCGLIFCONF - * ioctl on. HP/UX requires an AF_INET6 socket for - * SIOCGLIFCONF to get IPv6 addresses. - */ - if ((iter->socket6 = socket(AF_INET6, SOCK_DGRAM, 0)) < 0) { - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, - ISC_MSGSET_IFITERIOCTL, - ISC_MSG_MAKESCANSOCKET, - "making interface " - "scan socket: %s"), - strbuf); - result = ISC_R_UNEXPECTED; - goto socket6_failure; - } - iter->result6 = getbuf6(iter); - if (iter->result6 != ISC_R_NOTIMPLEMENTED && - iter->result6 != ISC_R_SUCCESS) - goto ioctl6_failure; - } -#endif - if ((iter->socket = socket(AF_INET, SOCK_DGRAM, 0)) < 0) { - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, - ISC_MSGSET_IFITERIOCTL, - ISC_MSG_MAKESCANSOCKET, - "making interface " - "scan socket: %s"), - strbuf); - result = ISC_R_UNEXPECTED; - goto socket_failure; - } - result = getbuf4(iter); - if (result != ISC_R_SUCCESS) - goto ioctl_failure; - - /* - * A newly created iterator has an undefined position - * until isc_interfaceiter_first() is called. - */ -#ifdef HAVE_TRUCLUSTER - iter->clua_context = -1; - iter->clua_done = ISC_TRUE; -#endif -#ifdef __linux - iter->proc = fopen("/proc/net/if_inet6", "r"); - iter->valid = ISC_R_FAILURE; - iter->first = ISC_FALSE; -#endif - iter->result = ISC_R_FAILURE; - - iter->magic = IFITER_MAGIC; - *iterp = iter; - return (ISC_R_SUCCESS); - - ioctl_failure: - if (iter->buf != NULL) - isc_mem_put(mctx, iter->buf, iter->bufsize); - (void) close(iter->socket); - - socket_failure: -#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) - if (iter->buf6 != NULL) - isc_mem_put(mctx, iter->buf6, iter->bufsize6); - ioctl6_failure: - if (iter->socket6 != -1) - (void) close(iter->socket6); - socket6_failure: -#endif - - isc_mem_put(mctx, iter, sizeof(*iter)); - return (result); -} - -#ifdef HAVE_TRUCLUSTER -static void -get_inaddr(isc_netaddr_t *dst, struct in_addr *src) { - dst->family = AF_INET; - memcpy(&dst->type.in, src, sizeof(struct in_addr)); -} - -static isc_result_t -internal_current_clusteralias(isc_interfaceiter_t *iter) { - struct clua_info ci; - if (clua_getaliasinfo(&iter->clua_sa, &ci) != CLUA_SUCCESS) - return (ISC_R_IGNORE); - memset(&iter->current, 0, sizeof(iter->current)); - iter->current.af = iter->clua_sa.sa_family; - memset(iter->current.name, 0, sizeof(iter->current.name)); - sprintf(iter->current.name, "clua%d", ci.aliasid); - iter->current.flags = INTERFACE_F_UP; - get_inaddr(&iter->current.address, &ci.addr); - get_inaddr(&iter->current.netmask, &ci.netmask); - return (ISC_R_SUCCESS); -} -#endif - -#ifdef __linux -static isc_result_t -linux_if_inet6_next(isc_interfaceiter_t *iter) { - if (iter->proc != NULL && - fgets(iter->entry, sizeof(iter->entry), iter->proc) != NULL) - iter->valid = ISC_R_SUCCESS; - else - iter->valid = ISC_R_NOMORE; - return (iter->valid); -} - -static void -linux_if_inet6_first(isc_interfaceiter_t *iter) { - if (iter->proc != NULL) { - rewind(iter->proc); - (void)linux_if_inet6_next(iter); - } else - iter->valid = ISC_R_NOMORE; - iter->first = ISC_FALSE; -} - -static isc_result_t -linux_if_inet6_current(isc_interfaceiter_t *iter) { - char address[33]; - char name[IF_NAMESIZE+1]; - char strbuf[ISC_STRERRORSIZE]; - struct in6_addr addr6; - struct ifreq ifreq; - int ifindex, prefix, scope, flags; - int res; - unsigned int i; - - if (iter->valid != ISC_R_SUCCESS) - return (iter->valid); - if (iter->proc == NULL) { - UNEXPECTED_ERROR(__FILE__, __LINE__, - "/proc/net/if_inet6:iter->proc == NULL"); - return (ISC_R_FAILURE); - } - - /* - * Format for /proc/net/if_inet6: - * (see iface_proc_info() in net/ipv6/addrconf.c) - * - */ - res = sscanf(iter->entry, "%32[a-f0-9] %x %x %x %x %16s\n", - address, &ifindex, &prefix, &scope, &flags, name); - if (res != 6) { - UNEXPECTED_ERROR(__FILE__, __LINE__, - "/proc/net/if_inet6:sscanf() -> %d (expected 6)", - res); - return (ISC_R_FAILURE); - } - if (strlen(address) != 32) { - UNEXPECTED_ERROR(__FILE__, __LINE__, - "/proc/net/if_inet6:strlen(%s) != 32", address); - return (ISC_R_FAILURE); - } - for (i = 0; i < 16; i++) { - unsigned char byte; - static const char hex[] = "0123456789abcdef"; - byte = ((index(hex, address[i * 2]) - hex) << 4) | - (index(hex, address[i * 2 + 1]) - hex); - addr6.s6_addr[i] = byte; - } - iter->current.af = AF_INET6; - /* iter->current.ifindex = ifindex; */ - iter->current.flags = 0; - - memset(&ifreq, 0, sizeof(ifreq)); - INSIST(sizeof(ifreq.ifr_name) <= sizeof(iter->current.name)); - strncpy(ifreq.ifr_name, name, sizeof(ifreq.ifr_name)); - - if (ioctl(iter->socket, SIOCGIFFLAGS, (char *) &ifreq) < 0) { - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - "%s: getting interface flags: %s", - ifreq.ifr_name, strbuf); - return (ISC_R_IGNORE); - } - - if ((ifreq.ifr_flags & IFF_UP) != 0) - iter->current.flags |= INTERFACE_F_UP; -#ifdef IFF_POINTOPOINT - if ((ifreq.ifr_flags & IFF_POINTOPOINT) != 0) - iter->current.flags |= INTERFACE_F_POINTTOPOINT; -#endif - if ((ifreq.ifr_flags & IFF_LOOPBACK) != 0) - iter->current.flags |= INTERFACE_F_LOOPBACK; - if ((ifreq.ifr_flags & IFF_BROADCAST) != 0) - iter->current.flags |= INTERFACE_F_BROADCAST; -#ifdef IFF_MULTICAST - if ((ifreq.ifr_flags & IFF_MULTICAST) != 0) - iter->current.flags |= INTERFACE_F_MULTICAST; -#endif - - /* - * enable_multicast_if() requires scopeid for setsockopt, - * so associate address with their corresponding ifindex. - */ - isc_netaddr_fromin6(&iter->current.address, &addr6); - isc_netaddr_setzone(&iter->current.address, (isc_uint32_t)ifindex); - - for (i = 0; i < 16; i++) { - if (prefix > 8) { - addr6.s6_addr[i] = 0xff; - prefix -= 8; - } else { - addr6.s6_addr[i] = (0xff << (8 - prefix)) & 0xff; - prefix = 0; - } - } - isc_netaddr_fromin6(&iter->current.netmask, &addr6); - strncpy(iter->current.name, name, sizeof(iter->current.name)); - return (ISC_R_SUCCESS); -} -#endif - -/* - * Get information about the current interface to iter->current. - * If successful, return ISC_R_SUCCESS. - * If the interface has an unsupported address family, or if - * some operation on it fails, return ISC_R_IGNORE to make - * the higher-level iterator code ignore it. - */ - -static isc_result_t -internal_current4(isc_interfaceiter_t *iter) { - struct ifreq *ifrp; - struct ifreq ifreq; - int family; - char strbuf[ISC_STRERRORSIZE]; -#if !defined(ISC_PLATFORM_HAVEIF_LADDRREQ) && defined(SIOCGLIFADDR) - struct lifreq lifreq; -#else - char sabuf[256]; -#endif - int i, bits, prefixlen; -#ifdef __linux - isc_result_t result; -#endif - - REQUIRE(VALID_IFITER(iter)); - REQUIRE (iter->pos < (unsigned int) iter->ifc.ifc_len); - -#ifdef __linux - result = linux_if_inet6_current(iter); - if (result != ISC_R_NOMORE) - return (result); - iter->first = ISC_TRUE; -#endif - - ifrp = (struct ifreq *)((char *) iter->ifc.ifc_req + iter->pos); - - memset(&ifreq, 0, sizeof(ifreq)); - memcpy(&ifreq, ifrp, sizeof(ifreq)); - - family = ifreq.ifr_addr.sa_family; -#if defined(ISC_PLATFORM_HAVEIPV6) - if (family != AF_INET && family != AF_INET6) -#else - if (family != AF_INET) -#endif - return (ISC_R_IGNORE); - - memset(&iter->current, 0, sizeof(iter->current)); - iter->current.af = family; - - INSIST(sizeof(ifreq.ifr_name) <= sizeof(iter->current.name)); - memset(iter->current.name, 0, sizeof(iter->current.name)); - memcpy(iter->current.name, ifreq.ifr_name, sizeof(ifreq.ifr_name)); - - get_addr(family, &iter->current.address, - (struct sockaddr *)&ifrp->ifr_addr, ifreq.ifr_name); - - /* - * If the interface does not have a address ignore it. - */ - switch (family) { - case AF_INET: - if (iter->current.address.type.in.s_addr == htonl(INADDR_ANY)) - return (ISC_R_IGNORE); - break; -#ifdef ISC_PLATFORM_HAVEIPV6 - case AF_INET6: - if (memcmp(&iter->current.address.type.in6, &in6addr_any, - sizeof(in6addr_any)) == 0) - return (ISC_R_IGNORE); - break; -#endif - } - - /* - * Get interface flags. - */ - - iter->current.flags = 0; - - /* - * Ignore the HP/UX warning about "integer overflow during - * conversion. It comes from its own macro definition, - * and is really hard to shut up. - */ - if (ioctl(iter->socket, SIOCGIFFLAGS, (char *) &ifreq) < 0) { - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - "%s: getting interface flags: %s", - ifreq.ifr_name, strbuf); - return (ISC_R_IGNORE); - } - - if ((ifreq.ifr_flags & IFF_UP) != 0) - iter->current.flags |= INTERFACE_F_UP; - -#ifdef IFF_POINTOPOINT - if ((ifreq.ifr_flags & IFF_POINTOPOINT) != 0) - iter->current.flags |= INTERFACE_F_POINTTOPOINT; -#endif - - if ((ifreq.ifr_flags & IFF_LOOPBACK) != 0) - iter->current.flags |= INTERFACE_F_LOOPBACK; - - if ((ifreq.ifr_flags & IFF_BROADCAST) != 0) { - iter->current.flags |= INTERFACE_F_BROADCAST; - } - -#ifdef IFF_MULTICAST - if ((ifreq.ifr_flags & IFF_MULTICAST) != 0) { - iter->current.flags |= INTERFACE_F_MULTICAST; - } -#endif - - if (family == AF_INET) - goto inet; - -#if !defined(ISC_PLATFORM_HAVEIF_LADDRREQ) && defined(SIOCGLIFADDR) - memset(&lifreq, 0, sizeof(lifreq)); - memcpy(lifreq.lifr_name, iter->current.name, sizeof(lifreq.lifr_name)); - memcpy(&lifreq.lifr_addr, &iter->current.address.type.in6, - sizeof(iter->current.address.type.in6)); - - if (ioctl(iter->socket, SIOCGLIFADDR, &lifreq) < 0) { - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - "%s: getting interface address: %s", - ifreq.ifr_name, strbuf); - return (ISC_R_IGNORE); - } - prefixlen = lifreq.lifr_addrlen; -#else - isc_netaddr_format(&iter->current.address, sabuf, sizeof(sabuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, - ISC_MSGSET_IFITERIOCTL, - ISC_MSG_GETIFCONFIG, - "prefix length for %s is unknown " - "(assume 128)"), sabuf); - prefixlen = 128; -#endif - - /* - * Netmask already zeroed. - */ - iter->current.netmask.family = family; - for (i = 0; i < 16; i++) { - if (prefixlen > 8) { - bits = 0; - prefixlen -= 8; - } else { - bits = 8 - prefixlen; - prefixlen = 0; - } - iter->current.netmask.type.in6.s6_addr[i] = (~0 << bits) & 0xff; - } - return (ISC_R_SUCCESS); - - inet: - if (family != AF_INET) - return (ISC_R_IGNORE); -#ifdef IFF_POINTOPOINT - /* - * If the interface is point-to-point, get the destination address. - */ - if ((iter->current.flags & INTERFACE_F_POINTTOPOINT) != 0) { - /* - * Ignore the HP/UX warning about "integer overflow during - * conversion. It comes from its own macro definition, - * and is really hard to shut up. - */ - if (ioctl(iter->socket, SIOCGIFDSTADDR, (char *)&ifreq) - < 0) { - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, - ISC_MSGSET_IFITERIOCTL, - ISC_MSG_GETDESTADDR, - "%s: getting " - "destination address: %s"), - ifreq.ifr_name, strbuf); - return (ISC_R_IGNORE); - } - get_addr(family, &iter->current.dstaddress, - (struct sockaddr *)&ifreq.ifr_dstaddr, ifreq.ifr_name); - } -#endif - if ((iter->current.flags & INTERFACE_F_BROADCAST) != 0) { - /* - * Ignore the HP/UX warning about "integer overflow during - * conversion. It comes from its own macro definition, - * and is really hard to shut up. - */ - if (ioctl(iter->socket, SIOCGIFBRDADDR, (char *)&ifreq) - < 0) { - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, - ISC_MSGSET_IFITERIOCTL, - ISC_MSG_GETDESTADDR, - "%s: getting " - "broadcast address: %s"), - ifreq.ifr_name, strbuf); - return (ISC_R_IGNORE); - } - get_addr(family, &iter->current.broadcast, - (struct sockaddr *)&ifreq.ifr_broadaddr, ifreq.ifr_name); - } - - /* - * Get the network mask. - */ - memset(&ifreq, 0, sizeof(ifreq)); - memcpy(&ifreq, ifrp, sizeof(ifreq)); - /* - * Ignore the HP/UX warning about "integer overflow during - * conversion. It comes from its own macro definition, - * and is really hard to shut up. - */ - if (ioctl(iter->socket, SIOCGIFNETMASK, (char *)&ifreq) < 0) { - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, - ISC_MSGSET_IFITERIOCTL, - ISC_MSG_GETNETMASK, - "%s: getting netmask: %s"), - ifreq.ifr_name, strbuf); - return (ISC_R_IGNORE); - } - get_addr(family, &iter->current.netmask, - (struct sockaddr *)&ifreq.ifr_addr, ifreq.ifr_name); - return (ISC_R_SUCCESS); -} - -#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) -static isc_result_t -internal_current6(isc_interfaceiter_t *iter) { - struct LIFREQ *ifrp; - struct LIFREQ lifreq; - int family; - char strbuf[ISC_STRERRORSIZE]; - int fd; - - REQUIRE(VALID_IFITER(iter)); - if (iter->result6 != ISC_R_SUCCESS) - return (iter->result6); - REQUIRE(iter->pos6 < (unsigned int) iter->lifc.lifc_len); - - ifrp = (struct LIFREQ *)((char *) iter->lifc.lifc_req + iter->pos6); - - memset(&lifreq, 0, sizeof(lifreq)); - memcpy(&lifreq, ifrp, sizeof(lifreq)); - - family = lifreq.lifr_addr.ss_family; -#ifdef ISC_PLATFORM_HAVEIPV6 - if (family != AF_INET && family != AF_INET6) -#else - if (family != AF_INET) -#endif - return (ISC_R_IGNORE); - - memset(&iter->current, 0, sizeof(iter->current)); - iter->current.af = family; - - INSIST(sizeof(lifreq.lifr_name) <= sizeof(iter->current.name)); - memset(iter->current.name, 0, sizeof(iter->current.name)); - memcpy(iter->current.name, lifreq.lifr_name, sizeof(lifreq.lifr_name)); - - get_addr(family, &iter->current.address, - (struct sockaddr *)&lifreq.lifr_addr, lifreq.lifr_name); - - /* - * If the interface does not have a address ignore it. - */ - switch (family) { - case AF_INET: - if (iter->current.address.type.in.s_addr == htonl(INADDR_ANY)) - return (ISC_R_IGNORE); - break; -#ifdef ISC_PLATFORM_HAVEIPV6 - case AF_INET6: - if (memcmp(&iter->current.address.type.in6, &in6addr_any, - sizeof(in6addr_any)) == 0) - return (ISC_R_IGNORE); - break; -#endif - } - - /* - * Get interface flags. - */ - - iter->current.flags = 0; - - if (family == AF_INET6) - fd = iter->socket6; - else - fd = iter->socket; - - /* - * Ignore the HP/UX warning about "integer overflow during - * conversion. It comes from its own macro definition, - * and is really hard to shut up. - */ - if (ioctl(fd, SIOCGLIFFLAGS, (char *) &lifreq) < 0) { - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - "%s: getting interface flags: %s", - lifreq.lifr_name, strbuf); - return (ISC_R_IGNORE); - } - - if ((lifreq.lifr_flags & IFF_UP) != 0) - iter->current.flags |= INTERFACE_F_UP; - -#ifdef IFF_POINTOPOINT - if ((lifreq.lifr_flags & IFF_POINTOPOINT) != 0) - iter->current.flags |= INTERFACE_F_POINTTOPOINT; -#endif - - if ((lifreq.lifr_flags & IFF_LOOPBACK) != 0) - iter->current.flags |= INTERFACE_F_LOOPBACK; - - if ((lifreq.lifr_flags & IFF_BROADCAST) != 0) { - iter->current.flags |= INTERFACE_F_BROADCAST; - } - -#ifdef IFF_MULTICAST - if ((lifreq.lifr_flags & IFF_MULTICAST) != 0) { - iter->current.flags |= INTERFACE_F_MULTICAST; - } -#endif - -#ifdef IFF_POINTOPOINT - /* - * If the interface is point-to-point, get the destination address. - */ - if ((iter->current.flags & INTERFACE_F_POINTTOPOINT) != 0) { - /* - * Ignore the HP/UX warning about "interger overflow during - * conversion. It comes from its own macro definition, - * and is really hard to shut up. - */ - if (ioctl(fd, SIOCGLIFDSTADDR, (char *)&lifreq) - < 0) { - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, - ISC_MSGSET_IFITERIOCTL, - ISC_MSG_GETDESTADDR, - "%s: getting " - "destination address: %s"), - lifreq.lifr_name, strbuf); - return (ISC_R_IGNORE); - } - get_addr(family, &iter->current.dstaddress, - (struct sockaddr *)&lifreq.lifr_dstaddr, - lifreq.lifr_name); - } -#endif - -#ifdef SIOCGLIFBRDADDR - if ((iter->current.flags & INTERFACE_F_BROADCAST) != 0) { - /* - * Ignore the HP/UX warning about "integer overflow during - * conversion. It comes from its own macro definition, - * and is really hard to shut up. - */ - if (ioctl(iter->socket, SIOCGLIFBRDADDR, (char *)&lifreq) - < 0) { - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, - ISC_MSGSET_IFITERIOCTL, - ISC_MSG_GETDESTADDR, - "%s: getting " - "broadcast address: %s"), - lifreq.lifr_name, strbuf); - return (ISC_R_IGNORE); - } - get_addr(family, &iter->current.broadcast, - (struct sockaddr *)&lifreq.lifr_broadaddr, - lifreq.lifr_name); - } -#endif /* SIOCGLIFBRDADDR */ - - /* - * Get the network mask. Netmask already zeroed. - */ - memset(&lifreq, 0, sizeof(lifreq)); - memcpy(&lifreq, ifrp, sizeof(lifreq)); - -#ifdef lifr_addrlen - /* - * Special case: if the system provides lifr_addrlen member, the - * netmask of an IPv6 address can be derived from the length, since - * an IPv6 address always has a contiguous mask. - */ - if (family == AF_INET6) { - int i, bits; - - iter->current.netmask.family = family; - for (i = 0; i < lifreq.lifr_addrlen; i += 8) { - bits = lifreq.lifr_addrlen - i; - bits = (bits < 8) ? (8 - bits) : 0; - iter->current.netmask.type.in6.s6_addr[i / 8] = - (~0 << bits) & 0xff; - } - - return (ISC_R_SUCCESS); - } -#endif - - /* - * Ignore the HP/UX warning about "integer overflow during - * conversion. It comes from its own macro definition, - * and is really hard to shut up. - */ - if (ioctl(fd, SIOCGLIFNETMASK, (char *)&lifreq) < 0) { - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, - ISC_MSGSET_IFITERIOCTL, - ISC_MSG_GETNETMASK, - "%s: getting netmask: %s"), - lifreq.lifr_name, strbuf); - return (ISC_R_IGNORE); - } - get_addr(family, &iter->current.netmask, - (struct sockaddr *)&lifreq.lifr_addr, lifreq.lifr_name); - - return (ISC_R_SUCCESS); -} -#endif - -static isc_result_t -internal_current(isc_interfaceiter_t *iter) { -#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) - if (iter->mode == 6) { - iter->result6 = internal_current6(iter); - if (iter->result6 != ISC_R_NOMORE) - return (iter->result6); - } -#endif -#ifdef HAVE_TRUCLUSTER - if (!iter->clua_done) - return(internal_current_clusteralias(iter)); -#endif - return (internal_current4(iter)); -} - -/* - * Step the iterator to the next interface. Unlike - * isc_interfaceiter_next(), this may leave the iterator - * positioned on an interface that will ultimately - * be ignored. Return ISC_R_NOMORE if there are no more - * interfaces, otherwise ISC_R_SUCCESS. - */ -static isc_result_t -internal_next4(isc_interfaceiter_t *iter) { - struct ifreq *ifrp; - - REQUIRE (iter->pos < (unsigned int) iter->ifc.ifc_len); - -#ifdef __linux - if (linux_if_inet6_next(iter) == ISC_R_SUCCESS) - return (ISC_R_SUCCESS); - if (!iter->first) - return (ISC_R_SUCCESS); -#endif - ifrp = (struct ifreq *)((char *) iter->ifc.ifc_req + iter->pos); - -#ifdef ISC_PLATFORM_HAVESALEN - if (ifrp->ifr_addr.sa_len > sizeof(struct sockaddr)) - iter->pos += sizeof(ifrp->ifr_name) + ifrp->ifr_addr.sa_len; - else -#endif - iter->pos += sizeof(*ifrp); - - if (iter->pos >= (unsigned int) iter->ifc.ifc_len) - return (ISC_R_NOMORE); - - return (ISC_R_SUCCESS); -} - -#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) -static isc_result_t -internal_next6(isc_interfaceiter_t *iter) { - struct LIFREQ *ifrp; - - if (iter->result6 != ISC_R_SUCCESS && iter->result6 != ISC_R_IGNORE) - return (iter->result6); - - REQUIRE(iter->pos6 < (unsigned int) iter->lifc.lifc_len); - - ifrp = (struct LIFREQ *)((char *) iter->lifc.lifc_req + iter->pos6); - -#ifdef ISC_PLATFORM_HAVESALEN - if (ifrp->lifr_addr.sa_len > sizeof(struct sockaddr)) - iter->pos6 += sizeof(ifrp->lifr_name) + ifrp->lifr_addr.sa_len; - else -#endif - iter->pos6 += sizeof(*ifrp); - - if (iter->pos6 >= (unsigned int) iter->lifc.lifc_len) - return (ISC_R_NOMORE); - - return (ISC_R_SUCCESS); -} -#endif - -static isc_result_t -internal_next(isc_interfaceiter_t *iter) { -#ifdef HAVE_TRUCLUSTER - int clua_result; -#endif -#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) - if (iter->mode == 6) { - iter->result6 = internal_next6(iter); - if (iter->result6 != ISC_R_NOMORE) - return (iter->result6); - if (iter->first6) { - iter->first6 = ISC_FALSE; - return (ISC_R_SUCCESS); - } - } -#endif -#ifdef HAVE_TRUCLUSTER - if (!iter->clua_done) { - clua_result = clua_getaliasaddress(&iter->clua_sa, - &iter->clua_context); - if (clua_result != CLUA_SUCCESS) - iter->clua_done = ISC_TRUE; - return (ISC_R_SUCCESS); - } -#endif - return (internal_next4(iter)); -} - -static void -internal_destroy(isc_interfaceiter_t *iter) { - (void) close(iter->socket); -#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) - if (iter->socket6 != -1) - (void) close(iter->socket6); - if (iter->buf6 != NULL) { - isc_mem_put(iter->mctx, iter->buf6, iter->bufsize6); - } -#endif -#ifdef __linux - if (iter->proc != NULL) - fclose(iter->proc); -#endif -} - -static -void internal_first(isc_interfaceiter_t *iter) { -#ifdef HAVE_TRUCLUSTER - int clua_result; -#endif - iter->pos = 0; -#if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) - iter->pos6 = 0; - if (iter->result6 == ISC_R_NOMORE) - iter->result6 = ISC_R_SUCCESS; - iter->first6 = ISC_TRUE; -#endif -#ifdef HAVE_TRUCLUSTER - iter->clua_context = 0; - clua_result = clua_getaliasaddress(&iter->clua_sa, - &iter->clua_context); - iter->clua_done = ISC_TF(clua_result != CLUA_SUCCESS); -#endif -#ifdef __linux - linux_if_inet6_first(iter); -#endif -} diff -urN src/contrib/ntp/libisc/ifiter_sysctl.c src.ntp/contrib/ntp/libisc/ifiter_sysctl.c --- src/contrib/ntp/libisc/ifiter_sysctl.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libisc/ifiter_sysctl.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,315 +0,0 @@ -/* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") - * Copyright (C) 1999-2003 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH - * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY - * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM - * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE - * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: ifiter_sysctl.c,v 1.14.12.7 2004/03/08 09:04:56 marka Exp $ */ - -/* - * Obtain the list of network interfaces using sysctl. - * See TCP/IP Illustrated Volume 2, sections 19.8, 19.14, - * and 19.16. - */ - -#include -#include - -#include -#include - -/* XXX what about Alpha? */ -#ifdef sgi -#define ROUNDUP(a) ((a) > 0 ? \ - (1 + (((a) - 1) | (sizeof(__uint64_t) - 1))) : \ - sizeof(__uint64_t)) -#else -#define ROUNDUP(a) ((a) > 0 ? (1 + (((a) - 1) | (sizeof(long) - 1))) \ - : sizeof(long)) -#endif - -#define IFITER_MAGIC ISC_MAGIC('I', 'F', 'I', 'S') -#define VALID_IFITER(t) ISC_MAGIC_VALID(t, IFITER_MAGIC) - -struct isc_interfaceiter { - unsigned int magic; /* Magic number. */ - isc_mem_t *mctx; - void *buf; /* Buffer for sysctl data. */ - unsigned int bufsize; /* Bytes allocated. */ - unsigned int bufused; /* Bytes used. */ - unsigned int pos; /* Current offset in - sysctl data. */ - isc_interface_t current; /* Current interface data. */ - isc_result_t result; /* Last result code. */ -}; - -static int mib[6] = { - CTL_NET, - PF_ROUTE, - 0, - 0, /* Any address family. */ - NET_RT_IFLIST, - 0 /* Flags. */ -}; - -isc_result_t -isc_interfaceiter_create(isc_mem_t *mctx, isc_interfaceiter_t **iterp) { - isc_interfaceiter_t *iter; - isc_result_t result; - size_t bufsize; - size_t bufused; - char strbuf[ISC_STRERRORSIZE]; - - REQUIRE(iterp != NULL); - REQUIRE(*iterp == NULL); - - iter = isc_mem_get(mctx, sizeof(*iter)); - if (iter == NULL) - return (ISC_R_NOMEMORY); - - iter->mctx = mctx; - iter->buf = 0; - - /* - * Determine the amount of memory needed. - */ - bufsize = 0; - if (sysctl(mib, 6, NULL, &bufsize, NULL, (size_t) 0) < 0) { - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, - ISC_MSGSET_IFITERSYSCTL, - ISC_MSG_GETIFLISTSIZE, - "getting interface " - "list size: sysctl: %s"), - strbuf); - result = ISC_R_UNEXPECTED; - goto failure; - } - iter->bufsize = bufsize; - - iter->buf = isc_mem_get(iter->mctx, iter->bufsize); - if (iter->buf == NULL) { - result = ISC_R_NOMEMORY; - goto failure; - } - - bufused = bufsize; - if (sysctl(mib, 6, iter->buf, &bufused, NULL, (size_t) 0) < 0) { - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, - ISC_MSGSET_IFITERSYSCTL, - ISC_MSG_GETIFLIST, - "getting interface list: " - "sysctl: %s"), - strbuf); - result = ISC_R_UNEXPECTED; - goto failure; - } - iter->bufused = bufused; - INSIST(iter->bufused <= iter->bufsize); - - /* - * A newly created iterator has an undefined position - * until isc_interfaceiter_first() is called. - */ - iter->pos = (unsigned int) -1; - iter->result = ISC_R_FAILURE; - - iter->magic = IFITER_MAGIC; - *iterp = iter; - return (ISC_R_SUCCESS); - - failure: - if (iter->buf != NULL) - isc_mem_put(mctx, iter->buf, iter->bufsize); - isc_mem_put(mctx, iter, sizeof(*iter)); - return (result); -} - -/* - * Get information about the current interface to iter->current. - * If successful, return ISC_R_SUCCESS. - * If the interface has an unsupported address family, - * return ISC_R_IGNORE. In case of other failure, - * return ISC_R_UNEXPECTED. - */ - -static isc_result_t -internal_current(isc_interfaceiter_t *iter) { - struct ifa_msghdr *ifam, *ifam_end; - - REQUIRE(VALID_IFITER(iter)); - REQUIRE (iter->pos < (unsigned int) iter->bufused); - - ifam = (struct ifa_msghdr *) ((char *) iter->buf + iter->pos); - ifam_end = (struct ifa_msghdr *) ((char *) iter->buf + iter->bufused); - - if (ifam->ifam_type == RTM_IFINFO) { - struct if_msghdr *ifm = (struct if_msghdr *) ifam; - struct sockaddr_dl *sdl = (struct sockaddr_dl *) (ifm + 1); - unsigned int namelen; - - memset(&iter->current, 0, sizeof(iter->current)); - - namelen = sdl->sdl_nlen; - if (namelen > sizeof(iter->current.name) - 1) - namelen = sizeof(iter->current.name) - 1; - - memset(iter->current.name, 0, sizeof(iter->current.name)); - memcpy(iter->current.name, sdl->sdl_data, namelen); - - iter->current.flags = 0; - - if ((ifam->ifam_flags & IFF_UP) != 0) - iter->current.flags |= INTERFACE_F_UP; - - if ((ifam->ifam_flags & IFF_POINTOPOINT) != 0) - iter->current.flags |= INTERFACE_F_POINTTOPOINT; - - if ((ifam->ifam_flags & IFF_LOOPBACK) != 0) - iter->current.flags |= INTERFACE_F_LOOPBACK; - - if ((ifam->ifam_flags & IFF_BROADCAST) != 0) { - iter->current.flags |= INTERFACE_F_BROADCAST; - } -#ifdef IFF_MULTICAST - if ((ifam->ifam_flags & IFF_MULTICAST) != 0) { - iter->current.flags |= INTERFACE_F_MULTICAST; - } -#endif - - /* - * This is not an interface address. - * Force another iteration. - */ - return (ISC_R_IGNORE); - } else if (ifam->ifam_type == RTM_NEWADDR) { - int i; - int family; - struct sockaddr *mask_sa = NULL; - struct sockaddr *addr_sa = NULL; - struct sockaddr *dst_sa = NULL; - - struct sockaddr *sa = (struct sockaddr *)(ifam + 1); - family = sa->sa_family; - - for (i = 0; i < RTAX_MAX; i++) - { - if ((ifam->ifam_addrs & (1 << i)) == 0) - continue; - - INSIST(sa < (struct sockaddr *) ifam_end); - - switch (i) { - case RTAX_NETMASK: /* Netmask */ - mask_sa = sa; - break; - case RTAX_IFA: /* Interface address */ - addr_sa = sa; - break; - case RTAX_BRD: /* Broadcast or destination address */ - dst_sa = sa; - break; - } -#ifdef ISC_PLATFORM_HAVESALEN - sa = (struct sockaddr *)((char*)(sa) - + ROUNDUP(sa->sa_len)); -#else -#ifdef sgi - /* - * Do as the contributed SGI code does. - */ - sa = (struct sockaddr *)((char*)(sa) - + ROUNDUP(_FAKE_SA_LEN_DST(sa))); -#else - /* XXX untested. */ - sa = (struct sockaddr *)((char*)(sa) - + ROUNDUP(sizeof(struct sockaddr))); -#endif -#endif - } - - if (addr_sa == NULL) - return (ISC_R_IGNORE); - - family = addr_sa->sa_family; - if (family != AF_INET && family != AF_INET6) - return (ISC_R_IGNORE); - - iter->current.af = family; - - get_addr(family, &iter->current.address, addr_sa, - iter->current.name); - - if (mask_sa != NULL) - get_addr(family, &iter->current.netmask, mask_sa, - iter->current.name); - - if (dst_sa != NULL && - (iter->current.flags & INTERFACE_F_POINTTOPOINT) != 0) - get_addr(family, &iter->current.dstaddress, dst_sa, - iter->current.name); - - if (dst_sa != NULL && - (iter->current.flags & INTERFACE_F_BROADCAST) != 0) - get_addr(family, &iter->current.broadcast, dst_sa, - iter->current.name); - - - return (ISC_R_SUCCESS); - } else { - printf(isc_msgcat_get(isc_msgcat, ISC_MSGSET_IFITERSYSCTL, - ISC_MSG_UNEXPECTEDTYPE, - "warning: unexpected interface list " - "message type\n")); - return (ISC_R_IGNORE); - } -} - -/* - * Step the iterator to the next interface. Unlike - * isc_interfaceiter_next(), this may leave the iterator - * positioned on an interface that will ultimately - * be ignored. Return ISC_R_NOMORE if there are no more - * interfaces, otherwise ISC_R_SUCCESS. - */ -static isc_result_t -internal_next(isc_interfaceiter_t *iter) { - struct ifa_msghdr *ifam; - REQUIRE (iter->pos < (unsigned int) iter->bufused); - - ifam = (struct ifa_msghdr *) ((char *) iter->buf + iter->pos); - - iter->pos += ifam->ifam_msglen; - - if (iter->pos >= iter->bufused) - return (ISC_R_NOMORE); - - return (ISC_R_SUCCESS); -} - -static void -internal_destroy(isc_interfaceiter_t *iter) { - UNUSED(iter); /* Unused. */ - /* - * Do nothing. - */ -} - -static -void internal_first(isc_interfaceiter_t *iter) { - iter->pos = 0; -} diff -urN src/contrib/ntp/libisc/inet_aton.c src.ntp/contrib/ntp/libisc/inet_aton.c --- src/contrib/ntp/libisc/inet_aton.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libisc/inet_aton.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,195 +0,0 @@ -/* - * Portions Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") - * Portions Copyright (C) 1996-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH - * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY - * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM - * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE - * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ - -/* - * Copyright (c) 1983, 1990, 1993 - * The Regents of the University of California. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. All advertising materials mentioning features or use of this software - * must display the following acknowledgement: - * This product includes software developed by the University of - * California, Berkeley and its contributors. - * 4. Neither the name of the University nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ - -/* - * Portions Copyright (c) 1993 by Digital Equipment Corporation. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies, and that - * the name of Digital Equipment Corporation not be used in advertising or - * publicity pertaining to distribution of the document or software without - * specific, written prior permission. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND DIGITAL EQUIPMENT CORP. DISCLAIMS ALL - * WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL DIGITAL EQUIPMENT - * CORPORATION BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL - * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR - * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS - * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS - * SOFTWARE. - */ - -#if defined(LIBC_SCCS) && !defined(lint) -static char sccsid[] = "@(#)inet_addr.c 8.1 (Berkeley) 6/17/93"; -static char rcsid[] = "$Id: inet_aton.c,v 1.15.12.3 2004/03/08 09:04:49 marka Exp $"; -#endif /* LIBC_SCCS and not lint */ - -#include - -#include -#include /* Required for NULL. */ - -#include -#include - -/* - * Check whether "cp" is a valid ascii representation - * of an Internet address and convert to a binary address. - * Returns 1 if the address is valid, 0 if not. - * This replaces inet_addr, the return value from which - * cannot distinguish between failure and a local broadcast address. - */ -int -isc_net_aton(const char *cp, struct in_addr *addr) { - unsigned long val; - int base, n; - unsigned char c; - isc_uint8_t parts[4]; - isc_uint8_t *pp = parts; - int digit; - - c = *cp; - for (;;) { - /* - * Collect number up to ``.''. - * Values are specified as for C: - * 0x=hex, 0=octal, isdigit=decimal. - */ - if (!isdigit(c & 0xff)) - return (0); - val = 0; base = 10; digit = 0; - if (c == '0') { - c = *++cp; - if (c == 'x' || c == 'X') - base = 16, c = *++cp; - else { - base = 8; - digit = 1; - } - } - for (;;) { - /* - * isascii() is valid for all integer values, and - * when it is true, c is known to be in scope - * for isdigit(). No cast necessary. Similar - * comment applies for later ctype uses. - */ - if (isascii(c) && isdigit(c)) { - if (base == 8 && (c == '8' || c == '9')) - return (0); - val = (val * base) + (c - '0'); - c = *++cp; - digit = 1; - } else if (base == 16 && isascii(c) && isxdigit(c)) { - val = (val << 4) | - (c + 10 - (islower(c) ? 'a' : 'A')); - c = *++cp; - digit = 1; - } else - break; - } - if (c == '.') { - /* - * Internet format: - * a.b.c.d - * a.b.c (with c treated as 16 bits) - * a.b (with b treated as 24 bits) - */ - if (pp >= parts + 3 || val > 0xff) - return (0); - *pp++ = (isc_uint8_t)val; - c = *++cp; - } else - break; - } - /* - * Check for trailing characters. - */ - if (c != '\0' && (!isascii(c) || !isspace(c))) - return (0); - /* - * Did we get a valid digit? - */ - if (!digit) - return (0); - /* - * Concoct the address according to - * the number of parts specified. - */ - n = pp - parts + 1; - switch (n) { - case 1: /* a -- 32 bits */ - break; - - case 2: /* a.b -- 8.24 bits */ - if (val > 0xffffff) - return (0); - val |= parts[0] << 24; - break; - - case 3: /* a.b.c -- 8.8.16 bits */ - if (val > 0xffff) - return (0); - val |= (parts[0] << 24) | (parts[1] << 16); - break; - - case 4: /* a.b.c.d -- 8.8.8.8 bits */ - if (val > 0xff) - return (0); - val |= (parts[0] << 24) | (parts[1] << 16) | (parts[2] << 8); - break; - } - if (addr != NULL) - addr->s_addr = htonl(val); - - return (1); -} diff -urN src/contrib/ntp/libisc/inet_ntop.c src.ntp/contrib/ntp/libisc/inet_ntop.c --- src/contrib/ntp/libisc/inet_ntop.c 2004-07-20 17:01:17.000000000 +0200 +++ src.ntp/contrib/ntp/libisc/inet_ntop.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,198 +0,0 @@ -/* - * Copyright (C) 1996-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -#if defined(LIBC_SCCS) && !defined(lint) -static char rcsid[] = - "$Id: inet_ntop.c,v 1.13 2001/11/27 01:56:00 gson Exp $"; -#endif /* LIBC_SCCS and not lint */ - -#include - -#include -#include -#include - -#include - -#include "ntp_sprintf.h" - -#define NS_INT16SZ 2 -#define NS_IN6ADDRSZ 16 - -/* - * WARNING: Don't even consider trying to compile this on a system where - * sizeof(int) < 4. sizeof(int) > 4 is fine; all the world's not a VAX. - */ - -static const char *inet_ntop4(const unsigned char *src, char *dst, - size_t size); - -#ifdef AF_INET6 -static const char *inet_ntop6(const unsigned char *src, char *dst, - size_t size); -#endif - -/* char * - * isc_net_ntop(af, src, dst, size) - * convert a network format address to presentation format. - * return: - * pointer to presentation format address (`dst'), or NULL (see errno). - * author: - * Paul Vixie, 1996. - */ -const char * -isc_net_ntop(int af, const void *src, char *dst, size_t size) -{ - switch (af) { - case AF_INET: - return (inet_ntop4(src, dst, size)); -#ifdef AF_INET6 - case AF_INET6: - return (inet_ntop6(src, dst, size)); -#endif - default: - errno = EAFNOSUPPORT; - return (NULL); - } - /* NOTREACHED */ -} - -/* const char * - * inet_ntop4(src, dst, size) - * format an IPv4 address - * return: - * `dst' (as a const) - * notes: - * (1) uses no statics - * (2) takes a unsigned char* not an in_addr as input - * author: - * Paul Vixie, 1996. - */ -static const char * -inet_ntop4(const unsigned char *src, char *dst, size_t size) -{ - static const char *fmt = "%u.%u.%u.%u"; - char tmp[sizeof("255.255.255.255")]; - - if (SPRINTF((tmp, fmt, src[0], src[1], src[2], src[3])) >= size) - { - errno = ENOSPC; - return (NULL); - } - strcpy(dst, tmp); - - return (dst); -} - -/* const char * - * isc_inet_ntop6(src, dst, size) - * convert IPv6 binary address into presentation (printable) format - * author: - * Paul Vixie, 1996. - */ -#ifdef AF_INET6 -static const char * -inet_ntop6(const unsigned char *src, char *dst, size_t size) -{ - /* - * Note that int32_t and int16_t need only be "at least" large enough - * to contain a value of the specified size. On some systems, like - * Crays, there is no such thing as an integer variable with 16 bits. - * Keep this in mind if you think this function should have been coded - * to use pointer overlays. All the world's not a VAX. - */ - char tmp[sizeof("ffff:ffff:ffff:ffff:ffff:ffff:255.255.255.255")], *tp; - struct { int base, len; } best, cur; - unsigned int words[NS_IN6ADDRSZ / NS_INT16SZ]; - int i; - - /* - * Preprocess: - * Copy the input (bytewise) array into a wordwise array. - * Find the longest run of 0x00's in src[] for :: shorthanding. - */ - memset(words, '\0', sizeof(words)); - for (i = 0; i < NS_IN6ADDRSZ; i++) - words[i / 2] |= (src[i] << ((1 - (i % 2)) << 3)); - best.base = -1; - best.len = 0; - cur.base = -1; - cur.len = 0; - for (i = 0; i < (NS_IN6ADDRSZ / NS_INT16SZ); i++) { - if (words[i] == 0) { - if (cur.base == -1) - cur.base = i, cur.len = 1; - else - cur.len++; - } else { - if (cur.base != -1) { - if (best.base == -1 || cur.len > best.len) - best = cur; - cur.base = -1; - } - } - } - if (cur.base != -1) { - if (best.base == -1 || cur.len > best.len) - best = cur; - } - if (best.base != -1 && best.len < 2) - best.base = -1; - - /* - * Format the result. - */ - tp = tmp; - for (i = 0; i < (NS_IN6ADDRSZ / NS_INT16SZ); i++) { - /* Are we inside the best run of 0x00's? */ - if (best.base != -1 && i >= best.base && - i < (best.base + best.len)) { - if (i == best.base) - *tp++ = ':'; - continue; - } - /* Are we following an initial run of 0x00s or any real hex? */ - if (i != 0) - *tp++ = ':'; - /* Is this address an encapsulated IPv4? */ - if (i == 6 && best.base == 0 && - (best.len == 6 || (best.len == 5 && words[5] == 0xffff))) { - if (!inet_ntop4(src+12, tp, - sizeof(tmp) - (tp - tmp))) - return (NULL); - tp += strlen(tp); - break; - } - tp += SPRINTF((tp, "%x", words[i])); - } - /* Was it a trailing run of 0x00's? */ - if (best.base != -1 && (best.base + best.len) == - (NS_IN6ADDRSZ / NS_INT16SZ)) - *tp++ = ':'; - *tp++ = '\0'; - - /* - * Check for overflow, copy, and we're done. - */ - if ((size_t)(tp - tmp) > size) { - errno = ENOSPC; - return (NULL); - } - strcpy(dst, tmp); - return (dst); -} -#endif /* AF_INET6 */ diff -urN src/contrib/ntp/libisc/inet_pton.c src.ntp/contrib/ntp/libisc/inet_pton.c --- src/contrib/ntp/libisc/inet_pton.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libisc/inet_pton.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,211 +0,0 @@ -/* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") - * Copyright (C) 1996-2003 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH - * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY - * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM - * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE - * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ - -#if defined(LIBC_SCCS) && !defined(lint) -static char rcsid[] = - "$Id: inet_pton.c,v 1.10.2.4.2.1 2004/03/06 08:14:31 marka Exp $"; -#endif /* LIBC_SCCS and not lint */ - -#include - -#include -#include - -#include - -#define NS_INT16SZ 2 -#define NS_INADDRSZ 4 -#define NS_IN6ADDRSZ 16 - -/* - * WARNING: Don't even consider trying to compile this on a system where - * sizeof(int) < 4. sizeof(int) > 4 is fine; all the world's not a VAX. - */ - -static int inet_pton4(const char *src, unsigned char *dst); -static int inet_pton6(const char *src, unsigned char *dst); - -/* int - * isc_net_pton(af, src, dst) - * convert from presentation format (which usually means ASCII printable) - * to network format (which is usually some kind of binary format). - * return: - * 1 if the address was valid for the specified address family - * 0 if the address wasn't valid (`dst' is untouched in this case) - * -1 if some other error occurred (`dst' is untouched in this case, too) - * author: - * Paul Vixie, 1996. - */ -int -isc_net_pton(int af, const char *src, void *dst) { - switch (af) { - case AF_INET: - return (inet_pton4(src, dst)); - case AF_INET6: - return (inet_pton6(src, dst)); - default: - errno = EAFNOSUPPORT; - return (-1); - } - /* NOTREACHED */ -} - -/* int - * inet_pton4(src, dst) - * like inet_aton() but without all the hexadecimal and shorthand. - * return: - * 1 if `src' is a valid dotted quad, else 0. - * notice: - * does not touch `dst' unless it's returning 1. - * author: - * Paul Vixie, 1996. - */ -static int -inet_pton4(const char *src, unsigned char *dst) { - static const char digits[] = "0123456789"; - int saw_digit, octets, ch; - unsigned char tmp[NS_INADDRSZ], *tp; - - saw_digit = 0; - octets = 0; - *(tp = tmp) = 0; - while ((ch = *src++) != '\0') { - const char *pch; - - if ((pch = strchr(digits, ch)) != NULL) { - unsigned int new = *tp * 10 + (pch - digits); - - if (saw_digit && *tp == 0) - return (0); - if (new > 255) - return (0); - *tp = (unsigned char) new; - if (!saw_digit) { - if (++octets > 4) - return (0); - saw_digit = 1; - } - } else if (ch == '.' && saw_digit) { - if (octets == 4) - return (0); - *++tp = 0; - saw_digit = 0; - } else - return (0); - } - if (octets < 4) - return (0); - memcpy(dst, tmp, NS_INADDRSZ); - return (1); -} - -/* int - * inet_pton6(src, dst) - * convert presentation level address to network order binary form. - * return: - * 1 if `src' is a valid [RFC1884 2.2] address, else 0. - * notice: - * (1) does not touch `dst' unless it's returning 1. - * (2) :: in a full address is silently ignored. - * credit: - * inspired by Mark Andrews. - * author: - * Paul Vixie, 1996. - */ -static int -inet_pton6(const char *src, unsigned char *dst) { - static const char xdigits_l[] = "0123456789abcdef", - xdigits_u[] = "0123456789ABCDEF"; - unsigned char tmp[NS_IN6ADDRSZ], *tp, *endp, *colonp; - const char *xdigits, *curtok; - int ch, saw_xdigit; - unsigned int val; - - memset((tp = tmp), '\0', NS_IN6ADDRSZ); - endp = tp + NS_IN6ADDRSZ; - colonp = NULL; - /* Leading :: requires some special handling. */ - if (*src == ':') - if (*++src != ':') - return (0); - curtok = src; - saw_xdigit = 0; - val = 0; - while ((ch = *src++) != '\0') { - const char *pch; - - if ((pch = strchr((xdigits = xdigits_l), ch)) == NULL) - pch = strchr((xdigits = xdigits_u), ch); - if (pch != NULL) { - val <<= 4; - val |= (pch - xdigits); - if (val > 0xffff) - return (0); - saw_xdigit = 1; - continue; - } - if (ch == ':') { - curtok = src; - if (!saw_xdigit) { - if (colonp) - return (0); - colonp = tp; - continue; - } - if (tp + NS_INT16SZ > endp) - return (0); - *tp++ = (unsigned char) ((val >> 8) & 0xff); - *tp++ = (unsigned char) (val & 0xff); - saw_xdigit = 0; - val = 0; - continue; - } - if (ch == '.' && ((tp + NS_INADDRSZ) <= endp) && - inet_pton4(curtok, tp) > 0) { - tp += NS_INADDRSZ; - saw_xdigit = 0; - break; /* '\0' was seen by inet_pton4(). */ - } - return (0); - } - if (saw_xdigit) { - if (tp + NS_INT16SZ > endp) - return (0); - *tp++ = (unsigned char) ((val >> 8) & 0xff); - *tp++ = (unsigned char) (val & 0xff); - } - if (colonp != NULL) { - /* - * Since some memmove()'s erroneously fail to handle - * overlapping regions, we'll do the shift by hand. - */ - const int n = tp - colonp; - int i; - - if (tp == endp) - return (0); - for (i = 1; i <= n; i++) { - endp[- i] = colonp[n - i]; - colonp[n - i] = 0; - } - tp = endp; - } - if (tp != endp) - return (0); - memcpy(dst, tmp, NS_IN6ADDRSZ); - return (1); -} diff -urN src/contrib/ntp/libisc/interfaceiter.c src.ntp/contrib/ntp/libisc/interfaceiter.c --- src/contrib/ntp/libisc/interfaceiter.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libisc/interfaceiter.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,220 +0,0 @@ -/* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") - * Copyright (C) 1999-2003 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH - * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY - * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM - * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE - * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: interfaceiter.c,v 1.22.2.1.10.14 2004/08/28 06:25:22 marka Exp $ */ - -#include - -#define ISC_ONLY_IPV6 - -#include -#include -#ifdef HAVE_SYS_SOCKIO_H -#include /* Required for ifiter_ioctl.c. */ -#endif - -#include -#include -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -/* Must follow . */ -#ifdef HAVE_NET_IF6_H -#include -#endif - -/* Common utility functions */ - -/* - * Extract the network address part from a "struct sockaddr". - * - * The address family is given explicitly - * instead of using src->sa_family, because the latter does not work - * for copying a network mask obtained by SIOCGIFNETMASK (it does - * not have a valid address family). - */ - -static void -get_addr(unsigned int family, isc_netaddr_t *dst, struct sockaddr *src, - char *ifname) -{ - struct sockaddr_in6 *sa6; - -#if !defined(ISC_PLATFORM_HAVEIFNAMETOINDEX) || \ - !defined(ISC_PLATFORM_HAVESCOPEID) - UNUSED(ifname); -#endif - - /* clear any remaining value for safety */ - memset(dst, 0, sizeof(*dst)); - - dst->family = family; - switch (family) { - case AF_INET: - memcpy(&dst->type.in, - &((struct sockaddr_in *) src)->sin_addr, - sizeof(struct in_addr)); - break; - case AF_INET6: - sa6 = (struct sockaddr_in6 *)src; - memcpy(&dst->type.in6, &sa6->sin6_addr, - sizeof(struct in6_addr)); -#ifdef ISC_PLATFORM_HAVESCOPEID - if (sa6->sin6_scope_id != 0) - isc_netaddr_setzone(dst, sa6->sin6_scope_id); - else { - /* - * BSD variants embed scope zone IDs in the 128bit - * address as a kernel internal form. Unfortunately, - * the embedded IDs are not hidden from applications - * when getting access to them by sysctl or ioctl. - * We convert the internal format to the pure address - * part and the zone ID part. - * Since multicast addresses should not appear here - * and they cannot be distinguished from netmasks, - * we only consider unicast link-local addresses. - */ - if (IN6_IS_ADDR_LINKLOCAL(&sa6->sin6_addr)) { - isc_uint16_t zone16; - - memcpy(&zone16, &sa6->sin6_addr.s6_addr[2], - sizeof(zone16)); - zone16 = ntohs(zone16); - if (zone16 != 0) { - /* the zone ID is embedded */ - isc_netaddr_setzone(dst, - (isc_uint32_t)zone16); - dst->type.in6.s6_addr[2] = 0; - dst->type.in6.s6_addr[3] = 0; -#ifdef ISC_PLATFORM_HAVEIFNAMETOINDEX - } else if (ifname != NULL) { - unsigned int zone; - - /* - * sin6_scope_id is still not provided, - * but the corresponding interface name - * is know. Use the interface ID as - * the link ID. - */ - zone = if_nametoindex(ifname); - if (zone != 0) { - isc_netaddr_setzone(dst, - (isc_uint32_t)zone); - } -#endif - } - } - } -#endif - break; - default: - INSIST(0); - break; - } -} - -/* - * Include system-dependent code. - */ - -#if HAVE_GETIFADDRS -#include "ifiter_getifaddrs.c" -#elif HAVE_IFLIST_SYSCTL -#include "ifiter_sysctl.c" -#else -#include "ifiter_ioctl.c" -#endif - -/* - * The remaining code is common to the sysctl and ioctl case. - */ - -isc_result_t -isc_interfaceiter_current(isc_interfaceiter_t *iter, - isc_interface_t *ifdata) -{ - REQUIRE(iter->result == ISC_R_SUCCESS); - memcpy(ifdata, &iter->current, sizeof(*ifdata)); - return (ISC_R_SUCCESS); -} - -isc_result_t -isc_interfaceiter_first(isc_interfaceiter_t *iter) { - isc_result_t result; - - REQUIRE(VALID_IFITER(iter)); - - internal_first(iter); - for (;;) { - result = internal_current(iter); - if (result != ISC_R_IGNORE) - break; - result = internal_next(iter); - if (result != ISC_R_SUCCESS) - break; - } - iter->result = result; - return (result); -} - -isc_result_t -isc_interfaceiter_next(isc_interfaceiter_t *iter) { - isc_result_t result; - - REQUIRE(VALID_IFITER(iter)); - REQUIRE(iter->result == ISC_R_SUCCESS); - - for (;;) { - result = internal_next(iter); - if (result != ISC_R_SUCCESS) - break; - result = internal_current(iter); - if (result != ISC_R_IGNORE) - break; - } - iter->result = result; - return (result); -} - -void -isc_interfaceiter_destroy(isc_interfaceiter_t **iterp) -{ - isc_interfaceiter_t *iter; - REQUIRE(iterp != NULL); - iter = *iterp; - REQUIRE(VALID_IFITER(iter)); - - internal_destroy(iter); - if (iter->buf != NULL) - isc_mem_put(iter->mctx, iter->buf, iter->bufsize); - - iter->magic = 0; - isc_mem_put(iter->mctx, iter, sizeof(*iter)); - *iterp = NULL; -} diff -urN src/contrib/ntp/libisc/isc_strerror.c src.ntp/contrib/ntp/libisc/isc_strerror.c --- src/contrib/ntp/libisc/isc_strerror.c 2004-07-20 17:01:17.000000000 +0200 +++ src.ntp/contrib/ntp/libisc/isc_strerror.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,74 +0,0 @@ -/* - * Copyright (C) 2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: strerror.c,v 1.3 2001/11/20 01:45:45 gson Exp $ */ - -#include - -#include -#include - -#include -#include -#include -#include -#include - -#include "l_stdlib.h" - -#ifdef HAVE_STRERROR -/* - * We need to do this this way for profiled locks. - */ -static isc_mutex_t isc_strerror_lock; -static void init_lock(void) { - RUNTIME_CHECK(isc_mutex_init(&isc_strerror_lock) == ISC_R_SUCCESS); -} -#else -extern const char * const sys_errlist[]; -extern const int sys_nerr; -#endif - -void -isc__strerror(int num, char *buf, size_t size) { -#ifdef HAVE_STRERROR - char *msg; - unsigned int unum = num; - static isc_once_t once = ISC_ONCE_INIT; - - REQUIRE(buf != NULL); - - RUNTIME_CHECK(isc_once_do(&once, init_lock) == ISC_R_SUCCESS); - - LOCK(&isc_strerror_lock); - msg = strerror(num); - if (msg != NULL) - snprintf(buf, size, "%s", msg); - else - snprintf(buf, size, "Unknown error: %u", unum); - UNLOCK(&isc_strerror_lock); -#else - unsigned int unum = num; - - REQUIRE(buf != NULL); - - if (num >= 0 && num < sys_nerr) - snprintf(buf, size, "%s", sys_errlist[num]); - else - snprintf(buf, size, "Unknown error: %u", unum); -#endif -} diff -urN src/contrib/ntp/libisc/lib.c src.ntp/contrib/ntp/libisc/lib.c --- src/contrib/ntp/libisc/lib.c 2004-07-20 17:01:17.000000000 +0200 +++ src.ntp/contrib/ntp/libisc/lib.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,77 +0,0 @@ -/* - * Copyright (C) 1999-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: lib.c,v 1.9 2001/11/19 03:08:23 mayer Exp $ */ - -#include - -#include -#include - -#include -#include -#include - -/*** - *** Globals - ***/ - -LIBISC_EXTERNAL_DATA isc_msgcat_t * isc_msgcat = NULL; - - -/*** - *** Private - ***/ - -static isc_once_t msgcat_once = ISC_ONCE_INIT; - - -/*** - *** Functions - ***/ - -static void -open_msgcat(void) { - isc_msgcat_open("libisc.cat", &isc_msgcat); -} - -void -isc_lib_initmsgcat(void) { - isc_result_t result; - - /* - * Initialize the ISC library's message catalog, isc_msgcat, if it - * has not already been initialized. - */ - - result = isc_once_do(&msgcat_once, open_msgcat); - if (result != ISC_R_SUCCESS) { - /* - * Normally we'd use RUNTIME_CHECK() or FATAL_ERROR(), but - * we can't do that here, since they might call us! - * (Note that the catalog might be open anyway, so we might - * as well try to provide an internationalized message.) - */ - fprintf(stderr, "%s:%d: %s: isc_once_do() %s.\n", - __FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, - ISC_MSG_FATALERROR, "fatal error"), - isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, - ISC_MSG_FAILED, "failed")); - abort(); - } -} diff -urN src/contrib/ntp/libisc/mem.c src.ntp/contrib/ntp/libisc/mem.c --- src/contrib/ntp/libisc/mem.c 2004-07-20 17:01:17.000000000 +0200 +++ src.ntp/contrib/ntp/libisc/mem.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,42 +0,0 @@ -/* - * Copyright (C) 1997-2002 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: mem.c,v 1.113 2002/05/23 04:32:30 marka Exp $ */ - -#include -#include -#include - -#include -#include - -void * -isc_mem_get(isc_mem_t *ctx, size_t size) { - UNUSED(ctx); - if(size == 0) - size = 1; - return (malloc(size)); -} - -void -isc_mem_put(isc_mem_t *ctx, void *ptr, size_t size) -{ - UNUSED(ctx); - UNUSED(size); - free(ptr); -} - diff -urN src/contrib/ntp/libisc/msgcat.c src.ntp/contrib/ntp/libisc/msgcat.c --- src/contrib/ntp/libisc/msgcat.c 2004-07-20 17:01:18.000000000 +0200 +++ src.ntp/contrib/ntp/libisc/msgcat.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,130 +0,0 @@ -/* - * Copyright (C) 1999-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: msgcat.c,v 1.12 2001/11/30 01:59:39 gson Exp $ */ - -/* - * Principal Author: Bob Halley - */ - -#include - -#include -#include - -#include -#include -#include - -#ifdef HAVE_CATGETS -#include /* Required for nl_catd. */ -#endif - -/* - * Implementation Notes: - * - * We use malloc() and free() instead of isc_mem_get() and isc_mem_put() - * because we don't want to require a memory context to be specified - * in order to use a message catalog. - */ - -struct isc_msgcat { - unsigned int magic; -#ifdef HAVE_CATGETS - nl_catd catalog; -#endif -}; - -#define MSGCAT_MAGIC ISC_MAGIC('M', 'C', 'a', 't') -#define VALID_MSGCAT(m) ISC_MAGIC_VALID(m, MSGCAT_MAGIC) - -void -isc_msgcat_open(const char *name, isc_msgcat_t **msgcatp) { - isc_msgcat_t *msgcat; - - /* - * Open a message catalog. - */ - - REQUIRE(name != NULL); - REQUIRE(msgcatp != NULL && *msgcatp == NULL); - - msgcat = malloc(sizeof(*msgcat)); - if (msgcat == NULL) { - *msgcatp = NULL; - return; - } - -#ifdef HAVE_CATGETS - /* - * We don't check if catopen() fails because we don't care. - * If it does fail, then when we call catgets(), it will use - * the default string. - */ - msgcat->catalog = catopen(name, 0); -#endif - msgcat->magic = MSGCAT_MAGIC; - - *msgcatp = msgcat; -} - -void -isc_msgcat_close(isc_msgcat_t **msgcatp) { - isc_msgcat_t *msgcat; - - /* - * Close a message catalog. - */ - - REQUIRE(msgcatp != NULL); - msgcat = *msgcatp; - REQUIRE(VALID_MSGCAT(msgcat) || msgcat == NULL); - - if (msgcat != NULL) { -#ifdef HAVE_CATGETS - if (msgcat->catalog != (nl_catd)(-1)) - (void)catclose(msgcat->catalog); -#endif - msgcat->magic = 0; - free(msgcat); - } - - *msgcatp = NULL; -} - -const char * -isc_msgcat_get(isc_msgcat_t *msgcat, int set, int message, - const char *default_text) -{ - /* - * Get message 'message' from message set 'set' in 'msgcat'. If it - * is not available, use 'default'. - */ - - REQUIRE(VALID_MSGCAT(msgcat) || msgcat == NULL); - REQUIRE(set > 0); - REQUIRE(message > 0); - REQUIRE(default_text != NULL); - -#ifdef HAVE_CATGETS - if (msgcat == NULL) - return (default_text); - return (catgets(msgcat->catalog, set, message, default_text)); -#else - return (default_text); -#endif -} diff -urN src/contrib/ntp/libisc/net.c src.ntp/contrib/ntp/libisc/net.c --- src/contrib/ntp/libisc/net.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libisc/net.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,311 +0,0 @@ -/* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") - * Copyright (C) 1999-2003 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH - * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY - * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM - * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE - * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: net.c,v 1.22.2.2.10.7 2004/04/29 01:31:22 marka Exp $ */ - -#include - -#include -#include - -#include -#include -#include -#include -#include - -#if defined(ISC_PLATFORM_HAVEIPV6) && defined(ISC_PLATFORM_NEEDIN6ADDRANY) -const struct in6_addr isc_net_in6addrany = IN6ADDR_ANY_INIT; -#endif - -#if defined(ISC_PLATFORM_HAVEIPV6) && defined(ISC_PLATFORM_NEEDIN6ADDRLOOPBACK) -const struct in6_addr isc_net_in6addrloop = IN6ADDR_LOOPBACK_INIT; -#endif - -static isc_boolean_t once = ISC_FALSE; -static isc_once_t once_ipv6only = ISC_ONCE_INIT; -static isc_once_t once_ipv6pktinfo = ISC_ONCE_INIT; -static isc_result_t ipv4_result = ISC_R_NOTFOUND; -static isc_result_t ipv6_result = ISC_R_NOTFOUND; -static isc_result_t ipv6only_result = ISC_R_NOTFOUND; -static isc_result_t ipv6pktinfo_result = ISC_R_NOTFOUND; - -static isc_result_t -try_proto(int domain) { - int s; - isc_result_t result = ISC_R_SUCCESS; - char strbuf[ISC_STRERRORSIZE]; - - s = socket(domain, SOCK_STREAM, 0); - if (s == -1) { - switch (errno) { -#ifdef EAFNOSUPPORT - case EAFNOSUPPORT: -#endif -#ifdef EPROTONOSUPPORT - case EPROTONOSUPPORT: -#endif -#ifdef EINVAL - case EINVAL: -#endif - return (ISC_R_NOTFOUND); - default: - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - "socket() failed: %s", - strbuf); - return (ISC_R_UNEXPECTED); - } - } - -#ifdef ISC_PLATFORM_HAVEIPV6 -#ifdef WANT_IPV6 -#ifdef ISC_PLATFORM_HAVEIN6PKTINFO - if (domain == PF_INET6) { - struct sockaddr_in6 sin6; - GETSOCKNAME_SOCKLEN_TYPE len; - - /* - * Check to see if IPv6 is broken, as is common on Linux. - */ - len = sizeof(sin6); - if (getsockname(s, (struct sockaddr *)&sin6, &len) < 0) - { - result = ISC_R_NOTFOUND; - } else { - if (len == sizeof(struct sockaddr_in6)) - result = ISC_R_SUCCESS; - else { - result = ISC_R_NOTFOUND; - } - } - } -#endif -#endif -#endif - - (void)close(s); - - return (result); -} - -static void -initialize_action(void) { - ipv4_result = try_proto(PF_INET); -#ifdef ISC_PLATFORM_HAVEIPV6 -#ifdef WANT_IPV6 -#ifdef ISC_PLATFORM_HAVEIN6PKTINFO - ipv6_result = try_proto(PF_INET6); -#endif -#endif -#endif -} - -static void -initialize(void) { - if(once == ISC_FALSE) { - initialize_action(); - once = ISC_TRUE; - } -} - -isc_result_t -isc_net_probeipv4(void) { - initialize(); - return (ipv4_result); -} - -isc_result_t -isc_net_probeipv6(void) { - initialize(); - return (ipv6_result); -} - -#ifdef ISC_PLATFORM_HAVEIPV6 -#ifdef WANT_IPV6 -static void -try_ipv6only(void) { -#ifdef IPV6_V6ONLY - int s, on; - char strbuf[ISC_STRERRORSIZE]; -#endif - isc_result_t result; - - result = isc_net_probeipv6(); - if (result != ISC_R_SUCCESS) { - ipv6only_result = result; - return; - } - -#ifndef IPV6_V6ONLY - ipv6only_result = ISC_R_NOTFOUND; - return; -#else - /* check for TCP sockets */ - s = socket(PF_INET6, SOCK_STREAM, 0); - if (s == -1) { - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - "socket() failed: %s", - strbuf); - ipv6only_result = ISC_R_UNEXPECTED; - return; - } - - on = 1; - if (setsockopt(s, IPPROTO_IPV6, IPV6_V6ONLY, &on, sizeof(on)) < 0) { - ipv6only_result = ISC_R_NOTFOUND; - goto close; - } - - close(s); - - /* check for UDP sockets */ - s = socket(PF_INET6, SOCK_DGRAM, 0); - if (s == -1) { - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - "socket() failed: %s", - strbuf); - ipv6only_result = ISC_R_UNEXPECTED; - return; - } - - on = 1; - if (setsockopt(s, IPPROTO_IPV6, IPV6_V6ONLY, &on, sizeof(on)) < 0) { - ipv6only_result = ISC_R_NOTFOUND; - goto close; - } - - close(s); - - ipv6only_result = ISC_R_SUCCESS; - -close: - close(s); - return; -#endif /* IPV6_V6ONLY */ -} - -static void -initialize_ipv6only(void) { - RUNTIME_CHECK(isc_once_do(&once_ipv6only, - try_ipv6only) == ISC_R_SUCCESS); -} - -static void -try_ipv6pktinfo(void) { - int s, on; - char strbuf[ISC_STRERRORSIZE]; - isc_result_t result; - int optname; - - result = isc_net_probeipv6(); - if (result != ISC_R_SUCCESS) { - ipv6pktinfo_result = result; - return; - } - - /* we only use this for UDP sockets */ - s = socket(PF_INET6, SOCK_DGRAM, IPPROTO_UDP); - if (s == -1) { - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - "socket() failed: %s", - strbuf); - ipv6pktinfo_result = ISC_R_UNEXPECTED; - return; - } - -#ifdef IPV6_RECVPKTINFO - optname = IPV6_RECVPKTINFO; -#else - optname = IPV6_PKTINFO; -#endif - on = 1; - if (setsockopt(s, IPPROTO_IPV6, optname, &on, sizeof(on)) < 0) { - ipv6pktinfo_result = ISC_R_NOTFOUND; - goto close; - } - - close(s); - ipv6pktinfo_result = ISC_R_SUCCESS; - -close: - close(s); - return; -} - -static void -initialize_ipv6pktinfo(void) { - RUNTIME_CHECK(isc_once_do(&once_ipv6pktinfo, - try_ipv6pktinfo) == ISC_R_SUCCESS); -} -#endif /* WANT_IPV6 */ -#endif /* ISC_PLATFORM_HAVEIPV6 */ - -isc_result_t -isc_net_probe_ipv6only(void) { -#ifdef ISC_PLATFORM_HAVEIPV6 -#ifdef WANT_IPV6 - initialize_ipv6only(); -#else - ipv6only_result = ISC_R_NOTFOUND; -#endif -#endif - return (ipv6only_result); -} - -isc_result_t -isc_net_probe_ipv6pktinfo(void) { -#ifdef ISC_PLATFORM_HAVEIPV6 -#ifdef WANT_IPV6 - initialize_ipv6pktinfo(); -#else - ipv6pktinfo_result = ISC_R_NOTFOUND; -#endif -#endif - return (ipv6pktinfo_result); -} - -void -isc_net_disableipv4(void) { - initialize(); - if (ipv4_result == ISC_R_SUCCESS) - ipv4_result = ISC_R_DISABLED; -} - -void -isc_net_disableipv6(void) { - initialize(); - if (ipv6_result == ISC_R_SUCCESS) - ipv6_result = ISC_R_DISABLED; -} - -void -isc_net_enableipv4(void) { - initialize(); - if (ipv4_result == ISC_R_DISABLED) - ipv4_result = ISC_R_SUCCESS; -} - -void -isc_net_enableipv6(void) { - initialize(); - if (ipv6_result == ISC_R_DISABLED) - ipv6_result = ISC_R_SUCCESS; -} diff -urN src/contrib/ntp/libisc/netaddr.c src.ntp/contrib/ntp/libisc/netaddr.c --- src/contrib/ntp/libisc/netaddr.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libisc/netaddr.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,363 +0,0 @@ -/* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") - * Copyright (C) 1999-2002 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH - * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY - * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM - * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE - * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: netaddr.c,v 1.18.12.9 2004/05/15 03:46:12 jinmei Exp $ */ - -#include - -#define ISC_ONLY_IPV6 - -#include - -#include -#include -#include -#include -#include -#include -#include -#include - -isc_boolean_t -isc_netaddr_equal(const isc_netaddr_t *a, const isc_netaddr_t *b) { - REQUIRE(a != NULL && b != NULL); - - if (a->family != b->family) - return (ISC_FALSE); - - if (a->zone != b->zone) - return (ISC_FALSE); - - switch (a->family) { - case AF_INET: - if (a->type.in.s_addr != b->type.in.s_addr) - return (ISC_FALSE); - break; - case AF_INET6: - if (memcmp(&a->type.in6, &b->type.in6, - sizeof(a->type.in6)) != 0 || - a->zone != b->zone) - return (ISC_FALSE); - break; - default: - return (ISC_FALSE); - } - return (ISC_TRUE); -} - -isc_boolean_t -isc_netaddr_eqprefix(const isc_netaddr_t *a, const isc_netaddr_t *b, - unsigned int prefixlen) -{ - const unsigned char *pa, *pb; - unsigned int ipabytes; /* Length of whole IP address in bytes */ - unsigned int nbytes; /* Number of significant whole bytes */ - unsigned int nbits; /* Number of significant leftover bits */ - - REQUIRE(a != NULL && b != NULL); - - if (a->family != b->family) - return (ISC_FALSE); - - if (a->zone != b->zone) - return (ISC_FALSE); - - switch (a->family) { - case AF_INET: - pa = (const unsigned char *) &a->type.in; - pb = (const unsigned char *) &b->type.in; - ipabytes = 4; - break; - case AF_INET6: - pa = (const unsigned char *) &a->type.in6; - pb = (const unsigned char *) &b->type.in6; - ipabytes = 16; - break; - default: - pa = pb = NULL; /* Avoid silly compiler warning. */ - ipabytes = 0; /* Ditto. */ - return (ISC_FALSE); - } - - /* - * Don't crash if we get a pattern like 10.0.0.1/9999999. - */ - if (prefixlen > ipabytes * 8) - prefixlen = ipabytes * 8; - - nbytes = prefixlen / 8; - nbits = prefixlen % 8; - - if (nbytes > 0) { - if (memcmp(pa, pb, nbytes) != 0) - return (ISC_FALSE); - } - if (nbits > 0) { - unsigned int bytea, byteb, mask; - INSIST(nbytes < ipabytes); - INSIST(nbits < 8); - bytea = pa[nbytes]; - byteb = pb[nbytes]; - mask = (0xFF << (8-nbits)) & 0xFF; - if ((bytea & mask) != (byteb & mask)) - return (ISC_FALSE); - } - return (ISC_TRUE); -} - -isc_result_t -isc_netaddr_totext(const isc_netaddr_t *netaddr, isc_buffer_t *target) { - char abuf[sizeof("xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:255.255.255.255")]; - char zbuf[sizeof("%4294967295")]; - unsigned int alen; - int zlen; - const char *r; - const void *type; - - REQUIRE(netaddr != NULL); - - switch (netaddr->family) { - case AF_INET: - type = &netaddr->type.in; - break; - case AF_INET6: - type = &netaddr->type.in6; - break; - default: - return (ISC_R_FAILURE); - } - r = inet_ntop(netaddr->family, type, abuf, sizeof(abuf)); - if (r == NULL) - return (ISC_R_FAILURE); - - alen = strlen(abuf); - INSIST(alen < sizeof(abuf)); - - zlen = 0; - if (netaddr->family == AF_INET6 && netaddr->zone != 0) { - zlen = snprintf(zbuf, sizeof(zbuf), "%%%u", netaddr->zone); - if (zlen < 0) - return (ISC_R_FAILURE); - INSIST((unsigned int)zlen < sizeof(zbuf)); - } - - if (alen + zlen > isc_buffer_availablelength(target)) - return (ISC_R_NOSPACE); - - isc_buffer_putmem(target, (unsigned char *)abuf, alen); - isc_buffer_putmem(target, (unsigned char *)zbuf, zlen); - - return (ISC_R_SUCCESS); -} - -void -isc_netaddr_format(const isc_netaddr_t *na, char *array, unsigned int size) { - isc_result_t result; - isc_buffer_t buf; - - isc_buffer_init(&buf, array, size); - result = isc_netaddr_totext(na, &buf); - - /* - * Null terminate. - */ - if (result == ISC_R_SUCCESS) { - if (isc_buffer_availablelength(&buf) >= 1) - isc_buffer_putuint8(&buf, 0); - else - result = ISC_R_NOSPACE; - } - - if (result != ISC_R_SUCCESS) { - snprintf(array, size, - isc_msgcat_get(isc_msgcat, ISC_MSGSET_NETADDR, - ISC_MSG_UNKNOWNADDR, - ""), - na->family); - array[size - 1] = '\0'; - } -} - -isc_result_t -isc_netaddr_masktoprefixlen(const isc_netaddr_t *s, unsigned int *lenp) { - unsigned int nbits, nbytes, ipbytes, i; - const unsigned char *p; - - switch (s->family) { - case AF_INET: - p = (const unsigned char *) &s->type.in; - ipbytes = 4; - break; - case AF_INET6: - p = (const unsigned char *) &s->type.in6; - ipbytes = 16; - break; - default: - ipbytes = 0; - return (ISC_R_NOTIMPLEMENTED); - } - nbytes = nbits = 0; - for (i = 0; i < ipbytes; i++) { - if (p[i] != 0xFF) - break; - } - nbytes = i; - if (i < ipbytes) { - unsigned int c = p[nbytes]; - while ((c & 0x80) != 0 && nbits < 8) { - c <<= 1; nbits++; - } - if ((c & 0xFF) != 0) - return (ISC_R_MASKNONCONTIG); - i++; - } - for (; i < ipbytes; i++) { - if (p[i] != 0) - return (ISC_R_MASKNONCONTIG); - i++; - } - *lenp = nbytes * 8 + nbits; - return (ISC_R_SUCCESS); -} - -void -isc_netaddr_fromin(isc_netaddr_t *netaddr, const struct in_addr *ina) { - memset(netaddr, 0, sizeof(*netaddr)); - netaddr->family = AF_INET; - netaddr->type.in = *ina; -} - -void -isc_netaddr_fromin6(isc_netaddr_t *netaddr, const struct in6_addr *ina6) { - memset(netaddr, 0, sizeof(*netaddr)); - netaddr->family = AF_INET6; - netaddr->type.in6 = *ina6; -} - -void -isc_netaddr_setzone(isc_netaddr_t *netaddr, isc_uint32_t zone) { - /* we currently only support AF_INET6. */ - REQUIRE(netaddr->family == AF_INET6); - - netaddr->zone = zone; -} - -isc_uint32_t -isc_netaddr_getzone(const isc_netaddr_t *netaddr) { - return (netaddr->zone); -} - -void -isc_netaddr_fromsockaddr(isc_netaddr_t *t, const isc_sockaddr_t *s) { - int family = s->type.sa.sa_family; - t->family = family; - switch (family) { - case AF_INET: - t->type.in = s->type.sin.sin_addr; - t->zone = 0; - break; - case AF_INET6: - memcpy(&t->type.in6, &s->type.sin6.sin6_addr, 16); -#ifdef ISC_PLATFORM_HAVESCOPEID - t->zone = s->type.sin6.sin6_scope_id; -#else - t->zone = 0; -#endif - break; - default: - INSIST(0); - } -} - -void -isc_netaddr_any(isc_netaddr_t *netaddr) { - memset(netaddr, 0, sizeof(*netaddr)); - netaddr->family = AF_INET; - netaddr->type.in.s_addr = INADDR_ANY; -} - -#ifdef ISC_PLATFORM_HAVEIPV6 -void -isc_netaddr_any6(isc_netaddr_t *netaddr) { - memset(netaddr, 0, sizeof(*netaddr)); - netaddr->family = AF_INET6; - netaddr->type.in6 = in6addr_any; -} -#endif - -isc_boolean_t -isc_netaddr_ismulticast(isc_netaddr_t *na) { - switch (na->family) { - case AF_INET: - return (ISC_TF(ISC_IPADDR_ISMULTICAST(na->type.in.s_addr))); - case AF_INET6: - return (ISC_TF(IN6_IS_ADDR_MULTICAST(&na->type.in6))); - default: - return (ISC_FALSE); /* XXXMLG ? */ - } -} - -isc_boolean_t -isc_netaddr_isexperimental(isc_netaddr_t *na) { - switch (na->family) { - case AF_INET: - return (ISC_TF(ISC_IPADDR_ISEXPERIMENTAL(na->type.in.s_addr))); - default: - return (ISC_FALSE); /* XXXMLG ? */ - } -} - -isc_boolean_t -isc_netaddr_islinklocal(isc_netaddr_t *na) { - switch (na->family) { - case AF_INET: - return (ISC_FALSE); - case AF_INET6: - return (ISC_TF(IN6_IS_ADDR_LINKLOCAL(&na->type.in6))); - default: - return (ISC_FALSE); - } -} - -isc_boolean_t -isc_netaddr_issitelocal(isc_netaddr_t *na) { - switch (na->family) { - case AF_INET: - return (ISC_FALSE); - case AF_INET6: - return (ISC_TF(IN6_IS_ADDR_SITELOCAL(&na->type.in6))); - default: - return (ISC_FALSE); - } -} - -#ifdef ISC_PLATFORM_HAVEIPV6 -void -isc_netaddr_fromv4mapped(isc_netaddr_t *t, const isc_netaddr_t *s) { - isc_netaddr_t *src; - - DE_CONST(s, src); /* Must come before IN6_IS_ADDR_V4MAPPED. */ - - REQUIRE(s->family == AF_INET6); - REQUIRE(IN6_IS_ADDR_V4MAPPED(&src->type.in6)); - - memset(t, 0, sizeof(*t)); - t->family = AF_INET; - memcpy(&t->type.in, (char *)&src->type.in6 + 12, 4); - return; -} -#endif diff -urN src/contrib/ntp/libisc/netscope.c src.ntp/contrib/ntp/libisc/netscope.c --- src/contrib/ntp/libisc/netscope.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libisc/netscope.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,74 +0,0 @@ -/* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") - * Copyright (C) 2002 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH - * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY - * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM - * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE - * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ - -#if defined(LIBC_SCCS) && !defined(lint) -static char rcsid[] = - "$Id: netscope.c,v 1.5.142.7 2004/03/12 10:31:26 marka Exp $"; -#endif /* LIBC_SCCS and not lint */ - -#include - -#include -#include -#include -#include - -isc_result_t -isc_netscope_pton(int af, char *scopename, void *addr, isc_uint32_t *zoneid) { - char *ep; -#ifdef ISC_PLATFORM_HAVEIFNAMETOINDEX - unsigned int ifid; -#endif - struct in6_addr *in6; - isc_uint32_t zone; - isc_uint64_t llz; - - /* at this moment, we only support AF_INET6 */ - if (af != AF_INET6) - return (ISC_R_FAILURE); - - in6 = (struct in6_addr *)addr; - - /* - * Basically, "names" are more stable than numeric IDs in terms of - * renumbering, and are more preferred. However, since there is no - * standard naming convention and APIs to deal with the names. Thus, - * we only handle the case of link-local addresses, for which we use - * interface names as link names, assuming one to one mapping between - * interfaces and links. - */ -#ifdef ISC_PLATFORM_HAVEIFNAMETOINDEX - if (IN6_IS_ADDR_LINKLOCAL(in6) && - (ifid = if_nametoindex((const char *)scopename)) != 0) - zone = (isc_uint32_t)ifid; - else { -#endif - llz = isc_string_touint64(scopename, &ep, 10); - if (ep == scopename) - return (ISC_R_FAILURE); - - /* check overflow */ - zone = (isc_uint32_t)(llz & 0xffffffffUL); - if (zone != llz) - return (ISC_R_FAILURE); -#ifdef ISC_PLATFORM_HAVEIFNAMETOINDEX - } -#endif - - *zoneid = zone; - return (ISC_R_SUCCESS); -} diff -urN src/contrib/ntp/libisc/sockaddr.c src.ntp/contrib/ntp/libisc/sockaddr.c --- src/contrib/ntp/libisc/sockaddr.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libisc/sockaddr.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,480 +0,0 @@ -/* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") - * Copyright (C) 1999-2003 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH - * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY - * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM - * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE - * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: sockaddr.c,v 1.48.2.1.2.10 2004/05/15 03:46:12 jinmei Exp $ */ - -#include - -#define ISC_ONLY_IPV6 - -#include - -#include -/* - * We currently don't need hashing here - */ -#if 0 -#include -#endif - -#include -#include -#include -#include -#include -#include -#include - -isc_boolean_t -isc_sockaddr_equal(const isc_sockaddr_t *a, const isc_sockaddr_t *b) { - REQUIRE(a != NULL && b != NULL); - - if (a->length != b->length) - return (ISC_FALSE); - - /* - * We don't just memcmp because the sin_zero field isn't always - * zero. - */ - - if (a->type.sa.sa_family != b->type.sa.sa_family) - return (ISC_FALSE); - switch (a->type.sa.sa_family) { - case AF_INET: - if (memcmp(&a->type.sin.sin_addr, &b->type.sin.sin_addr, - sizeof(a->type.sin.sin_addr)) != 0) - return (ISC_FALSE); - if (a->type.sin.sin_port != b->type.sin.sin_port) - return (ISC_FALSE); - break; - case AF_INET6: - if (memcmp(&a->type.sin6.sin6_addr, &b->type.sin6.sin6_addr, - sizeof(a->type.sin6.sin6_addr)) != 0) - return (ISC_FALSE); -#ifdef ISC_PLATFORM_HAVESCOPEID - if (a->type.sin6.sin6_scope_id != b->type.sin6.sin6_scope_id) - return (ISC_FALSE); -#endif - if (a->type.sin6.sin6_port != b->type.sin6.sin6_port) - return (ISC_FALSE); - break; - default: - if (memcmp(&a->type, &b->type, a->length) != 0) - return (ISC_FALSE); - } - return (ISC_TRUE); -} - -isc_boolean_t -isc_sockaddr_eqaddr(const isc_sockaddr_t *a, const isc_sockaddr_t *b) { - REQUIRE(a != NULL && b != NULL); - - if (a->length != b->length) - return (ISC_FALSE); - - if (a->type.sa.sa_family != b->type.sa.sa_family) - return (ISC_FALSE); - switch (a->type.sa.sa_family) { - case AF_INET: - if (memcmp(&a->type.sin.sin_addr, &b->type.sin.sin_addr, - sizeof(a->type.sin.sin_addr)) != 0) - return (ISC_FALSE); - break; - case AF_INET6: - if (memcmp(&a->type.sin6.sin6_addr, &b->type.sin6.sin6_addr, - sizeof(a->type.sin6.sin6_addr)) != 0) - return (ISC_FALSE); -#ifdef ISC_PLATFORM_HAVESCOPEID - if (a->type.sin6.sin6_scope_id != b->type.sin6.sin6_scope_id) - return (ISC_FALSE); -#endif - break; - default: - if (memcmp(&a->type, &b->type, a->length) != 0) - return (ISC_FALSE); - } - return (ISC_TRUE); -} - -isc_boolean_t -isc_sockaddr_eqaddrprefix(const isc_sockaddr_t *a, const isc_sockaddr_t *b, - unsigned int prefixlen) -{ - isc_netaddr_t na, nb; - isc_netaddr_fromsockaddr(&na, a); - isc_netaddr_fromsockaddr(&nb, b); - return (isc_netaddr_eqprefix(&na, &nb, prefixlen)); -} - -isc_result_t -isc_sockaddr_totext(const isc_sockaddr_t *sockaddr, isc_buffer_t *target) { - isc_result_t result; - isc_netaddr_t netaddr; - char pbuf[sizeof("65000")]; - unsigned int plen; - isc_region_t avail; - - REQUIRE(sockaddr != NULL); - - /* - * Do the port first, giving us the opportunity to check for - * unsupported address families before calling - * isc_netaddr_fromsockaddr(). - */ - switch (sockaddr->type.sa.sa_family) { - case AF_INET: - snprintf(pbuf, sizeof(pbuf), "%u", ntohs(sockaddr->type.sin.sin_port)); - break; - case AF_INET6: - snprintf(pbuf, sizeof(pbuf), "%u", ntohs(sockaddr->type.sin6.sin6_port)); - break; - default: - return (ISC_R_FAILURE); - } - - plen = strlen(pbuf); - INSIST(plen < sizeof(pbuf)); - - isc_netaddr_fromsockaddr(&netaddr, sockaddr); - result = isc_netaddr_totext(&netaddr, target); - if (result != ISC_R_SUCCESS) - return (result); - - if (1 + plen + 1 > isc_buffer_availablelength(target)) - return (ISC_R_NOSPACE); - - isc_buffer_putmem(target, (const unsigned char *)"#", 1); - isc_buffer_putmem(target, (const unsigned char *)pbuf, plen); - - /* - * Null terminate after used region. - */ - isc_buffer_availableregion(target, &avail); - INSIST(avail.length >= 1); - avail.base[0] = '\0'; - - return (ISC_R_SUCCESS); -} - -void -isc_sockaddr_format(const isc_sockaddr_t *sa, char *array, unsigned int size) { - isc_result_t result; - isc_buffer_t buf; - - isc_buffer_init(&buf, array, size); - result = isc_sockaddr_totext(sa, &buf); - if (result != ISC_R_SUCCESS) { - /* - * The message is the same as in netaddr.c. - */ - snprintf(array, size, - isc_msgcat_get(isc_msgcat, ISC_MSGSET_NETADDR, - ISC_MSG_UNKNOWNADDR, - ""), - sa->type.sa.sa_family); - array[size - 1] = '\0'; - } -} - -#if 0 -/* - * We currently don't need hashing here - */ -unsigned int -isc_sockaddr_hash(const isc_sockaddr_t *sockaddr, isc_boolean_t address_only) { - unsigned int length = 0; - const unsigned char *s = NULL; - unsigned int h = 0; - unsigned int g; - unsigned int p = 0; - const struct in6_addr *in6; - - REQUIRE(sockaddr != NULL); - - switch (sockaddr->type.sa.sa_family) { - case AF_INET: - s = (const unsigned char *)&sockaddr->type.sin.sin_addr; - p = ntohs(sockaddr->type.sin.sin_port); - length = sizeof(sockaddr->type.sin.sin_addr.s_addr); - break; -#if ISC_PLATFORM_HAVEIPV6 - case AF_INET6: - in6 = &sockaddr->type.sin6.sin6_addr; - if (IN6_IS_ADDR_V4MAPPED(in6)) { - s = (const unsigned char *)&in6[12]; - length = sizeof(sockaddr->type.sin.sin_addr.s_addr); - } else { - s = (const unsigned char *)in6; - length = sizeof(sockaddr->type.sin6.sin6_addr); - } - p = ntohs(sockaddr->type.sin6.sin6_port); - break; -#endif - default: - UNEXPECTED_ERROR(__FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, - ISC_MSGSET_SOCKADDR, - ISC_MSG_UNKNOWNFAMILY, - "unknown address family: %d"), - (int)sockaddr->type.sa.sa_family); - s = (const unsigned char *)&sockaddr->type; - length = sockaddr->length; - p = 0; - } - - h = isc_hash_calc(s, length, ISC_TRUE); - if (!address_only) { - g = isc_hash_calc((const unsigned char *)&p, sizeof(p), - ISC_TRUE); - h = h ^ g; /* XXX: we should concatenate h and p first */ - } - - return (h); -} -#endif - -void -isc_sockaddr_any(isc_sockaddr_t *sockaddr) -{ - memset(sockaddr, 0, sizeof(*sockaddr)); - sockaddr->type.sin.sin_family = AF_INET; -#ifdef ISC_PLATFORM_HAVESALEN - sockaddr->type.sin.sin_len = sizeof(sockaddr->type.sin); -#endif - sockaddr->type.sin.sin_addr.s_addr = INADDR_ANY; - sockaddr->type.sin.sin_port = 0; - sockaddr->length = sizeof(sockaddr->type.sin); - ISC_LINK_INIT(sockaddr, link); -} - -void -isc_sockaddr_any6(isc_sockaddr_t *sockaddr) -{ -#ifdef ISC_PLATFORM_HAVEIPV6 - memset(sockaddr, 0, sizeof(*sockaddr)); - sockaddr->type.sin6.sin6_family = AF_INET6; -#ifdef ISC_PLATFORM_HAVESALEN - sockaddr->type.sin6.sin6_len = sizeof(sockaddr->type.sin6); -#endif - sockaddr->type.sin6.sin6_addr = in6addr_any; - sockaddr->type.sin6.sin6_port = 0; - sockaddr->length = sizeof(sockaddr->type.sin6); - ISC_LINK_INIT(sockaddr, link); -#endif -} - -void -isc_sockaddr_fromin(isc_sockaddr_t *sockaddr, const struct in_addr *ina, - in_port_t port) -{ - memset(sockaddr, 0, sizeof(*sockaddr)); - sockaddr->type.sin.sin_family = AF_INET; -#ifdef ISC_PLATFORM_HAVESALEN - sockaddr->type.sin.sin_len = sizeof(sockaddr->type.sin); -#endif - sockaddr->type.sin.sin_addr = *ina; - sockaddr->type.sin.sin_port = htons(port); - sockaddr->length = sizeof(sockaddr->type.sin); - ISC_LINK_INIT(sockaddr, link); -} - -void -isc_sockaddr_anyofpf(isc_sockaddr_t *sockaddr, int pf) { - switch (pf) { - case AF_INET: - isc_sockaddr_any(sockaddr); - break; - case AF_INET6: - isc_sockaddr_any6(sockaddr); - break; - default: - INSIST(0); - } -} - -void -isc_sockaddr_fromin6(isc_sockaddr_t *sockaddr, const struct in6_addr *ina6, - in_port_t port) -{ - memset(sockaddr, 0, sizeof(*sockaddr)); - sockaddr->type.sin6.sin6_family = AF_INET6; -#ifdef ISC_PLATFORM_HAVESALEN - sockaddr->type.sin6.sin6_len = sizeof(sockaddr->type.sin6); -#endif - sockaddr->type.sin6.sin6_addr = *ina6; - sockaddr->type.sin6.sin6_port = htons(port); - sockaddr->length = sizeof(sockaddr->type.sin6); - ISC_LINK_INIT(sockaddr, link); -} - -void -isc_sockaddr_v6fromin(isc_sockaddr_t *sockaddr, const struct in_addr *ina, - in_port_t port) -{ - memset(sockaddr, 0, sizeof(*sockaddr)); - sockaddr->type.sin6.sin6_family = AF_INET6; -#ifdef ISC_PLATFORM_HAVESALEN - sockaddr->type.sin6.sin6_len = sizeof(sockaddr->type.sin6); -#endif - sockaddr->type.sin6.sin6_addr.s6_addr[10] = 0xff; - sockaddr->type.sin6.sin6_addr.s6_addr[11] = 0xff; - memcpy(&sockaddr->type.sin6.sin6_addr.s6_addr[12], ina, 4); - sockaddr->type.sin6.sin6_port = htons(port); - sockaddr->length = sizeof(sockaddr->type.sin6); - ISC_LINK_INIT(sockaddr, link); -} - -int -isc_sockaddr_pf(const isc_sockaddr_t *sockaddr) { - - /* - * Get the protocol family of 'sockaddr'. - */ - -#if (AF_INET == PF_INET && AF_INET6 == PF_INET6) - /* - * Assume that PF_xxx == AF_xxx for all AF and PF. - */ - return (sockaddr->type.sa.sa_family); -#else - switch (sockaddr->type.sa.sa_family) { - case AF_INET: - return (PF_INET); - case AF_INET6: - return (PF_INET6); - default: - FATAL_ERROR(__FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKADDR, - ISC_MSG_UNKNOWNFAMILY, - "unknown address family: %d"), - (int)sockaddr->type.sa.sa_family); - } -#endif -} - -void -isc_sockaddr_fromnetaddr(isc_sockaddr_t *sockaddr, const isc_netaddr_t *na, - in_port_t port) -{ - memset(sockaddr, 0, sizeof(*sockaddr)); - sockaddr->type.sin.sin_family = na->family; - switch (na->family) { - case AF_INET: - sockaddr->length = sizeof(sockaddr->type.sin); -#ifdef ISC_PLATFORM_HAVESALEN - sockaddr->type.sin.sin_len = sizeof(sockaddr->type.sin); -#endif - sockaddr->type.sin.sin_addr = na->type.in; - sockaddr->type.sin.sin_port = htons(port); - break; - case AF_INET6: - sockaddr->length = sizeof(sockaddr->type.sin6); -#ifdef ISC_PLATFORM_HAVESALEN - sockaddr->type.sin6.sin6_len = sizeof(sockaddr->type.sin6); -#endif - memcpy(&sockaddr->type.sin6.sin6_addr, &na->type.in6, 16); -#ifdef ISC_PLATFORM_HAVESCOPEID - sockaddr->type.sin6.sin6_scope_id = isc_netaddr_getzone(na); -#endif - sockaddr->type.sin6.sin6_port = htons(port); - break; - default: - INSIST(0); - } - ISC_LINK_INIT(sockaddr, link); -} - -void -isc_sockaddr_setport(isc_sockaddr_t *sockaddr, in_port_t port) { - switch (sockaddr->type.sa.sa_family) { - case AF_INET: - sockaddr->type.sin.sin_port = htons(port); - break; - case AF_INET6: - sockaddr->type.sin6.sin6_port = htons(port); - break; - default: - FATAL_ERROR(__FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKADDR, - ISC_MSG_UNKNOWNFAMILY, - "unknown address family: %d"), - (int)sockaddr->type.sa.sa_family); - } -} - -in_port_t -isc_sockaddr_getport(isc_sockaddr_t *sockaddr) { - in_port_t port = 0; - - switch (sockaddr->type.sa.sa_family) { - case AF_INET: - port = ntohs(sockaddr->type.sin.sin_port); - break; - case AF_INET6: - port = ntohs(sockaddr->type.sin6.sin6_port); - break; - default: - FATAL_ERROR(__FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKADDR, - ISC_MSG_UNKNOWNFAMILY, - "unknown address family: %d"), - (int)sockaddr->type.sa.sa_family); - } - - return (port); -} - -isc_boolean_t -isc_sockaddr_ismulticast(isc_sockaddr_t *sockaddr) { - isc_netaddr_t netaddr; - - isc_netaddr_fromsockaddr(&netaddr, sockaddr); - return (isc_netaddr_ismulticast(&netaddr)); -} - -isc_boolean_t -isc_sockaddr_isexperimental(isc_sockaddr_t *sockaddr) { - isc_netaddr_t netaddr; - - if (sockaddr->type.sa.sa_family == AF_INET) { - isc_netaddr_fromsockaddr(&netaddr, sockaddr); - return (isc_netaddr_isexperimental(&netaddr)); - } - return (ISC_FALSE); -} - -isc_boolean_t -isc_sockaddr_issitelocal(isc_sockaddr_t *sockaddr) { - isc_netaddr_t netaddr; - - if (sockaddr->type.sa.sa_family == AF_INET6) { - isc_netaddr_fromsockaddr(&netaddr, sockaddr); - return (isc_netaddr_issitelocal(&netaddr)); - } - return (ISC_FALSE); -} - -isc_boolean_t -isc_sockaddr_islinklocal(isc_sockaddr_t *sockaddr) { - isc_netaddr_t netaddr; - - if (sockaddr->type.sa.sa_family == AF_INET6) { - isc_netaddr_fromsockaddr(&netaddr, sockaddr); - return (isc_netaddr_islinklocal(&netaddr)); - } - return (ISC_FALSE); -} diff -urN src/contrib/ntp/libisc/strerror.c src.ntp/contrib/ntp/libisc/strerror.c --- src/contrib/ntp/libisc/strerror.c 2004-07-20 17:01:18.000000000 +0200 +++ src.ntp/contrib/ntp/libisc/strerror.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,72 +0,0 @@ -/* - * Copyright (C) 2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: strerror.c,v 1.3 2001/11/20 01:45:45 gson Exp $ */ - -#include - -#include -#include - -#include -#include -#include -#include -#include - -#ifdef HAVE_STRERROR -/* - * We need to do this this way for profiled locks. - */ -static isc_mutex_t isc_strerror_lock; -static void init_lock(void) { - RUNTIME_CHECK(isc_mutex_init(&isc_strerror_lock) == ISC_R_SUCCESS); -} -#else -extern const char * const sys_errlist[]; -extern const int sys_nerr; -#endif - -void -isc__strerror(int num, char *buf, size_t size) { -#ifdef HAVE_STRERROR - char *msg; - unsigned int unum = num; - static isc_once_t once = ISC_ONCE_INIT; - - REQUIRE(buf != NULL); - - RUNTIME_CHECK(isc_once_do(&once, init_lock) == ISC_R_SUCCESS); - - LOCK(&isc_strerror_lock); - msg = strerror(num); - if (msg != NULL) - snprintf(buf, size, "%s", msg); - else - snprintf(buf, size, "Unknown error: %u", unum); - UNLOCK(&isc_strerror_lock); -#else - unsigned int unum = num; - - REQUIRE(buf != NULL); - - if (num >= 0 && num < sys_nerr) - snprintf(buf, size, "%s", sys_errlist[num]); - else - snprintf(buf, size, "Unknown error: %u", unum); -#endif -} diff -urN src/contrib/ntp/libntp/Makefile.am src.ntp/contrib/ntp/libntp/Makefile.am --- src/contrib/ntp/libntp/Makefile.am 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/Makefile.am 2009-12-09 08:36:35.000000000 +0100 @@ -1,38 +1,112 @@ +NULL= #AUTOMAKE_OPTIONS = ../ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr +AUTOMAKE_OPTIONS = +BUILT_SOURCES = +CLEANFILES = noinst_LIBRARIES = libntp.a @MAKE_LIBNTPSIM@ EXTRA_LIBRARIES = libntpsim.a -libntp_a_SRCS = a_md5encrypt.c adjtime.c atoint.c atolfp.c atouint.c \ - audio.c authkeys.c authreadkeys.c authusekey.c buftvtots.c \ - caljulian.c caltontp.c calyearstart.c clocktime.c \ - clocktypes.c decodenetnum.c dofptoa.c dolfptoa.c emalloc.c \ - findconfig.c fptoa.c fptoms.c getopt.c hextoint.c \ - hextolfp.c humandate.c icom.c inttoa.c iosignal.c \ - lib_strbuf.c machines.c md5c.c memmove.c mfptoa.c \ - mfptoms.c mktime.c modetoa.c mstolfp.c msutotsf.c msyslog.c netof.c \ - ntp_rfc2553.c numtoa.c numtohost.c octtoint.c prettydate.c \ - ntp_random.c recvbuff.c refnumtoa.c snprintf.c socktoa.c socktohost.c \ - statestr.c strdup.c strerror.c strstr.c \ - syssignal.c tsftomsu.c tstotv.c tvtoa.c tvtots.c \ - uglydate.c uinttoa.c utvtoa.c ymd2yd.c \ - $(srcdir)/../libisc/assertions.c $(srcdir)/../libisc/error.c \ - $(srcdir)/../libisc/interfaceiter.c $(srcdir)/../libisc/lib.c \ - $(srcdir)/../libisc/mem.c $(srcdir)/../libisc/msgcat.c \ - $(srcdir)/../libisc/net.c $(srcdir)/../libisc/isc_strerror.c \ - $(srcdir)/../libisc/inet_ntop.c \ - $(srcdir)/../libisc/inet_pton.c \ - $(srcdir)/../libisc/netaddr.c $(srcdir)/../libisc/sockaddr.c \ - $(srcdir)/../libisc/netscope.c +libntp_a_SRCS = \ + a_md5encrypt.c \ + adjtime.c \ + atoint.c \ + atolfp.c \ + atouint.c \ + audio.c \ + authkeys.c \ + authreadkeys.c \ + authusekey.c \ + bsd_strerror.c \ + buftvtots.c \ + caljulian.c \ + caltontp.c \ + calyearstart.c \ + clocktime.c \ + clocktypes.c \ + decodenetnum.c \ + dofptoa.c \ + dolfptoa.c \ + emalloc.c \ + findconfig.c \ + fptoa.c \ + fptoms.c \ + getopt.c \ + hextoint.c \ + hextolfp.c \ + humandate.c \ + icom.c \ + inttoa.c \ + iosignal.c \ + lib_strbuf.c \ + machines.c \ + memmove.c \ + mfptoa.c \ + ntp_lineedit.c \ + mfptoms.c \ + mktime.c \ + modetoa.c \ + mstolfp.c \ + msutotsf.c \ + msyslog.c \ + netof.c \ + ntp_rfc2553.c \ + numtoa.c \ + numtohost.c \ + octtoint.c \ + prettydate.c \ + ntp_random.c \ + recvbuff.c \ + refnumtoa.c \ + snprintf.c \ + socktoa.c \ + socktohost.c \ + ssl_init.c \ + statestr.c \ + strdup.c \ + strstr.c \ + syssignal.c \ + tsftomsu.c \ + tstotv.c \ + tvtots.c \ + uglydate.c \ + uinttoa.c \ + ymd2yd.c \ + $(srcdir)/../lib/isc/assertions.c \ + $(srcdir)/../lib/isc/buffer.c \ + $(srcdir)/../lib/isc/nothreads/condition.c \ + $(srcdir)/../lib/isc/unix/dir.c \ + $(srcdir)/../lib/isc/error.c \ + $(srcdir)/../lib/isc/unix/errno2result.c \ + $(srcdir)/../lib/isc/event.c \ + $(srcdir)/../lib/isc/unix/file.c \ + $(srcdir)/../lib/isc/inet_ntop.c \ + $(srcdir)/../lib/isc/inet_pton.c \ + $(srcdir)/../lib/isc/unix/interfaceiter.c \ + $(srcdir)/../lib/isc/lib.c \ + $(srcdir)/../lib/isc/log.c \ + $(srcdir)/../lib/isc/md5.c \ + $(srcdir)/../lib/isc/nls/msgcat.c \ + $(srcdir)/../lib/isc/unix/net.c \ + $(srcdir)/../lib/isc/netaddr.c \ + $(srcdir)/../lib/isc/netscope.c \ + $(srcdir)/../lib/isc/ondestroy.c \ + $(srcdir)/../lib/isc/random.c \ + $(srcdir)/../lib/isc/result.c \ + $(srcdir)/../lib/isc/unix/stdio.c \ + $(srcdir)/../lib/isc/unix/stdtime.c \ + $(srcdir)/../lib/isc/unix/strerror.c \ + $(srcdir)/../lib/isc/task.c \ + $(srcdir)/../lib/isc/nothreads/thread.c \ + $(srcdir)/../lib/isc/unix/time.c \ + $(srcdir)/../lib/isc/sockaddr.c \ + $(NULL) libntp_a_SOURCES = systime.c $(libntp_a_SRCS) libntpsim_a_SOURCES = systime_s.c $(libntp_a_SRCS) EXTRA_libntp_a_SOURCES = adjtimex.c -INCLUDES = -I$(top_srcdir)/include -I../include +INCLUDES = -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/nothreads/include \ + -I$(top_srcdir)/lib/isc/unix/include ETAGS_ARGS = Makefile.am -noinst_HEADERS = lib_strbuf.h - -../include/des.h: - touch ../include/des.h - EXTRA_DIST = README +include $(top_srcdir)/depsver.mf diff -urN src/contrib/ntp/libntp/Makefile.in src.ntp/contrib/ntp/libntp/Makefile.in --- src/contrib/ntp/libntp/Makefile.in 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/libntp/Makefile.in 2010-07-09 04:21:32.000000000 +0200 @@ -15,7 +15,6 @@ @SET_MAKE@ - VPATH = @srcdir@ pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ @@ -35,14 +34,17 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -ANSI2KNR = ../util/ansi2knr +DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ + $(top_srcdir)/depsver.mf subdir = libntp -DIST_COMMON = README $(noinst_HEADERS) $(srcdir)/Makefile.am \ - $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ + $(top_srcdir)/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/m4/ntp_openssl.m4 \ + $(top_srcdir)/m4/ntp_vpathhack.m4 \ $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ @@ -55,42 +57,44 @@ ARFLAGS = cru libntp_a_AR = $(AR) $(ARFLAGS) libntp_a_LIBADD = -am__objects_1 = a_md5encrypt$U.$(OBJEXT) adjtime$U.$(OBJEXT) \ - atoint$U.$(OBJEXT) atolfp$U.$(OBJEXT) atouint$U.$(OBJEXT) \ - audio$U.$(OBJEXT) authkeys$U.$(OBJEXT) \ - authreadkeys$U.$(OBJEXT) authusekey$U.$(OBJEXT) \ - buftvtots$U.$(OBJEXT) caljulian$U.$(OBJEXT) \ - caltontp$U.$(OBJEXT) calyearstart$U.$(OBJEXT) \ - clocktime$U.$(OBJEXT) clocktypes$U.$(OBJEXT) \ - decodenetnum$U.$(OBJEXT) dofptoa$U.$(OBJEXT) \ - dolfptoa$U.$(OBJEXT) emalloc$U.$(OBJEXT) \ - findconfig$U.$(OBJEXT) fptoa$U.$(OBJEXT) fptoms$U.$(OBJEXT) \ - getopt$U.$(OBJEXT) hextoint$U.$(OBJEXT) hextolfp$U.$(OBJEXT) \ - humandate$U.$(OBJEXT) icom$U.$(OBJEXT) inttoa$U.$(OBJEXT) \ - iosignal$U.$(OBJEXT) lib_strbuf$U.$(OBJEXT) \ - machines$U.$(OBJEXT) md5c$U.$(OBJEXT) memmove$U.$(OBJEXT) \ - mfptoa$U.$(OBJEXT) mfptoms$U.$(OBJEXT) mktime$U.$(OBJEXT) \ - modetoa$U.$(OBJEXT) mstolfp$U.$(OBJEXT) msutotsf$U.$(OBJEXT) \ - msyslog$U.$(OBJEXT) netof$U.$(OBJEXT) ntp_rfc2553$U.$(OBJEXT) \ - numtoa$U.$(OBJEXT) numtohost$U.$(OBJEXT) octtoint$U.$(OBJEXT) \ - prettydate$U.$(OBJEXT) ntp_random$U.$(OBJEXT) \ - recvbuff$U.$(OBJEXT) refnumtoa$U.$(OBJEXT) \ - snprintf$U.$(OBJEXT) socktoa$U.$(OBJEXT) \ - socktohost$U.$(OBJEXT) statestr$U.$(OBJEXT) strdup$U.$(OBJEXT) \ - strerror$U.$(OBJEXT) strstr$U.$(OBJEXT) syssignal$U.$(OBJEXT) \ - tsftomsu$U.$(OBJEXT) tstotv$U.$(OBJEXT) tvtoa$U.$(OBJEXT) \ - tvtots$U.$(OBJEXT) uglydate$U.$(OBJEXT) uinttoa$U.$(OBJEXT) \ - utvtoa$U.$(OBJEXT) ymd2yd$U.$(OBJEXT) assertions$U.$(OBJEXT) \ - error$U.$(OBJEXT) interfaceiter$U.$(OBJEXT) lib$U.$(OBJEXT) \ - mem$U.$(OBJEXT) msgcat$U.$(OBJEXT) net$U.$(OBJEXT) \ - isc_strerror$U.$(OBJEXT) inet_ntop$U.$(OBJEXT) \ - inet_pton$U.$(OBJEXT) netaddr$U.$(OBJEXT) sockaddr$U.$(OBJEXT) \ - netscope$U.$(OBJEXT) -am_libntp_a_OBJECTS = systime$U.$(OBJEXT) $(am__objects_1) +am__objects_1 = +am__objects_2 = a_md5encrypt.$(OBJEXT) adjtime.$(OBJEXT) \ + atoint.$(OBJEXT) atolfp.$(OBJEXT) atouint.$(OBJEXT) \ + audio.$(OBJEXT) authkeys.$(OBJEXT) authreadkeys.$(OBJEXT) \ + authusekey.$(OBJEXT) bsd_strerror.$(OBJEXT) \ + buftvtots.$(OBJEXT) caljulian.$(OBJEXT) caltontp.$(OBJEXT) \ + calyearstart.$(OBJEXT) clocktime.$(OBJEXT) \ + clocktypes.$(OBJEXT) decodenetnum.$(OBJEXT) dofptoa.$(OBJEXT) \ + dolfptoa.$(OBJEXT) emalloc.$(OBJEXT) findconfig.$(OBJEXT) \ + fptoa.$(OBJEXT) fptoms.$(OBJEXT) getopt.$(OBJEXT) \ + hextoint.$(OBJEXT) hextolfp.$(OBJEXT) humandate.$(OBJEXT) \ + icom.$(OBJEXT) inttoa.$(OBJEXT) iosignal.$(OBJEXT) \ + lib_strbuf.$(OBJEXT) machines.$(OBJEXT) memmove.$(OBJEXT) \ + mfptoa.$(OBJEXT) ntp_lineedit.$(OBJEXT) mfptoms.$(OBJEXT) \ + mktime.$(OBJEXT) modetoa.$(OBJEXT) mstolfp.$(OBJEXT) \ + msutotsf.$(OBJEXT) msyslog.$(OBJEXT) netof.$(OBJEXT) \ + ntp_rfc2553.$(OBJEXT) numtoa.$(OBJEXT) numtohost.$(OBJEXT) \ + octtoint.$(OBJEXT) prettydate.$(OBJEXT) ntp_random.$(OBJEXT) \ + recvbuff.$(OBJEXT) refnumtoa.$(OBJEXT) snprintf.$(OBJEXT) \ + socktoa.$(OBJEXT) socktohost.$(OBJEXT) ssl_init.$(OBJEXT) \ + statestr.$(OBJEXT) strdup.$(OBJEXT) strstr.$(OBJEXT) \ + syssignal.$(OBJEXT) tsftomsu.$(OBJEXT) tstotv.$(OBJEXT) \ + tvtots.$(OBJEXT) uglydate.$(OBJEXT) uinttoa.$(OBJEXT) \ + ymd2yd.$(OBJEXT) assertions.$(OBJEXT) buffer.$(OBJEXT) \ + condition.$(OBJEXT) dir.$(OBJEXT) error.$(OBJEXT) \ + errno2result.$(OBJEXT) event.$(OBJEXT) file.$(OBJEXT) \ + inet_ntop.$(OBJEXT) inet_pton.$(OBJEXT) \ + interfaceiter.$(OBJEXT) lib.$(OBJEXT) log.$(OBJEXT) \ + md5.$(OBJEXT) msgcat.$(OBJEXT) net.$(OBJEXT) netaddr.$(OBJEXT) \ + netscope.$(OBJEXT) ondestroy.$(OBJEXT) random.$(OBJEXT) \ + result.$(OBJEXT) stdio.$(OBJEXT) stdtime.$(OBJEXT) \ + strerror.$(OBJEXT) task.$(OBJEXT) thread.$(OBJEXT) \ + time.$(OBJEXT) sockaddr.$(OBJEXT) $(am__objects_1) +am_libntp_a_OBJECTS = systime.$(OBJEXT) $(am__objects_2) libntp_a_OBJECTS = $(am_libntp_a_OBJECTS) libntpsim_a_AR = $(AR) $(ARFLAGS) libntpsim_a_LIBADD = -am_libntpsim_a_OBJECTS = systime_s$U.$(OBJEXT) $(am__objects_1) +am_libntpsim_a_OBJECTS = systime_s.$(OBJEXT) $(am__objects_2) libntpsim_a_OBJECTS = $(am_libntpsim_a_OBJECTS) DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) depcomp = $(SHELL) $(top_srcdir)/depcomp @@ -109,14 +113,12 @@ $(libntpsim_a_SOURCES) DIST_SOURCES = $(libntp_a_SOURCES) $(EXTRA_libntp_a_SOURCES) \ $(libntpsim_a_SOURCES) -HEADERS = $(noinst_HEADERS) ETAGS = etags CTAGS = ctags DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -137,6 +139,7 @@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EF_LIBS = @EF_LIBS@ EF_PROGS = @EF_PROGS@ EGREP = @EGREP@ @@ -168,6 +171,7 @@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ @@ -184,18 +188,22 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ PATH_SEPARATOR = @PATH_SEPARATOR@ PATH_SH = @PATH_SH@ PROPDELAY = @PROPDELAY@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ VERSION = @VERSION@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ @@ -247,45 +255,123 @@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ - +NULL = #AUTOMAKE_OPTIONS = ../ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr +AUTOMAKE_OPTIONS = +BUILT_SOURCES = .deps-ver +CLEANFILES = .deps-ver noinst_LIBRARIES = libntp.a @MAKE_LIBNTPSIM@ EXTRA_LIBRARIES = libntpsim.a -libntp_a_SRCS = a_md5encrypt.c adjtime.c atoint.c atolfp.c atouint.c \ - audio.c authkeys.c authreadkeys.c authusekey.c buftvtots.c \ - caljulian.c caltontp.c calyearstart.c clocktime.c \ - clocktypes.c decodenetnum.c dofptoa.c dolfptoa.c emalloc.c \ - findconfig.c fptoa.c fptoms.c getopt.c hextoint.c \ - hextolfp.c humandate.c icom.c inttoa.c iosignal.c \ - lib_strbuf.c machines.c md5c.c memmove.c mfptoa.c \ - mfptoms.c mktime.c modetoa.c mstolfp.c msutotsf.c msyslog.c netof.c \ - ntp_rfc2553.c numtoa.c numtohost.c octtoint.c prettydate.c \ - ntp_random.c recvbuff.c refnumtoa.c snprintf.c socktoa.c socktohost.c \ - statestr.c strdup.c strerror.c strstr.c \ - syssignal.c tsftomsu.c tstotv.c tvtoa.c tvtots.c \ - uglydate.c uinttoa.c utvtoa.c ymd2yd.c \ - $(srcdir)/../libisc/assertions.c $(srcdir)/../libisc/error.c \ - $(srcdir)/../libisc/interfaceiter.c $(srcdir)/../libisc/lib.c \ - $(srcdir)/../libisc/mem.c $(srcdir)/../libisc/msgcat.c \ - $(srcdir)/../libisc/net.c $(srcdir)/../libisc/isc_strerror.c \ - $(srcdir)/../libisc/inet_ntop.c \ - $(srcdir)/../libisc/inet_pton.c \ - $(srcdir)/../libisc/netaddr.c $(srcdir)/../libisc/sockaddr.c \ - $(srcdir)/../libisc/netscope.c +libntp_a_SRCS = \ + a_md5encrypt.c \ + adjtime.c \ + atoint.c \ + atolfp.c \ + atouint.c \ + audio.c \ + authkeys.c \ + authreadkeys.c \ + authusekey.c \ + bsd_strerror.c \ + buftvtots.c \ + caljulian.c \ + caltontp.c \ + calyearstart.c \ + clocktime.c \ + clocktypes.c \ + decodenetnum.c \ + dofptoa.c \ + dolfptoa.c \ + emalloc.c \ + findconfig.c \ + fptoa.c \ + fptoms.c \ + getopt.c \ + hextoint.c \ + hextolfp.c \ + humandate.c \ + icom.c \ + inttoa.c \ + iosignal.c \ + lib_strbuf.c \ + machines.c \ + memmove.c \ + mfptoa.c \ + ntp_lineedit.c \ + mfptoms.c \ + mktime.c \ + modetoa.c \ + mstolfp.c \ + msutotsf.c \ + msyslog.c \ + netof.c \ + ntp_rfc2553.c \ + numtoa.c \ + numtohost.c \ + octtoint.c \ + prettydate.c \ + ntp_random.c \ + recvbuff.c \ + refnumtoa.c \ + snprintf.c \ + socktoa.c \ + socktohost.c \ + ssl_init.c \ + statestr.c \ + strdup.c \ + strstr.c \ + syssignal.c \ + tsftomsu.c \ + tstotv.c \ + tvtots.c \ + uglydate.c \ + uinttoa.c \ + ymd2yd.c \ + $(srcdir)/../lib/isc/assertions.c \ + $(srcdir)/../lib/isc/buffer.c \ + $(srcdir)/../lib/isc/nothreads/condition.c \ + $(srcdir)/../lib/isc/unix/dir.c \ + $(srcdir)/../lib/isc/error.c \ + $(srcdir)/../lib/isc/unix/errno2result.c \ + $(srcdir)/../lib/isc/event.c \ + $(srcdir)/../lib/isc/unix/file.c \ + $(srcdir)/../lib/isc/inet_ntop.c \ + $(srcdir)/../lib/isc/inet_pton.c \ + $(srcdir)/../lib/isc/unix/interfaceiter.c \ + $(srcdir)/../lib/isc/lib.c \ + $(srcdir)/../lib/isc/log.c \ + $(srcdir)/../lib/isc/md5.c \ + $(srcdir)/../lib/isc/nls/msgcat.c \ + $(srcdir)/../lib/isc/unix/net.c \ + $(srcdir)/../lib/isc/netaddr.c \ + $(srcdir)/../lib/isc/netscope.c \ + $(srcdir)/../lib/isc/ondestroy.c \ + $(srcdir)/../lib/isc/random.c \ + $(srcdir)/../lib/isc/result.c \ + $(srcdir)/../lib/isc/unix/stdio.c \ + $(srcdir)/../lib/isc/unix/stdtime.c \ + $(srcdir)/../lib/isc/unix/strerror.c \ + $(srcdir)/../lib/isc/task.c \ + $(srcdir)/../lib/isc/nothreads/thread.c \ + $(srcdir)/../lib/isc/unix/time.c \ + $(srcdir)/../lib/isc/sockaddr.c \ + $(NULL) libntp_a_SOURCES = systime.c $(libntp_a_SRCS) libntpsim_a_SOURCES = systime_s.c $(libntp_a_SRCS) EXTRA_libntp_a_SOURCES = adjtimex.c -INCLUDES = -I$(top_srcdir)/include -I../include +INCLUDES = -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/nothreads/include \ + -I$(top_srcdir)/lib/isc/unix/include + ETAGS_ARGS = Makefile.am -noinst_HEADERS = lib_strbuf.h EXTRA_DIST = README -all: all-am +all: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/depsver.mf $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -332,93 +418,102 @@ distclean-compile: -rm -f *.tab.c -../util/ansi2knr: - $(am__cd) ../util && $(MAKE) $(AM_MAKEFLAGS) ./ansi2knr - -mostlyclean-kr: - -test "$U" = "" || rm -f *_.c -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/a_md5encrypt$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/adjtime$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/adjtimex$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/assertions$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/atoint$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/atolfp$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/atouint$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/audio$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/authkeys$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/authreadkeys$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/authusekey$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/buftvtots$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/caljulian$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/caltontp$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/calyearstart$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clocktime$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clocktypes$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/decodenetnum$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dofptoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dolfptoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/emalloc$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/error$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/findconfig$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fptoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fptoms$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/getopt$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/hextoint$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/hextolfp$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/humandate$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/icom$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/inet_ntop$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/inet_pton$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/interfaceiter$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/inttoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/iosignal$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/isc_strerror$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/lib$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/lib_strbuf$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/machines$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/md5c$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mem$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/memmove$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mfptoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mfptoms$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mktime$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/modetoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/msgcat$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mstolfp$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/msutotsf$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/msyslog$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/net$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/netaddr$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/netof$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/netscope$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_random$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_rfc2553$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/numtoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/numtohost$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/octtoint$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/prettydate$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/recvbuff$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refnumtoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/snprintf$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sockaddr$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/socktoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/socktohost$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/statestr$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/strdup$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/strerror$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/strstr$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/syssignal$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/systime$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/systime_s$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tsftomsu$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tstotv$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tvtoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tvtots$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/uglydate$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/uinttoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/utvtoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ymd2yd$U.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/a_md5encrypt.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/adjtime.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/adjtimex.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/assertions.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/atoint.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/atolfp.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/atouint.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/audio.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/authkeys.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/authreadkeys.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/authusekey.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/bsd_strerror.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/buffer.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/buftvtots.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/caljulian.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/caltontp.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/calyearstart.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clocktime.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clocktypes.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/condition.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/decodenetnum.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dir.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dofptoa.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dolfptoa.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/emalloc.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/errno2result.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/error.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/event.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/file.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/findconfig.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fptoa.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fptoms.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/getopt.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/hextoint.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/hextolfp.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/humandate.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/icom.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/inet_ntop.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/inet_pton.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/interfaceiter.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/inttoa.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/iosignal.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/lib.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/lib_strbuf.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/log.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/machines.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/md5.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/memmove.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mfptoa.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mfptoms.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mktime.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/modetoa.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/msgcat.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mstolfp.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/msutotsf.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/msyslog.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/net.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/netaddr.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/netof.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/netscope.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_lineedit.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_random.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_rfc2553.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/numtoa.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/numtohost.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/octtoint.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ondestroy.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/prettydate.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/random.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/recvbuff.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refnumtoa.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/result.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/snprintf.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sockaddr.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/socktoa.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/socktohost.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ssl_init.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/statestr.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stdio.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stdtime.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/strdup.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/strerror.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/strstr.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/syssignal.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/systime.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/systime_s.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/task.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/thread.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/time.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tsftomsu.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tstotv.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tvtots.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/uglydate.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/uinttoa.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ymd2yd.Po@am__quote@ .c.o: @am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @@ -441,573 +536,397 @@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< -assertions_.o: assertions_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT assertions_.o -MD -MP -MF $(DEPDIR)/assertions_.Tpo -c -o assertions_.o `test -f 'assertions_.c' || echo '$(srcdir)/'`assertions_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/assertions_.Tpo $(DEPDIR)/assertions_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='assertions_.c' object='assertions_.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o assertions_.o `test -f 'assertions_.c' || echo '$(srcdir)/'`assertions_.c - -assertions_.obj: assertions_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT assertions_.obj -MD -MP -MF $(DEPDIR)/assertions_.Tpo -c -o assertions_.obj `if test -f 'assertions_.c'; then $(CYGPATH_W) 'assertions_.c'; else $(CYGPATH_W) '$(srcdir)/assertions_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/assertions_.Tpo $(DEPDIR)/assertions_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='assertions_.c' object='assertions_.obj' libtool=no @AMDEPBACKSLASH@ +assertions.o: $(srcdir)/../lib/isc/assertions.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT assertions.o -MD -MP -MF $(DEPDIR)/assertions.Tpo -c -o assertions.o `test -f '$(srcdir)/../lib/isc/assertions.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/assertions.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/assertions.Tpo $(DEPDIR)/assertions.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/assertions.c' object='assertions.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o assertions_.obj `if test -f 'assertions_.c'; then $(CYGPATH_W) 'assertions_.c'; else $(CYGPATH_W) '$(srcdir)/assertions_.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o assertions.o `test -f '$(srcdir)/../lib/isc/assertions.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/assertions.c -assertions.o: $(srcdir)/../libisc/assertions.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT assertions.o -MD -MP -MF $(DEPDIR)/assertions.Tpo -c -o assertions.o `test -f '$(srcdir)/../libisc/assertions.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/assertions.c +assertions.obj: $(srcdir)/../lib/isc/assertions.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT assertions.obj -MD -MP -MF $(DEPDIR)/assertions.Tpo -c -o assertions.obj `if test -f '$(srcdir)/../lib/isc/assertions.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/assertions.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/assertions.c'; fi` @am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/assertions.Tpo $(DEPDIR)/assertions.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/assertions.c' object='assertions.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/assertions.c' object='assertions.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o assertions.o `test -f '$(srcdir)/../libisc/assertions.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/assertions.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o assertions.obj `if test -f '$(srcdir)/../lib/isc/assertions.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/assertions.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/assertions.c'; fi` -assertions.obj: $(srcdir)/../libisc/assertions.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT assertions.obj -MD -MP -MF $(DEPDIR)/assertions.Tpo -c -o assertions.obj `if test -f '$(srcdir)/../libisc/assertions.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/assertions.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/assertions.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/assertions.Tpo $(DEPDIR)/assertions.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/assertions.c' object='assertions.obj' libtool=no @AMDEPBACKSLASH@ +buffer.o: $(srcdir)/../lib/isc/buffer.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT buffer.o -MD -MP -MF $(DEPDIR)/buffer.Tpo -c -o buffer.o `test -f '$(srcdir)/../lib/isc/buffer.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/buffer.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/buffer.Tpo $(DEPDIR)/buffer.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/buffer.c' object='buffer.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o assertions.obj `if test -f '$(srcdir)/../libisc/assertions.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/assertions.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/assertions.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o buffer.o `test -f '$(srcdir)/../lib/isc/buffer.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/buffer.c -error_.o: error_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT error_.o -MD -MP -MF $(DEPDIR)/error_.Tpo -c -o error_.o `test -f 'error_.c' || echo '$(srcdir)/'`error_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/error_.Tpo $(DEPDIR)/error_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='error_.c' object='error_.o' libtool=no @AMDEPBACKSLASH@ +buffer.obj: $(srcdir)/../lib/isc/buffer.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT buffer.obj -MD -MP -MF $(DEPDIR)/buffer.Tpo -c -o buffer.obj `if test -f '$(srcdir)/../lib/isc/buffer.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/buffer.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/buffer.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/buffer.Tpo $(DEPDIR)/buffer.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/buffer.c' object='buffer.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o error_.o `test -f 'error_.c' || echo '$(srcdir)/'`error_.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o buffer.obj `if test -f '$(srcdir)/../lib/isc/buffer.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/buffer.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/buffer.c'; fi` -error_.obj: error_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT error_.obj -MD -MP -MF $(DEPDIR)/error_.Tpo -c -o error_.obj `if test -f 'error_.c'; then $(CYGPATH_W) 'error_.c'; else $(CYGPATH_W) '$(srcdir)/error_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/error_.Tpo $(DEPDIR)/error_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='error_.c' object='error_.obj' libtool=no @AMDEPBACKSLASH@ +condition.o: $(srcdir)/../lib/isc/nothreads/condition.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT condition.o -MD -MP -MF $(DEPDIR)/condition.Tpo -c -o condition.o `test -f '$(srcdir)/../lib/isc/nothreads/condition.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/nothreads/condition.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/condition.Tpo $(DEPDIR)/condition.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/nothreads/condition.c' object='condition.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o error_.obj `if test -f 'error_.c'; then $(CYGPATH_W) 'error_.c'; else $(CYGPATH_W) '$(srcdir)/error_.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o condition.o `test -f '$(srcdir)/../lib/isc/nothreads/condition.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/nothreads/condition.c -error.o: $(srcdir)/../libisc/error.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT error.o -MD -MP -MF $(DEPDIR)/error.Tpo -c -o error.o `test -f '$(srcdir)/../libisc/error.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/error.c +condition.obj: $(srcdir)/../lib/isc/nothreads/condition.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT condition.obj -MD -MP -MF $(DEPDIR)/condition.Tpo -c -o condition.obj `if test -f '$(srcdir)/../lib/isc/nothreads/condition.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/nothreads/condition.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/nothreads/condition.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/condition.Tpo $(DEPDIR)/condition.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/nothreads/condition.c' object='condition.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o condition.obj `if test -f '$(srcdir)/../lib/isc/nothreads/condition.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/nothreads/condition.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/nothreads/condition.c'; fi` + +dir.o: $(srcdir)/../lib/isc/unix/dir.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dir.o -MD -MP -MF $(DEPDIR)/dir.Tpo -c -o dir.o `test -f '$(srcdir)/../lib/isc/unix/dir.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/dir.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/dir.Tpo $(DEPDIR)/dir.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/unix/dir.c' object='dir.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dir.o `test -f '$(srcdir)/../lib/isc/unix/dir.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/dir.c + +dir.obj: $(srcdir)/../lib/isc/unix/dir.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dir.obj -MD -MP -MF $(DEPDIR)/dir.Tpo -c -o dir.obj `if test -f '$(srcdir)/../lib/isc/unix/dir.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/dir.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/dir.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/dir.Tpo $(DEPDIR)/dir.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/unix/dir.c' object='dir.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dir.obj `if test -f '$(srcdir)/../lib/isc/unix/dir.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/dir.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/dir.c'; fi` + +error.o: $(srcdir)/../lib/isc/error.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT error.o -MD -MP -MF $(DEPDIR)/error.Tpo -c -o error.o `test -f '$(srcdir)/../lib/isc/error.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/error.c @am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/error.Tpo $(DEPDIR)/error.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/error.c' object='error.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/error.c' object='error.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o error.o `test -f '$(srcdir)/../libisc/error.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/error.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o error.o `test -f '$(srcdir)/../lib/isc/error.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/error.c -error.obj: $(srcdir)/../libisc/error.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT error.obj -MD -MP -MF $(DEPDIR)/error.Tpo -c -o error.obj `if test -f '$(srcdir)/../libisc/error.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/error.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/error.c'; fi` +error.obj: $(srcdir)/../lib/isc/error.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT error.obj -MD -MP -MF $(DEPDIR)/error.Tpo -c -o error.obj `if test -f '$(srcdir)/../lib/isc/error.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/error.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/error.c'; fi` @am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/error.Tpo $(DEPDIR)/error.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/error.c' object='error.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/error.c' object='error.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o error.obj `if test -f '$(srcdir)/../libisc/error.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/error.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/error.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o error.obj `if test -f '$(srcdir)/../lib/isc/error.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/error.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/error.c'; fi` -interfaceiter_.o: interfaceiter_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT interfaceiter_.o -MD -MP -MF $(DEPDIR)/interfaceiter_.Tpo -c -o interfaceiter_.o `test -f 'interfaceiter_.c' || echo '$(srcdir)/'`interfaceiter_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/interfaceiter_.Tpo $(DEPDIR)/interfaceiter_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='interfaceiter_.c' object='interfaceiter_.o' libtool=no @AMDEPBACKSLASH@ +errno2result.o: $(srcdir)/../lib/isc/unix/errno2result.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT errno2result.o -MD -MP -MF $(DEPDIR)/errno2result.Tpo -c -o errno2result.o `test -f '$(srcdir)/../lib/isc/unix/errno2result.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/errno2result.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/errno2result.Tpo $(DEPDIR)/errno2result.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/unix/errno2result.c' object='errno2result.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o interfaceiter_.o `test -f 'interfaceiter_.c' || echo '$(srcdir)/'`interfaceiter_.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o errno2result.o `test -f '$(srcdir)/../lib/isc/unix/errno2result.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/errno2result.c -interfaceiter_.obj: interfaceiter_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT interfaceiter_.obj -MD -MP -MF $(DEPDIR)/interfaceiter_.Tpo -c -o interfaceiter_.obj `if test -f 'interfaceiter_.c'; then $(CYGPATH_W) 'interfaceiter_.c'; else $(CYGPATH_W) '$(srcdir)/interfaceiter_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/interfaceiter_.Tpo $(DEPDIR)/interfaceiter_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='interfaceiter_.c' object='interfaceiter_.obj' libtool=no @AMDEPBACKSLASH@ +errno2result.obj: $(srcdir)/../lib/isc/unix/errno2result.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT errno2result.obj -MD -MP -MF $(DEPDIR)/errno2result.Tpo -c -o errno2result.obj `if test -f '$(srcdir)/../lib/isc/unix/errno2result.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/errno2result.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/errno2result.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/errno2result.Tpo $(DEPDIR)/errno2result.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/unix/errno2result.c' object='errno2result.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o interfaceiter_.obj `if test -f 'interfaceiter_.c'; then $(CYGPATH_W) 'interfaceiter_.c'; else $(CYGPATH_W) '$(srcdir)/interfaceiter_.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o errno2result.obj `if test -f '$(srcdir)/../lib/isc/unix/errno2result.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/errno2result.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/errno2result.c'; fi` -interfaceiter.o: $(srcdir)/../libisc/interfaceiter.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT interfaceiter.o -MD -MP -MF $(DEPDIR)/interfaceiter.Tpo -c -o interfaceiter.o `test -f '$(srcdir)/../libisc/interfaceiter.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/interfaceiter.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/interfaceiter.Tpo $(DEPDIR)/interfaceiter.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/interfaceiter.c' object='interfaceiter.o' libtool=no @AMDEPBACKSLASH@ +event.o: $(srcdir)/../lib/isc/event.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT event.o -MD -MP -MF $(DEPDIR)/event.Tpo -c -o event.o `test -f '$(srcdir)/../lib/isc/event.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/event.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/event.Tpo $(DEPDIR)/event.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/event.c' object='event.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o interfaceiter.o `test -f '$(srcdir)/../libisc/interfaceiter.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/interfaceiter.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o event.o `test -f '$(srcdir)/../lib/isc/event.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/event.c -interfaceiter.obj: $(srcdir)/../libisc/interfaceiter.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT interfaceiter.obj -MD -MP -MF $(DEPDIR)/interfaceiter.Tpo -c -o interfaceiter.obj `if test -f '$(srcdir)/../libisc/interfaceiter.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/interfaceiter.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/interfaceiter.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/interfaceiter.Tpo $(DEPDIR)/interfaceiter.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/interfaceiter.c' object='interfaceiter.obj' libtool=no @AMDEPBACKSLASH@ +event.obj: $(srcdir)/../lib/isc/event.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT event.obj -MD -MP -MF $(DEPDIR)/event.Tpo -c -o event.obj `if test -f '$(srcdir)/../lib/isc/event.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/event.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/event.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/event.Tpo $(DEPDIR)/event.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/event.c' object='event.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o interfaceiter.obj `if test -f '$(srcdir)/../libisc/interfaceiter.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/interfaceiter.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/interfaceiter.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o event.obj `if test -f '$(srcdir)/../lib/isc/event.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/event.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/event.c'; fi` -lib_.o: lib_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT lib_.o -MD -MP -MF $(DEPDIR)/lib_.Tpo -c -o lib_.o `test -f 'lib_.c' || echo '$(srcdir)/'`lib_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/lib_.Tpo $(DEPDIR)/lib_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='lib_.c' object='lib_.o' libtool=no @AMDEPBACKSLASH@ +file.o: $(srcdir)/../lib/isc/unix/file.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT file.o -MD -MP -MF $(DEPDIR)/file.Tpo -c -o file.o `test -f '$(srcdir)/../lib/isc/unix/file.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/file.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/file.Tpo $(DEPDIR)/file.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/unix/file.c' object='file.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o lib_.o `test -f 'lib_.c' || echo '$(srcdir)/'`lib_.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o file.o `test -f '$(srcdir)/../lib/isc/unix/file.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/file.c -lib_.obj: lib_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT lib_.obj -MD -MP -MF $(DEPDIR)/lib_.Tpo -c -o lib_.obj `if test -f 'lib_.c'; then $(CYGPATH_W) 'lib_.c'; else $(CYGPATH_W) '$(srcdir)/lib_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/lib_.Tpo $(DEPDIR)/lib_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='lib_.c' object='lib_.obj' libtool=no @AMDEPBACKSLASH@ +file.obj: $(srcdir)/../lib/isc/unix/file.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT file.obj -MD -MP -MF $(DEPDIR)/file.Tpo -c -o file.obj `if test -f '$(srcdir)/../lib/isc/unix/file.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/file.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/file.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/file.Tpo $(DEPDIR)/file.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/unix/file.c' object='file.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o lib_.obj `if test -f 'lib_.c'; then $(CYGPATH_W) 'lib_.c'; else $(CYGPATH_W) '$(srcdir)/lib_.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o file.obj `if test -f '$(srcdir)/../lib/isc/unix/file.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/file.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/file.c'; fi` -lib.o: $(srcdir)/../libisc/lib.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT lib.o -MD -MP -MF $(DEPDIR)/lib.Tpo -c -o lib.o `test -f '$(srcdir)/../libisc/lib.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/lib.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/lib.Tpo $(DEPDIR)/lib.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/lib.c' object='lib.o' libtool=no @AMDEPBACKSLASH@ +inet_ntop.o: $(srcdir)/../lib/isc/inet_ntop.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_ntop.o -MD -MP -MF $(DEPDIR)/inet_ntop.Tpo -c -o inet_ntop.o `test -f '$(srcdir)/../lib/isc/inet_ntop.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/inet_ntop.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/inet_ntop.Tpo $(DEPDIR)/inet_ntop.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/inet_ntop.c' object='inet_ntop.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o lib.o `test -f '$(srcdir)/../libisc/lib.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/lib.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_ntop.o `test -f '$(srcdir)/../lib/isc/inet_ntop.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/inet_ntop.c -lib.obj: $(srcdir)/../libisc/lib.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT lib.obj -MD -MP -MF $(DEPDIR)/lib.Tpo -c -o lib.obj `if test -f '$(srcdir)/../libisc/lib.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/lib.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/lib.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/lib.Tpo $(DEPDIR)/lib.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/lib.c' object='lib.obj' libtool=no @AMDEPBACKSLASH@ +inet_ntop.obj: $(srcdir)/../lib/isc/inet_ntop.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_ntop.obj -MD -MP -MF $(DEPDIR)/inet_ntop.Tpo -c -o inet_ntop.obj `if test -f '$(srcdir)/../lib/isc/inet_ntop.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/inet_ntop.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/inet_ntop.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/inet_ntop.Tpo $(DEPDIR)/inet_ntop.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/inet_ntop.c' object='inet_ntop.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o lib.obj `if test -f '$(srcdir)/../libisc/lib.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/lib.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/lib.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_ntop.obj `if test -f '$(srcdir)/../lib/isc/inet_ntop.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/inet_ntop.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/inet_ntop.c'; fi` -mem_.o: mem_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT mem_.o -MD -MP -MF $(DEPDIR)/mem_.Tpo -c -o mem_.o `test -f 'mem_.c' || echo '$(srcdir)/'`mem_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/mem_.Tpo $(DEPDIR)/mem_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='mem_.c' object='mem_.o' libtool=no @AMDEPBACKSLASH@ +inet_pton.o: $(srcdir)/../lib/isc/inet_pton.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_pton.o -MD -MP -MF $(DEPDIR)/inet_pton.Tpo -c -o inet_pton.o `test -f '$(srcdir)/../lib/isc/inet_pton.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/inet_pton.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/inet_pton.Tpo $(DEPDIR)/inet_pton.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/inet_pton.c' object='inet_pton.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o mem_.o `test -f 'mem_.c' || echo '$(srcdir)/'`mem_.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_pton.o `test -f '$(srcdir)/../lib/isc/inet_pton.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/inet_pton.c -mem_.obj: mem_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT mem_.obj -MD -MP -MF $(DEPDIR)/mem_.Tpo -c -o mem_.obj `if test -f 'mem_.c'; then $(CYGPATH_W) 'mem_.c'; else $(CYGPATH_W) '$(srcdir)/mem_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/mem_.Tpo $(DEPDIR)/mem_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='mem_.c' object='mem_.obj' libtool=no @AMDEPBACKSLASH@ +inet_pton.obj: $(srcdir)/../lib/isc/inet_pton.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_pton.obj -MD -MP -MF $(DEPDIR)/inet_pton.Tpo -c -o inet_pton.obj `if test -f '$(srcdir)/../lib/isc/inet_pton.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/inet_pton.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/inet_pton.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/inet_pton.Tpo $(DEPDIR)/inet_pton.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/inet_pton.c' object='inet_pton.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o mem_.obj `if test -f 'mem_.c'; then $(CYGPATH_W) 'mem_.c'; else $(CYGPATH_W) '$(srcdir)/mem_.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_pton.obj `if test -f '$(srcdir)/../lib/isc/inet_pton.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/inet_pton.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/inet_pton.c'; fi` -mem.o: $(srcdir)/../libisc/mem.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT mem.o -MD -MP -MF $(DEPDIR)/mem.Tpo -c -o mem.o `test -f '$(srcdir)/../libisc/mem.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/mem.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/mem.Tpo $(DEPDIR)/mem.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/mem.c' object='mem.o' libtool=no @AMDEPBACKSLASH@ +interfaceiter.o: $(srcdir)/../lib/isc/unix/interfaceiter.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT interfaceiter.o -MD -MP -MF $(DEPDIR)/interfaceiter.Tpo -c -o interfaceiter.o `test -f '$(srcdir)/../lib/isc/unix/interfaceiter.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/interfaceiter.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/interfaceiter.Tpo $(DEPDIR)/interfaceiter.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/unix/interfaceiter.c' object='interfaceiter.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o mem.o `test -f '$(srcdir)/../libisc/mem.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/mem.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o interfaceiter.o `test -f '$(srcdir)/../lib/isc/unix/interfaceiter.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/interfaceiter.c -mem.obj: $(srcdir)/../libisc/mem.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT mem.obj -MD -MP -MF $(DEPDIR)/mem.Tpo -c -o mem.obj `if test -f '$(srcdir)/../libisc/mem.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/mem.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/mem.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/mem.Tpo $(DEPDIR)/mem.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/mem.c' object='mem.obj' libtool=no @AMDEPBACKSLASH@ +interfaceiter.obj: $(srcdir)/../lib/isc/unix/interfaceiter.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT interfaceiter.obj -MD -MP -MF $(DEPDIR)/interfaceiter.Tpo -c -o interfaceiter.obj `if test -f '$(srcdir)/../lib/isc/unix/interfaceiter.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/interfaceiter.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/interfaceiter.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/interfaceiter.Tpo $(DEPDIR)/interfaceiter.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/unix/interfaceiter.c' object='interfaceiter.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o mem.obj `if test -f '$(srcdir)/../libisc/mem.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/mem.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/mem.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o interfaceiter.obj `if test -f '$(srcdir)/../lib/isc/unix/interfaceiter.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/interfaceiter.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/interfaceiter.c'; fi` -msgcat_.o: msgcat_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT msgcat_.o -MD -MP -MF $(DEPDIR)/msgcat_.Tpo -c -o msgcat_.o `test -f 'msgcat_.c' || echo '$(srcdir)/'`msgcat_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/msgcat_.Tpo $(DEPDIR)/msgcat_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='msgcat_.c' object='msgcat_.o' libtool=no @AMDEPBACKSLASH@ +lib.o: $(srcdir)/../lib/isc/lib.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT lib.o -MD -MP -MF $(DEPDIR)/lib.Tpo -c -o lib.o `test -f '$(srcdir)/../lib/isc/lib.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/lib.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/lib.Tpo $(DEPDIR)/lib.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/lib.c' object='lib.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o msgcat_.o `test -f 'msgcat_.c' || echo '$(srcdir)/'`msgcat_.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o lib.o `test -f '$(srcdir)/../lib/isc/lib.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/lib.c -msgcat_.obj: msgcat_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT msgcat_.obj -MD -MP -MF $(DEPDIR)/msgcat_.Tpo -c -o msgcat_.obj `if test -f 'msgcat_.c'; then $(CYGPATH_W) 'msgcat_.c'; else $(CYGPATH_W) '$(srcdir)/msgcat_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/msgcat_.Tpo $(DEPDIR)/msgcat_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='msgcat_.c' object='msgcat_.obj' libtool=no @AMDEPBACKSLASH@ +lib.obj: $(srcdir)/../lib/isc/lib.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT lib.obj -MD -MP -MF $(DEPDIR)/lib.Tpo -c -o lib.obj `if test -f '$(srcdir)/../lib/isc/lib.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/lib.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/lib.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/lib.Tpo $(DEPDIR)/lib.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/lib.c' object='lib.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o msgcat_.obj `if test -f 'msgcat_.c'; then $(CYGPATH_W) 'msgcat_.c'; else $(CYGPATH_W) '$(srcdir)/msgcat_.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o lib.obj `if test -f '$(srcdir)/../lib/isc/lib.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/lib.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/lib.c'; fi` -msgcat.o: $(srcdir)/../libisc/msgcat.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT msgcat.o -MD -MP -MF $(DEPDIR)/msgcat.Tpo -c -o msgcat.o `test -f '$(srcdir)/../libisc/msgcat.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/msgcat.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/msgcat.Tpo $(DEPDIR)/msgcat.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/msgcat.c' object='msgcat.o' libtool=no @AMDEPBACKSLASH@ +log.o: $(srcdir)/../lib/isc/log.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT log.o -MD -MP -MF $(DEPDIR)/log.Tpo -c -o log.o `test -f '$(srcdir)/../lib/isc/log.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/log.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/log.Tpo $(DEPDIR)/log.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/log.c' object='log.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o msgcat.o `test -f '$(srcdir)/../libisc/msgcat.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/msgcat.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o log.o `test -f '$(srcdir)/../lib/isc/log.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/log.c -msgcat.obj: $(srcdir)/../libisc/msgcat.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT msgcat.obj -MD -MP -MF $(DEPDIR)/msgcat.Tpo -c -o msgcat.obj `if test -f '$(srcdir)/../libisc/msgcat.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/msgcat.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/msgcat.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/msgcat.Tpo $(DEPDIR)/msgcat.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/msgcat.c' object='msgcat.obj' libtool=no @AMDEPBACKSLASH@ +log.obj: $(srcdir)/../lib/isc/log.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT log.obj -MD -MP -MF $(DEPDIR)/log.Tpo -c -o log.obj `if test -f '$(srcdir)/../lib/isc/log.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/log.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/log.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/log.Tpo $(DEPDIR)/log.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/log.c' object='log.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o log.obj `if test -f '$(srcdir)/../lib/isc/log.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/log.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/log.c'; fi` + +md5.o: $(srcdir)/../lib/isc/md5.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT md5.o -MD -MP -MF $(DEPDIR)/md5.Tpo -c -o md5.o `test -f '$(srcdir)/../lib/isc/md5.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/md5.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/md5.Tpo $(DEPDIR)/md5.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/md5.c' object='md5.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o msgcat.obj `if test -f '$(srcdir)/../libisc/msgcat.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/msgcat.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/msgcat.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o md5.o `test -f '$(srcdir)/../lib/isc/md5.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/md5.c -net_.o: net_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT net_.o -MD -MP -MF $(DEPDIR)/net_.Tpo -c -o net_.o `test -f 'net_.c' || echo '$(srcdir)/'`net_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/net_.Tpo $(DEPDIR)/net_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='net_.c' object='net_.o' libtool=no @AMDEPBACKSLASH@ +md5.obj: $(srcdir)/../lib/isc/md5.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT md5.obj -MD -MP -MF $(DEPDIR)/md5.Tpo -c -o md5.obj `if test -f '$(srcdir)/../lib/isc/md5.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/md5.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/md5.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/md5.Tpo $(DEPDIR)/md5.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/md5.c' object='md5.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o md5.obj `if test -f '$(srcdir)/../lib/isc/md5.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/md5.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/md5.c'; fi` + +msgcat.o: $(srcdir)/../lib/isc/nls/msgcat.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT msgcat.o -MD -MP -MF $(DEPDIR)/msgcat.Tpo -c -o msgcat.o `test -f '$(srcdir)/../lib/isc/nls/msgcat.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/nls/msgcat.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/msgcat.Tpo $(DEPDIR)/msgcat.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/nls/msgcat.c' object='msgcat.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o net_.o `test -f 'net_.c' || echo '$(srcdir)/'`net_.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o msgcat.o `test -f '$(srcdir)/../lib/isc/nls/msgcat.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/nls/msgcat.c -net_.obj: net_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT net_.obj -MD -MP -MF $(DEPDIR)/net_.Tpo -c -o net_.obj `if test -f 'net_.c'; then $(CYGPATH_W) 'net_.c'; else $(CYGPATH_W) '$(srcdir)/net_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/net_.Tpo $(DEPDIR)/net_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='net_.c' object='net_.obj' libtool=no @AMDEPBACKSLASH@ +msgcat.obj: $(srcdir)/../lib/isc/nls/msgcat.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT msgcat.obj -MD -MP -MF $(DEPDIR)/msgcat.Tpo -c -o msgcat.obj `if test -f '$(srcdir)/../lib/isc/nls/msgcat.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/nls/msgcat.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/nls/msgcat.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/msgcat.Tpo $(DEPDIR)/msgcat.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/nls/msgcat.c' object='msgcat.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o net_.obj `if test -f 'net_.c'; then $(CYGPATH_W) 'net_.c'; else $(CYGPATH_W) '$(srcdir)/net_.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o msgcat.obj `if test -f '$(srcdir)/../lib/isc/nls/msgcat.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/nls/msgcat.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/nls/msgcat.c'; fi` -net.o: $(srcdir)/../libisc/net.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT net.o -MD -MP -MF $(DEPDIR)/net.Tpo -c -o net.o `test -f '$(srcdir)/../libisc/net.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/net.c +net.o: $(srcdir)/../lib/isc/unix/net.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT net.o -MD -MP -MF $(DEPDIR)/net.Tpo -c -o net.o `test -f '$(srcdir)/../lib/isc/unix/net.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/net.c @am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/net.Tpo $(DEPDIR)/net.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/net.c' object='net.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/unix/net.c' object='net.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o net.o `test -f '$(srcdir)/../libisc/net.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/net.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o net.o `test -f '$(srcdir)/../lib/isc/unix/net.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/net.c -net.obj: $(srcdir)/../libisc/net.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT net.obj -MD -MP -MF $(DEPDIR)/net.Tpo -c -o net.obj `if test -f '$(srcdir)/../libisc/net.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/net.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/net.c'; fi` +net.obj: $(srcdir)/../lib/isc/unix/net.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT net.obj -MD -MP -MF $(DEPDIR)/net.Tpo -c -o net.obj `if test -f '$(srcdir)/../lib/isc/unix/net.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/net.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/net.c'; fi` @am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/net.Tpo $(DEPDIR)/net.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/net.c' object='net.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/unix/net.c' object='net.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o net.obj `if test -f '$(srcdir)/../libisc/net.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/net.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/net.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o net.obj `if test -f '$(srcdir)/../lib/isc/unix/net.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/net.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/net.c'; fi` -isc_strerror_.o: isc_strerror_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT isc_strerror_.o -MD -MP -MF $(DEPDIR)/isc_strerror_.Tpo -c -o isc_strerror_.o `test -f 'isc_strerror_.c' || echo '$(srcdir)/'`isc_strerror_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/isc_strerror_.Tpo $(DEPDIR)/isc_strerror_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='isc_strerror_.c' object='isc_strerror_.o' libtool=no @AMDEPBACKSLASH@ +netaddr.o: $(srcdir)/../lib/isc/netaddr.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netaddr.o -MD -MP -MF $(DEPDIR)/netaddr.Tpo -c -o netaddr.o `test -f '$(srcdir)/../lib/isc/netaddr.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/netaddr.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/netaddr.Tpo $(DEPDIR)/netaddr.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/netaddr.c' object='netaddr.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o isc_strerror_.o `test -f 'isc_strerror_.c' || echo '$(srcdir)/'`isc_strerror_.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netaddr.o `test -f '$(srcdir)/../lib/isc/netaddr.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/netaddr.c -isc_strerror_.obj: isc_strerror_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT isc_strerror_.obj -MD -MP -MF $(DEPDIR)/isc_strerror_.Tpo -c -o isc_strerror_.obj `if test -f 'isc_strerror_.c'; then $(CYGPATH_W) 'isc_strerror_.c'; else $(CYGPATH_W) '$(srcdir)/isc_strerror_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/isc_strerror_.Tpo $(DEPDIR)/isc_strerror_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='isc_strerror_.c' object='isc_strerror_.obj' libtool=no @AMDEPBACKSLASH@ +netaddr.obj: $(srcdir)/../lib/isc/netaddr.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netaddr.obj -MD -MP -MF $(DEPDIR)/netaddr.Tpo -c -o netaddr.obj `if test -f '$(srcdir)/../lib/isc/netaddr.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/netaddr.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/netaddr.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/netaddr.Tpo $(DEPDIR)/netaddr.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/netaddr.c' object='netaddr.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o isc_strerror_.obj `if test -f 'isc_strerror_.c'; then $(CYGPATH_W) 'isc_strerror_.c'; else $(CYGPATH_W) '$(srcdir)/isc_strerror_.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netaddr.obj `if test -f '$(srcdir)/../lib/isc/netaddr.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/netaddr.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/netaddr.c'; fi` -isc_strerror.o: $(srcdir)/../libisc/isc_strerror.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT isc_strerror.o -MD -MP -MF $(DEPDIR)/isc_strerror.Tpo -c -o isc_strerror.o `test -f '$(srcdir)/../libisc/isc_strerror.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/isc_strerror.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/isc_strerror.Tpo $(DEPDIR)/isc_strerror.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/isc_strerror.c' object='isc_strerror.o' libtool=no @AMDEPBACKSLASH@ +netscope.o: $(srcdir)/../lib/isc/netscope.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netscope.o -MD -MP -MF $(DEPDIR)/netscope.Tpo -c -o netscope.o `test -f '$(srcdir)/../lib/isc/netscope.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/netscope.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/netscope.Tpo $(DEPDIR)/netscope.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/netscope.c' object='netscope.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o isc_strerror.o `test -f '$(srcdir)/../libisc/isc_strerror.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/isc_strerror.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netscope.o `test -f '$(srcdir)/../lib/isc/netscope.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/netscope.c -isc_strerror.obj: $(srcdir)/../libisc/isc_strerror.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT isc_strerror.obj -MD -MP -MF $(DEPDIR)/isc_strerror.Tpo -c -o isc_strerror.obj `if test -f '$(srcdir)/../libisc/isc_strerror.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/isc_strerror.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/isc_strerror.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/isc_strerror.Tpo $(DEPDIR)/isc_strerror.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/isc_strerror.c' object='isc_strerror.obj' libtool=no @AMDEPBACKSLASH@ +netscope.obj: $(srcdir)/../lib/isc/netscope.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netscope.obj -MD -MP -MF $(DEPDIR)/netscope.Tpo -c -o netscope.obj `if test -f '$(srcdir)/../lib/isc/netscope.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/netscope.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/netscope.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/netscope.Tpo $(DEPDIR)/netscope.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/netscope.c' object='netscope.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o isc_strerror.obj `if test -f '$(srcdir)/../libisc/isc_strerror.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/isc_strerror.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/isc_strerror.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netscope.obj `if test -f '$(srcdir)/../lib/isc/netscope.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/netscope.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/netscope.c'; fi` -inet_ntop_.o: inet_ntop_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_ntop_.o -MD -MP -MF $(DEPDIR)/inet_ntop_.Tpo -c -o inet_ntop_.o `test -f 'inet_ntop_.c' || echo '$(srcdir)/'`inet_ntop_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/inet_ntop_.Tpo $(DEPDIR)/inet_ntop_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='inet_ntop_.c' object='inet_ntop_.o' libtool=no @AMDEPBACKSLASH@ +ondestroy.o: $(srcdir)/../lib/isc/ondestroy.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT ondestroy.o -MD -MP -MF $(DEPDIR)/ondestroy.Tpo -c -o ondestroy.o `test -f '$(srcdir)/../lib/isc/ondestroy.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/ondestroy.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ondestroy.Tpo $(DEPDIR)/ondestroy.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/ondestroy.c' object='ondestroy.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_ntop_.o `test -f 'inet_ntop_.c' || echo '$(srcdir)/'`inet_ntop_.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o ondestroy.o `test -f '$(srcdir)/../lib/isc/ondestroy.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/ondestroy.c -inet_ntop_.obj: inet_ntop_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_ntop_.obj -MD -MP -MF $(DEPDIR)/inet_ntop_.Tpo -c -o inet_ntop_.obj `if test -f 'inet_ntop_.c'; then $(CYGPATH_W) 'inet_ntop_.c'; else $(CYGPATH_W) '$(srcdir)/inet_ntop_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/inet_ntop_.Tpo $(DEPDIR)/inet_ntop_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='inet_ntop_.c' object='inet_ntop_.obj' libtool=no @AMDEPBACKSLASH@ +ondestroy.obj: $(srcdir)/../lib/isc/ondestroy.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT ondestroy.obj -MD -MP -MF $(DEPDIR)/ondestroy.Tpo -c -o ondestroy.obj `if test -f '$(srcdir)/../lib/isc/ondestroy.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/ondestroy.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/ondestroy.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ondestroy.Tpo $(DEPDIR)/ondestroy.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/ondestroy.c' object='ondestroy.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_ntop_.obj `if test -f 'inet_ntop_.c'; then $(CYGPATH_W) 'inet_ntop_.c'; else $(CYGPATH_W) '$(srcdir)/inet_ntop_.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o ondestroy.obj `if test -f '$(srcdir)/../lib/isc/ondestroy.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/ondestroy.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/ondestroy.c'; fi` -inet_ntop.o: $(srcdir)/../libisc/inet_ntop.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_ntop.o -MD -MP -MF $(DEPDIR)/inet_ntop.Tpo -c -o inet_ntop.o `test -f '$(srcdir)/../libisc/inet_ntop.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/inet_ntop.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/inet_ntop.Tpo $(DEPDIR)/inet_ntop.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/inet_ntop.c' object='inet_ntop.o' libtool=no @AMDEPBACKSLASH@ +random.o: $(srcdir)/../lib/isc/random.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT random.o -MD -MP -MF $(DEPDIR)/random.Tpo -c -o random.o `test -f '$(srcdir)/../lib/isc/random.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/random.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/random.Tpo $(DEPDIR)/random.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/random.c' object='random.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_ntop.o `test -f '$(srcdir)/../libisc/inet_ntop.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/inet_ntop.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o random.o `test -f '$(srcdir)/../lib/isc/random.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/random.c -inet_ntop.obj: $(srcdir)/../libisc/inet_ntop.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_ntop.obj -MD -MP -MF $(DEPDIR)/inet_ntop.Tpo -c -o inet_ntop.obj `if test -f '$(srcdir)/../libisc/inet_ntop.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/inet_ntop.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/inet_ntop.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/inet_ntop.Tpo $(DEPDIR)/inet_ntop.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/inet_ntop.c' object='inet_ntop.obj' libtool=no @AMDEPBACKSLASH@ +random.obj: $(srcdir)/../lib/isc/random.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT random.obj -MD -MP -MF $(DEPDIR)/random.Tpo -c -o random.obj `if test -f '$(srcdir)/../lib/isc/random.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/random.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/random.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/random.Tpo $(DEPDIR)/random.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/random.c' object='random.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_ntop.obj `if test -f '$(srcdir)/../libisc/inet_ntop.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/inet_ntop.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/inet_ntop.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o random.obj `if test -f '$(srcdir)/../lib/isc/random.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/random.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/random.c'; fi` -inet_pton_.o: inet_pton_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_pton_.o -MD -MP -MF $(DEPDIR)/inet_pton_.Tpo -c -o inet_pton_.o `test -f 'inet_pton_.c' || echo '$(srcdir)/'`inet_pton_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/inet_pton_.Tpo $(DEPDIR)/inet_pton_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='inet_pton_.c' object='inet_pton_.o' libtool=no @AMDEPBACKSLASH@ +result.o: $(srcdir)/../lib/isc/result.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT result.o -MD -MP -MF $(DEPDIR)/result.Tpo -c -o result.o `test -f '$(srcdir)/../lib/isc/result.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/result.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/result.Tpo $(DEPDIR)/result.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/result.c' object='result.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_pton_.o `test -f 'inet_pton_.c' || echo '$(srcdir)/'`inet_pton_.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o result.o `test -f '$(srcdir)/../lib/isc/result.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/result.c -inet_pton_.obj: inet_pton_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_pton_.obj -MD -MP -MF $(DEPDIR)/inet_pton_.Tpo -c -o inet_pton_.obj `if test -f 'inet_pton_.c'; then $(CYGPATH_W) 'inet_pton_.c'; else $(CYGPATH_W) '$(srcdir)/inet_pton_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/inet_pton_.Tpo $(DEPDIR)/inet_pton_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='inet_pton_.c' object='inet_pton_.obj' libtool=no @AMDEPBACKSLASH@ +result.obj: $(srcdir)/../lib/isc/result.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT result.obj -MD -MP -MF $(DEPDIR)/result.Tpo -c -o result.obj `if test -f '$(srcdir)/../lib/isc/result.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/result.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/result.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/result.Tpo $(DEPDIR)/result.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/result.c' object='result.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_pton_.obj `if test -f 'inet_pton_.c'; then $(CYGPATH_W) 'inet_pton_.c'; else $(CYGPATH_W) '$(srcdir)/inet_pton_.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o result.obj `if test -f '$(srcdir)/../lib/isc/result.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/result.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/result.c'; fi` -inet_pton.o: $(srcdir)/../libisc/inet_pton.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_pton.o -MD -MP -MF $(DEPDIR)/inet_pton.Tpo -c -o inet_pton.o `test -f '$(srcdir)/../libisc/inet_pton.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/inet_pton.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/inet_pton.Tpo $(DEPDIR)/inet_pton.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/inet_pton.c' object='inet_pton.o' libtool=no @AMDEPBACKSLASH@ +stdio.o: $(srcdir)/../lib/isc/unix/stdio.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT stdio.o -MD -MP -MF $(DEPDIR)/stdio.Tpo -c -o stdio.o `test -f '$(srcdir)/../lib/isc/unix/stdio.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/stdio.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/stdio.Tpo $(DEPDIR)/stdio.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/unix/stdio.c' object='stdio.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_pton.o `test -f '$(srcdir)/../libisc/inet_pton.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/inet_pton.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o stdio.o `test -f '$(srcdir)/../lib/isc/unix/stdio.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/stdio.c -inet_pton.obj: $(srcdir)/../libisc/inet_pton.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_pton.obj -MD -MP -MF $(DEPDIR)/inet_pton.Tpo -c -o inet_pton.obj `if test -f '$(srcdir)/../libisc/inet_pton.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/inet_pton.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/inet_pton.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/inet_pton.Tpo $(DEPDIR)/inet_pton.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/inet_pton.c' object='inet_pton.obj' libtool=no @AMDEPBACKSLASH@ +stdio.obj: $(srcdir)/../lib/isc/unix/stdio.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT stdio.obj -MD -MP -MF $(DEPDIR)/stdio.Tpo -c -o stdio.obj `if test -f '$(srcdir)/../lib/isc/unix/stdio.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/stdio.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/stdio.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/stdio.Tpo $(DEPDIR)/stdio.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/unix/stdio.c' object='stdio.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_pton.obj `if test -f '$(srcdir)/../libisc/inet_pton.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/inet_pton.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/inet_pton.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o stdio.obj `if test -f '$(srcdir)/../lib/isc/unix/stdio.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/stdio.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/stdio.c'; fi` -netaddr_.o: netaddr_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netaddr_.o -MD -MP -MF $(DEPDIR)/netaddr_.Tpo -c -o netaddr_.o `test -f 'netaddr_.c' || echo '$(srcdir)/'`netaddr_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/netaddr_.Tpo $(DEPDIR)/netaddr_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='netaddr_.c' object='netaddr_.o' libtool=no @AMDEPBACKSLASH@ +stdtime.o: $(srcdir)/../lib/isc/unix/stdtime.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT stdtime.o -MD -MP -MF $(DEPDIR)/stdtime.Tpo -c -o stdtime.o `test -f '$(srcdir)/../lib/isc/unix/stdtime.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/stdtime.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/stdtime.Tpo $(DEPDIR)/stdtime.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/unix/stdtime.c' object='stdtime.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netaddr_.o `test -f 'netaddr_.c' || echo '$(srcdir)/'`netaddr_.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o stdtime.o `test -f '$(srcdir)/../lib/isc/unix/stdtime.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/stdtime.c -netaddr_.obj: netaddr_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netaddr_.obj -MD -MP -MF $(DEPDIR)/netaddr_.Tpo -c -o netaddr_.obj `if test -f 'netaddr_.c'; then $(CYGPATH_W) 'netaddr_.c'; else $(CYGPATH_W) '$(srcdir)/netaddr_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/netaddr_.Tpo $(DEPDIR)/netaddr_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='netaddr_.c' object='netaddr_.obj' libtool=no @AMDEPBACKSLASH@ +stdtime.obj: $(srcdir)/../lib/isc/unix/stdtime.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT stdtime.obj -MD -MP -MF $(DEPDIR)/stdtime.Tpo -c -o stdtime.obj `if test -f '$(srcdir)/../lib/isc/unix/stdtime.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/stdtime.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/stdtime.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/stdtime.Tpo $(DEPDIR)/stdtime.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/unix/stdtime.c' object='stdtime.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netaddr_.obj `if test -f 'netaddr_.c'; then $(CYGPATH_W) 'netaddr_.c'; else $(CYGPATH_W) '$(srcdir)/netaddr_.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o stdtime.obj `if test -f '$(srcdir)/../lib/isc/unix/stdtime.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/stdtime.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/stdtime.c'; fi` -netaddr.o: $(srcdir)/../libisc/netaddr.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netaddr.o -MD -MP -MF $(DEPDIR)/netaddr.Tpo -c -o netaddr.o `test -f '$(srcdir)/../libisc/netaddr.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/netaddr.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/netaddr.Tpo $(DEPDIR)/netaddr.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/netaddr.c' object='netaddr.o' libtool=no @AMDEPBACKSLASH@ +strerror.o: $(srcdir)/../lib/isc/unix/strerror.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT strerror.o -MD -MP -MF $(DEPDIR)/strerror.Tpo -c -o strerror.o `test -f '$(srcdir)/../lib/isc/unix/strerror.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/strerror.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/strerror.Tpo $(DEPDIR)/strerror.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/unix/strerror.c' object='strerror.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netaddr.o `test -f '$(srcdir)/../libisc/netaddr.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/netaddr.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o strerror.o `test -f '$(srcdir)/../lib/isc/unix/strerror.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/strerror.c -netaddr.obj: $(srcdir)/../libisc/netaddr.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netaddr.obj -MD -MP -MF $(DEPDIR)/netaddr.Tpo -c -o netaddr.obj `if test -f '$(srcdir)/../libisc/netaddr.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/netaddr.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/netaddr.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/netaddr.Tpo $(DEPDIR)/netaddr.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/netaddr.c' object='netaddr.obj' libtool=no @AMDEPBACKSLASH@ +strerror.obj: $(srcdir)/../lib/isc/unix/strerror.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT strerror.obj -MD -MP -MF $(DEPDIR)/strerror.Tpo -c -o strerror.obj `if test -f '$(srcdir)/../lib/isc/unix/strerror.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/strerror.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/strerror.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/strerror.Tpo $(DEPDIR)/strerror.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/unix/strerror.c' object='strerror.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netaddr.obj `if test -f '$(srcdir)/../libisc/netaddr.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/netaddr.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/netaddr.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o strerror.obj `if test -f '$(srcdir)/../lib/isc/unix/strerror.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/strerror.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/strerror.c'; fi` -sockaddr_.o: sockaddr_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT sockaddr_.o -MD -MP -MF $(DEPDIR)/sockaddr_.Tpo -c -o sockaddr_.o `test -f 'sockaddr_.c' || echo '$(srcdir)/'`sockaddr_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/sockaddr_.Tpo $(DEPDIR)/sockaddr_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='sockaddr_.c' object='sockaddr_.o' libtool=no @AMDEPBACKSLASH@ +task.o: $(srcdir)/../lib/isc/task.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT task.o -MD -MP -MF $(DEPDIR)/task.Tpo -c -o task.o `test -f '$(srcdir)/../lib/isc/task.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/task.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/task.Tpo $(DEPDIR)/task.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/task.c' object='task.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o sockaddr_.o `test -f 'sockaddr_.c' || echo '$(srcdir)/'`sockaddr_.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o task.o `test -f '$(srcdir)/../lib/isc/task.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/task.c -sockaddr_.obj: sockaddr_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT sockaddr_.obj -MD -MP -MF $(DEPDIR)/sockaddr_.Tpo -c -o sockaddr_.obj `if test -f 'sockaddr_.c'; then $(CYGPATH_W) 'sockaddr_.c'; else $(CYGPATH_W) '$(srcdir)/sockaddr_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/sockaddr_.Tpo $(DEPDIR)/sockaddr_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='sockaddr_.c' object='sockaddr_.obj' libtool=no @AMDEPBACKSLASH@ +task.obj: $(srcdir)/../lib/isc/task.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT task.obj -MD -MP -MF $(DEPDIR)/task.Tpo -c -o task.obj `if test -f '$(srcdir)/../lib/isc/task.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/task.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/task.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/task.Tpo $(DEPDIR)/task.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/task.c' object='task.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o sockaddr_.obj `if test -f 'sockaddr_.c'; then $(CYGPATH_W) 'sockaddr_.c'; else $(CYGPATH_W) '$(srcdir)/sockaddr_.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o task.obj `if test -f '$(srcdir)/../lib/isc/task.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/task.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/task.c'; fi` -sockaddr.o: $(srcdir)/../libisc/sockaddr.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT sockaddr.o -MD -MP -MF $(DEPDIR)/sockaddr.Tpo -c -o sockaddr.o `test -f '$(srcdir)/../libisc/sockaddr.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/sockaddr.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/sockaddr.Tpo $(DEPDIR)/sockaddr.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/sockaddr.c' object='sockaddr.o' libtool=no @AMDEPBACKSLASH@ +thread.o: $(srcdir)/../lib/isc/nothreads/thread.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT thread.o -MD -MP -MF $(DEPDIR)/thread.Tpo -c -o thread.o `test -f '$(srcdir)/../lib/isc/nothreads/thread.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/nothreads/thread.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/thread.Tpo $(DEPDIR)/thread.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/nothreads/thread.c' object='thread.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o sockaddr.o `test -f '$(srcdir)/../libisc/sockaddr.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/sockaddr.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o thread.o `test -f '$(srcdir)/../lib/isc/nothreads/thread.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/nothreads/thread.c -sockaddr.obj: $(srcdir)/../libisc/sockaddr.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT sockaddr.obj -MD -MP -MF $(DEPDIR)/sockaddr.Tpo -c -o sockaddr.obj `if test -f '$(srcdir)/../libisc/sockaddr.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/sockaddr.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/sockaddr.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/sockaddr.Tpo $(DEPDIR)/sockaddr.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/sockaddr.c' object='sockaddr.obj' libtool=no @AMDEPBACKSLASH@ +thread.obj: $(srcdir)/../lib/isc/nothreads/thread.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT thread.obj -MD -MP -MF $(DEPDIR)/thread.Tpo -c -o thread.obj `if test -f '$(srcdir)/../lib/isc/nothreads/thread.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/nothreads/thread.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/nothreads/thread.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/thread.Tpo $(DEPDIR)/thread.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/nothreads/thread.c' object='thread.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o sockaddr.obj `if test -f '$(srcdir)/../libisc/sockaddr.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/sockaddr.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/sockaddr.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o thread.obj `if test -f '$(srcdir)/../lib/isc/nothreads/thread.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/nothreads/thread.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/nothreads/thread.c'; fi` -netscope_.o: netscope_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netscope_.o -MD -MP -MF $(DEPDIR)/netscope_.Tpo -c -o netscope_.o `test -f 'netscope_.c' || echo '$(srcdir)/'`netscope_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/netscope_.Tpo $(DEPDIR)/netscope_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='netscope_.c' object='netscope_.o' libtool=no @AMDEPBACKSLASH@ +time.o: $(srcdir)/../lib/isc/unix/time.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT time.o -MD -MP -MF $(DEPDIR)/time.Tpo -c -o time.o `test -f '$(srcdir)/../lib/isc/unix/time.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/time.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/time.Tpo $(DEPDIR)/time.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/unix/time.c' object='time.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netscope_.o `test -f 'netscope_.c' || echo '$(srcdir)/'`netscope_.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o time.o `test -f '$(srcdir)/../lib/isc/unix/time.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/time.c -netscope_.obj: netscope_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netscope_.obj -MD -MP -MF $(DEPDIR)/netscope_.Tpo -c -o netscope_.obj `if test -f 'netscope_.c'; then $(CYGPATH_W) 'netscope_.c'; else $(CYGPATH_W) '$(srcdir)/netscope_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/netscope_.Tpo $(DEPDIR)/netscope_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='netscope_.c' object='netscope_.obj' libtool=no @AMDEPBACKSLASH@ +time.obj: $(srcdir)/../lib/isc/unix/time.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT time.obj -MD -MP -MF $(DEPDIR)/time.Tpo -c -o time.obj `if test -f '$(srcdir)/../lib/isc/unix/time.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/time.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/time.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/time.Tpo $(DEPDIR)/time.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/unix/time.c' object='time.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netscope_.obj `if test -f 'netscope_.c'; then $(CYGPATH_W) 'netscope_.c'; else $(CYGPATH_W) '$(srcdir)/netscope_.c'; fi` +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o time.obj `if test -f '$(srcdir)/../lib/isc/unix/time.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/time.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/time.c'; fi` -netscope.o: $(srcdir)/../libisc/netscope.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netscope.o -MD -MP -MF $(DEPDIR)/netscope.Tpo -c -o netscope.o `test -f '$(srcdir)/../libisc/netscope.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/netscope.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/netscope.Tpo $(DEPDIR)/netscope.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/netscope.c' object='netscope.o' libtool=no @AMDEPBACKSLASH@ +sockaddr.o: $(srcdir)/../lib/isc/sockaddr.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT sockaddr.o -MD -MP -MF $(DEPDIR)/sockaddr.Tpo -c -o sockaddr.o `test -f '$(srcdir)/../lib/isc/sockaddr.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/sockaddr.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/sockaddr.Tpo $(DEPDIR)/sockaddr.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/sockaddr.c' object='sockaddr.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netscope.o `test -f '$(srcdir)/../libisc/netscope.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/netscope.c +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o sockaddr.o `test -f '$(srcdir)/../lib/isc/sockaddr.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/sockaddr.c -netscope.obj: $(srcdir)/../libisc/netscope.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netscope.obj -MD -MP -MF $(DEPDIR)/netscope.Tpo -c -o netscope.obj `if test -f '$(srcdir)/../libisc/netscope.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/netscope.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/netscope.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/netscope.Tpo $(DEPDIR)/netscope.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/netscope.c' object='netscope.obj' libtool=no @AMDEPBACKSLASH@ +sockaddr.obj: $(srcdir)/../lib/isc/sockaddr.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT sockaddr.obj -MD -MP -MF $(DEPDIR)/sockaddr.Tpo -c -o sockaddr.obj `if test -f '$(srcdir)/../lib/isc/sockaddr.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/sockaddr.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/sockaddr.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/sockaddr.Tpo $(DEPDIR)/sockaddr.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../lib/isc/sockaddr.c' object='sockaddr.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netscope.obj `if test -f '$(srcdir)/../libisc/netscope.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/netscope.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/netscope.c'; fi` -a_md5encrypt_.c: a_md5encrypt.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/a_md5encrypt.c; then echo $(srcdir)/a_md5encrypt.c; else echo a_md5encrypt.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -adjtime_.c: adjtime.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/adjtime.c; then echo $(srcdir)/adjtime.c; else echo adjtime.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -adjtimex_.c: adjtimex.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/adjtimex.c; then echo $(srcdir)/adjtimex.c; else echo adjtimex.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -assertions_.c: $(srcdir)/../libisc/assertions.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/assertions.c; then echo $(srcdir)/$(srcdir)/../libisc/assertions.c; else echo $(srcdir)/../libisc/assertions.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -atoint_.c: atoint.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/atoint.c; then echo $(srcdir)/atoint.c; else echo atoint.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -atolfp_.c: atolfp.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/atolfp.c; then echo $(srcdir)/atolfp.c; else echo atolfp.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -atouint_.c: atouint.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/atouint.c; then echo $(srcdir)/atouint.c; else echo atouint.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -audio_.c: audio.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/audio.c; then echo $(srcdir)/audio.c; else echo audio.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -authkeys_.c: authkeys.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/authkeys.c; then echo $(srcdir)/authkeys.c; else echo authkeys.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -authreadkeys_.c: authreadkeys.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/authreadkeys.c; then echo $(srcdir)/authreadkeys.c; else echo authreadkeys.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -authusekey_.c: authusekey.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/authusekey.c; then echo $(srcdir)/authusekey.c; else echo authusekey.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -buftvtots_.c: buftvtots.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/buftvtots.c; then echo $(srcdir)/buftvtots.c; else echo buftvtots.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -caljulian_.c: caljulian.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/caljulian.c; then echo $(srcdir)/caljulian.c; else echo caljulian.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -caltontp_.c: caltontp.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/caltontp.c; then echo $(srcdir)/caltontp.c; else echo caltontp.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -calyearstart_.c: calyearstart.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/calyearstart.c; then echo $(srcdir)/calyearstart.c; else echo calyearstart.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clocktime_.c: clocktime.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clocktime.c; then echo $(srcdir)/clocktime.c; else echo clocktime.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clocktypes_.c: clocktypes.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clocktypes.c; then echo $(srcdir)/clocktypes.c; else echo clocktypes.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -decodenetnum_.c: decodenetnum.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/decodenetnum.c; then echo $(srcdir)/decodenetnum.c; else echo decodenetnum.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -dofptoa_.c: dofptoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/dofptoa.c; then echo $(srcdir)/dofptoa.c; else echo dofptoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -dolfptoa_.c: dolfptoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/dolfptoa.c; then echo $(srcdir)/dolfptoa.c; else echo dolfptoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -emalloc_.c: emalloc.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/emalloc.c; then echo $(srcdir)/emalloc.c; else echo emalloc.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -error_.c: $(srcdir)/../libisc/error.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/error.c; then echo $(srcdir)/$(srcdir)/../libisc/error.c; else echo $(srcdir)/../libisc/error.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -findconfig_.c: findconfig.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/findconfig.c; then echo $(srcdir)/findconfig.c; else echo findconfig.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -fptoa_.c: fptoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/fptoa.c; then echo $(srcdir)/fptoa.c; else echo fptoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -fptoms_.c: fptoms.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/fptoms.c; then echo $(srcdir)/fptoms.c; else echo fptoms.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -getopt_.c: getopt.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/getopt.c; then echo $(srcdir)/getopt.c; else echo getopt.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -hextoint_.c: hextoint.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/hextoint.c; then echo $(srcdir)/hextoint.c; else echo hextoint.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -hextolfp_.c: hextolfp.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/hextolfp.c; then echo $(srcdir)/hextolfp.c; else echo hextolfp.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -humandate_.c: humandate.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/humandate.c; then echo $(srcdir)/humandate.c; else echo humandate.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -icom_.c: icom.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/icom.c; then echo $(srcdir)/icom.c; else echo icom.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -inet_ntop_.c: $(srcdir)/../libisc/inet_ntop.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/inet_ntop.c; then echo $(srcdir)/$(srcdir)/../libisc/inet_ntop.c; else echo $(srcdir)/../libisc/inet_ntop.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -inet_pton_.c: $(srcdir)/../libisc/inet_pton.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/inet_pton.c; then echo $(srcdir)/$(srcdir)/../libisc/inet_pton.c; else echo $(srcdir)/../libisc/inet_pton.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -interfaceiter_.c: $(srcdir)/../libisc/interfaceiter.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/interfaceiter.c; then echo $(srcdir)/$(srcdir)/../libisc/interfaceiter.c; else echo $(srcdir)/../libisc/interfaceiter.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -inttoa_.c: inttoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/inttoa.c; then echo $(srcdir)/inttoa.c; else echo inttoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -iosignal_.c: iosignal.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/iosignal.c; then echo $(srcdir)/iosignal.c; else echo iosignal.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -isc_strerror_.c: $(srcdir)/../libisc/isc_strerror.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/isc_strerror.c; then echo $(srcdir)/$(srcdir)/../libisc/isc_strerror.c; else echo $(srcdir)/../libisc/isc_strerror.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -lib_.c: $(srcdir)/../libisc/lib.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/lib.c; then echo $(srcdir)/$(srcdir)/../libisc/lib.c; else echo $(srcdir)/../libisc/lib.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -lib_strbuf_.c: lib_strbuf.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/lib_strbuf.c; then echo $(srcdir)/lib_strbuf.c; else echo lib_strbuf.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -machines_.c: machines.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/machines.c; then echo $(srcdir)/machines.c; else echo machines.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -md5c_.c: md5c.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/md5c.c; then echo $(srcdir)/md5c.c; else echo md5c.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -mem_.c: $(srcdir)/../libisc/mem.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/mem.c; then echo $(srcdir)/$(srcdir)/../libisc/mem.c; else echo $(srcdir)/../libisc/mem.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -memmove_.c: memmove.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/memmove.c; then echo $(srcdir)/memmove.c; else echo memmove.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -mfptoa_.c: mfptoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/mfptoa.c; then echo $(srcdir)/mfptoa.c; else echo mfptoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -mfptoms_.c: mfptoms.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/mfptoms.c; then echo $(srcdir)/mfptoms.c; else echo mfptoms.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -mktime_.c: mktime.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/mktime.c; then echo $(srcdir)/mktime.c; else echo mktime.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -modetoa_.c: modetoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/modetoa.c; then echo $(srcdir)/modetoa.c; else echo modetoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -msgcat_.c: $(srcdir)/../libisc/msgcat.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/msgcat.c; then echo $(srcdir)/$(srcdir)/../libisc/msgcat.c; else echo $(srcdir)/../libisc/msgcat.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -mstolfp_.c: mstolfp.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/mstolfp.c; then echo $(srcdir)/mstolfp.c; else echo mstolfp.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -msutotsf_.c: msutotsf.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/msutotsf.c; then echo $(srcdir)/msutotsf.c; else echo msutotsf.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -msyslog_.c: msyslog.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/msyslog.c; then echo $(srcdir)/msyslog.c; else echo msyslog.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -net_.c: $(srcdir)/../libisc/net.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/net.c; then echo $(srcdir)/$(srcdir)/../libisc/net.c; else echo $(srcdir)/../libisc/net.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -netaddr_.c: $(srcdir)/../libisc/netaddr.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/netaddr.c; then echo $(srcdir)/$(srcdir)/../libisc/netaddr.c; else echo $(srcdir)/../libisc/netaddr.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -netof_.c: netof.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/netof.c; then echo $(srcdir)/netof.c; else echo netof.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -netscope_.c: $(srcdir)/../libisc/netscope.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/netscope.c; then echo $(srcdir)/$(srcdir)/../libisc/netscope.c; else echo $(srcdir)/../libisc/netscope.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_random_.c: ntp_random.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_random.c; then echo $(srcdir)/ntp_random.c; else echo ntp_random.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_rfc2553_.c: ntp_rfc2553.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_rfc2553.c; then echo $(srcdir)/ntp_rfc2553.c; else echo ntp_rfc2553.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -numtoa_.c: numtoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/numtoa.c; then echo $(srcdir)/numtoa.c; else echo numtoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -numtohost_.c: numtohost.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/numtohost.c; then echo $(srcdir)/numtohost.c; else echo numtohost.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -octtoint_.c: octtoint.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/octtoint.c; then echo $(srcdir)/octtoint.c; else echo octtoint.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -prettydate_.c: prettydate.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/prettydate.c; then echo $(srcdir)/prettydate.c; else echo prettydate.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -recvbuff_.c: recvbuff.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/recvbuff.c; then echo $(srcdir)/recvbuff.c; else echo recvbuff.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refnumtoa_.c: refnumtoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refnumtoa.c; then echo $(srcdir)/refnumtoa.c; else echo refnumtoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -snprintf_.c: snprintf.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/snprintf.c; then echo $(srcdir)/snprintf.c; else echo snprintf.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -sockaddr_.c: $(srcdir)/../libisc/sockaddr.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/sockaddr.c; then echo $(srcdir)/$(srcdir)/../libisc/sockaddr.c; else echo $(srcdir)/../libisc/sockaddr.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -socktoa_.c: socktoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/socktoa.c; then echo $(srcdir)/socktoa.c; else echo socktoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -socktohost_.c: socktohost.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/socktohost.c; then echo $(srcdir)/socktohost.c; else echo socktohost.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -statestr_.c: statestr.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/statestr.c; then echo $(srcdir)/statestr.c; else echo statestr.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -strdup_.c: strdup.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/strdup.c; then echo $(srcdir)/strdup.c; else echo strdup.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -strerror_.c: strerror.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/strerror.c; then echo $(srcdir)/strerror.c; else echo strerror.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -strstr_.c: strstr.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/strstr.c; then echo $(srcdir)/strstr.c; else echo strstr.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -syssignal_.c: syssignal.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/syssignal.c; then echo $(srcdir)/syssignal.c; else echo syssignal.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -systime_.c: systime.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/systime.c; then echo $(srcdir)/systime.c; else echo systime.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -systime_s_.c: systime_s.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/systime_s.c; then echo $(srcdir)/systime_s.c; else echo systime_s.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -tsftomsu_.c: tsftomsu.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/tsftomsu.c; then echo $(srcdir)/tsftomsu.c; else echo tsftomsu.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -tstotv_.c: tstotv.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/tstotv.c; then echo $(srcdir)/tstotv.c; else echo tstotv.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -tvtoa_.c: tvtoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/tvtoa.c; then echo $(srcdir)/tvtoa.c; else echo tvtoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -tvtots_.c: tvtots.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/tvtots.c; then echo $(srcdir)/tvtots.c; else echo tvtots.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -uglydate_.c: uglydate.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/uglydate.c; then echo $(srcdir)/uglydate.c; else echo uglydate.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -uinttoa_.c: uinttoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/uinttoa.c; then echo $(srcdir)/uinttoa.c; else echo uinttoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -utvtoa_.c: utvtoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/utvtoa.c; then echo $(srcdir)/utvtoa.c; else echo utvtoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ymd2yd_.c: ymd2yd.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ymd2yd.c; then echo $(srcdir)/ymd2yd.c; else echo ymd2yd.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -a_md5encrypt_.$(OBJEXT) a_md5encrypt_.lo adjtime_.$(OBJEXT) \ -adjtime_.lo adjtimex_.$(OBJEXT) adjtimex_.lo assertions_.$(OBJEXT) \ -assertions_.lo atoint_.$(OBJEXT) atoint_.lo atolfp_.$(OBJEXT) \ -atolfp_.lo atouint_.$(OBJEXT) atouint_.lo audio_.$(OBJEXT) audio_.lo \ -authkeys_.$(OBJEXT) authkeys_.lo authreadkeys_.$(OBJEXT) \ -authreadkeys_.lo authusekey_.$(OBJEXT) authusekey_.lo \ -buftvtots_.$(OBJEXT) buftvtots_.lo caljulian_.$(OBJEXT) caljulian_.lo \ -caltontp_.$(OBJEXT) caltontp_.lo calyearstart_.$(OBJEXT) \ -calyearstart_.lo clocktime_.$(OBJEXT) clocktime_.lo \ -clocktypes_.$(OBJEXT) clocktypes_.lo decodenetnum_.$(OBJEXT) \ -decodenetnum_.lo dofptoa_.$(OBJEXT) dofptoa_.lo dolfptoa_.$(OBJEXT) \ -dolfptoa_.lo emalloc_.$(OBJEXT) emalloc_.lo error_.$(OBJEXT) error_.lo \ -findconfig_.$(OBJEXT) findconfig_.lo fptoa_.$(OBJEXT) fptoa_.lo \ -fptoms_.$(OBJEXT) fptoms_.lo getopt_.$(OBJEXT) getopt_.lo \ -hextoint_.$(OBJEXT) hextoint_.lo hextolfp_.$(OBJEXT) hextolfp_.lo \ -humandate_.$(OBJEXT) humandate_.lo icom_.$(OBJEXT) icom_.lo \ -inet_ntop_.$(OBJEXT) inet_ntop_.lo inet_pton_.$(OBJEXT) inet_pton_.lo \ -interfaceiter_.$(OBJEXT) interfaceiter_.lo inttoa_.$(OBJEXT) \ -inttoa_.lo iosignal_.$(OBJEXT) iosignal_.lo isc_strerror_.$(OBJEXT) \ -isc_strerror_.lo lib_.$(OBJEXT) lib_.lo lib_strbuf_.$(OBJEXT) \ -lib_strbuf_.lo machines_.$(OBJEXT) machines_.lo md5c_.$(OBJEXT) \ -md5c_.lo mem_.$(OBJEXT) mem_.lo memmove_.$(OBJEXT) memmove_.lo \ -mfptoa_.$(OBJEXT) mfptoa_.lo mfptoms_.$(OBJEXT) mfptoms_.lo \ -mktime_.$(OBJEXT) mktime_.lo modetoa_.$(OBJEXT) modetoa_.lo \ -msgcat_.$(OBJEXT) msgcat_.lo mstolfp_.$(OBJEXT) mstolfp_.lo \ -msutotsf_.$(OBJEXT) msutotsf_.lo msyslog_.$(OBJEXT) msyslog_.lo \ -net_.$(OBJEXT) net_.lo netaddr_.$(OBJEXT) netaddr_.lo netof_.$(OBJEXT) \ -netof_.lo netscope_.$(OBJEXT) netscope_.lo ntp_random_.$(OBJEXT) \ -ntp_random_.lo ntp_rfc2553_.$(OBJEXT) ntp_rfc2553_.lo \ -numtoa_.$(OBJEXT) numtoa_.lo numtohost_.$(OBJEXT) numtohost_.lo \ -octtoint_.$(OBJEXT) octtoint_.lo prettydate_.$(OBJEXT) prettydate_.lo \ -recvbuff_.$(OBJEXT) recvbuff_.lo refnumtoa_.$(OBJEXT) refnumtoa_.lo \ -snprintf_.$(OBJEXT) snprintf_.lo sockaddr_.$(OBJEXT) sockaddr_.lo \ -socktoa_.$(OBJEXT) socktoa_.lo socktohost_.$(OBJEXT) socktohost_.lo \ -statestr_.$(OBJEXT) statestr_.lo strdup_.$(OBJEXT) strdup_.lo \ -strerror_.$(OBJEXT) strerror_.lo strstr_.$(OBJEXT) strstr_.lo \ -syssignal_.$(OBJEXT) syssignal_.lo systime_.$(OBJEXT) systime_.lo \ -systime_s_.$(OBJEXT) systime_s_.lo tsftomsu_.$(OBJEXT) tsftomsu_.lo \ -tstotv_.$(OBJEXT) tstotv_.lo tvtoa_.$(OBJEXT) tvtoa_.lo \ -tvtots_.$(OBJEXT) tvtots_.lo uglydate_.$(OBJEXT) uglydate_.lo \ -uinttoa_.$(OBJEXT) uinttoa_.lo utvtoa_.$(OBJEXT) utvtoa_.lo \ -ymd2yd_.$(OBJEXT) ymd2yd_.lo : $(ANSI2KNR) +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o sockaddr.obj `if test -f '$(srcdir)/../lib/isc/sockaddr.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/sockaddr.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/sockaddr.c'; fi` mostlyclean-libtool: -rm -f *.lo @@ -1098,10 +1017,12 @@ fi; \ done check-am: all-am -check: check-am -all-am: Makefile $(LIBRARIES) $(HEADERS) +check: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) check-am +all-am: Makefile $(LIBRARIES) installdirs: -install: install-am +install: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am @@ -1118,6 +1039,7 @@ mostlyclean-generic: clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) @@ -1126,6 +1048,7 @@ maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." + -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-am clean-am: clean-generic clean-libtool clean-noinstLIBRARIES \ @@ -1184,7 +1107,7 @@ mostlyclean: mostlyclean-am -mostlyclean-am: mostlyclean-compile mostlyclean-generic mostlyclean-kr \ +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am @@ -1197,7 +1120,7 @@ uninstall-am: -.MAKE: ../util/ansi2knr install-am install-strip +.MAKE: all check install install-am install-strip .PHONY: CTAGS GTAGS all all-am check check-am clean clean-generic \ clean-libtool clean-noinstLIBRARIES ctags distclean \ @@ -1209,13 +1132,73 @@ install-pdf install-pdf-am install-ps install-ps-am \ install-strip installcheck installcheck-am installdirs \ maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-compile mostlyclean-generic mostlyclean-kr \ - mostlyclean-libtool pdf pdf-am ps ps-am tags uninstall \ - uninstall-am - + mostlyclean-compile mostlyclean-generic mostlyclean-libtool \ + pdf pdf-am ps ps-am tags uninstall uninstall-am -../include/des.h: - touch ../include/des.h +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + ..) \ + cd .. && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + *) \ + echo 'Fatal: depsver.mf Automake fragment limited' \ + 'to immediate subdirectories.' && \ + echo "top_builddir: $(top_builddir)" && \ + echo "subdir: $(subdir)" && \ + exit 1 \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff -urN src/contrib/ntp/libntp/a_md5encrypt.c src.ntp/contrib/ntp/libntp/a_md5encrypt.c --- src/contrib/ntp/libntp/a_md5encrypt.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/a_md5encrypt.c 2010-05-11 09:46:54.000000000 +0200 @@ -1,13 +1,6 @@ /* - * MD5 interface for rsaref2.0 - * - * These routines implement an interface for the RSA Laboratories - * implementation of the Message Digest 5 (MD5) algorithm. This - * algorithm is included in the rsaref2.0 package available from RSA in - * the US and foreign countries. Further information is available at - * www.rsa.com. + * digest support for NTP, MD5 and with OpenSSL more */ - #ifdef HAVE_CONFIG_H #include #endif @@ -15,69 +8,79 @@ #include "ntp_fp.h" #include "ntp_string.h" #include "ntp_stdlib.h" - -/* Disable the openssl md5 includes, because they'd clash with ours. */ -/* #define NO_MD5 */ -/* #define OPENSSL_NO_MD5 */ -#undef OPENSSL - #include "ntp.h" -#include "global.h" -#include "ntp_md5.h" +#ifdef OPENSSL +# include "openssl/evp.h" +#else +# include "ntp_md5.h" /* provides clone of OpenSSL MD5 API */ +#endif /* - * MD5authencrypt - generate MD5 message authenticator + * MD5authencrypt - generate message digest * - * Returns length of authenticator field. + * Returns length of MAC including key ID and digest. */ int MD5authencrypt( - u_char *key, /* key pointer */ + int type, /* hash algorithm */ + u_char *key, /* key pointer */ u_int32 *pkt, /* packet pointer */ - int length /* packet length */ + int length /* packet length */ ) { - MD5_CTX md5; - u_char digest[16]; + u_char digest[EVP_MAX_MD_SIZE]; + u_int len; + EVP_MD_CTX ctx; /* - * MD5 with key identifier concatenated with packet. + * Compute digest of key concatenated with packet. Note: the + * key type and digest type have been verified when the key + * was creaded. */ - MD5Init(&md5); - MD5Update(&md5, key, (u_int)cache_keylen); - MD5Update(&md5, (u_char *)pkt, (u_int)length); - MD5Final(digest, &md5); - memmove((u_char *)pkt + length + 4, digest, 16); - return (16 + 4); + INIT_SSL(); + EVP_DigestInit(&ctx, EVP_get_digestbynid(type)); + EVP_DigestUpdate(&ctx, key, (u_int)cache_keylen); + EVP_DigestUpdate(&ctx, (u_char *)pkt, (u_int)length); + EVP_DigestFinal(&ctx, digest, &len); + memmove((u_char *)pkt + length + 4, digest, len); + return (len + 4); } /* * MD5authdecrypt - verify MD5 message authenticator * - * Returns one if authenticator valid, zero if invalid. + * Returns one if digest valid, zero if invalid. */ int MD5authdecrypt( - u_char *key, /* key pointer */ - u_int32 *pkt, /* packet pointer */ - int length, /* packet length */ - int size /* MAC size */ + int type, /* hash algorithm */ + u_char *key, /* key pointer */ + u_int32 *pkt, /* packet pointer */ + int length, /* packet length */ + int size /* MAC size */ ) { - MD5_CTX md5; - u_char digest[16]; + u_char digest[EVP_MAX_MD_SIZE]; + u_int len; + EVP_MD_CTX ctx; /* - * MD5 with key identifier concatenated with packet. + * Compute digest of key concatenated with packet. Note: the + * key type and digest type have been verified when the key + * was created. */ - MD5Init(&md5); - MD5Update(&md5, key, (u_int)cache_keylen); - MD5Update(&md5, (u_char *)pkt, (u_int)length); - MD5Final(digest, &md5); - if (size != 16 + 4) + INIT_SSL(); + EVP_DigestInit(&ctx, EVP_get_digestbynid(type)); + EVP_DigestUpdate(&ctx, key, (u_int)cache_keylen); + EVP_DigestUpdate(&ctx, (u_char *)pkt, (u_int)length); + EVP_DigestFinal(&ctx, digest, &len); + if ((u_int)size != len + 4) { + msyslog(LOG_ERR, + "MAC decrypt: MAC length error"); return (0); - return (!memcmp(digest, (char *)pkt + length + 4, 16)); + } + return (!memcmp(digest, (char *)pkt + length + 4, len)); } /* @@ -86,19 +89,21 @@ * it and use the bottom 4 bytes. */ u_int32 -addr2refid(struct sockaddr_storage *addr) +addr2refid(sockaddr_u *addr) { - MD5_CTX md5; - u_char digest[16]; - u_int32 addr_refid; - - if (addr->ss_family == AF_INET) - return (GET_INADDR(*addr)); - - MD5Init(&md5); - MD5Update(&md5, (u_char *)&GET_INADDR6(*addr), + u_char digest[20]; + u_int32 addr_refid; + EVP_MD_CTX ctx; + u_int len; + + if (IS_IPV4(addr)) + return (NSRCADR(addr)); + + INIT_SSL(); + EVP_DigestInit(&ctx, EVP_get_digestbynid(NID_md5)); + EVP_DigestUpdate(&ctx, (u_char *)PSOCK_ADDR6(addr), sizeof(struct in6_addr)); - MD5Final(digest, &md5); + EVP_DigestFinal(&ctx, digest, &len); memcpy(&addr_refid, digest, 4); return (addr_refid); } diff -urN src/contrib/ntp/libntp/atolfp.c src.ntp/contrib/ntp/libntp/atolfp.c --- src/contrib/ntp/libntp/atolfp.c 1999-12-09 14:01:09.000000000 +0100 +++ src.ntp/contrib/ntp/libntp/atolfp.c 2009-12-09 08:36:35.000000000 +0100 @@ -6,6 +6,7 @@ #include "ntp_fp.h" #include "ntp_string.h" +#include "ntp_assert.h" /* * Powers of 10 @@ -38,6 +39,8 @@ int isneg; static const char *digits = "0123456789"; + NTP_REQUIRE(str != NULL); + isneg = 0; dec_i = dec_f = 0; ndec = 0; diff -urN src/contrib/ntp/libntp/audio.c src.ntp/contrib/ntp/libntp/audio.c --- src/contrib/ntp/libntp/audio.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/audio.c 2010-02-04 08:26:56.000000000 +0100 @@ -67,8 +67,8 @@ static int ctl_fd; /* audio control file descriptor */ #ifdef PCM_STYLE_SOUND -static void audio_config_read P((int, char **, char **)); -static int mixer_name P((const char *, int)); +static void audio_config_read (int, char **, char **); +static int mixer_name (const char *, int); int @@ -121,15 +121,18 @@ FILE *fd; char device[20], line[100], ab[100]; - sprintf(device, "%s%d", INIT_FILE, unit); + snprintf(device, sizeof(device), "%s%d", INIT_FILE, unit); if ((fd = fopen(device, "r")) == NULL) { printf("audio_config_read: <%s> NO\n", device); - sprintf(device, "%s.%d", INIT_FILE, unit); + snprintf(device, sizeof(device), "%s.%d", INIT_FILE, + unit); if ((fd = fopen(device, "r")) == NULL) { printf("audio_config_read: <%s> NO\n", device); - sprintf(device, "%s.%d", INIT_FILE, unit); + snprintf(device, sizeof(device), "%s", + INIT_FILE); if ((fd = fopen(device, "r")) == NULL) { - printf("audio_config_read: <%s> NO\n", device); + printf("audio_config_read: <%s> NO\n", + device); return; } } @@ -233,7 +236,7 @@ ; #ifdef PCM_STYLE_SOUND - (void)sprintf(actl_dev, ACTL_DEV, unit); + snprintf(actl_dev, sizeof(actl_dev), ACTL_DEV, unit); audio_config_read(unit, &actl, &dname); /* If we have values for cf_c_dev or cf_i_dev, use them. */ @@ -244,18 +247,21 @@ #endif /* - * Open audio device. Do not complain if not there. + * Open audio device */ fd = open(dname, O_RDWR | O_NONBLOCK, 0777); - if (fd < 0) + if (fd < 0) { + msyslog(LOG_ERR, "audio_init: %s %m\n", dname); return (fd); + } /* * Open audio control device. */ ctl_fd = open(actl, O_RDWR); if (ctl_fd < 0) { - msyslog(LOG_ERR, "audio_init: invalid control device <%s>\n", actl); + msyslog(LOG_ERR, "audio_init: invalid control device <%s>\n", + actl); close(fd); return(ctl_fd); } @@ -377,9 +383,10 @@ if (debug > 1) printf("audio_gain: gain %d/%d\n", gain, l); # endif +#if 0 /* not a good idea to do this; connector wiring dependency */ /* figure out what channel(s) to use. just nuke right for now. */ r = 0 ; /* setting to zero nicely mutes the channel */ - +#endif l |= r << 8; if ( cf_agc ) rval = ioctl(ctl_fd, agc, &l); diff -urN src/contrib/ntp/libntp/authkeys.c src.ntp/contrib/ntp/libntp/authkeys.c --- src/contrib/ntp/libntp/authkeys.c 2004-07-20 17:01:20.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/authkeys.c 2009-12-09 08:36:35.000000000 +0100 @@ -1,7 +1,6 @@ /* * authkeys.c - routines to manage the storage of authentication keys */ - #ifdef HAVE_CONFIG_H # include #endif @@ -22,17 +21,16 @@ struct savekey { struct savekey *next; union { - long bogon; /* Make sure nonempty */ - u_char MD5_key[32]; /* MD5 key */ + u_char MD5_key[64]; /* for keys up to to 512 bits */ } k; keyid_t keyid; /* key identifier */ + int type; /* key type */ u_short flags; /* flags that wave */ u_long lifetime; /* remaining lifetime */ int keylen; /* key length */ }; #define KEY_TRUSTED 0x001 /* this key is trusted */ -#define KEY_MD5 0x200 /* this is a MD5 type key */ /* * The hash table. This is indexed by the low order bits of the @@ -68,6 +66,7 @@ keyid_t cache_keyid; /* key identifier */ u_char *cache_key; /* key pointer */ u_int cache_keylen; /* key length */ +int cache_type; /* key type */ u_short cache_flags; /* flags that wave */ @@ -143,28 +142,47 @@ if (keyno == 0 || keyno == cache_keyid) return (1); + /* + * Seach the bin for the key. If found and the key type + * is zero, somebody marked it trusted without specifying + * a key or key type. In this case consider the key missing. + */ authkeyuncached++; sk = key_hash[KEYHASH(keyno)]; - while (sk != 0) { - if (keyno == sk->keyid) - break; + while (sk != NULL) { + if (keyno == sk->keyid) { + if (sk->type == 0) { + authkeynotfound++; + return (0); + } + break; + } sk = sk->next; } - if (sk == 0) { + + /* + * If the key is not found, or if it is found but not trusted, + * the key is not considered found. + */ + if (sk == NULL) { authkeynotfound++; return (0); - } else if (!(sk->flags & KEY_TRUSTED)) { + + } + if (!(sk->flags & KEY_TRUSTED)) { authnokey++; return (0); } + + /* + * The key is found and trusted. Initialize the key cache. + */ cache_keyid = sk->keyid; + cache_type = sk->type; cache_flags = sk->flags; - if (sk->flags & KEY_MD5) { - cache_key = sk->k.MD5_key; - cache_keylen = sk->keylen; - return (1); - } - return (0); + cache_key = sk->k.MD5_key; + cache_keylen = sk->keylen; + return (1); } @@ -201,26 +219,36 @@ { struct savekey *sk; -#ifdef DEBUG - if (debug > 2) - printf("authtrust: keyid %08x life %lu\n", keyno, trust); -#endif + /* + * Search bin for key; if it does not exist and is untrusted, + * forget it. + */ sk = key_hash[KEYHASH(keyno)]; while (sk != 0) { if (keyno == sk->keyid) break; + sk = sk->next; } - if (sk == 0 && !trust) return; - + + /* + * There are two conditions remaining. Either it does not + * exist and is to be trusted or it does exist and is or is + * not to be trusted. + */ if (sk != 0) { if (cache_keyid == keyno) { cache_flags = 0; cache_keyid = 0; } + /* + * Key exists. If it is to be trusted, say so and + * update its lifetime. If not, return it to the + * free list. + */ if (trust > 0) { sk->flags |= KEY_TRUSTED; if (trust > 1) @@ -229,7 +257,6 @@ sk->lifetime = 0; return; } - sk->flags &= ~KEY_TRUSTED; { struct savekey *skp; @@ -250,6 +277,11 @@ return; } + /* + * Here there is not key, but the key is to be trusted. There + * seems to be a disconnect here. Here we allocate a new key, + * but do not specify a key type, key or key length. + */ if (authnumfreekeys == 0) if (auth_moremem() == 0) return; @@ -257,8 +289,9 @@ sk = authfreekeys; authfreekeys = sk->next; authnumfreekeys--; - sk->keyid = keyno; + sk->type = 0; + sk->keylen = 0; sk->flags = KEY_TRUSTED; sk->next = key_hash[KEYHASH(keyno)]; key_hash[KEYHASH(keyno)] = sk; @@ -290,6 +323,7 @@ if (sk == 0) { authkeynotfound++; return (0); + } else if (!(sk->flags & KEY_TRUSTED)) { authkeynotfound++; return (0); @@ -301,6 +335,7 @@ void MD5auth_setkey( keyid_t keyno, + int keytype, const u_char *key, const int len ) @@ -312,14 +347,16 @@ * new value. */ sk = key_hash[KEYHASH(keyno)]; - while (sk != 0) { + while (sk != NULL) { if (keyno == sk->keyid) { + sk->type = keytype; + sk->keylen = min(len, sizeof(sk->k.MD5_key)); +#ifndef DISABLE_BUG1243_FIX + memcpy(sk->k.MD5_key, key, sk->keylen); +#else strncpy((char *)sk->k.MD5_key, (const char *)key, sizeof(sk->k.MD5_key)); - if ((sk->keylen = len) > sizeof(sk->k.MD5_key)) - sk->keylen = sizeof(sk->k.MD5_key); - - sk->flags |= KEY_MD5; +#endif if (cache_keyid == keyno) { cache_flags = 0; cache_keyid = 0; @@ -332,29 +369,43 @@ /* * Need to allocate new structure. Do it. */ - if (authnumfreekeys == 0) { - if (auth_moremem() == 0) - return; - } + if (0 == authnumfreekeys && !auth_moremem()) + return; sk = authfreekeys; authfreekeys = sk->next; authnumfreekeys--; - strncpy((char *)sk->k.MD5_key, (const char *)key, - sizeof(sk->k.MD5_key)); - if ((sk->keylen = len) > sizeof(sk->k.MD5_key)) - sk->keylen = sizeof(sk->k.MD5_key); - sk->keyid = keyno; - sk->flags = KEY_MD5; + sk->type = keytype; + sk->flags = 0; sk->lifetime = 0; + sk->keylen = min(len, sizeof(sk->k.MD5_key)); +#ifndef DISABLE_BUG1243_FIX + memcpy(sk->k.MD5_key, key, sk->keylen); +#else + strncpy((char *)sk->k.MD5_key, (const char *)key, + sizeof(sk->k.MD5_key)); +#endif sk->next = key_hash[KEYHASH(keyno)]; key_hash[KEYHASH(keyno)] = sk; +#ifdef DEBUG + if (debug > 1) { + char hex[] = "0123456789abcdef"; + int j; + + printf("auth_setkey: key %d type %d len %d ", sk->keyid, + sk->type, sk->keylen); + for (j = 0; j < sk->keylen; j++) + printf("%c%c", hex[key[j] >> 4], + hex[key[j] & 0xf]); + printf("\n"); + } +#endif authnumkeys++; - return; } - + + /* * auth_delkeys - delete all known keys, in preparation for rereading * the keys file (presumably) @@ -449,10 +500,7 @@ if (!authhavekey(keyno)) return (0); - if (cache_flags & KEY_MD5) - return (MD5authencrypt(cache_key, pkt, length)); - - return (0); + return (MD5authencrypt(cache_type, cache_key, pkt, length)); } /* @@ -481,8 +529,6 @@ if (!authhavekey(keyno) || size < 4) return (0); - if (cache_flags & KEY_MD5) - return (MD5authdecrypt(cache_key, pkt, length, size)); - - return (0); + return (MD5authdecrypt(cache_type, cache_key, pkt, length, + size)); } diff -urN src/contrib/ntp/libntp/authreadkeys.c src.ntp/contrib/ntp/libntp/authreadkeys.c --- src/contrib/ntp/libntp/authreadkeys.c 2004-07-20 17:01:20.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/authreadkeys.c 2009-12-09 08:36:36.000000000 +0100 @@ -1,6 +1,7 @@ /* * authreadkeys.c - routines to support the reading of the key file */ +#include #include #include @@ -9,20 +10,19 @@ #include "ntp_syslog.h" #include "ntp_stdlib.h" -/* - * Arbitrary long string of ASCII characters. - */ -#define KEY_TYPE_MD5 4 +#ifdef OPENSSL +#include "openssl/objects.h" +#endif /* OPENSSL */ /* Forwards */ -static char *nexttok P((char **)); +static char *nexttok (char **); /* * nexttok - basic internal tokenizing routine */ static char * nexttok( - char **str + char **str ) { register char *cp; @@ -49,7 +49,7 @@ * token to zero and return start. */ if (starttok == cp) - return 0; + return (NULL); if (*cp == ' ' || *cp == '\t') *cp++ = '\0'; @@ -69,21 +69,26 @@ const char *file ) { - FILE *fp; - char *line; - char *token; - u_long keyno; - int keytype; - char buf[512]; /* lots of room for line */ + FILE *fp; + char *line; + char *token; + keyid_t keyno; + int keytype; + char buf[512]; /* lots of room for line */ + u_char keystr[20]; + int len; + int j; /* * Open file. Complain and return if it can't be opened. */ fp = fopen(file, "r"); if (fp == NULL) { - msyslog(LOG_ERR, "can't open key file %s: %m", file); - return 0; + msyslog(LOG_ERR, "authreadkeys: file %s: %m", + file); + return (0); } + INIT_SSL(); /* * Remove all existing keys @@ -95,8 +100,8 @@ */ while ((line = fgets(buf, sizeof buf, fp)) != NULL) { token = nexttok(&line); - if (token == 0) - continue; + if (token == NULL) + continue; /* * First is key number. See if it is okay. @@ -104,59 +109,96 @@ keyno = atoi(token); if (keyno == 0) { msyslog(LOG_ERR, - "cannot change keyid 0, key entry `%s' ignored", - token); + "authreadkeys: cannot change key %s", token); continue; } if (keyno > NTP_MAXKEY) { msyslog(LOG_ERR, - "keyid's > %d reserved for autokey, key entry `%s' ignored", - NTP_MAXKEY, token); + "authreadkeys: key %s > %d reserved for Autokey", + token, NTP_MAXKEY); continue; } /* - * Next is keytype. See if that is all right. + * Next is keytype. See if that is all right. */ token = nexttok(&line); - if (token == 0) { + if (token == NULL) { + msyslog(LOG_ERR, + "authreadkeys: no key type for key %d", keyno); + continue; + } +#ifdef OPENSSL + /* + * The key type is the NID used by the message digest + * algorithm. There are a number of inconsistencies in + * the OpenSSL database. We attempt to discover them + * here and prevent use of inconsistent data later. + */ + keytype = keytype_from_text(token, NULL); + if (keytype == 0) { msyslog(LOG_ERR, - "no key type for key number %ld, entry ignored", - keyno); + "authreadkeys: invalid type for key %d", keyno); continue; } - switch (*token) { - case 'M': - case 'm': - keytype = KEY_TYPE_MD5; break; - default: + if (EVP_get_digestbynid(keytype) == NULL) { msyslog(LOG_ERR, - "invalid key type for key number %ld, entry ignored", - keyno); + "authreadkeys: no algorithm for key %d", keyno); continue; } +#else /* OPENSSL */ /* - * Finally, get key and insert it + * The key type is unused, but is required to be 'M' or + * 'm' for compatibility. + */ + if (!(*token == 'M' || *token == 'm')) { + msyslog(LOG_ERR, + "authreadkeys: invalid type for key %d", keyno); + continue; + } + keytype = KEY_TYPE_MD5; +#endif /* OPENSSL */ + + /* + * Finally, get key and insert it. If it is longer than 20 + * characters, it is a binary string encoded in hex; + * otherwise, it is a text string of printable ASCII + * characters. */ token = nexttok(&line); - if (token == 0) { + if (token == NULL) { msyslog(LOG_ERR, - "no key for number %ld entry, entry ignored", - keyno); + "authreadkeys: no key for key %d", keyno); + continue; + } + len = strlen(token); + if (len <= 20) { + MD5auth_setkey(keyno, keytype, (u_char *)token, len); } else { - switch(keytype) { - case KEY_TYPE_MD5: - if (!authusekey(keyno, keytype, - (u_char *)token)) - msyslog(LOG_ERR, - "format/parity error for MD5 key %ld, not used", - keyno); - break; + char hex[] = "0123456789abcdef"; + u_char temp; + char *ptr; + int jlim; + + jlim = min(len, 2 * sizeof(keystr)); + for (j = 0; j < jlim; j++) { + ptr = strchr(hex, tolower(token[j])); + if (ptr == NULL) { + msyslog(LOG_ERR, + "authreadkeys: invalid hex digit for key %d", keyno); + continue; + } + temp = (u_char)(ptr - hex); + if (j & 1) + keystr[j / 2] |= temp; + else + keystr[j / 2] = temp << 4; } + MD5auth_setkey(keyno, keytype, keystr, jlim / 2); } } - (void) fclose(fp); - return 1; + fclose(fp); + return (1); } diff -urN src/contrib/ntp/libntp/authusekey.c src.ntp/contrib/ntp/libntp/authusekey.c --- src/contrib/ntp/libntp/authusekey.c 2004-07-20 17:01:20.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/authusekey.c 2009-12-09 08:36:37.000000000 +0100 @@ -15,9 +15,6 @@ * high order bit of each byte a parity bit. "Ascii" means a 1-to-8 * character string whose ascii representation is used as the key. */ - -#define KEY_TYPE_MD5 4 - int authusekey( keyid_t keyno, @@ -31,17 +28,8 @@ cp = str; len = strlen((const char *)cp); if (len == 0) - return 0; - - switch(keytype) { - case KEY_TYPE_MD5: - MD5auth_setkey(keyno, str, (int)strlen((const char *)str)); - break; - - default: - /* Oh, well */ return 0; - } + MD5auth_setkey(keyno, keytype, str, (int)strlen((const char *)str)); return 1; } diff -urN src/contrib/ntp/libntp/bsd_strerror.c src.ntp/contrib/ntp/libntp/bsd_strerror.c --- src/contrib/ntp/libntp/bsd_strerror.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/libntp/bsd_strerror.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,48 @@ +#include + +#if !HAVE_STRERROR +/* + * Copyright (c) 1988 Regents of the University of California. + * All rights reserved. + * + * Redistribution and use in source and binary forms are permitted + * provided that the above copyright notice and this paragraph are + * duplicated in all such forms and that any documentation, + * advertising materials, and other materials related to such + * distribution and use acknowledge that the software was developed + * by the University of California, Berkeley. The name of the + * University may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED + * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. + */ + +#if defined(LIBC_SCCS) && !defined(lint) +static const char sccsid[] = "@(#)strerror.c 5.1 (Berkeley) 4/9/89"; +#endif /* LIBC_SCCS and not lint */ + +#include + +#include +#include + +#include "l_stdlib.h" + +char * +strerror( + int errnum + ) +{ + extern int sys_nerr; + extern char *sys_errlist[]; + static char ebuf[20]; + + if ((unsigned int)errnum < sys_nerr) + return(sys_errlist[errnum]); + (void)sprintf(ebuf, "Unknown error: %d", errnum); + return(ebuf); +} +#else +int strerror_bs; +#endif diff -urN src/contrib/ntp/libntp/buftvtots.c src.ntp/contrib/ntp/libntp/buftvtots.c --- src/contrib/ntp/libntp/buftvtots.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/buftvtots.c 2009-12-09 08:36:35.000000000 +0100 @@ -11,6 +11,7 @@ #include "ntp_string.h" #include "ntp_unixtime.h" +#ifndef SYS_WINNT int buftvtots( const char *bufp, @@ -33,3 +34,20 @@ TVUTOTSF(tv.tv_usec, ts->l_uf); return 1; } +#else /* SYS_WINNT */ +/* + * Windows doesn't have the tty_clock line discipline, so + * don't look for a timestamp where there is none. + */ +int +buftvtots( + const char *bufp, + l_fp *ts + ) +{ + UNUSED_ARG(bufp); + UNUSED_ARG(ts); + + return 0; +} +#endif /* SYS_WINNT */ diff -urN src/contrib/ntp/libntp/caljulian.c src.ntp/contrib/ntp/libntp/caljulian.c --- src/contrib/ntp/libntp/caljulian.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/caljulian.c 2009-12-09 08:36:35.000000000 +0100 @@ -7,24 +7,25 @@ #include "ntp_calendar.h" #include "ntp_stdlib.h" #include "ntp_fp.h" +#include "ntp_unixtime.h" -#if 0 -/* - * calmonthtab - days-in-the-month table +#if !(defined(ISC_CHECK_ALL) || defined(ISC_CHECK_NONE) || \ + defined(ISC_CHECK_ENSURE) || defined(ISC_CHECK_INSIST) || \ + defined(ISC_CHECK_INVARIANT)) +# define ISC_CHECK_ALL +#endif + +#include "ntp_assert.h" + +#if 1 + +/* Updated 2008-11-10 Juergen Perlinger + * + * Make the conversion 2038-proof with proper NTP epoch unfolding and extended + * precision calculations. Though we should really get a 'time_t' with more + * than 32 bits at least until 2037, because the unfolding cannot work after + * the wrap of the 32-bit 'time_t'. */ -static u_short calmonthtab[11] = { - JAN, - FEB, - MAR, - APR, - MAY, - JUN, - JUL, - AUG, - SEP, - OCT, - NOV -}; void caljulian( @@ -32,89 +33,137 @@ register struct calendar *jt ) { - u_long ntp_day; - u_long minutes; + u_long saved_time = ntptime; + u_long ntp_day; /* days (since christian era or in year) */ + u_long n400; /* # of Gregorian cycles */ + u_long n100; /* # of normal centuries */ + u_long n4; /* # of 4-year cycles */ + u_long n1; /* # of years into a leap year cycle */ + u_long sclday; /* scaled days for month conversion */ + int leaps; /* # of leaps days in year */ + time_t now; /* current system time */ + u_int32 tmplo; /* double precision tmp value / lo part */ + int32 tmphi; /* double precision tmp value / hi part */ + + NTP_INSIST(NULL != jt); + + /* + * First we have to unfold the ntp time stamp around the current time + * to make sure we are in the right epoch. Also we we do *NOT* fold + * before the begin of the first NTP epoch, so we WILL have a + * non-negative time stamp afterwards. Though at the time of this + * writing (2008 A.D.) it would be really strange to have systems + * running with clock set to he 1960's or before... + * + * But's important to use a 32 bit max signed value -- LONG_MAX is 64 + * bit on a 64-bit system, and it will give wrong results. + */ + now = time(NULL); + tmplo = (u_int32)now; +#if ( SIZEOF_TIME_T > 4 ) + tmphi = (int32)(now >> 16 >> 16); +#else /* - * Absolute, zero-adjusted Christian era day, starting from the - * mythical day 12/1/1 BC + * Get the correct sign extension in the high part. + * (now >> 32) may not work correctly on every 32 bit + * system, e.g. it yields garbage under Win32/VC6. */ - u_long acez_day; - - u_long d400; /* Days into a Gregorian cycle */ - u_long d100; /* Days into a normal century */ - u_long d4; /* Days into a 4-year cycle */ - u_long n400; /* # of Gregorian cycles */ - u_long n100; /* # of normal centuries */ - u_long n4; /* # of 4-year cycles */ - u_long n1; /* # of years into a leap year */ - /* cycle */ + tmphi = (int32)(now >> 31); +#endif + + M_ADD(tmphi, tmplo, 0, ((1UL << 31)-1)); /* 32-bit max signed */ + M_ADD(tmphi, tmplo, 0, JAN_1970); + if ((ntptime > tmplo) && (tmphi > 0)) + --tmphi; + tmplo = ntptime; + + /* + * Now split into days and seconds-of-day, using the fact that + * SECSPERDAY (86400) == 675 * 128; we can get roughly 17000 years of + * time scale, using only 32-bit calculations. Some magic numbers here, + * sorry for that. (This could be streamlined for 64 bit machines, but + * is worth the trouble?) + */ + ntptime = tmplo & 127; /* save remainder bits */ + tmplo = (tmplo >> 7) | (tmphi << 25); + ntp_day = (u_int32)tmplo / 675; + ntptime += ((u_int32)tmplo % 675) << 7; + + /* some checks for the algorithm + * There's some 64-bit trouble out there: the original NTP time stamp + * had only 32 bits, so our calculation invariant only holds in 32 bits! + */ + NTP_ENSURE(ntptime < SECSPERDAY); + NTP_INVARIANT((u_int32)(ntptime + ntp_day * SECSPERDAY) == (u_int32)saved_time); /* * Do the easy stuff first: take care of hh:mm:ss, ignoring leap * seconds */ jt->second = (u_char)(ntptime % SECSPERMIN); - minutes = ntptime / SECSPERMIN; - jt->minute = (u_char)(minutes % MINSPERHR); - jt->hour = (u_char)((minutes / MINSPERHR) % HRSPERDAY); + ntptime /= SECSPERMIN; + jt->minute = (u_char)(ntptime % MINSPERHR); + ntptime /= MINSPERHR; + jt->hour = (u_char)(ntptime); + + /* check time invariants */ + NTP_ENSURE(jt->second < SECSPERMIN); + NTP_ENSURE(jt->minute < MINSPERHR); + NTP_ENSURE(jt->hour < HRSPERDAY); /* * Find the day past 1900/01/01 00:00 UTC */ - ntp_day = ntptime / SECSPERDAY; - acez_day = DAY_NTP_STARTS + ntp_day - 1; - n400 = acez_day/GREGORIAN_CYCLE_DAYS; - d400 = acez_day%GREGORIAN_CYCLE_DAYS; - n100 = d400 / GREGORIAN_NORMAL_CENTURY_DAYS; - d100 = d400 % GREGORIAN_NORMAL_CENTURY_DAYS; - n4 = d100 / GREGORIAN_NORMAL_LEAP_CYCLE_DAYS; - d4 = d100 % GREGORIAN_NORMAL_LEAP_CYCLE_DAYS; - n1 = d4 / DAYSPERYEAR; - - /* - * Calculate the year and year-of-day - */ - jt->yearday = (u_short)(1 + d4%DAYSPERYEAR); - jt->year = (u_short)(400*n400 + 100*n100 + n4*4 + n1); - - if (n100 == 4 || n1 == 4) - { - /* - * If the cycle year ever comes out to 4, it must be December 31st - * of a leap year. - */ - jt->month = 12; - jt->monthday = 31; - jt->yearday = 366; + ntp_day += DAY_NTP_STARTS - 1; /* convert to days in CE */ + n400 = ntp_day / GREGORIAN_CYCLE_DAYS; /* split off cycles */ + ntp_day %= GREGORIAN_CYCLE_DAYS; + n100 = ntp_day / GREGORIAN_NORMAL_CENTURY_DAYS; + ntp_day %= GREGORIAN_NORMAL_CENTURY_DAYS; + n4 = ntp_day / GREGORIAN_NORMAL_LEAP_CYCLE_DAYS; + ntp_day %= GREGORIAN_NORMAL_LEAP_CYCLE_DAYS; + n1 = ntp_day / DAYSPERYEAR; + ntp_day %= DAYSPERYEAR; /* now zero-based day-of-year */ + + NTP_ENSURE(ntp_day < 366); + + /* + * Calculate the year and day-of-year + */ + jt->year = (u_short)(400*n400 + 100*n100 + 4*n4 + n1); + + if ((n100 | n1) > 3) { + /* + * If the cycle year ever comes out to 4, it must be December + * 31st of a leap year. + */ + jt->month = 12; + jt->monthday = 31; + jt->yearday = 366; + } else { + /* + * The following code is according to the excellent book + * 'Calendrical Calculations' by Nachum Dershowitz and Edward + * Reingold. It converts the day-of-year into month and + * day-of-month, using a linear transformation with integer + * truncation. Magic numbers again, but they will not be used + * anywhere else. + */ + sclday = ntp_day * 7 + 217; + leaps = ((n1 == 3) && ((n4 != 24) || (n100 == 3))) ? 1 : 0; + if (ntp_day >= (u_long)(JAN + FEB + leaps)) + sclday += (2 - leaps) * 7; + ++jt->year; + jt->month = (u_char)(sclday / 214); + jt->monthday = (u_char)((sclday % 214) / 7 + 1); + jt->yearday = (u_short)(1 + ntp_day); } - else - { - /* - * Else, search forwards through the months to get the right month - * and date. - */ - int monthday; - - jt->year++; - monthday = jt->yearday; - - for (jt->month=0;jt->month<11; jt->month++) - { - int t; - t = monthday - calmonthtab[jt->month]; - if (jt->month == 1 && is_leapyear(jt->year)) - t--; - - if (t > 0) - monthday = t; - else - break; - } - jt->month++; - jt->monthday = (u_char) monthday; - } + /* check date invariants */ + NTP_ENSURE(1 <= jt->month && jt->month <= 12); + NTP_ENSURE(1 <= jt->monthday && jt->monthday <= 31); + NTP_ENSURE(1 <= jt->yearday && jt->yearday <= 366); } + #else /* Updated 2003-12-30 TMa @@ -132,8 +181,10 @@ ) { struct tm *tm; + NTP_REQUIRE(jt != NULL); tm = ntp2unix_tm(ntptime, 0); + NTP_INSIST(tm != NULL); jt->hour = (u_char) tm->tm_hour; jt->minute = (u_char) tm->tm_min; diff -urN src/contrib/ntp/libntp/caltontp.c src.ntp/contrib/ntp/libntp/caltontp.c --- src/contrib/ntp/libntp/caltontp.c 1999-12-09 14:01:09.000000000 +0100 +++ src.ntp/contrib/ntp/libntp/caltontp.c 2009-12-09 08:36:35.000000000 +0100 @@ -6,37 +6,100 @@ #include "ntp_types.h" #include "ntp_calendar.h" #include "ntp_stdlib.h" +#include "ntp_assert.h" +/* + * Juergen Perlinger, 2008-11-12 + * Add support for full calendar calculatios. If the day-of-year is provided + * (that is, not zero) it will be used instead of month and day-of-month; + * otherwise a full turn through the calendar calculations will be taken. + * + * I know that Harlan Stenn likes to see assertions in production code, and I + * agree there, but it would be a tricky thing here. The algorithm is quite + * capable of producing sensible answers even to seemingly weird inputs: the + * date -03-00, the 0.th March of the year, will be automtically + * treated as the last day of February, no matter whether the year is a leap + * year or not. So adding constraints is merely for the benefit of the callers, + * because the only thing we can check for consistency is our input, produced + * by somebody else. + * + * BTW: A total roundtrip using 'caljulian' would be a quite shaky thing: + * Because of the truncation of the NTP time stamp to 32 bits and the epoch + * unfolding around the current time done by 'caljulian' the roundtrip does + * *not* necessarily reproduce the input, especially if the time spec is more + * than 68 years off from the current time... + */ u_long caltontp( - register const struct calendar *jt + const struct calendar *jt ) { - u_long ace_days; /* absolute Christian Era days */ - u_long ntp_days; - int prior_years; - u_long ntp_time; - - /* - * First convert today's date to absolute days past 12/1/1 BC - */ - prior_years = jt->year-1; - ace_days = jt->yearday /* days this year */ - +(DAYSPERYEAR*prior_years) /* plus days in previous years */ - +(prior_years/4) /* plus prior years's leap days */ - -(prior_years/100) /* minus leapless century years */ - +(prior_years/400); /* plus leapful Gregorian yrs */ + ntp_u_int32_t days; /* full days in NTP epoch */ + ntp_u_int32_t years; /* complete ACE years before date */ + ntp_u_int32_t month; /* adjusted month for calendar */ + + NTP_INSIST(jt != NULL); - /* - * Subtract out 1/1/1900, the beginning of the NTP epoch - */ - ntp_days = ace_days - DAY_NTP_STARTS; + NTP_REQUIRE(jt->month <= 13); /* permit month 0..13! */ + NTP_REQUIRE(jt->monthday <= 32); + NTP_REQUIRE(jt->yearday <= 366); + NTP_REQUIRE(jt->hour <= 24); + NTP_REQUIRE(jt->minute <= MINSPERHR); + NTP_REQUIRE(jt->second <= SECSPERMIN); - /* - * Do the obvious: - */ - ntp_time = - ntp_days*SECSPERDAY+SECSPERMIN*(MINSPERHR*jt->hour + jt->minute); + /* + * First convert the date to fully elapsed days since NTP epoch. The + * expressions used here give us initially days since 0001-01-01, the + * beginning of the christian era in the proleptic gregorian calendar; + * they are rebased on-the-fly into days since beginning of the NTP + * epoch, 1900-01-01. + */ + if (jt->yearday) { + /* + * Assume that the day-of-year contains a useable value and + * avoid all calculations involving month and day-of-month. + */ + years = jt->year - 1; + days = years * DAYSPERYEAR /* days in previous years */ + + years / 4 /* plus prior years's leap days */ + - years / 100 /* minus leapless century years */ + + years / 400 /* plus leapful Gregorian yrs */ + + jt->yearday /* days this year */ + - DAY_NTP_STARTS; /* rebase to NTP epoch */ + } else { + /* + * The following code is according to the excellent book + * 'Calendrical Calculations' by Nachum Dershowitz and Edward + * Reingold. It does a full calendar evaluation, using one of + * the alternate algorithms: Shift to a hypothetical year + * starting on the previous march,1st; merge years, month and + * days; undo the the 9 month shift (which is 306 days). The + * advantage is that we do NOT need to now whether a year is a + * leap year or not, because the leap day is the LAST day of + * the year. + */ + month = (ntp_u_int32_t)jt->month + 9; + years = jt->year - 1 + month / 12; + month %= 12; + days = years * DAYSPERYEAR /* days in previous years */ + + years / 4 /* plus prior years's leap days */ + - years / 100 /* minus leapless century years */ + + years / 400 /* plus leapful Gregorian yrs */ + + (month * 153 + 2) / 5 /* plus days before month */ + + jt->monthday /* plus day-of-month */ + - 306 /* minus 9 months */ + - DAY_NTP_STARTS; /* rebase to NTP epoch */ + } - return ntp_time; + /* + * Do the obvious: Merge everything together, making sure integer + * promotion doesn't play dirty tricks on us; there is probably some + * redundancy in the casts, but this drives it home with force. All + * arithmetic is done modulo 2**32, because the result is truncated + * anyway. + */ + return days * SECSPERDAY + + (ntp_u_int32_t)jt->hour * MINSPERHR*SECSPERMIN + + (ntp_u_int32_t)jt->minute * SECSPERMIN + + (ntp_u_int32_t)jt->second; } diff -urN src/contrib/ntp/libntp/calyearstart.c src.ntp/contrib/ntp/libntp/calyearstart.c --- src/contrib/ntp/libntp/calyearstart.c 1999-12-09 14:01:09.000000000 +0100 +++ src.ntp/contrib/ntp/libntp/calyearstart.c 2009-12-09 08:36:35.000000000 +0100 @@ -7,16 +7,50 @@ #include "ntp_types.h" #include "ntp_calendar.h" #include "ntp_stdlib.h" +#include "ntp_assert.h" +/* + * Juergen Perlinger, 2008-11-12 + * Use the result of 'caljulian' to get the delta from the time stamp to the + * beginning of the year. Do not make a second trip through 'caltontp' after + * fixing the date, apart for invariant tests. + */ u_long calyearstart(u_long ntp_time) { - struct calendar jt; + struct calendar jt; + ntp_u_int32_t delta; - caljulian(ntp_time,&jt); - jt.yearday = 1; - jt.monthday = 1; - jt.month = 1; - jt.hour = jt.minute = jt.second = 0; - return caltontp(&jt); + caljulian(ntp_time,&jt); + + /* + * Now we have days since yearstart (unity-based) and the time in that + * day. Simply merge these together to seconds and subtract that from + * input time. That's faster than going through the calendar stuff + * again... + */ + delta = (ntp_u_int32_t)jt.yearday * SECSPERDAY + + (ntp_u_int32_t)jt.hour * MINSPERHR * SECSPERMIN + + (ntp_u_int32_t)jt.minute * SECSPERMIN + + (ntp_u_int32_t)jt.second + - SECSPERDAY; /* yearday is unity-based... */ + +# if ISC_CHECK_INVARIANT + /* + * check that this computes properly: do a roundtrip! That's the only + * sensible test here, but it's a rather expensive invariant... + */ + jt.yearday = 0; + jt.month = 1; + jt.monthday = 1; + jt.hour = 0; + jt.minute = 0; + jt.second = 0; + NTP_INVARIANT((ntp_u_int32_t)(caltontp(&jt) + delta) == (ntp_u_int32_t)ntp_time); +# endif + + /* The NTP time stamps (l_fp) count seconds unsigned mod 2**32, so we + * have to calculate this in the proper way! + */ + return (ntp_u_int32_t)(ntp_time - delta); } diff -urN src/contrib/ntp/libntp/clocktypes.c src.ntp/contrib/ntp/libntp/clocktypes.c --- src/contrib/ntp/libntp/clocktypes.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/clocktypes.c 2009-12-09 08:36:37.000000000 +0100 @@ -68,8 +68,8 @@ "MSF_ARCRON" }, { REFCLK_SHM, "Clock attached thru shared Memory (28)", "SHM" }, - { REFCLK_PALISADE, "Trimble Navigation Palisade GPS (29)", - "GPS_PALISADE" }, + { REFCLK_PALISADE, "Trimble Navigation Palisade GPS (29)", + "GPS_PALISADE" }, { REFCLK_ONCORE, "Motorola UT Oncore GPS (30)", "GPS_ONCORE" }, { REFCLK_GPS_JUPITER, "Rockwell Jupiter GPS (31)", @@ -78,7 +78,7 @@ "CHRONOLOG" }, { REFCLK_DUMBCLOCK, "Dumb generic hh:mm:ss local clock (33)", "DUMBCLOCK" }, - { REFCLK_ULINK, "Ultralink M320 WWVB receiver (34)", + { REFCLK_ULINK, "Ultralink M320 WWVB receiver (34)", "ULINK_M320"}, { REFCLK_PCF, "Conrad parallel port radio clock (35)", "PCF"}, @@ -112,7 +112,7 @@ for (clk = clktypes; clk->code != -1; clk++) { if (num == clk->code) - return (clk->abbrev); + return (clk->abbrev); } return (NULL); } diff -urN src/contrib/ntp/libntp/decodenetnum.c src.ntp/contrib/ntp/libntp/decodenetnum.c --- src/contrib/ntp/libntp/decodenetnum.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/decodenetnum.c 2009-12-09 08:36:35.000000000 +0100 @@ -1,39 +1,50 @@ /* * decodenetnum - return a net number (this is crude, but careful) */ +#include #include #include +#ifdef HAVE_SYS_SOCKET_H #include +#endif +#ifdef HAVE_NETINET_IN_H #include +#endif #include "ntp_stdlib.h" +#include "ntp_assert.h" int decodenetnum( const char *num, - struct sockaddr_storage *netnum + sockaddr_u *netnum ) { struct addrinfo hints, *ai = NULL; - register int err, i; + register int err; register const char *cp; char name[80]; + char *np; - cp = num; + NTP_REQUIRE(num != NULL); + NTP_REQUIRE(strlen(num) < sizeof(name)); - if (*cp == '[') { - cp++; - for (i = 0; *cp != ']'; cp++, i++) - name[i] = *cp; - name[i] = '\0'; - num = name; + if ('[' != num[0]) + cp = num; + else { + cp = num + 1; + np = name; + while (*cp && ']' != *cp) + *np++ = *cp++; + *np = 0; + cp = name; } - memset(&hints, 0, sizeof(struct addrinfo)); + memset(&hints, 0, sizeof(hints)); hints.ai_flags = AI_NUMERICHOST; - err = getaddrinfo(num, NULL, &hints, &ai); + err = getaddrinfo(cp, NULL, &hints, &ai); if (err != 0) return 0; - memcpy(netnum, (struct sockaddr_storage *)ai->ai_addr, ai->ai_addrlen); + memcpy(netnum, ai->ai_addr, ai->ai_addrlen); freeaddrinfo(ai); return 1; } diff -urN src/contrib/ntp/libntp/emalloc.c src.ntp/contrib/ntp/libntp/emalloc.c --- src/contrib/ntp/libntp/emalloc.c 2001-08-29 16:35:11.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/emalloc.c 2009-12-09 08:36:35.000000000 +0100 @@ -6,43 +6,117 @@ #include "ntp_syslog.h" #include "ntp_stdlib.h" -#if defined SYS_WINNT && defined DEBUG -#include -#endif +extern char *progname; + +#if !defined(_MSC_VER) || !defined(_DEBUG) -#if defined SYS_WINNT && defined DEBUG void * -debug_emalloc( - u_int size, - char *filename, - int line +erealloc( + void * prev, + size_t size ) { - char *mem; + void * mem; + + mem = realloc(prev, size ? size : 1); - if ((mem = (char *)_malloc_dbg(size, _NORMAL_BLOCK, filename, line)) == 0) { - msyslog(LOG_ERR, "Exiting: No more memory!"); + if (NULL == mem) { + msyslog(LOG_ERR, + "fatal out of memory (%u bytes)", (u_int)size); + fprintf(stderr, + "%s: fatal out of memory (%u bytes)", progname, + (u_int)size); exit(1); } + return mem; } -#else void * emalloc( - u_int size + size_t size + ) +{ + return erealloc(NULL, size); +} + + +char * +estrdup( + const char * str ) { - char *mem; + char * copy; + + copy = strdup(str); - if ((mem = (char *)malloc(size)) == 0) { - msyslog(LOG_ERR, "Exiting: No more memory!"); + if (NULL == copy) { + msyslog(LOG_ERR, + "fatal out of memory duplicating %u bytes", + (u_int)strlen(str) + 1); + fprintf(stderr, + "%s: fatal out of memory duplicating %u bytes", + progname, (u_int)strlen(str) + 1); exit(1); } + + return copy; +} + +#else /* below is _MSC_VER && _DEBUG */ + +/* + * When using the debug MS CRT allocator, each allocation stores the + * callsite __FILE__ and __LINE__, which is then displayed at process + * termination, to track down leaks. We don't want all of our + * allocations to show up as coming from emalloc.c, so we preserve the + * original callsite's source file and line using macros which pass + * __FILE__ and __LINE__ as parameters to these routines. + */ + +void * +debug_erealloc( + void * prev, + size_t size, + const char * file, /* __FILE__ */ + int line /* __LINE__ */ + ) +{ + void * mem; + + mem = _realloc_dbg(prev, size ? size : 1, + _NORMAL_BLOCK, file, line); + + if (NULL == mem) { + msyslog(LOG_ERR, + "fatal: out of memory in %s line %d size %u", + file, line, (u_int)size); + fprintf(stderr, + "%s: fatal: out of memory in %s line %d size %u", + progname, file, line, (u_int)size); + exit(1); + } + return mem; } +char * +debug_estrdup( + const char * str, + const char * file, /* __FILE__ */ + int line /* __LINE__ */ + ) +{ + char * copy; + size_t bytes; + + bytes = strlen(str) + 1; + copy = debug_erealloc(NULL, bytes, file, line); + memcpy(copy, str, bytes); + + return copy; +} -#endif +#endif /* _MSC_VER && _DEBUG */ diff -urN src/contrib/ntp/libntp/findconfig.c src.ntp/contrib/ntp/libntp/findconfig.c --- src/contrib/ntp/libntp/findconfig.c 1999-12-09 14:01:09.000000000 +0100 +++ src.ntp/contrib/ntp/libntp/findconfig.c 2010-02-04 08:26:58.000000000 +0100 @@ -28,7 +28,7 @@ /* First choice is my hostname */ if (gethostname(hostname, BUFSIZ) >= 0) { - (void) sprintf(result, "%s/%s", base, hostname); + snprintf(result, sizeof(result), "%s/%s", base, hostname); if (stat(result, &sbuf) == 0) { goto outahere; } else { @@ -39,13 +39,13 @@ cp = unamebuf.machine + 5; else cp = unamebuf.machine; - (void) sprintf(result, "%s/default.%s", base, cp); + snprintf(result, sizeof(result), "%s/default.%s", base, cp); if (stat(result, &sbuf) == 0) { goto outahere; } else { /* Last choice is just default */ - (void) sprintf(result, "%s/default", base); + snprintf(result, sizeof(result), "%s/default", base); if (stat(result, &sbuf) == 0) { goto outahere; } else { diff -urN src/contrib/ntp/libntp/hextoint.c src.ntp/contrib/ntp/libntp/hextoint.c --- src/contrib/ntp/libntp/hextoint.c 1999-12-09 14:01:09.000000000 +0100 +++ src.ntp/contrib/ntp/libntp/hextoint.c 2009-12-09 08:36:35.000000000 +0100 @@ -9,7 +9,7 @@ int hextoint( const char *str, - u_long *ival + u_long *pu ) { register u_long u; @@ -18,22 +18,24 @@ cp = str; if (*cp == '\0') - return 0; + return 0; u = 0; while (*cp != '\0') { - if (!isxdigit((int)*cp)) - return 0; - if (u >= 0x10000000) - return 0; /* overflow */ + if (!isxdigit(*cp)) + return 0; + if (u & 0xF0000000) + return 0; /* overflow */ u <<= 4; - if (*cp <= '9') /* very ascii dependent */ - u += *cp++ - '0'; - else if (*cp >= 'a') - u += *cp++ - 'a' + 10; + if ('0' <= *cp && *cp <= '9') + u += *cp++ - '0'; + else if ('a' <= *cp && *cp <= 'f') + u += *cp++ - 'a' + 10; + else if ('A' <= *cp && *cp <= 'F') + u += *cp++ - 'A' + 10; else - u += *cp++ - 'A' + 10; + return 0; } - *ival = u; + *pu = u; return 1; } diff -urN src/contrib/ntp/libntp/humandate.c src.ntp/contrib/ntp/libntp/humandate.c --- src/contrib/ntp/libntp/humandate.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/humandate.c 2010-02-04 08:26:54.000000000 +0100 @@ -7,36 +7,7 @@ #include "lib_strbuf.h" #include "ntp_stdlib.h" -static const char *months[] = { - "Jan", "Feb", "Mar", "Apr", "May", "Jun", - "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" -}; -static const char *days[] = { - "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" -}; - -char * -humandate( - u_long ntptime - ) -{ - char *bp; - struct tm *tm; - - tm = ntp2unix_tm(ntptime, 1); - - if (!tm) - return "--- --- -- ---- --:--:--"; - - LIB_GETBUF(bp); - - (void) sprintf(bp, "%s, %s %2d %4d %2d:%02d:%02d", - days[tm->tm_wday], months[tm->tm_mon], tm->tm_mday, - 1900+tm->tm_year, tm->tm_hour, tm->tm_min, tm->tm_sec); - - return bp; -} - +extern const char *months[]; /* prettydate.c */ /* This is used in msyslog.c; we don't want to clutter up the log with the year and day of the week, etc.; just the minimal date and time. */ @@ -44,19 +15,20 @@ char * humanlogtime(void) { - char *bp; - time_t cursec = time((time_t *) 0); - struct tm *tm; + char * bp; + time_t cursec; + struct tm * tm; + cursec = time(NULL); tm = localtime(&cursec); if (!tm) return "-- --- --:--:--"; LIB_GETBUF(bp); - (void) sprintf(bp, "%2d %s %02d:%02d:%02d", - tm->tm_mday, months[tm->tm_mon], - tm->tm_hour, tm->tm_min, tm->tm_sec); + snprintf(bp, LIB_BUFLENGTH, "%2d %s %02d:%02d:%02d", + tm->tm_mday, months[tm->tm_mon], + tm->tm_hour, tm->tm_min, tm->tm_sec); return bp; } diff -urN src/contrib/ntp/libntp/icom.c src.ntp/contrib/ntp/libntp/icom.c --- src/contrib/ntp/libntp/icom.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/icom.c 2009-12-09 08:36:37.000000000 +0100 @@ -15,33 +15,40 @@ #include "l_stdlib.h" /* - * Scraps + * Packet routines + * + * These routines send a packet and receive the response. If an error + * (collision) occurs on transmit, the packet is resent. If an error + * occurs on receive (timeout), all input to the terminating FI is + * discarded and the packet is resent. If the maximum number of retries + * is not exceeded, the program returns the number of octets in the user + * buffer; otherwise, it returns zero. + * + * ICOM frame format + * + * Frames begin with a two-octet preamble PR-PR followyd by the + * transceiver address RE, controller address TX, control code CN, zero + * or more data octets DA (depending on command), and terminator FI. + * Since the bus is bidirectional, every octet output is echoed on + * input. Every valid frame sent is answered with a frame in the same + * format, but with the RE and TX fields interchanged. The CN field is + * set to NAK if an error has occurred. Otherwise, the data are returned + * in this and following DA octets. If no data are returned, the CN + * octet is set to ACK. + * + * +------+------+------+------+------+--//--+------+ + * | PR | PR | RE | TX | CN | DA | FI | + * +------+------+------+------+------+--//--+------+ */ -#define BMAX 50 /* max command length */ -#define DICOM /dev/icom/ /* ICOM port link */ - /* - * FSA definitions + * Scraps */ -#define S_IDLE 0 /* idle */ -#define S_HDR 1 /* header */ -#define S_TX 2 /* address */ -#define S_DATA 3 /* data */ -#define S_ERROR 4 /* error */ +#define DICOM /dev/icom/ /* ICOM port link */ /* * Local function prototypes */ -static void doublefreq P((double, u_char *, int)); -static int sndpkt P((int, int, u_char *, u_char *)); -static int sndoctet P((int, int)); -static int rcvoctet P((int)); - -/* - * Local variables - */ -static int flags; /* trace flags */ -static int state; /* fsa state */ +static void doublefreq (double, u_char *, int); /* @@ -54,17 +61,16 @@ double freq /* frequency (MHz) */ ) { - u_char cmd[BMAX], rsp[BMAX]; + u_char cmd[] = {PAD, PR, PR, 0, TX, V_SFREQ, 0, 0, 0, 0, FI, + FI}; int temp; - cmd[0] = V_SFREQ; + cmd[3] = ident; if (ident == IC735) temp = 4; else temp = 5; - doublefreq(freq * 1e6, &cmd[1], temp); - temp = sndpkt(fd, ident, cmd, rsp); - if (temp < 1 || rsp[0] != ACK) - return (EIO); + doublefreq(freq * 1e6, &cmd[6], temp); + temp = write(fd, cmd, temp + 7); return (0); } @@ -96,33 +102,6 @@ x[i] = FI; } - -/* - * Packet routines - * - * These routines send a packet and receive the response. If an error - * (collision) occurs on transmit, the packet is resent. If an error - * occurs on receive (timeout), all input to the terminating FI is - * discarded and the packet is resent. If the maximum number of retries - * is not exceeded, the program returns the number of octets in the user - * buffer; otherwise, it returns zero. - * - * ICOM frame format - * - * Frames begin with a two-octet preamble PR-PR followyd by the - * transceiver address RE, controller address TX, control code CN, zero - * or more data octets DA (depending on command), and terminator FI. - * Since the bus is bidirectional, every octet output is echoed on - * input. Every valid frame sent is answered with a frame in the same - * format, but with the RE and TX fields interchanged. The CN field is - * set to NAK if an error has occurred. Otherwise, the data are returned - * in this and following DA octets. If no data are returned, the CN - * octet is set to ACK. - * - * +------+------+------+------+------+--//--+------+ - * | PR | PR | RE | TX | CN | DA | FI | - * +------+------+------+------+------+--//--+------+ - */ /* * icom_open() - open and initialize serial interface * @@ -138,7 +117,7 @@ int trace /* trace flags */ ) { TTY ttyb; - int fd; + int fd, flags; flags = trace; fd = open(device, O_RDWR, 0777); @@ -148,7 +127,7 @@ tcgetattr(fd, &ttyb); ttyb.c_iflag = 0; /* input modes */ ttyb.c_oflag = 0; /* output modes */ - ttyb.c_cflag = IBAUD|CS8|CREAD|CLOCAL; /* control modes */ + ttyb.c_cflag = IBAUD|CS8|CLOCAL; /* control modes (no read) */ ttyb.c_lflag = 0; /* local modes */ ttyb.c_cc[VMIN] = 0; /* min chars */ ttyb.c_cc[VTIME] = 5; /* receive timeout */ @@ -158,168 +137,4 @@ return (fd); } - -/* - * sndpkt(r, x, y) - send packet and receive response - * - * This routine sends a command frame, which consists of all except the - * preamble octets PR-PR. It then listens for the response frame and - * returns the payload to the caller. The routine checks for correct - * response header format; that is, the length of the response vector - * returned to the caller must be at least 2 and the RE and TX octets - * must be interchanged; otherwise, the operation is retried up to - * the number of times specified in a global variable. - * - * The trace function, which is enabled by the P_TRACE bit of the global - * flags variable, prints all characters received or echoed on the bus - * preceded by a T (transmit) or R (receive). The P_ERMSG bit of the - * flags variable enables printing of bus error messages. - * - * Note that the first octet sent is a PAD in order to allow time for - * the radio to flush its receive buffer after sending the previous - * response. Even with this precaution, some of the older radios - * occasionally fail to receive a command and it has to be sent again. - */ -static int -sndpkt( /* returns octet count */ - int fd, /* file descriptor */ - int r, /* radio address */ - u_char *cmd, /* command vector */ - u_char *rsp /* response vector */ - ) -{ - int i, j, temp; - - (void)tcflush(fd, TCIOFLUSH); - for (i = 0; i < RETRY; i++) { - state = S_IDLE; - - /* - * Transmit packet. - */ - if (flags & P_TRACE) - printf("icom T:"); - sndoctet(fd, PAD); /* send header */ - sndoctet(fd, PR); - sndoctet(fd, PR); - sndoctet(fd, r); - sndoctet(fd, TX); - for (j = 0; j < BMAX; j++) { /* send body */ - if (sndoctet(fd, cmd[j]) == FI) - break; - } - while (rcvoctet(fd) != FI); /* purge echos */ - if (cmd[0] == V_FREQT || cmd[0] == V_MODET) - return (0); /* shortcut for broadcast */ - - /* - * Receive packet. First, delete all characters - * preceeding a PR, then discard all PRs. Check that the - * RE and TX fields are correctly interchanged, then - * copy the remaining data and FI to the user buffer. - */ - if (flags & P_TRACE) - printf("\nicom R:"); - j = 0; - while ((temp = rcvoctet(fd)) != FI) { - switch (state) { - - case S_IDLE: - if (temp != PR) - continue; - state = S_HDR; - break; - - case S_HDR: - if (temp == PR) { - continue; - } else if (temp != TX) { - if (flags & P_ERMSG) - printf( - "icom: TX error\n"); - state = S_ERROR; - } - state = S_TX; - break; - - case S_TX: - if (temp != r) { - if (flags & P_ERMSG) - printf( - "icom: RE error\n"); - state = S_ERROR; - } - state = S_DATA; - break; - - case S_DATA: - if (j >= BMAX ) { - if (flags & P_ERMSG) - printf( - "icom: buffer overrun\n"); - state = S_ERROR; - j = 0; - } - rsp[j++] = (u_char)temp; - break; - - case S_ERROR: - break; - } - } - if (flags & P_TRACE) - printf("\n"); - if (j > 0) { - rsp[j++] = FI; - return (j); - } - } - if (flags & P_ERMSG) - printf("icom: retries exceeded\n"); - return (0); -} - - -/* - * Interface routines - * - * These routines read and write octets on the bus. In case of receive - * timeout a FI code is returned. In case of output collision (echo - * does not match octet sent), the remainder of the collision frame - * (including the trailing FI) is discarded. - */ -/* - * sndoctet(fd, x) - send octet - */ -static int -sndoctet( /* returns octet */ - int fd, /* file descriptor */ - int x /* octet */ - ) -{ - u_char y; - - y = (u_char)x; - write(fd, &y, 1); - return (x); -} - - -/* - * rcvoctet(fd) - receive octet - */ -static int -rcvoctet( /* returns octet */ - int fd /* file descriptor */ - ) -{ - u_char y; - - if (read(fd, &y, 1) < 1) - y = FI; /* come here if timeout */ - if (flags & P_TRACE && y != PAD) - printf(" %02x", y); - return (y); -} - /* end program */ diff -urN src/contrib/ntp/libntp/inttoa.c src.ntp/contrib/ntp/libntp/inttoa.c --- src/contrib/ntp/libntp/inttoa.c 1999-12-09 14:01:09.000000000 +0100 +++ src.ntp/contrib/ntp/libntp/inttoa.c 2010-06-19 08:40:31.000000000 +0200 @@ -1,6 +1,7 @@ /* * inttoa - return an asciized signed integer */ +#include #include #include "lib_strbuf.h" @@ -8,13 +9,13 @@ char * inttoa( - long ival + long val ) { register char *buf; LIB_GETBUF(buf); + snprintf(buf, LIB_BUFLENGTH, "%ld", val); - (void) sprintf(buf, "%ld", (long)ival); return buf; } diff -urN src/contrib/ntp/libntp/iosignal.c src.ntp/contrib/ntp/libntp/iosignal.c --- src/contrib/ntp/libntp/iosignal.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/iosignal.c 2009-12-09 08:36:35.000000000 +0100 @@ -59,7 +59,7 @@ */ static int sigio_handler_active = 0; # endif -extern void input_handler P((l_fp *)); +extern void input_handler (l_fp *); /* * SIGPOLL and SIGIO ROUTINES. diff -urN src/contrib/ntp/libntp/lib_strbuf.c src.ntp/contrib/ntp/libntp/lib_strbuf.c --- src/contrib/ntp/libntp/lib_strbuf.c 2001-08-29 16:35:11.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/lib_strbuf.c 2009-12-09 08:36:35.000000000 +0100 @@ -1,7 +1,12 @@ /* * lib_strbuf - library string storage */ +#ifdef HAVE_CONFIG_H +#include +#endif +#include +#include #include "ntp_stdlib.h" #include "lib_strbuf.h" @@ -10,6 +15,8 @@ */ char lib_stringbuf[LIB_NUMBUFS][LIB_BUFLENGTH]; int lib_nextbuf; +int ipv4_works; +int ipv6_works; int lib_inited = 0; /* @@ -19,5 +26,7 @@ init_lib(void) { lib_nextbuf = 0; + ipv4_works = (ISC_R_SUCCESS == isc_net_probeipv4()); + ipv6_works = (ISC_R_SUCCESS == isc_net_probeipv6()); lib_inited = 1; } diff -urN src/contrib/ntp/libntp/lib_strbuf.h src.ntp/contrib/ntp/libntp/lib_strbuf.h --- src/contrib/ntp/libntp/lib_strbuf.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/lib_strbuf.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,28 +0,0 @@ -/* - * lib_strbuf.h - definitions for routines which use the common string buffers - */ - -#include - -/* - * Sizes of things - */ -#define LIB_NUMBUFS 200 -#define LIB_BUFLENGTH 80 - -/* - * Macro to get a pointer to the next buffer - */ -#define LIB_GETBUF(buf) \ - do { \ - if (!lib_inited) \ - init_lib(); \ - buf = &lib_stringbuf[lib_nextbuf][0]; \ - if (++lib_nextbuf >= LIB_NUMBUFS) \ - lib_nextbuf = 0; \ - memset(buf, 0, LIB_BUFLENGTH); \ - } while (0) - -extern char lib_stringbuf[LIB_NUMBUFS][LIB_BUFLENGTH]; -extern int lib_nextbuf; -extern int lib_inited; diff -urN src/contrib/ntp/libntp/machines.c src.ntp/contrib/ntp/libntp/machines.c --- src/contrib/ntp/libntp/machines.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/machines.c 2009-12-09 08:36:37.000000000 +0100 @@ -12,6 +12,7 @@ #include "ntp_syslog.h" #include "ntp_stdlib.h" #include "ntp_unixtime.h" +#include "lib_strbuf.h" #ifdef HAVE_UNISTD_H #include @@ -409,7 +410,20 @@ } #endif /* MPE */ -const char *set_tod_using = "UNKNOWN"; +#define SET_TOD_UNDETERMINED 0 +#define SET_TOD_CLOCK_SETTIME 1 +#define SET_TOD_SETTIMEOFDAY 2 +#define SET_TOD_STIME 3 + +const char * const set_tod_used[] = { + "undetermined", + "clock_settime", + "settimeofday", + "stime" +}; + +pset_tod_using set_tod_using = NULL; + int ntp_set_tod( @@ -417,7 +431,9 @@ void *tzp ) { + static int tod; int rc = -1; + int saved_errno = 0; #ifdef DEBUG if (debug) @@ -425,29 +441,31 @@ #endif #ifdef HAVE_CLOCK_SETTIME - if (rc) { + if (rc && (SET_TOD_CLOCK_SETTIME == tod || !tod)) { struct timespec ts; - set_tod_using = "clock_settime"; /* Convert timeval to timespec */ ts.tv_sec = tvp->tv_sec; ts.tv_nsec = 1000 * tvp->tv_usec; errno = 0; rc = clock_settime(CLOCK_REALTIME, &ts); + saved_errno = errno; #ifdef DEBUG if (debug) { - printf("ntp_set_tod: %s: %d: %s\n", - set_tod_using, rc, strerror(errno)); + printf("ntp_set_tod: clock_settime: %d: %s\n", + rc, strerror(saved_errno)); } #endif + if (!tod && !rc) + tod = SET_TOD_CLOCK_SETTIME; + } #endif /* HAVE_CLOCK_SETTIME */ #ifdef HAVE_SETTIMEOFDAY - if (rc) { + if (rc && (SET_TOD_SETTIMEOFDAY == tod || !tod)) { struct timeval adjtv; - set_tod_using = "settimeofday"; /* * Some broken systems don't reset adjtime() when the * clock is stepped. @@ -456,37 +474,52 @@ adjtime(&adjtv, NULL); errno = 0; rc = SETTIMEOFDAY(tvp, tzp); + saved_errno = errno; #ifdef DEBUG if (debug) { - printf("ntp_set_tod: %s: %d: %s\n", - set_tod_using, rc, strerror(errno)); + printf("ntp_set_tod: settimeofday: %d: %s\n", + rc, strerror(saved_errno)); } #endif + if (!tod && !rc) + tod = SET_TOD_SETTIMEOFDAY; } #endif /* HAVE_SETTIMEOFDAY */ #ifdef HAVE_STIME - if (rc) { + if (rc && (SET_TOD_STIME == tod || !tod)) { long tp = tvp->tv_sec; - set_tod_using = "stime"; errno = 0; rc = stime(&tp); /* lie as bad as SysVR4 */ + saved_errno = errno; #ifdef DEBUG if (debug) { - printf("ntp_set_tod: %s: %d: %s\n", - set_tod_using, rc, strerror(errno)); + printf("ntp_set_tod: stime: %d: %s\n", + rc, strerror(saved_errno)); } #endif + if (!tod && !rc) + tod = SET_TOD_STIME; } #endif /* HAVE_STIME */ - if (rc) - set_tod_using = "Failed!"; + #ifdef DEBUG if (debug) { printf("ntp_set_tod: Final result: %s: %d: %s\n", - set_tod_using, rc, strerror(errno)); + set_tod_used[tod], rc, strerror(saved_errno)); } #endif + /* + * Say how we're setting the time of day + */ + if (!rc && NULL != set_tod_using) { + (*set_tod_using)(set_tod_used[tod]); + set_tod_using = NULL; + } + + if (rc) + errno = saved_errno; + return rc; } @@ -509,6 +542,9 @@ } password[i] = '\0'; + fputc('\n', stderr); + fflush(stderr); + return password; } #endif /* SYS_WINNT */ diff -urN src/contrib/ntp/libntp/md5c.c src.ntp/contrib/ntp/libntp/md5c.c --- src/contrib/ntp/libntp/md5c.c 2004-07-20 17:01:21.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/md5c.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,354 +0,0 @@ -/* MD5C.C - RSA Data Security, Inc., MD5 message-digest algorithm - */ - -/* Copyright (C) 1991-2, RSA Data Security, Inc. Created 1991. All - rights reserved. - - License to copy and use this software is granted provided that it - is identified as the "RSA Data Security, Inc. MD5 Message-Digest - Algorithm" in all material mentioning or referencing this software - or this function. - - License is also granted to make and use derivative works provided - that such works are identified as "derived from the RSA Data - Security, Inc. MD5 Message-Digest Algorithm" in all material - mentioning or referencing the derived work. - - RSA Data Security, Inc. makes no representations concerning either - the merchantability of this software or the suitability of this - software for any particular purpose. It is provided "as is" - without express or implied warranty of any kind. - - These notices must be retained in any copies of any part of this - documentation and/or software. - */ - -#include "global.h" -#ifndef HAVE_MD5INIT -#include "ntp_md5.h" - -/* Constants for MD5Transform routine. - */ -#define S11 7 -#define S12 12 -#define S13 17 -#define S14 22 -#define S21 5 -#define S22 9 -#define S23 14 -#define S24 20 -#define S31 4 -#define S32 11 -#define S33 16 -#define S34 23 -#define S41 6 -#define S42 10 -#define S43 15 -#define S44 21 - -static void MD5Transform PROTO_LIST ((UINT4 [4], unsigned char [64])); -static void Encode PROTO_LIST - ((unsigned char *, UINT4 *, unsigned int)); -static void Decode PROTO_LIST - ((UINT4 *, unsigned char *, unsigned int)); -static void MD5_memcpy PROTO_LIST ((POINTER, POINTER, unsigned int)); -static void MD5_memset PROTO_LIST ((POINTER, int, unsigned int)); - -static unsigned char PADDING[64] = { - 0x80, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 -}; - -/* F, G, H and I are basic MD5 functions. - */ -#define F(x, y, z) (((x) & (y)) | ((~x) & (z))) -#define G(x, y, z) (((x) & (z)) | ((y) & (~z))) -#define H(x, y, z) ((x) ^ (y) ^ (z)) -#define I(x, y, z) ((y) ^ ((x) | (~z))) - -/* ROTATE_LEFT rotates x left n bits. - */ -#define ROTATE_LEFT(x, n) (((x) << (n)) | ((x) >> (32-(n)))) - -/* FF, GG, HH, and II transformations for rounds 1, 2, 3, and 4. - Rotation is separate from addition to prevent recomputation. - */ -#define FF(a, b, c, d, x, s, ac) { \ - (a) += F ((b), (c), (d)) + (x) + (UINT4)(ac); \ - (a) = ROTATE_LEFT ((a), (s)); \ - (a) += (b); \ - } -#define GG(a, b, c, d, x, s, ac) { \ - (a) += G ((b), (c), (d)) + (x) + (UINT4)(ac); \ - (a) = ROTATE_LEFT ((a), (s)); \ - (a) += (b); \ - } -#define HH(a, b, c, d, x, s, ac) { \ - (a) += H ((b), (c), (d)) + (x) + (UINT4)(ac); \ - (a) = ROTATE_LEFT ((a), (s)); \ - (a) += (b); \ - } -#define II(a, b, c, d, x, s, ac) { \ - (a) += I ((b), (c), (d)) + (x) + (UINT4)(ac); \ - (a) = ROTATE_LEFT ((a), (s)); \ - (a) += (b); \ - } - -/* MD5 initialization. Begins an MD5 operation, writing a new context. - */ -void -MD5Init( - MD5_CTX *context /* context */ - ) -{ - context->count[0] = context->count[1] = 0; - - /* Load magic initialization constants. - */ - context->state[0] = 0x67452301; - context->state[1] = 0xefcdab89; - context->state[2] = 0x98badcfe; - context->state[3] = 0x10325476; -} - -/* MD5 block update operation. Continues an MD5 message-digest - operation, processing another message block, and updating the - context. - */ -void -MD5Update ( - MD5_CTX *context, /* context */ - unsigned char *input, /* input block */ - unsigned int inputLen /* length of input block */ - ) -{ - unsigned int i, idx, partLen; - - /* Compute number of bytes mod 64 */ - idx = (unsigned int)((context->count[0] >> 3) & 0x3F); - - /* Update number of bits */ - if ((context->count[0] += ((UINT4)inputLen << 3)) - < ((UINT4)inputLen << 3)) - context->count[1]++; - context->count[1] += ((UINT4)inputLen >> 29); - - partLen = 64 - idx; - - /* Transform as many times as possible. - */ - if (inputLen >= partLen) { - MD5_memcpy - ((POINTER)&context->buffer[idx], (POINTER)input, partLen); - MD5Transform (context->state, context->buffer); - - for (i = partLen; i + 63 < inputLen; i += 64) - MD5Transform (context->state, &input[i]); - - idx = 0; - } - else - i = 0; - - /* Buffer remaining input */ - MD5_memcpy - ((POINTER)&context->buffer[idx], (POINTER)&input[i], - inputLen-i); -} - -/* MD5 finalization. Ends an MD5 message-digest operation, writing the - the message digest and zeroizing the context. - */ -void -MD5Final ( - unsigned char digest[16], /* message digest */ - MD5_CTX *context /* context */ - ) -{ - unsigned char bits[8]; - unsigned int idx, padLen; - - /* Save number of bits */ - Encode (bits, context->count, 8); - - /* Pad out to 56 mod 64. - */ - idx = (unsigned int)((context->count[0] >> 3) & 0x3f); - padLen = (idx < 56) ? (56 - idx) : (120 - idx); - MD5Update (context, PADDING, padLen); - - /* Append length (before padding) */ - MD5Update (context, bits, 8); - - /* Store state in digest */ - Encode (digest, context->state, 16); - - /* Zeroize sensitive information. - */ - MD5_memset ((POINTER)context, 0, sizeof (*context)); -} - -/* MD5 basic transformation. Transforms state based on block. - */ -static void -MD5Transform ( - UINT4 state[4], - unsigned char block[64] - ) -{ - UINT4 a = state[0], b = state[1], c = state[2], d = state[3], x[16]; - - Decode (x, block, 64); - - /* Round 1 */ - FF (a, b, c, d, x[ 0], S11, 0xd76aa478); /* 1 */ - FF (d, a, b, c, x[ 1], S12, 0xe8c7b756); /* 2 */ - FF (c, d, a, b, x[ 2], S13, 0x242070db); /* 3 */ - FF (b, c, d, a, x[ 3], S14, 0xc1bdceee); /* 4 */ - FF (a, b, c, d, x[ 4], S11, 0xf57c0faf); /* 5 */ - FF (d, a, b, c, x[ 5], S12, 0x4787c62a); /* 6 */ - FF (c, d, a, b, x[ 6], S13, 0xa8304613); /* 7 */ - FF (b, c, d, a, x[ 7], S14, 0xfd469501); /* 8 */ - FF (a, b, c, d, x[ 8], S11, 0x698098d8); /* 9 */ - FF (d, a, b, c, x[ 9], S12, 0x8b44f7af); /* 10 */ - FF (c, d, a, b, x[10], S13, 0xffff5bb1); /* 11 */ - FF (b, c, d, a, x[11], S14, 0x895cd7be); /* 12 */ - FF (a, b, c, d, x[12], S11, 0x6b901122); /* 13 */ - FF (d, a, b, c, x[13], S12, 0xfd987193); /* 14 */ - FF (c, d, a, b, x[14], S13, 0xa679438e); /* 15 */ - FF (b, c, d, a, x[15], S14, 0x49b40821); /* 16 */ - - /* Round 2 */ - GG (a, b, c, d, x[ 1], S21, 0xf61e2562); /* 17 */ - GG (d, a, b, c, x[ 6], S22, 0xc040b340); /* 18 */ - GG (c, d, a, b, x[11], S23, 0x265e5a51); /* 19 */ - GG (b, c, d, a, x[ 0], S24, 0xe9b6c7aa); /* 20 */ - GG (a, b, c, d, x[ 5], S21, 0xd62f105d); /* 21 */ - GG (d, a, b, c, x[10], S22, 0x2441453); /* 22 */ - GG (c, d, a, b, x[15], S23, 0xd8a1e681); /* 23 */ - GG (b, c, d, a, x[ 4], S24, 0xe7d3fbc8); /* 24 */ - GG (a, b, c, d, x[ 9], S21, 0x21e1cde6); /* 25 */ - GG (d, a, b, c, x[14], S22, 0xc33707d6); /* 26 */ - GG (c, d, a, b, x[ 3], S23, 0xf4d50d87); /* 27 */ - GG (b, c, d, a, x[ 8], S24, 0x455a14ed); /* 28 */ - GG (a, b, c, d, x[13], S21, 0xa9e3e905); /* 29 */ - GG (d, a, b, c, x[ 2], S22, 0xfcefa3f8); /* 30 */ - GG (c, d, a, b, x[ 7], S23, 0x676f02d9); /* 31 */ - GG (b, c, d, a, x[12], S24, 0x8d2a4c8a); /* 32 */ - - /* Round 3 */ - HH (a, b, c, d, x[ 5], S31, 0xfffa3942); /* 33 */ - HH (d, a, b, c, x[ 8], S32, 0x8771f681); /* 34 */ - HH (c, d, a, b, x[11], S33, 0x6d9d6122); /* 35 */ - HH (b, c, d, a, x[14], S34, 0xfde5380c); /* 36 */ - HH (a, b, c, d, x[ 1], S31, 0xa4beea44); /* 37 */ - HH (d, a, b, c, x[ 4], S32, 0x4bdecfa9); /* 38 */ - HH (c, d, a, b, x[ 7], S33, 0xf6bb4b60); /* 39 */ - HH (b, c, d, a, x[10], S34, 0xbebfbc70); /* 40 */ - HH (a, b, c, d, x[13], S31, 0x289b7ec6); /* 41 */ - HH (d, a, b, c, x[ 0], S32, 0xeaa127fa); /* 42 */ - HH (c, d, a, b, x[ 3], S33, 0xd4ef3085); /* 43 */ - HH (b, c, d, a, x[ 6], S34, 0x4881d05); /* 44 */ - HH (a, b, c, d, x[ 9], S31, 0xd9d4d039); /* 45 */ - HH (d, a, b, c, x[12], S32, 0xe6db99e5); /* 46 */ - HH (c, d, a, b, x[15], S33, 0x1fa27cf8); /* 47 */ - HH (b, c, d, a, x[ 2], S34, 0xc4ac5665); /* 48 */ - - /* Round 4 */ - II (a, b, c, d, x[ 0], S41, 0xf4292244); /* 49 */ - II (d, a, b, c, x[ 7], S42, 0x432aff97); /* 50 */ - II (c, d, a, b, x[14], S43, 0xab9423a7); /* 51 */ - II (b, c, d, a, x[ 5], S44, 0xfc93a039); /* 52 */ - II (a, b, c, d, x[12], S41, 0x655b59c3); /* 53 */ - II (d, a, b, c, x[ 3], S42, 0x8f0ccc92); /* 54 */ - II (c, d, a, b, x[10], S43, 0xffeff47d); /* 55 */ - II (b, c, d, a, x[ 1], S44, 0x85845dd1); /* 56 */ - II (a, b, c, d, x[ 8], S41, 0x6fa87e4f); /* 57 */ - II (d, a, b, c, x[15], S42, 0xfe2ce6e0); /* 58 */ - II (c, d, a, b, x[ 6], S43, 0xa3014314); /* 59 */ - II (b, c, d, a, x[13], S44, 0x4e0811a1); /* 60 */ - II (a, b, c, d, x[ 4], S41, 0xf7537e82); /* 61 */ - II (d, a, b, c, x[11], S42, 0xbd3af235); /* 62 */ - II (c, d, a, b, x[ 2], S43, 0x2ad7d2bb); /* 63 */ - II (b, c, d, a, x[ 9], S44, 0xeb86d391); /* 64 */ - - state[0] += a; - state[1] += b; - state[2] += c; - state[3] += d; - - /* Zeroize sensitive information. - */ - MD5_memset ((POINTER)x, 0, sizeof (x)); -} - -/* Encodes input (UINT4) into output (unsigned char). Assumes len is - a multiple of 4. - */ -static void -Encode ( - unsigned char *output, - UINT4 *input, - unsigned int len - ) -{ - unsigned int i, j; - - for (i = 0, j = 0; j < len; i++, j += 4) { - output[j] = (unsigned char)(input[i] & 0xff); - output[j+1] = (unsigned char)((input[i] >> 8) & 0xff); - output[j+2] = (unsigned char)((input[i] >> 16) & 0xff); - output[j+3] = (unsigned char)((input[i] >> 24) & 0xff); - } -} - -/* Decodes input (unsigned char) into output (UINT4). Assumes len is - a multiple of 4. - */ -static void -Decode ( - UINT4 *output, - unsigned char *input, - unsigned int len - ) -{ - unsigned int i, j; - - for (i = 0, j = 0; j < len; i++, j += 4) - output[i] = ((UINT4)input[j]) | (((UINT4)input[j+1]) << 8) | - (((UINT4)input[j+2]) << 16) | (((UINT4)input[j+3]) << 24); -} - -/* Note: Replace "for loop" with standard memcpy if possible. - */ -static void -MD5_memcpy ( - POINTER output, - POINTER input, - unsigned int len - ) -{ - unsigned int i; - - for (i = 0; i < len; i++) - output[i] = input[i]; -} - -/* Note: Replace "for loop" with standard memset if possible. - */ -static void -MD5_memset ( - POINTER output, - int value, - unsigned int len - ) -{ - unsigned int i; - - for (i = 0; i < len; i++) - ((char *)output)[i] = (char)value; -} -#else -int md5_bs; -#endif diff -urN src/contrib/ntp/libntp/modetoa.c src.ntp/contrib/ntp/libntp/modetoa.c --- src/contrib/ntp/libntp/modetoa.c 1999-12-09 14:01:10.000000000 +0100 +++ src.ntp/contrib/ntp/libntp/modetoa.c 2010-02-04 08:26:57.000000000 +0100 @@ -24,9 +24,9 @@ "bclient", }; - if (mode < 0 || mode >= (sizeof modestrings)/sizeof(char *)) { + if (mode < 0 || mode >= COUNTOF(modestrings)) { LIB_GETBUF(bp); - (void)sprintf(bp, "mode#%d", mode); + snprintf(bp, LIB_BUFLENGTH, "mode#%d", mode); return bp; } diff -urN src/contrib/ntp/libntp/msyslog.c src.ntp/contrib/ntp/libntp/msyslog.c --- src/contrib/ntp/libntp/msyslog.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/msyslog.c 2009-12-09 08:36:35.000000000 +0100 @@ -9,9 +9,7 @@ # include #endif -#ifdef HAVE_SYS_TYPES_H -# include -#endif +#include #ifdef HAVE_UNISTD_H # include #endif @@ -42,8 +40,8 @@ extern char *progname; /* Declare the local functions */ -void addto_syslog P((int, char *)); -void format_errmsg P((char *, int, const char *, int)); +void addto_syslog (int, char *); +void format_errmsg (char *, int, const char *, int); /* @@ -84,12 +82,12 @@ register char c; register char *n; register const char *f; - + size_t len; char *err; n = nfmt; f = fmt; - while ((c = *f++) != '\0' && n < (nfmt+lennfmt - 2)) { + while ((c = *f++) != '\0' && n < (nfmt + lennfmt - 2)) { if (c != '%') { *n++ = c; continue; @@ -99,12 +97,13 @@ *n++ = c; continue; } - err = 0; err = strerror(errval); + len = strlen(err); + /* Make sure we have enough space for the error message */ - if ((n + strlen(err)) < (nfmt + lennfmt -2)) { - strcpy(n, err); - n += strlen(err); + if ((n + len) < (nfmt + lennfmt - 2)) { + memcpy(n, err, len); + n += len; } } #if !defined(VMS) @@ -114,18 +113,6 @@ *n = '\0'; } -/* - * The externally called functions are defined here - * but share the internal function above to fetch - * any error message strings, This is done so that we can - * have two different functions to perform the logging - * since Windows gets it's error information from different - * places depending on whether or not it's network I/O. - * msyslog() is for general use while netsyslog() is for - * network I/O functions. They are virtually identical - * in implementation. - */ - #if defined(__STDC__) || defined(HAVE_STDARG_H) void msyslog(int level, const char *fmt, ...) #else /* defined(__STDC__) || defined(HAVE_STDARG_H) */ @@ -141,54 +128,18 @@ #endif va_list ap; char buf[1025], nfmt[256]; + int errval; /* * Save the error value as soon as possible */ -#ifdef SYS_WINNT - int errval = GetLastError(); -#else - int errval = errno; -#endif - -#if defined(__STDC__) || defined(HAVE_STDARG_H) - va_start(ap, fmt); -#else - va_start(ap); + errval = errno; - level = va_arg(ap, int); - fmt = va_arg(ap, char *); -#endif - format_errmsg(nfmt, sizeof(nfmt), fmt, errval); - - vsnprintf(buf, sizeof(buf), nfmt, ap); - addto_syslog(level, buf); - va_end(ap); -} -#if defined(__STDC__) || defined(HAVE_STDARG_H) -void netsyslog(int level, const char *fmt, ...) -#else /* defined(__STDC__) || defined(HAVE_STDARG_H) */ - /*VARARGS*/ - void netsyslog(va_alist) - va_dcl -#endif /* defined(__STDC__) || defined(HAVE_STDARG_H) */ -{ -#if defined(__STDC__) || defined(HAVE_STDARG_H) -#else - int level; - const char *fmt; -#endif - va_list ap; - char buf[1025], nfmt[256]; - - /* - * Save the error value as soon as possible - */ #ifdef SYS_WINNT - int errval = WSAGetLastError(); -#else - int errval = errno; -#endif + errval = GetLastError(); + if (NO_ERROR == errval) + errval = errno; +#endif /* SYS_WINNT */ #if defined(__STDC__) || defined(HAVE_STDARG_H) va_start(ap, fmt); diff -urN src/contrib/ntp/libntp/netof.c src.ntp/contrib/ntp/libntp/netof.c --- src/contrib/ntp/libntp/netof.c 2004-07-20 17:01:21.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/netof.c 2009-12-09 08:36:35.000000000 +0100 @@ -3,46 +3,52 @@ * (zero out host part) */ #include +#include #include "ntp_fp.h" +#include "ntp_net.h" #include "ntp_stdlib.h" #include "ntp.h" -#define NUM_NETOF_BUFS 10 -static struct sockaddr_storage ssbuf[NUM_NETOF_BUFS]; -static int next_ssbuf = 0; - -struct sockaddr_storage* +sockaddr_u * netof( - struct sockaddr_storage* hostaddr + sockaddr_u *hostaddr ) { - register u_int32 netnum; - struct sockaddr_storage *netaddr; + static sockaddr_u netofbuf[8]; + static int next_netofbuf; + u_int32 netnum; + sockaddr_u * netaddr; + + netaddr = &netofbuf[next_netofbuf]; + next_netofbuf = (next_netofbuf + 1) % COUNTOF(netofbuf); - netaddr = &ssbuf[next_ssbuf++]; - if (next_ssbuf == NUM_NETOF_BUFS) - next_ssbuf = 0; - memcpy(netaddr, hostaddr, sizeof(struct sockaddr_storage)); + memcpy(netaddr, hostaddr, sizeof(*netaddr)); - if(netaddr->ss_family == AF_INET) { - netnum = ((struct sockaddr_in*)netaddr)->sin_addr.s_addr; + if (IS_IPV4(netaddr)) { + netnum = SRCADR(netaddr); /* * We live in a modern CIDR world where the basement nets, which * used to be class A, are now probably associated with each * host address. So, for class-A nets, all bits are significant. */ - if(IN_CLASSC(netnum)) - netnum &= IN_CLASSC_NET; + if (IN_CLASSC(netnum)) + netnum &= IN_CLASSC_NET; else if (IN_CLASSB(netnum)) - netnum &= IN_CLASSB_NET; - ((struct sockaddr_in*)netaddr)->sin_addr.s_addr = netnum; - } - else if(netaddr->ss_family == AF_INET6) { - /* Here we put 0 at the local link address so we get net address */ - memset(&((struct sockaddr_in6*)netaddr)->sin6_addr.s6_addr[8], 0, 8*sizeof(u_char)); - } + netnum &= IN_CLASSB_NET; + + SET_ADDR4(netaddr, netnum); + + } else if (IS_IPV6(netaddr)) + /* assume the typical /64 subnet size */ + memset(&NSRCADR6(netaddr)[8], 0, 8); +#ifdef DEBUG + else { + msyslog(LOG_ERR, "netof unknown AF %d", AF(netaddr)); + exit(1); + } +#endif - return netaddr; + return netaddr; } diff -urN src/contrib/ntp/libntp/ntp_lineedit.c src.ntp/contrib/ntp/libntp/ntp_lineedit.c --- src/contrib/ntp/libntp/ntp_lineedit.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/libntp/ntp_lineedit.c 2010-02-09 11:01:25.000000000 +0100 @@ -0,0 +1,240 @@ +/* + * ntp_lineedit.c - generic interface to various line editing libs + */ +#ifdef HAVE_CONFIG_H +# include +#endif + +#include +#include +#include +#include + +#if defined(HAVE_READLINE_HISTORY) && \ + (!defined(HAVE_READLINE_HISTORY_H) || \ + !defined(HAVE_READLINE_READLINE_H)) +# undef HAVE_READLINE_HISTORY +#endif +#if defined(HAVE_READLINE_HISTORY) +# include +# include +# define LE_READLINE +#elif defined(HAVE_HISTEDIT_H) +# include +# define LE_EDITLINE +#else +# define LE_NONE +#endif + +#include "ntp.h" +#include "ntp_stdlib.h" +#include "ntp_lineedit.h" + +#define MAXEDITLINE 512 + +/* + * external references + */ + +extern char * progname; + +/* + * globals, private prototypes + */ + +static int ntp_readline_initted; +static char * lineedit_prompt; + + +#ifdef LE_EDITLINE + static EditLine * ntp_el; + static History * ntp_hist; + static HistEvent hev; + + char * ntp_prompt_callback(EditLine *); +#endif /* LE_EDITLINE */ + + +/* + * ntp_readline_init - setup, set or reset prompt string + */ +int +ntp_readline_init( + const char * prompt + ) +{ + int success; + + success = 1; + + if (prompt) { + if (lineedit_prompt) + free(lineedit_prompt); + lineedit_prompt = estrdup(prompt); + } + +#ifdef LE_EDITLINE + if (NULL == ntp_el) { + + ntp_el = el_init(progname, stdin, stdout, stderr); + if (ntp_el) { + + el_set(ntp_el, EL_PROMPT, ntp_prompt_callback); + el_set(ntp_el, EL_EDITOR, "emacs"); + + ntp_hist = history_init(); + + if (NULL == ntp_hist) { + + fprintf(stderr, "history_init(): %s\n", + strerror(errno)); + fflush(stderr); + + el_end(ntp_el); + ntp_el = NULL; + + success = 0; + + } else { + memset(&hev, 0, sizeof hev); + + history(ntp_hist, &hev, H_SETSIZE, 128); + + el_set(ntp_el, EL_HIST, history, ntp_hist); + + /* use any .editrc */ + el_source(ntp_el, NULL); + } + } else + success = 0; + } +#endif /* LE_EDITLINE */ + + ntp_readline_initted = success; + + return success; +} + + +/* + * ntp_readline_uninit - release resources + */ +void +ntp_readline_uninit( + void + ) +{ +#ifdef LE_EDITLINE + if (ntp_el) { + el_end(ntp_el); + ntp_el = NULL; + + history_end(ntp_hist); + ntp_hist = NULL; + } +#endif /* LE_EDITLINE */ + + if (lineedit_prompt) { + free(lineedit_prompt); + lineedit_prompt = NULL; + } + + ntp_readline_initted = 0; +} + + +/* + * ntp_readline - read a line with the line editor available + * + * The string returned must be released with free() + */ + +char * +ntp_readline( + int * pcount + ) +{ + char * line; +#ifdef LE_NONE + char line_buf[MAXEDITLINE]; +#endif +#ifdef LE_EDITLINE + const char * cline; +#endif + + if (!ntp_readline_initted) + return NULL; + + *pcount = 0; + +#ifdef LE_READLINE + line = readline(lineedit_prompt ? lineedit_prompt : ""); + if (NULL != line) { + if (*line) { + add_history(line); + *pcount = strlen(line); + } else { + free(line); + line = NULL; + } + } +#endif /* LE_READLINE */ + +#ifdef LE_EDITLINE + cline = el_gets(ntp_el, pcount); + + if (NULL != cline && *cline) { + history(ntp_hist, &hev, H_ENTER, cline); + *pcount = strlen(cline); + line = estrdup(cline); + } else + line = NULL; +#endif /* LE_EDITLINE */ + +#ifdef LE_NONE + /* stone hammers */ + if (lineedit_prompt) { +# ifdef VMS + /* + * work around problem mixing + * stdout & stderr + */ + fputs("", stdout); +# endif /* VMS */ + + fputs(lineedit_prompt, stderr); + fflush(stderr); + } + + line = fgets(line_buf, sizeof(line_buf), stdin); + if (NULL != line && *line) { + *pcount = strlen(line); + line = estrdup(line); + } else + line = NULL; + +#endif /* LE_NONE */ + + + if (!line) /* EOF */ + fputs("\n", stderr); + + return line; +} + + +#ifdef LE_EDITLINE +/* + * ntp_prompt_callback - return prompt string to el_gets() + */ +char * +ntp_prompt_callback( + EditLine *el + ) +{ + UNUSED_ARG(el); + + return lineedit_prompt; +} +#endif /* LE_EDITLINE */ + diff -urN src/contrib/ntp/libntp/ntp_random.c src.ntp/contrib/ntp/libntp/ntp_random.c --- src/contrib/ntp/libntp/ntp_random.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/ntp_random.c 2009-12-09 08:36:36.000000000 +0100 @@ -30,7 +30,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/contrib/ntp/libntp/ntp_random.c,v 1.1 2008/08/22 15:58:00 roberto Exp $ + * $FreeBSD: src/lib/libc/stdlib/random.c,v 1.4.2.2 1999/09/05 11:16:45 peter Exp $ * */ @@ -39,9 +39,7 @@ #endif /* LIBC_SCCS and not lint */ #include "config.h" -#ifdef HAVE_SYS_TYPES_H -# include -#endif +#include #ifdef HAVE_UNISTD_H # include #endif @@ -219,7 +217,7 @@ static long rand_sep = SEP_3; static long *end_ptr = &randtbl[DEG_3 + 1]; -static inline long good_rand P((long)); +static inline long good_rand (long); static inline long good_rand ( diff -urN src/contrib/ntp/libntp/ntp_rfc2553.c src.ntp/contrib/ntp/libntp/ntp_rfc2553.c --- src/contrib/ntp/libntp/ntp_rfc2553.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/ntp_rfc2553.c 2009-12-09 08:36:37.000000000 +0100 @@ -69,7 +69,9 @@ #include #include +#ifdef HAVE_SYS_SOCKET_H #include +#endif #include #ifdef HAVE_NETINET_IN_H #include @@ -127,8 +129,8 @@ } #endif -static int do_nodename P((const char *nodename, struct addrinfo *ai, - const struct addrinfo *hints)); +static int do_nodename (const char *nodename, struct addrinfo *ai, + const struct addrinfo *hints); int getaddrinfo (const char *nodename, const char *servname, @@ -362,7 +364,7 @@ sockin6->sin6_addr = in6addr_any; */ } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR +#ifdef ISC_PLATFORM_HAVESALEN ai->ai_addr->sa_len = SOCKLEN(ai->ai_addr); #endif @@ -428,15 +430,11 @@ sockin = (struct sockaddr_in *)ai->ai_addr; memcpy(&sockin->sin_addr, hp->h_addr, hp->h_length); ai->ai_addr->sa_family = hp->h_addrtype; -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR +#ifdef ISC_PLATFORM_HAVESALEN ai->ai_addr->sa_len = sizeof(struct sockaddr); #endif - if (hints != NULL && hints->ai_flags & AI_CANONNAME) { - ai->ai_canonname = malloc(strlen(hp->h_name) + 1); - if (ai->ai_canonname == NULL) - return (EAI_MEMORY); - strcpy(ai->ai_canonname, hp->h_name); - } + if (hints != NULL && hints->ai_flags & AI_CANONNAME) + ai->ai_canonname = estrdup(hp->h_name); return (0); } diff -urN src/contrib/ntp/libntp/numtoa.c src.ntp/contrib/ntp/libntp/numtoa.c --- src/contrib/ntp/libntp/numtoa.c 1999-12-09 14:01:10.000000000 +0100 +++ src.ntp/contrib/ntp/libntp/numtoa.c 2009-12-09 08:36:35.000000000 +0100 @@ -1,6 +1,13 @@ /* * numtoa - return asciized network numbers store in local array space */ +#include + +#include +#ifdef HAVE_NETINET_IN_H +#include /* ntohl */ +#endif + #include #include "ntp_fp.h" @@ -17,8 +24,10 @@ netnum = ntohl(num); LIB_GETBUF(buf); - (void) sprintf(buf, "%lu.%lu.%lu.%lu", ((u_long)netnum >> 24) & 0xff, - ((u_long)netnum >> 16) & 0xff, ((u_long)netnum >> 8) & 0xff, - (u_long)netnum & 0xff); + snprintf(buf, LIB_BUFLENGTH, "%lu.%lu.%lu.%lu", + ((u_long)netnum >> 24) & 0xff, + ((u_long)netnum >> 16) & 0xff, + ((u_long)netnum >> 8) & 0xff, + (u_long)netnum & 0xff); return buf; } diff -urN src/contrib/ntp/libntp/numtohost.c src.ntp/contrib/ntp/libntp/numtohost.c --- src/contrib/ntp/libntp/numtohost.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/numtohost.c 2009-12-09 08:36:35.000000000 +0100 @@ -1,6 +1,12 @@ /* * numtohost - convert network number to host name. */ +#include + +#include +#ifdef HAVE_NETINET_IN_H +#include /* ntohl */ +#endif #include "ntp_fp.h" #include "ntp_stdlib.h" diff -urN src/contrib/ntp/libntp/prettydate.c src.ntp/contrib/ntp/libntp/prettydate.c --- src/contrib/ntp/libntp/prettydate.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/prettydate.c 2010-02-04 08:26:56.000000000 +0100 @@ -7,8 +7,11 @@ #include "ntp_unixtime.h" /* includes */ #include "lib_strbuf.h" #include "ntp_stdlib.h" +#include "ntp_assert.h" -static const char *months[] = { +static char *common_prettydate(l_fp *, int); + +const char *months[] = { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" }; @@ -19,66 +22,146 @@ /* Helper function to handle possible wraparound of the ntp epoch. - Works by assuming that the localtime/gmtime library functions - have been updated so that they work + Works by periodic extension of the ntp time stamp in the NTP epoch. If the + 'time_t' is 32 bit, use solar cycle warping to get the value in a suitable + range. Also uses solar cycle warping to work around really buggy + implementations of 'gmtime()' / 'localtime()' that cannot work with a + negative time value, that is, times before 1970-01-01. (MSVCRT...) + + Apart from that we're assuming that the localtime/gmtime library functions + have been updated so that they work... */ -#define MAX_EPOCH_NR 1000 + +/* solar cycle in secs, unsigned secs and years. And the cycle limits. +** +** And an explanation. The julian calendar repeats ever 28 years, because it's +** the LCM of 7 and 4, the week and leap year cycles. This is called a 'solar +** cycle'. The gregorian calendar does the same as long as no centennial year +** (divisible by 100, but not 400) goes in the way. So between 1901 and 2099 +** (inclusive) we can warp time stamps by 28 years to make them suitable for +** localtime() and gmtime() if we have trouble. Of course this will play +** hubbubb with the DST zone switches, so we should do it only if necessary; +** but as we NEED a proper conversion to dates via gmtime() we should try to +** cope with as many idiosyncrasies as possible. +*/ +#define SOLAR_CYCLE_SECS 0x34AADC80UL /* 7*1461*86400*/ +#define SOLAR_CYCLE_YEARS 28 +#define MINFOLD -3 +#define MAXFOLD 3 struct tm * ntp2unix_tm( u_long ntp, int local ) { - time_t t, curr; struct tm *tm; - int curr_year, epoch_nr; + int32 folds = 0; + time_t t = time(NULL); + u_int32 dwlo = (int32)t; /* might expand for SIZEOF_TIME_T < 4 */ +#if ( SIZEOF_TIME_T > 4 ) + int32 dwhi = (int32)(t >> 16 >> 16);/* double shift: avoid warnings */ +#else + /* + * Get the correct sign extension in the high part. + * (now >> 32) may not work correctly on every 32 bit + * system, e.g. it yields garbage under Win32/VC6. + */ + int32 dwhi = (int32)(t >> 31); +#endif + + /* Shift NTP to UN*X epoch, then unfold around currrent time. It's + * important to use a 32 bit max signed value -- LONG_MAX is 64 bit on + * a 64-bit system, and it will give wrong results. + */ + M_ADD(dwhi, dwlo, 0, ((1UL << 31)-1)); /* 32-bit max signed */ + if ((ntp -= JAN_1970) > dwlo) + --dwhi; + dwlo = ntp; + +# if SIZEOF_TIME_T < 4 +# error sizeof(time_t) < 4 -- this will not work! +# elif SIZEOF_TIME_T == 4 + + /* + ** If the result will not fit into a 'time_t' we have to warp solar + ** cycles. That's implemented by looped addition / subtraction with + ** M_ADD and M_SUB to avoid implicit 64 bit operations, especially + ** division. As he number of warps is rather limited there's no big + ** performance loss here. + ** + ** note: unless the high word doesn't match the sign-extended low word, + ** the combination will not fit into time_t. That's what we use for + ** loop control here... + */ + while (dwhi != ((int32)dwlo >> 31)) { + if (dwhi < 0 && --folds >= MINFOLD) + M_ADD(dwhi, dwlo, 0, SOLAR_CYCLE_SECS); + else if (dwhi >= 0 && ++folds <= MAXFOLD) + M_SUB(dwhi, dwlo, 0, SOLAR_CYCLE_SECS); + else + return NULL; + } - /* First get the current year: */ - curr = time(NULL); - tm = local ? localtime(&curr) : gmtime(&curr); - if (!tm) return NULL; +# else - curr_year = 1900 + tm->tm_year; + /* everything fine -- no reduction needed for the next thousand years */ - /* Convert the ntp timestamp to a unix utc seconds count: */ - t = (time_t) ntp - JAN_1970; +# endif - /* Check that the ntp timestamp is not before a 136 year window centered - around the current year: + /* combine hi/lo to make time stamp */ + t = ((time_t)dwhi << 16 << 16) | dwlo; /* double shift: avoid warnings */ - Failsafe in case of an infinite loop: - Allow up to 1000 epochs of 136 years each! - */ - for (epoch_nr = 0; epoch_nr < MAX_EPOCH_NR; epoch_nr++) { - tm = local ? localtime(&t) : gmtime(&t); +# ifdef _MSC_VER /* make this an autoconf option? */ -#if SIZEOF_TIME_T < 4 -# include "Bletch: sizeof(time_t) < 4!" -#endif + /* + ** The MSDN says that the (Microsoft) Windoze versions of 'gmtime()' + ** and 'localtime()' will bark on time stamps < 0. Better to fix it + ** immediately. + */ + while (t < 0) { + if (--folds < MINFOLD) + return NULL; + t += SOLAR_CYCLE_SECS; + } + +# endif /* Microsoft specific */ -#if SIZEOF_TIME_T == 4 - /* If 32 bits, then year is 1970-2038, so no sense looking */ - epoch_nr = MAX_EPOCH_NR; -#else /* SIZEOF_TIME_T > 4 */ - /* Check that the resulting year is in the correct epoch: */ - if (1900 + tm->tm_year > curr_year - 68) break; - - /* Epoch wraparound: Add 2^32 seconds! */ - t += (time_t) 65536 << 16; -#endif /* SIZEOF_TIME_T > 4 */ + /* 't' should be a suitable value by now. Just go ahead. */ + while ( (tm = (*(local ? localtime : gmtime))(&t)) == 0) + /* seems there are some other pathological implementations of + ** 'gmtime()' and 'localtime()' somewhere out there. No matter + ** if we have 32-bit or 64-bit 'time_t', try to fix this by + ** solar cycle warping again... + */ + if (t < 0) { + if (--folds < MINFOLD) + return NULL; + t += SOLAR_CYCLE_SECS; + } else { + if ((++folds > MAXFOLD) || ((t -= SOLAR_CYCLE_SECS) < 0)) + return NULL; /* That's truely pathological! */ + } + /* 'tm' surely not NULL here... */ + NTP_INSIST(tm != NULL); + if (folds != 0) { + tm->tm_year += folds * SOLAR_CYCLE_YEARS; + if (tm->tm_year <= 0 || tm->tm_year >= 200) + return NULL; /* left warp range... can't help here! */ } return tm; } -char * -prettydate( - l_fp *ts + +static char * +common_prettydate( + l_fp *ts, + int local ) { char *bp; struct tm *tm; - time_t sec; + u_long sec; u_long msec; LIB_GETBUF(bp); @@ -86,47 +169,36 @@ sec = ts->l_ui; msec = ts->l_uf / 4294967; /* fract / (2 ** 32 / 1000) */ - tm = ntp2unix_tm(sec, 1); - if (!tm) { - (void) sprintf(bp, "%08lx.%08lx --- --- -- ---- --:--:--", - (u_long)ts->l_ui, (u_long)ts->l_uf); - } - else { - (void) sprintf(bp, "%08lx.%08lx %s, %s %2d %4d %2d:%02d:%02d.%03lu", - (u_long)ts->l_ui, (u_long)ts->l_uf, days[tm->tm_wday], - months[tm->tm_mon], tm->tm_mday, 1900 + tm->tm_year, - tm->tm_hour,tm->tm_min, tm->tm_sec, msec); - } + tm = ntp2unix_tm(sec, local); + if (!tm) + snprintf(bp, LIB_BUFLENGTH, + "%08lx.%08lx --- --- -- ---- --:--:--", + (u_long)ts->l_ui, (u_long)ts->l_uf); + else + snprintf(bp, LIB_BUFLENGTH, + "%08lx.%08lx %s, %s %2d %4d %2d:%02d:%02d.%03lu", + (u_long)ts->l_ui, (u_long)ts->l_uf, + days[tm->tm_wday], months[tm->tm_mon], + tm->tm_mday, 1900 + tm->tm_year, tm->tm_hour, + tm->tm_min, tm->tm_sec, msec); return bp; } + char * -gmprettydate( +prettydate( l_fp *ts ) { - char *bp; - struct tm *tm; - time_t sec; - u_long msec; - - LIB_GETBUF(bp); - - sec = ts->l_ui; - msec = ts->l_uf / 4294967; /* fract / (2 ** 32 / 1000) */ + return common_prettydate(ts, 1); +} - tm = ntp2unix_tm(sec, 0); - if (!tm) { - (void) sprintf(bp, "%08lx.%08lx --- --- -- ---- --:--:--", - (u_long)ts->l_ui, (u_long)ts->l_uf); - } - else { - (void) sprintf(bp, "%08lx.%08lx %s, %s %2d %4d %2d:%02d:%02d.%03lu", - (u_long)ts->l_ui, (u_long)ts->l_uf, days[tm->tm_wday], - months[tm->tm_mon], tm->tm_mday, 1900 + tm->tm_year, - tm->tm_hour,tm->tm_min, tm->tm_sec, msec); - } - return bp; +char * +gmprettydate( + l_fp *ts + ) +{ + return common_prettydate(ts, 0); } diff -urN src/contrib/ntp/libntp/recvbuff.c src.ntp/contrib/ntp/libntp/recvbuff.c --- src/contrib/ntp/libntp/recvbuff.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/recvbuff.c 2009-12-09 08:36:35.000000000 +0100 @@ -4,14 +4,21 @@ #include #include "ntp_machine.h" +#include "ntp_assert.h" #include "ntp_fp.h" #include "ntp_syslog.h" #include "ntp_stdlib.h" #include "ntp_io.h" +#include "ntp_lists.h" #include "recvbuff.h" #include "iosignal.h" -#include + + +#ifdef DEBUG +static void uninit_recvbuff(void); +#endif + /* * Memory allocation */ @@ -20,10 +27,10 @@ static u_long volatile total_recvbufs; /* total recvbufs currently in use */ static u_long volatile lowater_adds; /* number of times we have added memory */ static u_long volatile buffer_shortfall;/* number of missed free receive buffers - between replenishments */ + between replenishments */ static ISC_LIST(recvbuf_t) full_recv_list; /* Currently used recv buffers */ -static ISC_LIST(recvbuf_t) free_recv_list; /* Currently unused buffers */ +static recvbuf_t * free_recv_list; /* Currently unused buffers */ #if defined(SYS_WINNT) @@ -64,15 +71,10 @@ return lowater_adds; } -static void +static inline void initialise_buffer(recvbuf_t *buff) { - memset((char *) buff, 0, sizeof(recvbuf_t)); - -#if defined SYS_WINNT - buff->wsabuff.len = RX_BUFF_SIZE; - buff->wsabuff.buf = (char *) buff->recv_buffer; -#endif + memset(buff, 0, sizeof(*buff)); } static void @@ -84,12 +86,21 @@ abuf = nbufs + buffer_shortfall; buffer_shortfall = 0; - bufp = (recvbuf_t *) emalloc(abuf*sizeof(recvbuf_t)); +#ifndef DEBUG + bufp = emalloc(abuf * sizeof(*bufp)); +#endif - for (i = 0; i < abuf; i++) - { - memset((char *) bufp, 0, sizeof(recvbuf_t)); - ISC_LIST_APPEND(free_recv_list, bufp, link); + for (i = 0; i < abuf; i++) { +#ifdef DEBUG + /* + * Allocate each buffer individually so they can be + * free()d during ntpd shutdown on DEBUG builds to + * keep them out of heap leak reports. + */ + bufp = emalloc(sizeof(*bufp)); +#endif + memset(bufp, 0, sizeof(*bufp)); + LINK_SLIST(free_recv_list, bufp, link.next); bufp++; free_recvbufs++; total_recvbufs++; @@ -105,7 +116,6 @@ * Init buffer free list and stat counters */ ISC_LIST_INIT(full_recv_list); - ISC_LIST_INIT(free_recv_list); free_recvbufs = total_recvbufs = 0; full_recvbufs = lowater_adds = 0; @@ -115,8 +125,32 @@ InitializeCriticalSection(&RecvLock); #endif +#ifdef DEBUG + atexit(&uninit_recvbuff); +#endif } + +#ifdef DEBUG +static void +uninit_recvbuff(void) +{ + recvbuf_t *rbunlinked; + + while ((rbunlinked = ISC_LIST_HEAD(full_recv_list)) != NULL) { + ISC_LIST_DEQUEUE_TYPE(full_recv_list, rbunlinked, link, recvbuf_t); + free(rbunlinked); + } + + do { + UNLINK_HEAD_SLIST(rbunlinked, free_recv_list, link.next); + if (rbunlinked != NULL) + free(rbunlinked); + } while (rbunlinked != NULL); +} +#endif /* DEBUG */ + + /* * freerecvbuf - make a single recvbuf available for reuse */ @@ -132,11 +166,7 @@ (rb->used)--; if (rb->used != 0) msyslog(LOG_ERR, "******** freerecvbuff non-zero usage: %d *******", rb->used); - ISC_LIST_APPEND(free_recv_list, rb, link); -#if defined SYS_WINNT - rb->wsabuff.len = RX_BUFF_SIZE; - rb->wsabuff.buf = (char *) rb->recv_buffer; -#endif + LINK_SLIST(free_recv_list, rb, link.next); free_recvbufs++; UNLOCK(); } @@ -150,6 +180,7 @@ return; } LOCK(); + ISC_LINK_INIT(rb, link); ISC_LIST_APPEND(full_recv_list, rb, link); full_recvbufs++; UNLOCK(); @@ -158,20 +189,16 @@ recvbuf_t * get_free_recv_buffer(void) { - recvbuf_t * buffer = NULL; + recvbuf_t *buffer; + LOCK(); - buffer = ISC_LIST_HEAD(free_recv_list); - if (buffer != NULL) - { - ISC_LIST_DEQUEUE(free_recv_list, buffer, link); + UNLINK_HEAD_SLIST(buffer, free_recv_list, link.next); + if (buffer != NULL) { free_recvbufs--; initialise_buffer(buffer); (buffer->used)++; - } - else - { + } else buffer_shortfall++; - } UNLOCK(); return (buffer); } @@ -180,12 +207,14 @@ recvbuf_t * get_free_recv_buffer_alloc(void) { - recvbuf_t * buffer = get_free_recv_buffer(); - if (buffer == NULL) - { + recvbuf_t *buffer; + + buffer = get_free_recv_buffer(); + if (NULL == buffer) { create_buffers(RECV_INC); buffer = get_free_recv_buffer(); } + NTP_ENSURE(buffer != NULL); return (buffer); } #endif @@ -199,14 +228,13 @@ #ifdef HAVE_SIGNALED_IO /* * make sure there are free buffers when we - * wander off to do lengthy paket processing with + * wander off to do lengthy packet processing with * any buffer we grab from the full list. * * fixes malloc() interrupted by SIGIO risk * (Bug 889) */ - rbuf = ISC_LIST_HEAD(free_recv_list); - if (rbuf == NULL || buffer_shortfall > 0) { + if (NULL == free_recv_list || buffer_shortfall > 0) { /* * try to get us some more buffers */ @@ -218,18 +246,14 @@ * try to grab a full buffer */ rbuf = ISC_LIST_HEAD(full_recv_list); - if (rbuf != NULL) - { - ISC_LIST_DEQUEUE(full_recv_list, rbuf, link); + if (rbuf != NULL) { + ISC_LIST_DEQUEUE_TYPE(full_recv_list, rbuf, link, recvbuf_t); --full_recvbufs; - } - else - { + } else /* * Make sure we reset the full count to 0 */ full_recvbufs = 0; - } UNLOCK(); return (rbuf); } diff -urN src/contrib/ntp/libntp/refnumtoa.c src.ntp/contrib/ntp/libntp/refnumtoa.c --- src/contrib/ntp/libntp/refnumtoa.c 2004-07-20 17:01:21.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/refnumtoa.c 2009-12-09 08:36:35.000000000 +0100 @@ -3,13 +3,13 @@ */ #include -#include "ntp_fp.h" +#include "ntp_net.h" #include "lib_strbuf.h" #include "ntp_stdlib.h" char * refnumtoa( - struct sockaddr_storage* num + sockaddr_u *num ) { register u_int32 netnum; @@ -18,19 +18,19 @@ LIB_GETBUF(buf); - if(num->ss_family == AF_INET) { - netnum = ntohl(((struct sockaddr_in*)num)->sin_addr.s_addr); + if (ISREFCLOCKADR(num)) { + netnum = SRCADR(num); rclock = clockname((int)((u_long)netnum >> 8) & 0xff); if (rclock != NULL) - (void)sprintf(buf, "%s(%lu)", rclock, (u_long)netnum & 0xff); + snprintf(buf, LIB_BUFLENGTH, "%s(%lu)", + rclock, (u_long)netnum & 0xff); else - (void)sprintf(buf, "REFCLK(%lu,%lu)", - ((u_long)netnum >> 8) & 0xff, (u_long)netnum & 0xff); + snprintf(buf, LIB_BUFLENGTH, "REFCLK(%lu,%lu)", + ((u_long)netnum >> 8) & 0xff, + (u_long)netnum & 0xff); } - else { - (void)sprintf(buf, "refclock address type not implemented yet, use IPv4 refclock address."); - } + return buf; } diff -urN src/contrib/ntp/libntp/socktoa.c src.ntp/contrib/ntp/libntp/socktoa.c --- src/contrib/ntp/libntp/socktoa.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/socktoa.c 2009-12-09 08:36:35.000000000 +0100 @@ -2,11 +2,17 @@ * socktoa - return a numeric host name from a sockaddr_storage structure */ +#ifdef HAVE_CONFIG_H #include +#endif #include +#ifdef HAVE_SYS_SOCKET_H #include +#endif +#ifdef HAVE_NETINET_IN_H #include +#endif #include @@ -23,34 +29,34 @@ char * socktoa( - struct sockaddr_storage* sock + sockaddr_u *sock ) { register char *buffer; LIB_GETBUF(buffer); - if (sock == NULL) - strcpy(buffer, "null"); - else - { - - switch(sock->ss_family) { + if (NULL == sock) + strncpy(buffer, "(null)", LIB_BUFLENGTH); + else { + switch(AF(sock)) { + + case AF_INET: + case AF_UNSPEC: + inet_ntop(AF_INET, PSOCK_ADDR4(sock), buffer, + LIB_BUFLENGTH); + break; - default: - case AF_INET : - inet_ntop(AF_INET, &GET_INADDR(*sock), buffer, - LIB_BUFLENGTH); + case AF_INET6: + inet_ntop(AF_INET6, PSOCK_ADDR6(sock), buffer, + LIB_BUFLENGTH); break; - case AF_INET6 : - inet_ntop(AF_INET6, &GET_INADDR6(*sock), buffer, - LIB_BUFLENGTH); -#if 0 default: - strcpy(buffer, "unknown"); -#endif + snprintf(buffer, LIB_BUFLENGTH, + "(socktoa unknown family %d)", + AF(sock)); } } - return buffer; + return buffer; } diff -urN src/contrib/ntp/libntp/socktohost.c src.ntp/contrib/ntp/libntp/socktohost.c --- src/contrib/ntp/libntp/socktohost.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/socktohost.c 2009-12-09 08:36:35.000000000 +0100 @@ -2,8 +2,12 @@ * socktoa - return a numeric host name from a sockaddr_storage structure */ #include +#ifdef HAVE_SYS_SOCKET_H #include +#endif +#ifdef HAVE_NETINET_IN_H #include +#endif #include @@ -17,15 +21,15 @@ char * socktohost( - struct sockaddr_storage* sock + sockaddr_u *sock ) { register char *buffer; LIB_GETBUF(buffer); - if (getnameinfo((struct sockaddr *)sock, SOCKLEN(sock), buffer, - LIB_BUFLENGTH /* NI_MAXHOST*/, NULL, 0, 0)) + if (getnameinfo(&sock->sa, SOCKLEN(sock), buffer, + LIB_BUFLENGTH, NULL, 0, 0)) return stoa(sock); - return buffer; + return buffer; } diff -urN src/contrib/ntp/libntp/ssl_init.c src.ntp/contrib/ntp/libntp/ssl_init.c --- src/contrib/ntp/libntp/ssl_init.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/libntp/ssl_init.c 2010-07-07 12:01:06.000000000 +0200 @@ -0,0 +1,171 @@ +/* + * ssl_init.c Common OpenSSL initialization code for the various + * programs which use it. + * + * Moved from ntpd/ntp_crypto.c crypto_setup() + */ +#ifdef HAVE_CONFIG_H +#include +#endif +#include +#include +#include +#include + +#ifdef OPENSSL +#include "openssl/err.h" +#include "openssl/rand.h" + + +int ssl_init_done; + +void +ssl_init(void) +{ + if (ssl_init_done) + return; + + ERR_load_crypto_strings(); + OpenSSL_add_all_algorithms(); + + ssl_init_done = 1; +} + + +void +ssl_check_version(void) +{ + if ((SSLeay() ^ OPENSSL_VERSION_NUMBER) & ~0xff0L) { + msyslog(LOG_WARNING, + "OpenSSL version mismatch. Built against %lx, you have %lx", + OPENSSL_VERSION_NUMBER, SSLeay()); + fprintf(stderr, + "OpenSSL version mismatch. Built against %lx, you have %lx\n", + OPENSSL_VERSION_NUMBER, SSLeay()); + } + + INIT_SSL(); +} +#endif /* OPENSSL */ + + +/* + * keytype_from_text returns OpenSSL NID for digest by name, and + * optionally the associated digest length. + * + * Used by ntpd authreadkeys(), ntpq and ntpdc keytype() + */ +int +keytype_from_text( + const char *text, + size_t *pdigest_len + ) +{ + const u_long max_digest_len = MAX_MAC_LEN - sizeof(keyid_t); + int key_type; + u_int digest_len; +#ifdef OPENSSL + u_char digest[EVP_MAX_MD_SIZE]; + char * upcased; + char * pch; + EVP_MD_CTX ctx; + + /* + * OpenSSL digest short names are capitalized, so uppercase the + * digest name before passing to OBJ_sn2nid(). If it is not + * recognized but begins with 'M' use NID_md5 to be consistent + * with past behavior. + */ + INIT_SSL(); + LIB_GETBUF(upcased); + strncpy(upcased, text, LIB_BUFLENGTH); + for (pch = upcased; '\0' != *pch; pch++) + *pch = (char)toupper(*pch); + key_type = OBJ_sn2nid(upcased); +#else + key_type = 0; +#endif + + if (!key_type && 'm' == tolower(text[0])) + key_type = NID_md5; + + if (!key_type) + return 0; + + if (NULL != pdigest_len) { +#ifdef OPENSSL + EVP_DigestInit(&ctx, EVP_get_digestbynid(key_type)); + EVP_DigestFinal(&ctx, digest, &digest_len); + if (digest_len + sizeof(keyid_t) > MAX_MAC_LEN) { + fprintf(stderr, + "key type %s %u octet digests are too big, max %lu\n", + keytype_name(key_type), digest_len, + max_digest_len); + msyslog(LOG_ERR, + "key type %s %u octet digests are too big, max %lu\n", + keytype_name(key_type), digest_len, + max_digest_len); + return 0; + } +#else + digest_len = 16; +#endif + *pdigest_len = digest_len; + } + + return key_type; +} + + +/* + * keytype_name returns OpenSSL short name for digest by NID. + * + * Used by ntpq and ntpdc keytype() + */ +const char * +keytype_name( + int nid + ) +{ + static const char unknown_type[] = "(unknown key type)"; + const char *name; + +#ifdef OPENSSL + INIT_SSL(); + name = OBJ_nid2sn(nid); + if (NULL == name) + name = unknown_type; +#else /* !OPENSSL follows */ + if (NID_md5 == nid) + name = "MD5"; + else + name = unknown_type; +#endif + return name; +} + + +/* + * Use getpassphrase() if configure.ac detected it, as Suns that + * have it truncate the password in getpass() to 8 characters. + */ +#ifdef HAVE_GETPASSPHRASE +# define getpass(str) getpassphrase(str) +#endif + +/* + * getpass_keytype() -- shared between ntpq and ntpdc, only vaguely + * related to the rest of ssl_init.c. + */ +char * +getpass_keytype( + int keytype + ) +{ + char pass_prompt[64 + 11 + 1]; /* 11 for " Password: " */ + + snprintf(pass_prompt, sizeof(pass_prompt), + "%.64s Password: ", keytype_name(keytype)); + + return getpass(pass_prompt); +} diff -urN src/contrib/ntp/libntp/statestr.c src.ntp/contrib/ntp/libntp/statestr.c --- src/contrib/ntp/libntp/statestr.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/statestr.c 2009-12-09 08:36:35.000000000 +0100 @@ -22,105 +22,143 @@ }; /* - * Leap values + * Leap status (leap) */ static struct codestring leap_codes[] = { { LEAP_NOWARNING, "leap_none" }, { LEAP_ADDSECOND, "leap_add_sec" }, { LEAP_DELSECOND, "leap_del_sec" }, - { LEAP_NOTINSYNC, "sync_alarm" }, - { -1, "leap" } + { LEAP_NOTINSYNC, "leap_alarm" }, + { -1, "leap" } }; /* - * Clock source + * Clock source status (sync) */ static struct codestring sync_codes[] = { { CTL_SST_TS_UNSPEC, "sync_unspec" }, - { CTL_SST_TS_ATOM, "sync_atomic" }, - { CTL_SST_TS_LF, "sync_lf_clock" }, - { CTL_SST_TS_HF, "sync_hf_clock" }, - { CTL_SST_TS_UHF, "sync_uhf_clock" }, - { CTL_SST_TS_LOCAL, "sync_local_proto" }, + { CTL_SST_TS_ATOM, "sync_pps" }, + { CTL_SST_TS_LF, "sync_lf_radio" }, + { CTL_SST_TS_HF, "sync_hf_radio" }, + { CTL_SST_TS_UHF, "sync_uhf_radio" }, + { CTL_SST_TS_LOCAL, "sync_local" }, { CTL_SST_TS_NTP, "sync_ntp" }, - { CTL_SST_TS_UDPTIME, "sync_udp/time" }, + { CTL_SST_TS_UDPTIME, "sync_other" }, { CTL_SST_TS_WRSTWTCH, "sync_wristwatch" }, { CTL_SST_TS_TELEPHONE, "sync_telephone" }, { -1, "sync" } }; - /* - * Peer selection + * Peer selection status (sel) */ static struct codestring select_codes[] = { - { CTL_PST_SEL_REJECT, "selreject" }, + { CTL_PST_SEL_REJECT, "sel_reject" }, { CTL_PST_SEL_SANE, "sel_falsetick" }, { CTL_PST_SEL_CORRECT, "sel_excess" }, { CTL_PST_SEL_SELCAND, "sel_outlyer" }, - { CTL_PST_SEL_SYNCCAND, "sel_candidat" }, - { CTL_PST_SEL_DISTSYSPEER, "sel_selected" }, + { CTL_PST_SEL_SYNCCAND, "sel_candidate" }, + { CTL_PST_SEL_EXCESS, "sel_backup" }, { CTL_PST_SEL_SYSPEER, "sel_sys.peer" }, { CTL_PST_SEL_PPS, "sel_pps.peer" }, { -1, "sel" } }; - /* - * Clock status + * Clock status (clk) */ static struct codestring clock_codes[] = { - { CTL_CLK_OKAY, "clk_okay" }, - { CTL_CLK_NOREPLY, "clk_noreply" }, - { CTL_CLK_BADFORMAT, "clk_badformat" }, + { CTL_CLK_OKAY, "clk_unspec" }, + { CTL_CLK_NOREPLY, "clk_no_reply" }, + { CTL_CLK_BADFORMAT, "clk_bad_format" }, { CTL_CLK_FAULT, "clk_fault" }, - { CTL_CLK_PROPAGATION, "clk_badsignal" }, - { CTL_CLK_BADDATE, "clk_baddate" }, - { CTL_CLK_BADTIME, "clk_badtime" }, + { CTL_CLK_PROPAGATION, "clk_bad_signal" }, + { CTL_CLK_BADDATE, "clk_bad_date" }, + { CTL_CLK_BADTIME, "clk_bad_time" }, { -1, "clk" } }; +#ifdef FLASH_CODES_UNUSED +/* + * Flash bits -- see ntpq.c tstflags & tstflagnames + */ +static +struct codestring flash_codes[] = { + { TEST1, "pkt_dup" }, + { TEST2, "pkt_bogus" }, + { TEST3, "pkt_unsync" }, + { TEST4, "pkt_denied" }, + { TEST5, "pkt_auth" }, + { TEST6, "pkt_stratum" }, + { TEST7, "pkt_header" }, + { TEST8, "pkt_autokey" }, + { TEST9, "pkt_crypto" }, + { TEST10, "peer_stratum" }, + { TEST11, "peer_dist" }, + { TEST12, "peer_loop" }, + { TEST13, "peer_unreach" }, + { -1, "flash" } +}; +#endif + + /* - * System Events + * System events (sys) */ static struct codestring sys_codes[] = { - { EVNT_UNSPEC, "event_unspec" }, - { EVNT_SYSRESTART, "event_restart" }, - { EVNT_SYSFAULT, "event_fault" }, - { EVNT_SYNCCHG, "event_sync_chg" }, - { EVNT_PEERSTCHG, "event_peer/strat_chg" }, - { EVNT_CLOCKRESET, "event_clock_reset" }, - { EVNT_BADDATETIM, "event_bad_date" }, - { EVNT_CLOCKEXCPT, "event_clock_excptn" }, - { -1, "event" } + { EVNT_UNSPEC, "unspecified" }, + { EVNT_NSET, "freq_not_set" }, + { EVNT_FSET, "freq_set" }, + { EVNT_SPIK, "spike_detect" }, + { EVNT_FREQ, "freq_mode" }, + { EVNT_SYNC, "clock_sync" }, + { EVNT_SYSRESTART, "restart" }, + { EVNT_SYSFAULT, "panic_stop" }, + { EVNT_NOPEER, "no_sys_peer" }, + { EVNT_ARMED, "leap_armed" }, + { EVNT_DISARMED, "leap_disarmed" }, + { EVNT_LEAP, "leap_event" }, + { EVNT_CLOCKRESET, "clock_step" }, + { EVNT_KERN, "kern" }, + { EVNT_TAI, "TAI" }, + { EVNT_LEAPVAL, "stale_leapsecond_values" }, + { EVNT_CLKHOP, "clockhop" }, + { -1, "" } }; /* - * Peer events + * Peer events (peer) */ static struct codestring peer_codes[] = { - { EVNT_UNSPEC, "event_unspec" }, - { EVNT_PEERIPERR & ~PEER_EVENT, "event_ip_err" }, - { EVNT_PEERAUTH & ~PEER_EVENT, "event_authen" }, - { EVNT_UNREACH & ~PEER_EVENT, "event_unreach" }, - { EVNT_REACH & ~PEER_EVENT, "event_reach" }, - { EVNT_PEERCLOCK & ~PEER_EVENT, "event_peer_clock" }, -#if 0 - { EVNT_PEERSTRAT & ~PEER_EVENT, "event_stratum_chg" }, -#endif - { -1, "event" } + { PEVNT_MOBIL & ~PEER_EVENT, "mobilize" }, + { PEVNT_DEMOBIL & ~PEER_EVENT, "demobilize" }, + { PEVNT_UNREACH & ~PEER_EVENT, "unreachable" }, + { PEVNT_REACH & ~PEER_EVENT, "reachable" }, + { PEVNT_RESTART & ~PEER_EVENT, "restart" }, + { PEVNT_REPLY & ~PEER_EVENT, "no_reply" }, + { PEVNT_RATE & ~PEER_EVENT, "rate_exceeded" }, + { PEVNT_DENY & ~PEER_EVENT, "access_denied" }, + { PEVNT_ARMED & ~PEER_EVENT, "leap_armed" }, + { PEVNT_NEWPEER & ~PEER_EVENT, "sys_peer" }, + { PEVNT_CLOCK & ~PEER_EVENT, "clock_event" }, + { PEVNT_AUTH & ~PEER_EVENT, "bad_auth" }, + { PEVNT_POPCORN & ~PEER_EVENT, "popcorn" }, + { PEVNT_XLEAVE & ~PEER_EVENT, "interleave_mode" }, + { PEVNT_XERR & ~PEER_EVENT, "interleave_error" }, + { PEVNT_TAI & ~PEER_EVENT, "TAI" }, + { -1, "" } }; #ifdef OPENSSL /* - * Crypto events + * Crypto events (cryp) */ static struct codestring crypto_codes[] = { @@ -134,20 +172,19 @@ { XEVNT_SGL & ~CRPT_EVENT, "bad_signature_length" }, { XEVNT_SIG & ~CRPT_EVENT, "signature_not_verified" }, { XEVNT_VFY & ~CRPT_EVENT, "certificate_not_verified" }, - { XEVNT_PER & ~CRPT_EVENT, "host certificate_expired" }, + { XEVNT_PER & ~CRPT_EVENT, "host_certificate_expired" }, { XEVNT_CKY & ~CRPT_EVENT, "bad_or_missing_cookie" }, - { XEVNT_DAT & ~CRPT_EVENT, "bad_or_missing_leapsecond_table" }, + { XEVNT_DAT & ~CRPT_EVENT, "bad_or_missing_leapseconds" }, { XEVNT_CRT & ~CRPT_EVENT, "bad_or_missing_certificate" }, - { XEVNT_ID & ~CRPT_EVENT, "bad_or_missing_group_key" }, + { XEVNT_ID & ~CRPT_EVENT, "bad_or_missing_group key" }, { XEVNT_ERR & ~CRPT_EVENT, "protocol_error" }, - { XEVNT_SRV & ~CRPT_EVENT, "server certificate expired" }, - { -1, "crypto" } + { -1, "" } }; #endif /* OPENSSL */ /* Forwards */ -static const char *getcode P((int, struct codestring *)); -static const char *getevents P((int)); +static const char *getcode (int, struct codestring *); +static const char *getevents (int); /* * getcode - return string corresponding to code @@ -162,10 +199,10 @@ while (codetab->code != -1) { if (codetab->code == code) - return codetab->string; + return codetab->string; codetab++; } - (void) sprintf(buf, "%s_%d", codetab->string, code); + snprintf(buf, sizeof(buf), "%s_%d", codetab->string, code); return buf; } @@ -180,8 +217,9 @@ static char buf[20]; if (cnt == 0) - return "no events"; - (void) sprintf(buf, "%d event%s", cnt, (cnt==1) ? "" : "s"); + return "no events"; + snprintf(buf, sizeof(buf), "%d event%s", cnt, (cnt==1) ? "" : + "s"); return buf; } @@ -201,57 +239,69 @@ switch (type) { case TYPE_SYS: - (void)strcpy(cb, getcode(CTL_SYS_LI(st), leap_codes)); - (void)strcat(cb, ", "); - (void)strcat(cb, getcode(CTL_SYS_SOURCE(st) & ~CTL_SST_TS_PPS, sync_codes)); - if (CTL_SYS_SOURCE(st) & CTL_SST_TS_PPS) - (void)strcat(cb, "/PPS"); - (void)strcat(cb, ", "); - (void)strcat(cb, getevents(CTL_SYS_NEVNT(st))); - (void)strcat(cb, ", "); - (void)strcat(cb, getcode(CTL_SYS_EVENT(st), sys_codes)); + strcpy(cb, getcode(CTL_SYS_LI(st), leap_codes)); + strcat(cb, ", "); + strcat(cb, getcode(CTL_SYS_SOURCE(st), sync_codes)); + strcat(cb, ", "); + strcat(cb, getevents(CTL_SYS_NEVNT(st))); + strcat(cb, ", "); + strcat(cb, getcode(CTL_SYS_EVENT(st), sys_codes)); break; case TYPE_PEER: + /* * Handcraft the bits */ pst = (u_char) CTL_PEER_STATVAL(st); - if (!(pst & CTL_PST_REACH)) { - (void)strcpy(cb, "unreach"); - } else { - (void)strcpy(cb, "reach"); - - } if (pst & CTL_PST_CONFIG) - (void)strcat(cb, ", conf"); + strcpy(cb, "conf"); if (pst & CTL_PST_AUTHENABLE) { - if (!(pst & CTL_PST_REACH) || (pst & CTL_PST_AUTHENTIC)) - (void)strcat(cb, ", auth"); + if (pst & CTL_PST_CONFIG) + strcat(cb, ", authenb"); else - (void)strcat(cb, ", unauth"); + strcat(cb, "authenb"); + } + if (pst & CTL_PST_AUTHENTIC) { + if (pst & (CTL_PST_CONFIG | CTL_PST_AUTHENABLE)) + strcat(cb, ", auth"); + else + strcat(cb, "auth"); + } + if (pst & CTL_PST_REACH) { + if (pst & (CTL_PST_CONFIG | CTL_PST_AUTHENABLE | + CTL_PST_AUTHENTIC)) + strcat(cb, ", reach"); + else + strcat(cb, "reach"); + } + if (pst & CTL_PST_BCAST) { + if (pst & (CTL_PST_CONFIG | CTL_PST_AUTHENABLE | + CTL_PST_AUTHENTIC | CTL_PST_REACH)) + strcat(cb, ", bcst"); + else + strcat(cb, "bcst"); } /* * Now the codes */ - if ((pst & 0x7) != CTL_PST_SEL_REJECT) { - (void)strcat(cb, ", "); - (void)strcat(cb, getcode(pst & 0x7, select_codes)); - } - (void)strcat(cb, ", "); - (void)strcat(cb, getevents(CTL_PEER_NEVNT(st))); + strcat(cb, ", "); + strcat(cb, getcode(pst & 0x7, select_codes)); + strcat(cb, ", "); + strcat(cb, getevents(CTL_PEER_NEVNT(st))); if (CTL_PEER_EVENT(st) != EVNT_UNSPEC) { - (void)strcat(cb, ", "); - (void)strcat(cb, getcode(CTL_PEER_EVENT(st), - peer_codes)); + strcat(cb, ", "); + strcat(cb, getcode(CTL_PEER_EVENT(st), + peer_codes)); } break; case TYPE_CLOCK: - (void)strcpy(cb, getcode(((st)>>8) & 0xff, clock_codes)); - (void)strcat(cb, ", last_"); - (void)strcat(cb, getcode((st) & 0xff, clock_codes)); + strcat(cb, ", "); + strcat(cb, getevents(CTL_SYS_NEVNT(st))); + strcat(cb, ", "); + strcat(cb, getcode((st) & 0xf, clock_codes)); break; } return cb; @@ -279,27 +329,3 @@ { return getcode(num, clock_codes); } - -const char * -sysstatstr( - int status - ) -{ - return statustoa(TYPE_SYS, status); -} - -const char * -peerstatstr( - int status - ) -{ - return statustoa(TYPE_PEER, status); -} - -const char * -clockstatstr( - int status - ) -{ - return statustoa(TYPE_CLOCK, status); -} diff -urN src/contrib/ntp/libntp/strerror.c src.ntp/contrib/ntp/libntp/strerror.c --- src/contrib/ntp/libntp/strerror.c 2004-07-20 17:01:21.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/strerror.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,48 +0,0 @@ -#include - -#if !HAVE_STRERROR -/* - * Copyright (c) 1988 Regents of the University of California. - * All rights reserved. - * - * Redistribution and use in source and binary forms are permitted - * provided that the above copyright notice and this paragraph are - * duplicated in all such forms and that any documentation, - * advertising materials, and other materials related to such - * distribution and use acknowledge that the software was developed - * by the University of California, Berkeley. The name of the - * University may not be used to endorse or promote products derived - * from this software without specific prior written permission. - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR - * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED - * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. - */ - -#if defined(LIBC_SCCS) && !defined(lint) -static const char sccsid[] = "@(#)strerror.c 5.1 (Berkeley) 4/9/89"; -#endif /* LIBC_SCCS and not lint */ - -#include - -#include -#include - -#include "l_stdlib.h" - -char * -strerror( - int errnum - ) -{ - extern int sys_nerr; - extern char *sys_errlist[]; - static char ebuf[20]; - - if ((unsigned int)errnum < sys_nerr) - return(sys_errlist[errnum]); - (void)sprintf(ebuf, "Unknown error: %d", errnum); - return(ebuf); -} -#else -int strerror_bs; -#endif diff -urN src/contrib/ntp/libntp/syssignal.c src.ntp/contrib/ntp/libntp/syssignal.c --- src/contrib/ntp/libntp/syssignal.c 2000-01-28 15:52:23.000000000 +0100 +++ src.ntp/contrib/ntp/libntp/syssignal.c 2009-12-09 08:36:35.000000000 +0100 @@ -23,7 +23,7 @@ #if defined(__STDC__) || defined(HAVE_STDARG_H) #else int sig; - void (*func) P((int)); + void (*func) (int); #endif { int n; diff -urN src/contrib/ntp/libntp/systime.c src.ntp/contrib/ntp/libntp/systime.c --- src/contrib/ntp/libntp/systime.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/systime.c 2009-12-09 08:36:35.000000000 +0100 @@ -12,10 +12,6 @@ #include "ntp_random.h" #include "ntpd.h" /* for sys_precision */ -#ifdef SIM -# include "ntpsim.h" -#endif /*SIM */ - #ifdef HAVE_SYS_PARAM_H # include #endif @@ -26,24 +22,33 @@ # include #endif /* HAVE_UTMPX_H */ + +#define FUZZ 500e-6 /* fuzz pivot */ + /* * These routines (get_systime, step_systime, adj_systime) implement an * interface between the system independent NTP clock and the Unix - * system clock in various architectures and operating systems. + * system clock in various architectures and operating systems. Time is + * a precious quantity in these routines and every effort is made to + * minimize errors by unbiased rounding and amortizing adjustment + * residues. + * + * In order to improve the apparent resolution, provide unbiased + * rounding and insure that the readings cannot be predicted, the low- + * order unused portion of the time below the resolution limit is filled + * with an unbiased random fuzz. * - * Time is a precious quantity in these routines and every effort is - * made to minimize errors by always rounding toward zero and amortizing - * adjustment residues. By default the adjustment quantum is 1 us for - * the usual Unix tickadj() system call, but this can be increased if - * necessary by the tick configuration command. For instance, when the - * adjtime() quantum is a clock tick for a 100-Hz clock, the quantum - * should be 10 ms. + * The sys_tick variable secifies the system clock tick interval in + * seconds. For systems that can interpolate between timer interrupts, + * the resolution is presumed much less than the time to read the system + * clock, which is the value of sys_tick after the precision has been + * determined. For those systems that cannot interpolate between timer + * interrupts, sys_tick will be much larger in the order of 10 ms, so the + * fuzz should be that value. For Sunses the tick is not interpolated, but + * the system clock is derived from a 2-MHz oscillator, so the resolution + * is 500 ns and sys_tick is 500 ns. */ -#if defined RELIANTUNIX_CLOCK || defined SCO5_CLOCK -double sys_tick = 10e-3; /* 10 ms tickadj() */ -#else -double sys_tick = 1e-6; /* 1 us tickadj() */ -#endif +double sys_tick = 0; /* precision (time to read the clock) */ double sys_residual = 0; /* adjustment residue (s) */ #ifndef SIM @@ -56,59 +61,61 @@ l_fp *now /* system time */ ) { - double dtemp; + double dtemp; #if defined(HAVE_CLOCK_GETTIME) || defined(HAVE_GETCLOCK) struct timespec ts; /* seconds and nanoseconds */ /* - * Convert Unix clock from seconds and nanoseconds to seconds. - * The bottom is only two bits down, so no need for fuzz. - * Some systems don't have that level of precision, however... + * Convert Unix timespec from seconds and nanoseconds to NTP + * seconds and fraction. */ # ifdef HAVE_CLOCK_GETTIME clock_gettime(CLOCK_REALTIME, &ts); # else getclock(TIMEOFDAY, &ts); # endif - now->l_i = ts.tv_sec + JAN_1970; - dtemp = ts.tv_nsec / 1e9; + now->l_i = (int32)ts.tv_sec + JAN_1970; + dtemp = 0; + if (sys_tick > FUZZ) + dtemp = ntp_random() * 2. / FRAC * sys_tick * 1e9; + else if (sys_tick > 0) + dtemp = ntp_random() * 2. / FRAC; + dtemp = (ts.tv_nsec + dtemp) * 1e-9 + sys_residual; + if (dtemp >= 1.) { + dtemp -= 1.; + now->l_i++; + } else if (dtemp < 0) { + dtemp += 1.; + now->l_i--; + } + now->l_uf = (u_int32)(dtemp * FRAC); #else /* HAVE_CLOCK_GETTIME || HAVE_GETCLOCK */ struct timeval tv; /* seconds and microseconds */ /* - * Convert Unix clock from seconds and microseconds to seconds. - * Add in unbiased random fuzz beneath the microsecond. + * Convert Unix timeval from seconds and microseconds to NTP + * seconds and fraction. */ GETTIMEOFDAY(&tv, NULL); now->l_i = tv.tv_sec + JAN_1970; - dtemp = tv.tv_usec / 1e6; - -#endif /* HAVE_CLOCK_GETTIME || HAVE_GETCLOCK */ - - /* - * ntp_random() produces 31 bits (always nonnegative). - * This bit is done only after the precision has been - * determined. - */ - if (sys_precision != 0) - dtemp += (ntp_random() / FRAC - .5) / (1 << - -sys_precision); - - /* - * Renormalize to seconds past 1900 and fraction. - */ - dtemp += sys_residual; - if (dtemp >= 1) { - dtemp -= 1; + dtemp = 0; + if (sys_tick > FUZZ) + dtemp = ntp_random() * 2. / FRAC * sys_tick * 1e6; + else if (sys_tick > 0) + dtemp = ntp_random() * 2. / FRAC; + dtemp = (tv.tv_usec + dtemp) * 1e-6 + sys_residual; + if (dtemp >= 1.) { + dtemp -= 1.; now->l_i++; } else if (dtemp < 0) { - dtemp += 1; + dtemp += 1.; now->l_i--; } - dtemp *= FRAC; - now->l_uf = (u_int32)dtemp; + now->l_uf = (u_int32)(dtemp * FRAC); + +#endif /* HAVE_CLOCK_GETTIME || HAVE_GETCLOCK */ } @@ -363,180 +370,11 @@ /* * Clock routines for the simulator - Harish Nair, with help */ -/* - * get_systime - return the system time in NTP timestamp format - */ -void -get_systime( - l_fp *now /* current system time in l_fp */ ) -{ - /* - * To fool the code that determines the local clock precision, - * we advance the clock a minimum of 200 nanoseconds on every - * clock read. This is appropriate for a typical modern machine - * with nanosecond clocks. Note we make no attempt here to - * simulate reading error, since the error is so small. This may - * change when the need comes to implement picosecond clocks. - */ - if (ntp_node.ntp_time == ntp_node.last_time) - ntp_node.ntp_time += 200e-9; - ntp_node.last_time = ntp_node.ntp_time; - DTOLFP(ntp_node.ntp_time, now); -} - - -/* - * adj_systime - advance or retard the system clock exactly like the - * real thng. - */ -int /* always succeeds */ -adj_systime( - double now /* time adjustment (s) */ - ) -{ - struct timeval adjtv; /* new adjustment */ - double dtemp; - long ticks; - int isneg = 0; - - /* - * Most Unix adjtime() implementations adjust the system clock - * in microsecond quanta, but some adjust in 10-ms quanta. We - * carefully round the adjustment to the nearest quantum, then - * adjust in quanta and keep the residue for later. - */ - dtemp = now + sys_residual; - if (dtemp < 0) { - isneg = 1; - dtemp = -dtemp; - } - adjtv.tv_sec = (long)dtemp; - dtemp -= adjtv.tv_sec; - ticks = (long)(dtemp / sys_tick + .5); - adjtv.tv_usec = (long)(ticks * sys_tick * 1e6); - dtemp -= adjtv.tv_usec / 1e6; - sys_residual = dtemp; - - /* - * Convert to signed seconds and microseconds for the Unix - * adjtime() system call. Note we purposely lose the adjtime() - * leftover. - */ - if (isneg) { - adjtv.tv_sec = -adjtv.tv_sec; - adjtv.tv_usec = -adjtv.tv_usec; - sys_residual = -sys_residual; - } - ntp_node.adj = now; - return (1); -} - - -/* - * step_systime - step the system clock. We are religious here. - */ -int /* always succeeds */ -step_systime( - double now /* step adjustment (s) */ - ) -{ -#ifdef DEBUG - if (debug) - printf("step_systime: time %.6f adj %.6f\n", - ntp_node.ntp_time, now); -#endif - ntp_node.ntp_time += now; - return (1); -} - -/* - * node_clock - update the clocks - */ -int /* always succeeds */ -node_clock( - Node *n, /* global node pointer */ - double t /* node time */ - ) -{ - double dtemp; - - /* - * Advance client clock (ntp_time). Advance server clock - * (clk_time) adjusted for systematic and random frequency - * errors. The random error is a random walk computed as the - * integral of samples from a Gaussian distribution. - */ - dtemp = t - n->ntp_time; - n->time = t; - n->ntp_time += dtemp; - n->ferr += gauss(0, dtemp * n->fnse); - n->clk_time += dtemp * (1 + n->ferr); - - /* - * Perform the adjtime() function. If the adjustment completed - * in the previous interval, amortize the entire amount; if not, - * carry the leftover to the next interval. - */ - dtemp *= n->slew; - if (dtemp < fabs(n->adj)) { - if (n->adj < 0) { - n->adj += dtemp; - n->ntp_time -= dtemp; - } else { - n->adj -= dtemp; - n->ntp_time += dtemp; - } - } else { - n->ntp_time += n->adj; - n->adj = 0; - } - return (0); -} - - -/* - * gauss() - returns samples from a gaussion distribution - */ -double /* Gaussian sample */ -gauss( - double m, /* sample mean */ - double s /* sample standard deviation (sigma) */ - ) -{ - double q1, q2; - /* - * Roll a sample from a Gaussian distribution with mean m and - * standard deviation s. For m = 0, s = 1, mean(y) = 0, - * std(y) = 1. - */ - if (s == 0) - return (m); - while ((q1 = drand48()) == 0); - q2 = drand48(); - return (m + s * sqrt(-2. * log(q1)) * cos(2. * PI * q2)); -} - -/* - * poisson() - returns samples from a network delay distribution +/* SK: + * The code that used to be here has been moved to ntpsim.c, + * where, IMHO, it rightfully belonged. */ -double /* delay sample (s) */ -poisson( - double m, /* fixed propagation delay (s) */ - double s /* exponential parameter (mu) */ - ) -{ - double q1; - /* - * Roll a sample from a composite distribution with propagation - * delay m and exponential distribution time with parameter s. - * For m = 0, s = 1, mean(y) = std(y) = 1. - */ - if (s == 0) - return (m); - while ((q1 = drand48()) == 0); - return (m - s * log(q1 * s)); -} -#endif /* SIM */ +#endif diff -urN src/contrib/ntp/libntp/tvtoa.c src.ntp/contrib/ntp/libntp/tvtoa.c --- src/contrib/ntp/libntp/tvtoa.c 2001-08-29 16:35:11.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/tvtoa.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,39 +0,0 @@ -/* - * tvtoa - return an asciized representation of a struct timeval - */ - -#include "lib_strbuf.h" - -#if defined(VMS) -# include "ntp_fp.h" -#endif /* VMS */ -#include "ntp_stdlib.h" -#include "ntp_unixtime.h" - -#include - -char * -tvtoa( - const struct timeval *tv - ) -{ - register char *buf; - register u_long sec; - register u_long usec; - register int isneg; - - if (tv->tv_sec < 0 || tv->tv_usec < 0) { - sec = -tv->tv_sec; - usec = -tv->tv_usec; - isneg = 1; - } else { - sec = tv->tv_sec; - usec = tv->tv_usec; - isneg = 0; - } - - LIB_GETBUF(buf); - - (void) sprintf(buf, "%s%lu.%06lu", (isneg?"-":""), sec, usec); - return buf; -} diff -urN src/contrib/ntp/libntp/uglydate.c src.ntp/contrib/ntp/libntp/uglydate.c --- src/contrib/ntp/libntp/uglydate.c 2001-08-29 16:35:11.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/uglydate.c 2010-02-04 08:26:52.000000000 +0100 @@ -41,8 +41,10 @@ while (year >= 100) year -= 100; } - (void) sprintf(bp, "%17s %02d:%03d:%02d:%02d:%02d.%03ld", - timep, year, tm->tm_yday, tm->tm_hour, tm->tm_min, - tm->tm_sec, msec); + snprintf(bp, LIB_BUFLENGTH, + "%17s %02d:%03d:%02d:%02d:%02d.%03ld", timep, year, + tm->tm_yday, tm->tm_hour, tm->tm_min, tm->tm_sec, + msec); + return bp; } diff -urN src/contrib/ntp/libntp/uinttoa.c src.ntp/contrib/ntp/libntp/uinttoa.c --- src/contrib/ntp/libntp/uinttoa.c 1999-12-09 14:01:10.000000000 +0100 +++ src.ntp/contrib/ntp/libntp/uinttoa.c 2010-02-04 08:26:58.000000000 +0100 @@ -14,7 +14,7 @@ register char *buf; LIB_GETBUF(buf); + snprintf(buf, LIB_BUFLENGTH, "%lu", uval); - (void) sprintf(buf, "%lu", (u_long)uval); return buf; } diff -urN src/contrib/ntp/libntp/utvtoa.c src.ntp/contrib/ntp/libntp/utvtoa.c --- src/contrib/ntp/libntp/utvtoa.c 2001-08-29 16:35:11.000000000 +0200 +++ src.ntp/contrib/ntp/libntp/utvtoa.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,26 +0,0 @@ -/* - * utvtoa - return an asciized representation of an unsigned struct timeval - */ -#include - -#include "lib_strbuf.h" - -#if defined(VMS) -# include "ntp_fp.h" -#endif -#include "ntp_stdlib.h" -#include "ntp_unixtime.h" - -char * -utvtoa( - const struct timeval *tv - ) -{ - register char *buf; - - LIB_GETBUF(buf); - - (void) sprintf(buf, "%lu.%06lu", (u_long)tv->tv_sec, - (u_long)tv->tv_usec); - return buf; -} diff -urN src/contrib/ntp/libopts/COPYING.gplv3 src.ntp/contrib/ntp/libopts/COPYING.gplv3 --- src/contrib/ntp/libopts/COPYING.gplv3 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/libopts/COPYING.gplv3 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,674 @@ + GNU GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 + + copyright (c) 2009 by Bruce Korb - all rights reserved + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The GNU General Public License is a free, copyleft license for +software and other kinds of works. + + The licenses for most software and other practical works are designed +to take away your freedom to share and change the works. By contrast, +the GNU General Public License is intended to guarantee your freedom to +share and change all versions of a program--to make sure it remains free +software for all its users. We, the Free Software Foundation, use the +GNU General Public License for most of our software; it applies also to +any other work released this way by its authors. You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +them if you wish), that you receive source code or can get it if you +want it, that you can change the software or use pieces of it in new +free programs, and that you know you can do these things. + + To protect your rights, we need to prevent others from denying you +these rights or asking you to surrender the rights. Therefore, you have +certain responsibilities if you distribute copies of the software, or if +you modify it: responsibilities to respect the freedom of others. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must pass on to the recipients the same +freedoms that you received. You must make sure that they, too, receive +or can get the source code. And you must show them these terms so they +know their rights. + + Developers that use the GNU GPL protect your rights with two steps: +(1) assert copyright on the software, and (2) offer you this License +giving you legal permission to copy, distribute and/or modify it. + + For the developers' and authors' protection, the GPL clearly explains +that there is no warranty for this free software. For both users' and +authors' sake, the GPL requires that modified versions be marked as +changed, so that their problems will not be attributed erroneously to +authors of previous versions. + + Some devices are designed to deny users access to install or run +modified versions of the software inside them, although the manufacturer +can do so. This is fundamentally incompatible with the aim of +protecting users' freedom to change the software. The systematic +pattern of such abuse occurs in the area of products for individuals to +use, which is precisely where it is most unacceptable. Therefore, we +have designed this version of the GPL to prohibit the practice for those +products. If such problems arise substantially in other domains, we +stand ready to extend this provision to those domains in future versions +of the GPL, as needed to protect the freedom of users. + + Finally, every program is threatened constantly by software patents. +States should not allow patents to restrict development and use of +software on general-purpose computers, but in those that do, we wish to +avoid the special danger that patents applied to a free program could +make it effectively proprietary. To prevent this, the GPL assures that +patents cannot be used to render the program non-free. + + The precise terms and conditions for copying, distribution and +modification follow. + + TERMS AND CONDITIONS + + 0. Definitions. + + "This License" refers to version 3 of the GNU General Public License. + + "Copyright" also means copyright-like laws that apply to other kinds of +works, such as semiconductor masks. + + "The Program" refers to any copyrightable work licensed under this +License. Each licensee is addressed as "you". "Licensees" and +"recipients" may be individuals or organizations. + + To "modify" a work means to copy from or adapt all or part of the work +in a fashion requiring copyright permission, other than the making of an +exact copy. The resulting work is called a "modified version" of the +earlier work or a work "based on" the earlier work. + + A "covered work" means either the unmodified Program or a work based +on the Program. + + To "propagate" a work means to do anything with it that, without +permission, would make you directly or secondarily liable for +infringement under applicable copyright law, except executing it on a +computer or modifying a private copy. Propagation includes copying, +distribution (with or without modification), making available to the +public, and in some countries other activities as well. + + To "convey" a work means any kind of propagation that enables other +parties to make or receive copies. Mere interaction with a user through +a computer network, with no transfer of a copy, is not conveying. + + An interactive user interface displays "Appropriate Legal Notices" +to the extent that it includes a convenient and prominently visible +feature that (1) displays an appropriate copyright notice, and (2) +tells the user that there is no warranty for the work (except to the +extent that warranties are provided), that licensees may convey the +work under this License, and how to view a copy of this License. If +the interface presents a list of user commands or options, such as a +menu, a prominent item in the list meets this criterion. + + 1. Source Code. + + The "source code" for a work means the preferred form of the work +for making modifications to it. "Object code" means any non-source +form of a work. + + A "Standard Interface" means an interface that either is an official +standard defined by a recognized standards body, or, in the case of +interfaces specified for a particular programming language, one that +is widely used among developers working in that language. + + The "System Libraries" of an executable work include anything, other +than the work as a whole, that (a) is included in the normal form of +packaging a Major Component, but which is not part of that Major +Component, and (b) serves only to enable use of the work with that +Major Component, or to implement a Standard Interface for which an +implementation is available to the public in source code form. A +"Major Component", in this context, means a major essential component +(kernel, window system, and so on) of the specific operating system +(if any) on which the executable work runs, or a compiler used to +produce the work, or an object code interpreter used to run it. + + The "Corresponding Source" for a work in object code form means all +the source code needed to generate, install, and (for an executable +work) run the object code and to modify the work, including scripts to +control those activities. However, it does not include the work's +System Libraries, or general-purpose tools or generally available free +programs which are used unmodified in performing those activities but +which are not part of the work. For example, Corresponding Source +includes interface definition files associated with source files for +the work, and the source code for shared libraries and dynamically +linked subprograms that the work is specifically designed to require, +such as by intimate data communication or control flow between those +subprograms and other parts of the work. + + The Corresponding Source need not include anything that users +can regenerate automatically from other parts of the Corresponding +Source. + + The Corresponding Source for a work in source code form is that +same work. + + 2. Basic Permissions. + + All rights granted under this License are granted for the term of +copyright on the Program, and are irrevocable provided the stated +conditions are met. This License explicitly affirms your unlimited +permission to run the unmodified Program. The output from running a +covered work is covered by this License only if the output, given its +content, constitutes a covered work. This License acknowledges your +rights of fair use or other equivalent, as provided by copyright law. + + You may make, run and propagate covered works that you do not +convey, without conditions so long as your license otherwise remains +in force. You may convey covered works to others for the sole purpose +of having them make modifications exclusively for you, or provide you +with facilities for running those works, provided that you comply with +the terms of this License in conveying all material for which you do +not control copyright. Those thus making or running the covered works +for you must do so exclusively on your behalf, under your direction +and control, on terms that prohibit them from making any copies of +your copyrighted material outside their relationship with you. + + Conveying under any other circumstances is permitted solely under +the conditions stated below. Sublicensing is not allowed; section 10 +makes it unnecessary. + + 3. Protecting Users' Legal Rights From Anti-Circumvention Law. + + No covered work shall be deemed part of an effective technological +measure under any applicable law fulfilling obligations under article +11 of the WIPO copyright treaty adopted on 20 December 1996, or +similar laws prohibiting or restricting circumvention of such +measures. + + When you convey a covered work, you waive any legal power to forbid +circumvention of technological measures to the extent such circumvention +is effected by exercising rights under this License with respect to +the covered work, and you disclaim any intention to limit operation or +modification of the work as a means of enforcing, against the work's +users, your or third parties' legal rights to forbid circumvention of +technological measures. + + 4. Conveying Verbatim Copies. + + You may convey verbatim copies of the Program's source code as you +receive it, in any medium, provided that you conspicuously and +appropriately publish on each copy an appropriate copyright notice; +keep intact all notices stating that this License and any +non-permissive terms added in accord with section 7 apply to the code; +keep intact all notices of the absence of any warranty; and give all +recipients a copy of this License along with the Program. + + You may charge any price or no price for each copy that you convey, +and you may offer support or warranty protection for a fee. + + 5. Conveying Modified Source Versions. + + You may convey a work based on the Program, or the modifications to +produce it from the Program, in the form of source code under the +terms of section 4, provided that you also meet all of these conditions: + + a) The work must carry prominent notices stating that you modified + it, and giving a relevant date. + + b) The work must carry prominent notices stating that it is + released under this License and any conditions added under section + 7. This requirement modifies the requirement in section 4 to + "keep intact all notices". + + c) You must license the entire work, as a whole, under this + License to anyone who comes into possession of a copy. This + License will therefore apply, along with any applicable section 7 + additional terms, to the whole of the work, and all its parts, + regardless of how they are packaged. This License gives no + permission to license the work in any other way, but it does not + invalidate such permission if you have separately received it. + + d) If the work has interactive user interfaces, each must display + Appropriate Legal Notices; however, if the Program has interactive + interfaces that do not display Appropriate Legal Notices, your + work need not make them do so. + + A compilation of a covered work with other separate and independent +works, which are not by their nature extensions of the covered work, +and which are not combined with it such as to form a larger program, +in or on a volume of a storage or distribution medium, is called an +"aggregate" if the compilation and its resulting copyright are not +used to limit the access or legal rights of the compilation's users +beyond what the individual works permit. Inclusion of a covered work +in an aggregate does not cause this License to apply to the other +parts of the aggregate. + + 6. Conveying Non-Source Forms. + + You may convey a covered work in object code form under the terms +of sections 4 and 5, provided that you also convey the +machine-readable Corresponding Source under the terms of this License, +in one of these ways: + + a) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by the + Corresponding Source fixed on a durable physical medium + customarily used for software interchange. + + b) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by a + written offer, valid for at least three years and valid for as + long as you offer spare parts or customer support for that product + model, to give anyone who possesses the object code either (1) a + copy of the Corresponding Source for all the software in the + product that is covered by this License, on a durable physical + medium customarily used for software interchange, for a price no + more than your reasonable cost of physically performing this + conveying of source, or (2) access to copy the + Corresponding Source from a network server at no charge. + + c) Convey individual copies of the object code with a copy of the + written offer to provide the Corresponding Source. This + alternative is allowed only occasionally and noncommercially, and + only if you received the object code with such an offer, in accord + with subsection 6b. + + d) Convey the object code by offering access from a designated + place (gratis or for a charge), and offer equivalent access to the + Corresponding Source in the same way through the same place at no + further charge. You need not require recipients to copy the + Corresponding Source along with the object code. If the place to + copy the object code is a network server, the Corresponding Source + may be on a different server (operated by you or a third party) + that supports equivalent copying facilities, provided you maintain + clear directions next to the object code saying where to find the + Corresponding Source. Regardless of what server hosts the + Corresponding Source, you remain obligated to ensure that it is + available for as long as needed to satisfy these requirements. + + e) Convey the object code using peer-to-peer transmission, provided + you inform other peers where the object code and Corresponding + Source of the work are being offered to the general public at no + charge under subsection 6d. + + A separable portion of the object code, whose source code is excluded +from the Corresponding Source as a System Library, need not be +included in conveying the object code work. + + A "User Product" is either (1) a "consumer product", which means any +tangible personal property which is normally used for personal, family, +or household purposes, or (2) anything designed or sold for incorporation +into a dwelling. In determining whether a product is a consumer product, +doubtful cases shall be resolved in favor of coverage. For a particular +product received by a particular user, "normally used" refers to a +typical or common use of that class of product, regardless of the status +of the particular user or of the way in which the particular user +actually uses, or expects or is expected to use, the product. A product +is a consumer product regardless of whether the product has substantial +commercial, industrial or non-consumer uses, unless such uses represent +the only significant mode of use of the product. + + "Installation Information" for a User Product means any methods, +procedures, authorization keys, or other information required to install +and execute modified versions of a covered work in that User Product from +a modified version of its Corresponding Source. The information must +suffice to ensure that the continued functioning of the modified object +code is in no case prevented or interfered with solely because +modification has been made. + + If you convey an object code work under this section in, or with, or +specifically for use in, a User Product, and the conveying occurs as +part of a transaction in which the right of possession and use of the +User Product is transferred to the recipient in perpetuity or for a +fixed term (regardless of how the transaction is characterized), the +Corresponding Source conveyed under this section must be accompanied +by the Installation Information. But this requirement does not apply +if neither you nor any third party retains the ability to install +modified object code on the User Product (for example, the work has +been installed in ROM). + + The requirement to provide Installation Information does not include a +requirement to continue to provide support service, warranty, or updates +for a work that has been modified or installed by the recipient, or for +the User Product in which it has been modified or installed. Access to a +network may be denied when the modification itself materially and +adversely affects the operation of the network or violates the rules and +protocols for communication across the network. + + Corresponding Source conveyed, and Installation Information provided, +in accord with this section must be in a format that is publicly +documented (and with an implementation available to the public in +source code form), and must require no special password or key for +unpacking, reading or copying. + + 7. Additional Terms. + + "Additional permissions" are terms that supplement the terms of this +License by making exceptions from one or more of its conditions. +Additional permissions that are applicable to the entire Program shall +be treated as though they were included in this License, to the extent +that they are valid under applicable law. If additional permissions +apply only to part of the Program, that part may be used separately +under those permissions, but the entire Program remains governed by +this License without regard to the additional permissions. + + When you convey a copy of a covered work, you may at your option +remove any additional permissions from that copy, or from any part of +it. (Additional permissions may be written to require their own +removal in certain cases when you modify the work.) You may place +additional permissions on material, added by you to a covered work, +for which you have or can give appropriate copyright permission. + + Notwithstanding any other provision of this License, for material you +add to a covered work, you may (if authorized by the copyright holders of +that material) supplement the terms of this License with terms: + + a) Disclaiming warranty or limiting liability differently from the + terms of sections 15 and 16 of this License; or + + b) Requiring preservation of specified reasonable legal notices or + author attributions in that material or in the Appropriate Legal + Notices displayed by works containing it; or + + c) Prohibiting misrepresentation of the origin of that material, or + requiring that modified versions of such material be marked in + reasonable ways as different from the original version; or + + d) Limiting the use for publicity purposes of names of licensors or + authors of the material; or + + e) Declining to grant rights under trademark law for use of some + trade names, trademarks, or service marks; or + + f) Requiring indemnification of licensors and authors of that + material by anyone who conveys the material (or modified versions of + it) with contractual assumptions of liability to the recipient, for + any liability that these contractual assumptions directly impose on + those licensors and authors. + + All other non-permissive additional terms are considered "further +restrictions" within the meaning of section 10. If the Program as you +received it, or any part of it, contains a notice stating that it is +governed by this License along with a term that is a further +restriction, you may remove that term. If a license document contains +a further restriction but permits relicensing or conveying under this +License, you may add to a covered work material governed by the terms +of that license document, provided that the further restriction does +not survive such relicensing or conveying. + + If you add terms to a covered work in accord with this section, you +must place, in the relevant source files, a statement of the +additional terms that apply to those files, or a notice indicating +where to find the applicable terms. + + Additional terms, permissive or non-permissive, may be stated in the +form of a separately written license, or stated as exceptions; +the above requirements apply either way. + + 8. Termination. + + You may not propagate or modify a covered work except as expressly +provided under this License. Any attempt otherwise to propagate or +modify it is void, and will automatically terminate your rights under +this License (including any patent licenses granted under the third +paragraph of section 11). + + However, if you cease all violation of this License, then your +license from a particular copyright holder is reinstated (a) +provisionally, unless and until the copyright holder explicitly and +finally terminates your license, and (b) permanently, if the copyright +holder fails to notify you of the violation by some reasonable means +prior to 60 days after the cessation. + + Moreover, your license from a particular copyright holder is +reinstated permanently if the copyright holder notifies you of the +violation by some reasonable means, this is the first time you have +received notice of violation of this License (for any work) from that +copyright holder, and you cure the violation prior to 30 days after +your receipt of the notice. + + Termination of your rights under this section does not terminate the +licenses of parties who have received copies or rights from you under +this License. If your rights have been terminated and not permanently +reinstated, you do not qualify to receive new licenses for the same +material under section 10. + + 9. Acceptance Not Required for Having Copies. + + You are not required to accept this License in order to receive or +run a copy of the Program. Ancillary propagation of a covered work +occurring solely as a consequence of using peer-to-peer transmission +to receive a copy likewise does not require acceptance. However, +nothing other than this License grants you permission to propagate or +modify any covered work. These actions infringe copyright if you do +not accept this License. Therefore, by modifying or propagating a +covered work, you indicate your acceptance of this License to do so. + + 10. Automatic Licensing of Downstream Recipients. + + Each time you convey a covered work, the recipient automatically +receives a license from the original licensors, to run, modify and +propagate that work, subject to this License. You are not responsible +for enforcing compliance by third parties with this License. + + An "entity transaction" is a transaction transferring control of an +organization, or substantially all assets of one, or subdividing an +organization, or merging organizations. If propagation of a covered +work results from an entity transaction, each party to that +transaction who receives a copy of the work also receives whatever +licenses to the work the party's predecessor in interest had or could +give under the previous paragraph, plus a right to possession of the +Corresponding Source of the work from the predecessor in interest, if +the predecessor has it or can get it with reasonable efforts. + + You may not impose any further restrictions on the exercise of the +rights granted or affirmed under this License. For example, you may +not impose a license fee, royalty, or other charge for exercise of +rights granted under this License, and you may not initiate litigation +(including a cross-claim or counterclaim in a lawsuit) alleging that +any patent claim is infringed by making, using, selling, offering for +sale, or importing the Program or any portion of it. + + 11. Patents. + + A "contributor" is a copyright holder who authorizes use under this +License of the Program or a work on which the Program is based. The +work thus licensed is called the contributor's "contributor version". + + A contributor's "essential patent claims" are all patent claims +owned or controlled by the contributor, whether already acquired or +hereafter acquired, that would be infringed by some manner, permitted +by this License, of making, using, or selling its contributor version, +but do not include claims that would be infringed only as a +consequence of further modification of the contributor version. For +purposes of this definition, "control" includes the right to grant +patent sublicenses in a manner consistent with the requirements of +this License. + + Each contributor grants you a non-exclusive, worldwide, royalty-free +patent license under the contributor's essential patent claims, to +make, use, sell, offer for sale, import and otherwise run, modify and +propagate the contents of its contributor version. + + In the following three paragraphs, a "patent license" is any express +agreement or commitment, however denominated, not to enforce a patent +(such as an express permission to practice a patent or covenant not to +sue for patent infringement). To "grant" such a patent license to a +party means to make such an agreement or commitment not to enforce a +patent against the party. + + If you convey a covered work, knowingly relying on a patent license, +and the Corresponding Source of the work is not available for anyone +to copy, free of charge and under the terms of this License, through a +publicly available network server or other readily accessible means, +then you must either (1) cause the Corresponding Source to be so +available, or (2) arrange to deprive yourself of the benefit of the +patent license for this particular work, or (3) arrange, in a manner +consistent with the requirements of this License, to extend the patent +license to downstream recipients. "Knowingly relying" means you have +actual knowledge that, but for the patent license, your conveying the +covered work in a country, or your recipient's use of the covered work +in a country, would infringe one or more identifiable patents in that +country that you have reason to believe are valid. + + If, pursuant to or in connection with a single transaction or +arrangement, you convey, or propagate by procuring conveyance of, a +covered work, and grant a patent license to some of the parties +receiving the covered work authorizing them to use, propagate, modify +or convey a specific copy of the covered work, then the patent license +you grant is automatically extended to all recipients of the covered +work and works based on it. + + A patent license is "discriminatory" if it does not include within +the scope of its coverage, prohibits the exercise of, or is +conditioned on the non-exercise of one or more of the rights that are +specifically granted under this License. You may not convey a covered +work if you are a party to an arrangement with a third party that is +in the business of distributing software, under which you make payment +to the third party based on the extent of your activity of conveying +the work, and under which the third party grants, to any of the +parties who would receive the covered work from you, a discriminatory +patent license (a) in connection with copies of the covered work +conveyed by you (or copies made from those copies), or (b) primarily +for and in connection with specific products or compilations that +contain the covered work, unless you entered into that arrangement, +or that patent license was granted, prior to 28 March 2007. + + Nothing in this License shall be construed as excluding or limiting +any implied license or other defenses to infringement that may +otherwise be available to you under applicable patent law. + + 12. No Surrender of Others' Freedom. + + If conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot convey a +covered work so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you may +not convey it at all. For example, if you agree to terms that obligate you +to collect a royalty for further conveying from those to whom you convey +the Program, the only way you could satisfy both those terms and this +License would be to refrain entirely from conveying the Program. + + 13. Use with the GNU Affero General Public License. + + Notwithstanding any other provision of this License, you have +permission to link or combine any covered work with a work licensed +under version 3 of the GNU Affero General Public License into a single +combined work, and to convey the resulting work. The terms of this +License will continue to apply to the part which is the covered work, +but the special requirements of the GNU Affero General Public License, +section 13, concerning interaction through a network will apply to the +combination as such. + + 14. Revised Versions of this License. + + The Free Software Foundation may publish revised and/or new versions of +the GNU General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + + Each version is given a distinguishing version number. If the +Program specifies that a certain numbered version of the GNU General +Public License "or any later version" applies to it, you have the +option of following the terms and conditions either of that numbered +version or of any later version published by the Free Software +Foundation. If the Program does not specify a version number of the +GNU General Public License, you may choose any version ever published +by the Free Software Foundation. + + If the Program specifies that a proxy can decide which future +versions of the GNU General Public License can be used, that proxy's +public statement of acceptance of a version permanently authorizes you +to choose that version for the Program. + + Later license versions may give you additional or different +permissions. However, no additional obligations are imposed on any +author or copyright holder as a result of your choosing to follow a +later version. + + 15. Disclaimer of Warranty. + + THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY +APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT +HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY +OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, +THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM +IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF +ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. Limitation of Liability. + + IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS +THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY +GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE +USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF +DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD +PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), +EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF +SUCH DAMAGES. + + 17. Interpretation of Sections 15 and 16. + + If the disclaimer of warranty and limitation of liability provided +above cannot be given local legal effect according to their terms, +reviewing courts shall apply local law that most closely approximates +an absolute waiver of all civil liability in connection with the +Program, unless a warranty or assumption of liability accompanies a +copy of the Program in return for a fee. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +state the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + copyright (c) by Bruce Korb - all rights reserved + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + +Also add information on how to contact you by electronic and paper mail. + + If the program does terminal interaction, make it output a short +notice like this when it starts in an interactive mode: + + copyright (c) by Bruce Korb - all rights reserved + This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, your program's commands +might be different; for a GUI interface, you would use an "about box". + + You should also get your employer (if you work as a programmer) or school, +if any, to sign a "copyright disclaimer" for the program, if necessary. +For more information on this, and how to apply and follow the GNU GPL, see +. + + The GNU General Public License does not permit incorporating your program +into proprietary programs. If your program is a subroutine library, you +may consider it more useful to permit linking proprietary applications with +the library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. But first, please read +. diff -urN src/contrib/ntp/libopts/COPYING.lgpl src.ntp/contrib/ntp/libopts/COPYING.lgpl --- src/contrib/ntp/libopts/COPYING.lgpl 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/COPYING.lgpl 1970-01-01 01:00:00.000000000 +0100 @@ -1,502 +0,0 @@ - GNU LESSER GENERAL PUBLIC LICENSE - Version 2.1, February 1999 - - Copyright (C) 1991, 1999 Free Software Foundation, Inc. - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - -[This is the first released version of the Lesser GPL. It also counts - as the successor of the GNU Library Public License, version 2, hence - the version number 2.1.] - - Preamble - - The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -Licenses are intended to guarantee your freedom to share and change -free software--to make sure the software is free for all its users. - - This license, the Lesser General Public License, applies to some -specially designated software packages--typically libraries--of the -Free Software Foundation and other authors who decide to use it. You -can use it too, but we suggest you first think carefully about whether -this license or the ordinary General Public License is the better -strategy to use in any particular case, based on the explanations below. - - When we speak of free software, we are referring to freedom of use, -not price. Our General Public Licenses are designed to make sure that -you have the freedom to distribute copies of free software (and charge -for this service if you wish); that you receive source code or can get -it if you want it; that you can change the software and use pieces of -it in new free programs; and that you are informed that you can do -these things. - - To protect your rights, we need to make restrictions that forbid -distributors to deny you these rights or to ask you to surrender these -rights. These restrictions translate to certain responsibilities for -you if you distribute copies of the library or if you modify it. - - For example, if you distribute copies of the library, whether gratis -or for a fee, you must give the recipients all the rights that we gave -you. You must make sure that they, too, receive or can get the source -code. If you link other code with the library, you must provide -complete object files to the recipients, so that they can relink them -with the library after making changes to the library and recompiling -it. And you must show them these terms so they know their rights. - - We protect your rights with a two-step method: (1) we copyright the -library, and (2) we offer you this license, which gives you legal -permission to copy, distribute and/or modify the library. - - To protect each distributor, we want to make it very clear that -there is no warranty for the free library. Also, if the library is -modified by someone else and passed on, the recipients should know -that what they have is not the original version, so that the original -author's reputation will not be affected by problems that might be -introduced by others. - - Finally, software patents pose a constant threat to the existence of -any free program. We wish to make sure that a company cannot -effectively restrict the users of a free program by obtaining a -restrictive license from a patent holder. Therefore, we insist that -any patent license obtained for a version of the library must be -consistent with the full freedom of use specified in this license. - - Most GNU software, including some libraries, is covered by the -ordinary GNU General Public License. This license, the GNU Lesser -General Public License, applies to certain designated libraries, and -is quite different from the ordinary General Public License. We use -this license for certain libraries in order to permit linking those -libraries into non-free programs. - - When a program is linked with a library, whether statically or using -a shared library, the combination of the two is legally speaking a -combined work, a derivative of the original library. The ordinary -General Public License therefore permits such linking only if the -entire combination fits its criteria of freedom. The Lesser General -Public License permits more lax criteria for linking other code with -the library. - - We call this license the "Lesser" General Public License because it -does Less to protect the user's freedom than the ordinary General -Public License. It also provides other free software developers Less -of an advantage over competing non-free programs. These disadvantages -are the reason we use the ordinary General Public License for many -libraries. However, the Lesser license provides advantages in certain -special circumstances. - - For example, on rare occasions, there may be a special need to -encourage the widest possible use of a certain library, so that it becomes -a de-facto standard. To achieve this, non-free programs must be -allowed to use the library. A more frequent case is that a free -library does the same job as widely used non-free libraries. In this -case, there is little to gain by limiting the free library to free -software only, so we use the Lesser General Public License. - - In other cases, permission to use a particular library in non-free -programs enables a greater number of people to use a large body of -free software. For example, permission to use the GNU C Library in -non-free programs enables many more people to use the whole GNU -operating system, as well as its variant, the GNU/Linux operating -system. - - Although the Lesser General Public License is Less protective of the -users' freedom, it does ensure that the user of a program that is -linked with the Library has the freedom and the wherewithal to run -that program using a modified version of the Library. - - The precise terms and conditions for copying, distribution and -modification follow. Pay close attention to the difference between a -"work based on the library" and a "work that uses the library". The -former contains code derived from the library, whereas the latter must -be combined with the library in order to run. - - GNU LESSER GENERAL PUBLIC LICENSE - TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - - 0. This License Agreement applies to any software library or other -program which contains a notice placed by the copyright holder or -other authorized party saying it may be distributed under the terms of -this Lesser General Public License (also called "this License"). -Each licensee is addressed as "you". - - A "library" means a collection of software functions and/or data -prepared so as to be conveniently linked with application programs -(which use some of those functions and data) to form executables. - - The "Library", below, refers to any such software library or work -which has been distributed under these terms. A "work based on the -Library" means either the Library or any derivative work under -copyright law: that is to say, a work containing the Library or a -portion of it, either verbatim or with modifications and/or translated -straightforwardly into another language. (Hereinafter, translation is -included without limitation in the term "modification".) - - "Source code" for a work means the preferred form of the work for -making modifications to it. For a library, complete source code means -all the source code for all modules it contains, plus any associated -interface definition files, plus the scripts used to control compilation -and installation of the library. - - Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running a program using the Library is not restricted, and output from -such a program is covered only if its contents constitute a work based -on the Library (independent of the use of the Library in a tool for -writing it). Whether that is true depends on what the Library does -and what the program that uses the Library does. - - 1. You may copy and distribute verbatim copies of the Library's -complete source code as you receive it, in any medium, provided that -you conspicuously and appropriately publish on each copy an -appropriate copyright notice and disclaimer of warranty; keep intact -all the notices that refer to this License and to the absence of any -warranty; and distribute a copy of this License along with the -Library. - - You may charge a fee for the physical act of transferring a copy, -and you may at your option offer warranty protection in exchange for a -fee. - - 2. You may modify your copy or copies of the Library or any portion -of it, thus forming a work based on the Library, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - - a) The modified work must itself be a software library. - - b) You must cause the files modified to carry prominent notices - stating that you changed the files and the date of any change. - - c) You must cause the whole of the work to be licensed at no - charge to all third parties under the terms of this License. - - d) If a facility in the modified Library refers to a function or a - table of data to be supplied by an application program that uses - the facility, other than as an argument passed when the facility - is invoked, then you must make a good faith effort to ensure that, - in the event an application does not supply such function or - table, the facility still operates, and performs whatever part of - its purpose remains meaningful. - - (For example, a function in a library to compute square roots has - a purpose that is entirely well-defined independent of the - application. Therefore, Subsection 2d requires that any - application-supplied function or table used by this function must - be optional: if the application does not supply it, the square - root function must still compute square roots.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Library, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Library, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote -it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Library. - -In addition, mere aggregation of another work not based on the Library -with the Library (or with a work based on the Library) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - - 3. You may opt to apply the terms of the ordinary GNU General Public -License instead of this License to a given copy of the Library. To do -this, you must alter all the notices that refer to this License, so -that they refer to the ordinary GNU General Public License, version 2, -instead of to this License. (If a newer version than version 2 of the -ordinary GNU General Public License has appeared, then you can specify -that version instead if you wish.) Do not make any other change in -these notices. - - Once this change is made in a given copy, it is irreversible for -that copy, so the ordinary GNU General Public License applies to all -subsequent copies and derivative works made from that copy. - - This option is useful when you wish to copy part of the code of -the Library into a program that is not a library. - - 4. You may copy and distribute the Library (or a portion or -derivative of it, under Section 2) in object code or executable form -under the terms of Sections 1 and 2 above provided that you accompany -it with the complete corresponding machine-readable source code, which -must be distributed under the terms of Sections 1 and 2 above on a -medium customarily used for software interchange. - - If distribution of object code is made by offering access to copy -from a designated place, then offering equivalent access to copy the -source code from the same place satisfies the requirement to -distribute the source code, even though third parties are not -compelled to copy the source along with the object code. - - 5. A program that contains no derivative of any portion of the -Library, but is designed to work with the Library by being compiled or -linked with it, is called a "work that uses the Library". Such a -work, in isolation, is not a derivative work of the Library, and -therefore falls outside the scope of this License. - - However, linking a "work that uses the Library" with the Library -creates an executable that is a derivative of the Library (because it -contains portions of the Library), rather than a "work that uses the -library". The executable is therefore covered by this License. -Section 6 states terms for distribution of such executables. - - When a "work that uses the Library" uses material from a header file -that is part of the Library, the object code for the work may be a -derivative work of the Library even though the source code is not. -Whether this is true is especially significant if the work can be -linked without the Library, or if the work is itself a library. The -threshold for this to be true is not precisely defined by law. - - If such an object file uses only numerical parameters, data -structure layouts and accessors, and small macros and small inline -functions (ten lines or less in length), then the use of the object -file is unrestricted, regardless of whether it is legally a derivative -work. (Executables containing this object code plus portions of the -Library will still fall under Section 6.) - - Otherwise, if the work is a derivative of the Library, you may -distribute the object code for the work under the terms of Section 6. -Any executables containing that work also fall under Section 6, -whether or not they are linked directly with the Library itself. - - 6. As an exception to the Sections above, you may also combine or -link a "work that uses the Library" with the Library to produce a -work containing portions of the Library, and distribute that work -under terms of your choice, provided that the terms permit -modification of the work for the customer's own use and reverse -engineering for debugging such modifications. - - You must give prominent notice with each copy of the work that the -Library is used in it and that the Library and its use are covered by -this License. You must supply a copy of this License. If the work -during execution displays copyright notices, you must include the -copyright notice for the Library among them, as well as a reference -directing the user to the copy of this License. Also, you must do one -of these things: - - a) Accompany the work with the complete corresponding - machine-readable source code for the Library including whatever - changes were used in the work (which must be distributed under - Sections 1 and 2 above); and, if the work is an executable linked - with the Library, with the complete machine-readable "work that - uses the Library", as object code and/or source code, so that the - user can modify the Library and then relink to produce a modified - executable containing the modified Library. (It is understood - that the user who changes the contents of definitions files in the - Library will not necessarily be able to recompile the application - to use the modified definitions.) - - b) Use a suitable shared library mechanism for linking with the - Library. A suitable mechanism is one that (1) uses at run time a - copy of the library already present on the user's computer system, - rather than copying library functions into the executable, and (2) - will operate properly with a modified version of the library, if - the user installs one, as long as the modified version is - interface-compatible with the version that the work was made with. - - c) Accompany the work with a written offer, valid for at - least three years, to give the same user the materials - specified in Subsection 6a, above, for a charge no more - than the cost of performing this distribution. - - d) If distribution of the work is made by offering access to copy - from a designated place, offer equivalent access to copy the above - specified materials from the same place. - - e) Verify that the user has already received a copy of these - materials or that you have already sent this user a copy. - - For an executable, the required form of the "work that uses the -Library" must include any data and utility programs needed for -reproducing the executable from it. However, as a special exception, -the materials to be distributed need not include anything that is -normally distributed (in either source or binary form) with the major -components (compiler, kernel, and so on) of the operating system on -which the executable runs, unless that component itself accompanies -the executable. - - It may happen that this requirement contradicts the license -restrictions of other proprietary libraries that do not normally -accompany the operating system. Such a contradiction means you cannot -use both them and the Library together in an executable that you -distribute. - - 7. You may place library facilities that are a work based on the -Library side-by-side in a single library together with other library -facilities not covered by this License, and distribute such a combined -library, provided that the separate distribution of the work based on -the Library and of the other library facilities is otherwise -permitted, and provided that you do these two things: - - a) Accompany the combined library with a copy of the same work - based on the Library, uncombined with any other library - facilities. This must be distributed under the terms of the - Sections above. - - b) Give prominent notice with the combined library of the fact - that part of it is a work based on the Library, and explaining - where to find the accompanying uncombined form of the same work. - - 8. You may not copy, modify, sublicense, link with, or distribute -the Library except as expressly provided under this License. Any -attempt otherwise to copy, modify, sublicense, link with, or -distribute the Library is void, and will automatically terminate your -rights under this License. However, parties who have received copies, -or rights, from you under this License will not have their licenses -terminated so long as such parties remain in full compliance. - - 9. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Library or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Library (or any work based on the -Library), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Library or works based on it. - - 10. Each time you redistribute the Library (or any work based on the -Library), the recipient automatically receives a license from the -original licensor to copy, distribute, link with or modify the Library -subject to these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties with -this License. - - 11. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Library at all. For example, if a patent -license would not permit royalty-free redistribution of the Library by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Library. - -If any portion of this section is held invalid or unenforceable under any -particular circumstance, the balance of the section is intended to apply, -and the section as a whole is intended to apply in other circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - - 12. If the distribution and/or use of the Library is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Library under this License may add -an explicit geographical distribution limitation excluding those countries, -so that distribution is permitted only in or among countries not thus -excluded. In such case, this License incorporates the limitation as if -written in the body of this License. - - 13. The Free Software Foundation may publish revised and/or new -versions of the Lesser General Public License from time to time. -Such new versions will be similar in spirit to the present version, -but may differ in detail to address new problems or concerns. - -Each version is given a distinguishing version number. If the Library -specifies a version number of this License which applies to it and -"any later version", you have the option of following the terms and -conditions either of that version or of any later version published by -the Free Software Foundation. If the Library does not specify a -license version number, you may choose any version ever published by -the Free Software Foundation. - - 14. If you wish to incorporate parts of the Library into other free -programs whose distribution conditions are incompatible with these, -write to the author to ask for permission. For software which is -copyrighted by the Free Software Foundation, write to the Free -Software Foundation; we sometimes make exceptions for this. Our -decision will be guided by the two goals of preserving the free status -of all derivatives of our free software and of promoting the sharing -and reuse of software generally. - - NO WARRANTY - - 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO -WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. -EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR -OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY -KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE -IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE -LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME -THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN -WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY -AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU -FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR -CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE -LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING -RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A -FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF -SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH -DAMAGES. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Libraries - - If you develop a new library, and you want it to be of the greatest -possible use to the public, we recommend making it free software that -everyone can redistribute and change. You can do so by permitting -redistribution under these terms (or, alternatively, under the terms of the -ordinary General Public License). - - To apply these terms, attach the following notices to the library. It is -safest to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least the -"copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA - -Also add information on how to contact you by electronic and paper mail. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the library, if -necessary. Here is a sample; alter the names: - - Yoyodyne, Inc., hereby disclaims all copyright interest in the - library `Frob' (a library for tweaking knobs) written by James Random Hacker. - - , 1 April 1990 - Ty Coon, President of Vice - -That's all there is to it! diff -urN src/contrib/ntp/libopts/COPYING.lgplv3 src.ntp/contrib/ntp/libopts/COPYING.lgplv3 --- src/contrib/ntp/libopts/COPYING.lgplv3 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/libopts/COPYING.lgplv3 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,165 @@ + GNU LESSER GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 + + copyright (c) 2009 by Bruce Korb - all rights reserved + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + + This version of the GNU Lesser General Public License incorporates +the terms and conditions of version 3 of the GNU General Public +License, supplemented by the additional permissions listed below. + + 0. Additional Definitions. + + As used herein, "this License" refers to version 3 of the GNU Lesser +General Public License, and the "GNU GPL" refers to version 3 of the GNU +General Public License. + + "The Library" refers to a covered work governed by this License, +other than an Application or a Combined Work as defined below. + + An "Application" is any work that makes use of an interface provided +by the Library, but which is not otherwise based on the Library. +Defining a subclass of a class defined by the Library is deemed a mode +of using an interface provided by the Library. + + A "Combined Work" is a work produced by combining or linking an +Application with the Library. The particular version of the Library +with which the Combined Work was made is also called the "Linked +Version". + + The "Minimal Corresponding Source" for a Combined Work means the +Corresponding Source for the Combined Work, excluding any source code +for portions of the Combined Work that, considered in isolation, are +based on the Application, and not on the Linked Version. + + The "Corresponding Application Code" for a Combined Work means the +object code and/or source code for the Application, including any data +and utility programs needed for reproducing the Combined Work from the +Application, but excluding the System Libraries of the Combined Work. + + 1. Exception to Section 3 of the GNU GPL. + + You may convey a covered work under sections 3 and 4 of this License +without being bound by section 3 of the GNU GPL. + + 2. Conveying Modified Versions. + + If you modify a copy of the Library, and, in your modifications, a +facility refers to a function or data to be supplied by an Application +that uses the facility (other than as an argument passed when the +facility is invoked), then you may convey a copy of the modified +version: + + a) under this License, provided that you make a good faith effort to + ensure that, in the event an Application does not supply the + function or data, the facility still operates, and performs + whatever part of its purpose remains meaningful, or + + b) under the GNU GPL, with none of the additional permissions of + this License applicable to that copy. + + 3. Object Code Incorporating Material from Library Header Files. + + The object code form of an Application may incorporate material from +a header file that is part of the Library. You may convey such object +code under terms of your choice, provided that, if the incorporated +material is not limited to numerical parameters, data structure +layouts and accessors, or small macros, inline functions and templates +(ten or fewer lines in length), you do both of the following: + + a) Give prominent notice with each copy of the object code that the + Library is used in it and that the Library and its use are + covered by this License. + + b) Accompany the object code with a copy of the GNU GPL and this license + document. + + 4. Combined Works. + + You may convey a Combined Work under terms of your choice that, +taken together, effectively do not restrict modification of the +portions of the Library contained in the Combined Work and reverse +engineering for debugging such modifications, if you also do each of +the following: + + a) Give prominent notice with each copy of the Combined Work that + the Library is used in it and that the Library and its use are + covered by this License. + + b) Accompany the Combined Work with a copy of the GNU GPL and this license + document. + + c) For a Combined Work that displays copyright notices during + execution, include the copyright notice for the Library among + these notices, as well as a reference directing the user to the + copies of the GNU GPL and this license document. + + d) Do one of the following: + + 0) Convey the Minimal Corresponding Source under the terms of this + License, and the Corresponding Application Code in a form + suitable for, and under terms that permit, the user to + recombine or relink the Application with a modified version of + the Linked Version to produce a modified Combined Work, in the + manner specified by section 6 of the GNU GPL for conveying + Corresponding Source. + + 1) Use a suitable shared library mechanism for linking with the + Library. A suitable mechanism is one that (a) uses at run time + a copy of the Library already present on the user's computer + system, and (b) will operate properly with a modified version + of the Library that is interface-compatible with the Linked + Version. + + e) Provide Installation Information, but only if you would otherwise + be required to provide such information under section 6 of the + GNU GPL, and only to the extent that such information is + necessary to install and execute a modified version of the + Combined Work produced by recombining or relinking the + Application with a modified version of the Linked Version. (If + you use option 4d0, the Installation Information must accompany + the Minimal Corresponding Source and Corresponding Application + Code. If you use option 4d1, you must provide the Installation + Information in the manner specified by section 6 of the GNU GPL + for conveying Corresponding Source.) + + 5. Combined Libraries. + + You may place library facilities that are a work based on the +Library side by side in a single library together with other library +facilities that are not Applications and are not covered by this +License, and convey such a combined library under terms of your +choice, if you do both of the following: + + a) Accompany the combined library with a copy of the same work based + on the Library, uncombined with any other library facilities, + conveyed under the terms of this License. + + b) Give prominent notice with the combined library that part of it + is a work based on the Library, and explaining where to find the + accompanying uncombined form of the same work. + + 6. Revised Versions of the GNU Lesser General Public License. + + The Free Software Foundation may publish revised and/or new versions +of the GNU Lesser General Public License from time to time. Such new +versions will be similar in spirit to the present version, but may +differ in detail to address new problems or concerns. + + Each version is given a distinguishing version number. If the +Library as you received it specifies that a certain numbered version +of the GNU Lesser General Public License "or any later version" +applies to it, you have the option of following the terms and +conditions either of that published version or of any later version +published by the Free Software Foundation. If the Library as you +received it does not specify a version number of the GNU Lesser +General Public License, you may choose any version of the GNU Lesser +General Public License ever published by the Free Software Foundation. + + If the Library as you received it specifies that a proxy can decide +whether future versions of the GNU Lesser General Public License shall +apply, that proxy's public statement of acceptance of any version is +permanent authorization for you to choose that version for the +Library. diff -urN src/contrib/ntp/libopts/Makefile.am src.ntp/contrib/ntp/libopts/Makefile.am --- src/contrib/ntp/libopts/Makefile.am 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/Makefile.am 2009-12-09 08:36:36.000000000 +0100 @@ -7,18 +7,22 @@ endif libopts_la_SOURCES = libopts.c libopts_la_CPPFLAGS = -I$(top_srcdir) -libopts_la_LDFLAGS = -version-info 29:0:4 +libopts_la_LDFLAGS = -version-info 33:0:8 EXTRA_DIST = \ - COPYING.lgpl COPYING.mbsd MakeDefs.inc \ - README autoopts/options.h autoopts/usage-txt.h \ - autoopts.c autoopts.h boolean.c \ - compat/windows-config.h compat/compat.h compat/pathfind.c \ - compat/snprintf.c compat/strdup.c compat/strchr.c \ - configfile.c cook.c enumeration.c \ - environment.c genshell.c genshell.h \ + COPYING.gplv3 COPYING.lgplv3 COPYING.mbsd \ + MakeDefs.inc README ag-char-map.h \ + autoopts/options.h autoopts/usage-txt.h autoopts.c \ + autoopts.h boolean.c compat/windows-config.h \ + compat/compat.h compat/pathfind.c compat/snprintf.c \ + compat/strdup.c compat/strchr.c configfile.c \ + cook.c enumeration.c environment.c \ + file.c genshell.c genshell.h \ load.c m4/libopts.m4 m4/liboptschk.m4 \ makeshell.c nested.c numeric.c \ - pgusage.c proto.h putshell.c \ + parse-duration.c parse-duration.h pgusage.c \ + proto.h putshell.c reset.c \ restore.c save.c sort.c \ stack.c streqvcmp.c text_mmap.c \ - tokenize.c usage.c version.c + time.c tokenize.c usage.c \ + value-type.c value-type.h version.c \ + xat-attribute.c xat-attribute.h diff -urN src/contrib/ntp/libopts/Makefile.in src.ntp/contrib/ntp/libopts/Makefile.in --- src/contrib/ntp/libopts/Makefile.in 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/libopts/Makefile.in 2010-07-09 04:21:33.000000000 +0200 @@ -39,7 +39,11 @@ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ + $(top_srcdir)/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/m4/ntp_openssl.m4 \ + $(top_srcdir)/m4/ntp_vpathhack.m4 \ $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ @@ -100,7 +104,6 @@ ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -121,6 +124,7 @@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EF_LIBS = @EF_LIBS@ EF_PROGS = @EF_PROGS@ EGREP = @EGREP@ @@ -152,6 +156,7 @@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ @@ -168,18 +173,22 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ PATH_SEPARATOR = @PATH_SEPARATOR@ PATH_SH = @PATH_SH@ PROPDELAY = @PROPDELAY@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ VERSION = @VERSION@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ @@ -236,21 +245,25 @@ @INSTALL_LIBOPTS_FALSE@noinst_LTLIBRARIES = libopts.la libopts_la_SOURCES = libopts.c libopts_la_CPPFLAGS = -I$(top_srcdir) -libopts_la_LDFLAGS = -version-info 29:0:4 +libopts_la_LDFLAGS = -version-info 33:0:8 EXTRA_DIST = \ - COPYING.lgpl COPYING.mbsd MakeDefs.inc \ - README autoopts/options.h autoopts/usage-txt.h \ - autoopts.c autoopts.h boolean.c \ - compat/windows-config.h compat/compat.h compat/pathfind.c \ - compat/snprintf.c compat/strdup.c compat/strchr.c \ - configfile.c cook.c enumeration.c \ - environment.c genshell.c genshell.h \ + COPYING.gplv3 COPYING.lgplv3 COPYING.mbsd \ + MakeDefs.inc README ag-char-map.h \ + autoopts/options.h autoopts/usage-txt.h autoopts.c \ + autoopts.h boolean.c compat/windows-config.h \ + compat/compat.h compat/pathfind.c compat/snprintf.c \ + compat/strdup.c compat/strchr.c configfile.c \ + cook.c enumeration.c environment.c \ + file.c genshell.c genshell.h \ load.c m4/libopts.m4 m4/liboptschk.m4 \ makeshell.c nested.c numeric.c \ - pgusage.c proto.h putshell.c \ + parse-duration.c parse-duration.h pgusage.c \ + proto.h putshell.c reset.c \ restore.c save.c sort.c \ stack.c streqvcmp.c text_mmap.c \ - tokenize.c usage.c version.c + time.c tokenize.c usage.c \ + value-type.c value-type.h version.c \ + xat-attribute.c xat-attribute.h all: all-am diff -urN src/contrib/ntp/libopts/README src.ntp/contrib/ntp/libopts/README --- src/contrib/ntp/libopts/README 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/README 2009-12-09 08:36:37.000000000 +0100 @@ -85,7 +85,7 @@ LICENSING: -This material is copyright 1993-2007 by Bruce Korb. +This material is copyright (c) 1993-2009 by Bruce Korb. You are licensed to use this under the terms of either the GNU Lesser General Public License (see: COPYING.lgpl), or, at your option, the modified Berkeley Software Distribution diff -urN src/contrib/ntp/libopts/ag-char-map.h src.ntp/contrib/ntp/libopts/ag-char-map.h --- src/contrib/ntp/libopts/ag-char-map.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/libopts/ag-char-map.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,160 @@ +/* + * Character mapping generated 11/08/09 08:41:19 + * + * This file contains the character classifications + * used by AutoGen and AutoOpts for identifying tokens. + */ +#ifndef AG_CHAR_MAP_H_GUARD +#define AG_CHAR_MAP_H_GUARD 1 + +#ifdef HAVE_CONFIG_H +# if defined(HAVE_INTTYPES_H) +# include +# elif defined(HAVE_STDINT_H) +# include + +# else +# ifndef HAVE_INT8_T + typedef signed char int8_t; +# endif +# ifndef HAVE_UINT8_T + typedef unsigned char uint8_t; +# endif +# ifndef HAVE_INT16_T + typedef signed short int16_t; +# endif +# ifndef HAVE_UINT16_T + typedef unsigned short uint16_t; +# endif +# ifndef HAVE_UINT_T + typedef unsigned int uint_t; +# endif + +# ifndef HAVE_INT32_T +# if SIZEOF_INT == 4 + typedef signed int int32_t; +# elif SIZEOF_LONG == 4 + typedef signed long int32_t; +# endif +# endif + +# ifndef HAVE_UINT32_T +# if SIZEOF_INT == 4 + typedef unsigned int uint32_t; +# elif SIZEOF_LONG == 4 + typedef unsigned long uint32_t; +# endif +# endif +# endif /* HAVE_*INT*_H header */ + +#else /* not HAVE_CONFIG_H -- */ +# ifdef __sun +# include +# else +# include +# endif +#endif /* HAVE_CONFIG_H */ + +#if 0 /* mapping specification source (from autogen.map) */ +// +// %guard autoopts_internal +// %file ag-char-map.h +// %table opt-char-cat +// +// %comment +// This file contains the character classifications +// used by AutoGen and AutoOpts for identifying tokens. +// % +// +// lower-case "a-z" +// upper-case "A-Z" +// alphabetic +lower-case +upper-case +// oct-digit "0-7" +// dec-digit "89" +oct-digit +// hex-digit "a-fA-F" +dec-digit +// alphanumeric +alphabetic +dec-digit +// var-first "_" +alphabetic +// variable-name +var-first +dec-digit +// option-name "^-" +variable-name +// value-name ":" +option-name +// horiz-white "\t " +// compound-name "[.]" +value-name +horiz-white +// whitespace "\v\f\r\n\b" +horiz-white +// unquotable "!-~" -"\"#(),;<=>[\\]`{}?*'" +// end-xml-token "/>" +whitespace +// graphic "!-~" +// plus-n-space "+" +whitespace +// punctuation "!-~" -alphanumeric -"_" +// suffix "-._" +alphanumeric +// suffix-fmt "%/" +suffix +// false-type "nNfF0\x00" +// +#endif /* 0 -- mapping spec. source */ + +typedef uint32_t opt_char_cat_mask_t; +extern opt_char_cat_mask_t const opt_char_cat[128]; + +static inline int is_opt_char_cat_char(char ch, opt_char_cat_mask_t mask) { + unsigned int ix = (unsigned char)ch; + return ((ix < 0x7F) && ((opt_char_cat[ix] & mask) != 0)); } + +#define IS_LOWER_CASE_CHAR(_c) is_opt_char_cat_char((_c), 0x00001) +#define IS_UPPER_CASE_CHAR(_c) is_opt_char_cat_char((_c), 0x00002) +#define IS_ALPHABETIC_CHAR(_c) is_opt_char_cat_char((_c), 0x00003) +#define IS_OCT_DIGIT_CHAR(_c) is_opt_char_cat_char((_c), 0x00004) +#define IS_DEC_DIGIT_CHAR(_c) is_opt_char_cat_char((_c), 0x0000C) +#define IS_HEX_DIGIT_CHAR(_c) is_opt_char_cat_char((_c), 0x0001C) +#define IS_ALPHANUMERIC_CHAR(_c) is_opt_char_cat_char((_c), 0x0000F) +#define IS_VAR_FIRST_CHAR(_c) is_opt_char_cat_char((_c), 0x00023) +#define IS_VARIABLE_NAME_CHAR(_c) is_opt_char_cat_char((_c), 0x0002F) +#define IS_OPTION_NAME_CHAR(_c) is_opt_char_cat_char((_c), 0x0006F) +#define IS_VALUE_NAME_CHAR(_c) is_opt_char_cat_char((_c), 0x000EF) +#define IS_HORIZ_WHITE_CHAR(_c) is_opt_char_cat_char((_c), 0x00100) +#define IS_COMPOUND_NAME_CHAR(_c) is_opt_char_cat_char((_c), 0x003EF) +#define IS_WHITESPACE_CHAR(_c) is_opt_char_cat_char((_c), 0x00500) +#define IS_UNQUOTABLE_CHAR(_c) is_opt_char_cat_char((_c), 0x00800) +#define IS_END_XML_TOKEN_CHAR(_c) is_opt_char_cat_char((_c), 0x01500) +#define IS_GRAPHIC_CHAR(_c) is_opt_char_cat_char((_c), 0x02000) +#define IS_PLUS_N_SPACE_CHAR(_c) is_opt_char_cat_char((_c), 0x04500) +#define IS_PUNCTUATION_CHAR(_c) is_opt_char_cat_char((_c), 0x08000) +#define IS_SUFFIX_CHAR(_c) is_opt_char_cat_char((_c), 0x1000F) +#define IS_SUFFIX_FMT_CHAR(_c) is_opt_char_cat_char((_c), 0x3000F) +#define IS_FALSE_TYPE_CHAR(_c) is_opt_char_cat_char((_c), 0x40000) + +#ifdef AUTOOPTS_INTERNAL +opt_char_cat_mask_t const opt_char_cat[128] = { + /*x00*/ 0x40000, /*x01*/ 0x00000, /*x02*/ 0x00000, /*x03*/ 0x00000, + /*x04*/ 0x00000, /*x05*/ 0x00000, /*x06*/ 0x00000, /*\a */ 0x00000, + /*\b */ 0x00400, /*\t */ 0x00100, /*\n */ 0x00400, /*\v */ 0x00400, + /*\f */ 0x00400, /*\r */ 0x00400, /*x0E*/ 0x00000, /*x0F*/ 0x00000, + /*x10*/ 0x00000, /*x11*/ 0x00000, /*x12*/ 0x00000, /*x13*/ 0x00000, + /*x14*/ 0x00000, /*x15*/ 0x00000, /*x16*/ 0x00000, /*x17*/ 0x00000, + /*x18*/ 0x00000, /*x19*/ 0x00000, /*x1A*/ 0x00000, /*x1B*/ 0x00000, + /*x1C*/ 0x00000, /*x1D*/ 0x00000, /*x1E*/ 0x00000, /*x1F*/ 0x00000, + /* */ 0x00100, /* ! */ 0x0A800, /* " */ 0x0A000, /* # */ 0x0A000, + /* $ */ 0x0A800, /* % */ 0x2A800, /* & */ 0x0A800, /* ' */ 0x0A000, + /* ( */ 0x0A000, /* ) */ 0x0A000, /* * */ 0x0A000, /* + */ 0x0E800, + /* , */ 0x0A000, /* - */ 0x1A840, /* . */ 0x1AA00, /* / */ 0x2B800, + /* 0 */ 0x42804, /* 1 */ 0x02804, /* 2 */ 0x02804, /* 3 */ 0x02804, + /* 4 */ 0x02804, /* 5 */ 0x02804, /* 6 */ 0x02804, /* 7 */ 0x02804, + /* 8 */ 0x02808, /* 9 */ 0x02808, /* : */ 0x0A880, /* ; */ 0x0A000, + /* < */ 0x0A000, /* = */ 0x0A000, /* > */ 0x0B000, /* ? */ 0x0A000, + /* @ */ 0x0A800, /* A */ 0x02812, /* B */ 0x02812, /* C */ 0x02812, + /* D */ 0x02812, /* E */ 0x02812, /* F */ 0x42812, /* G */ 0x02802, + /* H */ 0x02802, /* I */ 0x02802, /* J */ 0x02802, /* K */ 0x02802, + /* L */ 0x02802, /* M */ 0x02802, /* N */ 0x42802, /* O */ 0x02802, + /* P */ 0x02802, /* Q */ 0x02802, /* R */ 0x02802, /* S */ 0x02802, + /* T */ 0x02802, /* U */ 0x02802, /* V */ 0x02802, /* W */ 0x02802, + /* X */ 0x02802, /* Y */ 0x02802, /* Z */ 0x02802, /* [ */ 0x0A200, + /* \ */ 0x0A000, /* ] */ 0x0A200, /* ^ */ 0x0A840, /* _ */ 0x12820, + /* ` */ 0x0A000, /* a */ 0x02811, /* b */ 0x02811, /* c */ 0x02811, + /* d */ 0x02811, /* e */ 0x02811, /* f */ 0x42811, /* g */ 0x02801, + /* h */ 0x02801, /* i */ 0x02801, /* j */ 0x02801, /* k */ 0x02801, + /* l */ 0x02801, /* m */ 0x02801, /* n */ 0x42801, /* o */ 0x02801, + /* p */ 0x02801, /* q */ 0x02801, /* r */ 0x02801, /* s */ 0x02801, + /* t */ 0x02801, /* u */ 0x02801, /* v */ 0x02801, /* w */ 0x02801, + /* x */ 0x02801, /* y */ 0x02801, /* z */ 0x02801, /* { */ 0x0A000, + /* | */ 0x0A800, /* } */ 0x0A000, /* ~ */ 0x0A800, /*x7F*/ 0x00000 +}; +#endif /* AUTOOPTS_INTERNAL */ +#endif /* AG_CHAR_MAP_H_GUARD */ diff -urN src/contrib/ntp/libopts/autoopts/options.h src.ntp/contrib/ntp/libopts/autoopts/options.h --- src/contrib/ntp/libopts/autoopts/options.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/autoopts/options.h 2009-12-09 08:36:35.000000000 +0100 @@ -2,34 +2,32 @@ * * DO NOT EDIT THIS FILE (options.h) * - * It has been AutoGen-ed Saturday May 5, 2007 at 12:02:34 PM PDT + * It has been AutoGen-ed November 8, 2009 at 08:41:08 AM by AutoGen 5.9.10pre13 * From the definitions funcs.def * and the template file options_h * * This file defines all the global structures and special values * used in the automated option processing library. * - * Automated Options copyright 1992-Y Bruce Korb + * Automated Options copyright (c) 1992-Y by Bruce Korb * - * AutoOpts is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * AutoOpts is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with AutoOpts. If not, write to: - * The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor - * Boston, MA 02110-1301, USA. + * AutoOpts is free software: you can redistribute it and/or modify it + * under the terms of the GNU Lesser General Public License as published + * by the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * AutoOpts is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with this program. If not, see . */ #ifndef AUTOOPTS_OPTIONS_H_GUARD -#define AUTOOPTS_OPTIONS_H_GUARD +#define AUTOOPTS_OPTIONS_H_GUARD 1 #include +#include #if defined(HAVE_STDINT_H) # include @@ -68,8 +66,8 @@ * values for "opt_name" are available. */ -#define OPTIONS_STRUCT_VERSION 118784 -#define OPTIONS_VERSION_STRING "29:0:4" +#define OPTIONS_STRUCT_VERSION 135168 +#define OPTIONS_VERSION_STRING "33:0:8" #define OPTIONS_MINIMUM_VERSION 102400 #define OPTIONS_MIN_VER_STRING "25:0:0" @@ -80,7 +78,9 @@ OPARG_TYPE_BOOLEAN = 3, /* opt arg is boolean-valued */ OPARG_TYPE_MEMBERSHIP = 4, /* opt arg sets set membership bits */ OPARG_TYPE_NUMERIC = 5, /* opt arg has numeric value */ - OPARG_TYPE_HIERARCHY = 6 /* option arg is hierarchical value */ + OPARG_TYPE_HIERARCHY = 6, /* option arg is hierarchical value */ + OPARG_TYPE_FILE = 7, /* option arg names a file */ + OPARG_TYPE_TIME = 8 /* opt arg is a time duration */ } teOptArgType; typedef struct optionValue { @@ -96,6 +96,22 @@ } v; } tOptionValue; +typedef enum { + FTYPE_MODE_MAY_EXIST = 0x00, + FTYPE_MODE_MUST_EXIST = 0x01, + FTYPE_MODE_MUST_NOT_EXIST = 0x02, + FTYPE_MODE_EXIST_MASK = 0x03, + FTYPE_MODE_NO_OPEN = 0x00, + FTYPE_MODE_OPEN_FD = 0x10, + FTYPE_MODE_FOPEN_FP = 0x20, + FTYPE_MODE_OPEN_MASK = 0x30 +} teOptFileType; + +typedef union { + int file_flags; + char const * file_mode; +} tuFileMode; + /* * Bits in the fOptState option descriptor field. */ @@ -103,6 +119,7 @@ OPTST_SET_ID = 0, /* Set via the "SET_OPT()" macro */ OPTST_PRESET_ID = 1, /* Set via an RC/INI file */ OPTST_DEFINED_ID = 2, /* Set via a command line option */ + OPTST_RESET_ID = 3, /* Reset via command line option */ OPTST_EQUIVALENCE_ID = 4, /* selected by equiv'ed option */ OPTST_DISABLED_ID = 5, /* option is in disabled state */ OPTST_ALLOC_ARG_ID = 6, /* pzOptArg was allocated */ @@ -121,13 +138,17 @@ OPTST_MUST_SET_ID = 20, /* must be set or pre-set */ OPTST_DOCUMENT_ID = 21, /* opt is for doc only */ OPTST_TWICE_ID = 22, /* process opt twice - imm + reg */ - OPTST_DISABLE_TWICE_ID = 23 /* process disabled option twice */ + OPTST_DISABLE_TWICE_ID = 23, /* process disabled option twice */ + OPTST_SCALED_NUM_ID = 24, /* scaled integer value */ + OPTST_NO_COMMAND_ID = 25, /* disable from cmd line */ + OPTST_DEPRECATED_ID = 26 /* support is being removed */ } opt_state_enum_t; -#define OPTST_INIT 0U +#define OPTST_INIT 0U #define OPTST_SET (1U << OPTST_SET_ID) #define OPTST_PRESET (1U << OPTST_PRESET_ID) #define OPTST_DEFINED (1U << OPTST_DEFINED_ID) +#define OPTST_RESET (1U << OPTST_RESET_ID) #define OPTST_EQUIVALENCE (1U << OPTST_EQUIVALENCE_ID) #define OPTST_DISABLED (1U << OPTST_DISABLED_ID) #define OPTST_ALLOC_ARG (1U << OPTST_ALLOC_ARG_ID) @@ -147,30 +168,39 @@ #define OPTST_DOCUMENT (1U << OPTST_DOCUMENT_ID) #define OPTST_TWICE (1U << OPTST_TWICE_ID) #define OPTST_DISABLE_TWICE (1U << OPTST_DISABLE_TWICE_ID) -#define OPT_STATE_MASK 0x00FFFF77U - -#define OPTST_SET_MASK ( \ - OPTST_SET | \ - OPTST_PRESET | \ - OPTST_DEFINED ) - -#define OPTST_MUTABLE_MASK ( \ - OPTST_SET | \ - OPTST_PRESET | \ - OPTST_DEFINED | \ - OPTST_EQUIVALENCE | \ - OPTST_DISABLED | \ - OPTST_ALLOC_ARG ) - -#define OPTST_SELECTED_MASK ( \ - OPTST_SET | \ - OPTST_DEFINED ) - -#define OPTST_ARG_TYPE_MASK ( \ - OPTST_ARG_TYPE_1 | \ - OPTST_ARG_TYPE_2 | \ - OPTST_ARG_TYPE_3 | \ - OPTST_ARG_TYPE_4 ) +#define OPTST_SCALED_NUM (1U << OPTST_SCALED_NUM_ID) +#define OPTST_NO_COMMAND (1U << OPTST_NO_COMMAND_ID) +#define OPTST_DEPRECATED (1U << OPTST_DEPRECATED_ID) +#define OPT_STATE_MASK 0x07FFFF7FU + +#define OPTST_SET_MASK ( \ + OPTST_DEFINED | OPTST_PRESET | OPTST_RESET | \ + OPTST_SET \ + /* 0x0000000FU */ ) + +#define OPTST_MUTABLE_MASK ( \ + OPTST_ALLOC_ARG | OPTST_DEFINED | \ + OPTST_DISABLED | OPTST_EQUIVALENCE | \ + OPTST_PRESET | OPTST_RESET | \ + OPTST_SET \ + /* 0x0000007FU */ ) + +#define OPTST_SELECTED_MASK ( \ + OPTST_DEFINED | OPTST_SET \ + /* 0x00000005U */ ) + +#define OPTST_ARG_TYPE_MASK ( \ + OPTST_ARG_TYPE_1 | OPTST_ARG_TYPE_2 | OPTST_ARG_TYPE_3 | \ + OPTST_ARG_TYPE_4 \ + /* 0x0000F000U */ ) + +#define OPTST_DO_NOT_SAVE_MASK ( \ + OPTST_DOCUMENT | OPTST_NO_INIT | OPTST_OMITTED \ + /* 0x00280100U */ ) + +#define OPTST_NO_USAGE_MASK ( \ + OPTST_DEPRECATED | OPTST_NO_COMMAND | OPTST_OMITTED \ + /* 0x06080000U */ ) #ifdef NO_OPTIONAL_OPT_ARGS # undef OPTST_ARG_OPTIONAL @@ -179,13 +209,12 @@ #define OPTST_PERSISTENT_MASK (~OPTST_MUTABLE_MASK) -#define SELECTED_OPT( pod ) ((pod)->fOptState & OPTST_SELECTED_MASK) -#define UNUSED_OPT( pod ) (((pod)->fOptState & OPTST_SET_MASK) == 0) -#define DISABLED_OPT( pod ) ((pod)->fOptState & OPTST_DISABLED) -#define OPTION_STATE( pod ) ((pod)->fOptState) - -#define OPTST_SET_ARGTYPE(n) ((n) << OPTST_ARG_TYPE_1_ID) -#define OPTST_GET_ARGTYPE(f) (((f) & OPTST_ARG_TYPE_MASK)>>OPTST_ARG_TYPE_1_ID) +#define SELECTED_OPT(_od) ((_od)->fOptState & OPTST_SELECTED_MASK) +#define UNUSED_OPT( _od) (((_od)->fOptState & OPTST_SET_MASK) == 0) +#define DISABLED_OPT(_od) ((_od)->fOptState & OPTST_DISABLED) +#define OPTION_STATE(_od) ((_od)->fOptState) +#define OPTST_SET_ARGTYPE(_n) ((_n) << OPTST_ARG_TYPE_1_ID) +#define OPTST_GET_ARGTYPE(_f) (((_f)&OPTST_ARG_TYPE_MASK)>>OPTST_ARG_TYPE_1_ID) /* * PRIVATE INTERFACES @@ -199,42 +228,48 @@ * Define the processing state flags */ typedef enum { - OPTPROC_LONGOPT_ID = 0, /* Process long style options */ - OPTPROC_SHORTOPT_ID = 1, /* Process short style "flags" */ - OPTPROC_ERRSTOP_ID = 2, /* Stop on argument errors */ - OPTPROC_DISABLEDOPT_ID = 3, /* Current option is disabled */ - OPTPROC_NO_REQ_OPT_ID = 4, /* no options are required */ - OPTPROC_NUM_OPT_ID = 5, /* there is a number option */ - OPTPROC_INITDONE_ID = 6, /* have initializations been done? */ - OPTPROC_NEGATIONS_ID = 7, /* any negation options? */ - OPTPROC_ENVIRON_ID = 8, /* check environment? */ - OPTPROC_NO_ARGS_ID = 9, /* Disallow remaining arguments */ - OPTPROC_ARGS_REQ_ID = 10, /* Require arguments after options */ - OPTPROC_REORDER_ID = 11, /* reorder operands after options */ - OPTPROC_GNUUSAGE_ID = 12, /* emit usage in GNU style */ - OPTPROC_TRANSLATE_ID = 13, /* Translate strings in tOptions */ - OPTPROC_HAS_IMMED_ID = 14, /* program defines immed options */ - OPTPROC_PRESETTING_ID = 19 /* opt processing in preset state */ + OPTPROC_LONGOPT_ID = 0, /* Process long style options */ + OPTPROC_SHORTOPT_ID = 1, /* Process short style "flags" */ + OPTPROC_ERRSTOP_ID = 2, /* Stop on argument errors */ + OPTPROC_DISABLEDOPT_ID = 3, /* Current option is disabled */ + OPTPROC_NO_REQ_OPT_ID = 4, /* no options are required */ + OPTPROC_NUM_OPT_ID = 5, /* there is a number option */ + OPTPROC_INITDONE_ID = 6, /* have inits been done? */ + OPTPROC_NEGATIONS_ID = 7, /* any negation options? */ + OPTPROC_ENVIRON_ID = 8, /* check environment? */ + OPTPROC_NO_ARGS_ID = 9, /* Disallow remaining arguments */ + OPTPROC_ARGS_REQ_ID = 10, /* Require args after options */ + OPTPROC_REORDER_ID = 11, /* reorder operands after opts */ + OPTPROC_GNUUSAGE_ID = 12, /* emit usage in GNU style */ + OPTPROC_TRANSLATE_ID = 13, /* Translate strings in tOptions */ + OPTPROC_NXLAT_OPT_CFG_ID = 16, /* suppress for config only */ + OPTPROC_NXLAT_OPT_ID = 17, /* suppress xlation always */ + OPTPROC_PRESETTING_ID = 19 /* opt processing in preset state */ } optproc_state_enum_t; -#define OPTPROC_NONE 0U -#define OPTPROC_LONGOPT (1U << OPTPROC_LONGOPT_ID) -#define OPTPROC_SHORTOPT (1U << OPTPROC_SHORTOPT_ID) -#define OPTPROC_ERRSTOP (1U << OPTPROC_ERRSTOP_ID) -#define OPTPROC_DISABLEDOPT (1U << OPTPROC_DISABLEDOPT_ID) -#define OPTPROC_NO_REQ_OPT (1U << OPTPROC_NO_REQ_OPT_ID) -#define OPTPROC_NUM_OPT (1U << OPTPROC_NUM_OPT_ID) -#define OPTPROC_INITDONE (1U << OPTPROC_INITDONE_ID) -#define OPTPROC_NEGATIONS (1U << OPTPROC_NEGATIONS_ID) -#define OPTPROC_ENVIRON (1U << OPTPROC_ENVIRON_ID) -#define OPTPROC_NO_ARGS (1U << OPTPROC_NO_ARGS_ID) -#define OPTPROC_ARGS_REQ (1U << OPTPROC_ARGS_REQ_ID) -#define OPTPROC_REORDER (1U << OPTPROC_REORDER_ID) -#define OPTPROC_GNUUSAGE (1U << OPTPROC_GNUUSAGE_ID) -#define OPTPROC_TRANSLATE (1U << OPTPROC_TRANSLATE_ID) -#define OPTPROC_HAS_IMMED (1U << OPTPROC_HAS_IMMED_ID) -#define OPTPROC_PRESETTING (1U << OPTPROC_PRESETTING_ID) -#define OPTPROC_STATE_MASK 0x00087FFFU +#define OPTPROC_NONE 0U +#define OPTPROC_LONGOPT (1U << OPTPROC_LONGOPT_ID) +#define OPTPROC_SHORTOPT (1U << OPTPROC_SHORTOPT_ID) +#define OPTPROC_ERRSTOP (1U << OPTPROC_ERRSTOP_ID) +#define OPTPROC_DISABLEDOPT (1U << OPTPROC_DISABLEDOPT_ID) +#define OPTPROC_NO_REQ_OPT (1U << OPTPROC_NO_REQ_OPT_ID) +#define OPTPROC_NUM_OPT (1U << OPTPROC_NUM_OPT_ID) +#define OPTPROC_INITDONE (1U << OPTPROC_INITDONE_ID) +#define OPTPROC_NEGATIONS (1U << OPTPROC_NEGATIONS_ID) +#define OPTPROC_ENVIRON (1U << OPTPROC_ENVIRON_ID) +#define OPTPROC_NO_ARGS (1U << OPTPROC_NO_ARGS_ID) +#define OPTPROC_ARGS_REQ (1U << OPTPROC_ARGS_REQ_ID) +#define OPTPROC_REORDER (1U << OPTPROC_REORDER_ID) +#define OPTPROC_GNUUSAGE (1U << OPTPROC_GNUUSAGE_ID) +#define OPTPROC_TRANSLATE (1U << OPTPROC_TRANSLATE_ID) +#define OPTPROC_NXLAT_OPT_CFG (1U << OPTPROC_NXLAT_OPT_CFG_ID) +#define OPTPROC_NXLAT_OPT (1U << OPTPROC_NXLAT_OPT_ID) +#define OPTPROC_PRESETTING (1U << OPTPROC_PRESETTING_ID) +#define OPTPROC_STATE_MASK 0x000B3FFFU + +#define OPTPROC_NO_XLAT_MASK ( \ + OPTPROC_NXLAT_OPT | OPTPROC_NXLAT_OPT_CFG \ + /* 0x00030000U */ ) #define STMTS(s) do { s; } while (0) @@ -265,19 +300,24 @@ typedef struct options tOptions; typedef struct optDesc tOptDesc; typedef struct optNames tOptNames; +#define OPTPROC_EMIT_USAGE ((tOptions *)0x01UL) +#define OPTPROC_EMIT_SHELL ((tOptions *)0x02UL) +#define OPTPROC_RETURN_VALNAME ((tOptions *)0x03UL) +#define OPTPROC_EMIT_LIMIT ((tOptions *)0x0FUL) /* * The option procedures do the special processing for each * option flag that needs it. */ -typedef void (tOptProc)( tOptions* pOpts, tOptDesc* pOptDesc ); +typedef void (tOptProc)(tOptions* pOpts, tOptDesc* pOptDesc); typedef tOptProc* tpOptProc; /* * The usage procedure will never return. It calls "exit(2)" * with the "exitCode" argument passed to it. */ -typedef void (tUsageProc)( tOptions* pOpts, int exitCode ); +// coverity[+kill] +typedef void (tUsageProc)(tOptions* pOpts, int exitCode); typedef tUsageProc* tpUsageProc; /* @@ -311,6 +351,8 @@ long argInt; unsigned long argUint; unsigned int argBool; + FILE* argFp; + int argFd; } optArgBucket_t; /* @@ -334,15 +376,15 @@ # define pzLastArg optArg.argString void* optCookie; /* PUBLIC */ - const int * pOptMust; - const int * pOptCant; - tpOptProc pOptProc; - char const* pzText; - - char const* pz_NAME; - char const* pz_Name; - char const* pz_DisableName; - char const* pz_DisablePfx; + int const * const pOptMust; + int const * const pOptCant; + tpOptProc const pOptProc; + char const* const pzText; + + char const* const pz_NAME; + char const* const pz_Name; + char const* const pz_DisableName; + char const* const pz_DisablePfx; }; /* @@ -370,32 +412,46 @@ unsigned int curOptIdx; char* pzCurOpt; - char const* pzProgPath; - char const* pzProgName; - char const* const pzPROGNAME; - char const* const pzRcName; - char const* const pzCopyright; - char const* const pzCopyNotice; - char const* const pzFullVersion; + char const* pzProgPath; /* PUBLIC */ + char const* pzProgName; /* PUBLIC */ + char const* const pzPROGNAME; /* PUBLIC */ + char const* const pzRcName; /* PUBLIC */ + char const* const pzCopyright; /* PUBLIC */ + char const* const pzCopyNotice; /* PUBLIC */ + char const* const pzFullVersion; /* PUBLIC */ char const* const* const papzHomeList; char const* const pzUsageTitle; char const* const pzExplain; char const* const pzDetail; - tOptDesc* const pOptDesc; - char const* const pzBugAddr; + tOptDesc* const pOptDesc; /* PUBLIC */ + char const* const pzBugAddr; /* PUBLIC */ void* pExtensions; void* pSavedState; + // coverity[+kill] tpUsageProc pUsageProc; tOptionXlateProc* pTransProc; tOptSpecIndex specOptIdx; int const optCt; int const presetOptCt; + char const * pzFullUsage; + char const * pzShortUsage; + /* PUBLIC: */ + optArgBucket_t const * const originalOptArgArray; + void * const * const originalOptArgCookie; }; /* + * Versions where in various fields first appear: + * ($AO_CURRENT * 4096 + $AO_REVISION, but $AO_REVISION must be zero) + */ +#define originalOptArgArray_STRUCT_VERSION 131072 /* AO_CURRENT = 32 */ +#define HAS_originalOptArgArray(_opt) \ + ((_opt)->structVersion >= originalOptArgArray_STRUCT_VERSION) + +/* * "token list" structure returned by "string_tokenize()" */ typedef struct { @@ -447,7 +503,7 @@ * The following routines may be coded into AutoOpts client code: */ -/* From: tokenize.c line 115 +/* From: tokenize.c line 117 * * ao_string_tokenize - tokenize an input string * @@ -488,10 +544,10 @@ * Double quote strings are formed according to the rules of string * constants in ANSI-C programs. */ -extern token_list_t* ao_string_tokenize( char const* ); +extern token_list_t* ao_string_tokenize(char const*); -/* From: configfile.c line 113 +/* From: configfile.c line 85 * * configFileLoad - parse a configuration file * @@ -508,10 +564,10 @@ * @code{optionGetValue()}, @code{optionNextValue()} and * @code{optionUnloadNested()}. */ -extern const tOptionValue* configFileLoad( char const* ); +extern const tOptionValue* configFileLoad(char const*); -/* From: configfile.c line 883 +/* From: configfile.c line 897 * * optionFileLoad - Load the locatable config files, in order * @@ -538,10 +594,10 @@ * * Configuration files not found or not decipherable are simply ignored. */ -extern int optionFileLoad( tOptions*, char const* ); +extern int optionFileLoad(tOptions*, char const*); -/* From: configfile.c line 245 +/* From: configfile.c line 217 * * optionFindNextValue - find a hierarcicaly valued option instance * @@ -557,10 +613,10 @@ * configurable. It will search through the list and return the next entry * that matches the criteria. */ -extern const tOptionValue* optionFindNextValue( const tOptDesc*, const tOptionValue*, char const*, char const* ); +extern const tOptionValue* optionFindNextValue(const tOptDesc*, const tOptionValue*, char const*, char const*); -/* From: configfile.c line 171 +/* From: configfile.c line 143 * * optionFindValue - find a hierarcicaly valued option instance * @@ -574,10 +630,10 @@ * This routine will find an entry in a nested value option or configurable. * It will search through the list and return a matching entry. */ -extern const tOptionValue* optionFindValue( const tOptDesc*, char const*, char const* ); +extern const tOptionValue* optionFindValue(const tOptDesc*, char const*, char const*); -/* From: restore.c line 188 +/* From: restore.c line 165 * * optionFree - free allocated option processing memory * @@ -587,10 +643,10 @@ * AutoOpts sometimes allocates memory and puts pointers to it in the * option state structures. This routine deallocates all such memory. */ -extern void optionFree( tOptions* ); +extern void optionFree(tOptions*); -/* From: configfile.c line 314 +/* From: configfile.c line 286 * * optionGetValue - get a specific value from a hierarcical list * @@ -605,10 +661,10 @@ * the first entry with a name that exactly matches the argument will be * returned. */ -extern const tOptionValue* optionGetValue( const tOptionValue*, char const* ); +extern const tOptionValue* optionGetValue(const tOptionValue*, char const*); -/* From: load.c line 521 +/* From: load.c line 498 * * optionLoadLine - process a string for an option name and value * @@ -629,10 +685,10 @@ * formation used in AutoGen definition files (@pxref{basic expression}), * except that you may not use backquotes. */ -extern void optionLoadLine( tOptions*, char const* ); +extern void optionLoadLine(tOptions*, char const*); -/* From: configfile.c line 373 +/* From: configfile.c line 345 * * optionNextValue - get the next value from a hierarchical list * @@ -648,10 +704,10 @@ * The "@var{pOldValue}" must have been gotten from a prior call to this * routine or to "@code{opitonGetValue()}". */ -extern const tOptionValue* optionNextValue( const tOptionValue*, const tOptionValue* ); +extern const tOptionValue* optionNextValue(const tOptionValue*, const tOptionValue*); -/* From: usage.c line 128 +/* From: usage.c line 107 * * optionOnlyUsage - Print usage text for just the options * @@ -663,10 +719,10 @@ * This function may be used when the emitted usage must incorporate * information not available to AutoOpts. */ -extern void optionOnlyUsage( tOptions*, int ); +extern void optionOnlyUsage(tOptions*, int); -/* From: autoopts.c line 1012 +/* From: autoopts.c line 1058 * * optionProcess - this is the main option processing routine * @@ -693,10 +749,10 @@ * is treated as an operand. Encountering an operand stops option * processing. */ -extern int optionProcess( tOptions*, int, char** ); +extern int optionProcess(tOptions*, int, char**); -/* From: restore.c line 145 +/* From: restore.c line 122 * * optionRestore - restore option state from memory copy * @@ -710,10 +766,10 @@ * to optionProcess(3AO), then you may change the contents of the * argc/argv parameters to optionProcess. */ -extern void optionRestore( tOptions* ); +extern void optionRestore(tOptions*); -/* From: save.c line 334 +/* From: save.c line 671 * * optionSaveFile - saves the option state to a file * @@ -726,11 +782,19 @@ * @code{homerc} attribute. If no @code{rcfile} attribute was specified, it * will default to @code{.@i{programname}rc}. If you wish to specify another * file, you should invoke the @code{SET_OPT_SAVE_OPTS( @i{filename} )} macro. + * + * The recommend usage is as follows: + * @example + * optionProcess(&progOptions, argc, argv); + * if (i_want_a_non_standard_place_for_this) + * SET_OPT_SAVE_OPTS("myfilename"); + * optionSaveFile(&progOptions); + * @end example */ -extern void optionSaveFile( tOptions* ); +extern void optionSaveFile(tOptions*); -/* From: restore.c line 93 +/* From: restore.c line 70 * * optionSaveState - saves the option state to memory * @@ -749,10 +813,10 @@ * restoring of stacked string arguments and hierarchical values is * disabled. The values are not saved. */ -extern void optionSaveState( tOptions* ); +extern void optionSaveState(tOptions*); -/* From: nested.c line 559 +/* From: nested.c line 569 * * optionUnloadNested - Deallocate the memory for a nested value * @@ -763,10 +827,10 @@ * have been gotten from a call to @code{configFileLoad()} (See * @pxref{libopts-configFileLoad}). */ -extern void optionUnloadNested( tOptionValue const * ); +extern void optionUnloadNested(tOptionValue const *); -/* From: version.c line 58 +/* From: version.c line 37 * * optionVersion - return the compiled AutoOpts version number * @@ -775,10 +839,10 @@ * Returns the full version string compiled into the library. * The returned string cannot be modified. */ -extern char const* optionVersion( void ); +extern char const* optionVersion(void); -/* From: ../compat/pathfind.c line 34 +/* From: ../compat/pathfind.c line 32 * * pathfind - fild a file in a list of directories * @@ -818,11 +882,11 @@ * @end example */ #ifndef HAVE_PATHFIND -extern char* pathfind( char const*, char const*, char const* ); +extern char* pathfind(char const*, char const*, char const*); #endif /* HAVE_PATHFIND */ -/* From: streqvcmp.c line 233 +/* From: streqvcmp.c line 208 * * strequate - map a list of characters to the same value * @@ -834,10 +898,10 @@ * This function name is mapped to option_strequate so as to not conflict * with the POSIX name space. */ -extern void strequate( char const* ); +extern void strequate(char const*); -/* From: streqvcmp.c line 143 +/* From: streqvcmp.c line 118 * * streqvcmp - compare two strings with an equivalence mapping * @@ -853,10 +917,10 @@ * This function name is mapped to option_streqvcmp so as to not conflict * with the POSIX name space. */ -extern int streqvcmp( char const*, char const* ); +extern int streqvcmp(char const*, char const*); -/* From: streqvcmp.c line 180 +/* From: streqvcmp.c line 155 * * streqvmap - Set the character mappings for the streqv functions * @@ -881,10 +945,10 @@ * This function name is mapped to option_streqvmap so as to not conflict * with the POSIX name space. */ -extern void streqvmap( char, char, int ); +extern void streqvmap(char, char, int); -/* From: streqvcmp.c line 102 +/* From: streqvcmp.c line 77 * * strneqvcmp - compare two strings with an equivalence mapping * @@ -902,10 +966,10 @@ * This function name is mapped to option_strneqvcmp so as to not conflict * with the POSIX name space. */ -extern int strneqvcmp( char const*, char const*, int ); +extern int strneqvcmp(char const*, char const*, int); -/* From: streqvcmp.c line 259 +/* From: streqvcmp.c line 234 * * strtransform - convert a string into its mapped-to value * @@ -917,55 +981,65 @@ * character is put into the output. * This function name is mapped to option_strtransform so as to not conflict * with the POSIX name space. + * + * The source and destination may be the same. */ -extern void strtransform( char*, char const* ); +extern void strtransform(char*, char const*); /* AutoOpts PRIVATE FUNCTIONS: */ tOptProc optionStackArg, optionUnstackArg, optionBooleanVal, optionNumericVal; -extern char* ao_string_cook( char*, int* ); +extern char* ao_string_cook(char*, int*); + +extern unsigned int ao_string_cook_escape_char(char const*, char*, unsigned int); + +extern void export_options_to_guile(tOptions*); + +extern void genshelloptUsage(tOptions*, int); + +extern void optionBooleanVal(tOptions*, tOptDesc*); -extern unsigned int ao_string_cook_escape_char( char const*, char*, unsigned int ); +extern uintptr_t optionEnumerationVal(tOptions*, tOptDesc*, char const * const *, unsigned int); -extern void export_options_to_guile( tOptions* ); +extern void optionFileCheck(tOptions*, tOptDesc*, teOptFileType, tuFileMode); -extern void genshelloptUsage( tOptions*, int ); +extern char const* optionKeywordName(tOptDesc*, unsigned int); -extern void optionBooleanVal( tOptions*, tOptDesc* ); +extern void optionLoadOpt(tOptions*, tOptDesc*); -extern uintptr_t optionEnumerationVal( tOptions*, tOptDesc*, char const * const *, unsigned int ); +extern ag_bool optionMakePath(char*, int, char const*, char const*); -extern char const* optionKeywordName( tOptDesc*, unsigned int ); +extern void optionNestedVal(tOptions*, tOptDesc*); -extern void optionLoadOpt( tOptions*, tOptDesc* ); +extern void optionNumericVal(tOptions*, tOptDesc*); -extern ag_bool optionMakePath( char*, int, char const*, char const* ); +extern void optionPagedUsage(tOptions*, tOptDesc*); -extern void optionNestedVal( tOptions*, tOptDesc* ); +extern void optionParseShell(tOptions*); -extern void optionNumericVal( tOptions*, tOptDesc* ); +extern void optionPrintVersion(tOptions*, tOptDesc*); -extern void optionPagedUsage( tOptions*, tOptDesc* ); +extern void optionPutShell(tOptions*); -extern void optionParseShell( tOptions* ); +extern void optionResetOpt(tOptions*, tOptDesc*); -extern void optionPrintVersion( tOptions*, tOptDesc* ); +extern void optionSetMembers(tOptions*, tOptDesc*, char const * const *, unsigned int); -extern void optionPutShell( tOptions* ); +extern void optionShowRange(tOptions*, tOptDesc*, void *, int); -extern void optionSetMembers( tOptions*, tOptDesc*, char const * const *, unsigned int ); +extern void optionStackArg(tOptions*, tOptDesc*); -extern void optionStackArg( tOptions*, tOptDesc* ); +extern void optionTimeVal(tOptions*, tOptDesc*); -extern void optionUnstackArg( tOptions*, tOptDesc* ); +extern void optionUnstackArg(tOptions*, tOptDesc*); -extern void optionUsage( tOptions*, int ); +extern void optionUsage(tOptions*, int); -extern void optionVersionStderr( tOptions*, tOptDesc* ); +extern void optionVersionStderr(tOptions*, tOptDesc*); -extern void* text_mmap( char const*, int, int, tmap_info_t* ); +extern void* text_mmap(char const*, int, int, tmap_info_t*); -extern int text_munmap( tmap_info_t* ); +extern int text_munmap(tmap_info_t*); CPLUSPLUS_CLOSER #endif /* AUTOOPTS_OPTIONS_H_GUARD */ diff -urN src/contrib/ntp/libopts/autoopts/usage-txt.h src.ntp/contrib/ntp/libopts/autoopts/usage-txt.h --- src/contrib/ntp/libopts/autoopts/usage-txt.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/autoopts/usage-txt.h 2009-12-09 08:36:37.000000000 +0100 @@ -2,35 +2,32 @@ * * DO NOT EDIT THIS FILE (usage-txt.h) * - * It has been AutoGen-ed Saturday May 5, 2007 at 12:02:33 PM PDT + * It has been AutoGen-ed November 8, 2009 at 08:41:07 AM by AutoGen 5.9.10pre13 * From the definitions usage-txt.def * and the template file usage-txt.tpl * * This file handles all the bookkeeping required for tracking all the little - * tiny strings used by the AutoOpts library. There are 113 + * tiny strings used by the AutoOpts library. There are 134 * of them. This is not versioned because it is entirely internal to the * library and accessed by client code only in a very well-controlled way: * they may substitute translated strings using a procedure that steps through * all the string pointers. * - * AutoOpts is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. + * AutoOpts is free software: you can redistribute it and/or modify it + * under the terms of the GNU Lesser General Public License as published + * by the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. * - * AutoOpts is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. + * AutoOpts is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the GNU Lesser General Public License for more details. * - * You should have received a copy of the GNU Lesser General Public - * License along with AutoOpts. If not, write to: - * The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor - * Boston, MA 02110-1301, USA. + * You should have received a copy of the GNU Lesser General Public License + * along with this program. If not, see . */ #ifndef AUTOOPTS_USAGE_TXT_H_GUARD -#define AUTOOPTS_USAGE_TXT_H_GUARD +#define AUTOOPTS_USAGE_TXT_H_GUARD 1 #undef cch_t #define cch_t char const @@ -42,10 +39,12 @@ int field_ct; char* utpz_GnuBoolArg; char* utpz_GnuKeyArg; + char* utpz_GnuFileArg; char* utpz_GnuKeyLArg; + char* utpz_GnuTimeArg; char* utpz_GnuNumArg; char* utpz_GnuStrArg; - cch_t* apz_str[ 108 ]; + cch_t* apz_str[ 127 ]; } usage_text_t; /* @@ -62,115 +61,136 @@ #define zAO_Big (option_usage_text.apz_str[ 1]) #define zAO_Err (option_usage_text.apz_str[ 2]) #define zAO_Sml (option_usage_text.apz_str[ 3]) -#define zAll (option_usage_text.apz_str[ 4]) -#define zAlt (option_usage_text.apz_str[ 5]) -#define zAmbigKey (option_usage_text.apz_str[ 6]) -#define zAmbiguous (option_usage_text.apz_str[ 7]) -#define zArgsMust (option_usage_text.apz_str[ 8]) -#define zAtMost (option_usage_text.apz_str[ 9]) -#define zAuto (option_usage_text.apz_str[ 10]) -#define zBadPipe (option_usage_text.apz_str[ 11]) -#define zBadVerArg (option_usage_text.apz_str[ 12]) -#define zCantFmt (option_usage_text.apz_str[ 13]) -#define zCantSave (option_usage_text.apz_str[ 14]) -#define zDefaultOpt (option_usage_text.apz_str[ 15]) -#define zDis (option_usage_text.apz_str[ 16]) -#define zEnab (option_usage_text.apz_str[ 17]) -#define zEquiv (option_usage_text.apz_str[ 18]) -#define zErrOnly (option_usage_text.apz_str[ 19]) -#define zExamineFmt (option_usage_text.apz_str[ 20]) -#define zFiveSpaces (option_usage_text.apz_str[ 21]) -#define zFlagOkay (option_usage_text.apz_str[ 22]) -#define zFmtFmt (option_usage_text.apz_str[ 23]) -#define zForkFail (option_usage_text.apz_str[ 24]) -#define zFSErrOptLoad (option_usage_text.apz_str[ 25]) -#define zFSErrReadFile (option_usage_text.apz_str[ 26]) -#define zGenshell (option_usage_text.apz_str[ 27]) +#define zAO_Ver (option_usage_text.apz_str[ 4]) +#define zAO_Woops (option_usage_text.apz_str[ 5]) +#define zAliasRange (option_usage_text.apz_str[ 6]) +#define zAll (option_usage_text.apz_str[ 7]) +#define zAlt (option_usage_text.apz_str[ 8]) +#define zAmbigKey (option_usage_text.apz_str[ 9]) +#define zAmbigOptStr (option_usage_text.apz_str[ 10]) +#define zArgsMust (option_usage_text.apz_str[ 11]) +#define zAtMost (option_usage_text.apz_str[ 12]) +#define zAuto (option_usage_text.apz_str[ 13]) +#define zBadPipe (option_usage_text.apz_str[ 14]) +#define zBadVerArg (option_usage_text.apz_str[ 15]) +#define zCantFmt (option_usage_text.apz_str[ 16]) +#define zCantSave (option_usage_text.apz_str[ 17]) +#define zDefaultOpt (option_usage_text.apz_str[ 18]) +#define zDis (option_usage_text.apz_str[ 19]) +#define zDisabledErr (option_usage_text.apz_str[ 20]) +#define zDisabledOpt (option_usage_text.apz_str[ 21]) +#define zDisabledWhy (option_usage_text.apz_str[ 22]) +#define zEnab (option_usage_text.apz_str[ 23]) +#define zEquiv (option_usage_text.apz_str[ 24]) +#define zErrOnly (option_usage_text.apz_str[ 25]) +#define zExamineFmt (option_usage_text.apz_str[ 26]) +#define zFiveSpaces (option_usage_text.apz_str[ 27]) +#define zFlagOkay (option_usage_text.apz_str[ 28]) +#define zFmtFmt (option_usage_text.apz_str[ 29]) +#define zForkFail (option_usage_text.apz_str[ 30]) +#define zFSErrOptLoad (option_usage_text.apz_str[ 31]) +#define zFSErrReadFile (option_usage_text.apz_str[ 32]) +#define zFSOptError (option_usage_text.apz_str[ 33]) +#define zFSOptErrMayExist (option_usage_text.apz_str[ 34]) +#define zFSOptErrMustExist (option_usage_text.apz_str[ 35]) +#define zFSOptErrNoExist (option_usage_text.apz_str[ 36]) +#define zFSOptErrOpen (option_usage_text.apz_str[ 37]) +#define zFSOptErrFopen (option_usage_text.apz_str[ 38]) +#define zFileCannotExist (option_usage_text.apz_str[ 39]) +#define zFileMustExist (option_usage_text.apz_str[ 40]) +#define zGenshell (option_usage_text.apz_str[ 41]) #define zGnuBoolArg (option_usage_text.utpz_GnuBoolArg) -#define zGnuBreak (option_usage_text.apz_str[ 28]) +#define zGnuBreak (option_usage_text.apz_str[ 42]) #define zGnuKeyArg (option_usage_text.utpz_GnuKeyArg) +#define zGnuFileArg (option_usage_text.utpz_GnuFileArg) #define zGnuKeyLArg (option_usage_text.utpz_GnuKeyLArg) -#define zGnuNestArg (option_usage_text.apz_str[ 29]) +#define zGnuTimeArg (option_usage_text.utpz_GnuTimeArg) +#define zGnuNestArg (option_usage_text.apz_str[ 43]) #define zGnuNumArg (option_usage_text.utpz_GnuNumArg) -#define zGnuOptArg (option_usage_text.apz_str[ 30]) -#define zGnuOptFmt (option_usage_text.apz_str[ 31]) +#define zGnuOptArg (option_usage_text.apz_str[ 44]) +#define zGnuOptFmt (option_usage_text.apz_str[ 45]) #define zGnuStrArg (option_usage_text.utpz_GnuStrArg) -#define zIllOptChr (option_usage_text.apz_str[ 32]) -#define zIllOptStr (option_usage_text.apz_str[ 33]) -#define zIllegal (option_usage_text.apz_str[ 34]) -#define zInvalOptDesc (option_usage_text.apz_str[ 35]) -#define zKeyWords (option_usage_text.apz_str[ 36]) -#define zLoadCooked (option_usage_text.apz_str[ 37]) -#define zLoadKeep (option_usage_text.apz_str[ 38]) -#define zLoadType (option_usage_text.apz_str[ 39]) -#define zLoadUncooked (option_usage_text.apz_str[ 40]) -#define zLtypeInteger (option_usage_text.apz_str[ 41]) -#define zLtypeNest (option_usage_text.apz_str[ 42]) -#define zLtypeString (option_usage_text.apz_str[ 43]) -#define zLtypeBool (option_usage_text.apz_str[ 44]) -#define zLtypeKeyword (option_usage_text.apz_str[ 45]) -#define zLtypeSetMembership (option_usage_text.apz_str[ 46]) -#define zMembers (option_usage_text.apz_str[ 47]) -#define zMisArg (option_usage_text.apz_str[ 48]) -#define zMultiEquiv (option_usage_text.apz_str[ 49]) -#define zMust (option_usage_text.apz_str[ 50]) -#define zNeedOne (option_usage_text.apz_str[ 51]) -#define zNoArg (option_usage_text.apz_str[ 52]) -#define zNoArgs (option_usage_text.apz_str[ 53]) -#define zNoCreat (option_usage_text.apz_str[ 54]) -#define zNoFlags (option_usage_text.apz_str[ 55]) -#define zNoKey (option_usage_text.apz_str[ 56]) -#define zNoLim (option_usage_text.apz_str[ 57]) -#define zNoPreset (option_usage_text.apz_str[ 58]) -#define zNoRq_NoShrtTtl (option_usage_text.apz_str[ 59]) -#define zNoRq_ShrtTtl (option_usage_text.apz_str[ 60]) -#define zNoStat (option_usage_text.apz_str[ 61]) -#define zNoState (option_usage_text.apz_str[ 62]) -#define zNone (option_usage_text.apz_str[ 63]) -#define zNotDef (option_usage_text.apz_str[ 64]) -#define zNotEnough (option_usage_text.apz_str[ 65]) -#define zNotFile (option_usage_text.apz_str[ 66]) -#define zNotNumber (option_usage_text.apz_str[ 67]) -#define zNrmOptFmt (option_usage_text.apz_str[ 68]) -#define zNumberOpt (option_usage_text.apz_str[ 69]) -#define zOneSpace (option_usage_text.apz_str[ 70]) -#define zOnlyOne (option_usage_text.apz_str[ 71]) -#define zOptsOnly (option_usage_text.apz_str[ 72]) -#define zPathFmt (option_usage_text.apz_str[ 73]) -#define zPlsSendBugs (option_usage_text.apz_str[ 74]) -#define zPreset (option_usage_text.apz_str[ 75]) -#define zPresetFile (option_usage_text.apz_str[ 76]) -#define zPresetIntro (option_usage_text.apz_str[ 77]) -#define zProg (option_usage_text.apz_str[ 78]) -#define zProhib (option_usage_text.apz_str[ 79]) -#define zReorder (option_usage_text.apz_str[ 80]) -#define zReqFmt (option_usage_text.apz_str[ 81]) -#define zReqOptFmt (option_usage_text.apz_str[ 82]) -#define zReqThese (option_usage_text.apz_str[ 83]) -#define zReq_NoShrtTtl (option_usage_text.apz_str[ 84]) -#define zReq_ShrtTtl (option_usage_text.apz_str[ 85]) -#define zSepChars (option_usage_text.apz_str[ 86]) -#define zSetMembers (option_usage_text.apz_str[ 87]) -#define zSetMemberSettings (option_usage_text.apz_str[ 88]) -#define zShrtGnuOptFmt (option_usage_text.apz_str[ 89]) -#define zSixSpaces (option_usage_text.apz_str[ 90]) -#define zStdBoolArg (option_usage_text.apz_str[ 91]) -#define zStdBreak (option_usage_text.apz_str[ 92]) -#define zStdKeyArg (option_usage_text.apz_str[ 93]) -#define zStdKeyLArg (option_usage_text.apz_str[ 94]) -#define zStdNestArg (option_usage_text.apz_str[ 95]) -#define zStdNoArg (option_usage_text.apz_str[ 96]) -#define zStdNumArg (option_usage_text.apz_str[ 97]) -#define zStdOptArg (option_usage_text.apz_str[ 98]) -#define zStdReqArg (option_usage_text.apz_str[ 99]) -#define zStdStrArg (option_usage_text.apz_str[100]) -#define zTabHyp (option_usage_text.apz_str[101]) -#define zTabHypAnd (option_usage_text.apz_str[102]) -#define zTabout (option_usage_text.apz_str[103]) -#define zThreeSpaces (option_usage_text.apz_str[104]) -#define zTwoSpaces (option_usage_text.apz_str[105]) -#define zUpTo (option_usage_text.apz_str[106]) -#define zValidKeys (option_usage_text.apz_str[107]) +#define zIllOptChr (option_usage_text.apz_str[ 46]) +#define zIllOptStr (option_usage_text.apz_str[ 47]) +#define zIllegal (option_usage_text.apz_str[ 48]) +#define zIntRange (option_usage_text.apz_str[ 49]) +#define zInvalOptDesc (option_usage_text.apz_str[ 50]) +#define zLowerBits (option_usage_text.apz_str[ 51]) +#define zMembers (option_usage_text.apz_str[ 52]) +#define zMisArg (option_usage_text.apz_str[ 53]) +#define zMultiEquiv (option_usage_text.apz_str[ 54]) +#define zMust (option_usage_text.apz_str[ 55]) +#define zNeedOne (option_usage_text.apz_str[ 56]) +#define zNoArg (option_usage_text.apz_str[ 57]) +#define zNoArgs (option_usage_text.apz_str[ 58]) +#define zNoCreat (option_usage_text.apz_str[ 59]) +#define zNoFlags (option_usage_text.apz_str[ 60]) +#define zNoKey (option_usage_text.apz_str[ 61]) +#define zNoLim (option_usage_text.apz_str[ 62]) +#define zNoPreset (option_usage_text.apz_str[ 63]) +#define zNoResetArg (option_usage_text.apz_str[ 64]) +#define zNoRq_NoShrtTtl (option_usage_text.apz_str[ 65]) +#define zNoRq_ShrtTtl (option_usage_text.apz_str[ 66]) +#define zNoStat (option_usage_text.apz_str[ 67]) +#define zNoState (option_usage_text.apz_str[ 68]) +#define zNone (option_usage_text.apz_str[ 69]) +#define zNotDef (option_usage_text.apz_str[ 70]) +#define zNotCmdOpt (option_usage_text.apz_str[ 71]) +#define zNotEnough (option_usage_text.apz_str[ 72]) +#define zNotFile (option_usage_text.apz_str[ 73]) +#define zNotNumber (option_usage_text.apz_str[ 74]) +#define zNrmOptFmt (option_usage_text.apz_str[ 75]) +#define zNumberOpt (option_usage_text.apz_str[ 76]) +#define zOneSpace (option_usage_text.apz_str[ 77]) +#define zOnlyOne (option_usage_text.apz_str[ 78]) +#define zOptsOnly (option_usage_text.apz_str[ 79]) +#define zPathFmt (option_usage_text.apz_str[ 80]) +#define zPlsSendBugs (option_usage_text.apz_str[ 81]) +#define zPreset (option_usage_text.apz_str[ 82]) +#define zPresetFile (option_usage_text.apz_str[ 83]) +#define zPresetIntro (option_usage_text.apz_str[ 84]) +#define zProg (option_usage_text.apz_str[ 85]) +#define zProhib (option_usage_text.apz_str[ 86]) +#define zReorder (option_usage_text.apz_str[ 87]) +#define zRange (option_usage_text.apz_str[ 88]) +#define zRangeAbove (option_usage_text.apz_str[ 89]) +#define zRangeLie (option_usage_text.apz_str[ 90]) +#define zRangeBadLie (option_usage_text.apz_str[ 91]) +#define zRangeOnly (option_usage_text.apz_str[ 92]) +#define zRangeOr (option_usage_text.apz_str[ 93]) +#define zRangeErr (option_usage_text.apz_str[ 94]) +#define zRangeExact (option_usage_text.apz_str[ 95]) +#define zRangeScaled (option_usage_text.apz_str[ 96]) +#define zRangeUpto (option_usage_text.apz_str[ 97]) +#define zResetNotConfig (option_usage_text.apz_str[ 98]) +#define zReqFmt (option_usage_text.apz_str[ 99]) +#define zReqOptFmt (option_usage_text.apz_str[100]) +#define zReqThese (option_usage_text.apz_str[101]) +#define zReq_NoShrtTtl (option_usage_text.apz_str[102]) +#define zReq_ShrtTtl (option_usage_text.apz_str[103]) +#define zSepChars (option_usage_text.apz_str[104]) +#define zSetMemberSettings (option_usage_text.apz_str[105]) +#define zShrtGnuOptFmt (option_usage_text.apz_str[106]) +#define zSixSpaces (option_usage_text.apz_str[107]) +#define zStdBoolArg (option_usage_text.apz_str[108]) +#define zStdBreak (option_usage_text.apz_str[109]) +#define zStdFileArg (option_usage_text.apz_str[110]) +#define zStdKeyArg (option_usage_text.apz_str[111]) +#define zStdKeyLArg (option_usage_text.apz_str[112]) +#define zStdTimeArg (option_usage_text.apz_str[113]) +#define zStdNestArg (option_usage_text.apz_str[114]) +#define zStdNoArg (option_usage_text.apz_str[115]) +#define zStdNumArg (option_usage_text.apz_str[116]) +#define zStdOptArg (option_usage_text.apz_str[117]) +#define zStdReqArg (option_usage_text.apz_str[118]) +#define zStdStrArg (option_usage_text.apz_str[119]) +#define zTabHyp (option_usage_text.apz_str[120]) +#define zTabHypAnd (option_usage_text.apz_str[121]) +#define zTabout (option_usage_text.apz_str[122]) +#define zThreeSpaces (option_usage_text.apz_str[123]) +#define zTwoSpaces (option_usage_text.apz_str[124]) +#define zUpTo (option_usage_text.apz_str[125]) +#define zValidKeys (option_usage_text.apz_str[126]) /* * First, set up the strings. Some of these are writable. These are all in @@ -180,19 +200,25 @@ static char eng_zGnuBoolArg[] = "=T/F"; static char eng_zGnuKeyArg[] = "=KWd"; + static char eng_zGnuFileArg[] = "=file"; static char eng_zGnuKeyLArg[] = "=Mbr"; + static char eng_zGnuTimeArg[] = "=Tim"; static char eng_zGnuNumArg[] = "=num"; static char eng_zGnuStrArg[] = "=str"; -static char const usage_txt[3208] = +static char const usage_txt[4159] = "AutoOpts function called without option descriptor\n\0" "\tThis exceeds the compiled library version: \0" "Automated Options Processing Error!\n" "\t%s called AutoOpts function with structure version %d:%d:%d.\n\0" "\tThis is less than the minimum library version: \0" + "Automated Options version %s\n" + "\tcopyright (c) 1999-2009 by Bruce Korb - all rights reserved\n\0" + "AutoOpts lib error: defaulted to option with optional arg\n\0" + "(AutoOpts bug): Aliasing option is out of range.\0" "all\0" "\t\t\t\t- an alternate for %s\n\0" "%s error: the keyword `%s' is ambiguous for %s\n\0" - "ambiguous\0" + "%s: ambiguous option -- %s\n\0" "%s: Command line arguments required\n\0" "%d %s%s options allowed\n\0" "version and help options:\0" @@ -205,6 +231,9 @@ "%s(optionSaveState): error: cannot allocate %d bytes\n\0" "\t\t\t\t- default option for unnamed options\n\0" "\t\t\t\t- disabled as --%s\n\0" + "%s: The ``%s'' option has been disabled\0" + " --- %-14s %s\n\0" + "This option has been disabled\0" "\t\t\t\t- enabled by default\n\0" "-equivalence\0" "ERROR: only \0" @@ -216,6 +245,14 @@ "fs error %d (%s) on fork - cannot obtain %s usage\n\0" "File error %d (%s) opening %s for loading options\n\0" "fs error %d (%s) reading file %s\n\0" + "fs error %d (%s) on %s %s for option %s\n\0" + "stat-ing for directory\0" + "stat-ing for regular file\0" + "stat-ing for non-existant file\0" + "open-ing file\0" + "fopen-ing file\0" + "\t\t\t\t- file must not pre-exist\n\0" + "\t\t\t\t- file must pre-exist\n\0" "\n" "= = = = = = = =\n\n" "This incarnation of genshell will produce\n" @@ -226,20 +263,11 @@ "[=arg]\0" "--%2$s%1$s\0" "%s: illegal option -- %c\n\0" - "%s: %s option -- %s\n\0" + "%s: illegal option -- %s\n\0" "illegal\0" + " or an integer from %d through %d\n\0" "AutoOpts ERROR: invalid option descriptor for %s\n\0" - "words=\0" - "cooked\0" - "keep\0" - "type=\0" - "uncooked\0" - "integer\0" - "nested\0" - "string\0" - "bool\0" - "keyword\0" - "set\0" + " or an integer mask with any of the lower %d bits set\n\0" "\t\t\t\t- is a set membership option\n\0" "%s: option `%s' requires an argument\n\0" "Equivalenced option '%s' was equivalenced to both\n" @@ -253,12 +281,14 @@ "%s error: `%s' does not match any %s keywords\n\0" "\t\t\t\t- may appear multiple times\n\0" "\t\t\t\t- may not be preset\n\0" + "The 'reset-option' option requires an argument\n\0" " Arg Option-Name Description\n\0" " Flg Arg Option-Name Description\n\0" "error %d (%s) stat-ing %s\n\0" "%s(optionRestore): error: no saved option state\n\0" "none\0" "'%s' not defined\n\0" + "'%s' is not a command line option\n\0" "ERROR: The %s option must appear %d times\n\0" "error: cannot load options from non-regular file %s\n\0" "%s error: `%s' is not a recognizable number\n\0" @@ -278,13 +308,23 @@ "program\0" "prohibits these options:\n\0" "Operands and options may be intermixed. They will be reordered.\n\0" + "%s%ld to %ld\0" + "%sgreater than or equal to %ld\0" + "%sIt must lie in one of the ranges:\n\0" + "%sThis option must lie in one of the ranges:\n\0" + "%sit must be: \0" + ", or\n\0" + "%s error: %s option value ``%s'' is out of range.\n\0" + "%s%ld exactly\0" + "%sis scalable with a suffix: k/K/m/M/g/G/t/T\n\0" + "%sless than or equal to %ld\0" + "The --reset-option has not been configured.\n\0" "ERROR: %s option requires the %s option\n\0" " %3s %-14s %s\0" "requires these options:\n\0" " Arg Option-Name Req? Description\n\0" " Flg Arg Option-Name Req? Description\n\0" "-_^\0" - "members=\0" "or you may use a numeric representation. Preceding these with a '!' will\n" "clear the bits, specifying 'none' will clear all bits, and 'all' will set them\n" "all. Multiple entries may be passed as an option argument list.\n\0" @@ -294,8 +334,10 @@ "\n" "%s\n\n" "%s\0" + "Fil\0" "KWd\0" "Mbr\0" + "Tim\0" "Cpx\0" "no \0" "Num\0" @@ -317,37 +359,42 @@ * Aren't you glad you don't maintain this by hand? */ usage_text_t option_usage_text = { - 113, - eng_zGnuBoolArg, eng_zGnuKeyArg, eng_zGnuKeyLArg, eng_zGnuNumArg, - eng_zGnuStrArg, + 134, + eng_zGnuBoolArg, eng_zGnuKeyArg, eng_zGnuFileArg, eng_zGnuKeyLArg, + eng_zGnuTimeArg, eng_zGnuNumArg, eng_zGnuStrArg, { usage_txt + 0, usage_txt + 52, usage_txt + 98, usage_txt + 197, - usage_txt + 247, usage_txt + 251, usage_txt + 278, usage_txt + 327, - usage_txt + 337, usage_txt + 374, usage_txt + 399, usage_txt + 425, - usage_txt + 465, usage_txt + 602, usage_txt + 650, usage_txt + 704, - usage_txt + 746, usage_txt + 770, usage_txt + 796, usage_txt + 809, - usage_txt + 823, usage_txt + 870, usage_txt + 876, usage_txt + 979, - usage_txt + 991, usage_txt +1042, usage_txt +1093, usage_txt +1127, - usage_txt +1233, usage_txt +1239, usage_txt +1245, usage_txt +1252, - usage_txt +1263, usage_txt +1289, usage_txt +1310, usage_txt +1318, - usage_txt +1369, usage_txt +1376, usage_txt +1383, usage_txt +1388, - usage_txt +1394, usage_txt +1403, usage_txt +1411, usage_txt +1418, - usage_txt +1425, usage_txt +1430, usage_txt +1438, usage_txt +1442, - usage_txt +1476, usage_txt +1514, usage_txt +1579, usage_txt +1622, - usage_txt +1657, usage_txt +1698, usage_txt +1738, usage_txt +1765, - usage_txt +1832, usage_txt +1880, usage_txt +1913, usage_txt +1938, - usage_txt +1973, usage_txt +2011, usage_txt +2038, usage_txt +2087, - usage_txt +2092, usage_txt +2110, usage_txt +2154, usage_txt +2208, - usage_txt +2254, usage_txt +2262, usage_txt +2310, usage_txt +2312, - usage_txt +2337, usage_txt +2371, usage_txt +2390, usage_txt +2424, - usage_txt +2460, usage_txt +2498, usage_txt +2554, usage_txt +2562, - usage_txt +2588, usage_txt +2654, usage_txt +2696, usage_txt +2710, - usage_txt +2735, usage_txt +2775, usage_txt +2818, usage_txt +2822, - usage_txt +2831, usage_txt +3050, usage_txt +3053, usage_txt +3060, - usage_txt +3064, usage_txt +3072, usage_txt +3076, usage_txt +3080, - usage_txt +3084, usage_txt +3088, usage_txt +3092, usage_txt +3096, - usage_txt +3100, usage_txt +3104, usage_txt +3111, usage_txt +3123, - usage_txt +3131, usage_txt +3135, usage_txt +3138, usage_txt +3171 + usage_txt + 247, usage_txt + 338, usage_txt + 397, usage_txt + 447, + usage_txt + 451, usage_txt + 478, usage_txt + 527, usage_txt + 555, + usage_txt + 592, usage_txt + 617, usage_txt + 643, usage_txt + 683, + usage_txt + 820, usage_txt + 868, usage_txt + 922, usage_txt + 964, + usage_txt + 988, usage_txt +1028, usage_txt +1043, usage_txt +1073, + usage_txt +1099, usage_txt +1112, usage_txt +1126, usage_txt +1173, + usage_txt +1179, usage_txt +1282, usage_txt +1294, usage_txt +1345, + usage_txt +1396, usage_txt +1430, usage_txt +1471, usage_txt +1494, + usage_txt +1520, usage_txt +1551, usage_txt +1565, usage_txt +1580, + usage_txt +1611, usage_txt +1638, usage_txt +1744, usage_txt +1750, + usage_txt +1756, usage_txt +1763, usage_txt +1774, usage_txt +1800, + usage_txt +1826, usage_txt +1834, usage_txt +1870, usage_txt +1921, + usage_txt +1977, usage_txt +2011, usage_txt +2049, usage_txt +2114, + usage_txt +2157, usage_txt +2192, usage_txt +2233, usage_txt +2273, + usage_txt +2300, usage_txt +2367, usage_txt +2415, usage_txt +2448, + usage_txt +2473, usage_txt +2521, usage_txt +2556, usage_txt +2594, + usage_txt +2621, usage_txt +2670, usage_txt +2675, usage_txt +2693, + usage_txt +2728, usage_txt +2772, usage_txt +2826, usage_txt +2872, + usage_txt +2880, usage_txt +2928, usage_txt +2930, usage_txt +2955, + usage_txt +2989, usage_txt +3008, usage_txt +3042, usage_txt +3078, + usage_txt +3116, usage_txt +3172, usage_txt +3180, usage_txt +3206, + usage_txt +3272, usage_txt +3285, usage_txt +3316, usage_txt +3353, + usage_txt +3399, usage_txt +3415, usage_txt +3421, usage_txt +3473, + usage_txt +3487, usage_txt +3533, usage_txt +3561, usage_txt +3606, + usage_txt +3648, usage_txt +3662, usage_txt +3687, usage_txt +3727, + usage_txt +3770, usage_txt +3774, usage_txt +3993, usage_txt +3996, + usage_txt +4003, usage_txt +4007, usage_txt +4015, usage_txt +4019, + usage_txt +4023, usage_txt +4027, usage_txt +4031, usage_txt +4035, + usage_txt +4039, usage_txt +4043, usage_txt +4047, usage_txt +4051, + usage_txt +4055, usage_txt +4062, usage_txt +4074, usage_txt +4082, + usage_txt +4086, usage_txt +4089, usage_txt +4122 } }; diff -urN src/contrib/ntp/libopts/autoopts.c src.ntp/contrib/ntp/libopts/autoopts.c --- src/contrib/ntp/libopts/autoopts.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/autoopts.c 2009-12-09 08:36:35.000000000 +0100 @@ -1,66 +1,52 @@ /* - * $Id: autoopts.c,v 4.25 2007/04/15 19:01:18 bkorb Exp $ - * Time-stamp: "2007-04-15 11:10:40 bkorb" + * $Id: 56abb301f50605ec5bae137ded730e330d8d7735 $ + * Time-stamp: "2009-11-01 10:50:34 bkorb" * * This file contains all of the routines that must be linked into * an executable to use the generated option processing. The optional * routines are in separately compiled modules so that they will not * necessarily be linked in. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ static char const zNil[] = ""; /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static tSuccess findOptDesc( tOptions* pOpts, tOptState* pOptState ); static tSuccess -nextOption( tOptions* pOpts, tOptState* pOptState ); +next_opt_arg_must(tOptions* pOpts, tOptState* pOptState); + +static tSuccess +next_opt_arg_may(tOptions* pOpts, tOptState* pOptState); + +static tSuccess +next_opt_arg_none(tOptions* pOpts, tOptState* pOptState); + +static tSuccess +nextOption(tOptions* pOpts, tOptState* pOptState); static tSuccess doPresets( tOptions* pOpts ); @@ -111,7 +97,7 @@ { char * res = strdup(str); if (res == NULL) { - fprintf( stderr, "strdup of %d byte string failed\n", (int)strlen(str) ); + fprintf(stderr, "strdup of %d byte string failed\n", (int)strlen(str)); exit( EXIT_FAILURE ); } return res; @@ -254,7 +240,7 @@ /* * If provided a procedure to call, call it */ - if (pOP != (tpOptProc)NULL) + if (pOP != NULL) (*pOP)( pOpts, pOD ); return SUCCESS; @@ -284,20 +270,30 @@ int matchCt = 0; int matchIdx = 0; int nameLen; + char opt_name_buf[128]; /* * IF the value is attached to the name, - * THEN clip it off. - * Either way, figure out how long our name is + * copy it off so we can NUL terminate. */ if (pzEq != NULL) { nameLen = (int)(pzEq - pzOptName); - *pzEq = NUL; + if (nameLen >= sizeof(opt_name_buf)) + return FAILURE; + memcpy(opt_name_buf, pzOptName, nameLen); + opt_name_buf[nameLen] = NUL; + pzOptName = opt_name_buf; + pzEq++; + } else nameLen = strlen( pzOptName ); do { - if (SKIP_OPT(pOD)) - continue; + if (SKIP_OPT(pOD)) { + if ( (pOD->fOptState != (OPTST_OMITTED | OPTST_NO_INIT)) + || (pOD->pz_Name == NULL)) + continue; + } + else assert(pOD->pz_Name != NULL); if (strneqvcmp( pzOptName, pOD->pz_Name, nameLen ) == 0) { /* @@ -348,13 +344,21 @@ } while (pOD++, (++idx < idxLim)); - if (pzEq != NULL) - *(pzEq++) = '='; - /* * Make sure we either found an exact match or found only one partial */ if (matchCt == 1) { + pOD = pOpts->pOptDesc + matchIdx; + + if (SKIP_OPT(pOD)) { + fprintf(stderr, zDisabledErr, pOpts->pzProgName, pOD->pz_Name); + if (pOD->pzText != NULL) + fprintf(stderr, " -- %s", pOD->pzText); + fputc('\n', stderr); + (*pOpts->pUsageProc)(pOpts, EXIT_FAILURE); + /* NOTREACHED */ + } + /* * IF we found a disablement name, * THEN set the bit in the callers' flag word @@ -362,7 +366,7 @@ if (disable) pOptState->flags |= OPTST_DISABLED; - pOptState->pOD = pOpts->pOptDesc + matchIdx; + pOptState->pOD = pOD; pOptState->pzOptArg = pzEq; pOptState->optType = TOPT_LONG; return SUCCESS; @@ -389,9 +393,9 @@ * THEN call the usage procedure. */ if ((pOpts->fOptSet & OPTPROC_ERRSTOP) != 0) { - fprintf( stderr, zIllOptStr, pOpts->pzProgPath, - (matchCt == 0) ? zIllegal : zAmbiguous, pzOptName ); - (*pOpts->pUsageProc)( pOpts, EXIT_FAILURE ); + fprintf(stderr, (matchCt == 0) ? zIllOptStr : zAmbigOptStr, + pOpts->pzProgPath, pzOptName); + (*pOpts->pUsageProc)(pOpts, EXIT_FAILURE); } return FAILURE; @@ -412,28 +416,28 @@ /* * Search the option list */ - for (;;) { - /* - * IF the values match, - * THEN we stop here - */ - if ((! SKIP_OPT(pRes)) && (optValue == pRes->optValue)) { - pOptState->pOD = pRes; - pOptState->optType = TOPT_SHORT; - return SUCCESS; + do { + if (optValue != pRes->optValue) + continue; + + if (SKIP_OPT(pRes)) { + if ( (pRes->fOptState == (OPTST_OMITTED | OPTST_NO_INIT)) + && (pRes->pz_Name != NULL)) { + fprintf(stderr, zDisabledErr, pOpts->pzProgPath, pRes->pz_Name); + if (pRes->pzText != NULL) + fprintf(stderr, " -- %s", pRes->pzText); + fputc('\n', stderr); + (*pOpts->pUsageProc)(pOpts, EXIT_FAILURE); + /* NOTREACHED */ + } + goto short_opt_error; } - /* - * Advance to next option description - */ - pRes++; + pOptState->pOD = pRes; + pOptState->optType = TOPT_SHORT; + return SUCCESS; - /* - * IF we have searched everything, ... - */ - if (--ct <= 0) - break; - } + } while (pRes++, --ct > 0); /* * IF the character value is a digit @@ -441,7 +445,7 @@ * THEN the result is the "option" itself and the * option is the specially marked "number" option. */ - if ( isdigit( optValue ) + if ( IS_DEC_DIGIT_CHAR(optValue) && (pOpts->specOptIdx.number_option != NO_EQUIVALENT) ) { pOptState->pOD = \ pRes = pOpts->pOptDesc + pOpts->specOptIdx.number_option; @@ -450,6 +454,8 @@ return SUCCESS; } + short_opt_error: + /* * IF we are to stop on errors (the default, actually) * THEN call the usage procedure. @@ -488,16 +494,28 @@ * IF all arguments must be named options, ... */ if (NAMED_OPTS(pOpts)) { - char* pz = pOpts->pzCurOpt; + char * pz = pOpts->pzCurOpt; + int def; + tSuccess res; + tAoUS * def_opt; + pOpts->curOptIdx++; - /* - * Skip over any flag/option markers. - * In this mode, they are not required. - */ - while (*pz == '-') pz++; + if (*pz != '-') + return longOptionFind(pOpts, pz, pOptState); - return longOptionFind( pOpts, pz, pOptState ); + /* + * The name is prefixed with one or more hyphens. Strip them off + * and disable the "default_opt" setting. Use heavy recasting to + * strip off the "const" quality of the "default_opt" field. + */ + while (*(++pz) == '-') ; + def_opt = (void *)&(pOpts->specOptIdx.default_opt); + def = *def_opt; + *def_opt = NO_EQUIVALENT; + res = longOptionFind(pOpts, pz, pOptState); + *def_opt = def; + return res; } /* @@ -553,186 +571,213 @@ } -/* - * nextOption - * - * Find the option descriptor and option argument (if any) for the - * next command line argument. DO NOT modify the descriptor. Put - * all the state in the state argument so that the option can be skipped - * without consequence (side effect). - */ static tSuccess -nextOption( tOptions* pOpts, tOptState* pOptState ) +next_opt_arg_must(tOptions* pOpts, tOptState* pOptState) { - tSuccess res; - enum { ARG_NONE, ARG_MAY, ARG_MUST } arg_type = ARG_NONE; - teOptArgType at; - - res = findOptDesc( pOpts, pOptState ); - if (! SUCCESSFUL( res )) - return res; - pOptState->flags |= (pOptState->pOD->fOptState & OPTST_PERSISTENT_MASK); - at = OPTST_GET_ARGTYPE(pOptState->flags); - /* - * Figure out what to do about option arguments. An argument may be - * required, not associated with the option, or be optional. We detect the - * latter by examining for an option marker on the next possible argument. - * Disabled mode option selection also disables option arguments. + * An option argument is required. Long options can either have + * a separate command line argument, or an argument attached by + * the '=' character. Figure out which. */ - if ((pOptState->flags & OPTST_DISABLED) != 0) - arg_type = ARG_NONE; - else if (at == OPARG_TYPE_NONE) - arg_type = ARG_NONE; - else if (pOptState->flags & OPTST_ARG_OPTIONAL) - arg_type = ARG_MAY; - else - arg_type = ARG_MUST; - - switch (arg_type) { - case ARG_MUST: + switch (pOptState->optType) { + case TOPT_SHORT: /* - * An option argument is required. Long options can either have - * a separate command line argument, or an argument attached by - * the '=' character. Figure out which. + * See if an arg string follows the flag character */ - switch (pOptState->optType) { - case TOPT_SHORT: - /* - * See if an arg string follows the flag character - */ - if (*++(pOpts->pzCurOpt) == NUL) - pOpts->pzCurOpt = pOpts->origArgVect[ pOpts->curOptIdx++ ]; - pOptState->pzOptArg = pOpts->pzCurOpt; - break; + if (*++(pOpts->pzCurOpt) == NUL) + pOpts->pzCurOpt = pOpts->origArgVect[ pOpts->curOptIdx++ ]; + pOptState->pzOptArg = pOpts->pzCurOpt; + break; - case TOPT_LONG: - /* - * See if an arg string has already been assigned (glued on - * with an `=' character) - */ - if (pOptState->pzOptArg == NULL) - pOptState->pzOptArg = pOpts->origArgVect[ pOpts->curOptIdx++ ]; - break; + case TOPT_LONG: + /* + * See if an arg string has already been assigned (glued on + * with an `=' character) + */ + if (pOptState->pzOptArg == NULL) + pOptState->pzOptArg = pOpts->origArgVect[ pOpts->curOptIdx++ ]; + break; - default: + default: #ifdef DEBUG - fputs( "AutoOpts lib error: option type not selected\n", - stderr ); - exit( EXIT_FAILURE ); + fputs( "AutoOpts lib error: option type not selected\n", + stderr ); + exit( EXIT_FAILURE ); #endif - case TOPT_DEFAULT: - /* - * The option was selected by default. The current token is - * the option argument. - */ - break; - } - + case TOPT_DEFAULT: /* - * Make sure we did not overflow the argument list. + * The option was selected by default. The current token is + * the option argument. */ - if (pOpts->curOptIdx > pOpts->origArgCt) { - fprintf( stderr, zMisArg, pOpts->pzProgPath, - pOptState->pOD->pz_Name ); - return FAILURE; - } - - pOpts->pzCurOpt = NULL; /* next time advance to next arg */ break; + } - case ARG_MAY: - /* - * An option argument is optional. - */ - switch (pOptState->optType) { - case TOPT_SHORT: - if (*++pOpts->pzCurOpt != NUL) - pOptState->pzOptArg = pOpts->pzCurOpt; - else { - char* pzLA = pOpts->origArgVect[ pOpts->curOptIdx ]; + /* + * Make sure we did not overflow the argument list. + */ + if (pOpts->curOptIdx > pOpts->origArgCt) { + fprintf( stderr, zMisArg, pOpts->pzProgPath, + pOptState->pOD->pz_Name ); + return FAILURE; + } - /* - * BECAUSE it is optional, we must make sure - * we did not find another flag and that there - * is such an argument. - */ - if ((pzLA == NULL) || (*pzLA == '-')) - pOptState->pzOptArg = NULL; - else { - pOpts->curOptIdx++; /* argument found */ - pOptState->pzOptArg = pzLA; - } - } - break; + pOpts->pzCurOpt = NULL; /* next time advance to next arg */ + return SUCCESS; +} + + +static tSuccess +next_opt_arg_may(tOptions* pOpts, tOptState* pOptState) +{ + /* + * An option argument is optional. + */ + switch (pOptState->optType) { + case TOPT_SHORT: + if (*++pOpts->pzCurOpt != NUL) + pOptState->pzOptArg = pOpts->pzCurOpt; + else { + char* pzLA = pOpts->origArgVect[ pOpts->curOptIdx ]; - case TOPT_LONG: /* - * Look for an argument if we don't already have one (glued on - * with a `=' character) *AND* we are not in named argument mode + * BECAUSE it is optional, we must make sure + * we did not find another flag and that there + * is such an argument. */ - if ( (pOptState->pzOptArg == NULL) - && (! NAMED_OPTS(pOpts))) { - char* pzLA = pOpts->origArgVect[ pOpts->curOptIdx ]; - - /* - * BECAUSE it is optional, we must make sure - * we did not find another flag and that there - * is such an argument. - */ - if ((pzLA == NULL) || (*pzLA == '-')) - pOptState->pzOptArg = NULL; - else { - pOpts->curOptIdx++; /* argument found */ - pOptState->pzOptArg = pzLA; - } + if ((pzLA == NULL) || (*pzLA == '-')) + pOptState->pzOptArg = NULL; + else { + pOpts->curOptIdx++; /* argument found */ + pOptState->pzOptArg = pzLA; } - break; - - default: - case TOPT_DEFAULT: - fputs( "AutoOpts lib error: defaulted to option with optional arg\n", - stderr ); - exit( EX_SOFTWARE ); } - - /* - * After an option with an optional argument, we will - * *always* start with the next option because if there - * were any characters following the option name/flag, - * they would be interpreted as the argument. - */ - pOpts->pzCurOpt = NULL; break; - default: /* CANNOT */ + case TOPT_LONG: /* - * No option argument. Make sure next time around we find - * the correct option flag character for short options + * Look for an argument if we don't already have one (glued on + * with a `=' character) *AND* we are not in named argument mode */ - if (pOptState->optType == TOPT_SHORT) - (pOpts->pzCurOpt)++; + if ( (pOptState->pzOptArg == NULL) + && (! NAMED_OPTS(pOpts))) { + char* pzLA = pOpts->origArgVect[ pOpts->curOptIdx ]; - /* - * It is a long option. Make sure there was no ``=xxx'' argument - */ - else if (pOptState->pzOptArg != NULL) { - fprintf( stderr, zNoArg, pOpts->pzProgPath, - pOptState->pOD->pz_Name ); - return FAILURE; + /* + * BECAUSE it is optional, we must make sure + * we did not find another flag and that there + * is such an argument. + */ + if ((pzLA == NULL) || (*pzLA == '-')) + pOptState->pzOptArg = NULL; + else { + pOpts->curOptIdx++; /* argument found */ + pOptState->pzOptArg = pzLA; + } } + break; - /* - * It is a long option. Advance to next command line argument. - */ - else - pOpts->pzCurOpt = NULL; + default: + case TOPT_DEFAULT: + fputs(zAO_Woops, stderr ); + exit( EX_SOFTWARE ); + } + + /* + * After an option with an optional argument, we will + * *always* start with the next option because if there + * were any characters following the option name/flag, + * they would be interpreted as the argument. + */ + pOpts->pzCurOpt = NULL; + return SUCCESS; +} + + +static tSuccess +next_opt_arg_none(tOptions* pOpts, tOptState* pOptState) +{ + /* + * No option argument. Make sure next time around we find + * the correct option flag character for short options + */ + if (pOptState->optType == TOPT_SHORT) + (pOpts->pzCurOpt)++; + + /* + * It is a long option. Make sure there was no ``=xxx'' argument + */ + else if (pOptState->pzOptArg != NULL) { + fprintf(stderr, zNoArg, pOpts->pzProgPath, pOptState->pOD->pz_Name); + return FAILURE; } + /* + * It is a long option. Advance to next command line argument. + */ + else + pOpts->pzCurOpt = NULL; return SUCCESS; } +/* + * nextOption + * + * Find the option descriptor and option argument (if any) for the + * next command line argument. DO NOT modify the descriptor. Put + * all the state in the state argument so that the option can be skipped + * without consequence (side effect). + */ +static tSuccess +nextOption(tOptions* pOpts, tOptState* pOptState) +{ + { + tSuccess res; + res = findOptDesc( pOpts, pOptState ); + if (! SUCCESSFUL( res )) + return res; + } + + if ( ((pOptState->flags & OPTST_DEFINED) != 0) + && ((pOptState->pOD->fOptState & OPTST_NO_COMMAND) != 0)) { + fprintf(stderr, zNotCmdOpt, pOptState->pOD->pz_Name); + return FAILURE; + } + + pOptState->flags |= (pOptState->pOD->fOptState & OPTST_PERSISTENT_MASK); + + /* + * Figure out what to do about option arguments. An argument may be + * required, not associated with the option, or be optional. We detect the + * latter by examining for an option marker on the next possible argument. + * Disabled mode option selection also disables option arguments. + */ + { + enum { ARG_NONE, ARG_MAY, ARG_MUST } arg_type = ARG_NONE; + tSuccess res; + + if ((pOptState->flags & OPTST_DISABLED) != 0) + arg_type = ARG_NONE; + + else if (OPTST_GET_ARGTYPE(pOptState->flags) == OPARG_TYPE_NONE) + arg_type = ARG_NONE; + + else if (pOptState->flags & OPTST_ARG_OPTIONAL) + arg_type = ARG_MAY; + + else + arg_type = ARG_MUST; + + switch (arg_type) { + case ARG_MUST: res = next_opt_arg_must(pOpts, pOptState); break; + case ARG_MAY: res = next_opt_arg_may( pOpts, pOptState); break; + case ARG_NONE: res = next_opt_arg_none(pOpts, pOptState); break; + } + + return res; + } +} + /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * @@ -837,7 +882,8 @@ * has a --load-opts option. See if a command line option has disabled * option presetting. */ - if (pOpts->specOptIdx.save_opts != 0) { + if ( (pOpts->specOptIdx.save_opts != NO_EQUIVALENT) + && (pOpts->specOptIdx.save_opts != 0)) { pOD = pOpts->pOptDesc + pOpts->specOptIdx.save_opts + 1; if (DISABLED_OPT(pOD)) return SUCCESS; @@ -1064,6 +1110,20 @@ if (! SUCCESSFUL( doPresets( pOpts ))) return 0; + /* + * IF option name conversion was suppressed but it is not suppressed + * for the command line, then it's time to translate option names. + * Usage text will not get retranslated. + */ + if ( ((pOpts->fOptSet & OPTPROC_TRANSLATE) != 0) + && (pOpts->pTransProc != NULL) + && ((pOpts->fOptSet & OPTPROC_NO_XLAT_MASK) + == OPTPROC_NXLAT_OPT_CFG) ) { + + pOpts->fOptSet &= ~OPTPROC_NXLAT_OPT_CFG; + (*pOpts->pTransProc)(); + } + if ((pOpts->fOptSet & OPTPROC_REORDER) != 0) optionSort( pOpts ); @@ -1090,7 +1150,8 @@ * THEN do that now before testing for conflicts. * (conflicts are ignored in preset options) */ - if (pOpts->specOptIdx.save_opts != 0) { + if ( (pOpts->specOptIdx.save_opts != NO_EQUIVALENT) + && (pOpts->specOptIdx.save_opts != 0)) { tOptDesc* pOD = pOpts->pOptDesc + pOpts->specOptIdx.save_opts; if (SELECTED_OPT( pOD )) { diff -urN src/contrib/ntp/libopts/autoopts.h src.ntp/contrib/ntp/libopts/autoopts.h --- src/contrib/ntp/libopts/autoopts.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/autoopts.h 2009-12-09 08:36:35.000000000 +0100 @@ -1,61 +1,38 @@ /* - * Time-stamp: "2007-04-15 09:59:39 bkorb" + * Time-stamp: "2008-11-01 20:08:06 bkorb" * - * autoopts.h $Id: autoopts.h,v 4.23 2007/04/15 19:01:18 bkorb Exp $ - * Time-stamp: "2005-02-14 05:59:50 bkorb" + * autoopts.h $Id: d5e30331d37ca10ec88c592d24d8615dd6c1f0ee $ * * This file defines all the global structures and special values * used in the automated option processing library. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ #ifndef AUTOGEN_AUTOOPTS_H #define AUTOGEN_AUTOOPTS_H #include "compat/compat.h" +#include "ag-char-map.h" #define AO_NAME_LIMIT 127 #define AO_NAME_SIZE ((size_t)(AO_NAME_LIMIT + 1)) @@ -110,8 +87,6 @@ #define PROCESSING(d) ((d)>0) #define PRESETTING(d) ((d)<0) -#define ISNAMECHAR( c ) (isalnum(c) || ((c) == '_') || ((c) == '-')) - /* * Procedure success codes * @@ -222,6 +197,7 @@ tCC* pzStr; tCC* pzReq; tCC* pzNum; + tCC* pzFile; tCC* pzKey; tCC* pzKeyL; tCC* pzBool; @@ -232,11 +208,12 @@ tCC* pzNoF; tCC* pzSpc; tCC* pzOptFmt; + tCC* pzTime; } arg_types_t; #define AGALOC( c, w ) ao_malloc((size_t)c) #define AGREALOC( p, c, w ) ao_realloc((void*)p, (size_t)c) -#define AGFREE( p ) ao_free((void*)p) +#define AGFREE(_p) do{void*X=(void*)_p;ao_free(X);}while(0) #define AGDUPSTR( p, s, w ) (p = ao_strdup(s)) static void * diff -urN src/contrib/ntp/libopts/boolean.c src.ntp/contrib/ntp/libopts/boolean.c --- src/contrib/ntp/libopts/boolean.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/boolean.c 2009-12-09 08:36:37.000000000 +0100 @@ -1,55 +1,32 @@ /* - * $Id: boolean.c,v 4.10 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-13 10:10:39 bkorb" + * $Id: 329b43154b88d78564d8f960a00a83ec7d8baee0 $ + * Time-stamp: "2008-08-03 13:06:02 bkorb" * * Automated Options Paged Usage module. * * This routine will run run-on options through a pager so the * user may examine, print or edit them at their leisure. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ /*=export_func optionBooleanVal @@ -70,6 +47,14 @@ char* pz; ag_bool res = AG_TRUE; + if ((pOD->fOptState & OPTST_RESET) != 0) + return; + + if (pOD->optArg.argString == NULL) { + pOD->optArg.argBool = AG_FALSE; + return; + } + switch (*(pOD->optArg.argString)) { case '0': { diff -urN src/contrib/ntp/libopts/compat/compat.h src.ntp/contrib/ntp/libopts/compat/compat.h --- src/contrib/ntp/libopts/compat/compat.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/compat/compat.h 2009-12-09 08:36:37.000000000 +0100 @@ -1,13 +1,51 @@ /* -*- Mode: C -*- */ -/* --- fake the preprocessor into handlng portability */ -/* - * Time-stamp: "2007-02-03 17:41:06 bkorb" +/* compat.h --- fake the preprocessor into handlng portability + * + * Time-stamp: "2009-10-18 11:14:14 bkorb" + * + * $Id: 27c1eb45f171295ab6176280aeca742cfdbe9fed $ + * + * compat.h is free software. + * This file is part of AutoGen. + * + * AutoGen copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoGen is free software: you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * AutoGen is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the GNU General Public License for more details. * - * Author: Gary V Vaughan - * Created: Mon Jun 30 15:54:46 1997 + * You should have received a copy of the GNU General Public License along + * with this program. If not, see . * - * $Id: compat.h,v 4.16 2007/04/27 01:10:47 bkorb Exp $ + * As a special exception, Bruce Korb gives permission for additional + * uses of the text contained in the release of compat.h. + * + * The exception is that, if you link the compat.h library with other + * files to produce an executable, this does not by itself cause the + * resulting executable to be covered by the GNU General Public License. + * Your use of that executable is in no way restricted on account of + * linking the compat.h library code into it. + * + * This exception does not however invalidate any other reasons why + * the executable file might be covered by the GNU General Public License. + * + * This exception applies only to the code released by Bruce Korb under + * the name compat.h. If you copy code from other sources under the + * General Public License into a copy of compat.h, as the General Public + * License permits, the exception does not apply to the code that you add + * in this way. To avoid misleading anyone as to the status of such + * modified files, you must delete this exception notice from them. + * + * If you write modifications of your own for compat.h, it is your choice + * whether to permit this exception to apply to your modifications. + * If you do not wish that, delete this exception notice. */ #ifndef COMPAT_H_GUARD #define COMPAT_H_GUARD 1 @@ -221,57 +259,89 @@ #endif #ifndef SHORT_MAX -# define SHORT_MAX ~(1 << (8*sizeof(short) -1)) +# define SHORT_MAX ~(1 << (8*sizeof(short) - 1)) #else # define USHORT_MAX ~(OUS) #endif #ifndef HAVE_INT8_T - typedef signed char int8_t; + typedef signed char int8_t; +# define HAVE_INT8_T 1 #endif #ifndef HAVE_UINT8_T - typedef unsigned char uint8_t; + typedef unsigned char uint8_t; +# define HAVE_UINT8_T 1 #endif #ifndef HAVE_INT16_T - typedef signed short int16_t; + typedef signed short int16_t; +# define HAVE_INT16_T 1 #endif #ifndef HAVE_UINT16_T - typedef unsigned short uint16_t; -#endif -#ifndef HAVE_UINT_T - typedef unsigned int uint_t; + typedef unsigned short uint16_t; +# define HAVE_UINT16_T 1 #endif #ifndef HAVE_INT32_T -# if SIZEOF_INT == 4 - typedef signed int int32_t; -# elif SIZEOF_LONG == 4 - typedef signed long int32_t; +# if SIZEOF_INT == 4 + typedef signed int int32_t; +# elif SIZEOF_LONG == 4 + typedef signed long int32_t; # endif +# define HAVE_INT32_T 1 #endif #ifndef HAVE_UINT32_T -# if SIZEOF_INT == 4 - typedef unsigned int uint32_t; -# elif SIZEOF_LONG == 4 - typedef unsigned long uint32_t; +# if SIZEOF_INT == 4 + typedef unsigned int uint32_t; +# elif SIZEOF_LONG == 4 + typedef unsigned long uint32_t; # else # error Cannot create a uint32_t type. Choke Me. # endif +# define HAVE_UINT32_T 1 #endif #ifndef HAVE_INTPTR_T - typedef signed long intptr_t; +# if SIZEOF_CHARP == SIZEOF_LONG + typedef signed long intptr_t; +# else + typedef signed int intptr_t; +# endif +# define HAVE_INTPTR_T 1 #endif + #ifndef HAVE_UINTPTR_T - typedef unsigned long uintptr_t; +# if SIZEOF_CHARP == SIZEOF_LONG + typedef unsigned long intptr_t; +# else + typedef unsigned int intptr_t; +# endif +# define HAVE_INTPTR_T 1 +#endif + +#ifndef HAVE_UINT_T + typedef unsigned int uint_t; +# define HAVE_UINT_T 1 +#endif + +#ifndef HAVE_SIZE_T + typedef unsigned int size_t; +# define HAVE_SIZE_T 1 +#endif +#ifndef HAVE_WINT_T + typedef unsigned int wint_t; +# define HAVE_WINT_T 1 +#endif +#ifndef HAVE_PID_T + typedef signed int pid_t; +# define HAVE_PID_T 1 #endif /* redefine these for BSD style string libraries */ #ifndef HAVE_STRCHR -# define strchr index -# define strrchr rindex +# define strchr index +# define strrchr rindex #endif #ifdef USE_FOPEN_BINARY diff -urN src/contrib/ntp/libopts/compat/pathfind.c src.ntp/contrib/ntp/libopts/compat/pathfind.c --- src/contrib/ntp/libopts/compat/pathfind.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/compat/pathfind.c 2009-12-09 08:36:37.000000000 +0100 @@ -5,11 +5,9 @@ /* * Author: Gary V Vaughan * Time-stamp: "2006-09-23 19:46:16 bkorb" - * Created: Tue Jun 24 15:07:31 1997 - * Last Modified: $Date: 2006/11/27 01:52:23 $ * by: bkorb * - * $Id: pathfind.c,v 4.10 2006/11/27 01:52:23 bkorb Exp $ + * $Id: 8ce7ddfe2378f0b75c91c0ab348a6ad81634fb01 $ */ /* Code: */ diff -urN src/contrib/ntp/libopts/compat/windows-config.h src.ntp/contrib/ntp/libopts/compat/windows-config.h --- src/contrib/ntp/libopts/compat/windows-config.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/compat/windows-config.h 2009-12-09 08:36:35.000000000 +0100 @@ -1,8 +1,24 @@ /* - * Time-stamp: "2006-10-14 14:55:09 bkorb" + * Time-stamp: "2009-07-22 18:53:59 bkorb" * by: bkorb - * Last Committed: $Date: 2007/04/28 22:19:23 $ + * + * This file is part of AutoGen. + * + * AutoGen copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoGen is free software: you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * AutoGen is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along + * with this program. If not, see . */ #ifndef WINDOWS_CONFIG_HACKERY #define WINDOWS_CONFIG_HACKERY 1 diff -urN src/contrib/ntp/libopts/configfile.c src.ntp/contrib/ntp/libopts/configfile.c --- src/contrib/ntp/libopts/configfile.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/configfile.c 2009-12-09 08:36:35.000000000 +0100 @@ -1,55 +1,32 @@ /* - * $Id: configfile.c,v 1.21 2007/04/15 19:01:18 bkorb Exp $ - * Time-stamp: "2007-04-15 11:22:46 bkorb" + * $Id: f1650b45a91ec95af830ff76041cc4f0048e60f0 $ + * Time-stamp: "2009-01-18 10:21:58 bkorb" * * configuration/rc/ini file handling. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static void filePreset( tOptions* pOpts, @@ -90,11 +67,6 @@ tOptionValue* pType ); static char* -parseLoadMode( - char* pzText, - tOptionLoadMode* pMode ); - -static char* parseSetMemType( tOptions* pOpts, char* pzText, @@ -444,7 +416,7 @@ int direction ) { tmap_info_t cfgfile; - tOptState st = OPTSTATE_INITIALIZER(PRESET); + tOptState optst = OPTSTATE_INITIALIZER(PRESET); char* pzFileText = text_mmap( pzFileName, PROT_READ|PROT_WRITE, MAP_PRIVATE, &cfgfile ); @@ -452,8 +424,8 @@ return; if (direction == DIRECTION_CALLED) { - st.flags = OPTST_DEFINED; - direction = DIRECTION_PROCESS; + optst.flags = OPTST_DEFINED; + direction = DIRECTION_PROCESS; } /* @@ -463,18 +435,19 @@ * and we consider stuff set herein to be "set" by the client program. */ if ((pOpts->fOptSet & OPTPROC_PRESETTING) == 0) - st.flags = OPTST_SET; + optst.flags = OPTST_SET; do { - while (isspace( (int)*pzFileText )) pzFileText++; + while (IS_WHITESPACE_CHAR(*pzFileText)) pzFileText++; - if (isalpha( (int)*pzFileText )) { - pzFileText = handleConfig( pOpts, &st, pzFileText, direction ); + if (IS_VAR_FIRST_CHAR(*pzFileText)) { + pzFileText = handleConfig(pOpts, &optst, pzFileText, direction); } else switch (*pzFileText) { case '<': - if (isalpha( (int)pzFileText[1] )) - pzFileText = handleStructure(pOpts, &st, pzFileText, direction); + if (IS_VAR_FIRST_CHAR(pzFileText[1])) + pzFileText = + handleStructure(pOpts, &optst, pzFileText, direction); else switch (pzFileText[1]) { case '?': @@ -549,8 +522,8 @@ if (pzEnd == NULL) return pzText + strlen(pzText); - while (ISNAMECHAR( (int)*pzText )) pzText++; - while (isspace( (int)*pzText )) pzText++; + while (IS_VALUE_NAME_CHAR(*pzText)) pzText++; + while (IS_WHITESPACE_CHAR(*pzText)) pzText++; if (pzText > pzEnd) { name_only: *pzEnd++ = NUL; @@ -564,10 +537,10 @@ * is an invalid format and we give up parsing the text. */ if ((*pzText == '=') || (*pzText == ':')) { - while (isspace( (int)*++pzText )) ; + while (IS_WHITESPACE_CHAR(*++pzText)) ; if (pzText > pzEnd) goto name_only; - } else if (! isspace((int)pzText[-1])) + } else if (! IS_WHITESPACE_CHAR(pzText[-1])) return NULL; /* @@ -631,7 +604,7 @@ size_t name_len; if ( (strncmp( pzText+2, zProg, title_len ) != 0) - || (! isspace( (int)pzText[title_len+2] )) ) { + || (! IS_WHITESPACE_CHAR(pzText[title_len+2])) ) { pzText = strchr( pzText+2, '>' ); if (pzText != NULL) pzText++; @@ -645,8 +618,8 @@ do { pzText += title_len; - if (isspace((int)*pzText)) { - while (isspace((int)*pzText)) pzText++; + if (IS_WHITESPACE_CHAR(*pzText)) { + while (IS_WHITESPACE_CHAR(*++pzText)) ; if ( (strneqvcmp( pzText, pOpts->pzProgName, (int)name_len) == 0) && (pzText[name_len] == '>')) { pzText += name_len + 1; @@ -706,13 +679,13 @@ int direction ) { tOptionLoadMode mode = option_load_mode; - tOptionValue valu; + tOptionValue valu; char* pzName = ++pzText; char* pzData; char* pcNulPoint; - while (ISNAMECHAR( *pzText )) pzText++; + while (IS_VALUE_NAME_CHAR(*pzText)) pzText++; pcNulPoint = pzText; valu.valType = OPARG_TYPE_STRING; @@ -780,6 +753,36 @@ memset(pcNulPoint, ' ', pzData - pcNulPoint); /* + * If we are getting a "string" value, the process the XML-ish + * %XX hex characters. + */ + if (valu.valType == OPARG_TYPE_STRING) { + char * pzSrc = pzData; + char * pzDst = pzData; + char bf[4]; + bf[2] = NUL; + + for (;;) { + int ch = ((int)*(pzSrc++)) & 0xFF; + switch (ch) { + case NUL: goto string_fixup_done; + + case '%': + bf[0] = *(pzSrc++); + bf[1] = *(pzSrc++); + if ((bf[0] == NUL) || (bf[1] == NUL)) + goto string_fixup_done; + ch = strtoul(bf, NULL, 16); + /* FALLTHROUGH */ + + default: + *(pzDst++) = ch; + } + } string_fixup_done:; + *pzDst = NUL; + } + + /* * "pzName" points to what looks like text for one option/configurable. * It is NUL terminated. Process it. */ @@ -798,13 +801,22 @@ LOCAL void internalFileLoad( tOptions* pOpts ) { - int idx; - int inc = DIRECTION_PRESET; - char zFileName[ AG_PATH_MAX+1 ]; + uint32_t svfl; + int idx; + int inc; + char zFileName[ AG_PATH_MAX+1 ]; if (pOpts->papzHomeList == NULL) return; + svfl = pOpts->fOptSet; + inc = DIRECTION_PRESET; + + /* + * Never stop on errors in config files. + */ + pOpts->fOptSet &= ~OPTPROC_ERRSTOP; + /* * Find the last RC entry (highest priority entry) */ @@ -877,6 +889,8 @@ } } } /* twice for every path in the home list, ... */ + + pOpts->fOptSet = svfl; } @@ -939,35 +953,38 @@ void optionLoadOpt( tOptions* pOpts, tOptDesc* pOptDesc ) { + struct stat sb; + /* * IF the option is not being disabled, THEN load the file. There must * be a file. (If it is being disabled, then the disablement processing * already took place. It must be done to suppress preloading of ini/rc * files.) */ - if (! DISABLED_OPT( pOptDesc )) { - struct stat sb; - if (stat( pOptDesc->optArg.argString, &sb ) != 0) { - if ((pOpts->fOptSet & OPTPROC_ERRSTOP) == 0) - return; - - fprintf( stderr, zFSErrOptLoad, errno, strerror( errno ), - pOptDesc->optArg.argString ); - exit(EX_NOINPUT); - /* NOT REACHED */ - } + if ( DISABLED_OPT(pOptDesc) + || ((pOptDesc->fOptState & OPTST_RESET) != 0)) + return; - if (! S_ISREG( sb.st_mode )) { - if ((pOpts->fOptSet & OPTPROC_ERRSTOP) == 0) - return; - - fprintf( stderr, zNotFile, pOptDesc->optArg.argString ); - exit(EX_NOINPUT); - /* NOT REACHED */ - } + if (stat( pOptDesc->optArg.argString, &sb ) != 0) { + if ((pOpts->fOptSet & OPTPROC_ERRSTOP) == 0) + return; + + fprintf( stderr, zFSErrOptLoad, errno, strerror( errno ), + pOptDesc->optArg.argString ); + exit(EX_NOINPUT); + /* NOT REACHED */ + } - filePreset(pOpts, pOptDesc->optArg.argString, DIRECTION_CALLED); + if (! S_ISREG( sb.st_mode )) { + if ((pOpts->fOptSet & OPTPROC_ERRSTOP) == 0) + return; + + fprintf( stderr, zNotFile, pOptDesc->optArg.argString ); + exit(EX_NOINPUT); + /* NOT REACHED */ } + + filePreset(pOpts, pOptDesc->optArg.argString, DIRECTION_CALLED); } @@ -982,45 +999,65 @@ tOptionLoadMode* pMode, tOptionValue* pType ) { - size_t lenLoadType = strlen( zLoadType ); - size_t lenKeyWords = strlen( zKeyWords ); - size_t lenSetMem = strlen( zSetMembers ); + size_t len; do { - switch (*pzText) { - case '/': pType->valType = OPARG_TYPE_NONE; - case '>': return pzText; + if (! IS_WHITESPACE_CHAR(*pzText)) + switch (*pzText) { + case '/': pType->valType = OPARG_TYPE_NONE; + case '>': return pzText; - default: - case NUL: return NULL; + default: + case NUL: return NULL; + } - case ' ': - case '\t': - case '\n': - case '\f': - case '\r': - case '\v': + while (IS_WHITESPACE_CHAR(*++pzText)) ; + len = 0; + while (IS_LOWER_CASE_CHAR(pzText[len])) len++; + + switch (find_xat_attribute_id(pzText, len)) { + case XAT_KWD_TYPE: + pzText = parseValueType( pzText+len, pType ); break; - } - while (isspace( (int)*++pzText )) ; + case XAT_KWD_WORDS: + pzText = parseKeyWordType( pOpts, pzText+len, pType ); + break; - if (strncmp( pzText, zLoadType, lenLoadType ) == 0) { - pzText = parseValueType( pzText+lenLoadType, pType ); - continue; - } + case XAT_KWD_MEMBERS: + pzText = parseSetMemType( pOpts, pzText+len, pType ); + break; - if (strncmp( pzText, zKeyWords, lenKeyWords ) == 0) { - pzText = parseKeyWordType( pOpts, pzText+lenKeyWords, pType ); - continue; - } + case XAT_KWD_COOKED: + pzText += len; + if (! IS_END_XML_TOKEN_CHAR(*pzText)) + goto invalid_kwd; - if (strncmp( pzText, zSetMembers, lenSetMem ) == 0) { - pzText = parseSetMemType( pOpts, pzText+lenSetMem, pType ); - continue; - } + *pMode = OPTION_LOAD_COOKED; + break; + + case XAT_KWD_UNCOOKED: + pzText += len; + if (! IS_END_XML_TOKEN_CHAR(*pzText)) + goto invalid_kwd; + + *pMode = OPTION_LOAD_UNCOOKED; + break; + + case XAT_KWD_KEEP: + pzText += len; + if (! IS_END_XML_TOKEN_CHAR(*pzText)) + goto invalid_kwd; - pzText = parseLoadMode( pzText, pMode ); + *pMode = OPTION_LOAD_KEEP; + break; + + default: + case XAT_KWD_INVALID: + invalid_kwd: + pType->valType = OPARG_TYPE_NONE; + return skipUnknown( pzText ); + } } while (pzText != NULL); return pzText; @@ -1042,61 +1079,6 @@ } -/* parseLoadMode - * - * "pzText" points to some name character. We check for "cooked" or - * "uncooked" or "keep". This function should handle any attribute - * that does not have an associated value. - */ -static char* -parseLoadMode( - char* pzText, - tOptionLoadMode* pMode ) -{ - { - size_t len = strlen(zLoadCooked); - if (strncmp( pzText, zLoadCooked, len ) == 0) { - if ( (pzText[len] == '>') - || (pzText[len] == '/') - || isspace((int)pzText[len])) { - *pMode = OPTION_LOAD_COOKED; - return pzText + len; - } - goto unknown; - } - } - - { - size_t len = strlen(zLoadUncooked); - if (strncmp( pzText, zLoadUncooked, len ) == 0) { - if ( (pzText[len] == '>') - || (pzText[len] == '/') - || isspace((int)pzText[len])) { - *pMode = OPTION_LOAD_UNCOOKED; - return pzText + len; - } - goto unknown; - } - } - - { - size_t len = strlen(zLoadKeep); - if (strncmp( pzText, zLoadKeep, len ) == 0) { - if ( (pzText[len] == '>') - || (pzText[len] == '/') - || isspace((int)pzText[len])) { - *pMode = OPTION_LOAD_KEEP; - return pzText + len; - } - goto unknown; - } - } - - unknown: - return skipUnknown( pzText ); -} - - /* parseSetMemType * * "pzText" points to the character after "members=" @@ -1122,75 +1104,52 @@ char* pzText, tOptionValue* pType ) { - { - size_t len = strlen(zLtypeString); - if (strncmp( pzText, zLtypeString, len ) == 0) { - if ((pzText[len] == '>') || isspace((int)pzText[len])) { - pType->valType = OPARG_TYPE_STRING; - return pzText + len; - } - goto unknown; - } - } + size_t len = 0; - { - size_t len = strlen(zLtypeInteger); - if (strncmp( pzText, zLtypeInteger, len ) == 0) { - if ((pzText[len] == '>') || isspace((int)pzText[len])) { - pType->valType = OPARG_TYPE_NUMERIC; - return pzText + len; - } - goto unknown; - } - } + if (*(pzText++) != '=') + goto woops; - { - size_t len = strlen(zLtypeBool); - if (strncmp( pzText, zLtypeBool, len ) == 0) { - if ((pzText[len] == '>') || isspace(pzText[len])) { - pType->valType = OPARG_TYPE_BOOLEAN; - return pzText + len; - } - goto unknown; - } - } + while (IS_OPTION_NAME_CHAR(pzText[len])) len++; + pzText += len; - { - size_t len = strlen(zLtypeKeyword); - if (strncmp( pzText, zLtypeKeyword, len ) == 0) { - if ((pzText[len] == '>') || isspace((int)pzText[len])) { - pType->valType = OPARG_TYPE_ENUMERATION; - return pzText + len; - } - goto unknown; - } + if ((len == 0) || (! IS_END_XML_TOKEN_CHAR(*pzText))) { + woops: + pType->valType = OPARG_TYPE_NONE; + return skipUnknown( pzText ); } - { - size_t len = strlen(zLtypeSetMembership); - if (strncmp( pzText, zLtypeSetMembership, len ) == 0) { - if ((pzText[len] == '>') || isspace((int)pzText[len])) { - pType->valType = OPARG_TYPE_MEMBERSHIP; - return pzText + len; - } - goto unknown; - } - } + switch (find_value_type_id(pzText - len, len)) { + default: + case VTP_KWD_INVALID: goto woops; - { - size_t len = strlen(zLtypeNest); - if (strncmp( pzText, zLtypeNest, len ) == 0) { - if ((pzText[len] == '>') || isspace((int)pzText[len])) { - pType->valType = OPARG_TYPE_HIERARCHY; - return pzText + len; - } - goto unknown; - } + case VTP_KWD_STRING: + pType->valType = OPARG_TYPE_STRING; + break; + + case VTP_KWD_INTEGER: + pType->valType = OPARG_TYPE_NUMERIC; + break; + + case VTP_KWD_BOOL: + case VTP_KWD_BOOLEAN: + pType->valType = OPARG_TYPE_BOOLEAN; + break; + + case VTP_KWD_KEYWORD: + pType->valType = OPARG_TYPE_ENUMERATION; + break; + + case VTP_KWD_SET: + case VTP_KWD_SET_MEMBERSHIP: + pType->valType = OPARG_TYPE_MEMBERSHIP; + break; + + case VTP_KWD_NESTED: + case VTP_KWD_HIERARCHY: + pType->valType = OPARG_TYPE_HIERARCHY; } - unknown: - pType->valType = OPARG_TYPE_NONE; - return skipUnknown( pzText ); + return pzText; } @@ -1202,12 +1161,8 @@ skipUnknown( char* pzText ) { for (;; pzText++) { - if (isspace( (int)*pzText )) return pzText; - switch (*pzText) { - case NUL: return NULL; - case '/': - case '>': return pzText; - } + if (IS_END_XML_TOKEN_CHAR(*pzText)) return pzText; + if (*pzText == NUL) return NULL; } } @@ -1233,7 +1188,14 @@ * is available, then go do it. */ if ( ((pOpts->fOptSet & OPTPROC_TRANSLATE) != 0) - && (pOpts->pTransProc != 0) ) { + && (pOpts->pTransProc != NULL) ) { + /* + * If option names are not to be translated at all, then do not do + * it for configuration parsing either. (That is the bit that really + * gets tested anyway.) + */ + if ((pOpts->fOptSet & OPTPROC_NO_XLAT_MASK) == OPTPROC_NXLAT_OPT) + pOpts->fOptSet |= OPTPROC_NXLAT_OPT_CFG; (*pOpts->pTransProc)(); pOpts->fOptSet &= ~OPTPROC_TRANSLATE; } @@ -1248,8 +1210,7 @@ || (pOpts->structVersion < OPTIONS_MINIMUM_VERSION ) ) ) { - fprintf( stderr, zAO_Err, pOpts->origArgVect[0], - NUM_TO_VER( pOpts->structVersion )); + fprintf(stderr, zAO_Err, pzProgram, NUM_TO_VER(pOpts->structVersion)); if (pOpts->structVersion > OPTIONS_STRUCT_VERSION ) fputs( zAO_Big, stderr ); else diff -urN src/contrib/ntp/libopts/cook.c src.ntp/contrib/ntp/libopts/cook.c --- src/contrib/ntp/libopts/cook.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/cook.c 2009-12-09 08:36:35.000000000 +0100 @@ -1,57 +1,33 @@ - /* - * $Id: cook.c,v 4.10 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2006-09-24 15:21:02 bkorb" + * $Id: 3da9a5fc88c904673b3b95d0c9667b2bcbccfc80 $ + * Time-stamp: "2007-11-16 22:49:11 bkorb" * * This file contains the routines that deal with processing quoted strings * into an internal format. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ /* = = = END-STATIC-FORWARD = = = */ /*=export_func ao_string_cook_escape_char @@ -105,79 +81,42 @@ case 't': *pRes = '\t'; break; case 'v': *pRes = '\v'; break; - case 'x': /* HEX Escape */ - if (isxdigit( (int)*pzIn )) { - unsigned int val; - unsigned char ch = *pzIn++; - - if ((ch >= 'A') && (ch <= 'F')) - val = 10 + (ch - 'A'); - else if ((ch >= 'a') && (ch <= 'f')) - val = 10 + (ch - 'a'); - else val = ch - '0'; - - ch = *pzIn; - - if (! isxdigit( ch )) { - *pRes = val; - res = 2; - break; - } - val <<= 4; - if ((ch >= 'A') && (ch <= 'F')) - val += 10 + (ch - 'A'); - else if ((ch >= 'a') && (ch <= 'f')) - val += 10 + (ch - 'a'); - else val += ch - '0'; - - res = 3; - *pRes = val; + case 'x': + case 'X': /* HEX Escape */ + if (IS_HEX_DIGIT_CHAR(*pzIn)) { + char z[4], *pz = z; + + do *(pz++) = *(pzIn++); + while (IS_HEX_DIGIT_CHAR(*pzIn) && (pz < z + 2)); + *pz = NUL; + *pRes = (unsigned char)strtoul(z, NULL, 16); + res += pz - z; } break; - default: + case '0': case '1': case '2': case '3': + case '4': case '5': case '6': case '7': + { /* * IF the character copied was an octal digit, * THEN set the output character to an octal value */ - if (isdigit( (int)*pRes ) && (*pRes < '8')) { - unsigned int val = *pRes - '0'; - unsigned char ch = *pzIn++; - - /* - * IF the second character is *not* an octal digit, - * THEN save the value and bail - */ - if ((ch < '0') || (ch > '7')) { - *pRes = val; - break; - } - - val = (val<<3) + (ch - '0'); - ch = *pzIn; - res = 2; - - /* - * IF the THIRD character is *not* an octal digit, - * THEN save the value and bail - */ - if ((ch < '0') || (ch > '7')) { - *pRes = val; - break; - } - - /* - * IF the new value would not be too large, - * THEN add on the third and last character value - */ - if ((val<<3) < 0xFF) { - val = (val<<3) + (ch - '0'); - res = 3; - } + char z[4], *pz = z + 1; + unsigned long val; + z[0] = *pRes; + + while (IS_OCT_DIGIT_CHAR(*pzIn) && (pz < z + 3)) + *(pz++) = *(pzIn++); + *pz = NUL; + val = strtoul(z, NULL, 8); + if (val > 0xFF) + val = 0xFF; + *pRes = (unsigned char)val; + res = pz - z; + break; + } - *pRes = val; - break; - } + default: ; } return res; @@ -239,7 +178,7 @@ pzS++; scan_for_quote: - while (isspace((int)*pzS)) + while (IS_WHITESPACE_CHAR(*pzS)) if (*(pzS++) == '\n') (*pLineCt)++; diff -urN src/contrib/ntp/libopts/enumeration.c src.ntp/contrib/ntp/libopts/enumeration.c --- src/contrib/ntp/libopts/enumeration.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/enumeration.c 2009-12-09 08:36:35.000000000 +0100 @@ -1,61 +1,38 @@ /* - * $Id: enumeration.c,v 4.17 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-13 10:22:35 bkorb" + * $Id: 27595043d23170eb4bb8b9831fc54016944e00e8 $ + * Time-stamp: "2008-07-27 12:28:01 bkorb" * * Automated Options Paged Usage module. * * This routine will run run-on options through a pager so the * user may examine, print or edit them at their leisure. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ tSCC* pz_enum_err_fmt; /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static void enumError( tOptions* pOpts, @@ -81,16 +58,27 @@ { size_t max_len = 0; size_t ttl_len = 0; + int ct_down = name_ct; + int hidden = 0; - if (pOpts != NULL) - fprintf( option_usage_fp, pz_enum_err_fmt, pOpts->pzProgName, - pOD->optArg.argString, pOD->pz_Name ); + /* + * A real "pOpts" pointer means someone messed up. Give a real error. + */ + if (pOpts > OPTPROC_EMIT_LIMIT) + fprintf(option_usage_fp, pz_enum_err_fmt, pOpts->pzProgName, + pOD->optArg.argString, pOD->pz_Name); - fprintf( option_usage_fp, zValidKeys, pOD->pz_Name ); + fprintf(option_usage_fp, zValidKeys, pOD->pz_Name); + /* + * If the first name starts with this funny character, then we have + * a first value with an unspellable name. You cannot specify it. + * So, we don't list it either. + */ if (**paz_names == 0x7F) { paz_names++; - name_ct--; + hidden = 1; + ct_down = --name_ct; } /* @@ -99,14 +87,15 @@ */ { tCC * const * paz = paz_names; - int ct = name_ct; do { size_t len = strlen( *(paz++) ) + 1; if (len > max_len) max_len = len; ttl_len += len; - } while (--ct > 0); + } while (--ct_down > 0); + + ct_down = name_ct; } /* @@ -115,7 +104,7 @@ if (max_len > 35) { do { fprintf( option_usage_fp, " %s\n", *(paz_names++) ); - } while (--name_ct > 0); + } while (--ct_down > 0); } /* @@ -126,7 +115,7 @@ do { fputc( ' ', option_usage_fp ); fputs( *(paz_names++), option_usage_fp ); - } while (--name_ct > 0); + } while (--ct_down > 0); fputc( '\n', option_usage_fp ); } @@ -144,7 +133,8 @@ /* * Loop through all but the last entry */ - while (--name_ct > 0) { + ct_down = name_ct; + while (--ct_down > 0) { if (++ent_no == max_len) { /* * Last entry on a line. Start next line, too. @@ -154,19 +144,25 @@ } else - fprintf( option_usage_fp, zFmt, *(paz_names++) ); + fprintf(option_usage_fp, zFmt, *(paz_names++) ); } - fprintf( option_usage_fp, "%s\n", *paz_names ); + fprintf(option_usage_fp, "%s\n", *paz_names); } - /* - * IF we do not have a pOpts pointer, then this output is being requested - * by the usage procedure. Let's not re-invoke it recursively. - */ - if (pOpts != NULL) + if (pOpts > OPTPROC_EMIT_LIMIT) { + fprintf(option_usage_fp, zIntRange, hidden, name_ct - 1 + hidden); + (*(pOpts->pUsageProc))( pOpts, EXIT_FAILURE ); - if (OPTST_GET_ARGTYPE(pOD->fOptState) == OPARG_TYPE_MEMBERSHIP) - fputs( zSetMemberSettings, option_usage_fp ); + /* NOTREACHED */ + } + + + if (OPTST_GET_ARGTYPE(pOD->fOptState) == OPARG_TYPE_MEMBERSHIP) { + fprintf(option_usage_fp, zLowerBits, name_ct); + fputs(zSetMemberSettings, option_usage_fp); + } else { + fprintf(option_usage_fp, zIntRange, hidden, name_ct - 1 + hidden); + } } @@ -178,9 +174,23 @@ tCC* const * paz_names, unsigned int name_ct ) { + /* + * Return the matching index as a pointer sized integer. + * The result gets stashed in a char* pointer. + */ uintptr_t res = name_ct; size_t len = strlen( (char*)pzName ); uintptr_t idx; + + if (IS_DEC_DIGIT_CHAR(*pzName)) { + char * pz = (char *)(void *)pzName; + unsigned long val = strtoul(pz, &pz, 0); + if ((*pz == NUL) && (val < name_ct)) + return (uintptr_t)val; + enumError(pOpts, pOD, paz_names, (int)name_ct); + return name_ct; + } + /* * Look for an exact match, but remember any partial matches. * Multiple partial matches means we have an ambiguous match. @@ -190,29 +200,17 @@ if (paz_names[idx][len] == NUL) return idx; /* full match */ - if (res != name_ct) { - pz_enum_err_fmt = zAmbigKey; - option_usage_fp = stderr; - enumError( pOpts, pOD, paz_names, (int)name_ct ); - } - res = idx; /* save partial match */ + res = (res != name_ct) ? ~0 : idx; /* save partial match */ } } - /* - * no partial match -> error - */ - if (res == name_ct) { - pz_enum_err_fmt = zNoKey; - option_usage_fp = stderr; - enumError( pOpts, pOD, paz_names, (int)name_ct ); - } + if (res < name_ct) + return res; /* partial match */ - /* - * Return the matching index as a char* pointer. - * The result gets stashed in a char* pointer, so it will have to fit. - */ - return res; + pz_enum_err_fmt = (res == name_ct) ? zNoKey : zAmbigKey; + option_usage_fp = stderr; + enumError(pOpts, pOD, paz_names, (int)name_ct); + return name_ct; } @@ -236,7 +234,7 @@ tOptDesc od; od.optArg.argEnum = enum_val; - (*(pOD->pOptProc))( (void*)(2UL), &od ); + (*(pOD->pOptProc))(OPTPROC_RETURN_VALNAME, &od ); return od.optArg.argString; } @@ -273,14 +271,14 @@ * then it is some sort of special request. */ switch ((uintptr_t)pOpts) { - case 0UL: + case (uintptr_t)OPTPROC_EMIT_USAGE: /* * print the list of enumeration names. */ - enumError( pOpts, pOD, paz_names, (int)name_ct ); + enumError(pOpts, pOD, paz_names, (int)name_ct); break; - case 1UL: + case (uintptr_t)OPTPROC_EMIT_SHELL: { unsigned int ix = pOD->optArg.argEnum; /* @@ -294,7 +292,7 @@ break; } - case 2UL: + case (uintptr_t)OPTPROC_RETURN_VALNAME: { tSCC zInval[] = "*INVALID*"; unsigned int ix = pOD->optArg.argEnum; @@ -304,12 +302,12 @@ if (ix >= name_ct) return (uintptr_t)zInval; - res = (uintptr_t)paz_names[ ix ]; + pOD->optArg.argString = paz_names[ix]; break; } default: - res = findName( pOD->optArg.argString, pOpts, pOD, paz_names, name_ct ); + res = findName(pOD->optArg.argString, pOpts, pOD, paz_names, name_ct); if (pOD->fOptState & OPTST_ALLOC_ARG) { AGFREE(pOD->optArg.argString); @@ -350,39 +348,43 @@ * then it is some sort of special request. */ switch ((uintptr_t)pOpts) { - case 0UL: + case (uintptr_t)OPTPROC_EMIT_USAGE: /* * print the list of enumeration names. */ - enumError( pOpts, pOD, paz_names, (int)name_ct ); + enumError(OPTPROC_EMIT_USAGE, pOD, paz_names, (int)name_ct ); return; - case 1UL: + case (uintptr_t)OPTPROC_EMIT_SHELL: { /* * print the name string. */ + int ix = 0; uintptr_t bits = (uintptr_t)pOD->optCookie; - uintptr_t res = 0; size_t len = 0; + bits &= ((uintptr_t)1 << (uintptr_t)name_ct) - (uintptr_t)1; + while (bits != 0) { if (bits & 1) { if (len++ > 0) fputs( " | ", stdout ); - fputs( paz_names[ res ], stdout ); + fputs(paz_names[ix], stdout); } - if (++res >= name_ct) break; + if (++ix >= name_ct) break; bits >>= 1; } return; } - case 2UL: + case (uintptr_t)OPTPROC_RETURN_VALNAME: { char* pz; uintptr_t bits = (uintptr_t)pOD->optCookie; - uintptr_t res = 0; - size_t len = 0; + int ix = 0; + size_t len = 5; + + bits &= ((uintptr_t)1 << (uintptr_t)name_ct) - (uintptr_t)1; /* * Replace the enumeration value with the name string. @@ -390,12 +392,12 @@ */ while (bits != 0) { if (bits & 1) - len += strlen( paz_names[ res ]) + 8; - if (++res >= name_ct) break; + len += strlen( paz_names[ix]) + 8; + if (++ix >= name_ct) break; bits >>= 1; } - pOD->optArg.argString = pz = AGALOC( len, "enum name" ); + pOD->optArg.argString = pz = AGALOC(len, "enum name"); /* * Start by clearing all the bits. We want to turn off any defaults @@ -405,14 +407,16 @@ strcpy( pz, "none" ); pz += 4; bits = (uintptr_t)pOD->optCookie; - res = 0; + bits &= ((uintptr_t)1 << (uintptr_t)name_ct) - (uintptr_t)1; + ix = 0; + while (bits != 0) { if (bits & 1) { strcpy( pz, " + " ); - strcpy( pz+3, paz_names[ res ]); - pz += strlen( paz_names[ res ]) + 3; + strcpy( pz+3, paz_names[ix]); + pz += strlen( paz_names[ix]) + 3; } - if (++res >= name_ct) break; + if (++ix >= name_ct) break; bits >>= 1; } return; @@ -422,6 +426,9 @@ break; } + if ((pOD->fOptState & OPTST_RESET) != 0) + return; + { tCC* pzArg = pOD->optArg.argString; uintptr_t res; @@ -460,6 +467,8 @@ if (pz != pzArg + len) { char z[ AO_NAME_SIZE ]; tCC* p; + int shift_ct; + if (*pz != NUL) { if (len >= AO_NAME_LIMIT) break; @@ -470,7 +479,12 @@ p = pzArg; } - bit = 1UL << findName(p, pOpts, pOD, paz_names, name_ct); + shift_ct = findName(p, pOpts, pOD, paz_names, name_ct); + if (shift_ct >= name_ct) { + pOD->optCookie = (void*)0; + return; + } + bit = 1UL << shift_ct; } if (iv) res &= ~bit; diff -urN src/contrib/ntp/libopts/environment.c src.ntp/contrib/ntp/libopts/environment.c --- src/contrib/ntp/libopts/environment.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/environment.c 2009-12-09 08:36:35.000000000 +0100 @@ -1,59 +1,36 @@ /* - * $Id: environment.c,v 4.13 2007/04/15 19:01:18 bkorb Exp $ - * Time-stamp: "2007-04-15 11:50:35 bkorb" + * $Id: 8700c8e91e8094c455392c691d9b6a7d62222240 $ + * Time-stamp: "2009-07-20 20:12:24 bkorb" * * This file contains all of the routines that must be linked into * an executable to use the generated option processing. The optional * routines are in separately compiled modules so that they will not * necessarily be linked in. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. + * These files have the following md5sums: * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static void checkEnvOpt(tOptState * os, char * env_name, tOptions* pOpts, teEnvPresetType type); @@ -75,15 +52,9 @@ char** sv_argv; /* - * IF there is no such environment variable - * *or* there is, but we are doing immediate opts and there are - * no immediate opts to do (--help inside $PROGNAME is silly, - * but --no-load-defs is not, so that is marked) - * THEN bail out now. ( + * No such beast? Then bail now. */ - if ( (pczOptStr == NULL) - || ( (type == ENV_IMM) - && ((pOpts->fOptSet & OPTPROC_HAS_IMMED) == 0) ) ) + if (pczOptStr == NULL) return; /* @@ -116,27 +87,17 @@ switch (type) { case ENV_IMM: - /* - * We know the OPTPROC_HAS_IMMED bit is set. - */ (void)doImmediateOpts( pOpts ); break; - case ENV_NON_IMM: - (void)doRegularOpts( pOpts ); - break; + case ENV_ALL: + (void)doImmediateOpts( pOpts ); + pOpts->curOptIdx = 1; + pOpts->pzCurOpt = NULL; + /* FALLTHROUGH */ - default: - /* - * Only to immediate opts if the OPTPROC_HAS_IMMED bit is set. - */ - if (pOpts->fOptSet & OPTPROC_HAS_IMMED) { - (void)doImmediateOpts( pOpts ); - pOpts->curOptIdx = 1; - pOpts->pzCurOpt = NULL; - } + case ENV_NON_IMM: (void)doRegularOpts( pOpts ); - break; } /* @@ -263,7 +224,8 @@ /* * Special handling for ${PROGNAME_LOAD_OPTS} */ - if (pOpts->specOptIdx.save_opts != 0) { + if ( (pOpts->specOptIdx.save_opts != NO_EQUIVALENT) + && (pOpts->specOptIdx.save_opts != 0)) { st.pOD = pOpts->pOptDesc + pOpts->specOptIdx.save_opts + 1; strcpy( pzFlagName, st.pOD->pz_NAME ); checkEnvOpt(&st, zEnvName, pOpts, type); diff -urN src/contrib/ntp/libopts/file.c src.ntp/contrib/ntp/libopts/file.c --- src/contrib/ntp/libopts/file.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/libopts/file.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,170 @@ + +/* + * $Id: 1410aaa5f08a562e0cd6c28ffae5a49dc7a3164f $ + * Time-stamp: "2009-07-23 17:23:46 bkorb" + * + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd + */ + +/*=export_func optionFileCheck + * private: + * + * what: Decipher a boolean value + * arg: + tOptions* + pOpts + program options descriptor + + * arg: + tOptDesc* + pOptDesc + the descriptor for this arg + + * arg: + teOptFileType + ftype + File handling type + + * arg: + tuFileMode + mode + file open mode (if needed) + + * + * doc: + * Make sure the named file conforms with the file type mode. + * The mode specifies if the file must exist, must not exist or may + * (or may not) exist. The mode may also specify opening the + * file: don't, open just the descriptor (fd), or open as a stream + * (FILE* pointer). +=*/ +void +optionFileCheck(tOptions* pOpts, tOptDesc* pOD, + teOptFileType ftype, tuFileMode mode) +{ + if (pOpts <= OPTPROC_EMIT_LIMIT) { + if (pOpts != OPTPROC_EMIT_USAGE) + return; + + switch (ftype & FTYPE_MODE_EXIST_MASK) { + case FTYPE_MODE_MUST_NOT_EXIST: + fputs(zFileCannotExist, option_usage_fp); + break; + + case FTYPE_MODE_MUST_EXIST: + fputs(zFileMustExist, option_usage_fp); + break; + } + return; + } + + if ((pOD->fOptState & OPTST_RESET) != 0) { + if (pOD->optCookie != NULL) + AGFREE(pOD->optCookie); + return; + } + + { + struct stat sb; + + errno = 0; + + switch (ftype & FTYPE_MODE_EXIST_MASK) { + case FTYPE_MODE_MUST_NOT_EXIST: + if ( (stat(pOD->optArg.argString, &sb) == 0) + || (errno != ENOENT) ){ + if (errno == 0) + errno = EINVAL; + fprintf(stderr, zFSOptError, errno, strerror(errno), + zFSOptErrNoExist, pOD->optArg.argString, pOD->pz_Name); + pOpts->pUsageProc(pOpts, EXIT_FAILURE); + /* NOTREACHED */ + } + /* FALLTHROUGH */ + + default: + case FTYPE_MODE_MAY_EXIST: + { + char * p = strrchr(pOD->optArg.argString, DIRCH); + if (p != NULL) + *p = NUL; + if ( (stat(pOD->optArg.argString, &sb) != 0) + || (errno = EINVAL, ! S_ISDIR(sb.st_mode)) ){ + fprintf(stderr, zFSOptError, errno, strerror(errno), + zFSOptErrMayExist, pOD->optArg.argString, pOD->pz_Name); + pOpts->pUsageProc(pOpts, EXIT_FAILURE); + /* NOTREACHED */ + } + if (p != NULL) + *p = DIRCH; + break; + } + + case FTYPE_MODE_MUST_EXIST: + if ( (stat(pOD->optArg.argString, &sb) != 0) + || (errno = EINVAL, ! S_ISREG(sb.st_mode)) ){ + fprintf(stderr, zFSOptError, errno, strerror(errno), + zFSOptErrMustExist, pOD->optArg.argString, + pOD->pz_Name); + pOpts->pUsageProc(pOpts, EXIT_FAILURE); + /* NOTREACHED */ + } + break; + } + } + + switch (ftype & FTYPE_MODE_OPEN_MASK) { + default: + case FTYPE_MODE_NO_OPEN: + break; + + case FTYPE_MODE_OPEN_FD: + { + int fd = open(pOD->optArg.argString, mode.file_flags); + if (fd < 0) { + fprintf(stderr, zFSOptError, errno, strerror(errno), + zFSOptErrOpen, pOD->optArg.argString, pOD->pz_Name); + pOpts->pUsageProc(pOpts, EXIT_FAILURE); + /* NOTREACHED */ + } + + if ((pOD->fOptState & OPTST_ALLOC_ARG) != 0) + pOD->optCookie = (void *)pOD->optArg.argString; + else + AGDUPSTR(pOD->optCookie, pOD->optArg.argString, "file name"); + + pOD->optArg.argFd = fd; + pOD->fOptState &= ~OPTST_ALLOC_ARG; + break; + } + + case FTYPE_MODE_FOPEN_FP: + { + FILE* fp = fopen(pOD->optArg.argString, mode.file_mode); + if (fp == NULL) { + fprintf(stderr, zFSOptError, errno, strerror(errno), + zFSOptErrFopen, pOD->optArg.argString, pOD->pz_Name); + pOpts->pUsageProc(pOpts, EXIT_FAILURE); + /* NOTREACHED */ + } + + if ((pOD->fOptState & OPTST_ALLOC_ARG) != 0) + pOD->optCookie = (void *)pOD->optArg.argString; + else + AGDUPSTR(pOD->optCookie, pOD->optArg.argString, "file name"); + + pOD->optArg.argFp = fp; + pOD->fOptState &= ~OPTST_ALLOC_ARG; + break; + } + } +} +/* + * Local Variables: + * mode: C + * c-file-style: "stroustrup" + * indent-tabs-mode: nil + * End: + * end of autoopts/file.c */ diff -urN src/contrib/ntp/libopts/genshell.c src.ntp/contrib/ntp/libopts/genshell.c --- src/contrib/ntp/libopts/genshell.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/genshell.c 2009-12-09 08:36:35.000000000 +0100 @@ -2,11 +2,11 @@ * * DO NOT EDIT THIS FILE (genshell.c) * - * It has been AutoGen-ed Saturday May 5, 2007 at 12:02:35 PM PDT + * It has been AutoGen-ed November 8, 2009 at 08:41:09 AM by AutoGen 5.9.10pre13 * From the definitions genshell.def * and the template file options * - * Generated from AutoOpts 29:0:4 templates. + * Generated from AutoOpts @AO_CURRENT@:@AO_REVISION@:@AO_AGE@ templates. */ /* @@ -20,27 +20,26 @@ * * This source file is copyrighted and licensed under the following terms: * - * genshellopt copyright 1999-2007 Bruce Korb - all rights reserved + * genshellopt copyright (c) 1999-2009 Bruce Korb - all rights reserved * - * genshellopt is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. + * genshellopt is free software: you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. * - * genshellopt is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. + * genshellopt is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the GNU General Public License for more details. * - * You should have received a copy of the GNU Lesser General Public - * License along with genshellopt. If not, write to: - * The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor - * Boston, MA 02110-1301, USA. + * You should have received a copy of the GNU General Public License along + * with this program. If not, see . */ - +#include #include +#include +#include #define OPTION_CODE_COMPILE 1 #include "genshell.h" @@ -48,22 +47,22 @@ #ifdef __cplusplus extern "C" { #endif + +/* TRANSLATORS: choose the translation for option names wisely because you + cannot ever change your mind. */ tSCC zCopyright[] = - "genshellopt copyright (c) 1999-2007 Bruce Korb, all rights reserved"; -tSCC zCopyrightNotice[] = - "genshellopt is free software; you can redistribute it and/or\n\ -modify it under the terms of the GNU Lesser General Public\n\ -License as published by the Free Software Foundation; either\n\ -version 2.1 of the License, or (at your option) any later version.\n\n\ -genshellopt is distributed in the hope that it will be useful,\n\ -but WITHOUT ANY WARRANTY; without even the implied warranty of\n\ -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\n\ -Lesser General Public License for more details.\n\n\ -You should have received a copy of the GNU Lesser General Public\n\ -License along with genshellopt. If not, write to:\n\ -\tThe Free Software Foundation, Inc.,\n\ -\t51 Franklin Street, Fifth Floor\n\ -\tBoston, MA 02110-1301, USA."; + "genshellopt copyright (c) 1999-2009 Bruce Korb, all rights reserved"; +tSCC zCopyrightNotice[610] = +"genshellopt is free software: you can redistribute it and/or modify it under\n\ +the terms of the GNU General Public License as published by the Free Software\n\ +Foundation, either version 3 of the License, or (at your option) any later\n\ +version.\n\n\ +genshellopt is distributed in the hope that it will be useful, but WITHOUT ANY\n\ +WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A\n\ +PARTICULAR PURPOSE. See the GNU General Public License for more details.\n\n\ +You should have received a copy of the GNU General Public License along with\n\ +this program. If not, see ."; + extern tUsageProc genshelloptUsage; #ifndef NULL @@ -75,6 +74,7 @@ #ifndef EXIT_FAILURE # define EXIT_FAILURE 1 #endif + /* * Script option description: */ @@ -100,14 +100,26 @@ /* * Help/More_Help/Version option descriptions: */ -tSCC zHelpText[] = "Display usage information and exit"; -tSCC zHelp_Name[] = "help"; - -tSCC zMore_HelpText[] = "Extended usage information passed thru pager"; -tSCC zMore_Help_Name[] = "more-help"; +tSCC zHelpText[] = "Display extended usage information and exit"; +tSCC zHelp_Name[] = "help"; +#ifdef HAVE_WORKING_FORK +#define OPTST_MORE_HELP_FLAGS (OPTST_IMM | OPTST_NO_INIT) +tSCC zMore_Help_Name[] = "more-help"; +tSCC zMore_HelpText[] = "Extended usage information passed thru pager"; +#else +#define OPTST_MORE_HELP_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#define zMore_Help_Name NULL +#define zMore_HelpText NULL +#endif +#ifdef NO_OPTIONAL_OPT_ARGS +# define OPTST_VERSION_FLAGS OPTST_IMM | OPTST_NO_INIT +#else +# define OPTST_VERSION_FLAGS OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ + OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT +#endif -tSCC zVersionText[] = "Output version information and exit"; -tSCC zVersion_Name[] = "version"; +tSCC zVersionText[] = "Output version information and exit"; +tSCC zVersion_Name[] = "version"; /* * Declare option callback procedures */ @@ -145,18 +157,11 @@ /* desc, NAME, name */ zShellText, zShell_NAME, zShell_Name, /* disablement strs */ zNotShell_Name, zNotShell_Pfx }, -#ifdef NO_OPTIONAL_OPT_ARGS -# define VERSION_OPT_FLAGS OPTST_IMM | OPTST_NO_INIT -#else -# define VERSION_OPT_FLAGS OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ - OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT -#endif - { /* entry idx, value */ INDEX_OPT_VERSION, VALUE_OPT_VERSION, /* equiv idx value */ NO_EQUIVALENT, 0, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ VERSION_OPT_FLAGS, 0, + /* opt state flags */ OPTST_VERSION_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, @@ -164,7 +169,6 @@ /* desc, NAME, name */ zVersionText, NULL, zVersion_Name, /* disablement strs */ NULL, NULL }, -#undef VERSION_OPT_FLAGS { /* entry idx, value */ INDEX_OPT_HELP, VALUE_OPT_HELP, @@ -183,7 +187,7 @@ /* equiv idx value */ NO_EQUIVALENT, 0, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, 0, + /* opt state flags */ OPTST_MORE_HELP_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, @@ -213,7 +217,7 @@ text, the second line of the file through the ending tag will be replaced\n\ by the newly generated text. The first `#!' line will be regenerated.\n"; tSCC zFullVersion[] = GENSHELLOPT_FULL_VERSION; -/* extracted from optcode.tpl near line 408 */ +/* extracted from optcode.tpl near line 495 */ #if defined(ENABLE_NLS) # define OPTPROC_BASE OPTPROC_TRANSLATE @@ -223,6 +227,9 @@ # define translate_option_strings NULL #endif /* ENABLE_NLS */ + +#define genshellopt_full_usage NULL +#define genshellopt_short_usage NULL tOptions genshelloptOptions = { OPTIONS_STRUCT_VERSION, 0, NULL, /* original argc + argv */ @@ -245,12 +252,14 @@ /* * Indexes to special options */ - { INDEX_OPT_MORE_HELP, - 0 /* no option state saving */, - NO_EQUIVALENT /* index of '-#' option */, + { INDEX_OPT_MORE_HELP, /* more-help option index */ + NO_EQUIVALENT, /* save option index */ + NO_EQUIVALENT, /* '-#' option index */ NO_EQUIVALENT /* index of default opt */ }, - 5 /* full option count */, 2 /* user option count */ + 5 /* full option count */, 2 /* user option count */, + genshellopt_full_usage, genshellopt_short_usage, + NULL, NULL }; /* @@ -261,9 +270,10 @@ tOptions* pOptions, tOptDesc* pOptDesc ) { + (void)pOptions; USAGE( EXIT_SUCCESS ); } -/* extracted from optcode.tpl near line 514 */ +/* extracted from optcode.tpl near line 627 */ #if ENABLE_NLS #include @@ -306,44 +316,45 @@ * Guard against re-translation. It won't work. The strings will have * been changed by the first pass through this code. One shot only. */ - if (option_usage_text.field_ct == 0) - return; - /* - * Do the translations. The first pointer follows the field count field. - * The field count field is the size of a pointer. - */ - { - char** ppz = (char**)(void*)&(option_usage_text); - int ix = option_usage_text.field_ct; + if (option_usage_text.field_ct != 0) { + + /* + * Do the translations. The first pointer follows the field count + * field. The field count field is the size of a pointer. + */ + tOptDesc* pOD = genshelloptOptions.pOptDesc; + char** ppz = (char**)(void*)&(option_usage_text); + int ix = option_usage_text.field_ct; do { ppz++; *ppz = AO_gettext(*ppz); } while (--ix > 0); + + COERSION(pzCopyright); + COERSION(pzCopyNotice); + COERSION(pzFullVersion); + COERSION(pzUsageTitle); + COERSION(pzExplain); + COERSION(pzDetail); + option_usage_text.field_ct = 0; + + for (ix = genshelloptOptions.optCt; ix > 0; ix--, pOD++) + coerce_it((void*)&(pOD->pzText)); } - option_usage_text.field_ct = 0; - { + if ((genshelloptOptions.fOptSet & OPTPROC_NXLAT_OPT_CFG) == 0) { tOptDesc* pOD = genshelloptOptions.pOptDesc; - int ix = genshelloptOptions.optCt; + int ix; - for (;;) { - pOD->pzText = AO_gettext(pOD->pzText); - pOD->pz_NAME = AO_gettext(pOD->pz_NAME); - pOD->pz_Name = AO_gettext(pOD->pz_Name); - pOD->pz_DisableName = AO_gettext(pOD->pz_DisableName); - pOD->pz_DisablePfx = AO_gettext(pOD->pz_DisablePfx); - if (--ix <= 0) - break; - pOD++; + for (ix = genshelloptOptions.optCt; ix > 0; ix--, pOD++) { + coerce_it((void*)&(pOD->pz_Name)); + coerce_it((void*)&(pOD->pz_DisableName)); + coerce_it((void*)&(pOD->pz_DisablePfx)); } + /* prevent re-translation */ + genshelloptOptions.fOptSet |= OPTPROC_NXLAT_OPT_CFG | OPTPROC_NXLAT_OPT; } - COERSION(pzCopyright); - COERSION(pzCopyNotice); - COERSION(pzFullVersion); - COERSION(pzUsageTitle); - COERSION(pzExplain); - COERSION(pzDetail); } #endif /* ENABLE_NLS */ diff -urN src/contrib/ntp/libopts/genshell.h src.ntp/contrib/ntp/libopts/genshell.h --- src/contrib/ntp/libopts/genshell.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/genshell.h 2009-12-09 08:36:35.000000000 +0100 @@ -2,11 +2,11 @@ * * DO NOT EDIT THIS FILE (genshell.h) * - * It has been AutoGen-ed Saturday May 5, 2007 at 12:02:35 PM PDT + * It has been AutoGen-ed November 8, 2009 at 08:41:09 AM by AutoGen 5.9.10pre13 * From the definitions genshell.def * and the template file options * - * Generated from AutoOpts 29:0:4 templates. + * Generated from AutoOpts @AO_CURRENT@:@AO_REVISION@:@AO_AGE@ templates. */ /* @@ -20,23 +20,20 @@ * * This source file is copyrighted and licensed under the following terms: * - * genshellopt copyright 1999-2007 Bruce Korb - all rights reserved + * genshellopt copyright (c) 1999-2009 Bruce Korb - all rights reserved * - * genshellopt is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. + * genshellopt is free software: you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. * - * genshellopt is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. + * genshellopt is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the GNU General Public License for more details. * - * You should have received a copy of the GNU Lesser General Public - * License along with genshellopt. If not, write to: - * The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor - * Boston, MA 02110-1301, USA. + * You should have received a copy of the GNU General Public License along + * with this program. If not, see . */ /* * This file contains the programmatic interface to the Automated @@ -45,7 +42,7 @@ * "AutoOpts" chapter. Please refer to that doc for usage help. */ #ifndef AUTOOPTS_GENSHELL_H_GUARD -#define AUTOOPTS_GENSHELL_H_GUARD +#define AUTOOPTS_GENSHELL_H_GUARD 1 #include /* @@ -55,7 +52,7 @@ * tolerable version is at least as old as what was current when the header * template was released. */ -#define AO_TEMPLATE_VERSION 118784 +#define AO_TEMPLATE_VERSION 135168 #if (AO_TEMPLATE_VERSION < OPTIONS_MINIMUM_VERSION) \ || (AO_TEMPLATE_VERSION > OPTIONS_STRUCT_VERSION) # error option template version mismatches autoopts/options.h header @@ -66,11 +63,11 @@ * Enumeration of each option: */ typedef enum { - INDEX_OPT_SCRIPT = 0, - INDEX_OPT_SHELL = 1, - INDEX_OPT_VERSION = 2, - INDEX_OPT_HELP = 3, - INDEX_OPT_MORE_HELP = 4 + INDEX_OPT_SCRIPT = 0, + INDEX_OPT_SHELL = 1, + INDEX_OPT_VERSION = 2, + INDEX_OPT_HELP = 3, + INDEX_OPT_MORE_HELP = 4 } teOptIndex; #define OPTION_CT 5 @@ -98,15 +95,15 @@ DESC(n).fOptState |= OPTST_DISABLED; \ DESC(n).optCookie = NULL ) -/* +/* * * * * * + * * Interface defines for specific options. */ #define VALUE_OPT_SCRIPT 'o' #define VALUE_OPT_SHELL 's' - -#define VALUE_OPT_VERSION 'v' #define VALUE_OPT_HELP '?' #define VALUE_OPT_MORE_HELP '!' +#define VALUE_OPT_VERSION 'v' /* * Interface defines not associated with particular options */ @@ -117,7 +114,7 @@ genshelloptOptions.pzCurOpt = NULL ) #define START_OPT RESTART_OPT(1) #define USAGE(c) (*genshelloptOptions.pUsageProc)( &genshelloptOptions, c ) -/* extracted from opthead.tpl near line 360 */ +/* extracted from opthead.tpl near line 409 */ /* * * * * * * @@ -129,18 +126,37 @@ extern tOptions genshelloptOptions; -#ifndef _ -# if ENABLE_NLS -# include - static inline char* aoGetsText( char const* pz ) { - if (pz == NULL) return NULL; - return (char*)gettext( pz ); - } -# define _(s) aoGetsText(s) -# else /* ENABLE_NLS */ -# define _(s) s -# endif /* ENABLE_NLS */ -#endif +#if defined(ENABLE_NLS) +# ifndef _ +# include + static inline char* aoGetsText( char const* pz ) { + if (pz == NULL) return NULL; + return (char*)gettext( pz ); + } +# define _(s) aoGetsText(s) +# endif /* _() */ + +# define OPT_NO_XLAT_CFG_NAMES STMTS(genshelloptOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT_CFG;) +# define OPT_NO_XLAT_OPT_NAMES STMTS(genshelloptOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG;) + +# define OPT_XLAT_CFG_NAMES STMTS(genshelloptOptions.fOptSet &= \ + ~(OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG);) +# define OPT_XLAT_OPT_NAMES STMTS(genshelloptOptions.fOptSet &= \ + ~OPTPROC_NXLAT_OPT;) + +#else /* ENABLE_NLS */ +# define OPT_NO_XLAT_CFG_NAMES +# define OPT_NO_XLAT_OPT_NAMES + +# define OPT_XLAT_CFG_NAMES +# define OPT_XLAT_OPT_NAMES + +# ifndef _ +# define _(_s) _s +# endif +#endif /* ENABLE_NLS */ #ifdef __cplusplus } diff -urN src/contrib/ntp/libopts/libopts.c src.ntp/contrib/ntp/libopts/libopts.c --- src/contrib/ntp/libopts/libopts.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/libopts.c 2009-12-09 08:36:35.000000000 +0100 @@ -4,14 +4,20 @@ #include "autoopts/options.h" #include "autoopts/usage-txt.h" #include "genshell.h" +#include "xat-attribute.h" +#include "value-type.h" +#include "ag-char-map.h" #include "autoopts.h" #include "proto.h" +#include "value-type.c" +#include "xat-attribute.c" #include "autoopts.c" #include "boolean.c" #include "configfile.c" #include "cook.c" #include "enumeration.c" #include "environment.c" +#include "file.c" #include "genshell.c" #include "load.c" #include "makeshell.c" @@ -19,6 +25,7 @@ #include "numeric.c" #include "pgusage.c" #include "putshell.c" +#include "reset.c" #include "restore.c" #include "save.c" #include "sort.c" @@ -26,5 +33,6 @@ #include "streqvcmp.c" #include "text_mmap.c" #include "tokenize.c" +#include "time.c" #include "usage.c" #include "version.c" diff -urN src/contrib/ntp/libopts/load.c src.ntp/contrib/ntp/libopts/load.c --- src/contrib/ntp/libopts/load.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/load.c 2009-12-09 08:36:35.000000000 +0100 @@ -1,60 +1,37 @@ /* - * $Id: load.c,v 4.20 2007/02/04 22:17:39 bkorb Exp $ - * Time-stamp: "2007-02-04 11:54:57 bkorb" + * $Id: f0ececd5fec43bacb417d7b50294accc2121923f $ + * Time-stamp: "2008-12-06 10:16:05 bkorb" * * This file contains the routines that deal with processing text strings * for options, either from a NUL-terminated string passed in or from an * rc/ini file. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ tOptionLoadMode option_load_mode = OPTION_LOAD_UNCOOKED; /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static ag_bool insertProgramPath( char* pzBuf, @@ -86,8 +63,8 @@ * ret-desc: AG_TRUE if the name was handled, otherwise AG_FALSE. * If the name does not start with ``$'', then it is handled * simply by copying the input name to the output buffer and - * resolving the name with either @code{canonicalize_file_name(3GLIBC)} - * or @code{realpath(3C)}. + * resolving the name with either + * @code{canonicalize_file_name(3GLIBC)} or @code{realpath(3C)}. * * doc: * @@ -277,7 +254,7 @@ * allocated and we need to deallocate it. */ if (pzPath != pzProgPath) - free( (void*)pzPath ); + AGFREE(pzPath); return AG_TRUE; } @@ -293,7 +270,7 @@ for (;;) { int ch = (int)*++pzName; - if (! ISNAMECHAR( ch )) + if (! IS_VALUE_NAME_CHAR(ch)) break; *(pzDir++) = (char)ch; } @@ -327,16 +304,16 @@ if (mode == OPTION_LOAD_KEEP) return; - if (isspace( (int)*pzTxt )) { + if (IS_WHITESPACE_CHAR(*pzTxt)) { char* pzS = pzTxt; char* pzD = pzTxt; - while (isspace( (int)*++pzS )) ; + while (IS_WHITESPACE_CHAR(*++pzS)) ; while ((*(pzD++) = *(pzS++)) != NUL) ; pzE = pzD-1; } else pzE = pzTxt + strlen( pzTxt ); - while ((pzE > pzTxt) && isspace( (int)pzE[-1] )) pzE--; + while ((pzE > pzTxt) && IS_WHITESPACE_CHAR(pzE[-1])) pzE--; *pzE = NUL; if (mode == OPTION_LOAD_UNCOOKED) @@ -361,7 +338,7 @@ static char* assembleArgValue( char* pzTxt, tOptionLoadMode mode ) { - tSCC zBrk[] = " \t:="; + tSCC zBrk[] = " \t\n:="; char* pzEnd = strpbrk( pzTxt, zBrk ); int space_break; @@ -386,11 +363,11 @@ * because we'll have to skip over an immediately following ':' or '=' * (and the white space following *that*). */ - space_break = isspace((int)*pzEnd); + space_break = IS_WHITESPACE_CHAR(*pzEnd); *(pzEnd++) = NUL; - while (isspace((int)*pzEnd)) pzEnd++; + while (IS_WHITESPACE_CHAR(*pzEnd)) pzEnd++; if (space_break && ((*pzEnd == ':') || (*pzEnd == '='))) - while (isspace((int)*++pzEnd)) ; + while (IS_WHITESPACE_CHAR(*++pzEnd)) ; return pzEnd; } @@ -410,7 +387,7 @@ tDirection direction, tOptionLoadMode load_mode ) { - while (isspace( (int)*pzLine )) pzLine++; + while (IS_WHITESPACE_CHAR(*pzLine)) pzLine++; { char* pzArg = assembleArgValue( pzLine, load_mode ); diff -urN src/contrib/ntp/libopts/m4/libopts.m4 src.ntp/contrib/ntp/libopts/m4/libopts.m4 --- src/contrib/ntp/libopts/m4/libopts.m4 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/m4/libopts.m4 2009-12-09 08:36:35.000000000 +0100 @@ -2,7 +2,7 @@ dnl dnl DO NOT EDIT THIS FILE (libopts.m4) dnl -dnl It has been AutoGen-ed Saturday May 5, 2007 at 12:02:37 PM PDT +dnl It has been AutoGen-ed November 8, 2009 at 08:41:10 AM by AutoGen 5.9.10pre13 dnl From the definitions libopts.def dnl and the template file conftest.tpl dnl @@ -10,13 +10,7 @@ dnl AC_DEFUN([INVOKE_LIBOPTS_MACROS_FIRST],[ [if test X${INVOKE_LIBOPTS_MACROS_FIRST_done} != Xyes ; then] - # ================= - # AC_HEADER_STDC - # ================= AC_HEADER_STDC - # ================= - # AC_HEADER_DIRENT - # ================= AC_HEADER_DIRENT # ================= @@ -62,19 +56,41 @@ AC_MSG_ERROR([You must have one of limits.h, sys/limits.h or values.h]) fi + # ---------------------------------------------------------------------- + # check for various programs used during the build. + # On OS/X, "wchar.h" needs "runetype.h" to work properly. + # ---------------------------------------------------------------------- + AC_CHECK_HEADERS([runetype.h wchar.h], [], [],[ + AC_INCLUDES_DEFAULT + #if HAVE_RUNETYPE_H + # include + #endif + ]) + + # ---------------------------------------------------------------------- + # Checks for typedefs + # ---------------------------------------------------------------------- + AC_CHECK_TYPES(wchar_t) + AC_CHECK_TYPES(wint_t, [], [], [ + AC_INCLUDES_DEFAULT + #if HAVE_RUNETYPE_H + # include + #endif + #if HAVE_WCHAR_H + # include + #endif + ]) + # ======================== # ...and int types headers # ======================== AC_CHECK_HEADERS(stdint.h inttypes.h, break) AC_CHECK_TYPES([int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, - intptr_t, uint_t]) + intptr_t, uintptr_t, uint_t, pid_t, size_t]) - # ==================== - # uintptr type & sizes - # ==================== - AC_CHECK_TYPES([uintptr_t], , - [AC_DEFINE([uintptr_t], unsigned long, - [Alternate uintptr_t for systems without it.])]) + # ===== + # sizes + # ===== AC_CHECK_SIZEOF(char*, 4) AC_CHECK_SIZEOF(int, 4) AC_CHECK_SIZEOF(long, 4) @@ -85,7 +101,9 @@ # ---------------------------------------------------------------------- AC_CHECK_LIB(gen, pathfind) AC_FUNC_VPRINTF - AC_CHECK_FUNCS([mmap canonicalize_file_name snprintf strdup strchr strrchr]) + AC_FUNC_FORK + AC_CHECK_FUNCS([mmap canonicalize_file_name snprintf strdup strchr \ + strrchr strsignal]) [ INVOKE_LIBOPTS_MACROS_FIRST_done=yes fi]]) @@ -420,14 +438,29 @@ dnl @synopsis LIBOPTS_CHECK dnl -dnl Time-stamp: "2006-09-23 19:36:24 bkorb" -dnl Last Committed: $Date: 2006/09/24 02:59:00 $ +dnl Time-stamp: "2009-07-22 18:50:49 bkorb" dnl dnl If autoopts-config works, add the linking information to LIBS. dnl Otherwise, add ``libopts-${ao_rev}'' to SUBDIRS and run all dnl the config tests that the library needs. Invoke the dnl "INVOKE_LIBOPTS_MACROS" macro iff we are building libopts. dnl +dnl This file is part of AutoGen. +dnl AutoGen copyright (c) 1992-2009 by Bruce Korb - all rights reserved +dnl +dnl AutoGen is free software: you can redistribute it and/or modify it +dnl under the terms of the GNU General Public License as published by the +dnl Free Software Foundation, either version 3 of the License, or +dnl (at your option) any later version. +dnl +dnl AutoGen is distributed in the hope that it will be useful, but +dnl WITHOUT ANY WARRANTY; without even the implied warranty of +dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +dnl See the GNU General Public License for more details. +dnl +dnl You should have received a copy of the GNU General Public License along +dnl with this program. If not, see . +dnl dnl Default to system libopts dnl AC_DEFUN([LIBOPTS_CHECK],[ diff -urN src/contrib/ntp/libopts/m4/liboptschk.m4 src.ntp/contrib/ntp/libopts/m4/liboptschk.m4 --- src/contrib/ntp/libopts/m4/liboptschk.m4 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/m4/liboptschk.m4 2009-12-09 08:36:35.000000000 +0100 @@ -1,11 +1,11 @@ # liboptschk.m4 serial 1 (autogen - 5.7.3) -dnl Copyright (C) 2005 Free Software Foundation, Inc. +dnl copyright (c) 2005-2009 by Bruce Korb - all rights reserved +dnl dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, dnl with or without modifications, as long as this notice is preserved. -dnl Time-stamp: "2006-09-23 19:42:31 bkorb" -dnl Last Committed: $Date: 2006/09/24 02:59:00 $ +dnl Time-stamp: "2009-07-22 18:53:27 bkorb" dnl This file can can be used in projects which are not available under dnl the GNU General Public License or the GNU Library General Public diff -urN src/contrib/ntp/libopts/makeshell.c src.ntp/contrib/ntp/libopts/makeshell.c --- src/contrib/ntp/libopts/makeshell.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/makeshell.c 2009-12-09 08:36:36.000000000 +0100 @@ -1,53 +1,30 @@ /* - * $Id: makeshell.c,v 4.20 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-27 06:05:45 bkorb" + * $Id: 7226344c6486a4eda395f893881080b7d80a2003 $ + * Time-stamp: "2009-11-01 11:52:37 bkorb" * * This module will interpret the options set in the tOptions * structure and create a Bourne shell script capable of parsing them. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ tOptions* pShellParseOptions = NULL; @@ -56,19 +33,19 @@ * * Setup Format Strings */ -tSCC zStartMarker[] = +static char const zStartMarker[] = "# # # # # # # # # # -- do not modify this marker --\n#\n" "# DO NOT EDIT THIS SECTION"; -tSCC zPreamble[] = +static char const zPreamble[] = "%s OF %s\n#\n" "# From here to the next `-- do not modify this marker --',\n" "# the text has been generated %s\n"; -tSCC zEndPreamble[] = +static char const zEndPreamble[] = "# From the %s option definitions\n#\n"; -tSCC zMultiDef[] = "\n" +static char const zMultiDef[] = "\n" "if test -z \"${%1$s_%2$s}\"\n" "then\n" " %1$s_%2$s_CT=0\n" @@ -78,12 +55,12 @@ "fi\n" "export %1$s_%2$s_CT"; -tSCC zSingleDef[] = "\n" +static char const zSingleDef[] = "\n" "%1$s_%2$s=\"${%1$s_%2$s-'%3$s'}\"\n" "%1$s_%2$s_set=false\n" "export %1$s_%2$s\n"; -tSCC zSingleNoDef[] = "\n" +static char const zSingleNoDef[] = "\n" "%1$s_%2$s=\"${%1$s_%2$s}\"\n" "%1$s_%2$s_set=false\n" "export %1$s_%2$s\n"; @@ -96,7 +73,7 @@ * all options are named options (loop only) * regular, marked option processing. */ -tSCC zLoopCase[] = "\n" +static char const zLoopCase[] = "\n" "OPT_PROCESS=true\n" "OPT_ARG=\"$1\"\n\n" "while ${OPT_PROCESS} && [ $# -gt 0 ]\ndo\n" @@ -111,7 +88,7 @@ " shift\n" " ;;\n\n"; -tSCC zLoopOnly[] = "\n" +static char const zLoopOnly[] = "\n" "OPT_ARG=\"$1\"\n\n" "while [ $# -gt 0 ]\ndo\n" " OPT_ELEMENT=''\n" @@ -126,16 +103,16 @@ * then we must have selectors for each acceptable option * type (long option, flag character and non-option) */ -tSCC zLongSelection[] = +static char const zLongSelection[] = " --* )\n"; -tSCC zFlagSelection[] = +static char const zFlagSelection[] = " -* )\n"; -tSCC zEndSelection[] = +static char const zEndSelection[] = " ;;\n\n"; -tSCC zNoSelection[] = +static char const zNoSelection[] = " * )\n" " OPT_PROCESS=false\n" " ;;\n" @@ -145,7 +122,7 @@ * * LOOP END */ -tSCC zLoopEnd[] = +static char const zLoopEnd[] = " if [ -n \"${OPT_ARG_VAL}\" ]\n" " then\n" " eval %1$s_${OPT_NAME}${OPT_ELEMENT}=\"'${OPT_ARG_VAL}'\"\n" @@ -160,7 +137,7 @@ "unset OPT_CODE || :\n" "unset OPT_ARG_VAL || :\n%2$s"; -tSCC zTrailerMarker[] = "\n" +static char const zTrailerMarker[] = "\n" "# # # # # # # # # #\n#\n" "# END OF AUTOMATED OPTION PROCESSING\n" "#\n# # # # # # # # # # -- do not modify this marker --\n"; @@ -169,22 +146,22 @@ * * OPTION SELECTION */ -tSCC zOptionCase[] = +static char const zOptionCase[] = " case \"${OPT_CODE}\" in\n"; -tSCC zOptionPartName[] = +static char const zOptionPartName[] = " '%s' | \\\n"; -tSCC zOptionFullName[] = +static char const zOptionFullName[] = " '%s' )\n"; -tSCC zOptionFlag[] = +static char const zOptionFlag[] = " '%c' )\n"; -tSCC zOptionEndSelect[] = +static char const zOptionEndSelect[] = " ;;\n\n"; -tSCC zOptionUnknown[] = +static char const zOptionUnknown[] = " * )\n" " echo Unknown %s: \"${OPT_CODE}\" >&2\n" " echo \"$%s_USAGE_TEXT\"\n" @@ -198,29 +175,29 @@ * * Formats for emitting the text for handling particular options */ -tSCC zTextExit[] = +static char const zTextExit[] = " echo \"$%s_%s_TEXT\"\n" " exit 0\n"; -tSCC zPagedUsageExit[] = +static char const zPagedUsageExit[] = " echo \"$%s_LONGUSAGE_TEXT\" | ${PAGER-more}\n" " exit 0\n"; -tSCC zCmdFmt[] = +static char const zCmdFmt[] = " %s\n"; -tSCC zCountTest[] = +static char const zCountTest[] = " if [ $%1$s_%2$s_CT -ge %3$d ] ; then\n" " echo Error: more than %3$d %2$s options >&2\n" " echo \"$%1$s_USAGE_TEXT\"\n" " exit 1 ; fi\n"; -tSCC zMultiArg[] = +static char const zMultiArg[] = " %1$s_%2$s_CT=`expr ${%1$s_%2$s_CT} + 1`\n" " OPT_ELEMENT=\"_${%1$s_%2$s_CT}\"\n" " OPT_NAME='%2$s'\n"; -tSCC zSingleArg[] = +static char const zSingleArg[] = " if [ -n \"${%1$s_%2$s}\" ] && ${%1$s_%2$s_set} ; then\n" " echo Error: duplicate %2$s option >&2\n" " echo \"$%1$s_USAGE_TEXT\"\n" @@ -228,14 +205,14 @@ " %1$s_%2$s_set=true\n" " OPT_NAME='%2$s'\n"; -tSCC zNoMultiArg[] = +static char const zNoMultiArg[] = " %1$s_%2$s_CT=0\n" " OPT_ELEMENT=''\n" " %1$s_%2$s='%3$s'\n" " export %1$s_%2$s\n" " OPT_NAME='%2$s'\n"; -tSCC zNoSingleArg[] = +static char const zNoSingleArg[] = " if [ -n \"${%1$s_%2$s}\" ] && ${%1$s_%2$s_set} ; then\n" " echo Error: duplicate %2$s option >&2\n" " echo \"$%1$s_USAGE_TEXT\"\n" @@ -245,15 +222,15 @@ " export %1$s_%2$s\n" " OPT_NAME='%2$s'\n"; -tSCC zMayArg[] = +static char const zMayArg[] = " eval %1$s_%2$s${OPT_ELEMENT}=true\n" " export %1$s_%2$s${OPT_ELEMENT}\n" " OPT_ARG_NEEDED=OK\n"; -tSCC zMustArg[] = +static char const zMustArg[] = " OPT_ARG_NEEDED=YES\n"; -tSCC zCantArg[] = +static char const zCantArg[] = " eval %1$s_%2$s${OPT_ELEMENT}=true\n" " export %1$s_%2$s${OPT_ELEMENT}\n" " OPT_ARG_NEEDED=NO\n"; @@ -264,7 +241,7 @@ * * Formats for emitting the text for handling long option types */ -tSCC zLongOptInit[] = +static char const zLongOptInit[] = " OPT_CODE=`echo \"X${OPT_ARG}\"|sed 's/^X-*//'`\n" " shift\n" " OPT_ARG=\"$1\"\n\n" @@ -272,7 +249,7 @@ " OPT_ARG_VAL=`echo \"${OPT_CODE}\"|sed 's/^[^=]*=//'`\n" " OPT_CODE=`echo \"${OPT_CODE}\"|sed 's/=.*$//'` ;; esac\n\n"; -tSCC zLongOptArg[] = +static char const zLongOptArg[] = " case \"${OPT_ARG_NEEDED}\" in\n" " NO )\n" " OPT_ARG_VAL=''\n" @@ -308,11 +285,11 @@ * * Formats for emitting the text for handling flag option types */ -tSCC zFlagOptInit[] = +static char const zFlagOptInit[] = " OPT_CODE=`echo \"X${OPT_ARG}\" | sed 's/X-\\(.\\).*/\\1/'`\n" " OPT_ARG=` echo \"X${OPT_ARG}\" | sed 's/X-.//'`\n\n"; -tSCC zFlagOptArg[] = +static char const zFlagOptArg[] = " case \"${OPT_ARG_NEEDED}\" in\n" " NO )\n" " if [ -n \"${OPT_ARG}\" ]\n" @@ -364,7 +341,7 @@ static char* pzTrailer = NULL; /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static void textToVariable( tOptions* pOpts, teTextTo whichVar, tOptDesc* pOD ); @@ -506,7 +483,7 @@ static char const* apzTTNames[] = { TEXTTO_TABLE }; # undef _TT_ -#if defined(__windows__) && !defined(__CYGWIN__) +#if ! defined(HAVE_WORKING_FORK) printf( "%1$s_%2$s_TEXT='no %2$s text'\n", pOpts->pzPROGNAME, apzTTNames[ whichVar ]); #else @@ -695,7 +672,7 @@ */ switch (OPTST_GET_ARGTYPE(pOptDesc->fOptState)) { case OPARG_TYPE_ENUMERATION: - (*(pOptDesc->pOptProc))( (tOptions*)2UL, pOptDesc ); + (*(pOptDesc->pOptProc))(OPTPROC_EMIT_SHELL, pOptDesc ); pzDefault = pOptDesc->optArg.argString; break; @@ -815,7 +792,7 @@ if (SKIP_OPT(pOptDesc)) continue; - if (isprint( pOptDesc->optValue )) { + if (IS_GRAPHIC_CHAR(pOptDesc->optValue)) { printf( zOptionFlag, pOptDesc->optValue ); printOptionAction( pOpts, pOptDesc ); } @@ -1036,7 +1013,7 @@ void genshelloptUsage( tOptions* pOpts, int exitCode ) { -#if defined(__windows__) && !defined(__CYGWIN__) +#if ! defined(HAVE_WORKING_FORK) optionUsage( pOpts, exitCode ); #else /* @@ -1056,13 +1033,13 @@ switch (fork()) { case -1: optionUsage( pOpts, EXIT_FAILURE ); - /*NOTREACHED*/ + /* NOTREACHED */ _exit( EXIT_FAILURE ); case 0: pagerState = PAGER_STATE_CHILD; optionUsage( pOpts, EXIT_SUCCESS ); - /*NOTREACHED*/ + /* NOTREACHED */ _exit( EXIT_FAILURE ); default: diff -urN src/contrib/ntp/libopts/nested.c src.ntp/contrib/ntp/libopts/nested.c --- src/contrib/ntp/libopts/nested.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/nested.c 2009-12-09 08:36:36.000000000 +0100 @@ -1,57 +1,49 @@ /* - * $Id: nested.c,v 4.14 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-26 11:04:35 bkorb" + * $Id: 43877d3ade0b626b4bec87f2f340a8358c118333 $ + * Time-stamp: "2008-07-28 19:18:28 bkorb" * * Automated Options Nested Values module. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd + */ + +typedef struct { + int xml_ch; + int xml_len; + char xml_txt[8]; +} xml_xlate_t; + +static xml_xlate_t const xml_xlate[] = { + { '&', 4, "amp;" }, + { '<', 3, "lt;" }, + { '>', 3, "gt;" }, + { '"', 5, "quot;" }, + { '\'',5, "apos;" } +}; + /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static void -removeBackslashes( char* pzSrc ); +removeLineContinue( char* pzSrc ); static char const* scanQuotedString( char const* pzTxt ); @@ -85,27 +77,42 @@ sortNestedList( tArgList* pAL ); /* = = = END-STATIC-FORWARD = = = */ -/* removeBackslashes +/* removeLineContinue * - * This function assumes that all newline characters were preceeded by - * backslashes that need removal. + * Backslashes are used for line continuations. We keep the newline + * characters, but trim out the backslash: */ static void -removeBackslashes( char* pzSrc ) +removeLineContinue( char* pzSrc ) { - char* pzD = strchr(pzSrc, '\n'); + char* pzD; - if (pzD == NULL) - return; - *--pzD = '\n'; + do { + while (*pzSrc == '\n') pzSrc++; + pzD = strchr(pzSrc, '\n'); + if (pzD == NULL) + return; + + /* + * pzD has skipped at least one non-newline character and now + * points to a newline character. It now becomes the source and + * pzD goes to the previous character. + */ + pzSrc = pzD--; + if (*pzD != '\\') + pzD++; + } while (pzD == pzSrc); + /* + * Start shifting text. + */ for (;;) { char ch = ((*pzD++) = *(pzSrc++)); switch (ch) { - case '\n': *--pzD = ch; break; case NUL: return; - default: - ; + case '\\': + if (*pzSrc == '\n') + --pzD; /* rewrite on next iteration */ } } } @@ -170,9 +177,24 @@ } else { pNV->valType = OPARG_TYPE_STRING; - if (dataLen > 0) - memcpy( pNV->v.strVal, pzValue, dataLen ); - pNV->v.strVal[dataLen] = NUL; + if (dataLen > 0) { + char const * pzSrc = pzValue; + char * pzDst = pNV->v.strVal; + int ct = dataLen; + do { + int ch = *(pzSrc++) & 0xFF; + if (ch == NUL) goto data_copy_done; + if (ch == '&') + ch = get_special_char(&pzSrc, &ct); + *(pzDst++) = ch; + } while (--ct > 0); + data_copy_done: + *pzDst = NUL; + + } else { + pNV->v.strVal[0] = NUL; + } + pNV->pzName = pNV->v.strVal + dataLen + 1; } @@ -197,22 +219,16 @@ pNV = AGALOC( sz, "option name/bool value pair" ); if (pNV == NULL) return NULL; - while (isspace( (int)*pzValue ) && (dataLen > 0)) { + while (IS_WHITESPACE_CHAR(*pzValue) && (dataLen > 0)) { dataLen--; pzValue++; } if (dataLen == 0) pNV->v.boolVal = 0; - else if (isdigit( (int)*pzValue )) - pNV->v.boolVal = atoi( pzValue ); - else switch (*pzValue) { - case 'f': - case 'F': - case 'n': - case 'N': - pNV->v.boolVal = 0; break; - default: - pNV->v.boolVal = 1; - } + + else if (IS_DEC_DIGIT_CHAR(*pzValue)) + pNV->v.boolVal = atoi(pzValue); + + else pNV->v.boolVal = ! IS_FALSE_TYPE_CHAR(*pzValue); pNV->valType = OPARG_TYPE_BOOLEAN; pNV->pzName = (char*)(pNV + 1); @@ -237,16 +253,16 @@ pNV = AGALOC( sz, "option name/bool value pair" ); if (pNV == NULL) return NULL; - while (isspace( (int)*pzValue ) && (dataLen > 0)) { + while (IS_WHITESPACE_CHAR(*pzValue) && (dataLen > 0)) { dataLen--; pzValue++; } if (dataLen == 0) - pNV->v.boolVal = 0; + pNV->v.longVal = 0; else - pNV->v.boolVal = atoi( pzValue ); + pNV->v.longVal = strtol(pzValue, 0, 0); pNV->valType = OPARG_TYPE_NUMERIC; - pNV->pzName = (char*)(pNV + 1); + pNV->pzName = (char*)(pNV + 1); memcpy( pNV->pzName, pzName, nameLen ); pNV->pzName[ nameLen ] = NUL; addArgListEntry( pp, pNV ); @@ -295,46 +311,39 @@ scanNameEntry(char const* pzName, tOptionValue* pRes) { tOptionValue* pNV; - char const * pzScan = pzName+1; + char const * pzScan = pzName+1; /* we know first char is a name char */ char const * pzVal; size_t nameLen = 1; size_t dataLen = 0; - while (ISNAMECHAR( (int)*pzScan )) { pzScan++; nameLen++; } - - while (isspace( (int)*pzScan )) { - char ch = *(pzScan++); - if ((ch == '\n') || (ch == ',')) { - addStringValue(&(pRes->v.nestVal), pzName, nameLen, NULL,(size_t)0); - return pzScan - 1; - } - } + /* + * Scan over characters that name a value. These names may not end + * with a colon, but they may contain colons. + */ + while (IS_VALUE_NAME_CHAR(*pzScan)) { pzScan++; nameLen++; } + if (pzScan[-1] == ':') { pzScan--; nameLen--; } + while (IS_HORIZ_WHITE_CHAR(*pzScan)) pzScan++; +re_switch: switch (*pzScan) { case '=': case ':': - while (isspace( (int)*++pzScan )) ; - switch (*pzScan) { - case ',': goto comma_char; - case '"': - case '\'': goto quote_char; - case NUL: goto nul_byte; - default: goto default_char; - } + while (IS_HORIZ_WHITE_CHAR( (int)*++pzScan )) ; + if ((*pzScan == '=') || (*pzScan == ':')) + goto default_char; + goto re_switch; + case '\n': case ',': - comma_char: pzScan++; /* FALLTHROUGH */ case NUL: - nul_byte: addStringValue(&(pRes->v.nestVal), pzName, nameLen, NULL, (size_t)0); break; case '"': case '\'': - quote_char: pzVal = pzScan; pzScan = scanQuotedString( pzScan ); dataLen = pzScan - pzVal; @@ -373,7 +382,7 @@ pNV = addStringValue( &(pRes->v.nestVal), pzName, nameLen, pzVal, dataLen ); if (pNV != NULL) - removeBackslashes( pNV->v.strVal ); + removeLineContinue( pNV->v.strVal ); goto leave_scan_name; } } @@ -400,7 +409,7 @@ tOptionValue* pNewVal; tOptionLoadMode save_mode = option_load_mode; - if (! isalpha((int)*pzName)) { + if (! IS_VAR_FIRST_CHAR(*pzName)) { switch (*pzName) { default: pzName = NULL; @@ -421,7 +430,8 @@ return pzName; } - while (isalpha( (int)*++pzScan )) nameLen++; + pzScan++; + while (IS_VALUE_NAME_CHAR( (int)*pzScan )) { pzScan++; nameLen++; } if (nameLen > 64) return NULL; valu.valType = OPARG_TYPE_STRING; @@ -449,7 +459,7 @@ } addStringValue(&(pRes->v.nestVal), pzName, nameLen, NULL, (size_t)0); option_load_mode = save_mode; - return pzScan+2; + return pzScan+1; default: option_load_mode = save_mode; @@ -484,7 +494,7 @@ } valLen = (pzScan - pzVal); pzScan += nameLen + 3; - while (isspace( (int)*pzScan )) pzScan++; + while (IS_WHITESPACE_CHAR(*pzScan)) pzScan++; } switch (valu.valType) { @@ -651,7 +661,7 @@ errno = EINVAL; return NULL; } - while (isspace( (int)*pzTxt )) pzTxt++; + while (IS_WHITESPACE_CHAR(*pzTxt)) pzTxt++; if (*pzTxt == NUL) { errno = ENOENT; return NULL; @@ -679,13 +689,14 @@ * Scan until we hit a NUL. */ do { - while (isspace( (int)*pzTxt )) pzTxt++; - if (isalpha( (int)*pzTxt )) { + while (IS_WHITESPACE_CHAR( (int)*pzTxt )) pzTxt++; + if (IS_VAR_FIRST_CHAR( (int)*pzTxt )) { pzTxt = scanNameEntry( pzTxt, pRes ); } else switch (*pzTxt) { case NUL: goto scan_done; case '<': pzTxt = scanXmlEntry( pzTxt, pRes ); + if (pzTxt == NULL) goto woops; if (*pzTxt == ',') pzTxt++; break; case '#': pzTxt = strchr( pzTxt, '\n' ); break; default: goto woops; @@ -716,14 +727,113 @@ * Nested value was found on the command line =*/ void -optionNestedVal( tOptions* pOpts, tOptDesc* pOD ) +optionNestedVal(tOptions* pOpts, tOptDesc* pOD) +{ + if (pOpts < OPTPROC_EMIT_LIMIT) + return; + + if (pOD->fOptState & OPTST_RESET) { + tArgList* pAL = pOD->optCookie; + int ct; + tCC ** av; + + if (pAL == NULL) + return; + ct = pAL->useCt; + av = pAL->apzArgs; + + while (--ct >= 0) { + void * p = (void *)*(av++); + optionUnloadNested((tOptionValue const *)p); + } + + AGFREE(pOD->optCookie); + + } else { + tOptionValue* pOV = optionLoadNested( + pOD->optArg.argString, pOD->pz_Name, strlen(pOD->pz_Name)); + + if (pOV != NULL) + addArgListEntry( &(pOD->optCookie), (void*)pOV ); + } +} + + +/* + * get_special_char + */ +LOCAL int +get_special_char(char const ** ppz, int * ct) +{ + char const * pz = *ppz; + + if (*ct < 3) + return '&'; + + if (*pz == '#') { + int base = 10; + int retch; + + pz++; + if (*pz == 'x') { + base = 16; + pz++; + } + retch = (int)strtoul(pz, (char **)&pz, base); + if (*pz != ';') + return '&'; + base = ++pz - *ppz; + if (base > *ct) + return '&'; + + *ct -= base; + *ppz = pz; + return retch; + } + + { + int ctr = sizeof(xml_xlate) / sizeof(xml_xlate[0]); + xml_xlate_t const * xlatp = xml_xlate; + + for (;;) { + if ( (*ct >= xlatp->xml_len) + && (strncmp(pz, xlatp->xml_txt, xlatp->xml_len) == 0)) { + *ppz += xlatp->xml_len; + *ct -= xlatp->xml_len; + return xlatp->xml_ch; + } + + if (--ctr <= 0) + break; + xlatp++; + } + } + return '&'; +} + + +/* + * emit_special_char + */ +LOCAL void +emit_special_char(FILE * fp, int ch) { - tOptionValue* pOV = optionLoadNested( - pOD->optArg.argString, pOD->pz_Name, strlen(pOD->pz_Name)); + int ctr = sizeof(xml_xlate) / sizeof(xml_xlate[0]); + xml_xlate_t const * xlatp = xml_xlate; - if (pOV != NULL) - addArgListEntry( &(pOD->optCookie), (void*)pOV ); + putc('&', fp); + for (;;) { + if (ch == xlatp->xml_ch) { + fputs(xlatp->xml_txt, fp); + return; + } + if (--ctr <= 0) + break; + xlatp++; + } + fprintf(fp, "#x%02X;", (ch & 0xFF)); } + /* * Local Variables: * mode: C diff -urN src/contrib/ntp/libopts/numeric.c src.ntp/contrib/ntp/libopts/numeric.c --- src/contrib/ntp/libopts/numeric.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/numeric.c 2009-12-09 08:36:37.000000000 +0100 @@ -1,56 +1,108 @@ /* - * $Id: numeric.c,v 4.11 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-13 10:28:20 bkorb" + * $Id: 52d772d69bed7f2911d88ff17b9a44308d6ca0b1 $ + * Time-stamp: "2009-07-23 17:25:39 bkorb" + * + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ -/* - * Automated Options copyright 1992-2007 Bruce Korb +/*=export_func optionShowRange + * private: * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ + * what: + * arg: + tOptions* + pOpts + program options descriptor + + * arg: + tOptDesc* + pOptDesc + the descriptor for this arg + + * arg: + void * + rng_table + the value range tables + + * arg: + int + rng_count + the number of entries + + * + * doc: + * Show information about a numeric option with range constraints. +=*/ +void +optionShowRange(tOptions* pOpts, tOptDesc* pOD, void * rng_table, int rng_ct) +{ + static char const bullet[] = "\t\t\t\t- "; + static char const deepin[] = "\t\t\t\t "; + static char const onetab[] = "\t"; + + const struct {long const rmin, rmax;} * rng = rng_table; + + char const * pz_indent = + (pOpts != OPTPROC_EMIT_USAGE) ? onetab : bullet; + + if ((pOpts == OPTPROC_EMIT_USAGE) || (pOpts > OPTPROC_EMIT_LIMIT)) { + char const * lie_in_range = zRangeLie; + + if (pOpts > OPTPROC_EMIT_LIMIT) { + fprintf(option_usage_fp, zRangeErr, + pOpts->pzProgName, pOD->pz_Name, pOD->optArg.argString); + fprintf(option_usage_fp, "The %s option:\n", pOD->pz_Name); + lie_in_range = zRangeBadLie; + pz_indent = ""; + } + + if (pOD->fOptState & OPTST_SCALED_NUM) + fprintf(option_usage_fp, zRangeScaled, pz_indent); + + if (rng_ct > 1) { + fprintf(option_usage_fp, lie_in_range, pz_indent); + pz_indent = + (pOpts != OPTPROC_EMIT_USAGE) ? onetab : deepin; + + } else { + fprintf(option_usage_fp, zRangeOnly, pz_indent); + pz_indent = onetab + 1; /* empty string */ + } + + for (;;) { + if (rng->rmax == LONG_MIN) + fprintf(option_usage_fp, zRangeExact, pz_indent, rng->rmin); + else if (rng->rmin == LONG_MIN) + fprintf(option_usage_fp, zRangeUpto, pz_indent, rng->rmax); + else if (rng->rmax == LONG_MAX) + fprintf(option_usage_fp, zRangeAbove, pz_indent, rng->rmin); + else + fprintf(option_usage_fp, zRange, pz_indent, rng->rmin, + rng->rmax); + + if (--rng_ct <= 0) { + fputc('\n', option_usage_fp); + break; + } + fputs(zRangeOr, option_usage_fp); + rng++; + pz_indent = + (pOpts != OPTPROC_EMIT_USAGE) ? onetab : deepin; + } + + if (pOpts > OPTPROC_EMIT_LIMIT) + pOpts->pUsageProc(pOpts, EXIT_FAILURE); + } +} + /*=export_func optionNumericVal * private: * - * what: Decipher a boolean value + * what: process an option with a numeric value. * arg: + tOptions* + pOpts + program options descriptor + * arg: + tOptDesc* + pOptDesc + the descriptor for this arg + * @@ -58,7 +110,7 @@ * Decipher a numeric value. =*/ void -optionNumericVal( tOptions* pOpts, tOptDesc* pOD ) +optionNumericVal(tOptions* pOpts, tOptDesc* pOD ) { char* pz; long val; @@ -66,16 +118,37 @@ /* * Numeric options may have a range associated with it. * If it does, the usage procedure requests that it be - * emitted by passing a NULL pOD pointer. + * emitted by passing a NULL pOD pointer. Also bail out + * if there is no option argument or if we are being reset. */ - if ((pOD == NULL) || (pOD->optArg.argString == NULL)) + if ( (pOD == NULL) + || (pOD->optArg.argString == NULL) + || ((pOD->fOptState & OPTST_RESET) != 0)) return; - val = strtol( pOD->optArg.argString, &pz, 0 ); - if (*pz != NUL) { - fprintf( stderr, zNotNumber, pOpts->pzProgName, pOD->optArg.argString ); - (*(pOpts->pUsageProc))(pOpts, EXIT_FAILURE); - } + errno = 0; + val = strtol(pOD->optArg.argString, &pz, 0); + if ((pz == pOD->optArg.argString) || (errno != 0)) + goto bad_number; + + if ((pOD->fOptState & OPTST_SCALED_NUM) != 0) + switch (*(pz++)) { + case '\0': pz--; break; + case 't': val *= 1000; + case 'g': val *= 1000; + case 'm': val *= 1000; + case 'k': val *= 1000; break; + + case 'T': val *= 1024; + case 'G': val *= 1024; + case 'M': val *= 1024; + case 'K': val *= 1024; break; + + default: goto bad_number; + } + + if (*pz != NUL) + goto bad_number; if (pOD->fOptState & OPTST_ALLOC_ARG) { AGFREE(pOD->optArg.argString); @@ -83,7 +156,17 @@ } pOD->optArg.argInt = val; + return; + + bad_number: + + fprintf( stderr, zNotNumber, pOpts->pzProgName, pOD->optArg.argString ); + if ((pOpts->fOptSet & OPTPROC_ERRSTOP) != 0) + (*(pOpts->pUsageProc))(pOpts, EXIT_FAILURE); + + pOD->optArg.argInt = ~0; } + /* * Local Variables: * mode: C diff -urN src/contrib/ntp/libopts/parse-duration.c src.ntp/contrib/ntp/libopts/parse-duration.c --- src/contrib/ntp/libopts/parse-duration.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/libopts/parse-duration.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,582 @@ +/* Parse a time duration and return a seconds count + Copyright (C) 2008 Free Software Foundation, Inc. + Written by Bruce Korb , 2008. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . */ + +#include + +#include +#include +#include +#include +#include +#include + +#include "parse-duration.h" + +#ifndef _ +#define _(_s) _s +#endif + +#ifndef NUL +#define NUL '\0' +#endif + +#define cch_t char const + +typedef enum { + NOTHING_IS_DONE, + YEAR_IS_DONE, + MONTH_IS_DONE, + WEEK_IS_DONE, + DAY_IS_DONE, + HOUR_IS_DONE, + MINUTE_IS_DONE, + SECOND_IS_DONE +} whats_done_t; + +#define SEC_PER_MIN 60 +#define SEC_PER_HR (SEC_PER_MIN * 60) +#define SEC_PER_DAY (SEC_PER_HR * 24) +#define SEC_PER_WEEK (SEC_PER_DAY * 7) +#define SEC_PER_MONTH (SEC_PER_DAY * 30) +#define SEC_PER_YEAR (SEC_PER_DAY * 365) + +#define TIME_MAX 0x7FFFFFFF + +static unsigned long inline +str_const_to_ul (cch_t * str, cch_t ** ppz, int base) +{ + return strtoul (str, (char **)ppz, base); +} + +static long inline +str_const_to_l (cch_t * str, cch_t ** ppz, int base) +{ + return strtol (str, (char **)ppz, base); +} + +static time_t inline +scale_n_add (time_t base, time_t val, int scale) +{ + if (base == BAD_TIME) + { + if (errno == 0) + errno = EINVAL; + return BAD_TIME; + } + + if (val > TIME_MAX / scale) + { + errno = ERANGE; + return BAD_TIME; + } + + val *= scale; + if (base > TIME_MAX - val) + { + errno = ERANGE; + return BAD_TIME; + } + + return base + val; +} + +static time_t +parse_hr_min_sec (time_t start, cch_t * pz) +{ + int lpct = 0; + + errno = 0; + + /* For as long as our scanner pointer points to a colon *AND* + we've not looped before, then keep looping. (two iterations max) */ + while ((*pz == ':') && (lpct++ <= 1)) + { + unsigned long v = str_const_to_ul (pz+1, &pz, 10); + + if (errno != 0) + return BAD_TIME; + + start = scale_n_add (v, start, 60); + + if (errno != 0) + return BAD_TIME; + } + + /* allow for trailing spaces */ + while (isspace ((unsigned char)*pz)) pz++; + if (*pz != NUL) + { + errno = EINVAL; + return BAD_TIME; + } + + return start; +} + +static time_t +parse_scaled_value (time_t base, cch_t ** ppz, cch_t * endp, int scale) +{ + cch_t * pz = *ppz; + time_t val; + + if (base == BAD_TIME) + return base; + + errno = 0; + val = str_const_to_ul (pz, &pz, 10); + if (errno != 0) + return BAD_TIME; + while (isspace ((unsigned char)*pz)) pz++; + if (pz != endp) + { + errno = EINVAL; + return BAD_TIME; + } + + *ppz = pz; + return scale_n_add (base, val, scale); +} + +static time_t +parse_year_month_day (cch_t * pz, cch_t * ps) +{ + time_t res = 0; + + res = parse_scaled_value (0, &pz, ps, SEC_PER_YEAR); + + ps = strchr (++pz, '-'); + if (ps == NULL) + { + errno = EINVAL; + return BAD_TIME; + } + res = parse_scaled_value (res, &pz, ps, SEC_PER_MONTH); + + pz++; + ps = pz + strlen (pz); + return parse_scaled_value (res, &pz, ps, SEC_PER_DAY); +} + +static time_t +parse_yearmonthday (cch_t * in_pz) +{ + time_t res = 0; + char buf[8]; + cch_t * pz; + + if (strlen (in_pz) != 8) + { + errno = EINVAL; + return BAD_TIME; + } + + memcpy (buf, in_pz, 4); + buf[4] = NUL; + pz = buf; + res = parse_scaled_value (0, &pz, buf + 4, SEC_PER_YEAR); + + memcpy (buf, in_pz + 4, 2); + buf[2] = NUL; + pz = buf; + res = parse_scaled_value (res, &pz, buf + 2, SEC_PER_MONTH); + + memcpy (buf, in_pz + 6, 2); + buf[2] = NUL; + pz = buf; + return parse_scaled_value (res, &pz, buf + 2, SEC_PER_DAY); +} + +static time_t +parse_YMWD (cch_t * pz) +{ + time_t res = 0; + cch_t * ps = strchr (pz, 'Y'); + if (ps != NULL) + { + res = parse_scaled_value (0, &pz, ps, SEC_PER_YEAR); + pz++; + } + + ps = strchr (pz, 'M'); + if (ps != NULL) + { + res = parse_scaled_value (res, &pz, ps, SEC_PER_MONTH); + pz++; + } + + ps = strchr (pz, 'W'); + if (ps != NULL) + { + res = parse_scaled_value (res, &pz, ps, SEC_PER_WEEK); + pz++; + } + + ps = strchr (pz, 'D'); + if (ps != NULL) + { + res = parse_scaled_value (res, &pz, ps, SEC_PER_DAY); + pz++; + } + + while (isspace ((unsigned char)*pz)) pz++; + if (*pz != NUL) + { + errno = EINVAL; + return BAD_TIME; + } + + return res; +} + +static time_t +parse_hour_minute_second (cch_t * pz, cch_t * ps) +{ + time_t res = 0; + + res = parse_scaled_value (0, &pz, ps, SEC_PER_HR); + + ps = strchr (++pz, ':'); + if (ps == NULL) + { + errno = EINVAL; + return BAD_TIME; + } + + res = parse_scaled_value (res, &pz, ps, SEC_PER_MIN); + + pz++; + ps = pz + strlen (pz); + return parse_scaled_value (res, &pz, ps, 1); +} + +static time_t +parse_hourminutesecond (cch_t * in_pz) +{ + time_t res = 0; + char buf[4]; + cch_t * pz; + + if (strlen (in_pz) != 6) + { + errno = EINVAL; + return BAD_TIME; + } + + memcpy (buf, in_pz, 2); + buf[2] = NUL; + pz = buf; + res = parse_scaled_value (0, &pz, buf + 2, SEC_PER_HR); + + memcpy (buf, in_pz + 2, 2); + buf[2] = NUL; + pz = buf; + res = parse_scaled_value (res, &pz, buf + 2, SEC_PER_MIN); + + memcpy (buf, in_pz + 4, 2); + buf[2] = NUL; + pz = buf; + return parse_scaled_value (res, &pz, buf + 2, 1); +} + +static time_t +parse_HMS (cch_t * pz) +{ + time_t res = 0; + cch_t * ps = strchr (pz, 'H'); + if (ps != NULL) + { + res = parse_scaled_value (0, &pz, ps, SEC_PER_HR); + pz++; + } + + ps = strchr (pz, 'M'); + if (ps != NULL) + { + res = parse_scaled_value (res, &pz, ps, SEC_PER_MIN); + pz++; + } + + ps = strchr (pz, 'S'); + if (ps != NULL) + { + res = parse_scaled_value (res, &pz, ps, 1); + pz++; + } + + while (isspace ((unsigned char)*pz)) pz++; + if (*pz != NUL) + { + errno = EINVAL; + return BAD_TIME; + } + + return res; +} + +static time_t +parse_time (cch_t * pz) +{ + cch_t * ps; + time_t res = 0; + + /* + * Scan for a hyphen + */ + ps = strchr (pz, ':'); + if (ps != NULL) + { + res = parse_hour_minute_second (pz, ps); + } + + /* + * Try for a 'H', 'M' or 'S' suffix + */ + else if (ps = strpbrk (pz, "HMS"), + ps == NULL) + { + /* Its a YYYYMMDD format: */ + res = parse_hourminutesecond (pz); + } + + else + res = parse_HMS (pz); + + return res; +} + +static char * +trim(char * pz) +{ + /* trim leading white space */ + while (isspace ((unsigned char)*pz)) pz++; + + /* trim trailing white space */ + { + char * pe = pz + strlen (pz); + while ((pe > pz) && isspace ((unsigned char)pe[-1])) pe--; + *pe = NUL; + } + + return pz; +} + +/* + * Parse the year/months/days of a time period + */ +static time_t +parse_period (cch_t * in_pz) +{ + char * pz = xstrdup (in_pz); + char * pT = strchr (pz, 'T'); + char * ps; + void * fptr = pz; + time_t res = 0; + + if (pT != NUL) + { + *(pT++) = NUL; + pz = trim (pz); + pT = trim (pT); + } + + /* + * Scan for a hyphen + */ + ps = strchr (pz, '-'); + if (ps != NULL) + { + res = parse_year_month_day (pz, ps); + } + + /* + * Try for a 'Y', 'M' or 'D' suffix + */ + else if (ps = strpbrk (pz, "YMWD"), + ps == NULL) + { + /* Its a YYYYMMDD format: */ + res = parse_yearmonthday (pz); + } + + else + res = parse_YMWD (pz); + + if ((errno == 0) && (pT != NULL)) + { + time_t val = parse_time (pT); + res = scale_n_add (res, val, 1); + } + + free (fptr); + return res; +} + +static time_t +parse_non_iso8601(cch_t * pz) +{ + whats_done_t whatd_we_do = NOTHING_IS_DONE; + + time_t res = 0; + + do { + time_t val; + + errno = 0; + val = str_const_to_l (pz, &pz, 10); + if (errno != 0) + goto bad_time; + + /* IF we find a colon, then we're going to have a seconds value. + We will not loop here any more. We cannot already have parsed + a minute value and if we've parsed an hour value, then the result + value has to be less than an hour. */ + if (*pz == ':') + { + if (whatd_we_do >= MINUTE_IS_DONE) + break; + + val = parse_hr_min_sec (val, pz); + + if ((whatd_we_do == HOUR_IS_DONE) && (val >= SEC_PER_HR)) + break; + + return scale_n_add (res, val, 1); + } + + { + unsigned int mult; + + /* Skip over white space following the number we just parsed. */ + while (isspace ((unsigned char)*pz)) pz++; + + switch (*pz) + { + default: goto bad_time; + case NUL: + return scale_n_add (res, val, 1); + + case 'y': case 'Y': + if (whatd_we_do >= YEAR_IS_DONE) + goto bad_time; + mult = SEC_PER_YEAR; + whatd_we_do = YEAR_IS_DONE; + break; + + case 'M': + if (whatd_we_do >= MONTH_IS_DONE) + goto bad_time; + mult = SEC_PER_MONTH; + whatd_we_do = MONTH_IS_DONE; + break; + + case 'W': + if (whatd_we_do >= WEEK_IS_DONE) + goto bad_time; + mult = SEC_PER_WEEK; + whatd_we_do = WEEK_IS_DONE; + break; + + case 'd': case 'D': + if (whatd_we_do >= DAY_IS_DONE) + goto bad_time; + mult = SEC_PER_DAY; + whatd_we_do = DAY_IS_DONE; + break; + + case 'h': + if (whatd_we_do >= HOUR_IS_DONE) + goto bad_time; + mult = SEC_PER_HR; + whatd_we_do = HOUR_IS_DONE; + break; + + case 'm': + if (whatd_we_do >= MINUTE_IS_DONE) + goto bad_time; + mult = SEC_PER_MIN; + whatd_we_do = MINUTE_IS_DONE; + break; + + case 's': + mult = 1; + whatd_we_do = SECOND_IS_DONE; + break; + } + + res = scale_n_add (res, val, mult); + + while (isspace ((unsigned char)*++pz)) ; + if (*pz == NUL) + return res; + + if (! isdigit ((unsigned char)*pz)) + break; + } + + } while (whatd_we_do < SECOND_IS_DONE); + + bad_time: + errno = EINVAL; + return BAD_TIME; +} + +time_t +parse_duration (char const * pz) +{ + time_t res = 0; + + while (isspace ((unsigned char)*pz)) pz++; + + do { + if (*pz == 'P') + { + res = parse_period (pz + 1); + if ((errno != 0) || (res == BAD_TIME)) + break; + return res; + } + + if (*pz == 'T') + { + res = parse_time (pz + 1); + if ((errno != 0) || (res == BAD_TIME)) + break; + return res; + } + + if (! isdigit ((unsigned char)*pz)) + break; + + res = parse_non_iso8601 (pz); + if ((errno == 0) && (res != BAD_TIME)) + return res; + + } while (0); + + fprintf (stderr, _("Invalid time duration: %s\n"), pz); + if (errno == 0) + errno = EINVAL; + return BAD_TIME; +} + +/* + * Local Variables: + * mode: C + * c-file-style: "gnu" + * indent-tabs-mode: nil + * End: + * end of parse-duration.c */ diff -urN src/contrib/ntp/libopts/parse-duration.h src.ntp/contrib/ntp/libopts/parse-duration.h --- src/contrib/ntp/libopts/parse-duration.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/libopts/parse-duration.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,82 @@ +/* Parse a time duration and return a seconds count + Copyright (C) 2008 Free Software Foundation, Inc. + Written by Bruce Korb , 2008. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . */ + +/* + + Readers and users of this function are referred to the ISO-8601 + specification, with particular attention to "Durations". + + At the time of writing, this worked: + + http://en.wikipedia.org/wiki/ISO_8601#Durations + + The string must start with a 'P', 'T' or a digit. + + ==== if it is a digit + + the string may contain: NNN d NNN h NNN m NNN s + This represents NNN days, NNN hours, NNN minutes and NNN seconds. + The embeded white space is optional. + These terms must appear in this order. + The final "s" is optional. + All of the terms ("NNN" plus designator) are optional. + Minutes and seconds may optionally be represented as NNN:NNN. + Also, hours, minute and seconds may be represented as NNN:NNN:NNN. + There is no limitation on the value of any of the terms, except + that the final result must fit in a time_t value. + + ==== if it is a 'P' or 'T', please see ISO-8601 for a rigorous definition. + + The 'P' term may be followed by any of three formats: + yyyymmdd + yy-mm-dd + yy Y mm M ww W dd D + + or it may be empty and followed by a 'T'. The "yyyymmdd" must be eight + digits long. Note: months are always 30 days and years are always 365 + days long. 5 years is always 1825, not 1826 or 1827 depending on leap + year considerations. 3 months is always 90 days. There is no consideration + for how many days are in the current, next or previous months. + + For the final format: + * Embedded white space is allowed, but it is optional. + * All of the terms are optional. Any or all-but-one may be omitted. + * The meanings are yy years, mm months, ww weeks and dd days. + * The terms must appear in this order. + + ==== The 'T' term may be followed by any of these formats: + + hhmmss + hh:mm:ss + hh H mm M ss S + + For the final format: + * Embedded white space is allowed, but it is optional. + * All of the terms are optional. Any or all-but-one may be omitted. + * The terms must appear in this order. + + */ +#ifndef GNULIB_PARSE_DURATION_H +#define GNULIB_PARSE_DURATION_H + +#include + +#define BAD_TIME ((time_t)~0) + +extern time_t parse_duration(char const * in_pz); + +#endif /* GNULIB_PARSE_DURATION_H */ diff -urN src/contrib/ntp/libopts/pgusage.c src.ntp/contrib/ntp/libopts/pgusage.c --- src/contrib/ntp/libopts/pgusage.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/pgusage.c 2009-12-09 08:36:35.000000000 +0100 @@ -1,55 +1,32 @@ /* - * $Id: pgusage.c,v 4.12 2007/04/28 22:19:23 bkorb Exp $ - * Time-stamp: "2006-07-16 08:13:26 bkorb" + * $Id: da09fc943da953195b243b7697fdbf5127f5b6c2 $ + * Time-stamp: "2009-11-01 11:52:51 bkorb" * * Automated Options Paged Usage module. * * This routine will run run-on options through a pager so the * user may examine, print or edit them at their leisure. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ tePagerState pagerState = PAGER_STATE_INITIAL; @@ -64,11 +41,15 @@ * doc: * Run the usage output through a pager. * This is very handy if it is very long. + * This is disabled on platforms without a working fork() function. =*/ void optionPagedUsage( tOptions* pOptions, tOptDesc* pOD ) { -#if defined(__windows__) && !defined(__CYGWIN__) +#if ! defined(HAVE_WORKING_FORK) + if ((pOD->fOptState & OPTST_RESET) != 0) + return; + (*pOptions->pUsageProc)( pOptions, EXIT_SUCCESS ); #else static pid_t my_pid; @@ -82,6 +63,9 @@ switch (pagerState) { case PAGER_STATE_INITIAL: { + if ((pOD->fOptState & OPTST_RESET) != 0) + return; + my_pid = getpid(); #ifdef HAVE_SNPRINTF snprintf(zPageUsage, sizeof(zPageUsage), "/tmp/use.%lu", (tAoUL)my_pid); @@ -110,7 +94,7 @@ */ (*pOptions->pUsageProc)( pOptions, EXIT_SUCCESS ); - /*NOTREACHED*/ + /* NOTREACHED */ _exit( EXIT_FAILURE ); } diff -urN src/contrib/ntp/libopts/proto.h src.ntp/contrib/ntp/libopts/proto.h --- src/contrib/ntp/libopts/proto.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/proto.h 2009-12-09 08:36:35.000000000 +0100 @@ -1,17 +1,20 @@ /* -*- buffer-read-only: t -*- vi: set ro: * * Prototypes for autoopts - * Generated Sat May 5 12:02:36 PDT 2007 + * Generated Sun Nov 8 08:41:10 PST 2009 */ #ifndef AUTOOPTS_PROTO_H_GUARD #define AUTOOPTS_PROTO_H_GUARD 1 + #ifndef LOCAL # define LOCAL extern # define REDEF_LOCAL 1 #else # undef REDEF_LOCAL #endif -/*\n * Extracted from autoopts.c\n */ +/* + * Extracted from autoopts.c + */ LOCAL void * ao_malloc( size_t sz ); @@ -39,7 +42,9 @@ LOCAL tSuccess doRegularOpts( tOptions* pOpts ); -/*\n * Extracted from configfile.c\n */ +/* + * Extracted from configfile.c + */ LOCAL void internalFileLoad( tOptions* pOpts ); @@ -53,14 +58,18 @@ LOCAL tSuccess validateOptionsStruct( tOptions* pOpts, char const* pzProgram ); -/*\n * Extracted from environment.c\n */ +/* + * Extracted from environment.c + */ LOCAL void doPrognameEnv( tOptions* pOpts, teEnvPresetType type ); LOCAL void doEnvPresets( tOptions* pOpts, teEnvPresetType type ); -/*\n * Extracted from load.c\n */ +/* + * Extracted from load.c + */ LOCAL void mungeString( char* pzTxt, tOptionLoadMode mode ); @@ -72,15 +81,27 @@ tDirection direction, tOptionLoadMode load_mode ); -/*\n * Extracted from nested.c\n */ +/* + * Extracted from nested.c + */ LOCAL tOptionValue* optionLoadNested(char const* pzTxt, char const* pzName, size_t nameLen); -/*\n * Extracted from sort.c\n */ +LOCAL int +get_special_char(char const ** ppz, int * ct); + +LOCAL void +emit_special_char(FILE * fp, int ch); + +/* + * Extracted from sort.c + */ LOCAL void optionSort( tOptions* pOpts ); -/*\n * Extracted from stack.c\n */ +/* + * Extracted from stack.c + */ LOCAL void addArgListEntry( void** ppAL, void* entry ); diff -urN src/contrib/ntp/libopts/putshell.c src.ntp/contrib/ntp/libopts/putshell.c --- src/contrib/ntp/libopts/putshell.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/putshell.c 2009-12-09 08:36:35.000000000 +0100 @@ -1,58 +1,35 @@ /* - * $Id: putshell.c,v 4.18 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-13 10:29:39 bkorb" + * $Id: 5d14243d5d32d234f05bc8a20b1a6464716b30aa $ + * Time-stamp: "2008-07-27 12:14:38 bkorb" * * This module will interpret the options set in the tOptions * structure and print them to standard out in a fashion that * will allow them to be interpreted by the Bourne or Korn shells. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. + * These files have the following md5sums: * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static void putQuotedStr( tCC* pzStr ); /* = = = END-STATIC-FORWARD = = = */ @@ -181,7 +158,7 @@ printf( zOptNumFmt, pOpts->pzPROGNAME, pOD->pz_NAME, (int)(uintptr_t)(pOD->optCookie) ); pOD->optCookie = (void*)(uintptr_t)~0UL; - (*(pOD->pOptProc))( (tOptions*)2UL, pOD ); + (*(pOD->pOptProc))(OPTPROC_RETURN_VALNAME, pOD); /* * We are building the typeset list. The list returned starts with @@ -190,15 +167,15 @@ pz = pOD->optArg.argString + 7; while (*pz != NUL) { printf( "typeset -x -i %s_", pOD->pz_NAME ); - pz += strspn( pz, " +\t\n\f" ); + while (IS_PLUS_N_SPACE_CHAR(*pz)) pz++; + for (;;) { - int ch = *(pz++); - if (islower( ch )) fputc( toupper( ch ), stdout ); - else if (isalnum( ch )) fputc( ch, stdout ); - else if (isspace( ch ) - || (ch == '+')) goto name_done; - else if (ch == NUL) { pz--; goto name_done; } - else fputc( '_', stdout ); + int ch = *(pz++); + if (IS_LOWER_CASE_CHAR(ch)) fputc(toupper(ch), stdout); + else if (IS_UPPER_CASE_CHAR(ch)) fputc(ch, stdout); + else if (IS_PLUS_N_SPACE_CHAR(ch)) goto name_done; + else if (ch == NUL) { pz--; goto name_done; } + else fputc( '_', stdout ); } name_done:; printf( "=%1$lu # 0x%1$lX\n", (unsigned long)val ); val <<= 1; @@ -267,11 +244,19 @@ * to emit the value corresponding to the "optArg" number. */ else if (OPTST_GET_ARGTYPE(pOD->fOptState) == OPARG_TYPE_ENUMERATION) { + uintptr_t e_val = pOD->optArg.argEnum; printf( zOptValFmt, pOpts->pzPROGNAME, pOD->pz_NAME ); - fputc( '\'', stdout ); - (*(pOD->pOptProc))( (tOptions*)1UL, pOD ); - fputc( '\'', stdout ); - printf( zOptEnd, pOpts->pzPROGNAME, pOD->pz_NAME ); + + /* + * Convert value to string, print that and restore numeric value. + */ + (*(pOD->pOptProc))(OPTPROC_RETURN_VALNAME, pOD); + printf("'%s'", pOD->optArg.argString); + if (pOD->fOptState & OPTST_ALLOC_ARG) + AGFREE(pOD->optArg.argString); + pOD->optArg.argEnum = e_val; + + printf(zOptEnd, pOpts->pzPROGNAME, pOD->pz_NAME); } /* diff -urN src/contrib/ntp/libopts/reset.c src.ntp/contrib/ntp/libopts/reset.c --- src/contrib/ntp/libopts/reset.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/libopts/reset.c 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,134 @@ + +/* + * $Id: 808e536555f06924b450ab6b5a72c03b67c5b99a $ + * Time-stamp: "2009-11-01 11:45:57 bkorb" + * + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd + */ + +static void +optionReset( tOptions* pOpts, tOptDesc* pOD ) +{ + pOD->fOptState &= OPTST_PERSISTENT_MASK; + pOD->fOptState |= OPTST_RESET; + if (pOD->pOptProc != NULL) + pOD->pOptProc(pOpts, pOD); + pOD->optArg.argString = + pOpts->originalOptArgArray[ pOD->optIndex ].argString; + pOD->optCookie = pOpts->originalOptArgCookie[ pOD->optIndex ]; + pOD->fOptState &= OPTST_PERSISTENT_MASK; +} + + +static void +optionResetEverything(tOptions * pOpts) +{ + tOptDesc * pOD = pOpts->pOptDesc; + int ct = pOpts->presetOptCt; + + for (;;) { + optionReset(pOpts, pOD); + + if (--ct <= 0) + break; + pOD++; + } +} + + +/*=export_func optionResetOpt + * private: + * + * what: Reset the value of an option + * arg: + tOptions* + pOpts + program options descriptor + + * arg: + tOptDesc* + pOptDesc + the descriptor for this arg + + * + * doc: + * This code will cause another option to be reset to its initial state. + * For example, --reset=foo will cause the --foo option to be reset. +=*/ +void +optionResetOpt( tOptions* pOpts, tOptDesc* pOD ) +{ + static ag_bool reset_active = AG_FALSE; + + tOptState opt_state = OPTSTATE_INITIALIZER(DEFINED); + char const * pzArg = pOD->optArg.argString; + tSuccess succ; + + if (reset_active) + return; + + if ( (! HAS_originalOptArgArray(pOpts)) + || (pOpts->originalOptArgCookie == NULL)) { + fputs(zResetNotConfig, stderr); + _exit(EX_SOFTWARE); + } + + if ((pzArg == NULL) || (*pzArg == NUL)) { + fputs(zNoResetArg, stderr); + pOpts->pUsageProc(pOpts, EXIT_FAILURE); + /* NOTREACHED */ + assert(0 == 1); + } + + reset_active = AG_TRUE; + + if (pzArg[1] == NUL) { + if (*pzArg == '*') { + optionResetEverything(pOpts); + reset_active = AG_FALSE; + return; + } + + succ = shortOptionFind(pOpts, (tAoUC)*pzArg, &opt_state); + if (! SUCCESSFUL(succ)) { + fprintf(stderr, zIllOptChr, pOpts->pzProgPath, *pzArg); + pOpts->pUsageProc(pOpts, EXIT_FAILURE); + /* NOTREACHED */ + assert(0 == 1); + } + } else { + succ = longOptionFind(pOpts, (char *)pzArg, &opt_state); + if (! SUCCESSFUL(succ)) { + fprintf(stderr, zIllOptStr, pOpts->pzProgPath, pzArg); + pOpts->pUsageProc(pOpts, EXIT_FAILURE); + /* NOTREACHED */ + assert(0 == 1); + } + } + + /* + * We've found the indicated option. Turn off all non-persistent + * flags because we're forcing the option back to its initialized state. + * Call any callout procedure to handle whatever it needs to. + * Finally, clear the reset flag, too. + */ + optionReset(pOpts, opt_state.pOD); + reset_active = AG_FALSE; +} +/* + * Local Variables: + * mode: C + * c-file-style: "stroustrup" + * indent-tabs-mode: nil + * End: + * end of autoopts/reset.c */ diff -urN src/contrib/ntp/libopts/restore.c src.ntp/contrib/ntp/libopts/restore.c --- src/contrib/ntp/libopts/restore.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/restore.c 2009-12-09 08:36:36.000000000 +0100 @@ -1,54 +1,31 @@ /* - * restore.c $Id: restore.c,v 4.10 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-13 14:13:17 bkorb" + * restore.c $Id: 6f5237ba2586755d8ca354f325fc00e7fa1395ec $ + * Time-stamp: "2007-07-04 11:34:40 bkorb" * * This module's routines will save the current option state to memory * and restore it. If saved prior to the initial optionProcess call, * then the initial state will be restored. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ /* diff -urN src/contrib/ntp/libopts/save.c src.ntp/contrib/ntp/libopts/save.c --- src/contrib/ntp/libopts/save.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/save.c 2009-12-09 08:36:35.000000000 +0100 @@ -1,60 +1,38 @@ /* - * save.c $Id: save.c,v 4.18 2007/04/15 19:01:18 bkorb Exp $ - * Time-stamp: "2007-04-15 11:11:10 bkorb" + * save.c $Id: 5a69234fab4c2d8d7eaf4aed4dbb3052ce6be5b6 $ + * Time-stamp: "2009-07-20 20:40:28 bkorb" * * This module's routines will take the currently set options and * store them into an ".rc" file for re-interpretation the next * time the invoking program is run. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ -tSCC zWarn[] = "%s WARNING: cannot save options - "; +static char const zWarn[] = "%s WARNING: cannot save options - "; +static char const close_xml[] = "\n"; /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static tCC* findDirName( tOptions* pOpts, int* p_free ); @@ -66,6 +44,36 @@ FILE * fp, tOptDesc * p, tCC* pzLA ); + +static void +print_a_value(FILE * fp, int depth, tOptDesc * pOD, tOptionValue const * ovp); + +static void +print_a_string(FILE * fp, char const * name, char const * pz); + +static void +printValueList(FILE * fp, char const * name, tArgList * al); + +static void +printHierarchy(FILE * fp, tOptDesc * p); + +static FILE * +openSaveFile( tOptions* pOpts ); + +static void +printNoArgOpt(FILE * fp, tOptDesc * p, tOptDesc * pOD); + +static void +printStringArg(FILE * fp, tOptDesc * pOD); + +static void +printEnumArg(FILE * fp, tOptDesc * pOD); + +static void +printSetMemberArg(FILE * fp, tOptDesc * pOD); + +static void +printFileArg(FILE * fp, tOptDesc * pOD, tOptions* pOpts); /* = = = END-STATIC-FORWARD = = = */ static tCC* @@ -73,7 +81,8 @@ { tCC* pzDir; - if (pOpts->specOptIdx.save_opts == 0) + if ( (pOpts->specOptIdx.save_opts == NO_EQUIVALENT) + || (pOpts->specOptIdx.save_opts == 0)) return NULL; pzDir = pOpts->pOptDesc[ pOpts->specOptIdx.save_opts ].optArg.argString; @@ -331,39 +340,194 @@ } -/*=export_func optionSaveFile - * - * what: saves the option state to a file - * - * arg: tOptions*, pOpts, program options descriptor - * - * doc: - * - * This routine will save the state of option processing to a file. The name - * of that file can be specified with the argument to the @code{--save-opts} - * option, or by appending the @code{rcfile} attribute to the last - * @code{homerc} attribute. If no @code{rcfile} attribute was specified, it - * will default to @code{.@i{programname}rc}. If you wish to specify another - * file, you should invoke the @code{SET_OPT_SAVE_OPTS( @i{filename} )} macro. - * - * err: - * - * If no @code{homerc} file was specified, this routine will silently return - * and do nothing. If the output file cannot be created or updated, a message - * will be printed to @code{stderr} and the routine will return. -=*/ -void -optionSaveFile( tOptions* pOpts ) +static void +print_a_value(FILE * fp, int depth, tOptDesc * pOD, tOptionValue const * ovp) +{ + static char const bool_atr[] = "<%1$s type=boolean>%2$s\n"; + static char const numb_atr[] = "<%1$s type=integer>0x%2$lX\n"; + static char const type_atr[] = "<%s type=%s>"; + static char const null_atr[] = "<%s/>\n"; + + while (--depth >= 0) + putc(' ', fp), putc(' ', fp); + + switch (ovp->valType) { + default: + case OPARG_TYPE_NONE: + fprintf(fp, null_atr, ovp->pzName); + break; + + case OPARG_TYPE_STRING: + print_a_string(fp, ovp->pzName, ovp->v.strVal); + break; + + case OPARG_TYPE_ENUMERATION: + case OPARG_TYPE_MEMBERSHIP: + if (pOD != NULL) { + tAoUI opt_state = pOD->fOptState; + uintptr_t val = pOD->optArg.argEnum; + char const * typ = (ovp->valType == OPARG_TYPE_ENUMERATION) + ? "keyword" : "set-membership"; + + fprintf(fp, type_atr, ovp->pzName, typ); + + /* + * This is a magic incantation that will convert the + * bit flag values back into a string suitable for printing. + */ + (*(pOD->pOptProc))(OPTPROC_RETURN_VALNAME, pOD ); + if (pOD->optArg.argString != NULL) { + fputs(pOD->optArg.argString, fp); + + if (ovp->valType != OPARG_TYPE_ENUMERATION) { + /* + * set membership strings get allocated + */ + AGFREE( (void*)pOD->optArg.argString ); + } + } + + pOD->optArg.argEnum = val; + pOD->fOptState = opt_state; + fprintf(fp, close_xml, ovp->pzName); + break; + } + /* FALLTHROUGH */ + + case OPARG_TYPE_NUMERIC: + fprintf(fp, numb_atr, ovp->pzName, ovp->v.longVal); + break; + + case OPARG_TYPE_BOOLEAN: + fprintf(fp, bool_atr, ovp->pzName, + ovp->v.boolVal ? "true" : "false"); + break; + + case OPARG_TYPE_HIERARCHY: + printValueList(fp, ovp->pzName, ovp->v.nestVal); + break; + } +} + + +static void +print_a_string(FILE * fp, char const * name, char const * pz) +{ + static char const open_atr[] = "<%s>"; + + fprintf(fp, open_atr, name); + for (;;) { + int ch = ((int)*(pz++)) & 0xFF; + + switch (ch) { + case NUL: goto string_done; + + case '&': + case '<': + case '>': +#if __GNUC__ >= 4 + case 1 ... (' ' - 1): + case ('~' + 1) ... 0xFF: +#endif + emit_special_char(fp, ch); + break; + + default: +#if __GNUC__ < 4 + if ( ((ch >= 1) && (ch <= (' ' - 1))) + || ((ch >= ('~' + 1)) && (ch <= 0xFF)) ) { + emit_special_char(fp, ch); + break; + } +#endif + putc(ch, fp); + } + } string_done:; + fprintf(fp, close_xml, name); +} + + +static void +printValueList(FILE * fp, char const * name, tArgList * al) +{ + static int depth = 1; + + int sp_ct; + int opt_ct; + void ** opt_list; + + if (al == NULL) + return; + opt_ct = al->useCt; + opt_list = (void **)al->apzArgs; + + if (opt_ct <= 0) { + fprintf(fp, "<%s/>\n", name); + return; + } + + fprintf(fp, "<%s type=nested>\n", name); + + depth++; + while (--opt_ct >= 0) { + tOptionValue const * ovp = *(opt_list++); + + print_a_value(fp, depth, NULL, ovp); + } + depth--; + + for (sp_ct = depth; --sp_ct >= 0;) + putc(' ', fp), putc(' ', fp); + fprintf(fp, "\n", name); +} + + +static void +printHierarchy(FILE * fp, tOptDesc * p) +{ + int opt_ct; + tArgList * al = p->optCookie; + void ** opt_list; + + if (al == NULL) + return; + + opt_ct = al->useCt; + opt_list = (void **)al->apzArgs; + + if (opt_ct <= 0) + return; + + do { + tOptionValue const * base = *(opt_list++); + tOptionValue const * ovp = optionGetValue(base, NULL); + + if (ovp == NULL) + continue; + + fprintf(fp, "<%s type=nested>\n", p->pz_Name); + + do { + print_a_value(fp, 1, p, ovp); + + } while (ovp = optionNextValue(base, ovp), + ovp != NULL); + + fprintf(fp, "\n", p->pz_Name); + } while (--opt_ct > 0); +} + + +static FILE * +openSaveFile( tOptions* pOpts ) { - tOptDesc* pOD; - int ct; FILE* fp; { int free_name = 0; tCC* pzFName = findFileName( pOpts, &free_name ); if (pzFName == NULL) - return; + return NULL; fp = fopen( pzFName, "w" FOPEN_BINARY_FLAG ); if (fp == NULL) { @@ -371,7 +535,7 @@ fprintf( stderr, zNoCreat, errno, strerror( errno ), pzFName ); if (free_name) AGFREE((void*) pzFName ); - return; + return fp; } if (free_name) @@ -399,13 +563,156 @@ #endif } + return fp; +} + +static void +printNoArgOpt(FILE * fp, tOptDesc * p, tOptDesc * pOD) +{ + /* + * The aliased to argument indicates whether or not the option + * is "disabled". However, the original option has the name + * string, so we get that there, not with "p". + */ + char const * pznm = + (DISABLED_OPT( p )) ? pOD->pz_DisableName : pOD->pz_Name; + /* + * If the option was disabled and the disablement name is NULL, + * then the disablement was caused by aliasing. + * Use the name as the string to emit. + */ + if (pznm == NULL) + pznm = pOD->pz_Name; + + fprintf(fp, "%s\n", pznm); +} + +static void +printStringArg(FILE * fp, tOptDesc * pOD) +{ + if (pOD->fOptState & OPTST_STACKED) { + tArgList* pAL = (tArgList*)pOD->optCookie; + int uct = pAL->useCt; + tCC** ppz = pAL->apzArgs; + + /* + * un-disable multiple copies of disabled options. + */ + if (uct > 1) + pOD->fOptState &= ~OPTST_DISABLED; + + while (uct-- > 0) + printEntry( fp, pOD, *(ppz++) ); + } else { + printEntry( fp, pOD, pOD->optArg.argString ); + } +} + +static void +printEnumArg(FILE * fp, tOptDesc * pOD) +{ + uintptr_t val = pOD->optArg.argEnum; + + /* + * This is a magic incantation that will convert the + * bit flag values back into a string suitable for printing. + */ + (*(pOD->pOptProc))(OPTPROC_RETURN_VALNAME, pOD); + printEntry( fp, pOD, (void*)(pOD->optArg.argString)); + + pOD->optArg.argEnum = val; +} + +static void +printSetMemberArg(FILE * fp, tOptDesc * pOD) +{ + uintptr_t val = pOD->optArg.argEnum; + + /* + * This is a magic incantation that will convert the + * bit flag values back into a string suitable for printing. + */ + (*(pOD->pOptProc))(OPTPROC_RETURN_VALNAME, pOD); + printEntry( fp, pOD, (void*)(pOD->optArg.argString)); + + if (pOD->optArg.argString != NULL) { + /* + * set membership strings get allocated + */ + AGFREE( (void*)pOD->optArg.argString ); + pOD->fOptState &= ~OPTST_ALLOC_ARG; + } + + pOD->optArg.argEnum = val; +} + +static void +printFileArg(FILE * fp, tOptDesc * pOD, tOptions* pOpts) +{ + /* + * If the cookie is not NULL, then it has the file name, period. + * Otherwise, if we have a non-NULL string argument, then.... + */ + if (pOD->optCookie != NULL) + printEntry(fp, pOD, pOD->optCookie); + + else if (HAS_originalOptArgArray(pOpts)) { + char const * orig = + pOpts->originalOptArgArray[pOD->optIndex].argString; + + if (pOD->optArg.argString == orig) + return; + + printEntry(fp, pOD, pOD->optArg.argString); + } +} + + +/*=export_func optionSaveFile + * + * what: saves the option state to a file + * + * arg: tOptions*, pOpts, program options descriptor + * + * doc: + * + * This routine will save the state of option processing to a file. The name + * of that file can be specified with the argument to the @code{--save-opts} + * option, or by appending the @code{rcfile} attribute to the last + * @code{homerc} attribute. If no @code{rcfile} attribute was specified, it + * will default to @code{.@i{programname}rc}. If you wish to specify another + * file, you should invoke the @code{SET_OPT_SAVE_OPTS( @i{filename} )} macro. + * + * The recommend usage is as follows: + * @example + * optionProcess(&progOptions, argc, argv); + * if (i_want_a_non_standard_place_for_this) + * SET_OPT_SAVE_OPTS("myfilename"); + * optionSaveFile(&progOptions); + * @end example + * + * err: + * + * If no @code{homerc} file was specified, this routine will silently return + * and do nothing. If the output file cannot be created or updated, a message + * will be printed to @code{stderr} and the routine will return. +=*/ +void +optionSaveFile( tOptions* pOpts ) +{ + tOptDesc* pOD; + int ct; + FILE* fp = openSaveFile(pOpts); + + if (fp == NULL) + return; + /* * FOR each of the defined options, ... */ ct = pOpts->presetOptCt; pOD = pOpts->pOptDesc; do { - int arg_state; tOptDesc* p; /* @@ -413,98 +720,61 @@ * OR it does not take an initialization value * OR it is equivalenced to another option * THEN continue (ignore it) + * + * Equivalenced options get picked up when the equivalenced-to + * option is processed. */ if (UNUSED_OPT( pOD )) continue; - if ((pOD->fOptState & (OPTST_NO_INIT|OPTST_DOCUMENT|OPTST_OMITTED)) - != 0) + if ((pOD->fOptState & OPTST_DO_NOT_SAVE_MASK) != 0) continue; if ( (pOD->optEquivIndex != NO_EQUIVALENT) - && (pOD->optEquivIndex != pOD->optIndex)) + && (pOD->optEquivIndex != pOD->optIndex)) continue; /* - * Set a temporary pointer to the real option description - * (i.e. account for equivalencing) + * The option argument data are found at the equivalenced-to option, + * but the actual option argument type comes from the original + * option descriptor. Be careful! */ p = ((pOD->fOptState & OPTST_EQUIVALENCE) != 0) ? (pOpts->pOptDesc + pOD->optActualIndex) : pOD; - /* - * IF no arguments are allowed - * THEN just print the name and continue - */ - if (OPTST_GET_ARGTYPE(pOD->fOptState) == OPARG_TYPE_NONE) { - char const * pznm = - (DISABLED_OPT( p )) ? p->pz_DisableName : p->pz_Name; - /* - * If the option was disabled and the disablement name is NULL, - * then the disablement was caused by aliasing. - * Use the name as the string to emit. - */ - if (pznm == NULL) - pznm = p->pz_Name; - - fprintf(fp, "%s\n", pznm); - continue; - } + switch (OPTST_GET_ARGTYPE(pOD->fOptState)) { + case OPARG_TYPE_NONE: + printNoArgOpt(fp, p, pOD); + break; - arg_state = OPTST_GET_ARGTYPE(p->fOptState); - switch (arg_state) { - case 0: case OPARG_TYPE_NUMERIC: printEntry( fp, p, (void*)(p->optArg.argInt)); break; case OPARG_TYPE_STRING: - if (p->fOptState & OPTST_STACKED) { - tArgList* pAL = (tArgList*)p->optCookie; - int uct = pAL->useCt; - tCC** ppz = pAL->apzArgs; - - /* - * Disallow multiple copies of disabled options. - */ - if (uct > 1) - p->fOptState &= ~OPTST_DISABLED; - - while (uct-- > 0) - printEntry( fp, p, *(ppz++) ); - } else { - printEntry( fp, p, p->optArg.argString ); - } + printStringArg(fp, p); break; case OPARG_TYPE_ENUMERATION: - case OPARG_TYPE_MEMBERSHIP: - { - uintptr_t val = p->optArg.argEnum; - /* - * This is a magic incantation that will convert the - * bit flag values back into a string suitable for printing. - */ - (*(p->pOptProc))( (tOptions*)2UL, p ); - printEntry( fp, p, (void*)(p->optArg.argString)); - - if ( (p->optArg.argString != NULL) - && (arg_state != OPARG_TYPE_ENUMERATION)) { - /* - * set membership strings get allocated - */ - AGFREE( (void*)p->optArg.argString ); - p->fOptState &= ~OPTST_ALLOC_ARG; - } + printEnumArg(fp, p); + break; - p->optArg.argEnum = val; + case OPARG_TYPE_MEMBERSHIP: + printSetMemberArg(fp, p); break; - } case OPARG_TYPE_BOOLEAN: printEntry( fp, p, p->optArg.argBool ? "true" : "false" ); break; + case OPARG_TYPE_HIERARCHY: + printHierarchy(fp, p); + break; + + case OPARG_TYPE_FILE: + printFileArg(fp, p, pOpts); + break; + default: break; /* cannot handle - skip it */ } diff -urN src/contrib/ntp/libopts/sort.c src.ntp/contrib/ntp/libopts/sort.c --- src/contrib/ntp/libopts/sort.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/sort.c 2009-12-09 08:36:36.000000000 +0100 @@ -1,56 +1,33 @@ /* - * sort.c $Id: sort.c,v 4.10 2007/04/28 22:19:23 bkorb Exp $ - * Time-stamp: "2006-10-18 11:29:04 bkorb" + * sort.c $Id: aac1bf81481f4bb149a72129fbd11fe54db7fa35 $ + * Time-stamp: "2007-07-04 11:34:52 bkorb" * * This module implements argument sorting. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. + * These files have the following md5sums: * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static tSuccess mustHandleArg( tOptions* pOpts, char* pzArg, tOptState* pOS, char** ppzOpts, int* pOptsIdx ); diff -urN src/contrib/ntp/libopts/stack.c src.ntp/contrib/ntp/libopts/stack.c --- src/contrib/ntp/libopts/stack.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/stack.c 2009-12-09 08:36:36.000000000 +0100 @@ -1,54 +1,31 @@ /* * stack.c - * $Id: stack.c,v 4.13 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-13 10:43:21 bkorb" + * $Id: 9d4a7c1c6ae364a6134dc5ff01f58f08b52f1a16 $ + * Time-stamp: "2008-07-30 16:56:32 bkorb" * * This is a special option processing routine that will save the * argument to an option in a FIFO queue. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ #ifdef WITH_LIBREGEX @@ -72,7 +49,12 @@ { int res; - tArgList* pAL = (tArgList*)pOptDesc->optCookie; + tArgList* pAL; + + if ((pOptDesc->fOptState & OPTST_RESET) != 0) + return; + pAL = (tArgList*)pOptDesc->optCookie; + /* * IF we don't have any stacked options, * THEN indicate that we don't have any of these options @@ -254,11 +236,24 @@ { char * pz; - if (pOD->optArg.argString == NULL) - return; + if ((pOD->fOptState & OPTST_RESET) != 0) { + tArgList* pAL = (void*)pOD->optCookie; + int ix; + if (pAL == NULL) + return; - AGDUPSTR(pz, pOD->optArg.argString, "stack arg"); - addArgListEntry( &(pOD->optCookie), (void*)pz ); + ix = pAL->useCt; + while (--ix >= 0) + AGFREE(pAL->apzArgs[ix]); + AGFREE(pAL); + + } else { + if (pOD->optArg.argString == NULL) + return; + + AGDUPSTR(pz, pOD->optArg.argString, "stack arg"); + addArgListEntry( &(pOD->optCookie), (void*)pz ); + } } /* * Local Variables: diff -urN src/contrib/ntp/libopts/streqvcmp.c src.ntp/contrib/ntp/libopts/streqvcmp.c --- src/contrib/ntp/libopts/streqvcmp.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/streqvcmp.c 2009-12-09 08:36:36.000000000 +0100 @@ -1,7 +1,7 @@ /* - * $Id: streqvcmp.c,v 4.10 2007/04/28 22:19:23 bkorb Exp $ - * Time-stamp: "2006-07-26 18:25:53 bkorb" + * $Id: cb437d22b0c48960c9e1c23501fba6e3291fecd8 $ + * Time-stamp: "2008-12-26 10:15:46 bkorb" * * String Equivalence Comparison * @@ -9,52 +9,27 @@ * character before comparison. In processing long option names, * the characters "-", "_" and "^" all need to be equivalent * (because they are treated so by different development environments). - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ - -/* + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd + * * This array is designed for mapping upper and lower case letter * together for a case independent comparison. The mappings are * based upon ascii character sequences. @@ -270,6 +245,8 @@ * This function name is mapped to option_strtransform so as to not conflict * with the POSIX name space. * + * The source and destination may be the same. + * * err: none. =*/ void diff -urN src/contrib/ntp/libopts/text_mmap.c src.ntp/contrib/ntp/libopts/text_mmap.c --- src/contrib/ntp/libopts/text_mmap.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/text_mmap.c 2009-12-09 08:36:36.000000000 +0100 @@ -1,7 +1,27 @@ /* - * $Id: text_mmap.c,v 4.15 2006/11/27 01:52:23 bkorb Exp $ + * $Id: 14e1f51d1a5a31d8395fdf1e93a07bace1c59e87 $ * - * Time-stamp: "2006-09-10 14:50:04 bkorb" + * Time-stamp: "2007-07-04 11:35:49 bkorb" + * + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ #ifndef MAP_ANONYMOUS diff -urN src/contrib/ntp/libopts/time.c src.ntp/contrib/ntp/libopts/time.c --- src/contrib/ntp/libopts/time.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/libopts/time.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,88 @@ + +/* + * $Id: 63d3312044fd7854ad0995faea41c96f5185cb93 $ + * Time-stamp: "2008-11-16 14:51:48 bkorb" + * + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd + */ + +#ifndef HAVE_PARSE_DURATION +#include + +static inline char * +ao_xstrdup(char const * pz) +{ + char * str; + AGDUPSTR(str, pz, "time val str"); + return str; +} + +#define xstrdup(_s) ao_xstrdup(_s) + +#include "parse-duration.c" + +#undef xstrdup +#endif + +/*=export_func optionTimeVal + * private: + * + * what: process an option with a time value. + * arg: + tOptions* + pOpts + program options descriptor + + * arg: + tOptDesc* + pOptDesc + the descriptor for this arg + + * + * doc: + * Decipher a time duration value. +=*/ +void +optionTimeVal(tOptions* pOpts, tOptDesc* pOD ) +{ + long val; + + if ((pOD->fOptState & OPTST_RESET) != 0) + return; + + val = parse_duration(pOD->optArg.argString); + if (errno != 0) + goto bad_time; + + if (pOD->fOptState & OPTST_ALLOC_ARG) { + AGFREE(pOD->optArg.argString); + pOD->fOptState &= ~OPTST_ALLOC_ARG; + } + + pOD->optArg.argInt = val; + return; + +bad_time: + fprintf( stderr, zNotNumber, pOpts->pzProgName, pOD->optArg.argString ); + if ((pOpts->fOptSet & OPTPROC_ERRSTOP) != 0) + (*(pOpts->pUsageProc))(pOpts, EXIT_FAILURE); + + pOD->optArg.argInt = ~0; +} +/* + * Local Variables: + * mode: C + * c-file-style: "stroustrup" + * indent-tabs-mode: nil + * End: + * end of autoopts/numeric.c */ diff -urN src/contrib/ntp/libopts/tokenize.c src.ntp/contrib/ntp/libopts/tokenize.c --- src/contrib/ntp/libopts/tokenize.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/tokenize.c 2009-12-09 08:36:36.000000000 +0100 @@ -1,26 +1,28 @@ /* * This file defines the string_tokenize interface - * Time-stamp: "2006-06-24 15:27:49 bkorb" + * Time-stamp: "2007-11-12 20:40:36 bkorb" * - * string_tokenize copyright 2005 Bruce Korb + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved * - * string_tokenize is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * string_tokenize is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with string_tokenize; if not, write to: - * The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ -#include + #include #include @@ -28,7 +30,7 @@ #define ch_t unsigned char /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static void copy_cooked( ch_t** ppDest, char const ** ppSrc ); @@ -189,7 +191,7 @@ * Trim leading white space. Use "ENOENT" and a NULL return to indicate * an empty string was passed. */ - while (isspace( (ch_t)*str )) str++; + while (IS_WHITESPACE_CHAR(*str)) str++; if (*str == NUL) { bogus_str: errno = ENOENT; @@ -206,9 +208,9 @@ do { max_token_ct++; - while (! isspace( *++pz )) + while (! IS_WHITESPACE_CHAR(*++pz)) if (*pz == NUL) goto found_nul; - while (isspace( *pz )) pz++; + while (IS_WHITESPACE_CHAR(*pz)) pz++; } while (*pz != NUL); found_nul: @@ -232,9 +234,9 @@ res->tkn_list[ res->tkn_ct++ ] = pzDest; for (;;) { int ch = (ch_t)*str; - if (isspace( ch )) { + if (IS_WHITESPACE_CHAR(ch)) { found_white_space: - while (isspace( (ch_t)*++str )) ; + while (IS_WHITESPACE_CHAR(*++str)) ; break; } @@ -246,7 +248,7 @@ errno = EINVAL; return NULL; } - if (isspace( (ch_t)*str )) + if (IS_WHITESPACE_CHAR(*str)) goto found_white_space; break; @@ -257,7 +259,7 @@ errno = EINVAL; return NULL; } - if (isspace( (ch_t)*str )) + if (IS_WHITESPACE_CHAR(*str)) goto found_white_space; break; diff -urN src/contrib/ntp/libopts/usage.c src.ntp/contrib/ntp/libopts/usage.c --- src/contrib/ntp/libopts/usage.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/usage.c 2009-12-09 08:36:36.000000000 +0100 @@ -1,7 +1,7 @@ /* - * usage.c $Id: usage.c,v 4.15 2007/04/28 22:19:23 bkorb Exp $ - * Time-stamp: "2007-04-15 11:02:46 bkorb" + * usage.c $Id: f611ee45aa9aa8dc102b8acf6b4bc568c60fa99f $ + * Time-stamp: "2009-10-02 23:18:50 bkorb" * * This module implements the default usage procedure for * Automated Options. It may be overridden, of course. @@ -13,46 +13,25 @@ */ /* - * Automated Options copyright 1992-2007 Bruce Korb + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ #define OPTPROC_L_N_S (OPTPROC_LONGOPT | OPTPROC_SHORTOPT) @@ -64,7 +43,7 @@ static ag_bool displayEnum; /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static ag_bool checkGNUUsage( tOptions* pOpts ); @@ -82,6 +61,12 @@ tCC* pzPN ); static void +printOptPreamble( + tOptions* pOptions, + tOptDesc* pOD, + arg_types_t* pAT ); + +static void printOneUsage( tOptions* pOptions, tOptDesc* pOD, @@ -89,9 +74,9 @@ static void printOptionUsage( - tOptions* pOpts, - int ex_code, - tCC* pOptTitle ); + tOptions * pOpts, + int ex_code, + tCC * pOptTitle ); static void printProgramDetails( tOptions* pOptions ); @@ -187,9 +172,32 @@ * Paged usage will preset option_usage_fp to an output file. * If it hasn't already been set, then set it to standard output * on successful exit (help was requested), otherwise error out. + * + * Test the version before obtaining pzFullUsage or pzShortUsage. + * These fields do not exist before revision 30. */ - if (option_usage_fp == NULL) - option_usage_fp = (actual_exit_code != EXIT_SUCCESS) ? stderr : stdout; + { + char const * pz; + + if (actual_exit_code == EXIT_SUCCESS) { + pz = (pOptions->structVersion >= 30 * 4096) + ? pOptions->pzFullUsage : NULL; + + if (option_usage_fp == NULL) + option_usage_fp = stdout; + } else { + pz = (pOptions->structVersion >= 30 * 4096) + ? pOptions->pzShortUsage : NULL; + + if (option_usage_fp == NULL) + option_usage_fp = stderr; + } + + if (pz != NULL) { + fputs(pz, option_usage_fp); + exit(actual_exit_code); + } + } fprintf( option_usage_fp, pOptions->pzUsageTitle, pOptions->pzProgName ); @@ -319,13 +327,23 @@ fprintf( option_usage_fp, zDis, pOD->pz_DisableName ); /* - * IF the numeric option has a special callback, - * THEN call it, requesting the range or other special info + * Check for argument types that have callbacks with magical properties */ - if ( (OPTST_GET_ARGTYPE(pOD->fOptState) == OPARG_TYPE_NUMERIC) - && (pOD->pOptProc != NULL) - && (pOD->pOptProc != optionNumericVal) ) { - (*(pOD->pOptProc))( pOptions, NULL ); + switch (OPTST_GET_ARGTYPE(pOD->fOptState)) { + case OPARG_TYPE_NUMERIC: + /* + * IF the numeric option has a special callback, + * THEN call it, requesting the range or other special info + */ + if ( (pOD->pOptProc != NULL) + && (pOD->pOptProc != optionNumericVal) ) { + (*(pOD->pOptProc))(OPTPROC_EMIT_USAGE, pOD); + } + break; + + case OPARG_TYPE_FILE: + (*(pOD->pOptProc))(OPTPROC_EMIT_USAGE, pOD); + break; } /* @@ -450,11 +468,8 @@ } -/* - * Print the usage information for a single option. - */ static void -printOneUsage( +printOptPreamble( tOptions* pOptions, tOptDesc* pOD, arg_types_t* pAT ) @@ -467,17 +482,31 @@ */ if ((pOptions->fOptSet & OPTPROC_SHORTOPT) == 0) fputs( pAT->pzSpc, option_usage_fp ); - else if (! isgraph( pOD->optValue)) { + + else if (! IS_GRAPHIC_CHAR(pOD->optValue)) { if ( (pOptions->fOptSet & (OPTPROC_GNUUSAGE|OPTPROC_LONGOPT)) == (OPTPROC_GNUUSAGE|OPTPROC_LONGOPT)) fputc( ' ', option_usage_fp ); fputs( pAT->pzNoF, option_usage_fp ); + } else { fprintf( option_usage_fp, " -%c", pOD->optValue ); if ( (pOptions->fOptSet & (OPTPROC_GNUUSAGE|OPTPROC_LONGOPT)) == (OPTPROC_GNUUSAGE|OPTPROC_LONGOPT)) fputs( ", ", option_usage_fp ); } +} + +/* + * Print the usage information for a single option. + */ +static void +printOneUsage( + tOptions* pOptions, + tOptDesc* pOD, + arg_types_t* pAT ) +{ + printOptPreamble(pOptions, pOD, pAT); { char z[ 80 ]; @@ -487,20 +516,20 @@ * when the option argument is required, base the type string on the * argument type. */ - if (OPTST_GET_ARGTYPE(pOD->fOptState) == OPARG_TYPE_NONE) { - pzArgType = pAT->pzNo; - - } else if (pOD->fOptState & OPTST_ARG_OPTIONAL) { + if (pOD->fOptState & OPTST_ARG_OPTIONAL) { pzArgType = pAT->pzOpt; } else switch (OPTST_GET_ARGTYPE(pOD->fOptState)) { + case OPARG_TYPE_NONE: pzArgType = pAT->pzNo; break; case OPARG_TYPE_ENUMERATION: pzArgType = pAT->pzKey; break; + case OPARG_TYPE_FILE : pzArgType = pAT->pzFile; break; case OPARG_TYPE_MEMBERSHIP: pzArgType = pAT->pzKeyL; break; case OPARG_TYPE_BOOLEAN: pzArgType = pAT->pzBool; break; case OPARG_TYPE_NUMERIC: pzArgType = pAT->pzNum; break; case OPARG_TYPE_HIERARCHY: pzArgType = pAT->pzNest; break; case OPARG_TYPE_STRING: pzArgType = pAT->pzStr; break; - default: goto bogus_desc; break; + case OPARG_TYPE_TIME: pzArgType = pAT->pzTime; break; + default: goto bogus_desc; } snprintf( z, sizeof(z), pAT->pzOptFmt, pzArgType, pOD->pz_Name, @@ -527,18 +556,36 @@ */ static void printOptionUsage( - tOptions* pOpts, - int ex_code, - tCC* pOptTitle ) + tOptions * pOpts, + int ex_code, + tCC * pOptTitle ) { - int ct = pOpts->optCt; - int optNo = 0; - tOptDesc* pOD = pOpts->pOptDesc; - int docCt = 0; + int ct = pOpts->optCt; + int optNo = 0; + tOptDesc * pOD = pOpts->pOptDesc; + int docCt = 0; do { - if ((pOD->fOptState & OPTST_OMITTED) != 0) + if ((pOD->fOptState & OPTST_NO_USAGE_MASK) != 0) { + + /* + * IF this is a compiled-out option + * *AND* usage was requested with "omitted-usage" + * *AND* this is NOT abbreviated usage + * THEN display this option. + */ + if ( (pOD->fOptState == (OPTST_OMITTED | OPTST_NO_INIT)) + && (pOD->pz_Name != NULL) + && (ex_code == EXIT_SUCCESS)) { + + char const * why_pz = + (pOD->pzText == NULL) ? zDisabledWhy : pOD->pzText; + printOptPreamble(pOpts, pOD, &argTypes); + fprintf(option_usage_fp, zDisabledOpt, pOD->pz_Name, why_pz); + } + continue; + } if ((pOD->fOptState & OPTST_DOCUMENT) != 0) { if (ex_code == EXIT_SUCCESS) { @@ -558,12 +605,12 @@ * THEN document that the remaining options are not user opts */ if ( (pOpts->presetOptCt == optNo) - && (ex_code == EXIT_SUCCESS) - && (docCt > 0) - && ((pOD[-1].fOptState & OPTST_DOCUMENT) == 0) ) + && (ex_code == EXIT_SUCCESS) + && (docCt > 0) + && ((pOD[-1].fOptState & OPTST_DOCUMENT) == 0) ) fprintf( option_usage_fp, argTypes.pzBrk, zAuto, pOptTitle ); - printOneUsage( pOpts, pOD, &argTypes ); + printOneUsage(pOpts, pOD, &argTypes); /* * IF we were invoked because of the --help option, @@ -619,7 +666,7 @@ switch (OPTST_GET_ARGTYPE(pOD->fOptState)) { case OPARG_TYPE_ENUMERATION: case OPARG_TYPE_MEMBERSHIP: - (*(pOD->pOptProc))( NULL, pOD ); + (*(pOD->pOptProc))(OPTPROC_EMIT_USAGE, pOD); } } while (pOD++, optNo++, (--ct > 0)); } @@ -657,6 +704,8 @@ argTypes.pzNum = zGnuNumArg; argTypes.pzKey = zGnuKeyArg; argTypes.pzKeyL = zGnuKeyLArg; + argTypes.pzTime = zGnuTimeArg; + argTypes.pzFile = zGnuFileArg; argTypes.pzBool = zGnuBoolArg; argTypes.pzNest = zGnuNestArg; argTypes.pzOpt = zGnuOptArg; @@ -694,6 +743,8 @@ argTypes.pzNum = zStdNumArg; argTypes.pzKey = zStdKeyArg; argTypes.pzKeyL = zStdKeyLArg; + argTypes.pzTime = zStdTimeArg; + argTypes.pzFile = zStdFileArg; argTypes.pzBool = zStdBoolArg; argTypes.pzNest = zStdNestArg; argTypes.pzOpt = zStdOptArg; diff -urN src/contrib/ntp/libopts/value-type.c src.ntp/contrib/ntp/libopts/value-type.c --- src/contrib/ntp/libopts/value-type.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/libopts/value-type.c 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,120 @@ +/* ANSI-C code produced by gperf version 3.0.2 */ + + +#if 0 /* gperf build options: */ +// %struct-type +// %language=ANSI-C +// %includes +// %global-table +// %omit-struct-type +// %readonly-tables +// %compare-strncmp +// +// %define slot-name vtp_name +// %define hash-function-name value_type_hash +// %define lookup-function-name find_value_type_name +// %define word-array-name value_type_table +// %define initializer-suffix ,VTP_COUNT_KWD +#endif /* gperf build options: */ + +#include "value-type.h" + +typedef struct { + char const * vtp_name; + value_type_enum_t vtp_id; +} value_type_map_t; +#include + +/* maximum key range = 20, duplicates = 0 */ + +#ifdef __GNUC__ +#else +#ifdef __cplusplus +#endif +#endif +inline static unsigned int +value_type_hash (register const char *str, register unsigned int len) +{ + static const unsigned char asso_values[] = + { + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 10, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 5, 23, 23, 5, 0, 0, 23, 15, 23, + 23, 10, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23 + }; + return len + asso_values[(unsigned char)str[2]]; +} + +static const value_type_map_t value_type_table[] = + { + {"",VTP_COUNT_KWD}, {"",VTP_COUNT_KWD}, + {"",VTP_COUNT_KWD}, + {"set", VTP_KWD_SET}, + {"",VTP_COUNT_KWD}, {"",VTP_COUNT_KWD}, + {"nested", VTP_KWD_NESTED}, + {"integer", VTP_KWD_INTEGER}, + {"",VTP_COUNT_KWD}, + {"bool", VTP_KWD_BOOL}, + {"",VTP_COUNT_KWD}, + {"string", VTP_KWD_STRING}, + {"boolean", VTP_KWD_BOOLEAN}, + {"",VTP_COUNT_KWD}, + {"set-membership", VTP_KWD_SET_MEMBERSHIP}, + {"",VTP_COUNT_KWD}, {"",VTP_COUNT_KWD}, + {"keyword", VTP_KWD_KEYWORD}, + {"",VTP_COUNT_KWD}, + {"hierarchy", VTP_KWD_HIERARCHY}, + {"",VTP_COUNT_KWD}, {"",VTP_COUNT_KWD}, + {"invalid", VTP_KWD_INVALID} + }; + +#ifdef __GNUC__ +#endif +static inline const value_type_map_t * +find_value_type_name (register const char *str, register unsigned int len) +{ + if (len <= 14 && len >= 3) + { + register int key = value_type_hash (str, len); + + if (key <= 22 && key >= 0) + { + register const char *s = value_type_table[key].vtp_name; + + if (*str == *s && !strncmp (str + 1, s + 1, len - 1) && s[len] == '\0') + return &value_type_table[key]; + } + } + return 0; +} + + +value_type_enum_t +find_value_type_id(char const * str, unsigned int len) +{ + const value_type_map_t * p = + find_value_type_name(str, len); + return (p == 0) ? VTP_KWD_INVALID : p->vtp_id; +} diff -urN src/contrib/ntp/libopts/value-type.h src.ntp/contrib/ntp/libopts/value-type.h --- src/contrib/ntp/libopts/value-type.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/libopts/value-type.h 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,25 @@ +/* + * Generated header for gperf generated source Sun Nov 8 08:41:19 PST 2009 + * This file enumerates the list of names and declares the + * procedure for mapping string names to the enum value. + */ +#ifndef AUTOOPTS_VALUE_TYPE_H_GUARD +#define AUTOOPTS_VALUE_TYPE_H_GUARD 1 + +typedef enum { + VTP_KWD_INVALID, + VTP_KWD_STRING, + VTP_KWD_INTEGER, + VTP_KWD_BOOLEAN, + VTP_KWD_BOOL, + VTP_KWD_KEYWORD, + VTP_KWD_SET, + VTP_KWD_SET_MEMBERSHIP, + VTP_KWD_NESTED, + VTP_KWD_HIERARCHY, + VTP_COUNT_KWD +} value_type_enum_t; + +extern value_type_enum_t +find_value_type_id(char const * str, unsigned int len); +#endif /* AUTOOPTS_VALUE_TYPE_H_GUARD */ diff -urN src/contrib/ntp/libopts/version.c src.ntp/contrib/ntp/libopts/version.c --- src/contrib/ntp/libopts/version.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libopts/version.c 2009-12-09 08:36:36.000000000 +0100 @@ -1,56 +1,35 @@ -/* $Id: version.c,v 4.10 2007/04/28 22:19:23 bkorb Exp $ - * Time-stamp: "2007-04-28 10:08:34 bkorb" +/* $Id: e21e2bf9958c54e440efbdc7c1026e46ac589f66 $ + * Time-stamp: "2008-07-27 10:11:30 bkorb" * * This module implements the default usage procedure for * Automated Options. It may be overridden, of course. */ -static char const zAOV[] = - "Automated Options version %s, copyright (c) 1999-2007 Bruce Korb\n"; - -/* Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. +/* + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static void printVersion( tOptions* pOpts, tOptDesc* pOD, FILE* fp ); /* = = = END-STATIC-FORWARD = = = */ @@ -107,7 +86,7 @@ fputs( pOpts->pzCopyright, fp ); fputc( '\n', fp ); } - fprintf( fp, zAOV, optionVersion() ); + fprintf( fp, zAO_Ver, optionVersion() ); if (pOpts->pzBugAddr != NULL) fprintf( fp, zPlsSendBugs, pOpts->pzBugAddr ); break; @@ -124,7 +103,7 @@ fputc( '\n', fp ); } - fprintf( fp, zAOV, optionVersion() ); + fprintf( fp, zAO_Ver, optionVersion() ); if (pOpts->pzBugAddr != NULL) fprintf( fp, zPlsSendBugs, pOpts->pzBugAddr ); break; diff -urN src/contrib/ntp/libopts/xat-attribute.c src.ntp/contrib/ntp/libopts/xat-attribute.c --- src/contrib/ntp/libopts/xat-attribute.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/libopts/xat-attribute.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,111 @@ +/* ANSI-C code produced by gperf version 3.0.2 */ + + +#if 0 /* gperf build options: */ +// %struct-type +// %language=ANSI-C +// %includes +// %global-table +// %omit-struct-type +// %readonly-tables +// %compare-strncmp +// +// %define slot-name xat_name +// %define hash-function-name xat_attribute_hash +// %define lookup-function-name find_xat_attribute_name +// %define word-array-name xat_attribute_table +// %define initializer-suffix ,XAT_COUNT_KWD +#endif /* gperf build options: */ + +#include "xat-attribute.h" + +typedef struct { + char const * xat_name; + xat_attribute_enum_t xat_id; +} xat_attribute_map_t; +#include + +/* maximum key range = 9, duplicates = 0 */ + +#ifdef __GNUC__ +#else +#ifdef __cplusplus +#endif +#endif +inline static unsigned int +xat_attribute_hash (register const char *str, register unsigned int len) +{ + static const unsigned char asso_values[] = + { + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 0, + 13, 13, 13, 13, 13, 5, 13, 5, 13, 0, + 13, 13, 13, 13, 13, 13, 0, 0, 13, 0, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13 + }; + return len + asso_values[(unsigned char)str[0]]; +} + +static const xat_attribute_map_t xat_attribute_table[] = + { + {"",XAT_COUNT_KWD}, {"",XAT_COUNT_KWD}, + {"",XAT_COUNT_KWD}, {"",XAT_COUNT_KWD}, + {"type", XAT_KWD_TYPE}, + {"words", XAT_KWD_WORDS}, + {"cooked", XAT_KWD_COOKED}, + {"members", XAT_KWD_MEMBERS}, + {"uncooked", XAT_KWD_UNCOOKED}, + {"keep", XAT_KWD_KEEP}, + {"",XAT_COUNT_KWD}, {"",XAT_COUNT_KWD}, + {"invalid", XAT_KWD_INVALID} + }; + +#ifdef __GNUC__ +#endif +static inline const xat_attribute_map_t * +find_xat_attribute_name (register const char *str, register unsigned int len) +{ + if (len <= 8 && len >= 4) + { + register int key = xat_attribute_hash (str, len); + + if (key <= 12 && key >= 0) + { + register const char *s = xat_attribute_table[key].xat_name; + + if (*str == *s && !strncmp (str + 1, s + 1, len - 1) && s[len] == '\0') + return &xat_attribute_table[key]; + } + } + return 0; +} + + +xat_attribute_enum_t +find_xat_attribute_id(char const * str, unsigned int len) +{ + const xat_attribute_map_t * p = + find_xat_attribute_name(str, len); + return (p == 0) ? XAT_KWD_INVALID : p->xat_id; +} diff -urN src/contrib/ntp/libopts/xat-attribute.h src.ntp/contrib/ntp/libopts/xat-attribute.h --- src/contrib/ntp/libopts/xat-attribute.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/libopts/xat-attribute.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,22 @@ +/* + * Generated header for gperf generated source Sun Nov 8 08:41:19 PST 2009 + * This file enumerates the list of names and declares the + * procedure for mapping string names to the enum value. + */ +#ifndef AUTOOPTS_XAT_ATTRIBUTE_H_GUARD +#define AUTOOPTS_XAT_ATTRIBUTE_H_GUARD 1 + +typedef enum { + XAT_KWD_INVALID, + XAT_KWD_TYPE, + XAT_KWD_WORDS, + XAT_KWD_MEMBERS, + XAT_KWD_COOKED, + XAT_KWD_UNCOOKED, + XAT_KWD_KEEP, + XAT_COUNT_KWD +} xat_attribute_enum_t; + +extern xat_attribute_enum_t +find_xat_attribute_id(char const * str, unsigned int len); +#endif /* AUTOOPTS_XAT_ATTRIBUTE_H_GUARD */ diff -urN src/contrib/ntp/libparse/Makefile.am src.ntp/contrib/ntp/libparse/Makefile.am --- src/contrib/ntp/libparse/Makefile.am 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/libparse/Makefile.am 2009-12-20 06:21:43.000000000 +0100 @@ -1,55 +1,63 @@ +NULL= #AUTOMAKE_OPTIONS = ../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr +AUTOMAKE_OPTIONS = +BUILT_SOURCES = noinst_LIBRARIES = @MAKE_LIBPARSE@ @MAKE_LIBPARSE_KERNEL@ EXTRA_LIBRARIES = libparse.a libparse_kernel.a EXTRA_PROGRAMS = parsestreams parsesolaris noinst_PROGRAMS = @MAKE_PARSEKMODULE@ -CLEANFILES = libparse.a libparse_kernel.a +CLEANFILES = libparse.a libparse_kernel.a info_trimble.c K_CFLAGS = -DPARSESTREAM -DNTP_NEED_BOPS libparse_a_SOURCES = parse.c \ - parse_conf.c \ - clk_meinberg.c \ - clk_schmid.c \ + parse_conf.c \ + clk_meinberg.c \ + clk_schmid.c \ clk_rawdcf.c \ clk_trimtsip.c \ - clk_dcf7000.c \ - clk_trimtaip.c \ - clk_rcc8000.c \ - clk_hopf6021.c \ - clk_computime.c \ + clk_dcf7000.c \ + clk_trimtaip.c \ + clk_rcc8000.c \ + clk_hopf6021.c \ + clk_computime.c \ clk_wharton.c \ clk_varitext.c \ - data_mbg.c \ + data_mbg.c \ info_trimble.c \ trim_info.c \ binio.c \ ieee754io.c \ mfp_mul.c \ - gpstolfp.c + gpstolfp.c \ + $(NULL) libparse_kernel_a_SOURCES = -libparse_kernel_a_LIBADD = kparse$U.o \ - kparse_conf$U.o \ - kclk_computime$U.o \ - kclk_dcf7000$U.o \ - kclk_hopf6021$U.o \ - kclk_meinberg$U.o \ - kclk_rawdcf$U.o \ - kclk_rcc8000$U.o \ - kclk_schmid$U.o \ - kclk_trimtaip$U.o \ - kclk_trimtsip$U.o \ - kclk_varitext$U.o \ - kclk_wharton$U.o \ - kbinio$U.o \ - kieee754io$U.o \ - kmfp_mul$U.o \ - kgpstolfp$U.o +libparse_kernel_a_LIBADD = \ + kparse.o \ + kparse_conf.o \ + kclk_computime.o \ + kclk_dcf7000.o \ + kclk_hopf6021.o \ + kclk_meinberg.o \ + kclk_rawdcf.o \ + kclk_rcc8000.o \ + kclk_schmid.o \ + kclk_trimtaip.o \ + kclk_trimtsip.o \ + kclk_varitext.o \ + kclk_wharton.o \ + kbinio.o \ + kieee754io.o \ + kmfp_mul.o \ + kgpstolfp.o \ + $(NULL) + + +INCLUDES = -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/nothreads/include \ + -I$(top_srcdir)/lib/isc/unix/include -I$(top_srcdir)/kernel - -INCLUDES = -I$(top_srcdir)/include -I$(top_srcdir)/kernel ETAGS_ARGS = Makefile.am EXTRA_DIST = parsesolaris.c parsestreams.c mkinfo_scmd.sed mkinfo_rcmd.sed info_trimble.c @@ -58,9 +66,9 @@ # create info_trimble.c # info_trimble.c: $(top_srcdir)/include/trimble.h mkinfo_rcmd.sed mkinfo_scmd.sed - @rm -f info_trimble.c - sed -n -f $(srcdir)/mkinfo_scmd.sed $(top_srcdir)/include/trimble.h > info_trimble.c || rm -f info_trimble.c - sed -n -f $(srcdir)/mkinfo_rcmd.sed $(top_srcdir)/include/trimble.h >> info_trimble.c || rm -f info_trimble.c + @rm -f $@ + sed -n -f $(srcdir)/mkinfo_scmd.sed $(top_srcdir)/include/trimble.h > $@ || rm -f $@ + sed -n -f $(srcdir)/mkinfo_rcmd.sed $(top_srcdir)/include/trimble.h >> $@ || rm -f $@ kieee754io.o: ieee754io.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/ieee754io.c -o $@ @@ -166,3 +174,5 @@ sys/systm.h: mkdir sys && \ sed -e '/ffs(.*)/d' < /usr/include/sys/systm.h > sys/systm.h + +include $(top_srcdir)/depsver.mf diff -urN src/contrib/ntp/libparse/Makefile.in src.ntp/contrib/ntp/libparse/Makefile.in --- src/contrib/ntp/libparse/Makefile.in 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/libparse/Makefile.in 2010-07-09 04:21:33.000000000 +0200 @@ -35,14 +35,18 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -ANSI2KNR = ../util/ansi2knr EXTRA_PROGRAMS = parsestreams$(EXEEXT) parsesolaris$(EXEEXT) +DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ + $(top_srcdir)/depsver.mf subdir = libparse -DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ + $(top_srcdir)/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/m4/ntp_openssl.m4 \ + $(top_srcdir)/m4/ntp_vpathhack.m4 \ $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ @@ -55,32 +59,34 @@ ARFLAGS = cru libparse_a_AR = $(AR) $(ARFLAGS) libparse_a_LIBADD = -am_libparse_a_OBJECTS = parse$U.$(OBJEXT) parse_conf$U.$(OBJEXT) \ - clk_meinberg$U.$(OBJEXT) clk_schmid$U.$(OBJEXT) \ - clk_rawdcf$U.$(OBJEXT) clk_trimtsip$U.$(OBJEXT) \ - clk_dcf7000$U.$(OBJEXT) clk_trimtaip$U.$(OBJEXT) \ - clk_rcc8000$U.$(OBJEXT) clk_hopf6021$U.$(OBJEXT) \ - clk_computime$U.$(OBJEXT) clk_wharton$U.$(OBJEXT) \ - clk_varitext$U.$(OBJEXT) data_mbg$U.$(OBJEXT) \ - info_trimble$U.$(OBJEXT) trim_info$U.$(OBJEXT) \ - binio$U.$(OBJEXT) ieee754io$U.$(OBJEXT) mfp_mul$U.$(OBJEXT) \ - gpstolfp$U.$(OBJEXT) +am__objects_1 = +am_libparse_a_OBJECTS = parse.$(OBJEXT) parse_conf.$(OBJEXT) \ + clk_meinberg.$(OBJEXT) clk_schmid.$(OBJEXT) \ + clk_rawdcf.$(OBJEXT) clk_trimtsip.$(OBJEXT) \ + clk_dcf7000.$(OBJEXT) clk_trimtaip.$(OBJEXT) \ + clk_rcc8000.$(OBJEXT) clk_hopf6021.$(OBJEXT) \ + clk_computime.$(OBJEXT) clk_wharton.$(OBJEXT) \ + clk_varitext.$(OBJEXT) data_mbg.$(OBJEXT) \ + info_trimble.$(OBJEXT) trim_info.$(OBJEXT) binio.$(OBJEXT) \ + ieee754io.$(OBJEXT) mfp_mul.$(OBJEXT) gpstolfp.$(OBJEXT) \ + $(am__objects_1) libparse_a_OBJECTS = $(am_libparse_a_OBJECTS) libparse_kernel_a_AR = $(AR) $(ARFLAGS) -libparse_kernel_a_DEPENDENCIES = kparse$U.o kparse_conf$U.o \ - kclk_computime$U.o kclk_dcf7000$U.o kclk_hopf6021$U.o \ - kclk_meinberg$U.o kclk_rawdcf$U.o kclk_rcc8000$U.o \ - kclk_schmid$U.o kclk_trimtaip$U.o kclk_trimtsip$U.o \ - kclk_varitext$U.o kclk_wharton$U.o kbinio$U.o kieee754io$U.o \ - kmfp_mul$U.o kgpstolfp$U.o +am__DEPENDENCIES_1 = +libparse_kernel_a_DEPENDENCIES = kparse.o kparse_conf.o \ + kclk_computime.o kclk_dcf7000.o kclk_hopf6021.o \ + kclk_meinberg.o kclk_rawdcf.o kclk_rcc8000.o kclk_schmid.o \ + kclk_trimtaip.o kclk_trimtsip.o kclk_varitext.o kclk_wharton.o \ + kbinio.o kieee754io.o kmfp_mul.o kgpstolfp.o \ + $(am__DEPENDENCIES_1) am_libparse_kernel_a_OBJECTS = libparse_kernel_a_OBJECTS = $(am_libparse_kernel_a_OBJECTS) PROGRAMS = $(noinst_PROGRAMS) parsesolaris_SOURCES = parsesolaris.c -parsesolaris_OBJECTS = parsesolaris$U.$(OBJEXT) +parsesolaris_OBJECTS = parsesolaris.$(OBJEXT) parsesolaris_LDADD = $(LDADD) parsestreams_SOURCES = parsestreams.c -parsestreams_OBJECTS = parsestreams$U.$(OBJEXT) +parsestreams_OBJECTS = parsestreams.$(OBJEXT) parsestreams_LDADD = $(LDADD) DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) depcomp = $(SHELL) $(top_srcdir)/depcomp @@ -105,7 +111,6 @@ ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -126,6 +131,7 @@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EF_LIBS = @EF_LIBS@ EF_PROGS = @EF_PROGS@ EGREP = @EGREP@ @@ -157,6 +163,7 @@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ @@ -173,18 +180,22 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ PATH_SEPARATOR = @PATH_SEPARATOR@ PATH_SH = @PATH_SH@ PROPDELAY = @PROPDELAY@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ VERSION = @VERSION@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ @@ -236,62 +247,70 @@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ - +NULL = #AUTOMAKE_OPTIONS = ../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr +AUTOMAKE_OPTIONS = +BUILT_SOURCES = .deps-ver noinst_LIBRARIES = @MAKE_LIBPARSE@ @MAKE_LIBPARSE_KERNEL@ EXTRA_LIBRARIES = libparse.a libparse_kernel.a noinst_PROGRAMS = @MAKE_PARSEKMODULE@ -CLEANFILES = libparse.a libparse_kernel.a +CLEANFILES = libparse.a libparse_kernel.a info_trimble.c .deps-ver K_CFLAGS = -DPARSESTREAM -DNTP_NEED_BOPS libparse_a_SOURCES = parse.c \ - parse_conf.c \ - clk_meinberg.c \ - clk_schmid.c \ + parse_conf.c \ + clk_meinberg.c \ + clk_schmid.c \ clk_rawdcf.c \ clk_trimtsip.c \ - clk_dcf7000.c \ - clk_trimtaip.c \ - clk_rcc8000.c \ - clk_hopf6021.c \ - clk_computime.c \ + clk_dcf7000.c \ + clk_trimtaip.c \ + clk_rcc8000.c \ + clk_hopf6021.c \ + clk_computime.c \ clk_wharton.c \ clk_varitext.c \ - data_mbg.c \ + data_mbg.c \ info_trimble.c \ trim_info.c \ binio.c \ ieee754io.c \ mfp_mul.c \ - gpstolfp.c + gpstolfp.c \ + $(NULL) libparse_kernel_a_SOURCES = -libparse_kernel_a_LIBADD = kparse$U.o \ - kparse_conf$U.o \ - kclk_computime$U.o \ - kclk_dcf7000$U.o \ - kclk_hopf6021$U.o \ - kclk_meinberg$U.o \ - kclk_rawdcf$U.o \ - kclk_rcc8000$U.o \ - kclk_schmid$U.o \ - kclk_trimtaip$U.o \ - kclk_trimtsip$U.o \ - kclk_varitext$U.o \ - kclk_wharton$U.o \ - kbinio$U.o \ - kieee754io$U.o \ - kmfp_mul$U.o \ - kgpstolfp$U.o +libparse_kernel_a_LIBADD = \ + kparse.o \ + kparse_conf.o \ + kclk_computime.o \ + kclk_dcf7000.o \ + kclk_hopf6021.o \ + kclk_meinberg.o \ + kclk_rawdcf.o \ + kclk_rcc8000.o \ + kclk_schmid.o \ + kclk_trimtaip.o \ + kclk_trimtsip.o \ + kclk_varitext.o \ + kclk_wharton.o \ + kbinio.o \ + kieee754io.o \ + kmfp_mul.o \ + kgpstolfp.o \ + $(NULL) + +INCLUDES = -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/nothreads/include \ + -I$(top_srcdir)/lib/isc/unix/include -I$(top_srcdir)/kernel -INCLUDES = -I$(top_srcdir)/include -I$(top_srcdir)/kernel ETAGS_ARGS = Makefile.am EXTRA_DIST = parsesolaris.c parsestreams.c mkinfo_scmd.sed mkinfo_rcmd.sed info_trimble.c -all: all-am +all: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/depsver.mf $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -353,34 +372,29 @@ distclean-compile: -rm -f *.tab.c -../util/ansi2knr: - $(am__cd) ../util && $(MAKE) $(AM_MAKEFLAGS) ./ansi2knr - -mostlyclean-kr: - -test "$U" = "" || rm -f *_.c -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/binio$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_computime$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_dcf7000$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_hopf6021$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_meinberg$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_rawdcf$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_rcc8000$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_schmid$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_trimtaip$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_trimtsip$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_varitext$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_wharton$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/data_mbg$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gpstolfp$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ieee754io$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/info_trimble$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mfp_mul$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parse$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parse_conf$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parsesolaris$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parsestreams$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/trim_info$U.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/binio.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_computime.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_dcf7000.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_hopf6021.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_meinberg.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_rawdcf.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_rcc8000.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_schmid.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_trimtaip.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_trimtsip.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_varitext.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_wharton.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/data_mbg.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gpstolfp.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ieee754io.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/info_trimble.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mfp_mul.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parse.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parse_conf.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parsesolaris.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parsestreams.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/trim_info.Po@am__quote@ .c.o: @am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @@ -402,64 +416,6 @@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< -binio_.c: binio.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/binio.c; then echo $(srcdir)/binio.c; else echo binio.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clk_computime_.c: clk_computime.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clk_computime.c; then echo $(srcdir)/clk_computime.c; else echo clk_computime.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clk_dcf7000_.c: clk_dcf7000.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clk_dcf7000.c; then echo $(srcdir)/clk_dcf7000.c; else echo clk_dcf7000.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clk_hopf6021_.c: clk_hopf6021.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clk_hopf6021.c; then echo $(srcdir)/clk_hopf6021.c; else echo clk_hopf6021.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clk_meinberg_.c: clk_meinberg.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clk_meinberg.c; then echo $(srcdir)/clk_meinberg.c; else echo clk_meinberg.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clk_rawdcf_.c: clk_rawdcf.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clk_rawdcf.c; then echo $(srcdir)/clk_rawdcf.c; else echo clk_rawdcf.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clk_rcc8000_.c: clk_rcc8000.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clk_rcc8000.c; then echo $(srcdir)/clk_rcc8000.c; else echo clk_rcc8000.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clk_schmid_.c: clk_schmid.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clk_schmid.c; then echo $(srcdir)/clk_schmid.c; else echo clk_schmid.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clk_trimtaip_.c: clk_trimtaip.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clk_trimtaip.c; then echo $(srcdir)/clk_trimtaip.c; else echo clk_trimtaip.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clk_trimtsip_.c: clk_trimtsip.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clk_trimtsip.c; then echo $(srcdir)/clk_trimtsip.c; else echo clk_trimtsip.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clk_varitext_.c: clk_varitext.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clk_varitext.c; then echo $(srcdir)/clk_varitext.c; else echo clk_varitext.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clk_wharton_.c: clk_wharton.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clk_wharton.c; then echo $(srcdir)/clk_wharton.c; else echo clk_wharton.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -data_mbg_.c: data_mbg.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/data_mbg.c; then echo $(srcdir)/data_mbg.c; else echo data_mbg.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -gpstolfp_.c: gpstolfp.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/gpstolfp.c; then echo $(srcdir)/gpstolfp.c; else echo gpstolfp.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ieee754io_.c: ieee754io.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ieee754io.c; then echo $(srcdir)/ieee754io.c; else echo ieee754io.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -info_trimble_.c: info_trimble.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/info_trimble.c; then echo $(srcdir)/info_trimble.c; else echo info_trimble.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -mfp_mul_.c: mfp_mul.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/mfp_mul.c; then echo $(srcdir)/mfp_mul.c; else echo mfp_mul.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -parse_.c: parse.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/parse.c; then echo $(srcdir)/parse.c; else echo parse.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -parse_conf_.c: parse_conf.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/parse_conf.c; then echo $(srcdir)/parse_conf.c; else echo parse_conf.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -parsesolaris_.c: parsesolaris.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/parsesolaris.c; then echo $(srcdir)/parsesolaris.c; else echo parsesolaris.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -parsestreams_.c: parsestreams.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/parsestreams.c; then echo $(srcdir)/parsestreams.c; else echo parsestreams.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -trim_info_.c: trim_info.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/trim_info.c; then echo $(srcdir)/trim_info.c; else echo trim_info.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -binio_.$(OBJEXT) binio_.lo clk_computime_.$(OBJEXT) clk_computime_.lo \ -clk_dcf7000_.$(OBJEXT) clk_dcf7000_.lo clk_hopf6021_.$(OBJEXT) \ -clk_hopf6021_.lo clk_meinberg_.$(OBJEXT) clk_meinberg_.lo \ -clk_rawdcf_.$(OBJEXT) clk_rawdcf_.lo clk_rcc8000_.$(OBJEXT) \ -clk_rcc8000_.lo clk_schmid_.$(OBJEXT) clk_schmid_.lo \ -clk_trimtaip_.$(OBJEXT) clk_trimtaip_.lo clk_trimtsip_.$(OBJEXT) \ -clk_trimtsip_.lo clk_varitext_.$(OBJEXT) clk_varitext_.lo \ -clk_wharton_.$(OBJEXT) clk_wharton_.lo data_mbg_.$(OBJEXT) \ -data_mbg_.lo gpstolfp_.$(OBJEXT) gpstolfp_.lo ieee754io_.$(OBJEXT) \ -ieee754io_.lo info_trimble_.$(OBJEXT) info_trimble_.lo \ -mfp_mul_.$(OBJEXT) mfp_mul_.lo parse_.$(OBJEXT) parse_.lo \ -parse_conf_.$(OBJEXT) parse_conf_.lo parsesolaris_.$(OBJEXT) \ -parsesolaris_.lo parsestreams_.$(OBJEXT) parsestreams_.lo \ -trim_info_.$(OBJEXT) trim_info_.lo : $(ANSI2KNR) mostlyclean-libtool: -rm -f *.lo @@ -550,10 +506,12 @@ fi; \ done check-am: all-am -check: check-am +check: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) check-am all-am: Makefile $(LIBRARIES) $(PROGRAMS) installdirs: -install: install-am +install: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am @@ -579,6 +537,7 @@ maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." + -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-am clean-am: clean-generic clean-libtool clean-noinstLIBRARIES \ @@ -637,7 +596,7 @@ mostlyclean: mostlyclean-am -mostlyclean-am: mostlyclean-compile mostlyclean-generic mostlyclean-kr \ +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am @@ -650,7 +609,7 @@ uninstall-am: -.MAKE: ../util/ansi2knr install-am install-strip +.MAKE: all check install install-am install-strip .PHONY: CTAGS GTAGS all all-am check check-am clean clean-generic \ clean-libtool clean-noinstLIBRARIES clean-noinstPROGRAMS ctags \ @@ -663,17 +622,17 @@ install-ps install-ps-am install-strip installcheck \ installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-compile \ - mostlyclean-generic mostlyclean-kr mostlyclean-libtool pdf \ - pdf-am ps ps-am tags uninstall uninstall-am + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags uninstall uninstall-am # # create info_trimble.c # info_trimble.c: $(top_srcdir)/include/trimble.h mkinfo_rcmd.sed mkinfo_scmd.sed - @rm -f info_trimble.c - sed -n -f $(srcdir)/mkinfo_scmd.sed $(top_srcdir)/include/trimble.h > info_trimble.c || rm -f info_trimble.c - sed -n -f $(srcdir)/mkinfo_rcmd.sed $(top_srcdir)/include/trimble.h >> info_trimble.c || rm -f info_trimble.c + @rm -f $@ + sed -n -f $(srcdir)/mkinfo_scmd.sed $(top_srcdir)/include/trimble.h > $@ || rm -f $@ + sed -n -f $(srcdir)/mkinfo_rcmd.sed $(top_srcdir)/include/trimble.h >> $@ || rm -f $@ kieee754io.o: ieee754io.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/ieee754io.c -o $@ @@ -779,6 +738,70 @@ sys/systm.h: mkdir sys && \ sed -e '/ffs(.*)/d' < /usr/include/sys/systm.h > sys/systm.h +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + ..) \ + cd .. && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + *) \ + echo 'Fatal: depsver.mf Automake fragment limited' \ + 'to immediate subdirectories.' && \ + echo "top_builddir: $(top_builddir)" && \ + echo "subdir: $(subdir)" && \ + exit 1 \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff -urN src/contrib/ntp/libparse/clk_computime.c src.ntp/contrib/ntp/libparse/clk_computime.c --- src/contrib/ntp/libparse/clk_computime.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libparse/clk_computime.c 2009-12-09 08:36:35.000000000 +0100 @@ -54,7 +54,7 @@ #include #else #include "sys/parsestreams.h" -extern void printf P((const char *, ...)); +extern int printf (const char *, ...); #endif /* @@ -88,8 +88,8 @@ 0 }; -static u_long cvt_computime P((unsigned char *, int, struct format *, clocktime_t *, void *)); -static unsigned long inp_computime P((parse_t *, unsigned int, timestamp_t *)); +static u_long cvt_computime (unsigned char *, int, struct format *, clocktime_t *, void *); +static unsigned long inp_computime (parse_t *, unsigned int, timestamp_t *); clockformat_t clock_computime = { diff -urN src/contrib/ntp/libparse/clk_dcf7000.c src.ntp/contrib/ntp/libparse/clk_dcf7000.c --- src/contrib/ntp/libparse/clk_dcf7000.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libparse/clk_dcf7000.c 2009-12-09 08:36:35.000000000 +0100 @@ -51,7 +51,7 @@ #include #else #include "sys/parsestreams.h" -extern void printf P((const char *, ...)); +extern int printf (const char *, ...); #endif static struct format dcf7000_fmt = @@ -64,8 +64,8 @@ (const unsigned char *)" - - - - - - - \r", 0 }; -static u_long cvt_dcf7000 P((unsigned char *, int, struct format *, clocktime_t *, void *)); -static unsigned long inp_dcf7000 P((parse_t *, unsigned int, timestamp_t *)); +static u_long cvt_dcf7000 (unsigned char *, int, struct format *, clocktime_t *, void *); +static unsigned long inp_dcf7000 (parse_t *, unsigned int, timestamp_t *); clockformat_t clock_dcf7000 = { diff -urN src/contrib/ntp/libparse/clk_hopf6021.c src.ntp/contrib/ntp/libparse/clk_hopf6021.c --- src/contrib/ntp/libparse/clk_hopf6021.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libparse/clk_hopf6021.c 2009-12-09 08:36:36.000000000 +0100 @@ -34,7 +34,7 @@ #include #else #include "sys/parsestreams.h" -extern void printf P((const char *, ...)); +extern int printf (const char *, ...); #endif /* @@ -118,8 +118,8 @@ ('A' <= (x) && (x) <= 'F') ? (x) - 'A' + 10 : \ -1) -static unsigned long cvt_hopf6021 P((unsigned char *, int, struct format *, clocktime_t *, void *)); -static unsigned long inp_hopf6021 P((parse_t *, unsigned int, timestamp_t *)); +static unsigned long cvt_hopf6021 (unsigned char *, int, struct format *, clocktime_t *, void *); +static unsigned long inp_hopf6021 (parse_t *, unsigned int, timestamp_t *); clockformat_t clock_hopf6021 = { diff -urN src/contrib/ntp/libparse/clk_meinberg.c src.ntp/contrib/ntp/libparse/clk_meinberg.c --- src/contrib/ntp/libparse/clk_meinberg.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libparse/clk_meinberg.c 2009-12-09 08:36:37.000000000 +0100 @@ -209,10 +209,10 @@ } }; -static u_long cvt_meinberg P((unsigned char *, int, struct format *, clocktime_t *, void *)); -static u_long cvt_mgps P((unsigned char *, int, struct format *, clocktime_t *, void *)); -static u_long mbg_input P((parse_t *, unsigned int, timestamp_t *)); -static u_long gps_input P((parse_t *, unsigned int, timestamp_t *)); +static u_long cvt_meinberg (unsigned char *, int, struct format *, clocktime_t *, void *); +static u_long cvt_mgps (unsigned char *, int, struct format *, clocktime_t *, void *); +static u_long mbg_input (parse_t *, unsigned int, timestamp_t *); +static u_long gps_input (parse_t *, unsigned int, timestamp_t *); struct msg_buf { diff -urN src/contrib/ntp/libparse/clk_rawdcf.c src.ntp/contrib/ntp/libparse/clk_rawdcf.c --- src/contrib/ntp/libparse/clk_rawdcf.c 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/libparse/clk_rawdcf.c 2009-12-09 08:36:35.000000000 +0100 @@ -101,9 +101,9 @@ * 59 - usually missing (minute indication), except for leap insertion */ -static u_long pps_rawdcf P((parse_t *, int, timestamp_t *)); -static u_long cvt_rawdcf P((unsigned char *, int, struct format *, clocktime_t *, void *)); -static u_long inp_rawdcf P((parse_t *, unsigned int, timestamp_t *)); +static u_long pps_rawdcf (parse_t *, int, timestamp_t *); +static u_long cvt_rawdcf (unsigned char *, int, struct format *, clocktime_t *, void *); +static u_long inp_rawdcf (parse_t *, unsigned int, timestamp_t *); typedef struct last_tcode { time_t tcode; /* last converted time code */ diff -urN src/contrib/ntp/libparse/clk_rcc8000.c src.ntp/contrib/ntp/libparse/clk_rcc8000.c --- src/contrib/ntp/libparse/clk_rcc8000.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libparse/clk_rcc8000.c 2009-12-09 08:36:35.000000000 +0100 @@ -30,7 +30,7 @@ #include #else #include "sys/parsestreams.h" -extern void printf P((const char *, ...)); +extern int printf (const char *, ...); #endif /* Type II Serial Output format @@ -57,8 +57,8 @@ 0 }; -static unsigned long cvt_rcc8000 P((unsigned char *, int, struct format *, clocktime_t *, void *)); -static unsigned long inp_rcc8000 P((parse_t *, unsigned int, timestamp_t *)); +static unsigned long cvt_rcc8000 (unsigned char *, int, struct format *, clocktime_t *, void *); +static unsigned long inp_rcc8000 (parse_t *, unsigned int, timestamp_t *); clockformat_t clock_rcc8000 = { diff -urN src/contrib/ntp/libparse/clk_schmid.c src.ntp/contrib/ntp/libparse/clk_schmid.c --- src/contrib/ntp/libparse/clk_schmid.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libparse/clk_schmid.c 2009-12-09 08:36:35.000000000 +0100 @@ -52,7 +52,7 @@ #include #else #include "sys/parsestreams.h" -extern void printf P((const char *, ...)); +extern int printf (const char *, ...); #endif /* @@ -89,8 +89,8 @@ #define WS_MEST 0x04 #define WS_LEAP 0x10 -static u_long cvt_schmid P((unsigned char *, int, struct format *, clocktime_t *, void *)); -static unsigned long inp_schmid P((parse_t *, unsigned int, timestamp_t *)); +static u_long cvt_schmid (unsigned char *, int, struct format *, clocktime_t *, void *); +static unsigned long inp_schmid (parse_t *, unsigned int, timestamp_t *); clockformat_t clock_schmid = { diff -urN src/contrib/ntp/libparse/clk_trimtaip.c src.ntp/contrib/ntp/libparse/clk_trimtaip.c --- src/contrib/ntp/libparse/clk_trimtaip.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libparse/clk_trimtaip.c 2009-12-09 08:36:35.000000000 +0100 @@ -51,7 +51,7 @@ #include #else #include "sys/parsestreams.h" -extern void printf P((const char *, ...)); +extern int printf (const char *, ...); #endif /* 0000000000111111111122222222223333333 / char @@ -78,8 +78,8 @@ 0 }; -static unsigned long cvt_trimtaip P((unsigned char *, int, struct format *, clocktime_t *, void *)); -static unsigned long inp_trimtaip P((parse_t *, unsigned int, timestamp_t *)); +static unsigned long cvt_trimtaip (unsigned char *, int, struct format *, clocktime_t *, void *); +static unsigned long inp_trimtaip (parse_t *, unsigned int, timestamp_t *); clockformat_t clock_trimtaip = { diff -urN src/contrib/ntp/libparse/clk_trimtsip.c src.ntp/contrib/ntp/libparse/clk_trimtsip.c --- src/contrib/ntp/libparse/clk_trimtsip.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libparse/clk_trimtsip.c 2009-12-09 08:36:35.000000000 +0100 @@ -1,12 +1,12 @@ /* - * /src/NTP/ntp4-dev/libparse/clk_trimtsip.c,v 4.17 2005/04/16 17:32:10 kardel RELEASE_20050508_A + * /src/NTP/REPOSITORY/ntp4-dev/libparse/clk_trimtsip.c,v 4.19 2009/11/01 10:47:49 kardel RELEASE_20091101_A * - * clk_trimtsip.c,v 4.17 2005/04/16 17:32:10 kardel RELEASE_20050508_A + * clk_trimtsip.c,v 4.19 2009/11/01 10:47:49 kardel RELEASE_20091101_A * * Trimble TSIP support * Thanks to Sven Dietrich for providing test hardware * - * Copyright (c) 1995-2005 by Frank Kardel ntp.org> + * Copyright (c) 1995-2009 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 @@ -116,8 +116,8 @@ #define STATUS_UNSAFE 1 /* not enough receivers for full precision */ #define STATUS_SYNC 2 /* enough information for good operation */ -static unsigned long inp_tsip P((parse_t *, unsigned int, timestamp_t *)); -static unsigned long cvt_trimtsip P((unsigned char *, int, struct format *, clocktime_t *, void *)); +static unsigned long inp_tsip (parse_t *, unsigned int, timestamp_t *); +static unsigned long cvt_trimtsip (unsigned char *, int, struct format *, clocktime_t *, void *); struct clockformat clock_trimtsip = { @@ -190,6 +190,7 @@ t->t_in_pkt = t->t_dle = 0; return PARSE_INP_TIME|PARSE_INP_DATA; } + /*FALLTHROUGH*/ default: /* collect data */ t->t_dle = 0; @@ -398,6 +399,12 @@ * History: * * clk_trimtsip.c,v + * Revision 4.19 2009/11/01 10:47:49 kardel + * de-P() + * + * Revision 4.18 2009/11/01 08:46:46 kardel + * clarify case FALLTHROUGH + * * Revision 4.17 2005/04/16 17:32:10 kardel * update copyright * diff -urN src/contrib/ntp/libparse/clk_varitext.c src.ntp/contrib/ntp/libparse/clk_varitext.c --- src/contrib/ntp/libparse/clk_varitext.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libparse/clk_varitext.c 2009-12-09 08:36:36.000000000 +0100 @@ -55,7 +55,7 @@ # include #else # include "sys/parsestreams.h" -extern void printf P((const char *, ...)); +extern int printf (const char *, ...); #endif static const u_char VT_INITIALISED = 0x01; @@ -105,8 +105,8 @@ 0 }; -static u_long cvt_varitext P((unsigned char *, int, struct format *, clocktime_t *, void *)); -static u_long inp_varitext P((parse_t *, unsigned int, timestamp_t *)); +static u_long cvt_varitext (unsigned char *, int, struct format *, clocktime_t *, void *); +static u_long inp_varitext (parse_t *, unsigned int, timestamp_t *); struct varitext { unsigned char start_found; diff -urN src/contrib/ntp/libparse/clk_wharton.c src.ntp/contrib/ntp/libparse/clk_wharton.c --- src/contrib/ntp/libparse/clk_wharton.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libparse/clk_wharton.c 2009-12-09 08:36:36.000000000 +0100 @@ -30,7 +30,7 @@ #include #else #include "sys/parsestreams.h" -extern void printf P((const char *, ...)); +extern void printf (const char *, ...); #endif /* diff -urN src/contrib/ntp/libparse/data_mbg.c src.ntp/contrib/ntp/libparse/data_mbg.c --- src/contrib/ntp/libparse/data_mbg.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libparse/data_mbg.c 2009-12-09 08:36:36.000000000 +0100 @@ -46,8 +46,8 @@ #include "binio.h" #include "ieee754io.h" -static void get_mbg_tzname P((unsigned char **, char *)); -static void mbg_time_status_str P((char **, unsigned int, int)); +static void get_mbg_tzname (unsigned char **, char *); +static void mbg_time_status_str (char **, unsigned int, int); #if 0 /* no actual floats on Meinberg binary interface */ static offsets_t mbg_float = { 1, 0, 3, 2, 0, 0, 0, 0 }; /* byte order for meinberg floats */ diff -urN src/contrib/ntp/libparse/gpstolfp.c src.ntp/contrib/ntp/libparse/gpstolfp.c --- src/contrib/ntp/libparse/gpstolfp.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libparse/gpstolfp.c 2009-12-09 08:36:36.000000000 +0100 @@ -34,7 +34,7 @@ */ #include "ntp_fp.h" -#define GPSORIGIN ULONG_CONST(2524953600) /* NTP origin - GPS origin in seconds */ +#define GPSORIGIN 2524953600UL /* NTP origin - GPS origin in seconds */ #define SECSPERWEEK (unsigned)(604800) /* seconds per week - GPS tells us about weeks */ #define GPSWRAP 990 /* assume week count less than this in the previous epoch */ diff -urN src/contrib/ntp/libparse/ieee754io.c src.ntp/contrib/ntp/libparse/ieee754io.c --- src/contrib/ntp/libparse/ieee754io.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libparse/ieee754io.c 2009-12-09 08:36:36.000000000 +0100 @@ -43,9 +43,9 @@ #include "ntp_fp.h" #include "ieee754io.h" -static unsigned char get_byte P((unsigned char *, offsets_t, int *)); +static unsigned char get_byte (unsigned char *, offsets_t, int *); #ifdef __not_yet__ -static void put_byte P((unsigned char *, offsets_t, int *, unsigned char)); +static void put_byte (unsigned char *, offsets_t, int *, unsigned char); #endif #ifdef LIBDEBUG diff -urN src/contrib/ntp/libparse/parse.c src.ntp/contrib/ntp/libparse/parse.c --- src/contrib/ntp/libparse/parse.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libparse/parse.c 2009-12-09 08:36:36.000000000 +0100 @@ -68,7 +68,7 @@ extern clockformat_t *clockformats[]; extern unsigned short nformats; -static u_long timepacket P((parse_t *)); +static u_long timepacket (parse_t *); /* * strings support usually not in kernel - duplicated, but what the heck @@ -234,7 +234,7 @@ * collect into buffer */ parseprintf(DD_PARSE, ("parse: parse_addchar: buffer[%d] = 0x%x\n", parseio->parse_index, ch)); - parseio->parse_data[parseio->parse_index++] = ch; + parseio->parse_data[parseio->parse_index++] = (char)ch; return PARSE_INP_SKIP; } else diff -urN src/contrib/ntp/libparse/parsesolaris.c src.ntp/contrib/ntp/libparse/parsesolaris.c --- src/contrib/ntp/libparse/parsesolaris.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libparse/parsesolaris.c 2009-12-09 08:36:36.000000000 +0100 @@ -173,11 +173,11 @@ /*--------------- stream module definition ----------------------------*/ -static int parseopen P((queue_t *, dev_t *, int, int, cred_t *)); -static int parseclose P((queue_t *, int)); -static int parsewput P((queue_t *, mblk_t *)); -static int parserput P((queue_t *, mblk_t *)); -static int parsersvc P((queue_t *)); +static int parseopen (queue_t *, dev_t *, int, int, cred_t *); +static int parseclose (queue_t *, int); +static int parsewput (queue_t *, mblk_t *); +static int parserput (queue_t *, mblk_t *); +static int parsersvc (queue_t *); static struct module_info driverinfo = { @@ -244,8 +244,8 @@ }\ } while (0) -static int init_linemon P((queue_t *)); -static void close_linemon P((queue_t *, queue_t *)); +static int init_linemon (queue_t *); +static void close_linemon (queue_t *, queue_t *); #define M_PARSE 0x0001 #define M_NOPARSE 0x0002 @@ -264,7 +264,7 @@ static void pprintf( int lev, - const char *form, + char *form, ... ) { @@ -273,7 +273,7 @@ va_start(ap, form); if (lev & parsedebug) - vcmn_err(CE_CONT, (char *)form, ap); + vcmn_err(CE_CONT, form, ap); va_end(ap); } @@ -641,15 +641,15 @@ register parsestream_t * parse = (parsestream_t *)q->q_ptr; register mblk_t *nmp; register unsigned long ch; - timestamp_t ctime; + timestamp_t c_time; timespec_t hres_time; /* * get time on packet delivery */ gethrestime(&hres_time); - ctime.tv.tv_sec = hres_time.tv_sec; - ctime.tv.tv_usec = hres_time.tv_nsec / 1000; + c_time.tv.tv_sec = hres_time.tv_sec; + c_time.tv.tv_usec = hres_time.tv_nsec / 1000; if (!(parse->parse_status & PARSE_ENABLE)) { @@ -672,7 +672,7 @@ while (mp != (mblk_t *)NULL) { ch = rdchar(&mp); - if (ch != ~0 && parse_ioread(&parse->parse_io, (unsigned int)ch, &ctime)) + if (ch != ~0 && parse_ioread(&parse->parse_io, (unsigned int)ch, &c_time)) { /* * up up and away (hopefully ...) @@ -693,7 +693,7 @@ } else { - if (parse_ioread(&parse->parse_io, (unsigned int)0, &ctime)) + if (parse_ioread(&parse->parse_io, (unsigned int)0, &c_time)) { /* * up up and away (hopefully ...) @@ -723,19 +723,19 @@ case M_UNHANGUP: { register parsestream_t * parse = (parsestream_t *)q->q_ptr; - timestamp_t ctime; + timestamp_t c_time; timespec_t hres_time; register mblk_t *nmp; register int status = cd_invert ^ (type == M_UNHANGUP); gethrestime(&hres_time); - ctime.tv.tv_sec = hres_time.tv_sec; - ctime.tv.tv_usec = hres_time.tv_nsec / 1000; + c_time.tv.tv_sec = hres_time.tv_sec; + c_time.tv.tv_usec = hres_time.tv_nsec / 1000; pprintf(DD_RPUT, "parse: parserput - M_%sHANGUP\n", (type == M_HANGUP) ? "" : "UN"); if ((parse->parse_status & PARSE_ENABLE) && - parse_iopps(&parse->parse_io, status ? SYNC_ONE : SYNC_ZERO, &ctime)) + parse_iopps(&parse->parse_io, status ? SYNC_ONE : SYNC_ZERO, &c_time)) { nmp = (mblk_t *)NULL; if (canputnext(parse->parse_queue) && (nmp = allocb(sizeof(parsetime_t), BPRI_MED))) @@ -759,7 +759,7 @@ if (status) { - parse->parse_ppsclockev.tv = ctime.tv; + parse->parse_ppsclockev.tv = c_time.tv; ++(parse->parse_ppsclockev.serial); } } @@ -767,8 +767,8 @@ return 0; } -static int init_zs_linemon P((queue_t *, queue_t *)); /* handle line monitor for "zs" driver */ -static void close_zs_linemon P((queue_t *, queue_t *)); +static int init_zs_linemon (queue_t *, queue_t *); /* handle line monitor for "zs" driver */ +static void close_zs_linemon (queue_t *, queue_t *); /*-------------------- CD isr status monitor ---------------*/ @@ -849,7 +849,7 @@ #include #include -static void zs_xsisr P((struct zscom *)); /* zs external status interupt handler */ +static void zs_xsisr (struct zscom *); /* zs external status interupt handler */ /* * there should be some docs telling how to get to @@ -911,7 +911,7 @@ parsestream->parse_dqueue = q; /* remember driver */ szs->zsops = *zs->zs_ops; - szs->zsops.zsop_xsint = (void (*) P((struct zscom *)))zs_xsisr; /* place our bastard */ + szs->zsops.zsop_xsint = (void (*) (struct zscom *))zs_xsisr; /* place our bastard */ szs->oldzsops = zs->zs_ops; emergencyzs = zs->zs_ops; @@ -920,7 +920,7 @@ * XXX: this is usually done via zsopinit() * - have yet to find a way to call that routine */ - zs->zs_xsint = (void (*) P((struct zscom *)))zs_xsisr; + zs->zs_xsint = (void (*) (struct zscom *))zs_xsisr; mutex_exit(zs->zs_excl); @@ -1117,7 +1117,7 @@ dname = q->q_qinfo->qi_minfo->mi_idname; if (!strcmp(dname, parseinfo.st_rdinit->qi_minfo->mi_idname)) { - register void (*zsisr) P((struct zscom *)); + register void (*zsisr) (struct zscom *); /* * back home - phew (hopping along stream queues might diff -urN src/contrib/ntp/libparse/parsestreams.c src.ntp/contrib/ntp/libparse/parsestreams.c --- src/contrib/ntp/libparse/parsestreams.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/libparse/parsestreams.c 2009-12-09 08:36:35.000000000 +0100 @@ -77,15 +77,15 @@ /* * just make checking compilers more silent */ -extern int printf P((const char *, ...)); -extern int putctl1 P((queue_t *, int, int)); -extern int canput P((queue_t *)); -extern void putbq P((queue_t *, mblk_t *)); -extern void freeb P((mblk_t *)); -extern void qreply P((queue_t *, mblk_t *)); -extern void freemsg P((mblk_t *)); -extern void panic P((const char *, ...)); -extern void usec_delay P((int)); +extern int printf (const char *, ...); +extern int putctl1 (queue_t *, int, int); +extern int canput (queue_t *); +extern void putbq (queue_t *, mblk_t *); +extern void freeb (mblk_t *); +extern void qreply (queue_t *, mblk_t *); +extern void freemsg (mblk_t *); +extern void panic (const char *, ...); +extern void usec_delay (int); #include "parse.h" #include "sys/parsestreams.h" @@ -357,11 +357,11 @@ /*--------------- stream module definition ----------------------------*/ -static int parseopen P((queue_t *, dev_t, int, int)); -static int parseclose P((queue_t *, int)); -static int parsewput P((queue_t *, mblk_t *)); -static int parserput P((queue_t *, mblk_t *)); -static int parsersvc P((queue_t *)); +static int parseopen (queue_t *, dev_t, int, int); +static int parseclose (queue_t *, int); +static int parsewput (queue_t *, mblk_t *); +static int parserput (queue_t *, mblk_t *); +static int parsersvc (queue_t *); static char mn[] = "parse"; @@ -416,7 +416,7 @@ int parsedebug = ~0; -extern void uniqtime P((struct timeval *)); +extern void uniqtime (struct timeval *); /*--------------- module implementation -----------------------------*/ @@ -429,8 +429,8 @@ }\ } while (0) -static int init_linemon P((queue_t *)); -static void close_linemon P((queue_t *, queue_t *)); +static int init_linemon (queue_t *); +static void close_linemon (queue_t *, queue_t *); #define M_PARSE 0x0001 #define M_NOPARSE 0x0002 @@ -919,8 +919,8 @@ return 0; } -static int init_zs_linemon P((queue_t *, queue_t *)); /* handle line monitor for "zs" driver */ -static void close_zs_linemon P((queue_t *, queue_t *)); +static int init_zs_linemon (queue_t *, queue_t *); /* handle line monitor for "zs" driver */ +static void close_zs_linemon (queue_t *, queue_t *); /*-------------------- CD isr status monitor ---------------*/ @@ -1010,8 +1010,8 @@ }; struct zsops *emergencyzs; -extern void zsopinit P((struct zscom *, struct zsops *)); -static int zs_xsisr P((struct zscom *)); /* zs external status interupt handler */ +extern void zsopinit (struct zscom *, struct zsops *); +static int zs_xsisr (struct zscom *); /* zs external status interupt handler */ static int init_zs_linemon( @@ -1112,7 +1112,7 @@ #define MAXDEPTH 50 /* maximum allowed stream crawl */ #ifdef PPS_SYNC -extern void hardpps P((struct timeval *, long)); +extern void hardpps (struct timeval *, long); #ifdef PPS_NEW extern struct timeval timestamp; #else @@ -1282,7 +1282,7 @@ dname = q->q_qinfo->qi_minfo->mi_idname; if (!Strcmp(dname, parseinfo.st_rdinit->qi_minfo->mi_idname)) { - register int (*zsisr) P((struct zscom *)); + register int (*zsisr) (struct zscom *); /* * back home - phew (hopping along stream queues might diff -urN src/contrib/ntp/ltmain.sh src.ntp/contrib/ntp/ltmain.sh --- src/contrib/ntp/ltmain.sh 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ltmain.sh 2005-09-24 03:15:44.000000000 +0200 @@ -43,8 +43,8 @@ PROGRAM=ltmain.sh PACKAGE=libtool -VERSION=1.5.22 -TIMESTAMP=" (1.1220.2.365 2005/12/18 22:14:06)" +VERSION=1.5.20 +TIMESTAMP=" (1.1220.2.287 2005/08/31 18:54:15)" # See if we are running on zsh, and set the options which allow our # commands through without removal of \ escapes. @@ -132,8 +132,6 @@ show="$echo" show_help= execute_dlfiles= -duplicate_deps=no -preserve_args= lo2o="s/\\.lo\$/.${objext}/" o2lo="s/\\.${objext}\$/.lo/" @@ -141,43 +139,6 @@ # Shell function definitions: # This seems to be the best place for them -# func_mktempdir [string] -# Make a temporary directory that won't clash with other running -# libtool processes, and avoids race conditions if possible. If -# given, STRING is the basename for that directory. -func_mktempdir () -{ - my_template="${TMPDIR-/tmp}/${1-$progname}" - - if test "$run" = ":"; then - # Return a directory name, but don't create it in dry-run mode - my_tmpdir="${my_template}-$$" - else - - # If mktemp works, use that first and foremost - my_tmpdir=`mktemp -d "${my_template}-XXXXXXXX" 2>/dev/null` - - if test ! -d "$my_tmpdir"; then - # Failing that, at least try and use $RANDOM to avoid a race - my_tmpdir="${my_template}-${RANDOM-0}$$" - - save_mktempdir_umask=`umask` - umask 0077 - $mkdir "$my_tmpdir" - umask $save_mktempdir_umask - fi - - # If we're not in dry-run mode, bomb out on failure - test -d "$my_tmpdir" || { - $echo "cannot create temporary directory \`$my_tmpdir'" 1>&2 - exit $EXIT_FAILURE - } - fi - - $echo "X$my_tmpdir" | $Xsed -} - - # func_win32_libid arg # return the library type of file 'arg' # @@ -196,11 +157,12 @@ if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null | \ $EGREP -e 'file format pe-i386(.*architecture: i386)?' >/dev/null ; then win32_nmres=`eval $NM -f posix -A $1 | \ - $SED -n -e '1,100{/ I /{s,.*,import,;p;q;};}'` - case $win32_nmres in - import*) win32_libid_type="x86 archive import";; - *) win32_libid_type="x86 archive static";; - esac + sed -n -e '1,100{/ I /{x;/import/!{s/^/import/;h;p;};x;};}'` + if test "X$win32_nmres" = "Ximport" ; then + win32_libid_type="x86 archive import" + else + win32_libid_type="x86 archive static" + fi fi ;; *DLL*) @@ -333,9 +295,9 @@ $run ${rm}r "$my_xdir" $show "$mkdir $my_xdir" $run $mkdir "$my_xdir" - exit_status=$? - if test "$exit_status" -ne 0 && test ! -d "$my_xdir"; then - exit $exit_status + status=$? + if test "$status" -ne 0 && test ! -d "$my_xdir"; then + exit $status fi case $host in *-darwin*) @@ -390,8 +352,6 @@ # Darwin sucks eval std_shrext=\"$shrext_cmds\" -disable_libs=no - # Parse our command line options once, thoroughly. while test "$#" -gt 0 do @@ -508,11 +468,7 @@ preserve_args="$preserve_args $arg" ;; - --tag) - prevopt="--tag" - prev=tag - preserve_args="$preserve_args --tag" - ;; + --tag) prevopt="--tag" prev=tag ;; --tag=*) set tag "$optarg" ${1+"$@"} shift @@ -544,18 +500,6 @@ exit $EXIT_FAILURE fi -case $disable_libs in -no) - ;; -shared) - build_libtool_libs=no - build_old_libs=yes - ;; -static) - build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac` - ;; -esac - # If this variable is set in any of the actions, the command in it # will be execed at the end. This prevents here-documents from being # left over by shells. @@ -912,9 +856,9 @@ if test ! -d "${xdir}$objdir"; then $show "$mkdir ${xdir}$objdir" $run $mkdir ${xdir}$objdir - exit_status=$? - if test "$exit_status" -ne 0 && test ! -d "${xdir}$objdir"; then - exit $exit_status + status=$? + if test "$status" -ne 0 && test ! -d "${xdir}$objdir"; then + exit $status fi fi @@ -1117,7 +1061,6 @@ no_install=no objs= non_pic_objects= - notinst_path= # paths that contain not-installed libtool libraries precious_files_regex= prefer_static_libs=no preload=no @@ -1146,15 +1089,14 @@ if test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi - prefer_static_libs=yes else if test -z "$pic_flag" && test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi - prefer_static_libs=built fi build_libtool_libs=no build_old_libs=yes + prefer_static_libs=yes break ;; esac @@ -1329,11 +1271,6 @@ if test -z "$pic_object" || test "$pic_object" = none ; then arg="$non_pic_object" fi - else - # If the PIC object exists, use it instead. - # $xdir was prepended to $pic_object above. - non_pic_object="$pic_object" - non_pic_objects="$non_pic_objects $non_pic_object" fi else # Only an error if not doing a dry-run. @@ -1417,8 +1354,8 @@ prev= continue ;; - darwin_framework|darwin_framework_skip) - test "$prev" = "darwin_framework" && compiler_flags="$compiler_flags $arg" + darwin_framework) + compiler_flags="$compiler_flags $arg" compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" prev= @@ -1482,17 +1419,13 @@ continue ;; - -framework|-arch|-isysroot) - case " $CC " in - *" ${arg} ${1} "* | *" ${arg} ${1} "*) - prev=darwin_framework_skip ;; - *) compiler_flags="$compiler_flags $arg" - prev=darwin_framework ;; - esac + -framework|-arch) + prev=darwin_framework + compiler_flags="$compiler_flags $arg" compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" - continue - ;; + continue + ;; -inst-prefix-dir) prev=inst_prefix @@ -1520,8 +1453,7 @@ absdir=`cd "$dir" && pwd` if test -z "$absdir"; then $echo "$modename: cannot determine absolute directory name of \`$dir'" 1>&2 - absdir="$dir" - notinst_path="$notinst_path $dir" + exit $EXIT_FAILURE fi dir="$absdir" ;; @@ -1535,15 +1467,10 @@ esac case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*) - testbindir=`$echo "X$dir" | $Xsed -e 's*/lib$*/bin*'` case :$dllsearchpath: in *":$dir:"*) ;; *) dllsearchpath="$dllsearchpath:$dir";; esac - case :$dllsearchpath: in - *":$testbindir:"*) ;; - *) dllsearchpath="$dllsearchpath:$testbindir";; - esac ;; esac continue @@ -1552,11 +1479,11 @@ -l*) if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos*) + *-*-cygwin* | *-*-pw32* | *-*-beos*) # These systems don't actually have a C or math library (as such) continue ;; - *-*-os2*) + *-*-mingw* | *-*-os2*) # These systems don't actually have a C library (as such) test "X$arg" = "X-lc" && continue ;; @@ -1568,15 +1495,6 @@ # Rhapsody C and math libraries are in the System framework deplibs="$deplibs -framework System" continue - ;; - *-*-sco3.2v5* | *-*-sco5v6*) - # Causes problems with __ctype - test "X$arg" = "X-lc" && continue - ;; - *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) - # Compiler inserts libc in the correct place for threads to work - test "X$arg" = "X-lc" && continue - ;; esac elif test "X$arg" = "X-lc_r"; then case $host in @@ -1618,12 +1536,7 @@ # +DA*, +DD* enable 64-bit mode on the HP compiler # -q* pass through compiler args for the IBM compiler # -m* pass through architecture-specific compiler args for GCC - # -m*, -t[45]*, -txscale* pass through architecture-specific - # compiler args for GCC - # -pg pass through profiling flag for GCC - # @file GCC response files - -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*|-pg| \ - -t[45]*|-txscale*|@*) + -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*) # Unknown arguments in both finalize_command and compile_command need # to be aesthetically quoted because they are evaled later. @@ -1635,7 +1548,9 @@ esac compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" - compiler_flags="$compiler_flags $arg" + if test "$with_gcc" = "yes" ; then + compiler_flags="$compiler_flags $arg" + fi continue ;; @@ -1873,11 +1788,6 @@ if test -z "$pic_object" || test "$pic_object" = none ; then arg="$non_pic_object" fi - else - # If the PIC object exists, use it instead. - # $xdir was prepended to $pic_object above. - non_pic_object="$pic_object" - non_pic_objects="$non_pic_objects $non_pic_object" fi else # Only an error if not doing a dry-run. @@ -1983,9 +1893,9 @@ if test ! -d "$output_objdir"; then $show "$mkdir $output_objdir" $run $mkdir $output_objdir - exit_status=$? - if test "$exit_status" -ne 0 && test ! -d "$output_objdir"; then - exit $exit_status + status=$? + if test "$status" -ne 0 && test ! -d "$output_objdir"; then + exit $status fi fi @@ -2048,6 +1958,7 @@ newlib_search_path= need_relink=no # whether we're linking any uninstalled libtool libraries notinst_deplibs= # not-installed libtool libraries + notinst_path= # paths that contain not-installed libtool libraries case $linkmode in lib) passes="conv link" @@ -2283,7 +2194,7 @@ esac # case $deplib if test "$found" = yes || test -f "$lib"; then : else - $echo "$modename: cannot find the library \`$lib' or unhandled argument \`$deplib'" 1>&2 + $echo "$modename: cannot find the library \`$lib'" 1>&2 exit $EXIT_FAILURE fi @@ -2534,12 +2445,8 @@ fi link_static=no # Whether the deplib will be linked statically - use_static_libs=$prefer_static_libs - if test "$use_static_libs" = built && test "$installed" = yes ; then - use_static_libs=no - fi if test -n "$library_names" && - { test "$use_static_libs" = no || test -z "$old_library"; }; then + { test "$prefer_static_libs" = no || test -z "$old_library"; }; then if test "$installed" = no; then notinst_deplibs="$notinst_deplibs $lib" need_relink=yes @@ -2652,15 +2559,11 @@ if test "$hardcode_direct" = no; then add="$dir/$linklib" case $host in - *-*-sco3.2v5.0.[024]*) add_dir="-L$dir" ;; - *-*-sysv4*uw2*) add_dir="-L$dir" ;; - *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \ - *-*-unixware7*) add_dir="-L$dir" ;; + *-*-sco3.2v5* ) add_dir="-L$dir" ;; *-*-darwin* ) # if the lib is a module then we can not link against # it, someone is ignoring the new warnings I added - if /usr/bin/file -L $add 2> /dev/null | - $EGREP ": [^:]* bundle" >/dev/null ; then + if /usr/bin/file -L $add 2> /dev/null | $EGREP "bundle" >/dev/null ; then $echo "** Warning, lib $linklib is a module, not a shared library" if test -z "$old_library" ; then $echo @@ -3411,9 +3314,9 @@ # Eliminate all temporary directories. for path in $notinst_path; do - lib_search_path=`$echo "$lib_search_path " | ${SED} -e "s% $path % %g"` - deplibs=`$echo "$deplibs " | ${SED} -e "s% -L$path % %g"` - dependency_libs=`$echo "$dependency_libs " | ${SED} -e "s% -L$path % %g"` + lib_search_path=`$echo "$lib_search_path " | ${SED} -e 's% $path % %g'` + deplibs=`$echo "$deplibs " | ${SED} -e 's% -L$path % %g'` + dependency_libs=`$echo "$dependency_libs " | ${SED} -e 's% -L$path % %g'` done if test -n "$xrpath"; then @@ -3466,12 +3369,7 @@ ;; *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) # Do not include libc due to us having libc/libc_r. - ;; - *-*-sco3.2v5* | *-*-sco5v6*) - # Causes problems with __ctype - ;; - *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) - # Compiler inserts libc in the correct place for threads to work + test "X$arg" = "X-lc" && continue ;; *) # Add libc to deplibs on all other systems if necessary. @@ -3515,7 +3413,7 @@ int main() { return 0; } EOF $rm conftest - $LTCC $LTCFLAGS -o conftest conftest.c $deplibs + $LTCC -o conftest conftest.c $deplibs if test "$?" -eq 0 ; then ldd_output=`ldd conftest` for i in $deplibs; do @@ -3560,7 +3458,7 @@ # If $name is empty we are operating on a -L argument. if test "$name" != "" && test "$name" != "0"; then $rm conftest - $LTCC $LTCFLAGS -o conftest conftest.c $i + $LTCC -o conftest conftest.c $i # Did it work? if test "$?" -eq 0 ; then ldd_output=`ldd conftest` @@ -3807,35 +3705,6 @@ deplibs=$newdeplibs fi - - # move library search paths that coincide with paths to not yet - # installed libraries to the beginning of the library search list - new_libs= - for path in $notinst_path; do - case " $new_libs " in - *" -L$path/$objdir "*) ;; - *) - case " $deplibs " in - *" -L$path/$objdir "*) - new_libs="$new_libs -L$path/$objdir" ;; - esac - ;; - esac - done - for deplib in $deplibs; do - case $deplib in - -L*) - case " $new_libs " in - *" $deplib "*) ;; - *) new_libs="$new_libs $deplib" ;; - esac - ;; - *) new_libs="$new_libs $deplib" ;; - esac - done - deplibs="$new_libs" - - # All the library-specific variables (install_libdir is set above). library_names= old_library= @@ -3919,7 +3788,6 @@ fi lib="$output_objdir/$realname" - linknames= for link do linknames="$linknames $link" @@ -4351,35 +4219,6 @@ ;; esac - - # move library search paths that coincide with paths to not yet - # installed libraries to the beginning of the library search list - new_libs= - for path in $notinst_path; do - case " $new_libs " in - *" -L$path/$objdir "*) ;; - *) - case " $compile_deplibs " in - *" -L$path/$objdir "*) - new_libs="$new_libs -L$path/$objdir" ;; - esac - ;; - esac - done - for deplib in $compile_deplibs; do - case $deplib in - -L*) - case " $new_libs " in - *" $deplib "*) ;; - *) new_libs="$new_libs $deplib" ;; - esac - ;; - *) new_libs="$new_libs $deplib" ;; - esac - done - compile_deplibs="$new_libs" - - compile_command="$compile_command $compile_deplibs" finalize_command="$finalize_command $finalize_deplibs" @@ -4424,15 +4263,10 @@ fi case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*) - testbindir=`$echo "X$libdir" | $Xsed -e 's*/lib$*/bin*'` case :$dllsearchpath: in *":$libdir:"*) ;; *) dllsearchpath="$dllsearchpath:$libdir";; esac - case :$dllsearchpath: in - *":$testbindir:"*) ;; - *) dllsearchpath="$dllsearchpath:$testbindir";; - esac ;; esac done @@ -4549,22 +4383,10 @@ export_symbols="$output_objdir/$outputname.exp" $run $rm $export_symbols $run eval "${SED} -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"' - case $host in - *cygwin* | *mingw* ) - $run eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' - $run eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"' - ;; - esac else - $run eval "${SED} -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"' + $run eval "${SED} -e 's/\([ ][.*^$]\)/\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"' $run eval 'grep -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T' $run eval 'mv "$nlist"T "$nlist"' - case $host in - *cygwin* | *mingw* ) - $run eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' - $run eval 'cat "$nlist" >> "$output_objdir/$outputname.def"' - ;; - esac fi fi @@ -4681,29 +4503,16 @@ esac # Now compile the dynamic symbol file. - $show "(cd $output_objdir && $LTCC $LTCFLAGS -c$no_builtin_flag$pic_flag_for_symtable \"$dlsyms\")" - $run eval '(cd $output_objdir && $LTCC $LTCFLAGS -c$no_builtin_flag$pic_flag_for_symtable "$dlsyms")' || exit $? + $show "(cd $output_objdir && $LTCC -c$no_builtin_flag$pic_flag_for_symtable \"$dlsyms\")" + $run eval '(cd $output_objdir && $LTCC -c$no_builtin_flag$pic_flag_for_symtable "$dlsyms")' || exit $? # Clean up the generated files. $show "$rm $output_objdir/$dlsyms $nlist ${nlist}S ${nlist}T" $run $rm "$output_objdir/$dlsyms" "$nlist" "${nlist}S" "${nlist}T" # Transform the symbol file into the correct name. - case $host in - *cygwin* | *mingw* ) - if test -f "$output_objdir/${outputname}.def" ; then - compile_command=`$echo "X$compile_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}.def $output_objdir/${outputname}S.${objext}%"` - finalize_command=`$echo "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}.def $output_objdir/${outputname}S.${objext}%"` - else - compile_command=`$echo "X$compile_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%"` - finalize_command=`$echo "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%"` - fi - ;; - * ) - compile_command=`$echo "X$compile_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%"` - finalize_command=`$echo "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%"` - ;; - esac + compile_command=`$echo "X$compile_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%"` + finalize_command=`$echo "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%"` ;; *) $echo "$modename: unknown suffix for \`$dlsyms'" 1>&2 @@ -4728,7 +4537,7 @@ # We have no uninstalled library dependencies, so finalize right now. $show "$link_command" $run eval "$link_command" - exit_status=$? + status=$? # Delete the generated files. if test -n "$dlsyms"; then @@ -4736,7 +4545,7 @@ $run $rm "$output_objdir/${outputname}S.${objext}" fi - exit $exit_status + exit $status fi if test -n "$shlibpath_var"; then @@ -4876,12 +4685,10 @@ esac case $host in *cygwin* | *mingw* ) - output_name=`basename $output` - output_path=`dirname $output` - cwrappersource="$output_path/$objdir/lt-$output_name.c" - cwrapper="$output_path/$output_name.exe" - $rm $cwrappersource $cwrapper - trap "$rm $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15 + cwrappersource=`$echo ${objdir}/lt-${outputname}.c` + cwrapper=`$echo ${output}.exe` + $rm $cwrappersource $cwrapper + trap "$rm $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15 cat > $cwrappersource < #include #include -#include -#include -#include #if defined(PATH_MAX) # define LT_PATHMAX PATH_MAX @@ -4919,19 +4723,15 @@ #endif #ifndef DIR_SEPARATOR -# define DIR_SEPARATOR '/' -# define PATH_SEPARATOR ':' +#define DIR_SEPARATOR '/' #endif #if defined (_WIN32) || defined (__MSDOS__) || defined (__DJGPP__) || \ defined (__OS2__) -# define HAVE_DOS_BASED_FILE_SYSTEM -# ifndef DIR_SEPARATOR_2 -# define DIR_SEPARATOR_2 '\\' -# endif -# ifndef PATH_SEPARATOR_2 -# define PATH_SEPARATOR_2 ';' -# endif +#define HAVE_DOS_BASED_FILE_SYSTEM +#ifndef DIR_SEPARATOR_2 +#define DIR_SEPARATOR_2 '\\' +#endif #endif #ifndef DIR_SEPARATOR_2 @@ -4941,32 +4741,17 @@ (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2)) #endif /* DIR_SEPARATOR_2 */ -#ifndef PATH_SEPARATOR_2 -# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR) -#else /* PATH_SEPARATOR_2 */ -# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2) -#endif /* PATH_SEPARATOR_2 */ - #define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type))) #define XFREE(stale) do { \ if (stale) { free ((void *) stale); stale = 0; } \ } while (0) -/* -DDEBUG is fairly common in CFLAGS. */ -#undef DEBUG -#if defined DEBUGWRAPPER -# define DEBUG(format, ...) fprintf(stderr, format, __VA_ARGS__) -#else -# define DEBUG(format, ...) -#endif - const char *program_name = NULL; void * xmalloc (size_t num); char * xstrdup (const char *string); -const char * base_name (const char *name); -char * find_executable(const char *wrapper); -int check_executable(const char *path); +char * basename (const char *name); +char * fnqualify(const char *path); char * strendzap(char *str, const char *pat); void lt_fatal (const char *message, ...); @@ -4976,50 +4761,29 @@ char **newargz; int i; - program_name = (char *) xstrdup (base_name (argv[0])); - DEBUG("(main) argv[0] : %s\n",argv[0]); - DEBUG("(main) program_name : %s\n",program_name); + program_name = (char *) xstrdup ((char *) basename (argv[0])); newargz = XMALLOC(char *, argc+2); EOF - cat >> $cwrappersource <> $cwrappersource <> $cwrappersource <<"EOF" - newargz[1] = find_executable(argv[0]); - if (newargz[1] == NULL) - lt_fatal("Couldn't find %s", argv[0]); - DEBUG("(main) found exe at : %s\n",newargz[1]); + cat >> $cwrappersource <<"EOF" + newargz[1] = fnqualify(argv[0]); /* we know the script has the same name, without the .exe */ /* so make sure newargz[1] doesn't end in .exe */ strendzap(newargz[1],".exe"); for (i = 1; i < argc; i++) newargz[i+1] = xstrdup(argv[i]); newargz[argc+1] = NULL; - - for (i=0; i> $cwrappersource <> $cwrappersource <> $cwrappersource <> $cwrappersource <<"EOF" + cat >> $cwrappersource <<"EOF" return 127; } @@ -5040,148 +4804,48 @@ ; } -const char * -base_name (const char *name) +char * +basename (const char *name) { const char *base; #if defined (HAVE_DOS_BASED_FILE_SYSTEM) /* Skip over the disk name in MSDOS pathnames. */ - if (isalpha ((unsigned char)name[0]) && name[1] == ':') + if (isalpha (name[0]) && name[1] == ':') name += 2; #endif for (base = name; *name; name++) if (IS_DIR_SEPARATOR (*name)) base = name + 1; - return base; + return (char *) base; } -int -check_executable(const char * path) -{ - struct stat st; - - DEBUG("(check_executable) : %s\n", path ? (*path ? path : "EMPTY!") : "NULL!"); - if ((!path) || (!*path)) - return 0; - - if ((stat (path, &st) >= 0) && - ( - /* MinGW & native WIN32 do not support S_IXOTH or S_IXGRP */ -#if defined (S_IXOTH) - ((st.st_mode & S_IXOTH) == S_IXOTH) || -#endif -#if defined (S_IXGRP) - ((st.st_mode & S_IXGRP) == S_IXGRP) || -#endif - ((st.st_mode & S_IXUSR) == S_IXUSR)) - ) - return 1; - else - return 0; -} - -/* Searches for the full path of the wrapper. Returns - newly allocated full path name if found, NULL otherwise */ char * -find_executable (const char* wrapper) +fnqualify(const char *path) { - int has_slash = 0; - const char* p; - const char* p_next; - /* static buffer for getcwd */ + size_t size; + char *p; char tmp[LT_PATHMAX + 1]; - int tmp_len; - char* concat_name; - - DEBUG("(find_executable) : %s\n", wrapper ? (*wrapper ? wrapper : "EMPTY!") : "NULL!"); - if ((wrapper == NULL) || (*wrapper == '\0')) - return NULL; + assert(path != NULL); - /* Absolute path? */ -#if defined (HAVE_DOS_BASED_FILE_SYSTEM) - if (isalpha ((unsigned char)wrapper[0]) && wrapper[1] == ':') - { - concat_name = xstrdup (wrapper); - if (check_executable(concat_name)) - return concat_name; - XFREE(concat_name); - } - else - { -#endif - if (IS_DIR_SEPARATOR (wrapper[0])) - { - concat_name = xstrdup (wrapper); - if (check_executable(concat_name)) - return concat_name; - XFREE(concat_name); - } + /* Is it qualified already? */ #if defined (HAVE_DOS_BASED_FILE_SYSTEM) - } + if (isalpha (path[0]) && path[1] == ':') + return xstrdup (path); #endif + if (IS_DIR_SEPARATOR (path[0])) + return xstrdup (path); - for (p = wrapper; *p; p++) - if (*p == '/') - { - has_slash = 1; - break; - } - if (!has_slash) - { - /* no slashes; search PATH */ - const char* path = getenv ("PATH"); - if (path != NULL) - { - for (p = path; *p; p = p_next) - { - const char* q; - size_t p_len; - for (q = p; *q; q++) - if (IS_PATH_SEPARATOR(*q)) - break; - p_len = q - p; - p_next = (*q == '\0' ? q : q + 1); - if (p_len == 0) - { - /* empty path: current directory */ - if (getcwd (tmp, LT_PATHMAX) == NULL) - lt_fatal ("getcwd failed"); - tmp_len = strlen(tmp); - concat_name = XMALLOC(char, tmp_len + 1 + strlen(wrapper) + 1); - memcpy (concat_name, tmp, tmp_len); - concat_name[tmp_len] = '/'; - strcpy (concat_name + tmp_len + 1, wrapper); - } - else - { - concat_name = XMALLOC(char, p_len + 1 + strlen(wrapper) + 1); - memcpy (concat_name, p, p_len); - concat_name[p_len] = '/'; - strcpy (concat_name + p_len + 1, wrapper); - } - if (check_executable(concat_name)) - return concat_name; - XFREE(concat_name); - } - } - /* not found in PATH; assume curdir */ - } - /* Relative path | not found in path: prepend cwd */ + /* prepend the current directory */ + /* doesn't handle '~' */ if (getcwd (tmp, LT_PATHMAX) == NULL) lt_fatal ("getcwd failed"); - tmp_len = strlen(tmp); - concat_name = XMALLOC(char, tmp_len + 1 + strlen(wrapper) + 1); - memcpy (concat_name, tmp, tmp_len); - concat_name[tmp_len] = '/'; - strcpy (concat_name + tmp_len + 1, wrapper); - - if (check_executable(concat_name)) - return concat_name; - XFREE(concat_name); - return NULL; + size = strlen(tmp) + 1 + strlen(path) + 1; /* +2 for '/' and '\0' */ + p = XMALLOC(char, size); + sprintf(p, "%s%c%s", tmp, DIR_SEPARATOR, path); + return p; } char * @@ -5225,16 +4889,16 @@ va_end (ap); } EOF - # we should really use a build-platform specific compiler - # here, but OTOH, the wrappers (shell script and this C one) - # are only useful if you want to execute the "real" binary. - # Since the "real" binary is built for $host, then this - # wrapper might as well be built for $host, too. - $run $LTCC $LTCFLAGS -s -o $cwrapper $cwrappersource - ;; - esac - $rm $output - trap "$rm $output; exit $EXIT_FAILURE" 1 2 15 + # we should really use a build-platform specific compiler + # here, but OTOH, the wrappers (shell script and this C one) + # are only useful if you want to execute the "real" binary. + # Since the "real" binary is built for $host, then this + # wrapper might as well be built for $host, too. + $run $LTCC -s -o $cwrapper $cwrappersource + ;; + esac + $rm $output + trap "$rm $output; exit $EXIT_FAILURE" 1 2 15 $echo > $output "\ #! $SHELL @@ -5464,9 +5128,9 @@ $run ${rm}r "$gentop" $show "$mkdir $gentop" $run $mkdir "$gentop" - exit_status=$? - if test "$exit_status" -ne 0 && test ! -d "$gentop"; then - exit $exit_status + status=$? + if test "$status" -ne 0 && test ! -d "$gentop"; then + exit $status fi fi @@ -6133,7 +5797,18 @@ outputname= if test "$fast_install" = no && test -n "$relink_command"; then if test "$finalize" = yes && test -z "$run"; then - tmpdir=`func_mktempdir` + tmpdir="/tmp" + test -n "$TMPDIR" && tmpdir="$TMPDIR" + tmpdir="$tmpdir/libtool-$$" + save_umask=`umask` + umask 0077 + if $mkdir "$tmpdir"; then + umask $save_umask + else + umask $save_umask + $echo "$modename: error: cannot create temporary directory \`$tmpdir'" 1>&2 + continue + fi file=`$echo "X$file$stripped_ext" | $Xsed -e 's%^.*/%%'` outputname="$tmpdir/$file" # Replace the output file specification. @@ -6257,7 +5932,7 @@ # Exit here if they wanted silent mode. test "$show" = : && exit $EXIT_SUCCESS - $echo "X----------------------------------------------------------------------" | $Xsed + $echo "----------------------------------------------------------------------" $echo "Libraries have been installed in:" for libdir in $libdirs; do $echo " $libdir" @@ -6290,7 +5965,7 @@ $echo $echo "See any operating system documentation about shared libraries for" $echo "more information, such as the ld(1) and ld.so(8) manual pages." - $echo "X----------------------------------------------------------------------" | $Xsed + $echo "----------------------------------------------------------------------" exit $EXIT_SUCCESS ;; @@ -6507,17 +6182,9 @@ rmfiles="$rmfiles $objdir/$n" done test -n "$old_library" && rmfiles="$rmfiles $objdir/$old_library" + test "$mode" = clean && rmfiles="$rmfiles $objdir/$name $objdir/${name}i" - case "$mode" in - clean) - case " $library_names " in - # " " in the beginning catches empty $dlname - *" $dlname "*) ;; - *) rmfiles="$rmfiles $objdir/$dlname" ;; - esac - test -n "$libdir" && rmfiles="$rmfiles $objdir/$name $objdir/${name}i" - ;; - uninstall) + if test "$mode" = uninstall; then if test -n "$library_names"; then # Do each command in the postuninstall commands. cmds=$postuninstall_cmds @@ -6550,8 +6217,7 @@ IFS="$save_ifs" fi # FIXME: should reinstall the best remaining shared library. - ;; - esac + fi fi ;; @@ -6850,11 +6516,12 @@ # configuration. But we'll never go from static-only to shared-only. # ### BEGIN LIBTOOL TAG CONFIG: disable-shared -disable_libs=shared +build_libtool_libs=no +build_old_libs=yes # ### END LIBTOOL TAG CONFIG: disable-shared # ### BEGIN LIBTOOL TAG CONFIG: disable-static -disable_libs=static +build_old_libs=`case $build_libtool_libs in yes) $echo no;; *) $echo yes;; esac` # ### END LIBTOOL TAG CONFIG: disable-static # Local Variables: diff -urN src/contrib/ntp/m4/hs_ulong_const.m4 src.ntp/contrib/ntp/m4/hs_ulong_const.m4 --- src/contrib/ntp/m4/hs_ulong_const.m4 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/m4/hs_ulong_const.m4 1970-01-01 01:00:00.000000000 +0100 @@ -1,11 +0,0 @@ -AC_DEFUN([hs_ULONG_CONST], -[ AH_TEMPLATE(ULONG_CONST, [How do we create unsigned long constants?]) -AC_EGREP_CPP(Circus, - [#define ACAT(a,b)a ## b -ACAT(Cir,cus) -], AC_DEFINE([ULONG_CONST(a)], [a ## UL]), - AC_EGREP_CPP(Reiser, -[#define RCAT(a,b)a/**/b -RCAT(Rei,ser) -], AC_DEFINE([ULONG_CONST(a)], [a/**/L]), - AC_MSG_ERROR([How do we create an unsigned long constant?])))]) diff -urN src/contrib/ntp/m4/ntp_cacheversion.m4 src.ntp/contrib/ntp/m4/ntp_cacheversion.m4 --- src/contrib/ntp/m4/ntp_cacheversion.m4 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/m4/ntp_cacheversion.m4 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,122 @@ +# NTP_CACHEVERSION(component, version) +# ------------------------------------ +# compare this configure script's cache version stamp with the stamp +# saved by the prior run in config.cache. If they differ, clear all +# cache variables to avoid using results cached with a script that +# is known to differ in a cache-invalidating manner. +# +# Note: use immediately following AC_INIT in configure.ac, as clearing +# all _cv_ variables only makes sense immediately after loading, before +# use or modification. +# +# It is assumed that parent configure.ac files which use +# AC_CONFIG_SUBDIR to invoke child configure.ac files have used +# NTP_CACHEVERSION if any children do. The top-level configure script +# will clear a previous cache lacking any saved cache version number, +# while children do not. The reason is the children can rely on the +# parent having cleared any cache variables predating this mechanism. +# Therefore the child can rely on the config.cache generated by the +# parent on the first run despite not finding its version stamp +# previously saved. In this case top-level means a configure script +# not invoked by another configure script in its parent directory. + +AC_DEFUN_ONCE([NTP_CACHEVERSION], [ + AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl + AC_BEFORE([$0], [AM_CONFIG_HEADER])dnl + AC_BEFORE([$0], [AC_PROG_CC])dnl + AC_BEFORE([$0], [AC_CONFIG_SUBDIRS])dnl + + ntp_cache_flush=1 + + case "$ntp_cv_[$1]_cache_version" in + [$2]) + # same version, good + ntp_cache_flush=0 + ;; + '') + # No cache, predates ntp_cv_$1_cache_version, or is empty. + case "$cache_file" in + /dev/null) + ntp_cache_flush=0 + ;; + *) + case "$NTP_CACHEVERSION_PARENT" in + '') + # Do not clear the cache immediately after it is created + # empty as it is noisy. Differentiate a newly-created + # config.cache from one predating the cache version + # mechanism by looking for the first cached variable set + # by Autoconf + case "$ac_cv_path_install" in + '') + # empty config.cache file + ntp_cache_flush=0 + esac + ;; + *) + # Parent configure just created cache from empty, + # flushing would be counterproductive. + ntp_cache_flush=0; + esac + esac + ;; + *) + # configure cache version mismatches config.cache version + esac + + case "$ntp_cache_flush" in + 1) + c_version="${ntp_cv_[$1]_cache_version:-(no version found)}" + + # Do we flush all variables or exclude others' version stamps? + + case "$NTP_CACHEVERSION_PARENT" in + '') + # Clear all *_cv_* variables including our child subdirs' + # ntp_cv_*_cache_version variables. This prevents subdir + # configure scripts from noticing a version mismatch just + # after the top configure in the invocation cleared and + # recreated the cache. + + c_varname_list=`set | + sed -n -e 's/=.*$//' \ + -e '/_cv_/p' + ` + ;; + *) + # This is not the top configure this particular invocation. + # Clear all *_cv_* variables sparing the version stamps + # of other configure scripts, so we don't trigger + # useless repeated clearings. + + c_varname_list=`set | + sed -n -e 's/=.*$//' \ + -e '/ntp_cv_.*_cache_version/d' \ + -e '/_cv_/p' + ` + esac + + for c_varname in $c_varname_list + do + dnl use AS_UNSET([$c_varname]) eventually + eval ${c_varname}=; $as_unset $c_varname + done + + dnl use AS_UNSET([c_varname_list c_varname]) eventually + c_varname_list=; $as_unset c_varname_list c_varname + + AC_MSG_NOTICE([[$cache_file saved by another version, ignored.]]) + AC_MSG_NOTICE([[configure script cache version: ]][$2]) + AC_MSG_NOTICE([[$cache_file version: $c_version]]) + $as_unset c_version + esac + + # save configure version in config.cache for next time + ntp_cv_[$1]_cache_version="[$2]" + + $as_unset ntp_cache_flush + + # let any subdir configure.ac NTP_CACHEVERSION invocations + # know they are not the top level. + NTP_CACHEVERSION_PARENT='[$1]' ; export NTP_CACHEVERSION_PARENT +])dnl diff -urN src/contrib/ntp/m4/ntp_dir_sep.m4 src.ntp/contrib/ntp/m4/ntp_dir_sep.m4 --- src/contrib/ntp/m4/ntp_dir_sep.m4 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/m4/ntp_dir_sep.m4 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,18 @@ +dnl ###################################################################### +dnl What directory path separator do we use? +AC_DEFUN([NTP_DIR_SEP], [ +AC_CACHE_CHECK([for directory path separator], ac_cv_dir_sep, +[ + case "$ac_cv_dir_sep" in + '') + case "$target_os" in + *djgpp | *mingw32* | *emx*) ac_cv_dir_sep="'\\'" ;; + *) ac_cv_dir_sep="'/'" ;; + esac + ;; + esac +]) +AC_DEFINE_UNQUOTED(DIR_SEP,$ac_cv_dir_sep,dnl + [Directory separator character, usually / or \\])dnl +]) +dnl ====================================================================== diff -urN src/contrib/ntp/m4/ntp_lineeditlibs.m4 src.ntp/contrib/ntp/m4/ntp_lineeditlibs.m4 --- src/contrib/ntp/m4/ntp_lineeditlibs.m4 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/m4/ntp_lineeditlibs.m4 2010-02-09 11:01:25.000000000 +0100 @@ -0,0 +1,100 @@ +AC_DEFUN([NTP_LINEEDITLIBS], [ + NTP_ORIG_LIBS="$LIBS" + AC_ARG_WITH([lineeditlibs], + [AC_HELP_STRING([--with-lineeditlibs], [edit,editline (readline may be specified if desired)])], + [use_lineeditlibs="$withval"], + [use_lineeditlibs="edit,editline"]) + + AC_MSG_CHECKING([line editing libraries]) + AC_MSG_RESULT([$use_lineeditlibs]) + case "$use_lineeditlibs" in + no) + ntp_lib_lineedit=no + ;; + *) + for lineedit_lib in `echo $use_lineeditlibs | sed -e 's/,/ /'`; do + for term_lib in "" termcap curses ncurses; do + case "$term_lib" in + '') + TRY_LIB="-l$lineedit_lib" + ;; + *) TRY_LIB="-l$lineedit_lib -l$term_lib" + esac # $term_lib + LIBS="$NTP_ORIG_LIBS $TRY_LIB" + AC_MSG_CHECKING([for readline() with $TRY_LIB]) + AC_TRY_LINK_FUNC([readline], [ntp_lib_lineedit="$TRY_LIB"]) + case "$ntp_lib_lineedit" in + '') + AC_MSG_RESULT([no]) + ;; + *) + # Use readline() + AC_MSG_RESULT([yes]) + break + esac # $ntp_lib_lineedit + case "$term_lib" in + '') + # do not try el_gets without a terminal library + ;; + *) + AC_MSG_CHECKING([for el_gets() with $TRY_LIB]) + AC_TRY_LINK_FUNC([el_gets], [ntp_lib_lineedit="$TRY_LIB"]) + case "$ntp_lib_lineedit" in + '') + AC_MSG_RESULT([no]) + ;; + *) # Use el_gets() + AC_MSG_RESULT([yes]) + break + ;; + esac # $ntp_lib_lineedit + esac # $term_lib + done + case "$ntp_lib_lineedit" in + '') ;; + *) break ;; + esac + done + LIBS="$NTP_ORIG_LIBS" + ;; + esac # $use_lineeditlibs + + case "$ntp_lib_lineedit" in + '') + ntp_lib_lineedit="no" + ;; + no) + ;; + *) + EDITLINE_LIBS="$ntp_lib_lineedit" + AC_SUBST(EDITLINE_LIBS) + ;; + esac # $ntp_lib_lineedit + + case "$ntp_lib_lineedit" in + no) + ;; + *) + AC_CHECK_HEADERS([readline.h readline/readline.h histedit.h]) + AC_CHECK_HEADERS([history.h readline/history.h]) + + AC_MSG_CHECKING([whether readline supports history]) + + ntp_lib_lineedit_history="no" + ORIG_LIBS="$LIBS" + LIBS="$ORIG_LIBS $ntp_lib_lineedit" + AC_TRY_LINK_FUNC([add_history], [ntp_lib_lineedit_history="yes"]) + LIBS="$ORIG_LIBS" + + AC_MSG_RESULT([$ntp_lib_lineedit_history]) + + case "$ntp_lib_lineedit_history" in + yes) + AC_DEFINE(HAVE_READLINE_HISTORY, 1, + [Define if your readline library has \`add_history']) + esac # $ntp_lib_lineedit_history + esac # $ntp_lib_lineedit + dnl when oldest supported autoconf has AS_UNSET + dnl AS_UNSET([NTP_ORIG_LIBS TRY_LIB use_lineeditlibs]) + $as_unset NTP_ORIG_LIBS TRY_LIB use_lineeditlibs +])dnl diff -urN src/contrib/ntp/m4/ntp_openssl.m4 src.ntp/contrib/ntp/m4/ntp_openssl.m4 --- src/contrib/ntp/m4/ntp_openssl.m4 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/m4/ntp_openssl.m4 2010-05-11 09:46:54.000000000 +0200 @@ -0,0 +1,182 @@ +dnl ###################################################################### +dnl OpenSSL support shared by top-level and sntp/configure.ac +AC_DEFUN([NTP_OPENSSL], [ + +AC_SUBST(OPENSSL) +AC_SUBST(OPENSSL_INC) +AC_SUBST(OPENSSL_LIB) + +AC_MSG_CHECKING([for openssl library directory]) +AC_ARG_WITH(openssl-libdir, + AC_HELP_STRING([--with-openssl-libdir], [+ =/something/reasonable]), +[ans=$withval], +[case "$build" in + $host) ans=yes ;; + *) ans=no ;; +esac]) +case "$ans" in + no) ;; + yes) # Look in: + ans="/usr/lib /usr/lib/openssl /usr/sfw/lib /usr/local/lib /usr/local/ssl/lib /lib" + ;; + *) # Look where they said + ;; +esac +case "$ans" in + no) ;; + *) # Look for libcrypto.a and libssl.a: + for i in $ans no + do + case "$host" in + *-*-darwin*) + test -f $i/libcrypto.dylib -a -f $i/libssl.dylib && break + ;; + *) + test -f $i/libcrypto.so -a -f $i/libssl.so && break + test -f $i/libcrypto.a -a -f $i/libssl.a && break + ;; + esac + done + case "$i" in + no) + ans=no + OPENSSL_LIB= + ;; + *) ans=$i + OPENSSL_LIB=$ans + ;; + esac + ;; +esac +AC_MSG_RESULT([$ans]) + +AC_MSG_CHECKING([for openssl include directory]) +AC_ARG_WITH(openssl-incdir, + AC_HELP_STRING([--with-openssl-incdir], [+ =/something/reasonable]), +[ans=$withval], +[case "$build" in + $host) ans=yes ;; + *) ans=no ;; +esac]) +case "$ans" in + no) ;; + yes) # look in: + ans="/usr/include /usr/sfw/include /usr/local/include /usr/local/ssl/include" + ;; + *) # Look where they said + ;; +esac +case "$ans" in + no) ;; + *) # look for openssl/opensslconf.h: + for i in $ans no + do + test -f $i/openssl/opensslconf.h && break + done + case "$i" in + no) + ans=no + OPENSSL_INC= + ;; + *) ans=$i + OPENSSL_INC=$ans + ;; + esac + ;; +esac +AC_MSG_RESULT([$ans]) + +AC_MSG_CHECKING([if we will use crypto]) +AC_ARG_WITH(crypto, + AC_HELP_STRING([--with-crypto], [+ =openssl]), +[ans=$withval], [ans=yes]) +case "$ans" in + no) + ;; + yes|openssl) + if test -z "$OPENSSL_LIB" -o -z "$OPENSSL_INC" + then + ans=no + else + ans=yes + fi +esac +ntp_openssl=$ans +AC_MSG_RESULT([$ans]) + +case "$ntp_openssl" in + yes) + # We have OpenSSL inc/lib - use them. + CPPFLAGS="$CPPFLAGS -I$OPENSSL_INC" + LDFLAGS="$LDFLAGS -L$OPENSSL_LIB" + case "$need_dash_r" in + 1) LDFLAGS="$LDFLAGS -R$OPENSSL_LIB" + esac + AC_SUBST(LCRYPTO, [-lcrypto]) + AC_DEFINE(OPENSSL, , [Use OpenSSL?]) +esac + +# +# Older OpenSSL headers have a number of callback prototypes inside +# other function prototypes which trigger copious warnings with gcc's +# -Wstrict-prototypes, which is included in -Wall. +# +# An example: +# +# int i2d_RSA_NET(const RSA *a, unsigned char **pp, +# int (*cb)(), int sgckey); +# ^^^^^^^^^^^ +# +# +# +openssl_triggers_warnings=unknown +SAVED_CFLAGS="$CFLAGS" + +case "$GCC$ntp_openssl" in + yesyes) + CFLAGS="$CFLAGS -Werror" + AC_COMPILE_IFELSE( + AC_LANG_SOURCE([[ /* see if -Werror breaks gcc */ ]]), + [gcc_handles_Werror=yes], + [gcc_handles_Werror=no] + ) + case "$gcc_handles_Werror" in + no) + # if this gcc doesn't do -Werror go ahead and use + # -Wstrict-prototypes. + openssl_triggers_warnings=yes + ;; + yes) + CFLAGS="$CFLAGS -Wstrict-prototypes" + AC_COMPILE_IFELSE( + AC_LANG_PROGRAM( + [[ + #include "openssl/asn1_mac.h" + #include "openssl/bn.h" + #include "openssl/err.h" + #include "openssl/evp.h" + #include "openssl/pem.h" + #include "openssl/rand.h" + #include "openssl/x509v3.h" + ]], + [[ /* empty body */ ]] + ), + [openssl_triggers_warnings=no], + [openssl_triggers_warnings=yes] + ) + esac + case "$openssl_triggers_warnings" in + yes) + CFLAGS="$SAVED_CFLAGS -Wno-strict-prototypes" + ;; + *) + CFLAGS="$SAVED_CFLAGS -Wstrict-prototypes" + esac + ;; + yesno) + # gcc without OpenSSL + CFLAGS="$SAVED_CFLAGS -Wstrict-prototypes" +esac + +]) +dnl ====================================================================== diff -urN src/contrib/ntp/m4/ntp_vpathhack.m4 src.ntp/contrib/ntp/m4/ntp_vpathhack.m4 --- src/contrib/ntp/m4/ntp_vpathhack.m4 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/m4/ntp_vpathhack.m4 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,29 @@ +dnl ###################################################################### +dnl NTP_VPATH_HACK +dnl +dnl Are we using FreeBSD's make? +dnl if we are building outside the srcdir and either +dnl force_ntp_vpath_hack is set +dnl or +dnl we're on freebsd and not using GNU make +dnl then we want VPATH_HACK to be true in automake tests +dnl +AC_DEFUN([NTP_VPATH_HACK], [ +AC_MSG_CHECKING([to see if we need a VPATH hack]) +ntp_vpath_hack="no" +case "$srcdir::$build_os::${force_ntp_vpath_hack+set}" in + .::*::*) + ;; + *::*::set) + ntp_vpath_hack="yes" + ;; + *::freebsd*::) + case "`${MAKE-make} -v -f /dev/null 2>/dev/null | grep 'GNU Make'`" in + '') + ntp_vpath_hack="yes" + esac +esac +AC_MSG_RESULT($ntp_vpath_hack) +AM_CONDITIONAL([VPATH_HACK], [test x$ntp_vpath_hack = xyes]) +]) +dnl ====================================================================== diff -urN src/contrib/ntp/m4/os_cflags.m4 src.ntp/contrib/ntp/m4/os_cflags.m4 --- src/contrib/ntp/m4/os_cflags.m4 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/m4/os_cflags.m4 2009-12-25 10:03:40.000000000 +0100 @@ -1,87 +1,99 @@ dnl ###################################################################### dnl Specify additional compile options based on the OS and the compiler -dnl From Erez Zadok , http://www.am-utils.org -AC_DEFUN([AMU_OS_CFLAGS], -[ -AC_CACHE_CHECK(additional compiler flags, -ac_cv_os_cflags, -[ -case "${host_os}" in - irix6* ) - case "${CC}" in - cc ) - # do not use 64-bit compiler - ac_cv_os_cflags="-n32 -mips3 -Wl,-woff,84" - ;; - esac - ;; -# HMS: am-utils needed this but we don't (apparently) -# osf[[1-3]]* ) -# # get the right version of struct sockaddr -# case "${CC}" in -# cc ) -# ac_cv_os_cflags="-std -D_SOCKADDR_LEN -D_NO_PROTO" -# ;; -# * ) -# ac_cv_os_cflags="-D_SOCKADDR_LEN -D_NO_PROTO" -# ;; -# esac -# ;; -# osf* ) -# # get the right version of struct sockaddr -# case "${CC}" in -# cc ) -# ac_cv_os_cflags="-std -D_SOCKADDR_LEN" -# ;; -# * ) -# ac_cv_os_cflags="-D_SOCKADDR_LEN" -# ;; -# esac -# ;; - aix[[1-3]]* ) - ac_cv_os_cflags="" ;; - aix4.[[0-2]]* ) - # turn on additional headers - ac_cv_os_cflags="-D_XOPEN_EXTENDED_SOURCE" - ;; - aix* ) - # avoid circular dependencies in yp headers - ac_cv_os_cflags="-DHAVE_BAD_HEADERS -D_XOPEN_EXTENDED_SOURCE" +AC_DEFUN([NTP_OS_CFLAGS], [ + AC_MSG_CHECKING([additional compiler flags]) + # allow ntp_os_flags to be preset to skip this stuff + case "${ntp_os_cflags+set}" in + set) + ;; + *) + ntp_os_cflags="" + case "$host_os" in + aix[[1-3]]*) + ;; + aix4.[[0-2]]*) + # turn on additional headers + ntp_os_cflags="-D_XOPEN_EXTENDED_SOURCE" + ;; + aix5.3*) + # avoid circular dependencies in yp headers, and more + ntp_os_cflags="-DHAVE_BAD_HEADERS -D_XOPEN_EXTENDED_SOURCE" + ntp_os_cflags="${ntp_os_cflags} -D_USE_IRS -D_MSGQSUPPORT" + ;; + aix*) + # avoid circular dependencies in yp headers + ntp_os_cflags="-DHAVE_BAD_HEADERS -D_XOPEN_EXTENDED_SOURCE" + ntp_os_cflags="${ntp_os_cflags} -D_USE_IRS" + ;; + amigaos) + ntp_os_cflags="-DSYS_AMIGA" + ;; + darwin*|macosx*|rhapsody*) + ntp_os_cflags="-D_P1003_1B_VISIBLE" + ;; + hpux10.*) # at least for hppa2.0-hp-hpux10.20 + case "$GCC" in + yes) + ;; + *) + # use Ansi compiler on HPUX, and some -Wp magic + ntp_os_cflags="-Ae -Wp,-H18816" + ;; + esac + ntp_os_cflags="${ntp_os_cflags} -D_HPUX_SOURCE" + ;; + hpux*) + case "$GCC" in + yes) ;; - OFF-sunos4* ) - # make sure passing whole structures is handled in gcc - case "${CC}" in - gcc ) - ac_cv_os_cflags="-fpcc-struct-return" - ;; - esac - ;; - sunos[[34]]* | solaris1* | solaris2.[[0-5]]* | sunos5.[[0-5]]* ) - ac_cv_os_cflags="" ;; - solaris* | sunos* ) - # turn on 64-bit file offset interface - case "${CC}" in - * ) - ac_cv_os_cflags="-D_LARGEFILE64_SOURCE" - ;; - esac - ;; - hpux* ) + *) # use Ansi compiler on HPUX - case "${CC}" in - cc ) - ac_cv_os_cflags="-Ae" - ;; + ntp_os_cflags="-Ae" + esac + ntp_os_cflags="${ntp_os_cflags} -D_HPUX_SOURCE" + ;; + irix6*) + case "$CC" in + cc) + # do not use 64-bit compiler + ntp_os_cflags="-n32 -mips3 -Wl,-woff,84" + esac + ;; + nextstep3) + ntp_os_cflags="-posix" + ;; + solaris1*|solaris2.[[0-5]]|solaris2.5.*) + ;; + sunos[[34]]*|sunos5.[[0-5]]|sunos5.5.*) + ;; + solaris2*|sunos5*) + # turn on 64-bit file offset interface + ntp_os_cflags="-D_LARGEFILE64_SOURCE" + ;; + vxworks*) + case "$build" in + $host) + ;; + *) + # Quick and dirty sanity check + case "$VX_KERNEL" in + '') + AC_MSG_ERROR([See html/build/hints/vxworks.html]) esac - ;; - darwin* | rhapsody* ) - ac_cv_os_cflags="-D_P1003_1B_VISIBLE" - ;; - * ) - ac_cv_os_cflags="" - ;; -esac -]) -CFLAGS="$CFLAGS $ac_cv_os_cflags" + ntp_os_cflags="-DSYS_VXWORKS" + esac + ;; + esac + esac + case "$ntp_os_flags" in + '') + ntp_os_cflags_msg="none needed" + ;; + *) + ntp_os_cflags_msg="$ntp_os_cflags" + CFLAGS="$CFLAGS $ntp_os_cflags" + esac + AC_MSG_RESULT([$ntp_os_cflags_msg]) + AS_UNSET([ntp_os_cflags_msg]) ]) dnl ====================================================================== diff -urN src/contrib/ntp/ntpd/Makefile.am src.ntp/contrib/ntp/ntpd/Makefile.am --- src/contrib/ntp/ntpd/Makefile.am 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/Makefile.am 2010-02-04 08:26:51.000000000 +0100 @@ -1,108 +1,277 @@ -AUTOMAKE_OPTIONS= ../util/ansi2knr - -bindir= ${exec_prefix}/${BINSUBDIR} +NULL= +AUTOMAKE_OPTIONS= +if NTP_BINSUBDIR_IS_BIN bin_PROGRAMS= ntpd @MAKE_NTPDSIM@ +else +sbin_PROGRAMS= ntpd @MAKE_NTPDSIM@ +endif noinst_LIBRARIES= libntpd.a -AM_CPPFLAGS= -I$(top_srcdir)/include -I../include $(LIBOPTS_CFLAGS) +AM_CPPFLAGS= -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/nothreads/include \ + -I$(top_srcdir)/lib/isc/unix/include $(LIBOPTS_CFLAGS) + # LDADD might need RESLIB and ADJLIB. LDADD= version.o libntpd.a @LIBPARSE@ +AM_YFLAGS= -d -t -r all -BUILT_SOURCES= ntpd-opts.c ntpd-opts.h ntpd.1 ntpd-opts.texi ntpd-opts.menu -man_MANS= ntpd.1 - -BUILT_SOURCES+= ntpdsim-opts.c ntpdsim-opts.h ntpdsim.1 ntpdsim-opts.texi ntpdsim-opts.menu -man_MANS+= ntpdsim.1 +if SAVECONFIG_ENABLED +if NTP_CROSSCOMPILE +CHECK_SAVECONFIG= +else +CHECK_SAVECONFIG= check-saveconfig +endif +else !SAVECONFIG_ENABLED +CHECK_SAVECONFIG= +endif + +# +# VPHACK and VPHACK_AFTER are enabled on non-GNU makes (such as +# BSD make) to work around issues specific to compiling +# ntp_parser.y into ntp_parser.h and ntp_parser.c in a vPATH +# configuration where we would like (for a change) the output +# files ntp_parser.[ch] to be placed in the source directory, +# as opposed to the build directory. This allows a single +# host of a flock configured with Bison to update ntp_parser.[ch] +# used by the rest. +# + +if VPATH_HACK +VPHACK= vphack +VPHACK_AFTER= vphack_after +else +VPHACK= +VPHACK_AFTER= +endif + +vphack: + test -e ntp_parser.c || ln -s $(srcdir)/ntp_parser.c . + test -e ntp_parser.h || ln -s $(srcdir)/ntp_parser.h . + +# +# ylwrap script which invokes Bison replaces ntp_parser.h +# symlink with the updated file, when ntp_parser.h changes. +# vphack_after detects this and copies the updated file to srcdir +# and re-creates the ntp_parser.h symlink in its place. +# + +vphack_after: + test -L ntp_parser.h || ( \ + mv ntp_parser.h $(srcdir)/ntp_parser.h && \ + ln -s $(srcdir)/ntp_parser.h . \ + ) + +# BUILT_SOURCES which should also be in EXTRA_DIST +B_S_DIST= \ + ntpd-opts.c \ + ntpd-opts.h \ + $(NULL) + +BUILT_SOURCES= \ + $(VPHACK) \ + ntp_parser.c \ + ntp_parser.h \ + $(VPHACK_AFTER) \ + $(B_S_DIST) \ + $(NULL) + +man_MANS= $(srcdir)/ntpd.1 + +# ntpdsim.1 is a remnant along with all the ntpdsim-opts.* files, the +# simulator currently uses ntpd-opts.[ch]. This also means there is no +# longer a reason to have ntpdbase-opts.def split off of ntpd-opts.def. # ntpd may need: # log10 refclock_wwv.o # sqrt ntp_control.o # floor refclock_wwv.o # which are (usually) provided by -lm. -ntpd_LDADD = $(LDADD) -lm @LCRYPTO@ $(LIBOPTS_LDADD) ../libntp/libntp.a -ntpdsim_LDADD = $(LDADD) ../libntp/libntpsim.a -lm @LCRYPTO@ $(LIBOPTS_LDADD) +ntpd_LDADD = $(LDADD) $(LIBOPTS_LDADD) ../libntp/libntp.a -lm @LCRYPTO@ @LSCF@ +ntpdsim_LDADD = $(LDADD) $(LIBOPTS_LDADD) ../libntp/libntpsim.a -lm @LCRYPTO@ @LSCF@ ntpdsim_CFLAGS = $(CFLAGS) -DSIM check_y2k_LDADD = $(LDADD) ../libntp/libntp.a -DISTCLEANFILES = .version version.c -EXTRA_DIST = ntpd-opts.def ntpdbase-opts.def ntpdsim-opts.def \ +keyword_gen_LDADD = ../libntp/libntp.a # we don't want $(LDADD) here + +DISTCLEANFILES = \ + keyword-gen \ + .version \ + version.c \ + $(NULL) + +CLEANFILES = \ + check-saveconfig \ + compsave.conf \ + k-g-u-submake \ + $(NULL) + +EXTRA_DIST = \ + complete.conf \ + keyword-gen-utd \ + ntpd.1 \ + ntpd-opts.def \ + ntpd-opts.menu \ + ntpd-opts.texi \ + ntpdbase-opts.def \ refclock_msfees.c \ refclock_trak.c \ - $(BUILT_SOURCES) + $(B_S_DIST) \ + $(NULL) + ETAGS_ARGS = Makefile.am ### Y2Kfixes check_PROGRAMS = @MAKE_CHECK_Y2K@ -EXTRA_PROGRAMS = check_y2k ntpdsim -run_ag = cd $(srcdir) && autogen -L ../include --writable -std_def_list= $(top_srcdir)/include/debug-opt.def \ - $(top_srcdir)/include/autogen-version.def \ +EXTRA_PROGRAMS = check_y2k ntpdsim keyword-gen +noinst_DATA = $(srcdir)/ntpd-opts.texi $(srcdir)/ntpd-opts.menu +run_ag= cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" \ + autogen -L ../include --writable +std_def_list= $(top_srcdir)/include/autogen-version.def \ $(top_srcdir)/include/copyright.def \ $(top_srcdir)/include/version.def -check-local: @MAKE_CHECK_Y2K@ +check-local: @MAKE_CHECK_Y2K@ $(CHECK_SAVECONFIG) test -z "@MAKE_CHECK_Y2K@" || ./@MAKE_CHECK_Y2K@ -# SIM: cmd_args.c ntp_config.c ntp_io.c ntpd.c + ntpsim.c (include/ntpsim.h) -# ntp_resolver.c is presently unused... -ntpd_SOURCES = cmd_args.c ntp_config.c ntp_io.c ntpd.c ntpd-opts.c ntpd-opts.h -ntpdsim_SOURCES = $(ntpd_SOURCES) ntpsim.c ntpdsim-opts.c ntpdsim-opts.h -libntpd_a_SOURCES = jupiter.h ntp_control.c \ - ntp_crypto.c ntp_filegen.c \ - ntp_intres.c ntp_loopfilter.c ntp_monitor.c ntp_peer.c \ - ntp_proto.c ntp_refclock.c ntp_request.c \ - ntp_restrict.c ntp_timer.c ntp_util.c \ - ppsapi_timepps.h \ - refclock_acts.c refclock_arbiter.c refclock_arc.c refclock_as2201.c \ - refclock_atom.c refclock_bancomm.c refclock_chronolog.c \ - refclock_chu.c refclock_conf.c refclock_datum.c refclock_dumbclock.c \ - refclock_fg.c refclock_gpsvme.c refclock_heath.c refclock_hopfser.c \ - refclock_hopfpci.c refclock_hpgps.c refclock_irig.c refclock_jjy.c \ - refclock_jupiter.c refclock_leitch.c refclock_local.c \ - refclock_mx4200.c refclock_neoclock4x.c \ - refclock_nmea.c refclock_oncore.c refclock_palisade.c \ - refclock_palisade.h refclock_parse.c \ - refclock_pcf.c refclock_pst.c refclock_ripencc.c refclock_shm.c \ - refclock_tpro.c refclock_true.c refclock_tt560.c \ - refclock_ulink.c refclock_wwv.c refclock_wwvb.c \ - refclock_zyfer.c +ntpd_SOURCES = \ + cmd_args.c \ + ntp_config.c \ + ntp_data_structures.c \ + ntp_keyword.h \ + ntp_io.c \ + ntp_parser.y \ + ntp_scanner.c \ + ntp_scanner.h \ + ntpd.c \ + ntpd-opts.c \ + ntpd-opts.h \ + $(NULL) + +ntpdsim_SOURCES = \ + $(ntpd_SOURCES) \ + ntpsim.c \ + $(NULL) + +# libntpd_a_SOURCES do not use #ifdef SIM + +libntpd_a_SOURCES = \ + jupiter.h \ + ntp_control.c \ + ntp_crypto.c \ + ntp_filegen.c \ + ntp_intres.c \ + ntp_loopfilter.c \ + ntp_monitor.c \ + ntp_peer.c \ + ntp_proto.c \ + ntp_refclock.c \ + ntp_request.c \ + ntp_restrict.c \ + ntp_signd.c \ + ntp_timer.c \ + ntp_util.c \ + ppsapi_timepps.h \ + refclock_acts.c \ + refclock_arbiter.c \ + refclock_arc.c \ + refclock_as2201.c \ + refclock_atom.c \ + refclock_bancomm.c \ + refclock_chronolog.c \ + refclock_chu.c \ + refclock_conf.c \ + refclock_datum.c \ + refclock_dumbclock.c \ + refclock_fg.c \ + refclock_gpsvme.c \ + refclock_heath.c \ + refclock_hopfser.c \ + refclock_hopfpci.c \ + refclock_hpgps.c \ + refclock_irig.c \ + refclock_jjy.c \ + refclock_jupiter.c \ + refclock_leitch.c \ + refclock_local.c \ + refclock_mx4200.c \ + refclock_neoclock4x.c \ + refclock_nmea.c \ + refclock_oncore.c \ + refclock_palisade.c \ + refclock_palisade.h \ + refclock_parse.c \ + refclock_pcf.c \ + refclock_pst.c \ + refclock_ripencc.c \ + refclock_shm.c \ + refclock_tpro.c \ + refclock_true.c \ + refclock_tt560.c \ + refclock_ulink.c \ + refclock_wwv.c \ + refclock_wwvb.c \ + refclock_zyfer.c \ + $(NULL) + +k-g-u-submake: keyword-gen + ./keyword-gen $(srcdir)/ntp_parser.h > k-g.out + @grep -v diff_ignore_line < k-g.out > cmp1 + @grep -v diff_ignore_line < $(srcdir)/ntp_keyword.h > cmp2 + @cmp cmp1 cmp2 > /dev/null || \ + { mv -f k-g.out $(srcdir)/ntp_keyword.h && \ + echo 'Generated changed ntp_keyword.h.' ;} + @[ ! -f k-g.out ] || \ + { rm k-g.out && echo 'ntp_keyword.h is up to date.' ;} + @rm cmp1 cmp2 + @echo 'keyword-gen and ntp_keyword.h are up to date.' > $@ + +$(srcdir)/keyword-gen-utd: $(srcdir)/keyword-gen.c $(srcdir)/ntp_parser.h + $(MAKE) k-g-u-submake # avoid explicit dependency + grep diff_ignore_line $(srcdir)/ntp_keyword.h > k-g-u + mv -f k-g-u $@ + +$(srcdir)/ntp_keyword.h: $(srcdir)/keyword-gen-utd + @: do-nothing action to avoid default SCCS get + @: .h updated if needed by k-g-u-submake rule $(srcdir)/ntpd-opts.h: $(srcdir)/ntpd-opts.c + @: do-nothing action to avoid default SCCS get, .h built with .c + $(srcdir)/ntpd-opts.c: $(srcdir)/ntpd-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) $(run_ag) ntpd-opts.def $(srcdir)/ntpd.1: $(srcdir)/ntpd-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) $(run_ag) -Tagman1.tpl -bntpd ntpd-opts.def -$(srcdir)/ntpd-opts.texi $(srcdir)/ntpd-opts.menu: $(srcdir)/ntpd-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) +$(srcdir)/ntpd-opts.menu: $(srcdir)/ntpd-opts.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/ntpd-opts.texi: $(srcdir)/ntpd-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) $(run_ag) -Taginfo.tpl -DLEVEL=section ntpd-opts.def -$(srcdir)/ntpdsim-opts.h: $(srcdir)/ntpdsim-opts.c -$(srcdir)/ntpdsim-opts.c: $(srcdir)/ntpdsim-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) $(top_srcdir)/include/homerc.def - $(run_ag) ntpdsim-opts.def +$(PROGRAMS): $(LDADD) -$(srcdir)/ntpdsim.1: $(srcdir)/ntpdsim-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) $(top_srcdir)/include/homerc.def - $(run_ag) -Tagman1.tpl -bntpdsim ntpdsim-opts.def +compsave.conf: ntpd $(srcdir)/complete.conf + ./ntpd --configfile $(srcdir)/complete.conf --saveconfigquit $@ -$(srcdir)/ntpdsim-opts.texi $(srcdir)/ntpdsim-opts.menu: $(srcdir)/ntpdsim-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) $(top_srcdir)/include/homerc.def - $(run_ag) -Taginfo.tpl -DLEVEL=section ntpdsim-opts.def +check-saveconfig: $(srcdir)/complete.conf compsave.conf + cmp $(srcdir)/complete.conf compsave.conf && echo stamp > $@ -$(PROGRAMS): $(LDADD) +../libopts/libopts.la: + cd ../libopts && $(MAKE) libopts.la ../libntp/libntp.a: cd ../libntp && $(MAKE) libntp.a -../libntp/libntpsim.a: - cd ../libntp && $(MAKE) libntpsim.a - ../libparse/libparse.a: - cd ../libparse && $(MAKE) + cd ../libparse && $(MAKE) libparse.a -$(top_srcdir)/version : +$(top_srcdir)/version: cd $(top_srcdir) && $(MAKE) version version.o: $(ntpd_OBJECTS) ../libntp/libntp.a @LIBPARSE@ Makefile $(top_srcdir)/version env CSET=`cat $(top_srcdir)/version` $(top_builddir)/scripts/mkver ntpd $(COMPILE) -c version.c -include ../bincheck.mf +include $(top_srcdir)/bincheck.mf +include $(top_srcdir)/depsver.mf diff -urN src/contrib/ntp/ntpd/Makefile.in src.ntp/contrib/ntp/ntpd/Makefile.in --- src/contrib/ntp/ntpd/Makefile.in 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/Makefile.in 2010-07-09 04:21:34.000000000 +0200 @@ -20,6 +20,7 @@ # subdir to warn folks if there is another version there. + VPATH = @srcdir@ pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ @@ -39,16 +40,23 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -ANSI2KNR = ../util/ansi2knr -bin_PROGRAMS = ntpd$(EXEEXT) @MAKE_NTPDSIM@ -EXTRA_PROGRAMS = check_y2k$(EXEEXT) ntpdsim$(EXEEXT) -DIST_COMMON = $(srcdir)/../bincheck.mf $(srcdir)/Makefile.am \ - $(srcdir)/Makefile.in +@NTP_BINSUBDIR_IS_BIN_TRUE@bin_PROGRAMS = ntpd$(EXEEXT) @MAKE_NTPDSIM@ +@NTP_BINSUBDIR_IS_BIN_FALSE@sbin_PROGRAMS = ntpd$(EXEEXT) \ +@NTP_BINSUBDIR_IS_BIN_FALSE@ @MAKE_NTPDSIM@ $(am__empty) +EXTRA_PROGRAMS = check_y2k$(EXEEXT) ntpdsim$(EXEEXT) \ + keyword-gen$(EXEEXT) +DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ + $(top_srcdir)/bincheck.mf $(top_srcdir)/depsver.mf \ + ntp_parser.c ntp_parser.h subdir = ntpd ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ + $(top_srcdir)/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/m4/ntp_openssl.m4 \ + $(top_srcdir)/m4/ntp_vpathhack.m4 \ $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ @@ -61,53 +69,63 @@ ARFLAGS = cru libntpd_a_AR = $(AR) $(ARFLAGS) libntpd_a_LIBADD = -am_libntpd_a_OBJECTS = ntp_control$U.$(OBJEXT) ntp_crypto$U.$(OBJEXT) \ - ntp_filegen$U.$(OBJEXT) ntp_intres$U.$(OBJEXT) \ - ntp_loopfilter$U.$(OBJEXT) ntp_monitor$U.$(OBJEXT) \ - ntp_peer$U.$(OBJEXT) ntp_proto$U.$(OBJEXT) \ - ntp_refclock$U.$(OBJEXT) ntp_request$U.$(OBJEXT) \ - ntp_restrict$U.$(OBJEXT) ntp_timer$U.$(OBJEXT) \ - ntp_util$U.$(OBJEXT) refclock_acts$U.$(OBJEXT) \ - refclock_arbiter$U.$(OBJEXT) refclock_arc$U.$(OBJEXT) \ - refclock_as2201$U.$(OBJEXT) refclock_atom$U.$(OBJEXT) \ - refclock_bancomm$U.$(OBJEXT) refclock_chronolog$U.$(OBJEXT) \ - refclock_chu$U.$(OBJEXT) refclock_conf$U.$(OBJEXT) \ - refclock_datum$U.$(OBJEXT) refclock_dumbclock$U.$(OBJEXT) \ - refclock_fg$U.$(OBJEXT) refclock_gpsvme$U.$(OBJEXT) \ - refclock_heath$U.$(OBJEXT) refclock_hopfser$U.$(OBJEXT) \ - refclock_hopfpci$U.$(OBJEXT) refclock_hpgps$U.$(OBJEXT) \ - refclock_irig$U.$(OBJEXT) refclock_jjy$U.$(OBJEXT) \ - refclock_jupiter$U.$(OBJEXT) refclock_leitch$U.$(OBJEXT) \ - refclock_local$U.$(OBJEXT) refclock_mx4200$U.$(OBJEXT) \ - refclock_neoclock4x$U.$(OBJEXT) refclock_nmea$U.$(OBJEXT) \ - refclock_oncore$U.$(OBJEXT) refclock_palisade$U.$(OBJEXT) \ - refclock_parse$U.$(OBJEXT) refclock_pcf$U.$(OBJEXT) \ - refclock_pst$U.$(OBJEXT) refclock_ripencc$U.$(OBJEXT) \ - refclock_shm$U.$(OBJEXT) refclock_tpro$U.$(OBJEXT) \ - refclock_true$U.$(OBJEXT) refclock_tt560$U.$(OBJEXT) \ - refclock_ulink$U.$(OBJEXT) refclock_wwv$U.$(OBJEXT) \ - refclock_wwvb$U.$(OBJEXT) refclock_zyfer$U.$(OBJEXT) +am__objects_1 = +am_libntpd_a_OBJECTS = ntp_control.$(OBJEXT) ntp_crypto.$(OBJEXT) \ + ntp_filegen.$(OBJEXT) ntp_intres.$(OBJEXT) \ + ntp_loopfilter.$(OBJEXT) ntp_monitor.$(OBJEXT) \ + ntp_peer.$(OBJEXT) ntp_proto.$(OBJEXT) ntp_refclock.$(OBJEXT) \ + ntp_request.$(OBJEXT) ntp_restrict.$(OBJEXT) \ + ntp_signd.$(OBJEXT) ntp_timer.$(OBJEXT) ntp_util.$(OBJEXT) \ + refclock_acts.$(OBJEXT) refclock_arbiter.$(OBJEXT) \ + refclock_arc.$(OBJEXT) refclock_as2201.$(OBJEXT) \ + refclock_atom.$(OBJEXT) refclock_bancomm.$(OBJEXT) \ + refclock_chronolog.$(OBJEXT) refclock_chu.$(OBJEXT) \ + refclock_conf.$(OBJEXT) refclock_datum.$(OBJEXT) \ + refclock_dumbclock.$(OBJEXT) refclock_fg.$(OBJEXT) \ + refclock_gpsvme.$(OBJEXT) refclock_heath.$(OBJEXT) \ + refclock_hopfser.$(OBJEXT) refclock_hopfpci.$(OBJEXT) \ + refclock_hpgps.$(OBJEXT) refclock_irig.$(OBJEXT) \ + refclock_jjy.$(OBJEXT) refclock_jupiter.$(OBJEXT) \ + refclock_leitch.$(OBJEXT) refclock_local.$(OBJEXT) \ + refclock_mx4200.$(OBJEXT) refclock_neoclock4x.$(OBJEXT) \ + refclock_nmea.$(OBJEXT) refclock_oncore.$(OBJEXT) \ + refclock_palisade.$(OBJEXT) refclock_parse.$(OBJEXT) \ + refclock_pcf.$(OBJEXT) refclock_pst.$(OBJEXT) \ + refclock_ripencc.$(OBJEXT) refclock_shm.$(OBJEXT) \ + refclock_tpro.$(OBJEXT) refclock_true.$(OBJEXT) \ + refclock_tt560.$(OBJEXT) refclock_ulink.$(OBJEXT) \ + refclock_wwv.$(OBJEXT) refclock_wwvb.$(OBJEXT) \ + refclock_zyfer.$(OBJEXT) $(am__objects_1) libntpd_a_OBJECTS = $(am_libntpd_a_OBJECTS) -am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)" -PROGRAMS = $(bin_PROGRAMS) +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(sbindir)" \ + "$(DESTDIR)$(man1dir)" +PROGRAMS = $(bin_PROGRAMS) $(sbin_PROGRAMS) check_y2k_SOURCES = check_y2k.c -check_y2k_OBJECTS = check_y2k$U.$(OBJEXT) +check_y2k_OBJECTS = check_y2k.$(OBJEXT) am__DEPENDENCIES_1 = version.o libntpd.a check_y2k_DEPENDENCIES = $(am__DEPENDENCIES_1) ../libntp/libntp.a -am_ntpd_OBJECTS = cmd_args$U.$(OBJEXT) ntp_config$U.$(OBJEXT) \ - ntp_io$U.$(OBJEXT) ntpd$U.$(OBJEXT) ntpd-opts$U.$(OBJEXT) +keyword_gen_SOURCES = keyword-gen.c +keyword_gen_OBJECTS = keyword-gen.$(OBJEXT) +keyword_gen_DEPENDENCIES = ../libntp/libntp.a +am_ntpd_OBJECTS = cmd_args.$(OBJEXT) ntp_config.$(OBJEXT) \ + ntp_data_structures.$(OBJEXT) ntp_io.$(OBJEXT) \ + ntp_parser.$(OBJEXT) ntp_scanner.$(OBJEXT) ntpd.$(OBJEXT) \ + ntpd-opts.$(OBJEXT) $(am__objects_1) ntpd_OBJECTS = $(am_ntpd_OBJECTS) am__DEPENDENCIES_2 = ntpd_DEPENDENCIES = $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2) \ ../libntp/libntp.a -am__objects_1 = ntpdsim-cmd_args$U.$(OBJEXT) \ - ntpdsim-ntp_config$U.$(OBJEXT) ntpdsim-ntp_io$U.$(OBJEXT) \ - ntpdsim-ntpd$U.$(OBJEXT) ntpdsim-ntpd-opts$U.$(OBJEXT) -am_ntpdsim_OBJECTS = $(am__objects_1) ntpdsim-ntpsim$U.$(OBJEXT) \ - ntpdsim-ntpdsim-opts$U.$(OBJEXT) +am__objects_2 = ntpdsim-cmd_args.$(OBJEXT) \ + ntpdsim-ntp_config.$(OBJEXT) \ + ntpdsim-ntp_data_structures.$(OBJEXT) ntpdsim-ntp_io.$(OBJEXT) \ + ntpdsim-ntp_parser.$(OBJEXT) ntpdsim-ntp_scanner.$(OBJEXT) \ + ntpdsim-ntpd.$(OBJEXT) ntpdsim-ntpd-opts.$(OBJEXT) \ + $(am__objects_1) +am_ntpdsim_OBJECTS = $(am__objects_2) ntpdsim-ntpsim.$(OBJEXT) \ + $(am__objects_1) ntpdsim_OBJECTS = $(am_ntpdsim_OBJECTS) -ntpdsim_DEPENDENCIES = $(am__DEPENDENCIES_1) ../libntp/libntpsim.a \ - $(am__DEPENDENCIES_2) +ntpdsim_DEPENDENCIES = $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2) \ + ../libntp/libntpsim.a ntpdsim_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ --mode=link $(CCLD) $(ntpdsim_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ $(LDFLAGS) -o $@ @@ -124,10 +142,14 @@ LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ $(LDFLAGS) -o $@ -SOURCES = $(libntpd_a_SOURCES) check_y2k.c $(ntpd_SOURCES) \ - $(ntpdsim_SOURCES) -DIST_SOURCES = $(libntpd_a_SOURCES) check_y2k.c $(ntpd_SOURCES) \ - $(ntpdsim_SOURCES) +YACCCOMPILE = $(YACC) $(YFLAGS) $(AM_YFLAGS) +LTYACCCOMPILE = $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ + --mode=compile $(YACC) $(YFLAGS) $(AM_YFLAGS) +YLWRAP = $(top_srcdir)/ylwrap +SOURCES = $(libntpd_a_SOURCES) check_y2k.c keyword-gen.c \ + $(ntpd_SOURCES) $(ntpdsim_SOURCES) +DIST_SOURCES = $(libntpd_a_SOURCES) check_y2k.c keyword-gen.c \ + $(ntpd_SOURCES) $(ntpdsim_SOURCES) am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ @@ -152,13 +174,13 @@ man1dir = $(mandir)/man1 NROFF = nroff MANS = $(man_MANS) +DATA = $(noinst_DATA) ETAGS = etags CTAGS = ctags DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -179,6 +201,7 @@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EF_LIBS = @EF_LIBS@ EF_PROGS = @EF_PROGS@ EGREP = @EGREP@ @@ -210,6 +233,7 @@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ @@ -226,18 +250,22 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ PATH_SEPARATOR = @PATH_SEPARATOR@ PATH_SH = @PATH_SH@ PROPDELAY = @PROPDELAY@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ VERSION = @VERSION@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ @@ -248,7 +276,7 @@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ -bindir = ${exec_prefix}/${BINSUBDIR} +bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ @@ -289,71 +317,178 @@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -AUTOMAKE_OPTIONS = ../util/ansi2knr +NULL = +AUTOMAKE_OPTIONS = noinst_LIBRARIES = libntpd.a -AM_CPPFLAGS = -I$(top_srcdir)/include -I../include $(LIBOPTS_CFLAGS) +AM_CPPFLAGS = -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/nothreads/include \ + -I$(top_srcdir)/lib/isc/unix/include $(LIBOPTS_CFLAGS) + + # LDADD might need RESLIB and ADJLIB. LDADD = version.o libntpd.a @LIBPARSE@ -BUILT_SOURCES = ntpd-opts.c ntpd-opts.h ntpd.1 ntpd-opts.texi \ - ntpd-opts.menu ntpdsim-opts.c ntpdsim-opts.h ntpdsim.1 \ - ntpdsim-opts.texi ntpdsim-opts.menu -man_MANS = ntpd.1 ntpdsim.1 +AM_YFLAGS = -d -t -r all +@NTP_CROSSCOMPILE_FALSE@@SAVECONFIG_ENABLED_TRUE@CHECK_SAVECONFIG = check-saveconfig +@NTP_CROSSCOMPILE_TRUE@@SAVECONFIG_ENABLED_TRUE@CHECK_SAVECONFIG = +@SAVECONFIG_ENABLED_FALSE@CHECK_SAVECONFIG = +@VPATH_HACK_FALSE@VPHACK = + +# +# VPHACK and VPHACK_AFTER are enabled on non-GNU makes (such as +# BSD make) to work around issues specific to compiling +# ntp_parser.y into ntp_parser.h and ntp_parser.c in a vPATH +# configuration where we would like (for a change) the output +# files ntp_parser.[ch] to be placed in the source directory, +# as opposed to the build directory. This allows a single +# host of a flock configured with Bison to update ntp_parser.[ch] +# used by the rest. +# +@VPATH_HACK_TRUE@VPHACK = vphack +@VPATH_HACK_FALSE@VPHACK_AFTER = +@VPATH_HACK_TRUE@VPHACK_AFTER = vphack_after + +# BUILT_SOURCES which should also be in EXTRA_DIST +B_S_DIST = \ + ntpd-opts.c \ + ntpd-opts.h \ + $(NULL) + +BUILT_SOURCES = $(VPHACK) ntp_parser.c ntp_parser.h $(VPHACK_AFTER) \ + $(B_S_DIST) $(NULL) .deps-ver +man_MANS = $(srcdir)/ntpd.1 + +# ntpdsim.1 is a remnant along with all the ntpdsim-opts.* files, the +# simulator currently uses ntpd-opts.[ch]. This also means there is no +# longer a reason to have ntpdbase-opts.def split off of ntpd-opts.def. # ntpd may need: # log10 refclock_wwv.o # sqrt ntp_control.o # floor refclock_wwv.o # which are (usually) provided by -lm. -ntpd_LDADD = $(LDADD) -lm @LCRYPTO@ $(LIBOPTS_LDADD) ../libntp/libntp.a -ntpdsim_LDADD = $(LDADD) ../libntp/libntpsim.a -lm @LCRYPTO@ $(LIBOPTS_LDADD) +ntpd_LDADD = $(LDADD) $(LIBOPTS_LDADD) ../libntp/libntp.a -lm @LCRYPTO@ @LSCF@ +ntpdsim_LDADD = $(LDADD) $(LIBOPTS_LDADD) ../libntp/libntpsim.a -lm @LCRYPTO@ @LSCF@ ntpdsim_CFLAGS = $(CFLAGS) -DSIM check_y2k_LDADD = $(LDADD) ../libntp/libntp.a -DISTCLEANFILES = .version version.c -EXTRA_DIST = ntpd-opts.def ntpdbase-opts.def ntpdsim-opts.def \ +keyword_gen_LDADD = ../libntp/libntp.a # we don't want $(LDADD) here +DISTCLEANFILES = \ + keyword-gen \ + .version \ + version.c \ + $(NULL) + +CLEANFILES = check-saveconfig compsave.conf k-g-u-submake $(NULL) \ + .deps-ver +EXTRA_DIST = \ + complete.conf \ + keyword-gen-utd \ + ntpd.1 \ + ntpd-opts.def \ + ntpd-opts.menu \ + ntpd-opts.texi \ + ntpdbase-opts.def \ refclock_msfees.c \ refclock_trak.c \ - $(BUILT_SOURCES) + $(B_S_DIST) \ + $(NULL) ETAGS_ARGS = Makefile.am ### Y2Kfixes check_PROGRAMS = @MAKE_CHECK_Y2K@ -run_ag = cd $(srcdir) && autogen -L ../include --writable -std_def_list = $(top_srcdir)/include/debug-opt.def \ - $(top_srcdir)/include/autogen-version.def \ +noinst_DATA = $(srcdir)/ntpd-opts.texi $(srcdir)/ntpd-opts.menu +run_ag = cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" \ + autogen -L ../include --writable + +std_def_list = $(top_srcdir)/include/autogen-version.def \ $(top_srcdir)/include/copyright.def \ $(top_srcdir)/include/version.def - -# SIM: cmd_args.c ntp_config.c ntp_io.c ntpd.c + ntpsim.c (include/ntpsim.h) -# ntp_resolver.c is presently unused... -ntpd_SOURCES = cmd_args.c ntp_config.c ntp_io.c ntpd.c ntpd-opts.c ntpd-opts.h -ntpdsim_SOURCES = $(ntpd_SOURCES) ntpsim.c ntpdsim-opts.c ntpdsim-opts.h -libntpd_a_SOURCES = jupiter.h ntp_control.c \ - ntp_crypto.c ntp_filegen.c \ - ntp_intres.c ntp_loopfilter.c ntp_monitor.c ntp_peer.c \ - ntp_proto.c ntp_refclock.c ntp_request.c \ - ntp_restrict.c ntp_timer.c ntp_util.c \ - ppsapi_timepps.h \ - refclock_acts.c refclock_arbiter.c refclock_arc.c refclock_as2201.c \ - refclock_atom.c refclock_bancomm.c refclock_chronolog.c \ - refclock_chu.c refclock_conf.c refclock_datum.c refclock_dumbclock.c \ - refclock_fg.c refclock_gpsvme.c refclock_heath.c refclock_hopfser.c \ - refclock_hopfpci.c refclock_hpgps.c refclock_irig.c refclock_jjy.c \ - refclock_jupiter.c refclock_leitch.c refclock_local.c \ - refclock_mx4200.c refclock_neoclock4x.c \ - refclock_nmea.c refclock_oncore.c refclock_palisade.c \ - refclock_palisade.h refclock_parse.c \ - refclock_pcf.c refclock_pst.c refclock_ripencc.c refclock_shm.c \ - refclock_tpro.c refclock_true.c refclock_tt560.c \ - refclock_ulink.c refclock_wwv.c refclock_wwvb.c \ - refclock_zyfer.c +ntpd_SOURCES = \ + cmd_args.c \ + ntp_config.c \ + ntp_data_structures.c \ + ntp_keyword.h \ + ntp_io.c \ + ntp_parser.y \ + ntp_scanner.c \ + ntp_scanner.h \ + ntpd.c \ + ntpd-opts.c \ + ntpd-opts.h \ + $(NULL) + +ntpdsim_SOURCES = \ + $(ntpd_SOURCES) \ + ntpsim.c \ + $(NULL) + + +# libntpd_a_SOURCES do not use #ifdef SIM +libntpd_a_SOURCES = \ + jupiter.h \ + ntp_control.c \ + ntp_crypto.c \ + ntp_filegen.c \ + ntp_intres.c \ + ntp_loopfilter.c \ + ntp_monitor.c \ + ntp_peer.c \ + ntp_proto.c \ + ntp_refclock.c \ + ntp_request.c \ + ntp_restrict.c \ + ntp_signd.c \ + ntp_timer.c \ + ntp_util.c \ + ppsapi_timepps.h \ + refclock_acts.c \ + refclock_arbiter.c \ + refclock_arc.c \ + refclock_as2201.c \ + refclock_atom.c \ + refclock_bancomm.c \ + refclock_chronolog.c \ + refclock_chu.c \ + refclock_conf.c \ + refclock_datum.c \ + refclock_dumbclock.c \ + refclock_fg.c \ + refclock_gpsvme.c \ + refclock_heath.c \ + refclock_hopfser.c \ + refclock_hopfpci.c \ + refclock_hpgps.c \ + refclock_irig.c \ + refclock_jjy.c \ + refclock_jupiter.c \ + refclock_leitch.c \ + refclock_local.c \ + refclock_mx4200.c \ + refclock_neoclock4x.c \ + refclock_nmea.c \ + refclock_oncore.c \ + refclock_palisade.c \ + refclock_palisade.h \ + refclock_parse.c \ + refclock_pcf.c \ + refclock_pst.c \ + refclock_ripencc.c \ + refclock_shm.c \ + refclock_tpro.c \ + refclock_true.c \ + refclock_tt560.c \ + refclock_ulink.c \ + refclock_wwv.c \ + refclock_wwvb.c \ + refclock_zyfer.c \ + $(NULL) all: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: -.SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(srcdir)/../bincheck.mf $(am__configure_deps) +.SUFFIXES: .c .lo .o .obj .y +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/bincheck.mf $(top_srcdir)/depsver.mf $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -442,9 +577,60 @@ list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ echo " rm -f" $$list; \ rm -f $$list +install-sbinPROGRAMS: $(sbin_PROGRAMS) + @$(NORMAL_INSTALL) + test -z "$(sbindir)" || $(MKDIR_P) "$(DESTDIR)$(sbindir)" + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p || test -f $$p1; \ + then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-sbinPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(sbindir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(sbindir)" && rm -f $$files + +clean-sbinPROGRAMS: + @list='$(sbin_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list check_y2k$(EXEEXT): $(check_y2k_OBJECTS) $(check_y2k_DEPENDENCIES) @rm -f check_y2k$(EXEEXT) $(LINK) $(check_y2k_OBJECTS) $(check_y2k_LDADD) $(LIBS) +keyword-gen$(EXEEXT): $(keyword_gen_OBJECTS) $(keyword_gen_DEPENDENCIES) + @rm -f keyword-gen$(EXEEXT) + $(LINK) $(keyword_gen_OBJECTS) $(keyword_gen_LDADD) $(LIBS) +ntp_parser.h: ntp_parser.c + @if test ! -f $@; then \ + rm -f ntp_parser.c; \ + $(MAKE) $(AM_MAKEFLAGS) ntp_parser.c; \ + else :; fi ntpd$(EXEEXT): $(ntpd_OBJECTS) $(ntpd_DEPENDENCIES) @rm -f ntpd$(EXEEXT) $(LINK) $(ntpd_OBJECTS) $(ntpd_LDADD) $(LIBS) @@ -457,77 +643,79 @@ distclean-compile: -rm -f *.tab.c -../util/ansi2knr: - $(am__cd) ../util && $(MAKE) $(AM_MAKEFLAGS) ./ansi2knr - -mostlyclean-kr: - -test "$U" = "" || rm -f *_.c -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/check_y2k$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cmd_args$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_config$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_control$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_crypto$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_filegen$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_intres$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_io$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_loopfilter$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_monitor$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_peer$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_proto$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_refclock$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_request$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_restrict$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_timer$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_util$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpd$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpd-opts$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-cmd_args$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntp_config$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntp_io$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntpd$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntpd-opts$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntpdsim-opts$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntpsim$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_acts$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_arbiter$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_arc$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_as2201$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_atom$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_bancomm$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_chronolog$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_chu$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_conf$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_datum$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_dumbclock$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_fg$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_gpsvme$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_heath$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_hopfpci$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_hopfser$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_hpgps$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_irig$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_jjy$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_jupiter$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_leitch$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_local$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_mx4200$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_neoclock4x$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_nmea$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_oncore$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_palisade$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_parse$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_pcf$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_pst$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_ripencc$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_shm$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_tpro$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_true$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_tt560$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_ulink$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_wwv$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_wwvb$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_zyfer$U.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/check_y2k.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cmd_args.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/keyword-gen.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_config.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_control.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_crypto.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_data_structures.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_filegen.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_intres.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_io.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_loopfilter.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_monitor.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_parser.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_peer.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_proto.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_refclock.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_request.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_restrict.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_scanner.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_signd.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_timer.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_util.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpd-opts.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpd.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-cmd_args.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntp_config.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntp_data_structures.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntp_io.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntp_parser.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntp_scanner.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntpd-opts.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntpd.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntpsim.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_acts.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_arbiter.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_arc.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_as2201.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_atom.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_bancomm.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_chronolog.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_chu.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_conf.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_datum.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_dumbclock.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_fg.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_gpsvme.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_heath.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_hopfpci.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_hopfser.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_hpgps.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_irig.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_jjy.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_jupiter.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_leitch.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_local.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_mx4200.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_neoclock4x.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_nmea.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_oncore.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_palisade.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_parse.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_pcf.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_pst.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_ripencc.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_shm.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_tpro.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_true.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_tt560.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_ulink.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_wwv.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_wwvb.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_zyfer.Po@am__quote@ .c.o: @am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @@ -550,266 +738,134 @@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< -ntpdsim-cmd_args$U.o: cmd_args$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-cmd_args$U.o -MD -MP -MF $(DEPDIR)/ntpdsim-cmd_args$U.Tpo -c -o ntpdsim-cmd_args$U.o `test -f 'cmd_args$U.c' || echo '$(srcdir)/'`cmd_args$U.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-cmd_args$U.Tpo $(DEPDIR)/ntpdsim-cmd_args$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='cmd_args$U.c' object='ntpdsim-cmd_args$U.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-cmd_args$U.o `test -f 'cmd_args$U.c' || echo '$(srcdir)/'`cmd_args$U.c - -ntpdsim-cmd_args$U.obj: cmd_args$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-cmd_args$U.obj -MD -MP -MF $(DEPDIR)/ntpdsim-cmd_args$U.Tpo -c -o ntpdsim-cmd_args$U.obj `if test -f 'cmd_args$U.c'; then $(CYGPATH_W) 'cmd_args$U.c'; else $(CYGPATH_W) '$(srcdir)/cmd_args$U.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-cmd_args$U.Tpo $(DEPDIR)/ntpdsim-cmd_args$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='cmd_args$U.c' object='ntpdsim-cmd_args$U.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-cmd_args$U.obj `if test -f 'cmd_args$U.c'; then $(CYGPATH_W) 'cmd_args$U.c'; else $(CYGPATH_W) '$(srcdir)/cmd_args$U.c'; fi` - -ntpdsim-ntp_config$U.o: ntp_config$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_config$U.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_config$U.Tpo -c -o ntpdsim-ntp_config$U.o `test -f 'ntp_config$U.c' || echo '$(srcdir)/'`ntp_config$U.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntp_config$U.Tpo $(DEPDIR)/ntpdsim-ntp_config$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntp_config$U.c' object='ntpdsim-ntp_config$U.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_config$U.o `test -f 'ntp_config$U.c' || echo '$(srcdir)/'`ntp_config$U.c - -ntpdsim-ntp_config$U.obj: ntp_config$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_config$U.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_config$U.Tpo -c -o ntpdsim-ntp_config$U.obj `if test -f 'ntp_config$U.c'; then $(CYGPATH_W) 'ntp_config$U.c'; else $(CYGPATH_W) '$(srcdir)/ntp_config$U.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntp_config$U.Tpo $(DEPDIR)/ntpdsim-ntp_config$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntp_config$U.c' object='ntpdsim-ntp_config$U.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_config$U.obj `if test -f 'ntp_config$U.c'; then $(CYGPATH_W) 'ntp_config$U.c'; else $(CYGPATH_W) '$(srcdir)/ntp_config$U.c'; fi` - -ntpdsim-ntp_io$U.o: ntp_io$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_io$U.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_io$U.Tpo -c -o ntpdsim-ntp_io$U.o `test -f 'ntp_io$U.c' || echo '$(srcdir)/'`ntp_io$U.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntp_io$U.Tpo $(DEPDIR)/ntpdsim-ntp_io$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntp_io$U.c' object='ntpdsim-ntp_io$U.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_io$U.o `test -f 'ntp_io$U.c' || echo '$(srcdir)/'`ntp_io$U.c - -ntpdsim-ntp_io$U.obj: ntp_io$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_io$U.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_io$U.Tpo -c -o ntpdsim-ntp_io$U.obj `if test -f 'ntp_io$U.c'; then $(CYGPATH_W) 'ntp_io$U.c'; else $(CYGPATH_W) '$(srcdir)/ntp_io$U.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntp_io$U.Tpo $(DEPDIR)/ntpdsim-ntp_io$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntp_io$U.c' object='ntpdsim-ntp_io$U.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_io$U.obj `if test -f 'ntp_io$U.c'; then $(CYGPATH_W) 'ntp_io$U.c'; else $(CYGPATH_W) '$(srcdir)/ntp_io$U.c'; fi` - -ntpdsim-ntpd$U.o: ntpd$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpd$U.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntpd$U.Tpo -c -o ntpdsim-ntpd$U.o `test -f 'ntpd$U.c' || echo '$(srcdir)/'`ntpd$U.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntpd$U.Tpo $(DEPDIR)/ntpdsim-ntpd$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntpd$U.c' object='ntpdsim-ntpd$U.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpd$U.o `test -f 'ntpd$U.c' || echo '$(srcdir)/'`ntpd$U.c - -ntpdsim-ntpd$U.obj: ntpd$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpd$U.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntpd$U.Tpo -c -o ntpdsim-ntpd$U.obj `if test -f 'ntpd$U.c'; then $(CYGPATH_W) 'ntpd$U.c'; else $(CYGPATH_W) '$(srcdir)/ntpd$U.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntpd$U.Tpo $(DEPDIR)/ntpdsim-ntpd$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntpd$U.c' object='ntpdsim-ntpd$U.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpd$U.obj `if test -f 'ntpd$U.c'; then $(CYGPATH_W) 'ntpd$U.c'; else $(CYGPATH_W) '$(srcdir)/ntpd$U.c'; fi` - -ntpdsim-ntpd-opts$U.o: ntpd-opts$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpd-opts$U.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntpd-opts$U.Tpo -c -o ntpdsim-ntpd-opts$U.o `test -f 'ntpd-opts$U.c' || echo '$(srcdir)/'`ntpd-opts$U.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntpd-opts$U.Tpo $(DEPDIR)/ntpdsim-ntpd-opts$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntpd-opts$U.c' object='ntpdsim-ntpd-opts$U.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpd-opts$U.o `test -f 'ntpd-opts$U.c' || echo '$(srcdir)/'`ntpd-opts$U.c - -ntpdsim-ntpd-opts$U.obj: ntpd-opts$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpd-opts$U.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntpd-opts$U.Tpo -c -o ntpdsim-ntpd-opts$U.obj `if test -f 'ntpd-opts$U.c'; then $(CYGPATH_W) 'ntpd-opts$U.c'; else $(CYGPATH_W) '$(srcdir)/ntpd-opts$U.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntpd-opts$U.Tpo $(DEPDIR)/ntpdsim-ntpd-opts$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntpd-opts$U.c' object='ntpdsim-ntpd-opts$U.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpd-opts$U.obj `if test -f 'ntpd-opts$U.c'; then $(CYGPATH_W) 'ntpd-opts$U.c'; else $(CYGPATH_W) '$(srcdir)/ntpd-opts$U.c'; fi` - -ntpdsim-ntpsim$U.o: ntpsim$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpsim$U.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntpsim$U.Tpo -c -o ntpdsim-ntpsim$U.o `test -f 'ntpsim$U.c' || echo '$(srcdir)/'`ntpsim$U.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntpsim$U.Tpo $(DEPDIR)/ntpdsim-ntpsim$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntpsim$U.c' object='ntpdsim-ntpsim$U.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpsim$U.o `test -f 'ntpsim$U.c' || echo '$(srcdir)/'`ntpsim$U.c - -ntpdsim-ntpsim$U.obj: ntpsim$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpsim$U.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntpsim$U.Tpo -c -o ntpdsim-ntpsim$U.obj `if test -f 'ntpsim$U.c'; then $(CYGPATH_W) 'ntpsim$U.c'; else $(CYGPATH_W) '$(srcdir)/ntpsim$U.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntpsim$U.Tpo $(DEPDIR)/ntpdsim-ntpsim$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntpsim$U.c' object='ntpdsim-ntpsim$U.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpsim$U.obj `if test -f 'ntpsim$U.c'; then $(CYGPATH_W) 'ntpsim$U.c'; else $(CYGPATH_W) '$(srcdir)/ntpsim$U.c'; fi` - -ntpdsim-ntpdsim-opts$U.o: ntpdsim-opts$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpdsim-opts$U.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntpdsim-opts$U.Tpo -c -o ntpdsim-ntpdsim-opts$U.o `test -f 'ntpdsim-opts$U.c' || echo '$(srcdir)/'`ntpdsim-opts$U.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntpdsim-opts$U.Tpo $(DEPDIR)/ntpdsim-ntpdsim-opts$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntpdsim-opts$U.c' object='ntpdsim-ntpdsim-opts$U.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpdsim-opts$U.o `test -f 'ntpdsim-opts$U.c' || echo '$(srcdir)/'`ntpdsim-opts$U.c - -ntpdsim-ntpdsim-opts$U.obj: ntpdsim-opts$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpdsim-opts$U.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntpdsim-opts$U.Tpo -c -o ntpdsim-ntpdsim-opts$U.obj `if test -f 'ntpdsim-opts$U.c'; then $(CYGPATH_W) 'ntpdsim-opts$U.c'; else $(CYGPATH_W) '$(srcdir)/ntpdsim-opts$U.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntpdsim-opts$U.Tpo $(DEPDIR)/ntpdsim-ntpdsim-opts$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntpdsim-opts$U.c' object='ntpdsim-ntpdsim-opts$U.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpdsim-opts$U.obj `if test -f 'ntpdsim-opts$U.c'; then $(CYGPATH_W) 'ntpdsim-opts$U.c'; else $(CYGPATH_W) '$(srcdir)/ntpdsim-opts$U.c'; fi` -check_y2k_.c: check_y2k.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/check_y2k.c; then echo $(srcdir)/check_y2k.c; else echo check_y2k.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -cmd_args_.c: cmd_args.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/cmd_args.c; then echo $(srcdir)/cmd_args.c; else echo cmd_args.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_config_.c: ntp_config.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_config.c; then echo $(srcdir)/ntp_config.c; else echo ntp_config.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_control_.c: ntp_control.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_control.c; then echo $(srcdir)/ntp_control.c; else echo ntp_control.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_crypto_.c: ntp_crypto.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_crypto.c; then echo $(srcdir)/ntp_crypto.c; else echo ntp_crypto.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_filegen_.c: ntp_filegen.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_filegen.c; then echo $(srcdir)/ntp_filegen.c; else echo ntp_filegen.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_intres_.c: ntp_intres.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_intres.c; then echo $(srcdir)/ntp_intres.c; else echo ntp_intres.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_io_.c: ntp_io.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_io.c; then echo $(srcdir)/ntp_io.c; else echo ntp_io.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_loopfilter_.c: ntp_loopfilter.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_loopfilter.c; then echo $(srcdir)/ntp_loopfilter.c; else echo ntp_loopfilter.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_monitor_.c: ntp_monitor.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_monitor.c; then echo $(srcdir)/ntp_monitor.c; else echo ntp_monitor.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_peer_.c: ntp_peer.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_peer.c; then echo $(srcdir)/ntp_peer.c; else echo ntp_peer.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_proto_.c: ntp_proto.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_proto.c; then echo $(srcdir)/ntp_proto.c; else echo ntp_proto.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_refclock_.c: ntp_refclock.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_refclock.c; then echo $(srcdir)/ntp_refclock.c; else echo ntp_refclock.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_request_.c: ntp_request.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_request.c; then echo $(srcdir)/ntp_request.c; else echo ntp_request.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_restrict_.c: ntp_restrict.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_restrict.c; then echo $(srcdir)/ntp_restrict.c; else echo ntp_restrict.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_timer_.c: ntp_timer.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_timer.c; then echo $(srcdir)/ntp_timer.c; else echo ntp_timer.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_util_.c: ntp_util.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_util.c; then echo $(srcdir)/ntp_util.c; else echo ntp_util.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntpd_.c: ntpd.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntpd.c; then echo $(srcdir)/ntpd.c; else echo ntpd.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntpd-opts_.c: ntpd-opts.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntpd-opts.c; then echo $(srcdir)/ntpd-opts.c; else echo ntpd-opts.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntpdsim-opts_.c: ntpdsim-opts.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntpdsim-opts.c; then echo $(srcdir)/ntpdsim-opts.c; else echo ntpdsim-opts.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntpsim_.c: ntpsim.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntpsim.c; then echo $(srcdir)/ntpsim.c; else echo ntpsim.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_acts_.c: refclock_acts.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_acts.c; then echo $(srcdir)/refclock_acts.c; else echo refclock_acts.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_arbiter_.c: refclock_arbiter.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_arbiter.c; then echo $(srcdir)/refclock_arbiter.c; else echo refclock_arbiter.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_arc_.c: refclock_arc.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_arc.c; then echo $(srcdir)/refclock_arc.c; else echo refclock_arc.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_as2201_.c: refclock_as2201.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_as2201.c; then echo $(srcdir)/refclock_as2201.c; else echo refclock_as2201.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_atom_.c: refclock_atom.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_atom.c; then echo $(srcdir)/refclock_atom.c; else echo refclock_atom.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_bancomm_.c: refclock_bancomm.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_bancomm.c; then echo $(srcdir)/refclock_bancomm.c; else echo refclock_bancomm.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_chronolog_.c: refclock_chronolog.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_chronolog.c; then echo $(srcdir)/refclock_chronolog.c; else echo refclock_chronolog.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_chu_.c: refclock_chu.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_chu.c; then echo $(srcdir)/refclock_chu.c; else echo refclock_chu.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_conf_.c: refclock_conf.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_conf.c; then echo $(srcdir)/refclock_conf.c; else echo refclock_conf.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_datum_.c: refclock_datum.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_datum.c; then echo $(srcdir)/refclock_datum.c; else echo refclock_datum.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_dumbclock_.c: refclock_dumbclock.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_dumbclock.c; then echo $(srcdir)/refclock_dumbclock.c; else echo refclock_dumbclock.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_fg_.c: refclock_fg.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_fg.c; then echo $(srcdir)/refclock_fg.c; else echo refclock_fg.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_gpsvme_.c: refclock_gpsvme.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_gpsvme.c; then echo $(srcdir)/refclock_gpsvme.c; else echo refclock_gpsvme.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_heath_.c: refclock_heath.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_heath.c; then echo $(srcdir)/refclock_heath.c; else echo refclock_heath.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_hopfpci_.c: refclock_hopfpci.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_hopfpci.c; then echo $(srcdir)/refclock_hopfpci.c; else echo refclock_hopfpci.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_hopfser_.c: refclock_hopfser.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_hopfser.c; then echo $(srcdir)/refclock_hopfser.c; else echo refclock_hopfser.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_hpgps_.c: refclock_hpgps.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_hpgps.c; then echo $(srcdir)/refclock_hpgps.c; else echo refclock_hpgps.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_irig_.c: refclock_irig.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_irig.c; then echo $(srcdir)/refclock_irig.c; else echo refclock_irig.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_jjy_.c: refclock_jjy.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_jjy.c; then echo $(srcdir)/refclock_jjy.c; else echo refclock_jjy.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_jupiter_.c: refclock_jupiter.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_jupiter.c; then echo $(srcdir)/refclock_jupiter.c; else echo refclock_jupiter.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_leitch_.c: refclock_leitch.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_leitch.c; then echo $(srcdir)/refclock_leitch.c; else echo refclock_leitch.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_local_.c: refclock_local.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_local.c; then echo $(srcdir)/refclock_local.c; else echo refclock_local.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_mx4200_.c: refclock_mx4200.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_mx4200.c; then echo $(srcdir)/refclock_mx4200.c; else echo refclock_mx4200.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_neoclock4x_.c: refclock_neoclock4x.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_neoclock4x.c; then echo $(srcdir)/refclock_neoclock4x.c; else echo refclock_neoclock4x.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_nmea_.c: refclock_nmea.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_nmea.c; then echo $(srcdir)/refclock_nmea.c; else echo refclock_nmea.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_oncore_.c: refclock_oncore.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_oncore.c; then echo $(srcdir)/refclock_oncore.c; else echo refclock_oncore.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_palisade_.c: refclock_palisade.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_palisade.c; then echo $(srcdir)/refclock_palisade.c; else echo refclock_palisade.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_parse_.c: refclock_parse.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_parse.c; then echo $(srcdir)/refclock_parse.c; else echo refclock_parse.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_pcf_.c: refclock_pcf.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_pcf.c; then echo $(srcdir)/refclock_pcf.c; else echo refclock_pcf.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_pst_.c: refclock_pst.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_pst.c; then echo $(srcdir)/refclock_pst.c; else echo refclock_pst.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_ripencc_.c: refclock_ripencc.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_ripencc.c; then echo $(srcdir)/refclock_ripencc.c; else echo refclock_ripencc.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_shm_.c: refclock_shm.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_shm.c; then echo $(srcdir)/refclock_shm.c; else echo refclock_shm.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_tpro_.c: refclock_tpro.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_tpro.c; then echo $(srcdir)/refclock_tpro.c; else echo refclock_tpro.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_true_.c: refclock_true.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_true.c; then echo $(srcdir)/refclock_true.c; else echo refclock_true.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_tt560_.c: refclock_tt560.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_tt560.c; then echo $(srcdir)/refclock_tt560.c; else echo refclock_tt560.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_ulink_.c: refclock_ulink.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_ulink.c; then echo $(srcdir)/refclock_ulink.c; else echo refclock_ulink.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_wwv_.c: refclock_wwv.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_wwv.c; then echo $(srcdir)/refclock_wwv.c; else echo refclock_wwv.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_wwvb_.c: refclock_wwvb.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_wwvb.c; then echo $(srcdir)/refclock_wwvb.c; else echo refclock_wwvb.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_zyfer_.c: refclock_zyfer.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_zyfer.c; then echo $(srcdir)/refclock_zyfer.c; else echo refclock_zyfer.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -check_y2k_.$(OBJEXT) check_y2k_.lo cmd_args_.$(OBJEXT) cmd_args_.lo \ -ntp_config_.$(OBJEXT) ntp_config_.lo ntp_control_.$(OBJEXT) \ -ntp_control_.lo ntp_crypto_.$(OBJEXT) ntp_crypto_.lo \ -ntp_filegen_.$(OBJEXT) ntp_filegen_.lo ntp_intres_.$(OBJEXT) \ -ntp_intres_.lo ntp_io_.$(OBJEXT) ntp_io_.lo ntp_loopfilter_.$(OBJEXT) \ -ntp_loopfilter_.lo ntp_monitor_.$(OBJEXT) ntp_monitor_.lo \ -ntp_peer_.$(OBJEXT) ntp_peer_.lo ntp_proto_.$(OBJEXT) ntp_proto_.lo \ -ntp_refclock_.$(OBJEXT) ntp_refclock_.lo ntp_request_.$(OBJEXT) \ -ntp_request_.lo ntp_restrict_.$(OBJEXT) ntp_restrict_.lo \ -ntp_timer_.$(OBJEXT) ntp_timer_.lo ntp_util_.$(OBJEXT) ntp_util_.lo \ -ntpd_.$(OBJEXT) ntpd_.lo ntpd-opts_.$(OBJEXT) ntpd-opts_.lo \ -ntpdsim-opts_.$(OBJEXT) ntpdsim-opts_.lo ntpsim_.$(OBJEXT) ntpsim_.lo \ -refclock_acts_.$(OBJEXT) refclock_acts_.lo refclock_arbiter_.$(OBJEXT) \ -refclock_arbiter_.lo refclock_arc_.$(OBJEXT) refclock_arc_.lo \ -refclock_as2201_.$(OBJEXT) refclock_as2201_.lo \ -refclock_atom_.$(OBJEXT) refclock_atom_.lo refclock_bancomm_.$(OBJEXT) \ -refclock_bancomm_.lo refclock_chronolog_.$(OBJEXT) \ -refclock_chronolog_.lo refclock_chu_.$(OBJEXT) refclock_chu_.lo \ -refclock_conf_.$(OBJEXT) refclock_conf_.lo refclock_datum_.$(OBJEXT) \ -refclock_datum_.lo refclock_dumbclock_.$(OBJEXT) \ -refclock_dumbclock_.lo refclock_fg_.$(OBJEXT) refclock_fg_.lo \ -refclock_gpsvme_.$(OBJEXT) refclock_gpsvme_.lo \ -refclock_heath_.$(OBJEXT) refclock_heath_.lo \ -refclock_hopfpci_.$(OBJEXT) refclock_hopfpci_.lo \ -refclock_hopfser_.$(OBJEXT) refclock_hopfser_.lo \ -refclock_hpgps_.$(OBJEXT) refclock_hpgps_.lo refclock_irig_.$(OBJEXT) \ -refclock_irig_.lo refclock_jjy_.$(OBJEXT) refclock_jjy_.lo \ -refclock_jupiter_.$(OBJEXT) refclock_jupiter_.lo \ -refclock_leitch_.$(OBJEXT) refclock_leitch_.lo \ -refclock_local_.$(OBJEXT) refclock_local_.lo \ -refclock_mx4200_.$(OBJEXT) refclock_mx4200_.lo \ -refclock_neoclock4x_.$(OBJEXT) refclock_neoclock4x_.lo \ -refclock_nmea_.$(OBJEXT) refclock_nmea_.lo refclock_oncore_.$(OBJEXT) \ -refclock_oncore_.lo refclock_palisade_.$(OBJEXT) refclock_palisade_.lo \ -refclock_parse_.$(OBJEXT) refclock_parse_.lo refclock_pcf_.$(OBJEXT) \ -refclock_pcf_.lo refclock_pst_.$(OBJEXT) refclock_pst_.lo \ -refclock_ripencc_.$(OBJEXT) refclock_ripencc_.lo \ -refclock_shm_.$(OBJEXT) refclock_shm_.lo refclock_tpro_.$(OBJEXT) \ -refclock_tpro_.lo refclock_true_.$(OBJEXT) refclock_true_.lo \ -refclock_tt560_.$(OBJEXT) refclock_tt560_.lo refclock_ulink_.$(OBJEXT) \ -refclock_ulink_.lo refclock_wwv_.$(OBJEXT) refclock_wwv_.lo \ -refclock_wwvb_.$(OBJEXT) refclock_wwvb_.lo refclock_zyfer_.$(OBJEXT) \ -refclock_zyfer_.lo : $(ANSI2KNR) +ntpdsim-cmd_args.o: cmd_args.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-cmd_args.o -MD -MP -MF $(DEPDIR)/ntpdsim-cmd_args.Tpo -c -o ntpdsim-cmd_args.o `test -f 'cmd_args.c' || echo '$(srcdir)/'`cmd_args.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-cmd_args.Tpo $(DEPDIR)/ntpdsim-cmd_args.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='cmd_args.c' object='ntpdsim-cmd_args.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-cmd_args.o `test -f 'cmd_args.c' || echo '$(srcdir)/'`cmd_args.c + +ntpdsim-cmd_args.obj: cmd_args.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-cmd_args.obj -MD -MP -MF $(DEPDIR)/ntpdsim-cmd_args.Tpo -c -o ntpdsim-cmd_args.obj `if test -f 'cmd_args.c'; then $(CYGPATH_W) 'cmd_args.c'; else $(CYGPATH_W) '$(srcdir)/cmd_args.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-cmd_args.Tpo $(DEPDIR)/ntpdsim-cmd_args.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='cmd_args.c' object='ntpdsim-cmd_args.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-cmd_args.obj `if test -f 'cmd_args.c'; then $(CYGPATH_W) 'cmd_args.c'; else $(CYGPATH_W) '$(srcdir)/cmd_args.c'; fi` + +ntpdsim-ntp_config.o: ntp_config.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_config.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_config.Tpo -c -o ntpdsim-ntp_config.o `test -f 'ntp_config.c' || echo '$(srcdir)/'`ntp_config.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntp_config.Tpo $(DEPDIR)/ntpdsim-ntp_config.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntp_config.c' object='ntpdsim-ntp_config.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_config.o `test -f 'ntp_config.c' || echo '$(srcdir)/'`ntp_config.c + +ntpdsim-ntp_config.obj: ntp_config.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_config.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_config.Tpo -c -o ntpdsim-ntp_config.obj `if test -f 'ntp_config.c'; then $(CYGPATH_W) 'ntp_config.c'; else $(CYGPATH_W) '$(srcdir)/ntp_config.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntp_config.Tpo $(DEPDIR)/ntpdsim-ntp_config.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntp_config.c' object='ntpdsim-ntp_config.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_config.obj `if test -f 'ntp_config.c'; then $(CYGPATH_W) 'ntp_config.c'; else $(CYGPATH_W) '$(srcdir)/ntp_config.c'; fi` + +ntpdsim-ntp_data_structures.o: ntp_data_structures.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_data_structures.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_data_structures.Tpo -c -o ntpdsim-ntp_data_structures.o `test -f 'ntp_data_structures.c' || echo '$(srcdir)/'`ntp_data_structures.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntp_data_structures.Tpo $(DEPDIR)/ntpdsim-ntp_data_structures.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntp_data_structures.c' object='ntpdsim-ntp_data_structures.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_data_structures.o `test -f 'ntp_data_structures.c' || echo '$(srcdir)/'`ntp_data_structures.c + +ntpdsim-ntp_data_structures.obj: ntp_data_structures.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_data_structures.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_data_structures.Tpo -c -o ntpdsim-ntp_data_structures.obj `if test -f 'ntp_data_structures.c'; then $(CYGPATH_W) 'ntp_data_structures.c'; else $(CYGPATH_W) '$(srcdir)/ntp_data_structures.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntp_data_structures.Tpo $(DEPDIR)/ntpdsim-ntp_data_structures.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntp_data_structures.c' object='ntpdsim-ntp_data_structures.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_data_structures.obj `if test -f 'ntp_data_structures.c'; then $(CYGPATH_W) 'ntp_data_structures.c'; else $(CYGPATH_W) '$(srcdir)/ntp_data_structures.c'; fi` + +ntpdsim-ntp_io.o: ntp_io.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_io.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_io.Tpo -c -o ntpdsim-ntp_io.o `test -f 'ntp_io.c' || echo '$(srcdir)/'`ntp_io.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntp_io.Tpo $(DEPDIR)/ntpdsim-ntp_io.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntp_io.c' object='ntpdsim-ntp_io.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_io.o `test -f 'ntp_io.c' || echo '$(srcdir)/'`ntp_io.c + +ntpdsim-ntp_io.obj: ntp_io.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_io.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_io.Tpo -c -o ntpdsim-ntp_io.obj `if test -f 'ntp_io.c'; then $(CYGPATH_W) 'ntp_io.c'; else $(CYGPATH_W) '$(srcdir)/ntp_io.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntp_io.Tpo $(DEPDIR)/ntpdsim-ntp_io.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntp_io.c' object='ntpdsim-ntp_io.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_io.obj `if test -f 'ntp_io.c'; then $(CYGPATH_W) 'ntp_io.c'; else $(CYGPATH_W) '$(srcdir)/ntp_io.c'; fi` + +ntpdsim-ntp_parser.o: ntp_parser.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_parser.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_parser.Tpo -c -o ntpdsim-ntp_parser.o `test -f 'ntp_parser.c' || echo '$(srcdir)/'`ntp_parser.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntp_parser.Tpo $(DEPDIR)/ntpdsim-ntp_parser.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntp_parser.c' object='ntpdsim-ntp_parser.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_parser.o `test -f 'ntp_parser.c' || echo '$(srcdir)/'`ntp_parser.c + +ntpdsim-ntp_parser.obj: ntp_parser.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_parser.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_parser.Tpo -c -o ntpdsim-ntp_parser.obj `if test -f 'ntp_parser.c'; then $(CYGPATH_W) 'ntp_parser.c'; else $(CYGPATH_W) '$(srcdir)/ntp_parser.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntp_parser.Tpo $(DEPDIR)/ntpdsim-ntp_parser.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntp_parser.c' object='ntpdsim-ntp_parser.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_parser.obj `if test -f 'ntp_parser.c'; then $(CYGPATH_W) 'ntp_parser.c'; else $(CYGPATH_W) '$(srcdir)/ntp_parser.c'; fi` + +ntpdsim-ntp_scanner.o: ntp_scanner.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_scanner.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_scanner.Tpo -c -o ntpdsim-ntp_scanner.o `test -f 'ntp_scanner.c' || echo '$(srcdir)/'`ntp_scanner.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntp_scanner.Tpo $(DEPDIR)/ntpdsim-ntp_scanner.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntp_scanner.c' object='ntpdsim-ntp_scanner.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_scanner.o `test -f 'ntp_scanner.c' || echo '$(srcdir)/'`ntp_scanner.c + +ntpdsim-ntp_scanner.obj: ntp_scanner.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_scanner.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_scanner.Tpo -c -o ntpdsim-ntp_scanner.obj `if test -f 'ntp_scanner.c'; then $(CYGPATH_W) 'ntp_scanner.c'; else $(CYGPATH_W) '$(srcdir)/ntp_scanner.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntp_scanner.Tpo $(DEPDIR)/ntpdsim-ntp_scanner.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntp_scanner.c' object='ntpdsim-ntp_scanner.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_scanner.obj `if test -f 'ntp_scanner.c'; then $(CYGPATH_W) 'ntp_scanner.c'; else $(CYGPATH_W) '$(srcdir)/ntp_scanner.c'; fi` + +ntpdsim-ntpd.o: ntpd.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpd.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntpd.Tpo -c -o ntpdsim-ntpd.o `test -f 'ntpd.c' || echo '$(srcdir)/'`ntpd.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntpd.Tpo $(DEPDIR)/ntpdsim-ntpd.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntpd.c' object='ntpdsim-ntpd.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpd.o `test -f 'ntpd.c' || echo '$(srcdir)/'`ntpd.c + +ntpdsim-ntpd.obj: ntpd.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpd.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntpd.Tpo -c -o ntpdsim-ntpd.obj `if test -f 'ntpd.c'; then $(CYGPATH_W) 'ntpd.c'; else $(CYGPATH_W) '$(srcdir)/ntpd.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntpd.Tpo $(DEPDIR)/ntpdsim-ntpd.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntpd.c' object='ntpdsim-ntpd.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpd.obj `if test -f 'ntpd.c'; then $(CYGPATH_W) 'ntpd.c'; else $(CYGPATH_W) '$(srcdir)/ntpd.c'; fi` + +ntpdsim-ntpd-opts.o: ntpd-opts.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpd-opts.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntpd-opts.Tpo -c -o ntpdsim-ntpd-opts.o `test -f 'ntpd-opts.c' || echo '$(srcdir)/'`ntpd-opts.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntpd-opts.Tpo $(DEPDIR)/ntpdsim-ntpd-opts.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntpd-opts.c' object='ntpdsim-ntpd-opts.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpd-opts.o `test -f 'ntpd-opts.c' || echo '$(srcdir)/'`ntpd-opts.c + +ntpdsim-ntpd-opts.obj: ntpd-opts.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpd-opts.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntpd-opts.Tpo -c -o ntpdsim-ntpd-opts.obj `if test -f 'ntpd-opts.c'; then $(CYGPATH_W) 'ntpd-opts.c'; else $(CYGPATH_W) '$(srcdir)/ntpd-opts.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntpd-opts.Tpo $(DEPDIR)/ntpdsim-ntpd-opts.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntpd-opts.c' object='ntpdsim-ntpd-opts.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpd-opts.obj `if test -f 'ntpd-opts.c'; then $(CYGPATH_W) 'ntpd-opts.c'; else $(CYGPATH_W) '$(srcdir)/ntpd-opts.c'; fi` + +ntpdsim-ntpsim.o: ntpsim.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpsim.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntpsim.Tpo -c -o ntpdsim-ntpsim.o `test -f 'ntpsim.c' || echo '$(srcdir)/'`ntpsim.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntpsim.Tpo $(DEPDIR)/ntpdsim-ntpsim.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntpsim.c' object='ntpdsim-ntpsim.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpsim.o `test -f 'ntpsim.c' || echo '$(srcdir)/'`ntpsim.c + +ntpdsim-ntpsim.obj: ntpsim.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpsim.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntpsim.Tpo -c -o ntpdsim-ntpsim.obj `if test -f 'ntpsim.c'; then $(CYGPATH_W) 'ntpsim.c'; else $(CYGPATH_W) '$(srcdir)/ntpsim.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntpsim.Tpo $(DEPDIR)/ntpdsim-ntpsim.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntpsim.c' object='ntpdsim-ntpsim.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpsim.obj `if test -f 'ntpsim.c'; then $(CYGPATH_W) 'ntpsim.c'; else $(CYGPATH_W) '$(srcdir)/ntpsim.c'; fi` + +.y.c: + $(am__skipyacc) $(SHELL) $(YLWRAP) $< y.tab.c $@ y.tab.h $*.h y.output $*.output -- $(YACCCOMPILE) mostlyclean-libtool: -rm -f *.lo @@ -955,9 +1011,9 @@ $(MAKE) $(AM_MAKEFLAGS) check-local check: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) check-am -all-am: Makefile $(LIBRARIES) $(PROGRAMS) $(MANS) +all-am: Makefile $(LIBRARIES) $(PROGRAMS) $(MANS) $(DATA) installdirs: - for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)"; do \ + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: $(BUILT_SOURCES) @@ -978,6 +1034,7 @@ mostlyclean-generic: clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) @@ -987,11 +1044,14 @@ maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." + -rm -f ntp_parser.c + -rm -f ntp_parser.h -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-am clean-am: clean-binPROGRAMS clean-checkPROGRAMS clean-generic \ - clean-libtool clean-noinstLIBRARIES mostlyclean-am + clean-libtool clean-noinstLIBRARIES clean-sbinPROGRAMS \ + mostlyclean-am distclean: distclean-am -rm -rf ./$(DEPDIR) @@ -1017,7 +1077,7 @@ install-dvi-am: -install-exec-am: install-binPROGRAMS +install-exec-am: install-binPROGRAMS install-sbinPROGRAMS @$(NORMAL_INSTALL) $(MAKE) $(AM_MAKEFLAGS) install-exec-hook install-html: install-html-am @@ -1047,7 +1107,7 @@ mostlyclean: mostlyclean-am -mostlyclean-am: mostlyclean-compile mostlyclean-generic mostlyclean-kr \ +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am @@ -1058,66 +1118,106 @@ ps-am: -uninstall-am: uninstall-binPROGRAMS uninstall-man +uninstall-am: uninstall-binPROGRAMS uninstall-man \ + uninstall-sbinPROGRAMS uninstall-man: uninstall-man1 -.MAKE: ../util/ansi2knr all check check-am install install-am \ - install-exec-am install-strip +.MAKE: all check check-am install install-am install-exec-am \ + install-strip .PHONY: CTAGS GTAGS all all-am check check-am check-local clean \ clean-binPROGRAMS clean-checkPROGRAMS clean-generic \ - clean-libtool clean-noinstLIBRARIES ctags distclean \ - distclean-compile distclean-generic distclean-libtool \ - distclean-tags distdir dvi dvi-am html html-am info info-am \ - install install-am install-binPROGRAMS install-data \ - install-data-am install-dvi install-dvi-am install-exec \ - install-exec-am install-exec-hook install-html install-html-am \ - install-info install-info-am install-man install-man1 \ - install-pdf install-pdf-am install-ps install-ps-am \ - install-strip installcheck installcheck-am installdirs \ - maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-compile mostlyclean-generic mostlyclean-kr \ - mostlyclean-libtool pdf pdf-am ps ps-am tags uninstall \ - uninstall-am uninstall-binPROGRAMS uninstall-man \ - uninstall-man1 + clean-libtool clean-noinstLIBRARIES clean-sbinPROGRAMS ctags \ + distclean distclean-compile distclean-generic \ + distclean-libtool distclean-tags distdir dvi dvi-am html \ + html-am info info-am install install-am install-binPROGRAMS \ + install-data install-data-am install-dvi install-dvi-am \ + install-exec install-exec-am install-exec-hook install-html \ + install-html-am install-info install-info-am install-man \ + install-man1 install-pdf install-pdf-am install-ps \ + install-ps-am install-sbinPROGRAMS install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-compile \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags uninstall uninstall-am uninstall-binPROGRAMS \ + uninstall-man uninstall-man1 uninstall-sbinPROGRAMS + + +vphack: + test -e ntp_parser.c || ln -s $(srcdir)/ntp_parser.c . + test -e ntp_parser.h || ln -s $(srcdir)/ntp_parser.h . + +# +# ylwrap script which invokes Bison replaces ntp_parser.h +# symlink with the updated file, when ntp_parser.h changes. +# vphack_after detects this and copies the updated file to srcdir +# and re-creates the ntp_parser.h symlink in its place. +# +vphack_after: + test -L ntp_parser.h || ( \ + mv ntp_parser.h $(srcdir)/ntp_parser.h && \ + ln -s $(srcdir)/ntp_parser.h . \ + ) -check-local: @MAKE_CHECK_Y2K@ +check-local: @MAKE_CHECK_Y2K@ $(CHECK_SAVECONFIG) test -z "@MAKE_CHECK_Y2K@" || ./@MAKE_CHECK_Y2K@ +k-g-u-submake: keyword-gen + ./keyword-gen $(srcdir)/ntp_parser.h > k-g.out + @grep -v diff_ignore_line < k-g.out > cmp1 + @grep -v diff_ignore_line < $(srcdir)/ntp_keyword.h > cmp2 + @cmp cmp1 cmp2 > /dev/null || \ + { mv -f k-g.out $(srcdir)/ntp_keyword.h && \ + echo 'Generated changed ntp_keyword.h.' ;} + @[ ! -f k-g.out ] || \ + { rm k-g.out && echo 'ntp_keyword.h is up to date.' ;} + @rm cmp1 cmp2 + @echo 'keyword-gen and ntp_keyword.h are up to date.' > $@ + +$(srcdir)/keyword-gen-utd: $(srcdir)/keyword-gen.c $(srcdir)/ntp_parser.h + $(MAKE) k-g-u-submake # avoid explicit dependency + grep diff_ignore_line $(srcdir)/ntp_keyword.h > k-g-u + mv -f k-g-u $@ + +$(srcdir)/ntp_keyword.h: $(srcdir)/keyword-gen-utd + @: do-nothing action to avoid default SCCS get + @: .h updated if needed by k-g-u-submake rule + $(srcdir)/ntpd-opts.h: $(srcdir)/ntpd-opts.c + @: do-nothing action to avoid default SCCS get, .h built with .c + $(srcdir)/ntpd-opts.c: $(srcdir)/ntpd-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) $(run_ag) ntpd-opts.def $(srcdir)/ntpd.1: $(srcdir)/ntpd-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) $(run_ag) -Tagman1.tpl -bntpd ntpd-opts.def -$(srcdir)/ntpd-opts.texi $(srcdir)/ntpd-opts.menu: $(srcdir)/ntpd-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) +$(srcdir)/ntpd-opts.menu: $(srcdir)/ntpd-opts.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/ntpd-opts.texi: $(srcdir)/ntpd-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) $(run_ag) -Taginfo.tpl -DLEVEL=section ntpd-opts.def -$(srcdir)/ntpdsim-opts.h: $(srcdir)/ntpdsim-opts.c -$(srcdir)/ntpdsim-opts.c: $(srcdir)/ntpdsim-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) $(top_srcdir)/include/homerc.def - $(run_ag) ntpdsim-opts.def +$(PROGRAMS): $(LDADD) -$(srcdir)/ntpdsim.1: $(srcdir)/ntpdsim-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) $(top_srcdir)/include/homerc.def - $(run_ag) -Tagman1.tpl -bntpdsim ntpdsim-opts.def +compsave.conf: ntpd $(srcdir)/complete.conf + ./ntpd --configfile $(srcdir)/complete.conf --saveconfigquit $@ -$(srcdir)/ntpdsim-opts.texi $(srcdir)/ntpdsim-opts.menu: $(srcdir)/ntpdsim-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) $(top_srcdir)/include/homerc.def - $(run_ag) -Taginfo.tpl -DLEVEL=section ntpdsim-opts.def +check-saveconfig: $(srcdir)/complete.conf compsave.conf + cmp $(srcdir)/complete.conf compsave.conf && echo stamp > $@ -$(PROGRAMS): $(LDADD) +../libopts/libopts.la: + cd ../libopts && $(MAKE) libopts.la ../libntp/libntp.a: cd ../libntp && $(MAKE) libntp.a -../libntp/libntpsim.a: - cd ../libntp && $(MAKE) libntpsim.a - ../libparse/libparse.a: - cd ../libparse && $(MAKE) + cd ../libparse && $(MAKE) libparse.a -$(top_srcdir)/version : +$(top_srcdir)/version: cd $(top_srcdir) && $(MAKE) version version.o: $(ntpd_OBJECTS) ../libntp/libntp.a @LIBPARSE@ Makefile $(top_srcdir)/version @@ -1125,16 +1225,80 @@ $(COMPILE) -c version.c install-exec-hook: - @case ${BINSUBDIR} in \ - bin) ODIR=${exec_prefix}/sbin ;; \ - sbin) ODIR=${exec_prefix}/bin ;; \ - esac; \ - test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ + @case ${BINSUBDIR} in \ + bin) ODIR=${sbindir} ;; \ + sbin) ODIR=${bindir} ;; \ + esac; \ + test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ test ! -f $$ODIR/$$i || echo "*** $$i is also in $$ODIR!"; \ done # +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + ..) \ + cd .. && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + *) \ + echo 'Fatal: depsver.mf Automake fragment limited' \ + 'to immediate subdirectories.' && \ + echo "top_builddir: $(top_builddir)" && \ + echo "subdir: $(subdir)" && \ + exit 1 \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff -urN src/contrib/ntp/ntpd/cmd_args.c src.ntp/contrib/ntp/ntpd/cmd_args.c --- src/contrib/ntp/ntpd/cmd_args.c 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/cmd_args.c 2009-12-25 10:03:41.000000000 +0100 @@ -9,21 +9,13 @@ #include "ntp_stdlib.h" #include "ntp_cmdargs.h" -#ifdef SIM -# include "ntpsim.h" -# include "ntpdsim-opts.h" -# define OPTSTRUCT ntpdsimOptions -#else -# include "ntpd-opts.h" -# define OPTSTRUCT ntpdOptions -#endif /* SIM */ +#include "ntpd-opts.h" /* * Definitions of things either imported from or exported to outside */ extern char const *progname; extern const char *specific_interface; -extern short default_ai_family; #ifdef HAVE_NETINFO extern int check_netinfo; @@ -41,29 +33,29 @@ { extern const char *config_file; int errflg; - tOptions *myOptions = &OPTSTRUCT; + tOptions *myOptions = &ntpdOptions; /* * Initialize, initialize */ errflg = 0; - switch (WHICH_IDX_IPV4) { - case INDEX_OPT_IPV4: - default_ai_family = AF_INET; - break; - case INDEX_OPT_IPV6: - default_ai_family = AF_INET6; - break; - default: - /* ai_fam_templ = ai_fam_default; */ - break; - } + if (ipv4_works && ipv6_works) { + if (HAVE_OPT( IPV4 )) + ipv6_works = 0; + else if (HAVE_OPT( IPV6 )) + ipv4_works = 0; + } else if (!ipv4_works && !ipv6_works) { + msyslog(LOG_ERR, "Neither IPv4 nor IPv6 networking detected, fatal."); + exit(1); + } else if (HAVE_OPT( IPV4 ) && !ipv4_works) + msyslog(LOG_WARNING, "-4/--ipv4 ignored, IPv4 networking not found."); + else if (HAVE_OPT( IPV6 ) && !ipv6_works) + msyslog(LOG_WARNING, "-6/--ipv6 ignored, IPv6 networking not found."); if (HAVE_OPT( AUTHREQ )) proto_config(PROTO_AUTHENTICATE, 1, 0., NULL); - - if (HAVE_OPT( AUTHNOREQ )) + else if (HAVE_OPT( AUTHNOREQ )) proto_config(PROTO_AUTHENTICATE, 0, 0., NULL); if (HAVE_OPT( BCASTSYNC )) @@ -82,24 +74,12 @@ if (HAVE_OPT( PANICGATE )) allow_panic = TRUE; - if (HAVE_OPT( JAILDIR )) { #ifdef HAVE_DROPROOT - droproot = 1; - chrootdir = OPT_ARG( JAILDIR ); -#else - fprintf(stderr, - "command line -i option (jaildir) is not supported by this binary" -# ifndef SYS_WINNT - ",\n" "can not drop root privileges. See configure options\n" - "--enable-clockctl and --enable-linuxcaps.\n"); -# else - ".\n"); -# endif - msyslog(LOG_ERR, - "command line -i option (jaildir) is not supported by this binary."); - errflg++; -#endif + if (HAVE_OPT( JAILDIR )) { + droproot = 1; + chrootdir = OPT_ARG( JAILDIR ); } +#endif if (HAVE_OPT( KEYFILE )) getauthkeys(OPT_ARG( KEYFILE )); @@ -146,30 +126,15 @@ } while (--ct > 0); } - if (HAVE_OPT( USER )) { #ifdef HAVE_DROPROOT - char *ntp_optarg = OPT_ARG( USER ); - + if (HAVE_OPT( USER )) { droproot = 1; - user = emalloc(strlen(ntp_optarg) + 1); - (void)strncpy(user, ntp_optarg, strlen(ntp_optarg) + 1); + user = estrdup(OPT_ARG( USER )); group = rindex(user, ':'); if (group) *group++ = '\0'; /* get rid of the ':' */ -#else - fprintf(stderr, - "command line -u/--user option is not supported by this binary" -# ifndef SYS_WINNT - ",\n" "can not drop root privileges. See configure options\n" - "--enable-clockctl and --enable-linuxcaps.\n"); -# else - ".\n"); -# endif - msyslog(LOG_ERR, - "command line -u/--user option is not supported by this binary."); - errflg++; -#endif } +#endif if (HAVE_OPT( VAR )) { int ct = STACKCT_OPT( VAR ); @@ -195,9 +160,10 @@ } while (--ct > 0); } - if (HAVE_OPT( SLEW )) + if (HAVE_OPT( SLEW )) { clock_max = 600; - + kern_enable = 0; + } if (HAVE_OPT( UPDATEINTERVAL )) { long val = OPT_VALUE_UPDATEINTERVAL; @@ -214,32 +180,11 @@ } } #ifdef SIM - if (HAVE_OPT( SIMBROADCASTDELAY )) - sscanf(OPT_ARG( SIMBROADCASTDELAY ), "%lf", &ntp_node.bdly); - - if (HAVE_OPT( PHASENOISE )) - sscanf(OPT_ARG( PHASENOISE ), "%lf", &ntp_node.snse); - - if (HAVE_OPT( SIMSLEW )) - sscanf(OPT_ARG( SIMSLEW ), "%lf", &ntp_node.slew); - if (HAVE_OPT( SERVERTIME )) - sscanf(OPT_ARG( SERVERTIME ), "%lf", &ntp_node.clk_time); - - if (HAVE_OPT( ENDSIMTIME )) - sscanf(OPT_ARG( ENDSIMTIME ), "%lf", &ntp_node.sim_time); - - if (HAVE_OPT( FREQERR )) - sscanf(OPT_ARG( FREQERR ), "%lf", &ntp_node.ferr); - - if (HAVE_OPT( WALKNOISE )) - sscanf(OPT_ARG( WALKNOISE ), "%lf", &ntp_node.fnse); - - if (HAVE_OPT( NDELAY )) - sscanf(OPT_ARG( NDELAY ), "%lf", &ntp_node.ndly); - - if (HAVE_OPT( PDELAY )) - sscanf(OPT_ARG( PDELAY ), "%lf", &ntp_node.pdly); + /* SK: + * The simulator no longer takes any command line arguments. Hence, + * all the code that was here has been removed. + */ #endif /* SIM */ diff -urN src/contrib/ntp/ntpd/complete.conf src.ntp/contrib/ntp/ntpd/complete.conf --- src/contrib/ntp/ntpd/complete.conf 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/complete.conf 2010-04-18 10:05:39.000000000 +0200 @@ -0,0 +1,56 @@ +saveconfigdir "/etc/ntp/conf" +driftfile "/etc/ntp.drift" +logfile "/var/log/ntp.log" +logconfig =all -allinfo -allevents -allstatistics -allstatus +allall -clockinfo -clockevents -clockstatistics -clockstatus +clockall -syncinfo -syncevents -syncstatistics -syncstatus +syncall -sysinfo -sysevents -sysstatistics -sysstatus +sysall +statsdir "/etc/ntp/stats" +statistics loopstats peerstats +filegen clockstats file clockstats type none enable +filegen cryptostats file cryptostats type pid link disable +filegen loopstats file loopstats type day nolink enable +filegen peerstats file peerstats type week enable +filegen protostats file stats type month enable +filegen rawstats file rawstats type year nolink enable +filegen sysstats file sysstats type age enable +filegen timingstats file timingstats type none disable +crypto digest md5 host myhostname ident wedent pw cryptopass randfile /.rnd +revoke 10 +keysdir "/etc/ntp/keys" +keys "/etc/ntp.keys" +trustedkey 1 2 3 4 5 6 7 8 9 10 11 12 (14 ... 16) 18 (32768 ... 65534) +controlkey 12 +requestkey 12 +enable auth ntp monitor +disable bclient calibrate kernel +tos beacon 3600 ceiling 16 cohort 0 floor 1 maxclock 10 maxdist 1.5 minclock 3 mindist 0.001 minsane 1 orphan 16 +tinker allan 1500 dispersion 15 freq 0 huffpuff 7200 panic 1000 step 0.128 stepout 900 +broadcastclient +server 127.127.1.0 mode 64 prefer true +fudge 127.127.1.0 time1 0 time2 1.1 stratum 7 refid Abcd +pool 0.north-america.pool.ntp.org. iburst preempt +server 1.north-america.pool.ntp.org. iburst +server -4 2.north-america.pool.ntp.org. minpoll 6 maxpoll 10 iburst +server -6 ntp.davehart.net. minpoll 6 maxpoll 10 version 5 burst iburst +peer -6 davehart.broker.freenet6.net. xleave autokey +peer -4 192.168.192.168 key 1 bias 3.1416 noselect +broadcast 192.168.192.255 +manycastclient 224.0.1.1 +manycastclient ff05::101 +manycastserver 224.0.1.1 ff05::101 +multicastclient 224.0.1.1 ff05::101 +discard minimum 1 average 3 monitor 1 +restrict default nomodify limited kod +restrict trusted.host.name.example.com. nomodify +restrict [fe80::1] mask [ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff] +restrict 127.0.0.1 mask 255.255.255.255 +restrict ::1 +interface drop ipv6 +interface ignore ipv4 +interface drop wildcard +interface listen eth0 +interface listen ipv6 +interface listen 192.168.192.0/24 +interface listen 192.168.193.1 +setvar varnondef = "this variable does not have default after the value" +setvar vanity = "name plate" default +trap 127.0.0.1 interface 127.0.0.1 port 1234 +trap 127.0.0.2 diff -urN src/contrib/ntp/ntpd/keyword-gen-utd src.ntp/contrib/ntp/ntpd/keyword-gen-utd --- src/contrib/ntp/ntpd/keyword-gen-utd 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/keyword-gen-utd 2010-07-09 04:17:43.000000000 +0200 @@ -0,0 +1 @@ + * Generated 2010-04-06 04:38:11 UTC diff_ignore_line diff -urN src/contrib/ntp/ntpd/keyword-gen.c src.ntp/contrib/ntp/ntpd/keyword-gen.c --- src/contrib/ntp/ntpd/keyword-gen.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/keyword-gen.c 2010-04-18 10:05:39.000000000 +0200 @@ -0,0 +1,663 @@ +/* + * keyword-gen.c -- generate keyword scanner finite state machine and + * keyword_text array. + * This program is run to generate ntp_keyword.h + */ +#include +#include +#include +#include + +#include +#include +#include +#include "ntp_scanner.h" +#include "ntp_parser.h" + + +#ifdef QSORT_USES_VOID_P +typedef const void * QSORTP; +#else +typedef char * QSORTP; +#endif + +/* Define a structure to hold a (keyword, token) pair */ +struct key_tok { + char * key; /* Keyword */ + int token; /* Associated Token */ + follby followedby; /* nonzero indicates the next token(s) + forced to be string(s) */ +}; + +struct key_tok ntp_keywords[] = { +{ "...", T_Ellipsis, FOLLBY_TOKEN }, +{ "automax", T_Automax, FOLLBY_TOKEN }, +{ "broadcast", T_Broadcast, FOLLBY_STRING }, +{ "broadcastclient", T_Broadcastclient, FOLLBY_TOKEN }, +{ "broadcastdelay", T_Broadcastdelay, FOLLBY_TOKEN }, +{ "calldelay", T_Calldelay, FOLLBY_TOKEN }, +{ "disable", T_Disable, FOLLBY_TOKEN }, +{ "driftfile", T_Driftfile, FOLLBY_STRING }, +{ "enable", T_Enable, FOLLBY_TOKEN }, +{ "end", T_End, FOLLBY_TOKEN }, +{ "filegen", T_Filegen, FOLLBY_TOKEN }, +{ "fudge", T_Fudge, FOLLBY_STRING }, +{ "includefile", T_Includefile, FOLLBY_STRING }, +{ "leapfile", T_Leapfile, FOLLBY_STRING }, +{ "logconfig", T_Logconfig, FOLLBY_STRINGS_TO_EOC }, +{ "logfile", T_Logfile, FOLLBY_STRING }, +{ "manycastclient", T_Manycastclient, FOLLBY_STRING }, +{ "manycastserver", T_Manycastserver, FOLLBY_STRINGS_TO_EOC }, +{ "multicastclient", T_Multicastclient, FOLLBY_STRINGS_TO_EOC }, +{ "peer", T_Peer, FOLLBY_STRING }, +{ "phone", T_Phone, FOLLBY_STRINGS_TO_EOC }, +{ "pidfile", T_Pidfile, FOLLBY_STRING }, +{ "pool", T_Pool, FOLLBY_STRING }, +{ "discard", T_Discard, FOLLBY_TOKEN }, +{ "restrict", T_Restrict, FOLLBY_TOKEN }, +{ "server", T_Server, FOLLBY_STRING }, +{ "setvar", T_Setvar, FOLLBY_STRING }, +{ "statistics", T_Statistics, FOLLBY_TOKEN }, +{ "statsdir", T_Statsdir, FOLLBY_STRING }, +{ "tick", T_Tick, FOLLBY_TOKEN }, +{ "tinker", T_Tinker, FOLLBY_TOKEN }, +{ "tos", T_Tos, FOLLBY_TOKEN }, +{ "trap", T_Trap, FOLLBY_STRING }, +{ "unconfig", T_Unconfig, FOLLBY_STRING }, +{ "unpeer", T_Unpeer, FOLLBY_STRING }, +/* authentication_command */ +{ "controlkey", T_ControlKey, FOLLBY_TOKEN }, +{ "crypto", T_Crypto, FOLLBY_TOKEN }, +{ "keys", T_Keys, FOLLBY_STRING }, +{ "keysdir", T_Keysdir, FOLLBY_STRING }, +{ "ntpsigndsocket", T_NtpSignDsocket, FOLLBY_STRING }, +{ "requestkey", T_Requestkey, FOLLBY_TOKEN }, +{ "revoke", T_Revoke, FOLLBY_TOKEN }, +{ "trustedkey", T_Trustedkey, FOLLBY_TOKEN }, +/* IPv4/IPv6 protocol override flag */ +{ "-4", T_Ipv4_flag, FOLLBY_TOKEN }, +{ "-6", T_Ipv6_flag, FOLLBY_TOKEN }, +/* option */ +{ "autokey", T_Autokey, FOLLBY_TOKEN }, +{ "bias", T_Bias, FOLLBY_TOKEN }, +{ "burst", T_Burst, FOLLBY_TOKEN }, +{ "iburst", T_Iburst, FOLLBY_TOKEN }, +{ "key", T_Key, FOLLBY_TOKEN }, +{ "maxpoll", T_Maxpoll, FOLLBY_TOKEN }, +{ "minpoll", T_Minpoll, FOLLBY_TOKEN }, +{ "mode", T_Mode, FOLLBY_TOKEN }, +{ "noselect", T_Noselect, FOLLBY_TOKEN }, +{ "preempt", T_Preempt, FOLLBY_TOKEN }, +{ "true", T_True, FOLLBY_TOKEN }, +{ "prefer", T_Prefer, FOLLBY_TOKEN }, +{ "ttl", T_Ttl, FOLLBY_TOKEN }, +{ "version", T_Version, FOLLBY_TOKEN }, +{ "xleave", T_Xleave, FOLLBY_TOKEN }, +/* crypto_command */ +{ "host", T_Host, FOLLBY_STRING }, +{ "ident", T_Ident, FOLLBY_STRING }, +{ "pw", T_Pw, FOLLBY_STRING }, +{ "randfile", T_Randfile, FOLLBY_STRING }, +{ "sign", T_Sign, FOLLBY_STRING }, +{ "digest", T_Digest, FOLLBY_STRING }, +/*** MONITORING COMMANDS ***/ +/* stat */ +{ "clockstats", T_Clockstats, FOLLBY_TOKEN }, +{ "cryptostats", T_Cryptostats, FOLLBY_TOKEN }, +{ "loopstats", T_Loopstats, FOLLBY_TOKEN }, +{ "peerstats", T_Peerstats, FOLLBY_TOKEN }, +{ "rawstats", T_Rawstats, FOLLBY_TOKEN }, +{ "sysstats", T_Sysstats, FOLLBY_TOKEN }, +{ "protostats", T_Protostats, FOLLBY_TOKEN }, +{ "timingstats", T_Timingstats, FOLLBY_TOKEN }, +/* filegen_option */ +{ "file", T_File, FOLLBY_STRING }, +{ "link", T_Link, FOLLBY_TOKEN }, +{ "nolink", T_Nolink, FOLLBY_TOKEN }, +{ "type", T_Type, FOLLBY_TOKEN }, +/* filegen_type */ +{ "age", T_Age, FOLLBY_TOKEN }, +{ "day", T_Day, FOLLBY_TOKEN }, +{ "month", T_Month, FOLLBY_TOKEN }, +{ "none", T_None, FOLLBY_TOKEN }, +{ "pid", T_Pid, FOLLBY_TOKEN }, +{ "week", T_Week, FOLLBY_TOKEN }, +{ "year", T_Year, FOLLBY_TOKEN }, +/*** ORPHAN MODE COMMANDS ***/ +/* tos_option */ +{ "minclock", T_Minclock, FOLLBY_TOKEN }, +{ "maxclock", T_Maxclock, FOLLBY_TOKEN }, +{ "minsane", T_Minsane, FOLLBY_TOKEN }, +{ "floor", T_Floor, FOLLBY_TOKEN }, +{ "ceiling", T_Ceiling, FOLLBY_TOKEN }, +{ "cohort", T_Cohort, FOLLBY_TOKEN }, +{ "mindist", T_Mindist, FOLLBY_TOKEN }, +{ "maxdist", T_Maxdist, FOLLBY_TOKEN }, +{ "beacon", T_Beacon, FOLLBY_TOKEN }, +{ "orphan", T_Orphan, FOLLBY_TOKEN }, +/* access_control_flag */ +{ "default", T_Default, FOLLBY_TOKEN }, +{ "flake", T_Flake, FOLLBY_TOKEN }, +{ "ignore", T_Ignore, FOLLBY_TOKEN }, +{ "limited", T_Limited, FOLLBY_TOKEN }, +{ "mssntp", T_Mssntp, FOLLBY_TOKEN }, +{ "kod", T_Kod, FOLLBY_TOKEN }, +{ "lowpriotrap", T_Lowpriotrap, FOLLBY_TOKEN }, +{ "mask", T_Mask, FOLLBY_TOKEN }, +{ "nomodify", T_Nomodify, FOLLBY_TOKEN }, +{ "nopeer", T_Nopeer, FOLLBY_TOKEN }, +{ "noquery", T_Noquery, FOLLBY_TOKEN }, +{ "noserve", T_Noserve, FOLLBY_TOKEN }, +{ "notrap", T_Notrap, FOLLBY_TOKEN }, +{ "notrust", T_Notrust, FOLLBY_TOKEN }, +{ "ntpport", T_Ntpport, FOLLBY_TOKEN }, +/* discard_option */ +{ "average", T_Average, FOLLBY_TOKEN }, +{ "minimum", T_Minimum, FOLLBY_TOKEN }, +{ "monitor", T_Monitor, FOLLBY_TOKEN }, +/* fudge_factor */ +{ "flag1", T_Flag1, FOLLBY_TOKEN }, +{ "flag2", T_Flag2, FOLLBY_TOKEN }, +{ "flag3", T_Flag3, FOLLBY_TOKEN }, +{ "flag4", T_Flag4, FOLLBY_TOKEN }, +{ "refid", T_Refid, FOLLBY_STRING }, +{ "stratum", T_Stratum, FOLLBY_TOKEN }, +{ "time1", T_Time1, FOLLBY_TOKEN }, +{ "time2", T_Time2, FOLLBY_TOKEN }, +/* system_option */ +{ "auth", T_Auth, FOLLBY_TOKEN }, +{ "bclient", T_Bclient, FOLLBY_TOKEN }, +{ "calibrate", T_Calibrate, FOLLBY_TOKEN }, +{ "kernel", T_Kernel, FOLLBY_TOKEN }, +{ "ntp", T_Ntp, FOLLBY_TOKEN }, +{ "stats", T_Stats, FOLLBY_TOKEN }, +/* tinker_option */ +{ "step", T_Step, FOLLBY_TOKEN }, +{ "panic", T_Panic, FOLLBY_TOKEN }, +{ "dispersion", T_Dispersion, FOLLBY_TOKEN }, +{ "stepout", T_Stepout, FOLLBY_TOKEN }, +{ "allan", T_Allan, FOLLBY_TOKEN }, +{ "huffpuff", T_Huffpuff, FOLLBY_TOKEN }, +{ "freq", T_Freq, FOLLBY_TOKEN }, +/* miscellaneous_command */ +{ "port", T_Port, FOLLBY_TOKEN }, +{ "interface", T_Interface, FOLLBY_TOKEN }, +{ "qos", T_Qos, FOLLBY_TOKEN }, +{ "saveconfigdir", T_Saveconfigdir, FOLLBY_STRING }, +/* interface_command (ignore and interface already defined) */ +{ "nic", T_Nic, FOLLBY_TOKEN }, +{ "all", T_All, FOLLBY_TOKEN }, +{ "ipv4", T_Ipv4, FOLLBY_TOKEN }, +{ "ipv6", T_Ipv6, FOLLBY_TOKEN }, +{ "wildcard", T_Wildcard, FOLLBY_TOKEN }, +{ "listen", T_Listen, FOLLBY_TOKEN }, +{ "drop", T_Drop, FOLLBY_TOKEN }, +/* simulator commands */ +{ "simulate", T_Simulate, FOLLBY_TOKEN }, +{ "simulation_duration",T_Sim_Duration, FOLLBY_TOKEN }, +{ "beep_delay", T_Beep_Delay, FOLLBY_TOKEN }, +{ "duration", T_Duration, FOLLBY_TOKEN }, +{ "server_offset", T_Server_Offset, FOLLBY_TOKEN }, +{ "freq_offset", T_Freq_Offset, FOLLBY_TOKEN }, +{ "wander", T_Wander, FOLLBY_TOKEN }, +{ "jitter", T_Jitter, FOLLBY_TOKEN }, +{ "prop_delay", T_Prop_Delay, FOLLBY_TOKEN }, +{ "proc_delay", T_Proc_Delay, FOLLBY_TOKEN }, +}; + + +typedef struct big_scan_state_tag { + char ch; /* Character this state matches on */ + char followedby; /* Forces next token(s) to T_String */ + u_short finishes_token; /* nonzero ID if last keyword char */ + u_short match_next_s; /* next state to check matching ch */ + u_short other_next_s; /* next state to check if not ch */ +} big_scan_state; + +/* + * Note: to increase MAXSTATES beyond 2048, be aware it is currently + * crammed into 11 bits in scan_state form. Raising to 4096 would be + * relatively easy by storing the followedby value in a separate + * array with one entry per token, and shrinking the char value to + * 7 bits to free a bit for accepting/non-accepting. More than 4096 + * states will require expanding scan_state beyond 32 bits each. + */ +#define MAXSTATES 2048 + +const char * current_keyword;/* for error reporting */ +big_scan_state sst[MAXSTATES]; /* scanner FSM state entries */ +int sst_highwater; /* next entry index to consider */ +char * symb[1024]; /* map token ID to symbolic name */ + +/* for libntp */ +const char * progname = "keyword-gen"; +volatile int debug = 1; + +int main (int, char **); +static void generate_preamble (void); +static void generate_fsm (void); +static void generate_token_text (void); +static int create_keyword_scanner (void); +static int create_scan_states (char *, int, follby, int); +int compare_key_tok_id (QSORTP, QSORTP); +int compare_key_tok_text (QSORTP, QSORTP); +void populate_symb (char *); +const char * symbname (int); + + +int main(int argc, char **argv) +{ + if (argc < 2) { + fprintf(stderr, "Usage:\n%s t_header.h\n", argv[0]); + exit(1); + } + populate_symb(argv[1]); + + generate_preamble(); + generate_token_text(); + generate_fsm(); + + return 0; +} + + +static void +generate_preamble(void) +{ + time_t now; + char timestamp[128]; + char preamble[] = +"/*\n" +" * ntp_keyword.h\n" +" * \n" +" * NOTE: edit this file with caution, it is generated by keyword-gen.c\n" +" *\t Generated %s UTC diff_ignore_line\n" +" *\n" +" */\n" +"#include \"ntp_scanner.h\"\n" +"#include \"ntp_parser.h\"\n" +"\n"; + + time(&now); + if (!strftime(timestamp, sizeof(timestamp), + "%Y-%m-%d %H:%M:%S", gmtime(&now))) + timestamp[0] = '\0'; + + printf(preamble, timestamp); +} + + +static void +generate_fsm(void) +{ + char token_id_comment[128]; + int initial_state; + int i; + int token; + + /* + * Sort ntp_keywords in alphabetical keyword order. This is + * not necessary, but minimizes nonfunctional changes in the + * generated finite state machine when keywords are modified. + */ + qsort(ntp_keywords, COUNTOF(ntp_keywords), + sizeof(ntp_keywords[0]), compare_key_tok_text); + + /* + * To save space, reserve the state array entry matching each + * token number for its terminal state, so the token identifier + * does not need to be stored in each state, but can be + * recovered trivially. To mark the entry reserved, + * finishes_token is nonzero. + */ + + for (i = 0; i < COUNTOF(ntp_keywords); i++) { + token = ntp_keywords[i].token; + if (1 > token || token >= COUNTOF(sst)) { + fprintf(stderr, + "keyword-gen sst[%u] too small " + "for keyword '%s' id %d\n", + COUNTOF(sst), + ntp_keywords[i].key, + token); + exit(4); + } + sst[token].finishes_token = token; + } + + initial_state = create_keyword_scanner(); + + fprintf(stderr, + "%d keywords consumed %d states of %d max.\n", + (int)COUNTOF(ntp_keywords), + sst_highwater - 1, + (int)COUNTOF(sst) - 1); + + printf("#define SCANNER_INIT_S %d\n\n", initial_state); + + printf("const scan_state sst[%d] = {\n" + "/*SS_T( ch,\tf-by, match, other ),\t\t\t\t */\n" + " 0,\t\t\t\t /* %5d %-17s */\n", + sst_highwater, + 0, ""); + + for (i = 1; i < sst_highwater; i++) { + + /* verify fields will fit */ + if (sst[i].followedby & ~0x3) { + fprintf(stderr, + "keyword-gen internal error " + "sst[%d].followedby %d too big\n", + i, sst[i].followedby); + exit(7); + } + + if (sst_highwater <= sst[i].match_next_s + || sst[i].match_next_s & ~0x7ff) { + fprintf(stderr, + "keyword-gen internal error " + "sst[%d].match_next_s %d too big\n", + i, sst[i].match_next_s); + exit(8); + } + + if (sst_highwater <= sst[i].other_next_s + || sst[i].other_next_s & ~0x7ff) { + fprintf(stderr, + "keyword-gen internal error " + "sst[%d].other_next_s %d too big\n", + i, sst[i].other_next_s); + exit(9); + } + + if (!sst[i].finishes_token) + snprintf(token_id_comment, + sizeof(token_id_comment), "%5d %-17s", + i, (initial_state == i) + ? "initial state" + : ""); + else { + snprintf(token_id_comment, + sizeof(token_id_comment), "%5d %-17s", + i, symbname(sst[i].finishes_token)); + if (i != sst[i].finishes_token) { + fprintf(stderr, + "keyword-gen internal error " + "entry %d finishes token %d\n", + i, sst[i].finishes_token); + exit(5); + } + } + + printf(" S_ST( '%c',\t%d, %5u, %5u )%s /* %s */\n", + sst[i].ch, + sst[i].followedby, + sst[i].match_next_s, + sst[i].other_next_s, + (i + 1 < sst_highwater) + ? "," + : " ", + token_id_comment); + } + + printf("};\n\n"); +} + + +/* Define a function to create the states of the scanner. This function + * is used by the create_keyword_scanner function below. + * + * This function takes a suffix of a keyword, the token to be returned on + * recognizing the complete keyword, and any pre-existing state that exists + * for some other keyword that has the same prefix as the current one. + */ +static int +create_scan_states( + char * text, + int token, + follby followedby, + int prev_state + ) +{ + int my_state; + int return_state; + int prev_char_s; + int curr_char_s; + + return_state = prev_state; + curr_char_s = prev_state; + prev_char_s = 0; + + /* Find the correct position to insert the state. + * All states should be in alphabetical order + */ + while (curr_char_s && (text[0] < sst[curr_char_s].ch)) { + prev_char_s = curr_char_s; + curr_char_s = sst[curr_char_s].other_next_s; + } + + /* + * Check if a previously seen keyword has the same prefix as + * the current keyword. If so, simply use the state for that + * keyword as my_state, otherwise, allocate a new state. + */ + if (curr_char_s && (text[0] == sst[curr_char_s].ch)) { + my_state = curr_char_s; + if ('\0' == text[1]) { + fprintf(stderr, + "Duplicate entries for keyword '%s' in" + " keyword_gen.c ntp_keywords[].\n", + current_keyword); + exit(2); + } + } else { + do + my_state = sst_highwater++; + while (my_state < COUNTOF(sst) + && sst[my_state].finishes_token); + if (my_state >= COUNTOF(sst)) { + fprintf(stderr, + "fatal, keyword scanner state array " + "sst[%d] is too small, modify\n" + "keyword-gen.c to increase.\n", + (int)COUNTOF(sst)); + exit(3); + } + /* Store the next character of the keyword */ + sst[my_state].ch = text[0]; + sst[my_state].other_next_s = curr_char_s; + sst[my_state].followedby = FOLLBY_NON_ACCEPTING; + + if (prev_char_s) + sst[prev_char_s].other_next_s = my_state; + else + return_state = my_state; + } + + /* Check if the next character is '\0'. + * If yes, we are done with the recognition and this is an accepting + * state. + * If not, we need to continue scanning + */ + if ('\0' == text[1]) { + sst[my_state].finishes_token = (u_short)token; + sst[my_state].followedby = (char)followedby; + + if (sst[token].finishes_token != (u_short)token) { + fprintf(stderr, + "fatal, sst[%d] not reserved for %s.\n", + token, symbname(token)); + exit(6); + } + /* relocate so token id is sst[] index */ + if (my_state != token) { + sst[token] = sst[my_state]; + memset(&sst[my_state], 0, + sizeof(sst[my_state])); + do + sst_highwater--; + while (sst[sst_highwater].finishes_token); + my_state = token; + if (prev_char_s) + sst[prev_char_s].other_next_s = my_state; + else + return_state = my_state; + } + } else + sst[my_state].match_next_s = + create_scan_states( + &text[1], + token, + followedby, + sst[my_state].match_next_s); + + return return_state; +} + + +/* Define a function that takes a list of (keyword, token) values and + * creates a keywords scanner out of it. + */ + +static int +create_keyword_scanner(void) +{ + int scanner; + int i; + + sst_highwater = 1; /* index 0 invalid, unused */ + scanner = 0; + + for (i = 0; i < COUNTOF(ntp_keywords); i++) { + current_keyword = ntp_keywords[i].key; + scanner = + create_scan_states( + ntp_keywords[i].key, + ntp_keywords[i].token, + ntp_keywords[i].followedby, + scanner); + } + + return scanner; +} + + +static void +generate_token_text(void) +{ + int lowest_id; + int highest_id; + int id_count; + int id; + int i; + + /* sort ntp_keywords in token ID order */ + qsort(ntp_keywords, COUNTOF(ntp_keywords), + sizeof(ntp_keywords[0]), compare_key_tok_id); + + lowest_id = ntp_keywords[0].token; + highest_id = ntp_keywords[COUNTOF(ntp_keywords) - 1].token; + id_count = highest_id - lowest_id + 1; + + printf("#define LOWEST_KEYWORD_ID %d\n\n", lowest_id); + + printf("const char * const keyword_text[%d] = {", id_count); + + id = lowest_id; + i = 0; + while (i < COUNTOF(ntp_keywords)) { + while (id < ntp_keywords[i].token) { + printf(",\n\t/* %-5d %5d %20s */\tNULL", + id - lowest_id, id, symbname(id)); + id++; + } + if (i > 0) + printf(","); + printf("\n\t/* %-5d %5d %20s */\t\"%s\"", + id - lowest_id, id, symbname(id), + ntp_keywords[i].key); + i++; + id++; + } + + printf("\n};\n\n"); +} + + +int +compare_key_tok_id( + QSORTP a1, + QSORTP a2 + ) +{ + const struct key_tok *p1 = (const void *)a1; + const struct key_tok *p2 = (const void *)a2; + + if (p1->token == p2->token) + return 0; + + if (p1->token < p2->token) + return -1; + else + return 1; +} + + +int +compare_key_tok_text( + QSORTP a1, + QSORTP a2 + ) +{ + const struct key_tok *p1 = (const void *)a1; + const struct key_tok *p2 = (const void *)a2; + + return strcmp(p1->key, p2->key); +} + + +/* + * populate_symb() - populate symb[] lookup array with symbolic token + * names such that symb[T_Age] == "T_Age", etc. + */ +void +populate_symb( + char *header_file + ) +{ + FILE * yh; + char line[128]; + char name[128]; + int token; + + yh = fopen(header_file, "r"); + if (NULL == yh) { + perror("unable to open yacc/bison header file"); + exit(4); + } + + while (NULL != fgets(line, sizeof(line), yh)) + if (2 == sscanf(line, "#define %s %d", name, &token) + && 'T' == name[0] && '_' == name[1] && token >= 0 + && token < COUNTOF(symb)) + + symb[token] = estrdup(name); + + fclose(yh); +} + + +const char * +symbname( + int token + ) +{ + char *name; + + if (token >= 0 && token < COUNTOF(symb) && symb[token] != NULL) + return symb[token]; + + LIB_GETBUF(name); + snprintf(name, LIB_BUFLENGTH, "%d", token); + return name; +} diff -urN src/contrib/ntp/ntpd/ntp_config.c src.ntp/contrib/ntp/ntpd/ntp_config.c --- src/contrib/ntp/ntpd/ntp_config.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/ntp_config.c 2010-07-07 12:01:06.000000000 +0200 @@ -1,6 +1,14 @@ -/* - * ntp_config.c - read and apply configuration information +/* ntp_config.c + * + * This file contains the ntpd configuration code. + * + * Written By: Sachin Kamboj + * University of Delaware + * Newark, DE 19711 + * Some parts borrowed from the older ntp_config.c + * Copyright (c) 2006 */ + #ifdef HAVE_CONFIG_H # include #endif @@ -9,20 +17,30 @@ # include #endif +#include "ntp.h" #include "ntpd.h" #include "ntp_io.h" #include "ntp_unixtime.h" #include "ntp_refclock.h" #include "ntp_filegen.h" #include "ntp_stdlib.h" +#include "ntp_assert.h" +#include "ntpd-opts.h" +/* + * Sim header. Currently unconditionally included + * PDMXXX This needs to be a conditional include + */ +#include "ntpsim.h" + #include +#include "ntp_intres.h" #include #include #include #include #ifdef HAVE_SYS_PARAM_H -#include +# include #endif #include #ifndef SIGCHLD @@ -36,7 +54,6 @@ #ifdef SYS_WINNT # include -static HANDLE ResolverThreadHandle = NULL; HANDLE ResolverEventHandle; #else int resolver_pipe_fd[2]; /* used to let the resolver process alert the parent process */ @@ -50,246 +67,10 @@ #include "ntp_config.h" #include "ntp_cmdargs.h" -extern int priority_done; - -/* - * These routines are used to read the configuration file at - * startup time. An entry in the file must fit on a single line. - * Entries are processed as multiple tokens separated by white space - * Lines are considered terminated when a '#' is encountered. Blank - * lines are ignored. - */ -/* - * Translation table - keywords to function index - */ -struct keyword { - const char *text; - int keytype; -}; - -/* - * Command keywords - */ -static struct keyword keywords[] = { - { "automax", CONFIG_AUTOMAX }, - { "broadcast", CONFIG_BROADCAST }, - { "broadcastclient", CONFIG_BROADCASTCLIENT }, - { "broadcastdelay", CONFIG_BDELAY }, - { "calldelay", CONFIG_CDELAY}, -#ifdef OPENSSL - { "crypto", CONFIG_CRYPTO }, -#endif /* OPENSSL */ - { "controlkey", CONFIG_CONTROLKEY }, - { "disable", CONFIG_DISABLE }, - { "driftfile", CONFIG_DRIFTFILE }, - { "enable", CONFIG_ENABLE }, - { "end", CONFIG_END }, - { "filegen", CONFIG_FILEGEN }, - { "fudge", CONFIG_FUDGE }, - { "includefile", CONFIG_INCLUDEFILE }, - { "keys", CONFIG_KEYS }, - { "keysdir", CONFIG_KEYSDIR }, - { "logconfig", CONFIG_LOGCONFIG }, - { "logfile", CONFIG_LOGFILE }, - { "manycastclient", CONFIG_MANYCASTCLIENT }, - { "manycastserver", CONFIG_MANYCASTSERVER }, - { "multicastclient", CONFIG_MULTICASTCLIENT }, - { "peer", CONFIG_PEER }, - { "phone", CONFIG_PHONE }, - { "pidfile", CONFIG_PIDFILE }, - { "discard", CONFIG_DISCARD }, - { "requestkey", CONFIG_REQUESTKEY }, - { "restrict", CONFIG_RESTRICT }, - { "revoke", CONFIG_REVOKE }, - { "server", CONFIG_SERVER }, - { "setvar", CONFIG_SETVAR }, - { "statistics", CONFIG_STATISTICS }, - { "statsdir", CONFIG_STATSDIR }, - { "tick", CONFIG_ADJ }, - { "tinker", CONFIG_TINKER }, - { "tos", CONFIG_TOS }, - { "trap", CONFIG_TRAP }, - { "trustedkey", CONFIG_TRUSTEDKEY }, - { "ttl", CONFIG_TTL }, - { "", CONFIG_UNKNOWN } -}; - -/* - * "peer", "server", "broadcast" modifier keywords - */ -static struct keyword mod_keywords[] = { - { "autokey", CONF_MOD_SKEY }, - { "burst", CONF_MOD_BURST }, - { "iburst", CONF_MOD_IBURST }, - { "key", CONF_MOD_KEY }, - { "maxpoll", CONF_MOD_MAXPOLL }, - { "minpoll", CONF_MOD_MINPOLL }, - { "mode", CONF_MOD_MODE }, /* refclocks */ - { "noselect", CONF_MOD_NOSELECT }, - { "preempt", CONF_MOD_PREEMPT }, - { "true", CONF_MOD_TRUE }, - { "prefer", CONF_MOD_PREFER }, - { "ttl", CONF_MOD_TTL }, /* NTP peers */ - { "version", CONF_MOD_VERSION }, - { "dynamic", CONF_MOD_DYNAMIC }, - { "", CONFIG_UNKNOWN } -}; - -/* - * "restrict" modifier keywords - */ -static struct keyword res_keywords[] = { - { "ignore", CONF_RES_IGNORE }, - { "limited", CONF_RES_LIMITED }, - { "kod", CONF_RES_DEMOBILIZE }, - { "lowpriotrap", CONF_RES_LPTRAP }, - { "mask", CONF_RES_MASK }, - { "nomodify", CONF_RES_NOMODIFY }, - { "nopeer", CONF_RES_NOPEER }, - { "noquery", CONF_RES_NOQUERY }, - { "noserve", CONF_RES_NOSERVE }, - { "notrap", CONF_RES_NOTRAP }, - { "notrust", CONF_RES_NOTRUST }, - { "ntpport", CONF_RES_NTPPORT }, - { "version", CONF_RES_VERSION }, - { "", CONFIG_UNKNOWN } -}; - -/* - * "trap" modifier keywords - */ -static struct keyword trap_keywords[] = { - { "port", CONF_TRAP_PORT }, - { "interface", CONF_TRAP_INTERFACE }, - { "", CONFIG_UNKNOWN } -}; - -/* - * "fudge" modifier keywords - */ -static struct keyword fudge_keywords[] = { - { "flag1", CONF_FDG_FLAG1 }, - { "flag2", CONF_FDG_FLAG2 }, - { "flag3", CONF_FDG_FLAG3 }, - { "flag4", CONF_FDG_FLAG4 }, - { "refid", CONF_FDG_REFID }, /* this mapping should be cleaned up (endianness, \0) - kd 20041031 */ - { "stratum", CONF_FDG_STRATUM }, - { "time1", CONF_FDG_TIME1 }, - { "time2", CONF_FDG_TIME2 }, - { "", CONFIG_UNKNOWN } -}; - -/* - * "filegen" modifier keywords - */ -static struct keyword filegen_keywords[] = { - { "disable", CONF_FGEN_FLAG_DISABLE }, - { "enable", CONF_FGEN_FLAG_ENABLE }, - { "file", CONF_FGEN_FILE }, - { "link", CONF_FGEN_FLAG_LINK }, - { "nolink", CONF_FGEN_FLAG_NOLINK }, - { "type", CONF_FGEN_TYPE }, - { "", CONFIG_UNKNOWN } -}; - -/* - * "type" modifier keywords - */ -static struct keyword fgen_types[] = { - { "age", FILEGEN_AGE }, - { "day", FILEGEN_DAY }, - { "month", FILEGEN_MONTH }, - { "none", FILEGEN_NONE }, - { "pid", FILEGEN_PID }, - { "week", FILEGEN_WEEK }, - { "year", FILEGEN_YEAR }, - { "", CONFIG_UNKNOWN} -}; - -/* - * "enable", "disable" modifier keywords - */ -static struct keyword flags_keywords[] = { - { "auth", PROTO_AUTHENTICATE }, - { "bclient", PROTO_BROADCLIENT }, - { "calibrate", PROTO_CAL }, - { "kernel", PROTO_KERNEL }, - { "monitor", PROTO_MONITOR }, - { "ntp", PROTO_NTP }, - { "stats", PROTO_FILEGEN }, - { "", CONFIG_UNKNOWN } -}; - -/* - * "discard" modifier keywords - */ -static struct keyword discard_keywords[] = { - { "average", CONF_DISCARD_AVERAGE }, - { "minimum", CONF_DISCARD_MINIMUM }, - { "monitor", CONF_DISCARD_MONITOR }, - { "", CONFIG_UNKNOWN } -}; - -/* - * "tinker" modifier keywords - */ -static struct keyword tinker_keywords[] = { - { "step", CONF_CLOCK_MAX }, - { "panic", CONF_CLOCK_PANIC }, - { "dispersion", CONF_CLOCK_PHI }, - { "stepout", CONF_CLOCK_MINSTEP }, - { "allan", CONF_CLOCK_ALLAN }, - { "huffpuff", CONF_CLOCK_HUFFPUFF }, - { "freq", CONF_CLOCK_FREQ }, - { "", CONFIG_UNKNOWN } -}; - -/* - * "tos" modifier keywords - */ -static struct keyword tos_keywords[] = { - { "minclock", CONF_TOS_MINCLOCK }, - { "maxclock", CONF_TOS_MAXCLOCK }, - { "minsane", CONF_TOS_MINSANE }, - { "floor", CONF_TOS_FLOOR }, - { "ceiling", CONF_TOS_CEILING }, - { "cohort", CONF_TOS_COHORT }, - { "mindist", CONF_TOS_MINDISP }, - { "maxdist", CONF_TOS_MAXDIST }, - { "maxhop", CONF_TOS_MAXHOP }, - { "beacon", CONF_TOS_BEACON }, - { "orphan", CONF_TOS_ORPHAN }, - { "", CONFIG_UNKNOWN } -}; - -#ifdef OPENSSL -/* - * "crypto" modifier keywords - */ -static struct keyword crypto_keywords[] = { - { "cert", CONF_CRYPTO_CERT }, - { "gqpar", CONF_CRYPTO_GQPAR }, - { "host", CONF_CRYPTO_RSA }, - { "ident", CONF_CRYPTO_IDENT }, - { "iffpar", CONF_CRYPTO_IFFPAR }, - { "leap", CONF_CRYPTO_LEAP }, - { "mvpar", CONF_CRYPTO_MVPAR }, - { "pw", CONF_CRYPTO_PW }, - { "randfile", CONF_CRYPTO_RAND }, - { "sign", CONF_CRYPTO_SIGN }, - { "", CONFIG_UNKNOWN } -}; -#endif /* OPENSSL */ +#include "ntp_scanner.h" +#include "ntp_parser.h" +#include "ntp_data_structures.h" -/* - * Address type selection, IPv4 or IPv4. - * Used on various lines. - */ -static struct keyword addr_type[] = { - { "-4", CONF_ADDR_IPV4 }, - { "-6", CONF_ADDR_IPV6 }, - { "", CONFIG_UNKNOWN } -}; /* * "logconfig" building blocks @@ -324,14 +105,9 @@ { (char *)0, 0 } }; -/* - * Limits on things - */ -#define MAXTOKENS 20 /* 20 tokens on line */ -#define MAXLINE 1024 /* maximum length of line */ +/* Limits */ #define MAXPHONE 10 /* maximum number of phone strings */ #define MAXPPS 20 /* maximum length of PPS device string */ -#define MAXINCLUDELEVEL 5 /* maximum include file levels */ /* * Miscellaneous macros @@ -341,14 +117,11 @@ #define ISSPACE(c) ((c) == ' ' || (c) == '\t') #define STREQ(a, b) (*(a) == *(b) && strcmp((a), (b)) == 0) -#define KEY_TYPE_MD5 4 - /* * File descriptor used by the resolver save routines, and temporary file * name. */ int call_resolver = 1; /* ntp-genkeys sets this to 0, for example */ -static FILE *res_fp; #ifndef SYS_WINNT static char res_file[20]; /* enough for /tmp/ntpXXXXXX\0 */ #define RES_TEMPFILE "/tmp/ntpXXXXXX" @@ -359,25 +132,38 @@ /* * Definitions of things either imported from or exported to outside */ - -short default_ai_family = AF_UNSPEC; /* Default either IPv4 or IPv6 */ -char *sys_phone[MAXPHONE] = {NULL}; /* ACTS phone numbers */ -char *keysdir = NTP_KEYSDIR; /* crypto keys directory */ +extern int yydebug; /* ntp_parser.c (.y) */ +int curr_include_level; /* The current include level */ +struct FILE_INFO *fp[MAXINCLUDELEVEL+1]; +FILE *res_fp; +struct config_tree cfgt; /* Parser output stored here */ +struct config_tree *cfg_tree_history = NULL; /* History of configs */ +char *sys_phone[MAXPHONE] = {NULL}; /* ACTS phone numbers */ +char default_keysdir[] = NTP_KEYSDIR; +char *keysdir = default_keysdir; /* crypto keys directory */ +char * saveconfigdir; #if defined(HAVE_SCHED_SETSCHEDULER) int config_priority_override = 0; int config_priority; #endif const char *config_file; +char default_ntp_signd_socket[] = +#ifdef NTP_SIGND_PATH + NTP_SIGND_PATH; +#else + ""; +#endif +char *ntp_signd_socket = default_ntp_signd_socket; #ifdef HAVE_NETINFO - struct netinfo_config_state *config_netinfo = NULL; - int check_netinfo = 1; +struct netinfo_config_state *config_netinfo = NULL; +int check_netinfo = 1; #endif /* HAVE_NETINFO */ #ifdef SYS_WINNT - char *alt_config_file; - LPTSTR temp; - char config_file_storage[MAX_PATH]; - char alt_config_file_storage[MAX_PATH]; +char *alt_config_file; +LPTSTR temp; +char config_file_storage[MAX_PATH]; +char alt_config_file_storage[MAX_PATH]; #endif /* SYS_WINNT */ #ifdef HAVE_NETINFO @@ -393,1513 +179,3742 @@ }; #endif +struct REMOTE_CONFIG_INFO remote_config; /* Remote configuration buffer and + pointer info */ +int input_from_file = 1; /* A boolean flag, which when set, indicates that + the input is to be taken from the configuration + file, instead of the remote-configuration buffer + */ + +int old_config_style = 1; /* A boolean flag, which when set, + * indicates that the old configuration + * format with a newline at the end of + * every command is being used + */ +int cryptosw; /* crypto command called */ + +extern int sys_maxclock; +extern char *stats_drift_file; /* name of the driftfile */ +extern char *leapseconds_file_name; /*name of the leapseconds file */ +#ifdef HAVE_IPTOS_SUPPORT +extern unsigned int qos; /* QoS setting */ +#endif /* HAVE_IPTOS_SUPPORT */ + +#ifdef BC_LIST_FRAMEWORK_NOT_YET_USED /* - * Function prototypes + * backwards compatibility flags */ -static unsigned long get_pfxmatch P((char **, struct masks *)); -static unsigned long get_match P((char *, struct masks *)); -static unsigned long get_logmask P((char *)); -#ifdef HAVE_NETINFO -static struct netinfo_config_state *get_netinfo_config P((void)); -static void free_netinfo_config P((struct netinfo_config_state *)); -static int gettokens_netinfo P((struct netinfo_config_state *, char **, int *)); +bc_entry bc_list[] = { + { T_Bc_bugXXXX, 1 } /* default enabled */ +}; + +/* + * declare an int pointer for each flag for quick testing without + * walking bc_list. If the pointer is consumed by libntp rather + * than ntpd, declare it in a libntp source file pointing to storage + * initialized with the appropriate value for other libntp clients, and + * redirect it to point into bc_list during ntpd startup. + */ +int *p_bcXXXX_enabled = &bc_list[0].enabled; #endif -static int gettokens P((FILE *, char *, char **, int *)); -static int matchkey P((char *, struct keyword *, int)); + +/* FUNCTION PROTOTYPES */ + +static void apply_enable_disable(queue *q, int enable); +static void init_syntax_tree(struct config_tree *); + +#ifdef FREE_CFG_T +static void free_auth_node(struct config_tree *); + +static void free_config_other_modes(struct config_tree *); +static void free_config_auth(struct config_tree *); +static void free_config_tos(struct config_tree *); +static void free_config_monitor(struct config_tree *); +static void free_config_access(struct config_tree *); +static void free_config_tinker(struct config_tree *); +static void free_config_system_opts(struct config_tree *); +static void free_config_logconfig(struct config_tree *); +static void free_config_phone(struct config_tree *); +static void free_config_qos(struct config_tree *); +static void free_config_setvar(struct config_tree *); +static void free_config_ttl(struct config_tree *); +static void free_config_trap(struct config_tree *); +static void free_config_fudge(struct config_tree *); +static void free_config_vars(struct config_tree *); +static void free_config_peers(struct config_tree *); +static void free_config_unpeers(struct config_tree *); +static void free_config_nic_rules(struct config_tree *); +#ifdef SIM +static void free_config_sim(struct config_tree *); +#endif + + void free_all_config_trees(void); /* atexit() */ +static void free_config_tree(struct config_tree *ptree); +#endif /* FREE_CFG_T */ + +double *create_dval(double val); +void destroy_restrict_node(struct restrict_node *my_node); +static int is_sane_resolved_address(sockaddr_u *peeraddr, int hmode); +static int get_correct_host_mode(int hmode); +static void save_and_apply_config_tree(void); +void getconfig(int argc,char *argv[]); +#if !defined(SIM) +static sockaddr_u *get_next_address(struct address_node *addr); +#endif + +static void config_other_modes(struct config_tree *); +static void config_auth(struct config_tree *); +static void config_tos(struct config_tree *); +static void config_monitor(struct config_tree *); +static void config_access(struct config_tree *); +static void config_tinker(struct config_tree *); +static void config_system_opts(struct config_tree *); +static void config_logconfig(struct config_tree *); +static void config_phone(struct config_tree *); +static void config_qos(struct config_tree *); +static void config_setvar(struct config_tree *); +static void config_ttl(struct config_tree *); +static void config_trap(struct config_tree *); +static void config_fudge(struct config_tree *); +static void config_vars(struct config_tree *); +static void config_peers(struct config_tree *); +static void config_unpeers(struct config_tree *); +static void config_nic_rules(struct config_tree *); + +#ifdef SIM +static void config_sim(struct config_tree *); +static void config_ntpdsim(struct config_tree *); +#else +static void config_ntpd(struct config_tree *); +#endif + enum gnn_type { t_UNK, /* Unknown */ t_REF, /* Refclock */ t_MSK /* Network Mask */ - }; -static int getnetnum P((const char *, struct sockaddr_storage *, int, - enum gnn_type)); -static void save_resolve P((char *, int, int, int, int, u_int, int, - keyid_t, u_char *)); -static void do_resolve_internal P((void)); -static void abort_resolve P((void)); -#if !defined(VMS) && !defined(SYS_WINNT) -static RETSIGTYPE catchchild P((int)); -#endif /* VMS */ +}; -/* - * get_pfxmatch - find value for prefixmatch - * and update char * accordingly +#define DESTROY_QUEUE(q) \ +do { \ + if (q) { \ + destroy_queue(q); \ + (q) = NULL; \ + } \ +} while (0) + +void ntpd_set_tod_using(const char *); +static unsigned long get_pfxmatch(char **s,struct masks *m); +static unsigned long get_match(char *s,struct masks *m); +static unsigned long get_logmask(char *s); +static int getnetnum(const char *num,sockaddr_u *addr, int complain, + enum gnn_type a_type); +static int get_multiple_netnums(const char *num, sockaddr_u *addr, + struct addrinfo **res, int complain, + enum gnn_type a_type); +static void save_resolve(char *name, int no_needed, int type, + int mode, int version, int minpoll, int maxpoll, + u_int flags, int ttl, keyid_t keyid, u_char *keystr); +static void abort_resolve(void); +static void do_resolve_internal(void); + + + +/* FUNCTIONS FOR INITIALIZATION + * ---------------------------- */ -static unsigned long -get_pfxmatch( - char ** s, - struct masks *m + +#ifdef FREE_CFG_T +static void +free_auth_node( + struct config_tree *ptree ) { - while (m->name) { - if (strncmp(*s, m->name, strlen(m->name)) == 0) { - *s += strlen(m->name); - return m->mask; - } else { - m++; - } + if (ptree->auth.keys) { + free(ptree->auth.keys); + ptree->auth.keys = NULL; } - return 0; -} -/* - * get_match - find logmask value - */ -static unsigned long -get_match( - char *s, - struct masks *m - ) -{ - while (m->name) { - if (strcmp(s, m->name) == 0) { - return m->mask; - } else { - m++; - } + if (ptree->auth.keysdir) { + free(ptree->auth.keysdir); + ptree->auth.keysdir = NULL; + } + + if (ptree->auth.ntp_signd_socket) { + free(ptree->auth.ntp_signd_socket); + ptree->auth.ntp_signd_socket = NULL; } - return 0; } +#endif /* DEBUG */ -/* - * get_logmask - build bitmask for ntp_syslogmask - */ -static unsigned long -get_logmask( - char *s + +static void +init_syntax_tree( + struct config_tree *ptree ) { - char *t; - unsigned long offset; - unsigned long mask; - - t = s; - offset = get_pfxmatch(&t, logcfg_class); - mask = get_match(t, logcfg_item); - - if (mask) - return mask << offset; - else - msyslog(LOG_ERR, "logconfig: illegal argument %s - ignored", s); + memset(ptree, 0, sizeof(*ptree)); - return 0; + ptree->peers = create_queue(); + ptree->unpeers = create_queue(); + ptree->orphan_cmds = create_queue(); + ptree->manycastserver = create_queue(); + ptree->multicastclient = create_queue(); + ptree->stats_list = create_queue(); + ptree->filegen_opts = create_queue(); + ptree->discard_opts = create_queue(); + ptree->restrict_opts = create_queue(); + ptree->enable_opts = create_queue(); + ptree->disable_opts = create_queue(); + ptree->tinker = create_queue(); + ptree->fudge = create_queue(); + ptree->logconfig = create_queue(); + ptree->phone = create_queue(); + ptree->qos = create_queue(); + ptree->setvar = create_queue(); + ptree->ttl = create_queue(); + ptree->trap = create_queue(); + ptree->vars = create_queue(); + ptree->nic_rules = create_queue(); + ptree->auth.crypto_cmd_list = create_queue(); + ptree->auth.trusted_key_list = create_queue(); } -/* - * getconfig - get command line options and read the configuration file - */ +#ifdef FREE_CFG_T void -getconfig( - int argc, - char *argv[] - ) +free_all_config_trees(void) { - register int i; - int c; - int errflg; - int status; - int istart; - int peerversion; - int minpoll; - int maxpoll; - int ttl; - long stratum; - unsigned long ul; - keyid_t peerkey; - u_char *peerkeystr; - u_long fudgeflag; - u_int peerflags; - int hmode; - struct sockaddr_storage peeraddr; - struct sockaddr_storage maskaddr; - FILE *fp[MAXINCLUDELEVEL+1]; - FILE *includefile; - int includelevel = 0; - char line[MAXLINE]; - char *(tokens[MAXTOKENS]); - int ntokens = 0; - int tok = CONFIG_UNKNOWN; - struct interface *localaddr; - struct refclockstat clock_stat; - FILEGEN *filegen; + struct config_tree *ptree; + struct config_tree *pnext; - /* - * Initialize, initialize - */ - errflg = 0; - -#ifndef SYS_WINNT - config_file = CONFIG_FILE; -#else - temp = CONFIG_FILE; - if (!ExpandEnvironmentStrings((LPCTSTR)temp, (LPTSTR)config_file_storage, (DWORD)sizeof(config_file_storage))) { - msyslog(LOG_ERR, "ExpandEnvironmentStrings CONFIG_FILE failed: %m\n"); - exit(1); - } - config_file = config_file_storage; + ptree = cfg_tree_history; - temp = ALT_CONFIG_FILE; - if (!ExpandEnvironmentStrings((LPCTSTR)temp, (LPTSTR)alt_config_file_storage, (DWORD)sizeof(alt_config_file_storage))) { - msyslog(LOG_ERR, "ExpandEnvironmentStrings ALT_CONFIG_FILE failed: %m\n"); - exit(1); + while (ptree != NULL) { + pnext = ptree->link; + free_config_tree(ptree); + ptree = pnext; } - alt_config_file = alt_config_file_storage; +} -#endif /* SYS_WINNT */ - res_fp = NULL; - ntp_syslogmask = NLOG_SYNCMASK; /* set more via logconfig */ - /* - * install a non default variable with this daemon version - */ - (void) sprintf(line, "daemon_version=\"%s\"", Version); - set_sys_var(line, strlen(line)+1, RO); +static void +free_config_tree( + struct config_tree *ptree + ) +{ +#if defined(_MSC_VER) && defined (_DEBUG) + _CrtCheckMemory(); +#endif - /* - * Say how we're setting the time of day - */ - (void) sprintf(line, "settimeofday=\"%s\"", set_tod_using); - set_sys_var(line, strlen(line)+1, RO); + if (ptree->source.value.s != NULL) + free(ptree->source.value.s); + free_config_other_modes(ptree); + free_config_auth(ptree); + free_config_tos(ptree); + free_config_monitor(ptree); + free_config_access(ptree); + free_config_tinker(ptree); + free_config_system_opts(ptree); + free_config_logconfig(ptree); + free_config_phone(ptree); + free_config_qos(ptree); + free_config_setvar(ptree); + free_config_ttl(ptree); + free_config_trap(ptree); + free_config_fudge(ptree); + free_config_vars(ptree); + free_config_peers(ptree); + free_config_unpeers(ptree); + free_config_nic_rules(ptree); +#ifdef SIM + free_config_sim(ptree); +#endif /* - * Initialize the loop. + * Most of these DESTROY_QUEUE()s are handled already by the + * free_config_*() routines above but it's safe to use twice. + * Please feel free to remove ones you verified are handled + * in a free_config_*() routine. */ - loop_config(LOOP_DRIFTINIT, 0.); + DESTROY_QUEUE(ptree->peers); + DESTROY_QUEUE(ptree->unpeers); + DESTROY_QUEUE(ptree->orphan_cmds); + DESTROY_QUEUE(ptree->manycastserver); + DESTROY_QUEUE(ptree->multicastclient); + DESTROY_QUEUE(ptree->stats_list); + DESTROY_QUEUE(ptree->filegen_opts); + DESTROY_QUEUE(ptree->discard_opts); + DESTROY_QUEUE(ptree->restrict_opts); + DESTROY_QUEUE(ptree->enable_opts); + DESTROY_QUEUE(ptree->disable_opts); + DESTROY_QUEUE(ptree->tinker); + DESTROY_QUEUE(ptree->fudge); + DESTROY_QUEUE(ptree->logconfig); + DESTROY_QUEUE(ptree->phone); + DESTROY_QUEUE(ptree->qos); + DESTROY_QUEUE(ptree->setvar); + DESTROY_QUEUE(ptree->ttl); + DESTROY_QUEUE(ptree->trap); + DESTROY_QUEUE(ptree->vars); - getCmdOpts(argc, argv); + free_auth_node(ptree); - if ( - (fp[0] = fopen(FindConfig(config_file), "r")) == NULL -#ifdef HAVE_NETINFO - /* If there is no config_file, try NetInfo. */ - && check_netinfo && !(config_netinfo = get_netinfo_config()) -#endif /* HAVE_NETINFO */ - ) { - fprintf(stderr, "getconfig: Couldn't open <%s>\n", FindConfig(config_file)); - msyslog(LOG_INFO, "getconfig: Couldn't open <%s>", FindConfig(config_file)); -#ifdef SYS_WINNT - /* Under WinNT try alternate_config_file name, first NTP.CONF, then NTP.INI */ + free(ptree); + +#if defined(_MSC_VER) && defined (_DEBUG) + _CrtCheckMemory(); +#endif +} +#endif /* FREE_CFG_T */ - if ((fp[0] = fopen(FindConfig(alt_config_file), "r")) == NULL) { - /* - * Broadcast clients can sometimes run without - * a configuration file. - */ +#ifdef SAVECONFIG +/* Dump all trees */ +int +dump_all_config_trees( + FILE *df, + int comment + ) +{ + struct config_tree *cfg_ptr = cfg_tree_history; + int return_value = 0; - fprintf(stderr, "getconfig: Couldn't open <%s>\n", FindConfig(alt_config_file)); - msyslog(LOG_INFO, "getconfig: Couldn't open <%s>", FindConfig(alt_config_file)); - return; - } -#else /* not SYS_WINNT */ - return; -#endif /* not SYS_WINNT */ + for (cfg_ptr = cfg_tree_history; + cfg_ptr != NULL; + cfg_ptr = cfg_ptr->link) + return_value |= dump_config_tree(cfg_ptr, df, comment); + + return return_value; +} + + +/* The config dumper */ +int +dump_config_tree( + struct config_tree *ptree, + FILE *df, + int comment + ) +{ + struct peer_node *peer = NULL; + struct unpeer_node *unpeers = NULL; + struct attr_val *atrv = NULL; + struct address_node *addr = NULL; + struct address_node *peer_addr; + struct address_node *fudge_addr; + struct filegen_node *fgen_node = NULL; + struct restrict_node *rest_node = NULL; + struct addr_opts_node *addr_opts = NULL; + struct setvar_node *setv_node = NULL; + nic_rule_node *rule_node; + + char **pstr = NULL; + char *s1; + char *s2; + int *intp = NULL; + void *fudge_ptr; + void *list_ptr = NULL; + void *options = NULL; + void *opt_ptr = NULL; + int *flags = NULL; + void *opts = NULL; + char timestamp[80]; + int enable; + + DPRINTF(1, ("dump_config_tree(%p)\n", ptree)); + + if (comment) { + if (!strftime(timestamp, sizeof(timestamp), + "%Y-%m-%d %H:%M:%S", + localtime(&ptree->timestamp))) + timestamp[0] = '\0'; + + fprintf(df, "# %s %s %s\n", + timestamp, + (CONF_SOURCE_NTPQ == ptree->source.attr) + ? "ntpq remote config from" + : "startup configuration file", + ptree->source.value.s); } - for (;;) { - if (tok == CONFIG_END) + /* For options I didn't find documentation I'll just output its name and the cor. value */ + list_ptr = queue_head(ptree->vars); + for(; list_ptr != NULL; + list_ptr = next_node(list_ptr)) { + + atrv = (struct attr_val *) list_ptr; + + switch (atrv->attr) { + + default: + fprintf(df, "\n# dump error:\n" + "# unknown vars token %s\n", + token_name(atrv->attr)); break; - if (fp[includelevel]) - tok = gettokens(fp[includelevel], line, tokens, &ntokens); -#ifdef HAVE_NETINFO - else - tok = gettokens_netinfo(config_netinfo, tokens, &ntokens); -#endif /* HAVE_NETINFO */ - if (tok == CONFIG_UNKNOWN) { - if (includelevel > 0) { - fclose(fp[includelevel--]); - continue; - } else { + /* doubles */ + case T_Broadcastdelay: + case T_Tick: + case T_WanderThreshold: + fprintf(df, "%s %g\n", + keyword(atrv->attr), + atrv->value.d); + break; + + /* ints */ + case T_Calldelay: +#ifdef OPENSSL + case T_Automax: +#endif + fprintf(df, "%s %d\n", + keyword(atrv->attr), + atrv->value.i); + break; + + /* strings */ + case T_Driftfile: + case T_Leapfile: + case T_Logfile: + case T_Pidfile: + case T_Saveconfigdir: + fprintf(df, "%s \"%s\"\n", + keyword(atrv->attr), + atrv->value.s); break; - } } + } - switch(tok) { - case CONFIG_PEER: - case CONFIG_SERVER: - case CONFIG_MANYCASTCLIENT: - case CONFIG_BROADCAST: - if (tok == CONFIG_PEER) - hmode = MODE_ACTIVE; - else if (tok == CONFIG_SERVER) - hmode = MODE_CLIENT; - else if (tok == CONFIG_MANYCASTCLIENT) - hmode = MODE_CLIENT; - else - hmode = MODE_BROADCAST; + list_ptr = queue_head(ptree->logconfig); + if (list_ptr != NULL) { + + fprintf(df, "logconfig"); - if (ntokens < 2) { - msyslog(LOG_ERR, - "No address for %s, line ignored", - tokens[0]); - break; - } + for(; list_ptr != NULL; + list_ptr = next_node(list_ptr)) { - istart = 1; - memset((char *)&peeraddr, 0, sizeof(peeraddr)); - peeraddr.ss_family = default_ai_family; - switch (matchkey(tokens[istart], addr_type, 0)) { - case CONF_ADDR_IPV4: - peeraddr.ss_family = AF_INET; - istart++; - break; - case CONF_ADDR_IPV6: - peeraddr.ss_family = AF_INET6; - istart++; - break; - } + atrv = list_ptr; + fprintf(df, " %c%s", atrv->attr, atrv->value.s); + } + fprintf(df, "\n"); + } - status = getnetnum(tokens[istart], &peeraddr, 0, t_UNK); - if (status == -1) - break; /* Found IPv6 address */ - if(status != 1) { - errflg = -1; - } else { - errflg = 0; + if (ptree->stats_dir) + fprintf(df, "statsdir \"%s\"\n", ptree->stats_dir); - if ( -#ifdef REFCLOCK - !ISREFCLOCKADR(&peeraddr) && -#endif - ISBADADR(&peeraddr)) { - msyslog(LOG_ERR, - "attempt to configure invalid address %s", - stoa(&peeraddr)); - break; - } - /* - * Shouldn't be able to specify multicast - * address for server/peer! - * and unicast address for manycastclient! - */ - if (peeraddr.ss_family == AF_INET) { - if (((tok == CONFIG_SERVER) || - (tok == CONFIG_PEER)) && -#ifdef REFCLOCK - !ISREFCLOCKADR(&peeraddr) && -#endif - IN_CLASSD(ntohl(((struct sockaddr_in*)&peeraddr)->sin_addr.s_addr))) { - msyslog(LOG_ERR, - "attempt to configure invalid address %s", - stoa(&peeraddr)); - break; - } - if ((tok == CONFIG_MANYCASTCLIENT) && - !IN_CLASSD(ntohl(((struct sockaddr_in*)&peeraddr)->sin_addr.s_addr))) { - msyslog(LOG_ERR, - "attempt to configure invalid address %s", - stoa(&peeraddr)); - break; - } - } - else if(peeraddr.ss_family == AF_INET6) { - if (((tok == CONFIG_SERVER) || - (tok == CONFIG_PEER)) && -#ifdef REFCLOCK - !ISREFCLOCKADR(&peeraddr) && -#endif - IN6_IS_ADDR_MULTICAST(&((struct sockaddr_in6*)&peeraddr)->sin6_addr)) { - msyslog(LOG_ERR, - "attempt to configure in valid address %s", - stoa(&peeraddr)); - break; - } - if ((tok == CONFIG_MANYCASTCLIENT) && - !IN6_IS_ADDR_MULTICAST(&((struct sockaddr_in6*)&peeraddr)->sin6_addr)) { - msyslog(LOG_ERR, - "attempt to configure in valid address %s", - stoa(&peeraddr)); - break; - } - } - } - if (peeraddr.ss_family == AF_INET6 && - isc_net_probeipv6() != ISC_R_SUCCESS) - break; - - peerversion = NTP_VERSION; - minpoll = NTP_MINDPOLL; - maxpoll = NTP_MAXDPOLL; - peerkey = 0; - peerkeystr = (u_char *)"*"; - peerflags = 0; - ttl = 0; - istart++; - for (i = istart; i < ntokens; i++) - switch (matchkey(tokens[i], mod_keywords, 1)) { - case CONF_MOD_VERSION: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "peer/server version requires an argument"); - errflg = 1; - break; - } - peerversion = atoi(tokens[++i]); - if ((u_char)peerversion > NTP_VERSION - || (u_char)peerversion < NTP_OLDVERSION) { - msyslog(LOG_ERR, - "inappropriate version number %s, line ignored", - tokens[i]); - errflg = 1; - } - break; - - case CONF_MOD_KEY: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "key: argument required"); - errflg = 1; - break; - } - peerkey = (int)atol(tokens[++i]); - peerflags |= FLAG_AUTHENABLE; - break; - - case CONF_MOD_MINPOLL: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "minpoll: argument required"); - errflg = 1; - break; - } - minpoll = atoi(tokens[++i]); - if (minpoll < NTP_MINPOLL) { - msyslog(LOG_INFO, - "minpoll: provided value (%d) is below minimum (%d)", - minpoll, NTP_MINPOLL); - minpoll = NTP_MINPOLL; - } - break; - - case CONF_MOD_MAXPOLL: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "maxpoll: argument required" - ); - errflg = 1; - break; - } - maxpoll = atoi(tokens[++i]); - if (maxpoll > NTP_MAXPOLL) { - msyslog(LOG_INFO, - "maxpoll: provided value (%d) is above maximum (%d)", - maxpoll, NTP_MAXPOLL); - maxpoll = NTP_MAXPOLL; - } - break; - - case CONF_MOD_PREFER: - peerflags |= FLAG_PREFER; - break; - - case CONF_MOD_PREEMPT: - peerflags |= FLAG_PREEMPT; - break; - - case CONF_MOD_NOSELECT: - peerflags |= FLAG_NOSELECT; - break; - - case CONF_MOD_TRUE: - peerflags |= FLAG_TRUE; - - case CONF_MOD_BURST: - peerflags |= FLAG_BURST; - break; - - case CONF_MOD_IBURST: - peerflags |= FLAG_IBURST; - break; - - case CONF_MOD_DYNAMIC: - msyslog(LOG_WARNING, - "Warning: the \"dynamic\" keyword has been obsoleted" - " and will be removed in the next release\n"); - break; + list_ptr = queue_head(ptree->stats_list); + if (list_ptr != NULL) { -#ifdef OPENSSL - case CONF_MOD_SKEY: - peerflags |= FLAG_SKEY | - FLAG_AUTHENABLE; - break; -#endif /* OPENSSL */ + fprintf(df, "statistics"); + for(; list_ptr != NULL; + list_ptr = next_node(list_ptr)) { - case CONF_MOD_TTL: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "ttl: argument required"); - errflg = 1; - break; - } - ttl = atoi(tokens[++i]); - if (ttl >= MAX_TTL) { - msyslog(LOG_ERR, - "ttl: invalid argument"); - errflg = 1; - } - break; + intp = list_ptr; + + fprintf(df, " %s", keyword(*intp)); + } - case CONF_MOD_MODE: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "mode: argument required"); - errflg = 1; - break; - } - ttl = atoi(tokens[++i]); - break; - - case CONFIG_UNKNOWN: - errflg = 1; - break; - } - if (minpoll > maxpoll) { - msyslog(LOG_ERR, - "config error: minpoll > maxpoll"); - errflg = 1; - } - if (errflg == 0) { - if (peer_config(&peeraddr, - ANY_INTERFACE_CHOOSE(&peeraddr), hmode, - peerversion, minpoll, maxpoll, peerflags, - ttl, peerkey, peerkeystr) == 0) { - msyslog(LOG_ERR, - "configuration of %s failed", - stoa(&peeraddr)); - } - } else if (errflg == -1) { - save_resolve(tokens[1], hmode, peerversion, - minpoll, maxpoll, peerflags, ttl, - peerkey, peerkeystr); - } - break; + fprintf(df, "\n"); + } - case CONFIG_DRIFTFILE: - if (ntokens >= 2) - stats_config(STATS_FREQ_FILE, tokens[1]); - else - stats_config(STATS_FREQ_FILE, (char *)0); - stats_write_period = stats_write_tolerance = 0; - if (ntokens >= 3) - stats_write_period = 60 * atol(tokens[2]); - if (stats_write_period <= 0) - stats_write_period = 3600; - if (ntokens >= 4) { - double ftemp; - sscanf(tokens[3], "%lf", &ftemp); - stats_write_tolerance = ftemp / 100; - } - break; - - case CONFIG_PIDFILE: - if (ntokens >= 2) - stats_config(STATS_PID_FILE, tokens[1]); - else - stats_config(STATS_PID_FILE, (char *)0); - break; + list_ptr = queue_head(ptree->filegen_opts); + for(; list_ptr != NULL; + list_ptr = next_node(list_ptr)) { + + fgen_node = list_ptr; + opt_ptr = queue_head(fgen_node->options); + + if (opt_ptr != NULL) + fprintf(df, "filegen %s", + keyword(fgen_node->filegen_token)); - case CONFIG_END: - for ( i = 0; i <= includelevel; i++ ) { - fclose(fp[i]); - } - break; + for(; opt_ptr != NULL; + opt_ptr = next_node(opt_ptr)) { - case CONFIG_INCLUDEFILE: - if (ntokens < 2) { - msyslog(LOG_ERR, "includefile needs one argument"); - break; - } - if (includelevel >= MAXINCLUDELEVEL) { - fprintf(stderr, "getconfig: Maximum include file level exceeded.\n"); - msyslog(LOG_INFO, "getconfig: Maximum include file level exceeded."); - break; - } - includefile = fopen(FindConfig(tokens[1]), "r"); - if (includefile == NULL) { - fprintf(stderr, "getconfig: Couldn't open <%s>\n", FindConfig(tokens[1])); - msyslog(LOG_INFO, "getconfig: Couldn't open <%s>", FindConfig(tokens[1])); - break; - } - fp[++includelevel] = includefile; - break; - - case CONFIG_LOGFILE: - if (ntokens >= 2) { - FILE *new_file; - - new_file = fopen(tokens[1], "a"); - if (new_file != NULL) { - NLOG(NLOG_SYSINFO) /* conditional if clause for conditional syslog */ - msyslog(LOG_NOTICE, "logging to file %s", tokens[1]); - if (syslog_file != NULL && - fileno(syslog_file) != fileno(new_file)) - (void)fclose(syslog_file); - - syslog_file = new_file; - syslogit = 0; - } - else - msyslog(LOG_ERR, - "Cannot open log file %s", - tokens[1]); - } - else - msyslog(LOG_ERR, "logfile needs one argument"); - break; - - case CONFIG_LOGCONFIG: - for (i = 1; i < ntokens; i++) - { - int add = 1; - int equals = 0; - char * s = &tokens[i][0]; - - switch (*s) { - case '+': - case '-': - case '=': - add = *s == '+'; - equals = *s == '='; - s++; - break; + atrv = opt_ptr; - default: - break; - } - if (equals) { - ntp_syslogmask = get_logmask(s); - } else { - if (add) { - ntp_syslogmask |= get_logmask(s); - } else { - ntp_syslogmask &= ~get_logmask(s); - } - } -#ifdef DEBUG - if (debug) - printf("ntp_syslogmask = 0x%08lx (%s)\n", ntp_syslogmask, tokens[i]); -#endif - } - break; + switch (atrv->attr) { - case CONFIG_BROADCASTCLIENT: - if (ntokens == 1) { - proto_config(PROTO_BROADCLIENT, 1, 0., NULL); - } else { - proto_config(PROTO_BROADCLIENT, 2, 0., NULL); - } - break; + default: + fprintf(df, "\n# dump error:\n" + "# unknown filegen option token %s\n" + "filegen %s", + token_name(atrv->attr), + keyword(fgen_node->filegen_token)); + break; - case CONFIG_MULTICASTCLIENT: - case CONFIG_MANYCASTSERVER: - if (ntokens > 1) { - istart = 1; - memset((char *)&peeraddr, 0, sizeof(peeraddr)); - peeraddr.ss_family = default_ai_family; - switch (matchkey(tokens[istart], - addr_type, 0)) { - case CONF_ADDR_IPV4: - peeraddr.ss_family = AF_INET; - istart++; - break; - case CONF_ADDR_IPV6: - peeraddr.ss_family = AF_INET6; - istart++; - break; - } - /* - * Abuse maskaddr to store the prefered ip - * version. - */ - memset((char *)&maskaddr, 0, sizeof(maskaddr)); - maskaddr.ss_family = peeraddr.ss_family; - - for (i = istart; i < ntokens; i++) { - memset((char *)&peeraddr, 0, - sizeof(peeraddr)); - peeraddr.ss_family = maskaddr.ss_family; - if (getnetnum(tokens[i], &peeraddr, 1, - t_UNK) == 1) - proto_config(PROTO_MULTICAST_ADD, - 0, 0., &peeraddr); - } - } else - proto_config(PROTO_MULTICAST_ADD, - 0, 0., NULL); - if (tok == CONFIG_MULTICASTCLIENT) - proto_config(PROTO_MULTICAST_ADD, 1, 0., NULL); - else if (tok == CONFIG_MANYCASTSERVER) - sys_manycastserver = 1; - break; + case T_File: + fprintf(df, " file %s", + atrv->value.s); + break; - case CONFIG_KEYS: - if (ntokens >= 2) { - getauthkeys(tokens[1]); - } - break; + case T_Type: + fprintf(df, " type %s", + keyword(atrv->value.i)); + break; - case CONFIG_KEYSDIR: - if (ntokens < 2) { - msyslog(LOG_ERR, - "Keys directory name required"); - break; + case T_Flag: + fprintf(df, " %s", + keyword(atrv->value.i)); + break; } - keysdir = (char *)emalloc(strlen(tokens[1]) + 1); - strcpy(keysdir, tokens[1]); - break; - - case CONFIG_TINKER: - for (i = 1; i < ntokens; i++) { - int temp; - double ftemp; - temp = matchkey(tokens[i++], tinker_keywords, 1); - if (i > ntokens - 1) { - msyslog(LOG_ERR, - "tinker: missing argument"); - errflg++; - break; - } - sscanf(tokens[i], "%lf", &ftemp); - switch(temp) { + } - case CONF_CLOCK_MAX: - loop_config(LOOP_MAX, ftemp); - break; + fprintf(df, "\n"); + } - case CONF_CLOCK_PANIC: - loop_config(LOOP_PANIC, ftemp); - break; + list_ptr = queue_head(ptree->auth.crypto_cmd_list); + if (list_ptr != NULL) { + fprintf(df, "crypto"); + + for (; list_ptr != NULL; + list_ptr = next_node(list_ptr)) { + + atrv = list_ptr; + fprintf(df, " %s %s", keyword(atrv->attr), + atrv->value.s); + } + fprintf(df, "\n"); + } - case CONF_CLOCK_PHI: - loop_config(LOOP_PHI, ftemp); - break; + if (ptree->auth.revoke != 0) + fprintf(df, "revoke %d\n", ptree->auth.revoke); - case CONF_CLOCK_MINSTEP: - loop_config(LOOP_MINSTEP, ftemp); - break; + if (NULL != ptree->auth.keysdir) + fprintf(df, "keysdir \"%s\"\n", ptree->auth.keysdir); - case CONF_CLOCK_ALLAN: - loop_config(LOOP_ALLAN, ftemp); - break; + if (NULL != ptree->auth.keys) + fprintf(df, "keys \"%s\"\n", ptree->auth.keys); - case CONF_CLOCK_HUFFPUFF: - loop_config(LOOP_HUFFPUFF, ftemp); - break; + atrv = queue_head(ptree->auth.trusted_key_list); + if (atrv != NULL) { + fprintf(df, "trustedkey"); + do { + if ('i' == atrv->attr) + fprintf(df, " %d", atrv->value.i); + else if ('-' == atrv->attr) + fprintf(df, " (%u ... %u)", + atrv->value.u >> 16, + atrv->value.u & 0xffff); + else + fprintf(df, "\n# dump error:\n" + "# unknown trustedkey attr %d\n" + "trustedkey", atrv->attr); + } while (NULL != (atrv = next_node(atrv))); + fprintf(df, "\n"); + } - case CONF_CLOCK_FREQ: - loop_config(LOOP_FREQ, ftemp); - break; - } - } - break; + if (ptree->auth.control_key) + fprintf(df, "controlkey %d\n", ptree->auth.control_key); - case CONFIG_TOS: - for (i = 1; i < ntokens; i++) { - int temp; - double ftemp; + if (ptree->auth.request_key) + fprintf(df, "requestkey %d\n", ptree->auth.request_key); - temp = matchkey(tokens[i++], tos_keywords, 1); - if (i > ntokens - 1) { - msyslog(LOG_ERR, - "tos: missing argument"); - errflg++; - break; - } - sscanf(tokens[i], "%lf", &ftemp); - switch(temp) { + /* dump enable list, then disable list */ + for (enable = 1; enable >= 0; enable--) { - case CONF_TOS_MINCLOCK: - proto_config(PROTO_MINCLOCK, 0, ftemp, NULL); - break; + list_ptr = (enable) + ? queue_head(ptree->enable_opts) + : queue_head(ptree->disable_opts); - case CONF_TOS_MAXCLOCK: - proto_config(PROTO_MAXCLOCK, 0, ftemp, NULL); - break; + if (list_ptr != NULL) { + fprintf(df, (enable) + ? "enable" + : "disable"); - case CONF_TOS_MINSANE: - proto_config(PROTO_MINSANE, 0, ftemp, NULL); - break; + for(; list_ptr != NULL; + list_ptr = next_node(list_ptr)) { - case CONF_TOS_FLOOR: - proto_config(PROTO_FLOOR, 0, ftemp, NULL); - break; + atrv = (struct attr_val *) list_ptr; - case CONF_TOS_CEILING: - proto_config(PROTO_CEILING, 0, ftemp, NULL); - break; + fprintf(df, " %s", + keyword(atrv->value.i)); + } + fprintf(df, "\n"); + } + } - case CONF_TOS_COHORT: - proto_config(PROTO_COHORT, 0, ftemp, NULL); - break; + list_ptr = queue_head(ptree->orphan_cmds); + if (list_ptr != NULL) + fprintf(df, "tos"); - case CONF_TOS_MINDISP: - proto_config(PROTO_MINDISP, 0, ftemp, NULL); - break; + for(; list_ptr != NULL; + list_ptr = next_node(list_ptr)) { - case CONF_TOS_MAXDIST: - proto_config(PROTO_MAXDIST, 0, ftemp, NULL); - break; + atrv = list_ptr; - case CONF_TOS_MAXHOP: - proto_config(PROTO_MAXHOP, 0, ftemp, NULL); - break; + switch (atrv->attr) { - case CONF_TOS_ORPHAN: - proto_config(PROTO_ORPHAN, 0, ftemp, NULL); - break; + default: + fprintf(df, "\n# dump error:\n" + "# unknown tos token %s\n" + "tos", token_name(atrv->attr)); + break; - case CONF_TOS_BEACON: - proto_config(PROTO_BEACON, 0, ftemp, NULL); - break; - } - } + /* ints */ + case T_Ceiling: + case T_Floor: + case T_Cohort: + case T_Orphan: + case T_Minclock: + case T_Maxclock: + case T_Minsane: + case T_Beacon: + fprintf(df, " %s %d", keyword(atrv->attr), + (int)atrv->value.d); break; - case CONFIG_TTL: - for (i = 1; i < ntokens && i < MAX_TTL; i++) { - sys_ttl[i - 1] = (u_char) atoi(tokens[i]); - sys_ttlmax = i - 1; - } + /* doubles */ + case T_Mindist: + case T_Maxdist: + fprintf(df, " %s %g", keyword(atrv->attr), + atrv->value.d); break; + } + } + if (queue_head(ptree->orphan_cmds) != NULL) + fprintf(df, "\n"); - case CONFIG_DISCARD: - for (i = 1; i < ntokens; i++) { - int temp; + list_ptr = queue_head(ptree->tinker); + if (list_ptr != NULL) { - temp = matchkey(tokens[i++], - discard_keywords, 1); - if (i > ntokens - 1) { - msyslog(LOG_ERR, - "discard: missing argument"); - errflg++; - break; - } - switch(temp) { - case CONF_DISCARD_AVERAGE: - res_avg_interval = atoi(tokens[i]); - break; + fprintf(df, "tinker"); - case CONF_DISCARD_MINIMUM: - res_min_interval = atoi(tokens[i]); - break; + for(; list_ptr != NULL; + list_ptr = next_node(list_ptr)) { - case CONF_DISCARD_MONITOR: - mon_age = atoi(tokens[i]); - break; + atrv = list_ptr; + fprintf(df, " %s %g", keyword(atrv->attr), + atrv->value.d); + } - default: - msyslog(LOG_ERR, - "discard: unknown keyword"); - break; - } - } + fprintf(df, "\n"); + } + + if (ptree->broadcastclient) + fprintf(df, "broadcastclient\n"); + + list_ptr = queue_head(ptree->peers); + for (; list_ptr != NULL; + list_ptr = next_node(list_ptr)) { + + peer = list_ptr; + addr = peer->addr; + fprintf(df, "%s", keyword(peer->host_mode)); + + switch (addr->type) { + + default: + fprintf(df, "# dump error:\n" + "# unknown peer family %d for:\n" + "peer", addr->type); break; -#ifdef OPENSSL - case CONFIG_REVOKE: - if (ntokens >= 2) - sys_revoke = (u_char) max(atoi(tokens[1]), KEY_REVOKE); + case AF_UNSPEC: break; - case CONFIG_AUTOMAX: - if (ntokens >= 2) - sys_automax = 1 << max(atoi(tokens[1]), 10); + case AF_INET: + fprintf(df, " -4"); break; - case CONFIG_CRYPTO: - if (ntokens == 1) { - crypto_config(CRYPTO_CONF_NONE, NULL); - break; - } - for (i = 1; i < ntokens; i++) { - int temp; + case AF_INET6: + fprintf(df, " -6"); + break; + } + fprintf(df, " %s", addr->address); + + if (peer->minpoll != 0) + fprintf(df, " minpoll %d", peer->minpoll); - temp = matchkey(tokens[i++], - crypto_keywords, 1); - if (i > ntokens - 1) { - msyslog(LOG_ERR, - "crypto: missing argument"); - errflg++; - break; - } - switch(temp) { + if (peer->maxpoll != 0) + fprintf(df, " maxpoll %d", peer->maxpoll); - case CONF_CRYPTO_CERT: - crypto_config(CRYPTO_CONF_CERT, - tokens[i]); - break; + if (peer->ttl != 0) { + if (strlen(addr->address) > 8 + && !memcmp(addr->address, "127.127.", 8)) + fprintf(df, " mode %d", peer->ttl); + else + fprintf(df, " ttl %d", peer->ttl); + } - case CONF_CRYPTO_RSA: - crypto_config(CRYPTO_CONF_PRIV, - tokens[i]); - break; + if (peer->peerversion != NTP_VERSION) + fprintf(df, " version %d", peer->peerversion); - case CONF_CRYPTO_IDENT: - crypto_config(CRYPTO_CONF_IDENT, - tokens[i]); - break; + if (peer->peerkey != 0) + fprintf(df, " key %d", peer->peerkey); - case CONF_CRYPTO_IFFPAR: - crypto_config(CRYPTO_CONF_IFFPAR, - tokens[i]); - break; + if (peer->bias != 0.) + fprintf(df, " bias %g", peer->bias); - case CONF_CRYPTO_GQPAR: - crypto_config(CRYPTO_CONF_GQPAR, - tokens[i]); - break; + for (atrv = queue_head(peer->peerflags); + atrv != NULL; + atrv = next_node(atrv)) { - case CONF_CRYPTO_MVPAR: - crypto_config(CRYPTO_CONF_MVPAR, - tokens[i]); - break; + NTP_INSIST(T_Flag == atrv->attr); + NTP_INSIST(T_Integer == atrv->type); - case CONF_CRYPTO_LEAP: - crypto_config(CRYPTO_CONF_LEAP, - tokens[i]); - break; + fprintf(df, " %s", keyword(atrv->value.i)); + } - case CONF_CRYPTO_PW: - crypto_config(CRYPTO_CONF_PW, - tokens[i]); - break; + fprintf(df, "\n"); - case CONF_CRYPTO_RAND: - crypto_config(CRYPTO_CONF_RAND, - tokens[i]); - break; + fudge_ptr = queue_head(ptree->fudge); + for(; fudge_ptr != NULL; + fudge_ptr = next_node(fudge_ptr)) { - case CONF_CRYPTO_SIGN: - crypto_config(CRYPTO_CONF_SIGN, - tokens[i]); - break; - default: - msyslog(LOG_ERR, - "crypto: unknown keyword"); - break; - } - } - break; -#endif /* OPENSSL */ + addr_opts = (struct addr_opts_node *) fudge_ptr; + peer_addr = peer->addr; + fudge_addr = addr_opts->addr; - case CONFIG_RESTRICT: - if (ntokens < 2) { - msyslog(LOG_ERR, "restrict requires an address"); - break; - } - istart = 1; - memset((char *)&peeraddr, 0, sizeof(peeraddr)); - peeraddr.ss_family = default_ai_family; - switch (matchkey(tokens[istart], addr_type, 0)) { - case CONF_ADDR_IPV4: - peeraddr.ss_family = AF_INET; - istart++; - break; - case CONF_ADDR_IPV6: - peeraddr.ss_family = AF_INET6; - istart++; - break; - } + s1 = peer_addr->address; + s2 = fudge_addr->address; - /* - * Assume default means an IPv4 address, except - * if forced by a -4 or -6. - */ - if (STREQ(tokens[istart], "default")) { - if (peeraddr.ss_family == 0) - peeraddr.ss_family = AF_INET; - } else if (getnetnum(tokens[istart], &peeraddr, 1, - t_UNK) != 1) - break; + if (!strcmp(s1, s2)) { - /* - * Use peerversion as flags, peerkey as mflags. Ick. - */ - peerversion = 0; - peerkey = 0; - errflg = 0; - SET_HOSTMASK(&maskaddr, peeraddr.ss_family); - istart++; - for (i = istart; i < ntokens; i++) { - switch (matchkey(tokens[i], res_keywords, 1)) { - case CONF_RES_MASK: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "mask keyword needs argument"); - errflg++; + fprintf(df, "fudge %s", addr_opts->addr->address); + + opts = queue_head(addr_opts->options); + + for(; opts != NULL; opts = next_node(opts)) { + atrv = (struct attr_val *) opts; + + switch (atrv->attr) { + + default: + fprintf(df, "\n# dump error:\n" + "# unknown fudge option %s\n" + "fudge %s", + token_name(atrv->attr), + addr_opts->addr->address); + break; + + /* doubles */ + case T_Time1: + case T_Time2: + fprintf(df, " %s %g", + keyword(atrv->attr), + atrv->value.d); + break; + + /* ints */ + case T_Stratum: + case T_Flag1: + case T_Flag2: + case T_Flag3: + case T_Flag4: + fprintf(df, " %s %d", + keyword(atrv->attr), + atrv->value.i); + break; + + /* strings */ + case T_Refid: + fprintf(df, " %s %s", + keyword(atrv->attr), + atrv->value.s); break; } - i++; - if (getnetnum(tokens[i], &maskaddr, 1, - t_MSK) != 1) - errflg++; - break; + } + fprintf(df, "\n"); + } + } + } - case CONF_RES_IGNORE: - peerversion |= RES_IGNORE; - break; + list_ptr = queue_head(ptree->manycastserver); + if (list_ptr != NULL) { + addr = list_ptr; + fprintf(df, "manycastserver %s", addr->address); + for (addr = next_node(addr); + addr != NULL; + addr = next_node(addr)) + fprintf(df, " %s", addr->address); + fprintf(df, "\n"); + } - case CONF_RES_NOSERVE: - peerversion |= RES_DONTSERVE; - break; + list_ptr = queue_head(ptree->multicastclient); + if (list_ptr != NULL) { + addr = list_ptr; + fprintf(df, "multicastclient %s", addr->address); + for (addr = next_node(addr); + addr != NULL; + addr = next_node(addr)) + fprintf(df, " %s", addr->address); + fprintf(df, "\n"); + } - case CONF_RES_NOTRUST: - peerversion |= RES_DONTTRUST; - break; + list_ptr = queue_head(ptree->unpeers); + for (; list_ptr != NULL; + list_ptr = next_node(list_ptr)) { + + unpeers = (struct unpeer_node *) list_ptr; + + fprintf(df, "unpeer %s\n", (unpeers->addr)->address); + } - case CONF_RES_NOQUERY: - peerversion |= RES_NOQUERY; - break; + list_ptr = queue_head(ptree->discard_opts); + if (list_ptr != NULL) { - case CONF_RES_NOMODIFY: - peerversion |= RES_NOMODIFY; - break; + fprintf(df, "discard"); - case CONF_RES_NOPEER: - peerversion |= RES_NOPEER; - break; + for(; list_ptr != NULL; + list_ptr = next_node(list_ptr)) { - case CONF_RES_NOTRAP: - peerversion |= RES_NOTRAP; - break; + atrv = list_ptr; + fprintf(df, " %s %d", keyword(atrv->attr), + atrv->value.i); + } + fprintf(df, "\n"); + } - case CONF_RES_LPTRAP: - peerversion |= RES_LPTRAP; - break; + list_ptr = queue_head(ptree->restrict_opts); + for (; list_ptr != NULL; + list_ptr = next_node(list_ptr)) { + + rest_node = list_ptr; + if (NULL == rest_node->addr) + s1 = "default"; + else + s1 = rest_node->addr->address; - case CONF_RES_NTPPORT: - peerkey |= RESM_NTPONLY; - break; + fprintf(df, "restrict %s", s1); - case CONF_RES_VERSION: - peerversion |= RES_VERSION; - break; + if (rest_node->mask != NULL) + fprintf(df, " mask %s", + rest_node->mask->address); - case CONF_RES_DEMOBILIZE: - peerversion |= RES_DEMOBILIZE; - break; + flags = queue_head(rest_node->flags); + for (; flags != NULL; flags = next_node(flags)) + fprintf(df, " %s", keyword(*flags)); - case CONF_RES_LIMITED: - peerversion |= RES_LIMITED; - break; + fprintf(df, "\n"); + } - case CONFIG_UNKNOWN: - errflg++; - break; - } - } - if (SOCKNUL(&peeraddr)) - ANYSOCK(&maskaddr); - if (!errflg) - hack_restrict(RESTRICT_FLAGS, &peeraddr, &maskaddr, - (int)peerkey, peerversion); - break; + list_ptr = queue_head(ptree->nic_rules); + for (; list_ptr != NULL; + list_ptr = next_node(list_ptr)) { + + rule_node = list_ptr; + fprintf(df, "interface %s %s\n", + keyword(rule_node->action), + (rule_node->match_class) + ? keyword(rule_node->match_class) + : rule_node->if_name); + } - case CONFIG_BDELAY: - if (ntokens >= 2) { - double tmp; + list_ptr = queue_head(ptree->phone); + if (list_ptr != NULL) { - if (sscanf(tokens[1], "%lf", &tmp) != 1) { - msyslog(LOG_ERR, - "broadcastdelay value %s undecodable", - tokens[1]); - } else { - proto_config(PROTO_BROADDELAY, 0, tmp, NULL); - } - } - break; + fprintf(df, "phone"); - case CONFIG_CDELAY: - if (ntokens >= 2) { - u_long ui; + for(; list_ptr != NULL; + list_ptr = next_node(list_ptr)) { - if (sscanf(tokens[1], "%ld", &ui) != 1) - msyslog(LOG_ERR, - "illegal value - line ignored"); - else - proto_config(PROTO_CALLDELAY, ui, 0, NULL); - } - break; + pstr = list_ptr; + fprintf(df, " %s", *pstr); + } - case CONFIG_TRUSTEDKEY: - for (i = 1; i < ntokens; i++) { - keyid_t tkey; + fprintf(df, "\n"); + } - tkey = atol(tokens[i]); - if (tkey == 0) { - msyslog(LOG_ERR, - "trusted key %s unlikely", - tokens[i]); - } else { - authtrust(tkey, 1); - } - } - break; + list_ptr = queue_head(ptree->qos); + if (list_ptr != NULL) { + + fprintf(df, "qos"); - case CONFIG_REQUESTKEY: - if (ntokens >= 2) { - if (!atouint(tokens[1], &ul)) { - msyslog(LOG_ERR, - "%s is undecodable as request key", - tokens[1]); - } else if (ul == 0) { - msyslog(LOG_ERR, - "%s makes a poor request keyid", - tokens[1]); - } else { -#ifdef DEBUG - if (debug > 3) - printf( - "set info_auth_key to %08lx\n", ul); -#endif - info_auth_keyid = (keyid_t)ul; - } - } - break; + for(; list_ptr != NULL; + list_ptr = next_node(list_ptr)) { - case CONFIG_CONTROLKEY: - if (ntokens >= 2) { - keyid_t ckey; + atrv = list_ptr; + fprintf(df, " %s", atrv->value.s); + } - ckey = atol(tokens[1]); - if (ckey == 0) { - msyslog(LOG_ERR, - "%s makes a poor control keyid", - tokens[1]); - } else { - ctl_auth_keyid = ckey; - } - } - break; + fprintf(df, "\n"); + } - case CONFIG_TRAP: - if (ntokens < 2) { - msyslog(LOG_ERR, - "no address for trap command, line ignored"); - break; - } - istart = 1; - memset((char *)&peeraddr, 0, sizeof(peeraddr)); - peeraddr.ss_family = default_ai_family; - switch (matchkey(tokens[istart], addr_type, 0)) { - case CONF_ADDR_IPV4: - peeraddr.ss_family = AF_INET; - istart++; - break; - case CONF_ADDR_IPV6: - peeraddr.ss_family = AF_INET6; - istart++; - break; - } + list_ptr = queue_head(ptree->setvar); + for(; list_ptr != NULL; + list_ptr = next_node(list_ptr)) { + + setv_node = list_ptr; + s1 = quote_if_needed(setv_node->var); + s2 = quote_if_needed(setv_node->val); + fprintf(df, "setvar %s = %s", s1, s2); + free(s1); + free(s2); - if (getnetnum(tokens[istart], &peeraddr, 1, t_UNK) != 1) - break; + if (setv_node->isdefault) + fprintf(df, " default"); - /* - * Use peerversion for port number. Barf. - */ - errflg = 0; - peerversion = 0; - localaddr = 0; - istart++; - for (i = istart; i < ntokens-1; i++) - switch (matchkey(tokens[i], trap_keywords, 1)) { - case CONF_TRAP_PORT: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "trap port requires an argument"); - errflg = 1; - break; - } - peerversion = atoi(tokens[++i]); - if (peerversion <= 0 - || peerversion > 32767) { - msyslog(LOG_ERR, - "invalid port number %s, trap ignored", - tokens[i]); - errflg = 1; - } - break; - - case CONF_TRAP_INTERFACE: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "trap interface requires an argument"); - errflg = 1; - break; - } - - memset((char *)&maskaddr, 0, - sizeof(maskaddr)); - maskaddr.ss_family = peeraddr.ss_family; - if (getnetnum(tokens[++i], - &maskaddr, 1, t_UNK) != 1) { - errflg = 1; - break; - } - - localaddr = findinterface(&maskaddr); - if (localaddr == NULL) { - msyslog(LOG_ERR, - "can't find interface with address %s", - stoa(&maskaddr)); - errflg = 1; - } - break; - - case CONFIG_UNKNOWN: - errflg++; - break; - } - - if (!errflg) { - if (peerversion != 0) - ((struct sockaddr_in6*)&peeraddr)->sin6_port = htons( (u_short) peerversion); - else - ((struct sockaddr_in6*)&peeraddr)->sin6_port = htons(TRAPPORT); - if (localaddr == NULL) - localaddr = ANY_INTERFACE_CHOOSE(&peeraddr); - if (!ctlsettrap(&peeraddr, localaddr, 0, - NTP_VERSION)) - msyslog(LOG_ERR, - "can't set trap for %s, no resources", - stoa(&peeraddr)); - } - break; + fprintf(df, "\n"); + } - case CONFIG_FUDGE: - if (ntokens < 2) { - msyslog(LOG_ERR, - "no address for fudge command, line ignored"); - break; - } - memset((char *)&peeraddr, 0, sizeof(peeraddr)); - if (getnetnum(tokens[1], &peeraddr, 1, t_REF) != 1) - break; - if (!ISREFCLOCKADR(&peeraddr)) { - msyslog(LOG_ERR, - "%s is inappropriate address for the fudge command, line ignored", - stoa(&peeraddr)); - break; - } + list_ptr = queue_head(ptree->ttl); + if (list_ptr != NULL) { - memset((void *)&clock_stat, 0, sizeof clock_stat); - fudgeflag = 0; - errflg = 0; - for (i = 2; i < ntokens-1; i++) { - switch (c = matchkey(tokens[i], - fudge_keywords, 1)) { - case CONF_FDG_TIME1: - if (sscanf(tokens[++i], "%lf", - &clock_stat.fudgetime1) != 1) { - msyslog(LOG_ERR, - "fudge %s time1 value in error", - stoa(&peeraddr)); - errflg = i; - break; - } - clock_stat.haveflags |= CLK_HAVETIME1; - break; + fprintf(df, "ttl"); - case CONF_FDG_TIME2: - if (sscanf(tokens[++i], "%lf", - &clock_stat.fudgetime2) != 1) { - msyslog(LOG_ERR, - "fudge %s time2 value in error", - stoa(&peeraddr)); - errflg = i; - break; - } - clock_stat.haveflags |= CLK_HAVETIME2; - break; + for(; list_ptr != NULL; + list_ptr = next_node(list_ptr)) { + intp = list_ptr; + fprintf(df, " %d", *intp); + } + + fprintf(df, "\n"); + } + + list_ptr = queue_head(ptree->trap); + for(; list_ptr != NULL; + list_ptr = next_node(list_ptr)) { - case CONF_FDG_STRATUM: - if (!atoint(tokens[++i], &stratum)) - { - msyslog(LOG_ERR, - "fudge %s stratum value in error", - stoa(&peeraddr)); - errflg = i; - break; - } - clock_stat.fudgeval1 = stratum; - clock_stat.haveflags |= CLK_HAVEVAL1; - break; + addr_opts = list_ptr; + addr = addr_opts->addr; - case CONF_FDG_REFID: - i++; - memcpy(&clock_stat.fudgeval2, - tokens[i], min(strlen(tokens[i]), - 4)); - clock_stat.haveflags |= CLK_HAVEVAL2; - break; + fprintf(df, "trap %s", addr->address); - case CONF_FDG_FLAG1: - case CONF_FDG_FLAG2: - case CONF_FDG_FLAG3: - case CONF_FDG_FLAG4: - if (!atouint(tokens[++i], &fudgeflag) - || fudgeflag > 1) { - msyslog(LOG_ERR, - "fudge %s flag value in error", - stoa(&peeraddr)); - errflg = i; - break; - } - switch(c) { - case CONF_FDG_FLAG1: - c = CLK_FLAG1; - clock_stat.haveflags|=CLK_HAVEFLAG1; - break; - case CONF_FDG_FLAG2: - c = CLK_FLAG2; - clock_stat.haveflags|=CLK_HAVEFLAG2; - break; - case CONF_FDG_FLAG3: - c = CLK_FLAG3; - clock_stat.haveflags|=CLK_HAVEFLAG3; - break; - case CONF_FDG_FLAG4: - c = CLK_FLAG4; - clock_stat.haveflags|=CLK_HAVEFLAG4; - break; - } - if (fudgeflag == 0) - clock_stat.flags &= ~c; - else - clock_stat.flags |= c; + options = queue_head(addr_opts->options); + + for(; options != NULL; + options = next_node(options)) { + + atrv = options; + + switch (atrv->attr) { + + default: + fprintf(df, "\n# dump error:\n" + "# unknown trap token %d\n" + "trap %s", atrv->attr, + addr->address); + break; + + case T_Port: + fprintf(df, " port %d", atrv->value.i); + break; + + case T_Interface: + addr = (struct address_node *) atrv->value.p; + fprintf(df, " interface %s", addr->address); + break; + } + } + + fprintf(df, "\n"); + } + + return 0; +} +#endif /* SAVECONFIG */ + + +/* FUNCTIONS FOR CREATING NODES ON THE SYNTAX TREE + * ----------------------------------------------- + */ + +queue * +enqueue_in_new_queue( + void *my_node + ) +{ + queue *my_queue = create_queue(); + + enqueue(my_queue, my_node); + return my_queue; +} + +struct attr_val * +create_attr_dval( + int attr, + double value + ) +{ + struct attr_val *my_val; + + my_val = get_node(sizeof *my_val); + my_val->attr = attr; + my_val->value.d = value; + my_val->type = T_Double; + return my_val; +} + +struct attr_val * +create_attr_ival( + int attr, + int value + ) +{ + struct attr_val *my_val; + + my_val = get_node(sizeof *my_val); + my_val->attr = attr; + my_val->value.i = value; + my_val->type = T_Integer; + return my_val; +} + +struct attr_val * +create_attr_shorts( + int attr, + ntp_u_int16_t val1, + ntp_u_int16_t val2 + ) +{ + struct attr_val *my_val; + + my_val = get_node(sizeof *my_val); + my_val->attr = attr; + my_val->value.u = (val1 << 16) | val2; + my_val->type = T_Integer; + return my_val; +} + +struct attr_val * +create_attr_sval( + int attr, + char *s + ) +{ + struct attr_val *my_val; + + my_val = get_node(sizeof *my_val); + my_val->attr = attr; + if (NULL == s) /* free() hates NULL */ + s = estrdup(""); + my_val->value.s = s; + my_val->type = T_String; + return my_val; +} + +struct attr_val * +create_attr_pval( + int attr, + void *p + ) +{ + struct attr_val *my_val; + + my_val = get_node(sizeof *my_val); + my_val->attr = attr; + my_val->value.p = p; + my_val->type = T_Void; + return my_val; +} + +int * +create_ival( + int val + ) +{ + int *p = get_node(sizeof *p); + + *p = val; + return p; +} + +double * +create_dval( + double val + ) +{ + double *p = get_node(sizeof *p); + + *p = val; + return p; +} + +void ** +create_pval( + void *val + ) +{ + void **p = get_node(sizeof *p); + + *p = val; + return p; +} + +struct address_node * +create_address_node( + char *addr, + int type + ) +{ + struct address_node *my_node; + + NTP_REQUIRE(NULL != addr); + + my_node = get_node(sizeof *my_node); + + my_node->address = addr; + my_node->type = type; + + return my_node; +} + + +void +destroy_address_node( + struct address_node *my_node + ) +{ + NTP_REQUIRE(NULL != my_node); + NTP_REQUIRE(NULL != my_node->address); + + free(my_node->address); + free_node(my_node); +} + + +struct peer_node * +create_peer_node( + int hmode, + struct address_node *addr, + queue *options + ) +{ + struct peer_node *my_node; + struct attr_val *option; + int freenode; + int errflag = 0; + + my_node = get_node(sizeof(*my_node)); + + /* Initialize node values to default */ + my_node->minpoll = 0; + my_node->maxpoll = 0; + my_node->ttl = 0; + my_node->peerversion = NTP_VERSION; + my_node->peerkey = 0; + my_node->bias = 0; + my_node->peerflags = create_queue(); + + /* Now set the node to the read values */ + my_node->host_mode = hmode; + my_node->addr = addr; + + /* + * the options list mixes items that will be saved in the + * peer_node as explicit members, such as minpoll, and + * those that are moved from the options queue intact + * to the peer_node's peerflags queue. The options + * queue is consumed and destroyed here. + */ + + while (options && NULL != (option = dequeue(options))) { + + freenode = 1; + /* Check the kind of option being set */ + switch (option->attr) { + + case T_Flag: + enqueue(my_node->peerflags, option); + freenode = 0; + break; + + case T_Minpoll: + if (option->value.i < NTP_MINPOLL) { + msyslog(LOG_INFO, + "minpoll: provided value (%d) is below minimum (%d)", + option->value.i, NTP_MINPOLL); + my_node->minpoll = NTP_MINPOLL; + } + else + my_node->minpoll = option->value.i; + break; + + case T_Maxpoll: + if (option->value.i > NTP_MAXPOLL) { + msyslog(LOG_INFO, + "maxpoll: provided value (%d) is above maximum (%d)", + option->value.i, NTP_MAXPOLL); + my_node->maxpoll = NTP_MAXPOLL; + } + else + my_node->maxpoll = option->value.i; + break; + + case T_Ttl: + if (my_node->ttl >= MAX_TTL) { + msyslog(LOG_ERR, "ttl: invalid argument"); + errflag = 1; + } + else + my_node->ttl = option->value.i; + break; + + case T_Mode: + my_node->ttl = option->value.i; + break; + + case T_Key: + my_node->peerkey = option->value.i; + break; + + case T_Version: + my_node->peerversion = option->value.i; + break; + + case T_Bias: + my_node->bias = option->value.d; + break; + + default: + msyslog(LOG_ERR, + "Unknown peer/server option token %s", + token_name(option->attr)); + errflag = 1; + } + if (freenode) + free_node(option); + } + DESTROY_QUEUE(options); + + /* Check if errors were reported. If yes, ignore the node */ + if (errflag) { + free_node(my_node); + my_node = NULL; + } + return my_node; +} + + +struct unpeer_node * +create_unpeer_node( + struct address_node *addr + ) +{ + struct unpeer_node * my_node; + char * pch; + + my_node = get_node(sizeof(*my_node)); + + /* + * From the parser's perspective an association ID fits into + * its generic T_String definition of a name/address "address". + * We treat all valid 16-bit numbers as association IDs. + */ + pch = addr->address; + while (*pch && isdigit(*pch)) + pch++; + + if (!*pch + && 1 == sscanf(addr->address, "%u", &my_node->assocID) + && my_node->assocID <= USHRT_MAX) { + + destroy_address_node(addr); + my_node->addr = NULL; + } else { + my_node->assocID = 0; + my_node->addr = addr; + } + + return my_node; +} + +struct filegen_node * +create_filegen_node( + int filegen_token, + queue * options + ) +{ + struct filegen_node *my_node; + + my_node = get_node(sizeof *my_node); + my_node->filegen_token = filegen_token; + my_node->options = options; + + return my_node; +} + + +struct restrict_node * +create_restrict_node( + struct address_node *addr, + struct address_node *mask, + queue *flags, + int line_no + ) +{ + struct restrict_node *my_node; + + my_node = get_node(sizeof *my_node); + + my_node->addr = addr; + my_node->mask = mask; + my_node->flags = flags; + my_node->line_no = line_no; + + return my_node; +} + +void +destroy_restrict_node( + struct restrict_node *my_node + ) +{ + /* With great care, free all the memory occupied by + * the restrict node + */ + if (my_node->addr) + destroy_address_node(my_node->addr); + if (my_node->mask) + destroy_address_node(my_node->mask); + DESTROY_QUEUE(my_node->flags); + free_node(my_node); +} + + +struct setvar_node * +create_setvar_node( + char * var, + char * val, + int isdefault + ) +{ + char * pch; + struct setvar_node *my_node; + + /* do not allow = in the variable name */ + if (NULL != (pch = strchr(var, '='))) + *pch = '\0'; + + /* Now store the string into a setvar_node */ + my_node = get_node(sizeof *my_node); + my_node->var = var; + my_node->val = val; + my_node->isdefault = isdefault; + + return my_node; +} + + +nic_rule_node * +create_nic_rule_node( + int match_class, + char *if_name, /* interface name or numeric address */ + int action + ) +{ + nic_rule_node *my_node; + + NTP_REQUIRE(match_class != 0 || if_name != NULL); + + my_node = get_node(sizeof(*my_node)); + my_node->match_class = match_class; + my_node->if_name = if_name; + my_node->action = action; + + return my_node; +} + + +struct addr_opts_node * +create_addr_opts_node( + struct address_node *addr, + queue *options + ) +{ + struct addr_opts_node *my_node; + + my_node = get_node(sizeof *my_node); + my_node->addr = addr; + my_node->options = options; + return my_node; +} + +script_info * +create_sim_script_info( + double duration, + queue *script_queue + ) +{ +#ifdef SIM + return NULL; +#else + script_info *my_info; + struct attr_val *my_attr_val; + + my_info = get_node(sizeof *my_info); + + /* Initialize Script Info with default values*/ + my_info->duration = duration; + my_info->freq_offset = 0; + my_info->wander = 0; + my_info->jitter = 0; + my_info->prop_delay = NET_DLY; + my_info->proc_delay = PROC_DLY; + + /* Traverse the script_queue and fill out non-default values */ + my_attr_val = queue_head(script_queue); + while (my_attr_val != NULL) { + /* Set the desired value */ + switch (my_attr_val->attr) { + + case T_Freq_Offset: + my_info->freq_offset = my_attr_val->value.d; + break; + + case T_Wander: + my_info->wander = my_attr_val->value.d; + break; + + case T_Jitter: + my_info->jitter = my_attr_val->value.d; + break; + + case T_Prop_Delay: + my_info->prop_delay = my_attr_val->value.d; + break; + + case T_Proc_Delay: + my_info->proc_delay = my_attr_val->value.d; + break; + + default: + msyslog(LOG_ERR, + "Unknown script token %d", + my_attr_val->attr); + } + } + return (my_info); +#endif +} + + +#if !defined(SIM) + +#define ADDR_LENGTH 16 + 1 + +static sockaddr_u * +get_next_address( + struct address_node *addr + ) +{ + const char addr_prefix[] = "192.168.0."; + static int curr_addr_no = 1; + char addr_string[ADDR_LENGTH]; + sockaddr_u *final_addr; + struct addrinfo *ptr; + int retval; + + final_addr = emalloc(sizeof *final_addr); + + if (addr->type == T_String) { + snprintf(addr_string, ADDR_LENGTH, "%s%d", addr_prefix, curr_addr_no++); + printf("Selecting ip address %s for hostname %s\n", addr_string, addr->address); + retval = getaddrinfo(addr_string, "ntp", NULL, &ptr); + } else + retval = getaddrinfo(addr->address, "ntp", NULL, &ptr); + + if (!retval) { + memcpy(final_addr, ptr->ai_addr, ptr->ai_addrlen); + fprintf(stderr, "Successful in setting ip address of simulated server to: %s\n", stoa(final_addr)); + } + else { + fprintf(stderr, "ERROR!! Could not get a new address\n"); + exit(1); + } + freeaddrinfo(ptr); + return final_addr; +} +#endif /* !SIM */ + + +server_info * +create_sim_server( + struct address_node *addr, + double server_offset, + queue *script + ) +{ +#ifdef SIM + return NULL; +#else + server_info *my_info; + + my_info = get_node(sizeof *my_info); + + my_info->server_time = server_offset; + my_info->addr = get_next_address(addr); + my_info->script = script; + my_info->curr_script = dequeue(my_info->script); + return my_info; +#endif /* SIM */ +} + +struct sim_node * +create_sim_node( + queue *init_opts, + queue *servers + ) +{ + struct sim_node *my_node; + + my_node = get_node(sizeof *my_node); + + my_node->init_opts = init_opts; + my_node->servers = servers; + return my_node; +} + + + + +/* FUNCTIONS FOR PERFORMING THE CONFIGURATION + * ------------------------------------------ + */ + +static void +config_other_modes( + struct config_tree *ptree + ) +{ + sockaddr_u addr_sock; + struct address_node *addr_node; + + if (ptree->broadcastclient) + proto_config(PROTO_BROADCLIENT, ptree->broadcastclient, 0., NULL); + + /* Configure the many-cast servers */ + addr_node = queue_head(ptree->manycastserver); + if (addr_node != NULL) { + do { + memset((char *)&addr_sock, 0, sizeof(addr_sock)); + AF(&addr_sock) = (u_short)addr_node->type; + + if (getnetnum(addr_node->address, &addr_sock, 1, t_UNK) == 1) + proto_config(PROTO_MULTICAST_ADD, 0, 0., &addr_sock); + + addr_node = next_node(addr_node); + } while (addr_node != NULL); + sys_manycastserver = 1; + } + + /* Configure the multicast clients */ + addr_node = queue_head(ptree->multicastclient); + if (addr_node != NULL) { + do { + memset((char *)&addr_sock, 0, sizeof(addr_sock)); + AF(&addr_sock) = (u_short)addr_node->type; + + if (getnetnum(addr_node->address, &addr_sock, 1, t_UNK) == 1) + proto_config(PROTO_MULTICAST_ADD, 0, 0., &addr_sock); + + + addr_node = next_node(addr_node); + } while (addr_node != NULL); + proto_config(PROTO_MULTICAST_ADD, 1, 0., NULL); + } +} + + +#ifdef FREE_CFG_T +static void +free_config_other_modes( + struct config_tree *ptree + ) +{ + struct address_node *addr_node; + + while (NULL != (addr_node = dequeue(ptree->manycastserver))) + destroy_address_node(addr_node); + + while (NULL != (addr_node = dequeue(ptree->multicastclient))) + destroy_address_node(addr_node); +} +#endif /* FREE_CFG_T */ + + +static void +config_auth( + struct config_tree *ptree + ) +{ + ntp_u_int16_t ufirst; + ntp_u_int16_t ulast; + ntp_u_int16_t u; + struct attr_val *my_val; +#ifdef OPENSSL +#ifndef NO_INTRES + u_char digest[EVP_MAX_MD_SIZE]; + u_int digest_len; + EVP_MD_CTX ctx; +#endif + int item; +#endif + + /* Crypto Command */ +#ifdef OPENSSL + item = -1; /* quiet warning */ + my_val = queue_head(ptree->auth.crypto_cmd_list); + while (my_val != NULL) { + switch (my_val->attr) { + + default: + NTP_INSIST(0); + break; + + case T_Host: + item = CRYPTO_CONF_PRIV; + break; + + case T_Ident: + item = CRYPTO_CONF_IDENT; + break; + + case T_Pw: + item = CRYPTO_CONF_PW; + break; + + case T_Randfile: + item = CRYPTO_CONF_RAND; + break; + + case T_Sign: + item = CRYPTO_CONF_SIGN; + break; + + case T_Digest: + item = CRYPTO_CONF_NID; + break; + } + crypto_config(item, my_val->value.s); + my_val = next_node(my_val); + } +#endif /* OPENSSL */ + + /* Keysdir Command */ + if (ptree->auth.keysdir) { + if (keysdir != default_keysdir) + free(keysdir); + keysdir = estrdup(ptree->auth.keysdir); + } + + + /* ntp_signd_socket Command */ + if (ptree->auth.ntp_signd_socket) { + if (ntp_signd_socket != default_ntp_signd_socket) + free(ntp_signd_socket); + ntp_signd_socket = estrdup(ptree->auth.ntp_signd_socket); + } + +#ifdef OPENSSL + if (ptree->auth.cryptosw && !cryptosw) { + crypto_setup(); + cryptosw = 1; + } +#endif /* OPENSSL */ + + /* Keys Command */ + if (ptree->auth.keys) + getauthkeys(ptree->auth.keys); + + /* Control Key Command */ + if (ptree->auth.control_key) + ctl_auth_keyid = (keyid_t)ptree->auth.control_key; + + /* Requested Key Command */ + if (ptree->auth.request_key) { + DPRINTF(4, ("set info_auth_keyid to %08lx\n", + (u_long) ptree->auth.request_key)); + info_auth_keyid = (keyid_t)ptree->auth.request_key; + } + + /* Trusted Key Command */ + my_val = queue_head(ptree->auth.trusted_key_list); + for (; my_val != NULL; my_val = next_node(my_val)) { + if ('i' == my_val->attr) + authtrust(my_val->value.i, 1); + else if ('-' == my_val->attr) { + ufirst = my_val->value.u >> 16; + ulast = my_val->value.u & 0xffff; + for (u = ufirst; u <= ulast; u++) + authtrust(u, 1); + } + } + +#ifdef OPENSSL + /* crypto revoke command */ + if (ptree->auth.revoke) + sys_revoke = ptree->auth.revoke; +#endif /* OPENSSL */ + +#ifndef NO_INTRES + /* find a keyid */ + if (info_auth_keyid == 0) + req_keyid = 65535; + else + req_keyid = info_auth_keyid; + + /* if doesn't exist, make up one at random */ + if (authhavekey(req_keyid)) { + req_keytype = cache_type; +#ifndef OPENSSL + req_hashlen = 16; +#else /* OPENSSL follows */ + EVP_DigestInit(&ctx, EVP_get_digestbynid(req_keytype)); + EVP_DigestFinal(&ctx, digest, &digest_len); + req_hashlen = digest_len; +#endif + } else { + int rankey; + + rankey = ntp_random(); + req_keytype = NID_md5; + req_hashlen = 16; + MD5auth_setkey(req_keyid, req_keytype, + (u_char *)&rankey, sizeof(rankey)); + authtrust(req_keyid, 1); + } + + /* save keyid so we will accept config requests with it */ + info_auth_keyid = req_keyid; +#endif /* !NO_INTRES */ + +} + + +#ifdef FREE_CFG_T +static void +free_config_auth( + struct config_tree *ptree + ) +{ + struct attr_val *my_val; + + while (NULL != + (my_val = dequeue(ptree->auth.crypto_cmd_list))) { + + free(my_val->value.s); + free_node(my_val); + } + DESTROY_QUEUE(ptree->auth.crypto_cmd_list); + + DESTROY_QUEUE(ptree->auth.trusted_key_list); +} +#endif /* FREE_CFG_T */ + + +static void +config_tos( + struct config_tree *ptree + ) +{ + struct attr_val *tos; + int item; + + item = -1; /* quiet warning */ + tos = queue_head(ptree->orphan_cmds); + while (tos != NULL) { + switch(tos->attr) { + + default: + NTP_INSIST(0); + break; + + case T_Ceiling: + item = PROTO_CEILING; + break; + + case T_Floor: + item = PROTO_FLOOR; + break; + + case T_Cohort: + item = PROTO_COHORT; + break; + + case T_Orphan: + item = PROTO_ORPHAN; + break; + + case T_Mindist: + item = PROTO_MINDISP; + break; + + case T_Maxdist: + item = PROTO_MAXDIST; + break; + + case T_Minclock: + item = PROTO_MINCLOCK; + break; + + case T_Maxclock: + item = PROTO_MAXCLOCK; + break; + + case T_Minsane: + item = PROTO_MINSANE; + break; + + case T_Beacon: + item = PROTO_BEACON; + break; + } + proto_config(item, 0, tos->value.d, NULL); + tos = next_node(tos); + } +} + + +#ifdef FREE_CFG_T +static void +free_config_tos( + struct config_tree *ptree + ) +{ + struct attr_val *tos; + + while (!empty(ptree->orphan_cmds)) { + tos = dequeue(ptree->orphan_cmds); + free_node(tos); + } +} +#endif /* FREE_CFG_T */ + + +static void +config_monitor( + struct config_tree *ptree + ) +{ + int *pfilegen_token; + const char *filegen_string; + const char *filegen_file; + FILEGEN *filegen; + struct filegen_node *my_node; + struct attr_val *my_opts; + int filegen_type; + int filegen_flag; + + /* Set the statistics directory */ + if (ptree->stats_dir) + stats_config(STATS_STATSDIR, ptree->stats_dir); + + /* NOTE: + * Calling filegen_get is brain dead. Doing a string + * comparison to find the relavant filegen structure is + * expensive. + * + * Through the parser, we already know which filegen is + * being specified. Hence, we should either store a + * pointer to the specified structure in the syntax tree + * or an index into a filegen array. + * + * Need to change the filegen code to reflect the above. + */ + + /* Turn on the specified statistics */ + pfilegen_token = queue_head(ptree->stats_list); + while (pfilegen_token != NULL) { + filegen_string = keyword(*pfilegen_token); + filegen = filegen_get(filegen_string); + + DPRINTF(4, ("enabling filegen for %s statistics '%s%s'\n", + filegen_string, filegen->prefix, + filegen->basename)); + filegen->flag |= FGEN_FLAG_ENABLED; + pfilegen_token = next_node(pfilegen_token); + } + + /* Configure the statistics with the options */ + my_node = queue_head(ptree->filegen_opts); + while (my_node != NULL) { + filegen_file = keyword(my_node->filegen_token); + filegen = filegen_get(filegen_file); + + /* Initialize the filegen variables to their pre-configurtion states */ + filegen_flag = filegen->flag; + filegen_type = filegen->type; + + my_opts = queue_head(my_node->options); + while (my_opts != NULL) { + + switch (my_opts->attr) { + + case T_File: + filegen_file = my_opts->value.p; + break; + + case T_Type: + switch (my_opts->value.i) { + + default: + NTP_INSIST(0); + break; + + case T_None: + filegen_type = FILEGEN_NONE; + break; + + case T_Pid: + filegen_type = FILEGEN_PID; + break; + + case T_Day: + filegen_type = FILEGEN_DAY; + break; + + case T_Week: + filegen_type = FILEGEN_WEEK; + break; + + case T_Month: + filegen_type = FILEGEN_MONTH; + break; + + case T_Year: + filegen_type = FILEGEN_YEAR; + break; + + case T_Age: + filegen_type = FILEGEN_AGE; + break; + } + break; + + case T_Flag: + switch (my_opts->value.i) { + + case T_Link: + filegen_flag |= FGEN_FLAG_LINK; + break; + + case T_Nolink: + filegen_flag &= ~FGEN_FLAG_LINK; + break; + + case T_Enable: + filegen_flag |= FGEN_FLAG_ENABLED; + break; + + case T_Disable: + filegen_flag &= ~FGEN_FLAG_ENABLED; + break; + + default: + msyslog(LOG_ERR, + "Unknown filegen flag token %d", + my_opts->value.i); + exit(1); + } + break; + default: + msyslog(LOG_ERR, + "Unknown filegen option token %d", + my_opts->attr); + exit(1); + } + filegen_config(filegen, filegen_file, + filegen_type, filegen_flag); + my_opts = next_node(my_opts); + } + my_node = next_node(my_node); + } +} + + +#ifdef FREE_CFG_T +static void +free_config_monitor( + struct config_tree *ptree + ) +{ + char **filegen_string; + struct filegen_node *my_node; + struct attr_val *my_opts; + + if (ptree->stats_dir) { + free(ptree->stats_dir); + ptree->stats_dir = NULL; + } + + while (NULL != (filegen_string = dequeue(ptree->stats_list))) + free_node(filegen_string); + + while (NULL != (my_node = dequeue(ptree->filegen_opts))) { + + while (NULL != (my_opts = dequeue(my_node->options))) + free_node(my_opts); + + free_node(my_node); + } +} +#endif /* FREE_CFG_T */ + + +static void +config_access( + struct config_tree *ptree + ) +{ + static int warned_signd; + struct attr_val * my_opt; + struct restrict_node * my_node; + int * curr_flag; + sockaddr_u addr_sock; + sockaddr_u addr_mask; + int flags; + int mflags; + int restrict_default; + const char * signd_warning = +#ifdef HAVE_NTP_SIGND + "MS-SNTP signd operations currently block ntpd degrading service to all clients."; +#else + "mssntp restrict bit ignored, this ntpd was configured without --enable-ntp-signd."; +#endif + + /* Configure the discard options */ + my_opt = queue_head(ptree->discard_opts); + while (my_opt != NULL) { + + switch(my_opt->attr) { + + case T_Average: + ntp_minpoll = my_opt->value.i; + break; + + case T_Minimum: + ntp_minpkt = my_opt->value.i; + break; + + case T_Monitor: + mon_age = my_opt->value.i; + break; + + default: + msyslog(LOG_ERR, + "Unknown discard option token %d", + my_opt->attr); + exit(1); + } + my_opt = next_node(my_opt); + } + + /* Configure the restrict options */ + for (my_node = queue_head(ptree->restrict_opts); + my_node != NULL; + my_node = next_node(my_node)) { + + ZERO_SOCK(&addr_sock); + + if (NULL == my_node->addr) { + /* + * The user specified a default rule without a + * -4 / -6 qualifier, add to both lists + */ + restrict_default = 1; + ZERO_SOCK(&addr_mask); + } else { + restrict_default = 0; + /* Resolve the specified address */ + AF(&addr_sock) = (u_short)my_node->addr->type; + + if (getnetnum(my_node->addr->address, + &addr_sock, 1, t_UNK) != 1) { + + msyslog(LOG_ERR, + "restrict: error in address '%s' on line %d. Ignoring...", + my_node->addr->address, my_node->line_no); + continue; + } + + SET_HOSTMASK(&addr_mask, AF(&addr_sock)); + + /* Resolve the mask */ + if (my_node->mask) { + ZERO_SOCK(&addr_mask); + AF(&addr_mask) = (u_short)my_node->mask->type; + if (getnetnum(my_node->mask->address, &addr_mask, 1, t_MSK) != 1) { + + msyslog(LOG_ERR, + "restrict: error in mask '%s' on line %d. Ignoring...", + my_node->mask->address, my_node->line_no); + continue; + } + } + } + + /* Parse the flags */ + flags = 0; + mflags = 0; + + curr_flag = queue_head(my_node->flags); + while (curr_flag != NULL) { + switch (*curr_flag) { + + default: + NTP_INSIST(0); + break; + + case T_Ntpport: + mflags |= RESM_NTPONLY; + break; + + case T_Flake: + flags |= RES_TIMEOUT; + break; + + case T_Ignore: + flags |= RES_IGNORE; + break; + + case T_Kod: + flags |= RES_KOD; + break; + + case T_Mssntp: + flags |= RES_MSSNTP; + break; + + case T_Limited: + flags |= RES_LIMITED; + break; + + case T_Lowpriotrap: + flags |= RES_LPTRAP; + break; + + case T_Nomodify: + flags |= RES_NOMODIFY; + break; + + case T_Nopeer: + flags |= RES_NOPEER; + break; + + case T_Noquery: + flags |= RES_NOQUERY; + break; + + case T_Noserve: + flags |= RES_DONTSERVE; + break; + + case T_Notrap: + flags |= RES_NOTRAP; + break; + + case T_Notrust: + flags |= RES_DONTTRUST; + break; + + case T_Version: + flags |= RES_VERSION; + break; + } + curr_flag = next_node(curr_flag); + } + + /* Set the flags */ + if (restrict_default) { + AF(&addr_sock) = AF_INET; + hack_restrict(RESTRICT_FLAGS, &addr_sock, &addr_mask, + mflags, flags); + + AF(&addr_sock) = AF_INET6; + } + + hack_restrict(RESTRICT_FLAGS, &addr_sock, &addr_mask, + mflags, flags); + + if ((RES_MSSNTP & flags) && !warned_signd) { + warned_signd = 1; + fprintf(stderr, "%s\n", signd_warning); + msyslog(LOG_WARNING, signd_warning); + } + } +} + + +#ifdef FREE_CFG_T +static void +free_config_access( + struct config_tree *ptree + ) +{ + struct attr_val * my_opt; + struct restrict_node * my_node; + int * curr_flag; + + while (NULL != (my_opt = dequeue(ptree->discard_opts))) + free_node(my_opt); + + while (NULL != (my_node = dequeue(ptree->restrict_opts))) { + while (NULL != (curr_flag = dequeue(my_node->flags))) + free_node(curr_flag); + + destroy_restrict_node(my_node); + } +} +#endif /* FREE_CFG_T */ + + +static void +config_tinker( + struct config_tree *ptree + ) +{ + struct attr_val *tinker; + int item; + + item = -1; /* quiet warning */ + tinker = queue_head(ptree->tinker); + while (tinker != NULL) { + switch (tinker->attr) { + + default: + NTP_INSIST(0); + break; + + case T_Allan: + item = LOOP_ALLAN; + break; + + case T_Dispersion: + item = LOOP_PHI; + break; + + case T_Freq: + item = LOOP_FREQ; + break; + + case T_Huffpuff: + item = LOOP_HUFFPUFF; + break; + + case T_Panic: + item = LOOP_PANIC; + break; + + case T_Step: + item = LOOP_MAX; + break; + + case T_Stepout: + item = LOOP_MINSTEP; + break; + } + loop_config(item, tinker->value.d); + tinker = next_node(tinker); + } +} + + +#ifdef FREE_CFG_T +static void +free_config_tinker( + struct config_tree *ptree + ) +{ + struct attr_val *tinker; + + while (NULL != (tinker = dequeue(ptree->tinker))) + free_node(tinker); +} +#endif /* FREE_CFG_T */ + + +/* + * config_nic_rules - apply interface listen/ignore/drop items + */ +void +config_nic_rules( + struct config_tree *ptree + ) +{ + nic_rule_node * curr_node; + isc_netaddr_t netaddr; + nic_rule_match match_type; + nic_rule_action action; + char * if_name; + char * pchSlash; + int prefixlen; + + curr_node = queue_head(ptree->nic_rules); + + if (curr_node != NULL + && (HAVE_OPT( NOVIRTUALIPS ) || HAVE_OPT( INTERFACE ))) { + msyslog(LOG_ERR, + "interface/nic rules are not allowed with --interface (-I) or --novirtualips (-L)%s", + (input_from_file) ? ", exiting" : ""); + if (input_from_file) + exit(1); + else + return; + } + + for (; + curr_node != NULL; + curr_node = next_node(curr_node)) { + + prefixlen = -1; + if_name = curr_node->if_name; + if (if_name != NULL) + if_name = estrdup(if_name); + + switch (curr_node->match_class) { + + default: + /* + * this assignment quiets a gcc "may be used + * uninitialized" warning and is here for no + * other reason. + */ + match_type = MATCH_ALL; + NTP_INSIST(0); + break; + + case 0: + /* + * 0 is out of range for valid token T_... + * and in a nic_rules_node indicates the + * interface descriptor is either a name or + * address, stored in if_name in either case. + */ + NTP_INSIST(if_name != NULL); + pchSlash = strchr(if_name, '/'); + if (pchSlash != NULL) + *pchSlash = '\0'; + if (is_ip_address(if_name, &netaddr)) { + match_type = MATCH_IFADDR; + if (pchSlash != NULL) { + sscanf(pchSlash + 1, "%d", + &prefixlen); + prefixlen = max(-1, prefixlen); + prefixlen = min(prefixlen, + (AF_INET6 == netaddr.family) + ? 128 + : 32); + } + } else { + match_type = MATCH_IFNAME; + if (pchSlash != NULL) + *pchSlash = '/'; + } + break; + + case T_All: + match_type = MATCH_ALL; + break; + + case T_Ipv4: + match_type = MATCH_IPV4; + break; + + case T_Ipv6: + match_type = MATCH_IPV6; + break; + + case T_Wildcard: + match_type = MATCH_WILDCARD; + break; + } + + switch (curr_node->action) { + + default: + /* + * this assignment quiets a gcc "may be used + * uninitialized" warning and is here for no + * other reason. + */ + action = ACTION_LISTEN; + NTP_INSIST(0); + break; + + case T_Listen: + action = ACTION_LISTEN; + break; + + case T_Ignore: + action = ACTION_IGNORE; + break; + + case T_Drop: + action = ACTION_DROP; + break; + } + + add_nic_rule(match_type, if_name, prefixlen, + action); + timer_interfacetimeout(current_time + 2); + if (if_name != NULL) + free(if_name); + } +} + + +#ifdef FREE_CFG_T +static void +free_config_nic_rules( + struct config_tree *ptree + ) +{ + nic_rule_node *curr_node; + + while (NULL != (curr_node = dequeue(ptree->nic_rules))) { + if (curr_node->if_name != NULL) + free(curr_node->if_name); + free_node(curr_node); + } + DESTROY_QUEUE(ptree->nic_rules); +} +#endif /* FREE_CFG_T */ + + +static void +apply_enable_disable( + queue * q, + int enable + ) +{ + struct attr_val *curr_flag; + int option; +#ifdef BC_LIST_FRAMEWORK_NOT_YET_USED + bc_entry *pentry; +#endif + + for (curr_flag = queue_head(q); + curr_flag != NULL; + curr_flag = next_node(curr_flag)) { + + option = curr_flag->value.i; + switch (option) { + + default: + msyslog(LOG_ERR, + "can not apply enable/disable token %d, unknown", + option); + break; + + case T_Auth: + proto_config(PROTO_AUTHENTICATE, enable, 0., NULL); + break; + + case T_Bclient: + proto_config(PROTO_BROADCLIENT, enable, 0., NULL); + break; + + case T_Calibrate: + proto_config(PROTO_CAL, enable, 0., NULL); + break; + + case T_Kernel: + proto_config(PROTO_KERNEL, enable, 0., NULL); + break; + + case T_Monitor: + proto_config(PROTO_MONITOR, enable, 0., NULL); + break; + + case T_Ntp: + proto_config(PROTO_NTP, enable, 0., NULL); + break; + + case T_Stats: + proto_config(PROTO_FILEGEN, enable, 0., NULL); + break; + +#ifdef BC_LIST_FRAMEWORK_NOT_YET_USED + case T_Bc_bugXXXX: + pentry = bc_list; + while (pentry->token) { + if (pentry->token == option) + break; + pentry++; + } + if (!pentry->token) { + msyslog(LOG_ERR, + "compat token %d not in bc_list[]", + option); + continue; + } + pentry->enabled = enable; + break; +#endif + } + } +} + + +static void +config_system_opts( + struct config_tree *ptree + ) +{ + apply_enable_disable(ptree->enable_opts, 1); + apply_enable_disable(ptree->disable_opts, 0); +} + + +#ifdef FREE_CFG_T +static void +free_config_system_opts( + struct config_tree *ptree + ) +{ + struct attr_val *flag; + + while (NULL != (flag = dequeue(ptree->enable_opts))) + free_node(flag); + + while (NULL != (flag = dequeue(ptree->disable_opts))) + free_node(flag); +} +#endif /* FREE_CFG_T */ + + +static void +config_logconfig( + struct config_tree *ptree + ) +{ + struct attr_val *my_logconfig; + + my_logconfig = queue_head(ptree->logconfig); + while (my_logconfig != NULL) { + + switch (my_logconfig->attr) { + case '+': + ntp_syslogmask |= get_logmask(my_logconfig->value.s); + break; + case '-': + ntp_syslogmask &= ~get_logmask(my_logconfig->value.s); + break; + case '=': + ntp_syslogmask = get_logmask(my_logconfig->value.s); + break; + } + my_logconfig = next_node(my_logconfig); + } +} + + +#ifdef FREE_CFG_T +static void +free_config_logconfig( + struct config_tree *ptree + ) +{ + struct attr_val *my_logconfig; + + while (NULL != (my_logconfig = dequeue(ptree->logconfig))) { + free(my_logconfig->value.s); + free_node(my_logconfig); + } +} +#endif /* FREE_CFG_T */ + + +static void +config_phone( + struct config_tree *ptree + ) +{ + int i = 0; + char **s; + + s = queue_head(ptree->phone); + while (s != NULL) { + if (i < COUNTOF(sys_phone) - 1) + sys_phone[i++] = estrdup(*s); + else + msyslog(LOG_INFO, + "phone: Number of phone entries exceeds %lu. Ignoring phone %s...", + (u_long)(COUNTOF(sys_phone) - 1), *s); + s = next_node(s); + } + + if (i) + sys_phone[i] = NULL; +} + + +#ifdef FREE_CFG_T +static void +free_config_phone( + struct config_tree *ptree + ) +{ + char **s; + + while (NULL != (s = dequeue(ptree->phone))) { + free(*s); + free_node(s); + } +} +#endif /* FREE_CFG_T */ + + +static void +config_qos( + struct config_tree *ptree + ) +{ + struct attr_val *my_qosconfig; + char *s; +#ifdef HAVE_IPTOS_SUPPORT + unsigned int qtos = 0; +#endif + + my_qosconfig = queue_head(ptree->qos); + while (my_qosconfig != NULL) { + s = my_qosconfig->value.s; +#ifdef HAVE_IPTOS_SUPPORT + if (!strcmp(s, "lowdelay")) + qtos = CONF_QOS_LOWDELAY; + else if (!strcmp(s, "throughput")) + qtos = CONF_QOS_THROUGHPUT; + else if (!strcmp(s, "reliability")) + qtos = CONF_QOS_RELIABILITY; + else if (!strcmp(s, "mincost")) + qtos = CONF_QOS_MINCOST; +#ifdef IPTOS_PREC_INTERNETCONTROL + else if (!strcmp(s, "routine") || !strcmp(s, "cs0")) + qtos = CONF_QOS_CS0; + else if (!strcmp(s, "priority") || !strcmp(s, "cs1")) + qtos = CONF_QOS_CS1; + else if (!strcmp(s, "immediate") || !strcmp(s, "cs2")) + qtos = CONF_QOS_CS2; + else if (!strcmp(s, "flash") || !strcmp(s, "cs3")) + qtos = CONF_QOS_CS3; /* overlapping prefix on keyword */ + if (!strcmp(s, "flashoverride") || !strcmp(s, "cs4")) + qtos = CONF_QOS_CS4; + else if (!strcmp(s, "critical") || !strcmp(s, "cs5")) + qtos = CONF_QOS_CS5; + else if(!strcmp(s, "internetcontrol") || !strcmp(s, "cs6")) + qtos = CONF_QOS_CS6; + else if (!strcmp(s, "netcontrol") || !strcmp(s, "cs7")) + qtos = CONF_QOS_CS7; +#endif /* IPTOS_PREC_INTERNETCONTROL */ + if (qtos == 0) + msyslog(LOG_ERR, "parse error, qos %s not accepted\n", s); + else + qos = qtos; +#endif /* HAVE IPTOS_SUPPORT */ + /* + * value is set, but not being effective. Need code to + * change the current connections to notice. Might + * also consider logging a message about the action. + * XXX msyslog(LOG_INFO, "QoS %s requested by config\n", s); + */ + my_qosconfig = next_node(my_qosconfig); + } +} + + +#ifdef FREE_CFG_T +static void +free_config_qos( + struct config_tree *ptree + ) +{ + struct attr_val *my_qosconfig; + + while (NULL != (my_qosconfig = dequeue(ptree->qos))) { + free(my_qosconfig->value.s); + free_node(my_qosconfig); + } +} +#endif /* FREE_CFG_T */ + + +static void +config_setvar( + struct config_tree *ptree + ) +{ + struct setvar_node *my_node; + size_t varlen, vallen, octets; + char * str; + + str = NULL; + my_node = queue_head(ptree->setvar); + while (my_node != NULL) { + varlen = strlen(my_node->var); + vallen = strlen(my_node->val); + octets = varlen + vallen + 1 + 1; + str = erealloc(str, octets); + snprintf(str, octets, "%s=%s", my_node->var, + my_node->val); + set_sys_var(str, octets, (my_node->isdefault) + ? DEF + : 0); + my_node = next_node(my_node); + } + if (str != NULL) + free(str); +} + + +#ifdef FREE_CFG_T +static void +free_config_setvar( + struct config_tree *ptree + ) +{ + struct setvar_node *my_node; + + while (NULL != (my_node = dequeue(ptree->setvar))) { + free(my_node->var); + free(my_node->val); + free_node(my_node); + } +} +#endif /* FREE_CFG_T */ + + +static void +config_ttl( + struct config_tree *ptree + ) +{ + int i = 0; + int *curr_ttl; + + curr_ttl = queue_head(ptree->ttl); + while (curr_ttl != NULL) { + if (i < COUNTOF(sys_ttl)) + sys_ttl[i++] = (u_char)*curr_ttl; + else + msyslog(LOG_INFO, + "ttl: Number of TTL entries exceeds %lu. Ignoring TTL %d...", + (u_long)COUNTOF(sys_ttl), *curr_ttl); + + curr_ttl = next_node(curr_ttl); + } + sys_ttlmax = i - 1; +} + + +#ifdef FREE_CFG_T +static void +free_config_ttl( + struct config_tree *ptree + ) +{ + /* coming DESTROY_QUEUE(ptree->ttl) is enough */ +} +#endif /* FREE_CFG_T */ + + +static void +config_trap( + struct config_tree *ptree + ) +{ + struct addr_opts_node *curr_trap; + struct attr_val *curr_opt; + sockaddr_u addr_sock; + sockaddr_u peeraddr; + struct address_node *addr_node; + struct interface *localaddr; + u_short port_no; + int err_flag; + + /* silence warning about addr_sock potentially uninitialized */ + AF(&addr_sock) = AF_UNSPEC; + + for (curr_trap = queue_head(ptree->trap); + curr_trap != NULL; + curr_trap = next_node(curr_trap)) { + + err_flag = 0; + port_no = 0; + localaddr = NULL; + + curr_opt = queue_head(curr_trap->options); + while (curr_opt != NULL) { + if (T_Port == curr_opt->attr) { + if (curr_opt->value.i < 1 + || curr_opt->value.i > USHRT_MAX) { + msyslog(LOG_ERR, + "invalid port number " + "%d, trap ignored", + curr_opt->value.i); + err_flag = 1; + } + port_no = (u_short)curr_opt->value.i; + } + else if (T_Interface == curr_opt->attr) { + addr_node = curr_opt->value.p; + + /* Resolve the interface address */ + ZERO_SOCK(&addr_sock); + AF(&addr_sock) = (u_short)addr_node->type; + + if (getnetnum(addr_node->address, + &addr_sock, 1, t_UNK) != 1) { + err_flag = 1; break; + } + + localaddr = findinterface(&addr_sock); + + if (NULL == localaddr) { + msyslog(LOG_ERR, + "can't find interface with address %s", + stoa(&addr_sock)); + err_flag = 1; + } + } + curr_opt = next_node(curr_opt); + } + + /* Now process the trap for the specified interface + * and port number + */ + if (!err_flag) { + ZERO_SOCK(&peeraddr); + if (1 != getnetnum(curr_trap->addr->address, + &peeraddr, 1, t_UNK)) + continue; + + /* port is at same location for v4 and v6 */ + SET_PORT(&peeraddr, port_no ? port_no : TRAPPORT); + + if (NULL == localaddr) + localaddr = ANY_INTERFACE_CHOOSE(&peeraddr); + else + AF(&peeraddr) = AF(&addr_sock); + + if (!ctlsettrap(&peeraddr, localaddr, 0, + NTP_VERSION)) + msyslog(LOG_ERR, + "can't set trap for %s", + stoa(&peeraddr)); + } + } +} + + +#ifdef FREE_CFG_T +static void +free_config_trap( + struct config_tree *ptree + ) +{ + struct addr_opts_node *curr_trap; + struct attr_val *curr_opt; + struct address_node *addr_node; + + while (NULL != (curr_trap = dequeue(ptree->trap))) { + while (curr_trap->options != NULL && NULL != + (curr_opt = dequeue(curr_trap->options))) { + + if (T_Interface == curr_opt->attr) { + addr_node = curr_opt->value.p; + destroy_address_node(addr_node); + } + free_node(curr_opt); + } + DESTROY_QUEUE(curr_trap->options); + free_node(curr_trap); + } +} +#endif /* FREE_CFG_T */ + + +static void +config_fudge( + struct config_tree *ptree + ) +{ + struct addr_opts_node *curr_fudge; + struct attr_val *curr_opt; + sockaddr_u addr_sock; + struct address_node *addr_node; + struct refclockstat clock_stat; + int err_flag; + + curr_fudge = queue_head(ptree->fudge); + while (curr_fudge != NULL) { + err_flag = 0; + + /* Get the reference clock address and + * ensure that it is sane + */ + addr_node = curr_fudge->addr; + ZERO_SOCK(&addr_sock); + if (getnetnum(addr_node->address, &addr_sock, 1, t_REF) + != 1) + err_flag = 1; + + if (!ISREFCLOCKADR(&addr_sock)) { + msyslog(LOG_ERR, + "inappropriate address %s for the fudge command, line ignored", + stoa(&addr_sock)); + err_flag = 1; + } + + /* Parse all the options to the fudge command */ + memset(&clock_stat, 0, sizeof(clock_stat)); + curr_opt = queue_head(curr_fudge->options); + while (curr_opt != NULL) { + switch (curr_opt->attr) { + case T_Time1: + clock_stat.haveflags |= CLK_HAVETIME1; + clock_stat.fudgetime1 = curr_opt->value.d; + break; + case T_Time2: + clock_stat.haveflags |= CLK_HAVETIME2; + clock_stat.fudgetime2 = curr_opt->value.d; + break; + case T_Stratum: + clock_stat.haveflags |= CLK_HAVEVAL1; + clock_stat.fudgeval1 = curr_opt->value.i; + break; + case T_Refid: + clock_stat.haveflags |= CLK_HAVEVAL2; + clock_stat.fudgeval2 = 0; + memcpy(&clock_stat.fudgeval2, + curr_opt->value.s, + min(strlen(curr_opt->value.s), 4)); + break; + case T_Flag1: + clock_stat.haveflags |= CLK_HAVEFLAG1; + if (curr_opt->value.i) + clock_stat.flags |= CLK_FLAG1; + else + clock_stat.flags &= ~CLK_FLAG1; + break; + case T_Flag2: + clock_stat.haveflags |= CLK_HAVEFLAG2; + if (curr_opt->value.i) + clock_stat.flags |= CLK_FLAG2; + else + clock_stat.flags &= ~CLK_FLAG2; + break; + case T_Flag3: + clock_stat.haveflags |= CLK_HAVEFLAG3; + if (curr_opt->value.i) + clock_stat.flags |= CLK_FLAG3; + else + clock_stat.flags &= ~CLK_FLAG3; + break; + case T_Flag4: + clock_stat.haveflags |= CLK_HAVEFLAG4; + if (curr_opt->value.i) + clock_stat.flags |= CLK_FLAG4; + else + clock_stat.flags &= ~CLK_FLAG4; + break; + default: + msyslog(LOG_ERR, + "Unexpected fudge internal flag 0x%x for %s\n", + curr_opt->attr, stoa(&addr_sock)); + exit(curr_opt->attr ? curr_opt->attr : 1); + } + + curr_opt = next_node(curr_opt); + } + +#ifdef REFCLOCK + if (!err_flag) + refclock_control(&addr_sock, &clock_stat, + (struct refclockstat *)0); +#endif + + curr_fudge = next_node(curr_fudge); + } +} + + +#ifdef FREE_CFG_T +static void +free_config_fudge( + struct config_tree *ptree + ) +{ + struct addr_opts_node *curr_fudge; + struct attr_val *curr_opt; + + while (NULL != (curr_fudge = dequeue(ptree->fudge))) { + while (NULL != (curr_opt = dequeue(curr_fudge->options))) { + + switch (curr_opt->attr) { + case CLK_HAVEVAL2: + free(curr_opt->value.s); + } + + free_node(curr_opt); + } + + DESTROY_QUEUE(curr_fudge->options); + free_node(curr_fudge); + } +} +#endif /* FREE_CFG_T */ + + +static void +config_vars( + struct config_tree *ptree + ) +{ + struct attr_val *curr_var; + FILE *new_file; + int len; + + curr_var = queue_head(ptree->vars); + while (curr_var != NULL) { + /* Determine which variable to set and set it */ + switch (curr_var->attr) { + case T_Broadcastdelay: + proto_config(PROTO_BROADDELAY, 0, curr_var->value.d, NULL); + break; + case T_Calldelay: + proto_config(PROTO_CALLDELAY, curr_var->value.i, 0, NULL); + break; + case T_Tick: + proto_config(PROTO_ADJ, 0, curr_var->value.d, NULL); + break; + case T_Driftfile: + if ('\0' == curr_var->value.s[0]) { + stats_drift_file = 0; + msyslog(LOG_INFO, "config: driftfile disabled\n"); + } else + stats_config(STATS_FREQ_FILE, curr_var->value.s); + break; + case T_WanderThreshold: + wander_threshold = curr_var->value.d; + break; + case T_Leapfile: + stats_config(STATS_LEAP_FILE, curr_var->value.s); + break; + case T_Pidfile: + stats_config(STATS_PID_FILE, curr_var->value.s); + break; + case T_Logfile: + new_file = fopen(curr_var->value.s, "a"); + if (new_file != NULL) { + NLOG(NLOG_SYSINFO) /* conditional if clause for conditional syslog */ + msyslog(LOG_NOTICE, "logging to file %s", curr_var->value.s); + if (syslog_file != NULL && + fileno(syslog_file) != fileno(new_file)) + (void)fclose(syslog_file); + + syslog_file = new_file; + syslogit = 0; + } + else + msyslog(LOG_ERR, + "Cannot open log file %s", + curr_var->value.s); + break; + + case T_Saveconfigdir: + if (saveconfigdir != NULL) + free(saveconfigdir); + len = strlen(curr_var->value.s); + if (0 == len) + saveconfigdir = NULL; + else if (DIR_SEP != curr_var->value.s[len - 1] +#ifdef SYS_WINNT /* slash is also a dir. sep. on Windows */ + && '/' != curr_var->value.s[len - 1] +#endif + ) { + len++; + saveconfigdir = emalloc(len + 1); + snprintf(saveconfigdir, len + 1, + "%s%c", + curr_var->value.s, + DIR_SEP); + } else + saveconfigdir = estrdup( + curr_var->value.s); + break; + + case T_Automax: +#ifdef OPENSSL + sys_automax = curr_var->value.i; +#endif + break; + + default: + msyslog(LOG_ERR, + "config_vars(): unexpected token %d", + curr_var->attr); + } + curr_var = next_node(curr_var); + } +} + + +#ifdef FREE_CFG_T +static void +free_config_vars( + struct config_tree *ptree + ) +{ + struct attr_val *curr_var; + + while (NULL != (curr_var = dequeue(ptree->vars))) { + /* Determine which variable to set and set it */ + switch (curr_var->attr) { + case T_Driftfile: + case T_Leapfile: + case T_Pidfile: + case T_Logfile: + free(curr_var->value.s); + } + free_node(curr_var); + } +} +#endif /* FREE_CFG_T */ + + +/* Define a function to check if a resolved address is sane. + * If yes, return 1, else return 0; + */ +static int +is_sane_resolved_address( + sockaddr_u * peeraddr, + int hmode + ) +{ + if (!ISREFCLOCKADR(peeraddr) && ISBADADR(peeraddr)) { + msyslog(LOG_ERR, + "attempt to configure invalid address %s", + stoa(peeraddr)); + return 0; + } + /* + * Shouldn't be able to specify multicast + * address for server/peer! + * and unicast address for manycastclient! + */ + if ((T_Server == hmode || T_Peer == hmode || T_Pool == hmode) + && IS_MCAST(peeraddr)) { + msyslog(LOG_ERR, + "attempt to configure invalid address %s", + stoa(peeraddr)); + return 0; + } + if (T_Manycastclient == hmode && !IS_MCAST(peeraddr)) { + msyslog(LOG_ERR, + "attempt to configure invalid address %s", + stoa(peeraddr)); + return 0; + } - case CONFIG_UNKNOWN: - errflg = -1; - break; - } + if (IS_IPV6(peeraddr) && !ipv6_works) + return 0; + + /* Ok, all tests succeeded, now we can return 1 */ + return 1; +} + +static int +get_correct_host_mode( + int hmode + ) +{ + switch (hmode) { + case T_Server: + case T_Pool: + case T_Manycastclient: + return MODE_CLIENT; + break; + case T_Peer: + return MODE_ACTIVE; + break; + case T_Broadcast: + return MODE_BROADCAST; + break; + default: + return -1; + } +} + +static void +config_peers( + struct config_tree *ptree + ) +{ + struct addrinfo *res, *res_bak; + sockaddr_u peeraddr; + struct peer_node *curr_peer; + struct attr_val *option; + int hmode; + int peerflags; + int status; + int no_needed; + int i; + + curr_peer = queue_head(ptree->peers); + while (curr_peer != NULL) { + /* Find the number of associations needed. + * If a pool coomand is specified, then sys_maxclock needed + * else, only one is needed + */ + no_needed = (T_Pool == curr_peer->host_mode) + ? sys_maxclock + : 1; + + /* Find the correct host-mode */ + hmode = get_correct_host_mode(curr_peer->host_mode); + NTP_INSIST(hmode != -1); + + /* translate peerflags options to bits */ + peerflags = 0; + option = queue_head(curr_peer->peerflags); + for (; option != NULL; option = next_node(option)) + switch (option->value.i) { + + default: + NTP_INSIST(0); + break; + + case T_Autokey: + peerflags |= FLAG_SKEY; + break; + + case T_Burst: + peerflags |= FLAG_BURST; + break; + + case T_Iburst: + peerflags |= FLAG_IBURST; + break; + + case T_Noselect: + peerflags |= FLAG_NOSELECT; + break; + + case T_Preempt: + peerflags |= FLAG_PREEMPT; + break; + + case T_Prefer: + peerflags |= FLAG_PREFER; + break; + + case T_True: + peerflags |= FLAG_TRUE; + break; + + case T_Xleave: + peerflags |= FLAG_XLEAVE; + break; } -#ifdef REFCLOCK + /* Attempt to resolve the address */ + ZERO_SOCK(&peeraddr); + AF(&peeraddr) = (u_short)curr_peer->addr->type; + + status = get_multiple_netnums(curr_peer->addr->address, + &peeraddr, &res, 0, t_UNK); + +#ifdef FORCE_DEFER_DNS + /* Hack for debugging Deferred DNS + * Pretend working names didn't work. + */ + if (status == 1) { + /* Deferring everything breaks refclocks. */ + memcpy(&peeraddr, res->ai_addr, res->ai_addrlen); + if (!ISREFCLOCKADR(&peeraddr)) { + status = 0; /* force deferred DNS path */ + msyslog(LOG_INFO, "Forcing Deferred DNS for %s, %s", + curr_peer->addr->address, stoa(&peeraddr)); + } else { + msyslog(LOG_INFO, "NOT Deferring DNS for %s, %s", + curr_peer->addr->address, stoa(&peeraddr)); + } + } +#endif + + /* I don't know why getnetnum would return -1. + * The old code had this test, so I guess it must be + * useful + */ + if (status == -1) { + /* Do nothing, apparently we found an IPv6 + * address and can't do anything about it */ + } + /* Check if name resolution failed. If yes, store the + * peer information in a file for asynchronous + * resolution later + */ + else if (status != 1) { + msyslog(LOG_INFO, "Deferring DNS for %s %d", curr_peer->addr->address, no_needed); + save_resolve(curr_peer->addr->address, + no_needed, + curr_peer->addr->type, + hmode, + curr_peer->peerversion, + curr_peer->minpoll, + curr_peer->maxpoll, + peerflags, + curr_peer->ttl, + curr_peer->peerkey, + (u_char *)"*"); + } + /* Yippie!! Name resolution has succeeded!!! + * Now we can proceed to some more sanity checks on + * the resolved address before we start to configure + * the peer + */ + else { + res_bak = res; + /* - * If reference clock support isn't defined the - * fudge line will still be accepted and syntax - * checked, but will essentially do nothing. + * Loop to configure the desired number of + * associations */ - if (!errflg) { - refclock_control(&peeraddr, &clock_stat, - (struct refclockstat *)0); + for (i = 0; (i < no_needed) && res; res = + res->ai_next) { + ++i; + memcpy(&peeraddr, res->ai_addr, + res->ai_addrlen); + if (is_sane_resolved_address( + &peeraddr, + curr_peer->host_mode)) + + peer_config(&peeraddr, + NULL, + hmode, + curr_peer->peerversion, + curr_peer->minpoll, + curr_peer->maxpoll, + peerflags, + curr_peer->ttl, + curr_peer->peerkey, + (u_char *)"*"); } -#endif - break; + freeaddrinfo(res_bak); + } + curr_peer = next_node(curr_peer); + } +} - case CONFIG_STATSDIR: - if (ntokens >= 2) - stats_config(STATS_STATSDIR,tokens[1]); - break; - case CONFIG_STATISTICS: - for (i = 1; i < ntokens; i++) { - filegen = filegen_get(tokens[i]); +#ifdef FREE_CFG_T +static void +free_config_peers( + struct config_tree *ptree + ) +{ + struct peer_node *curr_peer; - if (filegen == NULL) { - msyslog(LOG_ERR, - "no statistics named %s available", - tokens[i]); - continue; - } -#ifdef DEBUG - if (debug > 3) - printf("enabling filegen for %s statistics \"%s%s\"\n", - tokens[i], filegen->prefix, filegen->basename); -#endif - filegen->flag |= FGEN_FLAG_ENABLED; - } - break; + while (NULL != (curr_peer = dequeue(ptree->peers))) { + destroy_address_node(curr_peer->addr); + DESTROY_QUEUE(curr_peer->peerflags); + free_node(curr_peer); + } +} +#endif /* FREE_CFG_T */ - case CONFIG_FILEGEN: - if (ntokens < 2) { - msyslog(LOG_ERR, - "no id for filegen command, line ignored"); - break; - } - filegen = filegen_get(tokens[1]); - if (filegen == NULL) { - msyslog(LOG_ERR, - "unknown filegen \"%s\" ignored", - tokens[1]); - break; - } +static void +config_unpeers( + struct config_tree *ptree + ) +{ + struct addrinfo *res, *res_bak; + sockaddr_u peeraddr; + struct unpeer_node *curr_unpeer; + struct peer *peer; + int status; + int found; + + for (curr_unpeer = queue_head(ptree->unpeers); + curr_unpeer != NULL; + curr_unpeer = next_node(curr_unpeer)) { + + /* + * Either AssocID will be zero, and we unpeer by name/ + * address addr, or it is nonzero and addr NULL. + */ + if (curr_unpeer->assocID) { + peer = findpeerbyassoc((u_int)curr_unpeer->assocID); + if (peer != NULL) { + peer_clear(peer, "GONE"); + unpeer(peer); + } + + continue; + } + + /* Attempt to resolve the name or address */ + ZERO_SOCK(&peeraddr); + AF(&peeraddr) = (u_short)curr_unpeer->addr->type; + + status = get_multiple_netnums( + curr_unpeer->addr->address, &peeraddr, &res, 0, + t_UNK); + + /* I don't know why getnetnum would return -1. + * The old code had this test, so I guess it must be + * useful + */ + if (status == -1) { + /* Do nothing, apparently we found an IPv6 + * address and can't do anything about it */ + } + /* Check if name resolution failed. If yes, throw + * up our hands. + */ + else if (status != 1) { + /* Do nothing */ + } + /* Yippie!! Name resolution has succeeded!!! + */ + else { + res_bak = res; + /* - * peerversion is (ab)used for filegen file (index) - * peerkey is (ab)used for filegen type - * peerflags is (ab)used for filegen flags + * Loop through the addresses found */ - peerversion = 0; - peerkey = filegen->type; - peerflags = filegen->flag; - errflg = 0; - - for (i = 2; i < ntokens; i++) { - switch (matchkey(tokens[i], - filegen_keywords, 1)) { - case CONF_FGEN_FILE: - if (i >= ntokens - 1) { - msyslog(LOG_ERR, - "filegen %s file requires argument", - tokens[1]); - errflg = i; - break; - } - peerversion = ++i; - break; - case CONF_FGEN_TYPE: - if (i >= ntokens -1) { - msyslog(LOG_ERR, - "filegen %s type requires argument", - tokens[1]); - errflg = i; - break; - } - peerkey = matchkey(tokens[++i], - fgen_types, 1); - if (peerkey == CONFIG_UNKNOWN) { - msyslog(LOG_ERR, - "filegen %s unknown type \"%s\"", - tokens[1], tokens[i]); - errflg = i; - break; - } - break; + while (res) { + memcpy(&peeraddr, res->ai_addr, res->ai_addrlen); - case CONF_FGEN_FLAG_LINK: - peerflags |= FGEN_FLAG_LINK; - break; + found = 0; + peer = NULL; - case CONF_FGEN_FLAG_NOLINK: - peerflags &= ~FGEN_FLAG_LINK; - break; + DPRINTF(1, ("searching for %s\n", stoa(&peeraddr))); - case CONF_FGEN_FLAG_ENABLE: - peerflags |= FGEN_FLAG_ENABLED; - break; + while (!found) { + peer = findexistingpeer(&peeraddr, peer, -1); + if (!peer) + break; + if (peer->flags & FLAG_CONFIG) + found = 1; + } - case CONF_FGEN_FLAG_DISABLE: - peerflags &= ~FGEN_FLAG_ENABLED; - break; + if (found) { + peer_clear(peer, "GONE"); + unpeer(peer); } + + res = res->ai_next; } - if (!errflg) - filegen_config(filegen, tokens[peerversion], - (u_char)peerkey, (u_char)peerflags); + freeaddrinfo(res_bak); + } + } +} + + +#ifdef FREE_CFG_T +static void +free_config_unpeers( + struct config_tree *ptree + ) +{ + struct unpeer_node *curr_unpeer; + + while (NULL != (curr_unpeer = dequeue(ptree->unpeers))) { + destroy_address_node(curr_unpeer->addr); + free_node(curr_unpeer); + } +} +#endif /* FREE_CFG_T */ + + +#ifdef SIM +static void +config_sim( + struct config_tree *ptree + ) +{ + int i; + server_info *serv_info; + struct attr_val *init_stmt; + + /* Check if a simulate block was found in the configuration code. + * If not, return an error and exit + */ + if (NULL == ptree->sim_details) { + fprintf(stderr, "ERROR!! I couldn't find a \"simulate\" block for configuring the simulator.\n"); + fprintf(stderr, "\tCheck your configuration file.\n"); + exit(1); + } + + /* Process the initialization statements + * ------------------------------------- + */ + init_stmt = queue_head(ptree->sim_details->init_opts); + while (init_stmt != NULL) { + + switch(init_stmt->attr) { + + case T_Beep_Delay: + simulation.beep_delay = init_stmt->value.d; + break; + + case T_Sim_Duration: + simulation.end_time = init_stmt->value.d; break; - case CONFIG_SETVAR: - if (ntokens < 2) { - msyslog(LOG_ERR, - "no value for setvar command - line ignored"); - } else { - set_sys_var(tokens[1], strlen(tokens[1])+1, - (u_short) (RW | - ((((ntokens > 2) - && !strcmp(tokens[2], - "default"))) - ? DEF - : 0))); - } - break; + default: + fprintf(stderr, + "Unknown simulator init token %d\n", + init_stmt->attr); + exit(1); + } + init_stmt = next_node(init_stmt); + } + + + /* Process the server list + * ----------------------- + */ + simulation.num_of_servers = + get_no_of_elements(ptree->sim_details->servers); + simulation.servers = emalloc(simulation.num_of_servers + * sizeof(server_info)); + + serv_info = queue_head(ptree->sim_details->servers); + for (i = 0;i < simulation.num_of_servers; i++) { + if (NULL == serv_info) { + fprintf(stderr, "Simulator server list is corrupt\n"); + exit(1); + } else + memcpy(&simulation.servers[i], serv_info, sizeof(server_info)); + serv_info = next_node(serv_info); + } + + /* Create server associations */ + printf("Creating server associations\n"); + create_server_associations(); + fprintf(stderr,"\tServer associations successfully created!!\n"); +} + + +#ifdef FREE_CFG_T +static void +free_config_sim( + struct config_tree *ptree + ) +{ + if (NULL == ptree->sim_details) + return; + + DESTROY_QUEUE(ptree->sim_details->init_opts); + DESTROY_QUEUE(ptree->sim_details->servers); + + /* Free the sim_node memory and set the sim_details as NULL */ + free_node(ptree->sim_details); + ptree->sim_details = NULL; +} +#endif /* FREE_CFG_T */ +#endif /* SIM */ + + +/* Define two different config functions. One for the daemon and the other for + * the simulator. The simulator ignores a lot of the standard ntpd configuration + * options + */ +#ifndef SIM +static void +config_ntpd( + struct config_tree *ptree + ) +{ + config_nic_rules(ptree); + io_open_sockets(); + config_monitor(ptree); + config_auth(ptree); + config_tos(ptree); + config_access(ptree); + config_tinker(ptree); + config_system_opts(ptree); + config_logconfig(ptree); + config_phone(ptree); + config_setvar(ptree); + config_ttl(ptree); + config_trap(ptree); + config_vars(ptree); + config_other_modes(ptree); + config_peers(ptree); + config_unpeers(ptree); + config_fudge(ptree); + config_qos(ptree); +} +#endif /* !SIM */ + + +#ifdef SIM +static void +config_ntpdsim( + struct config_tree *ptree + ) +{ + printf("Configuring Simulator...\n"); + printf("Some ntpd-specific commands in the configuration file will be ignored.\n"); + + config_tos(ptree); + config_monitor(ptree); + config_tinker(ptree); + config_system_opts(ptree); + config_logconfig(ptree); + config_vars(ptree); + config_sim(ptree); +} +#endif /* SIM */ + + +/* + * config_remotely() - implements ntpd side of ntpq :config + */ +void +config_remotely( + sockaddr_u * remote_addr + ) +{ + struct FILE_INFO remote_cuckoo; + char origin[128]; + + snprintf(origin, sizeof(origin), "remote config from %s", + stoa(remote_addr)); + memset(&remote_cuckoo, 0, sizeof(remote_cuckoo)); + remote_cuckoo.fname = origin; + remote_cuckoo.line_no = 1; + remote_cuckoo.col_no = 1; + ip_file = &remote_cuckoo; + input_from_file = 0; + + init_syntax_tree(&cfgt); + yyparse(); + cfgt.source.attr = CONF_SOURCE_NTPQ; + cfgt.timestamp = time(NULL); + cfgt.source.value.s = estrdup(stoa(remote_addr)); + + DPRINTF(1, ("Finished Parsing!!\n")); + + save_and_apply_config_tree(); + + input_from_file = 1; +} + + +/* + * getconfig() - process startup configuration file e.g /etc/ntp.conf + */ +void +getconfig( + int argc, + char *argv[] + ) +{ + char line[MAXLINE]; + +#ifdef DEBUG + atexit(free_all_config_trees); +#endif +#ifndef SYS_WINNT + config_file = CONFIG_FILE; +#else + temp = CONFIG_FILE; + if (!ExpandEnvironmentStrings((LPCTSTR)temp, (LPTSTR)config_file_storage, (DWORD)sizeof(config_file_storage))) { + msyslog(LOG_ERR, "ExpandEnvironmentStrings CONFIG_FILE failed: %m\n"); + exit(1); + } + config_file = config_file_storage; + + temp = ALT_CONFIG_FILE; + if (!ExpandEnvironmentStrings((LPCTSTR)temp, (LPTSTR)alt_config_file_storage, (DWORD)sizeof(alt_config_file_storage))) { + msyslog(LOG_ERR, "ExpandEnvironmentStrings ALT_CONFIG_FILE failed: %m\n"); + exit(1); + } + alt_config_file = alt_config_file_storage; + +#endif /* SYS_WINNT */ + res_fp = NULL; + ntp_syslogmask = NLOG_SYNCMASK; /* set more via logconfig */ + + /* + * install a non default variable with this daemon version + */ + snprintf(line, sizeof(line), "daemon_version=\"%s\"", Version); + set_sys_var(line, strlen(line)+1, RO); + + /* + * Set up for the first time step to install a variable showing + * which syscall is being used to step. + */ + set_tod_using = &ntpd_set_tod_using; + + /* + * On Windows, the variable has already been set, on the rest, + * initialize it to "UNKNOWN". + */ +#ifndef SYS_WINNT + strncpy(line, "settimeofday=\"UNKNOWN\"", sizeof(line)); + set_sys_var(line, strlen(line) + 1, RO); +#endif + + /* + * Initialize the loop. + */ + loop_config(LOOP_DRIFTINIT, 0.); + + getCmdOpts(argc, argv); + + init_syntax_tree(&cfgt); + + curr_include_level = 0; + if ( + (fp[curr_include_level] = F_OPEN(FindConfig(config_file), "r")) == NULL +#ifdef HAVE_NETINFO + /* If there is no config_file, try NetInfo. */ + && check_netinfo && !(config_netinfo = get_netinfo_config()) +#endif /* HAVE_NETINFO */ + ) { + msyslog(LOG_INFO, "getconfig: Couldn't open <%s>", FindConfig(config_file)); +#ifndef SYS_WINNT + io_open_sockets(); + + return; +#else + /* Under WinNT try alternate_config_file name, first NTP.CONF, then NTP.INI */ - case CONFIG_ENABLE: - for (i = 1; i < ntokens; i++) { - int flag; + if ((fp[curr_include_level] = F_OPEN(FindConfig(alt_config_file), "r")) == NULL) { - flag = matchkey(tokens[i], flags_keywords, 1); - if (flag == CONFIG_UNKNOWN) { - msyslog(LOG_ERR, - "enable unknown flag %s", - tokens[i]); - errflg = 1; - break; - } - proto_config(flag, 1, 0., NULL); - } - break; + /* + * Broadcast clients can sometimes run without + * a configuration file. + */ + msyslog(LOG_INFO, "getconfig: Couldn't open <%s>", FindConfig(alt_config_file)); + io_open_sockets(); - case CONFIG_DISABLE: - for (i = 1; i < ntokens; i++) { - int flag; + return; + } + cfgt.source.value.s = estrdup(alt_config_file); +#endif /* SYS_WINNT */ + } else + cfgt.source.value.s = estrdup(config_file); - flag = matchkey(tokens[i], flags_keywords, 1); - if (flag == CONFIG_UNKNOWN) { - msyslog(LOG_ERR, - "disable unknown flag %s", - tokens[i]); - errflg = 1; - break; - } - proto_config(flag, 0, 0., NULL); - } - break; - case CONFIG_PHONE: - for (i = 1; i < ntokens && i < MAXPHONE - 1; i++) { - sys_phone[i - 1] = - emalloc(strlen(tokens[i]) + 1); - strcpy(sys_phone[i - 1], tokens[i]); - } - sys_phone[i] = NULL; - break; + /*** BULK OF THE PARSER ***/ +#ifdef DEBUG + yydebug = !!(debug >= 5); +#endif + ip_file = fp[curr_include_level]; + yyparse(); + + DPRINTF(1, ("Finished Parsing!!\n")); - case CONFIG_ADJ: { - double ftemp; + cfgt.source.attr = CONF_SOURCE_FILE; + cfgt.timestamp = time(NULL); - sscanf(tokens[1], "%lf", &ftemp); - proto_config(PROTO_ADJ, 0, ftemp, NULL); - } - break; + save_and_apply_config_tree(); - } - } - if (fp[0]) - (void)fclose(fp[0]); + while (curr_include_level != -1) + FCLOSE(fp[curr_include_level--]); #ifdef HAVE_NETINFO if (config_netinfo) free_netinfo_config(config_netinfo); #endif /* HAVE_NETINFO */ -#if !defined(VMS) && !defined(SYS_VXWORKS) - /* find a keyid */ - if (info_auth_keyid == 0) - req_keyid = 65535; - else - req_keyid = info_auth_keyid; - - /* if doesn't exist, make up one at random */ - if (!authhavekey(req_keyid)) { - char rankey[9]; - int j; - - for (i = 0; i < 8; i++) - for (j = 1; j < 100; ++j) { - rankey[i] = (char) (ntp_random() & 0xff); - if (rankey[i] != 0) break; - } - rankey[8] = 0; - authusekey(req_keyid, KEY_TYPE_MD5, (u_char *)rankey); - authtrust(req_keyid, 1); - if (!authhavekey(req_keyid)) { - msyslog(LOG_ERR, "getconfig: Couldn't generate a valid random key!"); - /* HMS: Should this be fatal? */ - } - } - - /* save keyid so we will accept config requests with it */ - info_auth_keyid = req_keyid; -#endif /* !defined(VMS) && !defined(SYS_VXWORKS) */ + /* + printf("getconfig: res_fp <%p> call_resolver: %d", res_fp, call_resolver); + */ if (res_fp != NULL) { if (call_resolver) { @@ -1912,19 +3927,175 @@ } +void +save_and_apply_config_tree(void) +{ + struct config_tree *ptree; +#ifndef SAVECONFIG + struct config_tree *punlinked; +#endif + + /* + * Keep all the configuration trees applied since startup in + * a list that can be used to dump the configuration back to + * a text file. + */ + ptree = emalloc(sizeof(*ptree)); + memcpy(ptree, &cfgt, sizeof(*ptree)); + memset(&cfgt, 0, sizeof(cfgt)); + + LINK_TAIL_SLIST(cfg_tree_history, ptree, link, + struct config_tree); + +#ifdef SAVECONFIG + if (HAVE_OPT( SAVECONFIGQUIT )) { + FILE *dumpfile; + int err; + int dumpfailed; + + dumpfile = fopen(OPT_ARG( SAVECONFIGQUIT ), "w"); + if (NULL == dumpfile) { + err = errno; + fprintf(stderr, + "can not create save file %s, error %d %s\n", + OPT_ARG( SAVECONFIGQUIT ), err, + strerror(err)); + exit(err); + } + + dumpfailed = dump_all_config_trees(dumpfile, 0); + if (dumpfailed) + fprintf(stderr, + "--saveconfigquit %s error %d\n", + OPT_ARG( SAVECONFIGQUIT ), + dumpfailed); + else + fprintf(stderr, + "configuration saved to %s\n", + OPT_ARG( SAVECONFIGQUIT )); + + exit(dumpfailed); + } +#endif /* SAVECONFIG */ + + /* The actual configuration done depends on whether we are configuring the + * simulator or the daemon. Perform a check and call the appropriate + * function as needed. + */ + +#ifndef SIM + config_ntpd(ptree); +#else + config_ntpdsim(ptree); +#endif + + /* + * With configure --disable-saveconfig, there's no use keeping + * the config tree around after application, so free it. + */ +#ifndef SAVECONFIG + UNLINK_SLIST(punlinked, cfg_tree_history, ptree, link, + struct config_tree); + NTP_INSIST(punlinked == ptree); + free_config_tree(ptree); +#endif +} + + +void +ntpd_set_tod_using( + const char *which + ) +{ + char line[128]; + + snprintf(line, sizeof(line), "settimeofday=\"%s\"", which); + set_sys_var(line, strlen(line) + 1, RO); +} + + +/* FUNCTIONS COPIED FROM THE OLDER ntp_config.c + * -------------------------------------------- + */ + + +/* + * get_pfxmatch - find value for prefixmatch + * and update char * accordingly + */ +static unsigned long +get_pfxmatch( + char ** s, + struct masks *m + ) +{ + while (m->name) { + if (strncmp(*s, m->name, strlen(m->name)) == 0) { + *s += strlen(m->name); + return m->mask; + } else { + m++; + } + } + return 0; +} + +/* + * get_match - find logmask value + */ +static unsigned long +get_match( + char *s, + struct masks *m + ) +{ + while (m->name) { + if (strcmp(s, m->name) == 0) + return m->mask; + else + m++; + } + return 0; +} + +/* + * get_logmask - build bitmask for ntp_syslogmask + */ +static unsigned long +get_logmask( + char *s + ) +{ + char *t; + unsigned long offset; + unsigned long mask; + + t = s; + offset = get_pfxmatch(&t, logcfg_class); + mask = get_match(t, logcfg_item); + + if (mask) + return mask << offset; + else + msyslog(LOG_ERR, "logconfig: illegal argument %s - ignored", s); + + return 0; +} + + #ifdef HAVE_NETINFO -/* +/* * get_netinfo_config - find the nearest NetInfo domain with an ntp * configuration and initialize the configuration state. */ static struct netinfo_config_state * -get_netinfo_config() +get_netinfo_config(void) { ni_status status; void *domain; ni_id config_dir; - struct netinfo_config_state *config; + struct netinfo_config_state *config; if (ni_open(NULL, ".", &domain) != NI_OK) return NULL; @@ -1942,12 +4113,12 @@ return NULL; } - config = (struct netinfo_config_state *)malloc(sizeof(struct netinfo_config_state)); - config->domain = domain; - config->config_dir = config_dir; - config->prop_index = 0; - config->val_index = 0; - config->val_list = NULL; + config = emalloc(sizeof(*config)); + config->domain = domain; + config->config_dir = config_dir; + config->prop_index = 0; + config->val_index = 0; + config->val_list = NULL; return config; } @@ -1958,7 +4129,9 @@ * free_netinfo_config - release NetInfo configuration state */ static void -free_netinfo_config(struct netinfo_config_state *config) +free_netinfo_config( + struct netinfo_config_state *config + ) { ni_free(config->domain); free(config); @@ -1983,35 +4156,39 @@ /* * Iterate through each keyword and look for a property that matches it. */ - again: + again: if (!val_list) { - for (; prop_index < (sizeof(keywords)/sizeof(keywords[0])); prop_index++) - { - ni_namelist namelist; + for (; prop_index < COUNTOF(keywords); prop_index++) + { + ni_namelist namelist; struct keyword current_prop = keywords[prop_index]; + ni_index index; /* * For each value associated in the property, we're going to return * a separate line. We squirrel away the values in the config state * so the next time through, we don't need to do this lookup. */ - NI_INIT(&namelist); - if (ni_lookupprop(config->domain, &config->config_dir, current_prop.text, &namelist) == NI_OK) { - ni_index index; + NI_INIT(&namelist); + if (NI_OK == ni_lookupprop(config->domain, + &config->config_dir, current_prop.text, + &namelist)) { /* Found the property, but it has no values */ if (namelist.ni_namelist_len == 0) continue; - if (! (val_list = config->val_list = (char**)malloc(sizeof(char*) * (namelist.ni_namelist_len + 1)))) - { msyslog(LOG_ERR, "out of memory while configuring"); break; } - - for (index = 0; index < namelist.ni_namelist_len; index++) { - char *value = namelist.ni_namelist_val[index]; - - if (! (val_list[index] = (char*)malloc(strlen(value)+1))) - { msyslog(LOG_ERR, "out of memory while configuring"); break; } - - strcpy(val_list[index], value); + config->val_list = + emalloc(sizeof(char*) * + (namelist.ni_namelist_len + 1)); + val_list = config->val_list; + + for (index = 0; + index < namelist.ni_namelist_len; + index++) { + char *value; + + value = namelist.ni_namelist_val[index]; + val_list[index] = estrdup(value); } val_list[index] = NULL; @@ -2023,14 +4200,14 @@ } /* No list; we're done here. */ - if (!val_list) return CONFIG_UNKNOWN; + if (!val_list) + return CONFIG_UNKNOWN; /* * We have a list of values for the current property. * Iterate through them and return each in order. */ - if (val_list[val_index]) - { + if (val_list[val_index]) { int ntok = 1; int quoted = 0; char *tokens = val_list[val_index]; @@ -2048,16 +4225,18 @@ break; } else { /* must be space */ *tokens++ = '\0'; - while (ISSPACE(*tokens)) tokens++; - if (ISEOL(*tokens)) break; + while (ISSPACE(*tokens)) + tokens++; + if (ISEOL(*tokens)) + break; } } if (ntok == MAXTOKENS) { /* HMS: chomp it to lose the EOL? */ msyslog(LOG_ERR, - "gettokens_netinfo: too many tokens. Ignoring: %s", - tokens); + "gettokens_netinfo: too many tokens. Ignoring: %s", + tokens); } else { *ntokens = ntok + 1; } @@ -2073,220 +4252,143 @@ /* Free val_list and reset counters. */ for (val_index = 0; val_list[val_index]; val_index++) free(val_list[val_index]); - free(val_list); val_list = config->val_list = NULL; val_index = config->val_index = 0; + free(val_list); + val_list = config->val_list = NULL; + val_index = config->val_index = 0; goto again; } #endif /* HAVE_NETINFO */ - /* - * gettokens - read a line and return tokens + * getnetnum - return a net number (this is crude, but careful) + * + * returns 1 for success, and mysteriously, 0 or -1 for failure */ static int -gettokens ( - FILE *fp, - char *line, - char **tokenlist, - int *ntokens +getnetnum( + const char *num, + sockaddr_u *addr, + int complain, + enum gnn_type a_type ) { - register char *cp; - register int ntok; - register int quoted = 0; - - /* - * Find start of first token - */ - again: - while ((cp = fgets(line, MAXLINE, fp)) != NULL) { - cp = line; - while (ISSPACE(*cp)) - cp++; - if (!ISEOL(*cp)) - break; - } - if (cp == NULL) { - *ntokens = 0; - return CONFIG_UNKNOWN; /* hack. Is recognized as EOF */ - } - - /* - * Now separate out the tokens - */ - for (ntok = 0; ntok < MAXTOKENS; ntok++) { - tokenlist[ntok] = cp; - while (!ISEOL(*cp) && (!ISSPACE(*cp) || quoted)) - quoted ^= (*cp++ == '"'); + int retval; + struct addrinfo *res; - if (ISEOL(*cp)) { - *cp = '\0'; - break; - } else { /* must be space */ - *cp++ = '\0'; - while (ISSPACE(*cp)) - cp++; - if (ISEOL(*cp)) - break; - } - } + /* Get all the addresses that resolve to this name */ + retval = get_multiple_netnums(num, addr, &res, complain, a_type); - /* Heiko: Remove leading and trailing quotes around tokens */ - { - int i,j = 0; - - - for (i = 0; i < ntok; i++) { - /* Now check if the first char is a quote and remove that */ - if ( tokenlist[ntok][0] == '"' ) - tokenlist[ntok]++; - - /* Now check the last char ... */ - j = strlen(tokenlist[ntok])-1; - if ( tokenlist[ntok][j] == '"' ) - tokenlist[ntok][j] = '\0'; - } - - } - - if (ntok == MAXTOKENS) { - --ntok; - /* HMS: chomp it to lose the EOL? */ - msyslog(LOG_ERR, - "gettokens: too many tokens on the line. Ignoring %s", - cp); - } else { - /* - * Return the match - */ - *ntokens = ntok + 1; - ntok = matchkey(tokenlist[0], keywords, 1); - if (ntok == CONFIG_UNKNOWN) - goto again; + if (retval != 1) { + /* Name resolution failed */ + return retval; } - return ntok; -} - + memcpy(addr, res->ai_addr, res->ai_addrlen); + DPRINTF(2, ("getnetnum given %s, got %s\n", num, stoa(addr))); -/* - * matchkey - match a keyword to a list - */ -static int -matchkey( - register char *word, - register struct keyword *keys, - int complain - ) -{ - for (;;) { - if (keys->keytype == CONFIG_UNKNOWN) { - if (complain) - msyslog(LOG_ERR, - "configure: keyword \"%s\" unknown, line ignored", - word); - return CONFIG_UNKNOWN; - } - if (STRSAME(word, keys->text)) - return keys->keytype; - keys++; - } + freeaddrinfo(res); + return 1; } /* - * getnetnum - return a net number (this is crude, but careful) + * get_multiple_netnums + * + * returns 1 for success, and mysteriously, 0 or -1 for failure */ static int -getnetnum( - const char *num, - struct sockaddr_storage *addr, +get_multiple_netnums( + const char *nameornum, + sockaddr_u *addr, + struct addrinfo **res, int complain, enum gnn_type a_type ) { + char lookbuf[1024]; + const char *lookup; + char *pch; struct addrinfo hints; struct addrinfo *ptr; int retval; + isc_netaddr_t ipaddr; -#if 0 - printf("getnetnum: <%s> is a %s (%d)\n", - num, - (a_type == t_UNK) - ? "t_UNK" - : (a_type == t_REF) - ? "t_REF" - : (a_type == t_MSK) - ? "t_MSK" - : "???", - a_type); -#endif - - /* Get host address. Looking for UDP datagram connection */ - memset(&hints, 0, sizeof (hints)); - if (addr->ss_family == AF_INET || addr->ss_family == AF_INET6) - hints.ai_family = addr->ss_family; - else - hints.ai_family = AF_UNSPEC; - /* - * If we don't have an IPv6 stack, just look up IPv4 addresses - */ - if (isc_net_probeipv6() != ISC_R_SUCCESS) - hints.ai_family = AF_INET; + memset(&hints, 0, sizeof(hints)); - hints.ai_socktype = SOCK_DGRAM; + if (strlen(nameornum) >= sizeof(lookbuf)) { + NTP_INSIST(strlen(nameornum) < sizeof(lookbuf)); + return 0; + } - if (a_type != t_UNK) { + lookup = nameornum; + if (is_ip_address(nameornum, &ipaddr)) { hints.ai_flags = AI_NUMERICHOST; + hints.ai_family = ipaddr.family; + if ('[' == nameornum[0]) { + lookup = lookbuf; + strncpy(lookbuf, &nameornum[1], + sizeof(lookbuf)); + pch = strchr(lookbuf, ']'); + if (pch != NULL) + *pch = '\0'; + } + pch = strchr(lookup, '%'); + if (pch != NULL) { + if (lookup != lookbuf) { + lookup = lookbuf; + strncpy(lookbuf, nameornum, + sizeof(lookbuf)); + pch = strchr(lookup, '%'); + } + *pch = '\0'; + } } -#ifdef DEBUG - if (debug > 3) - printf("getnetnum: calling getaddrinfo(%s,...)\n", num); -#endif - retval = getaddrinfo(num, "ntp", &hints, &ptr); - if (retval != 0 || - (ptr->ai_family == AF_INET6 && isc_net_probeipv6() != ISC_R_SUCCESS)) { + if (AF_INET6 == hints.ai_family && !ipv6_works) + return 0; + + if (AF_UNSPEC == hints.ai_family) { + if (!ipv6_works) + hints.ai_family = AF_INET; + else if (!ipv4_works) + hints.ai_family = AF_INET6; + else if (IS_IPV4(addr) || IS_IPV6(addr)) + hints.ai_family = AF(addr); + } + + /* Get host address. Looking for UDP datagram connection */ + hints.ai_socktype = SOCK_DGRAM; + + DPRINTF(4, ("getaddrinfo %s%s\n", + (AF_UNSPEC == hints.ai_family) + ? "" + : (AF_INET == hints.ai_family) + ? "v4 " + : "v6 ", + lookup)); + + retval = getaddrinfo(lookup, "ntp", &hints, &ptr); + + if (retval || (AF_INET6 == ptr->ai_family && !ipv6_works)) { if (complain) msyslog(LOG_ERR, "getaddrinfo: \"%s\" invalid host address, ignored", - num); -#ifdef DEBUG - if (debug > 0) - printf( - "getaddrinfo: \"%s\" invalid host address%s.\n", - num, (complain) - ? ", ignored" - : ""); -#endif - if (retval == 0 && - ptr->ai_family == AF_INET6 && - isc_net_probeipv6() != ISC_R_SUCCESS) - { + lookup); + else + DPRINTF(1, ("getaddrinfo: \"%s\" invalid host address.\n", + lookup)); + + if (!retval) { + freeaddrinfo(ptr); return -1; - } - else { + } else return 0; - } } + *res = ptr; - memcpy(addr, ptr->ai_addr, ptr->ai_addrlen); -#ifdef DEBUG - if (debug > 1) - printf("getnetnum given %s, got %s (%s/%d)\n", - num, stoa(addr), - (a_type == t_UNK) - ? "t_UNK" - : (a_type == t_REF) - ? "t_REF" - : (a_type == t_MSK) - ? "t_MSK" - : "???", - a_type); -#endif - freeaddrinfo(ptr); return 1; } @@ -2318,6 +4420,8 @@ static void save_resolve( char *name, + int no_needed, + int type, int mode, int version, int minpoll, @@ -2331,16 +4435,26 @@ #ifndef SYS_VXWORKS if (res_fp == NULL) { #ifndef SYS_WINNT - (void) strcpy(res_file, RES_TEMPFILE); + strcpy(res_file, RES_TEMPFILE); #else + int len; + /* no /tmp directory under NT */ - { - if(!(GetTempPath((DWORD)MAX_PATH, (LPTSTR)res_file))) { - msyslog(LOG_ERR, "cannot get pathname for temporary directory: %m"); - return; - } - (void) strcat(res_file, "ntpdXXXXXX"); + if (!GetTempPath(sizeof res_file, res_file)) { + msyslog(LOG_ERR, "can not get temp dir: %m"); + exit(1); } + + len = strlen(res_file); + if (sizeof res_file < len + sizeof "ntpdXXXXXX") { + msyslog(LOG_ERR, + "temporary directory path %s too long", + res_file); + exit(1); + } + + memmove(res_file + len, "ntpdXXXXXX", + sizeof "ntpdXXXXXX"); #endif /* SYS_WINNT */ #ifdef HAVE_MKSTEMP { @@ -2351,7 +4465,7 @@ res_fp = fdopen(fd, "r+"); } #else - (void) mktemp(res_file); + mktemp(res_file); res_fp = fopen(res_file, "w"); #endif if (res_fp == NULL) { @@ -2365,12 +4479,15 @@ } #endif - (void)fprintf(res_fp, "%s %d %d %d %d %d %d %u %s\n", name, - mode, version, minpoll, maxpoll, flags, ttl, keyid, keystr); + (void)fprintf(res_fp, "%s %d %d %d %d %d %d %d %d %u %s\n", + name, no_needed, type, + mode, version, minpoll, maxpoll, flags, ttl, keyid, keystr); #ifdef DEBUG if (debug > 1) - printf("config: %s %d %d %d %d %x %d %u %s\n", name, mode, - version, minpoll, maxpoll, flags, ttl, keyid, keystr); + printf("config: %s %d %d %d %d %d %d %x %d %u %s\n", + name, no_needed, type, + mode, version, minpoll, maxpoll, flags, + ttl, keyid, keystr); #endif #else /* SYS_VXWORKS */ @@ -2397,7 +4514,10 @@ #ifndef SYS_VXWORKS /* we don't open the file to begin with */ #if !defined(VMS) - (void) unlink(res_file); + if (unlink(res_file)) + msyslog(LOG_WARNING, + "Unable to remove temporary resolver file %s, %m", + res_file); #else (void) delete(res_file); #endif /* VMS */ @@ -2407,9 +4527,9 @@ /* * do_resolve_internal - start up the resolver function (not program) - */ -/* - * On VMS, this routine will simply refuse to resolve anything. + * + * On VMS, VxWorks, and Unix-like systems lacking fork(), this routine + * will simply refuse to resolve anything. * * Possible implementation: keep `res_file' in memory, do async * name resolution via QIO, update from within completion AST. @@ -2418,7 +4538,9 @@ static void do_resolve_internal(void) { +#ifndef SYS_WINNT int i; +#endif if (res_fp == NULL) { /* belch */ @@ -2431,12 +4553,11 @@ (void) fclose(res_fp); res_fp = NULL; -#if !defined(VMS) && !defined (SYS_VXWORKS) +#ifndef NO_INTRES req_file = res_file; /* set up pointer to res file */ #ifndef SYS_WINNT (void) signal_no_reset(SIGCHLD, catchchild); -#ifndef SYS_VXWORKS /* the parent process will write to the pipe * in order to wake up to child process * which may be waiting in a select() call @@ -2487,36 +4608,19 @@ * THUS: */ - /* This is the child process who will read the pipe, - * so we close the write fd */ - close(resolver_pipe_fd[1]); + /* + msyslog(LOG_INFO, "do_resolve_internal: pre-closelog"); + */ closelog(); kill_asyncio(0); (void) signal_no_reset(SIGCHLD, SIG_DFL); -#ifdef DEBUG - if (0) - debug = 2; -#endif - -# ifndef LOG_DAEMON - openlog("ntpd_initres", LOG_PID); -# else /* LOG_DAEMON */ - -# ifndef LOG_NTP -# define LOG_NTP LOG_DAEMON -# endif - openlog("ntpd_initres", LOG_PID | LOG_NDELAY, LOG_NTP); -#ifndef SYS_CYGWIN32 -# ifdef DEBUG - if (debug) - setlogmask(LOG_UPTO(LOG_DEBUG)); - else -# endif /* DEBUG */ - setlogmask(LOG_UPTO(LOG_DEBUG)); /* @@@ was INFO */ -# endif /* LOG_DAEMON */ -#endif + init_logging("ntpd_intres", 0); + setup_logfile(); + /* + msyslog(LOG_INFO, "do_resolve_internal: post-closelog"); + */ ntp_intres(); @@ -2528,52 +4632,47 @@ abort_resolve(); exit(1); } -#else - /* vxWorks spawns a thread... -casey */ - i = sp (ntp_intres); - /*i = taskSpawn("ntp_intres",100,VX_FP_TASK,20000,ntp_intres);*/ -#endif if (i == -1) { msyslog(LOG_ERR, "fork() failed, can't start ntp_intres: %m"); (void) signal_no_reset(SIGCHLD, SIG_DFL); abort_resolve(); - } - else { + } else /* This is the parent process who will write to the pipe, * so we close the read fd */ close(resolver_pipe_fd[0]); - } #else /* SYS_WINNT */ { /* NT's equivalent of fork() is _spawn(), but the start point * of the new process is an executable filename rather than * a function name as desired here. */ - DWORD dwThreadId; + unsigned thread_id; + uintptr_t res_thd_handle; + fflush(stdout); ResolverEventHandle = CreateEvent(NULL, FALSE, FALSE, NULL); if (ResolverEventHandle == NULL) { msyslog(LOG_ERR, "Unable to create resolver event object, can't start ntp_intres"); abort_resolve(); } - ResolverThreadHandle = CreateThread( - NULL, /* no security attributes */ - 0, /* use default stack size */ - (LPTHREAD_START_ROUTINE) ntp_intres, /* thread function */ - NULL, /* argument to thread function */ - 0, /* use default creation flags */ - &dwThreadId); /* returns the thread identifier */ - if (ResolverThreadHandle == NULL) { - msyslog(LOG_ERR, "CreateThread() failed, can't start ntp_intres"); + res_thd_handle = _beginthreadex( + NULL, /* no security attributes */ + 0, /* use default stack size */ + ntp_intres_thread, /* thread function */ + NULL, /* argument to thread function */ + 0, /* use default creation flags */ + &thread_id); /* receives thread identifier */ + if (!res_thd_handle) { + msyslog(LOG_ERR, "_beginthreadex ntp_intres_thread failed %m"); CloseHandle(ResolverEventHandle); ResolverEventHandle = NULL; abort_resolve(); } } #endif /* SYS_WINNT */ -#else /* VMS VX_WORKS */ +#else /* NO_INTRES follows */ msyslog(LOG_ERR, - "Name resolution not implemented for VMS - use numeric addresses"); + "Deferred DNS not implemented - use numeric addresses"); abort_resolve(); -#endif /* VMS VX_WORKS */ +#endif } diff -urN src/contrib/ntp/ntpd/ntp_control.c src.ntp/contrib/ntp/ntpd/ntp_control.c --- src/contrib/ntp/ntpd/ntp_control.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/ntp_control.c 2010-02-16 12:17:59.000000000 +0100 @@ -2,12 +2,8 @@ * ntp_control.c - respond to control messages and send async traps */ -/* - * $FreeBSD: src/contrib/ntp/ntpd/ntp_control.c,v 1.10 2008/08/22 15:58:00 roberto Exp $ - */ - #ifdef HAVE_CONFIG_H -#include +# include #endif #include "ntpd.h" @@ -16,73 +12,75 @@ #include "ntp_control.h" #include "ntp_unixtime.h" #include "ntp_stdlib.h" +#include "ntp_config.h" +#include "ntp_crypto.h" +#include "ntp_assert.h" #include #include #include +#include +#ifdef HAVE_NETINET_IN_H #include +#endif #include /* * Structure to hold request procedure information */ -#define NOAUTH 0 -#define AUTH 1 - -#define NO_REQUEST (-1) struct ctl_proc { short control_code; /* defined request code */ +#define NO_REQUEST (-1) u_short flags; /* flags word */ - void (*handler) P((struct recvbuf *, int)); /* handle request */ -}; - -/* - * Only one flag. Authentication required or not. - */ + /* Only one flag. Authentication required or not. */ #define NOAUTH 0 #define AUTH 1 + void (*handler) (struct recvbuf *, int); /* handle request */ +}; + /* * Request processing routines */ -static void ctl_error P((int)); +static void ctl_error (int); #ifdef REFCLOCK -static u_short ctlclkstatus P((struct refclockstat *)); -#endif -static void ctl_flushpkt P((int)); -static void ctl_putdata P((const char *, unsigned int, int)); -static void ctl_putstr P((const char *, const char *, - unsigned int)); -static void ctl_putdbl P((const char *, double)); -static void ctl_putuint P((const char *, u_long)); -static void ctl_puthex P((const char *, u_long)); -static void ctl_putint P((const char *, long)); -static void ctl_putts P((const char *, l_fp *)); -static void ctl_putadr P((const char *, u_int32, struct sockaddr_storage*)); -static void ctl_putid P((const char *, char *)); -static void ctl_putarray P((const char *, double *, int)); -static void ctl_putsys P((int)); -static void ctl_putpeer P((int, struct peer *)); -#ifdef OPENSSL -static void ctl_putfs P((const char *, tstamp_t)); +static u_short ctlclkstatus (struct refclockstat *); #endif +static void ctl_flushpkt (int); +static void ctl_putdata (const char *, unsigned int, int); +static void ctl_putstr (const char *, const char *, + unsigned int); +static void ctl_putdbl (const char *, double); +static void ctl_putuint (const char *, u_long); +static void ctl_puthex (const char *, u_long); +static void ctl_putint (const char *, long); +static void ctl_putts (const char *, l_fp *); +static void ctl_putadr (const char *, u_int32, + sockaddr_u *); +static void ctl_putid (const char *, char *); +static void ctl_putarray (const char *, double *, int); +static void ctl_putsys (int); +static void ctl_putpeer (int, struct peer *); +static void ctl_putfs (const char *, tstamp_t); #ifdef REFCLOCK -static void ctl_putclock P((int, struct refclockstat *, int)); +static void ctl_putclock (int, struct refclockstat *, int); #endif /* REFCLOCK */ -static struct ctl_var *ctl_getitem P((struct ctl_var *, char **)); -static u_long count_var P((struct ctl_var *)); -static void control_unspec P((struct recvbuf *, int)); -static void read_status P((struct recvbuf *, int)); -static void read_variables P((struct recvbuf *, int)); -static void write_variables P((struct recvbuf *, int)); -static void read_clock_status P((struct recvbuf *, int)); -static void write_clock_status P((struct recvbuf *, int)); -static void set_trap P((struct recvbuf *, int)); -static void unset_trap P((struct recvbuf *, int)); -static struct ctl_trap *ctlfindtrap P((struct sockaddr_storage *, - struct interface *)); +static struct ctl_var *ctl_getitem (struct ctl_var *, char **); +static u_long count_var (struct ctl_var *); +static void control_unspec (struct recvbuf *, int); +static void read_status (struct recvbuf *, int); +static void read_variables (struct recvbuf *, int); +static void write_variables (struct recvbuf *, int); +static void read_clock_status (struct recvbuf *, int); +static void write_clock_status (struct recvbuf *, int); +static void set_trap (struct recvbuf *, int); +static void unset_trap (struct recvbuf *, int); +static void configure (struct recvbuf *, int); +static void save_config (struct recvbuf *, int); +static struct ctl_trap *ctlfindtrap (sockaddr_u *, + struct interface *); static struct ctl_proc control_codes[] = { { CTL_OP_UNSPEC, NOAUTH, control_unspec }, @@ -93,6 +91,8 @@ { CTL_OP_WRITECLOCK, NOAUTH, write_clock_status }, { CTL_OP_SETTRAP, NOAUTH, set_trap }, { CTL_OP_UNSETTRAP, NOAUTH, unset_trap }, + { CTL_OP_SAVECONFIG, AUTH, save_config }, + { CTL_OP_CONFIGURE, AUTH, configure }, { NO_REQUEST, 0 } }; @@ -106,35 +106,36 @@ { CS_STRATUM, RO, "stratum" }, /* 2 */ { CS_PRECISION, RO, "precision" }, /* 3 */ { CS_ROOTDELAY, RO, "rootdelay" }, /* 4 */ - { CS_ROOTDISPERSION, RO, "rootdispersion" }, /* 5 */ + { CS_ROOTDISPERSION, RO, "rootdisp" }, /* 5 */ { CS_REFID, RO, "refid" }, /* 6 */ { CS_REFTIME, RO, "reftime" }, /* 7 */ - { CS_POLL, RO, "poll" }, /* 8 */ + { CS_POLL, RO, "tc" }, /* 8 */ { CS_PEERID, RO, "peer" }, /* 9 */ - { CS_STATE, RO, "state" }, /* 10 */ - { CS_OFFSET, RO, "offset" }, /* 11 */ - { CS_DRIFT, RO, "frequency" }, /* 12 */ - { CS_JITTER, RO, "jitter" }, /* 13 */ - { CS_ERROR, RO, "noise" }, /* 14 */ - { CS_CLOCK, RO, "clock" }, /* 15 */ - { CS_PROCESSOR, RO, "processor" }, /* 16 */ - { CS_SYSTEM, RO, "system" }, /* 17 */ - { CS_VERSION, RO, "version" }, /* 18 */ - { CS_STABIL, RO, "stability" }, /* 19 */ - { CS_VARLIST, RO, "sys_var_list" }, /* 20 */ + { CS_OFFSET, RO, "offset" }, /* 10 */ + { CS_DRIFT, RO, "frequency" }, /* 11 */ + { CS_JITTER, RO, "sys_jitter" }, /* 12 */ + { CS_ERROR, RO, "clk_jitter" }, /* 13 */ + { CS_CLOCK, RO, "clock" }, /* 14 */ + { CS_PROCESSOR, RO, "processor" }, /* 15 */ + { CS_SYSTEM, RO, "system" }, /* 16 */ + { CS_VERSION, RO, "version" }, /* 17 */ + { CS_STABIL, RO, "clk_wander" }, /* 18 */ + { CS_VARLIST, RO, "sys_var_list" }, /* 19 */ + { CS_TAI, RO, "tai" }, /* 20 */ + { CS_LEAPTAB, RO, "leapsec" }, /* 21 */ + { CS_LEAPEND, RO, "expire" }, /* 22 */ + { CS_RATE, RO, "mintc" }, /* 23 */ #ifdef OPENSSL - { CS_FLAGS, RO, "flags" }, /* 21 */ - { CS_HOST, RO, "hostname" }, /* 22 */ - { CS_PUBLIC, RO, "update" }, /* 23 */ - { CS_CERTIF, RO, "cert" }, /* 24 */ - { CS_REVTIME, RO, "expire" }, /* 25 */ - { CS_LEAPTAB, RO, "leapsec" }, /* 26 */ - { CS_TAI, RO, "tai" }, /* 27 */ - { CS_DIGEST, RO, "signature" }, /* 28 */ - { CS_IDENT, RO, "ident" }, /* 29 */ - { CS_REVOKE, RO, "expire" }, /* 30 */ + { CS_FLAGS, RO, "flags" }, /* 24 */ + { CS_HOST, RO, "host" }, /* 25 */ + { CS_PUBLIC, RO, "update" }, /* 26 */ + { CS_CERTIF, RO, "cert" }, /* 27 */ + { CS_SIGNATURE, RO, "signature" }, /* 28 */ + { CS_REVTIME, RO, "until" }, /* 29 */ + { CS_GROUP, RO, "group" }, /* 30 */ + { CS_DIGEST, RO, "digest" }, /* 31 */ #endif /* OPENSSL */ - { 0, EOV, "" } /* 21/31 */ + { 0, EOV, "" } /* 24/3 2*/ }; static struct ctl_var *ext_sys_var = (struct ctl_var *)0; @@ -152,25 +153,27 @@ CS_PRECISION, CS_ROOTDELAY, CS_ROOTDISPERSION, - CS_PEERID, CS_REFID, CS_REFTIME, - CS_POLL, CS_CLOCK, - CS_STATE, + CS_PEERID, + CS_POLL, + CS_RATE, CS_OFFSET, CS_DRIFT, CS_JITTER, CS_ERROR, CS_STABIL, + CS_TAI, + CS_LEAPTAB, + CS_LEAPEND, #ifdef OPENSSL CS_HOST, - CS_DIGEST, + CS_GROUP, CS_FLAGS, + CS_DIGEST, + CS_SIGNATURE, CS_PUBLIC, - CS_IDENT, - CS_LEAPTAB, - CS_TAI, CS_CERTIF, #endif /* OPENSSL */ 0 @@ -196,12 +199,12 @@ { CP_HPOLL, RO, "hpoll" }, /* 12 */ { CP_PRECISION, RO, "precision" }, /* 13 */ { CP_ROOTDELAY, RO, "rootdelay" }, /* 14 */ - { CP_ROOTDISPERSION, RO, "rootdispersion" }, /* 15 */ + { CP_ROOTDISPERSION, RO, "rootdisp" }, /* 15 */ { CP_REFID, RO, "refid" }, /* 16 */ { CP_REFTIME, RO, "reftime" }, /* 17 */ { CP_ORG, RO, "org" }, /* 18 */ { CP_REC, RO, "rec" }, /* 19 */ - { CP_XMT, RO, "xmt" }, /* 20 */ + { CP_XMT, RO, "xleave" }, /* 20 */ { CP_REACH, RO, "reach" }, /* 21 */ { CP_UNREACH, RO, "unreach" }, /* 22 */ { CP_TIMER, RO, "timer" }, /* 23 */ @@ -219,17 +222,20 @@ { CP_FLASH, RO, "flash" }, /* 35 */ { CP_TTL, RO, "ttl" }, /* 36 */ { CP_VARLIST, RO, "peer_var_list" }, /* 37 */ + { CP_IN, RO, "in" }, /* 38 */ + { CP_OUT, RO, "out" }, /* 39 */ + { CP_RATE, RO, "headway" }, /* 40 */ + { CP_BIAS, RO, "bias" }, /* 41 */ #ifdef OPENSSL - { CP_FLAGS, RO, "flags" }, /* 38 */ - { CP_HOST, RO, "hostname" }, /* 39 */ - { CP_VALID, RO, "valid" }, /* 40 */ - { CP_INITSEQ, RO, "initsequence" }, /* 41 */ - { CP_INITKEY, RO, "initkey" }, /* 42 */ - { CP_INITTSP, RO, "timestamp" }, /* 43 */ - { CP_DIGEST, RO, "signature" }, /* 44 */ - { CP_IDENT, RO, "trust" }, /* 45 */ + { CP_FLAGS, RO, "flags" }, /* 42 */ + { CP_HOST, RO, "host" }, /* 43 */ + { CP_VALID, RO, "valid" }, /* 44 */ + { CP_INITSEQ, RO, "initsequence" }, /* 45 */ + { CP_INITKEY, RO, "initkey" }, /* 46 */ + { CP_INITTSP, RO, "timestamp" }, /* 47 */ + { CP_SIGNATURE, RO, "signature" }, /* 48 */ #endif /* OPENSSL */ - { 0, EOV, "" } /* 38/46 */ + { 0, EOV, "" } /* 42/49 */ }; @@ -241,18 +247,23 @@ CP_SRCPORT, CP_DSTADR, CP_DSTPORT, + CP_OUT, + CP_IN, CP_LEAP, CP_STRATUM, CP_PRECISION, CP_ROOTDELAY, CP_ROOTDISPERSION, CP_REFID, + CP_REFTIME, + CP_REC, CP_REACH, CP_UNREACH, CP_HMODE, CP_PMODE, CP_HPOLL, CP_PPOLL, + CP_RATE, CP_FLASH, CP_KEYID, CP_TTL, @@ -260,19 +271,16 @@ CP_DELAY, CP_DISPERSION, CP_JITTER, - CP_REFTIME, - CP_ORG, - CP_REC, CP_XMT, + CP_BIAS, CP_FILTDELAY, CP_FILTOFFSET, CP_FILTERROR, #ifdef OPENSSL CP_HOST, - CP_DIGEST, - CP_VALID, CP_FLAGS, - CP_IDENT, + CP_SIGNATURE, + CP_VALID, CP_INITSEQ, #endif /* OPENSSL */ 0 @@ -331,7 +339,7 @@ # define STR_SYSTEM "UNIX" # endif # ifndef STR_PROCESSOR -# define STR_PROCESSOR "unknown" +# define STR_PROCESSOR "unknown" # endif static char str_system[] = STR_SYSTEM; @@ -393,8 +401,8 @@ CTL_SST_TS_NTP, /* not used (24) */ CTL_SST_TS_NTP, /* not used (25) */ CTL_SST_TS_UHF, /* REFCLK_GPS_HP (26) */ - CTL_SST_TS_TELEPHONE, /* REFCLK_ARCRON_MSF (27) */ - CTL_SST_TS_TELEPHONE, /* REFCLK_SHM (28) */ + CTL_SST_TS_LF, /* REFCLK_ARCRON_MSF (27) */ + CTL_SST_TS_UHF, /* REFCLK_SHM (28) */ CTL_SST_TS_UHF, /* REFCLK_PALISADE (29) */ CTL_SST_TS_UHF, /* REFCLK_ONCORE (30) */ CTL_SST_TS_UHF, /* REFCLK_JUPITER (31) */ @@ -402,7 +410,7 @@ CTL_SST_TS_LF, /* REFCLK_DUMBCLOCK (33) */ CTL_SST_TS_LF, /* REFCLK_ULINK (34) */ CTL_SST_TS_LF, /* REFCLK_PCF (35) */ - CTL_SST_TS_LF, /* REFCLK_WWV (36) */ + CTL_SST_TS_HF, /* REFCLK_WWV (36) */ CTL_SST_TS_LF, /* REFCLK_FG (37) */ CTL_SST_TS_UHF, /* REFCLK_HOPF_SERIAL (38) */ CTL_SST_TS_UHF, /* REFCLK_HOPF_PCI (39) */ @@ -461,7 +469,7 @@ static u_char * dataend; static int datalinelen; static int datanotbinflag; -static struct sockaddr_storage *rmt_addr; +static sockaddr_u *rmt_addr; static struct interface *lcl_inter; static u_char res_authenticate; @@ -510,16 +518,14 @@ int errcode ) { -#ifdef DEBUG - if (debug >= 4) - printf("sending control error %d\n", errcode); -#endif + DPRINTF(3, ("sending control error %d\n", errcode)); + /* * Fill in the fields. We assume rpkt.sequence and rpkt.associd * have already been filled in. */ rpkt.r_m_e_op = (u_char) (CTL_RESPONSE|CTL_ERROR|(res_opcode & - CTL_OP_MASK)); + CTL_OP_MASK)); rpkt.status = htons((u_short) ((errcode<<8) & 0xff00)); rpkt.count = 0; @@ -532,16 +538,136 @@ *(u_int32 *)((u_char *)&rpkt + CTL_HEADER_LEN) = htonl(res_keyid); maclen = authencrypt(res_keyid, (u_int32 *)&rpkt, - CTL_HEADER_LEN); + CTL_HEADER_LEN); sendpkt(rmt_addr, lcl_inter, -2, (struct pkt *)&rpkt, - CTL_HEADER_LEN + maclen); + CTL_HEADER_LEN + maclen); } else { sendpkt(rmt_addr, lcl_inter, -3, (struct pkt *)&rpkt, - CTL_HEADER_LEN); + CTL_HEADER_LEN); } numctlerrors++; } +/* + * save_config - Implements ntpq -c "saveconfig " + * Writes current configuration including any runtime + * changes by ntpq's :config or config-from-file + */ +void +save_config( + struct recvbuf *rbufp, + int restrict_mask + ) +{ + char reply[128]; +#ifdef SAVECONFIG + char filespec[128]; + char filename[128]; + char fullpath[512]; + const char savedconfig_eq[] = "savedconfig="; + char savedconfig[sizeof(savedconfig_eq) + sizeof(filename)]; + time_t now; + int fd; + FILE *fptr; +#endif + + if (restrict_mask & RES_NOMODIFY) { + snprintf(reply, sizeof(reply), + "saveconfig prohibited by restrict ... nomodify"); + ctl_putdata(reply, strlen(reply), 0); + ctl_flushpkt(0); + msyslog(LOG_NOTICE, + "saveconfig from %s rejected due to nomodify restriction", + stoa(&rbufp->recv_srcadr)); + return; + } + +#ifdef SAVECONFIG + if (NULL == saveconfigdir) { + snprintf(reply, sizeof(reply), + "saveconfig prohibited, no saveconfigdir configured"); + ctl_putdata(reply, strlen(reply), 0); + ctl_flushpkt(0); + msyslog(LOG_NOTICE, + "saveconfig from %s rejected, no saveconfigdir", + stoa(&rbufp->recv_srcadr)); + return; + } + + if (0 == reqend - reqpt) + return; + + strncpy(filespec, reqpt, sizeof(filespec)); + filespec[sizeof(filespec) - 1] = '\0'; + + time(&now); + + /* + * allow timestamping of the saved config filename with + * strftime() format such as: + * ntpq -c "saveconfig ntp-%Y%m%d-%H%M%S.conf" + */ + if (0 == strftime(filename, sizeof(filename), filespec, + localtime(&now))) + strncpy(filename, filespec, sizeof(filename)); + + filename[sizeof(filename) - 1] = '\0'; + + if (strchr(filename, '\\') || strchr(filename, '/')) { + snprintf(reply, sizeof(reply), + "saveconfig does not allow directory in filename"); + ctl_putdata(reply, strlen(reply), 0); + ctl_flushpkt(0); + msyslog(LOG_NOTICE, + "saveconfig with path from %s rejected", + stoa(&rbufp->recv_srcadr)); + return; + } + + snprintf(fullpath, sizeof(fullpath), "%s%s", + saveconfigdir, filename); + + fd = open(fullpath, O_CREAT | O_TRUNC | O_WRONLY, + S_IRUSR | S_IWUSR); + if (-1 == fd) + fptr = NULL; + else + fptr = fdopen(fd, "w"); + + if (NULL == fptr || -1 == dump_all_config_trees(fptr, 1)) { + snprintf(reply, sizeof(reply), + "Unable to save configuration to file %s", + filename); + msyslog(LOG_ERR, + "saveconfig %s from %s failed", filename, + stoa(&rbufp->recv_srcadr)); + } else { + snprintf(reply, sizeof(reply), + "Configuration saved to %s", filename); + msyslog(LOG_NOTICE, + "Configuration saved to %s (requested by %s)", + fullpath, stoa(&rbufp->recv_srcadr)); + /* + * save the output filename in system variable + * savedconfig, retrieved with: + * ntpq -c "rv 0 savedconfig" + */ + snprintf(savedconfig, sizeof(savedconfig), "%s%s", + savedconfig_eq, filename); + set_sys_var(savedconfig, strlen(savedconfig) + 1, RO); + } + + if (NULL != fptr) + fclose(fptr); +#else /* !SAVECONFIG follows */ + snprintf(reply, sizeof(reply), + "saveconfig unavailable, configured with --disable-saveconfig"); +#endif + + ctl_putdata(reply, strlen(reply), 0); + ctl_flushpkt(0); +} + /* * process_control - process an incoming control message @@ -559,10 +685,7 @@ int properlen; int maclen; -#ifdef DEBUG - if (debug > 2) - printf("in process_control()\n"); -#endif + DPRINTF(3, ("in process_control()\n")); /* * Save the addresses for error responses @@ -579,10 +702,7 @@ if (rbufp->recv_length < CTL_HEADER_LEN || pkt->r_m_e_op & (CTL_RESPONSE|CTL_MORE|CTL_ERROR) || pkt->offset != 0) { -#ifdef DEBUG - if (debug) - printf("invalid format in control packet\n"); -#endif + DPRINTF(1, ("invalid format in control packet\n")); if (rbufp->recv_length < CTL_HEADER_LEN) numctltooshort++; if (pkt->r_m_e_op & CTL_RESPONSE) @@ -597,11 +717,8 @@ } res_version = PKT_VERSION(pkt->li_vn_mode); if (res_version > NTP_VERSION || res_version < NTP_OLDVERSION) { -#ifdef DEBUG - if (debug) - printf("unknown version %d in control packet\n", - res_version); -#endif + DPRINTF(1, ("unknown version %d in control packet\n", + res_version)); numctlbadversion++; return; } @@ -611,7 +728,7 @@ * responses */ rpkt.li_vn_mode = PKT_LI_VN_MODE(sys_leap, res_version, - MODE_CONTROL); + MODE_CONTROL); res_opcode = pkt->r_m_e_op; rpkt.sequence = pkt->sequence; rpkt.associd = pkt->associd; @@ -622,12 +739,16 @@ res_authenticate = 0; res_keyid = 0; res_authokay = 0; - req_count = (int)htons(pkt->count); + req_count = (int)ntohs(pkt->count); datanotbinflag = 0; datalinelen = 0; datapt = rpkt.data; dataend = &(rpkt.data[CTL_MAX_DATA_LEN]); + if ((rbufp->recv_length & 0x3) != 0) + DPRINTF(3, ("Control packet length %d unrounded\n", + rbufp->recv_length)); + /* * We're set up now. Make sure we've got at least enough * incoming data space to match the count. @@ -640,46 +761,30 @@ } properlen = req_count + CTL_HEADER_LEN; -#ifdef DEBUG - if (debug > 2 && (rbufp->recv_length & 0x3) != 0) - printf("Packet length %d unrounded\n", - rbufp->recv_length); -#endif /* round up proper len to a 8 octet boundary */ properlen = (properlen + 7) & ~7; maclen = rbufp->recv_length - properlen; - if ((rbufp->recv_length & (sizeof(u_long) - 1)) == 0 && + if ((rbufp->recv_length & 3) == 0 && maclen >= MIN_MAC_LEN && maclen <= MAX_MAC_LEN && sys_authenticate) { res_authenticate = 1; res_keyid = ntohl(*(u_int32 *)((u_char *)pkt + - properlen)); + properlen)); -#ifdef DEBUG - if (debug > 2) - printf( - "recv_len %d, properlen %d, wants auth with keyid %08x, MAC length=%d\n", - rbufp->recv_length, properlen, res_keyid, maclen); -#endif - if (!authistrusted(res_keyid)) { -#ifdef DEBUG - if (debug > 2) - printf("invalid keyid %08x\n", - res_keyid); -#endif - } else if (authdecrypt(res_keyid, (u_int32 *)pkt, - rbufp->recv_length - maclen, maclen)) { -#ifdef DEBUG - if (debug > 2) - printf("authenticated okay\n"); -#endif + DPRINTF(3, ("recv_len %d, properlen %d, wants auth with keyid %08x, MAC length=%d\n", + rbufp->recv_length, properlen, res_keyid, + maclen)); + + if (!authistrusted(res_keyid)) + DPRINTF(3, ("invalid keyid %08x\n", res_keyid)); + else if (authdecrypt(res_keyid, (u_int32 *)pkt, + rbufp->recv_length - maclen, + maclen)) { + DPRINTF(3, ("authenticated okay\n")); res_authokay = 1; } else { -#ifdef DEBUG - if (debug > 2) - printf("authentication failed\n"); -#endif + DPRINTF(3, ("authentication failed\n")); res_keyid = 0; } } @@ -695,13 +800,11 @@ */ for (cc = control_codes; cc->control_code != NO_REQUEST; cc++) { if (cc->control_code == res_opcode) { -#ifdef DEBUG - if (debug > 2) - printf("opcode %d, found command handler\n", - res_opcode); -#endif - if (cc->flags == AUTH && (!res_authokay || - res_keyid != ctl_auth_keyid)) { + DPRINTF(3, ("opcode %d, found command handler\n", + res_opcode)); + if (cc->flags == AUTH + && (!res_authokay + || res_keyid != ctl_auth_keyid)) { ctl_error(CERR_PERMISSION); return; } @@ -727,17 +830,19 @@ register struct peer *peer ) { - register u_short status; + u_short status; status = peer->status; - if (peer->flags & FLAG_CONFIG) + if (!(peer->flags & FLAG_PREEMPT)) status |= CTL_PST_CONFIG; - if (peer->flags & FLAG_AUTHENABLE) + if (peer->keyid != 0) status |= CTL_PST_AUTHENABLE; if (peer->flags & FLAG_AUTHENTIC) status |= CTL_PST_AUTHENTIC; if (peer->reach != 0) status |= CTL_PST_REACH; + if (peer->cast_flags & (MDF_BCAST | MDF_MCAST | MDF_ACAST)) + status |= CTL_PST_BCAST; return (u_short)CTL_PEER_STATUS(status, peer->num_events, peer->last_event); } @@ -752,8 +857,8 @@ struct refclockstat *this_clock ) { - return ((u_short)(((this_clock->currentstatus) << 8) | - (this_clock->lastevent))); + return (u_short)CTL_PEER_STATUS(0, this_clock->lastevent, + this_clock->currentstatus); } #endif @@ -771,16 +876,15 @@ if (sys_peer != 0) { if (sys_peer->sstclktype != CTL_SST_TS_UNSPEC) { this_clock = sys_peer->sstclktype; - if (pps_control) - this_clock |= CTL_SST_TS_PPS; } else { if (sys_peer->refclktype < sizeof(clocktypes)) this_clock = clocktypes[sys_peer->refclktype]; - if (pps_control) - this_clock |= CTL_SST_TS_PPS; } } +#else /* REFCLOCK */ + if (sys_peer != 0) + this_clock = CTL_SST_TS_NTP; #endif /* REFCLOCK */ return (u_short)CTL_SYS_STATUS(sys_leap, this_clock, ctl_sys_num_events, ctl_sys_last_event); @@ -821,7 +925,7 @@ * Fill in the packet with the current info */ rpkt.r_m_e_op = (u_char)(CTL_RESPONSE|more|(res_opcode & - CTL_OP_MASK)); + CTL_OP_MASK)); rpkt.count = htons((u_short) dlen); rpkt.offset = htons( (u_short) res_offset); if (res_async) { @@ -831,8 +935,8 @@ if (ctl_trap[i].tr_flags & TRAP_INUSE) { rpkt.li_vn_mode = PKT_LI_VN_MODE(sys_leap, - ctl_trap[i].tr_version, - MODE_CONTROL); + ctl_trap[i].tr_version, + MODE_CONTROL); rpkt.sequence = htons(ctl_trap[i].tr_sequence); sendpkt(&ctl_trap[i].tr_addr, @@ -860,12 +964,12 @@ } memcpy(datapt, &keyid, sizeof keyid); maclen = authencrypt(res_keyid, - (u_int32 *)&rpkt, totlen); + (u_int32 *)&rpkt, totlen); sendpkt(rmt_addr, lcl_inter, -5, - (struct pkt *)&rpkt, totlen + maclen); + (struct pkt *)&rpkt, totlen + maclen); } else { sendpkt(rmt_addr, lcl_inter, -6, - (struct pkt *)&rpkt, sendlen); + (struct pkt *)&rpkt, sendlen); } if (more) numctlfrags++; @@ -902,7 +1006,7 @@ *datapt++ = ','; datalinelen++; if ((dlen + datalinelen + 1) >= MAXDATALINELEN) - { + { *datapt++ = '\r'; *datapt++ = '\n'; datalinelen = 0; @@ -977,10 +1081,10 @@ while (*cq != '\0') *cp++ = *cq++; *cp++ = '='; - (void)sprintf(cp, "%.3f", ts); - while (*cp != '\0') - cp++; - ctl_putdata(buffer, (unsigned)( cp - buffer ), 0); + NTP_INSIST((cp - buffer) < sizeof(buffer)); + snprintf(cp, sizeof(buffer) - (cp - buffer), "%.3f", ts); + cp += strlen(cp); + ctl_putdata(buffer, (unsigned)(cp - buffer), 0); } /* @@ -1002,16 +1106,15 @@ *cp++ = *cq++; *cp++ = '='; - (void) sprintf(cp, "%lu", uval); - while (*cp != '\0') - cp++; + NTP_INSIST((cp - buffer) < sizeof(buffer)); + snprintf(cp, sizeof(buffer) - (cp - buffer), "%lu", uval); + cp += strlen(cp); ctl_putdata(buffer, (unsigned)( cp - buffer ), 0); } /* * ctl_putfs - write a decoded filestamp into the response */ -#ifdef OPENSSL static void ctl_putfs( const char *tag, @@ -1032,20 +1135,20 @@ *cp++ = '='; fstamp = uval - JAN_1970; tm = gmtime(&fstamp); - if (tm == NULL) + if (NULL == tm) return; - - sprintf(cp, "%04d%02d%02d%02d%02d", tm->tm_year + 1900, - tm->tm_mon + 1, tm->tm_mday, tm->tm_hour, tm->tm_min); - while (*cp != '\0') - cp++; + NTP_INSIST((cp - buffer) < sizeof(buffer)); + snprintf(cp, sizeof(buffer) - (cp - buffer), + "%04d%02d%02d%02d%02d", tm->tm_year + 1900, + tm->tm_mon + 1, tm->tm_mday, tm->tm_hour, tm->tm_min); + cp += strlen(cp); ctl_putdata(buffer, (unsigned)( cp - buffer ), 0); } -#endif /* - * ctl_puthex - write a tagged unsigned integer, in hex, into the response + * ctl_puthex - write a tagged unsigned integer, in hex, into the + * response */ static void ctl_puthex( @@ -1063,9 +1166,9 @@ *cp++ = *cq++; *cp++ = '='; - (void) sprintf(cp, "0x%lx", uval); - while (*cp != '\0') - cp++; + NTP_INSIST((cp - buffer) < sizeof(buffer)); + snprintf(cp, sizeof(buffer) - (cp - buffer), "0x%lx", uval); + cp += strlen(cp); ctl_putdata(buffer,(unsigned)( cp - buffer ), 0); } @@ -1089,9 +1192,9 @@ *cp++ = *cq++; *cp++ = '='; - (void) sprintf(cp, "%ld", ival); - while (*cp != '\0') - cp++; + NTP_INSIST((cp - buffer) < sizeof(buffer)); + snprintf(cp, sizeof(buffer) - (cp - buffer), "%ld", ival); + cp += strlen(cp); ctl_putdata(buffer, (unsigned)( cp - buffer ), 0); } @@ -1115,11 +1218,10 @@ *cp++ = *cq++; *cp++ = '='; - (void) sprintf(cp, "0x%08lx.%08lx", - ts->l_ui & ULONG_CONST(0xffffffff), - ts->l_uf & ULONG_CONST(0xffffffff)); - while (*cp != '\0') - cp++; + NTP_INSIST((cp - buffer) < sizeof(buffer)); + snprintf(cp, sizeof(buffer) - (cp - buffer), "0x%08lx.%08lx", + ts->l_ui & 0xffffffffUL, ts->l_uf & 0xffffffffUL); + cp += strlen(cp); ctl_putdata(buffer, (unsigned)( cp - buffer ), 0); } @@ -1131,7 +1233,7 @@ ctl_putadr( const char *tag, u_int32 addr32, - struct sockaddr_storage* addr + sockaddr_u *addr ) { register char *cp; @@ -1144,13 +1246,14 @@ *cp++ = *cq++; *cp++ = '='; - if (addr == NULL) + if (NULL == addr) cq = numtoa(addr32); else cq = stoa(addr); - while (*cq != '\0') - *cp++ = *cq++; - ctl_putdata(buffer, (unsigned)( cp - buffer ), 0); + NTP_INSIST((cp - buffer) < sizeof(buffer)); + snprintf(cp, sizeof(buffer) - (cp - buffer), "%s", cq); + cp += strlen(cp); + ctl_putdata(buffer, (unsigned)(cp - buffer), 0); } /* @@ -1172,9 +1275,9 @@ *cp++ = *cq++; *cp++ = '='; - cq = id; - while (*cq != '\0' && (cq - id) < 4) - *cp++ = *cq++; + NTP_INSIST((cp - buffer) < sizeof(buffer)); + snprintf(cp, sizeof(buffer) - (cp - buffer), "%.4s", id); + cp += strlen(cp); ctl_putdata(buffer, (unsigned)( cp - buffer ), 0); } @@ -1202,9 +1305,10 @@ if (i == 0) i = NTP_SHIFT; i--; - (void)sprintf(cp, " %.2f", arr[i] * 1e3); - while (*cp != '\0') - cp++; + NTP_INSIST((cp - buffer) < sizeof(buffer)); + snprintf(cp, sizeof(buffer) - (cp - buffer), + " %.2f", arr[i] * 1e3); + cp += strlen(cp); } while(i != start); ctl_putdata(buffer, (unsigned)(cp - buffer), 0); } @@ -1227,237 +1331,240 @@ switch (varid) { - case CS_LEAP: + case CS_LEAP: ctl_putuint(sys_var[CS_LEAP].text, sys_leap); break; - case CS_STRATUM: + case CS_STRATUM: ctl_putuint(sys_var[CS_STRATUM].text, sys_stratum); break; - case CS_PRECISION: + case CS_PRECISION: ctl_putint(sys_var[CS_PRECISION].text, sys_precision); break; - case CS_ROOTDELAY: + case CS_ROOTDELAY: ctl_putdbl(sys_var[CS_ROOTDELAY].text, sys_rootdelay * - 1e3); + 1e3); break; - case CS_ROOTDISPERSION: + case CS_ROOTDISPERSION: ctl_putdbl(sys_var[CS_ROOTDISPERSION].text, - sys_rootdispersion * 1e3); + sys_rootdisp * 1e3); break; - case CS_REFID: + case CS_REFID: if (sys_stratum > 1 && sys_stratum < STRATUM_UNSPEC) ctl_putadr(sys_var[CS_REFID].text, sys_refid, NULL); else ctl_putid(sys_var[CS_REFID].text, - (char *)&sys_refid); + (char *)&sys_refid); break; - case CS_REFTIME: + case CS_REFTIME: ctl_putts(sys_var[CS_REFTIME].text, &sys_reftime); break; - case CS_POLL: + case CS_POLL: ctl_putuint(sys_var[CS_POLL].text, sys_poll); break; - case CS_PEERID: + case CS_PEERID: if (sys_peer == NULL) ctl_putuint(sys_var[CS_PEERID].text, 0); else ctl_putuint(sys_var[CS_PEERID].text, - sys_peer->associd); + sys_peer->associd); break; - case CS_STATE: - ctl_putuint(sys_var[CS_STATE].text, (unsigned)state); - break; - - case CS_OFFSET: + case CS_OFFSET: ctl_putdbl(sys_var[CS_OFFSET].text, last_offset * 1e3); break; - case CS_DRIFT: + case CS_DRIFT: ctl_putdbl(sys_var[CS_DRIFT].text, drift_comp * 1e6); break; - case CS_JITTER: + case CS_JITTER: ctl_putdbl(sys_var[CS_JITTER].text, sys_jitter * 1e3); break; - case CS_ERROR: + case CS_ERROR: ctl_putdbl(sys_var[CS_ERROR].text, clock_jitter * 1e3); break; - case CS_CLOCK: + case CS_CLOCK: get_systime(&tmp); ctl_putts(sys_var[CS_CLOCK].text, &tmp); break; - case CS_PROCESSOR: + case CS_PROCESSOR: #ifndef HAVE_UNAME ctl_putstr(sys_var[CS_PROCESSOR].text, str_processor, - sizeof(str_processor) - 1); + sizeof(str_processor) - 1); #else ctl_putstr(sys_var[CS_PROCESSOR].text, - utsnamebuf.machine, strlen(utsnamebuf.machine)); + utsnamebuf.machine, strlen(utsnamebuf.machine)); #endif /* HAVE_UNAME */ break; - case CS_SYSTEM: + case CS_SYSTEM: #ifndef HAVE_UNAME ctl_putstr(sys_var[CS_SYSTEM].text, str_system, - sizeof(str_system) - 1); + sizeof(str_system) - 1); #else - sprintf(str, "%s/%s", utsnamebuf.sysname, utsnamebuf.release); + snprintf(str, sizeof(str), "%s/%s", utsnamebuf.sysname, + utsnamebuf.release); ctl_putstr(sys_var[CS_SYSTEM].text, str, strlen(str)); #endif /* HAVE_UNAME */ break; - case CS_VERSION: + case CS_VERSION: ctl_putstr(sys_var[CS_VERSION].text, Version, - strlen(Version)); + strlen(Version)); break; - case CS_STABIL: + case CS_STABIL: ctl_putdbl(sys_var[CS_STABIL].text, clock_stability * - 1e6); + 1e6); break; - case CS_VARLIST: - { - char buf[CTL_MAX_DATA_LEN]; - register char *s, *t, *be; - register const char *ss; - register int i; - register struct ctl_var *k; - - s = buf; - be = buf + sizeof(buf) - - strlen(sys_var[CS_VARLIST].text) - 4; - if (s > be) - break; /* really long var name */ - - strcpy(s, sys_var[CS_VARLIST].text); - strcat(s, "=\""); - s += strlen(s); - t = s; - for (k = sys_var; !(k->flags &EOV); k++) { - if (k->flags & PADDING) - continue; - i = strlen(k->text); - if (s+i+1 >= be) - break; - - if (s != t) - *s++ = ','; - strcpy(s, k->text); - s += i; - } - - for (k = ext_sys_var; k && !(k->flags &EOV); - k++) { - if (k->flags & PADDING) - continue; - - ss = k->text; - if (!ss) - continue; - - while (*ss && *ss != '=') - ss++; - i = ss - k->text; - if (s + i + 1 >= be) - break; - - if (s != t) - *s++ = ','; - strncpy(s, k->text, + case CS_VARLIST: + { + char buf[CTL_MAX_DATA_LEN]; + register char *s, *t, *be; + register const char *ss; + register int i; + register struct ctl_var *k; + + s = buf; + be = buf + sizeof(buf); + if (s + strlen(sys_var[CS_VARLIST].text) + 4 > be) + break; /* really long var name */ + + snprintf(s, sizeof(buf), "%s=\"", + sys_var[CS_VARLIST].text); + s += strlen(s); + t = s; + for (k = sys_var; !(k->flags & EOV); k++) { + if (k->flags & PADDING) + continue; + i = strlen(k->text); + if (s+i+1 >= be) + break; + + if (s != t) + *s++ = ','; + memcpy(s, k->text, i); + s += i; + } + + for (k = ext_sys_var; k && !(k->flags & EOV); + k++) { + if (k->flags & PADDING) + continue; + + ss = k->text; + if (!ss) + continue; + + while (*ss && *ss != '=') + ss++; + i = ss - k->text; + if (s + i + 1 >= be) + break; + + if (s != t) + *s++ = ','; + memcpy(s, k->text, (unsigned)i); - s += i; - } - if (s+2 >= be) - break; + s += i; + } + if (s+2 >= be) + break; + + *s++ = '"'; + *s = '\0'; + + ctl_putdata(buf, (unsigned)( s - buf ), + 0); + } + break; + + case CS_TAI: + if (sys_tai > 0) + ctl_putuint(sys_var[CS_TAI].text, sys_tai); + break; - *s++ = '"'; - *s = '\0'; + case CS_LEAPTAB: + if (leap_sec > 0) + ctl_putfs(sys_var[CS_LEAPTAB].text, + leap_sec); + break; - ctl_putdata(buf, (unsigned)( s - buf ), - 0); - } + case CS_LEAPEND: + if (leap_expire > 0) + ctl_putfs(sys_var[CS_LEAPEND].text, + leap_expire); + break; + + case CS_RATE: + ctl_putuint(sys_var[CS_RATE].text, ntp_minpoll); break; #ifdef OPENSSL - case CS_FLAGS: + case CS_FLAGS: + if (crypto_flags) + ctl_puthex(sys_var[CS_FLAGS].text, + crypto_flags); + break; + + case CS_DIGEST: if (crypto_flags) { - ctl_puthex(sys_var[CS_FLAGS].text, crypto_flags); + strcpy(str, OBJ_nid2ln(crypto_nid)); + ctl_putstr(sys_var[CS_DIGEST].text, str, + strlen(str)); } break; - case CS_DIGEST: + case CS_SIGNATURE: if (crypto_flags) { const EVP_MD *dp; dp = EVP_get_digestbynid(crypto_flags >> 16); strcpy(str, OBJ_nid2ln(EVP_MD_pkey_type(dp))); - ctl_putstr(sys_var[CS_DIGEST].text, str, + ctl_putstr(sys_var[CS_SIGNATURE].text, str, strlen(str)); } break; - case CS_HOST: + case CS_HOST: if (sys_hostname != NULL) ctl_putstr(sys_var[CS_HOST].text, sys_hostname, strlen(sys_hostname)); break; - case CS_CERTIF: + case CS_GROUP: + if (sys_groupname != NULL) + ctl_putstr(sys_var[CS_GROUP].text, sys_groupname, + strlen(sys_groupname)); + break; + + case CS_CERTIF: for (cp = cinfo; cp != NULL; cp = cp->link) { - sprintf(cbuf, "%s %s 0x%x", cp->subject, - cp->issuer, cp->flags); + snprintf(cbuf, sizeof(cbuf), "%s %s 0x%x", + cp->subject, cp->issuer, cp->flags); ctl_putstr(sys_var[CS_CERTIF].text, cbuf, strlen(cbuf)); - ctl_putfs(sys_var[CS_REVOKE].text, cp->last); + ctl_putfs(sys_var[CS_REVTIME].text, cp->last); } break; - case CS_PUBLIC: - if (hostval.fstamp != 0) - ctl_putfs(sys_var[CS_PUBLIC].text, - ntohl(hostval.tstamp)); - break; - - case CS_REVTIME: + case CS_PUBLIC: if (hostval.tstamp != 0) - ctl_putfs(sys_var[CS_REVTIME].text, + ctl_putfs(sys_var[CS_PUBLIC].text, ntohl(hostval.tstamp)); break; - - case CS_IDENT: - if (iffpar_pkey != NULL) - ctl_putstr(sys_var[CS_IDENT].text, - iffpar_file, strlen(iffpar_file)); - if (gqpar_pkey != NULL) - ctl_putstr(sys_var[CS_IDENT].text, - gqpar_file, strlen(gqpar_file)); - if (mvpar_pkey != NULL) - ctl_putstr(sys_var[CS_IDENT].text, - mvpar_file, strlen(mvpar_file)); - break; - - case CS_LEAPTAB: - if (tai_leap.fstamp != 0) - ctl_putfs(sys_var[CS_LEAPTAB].text, - ntohl(tai_leap.fstamp)); - break; - - case CS_TAI: - ctl_putuint(sys_var[CS_TAI].text, sys_tai); - break; #endif /* OPENSSL */ } } @@ -1480,32 +1587,32 @@ switch (varid) { - case CP_CONFIG: + case CP_CONFIG: ctl_putuint(peer_var[CP_CONFIG].text, - (unsigned)((peer->flags & FLAG_CONFIG) != 0)); + (unsigned)((peer->flags & FLAG_PREEMPT) == 0)); break; - case CP_AUTHENABLE: + case CP_AUTHENABLE: ctl_putuint(peer_var[CP_AUTHENABLE].text, - (unsigned)((peer->flags & FLAG_AUTHENABLE) != 0)); + (unsigned)(peer->keyid != 0)); break; - case CP_AUTHENTIC: + case CP_AUTHENTIC: ctl_putuint(peer_var[CP_AUTHENTIC].text, (unsigned)((peer->flags & FLAG_AUTHENTIC) != 0)); break; - case CP_SRCADR: + case CP_SRCADR: ctl_putadr(peer_var[CP_SRCADR].text, 0, &peer->srcadr); break; - case CP_SRCPORT: + case CP_SRCPORT: ctl_putuint(peer_var[CP_SRCPORT].text, ntohs(((struct sockaddr_in*)&peer->srcadr)->sin_port)); break; - case CP_DSTADR: + case CP_DSTADR: if (peer->dstadr) { ctl_putadr(peer_var[CP_DSTADR].text, 0, &(peer->dstadr->sin)); @@ -1515,226 +1622,252 @@ } break; - case CP_DSTPORT: + case CP_DSTPORT: ctl_putuint(peer_var[CP_DSTPORT].text, (u_long)(peer->dstadr ? ntohs(((struct sockaddr_in*)&peer->dstadr->sin)->sin_port) : 0)); break; - case CP_LEAP: + case CP_IN: + if (peer->r21 > 0) + ctl_putdbl(peer_var[CP_IN].text, + peer->r21 / 1e3); + break; + + case CP_OUT: + if (peer->r34 >0) + ctl_putdbl(peer_var[CP_OUT].text, + peer->r34 / 1e3); + break; + + case CP_RATE: + ctl_putuint(peer_var[CP_RATE].text, peer->throttle); + break; + + case CP_LEAP: ctl_putuint(peer_var[CP_LEAP].text, peer->leap); break; - case CP_HMODE: + case CP_HMODE: ctl_putuint(peer_var[CP_HMODE].text, peer->hmode); break; - case CP_STRATUM: + case CP_STRATUM: ctl_putuint(peer_var[CP_STRATUM].text, peer->stratum); break; - case CP_PPOLL: + case CP_PPOLL: ctl_putuint(peer_var[CP_PPOLL].text, peer->ppoll); break; - case CP_HPOLL: + case CP_HPOLL: ctl_putuint(peer_var[CP_HPOLL].text, peer->hpoll); break; - case CP_PRECISION: + case CP_PRECISION: ctl_putint(peer_var[CP_PRECISION].text, - peer->precision); + peer->precision); break; - case CP_ROOTDELAY: + case CP_ROOTDELAY: ctl_putdbl(peer_var[CP_ROOTDELAY].text, - peer->rootdelay * 1e3); + peer->rootdelay * 1e3); break; - case CP_ROOTDISPERSION: + case CP_ROOTDISPERSION: ctl_putdbl(peer_var[CP_ROOTDISPERSION].text, - peer->rootdispersion * 1e3); + peer->rootdisp * 1e3); break; - case CP_REFID: + case CP_REFID: if (peer->flags & FLAG_REFCLOCK) { ctl_putid(peer_var[CP_REFID].text, - (char *)&peer->refid); + (char *)&peer->refid); } else { if (peer->stratum > 1 && peer->stratum < STRATUM_UNSPEC) ctl_putadr(peer_var[CP_REFID].text, - peer->refid, NULL); + peer->refid, NULL); else ctl_putid(peer_var[CP_REFID].text, - (char *)&peer->refid); + (char *)&peer->refid); } break; - case CP_REFTIME: + case CP_REFTIME: ctl_putts(peer_var[CP_REFTIME].text, &peer->reftime); break; - case CP_ORG: - ctl_putts(peer_var[CP_ORG].text, &peer->org); + case CP_ORG: + ctl_putts(peer_var[CP_ORG].text, &peer->aorg); + break; + + case CP_REC: + ctl_putts(peer_var[CP_REC].text, &peer->dst); break; - case CP_REC: - ctl_putts(peer_var[CP_REC].text, &peer->rec); + case CP_XMT: + if (peer->xleave != 0) + ctl_putdbl(peer_var[CP_XMT].text, peer->xleave * + 1e3); break; - case CP_XMT: - ctl_putts(peer_var[CP_XMT].text, &peer->xmt); + case CP_BIAS: + if (peer->bias != 0) + ctl_putdbl(peer_var[CP_BIAS].text, peer->bias * + 1e3); break; - case CP_REACH: + case CP_REACH: ctl_puthex(peer_var[CP_REACH].text, peer->reach); break; - case CP_FLASH: + case CP_FLASH: temp = peer->flash; ctl_puthex(peer_var[CP_FLASH].text, temp); break; - case CP_TTL: - ctl_putint(peer_var[CP_TTL].text, sys_ttl[peer->ttl]); + case CP_TTL: + if (peer->ttl > 0) + ctl_putint(peer_var[CP_TTL].text, + sys_ttl[peer->ttl]); break; - case CP_UNREACH: + case CP_UNREACH: ctl_putuint(peer_var[CP_UNREACH].text, peer->unreach); break; - case CP_TIMER: + case CP_TIMER: ctl_putuint(peer_var[CP_TIMER].text, peer->nextdate - current_time); break; - case CP_DELAY: + case CP_DELAY: ctl_putdbl(peer_var[CP_DELAY].text, peer->delay * 1e3); break; - case CP_OFFSET: + case CP_OFFSET: ctl_putdbl(peer_var[CP_OFFSET].text, peer->offset * - 1e3); + 1e3); break; - case CP_JITTER: - ctl_putdbl(peer_var[CP_JITTER].text, peer->jitter * 1e3); + case CP_JITTER: + ctl_putdbl(peer_var[CP_JITTER].text, peer->jitter * + 1e3); break; - case CP_DISPERSION: + case CP_DISPERSION: ctl_putdbl(peer_var[CP_DISPERSION].text, peer->disp * - 1e3); + 1e3); break; - case CP_KEYID: - ctl_putuint(peer_var[CP_KEYID].text, peer->keyid); + case CP_KEYID: + if (peer->keyid > NTP_MAXKEY) + ctl_puthex(peer_var[CP_KEYID].text, + peer->keyid); + else + ctl_putuint(peer_var[CP_KEYID].text, + peer->keyid); break; - case CP_FILTDELAY: + case CP_FILTDELAY: ctl_putarray(peer_var[CP_FILTDELAY].text, peer->filter_delay, (int)peer->filter_nextpt); break; - case CP_FILTOFFSET: + case CP_FILTOFFSET: ctl_putarray(peer_var[CP_FILTOFFSET].text, peer->filter_offset, (int)peer->filter_nextpt); break; - case CP_FILTERROR: + case CP_FILTERROR: ctl_putarray(peer_var[CP_FILTERROR].text, peer->filter_disp, (int)peer->filter_nextpt); break; - case CP_PMODE: + case CP_PMODE: ctl_putuint(peer_var[CP_PMODE].text, peer->pmode); break; - case CP_RECEIVED: + case CP_RECEIVED: ctl_putuint(peer_var[CP_RECEIVED].text, peer->received); break; - case CP_SENT: + case CP_SENT: ctl_putuint(peer_var[CP_SENT].text, peer->sent); break; - case CP_VARLIST: - { - char buf[CTL_MAX_DATA_LEN]; - register char *s, *t, *be; - register int i; - register struct ctl_var *k; - - s = buf; - be = buf + sizeof(buf) - - strlen(peer_var[CP_VARLIST].text) - 4; - if (s > be) - break; /* really long var name */ - - strcpy(s, peer_var[CP_VARLIST].text); - strcat(s, "=\""); - s += strlen(s); - t = s; - for (k = peer_var; !(k->flags &EOV); k++) { - if (k->flags & PADDING) - continue; - - i = strlen(k->text); - if (s + i + 1 >= be) - break; - - if (s != t) - *s++ = ','; - strcpy(s, k->text); - s += i; - } - if (s+2 >= be) - break; - - *s++ = '"'; - *s = '\0'; - ctl_putdata(buf, (unsigned)(s - buf), 0); - } - break; + case CP_VARLIST: + { + char buf[CTL_MAX_DATA_LEN]; + register char *s, *t, *be; + register int i; + register struct ctl_var *k; + + s = buf; + be = buf + sizeof(buf); + if (s + strlen(peer_var[CP_VARLIST].text) + 4 > be) + break; /* really long var name */ + + snprintf(s, sizeof(buf), "%s=\"", + peer_var[CP_VARLIST].text); + s += strlen(s); + t = s; + for (k = peer_var; !(k->flags & EOV); k++) { + if (k->flags & PADDING) + continue; + + i = strlen(k->text); + if (s + i + 1 >= be) + break; + + if (s != t) + *s++ = ','; + memcpy(s, k->text, i); + s += i; + } + if (s+2 >= be) + break; + + *s++ = '"'; + *s = '\0'; + ctl_putdata(buf, (unsigned)(s - buf), 0); + } + break; #ifdef OPENSSL - case CP_FLAGS: + case CP_FLAGS: if (peer->crypto) ctl_puthex(peer_var[CP_FLAGS].text, peer->crypto); break; - case CP_DIGEST: + case CP_SIGNATURE: if (peer->crypto) { const EVP_MD *dp; dp = EVP_get_digestbynid(peer->crypto >> 16); strcpy(str, OBJ_nid2ln(EVP_MD_pkey_type(dp))); - ctl_putstr(peer_var[CP_DIGEST].text, str, - strlen(str)); + ctl_putstr(peer_var[CP_SIGNATURE].text, str, + strlen(str)); } break; - case CP_HOST: + case CP_HOST: if (peer->subject != NULL) ctl_putstr(peer_var[CP_HOST].text, peer->subject, strlen(peer->subject)); break; - case CP_VALID: /* not used */ - break; - - case CP_IDENT: - if (peer->issuer != NULL) - ctl_putstr(peer_var[CP_IDENT].text, - peer->issuer, strlen(peer->issuer)); + case CP_VALID: /* not used */ break; - case CP_INITSEQ: + case CP_INITSEQ: if ((ap = (struct autokey *)peer->recval.ptr) == NULL) break; + ctl_putint(peer_var[CP_INITSEQ].text, ap->seq); ctl_puthex(peer_var[CP_INITKEY].text, ap->key); ctl_putfs(peer_var[CP_INITTSP].text, - ntohl(peer->recval.tstamp)); + ntohl(peer->recval.tstamp)); break; #endif /* OPENSSL */ } @@ -1754,147 +1887,147 @@ { switch(varid) { - case CC_TYPE: + case CC_TYPE: if (mustput || clock_stat->clockdesc == NULL - || *(clock_stat->clockdesc) == '\0') { + || *(clock_stat->clockdesc) == '\0') { ctl_putuint(clock_var[CC_TYPE].text, clock_stat->type); } break; - case CC_TIMECODE: + case CC_TIMECODE: ctl_putstr(clock_var[CC_TIMECODE].text, - clock_stat->p_lastcode, - (unsigned)clock_stat->lencode); + clock_stat->p_lastcode, + (unsigned)clock_stat->lencode); break; - case CC_POLL: + case CC_POLL: ctl_putuint(clock_var[CC_POLL].text, clock_stat->polls); break; - case CC_NOREPLY: + case CC_NOREPLY: ctl_putuint(clock_var[CC_NOREPLY].text, - clock_stat->noresponse); + clock_stat->noresponse); break; - case CC_BADFORMAT: + case CC_BADFORMAT: ctl_putuint(clock_var[CC_BADFORMAT].text, - clock_stat->badformat); + clock_stat->badformat); break; - case CC_BADDATA: + case CC_BADDATA: ctl_putuint(clock_var[CC_BADDATA].text, - clock_stat->baddata); + clock_stat->baddata); break; - case CC_FUDGETIME1: + case CC_FUDGETIME1: if (mustput || (clock_stat->haveflags & CLK_HAVETIME1)) ctl_putdbl(clock_var[CC_FUDGETIME1].text, - clock_stat->fudgetime1 * 1e3); + clock_stat->fudgetime1 * 1e3); break; - case CC_FUDGETIME2: + case CC_FUDGETIME2: if (mustput || (clock_stat->haveflags & CLK_HAVETIME2)) ctl_putdbl(clock_var[CC_FUDGETIME2].text, - clock_stat->fudgetime2 * 1e3); + clock_stat->fudgetime2 * 1e3); break; - case CC_FUDGEVAL1: + case CC_FUDGEVAL1: if (mustput || (clock_stat->haveflags & CLK_HAVEVAL1)) ctl_putint(clock_var[CC_FUDGEVAL1].text, - clock_stat->fudgeval1); + clock_stat->fudgeval1); break; - case CC_FUDGEVAL2: + case CC_FUDGEVAL2: if (mustput || (clock_stat->haveflags & CLK_HAVEVAL2)) { if (clock_stat->fudgeval1 > 1) ctl_putadr(clock_var[CC_FUDGEVAL2].text, - (u_int32)clock_stat->fudgeval2, NULL); + (u_int32)clock_stat->fudgeval2, NULL); else ctl_putid(clock_var[CC_FUDGEVAL2].text, - (char *)&clock_stat->fudgeval2); + (char *)&clock_stat->fudgeval2); } break; - case CC_FLAGS: + case CC_FLAGS: if (mustput || (clock_stat->haveflags & (CLK_HAVEFLAG1 | - CLK_HAVEFLAG2 | CLK_HAVEFLAG3 | CLK_HAVEFLAG4))) + CLK_HAVEFLAG2 | CLK_HAVEFLAG3 | CLK_HAVEFLAG4))) ctl_putuint(clock_var[CC_FLAGS].text, - clock_stat->flags); + clock_stat->flags); break; - case CC_DEVICE: + case CC_DEVICE: if (clock_stat->clockdesc == NULL || *(clock_stat->clockdesc) == '\0') { if (mustput) ctl_putstr(clock_var[CC_DEVICE].text, - "", 0); + "", 0); } else { ctl_putstr(clock_var[CC_DEVICE].text, - clock_stat->clockdesc, - strlen(clock_stat->clockdesc)); + clock_stat->clockdesc, + strlen(clock_stat->clockdesc)); } break; - case CC_VARLIST: - { - char buf[CTL_MAX_DATA_LEN]; - register char *s, *t, *be; - register const char *ss; - register int i; - register struct ctl_var *k; - - s = buf; - be = buf + sizeof(buf); - if (s + strlen(clock_var[CC_VARLIST].text) + 4 > - be) - break; /* really long var name */ - - strcpy(s, clock_var[CC_VARLIST].text); - strcat(s, "=\""); - s += strlen(s); - t = s; - - for (k = clock_var; !(k->flags &EOV); k++) { - if (k->flags & PADDING) - continue; - - i = strlen(k->text); - if (s + i + 1 >= be) - break; - - if (s != t) - *s++ = ','; - strcpy(s, k->text); - s += i; - } - - for (k = clock_stat->kv_list; k && !(k->flags & - EOV); k++) { - if (k->flags & PADDING) - continue; - - ss = k->text; - if (!ss) - continue; - - while (*ss && *ss != '=') - ss++; - i = ss - k->text; - if (s+i+1 >= be) - break; - - if (s != t) - *s++ = ','; - strncpy(s, k->text, (unsigned)i); - s += i; - *s = '\0'; - } - if (s+2 >= be) - break; - - *s++ = '"'; - *s = '\0'; - ctl_putdata(buf, (unsigned)( s - buf ), 0); - } - break; + case CC_VARLIST: + { + char buf[CTL_MAX_DATA_LEN]; + register char *s, *t, *be; + register const char *ss; + register int i; + register struct ctl_var *k; + + s = buf; + be = buf + sizeof(buf); + if (s + strlen(clock_var[CC_VARLIST].text) + 4 > + be) + break; /* really long var name */ + + snprintf(s, sizeof(buf), "%s=\"", + clock_var[CC_VARLIST].text); + s += strlen(s); + t = s; + + for (k = clock_var; !(k->flags & EOV); k++) { + if (k->flags & PADDING) + continue; + + i = strlen(k->text); + if (s + i + 1 >= be) + break; + + if (s != t) + *s++ = ','; + memcpy(s, k->text, i); + s += i; + } + + for (k = clock_stat->kv_list; k && !(k->flags & + EOV); k++) { + if (k->flags & PADDING) + continue; + + ss = k->text; + if (!ss) + continue; + + while (*ss && *ss != '=') + ss++; + i = ss - k->text; + if (s+i+1 >= be) + break; + + if (s != t) + *s++ = ','; + memcpy(s, k->text, (unsigned)i); + s += i; + *s = '\0'; + } + if (s+2 >= be) + break; + + *s++ = '"'; + *s = '\0'; + ctl_putdata(buf, (unsigned)( s - buf ), 0); + } + break; } } #endif @@ -1920,7 +2053,7 @@ * Delete leading commas and white space */ while (reqpt < reqend && (*reqpt == ',' || - isspace((unsigned char)*reqpt))) + isspace((unsigned char)*reqpt))) reqpt++; if (reqpt >= reqend) return (0); @@ -1938,7 +2071,7 @@ if (!(v->flags & PADDING) && *cp == *(v->text)) { tp = v->text; while (*tp != '\0' && *tp != '=' && cp < - reqend && *cp == *tp) { + reqend && *cp == *tp) { cp++; tp++; } @@ -1966,8 +2099,8 @@ #if 0 /* Avoid possible DOS attack */ /* If we get a smarter msyslog we can re-enable this */ msyslog(LOG_WARNING, - "Possible 'ntpdx' exploit from %s:%d (possibly spoofed)\n", - stoa(rmt_addr), SRCPORT(rmt_addr) + "Possible 'ntpdx' exploit from %s:%d (possibly spoofed)\n", + stoa(rmt_addr), SRCPORT(rmt_addr) ); #endif return (0); @@ -2055,14 +2188,14 @@ rpkt.status = htons(ctlsysstatus()); for (i = 0; i < NTP_HASH_SIZE; i++) { for (peer = assoc_hash[i]; peer != 0; - peer = peer->ass_next) { + peer = peer->ass_next) { ass_stat[n++] = htons(peer->associd); ass_stat[n++] = htons(ctlpeerstatus(peer)); if (n == CTL_MAX_DATA_LEN/sizeof(u_short)) { ctl_putdata((char *)ass_stat, - n * sizeof(u_short), 1); + n * sizeof(u_short), 1); n = 0; } } @@ -2070,7 +2203,7 @@ if (n != 0) ctl_putdata((char *)ass_stat, n * - sizeof(u_short), 1); + sizeof(u_short), 1); ctl_flushpkt(0); } else { peer = findpeerbyassoc(res_associd); @@ -2109,7 +2242,7 @@ char *valuep; u_char *wants; unsigned int gotvar = (CS_MAXCODE > CP_MAXCODE) ? (CS_MAXCODE + - 1) : (CP_MAXCODE + 1); + 1) : (CP_MAXCODE + 1); if (res_associd == 0) { /* * Wants system variables. Figure out which he wants @@ -2125,14 +2258,14 @@ while ((v = ctl_getitem(sys_var, &valuep)) != 0) { if (v->flags & EOV) { if ((v = ctl_getitem(ext_sys_var, - &valuep)) != 0) { + &valuep)) != 0) { if (v->flags & EOV) { ctl_error(CERR_UNKNOWNVAR); free((char *)wants); return; } wants[CS_MAXCODE + 1 + - v->code] = 1; + v->code] = 1; gotvar = 1; continue; } else { @@ -2147,11 +2280,11 @@ if (wants[i]) ctl_putsys(i); for (i = 0; ext_sys_var && - !(ext_sys_var[i].flags & EOV); i++) + !(ext_sys_var[i].flags & EOV); i++) if (wants[i + CS_MAXCODE + 1]) ctl_putdata(ext_sys_var[i].text, - strlen(ext_sys_var[i].text), - 0); + strlen(ext_sys_var[i].text), + 0); } else { register u_char *cs; register struct ctl_var *kv; @@ -2159,10 +2292,10 @@ for (cs = def_sys_var; *cs != 0; cs++) ctl_putsys((int)*cs); for (kv = ext_sys_var; kv && !(kv->flags & EOV); - kv++) + kv++) if (kv->flags & DEF) ctl_putdata(kv->text, - strlen(kv->text), 0); + strlen(kv->text), 0); } free((char *)wants); } else { @@ -2260,7 +2393,7 @@ return; } if (!ext_var && (*valuep == '\0' || !atoint(valuep, - &val))) { + &val))) { ctl_error(CERR_BADFMT); return; } @@ -2271,7 +2404,7 @@ if (ext_var) { char *s = (char *)emalloc(strlen(v->text) + - strlen(valuep) + 2); + strlen(valuep) + 2); const char *t; char *tt = s; @@ -2289,8 +2422,8 @@ */ switch(v->code) { - case CS_LEAP: - default: + case CS_LEAP: + default: ctl_error(CERR_UNSPEC); /* really */ return; } @@ -2302,15 +2435,101 @@ */ /* if (leapind != ~0 || leapwarn != ~0) { - if (!leap_setleap((int)leapind, (int)leapwarn)) { - ctl_error(CERR_PERMISSION); - return; - } + if (!leap_setleap((int)leapind, (int)leapwarn)) { + ctl_error(CERR_PERMISSION); + return; + } } */ ctl_flushpkt(0); } +/* + * configure() processes ntpq :config/config-from-file, allowing + * generic runtime reconfiguration. + */ +static void configure( + struct recvbuf *rbufp, + int restrict_mask + ) +{ + int data_count, retval, replace_nl; + + /* I haven't yet implemented changes to an existing association. + * Hence check if the association id is 0 + */ + if (res_associd != 0) { + ctl_error(CERR_BADVALUE); + return; + } + + if (restrict_mask & RES_NOMODIFY) { + snprintf(remote_config.err_msg, + sizeof(remote_config.err_msg), + "runtime configuration prohibited by restrict ... nomodify"); + ctl_putdata(remote_config.err_msg, + strlen(remote_config.err_msg), 0); + ctl_flushpkt(0); + msyslog(LOG_NOTICE, + "runtime config from %s rejected due to nomodify restriction", + stoa(&rbufp->recv_srcadr)); + return; + } + + /* Initialize the remote config buffer */ + data_count = reqend - reqpt; + memcpy(remote_config.buffer, reqpt, data_count); + if (data_count > 0 + && '\n' != remote_config.buffer[data_count - 1]) + remote_config.buffer[data_count++] = '\n'; + remote_config.buffer[data_count] = '\0'; + remote_config.pos = 0; + remote_config.err_pos = 0; + remote_config.no_errors = 0; + + /* do not include terminating newline in log */ + if (data_count > 0 + && '\n' == remote_config.buffer[data_count - 1]) { + remote_config.buffer[data_count - 1] = '\0'; + replace_nl = 1; + } else + replace_nl = 0; + + DPRINTF(1, ("Got Remote Configuration Command: %s\n", + remote_config.buffer)); + msyslog(LOG_NOTICE, "%s config: %s", + stoa(&rbufp->recv_srcadr), + remote_config.buffer); + + if (replace_nl) + remote_config.buffer[data_count - 1] = '\n'; + + config_remotely(&rbufp->recv_srcadr); + + /* + * Check if errors were reported. If not, output 'Config + * Succeeded'. Else output the error count. It would be nice + * to output any parser error messages. + */ + if (0 == remote_config.no_errors) { + retval = snprintf(remote_config.err_msg, + sizeof(remote_config.err_msg), + "Config Succeeded"); + if (retval > 0) + remote_config.err_pos += retval; + } + + ctl_putdata(remote_config.err_msg, remote_config.err_pos, 0); + ctl_flushpkt(0); + + DPRINTF(1, ("Reply: %s\n", remote_config.err_msg)); + + if (remote_config.no_errors > 0) + msyslog(LOG_NOTICE, "%d error in %s config", + remote_config.no_errors, + stoa(&rbufp->recv_srcadr)); +} + /* * read_clock_status - return clock radio status @@ -2344,13 +2563,13 @@ * for one. */ if (sys_peer != 0 && (sys_peer->flags & FLAG_REFCLOCK)) - { + { peer = sys_peer; } else { peer = 0; for (i = 0; peer == 0 && i < NTP_HASH_SIZE; i++) { for (peer = assoc_hash[i]; peer != 0; - peer = peer->ass_next) { + peer = peer->ass_next) { if (peer->flags & FLAG_REFCLOCK) break; } @@ -2374,7 +2593,7 @@ */ clock_stat.kv_list = (struct ctl_var *)0; refclock_control(&peer->srcadr, (struct refclockstat *)0, - &clock_stat); + &clock_stat); /* * Look for variables in the packet. @@ -2387,7 +2606,7 @@ while ((v = ctl_getitem(clock_var, &valuep)) != 0) { if (v->flags & EOV) { if ((v = ctl_getitem(clock_stat.kv_list, - &valuep)) != 0) { + &valuep)) != 0) { if (v->flags & EOV) { ctl_error(CERR_UNKNOWNVAR); free((char*)wants); @@ -2408,13 +2627,13 @@ if (gotvar) { for (i = 1; i <= CC_MAXCODE; i++) if (wants[i]) - ctl_putclock(i, &clock_stat, 1); + ctl_putclock(i, &clock_stat, 1); for (i = 0; clock_stat.kv_list && - !(clock_stat.kv_list[i].flags & EOV); i++) + !(clock_stat.kv_list[i].flags & EOV); i++) if (wants[i + CC_MAXCODE + 1]) ctl_putdata(clock_stat.kv_list[i].text, - strlen(clock_stat.kv_list[i].text), - 0); + strlen(clock_stat.kv_list[i].text), + 0); } else { register u_char *cc; register struct ctl_var *kv; @@ -2422,10 +2641,10 @@ for (cc = def_clock_var; *cc != 0; cc++) ctl_putclock((int)*cc, &clock_stat, 0); for (kv = clock_stat.kv_list; kv && !(kv->flags & EOV); - kv++) + kv++) if (kv->flags & DEF) ctl_putdata(kv->text, strlen(kv->text), - 0); + 0); } free((char*)wants); @@ -2485,7 +2704,7 @@ * an error if it can't assign the trap. */ if (!ctlsettrap(&rbufp->recv_srcadr, rbufp->dstadr, traptype, - (int)res_version)) + (int)res_version)) ctl_error(CERR_NORESOURCE); ctl_flushpkt(0); } @@ -2526,7 +2745,7 @@ */ int ctlsettrap( - struct sockaddr_storage *raddr, + sockaddr_u *raddr, struct interface *linter, int traptype, int version @@ -2542,17 +2761,17 @@ if ((tp = ctlfindtrap(raddr, linter)) != NULL) { switch (traptype) { - case TRAP_TYPE_CONFIG: + case TRAP_TYPE_CONFIG: tp->tr_flags = TRAP_INUSE|TRAP_CONFIGURED; break; - case TRAP_TYPE_PRIO: + case TRAP_TYPE_PRIO: if (tp->tr_flags & TRAP_CONFIGURED) return (1); /* don't change anything */ tp->tr_flags = TRAP_INUSE; break; - case TRAP_TYPE_NONPRIO: + case TRAP_TYPE_NONPRIO: if (tp->tr_flags & TRAP_CONFIGURED) return (1); /* don't change anything */ tp->tr_flags = TRAP_INUSE|TRAP_NONPRIO; @@ -2581,7 +2800,7 @@ } else if (!(tp->tr_flags & TRAP_CONFIGURED)) { switch (traptype) { - case TRAP_TYPE_CONFIG: + case TRAP_TYPE_CONFIG: if (tptouse == NULL) { tptouse = tp; break; @@ -2600,18 +2819,18 @@ tptouse = tp; break; - case TRAP_TYPE_PRIO: + case TRAP_TYPE_PRIO: if (tp->tr_flags & TRAP_NONPRIO) { if (tptouse == NULL || (tptouse->tr_flags & - TRAP_INUSE && - tptouse->tr_origtime < - tp->tr_origtime)) + TRAP_INUSE && + tptouse->tr_origtime < + tp->tr_origtime)) tptouse = tp; } break; - case TRAP_TYPE_NONPRIO: + case TRAP_TYPE_NONPRIO: break; } } @@ -2647,7 +2866,7 @@ */ int ctlclrtrap( - struct sockaddr_storage *raddr, + sockaddr_u *raddr, struct interface *linter, int traptype ) @@ -2658,7 +2877,7 @@ return (0); if (tp->tr_flags & TRAP_CONFIGURED - && traptype != TRAP_TYPE_CONFIG) + && traptype != TRAP_TYPE_CONFIG) return (0); tp->tr_flags = 0; @@ -2672,7 +2891,7 @@ */ static struct ctl_trap * ctlfindtrap( - struct sockaddr_storage *raddr, + sockaddr_u *raddr, struct interface *linter ) { @@ -2681,9 +2900,9 @@ for (tp = ctl_trap; tp < &ctl_trap[CTL_MAXTRAPS]; tp++) { if ((tp->tr_flags & TRAP_INUSE) && (NSRCPORT(raddr) == NSRCPORT(&tp->tr_addr)) - && SOCKCMP(raddr, &tp->tr_addr) + && SOCK_EQ(raddr, &tp->tr_addr) && (linter == tp->tr_localaddr) ) - return (tp); + return (tp); } return (struct ctl_trap *)NULL; } @@ -2694,69 +2913,80 @@ */ void report_event( - int err, - struct peer *peer + int err, /* error code */ + struct peer *peer, /* peer structure pointer */ + const char *str /* protostats string */ ) { - register int i; + char statstr[NTP_MAXSTRLEN]; + int i; + size_t len; /* - * Record error code in proper spots, but have mercy on the - * log file. + * Report the error to the protostats file, system log and + * trappers. */ - if (!(err & (PEER_EVENT | CRPT_EVENT))) { - if (ctl_sys_num_events < CTL_SYS_MAXEVENTS) - ctl_sys_num_events++; - if (ctl_sys_last_event != (u_char)err) { - NLOG(NLOG_SYSEVENT) - msyslog(LOG_INFO, "system event '%s' (0x%02x) status '%s' (0x%02x)", - eventstr(err), err, - sysstatstr(ctlsysstatus()), ctlsysstatus()); -#ifdef DEBUG - if (debug) - printf("report_event: system event '%s' (0x%02x) status '%s' (0x%02x)\n", - eventstr(err), err, - sysstatstr(ctlsysstatus()), - ctlsysstatus()); -#endif - ctl_sys_last_event = (u_char)err; + if (peer == NULL) { + + /* + * Discard a system report if the number of reports of + * the same type exceeds the maximum. + */ + if (ctl_sys_last_event != (u_char)err) + ctl_sys_num_events= 0; + if (ctl_sys_num_events >= CTL_SYS_MAXEVENTS) + return; + + ctl_sys_last_event = (u_char)err; + ctl_sys_num_events++; + snprintf(statstr, NTP_MAXSTRLEN, + "0.0.0.0 %04x %02x %s", + ctlsysstatus(), err, eventstr(err)); + if (str != NULL) { + len = strlen(statstr); + snprintf(statstr + len, sizeof(statstr) - len, + " %s", str); } - } else if (peer != 0) { - char *src; + NLOG(NLOG_SYSEVENT) + msyslog(LOG_INFO, statstr); + } else { -#ifdef REFCLOCK + /* + * Discard a peer report if the number of reports of + * the same type exceeds the maximum for that peer. + */ + char *src; + u_char errlast; + + errlast = (u_char)err & ~PEER_EVENT; + if (peer->last_event == errlast) + peer->num_events = 0; + if (peer->num_events >= CTL_PEER_MAXEVENTS) + return; + + peer->last_event = errlast; + peer->num_events++; if (ISREFCLOCKADR(&peer->srcadr)) src = refnumtoa(&peer->srcadr); else -#endif src = stoa(&peer->srcadr); - peer->last_event = (u_char)(err & ~PEER_EVENT); - if (peer->num_events < CTL_PEER_MAXEVENTS) - peer->num_events++; + snprintf(statstr, NTP_MAXSTRLEN, + "%s %04x %02x %s", src, + ctlpeerstatus(peer), err, eventstr(err)); + if (str != NULL) { + len = strlen(statstr); + snprintf(statstr + len, sizeof(statstr) - len, + " %s", str); + } NLOG(NLOG_PEEREVENT) - msyslog(LOG_INFO, "peer %s event '%s' (0x%02x) status '%s' (0x%02x)", - src, eventstr(err), err, - peerstatstr(ctlpeerstatus(peer)), - ctlpeerstatus(peer)); -#ifdef DEBUG - if (debug) - printf( "peer %s event '%s' (0x%02x) status '%s' (0x%02x)\n", - src, eventstr(err), err, - peerstatstr(ctlpeerstatus(peer)), - ctlpeerstatus(peer)); -#endif - } else { - msyslog(LOG_ERR, - "report_event: err '%s' (0x%02x), no peer", - eventstr(err), err); -#ifdef DEBUG - printf( - "report_event: peer event '%s' (0x%02x), no peer\n", - eventstr(err), err); -#endif - return; + msyslog(LOG_INFO, statstr); } + record_proto_stats(statstr); +#if DEBUG + if (debug) + printf("event at %lu %s\n", current_time, statstr); +#endif /* * If no trappers, return. @@ -2788,31 +3018,8 @@ #endif /* OPENSSL */ ctl_putsys(i); } -#ifdef REFCLOCK - /* - * for clock exception events: add clock variables to - * reflect info on exception - */ - if (err == EVNT_CLOCKEXCPT) { - struct refclockstat clock_stat; - struct ctl_var *kv; - - clock_stat.kv_list = (struct ctl_var *)0; - refclock_control(&peer->srcadr, - (struct refclockstat *)0, &clock_stat); - ctl_puthex("refclockstatus", - ctlclkstatus(&clock_stat)); - for (i = 1; i <= CC_MAXCODE; i++) - ctl_putclock(i, &clock_stat, 0); - for (kv = clock_stat.kv_list; kv && - !(kv->flags & EOV); kv++) - if (kv->flags & DEF) - ctl_putdata(kv->text, - strlen(kv->text), 0); - free_varlist(clock_stat.kv_list); - } -#endif /* REFCLOCK */ } else { + NTP_INSIST(peer != NULL); rpkt.associd = htons(peer->associd); rpkt.status = htons(ctlpeerstatus(peer)); @@ -2831,24 +3038,24 @@ * for clock exception events: add clock variables to * reflect info on exception */ - if (err == EVNT_PEERCLOCK) { + if (err == PEVNT_CLOCK) { struct refclockstat clock_stat; struct ctl_var *kv; clock_stat.kv_list = (struct ctl_var *)0; refclock_control(&peer->srcadr, - (struct refclockstat *)0, &clock_stat); + (struct refclockstat *)0, &clock_stat); ctl_puthex("refclockstatus", - ctlclkstatus(&clock_stat)); + ctlclkstatus(&clock_stat)); for (i = 1; i <= CC_MAXCODE; i++) ctl_putclock(i, &clock_stat, 0); for (kv = clock_stat.kv_list; kv && - !(kv->flags & EOV); kv++) + !(kv->flags & EOV); kv++) if (kv->flags & DEF) ctl_putdata(kv->text, - strlen(kv->text), 0); + strlen(kv->text), 0); free_varlist(clock_stat.kv_list); } #endif /* REFCLOCK */ @@ -2917,7 +3124,7 @@ *kv = (struct ctl_var *)emalloc((c+2)*sizeof(struct ctl_var)); if (k) { memmove((char *)*kv, (char *)k, - sizeof(struct ctl_var)*c); + sizeof(struct ctl_var)*c); free((char *)k); } (*kv)[c].code = (u_short) c; diff -urN src/contrib/ntp/ntpd/ntp_crypto.c src.ntp/contrib/ntp/ntpd/ntp_crypto.c --- src/contrib/ntp/ntpd/ntp_crypto.c 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/ntp_crypto.c 2009-12-09 08:36:35.000000000 +0100 @@ -16,7 +16,8 @@ #include "ntp_stdlib.h" #include "ntp_unixtime.h" #include "ntp_string.h" -#include +#include "ntp_random.h" +#include "ntp_assert.h" #include "openssl/asn1_mac.h" #include "openssl/bn.h" @@ -40,7 +41,7 @@ * +-------+-------+ * | op | len | <- extension pointer * +-------+-------+ - * | assocID | + * | associd | * +---------------+ * | timestamp | <- value pointer * +---------------+ @@ -79,13 +80,28 @@ * creator or signor is synchronized to an authoritative source and * proventicated to a trusted authority. * - * Note there are four conditions required for server trust. First, the - * public key on the certificate must be verified, which involves a - * number of format, content and consistency checks. Next, the server - * identity must be confirmed by one of four schemes: private - * certificate, IFF scheme, GQ scheme or certificate trail hike to a - * self signed trusted certificate. Finally, the server signature must - * be verified. + * Note there are several conditions required for server trust. First, + * the public key on the server certificate must be verified, which can + * involve a hike along the certificate trail to a trusted host. Next, + * the server trust must be confirmed by one of several identity + * schemes. Valid cryptographic values are signed with attached + * timestamp and filestamp. Individual packet trust is confirmed + * relative to these values by a message digest with keys generated by a + * reverse-order pseudorandom hash. + * + * State decomposition. These flags are lit in the order given. They are + * dim only when the association is demobilized. + * + * CRYPTO_FLAG_ENAB Lit upon acceptance of a CRYPTO_ASSOC message + * CRYPTO_FLAG_CERT Lit when a self-digned trusted certificate is + * accepted. + * CRYPTO_FLAG_VRFY Lit when identity is confirmed. + * CRYPTO_FLAG_PROV Lit when the first signature is verified. + * CRYPTO_FLAG_COOK Lit when a valid cookie is accepted. + * CRYPTO_FLAG_AUTO Lit when valid autokey values are accepted. + * CRYPTO_FLAG_SIGN Lit when the server signed certificate is + * accepted. + * CRYPTO_FLAG_LEAP Lit when the leapsecond values are accepted. */ /* * Cryptodefines @@ -99,20 +115,22 @@ * Global cryptodata in host byte order */ u_int32 crypto_flags = 0x0; /* status word */ +int crypto_nid = KEY_TYPE_MD5; /* digest nid */ +char *sys_hostname = NULL; /* host name */ +char *sys_groupname = NULL; /* group name */ /* * Global cryptodata in network byte order */ -struct cert_info *cinfo = NULL; /* certificate info/value */ +struct cert_info *cinfo = NULL; /* certificate info/value cache */ +struct cert_info *cert_host = NULL; /* host certificate */ +struct pkey_info *pkinfo = NULL; /* key info/value cache */ struct value hostval; /* host value */ struct value pubkey; /* public key */ -struct value tai_leap; /* leapseconds table */ -EVP_PKEY *iffpar_pkey = NULL; /* IFF parameters */ -EVP_PKEY *gqpar_pkey = NULL; /* GQ parameters */ -EVP_PKEY *mvpar_pkey = NULL; /* MV parameters */ -char *iffpar_file = NULL; /* IFF parameters file */ -char *gqpar_file = NULL; /* GQ parameters file */ -char *mvpar_file = NULL; /* MV parameters file */ +struct value tai_leap; /* leapseconds values */ +struct pkey_info *iffkey_info = NULL; /* IFF keys */ +struct pkey_info *gqkey_info = NULL; /* GQ keys */ +struct pkey_info *mvkey_info = NULL; /* MV keys */ /* * Private cryptodata in host byte order @@ -123,43 +141,34 @@ static const EVP_MD *sign_digest = NULL; /* sign digest */ static u_int sign_siglen; /* sign key length */ static char *rand_file = NULL; /* random seed file */ -static char *host_file = NULL; /* host key file */ -static char *sign_file = NULL; /* sign key file */ -static char *cert_file = NULL; /* certificate file */ -static char *leap_file = NULL; /* leapseconds file */ -static tstamp_t if_fstamp = 0; /* IFF filestamp */ -static tstamp_t gq_fstamp = 0; /* GQ file stamp */ -static tstamp_t mv_fstamp = 0; /* MV filestamp */ -static u_int ident_scheme = 0; /* server identity scheme */ /* * Cryptotypes */ -static int crypto_verify P((struct exten *, struct value *, - struct peer *)); -static int crypto_encrypt P((struct exten *, struct value *, - keyid_t *)); -static int crypto_alice P((struct peer *, struct value *)); -static int crypto_alice2 P((struct peer *, struct value *)); -static int crypto_alice3 P((struct peer *, struct value *)); -static int crypto_bob P((struct exten *, struct value *)); -static int crypto_bob2 P((struct exten *, struct value *)); -static int crypto_bob3 P((struct exten *, struct value *)); -static int crypto_iff P((struct exten *, struct peer *)); -static int crypto_gq P((struct exten *, struct peer *)); -static int crypto_mv P((struct exten *, struct peer *)); -static u_int crypto_send P((struct exten *, struct value *)); -static tstamp_t crypto_time P((void)); -static u_long asn2ntp P((ASN1_TIME *)); -static struct cert_info *cert_parse P((u_char *, u_int, tstamp_t)); -static int cert_sign P((struct exten *, struct value *)); -static int cert_valid P((struct cert_info *, EVP_PKEY *)); -static int cert_install P((struct exten *, struct peer *)); -static void cert_free P((struct cert_info *)); -static EVP_PKEY *crypto_key P((char *, tstamp_t *)); -static int bighash P((BIGNUM *, BIGNUM *)); -static struct cert_info *crypto_cert P((char *)); -static void crypto_tai P((char *)); +static int crypto_verify (struct exten *, struct value *, + struct peer *); +static int crypto_encrypt (struct exten *, struct value *, + keyid_t *); +static int crypto_alice (struct peer *, struct value *); +static int crypto_alice2 (struct peer *, struct value *); +static int crypto_alice3 (struct peer *, struct value *); +static int crypto_bob (struct exten *, struct value *); +static int crypto_bob2 (struct exten *, struct value *); +static int crypto_bob3 (struct exten *, struct value *); +static int crypto_iff (struct exten *, struct peer *); +static int crypto_gq (struct exten *, struct peer *); +static int crypto_mv (struct exten *, struct peer *); +static int crypto_send (struct exten *, struct value *, int); +static tstamp_t crypto_time (void); +static u_long asn2ntp (ASN1_TIME *); +static struct cert_info *cert_parse (u_char *, long, tstamp_t); +static int cert_sign (struct exten *, struct value *); +static struct cert_info *cert_install (struct exten *, struct peer *); +static int cert_hike (struct peer *, struct cert_info *); +static void cert_free (struct cert_info *); +static struct pkey_info *crypto_key (char *, char *, sockaddr_u *); +static void bighash (BIGNUM *, BIGNUM *); +static struct cert_info *crypto_cert (char *); #ifdef SYS_WINNT int @@ -176,12 +185,12 @@ * session key is the MD5 hash of these values, while the next key ID is * the first four octets of the hash. * - * Returns the next key ID + * Returns the next key ID or 0 if there is no destination address. */ keyid_t session_key( - struct sockaddr_storage *srcadr, /* source address */ - struct sockaddr_storage *dstadr, /* destination address */ + sockaddr_u *srcadr, /* source address */ + sockaddr_u *dstadr, /* destination address */ keyid_t keyno, /* key ID */ keyid_t private, /* private value */ u_long lifetime /* key lifetime */ @@ -201,41 +210,38 @@ * greater than zero, install the key and call it trusted. */ hdlen = 0; - switch(srcadr->ss_family) { + switch(AF(srcadr)) { case AF_INET: - header[0] = ((struct sockaddr_in *)srcadr)->sin_addr.s_addr; - header[1] = ((struct sockaddr_in *)dstadr)->sin_addr.s_addr; + header[0] = NSRCADR(srcadr); + header[1] = NSRCADR(dstadr); header[2] = htonl(keyno); header[3] = htonl(private); hdlen = 4 * sizeof(u_int32); break; case AF_INET6: - memcpy(&header[0], &GET_INADDR6(*srcadr), + memcpy(&header[0], PSOCK_ADDR6(srcadr), sizeof(struct in6_addr)); - memcpy(&header[4], &GET_INADDR6(*dstadr), + memcpy(&header[4], PSOCK_ADDR6(dstadr), sizeof(struct in6_addr)); header[8] = htonl(keyno); header[9] = htonl(private); hdlen = 10 * sizeof(u_int32); break; } - EVP_DigestInit(&ctx, EVP_md5()); + EVP_DigestInit(&ctx, EVP_get_digestbynid(crypto_nid)); EVP_DigestUpdate(&ctx, (u_char *)header, hdlen); EVP_DigestFinal(&ctx, dgst, &len); memcpy(&keyid, dgst, 4); keyid = ntohl(keyid); if (lifetime != 0) { - MD5auth_setkey(keyno, dgst, len); + MD5auth_setkey(keyno, crypto_nid, dgst, len); authtrust(keyno, lifetime); } -#ifdef DEBUG - if (debug > 1) - printf( - "session_key: %s > %s %08x %08x hash %08x life %lu\n", + DPRINTF(2, ("session_key: %s > %s %08x %08x hash %08x life %lu\n", stoa(srcadr), stoa(dstadr), keyno, - private, keyid, lifetime); -#endif + private, keyid, lifetime)); + return (keyid); } @@ -245,7 +251,7 @@ * * Returns * XEVNT_OK success - * XEVNT_PER host certificate expired + * XEVNT_ERR protocol error * * This routine constructs a pseudo-random sequence by repeatedly * hashing the session key starting from a given source address, @@ -265,12 +271,12 @@ struct value *vp; /* value pointer */ keyid_t keyid = 0; /* next key ID */ keyid_t cookie; /* private value */ - u_long lifetime; + long lifetime; u_int len, mpoll; int i; if (!dstadr) - return XEVNT_OK; + return XEVNT_ERR; /* * Allocate the key list if necessary. @@ -285,8 +291,10 @@ * NTP_MAXKEY. */ while (1) { - keyid = (ntp_random() + NTP_MAXKEY + 1) & ((1 << - sizeof(keyid_t)) - 1); + keyid = ntp_random() & 0xffffffff; + if (keyid <= NTP_MAXKEY) + continue; + if (authhavekey(keyid)) continue; break; @@ -300,7 +308,7 @@ * cookie if client mode or the host cookie if symmetric modes. */ mpoll = 1 << min(peer->ppoll, peer->hpoll); - lifetime = min(sys_automax, NTP_MAXSESSION * mpoll); + lifetime = min(1 << sys_automax, NTP_MAXSESSION * mpoll); if (peer->hmode == MODE_BROADCAST) cookie = 0; else @@ -309,10 +317,10 @@ peer->keylist[i] = keyid; peer->keynumber = i; keyid = session_key(&dstadr->sin, &peer->srcadr, keyid, - cookie, lifetime); + cookie, lifetime + mpoll); lifetime -= mpoll; if (auth_havekey(keyid) || keyid <= NTP_MAXKEY || - lifetime <= mpoll) + lifetime < 0 || tstamp == 0) break; } @@ -333,26 +341,21 @@ vp->vallen = htonl(sizeof(struct autokey)); vp->siglen = 0; if (tstamp != 0) { - if (tstamp < cinfo->first || tstamp > cinfo->last) - return (XEVNT_PER); - if (vp->sig == NULL) vp->sig = emalloc(sign_siglen); EVP_SignInit(&ctx, sign_digest); EVP_SignUpdate(&ctx, (u_char *)vp, 12); EVP_SignUpdate(&ctx, vp->ptr, sizeof(struct autokey)); - if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) - vp->siglen = htonl(len); - else - msyslog(LOG_ERR, "make_keys %s\n", - ERR_error_string(ERR_get_error(), NULL)); - peer->flags |= FLAG_ASSOC; + if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) { + vp->siglen = htonl(sign_siglen); + peer->flags |= FLAG_ASSOC; + } } #ifdef DEBUG if (debug) printf("make_keys: %d %08x %08x ts %u fs %u poll %d\n", - ntohl(ap->seq), ntohl(ap->key), cookie, - ntohl(vp->tstamp), ntohl(vp->fstamp), peer->hpoll); + peer->keynumber, keyid, cookie, ntohl(vp->tstamp), + ntohl(vp->fstamp), peer->hpoll); #endif return (XEVNT_OK); } @@ -368,6 +371,11 @@ * valid length and is verified. There are a few cases where some values * are believed even if the signature fails, but only if the proventic * bit is not set. + * + * Returns + * XEVNT_OK success + * XEVNT_ERR protocol error + * XEVNT_LEN bad field format or length */ int crypto_recv( @@ -379,6 +387,7 @@ u_int32 *pkt; /* receive packet pointer */ struct autokey *ap, *bp; /* autokey pointer */ struct exten *ep, *fp; /* extension pointers */ + struct cert_info *xinfo; /* certificate info pointer */ int has_mac; /* length of MAC field */ int authlen; /* offset of MAC field */ associd_t associd; /* association ID */ @@ -412,12 +421,12 @@ ep = (struct exten *)pkt; code = ntohl(ep->opcode) & 0xffff0000; len = ntohl(ep->opcode) & 0x0000ffff; - associd = (associd_t) ntohl(pkt[1]); + associd = (associd_t)ntohl(pkt[1]); rval = XEVNT_OK; #ifdef DEBUG if (debug) printf( - "crypto_recv: flags 0x%x ext offset %d len %u code 0x%x assocID %d\n", + "crypto_recv: flags 0x%x ext offset %d len %u code 0x%x associd %d\n", peer->crypto, authlen, len, code >> 16, associd); #endif @@ -427,21 +436,10 @@ * quietly ignore the packet. */ if (((code >> 24) & 0x3f) != CRYPTO_VN || len < 8) { - sys_unknownversion++; + sys_badlength++; code |= CRYPTO_ERROR; } - /* - * Little vulnerability bandage here. If a perp tosses a - * fake association ID over the fence, we better toss it - * out. Only the first one counts. - */ - if (code & CRYPTO_RESP) { - if (peer->assoc == 0) - peer->assoc = associd; - else if (peer->assoc != associd) - code |= CRYPTO_ERROR; - } if (len >= VALUE_LEN) { tstamp = ntohl(ep->tstamp); fstamp = ntohl(ep->fstamp); @@ -462,19 +460,26 @@ case CRYPTO_ASSOC: /* - * If the machine is running when this message - * arrives, the other fellow has reset and so - * must we. Otherwise, pass the extension field - * to the transmit side. + * If our state machine is running when this + * message arrives, the other fellow might have + * restarted. However, this could be an + * intruder, so just clamp the poll interval and + * find out for ourselves. Otherwise, pass the + * extension field to the transmit side. */ - if (peer->crypto) { + if (peer->crypto & CRYPTO_FLAG_CERT) { rval = XEVNT_ERR; break; } + if (peer->cmmd) { + if (peer->assoc != associd) { + rval = XEVNT_ERR; + break; + } + } fp = emalloc(len); memcpy(fp, ep, len); - temp32 = CRYPTO_RESP; - fp->opcode |= htonl(temp32); + fp->associd = htonl(peer->associd); peer->cmmd = fp; /* fall through */ @@ -484,67 +489,55 @@ * Discard the message if it has already been * stored or the message has been amputated. */ - if (peer->crypto) + if (peer->crypto) { + if (peer->assoc != associd) + rval = XEVNT_ERR; break; - + } if (vallen == 0 || vallen > MAXHOSTNAME || len < VALUE_LEN + vallen) { rval = XEVNT_LEN; break; } - - /* - * Check the identity schemes are compatible. If - * the client has PC, the server must have PC, - * in which case the server public key and - * identity are presumed valid, so we skip the - * certificate and identity exchanges and move - * immediately to the cookie exchange which - * confirms the server signature. - */ #ifdef DEBUG if (debug) printf( - "crypto_recv: ident host 0x%x server 0x%x\n", - crypto_flags, fstamp); -#endif - temp32 = (crypto_flags | ident_scheme) & - fstamp & CRYPTO_FLAG_MASK; + "crypto_recv: ident host 0x%x %d server 0x%x %d\n", + crypto_flags, peer->associd, fstamp, + peer->assoc); +#endif + temp32 = crypto_flags & CRYPTO_FLAG_MASK; + + /* + * If the client scheme is PC, the server scheme + * must be PC. The public key and identity are + * presumed valid, so we skip the certificate + * and identity exchanges and move immediately + * to the cookie exchange which confirms the + * server signature. + */ if (crypto_flags & CRYPTO_FLAG_PRIV) { if (!(fstamp & CRYPTO_FLAG_PRIV)) { rval = XEVNT_KEY; break; - - } else { - fstamp |= CRYPTO_FLAG_VALID | - CRYPTO_FLAG_VRFY | - CRYPTO_FLAG_SIGN; } - /* - * In symmetric modes it is an error if either - * peer requests identity and the other peer - * does not support it. - */ - } else if ((hismode == MODE_ACTIVE || hismode == - MODE_PASSIVE) && ((crypto_flags | fstamp) & - CRYPTO_FLAG_MASK) && !temp32) { - rval = XEVNT_KEY; - break; - /* - * It is an error if the client requests - * identity and the server does not support it. - */ - } else if (hismode == MODE_CLIENT && (fstamp & - CRYPTO_FLAG_MASK) && !temp32) { - rval = XEVNT_KEY; - break; - } + fstamp |= CRYPTO_FLAG_CERT | + CRYPTO_FLAG_VRFY | CRYPTO_FLAG_SIGN; /* - * Otherwise, the identity scheme(s) are those - * that both client and server support. + * It is an error if either peer supports + * identity, but the other does not. */ - fstamp = temp32 | (fstamp & ~CRYPTO_FLAG_MASK); + } else if (hismode == MODE_ACTIVE || hismode == + MODE_PASSIVE) { + if ((temp32 && !(fstamp & + CRYPTO_FLAG_MASK)) || + (!temp32 && (fstamp & + CRYPTO_FLAG_MASK))) { + rval = XEVNT_KEY; + break; + } + } /* * Discard the message if the signature digest @@ -560,19 +553,31 @@ /* * Save status word, host name and message - * digest/signature type. - */ + * digest/signature type. If this is from a + * broadcast and the association ID has changed, + * request the autokey values. + */ + peer->assoc = associd; + if (hismode == MODE_SERVER) + fstamp |= CRYPTO_FLAG_AUTO; + if (!(fstamp & CRYPTO_FLAG_TAI)) + fstamp |= CRYPTO_FLAG_LEAP; + RAND_bytes((u_char *)&peer->hcookie, 4); peer->crypto = fstamp; peer->digest = dp; + if (peer->subject != NULL) + free(peer->subject); peer->subject = emalloc(vallen + 1); memcpy(peer->subject, ep->pkt, vallen); peer->subject[vallen] = '\0'; + if (peer->issuer != NULL) + free(peer->issuer); peer->issuer = emalloc(vallen + 1); strcpy(peer->issuer, peer->subject); - temp32 = (fstamp >> 16) & 0xffff; snprintf(statstr, NTP_MAXSTRLEN, - "flags 0x%x host %s signature %s", fstamp, - peer->subject, OBJ_nid2ln(temp32)); + "assoc %d %d host %s %s", peer->associd, + peer->assoc, peer->subject, + OBJ_nid2ln(temp32)); record_crypto_stats(&peer->srcadr, statstr); #ifdef DEBUG if (debug) @@ -590,8 +595,11 @@ case CRYPTO_CERT | CRYPTO_RESP: /* - * Discard the message if invalid. + * Discard the message if empty or invalid. */ + if (len < VALUE_LEN) + break; + if ((rval = crypto_verify(ep, NULL, peer)) != XEVNT_OK) break; @@ -599,26 +607,16 @@ /* * Scan the certificate list to delete old * versions and link the newest version first on - * the list. + * the list. Then, verify the signature. If the + * certificate is bad or missing, just ignore + * it. */ - if ((rval = cert_install(ep, peer)) != XEVNT_OK) + if ((xinfo = cert_install(ep, peer)) == NULL) { + rval = XEVNT_CRT; + break; + } + if ((rval = cert_hike(peer, xinfo)) != XEVNT_OK) break; - - /* - * If we snatch the certificate before the - * server certificate has been signed by its - * server, it will be self signed. When it is, - * we chase the certificate issuer, which the - * server has, and keep going until a self - * signed trusted certificate is found. Be sure - * to update the issuer field, since it may - * change. - */ - if (peer->issuer != NULL) - free(peer->issuer); - peer->issuer = emalloc(strlen(cinfo->issuer) + - 1); - strcpy(peer->issuer, cinfo->issuer); /* * We plug in the public key and lifetime from @@ -628,17 +626,17 @@ * signature/digest NID. */ if (peer->pkey == NULL) { - ptr = (u_char *)cinfo->cert.ptr; + ptr = (u_char *)xinfo->cert.ptr; cert = d2i_X509(NULL, &ptr, - ntohl(cinfo->cert.vallen)); + ntohl(xinfo->cert.vallen)); peer->pkey = X509_get_pubkey(cert); X509_free(cert); } peer->flash &= ~TEST8; - temp32 = cinfo->nid; + temp32 = xinfo->nid; snprintf(statstr, NTP_MAXSTRLEN, - "cert %s 0x%x %s (%u) fs %u", - cinfo->subject, cinfo->flags, + "cert %s %s 0x%x %s (%u) fs %u", + xinfo->subject, xinfo->issuer, xinfo->flags, OBJ_nid2ln(temp32), temp32, ntohl(ep->fstamp)); record_crypto_stats(&peer->srcadr, statstr); @@ -649,45 +647,38 @@ break; /* - * Schnorr (IFF)identity scheme. This scheme is designed - * for use with shared secret group keys and where the - * certificate may be generated by a third party. The - * client sends a challenge to the server, which - * performs a calculation and returns the result. A - * positive result is possible only if both client and + * Schnorr (IFF) identity scheme. This scheme is + * designed for use with shared secret server group keys + * and where the certificate may be generated by a third + * party. The client sends a challenge to the server, + * which performs a calculation and returns the result. + * A positive result is possible only if both client and * server contain the same secret group key. */ case CRYPTO_IFF | CRYPTO_RESP: /* - * Discard the message if invalid or certificate - * trail not trusted. + * Discard the message if invalid. */ - if (!(peer->crypto & CRYPTO_FLAG_VALID)) { - rval = XEVNT_ERR; - break; - } if ((rval = crypto_verify(ep, NULL, peer)) != XEVNT_OK) break; /* - * If the the challenge matches the response, - * the certificate public key, as well as the - * server public key, signatyre and identity are + * If the challenge matches the response, the + * server public key, signature and identity are * all verified at the same time. The server is * declared trusted, so we skip further - * certificate stages and move immediately to - * the cookie stage. + * certificate exchanges and move immediately to + * the cookie exchange. */ if ((rval = crypto_iff(ep, peer)) != XEVNT_OK) break; - peer->crypto |= CRYPTO_FLAG_VRFY | - CRYPTO_FLAG_PROV; + peer->crypto |= CRYPTO_FLAG_VRFY; peer->flash &= ~TEST8; - snprintf(statstr, NTP_MAXSTRLEN, "iff fs %u", - ntohl(ep->fstamp)); + snprintf(statstr, NTP_MAXSTRLEN, "iff %s fs %u", + peer->issuer, ntohl(ep->fstamp)); record_crypto_stats(&peer->srcadr, statstr); #ifdef DEBUG if (debug) @@ -708,34 +699,27 @@ case CRYPTO_GQ | CRYPTO_RESP: /* - * Discard the message if invalid or certificate - * trail not trusted. + * Discard the message if invalid */ - if (!(peer->crypto & CRYPTO_FLAG_VALID)) { - rval = XEVNT_ERR; - break; - } if ((rval = crypto_verify(ep, NULL, peer)) != XEVNT_OK) break; /* - * If the the challenge matches the response, - * the certificate public key, as well as the - * server public key, signatyre and identity are + * If the challenge matches the response, the + * server public key, signature and identity are * all verified at the same time. The server is * declared trusted, so we skip further - * certificate stages and move immediately to - * the cookie stage. + * certificate exchanges and move immediately to + * the cookie exchange. */ if ((rval = crypto_gq(ep, peer)) != XEVNT_OK) break; - peer->crypto |= CRYPTO_FLAG_VRFY | - CRYPTO_FLAG_PROV; + peer->crypto |= CRYPTO_FLAG_VRFY; peer->flash &= ~TEST8; - snprintf(statstr, NTP_MAXSTRLEN, "gq fs %u", - ntohl(ep->fstamp)); + snprintf(statstr, NTP_MAXSTRLEN, "gq %s fs %u", + peer->issuer, ntohl(ep->fstamp)); record_crypto_stats(&peer->srcadr, statstr); #ifdef DEBUG if (debug) @@ -744,39 +728,38 @@ break; /* - * MV + * Mu-Varadharajan (MV) identity scheme. This scheme is + * designed for use with three levels of trust, trusted + * host, server and client. The trusted host key is + * opaque to servers and clients; the server keys are + * opaque to clients and each client key is different. + * Client keys can be revoked without requiring new key + * generations. */ case CRYPTO_MV | CRYPTO_RESP: /* - * Discard the message if invalid or certificate - * trail not trusted. + * Discard the message if invalid. */ - if (!(peer->crypto & CRYPTO_FLAG_VALID)) { - rval = XEVNT_ERR; - break; - } if ((rval = crypto_verify(ep, NULL, peer)) != XEVNT_OK) break; /* - * If the the challenge matches the response, - * the certificate public key, as well as the - * server public key, signatyre and identity are + * If the challenge matches the response, the + * server public key, signature and identity are * all verified at the same time. The server is * declared trusted, so we skip further - * certificate stages and move immediately to - * the cookie stage. + * certificate exchanges and move immediately to + * the cookie exchange. */ if ((rval = crypto_mv(ep, peer)) != XEVNT_OK) break; - peer->crypto |= CRYPTO_FLAG_VRFY | - CRYPTO_FLAG_PROV; + peer->crypto |= CRYPTO_FLAG_VRFY; peer->flash &= ~TEST8; - snprintf(statstr, NTP_MAXSTRLEN, "mv fs %u", - ntohl(ep->fstamp)); + snprintf(statstr, NTP_MAXSTRLEN, "mv %s fs %u", + peer->issuer, ntohl(ep->fstamp)); record_crypto_stats(&peer->srcadr, statstr); #ifdef DEBUG if (debug) @@ -784,60 +767,6 @@ #endif break; - /* - * Cookie request in symmetric modes. Roll a random - * cookie and install in symmetric mode. Encrypt for the - * response, which is transmitted later. - */ - case CRYPTO_COOK: - - /* - * Discard the message if invalid or certificate - * trail not trusted. - */ - if (!(peer->crypto & CRYPTO_FLAG_VALID)) { - rval = XEVNT_ERR; - break; - } - if ((rval = crypto_verify(ep, NULL, peer)) != - XEVNT_OK) - break; - - /* - * Pass the extension field to the transmit - * side. If already agreed, walk away. - */ - fp = emalloc(len); - memcpy(fp, ep, len); - temp32 = CRYPTO_RESP; - fp->opcode |= htonl(temp32); - peer->cmmd = fp; - if (peer->crypto & CRYPTO_FLAG_AGREE) { - peer->flash &= ~TEST8; - break; - } - - /* - * Install cookie values and light the cookie - * bit. The transmit side will pick up and - * encrypt it for the response. - */ - key_expire(peer); - peer->cookval.tstamp = ep->tstamp; - peer->cookval.fstamp = ep->fstamp; - RAND_bytes((u_char *)&peer->pcookie, 4); - peer->crypto &= ~CRYPTO_FLAG_AUTO; - peer->crypto |= CRYPTO_FLAG_AGREE; - peer->flash &= ~TEST8; - snprintf(statstr, NTP_MAXSTRLEN, "cook %x ts %u fs %u", - peer->pcookie, ntohl(ep->tstamp), - ntohl(ep->fstamp)); - record_crypto_stats(&peer->srcadr, statstr); -#ifdef DEBUG - if (debug) - printf("crypto_recv: %s\n", statstr); -#endif - break; /* * Cookie response in client and symmetric modes. If the @@ -847,14 +776,10 @@ case CRYPTO_COOK | CRYPTO_RESP: /* - * Discard the message if invalid or identity - * not confirmed or signature not verified with - * respect to the cookie values. + * Discard the message if invalid or signature + * not verified with respect to the cookie + * values. */ - if (!(peer->crypto & CRYPTO_FLAG_VRFY)) { - rval = XEVNT_ERR; - break; - } if ((rval = crypto_verify(ep, &peer->cookval, peer)) != XEVNT_OK) break; @@ -863,13 +788,17 @@ * Decrypt the cookie, hunting all the time for * errors. */ - if (vallen == (u_int) EVP_PKEY_size(host_pkey)) { - RSA_private_decrypt(vallen, + if (vallen == (u_int)EVP_PKEY_size(host_pkey)) { + if (RSA_private_decrypt(vallen, (u_char *)ep->pkt, (u_char *)&temp32, host_pkey->pkey.rsa, - RSA_PKCS1_OAEP_PADDING); - cookie = ntohl(temp32); + RSA_PKCS1_OAEP_PADDING) <= 0) { + rval = XEVNT_CKY; + break; + } else { + cookie = ntohl(temp32); + } } else { rval = XEVNT_CKY; break; @@ -881,22 +810,16 @@ * are done here. */ key_expire(peer); - peer->cookval.tstamp = ep->tstamp; - peer->cookval.fstamp = ep->fstamp; - if (peer->crypto & CRYPTO_FLAG_AGREE) - peer->pcookie ^= cookie; + if (hismode == MODE_ACTIVE || hismode == + MODE_PASSIVE) + peer->pcookie = peer->hcookie ^ cookie; else peer->pcookie = cookie; - if (peer->hmode == MODE_CLIENT && - !(peer->cast_flags & MDF_BCLNT)) - peer->crypto |= CRYPTO_FLAG_AUTO; - else - peer->crypto &= ~CRYPTO_FLAG_AUTO; - peer->crypto |= CRYPTO_FLAG_AGREE; + peer->crypto |= CRYPTO_FLAG_COOK; peer->flash &= ~TEST8; - snprintf(statstr, NTP_MAXSTRLEN, "cook %x ts %u fs %u", - peer->pcookie, ntohl(ep->tstamp), - ntohl(ep->fstamp)); + snprintf(statstr, NTP_MAXSTRLEN, + "cook %x ts %u fs %u", peer->pcookie, + ntohl(ep->tstamp), ntohl(ep->fstamp)); record_crypto_stats(&peer->srcadr, statstr); #ifdef DEBUG if (debug) @@ -917,22 +840,32 @@ case CRYPTO_AUTO | CRYPTO_RESP: /* - * Discard the message if invalid or identity - * not confirmed or signature not verified with - * respect to the receive autokey values. + * Discard the message if invalid or signature + * not verified with respect to the receive + * autokey values. */ - if (!(peer->crypto & CRYPTO_FLAG_VRFY)) { - rval = XEVNT_ERR; - break; - } if ((rval = crypto_verify(ep, &peer->recval, - peer)) != XEVNT_OK) + peer)) != XEVNT_OK) + break; + + /* + * Discard the message if a broadcast client and + * the association ID does not match. This might + * happen if a broacast server restarts the + * protocol. A protocol restart will occur at + * the next ASSOC message. + */ + if (peer->cast_flags & MDF_BCLNT && + peer->assoc != associd) break; /* * Install autokey values and light the * autokey bit. This is not hard. */ + if (ep->tstamp == 0) + break; + if (peer->recval.ptr == NULL) peer->recval.ptr = emalloc(sizeof(struct autokey)); @@ -945,7 +878,7 @@ peer->pkeyid = bp->key; peer->crypto |= CRYPTO_FLAG_AUTO; peer->flash &= ~TEST8; - snprintf(statstr, NTP_MAXSTRLEN, + snprintf(statstr, NTP_MAXSTRLEN, "auto seq %d key %x ts %u fs %u", bp->seq, bp->key, ntohl(ep->tstamp), ntohl(ep->fstamp)); @@ -966,13 +899,8 @@ case CRYPTO_SIGN | CRYPTO_RESP: /* - * Discard the message if invalid or not - * proventic. + * Discard the message if invalid. */ - if (!(peer->crypto & CRYPTO_FLAG_PROV)) { - rval = XEVNT_ERR; - break; - } if ((rval = crypto_verify(ep, NULL, peer)) != XEVNT_OK) break; @@ -982,15 +910,16 @@ * versions and link the newest version first on * the list. */ - if ((rval = cert_install(ep, peer)) != XEVNT_OK) + if ((xinfo = cert_install(ep, peer)) == NULL) { + rval = XEVNT_CRT; break; - + } peer->crypto |= CRYPTO_FLAG_SIGN; peer->flash &= ~TEST8; - temp32 = cinfo->nid; + temp32 = xinfo->nid; snprintf(statstr, NTP_MAXSTRLEN, - "sign %s 0x%x %s (%u) fs %u", - cinfo->issuer, cinfo->flags, + "sign %s %s 0x%x %s (%u) fs %u", + xinfo->subject, xinfo->issuer, xinfo->flags, OBJ_nid2ln(temp32), temp32, ntohl(ep->fstamp)); record_crypto_stats(&peer->srcadr, statstr); @@ -1001,81 +930,50 @@ break; /* - * Install leapseconds table in symmetric modes. This - * table is proventicated to the NIST primary servers, - * either by copying the file containing the table from - * a NIST server to a trusted server or directly using - * this protocol. While the entire table is installed at - * the server, presently only the current TAI offset is - * provided via the kernel to other applications. + * Install leapseconds values. While the leapsecond + * values epoch, TAI offset and values expiration epoch + * are retained, only the current TAI offset is provided + * via the kernel to other applications. */ - case CRYPTO_TAI: + case CRYPTO_LEAP | CRYPTO_RESP: /* - * Discard the message if invalid. + * Discard the message if invalid. We can't + * compare the value timestamps here, as they + * can be updated by different servers. */ if ((rval = crypto_verify(ep, NULL, peer)) != XEVNT_OK) break; /* - * Pass the extension field to the transmit - * side. Continue below if a leapseconds table - * accompanies the message. - */ - fp = emalloc(len); - memcpy(fp, ep, len); - temp32 = CRYPTO_RESP; - fp->opcode |= htonl(temp32); - peer->cmmd = fp; - if (len <= VALUE_LEN) { - peer->flash &= ~TEST8; - break; - } - /* fall through */ - - case CRYPTO_TAI | CRYPTO_RESP: - - /* - * If this is a response, discard the message if - * signature not verified with respect to the - * leapsecond table values. - */ - if (peer->cmmd == NULL) { - if ((rval = crypto_verify(ep, - &peer->tai_leap, peer)) != XEVNT_OK) - break; - } - - /* - * Initialize peer variables with latest update. + * If the packet leap values are more recent + * than the stored ones, install the new leap + * values and recompute the signatures. */ - peer->tai_leap.tstamp = ep->tstamp; - peer->tai_leap.fstamp = ep->fstamp; - peer->tai_leap.vallen = ep->vallen; + if (ntohl(ep->pkt[2]) > leap_expire) { + char tbuf[80], str1 [20], str2[20]; - /* - * Install the new table if there is no stored - * table or the new table is more recent than - * the stored table. Since a filestamp may have - * changed, recompute the signatures. - */ - if (ntohl(peer->tai_leap.fstamp) > - ntohl(tai_leap.fstamp)) { + tai_leap.tstamp = ep->tstamp; tai_leap.fstamp = ep->fstamp; tai_leap.vallen = ep->vallen; - if (tai_leap.ptr != NULL) - free(tai_leap.ptr); - tai_leap.ptr = emalloc(vallen); - memcpy(tai_leap.ptr, ep->pkt, vallen); + leap_tai = ntohl(ep->pkt[0]); + leap_sec = ntohl(ep->pkt[1]); + leap_expire = ntohl(ep->pkt[2]); crypto_update(); + strcpy(str1, fstostr(leap_sec)); + strcpy(str2, fstostr(leap_expire)); + snprintf(tbuf, sizeof(tbuf), + "%d leap %s expire %s", leap_tai, str1, + str2); + report_event(EVNT_TAI, peer, tbuf); } - crypto_flags |= CRYPTO_FLAG_TAI; peer->crypto |= CRYPTO_FLAG_LEAP; peer->flash &= ~TEST8; snprintf(statstr, NTP_MAXSTRLEN, - "leap %u ts %u fs %u", vallen, - ntohl(ep->tstamp), ntohl(ep->fstamp)); + "leap TAI offset %d at %u expire %u fs %u", + ntohl(ep->pkt[0]), ntohl(ep->pkt[1]), + ntohl(ep->pkt[2]), ntohl(ep->fstamp)); record_crypto_stats(&peer->srcadr, statstr); #ifdef DEBUG if (debug) @@ -1087,13 +985,14 @@ * We come here in symmetric modes for miscellaneous * commands that have value fields but are processed on * the transmit side. All we need do here is check for - * valid field length. Remaining checks are below and on - * the transmit side. + * valid field length. Note that ASSOC is handled + * separately. */ case CRYPTO_CERT: case CRYPTO_IFF: case CRYPTO_GQ: case CRYPTO_MV: + case CRYPTO_COOK: case CRYPTO_SIGN: if (len < VALUE_LEN) { rval = XEVNT_LEN; @@ -1102,49 +1001,39 @@ /* fall through */ /* - * We come here for miscellaneous requests and unknown - * requests and responses. If an unknown response or - * error, forget it. If a request, save the extension - * field for later. Unknown requests will be caught on - * the transmit side. + * We come here in symmetric modes for requests + * requiring a response (above plus AUTO and LEAP) and + * for responses. If a request, save the extension field + * for later; invalid requests will be caught on the + * transmit side. If an error or invalid response, + * declare a protocol error. */ default: if (code & (CRYPTO_RESP | CRYPTO_ERROR)) { rval = XEVNT_ERR; - } else if ((rval = crypto_verify(ep, NULL, - peer)) == XEVNT_OK) { + } else if (peer->cmmd == NULL) { fp = emalloc(len); memcpy(fp, ep, len); - temp32 = CRYPTO_RESP; - fp->opcode |= htonl(temp32); peer->cmmd = fp; } } /* - * We don't log length/format/timestamp errors and - * duplicates, which are log clogging vulnerabilities. * The first error found terminates the extension field - * scan and we return the laundry to the caller. A - * length/format/timestamp error on transmit is - * cheerfully ignored, as the message is not sent. + * scan and we return the laundry to the caller. */ - if (rval > XEVNT_TSP) { + if (rval != XEVNT_OK) { snprintf(statstr, NTP_MAXSTRLEN, - "error %x opcode %x ts %u fs %u", rval, - code, tstamp, fstamp); + "%04x %d %02x %s", htonl(ep->opcode), + associd, rval, eventstr(rval)); record_crypto_stats(&peer->srcadr, statstr); - report_event(rval, peer); #ifdef DEBUG if (debug) printf("crypto_recv: %s\n", statstr); #endif - break; - - } else if (rval > XEVNT_OK && (code & CRYPTO_RESP)) { - rval = XEVNT_OK; + return (rval); } - authlen += len; + authlen += (len + 3) / 4 * 4; } return (rval); } @@ -1158,30 +1047,38 @@ * autokey information, in which case the caller has to provide the * association ID to match the association. * - * Returns length of extension field. + * Side effect: update the packet offset. + * + * Errors + * XEVNT_OK success + * XEVNT_CRT bad or missing certificate + * XEVNT_ERR protocol error + * XEVNT_LEN bad field format or length + * XEVNT_PER host certificate expired */ int crypto_xmit( + struct peer *peer, /* peer structure pointer */ struct pkt *xpkt, /* transmit packet pointer */ - struct sockaddr_storage *srcadr_sin, /* active runway */ + struct recvbuf *rbufp, /* receive buffer pointer */ int start, /* offset to extension field */ struct exten *ep, /* extension pointer */ keyid_t cookie /* session cookie */ ) { + struct exten *fp; /* extension pointers */ + struct cert_info *cp, *xp, *yp; /* cert info/value pointer */ + sockaddr_u *srcadr_sin; /* source address */ u_int32 *pkt; /* packet pointer */ - struct peer *peer; /* peer structure pointer */ u_int opcode; /* extension field opcode */ - struct exten *fp; /* extension pointers */ - struct cert_info *cp, *xp; /* certificate info/value pointer */ char certname[MAXHOSTNAME + 1]; /* subject name buffer */ char statstr[NTP_MAXSTRLEN]; /* statistics for filegen */ tstamp_t tstamp; u_int vallen; - u_int len; struct value vtemp; associd_t associd; int rval; + int len; keyid_t tcookie; /* @@ -1192,9 +1089,17 @@ pkt = (u_int32 *)xpkt + start / 4; fp = (struct exten *)pkt; opcode = ntohl(ep->opcode); + if (peer != NULL) { + srcadr_sin = &peer->srcadr; + if (!(opcode & CRYPTO_RESP)) + peer->opcode = ep->opcode; + } else { + srcadr_sin = &rbufp->recv_srcadr; + } associd = (associd_t) ntohl(ep->associd); - fp->associd = htonl(associd); len = 8; + fp->opcode = htonl((opcode & 0xffff0000) | len); + fp->associd = ep->associd; rval = XEVNT_OK; tstamp = crypto_time(); switch (opcode & 0xffff0000) { @@ -1204,16 +1109,12 @@ * host name. Note, this message is not signed and the filestamp * contains only the status word. */ + case CRYPTO_ASSOC: case CRYPTO_ASSOC | CRYPTO_RESP: - len += crypto_send(fp, &hostval); + len = crypto_send(fp, &hostval, start); fp->fstamp = htonl(crypto_flags); break; - case CRYPTO_ASSOC: - len += crypto_send(fp, &hostval); - fp->fstamp = htonl(crypto_flags | ident_scheme); - break; - /* * Send certificate request. Use the values from the extension * field. @@ -1224,21 +1125,36 @@ vtemp.fstamp = ep->fstamp; vtemp.vallen = ep->vallen; vtemp.ptr = (u_char *)ep->pkt; - len += crypto_send(fp, &vtemp); + len = crypto_send(fp, &vtemp, start); break; /* - * Send certificate response or sign request. Use the values - * from the certificate cache. If the request contains no - * subject name, assume the name of this host. This is for - * backwards compatibility. Private certificates are never sent. + * Send sign request. Use the host certificate, which is self- + * signed and may or may not be trusted. */ case CRYPTO_SIGN: + if (tstamp < cert_host->first || tstamp > + cert_host->last) + rval = XEVNT_PER; + else + len = crypto_send(fp, &cert_host->cert, start); + break; + + /* + * Send certificate response. Use the name in the extension + * field to find the certificate in the cache. If the request + * contains no subject name, assume the name of this host. This + * is for backwards compatibility. Private certificates are + * never sent. + * + * There may be several certificates matching the request. First + * choice is a self-signed trusted certificate; second choice is + * any certificate signed by another host. There is no third + * choice. + */ case CRYPTO_CERT | CRYPTO_RESP: vallen = ntohl(ep->vallen); - if (vallen == 8) { - strcpy(certname, sys_hostname); - } else if (vallen == 0 || vallen > MAXHOSTNAME) { + if (vallen == 0 || vallen > MAXHOSTNAME) { rval = XEVNT_LEN; break; @@ -1248,64 +1164,60 @@ } /* - * Find all certificates with matching subject. If a - * self-signed, trusted certificate is found, use that. - * If not, use the first one with matching subject. A - * private certificate is never divulged or signed. + * Find all public valid certificates with matching + * subject. If a self-signed, trusted certificate is + * found, use that certificate. If not, use the last non + * self-signed certificate. */ - xp = NULL; + xp = yp = NULL; for (cp = cinfo; cp != NULL; cp = cp->link) { - if (cp->flags & CERT_PRIV) + if (cp->flags & (CERT_PRIV | CERT_ERROR)) continue; - if (strcmp(certname, cp->subject) == 0) { - if (xp == NULL) - xp = cp; - if (strcmp(certname, cp->issuer) == - 0 && cp->flags & CERT_TRUST) { - xp = cp; - break; - } - } + if (strcmp(certname, cp->subject) != 0) + continue; + + if (strcmp(certname, cp->issuer) != 0) + yp = cp; + else if (cp ->flags & CERT_TRUST) + xp = cp; + continue; } /* - * Be careful who you trust. If not yet synchronized, - * give back an empty response. If certificate not found - * or beyond the lifetime, return an error. This is to - * avoid a bad dude trying to get an expired certificate - * re-signed. Otherwise, send it. + * Be careful who you trust. If the certificate is not + * found, return an empty response. Note that we dont + * enforce lifetimes here. * - * Note the timestamp and filestamp are taken from the + * The timestamp and filestamp are taken from the * certificate value structure. For all certificates the * timestamp is the latest signature update time. For * host and imported certificates the filestamp is the * creation epoch. For signed certificates the filestamp * is the creation epoch of the trusted certificate at - * the base of the certificate trail. In principle, this + * the root of the certificate trail. In principle, this * allows strong checking for signature masquerade. */ + if (xp == NULL) + xp = yp; + if (xp == NULL) + break; + if (tstamp == 0) break; - if (xp == NULL) - rval = XEVNT_CRT; - else if (tstamp < xp->first || tstamp > xp->last) - rval = XEVNT_SRV; - else - len += crypto_send(fp, &xp->cert); + len = crypto_send(fp, &xp->cert, start); break; /* * Send challenge in Schnorr (IFF) identity scheme. */ case CRYPTO_IFF: - if ((peer = findpeerbyassoc(ep->pkt[0])) == NULL) { - rval = XEVNT_ERR; - break; - } + if (peer == NULL) + break; /* hack attack */ + if ((rval = crypto_alice(peer, &vtemp)) == XEVNT_OK) { - len += crypto_send(fp, &vtemp); + len = crypto_send(fp, &vtemp, start); value_free(&vtemp); } break; @@ -1315,7 +1227,7 @@ */ case CRYPTO_IFF | CRYPTO_RESP: if ((rval = crypto_bob(ep, &vtemp)) == XEVNT_OK) { - len += crypto_send(fp, &vtemp); + len = crypto_send(fp, &vtemp, start); value_free(&vtemp); } break; @@ -1324,12 +1236,11 @@ * Send challenge in Guillou-Quisquater (GQ) identity scheme. */ case CRYPTO_GQ: - if ((peer = findpeerbyassoc(ep->pkt[0])) == NULL) { - rval = XEVNT_ERR; - break; - } + if (peer == NULL) + break; /* hack attack */ + if ((rval = crypto_alice2(peer, &vtemp)) == XEVNT_OK) { - len += crypto_send(fp, &vtemp); + len = crypto_send(fp, &vtemp, start); value_free(&vtemp); } break; @@ -1339,7 +1250,7 @@ */ case CRYPTO_GQ | CRYPTO_RESP: if ((rval = crypto_bob2(ep, &vtemp)) == XEVNT_OK) { - len += crypto_send(fp, &vtemp); + len = crypto_send(fp, &vtemp, start); value_free(&vtemp); } break; @@ -1348,12 +1259,11 @@ * Send challenge in MV identity scheme. */ case CRYPTO_MV: - if ((peer = findpeerbyassoc(ep->pkt[0])) == NULL) { - rval = XEVNT_ERR; - break; - } + if (peer == NULL) + break; /* hack attack */ + if ((rval = crypto_alice3(peer, &vtemp)) == XEVNT_OK) { - len += crypto_send(fp, &vtemp); + len = crypto_send(fp, &vtemp, start); value_free(&vtemp); } break; @@ -1363,7 +1273,7 @@ */ case CRYPTO_MV | CRYPTO_RESP: if ((rval = crypto_bob3(ep, &vtemp)) == XEVNT_OK) { - len += crypto_send(fp, &vtemp); + len = crypto_send(fp, &vtemp, start); value_free(&vtemp); } break; @@ -1377,9 +1287,10 @@ * invalid or contains an unverified signature. */ case CRYPTO_SIGN | CRYPTO_RESP: - if ((rval = cert_sign(ep, &vtemp)) == XEVNT_OK) - len += crypto_send(fp, &vtemp); - value_free(&vtemp); + if ((rval = cert_sign(ep, &vtemp)) == XEVNT_OK) { + len = crypto_send(fp, &vtemp, start); + value_free(&vtemp); + } break; /* @@ -1387,7 +1298,7 @@ * key. */ case CRYPTO_COOK: - len += crypto_send(fp, &pubkey); + len = crypto_send(fp, &pubkey, start); break; /* @@ -1399,19 +1310,15 @@ rval = XEVNT_LEN; break; } - if (PKT_MODE(xpkt->li_vn_mode) == MODE_SERVER) { + if (peer == NULL) tcookie = cookie; - } else { - if ((peer = findpeerbyassoc(associd)) == NULL) { - rval = XEVNT_ERR; - break; - } - tcookie = peer->pcookie; - } + else + tcookie = peer->hcookie; if ((rval = crypto_encrypt(ep, &vtemp, &tcookie)) == - XEVNT_OK) - len += crypto_send(fp, &vtemp); - value_free(&vtemp); + XEVNT_OK) { + len = crypto_send(fp, &vtemp, start); + value_free(&vtemp); + } break; /* @@ -1422,28 +1329,28 @@ * old message, in which case light the error bit. */ case CRYPTO_AUTO | CRYPTO_RESP: - if ((peer = findpeerbyassoc(associd)) == NULL) { - rval = XEVNT_ERR; - break; + if (peer == NULL) { + if ((peer = findpeerbyassoc(associd)) == NULL) { + rval = XEVNT_ERR; + break; + } } peer->flags &= ~FLAG_ASSOC; - len += crypto_send(fp, &peer->sndval); + len = crypto_send(fp, &peer->sndval, start); break; /* - * Send leapseconds table and signature. Use the values from the - * tai structure. If no table has been loaded, just send an + * Send leapseconds values and signature. Use the values from + * the tai structure. If no table has been loaded, just send an * empty request. */ - case CRYPTO_TAI: - case CRYPTO_TAI | CRYPTO_RESP: - if (crypto_flags & CRYPTO_FLAG_TAI) - len += crypto_send(fp, &tai_leap); + case CRYPTO_LEAP | CRYPTO_RESP: + len = crypto_send(fp, &tai_leap, start); break; /* - * Default - Fall through for requests; for unknown responses, - * flag as error. + * Default - Send a valid command for unknown requests; send + * an error response for unknown resonses. */ default: if (opcode & CRYPTO_RESP) @@ -1455,11 +1362,15 @@ * puppy; if a response, return so the sender can flame, too. */ if (rval != XEVNT_OK) { - opcode |= CRYPTO_ERROR; + u_int32 uint32; + + uint32 = CRYPTO_ERROR; + opcode |= uint32; + fp->opcode |= htonl(uint32); snprintf(statstr, NTP_MAXSTRLEN, - "error %x opcode %x", rval, opcode); + "%04x %d %02x %s", opcode, associd, rval, + eventstr(rval)); record_crypto_stats(srcadr_sin, statstr); - report_event(rval, NULL); #ifdef DEBUG if (debug) printf("crypto_xmit: %s\n", statstr); @@ -1467,17 +1378,10 @@ if (!(opcode & CRYPTO_RESP)) return (0); } - - /* - * Round up the field length to a multiple of 8 bytes and save - * the request code and length. - */ - len = ((len + 7) / 8) * 8; - fp->opcode = htonl((opcode & 0xffff0000) | len); #ifdef DEBUG if (debug) printf( - "crypto_xmit: flags 0x%x ext offset %d len %u code 0x%x assocID %d\n", + "crypto_xmit: flags 0x%x offset %d len %d code 0x%x associd %d\n", crypto_flags, start, len, opcode >> 16, associd); #endif return (len); @@ -1485,17 +1389,17 @@ /* - * crypto_verify - parse and verify the extension field and value + * crypto_verify - verify the extension field value and signature * * Returns * XEVNT_OK success - * XEVNT_LEN bad field format or length - * XEVNT_TSP bad timestamp + * XEVNT_ERR protocol error * XEVNT_FSP bad filestamp + * XEVNT_LEN bad field format or length * XEVNT_PUB bad or missing public key * XEVNT_SGL bad signature length * XEVNT_SIG signature not verified - * XEVNT_ERR protocol error + * XEVNT_TSP bad timestamp */ static int crypto_verify( @@ -1514,38 +1418,46 @@ int i; /* - * We require valid opcode and field lengths, timestamp, - * filestamp, public key, digest, signature length and - * signature, where relevant. Note that preliminary length - * checks are done in the main loop. + * We are extremely parannoyed. We require valid opcode, length, + * association ID, timestamp, filestamp, public key, digest, + * signature length and signature, where relevant. Note that + * preliminary length checks are done in the main loop. */ len = ntohl(ep->opcode) & 0x0000ffff; opcode = ntohl(ep->opcode) & 0xffff0000; /* - * Check for valid operation code and protocol. The opcode must - * not have the error bit set. If a response, it must have a - * value header. If a request and does not contain a value - * header, no need for further checking. + * Check for valid value header, association ID and extension + * field length. Remember, it is not an error to receive an + * unsolicited response; however, the response ID must match + * the association ID. */ if (opcode & CRYPTO_ERROR) return (XEVNT_ERR); - if (opcode & CRYPTO_RESP) { - if (len < VALUE_LEN) - return (XEVNT_LEN); + if (len < VALUE_LEN) + return (XEVNT_LEN); + + if (opcode == (CRYPTO_AUTO | CRYPTO_RESP) && (peer->pmode == + MODE_BROADCAST || (peer->cast_flags & MDF_BCLNT))) { + if (ntohl(ep->associd) != peer->assoc) + return (XEVNT_ERR); } else { - if (len < VALUE_LEN) - return (XEVNT_OK); + if (ntohl(ep->associd) != peer->associd) + return (XEVNT_ERR); } /* - * We have a value header. Check for valid field lengths. The - * field length must be long enough to contain the value header, - * value and signature. Note both the value and signature fields - * are rounded up to the next word. + * We have a valid value header. Check for valid value and + * signature field lengths. The extension field length must be + * long enough to contain the value header, value and signature. + * Note both the value and signature field lengths are rounded + * up to the next word (4 octets). */ vallen = ntohl(ep->vallen); + if (vallen == 0) + return (XEVNT_LEN); + i = (vallen + 3) / 4; siglen = ntohl(ep->pkt[i++]); if (len < VALUE_LEN + ((vallen + 3) / 4) * 4 + ((siglen + 3) / @@ -1553,32 +1465,16 @@ return (XEVNT_LEN); /* - * Punt if this is a response with no data. Punt if this is a - * request and a previous response is pending. - */ - if (opcode & CRYPTO_RESP) { - if (vallen == 0) - return (XEVNT_LEN); - } else { - if (peer->cmmd != NULL) - return (XEVNT_LEN); - } - - /* * Check for valid timestamp and filestamp. If the timestamp is * zero, the sender is not synchronized and signatures are - * disregarded. If not, the timestamp must not precede the + * not possible. If nonzero the timestamp must not precede the * filestamp. The timestamp and filestamp must not precede the - * corresponding values in the value structure, if present. Once - * the autokey values have been installed, the timestamp must - * always be later than the corresponding value in the value - * structure. Duplicate timestamps are illegal once the cookie - * has been validated. - */ + * corresponding values in the value structure, if present. + */ tstamp = ntohl(ep->tstamp); fstamp = ntohl(ep->fstamp); if (tstamp == 0) - return (XEVNT_OK); + return (XEVNT_TSP); if (tstamp < fstamp) return (XEVNT_TSP); @@ -1586,15 +1482,24 @@ if (vp != NULL) { tstamp1 = ntohl(vp->tstamp); fstamp1 = ntohl(vp->fstamp); - if ((tstamp < tstamp1 || (tstamp == tstamp1 && - (peer->crypto & CRYPTO_FLAG_AUTO)))) - return (XEVNT_TSP); + if (tstamp1 != 0 && fstamp1 != 0) { + if (tstamp < tstamp1) + return (XEVNT_TSP); - if ((tstamp < fstamp1 || fstamp < fstamp1)) - return (XEVNT_FSP); + if ((tstamp < fstamp1 || fstamp < fstamp1)) + return (XEVNT_FSP); + } } /* + * At the time the certificate message is validated, the public + * key in the message is not available. Thus, don't try to + * verify the signature. + */ + if (opcode == (CRYPTO_CERT | CRYPTO_RESP)) + return (XEVNT_OK); + + /* * Check for valid signature length, public key and digest * algorithm. */ @@ -1603,7 +1508,7 @@ else pkey = peer->pkey; if (siglen == 0 || pkey == NULL || peer->digest == NULL) - return (XEVNT_OK); + return (XEVNT_ERR); if (siglen != (u_int)EVP_PKEY_size(pkey)) return (XEVNT_SGL); @@ -1611,19 +1516,16 @@ /* * Darn, I thought we would never get here. Verify the * signature. If the identity exchange is verified, light the - * proventic bit. If no client identity scheme is specified, - * avoid doing the sign exchange. + * proventic bit. What a relief. */ EVP_VerifyInit(&ctx, peer->digest); EVP_VerifyUpdate(&ctx, (u_char *)&ep->tstamp, vallen + 12); - if (EVP_VerifyFinal(&ctx, (u_char *)&ep->pkt[i], siglen, pkey) <= 0) + if (EVP_VerifyFinal(&ctx, (u_char *)&ep->pkt[i], siglen, + pkey) <= 0) return (XEVNT_SIG); - if (peer->crypto & CRYPTO_FLAG_VRFY) { + if (peer->crypto & CRYPTO_FLAG_VRFY) peer->crypto |= CRYPTO_FLAG_PROV; - if (!(crypto_flags & CRYPTO_FLAG_MASK)) - peer->crypto |= CRYPTO_FLAG_SIGN; - } return (XEVNT_OK); } @@ -1634,9 +1536,8 @@ * * Returns * XEVNT_OK success - * XEVNT_PUB bad or missing public key * XEVNT_CKY bad or missing cookie - * XEVNT_PER host certificate expired + * XEVNT_PUB bad or missing public key */ static int crypto_encrypt( @@ -1659,7 +1560,7 @@ ptr = (u_char *)ep->pkt; pkey = d2i_PublicKey(EVP_PKEY_RSA, NULL, &ptr, len); if (pkey == NULL) { - msyslog(LOG_ERR, "crypto_encrypt %s\n", + msyslog(LOG_ERR, "crypto_encrypt: %s", ERR_error_string(ERR_get_error(), NULL)); return (XEVNT_PUB); } @@ -1667,35 +1568,33 @@ /* * Encrypt the cookie, encode in ASN.1 and sign. */ - tstamp = crypto_time(); memset(vp, 0, sizeof(struct value)); + tstamp = crypto_time(); vp->tstamp = htonl(tstamp); vp->fstamp = hostval.tstamp; len = EVP_PKEY_size(pkey); vp->vallen = htonl(len); vp->ptr = emalloc(len); + ptr = vp->ptr; temp32 = htonl(*cookie); - if (!RSA_public_encrypt(4, (u_char *)&temp32, vp->ptr, - pkey->pkey.rsa, RSA_PKCS1_OAEP_PADDING)) { - msyslog(LOG_ERR, "crypto_encrypt %s\n", + if (RSA_public_encrypt(4, (u_char *)&temp32, ptr, + pkey->pkey.rsa, RSA_PKCS1_OAEP_PADDING) <= 0) { + msyslog(LOG_ERR, "crypto_encrypt: %s", ERR_error_string(ERR_get_error(), NULL)); + free(vp->ptr); EVP_PKEY_free(pkey); return (XEVNT_CKY); } EVP_PKEY_free(pkey); - vp->siglen = 0; if (tstamp == 0) return (XEVNT_OK); - if (tstamp < cinfo->first || tstamp > cinfo->last) - return (XEVNT_PER); - vp->sig = emalloc(sign_siglen); EVP_SignInit(&ctx, sign_digest); EVP_SignUpdate(&ctx, (u_char *)&vp->tstamp, 12); EVP_SignUpdate(&ctx, vp->ptr, len); if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) - vp->siglen = htonl(len); + vp->siglen = htonl(sign_siglen); return (XEVNT_OK); } @@ -1705,71 +1604,54 @@ * * This routine determines which identity scheme is in use and * constructs an extension field for that scheme. + * + * Returns + * CRYTPO_IFF IFF scheme + * CRYPTO_GQ GQ scheme + * CRYPTO_MV MV scheme + * CRYPTO_NULL no available scheme */ u_int crypto_ident( struct peer *peer /* peer structure pointer */ ) { - char filename[MAXFILENAME + 1]; + char filename[MAXFILENAME]; /* - * If the server identity has already been verified, no further - * action is necessary. Otherwise, try to load the identity file - * of the certificate issuer. If the issuer file is not found, - * try the host file. If nothing found, declare a cryptobust. - * Note we can't get here unless the trusted certificate has - * been found and the CRYPTO_FLAG_VALID bit is set, so the - * certificate issuer is valid. + * We come here after the group trusted host has been found; its + * name defines the group name. Search the key cache for all + * keys matching the same group name in order IFF, GQ and MV. + * Use the first one available. */ - if (peer->ident_pkey != NULL) - EVP_PKEY_free(peer->ident_pkey); - if (peer->crypto & CRYPTO_FLAG_GQ) { - snprintf(filename, MAXFILENAME, "ntpkey_gq_%s", - peer->issuer); - peer->ident_pkey = crypto_key(filename, &peer->fstamp); - if (peer->ident_pkey != NULL) - return (CRYPTO_GQ); - - snprintf(filename, MAXFILENAME, "ntpkey_gq_%s", - sys_hostname); - peer->ident_pkey = crypto_key(filename, &peer->fstamp); - if (peer->ident_pkey != NULL) - return (CRYPTO_GQ); - } if (peer->crypto & CRYPTO_FLAG_IFF) { - snprintf(filename, MAXFILENAME, "ntpkey_iff_%s", + snprintf(filename, MAXFILENAME, "ntpkey_iffpar_%s", peer->issuer); - peer->ident_pkey = crypto_key(filename, &peer->fstamp); + peer->ident_pkey = crypto_key(filename, NULL, + &peer->srcadr); if (peer->ident_pkey != NULL) return (CRYPTO_IFF); - - snprintf(filename, MAXFILENAME, "ntpkey_iff_%s", - sys_hostname); - peer->ident_pkey = crypto_key(filename, &peer->fstamp); + } + if (peer->crypto & CRYPTO_FLAG_GQ) { + snprintf(filename, MAXFILENAME, "ntpkey_gqpar_%s", + peer->issuer); + peer->ident_pkey = crypto_key(filename, NULL, + &peer->srcadr); if (peer->ident_pkey != NULL) - return (CRYPTO_IFF); + return (CRYPTO_GQ); } if (peer->crypto & CRYPTO_FLAG_MV) { - snprintf(filename, MAXFILENAME, "ntpkey_mv_%s", + snprintf(filename, MAXFILENAME, "ntpkey_mvpar_%s", peer->issuer); - peer->ident_pkey = crypto_key(filename, &peer->fstamp); - if (peer->ident_pkey != NULL) - return (CRYPTO_MV); - - snprintf(filename, MAXFILENAME, "ntpkey_mv_%s", - sys_hostname); - peer->ident_pkey = crypto_key(filename, &peer->fstamp); + peer->ident_pkey = crypto_key(filename, NULL, + &peer->srcadr); if (peer->ident_pkey != NULL) return (CRYPTO_MV); } - - /* - * No compatible identity scheme is available. Life is hard. - */ - msyslog(LOG_INFO, - "crypto_ident: no compatible identity scheme found"); - return (0); + msyslog(LOG_NOTICE, + "crypto_ident: no identity parameters found for group %s", + peer->issuer); + return (CRYPTO_NULL); } @@ -1781,12 +1663,13 @@ * extension field is created here, but freed after the crypto_xmit() * call in the protocol module. * - * Returns extension field pointer (no errors). + * Returns extension field pointer (no errors) */ struct exten * crypto_args( struct peer *peer, /* peer structure pointer */ u_int opcode, /* operation code */ + associd_t associd, /* association ID */ char *str /* argument string */ ) { @@ -1804,23 +1687,13 @@ return (ep); ep->opcode = htonl(opcode + len); - - /* - * If a response, send our ID; if a request, send the - * responder's ID. - */ - if (opcode & CRYPTO_RESP) - ep->associd = htonl(peer->associd); - else - ep->associd = htonl(peer->assoc); + ep->associd = htonl(associd); ep->tstamp = htonl(tstamp); ep->fstamp = hostval.tstamp; ep->vallen = 0; if (str != NULL) { ep->vallen = htonl(strlen(str)); memcpy((char *)ep->pkt, str, strlen(str)); - } else { - ep->pkt[0] = peer->associd; } return (ep); } @@ -1829,42 +1702,67 @@ /* * crypto_send - construct extension field from value components * - * Returns extension field length. Note: it is not polite to send a - * nonempty signature with zero timestamp or a nonzero timestamp with - * empty signature, but these rules are not enforced here. + * The value and signature fields are zero-padded to a word boundary. + * Note: it is not polite to send a nonempty signature with zero + * timestamp or a nonzero timestamp with an empty signature, but those + * rules are not enforced here. */ -u_int +int crypto_send( struct exten *ep, /* extension field pointer */ - struct value *vp /* value pointer */ + struct value *vp, /* value pointer */ + int start /* buffer offset */ ) { - u_int len, temp32; - int i; + u_int len, vallen, siglen, opcode; + int i, j; + + /* + * Calculate extension field length and check for buffer + * overflow. Leave room for the MAC. + */ + len = 16; + vallen = ntohl(vp->vallen); + len += ((vallen + 3) / 4 + 1) * 4; + siglen = ntohl(vp->siglen); + len += ((siglen + 3) / 4 + 1) * 4; + if (start + len > sizeof(struct pkt) - MAX_MAC_LEN) + return (0); /* - * Copy data. If the data field is empty or zero length, encode - * an empty value with length zero. + * Copy timestamps. */ ep->tstamp = vp->tstamp; ep->fstamp = vp->fstamp; ep->vallen = vp->vallen; - len = 12; - temp32 = ntohl(vp->vallen); - if (temp32 > 0 && vp->ptr != NULL) - memcpy(ep->pkt, vp->ptr, temp32); + + /* + * Copy value. If the data field is empty or zero length, + * encode an empty value with length zero. + */ + i = 0; + if (vallen > 0 && vp->ptr != NULL) { + j = vallen / 4; + if (j * 4 < vallen) + ep->pkt[i + j++] = 0; + memcpy(&ep->pkt[i], vp->ptr, vallen); + i += j; + } /* * Copy signature. If the signature field is empty or zero * length, encode an empty signature with length zero. */ - i = (temp32 + 3) / 4; - len += i * 4 + 4; ep->pkt[i++] = vp->siglen; - temp32 = ntohl(vp->siglen); - if (temp32 > 0 && vp->sig != NULL) - memcpy(&ep->pkt[i], vp->sig, temp32); - len += temp32; + if (siglen > 0 && vp->sig != NULL) { + j = vallen / 4; + if (j * 4 < siglen) + ep->pkt[i + j++] = 0; + memcpy(&ep->pkt[i], vp->sig, siglen); + i += j; + } + opcode = ntohl(ep->opcode); + ep->opcode = htonl((opcode & 0xffff0000) | len); return (len); } @@ -1879,12 +1777,11 @@ * hostval host name (not signed) * pubkey public key * cinfo certificate info/value list - * tai_leap leapseconds file + * tai_leap leap values * - * Filestamps are proventicated data, so this routine is run only when - * the host has been synchronized to a proventicated source. Thus, the - * timestamp is proventicated, too, and can be used to deflect - * clogging attacks and even cook breakfast. + * Filestamps are proventic data, so this routine runs only when the + * host is synchronized to a proventicated source. Thus, the timestamp + * is proventic and can be used to deflect clogging attacks. * * Returns void (no errors) */ @@ -1892,15 +1789,15 @@ crypto_update(void) { EVP_MD_CTX ctx; /* message digest context */ - struct cert_info *cp, *cpn; /* certificate info/value */ + struct cert_info *cp; /* certificate info/value */ char statstr[NTP_MAXSTRLEN]; /* statistics for filegen */ - tstamp_t tstamp; /* NTP timestamp */ + u_int32 *ptr; u_int len; - if ((tstamp = crypto_time()) == 0) + hostval.tstamp = htonl(crypto_time()); + if (hostval.tstamp == 0) return; - hostval.tstamp = htonl(tstamp); /* * Sign public key and timestamps. The filestamp is derived from @@ -1916,7 +1813,7 @@ EVP_SignUpdate(&ctx, (u_char *)&pubkey, 12); EVP_SignUpdate(&ctx, pubkey.ptr, ntohl(pubkey.vallen)); if (EVP_SignFinal(&ctx, pubkey.sig, &len, sign_pkey)) - pubkey.siglen = htonl(len); + pubkey.siglen = htonl(sign_siglen); } /* @@ -1925,8 +1822,7 @@ * was generated. Note we do not throw expired certificates * away; they may have signed younger ones. */ - for (cp = cinfo; cp != NULL; cp = cpn) { - cpn = cp->link; + for (cp = cinfo; cp != NULL; cp = cp->link) { cp->cert.tstamp = hostval.tstamp; cp->cert.siglen = 0; if (cp->cert.sig == NULL) @@ -1936,28 +1832,34 @@ EVP_SignUpdate(&ctx, cp->cert.ptr, ntohl(cp->cert.vallen)); if (EVP_SignFinal(&ctx, cp->cert.sig, &len, sign_pkey)) - cp->cert.siglen = htonl(len); + cp->cert.siglen = htonl(sign_siglen); } /* - * Sign leapseconds table and timestamps. The filestamp is - * derived from the leapsecond file extension from wherever the - * file was generated. + * Sign leapseconds values and timestamps. Note it is not an + * error to return null values. */ - if (tai_leap.vallen != 0) { - tai_leap.tstamp = hostval.tstamp; - tai_leap.siglen = 0; - if (tai_leap.sig == NULL) - tai_leap.sig = emalloc(sign_siglen); - EVP_SignInit(&ctx, sign_digest); - EVP_SignUpdate(&ctx, (u_char *)&tai_leap, 12); - EVP_SignUpdate(&ctx, tai_leap.ptr, - ntohl(tai_leap.vallen)); - if (EVP_SignFinal(&ctx, tai_leap.sig, &len, sign_pkey)) - tai_leap.siglen = htonl(len); - } - snprintf(statstr, NTP_MAXSTRLEN, - "update ts %u", ntohl(hostval.tstamp)); + tai_leap.tstamp = hostval.tstamp; + tai_leap.fstamp = hostval.fstamp; + len = 3 * sizeof(u_int32); + if (tai_leap.ptr == NULL) + tai_leap.ptr = emalloc(len); + tai_leap.vallen = htonl(len); + ptr = (u_int32 *)tai_leap.ptr; + ptr[0] = htonl(leap_tai); + ptr[1] = htonl(leap_sec); + ptr[2] = htonl(leap_expire); + if (tai_leap.sig == NULL) + tai_leap.sig = emalloc(sign_siglen); + EVP_SignInit(&ctx, sign_digest); + EVP_SignUpdate(&ctx, (u_char *)&tai_leap, 12); + EVP_SignUpdate(&ctx, tai_leap.ptr, len); + if (EVP_SignFinal(&ctx, tai_leap.sig, &len, sign_pkey)) + tai_leap.siglen = htonl(sign_siglen); + if (leap_sec > 0) + crypto_flags |= CRYPTO_FLAG_TAI; + snprintf(statstr, NTP_MAXSTRLEN, "signature update ts %u", + ntohl(hostval.tstamp)); record_crypto_stats(NULL, statstr); #ifdef DEBUG if (debug) @@ -1985,12 +1887,14 @@ /* - * crypto_time - returns current NTP time in seconds. + * crypto_time - returns current NTP time. + * + * Returns NTP seconds if in synch, 0 otherwise */ tstamp_t crypto_time() { - l_fp tstamp; /* NTP time */ L_CLR(&tstamp); + l_fp tstamp; /* NTP time */ L_CLR(&tstamp); if (sys_leap != LEAP_NOTINSYNC) @@ -2000,7 +1904,9 @@ /* - * asn2ntp - convert ASN1_TIME time structure to NTP time in seconds. + * asn2ntp - convert ASN1_TIME time structure to NTP time. + * + * Returns NTP seconds (no errors) */ u_long asn2ntp ( @@ -2013,13 +1919,10 @@ /* * Extract time string YYMMDDHHMMSSZ from ASN1 time structure. * Note that the YY, MM, DD fields start with one, the HH, MM, - * SS fiels start with zero and the Z character should be 'Z' - * for UTC. Also note that years less than 50 map to years - * greater than 100. Dontcha love ASN.1? Better than MIL-188. + * SS fiels start with zero and the Z character is ignored. + * Also note that years less than 50 map to years greater than + * 100. Dontcha love ASN.1? Better than MIL-188. */ - if (asn1time->length > 13) - return ((u_long)(~0)); /* We can't use -1 here. It's invalid */ - v = (char *)asn1time->data; tm.tm_year = (v[0] - '0') * 10 + v[1] - '0'; if (tm.tm_year < 50) @@ -2032,14 +1935,16 @@ tm.tm_wday = 0; tm.tm_yday = 0; tm.tm_isdst = 0; - return (timegm(&tm) + JAN_1970); + return ((u_long)timegm(&tm) + JAN_1970); } /* * bigdig() - compute a BIGNUM MD5 hash of a BIGNUM number. + * + * Returns void (no errors) */ -static int +static void bighash( BIGNUM *bn, /* BIGNUM * from */ BIGNUM *bk /* BIGNUM * to */ @@ -2057,10 +1962,7 @@ EVP_DigestUpdate(&ctx, ptr, len); EVP_DigestFinal(&ctx, dgst, &len); BN_bin2bn(dgst, len, bk); - - /* XXX MEMLEAK? free ptr? */ - - return (1); + free(ptr); } @@ -2072,35 +1974,38 @@ *********************************************************************** * * The Schnorr (IFF) identity scheme is intended for use when - * the ntp-genkeys program does not generate the certificates used in - * the protocol and the group key cannot be conveyed in the certificate - * itself. For this purpose, new generations of IFF values must be - * securely transmitted to all members of the group before use. The - * scheme is self contained and independent of new generations of host - * keys, sign keys and certificates. - * - * The IFF identity scheme is based on DSA cryptography and algorithms - * described in Stinson p. 285. The IFF values hide in a DSA cuckoo - * structure, but only the primes and generator are used. The p is a - * 512-bit prime, q a 160-bit prime that divides p - 1 and is a qth root - * of 1 mod p; that is, g^q = 1 mod p. The TA rolls primvate random - * group key b disguised as a DSA structure member, then computes public - * key g^(q - b). These values are shared only among group members and - * never revealed in messages. Alice challenges Bob to confirm identity - * using the protocol described below. + * certificates are generated by some other trusted certificate + * authority and the certificate cannot be used to convey public + * parameters. There are two kinds of files: encrypted server files that + * contain private and public values and nonencrypted client files that + * contain only public values. New generations of server files must be + * securely transmitted to all servers of the group; client files can be + * distributed by any means. The scheme is self contained and + * independent of new generations of host keys, sign keys and + * certificates. + * + * The IFF values hide in a DSA cuckoo structure which uses the same + * parameters. The values are used by an identity scheme based on DSA + * cryptography and described in Stimson p. 285. The p is a 512-bit + * prime, g a generator of Zp* and q a 160-bit prime that divides p - 1 + * and is a qth root of 1 mod p; that is, g^q = 1 mod p. The TA rolls a + * private random group key b (0 < b < q) and public key v = g^b, then + * sends (p, q, g, b) to the servers and (p, q, g, v) to the clients. + * Alice challenges Bob to confirm identity using the protocol described + * below. * * How it works * * The scheme goes like this. Both Alice and Bob have the public primes * p, q and generator g. The TA gives private key b to Bob and public - * key v = g^(q - a) mod p to Alice. + * key v to Alice. * - * Alice rolls new random challenge r and sends to Bob in the IFF - * request message. Bob rolls new random k, then computes y = k + b r - * mod q and x = g^k mod p and sends (y, hash(x)) to Alice in the - * response message. Besides making the response shorter, the hash makes - * it effectivey impossible for an intruder to solve for b by observing - * a number of these messages. + * Alice rolls new random challenge r (o < r < q) and sends to Bob in + * the IFF request message. Bob rolls new random k (0 < k < q), then + * computes y = k + b r mod q and x = g^k mod p and sends (y, hash(x)) + * to Alice in the response message. Besides making the response + * shorter, the hash makes it effectivey impossible for an intruder to + * solve for b by observing a number of these messages. * * Alice receives the response and computes g^y v^r mod p. After a bit * of algebra, this simplifies to g^k. If the hash of this result @@ -2112,8 +2017,8 @@ * * Returns * XEVNT_OK success - * XEVNT_PUB bad or missing public key * XEVNT_ID bad or missing group key + * XEVNT_PUB bad or missing public key */ static int crypto_alice( @@ -2133,47 +2038,42 @@ if (peer->ident_pkey == NULL) return (XEVNT_ID); - if ((dsa = peer->ident_pkey->pkey.dsa) == NULL) { - msyslog(LOG_INFO, "crypto_alice: defective key"); + if ((dsa = peer->ident_pkey->pkey->pkey.dsa) == NULL) { + msyslog(LOG_NOTICE, "crypto_alice: defective key"); return (XEVNT_PUB); } /* - * Roll new random r (0 < r < q). The OpenSSL library has a bug - * omitting BN_rand_range, so we have to do it the hard way. + * Roll new random r (0 < r < q). */ - bctx = BN_CTX_new(); - len = BN_num_bytes(dsa->q); if (peer->iffval != NULL) BN_free(peer->iffval); peer->iffval = BN_new(); - BN_rand(peer->iffval, len * 8, -1, 1); /* r */ + len = BN_num_bytes(dsa->q); + BN_rand(peer->iffval, len * 8, -1, 1); /* r mod q*/ + bctx = BN_CTX_new(); BN_mod(peer->iffval, peer->iffval, dsa->q, bctx); BN_CTX_free(bctx); /* * Sign and send to Bob. The filestamp is from the local file. */ - tstamp = crypto_time(); memset(vp, 0, sizeof(struct value)); + tstamp = crypto_time(); vp->tstamp = htonl(tstamp); - vp->fstamp = htonl(peer->fstamp); + vp->fstamp = htonl(peer->ident_pkey->fstamp); vp->vallen = htonl(len); vp->ptr = emalloc(len); BN_bn2bin(peer->iffval, vp->ptr); - vp->siglen = 0; if (tstamp == 0) return (XEVNT_OK); - if (tstamp < cinfo->first || tstamp > cinfo->last) - return (XEVNT_PER); - vp->sig = emalloc(sign_siglen); EVP_SignInit(&ctx, sign_digest); EVP_SignUpdate(&ctx, (u_char *)&vp->tstamp, 12); EVP_SignUpdate(&ctx, vp->ptr, len); if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) - vp->siglen = htonl(len); + vp->siglen = htonl(sign_siglen); return (XEVNT_OK); } @@ -2183,9 +2083,8 @@ * * Returns * XEVNT_OK success - * XEVNT_ID bad or missing group key * XEVNT_ERR protocol error - * XEVNT_PER host expired certificate + * XEVNT_ID bad or missing group key */ static int crypto_bob( @@ -2206,18 +2105,18 @@ * If the IFF parameters are not valid, something awful * happened or we are being tormented. */ - if (iffpar_pkey == NULL) { - msyslog(LOG_INFO, "crypto_bob: scheme unavailable"); + if (iffkey_info == NULL) { + msyslog(LOG_NOTICE, "crypto_bob: scheme unavailable"); return (XEVNT_ID); } - dsa = iffpar_pkey->pkey.dsa; + dsa = iffkey_info->pkey->pkey.dsa; /* * Extract r from the challenge. */ len = ntohl(ep->vallen); if ((r = BN_bin2bn((u_char *)ep->pkt, len, NULL)) == NULL) { - msyslog(LOG_ERR, "crypto_bob %s\n", + msyslog(LOG_ERR, "crypto_bob: %s", ERR_error_string(ERR_get_error(), NULL)); return (XEVNT_ERR); } @@ -2238,39 +2137,40 @@ sdsa->s = BN_dup(bk); BN_CTX_free(bctx); BN_free(r); BN_free(bn); BN_free(bk); +#ifdef DEBUG + if (debug > 1) + DSA_print_fp(stdout, dsa, 0); +#endif /* - * Encode the values in ASN.1 and sign. + * Encode the values in ASN.1 and sign. The filestamp is from + * the local file. */ - tstamp = crypto_time(); - memset(vp, 0, sizeof(struct value)); - vp->tstamp = htonl(tstamp); - vp->fstamp = htonl(if_fstamp); len = i2d_DSA_SIG(sdsa, NULL); - if (len <= 0) { - msyslog(LOG_ERR, "crypto_bob %s\n", + if (len == 0) { + msyslog(LOG_ERR, "crypto_bob: %s", ERR_error_string(ERR_get_error(), NULL)); DSA_SIG_free(sdsa); return (XEVNT_ERR); } + memset(vp, 0, sizeof(struct value)); + tstamp = crypto_time(); + vp->tstamp = htonl(tstamp); + vp->fstamp = htonl(iffkey_info->fstamp); vp->vallen = htonl(len); ptr = emalloc(len); vp->ptr = ptr; i2d_DSA_SIG(sdsa, &ptr); DSA_SIG_free(sdsa); - vp->siglen = 0; if (tstamp == 0) return (XEVNT_OK); - if (tstamp < cinfo->first || tstamp > cinfo->last) - return (XEVNT_PER); - vp->sig = emalloc(sign_siglen); EVP_SignInit(&ctx, sign_digest); EVP_SignUpdate(&ctx, (u_char *)&vp->tstamp, 12); EVP_SignUpdate(&ctx, vp->ptr, len); if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) - vp->siglen = htonl(len); + vp->siglen = htonl(sign_siglen); return (XEVNT_OK); } @@ -2280,9 +2180,9 @@ * * Returns * XEVNT_OK success - * XEVNT_PUB bad or missing public key - * XEVNT_ID bad or missing group key * XEVNT_FSP bad filestamp + * XEVNT_ID bad or missing group key + * XEVNT_PUB bad or missing public key */ int crypto_iff( @@ -2295,7 +2195,7 @@ DSA_SIG *sdsa; /* DSA parameters */ BIGNUM *bn, *bk; u_int len; - const u_char *ptr; + const u_char *ptr; int temp; /* @@ -2303,20 +2203,20 @@ * something awful happened or we are being tormented. */ if (peer->ident_pkey == NULL) { - msyslog(LOG_INFO, "crypto_iff: scheme unavailable"); + msyslog(LOG_NOTICE, "crypto_iff: scheme unavailable"); return (XEVNT_ID); } - if (ntohl(ep->fstamp) != peer->fstamp) { - msyslog(LOG_INFO, "crypto_iff: invalid filestamp %u", + if (ntohl(ep->fstamp) != peer->ident_pkey->fstamp) { + msyslog(LOG_NOTICE, "crypto_iff: invalid filestamp %u", ntohl(ep->fstamp)); return (XEVNT_FSP); } - if ((dsa = peer->ident_pkey->pkey.dsa) == NULL) { - msyslog(LOG_INFO, "crypto_iff: defective key"); + if ((dsa = peer->ident_pkey->pkey->pkey.dsa) == NULL) { + msyslog(LOG_NOTICE, "crypto_iff: defective key"); return (XEVNT_PUB); } if (peer->iffval == NULL) { - msyslog(LOG_INFO, "crypto_iff: missing challenge"); + msyslog(LOG_NOTICE, "crypto_iff: missing challenge"); return (XEVNT_ID); } @@ -2325,9 +2225,10 @@ */ bctx = BN_CTX_new(); bk = BN_new(); bn = BN_new(); len = ntohl(ep->vallen); - ptr = (const u_char *)ep->pkt; + ptr = (u_char *)ep->pkt; if ((sdsa = d2i_DSA_SIG(NULL, &ptr, len)) == NULL) { - msyslog(LOG_ERR, "crypto_iff %s\n", + BN_free(bn); BN_free(bk); BN_CTX_free(bctx); + msyslog(LOG_ERR, "crypto_iff: %s", ERR_error_string(ERR_get_error(), NULL)); return (XEVNT_ERR); } @@ -2351,8 +2252,8 @@ if (temp == 0) return (XEVNT_OK); - else - return (XEVNT_ID); + msyslog(LOG_NOTICE, "crypto_iff: identity not verified"); + return (XEVNT_ID); } @@ -2365,20 +2266,25 @@ *********************************************************************** * * The Guillou-Quisquater (GQ) identity scheme is intended for use when - * the ntp-genkeys program generates the certificates used in the - * protocol and the group key can be conveyed in a certificate extension - * field. The scheme is self contained and independent of new - * generations of host keys, sign keys and certificates. - * - * The GQ identity scheme is based on RSA cryptography and algorithms - * described in Stinson p. 300 (with errors). The GQ values hide in a - * RSA cuckoo structure, but only the modulus is used. The 512-bit - * public modulus is n = p q, where p and q are secret large primes. The - * TA rolls random group key b disguised as a RSA structure member. - * Except for the public key, these values are shared only among group - * members and never revealed in messages. + * the certificate can be used to convey public parameters. The scheme + * uses a X509v3 certificate extension field do convey the public key of + * a private key known only to servers. There are two kinds of files: + * encrypted server files that contain private and public values and + * nonencrypted client files that contain only public values. New + * generations of server files must be securely transmitted to all + * servers of the group; client files can be distributed by any means. + * The scheme is self contained and independent of new generations of + * host keys and sign keys. The scheme is self contained and independent + * of new generations of host keys and sign keys. + * + * The GQ parameters hide in a RSA cuckoo structure which uses the same + * parameters. The values are used by an identity scheme based on RSA + * cryptography and described in Stimson p. 300 (with errors). The 512- + * bit public modulus is n = p q, where p and q are secret large primes. + * The TA rolls private random group key b as RSA exponent. These values + * are known to all group members. * - * When rolling new certificates, Bob recomputes the private and + * When rolling new certificates, a server recomputes the private and * public keys. The private key u is a random roll, while the public key * is the inverse obscured by the group key v = (u^-1)^b. These values * replace the private and public keys normally generated by the RSA @@ -2413,9 +2319,8 @@ * * Returns * XEVNT_OK success - * XEVNT_PUB bad or missing public key * XEVNT_ID bad or missing group key - * XEVNT_PER host certificate expired + * XEVNT_PUB bad or missing public key */ static int crypto_alice2( @@ -2435,47 +2340,42 @@ if (peer->ident_pkey == NULL) return (XEVNT_ID); - if ((rsa = peer->ident_pkey->pkey.rsa) == NULL) { - msyslog(LOG_INFO, "crypto_alice2: defective key"); + if ((rsa = peer->ident_pkey->pkey->pkey.rsa) == NULL) { + msyslog(LOG_NOTICE, "crypto_alice2: defective key"); return (XEVNT_PUB); } /* - * Roll new random r (0 < r < n). The OpenSSL library has a bug - * omitting BN_rand_range, so we have to do it the hard way. + * Roll new random r (0 < r < n). */ - bctx = BN_CTX_new(); - len = BN_num_bytes(rsa->n); if (peer->iffval != NULL) BN_free(peer->iffval); peer->iffval = BN_new(); + len = BN_num_bytes(rsa->n); BN_rand(peer->iffval, len * 8, -1, 1); /* r mod n */ + bctx = BN_CTX_new(); BN_mod(peer->iffval, peer->iffval, rsa->n, bctx); BN_CTX_free(bctx); /* * Sign and send to Bob. The filestamp is from the local file. */ - tstamp = crypto_time(); memset(vp, 0, sizeof(struct value)); + tstamp = crypto_time(); vp->tstamp = htonl(tstamp); - vp->fstamp = htonl(peer->fstamp); + vp->fstamp = htonl(peer->ident_pkey->fstamp); vp->vallen = htonl(len); vp->ptr = emalloc(len); BN_bn2bin(peer->iffval, vp->ptr); - vp->siglen = 0; if (tstamp == 0) return (XEVNT_OK); - if (tstamp < cinfo->first || tstamp > cinfo->last) - return (XEVNT_PER); - vp->sig = emalloc(sign_siglen); EVP_SignInit(&ctx, sign_digest); EVP_SignUpdate(&ctx, (u_char *)&vp->tstamp, 12); EVP_SignUpdate(&ctx, vp->ptr, len); if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) - vp->siglen = htonl(len); + vp->siglen = htonl(sign_siglen); return (XEVNT_OK); } @@ -2485,9 +2385,8 @@ * * Returns * XEVNT_OK success - * XEVNT_ID bad or missing group key * XEVNT_ERR protocol error - * XEVNT_PER host certificate expired + * XEVNT_ID bad or missing group key */ static int crypto_bob2( @@ -2508,18 +2407,18 @@ * If the GQ parameters are not valid, something awful * happened or we are being tormented. */ - if (gqpar_pkey == NULL) { - msyslog(LOG_INFO, "crypto_bob2: scheme unavailable"); + if (gqkey_info == NULL) { + msyslog(LOG_NOTICE, "crypto_bob2: scheme unavailable"); return (XEVNT_ID); } - rsa = gqpar_pkey->pkey.rsa; + rsa = gqkey_info->pkey->pkey.rsa; /* * Extract r from the challenge. */ len = ntohl(ep->vallen); if ((r = BN_bin2bn((u_char *)ep->pkt, len, NULL)) == NULL) { - msyslog(LOG_ERR, "crypto_bob2 %s\n", + msyslog(LOG_ERR, "crypto_bob2: %s", ERR_error_string(ERR_get_error(), NULL)); return (XEVNT_ERR); } @@ -2540,39 +2439,40 @@ sdsa->s = BN_dup(g); BN_CTX_free(bctx); BN_free(r); BN_free(k); BN_free(g); BN_free(y); +#ifdef DEBUG + if (debug > 1) + RSA_print_fp(stdout, rsa, 0); +#endif /* - * Encode the values in ASN.1 and sign. + * Encode the values in ASN.1 and sign. The filestamp is from + * the local file. */ - tstamp = crypto_time(); - memset(vp, 0, sizeof(struct value)); - vp->tstamp = htonl(tstamp); - vp->fstamp = htonl(gq_fstamp); len = i2d_DSA_SIG(sdsa, NULL); if (len <= 0) { - msyslog(LOG_ERR, "crypto_bob2 %s\n", + msyslog(LOG_ERR, "crypto_bob2: %s", ERR_error_string(ERR_get_error(), NULL)); DSA_SIG_free(sdsa); return (XEVNT_ERR); } + memset(vp, 0, sizeof(struct value)); + tstamp = crypto_time(); + vp->tstamp = htonl(tstamp); + vp->fstamp = htonl(gqkey_info->fstamp); vp->vallen = htonl(len); ptr = emalloc(len); vp->ptr = ptr; i2d_DSA_SIG(sdsa, &ptr); DSA_SIG_free(sdsa); - vp->siglen = 0; if (tstamp == 0) return (XEVNT_OK); - if (tstamp < cinfo->first || tstamp > cinfo->last) - return (XEVNT_PER); - vp->sig = emalloc(sign_siglen); EVP_SignInit(&ctx, sign_digest); EVP_SignUpdate(&ctx, (u_char *)&vp->tstamp, 12); EVP_SignUpdate(&ctx, vp->ptr, len); if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) - vp->siglen = htonl(len); + vp->siglen = htonl(sign_siglen); return (XEVNT_OK); } @@ -2582,10 +2482,10 @@ * * Returns * XEVNT_OK success - * XEVNT_PUB bad or missing public key - * XEVNT_ID bad or missing group keys * XEVNT_ERR protocol error * XEVNT_FSP bad filestamp + * XEVNT_ID bad or missing group keys + * XEVNT_PUB bad or missing public key */ int crypto_gq( @@ -2597,29 +2497,31 @@ BN_CTX *bctx; /* BIGNUM context */ DSA_SIG *sdsa; /* RSA signature context fake */ BIGNUM *y, *v; - const u_char *ptr; - u_int len; - int temp; + const u_char *ptr; + long len; + u_int temp; /* * If the GQ parameters are not valid or no challenge was sent, - * something awful happened or we are being tormented. + * something awful happened or we are being tormented. Note that + * the filestamp on the local key file can be greater than on + * the remote parameter file if the keys have been refreshed. */ if (peer->ident_pkey == NULL) { - msyslog(LOG_INFO, "crypto_gq: scheme unavailable"); + msyslog(LOG_NOTICE, "crypto_gq: scheme unavailable"); return (XEVNT_ID); } - if (ntohl(ep->fstamp) != peer->fstamp) { - msyslog(LOG_INFO, "crypto_gq: invalid filestamp %u", + if (ntohl(ep->fstamp) < peer->ident_pkey->fstamp) { + msyslog(LOG_NOTICE, "crypto_gq: invalid filestamp %u", ntohl(ep->fstamp)); return (XEVNT_FSP); } - if ((rsa = peer->ident_pkey->pkey.rsa) == NULL) { - msyslog(LOG_INFO, "crypto_gq: defective key"); + if ((rsa = peer->ident_pkey->pkey->pkey.rsa) == NULL) { + msyslog(LOG_NOTICE, "crypto_gq: defective key"); return (XEVNT_PUB); } if (peer->iffval == NULL) { - msyslog(LOG_INFO, "crypto_gq: missing challenge"); + msyslog(LOG_NOTICE, "crypto_gq: missing challenge"); return (XEVNT_ID); } @@ -2629,9 +2531,10 @@ */ bctx = BN_CTX_new(); y = BN_new(); v = BN_new(); len = ntohl(ep->vallen); - ptr = (const u_char *)ep->pkt; + ptr = (u_char *)ep->pkt; if ((sdsa = d2i_DSA_SIG(NULL, &ptr, len)) == NULL) { - msyslog(LOG_ERR, "crypto_gq %s\n", + BN_CTX_free(bctx); BN_free(y); BN_free(v); + msyslog(LOG_ERR, "crypto_gq: %s", ERR_error_string(ERR_get_error(), NULL)); return (XEVNT_ERR); } @@ -2639,6 +2542,10 @@ /* * Compute v^r y^b mod n. */ + if (peer->grpkey == NULL) { + msyslog(LOG_NOTICE, "crypto_gq: missing group key"); + return (XEVNT_ID); + } BN_mod_exp(v, peer->grpkey, peer->iffval, rsa->n, bctx); /* v^r mod n */ BN_mod_exp(y, sdsa->r, rsa->e, rsa->n, bctx); /* y^b mod n */ @@ -2656,8 +2563,8 @@ if (temp == 0) return (XEVNT_OK); - else - return (XEVNT_ID); + msyslog(LOG_NOTICE, "crypto_gq: identity not verified"); + return (XEVNT_ID); } @@ -2668,8 +2575,7 @@ * scheme * * * *********************************************************************** - */ -/* + * * The Mu-Varadharajan (MV) cryptosystem was originally intended when * servers broadcast messages to clients, but clients never send * messages to servers. There is one encryption key for the server and a @@ -2686,19 +2592,16 @@ * Varadharajan: Robust and Secure Broadcasting, Proc. Indocrypt 2001, * 223-231. The paper has significant errors and serious omissions. * - * Let q be the product of n distinct primes s'[j] (j = 1...n), where - * each s'[j] has m significant bits. Let p be a prime p = 2 * q + 1, so - * that q and each s'[j] divide p - 1 and p has M = n * m + 1 - * significant bits. The elements x mod q of Zq with the elements 2 and - * the primes removed form a field Zq* valid for polynomial arithetic. - * Let g be a generator of Zp; that is, gcd(g, p - 1) = 1 and g^q = 1 - * mod p. We expect M to be in the 500-bit range and n relatively small, - * like 25, so the likelihood of a randomly generated element of x mod q - * of Zq colliding with a factor of p - 1 is very small and can be - * avoided. Associated with each s'[j] is an element s[j] such that s[j] - * s'[j] = s'[j] mod q. We find s[j] as the quotient (q + s'[j]) / - * s'[j]. These are the parameters of the scheme and they are expensive - * to compute. + * Let q be the product of n distinct primes s1[j] (j = 1...n), where + * each s1[j] has m significant bits. Let p be a prime p = 2 * q + 1, so + * that q and each s1[j] divide p - 1 and p has M = n * m + 1 + * significant bits. Let g be a generator of Zp; that is, gcd(g, p - 1) + * = 1 and g^q = 1 mod p. We do modular arithmetic over Zq and then + * project into Zp* as exponents of g. Sometimes we have to compute an + * inverse b^-1 of random b in Zq, but for that purpose we require + * gcd(b, q) = 1. We expect M to be in the 500-bit range and n + * relatively small, like 30. These are the parameters of the scheme and + * they are expensive to compute. * * We set up an instance of the scheme as follows. A set of random * values x[j] mod q (j = 1...n), are generated as the zeros of a @@ -2709,39 +2612,41 @@ * pairs (xbar[j], xhat[j]) (j = 1...n) of private client keys are used * to construct the decryption keys. The devil is in the details. * + * This routine generates a private server encryption file including the + * private encryption key E and partial decryption keys gbar and ghat. + * It then generates public client decryption files including the public + * keys xbar[j] and xhat[j] for each client j. The partial decryption + * files are used to compute the inverse of E. These values are suitably + * blinded so secrets are not revealed. + * * The distinguishing characteristic of this scheme is the capability to * revoke keys. Included in the calculation of E, gbar and ghat is the - * product s = prod(s'[j]) (j = 1...n) above. If the factor s'[j] is + * product s = prod(s1[j]) (j = 1...n) above. If the factor s1[j] is * subsequently removed from the product and E, gbar and ghat * recomputed, the jth client will no longer be able to compute E^-1 and - * thus unable to decrypt the block. + * thus unable to decrypt the messageblock. * * How it works * - * The scheme goes like this. Bob has the server values (p, A, q, gbar, - * ghat) and Alice the client values (p, xbar, xhat). + * The scheme goes like this. Bob has the server values (p, E, q, gbar, + * ghat) and Alice has the client values (p, xbar, xhat). * - * Alice rolls new random challenge r (0 < r < p) and sends to Bob in - * the MV request message. Bob rolls new random k (0 < k < q), encrypts - * y = A^k mod p (a permutation) and sends (hash(y), gbar^k, ghat^k) to - * Alice. + * Alice rolls new random nonce r mod p and sends to Bob in the MV + * request message. Bob rolls random nonce k mod q, encrypts y = r E^k + * mod p and sends (y, gbar^k, ghat^k) to Alice. * - * Alice receives the response and computes the decryption key (the - * inverse permutation) from previously obtained (xbar, xhat) and - * (gbar^k, ghat^k) in the message. She computes the inverse, which is - * unique by reasons explained in the ntp-keygen.c program sources. If - * the hash of this result matches hash(y), Alice knows that Bob has the - * group key b. The signed response binds this knowledge to Bob's - * private key and the public key previously received in his - * certificate. + * Alice receives the response and computes the inverse (E^k)^-1 from + * the partial decryption keys gbar^k, ghat^k, xbar and xhat. She then + * decrypts y and verifies it matches the original r. The signed + * response binds this knowledge to Bob's private key and the public key + * previously received in his certificate. * * crypto_alice3 - construct Alice's challenge in MV scheme * * Returns * XEVNT_OK success - * XEVNT_PUB bad or missing public key * XEVNT_ID bad or missing group key - * XEVNT_PER host certificate expired + * XEVNT_PUB bad or missing public key */ static int crypto_alice3( @@ -2761,47 +2666,42 @@ if (peer->ident_pkey == NULL) return (XEVNT_ID); - if ((dsa = peer->ident_pkey->pkey.dsa) == NULL) { - msyslog(LOG_INFO, "crypto_alice3: defective key"); + if ((dsa = peer->ident_pkey->pkey->pkey.dsa) == NULL) { + msyslog(LOG_NOTICE, "crypto_alice3: defective key"); return (XEVNT_PUB); } /* - * Roll new random r (0 < r < q). The OpenSSL library has a bug - * omitting BN_rand_range, so we have to do it the hard way. + * Roll new random r (0 < r < q). */ - bctx = BN_CTX_new(); - len = BN_num_bytes(dsa->p); if (peer->iffval != NULL) BN_free(peer->iffval); peer->iffval = BN_new(); - BN_rand(peer->iffval, len * 8, -1, 1); /* r */ + len = BN_num_bytes(dsa->p); + BN_rand(peer->iffval, len * 8, -1, 1); /* r mod p */ + bctx = BN_CTX_new(); BN_mod(peer->iffval, peer->iffval, dsa->p, bctx); BN_CTX_free(bctx); /* * Sign and send to Bob. The filestamp is from the local file. */ - tstamp = crypto_time(); memset(vp, 0, sizeof(struct value)); + tstamp = crypto_time(); vp->tstamp = htonl(tstamp); - vp->fstamp = htonl(peer->fstamp); + vp->fstamp = htonl(peer->ident_pkey->fstamp); vp->vallen = htonl(len); vp->ptr = emalloc(len); BN_bn2bin(peer->iffval, vp->ptr); - vp->siglen = 0; if (tstamp == 0) return (XEVNT_OK); - if (tstamp < cinfo->first || tstamp > cinfo->last) - return (XEVNT_PER); - vp->sig = emalloc(sign_siglen); EVP_SignInit(&ctx, sign_digest); EVP_SignUpdate(&ctx, (u_char *)&vp->tstamp, 12); EVP_SignUpdate(&ctx, vp->ptr, len); if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) - vp->siglen = htonl(len); + vp->siglen = htonl(sign_siglen); return (XEVNT_OK); } @@ -2812,7 +2712,6 @@ * Returns * XEVNT_OK success * XEVNT_ERR protocol error - * XEVNT_PER host certificate expired */ static int crypto_bob3( @@ -2833,26 +2732,26 @@ * If the MV parameters are not valid, something awful * happened or we are being tormented. */ - if (mvpar_pkey == NULL) { - msyslog(LOG_INFO, "crypto_bob3: scheme unavailable"); + if (mvkey_info == NULL) { + msyslog(LOG_NOTICE, "crypto_bob3: scheme unavailable"); return (XEVNT_ID); } - dsa = mvpar_pkey->pkey.dsa; + dsa = mvkey_info->pkey->pkey.dsa; /* * Extract r from the challenge. */ len = ntohl(ep->vallen); if ((r = BN_bin2bn((u_char *)ep->pkt, len, NULL)) == NULL) { - msyslog(LOG_ERR, "crypto_bob3 %s\n", + msyslog(LOG_ERR, "crypto_bob3: %s", ERR_error_string(ERR_get_error(), NULL)); return (XEVNT_ERR); } /* * Bob rolls random k (0 < k < q), making sure it is not a - * factor of q. He then computes y = A^k r and sends (hash(y), - * gbar^k, ghat^k) to Alice. + * factor of q. He then computes y = r A^k and sends (y, gbar^k, + * and ghat^k) to Alice. */ bctx = BN_CTX_new(); k = BN_new(); u = BN_new(); sdsa = DSA_new(); @@ -2864,23 +2763,27 @@ if (BN_is_one(u)) break; } - BN_mod_exp(u, dsa->g, k, dsa->p, bctx); /* A r */ - BN_mod_mul(u, u, r, dsa->p, bctx); - bighash(u, sdsa->p); + BN_mod_exp(u, dsa->g, k, dsa->p, bctx); /* A^k r */ + BN_mod_mul(sdsa->p, u, r, dsa->p, bctx); BN_mod_exp(sdsa->q, dsa->priv_key, k, dsa->p, bctx); /* gbar */ BN_mod_exp(sdsa->g, dsa->pub_key, k, dsa->p, bctx); /* ghat */ BN_CTX_free(bctx); BN_free(k); BN_free(r); BN_free(u); +#ifdef DEBUG + if (debug > 1) + DSA_print_fp(stdout, sdsa, 0); +#endif /* - * Encode the values in ASN.1 and sign. + * Encode the values in ASN.1 and sign. The filestamp is from + * the local file. */ - tstamp = crypto_time(); memset(vp, 0, sizeof(struct value)); + tstamp = crypto_time(); vp->tstamp = htonl(tstamp); - vp->fstamp = htonl(mv_fstamp); + vp->fstamp = htonl(mvkey_info->fstamp); len = i2d_DSAparams(sdsa, NULL); - if (len <= 0) { - msyslog(LOG_ERR, "crypto_bob3 %s\n", + if (len == 0) { + msyslog(LOG_ERR, "crypto_bob3: %s", ERR_error_string(ERR_get_error(), NULL)); DSA_free(sdsa); return (XEVNT_ERR); @@ -2890,19 +2793,15 @@ vp->ptr = ptr; i2d_DSAparams(sdsa, &ptr); DSA_free(sdsa); - vp->siglen = 0; if (tstamp == 0) return (XEVNT_OK); - if (tstamp < cinfo->first || tstamp > cinfo->last) - return (XEVNT_PER); - vp->sig = emalloc(sign_siglen); EVP_SignInit(&ctx, sign_digest); EVP_SignUpdate(&ctx, (u_char *)&vp->tstamp, 12); EVP_SignUpdate(&ctx, vp->ptr, len); if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) - vp->siglen = htonl(len); + vp->siglen = htonl(sign_siglen); return (XEVNT_OK); } @@ -2912,10 +2811,10 @@ * * Returns * XEVNT_OK success - * XEVNT_PUB bad or missing public key - * XEVNT_ID bad or missing group key * XEVNT_ERR protocol error * XEVNT_FSP bad filestamp + * XEVNT_ID bad or missing group key + * XEVNT_PUB bad or missing public key */ int crypto_mv( @@ -2928,7 +2827,7 @@ BN_CTX *bctx; /* BIGNUM context */ BIGNUM *k, *u, *v; u_int len; - const u_char *ptr; + const u_char *ptr; int temp; /* @@ -2936,49 +2835,47 @@ * something awful happened or we are being tormented. */ if (peer->ident_pkey == NULL) { - msyslog(LOG_INFO, "crypto_mv: scheme unavailable"); + msyslog(LOG_NOTICE, "crypto_mv: scheme unavailable"); return (XEVNT_ID); } - if (ntohl(ep->fstamp) != peer->fstamp) { - msyslog(LOG_INFO, "crypto_mv: invalid filestamp %u", + if (ntohl(ep->fstamp) != peer->ident_pkey->fstamp) { + msyslog(LOG_NOTICE, "crypto_mv: invalid filestamp %u", ntohl(ep->fstamp)); return (XEVNT_FSP); } - if ((dsa = peer->ident_pkey->pkey.dsa) == NULL) { - msyslog(LOG_INFO, "crypto_mv: defective key"); + if ((dsa = peer->ident_pkey->pkey->pkey.dsa) == NULL) { + msyslog(LOG_NOTICE, "crypto_mv: defective key"); return (XEVNT_PUB); } if (peer->iffval == NULL) { - msyslog(LOG_INFO, "crypto_mv: missing challenge"); + msyslog(LOG_NOTICE, "crypto_mv: missing challenge"); return (XEVNT_ID); } /* - * Extract the (hash(y), gbar, ghat) values from the response. + * Extract the y, gbar and ghat values from the response. */ bctx = BN_CTX_new(); k = BN_new(); u = BN_new(); v = BN_new(); len = ntohl(ep->vallen); - ptr = (const u_char *)ep->pkt; + ptr = (u_char *)ep->pkt; if ((sdsa = d2i_DSAparams(NULL, &ptr, len)) == NULL) { - msyslog(LOG_ERR, "crypto_mv %s\n", + msyslog(LOG_ERR, "crypto_mv: %s", ERR_error_string(ERR_get_error(), NULL)); return (XEVNT_ERR); } /* - * Compute (gbar^xhat ghat^xbar)^-1 mod p. + * Compute (gbar^xhat ghat^xbar) mod p. */ BN_mod_exp(u, sdsa->q, dsa->pub_key, dsa->p, bctx); BN_mod_exp(v, sdsa->g, dsa->priv_key, dsa->p, bctx); BN_mod_mul(u, u, v, dsa->p, bctx); - BN_mod_inverse(u, u, dsa->p, bctx); - BN_mod_mul(v, u, peer->iffval, dsa->p, bctx); + BN_mod_mul(u, u, sdsa->p, dsa->p, bctx); /* - * The result should match the hash of r mod p. + * The result should match r. */ - bighash(v, v); - temp = BN_cmp(v, sdsa->p); + temp = BN_cmp(u, peer->iffval); BN_CTX_free(bctx); BN_free(k); BN_free(u); BN_free(v); BN_free(peer->iffval); peer->iffval = NULL; @@ -2986,8 +2883,8 @@ if (temp == 0) return (XEVNT_OK); - else - return (XEVNT_ID); + msyslog(LOG_NOTICE, "crypto_mv: identity not verified"); + return (XEVNT_ID); } @@ -2999,253 +2896,69 @@ *********************************************************************** */ /* - * cert_parse - parse x509 certificate and create info/value structures. + * cert_sign - sign x509 certificate equest and update value structure. * - * The server certificate includes the version number, issuer name, - * subject name, public key and valid date interval. If the issuer name - * is the same as the subject name, the certificate is self signed and - * valid only if the server is configured as trustable. If the names are - * different, another issuer has signed the server certificate and - * vouched for it. In this case the server certificate is valid if - * verified by the issuer public key. + * The certificate request includes a copy of the host certificate, + * which includes the version number, subject name and public key of the + * host. The resulting certificate includes these values plus the + * serial number, issuer name and valid interval of the server. The + * valid interval extends from the current time to the same time one + * year hence. This may extend the life of the signed certificate beyond + * that of the signer certificate. * - * Returns certificate info/value pointer if valid, NULL if not. + * It is convenient to use the NTP seconds of the current time as the + * serial number. In the value structure the timestamp is the current + * time and the filestamp is taken from the extension field. Note this + * routine is called only when the client clock is synchronized to a + * proventic source, so timestamp comparisons are valid. + * + * The host certificate is valid from the time it was generated for a + * period of one year. A signed certificate is valid from the time of + * signature for a period of one year, but only the host certificate (or + * sign certificate if used) is actually used to encrypt and decrypt + * signatures. The signature trail is built from the client via the + * intermediate servers to the trusted server. Each signature on the + * trail must be valid at the time of signature, but it could happen + * that a signer certificate expire before the signed certificate, which + * remains valid until its expiration. + * + * Returns + * XEVNT_OK success + * XEVNT_CRT bad or missing certificate + * XEVNT_PER host certificate expired + * XEVNT_PUB bad or missing public key + * XEVNT_VFY certificate not verified */ -struct cert_info * /* certificate information structure */ -cert_parse( - u_char *asn1cert, /* X509 certificate */ - u_int len, /* certificate length */ - tstamp_t fstamp /* filestamp */ +static int +cert_sign( + struct exten *ep, /* extension field pointer */ + struct value *vp /* value pointer */ ) { + X509 *req; /* X509 certificate request */ X509 *cert; /* X509 certificate */ - X509_EXTENSION *ext; /* X509v3 extension */ - struct cert_info *ret; /* certificate info/value */ - BIO *bp; - X509V3_EXT_METHOD *method; - char pathbuf[MAXFILENAME]; - u_char *uptr; - char *ptr; - int temp, cnt, i; + X509_EXTENSION *ext; /* certificate extension */ + ASN1_INTEGER *serial; /* serial number */ + X509_NAME *subj; /* distinguished (common) name */ + EVP_PKEY *pkey; /* public key */ + EVP_MD_CTX ctx; /* message digest context */ + tstamp_t tstamp; /* NTP timestamp */ + u_int len; + u_char *ptr; + int i, temp; /* * Decode ASN.1 objects and construct certificate structure. - */ - uptr = asn1cert; - if ((cert = d2i_X509(NULL, &uptr, len)) == NULL) { - msyslog(LOG_ERR, "cert_parse %s\n", - ERR_error_string(ERR_get_error(), NULL)); - return (NULL); - } - - /* - * Extract version, subject name and public key. - */ - ret = emalloc(sizeof(struct cert_info)); - memset(ret, 0, sizeof(struct cert_info)); - if ((ret->pkey = X509_get_pubkey(cert)) == NULL) { - msyslog(LOG_ERR, "cert_parse %s\n", - ERR_error_string(ERR_get_error(), NULL)); - cert_free(ret); - X509_free(cert); - return (NULL); - } - ret->version = X509_get_version(cert); - X509_NAME_oneline(X509_get_subject_name(cert), pathbuf, - MAXFILENAME - 1); - ptr = strstr(pathbuf, "CN="); - if (ptr == NULL) { - msyslog(LOG_INFO, "cert_parse: invalid subject %s", - pathbuf); - cert_free(ret); - X509_free(cert); - return (NULL); - } - ret->subject = emalloc(strlen(ptr) + 1); - strcpy(ret->subject, ptr + 3); - - /* - * Extract remaining objects. Note that the NTP serial number is - * the NTP seconds at the time of signing, but this might not be - * the case for other authority. We don't bother to check the - * objects at this time, since the real crunch can happen only - * when the time is valid but not yet certificated. - */ - ret->nid = OBJ_obj2nid(cert->cert_info->signature->algorithm); - ret->digest = (const EVP_MD *)EVP_get_digestbynid(ret->nid); - ret->serial = - (u_long)ASN1_INTEGER_get(X509_get_serialNumber(cert)); - X509_NAME_oneline(X509_get_issuer_name(cert), pathbuf, - MAXFILENAME); - if ((ptr = strstr(pathbuf, "CN=")) == NULL) { - msyslog(LOG_INFO, "cert_parse: invalid issuer %s", - pathbuf); - cert_free(ret); - X509_free(cert); - return (NULL); - } - ret->issuer = emalloc(strlen(ptr) + 1); - strcpy(ret->issuer, ptr + 3); - ret->first = asn2ntp(X509_get_notBefore(cert)); - ret->last = asn2ntp(X509_get_notAfter(cert)); - - /* - * Extract extension fields. These are ad hoc ripoffs of - * currently assigned functions and will certainly be changed - * before prime time. - */ - cnt = X509_get_ext_count(cert); - for (i = 0; i < cnt; i++) { - ext = X509_get_ext(cert, i); - method = X509V3_EXT_get(ext); - temp = OBJ_obj2nid(ext->object); - switch (temp) { - - /* - * If a key_usage field is present, we decode whether - * this is a trusted or private certificate. This is - * dorky; all we want is to compare NIDs, but OpenSSL - * insists on BIO text strings. - */ - case NID_ext_key_usage: - bp = BIO_new(BIO_s_mem()); - X509V3_EXT_print(bp, ext, 0, 0); - BIO_gets(bp, pathbuf, MAXFILENAME); - BIO_free(bp); -#if DEBUG - if (debug) - printf("cert_parse: %s: %s\n", - OBJ_nid2ln(temp), pathbuf); -#endif - if (strcmp(pathbuf, "Trust Root") == 0) - ret->flags |= CERT_TRUST; - else if (strcmp(pathbuf, "Private") == 0) - ret->flags |= CERT_PRIV; - break; - - /* - * If a NID_subject_key_identifier field is present, it - * contains the GQ public key. - */ - case NID_subject_key_identifier: - ret->grplen = ext->value->length - 2; - ret->grpkey = emalloc(ret->grplen); - memcpy(ret->grpkey, &ext->value->data[2], - ret->grplen); - break; - } - } - - /* - * If certificate is self signed, verify signature. - */ - if (strcmp(ret->subject, ret->issuer) == 0) { - if (!X509_verify(cert, ret->pkey)) { - msyslog(LOG_INFO, - "cert_parse: signature not verified %s", - pathbuf); - cert_free(ret); - X509_free(cert); - return (NULL); - } - } - - /* - * Verify certificate valid times. Note that certificates cannot - * be retroactive. - */ - if (ret->first > ret->last || ret->first < fstamp) { - msyslog(LOG_INFO, - "cert_parse: invalid certificate %s first %u last %u fstamp %u", - ret->subject, ret->first, ret->last, fstamp); - cert_free(ret); - X509_free(cert); - return (NULL); - } - - /* - * Build the value structure to sign and send later. - */ - ret->cert.fstamp = htonl(fstamp); - ret->cert.vallen = htonl(len); - ret->cert.ptr = emalloc(len); - memcpy(ret->cert.ptr, asn1cert, len); -#ifdef DEBUG - if (debug > 1) - X509_print_fp(stdout, cert); -#endif - X509_free(cert); - return (ret); -} - - -/* - * cert_sign - sign x509 certificate equest and update value structure. - * - * The certificate request includes a copy of the host certificate, - * which includes the version number, subject name and public key of the - * host. The resulting certificate includes these values plus the - * serial number, issuer name and valid interval of the server. The - * valid interval extends from the current time to the same time one - * year hence. This may extend the life of the signed certificate beyond - * that of the signer certificate. - * - * It is convenient to use the NTP seconds of the current time as the - * serial number. In the value structure the timestamp is the current - * time and the filestamp is taken from the extension field. Note this - * routine is called only when the client clock is synchronized to a - * proventic source, so timestamp comparisons are valid. - * - * The host certificate is valid from the time it was generated for a - * period of one year. A signed certificate is valid from the time of - * signature for a period of one year, but only the host certificate (or - * sign certificate if used) is actually used to encrypt and decrypt - * signatures. The signature trail is built from the client via the - * intermediate servers to the trusted server. Each signature on the - * trail must be valid at the time of signature, but it could happen - * that a signer certificate expire before the signed certificate, which - * remains valid until its expiration. - * - * Returns - * XEVNT_OK success - * XEVNT_PUB bad or missing public key - * XEVNT_CRT bad or missing certificate - * XEVNT_VFY certificate not verified - * XEVNT_PER host certificate expired - */ -static int -cert_sign( - struct exten *ep, /* extension field pointer */ - struct value *vp /* value pointer */ - ) -{ - X509 *req; /* X509 certificate request */ - X509 *cert; /* X509 certificate */ - X509_EXTENSION *ext; /* certificate extension */ - ASN1_INTEGER *serial; /* serial number */ - X509_NAME *subj; /* distinguished (common) name */ - EVP_PKEY *pkey; /* public key */ - EVP_MD_CTX ctx; /* message digest context */ - tstamp_t tstamp; /* NTP timestamp */ - u_int len; - u_char *ptr; - int i, temp; - - /* - * Decode ASN.1 objects and construct certificate structure. - * Make sure the system clock is synchronized to a proventic - * source. + * Make sure the system clock is synchronized to a proventic + * source. */ tstamp = crypto_time(); if (tstamp == 0) return (XEVNT_TSP); - if (tstamp < cinfo->first || tstamp > cinfo->last) - return (XEVNT_PER); - ptr = (u_char *)ep->pkt; if ((req = d2i_X509(NULL, &ptr, ntohl(ep->vallen))) == NULL) { - msyslog(LOG_ERR, "cert_sign %s\n", + msyslog(LOG_ERR, "cert_sign: %s", ERR_error_string(ERR_get_error(), NULL)); return (XEVNT_CRT); } @@ -3253,16 +2966,17 @@ * Extract public key and check for errors. */ if ((pkey = X509_get_pubkey(req)) == NULL) { - msyslog(LOG_ERR, "cert_sign %s\n", + msyslog(LOG_ERR, "cert_sign: %s", ERR_error_string(ERR_get_error(), NULL)); X509_free(req); return (XEVNT_PUB); } /* - * Generate X509 certificate signed by this server. For this - * purpose the issuer name is the server name. Also copy any - * extensions that might be present. + * Generate X509 certificate signed by this server. If this is a + * trusted host, the issuer name is the group name; otherwise, + * it is the host name. Also copy any extensions that might be + * present. */ cert = X509_new(); X509_set_version(cert, X509_get_version(req)); @@ -3273,7 +2987,7 @@ X509_gmtime_adj(X509_get_notAfter(cert), YEAR); subj = X509_get_issuer_name(cert); X509_NAME_add_entry_by_txt(subj, "commonName", MBSTRING_ASC, - (u_char *)sys_hostname, strlen(sys_hostname), -1, 0); + hostval.ptr, strlen(hostval.ptr), -1, 0); subj = X509_get_subject_name(req); X509_set_subject_name(cert, subj); X509_set_pubkey(cert, pkey); @@ -3286,11 +3000,16 @@ X509_free(req); /* - * Sign and verify the certificate. + * Sign and verify the client certificate, but only if the host + * certificate has not expired. */ + if (tstamp < cert_host->first || tstamp > cert_host->last) { + X509_free(cert); + return (XEVNT_PER); + } X509_sign(cert, sign_pkey, sign_digest); - if (!X509_verify(cert, sign_pkey)) { - printf("cert_sign\n%s\n", + if (X509_verify(cert, sign_pkey) <= 0) { + msyslog(LOG_ERR, "cert_sign: %s", ERR_error_string(ERR_get_error(), NULL)); X509_free(cert); return (XEVNT_VFY); @@ -3310,12 +3029,14 @@ ptr = vp->ptr; i2d_X509(cert, &ptr); vp->siglen = 0; - vp->sig = emalloc(sign_siglen); - EVP_SignInit(&ctx, sign_digest); - EVP_SignUpdate(&ctx, (u_char *)vp, 12); - EVP_SignUpdate(&ctx, vp->ptr, len); - if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) - vp->siglen = htonl(len); + if (tstamp != 0) { + vp->sig = emalloc(sign_siglen); + EVP_SignInit(&ctx, sign_digest); + EVP_SignUpdate(&ctx, (u_char *)vp, 12); + EVP_SignUpdate(&ctx, vp->ptr, len); + if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) + vp->siglen = htonl(sign_siglen); + } #ifdef DEBUG if (debug > 1) X509_print_fp(stdout, cert); @@ -3326,74 +3047,38 @@ /* - * cert_valid - verify certificate with given public key - * - * This is pretty ugly, as the certificate has to be verified in the - * OpenSSL X509 structure, not in the DER format in the info/value - * structure. - * - * Returns - * XEVNT_OK success - * XEVNT_VFY certificate not verified - */ -int -cert_valid( - struct cert_info *cinf, /* certificate information structure */ - EVP_PKEY *pkey /* public key */ - ) -{ - X509 *cert; /* X509 certificate */ - u_char *ptr; - - if (cinf->flags & CERT_SIGN) - return (XEVNT_OK); - - ptr = (u_char *)cinf->cert.ptr; - cert = d2i_X509(NULL, &ptr, ntohl(cinf->cert.vallen)); - if (cert == NULL || !X509_verify(cert, pkey)) - return (XEVNT_VFY); - - X509_free(cert); - return (XEVNT_OK); -} - - -/* - * cert - install certificate in certificate list + * cert_install - install certificate in certificate cache * * This routine encodes an extension field into a certificate info/value * structure. It searches the certificate list for duplicates and - * expunges whichever is older. It then searches the list for other - * certificates that might be verified by this latest one. Finally, it - * inserts this certificate first on the list. + * expunges whichever is older. Finally, it inserts this certificate + * first on the list. * - * Returns - * XEVNT_OK success - * XEVNT_FSP bad or missing filestamp - * XEVNT_CRT bad or missing certificate + * Returns certificate info pointer if valid, NULL if not. */ -int +struct cert_info * cert_install( struct exten *ep, /* cert info/value */ struct peer *peer /* peer structure */ ) { - struct cert_info *cp, *xp, *yp, **zp; + struct cert_info *cp, *xp, **zp; /* * Parse and validate the signed certificate. If valid, - * construct the info/value structure; otherwise, scamper home. + * construct the info/value structure; otherwise, scamper home + * empty handed. */ - if ((cp = cert_parse((u_char *)ep->pkt, ntohl(ep->vallen), - ntohl(ep->fstamp))) == NULL) - return (XEVNT_CRT); + if ((cp = cert_parse((u_char *)ep->pkt, (long)ntohl(ep->vallen), + (tstamp_t)ntohl(ep->fstamp))) == NULL) + return (NULL); /* * Scan certificate list looking for another certificate with * the same subject and issuer. If another is found with the * same or older filestamp, unlink it and return the goodies to * the heap. If another is found with a later filestamp, discard - * the new one and leave the building. + * the new one and leave the building with the old one. * * Make a note to study this issue again. An earlier certificate * with a long lifetime might be overtaken by a later @@ -3401,112 +3086,314 @@ * earlier signature. However, we gotta find a way to leak old * stuff from the cache, so we do it anyway. */ - yp = cp; zp = &cinfo; for (xp = cinfo; xp != NULL; xp = xp->link) { if (strcmp(cp->subject, xp->subject) == 0 && strcmp(cp->issuer, xp->issuer) == 0) { if (ntohl(cp->cert.fstamp) <= ntohl(xp->cert.fstamp)) { - *zp = xp->link;; - cert_free(xp); - } else { cert_free(cp); - return (XEVNT_FSP); + cp = xp; + } else { + *zp = xp->link; + cert_free(xp); + xp = NULL; } break; } - zp = &xp->link; + zp = &xp->link; + } + if (xp == NULL) { + cp->link = cinfo; + cinfo = cp; + } + cp->flags |= CERT_VALID; + crypto_update(); + return (cp); +} + + +/* + * cert_hike - verify the signature using the issuer public key + * + * Returns + * XEVNT_OK success + * XEVNT_CRT bad or missing certificate + * XEVNT_PER host certificate expired + * XEVNT_VFY certificate not verified + */ +int +cert_hike( + struct peer *peer, /* peer structure pointer */ + struct cert_info *yp /* issuer certificate */ + ) +{ + struct cert_info *xp; /* subject certificate */ + X509 *cert; /* X509 certificate */ + u_char *ptr; + + /* + * Save the issuer on the new certificate, but remember the old + * one. + */ + if (peer->issuer != NULL) + free(peer->issuer); + peer->issuer = emalloc(strlen(yp->issuer) + 1); + strcpy(peer->issuer, yp->issuer); + xp = peer->xinfo; + peer->xinfo = yp; + + /* + * If subject Y matches issuer Y, then the certificate trail is + * complete. If Y is not trusted, the server certificate has yet + * been signed, so keep trying. Otherwise, save the group key + * and light the valid bit. If the host certificate is trusted, + * do not execute a sign exchange. If no identity scheme is in + * use, light the identity and proventic bits. + */ + if (strcmp(yp->subject, yp->issuer) == 0) { + if (!(yp->flags & CERT_TRUST)) + return (XEVNT_OK); + + peer->grpkey = yp->grpkey; + peer->crypto |= CRYPTO_FLAG_CERT; + if (!(peer->crypto & CRYPTO_FLAG_MASK)) + peer->crypto |= CRYPTO_FLAG_VRFY | + CRYPTO_FLAG_PROV; + + /* + * If the server has an an identity scheme, fetch the + * identity credentials. If not, the identity is + * verified only by the trusted certificate. The next + * signature will set the server proventic. + */ + if (!(peer->crypto & CRYPTO_FLAG_MASK) || + sys_groupname == NULL) + peer->crypto |= CRYPTO_FLAG_VRFY; + } + + /* + * If X exists, verify signature X using public key Y. + */ + if (xp == NULL) + return (XEVNT_OK); + + ptr = (u_char *)xp->cert.ptr; + cert = d2i_X509(NULL, &ptr, ntohl(xp->cert.vallen)); + if (cert == NULL) { + xp->flags |= CERT_ERROR; + return (XEVNT_CRT); + } + if (X509_verify(cert, yp->pkey) <= 0) { + X509_free(cert); + xp->flags |= CERT_ERROR; + return (XEVNT_VFY); + } + X509_free(cert); + + /* + * Signature X is valid only if it begins during the + * lifetime of Y. + */ + if (xp->first < yp->first || xp->first > yp->last) { + xp->flags |= CERT_ERROR; + return (XEVNT_PER); + } + xp->flags |= CERT_SIGN; + return (XEVNT_OK); +} + + +/* + * cert_parse - parse x509 certificate and create info/value structures. + * + * The server certificate includes the version number, issuer name, + * subject name, public key and valid date interval. If the issuer name + * is the same as the subject name, the certificate is self signed and + * valid only if the server is configured as trustable. If the names are + * different, another issuer has signed the server certificate and + * vouched for it. In this case the server certificate is valid if + * verified by the issuer public key. + * + * Returns certificate info/value pointer if valid, NULL if not. + */ +struct cert_info * /* certificate information structure */ +cert_parse( + u_char *asn1cert, /* X509 certificate */ + long len, /* certificate length */ + tstamp_t fstamp /* filestamp */ + ) +{ + X509 *cert; /* X509 certificate */ + X509_EXTENSION *ext; /* X509v3 extension */ + struct cert_info *ret; /* certificate info/value */ + BIO *bp; + char pathbuf[MAXFILENAME]; + u_char *ptr; + int temp, cnt, i; + + /* + * Decode ASN.1 objects and construct certificate structure. + */ + ptr = asn1cert; + if ((cert = d2i_X509(NULL, &ptr, len)) == NULL) { + msyslog(LOG_ERR, "cert_parse: %s", + ERR_error_string(ERR_get_error(), NULL)); + return (NULL); + } +#ifdef DEBUG + if (debug > 1) + X509_print_fp(stdout, cert); +#endif + + /* + * Extract version, subject name and public key. + */ + ret = emalloc(sizeof(struct cert_info)); + memset(ret, 0, sizeof(struct cert_info)); + if ((ret->pkey = X509_get_pubkey(cert)) == NULL) { + msyslog(LOG_ERR, "cert_parse: %s", + ERR_error_string(ERR_get_error(), NULL)); + cert_free(ret); + X509_free(cert); + return (NULL); + } + ret->version = X509_get_version(cert); + X509_NAME_oneline(X509_get_subject_name(cert), pathbuf, + MAXFILENAME); + ptr = strstr(pathbuf, "CN="); + if (ptr == NULL) { + msyslog(LOG_NOTICE, "cert_parse: invalid subject %s", + pathbuf); + cert_free(ret); + X509_free(cert); + return (NULL); + } + ret->subject = estrdup(ptr + 3); + + /* + * Extract remaining objects. Note that the NTP serial number is + * the NTP seconds at the time of signing, but this might not be + * the case for other authority. We don't bother to check the + * objects at this time, since the real crunch can happen only + * when the time is valid but not yet certificated. + */ + ret->nid = OBJ_obj2nid(cert->cert_info->signature->algorithm); + ret->digest = (const EVP_MD *)EVP_get_digestbynid(ret->nid); + ret->serial = + (u_long)ASN1_INTEGER_get(X509_get_serialNumber(cert)); + X509_NAME_oneline(X509_get_issuer_name(cert), pathbuf, + MAXFILENAME); + if ((ptr = strstr(pathbuf, "CN=")) == NULL) { + msyslog(LOG_NOTICE, "cert_parse: invalid issuer %s", + pathbuf); + cert_free(ret); + X509_free(cert); + return (NULL); + } + ret->issuer = estrdup(ptr + 3); + ret->first = asn2ntp(X509_get_notBefore(cert)); + ret->last = asn2ntp(X509_get_notAfter(cert)); + + /* + * Extract extension fields. These are ad hoc ripoffs of + * currently assigned functions and will certainly be changed + * before prime time. + */ + cnt = X509_get_ext_count(cert); + for (i = 0; i < cnt; i++) { + ext = X509_get_ext(cert, i); + temp = OBJ_obj2nid(ext->object); + switch (temp) { + + /* + * If a key_usage field is present, we decode whether + * this is a trusted or private certificate. This is + * dorky; all we want is to compare NIDs, but OpenSSL + * insists on BIO text strings. + */ + case NID_ext_key_usage: + bp = BIO_new(BIO_s_mem()); + X509V3_EXT_print(bp, ext, 0, 0); + BIO_gets(bp, pathbuf, MAXFILENAME); + BIO_free(bp); + if (strcmp(pathbuf, "Trust Root") == 0) + ret->flags |= CERT_TRUST; + else if (strcmp(pathbuf, "Private") == 0) + ret->flags |= CERT_PRIV; +#if DEBUG + if (debug) + printf("cert_parse: %s: %s\n", + OBJ_nid2ln(temp), pathbuf); +#endif + break; + + /* + * If a NID_subject_key_identifier field is present, it + * contains the GQ public key. + */ + case NID_subject_key_identifier: + ret->grpkey = BN_bin2bn(&ext->value->data[2], + ext->value->length - 2, NULL); + /* fall through */ +#if DEBUG + default: + if (debug) + printf("cert_parse: %s\n", + OBJ_nid2ln(temp)); +#endif + } + } + if (strcmp(ret->subject, ret->issuer) == 0) { + + /* + * If certificate is self signed, verify signature. + */ + if (X509_verify(cert, ret->pkey) <= 0) { + msyslog(LOG_NOTICE, + "cert_parse: signature not verified %s", + ret->subject); + cert_free(ret); + X509_free(cert); + return (NULL); + } + } else { + + /* + * Check for a certificate loop. + */ + if (strcmp(hostval.ptr, ret->issuer) == 0) { + msyslog(LOG_NOTICE, + "cert_parse: certificate trail loop %s", + ret->subject); + cert_free(ret); + X509_free(cert); + return (NULL); + } } - yp->link = cinfo; - cinfo = yp; /* - * Scan the certificate list to see if Y is signed by X. This is - * independent of order. + * Verify certificate valid times. Note that certificates cannot + * be retroactive. */ - for (yp = cinfo; yp != NULL; yp = yp->link) { - for (xp = cinfo; xp != NULL; xp = xp->link) { - - /* - * If the issuer of certificate Y matches the - * subject of certificate X, verify the - * signature of Y using the public key of X. If - * so, X signs Y. - */ - if (strcmp(yp->issuer, xp->subject) != 0 || - xp->flags & CERT_ERROR) - continue; - - if (cert_valid(yp, xp->pkey) != XEVNT_OK) { - yp->flags |= CERT_ERROR; - continue; - } - - /* - * The signature Y is valid only if it begins - * during the lifetime of X; however, it is not - * necessarily an error, since some other - * certificate might sign Y. - */ - if (yp->first < xp->first || yp->first > - xp->last) - continue; - - yp->flags |= CERT_SIGN; - - /* - * If X is trusted, then Y is trusted. Note that - * we might stumble over a self-signed - * certificate that is not trusted, at least - * temporarily. This can happen when a dude - * first comes up, but has not synchronized the - * clock and had its certificate signed by its - * server. In case of broken certificate trail, - * this might result in a loop that could - * persist until timeout. - */ - if (!(xp->flags & (CERT_TRUST | CERT_VALID))) - continue; - - yp->flags |= CERT_VALID; - - /* - * If subject Y matches the server subject name, - * then Y has completed the certificate trail. - * Save the group key and light the valid bit. - */ - if (strcmp(yp->subject, peer->subject) != 0) - continue; - - if (yp->grpkey != NULL) { - if (peer->grpkey != NULL) - BN_free(peer->grpkey); - peer->grpkey = BN_bin2bn(yp->grpkey, - yp->grplen, NULL); - } - peer->crypto |= CRYPTO_FLAG_VALID; - - /* - * If the server has an an identity scheme, - * fetch the identity credentials. If not, the - * identity is verified only by the trusted - * certificate. The next signature will set the - * server proventic. - */ - if (peer->crypto & (CRYPTO_FLAG_GQ | - CRYPTO_FLAG_IFF | CRYPTO_FLAG_MV)) - continue; - - peer->crypto |= CRYPTO_FLAG_VRFY; - } + if (ret->first > ret->last || ret->first < fstamp) { + msyslog(LOG_NOTICE, + "cert_parse: invalid times %s first %u last %u fstamp %u", + ret->subject, ret->first, ret->last, fstamp); + cert_free(ret); + X509_free(cert); + return (NULL); } /* - * That was awesome. Now update the timestamps and signatures. + * Build the value structure to sign and send later. */ - crypto_update(); - return (XEVNT_OK); + ret->cert.fstamp = htonl(fstamp); + ret->cert.vallen = htonl(len); + ret->cert.ptr = emalloc(len); + memcpy(ret->cert.ptr, asn1cert, len); + X509_free(cert); + return (ret); } @@ -3525,42 +3412,47 @@ if (cinf->issuer != NULL) free(cinf->issuer); if (cinf->grpkey != NULL) - free(cinf->grpkey); + BN_free(cinf->grpkey); value_free(&cinf->cert); free(cinf); } /* - *********************************************************************** - * * - * The following routines are used only at initialization time * - * * - *********************************************************************** - */ -/* - * crypto_key - load cryptographic parameters and keys from files - * - * This routine loads a PEM-encoded public/private key pair and extracts - * the filestamp from the file name. + * crypto_key - load cryptographic parameters and keys * - * Returns public key pointer if valid, NULL if not. Side effect updates - * the filestamp if valid. + * This routine searches the key cache for matching name in the form + * ntpkey__, where is one of host, sign, iff, gq, mv, + * and is the host/group name. If not found, it tries to load a + * PEM-encoded file of the same name and extracts the filestamp from + * the first line of the file name. It returns the key pointer if valid, + * NULL if not. */ -static EVP_PKEY * +static struct pkey_info * crypto_key( char *cp, /* file name */ - tstamp_t *fstamp /* filestamp */ + char *passwd1, /* password */ + sockaddr_u *addr /* IP address */ ) { FILE *str; /* file handle */ + struct pkey_info *pkp; /* generic key */ EVP_PKEY *pkey = NULL; /* public/private key */ + tstamp_t fstamp; char filename[MAXFILENAME]; /* name of key file */ char linkname[MAXFILENAME]; /* filestamp buffer) */ char statstr[NTP_MAXSTRLEN]; /* statistics for filegen */ char *ptr; /* + * Search the key cache for matching key and name. + */ + for (pkp = pkinfo; pkp != NULL; pkp = pkp->link) { + if (strcmp(cp, pkp->name) == 0) + return (pkp); + } + + /* * Open the key file. If the first character of the file name is * not '/', prepend the keys directory string. If something goes * wrong, abandon ship. @@ -3577,64 +3469,83 @@ * Read the filestamp, which is contained in the first line. */ if ((ptr = fgets(linkname, MAXFILENAME, str)) == NULL) { - msyslog(LOG_ERR, "crypto_key: no data %s\n", + msyslog(LOG_ERR, "crypto_key: empty file %s", filename); - (void)fclose(str); + fclose(str); return (NULL); } if ((ptr = strrchr(ptr, '.')) == NULL) { - msyslog(LOG_ERR, "crypto_key: no filestamp %s\n", + msyslog(LOG_ERR, "crypto_key: no filestamp %s", filename); - (void)fclose(str); + fclose(str); return (NULL); } - if (sscanf(++ptr, "%u", fstamp) != 1) { - msyslog(LOG_ERR, "crypto_key: invalid timestamp %s\n", + if (sscanf(++ptr, "%u", &fstamp) != 1) { + msyslog(LOG_ERR, "crypto_key: invalid filestamp %s", filename); - (void)fclose(str); + fclose(str); return (NULL); } /* - * Read and decrypt PEM-encoded private key. + * Read and decrypt PEM-encoded private key. If it fails to + * decrypt, game over. */ - pkey = PEM_read_PrivateKey(str, NULL, NULL, passwd); + pkey = PEM_read_PrivateKey(str, NULL, NULL, passwd1); fclose(str); if (pkey == NULL) { - msyslog(LOG_ERR, "crypto_key %s\n", + msyslog(LOG_ERR, "crypto_key: %s", ERR_error_string(ERR_get_error(), NULL)); - return (NULL); + exit (-1); } /* + * Make a new entry in the key cache. + */ + pkp = emalloc(sizeof(struct pkey_info)); + pkp->link = pkinfo; + pkinfo = pkp; + pkp->pkey = pkey; + pkp->name = emalloc(strlen(cp) + 1); + pkp->fstamp = fstamp; + strcpy(pkp->name, cp); + + /* * Leave tracks in the cryptostats. */ if ((ptr = strrchr(linkname, '\n')) != NULL) *ptr = '\0'; snprintf(statstr, NTP_MAXSTRLEN, "%s mod %d", &linkname[2], EVP_PKEY_size(pkey) * 8); - record_crypto_stats(NULL, statstr); + record_crypto_stats(addr, statstr); #ifdef DEBUG if (debug) printf("crypto_key: %s\n", statstr); if (debug > 1) { if (pkey->type == EVP_PKEY_DSA) DSA_print_fp(stdout, pkey->pkey.dsa, 0); - else + else if (pkey->type == EVP_PKEY_RSA) RSA_print_fp(stdout, pkey->pkey.rsa, 0); } #endif - return (pkey); + return (pkp); } /* + *********************************************************************** + * * + * The following routines are used only at initialization time * + * * + *********************************************************************** + */ +/* * crypto_cert - load certificate from file * - * This routine loads a X.509 RSA or DSA certificate from a file and + * This routine loads an X.509 RSA or DSA certificate from a file and * constructs a info/cert value structure for this machine. The * structure includes a filestamp extracted from the file name. Later - * the certificate can be sent to another machine by request. + * the certificate can be sent to another machine on request. * * Returns certificate info/value pointer if valid, NULL if not. */ @@ -3671,21 +3582,21 @@ * Read the filestamp, which is contained in the first line. */ if ((ptr = fgets(linkname, MAXFILENAME, str)) == NULL) { - msyslog(LOG_ERR, "crypto_cert: no data %s\n", + msyslog(LOG_ERR, "crypto_cert: empty file %s", filename); - (void)fclose(str); + fclose(str); return (NULL); } if ((ptr = strrchr(ptr, '.')) == NULL) { msyslog(LOG_ERR, "crypto_cert: no filestamp %s\n", filename); - (void)fclose(str); + fclose(str); return (NULL); } if (sscanf(++ptr, "%u", &fstamp) != 1) { msyslog(LOG_ERR, "crypto_cert: invalid filestamp %s\n", filename); - (void)fclose(str); + fclose(str); return (NULL); } @@ -3693,35 +3604,35 @@ * Read PEM-encoded certificate and install. */ if (!PEM_read(str, &name, &header, &data, &len)) { - msyslog(LOG_ERR, "crypto_cert %s\n", + msyslog(LOG_ERR, "crypto_cert: %s\n", ERR_error_string(ERR_get_error(), NULL)); - (void)fclose(str); + fclose(str); return (NULL); } + fclose(str); free(header); - if (strcmp(name, "CERTIFICATE") !=0) { - msyslog(LOG_INFO, "crypto_cert: wrong PEM type %s", + if (strcmp(name, "CERTIFICATE") != 0) { + msyslog(LOG_NOTICE, "crypto_cert: wrong PEM type %s", name); free(name); free(data); - (void)fclose(str); return (NULL); } free(name); /* - * Parse certificate and generate info/value structure. + * Parse certificate and generate info/value structure. The + * pointer and copy nonsense is due something broken in Solaris. */ ret = cert_parse(data, len, fstamp); free(data); - (void)fclose(str); if (ret == NULL) return (NULL); if ((ptr = strrchr(linkname, '\n')) != NULL) *ptr = '\0'; - snprintf(statstr, NTP_MAXSTRLEN, - "%s 0x%x len %lu", &linkname[2], ret->flags, len); + snprintf(statstr, NTP_MAXSTRLEN, "%s 0x%x len %lu", + &linkname[2], ret->flags, len); record_crypto_stats(NULL, statstr); #ifdef DEBUG if (debug) @@ -3732,227 +3643,113 @@ /* - * crypto_tai - load leapseconds table from file - * - * This routine loads the ERTS leapsecond file in NIST text format, - * converts to a value structure and extracts a filestamp from the file - * name. The data are used to establish the TAI offset from UTC, which - * is provided to the kernel if supported. Later the data can be sent to - * another machine on request. - */ -static void -crypto_tai( - char *cp /* file name */ - ) -{ - FILE *str; /* file handle */ - char buf[NTP_MAXSTRLEN]; /* file line buffer */ - u_int32 leapsec[MAX_LEAP]; /* NTP time at leaps */ - int offset; /* offset at leap (s) */ - char filename[MAXFILENAME]; /* name of leapseconds file */ - char linkname[MAXFILENAME]; /* file link (for filestamp) */ - char statstr[NTP_MAXSTRLEN]; /* statistics for filegen */ - tstamp_t fstamp; /* filestamp */ - u_int len; - u_int32 *ptr; - char *dp; - int rval, i, j; - - /* - * Open the file and discard comment lines. If the first - * character of the file name is not '/', prepend the keys - * directory string. If the file is not found, not to worry; it - * can be retrieved over the net. But, if it is found with - * errors, we crash and burn. - */ - if (*cp == '/') - strcpy(filename, cp); - else - snprintf(filename, MAXFILENAME, "%s/%s", keysdir, cp); - if ((str = fopen(filename, "r")) == NULL) - return; - - /* - * Extract filestamp if present. - */ - rval = readlink(filename, linkname, MAXFILENAME - 1); - if (rval > 0) { - linkname[rval] = '\0'; - dp = strrchr(linkname, '.'); - } else { - dp = strrchr(filename, '.'); - } - if (dp != NULL) - sscanf(++dp, "%u", &fstamp); - else - fstamp = 0; - tai_leap.fstamp = htonl(fstamp); - - /* - * We are rather paranoid here, since an intruder might cause a - * coredump by infiltrating naughty values. Empty lines and - * comments are ignored. Other lines must begin with two - * integers followed by junk or comments. The first integer is - * the NTP seconds of leap insertion, the second is the offset - * of TAI relative to UTC after that insertion. The second word - * must equal the initial insertion of ten seconds on 1 January - * 1972 plus one second for each succeeding insertion. - */ - i = 0; - while (i < MAX_LEAP) { - dp = fgets(buf, NTP_MAXSTRLEN - 1, str); - if (dp == NULL) - break; - - if (strlen(buf) < 1) - continue; - - if (*buf == '#') - continue; - - if (sscanf(buf, "%u %d", &leapsec[i], &offset) != 2) - continue; - - if (i != offset - TAI_1972) - break; - - i++; - } - fclose(str); - if (dp != NULL) { - msyslog(LOG_INFO, - "crypto_tai: leapseconds file %s error %d", cp, - rval); - exit (-1); - } - - /* - * The extension field table entries consists of the NTP seconds - * of leap insertion in network byte order. - */ - len = i * sizeof(u_int32); - tai_leap.vallen = htonl(len); - ptr = emalloc(len); - tai_leap.ptr = (u_char *)ptr; - for (j = 0; j < i; j++) - *ptr++ = htonl(leapsec[j]); - crypto_flags |= CRYPTO_FLAG_TAI; - snprintf(statstr, NTP_MAXSTRLEN, "%s fs %u leap %u len %u", cp, fstamp, - leapsec[--j], len); - record_crypto_stats(NULL, statstr); -#ifdef DEBUG - if (debug) - printf("crypto_tai: %s\n", statstr); -#endif -} - - -/* - * crypto_setup - load keys, certificate and leapseconds table + * crypto_setup - load keys, certificate and identity parameters * * This routine loads the public/private host key and certificate. If * available, it loads the public/private sign key, which defaults to - * the host key, and leapseconds table. The host key must be RSA, but - * the sign key can be either RSA or DSA. In either case, the public key - * on the certificate must agree with the sign key. + * the host key. The host key must be RSA, but the sign key can be + * either RSA or DSA. If a trusted certificate, it loads the identity + * parameters. In either case, the public key on the certificate must + * agree with the sign key. + * + * Required but missing files and inconsistent data and errors are + * fatal. Allowing configuration to continue would be hazardous and + * require really messy error checks. */ void crypto_setup(void) { - EVP_PKEY *pkey; /* private/public key pair */ + struct pkey_info *pinfo; /* private/public key */ char filename[MAXFILENAME]; /* file name buffer */ + char * randfile; + char statstr[NTP_MAXSTRLEN]; /* statistics for filegen */ l_fp seed; /* crypto PRNG seed as NTP timestamp */ - tstamp_t fstamp; /* filestamp */ - tstamp_t sstamp; /* sign filestamp */ - u_int len, bytes; + u_int len; + int bytes; u_char *ptr; /* - * Initialize structures. + * Check for correct OpenSSL version and avoid initialization in + * the case of multiple crypto commands. */ - if (!crypto_flags) + if (crypto_flags & CRYPTO_FLAG_ENAB) { + msyslog(LOG_NOTICE, + "crypto_setup: spurious crypto command"); return; - - gethostname(filename, MAXFILENAME); - bytes = strlen(filename) + 1; - sys_hostname = emalloc(bytes); - memcpy(sys_hostname, filename, bytes); - if (passwd == NULL) - passwd = sys_hostname; - memset(&hostval, 0, sizeof(hostval)); - memset(&pubkey, 0, sizeof(pubkey)); - memset(&tai_leap, 0, sizeof(tai_leap)); + } + ssl_check_version(); /* * Load required random seed file and seed the random number - * generator. Be default, it is found in the user home + * generator. Be default, it is found as .rnd in the user home * directory. The root home directory may be / or /root, * depending on the system. Wiggle the contents a bit and write * it back so the sequence does not repeat when we next restart. */ - ERR_load_crypto_strings(); - if (rand_file == NULL) { - if ((RAND_file_name(filename, MAXFILENAME)) != NULL) { - rand_file = emalloc(strlen(filename) + 1); - strcpy(rand_file, filename); + if (!RAND_status()) { + if (rand_file == NULL) { + RAND_file_name(filename, sizeof(filename)); + randfile = filename; + } else if (*rand_file != '/') { + snprintf(filename, sizeof(filename), "%s/%s", + keysdir, rand_file); + randfile = filename; + } else + randfile = rand_file; + + if ((bytes = RAND_load_file(randfile, -1)) == 0) { + msyslog(LOG_ERR, + "crypto_setup: random seed file %s missing", + randfile); + exit (-1); } - } else if (*rand_file != '/') { - snprintf(filename, MAXFILENAME, "%s/%s", keysdir, - rand_file); - free(rand_file); - rand_file = emalloc(strlen(filename) + 1); - strcpy(rand_file, filename); - } - if (rand_file == NULL) { - msyslog(LOG_ERR, - "crypto_setup: random seed file not specified"); - exit (-1); - } - if ((bytes = RAND_load_file(rand_file, -1)) == 0) { - msyslog(LOG_ERR, - "crypto_setup: random seed file %s not found\n", - rand_file); - exit (-1); - } - get_systime(&seed); - RAND_seed(&seed, sizeof(l_fp)); - RAND_write_file(rand_file); - OpenSSL_add_all_algorithms(); + get_systime(&seed); + RAND_seed(&seed, sizeof(l_fp)); + RAND_write_file(randfile); #ifdef DEBUG - if (debug) - printf( - "crypto_setup: OpenSSL version %lx random seed file %s bytes read %d\n", - SSLeay(), rand_file, bytes); + if (debug) + printf( + "crypto_setup: OpenSSL version %lx random seed file %s bytes read %d\n", + SSLeay(), randfile, bytes); #endif + } /* - * Load required host key from file "ntpkey_host_". It - * also becomes the default sign key. + * Initialize structures. */ - if (host_file == NULL) { - snprintf(filename, MAXFILENAME, "ntpkey_host_%s", - sys_hostname); - host_file = emalloc(strlen(filename) + 1); - strcpy(host_file, filename); + if (sys_hostname == NULL) { + gethostname(filename, MAXFILENAME); + sys_hostname = emalloc(strlen(filename) + 1); + strcpy(sys_hostname, filename); } - pkey = crypto_key(host_file, &fstamp); - if (pkey == NULL) { + if (passwd == NULL) + passwd = sys_hostname; + memset(&hostval, 0, sizeof(hostval)); + memset(&pubkey, 0, sizeof(pubkey)); + memset(&tai_leap, 0, sizeof(tai_leap)); + + /* + * Load required host key from file "ntpkey_host_". If + * no host key file is not found or has invalid password, life + * as we know it ends. The host key also becomes the default + * sign key. + */ + snprintf(filename, MAXFILENAME, "ntpkey_host_%s", sys_hostname); + pinfo = crypto_key(filename, passwd, NULL); + if (pinfo == NULL) { msyslog(LOG_ERR, "crypto_setup: host key file %s not found or corrupt", - host_file); + filename); exit (-1); } - host_pkey = pkey; - sign_pkey = pkey; - sstamp = fstamp; - hostval.fstamp = htonl(fstamp); - if (host_pkey->type != EVP_PKEY_RSA) { + if (pinfo->pkey->type != EVP_PKEY_RSA) { msyslog(LOG_ERR, "crypto_setup: host key is not RSA key type"); exit (-1); } - hostval.vallen = htonl(strlen(sys_hostname)); - hostval.ptr = (u_char *)sys_hostname; + host_pkey = pinfo->pkey; + sign_pkey = host_pkey; + hostval.fstamp = htonl(pinfo->fstamp); /* * Construct public key extension field for agreement scheme. @@ -3961,228 +3758,169 @@ ptr = emalloc(len); pubkey.ptr = ptr; i2d_PublicKey(host_pkey, &ptr); - pubkey.vallen = htonl(len); pubkey.fstamp = hostval.fstamp; + pubkey.vallen = htonl(len); /* * Load optional sign key from file "ntpkey_sign_". If - * loaded, it becomes the sign key. - */ - if (sign_file == NULL) { - snprintf(filename, MAXFILENAME, "ntpkey_sign_%s", - sys_hostname); - sign_file = emalloc(strlen(filename) + 1); - strcpy(sign_file, filename); - } - pkey = crypto_key(sign_file, &fstamp); - if (pkey != NULL) { - sign_pkey = pkey; - sstamp = fstamp; - } - sign_siglen = EVP_PKEY_size(sign_pkey); - - /* - * Load optional IFF parameters from file - * "ntpkey_iff_". - */ - if (iffpar_file == NULL) { - snprintf(filename, MAXFILENAME, "ntpkey_iff_%s", - sys_hostname); - iffpar_file = emalloc(strlen(filename) + 1); - strcpy(iffpar_file, filename); - } - iffpar_pkey = crypto_key(iffpar_file, &if_fstamp); - if (iffpar_pkey != NULL) - crypto_flags |= CRYPTO_FLAG_IFF; - - /* - * Load optional GQ parameters from file "ntpkey_gq_". - */ - if (gqpar_file == NULL) { - snprintf(filename, MAXFILENAME, "ntpkey_gq_%s", - sys_hostname); - gqpar_file = emalloc(strlen(filename) + 1); - strcpy(gqpar_file, filename); - } - gqpar_pkey = crypto_key(gqpar_file, &gq_fstamp); - if (gqpar_pkey != NULL) - crypto_flags |= CRYPTO_FLAG_GQ; - - /* - * Load optional MV parameters from file "ntpkey_mv_". + * available, it becomes the sign key. */ - if (mvpar_file == NULL) { - snprintf(filename, MAXFILENAME, "ntpkey_mv_%s", - sys_hostname); - mvpar_file = emalloc(strlen(filename) + 1); - strcpy(mvpar_file, filename); - } - mvpar_pkey = crypto_key(mvpar_file, &mv_fstamp); - if (mvpar_pkey != NULL) - crypto_flags |= CRYPTO_FLAG_MV; + snprintf(filename, MAXFILENAME, "ntpkey_sign_%s", sys_hostname); + pinfo = crypto_key(filename, passwd, NULL); if (pinfo != NULL) + sign_pkey = pinfo->pkey; /* * Load required certificate from file "ntpkey_cert_". */ - if (cert_file == NULL) { - snprintf(filename, MAXFILENAME, "ntpkey_cert_%s", - sys_hostname); - cert_file = emalloc(strlen(filename) + 1); - strcpy(cert_file, filename); - } - if ((cinfo = crypto_cert(cert_file)) == NULL) { + snprintf(filename, MAXFILENAME, "ntpkey_cert_%s", sys_hostname); + cinfo = crypto_cert(filename); + if (cinfo == NULL) { msyslog(LOG_ERR, - "certificate file %s not found or corrupt", - cert_file); + "crypto_setup: certificate file %s not found or corrupt", + filename); exit (-1); } + cert_host = cinfo; + sign_digest = cinfo->digest; + sign_siglen = EVP_PKEY_size(sign_pkey); + if (cinfo->flags & CERT_PRIV) + crypto_flags |= CRYPTO_FLAG_PRIV; /* - * The subject name must be the same as the host name, unless - * the certificate is private, in which case it may have come - * from another host. + * The certificate must be self-signed. */ - if (!(cinfo->flags & CERT_PRIV) && strcmp(cinfo->subject, - sys_hostname) != 0) { + if (strcmp(cinfo->subject, cinfo->issuer) != 0) { msyslog(LOG_ERR, - "crypto_setup: certificate %s not for this host", - cert_file); - cert_free(cinfo); + "crypto_setup: certificate %s is not self-signed", + filename); exit (-1); } + hostval.vallen = htonl(strlen(cinfo->subject)); + hostval.ptr = cinfo->subject; /* - * It the certificate is trusted, the subject must be the same - * as the issuer, in other words it must be self signed. + * If trusted certificate, the subject name must match the group + * name. */ - if (cinfo->flags & CERT_TRUST && strcmp(cinfo->subject, - cinfo->issuer) != 0) { - if (cert_valid(cinfo, sign_pkey) != XEVNT_OK) { + if (cinfo->flags & CERT_TRUST) { + if (sys_groupname == NULL) { + sys_groupname = hostval.ptr; + } else if (strcmp(hostval.ptr, sys_groupname) != 0) { msyslog(LOG_ERR, - "crypto_setup: certificate %s is trusted, but not self signed.", - cert_file); - cert_free(cinfo); + "crypto_setup: trusted certificate name %s does not match group name %s", + hostval.ptr, sys_groupname); exit (-1); } } - sign_digest = cinfo->digest; - if (cinfo->flags & CERT_PRIV) - crypto_flags |= CRYPTO_FLAG_PRIV; - crypto_flags |= cinfo->nid << 16; + if (sys_groupname != NULL) { + + /* + * Load optional IFF parameters from file + * "ntpkey_iffkey_". + */ + snprintf(filename, MAXFILENAME, "ntpkey_iffkey_%s", + sys_groupname); + iffkey_info = crypto_key(filename, passwd, NULL); + if (iffkey_info != NULL) + crypto_flags |= CRYPTO_FLAG_IFF; + + /* + * Load optional GQ parameters from file + * "ntpkey_gqkey_". + */ + snprintf(filename, MAXFILENAME, "ntpkey_gqkey_%s", + sys_groupname); + gqkey_info = crypto_key(filename, passwd, NULL); + if (gqkey_info != NULL) + crypto_flags |= CRYPTO_FLAG_GQ; + + /* + * Load optional MV parameters from file + * "ntpkey_mvkey_". + */ + snprintf(filename, MAXFILENAME, "ntpkey_mvkey_%s", + sys_groupname); + mvkey_info = crypto_key(filename, passwd, NULL); + if (mvkey_info != NULL) + crypto_flags |= CRYPTO_FLAG_MV; + } /* - * Load optional leapseconds table from file "ntpkey_leap". If - * the file is missing or defective, the values can later be - * retrieved from a server. + * We met the enemy and he is us. Now strike up the dance. */ - if (leap_file == NULL) - leap_file = "ntpkey_leap"; - crypto_tai(leap_file); + crypto_flags |= CRYPTO_FLAG_ENAB | (cinfo->nid << 16); + snprintf(statstr, NTP_MAXSTRLEN, + "setup 0x%x host %s %s", crypto_flags, sys_hostname, + OBJ_nid2ln(cinfo->nid)); + record_crypto_stats(NULL, statstr); #ifdef DEBUG if (debug) - printf( - "crypto_setup: flags 0x%x host %s signature %s\n", - crypto_flags, sys_hostname, OBJ_nid2ln(cinfo->nid)); + printf("crypto_setup: %s\n", statstr); #endif } /* - * crypto_config - configure data from crypto configuration command. + * crypto_config - configure data from the crypto command. */ void crypto_config( int item, /* configuration item */ - char *cp /* file name */ + char *cp /* item name */ ) { - switch (item) { - - /* - * Set random seed file name. - */ - case CRYPTO_CONF_RAND: - rand_file = emalloc(strlen(cp) + 1); - strcpy(rand_file, cp); - break; + int nid; - /* - * Set private key password. - */ - case CRYPTO_CONF_PW: - passwd = emalloc(strlen(cp) + 1); - strcpy(passwd, cp); - break; +#ifdef DEBUG + if (debug > 1) + printf("crypto_config: item %d %s\n", item, cp); +#endif + switch (item) { /* - * Set host file name. + * Set host name (host). */ case CRYPTO_CONF_PRIV: - host_file = emalloc(strlen(cp) + 1); - strcpy(host_file, cp); - break; - - /* - * Set sign key file name. - */ - case CRYPTO_CONF_SIGN: - sign_file = emalloc(strlen(cp) + 1); - strcpy(sign_file, cp); - break; - - /* - * Set iff parameters file name. - */ - case CRYPTO_CONF_IFFPAR: - iffpar_file = emalloc(strlen(cp) + 1); - strcpy(iffpar_file, cp); - break; - - /* - * Set gq parameters file name. - */ - case CRYPTO_CONF_GQPAR: - gqpar_file = emalloc(strlen(cp) + 1); - strcpy(gqpar_file, cp); + sys_hostname = emalloc(strlen(cp) + 1); + strcpy(sys_hostname, cp); break; /* - * Set mv parameters file name. + * Set group name (ident). */ - case CRYPTO_CONF_MVPAR: - mvpar_file = emalloc(strlen(cp) + 1); - strcpy(mvpar_file, cp); + case CRYPTO_CONF_IDENT: + sys_groupname = emalloc(strlen(cp) + 1); + strcpy(sys_groupname, cp); break; /* - * Set identity scheme. + * Set private key password (pw). */ - case CRYPTO_CONF_IDENT: - if (!strcasecmp(cp, "iff")) - ident_scheme |= CRYPTO_FLAG_IFF; - else if (!strcasecmp(cp, "gq")) - ident_scheme |= CRYPTO_FLAG_GQ; - else if (!strcasecmp(cp, "mv")) - ident_scheme |= CRYPTO_FLAG_MV; + case CRYPTO_CONF_PW: + passwd = emalloc(strlen(cp) + 1); + strcpy(passwd, cp); break; /* - * Set certificate file name. + * Set random seed file name (randfile). */ - case CRYPTO_CONF_CERT: - cert_file = emalloc(strlen(cp) + 1); - strcpy(cert_file, cp); + case CRYPTO_CONF_RAND: + rand_file = emalloc(strlen(cp) + 1); + strcpy(rand_file, cp); break; /* - * Set leapseconds file name. + * Set message digest NID. */ - case CRYPTO_CONF_LEAP: - leap_file = emalloc(strlen(cp) + 1); - strcpy(leap_file, cp); + case CRYPTO_CONF_NID: + nid = OBJ_sn2nid(cp); + if (nid == 0) + msyslog(LOG_ERR, + "crypto_config: invalid digest name %s", cp); + else + crypto_nid = nid; break; } - crypto_flags |= CRYPTO_FLAG_ENAB; } # else int ntp_crypto_bs_pubkey; diff -urN src/contrib/ntp/ntpd/ntp_data_structures.c src.ntp/contrib/ntp/ntpd/ntp_data_structures.c --- src/contrib/ntp/ntpd/ntp_data_structures.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/ntp_data_structures.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,199 @@ +/* ntp_data_structures.c + * + * This file contains the data structures used by the ntp configuration + * code and the discrete event simulator. + * + * Written By: Sachin Kamboj + * University of Delaware + * Newark, DE 19711 + * Copyright (c) 2006 + */ + + +#include /* Needed for malloc */ +#include "ntp_data_structures.h" +#include "ntp_stdlib.h" + +/* Priority Queue + * -------------- + * Define a priority queue in which the relative priority of the elements + * is determined by a function 'get_order' which is supplied to the + * priority_queue + */ + + +queue *create_priority_queue(int (*get_order)(void *, void *)) +{ + queue *my_queue = (queue *) emalloc(sizeof(queue)); + my_queue->get_order = get_order; + my_queue->front = NULL; + my_queue->no_of_elements = 0; + return my_queue; +} + + +/* Define a function to "destroy" a priority queue, freeing-up + * all the allocated resources in the process + */ + +void destroy_queue(queue *my_queue) +{ + node *temp = NULL; + + /* Empty out the queue elements if they are not already empty */ + while (my_queue->front != NULL) { + temp = my_queue->front; + my_queue->front = my_queue->front->node_next; + free(temp); + } + + /* Now free the queue */ + free(my_queue); +} + + +/* Define a function to allocate memory for one element + * of the queue. The allocated memory consists of size + * bytes plus the number of bytes needed for bookkeeping + */ + +void *get_node(size_t size) +{ + node *new_node = emalloc(sizeof(*new_node) + size); + new_node->node_next = NULL; + return new_node + 1; +} + +/* Define a function to free the allocated memory for a queue node */ +void free_node(void *my_node) +{ + node *old_node = my_node; + free(old_node - 1); +} + + +void * +next_node( + void *pv + ) +{ + node *pn; + + pn = pv; + pn--; + + if (pn->node_next == NULL) + return NULL; + + return pn->node_next + 1; +} + + +/* Define a function to check if the queue is empty. */ +int empty(queue *my_queue) +{ + return (!my_queue || !my_queue->front); +} + + +void * +queue_head( + queue *q + ) +{ + if (NULL == q || NULL == q->front) + return NULL; + + return q->front + 1; +} + + +/* Define a function to add an element to the priority queue. + * The element is added according to its priority - + * relative priority is given by the get_order function + */ +queue *enqueue(queue *my_queue, void *my_node) +{ + node *new_node = ((node *) my_node) - 1; + node *i = NULL; + node *j = my_queue->front; + + while (j != NULL && ((*my_queue->get_order)(new_node + 1, j + 1) > 0)) { + i = j; + j = j->node_next; + } + + if (i == NULL) { /* Insert at beginning of the queue */ + new_node->node_next = my_queue->front; + my_queue->front = new_node; + } + else { /* Insert Elsewhere, including the end */ + new_node->node_next = i->node_next; + i->node_next = new_node; + } + + ++my_queue->no_of_elements; + return my_queue; +} + + +/* Define a function to dequeue the first element from the priority + * queue and return it + */ + +void *dequeue(queue *my_queue) +{ + node *my_node = my_queue->front; + if (my_node != NULL) { + my_queue->front = my_node->node_next; + --my_queue->no_of_elements; + return (void *)(my_node + 1); + } + else + return NULL; +} + +/* Define a function that returns the number of elements in the + * priority queue + */ +int get_no_of_elements(queue *my_queue) +{ + return my_queue->no_of_elements; +} + +/* Define a function to append a queue onto another. + * Note: there is a faster way (O(1) as opposed to O(n)) + * to do this for simple (FIFO) queues, but we can't rely on + * that for priority queues. (Given the current representation) + * + * I don't anticipate this to be a problem. If it does turn + * out to be a bottleneck, I will consider replacing the + * current implementation with a binomial or fibonacci heap. + */ + +void append_queue(queue *q1, queue *q2) +{ + while (!empty(q2)) + enqueue(q1, dequeue(q2)); + destroy_queue(q2); +} + +/* FIFO Queue + * ---------- + * Use the priority queue to create a traditional FIFO queue. + * The only extra function needed is the create_queue + */ + +/* C is not Lisp and does not allow anonymous lambda functions :-(. + * So define a get_fifo_order function here + */ + +int get_fifo_order(void *el1, void *el2) +{ return 1; +} + +/* Define a function to create a FIFO queue */ + +queue *create_queue() +{ return create_priority_queue(get_fifo_order); +} diff -urN src/contrib/ntp/ntpd/ntp_filegen.c src.ntp/contrib/ntp/ntpd/ntp_filegen.c --- src/contrib/ntp/ntpd/ntp_filegen.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/ntp_filegen.c 2009-12-09 08:36:35.000000000 +0100 @@ -44,34 +44,46 @@ */ #define SUFFIX_SEP '.' +static void filegen_open (FILEGEN *, u_long); +static int valid_fileref (const char *, const char *); +static void filegen_init (const char *, const char *, FILEGEN *); +#ifdef DEBUG +static void filegen_uninit (FILEGEN *); +#endif /* DEBUG */ + + /* - * other constants + * filegen_init */ -#define FGEN_AGE_SECS (24*60*60) /* life time of FILEGEN_AGE in seconds */ -static void filegen_open P((FILEGEN *, u_long)); -static int valid_fileref P((char *, char *)); -#ifdef UNUSED -static FILEGEN *filegen_unregister P((char *)); -#endif /* UNUSED */ +static void +filegen_init( + const char * prefix, + const char * basename, + FILEGEN * fgp + ) +{ + fgp->fp = NULL; + fgp->prefix = prefix; /* Yes, this is TOTALLY lame! */ + fgp->basename = estrdup(basename); + fgp->id = 0; + fgp->type = FILEGEN_DAY; + fgp->flag = FGEN_FLAG_LINK; /* not yet enabled !!*/ +} -static void filegen_init P((char *, const char *, FILEGEN *)); /* - * filegen_init + * filegen_uninit - free memory allocated by filegen_init */ - +#ifdef DEBUG static void -filegen_init(char *prefix, const char *basename, FILEGEN *fp) +filegen_uninit( + FILEGEN * fgp + ) { - fp->fp = NULL; - fp->prefix = prefix; /* Yes, this is TOTALLY lame! */ - fp->basename = (char*)emalloc(strlen(basename) + 1); - strcpy(fp->basename, basename); - fp->id = 0; - fp->type = FILEGEN_DAY; - fp->flag = FGEN_FLAG_LINK; /* not yet enabled !!*/ + free(fgp->basename); } +#endif /* @@ -81,8 +93,8 @@ static void filegen_open( - FILEGEN *gen, - u_long newid + FILEGEN * gen, + u_long newid ) { char *filename; @@ -92,70 +104,83 @@ struct calendar cal; len = strlen(gen->prefix) + strlen(gen->basename) + 1; - basename = (char*)emalloc(len); - sprintf(basename, "%s%s", gen->prefix, gen->basename); + basename = emalloc(len); + snprintf(basename, len, "%s%s", gen->prefix, gen->basename); switch(gen->type) { - default: - msyslog(LOG_ERR, "unsupported file generations type %d for \"%s\" - reverting to FILEGEN_NONE", + + default: + msyslog(LOG_ERR, + "unsupported file generations type %d for " + "\"%s\" - reverting to FILEGEN_NONE", gen->type, basename); gen->type = FILEGEN_NONE; - - /*FALLTHROUGH*/ - case FILEGEN_NONE: - filename = (char*)emalloc(len); - sprintf(filename,"%s", basename); - break; - - case FILEGEN_PID: - filename = (char*)emalloc(len + 1 + 1 + 10); - sprintf(filename,"%s%c#%ld", basename, SUFFIX_SEP, newid); - break; - - case FILEGEN_DAY: - /* You can argue here in favor of using MJD, but - * I would assume it to be easier for humans to interpret dates - * in a format they are used to in everyday life. + /* fall through to FILEGEN_NONE */ + + case FILEGEN_NONE: + filename = estrdup(basename); + break; + + case FILEGEN_PID: + filename = emalloc(len + 1 + 1 + 10); + snprintf(filename, len + 1 + 1 + 10, + "%s%c#%ld", + basename, SUFFIX_SEP, newid); + break; + + case FILEGEN_DAY: + /* + * You can argue here in favor of using MJD, but I + * would assume it to be easier for humans to interpret + * dates in a format they are used to in everyday life. */ - caljulian(newid,&cal); - filename = (char*)emalloc(len + 1 + 4 + 2 + 2); - sprintf(filename, "%s%c%04d%02d%02d", - basename, SUFFIX_SEP, cal.year, cal.month, cal.monthday); + caljulian(newid, &cal); + filename = emalloc(len + 1 + 4 + 2 + 2); + snprintf(filename, len + 1 + 4 + 2 + 2, + "%s%c%04d%02d%02d", + basename, SUFFIX_SEP, + cal.year, cal.month, cal.monthday); break; - - case FILEGEN_WEEK: + + case FILEGEN_WEEK: /* * This is still a hack * - the term week is not correlated to week as it is used * normally - it just refers to a period of 7 days * starting at Jan 1 - 'weeks' are counted starting from zero */ - caljulian(newid,&cal); - filename = (char*)emalloc(len + 1 + 4 + 1 + 2); - sprintf(filename, "%s%c%04dw%02d", - basename, SUFFIX_SEP, cal.year, cal.yearday / 7); - break; - - case FILEGEN_MONTH: - caljulian(newid,&cal); - filename = (char*)emalloc(len + 1 + 4 + 2); - sprintf(filename, "%s%c%04d%02d", - basename, SUFFIX_SEP, cal.year, cal.month); - break; - - case FILEGEN_YEAR: - caljulian(newid,&cal); - filename = (char*)emalloc(len + 1 + 4); - sprintf(filename, "%s%c%04d", basename, SUFFIX_SEP, cal.year); - break; - - case FILEGEN_AGE: - filename = (char*)emalloc(len + 1 + 2 + 10); - sprintf(filename, "%s%ca%08ld", basename, SUFFIX_SEP, newid); - break; + caljulian(newid, &cal); + filename = emalloc(len + 1 + 4 + 1 + 2); + snprintf(filename, len + 1 + 4 + 1 + 2, + "%s%c%04dw%02d", + basename, SUFFIX_SEP, + cal.year, cal.yearday / 7); + break; + + case FILEGEN_MONTH: + caljulian(newid, &cal); + filename = emalloc(len + 1 + 4 + 2); + snprintf(filename, len + 1 + 4 + 2, + "%s%c%04d%02d", + basename, SUFFIX_SEP, cal.year, cal.month); + break; + + case FILEGEN_YEAR: + caljulian(newid, &cal); + filename = emalloc(len + 1 + 4); + snprintf(filename, len + 1 + 4, + "%s%c%04d", + basename, SUFFIX_SEP, cal.year); + break; + + case FILEGEN_AGE: + filename = emalloc(len + 1 + 2 + 10); + snprintf(filename, len + 1 + 2 + 10, + "%s%ca%08ld", + basename, SUFFIX_SEP, newid); } - if (gen->type != FILEGEN_NONE) { + if (FILEGEN_NONE != gen->type) { /* * check for existence of a file with name 'basename' * as we disallow such a file @@ -177,14 +202,18 @@ /* * Oh, it is not linked - try to save it */ - char *savename = (char*)emalloc(len + 1 + 1 + 10 + 10); - sprintf(savename, "%s%c%dC%lu", - basename, - SUFFIX_SEP, - (int) getpid(), - (u_long)conflicts++); + char *savename; + + savename = emalloc(len + 1 + 1 + 10 + 10); + snprintf(savename, len + 1 + 1 + 10 + 10, + "%s%c%dC%lu", + basename, SUFFIX_SEP, + (int)getpid(), conflicts++); + if (rename(basename, savename) != 0) - msyslog(LOG_ERR," couldn't save %s: %m", basename); + msyslog(LOG_ERR, + "couldn't save %s: %m", + basename); free(savename); } else { /* @@ -199,22 +228,28 @@ delete(basename) != 0 #endif ) - msyslog(LOG_ERR, "couldn't unlink %s: %m", basename); + msyslog(LOG_ERR, + "couldn't unlink %s: %m", + basename); } } else { /* * Ehh? Not a regular file ?? strange !!!! */ - msyslog(LOG_ERR, "expected regular file for %s (found mode 0%lo)", - basename, (unsigned long)stats.st_mode); + msyslog(LOG_ERR, + "expected regular file for %s " + "(found mode 0%lo)", + basename, + (unsigned long)stats.st_mode); } } else { /* * stat(..) failed, but it is absolutely correct for * 'basename' not to exist */ - if (errno != ENOENT) - msyslog(LOG_ERR,"stat(%s) failed: %m", basename); + if (ENOENT != errno) + msyslog(LOG_ERR, "stat(%s) failed: %m", + basename); } } @@ -223,13 +258,10 @@ */ fp = fopen(filename, "a"); -#ifdef DEBUG - if (debug > 3) - printf("opening filegen (type=%d/id=%lu) \"%s\"\n", - gen->type, (u_long)newid, filename); -#endif + DPRINTF(4, ("opening filegen (type=%d/id=%lu) \"%s\"\n", + gen->type, newid, filename)); - if (fp == NULL) { + if (NULL == fp) { /* open failed -- keep previous state * * If the file was open before keep the previous generation. @@ -239,11 +271,12 @@ * ignore errors due to missing directories */ - if (errno != ENOENT) - msyslog(LOG_ERR, "can't open %s: %m", filename); + if (ENOENT != errno) + msyslog(LOG_ERR, "can't open %s: %m", filename); } else { - if (gen->fp != NULL) { + if (NULL != gen->fp) { fclose(gen->fp); + gen->fp = NULL; } gen->fp = fp; gen->id = newid; @@ -268,8 +301,10 @@ errno = 0; /* On VMS, don't support FGEN_FLAG_LINK */ #else /* not (VMS) / VXWORKS / WINNT ; DO THE LINK) */ if (link(filename, basename) != 0) - if (errno != EEXIST) - msyslog(LOG_ERR, "can't link(%s, %s): %m", filename, basename); + if (EEXIST != errno) + msyslog(LOG_ERR, + "can't link(%s, %s): %m", + filename, basename); #endif /* SYS_WINNT || VXWORKS */ } /* flags & FGEN_FLAG_LINK */ } /* else fp == NULL */ @@ -289,35 +324,39 @@ void filegen_setup( - FILEGEN *gen, - u_long now + FILEGEN * gen, + u_long now ) { u_long new_gen = ~ (u_long) 0; struct calendar cal; if (!(gen->flag & FGEN_FLAG_ENABLED)) { - if (gen->fp != NULL) - fclose(gen->fp); + if (NULL != gen->fp) { + fclose(gen->fp); + gen->fp = NULL; + } return; } switch (gen->type) { - case FILEGEN_NONE: - if (gen->fp != NULL) return; /* file already open */ + + case FILEGEN_NONE: + if (NULL != gen->fp) + return; /* file already open */ break; - - case FILEGEN_PID: + + case FILEGEN_PID: new_gen = getpid(); break; - case FILEGEN_DAY: + case FILEGEN_DAY: caljulian(now, &cal); cal.hour = cal.minute = cal.second = 0; new_gen = caltontp(&cal); break; - - case FILEGEN_WEEK: + + case FILEGEN_WEEK: /* Would be nice to have a calweekstart() routine */ /* so just use a hack ... */ /* just round time to integral 7 day period for actual year */ @@ -333,33 +372,32 @@ cal.hour = cal.minute = cal.second = 0; new_gen = caltontp(&cal); break; - - case FILEGEN_MONTH: + + case FILEGEN_MONTH: caljulian(now, &cal); cal.yearday = (u_short) (cal.yearday - cal.monthday + 1); cal.monthday = 1; cal.hour = cal.minute = cal.second = 0; new_gen = caltontp(&cal); break; - - case FILEGEN_YEAR: + + case FILEGEN_YEAR: new_gen = calyearstart(now); break; - case FILEGEN_AGE: - new_gen = current_time - (current_time % FGEN_AGE_SECS); + case FILEGEN_AGE: + new_gen = current_time - (current_time % SECSPERDAY); break; } /* * try to open file if not yet open * reopen new file generation file on change of generation id */ - if (gen->fp == NULL || gen->id != new_gen) { -#if DEBUG - if (debug) - printf("filegen %0x %lu %lu %lu\n", gen->type, now, - gen->id, new_gen); -#endif + if (NULL == gen->fp || gen->id != new_gen) { + + DPRINTF(1, ("filegen %0x %lu %lu %lu\n", + gen->type, now, gen->id, new_gen)); + filegen_open(gen, new_gen); } } @@ -370,38 +408,48 @@ */ void filegen_config( - FILEGEN *gen, - char *basename, - u_int type, - u_int flag + FILEGEN * gen, + const char * basename, + u_int type, + u_int flag ) { + int file_existed = 0; + size_t octets; + /* * if nothing would be changed... */ - if ((basename == gen->basename || strcmp(basename,gen->basename) == 0) && - type == gen->type && - flag == gen->flag) - return; + if ((strcmp(basename, gen->basename) == 0) && type == gen->type + && flag == gen->flag) + return; /* * validate parameters */ - if (!valid_fileref(gen->prefix,basename)) - return; + if (!valid_fileref(gen->prefix, basename)) + return; - if (gen->fp != NULL) - fclose(gen->fp); - -#ifdef DEBUG - if (debug > 2) - printf("configuring filegen:\n\tprefix:\t%s\n\tbasename:\t%s -> %s\n\ttype:\t%d -> %d\n\tflag: %x -> %x\n", - gen->prefix, gen->basename, basename, gen->type, type, gen->flag, flag); -#endif - if (gen->basename != basename || strcmp(gen->basename, basename) != 0) { - free(gen->basename); - gen->basename = (char*)emalloc(strlen(basename) + 1); - strcpy(gen->basename, basename); + if (NULL != gen->fp) { + fclose(gen->fp); + gen->fp = NULL; + file_existed = 1; + } + + DPRINTF(3, ("configuring filegen:\n" + "\tprefix:\t%s\n" + "\tbasename:\t%s -> %s\n" + "\ttype:\t%d -> %d\n" + "\tflag: %x -> %x\n", + gen->prefix, + gen->basename, basename, + gen->type, type, + gen->flag, flag)); + + if (strcmp(gen->basename, basename) != 0) { + octets = strlen(basename) + 1; + gen->basename = erealloc(gen->basename, octets); + memcpy(gen->basename, basename, octets); } gen->type = (u_char) type; gen->flag = (u_char) flag; @@ -412,7 +460,7 @@ * is currently open * otherwise the new settings will be used anyway at the next open */ - if (gen->fp != NULL) { + if (file_existed) { l_fp now; get_systime(&now); @@ -427,8 +475,8 @@ */ static int valid_fileref( - char *prefix, - char *basename + const char * prefix, + const char * basename ) { /* @@ -440,24 +488,25 @@ * file system parts 'below' prefix may be * specified without infringement of security * - * restricing prefix to legal values + * restricting prefix to legal values * has to be ensured by other means * (however, it would be possible to perform some checks here...) */ - register char *p = basename; + register const char *p = basename; /* * Just to catch, dumb errors opening up the world... */ - if (prefix == NULL || *prefix == '\0') - return 0; + if (NULL == prefix || '\0' == *prefix) + return 0; - if (basename == NULL) - return 0; + if (NULL == basename) + return 0; - for (p = basename; p; p = strchr(p, '/')) { - if (*p == '.' && *(p+1) == '.' && (*(p+2) == '\0' || *(p+2) == '/')) - return 0; + for (p = basename; p; p = strchr(p, DIR_SEP)) { + if ('.' == p[0] && '.' == p[1] + && ('\0' == p[2] || DIR_SEP == p[2])) + return 0; } return 1; @@ -469,108 +518,101 @@ */ static struct filegen_entry { - char *name; - FILEGEN *filegen; - struct filegen_entry *next; + char * name; + FILEGEN * filegen; + struct filegen_entry * next; } *filegen_registry = NULL; FILEGEN * filegen_get( - char *name + const char * name ) { struct filegen_entry *f = filegen_registry; - while(f) { + while (f) { if (f->name == name || strcmp(name, f->name) == 0) { -#ifdef XXX /* this gives the Alpha compiler fits */ - if (debug > 3) - printf("filegen_get(\"%s\") = %x\n", name, - (u_int)f->filegen); -#endif + DPRINTF(4, ("filegen_get(%s) = %p\n", + name, f->filegen)); return f->filegen; } f = f->next; } -#ifdef DEBUG - if (debug > 3) - printf("filegen_get(\"%s\") = NULL\n", name); -#endif + DPRINTF(4, ("filegen_get(%s) = NULL\n", name)); return NULL; } + void filegen_register( - char *prefix, - const char *name, - FILEGEN *filegen + const char * prefix, + const char * name, + FILEGEN * filegen ) { - struct filegen_entry **f = &filegen_registry; + struct filegen_entry **ppfe; -#ifdef XXX /* this gives the Alpha compiler fits */ - if (debug > 3) - printf("filegen_register(\"%s\",%x)\n", name, (u_int)filegen); -#endif + DPRINTF(4, ("filegen_register(%s, %p)\n", name, filegen)); filegen_init(prefix, name, filegen); - while (*f) { - if ((*f)->name == name || strcmp(name, (*f)->name) == 0) { -#ifdef XXX /* this gives the Alpha compiler fits */ - if (debug > 4) { - printf("replacing filegen %x\n", (u_int)(*f)->filegen); - } -#endif - (*f)->filegen = filegen; + ppfe = &filegen_registry; + while (NULL != *ppfe) { + if ((*ppfe)->name == name + || !strcmp((*ppfe)->name, name)) { + + DPRINTF(5, ("replacing filegen %p\n", + (*ppfe)->filegen)); + + (*ppfe)->filegen = filegen; return; } - f = &((*f)->next); + ppfe = &((*ppfe)->next); } - *f = (struct filegen_entry *) emalloc(sizeof(struct filegen_entry)); - if (*f) { - (*f)->next = NULL; - (*f)->name = (char*)emalloc(strlen(name) + 1); - strcpy((*f)->name, name); - (*f)->filegen = filegen; -#ifdef DEBUG - if (debug > 5) { - printf("adding new filegen\n"); - } -#endif - } + *ppfe = emalloc(sizeof **ppfe); + + (*ppfe)->next = NULL; + (*ppfe)->name = estrdup(name); + (*ppfe)->filegen = filegen; + + DPRINTF(6, ("adding new filegen\n")); return; } -#ifdef UNUSED -static FILEGEN * + +/* + * filegen_unregister frees memory allocated by filegen_register for + * name. + */ +#ifdef DEBUG +void filegen_unregister( char *name ) { - struct filegen_entry **f = &filegen_registry; - -#ifdef DEBUG - if (debug > 3) - printf("filegen_unregister(\"%s\")\n", name); -#endif - - while (*f) { - if (strcmp((*f)->name,name) == 0) { - struct filegen_entry *ff = *f; - FILEGEN *fg; + struct filegen_entry ** ppfe; + struct filegen_entry * pfe; + FILEGEN * fg; - *f = (*f)->next; - fg = ff->filegen; - free(ff->name); - free(ff); - return fg; + DPRINTF(4, ("filegen_unregister(%s)\n", name)); + + ppfe = &filegen_registry; + + while (NULL != *ppfe) { + if ((*ppfe)->name == name + || !strcmp((*ppfe)->name, name)) { + pfe = *ppfe; + *ppfe = (*ppfe)->next; + fg = pfe->filegen; + free(pfe->name); + free(pfe); + filegen_uninit(fg); + break; } - f = &((*f)->next); + ppfe = &((*ppfe)->next); } - return NULL; } -#endif /* UNUSED */ +#endif /* DEBUG */ diff -urN src/contrib/ntp/ntpd/ntp_intres.c src.ntp/contrib/ntp/ntpd/ntp_intres.c --- src/contrib/ntp/ntpd/ntp_intres.c 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/ntp_intres.c 2010-07-07 12:01:06.000000000 +0200 @@ -20,25 +20,53 @@ # include #endif -#include "ntp_machine.h" -#include "ntpd.h" -#include "ntp_io.h" -#include "ntp_request.h" -#include "ntp_stdlib.h" -#include "ntp_syslog.h" +#include "ntp_intres.h" + +#ifndef NO_INTRES #include #include #include /**/ +#ifdef HAVE_SYS_TYPES_H +# include +#endif +#ifdef HAVE_NETINET_IN_H #include +#endif #include /**/ #ifdef HAVE_SYS_PARAM_H # include /* MAXHOSTNAMELEN (often) */ #endif +#if !defined(HAVE_RES_INIT) && defined(HAVE___RES_INIT) +# define HAVE_RES_INIT +#endif + +#if defined(HAVE_RESOLV_H) && defined(HAVE_RES_INIT) +# ifdef HAVE_ARPA_NAMESER_H +# include /* DNS HEADER struct */ +# endif +# ifdef HAVE_NETDB_H +# include +# endif +# include +#endif + +#ifdef RES_TIMEOUT +#undef RES_TIMEOUT /* resolv.h has one, we want ours */ +#endif + +#include "ntp_machine.h" +#include "ntpd.h" +#include "ntp_io.h" +#include "ntp_request.h" +#include "ntp_stdlib.h" +#include "ntp_syslog.h" +#include "ntp_config.h" + #include #include @@ -50,9 +78,12 @@ */ struct conf_entry { struct conf_entry *ce_next; - char *ce_name; /* name we are trying to resolve */ - struct conf_peer ce_config; /* configuration info for peer */ - struct sockaddr_storage peer_store; /* address info for both fams */ + char *ce_name; /* name to resolve */ + struct conf_peer ce_config; /* config info for peer */ + int no_needed; /* number of addresses needed (pool) */ + /* no_needed isn't used yet: It's needed to fix bug-975 */ + int type; /* -4 and -6 flags */ + sockaddr_u peer_store; /* address info for both fams */ }; #define ce_peeraddr ce_config.peeraddr #define ce_peeraddr6 ce_config.peeraddr6 @@ -95,7 +126,6 @@ /* * Big hack attack */ -#define LOCALHOST 0x7f000001 /* 127.0.0.1, in hex, of course */ #define SKEWTIME 0x08000000 /* 0.03125 seconds as a l_fp fraction */ /* @@ -111,15 +141,17 @@ * is supposed to consist of entries in the following order */ #define TOK_HOSTNAME 0 -#define TOK_HMODE 1 -#define TOK_VERSION 2 -#define TOK_MINPOLL 3 -#define TOK_MAXPOLL 4 -#define TOK_FLAGS 5 -#define TOK_TTL 6 -#define TOK_KEYID 7 -#define TOK_KEYSTR 8 -#define NUMTOK 9 +#define TOK_NEEDED 1 +#define TOK_TYPE 2 +#define TOK_HMODE 3 +#define TOK_VERSION 4 +#define TOK_MINPOLL 5 +#define TOK_MAXPOLL 6 +#define TOK_FLAGS 7 +#define TOK_TTL 8 +#define TOK_KEYID 9 +#define TOK_KEYSTR 10 +#define NUMTOK 11 #define MAXLINESIZE 512 @@ -132,21 +164,24 @@ /* stuff to be filled in by caller */ keyid_t req_keyid; /* request keyid */ +int req_keytype; /* OpenSSL NID such as NID_md5 */ +size_t req_hashlen; /* digest size for req_keytype */ char *req_file; /* name of the file with configuration info */ /* end stuff to be filled in */ -static void checkparent P((void)); -static void removeentry P((struct conf_entry *)); -static void addentry P((char *, int, int, int, int, u_int, - int, keyid_t, char *)); -static int findhostaddr P((struct conf_entry *)); -static void openntp P((void)); -static int request P((struct conf_peer *)); -static char * nexttoken P((char **)); -static void readconf P((FILE *, char *)); -static void doconfigure P((int)); +static void checkparent (void); +static struct conf_entry * + removeentry (struct conf_entry *); +static void addentry (char *, int, int, int, int, int, int, u_int, + int, keyid_t, char *); +static int findhostaddr (struct conf_entry *); +static void openntp (void); +static int request (struct conf_peer *); +static char * nexttoken (char **); +static void readconf (FILE *, char *); +static void doconfigure (int); struct ntp_res_t_pkt { /* Tagged packet: */ void *tag; /* For the caller */ @@ -168,7 +203,7 @@ }; -static void resolver_exit P((int)); +static void resolver_exit (int); /* * Call here instead of just exiting @@ -179,7 +214,7 @@ #ifdef SYS_WINNT CloseHandle(ResolverEventHandle); ResolverEventHandle = NULL; - ExitThread(code); /* Just to kill the thread not the process */ + _endthreadex(code); /* Just to kill the thread not the process */ #else exit(code); /* kill the forked process */ #endif @@ -211,12 +246,13 @@ ntp_intres(void) { FILE *in; - struct timeval tv; - fd_set fdset; #ifdef SYS_WINNT DWORD rc; #else - int rc; + int rc; + struct timeval tv; + fd_set fdset; + int time_left; #endif #ifdef DEBUG @@ -248,9 +284,12 @@ (void) fclose(in); #ifdef DEBUG - if (!debug ) + if (!debug) #endif - (void) unlink(req_file); + if (unlink(req_file)) + msyslog(LOG_WARNING, + "unable to remove intres request file %s, %m", + req_file); /* * Set up the timers to do first shot immediately. @@ -304,20 +343,35 @@ resolver_exit(1); #else /* not SYS_WINNT */ - tv.tv_sec = ALARM_TIME; - tv.tv_usec = 0; - FD_ZERO(&fdset); - FD_SET(resolver_pipe_fd[0], &fdset); - rc = select(resolver_pipe_fd[0] + 1, &fdset, (fd_set *)0, (fd_set *)0, &tv); + /* Bug 1386: fork() in NetBSD leaves timers running. */ + /* So we need to retry select on EINTR */ + time_left = ALARM_TIME; + while (time_left > 0) { + tv.tv_sec = time_left; + tv.tv_usec = 0; + FD_ZERO(&fdset); + FD_SET(resolver_pipe_fd[0], &fdset); + rc = select(resolver_pipe_fd[0] + 1, &fdset, (fd_set *)0, (fd_set *)0, &tv); + + if (rc == 0) /* normal timeout */ + break; - if (rc > 0) { /* parent process has written to the pipe */ + if (rc > 0) { /* parent process has written to the pipe */ read(resolver_pipe_fd[0], (char *)&rc, sizeof(rc)); /* make pipe empty */ resolve_timer = 0; /* retry resolving immediately */ - continue; - } + break; + } - if ( rc < 0 ) /* select() returned error */ + if ( rc < 0 ) { /* select() returned error */ + if (errno == EINTR) { /* Timer went off */ + time_left -= (1<ce_next; - return; - } - - while (ce != NULL) { - if (ce->ce_next == entry) { - ce->ce_next = entry->ce_next; - return; + else + while (ce != NULL) { + if (ce->ce_next == entry) { + ce->ce_next = entry->ce_next; + break; + } + ce = ce->ce_next; } - ce = ce->ce_next; - } + + next_ce = entry->ce_next; + if (entry->ce_name != NULL) + free(entry->ce_name); + free(entry); + + return next_ce; } @@ -390,6 +465,8 @@ static void addentry( char *name, + int no_needed, + int type, int mode, int version, int minpoll, @@ -400,36 +477,34 @@ char *keystr ) { - register char *cp; register struct conf_entry *ce; - unsigned int len; #ifdef DEBUG if (debug > 1) msyslog(LOG_INFO, - "intres: <%s> %d %d %d %d %x %d %x %s\n", name, - mode, version, minpoll, maxpoll, flags, ttl, keyid, - keystr); -#endif - len = strlen(name) + 1; - cp = (char *)emalloc(len); - memmove(cp, name, len); - - ce = (struct conf_entry *)emalloc(sizeof(struct conf_entry)); - ce->ce_name = cp; + "intres: <%s> %d %d %d %d %d %d %x %d %x %s", + name, no_needed, type, mode, version, + minpoll, maxpoll, flags, ttl, keyid, keystr); +#endif + ce = emalloc(sizeof(*ce)); + ce->ce_name = estrdup(name); ce->ce_peeraddr = 0; #ifdef ISC_PLATFORM_HAVEIPV6 ce->ce_peeraddr6 = in6addr_any; #endif - ANYSOCK(&ce->peer_store); + ZERO_SOCK(&ce->peer_store); ce->ce_hmode = (u_char)mode; ce->ce_version = (u_char)version; ce->ce_minpoll = (u_char)minpoll; ce->ce_maxpoll = (u_char)maxpoll; + ce->no_needed = no_needed; /* Not used after here. */ + /* Start of fixing bug-975 */ + ce->type = type; ce->ce_flags = (u_char)flags; ce->ce_ttl = (u_char)ttl; ce->ce_keyid = keyid; - strncpy((char *)ce->ce_keystr, keystr, MAXFILENAME); + strncpy(ce->ce_keystr, keystr, sizeof(ce->ce_keystr) - 1); + ce->ce_keystr[sizeof(ce->ce_keystr) - 1] = 0; ce->ce_next = NULL; if (confentries == NULL) { @@ -466,13 +541,13 @@ checkparent(); /* make sure our guy is still running */ - if (entry->ce_name != NULL && !SOCKNUL(&entry->peer_store)) { + if (entry->ce_name != NULL && !SOCK_UNSPEC(&entry->peer_store)) { /* HMS: Squawk? */ msyslog(LOG_ERR, "findhostaddr: both ce_name and ce_peeraddr are defined..."); return 1; } - if (entry->ce_name == NULL && SOCKNUL(&entry->peer_store)) { + if (entry->ce_name == NULL && SOCK_UNSPEC(&entry->peer_store)) { msyslog(LOG_ERR, "findhostaddr: both ce_name and ce_peeraddr are undefined!"); return 0; } @@ -482,25 +557,27 @@ entry->ce_name)); memset(&hints, 0, sizeof(hints)); - hints.ai_family = AF_UNSPEC; + hints.ai_family = entry->type; + hints.ai_socktype = SOCK_DGRAM; + hints.ai_protocol = IPPROTO_UDP; /* - * If the IPv6 stack is not available look only for IPv4 addresses + * If IPv6 is not available look only for v4 addresses */ - if (isc_net_probeipv6() != ISC_R_SUCCESS) + if (!ipv6_works) hints.ai_family = AF_INET; - error = getaddrinfo(entry->ce_name, NULL, &hints, &addr); if (error == 0) { - entry->peer_store = *((struct sockaddr_storage*)(addr->ai_addr)); - if (entry->peer_store.ss_family == AF_INET) { + entry->peer_store = *((sockaddr_u *)(addr->ai_addr)); + if (IS_IPV4(&entry->peer_store)) { entry->ce_peeraddr = - GET_INADDR(entry->peer_store); + NSRCADR(&entry->peer_store); entry->ce_config.v6_flag = 0; } else { entry->ce_peeraddr6 = - GET_INADDR6(entry->peer_store); + SOCK_ADDR6(&entry->peer_store); entry->ce_config.v6_flag = 1; } + freeaddrinfo(addr); } } else { DPRINTF(2, ("findhostaddr: Resolving <%s>\n", @@ -678,15 +755,21 @@ struct conf_peer *conf ) { - fd_set fdset; - struct timeval tvout; + struct sock_timeval tvout; struct req_pkt reqpkt; - l_fp ts; + size_t req_len; + size_t total_len; /* req_len plus keyid & digest */ + fd_set fdset; + l_fp ts; + char * pch; + char * pchEnd; + l_fp * pts; + keyid_t *pkeyid; int n; #ifdef SYS_WINNT - HANDLE hReadWriteEvent = NULL; - BOOL ret; - DWORD NumberOfBytesWritten, NumberOfBytesRead, dwWait; + HANDLE hReadWriteEvent = NULL; + BOOL ret; + DWORD NumberOfBytesWritten, NumberOfBytesRead, dwWait; OVERLAPPED overlap; #endif /* SYS_WINNT */ @@ -709,7 +792,7 @@ FD_SET(sockfd, &fdset); while (select(sockfd + 1, &fdset, (fd_set *)0, (fd_set *)0, &tvout) > 0) { - recv(sockfd, (char *)&reqpkt, REQ_LEN_MAC, 0); + recv(sockfd, (char *)&reqpkt, sizeof(reqpkt), 0); FD_ZERO(&fdset); FD_SET(sockfd, &fdset); } @@ -717,34 +800,68 @@ /* * Make up a request packet with the configuration info */ - memset((char *)&reqpkt, 0, sizeof(reqpkt)); + memset(&reqpkt, 0, sizeof(reqpkt)); reqpkt.rm_vn_mode = RM_VN_MODE(0, 0, 0); reqpkt.auth_seq = AUTH_SEQ(1, 0); /* authenticated, no seq */ reqpkt.implementation = IMPL_XNTPD; /* local implementation */ reqpkt.request = REQ_CONFIG; /* configure a new peer */ reqpkt.err_nitems = ERR_NITEMS(0, 1); /* one item */ - reqpkt.mbz_itemsize = MBZ_ITEMSIZE(sizeof(struct conf_peer)); + reqpkt.mbz_itemsize = MBZ_ITEMSIZE(sizeof(*conf)); /* Make sure mbz_itemsize <= sizeof reqpkt.data */ - if (sizeof(struct conf_peer) > sizeof (reqpkt.data)) { - msyslog(LOG_ERR, "Bletch: conf_peer is too big for reqpkt.data!"); + if (sizeof(*conf) > sizeof(reqpkt.data)) { + msyslog(LOG_ERR, + "Bletch: conf_peer is too big for reqpkt.data!"); resolver_exit(1); } - memmove(reqpkt.data, (char *)conf, sizeof(struct conf_peer)); - reqpkt.keyid = htonl(req_keyid); + memcpy(reqpkt.data, conf, sizeof(*conf)); + if (sys_authenticate && req_hashlen > 16) { + pch = reqpkt.data; + /* 32-bit alignment */ + pch += (sizeof(*conf) + 3) & ~3; + pts = (void *)pch; + pkeyid = (void *)(pts + 1); + pchEnd = (void *)pkeyid; + req_len = pchEnd - (char *)&reqpkt; + pchEnd = (void *)(pkeyid + 1); + pchEnd += req_hashlen; + total_len = pchEnd - (char *)&reqpkt; + if (total_len > sizeof(reqpkt)) { + msyslog(LOG_ERR, + "intres total_len %lu limit is %lu (%lu octet digest)\n", + (u_long)total_len, + (u_long)sizeof(reqpkt), + (u_long)req_hashlen); + resolver_exit(1); + } + } else { + pts = &reqpkt.tstamp; + pkeyid = &reqpkt.keyid; + req_len = REQ_LEN_NOMAC; + } + + *pkeyid = htonl(req_keyid); get_systime(&ts); L_ADDUF(&ts, SKEWTIME); - HTONL_FP(&ts, &reqpkt.tstamp); - n = 0; - if (sys_authenticate) - n = authencrypt(req_keyid, (u_int32 *)&reqpkt, REQ_LEN_NOMAC); + HTONL_FP(&ts, pts); + if (sys_authenticate) { + n = authencrypt(req_keyid, (void *)&reqpkt, req_len); + if ((size_t)n != req_hashlen + sizeof(reqpkt.keyid)) { + msyslog(LOG_ERR, + "intres maclen %d expected %u\n", + n, (u_long)(req_hashlen + + sizeof(reqpkt.keyid))); + resolver_exit(1); + } + req_len += n; + } /* * Done. Send it. */ #ifndef SYS_WINNT - n = send(sockfd, (char *)&reqpkt, (unsigned)(REQ_LEN_NOMAC + n), 0); + n = send(sockfd, (char *)&reqpkt, req_len, 0); if (n < 0) { msyslog(LOG_ERR, "send to NTP server failed: %m"); return 0; /* maybe should exit */ @@ -762,7 +879,7 @@ */ overlap.Offset = overlap.OffsetHigh = (DWORD)0; overlap.hEvent = hReadWriteEvent; - ret = WriteFile((HANDLE)sockfd, (char *)&reqpkt, REQ_LEN_NOMAC + n, + ret = WriteFile((HANDLE)sockfd, (char *)&reqpkt, req_len, NULL, (LPOVERLAPPED)&overlap); if ((ret == FALSE) && (GetLastError() != ERROR_IO_PENDING)) { msyslog(LOG_ERR, "send to NTP server failed: %m"); @@ -780,7 +897,7 @@ return 0; } #endif /* SYS_WINNT */ - + /* * Wait for a response. A weakness of the mode 7 protocol used @@ -800,23 +917,20 @@ n = select(sockfd + 1, &fdset, (fd_set *)0, (fd_set *)0, &tvout); - if (n < 0) - { + if (n < 0) { if (errno != EINTR) - msyslog(LOG_ERR, "select() fails: %m"); + msyslog(LOG_ERR, "select() fails: %m"); return 0; - } - else if (n == 0) - { + } else if (n == 0) { #ifdef DEBUG if (debug) - msyslog(LOG_INFO, "select() returned 0."); + msyslog(LOG_INFO, "ntp_intres select() returned 0."); #endif return 0; } #ifndef SYS_WINNT - n = recv(sockfd, (char *)&reqpkt, REQ_LEN_MAC, 0); + n = recv(sockfd, (char *)&reqpkt, sizeof(reqpkt), 0); if (n <= 0) { if (n < 0) { msyslog(LOG_ERR, "recv() fails: %m"); @@ -825,7 +939,7 @@ continue; } #else /* Overlapped I/O used on non-blocking sockets on Windows NT */ - ret = ReadFile((HANDLE)sockfd, (char *)&reqpkt, (DWORD)REQ_LEN_MAC, + ret = ReadFile((HANDLE)sockfd, (char *)&reqpkt, sizeof(reqpkt), NULL, (LPOVERLAPPED)&overlap); if ((ret == FALSE) && (GetLastError() != ERROR_IO_PENDING)) { msyslog(LOG_ERR, "ReadFile() fails: %m"); @@ -929,34 +1043,36 @@ /* success */ return 1; + case INFO_ERR_NODATA: + /* + * newpeer() refused duplicate association, no + * point in retrying so call it success. + */ + return 1; + case INFO_ERR_IMPL: msyslog(LOG_ERR, - "ntpd reports implementation mismatch!"); + "ntp_intres.request: implementation mismatch"); return 0; case INFO_ERR_REQ: msyslog(LOG_ERR, - "ntpd says configuration request is unknown!"); + "ntp_intres.request: request unknown"); return 0; case INFO_ERR_FMT: msyslog(LOG_ERR, - "ntpd indicates a format error occurred!"); + "ntp_intres.request: format error"); return 0; - case INFO_ERR_NODATA: - msyslog(LOG_ERR, - "ntpd indicates no data available!"); - return 0; - case INFO_ERR_AUTH: msyslog(LOG_ERR, - "ntpd returns a permission denied error!"); + "ntp_intres.request: permission denied"); return 0; default: msyslog(LOG_ERR, - "ntpd returns unknown error code %d!", n); + "ntp_intres.request: unknown error code %d", n); return 0; } } @@ -1051,6 +1167,7 @@ } } +#if 0 /* paranoid checking - these are done in newpeer() */ if (intval[TOK_HMODE] != MODE_ACTIVE && intval[TOK_HMODE] != MODE_CLIENT && intval[TOK_HMODE] != MODE_BROADCAST) { @@ -1065,31 +1182,30 @@ intval[TOK_VERSION], name); resolver_exit(1); } - if (intval[TOK_MINPOLL] < NTP_MINPOLL || + if (intval[TOK_MINPOLL] < ntp_minpoll || intval[TOK_MINPOLL] > NTP_MAXPOLL) { + msyslog(LOG_ERR, "invalid MINPOLL value (%ld) in file %s", intval[TOK_MINPOLL], name); resolver_exit(1); } - if (intval[TOK_MAXPOLL] < NTP_MINPOLL || + if (intval[TOK_MAXPOLL] < ntp_minpoll || intval[TOK_MAXPOLL] > NTP_MAXPOLL) { msyslog(LOG_ERR, "invalid MAXPOLL value (%ld) in file %s", intval[TOK_MAXPOLL], name); resolver_exit(1); } - if ((intval[TOK_FLAGS] & ~(FLAG_AUTHENABLE | FLAG_PREFER | - FLAG_NOSELECT | FLAG_BURST | FLAG_IBURST | FLAG_SKEY)) - != 0) { + if ((intval[TOK_FLAGS] & ~(FLAG_PREFER | FLAG_NOSELECT | + FLAG_BURST | FLAG_IBURST | FLAG_SKEY)) != 0) { msyslog(LOG_ERR, "invalid flags (%ld) in file %s", intval[TOK_FLAGS], name); resolver_exit(1); } +#endif /* end paranoid checking */ flags = 0; - if (intval[TOK_FLAGS] & FLAG_AUTHENABLE) - flags |= CONF_FLAG_AUTHENABLE; if (intval[TOK_FLAGS] & FLAG_PREFER) flags |= CONF_FLAG_PREFER; if (intval[TOK_FLAGS] & FLAG_NOSELECT) @@ -1098,15 +1214,20 @@ flags |= CONF_FLAG_BURST; if (intval[TOK_FLAGS] & FLAG_IBURST) flags |= CONF_FLAG_IBURST; + +#ifdef OPENSSL if (intval[TOK_FLAGS] & FLAG_SKEY) flags |= CONF_FLAG_SKEY; +#endif /* OPENSSL */ /* * This is as good as we can check it. Add it in. */ - addentry(token[TOK_HOSTNAME], (int)intval[TOK_HMODE], - (int)intval[TOK_VERSION], (int)intval[TOK_MINPOLL], - (int)intval[TOK_MAXPOLL], flags, (int)intval[TOK_TTL], + addentry(token[TOK_HOSTNAME], + (int)intval[TOK_NEEDED], (int)intval[TOK_TYPE], + (int)intval[TOK_HMODE], (int)intval[TOK_VERSION], + (int)intval[TOK_MINPOLL], (int)intval[TOK_MAXPOLL], + flags, (int)intval[TOK_TTL], intval[TOK_KEYID], token[TOK_KEYSTR]); } } @@ -1121,7 +1242,6 @@ ) { register struct conf_entry *ce; - register struct conf_entry *ceremove; #ifdef DEBUG if (debug > 1) @@ -1129,6 +1249,10 @@ dores ? "with" : "without" ); #endif +#if defined(HAVE_RES_INIT) + if (dores) /* Reload /etc/resolv.conf - bug 1226 */ + res_init(); +#endif ce = confentries; while (ce != NULL) { #ifdef DEBUG @@ -1137,27 +1261,30 @@ "doconfigure: <%s> has peeraddr %s", ce->ce_name, stoa(&ce->peer_store)); #endif - if (dores && SOCKNUL(&(ce->peer_store))) { + if (dores && SOCK_UNSPEC(&ce->peer_store)) { if (!findhostaddr(ce)) { #ifndef IGNORE_DNS_ERRORS msyslog(LOG_ERR, "couldn't resolve `%s', giving up on it", ce->ce_name); - ceremove = ce; - ce = ceremove->ce_next; - removeentry(ceremove); + ce = removeentry(ce); continue; #endif - } + } else if (!SOCK_UNSPEC(&ce->peer_store)) + msyslog(LOG_INFO, + "DNS %s -> %s", ce->ce_name, + stoa(&ce->peer_store)); } - if (!SOCKNUL(&ce->peer_store)) { + if (!SOCK_UNSPEC(&ce->peer_store)) { if (request(&ce->ce_config)) { - ceremove = ce; - ce = ceremove->ce_next; - removeentry(ceremove); + ce = removeentry(ce); continue; } + /* + * Failed case. Should bump counter and give + * up. + */ #ifdef DEBUG if (debug > 1) { msyslog(LOG_INFO, @@ -1168,3 +1295,7 @@ ce = ce->ce_next; } } + +#else /* NO_INTRES follows */ +int ntp_intres_nonempty_compilation_unit; +#endif diff -urN src/contrib/ntp/ntpd/ntp_io.c src.ntp/contrib/ntp/ntpd/ntp_io.c --- src/contrib/ntp/ntpd/ntp_io.c 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/ntp_io.c 2010-04-18 10:05:39.000000000 +0200 @@ -7,41 +7,54 @@ # include #endif +#include +#include +#ifdef HAVE_SYS_PARAM_H +# include +#endif +#ifdef HAVE_SYS_IOCTL_H +# include +#endif +#ifdef HAVE_SYS_SOCKIO_H /* UXPV: SIOC* #defines (Frank Vance ) */ +# include +#endif +#ifdef HAVE_SYS_UIO_H +# include +#endif + #include "ntp_machine.h" #include "ntpd.h" #include "ntp_io.h" #include "iosignal.h" +#include "ntp_lists.h" #include "ntp_refclock.h" #include "ntp_stdlib.h" #include "ntp_request.h" #include "ntp.h" #include "ntp_unixtime.h" +#include "ntp_assert.h" +#include "ntpd-opts.h" /* Don't include ISC's version of IPv6 variables and structures */ #define ISC_IPV6_H 1 +#include #include -#include +#include #include +#include #ifdef SIM #include "ntpsim.h" #endif -#include -#include -#ifdef HAVE_SYS_PARAM_H -# include -#endif /* HAVE_SYS_PARAM_H */ -#ifdef HAVE_SYS_IOCTL_H -# include -#endif -#ifdef HAVE_SYS_SOCKIO_H /* UXPV: SIOC* #defines (Frank Vance ) */ -# include -#endif -#ifdef HAVE_SYS_UIO_H -# include +#ifdef HAS_ROUTING_SOCKET +# include +# ifdef HAVE_RTNETLINK +# include +# endif #endif + /* * setsockopt does not always have the same arg declaration * across all platforms. If it's not defined we make it empty @@ -51,28 +64,28 @@ #define SETSOCKOPT_ARG_CAST #endif -/* - * Set up some macros to look for IPv6 and IPv6 multicast - */ - -#if defined(ISC_PLATFORM_HAVEIPV6) && !defined(DISABLE_IPV6) - -#define INCLUDE_IPV6_SUPPORT +extern int listen_to_virtual_ips; -#if defined(INCLUDE_IPV6_SUPPORT) && defined(IPV6_JOIN_GROUP) && defined(IPV6_LEAVE_GROUP) -#define INCLUDE_IPV6_MULTICAST_SUPPORT +/* + * NIC rule entry + */ +typedef struct nic_rule_tag nic_rule; -#endif /* IPV6 Multicast Support */ -#endif /* IPv6 Support */ +struct nic_rule_tag { + nic_rule * next; + nic_rule_action action; + nic_rule_match match_type; + char * if_name; + isc_netaddr_t netaddr; + int prefixlen; +}; -#ifdef INCLUDE_IPV6_SUPPORT -#include -#include -#include -#endif /* !INCLUDE_IPV6_SUPPORT */ +/* + * NIC rule listhead. Entries are added at the head so that the first + * match in the list is the last matching rule specified. + */ +nic_rule *nic_rule_list; -extern int listen_to_virtual_ips; -extern const char *specific_interface; #if defined(SO_TIMESTAMP) && defined(SCM_TIMESTAMP) #if defined(CMSG_FIRSTHDR) @@ -90,17 +103,6 @@ #include #include /* - * Define this macro to control the behavior of connection - * resets on UDP sockets. See Microsoft KnowledgeBase Article Q263823 - * for details. - * NOTE: This requires that Windows 2000 systems install Service Pack 2 - * or later. - */ -#ifndef SIO_UDP_CONNRESET -#define SIO_UDP_CONNRESET _WSAIOW(IOC_VENDOR,12) -#endif - -/* * Windows C runtime ioctl() can't deal properly with sockets, * map to ioctlsocket for this source file. */ @@ -130,8 +132,8 @@ volatile u_long packets_dropped; /* total number of packets dropped on reception */ volatile u_long packets_ignored; /* packets received on wild card interface */ volatile u_long packets_received; /* total number of packets received */ -u_long packets_sent; /* total number of packets sent */ -u_long packets_notsent; /* total number of packets which couldn't be sent */ + u_long packets_sent; /* total number of packets sent */ + u_long packets_notsent; /* total number of packets which couldn't be sent */ volatile u_long handler_calls; /* number of calls to interrupt handler */ volatile u_long handler_pkts; /* number of pkts received by handler */ @@ -144,9 +146,10 @@ struct interface *any6_interface; /* default ipv6 interface */ struct interface *loopback_interface; /* loopback ipv4 interface */ +isc_boolean_t broadcast_client_enabled; /* is broadcast client enabled */ int ninterfaces; /* Total number of interfaces */ -volatile int disable_dynamic_updates; /* when set to != 0 dynamic updates won't happen */ +int disable_dynamic_updates; /* scan interfaces once only */ #ifdef REFCLOCK /* @@ -156,19 +159,14 @@ static struct refclockio *refio; #endif /* REFCLOCK */ - -/* - * Define what the possible "soft" errors can be. These are non-fatal returns - * of various network related functions, like recv() and so on. - * - * For some reason, BSDI (and perhaps others) will sometimes return <0 - * from recv() but will have errno==0. This is broken, but we have to - * work around it here. - */ -#define SOFT_ERROR(e) ((e) == EAGAIN || \ - (e) == EWOULDBLOCK || \ - (e) == EINTR || \ - (e) == 0) +#if defined(HAVE_IPTOS_SUPPORT) +/* set IP_TOS to minimize packet delay */ +# if defined(IPTOS_PREC_INTERNETCONTROL) + unsigned int qos = IPTOS_PREC_INTERNETCONTROL; +# else + unsigned int qos = IPTOS_LOWDELAY; +# endif +#endif /* * File descriptor masks etc. for call to select @@ -179,44 +177,50 @@ /* * bit alternating value to detect verified interfaces during an update cycle */ -static u_char sys_interphase = 0; - -static struct interface *new_interface P((struct interface *)); -static void add_interface P((struct interface *)); -static int update_interfaces P((u_short, interface_receiver_t, void *)); -static void remove_interface P((struct interface *)); -static struct interface *create_interface P((u_short, struct interface *)); +static u_short sys_interphase = 0; -static int move_fd P((SOCKET)); +static struct interface *new_interface (struct interface *); +static void add_interface (struct interface *); +static int update_interfaces(u_short, interface_receiver_t, void *); +static void remove_interface(struct interface *); +static struct interface *create_interface(u_short, struct interface *); + +static int move_fd (SOCKET); +static int is_wildcard_addr (sockaddr_u *); +static int is_wildcard_netaddr (const isc_netaddr_t *); /* * Multicast functions */ -static isc_boolean_t addr_ismulticast P((struct sockaddr_storage *)); +static isc_boolean_t addr_ismulticast (sockaddr_u *); /* * Not all platforms support multicast */ #ifdef MCAST -static isc_boolean_t socket_multicast_enable P((struct interface *, int, struct sockaddr_storage *)); -static isc_boolean_t socket_multicast_disable P((struct interface *, struct sockaddr_storage *)); +static isc_boolean_t socket_multicast_enable (struct interface *, int, sockaddr_u *); +static isc_boolean_t socket_multicast_disable(struct interface *, sockaddr_u *); #endif #ifdef DEBUG -static void print_interface P((struct interface *, char *, char *)); -#define DPRINT_INTERFACE(_LVL_, _ARGS_) do { if (debug >= (_LVL_)) { print_interface _ARGS_; } } while (0) +static void interface_dump (struct interface *); +static void sockaddr_dump (sockaddr_u *psau); +static void print_interface (struct interface *, char *, char *); +#define DPRINT_INTERFACE(level, args) do { if (debug >= (level)) { print_interface args; } } while (0) #else -#define DPRINT_INTERFACE(_LVL_, _ARGS_) do {} while (0) +#define DPRINT_INTERFACE(level, args) do {} while (0) #endif typedef struct vsock vsock_t; enum desc_type { FD_TYPE_SOCKET, FD_TYPE_FILE }; struct vsock { - SOCKET fd; - enum desc_type type; - ISC_LINK(vsock_t) link; + vsock_t * link; + SOCKET fd; + enum desc_type type; }; +vsock_t *fd_list; + #if !defined(HAVE_IO_COMPLETION_PORT) && defined(HAS_ROUTING_SOCKET) /* * async notification processing (e. g. routing sockets) @@ -226,69 +230,77 @@ * like e. g. routing sockets */ struct asyncio_reader { - SOCKET fd; /* fd to be read */ - void *data; /* possibly local data */ + struct asyncio_reader *link; /* the list this is being kept in */ + SOCKET fd; /* fd to be read */ + void *data; /* possibly local data */ void (*receiver)(struct asyncio_reader *); /* input handler */ - ISC_LINK(struct asyncio_reader) link; /* the list this is being kept in */ }; -ISC_LIST(struct asyncio_reader) asyncio_reader_list; +struct asyncio_reader *asyncio_reader_list; -static void delete_asyncio_reader P((struct asyncio_reader *)); -static struct asyncio_reader *new_asyncio_reader P((void)); -static void add_asyncio_reader P((struct asyncio_reader *, enum desc_type)); -static void remove_asyncio_reader P((struct asyncio_reader *)); +static void delete_asyncio_reader (struct asyncio_reader *); +static struct asyncio_reader *new_asyncio_reader (void); +static void add_asyncio_reader (struct asyncio_reader *, enum desc_type); +static void remove_asyncio_reader (struct asyncio_reader *); #endif /* !defined(HAVE_IO_COMPLETION_PORT) && defined(HAS_ROUTING_SOCKET) */ -static void init_async_notifications P((void)); - -static int create_sockets P((u_short)); -static SOCKET open_socket P((struct sockaddr_storage *, int, int, struct interface *)); -static char * fdbits P((int, fd_set *)); -static void set_reuseaddr P((int)); -static isc_boolean_t socket_broadcast_enable P((struct interface *, SOCKET, struct sockaddr_storage *)); -static isc_boolean_t socket_broadcast_disable P((struct interface *, struct sockaddr_storage *)); +static void init_async_notifications (void); -ISC_LIST(vsock_t) fd_list; +static int create_sockets (u_short); +static SOCKET open_socket (sockaddr_u *, int, int, struct interface *); +static char * fdbits (int, fd_set *); +static void set_reuseaddr (int); +static isc_boolean_t socket_broadcast_enable (struct interface *, SOCKET, sockaddr_u *); +static isc_boolean_t socket_broadcast_disable (struct interface *, sockaddr_u *); typedef struct remaddr remaddr_t; struct remaddr { - struct sockaddr_storage addr; - struct interface *interface; - ISC_LINK(remaddr_t) link; + remaddr_t * link; + sockaddr_u addr; + struct interface * interface; }; -ISC_LIST(remaddr_t) remoteaddr_list; +remaddr_t * remoteaddr_list; -ISC_LIST(struct interface) inter_list; +struct interface * inter_list; static struct interface *wildipv4 = NULL; static struct interface *wildipv6 = NULL; -static void add_fd_to_list P((SOCKET, enum desc_type)); -static void close_and_delete_fd_from_list P((SOCKET)); -static void add_addr_to_list P((struct sockaddr_storage *, struct interface *)); -static void delete_addr_from_list P((struct sockaddr_storage *)); -static struct interface *find_addr_in_list P((struct sockaddr_storage *)); -static struct interface *find_flagged_addr_in_list P((struct sockaddr_storage *, int)); -static void create_wildcards P((u_short)); -static isc_boolean_t address_okay P((struct interface *)); -static void convert_isc_if P((isc_interface_t *, struct interface *, u_short)); -static void delete_interface_from_list P((struct interface *)); -static struct interface *getinterface P((struct sockaddr_storage *, int)); -static struct interface *findlocalinterface P((struct sockaddr_storage *, int)); -static struct interface *findlocalcastinterface P((struct sockaddr_storage *, int)); +static void add_fd_to_list (SOCKET, + enum desc_type); +static struct interface *find_addr_in_list (sockaddr_u *); +static struct interface *find_samenet_addr_in_list(sockaddr_u *); +static struct interface *find_flagged_addr_in_list(sockaddr_u *, int); +static void delete_addr_from_list (sockaddr_u *); +static void delete_interface_from_list(struct interface *); +static void close_and_delete_fd_from_list(SOCKET); +static void add_addr_to_list (sockaddr_u *, + struct interface *); +static void create_wildcards (u_short); +#ifdef DEBUG +static const char * action_text (nic_rule_action); +#endif +static nic_rule_action interface_action(char *, isc_netaddr_t *, + isc_uint32_t); +static void convert_isc_if (isc_interface_t *, + struct interface *, u_short); +static struct interface *getinterface (sockaddr_u *, int); +static struct interface *getsamenetinterface (sockaddr_u *, int); +static struct interface *findlocalinterface (sockaddr_u *, int, int); +static struct interface *findlocalcastinterface (sockaddr_u *); /* * Routines to read the ntp packets */ #if !defined(HAVE_IO_COMPLETION_PORT) -static inline int read_network_packet P((SOCKET, struct interface *, l_fp)); -static inline int read_refclock_packet P((SOCKET, struct refclockio *, l_fp)); +static inline int read_network_packet (SOCKET, struct interface *, l_fp); +static inline int read_refclock_packet (SOCKET, struct refclockio *, l_fp); #endif + #ifdef SYS_WINNT /* * Windows 2000 systems incorrectly cause UDP sockets using WASRecvFrom @@ -302,11 +314,11 @@ */ void connection_reset_fix( - SOCKET fd, - struct sockaddr_storage *addr + SOCKET fd, + sockaddr_u * addr ) { - DWORD dwBytesReturned = 0; + DWORD dw; BOOL bNewBehavior = FALSE; DWORD status; @@ -317,11 +329,11 @@ if (isc_win32os_majorversion() >= 5) { status = WSAIoctl(fd, SIO_UDP_CONNRESET, &bNewBehavior, sizeof(bNewBehavior), NULL, 0, - &dwBytesReturned, NULL, NULL); + &dw, NULL, NULL); if (SOCKET_ERROR == status) - netsyslog(LOG_ERR, "connection_reset_fix() " - "failed for address %s: %m", - stoa(addr)); + msyslog(LOG_ERR, + "connection_reset_fix() failed for address %s: %m", + stoa(addr)); } } #endif @@ -329,12 +341,12 @@ /* * on Unix systems the stdio library typically * makes use of file descriptors in the lower - * integer range. stdio usually will make use - * of the file descriptor in the range of + * integer range. stdio usually will make use + * of the file descriptors in the range of * [0..FOPEN_MAX) - * in order to keep this range clean for socket + * in order to keep this range clean, for socket * file descriptors we attempt to move them above - * FOPEM_MAX. This is not as easy as it sounds as + * FOPEN_MAX. This is not as easy as it sounds as * FOPEN_MAX changes from implementation to implementation * and may exceed to current file decriptor limits. * We are using following strategy: @@ -355,7 +367,10 @@ * allocation is possible or 0 is reached - at this * point the algrithm will be disabled */ -static int move_fd(SOCKET fd) +static int +move_fd( + SOCKET fd + ) { #if !defined(SYS_WINNT) && defined(F_DUPFD) #ifndef FD_CHUNK @@ -388,6 +403,8 @@ static SOCKET socket_boundary = -1; SOCKET newfd; + NTP_REQUIRE((int)fd >= 0); + /* * check whether boundary has be set up * already @@ -396,7 +413,8 @@ socket_boundary = max(0, min(getdtablesize() - FD_CHUNK, min(FOPEN_MAX, FD_PREFERRED_SOCKBOUNDARY))); #ifdef DEBUG - msyslog(LOG_DEBUG, "ntp_io: estimated max descriptors: %d, initial socket boundary: %d", + msyslog(LOG_DEBUG, + "ntp_io: estimated max descriptors: %d, initial socket boundary: %d", getdtablesize(), socket_boundary); #endif } @@ -412,21 +430,24 @@ if (newfd != -1) { /* success: drop the old one - return the new one */ - (void)close(fd); - return (newfd); + close(fd); + return newfd; } } else { /* outside reserved range: no work - return the original one */ - return (fd); + return fd; } socket_boundary = max(0, socket_boundary - FD_CHUNK); #ifdef DEBUG - msyslog(LOG_DEBUG, "ntp_io: selecting new socket boundary: %d", + msyslog(LOG_DEBUG, + "ntp_io: selecting new socket boundary: %d", socket_boundary); #endif } while (socket_boundary > 0); +#else + NTP_REQUIRE((int)fd >= 0); #endif /* !defined(SYS_WINNT) && defined(F_DUPFD) */ - return (fd); + return fd; } #ifdef DEBUG_TIMING @@ -440,16 +461,19 @@ void collect_timing(struct recvbuf *rb, const char *tag, int count, l_fp *dts) { - char buf[2048]; + char buf[256]; snprintf(buf, sizeof(buf), "%s %d %s %s", - (rb != NULL) ? - ((rb->dstadr) ? stoa(&rb->recv_srcadr) : "-REFCLOCK-") : "-", + (rb != NULL) + ? ((rb->dstadr != NULL) + ? stoa(&rb->recv_srcadr) + : "-REFCLOCK-") + : "-", count, lfptoa(dts, 9), tag); record_timing_stats(buf); } #endif - + /* * About dynamic interfaces, sockets, reception and more... * @@ -493,61 +517,47 @@ void init_io(void) { -#ifdef SYS_WINNT - init_io_completion_port(); - - if (!Win32InitSockets()) - { - netsyslog(LOG_ERR, "No useable winsock.dll: %m"); - exit(1); - } - init_transmitbuff(); -#endif /* SYS_WINNT */ - /* * Init buffer free list and stat counters */ init_recvbuff(RECV_INIT); - packets_dropped = packets_received = 0; - packets_ignored = 0; - packets_sent = packets_notsent = 0; - handler_calls = handler_pkts = 0; - io_timereset = 0; - loopback_interface = NULL; - any_interface = NULL; - any6_interface = NULL; - -#ifdef REFCLOCK - refio = NULL; -#endif +#ifdef SYS_WINNT + init_io_completion_port(); +#endif /* SYS_WINNT */ #if defined(HAVE_SIGNALED_IO) (void) set_signal(); #endif +} - ISC_LIST_INIT(fd_list); -#if !defined(HAVE_IO_COMPLETION_PORT) && defined(HAS_ROUTING_SOCKET) - ISC_LIST_INIT(asyncio_reader_list); -#endif +/* + * io_open_sockets - call socket creation routine + */ +void +io_open_sockets(void) +{ + static int already_opened; - ISC_LIST_INIT(remoteaddr_list); + if (already_opened || HAVE_OPT( SAVECONFIGQUIT )) + return; - ISC_LIST_INIT(inter_list); + already_opened = 1; /* * Create the sockets */ BLOCKIO(); - (void) create_sockets(htons(NTP_PORT)); + create_sockets(NTP_PORT); UNBLOCKIO(); init_async_notifications(); - DPRINTF(3, ("init_io: maxactivefd %d\n", maxactivefd)); + DPRINTF(3, ("io_open_sockets: maxactivefd %d\n", maxactivefd)); } + #ifdef DEBUG /* * function to dump the contents of the interface structure @@ -556,41 +566,15 @@ void interface_dump(struct interface *itf) { - u_char* cp; - int i; - /* Limit the size of the sockaddr_storage hex dump */ - int maxsize = min(32, sizeof(struct sockaddr_storage)); - printf("Dumping interface: %p\n", itf); printf("fd = %d\n", itf->fd); printf("bfd = %d\n", itf->bfd); - printf("sin = %s,\n", stoa(&(itf->sin))); - cp = (u_char*) &(itf->sin); - for(i = 0; i < maxsize; i++) - { - printf("%02x", *cp++); - if((i+1)%4 == 0) - printf(" "); - } - printf("\n"); - printf("bcast = %s,\n", stoa(&(itf->bcast))); - cp = (u_char*) &(itf->bcast); - for(i = 0; i < maxsize; i++) - { - printf("%02x", *cp++); - if((i+1)%4 == 0) - printf(" "); - } - printf("\n"); - printf("mask = %s,\n", stoa(&(itf->mask))); - cp = (u_char*) &(itf->mask); - for(i = 0; i < maxsize; i++) - { - printf("%02x", *cp++); - if((i+1)%4 == 0) - printf(" "); - } - printf("\n"); + printf("sin = %s,\n", stoa(&itf->sin)); + sockaddr_dump(&itf->sin); + printf("bcast = %s,\n", stoa(&itf->bcast)); + sockaddr_dump(&itf->bcast); + printf("mask = %s,\n", stoa(&itf->mask)); + sockaddr_dump(&itf->mask); printf("name = %s\n", itf->name); printf("flags = 0x%08x\n", itf->flags); printf("last_ttl = %d\n", itf->last_ttl); @@ -599,19 +583,40 @@ printf("received = %ld\n", itf->received); printf("sent = %ld\n", itf->sent); printf("notsent = %ld\n", itf->notsent); - printf("ifindex = %u\n", itf->ifindex); printf("scopeid = %u\n", itf->scopeid); printf("peercnt = %u\n", itf->peercnt); printf("phase = %u\n", itf->phase); } /* + * sockaddr_dump - hex dump the start of a sockaddr_u + */ +static void +sockaddr_dump(sockaddr_u *psau) +{ + /* Limit the size of the sockaddr_storage hex dump */ + const int maxsize = min(32, sizeof(psau->sa6)); + u_char * cp; + int i; + + cp = (u_char *)&psau->sa; + + for(i = 0; i < maxsize; i++) + { + printf("%02x", *cp++); + if (!((i + 1) % 4)) + printf(" "); + } + printf("\n"); +} + +/* * print_interface - helper to output debug information */ static void print_interface(struct interface *iface, char *pfx, char *sfx) { - printf("%sinterface #%d: fd=%d, bfd=%d, name=%s, flags=0x%x, scope=%d, ifindex=%d", + printf("%sinterface #%d: fd=%d, bfd=%d, name=%s, flags=0x%x, scope=%d, sin=%s", pfx, iface->ifnum, iface->fd, @@ -619,21 +624,20 @@ iface->name, iface->flags, iface->scopeid, - iface->ifindex); - /* Leave these as three printf calls. */ - printf(", sin=%s", - stoa((&iface->sin))); - if (iface->flags & INT_BROADCAST) - printf(", bcast=%s,", - stoa((&iface->bcast))); - if (iface->family == AF_INET) - printf(", mask=%s", - stoa((&iface->mask))); - printf(", %s:%s", iface->ignore_packets == ISC_FALSE ? "Enabled" : "Disabled", sfx); + stoa(&iface->sin)); + if (AF_INET == iface->family) { + if (iface->flags & INT_BROADCAST) + printf(", bcast=%s", stoa(&iface->bcast)); + printf(", mask=%s", stoa(&iface->mask)); + } + printf(", %s:%s", + (iface->ignore_packets) + ? "Disabled" + : "Enabled", + sfx); if (debug > 4) /* in-depth debugging only */ interface_dump(iface); } - #endif #if !defined(HAVE_IO_COMPLETION_PORT) && defined(HAS_ROUTING_SOCKET) @@ -641,14 +645,13 @@ * create an asyncio_reader structure */ static struct asyncio_reader * -new_asyncio_reader() +new_asyncio_reader(void) { struct asyncio_reader *reader; - reader = (struct asyncio_reader *)emalloc(sizeof(struct asyncio_reader)); + reader = emalloc(sizeof(*reader)); - memset((char *)reader, 0, sizeof(*reader)); - ISC_LINK_INIT(reader, link); + memset(reader, 0, sizeof(*reader)); reader->fd = INVALID_SOCKET; return reader; } @@ -657,7 +660,9 @@ * delete a reader */ static void -delete_asyncio_reader(struct asyncio_reader *reader) +delete_asyncio_reader( + struct asyncio_reader *reader + ) { free(reader); } @@ -666,9 +671,11 @@ * add asynchio_reader */ static void -add_asyncio_reader(struct asyncio_reader *reader, enum desc_type type) +add_asyncio_reader( + struct asyncio_reader * reader, + enum desc_type type) { - ISC_LIST_APPEND(asyncio_reader_list, reader, link); + LINK_SLIST(asyncio_reader_list, reader, link); add_fd_to_list(reader->fd, type); } @@ -676,9 +683,14 @@ * remove asynchio_reader */ static void -remove_asyncio_reader(struct asyncio_reader *reader) +remove_asyncio_reader( + struct asyncio_reader *reader + ) { - ISC_LIST_UNLINK_TYPE(asyncio_reader_list, reader, link, struct asyncio_reader); + struct asyncio_reader *unlinked; + + UNLINK_SLIST(unlinked, asyncio_reader_list, reader, link, + struct asyncio_reader); if (reader->fd != INVALID_SOCKET) close_and_delete_fd_from_list(reader->fd); @@ -688,364 +700,621 @@ #endif /* !defined(HAVE_IO_COMPLETION_PORT) && defined(HAS_ROUTING_SOCKET) */ /* + * Code to tell if we have an IP address + * If we have then return the sockaddr structure + * and set the return value + * see the bind9/getaddresses.c for details + */ +isc_boolean_t +is_ip_address( + const char * host, + isc_netaddr_t * addr + ) +{ + struct in_addr in4; + struct in6_addr in6; + char tmpbuf[128]; + char *pch; + + NTP_REQUIRE(host != NULL); + NTP_REQUIRE(addr != NULL); + + /* + * Try IPv4, then IPv6. In order to handle the extended format + * for IPv6 scoped addresses (address%scope_ID), we'll use a local + * working buffer of 128 bytes. The length is an ad-hoc value, but + * should be enough for this purpose; the buffer can contain a string + * of at least 80 bytes for scope_ID in addition to any IPv6 numeric + * addresses (up to 46 bytes), the delimiter character and the + * terminating NULL character. + */ + if (inet_pton(AF_INET, host, &in4) == 1) { + isc_netaddr_fromin(addr, &in4); + return (ISC_TRUE); + } else if (sizeof(tmpbuf) > strlen(host)) { + if ('[' == host[0]) { + strncpy(tmpbuf, &host[1], sizeof(tmpbuf)); + pch = strchr(tmpbuf, ']'); + if (pch != NULL) + *pch = '\0'; + } else + strncpy(tmpbuf, host, sizeof(tmpbuf)); + pch = strchr(tmpbuf, '%'); + if (pch != NULL) + *pch = '\0'; + + if (inet_pton(AF_INET6, tmpbuf, &in6) == 1) { + isc_netaddr_fromin6(addr, &in6); + return (ISC_TRUE); + } + } + /* + * If we got here it was not an IP address + */ + return (ISC_FALSE); +} + + +/* * interface list enumerator - visitor pattern */ void -interface_enumerate(interface_receiver_t receiver, void *data) +interface_enumerate( + interface_receiver_t receiver, + void * data + ) { interface_info_t ifi; - struct interface *interf; ifi.action = IFS_EXISTS; - for (interf = ISC_LIST_HEAD(inter_list); - interf != NULL; - interf = ISC_LIST_NEXT(interf, link)) { - ifi.interface = interf; - receiver(data, &ifi); - } + for (ifi.interface = inter_list; + ifi.interface != NULL; + ifi.interface = ifi.interface->link) + (*receiver)(data, &ifi); } /* * do standard initialization of interface structure */ static void -init_interface(struct interface *interface) +init_interface( + struct interface *iface + ) { - memset((char *)interface, 0, sizeof(struct interface)); - ISC_LINK_INIT(interface, link); - ISC_LIST_INIT(interface->peers); - interface->fd = INVALID_SOCKET; - interface->bfd = INVALID_SOCKET; - interface->num_mcast = 0; - interface->received = 0; - interface->sent = 0; - interface->notsent = 0; - interface->peercnt = 0; - interface->phase = sys_interphase; + memset(iface, 0, sizeof(*iface)); + iface->fd = INVALID_SOCKET; + iface->bfd = INVALID_SOCKET; + iface->phase = sys_interphase; } + /* * create new interface structure initialize from * template structure or via standard initialization * function */ static struct interface * -new_interface(struct interface *interface) +new_interface( + struct interface *interface + ) { - static u_int sys_ifnum = 0; + static u_int sys_ifnum = 0; + struct interface * iface; - struct interface *iface = (struct interface *)emalloc(sizeof(struct interface)); + iface = emalloc(sizeof(*iface)); - if (interface != NULL) - { - memcpy((char*)iface, (char*)interface, sizeof(*interface)); - } - else - { + if (NULL == interface) init_interface(iface); - } + else /* use the template */ + memcpy(iface, interface, sizeof(*iface)); - iface->ifnum = sys_ifnum++; /* count every new instance of an interface in the system */ + /* count every new instance of an interface in the system */ + iface->ifnum = sys_ifnum++; iface->starttime = current_time; return iface; } + /* * return interface storage into free memory pool */ -static void -delete_interface(struct interface *interface) +static inline void +delete_interface( + struct interface *interface + ) { free(interface); } + /* * link interface into list of known interfaces */ static void -add_interface(struct interface *interface) +add_interface( + struct interface *interface + ) { - static struct interface *listhead = NULL; - - /* - * For ntpd, the first few interfaces (wildcard, localhost) - * will never be removed. This means inter_list.head is - * unchanging once initialized. Take advantage of that to - * watch for changes and catch corruption earlier. This - * helped track down corruption caused by using FD_SET with - * a descriptor numerically larger than FD_SETSIZE. - */ - if (NULL == listhead) - listhead = inter_list.head; - - if (listhead != inter_list.head) { - msyslog(LOG_ERR, "add_interface inter_list.head corrupted: was %p now %p", - listhead, inter_list.head); - exit(1); - } /* * Calculate the address hash */ interface->addr_refid = addr2refid(&interface->sin); - - ISC_LIST_APPEND(inter_list, interface, link); + + LINK_SLIST(inter_list, interface, link); ninterfaces++; } + /* * remove interface from known interface list and clean up * associated resources */ static void -remove_interface(struct interface *interface) +remove_interface( + struct interface *iface + ) { - struct sockaddr_storage resmask; + struct interface *unlinked; + sockaddr_u resmask; - ISC_LIST_UNLINK_TYPE(inter_list, interface, link, struct interface); + UNLINK_SLIST(unlinked, inter_list, iface, link, struct + interface); - delete_interface_from_list(interface); + delete_interface_from_list(iface); - if (interface->fd != INVALID_SOCKET) - { - msyslog(LOG_INFO, "Deleting interface #%d %s, %s#%d, interface stats: received=%ld, sent=%ld, dropped=%ld, active_time=%ld secs", - interface->ifnum, - interface->name, - stoa((&interface->sin)), - NTP_PORT, /* XXX should extract port from sin structure */ - interface->received, - interface->sent, - interface->notsent, - current_time - interface->starttime); + if (iface->fd != INVALID_SOCKET) { + msyslog(LOG_INFO, + "Deleting interface #%d %s, %s#%d, interface stats: received=%ld, sent=%ld, dropped=%ld, active_time=%ld secs", + iface->ifnum, + iface->name, + stoa(&iface->sin), + SRCPORT(&iface->sin), + iface->received, + iface->sent, + iface->notsent, + current_time - iface->starttime); + + close_and_delete_fd_from_list(iface->fd); + } + + if (iface->bfd != INVALID_SOCKET) { + msyslog(LOG_INFO, + "Deleting broadcast address %s#%d from interface #%d %s", + stoa(&iface->bcast), + SRCPORT(&iface->bcast), + iface->ifnum, + iface->name); - close_and_delete_fd_from_list(interface->fd); - } - - if (interface->bfd != INVALID_SOCKET) - { - msyslog(LOG_INFO, "Deleting interface #%d %s, broadcast address %s#%d", - interface->ifnum, - interface->name, - stoa((&interface->bcast)), - (u_short) NTP_PORT); /* XXX extract port from sin structure */ - close_and_delete_fd_from_list(interface->bfd); + close_and_delete_fd_from_list(iface->bfd); } ninterfaces--; - ntp_monclearinterface(interface); + ntp_monclearinterface(iface); /* remove restrict interface entry */ - - /* - * Blacklist bound interface address - */ - SET_HOSTMASK(&resmask, interface->sin.ss_family); - hack_restrict(RESTRICT_REMOVEIF, &interface->sin, &resmask, - RESM_NTPONLY|RESM_INTERFACE, RES_IGNORE); + SET_HOSTMASK(&resmask, AF(&iface->sin)); + hack_restrict(RESTRICT_REMOVEIF, &iface->sin, &resmask, + RESM_NTPONLY | RESM_INTERFACE, RES_IGNORE); } + static void -list_if_listening(struct interface *interface, u_short port) +list_if_listening( + struct interface * iface + ) { - msyslog(LOG_INFO, "Listening on interface #%d %s, %s#%d %s", - interface->ifnum, - interface->name, - stoa((&interface->sin)), - ntohs( (u_short) port), - (interface->ignore_packets == ISC_FALSE) ? - "Enabled": "Disabled"); + msyslog(LOG_INFO, "%s on %d %s %s UDP %d", + (iface->ignore_packets) + ? "Listen and drop" + : "Listen normally", + iface->ifnum, + iface->name, + stoa(&iface->sin), + SRCPORT(&iface->sin)); } + static void -create_wildcards(u_short port) { - isc_boolean_t okipv4 = ISC_TRUE; +create_wildcards( + u_short port + ) +{ + int v4wild, v6wild; + sockaddr_u wildaddr; + isc_netaddr_t wnaddr; + nic_rule_action action; + struct interface * wildif; + + /* + * silence "potentially uninitialized" warnings from VC9 + * failing to follow the logic. Ideally action could remain + * uninitialized, and the memset be the first statement under + * the first if (v4wild). + */ + action = ACTION_LISTEN; + memset(&wildaddr, 0, sizeof(wildaddr)); + /* * create pseudo-interface with wildcard IPv4 address */ -#ifdef IPV6_V6ONLY - if(isc_net_probeipv4() != ISC_R_SUCCESS) - okipv4 = ISC_FALSE; -#endif - - if(okipv4 == ISC_TRUE) { - struct interface *interface = new_interface(NULL); - - interface->family = AF_INET; - interface->sin.ss_family = AF_INET; - ((struct sockaddr_in*)&interface->sin)->sin_addr.s_addr = htonl(INADDR_ANY); - ((struct sockaddr_in*)&interface->sin)->sin_port = port; - (void) strncpy(interface->name, "wildcard", sizeof(interface->name)); - interface->mask.ss_family = AF_INET; - ((struct sockaddr_in*)&interface->mask)->sin_addr.s_addr = htonl(~(u_int32)0); - interface->flags = INT_BROADCAST | INT_UP | INT_WILDCARD; - interface->ignore_packets = ISC_TRUE; + v4wild = ipv4_works; + if (v4wild) { + /* set wildaddr to the v4 wildcard address 0.0.0.0 */ + AF(&wildaddr) = AF_INET; + SET_ADDR4(&wildaddr, INADDR_ANY); + SET_PORT(&wildaddr, port); + + /* make an libisc-friendly copy */ + isc_netaddr_fromin(&wnaddr, &wildaddr.sa4.sin_addr); + + /* check for interface/nic rules affecting the wildcard */ + action = interface_action(NULL, &wnaddr, 0); + v4wild = (ACTION_IGNORE != action); + } + if (v4wild) { + wildif = new_interface(NULL); + + strncpy(wildif->name, "v4wildcard", sizeof(wildif->name)); + memcpy(&wildif->sin, &wildaddr, sizeof(wildif->sin)); + wildif->family = AF_INET; + AF(&wildif->mask) = AF_INET; + SET_ONESMASK(&wildif->mask); + + wildif->flags = INT_BROADCAST | INT_UP | INT_WILDCARD; + wildif->ignore_packets = (ACTION_DROP == action); #if defined(MCAST) /* - * enable possible multicast reception on the broadcast socket + * enable multicast reception on the broadcast socket */ - interface->bcast.ss_family = AF_INET; - ((struct sockaddr_in*)&interface->bcast)->sin_port = port; - ((struct sockaddr_in*)&interface->bcast)->sin_addr.s_addr = htonl(INADDR_ANY); + AF(&wildif->bcast) = AF_INET; + SET_ADDR4(&wildif->bcast, INADDR_ANY); + SET_PORT(&wildif->bcast, port); #endif /* MCAST */ - interface->fd = open_socket(&interface->sin, - interface->flags, 1, interface); + wildif->fd = open_socket(&wildif->sin, 0, 1, wildif); - if (interface->fd != INVALID_SOCKET) { - wildipv4 = interface; - any_interface = interface; + if (wildif->fd != INVALID_SOCKET) { + wildipv4 = wildif; + any_interface = wildif; - add_addr_to_list(&interface->sin, interface); - add_interface(interface); - list_if_listening(interface, port); + add_addr_to_list(&wildif->sin, wildif); + add_interface(wildif); + list_if_listening(wildif); } else { - msyslog(LOG_ERR, "unable to bind to wildcard socket address %s - another process may be running - EXITING", - stoa((&interface->sin))); + msyslog(LOG_ERR, + "unable to bind to wildcard address %s - another process may be running - EXITING", + stoa(&wildif->sin)); exit(1); } + DPRINT_INTERFACE(2, (wildif, "created ", "\n")); } #ifdef INCLUDE_IPV6_SUPPORT /* * create pseudo-interface with wildcard IPv6 address */ - if (isc_net_probeipv6() == ISC_R_SUCCESS) { - struct interface *interface = new_interface(NULL); - - interface->family = AF_INET6; - interface->sin.ss_family = AF_INET6; - ((struct sockaddr_in6*)&interface->sin)->sin6_addr = in6addr_any; - ((struct sockaddr_in6*)&interface->sin)->sin6_port = port; -# ifdef ISC_PLATFORM_HAVESCOPEID - ((struct sockaddr_in6*)&interface->sin)->sin6_scope_id = 0; -# endif - (void) strncpy(interface->name, "wildcard", sizeof(interface->name)); - interface->mask.ss_family = AF_INET6; - memset(&((struct sockaddr_in6*)&interface->mask)->sin6_addr.s6_addr, 0xff, sizeof(struct in6_addr)); - interface->flags = INT_UP | INT_WILDCARD; - interface->ignore_packets = ISC_TRUE; - - interface->fd = open_socket(&interface->sin, - interface->flags, 1, interface); - - if (interface->fd != INVALID_SOCKET) { - wildipv6 = interface; - any6_interface = interface; - add_addr_to_list(&interface->sin, interface); - add_interface(interface); - list_if_listening(interface, port); + v6wild = ipv6_works; + if (v6wild) { + /* set wildaddr to the v6 wildcard address :: */ + memset(&wildaddr, 0, sizeof(wildaddr)); + AF(&wildaddr) = AF_INET6; + SET_ADDR6N(&wildaddr, in6addr_any); + SET_PORT(&wildaddr, port); + SET_SCOPE(&wildaddr, 0); + + /* make an libisc-friendly copy */ + isc_netaddr_fromin(&wnaddr, &wildaddr.sa4.sin_addr); + + /* check for interface/nic rules affecting the wildcard */ + action = interface_action(NULL, &wnaddr, 0); + v6wild = (ACTION_IGNORE != action); + } + if (v6wild) { + wildif = new_interface(NULL); + + strncpy(wildif->name, "v6wildcard", sizeof(wildif->name)); + memcpy(&wildif->sin, &wildaddr, sizeof(wildif->sin)); + wildif->family = AF_INET6; + AF(&wildif->mask) = AF_INET6; + SET_ONESMASK(&wildif->mask); + + wildif->flags = INT_UP | INT_WILDCARD; + wildif->ignore_packets = (ACTION_DROP == action); + + wildif->fd = open_socket(&wildif->sin, 0, 1, wildif); + + if (wildif->fd != INVALID_SOCKET) { + wildipv6 = wildif; + any6_interface = wildif; + add_addr_to_list(&wildif->sin, wildif); + add_interface(wildif); + list_if_listening(wildif); } else { - msyslog(LOG_ERR, "unable to bind to wildcard socket address %s - another process may be running - EXITING", - stoa((&interface->sin))); + msyslog(LOG_ERR, + "unable to bind to wildcard address %s - another process may be running - EXITING", + stoa(&wildif->sin)); exit(1); } + DPRINT_INTERFACE(2, (wildif, "created ", "\n")); } #endif } -static isc_boolean_t -address_okay(struct interface *iface) { +/* + * add_nic_rule() -- insert a rule entry at the head of nic_rule_list. + */ +void +add_nic_rule( + nic_rule_match match_type, + const char * if_name, /* interface name or numeric address */ + int prefixlen, + nic_rule_action action + ) +{ + nic_rule * rule; + isc_boolean_t is_ip; - DPRINTF(4, ("address_okay: listen Virtual: %d, IF name: %s\n", - listen_to_virtual_ips, iface->name)); + rule = emalloc(sizeof(*rule)); + memset(rule, 0, sizeof(*rule)); + rule->match_type = match_type; + rule->prefixlen = prefixlen; + rule->action = action; + + if (MATCH_IFNAME == match_type) { + NTP_REQUIRE(NULL != if_name); + rule->if_name = estrdup(if_name); + } else if (MATCH_IFADDR == match_type) { + NTP_REQUIRE(NULL != if_name); + /* set rule->netaddr */ + is_ip = is_ip_address(if_name, &rule->netaddr); + NTP_REQUIRE(is_ip); + } else + NTP_REQUIRE(NULL == if_name); - /* - * Always allow the loopback - */ - if((iface->flags & INT_LOOPBACK) != 0) { - DPRINTF(4, ("address_okay: loopback - OK\n")); - return (ISC_TRUE); - } + LINK_SLIST(nic_rule_list, rule, next); +} - /* - * Check if the interface is specified - */ - if (specific_interface != NULL) { - if (strcasecmp(iface->name, specific_interface) == 0) { - DPRINTF(4, ("address_okay: specific interface name matched - OK\n")); - return (ISC_TRUE); - } else { - DPRINTF(4, ("address_okay: specific interface name NOT matched - FAIL\n")); - return (ISC_FALSE); - } - } - else { - if (listen_to_virtual_ips == 0 && - (strchr(iface->name, (int)':') != NULL)) { - DPRINTF(4, ("address_okay: virtual ip/alias - FAIL\n")); - return (ISC_FALSE); - } + +#ifdef DEBUG +static const char * +action_text( + nic_rule_action action + ) +{ + const char *t; + + switch (action) { + + default: + t = "ERROR"; /* quiet uninit warning */ + DPRINTF(1, ("fatal: unknown nic_rule_action %d\n", + action)); + NTP_ENSURE(0); + break; + + case ACTION_LISTEN: + t = "listen"; + break; + + case ACTION_IGNORE: + t = "ignore"; + break; + + case ACTION_DROP: + t = "drop"; + break; } - DPRINTF(4, ("address_okay: OK\n")); - return (ISC_TRUE); + return t; } +#endif /* DEBUG */ -static void -convert_isc_if(isc_interface_t *isc_if, struct interface *itf, u_short port) + +static nic_rule_action +interface_action( + char * if_name, + isc_netaddr_t * if_netaddr, + isc_uint32_t if_flags + ) { - itf->scopeid = 0; - itf->family = (short) isc_if->af; - strcpy(itf->name, isc_if->name); + nic_rule *rule; + int isloopback; + int iswildcard; - if(isc_if->af == AF_INET) { - itf->sin.ss_family = (u_short) isc_if->af; - memcpy(&(((struct sockaddr_in*)&itf->sin)->sin_addr), - &(isc_if->address.type.in), - sizeof(struct in_addr)); - ((struct sockaddr_in*)&itf->sin)->sin_port = port; + DPRINTF(4, ("interface_action: interface %s ", + (if_name != NULL) ? if_name : "wildcard")); - if((isc_if->flags & INTERFACE_F_BROADCAST) != 0) { - itf->flags |= INT_BROADCAST; - itf->bcast.ss_family = itf->sin.ss_family; - memcpy(&(((struct sockaddr_in*)&itf->bcast)->sin_addr), - &(isc_if->broadcast.type.in), - sizeof(struct in_addr)); - ((struct sockaddr_in*)&itf->bcast)->sin_port = port; + iswildcard = is_wildcard_netaddr(if_netaddr); + + /* + * Always listen on 127.0.0.1 - required by ntp_intres + */ + if (if_flags & INTERFACE_F_LOOPBACK) { + isloopback = 1; + if (AF_INET == if_netaddr->family) { + DPRINTF(4, ("IPv4 loopback - listen\n")); + return ACTION_LISTEN; } + } else + isloopback = 0; - itf->mask.ss_family = itf->sin.ss_family; - memcpy(&(((struct sockaddr_in*)&itf->mask)->sin_addr), - &(isc_if->netmask.type.in), - sizeof(struct in_addr)); - ((struct sockaddr_in*)&itf->mask)->sin_port = port; - } -#ifdef INCLUDE_IPV6_SUPPORT - else if (isc_if->af == AF_INET6) { - itf->sin.ss_family = (u_short) isc_if->af; - memcpy(&(((struct sockaddr_in6 *)&itf->sin)->sin6_addr), - &(isc_if->address.type.in6), - sizeof(((struct sockaddr_in6 *)&itf->sin)->sin6_addr)); - ((struct sockaddr_in6 *)&itf->sin)->sin6_port = port; + /* + * Find any matching NIC rule from --interface / -I or ntp.conf + * interface/nic rules. + */ + for (rule = nic_rule_list; rule != NULL; rule = rule->next) { -#ifdef ISC_PLATFORM_HAVESCOPEID - ((struct sockaddr_in6 *)&itf->sin)->sin6_scope_id = isc_netaddr_getzone(&isc_if->address); - itf->scopeid = isc_netaddr_getzone(&isc_if->address); -#endif - itf->mask.ss_family = itf->sin.ss_family; - memcpy(&(((struct sockaddr_in6 *)&itf->mask)->sin6_addr), - &(isc_if->netmask.type.in6), - sizeof(struct in6_addr)); - ((struct sockaddr_in6 *)&itf->mask)->sin6_port = port; - /* Copy the interface index */ - itf->ifindex = isc_if->ifindex; - } -#endif /* INCLUDE_IPV6_SUPPORT */ + switch (rule->match_type) { + case MATCH_ALL: + /* loopback and wildcard excluded from "all" */ + if (isloopback || iswildcard) + break; + DPRINTF(4, ("nic all %s\n", + action_text(rule->action))); + return rule->action; + + case MATCH_IPV4: + if (AF_INET == if_netaddr->family) { + DPRINTF(4, ("nic ipv4 %s\n", + action_text(rule->action))); + return rule->action; + } + break; - /* Process the rest of the flags */ + case MATCH_IPV6: + if (AF_INET6 == if_netaddr->family) { + DPRINTF(4, ("nic ipv6 %s\n", + action_text(rule->action))); + return rule->action; + } + break; - if((isc_if->flags & INTERFACE_F_UP) != 0) - itf->flags |= INT_UP; - if((isc_if->flags & INTERFACE_F_LOOPBACK) != 0) - itf->flags |= INT_LOOPBACK; - if((isc_if->flags & INTERFACE_F_POINTTOPOINT) != 0) - itf->flags |= INT_PPP; - if((isc_if->flags & INTERFACE_F_MULTICAST) != 0) - itf->flags |= INT_MULTICAST; + case MATCH_WILDCARD: + if (iswildcard) { + DPRINTF(4, ("nic wildcard %s\n", + action_text(rule->action))); + return rule->action; + } + break; + + case MATCH_IFADDR: + if (rule->prefixlen != -1) { + if (isc_netaddr_eqprefix(if_netaddr, + &rule->netaddr, rule->prefixlen)) { + + DPRINTF(4, ("subnet address match - %s\n", + action_text(rule->action))); + return rule->action; + } + } else + if (isc_netaddr_equal(if_netaddr, + &rule->netaddr)) { + + DPRINTF(4, ("address match - %s\n", + action_text(rule->action))); + return rule->action; + } + break; + + case MATCH_IFNAME: + if (if_name != NULL + && !strcasecmp(if_name, rule->if_name)) { + + DPRINTF(4, ("interface name match - %s\n", + action_text(rule->action))); + return rule->action; + } + break; + } + } + + /* + * Unless explicitly disabled such as with "nic ignore ::1" + * listen on loopback addresses. Since ntpq and ntpdc query + * "localhost" by default, which typically resolves to ::1 and + * 127.0.0.1, it's useful to default to listening on both. + */ + if (isloopback) { + DPRINTF(4, ("default loopback listen\n")); + return ACTION_LISTEN; + } + + /* + * Treat wildcard addresses specially. If there is no explicit + * "nic ... wildcard" or "nic ... 0.0.0.0" or "nic ... ::" rule + * default to drop. + */ + if (iswildcard) { + DPRINTF(4, ("default wildcard drop\n")); + return ACTION_DROP; + } + + /* + * Check for "virtual IP" (colon in the interface name) after + * the rules so that "ntpd --interface eth0:1 -novirtualips" + * does indeed listen on eth0:1's addresses. + */ + if (!listen_to_virtual_ips && if_name != NULL + && (strchr(if_name, ':') != NULL)) { + + DPRINTF(4, ("virtual ip - ignore\n")); + return ACTION_IGNORE; + } + + /* + * If there are no --interface/-I command-line options and no + * interface/nic rules in ntp.conf, the default action is to + * listen. In the presence of rules from either, the default + * is to ignore. This implements ntpd's traditional listen- + * every default with no interface listen configuration, and + * ensures a single -I eth0 or "nic listen eth0" means do not + * listen on any other addresses. + */ + if (NULL == nic_rule_list) { + DPRINTF(4, ("default listen\n")); + return ACTION_LISTEN; + } + + DPRINTF(4, ("implicit ignore\n")); + return ACTION_IGNORE; +} + + +static void +convert_isc_if( + isc_interface_t *isc_if, + struct interface *itf, + u_short port + ) +{ + strncpy(itf->name, isc_if->name, sizeof(itf->name)); + itf->name[sizeof(itf->name) - 1] = 0; /* strncpy may not */ + itf->family = (u_short)isc_if->af; + AF(&itf->sin) = itf->family; + AF(&itf->mask) = itf->family; + AF(&itf->bcast) = itf->family; + SET_PORT(&itf->sin, port); + SET_PORT(&itf->mask, port); + SET_PORT(&itf->bcast, port); + + if (IS_IPV4(&itf->sin)) { + NSRCADR(&itf->sin) = isc_if->address.type.in.s_addr; + NSRCADR(&itf->mask) = isc_if->netmask.type.in.s_addr; + + if (isc_if->flags & INTERFACE_F_BROADCAST) { + itf->flags |= INT_BROADCAST; + NSRCADR(&itf->bcast) = + isc_if->broadcast.type.in.s_addr; + } + } +#ifdef INCLUDE_IPV6_SUPPORT + else if (IS_IPV6(&itf->sin)) { + SET_ADDR6N(&itf->sin, isc_if->address.type.in6); + SET_ADDR6N(&itf->mask, isc_if->netmask.type.in6); + + itf->scopeid = isc_netaddr_getzone(&isc_if->address); + SET_SCOPE(&itf->sin, itf->scopeid); + } +#endif /* INCLUDE_IPV6_SUPPORT */ + + + /* Process the rest of the flags */ + + itf->flags |= + ((INTERFACE_F_UP & isc_if->flags) + ? INT_UP : 0) + | ((INTERFACE_F_LOOPBACK & isc_if->flags) + ? INT_LOOPBACK : 0) + | ((INTERFACE_F_POINTTOPOINT & isc_if->flags) + ? INT_PPP : 0) + | ((INTERFACE_F_MULTICAST & isc_if->flags) + ? INT_MULTICAST : 0) + ; +} -} /* * refresh_interface @@ -1057,27 +1326,25 @@ * the socket. */ static int -refresh_interface(struct interface * interface) +refresh_interface( + struct interface * interface + ) { #ifdef OS_MISSES_SPECIFIC_ROUTE_UPDATES - if (interface->fd != INVALID_SOCKET) - { + if (interface->fd != INVALID_SOCKET) { close_and_delete_fd_from_list(interface->fd); interface->fd = open_socket(&interface->sin, - interface->flags, 0, interface); + 0, 0, interface); /* * reset TTL indication so TTL is is set again * next time around */ interface->last_ttl = 0; - return interface->fd != INVALID_SOCKET; - } - else - { + return (interface->fd != INVALID_SOCKET); + } else return 0; /* invalid sockets are not refreshable */ - } #else /* !OS_MISSES_SPECIFIC_ROUTE_UPDATES */ - return interface->fd != INVALID_SOCKET; + return (interface->fd != INVALID_SOCKET); #endif /* !OS_MISSES_SPECIFIC_ROUTE_UPDATES */ } @@ -1085,125 +1352,124 @@ * interface_update - externally callable update function */ void -interface_update(interface_receiver_t receiver, void *data) +interface_update( + interface_receiver_t receiver, + void * data) { - if (!disable_dynamic_updates) { - int new_interface_found; + int new_interface_found; - BLOCKIO(); - new_interface_found = update_interfaces(htons(NTP_PORT), receiver, data); - UNBLOCKIO(); + if (disable_dynamic_updates) + return; + + BLOCKIO(); + new_interface_found = update_interfaces(NTP_PORT, receiver, data); + UNBLOCKIO(); + + if (!new_interface_found) + return; - if (new_interface_found) { #ifdef DEBUG - msyslog(LOG_DEBUG, "new interface(s) found: waking up resolver"); + msyslog(LOG_DEBUG, "new interface(s) found: waking up resolver"); #endif #ifdef SYS_WINNT - /* wake up the resolver thread */ - if (ResolverEventHandle != NULL) - SetEvent(ResolverEventHandle); + /* wake up the resolver thread */ + if (ResolverEventHandle != NULL) + SetEvent(ResolverEventHandle); #else - /* write any single byte to the pipe to wake up the resolver process */ - write( resolver_pipe_fd[1], &new_interface_found, 1 ); + /* write any single byte to the pipe to wake up the resolver process */ + write( resolver_pipe_fd[1], &new_interface_found, 1 ); #endif - } - } } + /* - * find out if a given interface structure contains - * a wildcard address + * sau_from_netaddr() - convert network address on-wire formats. + * Convert from libisc's isc_netaddr_t to NTP's sockaddr_u */ +void +sau_from_netaddr( + sockaddr_u *psau, + const isc_netaddr_t *pna + ) +{ + memset(psau, 0, sizeof(*psau)); + AF(psau) = (u_short)pna->family; + switch (pna->family) { + + case AF_INET: + memcpy(&psau->sa4.sin_addr, &pna->type.in, + sizeof(psau->sa4.sin_addr)); + break; + + case AF_INET6: + memcpy(&psau->sa6.sin6_addr, &pna->type.in6, + sizeof(psau->sa6.sin6_addr)); + break; + } +} + + static int -is_wildcard_addr(struct sockaddr_storage *sas) +is_wildcard_addr( + sockaddr_u *psau + ) { - if (sas->ss_family == AF_INET && - ((struct sockaddr_in*)sas)->sin_addr.s_addr == htonl(INADDR_ANY)) + if (IS_IPV4(psau) && !NSRCADR(psau)) return 1; #ifdef INCLUDE_IPV6_SUPPORT - if (sas->ss_family == AF_INET6 && - memcmp(&((struct sockaddr_in6*)sas)->sin6_addr, &in6addr_any, - sizeof(in6addr_any) == 0)) + if (IS_IPV6(psau) && S_ADDR6_EQ(psau, &in6addr_any)) return 1; #endif return 0; } + +static int +is_wildcard_netaddr( + const isc_netaddr_t *pna + ) +{ + sockaddr_u sau; + + sau_from_netaddr(&sau, pna); + + return is_wildcard_addr(&sau); +} + + #ifdef OS_NEEDS_REUSEADDR_FOR_IFADDRBIND /* * enable/disable re-use of wildcard address socket */ static void -set_wildcard_reuse(int family, int on) +set_wildcard_reuse( + u_short family, + int on + ) { - int onvalue = 1; - int offvalue = 0; - int *onoff; + struct interface *any; SOCKET fd = INVALID_SOCKET; - onoff = on ? &onvalue : &offvalue; - - switch (family) { - case AF_INET: - if (any_interface) { - fd = any_interface->fd; - } - break; - -#ifdef INCLUDE_IPV6_SUPPORT - case AF_INET6: - if (any6_interface) { - fd = any6_interface->fd; - } - break; -#endif /* !INCLUDE_IPV6_SUPPORT */ - } + any = ANY_INTERFACE_BYFAM(family); + if (any != NULL) + fd = any->fd; if (fd != INVALID_SOCKET) { - if (setsockopt(fd, SOL_SOCKET, - SO_REUSEADDR, (char *)onoff, - sizeof(*onoff))) { - netsyslog(LOG_ERR, "set_wildcard_reuse: setsockopt(SO_REUSEADDR, %s) failed: %m", *onoff ? "on" : "off"); - } - DPRINTF(4, ("set SO_REUSEADDR to %s on %s\n", *onoff ? "ON" : "OFF", - stoa((family == AF_INET) ? - &any_interface->sin : &any6_interface->sin))); + if (setsockopt(fd, SOL_SOCKET, SO_REUSEADDR, + (char *)&on, sizeof(on))) + msyslog(LOG_ERR, + "set_wildcard_reuse: setsockopt(SO_REUSEADDR, %s) failed: %m", + on ? "on" : "off"); + + DPRINTF(4, ("set SO_REUSEADDR to %s on %s\n", + on ? "on" : "off", + stoa(&any->sin))); } } #endif /* OS_NEEDS_REUSEADDR_FOR_IFADDRBIND */ -#ifdef INCLUDE_IPV6_SUPPORT -static isc_boolean_t -is_anycast(struct sockaddr *sa, char *name) -{ -#if defined(SIOCGIFAFLAG_IN6) && defined(IN6_IFF_ANYCAST) - struct in6_ifreq ifr6; - int fd; - u_int32_t flags6; - - if (sa->sa_family != AF_INET6) - return ISC_FALSE; - if ((fd = socket(AF_INET6, SOCK_DGRAM, 0)) < 0) - return ISC_FALSE; - memset(&ifr6, 0, sizeof(ifr6)); - memcpy(&ifr6.ifr_addr, (struct sockaddr_in6 *)sa, - sizeof(struct sockaddr_in6)); - strlcpy(ifr6.ifr_name, name, IF_NAMESIZE); - if (ioctl(fd, SIOCGIFAFLAG_IN6, &ifr6) < 0) { - close(fd); - return ISC_FALSE; - } - close(fd); - flags6 = ifr6.ifr_ifru.ifru_flags6; - if ((flags6 & IN6_IFF_ANYCAST) != 0) - return ISC_TRUE; -#endif /* !SIOCGIFAFLAG_IN6 || !IN6_IFF_ANYCAST */ - return ISC_FALSE; -} -#endif /* !INCLUDE_IPV6_SUPPORT */ - /* * update_interface strategy * @@ -1212,17 +1478,17 @@ * Phase 1: * forall currently existing interfaces * if address is known: - * drop socket - rebind again + * drop socket - rebind again * * if address is NOT known: - * attempt to create a new interface entry + * attempt to create a new interface entry * * Phase 2: * forall currently known non MCAST and WILDCARD interfaces * if interface does not match configuration phase (not seen in phase 1): - * remove interface from known interface list - * forall peers associated with this interface - * disconnect peer from this interface + * remove interface from known interface list + * forall peers associated with this interface + * disconnect peer from this interface * * Phase 3: * attempt to re-assign interfaces to peers @@ -1231,67 +1497,47 @@ static int update_interfaces( - u_short port, - interface_receiver_t receiver, - void *data + u_short port, + interface_receiver_t receiver, + void * data ) { - interface_info_t ifi; - isc_mem_t *mctx = NULL; - isc_interfaceiter_t *iter = NULL; - isc_boolean_t scan_ipv4 = ISC_FALSE; - isc_boolean_t scan_ipv6 = ISC_FALSE; - isc_result_t result; - int new_interface_found = 0; + isc_mem_t * mctx = (void *)-1; + interface_info_t ifi; + isc_interfaceiter_t * iter; + isc_result_t result; + isc_interface_t isc_if; + int new_interface_found; + unsigned int family; + struct interface interface; + struct interface * iface; + struct interface * next; - DPRINTF(3, ("update_interfaces(%d)\n", ntohs( (u_short) port))); - -#ifdef INCLUDE_IPV6_SUPPORT - if (isc_net_probeipv6() == ISC_R_SUCCESS) - scan_ipv6 = ISC_TRUE; -#if defined(DEBUG) - else - if (debug) - netsyslog(LOG_ERR, "no IPv6 interfaces found"); -#endif -#endif - if (isc_net_probeipv6() == ISC_R_SUCCESS) - scan_ipv6 = ISC_TRUE; -#if defined(ISC_PLATFORM_HAVEIPV6) && defined(DEBUG) - else - if (debug) - netsyslog(LOG_ERR, "no IPv6 interfaces found"); -#endif + DPRINTF(3, ("update_interfaces(%d)\n", port)); - if (isc_net_probeipv4() == ISC_R_SUCCESS) - scan_ipv4 = ISC_TRUE; -#ifdef DEBUG - else - if(debug) - netsyslog(LOG_ERR, "no IPv4 interfaces found"); -#endif /* * phase one - scan interfaces * - create those that are not found * - update those that are found */ + new_interface_found = 0; + iter = NULL; result = isc_interfaceiter_create(mctx, &iter); if (result != ISC_R_SUCCESS) return 0; - sys_interphase ^= 0x1; /* toggle system phase for finding untouched (to be deleted) interfaces */ + /* + * Toggle system interface scan phase to find untouched + * interfaces to be deleted. + */ + sys_interphase ^= 0x1; for (result = isc_interfaceiter_first(iter); - result == ISC_R_SUCCESS; - result = isc_interfaceiter_next(iter)) - { - isc_interface_t isc_if; - unsigned int family; - struct interface interface; - struct interface *iface; - + ISC_R_SUCCESS == result; + result = isc_interfaceiter_next(iter)) { + result = isc_interfaceiter_current(iter, &isc_if); if (result != ISC_R_SUCCESS) @@ -1299,39 +1545,42 @@ /* See if we have a valid family to use */ family = isc_if.address.family; - if (family != AF_INET && family != AF_INET6) + if (AF_INET != family && AF_INET6 != family) continue; - if (scan_ipv4 == ISC_FALSE && family == AF_INET) + if (AF_INET == family && !ipv4_works) continue; - if (scan_ipv6 == ISC_FALSE && family == AF_INET6) + if (AF_INET6 == family && !ipv6_works) continue; - /* - * create prototype - */ + /* create prototype */ init_interface(&interface); convert_isc_if(&isc_if, &interface, port); /* - * Check to see if we are going to use the interface - * If we don't use it we mark it to drop any packet - * received but we still must create the socket and - * bind to it. This prevents other apps binding to it - * and potentially causing problems with more than one - * process fiddling with the clock + * Check if and how we are going to use the interface. */ - if (address_okay(&interface) == ISC_TRUE) { + switch (interface_action(isc_if.name, &isc_if.address, + isc_if.flags)) { + + case ACTION_IGNORE: + continue; + + case ACTION_LISTEN: interface.ignore_packets = ISC_FALSE; - } - else { + break; + + case ACTION_DROP: interface.ignore_packets = ISC_TRUE; + break; } DPRINT_INTERFACE(4, (&interface, "examining ", "\n")); - if (!(interface.flags & INT_UP)) { /* interfaces must be UP to be usable */ - DPRINTF(4, ("skipping interface %s (%s) - DOWN\n", interface.name, stoa(&interface.sin))); + /* interfaces must be UP to be usable */ + if (!(interface.flags & INT_UP)) { + DPRINTF(4, ("skipping interface %s (%s) - DOWN\n", + interface.name, stoa(&interface.sin))); continue; } @@ -1343,59 +1592,106 @@ if (is_wildcard_addr(&interface.sin)) continue; -#ifdef INCLUDE_IPV6_SUPPORT - if (is_anycast((struct sockaddr *)&interface.sin, isc_if.name)) - continue; -#endif /* !INCLUDE_IPV6_SUPPORT */ - /* - * map to local *address* in order - * to map all duplicate interfaces to an interface structure - * with the appropriate socket (our name space is - * (ip-address) - NOT (interface name, ip-address)) + * map to local *address* in order to map all duplicate + * interfaces to an interface structure with the + * appropriate socket. Our name space is (ip-address), + * NOT (interface name, ip-address). */ iface = getinterface(&interface.sin, INT_WILDCARD); - if (iface && refresh_interface(iface)) - { + if (iface != NULL && refresh_interface(iface)) { /* - * found existing and up to date interface - mark present + * found existing and up to date interface - + * mark present. */ + if (iface->phase != sys_interphase) { + /* + * On a new round we reset the name so + * the interface name shows up again if + * this address is no longer shared. + * The same reasoning goes for the + * ignore_packets flag. + */ + strncpy(iface->name, interface.name, + sizeof(iface->name)); + iface->ignore_packets = + interface.ignore_packets; + } else + /* name collision - rename interface */ + strncpy(iface->name, "*multiple*", + sizeof(iface->name)); + + DPRINT_INTERFACE(4, (iface, "updating ", + " present\n")); + + if (iface->ignore_packets != + interface.ignore_packets) { + /* + * We have conflicting configurations + * for the interface address. This is + * caused by using -I + * for an interface that shares its + * address with other interfaces. We + * can not disambiguate incoming + * packets delivered to this socket + * without extra syscalls/features. + * These are not (commonly) available. + * Note this is a more unusual + * configuration where several + * interfaces share an address but + * filtering via interface name is + * attempted. We resolve the + * configuration conflict by disabling + * the processing of received packets. + * This leads to no service on the + * interface address where the conflict + * occurs. + */ + msyslog(LOG_ERR, + "WARNING: conflicting enable configuration for interfaces %s and %s for address %s - unsupported configuration - address DISABLED", + interface.name, iface->name, + stoa(&interface.sin)); + + iface->ignore_packets = ISC_TRUE; + } iface->phase = sys_interphase; - DPRINT_INTERFACE(4, (iface, "updating ", " present\n")); + ifi.action = IFS_EXISTS; ifi.interface = iface; - if (receiver) - receiver(data, &ifi); - } - else - { + if (receiver != NULL) + (*receiver)(data, &ifi); + } else { /* - * this is new or refreshing failed - add to our interface list - * if refreshing failed we will delete the interface structure in - * phase 2 as the interface was not marked current. We can bind to - * the address as the refresh code already closed the offending socket + * This is new or refreshing failed - add to + * our interface list. If refreshing failed we + * will delete the interface structure in phase + * 2 as the interface was not marked current. + * We can bind to the address as the refresh + * code already closed the offending socket */ - iface = create_interface(port, &interface); - if (iface) - { + if (iface != NULL) { ifi.action = IFS_CREATED; ifi.interface = iface; - if (receiver) - receiver(data, &ifi); + if (receiver != NULL) + (*receiver)(data, &ifi); new_interface_found = 1; - DPRINT_INTERFACE(3, (iface, "updating ", " new - created\n")); - } - else - { - DPRINT_INTERFACE(3, (&interface, "updating ", " new - creation FAILED")); + DPRINT_INTERFACE(3, + (iface, "updating ", + " new - created\n")); + } else { + DPRINT_INTERFACE(3, + (&interface, "updating ", + " new - creation FAILED")); - msyslog(LOG_INFO, "failed to initialize interface for address %s", stoa(&interface.sin)); + msyslog(LOG_INFO, + "failed to init interface for address %s", + stoa(&interface.sin)); continue; } } @@ -1404,58 +1700,51 @@ isc_interfaceiter_destroy(&iter); /* - * phase 2 - delete gone interfaces - reassigning peers to other interfaces + * phase 2 - delete gone interfaces - reassigning peers to + * other interfaces */ - { - struct interface *interf = ISC_LIST_HEAD(inter_list); + iface = inter_list; + + while (iface != NULL) { + next = iface->link; + + if (!(iface->flags & (INT_WILDCARD | INT_MCASTIF))) { + /* + * if phase does not match sys_phase this + * interface was not enumerated during the last + * interface scan - so it is gone and will be + * deleted here unless it is solely an MCAST or + * WILDCARD interface. + */ + if (iface->phase != sys_interphase) { + DPRINT_INTERFACE(3, + (iface, "updating ", + "GONE - deleting\n")); + remove_interface(iface); + + ifi.action = IFS_DELETED; + ifi.interface = iface; + if (receiver != NULL) + (*receiver)(data, &ifi); - while (interf != NULL) - { - struct interface *next = ISC_LIST_NEXT(interf, link); - - if (!(interf->flags & (INT_WILDCARD|INT_MCASTIF))) { /* - * if phase does not match sys_phase this interface was not - * enumerated during interface scan - so it is gone and - * will be deleted here unless it is solely an MCAST/WILDCARD interface + * disconnect peers from deleted + * interface */ - if (interf->phase != sys_interphase) { - struct peer *peer; - DPRINT_INTERFACE(3, (interf, "updating ", "GONE - deleting\n")); - remove_interface(interf); - - ifi.action = IFS_DELETED; - ifi.interface = interf; - if (receiver) - receiver(data, &ifi); - - peer = ISC_LIST_HEAD(interf->peers); - /* - * disconnect peer from deleted interface - */ - while (peer != NULL) { - struct peer *npeer = ISC_LIST_NEXT(peer, ilink); - - /* - * this one just lost it's interface - */ - set_peerdstadr(peer, NULL); - - peer = npeer; - } - - /* - * update globals in case we lose - * a loopback interface - */ - if (interf == loopback_interface) - loopback_interface = NULL; + while (iface->peers != NULL) + set_peerdstadr(iface->peers, NULL); - delete_interface(interf); - } + /* + * update globals in case we lose + * a loopback interface + */ + if (iface == loopback_interface) + loopback_interface = NULL; + + delete_interface(iface); } - interf = next; } + iface = next; } /* @@ -1483,7 +1772,7 @@ FD_ZERO(&activefds); #endif - DPRINTF(2, ("create_sockets(%d)\n", ntohs( (u_short) port))); + DPRINTF(2, ("create_sockets(%d)\n", port)); create_wildcards(port); @@ -1506,87 +1795,105 @@ */ static struct interface * create_interface( - u_short port, - struct interface *iface - ) + u_short port, + struct interface * protot + ) { - struct sockaddr_storage resmask; - struct interface *interface; + sockaddr_u resmask; + struct interface *iface; - DPRINTF(2, ("create_interface(%s#%d)\n", stoa(&iface->sin), ntohs( (u_short) port))); + DPRINTF(2, ("create_interface(%s#%d)\n", stoa(&protot->sin), + port)); /* build an interface */ - interface = new_interface(iface); + iface = new_interface(protot); /* * create socket */ - interface->fd = open_socket(&interface->sin, - interface->flags, 0, interface); + iface->fd = open_socket(&iface->sin, 0, 0, iface); - if (interface->fd != INVALID_SOCKET) - list_if_listening(interface, port); + if (iface->fd != INVALID_SOCKET) + list_if_listening(iface); - if ((interface->flags & INT_BROADCAST) && - interface->bfd != INVALID_SOCKET) - msyslog(LOG_INFO, "Listening on broadcast address %s#%d", - stoa((&interface->bcast)), - ntohs( (u_short) port)); + if ((INT_BROADCAST & iface->flags) + && iface->bfd != INVALID_SOCKET) + msyslog(LOG_INFO, "Listening on broadcast address %s#%d", + stoa((&iface->bcast)), port); - if (interface->fd == INVALID_SOCKET && - interface->bfd == INVALID_SOCKET) { + if (INVALID_SOCKET == iface->fd + && INVALID_SOCKET == iface->bfd) { msyslog(LOG_ERR, "unable to create socket on %s (%d) for %s#%d", - interface->name, - interface->ifnum, - stoa((&interface->sin)), - ntohs( (u_short) port)); - delete_interface(interface); + iface->name, + iface->ifnum, + stoa((&iface->sin)), + port); + delete_interface(iface); return NULL; } - /* - * Blacklist bound interface address + /* + * Blacklist our own addresses, no use talking to ourself */ - - SET_HOSTMASK(&resmask, interface->sin.ss_family); - hack_restrict(RESTRICT_FLAGS, &interface->sin, &resmask, - RESM_NTPONLY|RESM_INTERFACE, RES_IGNORE); + SET_HOSTMASK(&resmask, AF(&iface->sin)); + hack_restrict(RESTRICT_FLAGS, &iface->sin, &resmask, + RESM_NTPONLY | RESM_INTERFACE, RES_IGNORE); /* * set globals with the first found * loopback interface of the appropriate class */ - if ((loopback_interface == NULL) && - (interface->family == AF_INET) && - ((interface->flags & INT_LOOPBACK) != 0)) - { - loopback_interface = interface; - } + if (NULL == loopback_interface && AF_INET == iface->family + && (INT_LOOPBACK & iface->flags)) + loopback_interface = iface; /* * put into our interface list */ - add_addr_to_list(&interface->sin, interface); - add_interface(interface); + add_addr_to_list(&iface->sin, iface); + add_interface(iface); - DPRINT_INTERFACE(2, (interface, "created ", "\n")); - return interface; + DPRINT_INTERFACE(2, (iface, "created ", "\n")); + return iface; } #ifdef SO_EXCLUSIVEADDRUSE static void -set_excladdruse(int fd) +set_excladdruse( + SOCKET fd + ) { int one = 1; int failed; +#ifdef SYS_WINNT + DWORD err; +#endif failed = setsockopt(fd, SOL_SOCKET, SO_EXCLUSIVEADDRUSE, (char *)&one, sizeof(one)); - if (failed) - netsyslog(LOG_ERR, - "setsockopt(%d, SO_EXCLUSIVEADDRUSE, on): %m", fd); + if (!failed) + return; + +#ifdef SYS_WINNT + /* + * Prior to Windows XP setting SO_EXCLUSIVEADDRUSE can fail with + * error WSAINVAL depending on service pack level and whether + * the user account is in the Administrators group. Do not + * complain if it fails that way on versions prior to XP (5.1). + */ + err = GetLastError(); + + if (isc_win32os_versioncheck(5, 1, 0, 0) < 0 /* < 5.1/XP */ + && WSAEINVAL == err) + return; + + SetLastError(err); +#endif + msyslog(LOG_ERR, + "setsockopt(%d, SO_EXCLUSIVEADDRUSE, on): %m", + (int)fd); } #endif /* SO_EXCLUSIVEADDRUSE */ @@ -1597,14 +1904,16 @@ * fd's also? */ static void -set_reuseaddr(int flag) { - struct interface *interf; - +set_reuseaddr( + int flag + ) +{ #ifndef SO_EXCLUSIVEADDRUSE + struct interface *interf; - for (interf = ISC_LIST_HEAD(inter_list); + for (interf = inter_list; interf != NULL; - interf = ISC_LIST_NEXT(interf, link)) { + interf = interf->link) { if (interf->flags & INT_WILDCARD) continue; @@ -1613,13 +1922,15 @@ * if interf->fd is INVALID_SOCKET, we might have a adapter * configured but not present */ - DPRINTF(4, ("setting SO_REUSEADDR on %.16s@%s to %s\n", interf->name, stoa(&interf->sin), flag ? "on" : "off")); + DPRINTF(4, ("setting SO_REUSEADDR on %.16s@%s to %s\n", + interf->name, stoa(&interf->sin), + flag ? "on" : "off")); if (interf->fd != INVALID_SOCKET) { if (setsockopt(interf->fd, SOL_SOCKET, SO_REUSEADDR, (char *)&flag, sizeof(flag))) { - netsyslog(LOG_ERR, "set_reuseaddr: setsockopt(SO_REUSEADDR, %s) failed: %m", flag ? "on" : "off"); + msyslog(LOG_ERR, "set_reuseaddr: setsockopt(SO_REUSEADDR, %s) failed: %m", flag ? "on" : "off"); } } } @@ -1631,9 +1942,12 @@ * make other changes as necessary later on */ void -enable_broadcast(struct interface *iface, struct sockaddr_storage *baddr) +enable_broadcast( + struct interface * iface, + sockaddr_u * baddr + ) { -#ifdef SO_BROADCAST +#ifdef OPEN_BCAST_SOCKET socket_broadcast_enable(iface, iface->fd, baddr); #endif } @@ -1645,28 +1959,28 @@ * broadcasting. It is not this function's job to select the socket */ static isc_boolean_t -socket_broadcast_enable(struct interface *iface, SOCKET fd, struct sockaddr_storage *maddr) +socket_broadcast_enable( + struct interface * iface, + SOCKET fd, + sockaddr_u * baddr + ) { #ifdef SO_BROADCAST int on = 1; - if (maddr->ss_family == AF_INET) - { + if (IS_IPV4(baddr)) { /* if this interface can support broadcast, set SO_BROADCAST */ if (setsockopt(fd, SOL_SOCKET, SO_BROADCAST, (char *)&on, sizeof(on))) - { - netsyslog(LOG_ERR, "setsockopt(SO_BROADCAST) enable failure on address %s: %m", - stoa(maddr)); - } -#ifdef DEBUG - else if (debug > 1) { - printf("Broadcast enabled on socket %d for address %s\n", - fd, stoa(maddr)); - } -#endif + msyslog(LOG_ERR, + "setsockopt(SO_BROADCAST) enable failure on address %s: %m", + stoa(baddr)); + else + DPRINTF(2, ("Broadcast enabled on socket %d for address %s\n", + fd, stoa(baddr))); } iface->flags |= INT_BCASTOPEN; + broadcast_client_enabled = ISC_TRUE; return ISC_TRUE; #else return ISC_FALSE; @@ -1679,21 +1993,22 @@ * broadcasting. It is not this function's job to select the socket */ static isc_boolean_t -socket_broadcast_disable(struct interface *iface, struct sockaddr_storage *maddr) +socket_broadcast_disable( + struct interface * iface, + sockaddr_u * baddr + ) { #ifdef SO_BROADCAST int off = 0; /* This seems to be OK as an int */ - if (maddr->ss_family == AF_INET) - { - if (setsockopt(iface->fd, SOL_SOCKET, SO_BROADCAST, - (char *)&off, sizeof(off))) - { - netsyslog(LOG_ERR, "setsockopt(SO_BROADCAST) disable failure on address %s: %m", - stoa(maddr)); - } - } + if (IS_IPV4(baddr) && setsockopt(iface->fd, SOL_SOCKET, + SO_BROADCAST, (char *)&off, sizeof(off))) + msyslog(LOG_ERR, + "setsockopt(SO_BROADCAST) disable failure on address %s: %m", + stoa(baddr)); + iface->flags &= ~INT_BCASTOPEN; + broadcast_client_enabled = ISC_FALSE; return ISC_TRUE; #else return ISC_FALSE; @@ -1701,47 +2016,40 @@ } #endif /* OPEN_BCAST_SOCKET */ + +/* + * return the broadcast client flag value + */ +isc_boolean_t +get_broadcastclient_flag(void) +{ + return (broadcast_client_enabled); +} /* * Check to see if the address is a multicast address */ static isc_boolean_t -addr_ismulticast(struct sockaddr_storage *maddr) +addr_ismulticast( + sockaddr_u *maddr + ) { - switch (maddr->ss_family) - { - case AF_INET : - if (!IN_CLASSD(ntohl(((struct sockaddr_in*)maddr)->sin_addr.s_addr))) { - DPRINTF(4, ("multicast address %s not class D\n", stoa(maddr))); - return (ISC_FALSE); - } - else - { - return (ISC_TRUE); - } - - case AF_INET6 : -#ifdef INCLUDE_IPV6_MULTICAST_SUPPORT - if (!IN6_IS_ADDR_MULTICAST(&((struct sockaddr_in6*)maddr)->sin6_addr)) { - DPRINTF(4, ("address %s not IPv6 multicast address\n", stoa(maddr))); - return (ISC_FALSE); - } - else - { - return (ISC_TRUE); - } + isc_boolean_t result; -/* - * If we don't have IPV6 support any IPV6 address is not multicast - */ -#else - return (ISC_FALSE); -#endif +#ifndef INCLUDE_IPV6_MULTICAST_SUPPORT /* - * Never valid + * If we don't have IPV6 support any IPV6 addr is not multicast */ - default: - return (ISC_FALSE); - } + if (IS_IPV6(maddr)) + result = ISC_FALSE; + else +#endif + result = IS_MCAST(maddr); + + if (!result) + DPRINTF(4, ("address %s is not multicast\n", + stoa(maddr))); + + return result; } /* @@ -1750,62 +2058,79 @@ * send the multicast packet. */ void -enable_multicast_if(struct interface *iface, struct sockaddr_storage *maddr) +enable_multicast_if( + struct interface * iface, + sockaddr_u * maddr + ) { #ifdef MCAST - /*u_char*/ TYPEOF_IP_MULTICAST_LOOP off = 0; + TYPEOF_IP_MULTICAST_LOOP off = 0; + + NTP_REQUIRE(AF(maddr) == AF(&iface->sin)); + + switch (AF(&iface->sin)) { - switch (maddr->ss_family) - { case AF_INET: if (setsockopt(iface->fd, IPPROTO_IP, IP_MULTICAST_IF, - (char *)&(((struct sockaddr_in*)&iface->sin)->sin_addr.s_addr), - sizeof(struct in_addr)) == -1) { - netsyslog(LOG_ERR, - "setsockopt IP_MULTICAST_IF failure: %m on socket %d, addr %s for multicast address %s", - iface->fd, stoa(&iface->sin), stoa(maddr)); + (void *)&NSRCADR(&iface->sin), + sizeof(NSRCADR(&iface->sin)))) { + + msyslog(LOG_ERR, + "setsockopt IP_MULTICAST_IF failed: %m on socket %d, addr %s for multicast address %s", + iface->fd, stoa(&iface->sin), + stoa(maddr)); return; } #ifdef IP_MULTICAST_LOOP /* - * Don't send back to itself, but allow it to fail to set it + * Don't send back to itself, but allow failure to set */ - if (setsockopt(iface->fd, IPPROTO_IP, IP_MULTICAST_LOOP, - SETSOCKOPT_ARG_CAST &off, sizeof(off)) == -1) { - netsyslog(LOG_ERR, - "setsockopt IP_MULTICAST_LOOP failure: %m on socket %d, addr %s for multicast address %s", - iface->fd, stoa(&iface->sin), stoa(maddr)); + if (setsockopt(iface->fd, IPPROTO_IP, + IP_MULTICAST_LOOP, + SETSOCKOPT_ARG_CAST &off, + sizeof(off))) { + + msyslog(LOG_ERR, + "setsockopt IP_MULTICAST_LOOP failed: %m on socket %d, addr %s for multicast address %s", + iface->fd, stoa(&iface->sin), + stoa(maddr)); } #endif - DPRINTF(4, ("Added IPv4 multicast interface on socket %d, addr %s for multicast address %s\n", + DPRINTF(4, ("Added IPv4 multicast interface on socket %d, addr %s for multicast address %s\n", iface->fd, stoa(&iface->sin), stoa(maddr))); break; case AF_INET6: #ifdef INCLUDE_IPV6_MULTICAST_SUPPORT - if (setsockopt(iface->fd, IPPROTO_IPV6, IPV6_MULTICAST_IF, - (char *) &iface->scopeid, sizeof(iface->scopeid)) == -1) { - netsyslog(LOG_ERR, - "setsockopt IPV6_MULTICAST_IF failure: %m on socket %d, addr %s, scope %d for multicast address %s", - iface->fd, stoa(&iface->sin), iface->scopeid, - stoa(maddr)); + if (setsockopt(iface->fd, IPPROTO_IPV6, + IPV6_MULTICAST_IF, + (char *)&iface->scopeid, + sizeof(iface->scopeid))) { + + msyslog(LOG_ERR, + "setsockopt IPV6_MULTICAST_IF failed: %m on socket %d, addr %s, scope %d for multicast address %s", + iface->fd, stoa(&iface->sin), + iface->scopeid, stoa(maddr)); return; } #ifdef IPV6_MULTICAST_LOOP /* - * Don't send back to itself, but allow it to fail to set it + * Don't send back to itself, but allow failure to set */ - if (setsockopt(iface->fd, IPPROTO_IPV6, IPV6_MULTICAST_LOOP, - (char *) &off, sizeof(off)) == -1) { - netsyslog(LOG_ERR, - "setsockopt IP_MULTICAST_LOOP failure: %m on socket %d, addr %s for multicast address %s", - iface->fd, stoa(&iface->sin), stoa(maddr)); + if (setsockopt(iface->fd, IPPROTO_IPV6, + IPV6_MULTICAST_LOOP, + (char *) &off, sizeof(off))) { + + msyslog(LOG_ERR, + "setsockopt IP_MULTICAST_LOOP failed: %m on socket %d, addr %s for multicast address %s", + iface->fd, stoa(&iface->sin), + stoa(maddr)); } #endif DPRINTF(4, ("Added IPv6 multicast interface on socket %d, addr %s, scope %d for multicast address %s\n", - iface->fd, stoa(&iface->sin), iface->scopeid, - stoa(maddr))); + iface->fd, stoa(&iface->sin), + iface->scopeid, stoa(maddr))); break; #else return; @@ -1820,34 +2145,42 @@ * The socket is in the inter_list all we need to do is enable * multicasting. It is not this function's job to select the socket */ +#ifdef MCAST static isc_boolean_t -socket_multicast_enable(struct interface *iface, int lscope, struct sockaddr_storage *maddr) +socket_multicast_enable( + struct interface * iface, + int lscope, + sockaddr_u * maddr + ) { + struct ip_mreq mreq; #ifdef INCLUDE_IPV6_MULTICAST_SUPPORT - struct ipv6_mreq mreq6; - struct in6_addr iaddr6; -#endif /* INCLUDE_IPV6_MULTICAST_SUPPORT */ + struct ipv6_mreq mreq6; +#endif - struct ip_mreq mreq; - - if (find_addr_in_list(maddr)) { - DPRINTF(4, ("socket_multicast_enable(%s): already enabled\n", stoa(maddr))); + if (find_addr_in_list(maddr) != NULL) { + DPRINTF(4, ("socket_multicast_enable(%s): already enabled\n", + stoa(maddr))); return ISC_TRUE; } - switch (maddr->ss_family) - { + switch (AF(maddr)) { + case AF_INET: - memset((char *)&mreq, 0, sizeof(mreq)); - mreq.imr_multiaddr = (((struct sockaddr_in*)maddr)->sin_addr); + memset(&mreq, 0, sizeof(mreq)); + mreq.imr_multiaddr = SOCK_ADDR4(maddr); mreq.imr_interface.s_addr = htonl(INADDR_ANY); - if (setsockopt(iface->fd, IPPROTO_IP, IP_ADD_MEMBERSHIP, - (char *)&mreq, sizeof(mreq)) == -1) { - netsyslog(LOG_ERR, - "setsockopt IP_ADD_MEMBERSHIP failure: %m on socket %d, addr %s for %x / %x (%s)", - iface->fd, stoa(&iface->sin), - mreq.imr_multiaddr.s_addr, - mreq.imr_interface.s_addr, stoa(maddr)); + if (setsockopt(iface->fd, + IPPROTO_IP, + IP_ADD_MEMBERSHIP, + (char *)&mreq, + sizeof(mreq))) { + msyslog(LOG_ERR, + "setsockopt IP_ADD_MEMBERSHIP failed: %m on socket %d, addr %s for %x / %x (%s)", + iface->fd, stoa(&iface->sin), + mreq.imr_multiaddr.s_addr, + mreq.imr_interface.s_addr, + stoa(maddr)); return ISC_FALSE; } DPRINTF(4, ("Added IPv4 multicast membership on socket %d, addr %s for %x / %x (%s)\n", @@ -1859,28 +2192,28 @@ case AF_INET6: #ifdef INCLUDE_IPV6_MULTICAST_SUPPORT /* - * Enable reception of multicast packets - * If the address is link-local we can get the interface index - * from the scope id. Don't do this for other types of multicast - * addresses. For now let the kernel figure it out. - */ - memset((char *)&mreq6, 0, sizeof(mreq6)); - iaddr6 = ((struct sockaddr_in6*)maddr)->sin6_addr; - mreq6.ipv6mr_multiaddr = iaddr6; + * Enable reception of multicast packets. + * If the address is link-local we can get the + * interface index from the scope id. Don't do this + * for other types of multicast addresses. For now let + * the kernel figure it out. + */ + memset(&mreq6, 0, sizeof(mreq6)); + mreq6.ipv6mr_multiaddr = SOCK_ADDR6(maddr); mreq6.ipv6mr_interface = lscope; - if (setsockopt(iface->fd, IPPROTO_IPV6, IPV6_JOIN_GROUP, - (char *)&mreq6, sizeof(mreq6)) == -1) { - netsyslog(LOG_ERR, - "setsockopt IPV6_JOIN_GROUP failure: %m on socket %d, addr %s for interface %d(%s)", - iface->fd, stoa(&iface->sin), - mreq6.ipv6mr_interface, stoa(maddr)); + if (setsockopt(iface->fd, IPPROTO_IPV6, + IPV6_JOIN_GROUP, (char *)&mreq6, + sizeof(mreq6))) { + msyslog(LOG_ERR, + "setsockopt IPV6_JOIN_GROUP failed: %m on socket %d, addr %s for interface %d (%s)", + iface->fd, stoa(&iface->sin), + mreq6.ipv6mr_interface, stoa(maddr)); return ISC_FALSE; } DPRINTF(4, ("Added IPv6 multicast group on socket %d, addr %s for interface %d(%s)\n", iface->fd, stoa(&iface->sin), mreq6.ipv6mr_interface, stoa(maddr))); - break; #else return ISC_FALSE; #endif /* INCLUDE_IPV6_MULTICAST_SUPPORT */ @@ -1897,33 +2230,38 @@ * multicasting. It is not this function's job to select the socket */ static isc_boolean_t -socket_multicast_disable(struct interface *iface, struct sockaddr_storage *maddr) +socket_multicast_disable( + struct interface * iface, + sockaddr_u * maddr + ) { #ifdef INCLUDE_IPV6_MULTICAST_SUPPORT struct ipv6_mreq mreq6; - struct in6_addr iaddr6; -#endif /* INCLUDE_IPV6_MULTICAST_SUPPORT */ - +#endif struct ip_mreq mreq; - memset((char *)&mreq, 0, sizeof(mreq)); + + memset(&mreq, 0, sizeof(mreq)); if (find_addr_in_list(maddr) == NULL) { - DPRINTF(4, ("socket_multicast_disable(%s): not enabled\n", stoa(maddr))); + DPRINTF(4, ("socket_multicast_disable(%s): not found\n", + stoa(maddr))); return ISC_TRUE; } - switch (maddr->ss_family) - { + switch (AF(maddr)) { + case AF_INET: - mreq.imr_multiaddr = (((struct sockaddr_in*)&maddr)->sin_addr); - mreq.imr_interface.s_addr = ((struct sockaddr_in*)&iface->sin)->sin_addr.s_addr; - if (setsockopt(iface->fd, IPPROTO_IP, IP_DROP_MEMBERSHIP, - (char *)&mreq, sizeof(mreq)) == -1) { - netsyslog(LOG_ERR, - "setsockopt IP_DROP_MEMBERSHIP failure: %m on socket %d, addr %s for %x / %x (%s)", - iface->fd, stoa(&iface->sin), - mreq.imr_multiaddr.s_addr, - mreq.imr_interface.s_addr, stoa(maddr)); + mreq.imr_multiaddr = SOCK_ADDR4(maddr); + mreq.imr_interface = SOCK_ADDR4(&iface->sin); + if (setsockopt(iface->fd, IPPROTO_IP, + IP_DROP_MEMBERSHIP, (char *)&mreq, + sizeof(mreq))) { + + msyslog(LOG_ERR, + "setsockopt IP_DROP_MEMBERSHIP failed: %m on socket %d, addr %s for %x / %x (%s)", + iface->fd, stoa(&iface->sin), + SRCADR(maddr), SRCADR(&iface->sin), + stoa(maddr)); return ISC_FALSE; } break; @@ -1931,35 +2269,37 @@ #ifdef INCLUDE_IPV6_MULTICAST_SUPPORT /* * Disable reception of multicast packets - * If the address is link-local we can get the interface index - * from the scope id. Don't do this for other types of multicast - * addresses. For now let the kernel figure it out. + * If the address is link-local we can get the + * interface index from the scope id. Don't do this + * for other types of multicast addresses. For now let + * the kernel figure it out. */ - iaddr6 = ((struct sockaddr_in6*)&maddr)->sin6_addr; - mreq6.ipv6mr_multiaddr = iaddr6; + mreq6.ipv6mr_multiaddr = SOCK_ADDR6(maddr); mreq6.ipv6mr_interface = iface->scopeid; - if (setsockopt(iface->fd, IPPROTO_IPV6, IPV6_LEAVE_GROUP, - (char *)&mreq6, sizeof(mreq6)) == -1) { - netsyslog(LOG_ERR, - "setsockopt IPV6_LEAVE_GROUP failure: %m on socket %d, addr %s for %d(%s)", - iface->fd, stoa(&iface->sin), - mreq6.ipv6mr_interface, stoa(maddr)); + if (setsockopt(iface->fd, IPPROTO_IPV6, + IPV6_LEAVE_GROUP, (char *)&mreq6, + sizeof(mreq6))) { + + msyslog(LOG_ERR, + "setsockopt IPV6_LEAVE_GROUP failure: %m on socket %d, addr %s for %d (%s)", + iface->fd, stoa(&iface->sin), + iface->scopeid, stoa(maddr)); return ISC_FALSE; } break; #else return ISC_FALSE; #endif /* INCLUDE_IPV6_MULTICAST_SUPPORT */ - } + iface->num_mcast--; - if (iface->num_mcast <= 0) { - iface->num_mcast = 0; + if (!iface->num_mcast) iface->flags &= ~INT_MCASTOPEN; - } + return ISC_TRUE; } +#endif /* MCAST */ /* * io_setbclient - open the broadcast client sockets @@ -1968,37 +2308,39 @@ io_setbclient(void) { #ifdef OPEN_BCAST_SOCKET - struct interface *interf; - int nif = 0; - isc_boolean_t jstatus; - SOCKET fd; + struct interface * interf; + int nif; + isc_boolean_t jstatus; + SOCKET fd; + nif = 0; set_reuseaddr(1); - for (interf = ISC_LIST_HEAD(inter_list); + for (interf = inter_list; interf != NULL; - interf = ISC_LIST_NEXT(interf, link)) { - if (interf->flags & INT_WILDCARD) - continue; + interf = interf->link) { + + if (interf->flags & (INT_WILDCARD | INT_LOOPBACK)) + continue; /* use only allowed addresses */ - if (interf->ignore_packets == ISC_TRUE) - continue; - /* Only IPv4 addresses are valid for broadcast */ - if (interf->sin.ss_family != AF_INET) + if (interf->ignore_packets) continue; - /* Is this a broadcast address? */ + + /* Need a broadcast-capable interface */ if (!(interf->flags & INT_BROADCAST)) continue; - /* Skip the loopback addresses */ - if (interf->flags & INT_LOOPBACK) - continue; + /* Only IPv4 addresses are valid for broadcast */ + NTP_REQUIRE(IS_IPV4(&interf->sin)); /* Do we already have the broadcast address open? */ if (interf->flags & INT_BCASTOPEN) { - /* account for already open interfaces to aviod misleading warning below */ + /* + * account for already open interfaces to avoid + * misleading warning below + */ nif++; continue; } @@ -2007,41 +2349,40 @@ * Try to open the broadcast address */ interf->family = AF_INET; - interf->bfd = open_socket(&interf->bcast, - INT_BROADCAST, 0, interf); + interf->bfd = open_socket(&interf->bcast, 1, 0, interf); - /* - * If we succeeded then we use it otherwise - * enable the underlying address + /* + * If we succeeded then we use it otherwise enable + * broadcast on the interface address */ - if (interf->bfd == INVALID_SOCKET) { - fd = interf->fd; - } - else { + if (interf->bfd != INVALID_SOCKET) { fd = interf->bfd; + jstatus = ISC_TRUE; + } else { + fd = interf->fd; + jstatus = socket_broadcast_enable(interf, fd, + &interf->sin); } /* Enable Broadcast on socket */ - jstatus = socket_broadcast_enable(interf, fd, &interf->sin); - if (jstatus == ISC_TRUE) - { + if (jstatus) { nif++; - netsyslog(LOG_INFO,"io_setbclient: Opened broadcast client on interface #%d %s, socket: %d", - interf->ifnum, interf->name, fd); + msyslog(LOG_INFO, + "io_setbclient: Opened broadcast client on interface #%d %s", + interf->ifnum, interf->name); interf->addr_refid = addr2refid(&interf->sin); } } set_reuseaddr(0); -#ifdef DEBUG - if (debug) - if (nif > 0) - printf("io_setbclient: Opened broadcast clients\n"); -#endif - if (nif == 0) - netsyslog(LOG_ERR, "Unable to listen for broadcasts, no broadcast interfaces available"); + if (nif > 0) + DPRINTF(1, ("io_setbclient: Opened broadcast clients\n")); + else if (!nif) + msyslog(LOG_ERR, + "Unable to listen for broadcasts, no broadcast interfaces available"); #else - netsyslog(LOG_ERR, "io_setbclient: Broadcast Client disabled by build"); -#endif + msyslog(LOG_ERR, + "io_setbclient: Broadcast Client disabled by build"); +#endif /* OPEN_BCAST_SOCKET */ } /* @@ -2050,19 +2391,19 @@ void io_unsetbclient(void) { - struct interface *interf; - isc_boolean_t lstatus; + struct interface *interf; - for (interf = ISC_LIST_HEAD(inter_list); - interf != NULL; - interf = ISC_LIST_NEXT(interf, link)) + for (interf = inter_list; + NULL != interf; + interf = interf->link) { - if (interf->flags & INT_WILDCARD) - continue; + if (interf->flags & INT_WILDCARD) + continue; if (!(interf->flags & INT_BCASTOPEN)) - continue; - lstatus = socket_broadcast_disable(interf, &interf->sin); + continue; + + socket_broadcast_disable(interf, &interf->sin); } } @@ -2071,7 +2412,7 @@ */ void io_multicast_add( - struct sockaddr_storage addr + sockaddr_u *addr ) { #ifdef MCAST @@ -2084,14 +2425,14 @@ /* * Check to see if this is a multicast address */ - if (addr_ismulticast(&addr) == ISC_FALSE) + if (!addr_ismulticast(addr)) return; /* If we already have it we can just return */ - if (find_flagged_addr_in_list(&addr, INT_MCASTOPEN|INT_MCASTIF) != NULL) - { - netsyslog(LOG_INFO, "Duplicate request found for multicast address %s", - stoa(&addr)); + if (NULL != find_flagged_addr_in_list(addr, INT_MCASTOPEN)) { + msyslog(LOG_INFO, + "Duplicate request found for multicast address %s", + stoa(addr)); return; } @@ -2101,77 +2442,73 @@ /* * Open a new socket for the multicast address */ - interface->sin.ss_family = addr.ss_family; - interface->family = addr.ss_family; + interface->family = + AF(&interface->sin) = + AF(&interface->mask) = AF(addr); + SET_PORT(&interface->sin, NTP_PORT); + SET_ONESMASK(&interface->mask); + + switch(AF(addr)) { - switch(addr.ss_family) { case AF_INET: - memcpy(&(((struct sockaddr_in *)&interface->sin)->sin_addr), - &(((struct sockaddr_in*)&addr)->sin_addr), - sizeof(struct in_addr)); - ((struct sockaddr_in*)&interface->sin)->sin_port = htons(NTP_PORT); - memset(&((struct sockaddr_in*)&interface->mask)->sin_addr.s_addr, 0xff, sizeof(struct in_addr)); + NSRCADR(&interface->sin) = NSRCADR(addr); break; + case AF_INET6: #ifdef INCLUDE_IPV6_MULTICAST_SUPPORT - memcpy(&(((struct sockaddr_in6 *)&interface->sin)->sin6_addr), - &((struct sockaddr_in6*)&addr)->sin6_addr, - sizeof(struct in6_addr)); - ((struct sockaddr_in6*)&interface->sin)->sin6_port = htons(NTP_PORT); -#ifdef ISC_PLATFORM_HAVESCOPEID - ((struct sockaddr_in6*)&interface->sin)->sin6_scope_id = ((struct sockaddr_in6*)&addr)->sin6_scope_id; -#endif - memset(&((struct sockaddr_in6*)&interface->mask)->sin6_addr.s6_addr, 0xff, sizeof(struct in6_addr)); -#endif - iface = findlocalcastinterface(&addr, INT_MULTICAST); - if (iface) { -# ifdef ISC_PLATFORM_HAVESCOPEID - lscope = ((struct sockaddr_in6*)&iface->sin)->sin6_scope_id; -# endif - DPRINTF(4, ("Found interface #%d %s, scope: %d for address %s\n", iface->ifnum, iface->name, lscope, stoa(&addr))); - } - break; + SET_ADDR6N(&interface->sin, SOCK_ADDR6(addr)); + lscope = SCOPE(addr); + SET_SCOPE(&interface->sin, lscope); +#endif + iface = findlocalcastinterface(addr); + if (iface != NULL) + DPRINTF(4, ("Found interface #%d %s, scope %d for address %s\n", + iface->ifnum, iface->name, lscope, + stoa(addr))); } set_reuseaddr(1); interface->bfd = INVALID_SOCKET; - interface->fd = open_socket(&interface->sin, - INT_MULTICAST, 0, interface); + interface->fd = open_socket(&interface->sin, INT_MULTICAST, 0, + interface); - if (interface->fd != INVALID_SOCKET) - { + if (interface->fd != INVALID_SOCKET) { interface->bfd = INVALID_SOCKET; interface->ignore_packets = ISC_FALSE; interface->flags |= INT_MCASTIF; - (void) strncpy(interface->name, "multicast", + strncpy(interface->name, "multicast", sizeof(interface->name)); - ((struct sockaddr_in*)&interface->mask)->sin_addr.s_addr = - htonl(~(u_int32)0); DPRINT_INTERFACE(2, (interface, "multicast add ", "\n")); - /* socket_multicast_enable() will add this address to the addresslist */ + /* + * socket_multicast_enable() will add this address to + * the addresslist + */ add_interface(interface); - list_if_listening(interface, htons(NTP_PORT)); - } - else - { - delete_interface(interface); /* re-use existing interface */ - interface = NULL; - if (addr.ss_family == AF_INET) + list_if_listening(interface); + } else { + /* bind failed, re-use wildcard interface */ + delete_interface(interface); + + if (IS_IPV4(addr)) interface = wildipv4; - else if (addr.ss_family == AF_INET6) + else if (IS_IPV6(addr)) interface = wildipv6; + else + interface = NULL; if (interface != NULL) { /* HACK ! -- stuff in an address */ - interface->bcast = addr; - netsyslog(LOG_ERR, - "...multicast address %s using wildcard interface #%d %s", - stoa(&addr), interface->ifnum, interface->name); + /* because we don't bind addr? DH */ + interface->bcast = *addr; + msyslog(LOG_ERR, + "multicast address %s using wildcard interface #%d %s", + stoa(addr), interface->ifnum, + interface->name); } else { - netsyslog(LOG_ERR, - "No multicast socket available to use for address %s", - stoa(&addr)); + msyslog(LOG_ERR, + "No multicast socket available to use for address %s", + stoa(addr)); return; } } @@ -2179,110 +2516,77 @@ /* * For the case where we can't use a separate socket */ - interface = findlocalcastinterface(&addr, INT_MULTICAST); + interface = findlocalcastinterface(addr); /* * If we don't have a valid socket, just return */ - if (!interface) - { - netsyslog(LOG_ERR, - "Cannot add multicast address %s: Cannot find slot", - stoa(&addr)); + if (NULL == interface) { + msyslog(LOG_ERR, + "Can not add multicast address %s: no multicast interface found", + stoa(addr)); return; } #endif - { - isc_boolean_t jstatus; - jstatus = socket_multicast_enable(interface, lscope, &addr); - - if (jstatus == ISC_TRUE) - netsyslog(LOG_INFO, "Added Multicast Listener %s on interface #%d %s\n", stoa(&addr), interface->ifnum, interface->name); - else - netsyslog(LOG_ERR, "Failed to add Multicast Listener %s\n", stoa(&addr)); - } + if (socket_multicast_enable(interface, lscope, addr)) + msyslog(LOG_INFO, + "Added Multicast Listener %s on interface #%d %s", + stoa(addr), interface->ifnum, interface->name); + else + msyslog(LOG_ERR, "Failed to add Multicast Listener %s", + stoa(addr)); #else /* MCAST */ - netsyslog(LOG_ERR, - "Cannot add multicast address %s: no Multicast support", - stoa(&addr)); + msyslog(LOG_ERR, + "Can not add multicast address %s: no multicast support", + stoa(addr)); #endif /* MCAST */ return; } + /* * io_multicast_del() - delete multicast group address */ void io_multicast_del( - struct sockaddr_storage addr + sockaddr_u * addr ) { #ifdef MCAST - struct interface *interface; - isc_boolean_t lstatus; + struct interface *iface; /* * Check to see if this is a multicast address */ - if (addr_ismulticast(&addr) == ISC_FALSE) - { - netsyslog(LOG_ERR, - "invalid multicast address %s", stoa(&addr)); + if (!addr_ismulticast(addr)) { + msyslog(LOG_ERR, "invalid multicast address %s", + stoa(addr)); return; } - switch (addr.ss_family) - { - case AF_INET : - /* - * Disable reception of multicast packets - */ - interface = find_flagged_addr_in_list(&addr, INT_MCASTOPEN); - while ( interface != NULL) { - lstatus = socket_multicast_disable(interface, &addr); - interface = find_flagged_addr_in_list(&addr, INT_MCASTOPEN); - } - break; - -#ifdef INCLUDE_IPV6_MULTICAST_SUPPORT - case AF_INET6 : - /* - * Disable reception of multicast packets - */ - for (interface = ISC_LIST_HEAD(inter_list); - interface != NULL; - interface = ISC_LIST_NEXT(interface, link)) - { - if (interface->flags & INT_WILDCARD) - continue; - - /* Be sure it's the correct family */ - if (interface->sin.ss_family != AF_INET6) - continue; - if (!(interface->flags & INT_MCASTOPEN)) - continue; - if (!(interface->fd < 0)) - continue; - if (!SOCKCMP(&addr, &interface->sin)) - continue; - lstatus = socket_multicast_disable(interface, &addr); - } - break; -#endif /* INCLUDE_IPV6_MULTICAST_SUPPORT */ - - }/* switch */ + /* + * Disable reception of multicast packets + */ + while ((iface = find_flagged_addr_in_list(addr, INT_MCASTOPEN)) + != NULL) + socket_multicast_disable(iface, addr); - delete_addr_from_list(&addr); + delete_addr_from_list(addr); #else /* not MCAST */ - netsyslog(LOG_ERR, "this function requires multicast kernel"); + msyslog(LOG_ERR, + "Can not delete multicast address %s: no multicast support", + stoa(addr)); #endif /* not MCAST */ } + /* * init_nonblocking_io() - set up descriptor to be non blocking */ -static void init_nonblocking_io(SOCKET fd) +static void init_nonblocking_io( + SOCKET fd + ) { /* * set non-blocking, @@ -2298,47 +2602,39 @@ #endif #if defined(O_NONBLOCK) /* POSIX */ - if (fcntl(fd, F_SETFL, O_NONBLOCK) < 0) - { - netsyslog(LOG_ERR, "fcntl(O_NONBLOCK) fails on fd #%d: %m", - fd); + if (fcntl(fd, F_SETFL, O_NONBLOCK) < 0) { + msyslog(LOG_ERR, + "fcntl(O_NONBLOCK) fails on fd #%d: %m", fd); exit(1); - /*NOTREACHED*/ } #elif defined(FNDELAY) - if (fcntl(fd, F_SETFL, FNDELAY) < 0) - { - netsyslog(LOG_ERR, "fcntl(FNDELAY) fails on fd #%d: %m", + if (fcntl(fd, F_SETFL, FNDELAY) < 0) { + msyslog(LOG_ERR, "fcntl(FNDELAY) fails on fd #%d: %m", fd); exit(1); - /*NOTREACHED*/ } #elif defined(O_NDELAY) /* generally the same as FNDELAY */ - if (fcntl(fd, F_SETFL, O_NDELAY) < 0) - { - netsyslog(LOG_ERR, "fcntl(O_NDELAY) fails on fd #%d: %m", + if (fcntl(fd, F_SETFL, O_NDELAY) < 0) { + msyslog(LOG_ERR, "fcntl(O_NDELAY) fails on fd #%d: %m", fd); exit(1); - /*NOTREACHED*/ } #elif defined(FIONBIO) { int on = 1; - if (ioctl(fd,FIONBIO,&on) < 0) - { - netsyslog(LOG_ERR, "ioctl(FIONBIO) fails on fd #%d: %m", + + if (ioctl(fd, FIONBIO, &on) < 0) { + msyslog(LOG_ERR, + "ioctl(FIONBIO) fails on fd #%d: %m", fd); exit(1); - /*NOTREACHED*/ } } #elif defined(FIOSNBIO) - if (ioctl(fd,FIOSNBIO,&on) < 0) - { - netsyslog(LOG_ERR, "ioctl(FIOSNBIO) fails on fd #%d: %m", - fd); + if (ioctl(fd, FIOSNBIO, &on) < 0) { + msyslog(LOG_ERR, + "ioctl(FIOSNBIO) fails on fd #%d: %m", fd); exit(1); - /*NOTREACHED*/ } #else # include "Bletch: Need non-blocking I/O!" @@ -2351,48 +2647,47 @@ static SOCKET open_socket( - struct sockaddr_storage *addr, - int flags, - int turn_off_reuse, - struct interface *interf + sockaddr_u * addr, + int bcast, + int turn_off_reuse, + struct interface * interf ) { - int errval; - SOCKET fd; + SOCKET fd; + int errval; + char scopetext[16]; /* * int is OK for REUSEADR per * http://www.kohala.com/start/mcast.api.txt */ - int on = 1; - int off = 0; - -#if defined(IPTOS_LOWDELAY) && defined(IPPROTO_IP) && defined(IP_TOS) - int tos; -#endif /* IPTOS_LOWDELAY && IPPROTO_IP && IP_TOS */ + int on = 1; + int off = 0; - if ((addr->ss_family == AF_INET6) && (isc_net_probeipv6() != ISC_R_SUCCESS)) - return (INVALID_SOCKET); + if (IS_IPV6(addr) && !ipv6_works) + return INVALID_SOCKET; /* create a datagram (UDP) socket */ - fd = socket(addr->ss_family, SOCK_DGRAM, 0); + fd = socket(AF(addr), SOCK_DGRAM, 0); if (INVALID_SOCKET == fd) { #ifndef SYS_WINNT errval = errno; #else errval = WSAGetLastError(); #endif - netsyslog(LOG_ERR, - "socket(AF_INET%s, SOCK_DGRAM, 0) failed on address %s: %m", - (addr->ss_family == AF_INET6) ? "6" : "", - stoa(addr)); + msyslog(LOG_ERR, + "socket(AF_INET%s, SOCK_DGRAM, 0) failed on address %s: %m", + IS_IPV6(addr) ? "6" : "", stoa(addr)); if (errval == EPROTONOSUPPORT || errval == EAFNOSUPPORT || errval == EPFNOSUPPORT) return (INVALID_SOCKET); - msyslog(LOG_ERR, "unexpected error code %d (not PROTONOSUPPORT|AFNOSUPPORT|FPNOSUPPORT) - exiting", errval); + + errno = errval; + msyslog(LOG_ERR, + "unexpected socket() error %m code %d (not EPROTONOSUPPORT nor EAFNOSUPPORT nor EPFNOSUPPORT) - exiting", + errno); exit(1); - /*NOTREACHED*/ } #ifdef SYS_WINNT @@ -2414,17 +2709,17 @@ if (isc_win32os_versioncheck(5, 1, 0, 0) < 0) /* before 5.1 */ #endif if (setsockopt(fd, SOL_SOCKET, SO_REUSEADDR, - (char *)(turn_off_reuse - ? &off - : &on), + (char *)((turn_off_reuse) + ? &off + : &on), sizeof(on))) { - netsyslog(LOG_ERR, "setsockopt SO_REUSEADDR %s" - " fails for address %s: %m", - turn_off_reuse - ? "off" - : "on", - stoa(addr)); + msyslog(LOG_ERR, + "setsockopt SO_REUSEADDR %s fails for address %s: %m", + (turn_off_reuse) + ? "off" + : "on", + stoa(addr)); closesocket(fd); return INVALID_SOCKET; } @@ -2440,38 +2735,36 @@ /* * IPv4 specific options go here */ - if (addr->ss_family == AF_INET) { -#if defined(IPTOS_LOWDELAY) && defined(IPPROTO_IP) && defined(IP_TOS) - /* set IP_TOS to minimize packet delay */ - tos = IPTOS_LOWDELAY; - if (setsockopt(fd, IPPROTO_IP, IP_TOS, (char *) &tos, sizeof(tos)) < 0) - { - netsyslog(LOG_ERR, "setsockopt IPTOS_LOWDELAY on fails on address %s: %m", - stoa(addr)); - } -#endif /* IPTOS_LOWDELAY && IPPROTO_IP && IP_TOS */ + if (IS_IPV4(addr)) { +#if defined(HAVE_IPTOS_SUPPORT) + if (setsockopt(fd, IPPROTO_IP, IP_TOS, (char *)&qos, + sizeof(qos))) + msyslog(LOG_ERR, + "setsockopt IP_TOS (%02x) fails on address %s: %m", + qos, stoa(addr)); +#endif /* HAVE_IPTOS_SUPPORT */ + if (bcast) + socket_broadcast_enable(interf, fd, addr); } /* * IPv6 specific options go here */ - if (addr->ss_family == AF_INET6) { + if (IS_IPV6(addr)) { #if defined(IPV6_V6ONLY) - if (setsockopt(fd, IPPROTO_IPV6, IPV6_V6ONLY, - (char*)&on, sizeof(on))) - { - netsyslog(LOG_ERR, "setsockopt IPV6_V6ONLY on fails on address %s: %m", + if (isc_net_probe_ipv6only() == ISC_R_SUCCESS + && setsockopt(fd, IPPROTO_IPV6, IPV6_V6ONLY, + (char*)&on, sizeof(on))) + msyslog(LOG_ERR, + "setsockopt IPV6_V6ONLY on fails on address %s: %m", stoa(addr)); - } #endif /* IPV6_V6ONLY */ #if defined(IPV6_BINDV6ONLY) - if (setsockopt(fd, IPPROTO_IPV6, IPV6_BINDV6ONLY, - (char*)&on, sizeof(on))) - { - netsyslog(LOG_ERR, - "setsockopt IPV6_BINDV6ONLY on fails on address %s: %m", - stoa(addr)); - } + if (setsockopt(fd, IPPROTO_IPV6, IPV6_BINDV6ONLY, + (char*)&on, sizeof(on))) + msyslog(LOG_ERR, + "setsockopt IPV6_BINDV6ONLY on fails on address %s: %m", + stoa(addr)); #endif /* IPV6_BINDV6ONLY */ } @@ -2481,25 +2774,18 @@ * addresses if a wildcard address already bound * to the port and SO_REUSEADDR is not set */ - if (!is_wildcard_addr(addr)) { - set_wildcard_reuse(addr->ss_family, 1); - } + if (!is_wildcard_addr(addr)) + set_wildcard_reuse(AF(addr), 1); #endif /* * bind the local address. */ - errval = bind(fd, (struct sockaddr *)addr, SOCKLEN(addr)); + errval = bind(fd, &addr->sa, SOCKLEN(addr)); #ifdef OS_NEEDS_REUSEADDR_FOR_IFADDRBIND - /* - * some OSes don't allow binding to more specific - * addresses if a wildcard address already bound - * to the port and REUSE_ADDR is not set - */ - if (!is_wildcard_addr(addr)) { - set_wildcard_reuse(addr->ss_family, 0); - } + if (!is_wildcard_addr(addr)) + set_wildcard_reuse(AF(addr), 0); #endif if (errval < 0) { @@ -2510,28 +2796,19 @@ #ifdef DEBUG || debug > 1 #endif - ) { - if (addr->ss_family == AF_INET) - netsyslog(LOG_ERR, - "bind() fd %d, family AF_INET, port %d, addr %s, in_classd=%d flags=0x%x fails: %m", - fd, (int)ntohs(((struct sockaddr_in*)addr)->sin_port), - stoa(addr), - IN_CLASSD(ntohl(((struct sockaddr_in*)addr)->sin_addr.s_addr)), - flags); -#ifdef INCLUDE_IPV6_SUPPORT - else if (addr->ss_family == AF_INET6) - netsyslog(LOG_ERR, - "bind() fd %d, family AF_INET6, port %d, scope %d, addr %s, mcast=%d flags=0x%x fails: %m", - fd, (int)ntohs(((struct sockaddr_in6*)addr)->sin6_port), -# ifdef ISC_PLATFORM_HAVESCOPEID - ((struct sockaddr_in6*)addr)->sin6_scope_id -# else - -1 -# endif - , stoa(addr), - IN6_IS_ADDR_MULTICAST(&((struct sockaddr_in6*)addr)->sin6_addr), - flags); -#endif + ) { + if (SCOPE(addr)) + snprintf(scopetext, sizeof(scopetext), + "%%%d", SCOPE(addr)); + else + scopetext[0] = 0; + + msyslog(LOG_ERR, + "bind(%d) AF_INET%s %s%s#%d%s flags 0x%x failed: %m", + fd, IS_IPV6(addr) ? "6" : "", + stoa(addr), scopetext, SRCPORT(addr), + IS_MCAST(addr) ? " (multicast)" : "", + interf->flags); } closesocket(fd); @@ -2543,25 +2820,17 @@ { if (setsockopt(fd, SOL_SOCKET, SO_TIMESTAMP, (char*)&on, sizeof(on))) - { - netsyslog(LOG_DEBUG, - "setsockopt SO_TIMESTAMP on fails on address %s: %m", - stoa(addr)); - } -#ifdef DEBUG + msyslog(LOG_DEBUG, + "setsockopt SO_TIMESTAMP on fails on address %s: %m", + stoa(addr)); else - { - DPRINTF(4, ("setsockopt SO_TIMESTAMP enabled on fd %d address %s\n", fd, stoa(addr))); - } -#endif + DPRINTF(4, ("setsockopt SO_TIMESTAMP enabled on fd %d address %s\n", + fd, stoa(addr))); } #endif - DPRINTF(4, ("bind() fd %d, family %d, port %d, addr %s, flags=0x%x\n", - fd, - addr->ss_family, - (int)ntohs(((struct sockaddr_in*)addr)->sin_port), - stoa(addr), - interf->flags)); + DPRINTF(4, ("bind(%d) AF_INET%s, addr %s%%%d#%d, flags 0x%x\n", + fd, IS_IPV6(addr) ? "6" : "", stoa(addr), + SCOPE(addr), SRCPORT(addr), interf->flags)); init_nonblocking_io(fd); @@ -2580,8 +2849,7 @@ /* * Add the socket to the completion port */ - if (io_completion_port_add_socket(fd, interf)) - { + if (io_completion_port_add_socket(fd, interf)) { msyslog(LOG_ERR, "unable to set up io completion port - EXITING"); exit(1); } @@ -2597,216 +2865,98 @@ */ void sendpkt( - struct sockaddr_storage *dest, + sockaddr_u *dest, struct interface *inter, int ttl, struct pkt *pkt, int len ) { - int cc, slot; - - /* - * Send error caches. Empty slots have port == 0 - * Set ERRORCACHESIZE to 0 to disable - */ - struct cache { - u_short port; - struct in_addr addr; - }; - -#ifdef INCLUDE_IPV6_SUPPORT - struct cache6 { - u_short port; - struct in6_addr addr; - }; -#endif /* INCLUDE_IPV6_SUPPORT */ + int cc; + if (NULL == inter) { + /* + * unbound peer - drop request and wait for better + * network conditions + */ + DPRINTF(2, ("%ssendpkt(dst=%s, ttl=%d, len=%d): no interface - IGNORED\n", + (ttl > 0) ? "\tMCAST\t***** " : "", + stoa(dest), ttl, len)); + return; + } -#ifndef ERRORCACHESIZE -#define ERRORCACHESIZE 8 -#endif -#if ERRORCACHESIZE > 0 - static struct cache badaddrs[ERRORCACHESIZE]; -#ifdef INCLUDE_IPV6_SUPPORT - static struct cache6 badaddrs6[ERRORCACHESIZE]; -#endif /* INCLUDE_IPV6_SUPPORT */ -#else -#define badaddrs ((struct cache *)0) /* Only used in empty loops! */ -#ifdef INCLUDE_IPV6_SUPPORT -#define badaddrs6 ((struct cache6 *)0) /* Only used in empty loops! */ -#endif /* INCLUDE_IPV6_SUPPORT */ -#endif -#ifdef DEBUG - if (debug > 1) - { - if (inter != NULL) - { - printf("%ssendpkt(fd=%d dst=%s, src=%s, ttl=%d, len=%d)\n", - (ttl > 0) ? "\tMCAST\t***** " : "", - inter->fd, stoa(dest), - stoa(&inter->sin), ttl, len); - } - else - { - printf("%ssendpkt(dst=%s, ttl=%d, len=%d): no interface - IGNORED\n", - (ttl > 0) ? "\tMCAST\t***** " : "", - stoa(dest), - ttl, len); - } - } -#endif + DPRINTF(2, ("%ssendpkt(%d, dst=%s, src=%s, ttl=%d, len=%d)\n", + (ttl > 0) ? "\tMCAST\t***** " : "", + inter->fd, stoa(dest), stoa(&inter->sin), + ttl, len)); - if (inter == NULL) /* unbound peer - drop request and wait for better network conditions */ - return; - #ifdef MCAST - /* * for the moment we use the bcast option to set multicast ttl */ if (ttl > 0 && ttl != inter->last_ttl) { - /* * set the multicast ttl for outgoing packets */ - int rtc; + int rtc; + u_char cttl; + u_int uttl; - switch (inter->sin.ss_family) { + switch (AF(&inter->sin)) { case AF_INET : - { - u_char mttl = (u_char) ttl; - - rtc = setsockopt(inter->fd, IPPROTO_IP, IP_MULTICAST_TTL, - (const void *) &mttl, sizeof(mttl)); + cttl = (u_char)ttl; + rtc = setsockopt(inter->fd, IPPROTO_IP, + IP_MULTICAST_TTL, + (void *)&cttl, sizeof(cttl)); break; - } #ifdef INCLUDE_IPV6_SUPPORT case AF_INET6 : - { - u_int ittl = (u_char) ttl; - - rtc = setsockopt(inter->fd, IPPROTO_IPV6, IPV6_MULTICAST_HOPS, - (const void *) &ittl, sizeof(ittl)); + uttl = (u_int)ttl; + rtc = setsockopt(inter->fd, IPPROTO_IPV6, + IPV6_MULTICAST_HOPS, + (void *)&uttl, sizeof(uttl)); break; - } - #endif /* INCLUDE_IPV6_SUPPORT */ + default: /* just NOP if not supported */ + DPRINTF(1, ("sendpkt unknown AF %d", + AF(&inter->sin))); rtc = 0; - break; } - if (rtc != 0) { - netsyslog(LOG_ERR, "setsockopt IP_MULTICAST_TTL/IPV6_MULTICAST_HOPS fails on address %s: %m", - stoa(&inter->sin)); - } - else + if (!rtc) inter->last_ttl = ttl; + else + msyslog(LOG_ERR, + "setsockopt IP_MULTICAST_TTL/IPV6_MULTICAST_HOPS fails on address %s: %m", + stoa(&inter->sin)); } #endif /* MCAST */ - for (slot = ERRORCACHESIZE; --slot >= 0; ) - if(dest->ss_family == AF_INET) { - if (badaddrs[slot].port == ((struct sockaddr_in*)dest)->sin_port && - badaddrs[slot].addr.s_addr == ((struct sockaddr_in*)dest)->sin_addr.s_addr) - break; - } -#ifdef INCLUDE_IPV6_SUPPORT - else if (dest->ss_family == AF_INET6) { - if (badaddrs6[slot].port == ((struct sockaddr_in6*)dest)->sin6_port && - badaddrs6[slot].addr.s6_addr == ((struct sockaddr_in6*)dest)->sin6_addr.s6_addr) - break; - } -#endif /* INCLUDE_IPV6_SUPPORT */ - #if defined(HAVE_IO_COMPLETION_PORT) - cc = io_completion_port_sendto(inter, pkt, len, dest); - if (cc != ERROR_SUCCESS) + cc = io_completion_port_sendto(inter, pkt, len, dest); + if (cc != ERROR_SUCCESS) { #else #ifdef SIM - cc = srvr_rply(&ntp_node, dest, inter, pkt); + cc = simulate_server(dest, inter, pkt); #else /* SIM */ - cc = sendto(inter->fd, (char *)pkt, (unsigned int)len, 0, (struct sockaddr *)dest, - SOCKLEN(dest)); + cc = sendto(inter->fd, (char *)pkt, (unsigned int)len, 0, + (struct sockaddr *)dest, SOCKLEN(dest)); #endif /* SIM */ - if (cc == -1) + if (cc == -1) { #endif - { inter->notsent++; packets_notsent++; - -#if defined(HAVE_IO_COMPLETION_PORT) - if (cc != WSAEWOULDBLOCK && cc != WSAENOBUFS && slot < 0) -#else - if (errno != EWOULDBLOCK && errno != ENOBUFS && slot < 0) -#endif - { - /* - * Remember this, if there's an empty slot - */ - switch (dest->ss_family) { - - case AF_INET : - - for (slot = ERRORCACHESIZE; --slot >= 0; ) - if (badaddrs[slot].port == 0) - { - badaddrs[slot].port = SRCPORT(dest); - badaddrs[slot].addr = ((struct sockaddr_in*)dest)->sin_addr; - break; - } - break; - -#ifdef INCLUDE_IPV6_SUPPORT - case AF_INET6 : - - for (slot = ERRORCACHESIZE; --slot >= 0; ) - if (badaddrs6[slot].port == 0) - { - badaddrs6[slot].port = SRCPORT(dest); - badaddrs6[slot].addr = ((struct sockaddr_in6*)dest)->sin6_addr; - break; - } - break; -#endif /* INCLUDE_IPV6_SUPPORT */ - default: /* don't care if not supported */ - break; - } - - netsyslog(LOG_ERR, "sendto(%s) (fd=%d): %m", - stoa(dest), inter->fd); - } - } - else - { + } else { inter->sent++; packets_sent++; - /* - * He's not bad any more - */ - if (slot >= 0) - { - netsyslog(LOG_INFO, "Connection re-established to %s", stoa(dest)); - switch (dest->ss_family) { - case AF_INET : - badaddrs[slot].port = 0; - break; -#ifdef INCLUDE_IPV6_SUPPORT - case AF_INET6 : - badaddrs6[slot].port = 0; - break; -#endif /* INCLUDE_IPV6_SUPPORT */ - default: /* don't care if not supported */ - break; - } - } } } + #if !defined(HAVE_IO_COMPLETION_PORT) /* * fdbits - generate ascii representation of fd_set (FAU debug support) @@ -2821,10 +2971,9 @@ static char buffer[256]; char * buf = buffer; - count = (count < 256) ? count : 255; + count = min(count, 255); - while (count >= 0) - { + while (count >= 0) { *buf++ = FD_ISSET(count, set) ? '#' : '-'; count--; } @@ -2847,8 +2996,7 @@ rb = get_free_recv_buffer(); - if (rb == NULL) - { + if (NULL == rb) { /* * No buffer space available - just drop the packet */ @@ -2860,15 +3008,14 @@ } i = (rp->datalen == 0 - || rp->datalen > sizeof(rb->recv_space)) - ? sizeof(rb->recv_space) : rp->datalen; + || rp->datalen > sizeof(rb->recv_space)) + ? sizeof(rb->recv_space) + : rp->datalen; buflen = read(fd, (char *)&rb->recv_space, (unsigned)i); - if (buflen < 0) - { - if (errno != EINTR && errno != EAGAIN) { - netsyslog(LOG_ERR, "clock read fd %d: %m", fd); - } + if (buflen < 0) { + if (errno != EINTR && errno != EAGAIN) + msyslog(LOG_ERR, "clock read fd %d: %m", fd); freerecvbuf(rb); return (buflen); } @@ -2884,13 +3031,11 @@ rb->recv_time = ts; rb->receiver = rp->clock_recv; - if (rp->io_input) - { + if (rp->io_input) { /* * have direct input routine for refclocks */ - if (rp->io_input(rb) == 0) - { + if (rp->io_input(rb) == 0) { /* * data was consumed - nothing to pass up * into block input machine @@ -2907,12 +3052,17 @@ return (buflen); } + #ifdef HAVE_TIMESTAMP /* * extract timestamps from control message buffer */ static l_fp - fetch_timestamp(struct recvbuf *rb, struct msghdr *msghdr, l_fp ts) +fetch_timestamp( + struct recvbuf * rb, + struct msghdr * msghdr, + l_fp ts + ) { #ifdef USE_TIMESTAMP_CMSG struct cmsghdr *cmsghdr; @@ -2923,33 +3073,36 @@ { case SCM_TIMESTAMP: { - struct timeval *tvp = (struct timeval *)CMSG_DATA(cmsghdr); + struct timeval *tvp; double dtemp; l_fp nts; - DPRINTF(4, ("fetch_timestamp: system network time stamp: %ld.%06ld\n", tvp->tv_sec, tvp->tv_usec)); - nts.l_i = tvp->tv_sec + JAN_1970; - dtemp = tvp->tv_usec / 1e6; - /* fuzz lower bits not covered by precision */ - if (sys_precision != 0) - dtemp += (ntp_random() / FRAC - .5) / (1 << - -sys_precision); - - nts.l_uf = (u_int32)(dtemp*FRAC); + tvp = (struct timeval *)CMSG_DATA(cmsghdr); + DPRINTF(4, ("fetch_timestamp: system network time stamp: %ld.%06ld\n", + tvp->tv_sec, tvp->tv_usec)); + nts.l_i = tvp->tv_sec + JAN_1970; + dtemp = (tvp->tv_usec + + (ntp_random() * 2. / FRAC)) / 1e6; + nts.l_uf = (u_int32)(dtemp * FRAC); #ifdef DEBUG_TIMING { - l_fp dts = ts; + l_fp dts; + + dts = ts; L_SUB(&dts, &nts); - collect_timing(rb, "input processing delay", 1, &dts); - DPRINTF(4, ("fetch_timestamp: timestamp delta: %s (incl. prec fuzz)\n", lfptoa(&dts, 9))); + collect_timing(rb, + "input processing delay", + 1, &dts); + DPRINTF(4, ("fetch_timestamp: timestamp delta: %s (incl. prec fuzz)\n", + lfptoa(&dts, 9))); } #endif ts = nts; /* network time stamp */ break; } default: - DPRINTF(4, ("fetch_timestamp: skipping control message 0x%x\n", cmsghdr->cmsg_type)); - break; + DPRINTF(4, ("fetch_timestamp: skipping control message 0x%x\n", + cmsghdr->cmsg_type)); } cmsghdr = CMSG_NXTHDR(msghdr, cmsghdr); } @@ -2958,13 +3111,18 @@ } #endif + /* * Routine to read the network NTP packets for a specific interface * Return the number of bytes read. That way we know if we should * read it again or go on to the next one if no bytes returned */ static inline int -read_network_packet(SOCKET fd, struct interface *itf, l_fp ts) +read_network_packet( + SOCKET fd, + struct interface * itf, + l_fp ts + ) { GETSOCKNAME_SOCKLEN_TYPE fromlen; int buflen; @@ -2972,7 +3130,7 @@ #ifdef HAVE_TIMESTAMP struct msghdr msghdr; struct iovec iovec; - char control[TIMESTAMP_CTLMSGBUF_SIZE]; /* pick up control messages */ + char control[TIMESTAMP_CTLMSGBUF_SIZE]; #endif /* @@ -2983,41 +3141,39 @@ */ rb = get_free_recv_buffer(); - - if (rb == NULL || itf->ignore_packets == ISC_TRUE) - { + if (NULL == rb || itf->ignore_packets) { char buf[RX_BUFF_SIZE]; - struct sockaddr_storage from; + sockaddr_u from; + if (rb != NULL) freerecvbuf(rb); fromlen = sizeof(from); buflen = recvfrom(fd, buf, sizeof(buf), 0, - (struct sockaddr*)&from, &fromlen); + &from.sa, &fromlen); DPRINTF(4, ("%s on (%lu) fd=%d from %s\n", - (itf->ignore_packets == ISC_TRUE) ? "ignore" : "drop", - free_recvbuffs(), fd, - stoa(&from))); - if (itf->ignore_packets == ISC_TRUE) + (itf->ignore_packets) + ? "ignore" + : "drop", + free_recvbuffs(), fd, stoa(&from))); + if (itf->ignore_packets) packets_ignored++; else packets_dropped++; return (buflen); } - fromlen = sizeof(struct sockaddr_storage); + fromlen = sizeof(rb->recv_srcadr); #ifndef HAVE_TIMESTAMP - rb->recv_length = recvfrom(fd, - (char *)&rb->recv_space, - sizeof(rb->recv_space), 0, - (struct sockaddr *)&rb->recv_srcadr, - &fromlen); + rb->recv_length = recvfrom(fd, (char *)&rb->recv_space, + sizeof(rb->recv_space), 0, + &rb->recv_srcadr.sa, &fromlen); #else - iovec.iov_base = (void *)&rb->recv_space; + iovec.iov_base = &rb->recv_space; iovec.iov_len = sizeof(rb->recv_space); - msghdr.msg_name = (void *)&rb->recv_srcadr; - msghdr.msg_namelen = sizeof(rb->recv_srcadr); + msghdr.msg_name = &rb->recv_srcadr; + msghdr.msg_namelen = fromlen; msghdr.msg_iov = &iovec; msghdr.msg_iovlen = 1; msghdr.msg_control = (void *)&control; @@ -3029,37 +3185,24 @@ buflen = rb->recv_length; if (buflen == 0 || (buflen == -1 && - (errno==EWOULDBLOCK + (EWOULDBLOCK == errno #ifdef EAGAIN - || errno==EAGAIN + || EAGAIN == errno #endif - ))) { + ))) { freerecvbuf(rb); return (buflen); - } - else if (buflen < 0) - { - netsyslog(LOG_ERR, "recvfrom(%s) fd=%d: %m", - stoa(&rb->recv_srcadr), fd); - DPRINTF(5, ("read_network_packet: fd=%d dropped (bad recvfrom)\n", fd)); + } else if (buflen < 0) { + msyslog(LOG_ERR, "recvfrom(%s) fd=%d: %m", + stoa(&rb->recv_srcadr), fd); + DPRINTF(5, ("read_network_packet: fd=%d dropped (bad recvfrom)\n", + fd)); freerecvbuf(rb); return (buflen); } -#ifdef DEBUG - if (debug > 2) { - if(rb->recv_srcadr.ss_family == AF_INET) - printf("read_network_packet: fd=%d length %d from %08lx %s\n", - fd, buflen, - (u_long)ntohl(((struct sockaddr_in*)&rb->recv_srcadr)->sin_addr.s_addr) & - 0x00000000ffffffff, - stoa(&rb->recv_srcadr)); - else - printf("read_network_packet: fd=%d length %d from %s\n", - fd, buflen, - stoa(&rb->recv_srcadr)); - } -#endif + DPRINTF(3, ("read_network_packet: fd=%d length %d from %s\n", + fd, buflen, stoa(&rb->recv_srcadr))); /* * Got one. Mark how and when it got here, @@ -3068,7 +3211,8 @@ rb->dstadr = itf; rb->fd = fd; #ifdef HAVE_TIMESTAMP - ts = fetch_timestamp(rb, &msghdr, ts); /* pick up a network time stamp if possible */ + /* pick up a network time stamp if possible */ + ts = fetch_timestamp(rb, &msghdr, ts); #endif rb->recv_time = ts; rb->receiver = receive; @@ -3080,6 +3224,7 @@ return (buflen); } + /* * input_handler - receive packets asynchronously */ @@ -3088,15 +3233,14 @@ l_fp *cts ) { - int buflen; int n; int doing; SOCKET fd; struct timeval tvzero; - l_fp ts; /* Timestamp at BOselect() gob */ + l_fp ts; /* Timestamp at BOselect() gob */ #ifdef DEBUG_TIMING - l_fp ts_e; /* Timestamp at EOselect() gob */ + l_fp ts_e; /* Timestamp at EOselect() gob */ #endif fd_set fds; int select_count = 0; @@ -3109,7 +3253,7 @@ /* * If we have something to do, freeze a timestamp. - * See below for the other cases (nothing (left) to do or error) + * See below for the other cases (nothing left to do or error) */ ts = *cts; @@ -3120,28 +3264,31 @@ fds = activefds; tvzero.tv_sec = tvzero.tv_usec = 0; - n = select(maxactivefd+1, &fds, (fd_set *)0, (fd_set *)0, &tvzero); + n = select(maxactivefd + 1, &fds, (fd_set *)0, (fd_set *)0, + &tvzero); /* * If there are no packets waiting just return */ - if (n < 0) - { + if (n < 0) { int err = errno; /* * extended FAU debugging output */ if (err != EINTR) - netsyslog(LOG_ERR, - "select(%d, %s, 0L, 0L, &0.0) error: %m", - maxactivefd+1, - fdbits(maxactivefd, &activefds)); + msyslog(LOG_ERR, + "select(%d, %s, 0L, 0L, &0.0) error: %m", + maxactivefd + 1, + fdbits(maxactivefd, &activefds)); if (err == EBADF) { int j, b; fds = activefds; for (j = 0; j <= maxactivefd; j++) - if ((FD_ISSET(j, &fds) && (read(j, &b, 0) == -1))) - netsyslog(LOG_ERR, "Bad file descriptor %d", j); + if ((FD_ISSET(j, &fds) + && (read(j, &b, 0) == -1))) + msyslog(LOG_ERR, + "Bad file descriptor %d", + j); } return; } @@ -3155,55 +3302,47 @@ * Check out the reference clocks first, if any */ - if (refio != NULL) - { + if (refio != NULL) { register struct refclockio *rp; - for (rp = refio; rp != NULL; rp = rp->next) - { + for (rp = refio; rp != NULL; rp = rp->next) { fd = rp->fd; if (FD_ISSET(fd, &fds)) - { do { ++select_count; - buflen = read_refclock_packet(fd, rp, ts); + buflen = read_refclock_packet( + fd, rp, ts); } while (buflen > 0); - - } /* End if (FD_ISSET(fd, &fds)) */ - } /* End for (rp = refio; rp != 0 && n > 0; rp = rp->next) */ - } /* End if (refio != 0) */ - + } + } #endif /* REFCLOCK */ /* * Loop through the interfaces looking for data to read. */ - for (interface = ISC_LIST_TAIL(inter_list); + for (interface = inter_list; interface != NULL; - interface = ISC_LIST_PREV(interface, link)) - { - for (doing = 0; (doing < 2); doing++) - { - if (doing == 0) - { + interface = interface->link) { + + for (doing = 0; (doing < 2); doing++) { + if (!doing) fd = interface->fd; - } - else - { + else { if (!(interface->flags & INT_BCASTOPEN)) - break; + break; fd = interface->bfd; } - if (fd < 0) continue; + if (fd < 0) + continue; if (FD_ISSET(fd, &fds)) - { do { ++select_count; - buflen = read_network_packet(fd, interface, ts); + buflen = read_network_packet( + fd, interface, + ts); } while (buflen > 0); - } - /* Check more interfaces */ + /* Check more interfaces */ } } @@ -3211,16 +3350,14 @@ /* * scan list of asyncio readers - currently only used for routing sockets */ - asyncio_reader = ISC_LIST_TAIL(asyncio_reader_list); + asyncio_reader = asyncio_reader_list; - while (asyncio_reader != NULL) - { - struct asyncio_reader *next = ISC_LIST_PREV(asyncio_reader, link); + while (asyncio_reader != NULL) { if (FD_ISSET(asyncio_reader->fd, &fds)) { ++select_count; - asyncio_reader->receiver(asyncio_reader); + (asyncio_reader->receiver)(asyncio_reader); } - asyncio_reader = next; + asyncio_reader = asyncio_reader->link; } #endif /* HAS_ROUTING_SOCKET */ @@ -3232,15 +3369,14 @@ * If nothing to do, just return. * If an error occurred, complain and return. */ - if (select_count == 0) /* We really had nothing to do */ - { + if (select_count == 0) { /* We really had nothing to do */ #ifdef DEBUG if (debug) - netsyslog(LOG_DEBUG, "input_handler: select() returned 0"); + msyslog(LOG_DEBUG, "input_handler: select() returned 0"); #endif return; } - /* We've done our work */ + /* We've done our work */ #ifdef DEBUG_TIMING get_systime(&ts_e); /* @@ -3251,12 +3387,13 @@ L_SUB(&ts_e, &ts); collect_timing(NULL, "input handler", 1, &ts_e); if (debug > 3) - netsyslog(LOG_INFO, "input_handler: Processed a gob of fd's in %s msec", lfptoms(&ts_e, 6)); + msyslog(LOG_DEBUG, + "input_handler: Processed a gob of fd's in %s msec", + lfptoms(&ts_e, 6)); #endif /* just bail. */ return; } - #endif /* @@ -3264,31 +3401,29 @@ */ struct interface * findinterface( - struct sockaddr_storage *addr + sockaddr_u *addr ) { - struct interface *interface; + struct interface *iface; - interface = findlocalinterface(addr, INT_WILDCARD); + iface = findlocalinterface(addr, INT_WILDCARD, 0); - if (interface == NULL) - { + if (NULL == iface) { DPRINTF(4, ("Found no interface for address %s - returning wildcard\n", stoa(addr))); - return (ANY_INTERFACE_CHOOSE(addr)); - } - else - { + iface = ANY_INTERFACE_CHOOSE(addr); + } else DPRINTF(4, ("Found interface #%d %s for address %s\n", - interface->ifnum, interface->name, stoa(addr))); + iface->ifnum, iface->name, stoa(addr))); - return (interface); - } + return iface; } /* - * findlocalinterface - find local interface index corresponding to address + * findlocalinterface - find local interface corresponding to addr, + * which does not have any of flags set. If bast is nonzero, addr is + * a broadcast address. * * This code attempts to find the local sending address for an outgoing * address by connecting a new socket to destinationaddress:NTP_PORT @@ -3302,244 +3437,254 @@ */ static struct interface * findlocalinterface( - struct sockaddr_storage *addr, - int flags + sockaddr_u * addr, + int flags, + int bcast ) { - SOCKET s; - int rtn; - struct sockaddr_storage saddr; - GETSOCKNAME_SOCKLEN_TYPE saddrlen = SOCKLEN(addr); - struct interface *iface; + GETSOCKNAME_SOCKLEN_TYPE sockaddrlen; + struct interface * iface; + sockaddr_u saddr; + SOCKET s; + int rtn; + int on; DPRINTF(4, ("Finding interface for addr %s in list of addresses\n", stoa(addr))); - - memset(&saddr, 0, sizeof(saddr)); - saddr.ss_family = addr->ss_family; - if(addr->ss_family == AF_INET) { - memcpy(&((struct sockaddr_in*)&saddr)->sin_addr, &((struct sockaddr_in*)addr)->sin_addr, sizeof(struct in_addr)); - ((struct sockaddr_in*)&saddr)->sin_port = htons(NTP_PORT); - } -#ifdef INCLUDE_IPV6_SUPPORT - else if(addr->ss_family == AF_INET6) { - memcpy(&((struct sockaddr_in6*)&saddr)->sin6_addr, &((struct sockaddr_in6*)addr)->sin6_addr, sizeof(struct in6_addr)); - ((struct sockaddr_in6*)&saddr)->sin6_port = htons(NTP_PORT); -# ifdef ISC_PLATFORM_HAVESCOPEID - ((struct sockaddr_in6*)&saddr)->sin6_scope_id = ((struct sockaddr_in6*)addr)->sin6_scope_id; -# endif - } -#endif - s = socket(addr->ss_family, SOCK_DGRAM, 0); - if (s == INVALID_SOCKET) + s = socket(AF(addr), SOCK_DGRAM, 0); + if (INVALID_SOCKET == s) return NULL; - rtn = connect(s, (struct sockaddr *)&saddr, SOCKLEN(&saddr)); -#ifndef SYS_WINNT - if (rtn < 0) -#else - if (rtn == SOCKET_ERROR) -#endif - { + /* + * If we are looking for broadcast interface we need to set this + * socket to allow broadcast + */ + if (bcast) { + on = 1; + setsockopt(s, SOL_SOCKET, SO_BROADCAST, + (char *)&on, sizeof(on)); + } + + rtn = connect(s, &addr->sa, SOCKLEN(addr)); + if (SOCKET_ERROR == rtn) { closesocket(s); return NULL; } - rtn = getsockname(s, (struct sockaddr *)&saddr, &saddrlen); + sockaddrlen = sizeof(saddr); + rtn = getsockname(s, &saddr.sa, &sockaddrlen); closesocket(s); -#ifndef SYS_WINNT - if (rtn < 0) -#else - if (rtn == SOCKET_ERROR) -#endif + + if (SOCKET_ERROR == rtn) return NULL; - DPRINTF(4, ("findlocalinterface: kernel maps %s to %s\n", stoa(addr), stoa(&saddr))); + DPRINTF(4, ("findlocalinterface: kernel maps %s to %s\n", + stoa(addr), stoa(&saddr))); iface = getinterface(&saddr, flags); - /* Don't both with ignore interfaces */ - if (iface != NULL && iface->ignore_packets == ISC_TRUE) - { - return NULL; - } - else - { - return iface; - } + /* + * if we didn't find an exact match on saddr check for an + * interface on the same subnet as saddr. This handles the + * case of the address suggested by the kernel being + * excluded by the user's -I and -L options to ntpd, when + * another address is enabled on the same subnet. + * See http://bugs.ntp.org/1184 for more detail. + */ + if (NULL == iface || iface->ignore_packets) + iface = getsamenetinterface(&saddr, flags); + + /* Don't use an interface which will ignore replies */ + if (iface != NULL && iface->ignore_packets) + iface = NULL; + + return iface; } + /* * fetch an interface structure the matches the - * address is has the given flags not set + * address and has the given flags NOT set */ static struct interface * -getinterface(struct sockaddr_storage *addr, int flags) +getinterface( + sockaddr_u * addr, + int flags + ) { - struct interface *interface = find_addr_in_list(addr); + struct interface *iface; + + iface = find_addr_in_list(addr); - if (interface != NULL && interface->flags & flags) - { - return NULL; - } - else - { - return interface; - } + if (iface != NULL && (iface->flags & flags)) + iface = NULL; + + return iface; +} + + +/* + * fetch an interface structure with a local address on the same subnet + * as addr which has the given flags NOT set + */ +static struct interface * +getsamenetinterface( + sockaddr_u * addr, + int flags + ) +{ + struct interface *iface; + + iface = find_samenet_addr_in_list(addr); + + if (iface != NULL && (iface->flags & flags)) + iface = NULL; + + return iface; } + /* - * findlocalcastinterface - find local *cast interface index corresponding to address - * depending on the flags passed + * findlocalcastinterface - find local *cast interface for addr */ static struct interface * findlocalcastinterface( - struct sockaddr_storage *addr, int flags + sockaddr_u * addr ) { - struct interface *interface; - struct interface *nif = NULL; + struct interface * iface; + struct interface * nif; #ifdef INCLUDE_IPV6_MULTICAST_SUPPORT - isc_boolean_t want_linklocal; + isc_boolean_t want_linklocal; #endif + NTP_REQUIRE(addr_ismulticast(addr)); + /* * see how kernel maps the mcast address */ - nif = findlocalinterface(addr, 0); + nif = findlocalinterface(addr, 0, 0); - if (nif) { - DPRINTF(2, ("findlocalcastinterface: kernel recommends interface #%d %s\n", nif->ifnum, nif->name)); + if (nif != NULL && !nif->ignore_packets) { + DPRINTF(2, ("findlocalcastinterface: kernel recommends interface #%d %s for %s\n", + nif->ifnum, nif->name, stoa(addr))); return nif; } #ifdef INCLUDE_IPV6_MULTICAST_SUPPORT - want_linklocal = ISC_FALSE; - if (addr_ismulticast(addr) && flags == INT_MULTICAST) - { - if (IN6_IS_ADDR_MC_LINKLOCAL(&((struct sockaddr_in6*)addr)->sin6_addr)) - { - want_linklocal = ISC_TRUE; - } - else if (IN6_IS_ADDR_MC_SITELOCAL(&((struct sockaddr_in6*)addr)->sin6_addr)) - { - want_linklocal = ISC_TRUE; - } - } + want_linklocal = (IN6_IS_ADDR_MC_LINKLOCAL(PSOCK_ADDR6(addr)) + || IN6_IS_ADDR_MC_SITELOCAL(PSOCK_ADDR6(addr))); #endif - for (interface = ISC_LIST_HEAD(inter_list); - interface != NULL; - interface = ISC_LIST_NEXT(interface, link)) + for (iface = inter_list; + iface != NULL; + iface = iface->link) { /* use only allowed addresses */ - if (interface->ignore_packets == ISC_TRUE) + if (iface->ignore_packets) continue; /* Skip the loopback and wildcard addresses */ - if (interface->flags & (INT_LOOPBACK|INT_WILDCARD)) + if (iface->flags & (INT_LOOPBACK | INT_WILDCARD)) continue; /* Skip if different family */ - if(interface->sin.ss_family != addr->ss_family) + if (AF(&iface->sin) != AF(addr)) continue; - /* Is this it one of these based on flags? */ - if (!(interface->flags & flags)) + /* Is it multicast capable? */ + if (!(iface->flags & INT_MULTICAST)) continue; - /* for IPv6 multicast check the address for linklocal */ #ifdef INCLUDE_IPV6_MULTICAST_SUPPORT - if (flags == INT_MULTICAST && interface->sin.ss_family == AF_INET6 && - (IN6_IS_ADDR_LINKLOCAL(&((struct sockaddr_in6*)&interface->sin)->sin6_addr)) - && want_linklocal == ISC_TRUE) - { - nif = interface; + if (want_linklocal && IS_IPV6(&iface->sin) && + IN6_IS_ADDR_LINKLOCAL(PSOCK_ADDR6(&iface->sin))) { + nif = iface; break; } - /* If we want a linklocal address and this isn't it, skip */\ - if (want_linklocal == ISC_TRUE) + /* If we want a linklocal address, skip */ + if (want_linklocal) continue; #endif - /* Otherwise just look for the flag */ - if((interface->flags & flags)) - { - nif = interface; - break; - } - } -#ifdef DEBUG - if (debug > 2) - { - if (nif) - printf("findlocalcastinterface: found interface #%d %s\n", nif->ifnum, nif->name); - else - printf("findlocalcastinterface: no interface found for %s flags 0x%x\n", stoa(addr), flags); - } -#endif - return (nif); + nif = iface; + break; + } /* for loop over interfaces */ + + if (nif != NULL) + DPRINTF(3, ("findlocalcastinterface: found interface #%d %s for %s\n", + nif->ifnum, nif->name, stoa(addr))); + else + DPRINTF(3, ("findlocalcastinterface: no interface found for %s\n", + stoa(addr))); + return nif; } + /* * findbcastinter - find broadcast interface corresponding to address */ struct interface * findbcastinter( - struct sockaddr_storage *addr + sockaddr_u *addr ) { #if !defined(MPE) && (defined(SIOCGIFCONF) || defined(SYS_WINNT)) - struct interface *interface; + struct interface *iface; DPRINTF(4, ("Finding broadcast/multicast interface for addr %s in list of addresses\n", stoa(addr))); - interface = findlocalinterface(addr, INT_LOOPBACK|INT_WILDCARD); - - if (interface != NULL) - { - DPRINTF(4, ("Found bcast-/mcast- interface index #%d %s\n", interface->ifnum, interface->name)); - return interface; + iface = findlocalinterface(addr, INT_LOOPBACK | INT_WILDCARD, + 1); + if (iface != NULL) { + DPRINTF(4, ("Easily found bcast-/mcast- interface index #%d %s\n", + iface->ifnum, iface->name)); + return iface; } - /* plan B - try to find something reasonable in our lists in case kernel lookup doesn't help */ - - for (interface = ISC_LIST_HEAD(inter_list); - interface != NULL; - interface = ISC_LIST_NEXT(interface, link)) + /* + * plan B - try to find something reasonable in our lists in + * case kernel lookup doesn't help + */ + for (iface = inter_list; + iface != NULL; + iface = iface->link) { - if (interface->flags & INT_WILDCARD) - continue; + if (iface->flags & INT_WILDCARD) + continue; /* Don't bother with ignored interfaces */ - if (interface->ignore_packets == ISC_TRUE) + if (iface->ignore_packets) continue; /* * First look if this is the correct family */ - if(interface->sin.ss_family != addr->ss_family) - continue; + if(AF(&iface->sin) != AF(addr)) + continue; /* Skip the loopback addresses */ - if (interface->flags & INT_LOOPBACK) + if (iface->flags & INT_LOOPBACK) continue; /* - * If we are looking to match a multicast address grab it. + * If we are looking to match a multicast address and + * this interface is one... */ - if (addr_ismulticast(addr) == ISC_TRUE && interface->flags & INT_MULTICAST) - { + if (addr_ismulticast(addr) + && (iface->flags & INT_MULTICAST)) { #ifdef INCLUDE_IPV6_SUPPORT - if(addr->ss_family == AF_INET6) { - /* Only use link-local address for link-scope mcast */ - if(IN6_IS_ADDR_MC_LINKLOCAL(&((struct sockaddr_in6*)addr)->sin6_addr) && - !IN6_IS_ADDR_LINKLOCAL(&((struct sockaddr_in6*)&interface->sin)->sin6_addr)) { - continue; - } - } + /* + * ...it is the winner unless we're looking for + * an interface to use for link-local multicast + * and its address is not link-local. + */ + if (IS_IPV6(addr) + && IN6_IS_ADDR_MC_LINKLOCAL(PSOCK_ADDR6(addr)) + && !IN6_IS_ADDR_LINKLOCAL(PSOCK_ADDR6(&iface->sin))) + continue; #endif break; } @@ -3550,34 +3695,33 @@ * address or the network portion of the IP address. * Sloppy. */ - if(addr->ss_family == AF_INET) { - if (SOCKCMP(&interface->bcast, addr)) { + if (IS_IPV4(addr)) { + if (SOCK_EQ(&iface->bcast, addr)) break; - } - if ((NSRCADR(&interface->sin) & - NSRCADR(&interface->mask)) == (NSRCADR(addr) & - NSRCADR(&interface->mask))) + + if ((NSRCADR(&iface->sin) & NSRCADR(&iface->mask)) + == (NSRCADR(addr) & NSRCADR(&iface->mask))) break; } #ifdef INCLUDE_IPV6_SUPPORT - else if(addr->ss_family == AF_INET6) { - if (SOCKCMP(&interface->bcast, addr)) { + else if(IS_IPV6(addr)) { + if (SOCK_EQ(&iface->bcast, addr)) break; - } - if (SOCKCMP(netof(&interface->sin), netof(addr))) { + + if (SOCK_EQ(netof(&iface->sin), netof(addr))) break; - } } #endif } #endif /* SIOCGIFCONF */ - if (interface == NULL) { - DPRINTF(4, ("No bcast interface found for %s\n", stoa(addr))); - return ANY_INTERFACE_CHOOSE(addr); - } else { - DPRINTF(4, ("Found bcast-/mcast- interface index #%d %s\n", interface->ifnum, interface->name)); - return interface; - } + if (NULL == iface) { + DPRINTF(4, ("No bcast interface found for %s\n", + stoa(addr))); + iface = ANY_INTERFACE_CHOOSE(addr); + } else + DPRINTF(4, ("Found bcast-/mcast- interface index #%d %s\n", + iface->ifnum, iface->name)); + return iface; } @@ -3610,21 +3754,20 @@ ) { BLOCKIO(); + /* * Stuff the I/O structure in the list and mark the descriptor - * in use. There is a harmless (I hope) race condition here. + * in use. There is a harmless (I hope) race condition here. */ rio->next = refio; # ifdef HAVE_SIGNALED_IO - if (init_clock_sig(rio)) - { + if (init_clock_sig(rio)) { UNBLOCKIO(); return 0; } # elif defined(HAVE_IO_COMPLETION_PORT) - if (io_completion_port_add_clock_io(rio)) - { + if (io_completion_port_add_clock_io(rio)) { UNBLOCKIO(); return 0; } @@ -3635,7 +3778,7 @@ */ refio = rio; - /* + /* * register fd */ add_fd_to_list(rio->fd, FD_TYPE_FILE); @@ -3652,26 +3795,23 @@ struct refclockio *rio ) { + register struct refclockio *rp; + BLOCKIO(); + /* * Remove structure from the list */ if (refio == rio) - { refio = rio->next; - } - else - { - register struct refclockio *rp; - + else { for (rp = refio; rp != NULL; rp = rp->next) - if (rp->next == rio) - { - rp->next = rio->next; - break; - } + if (rp->next == rio) { + rp->next = rio->next; + break; + } - if (rp == NULL) { + if (NULL == rp) { UNBLOCKIO(); return; } @@ -3689,230 +3829,352 @@ * On NT a SOCKET is an unsigned int so we cannot possibly keep it in * an array. So we use one of the ISC_LIST functions to hold the * socket value and use that when we want to enumerate it. + * + * This routine is called by the forked intres child process to close + * all open sockets. On Windows there's no need as intres runs in + * the same process as a thread. */ +#ifndef SYS_WINNT void kill_asyncio(int startfd) { - vsock_t *lsock; - vsock_t *next; - BLOCKIO(); - lsock = ISC_LIST_HEAD(fd_list); - while (lsock != NULL) { - /* - * careful here - list is being dismantled while - * we scan it - setting next here insures that - * we are able to correctly scan the list - */ - next = ISC_LIST_NEXT(lsock, link); - /* - * will remove socket from list - */ - close_and_delete_fd_from_list(lsock->fd); - lsock = next; - } + /* + * In the child process we do not maintain activefds and + * maxactivefd. Zeroing maxactivefd disables code which + * maintains it in close_and_delete_fd_from_list(). + */ + maxactivefd = 0; + + while (fd_list != NULL) + close_and_delete_fd_from_list(fd_list->fd); UNBLOCKIO(); } +#endif /* !SYS_WINNT */ /* * Add and delete functions for the list of open sockets */ static void -add_fd_to_list(SOCKET fd, enum desc_type type) { - vsock_t *lsock = (vsock_t *)emalloc(sizeof(vsock_t)); +add_fd_to_list( + SOCKET fd, + enum desc_type type + ) +{ + vsock_t *lsock = emalloc(sizeof(*lsock)); + lsock->fd = fd; lsock->type = type; - ISC_LIST_APPEND(fd_list, lsock, link); + LINK_SLIST(fd_list, lsock, link); /* * I/O Completion Ports don't care about the select and FD_SET */ #ifndef HAVE_IO_COMPLETION_PORT if (fd < 0 || fd >= FD_SETSIZE) { - msyslog(LOG_ERR, "Too many sockets in use, FD_SETSIZE %d exceeded", + msyslog(LOG_ERR, + "Too many sockets in use, FD_SETSIZE %d exceeded", FD_SETSIZE); exit(1); } /* * keep activefds in sync */ - if (fd > maxactivefd) - maxactivefd = fd; - FD_SET( (u_int)fd, &activefds); + maxactivefd = max(fd, maxactivefd); + + FD_SET(fd, &activefds); #endif } static void -close_and_delete_fd_from_list(SOCKET fd) { +close_and_delete_fd_from_list( + SOCKET fd + ) +{ + vsock_t *lsock; - vsock_t *next; - vsock_t *lsock = ISC_LIST_HEAD(fd_list); + UNLINK_EXPR_SLIST(lsock, fd_list, fd == + UNLINK_EXPR_SLIST_CURRENT()->fd, link, vsock_t); - while(lsock != NULL) { - next = ISC_LIST_NEXT(lsock, link); - if(lsock->fd == fd) { - ISC_LIST_DEQUEUE_TYPE(fd_list, lsock, link, vsock_t); + if (lsock != NULL) { + switch (lsock->type) { + case FD_TYPE_SOCKET: + closesocket(lsock->fd); + break; - switch (lsock->type) { - case FD_TYPE_SOCKET: -#ifdef SYS_WINNT - closesocket(lsock->fd); - break; -#endif - case FD_TYPE_FILE: - (void) close(lsock->fd); - break; - default: - msyslog(LOG_ERR, "internal error - illegal descriptor type %d - EXITING", (int)lsock->type); - exit(1); - } + case FD_TYPE_FILE: + close(lsock->fd); + break; - free(lsock); - /* - * I/O Completion Ports don't care about select and fd_set - */ + default: + msyslog(LOG_ERR, + "internal error - illegal descriptor type %d - EXITING", + (int)lsock->type); + exit(1); + } + + free(lsock); + /* + * I/O Completion Ports don't care about select and fd_set + */ #ifndef HAVE_IO_COMPLETION_PORT - /* - * remove from activefds - */ - FD_CLR( (u_int) fd, &activefds); - - if (fd == maxactivefd) { - int i, newmax = 0; - for (i = 0; i < maxactivefd; i++) - if (FD_ISSET(i, &activefds)) - newmax = i; - maxactivefd = newmax; - } -#endif - break; + /* + * remove from activefds + */ + FD_CLR(fd, &activefds); + + if (fd == maxactivefd && maxactivefd) { + int i; + NTP_INSIST(maxactivefd - 1 < FD_SETSIZE); + for (i = maxactivefd - 1; i >= 0; i--) + if (FD_ISSET(i, &activefds)) { + maxactivefd = i; + break; + } + NTP_INSIST(fd != maxactivefd); } - lsock = next; +#endif } } static void -add_addr_to_list(struct sockaddr_storage *addr, struct interface *interface){ +add_addr_to_list( + sockaddr_u *addr, + struct interface *interface + ) +{ + remaddr_t *laddr; + #ifdef DEBUG if (find_addr_in_list(addr) == NULL) { #endif /* not there yet - add to list */ - remaddr_t *laddr = (remaddr_t *)emalloc(sizeof(remaddr_t)); - memcpy(&laddr->addr, addr, sizeof(struct sockaddr_storage)); + laddr = emalloc(sizeof(*laddr)); + memcpy(&laddr->addr, addr, sizeof(laddr->addr)); laddr->interface = interface; - ISC_LIST_APPEND(remoteaddr_list, laddr, link); + LINK_SLIST(remoteaddr_list, laddr, link); DPRINTF(4, ("Added addr %s to list of addresses\n", stoa(addr))); #ifdef DEBUG - } else { + } else DPRINTF(4, ("WARNING: Attempt to add duplicate addr %s to address list\n", stoa(addr))); - } #endif } -static void -delete_addr_from_list(struct sockaddr_storage *addr) { - remaddr_t *next; - remaddr_t *laddr = ISC_LIST_HEAD(remoteaddr_list); +static void +delete_addr_from_list( + sockaddr_u *addr + ) +{ + remaddr_t *unlinked; + + UNLINK_EXPR_SLIST(unlinked, remoteaddr_list, SOCK_EQ(addr, + &(UNLINK_EXPR_SLIST_CURRENT()->addr)), link, remaddr_t); - while(laddr != NULL) { - next = ISC_LIST_NEXT(laddr, link); - if(SOCKCMP(&laddr->addr, addr)) { - ISC_LIST_DEQUEUE_TYPE(remoteaddr_list, laddr, link, remaddr_t); - DPRINTF(4, ("Deleted addr %s from list of addresses\n", - stoa(addr))); - free(laddr); - break; - } - laddr = next; + if (unlinked != NULL) { + DPRINTF(4, ("Deleted addr %s from list of addresses\n", + stoa(addr))); + free(unlinked); } } + static void -delete_interface_from_list(struct interface *iface) { - remaddr_t *next; - remaddr_t *laddr = ISC_LIST_HEAD(remoteaddr_list); +delete_interface_from_list( + struct interface *iface + ) +{ + remaddr_t *unlinked; - while(laddr != NULL) { - next = ISC_LIST_NEXT(laddr, link); - if (laddr->interface == iface) { - ISC_LIST_DEQUEUE_TYPE(remoteaddr_list, laddr, link, remaddr_t); + do { + UNLINK_EXPR_SLIST(unlinked, remoteaddr_list, iface == + UNLINK_EXPR_SLIST_CURRENT()->interface, link, + remaddr_t); + + if (unlinked != NULL) { DPRINTF(4, ("Deleted addr %s for interface #%d %s from list of addresses\n", - stoa(&laddr->addr), iface->ifnum, iface->name)); - free(laddr); + stoa(&unlinked->addr), iface->ifnum, + iface->name)); + if (addr_ismulticast(&unlinked->addr)) + /* find a new interface to use */ + io_multicast_add(&unlinked->addr); + free(unlinked); } - laddr = next; - } + } while (unlinked != NULL); } -static struct interface * -find_addr_in_list(struct sockaddr_storage *addr) { - remaddr_t *next; - remaddr_t *laddr = ISC_LIST_HEAD(remoteaddr_list); +static struct interface * +find_addr_in_list( + sockaddr_u *addr + ) +{ + remaddr_t *entry; + DPRINTF(4, ("Searching for addr %s in list of addresses - ", stoa(addr))); - while(laddr != NULL) { - next = ISC_LIST_NEXT(laddr, link); - if(SOCKCMP(&laddr->addr, addr)) { + for (entry = remoteaddr_list; + entry != NULL; + entry = entry->link) + if (SOCK_EQ(&entry->addr, addr)) { DPRINTF(4, ("FOUND\n")); - return laddr->interface; + return entry->interface; } - else - laddr = next; - } + DPRINTF(4, ("NOT FOUND\n")); - return NULL; /* Not found */ + return NULL; +} + +static inline isc_boolean_t +same_network_v4( + struct sockaddr_in *addr1, + struct sockaddr_in *mask, + struct sockaddr_in *addr2 + ) +{ + return (addr1->sin_addr.s_addr & mask->sin_addr.s_addr) + == (addr2->sin_addr.s_addr & mask->sin_addr.s_addr); +} + +#ifdef INCLUDE_IPV6_SUPPORT +static inline isc_boolean_t +same_network_v6( + struct sockaddr_in6 *addr1, + struct sockaddr_in6 *mask, + struct sockaddr_in6 *addr2 + ) +{ + int i; + + for (i = 0; + i < sizeof(addr1->sin6_addr.s6_addr) / + sizeof(addr1->sin6_addr.s6_addr[0]); + i++) + + if ((addr1->sin6_addr.s6_addr[i] & + mask->sin6_addr.s6_addr[i]) + != + (addr2->sin6_addr.s6_addr[i] & + mask->sin6_addr.s6_addr[i])) + + return ISC_FALSE; + + return ISC_TRUE; +} +#endif /* INCLUDE_IPV6_SUPPORT */ + + +static isc_boolean_t +same_network( + sockaddr_u *a1, + sockaddr_u *mask, + sockaddr_u *a2 + ) +{ + isc_boolean_t sn; + + if (AF(a1) != AF(a2)) + sn = ISC_FALSE; + else if (IS_IPV4(a1)) + sn = same_network_v4(&a1->sa4, &mask->sa4, &a2->sa4); +#ifdef INCLUDE_IPV6_SUPPORT + else if (IS_IPV6(a1)) + sn = same_network_v6(&a1->sa6, &mask->sa6, &a2->sa6); +#endif + else + sn = ISC_FALSE; + + return sn; } /* - * Find the given address with the associated flag in the list + * Find an address in the list on the same network as addr which is not + * addr. */ static struct interface * -find_flagged_addr_in_list(struct sockaddr_storage *addr, int flag) { +find_samenet_addr_in_list( + sockaddr_u *addr + ) +{ + remaddr_t *entry; - remaddr_t *next; - remaddr_t *laddr = ISC_LIST_HEAD(remoteaddr_list); - DPRINTF(4, ("Finding addr %s in list of addresses\n", + DPRINTF(4, ("Searching for addr with same subnet as %s in list of addresses - ", stoa(addr))); - while(laddr != NULL) { - next = ISC_LIST_NEXT(laddr, link); - if(SOCKCMP(&laddr->addr, addr) && (laddr->interface->flags & flag)) { - return laddr->interface; - break; + for (entry = remoteaddr_list; + entry != NULL; + entry = entry->link) + + if (!SOCK_EQ(addr, &entry->addr) + && same_network(&entry->addr, + &entry->interface->mask, + addr)) { + DPRINTF(4, ("FOUND\n")); + return entry->interface; } - else - laddr = next; - } - return NULL; /* Not found */ + + DPRINTF(4, ("NOT FOUND\n")); + return NULL; } -#ifdef HAS_ROUTING_SOCKET -#include -#ifndef UPDATE_GRACE -#define UPDATE_GRACE 2 /* wait UPDATE_GRACE seconds before scanning */ -#endif +/* + * Find the given address with the all given flags set in the list + */ +static struct interface * +find_flagged_addr_in_list( + sockaddr_u * addr, + int flags + ) +{ + remaddr_t *entry; + + DPRINTF(4, ("Finding addr %s with flags %d in list: ", + stoa(addr), flags)); + + for (entry = remoteaddr_list; + entry != NULL; + entry = entry->link) + + if (SOCK_EQ(&entry->addr, addr) + && (entry->interface->flags & flags) == flags) { + + DPRINTF(4, ("FOUND\n")); + return entry->interface; + } + + DPRINTF(4, ("NOT FOUND\n")); + return NULL; +} + + +#ifdef HAS_ROUTING_SOCKET +# ifndef UPDATE_GRACE +# define UPDATE_GRACE 2 /* wait UPDATE_GRACE seconds before scanning */ +# endif static void process_routing_msgs(struct asyncio_reader *reader) { char buffer[5120]; - char *p = buffer; - - int cnt; + int cnt, msg_type; +#ifdef HAVE_RTNETLINK + struct nlmsghdr *nh; +#else + struct rt_msghdr *rtm; + char *p; +#endif if (disable_dynamic_updates) { /* - * discard ourselves if we are not need any more + * discard ourselves if we are not needed any more * usually happens when running unprivileged */ remove_asyncio_reader(reader); @@ -3923,7 +4185,8 @@ cnt = read(reader->fd, buffer, sizeof(buffer)); if (cnt < 0) { - msyslog(LOG_ERR, "i/o error on routing socket %m - disabling"); + msyslog(LOG_ERR, + "i/o error on routing socket %m - disabling"); remove_asyncio_reader(reader); delete_asyncio_reader(reader); return; @@ -3932,19 +4195,28 @@ /* * process routing message */ - while ((p + sizeof(struct rt_msghdr)) <= (buffer + cnt)) - { - struct rt_msghdr *rtm; - +#ifdef HAVE_RTNETLINK + for (nh = (struct nlmsghdr *)buffer; + NLMSG_OK(nh, cnt); + nh = NLMSG_NEXT(nh, cnt)) { + msg_type = nh->nlmsg_type; +#else + for (p = buffer; + (p + sizeof(struct rt_msghdr)) <= (buffer + cnt); + p += rtm->rtm_msglen) { rtm = (struct rt_msghdr *)p; if (rtm->rtm_version != RTM_VERSION) { - msyslog(LOG_ERR, "version mismatch on routing socket %m - disabling"); + msyslog(LOG_ERR, + "version mismatch (got %d - expected %d) on routing socket - disabling", + rtm->rtm_version, RTM_VERSION); + remove_asyncio_reader(reader); delete_asyncio_reader(reader); return; } - - switch (rtm->rtm_type) { + msg_type = rtm->rtm_type; +#endif + switch (msg_type) { #ifdef RTM_NEWADDR case RTM_NEWADDR: #endif @@ -3972,20 +4244,40 @@ #ifdef RTM_IFANNOUNCE case RTM_IFANNOUNCE: #endif +#ifdef RTM_NEWLINK + case RTM_NEWLINK: +#endif +#ifdef RTM_DELLINK + case RTM_DELLINK: +#endif +#ifdef RTM_NEWROUTE + case RTM_NEWROUTE: +#endif +#ifdef RTM_DELROUTE + case RTM_DELROUTE: +#endif /* - * we are keen on new and deleted addresses and if an interface goes up and down or routing changes + * we are keen on new and deleted addresses and + * if an interface goes up and down or routing + * changes */ - DPRINTF(3, ("routing message op = %d: scheduling interface update\n", rtm->rtm_type)); + DPRINTF(3, ("routing message op = %d: scheduling interface update\n", + msg_type)); timer_interfacetimeout(current_time + UPDATE_GRACE); break; +#ifdef HAVE_RTNETLINK + case NLMSG_DONE: + /* end of multipart message */ + return; +#endif default: /* * the rest doesn't bother us. */ - DPRINTF(4, ("routing message op = %d: ignored\n", rtm->rtm_type)); + DPRINTF(4, ("routing message op = %d: ignored\n", + msg_type)); break; } - p += rtm->rtm_msglen; } } @@ -3996,29 +4288,51 @@ init_async_notifications() { struct asyncio_reader *reader; +#ifdef HAVE_RTNETLINK + int fd = socket(PF_NETLINK, SOCK_RAW, NETLINK_ROUTE); + struct sockaddr_nl sa; +#else int fd = socket(PF_ROUTE, SOCK_RAW, 0); - - if (fd >= 0) { - fd = move_fd(fd); - init_nonblocking_io(fd); +#endif + if (fd < 0) { + msyslog(LOG_ERR, + "unable to open routing socket (%m) - using polled interface update"); + return; + } + + fd = move_fd(fd); +#ifdef HAVE_RTNETLINK + memset(&sa, 0, sizeof(sa)); + sa.nl_family = PF_NETLINK; + sa.nl_groups = RTMGRP_LINK | RTMGRP_IPV4_IFADDR + | RTMGRP_IPV6_IFADDR | RTMGRP_IPV4_ROUTE + | RTMGRP_IPV4_MROUTE | RTMGRP_IPV6_ROUTE + | RTMGRP_IPV6_MROUTE; + if (bind(fd, (struct sockaddr *)&sa, sizeof(sa)) < 0) { + msyslog(LOG_ERR, + "bind failed on routing socket (%m) - using polled interface update"); + return; + } +#endif + init_nonblocking_io(fd); #if defined(HAVE_SIGNALED_IO) - init_socket_sig(fd); + init_socket_sig(fd); #endif /* HAVE_SIGNALED_IO */ - - reader = new_asyncio_reader(); + + reader = new_asyncio_reader(); - reader->fd = fd; - reader->receiver = process_routing_msgs; - - add_asyncio_reader(reader, FD_TYPE_SOCKET); - msyslog(LOG_INFO, "Listening on routing socket on fd #%d for interface updates", fd); - } else { - msyslog(LOG_ERR, "unable to open routing socket (%m) - using polled interface update"); - } + reader->fd = fd; + reader->receiver = process_routing_msgs; + + add_asyncio_reader(reader, FD_TYPE_SOCKET); + msyslog(LOG_INFO, + "Listening on routing socket on fd #%d for interface updates", + fd); } #else +/* HAS_ROUTING_SOCKET not defined */ static void -init_async_notifications() +init_async_notifications(void) { } #endif diff -urN src/contrib/ntp/ntpd/ntp_keyword.h src.ntp/contrib/ntp/ntpd/ntp_keyword.h --- src/contrib/ntp/ntpd/ntp_keyword.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/ntp_keyword.h 2010-07-09 04:17:43.000000000 +0200 @@ -0,0 +1,929 @@ +/* + * ntp_keyword.h + * + * NOTE: edit this file with caution, it is generated by keyword-gen.c + * Generated 2010-04-06 04:38:11 UTC diff_ignore_line + * + */ +#include "ntp_scanner.h" +#include "ntp_parser.h" + +#define LOWEST_KEYWORD_ID 258 + +const char * const keyword_text[163] = { + /* 0 258 T_Age */ "age", + /* 1 259 T_All */ "all", + /* 2 260 T_Allan */ "allan", + /* 3 261 T_Auth */ "auth", + /* 4 262 T_Autokey */ "autokey", + /* 5 263 T_Automax */ "automax", + /* 6 264 T_Average */ "average", + /* 7 265 T_Bclient */ "bclient", + /* 8 266 T_Beacon */ "beacon", + /* 9 267 T_Bias */ "bias", + /* 10 268 T_Broadcast */ "broadcast", + /* 11 269 T_Broadcastclient */ "broadcastclient", + /* 12 270 T_Broadcastdelay */ "broadcastdelay", + /* 13 271 T_Burst */ "burst", + /* 14 272 T_Calibrate */ "calibrate", + /* 15 273 T_Calldelay */ "calldelay", + /* 16 274 T_Ceiling */ "ceiling", + /* 17 275 T_Clockstats */ "clockstats", + /* 18 276 T_Cohort */ "cohort", + /* 19 277 T_ControlKey */ "controlkey", + /* 20 278 T_Crypto */ "crypto", + /* 21 279 T_Cryptostats */ "cryptostats", + /* 22 280 T_Day */ "day", + /* 23 281 T_Default */ "default", + /* 24 282 T_Digest */ "digest", + /* 25 283 T_Disable */ "disable", + /* 26 284 T_Discard */ "discard", + /* 27 285 T_Dispersion */ "dispersion", + /* 28 286 T_Double */ NULL, + /* 29 287 T_Driftfile */ "driftfile", + /* 30 288 T_Drop */ "drop", + /* 31 289 T_Ellipsis */ "...", + /* 32 290 T_Enable */ "enable", + /* 33 291 T_End */ "end", + /* 34 292 T_False */ NULL, + /* 35 293 T_File */ "file", + /* 36 294 T_Filegen */ "filegen", + /* 37 295 T_Flag1 */ "flag1", + /* 38 296 T_Flag2 */ "flag2", + /* 39 297 T_Flag3 */ "flag3", + /* 40 298 T_Flag4 */ "flag4", + /* 41 299 T_Flake */ "flake", + /* 42 300 T_Floor */ "floor", + /* 43 301 T_Freq */ "freq", + /* 44 302 T_Fudge */ "fudge", + /* 45 303 T_Host */ "host", + /* 46 304 T_Huffpuff */ "huffpuff", + /* 47 305 T_Iburst */ "iburst", + /* 48 306 T_Ident */ "ident", + /* 49 307 T_Ignore */ "ignore", + /* 50 308 T_Includefile */ "includefile", + /* 51 309 T_Integer */ NULL, + /* 52 310 T_Interface */ "interface", + /* 53 311 T_Ipv4 */ "ipv4", + /* 54 312 T_Ipv4_flag */ "-4", + /* 55 313 T_Ipv6 */ "ipv6", + /* 56 314 T_Ipv6_flag */ "-6", + /* 57 315 T_Kernel */ "kernel", + /* 58 316 T_Key */ "key", + /* 59 317 T_Keys */ "keys", + /* 60 318 T_Keysdir */ "keysdir", + /* 61 319 T_Kod */ "kod", + /* 62 320 T_Mssntp */ "mssntp", + /* 63 321 T_Leapfile */ "leapfile", + /* 64 322 T_Limited */ "limited", + /* 65 323 T_Link */ "link", + /* 66 324 T_Listen */ "listen", + /* 67 325 T_Logconfig */ "logconfig", + /* 68 326 T_Logfile */ "logfile", + /* 69 327 T_Loopstats */ "loopstats", + /* 70 328 T_Lowpriotrap */ "lowpriotrap", + /* 71 329 T_Manycastclient */ "manycastclient", + /* 72 330 T_Manycastserver */ "manycastserver", + /* 73 331 T_Mask */ "mask", + /* 74 332 T_Maxclock */ "maxclock", + /* 75 333 T_Maxdist */ "maxdist", + /* 76 334 T_Maxpoll */ "maxpoll", + /* 77 335 T_Minclock */ "minclock", + /* 78 336 T_Mindist */ "mindist", + /* 79 337 T_Minimum */ "minimum", + /* 80 338 T_Minpoll */ "minpoll", + /* 81 339 T_Minsane */ "minsane", + /* 82 340 T_Mode */ "mode", + /* 83 341 T_Monitor */ "monitor", + /* 84 342 T_Month */ "month", + /* 85 343 T_Multicastclient */ "multicastclient", + /* 86 344 T_Nic */ "nic", + /* 87 345 T_Nolink */ "nolink", + /* 88 346 T_Nomodify */ "nomodify", + /* 89 347 T_None */ "none", + /* 90 348 T_Nopeer */ "nopeer", + /* 91 349 T_Noquery */ "noquery", + /* 92 350 T_Noselect */ "noselect", + /* 93 351 T_Noserve */ "noserve", + /* 94 352 T_Notrap */ "notrap", + /* 95 353 T_Notrust */ "notrust", + /* 96 354 T_Ntp */ "ntp", + /* 97 355 T_Ntpport */ "ntpport", + /* 98 356 T_NtpSignDsocket */ "ntpsigndsocket", + /* 99 357 T_Orphan */ "orphan", + /* 100 358 T_Panic */ "panic", + /* 101 359 T_Peer */ "peer", + /* 102 360 T_Peerstats */ "peerstats", + /* 103 361 T_Phone */ "phone", + /* 104 362 T_Pid */ "pid", + /* 105 363 T_Pidfile */ "pidfile", + /* 106 364 T_Pool */ "pool", + /* 107 365 T_Port */ "port", + /* 108 366 T_Preempt */ "preempt", + /* 109 367 T_Prefer */ "prefer", + /* 110 368 T_Protostats */ "protostats", + /* 111 369 T_Pw */ "pw", + /* 112 370 T_Qos */ "qos", + /* 113 371 T_Randfile */ "randfile", + /* 114 372 T_Rawstats */ "rawstats", + /* 115 373 T_Refid */ "refid", + /* 116 374 T_Requestkey */ "requestkey", + /* 117 375 T_Restrict */ "restrict", + /* 118 376 T_Revoke */ "revoke", + /* 119 377 T_Saveconfigdir */ "saveconfigdir", + /* 120 378 T_Server */ "server", + /* 121 379 T_Setvar */ "setvar", + /* 122 380 T_Sign */ "sign", + /* 123 381 T_Statistics */ "statistics", + /* 124 382 T_Stats */ "stats", + /* 125 383 T_Statsdir */ "statsdir", + /* 126 384 T_Step */ "step", + /* 127 385 T_Stepout */ "stepout", + /* 128 386 T_Stratum */ "stratum", + /* 129 387 T_String */ NULL, + /* 130 388 T_Sysstats */ "sysstats", + /* 131 389 T_Tick */ "tick", + /* 132 390 T_Time1 */ "time1", + /* 133 391 T_Time2 */ "time2", + /* 134 392 T_Timingstats */ "timingstats", + /* 135 393 T_Tinker */ "tinker", + /* 136 394 T_Tos */ "tos", + /* 137 395 T_Trap */ "trap", + /* 138 396 T_True */ "true", + /* 139 397 T_Trustedkey */ "trustedkey", + /* 140 398 T_Ttl */ "ttl", + /* 141 399 T_Type */ "type", + /* 142 400 T_Unconfig */ "unconfig", + /* 143 401 T_Unpeer */ "unpeer", + /* 144 402 T_Version */ "version", + /* 145 403 T_WanderThreshold */ NULL, + /* 146 404 T_Week */ "week", + /* 147 405 T_Wildcard */ "wildcard", + /* 148 406 T_Xleave */ "xleave", + /* 149 407 T_Year */ "year", + /* 150 408 T_Flag */ NULL, + /* 151 409 T_Void */ NULL, + /* 152 410 T_EOC */ NULL, + /* 153 411 T_Simulate */ "simulate", + /* 154 412 T_Beep_Delay */ "beep_delay", + /* 155 413 T_Sim_Duration */ "simulation_duration", + /* 156 414 T_Server_Offset */ "server_offset", + /* 157 415 T_Duration */ "duration", + /* 158 416 T_Freq_Offset */ "freq_offset", + /* 159 417 T_Wander */ "wander", + /* 160 418 T_Jitter */ "jitter", + /* 161 419 T_Prop_Delay */ "prop_delay", + /* 162 420 T_Proc_Delay */ "proc_delay" +}; + +#define SCANNER_INIT_S 742 + +const scan_state sst[745] = { +/*SS_T( ch, f-by, match, other ), */ + 0, /* 0 */ + S_ST( '-', 3, 314, 0 ), /* 1 */ + S_ST( '.', 3, 3, 1 ), /* 2 */ + S_ST( '.', 3, 289, 0 ), /* 3 */ + S_ST( 'a', 3, 15, 2 ), /* 4 */ + S_ST( 'g', 3, 258, 0 ), /* 5 */ + S_ST( 'l', 3, 259, 5 ), /* 6 */ + S_ST( 'a', 3, 260, 0 ), /* 7 */ + S_ST( 'u', 3, 9, 6 ), /* 8 */ + S_ST( 't', 3, 10, 0 ), /* 9 */ + S_ST( 'o', 3, 13, 261 ), /* 10 */ + S_ST( 'k', 3, 12, 0 ), /* 11 */ + S_ST( 'e', 3, 262, 0 ), /* 12 */ + S_ST( 'm', 3, 14, 11 ), /* 13 */ + S_ST( 'a', 3, 263, 0 ), /* 14 */ + S_ST( 'v', 3, 16, 8 ), /* 15 */ + S_ST( 'e', 3, 17, 0 ), /* 16 */ + S_ST( 'r', 3, 18, 0 ), /* 17 */ + S_ST( 'a', 3, 19, 0 ), /* 18 */ + S_ST( 'g', 3, 264, 0 ), /* 19 */ + S_ST( 'b', 3, 55, 4 ), /* 20 */ + S_ST( 'c', 3, 22, 0 ), /* 21 */ + S_ST( 'l', 3, 23, 0 ), /* 22 */ + S_ST( 'i', 3, 24, 0 ), /* 23 */ + S_ST( 'e', 3, 25, 0 ), /* 24 */ + S_ST( 'n', 3, 265, 0 ), /* 25 */ + S_ST( 'e', 3, 30, 21 ), /* 26 */ + S_ST( 'a', 3, 28, 0 ), /* 27 */ + S_ST( 'c', 3, 29, 0 ), /* 28 */ + S_ST( 'o', 3, 266, 0 ), /* 29 */ + S_ST( 'e', 3, 31, 27 ), /* 30 */ + S_ST( 'p', 3, 32, 0 ), /* 31 */ + S_ST( '_', 3, 33, 0 ), /* 32 */ + S_ST( 'd', 3, 34, 0 ), /* 33 */ + S_ST( 'e', 3, 35, 0 ), /* 34 */ + S_ST( 'l', 3, 36, 0 ), /* 35 */ + S_ST( 'a', 3, 412, 0 ), /* 36 */ + S_ST( 'i', 3, 38, 26 ), /* 37 */ + S_ST( 'a', 3, 267, 0 ), /* 38 */ + S_ST( 'r', 3, 40, 37 ), /* 39 */ + S_ST( 'o', 3, 41, 0 ), /* 40 */ + S_ST( 'a', 3, 42, 0 ), /* 41 */ + S_ST( 'd', 3, 43, 0 ), /* 42 */ + S_ST( 'c', 3, 44, 0 ), /* 43 */ + S_ST( 'a', 3, 45, 0 ), /* 44 */ + S_ST( 's', 3, 268, 0 ), /* 45 */ + S_ST( 'c', 3, 47, 0 ), /* 46 */ + S_ST( 'l', 3, 48, 0 ), /* 47 */ + S_ST( 'i', 3, 49, 0 ), /* 48 */ + S_ST( 'e', 3, 50, 0 ), /* 49 */ + S_ST( 'n', 3, 269, 0 ), /* 50 */ + S_ST( 'd', 3, 52, 46 ), /* 51 */ + S_ST( 'e', 3, 53, 0 ), /* 52 */ + S_ST( 'l', 3, 54, 0 ), /* 53 */ + S_ST( 'a', 3, 270, 0 ), /* 54 */ + S_ST( 'u', 3, 56, 39 ), /* 55 */ + S_ST( 'r', 3, 57, 0 ), /* 56 */ + S_ST( 's', 3, 271, 0 ), /* 57 */ + S_ST( 'c', 3, 95, 20 ), /* 58 */ + S_ST( 'a', 3, 60, 0 ), /* 59 */ + S_ST( 'l', 3, 66, 0 ), /* 60 */ + S_ST( 'i', 3, 62, 0 ), /* 61 */ + S_ST( 'b', 3, 63, 0 ), /* 62 */ + S_ST( 'r', 3, 64, 0 ), /* 63 */ + S_ST( 'a', 3, 65, 0 ), /* 64 */ + S_ST( 't', 3, 272, 0 ), /* 65 */ + S_ST( 'l', 3, 67, 61 ), /* 66 */ + S_ST( 'd', 3, 68, 0 ), /* 67 */ + S_ST( 'e', 3, 69, 0 ), /* 68 */ + S_ST( 'l', 3, 70, 0 ), /* 69 */ + S_ST( 'a', 3, 273, 0 ), /* 70 */ + S_ST( 'e', 3, 72, 59 ), /* 71 */ + S_ST( 'i', 3, 73, 0 ), /* 72 */ + S_ST( 'l', 3, 74, 0 ), /* 73 */ + S_ST( 'i', 3, 75, 0 ), /* 74 */ + S_ST( 'n', 3, 274, 0 ), /* 75 */ + S_ST( 'l', 3, 77, 71 ), /* 76 */ + S_ST( 'o', 3, 78, 0 ), /* 77 */ + S_ST( 'c', 3, 79, 0 ), /* 78 */ + S_ST( 'k', 3, 80, 0 ), /* 79 */ + S_ST( 's', 3, 81, 0 ), /* 80 */ + S_ST( 't', 3, 82, 0 ), /* 81 */ + S_ST( 'a', 3, 83, 0 ), /* 82 */ + S_ST( 't', 3, 275, 0 ), /* 83 */ + S_ST( 'o', 3, 88, 76 ), /* 84 */ + S_ST( 'h', 3, 86, 0 ), /* 85 */ + S_ST( 'o', 3, 87, 0 ), /* 86 */ + S_ST( 'r', 3, 276, 0 ), /* 87 */ + S_ST( 'n', 3, 89, 85 ), /* 88 */ + S_ST( 't', 3, 90, 0 ), /* 89 */ + S_ST( 'r', 3, 91, 0 ), /* 90 */ + S_ST( 'o', 3, 92, 0 ), /* 91 */ + S_ST( 'l', 3, 93, 0 ), /* 92 */ + S_ST( 'k', 3, 94, 0 ), /* 93 */ + S_ST( 'e', 3, 277, 0 ), /* 94 */ + S_ST( 'r', 3, 96, 84 ), /* 95 */ + S_ST( 'y', 3, 97, 0 ), /* 96 */ + S_ST( 'p', 3, 98, 0 ), /* 97 */ + S_ST( 't', 3, 278, 0 ), /* 98 */ + S_ST( 's', 3, 100, 0 ), /* 99 */ + S_ST( 't', 3, 101, 0 ), /* 100 */ + S_ST( 'a', 3, 102, 0 ), /* 101 */ + S_ST( 't', 3, 279, 0 ), /* 102 */ + S_ST( 'd', 3, 135, 58 ), /* 103 */ + S_ST( 'a', 3, 280, 0 ), /* 104 */ + S_ST( 'e', 3, 106, 104 ), /* 105 */ + S_ST( 'f', 3, 107, 0 ), /* 106 */ + S_ST( 'a', 3, 108, 0 ), /* 107 */ + S_ST( 'u', 3, 109, 0 ), /* 108 */ + S_ST( 'l', 3, 281, 0 ), /* 109 */ + S_ST( 'i', 3, 114, 105 ), /* 110 */ + S_ST( 'g', 3, 112, 0 ), /* 111 */ + S_ST( 'e', 3, 113, 0 ), /* 112 */ + S_ST( 's', 3, 282, 0 ), /* 113 */ + S_ST( 's', 3, 121, 111 ), /* 114 */ + S_ST( 'a', 3, 116, 0 ), /* 115 */ + S_ST( 'b', 3, 117, 0 ), /* 116 */ + S_ST( 'l', 3, 283, 0 ), /* 117 */ + S_ST( 'c', 3, 119, 115 ), /* 118 */ + S_ST( 'a', 3, 120, 0 ), /* 119 */ + S_ST( 'r', 3, 284, 0 ), /* 120 */ + S_ST( 'p', 3, 122, 118 ), /* 121 */ + S_ST( 'e', 3, 123, 0 ), /* 122 */ + S_ST( 'r', 3, 124, 0 ), /* 123 */ + S_ST( 's', 3, 125, 0 ), /* 124 */ + S_ST( 'i', 3, 126, 0 ), /* 125 */ + S_ST( 'o', 3, 285, 0 ), /* 126 */ + S_ST( 'r', 3, 134, 110 ), /* 127 */ + S_ST( 'i', 3, 129, 0 ), /* 128 */ + S_ST( 'f', 3, 130, 0 ), /* 129 */ + S_ST( 't', 3, 131, 0 ), /* 130 */ + S_ST( 'f', 3, 132, 0 ), /* 131 */ + S_ST( 'i', 3, 133, 0 ), /* 132 */ + S_ST( 'l', 3, 287, 0 ), /* 133 */ + S_ST( 'o', 3, 288, 128 ), /* 134 */ + S_ST( 'u', 3, 136, 127 ), /* 135 */ + S_ST( 'r', 3, 137, 0 ), /* 136 */ + S_ST( 'a', 3, 138, 0 ), /* 137 */ + S_ST( 't', 3, 139, 0 ), /* 138 */ + S_ST( 'i', 3, 140, 0 ), /* 139 */ + S_ST( 'o', 3, 415, 0 ), /* 140 */ + S_ST( 'e', 3, 142, 103 ), /* 141 */ + S_ST( 'n', 3, 291, 0 ), /* 142 */ + S_ST( 'a', 3, 144, 0 ), /* 143 */ + S_ST( 'b', 3, 145, 0 ), /* 144 */ + S_ST( 'l', 3, 290, 0 ), /* 145 */ + S_ST( 'f', 3, 165, 141 ), /* 146 */ + S_ST( 'i', 3, 148, 0 ), /* 147 */ + S_ST( 'l', 3, 293, 0 ), /* 148 */ + S_ST( 'g', 3, 150, 0 ), /* 149 */ + S_ST( 'e', 3, 294, 0 ), /* 150 */ + S_ST( 'l', 3, 155, 147 ), /* 151 */ + S_ST( 'a', 3, 154, 0 ), /* 152 */ + S_ST( 'g', 3, 298, 0 ), /* 153 */ + S_ST( 'k', 3, 299, 153 ), /* 154 */ + S_ST( 'o', 3, 156, 152 ), /* 155 */ + S_ST( 'o', 3, 300, 0 ), /* 156 */ + S_ST( 'r', 3, 158, 151 ), /* 157 */ + S_ST( 'e', 3, 301, 0 ), /* 158 */ + S_ST( '_', 3, 160, 0 ), /* 159 */ + S_ST( 'o', 3, 161, 0 ), /* 160 */ + S_ST( 'f', 3, 162, 0 ), /* 161 */ + S_ST( 'f', 3, 163, 0 ), /* 162 */ + S_ST( 's', 3, 164, 0 ), /* 163 */ + S_ST( 'e', 3, 416, 0 ), /* 164 */ + S_ST( 'u', 3, 166, 157 ), /* 165 */ + S_ST( 'd', 3, 167, 0 ), /* 166 */ + S_ST( 'g', 3, 302, 0 ), /* 167 */ + S_ST( 'h', 3, 171, 146 ), /* 168 */ + S_ST( 'o', 3, 170, 0 ), /* 169 */ + S_ST( 's', 3, 303, 0 ), /* 170 */ + S_ST( 'u', 3, 172, 169 ), /* 171 */ + S_ST( 'f', 3, 173, 0 ), /* 172 */ + S_ST( 'f', 3, 174, 0 ), /* 173 */ + S_ST( 'p', 3, 175, 0 ), /* 174 */ + S_ST( 'u', 3, 176, 0 ), /* 175 */ + S_ST( 'f', 3, 304, 0 ), /* 176 */ + S_ST( 'i', 3, 204, 168 ), /* 177 */ + S_ST( 'b', 3, 179, 0 ), /* 178 */ + S_ST( 'u', 3, 180, 0 ), /* 179 */ + S_ST( 'r', 3, 181, 0 ), /* 180 */ + S_ST( 's', 3, 305, 0 ), /* 181 */ + S_ST( 'd', 3, 183, 178 ), /* 182 */ + S_ST( 'e', 3, 184, 0 ), /* 183 */ + S_ST( 'n', 3, 306, 0 ), /* 184 */ + S_ST( 'g', 3, 186, 182 ), /* 185 */ + S_ST( 'n', 3, 187, 0 ), /* 186 */ + S_ST( 'o', 3, 188, 0 ), /* 187 */ + S_ST( 'r', 3, 307, 0 ), /* 188 */ + S_ST( 'n', 3, 198, 185 ), /* 189 */ + S_ST( 'c', 3, 191, 0 ), /* 190 */ + S_ST( 'l', 3, 192, 0 ), /* 191 */ + S_ST( 'u', 3, 193, 0 ), /* 192 */ + S_ST( 'd', 3, 194, 0 ), /* 193 */ + S_ST( 'e', 3, 195, 0 ), /* 194 */ + S_ST( 'f', 3, 196, 0 ), /* 195 */ + S_ST( 'i', 3, 197, 0 ), /* 196 */ + S_ST( 'l', 3, 308, 0 ), /* 197 */ + S_ST( 't', 3, 199, 190 ), /* 198 */ + S_ST( 'e', 3, 200, 0 ), /* 199 */ + S_ST( 'r', 3, 201, 0 ), /* 200 */ + S_ST( 'f', 3, 202, 0 ), /* 201 */ + S_ST( 'a', 3, 203, 0 ), /* 202 */ + S_ST( 'c', 3, 310, 0 ), /* 203 */ + S_ST( 'p', 3, 205, 189 ), /* 204 */ + S_ST( 'v', 3, 313, 0 ), /* 205 */ + S_ST( 'j', 3, 207, 177 ), /* 206 */ + S_ST( 'i', 3, 208, 0 ), /* 207 */ + S_ST( 't', 3, 209, 0 ), /* 208 */ + S_ST( 't', 3, 210, 0 ), /* 209 */ + S_ST( 'e', 3, 418, 0 ), /* 210 */ + S_ST( 'k', 3, 218, 206 ), /* 211 */ + S_ST( 'e', 3, 316, 0 ), /* 212 */ + S_ST( 'r', 3, 214, 0 ), /* 213 */ + S_ST( 'n', 3, 215, 0 ), /* 214 */ + S_ST( 'e', 3, 315, 0 ), /* 215 */ + S_ST( 'd', 3, 217, 0 ), /* 216 */ + S_ST( 'i', 3, 318, 0 ), /* 217 */ + S_ST( 'o', 3, 319, 212 ), /* 218 */ + S_ST( 'l', 3, 235, 211 ), /* 219 */ + S_ST( 'e', 3, 221, 0 ), /* 220 */ + S_ST( 'a', 3, 222, 0 ), /* 221 */ + S_ST( 'p', 3, 223, 0 ), /* 222 */ + S_ST( 'f', 3, 224, 0 ), /* 223 */ + S_ST( 'i', 3, 225, 0 ), /* 224 */ + S_ST( 'l', 3, 321, 0 ), /* 225 */ + S_ST( 'i', 3, 232, 220 ), /* 226 */ + S_ST( 'm', 3, 228, 0 ), /* 227 */ + S_ST( 'i', 3, 229, 0 ), /* 228 */ + S_ST( 't', 3, 230, 0 ), /* 229 */ + S_ST( 'e', 3, 322, 0 ), /* 230 */ + S_ST( 'n', 3, 323, 227 ), /* 231 */ + S_ST( 's', 3, 233, 231 ), /* 232 */ + S_ST( 't', 3, 234, 0 ), /* 233 */ + S_ST( 'e', 3, 324, 0 ), /* 234 */ + S_ST( 'o', 3, 251, 226 ), /* 235 */ + S_ST( 'g', 3, 242, 0 ), /* 236 */ + S_ST( 'c', 3, 238, 0 ), /* 237 */ + S_ST( 'o', 3, 239, 0 ), /* 238 */ + S_ST( 'n', 3, 240, 0 ), /* 239 */ + S_ST( 'f', 3, 241, 0 ), /* 240 */ + S_ST( 'i', 3, 325, 0 ), /* 241 */ + S_ST( 'f', 3, 243, 237 ), /* 242 */ + S_ST( 'i', 3, 244, 0 ), /* 243 */ + S_ST( 'l', 3, 326, 0 ), /* 244 */ + S_ST( 'o', 3, 246, 236 ), /* 245 */ + S_ST( 'p', 3, 247, 0 ), /* 246 */ + S_ST( 's', 3, 248, 0 ), /* 247 */ + S_ST( 't', 3, 249, 0 ), /* 248 */ + S_ST( 'a', 3, 250, 0 ), /* 249 */ + S_ST( 't', 3, 327, 0 ), /* 250 */ + S_ST( 'w', 3, 252, 245 ), /* 251 */ + S_ST( 'p', 3, 253, 0 ), /* 252 */ + S_ST( 'r', 3, 254, 0 ), /* 253 */ + S_ST( 'i', 3, 255, 0 ), /* 254 */ + S_ST( 'o', 3, 256, 0 ), /* 255 */ + S_ST( 't', 3, 257, 0 ), /* 256 */ + S_ST( 'r', 3, 286, 0 ), /* 257 */ + S_ST( 'e', 0, 0, 0 ), /* 258 T_Age */ + S_ST( 'l', 0, 7, 0 ), /* 259 T_All */ + S_ST( 'n', 0, 0, 0 ), /* 260 T_Allan */ + S_ST( 'h', 0, 0, 0 ), /* 261 T_Auth */ + S_ST( 'y', 0, 0, 0 ), /* 262 T_Autokey */ + S_ST( 'x', 0, 0, 0 ), /* 263 T_Automax */ + S_ST( 'e', 0, 0, 0 ), /* 264 T_Average */ + S_ST( 't', 0, 0, 0 ), /* 265 T_Bclient */ + S_ST( 'n', 0, 0, 0 ), /* 266 T_Beacon */ + S_ST( 's', 0, 0, 0 ), /* 267 T_Bias */ + S_ST( 't', 1, 51, 0 ), /* 268 T_Broadcast */ + S_ST( 't', 0, 0, 0 ), /* 269 T_Broadcastclient */ + S_ST( 'y', 0, 0, 0 ), /* 270 T_Broadcastdelay */ + S_ST( 't', 0, 0, 0 ), /* 271 T_Burst */ + S_ST( 'e', 0, 0, 0 ), /* 272 T_Calibrate */ + S_ST( 'y', 0, 0, 0 ), /* 273 T_Calldelay */ + S_ST( 'g', 0, 0, 0 ), /* 274 T_Ceiling */ + S_ST( 's', 0, 0, 0 ), /* 275 T_Clockstats */ + S_ST( 't', 0, 0, 0 ), /* 276 T_Cohort */ + S_ST( 'y', 0, 0, 0 ), /* 277 T_ControlKey */ + S_ST( 'o', 0, 99, 0 ), /* 278 T_Crypto */ + S_ST( 's', 0, 0, 0 ), /* 279 T_Cryptostats */ + S_ST( 'y', 0, 0, 0 ), /* 280 T_Day */ + S_ST( 't', 0, 0, 0 ), /* 281 T_Default */ + S_ST( 't', 1, 0, 0 ), /* 282 T_Digest */ + S_ST( 'e', 0, 0, 0 ), /* 283 T_Disable */ + S_ST( 'd', 0, 0, 0 ), /* 284 T_Discard */ + S_ST( 'n', 0, 0, 0 ), /* 285 T_Dispersion */ + S_ST( 'a', 3, 328, 0 ), /* 286 */ + S_ST( 'e', 1, 0, 0 ), /* 287 T_Driftfile */ + S_ST( 'p', 0, 0, 0 ), /* 288 T_Drop */ + S_ST( '.', 0, 0, 0 ), /* 289 T_Ellipsis */ + S_ST( 'e', 0, 0, 0 ), /* 290 T_Enable */ + S_ST( 'd', 0, 0, 143 ), /* 291 T_End */ + S_ST( 'm', 3, 473, 219 ), /* 292 */ + S_ST( 'e', 1, 149, 0 ), /* 293 T_File */ + S_ST( 'n', 0, 0, 0 ), /* 294 T_Filegen */ + S_ST( '1', 0, 0, 0 ), /* 295 T_Flag1 */ + S_ST( '2', 0, 0, 295 ), /* 296 T_Flag2 */ + S_ST( '3', 0, 0, 296 ), /* 297 T_Flag3 */ + S_ST( '4', 0, 0, 297 ), /* 298 T_Flag4 */ + S_ST( 'e', 0, 0, 0 ), /* 299 T_Flake */ + S_ST( 'r', 0, 0, 0 ), /* 300 T_Floor */ + S_ST( 'q', 0, 159, 0 ), /* 301 T_Freq */ + S_ST( 'e', 1, 0, 0 ), /* 302 T_Fudge */ + S_ST( 't', 1, 0, 0 ), /* 303 T_Host */ + S_ST( 'f', 0, 0, 0 ), /* 304 T_Huffpuff */ + S_ST( 't', 0, 0, 0 ), /* 305 T_Iburst */ + S_ST( 't', 1, 0, 0 ), /* 306 T_Ident */ + S_ST( 'e', 0, 0, 0 ), /* 307 T_Ignore */ + S_ST( 'e', 1, 0, 0 ), /* 308 T_Includefile */ + S_ST( 'a', 3, 433, 0 ), /* 309 */ + S_ST( 'e', 0, 0, 0 ), /* 310 T_Interface */ + S_ST( '4', 0, 0, 0 ), /* 311 T_Ipv4 */ + S_ST( '4', 0, 0, 0 ), /* 312 T_Ipv4_flag */ + S_ST( '6', 0, 0, 311 ), /* 313 T_Ipv6 */ + S_ST( '6', 0, 0, 312 ), /* 314 T_Ipv6_flag */ + S_ST( 'l', 0, 0, 0 ), /* 315 T_Kernel */ + S_ST( 'y', 0, 317, 213 ), /* 316 T_Key */ + S_ST( 's', 1, 216, 0 ), /* 317 T_Keys */ + S_ST( 'r', 1, 0, 0 ), /* 318 T_Keysdir */ + S_ST( 'd', 0, 0, 0 ), /* 319 T_Kod */ + S_ST( 'p', 0, 0, 0 ), /* 320 T_Mssntp */ + S_ST( 'e', 1, 0, 0 ), /* 321 T_Leapfile */ + S_ST( 'd', 0, 0, 0 ), /* 322 T_Limited */ + S_ST( 'k', 0, 0, 0 ), /* 323 T_Link */ + S_ST( 'n', 0, 0, 0 ), /* 324 T_Listen */ + S_ST( 'g', 2, 0, 0 ), /* 325 T_Logconfig */ + S_ST( 'e', 1, 0, 0 ), /* 326 T_Logfile */ + S_ST( 's', 0, 0, 0 ), /* 327 T_Loopstats */ + S_ST( 'p', 0, 0, 0 ), /* 328 T_Lowpriotrap */ + S_ST( 't', 1, 0, 0 ), /* 329 T_Manycastclient */ + S_ST( 'r', 2, 0, 0 ), /* 330 T_Manycastserver */ + S_ST( 'k', 0, 0, 0 ), /* 331 T_Mask */ + S_ST( 'k', 0, 0, 0 ), /* 332 T_Maxclock */ + S_ST( 't', 0, 0, 0 ), /* 333 T_Maxdist */ + S_ST( 'l', 0, 0, 0 ), /* 334 T_Maxpoll */ + S_ST( 'k', 0, 0, 0 ), /* 335 T_Minclock */ + S_ST( 't', 0, 0, 0 ), /* 336 T_Mindist */ + S_ST( 'm', 0, 0, 0 ), /* 337 T_Minimum */ + S_ST( 'l', 0, 0, 0 ), /* 338 T_Minpoll */ + S_ST( 'e', 0, 0, 0 ), /* 339 T_Minsane */ + S_ST( 'e', 0, 0, 0 ), /* 340 T_Mode */ + S_ST( 'r', 0, 0, 0 ), /* 341 T_Monitor */ + S_ST( 'h', 0, 0, 0 ), /* 342 T_Month */ + S_ST( 't', 2, 0, 0 ), /* 343 T_Multicastclient */ + S_ST( 'c', 0, 0, 0 ), /* 344 T_Nic */ + S_ST( 'k', 0, 0, 0 ), /* 345 T_Nolink */ + S_ST( 'y', 0, 0, 0 ), /* 346 T_Nomodify */ + S_ST( 'e', 0, 0, 0 ), /* 347 T_None */ + S_ST( 'r', 0, 0, 0 ), /* 348 T_Nopeer */ + S_ST( 'y', 0, 0, 0 ), /* 349 T_Noquery */ + S_ST( 't', 0, 0, 0 ), /* 350 T_Noselect */ + S_ST( 'e', 0, 0, 0 ), /* 351 T_Noserve */ + S_ST( 'p', 0, 0, 0 ), /* 352 T_Notrap */ + S_ST( 't', 0, 0, 0 ), /* 353 T_Notrust */ + S_ST( 'p', 0, 521, 0 ), /* 354 T_Ntp */ + S_ST( 't', 0, 0, 0 ), /* 355 T_Ntpport */ + S_ST( 't', 1, 0, 0 ), /* 356 T_NtpSignDsocket */ + S_ST( 'n', 0, 0, 0 ), /* 357 T_Orphan */ + S_ST( 'c', 0, 0, 0 ), /* 358 T_Panic */ + S_ST( 'r', 1, 542, 0 ), /* 359 T_Peer */ + S_ST( 's', 0, 0, 0 ), /* 360 T_Peerstats */ + S_ST( 'e', 2, 0, 0 ), /* 361 T_Phone */ + S_ST( 'd', 0, 550, 0 ), /* 362 T_Pid */ + S_ST( 'e', 1, 0, 0 ), /* 363 T_Pidfile */ + S_ST( 'l', 1, 0, 0 ), /* 364 T_Pool */ + S_ST( 't', 0, 0, 0 ), /* 365 T_Port */ + S_ST( 't', 0, 0, 0 ), /* 366 T_Preempt */ + S_ST( 'r', 0, 0, 0 ), /* 367 T_Prefer */ + S_ST( 's', 0, 0, 0 ), /* 368 T_Protostats */ + S_ST( 'w', 1, 0, 556 ), /* 369 T_Pw */ + S_ST( 's', 0, 0, 0 ), /* 370 T_Qos */ + S_ST( 'e', 1, 0, 0 ), /* 371 T_Randfile */ + S_ST( 's', 0, 0, 0 ), /* 372 T_Rawstats */ + S_ST( 'd', 1, 0, 0 ), /* 373 T_Refid */ + S_ST( 'y', 0, 0, 0 ), /* 374 T_Requestkey */ + S_ST( 't', 0, 0, 0 ), /* 375 T_Restrict */ + S_ST( 'e', 0, 0, 0 ), /* 376 T_Revoke */ + S_ST( 'r', 1, 0, 0 ), /* 377 T_Saveconfigdir */ + S_ST( 'r', 1, 630, 0 ), /* 378 T_Server */ + S_ST( 'r', 1, 0, 0 ), /* 379 T_Setvar */ + S_ST( 'n', 1, 0, 0 ), /* 380 T_Sign */ + S_ST( 's', 0, 0, 0 ), /* 381 T_Statistics */ + S_ST( 's', 0, 665, 660 ), /* 382 T_Stats */ + S_ST( 'r', 1, 0, 0 ), /* 383 T_Statsdir */ + S_ST( 'p', 0, 668, 0 ), /* 384 T_Step */ + S_ST( 't', 0, 0, 0 ), /* 385 T_Stepout */ + S_ST( 'm', 0, 0, 0 ), /* 386 T_Stratum */ + S_ST( 'n', 3, 403, 0 ), /* 387 */ + S_ST( 's', 0, 0, 0 ), /* 388 T_Sysstats */ + S_ST( 'k', 0, 0, 0 ), /* 389 T_Tick */ + S_ST( '1', 0, 0, 0 ), /* 390 T_Time1 */ + S_ST( '2', 0, 0, 390 ), /* 391 T_Time2 */ + S_ST( 's', 0, 0, 0 ), /* 392 T_Timingstats */ + S_ST( 'r', 0, 0, 0 ), /* 393 T_Tinker */ + S_ST( 's', 0, 0, 0 ), /* 394 T_Tos */ + S_ST( 'p', 1, 0, 0 ), /* 395 T_Trap */ + S_ST( 'e', 0, 0, 0 ), /* 396 T_True */ + S_ST( 'y', 0, 0, 0 ), /* 397 T_Trustedkey */ + S_ST( 'l', 0, 0, 0 ), /* 398 T_Ttl */ + S_ST( 'e', 0, 0, 0 ), /* 399 T_Type */ + S_ST( 'g', 1, 0, 0 ), /* 400 T_Unconfig */ + S_ST( 'r', 1, 0, 0 ), /* 401 T_Unpeer */ + S_ST( 'n', 0, 0, 0 ), /* 402 T_Version */ + S_ST( 'y', 3, 408, 0 ), /* 403 */ + S_ST( 'k', 0, 0, 0 ), /* 404 T_Week */ + S_ST( 'd', 0, 0, 0 ), /* 405 T_Wildcard */ + S_ST( 'e', 0, 0, 0 ), /* 406 T_Xleave */ + S_ST( 'r', 0, 0, 0 ), /* 407 T_Year */ + S_ST( 'c', 3, 409, 0 ), /* 408 */ + S_ST( 'a', 3, 410, 0 ), /* 409 */ + S_ST( 's', 3, 421, 0 ), /* 410 */ + S_ST( 'e', 0, 0, 0 ), /* 411 T_Simulate */ + S_ST( 'y', 0, 0, 0 ), /* 412 T_Beep_Delay */ + S_ST( 'n', 0, 0, 0 ), /* 413 T_Sim_Duration */ + S_ST( 't', 0, 0, 0 ), /* 414 T_Server_Offset */ + S_ST( 'n', 0, 0, 0 ), /* 415 T_Duration */ + S_ST( 't', 0, 0, 0 ), /* 416 T_Freq_Offset */ + S_ST( 'r', 0, 0, 0 ), /* 417 T_Wander */ + S_ST( 'r', 0, 0, 0 ), /* 418 T_Jitter */ + S_ST( 'y', 0, 0, 0 ), /* 419 T_Prop_Delay */ + S_ST( 'y', 0, 0, 0 ), /* 420 T_Proc_Delay */ + S_ST( 't', 3, 427, 0 ), /* 421 */ + S_ST( 'c', 3, 423, 0 ), /* 422 */ + S_ST( 'l', 3, 424, 0 ), /* 423 */ + S_ST( 'i', 3, 425, 0 ), /* 424 */ + S_ST( 'e', 3, 426, 0 ), /* 425 */ + S_ST( 'n', 3, 329, 0 ), /* 426 */ + S_ST( 's', 3, 428, 422 ), /* 427 */ + S_ST( 'e', 3, 429, 0 ), /* 428 */ + S_ST( 'r', 3, 430, 0 ), /* 429 */ + S_ST( 'v', 3, 431, 0 ), /* 430 */ + S_ST( 'e', 3, 330, 0 ), /* 431 */ + S_ST( 's', 3, 331, 387 ), /* 432 */ + S_ST( 'x', 3, 441, 432 ), /* 433 */ + S_ST( 'c', 3, 435, 0 ), /* 434 */ + S_ST( 'l', 3, 436, 0 ), /* 435 */ + S_ST( 'o', 3, 437, 0 ), /* 436 */ + S_ST( 'c', 3, 332, 0 ), /* 437 */ + S_ST( 'd', 3, 439, 434 ), /* 438 */ + S_ST( 'i', 3, 440, 0 ), /* 439 */ + S_ST( 's', 3, 333, 0 ), /* 440 */ + S_ST( 'p', 3, 442, 438 ), /* 441 */ + S_ST( 'o', 3, 443, 0 ), /* 442 */ + S_ST( 'l', 3, 334, 0 ), /* 443 */ + S_ST( 'i', 3, 445, 309 ), /* 444 */ + S_ST( 'n', 3, 459, 0 ), /* 445 */ + S_ST( 'c', 3, 447, 0 ), /* 446 */ + S_ST( 'l', 3, 448, 0 ), /* 447 */ + S_ST( 'o', 3, 449, 0 ), /* 448 */ + S_ST( 'c', 3, 335, 0 ), /* 449 */ + S_ST( 'd', 3, 451, 446 ), /* 450 */ + S_ST( 'i', 3, 452, 0 ), /* 451 */ + S_ST( 's', 3, 336, 0 ), /* 452 */ + S_ST( 'i', 3, 454, 450 ), /* 453 */ + S_ST( 'm', 3, 455, 0 ), /* 454 */ + S_ST( 'u', 3, 337, 0 ), /* 455 */ + S_ST( 'p', 3, 457, 453 ), /* 456 */ + S_ST( 'o', 3, 458, 0 ), /* 457 */ + S_ST( 'l', 3, 338, 0 ), /* 458 */ + S_ST( 's', 3, 460, 456 ), /* 459 */ + S_ST( 'a', 3, 461, 0 ), /* 460 */ + S_ST( 'n', 3, 339, 0 ), /* 461 */ + S_ST( 'o', 3, 464, 444 ), /* 462 */ + S_ST( 'd', 3, 340, 0 ), /* 463 */ + S_ST( 'n', 3, 468, 463 ), /* 464 */ + S_ST( 'i', 3, 466, 0 ), /* 465 */ + S_ST( 't', 3, 467, 0 ), /* 466 */ + S_ST( 'o', 3, 341, 0 ), /* 467 */ + S_ST( 't', 3, 342, 465 ), /* 468 */ + S_ST( 's', 3, 470, 462 ), /* 469 */ + S_ST( 's', 3, 471, 0 ), /* 470 */ + S_ST( 'n', 3, 472, 0 ), /* 471 */ + S_ST( 't', 3, 320, 0 ), /* 472 */ + S_ST( 'u', 3, 474, 469 ), /* 473 */ + S_ST( 'l', 3, 475, 0 ), /* 474 */ + S_ST( 't', 3, 476, 0 ), /* 475 */ + S_ST( 'i', 3, 477, 0 ), /* 476 */ + S_ST( 'c', 3, 478, 0 ), /* 477 */ + S_ST( 'a', 3, 479, 0 ), /* 478 */ + S_ST( 's', 3, 480, 0 ), /* 479 */ + S_ST( 't', 3, 481, 0 ), /* 480 */ + S_ST( 'c', 3, 482, 0 ), /* 481 */ + S_ST( 'l', 3, 483, 0 ), /* 482 */ + S_ST( 'i', 3, 484, 0 ), /* 483 */ + S_ST( 'e', 3, 485, 0 ), /* 484 */ + S_ST( 'n', 3, 343, 0 ), /* 485 */ + S_ST( 'n', 3, 517, 292 ), /* 486 */ + S_ST( 'i', 3, 344, 0 ), /* 487 */ + S_ST( 'o', 3, 512, 487 ), /* 488 */ + S_ST( 'l', 3, 490, 0 ), /* 489 */ + S_ST( 'i', 3, 491, 0 ), /* 490 */ + S_ST( 'n', 3, 345, 0 ), /* 491 */ + S_ST( 'm', 3, 493, 489 ), /* 492 */ + S_ST( 'o', 3, 494, 0 ), /* 493 */ + S_ST( 'd', 3, 495, 0 ), /* 494 */ + S_ST( 'i', 3, 496, 0 ), /* 495 */ + S_ST( 'f', 3, 346, 0 ), /* 496 */ + S_ST( 'n', 3, 347, 492 ), /* 497 */ + S_ST( 'p', 3, 499, 497 ), /* 498 */ + S_ST( 'e', 3, 500, 0 ), /* 499 */ + S_ST( 'e', 3, 348, 0 ), /* 500 */ + S_ST( 'q', 3, 502, 498 ), /* 501 */ + S_ST( 'u', 3, 503, 0 ), /* 502 */ + S_ST( 'e', 3, 504, 0 ), /* 503 */ + S_ST( 'r', 3, 349, 0 ), /* 504 */ + S_ST( 's', 3, 506, 501 ), /* 505 */ + S_ST( 'e', 3, 510, 0 ), /* 506 */ + S_ST( 'l', 3, 508, 0 ), /* 507 */ + S_ST( 'e', 3, 509, 0 ), /* 508 */ + S_ST( 'c', 3, 350, 0 ), /* 509 */ + S_ST( 'r', 3, 511, 507 ), /* 510 */ + S_ST( 'v', 3, 351, 0 ), /* 511 */ + S_ST( 't', 3, 513, 505 ), /* 512 */ + S_ST( 'r', 3, 515, 0 ), /* 513 */ + S_ST( 'a', 3, 352, 0 ), /* 514 */ + S_ST( 'u', 3, 516, 514 ), /* 515 */ + S_ST( 's', 3, 353, 0 ), /* 516 */ + S_ST( 't', 3, 354, 488 ), /* 517 */ + S_ST( 'p', 3, 519, 0 ), /* 518 */ + S_ST( 'o', 3, 520, 0 ), /* 519 */ + S_ST( 'r', 3, 355, 0 ), /* 520 */ + S_ST( 's', 3, 522, 518 ), /* 521 */ + S_ST( 'i', 3, 523, 0 ), /* 522 */ + S_ST( 'g', 3, 524, 0 ), /* 523 */ + S_ST( 'n', 3, 525, 0 ), /* 524 */ + S_ST( 'd', 3, 526, 0 ), /* 525 */ + S_ST( 's', 3, 527, 0 ), /* 526 */ + S_ST( 'o', 3, 528, 0 ), /* 527 */ + S_ST( 'c', 3, 529, 0 ), /* 528 */ + S_ST( 'k', 3, 530, 0 ), /* 529 */ + S_ST( 'e', 3, 356, 0 ), /* 530 */ + S_ST( 'o', 3, 532, 486 ), /* 531 */ + S_ST( 'r', 3, 533, 0 ), /* 532 */ + S_ST( 'p', 3, 534, 0 ), /* 533 */ + S_ST( 'h', 3, 535, 0 ), /* 534 */ + S_ST( 'a', 3, 357, 0 ), /* 535 */ + S_ST( 'p', 3, 369, 531 ), /* 536 */ + S_ST( 'a', 3, 538, 0 ), /* 537 */ + S_ST( 'n', 3, 539, 0 ), /* 538 */ + S_ST( 'i', 3, 358, 0 ), /* 539 */ + S_ST( 'e', 3, 541, 537 ), /* 540 */ + S_ST( 'e', 3, 359, 0 ), /* 541 */ + S_ST( 's', 3, 543, 0 ), /* 542 */ + S_ST( 't', 3, 544, 0 ), /* 543 */ + S_ST( 'a', 3, 545, 0 ), /* 544 */ + S_ST( 't', 3, 360, 0 ), /* 545 */ + S_ST( 'h', 3, 547, 540 ), /* 546 */ + S_ST( 'o', 3, 548, 0 ), /* 547 */ + S_ST( 'n', 3, 361, 0 ), /* 548 */ + S_ST( 'i', 3, 362, 546 ), /* 549 */ + S_ST( 'f', 3, 551, 0 ), /* 550 */ + S_ST( 'i', 3, 552, 0 ), /* 551 */ + S_ST( 'l', 3, 363, 0 ), /* 552 */ + S_ST( 'o', 3, 555, 549 ), /* 553 */ + S_ST( 'o', 3, 364, 0 ), /* 554 */ + S_ST( 'r', 3, 365, 554 ), /* 555 */ + S_ST( 'r', 3, 563, 553 ), /* 556 */ + S_ST( 'e', 3, 561, 0 ), /* 557 */ + S_ST( 'e', 3, 559, 0 ), /* 558 */ + S_ST( 'm', 3, 560, 0 ), /* 559 */ + S_ST( 'p', 3, 366, 0 ), /* 560 */ + S_ST( 'f', 3, 562, 558 ), /* 561 */ + S_ST( 'e', 3, 367, 0 ), /* 562 */ + S_ST( 'o', 3, 576, 557 ), /* 563 */ + S_ST( 'c', 3, 565, 0 ), /* 564 */ + S_ST( '_', 3, 566, 0 ), /* 565 */ + S_ST( 'd', 3, 567, 0 ), /* 566 */ + S_ST( 'e', 3, 568, 0 ), /* 567 */ + S_ST( 'l', 3, 569, 0 ), /* 568 */ + S_ST( 'a', 3, 420, 0 ), /* 569 */ + S_ST( 'p', 3, 571, 564 ), /* 570 */ + S_ST( '_', 3, 572, 0 ), /* 571 */ + S_ST( 'd', 3, 573, 0 ), /* 572 */ + S_ST( 'e', 3, 574, 0 ), /* 573 */ + S_ST( 'l', 3, 575, 0 ), /* 574 */ + S_ST( 'a', 3, 419, 0 ), /* 575 */ + S_ST( 't', 3, 577, 570 ), /* 576 */ + S_ST( 'o', 3, 578, 0 ), /* 577 */ + S_ST( 's', 3, 579, 0 ), /* 578 */ + S_ST( 't', 3, 580, 0 ), /* 579 */ + S_ST( 'a', 3, 581, 0 ), /* 580 */ + S_ST( 't', 3, 368, 0 ), /* 581 */ + S_ST( 'q', 3, 583, 536 ), /* 582 */ + S_ST( 'o', 3, 370, 0 ), /* 583 */ + S_ST( 'r', 3, 596, 582 ), /* 584 */ + S_ST( 'a', 3, 591, 0 ), /* 585 */ + S_ST( 'n', 3, 587, 0 ), /* 586 */ + S_ST( 'd', 3, 588, 0 ), /* 587 */ + S_ST( 'f', 3, 589, 0 ), /* 588 */ + S_ST( 'i', 3, 590, 0 ), /* 589 */ + S_ST( 'l', 3, 371, 0 ), /* 590 */ + S_ST( 'w', 3, 592, 586 ), /* 591 */ + S_ST( 's', 3, 593, 0 ), /* 592 */ + S_ST( 't', 3, 594, 0 ), /* 593 */ + S_ST( 'a', 3, 595, 0 ), /* 594 */ + S_ST( 't', 3, 372, 0 ), /* 595 */ + S_ST( 'e', 3, 611, 585 ), /* 596 */ + S_ST( 'f', 3, 598, 0 ), /* 597 */ + S_ST( 'i', 3, 373, 0 ), /* 598 */ + S_ST( 'q', 3, 600, 597 ), /* 599 */ + S_ST( 'u', 3, 601, 0 ), /* 600 */ + S_ST( 'e', 3, 602, 0 ), /* 601 */ + S_ST( 's', 3, 603, 0 ), /* 602 */ + S_ST( 't', 3, 604, 0 ), /* 603 */ + S_ST( 'k', 3, 605, 0 ), /* 604 */ + S_ST( 'e', 3, 374, 0 ), /* 605 */ + S_ST( 's', 3, 607, 599 ), /* 606 */ + S_ST( 't', 3, 608, 0 ), /* 607 */ + S_ST( 'r', 3, 609, 0 ), /* 608 */ + S_ST( 'i', 3, 610, 0 ), /* 609 */ + S_ST( 'c', 3, 375, 0 ), /* 610 */ + S_ST( 'v', 3, 612, 606 ), /* 611 */ + S_ST( 'o', 3, 613, 0 ), /* 612 */ + S_ST( 'k', 3, 376, 0 ), /* 613 */ + S_ST( 's', 3, 674, 584 ), /* 614 */ + S_ST( 'a', 3, 616, 0 ), /* 615 */ + S_ST( 'v', 3, 617, 0 ), /* 616 */ + S_ST( 'e', 3, 618, 0 ), /* 617 */ + S_ST( 'c', 3, 619, 0 ), /* 618 */ + S_ST( 'o', 3, 620, 0 ), /* 619 */ + S_ST( 'n', 3, 621, 0 ), /* 620 */ + S_ST( 'f', 3, 622, 0 ), /* 621 */ + S_ST( 'i', 3, 623, 0 ), /* 622 */ + S_ST( 'g', 3, 624, 0 ), /* 623 */ + S_ST( 'd', 3, 625, 0 ), /* 624 */ + S_ST( 'i', 3, 377, 0 ), /* 625 */ + S_ST( 'e', 3, 636, 615 ), /* 626 */ + S_ST( 'r', 3, 628, 0 ), /* 627 */ + S_ST( 'v', 3, 629, 0 ), /* 628 */ + S_ST( 'e', 3, 378, 0 ), /* 629 */ + S_ST( '_', 3, 631, 0 ), /* 630 */ + S_ST( 'o', 3, 632, 0 ), /* 631 */ + S_ST( 'f', 3, 633, 0 ), /* 632 */ + S_ST( 'f', 3, 634, 0 ), /* 633 */ + S_ST( 's', 3, 635, 0 ), /* 634 */ + S_ST( 'e', 3, 414, 0 ), /* 635 */ + S_ST( 't', 3, 637, 627 ), /* 636 */ + S_ST( 'v', 3, 638, 0 ), /* 637 */ + S_ST( 'a', 3, 379, 0 ), /* 638 */ + S_ST( 'i', 3, 641, 626 ), /* 639 */ + S_ST( 'g', 3, 380, 0 ), /* 640 */ + S_ST( 'm', 3, 642, 640 ), /* 641 */ + S_ST( 'u', 3, 643, 0 ), /* 642 */ + S_ST( 'l', 3, 644, 0 ), /* 643 */ + S_ST( 'a', 3, 645, 0 ), /* 644 */ + S_ST( 't', 3, 646, 0 ), /* 645 */ + S_ST( 'i', 3, 647, 411 ), /* 646 */ + S_ST( 'o', 3, 648, 0 ), /* 647 */ + S_ST( 'n', 3, 649, 0 ), /* 648 */ + S_ST( '_', 3, 650, 0 ), /* 649 */ + S_ST( 'd', 3, 651, 0 ), /* 650 */ + S_ST( 'u', 3, 652, 0 ), /* 651 */ + S_ST( 'r', 3, 653, 0 ), /* 652 */ + S_ST( 'a', 3, 654, 0 ), /* 653 */ + S_ST( 't', 3, 655, 0 ), /* 654 */ + S_ST( 'i', 3, 656, 0 ), /* 655 */ + S_ST( 'o', 3, 413, 0 ), /* 656 */ + S_ST( 't', 3, 670, 639 ), /* 657 */ + S_ST( 'a', 3, 659, 0 ), /* 658 */ + S_ST( 't', 3, 382, 0 ), /* 659 */ + S_ST( 'i', 3, 661, 0 ), /* 660 */ + S_ST( 's', 3, 662, 0 ), /* 661 */ + S_ST( 't', 3, 663, 0 ), /* 662 */ + S_ST( 'i', 3, 664, 0 ), /* 663 */ + S_ST( 'c', 3, 381, 0 ), /* 664 */ + S_ST( 'd', 3, 666, 0 ), /* 665 */ + S_ST( 'i', 3, 383, 0 ), /* 666 */ + S_ST( 'e', 3, 384, 658 ), /* 667 */ + S_ST( 'o', 3, 669, 0 ), /* 668 */ + S_ST( 'u', 3, 385, 0 ), /* 669 */ + S_ST( 'r', 3, 671, 667 ), /* 670 */ + S_ST( 'a', 3, 672, 0 ), /* 671 */ + S_ST( 't', 3, 673, 0 ), /* 672 */ + S_ST( 'u', 3, 386, 0 ), /* 673 */ + S_ST( 'y', 3, 675, 657 ), /* 674 */ + S_ST( 's', 3, 676, 0 ), /* 675 */ + S_ST( 's', 3, 677, 0 ), /* 676 */ + S_ST( 't', 3, 678, 0 ), /* 677 */ + S_ST( 'a', 3, 679, 0 ), /* 678 */ + S_ST( 't', 3, 388, 0 ), /* 679 */ + S_ST( 't', 3, 706, 614 ), /* 680 */ + S_ST( 'i', 3, 692, 0 ), /* 681 */ + S_ST( 'c', 3, 389, 0 ), /* 682 */ + S_ST( 'm', 3, 685, 682 ), /* 683 */ + S_ST( 'e', 3, 391, 0 ), /* 684 */ + S_ST( 'i', 3, 686, 684 ), /* 685 */ + S_ST( 'n', 3, 687, 0 ), /* 686 */ + S_ST( 'g', 3, 688, 0 ), /* 687 */ + S_ST( 's', 3, 689, 0 ), /* 688 */ + S_ST( 't', 3, 690, 0 ), /* 689 */ + S_ST( 'a', 3, 691, 0 ), /* 690 */ + S_ST( 't', 3, 392, 0 ), /* 691 */ + S_ST( 'n', 3, 693, 683 ), /* 692 */ + S_ST( 'k', 3, 694, 0 ), /* 693 */ + S_ST( 'e', 3, 393, 0 ), /* 694 */ + S_ST( 'o', 3, 394, 681 ), /* 695 */ + S_ST( 'r', 3, 698, 695 ), /* 696 */ + S_ST( 'a', 3, 395, 0 ), /* 697 */ + S_ST( 'u', 3, 699, 697 ), /* 698 */ + S_ST( 's', 3, 700, 396 ), /* 699 */ + S_ST( 't', 3, 701, 0 ), /* 700 */ + S_ST( 'e', 3, 702, 0 ), /* 701 */ + S_ST( 'd', 3, 703, 0 ), /* 702 */ + S_ST( 'k', 3, 704, 0 ), /* 703 */ + S_ST( 'e', 3, 397, 0 ), /* 704 */ + S_ST( 't', 3, 398, 696 ), /* 705 */ + S_ST( 'y', 3, 707, 705 ), /* 706 */ + S_ST( 'p', 3, 399, 0 ), /* 707 */ + S_ST( 'u', 3, 709, 680 ), /* 708 */ + S_ST( 'n', 3, 715, 0 ), /* 709 */ + S_ST( 'c', 3, 711, 0 ), /* 710 */ + S_ST( 'o', 3, 712, 0 ), /* 711 */ + S_ST( 'n', 3, 713, 0 ), /* 712 */ + S_ST( 'f', 3, 714, 0 ), /* 713 */ + S_ST( 'i', 3, 400, 0 ), /* 714 */ + S_ST( 'p', 3, 716, 710 ), /* 715 */ + S_ST( 'e', 3, 717, 0 ), /* 716 */ + S_ST( 'e', 3, 401, 0 ), /* 717 */ + S_ST( 'v', 3, 719, 708 ), /* 718 */ + S_ST( 'e', 3, 720, 0 ), /* 719 */ + S_ST( 'r', 3, 721, 0 ), /* 720 */ + S_ST( 's', 3, 722, 0 ), /* 721 */ + S_ST( 'i', 3, 723, 0 ), /* 722 */ + S_ST( 'o', 3, 402, 0 ), /* 723 */ + S_ST( 'w', 3, 731, 718 ), /* 724 */ + S_ST( 'a', 3, 726, 0 ), /* 725 */ + S_ST( 'n', 3, 727, 0 ), /* 726 */ + S_ST( 'd', 3, 728, 0 ), /* 727 */ + S_ST( 'e', 3, 417, 0 ), /* 728 */ + S_ST( 'e', 3, 730, 725 ), /* 729 */ + S_ST( 'e', 3, 404, 0 ), /* 730 */ + S_ST( 'i', 3, 732, 729 ), /* 731 */ + S_ST( 'l', 3, 733, 0 ), /* 732 */ + S_ST( 'd', 3, 734, 0 ), /* 733 */ + S_ST( 'c', 3, 735, 0 ), /* 734 */ + S_ST( 'a', 3, 736, 0 ), /* 735 */ + S_ST( 'r', 3, 405, 0 ), /* 736 */ + S_ST( 'x', 3, 738, 724 ), /* 737 */ + S_ST( 'l', 3, 739, 0 ), /* 738 */ + S_ST( 'e', 3, 740, 0 ), /* 739 */ + S_ST( 'a', 3, 741, 0 ), /* 740 */ + S_ST( 'v', 3, 406, 0 ), /* 741 */ + S_ST( 'y', 3, 743, 737 ), /* 742 initial state */ + S_ST( 'e', 3, 744, 0 ), /* 743 */ + S_ST( 'a', 3, 407, 0 ) /* 744 */ +}; + diff -urN src/contrib/ntp/ntpd/ntp_loopfilter.c src.ntp/contrib/ntp/ntpd/ntp_loopfilter.c --- src/contrib/ntp/ntpd/ntp_loopfilter.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/ntp_loopfilter.c 2009-12-09 08:36:36.000000000 +0100 @@ -40,13 +40,15 @@ #define CLOCK_PHI 15e-6 /* max frequency error (s/s) */ #define CLOCK_PLL 16. /* PLL loop gain (log2) */ #define CLOCK_AVG 8. /* parameter averaging constant */ -#define CLOCK_FLL (NTP_MAXPOLL + CLOCK_AVG) /* FLL loop gain */ -#define CLOCK_ALLAN 1500. /* compromise Allan intercept (s) */ +#define CLOCK_FLL .25 /* FLL loop gain */ +#define CLOCK_ALLAN 11 /* Allan intercept (log2 s) */ #define CLOCK_DAY 86400. /* one day in seconds (s) */ #define CLOCK_JUNE (CLOCK_DAY * 30) /* June in seconds (s) */ #define CLOCK_LIMIT 30 /* poll-adjust threshold */ #define CLOCK_PGATE 4. /* poll-adjust gate */ #define PPS_MAXAGE 120 /* kernel pps signal timeout (s) */ +#define FREQTOD(x) ((x) / 65536e6) /* NTP to double */ +#define DTOFREQ(x) ((int32)((x) * 65536e6)) /* double to NTP */ /* * Clock discipline state machine. This is used to control the @@ -54,32 +56,25 @@ * timewarp. * * State < step > step Comments - * ==================================================== - * NSET FREQ step, FREQ no ntp.drift + * ======================================================== + * NSET FREQ step, FREQ freq not set * - * FSET SYNC step, SYNC ntp.drift + * FSET SYNC step, SYNC freq set * - * FREQ if (mu < 900) if (mu < 900) set freq + * FREQ if (mu < 900) if (mu < 900) set freq direct * ignore ignore * else else * freq, SYNC freq, step, SYNC * - * SYNC SYNC if (mu < 900) adjust phase/freq - * ignore - * else - * SPIK + * SYNC SYNC SPIK, ignore adjust phase/freq * - * SPIK SYNC step, SYNC set phase + * SPIK SYNC if (mu < 900) adjust phase/freq + * ignore + * step, SYNC */ -#define S_NSET 0 /* clock never set */ -#define S_FSET 1 /* frequency set from the drift file */ -#define S_SPIK 2 /* spike detected */ -#define S_FREQ 3 /* frequency mode */ -#define S_SYNC 4 /* clock synchronized */ - /* * Kernel PLL/PPS state machine. This is used with the kernel PLL - * modifications described in the README.kernel file. + * modifications described in the documentation. * * If kernel support for the ntp_adjtime() system call is available, the * ntp_control flag is set. The ntp_enable and kern_enable flags can be @@ -97,54 +92,55 @@ * includes TAI offset and is identified by the symbol NTP_API with * value 4. * - * Each update to a prefer peer sets pps_stratum if it survives the - * intersection algorithm and its time is within range. The PPS time - * discipline is enabled (STA_PPSTIME bit set in the status word) when - * pps_stratum is true and the PPS frequency discipline is enabled. If - * the PPS time discipline is enabled and the kernel reports a PPS - * signal is present, the pps_control variable is set to the current - * time. If the current time is later than pps_control by PPS_MAXAGE - * (120 s), this variable is set to zero. + * Each PPS time/frequency discipline can be enabled by the atom driver + * or another driver. If enabled, the STA_PPSTIME and STA_FREQ bits are + * set in the kernel status word; otherwise, these bits are cleared. + * These bits are also cleard if the kernel reports an error. * * If an external clock is present, the clock driver sets STA_CLK in the * status word. When the local clock driver sees this bit, it updates * via this routine, which then calls ntp_adjtime() with the STA_PLL bit * set to zero, in which case the system clock is not adjusted. This is * also a signal for the external clock driver to discipline the system - * clock. + * clock. Unless specified otherwise, all times are in seconds. */ /* * Program variables that can be tinkered. */ -double clock_max = CLOCK_MAX; /* step threshold (s) */ -double clock_minstep = CLOCK_MINSTEP; /* stepout threshold (s) */ -double clock_panic = CLOCK_PANIC; /* panic threshold (s) */ +double clock_max = CLOCK_MAX; /* step threshold */ +double clock_minstep = CLOCK_MINSTEP; /* stepout threshold */ +double clock_panic = CLOCK_PANIC; /* panic threshold */ double clock_phi = CLOCK_PHI; /* dispersion rate (s/s) */ -double allan_xpt = CLOCK_ALLAN; /* Allan intercept (s) */ +u_char allan_xpt = CLOCK_ALLAN; /* Allan intercept (log2 s) */ /* * Program variables */ -static double clock_offset; /* offset (s) */ -double clock_jitter; /* offset jitter (s) */ +static double clock_offset; /* offset */ +double clock_jitter; /* offset jitter */ double drift_comp; /* frequency (s/s) */ double clock_stability; /* frequency stability (wander) (s/s) */ -u_long sys_clocktime; /* last system clock update */ -u_long pps_control; /* last pps update */ -u_long sys_tai; /* UTC offset from TAI (s) */ -static void rstclock P((int, u_long, double)); /* transition function */ +double clock_codec; /* audio codec frequency (samples/s) */ +static u_long clock_epoch; /* last update */ +u_int sys_tai; /* TAI offset from UTC */ +static void rstclock (int, double); /* transition function */ +static double direct_freq(double); /* direct set frequency */ +static void set_freq(double); /* set frequency */ #ifdef KERNEL_PLL -struct timex ntv; /* kernel API parameters */ -int pll_status; /* status bits for kernel pll */ +static struct timex ntv; /* ntp_adjtime() parameters */ +int pll_status; /* last kernel status bits */ +#if defined(STA_NANO) && NTP_API == 4 +static u_int loop_tai; /* last TAI offset */ +#endif /* STA_NANO */ #endif /* KERNEL_PLL */ /* * Clock state machine control flags */ -int ntp_enable; /* clock discipline enabled */ +int ntp_enable = 1; /* clock discipline enabled */ int pll_control; /* kernel support available */ -int kern_enable; /* kernel support enabled */ +int kern_enable = 1; /* kernel support enabled */ int pps_enable; /* kernel PPS discipline enabled */ int ext_enable; /* external clock enabled */ int pps_stratum; /* pps stratum */ @@ -155,9 +151,10 @@ * Clock state machine variables */ int state; /* clock discipline state */ -u_char sys_poll = NTP_MINDPOLL; /* time constant/poll (log2 s) */ +u_char sys_poll; /* time constant/poll (log2 s) */ int tc_counter; /* jiggle counter */ double last_offset; /* last offset (s) */ +static u_long last_step; /* last clock step */ /* * Huff-n'-puff filter variables @@ -172,7 +169,7 @@ #define MOD_BITS (MOD_OFFSET | MOD_MAXERROR | MOD_ESTERROR | \ MOD_STATUS | MOD_TIMECONST) #ifdef SIGSYS -static void pll_trap P((int)); /* configuration trap */ +static void pll_trap (int); /* configuration trap */ static struct sigaction sigsys; /* current sigaction status */ static struct sigaction newsigsys; /* new sigaction status */ static sigjmp_buf env; /* environment var. for pll_trap() */ @@ -186,11 +183,9 @@ init_loopfilter(void) { /* - * Initialize state variables. Initially, we expect no drift - * file, so set the state to S_NSET. If a drift file is present, - * it will be detected later and the state set to S_FSET. + * Initialize state variables. */ - rstclock(S_NSET, 0, 0); + sys_poll = ntp_minpoll; clock_jitter = LOGTOD(sys_precision); } @@ -204,7 +199,7 @@ * 2 clock was stepped * * LOCKCLOCK: The only thing this routine does is set the - * sys_rootdispersion variable equal to the peer dispersion. + * sys_rootdisp variable equal to the peer dispersion. */ int local_clock( @@ -213,29 +208,17 @@ ) { int rval; /* return code */ - u_long mu; /* interval since last update (s) */ - double flladj; /* FLL frequency adjustment (ppm) */ - double plladj; /* PLL frequency adjustment (ppm) */ - double clock_frequency; /* clock frequency adjustment (ppm) */ + int osys_poll; /* old system poll */ + double mu; /* interval since last update */ + double clock_frequency; /* clock frequency */ double dtemp, etemp; /* double temps */ -#ifdef OPENSSL - u_int32 *tpt; - int i; - u_int len; - long togo; -#endif /* OPENSSL */ + char tbuf[80]; /* report buffer */ /* * If the loop is opened or the NIST LOCKCLOCK is in use, * monitor and record the offsets anyway in order to determine * the open-loop response and then go home. */ -#ifdef DEBUG - if (debug) - printf( - "local_clock: assocID %d offset %.9f freq %.3f state %d\n", - peer->associd, fp_offset, drift_comp * 1e6, state); -#endif #ifdef LOCKCLOCK return (0); @@ -257,33 +240,31 @@ */ if (fabs(fp_offset) > clock_panic && clock_panic > 0 && !allow_panic) { - msyslog(LOG_ERR, - "time correction of %.0f seconds exceeds sanity limit (%.0f); set clock manually to the correct UTC time.", + snprintf(tbuf, sizeof(tbuf), + "%+.0f s; set clock manually within %.0f s.", fp_offset, clock_panic); + report_event(EVNT_SYSFAULT, NULL, tbuf); return (-1); } /* - * If simulating ntpdate, set the clock directly, rather than - * using the discipline. The clock_max defines the step - * threshold, above which the clock will be stepped instead of - * slewed. The value defaults to 128 ms, but can be set to even - * unreasonable values. If set to zero, the clock will never be - * stepped. Note that a slew will persist beyond the life of - * this program. - * - * Note that if ntpdate is active, the terminal does not detach, - * so the termination comments print directly to the console. + * This section simulates ntpdate. If the offset exceeds the + * step threshold (128 ms), step the clock to that time and + * exit. Othewise, slew the clock to that time and exit. Note + * that the slew will persist and eventually complete beyond the + * life of this program. Note that while ntpdate is active, the + * terminal does not detach, so the termination message prints + * directly to the terminal. */ if (mode_ntpdate) { if (fabs(fp_offset) > clock_max && clock_max > 0) { step_systime(fp_offset); - msyslog(LOG_NOTICE, "time reset %+.6f s", + msyslog(LOG_NOTICE, "ntpd: time set %+.6f s", fp_offset); printf("ntpd: time set %+.6fs\n", fp_offset); } else { adj_systime(fp_offset); - msyslog(LOG_NOTICE, "time slew %+.6f s", + msyslog(LOG_NOTICE, "ntpd: time slew %+.6f s", fp_offset); printf("ntpd: time slew %+.6fs\n", fp_offset); } @@ -299,12 +280,8 @@ * is most effective if the delays are highly assymetric and * clockhopping is avoided and the clock frequency wander is * relatively small. - * - * Note either there is no prefer peer or this update is from - * the prefer peer. */ - if (sys_huffpuff != NULL && (sys_prefer == NULL || sys_prefer == - peer)) { + if (sys_huffpuff != NULL) { if (peer->delay < sys_huffpuff[sys_huffptr]) sys_huffpuff[sys_huffptr] = peer->delay; if (peer->delay < sys_mindly) @@ -323,100 +300,104 @@ } /* - * Clock state machine transition function. This is where the - * action is and defines how the system reacts to large phase - * and frequency errors. There are two main regimes: when the - * offset exceeds the step threshold and when it does not. - * However, if the step threshold is set to zero, a step will - * never occur. See the instruction manual for the details how - * these actions interact with the command line options. + * Clock state machine transition function which defines how the + * system reacts to large phase and frequency excursion. There + * are two main regimes: when the offset exceeds the step + * threshold (128 ms) and when it does not. Under certain + * conditions updates are suspended until the stepout theshold + * (900 s) is exceeded. See the documentation on how these + * thresholds interact with commands and command line options. * - * Note the system poll is set to minpoll only if the clock is - * stepped. Note also the kernel is disabled if step is - * disabled or greater than 0.5 s. - */ - clock_frequency = flladj = plladj = 0; - mu = peer->epoch - sys_clocktime; - if (clock_max == 0 || clock_max > 0.5) - kern_enable = 0; + * Note the kernel is disabled if step is disabled or greater + * than 0.5 s or in ntpdate mode. + */ + osys_poll = sys_poll; + if (sys_poll < peer->minpoll) + sys_poll = peer->minpoll; + if (sys_poll > peer->maxpoll) + sys_poll = peer->maxpoll; + mu = current_time - clock_epoch; + clock_frequency = drift_comp; rval = 1; if (fabs(fp_offset) > clock_max && clock_max > 0) { switch (state) { /* - * In S_SYNC state we ignore the first outlyer amd - * switch to S_SPIK state. + * In SYNC state we ignore the first outlyer amd switch + * to SPIK state. */ - case S_SYNC: - state = S_SPIK; + case EVNT_SYNC: + snprintf(tbuf, sizeof(tbuf), "%+.6f s", + fp_offset); + report_event(EVNT_SPIK, NULL, tbuf); + state = EVNT_SPIK; return (0); /* - * In S_FREQ state we ignore outlyers and inlyers. At - * the first outlyer after the stepout threshold, - * compute the apparent frequency correction and step - * the phase. + * In FREQ state we ignore outlyers and inlyers. At the + * first outlyer after the stepout threshold, compute + * the apparent frequency correction and step the phase. */ - case S_FREQ: + case EVNT_FREQ: if (mu < clock_minstep) return (0); - clock_frequency = (fp_offset - clock_offset) / - mu; + clock_frequency = direct_freq(fp_offset); /* fall through to S_SPIK */ /* - * In S_SPIK state we ignore succeeding outlyers until + * In SPIK state we ignore succeeding outlyers until * either an inlyer is found or the stepout threshold is * exceeded. */ - case S_SPIK: + case EVNT_SPIK: if (mu < clock_minstep) return (0); /* fall through to default */ /* - * We get here by default in S_NSET and S_FSET states - * and from above in S_FREQ or S_SPIK states. + * We get here by default in NSET and FSET states and + * from above in FREQ or SPIK states. * - * In S_NSET state an initial frequency correction is - * not available, usually because the frequency file has - * not yet been written. Since the time is outside the - * step threshold, the clock is stepped. The frequency - * will be set directly following the stepout interval. + * In NSET state an initial frequency correction is not + * available, usually because the frequency file has not + * yet been written. Since the time is outside the step + * threshold, the clock is stepped. The frequency will + * be set directly following the stepout interval. * - * In S_FSET state the initial frequency has been set - * from the frequency file. Since the time is outside - * the step threshold, the clock is stepped immediately, + * In FSET state the initial frequency has been set from + * the frequency file. Since the time is outside the + * step threshold, the clock is stepped immediately, * rather than after the stepout interval. Guys get - * nervous if it takes 17 minutes to set the clock for + * nervous if it takes 15 minutes to set the clock for * the first time. * - * In S_FREQ and S_SPIK states the stepout threshold has + * In FREQ and SPIK states the stepout threshold has * expired and the phase is still above the step * threshold. Note that a single spike greater than the - * step threshold is always suppressed, even at the - * longer poll intervals. + * step threshold is always suppressed, even with a + * long time constant. */ default: - step_systime(fp_offset); - msyslog(LOG_NOTICE, "time reset %+.6f s", + snprintf(tbuf, sizeof(tbuf), "%+.6f s", fp_offset); + report_event(EVNT_CLOCKRESET, NULL, tbuf); + step_systime(fp_offset); reinit_timer(); tc_counter = 0; - sys_poll = NTP_MINPOLL; - sys_tai = 0; clock_jitter = LOGTOD(sys_precision); rval = 2; - if (state == S_NSET) { - rstclock(S_FREQ, peer->epoch, 0); + if (state == EVNT_NSET || (current_time - + last_step) < clock_minstep * 2) { + rstclock(EVNT_FREQ, 0); return (rval); } + last_step = current_time; break; } - rstclock(S_SYNC, peer->epoch, 0); + rstclock(EVNT_SYNC, 0); } else { /* @@ -432,105 +413,76 @@ switch (state) { /* - * In S_NSET state this is the first update received and + * In NSET state this is the first update received and * the frequency has not been initialized. Adjust the * phase, but do not adjust the frequency until after * the stepout threshold. */ - case S_NSET: - rstclock(S_FREQ, peer->epoch, fp_offset); + case EVNT_NSET: + rstclock(EVNT_FREQ, fp_offset); break; /* - * In S_FSET state this is the first update received and + * In FSET state this is the first update received and * the frequency has been initialized. Adjust the phase, * but do not adjust the frequency until the next * update. */ - case S_FSET: - rstclock(S_SYNC, peer->epoch, fp_offset); + case EVNT_FSET: + rstclock(EVNT_SYNC, fp_offset); break; /* - * In S_FREQ state ignore updates until the stepout - * threshold. After that, correct the phase and - * frequency and switch to S_SYNC state. + * In FREQ state ignore updates until the stepout + * threshold. After that, compute the new frequency, but + * do not adjust the phase or frequency until the next + * update. */ - case S_FREQ: + case EVNT_FREQ: if (mu < clock_minstep) return (0); - clock_frequency = (fp_offset - clock_offset) / - mu; - rstclock(S_SYNC, peer->epoch, fp_offset); + clock_frequency = direct_freq(fp_offset); + rstclock(EVNT_SYNC, 0); break; + /* - * We get here by default in S_SYNC and S_SPIK states. - * Here we compute the frequency update due to PLL and - * FLL contributions. + * We get here by default in SYNC and SPIK states. Here + * we compute the frequency update due to PLL and FLL + * contributions. */ default: allow_panic = FALSE; /* * The FLL and PLL frequency gain constants - * depend on the poll interval and Allan + * depend on the time constant and Allan * intercept. The PLL is always used, but - * becomes ineffective above the Allan - * intercept. The FLL is not used below one-half - * the Allan intercept. Above that the loop gain - * increases in steps to 1 / CLOCK_AVG. + * becomes ineffective above the Allan intercept + * where the FLL becomes effective. */ - if (ULOGTOD(sys_poll) > allan_xpt / 2) { - dtemp = CLOCK_FLL - sys_poll; - flladj = (fp_offset - clock_offset) / - (max(mu, allan_xpt) * dtemp); - } + if (sys_poll >= allan_xpt) + clock_frequency += (fp_offset - + clock_offset) / + max(ULOGTOD(sys_poll), mu) * + CLOCK_FLL; /* - * For the PLL the integration interval - * (numerator) is the minimum of the update - * interval and poll interval. This allows - * oversampling, but not undersampling. + * The PLL frequency gain (numerator) depends on + * the minimum of the update interval and Allan + * intercept. This reduces the PLL gain when the + * FLL becomes effective. */ - etemp = min(mu, (u_long)ULOGTOD(sys_poll)); + etemp = min(ULOGTOD(allan_xpt), mu); dtemp = 4 * CLOCK_PLL * ULOGTOD(sys_poll); - plladj = fp_offset * etemp / (dtemp * dtemp); - rstclock(S_SYNC, peer->epoch, fp_offset); + clock_frequency += fp_offset * etemp / (dtemp * + dtemp); + rstclock(EVNT_SYNC, fp_offset); break; } } -#ifdef OPENSSL - /* - * Scan the loopsecond table to determine the TAI offset. If - * there is a scheduled leap in future, set the leap warning, - * but only if less than 30 days before the leap. - */ - tpt = (u_int32 *)tai_leap.ptr; - len = ntohl(tai_leap.vallen) / sizeof(u_int32); - if (tpt != NULL) { - for (i = 0; i < len; i++) { - togo = (long)ntohl(tpt[i]) - - (long)peer->rec.l_ui; - if (togo > 0) { - if (togo < CLOCK_JUNE) - leap_next |= LEAP_ADDSECOND; - break; - } - } -#if defined(STA_NANO) && NTP_API == 4 - if (pll_control && kern_enable && sys_tai == 0) { - memset(&ntv, 0, sizeof(ntv)); - ntv.modes = MOD_TAI; - ntv.constant = i + TAI_1972 - 1; - ntp_adjtime(&ntv); - } -#endif /* STA_NANO */ - sys_tai = i + TAI_1972 - 1; - } -#endif /* OPENSSL */ #ifdef KERNEL_PLL /* * This code segment works when clock adjustments are made using @@ -564,9 +516,6 @@ if (ext_enable) { ntv.modes = MOD_STATUS; } else { - struct tm *tm = NULL; - time_t tstamp; - #ifdef STA_NANO ntv.modes = MOD_BITS | MOD_NANO; #else /* STA_NANO */ @@ -585,73 +534,41 @@ dtemp); ntv.constant = sys_poll - 4; #endif /* STA_NANO */ - - /* - * The frequency is set directly only if - * clock_frequency is nonzero coming out of FREQ - * state. - */ - if (clock_frequency != 0) { - ntv.modes |= MOD_FREQUENCY; - ntv.freq = (int32)((clock_frequency + - drift_comp) * 65536e6); - } ntv.esterror = (u_int32)(clock_jitter * 1e6); ntv.maxerror = (u_int32)((sys_rootdelay / 2 + - sys_rootdispersion) * 1e6); + sys_rootdisp) * 1e6); ntv.status = STA_PLL; /* - * Set the leap bits in the status word, but - * only on the last day of June or December. - */ - tstamp = peer->rec.l_ui - JAN_1970; - tm = gmtime(&tstamp); - if (tm != NULL) { - if ((tm->tm_mon + 1 == 6 && - tm->tm_mday == 30) || (tm->tm_mon + - 1 == 12 && tm->tm_mday == 31)) { - if (leap_next & LEAP_ADDSECOND) - ntv.status |= STA_INS; - else if (leap_next & - LEAP_DELSECOND) - ntv.status |= STA_DEL; - } - } - - /* - * If the PPS signal is up and enabled, light - * the frequency bit. If the PPS driver is - * working, light the phase bit as well. If not, - * douse the lights, since somebody else may - * have left the switch on. + * Enable/disable the PPS if requested. */ - if (pps_enable && pll_status & STA_PPSSIGNAL) { - ntv.status |= STA_PPSFREQ; - if (pps_stratum < STRATUM_UNSPEC) - ntv.status |= STA_PPSTIME; + if (pps_enable) { + if (!(pll_status & STA_PPSTIME)) + report_event(EVNT_KERN, + NULL, "PPS enabled"); + ntv.status |= STA_PPSTIME | STA_PPSFREQ; } else { - ntv.status &= ~(STA_PPSFREQ | - STA_PPSTIME); + if (pll_status & STA_PPSTIME) + report_event(EVNT_KERN, + NULL, "PPS disabled"); + ntv.status &= ~(STA_PPSTIME | + STA_PPSFREQ); } + if (sys_leap == LEAP_ADDSECOND) + ntv.status |= STA_INS; + else if (sys_leap == LEAP_DELSECOND) + ntv.status |= STA_DEL; } /* * Pass the stuff to the kernel. If it squeals, turn off - * the pig. In any case, fetch the kernel offset and - * frequency and pretend we did it here. + * the pps. In any case, fetch the kernel offset, + * frequency and jitter. */ if (ntp_adjtime(&ntv) == TIME_ERROR) { - NLOG(NLOG_SYNCEVENT | NLOG_SYSEVENT) - msyslog(LOG_NOTICE, - "kernel time sync error %04x", ntv.status); - ntv.status &= ~(STA_PPSFREQ | STA_PPSTIME); - } else { - if ((ntv.status ^ pll_status) & ~STA_FLL) - NLOG(NLOG_SYNCEVENT | NLOG_SYSEVENT) - msyslog(LOG_NOTICE, - "kernel time sync status change %04x", - ntv.status); + if (!(ntv.status & STA_PPSSIGNAL)) + report_event(EVNT_KERN, NULL, + "PPS no signal"); } pll_status = ntv.status; #ifdef STA_NANO @@ -659,42 +576,39 @@ #else /* STA_NANO */ clock_offset = ntv.offset / 1e6; #endif /* STA_NANO */ - clock_frequency = ntv.freq / 65536e6; - flladj = plladj = 0; + clock_frequency = FREQTOD(ntv.freq); /* * If the kernel PPS is lit, monitor its performance. */ if (ntv.status & STA_PPSTIME) { - pps_control = current_time; #ifdef STA_NANO clock_jitter = ntv.jitter / 1e9; #else /* STA_NANO */ clock_jitter = ntv.jitter / 1e6; #endif /* STA_NANO */ } - } else { -#endif /* KERNEL_PLL */ - + +#if defined(STA_NANO) && NTP_API == 4 /* - * We get here if the kernel discipline is not enabled. - * Adjust the clock frequency as the sum of the directly - * computed frequency (if measured) and the PLL and FLL - * increments. + * If the TAI changes, update the kernel TAI. */ - clock_frequency = drift_comp + clock_frequency + - flladj + plladj; -#ifdef KERNEL_PLL + if (loop_tai != sys_tai) { + loop_tai = sys_tai; + ntv.modes = MOD_TAI; + ntv.constant = sys_tai; + ntp_adjtime(&ntv); + } +#endif /* STA_NANO */ } #endif /* KERNEL_PLL */ /* * Clamp the frequency within the tolerance range and calculate - * the frequency change since the last update. + * the frequency difference since the last update. */ if (fabs(clock_frequency) > NTP_MAXFREQ) - NLOG(NLOG_SYNCEVENT | NLOG_SYSEVENT) - msyslog(LOG_NOTICE, + msyslog(LOG_NOTICE, "frequency error %.0f PPM exceeds tolerance %.0f PPM", clock_frequency * 1e6, NTP_MAXFREQ * 1e6); dtemp = SQUARE(clock_frequency - drift_comp); @@ -706,14 +620,16 @@ drift_comp = clock_frequency; /* - * Calculate the wander as the exponentially weighted frequency - * differences. + * Calculate the wander as the exponentially weighted RMS + * frequency differences. Record the change for the frequency + * file update. */ etemp = SQUARE(clock_stability); clock_stability = SQRT(etemp + (dtemp - etemp) / CLOCK_AVG); + drift_file_sw = TRUE; /* - * Here we adjust the poll interval by comparing the current + * Here we adjust the timeconstan by comparing the current * offset with the clock jitter. If the offset is less than the * clock jitter times a constant, then the averaging interval is * increased, otherwise it is decreased. A bit of hysteresis @@ -740,6 +656,12 @@ } /* + * If the time constant has changed, update the poll variables. + */ + if (osys_poll != sys_poll) + poll_update(peer, sys_poll); + + /* * Yibbidy, yibbbidy, yibbidy; that'h all folks. */ record_loop_stats(clock_offset, drift_comp, clock_jitter, @@ -747,9 +669,9 @@ #ifdef DEBUG if (debug) printf( - "local_clock: mu %lu jitr %.6f freq %.3f stab %.6f poll %d count %d\n", - mu, clock_jitter, drift_comp * 1e6, - clock_stability * 1e6, sys_poll, tc_counter); + "local_clock: offset %.9f jit %.9f freq %.3f stab %.3f poll %d\n", + clock_offset, clock_jitter, drift_comp * 1e6, + clock_stability * 1e6, sys_poll); #endif /* DEBUG */ return (rval); #endif /* LOCKCLOCK */ @@ -760,7 +682,7 @@ * adj_host_clock - Called once every second to update the local clock. * * LOCKCLOCK: The only thing this routine does is increment the - * sys_rootdispersion variable. + * sys_rootdisp variable. */ void adj_host_clock( @@ -774,12 +696,9 @@ * NTPv3, NTPv4 does not declare unsynchronized after one day, * since the dispersion check serves this function. Also, * since the poll interval can exceed one day, the old test - * would be counterproductive. Note we do this even with - * external clocks, since the clock driver will recompute the - * maximum error and the local clock driver will pick it up and - * pass to the common refclock routines. Very elegant. + * would be counterproductive. */ - sys_rootdispersion += clock_phi; + sys_rootdisp += clock_phi; #ifndef LOCKCLOCK /* @@ -791,25 +710,11 @@ return; /* - * Declare PPS kernel unsync if the pps signal has not been - * heard for a few minutes. - */ - if (pps_control && current_time - pps_control > PPS_MAXAGE) { - if (pps_control) - NLOG(NLOG_SYNCEVENT | NLOG_SYSEVENT) - msyslog(LOG_NOTICE, "pps sync disabled"); - pps_control = 0; - } - - /* * Implement the phase and frequency adjustments. The gain - * factor (denominator) is not allowed to increase beyond the - * Allan intercept. It doesn't make sense to average phase noise - * beyond this point and it helps to damp residual offset at the - * longer poll intervals. - */ - adjustment = clock_offset / (CLOCK_PLL * min(ULOGTOD(sys_poll), - allan_xpt)); + * factor (denominator) increases with poll interval, so is + * dominated by the FLL above the Allan intercept. + */ + adjustment = clock_offset / (CLOCK_PLL * ULOGTOD(sys_poll)); clock_offset -= adjustment; adj_systime(adjustment + drift_comp); #endif /* LOCKCLOCK */ @@ -817,29 +722,104 @@ /* - * Clock state machine. Enter new state and set state variables. Note we - * use the time of the last clock filter sample, which may be earlier - * than the current time. + * Clock state machine. Enter new state and set state variables. */ static void rstclock( int trans, /* new state */ - u_long update, /* new update time */ double offset /* new offset */ ) { #ifdef DEBUG - if (debug) - printf("local_clock: time %lu offset %.6f freq %.3f state %d\n", - update, offset, drift_comp * 1e6, trans); + if (debug > 1) + printf("local_clock: mu %lu state %d poll %d count %d\n", + current_time - clock_epoch, trans, sys_poll, + tc_counter); #endif + if (trans != state && trans != EVNT_FSET) + report_event(trans, NULL, NULL); state = trans; - sys_clocktime = update; last_offset = clock_offset = offset; + clock_epoch = current_time; +} + +/* + * calc_freq - calculate frequency directly + * + * This is very carefully done. When the offset is first computed at the + * first update, a residual frequency component results. Subsequently, + * updates are suppresed until the end of the measurement interval while + * the offset is amortized. At the end of the interval the frequency is + * calculated from the current offset, residual offset, length of the + * interval and residual frequency component. At the same time the + * frequenchy file is armed for update at the next hourly stats. + */ +static double +direct_freq( + double fp_offset + ) +{ + +#ifdef KERNEL_PLL + /* + * If the kernel is enabled, we need the residual offset to + * calculate the frequency correction. + */ + if (pll_control && kern_enable) { + memset(&ntv, 0, sizeof(ntv)); + ntp_adjtime(&ntv); +#ifdef STA_NANO + clock_offset = ntv.offset / 1e9; +#else /* STA_NANO */ + clock_offset = ntv.offset / 1e6; +#endif /* STA_NANO */ + drift_comp = FREQTOD(ntv.freq); + } +#endif /* KERNEL_PLL */ + set_freq((fp_offset - clock_offset) / (current_time - + clock_epoch) + drift_comp); + wander_resid = 0; + return (drift_comp); } /* + * set_freq - set clock frequency + */ +static void +set_freq( + double freq /* frequency update */ + ) +{ + char tbuf[80]; + + drift_comp = freq; + +#ifdef KERNEL_PLL + /* + * If the kernel is enabled, update the kernel frequency. + */ + if (pll_control && kern_enable) { + memset(&ntv, 0, sizeof(ntv)); + ntv.modes = MOD_FREQUENCY; + ntv.freq = DTOFREQ(drift_comp); + ntp_adjtime(&ntv); + snprintf(tbuf, sizeof(tbuf), "kernel %.3f PPM", + drift_comp * 1e6); + report_event(EVNT_FSET, NULL, tbuf); + } else { + snprintf(tbuf, sizeof(tbuf), "ntpd %.3f PPM", + drift_comp * 1e6); + report_event(EVNT_FSET, NULL, tbuf); + } +#else /* KERNEL_PLL */ + snprintf(tbuf, sizeof(tbuf), "ntpd %.3f PPM", drift_comp * + 1e6); + report_event(EVNT_FSET, NULL, tbuf); +#endif /* KERNEL_PLL */ +} + +/* * huff-n'-puff filter */ void @@ -867,39 +847,36 @@ */ void loop_config( - int item, - double freq + int item, + double freq ) { int i; +#ifdef DEBUG + if (debug > 1) + printf("loop_config: item %d freq %f\n", item, freq); +#endif switch (item) { + /* + * We first assume the kernel supports the ntp_adjtime() + * syscall. If that syscall works, initialize the kernel time + * variables. Otherwise, continue leaving no harm behind. + */ case LOOP_DRIFTINIT: - #ifndef LOCKCLOCK #ifdef KERNEL_PLL - /* - * Assume the kernel supports the ntp_adjtime() syscall. - * If that syscall works, initialize the kernel time - * variables. Otherwise, continue leaving no harm - * behind. While at it, ask to set nanosecond mode. If - * the kernel agrees, rejoice; othewise, it does only - * microseconds. - */ if (mode_ntpdate) break; pll_control = 1; memset(&ntv, 0, sizeof(ntv)); -#ifdef STA_NANO - ntv.modes = MOD_BITS | MOD_NANO; -#else /* STA_NANO */ ntv.modes = MOD_BITS; -#endif /* STA_NANO */ + ntv.status = STA_PLL; ntv.maxerror = MAXDISPERSE; ntv.esterror = MAXDISPERSE; - ntv.status = STA_UNSYNC; + ntv.constant = sys_poll; #ifdef SIGSYS /* * Use sigsetjmp() to save state and then call @@ -935,91 +912,73 @@ if (pll_status & STA_CLK) ext_enable = 1; #endif /* STA_NANO */ - NLOG(NLOG_SYNCEVENT | NLOG_SYSEVENT) - msyslog(LOG_INFO, - "kernel time sync status %04x", - pll_status); + report_event(EVNT_KERN, NULL, + "kernel time sync enabled"); } #endif /* KERNEL_PLL */ #endif /* LOCKCLOCK */ break; + /* + * Initialize the frequency. If the frequency file is missing or + * broken, set the initial frequency to zero and set the state + * to NSET. Otherwise, set the initial frequency to the given + * value and the state to FSET. + */ case LOOP_DRIFTCOMP: - #ifndef LOCKCLOCK - /* - * If the frequency value is reasonable, set the initial - * frequency to the given value and the state to S_FSET. - * Otherwise, the drift file may be missing or broken, - * so set the frequency to zero. This erases past - * history should somebody break something. - */ - if (freq <= NTP_MAXFREQ && freq >= -NTP_MAXFREQ) { - drift_comp = freq; - rstclock(S_FSET, 0, 0); + if (freq > NTP_MAXFREQ || freq < -NTP_MAXFREQ) { + set_freq(0); + rstclock(EVNT_NSET, 0); } else { - drift_comp = 0; + set_freq(freq); + rstclock(EVNT_FSET, 0); } - -#ifdef KERNEL_PLL - /* - * Sanity check. If the kernel is available, load the - * frequency and light up the loop. Make sure the offset - * is zero to cancel any previous nonsense. If you don't - * want this initialization, remove the ntp.drift file. - */ - if (pll_control && kern_enable) { - memset((char *)&ntv, 0, sizeof(ntv)); - ntv.modes = MOD_OFFSET | MOD_FREQUENCY; - ntv.freq = (int32)(drift_comp * 65536e6); - ntp_adjtime(&ntv); - } -#endif /* KERNEL_PLL */ #endif /* LOCKCLOCK */ break; + /* + * Disable the kernel at shutdown. The microkernel just abandons + * ship. The nanokernel carefully cleans up so applications can + * see this. Note the last programmed offset and frequency are + * left in place. + */ case LOOP_KERN_CLEAR: #ifndef LOCKCLOCK #ifdef KERNEL_PLL - /* Completely turn off the kernel time adjustments. */ - if (pll_control) { + if (pll_control && kern_enable) { memset((char *)&ntv, 0, sizeof(ntv)); - ntv.modes = MOD_BITS | MOD_OFFSET | MOD_FREQUENCY; + ntv.modes = MOD_STATUS; ntv.status = STA_UNSYNC; ntp_adjtime(&ntv); - NLOG(NLOG_SYNCEVENT | NLOG_SYSEVENT) - msyslog(LOG_INFO, - "kernel time sync disabled %04x", - ntv.status); + report_event(EVNT_KERN, NULL, + "kernel time sync disabledx"); } #endif /* KERNEL_PLL */ #endif /* LOCKCLOCK */ break; /* - * Special tinker variables for Ulrich Windl. Very dangerous. + * Tinker command variables for Ulrich Windl. Very dangerous. */ - case LOOP_MAX: /* step threshold */ - clock_max = freq; + case LOOP_ALLAN: /* Allan intercept (log2) (allan) */ + allan_xpt = (u_char)freq; break; - case LOOP_PANIC: /* panic threshold */ - clock_panic = freq; + case LOOP_CODEC: /* audio codec frequency (codec) */ + clock_codec = freq / 1e6; break; - - case LOOP_PHI: /* dispersion rate */ - clock_phi = freq; + + case LOOP_PHI: /* dispersion threshold (dispersion) */ + clock_phi = freq / 1e6; break; - case LOOP_MINSTEP: /* watchdog bark */ - clock_minstep = freq; + case LOOP_FREQ: /* initial frequency (freq) */ + set_freq(freq / 1e6); + rstclock(EVNT_FSET, 0); break; - case LOOP_ALLAN: /* Allan intercept */ - allan_xpt = freq; - break; - - case LOOP_HUFFPUFF: /* huff-n'-puff filter length */ + case LOOP_HUFFPUFF: /* huff-n'-puff length (huffpuff) */ if (freq < HUFFPUFF) freq = HUFFPUFF; sys_hufflen = (int)(freq / HUFFPUFF); @@ -1030,10 +989,24 @@ sys_mindly = 1e9; break; - case LOOP_FREQ: /* initial frequency */ - drift_comp = freq / 1e6; - rstclock(S_FSET, 0, 0); + case LOOP_PANIC: /* panic threshold (panic) */ + clock_panic = freq; + break; + + case LOOP_MAX: /* step threshold (step) */ + clock_max = freq; + if (clock_max == 0 || clock_max > 0.5) + kern_enable = 0; break; + + case LOOP_MINSTEP: /* stepout threshold (stepout) */ + clock_minstep = freq; + break; + + case LOOP_LEAP: /* not used */ + default: + msyslog(LOG_NOTICE, + "loop_config: unsupported option %d", item); } } diff -urN src/contrib/ntp/ntpd/ntp_monitor.c src.ntp/contrib/ntp/ntpd/ntp_monitor.c --- src/contrib/ntp/ntpd/ntp_monitor.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/ntp_monitor.c 2010-04-18 10:05:39.000000000 +0200 @@ -18,17 +18,14 @@ #endif /* - * I'm still not sure I like what I've done here. It certainly consumes - * memory like it is going out of style, and also may not be as low - * overhead as I'd imagined. + * Record statistics based on source address, mode and version. The + * receive procedure calls us with the incoming rbufp before it does + * anything else. While at it, implement rate controls for inbound + * traffic. * - * Anyway, we record statistics based on source address, mode and - * version (for now, anyway. Check the code). The receive procedure - * calls us with the incoming rbufp before it does anything else. - * - * Each entry is doubly linked into two lists, a hash table and a - * most-recently-used list. When a packet arrives it is looked up in - * the hash table. If found, the statistics are updated and the entry + * Each entry is doubly linked into two lists, a hash table and a most- + * recently-used (MRU) list. When a packet arrives it is looked up in + * the hash table. If found, the statistics are updated and the entry * relinked at the head of the MRU list. If not found, a new entry is * allocated, initialized and linked into both the hash table and at the * head of the MRU list. @@ -38,14 +35,12 @@ * the memory limit. Then we free memory by grabbing entries off the * tail for the MRU list, unlinking from the hash table, and * reinitializing. - * - * trimmed back memory consumption ... jdg 8/94 */ /* * Limits on the number of structures allocated. This limit is picked - * with the illicit knowlege that we can only return somewhat less - * than 8K bytes in a mode 7 response packet, and that each structure - * will require about 20 bytes of space in the response. + * with the illicit knowlege that we can only return somewhat less than + * 8K bytes in a mode 7 response packet, and that each structure will + * require about 20 bytes of space in the response. * * ... I don't believe the above is true anymore ... jdg */ @@ -59,9 +54,9 @@ /* * Hashing stuff */ -#define MON_HASH_SIZE 128 -#define MON_HASH_MASK (MON_HASH_SIZE-1) -#define MON_HASH(addr) sock_hash(addr) +#define MON_HASH_SIZE NTP_HASH_SIZE +#define MON_HASH_MASK NTP_HASH_MASK +#define MON_HASH(addr) NTP_HASH_ADDR(addr) /* * Pointers to the hash table, the MRU list and the count table. Memory @@ -73,21 +68,30 @@ /* * List of free structures structures, and counters of free and total - * structures. The free structures are linked with the hash_next field. + * structures. The free structures are linked with the hash_next field. */ static struct mon_data *mon_free; /* free list or null if none */ static int mon_total_mem; /* total structures allocated */ static int mon_mem_increments; /* times called malloc() */ /* + * Parameters of the RES_LIMITED restriction option. We define headway + * as the idle time between packets. A packet is discarded if the + * headway is less than the minimum, as well as if the average headway + * is less than eight times the increment. + */ +int ntp_minpkt = NTP_MINPKT; /* minimum (log 2 s) */ +int ntp_minpoll = NTP_MINPOLL; /* increment (log 2 s) */ + +/* * Initialization state. We may be monitoring, we may not. If * we aren't, we may not even have allocated any memory yet. */ int mon_enabled; /* enable switch */ -u_long mon_age = 3000; /* preemption limit */ +int mon_age = 3000; /* preemption limit */ static int mon_have_memory; -static void mon_getmoremem P((void)); -static void remove_from_hash P((struct mon_data *)); +static void mon_getmoremem (void); +static void remove_from_hash (struct mon_data *); /* * init_mon - initialize monitoring global data @@ -101,7 +105,6 @@ */ mon_enabled = MON_OFF; mon_have_memory = 0; - mon_total_mem = 0; mon_mem_increments = 0; mon_free = NULL; @@ -152,13 +155,13 @@ register int i; if (mon_enabled == MON_OFF) - return; + return; if ((mon_enabled & mode) == 0 || mode == MON_OFF) - return; + return; mon_enabled &= ~mode; if (mon_enabled != MON_OFF) - return; + return; /* * Put everything back on the free list @@ -173,7 +176,6 @@ md = md_next; } } - mon_mru_list.mru_next = &mon_mru_list; mon_mru_list.mru_prev = &mon_mru_list; } @@ -184,37 +186,39 @@ struct mon_data *md; for (md = mon_mru_list.mru_next; md != &mon_mru_list; - md = md->mru_next) { - if (md->interface == interface) - { - /* dequeue from mru list and put to free list */ - md->mru_prev->mru_next = md->mru_next; - md->mru_next->mru_prev = md->mru_prev; - remove_from_hash(md); - md->hash_next = mon_free; - mon_free = md; - } + md = md->mru_next) { + if (md->interface == interface) { + /* dequeue from mru list and put to free list */ + md->mru_prev->mru_next = md->mru_next; + md->mru_next->mru_prev = md->mru_prev; + remove_from_hash(md); + md->hash_next = mon_free; + mon_free = md; + } } } + /* * ntp_monitor - record stats about this packet * - * Returns 1 if the packet is at the head of the list, 0 otherwise. + * Returns flags */ int ntp_monitor( - struct recvbuf *rbufp + struct recvbuf *rbufp, + int flags ) { register struct pkt *pkt; register struct mon_data *md; - struct sockaddr_storage addr; - register int hash; + sockaddr_u addr; + register u_int hash; register int mode; + int interval; if (mon_enabled == MON_OFF) - return 0; + return (flags); pkt = &rbufp->recv_pkt; memset(&addr, 0, sizeof(addr)); @@ -223,14 +227,18 @@ mode = PKT_MODE(pkt->li_vn_mode); md = mon_hash[hash]; while (md != NULL) { + int head; /* headway increment */ + int leak; /* new headway */ + int limit; /* average threshold */ /* * Match address only to conserve MRU size. */ - if (SOCKCMP(&md->rmtadr, &addr)) { - md->drop_count = current_time - md->lasttime; + if (SOCK_EQ(&md->rmtadr, &addr)) { + interval = current_time - md->lasttime; md->lasttime = current_time; md->count++; + md->flags = flags; md->rmtport = NSRCPORT(&rbufp->recv_srcadr); md->mode = (u_char) mode; md->version = PKT_VERSION(pkt->li_vn_mode); @@ -244,7 +252,49 @@ md->mru_prev = &mon_mru_list; mon_mru_list.mru_next->mru_prev = md; mon_mru_list.mru_next = md; - return 1; + + /* + * At this point the most recent arrival is + * first in the MRU list. Decrease the counter + * by the headway, but not less than zero. + */ + md->leak -= interval; + if (md->leak < 0) + md->leak = 0; + head = 1 << ntp_minpoll; + leak = md->leak + head; + limit = NTP_SHIFT * head; +#ifdef DEBUG + if (debug > 1) + printf("restrict: interval %d headway %d limit %d\n", + interval, leak, limit); +#endif + + /* + * If the minimum and average thresholds are not + * exceeded, douse the RES_LIMITED and RES_KOD + * bits and increase the counter by the headway + * increment. Note that we give a 1-s grace for + * the minimum threshold and a 2-s grace for the + * headway increment. If one or both thresholds + * are exceeded and the old counter is less than + * the average threshold, set the counter to the + * average threshold plus the inrcrment and + * leave the RES_KOD bit lit. Othewise, leave + * the counter alone and douse the RES_KOD bit. + * This rate-limits the KoDs to no less than the + * average headway. + */ + if (interval + 1 >= (1 << ntp_minpkt) && + leak < limit) { + md->leak = leak - 2; + md->flags &= ~(RES_LIMITED | RES_KOD); + } else if (md->leak < limit) { + md->leak = limit + head; + } else { + md->flags &= ~RES_KOD; + } + return (md->flags); } md = md->hash_next; } @@ -260,10 +310,9 @@ * Preempt from the MRU list if old enough. */ md = mon_mru_list.mru_prev; - /* We get 31 bits from ntp_random() */ - if (((u_long)ntp_random()) / FRAC > - (double)(current_time - md->lasttime) / mon_age) - return 0; + if (ntp_random() / (2. * FRAC) > (double)(current_time + - md->lasttime) / mon_age) + return (flags & ~(RES_LIMITED | RES_KOD)); md->mru_prev->mru_next = &mon_mru_list; mon_mru_list.mru_prev = md->mru_prev; @@ -278,19 +327,20 @@ /* * Got one, initialize it */ - md->avg_interval = 0; - md->lasttime = current_time; + md->lasttime = md->firsttime = current_time; md->count = 1; - md->drop_count = 0; + md->flags = flags & ~(RES_LIMITED | RES_KOD); + md->leak = 0; memset(&md->rmtadr, 0, sizeof(md->rmtadr)); memcpy(&md->rmtadr, &addr, sizeof(addr)); md->rmtport = NSRCPORT(&rbufp->recv_srcadr); md->mode = (u_char) mode; md->version = PKT_VERSION(pkt->li_vn_mode); md->interface = rbufp->dstadr; - md->cast_flags = (u_char)(((rbufp->dstadr->flags & INT_MCASTOPEN) && - rbufp->fd == md->interface->fd) ? MDF_MCAST: rbufp->fd == - md->interface->bfd ? MDF_BCAST : MDF_UCAST); + md->cast_flags = (u_char)(((rbufp->dstadr->flags & + INT_MCASTOPEN) && rbufp->fd == md->interface->fd) ? + MDF_MCAST: rbufp->fd == md->interface->bfd ? MDF_BCAST : + MDF_UCAST); /* * Drop him into front of the hash table. Also put him on top of @@ -302,7 +352,7 @@ md->mru_prev = &mon_mru_list; mon_mru_list.mru_next->mru_prev = md; mon_mru_list.mru_next = md; - return 1; + return (md->flags); } @@ -338,7 +388,7 @@ struct mon_data *md ) { - register int hash; + register u_int hash; register struct mon_data *md_prev; hash = MON_HASH(&md->rmtadr); diff -urN src/contrib/ntp/ntpd/ntp_parser.c src.ntp/contrib/ntp/ntpd/ntp_parser.c --- src/contrib/ntp/ntpd/ntp_parser.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/ntp_parser.c 2010-07-09 04:17:43.000000000 +0200 @@ -0,0 +1,3931 @@ + +/* A Bison parser, made by GNU Bison 2.4.1. */ + +/* Skeleton implementation for Bison's Yacc-like parsers in C + + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 + Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . */ + +/* As a special exception, you may create a larger work that contains + part or all of the Bison parser skeleton and distribute that work + under terms of your choice, so long as that work isn't itself a + parser generator using the skeleton or a modified version thereof + as a parser skeleton. Alternatively, if you modify or redistribute + the parser skeleton itself, you may (at your option) remove this + special exception, which will cause the skeleton and the resulting + Bison output files to be licensed under the GNU General Public + License without this special exception. + + This special exception was added by the Free Software Foundation in + version 2.2 of Bison. */ + +/* C LALR(1) parser skeleton written by Richard Stallman, by + simplifying the original so-called "semantic" parser. */ + +/* All symbols defined below should begin with yy or YY, to avoid + infringing on user name space. This should be done even for local + variables, as they might otherwise be expanded by user macros. + There are some unavoidable exceptions within include files to + define necessary library symbols; they are noted "INFRINGES ON + USER NAME SPACE" below. */ + +/* Identify Bison output. */ +#define YYBISON 1 + +/* Bison version. */ +#define YYBISON_VERSION "2.4.1" + +/* Skeleton name. */ +#define YYSKELETON_NAME "yacc.c" + +/* Pure parsers. */ +#define YYPURE 0 + +/* Push parsers. */ +#define YYPUSH 0 + +/* Pull parsers. */ +#define YYPULL 1 + +/* Using locations. */ +#define YYLSP_NEEDED 0 + + + +/* Copy the first part of user declarations. */ + +/* Line 189 of yacc.c */ +#line 11 "ntp_parser.y" + + #ifdef HAVE_CONFIG_H + # include + #endif + + #include "ntpd.h" + #include "ntp_machine.h" + #include "ntp.h" + #include "ntp_stdlib.h" + #include "ntp_filegen.h" + #include "ntp_data_structures.h" + #include "ntp_scanner.h" + #include "ntp_config.h" + #include "ntp_crypto.h" + + #include "ntpsim.h" /* HMS: Do we really want this all the time? */ + /* SK: It might be a good idea to always + include the simulator code. That way + someone can use the same configuration file + for both the simulator and the daemon + */ + + + struct FILE_INFO *ip_file; /* Pointer to the configuration file stream */ + + #define YYMALLOC emalloc + #define YYFREE free + #define YYERROR_VERBOSE + #define YYMAXDEPTH 1000 /* stop the madness sooner */ + void yyerror (char *msg); + extern int input_from_file; /* 0=input from ntpq :config */ + + +/* Line 189 of yacc.c */ +#line 107 "ntp_parser.c" + +/* Enabling traces. */ +#ifndef YYDEBUG +# define YYDEBUG 1 +#endif + +/* Enabling verbose error messages. */ +#ifdef YYERROR_VERBOSE +# undef YYERROR_VERBOSE +# define YYERROR_VERBOSE 1 +#else +# define YYERROR_VERBOSE 0 +#endif + +/* Enabling the token table. */ +#ifndef YYTOKEN_TABLE +# define YYTOKEN_TABLE 1 +#endif + + +/* Tokens. */ +#ifndef YYTOKENTYPE +# define YYTOKENTYPE + /* Put the tokens into the symbol table, so that GDB and other debuggers + know about them. */ + enum yytokentype { + T_Age = 258, + T_All = 259, + T_Allan = 260, + T_Auth = 261, + T_Autokey = 262, + T_Automax = 263, + T_Average = 264, + T_Bclient = 265, + T_Beacon = 266, + T_Bias = 267, + T_Broadcast = 268, + T_Broadcastclient = 269, + T_Broadcastdelay = 270, + T_Burst = 271, + T_Calibrate = 272, + T_Calldelay = 273, + T_Ceiling = 274, + T_Clockstats = 275, + T_Cohort = 276, + T_ControlKey = 277, + T_Crypto = 278, + T_Cryptostats = 279, + T_Day = 280, + T_Default = 281, + T_Digest = 282, + T_Disable = 283, + T_Discard = 284, + T_Dispersion = 285, + T_Double = 286, + T_Driftfile = 287, + T_Drop = 288, + T_Ellipsis = 289, + T_Enable = 290, + T_End = 291, + T_False = 292, + T_File = 293, + T_Filegen = 294, + T_Flag1 = 295, + T_Flag2 = 296, + T_Flag3 = 297, + T_Flag4 = 298, + T_Flake = 299, + T_Floor = 300, + T_Freq = 301, + T_Fudge = 302, + T_Host = 303, + T_Huffpuff = 304, + T_Iburst = 305, + T_Ident = 306, + T_Ignore = 307, + T_Includefile = 308, + T_Integer = 309, + T_Interface = 310, + T_Ipv4 = 311, + T_Ipv4_flag = 312, + T_Ipv6 = 313, + T_Ipv6_flag = 314, + T_Kernel = 315, + T_Key = 316, + T_Keys = 317, + T_Keysdir = 318, + T_Kod = 319, + T_Mssntp = 320, + T_Leapfile = 321, + T_Limited = 322, + T_Link = 323, + T_Listen = 324, + T_Logconfig = 325, + T_Logfile = 326, + T_Loopstats = 327, + T_Lowpriotrap = 328, + T_Manycastclient = 329, + T_Manycastserver = 330, + T_Mask = 331, + T_Maxclock = 332, + T_Maxdist = 333, + T_Maxpoll = 334, + T_Minclock = 335, + T_Mindist = 336, + T_Minimum = 337, + T_Minpoll = 338, + T_Minsane = 339, + T_Mode = 340, + T_Monitor = 341, + T_Month = 342, + T_Multicastclient = 343, + T_Nic = 344, + T_Nolink = 345, + T_Nomodify = 346, + T_None = 347, + T_Nopeer = 348, + T_Noquery = 349, + T_Noselect = 350, + T_Noserve = 351, + T_Notrap = 352, + T_Notrust = 353, + T_Ntp = 354, + T_Ntpport = 355, + T_NtpSignDsocket = 356, + T_Orphan = 357, + T_Panic = 358, + T_Peer = 359, + T_Peerstats = 360, + T_Phone = 361, + T_Pid = 362, + T_Pidfile = 363, + T_Pool = 364, + T_Port = 365, + T_Preempt = 366, + T_Prefer = 367, + T_Protostats = 368, + T_Pw = 369, + T_Qos = 370, + T_Randfile = 371, + T_Rawstats = 372, + T_Refid = 373, + T_Requestkey = 374, + T_Restrict = 375, + T_Revoke = 376, + T_Saveconfigdir = 377, + T_Server = 378, + T_Setvar = 379, + T_Sign = 380, + T_Statistics = 381, + T_Stats = 382, + T_Statsdir = 383, + T_Step = 384, + T_Stepout = 385, + T_Stratum = 386, + T_String = 387, + T_Sysstats = 388, + T_Tick = 389, + T_Time1 = 390, + T_Time2 = 391, + T_Timingstats = 392, + T_Tinker = 393, + T_Tos = 394, + T_Trap = 395, + T_True = 396, + T_Trustedkey = 397, + T_Ttl = 398, + T_Type = 399, + T_Unconfig = 400, + T_Unpeer = 401, + T_Version = 402, + T_WanderThreshold = 403, + T_Week = 404, + T_Wildcard = 405, + T_Xleave = 406, + T_Year = 407, + T_Flag = 408, + T_Void = 409, + T_EOC = 410, + T_Simulate = 411, + T_Beep_Delay = 412, + T_Sim_Duration = 413, + T_Server_Offset = 414, + T_Duration = 415, + T_Freq_Offset = 416, + T_Wander = 417, + T_Jitter = 418, + T_Prop_Delay = 419, + T_Proc_Delay = 420 + }; +#endif +/* Tokens. */ +#define T_Age 258 +#define T_All 259 +#define T_Allan 260 +#define T_Auth 261 +#define T_Autokey 262 +#define T_Automax 263 +#define T_Average 264 +#define T_Bclient 265 +#define T_Beacon 266 +#define T_Bias 267 +#define T_Broadcast 268 +#define T_Broadcastclient 269 +#define T_Broadcastdelay 270 +#define T_Burst 271 +#define T_Calibrate 272 +#define T_Calldelay 273 +#define T_Ceiling 274 +#define T_Clockstats 275 +#define T_Cohort 276 +#define T_ControlKey 277 +#define T_Crypto 278 +#define T_Cryptostats 279 +#define T_Day 280 +#define T_Default 281 +#define T_Digest 282 +#define T_Disable 283 +#define T_Discard 284 +#define T_Dispersion 285 +#define T_Double 286 +#define T_Driftfile 287 +#define T_Drop 288 +#define T_Ellipsis 289 +#define T_Enable 290 +#define T_End 291 +#define T_False 292 +#define T_File 293 +#define T_Filegen 294 +#define T_Flag1 295 +#define T_Flag2 296 +#define T_Flag3 297 +#define T_Flag4 298 +#define T_Flake 299 +#define T_Floor 300 +#define T_Freq 301 +#define T_Fudge 302 +#define T_Host 303 +#define T_Huffpuff 304 +#define T_Iburst 305 +#define T_Ident 306 +#define T_Ignore 307 +#define T_Includefile 308 +#define T_Integer 309 +#define T_Interface 310 +#define T_Ipv4 311 +#define T_Ipv4_flag 312 +#define T_Ipv6 313 +#define T_Ipv6_flag 314 +#define T_Kernel 315 +#define T_Key 316 +#define T_Keys 317 +#define T_Keysdir 318 +#define T_Kod 319 +#define T_Mssntp 320 +#define T_Leapfile 321 +#define T_Limited 322 +#define T_Link 323 +#define T_Listen 324 +#define T_Logconfig 325 +#define T_Logfile 326 +#define T_Loopstats 327 +#define T_Lowpriotrap 328 +#define T_Manycastclient 329 +#define T_Manycastserver 330 +#define T_Mask 331 +#define T_Maxclock 332 +#define T_Maxdist 333 +#define T_Maxpoll 334 +#define T_Minclock 335 +#define T_Mindist 336 +#define T_Minimum 337 +#define T_Minpoll 338 +#define T_Minsane 339 +#define T_Mode 340 +#define T_Monitor 341 +#define T_Month 342 +#define T_Multicastclient 343 +#define T_Nic 344 +#define T_Nolink 345 +#define T_Nomodify 346 +#define T_None 347 +#define T_Nopeer 348 +#define T_Noquery 349 +#define T_Noselect 350 +#define T_Noserve 351 +#define T_Notrap 352 +#define T_Notrust 353 +#define T_Ntp 354 +#define T_Ntpport 355 +#define T_NtpSignDsocket 356 +#define T_Orphan 357 +#define T_Panic 358 +#define T_Peer 359 +#define T_Peerstats 360 +#define T_Phone 361 +#define T_Pid 362 +#define T_Pidfile 363 +#define T_Pool 364 +#define T_Port 365 +#define T_Preempt 366 +#define T_Prefer 367 +#define T_Protostats 368 +#define T_Pw 369 +#define T_Qos 370 +#define T_Randfile 371 +#define T_Rawstats 372 +#define T_Refid 373 +#define T_Requestkey 374 +#define T_Restrict 375 +#define T_Revoke 376 +#define T_Saveconfigdir 377 +#define T_Server 378 +#define T_Setvar 379 +#define T_Sign 380 +#define T_Statistics 381 +#define T_Stats 382 +#define T_Statsdir 383 +#define T_Step 384 +#define T_Stepout 385 +#define T_Stratum 386 +#define T_String 387 +#define T_Sysstats 388 +#define T_Tick 389 +#define T_Time1 390 +#define T_Time2 391 +#define T_Timingstats 392 +#define T_Tinker 393 +#define T_Tos 394 +#define T_Trap 395 +#define T_True 396 +#define T_Trustedkey 397 +#define T_Ttl 398 +#define T_Type 399 +#define T_Unconfig 400 +#define T_Unpeer 401 +#define T_Version 402 +#define T_WanderThreshold 403 +#define T_Week 404 +#define T_Wildcard 405 +#define T_Xleave 406 +#define T_Year 407 +#define T_Flag 408 +#define T_Void 409 +#define T_EOC 410 +#define T_Simulate 411 +#define T_Beep_Delay 412 +#define T_Sim_Duration 413 +#define T_Server_Offset 414 +#define T_Duration 415 +#define T_Freq_Offset 416 +#define T_Wander 417 +#define T_Jitter 418 +#define T_Prop_Delay 419 +#define T_Proc_Delay 420 + + + + +#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED +typedef union YYSTYPE +{ + +/* Line 214 of yacc.c */ +#line 50 "ntp_parser.y" + + char *String; + double Double; + int Integer; + void *VoidPtr; + queue *Queue; + struct attr_val *Attr_val; + struct address_node *Address_node; + struct setvar_node *Set_var; + + /* Simulation types */ + server_info *Sim_server; + script_info *Sim_script; + + + +/* Line 214 of yacc.c */ +#line 490 "ntp_parser.c" +} YYSTYPE; +# define YYSTYPE_IS_TRIVIAL 1 +# define yystype YYSTYPE /* obsolescent; will be withdrawn */ +# define YYSTYPE_IS_DECLARED 1 +#endif + + +/* Copy the second part of user declarations. */ + + +/* Line 264 of yacc.c */ +#line 502 "ntp_parser.c" + +#ifdef short +# undef short +#endif + +#ifdef YYTYPE_UINT8 +typedef YYTYPE_UINT8 yytype_uint8; +#else +typedef unsigned char yytype_uint8; +#endif + +#ifdef YYTYPE_INT8 +typedef YYTYPE_INT8 yytype_int8; +#elif (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +typedef signed char yytype_int8; +#else +typedef short int yytype_int8; +#endif + +#ifdef YYTYPE_UINT16 +typedef YYTYPE_UINT16 yytype_uint16; +#else +typedef unsigned short int yytype_uint16; +#endif + +#ifdef YYTYPE_INT16 +typedef YYTYPE_INT16 yytype_int16; +#else +typedef short int yytype_int16; +#endif + +#ifndef YYSIZE_T +# ifdef __SIZE_TYPE__ +# define YYSIZE_T __SIZE_TYPE__ +# elif defined size_t +# define YYSIZE_T size_t +# elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +# include /* INFRINGES ON USER NAME SPACE */ +# define YYSIZE_T size_t +# else +# define YYSIZE_T unsigned int +# endif +#endif + +#define YYSIZE_MAXIMUM ((YYSIZE_T) -1) + +#ifndef YY_ +# if YYENABLE_NLS +# if ENABLE_NLS +# include /* INFRINGES ON USER NAME SPACE */ +# define YY_(msgid) dgettext ("bison-runtime", msgid) +# endif +# endif +# ifndef YY_ +# define YY_(msgid) msgid +# endif +#endif + +/* Suppress unused-variable warnings by "using" E. */ +#if ! defined lint || defined __GNUC__ +# define YYUSE(e) ((void) (e)) +#else +# define YYUSE(e) /* empty */ +#endif + +/* Identity function, used to suppress warnings about constant conditions. */ +#ifndef lint +# define YYID(n) (n) +#else +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static int +YYID (int yyi) +#else +static int +YYID (yyi) + int yyi; +#endif +{ + return yyi; +} +#endif + +#if ! defined yyoverflow || YYERROR_VERBOSE + +/* The parser invokes alloca or malloc; define the necessary symbols. */ + +# ifdef YYSTACK_USE_ALLOCA +# if YYSTACK_USE_ALLOCA +# ifdef __GNUC__ +# define YYSTACK_ALLOC __builtin_alloca +# elif defined __BUILTIN_VA_ARG_INCR +# include /* INFRINGES ON USER NAME SPACE */ +# elif defined _AIX +# define YYSTACK_ALLOC __alloca +# elif defined _MSC_VER +# include /* INFRINGES ON USER NAME SPACE */ +# define alloca _alloca +# else +# define YYSTACK_ALLOC alloca +# if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +# include /* INFRINGES ON USER NAME SPACE */ +# ifndef _STDLIB_H +# define _STDLIB_H 1 +# endif +# endif +# endif +# endif +# endif + +# ifdef YYSTACK_ALLOC + /* Pacify GCC's `empty if-body' warning. */ +# define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0)) +# ifndef YYSTACK_ALLOC_MAXIMUM + /* The OS might guarantee only one guard page at the bottom of the stack, + and a page size can be as small as 4096 bytes. So we cannot safely + invoke alloca (N) if N exceeds 4096. Use a slightly smaller number + to allow for a few compiler-allocated temporary stack slots. */ +# define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */ +# endif +# else +# define YYSTACK_ALLOC YYMALLOC +# define YYSTACK_FREE YYFREE +# ifndef YYSTACK_ALLOC_MAXIMUM +# define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM +# endif +# if (defined __cplusplus && ! defined _STDLIB_H \ + && ! ((defined YYMALLOC || defined malloc) \ + && (defined YYFREE || defined free))) +# include /* INFRINGES ON USER NAME SPACE */ +# ifndef _STDLIB_H +# define _STDLIB_H 1 +# endif +# endif +# ifndef YYMALLOC +# define YYMALLOC malloc +# if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ +# endif +# endif +# ifndef YYFREE +# define YYFREE free +# if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +void free (void *); /* INFRINGES ON USER NAME SPACE */ +# endif +# endif +# endif +#endif /* ! defined yyoverflow || YYERROR_VERBOSE */ + + +#if (! defined yyoverflow \ + && (! defined __cplusplus \ + || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) + +/* A type that is properly aligned for any stack member. */ +union yyalloc +{ + yytype_int16 yyss_alloc; + YYSTYPE yyvs_alloc; +}; + +/* The size of the maximum gap between one aligned stack and the next. */ +# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) + +/* The size of an array large to enough to hold all stacks, each with + N elements. */ +# define YYSTACK_BYTES(N) \ + ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \ + + YYSTACK_GAP_MAXIMUM) + +/* Copy COUNT objects from FROM to TO. The source and destination do + not overlap. */ +# ifndef YYCOPY +# if defined __GNUC__ && 1 < __GNUC__ +# define YYCOPY(To, From, Count) \ + __builtin_memcpy (To, From, (Count) * sizeof (*(From))) +# else +# define YYCOPY(To, From, Count) \ + do \ + { \ + YYSIZE_T yyi; \ + for (yyi = 0; yyi < (Count); yyi++) \ + (To)[yyi] = (From)[yyi]; \ + } \ + while (YYID (0)) +# endif +# endif + +/* Relocate STACK from its old location to the new one. The + local variables YYSIZE and YYSTACKSIZE give the old and new number of + elements in the stack, and YYPTR gives the new location of the + stack. Advance YYPTR to a properly aligned location for the next + stack. */ +# define YYSTACK_RELOCATE(Stack_alloc, Stack) \ + do \ + { \ + YYSIZE_T yynewbytes; \ + YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ + Stack = &yyptr->Stack_alloc; \ + yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ + yyptr += yynewbytes / sizeof (*yyptr); \ + } \ + while (YYID (0)) + +#endif + +/* YYFINAL -- State number of the termination state. */ +#define YYFINAL 177 +/* YYLAST -- Last index in YYTABLE. */ +#define YYLAST 586 + +/* YYNTOKENS -- Number of terminals. */ +#define YYNTOKENS 171 +/* YYNNTS -- Number of nonterminals. */ +#define YYNNTS 71 +/* YYNRULES -- Number of rules. */ +#define YYNRULES 250 +/* YYNRULES -- Number of states. */ +#define YYNSTATES 393 + +/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */ +#define YYUNDEFTOK 2 +#define YYMAXUTOK 420 + +#define YYTRANSLATE(YYX) \ + ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) + +/* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */ +static const yytype_uint8 yytranslate[] = +{ + 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 167, 168, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 166, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 169, 2, 170, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 1, 2, 3, 4, + 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, + 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, + 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, + 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, + 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, + 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, + 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, + 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, + 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, + 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, + 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, + 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, + 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, + 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, + 145, 146, 147, 148, 149, 150, 151, 152, 153, 154, + 155, 156, 157, 158, 159, 160, 161, 162, 163, 164, + 165 +}; + +#if YYDEBUG +/* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in + YYRHS. */ +static const yytype_uint16 yyprhs[] = +{ + 0, 0, 3, 5, 9, 12, 15, 16, 18, 20, + 22, 24, 26, 28, 30, 32, 34, 36, 38, 40, + 44, 47, 49, 51, 53, 55, 57, 59, 62, 65, + 67, 70, 72, 74, 77, 79, 81, 84, 87, 90, + 92, 94, 96, 98, 100, 103, 106, 109, 112, 114, + 116, 118, 121, 124, 127, 130, 133, 136, 139, 142, + 145, 148, 151, 153, 154, 157, 159, 162, 165, 168, + 171, 174, 177, 180, 183, 186, 188, 191, 194, 197, + 200, 203, 206, 209, 212, 215, 218, 221, 224, 228, + 231, 233, 235, 237, 239, 241, 243, 245, 247, 249, + 252, 254, 257, 260, 262, 264, 266, 268, 270, 272, + 274, 276, 278, 280, 282, 285, 289, 293, 298, 303, + 309, 310, 313, 315, 317, 319, 321, 323, 325, 327, + 329, 331, 333, 335, 337, 339, 341, 344, 346, 349, + 352, 355, 359, 362, 364, 367, 370, 373, 376, 379, + 382, 385, 388, 391, 394, 397, 399, 401, 403, 405, + 407, 409, 411, 413, 416, 419, 421, 424, 427, 430, + 433, 436, 439, 442, 444, 448, 450, 453, 456, 459, + 462, 465, 468, 471, 474, 477, 480, 483, 486, 490, + 493, 496, 498, 501, 502, 507, 511, 514, 516, 519, + 522, 525, 527, 529, 533, 537, 539, 541, 543, 545, + 547, 549, 551, 553, 555, 558, 560, 563, 565, 567, + 569, 575, 578, 580, 583, 585, 587, 589, 591, 593, + 595, 601, 603, 607, 610, 614, 618, 621, 623, 629, + 634, 638, 641, 643, 650, 654, 657, 661, 665, 669, + 673 +}; + +/* YYRHS -- A `-1'-separated list of the rules' RHS. */ +static const yytype_int16 yyrhs[] = +{ + 172, 0, -1, 173, -1, 173, 174, 155, -1, 174, + 155, -1, 1, 155, -1, -1, 175, -1, 181, -1, + 183, -1, 184, -1, 191, -1, 197, -1, 188, -1, + 202, -1, 205, -1, 208, -1, 211, -1, 230, -1, + 176, 177, 179, -1, 176, 177, -1, 123, -1, 109, + -1, 104, -1, 13, -1, 74, -1, 178, -1, 57, + 132, -1, 59, 132, -1, 132, -1, 179, 180, -1, + 180, -1, 7, -1, 12, 229, -1, 16, -1, 50, + -1, 61, 54, -1, 83, 54, -1, 79, 54, -1, + 95, -1, 111, -1, 112, -1, 141, -1, 151, -1, + 143, 54, -1, 85, 54, -1, 147, 54, -1, 182, + 177, -1, 145, -1, 146, -1, 14, -1, 75, 227, + -1, 88, 227, -1, 8, 54, -1, 22, 54, -1, + 23, 185, -1, 62, 132, -1, 63, 132, -1, 119, + 54, -1, 121, 54, -1, 142, 223, -1, 101, 132, + -1, 186, -1, -1, 186, 187, -1, 187, -1, 48, + 132, -1, 51, 132, -1, 114, 132, -1, 116, 132, + -1, 125, 132, -1, 27, 132, -1, 121, 54, -1, + 139, 189, -1, 189, 190, -1, 190, -1, 19, 54, + -1, 45, 54, -1, 21, 228, -1, 102, 54, -1, + 81, 229, -1, 78, 229, -1, 80, 229, -1, 77, + 229, -1, 84, 54, -1, 11, 54, -1, 126, 192, + -1, 128, 132, -1, 39, 193, 194, -1, 192, 193, + -1, 193, -1, 20, -1, 24, -1, 72, -1, 105, + -1, 117, -1, 133, -1, 137, -1, 113, -1, 194, + 195, -1, 195, -1, 38, 132, -1, 144, 196, -1, + 68, -1, 90, -1, 35, -1, 28, -1, 92, -1, + 107, -1, 25, -1, 149, -1, 87, -1, 152, -1, + 3, -1, 29, 200, -1, 120, 177, 198, -1, 120, + 26, 198, -1, 120, 57, 26, 198, -1, 120, 59, + 26, 198, -1, 120, 178, 76, 178, 198, -1, -1, + 198, 199, -1, 44, -1, 52, -1, 64, -1, 65, + -1, 67, -1, 73, -1, 91, -1, 93, -1, 94, + -1, 96, -1, 97, -1, 98, -1, 100, -1, 147, + -1, 200, 201, -1, 201, -1, 9, 54, -1, 82, + 54, -1, 86, 54, -1, 47, 177, 203, -1, 203, + 204, -1, 204, -1, 135, 229, -1, 136, 229, -1, + 131, 54, -1, 118, 132, -1, 40, 228, -1, 41, + 228, -1, 42, 228, -1, 43, 228, -1, 35, 206, + -1, 28, 206, -1, 206, 207, -1, 207, -1, 6, + -1, 10, -1, 17, -1, 60, -1, 86, -1, 99, + -1, 127, -1, 138, 209, -1, 209, 210, -1, 210, + -1, 5, 229, -1, 30, 229, -1, 46, 229, -1, + 49, 229, -1, 103, 229, -1, 129, 229, -1, 130, + 229, -1, 218, -1, 53, 132, 174, -1, 36, -1, + 15, 229, -1, 18, 54, -1, 134, 229, -1, 32, + 212, -1, 66, 132, -1, 108, 132, -1, 71, 132, + -1, 70, 216, -1, 106, 226, -1, 122, 132, -1, + 124, 213, -1, 140, 178, -1, 140, 178, 214, -1, + 143, 222, -1, 115, 132, -1, 132, -1, 132, 31, + -1, -1, 132, 166, 132, 26, -1, 132, 166, 132, + -1, 214, 215, -1, 215, -1, 110, 54, -1, 55, + 178, -1, 216, 217, -1, 217, -1, 132, -1, 219, + 221, 220, -1, 219, 221, 132, -1, 55, -1, 89, + -1, 4, -1, 56, -1, 58, -1, 150, -1, 69, + -1, 52, -1, 33, -1, 222, 54, -1, 54, -1, + 223, 224, -1, 224, -1, 54, -1, 225, -1, 167, + 54, 34, 54, 168, -1, 226, 132, -1, 132, -1, + 227, 177, -1, 177, -1, 54, -1, 141, -1, 37, + -1, 54, -1, 31, -1, 231, 169, 232, 234, 170, + -1, 156, -1, 232, 233, 155, -1, 233, 155, -1, + 157, 166, 229, -1, 158, 166, 229, -1, 234, 235, + -1, 235, -1, 237, 169, 236, 238, 170, -1, 159, + 166, 229, 155, -1, 123, 166, 177, -1, 238, 239, + -1, 239, -1, 160, 166, 229, 169, 240, 170, -1, + 240, 241, 155, -1, 241, 155, -1, 161, 166, 229, + -1, 162, 166, 229, -1, 163, 166, 229, -1, 164, + 166, 229, -1, 165, 166, 229, -1 +}; + +/* YYRLINE[YYN] -- source line where rule number YYN was defined. */ +static const yytype_uint16 yyrline[] = +{ + 0, 300, 300, 304, 305, 306, 320, 321, 322, 323, + 324, 325, 326, 327, 328, 329, 330, 331, 332, 340, + 346, 355, 356, 357, 358, 359, 363, 364, 365, 369, + 373, 374, 378, 379, 380, 381, 382, 383, 384, 385, + 386, 387, 388, 389, 390, 391, 392, 401, 409, 410, + 420, 422, 424, 435, 437, 439, 444, 446, 448, 450, + 452, 454, 459, 461, 465, 472, 482, 484, 486, 488, + 490, 492, 494, 511, 516, 517, 521, 523, 525, 527, + 529, 531, 533, 535, 537, 539, 549, 551, 560, 568, + 569, 573, 574, 575, 576, 577, 578, 579, 580, 584, + 591, 601, 611, 620, 629, 638, 639, 643, 644, 645, + 646, 647, 648, 649, 658, 662, 667, 672, 685, 698, + 707, 708, 713, 714, 715, 716, 717, 718, 719, 720, + 721, 722, 723, 724, 725, 726, 730, 732, 737, 738, + 739, 747, 752, 754, 759, 760, 761, 762, 763, 764, + 765, 766, 774, 776, 781, 788, 798, 799, 800, 801, + 802, 803, 804, 820, 824, 825, 829, 830, 831, 832, + 833, 834, 835, 844, 845, 861, 867, 869, 871, 873, + 875, 878, 880, 891, 893, 895, 905, 907, 909, 911, + 913, 918, 920, 924, 928, 930, 935, 937, 941, 942, + 946, 947, 951, 966, 971, 979, 980, 984, 985, 986, + 987, 991, 992, 993, 1003, 1004, 1008, 1010, 1015, 1017, + 1021, 1026, 1027, 1031, 1032, 1036, 1045, 1046, 1050, 1051, + 1060, 1075, 1079, 1080, 1084, 1085, 1089, 1090, 1094, 1099, + 1103, 1107, 1108, 1112, 1117, 1118, 1122, 1124, 1126, 1128, + 1130 +}; +#endif + +#if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE +/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM. + First, the terminals, then, starting at YYNTOKENS, nonterminals. */ +static const char *const yytname[] = +{ + "$end", "error", "$undefined", "T_Age", "T_All", "T_Allan", "T_Auth", + "T_Autokey", "T_Automax", "T_Average", "T_Bclient", "T_Beacon", "T_Bias", + "T_Broadcast", "T_Broadcastclient", "T_Broadcastdelay", "T_Burst", + "T_Calibrate", "T_Calldelay", "T_Ceiling", "T_Clockstats", "T_Cohort", + "T_ControlKey", "T_Crypto", "T_Cryptostats", "T_Day", "T_Default", + "T_Digest", "T_Disable", "T_Discard", "T_Dispersion", "T_Double", + "T_Driftfile", "T_Drop", "T_Ellipsis", "T_Enable", "T_End", "T_False", + "T_File", "T_Filegen", "T_Flag1", "T_Flag2", "T_Flag3", "T_Flag4", + "T_Flake", "T_Floor", "T_Freq", "T_Fudge", "T_Host", "T_Huffpuff", + "T_Iburst", "T_Ident", "T_Ignore", "T_Includefile", "T_Integer", + "T_Interface", "T_Ipv4", "T_Ipv4_flag", "T_Ipv6", "T_Ipv6_flag", + "T_Kernel", "T_Key", "T_Keys", "T_Keysdir", "T_Kod", "T_Mssntp", + "T_Leapfile", "T_Limited", "T_Link", "T_Listen", "T_Logconfig", + "T_Logfile", "T_Loopstats", "T_Lowpriotrap", "T_Manycastclient", + "T_Manycastserver", "T_Mask", "T_Maxclock", "T_Maxdist", "T_Maxpoll", + "T_Minclock", "T_Mindist", "T_Minimum", "T_Minpoll", "T_Minsane", + "T_Mode", "T_Monitor", "T_Month", "T_Multicastclient", "T_Nic", + "T_Nolink", "T_Nomodify", "T_None", "T_Nopeer", "T_Noquery", + "T_Noselect", "T_Noserve", "T_Notrap", "T_Notrust", "T_Ntp", "T_Ntpport", + "T_NtpSignDsocket", "T_Orphan", "T_Panic", "T_Peer", "T_Peerstats", + "T_Phone", "T_Pid", "T_Pidfile", "T_Pool", "T_Port", "T_Preempt", + "T_Prefer", "T_Protostats", "T_Pw", "T_Qos", "T_Randfile", "T_Rawstats", + "T_Refid", "T_Requestkey", "T_Restrict", "T_Revoke", "T_Saveconfigdir", + "T_Server", "T_Setvar", "T_Sign", "T_Statistics", "T_Stats", + "T_Statsdir", "T_Step", "T_Stepout", "T_Stratum", "T_String", + "T_Sysstats", "T_Tick", "T_Time1", "T_Time2", "T_Timingstats", + "T_Tinker", "T_Tos", "T_Trap", "T_True", "T_Trustedkey", "T_Ttl", + "T_Type", "T_Unconfig", "T_Unpeer", "T_Version", "T_WanderThreshold", + "T_Week", "T_Wildcard", "T_Xleave", "T_Year", "T_Flag", "T_Void", + "T_EOC", "T_Simulate", "T_Beep_Delay", "T_Sim_Duration", + "T_Server_Offset", "T_Duration", "T_Freq_Offset", "T_Wander", "T_Jitter", + "T_Prop_Delay", "T_Proc_Delay", "'='", "'('", "')'", "'{'", "'}'", + "$accept", "configuration", "command_list", "command", "server_command", + "client_type", "address", "ip_address", "option_list", "option", + "unpeer_command", "unpeer_keyword", "other_mode_command", + "authentication_command", "crypto_command_line", "crypto_command_list", + "crypto_command", "orphan_mode_command", "tos_option_list", "tos_option", + "monitoring_command", "stats_list", "stat", "filegen_option_list", + "filegen_option", "filegen_type", "access_control_command", + "ac_flag_list", "access_control_flag", "discard_option_list", + "discard_option", "fudge_command", "fudge_factor_list", "fudge_factor", + "system_option_command", "system_option_list", "system_option", + "tinker_command", "tinker_option_list", "tinker_option", + "miscellaneous_command", "drift_parm", "variable_assign", + "trap_option_list", "trap_option", "log_config_list", + "log_config_command", "interface_command", "interface_nic", + "nic_rule_class", "nic_rule_action", "integer_list", + "integer_list_range", "integer_list_range_elt", "integer_range", + "string_list", "address_list", "boolean", "number", "simulate_command", + "sim_conf_start", "sim_init_statement_list", "sim_init_statement", + "sim_server_list", "sim_server", "sim_server_offset", "sim_server_name", + "sim_act_list", "sim_act", "sim_act_stmt_list", "sim_act_stmt", 0 +}; +#endif + +# ifdef YYPRINT +/* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to + token YYLEX-NUM. */ +static const yytype_uint16 yytoknum[] = +{ + 0, 256, 257, 258, 259, 260, 261, 262, 263, 264, + 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, + 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, + 285, 286, 287, 288, 289, 290, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, 304, + 305, 306, 307, 308, 309, 310, 311, 312, 313, 314, + 315, 316, 317, 318, 319, 320, 321, 322, 323, 324, + 325, 326, 327, 328, 329, 330, 331, 332, 333, 334, + 335, 336, 337, 338, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, 363, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, 374, + 375, 376, 377, 378, 379, 380, 381, 382, 383, 384, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, + 415, 416, 417, 418, 419, 420, 61, 40, 41, 123, + 125 +}; +# endif + +/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ +static const yytype_uint8 yyr1[] = +{ + 0, 171, 172, 173, 173, 173, 174, 174, 174, 174, + 174, 174, 174, 174, 174, 174, 174, 174, 174, 175, + 175, 176, 176, 176, 176, 176, 177, 177, 177, 178, + 179, 179, 180, 180, 180, 180, 180, 180, 180, 180, + 180, 180, 180, 180, 180, 180, 180, 181, 182, 182, + 183, 183, 183, 184, 184, 184, 184, 184, 184, 184, + 184, 184, 185, 185, 186, 186, 187, 187, 187, 187, + 187, 187, 187, 188, 189, 189, 190, 190, 190, 190, + 190, 190, 190, 190, 190, 190, 191, 191, 191, 192, + 192, 193, 193, 193, 193, 193, 193, 193, 193, 194, + 194, 195, 195, 195, 195, 195, 195, 196, 196, 196, + 196, 196, 196, 196, 197, 197, 197, 197, 197, 197, + 198, 198, 199, 199, 199, 199, 199, 199, 199, 199, + 199, 199, 199, 199, 199, 199, 200, 200, 201, 201, + 201, 202, 203, 203, 204, 204, 204, 204, 204, 204, + 204, 204, 205, 205, 206, 206, 207, 207, 207, 207, + 207, 207, 207, 208, 209, 209, 210, 210, 210, 210, + 210, 210, 210, 211, 211, 211, 211, 211, 211, 211, + 211, 211, 211, 211, 211, 211, 211, 211, 211, 211, + 211, 212, 212, 212, 213, 213, 214, 214, 215, 215, + 216, 216, 217, 218, 218, 219, 219, 220, 220, 220, + 220, 221, 221, 221, 222, 222, 223, 223, 224, 224, + 225, 226, 226, 227, 227, 228, 228, 228, 229, 229, + 230, 231, 232, 232, 233, 233, 234, 234, 235, 236, + 237, 238, 238, 239, 240, 240, 241, 241, 241, 241, + 241 +}; + +/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */ +static const yytype_uint8 yyr2[] = +{ + 0, 2, 1, 3, 2, 2, 0, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 3, + 2, 1, 1, 1, 1, 1, 1, 2, 2, 1, + 2, 1, 1, 2, 1, 1, 2, 2, 2, 1, + 1, 1, 1, 1, 2, 2, 2, 2, 1, 1, + 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 1, 0, 2, 1, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 1, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 3, 2, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, + 1, 2, 2, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 2, 3, 3, 4, 4, 5, + 0, 2, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 2, 1, 2, 2, + 2, 3, 2, 1, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 1, 1, 1, 1, 1, + 1, 1, 1, 2, 2, 1, 2, 2, 2, 2, + 2, 2, 2, 1, 3, 1, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 3, 2, + 2, 1, 2, 0, 4, 3, 2, 1, 2, 2, + 2, 1, 1, 3, 3, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 2, 1, 2, 1, 1, 1, + 5, 2, 1, 2, 1, 1, 1, 1, 1, 1, + 5, 1, 3, 2, 3, 3, 2, 1, 5, 4, + 3, 2, 1, 6, 3, 2, 3, 3, 3, 3, + 3 +}; + +/* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state + STATE-NUM when YYTABLE doesn't specify something else to do. Zero + means the default is an error. */ +static const yytype_uint8 yydefact[] = +{ + 0, 0, 0, 24, 50, 0, 0, 0, 63, 0, + 0, 193, 0, 175, 0, 0, 0, 205, 0, 0, + 0, 0, 0, 25, 0, 0, 206, 0, 23, 0, + 0, 22, 0, 0, 0, 0, 0, 21, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 48, 49, 231, + 0, 2, 0, 7, 0, 8, 0, 9, 10, 13, + 11, 12, 14, 15, 16, 17, 173, 0, 18, 0, + 5, 53, 229, 228, 176, 177, 54, 0, 0, 0, + 0, 0, 0, 0, 55, 62, 65, 156, 157, 158, + 159, 160, 161, 162, 153, 155, 0, 0, 0, 114, + 137, 191, 179, 152, 91, 92, 93, 94, 98, 95, + 96, 97, 0, 0, 0, 29, 0, 26, 6, 56, + 57, 180, 202, 183, 201, 182, 224, 51, 52, 61, + 222, 184, 181, 190, 58, 120, 0, 0, 120, 26, + 59, 185, 0, 186, 86, 90, 87, 178, 0, 0, + 0, 0, 0, 0, 0, 163, 165, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 73, 75, 187, + 218, 0, 60, 217, 219, 215, 189, 1, 0, 4, + 20, 47, 213, 212, 211, 0, 0, 71, 66, 67, + 68, 69, 72, 70, 64, 154, 138, 139, 140, 136, + 192, 106, 105, 0, 103, 104, 0, 88, 100, 27, + 28, 0, 0, 0, 0, 0, 0, 0, 0, 141, + 143, 174, 200, 223, 221, 116, 120, 120, 115, 0, + 0, 89, 166, 167, 168, 169, 170, 171, 172, 164, + 85, 76, 227, 225, 226, 78, 77, 83, 81, 82, + 80, 84, 79, 74, 0, 0, 188, 197, 0, 216, + 214, 3, 32, 0, 34, 35, 0, 0, 0, 0, + 39, 40, 41, 42, 0, 0, 43, 19, 31, 207, + 208, 209, 204, 210, 203, 0, 0, 0, 0, 101, + 113, 109, 111, 107, 108, 110, 112, 102, 99, 148, + 149, 150, 151, 147, 146, 144, 145, 142, 122, 123, + 124, 125, 126, 127, 128, 129, 130, 131, 132, 133, + 134, 135, 121, 117, 118, 120, 195, 199, 198, 196, + 0, 33, 36, 38, 37, 45, 44, 46, 30, 0, + 0, 0, 0, 0, 237, 0, 233, 119, 194, 0, + 234, 235, 0, 232, 230, 236, 0, 220, 240, 0, + 0, 0, 0, 0, 242, 0, 0, 238, 241, 239, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 243, 0, 245, 246, 247, 248, + 249, 250, 244 +}; + +/* YYDEFGOTO[NTERM-NUM]. */ +static const yytype_int16 yydefgoto[] = +{ + -1, 50, 51, 52, 53, 54, 126, 117, 277, 278, + 55, 56, 57, 58, 84, 85, 86, 59, 167, 168, + 60, 144, 112, 207, 208, 297, 61, 225, 322, 99, + 100, 62, 219, 220, 63, 94, 95, 64, 155, 156, + 65, 102, 143, 256, 257, 123, 124, 66, 67, 284, + 185, 176, 172, 173, 174, 131, 127, 245, 74, 68, + 69, 287, 288, 343, 344, 360, 345, 363, 364, 377, + 378 +}; + +/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing + STATE-NUM. */ +#define YYPACT_NINF -145 +static const yytype_int16 yypact[] = +{ + 26, -137, -31, -145, -145, -17, -25, -19, 164, 76, + -2, -111, 76, -145, 135, -29, -96, -145, -94, -86, + -72, -69, -65, -145, -29, -29, -145, -58, -145, -56, + -55, -145, -54, 29, 7, 31, -38, -145, -37, 135, + -34, -17, 94, 454, -30, -51, 51, -145, -145, -145, + 104, 247, -49, -145, -29, -145, -29, -145, -145, -145, + -145, -145, -145, -145, -145, -145, -145, 18, -145, -40, + -145, -145, -145, -145, -145, -145, -145, -1, 6, 12, + 21, 35, 107, 38, -145, 164, -145, -145, -145, -145, + -145, -145, -145, -145, 76, -145, 109, 119, 120, -2, + -145, 127, -145, 76, -145, -145, -145, -145, -145, -145, + -145, -145, -18, 46, 47, -145, 188, -145, 383, -145, + -145, -145, -145, -69, -145, -145, -145, -29, -29, -145, + -145, 48, -145, -145, -145, -145, -7, -4, -145, 108, + -145, -145, 17, -145, 135, -145, -145, -145, -17, -17, + -17, -17, -17, -17, -17, 94, -145, 132, 133, 15, + 134, -17, -17, -17, -17, 136, 138, 454, -145, -42, + -145, 140, -51, -145, -145, -145, 144, -145, 40, -145, + 435, -145, -145, -145, -145, 1, -126, -145, -145, -145, + -145, -145, -145, -145, -145, -145, -145, -145, -145, -145, + -145, -145, -145, 68, -145, -145, 50, -18, -145, -145, + -145, 15, 15, 15, 15, 69, 150, -17, -17, 188, + -145, -145, -145, -145, -145, 141, -145, -145, 141, -30, + 77, -145, -145, -145, -145, -145, -145, -145, -145, -145, + -145, -145, -145, -145, -145, -145, -145, -145, -145, -145, + -145, -145, -145, -145, -30, 156, -42, -145, 177, -145, + -145, -145, -145, -17, -145, -145, 159, 172, 173, 179, + -145, -145, -145, -145, 182, 193, -145, 435, -145, -145, + -145, -145, -145, -145, -145, 83, 84, -115, 96, -145, + -145, -145, -145, -145, -145, -145, -145, -145, -145, -145, + -145, -145, -145, -145, -145, -145, -145, -145, -145, -145, + -145, -145, -145, -145, -145, -145, -145, -145, -145, -145, + -145, -145, -145, 141, 141, -145, 227, -145, -145, -145, + 200, -145, -145, -145, -145, -145, -145, -145, -145, -17, + -17, 97, 111, -114, -145, 95, -145, 141, -145, 99, + -145, -145, -29, -145, -145, -145, 112, -145, -145, 115, + 113, -17, 118, -144, -145, 122, -17, -145, -145, -145, + 105, 81, 121, 124, 125, 126, 129, 55, 142, -17, + -17, -17, -17, -17, -145, 146, -145, -145, -145, -145, + -145, -145, -145 +}; + +/* YYPGOTO[NTERM-NUM]. */ +static const yytype_int16 yypgoto[] = +{ + -145, -145, -145, -47, -145, -145, -9, -33, -145, 16, + -145, -145, -145, -145, -145, -145, 211, -145, -145, 137, + -145, -145, -27, -145, 98, -145, -145, -136, -145, -145, + 204, -145, -145, 88, -145, 296, -79, -145, -145, 157, + -145, -145, -145, -145, 58, -145, 192, -145, -145, -145, + -145, -145, -145, 139, -145, -145, 291, 45, -41, -145, + -145, -145, 39, -145, -16, -145, -145, -145, -35, -145, + -48 +}; + +/* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If + positive, shift that token. If negative, reduce the rule which + number is the opposite. If zero, do what YYDEFACT says. + If YYTABLE_NINF, syntax error. */ +#define YYTABLE_NINF -7 +static const yytype_int16 yytable[] = +{ + 147, 139, 228, 170, 178, 279, 116, 96, 341, 341, + 201, 169, 145, 254, 72, 195, 362, 202, 70, 226, + 203, 101, 227, 71, 195, 138, 367, 1, 113, 75, + 114, 285, 286, 135, 2, 76, 118, 73, 119, 3, + 4, 5, 285, 286, 6, 180, 120, 181, 7, 8, + 204, 182, 242, 290, 9, 10, 354, 280, 11, 281, + 121, 12, 13, 122, 136, 14, 137, 125, 255, 243, + 183, 221, 205, 15, 129, 291, 130, 132, 133, 16, + 97, 17, 87, 134, 98, 140, 88, 184, 18, 19, + 323, 324, 20, 89, 141, 142, 21, 22, 146, 148, + 23, 24, 115, 115, 177, 175, 179, 232, 233, 234, + 235, 236, 237, 238, 25, 26, 171, 231, 223, 223, + 247, 248, 249, 250, 149, 209, 206, 27, 210, 186, + 28, 187, 29, 282, 30, 31, 90, 292, 188, 115, + 150, 32, 293, 151, 189, 33, 34, 35, 36, 37, + 38, 283, 39, 190, 40, 104, 244, 294, 200, 105, + 41, 192, 91, 196, 42, 43, 44, 191, 45, 46, + 193, 47, 48, 197, 198, 92, 305, 306, 209, 210, + 224, -6, 49, 230, 229, 308, 240, 241, 246, 347, + 251, 77, 252, 309, 258, 261, 325, 152, 260, 295, + 289, 303, 296, 93, 304, 310, 311, 106, 312, 326, + 328, 330, 78, 332, 313, 79, 372, 373, 374, 375, + 376, 327, 331, 153, 154, 384, 333, 334, 211, 212, + 213, 214, 314, 335, 315, 316, 336, 317, 318, 319, + 107, 320, 372, 373, 374, 375, 376, 337, 108, 339, + 340, 346, 109, 348, 349, 2, 299, 300, 301, 302, + 3, 4, 5, 352, 356, 6, 353, 357, 110, 7, + 8, 359, 111, 362, 371, 9, 10, 369, 80, 11, + 81, 361, 12, 13, 366, 82, 14, 379, 321, 83, + 380, 381, 382, 338, 15, 383, 194, 386, 350, 351, + 16, 392, 17, 199, 253, 298, 215, 307, 103, 18, + 19, 259, 239, 20, 329, 222, 128, 21, 22, 216, + 365, 23, 24, 217, 218, 370, 342, 355, 368, 385, + 0, 0, 0, 0, 0, 25, 26, 0, 387, 388, + 389, 390, 391, 358, 0, 0, 0, 0, 27, 0, + 0, 28, 0, 29, 0, 30, 31, 0, 0, 0, + 0, 0, 32, 0, 0, 0, 33, 34, 35, 36, + 37, 38, 0, 39, 0, 40, 0, 0, 0, 0, + 0, 41, 0, 0, 0, 42, 43, 44, 0, 45, + 46, 2, 47, 48, 0, 0, 3, 4, 5, 0, + 0, 6, -6, 49, 0, 7, 8, 0, 0, 0, + 0, 9, 10, 0, 0, 11, 0, 0, 12, 13, + 0, 0, 14, 0, 0, 0, 0, 0, 0, 0, + 15, 0, 0, 0, 0, 0, 16, 0, 17, 0, + 0, 0, 262, 0, 0, 18, 19, 263, 0, 20, + 0, 264, 0, 21, 22, 0, 0, 23, 24, 0, + 0, 0, 0, 0, 0, 157, 0, 0, 0, 0, + 0, 25, 26, 158, 0, 159, 0, 0, 0, 0, + 0, 0, 0, 0, 27, 265, 0, 28, 0, 29, + 0, 30, 31, 0, 0, 0, 266, 0, 32, 160, + 0, 0, 33, 34, 35, 36, 37, 38, 0, 39, + 0, 40, 0, 0, 267, 0, 0, 41, 268, 0, + 269, 42, 43, 44, 0, 45, 46, 0, 47, 48, + 270, 161, 162, 0, 163, 164, 0, 0, 165, 49, + 0, 0, 0, 0, 0, 0, 271, 272, 0, 0, + 0, 0, 0, 0, 0, 0, 166, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 273, 0, 274, 0, + 0, 0, 275, 0, 0, 0, 276 +}; + +static const yytype_int16 yycheck[] = +{ + 41, 34, 138, 54, 51, 4, 15, 9, 123, 123, + 28, 44, 39, 55, 31, 94, 160, 35, 155, 26, + 38, 132, 26, 54, 103, 34, 170, 1, 57, 54, + 59, 157, 158, 26, 8, 54, 132, 54, 132, 13, + 14, 15, 157, 158, 18, 54, 132, 56, 22, 23, + 68, 33, 37, 3, 28, 29, 170, 56, 32, 58, + 132, 35, 36, 132, 57, 39, 59, 132, 110, 54, + 52, 118, 90, 47, 132, 25, 132, 132, 132, 53, + 82, 55, 6, 54, 86, 54, 10, 69, 62, 63, + 226, 227, 66, 17, 132, 132, 70, 71, 132, 5, + 74, 75, 132, 132, 0, 54, 155, 148, 149, 150, + 151, 152, 153, 154, 88, 89, 167, 144, 127, 128, + 161, 162, 163, 164, 30, 132, 144, 101, 132, 169, + 104, 132, 106, 132, 108, 109, 60, 87, 132, 132, + 46, 115, 92, 49, 132, 119, 120, 121, 122, 123, + 124, 150, 126, 132, 128, 20, 141, 107, 31, 24, + 134, 54, 86, 54, 138, 139, 140, 132, 142, 143, + 132, 145, 146, 54, 54, 99, 217, 218, 132, 132, + 132, 155, 156, 166, 76, 44, 54, 54, 54, 325, + 54, 27, 54, 52, 54, 155, 229, 103, 54, 149, + 132, 132, 152, 127, 54, 64, 65, 72, 67, 132, + 54, 34, 48, 54, 73, 51, 161, 162, 163, 164, + 165, 254, 263, 129, 130, 170, 54, 54, 40, 41, + 42, 43, 91, 54, 93, 94, 54, 96, 97, 98, + 105, 100, 161, 162, 163, 164, 165, 54, 113, 166, + 166, 155, 117, 26, 54, 8, 211, 212, 213, 214, + 13, 14, 15, 166, 169, 18, 155, 168, 133, 22, + 23, 159, 137, 160, 169, 28, 29, 155, 114, 32, + 116, 166, 35, 36, 166, 121, 39, 166, 147, 125, + 166, 166, 166, 277, 47, 166, 85, 155, 339, 340, + 53, 155, 55, 99, 167, 207, 118, 219, 12, 62, + 63, 172, 155, 66, 256, 123, 25, 70, 71, 131, + 361, 74, 75, 135, 136, 366, 287, 343, 363, 377, + -1, -1, -1, -1, -1, 88, 89, -1, 379, 380, + 381, 382, 383, 352, -1, -1, -1, -1, 101, -1, + -1, 104, -1, 106, -1, 108, 109, -1, -1, -1, + -1, -1, 115, -1, -1, -1, 119, 120, 121, 122, + 123, 124, -1, 126, -1, 128, -1, -1, -1, -1, + -1, 134, -1, -1, -1, 138, 139, 140, -1, 142, + 143, 8, 145, 146, -1, -1, 13, 14, 15, -1, + -1, 18, 155, 156, -1, 22, 23, -1, -1, -1, + -1, 28, 29, -1, -1, 32, -1, -1, 35, 36, + -1, -1, 39, -1, -1, -1, -1, -1, -1, -1, + 47, -1, -1, -1, -1, -1, 53, -1, 55, -1, + -1, -1, 7, -1, -1, 62, 63, 12, -1, 66, + -1, 16, -1, 70, 71, -1, -1, 74, 75, -1, + -1, -1, -1, -1, -1, 11, -1, -1, -1, -1, + -1, 88, 89, 19, -1, 21, -1, -1, -1, -1, + -1, -1, -1, -1, 101, 50, -1, 104, -1, 106, + -1, 108, 109, -1, -1, -1, 61, -1, 115, 45, + -1, -1, 119, 120, 121, 122, 123, 124, -1, 126, + -1, 128, -1, -1, 79, -1, -1, 134, 83, -1, + 85, 138, 139, 140, -1, 142, 143, -1, 145, 146, + 95, 77, 78, -1, 80, 81, -1, -1, 84, 156, + -1, -1, -1, -1, -1, -1, 111, 112, -1, -1, + -1, -1, -1, -1, -1, -1, 102, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 141, -1, 143, -1, + -1, -1, 147, -1, -1, -1, 151 +}; + +/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing + symbol of state STATE-NUM. */ +static const yytype_uint8 yystos[] = +{ + 0, 1, 8, 13, 14, 15, 18, 22, 23, 28, + 29, 32, 35, 36, 39, 47, 53, 55, 62, 63, + 66, 70, 71, 74, 75, 88, 89, 101, 104, 106, + 108, 109, 115, 119, 120, 121, 122, 123, 124, 126, + 128, 134, 138, 139, 140, 142, 143, 145, 146, 156, + 172, 173, 174, 175, 176, 181, 182, 183, 184, 188, + 191, 197, 202, 205, 208, 211, 218, 219, 230, 231, + 155, 54, 31, 54, 229, 54, 54, 27, 48, 51, + 114, 116, 121, 125, 185, 186, 187, 6, 10, 17, + 60, 86, 99, 127, 206, 207, 9, 82, 86, 200, + 201, 132, 212, 206, 20, 24, 72, 105, 113, 117, + 133, 137, 193, 57, 59, 132, 177, 178, 132, 132, + 132, 132, 132, 216, 217, 132, 177, 227, 227, 132, + 132, 226, 132, 132, 54, 26, 57, 59, 177, 178, + 54, 132, 132, 213, 192, 193, 132, 229, 5, 30, + 46, 49, 103, 129, 130, 209, 210, 11, 19, 21, + 45, 77, 78, 80, 81, 84, 102, 189, 190, 178, + 54, 167, 223, 224, 225, 54, 222, 0, 174, 155, + 177, 177, 33, 52, 69, 221, 169, 132, 132, 132, + 132, 132, 54, 132, 187, 207, 54, 54, 54, 201, + 31, 28, 35, 38, 68, 90, 144, 194, 195, 132, + 132, 40, 41, 42, 43, 118, 131, 135, 136, 203, + 204, 174, 217, 177, 132, 198, 26, 26, 198, 76, + 166, 193, 229, 229, 229, 229, 229, 229, 229, 210, + 54, 54, 37, 54, 141, 228, 54, 229, 229, 229, + 229, 54, 54, 190, 55, 110, 214, 215, 54, 224, + 54, 155, 7, 12, 16, 50, 61, 79, 83, 85, + 95, 111, 112, 141, 143, 147, 151, 179, 180, 4, + 56, 58, 132, 150, 220, 157, 158, 232, 233, 132, + 3, 25, 87, 92, 107, 149, 152, 196, 195, 228, + 228, 228, 228, 132, 54, 229, 229, 204, 44, 52, + 64, 65, 67, 73, 91, 93, 94, 96, 97, 98, + 100, 147, 199, 198, 198, 178, 132, 178, 54, 215, + 34, 229, 54, 54, 54, 54, 54, 54, 180, 166, + 166, 123, 233, 234, 235, 237, 155, 198, 26, 54, + 229, 229, 166, 155, 170, 235, 169, 168, 177, 159, + 236, 166, 160, 238, 239, 229, 166, 170, 239, 155, + 229, 169, 161, 162, 163, 164, 165, 240, 241, 166, + 166, 166, 166, 166, 170, 241, 155, 229, 229, 229, + 229, 229, 155 +}; + +#define yyerrok (yyerrstatus = 0) +#define yyclearin (yychar = YYEMPTY) +#define YYEMPTY (-2) +#define YYEOF 0 + +#define YYACCEPT goto yyacceptlab +#define YYABORT goto yyabortlab +#define YYERROR goto yyerrorlab + + +/* Like YYERROR except do call yyerror. This remains here temporarily + to ease the transition to the new meaning of YYERROR, for GCC. + Once GCC version 2 has supplanted version 1, this can go. */ + +#define YYFAIL goto yyerrlab + +#define YYRECOVERING() (!!yyerrstatus) + +#define YYBACKUP(Token, Value) \ +do \ + if (yychar == YYEMPTY && yylen == 1) \ + { \ + yychar = (Token); \ + yylval = (Value); \ + yytoken = YYTRANSLATE (yychar); \ + YYPOPSTACK (1); \ + goto yybackup; \ + } \ + else \ + { \ + yyerror (YY_("syntax error: cannot back up")); \ + YYERROR; \ + } \ +while (YYID (0)) + + +#define YYTERROR 1 +#define YYERRCODE 256 + + +/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N]. + If N is 0, then set CURRENT to the empty location which ends + the previous symbol: RHS[0] (always defined). */ + +#define YYRHSLOC(Rhs, K) ((Rhs)[K]) +#ifndef YYLLOC_DEFAULT +# define YYLLOC_DEFAULT(Current, Rhs, N) \ + do \ + if (YYID (N)) \ + { \ + (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \ + (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \ + (Current).last_line = YYRHSLOC (Rhs, N).last_line; \ + (Current).last_column = YYRHSLOC (Rhs, N).last_column; \ + } \ + else \ + { \ + (Current).first_line = (Current).last_line = \ + YYRHSLOC (Rhs, 0).last_line; \ + (Current).first_column = (Current).last_column = \ + YYRHSLOC (Rhs, 0).last_column; \ + } \ + while (YYID (0)) +#endif + + +/* YY_LOCATION_PRINT -- Print the location on the stream. + This macro was not mandated originally: define only if we know + we won't break user code: when these are the locations we know. */ + +#ifndef YY_LOCATION_PRINT +# if YYLTYPE_IS_TRIVIAL +# define YY_LOCATION_PRINT(File, Loc) \ + fprintf (File, "%d.%d-%d.%d", \ + (Loc).first_line, (Loc).first_column, \ + (Loc).last_line, (Loc).last_column) +# else +# define YY_LOCATION_PRINT(File, Loc) ((void) 0) +# endif +#endif + + +/* YYLEX -- calling `yylex' with the right arguments. */ + +#ifdef YYLEX_PARAM +# define YYLEX yylex (YYLEX_PARAM) +#else +# define YYLEX yylex () +#endif + +/* Enable debugging if requested. */ +#if YYDEBUG + +# ifndef YYFPRINTF +# include /* INFRINGES ON USER NAME SPACE */ +# define YYFPRINTF fprintf +# endif + +# define YYDPRINTF(Args) \ +do { \ + if (yydebug) \ + YYFPRINTF Args; \ +} while (YYID (0)) + +# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \ +do { \ + if (yydebug) \ + { \ + YYFPRINTF (stderr, "%s ", Title); \ + yy_symbol_print (stderr, \ + Type, Value); \ + YYFPRINTF (stderr, "\n"); \ + } \ +} while (YYID (0)) + + +/*--------------------------------. +| Print this symbol on YYOUTPUT. | +`--------------------------------*/ + +/*ARGSUSED*/ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) +#else +static void +yy_symbol_value_print (yyoutput, yytype, yyvaluep) + FILE *yyoutput; + int yytype; + YYSTYPE const * const yyvaluep; +#endif +{ + if (!yyvaluep) + return; +# ifdef YYPRINT + if (yytype < YYNTOKENS) + YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep); +# else + YYUSE (yyoutput); +# endif + switch (yytype) + { + default: + break; + } +} + + +/*--------------------------------. +| Print this symbol on YYOUTPUT. | +`--------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) +#else +static void +yy_symbol_print (yyoutput, yytype, yyvaluep) + FILE *yyoutput; + int yytype; + YYSTYPE const * const yyvaluep; +#endif +{ + if (yytype < YYNTOKENS) + YYFPRINTF (yyoutput, "token %s (", yytname[yytype]); + else + YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]); + + yy_symbol_value_print (yyoutput, yytype, yyvaluep); + YYFPRINTF (yyoutput, ")"); +} + +/*------------------------------------------------------------------. +| yy_stack_print -- Print the state stack from its BOTTOM up to its | +| TOP (included). | +`------------------------------------------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop) +#else +static void +yy_stack_print (yybottom, yytop) + yytype_int16 *yybottom; + yytype_int16 *yytop; +#endif +{ + YYFPRINTF (stderr, "Stack now"); + for (; yybottom <= yytop; yybottom++) + { + int yybot = *yybottom; + YYFPRINTF (stderr, " %d", yybot); + } + YYFPRINTF (stderr, "\n"); +} + +# define YY_STACK_PRINT(Bottom, Top) \ +do { \ + if (yydebug) \ + yy_stack_print ((Bottom), (Top)); \ +} while (YYID (0)) + + +/*------------------------------------------------. +| Report that the YYRULE is going to be reduced. | +`------------------------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_reduce_print (YYSTYPE *yyvsp, int yyrule) +#else +static void +yy_reduce_print (yyvsp, yyrule) + YYSTYPE *yyvsp; + int yyrule; +#endif +{ + int yynrhs = yyr2[yyrule]; + int yyi; + unsigned long int yylno = yyrline[yyrule]; + YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n", + yyrule - 1, yylno); + /* The symbols being reduced. */ + for (yyi = 0; yyi < yynrhs; yyi++) + { + YYFPRINTF (stderr, " $%d = ", yyi + 1); + yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi], + &(yyvsp[(yyi + 1) - (yynrhs)]) + ); + YYFPRINTF (stderr, "\n"); + } +} + +# define YY_REDUCE_PRINT(Rule) \ +do { \ + if (yydebug) \ + yy_reduce_print (yyvsp, Rule); \ +} while (YYID (0)) + +/* Nonzero means print parse trace. It is left uninitialized so that + multiple parsers can coexist. */ +int yydebug; +#else /* !YYDEBUG */ +# define YYDPRINTF(Args) +# define YY_SYMBOL_PRINT(Title, Type, Value, Location) +# define YY_STACK_PRINT(Bottom, Top) +# define YY_REDUCE_PRINT(Rule) +#endif /* !YYDEBUG */ + + +/* YYINITDEPTH -- initial size of the parser's stacks. */ +#ifndef YYINITDEPTH +# define YYINITDEPTH 200 +#endif + +/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only + if the built-in stack extension method is used). + + Do not make this value too large; the results are undefined if + YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH) + evaluated with infinite-precision integer arithmetic. */ + +#ifndef YYMAXDEPTH +# define YYMAXDEPTH 10000 +#endif + + + +#if YYERROR_VERBOSE + +# ifndef yystrlen +# if defined __GLIBC__ && defined _STRING_H +# define yystrlen strlen +# else +/* Return the length of YYSTR. */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static YYSIZE_T +yystrlen (const char *yystr) +#else +static YYSIZE_T +yystrlen (yystr) + const char *yystr; +#endif +{ + YYSIZE_T yylen; + for (yylen = 0; yystr[yylen]; yylen++) + continue; + return yylen; +} +# endif +# endif + +# ifndef yystpcpy +# if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE +# define yystpcpy stpcpy +# else +/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in + YYDEST. */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static char * +yystpcpy (char *yydest, const char *yysrc) +#else +static char * +yystpcpy (yydest, yysrc) + char *yydest; + const char *yysrc; +#endif +{ + char *yyd = yydest; + const char *yys = yysrc; + + while ((*yyd++ = *yys++) != '\0') + continue; + + return yyd - 1; +} +# endif +# endif + +# ifndef yytnamerr +/* Copy to YYRES the contents of YYSTR after stripping away unnecessary + quotes and backslashes, so that it's suitable for yyerror. The + heuristic is that double-quoting is unnecessary unless the string + contains an apostrophe, a comma, or backslash (other than + backslash-backslash). YYSTR is taken from yytname. If YYRES is + null, do not copy; instead, return the length of what the result + would have been. */ +static YYSIZE_T +yytnamerr (char *yyres, const char *yystr) +{ + if (*yystr == '"') + { + YYSIZE_T yyn = 0; + char const *yyp = yystr; + + for (;;) + switch (*++yyp) + { + case '\'': + case ',': + goto do_not_strip_quotes; + + case '\\': + if (*++yyp != '\\') + goto do_not_strip_quotes; + /* Fall through. */ + default: + if (yyres) + yyres[yyn] = *yyp; + yyn++; + break; + + case '"': + if (yyres) + yyres[yyn] = '\0'; + return yyn; + } + do_not_strip_quotes: ; + } + + if (! yyres) + return yystrlen (yystr); + + return yystpcpy (yyres, yystr) - yyres; +} +# endif + +/* Copy into YYRESULT an error message about the unexpected token + YYCHAR while in state YYSTATE. Return the number of bytes copied, + including the terminating null byte. If YYRESULT is null, do not + copy anything; just return the number of bytes that would be + copied. As a special case, return 0 if an ordinary "syntax error" + message will do. Return YYSIZE_MAXIMUM if overflow occurs during + size calculation. */ +static YYSIZE_T +yysyntax_error (char *yyresult, int yystate, int yychar) +{ + int yyn = yypact[yystate]; + + if (! (YYPACT_NINF < yyn && yyn <= YYLAST)) + return 0; + else + { + int yytype = YYTRANSLATE (yychar); + YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]); + YYSIZE_T yysize = yysize0; + YYSIZE_T yysize1; + int yysize_overflow = 0; + enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; + char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; + int yyx; + +# if 0 + /* This is so xgettext sees the translatable formats that are + constructed on the fly. */ + YY_("syntax error, unexpected %s"); + YY_("syntax error, unexpected %s, expecting %s"); + YY_("syntax error, unexpected %s, expecting %s or %s"); + YY_("syntax error, unexpected %s, expecting %s or %s or %s"); + YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"); +# endif + char *yyfmt; + char const *yyf; + static char const yyunexpected[] = "syntax error, unexpected %s"; + static char const yyexpecting[] = ", expecting %s"; + static char const yyor[] = " or %s"; + char yyformat[sizeof yyunexpected + + sizeof yyexpecting - 1 + + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2) + * (sizeof yyor - 1))]; + char const *yyprefix = yyexpecting; + + /* Start YYX at -YYN if negative to avoid negative indexes in + YYCHECK. */ + int yyxbegin = yyn < 0 ? -yyn : 0; + + /* Stay within bounds of both yycheck and yytname. */ + int yychecklim = YYLAST - yyn + 1; + int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; + int yycount = 1; + + yyarg[0] = yytname[yytype]; + yyfmt = yystpcpy (yyformat, yyunexpected); + + for (yyx = yyxbegin; yyx < yyxend; ++yyx) + if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR) + { + if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) + { + yycount = 1; + yysize = yysize0; + yyformat[sizeof yyunexpected - 1] = '\0'; + break; + } + yyarg[yycount++] = yytname[yyx]; + yysize1 = yysize + yytnamerr (0, yytname[yyx]); + yysize_overflow |= (yysize1 < yysize); + yysize = yysize1; + yyfmt = yystpcpy (yyfmt, yyprefix); + yyprefix = yyor; + } + + yyf = YY_(yyformat); + yysize1 = yysize + yystrlen (yyf); + yysize_overflow |= (yysize1 < yysize); + yysize = yysize1; + + if (yysize_overflow) + return YYSIZE_MAXIMUM; + + if (yyresult) + { + /* Avoid sprintf, as that infringes on the user's name space. + Don't have undefined behavior even if the translation + produced a string with the wrong number of "%s"s. */ + char *yyp = yyresult; + int yyi = 0; + while ((*yyp = *yyf) != '\0') + { + if (*yyp == '%' && yyf[1] == 's' && yyi < yycount) + { + yyp += yytnamerr (yyp, yyarg[yyi++]); + yyf += 2; + } + else + { + yyp++; + yyf++; + } + } + } + return yysize; + } +} +#endif /* YYERROR_VERBOSE */ + + +/*-----------------------------------------------. +| Release the memory associated to this symbol. | +`-----------------------------------------------*/ + +/*ARGSUSED*/ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep) +#else +static void +yydestruct (yymsg, yytype, yyvaluep) + const char *yymsg; + int yytype; + YYSTYPE *yyvaluep; +#endif +{ + YYUSE (yyvaluep); + + if (!yymsg) + yymsg = "Deleting"; + YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp); + + switch (yytype) + { + + default: + break; + } +} + +/* Prevent warnings from -Wmissing-prototypes. */ +#ifdef YYPARSE_PARAM +#if defined __STDC__ || defined __cplusplus +int yyparse (void *YYPARSE_PARAM); +#else +int yyparse (); +#endif +#else /* ! YYPARSE_PARAM */ +#if defined __STDC__ || defined __cplusplus +int yyparse (void); +#else +int yyparse (); +#endif +#endif /* ! YYPARSE_PARAM */ + + +/* The lookahead symbol. */ +int yychar; + +/* The semantic value of the lookahead symbol. */ +YYSTYPE yylval; + +/* Number of syntax errors so far. */ +int yynerrs; + + + +/*-------------------------. +| yyparse or yypush_parse. | +`-------------------------*/ + +#ifdef YYPARSE_PARAM +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +int +yyparse (void *YYPARSE_PARAM) +#else +int +yyparse (YYPARSE_PARAM) + void *YYPARSE_PARAM; +#endif +#else /* ! YYPARSE_PARAM */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +int +yyparse (void) +#else +int +yyparse () + +#endif +#endif +{ + + + int yystate; + /* Number of tokens to shift before error messages enabled. */ + int yyerrstatus; + + /* The stacks and their tools: + `yyss': related to states. + `yyvs': related to semantic values. + + Refer to the stacks thru separate pointers, to allow yyoverflow + to reallocate them elsewhere. */ + + /* The state stack. */ + yytype_int16 yyssa[YYINITDEPTH]; + yytype_int16 *yyss; + yytype_int16 *yyssp; + + /* The semantic value stack. */ + YYSTYPE yyvsa[YYINITDEPTH]; + YYSTYPE *yyvs; + YYSTYPE *yyvsp; + + YYSIZE_T yystacksize; + + int yyn; + int yyresult; + /* Lookahead token as an internal (translated) token number. */ + int yytoken; + /* The variables used to return semantic value and location from the + action routines. */ + YYSTYPE yyval; + +#if YYERROR_VERBOSE + /* Buffer for error messages, and its allocated size. */ + char yymsgbuf[128]; + char *yymsg = yymsgbuf; + YYSIZE_T yymsg_alloc = sizeof yymsgbuf; +#endif + +#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N)) + + /* The number of symbols on the RHS of the reduced rule. + Keep to zero when no symbol should be popped. */ + int yylen = 0; + + yytoken = 0; + yyss = yyssa; + yyvs = yyvsa; + yystacksize = YYINITDEPTH; + + YYDPRINTF ((stderr, "Starting parse\n")); + + yystate = 0; + yyerrstatus = 0; + yynerrs = 0; + yychar = YYEMPTY; /* Cause a token to be read. */ + + /* Initialize stack pointers. + Waste one element of value and location stack + so that they stay on the same level as the state stack. + The wasted elements are never initialized. */ + yyssp = yyss; + yyvsp = yyvs; + + goto yysetstate; + +/*------------------------------------------------------------. +| yynewstate -- Push a new state, which is found in yystate. | +`------------------------------------------------------------*/ + yynewstate: + /* In all cases, when you get here, the value and location stacks + have just been pushed. So pushing a state here evens the stacks. */ + yyssp++; + + yysetstate: + *yyssp = yystate; + + if (yyss + yystacksize - 1 <= yyssp) + { + /* Get the current used size of the three stacks, in elements. */ + YYSIZE_T yysize = yyssp - yyss + 1; + +#ifdef yyoverflow + { + /* Give user a chance to reallocate the stack. Use copies of + these so that the &'s don't force the real ones into + memory. */ + YYSTYPE *yyvs1 = yyvs; + yytype_int16 *yyss1 = yyss; + + /* Each stack pointer address is followed by the size of the + data in use in that stack, in bytes. This used to be a + conditional around just the two extra args, but that might + be undefined if yyoverflow is a macro. */ + yyoverflow (YY_("memory exhausted"), + &yyss1, yysize * sizeof (*yyssp), + &yyvs1, yysize * sizeof (*yyvsp), + &yystacksize); + + yyss = yyss1; + yyvs = yyvs1; + } +#else /* no yyoverflow */ +# ifndef YYSTACK_RELOCATE + goto yyexhaustedlab; +# else + /* Extend the stack our own way. */ + if (YYMAXDEPTH <= yystacksize) + goto yyexhaustedlab; + yystacksize *= 2; + if (YYMAXDEPTH < yystacksize) + yystacksize = YYMAXDEPTH; + + { + yytype_int16 *yyss1 = yyss; + union yyalloc *yyptr = + (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); + if (! yyptr) + goto yyexhaustedlab; + YYSTACK_RELOCATE (yyss_alloc, yyss); + YYSTACK_RELOCATE (yyvs_alloc, yyvs); +# undef YYSTACK_RELOCATE + if (yyss1 != yyssa) + YYSTACK_FREE (yyss1); + } +# endif +#endif /* no yyoverflow */ + + yyssp = yyss + yysize - 1; + yyvsp = yyvs + yysize - 1; + + YYDPRINTF ((stderr, "Stack size increased to %lu\n", + (unsigned long int) yystacksize)); + + if (yyss + yystacksize - 1 <= yyssp) + YYABORT; + } + + YYDPRINTF ((stderr, "Entering state %d\n", yystate)); + + if (yystate == YYFINAL) + YYACCEPT; + + goto yybackup; + +/*-----------. +| yybackup. | +`-----------*/ +yybackup: + + /* Do appropriate processing given the current state. Read a + lookahead token if we need one and don't already have one. */ + + /* First try to decide what to do without reference to lookahead token. */ + yyn = yypact[yystate]; + if (yyn == YYPACT_NINF) + goto yydefault; + + /* Not known => get a lookahead token if don't already have one. */ + + /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */ + if (yychar == YYEMPTY) + { + YYDPRINTF ((stderr, "Reading a token: ")); + yychar = YYLEX; + } + + if (yychar <= YYEOF) + { + yychar = yytoken = YYEOF; + YYDPRINTF ((stderr, "Now at end of input.\n")); + } + else + { + yytoken = YYTRANSLATE (yychar); + YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc); + } + + /* If the proper action on seeing token YYTOKEN is to reduce or to + detect an error, take that action. */ + yyn += yytoken; + if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken) + goto yydefault; + yyn = yytable[yyn]; + if (yyn <= 0) + { + if (yyn == 0 || yyn == YYTABLE_NINF) + goto yyerrlab; + yyn = -yyn; + goto yyreduce; + } + + /* Count tokens shifted since error; after three, turn off error + status. */ + if (yyerrstatus) + yyerrstatus--; + + /* Shift the lookahead token. */ + YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc); + + /* Discard the shifted token. */ + yychar = YYEMPTY; + + yystate = yyn; + *++yyvsp = yylval; + + goto yynewstate; + + +/*-----------------------------------------------------------. +| yydefault -- do the default action for the current state. | +`-----------------------------------------------------------*/ +yydefault: + yyn = yydefact[yystate]; + if (yyn == 0) + goto yyerrlab; + goto yyreduce; + + +/*-----------------------------. +| yyreduce -- Do a reduction. | +`-----------------------------*/ +yyreduce: + /* yyn is the number of a rule to reduce with. */ + yylen = yyr2[yyn]; + + /* If YYLEN is nonzero, implement the default value of the action: + `$$ = $1'. + + Otherwise, the following line sets YYVAL to garbage. + This behavior is undocumented and Bison + users should not rely upon it. Assigning to YYVAL + unconditionally makes the parser a bit smaller, and it avoids a + GCC warning that YYVAL may be used uninitialized. */ + yyval = yyvsp[1-yylen]; + + + YY_REDUCE_PRINT (yyn); + switch (yyn) + { + case 5: + +/* Line 1455 of yacc.c */ +#line 307 "ntp_parser.y" + { + /* I will need to incorporate much more fine grained + * error messages. The following should suffice for + * the time being. + */ + msyslog(LOG_ERR, + "syntax error in %s line %d, column %d", + ip_file->fname, + ip_file->err_line_no, + ip_file->err_col_no); + } + break; + + case 19: + +/* Line 1455 of yacc.c */ +#line 341 "ntp_parser.y" + { + struct peer_node *my_node = create_peer_node((yyvsp[(1) - (3)].Integer), (yyvsp[(2) - (3)].Address_node), (yyvsp[(3) - (3)].Queue)); + if (my_node) + enqueue(cfgt.peers, my_node); + } + break; + + case 20: + +/* Line 1455 of yacc.c */ +#line 347 "ntp_parser.y" + { + struct peer_node *my_node = create_peer_node((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Address_node), NULL); + if (my_node) + enqueue(cfgt.peers, my_node); + } + break; + + case 27: + +/* Line 1455 of yacc.c */ +#line 364 "ntp_parser.y" + { (yyval.Address_node) = create_address_node((yyvsp[(2) - (2)].String), AF_INET); } + break; + + case 28: + +/* Line 1455 of yacc.c */ +#line 365 "ntp_parser.y" + { (yyval.Address_node) = create_address_node((yyvsp[(2) - (2)].String), AF_INET6); } + break; + + case 29: + +/* Line 1455 of yacc.c */ +#line 369 "ntp_parser.y" + { (yyval.Address_node) = create_address_node((yyvsp[(1) - (1)].String), 0); } + break; + + case 30: + +/* Line 1455 of yacc.c */ +#line 373 "ntp_parser.y" + { (yyval.Queue) = enqueue((yyvsp[(1) - (2)].Queue), (yyvsp[(2) - (2)].Attr_val)); } + break; + + case 31: + +/* Line 1455 of yacc.c */ +#line 374 "ntp_parser.y" + { (yyval.Queue) = enqueue_in_new_queue((yyvsp[(1) - (1)].Attr_val)); } + break; + + case 32: + +/* Line 1455 of yacc.c */ +#line 378 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[(1) - (1)].Integer)); } + break; + + case 33: + +/* Line 1455 of yacc.c */ +#line 379 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Double)); } + break; + + case 34: + +/* Line 1455 of yacc.c */ +#line 380 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[(1) - (1)].Integer)); } + break; + + case 35: + +/* Line 1455 of yacc.c */ +#line 381 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[(1) - (1)].Integer)); } + break; + + case 36: + +/* Line 1455 of yacc.c */ +#line 382 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Integer)); } + break; + + case 37: + +/* Line 1455 of yacc.c */ +#line 383 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Integer)); } + break; + + case 38: + +/* Line 1455 of yacc.c */ +#line 384 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Integer)); } + break; + + case 39: + +/* Line 1455 of yacc.c */ +#line 385 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[(1) - (1)].Integer)); } + break; + + case 40: + +/* Line 1455 of yacc.c */ +#line 386 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[(1) - (1)].Integer)); } + break; + + case 41: + +/* Line 1455 of yacc.c */ +#line 387 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[(1) - (1)].Integer)); } + break; + + case 42: + +/* Line 1455 of yacc.c */ +#line 388 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[(1) - (1)].Integer)); } + break; + + case 43: + +/* Line 1455 of yacc.c */ +#line 389 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[(1) - (1)].Integer)); } + break; + + case 44: + +/* Line 1455 of yacc.c */ +#line 390 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Integer)); } + break; + + case 45: + +/* Line 1455 of yacc.c */ +#line 391 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Integer)); } + break; + + case 46: + +/* Line 1455 of yacc.c */ +#line 392 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Integer)); } + break; + + case 47: + +/* Line 1455 of yacc.c */ +#line 402 "ntp_parser.y" + { + struct unpeer_node *my_node = create_unpeer_node((yyvsp[(2) - (2)].Address_node)); + if (my_node) + enqueue(cfgt.unpeers, my_node); + } + break; + + case 50: + +/* Line 1455 of yacc.c */ +#line 421 "ntp_parser.y" + { cfgt.broadcastclient = 1; } + break; + + case 51: + +/* Line 1455 of yacc.c */ +#line 423 "ntp_parser.y" + { append_queue(cfgt.manycastserver, (yyvsp[(2) - (2)].Queue)); } + break; + + case 52: + +/* Line 1455 of yacc.c */ +#line 425 "ntp_parser.y" + { append_queue(cfgt.multicastclient, (yyvsp[(2) - (2)].Queue)); } + break; + + case 53: + +/* Line 1455 of yacc.c */ +#line 436 "ntp_parser.y" + { enqueue(cfgt.vars, create_attr_ival((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Integer))); } + break; + + case 54: + +/* Line 1455 of yacc.c */ +#line 438 "ntp_parser.y" + { cfgt.auth.control_key = (yyvsp[(2) - (2)].Integer); } + break; + + case 55: + +/* Line 1455 of yacc.c */ +#line 440 "ntp_parser.y" + { + cfgt.auth.cryptosw++; + append_queue(cfgt.auth.crypto_cmd_list, (yyvsp[(2) - (2)].Queue)); + } + break; + + case 56: + +/* Line 1455 of yacc.c */ +#line 445 "ntp_parser.y" + { cfgt.auth.keys = (yyvsp[(2) - (2)].String); } + break; + + case 57: + +/* Line 1455 of yacc.c */ +#line 447 "ntp_parser.y" + { cfgt.auth.keysdir = (yyvsp[(2) - (2)].String); } + break; + + case 58: + +/* Line 1455 of yacc.c */ +#line 449 "ntp_parser.y" + { cfgt.auth.request_key = (yyvsp[(2) - (2)].Integer); } + break; + + case 59: + +/* Line 1455 of yacc.c */ +#line 451 "ntp_parser.y" + { cfgt.auth.revoke = (yyvsp[(2) - (2)].Integer); } + break; + + case 60: + +/* Line 1455 of yacc.c */ +#line 453 "ntp_parser.y" + { cfgt.auth.trusted_key_list = (yyvsp[(2) - (2)].Queue); } + break; + + case 61: + +/* Line 1455 of yacc.c */ +#line 455 "ntp_parser.y" + { cfgt.auth.ntp_signd_socket = (yyvsp[(2) - (2)].String); } + break; + + case 63: + +/* Line 1455 of yacc.c */ +#line 461 "ntp_parser.y" + { (yyval.Queue) = create_queue(); } + break; + + case 64: + +/* Line 1455 of yacc.c */ +#line 466 "ntp_parser.y" + { + if ((yyvsp[(2) - (2)].Attr_val) != NULL) + (yyval.Queue) = enqueue((yyvsp[(1) - (2)].Queue), (yyvsp[(2) - (2)].Attr_val)); + else + (yyval.Queue) = (yyvsp[(1) - (2)].Queue); + } + break; + + case 65: + +/* Line 1455 of yacc.c */ +#line 473 "ntp_parser.y" + { + if ((yyvsp[(1) - (1)].Attr_val) != NULL) + (yyval.Queue) = enqueue_in_new_queue((yyvsp[(1) - (1)].Attr_val)); + else + (yyval.Queue) = create_queue(); + } + break; + + case 66: + +/* Line 1455 of yacc.c */ +#line 483 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_sval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].String)); } + break; + + case 67: + +/* Line 1455 of yacc.c */ +#line 485 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_sval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].String)); } + break; + + case 68: + +/* Line 1455 of yacc.c */ +#line 487 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_sval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].String)); } + break; + + case 69: + +/* Line 1455 of yacc.c */ +#line 489 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_sval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].String)); } + break; + + case 70: + +/* Line 1455 of yacc.c */ +#line 491 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_sval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].String)); } + break; + + case 71: + +/* Line 1455 of yacc.c */ +#line 493 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_sval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].String)); } + break; + + case 72: + +/* Line 1455 of yacc.c */ +#line 495 "ntp_parser.y" + { + (yyval.Attr_val) = NULL; + cfgt.auth.revoke = (yyvsp[(2) - (2)].Integer); + msyslog(LOG_WARNING, + "'crypto revoke %d' is deprecated, " + "please use 'revoke %d' instead.", + cfgt.auth.revoke, cfgt.auth.revoke); + } + break; + + case 73: + +/* Line 1455 of yacc.c */ +#line 512 "ntp_parser.y" + { append_queue(cfgt.orphan_cmds,(yyvsp[(2) - (2)].Queue)); } + break; + + case 74: + +/* Line 1455 of yacc.c */ +#line 516 "ntp_parser.y" + { (yyval.Queue) = enqueue((yyvsp[(1) - (2)].Queue), (yyvsp[(2) - (2)].Attr_val)); } + break; + + case 75: + +/* Line 1455 of yacc.c */ +#line 517 "ntp_parser.y" + { (yyval.Queue) = enqueue_in_new_queue((yyvsp[(1) - (1)].Attr_val)); } + break; + + case 76: + +/* Line 1455 of yacc.c */ +#line 522 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (2)].Integer), (double)(yyvsp[(2) - (2)].Integer)); } + break; + + case 77: + +/* Line 1455 of yacc.c */ +#line 524 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (2)].Integer), (double)(yyvsp[(2) - (2)].Integer)); } + break; + + case 78: + +/* Line 1455 of yacc.c */ +#line 526 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (2)].Integer), (double)(yyvsp[(2) - (2)].Integer)); } + break; + + case 79: + +/* Line 1455 of yacc.c */ +#line 528 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (2)].Integer), (double)(yyvsp[(2) - (2)].Integer)); } + break; + + case 80: + +/* Line 1455 of yacc.c */ +#line 530 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Double)); } + break; + + case 81: + +/* Line 1455 of yacc.c */ +#line 532 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Double)); } + break; + + case 82: + +/* Line 1455 of yacc.c */ +#line 534 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Double)); } + break; + + case 83: + +/* Line 1455 of yacc.c */ +#line 536 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Double)); } + break; + + case 84: + +/* Line 1455 of yacc.c */ +#line 538 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (2)].Integer), (double)(yyvsp[(2) - (2)].Integer)); } + break; + + case 85: + +/* Line 1455 of yacc.c */ +#line 540 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (2)].Integer), (double)(yyvsp[(2) - (2)].Integer)); } + break; + + case 86: + +/* Line 1455 of yacc.c */ +#line 550 "ntp_parser.y" + { append_queue(cfgt.stats_list, (yyvsp[(2) - (2)].Queue)); } + break; + + case 87: + +/* Line 1455 of yacc.c */ +#line 552 "ntp_parser.y" + { + if (input_from_file) + cfgt.stats_dir = (yyvsp[(2) - (2)].String); + else { + free((yyvsp[(2) - (2)].String)); + yyerror("statsdir remote configuration ignored"); + } + } + break; + + case 88: + +/* Line 1455 of yacc.c */ +#line 561 "ntp_parser.y" + { + enqueue(cfgt.filegen_opts, + create_filegen_node((yyvsp[(2) - (3)].Integer), (yyvsp[(3) - (3)].Queue))); + } + break; + + case 89: + +/* Line 1455 of yacc.c */ +#line 568 "ntp_parser.y" + { (yyval.Queue) = enqueue((yyvsp[(1) - (2)].Queue), create_ival((yyvsp[(2) - (2)].Integer))); } + break; + + case 90: + +/* Line 1455 of yacc.c */ +#line 569 "ntp_parser.y" + { (yyval.Queue) = enqueue_in_new_queue(create_ival((yyvsp[(1) - (1)].Integer))); } + break; + + case 99: + +/* Line 1455 of yacc.c */ +#line 585 "ntp_parser.y" + { + if ((yyvsp[(2) - (2)].Attr_val) != NULL) + (yyval.Queue) = enqueue((yyvsp[(1) - (2)].Queue), (yyvsp[(2) - (2)].Attr_val)); + else + (yyval.Queue) = (yyvsp[(1) - (2)].Queue); + } + break; + + case 100: + +/* Line 1455 of yacc.c */ +#line 592 "ntp_parser.y" + { + if ((yyvsp[(1) - (1)].Attr_val) != NULL) + (yyval.Queue) = enqueue_in_new_queue((yyvsp[(1) - (1)].Attr_val)); + else + (yyval.Queue) = create_queue(); + } + break; + + case 101: + +/* Line 1455 of yacc.c */ +#line 602 "ntp_parser.y" + { + if (input_from_file) + (yyval.Attr_val) = create_attr_sval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].String)); + else { + (yyval.Attr_val) = NULL; + free((yyvsp[(2) - (2)].String)); + yyerror("filegen file remote configuration ignored"); + } + } + break; + + case 102: + +/* Line 1455 of yacc.c */ +#line 612 "ntp_parser.y" + { + if (input_from_file) + (yyval.Attr_val) = create_attr_ival((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Integer)); + else { + (yyval.Attr_val) = NULL; + yyerror("filegen type remote configuration ignored"); + } + } + break; + + case 103: + +/* Line 1455 of yacc.c */ +#line 621 "ntp_parser.y" + { + if (input_from_file) + (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[(1) - (1)].Integer)); + else { + (yyval.Attr_val) = NULL; + yyerror("filegen link remote configuration ignored"); + } + } + break; + + case 104: + +/* Line 1455 of yacc.c */ +#line 630 "ntp_parser.y" + { + if (input_from_file) + (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[(1) - (1)].Integer)); + else { + (yyval.Attr_val) = NULL; + yyerror("filegen nolink remote configuration ignored"); + } + } + break; + + case 105: + +/* Line 1455 of yacc.c */ +#line 638 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[(1) - (1)].Integer)); } + break; + + case 106: + +/* Line 1455 of yacc.c */ +#line 639 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[(1) - (1)].Integer)); } + break; + + case 114: + +/* Line 1455 of yacc.c */ +#line 659 "ntp_parser.y" + { + append_queue(cfgt.discard_opts, (yyvsp[(2) - (2)].Queue)); + } + break; + + case 115: + +/* Line 1455 of yacc.c */ +#line 663 "ntp_parser.y" + { + enqueue(cfgt.restrict_opts, + create_restrict_node((yyvsp[(2) - (3)].Address_node), NULL, (yyvsp[(3) - (3)].Queue), ip_file->line_no)); + } + break; + + case 116: + +/* Line 1455 of yacc.c */ +#line 668 "ntp_parser.y" + { + enqueue(cfgt.restrict_opts, + create_restrict_node(NULL, NULL, (yyvsp[(3) - (3)].Queue), ip_file->line_no)); + } + break; + + case 117: + +/* Line 1455 of yacc.c */ +#line 673 "ntp_parser.y" + { + enqueue(cfgt.restrict_opts, + create_restrict_node( + create_address_node( + estrdup("0.0.0.0"), + AF_INET), + create_address_node( + estrdup("0.0.0.0"), + AF_INET), + (yyvsp[(4) - (4)].Queue), + ip_file->line_no)); + } + break; + + case 118: + +/* Line 1455 of yacc.c */ +#line 686 "ntp_parser.y" + { + enqueue(cfgt.restrict_opts, + create_restrict_node( + create_address_node( + estrdup("::"), + AF_INET6), + create_address_node( + estrdup("::"), + AF_INET6), + (yyvsp[(4) - (4)].Queue), + ip_file->line_no)); + } + break; + + case 119: + +/* Line 1455 of yacc.c */ +#line 699 "ntp_parser.y" + { + enqueue(cfgt.restrict_opts, + create_restrict_node((yyvsp[(2) - (5)].Address_node), (yyvsp[(4) - (5)].Address_node), (yyvsp[(5) - (5)].Queue), ip_file->line_no)); + } + break; + + case 120: + +/* Line 1455 of yacc.c */ +#line 707 "ntp_parser.y" + { (yyval.Queue) = create_queue(); } + break; + + case 121: + +/* Line 1455 of yacc.c */ +#line 709 "ntp_parser.y" + { (yyval.Queue) = enqueue((yyvsp[(1) - (2)].Queue), create_ival((yyvsp[(2) - (2)].Integer))); } + break; + + case 136: + +/* Line 1455 of yacc.c */ +#line 731 "ntp_parser.y" + { (yyval.Queue) = enqueue((yyvsp[(1) - (2)].Queue), (yyvsp[(2) - (2)].Attr_val)); } + break; + + case 137: + +/* Line 1455 of yacc.c */ +#line 733 "ntp_parser.y" + { (yyval.Queue) = enqueue_in_new_queue((yyvsp[(1) - (1)].Attr_val)); } + break; + + case 138: + +/* Line 1455 of yacc.c */ +#line 737 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Integer)); } + break; + + case 139: + +/* Line 1455 of yacc.c */ +#line 738 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Integer)); } + break; + + case 140: + +/* Line 1455 of yacc.c */ +#line 739 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Integer)); } + break; + + case 141: + +/* Line 1455 of yacc.c */ +#line 748 "ntp_parser.y" + { enqueue(cfgt.fudge, create_addr_opts_node((yyvsp[(2) - (3)].Address_node), (yyvsp[(3) - (3)].Queue))); } + break; + + case 142: + +/* Line 1455 of yacc.c */ +#line 753 "ntp_parser.y" + { enqueue((yyvsp[(1) - (2)].Queue), (yyvsp[(2) - (2)].Attr_val)); } + break; + + case 143: + +/* Line 1455 of yacc.c */ +#line 755 "ntp_parser.y" + { (yyval.Queue) = enqueue_in_new_queue((yyvsp[(1) - (1)].Attr_val)); } + break; + + case 144: + +/* Line 1455 of yacc.c */ +#line 759 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Double)); } + break; + + case 145: + +/* Line 1455 of yacc.c */ +#line 760 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Double)); } + break; + + case 146: + +/* Line 1455 of yacc.c */ +#line 761 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Integer)); } + break; + + case 147: + +/* Line 1455 of yacc.c */ +#line 762 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_sval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].String)); } + break; + + case 148: + +/* Line 1455 of yacc.c */ +#line 763 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Integer)); } + break; + + case 149: + +/* Line 1455 of yacc.c */ +#line 764 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Integer)); } + break; + + case 150: + +/* Line 1455 of yacc.c */ +#line 765 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Integer)); } + break; + + case 151: + +/* Line 1455 of yacc.c */ +#line 766 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Integer)); } + break; + + case 152: + +/* Line 1455 of yacc.c */ +#line 775 "ntp_parser.y" + { append_queue(cfgt.enable_opts, (yyvsp[(2) - (2)].Queue)); } + break; + + case 153: + +/* Line 1455 of yacc.c */ +#line 777 "ntp_parser.y" + { append_queue(cfgt.disable_opts, (yyvsp[(2) - (2)].Queue)); } + break; + + case 154: + +/* Line 1455 of yacc.c */ +#line 782 "ntp_parser.y" + { + if ((yyvsp[(2) - (2)].Attr_val) != NULL) + (yyval.Queue) = enqueue((yyvsp[(1) - (2)].Queue), (yyvsp[(2) - (2)].Attr_val)); + else + (yyval.Queue) = (yyvsp[(1) - (2)].Queue); + } + break; + + case 155: + +/* Line 1455 of yacc.c */ +#line 789 "ntp_parser.y" + { + if ((yyvsp[(1) - (1)].Attr_val) != NULL) + (yyval.Queue) = enqueue_in_new_queue((yyvsp[(1) - (1)].Attr_val)); + else + (yyval.Queue) = create_queue(); + } + break; + + case 156: + +/* Line 1455 of yacc.c */ +#line 798 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[(1) - (1)].Integer)); } + break; + + case 157: + +/* Line 1455 of yacc.c */ +#line 799 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[(1) - (1)].Integer)); } + break; + + case 158: + +/* Line 1455 of yacc.c */ +#line 800 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[(1) - (1)].Integer)); } + break; + + case 159: + +/* Line 1455 of yacc.c */ +#line 801 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[(1) - (1)].Integer)); } + break; + + case 160: + +/* Line 1455 of yacc.c */ +#line 802 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[(1) - (1)].Integer)); } + break; + + case 161: + +/* Line 1455 of yacc.c */ +#line 803 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[(1) - (1)].Integer)); } + break; + + case 162: + +/* Line 1455 of yacc.c */ +#line 805 "ntp_parser.y" + { + if (input_from_file) + (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[(1) - (1)].Integer)); + else { + (yyval.Attr_val) = NULL; + yyerror("enable/disable stats remote configuration ignored"); + } + } + break; + + case 163: + +/* Line 1455 of yacc.c */ +#line 820 "ntp_parser.y" + { append_queue(cfgt.tinker, (yyvsp[(2) - (2)].Queue)); } + break; + + case 164: + +/* Line 1455 of yacc.c */ +#line 824 "ntp_parser.y" + { (yyval.Queue) = enqueue((yyvsp[(1) - (2)].Queue), (yyvsp[(2) - (2)].Attr_val)); } + break; + + case 165: + +/* Line 1455 of yacc.c */ +#line 825 "ntp_parser.y" + { (yyval.Queue) = enqueue_in_new_queue((yyvsp[(1) - (1)].Attr_val)); } + break; + + case 166: + +/* Line 1455 of yacc.c */ +#line 829 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Double)); } + break; + + case 167: + +/* Line 1455 of yacc.c */ +#line 830 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Double)); } + break; + + case 168: + +/* Line 1455 of yacc.c */ +#line 831 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Double)); } + break; + + case 169: + +/* Line 1455 of yacc.c */ +#line 832 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Double)); } + break; + + case 170: + +/* Line 1455 of yacc.c */ +#line 833 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Double)); } + break; + + case 171: + +/* Line 1455 of yacc.c */ +#line 834 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Double)); } + break; + + case 172: + +/* Line 1455 of yacc.c */ +#line 835 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Double)); } + break; + + case 174: + +/* Line 1455 of yacc.c */ +#line 846 "ntp_parser.y" + { + if (curr_include_level >= MAXINCLUDELEVEL) { + fprintf(stderr, "getconfig: Maximum include file level exceeded.\n"); + msyslog(LOG_ERR, "getconfig: Maximum include file level exceeded."); + } + else { + fp[curr_include_level + 1] = F_OPEN(FindConfig((yyvsp[(2) - (3)].String)), "r"); + if (fp[curr_include_level + 1] == NULL) { + fprintf(stderr, "getconfig: Couldn't open <%s>\n", FindConfig((yyvsp[(2) - (3)].String))); + msyslog(LOG_ERR, "getconfig: Couldn't open <%s>", FindConfig((yyvsp[(2) - (3)].String))); + } + else + ip_file = fp[++curr_include_level]; + } + } + break; + + case 175: + +/* Line 1455 of yacc.c */ +#line 862 "ntp_parser.y" + { + while (curr_include_level != -1) + FCLOSE(fp[curr_include_level--]); + } + break; + + case 176: + +/* Line 1455 of yacc.c */ +#line 868 "ntp_parser.y" + { enqueue(cfgt.vars, create_attr_dval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Double))); } + break; + + case 177: + +/* Line 1455 of yacc.c */ +#line 870 "ntp_parser.y" + { enqueue(cfgt.vars, create_attr_ival((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Integer))); } + break; + + case 178: + +/* Line 1455 of yacc.c */ +#line 872 "ntp_parser.y" + { enqueue(cfgt.vars, create_attr_dval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Double))); } + break; + + case 179: + +/* Line 1455 of yacc.c */ +#line 874 "ntp_parser.y" + { /* Null action, possibly all null parms */ } + break; + + case 180: + +/* Line 1455 of yacc.c */ +#line 876 "ntp_parser.y" + { enqueue(cfgt.vars, create_attr_sval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].String))); } + break; + + case 181: + +/* Line 1455 of yacc.c */ +#line 879 "ntp_parser.y" + { enqueue(cfgt.vars, create_attr_sval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].String))); } + break; + + case 182: + +/* Line 1455 of yacc.c */ +#line 881 "ntp_parser.y" + { + if (input_from_file) + enqueue(cfgt.vars, + create_attr_sval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].String))); + else { + free((yyvsp[(2) - (2)].String)); + yyerror("logfile remote configuration ignored"); + } + } + break; + + case 183: + +/* Line 1455 of yacc.c */ +#line 892 "ntp_parser.y" + { append_queue(cfgt.logconfig, (yyvsp[(2) - (2)].Queue)); } + break; + + case 184: + +/* Line 1455 of yacc.c */ +#line 894 "ntp_parser.y" + { append_queue(cfgt.phone, (yyvsp[(2) - (2)].Queue)); } + break; + + case 185: + +/* Line 1455 of yacc.c */ +#line 896 "ntp_parser.y" + { + if (input_from_file) + enqueue(cfgt.vars, + create_attr_sval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].String))); + else { + free((yyvsp[(2) - (2)].String)); + yyerror("saveconfigdir remote configuration ignored"); + } + } + break; + + case 186: + +/* Line 1455 of yacc.c */ +#line 906 "ntp_parser.y" + { enqueue(cfgt.setvar, (yyvsp[(2) - (2)].Set_var)); } + break; + + case 187: + +/* Line 1455 of yacc.c */ +#line 908 "ntp_parser.y" + { enqueue(cfgt.trap, create_addr_opts_node((yyvsp[(2) - (2)].Address_node), NULL)); } + break; + + case 188: + +/* Line 1455 of yacc.c */ +#line 910 "ntp_parser.y" + { enqueue(cfgt.trap, create_addr_opts_node((yyvsp[(2) - (3)].Address_node), (yyvsp[(3) - (3)].Queue))); } + break; + + case 189: + +/* Line 1455 of yacc.c */ +#line 912 "ntp_parser.y" + { append_queue(cfgt.ttl, (yyvsp[(2) - (2)].Queue)); } + break; + + case 190: + +/* Line 1455 of yacc.c */ +#line 914 "ntp_parser.y" + { enqueue(cfgt.qos, create_attr_sval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].String))); } + break; + + case 191: + +/* Line 1455 of yacc.c */ +#line 919 "ntp_parser.y" + { enqueue(cfgt.vars, create_attr_sval(T_Driftfile, (yyvsp[(1) - (1)].String))); } + break; + + case 192: + +/* Line 1455 of yacc.c */ +#line 921 "ntp_parser.y" + { enqueue(cfgt.vars, create_attr_dval(T_WanderThreshold, (yyvsp[(2) - (2)].Double))); + enqueue(cfgt.vars, create_attr_sval(T_Driftfile, (yyvsp[(1) - (2)].String))); } + break; + + case 193: + +/* Line 1455 of yacc.c */ +#line 924 "ntp_parser.y" + { enqueue(cfgt.vars, create_attr_sval(T_Driftfile, "\0")); } + break; + + case 194: + +/* Line 1455 of yacc.c */ +#line 929 "ntp_parser.y" + { (yyval.Set_var) = create_setvar_node((yyvsp[(1) - (4)].String), (yyvsp[(3) - (4)].String), (yyvsp[(4) - (4)].Integer)); } + break; + + case 195: + +/* Line 1455 of yacc.c */ +#line 931 "ntp_parser.y" + { (yyval.Set_var) = create_setvar_node((yyvsp[(1) - (3)].String), (yyvsp[(3) - (3)].String), 0); } + break; + + case 196: + +/* Line 1455 of yacc.c */ +#line 936 "ntp_parser.y" + { (yyval.Queue) = enqueue((yyvsp[(1) - (2)].Queue), (yyvsp[(2) - (2)].Attr_val)); } + break; + + case 197: + +/* Line 1455 of yacc.c */ +#line 937 "ntp_parser.y" + { (yyval.Queue) = enqueue_in_new_queue((yyvsp[(1) - (1)].Attr_val)); } + break; + + case 198: + +/* Line 1455 of yacc.c */ +#line 941 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Integer)); } + break; + + case 199: + +/* Line 1455 of yacc.c */ +#line 942 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_pval((yyvsp[(1) - (2)].Integer), (yyvsp[(2) - (2)].Address_node)); } + break; + + case 200: + +/* Line 1455 of yacc.c */ +#line 946 "ntp_parser.y" + { (yyval.Queue) = enqueue((yyvsp[(1) - (2)].Queue), (yyvsp[(2) - (2)].Attr_val)); } + break; + + case 201: + +/* Line 1455 of yacc.c */ +#line 947 "ntp_parser.y" + { (yyval.Queue) = enqueue_in_new_queue((yyvsp[(1) - (1)].Attr_val)); } + break; + + case 202: + +/* Line 1455 of yacc.c */ +#line 952 "ntp_parser.y" + { + char prefix = (yyvsp[(1) - (1)].String)[0]; + char *type = (yyvsp[(1) - (1)].String) + 1; + + if (prefix != '+' && prefix != '-' && prefix != '=') { + yyerror("Logconfig prefix is not '+', '-' or '='\n"); + } + else + (yyval.Attr_val) = create_attr_sval(prefix, estrdup(type)); + YYFREE((yyvsp[(1) - (1)].String)); + } + break; + + case 203: + +/* Line 1455 of yacc.c */ +#line 967 "ntp_parser.y" + { + enqueue(cfgt.nic_rules, + create_nic_rule_node((yyvsp[(3) - (3)].Integer), NULL, (yyvsp[(2) - (3)].Integer))); + } + break; + + case 204: + +/* Line 1455 of yacc.c */ +#line 972 "ntp_parser.y" + { + enqueue(cfgt.nic_rules, + create_nic_rule_node(0, (yyvsp[(3) - (3)].String), (yyvsp[(2) - (3)].Integer))); + } + break; + + case 214: + +/* Line 1455 of yacc.c */ +#line 1003 "ntp_parser.y" + { (yyval.Queue) = enqueue((yyvsp[(1) - (2)].Queue), create_ival((yyvsp[(2) - (2)].Integer))); } + break; + + case 215: + +/* Line 1455 of yacc.c */ +#line 1004 "ntp_parser.y" + { (yyval.Queue) = enqueue_in_new_queue(create_ival((yyvsp[(1) - (1)].Integer))); } + break; + + case 216: + +/* Line 1455 of yacc.c */ +#line 1009 "ntp_parser.y" + { (yyval.Queue) = enqueue((yyvsp[(1) - (2)].Queue), (yyvsp[(2) - (2)].Attr_val)); } + break; + + case 217: + +/* Line 1455 of yacc.c */ +#line 1011 "ntp_parser.y" + { (yyval.Queue) = enqueue_in_new_queue((yyvsp[(1) - (1)].Attr_val)); } + break; + + case 218: + +/* Line 1455 of yacc.c */ +#line 1016 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_ival('i', (yyvsp[(1) - (1)].Integer)); } + break; + + case 220: + +/* Line 1455 of yacc.c */ +#line 1022 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_shorts('-', (yyvsp[(2) - (5)].Integer), (yyvsp[(4) - (5)].Integer)); } + break; + + case 221: + +/* Line 1455 of yacc.c */ +#line 1026 "ntp_parser.y" + { (yyval.Queue) = enqueue((yyvsp[(1) - (2)].Queue), create_pval((yyvsp[(2) - (2)].String))); } + break; + + case 222: + +/* Line 1455 of yacc.c */ +#line 1027 "ntp_parser.y" + { (yyval.Queue) = enqueue_in_new_queue(create_pval((yyvsp[(1) - (1)].String))); } + break; + + case 223: + +/* Line 1455 of yacc.c */ +#line 1031 "ntp_parser.y" + { (yyval.Queue) = enqueue((yyvsp[(1) - (2)].Queue), (yyvsp[(2) - (2)].Address_node)); } + break; + + case 224: + +/* Line 1455 of yacc.c */ +#line 1032 "ntp_parser.y" + { (yyval.Queue) = enqueue_in_new_queue((yyvsp[(1) - (1)].Address_node)); } + break; + + case 225: + +/* Line 1455 of yacc.c */ +#line 1037 "ntp_parser.y" + { + if ((yyvsp[(1) - (1)].Integer) != 0 && (yyvsp[(1) - (1)].Integer) != 1) { + yyerror("Integer value is not boolean (0 or 1). Assuming 1"); + (yyval.Integer) = 1; + } + else + (yyval.Integer) = (yyvsp[(1) - (1)].Integer); + } + break; + + case 226: + +/* Line 1455 of yacc.c */ +#line 1045 "ntp_parser.y" + { (yyval.Integer) = 1; } + break; + + case 227: + +/* Line 1455 of yacc.c */ +#line 1046 "ntp_parser.y" + { (yyval.Integer) = 0; } + break; + + case 228: + +/* Line 1455 of yacc.c */ +#line 1050 "ntp_parser.y" + { (yyval.Double) = (double)(yyvsp[(1) - (1)].Integer); } + break; + + case 230: + +/* Line 1455 of yacc.c */ +#line 1061 "ntp_parser.y" + { + cfgt.sim_details = create_sim_node((yyvsp[(3) - (5)].Queue), (yyvsp[(4) - (5)].Queue)); + + /* Reset the old_config_style variable */ + old_config_style = 1; + } + break; + + case 231: + +/* Line 1455 of yacc.c */ +#line 1075 "ntp_parser.y" + { old_config_style = 0; } + break; + + case 232: + +/* Line 1455 of yacc.c */ +#line 1079 "ntp_parser.y" + { (yyval.Queue) = enqueue((yyvsp[(1) - (3)].Queue), (yyvsp[(2) - (3)].Attr_val)); } + break; + + case 233: + +/* Line 1455 of yacc.c */ +#line 1080 "ntp_parser.y" + { (yyval.Queue) = enqueue_in_new_queue((yyvsp[(1) - (2)].Attr_val)); } + break; + + case 234: + +/* Line 1455 of yacc.c */ +#line 1084 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (3)].Integer), (yyvsp[(3) - (3)].Double)); } + break; + + case 235: + +/* Line 1455 of yacc.c */ +#line 1085 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (3)].Integer), (yyvsp[(3) - (3)].Double)); } + break; + + case 236: + +/* Line 1455 of yacc.c */ +#line 1089 "ntp_parser.y" + { (yyval.Queue) = enqueue((yyvsp[(1) - (2)].Queue), (yyvsp[(2) - (2)].Sim_server)); } + break; + + case 237: + +/* Line 1455 of yacc.c */ +#line 1090 "ntp_parser.y" + { (yyval.Queue) = enqueue_in_new_queue((yyvsp[(1) - (1)].Sim_server)); } + break; + + case 238: + +/* Line 1455 of yacc.c */ +#line 1095 "ntp_parser.y" + { (yyval.Sim_server) = create_sim_server((yyvsp[(1) - (5)].Address_node), (yyvsp[(3) - (5)].Double), (yyvsp[(4) - (5)].Queue)); } + break; + + case 239: + +/* Line 1455 of yacc.c */ +#line 1099 "ntp_parser.y" + { (yyval.Double) = (yyvsp[(3) - (4)].Double); } + break; + + case 240: + +/* Line 1455 of yacc.c */ +#line 1103 "ntp_parser.y" + { (yyval.Address_node) = (yyvsp[(3) - (3)].Address_node); } + break; + + case 241: + +/* Line 1455 of yacc.c */ +#line 1107 "ntp_parser.y" + { (yyval.Queue) = enqueue((yyvsp[(1) - (2)].Queue), (yyvsp[(2) - (2)].Sim_script)); } + break; + + case 242: + +/* Line 1455 of yacc.c */ +#line 1108 "ntp_parser.y" + { (yyval.Queue) = enqueue_in_new_queue((yyvsp[(1) - (1)].Sim_script)); } + break; + + case 243: + +/* Line 1455 of yacc.c */ +#line 1113 "ntp_parser.y" + { (yyval.Sim_script) = create_sim_script_info((yyvsp[(3) - (6)].Double), (yyvsp[(5) - (6)].Queue)); } + break; + + case 244: + +/* Line 1455 of yacc.c */ +#line 1117 "ntp_parser.y" + { (yyval.Queue) = enqueue((yyvsp[(1) - (3)].Queue), (yyvsp[(2) - (3)].Attr_val)); } + break; + + case 245: + +/* Line 1455 of yacc.c */ +#line 1118 "ntp_parser.y" + { (yyval.Queue) = enqueue_in_new_queue((yyvsp[(1) - (2)].Attr_val)); } + break; + + case 246: + +/* Line 1455 of yacc.c */ +#line 1123 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (3)].Integer), (yyvsp[(3) - (3)].Double)); } + break; + + case 247: + +/* Line 1455 of yacc.c */ +#line 1125 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (3)].Integer), (yyvsp[(3) - (3)].Double)); } + break; + + case 248: + +/* Line 1455 of yacc.c */ +#line 1127 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (3)].Integer), (yyvsp[(3) - (3)].Double)); } + break; + + case 249: + +/* Line 1455 of yacc.c */ +#line 1129 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (3)].Integer), (yyvsp[(3) - (3)].Double)); } + break; + + case 250: + +/* Line 1455 of yacc.c */ +#line 1131 "ntp_parser.y" + { (yyval.Attr_val) = create_attr_dval((yyvsp[(1) - (3)].Integer), (yyvsp[(3) - (3)].Double)); } + break; + + + +/* Line 1455 of yacc.c */ +#line 3661 "ntp_parser.c" + default: break; + } + YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); + + YYPOPSTACK (yylen); + yylen = 0; + YY_STACK_PRINT (yyss, yyssp); + + *++yyvsp = yyval; + + /* Now `shift' the result of the reduction. Determine what state + that goes to, based on the state we popped back to and the rule + number reduced by. */ + + yyn = yyr1[yyn]; + + yystate = yypgoto[yyn - YYNTOKENS] + *yyssp; + if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp) + yystate = yytable[yystate]; + else + yystate = yydefgoto[yyn - YYNTOKENS]; + + goto yynewstate; + + +/*------------------------------------. +| yyerrlab -- here on detecting error | +`------------------------------------*/ +yyerrlab: + /* If not already recovering from an error, report this error. */ + if (!yyerrstatus) + { + ++yynerrs; +#if ! YYERROR_VERBOSE + yyerror (YY_("syntax error")); +#else + { + YYSIZE_T yysize = yysyntax_error (0, yystate, yychar); + if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM) + { + YYSIZE_T yyalloc = 2 * yysize; + if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM)) + yyalloc = YYSTACK_ALLOC_MAXIMUM; + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); + yymsg = (char *) YYSTACK_ALLOC (yyalloc); + if (yymsg) + yymsg_alloc = yyalloc; + else + { + yymsg = yymsgbuf; + yymsg_alloc = sizeof yymsgbuf; + } + } + + if (0 < yysize && yysize <= yymsg_alloc) + { + (void) yysyntax_error (yymsg, yystate, yychar); + yyerror (yymsg); + } + else + { + yyerror (YY_("syntax error")); + if (yysize != 0) + goto yyexhaustedlab; + } + } +#endif + } + + + + if (yyerrstatus == 3) + { + /* If just tried and failed to reuse lookahead token after an + error, discard it. */ + + if (yychar <= YYEOF) + { + /* Return failure if at end of input. */ + if (yychar == YYEOF) + YYABORT; + } + else + { + yydestruct ("Error: discarding", + yytoken, &yylval); + yychar = YYEMPTY; + } + } + + /* Else will try to reuse lookahead token after shifting the error + token. */ + goto yyerrlab1; + + +/*---------------------------------------------------. +| yyerrorlab -- error raised explicitly by YYERROR. | +`---------------------------------------------------*/ +yyerrorlab: + + /* Pacify compilers like GCC when the user code never invokes + YYERROR and the label yyerrorlab therefore never appears in user + code. */ + if (/*CONSTCOND*/ 0) + goto yyerrorlab; + + /* Do not reclaim the symbols of the rule which action triggered + this YYERROR. */ + YYPOPSTACK (yylen); + yylen = 0; + YY_STACK_PRINT (yyss, yyssp); + yystate = *yyssp; + goto yyerrlab1; + + +/*-------------------------------------------------------------. +| yyerrlab1 -- common code for both syntax error and YYERROR. | +`-------------------------------------------------------------*/ +yyerrlab1: + yyerrstatus = 3; /* Each real token shifted decrements this. */ + + for (;;) + { + yyn = yypact[yystate]; + if (yyn != YYPACT_NINF) + { + yyn += YYTERROR; + if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) + { + yyn = yytable[yyn]; + if (0 < yyn) + break; + } + } + + /* Pop the current state because it cannot handle the error token. */ + if (yyssp == yyss) + YYABORT; + + + yydestruct ("Error: popping", + yystos[yystate], yyvsp); + YYPOPSTACK (1); + yystate = *yyssp; + YY_STACK_PRINT (yyss, yyssp); + } + + *++yyvsp = yylval; + + + /* Shift the error token. */ + YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp); + + yystate = yyn; + goto yynewstate; + + +/*-------------------------------------. +| yyacceptlab -- YYACCEPT comes here. | +`-------------------------------------*/ +yyacceptlab: + yyresult = 0; + goto yyreturn; + +/*-----------------------------------. +| yyabortlab -- YYABORT comes here. | +`-----------------------------------*/ +yyabortlab: + yyresult = 1; + goto yyreturn; + +#if !defined(yyoverflow) || YYERROR_VERBOSE +/*-------------------------------------------------. +| yyexhaustedlab -- memory exhaustion comes here. | +`-------------------------------------------------*/ +yyexhaustedlab: + yyerror (YY_("memory exhausted")); + yyresult = 2; + /* Fall through. */ +#endif + +yyreturn: + if (yychar != YYEMPTY) + yydestruct ("Cleanup: discarding lookahead", + yytoken, &yylval); + /* Do not reclaim the symbols of the rule which action triggered + this YYABORT or YYACCEPT. */ + YYPOPSTACK (yylen); + YY_STACK_PRINT (yyss, yyssp); + while (yyssp != yyss) + { + yydestruct ("Cleanup: popping", + yystos[*yyssp], yyvsp); + YYPOPSTACK (1); + } +#ifndef yyoverflow + if (yyss != yyssa) + YYSTACK_FREE (yyss); +#endif +#if YYERROR_VERBOSE + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); +#endif + /* Make sure YYID is used. */ + return YYID (yyresult); +} + + + +/* Line 1675 of yacc.c */ +#line 1135 "ntp_parser.y" + + +void yyerror (char *msg) +{ + int retval; + + ip_file->err_line_no = ip_file->prev_token_line_no; + ip_file->err_col_no = ip_file->prev_token_col_no; + + msyslog(LOG_ERR, + "line %d column %d %s", + ip_file->err_line_no, + ip_file->err_col_no, + msg); + if (!input_from_file) { + /* Save the error message in the correct buffer */ + retval = snprintf(remote_config.err_msg + remote_config.err_pos, + MAXLINE - remote_config.err_pos, + "column %d %s", + ip_file->err_col_no, msg); + + /* Increment the value of err_pos */ + if (retval > 0) + remote_config.err_pos += retval; + + /* Increment the number of errors */ + ++remote_config.no_errors; + } +} + + +/* + * token_name - convert T_ token integers to text + * example: token_name(T_Server) returns "T_Server" + */ +const char * +token_name( + int token + ) +{ + return yytname[YYTRANSLATE(token)]; +} + + +/* Initial Testing function -- ignore +int main(int argc, char *argv[]) +{ + ip_file = FOPEN(argv[1], "r"); + if (!ip_file) { + fprintf(stderr, "ERROR!! Could not open file: %s\n", argv[1]); + } + key_scanner = create_keyword_scanner(keyword_list); + print_keyword_scanner(key_scanner, 0); + yyparse(); + return 0; +} +*/ + + diff -urN src/contrib/ntp/ntpd/ntp_parser.h src.ntp/contrib/ntp/ntpd/ntp_parser.h --- src/contrib/ntp/ntpd/ntp_parser.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/ntp_parser.h 2010-07-09 04:17:43.000000000 +0200 @@ -0,0 +1,407 @@ + +/* A Bison parser, made by GNU Bison 2.4.1. */ + +/* Skeleton interface for Bison's Yacc-like parsers in C + + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 + Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . */ + +/* As a special exception, you may create a larger work that contains + part or all of the Bison parser skeleton and distribute that work + under terms of your choice, so long as that work isn't itself a + parser generator using the skeleton or a modified version thereof + as a parser skeleton. Alternatively, if you modify or redistribute + the parser skeleton itself, you may (at your option) remove this + special exception, which will cause the skeleton and the resulting + Bison output files to be licensed under the GNU General Public + License without this special exception. + + This special exception was added by the Free Software Foundation in + version 2.2 of Bison. */ + + +/* Tokens. */ +#ifndef YYTOKENTYPE +# define YYTOKENTYPE + /* Put the tokens into the symbol table, so that GDB and other debuggers + know about them. */ + enum yytokentype { + T_Age = 258, + T_All = 259, + T_Allan = 260, + T_Auth = 261, + T_Autokey = 262, + T_Automax = 263, + T_Average = 264, + T_Bclient = 265, + T_Beacon = 266, + T_Bias = 267, + T_Broadcast = 268, + T_Broadcastclient = 269, + T_Broadcastdelay = 270, + T_Burst = 271, + T_Calibrate = 272, + T_Calldelay = 273, + T_Ceiling = 274, + T_Clockstats = 275, + T_Cohort = 276, + T_ControlKey = 277, + T_Crypto = 278, + T_Cryptostats = 279, + T_Day = 280, + T_Default = 281, + T_Digest = 282, + T_Disable = 283, + T_Discard = 284, + T_Dispersion = 285, + T_Double = 286, + T_Driftfile = 287, + T_Drop = 288, + T_Ellipsis = 289, + T_Enable = 290, + T_End = 291, + T_False = 292, + T_File = 293, + T_Filegen = 294, + T_Flag1 = 295, + T_Flag2 = 296, + T_Flag3 = 297, + T_Flag4 = 298, + T_Flake = 299, + T_Floor = 300, + T_Freq = 301, + T_Fudge = 302, + T_Host = 303, + T_Huffpuff = 304, + T_Iburst = 305, + T_Ident = 306, + T_Ignore = 307, + T_Includefile = 308, + T_Integer = 309, + T_Interface = 310, + T_Ipv4 = 311, + T_Ipv4_flag = 312, + T_Ipv6 = 313, + T_Ipv6_flag = 314, + T_Kernel = 315, + T_Key = 316, + T_Keys = 317, + T_Keysdir = 318, + T_Kod = 319, + T_Mssntp = 320, + T_Leapfile = 321, + T_Limited = 322, + T_Link = 323, + T_Listen = 324, + T_Logconfig = 325, + T_Logfile = 326, + T_Loopstats = 327, + T_Lowpriotrap = 328, + T_Manycastclient = 329, + T_Manycastserver = 330, + T_Mask = 331, + T_Maxclock = 332, + T_Maxdist = 333, + T_Maxpoll = 334, + T_Minclock = 335, + T_Mindist = 336, + T_Minimum = 337, + T_Minpoll = 338, + T_Minsane = 339, + T_Mode = 340, + T_Monitor = 341, + T_Month = 342, + T_Multicastclient = 343, + T_Nic = 344, + T_Nolink = 345, + T_Nomodify = 346, + T_None = 347, + T_Nopeer = 348, + T_Noquery = 349, + T_Noselect = 350, + T_Noserve = 351, + T_Notrap = 352, + T_Notrust = 353, + T_Ntp = 354, + T_Ntpport = 355, + T_NtpSignDsocket = 356, + T_Orphan = 357, + T_Panic = 358, + T_Peer = 359, + T_Peerstats = 360, + T_Phone = 361, + T_Pid = 362, + T_Pidfile = 363, + T_Pool = 364, + T_Port = 365, + T_Preempt = 366, + T_Prefer = 367, + T_Protostats = 368, + T_Pw = 369, + T_Qos = 370, + T_Randfile = 371, + T_Rawstats = 372, + T_Refid = 373, + T_Requestkey = 374, + T_Restrict = 375, + T_Revoke = 376, + T_Saveconfigdir = 377, + T_Server = 378, + T_Setvar = 379, + T_Sign = 380, + T_Statistics = 381, + T_Stats = 382, + T_Statsdir = 383, + T_Step = 384, + T_Stepout = 385, + T_Stratum = 386, + T_String = 387, + T_Sysstats = 388, + T_Tick = 389, + T_Time1 = 390, + T_Time2 = 391, + T_Timingstats = 392, + T_Tinker = 393, + T_Tos = 394, + T_Trap = 395, + T_True = 396, + T_Trustedkey = 397, + T_Ttl = 398, + T_Type = 399, + T_Unconfig = 400, + T_Unpeer = 401, + T_Version = 402, + T_WanderThreshold = 403, + T_Week = 404, + T_Wildcard = 405, + T_Xleave = 406, + T_Year = 407, + T_Flag = 408, + T_Void = 409, + T_EOC = 410, + T_Simulate = 411, + T_Beep_Delay = 412, + T_Sim_Duration = 413, + T_Server_Offset = 414, + T_Duration = 415, + T_Freq_Offset = 416, + T_Wander = 417, + T_Jitter = 418, + T_Prop_Delay = 419, + T_Proc_Delay = 420 + }; +#endif +/* Tokens. */ +#define T_Age 258 +#define T_All 259 +#define T_Allan 260 +#define T_Auth 261 +#define T_Autokey 262 +#define T_Automax 263 +#define T_Average 264 +#define T_Bclient 265 +#define T_Beacon 266 +#define T_Bias 267 +#define T_Broadcast 268 +#define T_Broadcastclient 269 +#define T_Broadcastdelay 270 +#define T_Burst 271 +#define T_Calibrate 272 +#define T_Calldelay 273 +#define T_Ceiling 274 +#define T_Clockstats 275 +#define T_Cohort 276 +#define T_ControlKey 277 +#define T_Crypto 278 +#define T_Cryptostats 279 +#define T_Day 280 +#define T_Default 281 +#define T_Digest 282 +#define T_Disable 283 +#define T_Discard 284 +#define T_Dispersion 285 +#define T_Double 286 +#define T_Driftfile 287 +#define T_Drop 288 +#define T_Ellipsis 289 +#define T_Enable 290 +#define T_End 291 +#define T_False 292 +#define T_File 293 +#define T_Filegen 294 +#define T_Flag1 295 +#define T_Flag2 296 +#define T_Flag3 297 +#define T_Flag4 298 +#define T_Flake 299 +#define T_Floor 300 +#define T_Freq 301 +#define T_Fudge 302 +#define T_Host 303 +#define T_Huffpuff 304 +#define T_Iburst 305 +#define T_Ident 306 +#define T_Ignore 307 +#define T_Includefile 308 +#define T_Integer 309 +#define T_Interface 310 +#define T_Ipv4 311 +#define T_Ipv4_flag 312 +#define T_Ipv6 313 +#define T_Ipv6_flag 314 +#define T_Kernel 315 +#define T_Key 316 +#define T_Keys 317 +#define T_Keysdir 318 +#define T_Kod 319 +#define T_Mssntp 320 +#define T_Leapfile 321 +#define T_Limited 322 +#define T_Link 323 +#define T_Listen 324 +#define T_Logconfig 325 +#define T_Logfile 326 +#define T_Loopstats 327 +#define T_Lowpriotrap 328 +#define T_Manycastclient 329 +#define T_Manycastserver 330 +#define T_Mask 331 +#define T_Maxclock 332 +#define T_Maxdist 333 +#define T_Maxpoll 334 +#define T_Minclock 335 +#define T_Mindist 336 +#define T_Minimum 337 +#define T_Minpoll 338 +#define T_Minsane 339 +#define T_Mode 340 +#define T_Monitor 341 +#define T_Month 342 +#define T_Multicastclient 343 +#define T_Nic 344 +#define T_Nolink 345 +#define T_Nomodify 346 +#define T_None 347 +#define T_Nopeer 348 +#define T_Noquery 349 +#define T_Noselect 350 +#define T_Noserve 351 +#define T_Notrap 352 +#define T_Notrust 353 +#define T_Ntp 354 +#define T_Ntpport 355 +#define T_NtpSignDsocket 356 +#define T_Orphan 357 +#define T_Panic 358 +#define T_Peer 359 +#define T_Peerstats 360 +#define T_Phone 361 +#define T_Pid 362 +#define T_Pidfile 363 +#define T_Pool 364 +#define T_Port 365 +#define T_Preempt 366 +#define T_Prefer 367 +#define T_Protostats 368 +#define T_Pw 369 +#define T_Qos 370 +#define T_Randfile 371 +#define T_Rawstats 372 +#define T_Refid 373 +#define T_Requestkey 374 +#define T_Restrict 375 +#define T_Revoke 376 +#define T_Saveconfigdir 377 +#define T_Server 378 +#define T_Setvar 379 +#define T_Sign 380 +#define T_Statistics 381 +#define T_Stats 382 +#define T_Statsdir 383 +#define T_Step 384 +#define T_Stepout 385 +#define T_Stratum 386 +#define T_String 387 +#define T_Sysstats 388 +#define T_Tick 389 +#define T_Time1 390 +#define T_Time2 391 +#define T_Timingstats 392 +#define T_Tinker 393 +#define T_Tos 394 +#define T_Trap 395 +#define T_True 396 +#define T_Trustedkey 397 +#define T_Ttl 398 +#define T_Type 399 +#define T_Unconfig 400 +#define T_Unpeer 401 +#define T_Version 402 +#define T_WanderThreshold 403 +#define T_Week 404 +#define T_Wildcard 405 +#define T_Xleave 406 +#define T_Year 407 +#define T_Flag 408 +#define T_Void 409 +#define T_EOC 410 +#define T_Simulate 411 +#define T_Beep_Delay 412 +#define T_Sim_Duration 413 +#define T_Server_Offset 414 +#define T_Duration 415 +#define T_Freq_Offset 416 +#define T_Wander 417 +#define T_Jitter 418 +#define T_Prop_Delay 419 +#define T_Proc_Delay 420 + + + + +#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED +typedef union YYSTYPE +{ + +/* Line 1676 of yacc.c */ +#line 50 "ntp_parser.y" + + char *String; + double Double; + int Integer; + void *VoidPtr; + queue *Queue; + struct attr_val *Attr_val; + struct address_node *Address_node; + struct setvar_node *Set_var; + + /* Simulation types */ + server_info *Sim_server; + script_info *Sim_script; + + + +/* Line 1676 of yacc.c */ +#line 399 "ntp_parser.h" +} YYSTYPE; +# define YYSTYPE_IS_TRIVIAL 1 +# define yystype YYSTYPE /* obsolescent; will be withdrawn */ +# define YYSTYPE_IS_DECLARED 1 +#endif + +extern YYSTYPE yylval; + + diff -urN src/contrib/ntp/ntpd/ntp_peer.c src.ntp/contrib/ntp/ntpd/ntp_peer.c --- src/contrib/ntp/ntpd/ntp_peer.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/ntp_peer.c 2009-12-09 08:36:36.000000000 +0100 @@ -9,7 +9,9 @@ #include #include "ntpd.h" +#include "ntp_lists.h" #include "ntp_stdlib.h" +#include "ntp_control.h" #include #ifdef OPENSSL #include "openssl/rand.h" @@ -29,7 +31,7 @@ * NO_PEER | e 1 0 1 1 1 * ACTIVE | e 1 1 0 0 0 * PASSIVE | e 1 e 0 0 0 - * CLIENT | e 0 0 0 1 1 + * CLIENT | e 0 0 0 1 0 * SERVER | e 0 0 0 0 0 * BCAST | e 0 0 0 0 0 * BCLIENT | e 0 0 0 e 1 @@ -53,7 +55,7 @@ /*P*/ { AM_ERR, AM_PROCPKT, AM_ERR, AM_NOMATCH, AM_NOMATCH, AM_NOMATCH}, -/*C*/ { AM_ERR, AM_NOMATCH, AM_NOMATCH, AM_NOMATCH, AM_PROCPKT, AM_POSSBCL}, +/*C*/ { AM_ERR, AM_NOMATCH, AM_NOMATCH, AM_NOMATCH, AM_PROCPKT, AM_NOMATCH}, /*S*/ { AM_ERR, AM_NOMATCH, AM_NOMATCH, AM_NOMATCH, AM_NOMATCH, AM_NOMATCH}, @@ -62,12 +64,12 @@ /*BCL*/ { AM_ERR, AM_NOMATCH, AM_NOMATCH, AM_NOMATCH, AM_NOMATCH, AM_PROCPKT}, }; -#define MATCH_ASSOC(x,y) AM[(x)][(y)] +#define MATCH_ASSOC(x, y) AM[(x)][(y)] /* * These routines manage the allocation of memory to peer structures - * and the maintenance of the peer hash table. The two main entry - * points are findpeer(), which looks for matching peer sturctures in + * and the maintenance of the peer hash table. The three main entry + * points are findpeer(), which looks for matching peer structures in * the peer list, newpeer(), which allocates a new peer structure and * adds it to the list, and unpeer(), which demobilizes the association * and deallocates the structure. @@ -76,11 +78,11 @@ * Peer hash tables */ struct peer *peer_hash[NTP_HASH_SIZE]; /* peer hash table */ -int peer_hash_count[NTP_HASH_SIZE]; /* peers in each bucket */ +int peer_hash_count[NTP_HASH_SIZE]; /* peers in each bucket */ struct peer *assoc_hash[NTP_HASH_SIZE]; /* association ID hash table */ -int assoc_hash_count[NTP_HASH_SIZE]; /* peers in each bucket */ +int assoc_hash_count[NTP_HASH_SIZE]; /* peers in each bucket */ static struct peer *peer_free; /* peer structures free list */ -int peer_free_count; /* count of free structures */ +int peer_free_count; /* count of free structures */ /* * Association ID. We initialize this value randomly, then assign a new @@ -97,18 +99,20 @@ /* * Miscellaneous statistic counters which may be queried. */ -u_long peer_timereset; /* time stat counters zeroed */ -u_long findpeer_calls; /* calls to findpeer */ -u_long assocpeer_calls; /* calls to findpeerbyassoc */ -u_long peer_allocations; /* allocations from free list */ -u_long peer_demobilizations; /* structs freed to free list */ -int total_peer_structs; /* peer structs */ -int peer_associations; /* mobilized associations */ -int peer_preempt; /* preemptable associations */ +u_long peer_timereset; /* time stat counters zeroed */ +u_long findpeer_calls; /* calls to findpeer */ +u_long assocpeer_calls; /* calls to findpeerbyassoc */ +u_long peer_allocations; /* allocations from free list */ +u_long peer_demobilizations; /* structs freed to free list */ +int total_peer_structs; /* peer structs */ +int peer_associations; /* mobilized associations */ +int peer_preempt; /* preemptable associations */ static struct peer init_peer_alloc[INIT_PEER_ALLOC]; /* init alloc */ -static void getmorepeermem P((void)); -static struct interface *select_peerinterface P((struct peer *, struct sockaddr_storage *, struct interface *, u_char)); +static void getmorepeermem (void); +static struct interface *select_peerinterface (struct peer *, sockaddr_u *, struct interface *, u_char); + +static int score(struct peer *); /* * init_peer - initialize peer data structures and counters @@ -122,14 +126,12 @@ register int i; /* - * Clear hash table and counters. + * Clear hash tables and counters. */ - for (i = 0; i < NTP_HASH_SIZE; i++) { - peer_hash[i] = 0; - peer_hash_count[i] = 0; - assoc_hash[i] = 0; - assoc_hash_count[i] = 0; - } + memset(peer_hash, 0, sizeof(peer_hash)); + memset(peer_hash_count, 0, sizeof(peer_hash_count)); + memset(assoc_hash, 0, sizeof(assoc_hash)); + memset(assoc_hash_count, 0, sizeof(assoc_hash_count)); /* * Clear stat counters @@ -140,11 +142,9 @@ /* * Initialize peer memory. */ - peer_free = 0; - for (i = 0; i < INIT_PEER_ALLOC; i++) { - init_peer_alloc[i].next = peer_free; - peer_free = &init_peer_alloc[i]; - } + peer_free = NULL; + for (i = 0; i < INIT_PEER_ALLOC; i++) + LINK_SLIST(peer_free, &init_peer_alloc[i], next); total_peer_structs = INIT_PEER_ALLOC; peer_free_count = INIT_PEER_ALLOC; @@ -167,8 +167,7 @@ peer = (struct peer *)emalloc(INC_PEER_ALLOC * sizeof(struct peer)); for (i = 0; i < INC_PEER_ALLOC; i++) { - peer->next = peer_free; - peer_free = peer; + LINK_SLIST(peer_free, peer, next); peer++; } @@ -182,7 +181,7 @@ */ struct peer * findexistingpeer( - struct sockaddr_storage *addr, + sockaddr_u *addr, struct peer *start_peer, int mode ) @@ -193,19 +192,16 @@ * start_peer is included so we can locate instances of the * same peer through different interfaces in the hash table. */ - if (start_peer == 0) + if (NULL == start_peer) peer = peer_hash[NTP_HASH_ADDR(addr)]; else peer = start_peer->next; - while (peer != 0) { - if (SOCKCMP(addr, &peer->srcadr) - && NSRCPORT(addr) == NSRCPORT(&peer->srcadr)) { - if (mode == -1) - return (peer); - else if (peer->hmode == mode) - break; - } + while (peer != NULL) { + if (SOCK_EQ(addr, &peer->srcadr) + && NSRCPORT(addr) == NSRCPORT(&peer->srcadr) + && (-1 == mode || peer->hmode == mode)) + break; peer = peer->next; } return (peer); @@ -217,19 +213,19 @@ */ struct peer * findpeer( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *dstadr, int pkt_mode, int *action ) { register struct peer *peer; - int hash; + u_int hash; findpeer_calls++; hash = NTP_HASH_ADDR(srcadr); for (peer = peer_hash[hash]; peer != NULL; peer = peer->next) { - if (SOCKCMP(srcadr, &peer->srcadr) && + if (SOCK_EQ(srcadr, &peer->srcadr) && NSRCPORT(srcadr) == NSRCPORT(&peer->srcadr)) { /* @@ -261,9 +257,7 @@ *action = MATCH_ASSOC(NO_PEER, pkt_mode); return ((struct peer *)0); } - set_peerdstadr(peer, dstadr); - return (peer); } @@ -276,7 +270,7 @@ ) { register struct peer *peer; - int hash; + u_int hash; assocpeer_calls++; @@ -306,9 +300,8 @@ for (n = 0; n < NTP_HASH_SIZE; n++) { for (peer = peer_hash[n]; peer != 0; peer = next_peer) { next_peer = peer->next; - if (!(peer->cast_flags & (MDF_ACAST | MDF_MCAST | - MDF_BCAST))) { - peer->hpoll = peer->minpoll; + if (!(peer->cast_flags & (MDF_ACAST | + MDF_MCAST | MDF_BCAST))) { peer_clear(peer, "STEP"); } } @@ -321,37 +314,93 @@ /* - * unpeer - remove peer structure from hash table and free structure + * score_all() - determine if an association can be demobilized */ -void -unpeer( - struct peer *peer_to_remove +int +score_all( + struct peer *peer /* peer structure pointer */ ) { - int hash; -#ifdef OPENSSL - char statstr[NTP_MAXSTRLEN]; /* statistics for filegen */ + struct peer *speer, *next_peer; + int n; + int temp, tamp; - if (peer_to_remove->flags & FLAG_SKEY) { - sprintf(statstr, "unpeer %d flash %x reach %03o flags %04x", - peer_to_remove->associd, peer_to_remove->flash, - peer_to_remove->reach, peer_to_remove->flags); - record_crypto_stats(&peer_to_remove->srcadr, statstr); -#ifdef DEBUG - if (debug) - printf("peer: %s\n", statstr); -#endif + /* + * This routine finds the minimum score for all ephemeral + * assocations and returns > 0 if the association can be + * demobilized. + */ + tamp = score(peer); + temp = 100; + for (n = 0; n < NTP_HASH_SIZE; n++) { + for (speer = peer_hash[n]; speer != 0; speer = + next_peer) { + int x; + + next_peer = speer->next; + if ((x = score(speer)) < temp && (peer->flags & + FLAG_PREEMPT)) + temp = x; + } } -#endif /* OPENSSL */ #ifdef DEBUG if (debug) - printf("demobilize %u %d %d\n", peer_to_remove->associd, - peer_associations, peer_preempt); + printf("score_all: at %lu score %d min %d\n", + current_time, tamp, temp); #endif - set_peerdstadr(peer_to_remove, NULL); + if (tamp != temp) + temp = 0; + return (temp); +} - /* XXXMEMLEAK? peer_clear->crypto allocation */ +/* + * score() - calculate preemption score + */ +static int +score( + struct peer *peer /* peer structure pointer */ + ) +{ + int temp; + + /* + * This routine calculates the premption score from the peer + * error bits and status. Increasing values are more cherished. + */ + temp = 0; + if (!(peer->flash & TEST10)) + temp++; /* 1 good synch and stratum */ + if (!(peer->flash & TEST13)) + temp++; /* 2 reachable */ + if (!(peer->flash & TEST12)) + temp++; /* 3 no loop */ + if (!(peer->flash & TEST11)) + temp++; /* 4 good distance */ + if (peer->status >= CTL_PST_SEL_SELCAND) + temp++; /* 5 in the hunt */ + if (peer->status != CTL_PST_SEL_EXCESS) + temp++; /* 6 not spare tire */ + return (temp); /* selection status */ +} + + +/* + * unpeer - remove peer structure from hash table and free structure + */ +void +unpeer( + struct peer *peer_to_remove + ) +{ + register struct peer *unlinked; + int hash; + char tbuf[80]; + + snprintf(tbuf, sizeof(tbuf), "assoc %d", + peer_to_remove->associd); + report_event(PEVNT_DEMOBIL, peer_to_remove, tbuf); + set_peerdstadr(peer_to_remove, NULL); hash = NTP_HASH_ADDR(&peer_to_remove->srcadr); peer_hash_count[hash]--; peer_demobilizations++; @@ -366,22 +415,14 @@ refclock_unpeer(peer_to_remove); #endif peer_to_remove->action = 0; /* disable timeout actions */ - if (peer_hash[hash] == peer_to_remove) - peer_hash[hash] = peer_to_remove->next; - else { - register struct peer *peer; - - peer = peer_hash[hash]; - while (peer != 0 && peer->next != peer_to_remove) - peer = peer->next; - - if (peer == 0) { - peer_hash_count[hash]++; - msyslog(LOG_ERR, "peer struct for %s not in table!", - stoa(&peer->srcadr)); - } else { - peer->next = peer_to_remove->next; - } + + UNLINK_SLIST(unlinked, peer_hash[hash], peer_to_remove, next, + struct peer); + + if (NULL == unlinked) { + peer_hash_count[hash]++; + msyslog(LOG_ERR, "peer struct for %s not in table!", + stoa(&peer_to_remove->srcadr)); } /* @@ -389,26 +430,18 @@ */ hash = peer_to_remove->associd & NTP_HASH_MASK; assoc_hash_count[hash]--; - if (assoc_hash[hash] == peer_to_remove) - assoc_hash[hash] = peer_to_remove->ass_next; - else { - register struct peer *peer; - - peer = assoc_hash[hash]; - while (peer != 0 && peer->ass_next != peer_to_remove) - peer = peer->ass_next; - - if (peer == 0) { - assoc_hash_count[hash]++; - msyslog(LOG_ERR, - "peer struct for %s not in association table!", - stoa(&peer->srcadr)); - } else { - peer->ass_next = peer_to_remove->ass_next; - } + + UNLINK_SLIST(unlinked, assoc_hash[hash], peer_to_remove, + ass_next, struct peer); + + if (NULL == unlinked) { + assoc_hash_count[hash]++; + msyslog(LOG_ERR, + "peer struct for %s not in association table!", + stoa(&peer_to_remove->srcadr)); } - peer_to_remove->next = peer_free; - peer_free = peer_to_remove; + + LINK_SLIST(peer_free, peer_to_remove, next); peer_free_count++; } @@ -418,7 +451,7 @@ */ struct peer * peer_config( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *dstadr, int hmode, int version, @@ -430,138 +463,81 @@ u_char *keystr ) { - register struct peer *peer; u_char cast_flags; /* - * First search from the beginning for an association with given - * remote address and mode. If an interface is given, search - * from there to find the association which matches that - * destination. If the given interface is "any", track down - * the actual interface, because that's what gets put into the - * peer structure. - */ - peer = findexistingpeer(srcadr, (struct peer *)0, hmode); - if (dstadr != 0) { - while (peer != 0) { - if (peer->dstadr == dstadr) - break; - if (dstadr == ANY_INTERFACE_CHOOSE(srcadr) && - peer->dstadr == findinterface(srcadr)) - break; - peer = findexistingpeer(srcadr, peer, hmode); - } - } - - /* * We do a dirty little jig to figure the cast flags. This is * probably not the best place to do this, at least until the * configure code is rebuilt. Note only one flag can be set. */ switch (hmode) { - case MODE_BROADCAST: - if(srcadr->ss_family == AF_INET) { - if (IN_CLASSD(ntohl(((struct sockaddr_in*)srcadr)->sin_addr.s_addr))) - cast_flags = MDF_MCAST; - else - cast_flags = MDF_BCAST; - break; - } - else { - if (IN6_IS_ADDR_MULTICAST(&((struct sockaddr_in6*)srcadr)->sin6_addr)) - cast_flags = MDF_MCAST; - else - cast_flags = MDF_BCAST; - break; - } + if (IS_MCAST(srcadr)) + cast_flags = MDF_MCAST; + else + cast_flags = MDF_BCAST; + break; case MODE_CLIENT: - if(srcadr->ss_family == AF_INET) { - if (IN_CLASSD(ntohl(((struct sockaddr_in*)srcadr)->sin_addr.s_addr))) - cast_flags = MDF_ACAST; - else - cast_flags = MDF_UCAST; - break; - } - else { - if (IN6_IS_ADDR_MULTICAST(&((struct sockaddr_in6*)srcadr)->sin6_addr)) - cast_flags = MDF_ACAST; - else - cast_flags = MDF_UCAST; - break; - } + if (IS_MCAST(srcadr)) + cast_flags = MDF_ACAST; + else + cast_flags = MDF_UCAST; + break; default: cast_flags = MDF_UCAST; } /* - * If the peer is already configured, some dope has a duplicate - * configureation entry or another dope is wiggling from afar. - */ - if (peer != 0) { - peer->hmode = (u_char)hmode; - peer->version = (u_char) version; - peer->minpoll = (u_char) minpoll; - peer->maxpoll = (u_char) maxpoll; - peer->flags = flags | FLAG_CONFIG | - (peer->flags & FLAG_REFCLOCK); - peer->cast_flags = cast_flags; - peer->ttl = (u_char) ttl; - peer->keyid = key; - peer->precision = sys_precision; - peer_clear(peer, "RMOT"); - return (peer); - } - - /* - * Here no match has been found, so presumably this is a new - * persistent association. Mobilize the thing and initialize its - * variables. If emulating ntpdate, force iburst. + * Mobilize the association and initialize its variables. If + * emulating ntpdate, force iburst. */ if (mode_ntpdate) flags |= FLAG_IBURST; - peer = newpeer(srcadr, dstadr, hmode, version, minpoll, maxpoll, - flags | FLAG_CONFIG, cast_flags, ttl, key); - return (peer); + return(newpeer(srcadr, dstadr, hmode, version, minpoll, maxpoll, + flags | FLAG_CONFIG, cast_flags, ttl, key)); } /* - * setup peer dstadr field keeping it in sync with the interface structures + * setup peer dstadr field keeping it in sync with the interface + * structures */ void -set_peerdstadr(struct peer *peer, struct interface *interface) +set_peerdstadr( + struct peer *peer, + struct interface *interface + ) { + struct peer *unlinked; + if (peer->dstadr != interface) { - if (interface != NULL && - (peer->cast_flags & MDF_BCLNT) && - (interface->flags & INT_MCASTIF) && + if (interface != NULL && (peer->cast_flags & + MDF_BCLNT) && (interface->flags & INT_MCASTIF) && peer->burst) { + /* - * don't accept updates to a true multicast reception - * interface while a BCLNT peer is running it's - * unicast protocol + * don't accept updates to a true multicast + * reception interface while a BCLNT peer is + * running it's unicast protocol */ return; } - - if (peer->dstadr != NULL) - { + if (peer->dstadr != NULL) { peer->dstadr->peercnt--; - ISC_LIST_UNLINK_TYPE(peer->dstadr->peers, peer, ilink, struct peer); + UNLINK_SLIST(unlinked, peer->dstadr->peers, + peer, ilink, struct peer); + msyslog(LOG_INFO, + "%s interface %s -> %s", + stoa(&peer->srcadr), + stoa(&peer->dstadr->sin), + (interface != NULL) + ? stoa(&interface->sin) + : "(null)"); } - - DPRINTF(4, ("set_peerdstadr(%s): change interface from %s to %s\n", - stoa(&peer->srcadr), - (peer->dstadr != NULL) ? stoa(&peer->dstadr->sin) : "", - (interface != NULL) ? stoa(&interface->sin) : "")); - peer->dstadr = interface; - - if (peer->dstadr != NULL) - { - ISC_LIST_APPEND(peer->dstadr->peers, peer, ilink); + if (peer->dstadr != NULL) { + LINK_SLIST(peer->dstadr->peers, peer, ilink); peer->dstadr->peercnt++; } } @@ -571,57 +547,50 @@ * attempt to re-rebind interface if necessary */ static void -peer_refresh_interface(struct peer *peer) +peer_refresh_interface( + struct peer *peer + ) { struct interface *niface, *piface; - niface = select_peerinterface(peer, &peer->srcadr, NULL, peer->cast_flags); + niface = select_peerinterface(peer, &peer->srcadr, NULL, + peer->cast_flags); #ifdef DEBUG if (debug > 3) { printf( - "peer_refresh_interface: %s->%s mode %d vers %d poll %d %d flags 0x%x 0x%x ttl %d key %08x: new interface: ", - peer->dstadr == NULL ? "" : stoa(&peer->dstadr->sin), - stoa(&peer->srcadr), - peer->hmode, peer->version, peer->minpoll, - peer->maxpoll, peer->flags, peer->cast_flags, - peer->ttl, peer->keyid); - if (niface != NULL) - { - printf("fd=%d, bfd=%d, name=%.16s, flags=0x%x, scope=%d, ", - niface->fd, - niface->bfd, - niface->name, - niface->flags, - niface->scopeid); - /* Leave these as three printf calls. */ - printf(", sin=%s", - stoa((&niface->sin))); + "peer_refresh_interface: %s->%s mode %d vers %d poll %d %d flags 0x%x 0x%x ttl %d key %08x: new interface: ", + peer->dstadr == NULL ? "" : + stoa(&peer->dstadr->sin), stoa(&peer->srcadr), + peer->hmode, peer->version, peer->minpoll, + peer->maxpoll, peer->flags, peer->cast_flags, + peer->ttl, peer->keyid); + if (niface != NULL) { + printf( + "fd=%d, bfd=%d, name=%.16s, flags=0x%x, scope=%d, ", + niface->fd, niface->bfd, niface->name, + niface->flags, niface->scopeid); + printf(", sin=%s", stoa((&niface->sin))); if (niface->flags & INT_BROADCAST) printf(", bcast=%s,", - stoa((&niface->bcast))); - printf(", mask=%s\n", - stoa((&niface->mask))); - } - else - { + stoa((&niface->bcast))); + printf(", mask=%s\n", stoa((&niface->mask))); + } else { printf("\n"); } } #endif piface = peer->dstadr; - set_peerdstadr(peer, niface); - if (peer->dstadr) { - /* - * clear crypto if we change the local address - */ - if (peer->dstadr != piface && !(peer->cast_flags & MDF_BCLNT)) { - peer_crypto_clear(peer); - } + /* + * clear crypto if we change the local address + */ + if (peer->dstadr != piface && !(peer->cast_flags & + MDF_ACAST) && peer->pmode != MODE_BROADCAST) + peer_clear(peer, "XFAC"); /* * Broadcast needs the socket enabled for broadcast @@ -631,16 +600,19 @@ } /* - * Multicast needs the socket interface enabled for multicast + * Multicast needs the socket interface enabled for + * multicast */ if (peer->cast_flags & MDF_MCAST) { - enable_multicast_if(peer->dstadr, &peer->srcadr); + enable_multicast_if(peer->dstadr, + &peer->srcadr); } } } /* - * refresh_all_peerinterfaces - see that all interface bindings are up to date + * refresh_all_peerinterfaces - see that all interface bindings are up + * to date */ void refresh_all_peerinterfaces(void) @@ -665,7 +637,12 @@ * find an interface suitable for the src address */ static struct interface * -select_peerinterface(struct peer *peer, struct sockaddr_storage *srcadr, struct interface *dstadr, u_char cast_flags) +select_peerinterface( + struct peer * peer, + sockaddr_u * srcadr, + struct interface * dstadr, + u_char cast_flags + ) { struct interface *interface; @@ -686,20 +663,22 @@ if (debug > 3) { if (interface != NULL) printf("Found *-cast interface address %s, for address %s\n", - stoa(&(interface)->sin), stoa(srcadr)); + stoa(&(interface)->sin), stoa(srcadr)); else printf("No *-cast local address found for address %s\n", stoa(srcadr)); } #endif /* - * If it was a multicast packet, findbcastinter() may not - * find it, so try a little harder. + * If it was a multicast packet, + * findbcastinter() may not find it, so try a + * little harder. */ if (interface == ANY_INTERFACE_CHOOSE(srcadr)) interface = findinterface(srcadr); } - else if (dstadr != NULL && dstadr != ANY_INTERFACE_CHOOSE(srcadr)) + else if (dstadr != NULL && dstadr != + ANY_INTERFACE_CHOOSE(srcadr)) interface = dstadr; else interface = findinterface(srcadr); @@ -724,37 +703,79 @@ */ struct peer * newpeer( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *dstadr, - int hmode, - int version, - int minpoll, - int maxpoll, - u_int flags, - u_char cast_flags, - int ttl, - keyid_t key + int hmode, + int version, + int minpoll, + int maxpoll, + u_int flags, + u_char cast_flags, + int ttl, + keyid_t key ) { - register struct peer *peer; - register int i; + struct peer *peer; + u_int hash; + char tbuf[80]; + #ifdef OPENSSL - char statstr[NTP_MAXSTRLEN]; /* statistics for filegen */ + /* + * If Autokey is requested but not configured, complain loudly. + */ + if (!crypto_flags) { + if (key > NTP_MAXKEY) { + return (NULL); + + } else if (flags & FLAG_SKEY) { + msyslog(LOG_ERR, "Autokey not configured"); + return (NULL); + } + } #endif /* OPENSSL */ /* + * First search from the beginning for an association with given + * remote address and mode. If an interface is given, search + * from there to find the association which matches that + * destination. If the given interface is "any", track down the + * actual interface, because that's what gets put into the peer + * structure. + */ + peer = findexistingpeer(srcadr, NULL, hmode); + if (dstadr != NULL) { + while (peer != NULL) { + if (peer->dstadr == dstadr) + break; + + if (dstadr == ANY_INTERFACE_CHOOSE(srcadr) && + peer->dstadr == findinterface(srcadr)) + break; + + peer = findexistingpeer(srcadr, peer, hmode); + } + } + + /* + * If a peer is found, this would be a duplicate and we don't + * allow that. This is mostly to avoid duplicate pool + * associations. + */ + if (peer != NULL) + return (NULL); + + /* * Allocate a new peer structure. Some dirt here, since some of * the initialization requires knowlege of our system state. */ if (peer_free_count == 0) getmorepeermem(); - peer = peer_free; - peer_free = peer->next; + UNLINK_HEAD_SLIST(peer, peer_free, next); peer_free_count--; peer_associations++; if (flags & FLAG_PREEMPT) peer_preempt++; - memset((char *)peer, 0, sizeof(struct peer)); + memset(peer, 0, sizeof(*peer)); /* * Assign an association ID and increment the system variable. @@ -766,42 +787,53 @@ DPRINTF(3, ("newpeer: cast flags: 0x%x for address: %s\n", cast_flags, stoa(srcadr))); - ISC_LINK_INIT(peer, ilink); /* set up interface link chain */ peer->srcadr = *srcadr; set_peerdstadr(peer, select_peerinterface(peer, srcadr, dstadr, cast_flags)); peer->hmode = (u_char)hmode; peer->version = (u_char)version; - peer->minpoll = (u_char)max(NTP_MINPOLL, minpoll); - peer->maxpoll = (u_char)min(NTP_MAXPOLL, maxpoll); peer->flags = flags; -#ifdef DEBUG - if (debug > 2) { - if (peer->dstadr) - printf("newpeer: using fd %d and our addr %s\n", - peer->dstadr->fd, - stoa(&peer->dstadr->sin)); - else - printf("newpeer: local interface currently not bound\n"); - } -#endif + + /* + * It is an error to set minpoll less than NTP_MINPOLL or to + * set maxpoll greater than NTP_MAXPOLL. However, minpoll is + * clamped not greater than NTP_MAXPOLL and maxpoll is clamped + * not less than NTP_MINPOLL without complaint. Finally, + * minpoll is clamped not greater than maxpoll. + */ + if (minpoll == 0) + peer->minpoll = NTP_MINDPOLL; + else + peer->minpoll = (u_char)min(minpoll, NTP_MAXPOLL); + if (maxpoll == 0) + peer->maxpoll = NTP_MAXDPOLL; + else + peer->maxpoll = (u_char)max(maxpoll, NTP_MINPOLL); + if (peer->minpoll > peer->maxpoll) + peer->minpoll = peer->maxpoll; + + if (peer->dstadr) + DPRINTF(3, ("newpeer: using fd %d and our addr %s\n", + peer->dstadr->fd, stoa(&peer->dstadr->sin))); + else + DPRINTF(3, ("newpeer: local interface currently not bound\n")); /* * Broadcast needs the socket enabled for broadcast */ - if (cast_flags & MDF_BCAST && peer->dstadr) { + if ((cast_flags & MDF_BCAST) && peer->dstadr) enable_broadcast(peer->dstadr, srcadr); - } + /* * Multicast needs the socket interface enabled for multicast */ - if (cast_flags & MDF_MCAST && peer->dstadr) { + if ((cast_flags & MDF_MCAST) && peer->dstadr) enable_multicast_if(peer->dstadr, srcadr); - } - if (key != 0) - peer->flags |= FLAG_AUTHENABLE; + +#ifdef OPENSSL if (key > NTP_MAXKEY) peer->flags |= FLAG_SKEY; +#endif /* OPENSSL */ peer->cast_flags = cast_flags; peer->ttl = (u_char)ttl; peer->keyid = key; @@ -834,14 +866,14 @@ * the peer timer, since the clock may have requirements * for this. */ + if (maxpoll == 0) + peer->maxpoll = peer->minpoll; if (!refclock_newpeer(peer)) { /* * Dump it, something screwed up */ set_peerdstadr(peer, NULL); - - peer->next = peer_free; - peer_free = peer; + LINK_SLIST(peer_free, peer, next); peer_free_count++; return (NULL); } @@ -851,79 +883,25 @@ /* * Put the new peer in the hash tables. */ - i = NTP_HASH_ADDR(&peer->srcadr); - peer->next = peer_hash[i]; - peer_hash[i] = peer; - peer_hash_count[i]++; - i = peer->associd & NTP_HASH_MASK; - peer->ass_next = assoc_hash[i]; - assoc_hash[i] = peer; - assoc_hash_count[i]++; - -#ifdef OPENSSL - if (peer->flags & FLAG_SKEY) { - sprintf(statstr, "newpeer %d", peer->associd); - record_crypto_stats(&peer->srcadr, statstr); - DPRINTF(1, ("peer: %s\n", statstr)); - } -#endif /* OPENSSL */ - + hash = NTP_HASH_ADDR(&peer->srcadr); + LINK_SLIST(peer_hash[hash], peer, next); + peer_hash_count[hash]++; + hash = peer->associd & NTP_HASH_MASK; + LINK_SLIST(assoc_hash[hash], peer, ass_next); + assoc_hash_count[hash]++; + snprintf(tbuf, sizeof(tbuf), "assoc %d", peer->associd); + report_event(PEVNT_MOBIL, peer, tbuf); DPRINTF(1, ("newpeer: %s->%s mode %d vers %d poll %d %d flags 0x%x 0x%x ttl %d key %08x\n", - peer->dstadr == NULL ? "" : stoa(&peer->dstadr->sin), - stoa(&peer->srcadr), - peer->hmode, peer->version, peer->minpoll, - peer->maxpoll, peer->flags, peer->cast_flags, - peer->ttl, peer->keyid)); - + peer->dstadr == NULL ? "" : stoa(&peer->dstadr->sin), + stoa(&peer->srcadr), peer->hmode, peer->version, + peer->minpoll, peer->maxpoll, peer->flags, peer->cast_flags, + peer->ttl, peer->keyid)); return (peer); } /* - * peer_unconfig - remove the configuration bit from a peer - */ -int -peer_unconfig( - struct sockaddr_storage *srcadr, - struct interface *dstadr, - int mode - ) -{ - register struct peer *peer; - int num_found; - - num_found = 0; - peer = findexistingpeer(srcadr, (struct peer *)0, mode); - while (peer != 0) { - if (peer->flags & FLAG_CONFIG - && (dstadr == 0 || peer->dstadr == dstadr)) { - num_found++; - - /* - * Tricky stuff here. If the peer is polling us - * in active mode, turn off the configuration - * bit and make the mode passive. This allows us - * to avoid dumping a lot of history for peers - * we might choose to keep track of in passive - * mode. The protocol will eventually terminate - * undesirables on its own. - */ - if (peer->hmode == MODE_ACTIVE - && peer->pmode == MODE_ACTIVE) { - peer->hmode = MODE_PASSIVE; - peer->flags &= ~FLAG_CONFIG; - } else { - unpeer(peer); - peer = 0; - } - } - peer = findexistingpeer(srcadr, peer, mode); - } - return (num_found); -} - -/* - * peer_clr_stats - clear peer module stat counters + * peer_clr_stats - clear peer module statiistics counters */ void peer_clr_stats(void) @@ -936,15 +914,17 @@ } /* - * peer_reset - reset stat counters in a peer structure + * peer_reset - reset statistics counters */ void peer_reset( struct peer *peer ) { - if (peer == 0) + if (peer == NULL) return; + + peer->timereset = current_time; peer->sent = 0; peer->received = 0; peer->processed = 0; @@ -952,12 +932,12 @@ peer->bogusorg = 0; peer->oldpkt = 0; peer->seldisptoolarge = 0; - peer->timereset = current_time; + peer->selbroken = 0; } /* - * peer_all_reset - reset all peer stat counters + * peer_all_reset - reset all peer statistics counters */ void peer_all_reset(void) @@ -971,54 +951,12 @@ } -#ifdef OPENSSL -/* - * expire_all - flush all crypto data and update timestamps. - */ -void -expire_all(void) -{ - struct peer *peer, *next_peer; - int n; - - /* - * This routine is called about once per day from the timer - * routine and when the client is first synchronized. Search the - * peer list for all associations and flush only the key list - * and cookie. If a manycast client association, flush - * everything. Then, recompute and sign the agreement public - * value, if present. - */ - if (!crypto_flags) - return; - - for (n = 0; n < NTP_HASH_SIZE; n++) { - for (peer = peer_hash[n]; peer != 0; peer = next_peer) { - next_peer = peer->next; - if (!(peer->flags & FLAG_SKEY)) { - continue; - - } else if (peer->hmode == MODE_ACTIVE || - peer->hmode == MODE_PASSIVE) { - key_expire(peer); - peer->crypto &= ~(CRYPTO_FLAG_AUTO | - CRYPTO_FLAG_AGREE); - } - - } - } - RAND_bytes((u_char *)&sys_private, 4); - crypto_update(); -} -#endif /* OPENSSL */ - - /* * findmanycastpeer - find and return a manycast peer */ struct peer * findmanycastpeer( - struct recvbuf *rbufp + struct recvbuf *rbufp /* receive buffer pointer */ ) { register struct peer *peer; @@ -1042,7 +980,7 @@ peer->next) { if (peer->cast_flags & MDF_ACAST) { NTOHL_FP(&pkt->org, &p_org); - if (L_ISEQU(&peer->xmt, &p_org)) + if (L_ISEQU(&p_org, &peer->aorg)) return (peer); } } diff -urN src/contrib/ntp/ntpd/ntp_proto.c src.ntp/contrib/ntp/ntpd/ntp_proto.c --- src/contrib/ntp/ntpd/ntp_proto.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/ntp_proto.c 2010-03-31 10:34:38.000000000 +0200 @@ -15,15 +15,16 @@ #include "ntp_string.h" #include +#ifdef HAVE_LIBSCF_H +#include +#include +#endif /* HAVE_LIBSCF_H */ + #if defined(VMS) && defined(VMS_LOCALUNIT) /*wjm*/ #include "ntp_refclock.h" #endif -#if defined(__FreeBSD__) && __FreeBSD__ >= 3 -#include -#endif - /* * This macro defines the authentication state. If x is 1 authentication * is required; othewise it is optional. @@ -31,49 +32,62 @@ #define AUTH(x, y) ((x) ? (y) == AUTH_OK : (y) == AUTH_OK || \ (y) == AUTH_NONE) +#define AUTH_NONE 0 /* authentication not required */ +#define AUTH_OK 1 /* authentication OK */ +#define AUTH_ERROR 2 /* authentication error */ +#define AUTH_CRYPTO 3 /* crypto_NAK */ + /* - * System variables are declared here. See Section 3.2 of the - * specification. + * traffic shaping parameters + */ +#define NTP_IBURST 6 /* packets in iburst */ +#define RESP_DELAY 1 /* refclock burst delay (s) */ + +/* + * System variables are declared here. Unless specified otherwise, all + * times are in seconds. */ u_char sys_leap; /* system leap indicator */ -u_char sys_stratum; /* stratum of system */ +u_char sys_stratum; /* system stratum */ s_char sys_precision; /* local clock precision (log2 s) */ double sys_rootdelay; /* roundtrip delay to primary source */ -double sys_rootdispersion; /* dispersion to primary source */ -u_int32 sys_refid; /* source/loop in network byte order */ -static double sys_offset; /* current local clock offset */ -l_fp sys_reftime; /* time we were last updated */ -struct peer *sys_peer; /* our current peer */ -struct peer *sys_pps; /* our PPS peer */ -struct peer *sys_prefer; /* our cherished peer */ -int sys_kod; /* kod credit */ -int sys_kod_rate = 2; /* max kod packets per second */ -#ifdef OPENSSL -u_long sys_automax; /* maximum session key lifetime */ -#endif /* OPENSSL */ - +double sys_rootdisp; /* dispersion to primary source */ +u_int32 sys_refid; /* reference id (network byte order) */ +l_fp sys_reftime; /* last update time */ +struct peer *sys_peer; /* current peer */ + +/* + * Rate controls. Leaky buckets are used to throttle the packet + * transmission rates in order to protect busy servers such as at NIST + * and USNO. There is a counter for each association and another for KoD + * packets. The association counter decrements each second, but not + * below zero. Each time a packet is sent the counter is incremented by + * a configurable value representing the average interval between + * packets. A packet is delayed as long as the counter is greater than + * zero. Note this does not affect the time value computations. + */ /* - * Nonspecified system state variables. + * Nonspecified system state variables */ int sys_bclient; /* broadcast client enable */ double sys_bdelay; /* broadcast client default delay */ -int sys_calldelay; /* modem callup delay (s) */ int sys_authenticate; /* requre authentication for config */ l_fp sys_authdelay; /* authentication delay */ -static u_long sys_authdly[2]; /* authentication delay shift reg */ -static double sys_mindisp = MINDISPERSE; /* min disp increment (s) */ -static double sys_maxdist = MAXDISTANCE; /* selection threshold (s) */ -double sys_jitter; /* system jitter (s) */ -static int sys_hopper; /* anticlockhop counter */ -static int sys_maxhop = MAXHOP; /* anticlockhop counter threshold */ -int leap_next; /* leap consensus */ +double sys_offset; /* current local clock offset */ +double sys_mindisp = MINDISPERSE; /* minimum distance (s) */ +double sys_maxdist = MAXDISTANCE; /* selection threshold */ +double sys_jitter; /* system jitter */ +u_long sys_epoch; /* last clock update time */ +static double sys_clockhop; /* clockhop threshold */ +int leap_tai; /* TAI at next next leap */ +u_long leap_sec; /* next scheduled leap from file */ +u_long leap_peers; /* next scheduled leap from peers */ +u_long leap_expire; /* leap information expiration */ +static int leap_vote; /* leap consensus */ keyid_t sys_private; /* private value for session seed */ int sys_manycastserver; /* respond to manycast client pkts */ int peer_ntpdate; /* active peers in ntpdate mode */ int sys_survivors; /* truest of the truechimers */ -#ifdef OPENSSL -char *sys_hostname; /* gethostname() name */ -#endif /* OPENSSL */ /* * TOS and multicast mapping stuff @@ -81,42 +95,41 @@ int sys_floor = 0; /* cluster stratum floor */ int sys_ceiling = STRATUM_UNSPEC; /* cluster stratum ceiling */ int sys_minsane = 1; /* minimum candidates */ -int sys_minclock = NTP_MINCLOCK; /* minimum survivors */ +int sys_minclock = NTP_MINCLOCK; /* minimum candidates */ int sys_maxclock = NTP_MAXCLOCK; /* maximum candidates */ int sys_cohort = 0; /* cohort switch */ int sys_orphan = STRATUM_UNSPEC + 1; /* orphan stratum */ -double sys_orphandelay = 0; /* orphan root delay */ int sys_beacon = BEACON; /* manycast beacon interval */ int sys_ttlmax; /* max ttl mapping vector index */ u_char sys_ttl[MAX_TTL]; /* ttl mapping vector */ /* - * Statistics counters + * Statistics counters - first the good, then the bad */ -u_long sys_stattime; /* time since reset */ +u_long sys_stattime; /* elapsed time */ u_long sys_received; /* packets received */ -u_long sys_processed; /* packets processed */ -u_long sys_newversionpkt; /* current version */ -u_long sys_oldversionpkt; /* recent version */ -u_long sys_unknownversion; /* invalid version */ +u_long sys_processed; /* packets for this host */ +u_long sys_newversion; /* current version */ +u_long sys_oldversion; /* old version */ u_long sys_restricted; /* access denied */ u_long sys_badlength; /* bad length or format */ u_long sys_badauth; /* bad authentication */ +u_long sys_declined; /* declined */ u_long sys_limitrejected; /* rate exceeded */ +u_long sys_kodsent; /* KoD sent */ -static double root_distance P((struct peer *)); -static void clock_combine P((struct peer **, int)); -static void peer_xmit P((struct peer *)); -static void fast_xmit P((struct recvbuf *, int, keyid_t, - int)); -static void clock_update P((void)); -static int default_get_precision P((void)); -static int peer_unfit P((struct peer *)); +static double root_distance (struct peer *); +static void clock_combine (struct peer **, int); +static void peer_xmit (struct peer *); +static void fast_xmit (struct recvbuf *, int, keyid_t, + int); +static void clock_update (struct peer *); +static int default_get_precision (void); +static int peer_unfit (struct peer *); /* - * transmit - Transmit Procedure. See Section 3.4.2 of the - * specification. + * transmit - transmit procedure called by poll timeout */ void transmit( @@ -131,24 +144,7 @@ * server modes) and those that do (all other modes). The dance * is intricate... */ - /* - * Orphan mode is active when enabled and when no servers less - * than the orphan statum are available. In this mode packets - * are sent at the orphan stratum. An orphan with no other - * synchronization source is an orphan parent. It assumes root - * delay zero and reference ID the loopback address. All others - * are orphan children with root delay randomized over a 1-s - * range. The root delay is used by the election algorithm to - * select the order of synchronization. - */ hpoll = peer->hpoll; - if (sys_orphan < STRATUM_UNSPEC && sys_peer == NULL) { - sys_leap = LEAP_NOWARNING; - sys_stratum = sys_orphan; - sys_refid = htonl(LOOPBACKADR); - sys_rootdelay = 0; - sys_rootdispersion = 0; - } /* * In broadcast mode the poll interval is never changed from @@ -156,7 +152,8 @@ */ if (peer->cast_flags & (MDF_BCAST | MDF_MCAST)) { peer->outdate = current_time; - peer_xmit(peer); + if (sys_leap != LEAP_NOTINSYNC) + peer_xmit(peer); poll_update(peer, hpoll); return; } @@ -177,7 +174,7 @@ peer->ttl = 0; peer_xmit(peer); } else if (sys_survivors < sys_minclock || - peer_preempt < sys_maxclock) { + peer_associations < sys_maxclock) { if (peer->ttl < sys_ttlmax) peer->ttl++; peer_xmit(peer); @@ -202,96 +199,63 @@ */ oreach = peer->reach; peer->outdate = current_time; - if (peer == sys_peer) - sys_hopper++; + peer->unreach++; peer->reach <<= 1; - if (!(peer->reach & 0x07)) + if (!(peer->reach & 0x0f)) clock_filter(peer, 0., 0., MAXDISPERSE); if (!peer->reach) { /* * Here the peer is unreachable. If it was - * previously reachable, raise a trap. - */ - if (oreach) { - report_event(EVNT_UNREACH, peer); - peer->timereachable = current_time; - } - - /* - * Send a burst if enabled, but only once after - * a peer becomes unreachable. If the prempt - * flag is dim, bump the unreach counter by one; - * otherwise, bump it by three. + * previously reachable raise a trap. Send a + * burst if enabled. */ - if (peer->flags & FLAG_IBURST && - peer->unreach == 0) { - peer->burst = NTP_BURST; - } - if (!(peer->flags & FLAG_PREEMPT)) - peer->unreach++; - else - peer->unreach += 3; + if (oreach) + report_event(PEVNT_UNREACH, peer, NULL); + if ((peer->flags & FLAG_IBURST) && + peer->retry == 0) + peer->retry = NTP_RETRY; } else { /* - * Here the peer is reachable. Set the poll - * interval to the system poll interval. Send a - * burst only if enabled and the peer is fit. - * - * Respond to the peer evaluation produced by - * the selection algorithm. If less than the - * outlyer level, up the unreach by three. If - * there are excess associations, up the unreach - * by two if not a candidate and by one if so. + * Here the peer is reachable. Send a burst if + * enabled and the peer is fit. */ - if (!(peer->flags & FLAG_PREEMPT)) { - peer->unreach = 0; - } else if (peer->status < CTL_PST_SEL_SELCAND) { - peer->unreach += 3; - } else if (peer_preempt > sys_maxclock) { - if (peer->status < CTL_PST_SEL_SYNCCAND) - peer->unreach += 2; - else - peer->unreach++; - } else { - peer->unreach = 0; - } hpoll = sys_poll; - if (peer->flags & FLAG_BURST && - !peer_unfit(peer)) - peer->burst = NTP_BURST; + if (!(peer->flags & FLAG_PREEMPT && + peer->hmode == MODE_CLIENT)) + peer->unreach = 0; + if ((peer->flags & FLAG_BURST) && peer->retry == + 0 && !peer_unfit(peer)) + peer->retry = NTP_RETRY; } /* - * Watch for timeout. If ephemeral or preemptable, toss - * the rascal; otherwise, bump the poll interval. + * Watch for timeout. If preemptable, toss the rascal; + * otherwise, bump the poll interval. Note the + * poll_update() routine will clamp it to maxpoll. */ if (peer->unreach >= NTP_UNREACH) { - if (peer->flags & FLAG_PREEMPT || - !(peer->flags & FLAG_CONFIG)) { - peer_clear(peer, "TIME"); - unpeer(peer); - return; - } else { - hpoll++; + hpoll++; + if (peer->flags & FLAG_PREEMPT) { + report_event(PEVNT_RESTART, peer, + "timeout"); + if (peer->hmode != MODE_CLIENT) { + peer_clear(peer, "TIME"); + unpeer(peer); + return; + } + if (peer_associations > sys_maxclock && + score_all(peer)) { + peer_clear(peer, "TIME"); + unpeer(peer); + return; + } } } } else { peer->burst--; - - /* - * If a broadcast client at this point, the burst has - * concluded, so we switch to client mode and purge the - * keylist, since no further transmissions will be made. - */ if (peer->burst == 0) { - if (peer->cast_flags & MDF_BCLNT) { - peer->hmode = MODE_BCLIENT; -#ifdef OPENSSL - key_expire(peer); -#endif /* OPENSSL */ - } /* * If ntpdate mode and the clock has not been @@ -302,12 +266,16 @@ peer_ntpdate--; if (peer_ntpdate == 0) { msyslog(LOG_NOTICE, - "no reply; clock not set"); + "ntpd: no servers found"); + printf( + "ntpd: no servers found\n"); exit (0); } } } } + if (peer->retry > 0) + peer->retry--; /* * Do not transmit if in broadcast client mode. @@ -319,7 +287,7 @@ /* - * receive - Receive Procedure. See section 3.4.3 in the specification. + * receive - receive procedure called for each packet received */ void receive( @@ -336,42 +304,39 @@ int has_mac; /* length of MAC field */ int authlen; /* offset of MAC field */ int is_authentic = 0; /* cryptosum ok */ - keyid_t skeyid = 0; /* key ID */ - struct sockaddr_storage *dstadr_sin; /* active runway */ + int retcode = AM_NOMATCH; /* match code */ + keyid_t skeyid = 0; /* key IDs */ + u_int32 opcode = 0; /* extension field opcode */ + sockaddr_u *dstadr_sin; /* active runway */ struct peer *peer2; /* aux peer structure pointer */ l_fp p_org; /* origin timestamp */ l_fp p_rec; /* receive timestamp */ l_fp p_xmt; /* transmit timestamp */ #ifdef OPENSSL - keyid_t tkeyid = 0; /* temporary key ID */ - keyid_t pkeyid = 0; /* previous key ID */ struct autokey *ap; /* autokey structure pointer */ int rval; /* cookie snatcher */ + keyid_t pkeyid = 0, tkeyid = 0; /* key IDs */ #endif /* OPENSSL */ - int retcode = AM_NOMATCH; - int at_listhead; +#ifdef HAVE_NTP_SIGND + static unsigned char zero_key[16]; +#endif /* HAVE_NTP_SIGND */ /* * Monitor the packet and get restrictions. Note that the packet * length for control and private mode packets must be checked - * by the service routines. Note that no statistics counters are - * recorded for restrict violations, since these counters are in - * the restriction routine. Note the careful distinctions here - * between a packet with a format error and a packet that is - * simply discarded without prejudice. Some restrictions have to - * be handled later in order to generate a kiss-of-death packet. + * by the service routines. Some restrictions have to be handled + * later in order to generate a kiss-o'-death packet. */ /* * Bogus port check is before anything, since it probably * reveals a clogging attack. */ sys_received++; - if (SRCPORT(&rbufp->recv_srcadr) == 0) { + if (SRCPORT(&rbufp->recv_srcadr) < NTP_PORT) { sys_badlength++; return; /* bogus port */ } - at_listhead = ntp_monitor(rbufp); - restrict_mask = restrictions(&rbufp->recv_srcadr, at_listhead); + restrict_mask = restrictions(&rbufp->recv_srcadr); #ifdef DEBUG if (debug > 1) printf("receive: at %ld %s<-%s flags %x restrict %03x\n", @@ -379,15 +344,15 @@ stoa(&rbufp->recv_srcadr), rbufp->dstadr->flags, restrict_mask); #endif - if (restrict_mask & RES_IGNORE) { - sys_restricted++; - return; /* ignore everything */ - } pkt = &rbufp->recv_pkt; hisversion = PKT_VERSION(pkt->li_vn_mode); hisleap = PKT_LEAP(pkt->li_vn_mode); hismode = (int)PKT_MODE(pkt->li_vn_mode); hisstratum = PKT_TO_STRATUM(pkt->stratum); + if (restrict_mask & RES_IGNORE) { + sys_restricted++; + return; /* ignore everything */ + } if (hismode == MODE_PRIVATE) { if (restrict_mask & RES_NOQUERY) { sys_restricted++; @@ -407,24 +372,31 @@ } if (restrict_mask & RES_DONTSERVE) { sys_restricted++; - return; /* no time */ + return; /* no time serve */ } - if (rbufp->recv_length < LEN_PKT_NOMAC) { - sys_badlength++; - return; /* runt packet */ + + /* + * This is for testing. If restricted drop ten percent of + * surviving packets. + */ + if (restrict_mask & RES_TIMEOUT) { + if ((double)ntp_random() / 0x7fffffff < .1) { + sys_restricted++; + return; /* no flakeway */ + } } /* * Version check must be after the query packets, since they - * intentionally use early version. + * intentionally use an early version. */ if (hisversion == NTP_VERSION) { - sys_newversionpkt++; /* new version */ + sys_newversion++; /* new version */ } else if (!(restrict_mask & RES_VERSION) && hisversion >= NTP_OLDVERSION) { - sys_oldversionpkt++; /* previous version */ + sys_oldversion++; /* previous version */ } else { - sys_unknownversion++; + sys_badlength++; return; /* old version */ } @@ -449,47 +421,70 @@ * the number of words following the packet header is 0, no MAC * is present and the packet is not authenticated. If 1, the * packet is a crypto-NAK; if 3, the packet is authenticated - * with DES; if 5, the packet is authenticated with MD5. If 2 or - * 4, the packet is a runt and discarded forthwith. If greater - * than 5, an extension field is present, so we subtract the - * length of the field and go around again. + * with DES; if 5, the packet is authenticated with MD5; if 6, + * the packet is authenticated with SHA. If 2 or * 4, the packet + * is a runt and discarded forthwith. If greater than 6, an + * extension field is present, so we subtract the length of the + * field and go around again. */ authlen = LEN_PKT_NOMAC; has_mac = rbufp->recv_length - authlen; - while (has_mac > 0) { - int temp; + while (has_mac != 0) { + u_int32 len; - if (has_mac % 4 != 0 || has_mac < 0) { + if (has_mac % 4 != 0 || has_mac < MIN_MAC_LEN) { sys_badlength++; - return; /* bad MAC length */ + return; /* bad length */ } - if (has_mac == 1 * 4 || has_mac == 3 * 4 || has_mac == - MAX_MAC_LEN) { + if (has_mac <= MAX_MAC_LEN) { skeyid = ntohl(((u_int32 *)pkt)[authlen / 4]); break; - } else if (has_mac > MAX_MAC_LEN) { - temp = ntohl(((u_int32 *)pkt)[authlen / 4]) & - 0xffff; - if (temp < 4 || temp > NTP_MAXEXTEN || temp % 4 - != 0) { + } else { + opcode = ntohl(((u_int32 *)pkt)[authlen / 4]); + len = opcode & 0xffff; + if (len % 4 != 0 || len < 4 || len + authlen > + rbufp->recv_length) { sys_badlength++; - return; /* bad MAC length */ + return; /* bad length */ } - authlen += temp; - has_mac -= temp; - } else { - sys_badlength++; - return; /* bad MAC length */ + authlen += len; + has_mac -= len; } } -#ifdef OPENSSL - pkeyid = tkeyid = 0; -#endif /* OPENSSL */ + + /* + * If authentication required, a MAC must be present. + */ + if (restrict_mask & RES_DONTTRUST && has_mac == 0) { + sys_restricted++; + return; /* access denied */ + } + + /* + * Update the MRU list and finger the cloggers. It can be a + * little expensive, so turn it off for production use. + */ + restrict_mask = ntp_monitor(rbufp, restrict_mask); + if (restrict_mask & RES_LIMITED) { + sys_limitrejected++; + if (!(restrict_mask & RES_KOD) || hismode == + MODE_BROADCAST) + return; /* rate exceeded */ + + if (hismode == MODE_CLIENT) + fast_xmit(rbufp, MODE_SERVER, skeyid, + restrict_mask); + else + fast_xmit(rbufp, MODE_ACTIVE, skeyid, + restrict_mask); + return; /* rate exceeded */ + } + restrict_mask &= ~RES_KOD; /* * We have tossed out as many buggy packets as possible early in - * the game to reduce the exposure to a clogging attack. Now we + * the game to reduce the exposure to a clogging attack. now we * have to burn some cycles to find the association and * authenticate the packet if required. Note that we burn only * MD5 cycles, again to reduce exposure. There may be no @@ -502,7 +497,7 @@ * address used to construct the autokey is the unicast address * of the interface. However, if the sender is a broadcaster, * the interface broadcast address is used instead. - & Notwithstanding this technobabble, if the sender is a + * Notwithstanding this technobabble, if the sender is a * multicaster, the broadcast address is null, so we use the * unicast address anyway. Don't ask. */ @@ -536,33 +531,56 @@ * is zero, acceptable outcomes of y are NONE and OK. If x is * one, the only acceptable outcome of y is OK. */ + if (has_mac == 0) { + restrict_mask &= ~RES_MSSNTP; is_authentic = AUTH_NONE; /* not required */ #ifdef DEBUG if (debug) - printf("receive: at %ld %s<-%s mode %d code %d auth %d\n", + printf( + "receive: at %ld %s<-%s mode %d len %d\n", current_time, stoa(dstadr_sin), - stoa(&rbufp->recv_srcadr), hismode, retcode, - is_authentic); + stoa(&rbufp->recv_srcadr), hismode, + authlen); #endif } else if (has_mac == 4) { - is_authentic = AUTH_CRYPTO; /* crypto-NAK */ + restrict_mask &= ~RES_MSSNTP; + is_authentic = AUTH_CRYPTO; /* crypto-NAK */ #ifdef DEBUG if (debug) printf( - "receive: at %ld %s<-%s mode %d code %d keyid %08x len %d mac %d auth %d\n", + "receive: at %ld %s<-%s mode %d keyid %08x len %d auth %d\n", current_time, stoa(dstadr_sin), - stoa(&rbufp->recv_srcadr), hismode, retcode, - skeyid, authlen, has_mac, is_authentic); + stoa(&rbufp->recv_srcadr), hismode, skeyid, + authlen + has_mac, is_authentic); #endif + +#ifdef HAVE_NTP_SIGND + /* + * If the signature is 20 bytes long, the last 16 of + * which are zero, then this is a Microsoft client + * wanting AD-style authentication of the server's + * reply. + * + * This is described in Microsoft's WSPP docs, in MS-SNTP: + * http://msdn.microsoft.com/en-us/library/cc212930.aspx + */ + } else if (has_mac == MAX_MD5_LEN && (restrict_mask & RES_MSSNTP) && + (retcode == AM_FXMIT || retcode == AM_NEWPASS) && + (memcmp(zero_key, (char *)pkt + authlen + 4, MAX_MD5_LEN - 4) == + 0)) { + is_authentic = AUTH_NONE; +#endif /* HAVE_NTP_SIGND */ + } else { + restrict_mask &= ~RES_MSSNTP; #ifdef OPENSSL /* * For autokey modes, generate the session key * and install in the key cache. Use the socket * broadcast or unicast address as appropriate. */ - if (skeyid > NTP_MAXKEY) { + if (crypto_flags && skeyid > NTP_MAXKEY) { /* * More on the autokey dance (AKD). A cookie is @@ -589,6 +607,10 @@ * # if unsync, 0 * % can't happen */ + if (has_mac < MAX_MD5_LEN) { + sys_badauth++; + return; + } if (hismode == MODE_BROADCAST) { /* @@ -605,7 +627,7 @@ return; /* no wildcard */ } pkeyid = 0; - if (!SOCKNUL(&rbufp->dstadr->bcast)) + if (!SOCK_UNSPEC(&rbufp->dstadr->bcast)) dstadr_sin = &rbufp->dstadr->bcast; } else if (peer == NULL) { @@ -646,23 +668,21 @@ * association. Note that there is no key zero. */ if (!authdecrypt(skeyid, (u_int32 *)pkt, authlen, - has_mac)) { + has_mac)) is_authentic = AUTH_ERROR; - sys_badauth++; - } else { + else is_authentic = AUTH_OK; - } #ifdef OPENSSL - if (skeyid > NTP_MAXKEY) + if (crypto_flags && skeyid > NTP_MAXKEY) authtrust(skeyid, 0); #endif /* OPENSSL */ #ifdef DEBUG if (debug) printf( - "receive: at %ld %s<-%s mode %d code %d keyid %08x len %d mac %d auth %d\n", + "receive: at %ld %s<-%s mode %d keyid %08x len %d auth %d\n", current_time, stoa(dstadr_sin), - stoa(&rbufp->recv_srcadr), hismode, retcode, - skeyid, authlen, has_mac, is_authentic); + stoa(&rbufp->recv_srcadr), hismode, skeyid, + authlen + has_mac, is_authentic); #endif } @@ -687,19 +707,21 @@ case AM_FXMIT: /* - * The vanilla case is when this is not a multicast - * interface. If authentication succeeds, return a - * server mode packet; if not and the key ID is nonzero, - * return a crypto-NAK. + * If authentication OK, send a server reply; otherwise, + * send a crypto-NAK. */ if (!(rbufp->dstadr->flags & INT_MCASTOPEN)) { if (AUTH(restrict_mask & RES_DONTTRUST, - is_authentic)) + is_authentic)) { fast_xmit(rbufp, MODE_SERVER, skeyid, restrict_mask); - else if (is_authentic == AUTH_ERROR) + } else if (is_authentic == AUTH_ERROR) { fast_xmit(rbufp, MODE_SERVER, 0, restrict_mask); + sys_badauth++; + } else { + sys_restricted++; + } return; /* hooray */ } @@ -713,21 +735,17 @@ } /* - * Do not respond if unsynchronized or stratum is below - * the floor or at or above the ceiling. - */ - if (sys_leap == LEAP_NOTINSYNC || sys_stratum < - sys_floor || sys_stratum >= sys_ceiling) - return; /* bad stratum */ - - /* - * Do not respond if our stratum is greater than the - * manycaster or it has already synchronized to us. - */ - if (sys_peer == NULL || hisstratum < sys_stratum || - (sys_cohort && hisstratum == sys_stratum) || - rbufp->dstadr->addr_refid == pkt->refid) + * Do not respond if we are not synchronized or our + * stratum is greater than the manycaster or the + * manycaster has already synchronized to us. + */ + if (sys_leap == LEAP_NOTINSYNC || sys_stratum >= + hisstratum || (!sys_cohort && sys_stratum == + hisstratum + 1) || rbufp->dstadr->addr_refid == + pkt->refid) { + sys_declined++; return; /* no help */ + } /* * Respond only if authentication succeeds. Don't do a @@ -736,7 +754,6 @@ if (AUTH(restrict_mask & RES_DONTTRUST, is_authentic)) fast_xmit(rbufp, MODE_SERVER, skeyid, restrict_mask); - return; /* hooray */ /* @@ -758,24 +775,39 @@ */ case AM_MANYCAST: if (!AUTH(sys_authenticate | (restrict_mask & - (RES_NOPEER | RES_DONTTRUST)), is_authentic)) - return; /* bad auth */ + (RES_NOPEER | RES_DONTTRUST)), is_authentic)) { + sys_restricted++; + return; /* access denied */ + } + /* + * Do not respond if unsynchronized or stratum is below + * the floor or at or above the ceiling. + */ + if (hisleap == LEAP_NOTINSYNC || hisstratum < + sys_floor || hisstratum >= sys_ceiling) { + sys_declined++; + return; /* no help */ + } if ((peer2 = findmanycastpeer(rbufp)) == NULL) { sys_restricted++; return; /* not enabled */ } - if ((peer = newpeer(&rbufp->recv_srcadr, - rbufp->dstadr, MODE_CLIENT, - hisversion, NTP_MINDPOLL, NTP_MAXDPOLL, - FLAG_IBURST | FLAG_PREEMPT, MDF_UCAST | MDF_ACLNT, - 0, skeyid)) == NULL) - return; /* system error */ + if ((peer = newpeer(&rbufp->recv_srcadr, rbufp->dstadr, + MODE_CLIENT, hisversion, NTP_MINDPOLL, NTP_MAXDPOLL, + FLAG_PREEMPT, MDF_UCAST | MDF_ACLNT, 0, skeyid)) == + NULL) { + sys_declined++; + return; /* ignore duplicate */ + } /* * We don't need these, but it warms the billboards. */ - peer->ttl = peer2->ttl; + if (peer2->flags & FLAG_IBURST) + peer->flags |= FLAG_IBURST; + peer->minpoll = peer2->minpoll; + peer->maxpoll = peer2->maxpoll; break; /* @@ -785,68 +817,92 @@ * kiss any frogs here. */ case AM_NEWBCL: + if (sys_bclient == 0) { + sys_restricted++; + return; /* not enabled */ + } if (!AUTH(sys_authenticate | (restrict_mask & - (RES_NOPEER | RES_DONTTRUST)), is_authentic)) - return; /* bad auth */ + (RES_NOPEER | RES_DONTTRUST)), is_authentic)) { + sys_restricted++; + return; /* access denied */ + } /* * Do not respond if unsynchronized or stratum is below * the floor or at or above the ceiling. */ if (hisleap == LEAP_NOTINSYNC || hisstratum < - sys_floor || hisstratum >= sys_ceiling) - return; /* bad stratum */ - - switch (sys_bclient) { - - /* - * If not enabled, just skedaddle. - */ - case 0: - sys_restricted++; - return; /* not enabled */ + sys_floor || hisstratum >= sys_ceiling) { + sys_declined++; + return; /* no help */ + } +#ifdef OPENSSL /* - * Execute the initial volley in order to calibrate the - * propagation delay and run the Autokey protocol, if - * enabled. + * Do not respond if Autokey and the opcode is not a + * CRYPTO_ASSOC response with associationn ID. */ - case 1: - if ((peer = newpeer(&rbufp->recv_srcadr, - rbufp->dstadr, MODE_CLIENT, hisversion, - NTP_MINDPOLL, NTP_MAXDPOLL, FLAG_MCAST | - FLAG_IBURST, MDF_BCLNT, 0, skeyid)) == - NULL) - return; /* system error */ -#ifdef OPENSSL - if (skeyid > NTP_MAXKEY) - crypto_recv(peer, rbufp); + if (crypto_flags && skeyid > NTP_MAXKEY && (opcode & + 0xffff0000) != (CRYPTO_ASSOC | CRYPTO_RESP)) { + sys_declined++; + return; /* protocol error */ + } #endif /* OPENSSL */ - return; /* hooray */ - /* - * Do not execute the initial volley. + * Determine whether to execute the initial volley. */ - case 2: + if (sys_bdelay != 0) { #ifdef OPENSSL /* * If a two-way exchange is not possible, * neither is Autokey. */ - if (skeyid > NTP_MAXKEY) { - msyslog(LOG_INFO, - "receive: autokey requires two-way communication"); + if (crypto_flags && skeyid > NTP_MAXKEY) { + sys_restricted++; return; /* no autokey */ } #endif /* OPENSSL */ + + /* + * Do not execute the volley. Start out in + * broadcast client mode. + */ if ((peer = newpeer(&rbufp->recv_srcadr, rbufp->dstadr, MODE_BCLIENT, hisversion, - NTP_MINDPOLL, NTP_MAXDPOLL, 0, MDF_BCLNT, 0, - skeyid)) == NULL) - return; /* system error */ + pkt->ppoll, pkt->ppoll, 0, 0, 0, + skeyid)) == NULL) { + sys_restricted++; + return; /* ignore duplicate */ + + } else { + peer->delay = sys_bdelay; + peer->bias = -sys_bdelay / 2.; + } + break; } - break; + + /* + * Execute the initial volley in order to calibrate the + * propagation delay and run the Autokey protocol. + * + * Note that the minpoll is taken from the broadcast + * packet, normally 6 (64 s) and that the poll interval + * is fixed at this value. + */ + if ((peer = newpeer(&rbufp->recv_srcadr, rbufp->dstadr, + MODE_CLIENT, hisversion, pkt->ppoll, pkt->ppoll, + FLAG_IBURST | FLAG_PREEMPT, MDF_BCLNT, 0, + skeyid)) == NULL) { + sys_restricted++; + return; /* ignore duplicate */ + } +#ifdef OPENSSL + if (skeyid > NTP_MAXKEY) + crypto_recv(peer, rbufp); +#endif /* OPENSSL */ + + return; /* hooray */ /* * This is the first packet received from a symmetric active @@ -854,41 +910,57 @@ * mobilize a passive association. If not, kiss the frog. */ case AM_NEWPASS: + if (!AUTH(sys_authenticate | (restrict_mask & + (RES_NOPEER | RES_DONTTRUST)), is_authentic)) { - /* - * If the inbound packet is correctly authenticated and - * enabled, a symmetric passive association is - * mobilized. If not but correctly authenticated, a - * symmetric active response is sent. If authentication - * fails, send a crypto-NAK packet. - */ - if (!AUTH(restrict_mask & RES_DONTTRUST, is_authentic)) - { - if (is_authentic == AUTH_ERROR) + /* + * If authenticated but cannot mobilize an + * association, send a symmetric passive + * response without mobilizing an association. + * This is for drat broken Windows clients. See + * Microsoft KB 875424 for preferred workaround. + */ + if (AUTH(restrict_mask & RES_DONTTRUST, + is_authentic)) { + fast_xmit(rbufp, MODE_PASSIVE, skeyid, + restrict_mask); + return; /* hooray */ + } + if (is_authentic == AUTH_ERROR) { fast_xmit(rbufp, MODE_ACTIVE, 0, restrict_mask); - return; /* bad auth */ - } - if (!AUTH(sys_authenticate | (restrict_mask & - RES_NOPEER), is_authentic)) { - fast_xmit(rbufp, MODE_ACTIVE, skeyid, - restrict_mask); - return; /* hooray */ + sys_restricted++; + } } /* - * Do not respond if stratum is below the floor. + * Do not respond if synchronized and stratum is either + * below the floor or at or above the ceiling. Note, + * this allows an unsynchronized peer to synchronize to + * us. It would be very strange if he did and then was + * nipped, but that could only happen if we were + * operating at the top end of the range. */ - if (hisstratum < sys_floor) - return; /* bad stratum */ + if (hisleap != LEAP_NOTINSYNC && (hisstratum < + sys_floor || hisstratum >= sys_ceiling)) { + sys_declined++; + return; /* no help */ + } + /* + * The message is correctly authenticated and + * allowed. Mobiliae a symmetric passive association. + */ if ((peer = newpeer(&rbufp->recv_srcadr, - rbufp->dstadr, MODE_PASSIVE, hisversion, - NTP_MINDPOLL, NTP_MAXDPOLL, 0, MDF_UCAST, 0, - skeyid)) == NULL) - return; /* system error */ + rbufp->dstadr, MODE_PASSIVE, hisversion, pkt->ppoll, + NTP_MAXDPOLL, FLAG_PREEMPT, MDF_UCAST, 0, + skeyid)) == NULL) { + sys_declined++; + return; /* ignore duplicate */ + } break; + /* * Process regular packet. Nothing special. */ @@ -902,99 +974,191 @@ * attempt to deny service, just ignore it. */ case AM_ERR: + sys_declined++; return; /* * For everything else there is the bit bucket. */ default: + sys_declined++; return; } + +#ifdef OPENSSL + /* + * If the association is configured for Autokey, the packet must + * have a public key ID; if not, the packet must have a + * symmetric key ID. + */ + if (is_authentic != AUTH_CRYPTO && (((peer->flags & + FLAG_SKEY) && skeyid <= NTP_MAXKEY) || (!(peer->flags & + FLAG_SKEY) && skeyid > NTP_MAXKEY))) { + sys_badauth++; + return; + } +#endif /* OPENSSL */ + peer->received++; peer->flash &= ~PKT_TEST_MASK; + if (peer->flags & FLAG_XBOGUS) { + peer->flags &= ~FLAG_XBOGUS; + peer->flash |= TEST3; + } /* * Next comes a rigorous schedule of timestamp checking. If the - * transmit timestamp is zero, the server is horribly broken. + * transmit timestamp is zero, the server has not initialized in + * interleaved modes or is horribly broken. */ if (L_ISZERO(&p_xmt)) { - return; /* read rfc1305 */ + peer->flash |= TEST3; /* unsynch */ /* * If the transmit timestamp duplicates a previous one, the * packet is a replay. This prevents the bad guys from replaying * the most recent packet, authenticated or not. */ - } else if (L_ISEQU(&peer->org, &p_xmt)) { - peer->flash |= TEST1; + } else if (L_ISEQU(&peer->xmt, &p_xmt)) { + peer->flash |= TEST1; /* duplicate */ peer->oldpkt++; - return; /* duplicate packet */ - + return; + + /* + * If this is a broadcast mode packet, skip further checking. If + * an intial volley, bail out now and let the client do its + * stuff. If the origin timestamp is nonzero, this is an + * interleaved broadcast. so restart the protocol. + */ + } else if (hismode == MODE_BROADCAST) { + if (!L_ISZERO(&p_org) && !(peer->flags & FLAG_XB)) { + peer->flags |= FLAG_XB; + peer->aorg = p_xmt; + peer->borg = rbufp->recv_time; + report_event(PEVNT_XLEAVE, peer, NULL); + return; + } + + /* + * Check for bogus packet in basic mode. If found, switch to + * interleaved mode and resynchronize, but only after confirming + * the packet is not bogus in symmetric interleaved mode. + */ + } else if (peer->flip == 0) { + if (!L_ISEQU(&p_org, &peer->aorg)) { + peer->bogusorg++; + peer->flash |= TEST2; /* bogus */ + if (!L_ISZERO(&peer->dst) && L_ISEQU(&p_org, + &peer->dst)) { + peer->flip = 1; + report_event(PEVNT_XLEAVE, peer, NULL); + } + } else { + L_CLR(&peer->aorg); + } + + /* + * Check for valid nonzero timestamp fields. + */ + } else if (L_ISZERO(&p_org) || L_ISZERO(&p_rec) || + L_ISZERO(&peer->dst)) { + peer->flash |= TEST3; /* unsynch */ /* - * If this is a broadcast mode packet, skip further checking. + * Check for bogus packet in interleaved symmetric mode. This + * can happen if a packet is lost, duplicat or crossed. If + * found, flip and resynchronize. */ - } else if (hismode != MODE_BROADCAST) { - if (L_ISZERO(&p_org)) - peer->flash |= TEST3; /* protocol unsynch */ - else if (!L_ISEQU(&p_org, &peer->xmt)) - peer->flash |= TEST2; /* bogus packet */ + } else if (!L_ISZERO(&peer->dst) && !L_ISEQU(&p_org, + &peer->dst)) { + peer->bogusorg++; + peer->flags |= FLAG_XBOGUS; + peer->flash |= TEST2; /* bogus */ } /* - * Update the origin and destination timestamps. If - * unsynchronized or bogus abandon ship. If the crypto machine - * breaks, light the crypto bit and plaint the log. + * Update the state variables. */ - peer->org = p_xmt; - peer->rec = rbufp->recv_time; - if (peer->flash & PKT_TEST_MASK) { -#ifdef OPENSSL - if (crypto_flags && (peer->flags & FLAG_SKEY)) { - rval = crypto_recv(peer, rbufp); - if (rval != XEVNT_OK) { - peer_clear(peer, "CRYP"); - peer->flash |= TEST9; /* crypto error */ - } - } -#endif /* OPENSSL */ - return; /* unsynch */ + if (peer->flip == 0) { + if (hismode != MODE_BROADCAST) + peer->rec = p_xmt; + peer->dst = rbufp->recv_time; } + peer->xmt = p_xmt; /* - * The timestamps are valid and the receive packet matches the - * last one sent. If the packet is a crypto-NAK, the server - * might have just changed keys. We reset the association - * and restart the protocol. + * If this is a crypto_NAK, the server cannot authenticate a + * client packet. The server might have just changed keys. Clear + * the association and restart the protocol. */ if (is_authentic == AUTH_CRYPTO) { - peer_clear(peer, "AUTH"); - return; /* crypto-NAK */ + report_event(PEVNT_AUTH, peer, "crypto_NAK"); + peer->flash |= TEST5; /* bad auth */ + peer->badauth++; + if (peer->flags & FLAG_PREEMPT) { + unpeer(peer); + return; + } +#ifdef OPENSSL + if (peer->crypto) + peer_clear(peer, "AUTH"); +#endif /* OPENSSL */ + return; /* - * If the association is authenticated, the key ID is nonzero - * and received packets must be authenticated. This is designed - * to avoid a bait-and-switch attack, which was possible in past - * versions. If symmetric modes, return a crypto-NAK. The peer - * should restart the protocol. + * If the digest fails, the client cannot authenticate a server + * reply to a client packet previously sent. The loopback check + * is designed to avoid a bait-and-switch attack, which was + * possible in past versions. If symmetric modes, return a + * crypto-NAK. The peer should restart the protocol. */ - } else if (!AUTH(peer->keyid || (restrict_mask & RES_DONTTRUST), + } else if (!AUTH(has_mac || (restrict_mask & RES_DONTTRUST), is_authentic)) { - peer->flash |= TEST5; + report_event(PEVNT_AUTH, peer, "digest"); + peer->flash |= TEST5; /* bad auth */ + peer->badauth++; if (hismode == MODE_ACTIVE || hismode == MODE_PASSIVE) fast_xmit(rbufp, MODE_ACTIVE, 0, restrict_mask); - return; /* bad auth */ + if (peer->flags & FLAG_PREEMPT) { + unpeer(peer); + return; + } +#ifdef OPENSSL + if (peer->crypto) + peer_clear(peer, "AUTH"); +#endif /* OPENSSL */ + return; + } + + /* + * Set the peer ppoll to the maximum of the packet ppoll and the + * peer minpoll. If a kiss-o'-death, set the peer minpoll to + * this maximumn and advance the headway to give the sender some + * headroom. Very intricate. + */ + peer->ppoll = max(peer->minpoll, pkt->ppoll); + if (hismode == MODE_SERVER && hisleap == LEAP_NOTINSYNC && + hisstratum == STRATUM_UNSPEC && memcmp(&pkt->refid, + "RATE", 4) == 0) { + peer->selbroken++; + report_event(PEVNT_RATE, peer, NULL); + if (pkt->ppoll > peer->minpoll) + peer->minpoll = peer->ppoll; + peer->burst = peer->retry = 0; + peer->throttle = (NTP_SHIFT + 1) * (1 << peer->minpoll); + poll_update(peer, pkt->ppoll); + return; /* kiss-o'-death */ } /* * That was hard and I am sweaty, but the packet is squeaky * clean. Get on with real work. */ - peer->received++; peer->timereceived = current_time; if (is_authentic == AUTH_OK) peer->flags |= FLAG_AUTHENTIC; else peer->flags &= ~FLAG_AUTHENTIC; + #ifdef OPENSSL /* * More autokey dance. The rules of the cha-cha are as follows: @@ -1014,31 +1178,64 @@ * 5. Check to see that one or more hashes of the current key ID * matches the previous key ID or ultimate original key ID * obtained from the broadcaster or symmetric peer. If no - * match, sit the dance and wait for timeout. + * match, sit the dance and call for new autokey values. * - * In case of crypto error, fire the orchestra and stop dancing. - * This is considered a permanant error, so light the crypto bit - * to suppress further requests. If preemptable or ephemeral, - * scuttle the ship. + * In case of crypto error, fire the orchestra, stop dancing and + * restart the protocol. */ - if (crypto_flags && (peer->flags & FLAG_SKEY)) { + if (peer->flags & FLAG_SKEY) { + /* + * Decrement remaining audokey hashes. This isn't + * perfect if a packet is lost, but results in no harm. + */ + ap = (struct autokey *)peer->recval.ptr; + if (ap != NULL) { + if (ap->seq > 0) + ap->seq--; + } peer->flash |= TEST8; rval = crypto_recv(peer, rbufp); - if (rval != XEVNT_OK) { - peer_clear(peer, "CRYP"); - peer->flash |= TEST9; /* crypto error */ - if (peer->flags & FLAG_PREEMPT || - !(peer->flags & FLAG_CONFIG)) - unpeer(peer); + if (rval == XEVNT_OK) { + peer->unreach = 0; + } else { + if (rval == XEVNT_ERR) { + report_event(PEVNT_RESTART, peer, + "crypto error"); + peer_clear(peer, "CRYP"); + peer->flash |= TEST9; /* bad crypt */ + if (peer->flags & FLAG_PREEMPT) + unpeer(peer); + } return; + } - } else if (hismode == MODE_SERVER) { + /* + * If server mode, verify the receive key ID matches + * the transmit key ID. + */ + if (hismode == MODE_SERVER) { if (skeyid == peer->keyid) peer->flash &= ~TEST8; + + /* + * If an extension field is present, verify only that it + * has been correctly signed. We don't need a sequence + * check here, but the sequence continues. + */ } else if (!(peer->flash & TEST8)) { peer->pkeyid = skeyid; - } else if ((ap = (struct autokey *)peer->recval.ptr) != - NULL) { + + /* + * Now the fun part. Here, skeyid is the current ID in + * the packet, pkeyid is the ID in the last packet and + * tkeyid is the hash of skeyid. If the autokey values + * have not been received, this is an automatic error. + * If so, check that the tkeyid matches pkeyid. If not, + * hash tkeyid and try again. If the number of hashes + * exceeds the number remaining in the sequence, declare + * a successful failure and refresh the autokey values. + */ + } else if (ap != NULL) { int i; for (i = 0; ; i++) { @@ -1046,25 +1243,34 @@ tkeyid == ap->key) { peer->flash &= ~TEST8; peer->pkeyid = skeyid; + ap->seq -= i; break; } - if (i > ap->seq) + if (i > ap->seq) { + peer->crypto &= + ~CRYPTO_FLAG_AUTO; break; + } tkeyid = session_key( &rbufp->recv_srcadr, dstadr_sin, tkeyid, pkeyid, 0); } + if (peer->flash & TEST8) + report_event(PEVNT_AUTH, peer, "keylist"); } if (!(peer->crypto & CRYPTO_FLAG_PROV)) /* test 9 */ - peer->flash |= TEST8; /* not proventic */ + peer->flash |= TEST8; /* bad autokey */ /* - * If the transmit queue is nonempty, clamp the host - * poll interval to the packet poll interval. + * The maximum lifetime of the protocol is about one + * week before restarting the Autokey protocol to + * refreshed certificates and leapseconds values. */ - if (peer->cmmd != 0) { - peer->ppoll = pkt->ppoll; - poll_update(peer, peer->hpoll); + if (current_time > peer->refresh) { + report_event(PEVNT_RESTART, peer, + "crypto refresh"); + peer_clear(peer, "TIME"); + return; } } #endif /* OPENSSL */ @@ -1074,17 +1280,20 @@ * the packet over the fence for processing, which may light up * more flashers. */ - process_packet(peer, pkt); + process_packet(peer, pkt, rbufp->recv_length); /* - * Well, that was nice. If TEST4 is lit, either the crypto - * machine jammed or a kiss-o'-death packet flew in, either of - * which is fatal. + * In interleaved mode update the state variables. Also adjust the + * transmit phase to avoid crossover. */ - if (peer->flash & TEST4) { - msyslog(LOG_INFO, "receive: fatal error %04x for %s", - peer->flash, stoa(&peer->srcadr)); - return; + if (peer->flip != 0) { + peer->rec = p_rec; + peer->dst = rbufp->recv_time; + if (peer->nextdate - current_time < (1 << min(peer->ppoll, + peer->hpoll)) / 2) + peer->nextdate++; + else + peer->nextdate--; } } @@ -1098,66 +1307,73 @@ void process_packet( register struct peer *peer, - register struct pkt *pkt + register struct pkt *pkt, + u_int len ) { double t34, t21; double p_offset, p_del, p_disp; - l_fp p_rec, p_xmt, p_org, p_reftime; - l_fp ci; + l_fp p_rec, p_xmt, p_org, p_reftime, ci; u_char pmode, pleap, pstratum; + char statstr[NTP_MAXSTRLEN]; +#ifdef ASSYM + int itemp; + double etemp, ftemp, td; +#endif /* ASSYM */ sys_processed++; peer->processed++; p_del = FPTOD(NTOHS_FP(pkt->rootdelay)); - p_disp = FPTOD(NTOHS_FP(pkt->rootdispersion)); + p_offset = 0; + p_disp = FPTOD(NTOHS_FP(pkt->rootdisp)); NTOHL_FP(&pkt->reftime, &p_reftime); + NTOHL_FP(&pkt->org, &p_org); NTOHL_FP(&pkt->rec, &p_rec); NTOHL_FP(&pkt->xmt, &p_xmt); pmode = PKT_MODE(pkt->li_vn_mode); pleap = PKT_LEAP(pkt->li_vn_mode); - if (pmode != MODE_BROADCAST) - NTOHL_FP(&pkt->org, &p_org); - else - p_org = peer->rec; pstratum = PKT_TO_STRATUM(pkt->stratum); /* - * Test for kiss-o'death packet) - */ - if (pleap == LEAP_NOTINSYNC && pstratum == STRATUM_UNSPEC) { - if (memcmp(&pkt->refid, "DENY", 4) == 0) { - peer_clear(peer, "DENY"); - peer->flash |= TEST4; /* access denied */ - } - } - - /* - * Capture the header values. + * Capture the header values in the client/peer association.. */ - record_raw_stats(&peer->srcadr, peer->dstadr ? &peer->dstadr->sin : NULL, &p_org, - &p_rec, &p_xmt, &peer->rec); + record_raw_stats(&peer->srcadr, peer->dstadr ? + &peer->dstadr->sin : NULL, &p_org, &p_rec, &p_xmt, + &peer->dst); peer->leap = pleap; peer->stratum = min(pstratum, STRATUM_UNSPEC); peer->pmode = pmode; - peer->ppoll = pkt->ppoll; peer->precision = pkt->precision; peer->rootdelay = p_del; - peer->rootdispersion = p_disp; + peer->rootdisp = p_disp; peer->refid = pkt->refid; /* network byte order */ peer->reftime = p_reftime; /* - * Verify the server is synchronized; that is, the leap bits and - * stratum are valid, the root delay and root dispersion are - * valid and the reference timestamp is not later than the - * transmit timestamp. + * First, if either burst mode is armed, enable the burst. + * Compute the headway for the next packet and delay if + * necessary to avoid exceeding the threshold. + */ + if (peer->retry > 0) { + peer->retry = 0; + if (peer->reach) + peer->burst = min(1 << (peer->hpoll - + peer->minpoll), NTP_SHIFT) - 1; + else + peer->burst = NTP_IBURST - 1; + if (peer->burst > 0) + peer->nextdate = current_time; + } + poll_update(peer, peer->hpoll); + + /* + * Verify the server is synchronized; that is, the leap bits, + * stratum and root distance are valid. */ if (pleap == LEAP_NOTINSYNC || /* test 6 */ pstratum < sys_floor || pstratum >= sys_ceiling) - peer->flash |= TEST6; /* peer not synch */ - if (p_del < 0 || p_disp < 0 || p_del / /* test 7 */ - 2 + p_disp >= MAXDISPERSE || !L_ISHIS(&p_xmt, &p_reftime)) + peer->flash |= TEST6; /* bad synch or strat */ + if (p_del / 2 + p_disp >= MAXDISPERSE) /* test 7 */ peer->flash |= TEST7; /* bad header */ /* @@ -1166,6 +1382,7 @@ * receive() routine. */ if (peer->flash & PKT_TEST_MASK) { + peer->seldisptoolarge++; #ifdef DEBUG if (debug) printf("packet: flash header %04x\n", @@ -1173,11 +1390,15 @@ #endif return; } - if (!(peer->reach)) { - report_event(EVNT_REACH, peer); + + /* + * If the peer was previously unreachable, raise a trap. In any + * case, mark it reachable. + */ + if (!peer->reach) { + report_event(PEVNT_REACH, peer, NULL); peer->timereachable = current_time; } - poll_update(peer, peer->hpoll); peer->reach |= 1; /* @@ -1185,8 +1406,7 @@ * roundtrip delay and dispersion. The equations are reordered * from the spec for more efficient use of temporaries. For a * broadcast association, offset the last measurement by the - * computed delay during the client/server volley. Note that - * org has been set to the time of last reception. Note the + * computed delay during the client/server volley. Note the * computation of dispersion includes the system precision plus * that due to the frequency error since the origin time. * @@ -1201,52 +1421,201 @@ * only half that span. Since the typical first-order * differences are usually very small, they are converted to 64- * bit doubles and all remaining calculations done in floating- - * point arithmetic. This preserves the accuracy while retaining - * the 68-year span. + * double arithmetic. This preserves the accuracy while + * retaining the 68-year span. * - * Let t1 = p_org, t2 = p_rec, t3 = p_xmt, t4 = peer->rec: + * There are three interleaving schemes, basic, interleaved + * symmetric and interleaved broadcast. The timestamps are + * idioscyncratically different. See the onwire briefing/white + * paper at www.eecis.udel.edu/~mills for details. + * + * Interleaved symmetric mode + * t1 = peer->aorg/borg, t2 = peer->rec, t3 = p_xmt, + * t4 = peer->dst + */ + if (peer->flip != 0) { + ci = p_xmt; /* t3 - t4 */ + L_SUB(&ci, &peer->dst); + LFPTOD(&ci, t34); + ci = p_rec; /* t2 - t1 */ + if (peer->flip > 0) + L_SUB(&ci, &peer->borg); + else + L_SUB(&ci, &peer->aorg); + LFPTOD(&ci, t21); + p_del = t21 - t34; + p_offset = (t21 + t34) / 2.; + if (p_del < 0 || p_del > 1.) { + sprintf(statstr, "t21 %.6f t34 %.6f", t21, t34); + report_event(PEVNT_XERR, peer, statstr); + return; + } + + /* + * Broadcast modes */ - ci = p_xmt; /* t3 - t4 */ - L_SUB(&ci, &peer->rec); - LFPTOD(&ci, t34); - ci = p_rec; /* t2 - t1 */ - L_SUB(&ci, &p_org); - LFPTOD(&ci, t21); - ci = peer->rec; /* t4 - t1 */ - L_SUB(&ci, &p_org); - - /* - * If running in a broadcast association, the clock offset is - * (t1 - t0) corrected by the one-way delay, but we can't - * measure that directly. Therefore, we start up in MODE_CLIENT - * mode, set FLAG_MCAST and exchange eight messages to determine - * the clock offset. When the last message is sent, we switch to - * MODE_BCLIENT mode. The next broadcast message after that - * computes the broadcast offset and clears FLAG_MCAST. - */ - if (pmode == MODE_BROADCAST) { - p_offset = t34; - if (peer->flags & FLAG_MCAST) { - peer->estbdelay = peer->offset - p_offset; - if (peer->hmode == MODE_CLIENT) + } else if (peer->pmode == MODE_BROADCAST) { + + /* + * Interleaved broadcast mode. Use interleaved timestamps. + * t1 = peer->borg, t2 = p_org, t3 = p_org, t4 = aorg + */ + if (peer->flags & FLAG_XB) { + ci = p_org; /* delay */ + L_SUB(&ci, &peer->aorg); + LFPTOD(&ci, t34); + ci = p_org; /* t2 - t1 */ + L_SUB(&ci, &peer->borg); + LFPTOD(&ci, t21); + peer->aorg = p_xmt; + peer->borg = peer->dst; + if (t34 < 0 || t34 > 1.) { + sprintf(statstr, + "offset %.6f delay %.6f", t21, t34); + report_event(PEVNT_XERR, peer, statstr); return; + } + p_offset = t21; + peer->xleave = t34; + + /* + * Basic broadcast - use direct timestamps. + * t3 = p_xmt, t4 = peer->dst + */ + } else { + ci = p_xmt; /* t3 - t4 */ + L_SUB(&ci, &peer->dst); + LFPTOD(&ci, t34); + p_offset = t34; + } - peer->flags &= ~(FLAG_MCAST | FLAG_BURST); + /* + * When calibration is complete and the clock is + * synchronized, the bias is calculated as the difference + * between the unicast timestamp and the broadcast + * timestamp. This works for both basic and interleaved + * modes. + */ + if (peer->cast_flags & MDF_BCLNT) { + peer->cast_flags &= ~MDF_BCLNT; + peer->delay = (peer->offset - p_offset) * 2; } - p_offset += peer->estbdelay; p_del = peer->delay; - p_disp = 0; + p_offset += p_del / 2; + + + /* + * Basic mode, otherwise known as the old fashioned way. + * + * t1 = p_org, t2 = p_rec, t3 = p_xmt, t4 = peer->dst + */ } else { + ci = p_xmt; /* t3 - t4 */ + L_SUB(&ci, &peer->dst); + LFPTOD(&ci, t34); + ci = p_rec; /* t2 - t1 */ + L_SUB(&ci, &p_org); + LFPTOD(&ci, t21); + p_del = fabs(t21 - t34); p_offset = (t21 + t34) / 2.; - p_del = t21 - t34; - LFPTOD(&ci, p_disp); - p_disp = LOGTOD(sys_precision) + - LOGTOD(peer->precision) + clock_phi * p_disp; } - p_del = max(p_del, LOGTOD(sys_precision)); + p_offset += peer->bias; + p_disp = LOGTOD(sys_precision) + LOGTOD(peer->precision) + + clock_phi * p_del; + +#if ASSYM + /* + * This code calculates the outbound and inbound data rates by + * measuring the differences between timestamps at different + * packet lengths. This is helpful in cases of large asymmetric + * delays commonly experienced on deep space communication + * links. + */ + if (peer->t21_last > 0 && peer->t34_bytes > 0) { + itemp = peer->t21_bytes - peer->t21_last; + if (itemp > 25) { + etemp = t21 - peer->t21; + if (fabs(etemp) > 1e-6) { + ftemp = itemp / etemp; + if (ftemp > 1000.) + peer->r21 = ftemp; + } + } + itemp = len - peer->t34_bytes; + if (itemp > 25) { + etemp = -t34 - peer->t34; + if (fabs(etemp) > 1e-6) { + ftemp = itemp / etemp; + if (ftemp > 1000.) + peer->r34 = ftemp; + } + } + } + + /* + * The following section compensates for different data rates on + * the outbound (d21) and inbound (t34) directions. To do this, + * it finds t such that r21 * t - r34 * (d - t) = 0, where d is + * the roundtrip delay. Then it calculates the correction as a + * fraction of d. + */ + peer->t21 = t21; + peer->t21_last = peer->t21_bytes; + peer->t34 = -t34; + peer->t34_bytes = len; +#ifdef DEBUG + if (debug > 1) + printf("packet: t21 %.9lf %d t34 %.9lf %d\n", peer->t21, + peer->t21_bytes, peer->t34, peer->t34_bytes); +#endif + if (peer->r21 > 0 && peer->r34 > 0 && p_del > 0) { + if (peer->pmode != MODE_BROADCAST) + td = (peer->r34 / (peer->r21 + peer->r34) - + .5) * p_del; + else + td = 0; + + /* + * Unfortunately, in many cases the errors are + * unacceptable, so for the present the rates are not + * used. In future, we might find conditions where the + * calculations are useful, so this should be considered + * a work in progress. + */ + t21 -= td; + t34 -= td; +#ifdef DEBUG + if (debug > 1) + printf("packet: del %.6lf r21 %.1lf r34 %.1lf %.6lf\n", + p_del, peer->r21 / 1e3, peer->r34 / 1e3, + td); +#endif + } +#endif /* ASSYM */ + + /* + * That was awesome. Now hand off to the clock filter. + */ clock_filter(peer, p_offset, p_del, p_disp); - record_peer_stats(&peer->srcadr, ctlpeerstatus(peer), - peer->offset, peer->delay, peer->disp, peer->jitter); + + /* + * If we are in broadcast calibrate mode, return to broadcast + * client mode when the client is fit and the autokey dance is + * complete. + */ + if ((peer->cast_flags & MDF_BCLNT) && !(peer_unfit(peer) & + TEST11)) { +#ifdef OPENSSL + if (peer->flags & FLAG_SKEY) { + if (!(~peer->crypto & CRYPTO_FLAG_ALL)) + peer->hmode = MODE_BCLIENT; + } else { + peer->hmode = MODE_BCLIENT; + } +#else /* OPENSSL */ + peer->hmode = MODE_BCLIENT; +#endif /* OPENSSL */ + } } @@ -1254,39 +1623,73 @@ * clock_update - Called at system process update intervals. */ static void -clock_update(void) +clock_update( + struct peer *peer /* peer structure pointer */ + ) { - u_char oleap; - u_char ostratum; double dtemp; - - /* - * There must be a system peer at this point. If we just changed - * the system peer, but have a newer sample from the old one, - * wait until newer data are available. - */ - if (sys_poll < sys_peer->minpoll) - sys_poll = sys_peer->minpoll; - if (sys_poll > sys_peer->maxpoll) - sys_poll = sys_peer->maxpoll; - poll_update(sys_peer, sys_poll); - if (sys_peer->epoch <= sys_clocktime) - return; + l_fp now; +#ifdef HAVE_LIBSCF_H + char *fmri; +#endif /* HAVE_LIBSCF_H */ + + /* + * Update the system state variables. We do this very carefully, + * as the poll interval might need to be clamped differently. + */ + sys_peer = peer; + sys_epoch = peer->epoch; + if (sys_poll < peer->minpoll) + sys_poll = peer->minpoll; + if (sys_poll > peer->maxpoll) + sys_poll = peer->maxpoll; + poll_update(peer, sys_poll); + sys_stratum = min(peer->stratum + 1, STRATUM_UNSPEC); + if (peer->stratum == STRATUM_REFCLOCK || + peer->stratum == STRATUM_UNSPEC) + sys_refid = peer->refid; + else + sys_refid = addr2refid(&peer->srcadr); + dtemp = sys_jitter + fabs(sys_offset) + peer->disp + clock_phi * + (current_time - peer->update); + sys_rootdisp = dtemp + peer->rootdisp; + sys_rootdelay = peer->delay + peer->rootdelay; + sys_reftime = peer->dst; #ifdef DEBUG if (debug) - printf("clock_update: at %ld assoc %d \n", current_time, - peer_associations); + printf( + "clock_update: at %lu sample %lu associd %d\n", + current_time, peer->epoch, peer->associd); #endif - oleap = sys_leap; - ostratum = sys_stratum; - switch (local_clock(sys_peer, sys_offset)) { + + /* + * Comes now the moment of truth. Crank the clock discipline and + * see what comes out. + */ + switch (local_clock(peer, sys_offset)) { /* * Clock exceeds panic threshold. Life as we know it ends. */ case -1: - report_event(EVNT_SYSFAULT, NULL); +#ifdef HAVE_LIBSCF_H + /* + * For Solaris enter the maintenance mode. + */ + if ((fmri = getenv("SMF_FMRI")) != NULL) { + if (smf_maintain_instance(fmri, 0) < 0) { + printf("smf_maintain_instance: %s\n", + scf_strerror(scf_error())); + exit(1); + } + /* + * Sleep until SMF kills us. + */ + for (;;) + pause(); + } +#endif /* HAVE_LIBSCF_H */ exit (-1); /* not reached */ @@ -1297,62 +1700,67 @@ clear_all(); sys_leap = LEAP_NOTINSYNC; sys_stratum = STRATUM_UNSPEC; - sys_peer = NULL; - sys_rootdelay = 0; - sys_rootdispersion = 0; memcpy(&sys_refid, "STEP", 4); - report_event(EVNT_CLOCKRESET, NULL); + sys_rootdelay = 0; + sys_rootdisp = 0; + L_CLR(&sys_reftime); + sys_jitter = LOGTOD(sys_precision); + leapsec = 0; break; /* - * Clock was slewed. Update the system stratum, leap bits, root - * delay, root dispersion, reference ID and reference time. If - * the leap changes, we gotta reroll the keys. Except for - * reference clocks, the minimum dispersion increment is not - * less than sys_mindisp. + * Clock was slewed. Handle the leapsecond stuff. */ case 1: - sys_leap = leap_next; - sys_stratum = min(sys_peer->stratum + 1, - STRATUM_UNSPEC); - sys_reftime = sys_peer->rec; /* - * In orphan mode the stratum defaults to the orphan - * stratum. The root delay is set to a random value - * generated at startup. The root dispersion is set from - * the peer dispersion; the peer root dispersion is - * ignored. - */ - dtemp = sys_peer->disp + clock_phi * (current_time - - sys_peer->update) + sys_jitter + - fabs(sys_peer->offset); -#ifdef REFCLOCK - if (!(sys_peer->flags & FLAG_REFCLOCK) && dtemp < - sys_mindisp) - dtemp = sys_mindisp; -#else - if (dtemp < sys_mindisp) - dtemp = sys_mindisp; -#endif /* REFCLOCK */ - if (sys_stratum >= sys_orphan) { - sys_stratum = sys_orphan; - sys_rootdelay = sys_peer->delay; - sys_rootdispersion = dtemp; - } else { - sys_rootdelay = sys_peer->delay + - sys_peer->rootdelay; - sys_rootdispersion = dtemp + - sys_peer->rootdispersion; - } - if (oleap == LEAP_NOTINSYNC) { - report_event(EVNT_SYNCCHG, NULL); -#ifdef OPENSSL - expire_all(); - crypto_update(); + * If this is the first time the clock is set, reset the + * leap bits. If crypto, the timer will goose the setup + * process. + */ + if (sys_leap == LEAP_NOTINSYNC) { + sys_leap = LEAP_NOWARNING; +#ifdef OPENSSL + if (crypto_flags) + crypto_update(); #endif /* OPENSSL */ } + + /* + * If the leapseconds values are from file or network + * and the leap is in the future, schedule a leap at the + * given epoch. Otherwise, if the number of survivor + * leap bits is greater than half the number of + * survivors, schedule a leap for the end of the current + * month. + */ + get_systime(&now); + if (leap_sec > 0) { + if (leap_sec > now.l_ui) { + sys_tai = leap_tai - 1; + if (leapsec == 0) + report_event(EVNT_ARMED, NULL, + NULL); + leapsec = leap_sec - now.l_ui; + } else { + sys_tai = leap_tai; + } + break; + + } else if (leap_vote > sys_survivors / 2) { + leap_peers = now.l_ui + leap_month(now.l_ui); + if (leap_peers > now.l_ui) { + if (leapsec == 0) + report_event(PEVNT_ARMED, peer, + NULL); + leapsec = leap_peers - now.l_ui; + } + } else if (leapsec > 0) { + report_event(EVNT_DISARMED, NULL, NULL); + leapsec = 0; + } break; + /* * Popcorn spike or step threshold exceeded. Pretend it never * happened. @@ -1360,8 +1768,6 @@ default: break; } - if (ostratum != sys_stratum) - report_event(EVNT_PEERSTCHG, NULL); } @@ -1370,115 +1776,144 @@ */ void poll_update( - struct peer *peer, + struct peer *peer, /* peer structure pointer */ int mpoll ) { - int hpoll; + int hpoll, minpkt; + u_long next, utemp; /* * This routine figures out when the next poll should be sent. - * That turns out to be wickedly complicated. The big problem is - * that sometimes the time for the next poll is in the past. - * Watch out for races here between the receive process and the - * poll process. The key assertion is that, if nextdate equals - * current_time, the call is from the poll process; otherwise, - * it is from the receive process. + * That turns out to be wickedly complicated. One problem is + * that sometimes the time for the next poll is in the past when + * the poll interval is reduced. We watch out for races here + * between the receive process and the poll process. * * First, bracket the poll interval according to the type of * association and options. If a fixed interval is configured, * use minpoll. This primarily is for reference clocks, but - * works for any association. + * works for any association. Otherwise, clamp the poll interval + * between minpoll and maxpoll. */ - if (peer->flags & FLAG_FIXPOLL) { + if (peer->cast_flags & MDF_BCLNT) hpoll = peer->minpoll; - - /* - * The ordinary case; clamp the poll interval between minpoll - * and maxpoll. - */ - } else { + else hpoll = max(min(peer->maxpoll, mpoll), peer->minpoll); - } + #ifdef OPENSSL /* - * Bit of crass arrogance at this point. If the poll interval - * has changed and we have a keylist, the lifetimes in the - * keylist are probably bogus. In this case purge the keylist - * and regenerate it later. + * If during the crypto protocol the poll interval has changed, + * the lifetimes in the key list are probably bogus. Purge the + * the key list and regenerate it later. */ - if (hpoll != peer->hpoll) + if ((peer->flags & FLAG_SKEY) && hpoll != peer->hpoll) key_expire(peer); #endif /* OPENSSL */ peer->hpoll = hpoll; /* - * Now we figure out if there is an override. If during the - * crypto protocol and a message is pending, make it wait not - * more than two seconds. - */ -#ifdef OPENSSL - if (peer->cmmd != NULL && (sys_leap != LEAP_NOTINSYNC || - peer->crypto)) { - peer->nextdate = current_time + RESP_DELAY; - - /* - * If we get called from the receive routine while a burst is - * pending, just slink away. If from the poll routine and a - * reference clock or a pending crypto response, delay for one - * second. If this is the first sent in a burst, wait for the - * modem to come up. For others in the burst, delay two seconds. - */ - } else if (peer->burst > 0) { -#else /* OPENSSL */ + * There are three variables important for poll scheduling, the + * current time (current_time), next scheduled time (nextdate) + * and the earliest time (utemp). The earliest time is 2 s + * seconds, but could be more due to rate management. When + * sending in a burst, use the earliest time. When not in a + * burst but with a reply pending, send at the earliest time + * unless the next scheduled time has not advanced. This can + * only happen if multiple replies are peinding in the same + * response interval. Otherwise, send at the later of the next + * scheduled time and the earliest time. + * + * Now we figure out if there is an override. If a burst is in + * progress and we get called from the receive process, just + * slink away. If called from the poll process, delay 1 s for a + * reference clock, otherwise 2 s. + */ + minpkt = 1 << ntp_minpkt; + utemp = current_time + max(peer->throttle - (NTP_SHIFT - 1) * + (1 << peer->minpoll), minpkt); if (peer->burst > 0) { -#endif /* OPENSSL */ - if (peer->nextdate != current_time) + if (peer->nextdate > current_time) return; #ifdef REFCLOCK else if (peer->flags & FLAG_REFCLOCK) - peer->nextdate += RESP_DELAY; + peer->nextdate = current_time + RESP_DELAY; #endif /* REFCLOCK */ - else if (peer->flags & (FLAG_IBURST | FLAG_BURST) && - peer->burst == NTP_BURST) - peer->nextdate += sys_calldelay; else - peer->nextdate += BURST_DELAY; + peer->nextdate = utemp; + +#ifdef OPENSSL /* - * The ordinary case; use the minimum of the host and peer - * intervals, but not less than minpoll. In other words, - * oversampling is okay but understampling is evil. + * If a burst is not in progress and a crypto response message + * is pending, delay 2 s, but only if this is a new interval. */ - } else { - peer->nextdate = peer->outdate + - RANDPOLL(max(min(peer->ppoll, hpoll), - peer->minpoll)); - } + } else if (peer->cmmd != NULL) { + if (peer->nextdate > current_time) { + if (peer->nextdate + minpkt != utemp) + peer->nextdate = utemp; + } else { + peer->nextdate = utemp; + } +#endif /* OPENSSL */ /* - * If the time for the next poll has already happened, bring it - * up to the next second after this one. This way the only way - * to get nexdate == current time is from the poll routine. + * The ordinary case. If a retry, use minpoll; if unreachable, + * use host poll; otherwise, use the minimum of host and peer + * polls; In other words, oversampling is okay but + * understampling is evil. Use the maximum of this value and the + * headway. If the average headway is greater than the headway + * threshold, increase the headway by the minimum interval. */ - if (peer->nextdate <= current_time) - peer->nextdate = current_time + 1; + } else { + if (peer->retry > 0) + hpoll = peer->minpoll; + else if (!(peer->reach)) + hpoll = peer->hpoll; + else + hpoll = min(peer->ppoll, peer->hpoll); +#ifdef REFCLOCK + if (peer->flags & FLAG_REFCLOCK) + next = 1 << hpoll; + else + next = ((0x1000UL | (ntp_random() & 0x0ff)) << + hpoll) >> 12; +#else /* REFCLOCK */ + next = ((0x1000UL | (ntp_random() & 0x0ff)) << hpoll) >> + 12; +#endif /* REFCLOCK */ + next += peer->outdate; + if (next > utemp) + peer->nextdate = next; + else + peer->nextdate = utemp; + hpoll = peer->throttle - (1 << peer->minpoll); + if (hpoll > 0) + peer->nextdate += minpkt; + } #ifdef DEBUG if (debug > 1) - printf("poll_update: at %lu %s flags %04x poll %d burst %d last %lu next %lu\n", - current_time, ntoa(&peer->srcadr), peer->flags, - peer->hpoll, peer->burst, peer->outdate, - peer->nextdate); + printf("poll_update: at %lu %s poll %d burst %d retry %d head %d early %lu next %lu\n", + current_time, ntoa(&peer->srcadr), peer->hpoll, + peer->burst, peer->retry, peer->throttle, + utemp - current_time, peer->nextdate - + current_time); #endif } + /* - * peer_crypto_clear - discard crypto information + * peer_clear - clear peer filter registers. See Section 3.4.8 of the + * spec. */ void -peer_crypto_clear( - struct peer *peer - ) +peer_clear( + struct peer *peer, /* peer structure */ + char *ident /* tally lights */ + ) { + int i; + +#ifdef OPENSSL /* * If cryptographic credentials have been acquired, toss them to * Valhalla. Note that autokeys are ephemeral, in that they are @@ -1488,84 +1923,36 @@ * purged, too. This makes it much harder to sneak in some * unauthenticated data in the clock filter. */ - DPRINTF(1, ("peer_crypto_clear: at %ld next %ld assoc ID %d\n", - current_time, peer->nextdate, peer->associd)); - -#ifdef OPENSSL - peer->assoc = 0; - peer->crypto = 0; - - if (peer->pkey != NULL) - EVP_PKEY_free(peer->pkey); - peer->pkey = NULL; - - peer->digest = NULL; /* XXX MEMLEAK? check whether this needs to be freed in any way - never was freed */ - - if (peer->subject != NULL) - free(peer->subject); - peer->subject = NULL; - - if (peer->issuer != NULL) - free(peer->issuer); - peer->issuer = NULL; - - peer->pkeyid = 0; - - peer->pcookie = 0; - - if (peer->ident_pkey != NULL) - EVP_PKEY_free(peer->ident_pkey); - peer->ident_pkey = NULL; - - memset(&peer->fstamp, 0, sizeof(peer->fstamp)); - + key_expire(peer); if (peer->iffval != NULL) BN_free(peer->iffval); - peer->iffval = NULL; - - if (peer->grpkey != NULL) - BN_free(peer->grpkey); - peer->grpkey = NULL; - value_free(&peer->cookval); value_free(&peer->recval); - - if (peer->cmmd != NULL) { - free(peer->cmmd); - peer->cmmd = NULL; - } - - key_expire(peer); - value_free(&peer->encrypt); + value_free(&peer->sndval); + if (peer->cmmd != NULL) + free(peer->cmmd); + if (peer->subject != NULL) + free(peer->subject); + if (peer->issuer != NULL) + free(peer->issuer); #endif /* OPENSSL */ -} - -/* - * peer_clear - clear peer filter registers. See Section 3.4.8 of the spec. - */ -void -peer_clear( - struct peer *peer, /* peer structure */ - char *ident /* tally lights */ - ) -{ - int i; - - peer_crypto_clear(peer); - - if (peer == sys_peer) - sys_peer = NULL; /* - * Wipe the association clean and initialize the nonzero values. + * Clear all values, including the optional crypto values above. */ memset(CLEAR_TO_ZERO(peer), 0, LEN_CLEAR_TO_ZERO); - peer->estbdelay = sys_bdelay; peer->ppoll = peer->maxpoll; peer->hpoll = peer->minpoll; peer->disp = MAXDISPERSE; + peer->flash = peer_unfit(peer); peer->jitter = LOGTOD(sys_precision); + + /* + * If interleave mode, initialize the alternate origin switch. + */ + if (peer->flags & FLAG_XLEAVE) + peer->flip = 1; for (i = 0; i < NTP_SHIFT; i++) { peer->filter_order[i] = i; peer->filter_disp[i] = MAXDISPERSE; @@ -1584,21 +1971,28 @@ /* * During initialization use the association count to spread out - * the polls at one-second intervals. Othersie, randomize over + * the polls at one-second intervals. Otherwise, randomize over * the minimum poll interval in order to avoid broadcast * implosion. */ peer->nextdate = peer->update = peer->outdate = current_time; - if (initializing) + if (initializing) { peer->nextdate += peer_associations; - else if (peer->hmode == MODE_PASSIVE) - peer->nextdate += RESP_DELAY; - else - peer->nextdate += (ntp_random() & ((1 << NTP_MINDPOLL) - - 1)); - - DPRINTF(1, ("peer_clear: at %ld next %ld assoc ID %d refid %s\n", - current_time, peer->nextdate, peer->associd, ident)); + } else if (peer->hmode == MODE_PASSIVE) { + peer->nextdate += 1 << ntp_minpkt; + } else { + peer->nextdate += ntp_random() % peer_associations; + } +#ifdef OPENSSL + peer->refresh = current_time + (1 << NTP_REFRESH); +#endif /* OPENSSL */ +#ifdef DEBUG + if (debug) + printf( + "peer_clear: at %ld next %ld associd %d refid %s\n", + current_time, peer->nextdate, peer->associd, + ident); +#endif } @@ -1618,19 +2012,20 @@ int ord[NTP_SHIFT]; /* index vector */ int i, j, k, m; double dtemp, etemp; + char tbuf[80]; /* - * Shift the new sample into the register and discard the oldest - * one. The new offset and delay come directly from the - * timestamp calculations. The dispersion grows from the last - * outbound packet or reference clock update to the present time - * and increased by the sum of the peer precision and the system - * precision. The delay can sometimes swing negative due to - * frequency skew, so it is clamped non-negative. + * A sample consists of the offset, delay, dispersion and epoch + * of arrival. The offset and delay are determined by the on- + * wire protcol. The dispersion grows from the last outbound + * packet to the arrival of this one increased by the sum of the + * peer precision and the system precision as required by the + * error budget. First, shift the new arrival into the shift + * register discarding the oldest one. */ j = peer->filter_nextpt; peer->filter_offset[j] = sample_offset; - peer->filter_delay[j] = max(0, sample_delay); + peer->filter_delay[j] = sample_delay; peer->filter_disp[j] = sample_disp; peer->filter_epoch[j] = current_time; j = (j + 1) % NTP_SHIFT; @@ -1638,40 +2033,42 @@ /* * Update dispersions since the last update and at the same - * time initialize the distance and index lists. The distance - * list uses a compound metric. If the sample is valid and - * younger than the minimum Allan intercept, use delay; - * otherwise, use biased dispersion. + * time initialize the distance and index lists. Since samples + * become increasingly uncorrelated beyond the Allan intercept, + * only under exceptional cases will an older sample be used. + * Therefore, the distance list uses a compound metric. If the + * dispersion is greater than the maximum dispersion, clamp the + * distance at that value. If the time since the last update is + * less than the Allan intercept use the delay; otherwise, use + * the sum of the delay and dispersion. */ dtemp = clock_phi * (current_time - peer->update); peer->update = current_time; for (i = NTP_SHIFT - 1; i >= 0; i--) { if (i != 0) peer->filter_disp[j] += dtemp; - if (peer->filter_disp[j] >= MAXDISPERSE) + if (peer->filter_disp[j] >= MAXDISPERSE) { peer->filter_disp[j] = MAXDISPERSE; - if (peer->filter_disp[j] >= MAXDISPERSE) dst[i] = MAXDISPERSE; - else if (peer->update - peer->filter_epoch[j] > - allan_xpt) - dst[i] = sys_maxdist + peer->filter_disp[j]; - else + } else if (peer->update - peer->filter_epoch[j] > + ULOGTOD(allan_xpt)) { + dst[i] = peer->filter_delay[j] + + peer->filter_disp[j]; + } else { dst[i] = peer->filter_delay[j]; + } ord[i] = j; - j++; j %= NTP_SHIFT; + j = (j + 1) % NTP_SHIFT; } /* - * If the clock discipline has stabilized, sort the samples in - * both lists by distance. Note, we do not displace a higher - * distance sample by a lower distance one unless lower by at - * least the precision. + * If the clock discipline has stabilized, sort the samples by + * distance. */ - if (state == 4) { + if (sys_leap != LEAP_NOTINSYNC) { for (i = 1; i < NTP_SHIFT; i++) { for (j = 0; j < i; j++) { - if (dst[j] > dst[i] + - LOGTOD(sys_precision)) { + if (dst[j] > dst[i]) { k = ord[j]; ord[j] = ord[i]; ord[i] = k; @@ -1685,9 +2082,12 @@ /* * Copy the index list to the association structure so ntpq - * can see it later. Prune the distance list to samples less - * than max distance, but keep at least two valid samples for - * jitter calculation. + * can see it later. Prune the distance list to leave only + * samples less than the maximum dispersion, which disfavors + * uncorrelated samples older than the Allan intercept. To + * further improve the jitter estimate, of the remainder leave + * only samples less than the maximum distance, but keep at + * least two samples for jitter calculation. */ m = 0; for (i = 0; i < NTP_SHIFT; i++) { @@ -1702,9 +2102,7 @@ * Compute the dispersion and jitter. The dispersion is weighted * exponentially by NTP_FWEIGHT (0.5) so it is normalized close * to 1.0. The jitter is the RMS differences relative to the - * lowest delay sample. If no acceptable samples remain in the - * shift register, quietly tiptoe home leaving only the - * dispersion. + * lowest delay sample. */ peer->disp = peer->jitter = 0; k = ord[0]; @@ -1734,47 +2132,51 @@ peer->jitter = max(SQRT(peer->jitter), LOGTOD(sys_precision)); /* - * A new sample is useful only if it is younger than the last - * one used. Note the order is FIFO if the clock discipline has - * not stabilized. + * If the the new sample and the current sample are both valid + * and the difference between their offsets exceeds CLOCK_SGATE + * (3) times the jitter and the interval between them is less + * than twice the host poll interval, consider the new sample + * a popcorn spike and ignore it. */ - if (peer->filter_epoch[k] <= peer->epoch) { -#ifdef DEBUG - if (debug) - printf("clock_filter: discard %lu\n", - peer->epoch - peer->filter_epoch[k]); -#endif + if (peer->disp < sys_maxdist && peer->filter_disp[k] < + sys_maxdist && etemp > CLOCK_SGATE * peer->jitter && + peer->filter_epoch[k] - peer->epoch < 2. * + ULOGTOD(peer->hpoll)) { + snprintf(tbuf, sizeof(tbuf), "%.6f s", etemp); + report_event(PEVNT_POPCORN, peer, tbuf); return; } /* - * If the difference between the last offset and the current one - * exceeds the jitter by CLOCK_SGATE and the interval since the - * last update is less than twice the system poll interval, - * consider the update a popcorn spike and ignore it. + * A new minimum sample is useful only if it is later than the + * last one used. In this design the maximum lifetime of any + * sample is not greater than eight times the poll interval, so + * the maximum interval between minimum samples is eight + * packets. */ - if (etemp > CLOCK_SGATE * peer->jitter && m > 1 && - peer->filter_epoch[k] - peer->epoch < 2. * - ULOGTOD(sys_poll)) { -#ifdef DEBUG - if (debug) - printf("clock_filter: popcorn %.6f %.6f\n", - etemp, dtemp); + if (peer->filter_epoch[k] <= peer->epoch) { +#if DEBUG + if (debug) + printf("clock_filter: old sample %lu\n", current_time - + peer->filter_epoch[k]); #endif return; } + peer->epoch = peer->filter_epoch[k]; /* * The mitigated sample statistics are saved for later - * processing. If not in a burst, tickle the select. + * processing. If not synchronized or not in a burst, tickle the + * clock select algorithm. */ - peer->epoch = peer->filter_epoch[k]; + record_peer_stats(&peer->srcadr, ctlpeerstatus(peer), + peer->offset, peer->delay, peer->disp, peer->jitter); #ifdef DEBUG if (debug) printf( - "clock_filter: n %d off %.6f del %.6f dsp %.6f jit %.6f, age %lu\n", + "clock_filter: n %d off %.6f del %.6f dsp %.6f jit %.6f\n", m, peer->offset, peer->delay, peer->disp, - peer->jitter, current_time - peer->epoch); + peer->jitter); #endif if (peer->burst == 0 || sys_leap == LEAP_NOTINSYNC) clock_select(); @@ -1784,10 +2186,11 @@ /* * clock_select - find the pick-of-the-litter clock * - * LOCKCLOCK: If the local clock is the prefer peer, it will always be - * enabled, even if declared falseticker, (2) only the prefer peer can - * be selected as the system peer, (3) if the external source is down, - * the system leap bits are set to 11 and the stratum set to infinity. + * LOCKCLOCK: (1) If the local clock is the prefer peer, it will always + * be enabled, even if declared falseticker, (2) only the prefer peer + * caN Be selected as the system peer, (3) if the external source is + * down, the system leap bits are set to 11 and the stratum set to + * infinity. */ void clock_select(void) @@ -1795,15 +2198,21 @@ struct peer *peer; int i, j, k, n; int nlist, nl3; - int allow, osurv; double d, e, f, g; double high, low; + double seljitter; double synch[NTP_MAXASSOC], error[NTP_MAXASSOC]; - struct peer *osys_peer; + double orphdist = 1e10; + struct peer *osys_peer = NULL; + struct peer *sys_prefer = NULL; /* prefer peer */ + struct peer *typesystem = NULL; + struct peer *typeorphan = NULL; +#ifdef REFCLOCK struct peer *typeacts = NULL; struct peer *typelocal = NULL; - struct peer *typesystem = NULL; + struct peer *typepps = NULL; +#endif /* REFCLOCK */ static int list_alloc = 0; static struct endpoint *endpoint = NULL; @@ -1818,9 +2227,6 @@ * enough to handle all associations. */ osys_peer = sys_peer; - sys_peer = NULL; - sys_pps = NULL; - sys_prefer = NULL; osurv = sys_survivors; sys_survivors = 0; #ifdef LOCKCLOCK @@ -1873,30 +2279,37 @@ continue; /* - * Don't allow the local clock or modem drivers - * in the kitchen at this point, unless the - * prefer peer. Do that later, but only if - * nobody else is around. These guys are all - * configured, so we never throw them away. - */ -#ifdef REFCLOCK - if (peer->refclktype == REFCLK_LOCALCLOCK -#if defined(VMS) && defined(VMS_LOCALUNIT) - /* wjm: VMS_LOCALUNIT taken seriously */ - && REFCLOCKUNIT(&peer->srcadr) != - VMS_LOCALUNIT -#endif /* VMS && VMS_LOCALUNIT */ - ) { - typelocal = peer; -#ifndef LOCKCLOCK - if (!(peer->flags & FLAG_PREFER)) - continue; /* no local clock */ -#endif /* LOCKCLOCK */ + * If this is an orphan, choose the one with + * the lowest metric defined as the IPv4 address + * or the first 64 bits of the hashed IPv6 address. + */ + if (peer->stratum == sys_orphan) { + double ftemp; + + ftemp = addr2refid(&peer->srcadr); + if (ftemp < orphdist) { + typeorphan = peer; + orphdist = ftemp; + } + continue; } - if (peer->sstclktype == CTL_SST_TS_TELEPHONE) { - typeacts = peer; - if (!(peer->flags & FLAG_PREFER)) - continue; /* no acts */ +#ifdef REFCLOCK + /* + * The following are special cases. We deal + * with them later. + */ + switch (peer->refclktype) { + case REFCLK_LOCALCLOCK: + if (typelocal == NULL && + !(peer->flags & FLAG_PREFER)) + typelocal = peer; + continue; + + case REFCLK_ACTS: + if (typeacts == NULL && + !(peer->flags & FLAG_PREFER)) + typeacts = peer; + continue; } #endif /* REFCLOCK */ @@ -2031,28 +2444,34 @@ * NTP_MAXASSOC of them. Scan the list to find falsetickers, who * leave the island immediately. The TRUE peer is always a * truechimer. We must leave at least one peer to collect the - * million bucks. If in orphan mode, rascals found with lower - * stratum are guaranteed a seat on the bus. + * million bucks. */ j = 0; for (i = 0; i < nlist; i++) { peer = peer_list[i]; if (nlist > 1 && (peer->offset <= low || peer->offset >= - high) && !(peer->flags & FLAG_TRUE) && - !(sys_stratum >= sys_orphan && peer->stratum < - sys_orphan)) + high) && !(peer->flags & FLAG_TRUE)) continue; - peer->status = CTL_PST_SEL_DISTSYSPEER; +#ifdef REFCLOCK + /* + * Elegible PPS peers must survive the intersection + * algorithm. Use the first one found, but don't + * include any of them in the cluster population. + */ + if (peer->flags & FLAG_PPS) { + if (typepps == NULL) + typepps = peer; + continue; + } +#endif /* REFCLOCK */ /* - * The order metric is formed from the stratum times - * max distance (1.) plus the root distance. It strongly - * favors the lowest stratum, but a higher stratum peer - * can capture the clock if the low stratum dominant - * hasn't been heard for awhile. + * The metric is the scaled root distance at the next + * poll interval plus the peer stratum. */ - d = root_distance(peer) + peer->stratum * sys_maxdist; + d = (root_distance(peer) + clock_phi * (peer->nextdate - + current_time)) / sys_maxdist + peer->stratum; if (j >= NTP_MAXASSOC) { if (d >= synch[j - 1]) continue; @@ -2075,44 +2494,40 @@ nlist = j; /* - * If no survivors remain at this point, check if the local - * clock or modem drivers have been found. If so, nominate one - * of them as the only survivor. Otherwise, give up and leave - * the island to the rats. + * If no survivors remain at this point, check if the modem + * driver, local driver or orphan parent in that order. If so, + * nominate the first one found as the only survivor. + * Otherwise, give up and leave the island to the rats. */ if (nlist == 0) { - if (typeacts != 0) { - typeacts->status = CTL_PST_SEL_DISTSYSPEER; + error[0] = 0; + synch[0] = 0; +#ifdef REFCLOCK + if (typeacts != NULL) { peer_list[0] = typeacts; nlist = 1; - } else if (typelocal != 0) { - typelocal->status = CTL_PST_SEL_DISTSYSPEER; + } else if (typelocal != NULL) { peer_list[0] = typelocal; nlist = 1; - } else { - if (osys_peer != NULL) { - NLOG(NLOG_SYNCSTATUS) - msyslog(LOG_INFO, - "no servers reachable"); - report_event(EVNT_PEERSTCHG, NULL); - } + } +#endif /* REFCLOCK */ + if (typeorphan != NULL) { + peer_list[0] = typeorphan; + nlist = 1; } } /* - * We can only trust the survivors if the number of candidates - * sys_minsane is at least the number required to detect and - * cast out one falsticker. For the Byzantine agreement - * algorithm used here, that number is 4; however, the default - * sys_minsane is 1 to speed initial synchronization. Careful - * operators will tinker a higher value and use at least that - * number of synchronization sources. + * Mark the candidates at this point as truechimers. */ - if (nlist < sys_minsane) - return; - - for (i = 0; i < nlist; i++) + for (i = 0; i < nlist; i++) { peer_list[i]->status = CTL_PST_SEL_SELCAND; +#ifdef DEBUG + if (debug > 1) + printf("select: survivor %s %f\n", + stoa(&peer_list[i]->srcadr), synch[i]); +#endif + } /* * Now, vote outlyers off the island by select jitter weighted @@ -2122,6 +2537,7 @@ * discard a TRUE or PREFER peer, who of course has the * immunity idol. */ + seljitter = 0; while (1) { d = 1e9; e = -1e9; @@ -2144,17 +2560,25 @@ } } f = max(f, LOGTOD(sys_precision)); - if (nlist <= sys_minclock || f <= d || - peer_list[k]->flags & (FLAG_TRUE | FLAG_PREFER)) + if (nlist <= sys_minsane || nlist <= sys_minclock) { + break; + + } else if (f <= d || peer_list[k]->flags & + (FLAG_TRUE | FLAG_PREFER)) { + seljitter = f; break; + } #ifdef DEBUG if (debug > 2) printf( - "select: drop %s select %.6f jitter %.6f\n", + "select: drop %s seljit %.6f jit %.6f\n", ntoa(&peer_list[k]->srcadr), g, d); #endif + if (nlist > sys_maxclock) + peer_list[k]->status = CTL_PST_SEL_EXCESS; for (j = k + 1; j < nlist; j++) { peer_list[j - 1] = peer_list[j]; + synch[j - 1] = synch[j]; error[j - 1] = error[j]; } nlist--; @@ -2162,156 +2586,140 @@ /* * What remains is a list usually not greater than sys_minclock - * peers. We want only a peer at the lowest stratum to become - * the system peer, although all survivors are eligible for the - * combining algorithm. Consider each peer in turn and OR the - * leap bits on the assumption that, if some of them honk - * nonzero bits, they must know what they are doing. Check for - * prefer and pps peers at any stratum. Note that the head of - * the list is at the lowest stratum and that unsynchronized - * peers cannot survive this far. + * peers. Note that the head of the list is the system peer at + * the lowest stratum and that unsynchronized peers cannot + * survive this far. + * + * While at it, count the number of leap warning bits found. + * This will be used later to vote the system leap warning bit. + * If a leap warning bit is found on a reference clock, the vote + * is always won. */ - leap_next = 0; + leap_vote = 0; for (i = 0; i < nlist; i++) { peer = peer_list[i]; - sys_survivors++; - leap_next |= peer->leap; + peer->unreach = 0; peer->status = CTL_PST_SEL_SYNCCAND; + sys_survivors++; + if (peer->leap == LEAP_ADDSECOND) { + if (peer->flags & FLAG_REFCLOCK) + leap_vote = nlist; + else + leap_vote++; + } if (peer->flags & FLAG_PREFER) sys_prefer = peer; - if (peer == osys_peer) - typesystem = peer; -#ifdef REFCLOCK - if (peer->refclktype == REFCLK_ATOM_PPS) - sys_pps = peer; -#endif /* REFCLOCK */ -#if DEBUG - if (debug > 1) - printf("cluster: survivor %s metric %.6f\n", - ntoa(&peer_list[i]->srcadr), synch[i]); -#endif } /* - * Anticlockhop provision. Keep the current system peer if it is - * a survivor but not first in the list. But do that only HOPPER - * times. + * Unless there are at least sys_misane survivors, leave the + * building dark. Otherwise, do a clockhop dance. Ordinarily, + * use the first survivor on the survivor list. However, if the + * last selection is not first on the list, use it as long as + * it doesn't get too old or too ugly. */ - if (osys_peer == NULL || typesystem == NULL || typesystem == - peer_list[0] || sys_hopper > sys_maxhop) { + if (nlist > 0 && nlist >= sys_minsane) { + double x; + typesystem = peer_list[0]; - sys_hopper = 0; - } else { - peer->selbroken++; + if (osys_peer == NULL || osys_peer == typesystem) { + sys_clockhop = 0; + } else if ((x = fabs(typesystem->offset - + osys_peer->offset)) < sys_mindisp) { + if (sys_clockhop == 0) + sys_clockhop = sys_mindisp; + else + sys_clockhop *= .5; +#ifdef DEBUG + if (debug) + printf("select: clockhop %d %.6f %.6f\n", + j, x, sys_clockhop); +#endif + if (fabs(x) < sys_clockhop) + typesystem = osys_peer; + else + sys_clockhop = 0; + } else { + sys_clockhop = 0; + } } /* - * Mitigation rules of the game. There are several types of - * peers that can be selected here: (1) orphan, (2) prefer peer - * (flag FLAG_PREFER) (3) pps peers (type REFCLK_ATOM_PPS), (4) - * the existing system peer, if any, and (5) the head of the - * survivor list. - */ - if (typesystem->stratum >= sys_orphan) { - - /* - * If in orphan mode, choose the system peer. If the - * lowest distance, we are the orphan parent and the - * offset is zero. - */ - sys_peer = typesystem; - sys_peer->status = CTL_PST_SEL_SYSPEER; - if (sys_orphandelay < sys_peer->rootdelay) { - sys_offset = 0; - sys_refid = htonl(LOOPBACKADR); + * Mitigation rules of the game. We have the pick of the + * litter in typesystem if any survivors are left. If + * there is a prefer peer, use its offset and jitter. + * Otherwise, use the combined offset and jitter of all kitters. + */ + if (typesystem != NULL) { + if (sys_prefer == NULL) { + typesystem->status = CTL_PST_SEL_SYSPEER; + clock_combine(peer_list, sys_survivors); + sys_jitter = SQRT(SQUARE(typesystem->jitter) + + SQUARE(sys_jitter) + SQUARE(seljitter)); } else { - sys_offset = sys_peer->offset; - sys_refid = addr2refid(&sys_peer->srcadr); + typesystem = sys_prefer; + sys_clockhop = 0; + typesystem->status = CTL_PST_SEL_SYSPEER; + sys_offset = typesystem->offset; + sys_jitter = typesystem->jitter; } - sys_jitter = LOGTOD(sys_precision); #ifdef DEBUG - if (debug > 1) - printf("select: orphan offset %.6f\n", - sys_offset); -#endif - } else if (sys_prefer) { - - /* - * If a pps peer is present, choose it; otherwise, - * choose the prefer peer. - */ - if (sys_pps) { - sys_peer = sys_pps; - sys_peer->status = CTL_PST_SEL_PPS; - sys_offset = sys_peer->offset; - if (!pps_control) - NLOG(NLOG_SYSEVENT) - msyslog(LOG_INFO, - "pps sync enabled"); - pps_control = current_time; -#ifdef DEBUG - if (debug > 1) - printf("select: pps offset %.6f\n", - sys_offset); -#endif - } else { - sys_peer = sys_prefer; - sys_peer->status = CTL_PST_SEL_SYSPEER; - sys_offset = sys_peer->offset; -#ifdef DEBUG - if (debug > 1) - printf("select: prefer offset %.6f\n", - sys_offset); + if (debug) + printf("select: combine offset %.9f jitter %.9f\n", + sys_offset, sys_jitter); #endif - } - if (sys_peer->stratum == STRATUM_REFCLOCK || - sys_peer->stratum == STRATUM_UNSPEC) - sys_refid = sys_peer->refid; - else - sys_refid = addr2refid(&sys_peer->srcadr); - sys_jitter = sys_peer->jitter; - } else { - - /* - * Otherwise, choose the anticlockhopper. - */ - sys_peer = typesystem; - sys_peer->status = CTL_PST_SEL_SYSPEER; - clock_combine(peer_list, nlist); - if (sys_peer->stratum == STRATUM_REFCLOCK || - sys_peer->stratum == STRATUM_UNSPEC) - sys_refid = sys_peer->refid; - else - sys_refid = addr2refid(&sys_peer->srcadr); - sys_jitter = SQRT(SQUARE(sys_peer->jitter) + - SQUARE(sys_jitter)); + } +#ifdef REFCLOCK + /* + * If a PPS driver is lit and the combined offset is less than + * 0.4 s, select the driver as the PPS peer and use its offset + * and jitter. However, if this is the atom driver, use it only + * if there is a prefer peer or there are no survivors and none + * are required. + */ + if (typepps != NULL && fabs(sys_offset) < 0.4 && + (typepps->refclktype != REFCLK_ATOM_PPS || + (typepps->refclktype == REFCLK_ATOM_PPS && (sys_prefer != + NULL || (typesystem == NULL && sys_minsane == 0))))) { + typesystem = typepps; + sys_clockhop = 0; + typesystem->status = CTL_PST_SEL_PPS; + sys_offset = typesystem->offset; + sys_jitter = typesystem->jitter; #ifdef DEBUG - if (debug > 1) - printf("select: combine offset %.6f\n", - sys_offset); + if (debug) + printf("select: pps offset %.9f jitter %.9f\n", + sys_offset, sys_jitter); #endif } +#endif /* REFCLOCK */ /* - * We have found the alpha male. - */ - sys_peer->flags |= FLAG_SYSPEER; - if (osys_peer != sys_peer) { - char *src; + * If there are no survivors at this point, there is no + * system peer. If so and this is an old update, keep the + * current statistics, but do not update the clock. + */ + if (typesystem == NULL) { + if (osys_peer != NULL) + report_event(EVNT_NOPEER, NULL, NULL); + sys_peer = NULL; + return; + } - report_event(EVNT_PEERSTCHG, NULL); + /* + * Do not use old data, as this may mess up the clock discipline + * stability. + */ + if (typesystem->epoch <= sys_epoch) + return; -#ifdef REFCLOCK - if (sys_peer->flags & FLAG_REFCLOCK) - src = refnumtoa(&sys_peer->srcadr); - else -#endif /* REFCLOCK */ - src = ntoa(&sys_peer->srcadr); - NLOG(NLOG_SYNCSTATUS) - msyslog(LOG_INFO, "synchronized to %s, stratum %d", - src, sys_peer->stratum); - } - clock_update(); + /* + * We have found the alpha male. Wind the clock. + */ + if (osys_peer != typesystem) + report_event(PEVNT_NEWPEER, typesystem, NULL); + typesystem->flags |= FLAG_SYSPEER; + clock_update(typesystem); } @@ -2320,8 +2728,8 @@ */ static void clock_combine( - struct peer **peers, /* survivor list */ - int npeers /* number of survivors */ + struct peer **peers, /* survivor list */ + int npeers /* number of survivors */ ) { int i; @@ -2338,32 +2746,33 @@ sys_jitter = SQRT(w / y); } + /* * root_distance - compute synchronization distance from peer to root */ static double root_distance( - struct peer *peer + struct peer *peer /* peer structure pointer */ ) { - double dist; + double dtemp; /* * Careful squeak here. The value returned must be greater than * the minimum root dispersion in order to avoid clockhop with - * highly precise reference clocks. In orphan mode lose the peer - * root delay, as that is used by the election algorithm. - */ - if (peer->stratum >= sys_orphan) - dist = 0; - else - dist = peer->rootdelay; - dist += max(sys_mindisp, dist + peer->delay) / 2 + - peer->rootdispersion + peer->disp + clock_phi * - (current_time - peer->update) + peer->jitter; - return (dist); + * highly precise reference clocks. Note that the root distance + * cannot exceed the sys_maxdist, as this is the cutoff by the + * selection algorithm. + */ + dtemp = (peer->delay + peer->rootdelay) / 2 + peer->disp + + peer->rootdisp + clock_phi * (current_time - peer->update) + + peer->jitter; + if (dtemp < sys_mindisp) + dtemp = sys_mindisp; + return (dtemp); } + /* * peer_xmit - send packet for persistent association. */ @@ -2375,64 +2784,22 @@ struct pkt xpkt; /* transmit packet */ int sendlen, authlen; keyid_t xkeyid = 0; /* transmit key ID */ - l_fp xmt_tx; + l_fp xmt_tx, xmt_ty; - if (!peer->dstadr) /* don't bother with peers without interface */ + if (!peer->dstadr) /* drop peers without interface */ return; - /* - * This is deliciously complicated. There are three cases. - * - * case leap stratum refid delay dispersion - * - * normal system system system system system - * orphan child 00 orphan system orphan system - * orphan parent 00 orphan loopbk 0 0 - */ - /* - * This is a normal packet. Use the system variables. - */ - if (sys_stratum < sys_orphan) { - xpkt.li_vn_mode = PKT_LI_VN_MODE(sys_leap, - peer->version, peer->hmode); - xpkt.stratum = STRATUM_TO_PKT(sys_stratum); - xpkt.refid = sys_refid; - xpkt.rootdelay = HTONS_FP(DTOFP(sys_rootdelay)); - xpkt.rootdispersion = - HTONS_FP(DTOUFP(sys_rootdispersion)); - - /* - * This is a orphan child packet. The host is synchronized to an - * orphan parent. Show leap synchronized, orphan stratum, system - * reference ID, orphan root delay and system root dispersion. - */ - } else if (sys_peer != NULL) { - xpkt.li_vn_mode = PKT_LI_VN_MODE(LEAP_NOWARNING, - peer->version, peer->hmode); - xpkt.stratum = STRATUM_TO_PKT(sys_orphan); - xpkt.refid = htonl(LOOPBACKADR); - xpkt.rootdelay = HTONS_FP(DTOFP(sys_orphandelay)); - xpkt.rootdispersion = - HTONS_FP(DTOUFP(sys_rootdispersion)); - - /* - * This is an orphan parent. Show leap synchronized, orphan - * stratum, loopack reference ID and zero root delay and root - * dispersion. - */ - } else { - xpkt.li_vn_mode = PKT_LI_VN_MODE(LEAP_NOWARNING, - peer->version, peer->hmode); - xpkt.stratum = STRATUM_TO_PKT(sys_orphan); - xpkt.refid = sys_refid; - xpkt.rootdelay = 0; - xpkt.rootdispersion = 0; - } + xpkt.li_vn_mode = PKT_LI_VN_MODE(sys_leap, peer->version, + peer->hmode); + xpkt.stratum = STRATUM_TO_PKT(sys_stratum); xpkt.ppoll = peer->hpoll; xpkt.precision = sys_precision; + xpkt.refid = sys_refid; + xpkt.rootdelay = HTONS_FP(DTOFP(sys_rootdelay)); + xpkt.rootdisp = HTONS_FP(DTOUFP(sys_rootdisp)); HTONL_FP(&sys_reftime, &xpkt.reftime); - HTONL_FP(&peer->org, &xpkt.org); - HTONL_FP(&peer->rec, &xpkt.rec); + HTONL_FP(&peer->rec, &xpkt.org); + HTONL_FP(&peer->dst, &xpkt.rec); /* * If the received packet contains a MAC, the transmitted packet @@ -2447,28 +2814,73 @@ * might not be usable. */ sendlen = LEN_PKT_NOMAC; - if (!(peer->flags & FLAG_AUTHENABLE)) { - get_systime(&peer->xmt); - HTONL_FP(&peer->xmt, &xpkt.xmt); +#ifdef OPENSSL + if (!(peer->flags & FLAG_SKEY) && peer->keyid == 0) { +#else + if (peer->keyid == 0) { +#endif /* OPENSSL */ + + /* + * Transmit a-priori timestamps + */ + get_systime(&xmt_tx); + if (peer->flip == 0) { /* basic mode */ + peer->aorg = xmt_tx; + HTONL_FP(&xmt_tx, &xpkt.xmt); + } else { /* interleaved modes */ + if (peer->hmode == MODE_BROADCAST) { /* bcst */ + HTONL_FP(&xmt_tx, &xpkt.xmt); + if (peer->flip > 0) + HTONL_FP(&peer->borg, + &xpkt.org); + else + HTONL_FP(&peer->aorg, + &xpkt.org); + } else { /* symmetric */ + if (peer->flip > 0) + HTONL_FP(&peer->borg, + &xpkt.xmt); + else + HTONL_FP(&peer->aorg, + &xpkt.xmt); + } + } + peer->t21_bytes = sendlen; sendpkt(&peer->srcadr, peer->dstadr, sys_ttl[peer->ttl], - &xpkt, sendlen); + &xpkt, sendlen); peer->sent++; + peer->throttle += (1 << peer->minpoll) - 2; + + /* + * Capture a-posteriori timestamps + */ + get_systime(&xmt_ty); + if (peer->flip != 0) { /* interleaved modes */ + if (peer->flip > 0) + peer->aorg = xmt_ty; + else + peer->borg = xmt_ty; + peer->flip = -peer->flip; + } + L_SUB(&xmt_ty, &xmt_tx); + LFPTOD(&xmt_ty, peer->xleave); #ifdef DEBUG if (debug) - printf("transmit: at %ld %s->%s mode %d\n", - current_time, peer->dstadr ? stoa(&peer->dstadr->sin) : "-", - stoa(&peer->srcadr), peer->hmode); + printf("transmit: at %ld %s->%s mode %d len %d\n", + current_time, peer->dstadr ? + stoa(&peer->dstadr->sin) : "-", + stoa(&peer->srcadr), peer->hmode, sendlen); #endif return; } /* - * The received packet contains a MAC, so the transmitted packet - * must be authenticated. If autokey is enabled, fuss with the - * various modes; otherwise, symmetric key cryptography is used. + * Authentication is enabled, so the transmitted packet must be + * authenticated. If autokey is enabled, fuss with the various + * modes; otherwise, symmetric key cryptography is used. */ #ifdef OPENSSL - if (crypto_flags && (peer->flags & FLAG_SKEY)) { + if (peer->flags & FLAG_SKEY) { struct exten *exten; /* extension field */ /* @@ -2484,7 +2896,7 @@ * messages have the same code as the request, but have * a response bit and possibly an error bit set. In this * implementation, a message may contain no more than - * one command and no more than one response. + * one command and one or more responses. * * Cryptographic session keys include both a public and * a private componet. Request and response messages @@ -2510,10 +2922,10 @@ * identifier to verify authenticity. * * If for some reason a key is no longer in the - * key cache, a birthday has happened and the - * pseudo-random sequence is probably broken. In - * that case, purge the keylist and regenerate - * it. + * key cache, a birthday has happened or the key + * has expired, so the pseudo-random sequence is + * broken. In that case, purge the keylist and + * regenerate it. */ if (peer->keynumber == 0) make_keylist(peer, peer->dstadr); @@ -2529,223 +2941,212 @@ exten = NULL; switch (peer->hmode) { - /* - * In broadcast server mode the autokey values are - * required by the broadcast clients. Push them when a - * new keylist is generated; otherwise, push the - * association message so the client can request them at - * other times. - */ + /* + * In broadcast server mode the autokey values are + * required by the broadcast clients. Push them when a + * new keylist is generated; otherwise, push the + * association message so the client can request them at + * other times. + */ case MODE_BROADCAST: if (peer->flags & FLAG_ASSOC) exten = crypto_args(peer, CRYPTO_AUTO | - CRYPTO_RESP, NULL); + CRYPTO_RESP, peer->associd, NULL); else exten = crypto_args(peer, CRYPTO_ASSOC | - CRYPTO_RESP, NULL); + CRYPTO_RESP, peer->associd, NULL); break; /* - * In symmetric modes the digest, certificate, agreement - * parameters, cookie and autokey values are required. - * The leapsecond table is optional. But, a passive peer - * will not believe the active peer until the latter has - * synchronized, so the agreement must be postponed - * until then. In any case, if a new keylist is - * generated, the autokey values are pushed. - * - * If the crypto bit is lit, don't send requests. + * In symmetric modes the parameter, certificate, + * identity, cookie and autokey exchanges are + * required. The leapsecond exchange is optional. But, a + * peer will not believe the other peer until the other + * peer has synchronized, so the certificate exchange + * might loop until then. If a peer finds a broken + * autokey sequence, it uses the autokey exchange to + * retrieve the autokey values. In any case, if a new + * keylist is generated, the autokey values are pushed. */ case MODE_ACTIVE: case MODE_PASSIVE: - if (peer->flash & TEST9) - break; + /* - * Parameter and certificate. + * Parameter, certificate and identity. */ if (!peer->crypto) exten = crypto_args(peer, CRYPTO_ASSOC, - sys_hostname); - else if (!(peer->crypto & CRYPTO_FLAG_VALID)) + peer->associd, sys_hostname); + else if (!(peer->crypto & CRYPTO_FLAG_CERT)) exten = crypto_args(peer, CRYPTO_CERT, - peer->issuer); - - /* - * Identity. Note we have to sign the - * certificate before the cookie to avoid a - * deadlock when the passive peer is walking the - * certificate trail. Awesome. - */ + peer->associd, peer->issuer); else if (!(peer->crypto & CRYPTO_FLAG_VRFY)) exten = crypto_args(peer, - crypto_ident(peer), NULL); - else if (sys_leap != LEAP_NOTINSYNC && - !(peer->crypto & CRYPTO_FLAG_SIGN)) - exten = crypto_args(peer, CRYPTO_SIGN, - sys_hostname); + crypto_ident(peer), peer->associd, + NULL); /* - * Autokey. We request the cookie only when the - * server and client are synchronized and - * signatures work both ways. On the other hand, - * the active peer needs the autokey values - * before then and when the passive peer is - * waiting for the active peer to synchronize. - * Any time we regenerate the key list, we offer - * the autokey values without being asked. + * Cookie and autokey. We request the cookie + * only when the this peer and the other peer + * are synchronized. But, this peer needs the + * autokey values when the cookie is zero. Any + * time we regenerate the key list, we offer the + * autokey values without being asked. If for + * some reason either peer finds a broken + * autokey sequence, the autokey exchange is + * used to retrieve the autokey values. */ else if (sys_leap != LEAP_NOTINSYNC && - peer->leap != LEAP_NOTINSYNC && - !(peer->crypto & CRYPTO_FLAG_AGREE)) + peer->leap != LEAP_NOTINSYNC && + !(peer->crypto & CRYPTO_FLAG_COOK)) exten = crypto_args(peer, CRYPTO_COOK, - NULL); - else if (peer->flags & FLAG_ASSOC) - exten = crypto_args(peer, CRYPTO_AUTO | - CRYPTO_RESP, NULL); + peer->associd, NULL); else if (!(peer->crypto & CRYPTO_FLAG_AUTO)) exten = crypto_args(peer, CRYPTO_AUTO, - NULL); + peer->associd, NULL); + else if (peer->flags & FLAG_ASSOC && + peer->crypto & CRYPTO_FLAG_SIGN) + exten = crypto_args(peer, CRYPTO_AUTO | + CRYPTO_RESP, peer->assoc, NULL); /* - * Postamble. We trade leapseconds only when the - * server and client are synchronized. + * Wait for clock sync, then sign the + * certificate and retrieve the leapsecond + * values. */ - else if (sys_leap != LEAP_NOTINSYNC && - peer->leap != LEAP_NOTINSYNC && - peer->crypto & CRYPTO_FLAG_TAI && - !(peer->crypto & CRYPTO_FLAG_LEAP)) - exten = crypto_args(peer, CRYPTO_TAI, - NULL); + else if (sys_leap == LEAP_NOTINSYNC) + break; + + else if (!(peer->crypto & CRYPTO_FLAG_SIGN)) + exten = crypto_args(peer, CRYPTO_SIGN, + peer->associd, sys_hostname); + else if (!(peer->crypto & CRYPTO_FLAG_LEAP)) + exten = crypto_args(peer, CRYPTO_LEAP, + peer->associd, NULL); break; /* - * In client mode the digest, certificate, agreement - * parameters and cookie are required. The leapsecond - * table is optional. If broadcast client mode, the - * autokey values are required as well. In broadcast - * client mode, these values must be acquired during the - * client/server exchange to avoid having to wait until - * the next key list regeneration. Otherwise, the poor - * dude may die a lingering death until becoming - * unreachable and attempting rebirth. - * - * If neither the server or client have the agreement - * parameters, the protocol transmits the cookie in the - * clear. If the server has the parameters, the client - * requests them and the protocol blinds it using the - * agreed key. It is a protocol error if the client has - * the parameters but the server does not. - * - * If the crypto bit is lit, don't send requests. + * In client mode the parameter, certificate, identity, + * cookie and sign exchanges are required. The + * leapsecond exchange is optional. If broadcast client + * mode the same exchanges are required, except that the + * autokey exchange is substitutes for the cookie + * exchange, since the cookie is always zero. If the + * broadcast client finds a broken autokey sequence, it + * uses the autokey exchange to retrieve the autokey + * values. */ case MODE_CLIENT: - if (peer->flash & TEST9) - break; + /* - * Parameter and certificate. + * Parameter, certificate and identity. */ if (!peer->crypto) exten = crypto_args(peer, CRYPTO_ASSOC, - sys_hostname); - else if (!(peer->crypto & CRYPTO_FLAG_VALID)) + peer->associd, sys_hostname); + else if (!(peer->crypto & CRYPTO_FLAG_CERT)) exten = crypto_args(peer, CRYPTO_CERT, - peer->issuer); - - /* - * Identity - */ + peer->associd, peer->issuer); else if (!(peer->crypto & CRYPTO_FLAG_VRFY)) exten = crypto_args(peer, - crypto_ident(peer), NULL); + crypto_ident(peer), peer->associd, + NULL); /* - * Autokey + * Cookie and autokey. These are requests, but + * we use the peer association ID with autokey + * rather than our own. */ - else if (!(peer->crypto & CRYPTO_FLAG_AGREE)) + else if (!(peer->crypto & CRYPTO_FLAG_COOK)) exten = crypto_args(peer, CRYPTO_COOK, - NULL); - else if (!(peer->crypto & CRYPTO_FLAG_AUTO) && - (peer->cast_flags & MDF_BCLNT)) + peer->associd, NULL); + else if (!(peer->crypto & CRYPTO_FLAG_AUTO)) exten = crypto_args(peer, CRYPTO_AUTO, - NULL); + peer->assoc, NULL); /* - * Postamble. We can sign the certificate here, - * since there is no chance of deadlock. + * Wait for clock sync, then sign the + * certificate and retrieve the leapsecond + * values. */ - else if (sys_leap != LEAP_NOTINSYNC && - !(peer->crypto & CRYPTO_FLAG_SIGN)) + else if (sys_leap == LEAP_NOTINSYNC) + break; + + else if (!(peer->crypto & CRYPTO_FLAG_SIGN)) exten = crypto_args(peer, CRYPTO_SIGN, - sys_hostname); - else if (sys_leap != LEAP_NOTINSYNC && - peer->crypto & CRYPTO_FLAG_TAI && - !(peer->crypto & CRYPTO_FLAG_LEAP)) - exten = crypto_args(peer, CRYPTO_TAI, - NULL); + peer->associd, sys_hostname); + else if (!(peer->crypto & CRYPTO_FLAG_LEAP)) + exten = crypto_args(peer, CRYPTO_LEAP, + peer->associd, NULL); break; } /* - * Build the extension fields as directed. A response to - * a request is always sent, even if an error. If an - * error occurs when sending a request, the crypto - * machinery broke or was misconfigured. In that case - * light the crypto bit to suppress further requests. + * Add a queued extension field if present. This is + * always a request message, so the reply ID is already + * in the message. If an error occurs, the error bit is + * lit in the response. */ if (peer->cmmd != NULL) { - peer->cmmd->associd = htonl(peer->associd); - sendlen += crypto_xmit(&xpkt, &peer->srcadr, - sendlen, peer->cmmd, 0); + u_int32 temp32; + + temp32 = CRYPTO_RESP; + peer->cmmd->opcode |= htonl(temp32); + sendlen += crypto_xmit(peer, &xpkt, NULL, + sendlen, peer->cmmd, 0); free(peer->cmmd); peer->cmmd = NULL; } - if (exten != NULL) { - int ltemp = 0; - if (exten->opcode != 0) { - ltemp = crypto_xmit(&xpkt, - &peer->srcadr, sendlen, exten, 0); - if (ltemp == 0) { - peer->flash |= TEST9; /* crypto error */ - free(exten); - return; - } - } - sendlen += ltemp; + /* + * Add an extension field created above. All but the + * autokey response message are request messages. + */ + if (exten != NULL) { + if (exten->opcode != 0) + sendlen += crypto_xmit(peer, &xpkt, + NULL, sendlen, exten, 0); free(exten); } /* - * If extension fields are present, we must use a - * private cookie value of zero. Don't send if the - * crypto bit is set and no extension field is present, - * but in that case give back the key. Most intricate. + * Calculate the next session key. Since extension + * fields are present, the cookie value is zero. */ if (sendlen > LEN_PKT_NOMAC) { session_key(&peer->dstadr->sin, &peer->srcadr, xkeyid, 0, 2); - } else if (peer->flash & TEST9) { - authtrust(xkeyid, 0); - return; } } #endif /* OPENSSL */ /* - * Stash the transmit timestamp corrected for the encryption - * delay. If autokey, give back the key, as we use keys only - * once. Check for errors such as missing keys, buffer overflow, - * etc. + * Transmit a-priori timestamps */ + get_systime(&xmt_tx); + if (peer->flip == 0) { /* basic mode */ + peer->aorg = xmt_tx; + HTONL_FP(&xmt_tx, &xpkt.xmt); + } else { /* interleaved modes */ + if (peer->hmode == MODE_BROADCAST) { /* bcst */ + HTONL_FP(&xmt_tx, &xpkt.xmt); + if (peer->flip > 0) + HTONL_FP(&peer->borg, &xpkt.org); + else + HTONL_FP(&peer->aorg, &xpkt.org); + } else { /* symmetric */ + if (peer->flip > 0) + HTONL_FP(&peer->borg, &xpkt.xmt); + else + HTONL_FP(&peer->aorg, &xpkt.xmt); + } + } xkeyid = peer->keyid; - get_systime(&peer->xmt); - L_ADD(&peer->xmt, &sys_authdelay); - HTONL_FP(&peer->xmt, &xpkt.xmt); authlen = authencrypt(xkeyid, (u_int32 *)&xpkt, sendlen); if (authlen == 0) { - msyslog(LOG_INFO, "transmit: %s key %u not found", - stoa(&peer->srcadr), xkeyid); - peer->flash |= TEST9; /* no key found */ + report_event(PEVNT_AUTH, peer, "no key"); + peer->flash |= TEST5; /* auth error */ + peer->badauth++; return; } sendlen += authlen; @@ -2753,44 +3154,45 @@ if (xkeyid > NTP_MAXKEY) authtrust(xkeyid, 0); #endif /* OPENSSL */ - get_systime(&xmt_tx); if (sendlen > sizeof(xpkt)) { - msyslog(LOG_ERR, "buffer overflow %u", sendlen); + msyslog(LOG_ERR, "proto: buffer overflow %u", sendlen); exit (-1); } + peer->t21_bytes = sendlen; sendpkt(&peer->srcadr, peer->dstadr, sys_ttl[peer->ttl], &xpkt, - sendlen); + sendlen); + peer->sent++; + peer->throttle += (1 << peer->minpoll) - 2; /* - * Calculate the encryption delay. Keep the minimum over - * the latest two samples. + * Capture a-posteriori timestamps */ - L_SUB(&xmt_tx, &peer->xmt); - L_ADD(&xmt_tx, &sys_authdelay); - sys_authdly[1] = sys_authdly[0]; - sys_authdly[0] = xmt_tx.l_uf; - if (sys_authdly[0] < sys_authdly[1]) - sys_authdelay.l_uf = sys_authdly[0]; - else - sys_authdelay.l_uf = sys_authdly[1]; - peer->sent++; + get_systime(&xmt_ty); + if (peer->flip != 0) { /* interleaved modes */ + if (peer->flip > 0) + peer->aorg = xmt_ty; + else + peer->borg = xmt_ty; + peer->flip = -peer->flip; + } + L_SUB(&xmt_ty, &xmt_tx); + LFPTOD(&xmt_ty, peer->xleave); #ifdef OPENSSL #ifdef DEBUG if (debug) - printf( - "transmit: at %ld %s->%s mode %d keyid %08x len %d mac %d index %d\n", - current_time, peer->dstadr ? ntoa(&peer->dstadr->sin) : "-", - ntoa(&peer->srcadr), peer->hmode, xkeyid, sendlen - - authlen, authlen, peer->keynumber); + printf("transmit: at %ld %s->%s mode %d keyid %08x len %d index %d\n", + current_time, peer->dstadr ? + ntoa(&peer->dstadr->sin) : "-", + ntoa(&peer->srcadr), peer->hmode, xkeyid, sendlen, + peer->keynumber); #endif -#else +#else /* OPENSSL */ #ifdef DEBUG if (debug) - printf( - "transmit: at %ld %s->%s mode %d keyid %08x len %d mac %d\n", - current_time, peer->dstadr ? ntoa(&peer->dstadr->sin) : "-", - ntoa(&peer->srcadr), peer->hmode, xkeyid, sendlen - - authlen, authlen); + printf("transmit: at %ld %s->%s mode %d keyid %08x len %d\n", + current_time, peer->dstadr ? + ntoa(&peer->dstadr->sin) : "-", + ntoa(&peer->srcadr), peer->hmode, xkeyid, sendlen); #endif #endif /* OPENSSL */ } @@ -2803,111 +3205,77 @@ static void fast_xmit( struct recvbuf *rbufp, /* receive packet pointer */ - int xmode, /* transmit mode */ + int xmode, /* receive mode */ keyid_t xkeyid, /* transmit key ID */ - int mask /* restrict mask */ + int flags /* restrict mask */ ) { - struct pkt xpkt; /* transmit packet structure */ - struct pkt *rpkt; /* receive packet structure */ - l_fp xmt_ts; /* timestamp */ - l_fp xmt_tx; /* timestamp after authent */ - int sendlen, authlen; + struct pkt xpkt; /* transmit packet structure */ + struct pkt *rpkt; /* receive packet structure */ + l_fp xmt_tx, xmt_ty; + int sendlen; #ifdef OPENSSL u_int32 temp32; #endif /* * Initialize transmit packet header fields from the receive - * buffer provided. We leave some fields intact as received. If - * the gazinta was from a multicast address, the gazoutta must - * go out another way. - * - * The root delay field is special. If the system stratum is - * less than the orphan stratum, send the real root delay. - * Otherwise, if there is no system peer, send the orphan delay. - * Otherwise, we must be an orphan parent, so send zero. + * buffer provided. We leave the fields intact as received, but + * set the peer poll at the maximum of the receive peer poll and + * the system minimum poll (ntp_minpoll). This is for KoD rate + * control and not strictly specification compliant, but doesn't + * break anything. + * + * If the gazinta was from a multicast address, the gazoutta + * must go out another way. */ rpkt = &rbufp->recv_pkt; if (rbufp->dstadr->flags & INT_MCASTOPEN) rbufp->dstadr = findinterface(&rbufp->recv_srcadr); /* - * This is deliciously complicated. There are four cases. - * - * case leap stratum refid delay dispersion - * - * KoD 11 16 KISS system system - * normal system system system system system - * orphan child 00 orphan system orphan system - * orphan parent 00 orphan loopbk 0 0 - */ - /* - * This is a kiss-of-death (KoD) packet. Show leap + * If this is a kiss-o'-death (KoD) packet, show leap * unsynchronized, stratum zero, reference ID the four-character - * kiss code and system root delay. Note the rate limit on these - * packets. Once a second initialize a bucket counter. Every - * packet sent decrements the counter until reaching zero. If - * the counter is zero, drop the kiss. + * kiss code and system root delay. Note we don't reveal the + * local time, so these packets can't be used for + * synchronization. */ - if (mask & RES_LIMITED) { - sys_limitrejected++; - if (sys_kod == 0 || !(mask & RES_DEMOBILIZE)) - return; - - sys_kod--; + if (flags & RES_KOD) { + sys_kodsent++; xpkt.li_vn_mode = PKT_LI_VN_MODE(LEAP_NOTINSYNC, PKT_VERSION(rpkt->li_vn_mode), xmode); - xpkt.stratum = STRATUM_UNSPEC; + xpkt.stratum = STRATUM_PKT_UNSPEC; + xpkt.ppoll = max(rpkt->ppoll, ntp_minpoll); memcpy(&xpkt.refid, "RATE", 4); - xpkt.rootdelay = HTONS_FP(DTOFP(sys_rootdelay)); - xpkt.rootdispersion = - HTONS_FP(DTOUFP(sys_rootdispersion)); + xpkt.org = rpkt->xmt; + xpkt.rec = rpkt->xmt; + xpkt.xmt = rpkt->xmt; /* * This is a normal packet. Use the system variables. */ - } else if (sys_stratum < sys_orphan) { + } else { xpkt.li_vn_mode = PKT_LI_VN_MODE(sys_leap, PKT_VERSION(rpkt->li_vn_mode), xmode); xpkt.stratum = STRATUM_TO_PKT(sys_stratum); + xpkt.ppoll = max(rpkt->ppoll, ntp_minpoll); + xpkt.precision = sys_precision; xpkt.refid = sys_refid; xpkt.rootdelay = HTONS_FP(DTOFP(sys_rootdelay)); - xpkt.rootdispersion = - HTONS_FP(DTOUFP(sys_rootdispersion)); - - /* - * This is a orphan child packet. The host is synchronized to an - * orphan parent. Show leap synchronized, orphan stratum, system - * reference ID and orphan root delay. - */ - } else if (sys_peer != NULL) { - xpkt.li_vn_mode = PKT_LI_VN_MODE(LEAP_NOWARNING, - PKT_VERSION(rpkt->li_vn_mode), xmode); - xpkt.stratum = STRATUM_TO_PKT(sys_orphan); - xpkt.refid = sys_refid; - xpkt.rootdelay = HTONS_FP(DTOFP(sys_orphandelay)); - xpkt.rootdispersion = - HTONS_FP(DTOUFP(sys_rootdispersion)); + xpkt.rootdisp = HTONS_FP(DTOUFP(sys_rootdisp)); + HTONL_FP(&sys_reftime, &xpkt.reftime); + xpkt.org = rpkt->xmt; + HTONL_FP(&rbufp->recv_time, &xpkt.rec); + get_systime(&xmt_tx); + HTONL_FP(&xmt_tx, &xpkt.xmt); + } - /* - * This is an orphan parent. Show leap synchronized, orphan - * stratum, loopack reference ID and zero root delay. - */ - } else { - xpkt.li_vn_mode = PKT_LI_VN_MODE(LEAP_NOWARNING, - PKT_VERSION(rpkt->li_vn_mode), xmode); - xpkt.stratum = STRATUM_TO_PKT(sys_orphan); - xpkt.refid = htonl(LOOPBACKADR); - xpkt.rootdelay = HTONS_FP(DTOFP(0)); - xpkt.rootdispersion = HTONS_FP(DTOFP(0)); +#ifdef HAVE_NTP_SIGND + if (flags & RES_MSSNTP) { + send_via_ntp_signd(rbufp, xmode, xkeyid, flags, &xpkt); + return; } - xpkt.ppoll = rpkt->ppoll; - xpkt.precision = sys_precision; - xpkt.rootdispersion = HTONS_FP(DTOUFP(sys_rootdispersion)); - HTONL_FP(&sys_reftime, &xpkt.reftime); - xpkt.org = rpkt->xmt; - HTONL_FP(&rbufp->recv_time, &xpkt.rec); +#endif /* HAVE_NTP_SIGND */ /* * If the received packet contains a MAC, the transmitted packet @@ -2916,15 +3284,14 @@ */ sendlen = LEN_PKT_NOMAC; if (rbufp->recv_length == sendlen) { - get_systime(&xmt_ts); - HTONL_FP(&xmt_ts, &xpkt.xmt); sendpkt(&rbufp->recv_srcadr, rbufp->dstadr, 0, &xpkt, sendlen); #ifdef DEBUG if (debug) - printf("transmit: at %ld %s->%s mode %d\n", + printf( + "transmit: at %ld %s->%s mode %d len %d\n", current_time, stoa(&rbufp->dstadr->sin), - stoa(&rbufp->recv_srcadr), xmode); + stoa(&rbufp->recv_srcadr), xmode, sendlen); #endif return; } @@ -2952,56 +3319,36 @@ */ cookie = session_key(&rbufp->recv_srcadr, &rbufp->dstadr->sin, 0, sys_private, 0); - if (rbufp->recv_length >= (int)(sendlen + MAX_MAC_LEN + - 2 * sizeof(u_int32))) { + if (rbufp->recv_length > sendlen + MAX_MAC_LEN) { session_key(&rbufp->dstadr->sin, &rbufp->recv_srcadr, xkeyid, 0, 2); temp32 = CRYPTO_RESP; rpkt->exten[0] |= htonl(temp32); - sendlen += crypto_xmit(&xpkt, - &rbufp->recv_srcadr, sendlen, - (struct exten *)rpkt->exten, cookie); + sendlen += crypto_xmit(NULL, &xpkt, rbufp, + sendlen, (struct exten *)rpkt->exten, + cookie); } else { session_key(&rbufp->dstadr->sin, &rbufp->recv_srcadr, xkeyid, cookie, 2); } } #endif /* OPENSSL */ - get_systime(&xmt_ts); - L_ADD(&xmt_ts, &sys_authdelay); - HTONL_FP(&xmt_ts, &xpkt.xmt); - authlen = authencrypt(xkeyid, (u_int32 *)&xpkt, sendlen); - sendlen += authlen; + get_systime(&xmt_tx); + sendlen += authencrypt(xkeyid, (u_int32 *)&xpkt, sendlen); #ifdef OPENSSL if (xkeyid > NTP_MAXKEY) authtrust(xkeyid, 0); #endif /* OPENSSL */ - get_systime(&xmt_tx); - if (sendlen > sizeof(xpkt)) { - msyslog(LOG_ERR, "buffer overflow %u", sendlen); - exit (-1); - } sendpkt(&rbufp->recv_srcadr, rbufp->dstadr, 0, &xpkt, sendlen); - - /* - * Calculate the encryption delay. Keep the minimum over the - * latest two samples. - */ - L_SUB(&xmt_tx, &xmt_ts); - L_ADD(&xmt_tx, &sys_authdelay); - sys_authdly[1] = sys_authdly[0]; - sys_authdly[0] = xmt_tx.l_uf; - if (sys_authdly[0] < sys_authdly[1]) - sys_authdelay.l_uf = sys_authdly[0]; - else - sys_authdelay.l_uf = sys_authdly[1]; + get_systime(&xmt_ty); + L_SUB(&xmt_ty, &xmt_tx); + sys_authdelay = xmt_ty; #ifdef DEBUG if (debug) printf( - "transmit: at %ld %s->%s mode %d keyid %08x len %d mac %d\n", + "transmit: at %ld %s->%s mode %d keyid %08x len %d\n", current_time, ntoa(&rbufp->dstadr->sin), - ntoa(&rbufp->recv_srcadr), xmode, xkeyid, sendlen - - authlen, authlen); + ntoa(&rbufp->recv_srcadr), xmode, xkeyid, sendlen); #endif } @@ -3025,9 +3372,11 @@ } value_free(&peer->sndval); peer->keynumber = 0; + peer->flags &= ~FLAG_ASSOC; #ifdef DEBUG if (debug) - printf("key_expire: at %lu\n", current_time); + printf("key_expire: at %lu associd %d\n", current_time, + peer->associd); #endif } #endif /* OPENSSL */ @@ -3038,7 +3387,7 @@ * * A peer is unfit for synchronization if * > TEST10 bad leap or stratum below floor or at or above ceiling - * > TEST11 root distance exceeded + * > TEST11 root distance exceeded for remote peer * > TEST12 a direct or indirect synchronization loop would form * > TEST13 unreachable or noselect */ @@ -3052,40 +3401,37 @@ /* * A stratum error occurs if (1) the server has never been * synchronized, (2) the server stratum is below the floor or - * greater than or equal to the ceiling, (3) the system stratum - * is below the orphan stratum and the server stratum is greater - * than or equal to the orphan stratum. + * greater than or equal to the ceiling. */ if (peer->leap == LEAP_NOTINSYNC || peer->stratum < sys_floor || - peer->stratum >= sys_ceiling || (sys_stratum < sys_orphan && - peer->stratum >= sys_orphan)) - rval |= TEST10; /* stratum out of bounds */ + peer->stratum >= sys_ceiling) + rval |= TEST10; /* bad synch or stratum */ /* - * A distance error occurs if the root distance is greater than - * or equal to the distance threshold plus the increment due to - * one poll interval. + * A distance error for a remote peer occurs if the root + * distance is greater than or equal to the distance threshold + * plus the increment due to one host poll interval. */ - if (root_distance(peer) >= sys_maxdist + clock_phi * - ULOGTOD(sys_poll)) + if (!(peer->flags & FLAG_REFCLOCK) && root_distance(peer) >= + sys_maxdist + clock_phi * ULOGTOD(peer->hpoll)) rval |= TEST11; /* distance exceeded */ /* * A loop error occurs if the remote peer is synchronized to the - * local peer of if the remote peer is synchronized to the same - * server as the local peer, but only if the remote peer is not - * the orphan parent. + * local peer or if the remote peer is synchronized to the same + * server as the local peer but only if the remote peer is + * neither a reference clock nor an orphan. */ if (peer->stratum > 1 && peer->refid != htonl(LOOPBACKADR) && - ((!peer->dstadr || peer->refid == peer->dstadr->addr_refid) || - peer->refid == sys_refid)) - rval |= TEST12; /* synch loop */ + (peer->refid == (peer->dstadr ? peer->dstadr->addr_refid : + 0) || peer->refid == sys_refid)) + rval |= TEST12; /* synchronization loop */ /* * An unreachable error occurs if the server is unreachable or * the noselect bit is set. */ - if (!peer->reach || peer->flags & FLAG_NOSELECT) + if (!peer->reach || (peer->flags & FLAG_NOSELECT)) rval |= TEST13; /* unreachable */ peer->flash &= ~PEER_TEST_MASK; @@ -3102,18 +3448,12 @@ #define MINLOOPS 5 /* minimum number of step samples */ /* - * This routine calculates the system precision, defined as the minimum - * of a sequence of differences between successive readings of the - * system clock. However, if the system clock can be read more than once - * during a tick interval, the difference can be zero or one LSB unit, - * where the LSB corresponds to one nanosecond or one microsecond. - * Conceivably, if some other process preempts this one and reads the - * clock, the difference can be more than one LSB unit. - * - * For hardware clock frequencies of 10 MHz or less, we assume the - * logical clock advances only at the hardware clock tick. For higher - * frequencies, we assume the logical clock can advance no more than 100 - * nanoseconds between ticks. + * This routine measures the system precision defined as the minimum of + * a sequence of differences between successive readings of the system + * clock. However, if a difference is less than MINSTEP, the clock has + * been read more than once during a clock tick and the difference is + * ignored. We set MINSTEP greater than zero in case something happens + * like a cache miss. */ int default_get_precision(void) @@ -3126,13 +3466,12 @@ int i; /* log2 precision */ /* - * Loop to find tick value in nanoseconds. Toss out outlyer - * values less than the minimun tick value. In wacky cases, use - * the default maximum value. + * Loop to find precision value in seconds. */ - get_systime(&last); tick = MAXSTEP; - for (i = 0; i < MINLOOPS;) { + i = 0; + get_systime(&last); + while (1) { get_systime(&val); diff = val; L_SUB(&diff, &last); @@ -3140,35 +3479,27 @@ LFPTOD(&diff, dtemp); if (dtemp < MINSTEP) continue; - i++; + if (dtemp < tick) tick = dtemp; + if (++i >= MINLOOPS) + break; } + sys_tick = tick; /* * Find the nearest power of two. */ - NLOG(NLOG_SYSEVENT) - msyslog(LOG_INFO, "precision = %.3f usec", tick * 1e6); + msyslog(LOG_NOTICE, "proto: precision = %.3f usec", tick * 1e6); for (i = 0; tick <= 1; i++) tick *= 2; - if (tick - 1. > 1. - tick / 2) + if (tick - 1 > 1 - tick / 2) i--; return (-i); } /* - * kod_proto - called once per second to limit kiss-of-death packets - */ -void -kod_proto(void) -{ - sys_kod = sys_kod_rate; -} - - -/* * init_proto - initialize the protocol module's data */ void @@ -3179,45 +3510,29 @@ /* * Fill in the sys_* stuff. Default is don't listen to - * broadcasting, authenticate. + * broadcasting, require authentication. */ sys_leap = LEAP_NOTINSYNC; sys_stratum = STRATUM_UNSPEC; memcpy(&sys_refid, "INIT", 4); - sys_precision = (s_char)default_get_precision(); - sys_jitter = LOGTOD(sys_precision); + sys_peer = NULL; sys_rootdelay = 0; - sys_orphandelay = (double)(ntp_random() & 0xffff) / 65536. * - sys_maxdist; - sys_rootdispersion = 0; + sys_rootdisp = 0; L_CLR(&sys_reftime); - sys_peer = NULL; - sys_survivors = 0; + sys_jitter = 0; + sys_precision = (s_char)default_get_precision(); get_systime(&dummy); + sys_survivors = 0; sys_manycastserver = 0; sys_bclient = 0; - sys_bdelay = DEFBROADDELAY; - sys_calldelay = BURST_DELAY; + sys_bdelay = 0; sys_authenticate = 1; - L_CLR(&sys_authdelay); - sys_authdly[0] = sys_authdly[1] = 0; - sys_stattime = 0; + sys_stattime = current_time; proto_clr_stats(); for (i = 0; i < MAX_TTL; i++) { sys_ttl[i] = (u_char)((i * 256) / MAX_TTL); sys_ttlmax = i; } -#ifdef OPENSSL - sys_automax = 1 << NTP_AUTOMAX; -#endif /* OPENSSL */ - - /* - * Default these to enable - */ - ntp_enable = 1; -#ifndef KERNEL_FLL_BUG - kern_enable = 1; -#endif pps_enable = 0; stats_control = 1; } @@ -3231,49 +3546,25 @@ int item, u_long value, double dvalue, - struct sockaddr_storage* svalue + sockaddr_u *svalue ) { /* * Figure out what he wants to change, then do it */ - switch (item) { - - /* - * Turn on/off kernel discipline. - */ - case PROTO_KERNEL: - kern_enable = (int)value; - break; + DPRINTF(2, ("proto_config: code %d value %lu dvalue %lf\n", + item, value, dvalue)); - /* - * Turn on/off clock discipline. - */ - case PROTO_NTP: - ntp_enable = (int)value; - break; - - /* - * Turn on/off monitoring. - */ - case PROTO_MONITOR: - if (value) - mon_start(MON_ON); - else - mon_stop(MON_ON); - break; + switch (item) { /* - * Turn on/off statistics. + * enable and disable commands - arguments are Boolean. */ - case PROTO_FILEGEN: - stats_control = (int)value; + case PROTO_AUTHENTICATE: /* authentication (auth) */ + sys_authenticate = value; break; - /* - * Turn on/off enable broadcasts. - */ - case PROTO_BROADCLIENT: + case PROTO_BROADCLIENT: /* broadcast client (bclient) */ sys_bclient = (int)value; if (sys_bclient == 0) io_unsetbclient(); @@ -3281,152 +3572,106 @@ io_setbclient(); break; - /* - * Turn on/off PPS discipline. - */ - case PROTO_PPS: - pps_enable = (int)value; +#ifdef REFCLOCK + case PROTO_CAL: /* refclock calibrate (calibrate) */ + cal_enable = value; break; +#endif /* REFCLOCK */ - /* - * Add muliticast group address. - */ - case PROTO_MULTICAST_ADD: - if (svalue) - io_multicast_add(*svalue); - sys_bclient = 1; + case PROTO_KERNEL: /* kernel discipline (kernel) */ + kern_enable = value; break; - /* - * Delete multicast group address. - */ - case PROTO_MULTICAST_DEL: - if (svalue) - io_multicast_del(*svalue); + case PROTO_MONITOR: /* monitoring (monitor) */ + if (value) + mon_start(MON_ON); + else + mon_stop(MON_ON); break; - /* - * Set default broadcast delay. - */ - case PROTO_BROADDELAY: - sys_bdelay = dvalue; + case PROTO_NTP: /* NTP discipline (ntp) */ + ntp_enable = value; break; - /* - * Set modem call delay. - */ - case PROTO_CALLDELAY: - sys_calldelay = (int)value; + case PROTO_PPS: /* PPS discipline (pps) */ + pps_enable = value; break; - /* - * Turn on/off authentication to mobilize ephemeral - * associations. - */ - case PROTO_AUTHENTICATE: - sys_authenticate = (int)value; + case PROTO_FILEGEN: /* statistics (stats) */ + stats_control = value; break; /* - * Set minimum number of survivors. + * tos command - arguments are double, sometimes cast to int */ - case PROTO_MINCLOCK: - sys_minclock = (int)dvalue; + case PROTO_BEACON: /* manycast beacon (beacon) */ + sys_beacon = (int)dvalue; break; - /* - * Set maximum number of preemptable associations. - */ - case PROTO_MAXCLOCK: - sys_maxclock = (int)dvalue; + case PROTO_BROADDELAY: /* default broadcast delay (bdelay) */ + sys_bdelay = dvalue; break; - /* - * Set minimum number of survivors. - */ - case PROTO_MINSANE: - sys_minsane = (int)dvalue; + case PROTO_CEILING: /* stratum ceiling (ceiling) */ + sys_ceiling = (int)dvalue; break; - /* - * Set stratum floor. - */ - case PROTO_FLOOR: + case PROTO_COHORT: /* cohort switch (cohort) */ + sys_cohort = (int)dvalue; + break; + + case PROTO_FLOOR: /* stratum floor (floor) */ sys_floor = (int)dvalue; break; - /* - * Set stratum ceiling. - */ - case PROTO_CEILING: - sys_ceiling = (int)dvalue; + case PROTO_MAXCLOCK: /* maximum candidates (maxclock) */ + sys_maxclock = (int)dvalue; break; - /* - * Set orphan stratum. - */ - case PROTO_ORPHAN: - sys_orphan = (int)dvalue; + case PROTO_MAXDIST: /* select threshold (maxdist) */ + sys_maxdist = dvalue; break; - /* - * Set cohort switch. - */ - case PROTO_COHORT: - sys_cohort = (int)dvalue; + case PROTO_CALLDELAY: /* modem call delay (mdelay) */ + break; /* NOT USED */ + + case PROTO_MINCLOCK: /* minimum candidates (minclock) */ + sys_minclock = (int)dvalue; break; - /* - * Set minimum dispersion increment. - */ - case PROTO_MINDISP: + case PROTO_MINDISP: /* minimum distance (mindist) */ sys_mindisp = dvalue; break; - /* - * Set maximum distance (select threshold). - */ - case PROTO_MAXDIST: - sys_maxdist = dvalue; + case PROTO_MINSANE: /* minimum survivors (minsane) */ + sys_minsane = (int)dvalue; break; - /* - * Set anticlockhop threshold. - */ - case PROTO_MAXHOP: - sys_maxhop = (int)dvalue; + case PROTO_ORPHAN: /* orphan stratum (orphan) */ + sys_orphan = (int)dvalue; break; - /* - * Set adjtime() resolution (s). - */ - case PROTO_ADJ: + case PROTO_ADJ: /* tick increment (tick) */ sys_tick = dvalue; break; /* - * Set manycast beacon interval. + * Miscellaneous commands */ - case PROTO_BEACON: - sys_beacon = (int)dvalue; + case PROTO_MULTICAST_ADD: /* add group address */ + if (svalue != NULL) + io_multicast_add(svalue); + sys_bclient = 1; break; -#ifdef REFCLOCK - /* - * Turn on/off refclock calibrate - */ - case PROTO_CAL: - cal_enable = (int)value; + case PROTO_MULTICAST_DEL: /* delete group address */ + if (svalue != NULL) + io_multicast_del(svalue); break; -#endif /* REFCLOCK */ - default: - /* - * Log this error. - */ - msyslog(LOG_INFO, - "proto_config: illegal item %d, value %ld", item, - value); + default: + msyslog(LOG_NOTICE, + "proto: unsupported option %d", item); } } @@ -3440,9 +3685,9 @@ sys_stattime = current_time; sys_received = 0; sys_processed = 0; - sys_newversionpkt = 0; - sys_oldversionpkt = 0; - sys_unknownversion = 0; + sys_newversion = 0; + sys_oldversion = 0; + sys_declined = 0; sys_restricted = 0; sys_badlength = 0; sys_badauth = 0; diff -urN src/contrib/ntp/ntpd/ntp_refclock.c src.ntp/contrib/ntp/ntpd/ntp_refclock.c --- src/contrib/ntp/ntpd/ntp_refclock.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/ntp_refclock.c 2010-06-19 08:40:31.000000000 +0200 @@ -11,6 +11,7 @@ #include "ntp_tty.h" #include "ntp_refclock.h" #include "ntp_stdlib.h" +#include "ntp_assert.h" #include @@ -34,63 +35,57 @@ #include "ntp_syscall.h" #endif /* KERNEL_PLL */ +#ifdef HAVE_PPSAPI +#include "ppsapi_timepps.h" +#include "refclock_atom.h" +#endif /* HAVE_PPSAPI */ + /* * Reference clock support is provided here by maintaining the fiction - * that the clock is actually a peer. As no packets are exchanged with a - * reference clock, however, we replace the transmit, receive and packet - * procedures with separate code to simulate them. Routines + * that the clock is actually a peer. As no packets are exchanged with + * a reference clock, however, we replace the transmit, receive and + * packet procedures with separate code to simulate them. Routines * refclock_transmit() and refclock_receive() maintain the peer * variables in a state analogous to an actual peer and pass reference - * clock data on through the filters. Routines refclock_peer() and + * clock data on through the filters. Routines refclock_peer() and * refclock_unpeer() are called to initialize and terminate reference - * clock associations. A set of utility routines is included to open + * clock associations. A set of utility routines is included to open * serial devices, process sample data, edit input lines to extract - * embedded timestamps and to peform various debugging functions. + * embedded timestamps and to perform various debugging functions. * * The main interface used by these routines is the refclockproc - * structure, which contains for most drivers the decimal equivalants of - * the year, day, month, hour, second and millisecond/microsecond - * decoded from the ASCII timecode. Additional information includes the - * receive timestamp, exception report, statistics tallies, etc. In - * addition, there may be a driver-specific unit structure used for + * structure, which contains for most drivers the decimal equivalants + * of the year, day, month, hour, second and millisecond/microsecond + * decoded from the ASCII timecode. Additional information includes + * the receive timestamp, exception report, statistics tallies, etc. + * In addition, there may be a driver-specific unit structure used for * local control of the device. * * The support routines are passed a pointer to the peer structure, - * which is used for all peer-specific processing and contains a pointer - * to the refclockproc structure, which in turn containes a pointer to - * the unit structure, if used. The peer structure is identified by an - * interface address in the dotted quad form 127.127.t.u (for now only - * IPv4 addresses are used, so we need to be sure the address is it), - * where t is the clock type and u the unit. Some legacy drivers derive - * the refclockproc structure pointer from the table - * typeunit[type][unit]. This interface is strongly discouraged and may - * be abandoned in future. + * which is used for all peer-specific processing and contains a + * pointer to the refclockproc structure, which in turn contains a + * pointer to the unit structure, if used. The peer structure is + * identified by an interface address in the dotted quad form + * 127.127.t.u, where t is the clock type and u the unit. */ -#define MAXUNIT 4 /* max units */ #define FUDGEFAC .1 /* fudge correction factor */ #define LF 0x0a /* ASCII LF */ #ifdef PPS int fdpps; /* ppsclock legacy */ #endif /* PPS */ -int cal_enable; /* enable refclock calibrate */ -/* - * Type/unit peer index. Used to find the peer structure for control and - * debugging. When all clock drivers have been converted to new style, - * this dissapears. - */ -static struct peer *typeunit[REFCLK_MAX + 1][MAXUNIT]; +int cal_enable; /* enable refclock calibrate */ /* * Forward declarations */ #ifdef QSORT_USES_VOID_P -static int refclock_cmpl_fp P((const void *, const void *)); +static int refclock_cmpl_fp (const void *, const void *); #else -static int refclock_cmpl_fp P((const double *, const double *)); +static int refclock_cmpl_fp (const double *, const double *); #endif /* QSORT_USES_VOID_P */ -static int refclock_sample P((struct refclockproc *)); +static int refclock_sample (struct refclockproc *); /* @@ -113,58 +108,36 @@ return; switch (code) { - case CEVNT_NOMINAL: - break; - case CEVNT_TIMEOUT: - pp->noreply++; - break; - - case CEVNT_BADREPLY: - pp->badformat++; - break; - - case CEVNT_FAULT: - break; - - case CEVNT_PROP: - break; - - case CEVNT_BADDATE: - case CEVNT_BADTIME: - pp->baddata++; - break; - - default: - /* shouldn't happen */ - break; - } + case CEVNT_TIMEOUT: + pp->noreply++; + break; - if (pp->currentstatus != code) { - pp->currentstatus = (u_char)code; + case CEVNT_BADREPLY: + pp->badformat++; + break; - /* RFC1305: copy only iff not CEVNT_NOMINAL */ - if (code != CEVNT_NOMINAL) - pp->lastevent = (u_char)code; + case CEVNT_FAULT: + break; - if (code == CEVNT_FAULT) - msyslog(LOG_ERR, - "clock %s event '%s' (0x%02x)", - refnumtoa(&peer->srcadr), - ceventstr(code), code); - else { - NLOG(NLOG_CLOCKEVENT) - msyslog(LOG_INFO, - "clock %s event '%s' (0x%02x)", - refnumtoa(&peer->srcadr), - ceventstr(code), code); - } + case CEVNT_BADDATE: + case CEVNT_BADTIME: + pp->baddata++; + break; - /* RFC1305: post peer clock event */ - report_event(EVNT_PEERCLOCK, peer); + default: + /* ignore others */ + break; + } + if (pp->lastevent < 15) + pp->lastevent++; + if (pp->currentstatus != code) { + pp->currentstatus = (u_char)code; + report_event(PEVNT_CLOCK, peer, ceventstr(code)); } } + /* * init_refclock - initialize the reference clock drivers * @@ -175,14 +148,11 @@ void init_refclock(void) { - int i, j; + int i; - for (i = 0; i < (int)num_refclock_conf; i++) { + for (i = 0; i < (int)num_refclock_conf; i++) if (refclock_conf[i]->clock_init != noentry) (refclock_conf[i]->clock_init)(); - for (j = 0; j < MAXUNIT; j++) - typeunit[i][j] = 0; - } } @@ -211,12 +181,6 @@ * Check for valid clock address. If already running, shut it * down first. */ - if (peer->srcadr.ss_family != AF_INET) { - msyslog(LOG_ERR, - "refclock_newpeer: clock address %s invalid, address family not implemented for refclock", - stoa(&peer->srcadr)); - return (0); - } if (!ISREFCLOCKADR(&peer->srcadr)) { msyslog(LOG_ERR, "refclock_newpeer: clock address %s invalid", @@ -225,7 +189,7 @@ } clktype = (u_char)REFCLOCKTYPE(&peer->srcadr); unit = REFCLOCKUNIT(&peer->srcadr); - if (clktype >= num_refclock_conf || unit >= MAXUNIT || + if (clktype >= num_refclock_conf || refclock_conf[clktype]->clock_start == noentry) { msyslog(LOG_ERR, "refclock_newpeer: clock type %d invalid\n", @@ -236,12 +200,8 @@ /* * Allocate and initialize interface structure */ - pp = (struct refclockproc *)emalloc(sizeof(struct refclockproc)); - if (pp == NULL) - return (0); - - memset((char *)pp, 0, sizeof(struct refclockproc)); - typeunit[clktype][unit] = peer; + pp = emalloc(sizeof(*pp)); + memset(pp, 0, sizeof(*pp)); peer->procptr = pp; /* @@ -249,7 +209,7 @@ */ peer->refclktype = clktype; peer->refclkunit = (u_char)unit; - peer->flags |= FLAG_REFCLOCK | FLAG_FIXPOLL; + peer->flags |= FLAG_REFCLOCK; peer->leap = LEAP_NOTINSYNC; peer->stratum = STRATUM_REFCLOCK; peer->ppoll = peer->maxpoll; @@ -297,7 +257,7 @@ * Wiggle the driver to release its resources, then give back * the interface structure. */ - if (!peer->procptr) + if (NULL == peer->procptr) return; clktype = peer->refclktype; @@ -305,7 +265,7 @@ if (refclock_conf[clktype]->clock_shutdown != noentry) (refclock_conf[clktype]->clock_shutdown)(unit, peer); free(peer->procptr); - peer->procptr = 0; + peer->procptr = NULL; } @@ -365,19 +325,17 @@ * Update reachability and poll variables like the * network code. */ - oreach = peer->reach; + oreach = peer->reach & 0xfe; peer->reach <<= 1; + if (!(peer->reach & 0x0f)) + clock_filter(peer, 0., 0., MAXDISPERSE); peer->outdate = current_time; if (!peer->reach) { if (oreach) { - report_event(EVNT_UNREACH, peer); + report_event(PEVNT_UNREACH, peer, NULL); peer->timereachable = current_time; } } else { - if (!(oreach & 0x07)) { - clock_filter(peer, 0., 0., MAXDISPERSE); - clock_select(); - } if (peer->flags & FLAG_BURST) peer->burst = NSTAGE; } @@ -458,6 +416,7 @@ /* * refclock_process - process a sample from the clock + * refclock_process_f - refclock_process with other than time1 fudge * * This routine converts the timecode in the form days, hours, minutes, * seconds and milliseconds/microseconds to internal timestamp format, @@ -472,8 +431,9 @@ * zero and the fraction for pp->lastrec is set to the PPS offset. */ int -refclock_process( - struct refclockproc *pp /* refclock structure pointer */ +refclock_process_f( + struct refclockproc *pp, /* refclock structure pointer */ + double fudge ) { l_fp offset, ltemp; @@ -493,12 +453,20 @@ offset.l_uf = 0; DTOLFP(pp->nsec / 1e9, <emp); L_ADD(&offset, <emp); - refclock_process_offset(pp, offset, pp->lastrec, - pp->fudgetime1); + refclock_process_offset(pp, offset, pp->lastrec, fudge); return (1); } +int +refclock_process( + struct refclockproc *pp /* refclock structure pointer */ +) +{ + return refclock_process_f(pp, pp->fudgetime1); +} + + /* * refclock_sample - process a pile of samples from the clock * @@ -611,30 +579,23 @@ peer->received++; peer->timereceived = current_time; if (!peer->reach) { - report_event(EVNT_REACH, peer); + report_event(PEVNT_REACH, peer, NULL); peer->timereachable = current_time; } peer->reach |= 1; peer->reftime = pp->lastref; - peer->org = pp->lastrec; - peer->rootdispersion = pp->disp; - get_systime(&peer->rec); + peer->aorg = pp->lastrec; + peer->rootdisp = pp->disp; + get_systime(&peer->dst); if (!refclock_sample(pp)) return; clock_filter(peer, pp->offset, 0., pp->jitter); - record_peer_stats(&peer->srcadr, ctlpeerstatus(peer), - peer->offset, peer->delay, clock_phi * (current_time - - peer->epoch), peer->jitter); - if (cal_enable && last_offset < MINDISPERSE) { -#ifdef KERNEL_PLL - if (peer != sys_peer || pll_status & STA_PPSTIME) -#else - if (peer != sys_peer) -#endif /* KERNEL_PLL */ + if (cal_enable && fabs(last_offset) < sys_mindisp && sys_peer != + NULL) { + if (sys_peer->refclktype == REFCLK_ATOM_PPS && + peer->refclktype != REFCLK_ATOM_PPS) pp->fudgetime1 -= pp->offset * FUDGEFAC; - else - pp->fudgetime1 -= pp->fudgetime1 * FUDGEFAC; } } @@ -781,6 +742,9 @@ { int fd; int omode; +#ifdef O_NONBLOCK + char trash[128]; /* litter bin for old input data */ +#endif /* * Open serial port and set default options @@ -798,6 +762,7 @@ msyslog(LOG_ERR, "refclock_open %s: %m", dev); return (0); } + NTP_INSIST(fd != 0); if (!refclock_setup(fd, speed, lflags)) { close(fd); return (0); @@ -806,9 +771,20 @@ close(fd); return (0); } +#ifdef O_NONBLOCK + /* + * We want to make sure there is no pending trash in the input + * buffer. Since we have non-blocking IO available, this is a + * good moment to read and dump all available outdated stuff + * that might have become toxic for the driver. + */ + while (read(fd, trash, sizeof(trash)) > 0 || errno == EINTR) + /*NOP*/; +#endif return (fd); } + /* * refclock_setup - initialize terminal interface structure */ @@ -900,6 +876,14 @@ "refclock_setup fd %d TCSANOW: %m", fd); return (0); } + + /* + * flush input and output buffers to discard any outdated stuff + * that might have become toxic for the driver. Failing to do so + * is logged, but we keep our fingers crossed otherwise. + */ + if (tcflush(fd, TCIOFLUSH) < 0) + msyslog(LOG_ERR, "refclock_setup fd %d tcflush(): %m", fd); #endif /* HAVE_TERMIOS */ #ifdef HAVE_SYSV_TTYS @@ -1064,7 +1048,7 @@ */ void refclock_control( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct refclockstat *in, struct refclockstat *out ) @@ -1077,22 +1061,15 @@ /* * Check for valid address and running peer */ - if (srcadr->ss_family != AF_INET) - return; - if (!ISREFCLOCKADR(srcadr)) return; clktype = (u_char)REFCLOCKTYPE(srcadr); unit = REFCLOCKUNIT(srcadr); - if (clktype >= num_refclock_conf || unit >= MAXUNIT) - return; - peer = typeunit[clktype][unit]; - if (peer == NULL) - return; + peer = findexistingpeer(srcadr, NULL, -1); - if (peer->procptr == NULL) + if (NULL == peer || NULL == peer->procptr) return; pp = peer->procptr; @@ -1149,7 +1126,7 @@ out->currentstatus = pp->currentstatus; out->type = pp->type; out->clockdesc = pp->clockdesc; - out->lencode = pp->lencode; + out->lencode = (u_short)pp->lencode; out->p_lastcode = pp->a_lastcode; } @@ -1170,32 +1147,28 @@ */ void refclock_buginfo( - struct sockaddr_storage *srcadr, /* clock address */ + sockaddr_u *srcadr, /* clock address */ struct refclockbug *bug /* output structure */ ) { struct peer *peer; struct refclockproc *pp; - u_char clktype; + int clktype; int unit; - int i; + unsigned u; /* * Check for valid address and peer structure */ - if (srcadr->ss_family != AF_INET) - return; - if (!ISREFCLOCKADR(srcadr)) return; clktype = (u_char) REFCLOCKTYPE(srcadr); unit = REFCLOCKUNIT(srcadr); - if (clktype >= num_refclock_conf || unit >= MAXUNIT) - return; - peer = typeunit[clktype][unit]; - if (peer == NULL) + peer = findexistingpeer(srcadr, NULL, -1); + + if (NULL == peer || NULL == peer->procptr) return; pp = peer->procptr; @@ -1216,8 +1189,8 @@ bug->stimes = 0xfffffffc; bug->times[0] = pp->lastref; bug->times[1] = pp->lastrec; - for (i = 2; i < (int)bug->ntimes; i++) - DTOLFP(pp->filter[i - 2], &bug->times[i]); + for (u = 2; u < bug->ntimes; u++) + DTOLFP(pp->filter[u - 2], &bug->times[u]); /* * Give the stuff to the clock @@ -1226,4 +1199,154 @@ (refclock_conf[clktype]->clock_buginfo)(unit, bug, peer); } + +#ifdef HAVE_PPSAPI +/* + * refclock_ppsapi - initialize/update ppsapi + * + * This routine is called after the fudge command to open the PPSAPI + * interface for later parameter setting after the fudge command. + */ +int +refclock_ppsapi( + int fddev, /* fd device */ + struct refclock_atom *ap /* atom structure pointer */ + ) +{ + if (ap->handle == 0) { + if (time_pps_create(fddev, &ap->handle) < 0) { + msyslog(LOG_ERR, + "refclock_ppsapi: time_pps_create: %m"); + return (0); + } + } + return (1); +} + + +/* + * refclock_params - set ppsapi parameters + * + * This routine is called to set the PPSAPI parameters after the fudge + * command. + */ +int +refclock_params( + int mode, /* mode bits */ + struct refclock_atom *ap /* atom structure pointer */ + ) +{ + memset(&ap->pps_params, 0, sizeof(pps_params_t)); + ap->pps_params.api_version = PPS_API_VERS_1; + + /* + * Solaris serial ports provide PPS pulse capture only on the + * assert edge. FreeBSD serial ports provide capture on the + * clear edge, while FreeBSD parallel ports provide capture + * on the assert edge. Your mileage may vary. + */ + if (mode & CLK_FLAG2) + ap->pps_params.mode = PPS_TSFMT_TSPEC | PPS_CAPTURECLEAR; + else + ap->pps_params.mode = PPS_TSFMT_TSPEC | PPS_CAPTUREASSERT; + if (time_pps_setparams(ap->handle, &ap->pps_params) < 0) { + msyslog(LOG_ERR, + "refclock_params: time_pps_setparams: %m"); + return (0); + } + + /* + * If flag3 is lit, select the kernel PPS. + */ + if (mode & CLK_FLAG3) { + if (time_pps_kcbind(ap->handle, PPS_KC_HARDPPS, + ap->pps_params.mode & ~PPS_TSFMT_TSPEC, + PPS_TSFMT_TSPEC) < 0) { + if (errno != EOPNOTSUPP) { + msyslog(LOG_ERR, + "refclock_params: time_pps_kcbind: %m"); + return (0); + } + } + pps_enable = 1; + } + return (1); +} + + +/* + * refclock_pps - called once per second + * + * This routine is called once per second. It snatches the PPS + * timestamp from the kernel and saves the sign-extended fraction in + * a circular buffer for processing at the next poll event. + */ +int +refclock_pps( + struct peer *peer, /* peer structure pointer */ + struct refclock_atom *ap, /* atom structure pointer */ + int mode /* mode bits */ + ) +{ + struct refclockproc *pp; + pps_info_t pps_info; + struct timespec timeout; + double dtemp; + + /* + * We require the clock to be synchronized before setting the + * parameters. When the parameters have been set, fetch the + * most recent PPS timestamp. + */ + pp = peer->procptr; + if (ap->handle == 0) + return (0); + + if (ap->pps_params.mode == 0 && sys_leap != LEAP_NOTINSYNC) { + if (refclock_params(pp->sloppyclockflag, ap) < 1) + return (0); + } + timeout.tv_sec = 0; + timeout.tv_nsec = 0; + memset(&pps_info, 0, sizeof(pps_info_t)); + if (time_pps_fetch(ap->handle, PPS_TSFMT_TSPEC, &pps_info, + &timeout) < 0) { + refclock_report(peer, CEVNT_FAULT); + return (0); + } + timeout = ap->ts; + if (ap->pps_params.mode & PPS_CAPTUREASSERT) + ap->ts = pps_info.assert_timestamp; + else if (ap->pps_params.mode & PPS_CAPTURECLEAR) + ap->ts = pps_info.clear_timestamp; + else + return (0); + + /* + * There can be zero, one or two PPS pulses between polls, + * depending on the poll interval relative to the PPS interval. + * The pulse must be newer and within the range gate relative + * to the last pulse. + */ + if (ap->ts.tv_sec <= timeout.tv_sec || abs(ap->ts.tv_nsec - + timeout.tv_nsec) > RANGEGATE) + return (0); + + /* + * Convert to signed fraction offset and stuff in median filter. + */ + pp->lastrec.l_ui = (u_int32)ap->ts.tv_sec + JAN_1970; + dtemp = ap->ts.tv_nsec / 1e9; + pp->lastrec.l_uf = (u_int32)(dtemp * FRAC); + if (dtemp > .5) + dtemp -= 1.; + SAMPLE(-dtemp + pp->fudgetime1); +#ifdef DEBUG + if (debug > 1) + printf("refclock_pps: %lu %f %f\n", current_time, + dtemp, pp->fudgetime1); +#endif + return (1); +} +#endif /* HAVE_PPSAPI */ #endif /* REFCLOCK */ diff -urN src/contrib/ntp/ntpd/ntp_request.c src.ntp/contrib/ntp/ntpd/ntp_request.c --- src/contrib/ntp/ntpd/ntp_request.c 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/ntp_request.c 2010-07-07 12:01:06.000000000 +0200 @@ -13,11 +13,14 @@ #include "ntp_refclock.h" #include "ntp_if.h" #include "ntp_stdlib.h" +#include "ntp_assert.h" #include #include #include +#ifdef HAVE_NETINET_IN_H #include +#endif #include #include "recvbuff.h" @@ -47,8 +50,8 @@ short needs_auth; /* true when authentication needed */ short sizeofitem; /* size of request data item (older size)*/ short v6_sizeofitem; /* size of request data item (new size)*/ - void (*handler) P((struct sockaddr_storage *, struct interface *, - struct req_pkt *)); /* routine to handle request */ + void (*handler) (sockaddr_u *, struct interface *, + struct req_pkt *); /* routine to handle request */ }; /* @@ -58,58 +61,59 @@ { NO_REQUEST, NOAUTH, 0, 0 } }; -static void req_ack P((struct sockaddr_storage *, struct interface *, struct req_pkt *, int)); -static char * prepare_pkt P((struct sockaddr_storage *, struct interface *, struct req_pkt *, u_int)); -static char * more_pkt P((void)); -static void flush_pkt P((void)); -static void peer_list P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void peer_list_sum P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void peer_info P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void peer_stats P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void sys_info P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void sys_stats P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void mem_stats P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void io_stats P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void timer_stats P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void loop_info P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void do_conf P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void do_unconf P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void set_sys_flag P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void clr_sys_flag P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void setclr_flags P((struct sockaddr_storage *, struct interface *, struct req_pkt *, u_long)); -static void list_restrict P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void do_resaddflags P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void do_ressubflags P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void do_unrestrict P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void do_restrict P((struct sockaddr_storage *, struct interface *, struct req_pkt *, int)); -static void mon_getlist_0 P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void mon_getlist_1 P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void reset_stats P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void reset_peer P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void do_key_reread P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void trust_key P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void untrust_key P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void do_trustkey P((struct sockaddr_storage *, struct interface *, struct req_pkt *, u_long)); -static void get_auth_info P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void reset_auth_stats P((void)); -static void req_get_traps P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void req_set_trap P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void req_clr_trap P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void do_setclr_trap P((struct sockaddr_storage *, struct interface *, struct req_pkt *, int)); -static void set_request_keyid P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void set_control_keyid P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void get_ctl_stats P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void get_if_stats P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void do_if_reload P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); +static void req_ack (sockaddr_u *, struct interface *, struct req_pkt *, int); +static char * prepare_pkt (sockaddr_u *, struct interface *, + struct req_pkt *, size_t); +static char * more_pkt (void); +static void flush_pkt (void); +static void peer_list (sockaddr_u *, struct interface *, struct req_pkt *); +static void peer_list_sum (sockaddr_u *, struct interface *, struct req_pkt *); +static void peer_info (sockaddr_u *, struct interface *, struct req_pkt *); +static void peer_stats (sockaddr_u *, struct interface *, struct req_pkt *); +static void sys_info (sockaddr_u *, struct interface *, struct req_pkt *); +static void sys_stats (sockaddr_u *, struct interface *, struct req_pkt *); +static void mem_stats (sockaddr_u *, struct interface *, struct req_pkt *); +static void io_stats (sockaddr_u *, struct interface *, struct req_pkt *); +static void timer_stats (sockaddr_u *, struct interface *, struct req_pkt *); +static void loop_info (sockaddr_u *, struct interface *, struct req_pkt *); +static void do_conf (sockaddr_u *, struct interface *, struct req_pkt *); +static void do_unconf (sockaddr_u *, struct interface *, struct req_pkt *); +static void set_sys_flag (sockaddr_u *, struct interface *, struct req_pkt *); +static void clr_sys_flag (sockaddr_u *, struct interface *, struct req_pkt *); +static void setclr_flags (sockaddr_u *, struct interface *, struct req_pkt *, u_long); +static void list_restrict (sockaddr_u *, struct interface *, struct req_pkt *); +static void do_resaddflags (sockaddr_u *, struct interface *, struct req_pkt *); +static void do_ressubflags (sockaddr_u *, struct interface *, struct req_pkt *); +static void do_unrestrict (sockaddr_u *, struct interface *, struct req_pkt *); +static void do_restrict (sockaddr_u *, struct interface *, struct req_pkt *, int); +static void mon_getlist_0 (sockaddr_u *, struct interface *, struct req_pkt *); +static void mon_getlist_1 (sockaddr_u *, struct interface *, struct req_pkt *); +static void reset_stats (sockaddr_u *, struct interface *, struct req_pkt *); +static void reset_peer (sockaddr_u *, struct interface *, struct req_pkt *); +static void do_key_reread (sockaddr_u *, struct interface *, struct req_pkt *); +static void trust_key (sockaddr_u *, struct interface *, struct req_pkt *); +static void untrust_key (sockaddr_u *, struct interface *, struct req_pkt *); +static void do_trustkey (sockaddr_u *, struct interface *, struct req_pkt *, u_long); +static void get_auth_info (sockaddr_u *, struct interface *, struct req_pkt *); +static void reset_auth_stats (void); +static void req_get_traps (sockaddr_u *, struct interface *, struct req_pkt *); +static void req_set_trap (sockaddr_u *, struct interface *, struct req_pkt *); +static void req_clr_trap (sockaddr_u *, struct interface *, struct req_pkt *); +static void do_setclr_trap (sockaddr_u *, struct interface *, struct req_pkt *, int); +static void set_request_keyid (sockaddr_u *, struct interface *, struct req_pkt *); +static void set_control_keyid (sockaddr_u *, struct interface *, struct req_pkt *); +static void get_ctl_stats (sockaddr_u *, struct interface *, struct req_pkt *); +static void get_if_stats (sockaddr_u *, struct interface *, struct req_pkt *); +static void do_if_reload (sockaddr_u *, struct interface *, struct req_pkt *); #ifdef KERNEL_PLL -static void get_kernel_info P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); +static void get_kernel_info (sockaddr_u *, struct interface *, struct req_pkt *); #endif /* KERNEL_PLL */ #ifdef REFCLOCK -static void get_clock_info P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void set_clock_fudge P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); +static void get_clock_info (sockaddr_u *, struct interface *, struct req_pkt *); +static void set_clock_fudge (sockaddr_u *, struct interface *, struct req_pkt *); #endif /* REFCLOCK */ #ifdef REFCLOCK -static void get_clkbug_info P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); +static void get_clkbug_info (sockaddr_u *, struct interface *, struct req_pkt *); #endif /* REFCLOCK */ /* @@ -216,7 +220,7 @@ static int databytes; static char exbuf[RESP_DATA_SIZE]; static int usingexbuf; -static struct sockaddr_storage *toaddr; +static sockaddr_u *toaddr; static struct interface *frominter; /* @@ -242,7 +246,7 @@ */ static void req_ack( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt, int errcode @@ -272,16 +276,13 @@ */ static char * prepare_pkt( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *pkt, - u_int structsize + size_t structsize ) { -#ifdef DEBUG - if (debug > 3) - printf("request: preparing pkt\n"); -#endif + DPRINTF(4, ("request: preparing pkt\n")); /* * Fill in the implementation, request and itemsize fields @@ -319,21 +320,18 @@ * If we were using the extra buffer, send the packet. */ if (usingexbuf) { -#ifdef DEBUG - if (debug > 2) - printf("request: sending pkt\n"); -#endif + DPRINTF(3, ("request: sending pkt\n")); rpkt.rm_vn_mode = RM_VN_MODE(RESP_BIT, MORE_BIT, reqver); rpkt.auth_seq = AUTH_SEQ(0, seqno); rpkt.err_nitems = htons((u_short)nitems); sendpkt(toaddr, frominter, -1, (struct pkt *)&rpkt, - RESP_HEADER_SIZE+databytes); + RESP_HEADER_SIZE + databytes); numresppkts++; /* * Copy data out of exbuf into the packet. */ - memmove(&rpkt.data[0], exbuf, (unsigned)itemsize); + memcpy(&rpkt.data[0], exbuf, (unsigned)itemsize); seqno++; databytes = 0; nitems = 0; @@ -343,10 +341,7 @@ databytes += itemsize; nitems++; if (databytes + itemsize <= RESP_DATA_SIZE) { -#ifdef DEBUG - if (debug > 3) - printf("request: giving him more data\n"); -#endif + DPRINTF(4, ("request: giving him more data\n")); /* * More room in packet. Give him the * next address. @@ -357,12 +352,9 @@ * No room in packet. Give him the extra * buffer unless this was the last in the sequence. */ -#ifdef DEBUG - if (debug > 3) - printf("request: into extra buffer\n"); -#endif + DPRINTF(4, ("request: into extra buffer\n")); if (seqno == MAXSEQ) - return (char *)0; + return NULL; else { usingexbuf = 1; return exbuf; @@ -377,17 +369,14 @@ static void flush_pkt(void) { -#ifdef DEBUG - if (debug > 2) - printf("request: flushing packet, %d items\n", nitems); -#endif + DPRINTF(3, ("request: flushing packet, %d items\n", nitems)); /* * Must send the last packet. If nothing in here and nothing * has been sent, send an error saying no data to be found. */ if (seqno == 0 && nitems == 0) - req_ack(toaddr, frominter, (struct req_pkt *)&rpkt, - INFO_ERR_NODATA); + req_ack(toaddr, frominter, (struct req_pkt *)&rpkt, + INFO_ERR_NODATA); else { rpkt.rm_vn_mode = RM_VN_MODE(RESP_BIT, 0, reqver); rpkt.auth_seq = AUTH_SEQ(0, seqno); @@ -401,6 +390,17 @@ /* + * Given a buffer, return the packet mode + */ +int +get_packet_mode(struct recvbuf *rbufp) +{ + struct req_pkt *inpkt = (struct req_pkt *)&rbufp->recv_pkt; + return (INFO_MODE(inpkt->rm_vn_mode)); +} + + +/* * process_private - process private mode (7) packets */ void @@ -412,24 +412,27 @@ static u_long quiet_until; struct req_pkt *inpkt; struct req_pkt_tail *tailinpkt; - struct sockaddr_storage *srcadr; + sockaddr_u *srcadr; struct interface *inter; struct req_proc *proc; int ec; short temp_size; + l_fp ftmp; + double dtemp; + size_t recv_len; + size_t noslop_len; + size_t mac_len; /* * Initialize pointers, for convenience */ + recv_len = rbufp->recv_length; inpkt = (struct req_pkt *)&rbufp->recv_pkt; srcadr = &rbufp->recv_srcadr; inter = rbufp->dstadr; -#ifdef DEBUG - if (debug > 2) - printf("process_private: impl %d req %d\n", - inpkt->implementation, inpkt->request); -#endif + DPRINTF(3, ("process_private: impl %d req %d\n", + inpkt->implementation, inpkt->request)); /* * Do some sanity checks on the packet. Return a format @@ -462,10 +465,10 @@ * Get the appropriate procedure list to search. */ if (inpkt->implementation == IMPL_UNIV) - proc = univ_codes; + proc = univ_codes; else if ((inpkt->implementation == IMPL_XNTPD) || (inpkt->implementation == IMPL_XNTPD_OLD)) - proc = ntp_codes; + proc = ntp_codes; else { req_ack(srcadr, inter, inpkt, INFO_ERR_IMPL); return; @@ -477,7 +480,7 @@ */ while (proc->request_code != NO_REQUEST) { if (proc->request_code == (short) inpkt->request) - break; + break; proc++; } if (proc->request_code == NO_REQUEST) { @@ -485,10 +488,7 @@ return; } -#ifdef DEBUG - if (debug > 3) - printf("found request in tables\n"); -#endif + DPRINTF(4, ("found request in tables\n")); /* * If we need data, check to see if we have some. If we @@ -507,21 +507,15 @@ !(inpkt->implementation == IMPL_XNTPD && inpkt->request == REQ_CONFIG && temp_size == sizeof(struct old_conf_peer))) { -#ifdef DEBUG - if (debug > 2) - printf("process_private: wrong item size, received %d, should be %d or %d\n", - temp_size, proc->sizeofitem, proc->v6_sizeofitem); -#endif + DPRINTF(3, ("process_private: wrong item size, received %d, should be %d or %d\n", + temp_size, proc->sizeofitem, proc->v6_sizeofitem)); req_ack(srcadr, inter, inpkt, INFO_ERR_FMT); return; } if ((proc->sizeofitem != 0) && - ((temp_size * INFO_NITEMS(inpkt->err_nitems)) > - (rbufp->recv_length - REQ_LEN_HDR))) { -#ifdef DEBUG - if (debug > 2) - printf("process_private: not enough data\n"); -#endif + ((size_t)(temp_size * INFO_NITEMS(inpkt->err_nitems)) > + (recv_len - REQ_LEN_HDR))) { + DPRINTF(3, ("process_private: not enough data\n")); req_ack(srcadr, inter, inpkt, INFO_ERR_FMT); return; } @@ -547,54 +541,74 @@ * time stamp. */ if (proc->needs_auth && sys_authenticate) { - l_fp ftmp; - double dtemp; - - if (rbufp->recv_length < (int)((REQ_LEN_HDR + + + if (recv_len < (REQ_LEN_HDR + (INFO_ITEMSIZE(inpkt->mbz_itemsize) * - INFO_NITEMS(inpkt->err_nitems)) - + sizeof(struct req_pkt_tail)))) { + INFO_NITEMS(inpkt->err_nitems)) + + REQ_TAIL_MIN)) { req_ack(srcadr, inter, inpkt, INFO_ERR_FMT); + return; } - tailinpkt = (struct req_pkt_tail *)((char *)&rbufp->recv_pkt + - rbufp->recv_length - sizeof(struct req_pkt_tail)); /* - * If this guy is restricted from doing this, don't let him - * If wrong key was used, or packet doesn't have mac, return. + * For 16-octet digests, regardless of itemsize and + * nitems, authenticated requests are a fixed size + * with the timestamp, key ID, and digest located + * at the end of the packet. Because the key ID + * determining the digest size precedes the digest, + * for larger digests the fixed size request scheme + * is abandoned and the timestamp, key ID, and digest + * are located relative to the start of the packet, + * with the digest size determined by the packet size. */ - if (!INFO_IS_AUTH(inpkt->auth_seq) || info_auth_keyid == 0 + noslop_len = REQ_LEN_HDR + + INFO_ITEMSIZE(inpkt->mbz_itemsize) * + INFO_NITEMS(inpkt->err_nitems) + + sizeof(inpkt->tstamp); + /* 32-bit alignment */ + noslop_len = (noslop_len + 3) & ~3; + if (recv_len > (noslop_len + MAX_MAC_LEN)) + mac_len = 20; + else + mac_len = recv_len - noslop_len; + + tailinpkt = (void *)((char *)inpkt + recv_len - + (mac_len + sizeof(inpkt->tstamp))); + + /* + * If this guy is restricted from doing this, don't let + * him. If the wrong key was used, or packet doesn't + * have mac, return. + */ + if (!INFO_IS_AUTH(inpkt->auth_seq) || !info_auth_keyid || ntohl(tailinpkt->keyid) != info_auth_keyid) { + DPRINTF(5, ("failed auth %d info_auth_keyid %u pkt keyid %u maclen %lu\n", + INFO_IS_AUTH(inpkt->auth_seq), + info_auth_keyid, + ntohl(tailinpkt->keyid), (u_long)mac_len)); #ifdef DEBUG - if (debug > 4) - printf("failed auth %d info_auth_keyid %lu pkt keyid %lu\n", - INFO_IS_AUTH(inpkt->auth_seq), - (u_long)info_auth_keyid, - (u_long)ntohl(tailinpkt->keyid)); msyslog(LOG_DEBUG, - "process_private: failed auth %d info_auth_keyid %lu pkt keyid %lu\n", + "process_private: failed auth %d info_auth_keyid %u pkt keyid %u maclen %lu\n", INFO_IS_AUTH(inpkt->auth_seq), - (u_long)info_auth_keyid, - (u_long)ntohl(tailinpkt->keyid)); + info_auth_keyid, + ntohl(tailinpkt->keyid), (u_long)mac_len); #endif req_ack(srcadr, inter, inpkt, INFO_ERR_AUTH); return; } - if (rbufp->recv_length > REQ_LEN_MAC) { -#ifdef DEBUG - if (debug > 4) - printf("bad pkt length %d\n", - rbufp->recv_length); -#endif - msyslog(LOG_ERR, "process_private: bad pkt length %d", - rbufp->recv_length); + if (recv_len > REQ_LEN_NOMAC + MAX_MAC_LEN) { + DPRINTF(5, ("bad pkt length %lu\n", + (u_long)recv_len)); + msyslog(LOG_ERR, + "process_private: bad pkt length %lu", + (u_long)recv_len); req_ack(srcadr, inter, inpkt, INFO_ERR_FMT); return; } if (!mod_okay || !authhavekey(info_auth_keyid)) { + DPRINTF(5, ("failed auth mod_okay %d\n", + mod_okay)); #ifdef DEBUG - if (debug > 4) - printf("failed auth mod_okay %d\n", mod_okay); msyslog(LOG_DEBUG, "process_private: failed auth mod_okay %d\n", mod_okay); @@ -610,14 +624,12 @@ NTOHL_FP(&tailinpkt->tstamp, &ftmp); L_SUB(&ftmp, &rbufp->recv_time); LFPTOD(&ftmp, dtemp); - if (fabs(dtemp) >= INFO_TS_MAXSKEW) { + if (fabs(dtemp) > INFO_TS_MAXSKEW) { /* * He's a loser. Tell him. */ -#ifdef DEBUG - if (debug > 4) - printf("xmit/rcv timestamp delta > INFO_TS_MAXSKEW\n"); -#endif + DPRINTF(5, ("xmit/rcv timestamp delta %g > INFO_TS_MAXSKEW %g\n", + dtemp, INFO_TS_MAXSKEW)); req_ack(srcadr, inter, inpkt, INFO_ERR_AUTH); return; } @@ -626,22 +638,14 @@ * So far so good. See if decryption works out okay. */ if (!authdecrypt(info_auth_keyid, (u_int32 *)inpkt, - rbufp->recv_length - sizeof(struct req_pkt_tail) + - REQ_LEN_HDR, sizeof(struct req_pkt_tail) - REQ_LEN_HDR)) { -#ifdef DEBUG - if (debug > 4) - printf("authdecrypt failed\n"); -#endif + recv_len - mac_len, mac_len)) { + DPRINTF(5, ("authdecrypt failed\n")); req_ack(srcadr, inter, inpkt, INFO_ERR_AUTH); return; } } -#ifdef DEBUG - if (debug > 3) - printf("process_private: all okay, into handler\n"); -#endif - + DPRINTF(3, ("process_private: all okay, into handler\n")); /* * Packet is okay. Call the handler to send him data. */ @@ -654,7 +658,7 @@ */ static void peer_list( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -669,9 +673,9 @@ for (i = 0; i < NTP_HASH_SIZE && ip != 0; i++) { pp = peer_hash[i]; while (pp != 0 && ip != 0) { - if (pp->srcadr.ss_family == AF_INET6) { + if (IS_IPV6(&pp->srcadr)) { if (client_v6_capable) { - ip->addr6 = GET_INADDR6(pp->srcadr); + ip->addr6 = SOCK_ADDR6(&pp->srcadr); ip->v6_flag = 1; skip = 0; } else { @@ -679,7 +683,7 @@ break; } } else { - ip->addr = GET_INADDR(pp->srcadr); + ip->addr = NSRCADR(&pp->srcadr); if (client_v6_capable) ip->v6_flag = 0; skip = 0; @@ -711,7 +715,7 @@ */ static void peer_list_sum( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -739,12 +743,12 @@ * Be careful here not to return v6 peers when we * want only v4. */ - if (pp->srcadr.ss_family == AF_INET6) { + if (IS_IPV6(&pp->srcadr)) { if (client_v6_capable) { - ips->srcadr6 = GET_INADDR6(pp->srcadr); + ips->srcadr6 = SOCK_ADDR6(&pp->srcadr); ips->v6_flag = 1; if (pp->dstadr) - ips->dstadr6 = GET_INADDR6(pp->dstadr->sin); + ips->dstadr6 = SOCK_ADDR6(&pp->dstadr->sin); else memset(&ips->dstadr6, 0, sizeof(ips->dstadr6)); skip = 0; @@ -753,22 +757,24 @@ break; } } else { - ips->srcadr = GET_INADDR(pp->srcadr); + ips->srcadr = NSRCADR(&pp->srcadr); if (client_v6_capable) ips->v6_flag = 0; -/* XXX PDM This code is buggy. Need to replace with a straightforward assignment */ - if (pp->dstadr) - ips->dstadr = (pp->processed) ? - pp->cast_flags == MDF_BCAST ? - GET_INADDR(pp->dstadr->bcast): - pp->cast_flags ? - GET_INADDR(pp->dstadr->sin) ? - GET_INADDR(pp->dstadr->sin): - GET_INADDR(pp->dstadr->bcast): - 1 : GET_INADDR(pp->dstadr->sin); - else - memset(&ips->dstadr, 0, sizeof(ips->dstadr)); + if (pp->dstadr) { + if (!pp->processed) + ips->dstadr = NSRCADR(&pp->dstadr->sin); + else { + if (MDF_BCAST == pp->cast_flags) + ips->dstadr = NSRCADR(&pp->dstadr->bcast); + else if (pp->cast_flags) { + ips->dstadr = NSRCADR(&pp->dstadr->sin); + if (!ips->dstadr) + ips->dstadr = NSRCADR(&pp->dstadr->bcast); + } + } + } else + ips->dstadr = 0; skip = 0; } @@ -786,8 +792,6 @@ ips->flags |= INFO_FLAG_CONFIG; if (pp->flags & FLAG_REFCLOCK) ips->flags |= INFO_FLAG_REFCLOCK; - if (pp->flags & FLAG_AUTHENABLE) - ips->flags |= INFO_FLAG_AUTHENABLE; if (pp->flags & FLAG_PREFER) ips->flags |= INFO_FLAG_PREFER; if (pp->flags & FLAG_BURST) @@ -815,7 +819,7 @@ */ static void peer_info ( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -825,57 +829,59 @@ register struct info_peer *ip; register int items; register int i, j; - struct sockaddr_storage addr; + sockaddr_u addr; extern struct peer *sys_peer; l_fp ltmp; - memset((char *)&addr, 0, sizeof addr); items = INFO_NITEMS(inpkt->err_nitems); ipl = (struct info_peer_list *) inpkt->data; ip = (struct info_peer *)prepare_pkt(srcadr, inter, inpkt, v6sizeof(struct info_peer)); while (items-- > 0 && ip != 0) { - memset((char *)&addr, 0, sizeof(addr)); + ZERO_SOCK(&addr); NSRCPORT(&addr) = ipl->port; - if (client_v6_capable && ipl->v6_flag != 0) { - addr.ss_family = AF_INET6; - GET_INADDR6(addr) = ipl->addr6; + if (client_v6_capable && ipl->v6_flag) { + AF(&addr) = AF_INET6; + SOCK_ADDR6(&addr) = ipl->addr6; } else { - addr.ss_family = AF_INET; - GET_INADDR(addr) = ipl->addr; + AF(&addr) = AF_INET; + NSRCADR(&addr) = ipl->addr; } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - addr.ss_len = SOCKLEN(&addr); +#ifdef ISC_PLATFORM_HAVESALEN + addr.sa.sa_len = SOCKLEN(&addr); #endif ipl++; if ((pp = findexistingpeer(&addr, (struct peer *)0, -1)) == 0) - continue; - if (pp->srcadr.ss_family == AF_INET6) { + continue; + if (IS_IPV6(srcadr)) { if (pp->dstadr) - ip->dstadr6 = pp->cast_flags == MDF_BCAST ? - GET_INADDR6(pp->dstadr->bcast) : - GET_INADDR6(pp->dstadr->sin); + ip->dstadr6 = + (MDF_BCAST == pp->cast_flags) + ? SOCK_ADDR6(&pp->dstadr->bcast) + : SOCK_ADDR6(&pp->dstadr->sin); else memset(&ip->dstadr6, 0, sizeof(ip->dstadr6)); - ip->srcadr6 = GET_INADDR6(pp->srcadr); + ip->srcadr6 = SOCK_ADDR6(&pp->srcadr); ip->v6_flag = 1; } else { -/* XXX PDM This code is buggy. Need to replace with a straightforward assignment */ - if (pp->dstadr) - ip->dstadr = (pp->processed) ? - pp->cast_flags == MDF_BCAST ? - GET_INADDR(pp->dstadr->bcast): - pp->cast_flags ? - GET_INADDR(pp->dstadr->sin) ? - GET_INADDR(pp->dstadr->sin): - GET_INADDR(pp->dstadr->bcast): - 2 : GET_INADDR(pp->dstadr->sin); - else - memset(&ip->dstadr, 0, sizeof(ip->dstadr)); + if (pp->dstadr) { + if (!pp->processed) + ip->dstadr = NSRCADR(&pp->dstadr->sin); + else { + if (MDF_BCAST == pp->cast_flags) + ip->dstadr = NSRCADR(&pp->dstadr->bcast); + else if (pp->cast_flags) { + ip->dstadr = NSRCADR(&pp->dstadr->sin); + if (!ip->dstadr) + ip->dstadr = NSRCADR(&pp->dstadr->bcast); + } + } + } else + ip->dstadr = 0; - ip->srcadr = GET_INADDR(pp->srcadr); + ip->srcadr = NSRCADR(&pp->srcadr); if (client_v6_capable) ip->v6_flag = 0; } @@ -887,8 +893,6 @@ ip->flags |= INFO_FLAG_CONFIG; if (pp->flags & FLAG_REFCLOCK) ip->flags |= INFO_FLAG_REFCLOCK; - if (pp->flags & FLAG_AUTHENABLE) - ip->flags |= INFO_FLAG_AUTHENABLE; if (pp->flags & FLAG_PREFER) ip->flags |= INFO_FLAG_PREFER; if (pp->flags & FLAG_BURST) @@ -909,14 +913,14 @@ ip->unreach = (u_char) pp->unreach; ip->flash = (u_char)pp->flash; ip->flash2 = (u_short) pp->flash; - ip->estbdelay = HTONS_FP(DTOFP(pp->estbdelay)); + ip->estbdelay = HTONS_FP(DTOFP(pp->delay)); ip->ttl = pp->ttl; ip->associd = htons(pp->associd); ip->rootdelay = HTONS_FP(DTOUFP(pp->rootdelay)); - ip->rootdispersion = HTONS_FP(DTOUFP(pp->rootdispersion)); + ip->rootdispersion = HTONS_FP(DTOUFP(pp->rootdisp)); ip->refid = pp->refid; HTONL_FP(&pp->reftime, &ip->reftime); - HTONL_FP(&pp->org, &ip->org); + HTONL_FP(&pp->aorg, &ip->org); HTONL_FP(&pp->rec, &ip->rec); HTONL_FP(&pp->xmt, &ip->xmt); j = pp->filter_nextpt - 1; @@ -947,7 +951,7 @@ */ static void peer_stats ( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -956,7 +960,7 @@ register struct peer *pp; register struct info_peer_stats *ip; register int items; - struct sockaddr_storage addr; + sockaddr_u addr; extern struct peer *sys_peer; #ifdef DEBUG @@ -971,54 +975,55 @@ memset((char *)&addr, 0, sizeof(addr)); NSRCPORT(&addr) = ipl->port; if (client_v6_capable && ipl->v6_flag) { - addr.ss_family = AF_INET6; - GET_INADDR6(addr) = ipl->addr6; + AF(&addr) = AF_INET6; + SOCK_ADDR6(&addr) = ipl->addr6; } else { - addr.ss_family = AF_INET; - GET_INADDR(addr) = ipl->addr; + AF(&addr) = AF_INET; + NSRCADR(&addr) = ipl->addr; } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - addr.ss_len = SOCKLEN(&addr); -#endif -#ifdef DEBUG - if (debug) - printf("peer_stats: looking for %s, %d, %d\n", stoa(&addr), - ipl->port, ((struct sockaddr_in6 *)&addr)->sin6_port); +#ifdef ISC_PLATFORM_HAVESALEN + addr.sa.sa_len = SOCKLEN(&addr); #endif + DPRINTF(1, ("peer_stats: looking for %s, %d, %d\n", + stoa(&addr), ipl->port, NSRCPORT(&addr))); + ipl = (struct info_peer_list *)((char *)ipl + INFO_ITEMSIZE(inpkt->mbz_itemsize)); - if ((pp = findexistingpeer(&addr, (struct peer *)0, -1)) == 0) - continue; -#ifdef DEBUG - if (debug) - printf("peer_stats: found %s\n", stoa(&addr)); -#endif - if (pp->srcadr.ss_family == AF_INET) { - if (pp->dstadr) - ip->dstadr = (pp->processed) ? - pp->cast_flags == MDF_BCAST ? - GET_INADDR(pp->dstadr->bcast): - pp->cast_flags ? - GET_INADDR(pp->dstadr->sin) ? - GET_INADDR(pp->dstadr->sin): - GET_INADDR(pp->dstadr->bcast): - 3 : 7; - else - memset(&ip->dstadr, 0, sizeof(ip->dstadr)); + if ((pp = findexistingpeer(&addr, (struct peer *)0, -1)) == NULL) + continue; + + DPRINTF(1, ("peer_stats: found %s\n", stoa(&addr))); + + if (IS_IPV4(&pp->srcadr)) { + if (pp->dstadr) { + if (!pp->processed) + ip->dstadr = NSRCADR(&pp->dstadr->sin); + else { + if (MDF_BCAST == pp->cast_flags) + ip->dstadr = NSRCADR(&pp->dstadr->bcast); + else if (pp->cast_flags) { + ip->dstadr = NSRCADR(&pp->dstadr->sin); + if (!ip->dstadr) + ip->dstadr = NSRCADR(&pp->dstadr->bcast); + } + } + } else + ip->dstadr = 0; - ip->srcadr = GET_INADDR(pp->srcadr); + ip->srcadr = NSRCADR(&pp->srcadr); if (client_v6_capable) ip->v6_flag = 0; } else { if (pp->dstadr) - ip->dstadr6 = pp->cast_flags == MDF_BCAST ? - GET_INADDR6(pp->dstadr->bcast): - GET_INADDR6(pp->dstadr->sin); + ip->dstadr6 = + (MDF_BCAST == pp->cast_flags) + ? SOCK_ADDR6(&pp->dstadr->bcast) + : SOCK_ADDR6(&pp->dstadr->sin); else memset(&ip->dstadr6, 0, sizeof(ip->dstadr6)); - - ip->srcadr6 = GET_INADDR6(pp->srcadr); + + ip->srcadr6 = SOCK_ADDR6(&pp->srcadr); ip->v6_flag = 1; } ip->srcport = NSRCPORT(&pp->srcadr); @@ -1029,8 +1034,6 @@ ip->flags |= INFO_FLAG_CONFIG; if (pp->flags & FLAG_REFCLOCK) ip->flags |= INFO_FLAG_REFCLOCK; - if (pp->flags & FLAG_AUTHENABLE) - ip->flags |= INFO_FLAG_AUTHENABLE; if (pp->flags & FLAG_PREFER) ip->flags |= INFO_FLAG_PREFER; if (pp->flags & FLAG_BURST) @@ -1064,7 +1067,7 @@ */ static void sys_info( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -1074,13 +1077,13 @@ is = (struct info_sys *)prepare_pkt(srcadr, inter, inpkt, v6sizeof(struct info_sys)); - if (sys_peer != 0) { - if (sys_peer->srcadr.ss_family == AF_INET) { - is->peer = GET_INADDR(sys_peer->srcadr); + if (sys_peer) { + if (IS_IPV4(&sys_peer->srcadr)) { + is->peer = NSRCADR(&sys_peer->srcadr); if (client_v6_capable) is->v6_flag = 0; } else if (client_v6_capable) { - is->peer6 = GET_INADDR6(sys_peer->srcadr); + is->peer6 = SOCK_ADDR6(&sys_peer->srcadr); is->v6_flag = 1; } is->peer_mode = sys_peer->hmode; @@ -1096,7 +1099,7 @@ is->stratum = sys_stratum; is->precision = sys_precision; is->rootdelay = htonl(DTOFP(sys_rootdelay)); - is->rootdispersion = htonl(DTOUFP(sys_rootdispersion)); + is->rootdispersion = htonl(DTOUFP(sys_rootdisp)); is->frequency = htonl(DTOFP(sys_jitter)); is->stability = htonl(DTOUFP(clock_stability)); is->refid = sys_refid; @@ -1125,7 +1128,6 @@ is->flags |= INFO_FLAG_FILEGEN; is->bdelay = HTONS_FP(DTOFP(sys_bdelay)); HTONL_UF(sys_authdelay.l_f, &is->authdelay); - (void) more_pkt(); flush_pkt(); } @@ -1136,7 +1138,7 @@ */ static void sys_stats( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -1151,9 +1153,9 @@ ss->timeup = htonl((u_int32)current_time); ss->timereset = htonl((u_int32)(current_time - sys_stattime)); ss->denied = htonl((u_int32)sys_restricted); - ss->oldversionpkt = htonl((u_int32)sys_oldversionpkt); - ss->newversionpkt = htonl((u_int32)sys_newversionpkt); - ss->unknownversion = htonl((u_int32)sys_unknownversion); + ss->oldversionpkt = htonl((u_int32)sys_oldversion); + ss->newversionpkt = htonl((u_int32)sys_newversion); + ss->unknownversion = htonl((u_int32)sys_declined); ss->badlength = htonl((u_int32)sys_badlength); ss->processed = htonl((u_int32)sys_processed); ss->badauth = htonl((u_int32)sys_badauth); @@ -1169,7 +1171,7 @@ */ static void mem_stats( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -1215,7 +1217,7 @@ */ static void io_stats( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -1253,7 +1255,7 @@ */ static void timer_stats( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -1285,7 +1287,7 @@ */ static void loop_info( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -1299,7 +1301,7 @@ extern double last_offset; extern double drift_comp; extern int tc_counter; - extern u_long sys_clocktime; + extern u_long sys_epoch; li = (struct info_loop *)prepare_pkt(srcadr, inter, inpkt, sizeof(struct info_loop)); @@ -1309,7 +1311,7 @@ DTOLFP(drift_comp * 1e6, <mp); HTONL_FP(<mp, &li->drift_comp); li->compliance = htonl((u_int32)(tc_counter)); - li->watchdog_timer = htonl((u_int32)(current_time - sys_clocktime)); + li->watchdog_timer = htonl((u_int32)(current_time - sys_epoch)); (void) more_pkt(); flush_pkt(); @@ -1321,7 +1323,7 @@ */ static void do_conf( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -1331,8 +1333,7 @@ u_int fl; struct conf_peer *cp; struct conf_peer temp_cp; - struct sockaddr_storage peeraddr; - struct sockaddr_in tmp_clock; + sockaddr_u peeraddr; /* * Do a check of everything to see that it looks @@ -1343,6 +1344,8 @@ cp = (struct conf_peer *)inpkt->data; memset(&temp_cp, 0, sizeof(struct conf_peer)); memcpy(&temp_cp, (char *)cp, INFO_ITEMSIZE(inpkt->mbz_itemsize)); + +#if 0 /* paranoid checking - these are done in newpeer() */ fl = 0; while (items-- > 0 && !fl) { if (((temp_cp.version) > NTP_VERSION) @@ -1352,9 +1355,9 @@ && temp_cp.hmode != MODE_CLIENT && temp_cp.hmode != MODE_BROADCAST) fl = 1; - if (temp_cp.flags & ~(CONF_FLAG_AUTHENABLE | CONF_FLAG_PREFER - | CONF_FLAG_BURST | CONF_FLAG_IBURST | CONF_FLAG_SKEY)) - fl = 1; + if (temp_cp.flags & ~(CONF_FLAG_PREFER | CONF_FLAG_BURST | + CONF_FLAG_IBURST | CONF_FLAG_SKEY)) + fl = 1; cp = (struct conf_peer *) ((char *)cp + INFO_ITEMSIZE(inpkt->mbz_itemsize)); } @@ -1363,6 +1366,7 @@ req_ack(srcadr, inter, inpkt, INFO_ERR_FMT); return; } +#endif /* end paranoid checking */ /* * Looks okay, try it out @@ -1373,43 +1377,38 @@ while (items-- > 0) { memset(&temp_cp, 0, sizeof(struct conf_peer)); memcpy(&temp_cp, (char *)cp, INFO_ITEMSIZE(inpkt->mbz_itemsize)); - memset((char *)&peeraddr, 0, sizeof(struct sockaddr_storage)); + ZERO_SOCK(&peeraddr); fl = 0; - if (temp_cp.flags & CONF_FLAG_AUTHENABLE) - fl |= FLAG_AUTHENABLE; if (temp_cp.flags & CONF_FLAG_PREFER) fl |= FLAG_PREFER; if (temp_cp.flags & CONF_FLAG_BURST) fl |= FLAG_BURST; if (temp_cp.flags & CONF_FLAG_IBURST) fl |= FLAG_IBURST; +#ifdef OPENSSL if (temp_cp.flags & CONF_FLAG_SKEY) fl |= FLAG_SKEY; - +#endif /* OPENSSL */ if (client_v6_capable && temp_cp.v6_flag != 0) { - peeraddr.ss_family = AF_INET6; - GET_INADDR6(peeraddr) = temp_cp.peeraddr6; + AF(&peeraddr) = AF_INET6; + SOCK_ADDR6(&peeraddr) = temp_cp.peeraddr6; } else { - peeraddr.ss_family = AF_INET; - GET_INADDR(peeraddr) = temp_cp.peeraddr; + AF(&peeraddr) = AF_INET; + NSRCADR(&peeraddr) = temp_cp.peeraddr; /* * Make sure the address is valid */ - tmp_clock = *CAST_V4(peeraddr); - if ( -#ifdef REFCLOCK - !ISREFCLOCKADR(&tmp_clock) && -#endif - ISBADADR(&tmp_clock)) { + if (!ISREFCLOCKADR(&peeraddr) && + ISBADADR(&peeraddr)) { req_ack(srcadr, inter, inpkt, INFO_ERR_FMT); return; } } NSRCPORT(&peeraddr) = htons(NTP_PORT); -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - peeraddr.ss_len = SOCKLEN(&peeraddr); +#ifdef ISC_PLATFORM_HAVESALEN + peeraddr.sa.sa_len = SOCKLEN(&peeraddr); #endif /* XXX W2DO? minpoll/maxpoll arguments ??? */ @@ -1451,7 +1450,7 @@ */ static void dns_a( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -1480,16 +1479,8 @@ /* * Make sure the address is valid */ - if ( -#ifdef REFCLOCK - !ISREFCLOCKADR(&peeraddr) && -#endif - ISBADADR(&peeraddr)) { -#ifdef REFCLOCK - msyslog(LOG_ERR, "dns_a: !ISREFCLOCK && ISBADADR"); -#else - msyslog(LOG_ERR, "dns_a: ISBADADR"); -#endif + if (!ISREFCLOCKADR(&peeraddr) && ISBADADR(&peeraddr)) { + msyslog(LOG_ERR, "dns_a: !ISREFCLOCKADR && ISBADADR"); req_ack(srcadr, inter, inpkt, INFO_ERR_FMT); return; } @@ -1519,7 +1510,7 @@ msyslog(LOG_INFO, "dns_a: <%s> for %s, AssocID %d, bogon %d", dp->hostname, - stoa((struct sockaddr_storage *)&peeraddr), associd, + stoa((sockaddr_u *)&peeraddr), associd, bogon); if (bogon) { @@ -1546,7 +1537,7 @@ */ static void do_unconf( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -1555,7 +1546,7 @@ struct conf_unpeer temp_cp; register int items; register struct peer *peer; - struct sockaddr_storage peeraddr; + sockaddr_u peeraddr; int bad, found; /* @@ -1570,36 +1561,35 @@ bad = 0; while (items-- > 0 && !bad) { memset(&temp_cp, 0, sizeof(temp_cp)); - memset(&peeraddr, 0, sizeof(peeraddr)); + ZERO_SOCK(&peeraddr); memcpy(&temp_cp, cp, INFO_ITEMSIZE(inpkt->mbz_itemsize)); - if (client_v6_capable && temp_cp.v6_flag != 0) { - peeraddr.ss_family = AF_INET6; - GET_INADDR6(peeraddr) = temp_cp.peeraddr6; + if (client_v6_capable && temp_cp.v6_flag) { + AF(&peeraddr) = AF_INET6; + SOCK_ADDR6(&peeraddr) = temp_cp.peeraddr6; } else { - peeraddr.ss_family = AF_INET; - GET_INADDR(peeraddr) = temp_cp.peeraddr; + AF(&peeraddr) = AF_INET; + NSRCADR(&peeraddr) = temp_cp.peeraddr; } - NSRCPORT(&peeraddr) = htons(NTP_PORT); -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - peeraddr.ss_len = SOCKLEN(&peeraddr); + SET_PORT(&peeraddr, NTP_PORT); +#ifdef ISC_PLATFORM_HAVESALEN + peeraddr.sa.sa_len = SOCKLEN(&peeraddr); #endif found = 0; - peer = (struct peer *)0; -#ifdef DEBUG - if (debug) - printf("searching for %s\n", stoa(&peeraddr)); -#endif + peer = NULL; + + DPRINTF(1, ("searching for %s\n", stoa(&peeraddr))); + while (!found) { peer = findexistingpeer(&peeraddr, peer, -1); - if (peer == (struct peer *)0) - break; + if (!peer) + break; if (peer->flags & FLAG_CONFIG) - found = 1; + found = 1; } if (!found) - bad = 1; + bad = 1; cp = (struct conf_unpeer *) - ((char *)cp + INFO_ITEMSIZE(inpkt->mbz_itemsize)); + ((char *)cp + INFO_ITEMSIZE(inpkt->mbz_itemsize)); } if (bad) { @@ -1613,24 +1603,40 @@ items = INFO_NITEMS(inpkt->err_nitems); cp = (struct conf_unpeer *)inpkt->data; + while (items-- > 0) { memset(&temp_cp, 0, sizeof(temp_cp)); memset(&peeraddr, 0, sizeof(peeraddr)); memcpy(&temp_cp, cp, INFO_ITEMSIZE(inpkt->mbz_itemsize)); - if (client_v6_capable && temp_cp.v6_flag != 0) { - peeraddr.ss_family = AF_INET6; - GET_INADDR6(peeraddr) = temp_cp.peeraddr6; + if (client_v6_capable && temp_cp.v6_flag) { + AF(&peeraddr) = AF_INET6; + SOCK_ADDR6(&peeraddr) = temp_cp.peeraddr6; } else { - peeraddr.ss_family = AF_INET; - GET_INADDR(peeraddr) = temp_cp.peeraddr; + AF(&peeraddr) = AF_INET; + NSRCADR(&peeraddr) = temp_cp.peeraddr; } - NSRCPORT(&peeraddr) = htons(NTP_PORT); -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - peeraddr.ss_len = SOCKLEN(&peeraddr); + SET_PORT(&peeraddr, NTP_PORT); +#ifdef ISC_PLATFORM_HAVESALEN + peeraddr.sa.sa_len = SOCKLEN(&peeraddr); #endif - peer_unconfig(&peeraddr, (struct interface *)0, -1); + found = 0; + peer = NULL; + + while (!found) { + peer = findexistingpeer(&peeraddr, peer, -1); + if (!peer) + break; + if (peer->flags & FLAG_CONFIG) + found = 1; + } + NTP_INSIST(found); + NTP_INSIST(peer); + + peer_clear(peer, "GONE"); + unpeer(peer); + cp = (struct conf_unpeer *) - ((char *)cp + INFO_ITEMSIZE(inpkt->mbz_itemsize)); + ((char *)cp + INFO_ITEMSIZE(inpkt->mbz_itemsize)); } req_ack(srcadr, inter, inpkt, INFO_OKAY); @@ -1642,7 +1648,7 @@ */ static void set_sys_flag( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -1656,7 +1662,7 @@ */ static void clr_sys_flag( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -1670,7 +1676,7 @@ */ static void setclr_flags( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt, u_long set @@ -1726,60 +1732,95 @@ loop_config(LOOP_DRIFTCOMP, drift_comp); } +/* + * list_restrict4 - recursive helper for list_restrict dumps IPv4 + * restriction list in reverse order. + */ +static void +list_restrict4( + restrict_u * res, + struct info_restrict ** ppir + ) +{ + struct info_restrict * pir; + + if (res->link != NULL) + list_restrict4(res->link, ppir); + + pir = *ppir; + pir->addr = htonl(res->u.v4.addr); + if (client_v6_capable) + pir->v6_flag = 0; + pir->mask = htonl(res->u.v4.mask); + pir->count = htonl(res->count); + pir->flags = htons(res->flags); + pir->mflags = htons(res->mflags); + *ppir = (struct info_restrict *)more_pkt(); +} + + +/* + * list_restrict6 - recursive helper for list_restrict dumps IPv6 + * restriction list in reverse order. + */ +static void +list_restrict6( + restrict_u * res, + struct info_restrict ** ppir + ) +{ + struct info_restrict * pir; + + if (res->link != NULL) + list_restrict6(res->link, ppir); + + pir = *ppir; + pir->addr6 = res->u.v6.addr; + pir->mask6 = res->u.v6.mask; + pir->v6_flag = 1; + pir->count = htonl(res->count); + pir->flags = htons(res->flags); + pir->mflags = htons(res->mflags); + *ppir = (struct info_restrict *)more_pkt(); +} + /* * list_restrict - return the restrict list */ static void list_restrict( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) { - register struct info_restrict *ir; - register struct restrictlist *rl; - register struct restrictlist6 *rl6; + struct info_restrict *ir; -#ifdef DEBUG - if (debug > 2) - printf("wants restrict list summary\n"); -#endif + DPRINTF(3, ("wants restrict list summary\n")); ir = (struct info_restrict *)prepare_pkt(srcadr, inter, inpkt, v6sizeof(struct info_restrict)); - for (rl = restrictlist; rl != 0 && ir != 0; rl = rl->next) { - ir->addr = htonl(rl->addr); - if (client_v6_capable) - ir->v6_flag = 0; - ir->mask = htonl(rl->mask); - ir->count = htonl((u_int32)rl->count); - ir->flags = htons(rl->flags); - ir->mflags = htons(rl->mflags); - ir = (struct info_restrict *)more_pkt(); - } + /* + * The restriction lists are kept sorted in the reverse order + * than they were originally. To preserve the output semantics, + * dump each list in reverse order. A recursive helper function + * achieves that. + */ + list_restrict4(restrictlist4, &ir); if (client_v6_capable) - for (rl6 = restrictlist6; rl6 != 0 && ir != 0; rl6 = rl6->next) { - ir->addr6 = rl6->addr6; - ir->mask6 = rl6->mask6; - ir->v6_flag = 1; - ir->count = htonl((u_int32)rl6->count); - ir->flags = htons(rl6->flags); - ir->mflags = htons(rl6->mflags); - ir = (struct info_restrict *)more_pkt(); - } + list_restrict6(restrictlist6, &ir); flush_pkt(); } - /* * do_resaddflags - add flags to a restrict entry (or create one) */ static void do_resaddflags( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -1794,7 +1835,7 @@ */ static void do_ressubflags( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -1808,7 +1849,7 @@ */ static void do_unrestrict( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -1817,15 +1858,12 @@ } - - - /* * do_restrict - do the dirty stuff of dealing with restrictions */ static void do_restrict( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt, int op @@ -1833,8 +1871,8 @@ { register struct conf_restrict *cr; register int items; - struct sockaddr_storage matchaddr; - struct sockaddr_storage matchmask; + sockaddr_u matchaddr; + sockaddr_u matchmask; int bad; /* @@ -1876,20 +1914,20 @@ */ items = INFO_NITEMS(inpkt->err_nitems); cr = (struct conf_restrict *)inpkt->data; - memset((char *)&matchaddr, 0, sizeof(struct sockaddr_storage)); - memset((char *)&matchmask, 0, sizeof(struct sockaddr_storage)); + ZERO_SOCK(&matchaddr); + ZERO_SOCK(&matchmask); while (items-- > 0) { - if (client_v6_capable && cr->v6_flag != 0) { - GET_INADDR6(matchaddr) = cr->addr6; - GET_INADDR6(matchmask) = cr->mask6; - matchaddr.ss_family = AF_INET6; - matchmask.ss_family = AF_INET6; + if (client_v6_capable && cr->v6_flag) { + AF(&matchaddr) = AF_INET6; + AF(&matchmask) = AF_INET6; + SOCK_ADDR6(&matchaddr) = cr->addr6; + SOCK_ADDR6(&matchmask) = cr->mask6; } else { - GET_INADDR(matchaddr) = cr->addr; - GET_INADDR(matchmask) = cr->mask; - matchaddr.ss_family = AF_INET; - matchmask.ss_family = AF_INET; + AF(&matchaddr) = AF_INET; + AF(&matchmask) = AF_INET; + NSRCADR(&matchaddr) = cr->addr; + NSRCADR(&matchmask) = cr->mask; } hack_restrict(op, &matchaddr, &matchmask, cr->mflags, cr->flags); @@ -1905,7 +1943,7 @@ */ static void mon_getlist_0( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -1927,17 +1965,18 @@ v6sizeof(struct info_monitor)); for (md = mon_mru_list.mru_next; md != &mon_mru_list && im != 0; md = md->mru_next) { - im->lasttime = htonl((u_int32)md->avg_interval); + im->lasttime = htonl((u_int32)((current_time - + md->firsttime) / md->count)); im->firsttime = htonl((u_int32)(current_time - md->lasttime)); - im->lastdrop = htonl((u_int32)md->drop_count); + im->restr = htonl((u_int32)md->flags); im->count = htonl((u_int32)(md->count)); - if (md->rmtadr.ss_family == AF_INET6) { + if (IS_IPV6(&md->rmtadr)) { if (!client_v6_capable) continue; - im->addr6 = GET_INADDR6(md->rmtadr); + im->addr6 = SOCK_ADDR6(&md->rmtadr); im->v6_flag = 1; } else { - im->addr = GET_INADDR(md->rmtadr); + im->addr = NSRCADR(&md->rmtadr); if (client_v6_capable) im->v6_flag = 0; } @@ -1954,7 +1993,7 @@ */ static void mon_getlist_1( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -1972,27 +2011,29 @@ v6sizeof(struct info_monitor_1)); for (md = mon_mru_list.mru_next; md != &mon_mru_list && im != 0; md = md->mru_next) { - im->lasttime = htonl((u_int32)md->avg_interval); + im->lasttime = htonl((u_int32)((current_time - + md->firsttime) / md->count)); im->firsttime = htonl((u_int32)(current_time - md->lasttime)); - im->lastdrop = htonl((u_int32)md->drop_count); + im->restr = htonl((u_int32)md->flags); im->count = htonl((u_int32)md->count); - if (md->rmtadr.ss_family == AF_INET6) { + if (IS_IPV6(&md->rmtadr)) { if (!client_v6_capable) continue; - im->addr6 = GET_INADDR6(md->rmtadr); + im->addr6 = SOCK_ADDR6(&md->rmtadr); im->v6_flag = 1; - im->daddr6 = GET_INADDR6(md->interface->sin); + im->daddr6 = SOCK_ADDR6(&md->interface->sin); } else { - im->addr = GET_INADDR(md->rmtadr); + im->addr = NSRCADR(&md->rmtadr); if (client_v6_capable) im->v6_flag = 0; - im->daddr = (md->cast_flags == MDF_BCAST) - ? GET_INADDR(md->interface->bcast) - : (md->cast_flags - ? (GET_INADDR(md->interface->sin) - ? GET_INADDR(md->interface->sin) - : GET_INADDR(md->interface->bcast)) - : 4); + if (MDF_BCAST == md->cast_flags) + im->daddr = NSRCADR(&md->interface->bcast); + else if (md->cast_flags) { + im->daddr = NSRCADR(&md->interface->sin); + if (!im->daddr) + im->daddr = NSRCADR(&md->interface->bcast); + } else + im->daddr = 4; } im->flags = htonl(md->cast_flags); im->port = md->rmtport; @@ -2008,7 +2049,7 @@ */ struct reset_entry { int flag; /* flag this corresponds to */ - void (*handler) P((void)); /* routine to handle request */ + void (*handler) (void); /* routine to handle request */ }; struct reset_entry reset_entries[] = { @@ -2027,7 +2068,7 @@ */ static void reset_stats( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -2064,15 +2105,15 @@ */ static void reset_peer( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) { - register struct conf_unpeer *cp; - register int items; - register struct peer *peer; - struct sockaddr_storage peeraddr; + struct conf_unpeer *cp; + int items; + struct peer *peer; + sockaddr_u peeraddr; int bad; /* @@ -2085,21 +2126,21 @@ bad = 0; while (items-- > 0 && !bad) { - memset((char *)&peeraddr, 0, sizeof(peeraddr)); - if (client_v6_capable && cp->v6_flag != 0) { - GET_INADDR6(peeraddr) = cp->peeraddr6; - peeraddr.ss_family = AF_INET6; + ZERO_SOCK(&peeraddr); + if (client_v6_capable && cp->v6_flag) { + AF(&peeraddr) = AF_INET6; + SOCK_ADDR6(&peeraddr) = cp->peeraddr6; } else { - GET_INADDR(peeraddr) = cp->peeraddr; - peeraddr.ss_family = AF_INET; + AF(&peeraddr) = AF_INET; + NSRCADR(&peeraddr) = cp->peeraddr; } - NSRCPORT(&peeraddr) = htons(NTP_PORT); -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - peeraddr.ss_len = SOCKLEN(&peeraddr); + +#ifdef ISC_PLATFORM_HAVESALEN + peeraddr.sa.sa_len = SOCKLEN(&peeraddr); #endif - peer = findexistingpeer(&peeraddr, (struct peer *)0, -1); - if (peer == (struct peer *)0) - bad++; + peer = findexistingpeer(&peeraddr, NULL, -1); + if (NULL == peer) + bad++; cp = (struct conf_unpeer *)((char *)cp + INFO_ITEMSIZE(inpkt->mbz_itemsize)); } @@ -2116,21 +2157,22 @@ items = INFO_NITEMS(inpkt->err_nitems); cp = (struct conf_unpeer *)inpkt->data; while (items-- > 0) { - memset((char *)&peeraddr, 0, sizeof(peeraddr)); - if (client_v6_capable && cp->v6_flag != 0) { - GET_INADDR6(peeraddr) = cp->peeraddr6; - peeraddr.ss_family = AF_INET6; + ZERO_SOCK(&peeraddr); + if (client_v6_capable && cp->v6_flag) { + AF(&peeraddr) = AF_INET6; + SOCK_ADDR6(&peeraddr) = cp->peeraddr6; } else { - GET_INADDR(peeraddr) = cp->peeraddr; - peeraddr.ss_family = AF_INET; + AF(&peeraddr) = AF_INET; + NSRCADR(&peeraddr) = cp->peeraddr; } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - peeraddr.ss_len = SOCKLEN(&peeraddr); + SET_PORT(&peeraddr, 123); +#ifdef ISC_PLATFORM_HAVESALEN + peeraddr.sa.sa_len = SOCKLEN(&peeraddr); #endif - peer = findexistingpeer(&peeraddr, (struct peer *)0, -1); - while (peer != 0) { + peer = findexistingpeer(&peeraddr, NULL, -1); + while (peer != NULL) { peer_reset(peer); - peer = findexistingpeer(&peeraddr, (struct peer *)peer, -1); + peer = findexistingpeer(&peeraddr, peer, -1); } cp = (struct conf_unpeer *)((char *)cp + INFO_ITEMSIZE(inpkt->mbz_itemsize)); @@ -2145,7 +2187,7 @@ */ static void do_key_reread( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -2160,7 +2202,7 @@ */ static void trust_key( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -2174,7 +2216,7 @@ */ static void untrust_key( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -2188,7 +2230,7 @@ */ static void do_trustkey( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt, u_long trust @@ -2213,7 +2255,7 @@ */ static void get_auth_info( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -2281,7 +2323,7 @@ */ static void req_get_traps( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -2306,21 +2348,21 @@ for (i = 0, tr = ctl_trap; i < CTL_MAXTRAPS; i++, tr++) { if (tr->tr_flags & TRAP_INUSE) { - if (tr->tr_addr.ss_family == AF_INET) { + if (IS_IPV4(&tr->tr_addr)) { if (tr->tr_localaddr == any_interface) it->local_address = 0; else it->local_address - = GET_INADDR(tr->tr_localaddr->sin); - it->trap_address = GET_INADDR(tr->tr_addr); + = NSRCADR(&tr->tr_localaddr->sin); + it->trap_address = NSRCADR(&tr->tr_addr); if (client_v6_capable) it->v6_flag = 0; } else { if (!client_v6_capable) continue; it->local_address6 - = GET_INADDR6(tr->tr_localaddr->sin); - it->trap_address6 = GET_INADDR6(tr->tr_addr); + = SOCK_ADDR6(&tr->tr_localaddr->sin); + it->trap_address6 = SOCK_ADDR6(&tr->tr_addr); it->v6_flag = 1; } it->trap_port = NSRCPORT(&tr->tr_addr); @@ -2341,7 +2383,7 @@ */ static void req_set_trap( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -2356,7 +2398,7 @@ */ static void req_clr_trap( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -2371,7 +2413,7 @@ */ static void do_setclr_trap( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt, int set @@ -2380,14 +2422,14 @@ register struct conf_trap *ct; register struct interface *linter; int res; - struct sockaddr_storage laddr; + sockaddr_u laddr; /* - * Prepare sockaddr_storage structure + * Prepare sockaddr */ - memset((char *)&laddr, 0, sizeof laddr); - laddr.ss_family = srcadr->ss_family; - NSRCPORT(&laddr) = ntohs(NTP_PORT); + ZERO_SOCK(&laddr); + AF(&laddr) = AF(srcadr); + SET_PORT(&laddr, NTP_PORT); /* * Restrict ourselves to one item only. This eliminates @@ -2406,25 +2448,25 @@ if (ct->local_address == 0) { linter = any_interface; } else { - if (laddr.ss_family == AF_INET) - GET_INADDR(laddr) = ct->local_address; + if (IS_IPV4(&laddr)) + NSRCADR(&laddr) = ct->local_address; else - GET_INADDR6(laddr) = ct->local_address6; + SOCK_ADDR6(&laddr) = ct->local_address6; linter = findinterface(&laddr); - if (linter == NULL) { + if (NULL == linter) { req_ack(srcadr, inter, inpkt, INFO_ERR_NODATA); return; } } - if (laddr.ss_family == AF_INET) - GET_INADDR(laddr) = ct->trap_address; + if (IS_IPV4(&laddr)) + NSRCADR(&laddr) = ct->trap_address; else - GET_INADDR6(laddr) = ct->trap_address6; - if (ct->trap_port != 0) - NSRCPORT(&laddr) = ct->trap_port; + SOCK_ADDR6(&laddr) = ct->trap_address6; + if (ct->trap_port) + NSRCPORT(&laddr) = ct->trap_port; else - NSRCPORT(&laddr) = htons(TRAPPORT); + SET_PORT(&laddr, TRAPPORT); if (set) { res = ctlsettrap(&laddr, linter, 0, @@ -2448,7 +2490,7 @@ */ static void set_request_keyid( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -2476,7 +2518,7 @@ */ static void set_control_keyid( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -2505,7 +2547,7 @@ */ static void get_ctl_stats( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -2561,7 +2603,7 @@ */ static void get_kernel_info( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -2616,7 +2658,7 @@ */ static void get_clock_info( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -2625,16 +2667,15 @@ register u_int32 *clkaddr; register int items; struct refclockstat clock_stat; - struct sockaddr_storage addr; - struct sockaddr_in tmp_clock; + sockaddr_u addr; l_fp ltmp; - memset((char *)&addr, 0, sizeof addr); - addr.ss_family = AF_INET; -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - addr.ss_len = SOCKLEN(&addr); + ZERO_SOCK(&addr); + AF(&addr) = AF_INET; +#ifdef ISC_PLATFORM_HAVESALEN + addr.sa.sa_len = SOCKLEN(&addr); #endif - NSRCPORT(&addr) = htons(NTP_PORT); + SET_PORT(&addr, NTP_PORT); items = INFO_NITEMS(inpkt->err_nitems); clkaddr = (u_int32 *) inpkt->data; @@ -2642,19 +2683,18 @@ sizeof(struct info_clock)); while (items-- > 0) { - tmp_clock.sin_addr.s_addr = *clkaddr++; - CAST_V4(addr)->sin_addr = tmp_clock.sin_addr; - if (!ISREFCLOCKADR(&tmp_clock) || - findexistingpeer(&addr, (struct peer *)0, -1) == 0) { + NSRCADR(&addr) = *clkaddr++; + if (!ISREFCLOCKADR(&addr) || + findexistingpeer(&addr, NULL, -1) == NULL) { req_ack(srcadr, inter, inpkt, INFO_ERR_NODATA); return; } clock_stat.kv_list = (struct ctl_var *)0; - refclock_control(&addr, (struct refclockstat *)0, &clock_stat); + refclock_control(&addr, NULL, &clock_stat); - ic->clockadr = tmp_clock.sin_addr.s_addr; + ic->clockadr = NSRCADR(&addr); ic->type = clock_stat.type; ic->flags = clock_stat.flags; ic->lastevent = clock_stat.lastevent; @@ -2685,7 +2725,7 @@ */ static void set_clock_fudge( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -2693,25 +2733,23 @@ register struct conf_fudge *cf; register int items; struct refclockstat clock_stat; - struct sockaddr_storage addr; - struct sockaddr_in tmp_clock; + sockaddr_u addr; l_fp ltmp; - memset((char *)&addr, 0, sizeof addr); + ZERO_SOCK(&addr); memset((char *)&clock_stat, 0, sizeof clock_stat); items = INFO_NITEMS(inpkt->err_nitems); cf = (struct conf_fudge *) inpkt->data; while (items-- > 0) { - tmp_clock.sin_addr.s_addr = cf->clockadr; - *CAST_V4(addr) = tmp_clock; - addr.ss_family = AF_INET; -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - addr.ss_len = SOCKLEN(&addr); -#endif - NSRCPORT(&addr) = htons(NTP_PORT); - if (!ISREFCLOCKADR(&tmp_clock) || - findexistingpeer(&addr, (struct peer *)0, -1) == 0) { + AF(&addr) = AF_INET; + NSRCADR(&addr) = cf->clockadr; +#ifdef ISC_PLATFORM_HAVESALEN + addr.sa.sa_len = SOCKLEN(&addr); +#endif + SET_PORT(&addr, NTP_PORT); + if (!ISREFCLOCKADR(&addr) || + findexistingpeer(&addr, NULL, -1) == 0) { req_ack(srcadr, inter, inpkt, INFO_ERR_NODATA); return; } @@ -2759,7 +2797,7 @@ */ static void get_clkbug_info( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -2769,15 +2807,14 @@ register u_int32 *clkaddr; register int items; struct refclockbug bug; - struct sockaddr_storage addr; - struct sockaddr_in tmp_clock; + sockaddr_u addr; - memset((char *)&addr, 0, sizeof addr); - addr.ss_family = AF_INET; -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - addr.ss_len = SOCKLEN(&addr); + ZERO_SOCK(&addr); + AF(&addr) = AF_INET; +#ifdef ISC_PLATFORM_HAVESALEN + addr.sa.sa_len = SOCKLEN(&addr); #endif - NSRCPORT(&addr) = htons(NTP_PORT); + SET_PORT(&addr, NTP_PORT); items = INFO_NITEMS(inpkt->err_nitems); clkaddr = (u_int32 *) inpkt->data; @@ -2785,10 +2822,9 @@ sizeof(struct info_clkbug)); while (items-- > 0) { - tmp_clock.sin_addr.s_addr = *clkaddr++; - GET_INADDR(addr) = tmp_clock.sin_addr.s_addr; - if (!ISREFCLOCKADR(&tmp_clock) || - findexistingpeer(&addr, (struct peer *)0, -1) == 0) { + NSRCADR(&addr) = *clkaddr++; + if (!ISREFCLOCKADR(&addr) || + findexistingpeer(&addr, NULL, -1) == 0) { req_ack(srcadr, inter, inpkt, INFO_ERR_NODATA); return; } @@ -2800,7 +2836,7 @@ return; } - ic->clockadr = tmp_clock.sin_addr.s_addr; + ic->clockadr = NSRCADR(&addr); i = bug.nvalues; if (i > NUMCBUGVALUES) i = NUMCBUGVALUES; @@ -2834,24 +2870,24 @@ struct info_if_stats *ifs = *ifsp; struct interface *interface = interface_info->interface; - memset((char*)ifs, 0, sizeof(*ifs)); + memset(ifs, 0, sizeof(*ifs)); - if (interface->sin.ss_family == AF_INET6) { + if (IS_IPV6(&interface->sin)) { if (!client_v6_capable) { return; } ifs->v6_flag = 1; - memcpy((char *)&ifs->unaddr.addr6, (char *)&CAST_V6(interface->sin)->sin6_addr, sizeof(struct in6_addr)); - memcpy((char *)&ifs->unbcast.addr6, (char *)&CAST_V6(interface->bcast)->sin6_addr, sizeof(struct in6_addr)); - memcpy((char *)&ifs->unmask.addr6, (char *)&CAST_V6(interface->mask)->sin6_addr, sizeof(struct in6_addr)); + ifs->unaddr.addr6 = SOCK_ADDR6(&interface->sin); + ifs->unbcast.addr6 = SOCK_ADDR6(&interface->bcast); + ifs->unmask.addr6 = SOCK_ADDR6(&interface->mask); } else { ifs->v6_flag = 0; - memcpy((char *)&ifs->unaddr.addr, (char *)&CAST_V4(interface->sin)->sin_addr, sizeof(struct in_addr)); - memcpy((char *)&ifs->unbcast.addr, (char *)&CAST_V4(interface->bcast)->sin_addr, sizeof(struct in_addr)); - memcpy((char *)&ifs->unmask.addr, (char *)&CAST_V4(interface->mask)->sin_addr, sizeof(struct in_addr)); + ifs->unaddr.addr = SOCK_ADDR4(&interface->sin); + ifs->unbcast.addr = SOCK_ADDR4(&interface->bcast); + ifs->unmask.addr = SOCK_ADDR4(&interface->mask); } ifs->v6_flag = htonl(ifs->v6_flag); - strcpy(ifs->name, interface->name); + strncpy(ifs->name, interface->name, sizeof(ifs->name)); ifs->family = htons(interface->family); ifs->flags = htonl(interface->flags); ifs->last_ttl = htonl(interface->last_ttl); @@ -2860,7 +2896,8 @@ ifs->sent = htonl(interface->sent); ifs->notsent = htonl(interface->notsent); ifs->scopeid = htonl(interface->scopeid); - ifs->ifindex = htonl(interface->ifindex); + /* ifindex was always zero, now no longer in struct interface */ + ifs->ifindex = 0; ifs->ifnum = htonl(interface->ifnum); ifs->uptime = htonl(current_time - interface->starttime); ifs->ignore_packets = interface->ignore_packets; @@ -2875,7 +2912,7 @@ */ static void get_if_stats( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) @@ -2894,7 +2931,7 @@ static void do_if_reload( - struct sockaddr_storage *srcadr, + sockaddr_u *srcadr, struct interface *inter, struct req_pkt *inpkt ) diff -urN src/contrib/ntp/ntpd/ntp_restrict.c src.ntp/contrib/ntp/ntpd/ntp_restrict.c --- src/contrib/ntp/ntpd/ntp_restrict.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/ntp_restrict.c 2010-04-18 10:05:39.000000000 +0200 @@ -10,7 +10,9 @@ #include "ntpd.h" #include "ntp_if.h" +#include "ntp_lists.h" #include "ntp_stdlib.h" +#include "ntp_assert.h" /* * This code keeps a simple address-and-mask list of hosts we want @@ -41,65 +43,75 @@ * addresses. This is not protocol-independant but for now I can't * find a way to respect this. We'll check this later... JFB 07/2001 */ -#define SET_IPV6_ADDR_MASK(dst, src, msk) \ - do { \ - int idx; \ - for (idx = 0; idx < 16; idx++) { \ - (dst)->s6_addr[idx] = \ - (u_char) ((src)->s6_addr[idx] & (msk)->s6_addr[idx]); \ - } \ +#define MASK_IPV6_ADDR(dst, src, msk) \ + do { \ + int idx; \ + for (idx = 0; idx < COUNTOF((dst)->s6_addr); idx++) { \ + (dst)->s6_addr[idx] = (src)->s6_addr[idx] \ + & (msk)->s6_addr[idx]; \ + } \ } while (0) /* - * Memory allocation parameters. We allocate INITRESLIST entries - * initially, and add INCRESLIST entries to the free list whenever - * we run out. + * We allocate INC_RESLIST{4|6} entries to the free list whenever empty. + * Auto-tune these to be just less than 1KB (leaving at least 16 bytes + * for allocator overhead). */ -#define INITRESLIST 10 -#define INCRESLIST 5 - -#define RES_AVG 8. /* interpacket averaging factor */ +#define INC_RESLIST4 ((1024 - 16) / V4_SIZEOF_RESTRICT_U) +#define INC_RESLIST6 ((1024 - 16) / V6_SIZEOF_RESTRICT_U) /* * The restriction list */ -struct restrictlist *restrictlist; -struct restrictlist6 *restrictlist6; -static int restrictcount; /* count of entries in the res list */ -static int restrictcount6; /* count of entries in the res list 2*/ +restrict_u *restrictlist4; +restrict_u *restrictlist6; +static int restrictcount; /* count in the restrict lists */ /* * The free list and associated counters. Also some uninteresting * stat counters. */ -static struct restrictlist *resfree; -static struct restrictlist6 *resfree6; -static int numresfree; /* number of structures on free list */ -static int numresfree6; /* number of structures on free list 2 */ +static restrict_u *resfree4; /* available entries (free list) */ +static restrict_u *resfree6; -static u_long res_calls; -static u_long res_found; -static u_long res_not_found; +static u_long res_calls; +static u_long res_found; +static u_long res_not_found; /* - * Parameters of the RES_LIMITED restriction option. + * Count number of restriction entries referring to RES_LIMITED, to + * control implicit activation/deactivation of the MRU monlist. */ -u_long res_avg_interval = 5; /* min average interpacket interval */ -u_long res_min_interval = 1; /* min interpacket interval */ +static u_long res_limited_refcnt; /* - * Count number of restriction entries referring to RES_LIMITED controls - * activation/deactivation of monitoring (with respect to RES_LIMITED - * control) + * Our default entries. */ -static u_long res_limited_refcnt; -static u_long res_limited_refcnt6; +static restrict_u restrict_def4; +static restrict_u restrict_def6; + +/* + * "restrict source ..." enabled knob and restriction bits. + */ +static int restrict_source_enabled; +static u_short restrict_source_flags; +static u_short restrict_source_mflags; /* - * Our initial allocation of lists entries. + * private functions */ -static struct restrictlist resinit[INITRESLIST]; -static struct restrictlist6 resinit6[INITRESLIST]; +static restrict_u * alloc_res4(void); +static restrict_u * alloc_res6(void); +static void free_res(restrict_u *, int); +static void inc_res_limited(void); +static void dec_res_limited(void); +static restrict_u * match_restrict4_addr(u_int32, u_short); +static restrict_u * match_restrict6_addr(const struct in6_addr *, + u_short); +static restrict_u * match_restrict_entry(const restrict_u *, int); +static int res_sorts_before4(restrict_u *, restrict_u *); +static int res_sorts_before6(restrict_u *, restrict_u *); + /* * init_restrict - initialize the restriction data structures @@ -107,103 +119,323 @@ void init_restrict(void) { - register int i; - /* - * Zero the list and put all but one on the free list + * The restriction lists begin with a default entry with address + * and mask 0, which will match any entry. The lists are kept + * sorted by descending address followed by descending mask: + * + * address mask + * 192.168.0.0 255.255.255.0 kod limited noquery nopeer + * 192.168.0.0 255.255.0.0 kod limited + * 0.0.0.0 0.0.0.0 kod limited noquery + * + * The first entry which matches an address is used. With the + * example restrictions above, 192.168.0.0/24 matches the first + * entry, the rest of 192.168.0.0/16 matches the second, and + * everything else matches the third (default). + * + * Note this achieves the same result a little more efficiently + * than the documented behavior, which is to keep the lists + * sorted by ascending address followed by ascending mask, with + * the _last_ matching entry used. + * + * An additional wrinkle is we may have multiple entries with + * the same address and mask but differing match flags (mflags). + * At present there is only one, RESM_NTPONLY. Entries with + * RESM_NTPONLY are sorted earlier so they take precedence over + * any otherwise similar entry without. Again, this is the same + * behavior as but reversed implementation compared to the docs. + * */ - resfree = NULL; - memset((char *)resinit, 0, sizeof resinit); - resfree6 = NULL; - memset((char *)resinit6, 0, sizeof resinit6); - for (i = 1; i < INITRESLIST; i++) { - resinit[i].next = resfree; - resinit6[i].next = resfree6; - resfree = &resinit[i]; - resfree6 = &resinit6[i]; + LINK_SLIST(restrictlist4, &restrict_def4, link); + LINK_SLIST(restrictlist6, &restrict_def6, link); + restrictcount = 2; +} + + +static restrict_u * +alloc_res4(void) +{ + const size_t cb = V4_SIZEOF_RESTRICT_U; + const size_t count = INC_RESLIST4; + restrict_u * rl; + restrict_u * res; + int i; + + UNLINK_HEAD_SLIST(res, resfree4, link); + if (res != NULL) + return res; + + rl = emalloc(count * cb); + memset(rl, 0, count * cb); + /* link all but the first onto free list */ + res = (void *)((char *)rl + (count - 1) * cb); + for (i = count - 1; i > 0; i--) { + LINK_SLIST(resfree4, res, link); + res = (void *)((char *)res - cb); } - numresfree = INITRESLIST-1; - numresfree6 = INITRESLIST-1; + NTP_INSIST(rl == res); + /* allocate the first */ + return res; +} - /* - * Put the remaining item at the head of the list as our default - * entry. Everything in here should be zero for now. - */ - resinit[0].addr = htonl(INADDR_ANY); - resinit[0].mask = 0; - memset(&resinit6[0].addr6, 0, sizeof(struct in6_addr)); - memset(&resinit6[0].mask6, 0, sizeof(struct in6_addr)); - restrictlist = &resinit[0]; - restrictlist6 = &resinit6[0]; - restrictcount = 1; - restrictcount = 2; - /* - * fix up stat counters - */ - res_calls = 0; - res_found = 0; - res_not_found = 0; +static restrict_u * +alloc_res6(void) +{ + const size_t cb = V6_SIZEOF_RESTRICT_U; + const size_t count = INC_RESLIST6; + restrict_u * rl; + restrict_u * res; + int i; + + UNLINK_HEAD_SLIST(res, resfree6, link); + if (res != NULL) + return res; + + rl = emalloc(count * cb); + memset(rl, 0, count * cb); + /* link all but the first onto free list */ + res = (void *)((char *)rl + (count - 1) * cb); + for (i = count - 1; i > 0; i--) { + LINK_SLIST(resfree6, res, link); + res = (void *)((char *)res - cb); + } + NTP_INSIST(rl == res); + /* allocate the first */ + return res; +} - /* - * set default values for RES_LIMIT functionality - */ - res_limited_refcnt = 0; - res_limited_refcnt6 = 0; + +static void +free_res( + restrict_u * res, + int v6 + ) +{ + restrict_u ** plisthead; + restrict_u * unlinked; + + restrictcount--; + if (RES_LIMITED && res->flags) + dec_res_limited(); + + if (v6) + plisthead = &restrictlist6; + else + plisthead = &restrictlist4; + UNLINK_SLIST(unlinked, *plisthead, res, link, restrict_u); + NTP_INSIST(unlinked == res); + + if (v6) { + memset(res, 0, V6_SIZEOF_RESTRICT_U); + plisthead = &resfree6; + } else { + memset(res, 0, V4_SIZEOF_RESTRICT_U); + plisthead = &resfree4; + } + LINK_SLIST(*plisthead, res, link); +} + + +static void +inc_res_limited(void) +{ + if (!res_limited_refcnt) + mon_start(MON_RES); + res_limited_refcnt++; +} + + +static void +dec_res_limited(void) +{ + res_limited_refcnt--; + if (!res_limited_refcnt) + mon_stop(MON_RES); +} + + +static restrict_u * +match_restrict4_addr( + u_int32 addr, + u_short port + ) +{ + restrict_u * res; + restrict_u * next; + + for (res = restrictlist4; res != NULL; res = next) { + next = res->link; + if (res->u.v4.addr == (addr & res->u.v4.mask) + && (!(RESM_NTPONLY & res->mflags) + || NTP_PORT == port)) + break; + } + return res; +} + + +static restrict_u * +match_restrict6_addr( + const struct in6_addr * addr, + u_short port + ) +{ + restrict_u * res; + restrict_u * next; + struct in6_addr masked; + + for (res = restrictlist6; res != NULL; res = next) { + next = res->link; + NTP_INSIST(next != res); + MASK_IPV6_ADDR(&masked, addr, &res->u.v6.mask); + if (ADDR6_EQ(&masked, &res->u.v6.addr) + && (!(RESM_NTPONLY & res->mflags) + || NTP_PORT == port)) + break; + } + return res; +} + + +/* + * match_restrict_entry - find an exact match on a restrict list. + * + * Exact match is addr, mask, and mflags all equal. + * In order to use more common code for IPv4 and IPv6, this routine + * requires the caller to populate a restrict_u with mflags and either + * the v4 or v6 address and mask as appropriate. Other fields in the + * input restrict_u are ignored. + */ +static restrict_u * +match_restrict_entry( + const restrict_u * pmatch, + int v6 + ) +{ + restrict_u *res; + restrict_u *rlist; + size_t cb; + + if (v6) { + rlist = restrictlist6; + cb = sizeof(pmatch->u.v6); + } else { + rlist = restrictlist4; + cb = sizeof(pmatch->u.v4); + } + + for (res = rlist; res != NULL; res = res->link) + if (res->mflags == pmatch->mflags && + !memcmp(&res->u, &pmatch->u, cb)) + break; + return res; +} + + +/* + * res_sorts_before4 - compare two restrict4 entries + * + * Returns nonzero if r1 sorts before r2. We sort by descending + * address, then descending mask, then descending mflags, so sorting + * before means having a higher value. + */ +static int +res_sorts_before4( + restrict_u *r1, + restrict_u *r2 + ) +{ + int r1_before_r2; + + if (r1->u.v4.addr > r2->u.v4.addr) + r1_before_r2 = 1; + else if (r1->u.v4.addr < r2->u.v4.addr) + r1_before_r2 = 0; + else if (r1->u.v4.mask > r2->u.v4.mask) + r1_before_r2 = 1; + else if (r1->u.v4.mask < r2->u.v4.mask) + r1_before_r2 = 0; + else if (r1->mflags > r2->mflags) + r1_before_r2 = 1; + else + r1_before_r2 = 0; + + return r1_before_r2; +} + + +/* + * res_sorts_before6 - compare two restrict6 entries + * + * Returns nonzero if r1 sorts before r2. We sort by descending + * address, then descending mask, then descending mflags, so sorting + * before means having a higher value. + */ +static int +res_sorts_before6( + restrict_u *r1, + restrict_u *r2 + ) +{ + int r1_before_r2; + int cmp; + + cmp = ADDR6_CMP(&r1->u.v6.addr, &r2->u.v6.addr); + if (cmp > 0) /* r1->addr > r2->addr */ + r1_before_r2 = 1; + else if (cmp < 0) /* r2->addr > r1->addr */ + r1_before_r2 = 0; + else { + cmp = ADDR6_CMP(&r1->u.v6.mask, &r2->u.v6.mask); + if (cmp > 0) /* r1->mask > r2->mask*/ + r1_before_r2 = 1; + else if (cmp < 0) /* r2->mask > r1->mask */ + r1_before_r2 = 0; + else if (r1->mflags > r2->mflags) + r1_before_r2 = 1; + else + r1_before_r2 = 0; + } + + return r1_before_r2; } /* * restrictions - return restrictions for this host */ -int +u_short restrictions( - struct sockaddr_storage *srcadr, - int at_listhead + sockaddr_u *srcadr ) { - struct restrictlist *rl; - struct restrictlist *match = NULL; - struct restrictlist6 *rl6; - struct restrictlist6 *match6 = NULL; - struct in6_addr hostaddr6; - struct in6_addr hostservaddr6; - u_int32 hostaddr; - int flags = 0; - int isntpport; + restrict_u *match; + struct in6_addr *pin6; + u_short flags; res_calls++; - if (srcadr->ss_family == AF_INET) { - /* - * We need the host address in host order. Also need to - * know whether this is from the ntp port or not. - */ - hostaddr = SRCADR(srcadr); - isntpport = (SRCPORT(srcadr) == NTP_PORT); - + flags = 0; + /* IPv4 source address */ + if (IS_IPV4(srcadr)) { /* * Ignore any packets with a multicast source address * (this should be done early in the receive process, - * later!) + * not later!) */ if (IN_CLASSD(SRCADR(srcadr))) return (int)RES_IGNORE; + match = match_restrict4_addr(SRCADR(srcadr), + SRCPORT(srcadr)); + match->count++; /* - * Set match to first entry, which is default entry. - * Work our way down from there. + * res_not_found counts only use of the final default + * entry, not any "restrict default ntpport ...", which + * would be just before the final default. */ - match = restrictlist; - for (rl = match->next; rl != NULL && rl->addr <= hostaddr; - rl = rl->next) - if ((hostaddr & rl->mask) == rl->addr) { - if ((rl->mflags & RESM_NTPONLY) && - !isntpport) - continue; - match = rl; - } - match->count++; - if (match == restrictlist) + if (&restrict_def4 == match) res_not_found++; else res_found++; @@ -211,77 +443,24 @@ } /* IPv6 source address */ - if (srcadr->ss_family == AF_INET6) { - /* - * Need to know whether this is from the ntp port or - * not. - */ - hostaddr6 = GET_INADDR6(*srcadr); - isntpport = (ntohs(( - (struct sockaddr_in6 *)srcadr)->sin6_port) == - NTP_PORT); + if (IS_IPV6(srcadr)) { + pin6 = PSOCK_ADDR6(srcadr); /* * Ignore any packets with a multicast source address * (this should be done early in the receive process, - * later!) + * not later!) */ - if (IN6_IS_ADDR_MULTICAST(&hostaddr6)) + if (IN6_IS_ADDR_MULTICAST(pin6)) return (int)RES_IGNORE; - /* - * Set match to first entry, which is default entry. - * Work our way down from there. - */ - match6 = restrictlist6; - for (rl6 = match6->next; rl6 != NULL && - (memcmp(&(rl6->addr6), &hostaddr6, - sizeof(hostaddr6)) <= 0); rl6 = rl6->next) { - SET_IPV6_ADDR_MASK(&hostservaddr6, &hostaddr6, - &rl6->mask6); - if (memcmp(&hostservaddr6, &(rl6->addr6), - sizeof(hostservaddr6)) == 0) { - if ((rl6->mflags & RESM_NTPONLY) && - !isntpport) - continue; - match6 = rl6; - } - } - match6->count++; - if (match6 == restrictlist6) + match = match_restrict6_addr(pin6, SRCPORT(srcadr)); + match->count++; + if (&restrict_def6 == match) res_not_found++; else res_found++; - flags = match6->flags; - } - - /* - * The following implements a generalized call gap facility. - * Douse the RES_LIMITED bit only if the interval since the last - * packet is greater than res_min_interval and the average is - * greater thatn res_avg_interval. - */ - if (!at_listhead || mon_enabled == MON_OFF) { - flags &= ~RES_LIMITED; - } else { - struct mon_data *md; - - /* - * At this poin the most recent arrival is first in the - * MRU list. Let the first 10 packets in for free until - * the average stabilizes. - */ - md = mon_mru_list.mru_next; - if (md->avg_interval == 0) - md->avg_interval = md->drop_count; - else - md->avg_interval += (md->drop_count - - md->avg_interval) / RES_AVG; - if (md->count < 10 || (md->drop_count > - res_min_interval && md->avg_interval > - res_avg_interval)) - flags &= ~RES_LIMITED; - md->drop_count = flags; + flags = match->flags; } return (flags); } @@ -292,316 +471,130 @@ */ void hack_restrict( - int op, - struct sockaddr_storage *resaddr, - struct sockaddr_storage *resmask, - int mflags, - int flags + int op, + sockaddr_u * resaddr, + sockaddr_u * resmask, + u_short mflags, + u_short flags ) { - register u_int32 addr = 0; - register u_int32 mask = 0; - struct in6_addr addr6; - struct in6_addr mask6; - register struct restrictlist *rl = NULL; - register struct restrictlist *rlprev = NULL; - register struct restrictlist6 *rl6 = NULL; - register struct restrictlist6 *rlprev6 = NULL; - int i, addr_cmp, mask_cmp; - memset(&addr6, 0, sizeof(struct in6_addr)); - memset(&mask6, 0, sizeof(struct in6_addr)); + int v6; + restrict_u match; + restrict_u * res; + restrict_u ** plisthead; + + DPRINTF(1, ("restrict: op %d addr %s mask %s mflags %08x flags %08x\n", + op, stoa(resaddr), stoa(resmask), mflags, flags)); + + if (NULL == resaddr) { + NTP_REQUIRE(NULL == resmask); + NTP_REQUIRE(RESTRICT_FLAGS == op); + restrict_source_flags = flags; + restrict_source_mflags = mflags; + restrict_source_enabled = 1; + return; + } + + memset(&match, 0, sizeof(match)); + /* silence VC9 potentially uninit warnings */ + res = NULL; + v6 = 0; - if (resaddr->ss_family == AF_INET) { + if (IS_IPV4(resaddr)) { + v6 = 0; /* - * Get address and mask in host byte order + * Get address and mask in host byte order for easy + * comparison as u_int32 */ - addr = SRCADR(resaddr); - mask = SRCADR(resmask); - addr &= mask; /* make sure low bits zero */ + match.u.v4.addr = SRCADR(resaddr); + match.u.v4.mask = SRCADR(resmask); + match.u.v4.addr &= match.u.v4.mask; + } else if (IS_IPV6(resaddr)) { + v6 = 1; /* - * If this is the default address, point at first on - * list. Else go searching for it. + * Get address and mask in network byte order for easy + * comparison as byte sequences (e.g. memcmp()) */ - if (addr == 0) { - rlprev = NULL; - rl = restrictlist; - } else { - rlprev = restrictlist; - rl = rlprev->next; - while (rl != NULL) { - if (rl->addr > addr) { - rl = NULL; - break; - } else if (rl->addr == addr) { - if (rl->mask == mask) { - if ((mflags & - RESM_NTPONLY) == - (rl->mflags & - RESM_NTPONLY)) - break; - - if (!(mflags & - RESM_NTPONLY)) { - rl = NULL; - break; - } - } else if (rl->mask > mask) { - rl = NULL; - break; - } - } - rlprev = rl; - rl = rl->next; - } - } - } + match.u.v6.mask = SOCK_ADDR6(resmask); + MASK_IPV6_ADDR(&match.u.v6.addr, PSOCK_ADDR6(resaddr), + &match.u.v6.mask); - if (resaddr->ss_family == AF_INET6) { - mask6 = GET_INADDR6(*resmask); - SET_IPV6_ADDR_MASK(&addr6, - &GET_INADDR6(*resaddr), &mask6); - if (IN6_IS_ADDR_UNSPECIFIED(&addr6)) { - rlprev6 = NULL; - rl6 = restrictlist6; - } else { - rlprev6 = restrictlist6; - rl6 = rlprev6->next; - while (rl6 != NULL) { - addr_cmp = memcmp(&rl6->addr6, &addr6, - sizeof(addr6)); - if (addr_cmp > 0) { - rl6 = NULL; - break; - } else if (addr_cmp == 0) { - mask_cmp = memcmp(&rl6->mask6, - &mask6, sizeof(mask6)); - if (mask_cmp == 0) { - if ((mflags & - RESM_NTPONLY) == - (rl6->mflags & - RESM_NTPONLY)) - break; - - if (!(mflags & - RESM_NTPONLY)) { - rl6 = NULL; - break; - } - } else if (mask_cmp > 0) { - rl6 = NULL; - break; - } - } - rlprev6 = rl6; - rl6 = rl6->next; - } - } - } + } else /* not IPv4 nor IPv6 */ + NTP_REQUIRE(0); - /* - * In case the above wasn't clear :-), either rl now points - * at the entry this call refers to, or rl is zero and rlprev - * points to the entry prior to where this one should go in - * the sort. - */ + match.flags = flags; + match.mflags = mflags; + res = match_restrict_entry(&match, v6); - /* - * Switch based on operation - */ - if (resaddr->ss_family == AF_INET) { - switch (op) { - case RESTRICT_FLAGS: - /* - * Here we add bits to the flags. If this is a - * new restriction add it. - */ - if (rl == NULL) { - if (resfree == NULL) { - rl = (struct restrictlist *) - emalloc(INCRESLIST * - sizeof(struct - restrictlist)); - memset((char *)rl, 0, - INCRESLIST * sizeof(struct - restrictlist)); - for (i = 0; i < INCRESLIST; i++) { - rl->next = resfree; - resfree = rl; - rl++; - } - numresfree = INCRESLIST; - } - - rl = resfree; - resfree = rl->next; - numresfree--; - - rl->addr = addr; - rl->mask = mask; - rl->mflags = (u_short)mflags; - - if (rlprev == NULL) { - rl->next = restrictlist; - restrictlist = rl; - } else { - rl->next = rlprev->next; - rlprev->next = rl; - } - restrictcount++; - } - if ((rl->flags ^ (u_short)flags) & - RES_LIMITED) { - res_limited_refcnt++; - mon_start(MON_RES); - } - rl->flags |= (u_short)flags; - break; + switch (op) { - case RESTRICT_UNFLAG: - /* - * Remove some bits from the flags. If we didn't - * find this one, just return. - */ - if (rl != NULL) { - if ((rl->flags ^ (u_short)flags) & - RES_LIMITED) { - res_limited_refcnt--; - if (res_limited_refcnt == 0) - mon_stop(MON_RES); - } - rl->flags &= (u_short)~flags; - } - break; - - case RESTRICT_REMOVE: - case RESTRICT_REMOVEIF: - /* - * Remove an entry from the table entirely if we - * found one. Don't remove the default entry and - * don't remove an interface entry. - */ - if (rl != NULL - && rl->addr != htonl(INADDR_ANY) - && !(rl->mflags & RESM_INTERFACE && op != RESTRICT_REMOVEIF)) { - if (rlprev != NULL) { - rlprev->next = rl->next; - } else { - restrictlist = rl->next; - } - restrictcount--; - if (rl->flags & RES_LIMITED) { - res_limited_refcnt--; - if (res_limited_refcnt == 0) - mon_stop(MON_RES); - } - memset((char *)rl, 0, - sizeof(struct restrictlist)); - - rl->next = resfree; - resfree = rl; - numresfree++; - } - break; - - default: - break; + case RESTRICT_FLAGS: + /* + * Here we add bits to the flags. If this is a + * new restriction add it. + */ + if (NULL == res) { + if (v6) { + res = alloc_res6(); + memcpy(res, &match, + V6_SIZEOF_RESTRICT_U); + plisthead = &restrictlist6; + } else { + res = alloc_res4(); + memcpy(res, &match, + V4_SIZEOF_RESTRICT_U); + plisthead = &restrictlist4; + } + LINK_SORT_SLIST( + *plisthead, res, + (v6) + ? res_sorts_before6(res, L_S_S_CUR()) + : res_sorts_before4(res, L_S_S_CUR()), + link, restrict_u); + restrictcount++; + if (RES_LIMITED & flags) + inc_res_limited(); + } else { + if ((RES_LIMITED & flags) && + !(RES_LIMITED & res->flags)) + inc_res_limited(); + res->flags |= flags; } - } else if (resaddr->ss_family == AF_INET6) { - switch (op) { - case RESTRICT_FLAGS: - /* - * Here we add bits to the flags. If this is a - * new restriction add it. - */ - if (rl6 == NULL) { - if (resfree6 == NULL) { - rl6 = (struct - restrictlist6 *)emalloc( - INCRESLIST * sizeof(struct - restrictlist6)); - memset((char *)rl6, 0, - INCRESLIST * sizeof(struct - restrictlist6)); - - for (i = 0; i < INCRESLIST; - i++) { - rl6->next = resfree6; - resfree6 = rl6; - rl6++; - } - numresfree6 = INCRESLIST; - } - rl6 = resfree6; - resfree6 = rl6->next; - numresfree6--; - rl6->addr6 = addr6; - rl6->mask6 = mask6; - rl6->mflags = (u_short)mflags; - if (rlprev6 != NULL) { - rl6->next = rlprev6->next; - rlprev6->next = rl6; - } else { - rl6->next = restrictlist6; - restrictlist6 = rl6; - } - restrictcount6++; - } - if ((rl6->flags ^ (u_short)flags) & - RES_LIMITED) { - res_limited_refcnt6++; - mon_start(MON_RES); - } - rl6->flags |= (u_short)flags; - break; - - case RESTRICT_UNFLAG: - /* - * Remove some bits from the flags. If we didn't - * find this one, just return. - */ - if (rl6 != NULL) { - if ((rl6->flags ^ (u_short)flags) & - RES_LIMITED) { - res_limited_refcnt6--; - if (res_limited_refcnt6 == 0) - mon_stop(MON_RES); - } - rl6->flags &= (u_short)~flags; - } - break; - - case RESTRICT_REMOVE: - case RESTRICT_REMOVEIF: - /* - * Remove an entry from the table entirely if we - * found one. Don't remove the default entry and - * don't remove an interface entry. - */ - if (rl6 != NULL && - !IN6_IS_ADDR_UNSPECIFIED(&rl6->addr6) - && !(rl6->mflags & RESM_INTERFACE && op != RESTRICT_REMOVEIF)) { - if (rlprev6 != NULL) { - rlprev6->next = rl6->next; - } else { - restrictlist6 = rl6->next; - } - restrictcount6--; - if (rl6->flags & RES_LIMITED) { - res_limited_refcnt6--; - if (res_limited_refcnt6 == 0) - mon_stop(MON_RES); - } - memset((char *)rl6, 0, - sizeof(struct restrictlist6)); - rl6->next = resfree6; - resfree6 = rl6; - numresfree6++; - } - break; + break; - default: - break; + case RESTRICT_UNFLAG: + /* + * Remove some bits from the flags. If we didn't + * find this one, just return. + */ + if (res != NULL) { + if ((RES_LIMITED & res->flags) + && (RES_LIMITED & flags)) + dec_res_limited(); + res->flags &= ~flags; } + break; + + case RESTRICT_REMOVE: + case RESTRICT_REMOVEIF: + /* + * Remove an entry from the table entirely if we + * found one. Don't remove the default entry and + * don't remove an interface entry. + */ + if (res != NULL + && (RESTRICT_REMOVEIF == op + || !(RESM_INTERFACE & res->mflags)) + && res != &restrict_def4 + && res != &restrict_def6) + free_res(res, v6); + break; + + default: /* unknown op */ + NTP_INSIST(0); + break; } + } + diff -urN src/contrib/ntp/ntpd/ntp_scanner.c src.ntp/contrib/ntp/ntpd/ntp_scanner.c --- src/contrib/ntp/ntpd/ntp_scanner.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/ntp_scanner.c 2010-07-07 12:01:06.000000000 +0200 @@ -0,0 +1,656 @@ + +/* ntp_scanner.c + * + * The source code for a simple lexical analyzer. + * + * Written By: Sachin Kamboj + * University of Delaware + * Newark, DE 19711 + * Copyright (c) 2006 + */ + +#ifdef HAVE_CONFIG_H +# include +#endif + +#include +#include +#include +#include +#include + +#include "ntp_config.h" +#include "ntpsim.h" +#include "ntp_scanner.h" +#include "ntp_parser.h" +#include "ntp_debug.h" + +/* ntp_keyword.h declares finite state machine and token text */ +#include "ntp_keyword.h" + + + +/* SCANNER GLOBAL VARIABLES + * ------------------------ + */ + +#define MAX_LEXEME (1024 + 1) /* The maximum size of a lexeme */ +char yytext[MAX_LEXEME]; /* Buffer for storing the input text/lexeme */ +extern int input_from_file; + + + + +/* CONSTANTS + * --------- + */ + + +/* SCANNER GLOBAL VARIABLES + * ------------------------ + */ +const char special_chars[] = "{}(),;|="; + + +/* FUNCTIONS + * --------- + */ + +int get_next_char(void); +static int is_keyword(char *lexeme, follby *pfollowedby); + + + +/* + * keyword() - Return the keyword associated with token T_ identifier + */ +const char * +keyword( + int token + ) +{ + int i; + const char *text; + + i = token - LOWEST_KEYWORD_ID; + + if (i >= 0 && i < COUNTOF(keyword_text)) + text = keyword_text[i]; + else + text = NULL; + + return (text != NULL) + ? text + : "(keyword not found)"; +} + + +/* FILE INTERFACE + * -------------- + * We define a couple of wrapper functions around the standard C fgetc + * and ungetc functions in order to include positional bookkeeping + */ + +struct FILE_INFO * +F_OPEN( + const char *path, + const char *mode + ) +{ + struct FILE_INFO *my_info; + + my_info = emalloc(sizeof *my_info); + + my_info->line_no = 1; + my_info->col_no = 0; + my_info->prev_line_col_no = 0; + my_info->prev_token_col_no = 0; + my_info->fname = path; + + my_info->fd = fopen(path, mode); + if (NULL == my_info->fd) { + free(my_info); + return NULL; + } + return my_info; +} + +int +FGETC( + struct FILE_INFO *stream + ) +{ + int ch = fgetc(stream->fd); + + ++stream->col_no; + if (ch == '\n') { + stream->prev_line_col_no = stream->col_no; + ++stream->line_no; + stream->col_no = 1; + } + return ch; +} + +/* BUGS: 1. Function will fail on more than one line of pushback + * 2. No error checking is done to see if ungetc fails + * SK: I don't think its worth fixing these bugs for our purposes ;-) + */ +int +UNGETC( + int ch, + struct FILE_INFO *stream + ) +{ + if (ch == '\n') { + stream->col_no = stream->prev_line_col_no; + stream->prev_line_col_no = -1; + --stream->line_no; + } + --stream->col_no; + return ungetc(ch, stream->fd); +} + +int +FCLOSE( + struct FILE_INFO *stream + ) +{ + int ret_val = fclose(stream->fd); + + if (!ret_val) + free(stream); + return ret_val; +} + +/* STREAM INTERFACE + * ---------------- + * Provide a wrapper for the stream functions so that the + * stream can either read from a file or from a character + * array. + * NOTE: This is not very efficient for reading from character + * arrays, but needed to allow remote configuration where the + * configuration command is provided through ntpq. + * + * The behavior of there two functions is determined by the + * input_from_file flag. + */ + +int +get_next_char( + void + ) +{ + char ch; + + if (input_from_file) + return FGETC(ip_file); + else { + if (remote_config.buffer[remote_config.pos] == '\0') + return EOF; + else { + ip_file->col_no++; + ch = remote_config.buffer[remote_config.pos++]; + if (ch == '\n') { + ip_file->prev_line_col_no = ip_file->col_no; + ++ip_file->line_no; + ip_file->col_no = 1; + } + return ch; + } + } +} + +void +push_back_char( + int ch + ) +{ + if (input_from_file) + UNGETC(ch, ip_file); + else { + if (ch == '\n') { + ip_file->col_no = ip_file->prev_line_col_no; + ip_file->prev_line_col_no = -1; + --ip_file->line_no; + } + --ip_file->col_no; + + remote_config.pos--; + } +} + + + +/* STATE MACHINES + * -------------- + */ + +/* Keywords */ +static int +is_keyword( + char *lexeme, + follby *pfollowedby + ) +{ + follby fb; + int curr_s; /* current state index */ + int token; + int i; + + curr_s = SCANNER_INIT_S; + token = 0; + + for (i = 0; lexeme[i]; i++) { + while (curr_s && (lexeme[i] != SS_CH(sst[curr_s]))) + curr_s = SS_OTHER_N(sst[curr_s]); + + if (curr_s && (lexeme[i] == SS_CH(sst[curr_s]))) { + if ('\0' == lexeme[i + 1] + && FOLLBY_NON_ACCEPTING + != SS_FB(sst[curr_s])) { + fb = SS_FB(sst[curr_s]); + *pfollowedby = fb; + token = curr_s; + break; + } + curr_s = SS_MATCH_N(sst[curr_s]); + } else + break; + } + + return token; +} + + +/* Integer */ +static int +is_integer( + char *lexeme + ) +{ + int i = 0; + + /* Allow a leading minus sign */ + if (lexeme[i] == '-') + ++i; + + /* Check that all the remaining characters are digits */ + for (; lexeme[i]; ++i) { + if (!isdigit(lexeme[i])) + return 0; + } + return 1; +} + + +/* Double */ +static int +is_double( + char *lexeme + ) +{ + int num_digits = 0; /* Number of digits read */ + int i; + + i = 0; + + /* Check for an optional '+' or '-' */ + if ('+' == lexeme[i] || '-' == lexeme[i]) + i++; + + /* Read the integer part */ + for (; lexeme[i] && isdigit(lexeme[i]); i++) + num_digits++; + + /* Check for the required decimal point */ + if ('.' == lexeme[i]) + i++; + else + return 0; + + /* Check for any digits after the decimal point */ + for (; lexeme[i] && isdigit(lexeme[i]); i++) + num_digits++; + + /* + * The number of digits in both the decimal part and the + * fraction part must not be zero at this point + */ + if (!num_digits) + return 0; + + /* Check if we are done */ + if (!lexeme[i]) + return 1; + + /* There is still more input, read the exponent */ + if ('e' == tolower(lexeme[i])) + i++; + else + return 0; + + /* Read an optional Sign */ + if ('+' == lexeme[i] || '-' == lexeme[i]) + i++; + + /* Now read the exponent part */ + while (lexeme[i] && isdigit(lexeme[i])) + i++; + + /* Check if we are done */ + if (!lexeme[i]) + return 1; + else + return 0; +} + + +/* is_special() - Test whether a character is a token */ +static inline int +is_special( + int ch + ) +{ + return (int)strchr(special_chars, ch); +} + + +static int +is_EOC( + int ch + ) +{ + if ((old_config_style && (ch == '\n')) || + (!old_config_style && (ch == ';'))) + return 1; + return 0; +} + + +char * +quote_if_needed(char *str) +{ + char *ret; + size_t len; + size_t octets; + + len = strlen(str); + octets = len + 2 + 1; + ret = emalloc(octets); + if ('"' != str[0] + && (strcspn(str, special_chars) < len + || strchr(str, ' ') != NULL)) { + snprintf(ret, octets, "\"%s\"", str); + } else + strncpy(ret, str, octets); + + return ret; +} + + +static int +create_string_token( + char *lexeme + ) +{ + char *pch; + + /* + * ignore end of line whitespace + */ + pch = lexeme; + while (*pch && isspace(*pch)) + pch++; + + if (!*pch) { + yylval.Integer = T_EOC; + return yylval.Integer; + } + + yylval.String = estrdup(lexeme); + return T_String; +} + + +/* + * yylex() - function that does the actual scanning. + * Bison expects this function to be called yylex and for it to take no + * input and return an int. + * Conceptually yylex "returns" yylval as well as the actual return + * value representing the token or type. + */ +int +yylex( + void + ) +{ + int i, instring = 0; + int yylval_was_set = 0; + int token; /* The return value/the recognized token */ + int ch; + static follby followedby = FOLLBY_TOKEN; + + do { + /* Ignore whitespace at the beginning */ + while (EOF != (ch = get_next_char()) && + isspace(ch) && + !is_EOC(ch)) + ; /* Null Statement */ + + if (EOF == ch) { + + if (!input_from_file || !curr_include_level) + return 0; + + FCLOSE(fp[curr_include_level]); + ip_file = fp[--curr_include_level]; + token = T_EOC; + goto normal_return; + + } else if (is_EOC(ch)) { + + /* end FOLLBY_STRINGS_TO_EOC effect */ + followedby = FOLLBY_TOKEN; + token = T_EOC; + goto normal_return; + + } else if (is_special(ch) && FOLLBY_TOKEN == followedby) { + /* special chars are their own token values */ + token = ch; + /* + * '=' implies a single string following as in: + * setvar Owner = "The Boss" default + * This could alternatively be handled by + * removing '=' from special_chars and adding + * it to the keyword table. + */ + if ('=' == ch) + followedby = FOLLBY_STRING; + yytext[0] = (char)ch; + yytext[1] = '\0'; + goto normal_return; + } else + push_back_char(ch); + + /* save the position of start of the token */ + ip_file->prev_token_line_no = ip_file->line_no; + ip_file->prev_token_col_no = ip_file->col_no; + + /* Read in the lexeme */ + i = 0; + while (EOF != (ch = get_next_char())) { + + yytext[i] = (char)ch; + + /* Break on whitespace or a special character */ + if (isspace(ch) || is_EOC(ch) + || '"' == ch + || (FOLLBY_TOKEN == followedby + && is_special(ch))) + break; + + /* Read the rest of the line on reading a start + of comment character */ + if ('#' == ch) { + while (EOF != (ch = get_next_char()) + && '\n' != ch) + ; /* Null Statement */ + break; + } + + i++; + if (i >= COUNTOF(yytext)) + goto lex_too_long; + } + /* Pick up all of the string inside between " marks, to + * end of line. If we make it to EOL without a + * terminating " assume it for them. + * + * XXX - HMS: I'm not sure we want to assume the closing " + */ + if ('"' == ch) { + instring = 1; + while (EOF != (ch = get_next_char()) && + ch != '"' && ch != '\n') { + yytext[i++] = (char)ch; + if (i >= COUNTOF(yytext)) + goto lex_too_long; + } + /* + * yytext[i] will be pushed back as not part of + * this lexeme, but any closing quote should + * not be pushed back, so we read another char. + */ + if ('"' == ch) + ch = get_next_char(); + } + /* Pushback the last character read that is not a part + * of this lexeme. + * If the last character read was an EOF, pushback a + * newline character. This is to prevent a parse error + * when there is no newline at the end of a file. + */ + if (EOF == ch) + push_back_char('\n'); + else + push_back_char(ch); + yytext[i] = '\0'; + } while (i == 0); + + /* Now return the desired token */ + + /* First make sure that the parser is *not* expecting a string + * as the next token (based on the previous token that was + * returned) and that we haven't read a string. + */ + + if (followedby == FOLLBY_TOKEN && !instring) { + token = is_keyword(yytext, &followedby); + if (token) + goto normal_return; + else if (is_integer(yytext)) { + yylval_was_set = 1; + errno = 0; + if ((yylval.Integer = strtol(yytext, NULL, 10)) == 0 + && ((errno == EINVAL) || (errno == ERANGE))) { + msyslog(LOG_ERR, + "Integer cannot be represented: %s", + yytext); + exit(1); + } else { + token = T_Integer; + goto normal_return; + } + } + else if (is_double(yytext)) { + yylval_was_set = 1; + errno = 0; + if ((yylval.Double = atof(yytext)) == 0 && errno == ERANGE) { + msyslog(LOG_ERR, + "Double too large to represent: %s", + yytext); + exit(1); + } else { + token = T_Double; + goto normal_return; + } + } else { + /* Default: Everything is a string */ + yylval_was_set = 1; + token = create_string_token(yytext); + goto normal_return; + } + } + + /* + * Either followedby is not FOLLBY_TOKEN or this lexeme is part + * of a string. Hence, we need to return T_String. + * + * _Except_ we might have a -4 or -6 flag on a an association + * configuration line (server, peer, pool, etc.). + * + * This is a terrible hack, but the grammar is ambiguous so we + * don't have a choice. [SK] + * + * The ambiguity is in the keyword scanner, not ntp_parser.y. + * We do not require server addresses be quoted in ntp.conf, + * complicating the scanner's job. To avoid trying (and + * failing) to match an IP address or DNS name to a keyword, + * the association keywords use FOLLBY_STRING in the keyword + * table, which tells the scanner to force the next token to be + * a T_String, so it does not try to match a keyword but rather + * expects a string when -4/-6 modifiers to server, peer, etc. + * are encountered. + * restrict -4 and restrict -6 parsing works correctly without + * this hack, as restrict uses FOLLBY_TOKEN. [DH] + */ + if ('-' == yytext[0]) { + if ('4' == yytext[1]) { + token = T_Ipv4_flag; + goto normal_return; + } else if ('6' == yytext[1]) { + token = T_Ipv6_flag; + goto normal_return; + } + } + + instring = 0; + if (FOLLBY_STRING == followedby) + followedby = FOLLBY_TOKEN; + + yylval_was_set = 1; + token = create_string_token(yytext); + +normal_return: + if (T_EOC == token) + DPRINTF(4,("\t\n")); + else + DPRINTF(4, ("yylex: lexeme '%s' -> %s\n", yytext, + token_name(token))); + + if (!yylval_was_set) + yylval.Integer = token; + + return token; + +lex_too_long: + yytext[min(sizeof(yytext) - 1, 50)] = 0; + msyslog(LOG_ERR, + "configuration item on line %d longer than limit of %lu, began with '%s'", + ip_file->line_no, (u_long)(sizeof(yytext) - 1), yytext); + + /* + * If we hit the length limit reading the startup configuration + * file, abort. + */ + if (input_from_file) + exit(sizeof(yytext) - 1); + + /* + * If it's runtime configuration via ntpq :config treat it as + * if the configuration text ended before the too-long lexeme, + * hostname, or string. + */ + yylval.Integer = 0; + return 0; +} diff -urN src/contrib/ntp/ntpd/ntp_scanner.h src.ntp/contrib/ntp/ntpd/ntp_scanner.h --- src/contrib/ntp/ntpd/ntp_scanner.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/ntp_scanner.h 2009-12-25 10:03:40.000000000 +0100 @@ -0,0 +1,132 @@ +/* ntp_scanner.h + * + * The header file for a simple lexical analyzer. + * + * Written By: Sachin Kamboj + * University of Delaware + * Newark, DE 19711 + * Copyright (c) 2006 + */ + +#ifndef NTP_SCANNER_H +#define NTP_SCANNER_H + +/* + * ntp.conf syntax is slightly irregular in that some tokens such as + * hostnames do not require quoting even if they might otherwise be + * recognized as T_ terminal tokens. This hand-crafted lexical scanner + * uses a "followed by" value associated with each keyword to indicate + * normal scanning of the next token, forced scanning of the next token + * alone as a T_String, or forced scanning of all tokens to the end of + * the command as T_String. + * In the past the identifiers for this functionality ended in _ARG: + * + * NO_ARG -> FOLLBY_TOKEN + * SINGLE_ARG -> FOLLBY_STRING + * MULTIPLE_ARG -> FOLLBY_STRINGS_TO_EOC + * + * Note that some tokens use FOLLBY_TOKEN even though they sometimes + * are followed by strings. FOLLBY_STRING is used only when needed to + * avoid the keyword scanner matching a token where a string is needed. + * + * FOLLBY_NON_ACCEPT is an overloading of this field to distinguish + * non-accepting states (where the state number does not match a T_ + * value). + */ +typedef enum { + FOLLBY_TOKEN = 0, + FOLLBY_STRING, + FOLLBY_STRINGS_TO_EOC, + FOLLBY_NON_ACCEPTING +} follby; + +#define MAXLINE 1024 /* maximum length of line */ +#define MAXINCLUDELEVEL 5 /* maximum include file levels */ + +/* STRUCTURES + * ---------- + */ + +/* + * Define a structure to hold the FSA for the keywords. + * The structure is actually a trie. + * + * To save space, a single u_int32 encodes four fields, and a fifth + * (the token completed for terminal states) is implied by the index of + * the rule within the scan state array, taking advantage of the fact + * there are more scan states than the highest T_ token number. + * + * The lowest 8 bits hold the character the state matches on. + * Bits 8 and 9 hold the followedby value (0 - 3). For non-accepting + * states (which do not match a completed token) the followedby + * value 3 (FOLLBY_NONACCEPTING) denotes that fact. For accepting + * states, values 0 - 2 control whether the scanner forces the + * following token(s) to strings. + * Bits 10 through 20 hold the next state to check not matching + * this state's character. + * Bits 21 through 31 hold the next state to check matching the char. + */ + +#define S_ST(ch, fb, match_n, other_n) ( \ + (u_char)((ch) & 0xff) | \ + ((u_int32)(fb) << 8) | \ + ((u_int32)(match_n) << 10) | \ + ((u_int32)(other_n) << 21) \ +) + +#define SS_CH(ss) ((char)(u_char)((ss) & 0xff)) +#define SS_FB(ss) (((u_int)(ss) >> 8) & 0x3) +#define SS_MATCH_N(ss) (((u_int)(ss) >> 10) & 0x7ff) +#define SS_OTHER_N(ss) (((u_int)(ss) >> 21) & 0x7ff) + +typedef u_int32 scan_state; + + +/* Structure to hold a filename, file pointer and positional info */ +struct FILE_INFO { + const char * fname; /* Path to the file */ + FILE * fd; /* File Descriptor */ + int line_no; /* Line Number */ + int col_no; /* Column Number */ + int prev_line_col_no; /* Col No on the + previous line when a + '\n' was seen */ + int prev_token_line_no; /* Line at start of + token */ + int prev_token_col_no; /* Col No at start of + token */ + int err_line_no; + int err_col_no; +}; + + +/* SCANNER GLOBAL VARIABLES + * ------------------------ + */ +extern struct config_tree cfgt; /* Parser output stored here */ +extern int curr_include_level; /* The current include level */ + +extern struct FILE_INFO *ip_file; /* Pointer to the configuration file stream */ + +/* VARIOUS EXTERNAL DECLARATIONS + * ----------------------------- + */ +extern int old_config_style; +extern int input_from_file; +extern struct FILE_INFO *fp[]; + +/* VARIOUS SUBROUTINE DECLARATIONS + * ------------------------------- + */ +extern const char *keyword(int token); +extern char *quote_if_needed(char *str); +int yylex(void); + +struct FILE_INFO *F_OPEN(const char *path, const char *mode); +int FGETC(struct FILE_INFO *stream); +int UNGETC(int ch, struct FILE_INFO *stream); +int FCLOSE(struct FILE_INFO *stream); + +void push_back_char(int ch); + +#endif /* NTP_SCANNER_H */ diff -urN src/contrib/ntp/ntpd/ntp_signd.c src.ntp/contrib/ntp/ntpd/ntp_signd.c --- src/contrib/ntp/ntpd/ntp_signd.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/ntp_signd.c 2009-12-09 08:36:36.000000000 +0100 @@ -0,0 +1,239 @@ +/* Copyright 2008, Red Hat, Inc. + Copyright 2008, Andrew Tridgell. + Licenced under the same terms as NTP itself. + */ +#ifdef HAVE_CONFIG_H +#include +#endif + +#ifdef HAVE_NTP_SIGND + +#include "ntpd.h" +#include "ntp_io.h" +#include "ntp_stdlib.h" +#include "ntp_unixtime.h" +#include "ntp_control.h" +#include "ntp_string.h" + +#include +#include +#ifdef HAVE_LIBSCF_H +#include +#include +#endif /* HAVE_LIBSCF_H */ + +#include + +/* socket routines by tridge - from junkcode.samba.org */ + +/* + connect to a unix domain socket +*/ +static int +ux_socket_connect(const char *name) +{ + int fd; + struct sockaddr_un addr; + if (!name) { + return -1; + } + + memset(&addr, 0, sizeof(addr)); + addr.sun_family = AF_UNIX; + strncpy(addr.sun_path, name, sizeof(addr.sun_path)); + + fd = socket(AF_UNIX, SOCK_STREAM, 0); + if (fd == -1) { + return -1; + } + + if (connect(fd, (struct sockaddr *)&addr, sizeof(addr)) == -1) { + close(fd); + return -1; + } + + return fd; +} + + +/* + keep writing until its all sent +*/ +static int +write_all(int fd, const void *buf, size_t len) +{ + size_t total = 0; + while (len) { + int n = write(fd, buf, len); + if (n <= 0) return total; + buf = n + (char *)buf; + len -= n; + total += n; + } + return total; +} + +/* + keep reading until its all read +*/ +static int +read_all(int fd, void *buf, size_t len) +{ + size_t total = 0; + while (len) { + int n = read(fd, buf, len); + if (n <= 0) return total; + buf = n + (char *)buf; + len -= n; + total += n; + } + return total; +} + +/* + send a packet in length prefix format +*/ +static int +send_packet(int fd, const char *buf, uint32_t len) +{ + uint32_t net_len = htonl(len); + if (write_all(fd, &net_len, sizeof(net_len)) != sizeof(net_len)) return -1; + if (write_all(fd, buf, len) != len) return -1; + return 0; +} + +/* + receive a packet in length prefix format +*/ +static int +recv_packet(int fd, char **buf, uint32_t *len) +{ + if (read_all(fd, len, sizeof(*len)) != sizeof(*len)) return -1; + *len = ntohl(*len); + (*buf) = emalloc(*len); + if (read_all(fd, *buf, *len) != *len) { + free(*buf); + return -1; + } + return 0; +} + +void +send_via_ntp_signd( + struct recvbuf *rbufp, /* receive packet pointer */ + int xmode, + keyid_t xkeyid, + int flags, + struct pkt *xpkt + ) +{ + + /* We are here because it was detected that the client + * sent an all-zero signature, and we therefore know + * it's windows trying to talk to an AD server + * + * Because we don't want to dive into Samba's secrets + * database just to find the long-term kerberos key + * that is re-used as the NTP key, we instead hand the + * packet over to Samba to sign, and return to us. + * + * The signing method Samba will use is described by + * Microsoft in MS-SNTP, found here: + * http://msdn.microsoft.com/en-us/library/cc212930.aspx + */ + + int fd, sendlen; + struct samba_key_in { + uint32_t version; + uint32_t op; + uint32_t packet_id; + uint32_t key_id_le; + struct pkt pkt; + } samba_pkt; + + struct samba_key_out { + uint32_t version; + uint32_t op; + uint32_t packet_id; + struct pkt pkt; + } samba_reply; + + char full_socket[256]; + + char *reply = NULL; + uint32_t reply_len; + + memset(&samba_pkt, 0, sizeof(samba_pkt)); + samba_pkt.op = 0; /* Sign message */ + /* This will be echoed into the reply - a different + * impelementation might want multiple packets + * awaiting signing */ + + samba_pkt.packet_id = 1; + + /* Swap the byte order back - it's actually little + * endian on the wire, but it was read above as + * network byte order */ + samba_pkt.key_id_le = htonl(xkeyid); + samba_pkt.pkt = *xpkt; + + snprintf(full_socket, sizeof(full_socket), "%s/socket", ntp_signd_socket); + + fd = ux_socket_connect(full_socket); + /* Only continue with this if we can talk to Samba */ + if (fd != -1) { + /* Send old packet to Samba, expect response */ + /* Packet to Samba is quite simple: + All values BIG endian except key ID as noted + [packet size as BE] - 4 bytes + [protocol version (0)] - 4 bytes + [packet ID] - 4 bytes + [operation (sign message=0)] - 4 bytes + [key id] - LITTLE endian (as on wire) - 4 bytes + [message to sign] - as marshalled, without signature + */ + + if (send_packet(fd, (char *)&samba_pkt, offsetof(struct samba_key_in, pkt) + LEN_PKT_NOMAC) != 0) { + /* Huh? could not talk to Samba... */ + close(fd); + return; + } + + if (recv_packet(fd, &reply, &reply_len) != 0) { + if (reply) { + free(reply); + } + close(fd); + return; + } + /* Return packet is also simple: + [packet size] - network byte order - 4 bytes + [protocol version (0)] network byte order - - 4 bytes + [operation (signed success=3, failure=4)] network byte order - - 4 byte + (optional) [signed message] - as provided before, with signature appended + */ + + if (reply_len <= sizeof(samba_reply)) { + memcpy(&samba_reply, reply, reply_len); + if (ntohl(samba_reply.op) == 3 && reply_len > offsetof(struct samba_key_out, pkt)) { + sendlen = reply_len - offsetof(struct samba_key_out, pkt); + xpkt = &samba_reply.pkt; + sendpkt(&rbufp->recv_srcadr, rbufp->dstadr, 0, xpkt, sendlen); +#ifdef DEBUG + if (debug) + printf( + "transmit ntp_signd packet: at %ld %s->%s mode %d keyid %08x len %d\n", + current_time, ntoa(&rbufp->dstadr->sin), + ntoa(&rbufp->recv_srcadr), xmode, xkeyid, sendlen); +#endif + } + } + + if (reply) { + free(reply); + } + close(fd); + + } +} +#endif diff -urN src/contrib/ntp/ntpd/ntp_timer.c src.ntp/contrib/ntp/ntpd/ntp_timer.c --- src/contrib/ntp/ntpd/ntp_timer.c 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/ntp_timer.c 2009-12-09 08:36:35.000000000 +0100 @@ -23,6 +23,14 @@ # include "ntp_timer.h" #endif +#ifdef KERNEL_PLL +#include "ntp_syscall.h" +#endif /* KERNEL_PLL */ + +#ifdef OPENSSL +#include +#endif /* OPENSSL */ + /* * These routines provide support for the event timer. The timer is * implemented by an interrupt routine which sets a flag once every @@ -33,25 +41,27 @@ * dispatched to the transmit procedure. Finally, we call the hourly * procedure to do cleanup and print a message. */ - volatile int interface_interval = 300; /* update interface every 5 minutes as default */ /* - * Alarm flag. The mainline code imports this. + * Alarm flag. The mainline code imports this. */ volatile int alarm_flag; /* - * The counters + * The counters and timeouts */ -static u_long adjust_timer; /* second timer */ -static u_long keys_timer; /* minute timer */ -static u_long stats_timer; /* stats timer */ -static u_long huffpuff_timer; /* huff-n'-puff timer */ -static u_long interface_timer; /* interface update timer */ +static u_long interface_timer; /* interface update timer */ +static u_long adjust_timer; /* second timer */ +static u_long stats_timer; /* stats timer */ +static u_long huffpuff_timer; /* huff-n'-puff timer */ +u_long leapsec; /* leapseconds countdown */ +l_fp sys_time; /* current system time */ #ifdef OPENSSL -static u_long revoke_timer; /* keys revoke timer */ -u_char sys_revoke = KEY_REVOKE; /* keys revoke timeout (log2 s) */ +static u_long revoke_timer; /* keys revoke timer */ +static u_long keys_timer; /* session key timer */ +u_long sys_revoke = KEY_REVOKE; /* keys revoke timeout (log2 s) */ +u_long sys_automax = NTP_AUTOMAX; /* key list timeout (log2 s) */ #endif /* OPENSSL */ /* @@ -60,9 +70,10 @@ volatile u_long alarm_overflow; #define MINUTE 60 -#define HOUR (60*60) +#define HOUR (60 * MINUTE) +#define DAY (24 * HOUR) -u_long current_time; +u_long current_time; /* seconds since startup */ /* * Stats. Number of overflows and number of calls to transmit(). @@ -79,7 +90,7 @@ #if defined SYS_WINNT static HANDLE WaitableTimerHandle = NULL; #else -static RETSIGTYPE alarming P((int)); +static RETSIGTYPE alarming (int); #endif /* SYS_WINNT */ #if !defined(VMS) @@ -140,11 +151,6 @@ void init_timer(void) { -# if defined SYS_WINNT & !defined(SYS_CYGWIN32) - HANDLE hToken = INVALID_HANDLE_VALUE; - TOKEN_PRIVILEGES tkp; -# endif /* SYS_WINNT */ - /* * Initialize... */ @@ -199,28 +205,6 @@ sys$setimr(0, &vmstimer, alarming, alarming, 0); # endif /* VMS */ #else /* SYS_WINNT */ - _tzset(); - - /* - * Get privileges needed for fiddling with the clock - */ - - /* get the current process token handle */ - if (!OpenProcessToken(GetCurrentProcess(), TOKEN_ADJUST_PRIVILEGES | TOKEN_QUERY, &hToken)) { - msyslog(LOG_ERR, "OpenProcessToken failed: %m"); - exit(1); - } - /* get the LUID for system-time privilege. */ - LookupPrivilegeValue(NULL, SE_SYSTEMTIME_NAME, &tkp.Privileges[0].Luid); - tkp.PrivilegeCount = 1; /* one privilege to set */ - tkp.Privileges[0].Attributes = SE_PRIVILEGE_ENABLED; - /* get set-time privilege for this process. */ - AdjustTokenPrivileges(hToken, FALSE, &tkp, 0, (PTOKEN_PRIVILEGES) NULL, 0); - /* cannot test return value of AdjustTokenPrivileges. */ - if (GetLastError() != ERROR_SUCCESS) { - msyslog(LOG_ERR, "AdjustTokenPrivileges failed: %m"); - } - /* * Set up timer interrupts for every 2**EVENT_TIMEOUT seconds * Under Windows/NT, @@ -253,26 +237,25 @@ #endif /* - * timer - dispatch anyone who needs to be + * timer - event timer */ void timer(void) { register struct peer *peer, *next_peer; -#ifdef OPENSSL - char statstr[NTP_MAXSTRLEN]; /* statistics for filegen */ -#endif /* OPENSSL */ - u_int n; - - current_time += (1<next; - if (peer->action && peer->nextaction <= current_time) - peer->action(peer); + if (peer->action && peer->nextaction <= + current_time) + peer->action(peer); + + /* + * Restrain the non-burst packet rate not more + * than one packet every 16 seconds. This is + * usually tripped using iburst and minpoll of + * 128 s or less. + */ + if (peer->throttle > 0) + peer->throttle--; if (peer->nextdate <= current_time) { #ifdef REFCLOCK if (peer->flags & FLAG_REFCLOCK) @@ -308,15 +301,61 @@ } /* - * Garbage collect expired keys. - */ - if (keys_timer <= current_time) { - keys_timer += MINUTE; - auth_agekeys(); + * Orphan mode is active when enabled and when no servers less + * than the orphan statum are available. A server with no other + * synchronization source is an orphan It shows offset zero and + * reference ID the loopback address. + */ + if (sys_orphan < STRATUM_UNSPEC && sys_peer == NULL) { + if (sys_leap == LEAP_NOTINSYNC) { + sys_leap = LEAP_NOWARNING; +#ifdef OPENSSL + if (crypto_flags) + crypto_update(); +#endif /* OPENSSL */ + } + sys_stratum = (u_char)sys_orphan; + if (sys_stratum > 1) + sys_refid = htonl(LOOPBACKADR); + else + memcpy(&sys_refid, "LOOP", 4); + sys_offset = 0; + sys_rootdelay = 0; + sys_rootdisp = 0; + } + + /* + * Leapseconds. If a leap is pending, decrement the time + * remaining. If less than one day remains, set the leap bits. + * When no time remains, clear the leap bits and increment the + * TAI. If kernel suppport is not available, do the leap + * crudely. Note a leap cannot be pending unless the clock is + * set. + */ + if (leapsec > 0) { + leapsec--; + if (leapsec == 0) { + sys_leap = LEAP_NOWARNING; + sys_tai = leap_tai; +#ifdef KERNEL_PLL + if (!(pll_control && kern_enable)) + step_systime(-1.0); +#else /* KERNEL_PLL */ +#ifndef SYS_WINNT /* WinNT port has its own leap second handling */ + step_systime(-1.0); +#endif /* SYS_WINNT */ +#endif /* KERNEL_PLL */ + report_event(EVNT_LEAP, NULL, NULL); + } else { + if (leapsec < DAY) + sys_leap = LEAP_ADDSECOND; + if (leap_tai > 0) + sys_tai = leap_tai - 1; + } } /* - * Huff-n'-puff filter + * Update huff-n'-puff filter. */ if (huffpuff_timer <= current_time) { huffpuff_timer += HUFFPUFF; @@ -325,37 +364,44 @@ #ifdef OPENSSL /* - * Garbage collect old keys and generate new private value + * Garbage collect expired keys. */ - if (revoke_timer <= current_time) { - revoke_timer += RANDPOLL(sys_revoke); - expire_all(); - sprintf(statstr, "refresh ts %u", ntohl(hostval.tstamp)); - record_crypto_stats(NULL, statstr); -#ifdef DEBUG - if (debug) - printf("timer: %s\n", statstr); -#endif + if (keys_timer <= current_time) { + keys_timer += 1 << sys_automax; + auth_agekeys(); + } + + /* + * Garbage collect key list and generate new private value. The + * timer runs only after initial synchronization and fires about + * once per day. + */ + if (revoke_timer <= current_time && sys_leap != + LEAP_NOTINSYNC) { + revoke_timer += 1 << sys_revoke; + RAND_bytes((u_char *)&sys_private, 4); } #endif /* OPENSSL */ /* - * interface update timer + * Interface update timer */ if (interface_interval && interface_timer <= current_time) { - timer_interfacetimeout(current_time + interface_interval); - DPRINTF(1, ("timer: interface update\n")); + timer_interfacetimeout(current_time + + interface_interval); + DPRINTF(2, ("timer: interface update\n")); interface_update(NULL, NULL); } /* - * Finally, periodically write stats. + * Finally, write hourly stats. */ if (stats_timer <= current_time) { - if (stats_timer != 0) - write_stats(); - stats_timer += stats_write_period; + stats_timer += HOUR; + write_stats(); + if (sys_tai != 0 && sys_time.l_ui > leap_expire) + report_event(EVNT_LEAPVAL, NULL, NULL); } } diff -urN src/contrib/ntp/ntpd/ntp_util.c src.ntp/contrib/ntp/ntpd/ntp_util.c --- src/contrib/ntp/ntpd/ntp_util.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/ntp_util.c 2009-12-09 08:36:35.000000000 +0100 @@ -1,7 +1,6 @@ /* * ntp_util.c - stuff I didn't have any other place for */ - #ifdef HAVE_CONFIG_H # include #endif @@ -12,6 +11,7 @@ #include "ntp_filegen.h" #include "ntp_if.h" #include "ntp_stdlib.h" +#include "ntp_assert.h" #include #include @@ -38,24 +38,29 @@ #endif /* VMS */ /* - * This contains odds and ends. Right now the only thing you'll find - * in here is the hourly stats printer and some code to support - * rereading the keys file, but I may eventually put other things in - * here such as code to do something with the leap bits. + * Defines used by the leapseconds stuff */ +#define MAX_TAI 100 /* max TAI offset (s) */ +#define L_DAY 86400UL /* seconds per day */ +#define L_YEAR (L_DAY * 365) /* days per year */ +#define L_LYEAR (L_YEAR + L_DAY) /* days per leap year */ +#define L_4YEAR (L_LYEAR + 3 * L_YEAR) /* days per leap cycle */ +#define L_CENT (L_4YEAR * 25) /* days per century */ + /* - * Name of the keys file + * This contains odds and ends, including the hourly stats, various + * configuration items, leapseconds stuff, etc. */ -static char *key_file_name; - /* - * The name of the drift_comp file and the temporary. + * File names */ -static char *stats_drift_file; -static char *stats_temp_file; -int stats_write_period = 3600; /* # of seconds between writes. */ -double stats_write_tolerance = 0; -static double prev_drift_comp = 99999.; +static char *key_file_name; /* keys file name */ +char *leapseconds_file_name; /* leapseconds file name */ +char *stats_drift_file; /* frequency file name */ +static char *stats_temp_file; /* temp frequency file name */ +double wander_resid; /* wander threshold */ +double wander_threshold = 1e-7; /* initial wander threshold */ +int drift_file_sw; /* clock update switch */ /* * Statistics file stuff @@ -64,7 +69,7 @@ # ifndef SYS_WINNT # define NTP_VAR "/var/NTP/" /* NOTE the trailing '/' */ # else -# define NTP_VAR "c:\\var\\ntp\\" /* NOTE the trailing '\\' */ +# define NTP_VAR "c:\\var\\ntp\\" /* NOTE the trailing '\\' */ # endif /* SYS_WINNT */ #endif @@ -72,13 +77,6 @@ # define MAXPATHLEN 256 #endif -static char statsdir[MAXPATHLEN] = NTP_VAR; - -static FILEGEN peerstats; -static FILEGEN loopstats; -static FILEGEN clockstats; -static FILEGEN rawstats; -static FILEGEN sysstats; #ifdef DEBUG_TIMING static FILEGEN timingstats; #endif @@ -86,6 +84,14 @@ static FILEGEN cryptostats; #endif /* OPENSSL */ +static char statsdir[MAXPATHLEN] = NTP_VAR; +static FILEGEN peerstats; +static FILEGEN loopstats; +static FILEGEN clockstats; +static FILEGEN rawstats; +static FILEGEN sysstats; +static FILEGEN protostats; + /* * This controls whether stats are written to the fileset. Provided * so that ntpdc can turn off stats when the file system fills up. @@ -95,35 +101,87 @@ /* * Initial frequency offset later passed to the loopfilter. */ -double old_drift; +double old_drift = 1e9; /* current frequency */ +static double prev_drift_comp; /* last frequency update */ /* - * init_util - initialize the utilities + * Static prototypes */ -void -init_util(void) -{ - stats_drift_file = 0; - stats_temp_file = 0; - key_file_name = 0; +static int leap_file(FILE *); +static void record_sys_stats(void); - filegen_register(&statsdir[0], "peerstats", &peerstats); +/* + * Prototypes + */ +#ifdef DEBUG +void uninit_util(void); +#endif - filegen_register(&statsdir[0], "loopstats", &loopstats); - filegen_register(&statsdir[0], "clockstats", &clockstats); +/* + * uninit_util - free memory allocated by init_util + */ +#ifdef DEBUG +void +uninit_util(void) +{ +#if defined(_MSC_VER) && defined (_DEBUG) + _CrtCheckMemory(); +#endif + if (stats_drift_file) { + free(stats_drift_file); + free(stats_temp_file); + stats_drift_file = NULL; + stats_temp_file = NULL; + } + if (key_file_name) { + free(key_file_name); + key_file_name = NULL; + } + filegen_unregister("peerstats"); + filegen_unregister("loopstats"); + filegen_unregister("clockstats"); + filegen_unregister("rawstats"); + filegen_unregister("sysstats"); + filegen_unregister("protostats"); +#ifdef OPENSSL + filegen_unregister("cryptostats"); +#endif /* OPENSSL */ +#ifdef DEBUG_TIMING + filegen_unregister("timingstats"); +#endif /* DEBUG_TIMING */ - filegen_register(&statsdir[0], "rawstats", &rawstats); +#if defined(_MSC_VER) && defined (_DEBUG) + _CrtCheckMemory(); +#endif +} +#endif /* DEBUG */ - filegen_register(&statsdir[0], "sysstats", &sysstats); +/* + * init_util - initialize the utilities (ntpd included) + */ +void +init_util(void) +{ + stats_drift_file = NULL; + stats_temp_file = NULL; + key_file_name = NULL; + filegen_register(statsdir, "peerstats", &peerstats); + filegen_register(statsdir, "loopstats", &loopstats); + filegen_register(statsdir, "clockstats", &clockstats); + filegen_register(statsdir, "rawstats", &rawstats); + filegen_register(statsdir, "sysstats", &sysstats); + filegen_register(statsdir, "protostats", &protostats); #ifdef OPENSSL - filegen_register(&statsdir[0], "cryptostats", &cryptostats); + filegen_register(statsdir, "cryptostats", &cryptostats); #endif /* OPENSSL */ - #ifdef DEBUG_TIMING - filegen_register(&statsdir[0], "timingstats", &timingstats); -#endif + filegen_register(statsdir, "timingstats", &timingstats); +#endif /* DEBUG_TIMING */ +#ifdef DEBUG + atexit(uninit_util); +#endif /* DEBUG */ } @@ -133,17 +191,17 @@ void write_stats(void) { - FILE *fp; - + FILE *fp; + double ftemp; #ifdef DOSYNCTODR struct timeval tv; #if !defined(VMS) - int prio_set; + int prio_set; #endif #ifdef HAVE_GETCLOCK struct timespec ts; #endif - int o_prio; + int o_prio; /* * Sometimes having a Sun can be a drag. @@ -168,7 +226,8 @@ */ #if !defined(VMS) - /* (prr) getpriority returns -1 on error, but -1 is also a valid + /* + * (prr) getpriority returns -1 on error, but -1 is also a valid * return value (!), so instead we have to zero errno before the * call and check it for non-zero afterwards. */ @@ -198,63 +257,87 @@ #else /* not HAVE_GETCLOCK */ GETTIMEOFDAY(&tv,(struct timezone *)NULL); #endif /* not HAVE_GETCLOCK */ - if (ntp_set_tod(&tv,(struct timezone *)NULL) != 0) { + if (ntp_set_tod(&tv,(struct timezone *)NULL) != 0) msyslog(LOG_ERR, "can't sync battery time: %m"); - } #if !defined(VMS) if (prio_set) setpriority(PRIO_PROCESS, 0, o_prio); /* downshift */ #endif /* VMS */ #endif /* DOSYNCTODR */ - - NLOG(NLOG_SYSSTATIST) - msyslog(LOG_INFO, - "offset %.6f sec freq %.3f ppm error %.6f poll %d", - last_offset, drift_comp * 1e6, sys_jitter, - sys_poll); - - record_sys_stats(); - if ((u_long)(fabs(prev_drift_comp - drift_comp) * 1e9) <= - (u_long)(fabs(stats_write_tolerance * drift_comp) * 1e9)) { - return; - } + ftemp = fabs(prev_drift_comp - drift_comp); prev_drift_comp = drift_comp; - if (stats_drift_file != 0) { - if ((fp = fopen(stats_temp_file, "w")) == NULL) { - msyslog(LOG_ERR, "can't open %s: %m", - stats_temp_file); - return; - } - fprintf(fp, "%.3f\n", drift_comp * 1e6); - (void)fclose(fp); - /* atomic */ + if (ftemp > clock_phi) + return; + + if (stats_drift_file != 0 && drift_file_sw) { + + /* + * When the frequency file is written, initialize the + * wander threshold to a configured initial value. + * Thereafter reduce it by a factor of 0.5. When it + * drops below the frequency wander, write the frequency + * file. This adapts to the prevailing wander yet + * minimizes the file writes. + */ + drift_file_sw = FALSE; + wander_resid *= 0.5; +#ifdef DEBUG + if (debug) + printf("write_stats: wander %.6lf thresh %.6lf, freq %.6lf\n", + clock_stability * 1e6, wander_resid * 1e6, + drift_comp * 1e6); +#endif + if (sys_leap != LEAP_NOTINSYNC && clock_stability > + wander_resid) { + wander_resid = wander_threshold; + if ((fp = fopen(stats_temp_file, "w")) == NULL) + { + msyslog(LOG_ERR, + "frequency file %s: %m", + stats_temp_file); + return; + } + fprintf(fp, "%.3f\n", drift_comp * 1e6); + (void)fclose(fp); + /* atomic */ #ifdef SYS_WINNT - (void) _unlink(stats_drift_file); /* rename semantics differ under NT */ + if (_unlink(stats_drift_file)) /* rename semantics differ under NT */ + msyslog(LOG_WARNING, + "Unable to remove prior drift file %s, %m", + stats_drift_file); #endif /* SYS_WINNT */ #ifndef NO_RENAME - (void) rename(stats_temp_file, stats_drift_file); + if (rename(stats_temp_file, stats_drift_file)) + msyslog(LOG_WARNING, + "Unable to rename temp drift file %s to %s, %m", + stats_temp_file, stats_drift_file); #else - /* we have no rename NFS of ftp in use */ - if ((fp = fopen(stats_drift_file, "w")) == NULL) { - msyslog(LOG_ERR, "can't open %s: %m", - stats_drift_file); - return; - } - + /* we have no rename NFS of ftp in use */ + if ((fp = fopen(stats_drift_file, "w")) == + NULL) { + msyslog(LOG_ERR, + "frequency file %s: %m", + stats_drift_file); + return; + } #endif #if defined(VMS) - /* PURGE */ - { - $DESCRIPTOR(oldvers,";-1"); - struct dsc$descriptor driftdsc = { - strlen(stats_drift_file),0,0,stats_drift_file }; - - while(lib$delete_file(&oldvers,&driftdsc) & 1) ; - } + /* PURGE */ + { + $DESCRIPTOR(oldvers,";-1"); + struct dsc$descriptor driftdsc = { + strlen(stats_drift_file), 0, 0, + stats_drift_file }; + while(lib$delete_file(&oldvers, + &driftdsc) & 1); + } #endif + } else { + /* XXX: Log a message at INFO level */ + } } } @@ -268,9 +351,11 @@ const char *invalue /* only one type so far */ ) { - FILE *fp; + FILE *fp; const char *value; - int len; + int len; + char tbuf[80]; + char str1[20], str2[20]; /* * Expand environment strings under Windows NT, since the @@ -284,20 +369,27 @@ case STATS_FREQ_FILE: strcpy(parameter,"STATS_FREQ_FILE"); break; + + case STATS_LEAP_FILE: + strcpy(parameter,"STATS_LEAP_FILE"); + break; + case STATS_STATSDIR: strcpy(parameter,"STATS_STATSDIR"); break; + case STATS_PID_FILE: strcpy(parameter,"STATS_PID_FILE"); break; + default: strcpy(parameter,"UNKNOWN"); break; } value = invalue; - msyslog(LOG_ERR, - "ExpandEnvironmentStrings(%s) failed: %m\n", parameter); + "ExpandEnvironmentStrings(%s) failed: %m\n", + parameter); } else { value = newvalue; } @@ -306,67 +398,81 @@ #endif /* SYS_WINNT */ switch(item) { - case STATS_FREQ_FILE: - if (stats_drift_file != 0) { - (void) free(stats_drift_file); - (void) free(stats_temp_file); - stats_drift_file = 0; - stats_temp_file = 0; - } - if (value == 0 || (len = strlen(value)) == 0) - break; + /* + * Open and read frequency file. + */ + case STATS_FREQ_FILE: + if (!value || (len = strlen(value)) == 0) + break; + + stats_drift_file = erealloc(stats_drift_file, len + 1); + stats_temp_file = erealloc(stats_temp_file, + len + sizeof(".TEMP")); - stats_drift_file = (char*)emalloc((u_int)(len + 1)); -#if !defined(VMS) - stats_temp_file = (char*)emalloc((u_int)(len + - sizeof(".TEMP"))); -#else - stats_temp_file = (char*)emalloc((u_int)(len + - sizeof("-TEMP"))); -#endif /* VMS */ memmove(stats_drift_file, value, (unsigned)(len+1)); memmove(stats_temp_file, value, (unsigned)len); + memmove(stats_temp_file + len, #if !defined(VMS) - memmove(stats_temp_file + len, ".TEMP", - sizeof(".TEMP")); + ".TEMP", sizeof(".TEMP")); #else - memmove(stats_temp_file + len, "-TEMP", - sizeof("-TEMP")); + "-TEMP", sizeof("-TEMP")); #endif /* VMS */ /* * Open drift file and read frequency. If the file is * missing or contains errors, tell the loop to reset. */ - if ((fp = fopen(stats_drift_file, "r")) == NULL) { - old_drift = 1e9; + if ((fp = fopen(stats_drift_file, "r")) == NULL) break; - } + if (fscanf(fp, "%lf", &old_drift) != 1) { - msyslog(LOG_ERR, "Frequency format error in %s", - stats_drift_file); - old_drift = 1e9; + msyslog(LOG_ERR, + "format error frequency file %s", + stats_drift_file); fclose(fp); break; + } fclose(fp); - prev_drift_comp = old_drift / 1e6; - msyslog(LOG_INFO, - "frequency initialized %.3f PPM from %s", - old_drift, stats_drift_file); + old_drift /= 1e6; + prev_drift_comp = old_drift; break; - - case STATS_STATSDIR: + + /* + * Specify statistics directory. + */ + case STATS_STATSDIR: + + /* + * HMS: the following test is insufficient: + * - value may be missing the DIR_SEP + * - we still need the filename after it + */ if (strlen(value) >= sizeof(statsdir)) { msyslog(LOG_ERR, - "value for statsdir too long (>%d, sigh)", - (int)sizeof(statsdir)-1); + "statsdir too long (>%d, sigh)", + (int)sizeof(statsdir) - 1); } else { l_fp now; + int add_dir_sep; + int value_l = strlen(value); + + /* Add a DIR_SEP unless we already have one. */ + if (value_l == 0) + add_dir_sep = 0; + else + add_dir_sep = (DIR_SEP != + value[value_l - 1]); + + if (add_dir_sep) + snprintf(statsdir, sizeof(statsdir), + "%s%c", value, DIR_SEP); + else + snprintf(statsdir, sizeof(statsdir), + "%s", value); get_systime(&now); - strcpy(statsdir,value); if(peerstats.prefix == &statsdir[0] && peerstats.fp != NULL) { fclose(peerstats.fp); @@ -397,6 +503,12 @@ sysstats.fp = NULL; filegen_setup(&sysstats, now.l_ui); } + if(protostats.prefix == &statsdir[0] && + protostats.fp != NULL) { + fclose(protostats.fp); + protostats.fp = NULL; + filegen_setup(&protostats, now.l_ui); + } #ifdef OPENSSL if(cryptostats.prefix == &statsdir[0] && cryptostats.fp != NULL) { @@ -405,45 +517,83 @@ filegen_setup(&cryptostats, now.l_ui); } #endif /* OPENSSL */ +#ifdef DEBUG_TIMING + if(timingstats.prefix == &statsdir[0] && + timingstats.fp != NULL) { + fclose(timingstats.fp); + timingstats.fp = NULL; + filegen_setup(&timingstats, now.l_ui); + } +#endif /* DEBUG_TIMING */ } break; - case STATS_PID_FILE: + /* + * Open pid file. + */ + case STATS_PID_FILE: if ((fp = fopen(value, "w")) == NULL) { - msyslog(LOG_ERR, "Can't open %s: %m", value); + msyslog(LOG_ERR, "pid file %s: %m", + value); break; } - fprintf(fp, "%d", (int) getpid()); + fprintf(fp, "%d", (int)getpid()); fclose(fp);; break; - default: + /* + * Read leapseconds file. + */ + case STATS_LEAP_FILE: + if ((fp = fopen(value, "r")) == NULL) { + msyslog(LOG_ERR, "leapseconds file %s: %m", + value); + break; + } + + if (leap_file(fp) < 0) { + msyslog(LOG_ERR, + "format error leapseconds file %s", + value); + } else { + strcpy(str1, fstostr(leap_sec)); + strcpy(str2, fstostr(leap_expire)); + snprintf(tbuf, sizeof(tbuf), + "%d leap %s expire %s", leap_tai, str1, + str2); + report_event(EVNT_TAI, NULL, tbuf); + } + fclose(fp); + break; + + default: /* oh well */ break; } } + /* * record_peer_stats - write peer statistics to file * * file format: - * day (mjd) + * day (MJD) * time (s past UTC midnight) - * peer (ip address) - * peer status word (hex) - * peer offset (s) - * peer delay (s) - * peer error bound (s) - * peer error (s) + * IP address + * status word (hex) + * offset + * delay + * dispersion + * jitter */ void record_peer_stats( - struct sockaddr_storage *addr, + sockaddr_u *addr, int status, - double offset, - double delay, - double dispersion, - double skew + double offset, /* offset */ + double delay, /* delay */ + double dispersion, /* dispersion */ + double jitter /* jitter */ ) { l_fp now; @@ -458,29 +608,32 @@ now.l_ui %= 86400; if (peerstats.fp != NULL) { fprintf(peerstats.fp, - "%lu %s %s %x %.9f %.9f %.9f %.9f\n", - day, ulfptoa(&now, 3), stoa(addr), status, offset, - delay, dispersion, skew); + "%lu %s %s %x %.9f %.9f %.9f %.9f\n", day, + ulfptoa(&now, 3), stoa(addr), status, offset, + delay, dispersion, jitter); fflush(peerstats.fp); } } + /* * record_loop_stats - write loop filter statistics to file * * file format: - * day (mjd) + * day (MJD) * time (s past midnight) - * offset (s) - * frequency (approx ppm) - * time constant (log base 2) + * offset + * frequency (PPM) + * jitter + * wnder (PPM) + * time constant (log2) */ void record_loop_stats( - double offset, - double freq, - double jitter, - double stability, + double offset, /* offset */ + double freq, /* frequency (PPM) */ + double jitter, /* jitter */ + double wander, /* wander (PPM) */ int spoll ) { @@ -497,24 +650,25 @@ if (loopstats.fp != NULL) { fprintf(loopstats.fp, "%lu %s %.9f %.3f %.9f %.6f %d\n", day, ulfptoa(&now, 3), offset, freq * 1e6, jitter, - stability * 1e6, spoll); + wander * 1e6, spoll); fflush(loopstats.fp); } } + /* * record_clock_stats - write clock statistics to file * * file format: - * day (mjd) + * day (MJD) * time (s past midnight) - * peer (ip address) + * IP address * text message */ void record_clock_stats( - struct sockaddr_storage *addr, - const char *text + sockaddr_u *addr, + const char *text /* timecode string */ ) { l_fp now; @@ -528,30 +682,31 @@ day = now.l_ui / 86400 + MJD_1900; now.l_ui %= 86400; if (clockstats.fp != NULL) { - fprintf(clockstats.fp, "%lu %s %s %s\n", - day, ulfptoa(&now, 3), stoa(addr), text); + fprintf(clockstats.fp, "%lu %s %s %s\n", day, + ulfptoa(&now, 3), stoa(addr), text); fflush(clockstats.fp); } } + /* * record_raw_stats - write raw timestamps to file * - * * file format + * day (MJD) * time (s past midnight) * peer ip address - * local ip address + * IP address * t1 t2 t3 t4 timestamps */ void record_raw_stats( - struct sockaddr_storage *srcadr, - struct sockaddr_storage *dstadr, - l_fp *t1, - l_fp *t2, - l_fp *t3, - l_fp *t4 + sockaddr_u *srcadr, + sockaddr_u *dstadr, + l_fp *t1, /* originate timestamp */ + l_fp *t2, /* receive timestamp */ + l_fp *t3, /* transmit timestamp */ + l_fp *t4 /* destination timestamp */ ) { l_fp now; @@ -565,10 +720,10 @@ day = now.l_ui / 86400 + MJD_1900; now.l_ui %= 86400; if (rawstats.fp != NULL) { - fprintf(rawstats.fp, "%lu %s %s %s %s %s %s %s\n", - day, ulfptoa(&now, 3), stoa(srcadr), dstadr ? stoa(dstadr) : "-", - ulfptoa(t1, 9), ulfptoa(t2, 9), ulfptoa(t3, 9), - ulfptoa(t4, 9)); + fprintf(rawstats.fp, "%lu %s %s %s %s %s %s %s\n", day, + ulfptoa(&now, 3), stoa(srcadr), dstadr ? + stoa(dstadr) : "-", ulfptoa(t1, 9), ulfptoa(t2, 9), + ulfptoa(t3, 9), ulfptoa(t4, 9)); fflush(rawstats.fp); } } @@ -578,17 +733,19 @@ * record_sys_stats - write system statistics to file * * file format + * day (MJD) * time (s past midnight) - * time since startup (hr) + * time since reset * packets recieved - * packets processed + * packets for this host * current version - * previous version - * bad version + * old version * access denied * bad length or format * bad authentication + * declined * rate exceeded + * KoD sent */ void record_sys_stats(void) @@ -605,18 +762,49 @@ now.l_ui %= 86400; if (sysstats.fp != NULL) { fprintf(sysstats.fp, - "%lu %s %lu %lu %lu %lu %lu %lu %lu %lu %lu %lu\n", - day, ulfptoa(&now, 3), sys_stattime / 3600, - sys_received, sys_processed, sys_newversionpkt, - sys_oldversionpkt, sys_unknownversion, - sys_restricted, sys_badlength, sys_badauth, - sys_limitrejected); + "%lu %s %lu %lu %lu %lu %lu %lu %lu %lu %lu %lu %lu\n", + day, ulfptoa(&now, 3), current_time - sys_stattime, + sys_received, sys_processed, sys_newversion, + sys_oldversion, sys_restricted, sys_badlength, + sys_badauth, sys_declined, sys_limitrejected, + sys_kodsent); fflush(sysstats.fp); proto_clr_stats(); } } +/* + * record_proto_stats - write system statistics to file + * + * file format + * day (MJD) + * time (s past midnight) + * text message + */ +void +record_proto_stats( + char *str /* text string */ + ) +{ + l_fp now; + u_long day; + + if (!stats_control) + return; + + get_systime(&now); + filegen_setup(&protostats, now.l_ui); + day = now.l_ui / 86400 + MJD_1900; + now.l_ui %= 86400; + if (protostats.fp != NULL) { + fprintf(protostats.fp, "%lu %s %s\n", day, + ulfptoa(&now, 3), str); + fflush(protostats.fp); + } +} + + #ifdef OPENSSL /* * record_crypto_stats - write crypto statistics to file @@ -624,13 +812,13 @@ * file format: * day (mjd) * time (s past midnight) - * peer (ip address) + * peer ip address * text message */ void record_crypto_stats( - struct sockaddr_storage *addr, - const char *text + sockaddr_u *addr, + const char *text /* text message */ ) { l_fp now; @@ -645,7 +833,7 @@ now.l_ui %= 86400; if (cryptostats.fp != NULL) { if (addr == NULL) - fprintf(cryptostats.fp, "%lu %s %s\n", + fprintf(cryptostats.fp, "%lu %s 0.0.0.0 %s\n", day, ulfptoa(&now, 3), text); else fprintf(cryptostats.fp, "%lu %s %s %s\n", @@ -655,9 +843,10 @@ } #endif /* OPENSSL */ + #ifdef DEBUG_TIMING /* - * record_crypto_stats - write crypto statistics to file + * record_timing_stats - write timing statistics to file * * file format: * day (mjd) @@ -666,7 +855,7 @@ */ void record_timing_stats( - const char *text + const char *text /* text message */ ) { static unsigned int flshcnt; @@ -681,13 +870,140 @@ day = now.l_ui / 86400 + MJD_1900; now.l_ui %= 86400; if (timingstats.fp != NULL) { - fprintf(timingstats.fp, "%lu %s %s\n", - day, lfptoa(&now, 3), text); + fprintf(timingstats.fp, "%lu %s %s\n", day, lfptoa(&now, + 3), text); if (++flshcnt % 100 == 0) fflush(timingstats.fp); } } #endif + + +/* + * leap_file - read leapseconds file + * + * Read the ERTS leapsecond file in NIST text format and extract the + * NTP seconds of the latest leap and TAI offset after the leap. + */ +static int +leap_file( + FILE *fp /* file handle */ + ) +{ + char buf[NTP_MAXSTRLEN]; /* file line buffer */ + u_long leap; /* NTP time at leap */ + u_long expire; /* NTP time when file expires */ + int offset; /* TAI offset at leap (s) */ + int i; + + /* + * Read and parse the leapseconds file. Empty lines and comments + * are ignored. A line beginning with #@ contains the file + * expiration time in NTP seconds. Other lines begin with two + * integers followed by junk or comments. The first integer is + * the NTP seconds at the leap, the second is the TAI offset + * after the leap. + */ + offset = 0; + leap = 0; + expire = 0; + i = 10; + while (fgets(buf, NTP_MAXSTRLEN - 1, fp) != NULL) { + if (strlen(buf) < 1) + continue; + + if (buf[0] == '#') { + if (strlen(buf) < 3) + continue; + + /* + * Note the '@' flag was used only in the 2006 + * table; previious to that the flag was '$'. + */ + if (buf[1] == '@' || buf[1] == '$') { + if (sscanf(&buf[2], "%lu", &expire) != + 1) + return (-1); + + continue; + } + } + if (sscanf(buf, "%lu %d", &leap, &offset) == 2) { + + /* + * Valid offsets must increase by one for each + * leap. + */ + if (i++ != offset) + return (-1); + } + } + + /* + * There must be at least one leap. + */ + if (i == 10) + return (-1); + + leap_tai = offset; + leap_sec = leap; + leap_expire = expire; + return (0); +} + + +/* + * leap_month - returns seconds until the end of the month. + */ +u_long +leap_month( + u_long sec /* current NTP second */ + ) +{ + u_long ltemp; + u_long *ptr; + u_long year[] = {31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, + 31}; + u_long lyear[] = {31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, + 31}; + + /* + * Find current leap cycle. + */ + ltemp = sec; + while (ltemp >= L_CENT) + ltemp -= L_CENT; + while (ltemp >= L_4YEAR) + ltemp -= L_4YEAR; + + /* + * We are within four years of the target. If in leap year, use + * leap year month table; otherwise, use year month table. + */ + if (ltemp < L_LYEAR) { + ptr = lyear; + } else { + ptr = year; + ltemp -= L_LYEAR; + while (ltemp >= L_YEAR) + ltemp -= L_YEAR; + } + + /* + * We are within one year of the target. Find the month of the + * leap. + */ + while (ltemp >= *ptr * L_DAY) + ltemp -= *ptr++ * L_DAY; + + /* + * The result is the number of seconds until the end of the + * month when the leap is to occur. + */ + return (*ptr * L_DAY - ltemp - L_DAY); +} + + /* * getauthkeys - read the authentication keys from the specified file */ @@ -699,30 +1015,21 @@ int len; len = strlen(keyfile); - if (len == 0) + if (!len) return; - if (key_file_name != 0) { - if (len > (int)strlen(key_file_name)) { - (void) free(key_file_name); - key_file_name = 0; - } - } - - if (key_file_name == 0) { #ifndef SYS_WINNT - key_file_name = (char*)emalloc((u_int) (len + 1)); + key_file_name = erealloc(key_file_name, len + 1); + memmove(key_file_name, keyfile, len + 1); #else - key_file_name = (char*)emalloc((u_int) (MAXPATHLEN)); -#endif - } -#ifndef SYS_WINNT - memmove(key_file_name, keyfile, (unsigned)(len+1)); -#else - if (!ExpandEnvironmentStrings(keyfile, key_file_name, MAXPATHLEN)) - { + key_file_name = erealloc(key_file_name, _MAX_PATH); + if (len + 1 > _MAX_PATH) + return; + if (!ExpandEnvironmentStrings(keyfile, key_file_name, + _MAX_PATH)) { msyslog(LOG_ERR, - "ExpandEnvironmentStrings(KEY_FILE) failed: %m\n"); + "ExpandEnvironmentStrings(KEY_FILE) failed: %m"); + strncpy(key_file_name, keyfile, _MAX_PATH); } #endif /* SYS_WINNT */ @@ -736,58 +1043,58 @@ void rereadkeys(void) { - if (key_file_name != 0) - authreadkeys(key_file_name); + if (NULL != key_file_name) + authreadkeys(key_file_name); } + /* - * sock_hash - hash an sockaddr_storage structure + * sock_hash - hash a sockaddr_u structure */ -int +u_short sock_hash( - struct sockaddr_storage *addr + sockaddr_u *addr ) { - int hashVal; - int i; - int len; - char *ch; - + u_int hashVal; + u_int j; + size_t len; + u_char *pch; hashVal = 0; len = 0; + /* * We can't just hash the whole thing because there are hidden * fields in sockaddr_in6 that might be filled in by recvfrom(), * so just use the family, port and address. */ - ch = (char *)&addr->ss_family; - hashVal = 37 * hashVal + (int)*ch; - if (sizeof(addr->ss_family) > 1) { - ch++; - hashVal = 37 * hashVal + (int)*ch; + pch = (u_char *)&AF(addr); + hashVal = 37 * hashVal + *pch; + if (sizeof(AF(addr)) > 1) { + pch++; + hashVal = 37 * hashVal + *pch; } - switch(addr->ss_family) { + switch(AF(addr)) { case AF_INET: - ch = (char *)&((struct sockaddr_in *)addr)->sin_addr; - len = sizeof(struct in_addr); + pch = (u_char *)&SOCK_ADDR4(addr); + len = sizeof(SOCK_ADDR4(addr)); break; + case AF_INET6: - ch = (char *)&((struct sockaddr_in6 *)addr)->sin6_addr; - len = sizeof(struct in6_addr); + pch = (u_char *)&SOCK_ADDR6(addr); + len = sizeof(SOCK_ADDR6(addr)); break; } - for (i = 0; i < len ; i++) - hashVal = 37 * hashVal + (int)*(ch + i); + for (j = 0; j < len ; j++) + hashVal = 37 * hashVal + pch[j]; - hashVal = hashVal % 128; /* % MON_HASH_SIZE hardcoded */ + hashVal = hashVal & NTP_HASH_MASK; - if (hashVal < 0) - hashVal += 128; - - return hashVal; + return (u_short)hashVal; } + #if notyet /* * ntp_exit - document explicitly that ntpd has exited @@ -795,7 +1102,31 @@ void ntp_exit(int retval) { - msyslog(LOG_ERR, "EXITING with return code %d", retval); - exit(retval); + msyslog(LOG_ERR, "EXITING with return code %d", retval); + exit(retval); } #endif + +/* + * fstostr - prettyprint NTP seconds + */ +char * fstostr( + time_t ntp_stamp + ) +{ + static char str[20]; + struct tm * tm; + time_t unix_stamp; + + unix_stamp = ntp_stamp - JAN_1970; + tm = gmtime(&unix_stamp); + if (NULL != tm) + snprintf(str, sizeof(str), + "%04d%02d%02d%02d%02d", + tm->tm_year + 1900, tm->tm_mon + 1, tm->tm_mday, + tm->tm_hour, tm->tm_min); + else + strcpy(str, "gmtime() error"); + + return str; +} diff -urN src/contrib/ntp/ntpd/ntpd-opts.c src.ntp/contrib/ntp/ntpd/ntpd-opts.c --- src/contrib/ntp/ntpd/ntpd-opts.c 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/ntpd-opts.c 2010-07-09 04:23:28.000000000 +0200 @@ -1,11 +1,11 @@ /* * EDIT THIS FILE WITH CAUTION (ntpd-opts.c) * - * It has been AutoGen-ed Tuesday December 8, 2009 at 08:13:10 AM EST + * It has been AutoGen-ed July 9, 2010 at 02:23:28 AM by AutoGen 5.10 * From the definitions ntpd-opts.def * and the template file options * - * Generated from AutoOpts 29:0:4 templates. + * Generated from AutoOpts 33:0:8 templates. */ /* @@ -19,13 +19,15 @@ * * This source file is copyrighted and licensed under the following terms: * - * ntpd copyright 1970-2009 David L. Mills and/or others - all rights reserved + * ntpd copyright (c) 1970-2010 David L. Mills and/or others - all rights reserved * * see html/copyright.html */ - +#include #include +#include +#include #define OPTION_CODE_COMPILE 1 #include "ntpd-opts.h" @@ -33,19 +35,23 @@ #ifdef __cplusplus extern "C" { #endif + +/* TRANSLATORS: choose the translation for option names wisely because you + cannot ever change your mind. */ tSCC zCopyright[] = - "ntpd copyright (c) 1970-2009 David L. Mills and/or others, all rights reserved"; -tSCC zCopyrightNotice[] = - + "ntpd copyright (c) 1970-2010 David L. Mills and/or others, all rights reserved" /* extracted from ../include/copyright.def near line 8 */ +; +tSCC zCopyrightNotice[24] = "see html/copyright.html"; + extern tUsageProc optionUsage; /* * global included definitions */ #ifdef __windows - extern int atoi(const char*); + extern int atoi(const char *); #else # include #endif @@ -59,22 +65,31 @@ #ifndef EXIT_FAILURE # define EXIT_FAILURE 1 #endif + /* - * Ipv4 option description: + * Ipv4 option description with + * "Must also have options" and "Incompatible options": */ tSCC zIpv4Text[] = "Force IPv4 DNS name resolution"; tSCC zIpv4_NAME[] = "IPV4"; tSCC zIpv4_Name[] = "ipv4"; +static const int + aIpv4CantList[] = { + INDEX_OPT_IPV6, NO_EQUIVALENT }; #define IPV4_FLAGS (OPTST_DISABLED) /* - * Ipv6 option description: + * Ipv6 option description with + * "Must also have options" and "Incompatible options": */ tSCC zIpv6Text[] = "Force IPv6 DNS name resolution"; tSCC zIpv6_NAME[] = "IPV6"; tSCC zIpv6_Name[] = "ipv6"; +static const int + aIpv6CantList[] = { + INDEX_OPT_IPV4, NO_EQUIVALENT }; #define IPV6_FLAGS (OPTST_DISABLED) /* @@ -133,11 +148,10 @@ #define DEBUG_LEVEL_FLAGS (OPTST_DISABLED) #else /* disable Debug_Level */ -#define VALUE_OPT_DEBUG_LEVEL NO_EQUIVALENT #define DEBUG_LEVEL_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zDebug_LevelText NULL #define zDebug_Level_NAME NULL -#define zDebug_Level_Name NULL +tSCC zDebug_Level_Name[] = "debug-level"; +tSCC zDebug_LevelText[] = "this package was built using 'configure --disable--debug'"; #endif /* DEBUG */ /* @@ -152,11 +166,10 @@ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) #else /* disable Set_Debug_Level */ -#define VALUE_OPT_SET_DEBUG_LEVEL NO_EQUIVALENT #define SET_DEBUG_LEVEL_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zSet_Debug_LevelText NULL #define zSet_Debug_Level_NAME NULL -#define zSet_Debug_Level_Name NULL +tSCC zSet_Debug_Level_Name[] = "set-debug-level"; +tSCC zSet_Debug_LevelText[] = "this package was built using 'configure --disable--debug'"; #endif /* DEBUG */ /* @@ -181,6 +194,7 @@ /* * Jaildir option description: */ +#ifdef HAVE_DROPROOT tSCC zJaildirText[] = "Jail directory"; tSCC zJaildir_NAME[] = "JAILDIR"; @@ -188,11 +202,18 @@ #define JAILDIR_FLAGS (OPTST_DISABLED \ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) +#else /* disable Jaildir */ +#define JAILDIR_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#define zJaildir_NAME NULL +tSCC zJaildir_Name[] = "jaildir"; +tSCC zJaildirText[] = "built without --enable-clockctl or --enable-linuxcaps"; +#endif /* HAVE_DROPROOT */ + /* * Interface option description: */ tSCC zInterfaceText[] = - "Listen on interface"; + "Listen on an interface name or address"; tSCC zInterface_NAME[] = "INTERFACE"; tSCC zInterface_Name[] = "interface"; #define INTERFACE_FLAGS (OPTST_DISABLED | OPTST_STACKED \ @@ -222,7 +243,7 @@ * Novirtualips option description: */ tSCC zNovirtualipsText[] = - "Do not listen to virtual IPs"; + "Do not listen to virtual interfaces"; tSCC zNovirtualips_NAME[] = "NOVIRTUALIPS"; tSCC zNovirtualips_Name[] = "novirtualips"; #define NOVIRTUALIPS_FLAGS (OPTST_DISABLED) @@ -238,10 +259,9 @@ #define MODIFYMMTIMER_FLAGS (OPTST_DISABLED) #else /* disable Modifymmtimer */ -#define VALUE_OPT_MODIFYMMTIMER NO_EQUIVALENT #define MODIFYMMTIMER_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zModifymmtimerText NULL #define zModifymmtimer_NAME NULL +#define zModifymmtimerText NULL #define zModifymmtimer_Name NULL #endif /* SYS_WINNT */ @@ -303,14 +323,22 @@ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) /* - * Updateinterval option description: + * Saveconfigquit option description: */ -tSCC zUpdateintervalText[] = - "interval in seconds between scans for new or dropped interfaces"; -tSCC zUpdateinterval_NAME[] = "UPDATEINTERVAL"; -tSCC zUpdateinterval_Name[] = "updateinterval"; -#define UPDATEINTERVAL_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_NUMERIC)) +#ifdef SAVECONFIG +tSCC zSaveconfigquitText[] = + "Save parsed configuration and quit"; +tSCC zSaveconfigquit_NAME[] = "SAVECONFIGQUIT"; +tSCC zSaveconfigquit_Name[] = "saveconfigquit"; +#define SAVECONFIGQUIT_FLAGS (OPTST_DISABLED \ + | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) + +#else /* disable Saveconfigquit */ +#define SAVECONFIGQUIT_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#define zSaveconfigquit_NAME NULL +#define zSaveconfigquitText NULL +#define zSaveconfigquit_Name NULL +#endif /* SAVECONFIG */ /* * Statsdir option description: @@ -335,6 +363,7 @@ /* * User option description: */ +#ifdef HAVE_DROPROOT tSCC zUserText[] = "Run as userid (or userid:groupid)"; tSCC zUser_NAME[] = "USER"; @@ -342,6 +371,23 @@ #define USER_FLAGS (OPTST_DISABLED \ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) +#else /* disable User */ +#define USER_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#define zUser_NAME NULL +tSCC zUser_Name[] = "user"; +tSCC zUserText[] = "built without --enable-clockctl or --enable-linuxcaps"; +#endif /* HAVE_DROPROOT */ + +/* + * Updateinterval option description: + */ +tSCC zUpdateintervalText[] = + "interval in seconds between scans for new or dropped interfaces"; +tSCC zUpdateinterval_NAME[] = "UPDATEINTERVAL"; +tSCC zUpdateinterval_Name[] = "updateinterval"; +#define UPDATEINTERVAL_FLAGS (OPTST_DISABLED \ + | OPTST_SET_ARGTYPE(OPARG_TYPE_NUMERIC)) + /* * Var option description: */ @@ -372,16 +418,63 @@ #define SLEW_FLAGS (OPTST_DISABLED) /* - * Help/More_Help/Version option descriptions: + * Usepcc option description: */ -tSCC zHelpText[] = "Display usage information and exit"; -tSCC zHelp_Name[] = "help"; +#ifdef SYS_WINNT +tSCC zUsepccText[] = + "Use CPU cycle counter (Windows only)"; +tSCC zUsepcc_NAME[] = "USEPCC"; +tSCC zUsepcc_Name[] = "usepcc"; +#define USEPCC_FLAGS (OPTST_DISABLED) + +#else /* disable Usepcc */ +#define USEPCC_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#define zUsepcc_NAME NULL +#define zUsepccText NULL +#define zUsepcc_Name NULL +#endif /* SYS_WINNT */ + +/* + * Pccfreq option description: + */ +#ifdef SYS_WINNT +tSCC zPccfreqText[] = + "Force CPU cycle counter use (Windows only)"; +tSCC zPccfreq_NAME[] = "PCCFREQ"; +tSCC zPccfreq_Name[] = "pccfreq"; +#define PCCFREQ_FLAGS (OPTST_DISABLED \ + | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) -tSCC zMore_HelpText[] = "Extended usage information passed thru pager"; -tSCC zMore_Help_Name[] = "more-help"; +#else /* disable Pccfreq */ +#define PCCFREQ_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#define zPccfreq_NAME NULL +#define zPccfreqText NULL +#define zPccfreq_Name NULL +#endif /* SYS_WINNT */ -tSCC zVersionText[] = "Output version information and exit"; -tSCC zVersion_Name[] = "version"; +/* + * Help/More_Help/Version option descriptions: + */ +tSCC zHelpText[] = "Display extended usage information and exit"; +tSCC zHelp_Name[] = "help"; +#ifdef HAVE_WORKING_FORK +#define OPTST_MORE_HELP_FLAGS (OPTST_IMM | OPTST_NO_INIT) +tSCC zMore_Help_Name[] = "more-help"; +tSCC zMore_HelpText[] = "Extended usage information passed thru pager"; +#else +#define OPTST_MORE_HELP_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#define zMore_Help_Name NULL +#define zMore_HelpText NULL +#endif +#ifdef NO_OPTIONAL_OPT_ARGS +# define OPTST_VERSION_FLAGS OPTST_IMM | OPTST_NO_INIT +#else +# define OPTST_VERSION_FLAGS OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ + OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT +#endif + +tSCC zVersionText[] = "Output version information and exit"; +tSCC zVersion_Name[] = "version"; /* * Declare option callback procedures */ @@ -435,25 +528,25 @@ */ static tOptDesc optDesc[ OPTION_CT ] = { { /* entry idx, value */ 0, VALUE_OPT_IPV4, - /* equiv idx, value */ NO_EQUIVALENT, 0, + /* equiv idx, value */ 0, VALUE_OPT_IPV4, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ IPV4_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, + /* must/cannot opts */ NULL, aIpv4CantList, /* option proc */ NULL, /* desc, NAME, name */ zIpv4Text, zIpv4_NAME, zIpv4_Name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ 1, VALUE_OPT_IPV6, - /* equiv idx, value */ NOLIMIT, NOLIMIT, - /* equivalenced to */ INDEX_OPT_IPV4, + /* equiv idx, value */ 1, VALUE_OPT_IPV6, + /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ IPV6_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, + /* must/cannot opts */ NULL, aIpv6CantList, /* option proc */ NULL, /* desc, NAME, name */ zIpv6Text, zIpv6_NAME, zIpv6_Name, /* disablement strs */ NULL, NULL }, @@ -545,7 +638,7 @@ { /* entry idx, value */ 9, VALUE_OPT_PANICGATE, /* equiv idx, value */ 9, VALUE_OPT_PANICGATE, /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, + /* min, max, act ct */ 0, NOLIMIT, 0, /* opt state flags */ PANICGATE_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, @@ -698,16 +791,16 @@ /* desc, NAME, name */ zPropagationdelayText, zPropagationdelay_NAME, zPropagationdelay_Name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 22, VALUE_OPT_UPDATEINTERVAL, - /* equiv idx, value */ 22, VALUE_OPT_UPDATEINTERVAL, + { /* entry idx, value */ 22, VALUE_OPT_SAVECONFIGQUIT, + /* equiv idx, value */ 22, VALUE_OPT_SAVECONFIGQUIT, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ UPDATEINTERVAL_FLAGS, 0, + /* opt state flags */ SAVECONFIGQUIT_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, - /* option proc */ optionNumericVal, - /* desc, NAME, name */ zUpdateintervalText, zUpdateinterval_NAME, zUpdateinterval_Name, + /* option proc */ NULL, + /* desc, NAME, name */ zSaveconfigquitText, zSaveconfigquit_NAME, zSaveconfigquit_Name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ 23, VALUE_OPT_STATSDIR, @@ -746,8 +839,20 @@ /* desc, NAME, name */ zUserText, zUser_NAME, zUser_Name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 26, VALUE_OPT_VAR, - /* equiv idx, value */ 26, VALUE_OPT_VAR, + { /* entry idx, value */ 26, VALUE_OPT_UPDATEINTERVAL, + /* equiv idx, value */ 26, VALUE_OPT_UPDATEINTERVAL, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ UPDATEINTERVAL_FLAGS, 0, + /* last opt argumnt */ { NULL }, + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ optionNumericVal, + /* desc, NAME, name */ zUpdateintervalText, zUpdateinterval_NAME, zUpdateinterval_Name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ 27, VALUE_OPT_VAR, + /* equiv idx, value */ 27, VALUE_OPT_VAR, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, NOLIMIT, 0, /* opt state flags */ VAR_FLAGS, 0, @@ -758,8 +863,8 @@ /* desc, NAME, name */ zVarText, zVar_NAME, zVar_Name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 27, VALUE_OPT_DVAR, - /* equiv idx, value */ 27, VALUE_OPT_DVAR, + { /* entry idx, value */ 28, VALUE_OPT_DVAR, + /* equiv idx, value */ 28, VALUE_OPT_DVAR, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, NOLIMIT, 0, /* opt state flags */ DVAR_FLAGS, 0, @@ -770,8 +875,8 @@ /* desc, NAME, name */ zDvarText, zDvar_NAME, zDvar_Name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 28, VALUE_OPT_SLEW, - /* equiv idx, value */ 28, VALUE_OPT_SLEW, + { /* entry idx, value */ 29, VALUE_OPT_SLEW, + /* equiv idx, value */ 29, VALUE_OPT_SLEW, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ SLEW_FLAGS, 0, @@ -782,18 +887,35 @@ /* desc, NAME, name */ zSlewText, zSlew_NAME, zSlew_Name, /* disablement strs */ NULL, NULL }, -#ifdef NO_OPTIONAL_OPT_ARGS -# define VERSION_OPT_FLAGS OPTST_IMM | OPTST_NO_INIT -#else -# define VERSION_OPT_FLAGS OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ - OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT -#endif + { /* entry idx, value */ 30, VALUE_OPT_USEPCC, + /* equiv idx, value */ 30, VALUE_OPT_USEPCC, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ USEPCC_FLAGS, 0, + /* last opt argumnt */ { NULL }, + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ NULL, + /* desc, NAME, name */ zUsepccText, zUsepcc_NAME, zUsepcc_Name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ 31, VALUE_OPT_PCCFREQ, + /* equiv idx, value */ 31, VALUE_OPT_PCCFREQ, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ PCCFREQ_FLAGS, 0, + /* last opt argumnt */ { NULL }, + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ NULL, + /* desc, NAME, name */ zPccfreqText, zPccfreq_NAME, zPccfreq_Name, + /* disablement strs */ NULL, NULL }, { /* entry idx, value */ INDEX_OPT_VERSION, VALUE_OPT_VERSION, /* equiv idx value */ NO_EQUIVALENT, 0, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ VERSION_OPT_FLAGS, 0, + /* opt state flags */ OPTST_VERSION_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, @@ -801,7 +923,6 @@ /* desc, NAME, name */ zVersionText, NULL, zVersion_Name, /* disablement strs */ NULL, NULL }, -#undef VERSION_OPT_FLAGS { /* entry idx, value */ INDEX_OPT_HELP, VALUE_OPT_HELP, @@ -820,7 +941,7 @@ /* equiv idx value */ NO_EQUIVALENT, 0, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, 0, + /* opt state flags */ OPTST_MORE_HELP_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, @@ -835,7 +956,7 @@ */ tSCC zPROGNAME[] = "NTPD"; tSCC zUsageTitle[] = -"ntpd - NTP daemon program - Ver. 4.2.4p8\n\ +"ntpd - NTP daemon program - Ver. 4.2.6p2\n\ USAGE: %s [ - [] | --[{=| }] ]...\n"; #define zRcName NULL #define apzHomeList NULL @@ -844,7 +965,7 @@ #define zExplain NULL tSCC zDetail[] = "\n\n"; tSCC zFullVersion[] = NTPD_FULL_VERSION; -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optcode.tpl near line 408 */ +/* extracted from /usr/local/gnu/share/autogen/optcode.tpl near line 495 */ #if defined(ENABLE_NLS) # define OPTPROC_BASE OPTPROC_TRANSLATE @@ -854,6 +975,9 @@ # define translate_option_strings NULL #endif /* ENABLE_NLS */ + +#define ntpd_full_usage NULL +#define ntpd_short_usage NULL tOptions ntpdOptions = { OPTIONS_STRUCT_VERSION, 0, NULL, /* original argc + argv */ @@ -876,12 +1000,14 @@ /* * Indexes to special options */ - { INDEX_OPT_MORE_HELP, - 0 /* no option state saving */, - NO_EQUIVALENT /* index of '-#' option */, + { INDEX_OPT_MORE_HELP, /* more-help option index */ + NO_EQUIVALENT, /* save option index */ + NO_EQUIVALENT, /* '-#' option index */ NO_EQUIVALENT /* index of default opt */ }, - 32 /* full option count */, 29 /* user option count */ + 35 /* full option count */, 32 /* user option count */, + ntpd_full_usage, ntpd_short_usage, + NULL, NULL }; /* @@ -892,45 +1018,41 @@ tOptions* pOptions, tOptDesc* pOptDesc ) { + (void)pOptions; USAGE( EXIT_SUCCESS ); } #if ! defined(TEST_NTPD_OPTS) -/* * * * * * * +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * For the set-debug-level option, when DEBUG is #define-d. */ #ifdef DEBUG static void -doOptSet_Debug_Level( - tOptions* pOptions, - tOptDesc* pOptDesc ) +doOptSet_Debug_Level(tOptions* pOptions, tOptDesc* pOptDesc) { - /* extracted from ../include/debug-opt.def, line 29 */ + /* extracted from ntpdbase-opts.def, line 100 */ DESC(DEBUG_LEVEL).optOccCt = atoi( pOptDesc->pzLastArg ); } #endif /* defined DEBUG */ - #endif /* defined(TEST_NTPD_OPTS) */ - -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optmain.tpl near line 92 */ +/* extracted from /usr/local/gnu/share/autogen/optmain.tpl near line 109 */ #if defined(TEST_NTPD_OPTS) /* TEST MAIN PROCEDURE: */ +extern void optionPutShell( tOptions* ); + int -main( int argc, char** argv ) +main(int argc, char** argv) { int res = EXIT_SUCCESS; (void)optionProcess( &ntpdOptions, argc, argv ); - { - void optionPutShell( tOptions* ); - optionPutShell( &ntpdOptions ); - } + optionPutShell( &ntpdOptions ); return res; } #endif /* defined TEST_NTPD_OPTS */ -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optcode.tpl near line 514 */ +/* extracted from /usr/local/gnu/share/autogen/optcode.tpl near line 627 */ #if ENABLE_NLS #include @@ -973,44 +1095,45 @@ * Guard against re-translation. It won't work. The strings will have * been changed by the first pass through this code. One shot only. */ - if (option_usage_text.field_ct == 0) - return; - /* - * Do the translations. The first pointer follows the field count field. - * The field count field is the size of a pointer. - */ - { - char** ppz = (char**)(void*)&(option_usage_text); - int ix = option_usage_text.field_ct; + if (option_usage_text.field_ct != 0) { + + /* + * Do the translations. The first pointer follows the field count + * field. The field count field is the size of a pointer. + */ + tOptDesc* pOD = ntpdOptions.pOptDesc; + char** ppz = (char**)(void*)&(option_usage_text); + int ix = option_usage_text.field_ct; do { ppz++; *ppz = AO_gettext(*ppz); } while (--ix > 0); + + COERSION(pzCopyright); + COERSION(pzCopyNotice); + COERSION(pzFullVersion); + COERSION(pzUsageTitle); + COERSION(pzExplain); + COERSION(pzDetail); + option_usage_text.field_ct = 0; + + for (ix = ntpdOptions.optCt; ix > 0; ix--, pOD++) + coerce_it((void*)&(pOD->pzText)); } - option_usage_text.field_ct = 0; - { + if ((ntpdOptions.fOptSet & OPTPROC_NXLAT_OPT_CFG) == 0) { tOptDesc* pOD = ntpdOptions.pOptDesc; - int ix = ntpdOptions.optCt; + int ix; - for (;;) { - pOD->pzText = AO_gettext(pOD->pzText); - pOD->pz_NAME = AO_gettext(pOD->pz_NAME); - pOD->pz_Name = AO_gettext(pOD->pz_Name); - pOD->pz_DisableName = AO_gettext(pOD->pz_DisableName); - pOD->pz_DisablePfx = AO_gettext(pOD->pz_DisablePfx); - if (--ix <= 0) - break; - pOD++; + for (ix = ntpdOptions.optCt; ix > 0; ix--, pOD++) { + coerce_it((void*)&(pOD->pz_Name)); + coerce_it((void*)&(pOD->pz_DisableName)); + coerce_it((void*)&(pOD->pz_DisablePfx)); } + /* prevent re-translation */ + ntpdOptions.fOptSet |= OPTPROC_NXLAT_OPT_CFG | OPTPROC_NXLAT_OPT; } - COERSION(pzCopyright); - COERSION(pzCopyNotice); - COERSION(pzFullVersion); - COERSION(pzUsageTitle); - COERSION(pzExplain); - COERSION(pzDetail); } #endif /* ENABLE_NLS */ diff -urN src/contrib/ntp/ntpd/ntpd-opts.h src.ntp/contrib/ntp/ntpd/ntpd-opts.h --- src/contrib/ntp/ntpd/ntpd-opts.h 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/ntpd-opts.h 2010-07-09 04:23:28.000000000 +0200 @@ -1,11 +1,11 @@ /* * EDIT THIS FILE WITH CAUTION (ntpd-opts.h) * - * It has been AutoGen-ed Tuesday December 8, 2009 at 08:13:09 AM EST + * It has been AutoGen-ed July 9, 2010 at 02:23:28 AM by AutoGen 5.10 * From the definitions ntpd-opts.def * and the template file options * - * Generated from AutoOpts 29:0:4 templates. + * Generated from AutoOpts 33:0:8 templates. */ /* @@ -19,7 +19,7 @@ * * This source file is copyrighted and licensed under the following terms: * - * ntpd copyright 1970-2009 David L. Mills and/or others - all rights reserved + * ntpd copyright (c) 1970-2010 David L. Mills and/or others - all rights reserved * * see html/copyright.html */ @@ -30,7 +30,7 @@ * "AutoOpts" chapter. Please refer to that doc for usage help. */ #ifndef AUTOOPTS_NTPD_OPTS_H_GUARD -#define AUTOOPTS_NTPD_OPTS_H_GUARD +#define AUTOOPTS_NTPD_OPTS_H_GUARD 1 #include "config.h" #include @@ -41,7 +41,7 @@ * tolerable version is at least as old as what was current when the header * template was released. */ -#define AO_TEMPLATE_VERSION 118784 +#define AO_TEMPLATE_VERSION 135168 #if (AO_TEMPLATE_VERSION < OPTIONS_MINIMUM_VERSION) \ || (AO_TEMPLATE_VERSION > OPTIONS_STRUCT_VERSION) # error option template version mismatches autoopts/options.h header @@ -52,43 +52,46 @@ * Enumeration of each option: */ typedef enum { - INDEX_OPT_IPV4 = 0, - INDEX_OPT_IPV6 = 1, - INDEX_OPT_AUTHREQ = 2, - INDEX_OPT_AUTHNOREQ = 3, - INDEX_OPT_BCASTSYNC = 4, - INDEX_OPT_CONFIGFILE = 5, - INDEX_OPT_DEBUG_LEVEL = 6, - INDEX_OPT_SET_DEBUG_LEVEL = 7, - INDEX_OPT_DRIFTFILE = 8, - INDEX_OPT_PANICGATE = 9, - INDEX_OPT_JAILDIR = 10, - INDEX_OPT_INTERFACE = 11, - INDEX_OPT_KEYFILE = 12, - INDEX_OPT_LOGFILE = 13, - INDEX_OPT_NOVIRTUALIPS = 14, - INDEX_OPT_MODIFYMMTIMER = 15, - INDEX_OPT_NOFORK = 16, - INDEX_OPT_NICE = 17, - INDEX_OPT_PIDFILE = 18, - INDEX_OPT_PRIORITY = 19, - INDEX_OPT_QUIT = 20, - INDEX_OPT_PROPAGATIONDELAY = 21, - INDEX_OPT_UPDATEINTERVAL = 22, - INDEX_OPT_STATSDIR = 23, - INDEX_OPT_TRUSTEDKEY = 24, - INDEX_OPT_USER = 25, - INDEX_OPT_VAR = 26, - INDEX_OPT_DVAR = 27, - INDEX_OPT_SLEW = 28, - INDEX_OPT_VERSION = 29, - INDEX_OPT_HELP = 30, - INDEX_OPT_MORE_HELP = 31 + INDEX_OPT_IPV4 = 0, + INDEX_OPT_IPV6 = 1, + INDEX_OPT_AUTHREQ = 2, + INDEX_OPT_AUTHNOREQ = 3, + INDEX_OPT_BCASTSYNC = 4, + INDEX_OPT_CONFIGFILE = 5, + INDEX_OPT_DEBUG_LEVEL = 6, + INDEX_OPT_SET_DEBUG_LEVEL = 7, + INDEX_OPT_DRIFTFILE = 8, + INDEX_OPT_PANICGATE = 9, + INDEX_OPT_JAILDIR = 10, + INDEX_OPT_INTERFACE = 11, + INDEX_OPT_KEYFILE = 12, + INDEX_OPT_LOGFILE = 13, + INDEX_OPT_NOVIRTUALIPS = 14, + INDEX_OPT_MODIFYMMTIMER = 15, + INDEX_OPT_NOFORK = 16, + INDEX_OPT_NICE = 17, + INDEX_OPT_PIDFILE = 18, + INDEX_OPT_PRIORITY = 19, + INDEX_OPT_QUIT = 20, + INDEX_OPT_PROPAGATIONDELAY = 21, + INDEX_OPT_SAVECONFIGQUIT = 22, + INDEX_OPT_STATSDIR = 23, + INDEX_OPT_TRUSTEDKEY = 24, + INDEX_OPT_USER = 25, + INDEX_OPT_UPDATEINTERVAL = 26, + INDEX_OPT_VAR = 27, + INDEX_OPT_DVAR = 28, + INDEX_OPT_SLEW = 29, + INDEX_OPT_USEPCC = 30, + INDEX_OPT_PCCFREQ = 31, + INDEX_OPT_VERSION = 32, + INDEX_OPT_HELP = 33, + INDEX_OPT_MORE_HELP = 34 } teOptIndex; -#define OPTION_CT 32 -#define NTPD_VERSION "4.2.4p8" -#define NTPD_FULL_VERSION "ntpd - NTP daemon program - Ver. 4.2.4p8" +#define OPTION_CT 35 +#define NTPD_VERSION "4.2.6p2" +#define NTPD_FULL_VERSION "ntpd - NTP daemon program - Ver. 4.2.6p2" /* * Interface defines for all options. Replace "n" with the UPPER_CASED @@ -203,9 +206,9 @@ # warning undefining PROPAGATIONDELAY due to option name conflict # undef PROPAGATIONDELAY # endif -# ifdef UPDATEINTERVAL -# warning undefining UPDATEINTERVAL due to option name conflict -# undef UPDATEINTERVAL +# ifdef SAVECONFIGQUIT +# warning undefining SAVECONFIGQUIT due to option name conflict +# undef SAVECONFIGQUIT # endif # ifdef STATSDIR # warning undefining STATSDIR due to option name conflict @@ -219,6 +222,10 @@ # warning undefining USER due to option name conflict # undef USER # endif +# ifdef UPDATEINTERVAL +# warning undefining UPDATEINTERVAL due to option name conflict +# undef UPDATEINTERVAL +# endif # ifdef VAR # warning undefining VAR due to option name conflict # undef VAR @@ -231,6 +238,14 @@ # warning undefining SLEW due to option name conflict # undef SLEW # endif +# ifdef USEPCC +# warning undefining USEPCC due to option name conflict +# undef USEPCC +# endif +# ifdef PCCFREQ +# warning undefining PCCFREQ due to option name conflict +# undef PCCFREQ +# endif #else /* NO_OPTION_NAME_WARNINGS */ # undef IPV4 # undef IPV6 @@ -254,32 +269,30 @@ # undef PRIORITY # undef QUIT # undef PROPAGATIONDELAY -# undef UPDATEINTERVAL +# undef SAVECONFIGQUIT # undef STATSDIR # undef TRUSTEDKEY # undef USER +# undef UPDATEINTERVAL # undef VAR # undef DVAR # undef SLEW +# undef USEPCC +# undef PCCFREQ #endif /* NO_OPTION_NAME_WARNINGS */ -/* +/* * * * * * + * * Interface defines for specific options. */ #define VALUE_OPT_IPV4 '4' -#define WHICH_OPT_IPV4 (DESC(IPV4).optActualValue) -#define WHICH_IDX_IPV4 (DESC(IPV4).optActualIndex) #define VALUE_OPT_IPV6 '6' #define VALUE_OPT_AUTHREQ 'a' #define VALUE_OPT_AUTHNOREQ 'A' #define VALUE_OPT_BCASTSYNC 'b' #define VALUE_OPT_CONFIGFILE 'c' -#ifdef DEBUG #define VALUE_OPT_DEBUG_LEVEL 'd' -#endif /* DEBUG */ -#ifdef DEBUG #define VALUE_OPT_SET_DEBUG_LEVEL 'D' -#endif /* DEBUG */ #define VALUE_OPT_DRIFTFILE 'f' #define VALUE_OPT_PANICGATE 'g' #define VALUE_OPT_JAILDIR 'i' @@ -287,28 +300,30 @@ #define VALUE_OPT_KEYFILE 'k' #define VALUE_OPT_LOGFILE 'l' #define VALUE_OPT_NOVIRTUALIPS 'L' -#ifdef SYS_WINNT #define VALUE_OPT_MODIFYMMTIMER 'M' -#endif /* SYS_WINNT */ #define VALUE_OPT_NOFORK 'n' #define VALUE_OPT_NICE 'N' #define VALUE_OPT_PIDFILE 'p' #define VALUE_OPT_PRIORITY 'P' + #define OPT_VALUE_PRIORITY (DESC(PRIORITY).optArg.argInt) #define VALUE_OPT_QUIT 'q' #define VALUE_OPT_PROPAGATIONDELAY 'r' -#define VALUE_OPT_UPDATEINTERVAL 'U' -#define OPT_VALUE_UPDATEINTERVAL (DESC(UPDATEINTERVAL).optArg.argInt) +#define VALUE_OPT_SAVECONFIGQUIT 22 #define VALUE_OPT_STATSDIR 's' #define VALUE_OPT_TRUSTEDKEY 't' #define VALUE_OPT_USER 'u' -#define VALUE_OPT_VAR 'v' -#define VALUE_OPT_DVAR 'V' -#define VALUE_OPT_SLEW 'x' +#define VALUE_OPT_UPDATEINTERVAL 'U' -#define VALUE_OPT_VERSION 'v' +#define OPT_VALUE_UPDATEINTERVAL (DESC(UPDATEINTERVAL).optArg.argInt) +#define VALUE_OPT_VAR 27 +#define VALUE_OPT_DVAR 28 +#define VALUE_OPT_SLEW 'x' +#define VALUE_OPT_USEPCC 30 +#define VALUE_OPT_PCCFREQ 31 #define VALUE_OPT_HELP '?' #define VALUE_OPT_MORE_HELP '!' +#define VALUE_OPT_VERSION INDEX_OPT_VERSION /* * Interface defines not associated with particular options */ @@ -319,7 +334,7 @@ ntpdOptions.pzCurOpt = NULL ) #define START_OPT RESTART_OPT(1) #define USAGE(c) (*ntpdOptions.pUsageProc)( &ntpdOptions, c ) -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/opthead.tpl near line 360 */ +/* extracted from /usr/local/gnu/share/autogen/opthead.tpl near line 409 */ /* * * * * * * @@ -331,18 +346,37 @@ extern tOptions ntpdOptions; -#ifndef _ -# if ENABLE_NLS -# include - static inline char* aoGetsText( char const* pz ) { - if (pz == NULL) return NULL; - return (char*)gettext( pz ); - } -# define _(s) aoGetsText(s) -# else /* ENABLE_NLS */ -# define _(s) s -# endif /* ENABLE_NLS */ -#endif +#if defined(ENABLE_NLS) +# ifndef _ +# include + static inline char* aoGetsText( char const* pz ) { + if (pz == NULL) return NULL; + return (char*)gettext( pz ); + } +# define _(s) aoGetsText(s) +# endif /* _() */ + +# define OPT_NO_XLAT_CFG_NAMES STMTS(ntpdOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT_CFG;) +# define OPT_NO_XLAT_OPT_NAMES STMTS(ntpdOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG;) + +# define OPT_XLAT_CFG_NAMES STMTS(ntpdOptions.fOptSet &= \ + ~(OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG);) +# define OPT_XLAT_OPT_NAMES STMTS(ntpdOptions.fOptSet &= \ + ~OPTPROC_NXLAT_OPT;) + +#else /* ENABLE_NLS */ +# define OPT_NO_XLAT_CFG_NAMES +# define OPT_NO_XLAT_OPT_NAMES + +# define OPT_XLAT_CFG_NAMES +# define OPT_XLAT_OPT_NAMES + +# ifndef _ +# define _(_s) _s +# endif +#endif /* ENABLE_NLS */ #ifdef __cplusplus } diff -urN src/contrib/ntp/ntpd/ntpd-opts.texi src.ntp/contrib/ntp/ntpd/ntpd-opts.texi --- src/contrib/ntp/ntpd/ntpd-opts.texi 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/ntpd-opts.texi 2010-07-09 04:24:03.000000000 +0200 @@ -6,7 +6,7 @@ # # EDIT THIS FILE WITH CAUTION (ntpd-opts.texi) # -# It has been AutoGen-ed Tuesday December 8, 2009 at 08:13:12 AM EST +# It has been AutoGen-ed July 9, 2010 at 02:24:03 AM by AutoGen 5.10 # From the definitions ntpd-opts.def # and the template file aginfo.tpl @end ignore @@ -27,7 +27,7 @@ * ntpd configfile:: configfile option (-c) * ntpd debug-level:: debug-level option (-d) * ntpd driftfile:: driftfile option (-f) -* ntpd dvar:: dvar option (-V) +* ntpd dvar:: dvar option * ntpd interface:: interface option (-I) * ntpd ipv4:: ipv4 option (-4) * ntpd ipv6:: ipv6 option (-6) @@ -39,17 +39,20 @@ * ntpd nofork:: nofork option (-n) * ntpd novirtualips:: novirtualips option (-L) * ntpd panicgate:: panicgate option (-g) +* ntpd pccfreq:: pccfreq option * ntpd pidfile:: pidfile option (-p) * ntpd priority:: priority option (-P) * ntpd propagationdelay:: propagationdelay option (-r) * ntpd quit:: quit option (-q) +* ntpd saveconfigquit:: saveconfigquit option * ntpd set-debug-level:: set-debug-level option (-D) * ntpd slew:: slew option (-x) * ntpd statsdir:: statsdir option (-s) * ntpd trustedkey:: trustedkey option (-t) * ntpd updateinterval:: updateinterval option (-U) +* ntpd usepcc:: usepcc option * ntpd user:: user option (-u) -* ntpd var:: var option (-v) +* ntpd var:: var option @end menu @node ntpd usage @@ -60,7 +63,7 @@ @exampleindent 0 @example -ntpd - NTP daemon program - Ver. 4.2.5p247-RC +ntpd - NTP daemon program - Ver. 4.2.6p2 USAGE: ntpd [ - [] | --[@{=| @}] ]... Flg Arg Option-Name Description -4 no ipv4 Force IPv4 DNS name resolution @@ -132,7 +135,8 @@ This option has some usage constraints. It: @itemize @bullet @item -is a member of the ipv4 class of options. +must not appear in combination with any of the following options: +ipv6. @end itemize Force DNS resolution of following host names on the command line @@ -147,7 +151,8 @@ This option has some usage constraints. It: @itemize @bullet @item -is a member of the ipv4 class of options. +must not appear in combination with any of the following options: +ipv4. @end itemize Force DNS resolution of following host names on the command line @@ -255,6 +260,13 @@ @cindex ntpd-panicgate This is the ``allow the first adjustment to be big'' option. + +This option has some usage constraints. It: +@itemize @bullet +@item +may appear an unlimited number of times. +@end itemize + Normally, ntpd exits with a message to the system log if the offset exceeds the panic threshold, which is 1000 s by default. This option allows the time to be set to any value without restriction; however, this can happen only once. If the threshold is exceeded after that, @@ -273,19 +285,33 @@ @cindex ntpd-jaildir This is the ``jail directory'' option. + +This option has some usage constraints. It: +@itemize @bullet +@item +must be compiled in by defining @code{HAVE_DROPROOT} during the compilation. +@end itemize + Chroot the server to the directory jaildir . -This option also implies that the server attempts to drop root privileges at startup (otherwise, chroot gives very little additional security), and it is only available if the OS supports to run the server without full root privileges. +This option also implies that the server attempts to drop root privileges at startup. You may need to also specify a -u option. +This option is only available if the OS supports adjusting the clock +without full root privileges. +This option is supported under NetBSD (configure with +--enable-clockctl +) and Linux (configure with +--enable-linuxcaps +). @node ntpd interface @subsection interface option (-I) @cindex ntpd-interface -This is the ``listen on interface'' option. +This is the ``listen on an interface name or address'' option. This option has some usage constraints. It: @itemize @bullet @@ -293,7 +319,11 @@ may appear an unlimited number of times. @end itemize - +Open the network address given, or all the addresses associated with the +given interface name. This option may appear multiple times. This option +also implies not opening other addresses, except wildcard and localhost. +This option is deprecated. Please consider using the configuration file +interface command, which is more versatile. @node ntpd keyfile @subsection keyfile option (-k) @@ -322,8 +352,11 @@ @subsection novirtualips option (-L) @cindex ntpd-novirtualips -This is the ``do not listen to virtual ips'' option. -Do not listen to virtual IPs. The default is to listen. +This is the ``do not listen to virtual interfaces'' option. +Do not listen to virtual interfaces, defined as those with +names containing a colon. This option is deprecated. Please +consider using the configuration file interface command, which +is more versatile. @node ntpd modifymmtimer @subsection modifymmtimer option (-M) @@ -337,7 +370,9 @@ must be compiled in by defining @code{SYS_WINNT} during the compilation. @end itemize -Set the Windows Multimedia Timer to highest resolution. +Set the Windows Multimedia Timer to highest resolution. This +ensures the resolution does not change while ntpd is running, +avoiding timekeeping glitches associated with changes. @node ntpd nofork @subsection nofork option (-n) @@ -401,15 +436,21 @@ This is the ``broadcast/propagation delay'' option. Specify the default propagation delay from the broadcast/multicast server to this client. This is necessary only if the delay cannot be computed automatically by the protocol. -@node ntpd updateinterval -@subsection updateinterval option (-U) -@cindex ntpd-updateinterval +@node ntpd saveconfigquit +@subsection saveconfigquit option +@cindex ntpd-saveconfigquit -This is the ``interval in seconds between scans for new or dropped interfaces'' option. -Give the time in seconds between two scans for new or dropped interfaces. -For systems with routing socket support the scans will be performed shortly after the interface change -has been detected by the system. -Use 0 to disable scanning. +This is the ``save parsed configuration and quit'' option. + +This option has some usage constraints. It: +@itemize @bullet +@item +must be compiled in by defining @code{SAVECONFIG} during the compilation. +@end itemize + +Cause ntpd to parse its startup configuration file and save an +equivalent to the given filename and exit. This option was +designed for automated testing. @node ntpd statsdir @subsection statsdir option (-s) @@ -440,16 +481,34 @@ @cindex ntpd-user This is the ``run as userid (or userid:groupid)'' option. + +This option has some usage constraints. It: +@itemize @bullet +@item +must be compiled in by defining @code{HAVE_DROPROOT} during the compilation. +@end itemize + Specify a user, and optionally a group, to switch to. -This option is only available if the OS supports to run the server without full root privileges. -Currently, this option is supported under NetBSD (configure with +This option is only available if the OS supports adjusting the clock +without full root privileges. +This option is supported under NetBSD (configure with --enable-clockctl ) and Linux (configure with --enable-linuxcaps ). +@node ntpd updateinterval +@subsection updateinterval option (-U) +@cindex ntpd-updateinterval + +This is the ``interval in seconds between scans for new or dropped interfaces'' option. +Give the time in seconds between two scans for new or dropped interfaces. +For systems with routing socket support the scans will be performed shortly after the interface change +has been detected by the system. +Use 0 to disable scanning. 60 seconds is the minimum time between scans. + @node ntpd var -@subsection var option (-v) +@subsection var option @cindex ntpd-var This is the ``make arg an ntp variable (rw)'' option. @@ -463,7 +522,7 @@ @node ntpd dvar -@subsection dvar option (-V) +@subsection dvar option @cindex ntpd-dvar This is the ``make arg an ntp variable (rw|def)'' option. @@ -494,3 +553,36 @@ tinker configuration file directive for other options. Note: The kernel time discipline is disabled with this option. + +@node ntpd usepcc +@subsection usepcc option +@cindex ntpd-usepcc + +This is the ``use cpu cycle counter (windows only)'' option. + +This option has some usage constraints. It: +@itemize @bullet +@item +must be compiled in by defining @code{SYS_WINNT} during the compilation. +@end itemize + +Attempt to substitute the CPU counter for QueryPerformanceCounter. +The CPU counter and QueryPerformanceCounter are compared, and if +they have the same frequency, the CPU counter (RDTSC on x86) is +used directly, saving the overhead of a system call. + +@node ntpd pccfreq +@subsection pccfreq option +@cindex ntpd-pccfreq + +This is the ``force cpu cycle counter use (windows only)'' option. + +This option has some usage constraints. It: +@itemize @bullet +@item +must be compiled in by defining @code{SYS_WINNT} during the compilation. +@end itemize + +Force substitution the CPU counter for QueryPerformanceCounter. +The CPU counter (RDTSC on x86) is used unconditionally with the +given frequency (in Hz). diff -urN src/contrib/ntp/ntpd/ntpd.1 src.ntp/contrib/ntp/ntpd/ntpd.1 --- src/contrib/ntp/ntpd/ntpd.1 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/ntpd.1 2010-07-09 04:24:03.000000000 +0200 @@ -1,7 +1,7 @@ -.TH NTPD 1 2009-12-08 "( 4.2.4p8)" "Programmer's Manual" +.TH NTPD 1 2010-07-09 "( 4.2.6p2)" "Programmer's Manual" .\" EDIT THIS FILE WITH CAUTION (ntpd.1) .\" -.\" It has been AutoGen-ed Tuesday December 8, 2009 at 08:13:11 AM EST +.\" It has been AutoGen-ed July 9, 2010 at 02:24:03 AM by AutoGen 5.10 .\" From the definitions ntpd-opts.def .\" and the template file agman1.tpl .\" @@ -14,20 +14,22 @@ .PP All arguments must be options. .SH "DESCRIPTION" -This manual page documents, briefly, the \fBntpd\fP command. +This manual page briefly documents the \fBntpd\fP command. .SH OPTIONS .TP .BR \-4 ", " \--ipv4 Force IPv4 DNS name resolution. -This option is a member of the ipv4 class of options. +This option must not appear in combination with any of the following options: +ipv6. .sp Force DNS resolution of following host names on the command line to the IPv4 namespace. .TP .BR \-6 ", " \--ipv6 Force IPv6 DNS name resolution. -This option is a member of the ipv4 class of options. +This option must not appear in combination with any of the following options: +ipv4. .sp Force DNS resolution of following host names on the command line to the IPv6 namespace. @@ -89,6 +91,7 @@ .TP .BR \-g ", " \--panicgate Allow the first adjustment to be Big. +This option may appear an unlimited number of times. .sp Normally, ntpd @@ -109,16 +112,27 @@ Chroot the server to the directory jaildir . -This option also implies that the server attempts to drop root privileges at startup (otherwise, chroot gives very little additional security), and it is only available if the OS supports to run the server without full root privileges. +This option also implies that the server attempts to drop root privileges at startup. You may need to also specify a -u option. +This option is only available if the OS supports adjusting the clock +without full root privileges. +This option is supported under NetBSD (configure with +--enable-clockctl +) and Linux (configure with +--enable-linuxcaps +). .TP .BR \-I " \fIiface\fP, " \--interface "=" \fIiface\fP -Listen on interface. +Listen on an interface name or address. This option may appear an unlimited number of times. .sp - +Open the network address given, or all the addresses associated with the +given interface name. This option may appear multiple times. This option +also implies not opening other addresses, except wildcard and localhost. +This option is deprecated. Please consider using the configuration file +interface command, which is more versatile. .TP .BR \-k " \fIstring\fP, " \--keyfile "=" \fIstring\fP path to symmetric keys. @@ -140,14 +154,19 @@ configuration file directive. .TP .BR \-L ", " \--novirtualips -Do not listen to virtual IPs. +Do not listen to virtual interfaces. .sp -Do not listen to virtual IPs. The default is to listen. +Do not listen to virtual interfaces, defined as those with +names containing a colon. This option is deprecated. Please +consider using the configuration file interface command, which +is more versatile. .TP .BR \-M ", " \--modifymmtimer Modify Multimedia Timer (Windows only). .sp -Set the Windows Multimedia Timer to highest resolution. +Set the Windows Multimedia Timer to highest resolution. This +ensures the resolution does not change while ntpd is running, +avoiding timekeeping glitches associated with changes. .TP .BR \-n ", " \--nofork Do not fork. @@ -200,14 +219,12 @@ .sp Specify the default propagation delay from the broadcast/multicast server to this client. This is necessary only if the delay cannot be computed automatically by the protocol. .TP -.BR \-U " \fInumber\fP, " \--updateinterval "=" \fInumber\fP -interval in seconds between scans for new or dropped interfaces. -This option takes an integer number as its argument. +.BR \--saveconfigquit "=\fIstring\fP" +Save parsed configuration and quit. .sp -Give the time in seconds between two scans for new or dropped interfaces. -For systems with routing socket support the scans will be performed shortly after the interface change -has been detected by the system. -Use 0 to disable scanning. +Cause ntpd to parse its startup configuration file and save an +equivalent to the given filename and exit. This option was +designed for automated testing. .TP .BR \-s " \fIstring\fP, " \--statsdir "=" \fIstring\fP Statistics file location. @@ -227,20 +244,30 @@ Run as userid (or userid:groupid). .sp Specify a user, and optionally a group, to switch to. -This option is only available if the OS supports to run the server without full root privileges. -Currently, this option is supported under NetBSD (configure with +This option is only available if the OS supports adjusting the clock +without full root privileges. +This option is supported under NetBSD (configure with --enable-clockctl ) and Linux (configure with --enable-linuxcaps ). .TP -.BR \-v " \fInvar\fP, " \--var "=" \fInvar\fP +.BR \-U " \fInumber\fP, " \--updateinterval "=" \fInumber\fP +interval in seconds between scans for new or dropped interfaces. +This option takes an integer number as its argument. +.sp +Give the time in seconds between two scans for new or dropped interfaces. +For systems with routing socket support the scans will be performed shortly after the interface change +has been detected by the system. +Use 0 to disable scanning. 60 seconds is the minimum time between scans. +.TP +.BR \--var "=\fInvar\fP" make ARG an ntp variable (RW). This option may appear an unlimited number of times. .sp .TP -.BR \-V " \fIndvar\fP, " \--dvar "=" \fIndvar\fP +.BR \--dvar "=\fIndvar\fP" make ARG an ntp variable (RW|DEF). This option may appear an unlimited number of times. .sp @@ -263,13 +290,28 @@ configuration file directive for other options. Note: The kernel time discipline is disabled with this option. .TP +.BR \--usepcc +Use CPU cycle counter (Windows only). +.sp +Attempt to substitute the CPU counter for QueryPerformanceCounter. +The CPU counter and QueryPerformanceCounter are compared, and if +they have the same frequency, the CPU counter (RDTSC on x86) is +used directly, saving the overhead of a system call. +.TP +.BR \--pccfreq "=\fIstring\fP" +Force CPU cycle counter use (Windows only). +.sp +Force substitution the CPU counter for QueryPerformanceCounter. +The CPU counter (RDTSC on x86) is used unconditionally with the +given frequency (in Hz). +.TP .BR \-? , " \--help" -Display usage information and exit. +Display extended usage information and exit. .TP .BR \-! , " \--more-help" Extended usage information passed thru pager. .TP -.BR \-v " [{\fIv|c|n\fP}]," " \--version" "[=\fI{v|c|n}\fP]" +.BR \- " [{\fIv|c|n\fP}]," " \--version" "[=\fI{v|c|n}\fP]" Output version of program and exit. The default mode is `v', a simple version. The `c' mode will print copyright information and `n' will print the full copyright notice. @@ -279,7 +321,7 @@ .nf \fBNTPD_\fP or \fBNTPD\fP .fi -.aj +.ad .SH AUTHOR David L. Mills and/or others .br diff -urN src/contrib/ntp/ntpd/ntpd.c src.ntp/contrib/ntp/ntpd/ntpd.c --- src/contrib/ntp/ntpd/ntpd.c 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/ntpd.c 2010-07-09 04:17:42.000000000 +0200 @@ -12,13 +12,18 @@ #include "ntp_stdlib.h" #include +#include "ntp_syslog.h" +#include "isc/assertions.h" +#include "isc/error.h" +#include "isc/strerror.h" +#include "isc/formatcheck.h" + #ifdef SIM # include "ntpsim.h" -# include "ntpdsim-opts.h" -#else -# include "ntpd-opts.h" #endif +#include "ntpd-opts.h" + #ifdef HAVE_UNISTD_H # include #endif @@ -78,8 +83,8 @@ # include #endif /* SYS_DOMAINOS */ -#include "recvbuff.h" -#include "ntp_cmdargs.h" +#include "recvbuff.h" +#include "ntp_cmdargs.h" #if 0 /* HMS: I don't think we need this. 961223 */ #ifdef LOCK_PROCESS @@ -119,10 +124,10 @@ * Signals which terminate us gracefully. */ #ifndef SYS_WINNT -# define SIGDIE1 SIGHUP -# define SIGDIE3 SIGQUIT -# define SIGDIE2 SIGINT -# define SIGDIE4 SIGTERM +# define SIGDIE1 SIGHUP +# define SIGDIE3 SIGQUIT +# define SIGDIE2 SIGINT +# define SIGDIE4 SIGTERM #endif /* SYS_WINNT */ #ifdef HAVE_DNSREGISTRATION @@ -155,16 +160,26 @@ */ int nofork = 0; /* Fork by default */ +#ifdef HAVE_DNSREGISTRATION +/* + * mDNS registration flag. If set, we attempt to register with the mDNS system, but only + * after we have synched the first time. If the attempt fails, then try again once per + * minute for up to 5 times. After all, we may be starting before mDNS. + */ +int mdnsreg = 1; +int mdnstries = 5; +#endif /* HAVE_DNSREGISTRATION */ + #ifdef HAVE_DROPROOT int droproot = 0; char *user = NULL; /* User to switch to */ char *group = NULL; /* group to switch to */ -char *chrootdir = NULL; /* directory to chroot to */ +const char *chrootdir = NULL; /* directory to chroot to */ int sw_uid; int sw_gid; -char *endp; +char *endp; struct group *gr; -struct passwd *pw; +struct passwd *pw; #endif /* HAVE_DROPROOT */ /* @@ -186,33 +201,45 @@ /* * We put this here, since the argument profile is syscall-specific */ -extern int syscall P((int, ...)); +extern int syscall (int, ...); #endif /* DECL_SYSCALL */ #ifdef SIGDIE2 -static RETSIGTYPE finish P((int)); +static RETSIGTYPE finish (int); #endif /* SIGDIE2 */ #ifdef DEBUG #ifndef SYS_WINNT -static RETSIGTYPE moredebug P((int)); -static RETSIGTYPE lessdebug P((int)); +static RETSIGTYPE moredebug (int); +static RETSIGTYPE lessdebug (int); #endif #else /* not DEBUG */ -static RETSIGTYPE no_debug P((int)); +static RETSIGTYPE no_debug (int); #endif /* not DEBUG */ -int ntpdmain P((int, char **)); -static void set_process_priority P((void)); -static void init_logging P((char const *)); -static void setup_logfile P((void)); +int ntpdmain (int, char **); +static void set_process_priority (void); +void init_logging (char const *, int); +void setup_logfile (void); +static void process_commandline_opts(int *, char ***); + +static void assertion_failed (const char *file, int line, + isc_assertiontype_t type, const char *cond); +static void library_fatal_error (const char *file, int line, + const char *format, va_list args) ISC_FORMAT_PRINTF(3, 0); +static void library_unexpected_error(const char *file, int line, + const char *format, va_list args) ISC_FORMAT_PRINTF(3, 0); + /* * Initialize the logging */ void -init_logging(char const *name) +init_logging( + char const *name, + int log_version + ) { const char *cp; @@ -243,17 +270,19 @@ # endif /* DEBUG */ setlogmask(LOG_UPTO(LOG_DEBUG)); /* @@@ was INFO */ # endif /* LOG_DAEMON */ -#endif /* !SYS_WINNT && !VMS */ +#endif /* !VMS */ - NLOG(NLOG_SYSINFO) /* conditional if clause for conditional syslog */ + if (log_version) + NLOG(NLOG_SYSINFO) /* 'if' clause for syslog */ msyslog(LOG_NOTICE, "%s", Version); } /* - * See if we should redirect the logfile + * Redirect logging to a file if requested with -l. + * The ntp.conf logfile directive does not use this code, see + * config_vars() in ntp_config.c. */ - void setup_logfile( void @@ -286,6 +315,21 @@ } } + +static void +process_commandline_opts( + int *pargc, + char ***pargv + ) +{ + int optct; + + optct = optionProcess(&ntpdOptions, *pargc, *pargv); + *pargc -= optct; + *pargv += optct; +} + + #ifdef SIM int main( @@ -293,6 +337,8 @@ char *argv[] ) { + process_commandline_opts(&argc, &argv); + return ntpsim(argc, argv); } #else /* SIM */ @@ -316,10 +362,10 @@ /* * OK. AIX is different than solaris in how it implements plock(). * If you do NOT adjust the stack limit, you will get the MAXIMUM - * stack size allocated and PINNED with you program. To check the - * value, use ulimit -a. + * stack size allocated and PINNED with you program. To check the + * value, use ulimit -a. * - * To fix this, we create an automatic variable and set our stack limit + * To fix this, we create an automatic variable and set our stack limit * to that PLUS 32KB of extra space (we need some headroom). * * This subroutine gets the stack address. @@ -363,10 +409,6 @@ priority_done); #endif /* DEBUG */ -#ifdef SYS_WINNT - priority_done += NT_set_process_priority(); -#endif - #if defined(HAVE_SCHED_SETSCHEDULER) if (!priority_done) { extern int config_priority_override, config_priority; @@ -453,24 +495,9 @@ #endif progname = argv[0]; - initializing = 1; /* mark that we are initializing */ - - { - int optct = optionProcess( -#ifdef SIM - &ntpdsimOptions -#else - &ntpdOptions -#endif - , argc, argv); - argc -= optct; - argv += optct; - } - - /* HMS: is this lame? Should we process -l first? */ - - init_logging(progname); /* Open the log file */ + process_commandline_opts(&argc, &argv); + init_logging(progname, 1); /* Open the log file */ #ifdef HAVE_UMASK { @@ -489,32 +516,24 @@ uid_t uid; uid = getuid(); - if (uid) - { + if (uid && !HAVE_OPT( SAVECONFIGQUIT )) { msyslog(LOG_ERR, "ntpd: must be run as root, not uid %ld", (long)uid); - printf("must be run as root, not uid %ld", (long)uid); + printf("must be run as root, not uid %ld\n", (long)uid); exit(1); } } #endif -#ifdef OPENSSL - if ((SSLeay() ^ OPENSSL_VERSION_NUMBER) & ~0xff0L) { - msyslog(LOG_ERR, - "ntpd: OpenSSL version mismatch. Built against %lx, you have %lx\n", - OPENSSL_VERSION_NUMBER, SSLeay()); - exit(1); - } -#endif - /* getstartup(argc, argv); / * startup configuration, may set debug */ #ifdef DEBUG debug = DESC(DEBUG_LEVEL).optOccCt; - if (debug) - printf("%s\n", Version); + DPRINTF(1, ("%s\n", Version)); #endif + /* honor -l/--logfile option to log to a file */ + setup_logfile(); + /* * Enable the Multi-Media Timer for Windows? */ @@ -523,24 +542,32 @@ set_mm_timer(MM_TIMER_HIRES); #endif - if (HAVE_OPT( NOFORK ) || HAVE_OPT( QUIT )) + if (HAVE_OPT( NOFORK ) || HAVE_OPT( QUIT ) +#ifdef DEBUG + || debug +#endif + || HAVE_OPT( SAVECONFIGQUIT )) nofork = 1; if (HAVE_OPT( NOVIRTUALIPS )) listen_to_virtual_ips = 0; + /* + * --interface, listen on specified interfaces + */ if (HAVE_OPT( INTERFACE )) { -#if 0 int ifacect = STACKCT_OPT( INTERFACE ); - char** ifaces = STACKLST_OPT( INTERFACE ); + const char** ifaces = STACKLST_OPT( INTERFACE ); + isc_netaddr_t netaddr; - /* malloc space for the array of names */ while (ifacect-- > 0) { - next_iface = *ifaces++; + add_nic_rule( + is_ip_address(*ifaces, &netaddr) + ? MATCH_IFADDR + : MATCH_IFNAME, + *ifaces, -1, ACTION_LISTEN); + ifaces++; } -#else - specific_interface = OPT_ARG( INTERFACE ); -#endif } if (HAVE_OPT( NICE )) @@ -556,13 +583,11 @@ #ifdef SYS_WINNT /* - * Initialize the time structures and variables + * Start interpolation thread, must occur before first + * get_systime() */ init_winnt_time(); #endif - - setup_logfile(); - /* * Initialize random generator and public key pair */ @@ -570,25 +595,22 @@ ntp_srandom((int)(now.l_i * now.l_uf)); -#ifdef HAVE_DNSREGISTRATION - /* HMS: does this have to happen this early? */ - msyslog(LOG_INFO, "Attemping to register mDNS"); - if ( DNSServiceRegister (&mdns, 0, 0, NULL, "_ntp._udp", NULL, NULL, htons(NTP_PORT), 0, NULL, NULL, NULL) != kDNSServiceErr_NoError ) { - msyslog(LOG_ERR, "Unable to register mDNS"); - } -#endif - #if !defined(VMS) # ifndef NODETACH /* * Detach us from the terminal. May need an #ifndef GIZMO. */ - if ( -# ifdef DEBUG - !debug && -# endif /* DEBUG */ - !nofork) - { + if (!nofork) { + + /* + * Install trap handlers to log errors and assertion + * failures. Default handlers print to stderr which + * doesn't work if detached. + */ + isc_assertion_setcallback(assertion_failed); + isc_error_setfatal(library_fatal_error); + isc_error_setunexpected(library_unexpected_error); + # ifndef SYS_WINNT # ifdef HAVE_DAEMON daemon(0, 0); @@ -600,8 +622,11 @@ #if !defined(F_CLOSEM) u_long s; int max_fd; -#endif /* not F_CLOSEM */ - +#endif /* !FCLOSEM */ + if (syslog_file != NULL) { + fclose(syslog_file); + syslog_file = NULL; + } #if defined(F_CLOSEM) /* * From 'Writing Reliable AIX Daemons,' SG24-4946-00, @@ -623,6 +648,11 @@ (void) open("/", 0); (void) dup2(0, 1); (void) dup2(0, 2); + + init_logging(progname, 0); + /* we lost our logfile (if any) daemonizing */ + setup_logfile(); + #ifdef SYS_DOMAINOS { uid_$t puid; @@ -674,8 +704,6 @@ # endif /* NODETACH */ #endif /* VMS */ - setup_logfile(); /* We lost any redirect when we daemonized */ - #ifdef SCO5_CLOCK /* * SCO OpenServer's system clock offers much more precise timekeeping @@ -724,7 +752,7 @@ */ rl.rlim_cur = rl.rlim_max = 32*1024*1024; if (setrlimit(RLIMIT_MEMLOCK, &rl) == -1) { - msyslog(LOG_ERR, "Cannot set RLIMIT_MEMLOCK: %m"); + msyslog(LOG_ERR, "Cannot set RLIMIT_MEMLOCK: %m"); } # endif /* RLIMIT_MEMLOCK */ } @@ -738,7 +766,7 @@ # ifdef HAVE_PLOCK # ifdef PROCLOCK # ifdef _AIX - /* + /* * set the stack limit for AIX for plock(). * see get_aix_stack() for more info. */ @@ -831,13 +859,9 @@ * Get the configuration. This is done in a separate module * since this will definitely be different for the gizmo board. */ - getconfig(argc, argv); - - loop_config(LOOP_DRIFTCOMP, old_drift / 1e6); -#ifdef OPENSSL - crypto_setup(); -#endif /* OPENSSL */ + report_event(EVNT_SYSRESTART, NULL, NULL); + loop_config(LOOP_DRIFTCOMP, old_drift); initializing = 0; #ifdef HAVE_DROPROOT @@ -846,30 +870,48 @@ #ifdef HAVE_LINUX_CAPABILITIES /* set flag: keep privileges accross setuid() call (we only really need cap_sys_time): */ - if( prctl( PR_SET_KEEPCAPS, 1L, 0L, 0L, 0L ) == -1 ) { + if (prctl( PR_SET_KEEPCAPS, 1L, 0L, 0L, 0L ) == -1) { msyslog( LOG_ERR, "prctl( PR_SET_KEEPCAPS, 1L ) failed: %m" ); exit(-1); } #else /* we need a user to switch to */ - if( user == NULL ) { + if (user == NULL) { msyslog(LOG_ERR, "Need user name to drop root privileges (see -u flag!)" ); exit(-1); } #endif /* HAVE_LINUX_CAPABILITIES */ - + if (user != NULL) { if (isdigit((unsigned char)*user)) { sw_uid = (uid_t)strtoul(user, &endp, 0); - if (*endp != '\0') + if (*endp != '\0') goto getuser; + + if ((pw = getpwuid(sw_uid)) != NULL) { + user = strdup(pw->pw_name); + if (NULL == user) { + msyslog(LOG_ERR, "strdup() failed: %m"); + exit (-1); + } + sw_gid = pw->pw_gid; + } else { + errno = 0; + msyslog(LOG_ERR, "Cannot find user ID %s", user); + exit (-1); + } + } else { -getuser: +getuser: + errno = 0; if ((pw = getpwnam(user)) != NULL) { sw_uid = pw->pw_uid; + sw_gid = pw->pw_gid; } else { - errno = 0; - msyslog(LOG_ERR, "Cannot find user `%s'", user); + if (errno) + msyslog(LOG_ERR, "getpwnam(%s) failed: %m", user); + else + msyslog(LOG_ERR, "Cannot find user `%s'", user); exit (-1); } } @@ -877,10 +919,10 @@ if (group != NULL) { if (isdigit((unsigned char)*group)) { sw_gid = (gid_t)strtoul(group, &endp, 0); - if (*endp != '\0') + if (*endp != '\0') goto getgroup; } else { -getgroup: +getgroup: if ((gr = getgrnam(group)) != NULL) { sw_gid = gr->gr_gid; } else { @@ -890,17 +932,25 @@ } } } - - if( chrootdir ) { + + if (chrootdir ) { /* make sure cwd is inside the jail: */ - if( chdir(chrootdir) ) { + if (chdir(chrootdir)) { msyslog(LOG_ERR, "Cannot chdir() to `%s': %m", chrootdir); exit (-1); } - if( chroot(chrootdir) ) { + if (chroot(chrootdir)) { msyslog(LOG_ERR, "Cannot chroot() to `%s': %m", chrootdir); exit (-1); } + if (chdir("/")) { + msyslog(LOG_ERR, "Cannot chdir() to`root after chroot(): %m"); + exit (-1); + } + } + if (user && initgroups(user, sw_gid)) { + msyslog(LOG_ERR, "Cannot initgroups() to user `%s': %m", user); + exit (-1); } if (group && setgid(sw_gid)) { msyslog(LOG_ERR, "Cannot setgid() to group `%s': %m", group); @@ -918,7 +968,7 @@ msyslog(LOG_ERR, "Cannot seteuid() to user `%s': %m", user); exit (-1); } - + #ifndef HAVE_LINUX_CAPABILITIES /* * for now assume that the privilege to bind to privileged ports @@ -941,9 +991,9 @@ * cap_net_bind_service if doing dynamic interface tracking. */ cap_t caps; - char *captext = interface_interval ? - "cap_sys_time,cap_net_bind_service=ipe" : - "cap_sys_time=ipe"; + char *captext = (interface_interval) + ? "cap_sys_time,cap_net_bind_service=ipe" + : "cap_sys_time=ipe"; if( ! ( caps = cap_from_text( captext ) ) ) { msyslog( LOG_ERR, "cap_from_text() failed: %m" ); exit(-1); @@ -958,11 +1008,6 @@ } /* if( droproot ) */ #endif /* HAVE_DROPROOT */ - - /* - * Report that we're up to any trappers - */ - report_event(EVNT_SYSRESTART, (struct peer *)0); /* * Use select() on all on all input fd's for unlimited @@ -989,7 +1034,7 @@ was_alarmed = 0; for (;;) { -# if !defined(HAVE_SIGNALED_IO) +# if !defined(HAVE_SIGNALED_IO) extern fd_set activefds; extern int maxactivefd; @@ -997,7 +1042,7 @@ int nfound; # endif - if (alarm_flag) /* alarmed? */ + if (alarm_flag) /* alarmed? */ { was_alarmed = 1; alarm_flag = 0; @@ -1032,16 +1077,16 @@ (void)input_handler(&ts); } else if (nfound == -1 && errno != EINTR) - netsyslog(LOG_ERR, "select() error: %m"); + msyslog(LOG_ERR, "select() error: %m"); # ifdef DEBUG else if (debug > 5) - netsyslog(LOG_DEBUG, "select(): nfound=%d, error: %m", nfound); + msyslog(LOG_DEBUG, "select(): nfound=%d, error: %m", nfound); # endif /* DEBUG */ # else /* HAVE_SIGNALED_IO */ - + wait_for_signal(); # endif /* HAVE_SIGNALED_IO */ - if (alarm_flag) /* alarmed? */ + if (alarm_flag) /* alarmed? */ { was_alarmed = 1; alarm_flag = 0; @@ -1057,17 +1102,17 @@ */ timer(); was_alarmed = 0; - BLOCK_IO_AND_ALARM(); + BLOCK_IO_AND_ALARM(); } -#endif /* HAVE_IO_COMPLETION_PORT */ +#endif /* ! HAVE_IO_COMPLETION_PORT */ #ifdef DEBUG_TIMING { l_fp pts; l_fp tsa, tsb; int bufcount = 0; - + get_systime(&pts); tsa = pts; #endif @@ -1124,6 +1169,25 @@ /* * Go around again */ + +#ifdef HAVE_DNSREGISTRATION + if (mdnsreg && (current_time - mdnsreg ) > 60 && mdnstries && sys_leap != LEAP_NOTINSYNC) { + mdnsreg = current_time; + msyslog(LOG_INFO, "Attemping to register mDNS"); + if ( DNSServiceRegister (&mdns, 0, 0, NULL, "_ntp._udp", NULL, NULL, + htons(NTP_PORT), 0, NULL, NULL, NULL) != kDNSServiceErr_NoError ) { + if (!--mdnstries) { + msyslog(LOG_ERR, "Unable to register mDNS, giving up."); + } else { + msyslog(LOG_INFO, "Unable to register mDNS, will try later."); + } + } else { + msyslog(LOG_INFO, "mDNS service registered."); + mdnsreg = 0; + } + } +#endif /* HAVE_DNSREGISTRATION */ + } UNBLOCK_IO_AND_ALARM(); return 1; @@ -1139,30 +1203,95 @@ int sig ) { - msyslog(LOG_NOTICE, "ntpd exiting on signal %d", sig); - write_stats(); #ifdef HAVE_DNSREGISTRATION if (mdns != NULL) - DNSServiceRefDeallocate(mdns); + DNSServiceRefDeallocate(mdns); #endif - - switch (sig) - { + switch (sig) { # ifdef SIGBUS - case SIGBUS: + case SIGBUS: printf("\nfinish(SIGBUS)\n"); exit(0); # endif - case 0: /* Should never happen... */ + case 0: /* Should never happen... */ return; - default: + + default: exit(0); } } #endif /* SIGDIE2 */ +/* assertion_failed + * Redirect trap messages from ISC libraries to syslog. + * This code was cloned and simplified from BIND. + */ + +/* + * assertion_failed - Handle assertion failures. + */ + +static void +assertion_failed(const char *file, int line, isc_assertiontype_t type, + const char *cond) +{ + isc_assertion_setcallback(NULL); /* Avoid recursion */ + + msyslog(LOG_ERR, "%s:%d: %s(%s) failed", + file, line, isc_assertion_typetotext(type), cond); + msyslog(LOG_ERR, "exiting (due to assertion failure)"); + + abort(); +} + +/* + * library_fatal_error - Handle fatal errors from our libraries. + */ + +static void +library_fatal_error(const char *file, int line, const char *format, + va_list args) +{ + char errbuf[256]; + + isc_error_setfatal(NULL); /* Avoid recursion */ + + msyslog(LOG_ERR, "%s:%d: fatal error:", file, line); + vsnprintf(errbuf, sizeof(errbuf), format, args); + msyslog(LOG_ERR, errbuf); + msyslog(LOG_ERR, "exiting (due to fatal error in library)"); + + abort(); +} + +/* + * library_unexpected_error - Handle non fatal errors from our libraries. + */ +#define MAX_UNEXPECTED_ERRORS 100 +int unexpected_error_cnt = 0; +static void +library_unexpected_error(const char *file, int line, const char *format, + va_list args) +{ + char errbuf[256]; + + if (unexpected_error_cnt >= MAX_UNEXPECTED_ERRORS) + return; /* avoid clutter in log */ + + msyslog(LOG_ERR, "%s:%d: unexpected error:", file, line); + vsnprintf(errbuf, sizeof(errbuf), format, args); + msyslog(LOG_ERR, errbuf); + + if (++unexpected_error_cnt == MAX_UNEXPECTED_ERRORS) + { + msyslog(LOG_ERR, "Too many errors. Shutting up."); + } + +} + + #ifdef DEBUG #ifndef SYS_WINNT /* diff -urN src/contrib/ntp/ntpd/ntpdbase-opts.def src.ntp/contrib/ntp/ntpd/ntpdbase-opts.def --- src/contrib/ntp/ntpd/ntpdbase-opts.def 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/ntpdbase-opts.def 2009-12-09 08:36:35.000000000 +0100 @@ -1,11 +1,19 @@ #include autogen-version.def +include = <<- _EOF_ + #ifdef __windows + extern int atoi(const char *); + #else + # include + #endif + _EOF_; + test-main; flag = { name = ipv4; value = 4; - equivalence = ipv4; + flags-cant = ipv6; descrip = "Force IPv4 DNS name resolution"; doc = <<- _EndOfDoc_ Force DNS resolution of following host names on the command line @@ -16,7 +24,7 @@ flag = { name = ipv6; value = 6; - equivalence = ipv4; + flags-cant = ipv4; descrip = "Force IPv6 DNS name resolution"; doc = <<- _EndOfDoc_ Force DNS resolution of following host names on the command line @@ -56,17 +64,6 @@ _EndOfDoc_; }; -#ifdef SIM -flag = { - name = simbroadcastdelay; - value = B; - arg-type = string; - descrip = "Simulator broadcast delay"; - doc = <<- _EndOfDoc_ - _EndOfDoc_; -}; -#endif - flag = { name = configfile; value = c; @@ -79,18 +76,33 @@ _EndOfDoc_; }; -#ifdef SIM flag = { - name = phasenoise; - value = C; - arg-type = string; - descrip = "Phase noise level"; + name = debug-level; + value = d; + max = NOLIMIT; + ifdef = DEBUG; + nopreset; + descrip = "Increase output debug message level"; + omitted-usage = "this package was built using 'configure --disable--debug'"; doc = <<- _EndOfDoc_ + Increase the debugging message output level. _EndOfDoc_; }; -#endif -#include debug-opt.def +flag = { + name = set-debug-level; + value = D; + arg-type = string; + max = NOLIMIT; + ifdef = DEBUG; + descrip = "Set the output debug message level"; + omitted-usage = "this package was built using 'configure --disable--debug'"; + flag-code = 'DESC(DEBUG_LEVEL).optOccCt = atoi( pOptDesc->pzLastArg );'; + doc = <<- _EndOfDoc_ + Set the output debugging level. Can be supplied multiple times, + but each overrides the previous value(s). + _EndOfDoc_; +}; flag = { name = driftfile; @@ -112,6 +124,7 @@ flag = { name = panicgate; value = g; + max = NOLIMIT; descrip = "Allow the first adjustment to be Big"; doc = <<- _EndOfDoc_ Normally, @@ -129,30 +142,28 @@ _EndOfDoc_; }; -#ifdef SIM -flag = { - name = simslew; - value = H; - arg-type = string; - descrip = "Simuator slew"; - doc = <<- _EndOfDoc_ - _EndOfDoc_; -}; -#endif - flag = { + ifdef = HAVE_DROPROOT; name = jaildir; value = i; arg-type = string; descrip = "Jail directory"; + omitted-usage = "built without --enable-clockctl or --enable-linuxcaps"; doc = <<- _EndOfDoc_ Chroot the server to the directory jaildir . - This option also implies that the server attempts to drop root privileges at startup (otherwise, chroot gives very little additional security), and it is only available if the OS supports to run the server without full root privileges. + This option also implies that the server attempts to drop root privileges at startup. You may need to also specify a -u option. + This option is only available if the OS supports adjusting the clock + without full root privileges. + This option is supported under NetBSD (configure with + --enable-clockctl + ) and Linux (configure with + --enable-linuxcaps + ). _EndOfDoc_; }; @@ -160,11 +171,16 @@ name = interface; value = I; arg-type = string; - descrip = "Listen on interface"; + descrip = "Listen on an interface name or address"; max = NOLIMIT; arg-name = iface; stack-arg; doc = <<- _EndOfDoc_ + Open the network address given, or all the addresses associated with the + given interface name. This option may appear multiple times. This option + also implies not opening other addresses, except wildcard and localhost. + This option is deprecated. Please consider using the configuration file + interface command, which is more versatile. _EndOfDoc_; }; @@ -200,9 +216,12 @@ flag = { name = novirtualips; value = L; - descrip = "Do not listen to virtual IPs"; + descrip = "Do not listen to virtual interfaces"; doc = <<- _EndOfDoc_ - Do not listen to virtual IPs. The default is to listen. + Do not listen to virtual interfaces, defined as those with + names containing a colon. This option is deprecated. Please + consider using the configuration file interface command, which + is more versatile. _EndOfDoc_; }; @@ -212,7 +231,9 @@ value = M; descrip = "Modify Multimedia Timer (Windows only)"; doc = <<- _EndOfDoc_ - Set the Windows Multimedia Timer to highest resolution. + Set the Windows Multimedia Timer to highest resolution. This + ensures the resolution does not change while ntpd is running, + avoiding timekeeping glitches associated with changes. _EndOfDoc_; }; @@ -235,17 +256,6 @@ _EndOfDoc_; }; -#ifdef SIM -flag = { - name = servertime; - value = O; - arg-type = string; - descrip = "Server time"; - doc = <<- _EndOfDoc_ - _EndOfDoc_; -}; -#endif - flag = { name = pidfile; value = p; @@ -304,15 +314,14 @@ }; flag = { - name = updateinterval; - value = U; - arg-type = number; - descrip = "interval in seconds between scans for new or dropped interfaces"; + ifdef = SAVECONFIG; + name = saveconfigquit; + arg-type = string; + descrip = "Save parsed configuration and quit"; doc = <<- _EndOfDoc_ - Give the time in seconds between two scans for new or dropped interfaces. - For systems with routing socket support the scans will be performed shortly after the interface change - has been detected by the system. - Use 0 to disable scanning. + Cause ntpd to parse its startup configuration file and save an + equivalent to the given filename and exit. This option was + designed for automated testing. _EndOfDoc_; }; @@ -329,17 +338,6 @@ _EndOfDoc_; }; -#ifdef SIM -flag = { - name = endsimtime; - value = S; - arg-type = string; - descrip = "Simulation end time"; - doc = <<- _EndOfDoc_ - _EndOfDoc_; -}; -#endif - flag = { name = trustedkey; value = t; @@ -353,37 +351,18 @@ _EndOfDoc_; }; -#ifdef SIM -flag = { - name = freqerr; - value = T; - arg-type = string; - descrip = "Simulation frequency error"; - doc = <<- _EndOfDoc_ - _EndOfDoc_; -}; -#endif - -#ifdef SIM -flag = { - name = walknoise; - value = W; - arg-type = string; - descrip = "Simulation random walk noise"; - doc = <<- _EndOfDoc_ - _EndOfDoc_; -}; -#endif - flag = { + ifdef = HAVE_DROPROOT; name = user; value = u; arg-type = string; descrip = "Run as userid (or userid:groupid)"; + omitted-usage = "built without --enable-clockctl or --enable-linuxcaps"; doc = <<- _EndOfDoc_ Specify a user, and optionally a group, to switch to. - This option is only available if the OS supports to run the server without full root privileges. - Currently, this option is supported under NetBSD (configure with + This option is only available if the OS supports adjusting the clock + without full root privileges. + This option is supported under NetBSD (configure with --enable-clockctl ) and Linux (configure with --enable-linuxcaps @@ -392,8 +371,21 @@ }; flag = { + name = updateinterval; + value = U; + arg-type = number; + descrip = "interval in seconds between scans for new or dropped interfaces"; + doc = <<- _EndOfDoc_ + Give the time in seconds between two scans for new or dropped interfaces. + For systems with routing socket support the scans will be performed shortly after the interface change + has been detected by the system. + Use 0 to disable scanning. 60 seconds is the minimum time between scans. + _EndOfDoc_; +}; + +flag = { name = var; - value = v; +/* value = v; Bug 817 */ arg-type = string; descrip = "make ARG an ntp variable (RW)"; max = NOLIMIT; @@ -405,7 +397,7 @@ flag = { name = dvar; - value = V; +/* value = V; Bug 817 */ arg-type = string; descrip = "make ARG an ntp variable (RW|DEF)"; max = NOLIMIT; @@ -436,24 +428,26 @@ _EndOfDoc_; }; -#ifdef SIM flag = { - name = ndelay; - value = Y; - arg-type = string; - descrip = "Simulation network delay"; + ifdef = SYS_WINNT; + name = usepcc; + descrip = "Use CPU cycle counter (Windows only)"; doc = <<- _EndOfDoc_ + Attempt to substitute the CPU counter for QueryPerformanceCounter. + The CPU counter and QueryPerformanceCounter are compared, and if + they have the same frequency, the CPU counter (RDTSC on x86) is + used directly, saving the overhead of a system call. _EndOfDoc_; }; -#endif -#ifdef SIM flag = { - name = pdelay; - value = Z; + ifdef = SYS_WINNT; + name = pccfreq; arg-type = string; - descrip = "Simulation processing delay"; + descrip = "Force CPU cycle counter use (Windows only)"; doc = <<- _EndOfDoc_ + Force substitution the CPU counter for QueryPerformanceCounter. + The CPU counter (RDTSC on x86) is used unconditionally with the + given frequency (in Hz). _EndOfDoc_; }; -#endif diff -urN src/contrib/ntp/ntpd/ntpdsim-opts.c src.ntp/contrib/ntp/ntpd/ntpdsim-opts.c --- src/contrib/ntp/ntpd/ntpdsim-opts.c 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/ntpdsim-opts.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,1262 +0,0 @@ -/* - * EDIT THIS FILE WITH CAUTION (ntpdsim-opts.c) - * - * It has been AutoGen-ed Tuesday December 8, 2009 at 08:13:13 AM EST - * From the definitions ntpdsim-opts.def - * and the template file options - * - * Generated from AutoOpts 29:0:4 templates. - */ - -/* - * This file was produced by an AutoOpts template. AutoOpts is a - * copyrighted work. This source file is not encumbered by AutoOpts - * licensing, but is provided under the licensing terms chosen by the - * ntpdsim author or copyright holder. AutoOpts is licensed under - * the terms of the LGPL. The redistributable library (``libopts'') is - * licensed under the terms of either the LGPL or, at the users discretion, - * the BSD license. See the AutoOpts and/or libopts sources for details. - * - * This source file is copyrighted and licensed under the following terms: - * - * ntpdsim copyright 1970-2009 David L. Mills and/or others - all rights reserved - * - * see html/copyright.html - */ - - -#include - -#define OPTION_CODE_COMPILE 1 -#include "ntpdsim-opts.h" - -#ifdef __cplusplus -extern "C" { -#endif -tSCC zCopyright[] = - "ntpdsim copyright (c) 1970-2009 David L. Mills and/or others, all rights reserved"; -tSCC zCopyrightNotice[] = - -/* extracted from ../include/copyright.def near line 8 */ -"see html/copyright.html"; -extern tUsageProc optionUsage; - -/* - * global included definitions - */ -#ifdef __windows - extern int atoi(const char*); -#else -# include -#endif - -#ifndef NULL -# define NULL 0 -#endif -#ifndef EXIT_SUCCESS -# define EXIT_SUCCESS 0 -#endif -#ifndef EXIT_FAILURE -# define EXIT_FAILURE 1 -#endif -/* - * Ipv4 option description: - */ -tSCC zIpv4Text[] = - "Force IPv4 DNS name resolution"; -tSCC zIpv4_NAME[] = "IPV4"; -tSCC zIpv4_Name[] = "ipv4"; -#define IPV4_FLAGS (OPTST_DISABLED) - -/* - * Ipv6 option description: - */ -tSCC zIpv6Text[] = - "Force IPv6 DNS name resolution"; -tSCC zIpv6_NAME[] = "IPV6"; -tSCC zIpv6_Name[] = "ipv6"; -#define IPV6_FLAGS (OPTST_DISABLED) - -/* - * Authreq option description with - * "Must also have options" and "Incompatible options": - */ -tSCC zAuthreqText[] = - "Require crypto authentication"; -tSCC zAuthreq_NAME[] = "AUTHREQ"; -tSCC zAuthreq_Name[] = "authreq"; -static const int - aAuthreqCantList[] = { - INDEX_OPT_AUTHNOREQ, NO_EQUIVALENT }; -#define AUTHREQ_FLAGS (OPTST_DISABLED) - -/* - * Authnoreq option description with - * "Must also have options" and "Incompatible options": - */ -tSCC zAuthnoreqText[] = - "Do not require crypto authentication"; -tSCC zAuthnoreq_NAME[] = "AUTHNOREQ"; -tSCC zAuthnoreq_Name[] = "authnoreq"; -static const int - aAuthnoreqCantList[] = { - INDEX_OPT_AUTHREQ, NO_EQUIVALENT }; -#define AUTHNOREQ_FLAGS (OPTST_DISABLED) - -/* - * Bcastsync option description: - */ -tSCC zBcastsyncText[] = - "Allow us to sync to broadcast servers"; -tSCC zBcastsync_NAME[] = "BCASTSYNC"; -tSCC zBcastsync_Name[] = "bcastsync"; -#define BCASTSYNC_FLAGS (OPTST_DISABLED) - -/* - * Simbroadcastdelay option description: - */ -tSCC zSimbroadcastdelayText[] = - "Simulator broadcast delay"; -tSCC zSimbroadcastdelay_NAME[] = "SIMBROADCASTDELAY"; -tSCC zSimbroadcastdelay_Name[] = "simbroadcastdelay"; -#define SIMBROADCASTDELAY_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Configfile option description: - */ -tSCC zConfigfileText[] = - "configuration file name"; -tSCC zConfigfile_NAME[] = "CONFIGFILE"; -tSCC zConfigfile_Name[] = "configfile"; -#define CONFIGFILE_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Phasenoise option description: - */ -tSCC zPhasenoiseText[] = - "Phase noise level"; -tSCC zPhasenoise_NAME[] = "PHASENOISE"; -tSCC zPhasenoise_Name[] = "phasenoise"; -#define PHASENOISE_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Debug_Level option description: - */ -#ifdef DEBUG -tSCC zDebug_LevelText[] = - "Increase output debug message level"; -tSCC zDebug_Level_NAME[] = "DEBUG_LEVEL"; -tSCC zDebug_Level_Name[] = "debug-level"; -#define DEBUG_LEVEL_FLAGS (OPTST_DISABLED) - -#else /* disable Debug_Level */ -#define VALUE_OPT_DEBUG_LEVEL NO_EQUIVALENT -#define DEBUG_LEVEL_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zDebug_LevelText NULL -#define zDebug_Level_NAME NULL -#define zDebug_Level_Name NULL -#endif /* DEBUG */ - -/* - * Set_Debug_Level option description: - */ -#ifdef DEBUG -tSCC zSet_Debug_LevelText[] = - "Set the output debug message level"; -tSCC zSet_Debug_Level_NAME[] = "SET_DEBUG_LEVEL"; -tSCC zSet_Debug_Level_Name[] = "set-debug-level"; -#define SET_DEBUG_LEVEL_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -#else /* disable Set_Debug_Level */ -#define VALUE_OPT_SET_DEBUG_LEVEL NO_EQUIVALENT -#define SET_DEBUG_LEVEL_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zSet_Debug_LevelText NULL -#define zSet_Debug_Level_NAME NULL -#define zSet_Debug_Level_Name NULL -#endif /* DEBUG */ - -/* - * Driftfile option description: - */ -tSCC zDriftfileText[] = - "frequency drift file name"; -tSCC zDriftfile_NAME[] = "DRIFTFILE"; -tSCC zDriftfile_Name[] = "driftfile"; -#define DRIFTFILE_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Panicgate option description: - */ -tSCC zPanicgateText[] = - "Allow the first adjustment to be Big"; -tSCC zPanicgate_NAME[] = "PANICGATE"; -tSCC zPanicgate_Name[] = "panicgate"; -#define PANICGATE_FLAGS (OPTST_DISABLED) - -/* - * Simslew option description: - */ -tSCC zSimslewText[] = - "Simuator slew"; -tSCC zSimslew_NAME[] = "SIMSLEW"; -tSCC zSimslew_Name[] = "simslew"; -#define SIMSLEW_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Jaildir option description: - */ -tSCC zJaildirText[] = - "Jail directory"; -tSCC zJaildir_NAME[] = "JAILDIR"; -tSCC zJaildir_Name[] = "jaildir"; -#define JAILDIR_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Interface option description: - */ -tSCC zInterfaceText[] = - "Listen on interface"; -tSCC zInterface_NAME[] = "INTERFACE"; -tSCC zInterface_Name[] = "interface"; -#define INTERFACE_FLAGS (OPTST_DISABLED | OPTST_STACKED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Keyfile option description: - */ -tSCC zKeyfileText[] = - "path to symmetric keys"; -tSCC zKeyfile_NAME[] = "KEYFILE"; -tSCC zKeyfile_Name[] = "keyfile"; -#define KEYFILE_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Logfile option description: - */ -tSCC zLogfileText[] = - "path to the log file"; -tSCC zLogfile_NAME[] = "LOGFILE"; -tSCC zLogfile_Name[] = "logfile"; -#define LOGFILE_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Novirtualips option description: - */ -tSCC zNovirtualipsText[] = - "Do not listen to virtual IPs"; -tSCC zNovirtualips_NAME[] = "NOVIRTUALIPS"; -tSCC zNovirtualips_Name[] = "novirtualips"; -#define NOVIRTUALIPS_FLAGS (OPTST_DISABLED) - -/* - * Modifymmtimer option description: - */ -#ifdef SYS_WINNT -tSCC zModifymmtimerText[] = - "Modify Multimedia Timer (Windows only)"; -tSCC zModifymmtimer_NAME[] = "MODIFYMMTIMER"; -tSCC zModifymmtimer_Name[] = "modifymmtimer"; -#define MODIFYMMTIMER_FLAGS (OPTST_DISABLED) - -#else /* disable Modifymmtimer */ -#define VALUE_OPT_MODIFYMMTIMER NO_EQUIVALENT -#define MODIFYMMTIMER_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zModifymmtimerText NULL -#define zModifymmtimer_NAME NULL -#define zModifymmtimer_Name NULL -#endif /* SYS_WINNT */ - -/* - * Nofork option description: - */ -tSCC zNoforkText[] = - "Do not fork"; -tSCC zNofork_NAME[] = "NOFORK"; -tSCC zNofork_Name[] = "nofork"; -#define NOFORK_FLAGS (OPTST_DISABLED) - -/* - * Nice option description: - */ -tSCC zNiceText[] = - "Run at high priority"; -tSCC zNice_NAME[] = "NICE"; -tSCC zNice_Name[] = "nice"; -#define NICE_FLAGS (OPTST_DISABLED) - -/* - * Servertime option description: - */ -tSCC zServertimeText[] = - "Server time"; -tSCC zServertime_NAME[] = "SERVERTIME"; -tSCC zServertime_Name[] = "servertime"; -#define SERVERTIME_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Pidfile option description: - */ -tSCC zPidfileText[] = - "path to the PID file"; -tSCC zPidfile_NAME[] = "PIDFILE"; -tSCC zPidfile_Name[] = "pidfile"; -#define PIDFILE_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Priority option description: - */ -tSCC zPriorityText[] = - "Process priority"; -tSCC zPriority_NAME[] = "PRIORITY"; -tSCC zPriority_Name[] = "priority"; -#define PRIORITY_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_NUMERIC)) - -/* - * Quit option description: - */ -tSCC zQuitText[] = - "Set the time and quit"; -tSCC zQuit_NAME[] = "QUIT"; -tSCC zQuit_Name[] = "quit"; -#define QUIT_FLAGS (OPTST_DISABLED) - -/* - * Propagationdelay option description: - */ -tSCC zPropagationdelayText[] = - "Broadcast/propagation delay"; -tSCC zPropagationdelay_NAME[] = "PROPAGATIONDELAY"; -tSCC zPropagationdelay_Name[] = "propagationdelay"; -#define PROPAGATIONDELAY_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Updateinterval option description: - */ -tSCC zUpdateintervalText[] = - "interval in seconds between scans for new or dropped interfaces"; -tSCC zUpdateinterval_NAME[] = "UPDATEINTERVAL"; -tSCC zUpdateinterval_Name[] = "updateinterval"; -#define UPDATEINTERVAL_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_NUMERIC)) - -/* - * Statsdir option description: - */ -tSCC zStatsdirText[] = - "Statistics file location"; -tSCC zStatsdir_NAME[] = "STATSDIR"; -tSCC zStatsdir_Name[] = "statsdir"; -#define STATSDIR_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Endsimtime option description: - */ -tSCC zEndsimtimeText[] = - "Simulation end time"; -tSCC zEndsimtime_NAME[] = "ENDSIMTIME"; -tSCC zEndsimtime_Name[] = "endsimtime"; -#define ENDSIMTIME_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Trustedkey option description: - */ -tSCC zTrustedkeyText[] = - "Trusted key number"; -tSCC zTrustedkey_NAME[] = "TRUSTEDKEY"; -tSCC zTrustedkey_Name[] = "trustedkey"; -#define TRUSTEDKEY_FLAGS (OPTST_DISABLED | OPTST_STACKED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Freqerr option description: - */ -tSCC zFreqerrText[] = - "Simulation frequency error"; -tSCC zFreqerr_NAME[] = "FREQERR"; -tSCC zFreqerr_Name[] = "freqerr"; -#define FREQERR_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Walknoise option description: - */ -tSCC zWalknoiseText[] = - "Simulation random walk noise"; -tSCC zWalknoise_NAME[] = "WALKNOISE"; -tSCC zWalknoise_Name[] = "walknoise"; -#define WALKNOISE_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * User option description: - */ -tSCC zUserText[] = - "Run as userid (or userid:groupid)"; -tSCC zUser_NAME[] = "USER"; -tSCC zUser_Name[] = "user"; -#define USER_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Var option description: - */ -tSCC zVarText[] = - "make ARG an ntp variable (RW)"; -tSCC zVar_NAME[] = "VAR"; -tSCC zVar_Name[] = "var"; -#define VAR_FLAGS (OPTST_DISABLED | OPTST_STACKED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Dvar option description: - */ -tSCC zDvarText[] = - "make ARG an ntp variable (RW|DEF)"; -tSCC zDvar_NAME[] = "DVAR"; -tSCC zDvar_Name[] = "dvar"; -#define DVAR_FLAGS (OPTST_DISABLED | OPTST_STACKED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Slew option description: - */ -tSCC zSlewText[] = - "Slew up to 600 seconds"; -tSCC zSlew_NAME[] = "SLEW"; -tSCC zSlew_Name[] = "slew"; -#define SLEW_FLAGS (OPTST_DISABLED) - -/* - * Ndelay option description: - */ -tSCC zNdelayText[] = - "Simulation network delay"; -tSCC zNdelay_NAME[] = "NDELAY"; -tSCC zNdelay_Name[] = "ndelay"; -#define NDELAY_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Pdelay option description: - */ -tSCC zPdelayText[] = - "Simulation processing delay"; -tSCC zPdelay_NAME[] = "PDELAY"; -tSCC zPdelay_Name[] = "pdelay"; -#define PDELAY_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Help/More_Help/Version option descriptions: - */ -tSCC zHelpText[] = "Display usage information and exit"; -tSCC zHelp_Name[] = "help"; - -tSCC zMore_HelpText[] = "Extended usage information passed thru pager"; -tSCC zMore_Help_Name[] = "more-help"; - -tSCC zVersionText[] = "Output version information and exit"; -tSCC zVersion_Name[] = "version"; - -/* - * Save/Load_Opts option description: - */ -tSCC zSave_OptsText[] = "Save the option state to a config file"; -tSCC zSave_Opts_Name[] = "save-opts"; - -tSCC zLoad_OptsText[] = "Load options from a config file"; -tSCC zLoad_Opts_NAME[] = "LOAD_OPTS"; - -tSCC zNotLoad_Opts_Name[] = "no-load-opts"; -tSCC zNotLoad_Opts_Pfx[] = "no"; -#define zLoad_Opts_Name (zNotLoad_Opts_Name + 3) -/* - * Declare option callback procedures - */ -#ifdef DEBUG - static tOptProc doOptSet_Debug_Level; -#else /* not DEBUG */ -# define doOptSet_Debug_Level NULL -#endif /* def/not DEBUG */ -#if defined(TEST_NTPDSIM_OPTS) -/* - * Under test, omit argument processing, or call optionStackArg, - * if multiple copies are allowed. - */ -extern tOptProc - optionNumericVal, optionPagedUsage, optionStackArg, - optionVersionStderr; -static tOptProc - doUsageOpt; - -/* - * #define map the "normal" callout procs to the test ones... - */ -#define SET_DEBUG_LEVEL_OPT_PROC optionStackArg - - -#else /* NOT defined TEST_NTPDSIM_OPTS */ -/* - * When not under test, there are different procs to use - */ -extern tOptProc - optionNumericVal, optionPagedUsage, optionPrintVersion, optionStackArg; -static tOptProc - doUsageOpt; - -/* - * #define map the "normal" callout procs - */ -#define SET_DEBUG_LEVEL_OPT_PROC doOptSet_Debug_Level - -#define SET_DEBUG_LEVEL_OPT_PROC doOptSet_Debug_Level -#endif /* defined(TEST_NTPDSIM_OPTS) */ -#ifdef TEST_NTPDSIM_OPTS -# define DOVERPROC optionVersionStderr -#else -# define DOVERPROC optionPrintVersion -#endif /* TEST_NTPDSIM_OPTS */ - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * Define the Ntpdsim Option Descriptions. - */ -static tOptDesc optDesc[ OPTION_CT ] = { - { /* entry idx, value */ 0, VALUE_OPT_IPV4, - /* equiv idx, value */ NO_EQUIVALENT, 0, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ IPV4_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zIpv4Text, zIpv4_NAME, zIpv4_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 1, VALUE_OPT_IPV6, - /* equiv idx, value */ NOLIMIT, NOLIMIT, - /* equivalenced to */ INDEX_OPT_IPV4, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ IPV6_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zIpv6Text, zIpv6_NAME, zIpv6_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 2, VALUE_OPT_AUTHREQ, - /* equiv idx, value */ 2, VALUE_OPT_AUTHREQ, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ AUTHREQ_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, aAuthreqCantList, - /* option proc */ NULL, - /* desc, NAME, name */ zAuthreqText, zAuthreq_NAME, zAuthreq_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 3, VALUE_OPT_AUTHNOREQ, - /* equiv idx, value */ 3, VALUE_OPT_AUTHNOREQ, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ AUTHNOREQ_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, aAuthnoreqCantList, - /* option proc */ NULL, - /* desc, NAME, name */ zAuthnoreqText, zAuthnoreq_NAME, zAuthnoreq_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 4, VALUE_OPT_BCASTSYNC, - /* equiv idx, value */ 4, VALUE_OPT_BCASTSYNC, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ BCASTSYNC_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zBcastsyncText, zBcastsync_NAME, zBcastsync_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 5, VALUE_OPT_SIMBROADCASTDELAY, - /* equiv idx, value */ 5, VALUE_OPT_SIMBROADCASTDELAY, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ SIMBROADCASTDELAY_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zSimbroadcastdelayText, zSimbroadcastdelay_NAME, zSimbroadcastdelay_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 6, VALUE_OPT_CONFIGFILE, - /* equiv idx, value */ 6, VALUE_OPT_CONFIGFILE, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ CONFIGFILE_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zConfigfileText, zConfigfile_NAME, zConfigfile_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 7, VALUE_OPT_PHASENOISE, - /* equiv idx, value */ 7, VALUE_OPT_PHASENOISE, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ PHASENOISE_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zPhasenoiseText, zPhasenoise_NAME, zPhasenoise_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 8, VALUE_OPT_DEBUG_LEVEL, - /* equiv idx, value */ 8, VALUE_OPT_DEBUG_LEVEL, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, NOLIMIT, 0, - /* opt state flags */ DEBUG_LEVEL_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zDebug_LevelText, zDebug_Level_NAME, zDebug_Level_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 9, VALUE_OPT_SET_DEBUG_LEVEL, - /* equiv idx, value */ 9, VALUE_OPT_SET_DEBUG_LEVEL, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, NOLIMIT, 0, - /* opt state flags */ SET_DEBUG_LEVEL_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ SET_DEBUG_LEVEL_OPT_PROC, - /* desc, NAME, name */ zSet_Debug_LevelText, zSet_Debug_Level_NAME, zSet_Debug_Level_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 10, VALUE_OPT_DRIFTFILE, - /* equiv idx, value */ 10, VALUE_OPT_DRIFTFILE, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ DRIFTFILE_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zDriftfileText, zDriftfile_NAME, zDriftfile_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 11, VALUE_OPT_PANICGATE, - /* equiv idx, value */ 11, VALUE_OPT_PANICGATE, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ PANICGATE_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zPanicgateText, zPanicgate_NAME, zPanicgate_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 12, VALUE_OPT_SIMSLEW, - /* equiv idx, value */ 12, VALUE_OPT_SIMSLEW, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ SIMSLEW_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zSimslewText, zSimslew_NAME, zSimslew_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 13, VALUE_OPT_JAILDIR, - /* equiv idx, value */ 13, VALUE_OPT_JAILDIR, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ JAILDIR_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zJaildirText, zJaildir_NAME, zJaildir_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 14, VALUE_OPT_INTERFACE, - /* equiv idx, value */ 14, VALUE_OPT_INTERFACE, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, NOLIMIT, 0, - /* opt state flags */ INTERFACE_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ optionStackArg, - /* desc, NAME, name */ zInterfaceText, zInterface_NAME, zInterface_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 15, VALUE_OPT_KEYFILE, - /* equiv idx, value */ 15, VALUE_OPT_KEYFILE, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ KEYFILE_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zKeyfileText, zKeyfile_NAME, zKeyfile_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 16, VALUE_OPT_LOGFILE, - /* equiv idx, value */ 16, VALUE_OPT_LOGFILE, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ LOGFILE_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zLogfileText, zLogfile_NAME, zLogfile_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 17, VALUE_OPT_NOVIRTUALIPS, - /* equiv idx, value */ 17, VALUE_OPT_NOVIRTUALIPS, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ NOVIRTUALIPS_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zNovirtualipsText, zNovirtualips_NAME, zNovirtualips_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 18, VALUE_OPT_MODIFYMMTIMER, - /* equiv idx, value */ 18, VALUE_OPT_MODIFYMMTIMER, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ MODIFYMMTIMER_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zModifymmtimerText, zModifymmtimer_NAME, zModifymmtimer_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 19, VALUE_OPT_NOFORK, - /* equiv idx, value */ 19, VALUE_OPT_NOFORK, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ NOFORK_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zNoforkText, zNofork_NAME, zNofork_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 20, VALUE_OPT_NICE, - /* equiv idx, value */ 20, VALUE_OPT_NICE, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ NICE_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zNiceText, zNice_NAME, zNice_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 21, VALUE_OPT_SERVERTIME, - /* equiv idx, value */ 21, VALUE_OPT_SERVERTIME, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ SERVERTIME_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zServertimeText, zServertime_NAME, zServertime_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 22, VALUE_OPT_PIDFILE, - /* equiv idx, value */ 22, VALUE_OPT_PIDFILE, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ PIDFILE_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zPidfileText, zPidfile_NAME, zPidfile_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 23, VALUE_OPT_PRIORITY, - /* equiv idx, value */ 23, VALUE_OPT_PRIORITY, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ PRIORITY_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ optionNumericVal, - /* desc, NAME, name */ zPriorityText, zPriority_NAME, zPriority_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 24, VALUE_OPT_QUIT, - /* equiv idx, value */ 24, VALUE_OPT_QUIT, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ QUIT_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zQuitText, zQuit_NAME, zQuit_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 25, VALUE_OPT_PROPAGATIONDELAY, - /* equiv idx, value */ 25, VALUE_OPT_PROPAGATIONDELAY, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ PROPAGATIONDELAY_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zPropagationdelayText, zPropagationdelay_NAME, zPropagationdelay_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 26, VALUE_OPT_UPDATEINTERVAL, - /* equiv idx, value */ 26, VALUE_OPT_UPDATEINTERVAL, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ UPDATEINTERVAL_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ optionNumericVal, - /* desc, NAME, name */ zUpdateintervalText, zUpdateinterval_NAME, zUpdateinterval_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 27, VALUE_OPT_STATSDIR, - /* equiv idx, value */ 27, VALUE_OPT_STATSDIR, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ STATSDIR_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zStatsdirText, zStatsdir_NAME, zStatsdir_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 28, VALUE_OPT_ENDSIMTIME, - /* equiv idx, value */ 28, VALUE_OPT_ENDSIMTIME, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ ENDSIMTIME_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zEndsimtimeText, zEndsimtime_NAME, zEndsimtime_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 29, VALUE_OPT_TRUSTEDKEY, - /* equiv idx, value */ 29, VALUE_OPT_TRUSTEDKEY, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, NOLIMIT, 0, - /* opt state flags */ TRUSTEDKEY_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ optionStackArg, - /* desc, NAME, name */ zTrustedkeyText, zTrustedkey_NAME, zTrustedkey_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 30, VALUE_OPT_FREQERR, - /* equiv idx, value */ 30, VALUE_OPT_FREQERR, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ FREQERR_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zFreqerrText, zFreqerr_NAME, zFreqerr_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 31, VALUE_OPT_WALKNOISE, - /* equiv idx, value */ 31, VALUE_OPT_WALKNOISE, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ WALKNOISE_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zWalknoiseText, zWalknoise_NAME, zWalknoise_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 32, VALUE_OPT_USER, - /* equiv idx, value */ 32, VALUE_OPT_USER, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ USER_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zUserText, zUser_NAME, zUser_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 33, VALUE_OPT_VAR, - /* equiv idx, value */ 33, VALUE_OPT_VAR, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, NOLIMIT, 0, - /* opt state flags */ VAR_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ optionStackArg, - /* desc, NAME, name */ zVarText, zVar_NAME, zVar_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 34, VALUE_OPT_DVAR, - /* equiv idx, value */ 34, VALUE_OPT_DVAR, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, NOLIMIT, 0, - /* opt state flags */ DVAR_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ optionStackArg, - /* desc, NAME, name */ zDvarText, zDvar_NAME, zDvar_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 35, VALUE_OPT_SLEW, - /* equiv idx, value */ 35, VALUE_OPT_SLEW, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ SLEW_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zSlewText, zSlew_NAME, zSlew_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 36, VALUE_OPT_NDELAY, - /* equiv idx, value */ 36, VALUE_OPT_NDELAY, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ NDELAY_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zNdelayText, zNdelay_NAME, zNdelay_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 37, VALUE_OPT_PDELAY, - /* equiv idx, value */ 37, VALUE_OPT_PDELAY, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ PDELAY_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zPdelayText, zPdelay_NAME, zPdelay_Name, - /* disablement strs */ NULL, NULL }, - -#ifdef NO_OPTIONAL_OPT_ARGS -# define VERSION_OPT_FLAGS OPTST_IMM | OPTST_NO_INIT -#else -# define VERSION_OPT_FLAGS OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ - OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT -#endif - - { /* entry idx, value */ INDEX_OPT_VERSION, VALUE_OPT_VERSION, - /* equiv idx value */ NO_EQUIVALENT, 0, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ VERSION_OPT_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ DOVERPROC, - /* desc, NAME, name */ zVersionText, NULL, zVersion_Name, - /* disablement strs */ NULL, NULL }, - -#undef VERSION_OPT_FLAGS - - - { /* entry idx, value */ INDEX_OPT_HELP, VALUE_OPT_HELP, - /* equiv idx value */ NO_EQUIVALENT, 0, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ doUsageOpt, - /* desc, NAME, name */ zHelpText, NULL, zHelp_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ INDEX_OPT_MORE_HELP, VALUE_OPT_MORE_HELP, - /* equiv idx value */ NO_EQUIVALENT, 0, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ optionPagedUsage, - /* desc, NAME, name */ zMore_HelpText, NULL, zMore_Help_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ INDEX_OPT_SAVE_OPTS, VALUE_OPT_SAVE_OPTS, - /* equiv idx value */ NO_EQUIVALENT, 0, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) - | OPTST_ARG_OPTIONAL | OPTST_NO_INIT, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zSave_OptsText, NULL, zSave_Opts_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ INDEX_OPT_LOAD_OPTS, VALUE_OPT_LOAD_OPTS, - /* equiv idx value */ NO_EQUIVALENT, 0, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, NOLIMIT, 0, - /* opt state flags */ OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) \ - | OPTST_DISABLE_IMM, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ optionLoadOpt, - /* desc, NAME, name */ zLoad_OptsText, zLoad_Opts_NAME, zLoad_Opts_Name, - /* disablement strs */ zNotLoad_Opts_Name, zNotLoad_Opts_Pfx } -}; - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * Define the Ntpdsim Option Environment - */ -tSCC zPROGNAME[] = "NTPDSIM"; -tSCC zUsageTitle[] = -"ntpdsim - NTP daemon simulation program - Ver. 4.2.4p8\n\ -USAGE: %s [ - [] | --[{=| }] ]...\n"; -tSCC zRcName[] = ".ntprc"; -tSCC* apzHomeList[] = { - "$HOME", - ".", - NULL }; - -tSCC zBugsAddr[] = "http://bugs.ntp.org, bugs@ntp.org"; -#define zExplain NULL -tSCC zDetail[] = "\n\n"; -tSCC zFullVersion[] = NTPDSIM_FULL_VERSION; -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optcode.tpl near line 408 */ - -#if defined(ENABLE_NLS) -# define OPTPROC_BASE OPTPROC_TRANSLATE - static tOptionXlateProc translate_option_strings; -#else -# define OPTPROC_BASE OPTPROC_NONE -# define translate_option_strings NULL -#endif /* ENABLE_NLS */ - -tOptions ntpdsimOptions = { - OPTIONS_STRUCT_VERSION, - 0, NULL, /* original argc + argv */ - ( OPTPROC_BASE - + OPTPROC_ERRSTOP - + OPTPROC_SHORTOPT - + OPTPROC_LONGOPT - + OPTPROC_NO_REQ_OPT - + OPTPROC_ENVIRON - + OPTPROC_NO_ARGS - + OPTPROC_HAS_IMMED ), - 0, NULL, /* current option index, current option */ - NULL, NULL, zPROGNAME, - zRcName, zCopyright, zCopyrightNotice, - zFullVersion, apzHomeList, zUsageTitle, - zExplain, zDetail, optDesc, - zBugsAddr, /* address to send bugs to */ - NULL, NULL, /* extensions/saved state */ - optionUsage, /* usage procedure */ - translate_option_strings, /* translation procedure */ - /* - * Indexes to special options - */ - { INDEX_OPT_MORE_HELP, - INDEX_OPT_SAVE_OPTS, - NO_EQUIVALENT /* index of '-#' option */, - NO_EQUIVALENT /* index of default opt */ - }, - 43 /* full option count */, 38 /* user option count */ -}; - -/* - * Create the static procedure(s) declared above. - */ -static void -doUsageOpt( - tOptions* pOptions, - tOptDesc* pOptDesc ) -{ - USAGE( EXIT_SUCCESS ); -} - -#if ! defined(TEST_NTPDSIM_OPTS) - -/* * * * * * * - * - * For the set-debug-level option, when DEBUG is #define-d. - */ -#ifdef DEBUG -static void -doOptSet_Debug_Level( - tOptions* pOptions, - tOptDesc* pOptDesc ) -{ - /* extracted from ../include/debug-opt.def, line 29 */ -DESC(DEBUG_LEVEL).optOccCt = atoi( pOptDesc->pzLastArg ); -} -#endif /* defined DEBUG */ - -#endif /* defined(TEST_NTPDSIM_OPTS) */ - -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optmain.tpl near line 92 */ - -#if defined(TEST_NTPDSIM_OPTS) /* TEST MAIN PROCEDURE: */ - -int -main( int argc, char** argv ) -{ - int res = EXIT_SUCCESS; - (void)optionProcess( &ntpdsimOptions, argc, argv ); - { - void optionPutShell( tOptions* ); - optionPutShell( &ntpdsimOptions ); - } - return res; -} -#endif /* defined TEST_NTPDSIM_OPTS */ -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optcode.tpl near line 514 */ - -#if ENABLE_NLS -#include -#include -#include -#include -#include - -static char* AO_gettext( char const* pz ); -static void coerce_it(void** s); - -static char* -AO_gettext( char const* pz ) -{ - char* pzRes; - if (pz == NULL) - return NULL; - pzRes = _(pz); - if (pzRes == pz) - return pzRes; - pzRes = strdup( pzRes ); - if (pzRes == NULL) { - fputs( _("No memory for duping translated strings\n"), stderr ); - exit( EXIT_FAILURE ); - } - return pzRes; -} - -static void coerce_it(void** s) { *s = AO_gettext(*s); } -#define COERSION(_f) \ - coerce_it((void*)&(ntpdsimOptions._f)) - -/* - * This invokes the translation code (e.g. gettext(3)). - */ -static void -translate_option_strings( void ) -{ - /* - * Guard against re-translation. It won't work. The strings will have - * been changed by the first pass through this code. One shot only. - */ - if (option_usage_text.field_ct == 0) - return; - /* - * Do the translations. The first pointer follows the field count field. - * The field count field is the size of a pointer. - */ - { - char** ppz = (char**)(void*)&(option_usage_text); - int ix = option_usage_text.field_ct; - - do { - ppz++; - *ppz = AO_gettext(*ppz); - } while (--ix > 0); - } - option_usage_text.field_ct = 0; - - { - tOptDesc* pOD = ntpdsimOptions.pOptDesc; - int ix = ntpdsimOptions.optCt; - - for (;;) { - pOD->pzText = AO_gettext(pOD->pzText); - pOD->pz_NAME = AO_gettext(pOD->pz_NAME); - pOD->pz_Name = AO_gettext(pOD->pz_Name); - pOD->pz_DisableName = AO_gettext(pOD->pz_DisableName); - pOD->pz_DisablePfx = AO_gettext(pOD->pz_DisablePfx); - if (--ix <= 0) - break; - pOD++; - } - } - COERSION(pzCopyright); - COERSION(pzCopyNotice); - COERSION(pzFullVersion); - COERSION(pzUsageTitle); - COERSION(pzExplain); - COERSION(pzDetail); -} - -#endif /* ENABLE_NLS */ - -#ifdef __cplusplus -} -#endif -/* ntpdsim-opts.c ends here */ diff -urN src/contrib/ntp/ntpd/ntpdsim-opts.def src.ntp/contrib/ntp/ntpd/ntpdsim-opts.def --- src/contrib/ntp/ntpd/ntpdsim-opts.def 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/ntpdsim-opts.def 1970-01-01 01:00:00.000000000 +0100 @@ -1,15 +0,0 @@ -/* -*- Mode: Text -*- */ - -autogen definitions options; - -#include copyright.def -#include homerc.def - -prog-name = "ntpdsim"; -prog-title = "NTP daemon simulation program"; - -#define SIM -#include ntpdbase-opts.def - -detail = <<- _END_DETAIL - _END_DETAIL; diff -urN src/contrib/ntp/ntpd/ntpdsim-opts.h src.ntp/contrib/ntp/ntpd/ntpdsim-opts.h --- src/contrib/ntp/ntpd/ntpdsim-opts.h 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/ntpdsim-opts.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,422 +0,0 @@ -/* - * EDIT THIS FILE WITH CAUTION (ntpdsim-opts.h) - * - * It has been AutoGen-ed Tuesday December 8, 2009 at 08:13:12 AM EST - * From the definitions ntpdsim-opts.def - * and the template file options - * - * Generated from AutoOpts 29:0:4 templates. - */ - -/* - * This file was produced by an AutoOpts template. AutoOpts is a - * copyrighted work. This header file is not encumbered by AutoOpts - * licensing, but is provided under the licensing terms chosen by the - * ntpdsim author or copyright holder. AutoOpts is licensed under - * the terms of the LGPL. The redistributable library (``libopts'') is - * licensed under the terms of either the LGPL or, at the users discretion, - * the BSD license. See the AutoOpts and/or libopts sources for details. - * - * This source file is copyrighted and licensed under the following terms: - * - * ntpdsim copyright 1970-2009 David L. Mills and/or others - all rights reserved - * - * see html/copyright.html - */ -/* - * This file contains the programmatic interface to the Automated - * Options generated for the ntpdsim program. - * These macros are documented in the AutoGen info file in the - * "AutoOpts" chapter. Please refer to that doc for usage help. - */ -#ifndef AUTOOPTS_NTPDSIM_OPTS_H_GUARD -#define AUTOOPTS_NTPDSIM_OPTS_H_GUARD -#include "config.h" -#include - -/* - * Ensure that the library used for compiling this generated header is at - * least as new as the version current when the header template was released - * (not counting patch version increments). Also ensure that the oldest - * tolerable version is at least as old as what was current when the header - * template was released. - */ -#define AO_TEMPLATE_VERSION 118784 -#if (AO_TEMPLATE_VERSION < OPTIONS_MINIMUM_VERSION) \ - || (AO_TEMPLATE_VERSION > OPTIONS_STRUCT_VERSION) -# error option template version mismatches autoopts/options.h header - Choke Me. -#endif - -/* - * Enumeration of each option: - */ -typedef enum { - INDEX_OPT_IPV4 = 0, - INDEX_OPT_IPV6 = 1, - INDEX_OPT_AUTHREQ = 2, - INDEX_OPT_AUTHNOREQ = 3, - INDEX_OPT_BCASTSYNC = 4, - INDEX_OPT_SIMBROADCASTDELAY = 5, - INDEX_OPT_CONFIGFILE = 6, - INDEX_OPT_PHASENOISE = 7, - INDEX_OPT_DEBUG_LEVEL = 8, - INDEX_OPT_SET_DEBUG_LEVEL = 9, - INDEX_OPT_DRIFTFILE = 10, - INDEX_OPT_PANICGATE = 11, - INDEX_OPT_SIMSLEW = 12, - INDEX_OPT_JAILDIR = 13, - INDEX_OPT_INTERFACE = 14, - INDEX_OPT_KEYFILE = 15, - INDEX_OPT_LOGFILE = 16, - INDEX_OPT_NOVIRTUALIPS = 17, - INDEX_OPT_MODIFYMMTIMER = 18, - INDEX_OPT_NOFORK = 19, - INDEX_OPT_NICE = 20, - INDEX_OPT_SERVERTIME = 21, - INDEX_OPT_PIDFILE = 22, - INDEX_OPT_PRIORITY = 23, - INDEX_OPT_QUIT = 24, - INDEX_OPT_PROPAGATIONDELAY = 25, - INDEX_OPT_UPDATEINTERVAL = 26, - INDEX_OPT_STATSDIR = 27, - INDEX_OPT_ENDSIMTIME = 28, - INDEX_OPT_TRUSTEDKEY = 29, - INDEX_OPT_FREQERR = 30, - INDEX_OPT_WALKNOISE = 31, - INDEX_OPT_USER = 32, - INDEX_OPT_VAR = 33, - INDEX_OPT_DVAR = 34, - INDEX_OPT_SLEW = 35, - INDEX_OPT_NDELAY = 36, - INDEX_OPT_PDELAY = 37, - INDEX_OPT_VERSION = 38, - INDEX_OPT_HELP = 39, - INDEX_OPT_MORE_HELP = 40, - INDEX_OPT_SAVE_OPTS = 41, - INDEX_OPT_LOAD_OPTS = 42 -} teOptIndex; - -#define OPTION_CT 43 -#define NTPDSIM_VERSION "4.2.4p8" -#define NTPDSIM_FULL_VERSION "ntpdsim - NTP daemon simulation program - Ver. 4.2.4p8" - -/* - * Interface defines for all options. Replace "n" with the UPPER_CASED - * option name (as in the teOptIndex enumeration above). - * e.g. HAVE_OPT( IPV4 ) - */ -#define DESC(n) (ntpdsimOptions.pOptDesc[INDEX_OPT_## n]) -#define HAVE_OPT(n) (! UNUSED_OPT(& DESC(n))) -#define OPT_ARG(n) (DESC(n).optArg.argString) -#define STATE_OPT(n) (DESC(n).fOptState & OPTST_SET_MASK) -#define COUNT_OPT(n) (DESC(n).optOccCt) -#define ISSEL_OPT(n) (SELECTED_OPT(&DESC(n))) -#define ISUNUSED_OPT(n) (UNUSED_OPT(& DESC(n))) -#define ENABLED_OPT(n) (! DISABLED_OPT(& DESC(n))) -#define STACKCT_OPT(n) (((tArgList*)(DESC(n).optCookie))->useCt) -#define STACKLST_OPT(n) (((tArgList*)(DESC(n).optCookie))->apzArgs) -#define CLEAR_OPT(n) STMTS( \ - DESC(n).fOptState &= OPTST_PERSISTENT_MASK; \ - if ( (DESC(n).fOptState & OPTST_INITENABLED) == 0) \ - DESC(n).fOptState |= OPTST_DISABLED; \ - DESC(n).optCookie = NULL ) - -/* - * Make sure there are no #define name conflicts with the option names - */ -#ifndef NO_OPTION_NAME_WARNINGS -# ifdef IPV4 -# warning undefining IPV4 due to option name conflict -# undef IPV4 -# endif -# ifdef IPV6 -# warning undefining IPV6 due to option name conflict -# undef IPV6 -# endif -# ifdef AUTHREQ -# warning undefining AUTHREQ due to option name conflict -# undef AUTHREQ -# endif -# ifdef AUTHNOREQ -# warning undefining AUTHNOREQ due to option name conflict -# undef AUTHNOREQ -# endif -# ifdef BCASTSYNC -# warning undefining BCASTSYNC due to option name conflict -# undef BCASTSYNC -# endif -# ifdef SIMBROADCASTDELAY -# warning undefining SIMBROADCASTDELAY due to option name conflict -# undef SIMBROADCASTDELAY -# endif -# ifdef CONFIGFILE -# warning undefining CONFIGFILE due to option name conflict -# undef CONFIGFILE -# endif -# ifdef PHASENOISE -# warning undefining PHASENOISE due to option name conflict -# undef PHASENOISE -# endif -# ifdef DEBUG_LEVEL -# warning undefining DEBUG_LEVEL due to option name conflict -# undef DEBUG_LEVEL -# endif -# ifdef SET_DEBUG_LEVEL -# warning undefining SET_DEBUG_LEVEL due to option name conflict -# undef SET_DEBUG_LEVEL -# endif -# ifdef DRIFTFILE -# warning undefining DRIFTFILE due to option name conflict -# undef DRIFTFILE -# endif -# ifdef PANICGATE -# warning undefining PANICGATE due to option name conflict -# undef PANICGATE -# endif -# ifdef SIMSLEW -# warning undefining SIMSLEW due to option name conflict -# undef SIMSLEW -# endif -# ifdef JAILDIR -# warning undefining JAILDIR due to option name conflict -# undef JAILDIR -# endif -# ifdef INTERFACE -# warning undefining INTERFACE due to option name conflict -# undef INTERFACE -# endif -# ifdef KEYFILE -# warning undefining KEYFILE due to option name conflict -# undef KEYFILE -# endif -# ifdef LOGFILE -# warning undefining LOGFILE due to option name conflict -# undef LOGFILE -# endif -# ifdef NOVIRTUALIPS -# warning undefining NOVIRTUALIPS due to option name conflict -# undef NOVIRTUALIPS -# endif -# ifdef MODIFYMMTIMER -# warning undefining MODIFYMMTIMER due to option name conflict -# undef MODIFYMMTIMER -# endif -# ifdef NOFORK -# warning undefining NOFORK due to option name conflict -# undef NOFORK -# endif -# ifdef NICE -# warning undefining NICE due to option name conflict -# undef NICE -# endif -# ifdef SERVERTIME -# warning undefining SERVERTIME due to option name conflict -# undef SERVERTIME -# endif -# ifdef PIDFILE -# warning undefining PIDFILE due to option name conflict -# undef PIDFILE -# endif -# ifdef PRIORITY -# warning undefining PRIORITY due to option name conflict -# undef PRIORITY -# endif -# ifdef QUIT -# warning undefining QUIT due to option name conflict -# undef QUIT -# endif -# ifdef PROPAGATIONDELAY -# warning undefining PROPAGATIONDELAY due to option name conflict -# undef PROPAGATIONDELAY -# endif -# ifdef UPDATEINTERVAL -# warning undefining UPDATEINTERVAL due to option name conflict -# undef UPDATEINTERVAL -# endif -# ifdef STATSDIR -# warning undefining STATSDIR due to option name conflict -# undef STATSDIR -# endif -# ifdef ENDSIMTIME -# warning undefining ENDSIMTIME due to option name conflict -# undef ENDSIMTIME -# endif -# ifdef TRUSTEDKEY -# warning undefining TRUSTEDKEY due to option name conflict -# undef TRUSTEDKEY -# endif -# ifdef FREQERR -# warning undefining FREQERR due to option name conflict -# undef FREQERR -# endif -# ifdef WALKNOISE -# warning undefining WALKNOISE due to option name conflict -# undef WALKNOISE -# endif -# ifdef USER -# warning undefining USER due to option name conflict -# undef USER -# endif -# ifdef VAR -# warning undefining VAR due to option name conflict -# undef VAR -# endif -# ifdef DVAR -# warning undefining DVAR due to option name conflict -# undef DVAR -# endif -# ifdef SLEW -# warning undefining SLEW due to option name conflict -# undef SLEW -# endif -# ifdef NDELAY -# warning undefining NDELAY due to option name conflict -# undef NDELAY -# endif -# ifdef PDELAY -# warning undefining PDELAY due to option name conflict -# undef PDELAY -# endif -#else /* NO_OPTION_NAME_WARNINGS */ -# undef IPV4 -# undef IPV6 -# undef AUTHREQ -# undef AUTHNOREQ -# undef BCASTSYNC -# undef SIMBROADCASTDELAY -# undef CONFIGFILE -# undef PHASENOISE -# undef DEBUG_LEVEL -# undef SET_DEBUG_LEVEL -# undef DRIFTFILE -# undef PANICGATE -# undef SIMSLEW -# undef JAILDIR -# undef INTERFACE -# undef KEYFILE -# undef LOGFILE -# undef NOVIRTUALIPS -# undef MODIFYMMTIMER -# undef NOFORK -# undef NICE -# undef SERVERTIME -# undef PIDFILE -# undef PRIORITY -# undef QUIT -# undef PROPAGATIONDELAY -# undef UPDATEINTERVAL -# undef STATSDIR -# undef ENDSIMTIME -# undef TRUSTEDKEY -# undef FREQERR -# undef WALKNOISE -# undef USER -# undef VAR -# undef DVAR -# undef SLEW -# undef NDELAY -# undef PDELAY -#endif /* NO_OPTION_NAME_WARNINGS */ - -/* - * Interface defines for specific options. - */ -#define VALUE_OPT_IPV4 '4' -#define WHICH_OPT_IPV4 (DESC(IPV4).optActualValue) -#define WHICH_IDX_IPV4 (DESC(IPV4).optActualIndex) -#define VALUE_OPT_IPV6 '6' -#define VALUE_OPT_AUTHREQ 'a' -#define VALUE_OPT_AUTHNOREQ 'A' -#define VALUE_OPT_BCASTSYNC 'b' -#define VALUE_OPT_SIMBROADCASTDELAY 'B' -#define VALUE_OPT_CONFIGFILE 'c' -#define VALUE_OPT_PHASENOISE 'C' -#ifdef DEBUG -#define VALUE_OPT_DEBUG_LEVEL 'd' -#endif /* DEBUG */ -#ifdef DEBUG -#define VALUE_OPT_SET_DEBUG_LEVEL 'D' -#endif /* DEBUG */ -#define VALUE_OPT_DRIFTFILE 'f' -#define VALUE_OPT_PANICGATE 'g' -#define VALUE_OPT_SIMSLEW 'H' -#define VALUE_OPT_JAILDIR 'i' -#define VALUE_OPT_INTERFACE 'I' -#define VALUE_OPT_KEYFILE 'k' -#define VALUE_OPT_LOGFILE 'l' -#define VALUE_OPT_NOVIRTUALIPS 'L' -#ifdef SYS_WINNT -#define VALUE_OPT_MODIFYMMTIMER 'M' -#endif /* SYS_WINNT */ -#define VALUE_OPT_NOFORK 'n' -#define VALUE_OPT_NICE 'N' -#define VALUE_OPT_SERVERTIME 'O' -#define VALUE_OPT_PIDFILE 'p' -#define VALUE_OPT_PRIORITY 'P' -#define OPT_VALUE_PRIORITY (DESC(PRIORITY).optArg.argInt) -#define VALUE_OPT_QUIT 'q' -#define VALUE_OPT_PROPAGATIONDELAY 'r' -#define VALUE_OPT_UPDATEINTERVAL 'U' -#define OPT_VALUE_UPDATEINTERVAL (DESC(UPDATEINTERVAL).optArg.argInt) -#define VALUE_OPT_STATSDIR 's' -#define VALUE_OPT_ENDSIMTIME 'S' -#define VALUE_OPT_TRUSTEDKEY 't' -#define VALUE_OPT_FREQERR 'T' -#define VALUE_OPT_WALKNOISE 'W' -#define VALUE_OPT_USER 'u' -#define VALUE_OPT_VAR 'v' -#define VALUE_OPT_DVAR 'V' -#define VALUE_OPT_SLEW 'x' -#define VALUE_OPT_NDELAY 'Y' -#define VALUE_OPT_PDELAY 'Z' - -#define VALUE_OPT_VERSION 'v' -#define VALUE_OPT_HELP '?' -#define VALUE_OPT_MORE_HELP '!' -#define VALUE_OPT_SAVE_OPTS '>' -#define VALUE_OPT_LOAD_OPTS '<' -#define SET_OPT_SAVE_OPTS(a) STMTS( \ - DESC(SAVE_OPTS).fOptState &= OPTST_PERSISTENT_MASK; \ - DESC(SAVE_OPTS).fOptState |= OPTST_SET; \ - DESC(SAVE_OPTS).optArg.argString = (char const*)(a) ) -/* - * Interface defines not associated with particular options - */ -#define ERRSKIP_OPTERR STMTS( ntpdsimOptions.fOptSet &= ~OPTPROC_ERRSTOP ) -#define ERRSTOP_OPTERR STMTS( ntpdsimOptions.fOptSet |= OPTPROC_ERRSTOP ) -#define RESTART_OPT(n) STMTS( \ - ntpdsimOptions.curOptIdx = (n); \ - ntpdsimOptions.pzCurOpt = NULL ) -#define START_OPT RESTART_OPT(1) -#define USAGE(c) (*ntpdsimOptions.pUsageProc)( &ntpdsimOptions, c ) -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/opthead.tpl near line 360 */ - -/* * * * * * - * - * Declare the ntpdsim option descriptor. - */ -#ifdef __cplusplus -extern "C" { -#endif - -extern tOptions ntpdsimOptions; - -#ifndef _ -# if ENABLE_NLS -# include - static inline char* aoGetsText( char const* pz ) { - if (pz == NULL) return NULL; - return (char*)gettext( pz ); - } -# define _(s) aoGetsText(s) -# else /* ENABLE_NLS */ -# define _(s) s -# endif /* ENABLE_NLS */ -#endif - -#ifdef __cplusplus -} -#endif -#endif /* AUTOOPTS_NTPDSIM_OPTS_H_GUARD */ -/* ntpdsim-opts.h ends here */ diff -urN src/contrib/ntp/ntpd/ntpdsim-opts.menu src.ntp/contrib/ntp/ntpd/ntpdsim-opts.menu --- src/contrib/ntp/ntpd/ntpdsim-opts.menu 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/ntpdsim-opts.menu 1970-01-01 01:00:00.000000000 +0100 @@ -1 +0,0 @@ -* ntpdsim Invocation:: Invoking ntpdsim diff -urN src/contrib/ntp/ntpd/ntpdsim-opts.texi src.ntp/contrib/ntp/ntpd/ntpdsim-opts.texi --- src/contrib/ntp/ntpd/ntpdsim-opts.texi 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/ntpdsim-opts.texi 1970-01-01 01:00:00.000000000 +0100 @@ -1,568 +0,0 @@ -@node ntpdsim Invocation -@section Invoking ntpdsim -@pindex ntpdsim -@cindex NTP daemon simulation program -@ignore -# -# EDIT THIS FILE WITH CAUTION (ntpdsim-opts.texi) -# -# It has been AutoGen-ed Tuesday December 8, 2009 at 08:13:15 AM EST -# From the definitions ntpdsim-opts.def -# and the template file aginfo.tpl -@end ignore -This program has no explanation. - - - -This section was generated by @strong{AutoGen}, -the aginfo template and the option descriptions for the @command{ntpdsim} program. It documents the ntpdsim usage text and option meanings. - -This software is released under a specialized copyright license. - -@menu -* ntpdsim usage:: ntpdsim usage help (-?) -* ntpdsim authnoreq:: authnoreq option (-A) -* ntpdsim authreq:: authreq option (-a) -* ntpdsim bcastsync:: bcastsync option (-b) -* ntpdsim configfile:: configfile option (-c) -* ntpdsim debug-level:: debug-level option (-d) -* ntpdsim driftfile:: driftfile option (-f) -* ntpdsim dvar:: dvar option (-V) -* ntpdsim endsimtime:: endsimtime option (-S) -* ntpdsim freqerr:: freqerr option (-T) -* ntpdsim interface:: interface option (-I) -* ntpdsim ipv4:: ipv4 option (-4) -* ntpdsim ipv6:: ipv6 option (-6) -* ntpdsim jaildir:: jaildir option (-i) -* ntpdsim keyfile:: keyfile option (-k) -* ntpdsim logfile:: logfile option (-l) -* ntpdsim modifymmtimer:: modifymmtimer option (-M) -* ntpdsim ndelay:: ndelay option (-Y) -* ntpdsim nice:: nice option (-N) -* ntpdsim nofork:: nofork option (-n) -* ntpdsim novirtualips:: novirtualips option (-L) -* ntpdsim panicgate:: panicgate option (-g) -* ntpdsim pdelay:: pdelay option (-Z) -* ntpdsim phasenoise:: phasenoise option (-C) -* ntpdsim pidfile:: pidfile option (-p) -* ntpdsim priority:: priority option (-P) -* ntpdsim propagationdelay:: propagationdelay option (-r) -* ntpdsim quit:: quit option (-q) -* ntpdsim servertime:: servertime option (-O) -* ntpdsim set-debug-level:: set-debug-level option (-D) -* ntpdsim simbroadcastdelay:: simbroadcastdelay option (-B) -* ntpdsim simslew:: simslew option (-H) -* ntpdsim slew:: slew option (-x) -* ntpdsim statsdir:: statsdir option (-s) -* ntpdsim trustedkey:: trustedkey option (-t) -* ntpdsim updateinterval:: updateinterval option (-U) -* ntpdsim user:: user option (-u) -* ntpdsim var:: var option (-v) -* ntpdsim walknoise:: walknoise option (-W) -@end menu - -@node ntpdsim usage -@subsection ntpdsim usage help (-?) -@cindex ntpdsim usage - -This is the automatically generated usage text for ntpdsim: - -@exampleindent 0 -@example -ntpd - NTP daemon program - Ver. 4.2.5p247-RC -USAGE: ntpdsim [ - [] | --[@{=| @}] ]... - Flg Arg Option-Name Description - -4 no ipv4 Force IPv4 DNS name resolution - - prohibits these options: - ipv6 - -6 no ipv6 Force IPv6 DNS name resolution - - prohibits these options: - ipv4 - -a no authreq Require crypto authentication - - prohibits these options: - authnoreq - -A no authnoreq Do not require crypto authentication - - prohibits these options: - authreq - -b no bcastsync Allow us to sync to broadcast servers - -c Str configfile configuration file name - -d no debug-level Increase output debug message level - - may appear multiple times - -D Str set-debug-level Set the output debug message level - - may appear multiple times - -f Str driftfile frequency drift file name - -g no panicgate Allow the first adjustment to be Big - - may appear multiple times - -i --- jaildir built without --enable-clockctl or --enable-linuxcaps - -I Str interface Listen on an interface name or address - - may appear multiple times - -k Str keyfile path to symmetric keys - -l Str logfile path to the log file - -L no novirtualips Do not listen to virtual interfaces - -n no nofork Do not fork - -N no nice Run at high priority - -p Str pidfile path to the PID file - -P Num priority Process priority - -q no quit Set the time and quit - -r Str propagationdelay Broadcast/propagation delay - Str saveconfigquit Save parsed configuration and quit - -s Str statsdir Statistics file location - -t Str trustedkey Trusted key number - - may appear multiple times - -u --- user built without --enable-clockctl or --enable-linuxcaps - -U Num updateinterval interval in seconds between scans for new or dropped interfaces - Str var make ARG an ntp variable (RW) - - may appear multiple times - Str dvar make ARG an ntp variable (RW|DEF) - - may appear multiple times - -x no slew Slew up to 600 seconds - opt version Output version information and exit - -? no help Display extended usage information and exit - -! no more-help Extended usage information passed thru pager - -Options are specified by doubled hyphens and their name -or by a single hyphen and the flag character. - -The following option preset mechanisms are supported: - - examining environment variables named NTPD_* - - - -please send bug reports to: http://bugs.ntp.org, bugs@@ntp.org -@end example -@exampleindent 4 - -@node ntpdsim ipv4 -@subsection ipv4 option (-4) -@cindex ntpdsim-ipv4 - -This is the ``force ipv4 dns name resolution'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -is a member of the ipv4 class of options. -@end itemize - -Force DNS resolution of following host names on the command line -to the IPv4 namespace. - -@node ntpdsim ipv6 -@subsection ipv6 option (-6) -@cindex ntpdsim-ipv6 - -This is the ``force ipv6 dns name resolution'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -is a member of the ipv4 class of options. -@end itemize - -Force DNS resolution of following host names on the command line -to the IPv6 namespace. - -@node ntpdsim authreq -@subsection authreq option (-a) -@cindex ntpdsim-authreq - -This is the ``require crypto authentication'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -must not appear in combination with any of the following options: -authnoreq. -@end itemize - -Require cryptographic authentication for broadcast client, -multicast client and symmetric passive associations. -This is the default. - -@node ntpdsim authnoreq -@subsection authnoreq option (-A) -@cindex ntpdsim-authnoreq - -This is the ``do not require crypto authentication'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -must not appear in combination with any of the following options: -authreq. -@end itemize - -Do not require cryptographic authentication for broadcast client, -multicast client and symmetric passive associations. -This is almost never a good idea. - -@node ntpdsim bcastsync -@subsection bcastsync option (-b) -@cindex ntpdsim-bcastsync - -This is the ``allow us to sync to broadcast servers'' option. - - -@node ntpdsim simbroadcastdelay -@subsection simbroadcastdelay option (-B) -@cindex ntpdsim-simbroadcastdelay - -This is the ``simulator broadcast delay'' option. - - -@node ntpdsim configfile -@subsection configfile option (-c) -@cindex ntpdsim-configfile - -This is the ``configuration file name'' option. -The name and path of the configuration file, -/etc/ntp.conf -by default. - -@node ntpdsim phasenoise -@subsection phasenoise option (-C) -@cindex ntpdsim-phasenoise - -This is the ``phase noise level'' option. - - -@node ntpdsim debug-level -@subsection debug-level option (-d) -@cindex ntpdsim-debug-level - -This is the ``increase output debug message level'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@item -must be compiled in by defining @code{DEBUG} during the compilation. -@end itemize - -Increase the debugging message output level. - -@node ntpdsim set-debug-level -@subsection set-debug-level option (-D) -@cindex ntpdsim-set-debug-level - -This is the ``set the output debug message level'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@item -must be compiled in by defining @code{DEBUG} during the compilation. -@end itemize - -Set the output debugging level. Can be supplied multiple times, -but each overrides the previous value(s). - -@node ntpdsim driftfile -@subsection driftfile option (-f) -@cindex ntpdsim-driftfile - -This is the ``frequency drift file name'' option. -The name and path of the frequency file, -/etc/ntp.drift -by default. -This is the same operation as the -driftfile driftfile -configuration specification in the -/etc/ntp.conf -file. - -@node ntpdsim panicgate -@subsection panicgate option (-g) -@cindex ntpdsim-panicgate - -This is the ``allow the first adjustment to be big'' option. -Normally, -ntpd -exits with a message to the system log if the offset exceeds the panic threshold, which is 1000 s by default. This option allows the time to be set to any value without restriction; however, this can happen only once. If the threshold is exceeded after that, -ntpd -will exit with a message to the system log. This option can be used with the --q -and --x -options. -See the -tinker -configuration file directive for other options. - -@node ntpdsim simslew -@subsection simslew option (-H) -@cindex ntpdsim-simslew - -This is the ``simuator slew'' option. - - -@node ntpdsim jaildir -@subsection jaildir option (-i) -@cindex ntpdsim-jaildir - -This is the ``jail directory'' option. -Chroot the server to the directory -jaildir -. -This option also implies that the server attempts to drop root privileges at startup (otherwise, chroot gives very little additional security), and it is only available if the OS supports to run the server without full root privileges. -You may need to also specify a --u -option. - -@node ntpdsim interface -@subsection interface option (-I) -@cindex ntpdsim-interface - -This is the ``listen on interface'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@end itemize - - - -@node ntpdsim keyfile -@subsection keyfile option (-k) -@cindex ntpdsim-keyfile - -This is the ``path to symmetric keys'' option. -Specify the name and path of the symmetric key file. -/etc/ntp.keys -is the default. -This is the same operation as the -keys keyfile -configuration file directive. - -@node ntpdsim logfile -@subsection logfile option (-l) -@cindex ntpdsim-logfile - -This is the ``path to the log file'' option. -Specify the name and path of the log file. -The default is the system log file. -This is the same operation as the -logfile logfile -configuration file directive. - -@node ntpdsim novirtualips -@subsection novirtualips option (-L) -@cindex ntpdsim-novirtualips - -This is the ``do not listen to virtual ips'' option. -Do not listen to virtual IPs. The default is to listen. - -@node ntpdsim modifymmtimer -@subsection modifymmtimer option (-M) -@cindex ntpdsim-modifymmtimer - -This is the ``modify multimedia timer (windows only)'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -must be compiled in by defining @code{SYS_WINNT} during the compilation. -@end itemize - -Set the Windows Multimedia Timer to highest resolution. - -@node ntpdsim nofork -@subsection nofork option (-n) -@cindex ntpdsim-nofork - -This is the ``do not fork'' option. - - -@node ntpdsim nice -@subsection nice option (-N) -@cindex ntpdsim-nice - -This is the ``run at high priority'' option. -To the extent permitted by the operating system, run -ntpd -at the highest priority. - -@node ntpdsim servertime -@subsection servertime option (-O) -@cindex ntpdsim-servertime - -This is the ``server time'' option. - - -@node ntpdsim pidfile -@subsection pidfile option (-p) -@cindex ntpdsim-pidfile - -This is the ``path to the pid file'' option. -Specify the name and path of the file used to record -ntpd's -process ID. -This is the same operation as the -pidfile pidfile -configuration file directive. - -@node ntpdsim priority -@subsection priority option (-P) -@cindex ntpdsim-priority - -This is the ``process priority'' option. -To the extent permitted by the operating system, run -ntpd -at the specified -sched_setscheduler(SCHED_FIFO) -priority. - -@node ntpdsim quit -@subsection quit option (-q) -@cindex ntpdsim-quit - -This is the ``set the time and quit'' option. -ntpd -will exit just after the first time the clock is set. This behavior mimics that of the -ntpdate -program, which is to be retired. -The --g -and --x -options can be used with this option. -Note: The kernel time discipline is disabled with this option. - -@node ntpdsim propagationdelay -@subsection propagationdelay option (-r) -@cindex ntpdsim-propagationdelay - -This is the ``broadcast/propagation delay'' option. -Specify the default propagation delay from the broadcast/multicast server to this client. This is necessary only if the delay cannot be computed automatically by the protocol. - -@node ntpdsim updateinterval -@subsection updateinterval option (-U) -@cindex ntpdsim-updateinterval - -This is the ``interval in seconds between scans for new or dropped interfaces'' option. -Give the time in seconds between two scans for new or dropped interfaces. -For systems with routing socket support the scans will be performed shortly after the interface change -has been detected by the system. -Use 0 to disable scanning. - -@node ntpdsim statsdir -@subsection statsdir option (-s) -@cindex ntpdsim-statsdir - -This is the ``statistics file location'' option. -Specify the directory path for files created by the statistics facility. -This is the same operation as the -statsdir statsdir -configuration file directive. - -@node ntpdsim endsimtime -@subsection endsimtime option (-S) -@cindex ntpdsim-endsimtime - -This is the ``simulation end time'' option. - - -@node ntpdsim trustedkey -@subsection trustedkey option (-t) -@cindex ntpdsim-trustedkey - -This is the ``trusted key number'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@end itemize - -Add a key number to the trusted key list. - -@node ntpdsim freqerr -@subsection freqerr option (-T) -@cindex ntpdsim-freqerr - -This is the ``simulation frequency error'' option. - - -@node ntpdsim walknoise -@subsection walknoise option (-W) -@cindex ntpdsim-walknoise - -This is the ``simulation random walk noise'' option. - - -@node ntpdsim user -@subsection user option (-u) -@cindex ntpdsim-user - -This is the ``run as userid (or userid:groupid)'' option. -Specify a user, and optionally a group, to switch to. -This option is only available if the OS supports to run the server without full root privileges. -Currently, this option is supported under NetBSD (configure with ---enable-clockctl -) and Linux (configure with ---enable-linuxcaps -). - -@node ntpdsim var -@subsection var option (-v) -@cindex ntpdsim-var - -This is the ``make arg an ntp variable (rw)'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@end itemize - - - -@node ntpdsim dvar -@subsection dvar option (-V) -@cindex ntpdsim-dvar - -This is the ``make arg an ntp variable (rw|def)'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@end itemize - - - -@node ntpdsim slew -@subsection slew option (-x) -@cindex ntpdsim-slew - -This is the ``slew up to 600 seconds'' option. -Normally, the time is slewed if the offset is less than the step threshold, which is 128 ms by default, and stepped if above the threshold. -This option sets the threshold to 600 s, which is well within the accuracy window to set the clock manually. -Note: Since the slew rate of typical Unix kernels is limited to 0.5 ms/s, each second of adjustment requires an amortization interval of 2000 s. -Thus, an adjustment as much as 600 s will take almost 14 days to complete. -This option can be used with the --g -and --q -options. -See the -tinker -configuration file directive for other options. -Note: The kernel time discipline is disabled with this option. - -@node ntpdsim ndelay -@subsection ndelay option (-Y) -@cindex ntpdsim-ndelay - -This is the ``simulation network delay'' option. - - -@node ntpdsim pdelay -@subsection pdelay option (-Z) -@cindex ntpdsim-pdelay - -This is the ``simulation processing delay'' option. - diff -urN src/contrib/ntp/ntpd/ntpdsim.1 src.ntp/contrib/ntp/ntpd/ntpdsim.1 --- src/contrib/ntp/ntpd/ntpdsim.1 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/ntpdsim.1 1970-01-01 01:00:00.000000000 +0100 @@ -1,357 +0,0 @@ -.TH NTPDSIM 1 2009-12-08 "( 4.2.4p8)" "Programmer's Manual" -.\" EDIT THIS FILE WITH CAUTION (ntpdsim.1) -.\" -.\" It has been AutoGen-ed Tuesday December 8, 2009 at 08:13:14 AM EST -.\" From the definitions ntpdsim-opts.def -.\" and the template file agman1.tpl -.\" -.SH NAME -ntpdsim \- NTP daemon simulation program -.SH SYNOPSIS -.B ntpdsim -.\" Mixture of short (flag) options and long options -.RB [ \-\fIflag\fP " [\fIvalue\fP]]... [" \--\fIopt-name\fP " [[=| ]\fIvalue\fP]]..." -.PP -All arguments must be options. -.SH "DESCRIPTION" -This manual page documents, briefly, the \fBntpdsim\fP command. - -.SH OPTIONS -.TP -.BR \-4 ", " \--ipv4 -Force IPv4 DNS name resolution. -This option is a member of the ipv4 class of options. -.sp -Force DNS resolution of following host names on the command line -to the IPv4 namespace. -.TP -.BR \-6 ", " \--ipv6 -Force IPv6 DNS name resolution. -This option is a member of the ipv4 class of options. -.sp -Force DNS resolution of following host names on the command line -to the IPv6 namespace. -.TP -.BR \-a ", " \--authreq -Require crypto authentication. -This option must not appear in combination with any of the following options: -authnoreq. -.sp -Require cryptographic authentication for broadcast client, -multicast client and symmetric passive associations. -This is the default. -.TP -.BR \-A ", " \--authnoreq -Do not require crypto authentication. -This option must not appear in combination with any of the following options: -authreq. -.sp -Do not require cryptographic authentication for broadcast client, -multicast client and symmetric passive associations. -This is almost never a good idea. -.TP -.BR \-b ", " \--bcastsync -Allow us to sync to broadcast servers. -.sp - -.TP -.BR \-B " \fIstring\fP, " \--simbroadcastdelay "=" \fIstring\fP -Simulator broadcast delay. -.sp - -.TP -.BR \-c " \fIstring\fP, " \--configfile "=" \fIstring\fP -configuration file name. -.sp -The name and path of the configuration file, -/etc/ntp.conf -by default. -.TP -.BR \-C " \fIstring\fP, " \--phasenoise "=" \fIstring\fP -Phase noise level. -.sp - -.TP -.BR \-d ", " \--debug-level -Increase output debug message level. -This option may appear an unlimited number of times. -.sp -Increase the debugging message output level. -.TP -.BR \-D " \fIstring\fP, " \--set-debug-level "=" \fIstring\fP -Set the output debug message level. -This option may appear an unlimited number of times. -.sp -Set the output debugging level. Can be supplied multiple times, -but each overrides the previous value(s). -.TP -.BR \-f " \fIstring\fP, " \--driftfile "=" \fIstring\fP -frequency drift file name. -.sp -The name and path of the frequency file, -/etc/ntp.drift -by default. -This is the same operation as the -driftfile driftfile -configuration specification in the -/etc/ntp.conf -file. -.TP -.BR \-g ", " \--panicgate -Allow the first adjustment to be Big. -.sp -Normally, -ntpd -exits with a message to the system log if the offset exceeds the panic threshold, which is 1000 s by default. This option allows the time to be set to any value without restriction; however, this can happen only once. If the threshold is exceeded after that, -ntpd -will exit with a message to the system log. This option can be used with the --q -and --x -options. -See the -tinker -configuration file directive for other options. -.TP -.BR \-H " \fIstring\fP, " \--simslew "=" \fIstring\fP -Simuator slew. -.sp - -.TP -.BR \-i " \fIstring\fP, " \--jaildir "=" \fIstring\fP -Jail directory. -.sp -Chroot the server to the directory -jaildir -. -This option also implies that the server attempts to drop root privileges at startup (otherwise, chroot gives very little additional security), and it is only available if the OS supports to run the server without full root privileges. -You may need to also specify a --u -option. -.TP -.BR \-I " \fIiface\fP, " \--interface "=" \fIiface\fP -Listen on interface. -This option may appear an unlimited number of times. -.sp - -.TP -.BR \-k " \fIstring\fP, " \--keyfile "=" \fIstring\fP -path to symmetric keys. -.sp -Specify the name and path of the symmetric key file. -/etc/ntp.keys -is the default. -This is the same operation as the -keys keyfile -configuration file directive. -.TP -.BR \-l " \fIstring\fP, " \--logfile "=" \fIstring\fP -path to the log file. -.sp -Specify the name and path of the log file. -The default is the system log file. -This is the same operation as the -logfile logfile -configuration file directive. -.TP -.BR \-L ", " \--novirtualips -Do not listen to virtual IPs. -.sp -Do not listen to virtual IPs. The default is to listen. -.TP -.BR \-M ", " \--modifymmtimer -Modify Multimedia Timer (Windows only). -.sp -Set the Windows Multimedia Timer to highest resolution. -.TP -.BR \-n ", " \--nofork -Do not fork. -.sp - -.TP -.BR \-N ", " \--nice -Run at high priority. -.sp -To the extent permitted by the operating system, run -ntpd -at the highest priority. -.TP -.BR \-O " \fIstring\fP, " \--servertime "=" \fIstring\fP -Server time. -.sp - -.TP -.BR \-p " \fIstring\fP, " \--pidfile "=" \fIstring\fP -path to the PID file. -.sp -Specify the name and path of the file used to record -ntpd's -process ID. -This is the same operation as the -pidfile pidfile -configuration file directive. -.TP -.BR \-P " \fInumber\fP, " \--priority "=" \fInumber\fP -Process priority. -This option takes an integer number as its argument. -.sp -To the extent permitted by the operating system, run -ntpd -at the specified -sched_setscheduler(SCHED_FIFO) -priority. -.TP -.BR \-q ", " \--quit -Set the time and quit. -.sp -ntpd -will exit just after the first time the clock is set. This behavior mimics that of the -ntpdate -program, which is to be retired. -The --g -and --x -options can be used with this option. -Note: The kernel time discipline is disabled with this option. -.TP -.BR \-r " \fIstring\fP, " \--propagationdelay "=" \fIstring\fP -Broadcast/propagation delay. -.sp -Specify the default propagation delay from the broadcast/multicast server to this client. This is necessary only if the delay cannot be computed automatically by the protocol. -.TP -.BR \-U " \fInumber\fP, " \--updateinterval "=" \fInumber\fP -interval in seconds between scans for new or dropped interfaces. -This option takes an integer number as its argument. -.sp -Give the time in seconds between two scans for new or dropped interfaces. -For systems with routing socket support the scans will be performed shortly after the interface change -has been detected by the system. -Use 0 to disable scanning. -.TP -.BR \-s " \fIstring\fP, " \--statsdir "=" \fIstring\fP -Statistics file location. -.sp -Specify the directory path for files created by the statistics facility. -This is the same operation as the -statsdir statsdir -configuration file directive. -.TP -.BR \-S " \fIstring\fP, " \--endsimtime "=" \fIstring\fP -Simulation end time. -.sp - -.TP -.BR \-t " \fItkey\fP, " \--trustedkey "=" \fItkey\fP -Trusted key number. -This option may appear an unlimited number of times. -.sp -Add a key number to the trusted key list. -.TP -.BR \-T " \fIstring\fP, " \--freqerr "=" \fIstring\fP -Simulation frequency error. -.sp - -.TP -.BR \-W " \fIstring\fP, " \--walknoise "=" \fIstring\fP -Simulation random walk noise. -.sp - -.TP -.BR \-u " \fIstring\fP, " \--user "=" \fIstring\fP -Run as userid (or userid:groupid). -.sp -Specify a user, and optionally a group, to switch to. -This option is only available if the OS supports to run the server without full root privileges. -Currently, this option is supported under NetBSD (configure with ---enable-clockctl -) and Linux (configure with ---enable-linuxcaps -). -.TP -.BR \-v " \fInvar\fP, " \--var "=" \fInvar\fP -make ARG an ntp variable (RW). -This option may appear an unlimited number of times. -.sp - -.TP -.BR \-V " \fIndvar\fP, " \--dvar "=" \fIndvar\fP -make ARG an ntp variable (RW|DEF). -This option may appear an unlimited number of times. -.sp - -.TP -.BR \-x ", " \--slew -Slew up to 600 seconds. -.sp -Normally, the time is slewed if the offset is less than the step threshold, which is 128 ms by default, and stepped if above the threshold. -This option sets the threshold to 600 s, which is well within the accuracy window to set the clock manually. -Note: Since the slew rate of typical Unix kernels is limited to 0.5 ms/s, each second of adjustment requires an amortization interval of 2000 s. -Thus, an adjustment as much as 600 s will take almost 14 days to complete. -This option can be used with the --g -and --q -options. -See the -tinker -configuration file directive for other options. -Note: The kernel time discipline is disabled with this option. -.TP -.BR \-Y " \fIstring\fP, " \--ndelay "=" \fIstring\fP -Simulation network delay. -.sp - -.TP -.BR \-Z " \fIstring\fP, " \--pdelay "=" \fIstring\fP -Simulation processing delay. -.sp - -.TP -.BR \-? , " \--help" -Display usage information and exit. -.TP -.BR \-! , " \--more-help" -Extended usage information passed thru pager. -.TP -.BR \-> " [\fIrcfile\fP]," " \--save-opts" "[=\fIrcfile\fP]" -Save the option state to \fIrcfile\fP. The default is the \fIlast\fP -configuration file listed in the \fBOPTION PRESETS\fP section, below. -.TP -.BR \-< " \fIrcfile\fP," " \--load-opts" "=\fIrcfile\fP," " \--no-load-opts" -Load options from \fIrcfile\fP. -The \fIno-load-opts\fP form will disable the loading -of earlier RC/INI files. \fI--no-load-opts\fP is handled early, -out of order. -.TP -.BR \-v " [{\fIv|c|n\fP}]," " \--version" "[=\fI{v|c|n}\fP]" -Output version of program and exit. The default mode is `v', a simple -version. The `c' mode will print copyright information and `n' will -print the full copyright notice. -.SH OPTION PRESETS -Any option that is not marked as \fInot presettable\fP may be preset -by loading values from configuration ("RC" or ".INI") file(s) and values from -environment variables named: -.nf - \fBNTPDSIM_\fP or \fBNTPDSIM\fP -.fi -.aj -The environmental presets take precedence (are processed later than) -the configuration files. -The \fIhomerc\fP files are "\fI$HOME\fP", and "\fI.\fP". -If any of these are directories, then the file \fI.ntprc\fP -is searched for within those directories. -.SH AUTHOR -David L. Mills and/or others -.br -Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org - -.PP -.nf -.na -see html/copyright.html -.fi -.ad -.PP -This manual page was \fIAutoGen\fP-erated from the \fBntpdsim\fP -option definitions. diff -urN src/contrib/ntp/ntpd/ntpsim.c src.ntp/contrib/ntp/ntpd/ntpsim.c --- src/contrib/ntp/ntpd/ntpsim.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/ntpsim.c 2009-12-09 08:36:35.000000000 +0100 @@ -1,371 +1,604 @@ -/* - * NTP simulator engine - Harish Nair - * University of Delaware, 2001 +/* ntpdsim.c + * + * The source code for the ntp discrete event simulator. + * + * Written By: Sachin Kamboj + * University of Delaware + * Newark, DE 19711 + * Copyright (c) 2006 + * (Some code shamelessly based on the original NTP discrete event simulator) */ + +#ifdef SIM #include "ntpd.h" #include "ntpsim.h" -#include "ntpdsim-opts.h" - -/* - * Defines... - */ -#define SIM_TIME 86400 /* end simulation time */ -#define NET_DLY .001 /* network delay */ -#define PROC_DLY .001 /* processing delay */ -#define BEEP_DLY 3600 /* beep interval (s) */ -#define SLEW 500e-6 /* correction rate (PPM) */ - -/* - * Function pointers - */ -void (*funcPtr[]) (Node *, Event) = { - &ndbeep, &ndeclk, &ntptmr, &netpkt -}; - +#include "ntp_data_structures.h" -/* - * ntpsim - initialize global variables and event queue and start - */ -int -ntpsim( - int argc, - char *argv[] - ) -{ - Event e; - double maxtime; - struct timeval seed; - - /* - * Initialize the global node - */ - ntp_node.time = 0; /* simulation time */ - ntp_node.sim_time = SIM_TIME; /* end simulation time (-S) */ - ntp_node.ntp_time = 0; /* client disciplined time */ - ntp_node.adj = 0; /* remaining time correction */ - ntp_node.slew = SLEW; /* correction rate (-H) */ - - ntp_node.clk_time = 0; /* server time (-O) */ - ntp_node.ferr = 0; /* frequency error (-T) */ - ntp_node.fnse = 0; /* random walk noise (-W) */ - ntp_node.ndly = NET_DLY; /* network delay (-Y) */ - ntp_node.snse = 0; /* phase noise (-C) */ - ntp_node.pdly = PROC_DLY; /* processing delay (-Z) */ - ntp_node.bdly = BEEP_DLY; /* beep interval (-B) */ - - ntp_node.events = NULL; - ntp_node.rbuflist = NULL; - - /* - * Initialize ntp variables - */ - initializing = 1; - init_auth(); - init_util(); - init_restrict(); - init_mon(); - init_timer(); - init_lib(); - init_request(); - init_control(); - init_peer(); - init_proto(); - init_io(); - init_loopfilter(); - mon_start(MON_OFF); - - { - int optct = optionProcess(&ntpdsimOptions, argc, argv); - argc -= optct; - argv += optct; - } - getconfig(argc, argv); +/* Global Variable Definitions */ - initializing = 0; - loop_config(LOOP_DRIFTCOMP, old_drift / 1e6); +sim_info simulation; /* Simulation Control Variables */ +local_clock_info simclock; /* Local Clock Variables */ +queue *event_queue; /* Event Queue */ +queue *recv_queue; /* Receive Queue */ +static double sys_residual = 0; /* adjustment residue (s) */ - /* - * Watch out here, we want the real time, not the silly stuff. - */ - gettimeofday(&seed, NULL); - ntp_srandom(seed.tv_usec); +void (*event_ptr[]) (Event *) = { + sim_event_beep, sim_update_clocks, sim_event_timer, sim_event_recv_packet +}; /* Function pointer to the events */ - /* - * Push a beep and timer interrupt on the queue - */ - push(event(0, BEEP), &ntp_node.events); - push(event(ntp_node.time + 1.0, TIMER), &ntp_node.events); - /* - * Pop the queue until nothing is left or time is exceeded - */ - maxtime = ntp_node.time + ntp_node.sim_time; - while (ntp_node.time <= maxtime && ntp_node.events != NULL ) { - e = pop(&ntp_node.events); - ndeclk(&ntp_node, e); - funcPtr[e.function](&ntp_node, e); - } - return (0); -} +/* Define a function to compare two events to determine which one occurs first + */ +int determine_event_ordering(Event *e1, Event *e2); -/* - * Return an event - */ -Event -event( - double t, - funcTkn f - ) -{ - Event e; - - e.time = t; - e.function = f; - return (e); +int determine_event_ordering(Event *e1, Event *e2) +{ + return (e1->time - e2->time); } -/* - * Create an event queue +/* Define a function to compare two received packets to determine which one + * is received first */ -Queue -queue( - Event e, - Queue q - ) -{ - Queue ret; - - if ((ret = (Queue)malloc(sizeof(struct List))) == NULL) - abortsim("queue-malloc"); - ret->event = e; - ret->next = q; - return (ret); -} +int determine_recv_buf_ordering(struct recvbuf *b1, struct recvbuf *b2); +int determine_recv_buf_ordering(struct recvbuf *b1, struct recvbuf *b2) +{ + double recv_time1, recv_time2; -/* - * Push an event into the event queue - */ -void push( - Event e, - Queue *qp - ) -{ - Queue *tmp = qp; - - while (*tmp != NULL && ((*tmp)->event.time < e.time)) - tmp = &((*tmp)->next); - *tmp = queue(e, (*tmp)); + /* Simply convert the time received to double and subtract */ + LFPTOD(&b1->recv_time, recv_time1); + LFPTOD(&b2->recv_time, recv_time2); + return ((int)(recv_time1 - recv_time2)); } - -/* - * Pop the first event from the event queue - */ -Event -pop( - Queue *qp - ) -{ - Event ret; - Queue tmp; - - tmp = *qp; - if (tmp == NULL) - abortsim("pop - empty queue"); - ret = tmp->event; - *qp = tmp->next; - free(tmp); - return (ret); +/* Define a function to create the server associations */ +void create_server_associations() +{ + int i; + for (i = 0;i < simulation.num_of_servers;++i) { + printf("%s\n", stoa(simulation.servers[i].addr)); + if (peer_config(simulation.servers[i].addr, + ANY_INTERFACE_CHOOSE(simulation.servers[i].addr), + MODE_CLIENT, + NTP_VERSION, + NTP_MINDPOLL, + NTP_MAXDPOLL, + 0, /* peerflags */ + 0, /* ttl */ + 0, /* peerkey */ + (u_char *)"*" /* peerkeystr */) == 0) { + fprintf(stderr, "ERROR!! Could not create association for: %s", + stoa(simulation.servers[i].addr)); + } + } } -/* - * Update clocks - */ -void -ndeclk( - Node *n, - Event e - ) -{ - node_clock(n, e.time); -} +/* Main Simulator Code */ +int ntpsim(int argc, char *argv[]) +{ + Event *curr_event; + struct timeval seed; + + /* Initialize the local Clock + */ + simclock.local_time = 0; + simclock.adj = 0; + simclock.slew = 0; + + /* Initialize the simulation + */ + simulation.num_of_servers = 0; + simulation.beep_delay = BEEP_DLY; + simulation.sim_time = 0; + simulation.end_time = SIM_TIME; + + /* + * Initialize ntp variables + */ + initializing = 1; + init_auth(); + init_util(); + init_restrict(); + init_mon(); + init_timer(); + init_lib(); + init_request(); + init_control(); + init_peer(); + init_proto(); + init_io(); + init_loopfilter(); + mon_start(MON_OFF); + + /* Call getconfig to parse the configuration file */ + getconfig(argc, argv); + initializing = 0; + loop_config(LOOP_DRIFTCOMP, old_drift / 1e6); + + /* + * Watch out here, we want the real time, not the silly stuff. + */ + gettimeofday(&seed, NULL); + ntp_srandom(seed.tv_usec); + + + /* Initialize the event queue */ + event_queue = create_priority_queue((int(*)(void *, void*)) + determine_event_ordering); + + /* Initialize the receive queue */ + recv_queue = create_priority_queue((int(*)(void *, void*)) + determine_recv_buf_ordering); + + /* Push a beep and a timer on the event queue */ + enqueue(event_queue, event(0, BEEP)); + enqueue(event_queue, event(simulation.sim_time + 1.0, TIMER)); + /* + * Pop the queue until nothing is left or time is exceeded + */ + /* maxtime = simulation.sim_time + simulation.end_time;*/ + while (simulation.sim_time <= simulation.end_time && + (!empty(event_queue))) { + curr_event = dequeue(event_queue); + /* Update all the clocks to the time on the event */ + sim_update_clocks(curr_event); + + /* Execute the function associated with the event */ + event_ptr[curr_event->function](curr_event); + free_node(curr_event); + } + return (0); +} + + + +/* Define a function to create an return an Event */ + +Event *event(double t, funcTkn f) +{ + Event *e; + + if ((e = get_node(sizeof(*e))) == NULL) + abortsim("get_node failed in event"); + e->time = t; + e->function = f; + return (e); +} + +/* NTP SIMULATION FUNCTIONS */ + +/* Define a function for processing a timer interrupt. + * On every timer interrupt, call the NTP timer to send packets and process + * the clock and then call the receive function to receive packets. + */ +void sim_event_timer(Event *e) +{ + struct recvbuf *rbuf; + + /* Call the NTP timer. + * This will be responsible for actually "sending the packets." + * Since this is a simulation, the packets sent over the network + * will be processed by the simulate_server routine below. + */ + timer(); + + /* Process received buffers */ + while (!empty(recv_queue)) { + rbuf = (struct recvbuf *)dequeue(recv_queue); + (rbuf->receiver)(rbuf); + free_node(rbuf); + } + + /* Arm the next timer interrupt. */ + enqueue(event_queue, + event(simulation.sim_time + (1 << EVENT_TIMEOUT), TIMER)); +} + + + +/* Define a function to simulate a server. + * This function processes the sent packet according to the server script, + * creates a reply packet and pushes the reply packet onto the event queue + */ +int simulate_server( + sockaddr_u *serv_addr, /* Address of the server */ + struct interface *inter, /* Interface on which the reply should + be inserted */ + struct pkt *rpkt /* Packet sent to the server that + needs to be processed. */ +) +{ + struct pkt xpkt; /* Packet to be transmitted back + to the client */ + struct recvbuf rbuf; /* Buffer for the received packet */ + Event *e; /* Packet receive event */ + server_info *server; /* Pointer to the server being simulated */ + script_info *curr_script; /* Current script being processed */ + int i; + double d1, d2, d3; /* Delays while the packet is enroute */ + double t1, t2, t3, t4; /* The four timestamps in the packet */ + + memset(&xpkt, 0, sizeof(xpkt)); + memset(&rbuf, 0, sizeof(rbuf)); + + /* Search for the server with the desired address */ + server = NULL; + for (i = 0; i < simulation.num_of_servers; ++i) { + fprintf(stderr,"Checking address: %s\n", stoa(simulation.servers[i].addr)); + if (memcmp(simulation.servers[i].addr, serv_addr, + sizeof(*serv_addr)) == 0) { + server = &simulation.servers[i]; + break; + } + } -/* - * Timer interrupt. Eventually, this results in calling the - * srvr_rplyi() routine below. - */ -void -ntptmr( - Node *n, - Event e - ) -{ - struct recvbuf *rbuf; - - timer(); - - /* - * Process buffers received. They had better be in order by - * receive timestamp. Note that there are no additional buffers - * in the current implementation of ntpsim. - */ - while (n->rbuflist != NULL) { - rbuf = n->rbuflist; - n->rbuflist = NULL; - (rbuf->receiver)(rbuf); - free(rbuf); + fprintf(stderr, "Received packet for: %s\n", stoa(serv_addr)); + if (server == NULL) + abortsim("Server with specified address not found!!!"); + + /* Get the current script for the server */ + curr_script = server->curr_script; + + /* Create a server reply packet. + * Masquerade the reply as a stratum-1 server with a GPS clock + */ + xpkt.li_vn_mode = PKT_LI_VN_MODE(LEAP_NOWARNING, NTP_VERSION, + MODE_SERVER); + xpkt.stratum = STRATUM_TO_PKT(((u_char)1)); + memcpy(&xpkt.refid, "GPS", 4); + xpkt.ppoll = rpkt->ppoll; + xpkt.precision = rpkt->precision; + xpkt.rootdelay = 0; + xpkt.rootdisp = 0; + + /* TIMESTAMP CALCULATIONS + t1 t4 + \ / + d1 \ / d3 + \ / + t2 ----------------- t3 + d2 + */ + /* Compute the delays */ + d1 = poisson(curr_script->prop_delay, curr_script->jitter); + d2 = poisson(curr_script->proc_delay, 0); + d3 = poisson(curr_script->prop_delay, curr_script->jitter); + + /* Note: In the transmitted packet: + * 1. t1 and t4 are times in the client according to the local clock. + * 2. t2 and t3 are server times according to the simulated server. + * Compute t1, t2, t3 and t4 + * Note: This function is called at time t1. + */ + + LFPTOD(&rpkt->xmt, t1); + t2 = server->server_time + d1; + t3 = server->server_time + d1 + d2; + t4 = t1 + d1 + d2 + d3; + + /* Save the timestamps */ + xpkt.org = rpkt->xmt; + DTOLFP(t2, &xpkt.rec); + DTOLFP(t3, &xpkt.xmt); + xpkt.reftime = xpkt.xmt; + + + + /* Ok, we are done with the packet. Now initialize the receive buffer for + * the packet. + */ + rbuf.receiver = receive; /* Function to call to process the packet */ + rbuf.recv_length = LEN_PKT_NOMAC; + rbuf.recv_pkt = xpkt; + rbuf.used = 1; + + memcpy(&rbuf.srcadr, serv_addr, sizeof(rbuf.srcadr)); + memcpy(&rbuf.recv_srcadr, serv_addr, sizeof(rbuf.recv_srcadr)); + if ((rbuf.dstadr = malloc(sizeof(*rbuf.dstadr))) == NULL) + abortsim("malloc failed in simulate_server"); + memcpy(rbuf.dstadr, inter, sizeof(*rbuf.dstadr)); + /* rbuf.link = NULL; */ + + /* Create a packet event and insert it onto the event_queue at the + * arrival time (t4) of the packet at the client + */ + e = event(t4, PACKET); + e->rcv_buf = rbuf; + enqueue(event_queue, e); + + + /* Check if the time of the script has expired. If yes, delete the script. + * If not, re-enqueue the script onto the server script queue + */ + if (curr_script->duration > simulation.sim_time && + !empty(server->script)) { + printf("Hello\n"); + /* + * For some reason freeing up the curr_script memory kills the + * simulation. Further debugging is needed to determine why. + * free_node(curr_script); + */ + curr_script = dequeue(server->script); + } + + return (0); +} + + +/* Define a function to update all the clocks + * Most of the code is modified from the systime.c file by Prof. Mills + */ + +void sim_update_clocks (Event *e) +{ + double time_gap; + double adj; + int i; + + /* Compute the time between the last update event and this update */ + time_gap = e->time - simulation.sim_time; + + /* Advance the client clock */ + simclock.local_time = e->time + time_gap; + + /* Advance the simulation time */ + simulation.sim_time = e->time; + + /* Advance the server clocks adjusted for systematic and random frequency + * errors. The random error is a random walk computed as the + * integral of samples from a Gaussian distribution. + */ + for (i = 0;i < simulation.num_of_servers; ++i) { + simulation.servers[i].curr_script->freq_offset += + gauss(0, time_gap * simulation.servers[i].curr_script->wander); + + simulation.servers[i].server_time += time_gap * + (1 + simulation.servers[i].curr_script->freq_offset); + } + + + /* Perform the adjtime() function. If the adjustment completed + * in the previous interval, amortize the entire amount; if not, + * carry the leftover to the next interval. + */ + + adj = time_gap * simclock.slew; + if (adj < fabs(simclock.adj)) { + if (simclock.adj < 0) { + simclock.adj += adj; + simclock.local_time -= adj; + } + else { + simclock.adj -= adj; + simclock.local_time += adj; + } + } + else { + simclock.local_time += simclock.adj; + simclock.adj = 0; + } +} + + +/* Define a function that processes a receive packet event. + * This function simply inserts the packet received onto the receive queue + */ + +void sim_event_recv_packet(Event *e) +{ + struct recvbuf *rbuf; + + /* Allocate a receive buffer and copy the packet to it */ + if ((rbuf = get_node(sizeof(*rbuf))) == NULL) + abortsim("get_node failed in sim_event_recv_packet"); + memcpy(rbuf, &e->rcv_buf, sizeof(*rbuf)); + + /* Store the local time in the received packet */ + DTOLFP(simclock.local_time, &rbuf->recv_time); + + /* Insert the packet received onto the receive queue */ + enqueue(recv_queue, rbuf); +} + + + +/* Define a function to output simulation statistics on a beep event + */ + +/*** TODO: Need to decide on how to output for multiple servers ***/ +void sim_event_beep(Event *e) +{ +#if 0 + static int first_time = 1; + char *dash = "-----------------"; +#endif + + fprintf(stderr, "BEEP!!!\n"); + enqueue(event_queue, event(e->time + simulation.beep_delay, BEEP)); +#if 0 + if(simulation.beep_delay > 0) { + if (first_time) { + printf("\t%4c T %4c\t%4c T+ERR %3c\t%5cT+ERR+NTP\n", + ' ', ' ', ' ', ' ',' '); + printf("\t%s\t%s\t%s\n", dash, dash, dash); + first_time = 0; + + printf("\t%16.6f\t%16.6f\t%16.6f\n", + n->time, n->clk_time, n->ntp_time); + return; } + printf("\t%16.6f\t%16.6f\t%16.6f\n", + simclock.local_time, + n->time, n->clk_time, n->ntp_time); +#endif - /* - * Arm the next timer interrupt. - */ - push(event(e.time + (1 << EVENT_TIMEOUT), TIMER), &n->events); } -/* - * srvr_rply() - send packet +/* Define a function to abort the simulation on an error and spit out an + * error message */ -int srvr_rply( - Node *n, - struct sockaddr_storage *dest, - struct interface *inter, struct pkt *rpkt - ) -{ - struct pkt xpkt; - struct recvbuf rbuf; - Event xvnt; - double dtemp, etemp; - - /* - * Insert packet header values. We make this look like a - * stratum-1 server with a GPS clock, but nobody will ever - * notice that. - */ - xpkt.li_vn_mode = PKT_LI_VN_MODE(LEAP_NOWARNING, NTP_VERSION, - MODE_SERVER); - xpkt.stratum = STRATUM_TO_PKT(((u_char)1)); - memcpy(&xpkt.refid, "GPS", 4); - xpkt.ppoll = rpkt->ppoll; - xpkt.precision = rpkt->precision; - xpkt.rootdelay = 0; - xpkt.rootdispersion = 0; - /* - * Insert the timestamps. - */ - xpkt.org = rpkt->xmt; - dtemp = poisson(n->ndly, n->snse); /* client->server delay */ - DTOLFP(dtemp + n->clk_time, &xpkt.rec); - dtemp += poisson(n->pdly, 0); /* server delay */ - DTOLFP(dtemp + n->clk_time, &xpkt.xmt); - xpkt.reftime = xpkt.xmt; - dtemp += poisson(n->ndly, n->snse); /* server->client delay */ - - /* - * Insert the I/O stuff. - */ - rbuf.receiver = receive; - get_systime(&rbuf.recv_time); - rbuf.recv_length = LEN_PKT_NOMAC; - rbuf.recv_pkt = xpkt; - memcpy(&rbuf.srcadr, dest, sizeof(struct sockaddr_storage)); - memcpy(&rbuf.recv_srcadr, dest, - sizeof(struct sockaddr_storage)); - if ((rbuf.dstadr = malloc(sizeof(struct interface))) == NULL) - abortsim("server-malloc"); - memcpy(rbuf.dstadr, inter, sizeof(struct interface)); - - /* - * Very carefully predict the time of arrival for the received - * packet. - */ - LFPTOD(&xpkt.org, etemp); - etemp += dtemp; - xvnt = event(etemp, PACKET); - xvnt.rcv_buf = rbuf; - push(xvnt, &n->events); - return (0); +void abortsim(char *errmsg) +{ + perror(errmsg); + exit(1); } -/* - * netpkt() - receive packet - */ -void -netpkt( - Node *n, - Event e - ) -{ - struct recvbuf *rbuf; - struct recvbuf *obuf; - - /* - * Insert the packet on the receive queue and record the arrival - * time. - */ - if ((rbuf = malloc(sizeof(struct recvbuf))) == NULL) - abortsim("ntprcv-malloc"); - memcpy(rbuf, &e.rcv_buf, sizeof(struct recvbuf)); - rbuf->receiver = receive; - DTOLFP(n->ntp_time, &rbuf->recv_time); - obuf = n->rbuflist; - - /* - * In the present incarnation, no more than one buffer can be on - * the queue; - */ - if (obuf == NULL) { - n->rbuflist = rbuf; - } -} - -/* - * ndbeep() - progress indicator +/* CODE ORIGINALLY IN libntp/systime.c + * ----------------------------------- + * This code was a part of the original NTP simulator and originally + * had its home in the libntp/systime.c file. + * + * It has been shamelessly moved to here and has been modified for the + * purposes of the current simulator. */ -void -ndbeep( - Node *n, - Event e - ) -{ - static int first_time = 1; - char *dash = "-----------------"; - - if(n->bdly > 0) { - if (first_time) { - printf( - "\t%4c T %4c\t%4c T+ERR %3c\t%5cT+ERR+NTP\n", ' ', ' ', ' ', ' ',' '); - printf("\t%s\t%s\t%s\n", dash, dash, dash); - first_time = 0; - push(event(n->bdly, BEEP), &n->events); - push(event(n->sim_time, BEEP), &n->events); - printf("\t%16.6f\t%16.6f\t%16.6f\n", - n->time, n->clk_time, n->ntp_time); - return; - } - printf("\t%16.6f\t%16.6f\t%16.6f\n", - n->time, n->clk_time, n->ntp_time); - push(event(e.time + n->bdly, BEEP), &n->events); - } -} /* - * Abort simulation + * get_systime - return the system time in NTP timestamp format */ void -abortsim( - char *errmsg - ) +get_systime( + l_fp *now /* current system time in l_fp */ ) { - perror(errmsg); - exit(1); + /* + * To fool the code that determines the local clock precision, + * we advance the clock a minimum of 200 nanoseconds on every + * clock read. This is appropriate for a typical modern machine + * with nanosecond clocks. Note we make no attempt here to + * simulate reading error, since the error is so small. This may + * change when the need comes to implement picosecond clocks. + */ + if (simclock.local_time == simclock.last_read_time) + simclock.local_time += 200e-9; + + simclock.last_read_time = simclock.local_time; + DTOLFP(simclock.local_time, now); +/* OLD Code + if (ntp_node.ntp_time == ntp_node.last_time) + ntp_node.ntp_time += 200e-9; + ntp_node.last_time = ntp_node.ntp_time; + DTOLFP(ntp_node.ntp_time, now); +*/ +} + + +/* + * adj_systime - advance or retard the system clock exactly like the + * real thng. + */ +int /* always succeeds */ +adj_systime( + double now /* time adjustment (s) */ + ) +{ + struct timeval adjtv; /* new adjustment */ + double dtemp; + long ticks; + int isneg = 0; + + /* + * Most Unix adjtime() implementations adjust the system clock + * in microsecond quanta, but some adjust in 10-ms quanta. We + * carefully round the adjustment to the nearest quantum, then + * adjust in quanta and keep the residue for later. + */ + dtemp = now + sys_residual; + if (dtemp < 0) { + isneg = 1; + dtemp = -dtemp; + } + adjtv.tv_sec = (long)dtemp; + dtemp -= adjtv.tv_sec; + ticks = (long)(dtemp / sys_tick + .5); + adjtv.tv_usec = (long)(ticks * sys_tick * 1e6); + dtemp -= adjtv.tv_usec / 1e6; + sys_residual = dtemp; + + /* + * Convert to signed seconds and microseconds for the Unix + * adjtime() system call. Note we purposely lose the adjtime() + * leftover. + */ + if (isneg) { + adjtv.tv_sec = -adjtv.tv_sec; + adjtv.tv_usec = -adjtv.tv_usec; + sys_residual = -sys_residual; + } + simclock.adj = now; +/* ntp_node.adj = now; */ + return (1); +} + + +/* + * step_systime - step the system clock. We are religious here. + */ +int /* always succeeds */ +step_systime( + double now /* step adjustment (s) */ + ) +{ +#ifdef DEBUG + if (debug) + printf("step_systime: time %.6f adj %.6f\n", + simclock.local_time, now); +#endif + simclock.local_time += now; + return (1); +} + +/* + * gauss() - returns samples from a gaussion distribution + */ +double /* Gaussian sample */ +gauss( + double m, /* sample mean */ + double s /* sample standard deviation (sigma) */ + ) +{ + double q1, q2; + + /* + * Roll a sample from a Gaussian distribution with mean m and + * standard deviation s. For m = 0, s = 1, mean(y) = 0, + * std(y) = 1. + */ + if (s == 0) + return (m); + while ((q1 = drand48()) == 0); + q2 = drand48(); + return (m + s * sqrt(-2. * log(q1)) * cos(2. * PI * q2)); +} + + +/* + * poisson() - returns samples from a network delay distribution + */ +double /* delay sample (s) */ +poisson( + double m, /* fixed propagation delay (s) */ + double s /* exponential parameter (mu) */ + ) +{ + double q1; + + /* + * Roll a sample from a composite distribution with propagation + * delay m and exponential distribution time with parameter s. + * For m = 0, s = 1, mean(y) = std(y) = 1. + */ + if (s == 0) + return (m); + while ((q1 = drand48()) == 0); + return (m - s * log(q1 * s)); } + +#endif diff -urN src/contrib/ntp/ntpd/refclock_acts.c src.ntp/contrib/ntp/ntpd/refclock_acts.c --- src/contrib/ntp/ntpd/refclock_acts.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_acts.c 2010-07-07 12:01:06.000000000 +0200 @@ -136,6 +136,7 @@ #define REFID "NONE" /* default reference ID */ #define MSGCNT 20 /* max message count */ #define SMAX 256 /* max clockstats line length */ +#define MAXPHONE 10 /* max number of phone numbers */ /* * Calling program modes @@ -210,15 +211,15 @@ /* * Function prototypes */ -static int acts_start P((int, struct peer *)); -static void acts_shutdown P((int, struct peer *)); -static void acts_receive P((struct recvbuf *)); -static void acts_message P((struct peer *)); -static void acts_timecode P((struct peer *, char *)); -static void acts_poll P((int, struct peer *)); -static void acts_timeout P((struct peer *)); -static void acts_disc P((struct peer *)); -static void acts_timer P((int, struct peer *)); +static int acts_start (int, struct peer *); +static void acts_shutdown (int, struct peer *); +static void acts_receive (struct recvbuf *); +static void acts_message (struct peer *); +static void acts_timecode (struct peer *, char *); +static void acts_poll (int, struct peer *); +static void acts_timeout (struct peer *); +static void acts_disc (struct peer *); +static void acts_timer (int, struct peer *); /* * Transfer vector (conditional structure name) @@ -233,8 +234,6 @@ acts_timer /* housekeeping timer */ }; -struct refclock refclock_ptb; - /* * Initialize data for processing */ @@ -251,9 +250,6 @@ * Allocate and initialize unit structure */ up = emalloc(sizeof(struct actsunit)); - if (up == NULL) - return (0); - memset(up, 0, sizeof(struct actsunit)); up->unit = unit; pp = peer->procptr; @@ -269,7 +265,6 @@ pp->clockdesc = DESCRIPTION; memcpy((char *)&pp->refid, REFID, 4); peer->sstclktype = CTL_SST_TS_TELEPHONE; - peer->flags &= ~FLAG_FIXPOLL; up->bufptr = pp->a_lastcode; return (1); } @@ -362,21 +357,28 @@ /* * What to do depends on the state and the first token in the - * message. A NO token sends the message to the clockstats. - */ + * message. */ pp = peer->procptr; up = (struct actsunit *)pp->unitptr; #ifdef DEBUG ioctl(pp->io.fd, TIOCMGET, (char *)&modem); - sprintf(tbuf, "acts: %04x (%d %d) %lu %s", modem, up->state, - up->timer, strlen(pp->a_lastcode), pp->a_lastcode); + snprintf(tbuf, sizeof(tbuf), "acts: %04x (%d %d) %lu %s", modem, + up->state, up->timer, (u_long)strlen(pp->a_lastcode), + pp->a_lastcode); if (debug) printf("%s\n", tbuf); #endif + + /* + * Extract the first token in the line. A NO token sends the + * message to the clockstats. + */ strncpy(tbuf, pp->a_lastcode, SMAX); strtok(tbuf, " "); - if (strcmp(tbuf, "NO") == 0) - record_clock_stats(&peer->srcadr, pp->a_lastcode); + if (strcmp(tbuf, "NO") == 0) { + report_event(PEVNT_CLOCK, peer, pp->a_lastcode); + return; + } switch(up->state) { /* @@ -401,7 +403,7 @@ * here is token CONNECT. Send the message to the clockstats. */ case S_CONNECT: - record_clock_stats(&peer->srcadr, pp->a_lastcode); + report_event(PEVNT_CLOCK, peer, pp->a_lastcode); if (strcmp(tbuf, "CONNECT") != 0) { acts_disc(peer); return; @@ -616,10 +618,8 @@ if (!refclock_process(pp)) { refclock_report(peer, CEVNT_BADTIME); return; - } + } pp->lastref = pp->lastrec; - if (peer->disp > MAXDISTANCE) - refclock_receive(peer); if (up->state != S_MSG) { up->state = S_MSG; up->timer = TIMECODE; @@ -724,7 +724,7 @@ int fd; char device[20]; char lockfile[128], pidbuf[8]; - char tbuf[BMAX]; + char tbuf[SMAX]; /* * The state machine is driven by messages from the modem, when @@ -751,14 +751,16 @@ * file may not be removed. */ if (pp->sloppyclockflag & CLK_FLAG2) { - sprintf(lockfile, LOCKFILE, up->unit); + snprintf(lockfile, sizeof(lockfile), LOCKFILE, + up->unit); fd = open(lockfile, O_WRONLY | O_CREAT | O_EXCL, 0644); if (fd < 0) { msyslog(LOG_ERR, "acts: port busy"); return; } - sprintf(pidbuf, "%d\n", (u_int)getpid()); + snprintf(pidbuf, sizeof(pidbuf), "%d\n", + (u_int)getpid()); write(fd, pidbuf, strlen(pidbuf)); close(fd); } @@ -767,10 +769,13 @@ * Open the device in raw mode and link the I/O. */ if (!pp->io.fd) { - sprintf(device, DEVICE, up->unit); + snprintf(device, sizeof(device), DEVICE, + up->unit); fd = refclock_open(device, SPEED232, LDISC_ACTS | LDISC_RAW | LDISC_REMOTE); if (fd == 0) { + msyslog(LOG_ERR, + "acts: open fails"); return; } pp->io.fd = fd; @@ -825,9 +830,9 @@ * before hammering it with a dial command. */ case S_DTR: - sprintf(tbuf, "DIAL #%d %s", up->retry, + snprintf(tbuf, sizeof(tbuf), "DIAL #%d %s", up->retry, sys_phone[up->retry]); - record_clock_stats(&peer->srcadr, tbuf); + report_event(PEVNT_CLOCK, peer, tbuf); #ifdef DEBUG if (debug) printf("%s\n", tbuf); @@ -866,7 +871,8 @@ io_closeclock(&pp->io); close(pp->io.fd); if (pp->sloppyclockflag & CLK_FLAG2) { - sprintf(lockfile, LOCKFILE, up->unit); + snprintf(lockfile, sizeof(lockfile), + LOCKFILE, up->unit); unlink(lockfile); } pp->io.fd = 0; @@ -910,9 +916,9 @@ /* * We get here if the call terminated successfully or if an - * error occured. If the median filter has something in it,feed - * the data to the clock filter. If a modem port, drop DTR to - * force command mode and send modem hangup. + * error occured. If the median filter has something in it, + * feed the data to the clock filter. If a modem port, drop DTR + * to force command mode and send modem hangup. */ pp = peer->procptr; up = (struct actsunit *)pp->unitptr; @@ -925,7 +931,6 @@ up->timer = SETUP; up->state = S_CLOSE; } - #else int refclock_acts_bs; #endif /* REFCLOCK */ diff -urN src/contrib/ntp/ntpd/refclock_arbiter.c src.ntp/contrib/ntp/ntpd/refclock_arbiter.c --- src/contrib/ntp/ntpd/refclock_arbiter.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_arbiter.c 2010-02-04 08:26:53.000000000 +0100 @@ -111,10 +111,10 @@ /* * Function prototypes */ -static int arb_start P((int, struct peer *)); -static void arb_shutdown P((int, struct peer *)); -static void arb_receive P((struct recvbuf *)); -static void arb_poll P((int, struct peer *)); +static int arb_start (int, struct peer *); +static void arb_shutdown (int, struct peer *); +static void arb_receive (struct recvbuf *); +static void arb_poll (int, struct peer *); /* * Transfer vector @@ -147,25 +147,23 @@ /* * Open serial port. Use CLK line discipline, if available. */ - (void)sprintf(device, DEVICE, unit); + snprintf(device, sizeof(device), DEVICE, unit); if (!(fd = refclock_open(device, SPEED232, LDISC_CLK))) return (0); /* * Allocate and initialize unit structure */ - if (!(up = (struct arbunit *)emalloc(sizeof(struct arbunit)))) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct arbunit)); + up = emalloc(sizeof(*up)); + memset(up, 0, sizeof(*up)); pp = peer->procptr; pp->io.clock_recv = arb_receive; pp->io.srcclock = (caddr_t)peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + close(fd); + pp->io.fd = -1; free(up); return (0); } @@ -196,8 +194,10 @@ pp = peer->procptr; up = (struct arbunit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } diff -urN src/contrib/ntp/ntpd/refclock_arc.c src.ntp/contrib/ntp/ntpd/refclock_arc.c --- src/contrib/ntp/ntpd/refclock_arc.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_arc.c 2010-02-04 08:26:56.000000000 +0100 @@ -138,27 +138,27 @@ 2) PRECISION should be -4/-5 (63ms/31ms) for the following reasons: a) The ARC documentation claims the internal clock is (only) - accurate to about 20ms relative to Rugby (plus there must be - noticable drift and delay in the ms range due to transmission - delays and changing atmospheric effects). This clock is not - designed for ms accuracy as NTP has spoilt us all to expect. + accurate to about 20ms relative to Rugby (plus there must be + noticable drift and delay in the ms range due to transmission + delays and changing atmospheric effects). This clock is not + designed for ms accuracy as NTP has spoilt us all to expect. b) The clock oscillator looks like a simple uncompensated quartz - crystal of the sort used in digital watches (ie 32768Hz) which - can have large temperature coefficients and drifts; it is not - clear if this oscillator is properly disciplined to the MSF - transmission, but as the default is to resync only once per - *day*, we can imagine that it is not, and is free-running. We - can minimise drift by resyncing more often (at the cost of - reduced battery life), but drift/wander may still be - significant. + crystal of the sort used in digital watches (ie 32768Hz) which + can have large temperature coefficients and drifts; it is not + clear if this oscillator is properly disciplined to the MSF + transmission, but as the default is to resync only once per + *day*, we can imagine that it is not, and is free-running. We + can minimise drift by resyncing more often (at the cost of + reduced battery life), but drift/wander may still be + significant. c) Note that the bit time of 3.3ms adds to the potential error in - the the clock timestamp, since the bit clock of the serial link - may effectively be free-running with respect to the host clock - and the MSF clock. Actually, the error is probably 1/16th of - the above, since the input data is probably sampled at at least - 16x the bit rate. + the the clock timestamp, since the bit clock of the serial link + may effectively be free-running with respect to the host clock + and the MSF clock. Actually, the error is probably 1/16th of + the above, since the input data is probably sampled at at least + 16x the bit rate. By keeping the clock marked as not very precise, it will have a fairly large dispersion, and thus will tend to be used as a @@ -178,9 +178,9 @@ IN ANY CASE, BE SURE TO SET AN APPROPRIATE FUDGE FACTOR TO REMOVE ANY RESIDUAL SKEW, eg: - server 127.127.27.0 # ARCRON MSF radio clock unit 0. - # Fudge timestamps by about 20ms. - fudge 127.127.27.0 time1 0.020 + server 127.127.27.0 # ARCRON MSF radio clock unit 0. + # Fudge timestamps by about 20ms. + fudge 127.127.27.0 time1 0.020 You will need to observe your system's behaviour, assuming you have some other NTP source to compare it with, to work out what the @@ -317,28 +317,28 @@ /* 12. year tens */ /* 13. year units */ /* 14. BST/UTC status */ -/* bit 7 parity */ -/* bit 6 always 0 */ -/* bit 5 always 1 */ -/* bit 4 always 1 */ -/* bit 3 always 0 */ -/* bit 2 =1 if UTC is in effect, complementary to the BST bit */ -/* bit 1 =1 if BST is in effect, according to the BST bit */ -/* bit 0 BST/UTC change impending bit=1 in case of change impending */ +/* bit 7 parity */ +/* bit 6 always 0 */ +/* bit 5 always 1 */ +/* bit 4 always 1 */ +/* bit 3 always 0 */ +/* bit 2 =1 if UTC is in effect, complementary to the BST bit */ +/* bit 1 =1 if BST is in effect, according to the BST bit */ +/* bit 0 BST/UTC change impending bit=1 in case of change impending */ /* 15. status */ -/* bit 7 parity */ -/* bit 6 always 0 */ -/* bit 5 always 1 */ -/* bit 4 always 1 */ -/* bit 3 =1 if low battery is detected */ -/* bit 2 =1 if the very last reception attempt failed and a valid */ -/* time information already exists (bit0=1) */ -/* =0 if the last reception attempt was successful */ -/* bit 1 =1 if at least one reception since 2:30 am was successful */ -/* =0 if no reception attempt since 2:30 am was successful */ -/* bit 0 =1 if the RC Computer Clock contains valid time information */ -/* This bit is zero after reset and one after the first */ -/* successful reception attempt */ +/* bit 7 parity */ +/* bit 6 always 0 */ +/* bit 5 always 1 */ +/* bit 4 always 1 */ +/* bit 3 =1 if low battery is detected */ +/* bit 2 =1 if the very last reception attempt failed and a valid */ +/* time information already exists (bit0=1) */ +/* =0 if the last reception attempt was successful */ +/* bit 1 =1 if at least one reception since 2:30 am was successful */ +/* =0 if no reception attempt since 2:30 am was successful */ +/* bit 0 =1 if the RC Computer Clock contains valid time information */ +/* This bit is zero after reset and one after the first */ +/* successful reception attempt */ /* DHD note: Also note g command which confirms that a resync is in progress, and @@ -375,15 +375,15 @@ /* * Interface definitions */ -#define DEVICE "/dev/arc%d" /* Device name and unit. */ -#define SPEED B300 /* UART speed (300 baud) */ -#define PRECISION (-4) /* Precision (~63 ms). */ -#define HIGHPRECISION (-5) /* If things are going well... */ -#define REFID "MSFa" /* Reference ID. */ -#define REFID_MSF "MSF" /* Reference ID. */ -#define REFID_DCF77 "DCF" /* Reference ID. */ -#define REFID_WWVB "WWVB" /* Reference ID. */ -#define DESCRIPTION "ARCRON MSF/DCF/WWVB Receiver" +#define DEVICE "/dev/arc%d" /* Device name and unit. */ +#define SPEED B300 /* UART speed (300 baud) */ +#define PRECISION (-4) /* Precision (~63 ms). */ +#define HIGHPRECISION (-5) /* If things are going well... */ +#define REFID "MSFa" /* Reference ID. */ +#define REFID_MSF "MSF" /* Reference ID. */ +#define REFID_DCF77 "DCF" /* Reference ID. */ +#define REFID_WWVB "WWVB" /* Reference ID. */ +#define DESCRIPTION "ARCRON MSF/DCF/WWVB Receiver" #ifdef PRE_NTP420 #define MODE ttlmax @@ -391,13 +391,13 @@ #define MODE ttl #endif -#define LENARC 16 /* Format `o' timecode length. */ +#define LENARC 16 /* Format `o' timecode length. */ -#define BITSPERCHAR 11 /* Bits per character. */ -#define BITTIME 0x0DA740E /* Time for 1 bit at 300bps. */ -#define CHARTIME10 0x8888888 /* Time for 10-bit char at 300bps. */ -#define CHARTIME11 0x962FC96 /* Time for 11-bit char at 300bps. */ -#define CHARTIME /* Time for char at 300bps. */ \ +#define BITSPERCHAR 11 /* Bits per character. */ +#define BITTIME 0x0DA740E /* Time for 1 bit at 300bps. */ +#define CHARTIME10 0x8888888 /* Time for 10-bit char at 300bps. */ +#define CHARTIME11 0x962FC96 /* Time for 11-bit char at 300bps. */ +#define CHARTIME /* Time for char at 300bps. */ \ ( (BITSPERCHAR == 11) ? CHARTIME11 : ( (BITSPERCHAR == 10) ? CHARTIME10 : \ (BITSPERCHAR * BITTIME) ) ) @@ -457,12 +457,12 @@ #endif }; -#define DEFAULT_RESYNC_TIME (57*60) /* Gap between resync attempts (s). */ -#define RETRY_RESYNC_TIME (27*60) /* Gap to emergency resync attempt. */ +#define DEFAULT_RESYNC_TIME (57*60) /* Gap between resync attempts (s). */ +#define RETRY_RESYNC_TIME (27*60) /* Gap to emergency resync attempt. */ #ifdef ARCRON_KEEN -#define INITIAL_RESYNC_DELAY 500 /* Delay before first resync. */ +#define INITIAL_RESYNC_DELAY 500 /* Delay before first resync. */ #else -#define INITIAL_RESYNC_DELAY 50 /* Delay before first resync. */ +#define INITIAL_RESYNC_DELAY 50 /* Delay before first resync. */ #endif static const int moff[12] = @@ -470,30 +470,30 @@ /* Flags for a raw open() of the clock serial device. */ #ifdef O_NOCTTY /* Good, we can avoid tty becoming controlling tty. */ #define OPEN_FLAGS (O_RDWR | O_NOCTTY) -#else /* Oh well, it may not matter... */ +#else /* Oh well, it may not matter... */ #define OPEN_FLAGS (O_RDWR) #endif /* Length of queue of command bytes to be sent. */ -#define CMDQUEUELEN 4 /* Enough for two cmds + each \r. */ +#define CMDQUEUELEN 4 /* Enough for two cmds + each \r. */ /* Queue tick time; interval in seconds between chars taken off queue. */ /* Must be >= 2 to allow o\r response to come back uninterrupted. */ -#define QUEUETICK 2 /* Allow o\r reply to finish. */ +#define QUEUETICK 2 /* Allow o\r reply to finish. */ /* * ARC unit control structure */ struct arcunit { - l_fp lastrec; /* Time tag for the receive time (system). */ - int status; /* Clock status. */ + l_fp lastrec; /* Time tag for the receive time (system). */ + int status; /* Clock status. */ - int quality; /* Quality of reception 0--5 for unit. */ + int quality; /* Quality of reception 0--5 for unit. */ /* We may also use the values -1 or 6 internally. */ u_long quality_stamp; /* Next time to reset quality average. */ u_long next_resync; /* Next resync time (s) compared to current_time. */ - int resyncing; /* Resync in progress if true. */ + int resyncing; /* Resync in progress if true. */ /* In the outgoing queue, cmdqueue[0] is next to be sent. */ char cmdqueue[CMDQUEUELEN+1]; /* Queue of outgoing commands + \0. */ @@ -527,11 +527,11 @@ #endif #if 0 -static void dummy_event_handler P((struct peer *)); -static void arc_event_handler P((struct peer *)); +static void dummy_event_handler (struct peer *); +static void arc_event_handler (struct peer *); #endif /* 0 */ -#define QUALITY_UNKNOWN -1 /* Indicates unknown clock quality. */ +#define QUALITY_UNKNOWN -1 /* Indicates unknown clock quality. */ #define MIN_CLOCK_QUALITY 0 /* Min quality clock will return. */ #define MIN_CLOCK_QUALITY_OK 3 /* Min quality for OK reception. */ #define MAX_CLOCK_QUALITY 5 /* Max quality clock will return. */ @@ -539,22 +539,22 @@ /* * Function prototypes */ -static int arc_start P((int, struct peer *)); -static void arc_shutdown P((int, struct peer *)); -static void arc_receive P((struct recvbuf *)); -static void arc_poll P((int, struct peer *)); +static int arc_start (int, struct peer *); +static void arc_shutdown (int, struct peer *); +static void arc_receive (struct recvbuf *); +static void arc_poll (int, struct peer *); /* * Transfer vector */ struct refclock refclock_arc = { - arc_start, /* start up driver */ - arc_shutdown, /* shut down driver */ - arc_poll, /* transmit poll message */ - noentry, /* not used (old arc_control) */ - noentry, /* initialize driver (not used) */ - noentry, /* not used (old arc_buginfo) */ - NOFLAGS /* not used */ + arc_start, /* start up driver */ + arc_shutdown, /* shut down driver */ + arc_poll, /* transmit poll message */ + noentry, /* not used (old arc_control) */ + noentry, /* initialize driver (not used) */ + noentry, /* not used (old arc_buginfo) */ + NOFLAGS /* not used */ }; /* Queue us up for the next tick. */ @@ -646,21 +646,23 @@ /* * Open serial port. Use CLK line discipline, if available. */ - (void)sprintf(device, DEVICE, unit); + snprintf(device, sizeof(device), DEVICE, unit); if (!(fd = refclock_open(device, SPEED, LDISC_CLK))) return(0); #ifdef DEBUG if(debug) { printf("arc: unit %d using open().\n", unit); } #endif - fd = open(device, OPEN_FLAGS); + fd = tty_open(device, OPEN_FLAGS, 0777); if(fd < 0) { #ifdef DEBUG - if(debug) { printf("arc: failed [open()] to open %s.\n", device); } + if(debug) { printf("arc: failed [tty_open()] to open %s.\n", device); } #endif return(0); } +#ifndef SYS_WINNT fcntl(fd, F_SETFL, 0); /* clear the descriptor flags */ +#endif #ifdef DEBUG if(debug) { printf("arc: opened RS232 port with file descriptor %d.\n", fd); } @@ -688,16 +690,20 @@ #endif - up = (struct arcunit *) emalloc(sizeof(struct arcunit)); - if(!up) { (void) close(fd); return(0); } + up = emalloc(sizeof(*up)); /* Set structure to all zeros... */ - memset((char *)up, 0, sizeof(struct arcunit)); + memset(up, 0, sizeof(*up)); pp = peer->procptr; pp->io.clock_recv = arc_receive; pp->io.srcclock = (caddr_t)peer; pp->io.datalen = 0; pp->io.fd = fd; - if(!io_addclock(&pp->io)) { (void) close(fd); free(up); return(0); } + if (!io_addclock(&pp->io)) { + close(fd); + pp->io.fd = -1; + free(up); + return(0); + } pp->unitptr = (caddr_t)up; /* @@ -770,8 +776,10 @@ pp = peer->procptr; up = (struct arcunit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } /* @@ -812,9 +820,9 @@ if(spaceleft < sl) { /* Should not normally happen... */ #ifdef DEBUG msyslog(LOG_NOTICE, "ARCRON: send-buffer overrun (%d/%d)", - sl, spaceleft); + sl, spaceleft); #endif - return(0); /* FAILED! */ + return(0); /* FAILED! */ } /* Copy in the command to be sent. */ @@ -846,10 +854,10 @@ (((q) < MIN_CLOCK_QUALITY_OK) ? "TOO POOR, will not use clock" : \ "OK, will use clock")) - /* +/* * arc_receive - receive data from the serial interface */ - static void +static void arc_receive( struct recvbuf *rbufp ) @@ -1005,7 +1013,7 @@ /* Just in case we still have lots of rubbish in the buffer... */ /* ...and to avoid the same timestamp being reused by mistake, */ /* eg on receipt of the \r coming in on its own after the */ - /* timecode. */ + /* timecode. */ if(pp->lencode >= LENARC) { #ifdef DEBUG if(debug && (rbufp->recv_buffer[0] != '\r')) @@ -1083,9 +1091,9 @@ } #endif msyslog(LOG_NOTICE, - "ARCRON: sync finished, signal quality %d: %s", - up->quality, - quality_action(up->quality)); + "ARCRON: sync finished, signal quality %d: %s", + up->quality, + quality_action(up->quality)); up->resyncing = 0; /* Resync is over. */ quality_average = 0; quality_sum = 0; @@ -1210,7 +1218,7 @@ if(pp->year >= YEAR_PIVOT+2000-2 ) { /* Y2KFixes */ /*This should get attention B^> */ msyslog(LOG_NOTICE, - "ARCRON: fix me! EITHER YOUR DATE IS BADLY WRONG or else I will break soon!"); + "ARCRON: fix me! EITHER YOUR DATE IS BADLY WRONG or else I will break soon!"); } #ifdef DEBUG if(debug) { @@ -1271,50 +1279,52 @@ if(peer->MODE > 0) { if(pp->sloppyclockflag & CLK_FLAG1) { struct tm local; - struct tm *gmtp; - time_t unixtime; + struct tm *gmtp; + time_t unixtime; - /* - * Convert to GMT for sites that distribute localtime. + /* + * Convert to GMT for sites that distribute localtime. * This means we have to do Y2K conversion on the * 2-digit year; otherwise, we get the time wrong. - */ - + */ + + memset(&local, 0, sizeof(local)); + local.tm_year = pp->year-1900; - local.tm_mon = month-1; - local.tm_mday = pp->day; - local.tm_hour = pp->hour; - local.tm_min = pp->minute; - local.tm_sec = pp->second; - switch (peer->MODE) { + local.tm_mon = month-1; + local.tm_mday = pp->day; + local.tm_hour = pp->hour; + local.tm_min = pp->minute; + local.tm_sec = pp->second; + switch (peer->MODE) { case 1: local.tm_isdst = (flags & 2); break; case 2: - local.tm_isdst = (flags & 2); + local.tm_isdst = (flags & 2); break; case 3: switch (flags & 3) { case 0: /* It is unclear exactly when the - Arcron changes from DST->ST and + Arcron changes from DST->ST and ST->DST. Testing has shown this to be irregular. For the time being, let the OS decide. */ - local.tm_isdst = 0; + local.tm_isdst = 0; #ifdef DEBUG if (debug) printf ("arc: DST = 00 (0)\n"); #endif break; case 1: /* dst->st time */ - local.tm_isdst = -1; + local.tm_isdst = -1; #ifdef DEBUG if (debug) printf ("arc: DST = 01 (1)\n"); #endif break; case 2: /* st->dst time */ - local.tm_isdst = -1; + local.tm_isdst = -1; #ifdef DEBUG if (debug) printf ("arc: DST = 10 (2)\n"); @@ -1331,26 +1341,26 @@ break; default: msyslog(LOG_NOTICE, "ARCRON: Invalid mode %d", - peer->MODE); + peer->MODE); return; break; } - unixtime = mktime (&local); - if ((gmtp = gmtime (&unixtime)) == NULL) - { + unixtime = mktime (&local); + if ((gmtp = gmtime (&unixtime)) == NULL) + { pp->lencode = 0; - refclock_report (peer, CEVNT_FAULT); - return; - } + refclock_report (peer, CEVNT_FAULT); + return; + } pp->year = gmtp->tm_year+1900; - month = gmtp->tm_mon+1; - pp->day = ymd2yd(pp->year,month,gmtp->tm_mday); - /* pp->day = gmtp->tm_yday; */ - pp->hour = gmtp->tm_hour; - pp->minute = gmtp->tm_min; - pp->second = gmtp->tm_sec; + month = gmtp->tm_mon+1; + pp->day = ymd2yd(pp->year,month,gmtp->tm_mday); + /* pp->day = gmtp->tm_yday; */ + pp->hour = gmtp->tm_hour; + pp->minute = gmtp->tm_min; + pp->second = gmtp->tm_sec; #ifdef DEBUG - if (debug) + if (debug) { printf ("arc: time is %04d/%02d/%02d %02d:%02d:%02d UTC\n", pp->year,month,gmtp->tm_mday,pp->hour,pp->minute, @@ -1359,10 +1369,10 @@ #endif } else { - /* - * For more rational sites distributing UTC - */ - pp->day = ymd2yd(pp->year,month,pp->day); + /* + * For more rational sites distributing UTC + */ + pp->day = ymd2yd(pp->year,month,pp->day); } } @@ -1391,10 +1401,10 @@ if(up->saved_flags != pp->sloppyclockflag) { #ifdef DEBUG msyslog(LOG_NOTICE, "ARCRON: flags enabled: %s%s%s%s", - ((pp->sloppyclockflag & CLK_FLAG1) ? "1" : "."), - ((pp->sloppyclockflag & CLK_FLAG2) ? "2" : "."), - ((pp->sloppyclockflag & CLK_FLAG3) ? "3" : "."), - ((pp->sloppyclockflag & CLK_FLAG4) ? "4" : ".")); + ((pp->sloppyclockflag & CLK_FLAG1) ? "1" : "."), + ((pp->sloppyclockflag & CLK_FLAG2) ? "2" : "."), + ((pp->sloppyclockflag & CLK_FLAG3) ? "3" : "."), + ((pp->sloppyclockflag & CLK_FLAG4) ? "4" : ".")); /* Note effects of flags changing... */ if(debug) { printf("arc: PRECISION = %d.\n", peer->precision); @@ -1436,7 +1446,7 @@ /* request_time() sends a time request to the clock with given peer. */ /* This automatically reports a fault if necessary. */ /* No data should be sent after this until arc_poll() returns. */ -static void request_time P((int, struct peer *)); +static void request_time (int, struct peer *); static void request_time( int unit, diff -urN src/contrib/ntp/ntpd/refclock_as2201.c src.ntp/contrib/ntp/ntpd/refclock_as2201.c --- src/contrib/ntp/ntpd/refclock_as2201.c 2004-07-20 17:01:29.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_as2201.c 2010-02-04 08:26:55.000000000 +0100 @@ -129,10 +129,10 @@ /* * Function prototypes */ -static int as2201_start P((int, struct peer *)); -static void as2201_shutdown P((int, struct peer *)); -static void as2201_receive P((struct recvbuf *)); -static void as2201_poll P((int, struct peer *)); +static int as2201_start (int, struct peer *); +static void as2201_shutdown (int, struct peer *); +static void as2201_receive (struct recvbuf *); +static void as2201_poll (int, struct peer *); /* * Transfer vector @@ -165,26 +165,23 @@ /* * Open serial port. Use CLK line discipline, if available. */ - (void)sprintf(gpsdev, DEVICE, unit); + snprintf(gpsdev, sizeof(gpsdev), DEVICE, unit); if (!(fd = refclock_open(gpsdev, SPEED232, LDISC_CLK))) return (0); /* * Allocate and initialize unit structure */ - if (!(up = (struct as2201unit *) - emalloc(sizeof(struct as2201unit)))) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct as2201unit)); + up = emalloc(sizeof(*up)); + memset(up, 0, sizeof(*up)); pp = peer->procptr; pp->io.clock_recv = as2201_receive; pp->io.srcclock = (caddr_t)peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + close(fd); + pp->io.fd = -1; free(up); return (0); } @@ -217,8 +214,10 @@ pp = peer->procptr; up = (struct as2201unit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } diff -urN src/contrib/ntp/ntpd/refclock_atom.c src.ntp/contrib/ntp/ntpd/refclock_atom.c --- src/contrib/ntp/ntpd/refclock_atom.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_atom.c 2010-02-04 08:26:50.000000000 +0100 @@ -14,21 +14,23 @@ #include "ntp_refclock.h" #include "ntp_stdlib.h" -#if defined(REFCLOCK) && defined(CLOCK_ATOM) - -#ifdef HAVE_PPSAPI -# include "ppsapi_timepps.h" -#endif /* HAVE_PPSAPI */ +/* + * This driver requires the PPSAPI interface (RFC 2783) + */ +#if defined(REFCLOCK) && defined(CLOCK_ATOM) && defined(HAVE_PPSAPI) +#include "ppsapi_timepps.h" +#include "refclock_atom.h" /* * This driver furnishes an interface for pulse-per-second (PPS) signals * produced by a cesium clock, timing receiver or related equipment. It - * can be used to remove accumulated jitter and retime a secondary - * server when synchronized to a primary server over a congested, wide- - * area network and before redistributing the time to local clients. + * can be used to remove accumulated jitter over a congested link and + * retime a server before redistributing the time to clients. It can + *also be used as a holdover should all other synchronization sources + * beconme unreachable. * * Before this driver becomes active, the local clock must be set to - * within +-500 ms by another means, such as a radio clock or NTP + * within +-0.4 s by another means, such as a radio clock or NTP * itself. There are two ways to connect the PPS signal, normally at TTL * levels, to the computer. One is to shift to EIA levels and connect to * pin 8 (DCD) of a serial port. This requires a level converter and @@ -36,27 +38,13 @@ * to connect the PPS signal directly to pin 10 (ACK) of a PC paralell * port. These methods are architecture dependent. * - * Both methods require a modified device driver and kernel interface - * compatible with the Pulse-per-Second API for Unix-like Operating + * This driver requires the Pulse-per-Second API for Unix-like Operating * Systems, Version 1.0, RFC-2783 (PPSAPI). Implementations are - * available for FreeBSD, Linux, SunOS, Solaris and Alpha. However, at - * present only the Alpha implementation provides the full generality of + * available for FreeBSD, Linux, SunOS, Solaris and Tru64. However, at + * present only the Tru64 implementation provides the full generality of * the API with multiple PPS drivers and multiple handles per driver. If * the PPSAPI is normally implemented in the /usr/include/sys/timepps.h * header file and kernel support specific to each operating system. - * However, this driver can operate without this interface if means are - * proviced to call the pps_sample() routine from another driver. Please - * note; if the PPSAPI interface is present, it must be used. - * - * In many configurations a single port is used for the radio timecode - * and PPS signal. In order to provide for this configuration and others - * involving dedicated multiple serial/parallel ports, the driver first - * attempts to open the device /dev/pps%d, where %d is the unit number. - * If this fails, the driver attempts to open the device specified by - * the pps configuration command. If a port is to be shared, the pps - * command must be placed before the radio device(s) and the radio - * device(s) must be placed before the PPS driver(s) in the - * configuration file. * * This driver normally uses the PLL/FLL clock discipline implemented in * the ntpd code. Ordinarily, this is the most accurate means, as the @@ -65,80 +53,62 @@ * to hundreds of PPM), it's better to used the kernel support, if * available. * + * This deriver is subject to the mitigation rules described in the + * "mitigation rulse and the prefer peer" page. However, there is an + * important difference. If this driver becomes the PPS driver according + * to these rules, it is acrive only if (a) a prefer peer other than + * this driver is among the survivors or (b) there are no survivors and + * the minsane option of the tos command is zero. This is intended to + * support space missions where updates from other spacecraft are + * infrequent, but a reliable PPS signal, such as from an Ultra Stable + * Oscillator (USO) is available. + * * Fudge Factors * - * If flag2 is dim (default), the on-time epoch is the assert edge of - * the PPS signal; if lit, the on-time epoch is the clear edge. If flag2 - * is lit, the assert edge is used; if flag3 is dim (default), the - * kernel PPS support is disabled; if lit it is enabled. The time1 - * parameter can be used to compensate for miscellaneous device driver - * and OS delays. + * The PPS timestamp is captured on the rising (assert) edge if flag2 is + * dim (default) and on the falling (clear) edge if lit. If flag3 is dim + * (default), the kernel PPS support is disabled; if lit it is enabled. + * If flag4 is lit, each timesampt is copied to the clockstats file for + * later analysis. This can be useful when constructing Allan deviation + * plots. The time1 parameter can be used to compensate for + * miscellaneous device driver and OS delays. */ /* * Interface definitions */ -#ifdef HAVE_PPSAPI #define DEVICE "/dev/pps%d" /* device name and unit */ -#endif /* HAVE_PPSAPI */ - #define PRECISION (-20) /* precision assumed (about 1 us) */ #define REFID "PPS\0" /* reference ID */ #define DESCRIPTION "PPS Clock Discipline" /* WRU */ -#define NANOSECOND 1000000000 /* one second (ns) */ -#define RANGEGATE 500000 /* range gate (ns) */ -static struct peer *pps_peer; /* atom driver for PPS sources */ - -#ifdef HAVE_PPSAPI /* * PPS unit control structure */ struct ppsunit { - struct timespec ts; /* last timestamp */ - int fddev; /* pps device descriptor */ - pps_params_t pps_params; /* pps parameters */ - pps_info_t pps_info; /* last pps data */ - pps_handle_t handle; /* pps handlebars */ + struct refclock_atom atom; /* atom structure pointer */ + int fddev; /* file descriptor */ }; -#endif /* HAVE_PPSAPI */ /* * Function prototypes */ -static int atom_start P((int, struct peer *)); -static void atom_poll P((int, struct peer *)); -static void atom_shutdown P((int, struct peer *)); -#ifdef HAVE_PPSAPI -static void atom_control P((int, struct refclockstat *, struct - refclockstat *, struct peer *)); -static void atom_timer P((int, struct peer *)); -static int atom_ppsapi P((struct peer *, int)); -#endif /* HAVE_PPSAPI */ +static int atom_start (int, struct peer *); +static void atom_shutdown (int, struct peer *); +static void atom_poll (int, struct peer *); +static void atom_timer (int, struct peer *); /* * Transfer vector */ -#ifdef HAVE_PPSAPI struct refclock refclock_atom = { atom_start, /* start up driver */ atom_shutdown, /* shut down driver */ atom_poll, /* transmit poll message */ - atom_control, /* fudge control */ + noentry, /* control (not used) */ noentry, /* initialize driver (not used) */ noentry, /* buginfo (not used) */ atom_timer, /* called once per second */ }; -#else /* HAVE_PPSAPI */ -struct refclock refclock_atom = { - atom_start, /* start up driver */ - atom_shutdown, /* shut down driver */ - atom_poll, /* transmit poll message */ - noentry, /* fudge control (not used) */ - noentry, /* initialize driver (not used) */ - noentry, /* buginfo (not used) */ - NOFLAGS /* not used */ -}; -#endif /* HAVE_PPPSAPI */ /* @@ -151,22 +121,17 @@ ) { struct refclockproc *pp; -#ifdef HAVE_PPSAPI - register struct ppsunit *up; + struct ppsunit *up; char device[80]; - int mode; -#endif /* HAVE_PPSAPI */ /* * Allocate and initialize unit structure */ - pps_peer = peer; pp = peer->procptr; peer->precision = PRECISION; pp->clockdesc = DESCRIPTION; pp->stratum = STRATUM_UNSPEC; memcpy((char *)&pp->refid, REFID, 4); -#ifdef HAVE_PPSAPI up = emalloc(sizeof(struct ppsunit)); memset(up, 0, sizeof(struct ppsunit)); pp->unitptr = (caddr_t)up; @@ -175,35 +140,18 @@ * Open PPS device. This can be any serial or parallel port and * not necessarily the port used for the associated radio. */ - sprintf(device, DEVICE, unit); - up->fddev = open(device, O_RDWR, 0777); + snprintf(device, sizeof(device), DEVICE, unit); + up->fddev = tty_open(device, O_RDWR, 0777); if (up->fddev <= 0) { msyslog(LOG_ERR, - "refclock_atom: %s: %m", device); - return (0); - } - - /* - * Light off the PPSAPI interface. - */ - if (time_pps_create(up->fddev, &up->handle) < 0) { - msyslog(LOG_ERR, - "refclock_atom: time_pps_create failed: %m"); + "refclock_atom: %s: %m", device); return (0); } /* - * If the mode is nonzero, use that for the time_pps_setparams() - * mode; otherwise, PPS_CAPTUREASSERT. Enable kernel PPS if - * flag3 is lit. + * Light up the PPSAPI interface. */ - mode = peer->ttl; - if (mode == 0) - mode = PPS_CAPTUREASSERT; - return (atom_ppsapi(peer, mode)); -#else /* HAVE_PPSAPI */ - return (1); -#endif /* HAVE_PPSAPI */ + return (refclock_ppsapi(up->fddev, &up->atom)); } @@ -217,249 +165,44 @@ ) { struct refclockproc *pp; - register struct ppsunit *up; + struct ppsunit *up; pp = peer->procptr; up = (struct ppsunit *)pp->unitptr; -#ifdef HAVE_PPSAPI if (up->fddev > 0) close(up->fddev); - if (up->handle != 0) - time_pps_destroy(up->handle); -#endif /* HAVE_PPSAPI */ - if (pps_peer == peer) - pps_peer = NULL; free(up); } - -#ifdef HAVE_PPSAPI -/* - * atom_control - fudge control - */ -static void -atom_control( - int unit, /* unit (not used */ - struct refclockstat *in, /* input parameters (not uded) */ - struct refclockstat *out, /* output parameters (not used) */ - struct peer *peer /* peer structure pointer */ - ) -{ - struct refclockproc *pp; - int mode; - - pp = peer->procptr; - if (peer->ttl != 0) /* all legal modes must be nonzero */ - return; - - if (pp->sloppyclockflag & CLK_FLAG2) - mode = PPS_CAPTURECLEAR; - else - mode = PPS_CAPTUREASSERT; - atom_ppsapi(peer, mode); -} - - -/* - * Initialize PPSAPI - */ -int -atom_ppsapi( - struct peer *peer, /* peer structure pointer */ - int mode /* mode */ - ) -{ - struct refclockproc *pp; - register struct ppsunit *up; - int capability; - - pp = peer->procptr; - up = (struct ppsunit *)pp->unitptr; - if (up->handle == 0) - return (0); - - if (time_pps_getcap(up->handle, &capability) < 0) { - msyslog(LOG_ERR, - "refclock_atom: time_pps_getcap failed: %m"); - return (0); - } - memset(&up->pps_params, 0, sizeof(pps_params_t)); - up->pps_params.api_version = PPS_API_VERS_1; - up->pps_params.mode = mode | PPS_TSFMT_TSPEC; - if (time_pps_setparams(up->handle, &up->pps_params) < 0) { - msyslog(LOG_ERR, - "refclock_atom: time_pps_setparams failed: %m"); - return (0); - } - if (pp->sloppyclockflag & CLK_FLAG3) { - if (time_pps_kcbind(up->handle, PPS_KC_HARDPPS, - up->pps_params.mode & ~PPS_TSFMT_TSPEC, - PPS_TSFMT_TSPEC) < 0) { - msyslog(LOG_ERR, - "refclock_atom: time_pps_kcbind failed: %m"); - return (0); - } - pps_enable = 1; - } -#if DEBUG - if (debug) { - time_pps_getparams(up->handle, &up->pps_params); - printf( - "refclock_ppsapi: fd %d capability 0x%x version %d mode 0x%x\n", - up->fddev, capability, up->pps_params.api_version, - up->pps_params.mode); - } -#endif - return (1); -} - - /* * atom_timer - called once per second - * - * This routine is called once per second when the PPSAPI interface is - * present. It snatches the PPS timestamp from the kernel and saves the - * sign-extended fraction in a circular buffer for processing at the - * next poll event. */ -static void +void atom_timer( - int unit, /* unit number (not used) */ + int unit, /* unit pointer (not used) */ struct peer *peer /* peer structure pointer */ ) { - register struct ppsunit *up; + struct ppsunit *up; struct refclockproc *pp; - pps_info_t pps_info; - struct timespec timeout, ts; - long sec, nsec; - double dtemp; - char tbuf[80]; /* monitor buffer */ + char tbuf[80]; - /* - * Convert the timespec nanoseconds field to signed double and - * save in the median filter. for billboards. No harm is done if - * previous data are overwritten. If the discipline comes bum or - * the data grow stale, just forget it. A range gate rejects new - * samples if less than a jiggle time from the next second. - */ pp = peer->procptr; up = (struct ppsunit *)pp->unitptr; - if (up->handle == 0) + if (refclock_pps(peer, &up->atom, pp->sloppyclockflag) <= 0) return; - timeout.tv_sec = 0; - timeout.tv_nsec = 0; - memcpy(&pps_info, &up->pps_info, sizeof(pps_info_t)); - if (time_pps_fetch(up->handle, PPS_TSFMT_TSPEC, &up->pps_info, - &timeout) < 0) { - refclock_report(peer, CEVNT_FAULT); - return; - } - if (up->pps_params.mode & PPS_CAPTUREASSERT) { - ts = up->pps_info.assert_timestamp; - } else if (up->pps_params.mode & PPS_CAPTURECLEAR) { - ts = up->pps_info.clear_timestamp; - } else { - refclock_report(peer, CEVNT_FAULT); - return; - } + peer->flags |= FLAG_PPS; /* - * There can be zero, one or two PPS seconds between polls. If - * zero, either the poll clock is slightly faster than the PPS - * clock or the PPS clock has died. If the PPS clock advanced - * once between polls, we make sure the fraction time difference - * since the last sample is within the range gate of 5 ms (500 - * PPM). If the PPS clock advanced twice since the last poll, - * the poll bracketed more than one second and the first second - * was lost to a slip. Since the interval since the last sample - * found is now two seconds, just widen the range gate. If the - * PPS clock advanced three or more times, either the signal has - * failed for a number of seconds or we have runts, in which - * case just ignore them. - * * If flag4 is lit, record each second offset to clockstats. * That's so we can make awesome Allan deviation plots. */ - sec = ts.tv_sec - up->ts.tv_sec; - nsec = ts.tv_nsec - up->ts.tv_nsec; - up->ts = ts; - if (nsec < 0) { - sec --; - nsec += NANOSECOND; - } else if (nsec >= NANOSECOND) { - sec++; - nsec -= NANOSECOND; - } - if (sec * NANOSECOND + nsec > NANOSECOND + RANGEGATE) - return; - - else if (sec * NANOSECOND + nsec < NANOSECOND - RANGEGATE) - return; - - pp->lastrec.l_ui = ts.tv_sec + JAN_1970; - dtemp = ts.tv_nsec * FRAC / 1e9; - if (dtemp >= FRAC) - pp->lastrec.l_ui++; - pp->lastrec.l_uf = (u_int32)dtemp; - if (ts.tv_nsec > NANOSECOND / 2) - ts.tv_nsec -= NANOSECOND; - dtemp = -(double)ts.tv_nsec / NANOSECOND; - SAMPLE(dtemp + pp->fudgetime1); - if (pp->sloppyclockflag & CLK_FLAG4){ - sprintf(tbuf, "%.9f", dtemp); + if (pp->sloppyclockflag & CLK_FLAG4) { + snprintf(tbuf, sizeof(tbuf), "%.9f", + pp->filter[pp->coderecv]); record_clock_stats(&peer->srcadr, tbuf); } -#ifdef DEBUG - if (debug > 1) - printf("atom_timer: %lu %f %f\n", current_time, - dtemp, pp->fudgetime1); -#endif - return; -} -#endif /* HAVE_PPSAPI */ - - -/* - * pps_sample - receive PPS data from some other clock driver - * - * This routine is called once per second when the external clock driver - * processes PPS information. It processes the PPS timestamp and saves - * the sign-extended fraction in a circular buffer for processing at the - * next poll event. This works only for a single PPS device. - * - * The routine should be used by another configured driver ONLY when - * this driver is configured as well and the PPSAPI is NOT in use. - */ -int -pps_sample( - l_fp *offset /* PPS offset */ - ) -{ - register struct peer *peer; - struct refclockproc *pp; - l_fp lftmp; - double doffset; - - peer = pps_peer; - if (peer == NULL) - return (1); - - pp = peer->procptr; - - /* - * Convert the timeval to l_fp and save for billboards. Sign- - * extend the fraction and stash in the buffer. No harm is done - * if previous data are overwritten. If the discipline comes bum - * or the data grow stale, just forget it. - */ - pp->lastrec = *offset; - L_CLR(&lftmp); - L_ADDF(&lftmp, pp->lastrec.l_f); - LFPTOD(&lftmp, doffset); - SAMPLE(-doffset + pp->fudgetime1); - return (0); } @@ -473,45 +216,24 @@ ) { struct refclockproc *pp; - pp = peer->procptr; - pp->polls++; /* - * Valid time is returned only if the prefer peer has survived - * the intersection algorithm and within 0.4 s of local time - * and not too long ago. This ensures the PPS time is within - * 0.5 s of the local time and the seconds numbering is - * unambiguous. Note that the leap bits, stratum and refid are - * set from the prefer peer, unless overriden by a fudge - * command. + * Don't wiggle the clock until some other driver has numbered + * the seconds. */ - if (pp->codeproc == pp->coderecv) { - refclock_report(peer, CEVNT_TIMEOUT); + if (sys_leap == LEAP_NOTINSYNC) return; - } else if (sys_prefer == NULL) { - pp->codeproc = pp->coderecv; - return; - - } else if (fabs(sys_prefer->offset) >= 0.4) { - pp->codeproc = pp->coderecv; + pp = peer->procptr; + pp->polls++; + if (pp->codeproc == pp->coderecv) { + peer->flags &= ~FLAG_PPS; + refclock_report(peer, CEVNT_TIMEOUT); return; } - pp->leap = sys_prefer->leap; - if (pp->stratum >= STRATUM_UNSPEC) - peer->stratum = sys_prefer->stratum; - else - peer->stratum = pp->stratum; pp->lastref = pp->lastrec; refclock_receive(peer); } #else int refclock_atom_bs; -int -pps_sample( - l_fp *offset /* PPS offset */ - ) -{ - return (1); -} #endif /* REFCLOCK */ diff -urN src/contrib/ntp/ntpd/refclock_bancomm.c src.ntp/contrib/ntp/ntpd/refclock_bancomm.c --- src/contrib/ntp/ntpd/refclock_bancomm.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_bancomm.c 2010-02-04 08:26:59.000000000 +0100 @@ -20,26 +20,29 @@ * vme_control() and vme_buginfo() have been deleted because * they are no longer being used. * - * The time on the bc635 TFP must be set to GMT due to the - * fact that NTP makes use of GMT for all its calculations. - * - * Installation of the Datum/Bancomm driver creates the - * device file /dev/btfp0 - * * 04/28/2005 Rob Neal * Modified to add support for Symmetricom bc637PCI-U Time & * Frequency Processor. + * 2/21/2007 Ali Ghorashi + * Modified to add support for Symmetricom bc637PCI-U Time & + * Frequency Processor on Solaris. + * Tested on Solaris 10 with a bc635 card. + * * Card bus type (VME/VXI or PCI) and environment are specified via the * "mode" keyword on the server command in ntp.conf. - * server 127.127.16.u prefer mode m (...) - * Modes currently supported are + * server 127.127.16.u prefer mode M + * where u is the id (usually 0) of the entry in /dev (/dev/stfp0) + * + * and M is one of the following modes: * 1 : FreeBSD PCI 635/637. * 2 : Linux or Windows PCI 635/637. + * 3 : Solaris PCI 635/637 * not specified, or other number: * : Assumed to be VME/VXI legacy Bancomm card on Solaris. * Linux and Windows platforms require Symmetricoms' proprietary driver - * for the TFP card. - * Tested on FreeBSD 5.3 with a 637 card. + * for the TFP card. + * Solaris requires Symmetricom's driver and its header file (freely distributed) to + * be installed and running. */ #ifdef HAVE_CONFIG_H @@ -58,7 +61,6 @@ #include #include -/* STUFF BY RES */ struct btfp_time /* Structure for reading 5 time words */ /* in one ioctl(2) operation. */ { @@ -85,9 +87,37 @@ #define READTIME _IOR('u', 5, struct btfp_time ) #endif -#define VMEFD "/dev/btfp0" +/* Solaris specific section */ +struct stfp_tm { + int32_t tm_sec; + int32_t tm_min; + int32_t tm_hour; + int32_t tm_mday; + int32_t tm_mon; + int32_t tm_year; + int32_t tm_wday; + int32_t tm_yday; + int32_t tm_isdst; +}; + +struct stfp_time { + struct stfp_tm tm; + int32_t usec; /* usec 0 - 999999 */ + int32_t hnsec; /* hnsec 0 - 9 (hundreds of nsecs) */ + int32_t status; +}; + +#define SELTIMEFORMAT 2 +# define TIME_DECIMAL 0 +# define TIME_BINARY 1 + +#if defined(__sun__) +#undef READTIME +#define READTIME 9 +#endif /** __sun___ **/ +/* end solaris specific section */ -struct vmedate { /* structure returned by get_vmetime.c */ +struct vmedate { /* structure returned by get_vmetime.c */ unsigned short year; unsigned short day; unsigned short hr; @@ -97,7 +127,6 @@ unsigned short status; }; -/* END OF STUFF FROM RES */ typedef void *SYMMT_PCI_HANDLE; /* @@ -139,7 +168,11 @@ static void vme_receive (struct recvbuf *); static void vme_poll (int unit, struct peer *); struct vmedate *get_datumtime(struct vmedate *); -void tvme_fill(struct vmedate *, uint32_t btm[2]); +void tvme_fill(struct vmedate *, uint32_t btm[2]); +void stfp_time2tvme(struct vmedate *time_vme, struct stfp_time *stfp); +inline const char *DEVICE_NAME(int n); + + /* * Define the bc*() functions as weak so we can compile/link without them. * Only clients with the card will have the proprietary vendor device driver @@ -167,6 +200,15 @@ int tfp_type; /* mode selector, indicate platform and driver interface */ SYMMT_PCI_HANDLE stfp_handle; +/** + * this macro returns the device name based on + * the platform we are running on and the device number + */ +#if defined(__sun__) +inline const char *DEVICE_NAME(int n) {static char s[20]={0}; snprintf(s,19,"/dev/stfp%d",n);return s;} +#else +inline const char* DEVICE_NAME(int n) {static char s[20]={0}; snprintf(s,19,"/dev/btfp%d",n);return s;} +#endif /**__sun__**/ /* * vme_start - open the VME device and initialize data for processing @@ -185,6 +227,7 @@ tfp_type = (int)(peer->ttl); switch (tfp_type) { case 1: + case 3: break; case 2: stfp_handle = bcStartPci(); /* init the card in lin/win */ @@ -197,9 +240,9 @@ */ #ifdef DEBUG - printf("Opening DATUM VME DEVICE \n"); + printf("Opening DATUM DEVICE %s\n",DEVICE_NAME(peer->refclkunit)); #endif - if ( (fd_vme = open(VMEFD, O_RDWR)) < 0) { + if ( (fd_vme = open(DEVICE_NAME(peer->refclkunit), O_RDWR)) < 0) { msyslog(LOG_ERR, "vme_start: failed open of %s: %m", vmedev); return (0); } @@ -207,6 +250,7 @@ switch (tfp_type) { case 1: break; case 2: break; + case 3:break; default: /* Release capture lockout in case it was set before. */ if( ioctl( fd_vme, RUNLOCK, &dummy ) ) @@ -268,8 +312,10 @@ vme = (struct vmeunit *)pp->unitptr; io_closeclock(&pp->io); pp->unitptr = NULL; - free(vme); - if (tfp_type == 2) bcStopPci(stfp_handle); + if (NULL != vme) + free(vme); + if (tfp_type == 2) + bcStopPci(stfp_handle); } @@ -324,14 +370,15 @@ tadr = gmtime(&tloc); tptr->year = (unsigned short)(tadr->tm_year + 1900); - sprintf(pp->a_lastcode, - "%3.3d %2.2d:%2.2d:%2.2d.%.6ld %1d", - tptr->day, - tptr->hr, - tptr->mn, - tptr->sec, - tptr->frac, - tptr->status); + snprintf(pp->a_lastcode, + sizeof(pp->a_lastcode), + "%3.3d %2.2d:%2.2d:%2.2d.%.6ld %1d", + tptr->day, + tptr->hr, + tptr->mn, + tptr->sec, + tptr->frac, + tptr->status); pp->lencode = (u_short) strlen(pp->a_lastcode); @@ -376,10 +423,10 @@ struct btfp_time vts; uint32_t btm[2]; uint8_t dmy; + struct stfp_time stfpm; - if ( time_vme == (struct vmedate *)NULL) { - time_vme = (struct vmedate *)malloc(sizeof(struct vmedate )); - } + if (time_vme == NULL) + time_vme = emalloc(sizeof(*time_vme)); switch (tfp_type) { case 1: /* BSD, PCI, 2 32bit time words */ @@ -397,41 +444,65 @@ } tvme_fill(time_vme, btm); break; + + case 3: /** solaris **/ + memset(&stfpm,0,sizeof(stfpm)); + + /* we need the time in decimal format */ + /* Here we rudely assume that we are the only user of the driver. + * Other programs will have to set their own time format before reading + * the time. + */ + if(ioctl (fd_vme, SELTIMEFORMAT, TIME_DECIMAL)){ + msyslog(LOG_ERR, "Could not set time format\n"); + return (NULL); + } + /* read the time */ + if (ioctl(fd_vme, READTIME, &stfpm)) { + msyslog(LOG_ERR, "ioctl error: %m"); + return(NULL); + } + stfp_time2tvme(time_vme, &stfpm); + break; default: /* legacy bancomm card */ if (ioctl(fd_vme, READTIME, &vts)) { - msyslog(LOG_ERR, "get_datumtime error: %m"); + msyslog(LOG_ERR, + "get_datumtime error: %m"); return(NULL); } /* Get day */ - sprintf(cbuf,"%3.3x", ((vts.btfp_time[ 0 ] & 0x000f) <<8) + - ((vts.btfp_time[ 1 ] & 0xff00) >> 8)); + snprintf(cbuf, sizeof(cbuf), "%3.3x", + ((vts.btfp_time[ 0 ] & 0x000f) << 8) + + ((vts.btfp_time[ 1 ] & 0xff00) >> 8)); time_vme->day = (unsigned short)atoi(cbuf); /* Get hour */ - sprintf(cbuf,"%2.2x", vts.btfp_time[ 1 ] & 0x00ff); - + snprintf(cbuf, sizeof(cbuf), "%2.2x", + vts.btfp_time[ 1 ] & 0x00ff); time_vme->hr = (unsigned short)atoi(cbuf); /* Get minutes */ - sprintf(cbuf,"%2.2x", (vts.btfp_time[ 2 ] & 0xff00) >>8); + snprintf(cbuf, sizeof(cbuf), "%2.2x", + (vts.btfp_time[ 2 ] & 0xff00) >> 8); time_vme->mn = (unsigned short)atoi(cbuf); /* Get seconds */ - sprintf(cbuf,"%2.2x", vts.btfp_time[ 2 ] & 0x00ff); + snprintf(cbuf, sizeof(cbuf), "%2.2x", + vts.btfp_time[ 2 ] & 0x00ff); time_vme->sec = (unsigned short)atoi(cbuf); /* Get microseconds. Yes, we ignore the 0.1 microsecond digit so we can use the TVTOTSF function later on...*/ - sprintf(cbuf,"%4.4x%2.2x", vts.btfp_time[ 3 ], - vts.btfp_time[ 4 ]>>8); - + snprintf(cbuf, sizeof(cbuf), "%4.4x%2.2x", + vts.btfp_time[ 3 ], + vts.btfp_time[ 4 ] >> 8); time_vme->frac = (u_long) atoi(cbuf); /* Get status bit */ - time_vme->status = (vts.btfp_time[0] & 0x0010) >>4; + time_vme->status = (vts.btfp_time[0] & 0x0010) >> 4; break; } @@ -462,6 +533,21 @@ return; } + +/* Assign values to time_vme struct. Mostly for readability */ +void +stfp_time2tvme(struct vmedate *time_vme, struct stfp_time *stfp) +{ + + time_vme->day = stfp->tm.tm_yday+1; + time_vme->hr = stfp->tm.tm_hour; + time_vme->mn = stfp->tm.tm_min; + time_vme->sec = stfp->tm.tm_sec; + time_vme->frac = stfp->usec*1000; + time_vme->frac += stfp->hnsec * 100; + time_vme->status = stfp->status; + return; +} #else int refclock_bancomm_bs; #endif /* REFCLOCK */ diff -urN src/contrib/ntp/ntpd/refclock_chronolog.c src.ntp/contrib/ntp/ntpd/refclock_chronolog.c --- src/contrib/ntp/ntpd/refclock_chronolog.c 2004-07-20 17:01:30.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_chronolog.c 2010-02-04 08:26:50.000000000 +0100 @@ -67,10 +67,10 @@ /* * Function prototypes */ -static int chronolog_start P((int, struct peer *)); -static void chronolog_shutdown P((int, struct peer *)); -static void chronolog_receive P((struct recvbuf *)); -static void chronolog_poll P((int, struct peer *)); +static int chronolog_start (int, struct peer *); +static void chronolog_shutdown (int, struct peer *); +static void chronolog_receive (struct recvbuf *); +static void chronolog_poll (int, struct peer *); /* * Transfer vector @@ -104,7 +104,7 @@ * Open serial port. Don't bother with CLK line discipline, since * it's not available. */ - (void)sprintf(device, DEVICE, unit); + snprintf(device, sizeof(device), DEVICE, unit); #ifdef DEBUG if (debug) printf ("starting Chronolog with device %s\n",device); @@ -115,12 +115,8 @@ /* * Allocate and initialize unit structure */ - if (!(up = (struct chronolog_unit *) - emalloc(sizeof(struct chronolog_unit)))) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct chronolog_unit)); + up = emalloc(sizeof(*up)); + memset(up, 0, sizeof(*up)); pp = peer->procptr; pp->unitptr = (caddr_t)up; pp->io.clock_recv = chronolog_receive; @@ -128,8 +124,10 @@ pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + close(fd); + pp->io.fd = -1; free(up); + pp->unitptr = NULL; return (0); } @@ -157,8 +155,10 @@ pp = peer->procptr; up = (struct chronolog_unit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } @@ -240,6 +240,8 @@ * otherwise, we get the time wrong. */ + memset(&local, 0, sizeof(local)); + local.tm_year = up->year; local.tm_mon = up->month-1; local.tm_mday = up->day; diff -urN src/contrib/ntp/ntpd/refclock_chu.c src.ntp/contrib/ntp/ntpd/refclock_chu.c --- src/contrib/ntp/ntpd/refclock_chu.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_chu.c 2010-02-16 12:17:56.000000000 +0100 @@ -26,47 +26,47 @@ #ifdef ICOM #include "icom.h" #endif /* ICOM */ - /* * Audio CHU demodulator/decoder * * This driver synchronizes the computer time using data encoded in * radio transmissions from Canadian time/frequency station CHU in * Ottawa, Ontario. Transmissions are made continuously on 3330 kHz, - * 7335 kHz and 14670 kHz in upper sideband, compatible AM mode. An + * 7850 kHz and 14670 kHz in upper sideband, compatible AM mode. An * ordinary shortwave receiver can be tuned manually to one of these * frequencies or, in the case of ICOM receivers, the receiver can be - * tuned automatically using this program as propagation conditions - * change throughout the day and night. + * tuned automatically as propagation conditions change throughout the + * day and season. * - * The driver receives, demodulates and decodes the radio signals when - * connected to the audio codec of a suported workstation hardware and - * operating system. These include Solaris, SunOS, FreeBSD, NetBSD and - * Linux. In this implementation, only one audio driver and codec can be - * supported on a single machine. + * The driver requires an audio codec or sound card with sampling rate 8 + * kHz and mu-law companding. This is the same standard as used by the + * telephone industry and is supported by most hardware and operating + * systems, including Solaris, SunOS, FreeBSD, NetBSD and Linux. In this + * implementation, only one audio driver and codec can be supported on a + * single machine. * * The driver can be compiled to use a Bell 103 compatible modem or * modem chip to receive the radio signal and demodulate the data. * Alternatively, the driver can be compiled to use the audio codec of - * the Sun workstation or another with compatible audio drivers. In the + * the workstation or another with compatible audio drivers. In the * latter case, the driver implements the modem using DSP routines, so * the radio can be connected directly to either the microphone on line * input port. In either case, the driver decodes the data using a - * maximum likelihood technique which exploits the considerable degree + * maximum-likelihood technique which exploits the considerable degree * of redundancy available to maximize accuracy and minimize errors. * * The CHU time broadcast includes an audio signal compatible with the - * Bell 103 modem standard (mark = 2225 Hz, space = 2025 Hz). It consist - * of nine, ten-character bursts transmitted at 300 bps and beginning - * each second from second 31 to second 39 of the minute. Each character - * consists of eight data bits plus one start bit and two stop bits to - * encode two hex digits. The burst data consist of five characters (ten - * hex digits) followed by a repeat of these characters. In format A, - * the characters are repeated in the same polarity; in format B, the - * characters are repeated in the opposite polarity. + * Bell 103 modem standard (mark = 2225 Hz, space = 2025 Hz). The signal + * consists of nine, ten-character bursts transmitted at 300 bps between + * seconds 31 and 39 of each minute. Each character consists of eight + * data bits plus one start bit and two stop bits to encode two hex + * digits. The burst data consist of five characters (ten hex digits) + * followed by a repeat of these characters. In format A, the characters + * are repeated in the same polarity; in format B, the characters are + * repeated in the opposite polarity. * * Format A bursts are sent at seconds 32 through 39 of the minute in - * hex digits + * hex digits (nibble swapped) * * 6dddhhmmss6dddhhmmss * @@ -96,10 +96,10 @@ * By design, the last stop bit of the last character in the burst * coincides with 0.5 second. Since characters have 11 bits and are * transmitted at 300 bps, the last stop bit of the first character - * coincides with 0.5 - 10 * 11/300 = 0.133 second. Depending on the - * UART, character interrupts can vary somewhere between the beginning - * of bit 9 and end of bit 11. These eccentricities can be corrected - * along with the radio propagation delay using fudge time 1. + * coincides with 0.5 - 9 * 11/300 = 0.170 second. Depending on the + * UART, character interrupts can vary somewhere between the end of bit + * 9 and end of bit 11. These eccentricities can be corrected along with + * the radio propagation delay using fudge time 1. * * Debugging aids * @@ -107,11 +107,15 @@ * data helpful in diagnosing problems with the radio signal and serial * connections. With debugging enabled (-d on the ntpd command line), * the driver produces one line for each burst in two formats - * corresponding to format A and B. Following is format A: + * corresponding to format A and B.Each line begins with the format code + * chuA or chuB followed by the status code and signal level (0-9999). + * The remainder of the line is as follows. + * + * Following is format A: * * n b f s m code * - * where n is the number of characters in the burst (0-11), b the burst + * where n is the number of characters in the burst (0-10), b the burst * distance (0-40), f the field alignment (-1, 0, 1), s the * synchronization distance (0-16), m the burst number (2-9) and code * the burst characters as received. Note that the hex digits in each @@ -119,43 +123,50 @@ * * 10 38 0 16 9 06851292930685129293 * - * is interpreted as containing 11 characters with burst distance 38, + * is interpreted as containing 10 characters with burst distance 38, * field alignment 0, synchronization distance 16 and burst number 9. * The nibble-swapped timecode shows day 58, hour 21, minute 29 and * second 39. * - * When the audio driver is compiled, format A is preceded by - * the current gain (0-255) and relative signal level (0-9999). The - * receiver folume control should be set so that the gain is somewhere - * near the middle of the range 0-255, which results in a signal level - * near 1000. - * * Following is format B: * * n b s code * - * where n is the number of characters in the burst (0-11), b the burst + * where n is the number of characters in the burst (0-10), b the burst * distance (0-40), s the synchronization distance (0-40) and code the * burst characters as received. Note that the hex digits in each * character are reversed and the last ten digits inverted, so the burst * - * 11 40 1091891300ef6e76ecff + * 10 40 1091891300ef6e76ec * - * is interpreted as containing 11 characters with burst distance 40. + * is interpreted as containing 10 characters with burst distance 40. * The nibble-swapped timecode shows DUT1 +0.1 second, year 1998 and TAI * - UTC 31 seconds. * + * Each line is preceeded by the code chuA or chuB, as appropriate. If + * the audio driver is compiled, the current gain (0-255) and relative + * signal level (0-9999) follow the code. The receiver volume control + * should be set so that the gain is somewhere near the middle of the + * range 0-255, which results in a signal level near 1000. + * * In addition to the above, the reference timecode is updated and * written to the clockstats file and debug score after the last burst * received in the minute. The format is * - * qq yyyy ddd hh:mm:ss nn dd tt + * sq yyyy ddd hh:mm:ss l s dd t agc ident m b * - * where qq are the error flags, as described below, yyyy is the year, - * ddd the day, hh:mm:ss the time of day, nn the number of format A - * bursts received during the previous minute, dd the decoding distance - * and tt the number of timestamps. The error flags are cleared after - * every update. + * s '?' before first synchronized and ' ' after that + * q status code (see below) + * yyyy year + * ddd day of year + * hh:mm:ss time of day + * l leap second indicator (space, L or D) + * dst Canadian daylight code (opaque) + * t number of minutes since last synchronized + * agc audio gain (0 - 255) + * ident identifier (CHU0 3330 kHz, CHU1 7850 kHz, CHU2 14670 kHz) + * m signal metric (0 - 100) + * b number of timecodes for the previous minute (0 - 59) * * Fudge factors * @@ -184,6 +195,11 @@ * 9600 bps if the high order 0x80 bit of the mode is zero and 1200 bps * if one. The C-IV trace is turned on if the debug level is greater * than one. + * + * Alarm codes + * + * CEVNT_BADTIME invalid date or time + * CEVNT_PROP propagation failure - no stations heard */ /* * Interface definitions @@ -194,8 +210,8 @@ #define DEVICE "/dev/chu%d" /* device name and unit */ #define SPEED232 B300 /* UART speed (300 baud) */ #ifdef ICOM -#define TUNE .001 /* offset for narrow filter (kHz) */ -#define DWELL 5 /* minutes in a probe cycle */ +#define TUNE .001 /* offset for narrow filter (MHz) */ +#define DWELL 5 /* minutes in a dwell */ #define NCHAN 3 /* number of channels */ #define ISTAGE 3 /* number of integrator stages */ #endif /* ICOM */ @@ -210,6 +226,7 @@ #define SIZE 256 /* decompanding table size */ #define MAXAMP 6000. /* maximum signal level */ #define MAXCLP 100 /* max clips above reference per s */ +#define SPAN 800. /* min envelope span */ #define LIMIT 1000. /* soft limiter threshold */ #define AGAIN 6. /* baseband gain */ #define LAG 10 /* discriminator lag */ @@ -224,23 +241,28 @@ * Decoder definitions */ #define CHAR (11. / 300.) /* character time (s) */ -#define FUDGE .185 /* offset to first stop bit (s) */ #define BURST 11 /* max characters per burst */ #define MINCHAR 9 /* min characters per burst */ #define MINDIST 28 /* min burst distance (of 40) */ -#define MINBURST 4 /* min bursts in minute */ #define MINSYNC 8 /* min sync distance (of 16) */ #define MINSTAMP 20 /* min timestamps (of 60) */ -#define METRIC 50. /* min channel metric */ -#define PANIC 1440 /* panic timeout (m) */ -#define HOLD 30 /* reach hold (m) */ +#define MINMETRIC 50 /* min channel metric (of 160) */ /* - * Hex extension codes (>= 16) + * The on-time synchronization point for the driver is the last stop bit + * of the first character 170 ms. The modem delay is 0.8 ms, while the + * receiver delay is approxmately 4.7 ms at 2125 Hz. The fudge value 1.3 + * ms due to the codec and other causes was determined by calibrating to + * a PPS signal from a GPS receiver. The additional propagation delay + * specific to each receiver location can be programmed in the fudge + * time1. + * + * The resulting offsets with a 2.4-GHz P4 running FreeBSD 6.1 are + * generally within 0.5 ms short term with 0.3 ms jitter. The long-term + * offsets vary up to 0.3 ms due to ionospheric layer height variations. + * The processor load due to the driver is 0.4 percent. */ -#define HEX_MISS 16 /* miss _ */ -#define HEX_SOFT 17 /* soft error * */ -#define HEX_HARD 18 /* hard error = */ +#define PDELAY ((170 + .8 + 4.7 + 1.3) / 1000) /* system delay (s) */ /* * Status bits (status) @@ -256,6 +278,7 @@ #define AVALID 0x0100 /* valid A frame */ #define BVALID 0x0200 /* valid B frame */ #define INSYNC 0x0400 /* clock synchronized */ +#define METRIC 0x0800 /* one or more stations heard */ /* * Alarm status bits (alarm) @@ -273,12 +296,13 @@ #ifdef HAVE_AUDIO /* - * Maximum likelihood UART structure. There are eight of these + * Maximum-likelihood UART structure. There are eight of these * corresponding to the number of phases. */ struct surv { - double shift[12]; /* mark register */ - double es_max, es_min; /* max/min envelope signals */ + l_fp cstamp; /* last bit timestamp */ + double shift[12]; /* sample shift register */ + double span; /* shift register envelope span */ double dist; /* sample distance */ int uart; /* decoded character */ }; @@ -301,19 +325,19 @@ * CHU unit control structure */ struct chuunit { - u_char decode[20][16]; /* maximum likelihood decoding matrix */ + u_char decode[20][16]; /* maximum-likelihood decoding matrix */ l_fp cstamp[BURST]; /* character timestamps */ l_fp tstamp[MAXSTAGE]; /* timestamp samples */ l_fp timestamp; /* current buffer timestamp */ l_fp laststamp; /* last buffer timestamp */ l_fp charstamp; /* character time as a l_fp */ + int second; /* counts the seconds of the minute */ int errflg; /* error flags */ int status; /* status bits */ char ident[5]; /* station ID and channel */ #ifdef ICOM int fd_icom; /* ICOM file descriptor */ - int chan; /* data channel */ - int achan; /* active channel */ + int chan; /* radio channel */ int dwell; /* dwell cycle */ struct xmtr xmtr[NCHAN]; /* station metric */ #endif /* ICOM */ @@ -328,6 +352,8 @@ int burdist; /* burst distance */ int syndist; /* sync distance */ int burstcnt; /* format A bursts this minute */ + double maxsignal; /* signal level (modem only) */ + int gain; /* codec gain (modem only) */ /* * Format particulars @@ -344,7 +370,6 @@ int fd_audio; /* audio port file descriptor */ double comp[SIZE]; /* decompanding table */ int port; /* codec port */ - int gain; /* codec gain */ int mongain; /* codec monitor gain */ int clipcnt; /* sample clip count */ int seccnt; /* second interval counter */ @@ -357,15 +382,15 @@ double disc[LAG]; /* discriminator shift register */ double lpf[27]; /* FIR lowpass filter */ double monitor; /* audio monitor */ - double maxsignal; /* signal level */ int discptr; /* discriminator pointer */ /* - * Maximum likelihood UART variables + * Maximum-likelihood UART variables */ double baud; /* baud interval */ struct surv surv[8]; /* UART survivor structures */ int decptr; /* decode pointer */ + int decpha; /* decode phase */ int dbrk; /* holdoff counter */ #endif /* HAVE_AUDIO */ }; @@ -373,31 +398,32 @@ /* * Function prototypes */ -static int chu_start P((int, struct peer *)); -static void chu_shutdown P((int, struct peer *)); -static void chu_receive P((struct recvbuf *)); -static void chu_poll P((int, struct peer *)); +static int chu_start (int, struct peer *); +static void chu_shutdown (int, struct peer *); +static void chu_receive (struct recvbuf *); +static void chu_second (int, struct peer *); +static void chu_poll (int, struct peer *); /* * More function prototypes */ -static void chu_decode P((struct peer *, int)); -static void chu_burst P((struct peer *)); -static void chu_clear P((struct peer *)); -static void chu_a P((struct peer *, int)); -static void chu_b P((struct peer *, int)); -static int chu_dist P((int, int)); -static double chu_major P((struct peer *)); +static void chu_decode (struct peer *, int, l_fp); +static void chu_burst (struct peer *); +static void chu_clear (struct peer *); +static void chu_a (struct peer *, int); +static void chu_b (struct peer *, int); +static int chu_dist (int, int); +static double chu_major (struct peer *); #ifdef HAVE_AUDIO -static void chu_uart P((struct surv *, double)); -static void chu_rf P((struct peer *, double)); -static void chu_gain P((struct peer *)); -static void chu_audio_receive P((struct recvbuf *rbufp)); +static void chu_uart (struct surv *, double); +static void chu_rf (struct peer *, double); +static void chu_gain (struct peer *); +static void chu_audio_receive (struct recvbuf *rbufp); #endif /* HAVE_AUDIO */ #ifdef ICOM -static int chu_newchan P((struct peer *, double)); +static int chu_newchan (struct peer *, double); #endif /* ICOM */ -static void chu_serial_receive P((struct recvbuf *rbufp)); +static void chu_serial_receive (struct recvbuf *rbufp); /* * Global variables @@ -410,7 +436,7 @@ * transmits on USB with carrier so we can use AM and the narrow SSB * filter. */ -static double qsy[NCHAN] = {3.330, 7.335, 14.670}; /* freq (MHz) */ +static double qsy[NCHAN] = {3.330, 7.850, 14.670}; /* freq (MHz) */ #endif /* ICOM */ /* @@ -423,7 +449,7 @@ noentry, /* not used (old chu_control) */ noentry, /* initialize driver (not used) */ noentry, /* not used (old chu_buginfo) */ - NOFLAGS /* not used */ + chu_second /* housekeeping timer */ }; @@ -449,7 +475,7 @@ double step; /* codec adjustment */ /* - * Open audio device. + * Open audio device. Don't complain if not there. */ fd_audio = audio_init(DEVICE_AUDIO, AUDIO_BUFSIZ, unit); #ifdef DEBUG @@ -458,12 +484,12 @@ #endif /* - * Open serial port in raw mode. + * If audio is unavailable, Open serial port in raw mode. */ if (fd_audio > 0) { fd = fd_audio; } else { - sprintf(device, DEVICE, unit); + snprintf(device, sizeof(device), DEVICE, unit); fd = refclock_open(device, SPEED232, LDISC_RAW); } #else /* HAVE_AUDIO */ @@ -471,7 +497,7 @@ /* * Open serial port in raw mode. */ - sprintf(device, DEVICE, unit); + snprintf(device, sizeof(device), DEVICE, unit); fd = refclock_open(device, SPEED232, LDISC_RAW); #endif /* HAVE_AUDIO */ if (fd <= 0) @@ -480,12 +506,8 @@ /* * Allocate and initialize unit structure */ - if (!(up = (struct chuunit *) - emalloc(sizeof(struct chuunit)))) { - close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct chuunit)); + up = emalloc(sizeof(*up)); + memset(up, 0, sizeof(*up)); pp = peer->procptr; pp->unitptr = (caddr_t)up; pp->io.clock_recv = chu_receive; @@ -494,7 +516,9 @@ pp->io.fd = fd; if (!io_addclock(&pp->io)) { close(fd); + pp->io.fd = -1; free(up); + pp->unitptr = NULL; return (0); } @@ -504,7 +528,7 @@ peer->precision = PRECISION; pp->clockdesc = DESCRIPTION; strcpy(up->ident, "CHU"); - memcpy(&peer->refid, up->ident, 4); + memcpy(&pp->refid, up->ident, 4); DTOLFP(CHAR, &up->charstamp); #ifdef HAVE_AUDIO @@ -543,16 +567,11 @@ } if (up->fd_icom > 0) { if (chu_newchan(peer, 0) != 0) { - NLOG(NLOG_SYNCEVENT | NLOG_SYSEVENT) - msyslog(LOG_NOTICE, - "icom: radio not found"); - up->errflg = CEVNT_FAULT; + msyslog(LOG_NOTICE, "icom: radio not found"); close(up->fd_icom); up->fd_icom = 0; } else { - NLOG(NLOG_SYNCEVENT | NLOG_SYSEVENT) - msyslog(LOG_NOTICE, - "icom: autotune enabled"); + msyslog(LOG_NOTICE, "icom: autotune enabled"); } } #endif /* ICOM */ @@ -674,7 +693,6 @@ */ up->seccnt = (up->seccnt + 1) % SECOND; if (up->seccnt == 0) { - pp->second = (pp->second + 1) % 60; chu_gain(peer); } } @@ -698,7 +716,7 @@ * * This routine implements a 300-baud Bell 103 modem with mark 2225 Hz * and space 2025 Hz. It uses a bandpass filter followed by a soft - * limiter, FM discriminator and lowpass filter. A maximum likelihood + * limiter, FM discriminator and lowpass filter. A maximum-likelihood * decoder samples the baseband signal at eight times the baud rate and * detects the start bit of each character. * @@ -723,7 +741,6 @@ double limit; /* limiter signal */ double disc; /* discriminator signal */ double lpf; /* lowpass signal */ - double span; /* UART signal span */ double dist; /* UART signal distance */ int i, j; @@ -732,7 +749,8 @@ /* * Bandpass filter. 4th-order elliptic, 500-Hz bandpass centered - * at 2125 Hz. Passband ripple 0.3 dB, stopband ripple 50 dB. + * at 2125 Hz. Passband ripple 0.3 dB, stopband ripple 50 dB, + * phase delay 0.24 ms. */ signal = (up->bpf[8] = up->bpf[7]) * 5.844676e-01; signal += (up->bpf[7] = up->bpf[6]) * 4.884860e-01; @@ -778,7 +796,7 @@ disc = -SQRT(-disc); /* - * Lowpass filter. Raised cosine, Ts = 1 / 300, beta = 0.1. + * Lowpass filter. Raised cosine FIR, Ts = 1 / 300, beta = 0.1. */ lpf = (up->lpf[26] = up->lpf[25]) * 2.538771e-02; lpf += (up->lpf[25] = up->lpf[24]) * 1.084671e-01; @@ -809,44 +827,68 @@ lpf += up->lpf[0] = disc * 2.538771e-02; /* - * Maximum likelihood decoder. The UART updates each of the + * Maximum-likelihood decoder. The UART updates each of the * eight survivors and determines the span, slice level and * tentative decoded character. Valid 11-bit characters are - * framed so that bit 1 and bit 11 (stop bits) are mark and bit - * 2 (start bit) is space. When a valid character is found, the + * framed so that bit 10 and bit 11 (stop bits) are mark and bit + * 1 (start bit) is space. When a valid character is found, the * survivor with maximum distance determines the final decoded * character. */ up->baud += 1. / SECOND; if (up->baud > 1. / (BAUD * 8.)) { up->baud -= 1. / (BAUD * 8.); + up->decptr = (up->decptr + 1) % 8; sp = &up->surv[up->decptr]; - span = sp->es_max - sp->es_min; - up->maxsignal += (span - up->maxsignal) / 80.; + sp->cstamp = up->timestamp; + chu_uart(sp, -lpf * AGAIN); if (up->dbrk > 0) { up->dbrk--; - } else if ((sp->uart & 0x403) == 0x401 && span > 1000.) - { - dist = 0; - j = 0; - for (i = 0; i < 8; i++) { - if (up->surv[i].dist > dist) { - dist = up->surv[i].dist; - j = i; - } + if (up->dbrk > 0) + return; + + up->decpha = up->decptr; + } + if (up->decptr != up->decpha) + return; + + dist = 0; + j = -1; + for (i = 0; i < 8; i++) { + + /* + * The timestamp is taken at the last bit, so + * for correct decoding we reqire sufficient + * span and correct start bit and two stop bits. + */ + if ((up->surv[i].uart & 0x601) != 0x600 || + up->surv[i].span < SPAN) + continue; + + if (up->surv[i].dist > dist) { + dist = up->surv[i].dist; + j = i; } - chu_decode(peer, (up->surv[j].uart >> 2) & - 0xff); - up->dbrk = 80; } - up->decptr = (up->decptr + 1) % 8; - chu_uart(sp, -lpf * AGAIN); + if (j < 0) + return; + + /* + * Process the character, then blank the decoder until + * the end of the next character.This sets the decoding + * phase of the entire burst from the phase of the first + * character. + */ + up->maxsignal = up->surv[j].span; + chu_decode(peer, (up->surv[j].uart >> 1) & 0xff, + up->surv[j].cstamp); + up->dbrk = 88; } } /* - * chu_uart - maximum likelihood UART + * chu_uart - maximum-likelihood UART * * This routine updates a shift register holding the last 11 envelope * samples. It then computes the slice level and span over these samples @@ -882,12 +924,15 @@ } /* - * Determine the slice level midway beteen the maximum and - * minimum and the span as the maximum less the minimum. Compute - * the distance on the assumption the first and last bits must - * be mark, the second space and the rest either mark or space. + * Determine the span as the maximum less the minimum and the + * slice level as the minimum plus a fraction of the span. Note + * the slight bias toward mark to correct for the modem tendency + * to make more mark than space errors. Compute the distance on + * the assumption the last two bits must be mark, the first + * space and the rest either mark or space. */ - slice = (es_max + es_min) / 2.; + sp->span = es_max - es_min; + slice = es_min + .45 * sp->span; dist = 0; sp->uart = 0; for (i = 1; i < 12; i++) { @@ -895,9 +940,9 @@ dtemp = sp->shift[i]; if (dtemp > slice) sp->uart |= 0x1; - if (i == 1 || i == 11) { + if (i == 1 || i == 2) { dist += dtemp - es_min; - } else if (i == 10) { + } else if (i == 11) { dist += es_max - dtemp; } else { if (dtemp > slice) @@ -906,9 +951,7 @@ dist += es_max - dtemp; } } - sp->es_max = es_max; - sp->es_min = es_min; - sp->dist = dist / (11 * (es_max - es_min)); + sp->dist = dist / (11 * sp->span); } #endif /* HAVE_AUDIO */ @@ -931,12 +974,8 @@ pp = peer->procptr; up = (struct chuunit *)pp->unitptr; - /* - * Initialize pointers and read the timecode and timestamp. - */ - up->timestamp = rbufp->recv_time; dpt = (u_char *)&rbufp->recv_space; - chu_decode(peer, *dpt); + chu_decode(peer, *dpt, rbufp->recv_time); } @@ -946,7 +985,8 @@ static void chu_decode( struct peer *peer, /* peer structure pointer */ - int hexhex /* data character */ + int hexhex, /* data character */ + l_fp cstamp /* data character timestamp */ ) { struct refclockproc *pp; @@ -979,11 +1019,11 @@ /* * Append the character to the current burst and append the - * timestamp to the timestamp list. + * character timestamp to the timestamp list. */ if (up->ndx < BURST) { up->cbuf[up->ndx] = hexhex & 0xff; - up->cstamp[up->ndx] = up->timestamp; + up->cstamp[up->ndx] = cstamp; up->ndx++; } @@ -1061,7 +1101,9 @@ u_char code[11]; /* decoded timecode */ char tbuf[80]; /* trace buffer */ - l_fp offset; /* timestamp offset */ + char * p; + size_t chars; + size_t cb; int i; pp = peer->procptr; @@ -1069,15 +1111,25 @@ /* * In a format B burst, a character is considered valid only if - * the first occurrence matches the last occurrence. The burst - * is considered valid only if all characters are valid; that - * is, only if the distance is 40. Note that once a valid frame - * has been found errors are ignored. - */ - sprintf(tbuf, "chuB %04x %2d %2d ", up->status, nchar, - -up->burdist); - for (i = 0; i < nchar; i++) - sprintf(&tbuf[strlen(tbuf)], "%02x", up->cbuf[i]); + * the first occurence matches the last occurence. The burst is + * considered valid only if all characters are valid; that is, + * only if the distance is 40. Note that once a valid frame has + * been found errors are ignored. + */ + snprintf(tbuf, sizeof(tbuf), "chuB %04x %4.0f %2d %2d ", + up->status, up->maxsignal, nchar, -up->burdist); + cb = sizeof(tbuf); + p = tbuf; + for (i = 0; i < nchar; i++) { + chars = strlen(p); + if (cb < chars + 1) { + msyslog(LOG_ERR, "chu_b() fatal out buffer"); + exit(1); + } + cb -= chars; + p += chars; + snprintf(p, cb, "%02x", up->cbuf[i]); + } if (pp->sloppyclockflag & CLK_FLAG4) record_clock_stats(&peer->srcadr, tbuf); #ifdef DEBUG @@ -1088,11 +1140,10 @@ up->status |= BFRAME; return; } - up->status |= BVALID; /* - * Convert the burst data to internal format. If this succeeds, - * save the timestamps for later. + * Convert the burst data to internal format. Don't bother with + * the timestamps. */ for (i = 0; i < 5; i++) { code[2 * i] = hexchar[up->cbuf[i] & 0xf]; @@ -1104,17 +1155,9 @@ up->status |= BFORMAT; return; } + up->status |= BVALID; if (up->leap & 0x8) up->dut = -up->dut; - offset.l_ui = 31; - offset.l_f = 0; - for (i = 0; i < nchar && i < 10; i++) { - up->tstamp[up->ntstamp] = up->cstamp[i]; - L_SUB(&up->tstamp[up->ntstamp], &offset); - L_ADD(&offset, &up->charstamp); - if (up->ntstamp < MAXSTAGE - 1) - up->ntstamp++; - } } @@ -1131,6 +1174,9 @@ struct chuunit *up; char tbuf[80]; /* trace buffer */ + char * p; + size_t chars; + size_t cb; l_fp offset; /* timestamp offset */ int val; /* distance */ int temp; @@ -1143,7 +1189,7 @@ * Determine correct burst phase. There are three cases * corresponding to in-phase, one character early or one * character late. These cases are distinguished by the position - * of the framing digits x6 at positions 0 and 5 and x3 at + * of the framing digits 0x6 at positions 0 and 5 and 0x3 at * positions 4 and 9. The correct phase is when the distance * relative to the framing digits is maximum. The burst is valid * only if the maximum distance is at least MINSYNC. @@ -1164,27 +1210,31 @@ k = i; } } + + /* + * Extract the second number; it must be in the range 2 through + * 9 and the two repititions must be the same. + */ temp = (up->cbuf[k + 4] >> 4) & 0xf; - if (temp > 9 || k + 9 >= nchar || temp != ((up->cbuf[k + 9] >> - 4) & 0xf)) + if (temp < 2 || temp > 9 || k + 9 >= nchar || temp != + ((up->cbuf[k + 9] >> 4) & 0xf)) temp = 0; -#ifdef HAVE_AUDIO - if (up->fd_audio) - sprintf(tbuf, "chuA %04x %4.0f %2d %2d %2d %2d %1d ", - up->status, up->maxsignal, nchar, up->burdist, k, - up->syndist, temp); - else - sprintf(tbuf, "chuA %04x %2d %2d %2d %2d %1d ", - up->status, nchar, up->burdist, k, up->syndist, - temp); - -#else - sprintf(tbuf, "chuA %04x %2d %2d %2d %2d %1d ", up->status, - nchar, up->burdist, k, up->syndist, temp); -#endif /* HAVE_AUDIO */ - for (i = 0; i < nchar; i++) - sprintf(&tbuf[strlen(tbuf)], "%02x", - up->cbuf[i]); + snprintf(tbuf, sizeof(tbuf), + "chuA %04x %4.0f %2d %2d %2d %2d %1d ", up->status, + up->maxsignal, nchar, up->burdist, k, up->syndist, + temp); + cb = sizeof(tbuf); + p = tbuf; + for (i = 0; i < nchar; i++) { + chars = strlen(p); + if (cb < chars + 1) { + msyslog(LOG_ERR, "chu_a() fatal out buffer"); + exit(1); + } + cb -= chars; + p += chars; + snprintf(p, cb, "%02x", up->cbuf[i]); + } if (pp->sloppyclockflag & CLK_FLAG4) record_clock_stats(&peer->srcadr, tbuf); #ifdef DEBUG @@ -1203,8 +1253,11 @@ * processing. In addition, the seconds decode is advanced from * the previous burst to the current one. */ - if (temp != 0) { - pp->second = 30 + temp; + if (temp == 0) { + up->status |= AFORMAT; + } else { + up->status |= AVALID; + up->second = pp->second = 30 + temp; offset.l_ui = 30 + temp; offset.l_f = 0; i = 0; @@ -1216,7 +1269,7 @@ up->tstamp[up->ntstamp] = up->cstamp[i]; L_SUB(&up->tstamp[up->ntstamp], &offset); L_ADD(&offset, &up->charstamp); - if (up->ntstamp < MAXSTAGE - 1) + if (up->ntstamp < MAXSTAGE - 1) up->ntstamp++; } while (temp > up->prevsec) { @@ -1229,6 +1282,10 @@ up->prevsec++; } } + + /* + * Stash the data in the decoding matrix. + */ i = -(2 * k); for (j = 0; j < nchar; j++) { if (i < 0 || i > 18) { @@ -1240,7 +1297,6 @@ up->decode[i][(up->cbuf[j] >> 4) & 0xf]++; i++; } - up->status |= AVALID; up->burstcnt++; } @@ -1255,6 +1311,22 @@ ) { struct refclockproc *pp; + + pp = peer->procptr; + pp->polls++; +} + + +/* + * chu_second - process minute data + */ +static void +chu_second( + int unit, + struct peer *peer /* peer structure pointer */ + ) +{ + struct refclockproc *pp; struct chuunit *up; l_fp offset; char synchar, qual, leapchar; @@ -1263,40 +1335,24 @@ pp = peer->procptr; up = (struct chuunit *)pp->unitptr; - if (pp->coderecv == pp->codeproc) - up->errflg = CEVNT_TIMEOUT; - else - pp->polls++; /* - * If once in sync and the radio has not been heard for awhile - * (30 m), it is no longer reachable. If not heard in a long - * while (one day), turn out the lights and start from scratch. + * This routine is called once per minute to process the + * accumulated burst data. We do a bit of fancy footwork so that + * this doesn't run while burst data are being accumulated. */ - minset = ((current_time - peer->update) + 30) / 60; - if (up->status & INSYNC) { - if (minset > PANIC) - up->status = 0; - else if (minset <= HOLD) - peer->reach |= 1; - } + up->second = (up->second + 1) % 60; + if (up->second != 0) + return; /* * Process the last burst, if still in the burst buffer. - * Don't mess with anything if nothing has been heard. If the - * minute contains a valid A frame and valid B frame, assume - * synchronized; however, believe the time only if within metric - * threshold. Note the quality indicator is only for - * diagnostics; the data are used only if in sync and above - * metric threshold. + * If the minute contains a valid B frame with sufficient A + * frame metric, it is considered valid. However, the timecode + * is sent to clockstats even if invalid. */ chu_burst(peer); - if (up->burstcnt == 0) { -#ifdef ICOM - chu_newchan(peer, 0); -#endif /* ICOM */ - return; - } + minset = ((current_time - peer->update) + 30) / 60; dtemp = chu_major(peer); qual = 0; if (up->status & (BFRAME | AFRAME)) @@ -1307,7 +1363,7 @@ qual |= DECERR; if (up->status & STAMP) qual |= TSPERR; - if (up->status & AVALID && up->status & BVALID) + if (up->status & BVALID && dtemp >= MINMETRIC) up->status |= INSYNC; synchar = leapchar = ' '; if (!(up->status & INSYNC)) { @@ -1322,35 +1378,20 @@ } else { pp->leap = LEAP_NOWARNING; } -#ifdef HAVE_AUDIO - if (up->fd_audio) - sprintf(pp->a_lastcode, - "%c%1X %04d %3d %02d:%02d:%02d %c%x %+d %d %d %s %.0f %d", - synchar, qual, pp->year, pp->day, pp->hour, - pp->minute, pp->second, leapchar, up->dst, up->dut, - minset, up->gain, up->ident, dtemp, up->ntstamp); - else - sprintf(pp->a_lastcode, - "%c%1X %04d %3d %02d:%02d:%02d %c%x %+d %d %s %.0f %d", - synchar, qual, pp->year, pp->day, pp->hour, - pp->minute, pp->second, leapchar, up->dst, up->dut, - minset, up->ident, dtemp, up->ntstamp); -#else - sprintf(pp->a_lastcode, - "%c%1X %04d %3d %02d:%02d:%02d %c%x %+d %d %s %.0f %d", + snprintf(pp->a_lastcode, sizeof(pp->a_lastcode), + "%c%1X %04d %03d %02d:%02d:%02d %c%x %+d %d %d %s %.0f %d", synchar, qual, pp->year, pp->day, pp->hour, pp->minute, - pp->second, leapchar, up->dst, up->dut, minset, up->ident, - dtemp, up->ntstamp); -#endif /* HAVE_AUDIO */ + pp->second, leapchar, up->dst, up->dut, minset, up->gain, + up->ident, dtemp, up->ntstamp); pp->lencode = strlen(pp->a_lastcode); /* * If in sync and the signal metric is above threshold, the * timecode is ipso fatso valid and can be selected to - * discipline the clock. Be sure not to leave stray timestamps - * around if signals are too weak or the clock time is invalid. + * discipline the clock. */ - if (up->status & INSYNC && dtemp > METRIC) { + if (up->status & INSYNC && !(up->status & (DECODE | STAMP)) && + dtemp > MINMETRIC) { if (!clocktime(pp->day, pp->hour, pp->minute, 0, GMT, up->tstamp[0].l_ui, &pp->yearstart, &offset.l_ui)) { up->errflg = CEVNT_BADTIME; @@ -1358,15 +1399,14 @@ offset.l_uf = 0; for (i = 0; i < up->ntstamp; i++) refclock_process_offset(pp, offset, - up->tstamp[i], FUDGE + + up->tstamp[i], PDELAY + pp->fudgetime1); pp->lastref = up->timestamp; refclock_receive(peer); } - record_clock_stats(&peer->srcadr, pp->a_lastcode); - } else if (pp->sloppyclockflag & CLK_FLAG4) { - record_clock_stats(&peer->srcadr, pp->a_lastcode); } + if (dtemp > 0) + record_clock_stats(&peer->srcadr, pp->a_lastcode); #ifdef DEBUG if (debug) printf("chu: timecode %d %s\n", pp->lencode, @@ -1394,8 +1434,8 @@ struct chuunit *up; u_char code[11]; /* decoded timecode */ - int mindist; /* minimum distance */ - int val1, val2; /* maximum distance */ + int metric; /* distance metric */ + int val1; /* maximum distance */ int synchar; /* stray cat */ int temp; int i, j, k; @@ -1406,54 +1446,32 @@ /* * Majority decoder. Each burst encodes two replications at each * digit position in the timecode. Each row of the decoding - * matrix encodes the number of occurrences of each digit found + * matrix encodes the number of occurences of each digit found * at the corresponding position. The maximum over all * occurrences at each position is the distance for this - * position and the corresponding digit is the maximum - * likelihood candidate. If the distance is zero, assume a miss - * '_'; if the distance is not more than half the total number - * of occurrences, assume a soft error '*'; if two different - * digits with the same distance are found, assume a hard error - * '='. These will later cause a format error when the timecode - * is interpreted. The decoding distance is defined as the - * minimum distance over the first nine digits. The tenth digit - * varies over the seconds, so we don't count it. + * position and the corresponding digit is the maximum- + * likelihood candidate. If the distance is not more than half + * the total number of occurences, a majority has not been found + * and the data are discarded. The decoding distance is defined + * as the sum of the distances over the first nine digits. The + * tenth digit varies over the seconds, so we don't count it. */ - mindist = 16; + metric = 0; for (i = 0; i < 9; i++) { - val1 = val2 = 0; + val1 = 0; k = 0; for (j = 0; j < 16; j++) { temp = up->decode[i][j] + up->decode[i + 10][j]; if (temp > val1) { - val2 = val1; val1 = temp; k = j; } } - if (val1 == 0) - code[i] = HEX_MISS; - else if (val1 == val2) - code[i] = HEX_HARD; - else if (val1 <= up->burstcnt) - code[i] = HEX_SOFT; - else - code[i] = k; - if (val1 < mindist) - mindist = val1; - code[i] = hexchar[code[i]]; + if (val1 <= up->burstcnt) + up->status |= DECODE; + metric += val1; + code[i] = hexchar[k]; } - code[i] = 0; - - /* - * A valid timecode requires a minimum distance at least half - * the total number of occurrences. A valid timecode also - * requires at least 20 valid timestamps. - */ - if (up->burstcnt < MINBURST || mindist < up->burstcnt) - up->status |= DECODE; - if (up->ntstamp < MINSTAMP) - up->status |= STAMP; /* * Compute the timecode timestamp from the days, hours and @@ -1463,15 +1481,11 @@ * for the years and does not use the years of the timecode. */ if (sscanf((char *)code, "%1x%3d%2d%2d", &synchar, &pp->day, - &pp->hour, &pp->minute) != 4) { - up->status |= AFORMAT; - return (0); - } - if (up->status & (DECODE | STAMP)) { - up->errflg = CEVNT_BADREPLY; - return (0); - } - return (mindist * 100. / (2. * up->burstcnt)); + &pp->hour, &pp->minute) != 4) + up->status |= DECODE; + if (up->ntstamp < MINSTAMP) + up->status |= STAMP; + return (metric); } @@ -1495,7 +1509,7 @@ */ up->ndx = up->prevsec = 0; up->burstcnt = up->ntstamp = 0; - up->status &= INSYNC; + up->status &= INSYNC | METRIC; for (i = 0; i < 20; i++) { for (j = 0; j < 16; j++) up->decode[i][j] = 0; @@ -1516,99 +1530,77 @@ struct chuunit *up; struct refclockproc *pp; struct xmtr *sp; - char tbuf[80]; /* trace buffer */ int rval; double metric; - int i, j; + int i; pp = peer->procptr; up = (struct chuunit *)pp->unitptr; /* * The radio can be tuned to three channels: 0 (3330 kHz), 1 - * (7335 kHz) and 2 (14670 kHz). There are five one-minute + * (7850 kHz) and 2 (14670 kHz). There are five one-minute * dwells in each cycle. During the first dwell the radio is - * tuned to one of three probe channels; during the remaining - * four dwells the radio is tuned to the data channel. The probe - * channel is selects as the least recently used. At the end of - * each dwell the channel metrics are measured and the highest - * one is selected as the data channel. + * tuned to one of the three channels to measure the channel + * metric. The channel is selected as the one least recently + * measured. During the remaining four dwells the radio is tuned + * to the channel with the highest channel metric. */ if (up->fd_icom <= 0) return (0); - sp = &up->xmtr[up->achan]; + /* + * Update the current channel metric and age of all channels. + * Scan all channels for the highest metric. + */ + sp = &up->xmtr[up->chan]; sp->metric -= sp->integ[sp->iptr]; sp->integ[sp->iptr] = met; sp->metric += sp->integ[sp->iptr]; + sp->probe = 0; sp->iptr = (sp->iptr + 1) % ISTAGE; metric = 0; - j = 0; for (i = 0; i < NCHAN; i++) { up->xmtr[i].probe++; - if (i == up->achan) - up->xmtr[i].probe = 0; - if (up->xmtr[i].metric < metric) - continue; - metric = up->xmtr[i].metric; - j = i; - } - if (j != up->chan && metric > 0) { - up->chan = j; - sprintf(tbuf, "chu: QSY to %.3f MHz metric %.0f", - qsy[up->chan], metric); - if (pp->sloppyclockflag & CLK_FLAG4) - record_clock_stats(&peer->srcadr, tbuf); -#ifdef DEBUG - if (debug) - printf("%s\n", tbuf); -#endif + if (up->xmtr[i].metric > metric) { + up->status |= METRIC; + metric = up->xmtr[i].metric; + up->chan = i; + } } /* - * Start the next dwell. We speed up the initial sync a little. - * If not in sync and no bursts were heard the previous dwell, - * restart the probe. - */ - rval = 0; - if (up->burstcnt == 0 && !(up->status & INSYNC)) - up->dwell = 0; -#ifdef DEBUG - if (debug) - printf( - "chu: at %ld dwell %d achan %d metric %.0f chan %d\n", - current_time, up->dwell, up->achan, sp->metric, - up->chan); -#endif - if (up->dwell == 0) { + * Start the next dwell. If the first dwell or no stations have + * been heard, continue round-robin scan. + */ + up->dwell = (up->dwell + 1) % DWELL; + if (up->dwell == 0 || metric == 0) { rval = 0; for (i = 0; i < NCHAN; i++) { - if (up->xmtr[i].probe < rval) - continue; - rval = up->xmtr[i].probe; - up->achan = i; - } - rval = icom_freq(up->fd_icom, peer->ttl & 0x7f, - qsy[up->achan] + TUNE); -#ifdef DEBUG - if (debug) - printf("chu: at %ld probe channel %d\n", - current_time, up->achan); -#endif - } else { - if (up->achan != up->chan) { - rval = icom_freq(up->fd_icom, peer->ttl & 0x7f, - qsy[up->chan] + TUNE); - up->achan = up->chan; + if (up->xmtr[i].probe > rval) { + rval = up->xmtr[i].probe; + up->chan = i; + } } } - sprintf(up->ident, "CHU%d", up->achan); - memcpy(&peer->refid, up->ident, 4); - up->dwell = (up->dwell + 1) % DWELL; + + /* Retune the radio at each dwell in case somebody nudges the + * tuning knob. + */ + rval = icom_freq(up->fd_icom, peer->ttl & 0x7f, qsy[up->chan] + + TUNE); + snprintf(up->ident, sizeof(up->ident), "CHU%d", up->chan); + memcpy(&pp->refid, up->ident, 4); + memcpy(&peer->refid, up->ident, 4); + if (metric == 0 && up->status & METRIC) { + up->status &= ~METRIC; + refclock_report(peer, CEVNT_PROP); + } return (rval); } #endif /* ICOM */ + /* * chu_dist - determine the distance of two octet arguments */ @@ -1645,11 +1637,12 @@ /* * chu_gain - adjust codec gain * - * This routine is called once each second. If the signal envelope - * amplitude is too low, the codec gain is bumped up by four units; if - * too high, it is bumped down. The decoder is relatively insensitive to - * amplitude, so this crudity works just fine. The input port is set and - * the error flag is cleared, mostly to be ornery. + * This routine is called at the end of each second. During the second + * the number of signal clips above the MAXAMP threshold (6000). If + * there are no clips, the gain is bumped up; if there are more than + * MAXCLP clips (100), it is bumped down. The decoder is relatively + * insensitive to amplitude, so this crudity works just peachy. The + * routine also jiggles the input port and selectively mutes the */ static void chu_gain( diff -urN src/contrib/ntp/ntpd/refclock_conf.c src.ntp/contrib/ntp/ntpd/refclock_conf.c --- src/contrib/ntp/ntpd/refclock_conf.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_conf.c 2009-12-09 08:36:36.000000000 +0100 @@ -138,7 +138,7 @@ #define refclock_nmea refclock_none #endif -#ifdef CLOCK_ATOM +#if defined (CLOCK_ATOM) && defined(HAVE_PPSAPI) extern struct refclock refclock_atom; #else #define refclock_atom refclock_none diff -urN src/contrib/ntp/ntpd/refclock_datum.c src.ntp/contrib/ntp/ntpd/refclock_datum.c --- src/contrib/ntp/ntpd/refclock_datum.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_datum.c 2009-12-09 08:36:36.000000000 +0100 @@ -173,13 +173,13 @@ ** Callback function prototypes that ntpd needs to know about. */ -static int datum_pts_start P((int, struct peer *)); -static void datum_pts_shutdown P((int, struct peer *)); -static void datum_pts_poll P((int, struct peer *)); -static void datum_pts_control P((int, struct refclockstat *, - struct refclockstat *, struct peer *)); -static void datum_pts_init P((void)); -static void datum_pts_buginfo P((int, struct refclockbug *, struct peer *)); +static int datum_pts_start (int, struct peer *); +static void datum_pts_shutdown (int, struct peer *); +static void datum_pts_poll (int, struct peer *); +static void datum_pts_control (int, struct refclockstat *, + struct refclockstat *, struct peer *); +static void datum_pts_init (void); +static void datum_pts_buginfo (int, struct refclockbug *, struct peer *); /* ** This is the call back function structure that ntpd actually uses for @@ -219,7 +219,7 @@ ** the adjtime() call. */ -static void datum_pts_receive P((struct recvbuf *)); +static void datum_pts_receive (struct recvbuf *); /*......................................................................*/ /* datum_pts_start - start up the datum PTS. This means open the */ @@ -259,13 +259,13 @@ */ temp_datum_pts_unit = (struct datum_pts_unit **) - malloc((nunits+1)*sizeof(struct datum_pts_unit *)); + emalloc((nunits+1)*sizeof(struct datum_pts_unit *)); if (nunits > 0) memcpy(temp_datum_pts_unit, datum_pts_unit, nunits*sizeof(struct datum_pts_unit *)); free(datum_pts_unit); datum_pts_unit = temp_datum_pts_unit; datum_pts_unit[nunits] = (struct datum_pts_unit *) - malloc(sizeof(struct datum_pts_unit)); + emalloc(sizeof(struct datum_pts_unit)); datum_pts = datum_pts_unit[nunits]; datum_pts->unit = unit; /* set my unit id */ @@ -292,6 +292,8 @@ #ifdef HAVE_TERMIOS + memset(&arg, 0, sizeof(arg)); + arg.c_iflag = IGNBRK; arg.c_oflag = 0; arg.c_cflag = B9600 | CS8 | CREAD | PARENB | CLOCAL; @@ -395,7 +397,7 @@ if (nunits > 1) { temp_datum_pts_unit = (struct datum_pts_unit **) - malloc((nunits-1)*sizeof(struct datum_pts_unit *)); + emalloc((nunits-1)*sizeof(struct datum_pts_unit *)); if (i!= 0) memcpy(temp_datum_pts_unit, datum_pts_unit, i*sizeof(struct datum_pts_unit *)); diff -urN src/contrib/ntp/ntpd/refclock_dumbclock.c src.ntp/contrib/ntp/ntpd/refclock_dumbclock.c --- src/contrib/ntp/ntpd/refclock_dumbclock.c 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/refclock_dumbclock.c 2010-02-16 12:18:00.000000000 +0100 @@ -35,7 +35,7 @@ * * Input format: * - * hh:mm:ss + * hh:mm:ss * * hh:mm:ss -- what you'd expect, with a 24 hour clock. (Heck, that's the only * way it could get stupider.) We take time on the . @@ -64,21 +64,21 @@ * Dumb clock control structure */ struct dumbclock_unit { - u_char tcswitch; /* timecode switch */ - l_fp laststamp; /* last receive timestamp */ - u_char lasthour; /* last hour (for monitor) */ - u_char linect; /* count ignored lines (for monitor */ - struct tm ymd; /* struct tm for y/m/d only */ + u_char tcswitch; /* timecode switch */ + l_fp laststamp; /* last receive timestamp */ + u_char lasthour; /* last hour (for monitor) */ + u_char linect; /* count ignored lines (for monitor */ + struct tm ymd; /* struct tm for y/m/d only */ }; /* * Function prototypes */ -static int dumbclock_start P((int, struct peer *)); -static void dumbclock_shutdown P((int, struct peer *)); -static void dumbclock_receive P((struct recvbuf *)); +static int dumbclock_start (int, struct peer *); +static void dumbclock_shutdown (int, struct peer *); +static void dumbclock_receive (struct recvbuf *); #if 0 -static void dumbclock_poll P((int, struct peer *)); +static void dumbclock_poll (int, struct peer *); #endif /* @@ -115,24 +115,20 @@ * Open serial port. Don't bother with CLK line discipline, since * it's not available. */ - (void)sprintf(device, DEVICE, unit); + snprintf(device, sizeof(device), DEVICE, unit); #ifdef DEBUG if (debug) printf ("starting Dumbclock with device %s\n",device); #endif fd = refclock_open(device, SPEED232, 0); - if (fd < 0) + if (!fd) return (0); /* * Allocate and initialize unit structure */ - up = (struct dumbclock_unit *)emalloc(sizeof(struct dumbclock_unit)); - if (up == NULL) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct dumbclock_unit)); + up = emalloc(sizeof(*up)); + memset(up, 0, sizeof(*up)); pp = peer->procptr; pp->unitptr = (caddr_t)up; pp->io.clock_recv = dumbclock_receive; @@ -140,8 +136,10 @@ pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + close(fd); + pp->io.fd = -1; free(up); + pp->unitptr = NULL; return (0); } @@ -153,14 +151,10 @@ tm_time_p = gmtime(&now); #endif if (tm_time_p) - { - up->ymd = *tm_time_p; - } + up->ymd = *tm_time_p; else - { - return 0; - } - + return 0; + /* * Initialize miscellaneous variables */ @@ -185,8 +179,10 @@ pp = peer->procptr; up = (struct dumbclock_unit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } @@ -202,12 +198,12 @@ struct refclockproc *pp; struct peer *peer; - l_fp trtmp; /* arrival timestamp */ - int hours; /* hour-of-day */ - int minutes; /* minutes-past-the-hour */ - int seconds; /* seconds */ - int temp; /* int temp */ - int got_good; /* got a good time flag */ + l_fp trtmp; /* arrival timestamp */ + int hours; /* hour-of-day */ + int minutes; /* minutes-past-the-hour */ + int seconds; /* seconds */ + int temp; /* int temp */ + int got_good; /* got a good time flag */ /* * Initialize pointers and read the timecode and timestamp @@ -222,7 +218,7 @@ up->tcswitch = 1; up->laststamp = trtmp; } else - up->tcswitch = 0; + up->tcswitch = 0; return; } pp->lencode = (u_short)temp; @@ -249,16 +245,18 @@ struct tm asserted_tm; /* the struct tm of the same */ int adjyear; int adjmon; - int reality_delta; + time_t reality_delta; time_t now; /* * Convert to GMT for sites that distribute localtime. This - * means we have to figure out what day it is. Easier said + * means we have to figure out what day it is. Easier said * than done... */ + memset(&asserted_tm, 0, sizeof(asserted_tm)); + asserted_tm.tm_year = up->ymd.tm_year; asserted_tm.tm_mon = up->ymd.tm_mon; asserted_tm.tm_mday = up->ymd.tm_mday; @@ -383,4 +381,4 @@ #else int refclock_dumbclock_bs; -#endif /* REFCLOCK */ +#endif /* defined(REFCLOCK) && defined(CLOCK_DUMBCLOCK) */ diff -urN src/contrib/ntp/ntpd/refclock_fg.c src.ntp/contrib/ntp/ntpd/refclock_fg.c --- src/contrib/ntp/ntpd/refclock_fg.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_fg.c 2009-12-09 08:36:35.000000000 +0100 @@ -33,11 +33,11 @@ /* * Function prototypes */ -static int fg_init P((int)); -static int fg_start P((int, struct peer *)); -static void fg_shutdown P((int, struct peer *)); -static void fg_poll P((int, struct peer *)); -static void fg_receive P((struct recvbuf *)); +static int fg_init (int); +static int fg_start (int, struct peer *); +static void fg_shutdown (int, struct peer *); +static void fg_poll (int, struct peer *); +static void fg_receive (struct recvbuf *); /* * Forum Graphic unit control structure diff -urN src/contrib/ntp/ntpd/refclock_gpsvme.c src.ntp/contrib/ntp/ntpd/refclock_gpsvme.c --- src/contrib/ntp/ntpd/refclock_gpsvme.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_gpsvme.c 2010-02-04 08:26:52.000000000 +0100 @@ -104,13 +104,9 @@ return 0; } - if (!up) { - msyslog(LOG_ERR, "psc_start: unit: %d, emalloc: %m", unit); - return 0; - } memset(up, '\0', sizeof *up); - sprintf(buf, DEVICE, unit); /* dev file name */ + snprintf(buf, sizeof(buf), DEVICE, unit); /* dev file name */ fd[unit] = open(buf, O_RDONLY); /* open device file */ if (fd[unit] < 0) { msyslog(LOG_ERR, "psc_start: unit: %d, open failed. %m", unit); @@ -131,7 +127,7 @@ pp->io.fd = -1; pp->unitptr = (caddr_t) up; get_systime(&pp->lastrec); - memcpy((char *)&pp->refid, REFID, 4); + memcpy(&pp->refid, REFID, 4); peer->precision = PRECISION; pp->clockdesc = DESCRIPTION; up->unit = unit; @@ -149,8 +145,10 @@ struct peer *peer ) { - free(peer->procptr->unitptr); - close(fd[unit]); + if (NULL != peer->procptr->unitptr) + free(peer->procptr->unitptr); + if (fd[unit] > 0) + close(fd[unit]); } /* psc_poll: read, decode, and record device time */ @@ -196,9 +194,10 @@ pp->nsec = 1000000*BCD2INT3((tlo & 0x00FFF000) >> 12) + BCD2INT3(tlo & 0x00000FFF); - sprintf(pp->a_lastcode, "%3.3d %2.2d:%2.2d:%2.2d.%09ld %02x %08x %08x", - pp->day, pp->hour, pp->minute, pp->second, pp->nsec, status, thi, - tlo); + snprintf(pp->a_lastcode, sizeof(pp->a_lastcode), + "%3.3d %2.2d:%2.2d:%2.2d.%09ld %02x %08x %08x", pp->day, + pp->hour, pp->minute, pp->second, pp->nsec, status, thi, + tlo); pp->lencode = strlen(pp->a_lastcode); /* compute the timecode timestamp */ diff -urN src/contrib/ntp/ntpd/refclock_heath.c src.ntp/contrib/ntp/ntpd/refclock_heath.c --- src/contrib/ntp/ntpd/refclock_heath.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_heath.c 2010-02-04 08:26:50.000000000 +0100 @@ -186,10 +186,10 @@ /* * Function prototypes */ -static int heath_start P((int, struct peer *)); -static void heath_shutdown P((int, struct peer *)); -static void heath_receive P((struct recvbuf *)); -static void heath_poll P((int, struct peer *)); +static int heath_start (int, struct peer *); +static void heath_shutdown (int, struct peer *); +static void heath_receive (struct recvbuf *); +static void heath_poll (int, struct peer *); /* * Transfer vector @@ -221,7 +221,7 @@ /* * Open serial port */ - sprintf(device, DEVICE, unit); + snprintf(device, sizeof(device), DEVICE, unit); if (!(fd = refclock_open(device, speed[peer->ttl & 0x3], LDISC_REMOTE))) return (0); @@ -231,7 +231,8 @@ pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + close(fd); + pp->io.fd = -1; return (0); } @@ -241,7 +242,7 @@ peer->precision = PRECISION; peer->burst = NSTAGE; pp->clockdesc = DESCRIPTION; - memcpy((char *)&pp->refid, REFID, 4); + memcpy(&pp->refid, REFID, 4); return (1); } @@ -258,7 +259,8 @@ struct refclockproc *pp; pp = peer->procptr; - io_closeclock(&pp->io); + if (-1 != pp->io.fd) + io_closeclock(&pp->io); } diff -urN src/contrib/ntp/ntpd/refclock_hopfpci.c src.ntp/contrib/ntp/ntpd/refclock_hopfpci.c --- src/contrib/ntp/ntpd/refclock_hopfpci.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_hopfpci.c 2010-02-04 08:26:51.000000000 +0100 @@ -124,24 +124,17 @@ /* * Allocate and initialize unit structure */ - up = (struct hopfclock_unit *) emalloc(sizeof(struct hopfclock_unit)); - - if (!(up)) { - msyslog(LOG_ERR, "hopfPCIClock(%d) emalloc: %m",unit); -#ifdef DEBUG - printf("hopfPCIClock(%d) emalloc\n",unit); -#endif - return (0); - } - memset((char *)up, 0, sizeof(struct hopfclock_unit)); + up = emalloc(sizeof(*up)); + memset(up, 0, sizeof(*up)); #ifndef SYS_WINNT fd = open(DEVICE,O_RDWR); /* try to open hopf clock device */ #else - if (!OpenHopfDevice()){ - msyslog(LOG_ERR,"Start: %s unit: %d failed!",DEVICE,unit); + if (!OpenHopfDevice()) { + msyslog(LOG_ERR, "Start: %s unit: %d failed!", DEVICE, unit); + free(up); return (0); } #endif @@ -158,17 +151,12 @@ /* * Initialize miscellaneous peer variables */ - if (pp->unitptr!=0) { - memcpy((char *)&pp->refid, REFID, 4); - peer->precision = PRECISION; - pp->clockdesc = DESCRIPTION; - up->leap_status = 0; - up->unit = (short) unit; - return (1); - } - else { - return 0; - } + memcpy((char *)&pp->refid, REFID, 4); + peer->precision = PRECISION; + pp->clockdesc = DESCRIPTION; + up->leap_status = 0; + up->unit = (short) unit; + return (1); } @@ -187,6 +175,8 @@ #else CloseHopfDevice(); #endif + if (NULL != peer->procptr->unitptr) + free(peer->procptr->unitptr); } @@ -221,9 +211,11 @@ else pp->leap = LEAP_NOWARNING; - sprintf(pp->a_lastcode,"ST: %02X T: %02d:%02d:%02d.%03ld D: %02d.%02d.%04d", - m_time.wStatus, pp->hour, pp->minute, pp->second, - pp->nsec / 1000000, m_time.wDay, m_time.wMonth, m_time.wYear); + snprintf(pp->a_lastcode, sizeof(pp->a_lastcode), + "ST: %02X T: %02d:%02d:%02d.%03ld D: %02d.%02d.%04d", + m_time.wStatus, pp->hour, pp->minute, pp->second, + pp->nsec / 1000000, m_time.wDay, m_time.wMonth, + m_time.wYear); pp->lencode = (u_short)strlen(pp->a_lastcode); get_systime(&pp->lastrec); diff -urN src/contrib/ntp/ntpd/refclock_hopfser.c src.ntp/contrib/ntp/ntpd/refclock_hopfser.c --- src/contrib/ntp/ntpd/refclock_hopfser.c 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/refclock_hopfser.c 2010-02-04 08:26:59.000000000 +0100 @@ -95,11 +95,11 @@ * Function prototypes */ -static int hopfserial_start P((int, struct peer *)); -static void hopfserial_shutdown P((int, struct peer *)); -static void hopfserial_receive P((struct recvbuf *)); -static void hopfserial_poll P((int, struct peer *)); -/* static void hopfserial_io P((struct recvbuf *)); */ +static int hopfserial_start (int, struct peer *); +static void hopfserial_shutdown (int, struct peer *); +static void hopfserial_receive (struct recvbuf *); +static void hopfserial_poll (int, struct peer *); +/* static void hopfserial_io (struct recvbuf *); */ /* * Transfer vector */ @@ -127,11 +127,8 @@ int fd; char gpsdev[20]; -#ifdef SYS_WINNT - (void) sprintf(gpsdev, "COM%d:", unit); -#else - (void) sprintf(gpsdev, DEVICE, unit); -#endif + snprintf(gpsdev, sizeof(gpsdev), DEVICE, unit); + /* LDISC_STD, LDISC_RAW * Open serial port. Use CLK line discipline, if available. */ @@ -149,18 +146,8 @@ /* * Allocate and initialize unit structure */ - up = (struct hopfclock_unit *) emalloc(sizeof(struct hopfclock_unit)); - - if (!(up)) { - msyslog(LOG_ERR, "hopfSerialClock(%d) emalloc: %m",unit); -#ifdef DEBUG - printf("hopfSerialClock(%d) emalloc\n",unit); -#endif - (void) close(fd); - return (0); - } - - memset((char *)up, 0, sizeof(struct hopfclock_unit)); + up = emalloc(sizeof(*up)); + memset(up, 0, sizeof(*up)); pp = peer->procptr; pp->unitptr = (caddr_t)up; pp->io.clock_recv = hopfserial_receive; @@ -169,10 +156,12 @@ pp->io.fd = fd; if (!io_addclock(&pp->io)) { #ifdef DEBUG - printf("hopfSerialClock(%d) io_addclock\n",unit); + printf("hopfSerialClock(%d) io_addclock\n", unit); #endif - (void) close(fd); + close(fd); + pp->io.fd = -1; free(up); + pp->unitptr = NULL; return (0); } @@ -205,8 +194,11 @@ pp = peer->procptr; up = (struct hopfclock_unit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } @@ -292,7 +284,7 @@ /* preparation for timecode ntpq rl command ! */ #if 0 - wsprintf(pp->a_lastcode, + snprintf(pp->a_lastcode, sizeof(pp->a_lastcode), "STATUS: %1X%1X, DATE: %02d.%02d.%04d TIME: %02d:%02d:%02d", synch, DoW, diff -urN src/contrib/ntp/ntpd/refclock_hpgps.c src.ntp/contrib/ntp/ntpd/refclock_hpgps.c --- src/contrib/ntp/ntpd/refclock_hpgps.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_hpgps.c 2010-02-04 08:26:55.000000000 +0100 @@ -125,10 +125,10 @@ /* * Function prototypes */ -static int hpgps_start P((int, struct peer *)); -static void hpgps_shutdown P((int, struct peer *)); -static void hpgps_receive P((struct recvbuf *)); -static void hpgps_poll P((int, struct peer *)); +static int hpgps_start (int, struct peer *); +static void hpgps_shutdown (int, struct peer *); +static void hpgps_receive (struct recvbuf *); +static void hpgps_poll (int, struct peer *); /* * Transfer vector @@ -162,7 +162,7 @@ * Open serial port. Use CLK line discipline, if available. * Default is HP 58503A, mode arg selects HP Z3801A */ - (void)sprintf(device, DEVICE, unit); + snprintf(device, sizeof(device), DEVICE, unit); /* mode parameter to server config line shares ttl slot */ if ((peer->ttl == 1)) { if (!(fd = refclock_open(device, SPEED232Z, @@ -175,19 +175,16 @@ /* * Allocate and initialize unit structure */ - if (!(up = (struct hpgpsunit *) - emalloc(sizeof(struct hpgpsunit)))) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct hpgpsunit)); + up = emalloc(sizeof(*up)); + memset(up, 0, sizeof(*up)); pp = peer->procptr; pp->io.clock_recv = hpgps_receive; pp->io.srcclock = (caddr_t)peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + close(fd); + pp->io.fd = -1; free(up); return (0); } @@ -232,8 +229,10 @@ pp = peer->procptr; up = (struct hpgpsunit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } @@ -532,18 +531,25 @@ pp->leap = LEAP_NOTINSYNC; } else { + pp->leap = LEAP_NOWARNING; switch (leapchar) { - case '+': - pp->leap = LEAP_ADDSECOND; + case '0': break; - case '0': - pp->leap = LEAP_NOWARNING; + /* See http://bugs.ntp.org/1090 + * Ignore leap announcements unless June or December. + * Better would be to use :GPSTime? to find the month, + * but that seems too likely to introduce other bugs. + */ + case '+': + if ((month==6) || (month==12)) + pp->leap = LEAP_ADDSECOND; break; case '-': - pp->leap = LEAP_DELSECOND; + if ((month==6) || (month==12)) + pp->leap = LEAP_DELSECOND; break; default: diff -urN src/contrib/ntp/ntpd/refclock_irig.c src.ntp/contrib/ntp/ntpd/refclock_irig.c --- src/contrib/ntp/ntpd/refclock_irig.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_irig.c 2010-07-07 12:01:06.000000000 +0200 @@ -25,27 +25,36 @@ /* * Audio IRIG-B/E demodulator/decoder * - * This driver receives, demodulates and decodes IRIG-B/E signals when - * connected to the audio codec /dev/audio. The IRIG signal format is an - * amplitude-modulated carrier with pulse-width modulated data bits. For - * IRIG-B, the carrier frequency is 1000 Hz and bit rate 100 b/s; for - * IRIG-E, the carrier frequenchy is 100 Hz and bit rate 10 b/s. The - * driver automatically recognizes which format is in use. + * This driver synchronizes the computer time using data encoded in + * IRIG-B/E signals commonly produced by GPS receivers and other timing + * devices. The IRIG signal is an amplitude-modulated carrier with + * pulse-width modulated data bits. For IRIG-B, the carrier frequency is + * 1000 Hz and bit rate 100 b/s; for IRIG-E, the carrier frequenchy is + * 100 Hz and bit rate 10 b/s. The driver automatically recognizes which + & format is in use. + * + * The driver requires an audio codec or sound card with sampling rate 8 + * kHz and mu-law companding. This is the same standard as used by the + * telephone industry and is supported by most hardware and operating + * systems, including Solaris, SunOS, FreeBSD, NetBSD and Linux. In this + * implementation, only one audio driver and codec can be supported on a + * single machine. * * The program processes 8000-Hz mu-law companded samples using separate * signal filters for IRIG-B and IRIG-E, a comb filter, envelope * detector and automatic threshold corrector. Cycle crossings relative * to the corrected slice level determine the width of each pulse and - * its value - zero, one or position identifier. The data encode 20 BCD - * digits which determine the second, minute, hour and day of the year - * and sometimes the year and synchronization condition. The comb filter - * exponentially averages the corresponding samples of successive baud - * intervals in order to reliably identify the reference carrier cycle. - * A type-II phase-lock loop (PLL) performs additional integration and - * interpolation to accurately determine the zero crossing of that - * cycle, which determines the reference timestamp. A pulse-width - * discriminator demodulates the data pulses, which are then encoded as - * the BCD digits of the timecode. + * its value - zero, one or position identifier. + * + * The data encode 20 BCD digits which determine the second, minute, + * hour and day of the year and sometimes the year and synchronization + * condition. The comb filter exponentially averages the corresponding + * samples of successive baud intervals in order to reliably identify + * the reference carrier cycle. A type-II phase-lock loop (PLL) performs + * additional integration and interpolation to accurately determine the + * zero crossing of that cycle, which determines the reference + * timestamp. A pulse-width discriminator demodulates the data pulses, + * which are then encoded as the BCD digits of the timecode. * * The timecode and reference timestamp are updated once each second * with IRIG-B (ten seconds with IRIG-E) and local clock offset samples @@ -60,70 +69,60 @@ * decompanded input signal amplitude must be greater than 100 units and * the codec sample frequency error less than 250 PPM (.025 percent). * - * The program performs a number of error checks to protect against - * overdriven or underdriven input signal levels, incorrect signal - * format or improper hardware configuration. Specifically, if any of - * the following errors occur for a time measurement, the data are - * rejected. - * - * o The peak carrier amplitude is less than DRPOUT (100). This usually - * means dead IRIG signal source, broken cable or wrong input port. - * - * o The frequency error is greater than MAXFREQ +-250 PPM (.025%). This - * usually means broken codec hardware or wrong codec configuration. - * - * o The modulation index is less than MODMIN (0.5). This usually means - * overdriven IRIG signal or wrong IRIG format. - * - * o A frame synchronization error has occurred. This usually means - * wrong IRIG signal format or the IRIG signal source has lost - * synchronization (signature control). - * - * o A data decoding error has occurred. This usually means wrong IRIG - * signal format. - * - * o The current second of the day is not exactly one greater than the - * previous one. This usually means a very noisy IRIG signal or - * insufficient CPU resources. - * - * o An audio codec error (overrun) occurred. This usually means - * insufficient CPU resources, as sometimes happens with Sun SPARC - * IPCs when doing something useful. - * - * Note that additional checks are done elsewhere in the reference clock - * interface routines. - * - * Debugging aids + * Monitor Data * * The timecode format used for debugging and data recording includes * data helpful in diagnosing problems with the IRIG signal and codec - * connections. With debugging enabled (-d on the ntpd command line), - * the driver produces one line for each timecode in the following - * format: - * - * 00 1 98 23 19:26:52 721 143 0.694 20 0.1 66.5 3094572411.00027 - * - * The most recent line is also written to the clockstats file at 64-s - * intervals. - * - * The first field contains the error flags in hex, where the hex bits - * are interpreted as below. This is followed by the IRIG status - * indicator, year of century, day of year and time of day. The status - * indicator and year are not produced by some IRIG devices. Following - * these fields are the signal amplitude (0-8100), codec gain (0-255), - * modulation index (0-1), time constant (2-20), carrier phase error - * (us) and carrier frequency error (PPM). The last field is the on-time - * timestamp in NTP format. - * - * The fraction part of the on-time timestamp is a good indicator of how - * well the driver is doing. Once upon a time, an UltrSPARC 30 and - * Solaris 2.7 kept the clock within a few tens of microseconds relative - * to the IRIG-B signal. Accuracy with IRIG-E was about ten times worse. - * Unfortunately, Sun broke the 2.7 audio driver in 2.8, which has a 10- - * ms sawtooth modulation. The driver attempts to remove the modulation - * by some clever estimation techniques which mostly work. With the - * "mixerctl -o" command before starting the daemon, the jitter is down - * to about 100 microseconds. Your experience may vary. + * connections. The driver produces one line for each timecode in the + * following format: + * + * 00 00 98 23 19:26:52 2782 143 0.694 10 0.3 66.5 3094572411.00027 + * + * If clockstats is enabled, the most recent line is written to the + * clockstats file every 64 s. If verbose recording is enabled (fudge + * flag 4) each line is written as generated. + * + * The first field containes the error flags in hex, where the hex bits + * are interpreted as below. This is followed by the year of century, + * day of year and time of day. Note that the time of day is for the + * previous minute, not the current time. The status indicator and year + * are not produced by some IRIG devices and appear as zeros. Following + * these fields are the carrier amplitude (0-3000), codec gain (0-255), + * modulation index (0-1), time constant (4-10), carrier phase error + * +-.5) and carrier frequency error (PPM). The last field is the on- + * time timestamp in NTP format. + * + * The error flags are defined as follows in hex: + * + * x01 Low signal. The carrier amplitude is less than 100 units. This + * is usually the result of no signal or wrong input port. + * x02 Frequency error. The codec frequency error is greater than 250 + * PPM. This may be due to wrong signal format or (rarely) + * defective codec. + * x04 Modulation error. The IRIG modulation index is less than 0.5. + * This is usually the result of an overdriven codec, wrong signal + * format or wrong input port. + * x08 Frame synch error. The decoder frame does not match the IRIG + * frame. This is usually the result of an overdriven codec, wrong + * signal format or noisy IRIG signal. It may also be the result of + * an IRIG signature check which indicates a failure of the IRIG + * signal synchronization source. + * x10 Data bit error. The data bit length is out of tolerance. This is + * usually the result of an overdriven codec, wrong signal format + * or noisy IRIG signal. + * x20 Seconds numbering discrepancy. The decoder second does not match + * the IRIG second. This is usually the result of an overdriven + * codec, wrong signal format or noisy IRIG signal. + * x40 Codec error (overrun). The machine is not fast enough to keep up + * with the codec. + * x80 Device status error (Spectracom). + * + * + * Once upon a time, an UltrSPARC 30 and Solaris 2.7 kept the clock + * within a few tens of microseconds relative to the IRIG-B signal. + * Accuracy with IRIG-E was about ten times worse. Unfortunately, Sun + * broke the 2.7 audio driver in 2.8, which has a 10-ms sawtooth + * modulation. * * Unlike other drivers, which can have multiple instantiations, this * one supports only one. It does not seem likely that more than one @@ -137,8 +136,13 @@ * port, where 0 is the mike port (default) and 1 is the line-in port. * It does not seem useful to select the compact disc player port. Fudge * flag3 enables audio monitoring of the input signal. For this purpose, - * the monitor gain is set to a default value. Fudgetime2 is used as a + * the monitor gain is set t a default value. Fudgetime2 is used as a * frequency vernier for broken codec sample frequency. + * + * Alarm codes + * + * CEVNT_BADTIME invalid date or time + * CEVNT_TIMEOUT no IRIG data since last poll */ /* * Interface definitions @@ -152,26 +156,30 @@ #define BAUD 80 /* samples per baud interval */ #define OFFSET 128 /* companded sample offset */ #define SIZE 256 /* decompanding table size */ -#define CYCLE 8 /* samples per carrier cycle */ -#define SUBFLD 10 /* bits per subfield */ -#define FIELD 10 /* subfields per field */ +#define CYCLE 8 /* samples per bit */ +#define SUBFLD 10 /* bits per frame */ +#define FIELD 100 /* bits per second */ #define MINTC 2 /* min PLL time constant */ -#define MAXTC 20 /* max PLL time constant max */ -#define MAXAMP 6000. /* maximum signal level */ -#define MAXCLP 100 /* max clips above reference per s */ -#define DRPOUT 100. /* dropout signal level */ +#define MAXTC 10 /* max PLL time constant max */ +#define MAXAMP 3000. /* maximum signal amplitude */ +#define MINAMP 2000. /* minimum signal amplitude */ +#define DRPOUT 100. /* dropout signal amplitude */ #define MODMIN 0.5 /* minimum modulation index */ #define MAXFREQ (250e-6 * SECOND) /* freq tolerance (.025%) */ -#define PI 3.1415926535 /* the real thing */ -#ifdef IRIG_SUCKS -#define WIGGLE 11 /* wiggle filter length */ -#endif /* IRIG_SUCKS */ /* - * Experimentally determined filter delays + * The on-time synchronization point is the positive-going zero crossing + * of the first cycle of the second. The IIR baseband filter phase delay + * is 1.03 ms for IRIG-B and 3.47 ms for IRIG-E. The fudge value 2.68 ms + * due to the codec and other causes was determined by calibrating to a + * PPS signal from a GPS receiver. + * + * The results with a 2.4-GHz P4 running FreeBSD 6.1 are generally + * within .02 ms short-term with .02 ms jitter. The processor load due + * to the driver is 0.51 percent. */ -#define IRIG_B .0019 /* IRIG-B filter delay */ -#define IRIG_E .0019 /* IRIG-E filter delay */ +#define IRIG_B ((1.03 + 2.68) / 1000) /* IRIG-B system delay (s) */ +#define IRIG_E ((3.47 + 2.68) / 1000) /* IRIG-E system delay (s) */ /* * Data bit definitions @@ -181,7 +189,7 @@ #define BITP 2 /* position identifier */ /* - * Error flags (up->errflg) + * Error flags */ #define IRIG_ERR_AMP 0x01 /* low carrier amplitude */ #define IRIG_ERR_FREQ 0x02 /* frequency tolerance exceeded */ @@ -192,13 +200,18 @@ #define IRIG_ERR_ERROR 0x40 /* codec error (overrun) */ #define IRIG_ERR_SIGERR 0x80 /* IRIG status error (Spectracom) */ +static char hexchar[] = "0123456789abcdef"; + /* * IRIG unit control structure */ struct irigunit { - u_char timecode[21]; /* timecode string */ + u_char timecode[2 * SUBFLD + 1]; /* timecode string */ l_fp timestamp; /* audio sample timestamp */ l_fp tick; /* audio sample increment */ + l_fp refstamp; /* reference timestamp */ + l_fp chrstamp; /* baud timestamp */ + l_fp prvstamp; /* previous baud timestamp */ double integ[BAUD]; /* baud integrator */ double phase, freq; /* logical clock phase and frequency */ double zxing; /* phase detector integrator */ @@ -212,20 +225,20 @@ * Audio codec variables */ double comp[SIZE]; /* decompanding table */ + double signal; /* peak signal for AGC */ int port; /* codec port */ int gain; /* codec gain */ int mongain; /* codec monitor gain */ - int clipcnt; /* sample clipped count */ int seccnt; /* second interval counter */ /* * RF variables */ - double hpf[5]; /* IRIG-B filter shift register */ + double bpf[9]; /* IRIG-B filter shift register */ double lpf[5]; /* IRIG-E filter shift register */ + double envmin, envmax; /* envelope min and max */ + double slice; /* envelope slice level */ double intmin, intmax; /* integrated envelope min and max */ - double envmax; /* peak amplitude */ - double envmin; /* noise amplitude */ double maxsignal; /* integrated peak amplitude */ double noise; /* integrated noise amplitude */ double lastenv[CYCLE]; /* last cycle amplitudes */ @@ -235,7 +248,6 @@ int decim; /* sample decimation factor */ int envphase; /* envelope phase */ int envptr; /* envelope phase pointer */ - int carphase; /* carrier phase */ int envsw; /* envelope state */ int envxing; /* envelope slice crossing */ int tc; /* time constant */ @@ -248,36 +260,30 @@ int pulse; /* cycle counter */ int cycles; /* carrier cycles */ int dcycles; /* data cycles */ - int xptr; /* translate table pointer */ - int lastbit; /* last code element length */ + int lastbit; /* last code element */ int second; /* previous second */ - int fieldcnt; /* subfield count in field */ + int bitcnt; /* bit count in frame */ + int frmcnt; /* bit count in second */ + int xptr; /* timecode pointer */ int bits; /* demodulated bits */ - int bitcnt; /* bit count in subfield */ -#ifdef IRIG_SUCKS - l_fp wigwag; /* wiggle accumulator */ - int wp; /* wiggle filter pointer */ - l_fp wiggle[WIGGLE]; /* wiggle filter */ - l_fp wigbot[WIGGLE]; /* wiggle bottom fisher*/ -#endif /* IRIG_SUCKS */ - l_fp wuggle; }; /* * Function prototypes */ -static int irig_start P((int, struct peer *)); -static void irig_shutdown P((int, struct peer *)); -static void irig_receive P((struct recvbuf *)); -static void irig_poll P((int, struct peer *)); +static int irig_start (int, struct peer *); +static void irig_shutdown (int, struct peer *); +static void irig_receive (struct recvbuf *); +static void irig_poll (int, struct peer *); /* * More function prototypes */ -static void irig_base P((struct peer *, double)); -static void irig_rf P((struct peer *, double)); -static void irig_decode P((struct peer *, int)); -static void irig_gain P((struct peer *)); +static void irig_base (struct peer *, double); +static void irig_rf (struct peer *, double); +static void irig_baud (struct peer *, int); +static void irig_decode (struct peer *, int); +static void irig_gain (struct peer *); /* * Transfer vector @@ -292,16 +298,6 @@ NOFLAGS /* not used */ }; -/* - * Global variables - */ -static char hexchar[] = { /* really quick decoding table */ - '0', '8', '4', 'c', /* 0000 0001 0010 0011 */ - '2', 'a', '6', 'e', /* 0100 0101 0110 0111 */ - '1', '9', '5', 'd', /* 1000 1001 1010 1011 */ - '3', 'b', '7', 'f' /* 1100 1101 1110 1111 */ -}; - /* * irig_start - open the devices and initialize data for processing @@ -336,12 +332,8 @@ /* * Allocate and initialize unit structure */ - if (!(up = (struct irigunit *) - emalloc(sizeof(struct irigunit)))) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct irigunit)); + up = emalloc(sizeof(*up)); + memset(up, 0, sizeof(*up)); pp = peer->procptr; pp->unitptr = (caddr_t)up; pp->io.clock_recv = irig_receive; @@ -349,8 +341,10 @@ pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void)close(fd); + close(fd); + pp->io.fd = -1; free(up); + pp->unitptr = NULL; return (0); } @@ -362,7 +356,6 @@ memcpy((char *)&pp->refid, REFID, 4); up->tc = MINTC; up->decim = 1; - up->fdelay = IRIG_B; up->gain = 127; /* @@ -376,7 +369,7 @@ for (i = 3; i < OFFSET; i++) { up->comp[i] = up->comp[i - 1] + step; up->comp[OFFSET + i] = -up->comp[i]; - if (i % 16 == 0) + if (i % 16 == 0) step *= 2.; } DTOLFP(1. / SECOND, &up->tick); @@ -398,8 +391,10 @@ pp = peer->procptr; up = (struct irigunit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } @@ -442,19 +437,6 @@ sample = up->comp[~*dpt++ & 0xff]; /* - * Clip noise spikes greater than MAXAMP. If no clips, - * increase the gain a tad; if the clips are too high, - * decrease a tad. - */ - if (sample > MAXAMP) { - sample = MAXAMP; - up->clipcnt++; - } else if (sample < -MAXAMP) { - sample = -MAXAMP; - up->clipcnt++; - } - - /* * Variable frequency oscillator. The codec oscillator * runs at the nominal rate of 8000 samples per second, * or 125 us per sample. A frequency change of one unit @@ -462,7 +444,7 @@ * per second, which results in a frequency change of * 125 PPM. */ - up->phase += up->freq / SECOND; + up->phase += (up->freq + clock_codec) / SECOND; up->phase += pp->fudgetime2 / 1e6; if (up->phase >= .5) { up->phase -= 1.; @@ -474,6 +456,11 @@ irig_rf(peer, sample); } L_ADD(&up->timestamp, &up->tick); + sample = fabs(sample); + if (sample > up->signal) + up->signal = sample; + up->signal += (sample - up->signal) / + 1000; /* * Once each second, determine the IRIG format and gain. @@ -487,8 +474,9 @@ up->decim = 10; up->fdelay = IRIG_E; } - irig_gain(peer); up->irig_b = up->irig_e = 0; + irig_gain(peer); + } } @@ -505,14 +493,14 @@ up->mongain = 0; } + /* * irig_rf - RF processing * - * This routine filters the RF signal using a highpass filter for IRIG-B + * This routine filters the RF signal using a bandass filter for IRIG-B * and a lowpass filter for IRIG-E. In case of IRIG-E, the samples are - * decimated by a factor of ten. The lowpass filter functions also as a - * decimation filter in this case. Note that the codec filters function - * as roofing filters to attenuate both the high and low ends of the + * decimated by a factor of ten. Note that the codec filters function as + * roofing filters to attenuate both the high and low ends of the * passband. IIR filter coefficients were determined using Matlab Signal * Processing Toolkit. */ @@ -534,36 +522,45 @@ up = (struct irigunit *)pp->unitptr; /* - * IRIG-B filter. 4th-order elliptic, 800-Hz highpass, 0.3 dB - * passband ripple, -50 dB stopband ripple, phase delay .0022 - * s) - */ - irig_b = (up->hpf[4] = up->hpf[3]) * 2.322484e-01; - irig_b += (up->hpf[3] = up->hpf[2]) * -1.103929e+00; - irig_b += (up->hpf[2] = up->hpf[1]) * 2.351081e+00; - irig_b += (up->hpf[1] = up->hpf[0]) * -2.335036e+00; - up->hpf[0] = sample - irig_b; - irig_b = up->hpf[0] * 4.335855e-01 - + up->hpf[1] * -1.695859e+00 - + up->hpf[2] * 2.525004e+00 - + up->hpf[3] * -1.695859e+00 - + up->hpf[4] * 4.335855e-01; + * IRIG-B filter. Matlab 4th-order IIR elliptic, 800-1200 Hz + * bandpass, 0.3 dB passband ripple, -50 dB stopband ripple, + * phase delay 1.03 ms. + */ + irig_b = (up->bpf[8] = up->bpf[7]) * 6.505491e-001; + irig_b += (up->bpf[7] = up->bpf[6]) * -3.875180e+000; + irig_b += (up->bpf[6] = up->bpf[5]) * 1.151180e+001; + irig_b += (up->bpf[5] = up->bpf[4]) * -2.141264e+001; + irig_b += (up->bpf[4] = up->bpf[3]) * 2.712837e+001; + irig_b += (up->bpf[3] = up->bpf[2]) * -2.384486e+001; + irig_b += (up->bpf[2] = up->bpf[1]) * 1.427663e+001; + irig_b += (up->bpf[1] = up->bpf[0]) * -5.352734e+000; + up->bpf[0] = sample - irig_b; + irig_b = up->bpf[0] * 4.952157e-003 + + up->bpf[1] * -2.055878e-002 + + up->bpf[2] * 4.401413e-002 + + up->bpf[3] * -6.558851e-002 + + up->bpf[4] * 7.462108e-002 + + up->bpf[5] * -6.558851e-002 + + up->bpf[6] * 4.401413e-002 + + up->bpf[7] * -2.055878e-002 + + up->bpf[8] * 4.952157e-003; up->irig_b += irig_b * irig_b; /* - * IRIG-E filter. 4th-order elliptic, 130-Hz lowpass, 0.3 dB - * passband ripple, -50 dB stopband ripple, phase delay .0219 s. - */ - irig_e = (up->lpf[4] = up->lpf[3]) * 8.694604e-01; - irig_e += (up->lpf[3] = up->lpf[2]) * -3.589893e+00; - irig_e += (up->lpf[2] = up->lpf[1]) * 5.570154e+00; - irig_e += (up->lpf[1] = up->lpf[0]) * -3.849667e+00; + * IRIG-E filter. Matlab 4th-order IIR elliptic, 130-Hz lowpass, + * 0.3 dB passband ripple, -50 dB stopband ripple, phase delay + * 3.47 ms. + */ + irig_e = (up->lpf[4] = up->lpf[3]) * 8.694604e-001; + irig_e += (up->lpf[3] = up->lpf[2]) * -3.589893e+000; + irig_e += (up->lpf[2] = up->lpf[1]) * 5.570154e+000; + irig_e += (up->lpf[1] = up->lpf[0]) * -3.849667e+000; up->lpf[0] = sample - irig_e; - irig_e = up->lpf[0] * 3.215696e-03 - + up->lpf[1] * -1.174951e-02 - + up->lpf[2] * 1.712074e-02 - + up->lpf[3] * -1.174951e-02 - + up->lpf[4] * 3.215696e-03; + irig_e = up->lpf[0] * 3.215696e-003 + + up->lpf[1] * -1.174951e-002 + + up->lpf[2] * 1.712074e-002 + + up->lpf[3] * -1.174951e-002 + + up->lpf[4] * 3.215696e-003; up->irig_e += irig_e * irig_e; /* @@ -583,7 +580,8 @@ * * This routine processes the baseband signal and demodulates the AM * carrier using a synchronous detector. It then synchronizes to the - * data frame at the baud rate and decodes the data pulses. + * data frame at the baud rate and decodes the width-modulated data + * pulses. */ static void irig_base( @@ -597,10 +595,10 @@ /* * Local variables */ - double xxing; /* phase detector interpolated output */ double lope; /* integrator output */ double env; /* envelope detector output */ - double dtemp; /* double temp */ + double dtemp; + int carphase; /* carrier phase */ pp = peer->procptr; up = (struct irigunit *)pp->unitptr; @@ -608,50 +606,42 @@ /* * Synchronous baud integrator. Corresponding samples of current * and past baud intervals are integrated to refine the envelope - * amplitude and phase estimate. We keep one cycle of both the - * raw and integrated data for later use. + * amplitude and phase estimate. We keep one cycle (1 ms) of the + * raw data and one baud (10 ms) of the integrated data. */ up->envphase = (up->envphase + 1) % BAUD; - up->carphase = (up->carphase + 1) % CYCLE; up->integ[up->envphase] += (sample - up->integ[up->envphase]) / (5 * up->tc); lope = up->integ[up->envphase]; - up->lastenv[up->carphase] = sample; - up->lastint[up->carphase] = lope; + carphase = up->envphase % CYCLE; + up->lastenv[carphase] = sample; + up->lastint[carphase] = lope; /* - * Phase detector. Sample amplitudes are integrated over the - * baud interval. Cycle phase is determined from these - * amplitudes using an eight-sample cyclic buffer. A phase - * change of 360 degrees produces an output change of one unit. + * Phase detector. Find the negative-going zero crossing + * relative to sample 4 in the 8-sample sycle. A phase change of + * 360 degrees produces an output change of one unit. */ - if (up->lastsig > 0 && lope <= 0) { - xxing = lope / (up->lastsig - lope); - up->zxing += (up->carphase - 4 + xxing) / CYCLE; - } + if (up->lastsig > 0 && lope <= 0) + up->zxing += (double)(carphase - 4) / CYCLE; up->lastsig = lope; /* - * Update signal/noise estimates and PLL phase/frequency. + * End of the baud. Update signal/noise estimates and PLL + * phase, frequency and time constant. */ if (up->envphase == 0) { - - /* - * Update envelope signal and noise estimates and mess - * with error bits. - */ - up->maxsignal = up->intmax; - up->noise = up->intmin; + up->maxsignal = up->intmax; up->noise = up->intmin; + up->intmin = 1e6; up->intmax = -1e6; if (up->maxsignal < DRPOUT) up->errflg |= IRIG_ERR_AMP; if (up->maxsignal > 0) - up->modndx = (up->intmax - up->intmin) / - up->intmax; + up->modndx = (up->maxsignal - up->noise) / + up->maxsignal; else up->modndx = 0; if (up->modndx < MODMIN) up->errflg |= IRIG_ERR_MOD; - up->intmin = 1e6; up->intmax = 0; if (up->errflg & (IRIG_ERR_AMP | IRIG_ERR_FREQ | IRIG_ERR_MOD | IRIG_ERR_SYNCH)) { up->tc = MINTC; @@ -681,17 +671,17 @@ /* * Synchronous demodulator. There are eight samples in the cycle - * and ten cycles in the baud interval. The amplitude of each - * cycle is determined at the last sample in the cycle. The + * and ten cycles in the baud. Since the PLL has aligned the + * negative-going zero crossing at sample 4, the maximum + * amplitude is at sample 2 and minimum at sample 6. The * beginning of the data pulse is determined from the integrated * samples, while the end of the pulse is determined from the * raw samples. The raw data bits are demodulated relative to * the slice level and left-shifted in the decoding register. */ - if (up->carphase != 7) + if (carphase != 7) return; - env = (up->lastenv[2] - up->lastenv[6]) / 2.; lope = (up->lastint[2] - up->lastint[6]) / 2.; if (lope > up->intmax) up->intmax = lope; @@ -705,91 +695,130 @@ * when three correct frames have been found. */ up->pulse = (up->pulse + 1) % 10; - if (up->pulse == 1) - up->envmax = env; - else if (up->pulse == 9) - up->envmin = env; - up->dcycles <<= 1; - if (env >= (up->envmax + up->envmin) / 2.) - up->dcycles |= 1; up->cycles <<= 1; if (lope >= (up->maxsignal + up->noise) / 2.) up->cycles |= 1; if ((up->cycles & 0x303c0f03) == 0x300c0300) { - l_fp ltemp; - int bitz; - - /* - * The PLL time constant starts out small, in order to - * sustain a frequency tolerance of 250 PPM. It - * gradually increases as the loop settles down. Note - * that small wiggles are not believed, unless they - * persist for lots of samples. - */ - if (up->pulse != 9) + if (up->pulse != 0) up->errflg |= IRIG_ERR_SYNCH; - up->pulse = 9; - up->exing = -up->yxing; - if (fabs(up->envxing - up->envphase) <= 1) { - up->tcount++; - if (up->tcount > 50 * up->tc) { - up->tc++; - if (up->tc > MAXTC) - up->tc = MAXTC; - up->tcount = 0; - up->envxing = up->envphase; - } else { - up->exing -= up->envxing - up->envphase; - } - } else { + up->pulse = 0; + } + + /* + * Assemble the baud and max/min to get the slice level for the + * next baud. The slice level is based on the maximum over the + * first two bits and the minimum over the last two bits, with + * the slice level halfway between the maximum and minimum. + */ + env = (up->lastenv[2] - up->lastenv[6]) / 2.; + up->dcycles <<= 1; + if (env >= up->slice) + up->dcycles |= 1; + switch(up->pulse) { + + case 0: + irig_baud(peer, up->dcycles); + if (env < up->envmin) + up->envmin = env; + up->slice = (up->envmax + up->envmin) / 2; + up->envmin = 1e6; up->envmax = -1e6; + break; + + case 1: + up->envmax = env; + break; + + case 2: + if (env > up->envmax) + up->envmax = env; + break; + + case 9: + up->envmin = env; + break; + } +} + +/* + * irig_baud - update the PLL and decode the pulse-width signal + */ +static void +irig_baud( + struct peer *peer, /* peer structure pointer */ + int bits /* decoded bits */ + ) +{ + struct refclockproc *pp; + struct irigunit *up; + double dtemp; + l_fp ltemp; + + pp = peer->procptr; + up = (struct irigunit *)pp->unitptr; + + /* + * The PLL time constant starts out small, in order to + * sustain a frequency tolerance of 250 PPM. It + * gradually increases as the loop settles down. Note + * that small wiggles are not believed, unless they + * persist for lots of samples. + */ + up->exing = -up->yxing; + if (fabs(up->envxing - up->envphase) <= 1) { + up->tcount++; + if (up->tcount > 20 * up->tc) { + up->tc++; + if (up->tc > MAXTC) + up->tc = MAXTC; up->tcount = 0; up->envxing = up->envphase; + } else { + up->exing -= up->envxing - up->envphase; } + } else { + up->tcount = 0; + up->envxing = up->envphase; + } - /* - * Determine a reference timestamp, accounting for the - * codec delay and filter delay. Note the timestamp is - * for the previous frame, so we have to backtrack for - * this plus the delay since the last carrier positive - * zero crossing. - */ - dtemp = up->decim * ((up->exing + BAUD) / SECOND + 1.) + - up->fdelay; - DTOLFP(dtemp, <emp); - pp->lastrec = up->timestamp; - L_SUB(&pp->lastrec, <emp); + /* + * Strike the baud timestamp as the positive zero crossing of + * the first bit, accounting for the codec delay and filter + * delay. + */ + up->prvstamp = up->chrstamp; + dtemp = up->decim * (up->exing / SECOND) + up->fdelay; + DTOLFP(dtemp, <emp); + up->chrstamp = up->timestamp; + L_SUB(&up->chrstamp, <emp); - /* - * The data bits are collected in ten-bit frames. The - * first two and last two bits are determined by frame - * sync and ignored here; the resulting patterns - * represent zero (0-1 bits), one (2-4 bits) and - * position identifier (5-6 bits). The remaining - * patterns represent errors and are treated as zeros. - */ - bitz = up->dcycles & 0xfc; - switch(bitz) { + /* + * The data bits are collected in ten-bit bauds. The first two + * bits are not used. The resulting patterns represent runs of + * 0-1 bits (0), 2-4 bits (1) and 5-7 bits (PI). The remaining + * 8-bit run represents a soft error and is treated as 0. + */ + switch (up->dcycles & 0xff) { - case 0x00: - case 0x80: - irig_decode(peer, BIT0); - break; - - case 0xc0: - case 0xe0: - case 0xf0: - irig_decode(peer, BIT1); - break; - - case 0xf8: - case 0xfc: - irig_decode(peer, BITP); - break; - - default: - irig_decode(peer, 0); - up->errflg |= IRIG_ERR_DECODE; - } + case 0x00: /* 0-1 bits (0) */ + case 0x80: + irig_decode(peer, BIT0); + break; + + case 0xc0: /* 2-4 bits (1) */ + case 0xe0: + case 0xf0: + irig_decode(peer, BIT1); + break; + + case 0xf8: /* (5-7 bits (PI) */ + case 0xfc: + case 0xfe: + irig_decode(peer, BITP); + break; + + default: /* 8 bits (error) */ + irig_decode(peer, BIT0); + up->errflg |= IRIG_ERR_DECODE; } } @@ -797,11 +826,10 @@ /* * irig_decode - decode the data * - * This routine assembles bits into digits, digits into subfields and - * subfields into the timecode field. Bits can have values of zero, one - * or position identifier. There are four bits per digit, two digits per - * subfield and ten subfields per field. The last bit in every subfield - * and the first bit in the first subfield are position identifiers. + * This routine assembles bauds into digits, digits into frames and + * frames into the timecode fields. Bits can have values of zero, one + * or position identifier. There are four bits per digit, ten digits per + * frame and ten frames per second. */ static void irig_decode( @@ -811,115 +839,58 @@ { struct refclockproc *pp; struct irigunit *up; -#ifdef IRIG_SUCKS - int i; -#endif /* IRIG_SUCKS */ /* * Local variables */ - char syncchar; /* sync character (Spectracom) */ - char sbs[6]; /* binary seconds since 0h */ - char spare[2]; /* mulligan digits */ + int syncdig; /* sync digit (Spectracom) */ + char sbs[6 + 1]; /* binary seconds since 0h */ + char spare[2 + 1]; /* mulligan digits */ + int temp; - pp = peer->procptr; + pp = peer->procptr; up = (struct irigunit *)pp->unitptr; /* - * Assemble subfield bits. + * Assemble frame bits. */ - up->bits <<= 1; + up->bits >>= 1; if (bit == BIT1) { - up->bits |= 1; + up->bits |= 0x200; } else if (bit == BITP && up->lastbit == BITP) { /* - * Frame sync - two adjacent position identifiers. - * Monitor the reference timestamp and wiggle the - * clock, but only if no errors have occurred. + * Frame sync - two adjacent position identifiers, which + * mark the beginning of the second. The reference time + * is the beginning of the second position identifier, + * so copy the character timestamp to the reference + * timestamp. */ - up->bitcnt = 1; - up->fieldcnt = 0; - up->lastbit = 0; - if (up->errflg == 0) { -#ifdef IRIG_SUCKS - l_fp ltemp; - - /* - * You really don't wanna know what comes down - * here. Leave it to say Solaris 2.8 broke the - * nice clean audio stream, apparently affected - * by a 5-ms sawtooth jitter. Sundown on - * Solaris. This leaves a little twilight. - * - * The scheme involves differentiation, forward - * learning and integration. The sawtooth has a - * period of 11 seconds. The timestamp - * differences are integrated and subtracted - * from the signal. - */ - ltemp = pp->lastrec; - L_SUB(<emp, &pp->lastref); - if (ltemp.l_f < 0) - ltemp.l_i = -1; - else - ltemp.l_i = 0; - pp->lastref = pp->lastrec; - if (!L_ISNEG(<emp)) - L_CLR(&up->wigwag); - else - L_ADD(&up->wigwag, <emp); - L_SUB(&pp->lastrec, &up->wigwag); - up->wiggle[up->wp] = ltemp; - - /* - * Bottom fisher. To understand this, you have - * to know about velocity microphones and AM - * transmitters. No further explanation is - * offered, as this is truly a black art. - */ - up->wigbot[up->wp] = pp->lastrec; - for (i = 0; i < WIGGLE; i++) { - if (i != up->wp) - up->wigbot[i].l_ui++; - L_SUB(&pp->lastrec, &up->wigbot[i]); - if (L_ISNEG(&pp->lastrec)) - L_ADD(&pp->lastrec, - &up->wigbot[i]); - else - pp->lastrec = up->wigbot[i]; - } - up->wp++; - up->wp %= WIGGLE; - up->wuggle = pp->lastrec; - refclock_process(pp); -#else /* IRIG_SUCKS */ - pp->lastref = pp->lastrec; - up->wuggle = pp->lastrec; - refclock_process(pp); -#endif /* IRIG_SUCKS */ - } - up->errflg = 0; + if (up->frmcnt != 1) + up->errflg |= IRIG_ERR_SYNCH; + up->frmcnt = 1; + up->refstamp = up->prvstamp; } - up->bitcnt = (up->bitcnt + 1) % SUBFLD; - if (up->bitcnt == 0) { + up->lastbit = bit; + if (up->frmcnt % SUBFLD == 0) { /* - * End of subfield. Encode two hexadecimal digits in - * little-endian timecode field. + * End of frame. Encode two hexadecimal digits in + * little-endian timecode field. Note frame 1 is shifted + * right one bit to account for the marker PI. */ - if (up->fieldcnt == 0) - up->bits <<= 1; - if (up->xptr < 2) - up->xptr = 2 * FIELD; - up->timecode[--up->xptr] = hexchar[(up->bits >> 5) & - 0xf]; - up->timecode[--up->xptr] = hexchar[up->bits & 0xf]; - up->fieldcnt = (up->fieldcnt + 1) % FIELD; - if (up->fieldcnt == 0) { + temp = up->bits; + if (up->frmcnt == 10) + temp >>= 1; + if (up->xptr >= 2) { + up->timecode[--up->xptr] = hexchar[temp & 0xf]; + up->timecode[--up->xptr] = hexchar[(temp >> 5) & + 0xf]; + } + if (up->frmcnt == 0) { /* - * End of field. Decode the timecode and wind + * End of second. Decode the timecode and wind * the clock. Not all IRIG generators have the * year; if so, it is nonzero after year 2000. * Not all have the hardware status bit; if so, @@ -931,40 +902,68 @@ * refclock_process() will reject the timecode * as invalid. */ - up->xptr = 2 * FIELD; + up->xptr = 2 * SUBFLD; if (sscanf((char *)up->timecode, - "%6s%2d%c%2s%3d%2d%2d%2d", sbs, &pp->year, - &syncchar, spare, &pp->day, &pp->hour, + "%6s%2d%1d%2s%3d%2d%2d%2d", sbs, &pp->year, + &syncdig, spare, &pp->day, &pp->hour, &pp->minute, &pp->second) != 8) pp->leap = LEAP_NOTINSYNC; else pp->leap = LEAP_NOWARNING; up->second = (up->second + up->decim) % 60; - if (pp->year > 0) - pp->year += 2000; + + /* + * Raise an alarm if the day field is zero, + * which happens when signature control is + * enabled and the device has lost + * synchronization. Raise an alarm if the year + * field is nonzero and the sync indicator is + * zero, which happens when a Spectracom radio + * has lost synchronization. Raise an alarm if + * the expected second does not agree with the + * decoded second, which happens with a garbled + * IRIG signal. We are very particular. + */ + if (pp->day == 0 || (pp->year != 0 && syncdig == + 0)) + up->errflg |= IRIG_ERR_SIGERR; if (pp->second != up->second) up->errflg |= IRIG_ERR_CHECK; up->second = pp->second; - sprintf(pp->a_lastcode, - "%02x %c %2d %3d %02d:%02d:%02d %4.0f %3d %6.3f %2d %6.1f %6.1f %s", - up->errflg, syncchar, pp->year, pp->day, + + /* + * Wind the clock only if there are no errors + * and the time constant has reached the + * maximum. + */ + if (up->errflg == 0 && up->tc == MAXTC) { + pp->lastref = pp->lastrec; + pp->lastrec = up->refstamp; + if (!refclock_process(pp)) + refclock_report(peer, + CEVNT_BADTIME); + } + snprintf(pp->a_lastcode, sizeof(pp->a_lastcode), + "%02x %02d %03d %02d:%02d:%02d %4.0f %3d %6.3f %2d %6.2f %6.1f %s", + up->errflg, pp->year, pp->day, pp->hour, pp->minute, pp->second, up->maxsignal, up->gain, up->modndx, up->tc, up->exing * 1e6 / SECOND, up->freq * - 1e6 / SECOND, ulfptoa(&up->wuggle, 6)); + 1e6 / SECOND, ulfptoa(&pp->lastrec, 6)); pp->lencode = strlen(pp->a_lastcode); + up->errflg = 0; if (pp->sloppyclockflag & CLK_FLAG4) { record_clock_stats(&peer->srcadr, pp->a_lastcode); #ifdef DEBUG if (debug) - printf("irig: %s\n", + printf("irig %s\n", pp->a_lastcode); #endif /* DEBUG */ } } } - up->lastbit = bit; + up->frmcnt = (up->frmcnt + 1) % FIELD; } @@ -973,8 +972,7 @@ * * This routine sweeps up the timecode updates since the last poll. For * IRIG-B there should be at least 60 updates; for IRIG-E there should - * be at least 6. If nothing is heard, a timeout event is declared and - * any orphaned timecode updates are sent to foster care. + * be at least 6. If nothing is heard, a timeout event is declared. */ static void irig_poll( @@ -992,12 +990,13 @@ refclock_report(peer, CEVNT_TIMEOUT); return; - } else { - refclock_receive(peer); + } + refclock_receive(peer); + if (!(pp->sloppyclockflag & CLK_FLAG4)) { record_clock_stats(&peer->srcadr, pp->a_lastcode); #ifdef DEBUG if (debug) - printf("irig: %s\n", pp->a_lastcode); + printf("irig %s\n", pp->a_lastcode); #endif /* DEBUG */ } pp->polls++; @@ -1008,11 +1007,10 @@ /* * irig_gain - adjust codec gain * - * This routine is called once each second. If the signal envelope - * amplitude is too low, the codec gain is bumped up by four units; if - * too high, it is bumped down. The decoder is relatively insensitive to - * amplitude, so this crudity works just fine. The input port is set and - * the error flag is cleared, mostly to be ornery. + * This routine is called at the end of each second. It uses the AGC to + * bradket the maximum signal level between MINAMP and MAXAMP to avoid + * hunting. The routine also jiggles the input port and selectively + * mutes the monitor. */ static void irig_gain( @@ -1030,19 +1028,19 @@ * gain control field. Thus, it may take awhile for changes to * wiggle the hardware bits. */ - if (up->clipcnt == 0) { + if (up->maxsignal < MINAMP) { up->gain += 4; if (up->gain > MAXGAIN) up->gain = MAXGAIN; - } else if (up->clipcnt > MAXCLP) { + } else if (up->maxsignal > MAXAMP) { up->gain -= 4; if (up->gain < 0) up->gain = 0; } audio_gain(up->gain, up->mongain, up->port); - up->clipcnt = 0; } + #else int refclock_irig_bs; #endif /* REFCLOCK */ diff -urN src/contrib/ntp/ntpd/refclock_jjy.c src.ntp/contrib/ntp/ntpd/refclock_jjy.c --- src/contrib/ntp/ntpd/refclock_jjy.c 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/refclock_jjy.c 2010-02-04 08:26:54.000000000 +0100 @@ -187,18 +187,18 @@ /* * Function prototypes */ -static int jjy_start P((int, struct peer *)); -static void jjy_shutdown P((int, struct peer *)); -static void jjy_poll P((int, struct peer *)); -static void jjy_poll_tristate_jjy01 P((int, struct peer *)); -static void jjy_poll_cdex_jst2000 P((int, struct peer *)); -static void jjy_poll_echokeisokuki_lt2000 P((int, struct peer *)); -static void jjy_poll_citizentic_jjy200 P((int, struct peer *)); -static void jjy_receive P((struct recvbuf *)); -static int jjy_receive_tristate_jjy01 P((struct recvbuf *)); -static int jjy_receive_cdex_jst2000 P((struct recvbuf *)); -static int jjy_receive_echokeisokuki_lt2000 P((struct recvbuf *)); -static int jjy_receive_citizentic_jjy200 P((struct recvbuf *)); +static int jjy_start (int, struct peer *); +static void jjy_shutdown (int, struct peer *); +static void jjy_poll (int, struct peer *); +static void jjy_poll_tristate_jjy01 (int, struct peer *); +static void jjy_poll_cdex_jst2000 (int, struct peer *); +static void jjy_poll_echokeisokuki_lt2000 (int, struct peer *); +static void jjy_poll_citizentic_jjy200 (int, struct peer *); +static void jjy_receive (struct recvbuf *); +static int jjy_receive_tristate_jjy01 (struct recvbuf *); +static int jjy_receive_cdex_jst2000 (struct recvbuf *); +static int jjy_receive_echokeisokuki_lt2000 (struct recvbuf *); +static int jjy_receive_citizentic_jjy200 (struct recvbuf *); /* * Transfer vector @@ -250,10 +250,8 @@ /* * Open serial port */ - if ( ! ( pDeviceName = (char*) emalloc ( strlen(DEVICE) + 10 ) ) ) { - return RC_START_ERROR ; - } - sprintf ( pDeviceName, DEVICE, unit ) ; + pDeviceName = emalloc ( strlen(DEVICE) + 10 ); + snprintf ( pDeviceName, strlen(DEVICE) + 10, DEVICE, unit ) ; /* * peer->ttl is a mode number specified by "127.127.40.X mode N" in the ntp.conf @@ -292,12 +290,8 @@ /* * Allocate and initialize unit structure */ - if ( ! ( up = (struct jjyunit *) emalloc (sizeof(struct jjyunit)) ) ) { - close ( fd ) ; - return RC_START_ERROR ; - } - - memset ( (char*)up, 0, sizeof(struct jjyunit) ) ; + up = emalloc (sizeof(*up)); + memset ( up, 0, sizeof(*up) ) ; up->linediscipline = iDiscipline ; /* @@ -325,8 +319,8 @@ up->unittype = UNITTYPE_ECHOKEISOKUKI_LT2000 ; up->operationmode = 2 ; /* Mode 2 : Continuous mode */ up->lineexpect = 1 ; - switch ( up->operationmode ) { - case 1 : + switch ( up->operationmode ) { + case 1 : up->charexpect[0] = 15 ; /* YYMMDDWHHMMSS */ break ; case 2 : @@ -334,11 +328,11 @@ break ; } break ; - case 4 : - up->unittype = UNITTYPE_CITIZENTIC_JJY200 ; - up->lineexpect = 1 ; - up->charexpect[0] = 23 ; /* 'XX YY/MM/DD W HH:MM:SS */ - break ; + case 4 : + up->unittype = UNITTYPE_CITIZENTIC_JJY200 ; + up->lineexpect = 1 ; + up->charexpect[0] = 23 ; /* 'XX YY/MM/DD W HH:MM:SS */ + break ; default : msyslog ( LOG_ERR, "JJY receiver [ %s mode %d ] : Unsupported mode", ntoa(&peer->srcadr), peer->ttl ) ; @@ -355,7 +349,9 @@ pp->io.fd = fd ; if ( ! io_addclock(&pp->io) ) { close ( fd ) ; - free ( (void*) up ) ; + pp->io.fd = -1 ; + free ( up ) ; + pp->unitptr = NULL ; return RC_START_ERROR ; } @@ -384,8 +380,10 @@ pp = peer->procptr ; up = (struct jjyunit *) pp->unitptr ; - io_closeclock ( &pp->io ) ; - free ( (void*) up ) ; + if ( -1 != pp->io.fd ) + io_closeclock ( &pp->io ) ; + if ( NULL != up ) + free ( up ) ; } @@ -546,8 +544,10 @@ * timecode timestamp. */ - sprintf ( sLogText, "%04d/%02d/%02d %02d:%02d:%02d.%1d JST", - up->year, up->month, up->day, up->hour, up->minute, up->second, up->msecond/100 ) ; + snprintf ( sLogText, sizeof(sLogText), + "%04d/%02d/%02d %02d:%02d:%02d.%1d JST", + up->year, up->month, up->day, + up->hour, up->minute, up->second, up->msecond/100 ) ; record_clock_stats ( &peer->srcadr, sLogText ) ; if ( ! refclock_process ( pp ) ) { diff -urN src/contrib/ntp/ntpd/refclock_jupiter.c src.ntp/contrib/ntp/ntpd/refclock_jupiter.c --- src/contrib/ntp/ntpd/refclock_jupiter.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_jupiter.c 2010-02-04 08:26:52.000000000 +0100 @@ -135,28 +135,28 @@ /* * Function prototypes */ -static void jupiter_canmsg P((struct instance *, u_int)); -static u_short jupiter_cksum P((u_short *, u_int)); -static int jupiter_config P((struct instance *)); -static void jupiter_debug P((struct peer *, char *, char *, ...)) +static void jupiter_canmsg (struct instance *, u_int); +static u_short jupiter_cksum (u_short *, u_int); +static int jupiter_config (struct instance *); +static void jupiter_debug (struct peer *, char *, char *, ...) __attribute__ ((format (printf, 3, 4))); -static char * jupiter_parse_t P((struct instance *, u_short *)); -static char * jupiter_parse_gpos P((struct instance *, u_short *)); -static void jupiter_platform P((struct instance *, u_int)); -static void jupiter_poll P((int, struct peer *)); -static void jupiter_control P((int, struct refclockstat *, struct - refclockstat *, struct peer *)); +static char * jupiter_parse_t (struct instance *, u_short *); +static char * jupiter_parse_gpos (struct instance *, u_short *); +static void jupiter_platform (struct instance *, u_int); +static void jupiter_poll (int, struct peer *); +static void jupiter_control (int, struct refclockstat *, struct + refclockstat *, struct peer *); #ifdef HAVE_PPSAPI -static int jupiter_ppsapi P((struct instance *)); -static int jupiter_pps P((struct instance *)); +static int jupiter_ppsapi (struct instance *); +static int jupiter_pps (struct instance *); #endif /* HAVE_PPSAPI */ -static int jupiter_recv P((struct instance *)); -static void jupiter_receive P((struct recvbuf *rbufp)); -static void jupiter_reqmsg P((struct instance *, u_int, u_int)); -static void jupiter_reqonemsg P((struct instance *, u_int)); -static char * jupiter_send P((struct instance *, struct jheader *)); -static void jupiter_shutdown P((int, struct peer *)); -static int jupiter_start P((int, struct peer *)); +static int jupiter_recv (struct instance *); +static void jupiter_receive (struct recvbuf *rbufp); +static void jupiter_reqmsg (struct instance *, u_int, u_int); +static void jupiter_reqonemsg (struct instance *, u_int); +static char * jupiter_send (struct instance *, struct jheader *); +static void jupiter_shutdown (int, struct peer *); +static int jupiter_start (int, struct peer *); /* * Transfer vector @@ -188,7 +188,7 @@ /* * Open serial port */ - (void)sprintf(gpsdev, DEVICE, unit); + snprintf(gpsdev, sizeof(gpsdev), DEVICE, unit); fd = refclock_open(gpsdev, SPEED232, LDISC_RAW); if (fd == 0) { jupiter_debug(peer, "jupiter_start", "open %s: %s", @@ -197,12 +197,8 @@ } /* Allocate unit structure */ - if ((instance = (struct instance *) - emalloc(sizeof(struct instance))) == NULL) { - (void) close(fd); - return (0); - } - memset((char *)instance, 0, sizeof(struct instance)); + instance = emalloc(sizeof(*instance)); + memset(instance, 0, sizeof(*instance)); instance->peer = peer; pp = peer->procptr; pp->io.clock_recv = jupiter_receive; @@ -210,7 +206,7 @@ pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + close(fd); free(instance); return (0); } @@ -934,10 +930,10 @@ } if ((cc = write(instance->peer->procptr->io.fd, (char *)hp, size)) < 0) { - (void)sprintf(errstr, "write: %s", strerror(errno)); + snprintf(errstr, sizeof(errstr), "write: %s", strerror(errno)); return (errstr); } else if (cc != size) { - (void)sprintf(errstr, "short write (%d != %d)", cc, size); + snprintf(errstr, sizeof(errstr), "short write (%d != %d)", cc, size); return (errstr); } return (NULL); diff -urN src/contrib/ntp/ntpd/refclock_leitch.c src.ntp/contrib/ntp/ntpd/refclock_leitch.c --- src/contrib/ntp/ntpd/refclock_leitch.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_leitch.c 2010-02-04 08:26:54.000000000 +0100 @@ -43,6 +43,7 @@ * STATUS: G (good), D (diag fail), T (time not provided) or * P (last phone update failed) */ +#define PRECISION (-20) /* 1x10-8 */ #define MAXUNITS 1 /* max number of LEITCH units */ #define LEITCHREFID "ATOM" /* reference id */ #define LEITCH_DESCRIPTION "Leitch: CSD 5300 Master Clock System Driver" @@ -96,20 +97,20 @@ /* * Function prototypes */ -static void leitch_init P((void)); -static int leitch_start P((int, struct peer *)); -static void leitch_shutdown P((int, struct peer *)); -static void leitch_poll P((int, struct peer *)); -static void leitch_control P((int, struct refclockstat *, struct refclockstat *, struct peer *)); +static void leitch_init (void); +static int leitch_start (int, struct peer *); +static void leitch_shutdown (int, struct peer *); +static void leitch_poll (int, struct peer *); +static void leitch_control (int, struct refclockstat *, struct refclockstat *, struct peer *); #define leitch_buginfo noentry -static void leitch_receive P((struct recvbuf *)); -static void leitch_process P((struct leitchunit *)); +static void leitch_receive (struct recvbuf *); +static void leitch_process (struct leitchunit *); #if 0 -static void leitch_timeout P((struct peer *)); +static void leitch_timeout (struct peer *); #endif -static int leitch_get_date P((struct recvbuf *, struct leitchunit *)); -static int leitch_get_time P((struct recvbuf *, struct leitchunit *, int)); -static int days_per_year P((int)); +static int leitch_get_date (struct recvbuf *, struct leitchunit *); +static int leitch_get_time (struct recvbuf *, struct leitchunit *, int); +static int days_per_year (int); static struct leitchunit leitchunits[MAXUNITS]; static u_char unitinuse[MAXUNITS]; @@ -149,9 +150,17 @@ struct peer *peer ) { + struct leitchunit *leitch; + + if (unit >= MAXUNITS) { + return; + } + leitch = &leitchunits[unit]; + if (-1 != leitch->leitchio.fd) + io_closeclock(&leitch->leitchio); #ifdef DEBUG if (debug) - fprintf(stderr, "leitch_shutdown()\n"); + fprintf(stderr, "leitch_shutdown()\n"); #endif } @@ -257,7 +266,7 @@ /* * Open serial port. */ - (void) sprintf(leitchdev, LEITCH232, unit); + snprintf(leitchdev, sizeof(leitchdev), LEITCH232, unit); fd232 = open(leitchdev, O_RDWR, 0777); if (fd232 == -1) { msyslog(LOG_ERR, @@ -266,7 +275,7 @@ } leitch = &leitchunits[unit]; - memset((char*)leitch, 0, sizeof(*leitch)); + memset(leitch, 0, sizeof(*leitch)); #if defined(HAVE_SYSV_TTYS) /* @@ -386,6 +395,7 @@ leitch->leitchio.datalen = 0; leitch->leitchio.fd = fd232; if (!io_addclock(&leitch->leitchio)) { + leitch->leitchio.fd = -1; goto screwed; } @@ -393,7 +403,7 @@ * All done. Initialize a few random peer variables, then * return success. */ - peer->precision = 0; + peer->precision = PRECISION; peer->stratum = stratumtouse[unit]; peer->refid = refid[unit]; unitinuse[unit] = 1; diff -urN src/contrib/ntp/ntpd/refclock_local.c src.ntp/contrib/ntp/ntpd/refclock_local.c --- src/contrib/ntp/ntpd/refclock_local.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_local.c 2009-12-09 08:36:36.000000000 +0100 @@ -24,19 +24,20 @@ /* * This is a hack to allow a machine to use its own system clock as a * reference clock, i.e., to free-run using no outside clock discipline - * source. This is useful if you want to use NTP in an isolated - * environment with no radio clock or NIST modem available. Pick a - * machine that you figure has a good clock oscillator and configure it - * with this driver. Set the clock using the best means available, like + * source. Note that the clock selection algorithm will not select this + * driver unless all other sources of synchronization have been lost. + * This is useful if you want to use NTP in an isolated environment + * with no radio clock or NIST modem available. Pick a machine that you + * figure has a good clock oscillator and configure it with this + * driver. Set the clock using the best means available, like * eyeball-and-wristwatch. Then, point all the other machines at this * one or use broadcast (not multicast) mode to distribute time. * * Another application for this driver is if you want to use a * particular server's clock as the clock of last resort when all other * normal synchronization sources have gone away. This is especially - * useful if that server has an ovenized oscillator. For this you would - * configure this driver at a higher stratum (say 5) to prevent the - * server's stratum from falling below that. + * useful if that server has an ovenized oscillator. However, the + * preferred was to do this is using orphan mode. See the documentation. * * A third application for this driver is when an external discipline * source is available, such as the NIST "lockclock" program, which @@ -52,42 +53,17 @@ * oscillator. In extreme cases, this can cause clients to exceed the * 128-ms slew window and drop off the NTP subnet. * - * THis driver includes provisions to telegraph synchronization state - * and related variables by means of kernel variables with specially - * modified kernels. This is done using the ntp_adjtime() syscall. - * In the cases where another protocol or device synchronizes the local - * host, the data given to the kernel can be slurped up by this driver - * and distributed to clients by ordinary NTP messaging. - * - * In the default mode the behavior of the clock selection algorithm is - * modified when this driver is in use. The algorithm is designed so - * that this driver will never be selected unless no other discipline - * source is available. This can be overriden with the prefer keyword of - * the server configuration command, in which case only this driver will - * be selected for synchronization and all other discipline sources will - * be ignored. This behavior is intended for use when an external - * discipline source controls the system clock. - * * Fudge Factors * - * The stratum for this driver set at 5 by default, but it can be - * changed by the fudge command and/or the ntpdc utility. The reference - * ID is 127.0.0.1 by default, but can be changed using the same mechanism. - * *NEVER* configure this driver to operate at a stratum which might - * possibly disrupt a client with access to a bona fide primary server, - * unless the local clock oscillator is reliably disciplined by another - * source. *NEVER NEVER* configure a server which might devolve to an - * undisciplined local clock to use multicast mode. Always remember that - * an improperly configured local clock driver let loose in the Internet - * can cause very serious disruption. This is why most of us who care - * about good time use cryptographic authentication. - * - * This driver provides a mechanism to trim the local clock in both time - * and frequency, as well as a way to manipulate the leap bits. The - * fudge time1 parameter adjusts the time, in seconds, and the fudge - * time2 parameter adjusts the frequency, in ppm. The fudge time1 - * parameter is additive; that is, it adds an increment to the current - * time. The fudge time2 parameter directly sets the frequency. + * If fudge flag1 is lit, the leap second bit is set in the peer + * status word. It should be set early in the day of a leap second + * event and set dark on the day after the event. + * + * Note the fudge time1 and time2 have been deprecated. The fudge time1 + * was intended to apply a bias offset. This can be done using the Unix + * date command. The fudge time2 was intended to apply a bias frequency. + * This can be done using the frequency file and/or the freq + * configuration command. */ /* * Local interface definitions @@ -107,20 +83,11 @@ */ extern s_char sys_precision; -#ifdef KERNEL_PLL -/* - * Imported from ntp_loopfilter - */ -extern int pll_control; /* kernel pll control */ -extern int kern_enable; /* kernel pll enabled */ -extern int ext_enable; /* external clock enable */ -#endif /* KERNEL_PLL */ - /* * Function prototypes */ -static int local_start P((int, struct peer *)); -static void local_poll P((int, struct peer *)); +static int local_start (int, struct peer *); +static void local_poll (int, struct peer *); /* * Local variables @@ -191,6 +158,12 @@ #endif /* KERNEL_PLL LOCKCLOCK */ struct refclockproc *pp; + /* + * Do no evil unless the house is dark or lit with our own lamp. + */ + if (!(sys_peer == NULL || sys_peer == peer)) + return; + #if defined(VMS) && defined(VMS_LOCALUNIT) if (unit == VMS_LOCALUNIT) { extern void vms_local_poll(struct peer *); @@ -199,6 +172,7 @@ return; } #endif /* VMS && VMS_LOCALUNIT */ + pp = peer->procptr; pp->polls++; @@ -209,12 +183,8 @@ * time1 (s) and a continuous frequency adjustment using fudge * time 2 (ppm). */ - get_systime(&pp->lastrec); - pp->fudgetime1 += pp->fudgetime2 * 1e-6 * (current_time - - poll_time); poll_time = current_time; - refclock_process_offset(pp, pp->lastrec, pp->lastrec, - pp->fudgetime1); + refclock_process_offset(pp, pp->lastrec, pp->lastrec, 0); /* * If another process is disciplining the system clock, we set @@ -245,13 +215,15 @@ pp->disp = 0; pp->jitter = 0; #else /* KERNEL_PLL LOCKCLOCK */ - pp->leap = LEAP_NOWARNING; + if (pp->sloppyclockflag & CLK_FLAG1) + pp->leap = LEAP_ADDSECOND; + else + pp->leap = LEAP_NOWARNING; pp->disp = DISPERSION; pp->jitter = 0; #endif /* KERNEL_PLL LOCKCLOCK */ pp->lastref = pp->lastrec; refclock_receive(peer); - pp->fudgetime1 = 0; } #else int refclock_local_bs; diff -urN src/contrib/ntp/ntpd/refclock_msfees.c src.ntp/contrib/ntp/ntpd/refclock_msfees.c --- src/contrib/ntp/ntpd/refclock_msfees.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_msfees.c 2010-02-04 08:26:52.000000000 +0100 @@ -382,11 +382,15 @@ int i; register char *ptr = buff; - sprintf(ptr, text); - for (i=from; i DUMP_BUF_SIZE) msyslog(LOG_DEBUG, "D: %s", ptr=buff); - sprintf(ptr, " %06d", ((int)coffs[i].l_f) / 4295); + snprintf(buff, sizeof(buff), text); + for (i = from; i < to; i++) { + ptr += strlen(ptr); + if ((ptr - buff) > DUMP_BUF_SIZE) { + msyslog(LOG_DEBUG, "D: %s", buff); + ptr = buff; + } + snprintf(ptr, sizeof(buff) - (ptr - buff), + " %06d", ((int)coffs[i].l_f) / 4295); } msyslog(LOG_DEBUG, "D: %s", buff); } @@ -450,7 +454,7 @@ /* Unit okay, attempt to open the devices. We do them both at * once to make sure we can */ - (void) sprintf(eesdev, EES232, unit); + snprintf(eesdev, sizeof(eesdev), EES232, unit); fd232 = open(eesdev, O_RDWR, 0777); if (fd232 == -1) { @@ -987,17 +991,20 @@ /* Dump the deltas each minute */ if (dbg & DB_DUMP_DELTAS) - { if (/*0 <= ees->second && */ - ees->second < ((sizeof deltas) / (sizeof deltas[0]))) deltas[ees->second] = delta_sfsec; + { + if (/*0 <= ees->second && */ + ees->second < COUNTOF(deltas)) + deltas[ees->second] = delta_sfsec; /* Dump on second 1, as second 0 sometimes missed */ if (ees->second == 1) { - char text[16 * ((sizeof deltas) / (sizeof deltas[0]))]; + char text[16 * COUNTOF(deltas)]; char *cptr=text; int i; - for (i=0; i<((sizeof deltas) / (sizeof deltas[0])); i++) { - sprintf(cptr, " %d.%04d", - msec(deltas[i]), subms(deltas[i])); - while (*cptr) cptr++; + for (i = 0; i < COUNTOF(deltas); i++) { + snprintf(cptr, sizeof(text) / COUNTOF(deltas), + " %d.%04d", msec(deltas[i]), + subms(deltas[i])); + cptr += strlen(cptr); } msyslog(LOG_ERR, "Deltas: %d.%04d<->%d.%04d: %s", msec(EES_STEP_F - EES_STEP_F_GRACE), subms(EES_STEP_F - EES_STEP_F_GRACE), diff -urN src/contrib/ntp/ntpd/refclock_mx4200.c src.ntp/contrib/ntp/ntpd/refclock_mx4200.c --- src/contrib/ntp/ntpd/refclock_mx4200.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_mx4200.c 2010-02-04 08:26:52.000000000 +0100 @@ -167,28 +167,28 @@ /* * Function prototypes */ -static int mx4200_start P((int, struct peer *)); -static void mx4200_shutdown P((int, struct peer *)); -static void mx4200_receive P((struct recvbuf *)); -static void mx4200_poll P((int, struct peer *)); - -static char * mx4200_parse_t P((struct peer *)); -static char * mx4200_parse_p P((struct peer *)); -static char * mx4200_parse_s P((struct peer *)); +static int mx4200_start (int, struct peer *); +static void mx4200_shutdown (int, struct peer *); +static void mx4200_receive (struct recvbuf *); +static void mx4200_poll (int, struct peer *); + +static char * mx4200_parse_t (struct peer *); +static char * mx4200_parse_p (struct peer *); +static char * mx4200_parse_s (struct peer *); #ifdef QSORT_USES_VOID_P -int mx4200_cmpl_fp P((const void *, const void *)); +int mx4200_cmpl_fp (const void *, const void *); #else -int mx4200_cmpl_fp P((const l_fp *, const l_fp *)); +int mx4200_cmpl_fp (const l_fp *, const l_fp *); #endif /* not QSORT_USES_VOID_P */ -static int mx4200_config P((struct peer *)); -static void mx4200_ref P((struct peer *)); -static void mx4200_send P((struct peer *, char *, ...)) +static int mx4200_config (struct peer *); +static void mx4200_ref (struct peer *); +static void mx4200_send (struct peer *, char *, ...) __attribute__ ((format (printf, 2, 3))); -static u_char mx4200_cksum P((char *, int)); -static int mx4200_jday P((int, int, int)); -static void mx4200_debug P((struct peer *, char *, ...)) +static u_char mx4200_cksum (char *, int); +static int mx4200_jday (int, int, int); +static void mx4200_debug (struct peer *, char *, ...) __attribute__ ((format (printf, 2, 3))); -static int mx4200_pps P((struct peer *)); +static int mx4200_pps (struct peer *); /* * Transfer vector @@ -222,7 +222,7 @@ /* * Open serial port */ - (void)sprintf(gpsdev, DEVICE, unit); + snprintf(gpsdev, sizeof(gpsdev), DEVICE, unit); if (!(fd = refclock_open(gpsdev, SPEED232, LDISC_PPS))) { return (0); } @@ -230,19 +230,16 @@ /* * Allocate unit structure */ - if (!(up = (struct mx4200unit *) emalloc(sizeof(struct mx4200unit)))) { - perror("emalloc"); - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct mx4200unit)); + up = emalloc(sizeof(*up)); + memset(up, 0, sizeof(*up)); pp = peer->procptr; pp->io.clock_recv = mx4200_receive; pp->io.srcclock = (caddr_t)peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + close(fd); + pp->io.fd = -1; free(up); return (0); } @@ -274,8 +271,10 @@ pp = peer->procptr; up = (struct mx4200unit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } @@ -576,9 +575,9 @@ } alt = up->avg_alt; minute = (lat - (double)(int)lat) * 60.0; - sprintf(lats,"%02d%02.4f", (int)lat, minute); + snprintf(lats, sizeof(lats), "%02d%02.4f", (int)lat, minute); minute = (lon - (double)(int)lon) * 60.0; - sprintf(lons,"%03d%02.4f", (int)lon, minute); + snprintf(lons, sizeof(lons), "%03d%02.4f", (int)lon, minute); mx4200_send(peer, "%s,%03d,,,,,%s,%c,%s,%c,%.2f,%d", pmvxg, PMVXG_S_INITMODEA, @@ -961,18 +960,18 @@ char time_mark_valid, time_sync, op_mode; int sentence_type, valid; int year, day_of_year, month, day_of_month; - int hour, minute, second, leapsec; + int hour, minute, second, leapsec_warn; int oscillator_offset, time_mark_error, time_bias; pp = peer->procptr; up = (struct mx4200unit *)pp->unitptr; - leapsec = 0; /* Not all receivers output leap second warnings (!) */ + leapsec_warn = 0; /* Not all receivers output leap second warnings (!) */ sscanf(pp->a_lastcode, "$PMVXG,%d,%c,%d,%d,%d,%d:%d:%d,%c,%c,%d,%d,%d,%d", &sentence_type, &time_mark_valid, &year, &month, &day_of_month, &hour, &minute, &second, &time_sync, &op_mode, - &oscillator_offset, &time_mark_error, &time_bias, &leapsec); + &oscillator_offset, &time_mark_error, &time_bias, &leapsec_warn); if (sentence_type != PMVXG_D_TRECOVOUT) return ("wrong rec-type"); @@ -1005,8 +1004,8 @@ mx4200_debug(peer, "mx4200_parse_t: bad time %02d:%02d:%02d", hour, minute, second); - if (leapsec != 0) - mx4200_debug(peer, " (leap %+d\n)", leapsec); + if (leapsec_warn != 0) + mx4200_debug(peer, " (leap %+d\n)", leapsec_warn); mx4200_debug(peer, "\n"); refclock_report(peer, CEVNT_BADTIME); return ("bad time"); @@ -1068,7 +1067,7 @@ /* * Setup leap second indicator */ - switch (leapsec) { + switch (leapsec_warn) { case 0: pp->leap = LEAP_NOWARNING; break; @@ -1085,12 +1084,12 @@ /* * Any change to the leap second warning status? */ - if (leapsec != up->last_leap ) { + if (leapsec_warn != up->last_leap ) { msyslog(LOG_DEBUG, "mx4200: leap second warning: %d to %d (%d)", - up->last_leap, leapsec, pp->leap); + up->last_leap, leapsec_warn, pp->leap); } - up->last_leap = leapsec; + up->last_leap = leapsec_warn; /* * Copy time data for billboard monitoring. @@ -1520,14 +1519,14 @@ if (time_pps_fetch(up->pps_h, PPS_TSFMT_TSPEC, &(up->pps_i), &timeout) < 0) { mx4200_debug(peer, - "mx4200_pps: time_pps_fetch: serial=%ul, %s\n", + "mx4200_pps: time_pps_fetch: serial=%lu, %s\n", (unsigned long)up->pps_i.assert_sequence, strerror(errno)); refclock_report(peer, CEVNT_FAULT); return(1); } if (temp_serial == up->pps_i.assert_sequence) { mx4200_debug(peer, - "mx4200_pps: assert_sequence serial not incrementing: %ul\n", + "mx4200_pps: assert_sequence serial not incrementing: %lu\n", (unsigned long)up->pps_i.assert_sequence); refclock_report(peer, CEVNT_FAULT); return(1); @@ -1540,7 +1539,7 @@ if (up->pps_i.assert_sequence == up->lastserial) { mx4200_debug(peer, "mx4200_pps: no new pps event\n"); } else { - mx4200_debug(peer, "mx4200_pps: missed %ul pps events\n", + mx4200_debug(peer, "mx4200_pps: missed %lu pps events\n", up->pps_i.assert_sequence - up->lastserial - 1UL); } refclock_report(peer, CEVNT_FAULT); diff -urN src/contrib/ntp/ntpd/refclock_neoclock4x.c src.ntp/contrib/ntp/ntpd/refclock_neoclock4x.c --- src/contrib/ntp/ntpd/refclock_neoclock4x.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_neoclock4x.c 2009-12-20 06:21:42.000000000 +0100 @@ -3,18 +3,11 @@ * Refclock_neoclock4x.c * - NeoClock4X driver for DCF77 or FIA Timecode * - * Date: 2006-01-11 v1.15 + * Date: 2009-12-04 v1.16 * * see http://www.linum.com/redir/jump/id=neoclock4x&action=redir * for details about the NeoClock4X device * - * Copyright (C) 2002-2004 by Linum Software GmbH - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - * - * */ #ifdef HAVE_CONFIG_H @@ -109,7 +102,7 @@ #define NEOCLOCK4X_OFFSET_ANTENNA2 33 #define NEOCLOCK4X_OFFSET_CRC 35 -#define NEOCLOCK4X_DRIVER_VERSION "1.15 (2006-01-11)" +#define NEOCLOCK4X_DRIVER_VERSION "1.16 (2009-12-04)" #define NSEC_TO_MILLI 1000000 @@ -138,20 +131,20 @@ int utc_msec; }; -static int neoclock4x_start P((int, struct peer *)); -static void neoclock4x_shutdown P((int, struct peer *)); -static void neoclock4x_receive P((struct recvbuf *)); -static void neoclock4x_poll P((int, struct peer *)); -static void neoclock4x_control P((int, struct refclockstat *, struct refclockstat *, struct peer *)); - -static int neol_atoi_len P((const char str[], int *, int)); -static int neol_hexatoi_len P((const char str[], int *, int)); -static void neol_jdn_to_ymd P((unsigned long, int *, int *, int *)); -static void neol_localtime P((unsigned long, int* , int*, int*, int*, int*, int*)); -static unsigned long neol_mktime P((int, int, int, int, int, int)); +static int neoclock4x_start (int, struct peer *); +static void neoclock4x_shutdown (int, struct peer *); +static void neoclock4x_receive (struct recvbuf *); +static void neoclock4x_poll (int, struct peer *); +static void neoclock4x_control (int, struct refclockstat *, struct refclockstat *, struct peer *); + +static int neol_atoi_len (const char str[], int *, int); +static int neol_hexatoi_len (const char str[], int *, int); +static void neol_jdn_to_ymd (unsigned long, int *, int *, int *); +static void neol_localtime (unsigned long, int* , int*, int*, int*, int*, int*); +static unsigned long neol_mktime (int, int, int, int, int, int); #if !defined(NEOCLOCK4X_FIRMWARE) -static int neol_query_firmware P((int, int, char *, int)); -static int neol_check_firmware P((int, const char*, char *)); +static int neol_query_firmware (int, int, char *, int); +static int neol_check_firmware (int, const char*, char *); #endif struct refclock refclock_neoclock4x = { @@ -1024,6 +1017,12 @@ { NLOG(NLOG_CLOCKINFO) msyslog(LOG_INFO, "NeoClock4X(%d): firmware version: %s", unit, firmware); + + if(strstr(firmware, "/R2")) + { + msyslog(LOG_INFO, "NeoClock4X(%d): Your NeoClock4X uses the new R2 firmware release. Please note the changed LED behaviour.", unit); + } + } return (flag); @@ -1110,4 +1109,16 @@ * - remove some unsued #ifdefs * - fix nsec calculation, closes #499 * + * 2009/12/04 cjh + * Revision 1.16 + * - change license to ntp COPYRIGHT notice. This should allow Debian + * to add this refclock driver in further releases. + * - detect R2 hardware + * */ + + + + + + diff -urN src/contrib/ntp/ntpd/refclock_nmea.c src.ntp/contrib/ntp/ntpd/refclock_nmea.c --- src/contrib/ntp/ntpd/refclock_nmea.c 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/refclock_nmea.c 2010-05-03 12:01:12.000000000 +0200 @@ -2,6 +2,18 @@ * refclock_nmea.c - clock driver for an NMEA GPS CLOCK * Michael Petry Jun 20, 1994 * based on refclock_heathn.c + * + * Updated to add support for Accord GPS Clock + * Venu Gopal Dec 05, 2007 + * neo.venu@gmail.com, venugopal_d@pgad.gov.in + * + * Updated to process 'time1' fudge factor + * Venu Gopal May 05, 2008 + * + * Converted to common PPSAPI code, separate PPS fudge time1 + * from serial timecode fudge time2. + * Dave Hart July 1, 2009 + * hart@ntp.org, davehart@davehart.com */ #ifdef HAVE_CONFIG_H #include @@ -9,6 +21,7 @@ #if defined(REFCLOCK) && defined(CLOCK_NMEA) +#include #include #include @@ -20,18 +33,19 @@ #ifdef HAVE_PPSAPI # include "ppsapi_timepps.h" +#include "refclock_atom.h" #endif /* HAVE_PPSAPI */ #ifdef SYS_WINNT +#undef write /* ports/winnt/include/config.h: #define write _write */ extern int async_write(int, const void *, unsigned int); -#undef write #define write(fd, data, octets) async_write(fd, data, octets) #endif /* - * This driver supports the NMEA GPS Receiver with + * This driver supports NMEA-compatible GPS receivers * - * Protype was refclock_trak.c, Thanks a lot. + * Prototype was refclock_trak.c, Thanks a lot. * * The receiver used spits out the NMEA sentences for boat navigation. * And you thought it was an information superhighway. Try a raging river @@ -52,17 +66,32 @@ * bit 0 - enables RMC (1) * bit 1 - enables GGA (2) * bit 2 - enables GLL (4) - * multiple sentences may be selected - */ + * bit 3 - enables ZDA (8) - Standard Time & Date + * bit 3 - enables ZDG (8) - Accord GPS Clock's custom sentence with GPS time + * very close to standard ZDA + * + * Multiple sentences may be selected except when ZDG/ZDA is selected. + * + * bit 4/5/6 - selects the baudrate for serial port : + * 0 for 4800 (default) + * 1 for 9600 + * 2 for 19200 + * 3 for 38400 + * 4 for 57600 + * 5 for 115200 + */ +#define NMEA_MESSAGE_MASK_OLD 0x07 +#define NMEA_MESSAGE_MASK_SINGLE 0x08 +#define NMEA_MESSAGE_MASK (NMEA_MESSAGE_MASK_OLD | NMEA_MESSAGE_MASK_SINGLE) + +#define NMEA_BAUDRATE_MASK 0x70 +#define NMEA_BAUDRATE_SHIFT 4 /* * Definitions */ -#ifdef SYS_WINNT -# define DEVICE "COM%d:" /* COM 1 - 3 supported */ -#else -# define DEVICE "/dev/gps%d" /* name of radio device */ -#endif +#define DEVICE "/dev/gps%d" /* GPS serial device */ +#define PPSDEV "/dev/gpspps%d" /* PPSAPI device override */ #define SPEED232 B4800 /* uart speed (4800 bps) */ #define PRECISION (-9) /* precision assumed (about 2 ms) */ #define PPS_PRECISION (-20) /* precision assumed (about 1 us) */ @@ -70,62 +99,66 @@ #define DESCRIPTION "NMEA GPS Clock" /* who we are */ #define NANOSECOND 1000000000 /* one second (ns) */ #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 - * leap. - */ -static int day1tab[] = {31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31}; -static int day2tab[] = {31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31}; +#ifndef O_NOCTTY +#define M_NOCTTY 0 +#else +#define M_NOCTTY O_NOCTTY +#endif +#ifndef O_NONBLOCK +#define M_NONBLOCK 0 +#else +#define M_NONBLOCK O_NONBLOCK +#endif +#define PPSOPENMODE (O_RDWR | M_NOCTTY | M_NONBLOCK) /* * Unit control structure */ struct nmeaunit { - int pollcnt; /* poll message counter */ - int polled; /* Hand in a sample? */ - l_fp tstamp; /* timestamp of last poll */ #ifdef HAVE_PPSAPI - struct timespec ts; /* last timestamp */ - pps_params_t pps_params; /* pps parameters */ - pps_info_t pps_info; /* last pps data */ - pps_handle_t handle; /* pps handlebars */ + struct refclock_atom atom; /* PPSAPI structure */ + int ppsapi_tried; /* attempt PPSAPI once */ + int ppsapi_lit; /* time_pps_create() worked */ + int ppsapi_fd; /* fd used with PPSAPI */ + int tcount; /* timecode sample counter */ + int pcount; /* PPS sample counter */ #endif /* HAVE_PPSAPI */ + l_fp tstamp; /* timestamp of last poll */ + int gps_time; /* 0 UTC, 1 GPS time */ }; /* * Function prototypes */ -static int nmea_start P((int, struct peer *)); -static void nmea_shutdown P((int, struct peer *)); +static int nmea_start (int, struct peer *); +static void nmea_shutdown (int, struct peer *); +static void nmea_receive (struct recvbuf *); +static void nmea_poll (int, struct peer *); #ifdef HAVE_PPSAPI -static void nmea_control P((int, struct refclockstat *, struct - refclockstat *, struct peer *)); -static int nmea_ppsapi P((struct peer *, int, int)); -static int nmea_pps P((struct nmeaunit *, l_fp *)); +static void nmea_control (int, struct refclockstat *, + struct refclockstat *, struct peer *); +static void nmea_timer (int, struct peer *); +#define NMEA_CONTROL nmea_control +#define NMEA_TIMER nmea_timer +#else +#define NMEA_CONTROL noentry +#define NMEA_TIMER noentry #endif /* HAVE_PPSAPI */ -static void nmea_receive P((struct recvbuf *)); -static void nmea_poll P((int, struct peer *)); -static void gps_send P((int, const char *, struct peer *)); -static char *field_parse P((char *, int)); +static void gps_send (int, const char *, struct peer *); +static char * field_parse (char *, int); +static int nmea_checksum_ok(const char *); /* * Transfer vector */ struct refclock refclock_nmea = { nmea_start, /* start up driver */ - nmea_shutdown, /* shut down driver */ + nmea_shutdown, /* shut down driver */ nmea_poll, /* transmit poll message */ -#ifdef HAVE_PPSAPI - nmea_control, /* fudge control */ -#else - noentry, /* fudge control */ -#endif /* HAVE_PPSAPI */ + NMEA_CONTROL, /* fudge control */ noentry, /* initialize driver */ noentry, /* buginfo */ - NOFLAGS /* not used */ + NMEA_TIMER /* called once per second */ }; /* @@ -141,77 +174,123 @@ struct refclockproc *pp; int fd; char device[20]; + int baudrate; + char *baudtext; + + pp = peer->procptr; /* * Open serial port. Use CLK line discipline, if available. */ - (void)sprintf(device, DEVICE, unit); + snprintf(device, sizeof(device), DEVICE, unit); + + /* + * Opening the serial port with appropriate baudrate + * based on the value of bit 4/5/6 + */ + switch ((peer->ttl & NMEA_BAUDRATE_MASK) >> NMEA_BAUDRATE_SHIFT) { + case 0: + case 6: + case 7: + default: + baudrate = SPEED232; + baudtext = "4800"; + break; + case 1: + baudrate = B9600; + baudtext = "9600"; + break; + case 2: + baudrate = B19200; + baudtext = "19200"; + break; + case 3: + baudrate = B38400; + baudtext = "38400"; + break; +#ifdef B57600 + case 4: + baudrate = B57600; + baudtext = "57600"; + break; +#endif +#ifdef B115200 + case 5: + baudrate = B115200; + baudtext = "115200"; + break; +#endif + } - fd = refclock_open(device, SPEED232, LDISC_CLK); + fd = refclock_open(device, baudrate, LDISC_CLK); + if (fd <= 0) { #ifdef HAVE_READLINK - /* nmead support added by Jon Miner (cp_n18@yahoo.com) - * - * See http://home.hiwaay.net/~taylorc/gps/nmea-server/ - * for information about nmead - * - * To use this, you need to create a link from /dev/gpsX to - * the server:port where nmead is running. Something like this: - * - * ln -s server:port /dev/gps1 - */ - char buffer[80]; - char *nmea_host; - int nmea_port; - int len; - struct hostent *he; - struct protoent *p; - struct sockaddr_in so_addr; - - if ((len = readlink(device,buffer,sizeof(buffer))) == -1) - return(0); - buffer[len] = 0; - - if ((nmea_host = strtok(buffer,":")) == NULL) - return(0); - - nmea_port = atoi(strtok(NULL,":")); - - if ((he = gethostbyname(nmea_host)) == NULL) - return(0); - if ((p = getprotobyname("ip")) == NULL) - return(0); - so_addr.sin_family = AF_INET; - so_addr.sin_port = htons(nmea_port); - so_addr.sin_addr = *((struct in_addr *) he->h_addr); - - if ((fd = socket(PF_INET,SOCK_STREAM,p->p_proto)) == -1) - return(0); - if (connect(fd,(struct sockaddr *)&so_addr,SOCKLEN(&so_addr)) == -1) { - close(fd); - return (0); - } + /* nmead support added by Jon Miner (cp_n18@yahoo.com) + * + * See http://home.hiwaay.net/~taylorc/gps/nmea-server/ + * for information about nmead + * + * To use this, you need to create a link from /dev/gpsX to + * the server:port where nmead is running. Something like this: + * + * ln -s server:port /dev/gps1 + */ + char buffer[80]; + char *nmea_host, *nmea_tail; + int nmea_port; + int len; + struct hostent *he; + struct protoent *p; + struct sockaddr_in so_addr; + + if ((len = readlink(device,buffer,sizeof(buffer))) == -1) + return(0); + buffer[len] = 0; + + if ((nmea_host = strtok(buffer,":")) == NULL) + return(0); + if ((nmea_tail = strtok(NULL,":")) == NULL) + return(0); + + nmea_port = atoi(nmea_tail); + + if ((he = gethostbyname(nmea_host)) == NULL) + return(0); + if ((p = getprotobyname("tcp")) == NULL) + return(0); + memset(&so_addr, 0, sizeof(so_addr)); + so_addr.sin_family = AF_INET; + so_addr.sin_port = htons(nmea_port); + so_addr.sin_addr = *((struct in_addr *) he->h_addr); + + if ((fd = socket(PF_INET,SOCK_STREAM,p->p_proto)) == -1) + return(0); + if (connect(fd,(struct sockaddr *)&so_addr, sizeof(so_addr)) == -1) { + close(fd); + return (0); + } #else - return (0); + pp->io.fd = -1; + return (0); #endif - } + } + + msyslog(LOG_NOTICE, "%s serial %s open at %s bps", + refnumtoa(&peer->srcadr), device, baudtext); /* * Allocate and initialize unit structure */ - up = (struct nmeaunit *)emalloc(sizeof(struct nmeaunit)); - if (up == NULL) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct nmeaunit)); - pp = peer->procptr; + up = emalloc(sizeof(*up)); + memset(up, 0, sizeof(*up)); pp->io.clock_recv = nmea_receive; pp->io.srcclock = (caddr_t)peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + pp->io.fd = -1; + close(fd); free(up); return (0); } @@ -222,29 +301,19 @@ */ peer->precision = PRECISION; pp->clockdesc = DESCRIPTION; - memcpy((char *)&pp->refid, REFID, 4); - up->pollcnt = 2; - gps_send(pp->io.fd,"$PMOTG,RMC,0000*1D\r\n", peer); + memcpy(&pp->refid, REFID, 4); + + gps_send(fd,"$PMOTG,RMC,0000*1D\r\n", peer); -#ifdef HAVE_PPSAPI - /* - * Start the PPSAPI interface if it is there. Default to use - * the assert edge and do not enable the kernel hardpps. - */ - if (time_pps_create(fd, &up->handle) < 0) { - up->handle = 0; - msyslog(LOG_ERR, - "refclock_nmea: time_pps_create failed: %m"); - return (1); - } - return(nmea_ppsapi(peer, 0, 0)); -#else return (1); -#endif /* HAVE_PPSAPI */ } + /* * nmea_shutdown - shut down a GPS clock + * + * NOTE this routine is called after nmea_start() returns failure, + * as well as during a normal shutdown due to ntpq :config unpeer. */ static void nmea_shutdown( @@ -255,150 +324,124 @@ register struct nmeaunit *up; struct refclockproc *pp; + UNUSED_ARG(unit); + pp = peer->procptr; up = (struct nmeaunit *)pp->unitptr; + if (up != NULL) { #ifdef HAVE_PPSAPI - if (up->handle != 0) - time_pps_destroy(up->handle); -#endif /* HAVE_PPSAPI */ - io_closeclock(&pp->io); - free(up); + if (up->ppsapi_lit) { + time_pps_destroy(up->atom.handle); + if (up->ppsapi_fd != pp->io.fd) + close(up->ppsapi_fd); + } +#endif + free(up); + } + if (-1 != pp->io.fd) + io_closeclock(&pp->io); } -#ifdef HAVE_PPSAPI /* - * nmea_control - fudge control + * nmea_control - configure fudge params */ +#ifdef HAVE_PPSAPI static void nmea_control( - int unit, /* unit (not used */ - struct refclockstat *in, /* input parameters (not uded) */ - struct refclockstat *out, /* output parameters (not used) */ - struct peer *peer /* peer structure pointer */ + int unit, + struct refclockstat *in_st, + struct refclockstat *out_st, + struct peer *peer ) { + char device[32]; + register struct nmeaunit *up; struct refclockproc *pp; + int pps_fd; + + UNUSED_ARG(in_st); + UNUSED_ARG(out_st); pp = peer->procptr; - nmea_ppsapi(peer, pp->sloppyclockflag & CLK_FLAG2, - pp->sloppyclockflag & CLK_FLAG3); -} + up = (struct nmeaunit *)pp->unitptr; + if (!(CLK_FLAG1 & pp->sloppyclockflag)) { + if (!up->ppsapi_tried) + return; + up->ppsapi_tried = 0; + if (!up->ppsapi_lit) + return; + peer->flags &= ~FLAG_PPS; + peer->precision = PRECISION; + time_pps_destroy(up->atom.handle); + if (up->ppsapi_fd != pp->io.fd) + close(up->ppsapi_fd); + up->atom.handle = 0; + up->ppsapi_lit = 0; + up->ppsapi_fd = -1; + return; + } -/* - * Initialize PPSAPI - */ -int -nmea_ppsapi( - struct peer *peer, /* peer structure pointer */ - int enb_clear, /* clear enable */ - int enb_hardpps /* hardpps enable */ - ) -{ - struct refclockproc *pp; - struct nmeaunit *up; - int capability; + if (up->ppsapi_tried) + return; + /* + * Light up the PPSAPI interface. + */ + up->ppsapi_tried = 1; - pp = peer->procptr; - up = (struct nmeaunit *)pp->unitptr; - if (time_pps_getcap(up->handle, &capability) < 0) { - msyslog(LOG_ERR, - "refclock_nmea: time_pps_getcap failed: %m"); - return (0); - } - memset(&up->pps_params, 0, sizeof(pps_params_t)); - if (enb_clear) - up->pps_params.mode = capability & PPS_CAPTURECLEAR; - else - up->pps_params.mode = capability & PPS_CAPTUREASSERT; - if (!up->pps_params.mode) { - msyslog(LOG_ERR, - "refclock_nmea: invalid capture edge %d", - !enb_clear); - return (0); - } - up->pps_params.mode |= PPS_TSFMT_TSPEC; - if (time_pps_setparams(up->handle, &up->pps_params) < 0) { - msyslog(LOG_ERR, - "refclock_nmea: time_pps_setparams failed: %m"); - return (0); - } - if (enb_hardpps) { - if (time_pps_kcbind(up->handle, PPS_KC_HARDPPS, - up->pps_params.mode & ~PPS_TSFMT_TSPEC, - PPS_TSFMT_TSPEC) < 0) { - msyslog(LOG_ERR, - "refclock_nmea: time_pps_kcbind failed: %m"); - return (0); - } - pps_enable = 1; - } - peer->precision = PPS_PRECISION; + /* + * if /dev/gpspps$UNIT can be opened that will be used for + * PPSAPI. Otherwise, the GPS serial device /dev/gps$UNIT + * already opened is used for PPSAPI as well. + */ + snprintf(device, sizeof(device), PPSDEV, unit); + + pps_fd = open(device, PPSOPENMODE, S_IRUSR | S_IWUSR); -#if DEBUG - if (debug) { - time_pps_getparams(up->handle, &up->pps_params); - printf( - "refclock_ppsapi: capability 0x%x version %d mode 0x%x kern %d\n", - capability, up->pps_params.api_version, - up->pps_params.mode, enb_hardpps); + if (-1 == pps_fd) + pps_fd = pp->io.fd; + + if (refclock_ppsapi(pps_fd, &up->atom)) { + up->ppsapi_lit = 1; + up->ppsapi_fd = pps_fd; + return; } -#endif - return (1); + NLOG(NLOG_CLOCKINFO) + msyslog(LOG_WARNING, "%s flag1 1 but PPSAPI fails", + refnumtoa(&peer->srcadr)); } +#endif /* HAVE_PPSAPI */ + /* - * Get PPSAPI timestamps. - * - * Return 0 on failure and 1 on success. + * nmea_timer - called once per second, fetches PPS + * timestamp and stuffs in median filter. */ -static int -nmea_pps( - struct nmeaunit *up, - l_fp *tsptr +#ifdef HAVE_PPSAPI +static void +nmea_timer( + int unit, + struct peer * peer ) { - pps_info_t pps_info; - struct timespec timeout, ts; - double dtemp; - l_fp tstmp; + struct nmeaunit *up; + struct refclockproc *pp; - /* - * Convert the timespec nanoseconds field to ntp l_fp units. - */ - if (up->handle == 0) - return (0); - timeout.tv_sec = 0; - timeout.tv_nsec = 0; - memcpy(&pps_info, &up->pps_info, sizeof(pps_info_t)); - if (time_pps_fetch(up->handle, PPS_TSFMT_TSPEC, &up->pps_info, - &timeout) < 0) - return (0); - if (up->pps_params.mode & PPS_CAPTUREASSERT) { - if (pps_info.assert_sequence == - up->pps_info.assert_sequence) - return (0); - ts = up->pps_info.assert_timestamp; - } else if (up->pps_params.mode & PPS_CAPTURECLEAR) { - if (pps_info.clear_sequence == - up->pps_info.clear_sequence) - return (0); - ts = up->pps_info.clear_timestamp; - } else { - return (0); - } - if ((up->ts.tv_sec == ts.tv_sec) && (up->ts.tv_nsec == ts.tv_nsec)) - return (0); - up->ts = ts; + UNUSED_ARG(unit); - tstmp.l_ui = ts.tv_sec + JAN_1970; - dtemp = ts.tv_nsec * FRAC / 1e9; - tstmp.l_uf = (u_int32)dtemp; - *tsptr = tstmp; - return (1); + pp = peer->procptr; + up = (struct nmeaunit *)pp->unitptr; + + if (up->ppsapi_lit && + refclock_pps(peer, &up->atom, pp->sloppyclockflag) > 0) { + up->pcount++, + peer->flags |= FLAG_PPS; + peer->precision = PPS_PRECISION; + } } -#endif /* HAVE_PPSAPI */ +#endif /* HAVE_PPSAPI */ + /* * nmea_receive - receive data from the serial interface @@ -412,160 +455,204 @@ struct refclockproc *pp; struct peer *peer; int month, day; - int i; - char *cp, *dp; + char *cp, *dp, *msg; int cmdtype; + int cmdtypezdg = 0; /* Use these variables to hold data until we decide its worth keeping */ char rd_lastcode[BMAX]; - l_fp rd_tmp; - u_short rd_lencode; + l_fp rd_timestamp; + int rd_lencode; /* * Initialize pointers and read the timecode and timestamp */ - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; up = (struct nmeaunit *)pp->unitptr; - rd_lencode = (u_short)refclock_gtlin(rbufp, rd_lastcode, BMAX, &rd_tmp); + + rd_lencode = refclock_gtlin( + rbufp, + rd_lastcode, + sizeof(rd_lastcode), + &rd_timestamp); /* * There is a case that a gives back a "blank" line */ if (rd_lencode == 0) - return; + return; -#ifdef DEBUG - if (debug) - printf("nmea: gpsread %d %s\n", rd_lencode, - rd_lastcode); -#endif + DPRINTF(1, ("nmea: gpsread %d %s\n", rd_lencode, rd_lastcode)); /* * We check the timecode format and decode its contents. The * we only care about a few of them. The most important being * the $GPRMC format * $GPRMC,hhmmss,a,fddmm.xx,n,dddmmm.xx,w,zz.z,yyy.,ddmmyy,dd,v*CC - * For Magellan (ColorTrak) GLL probably datum (order of sentences) - * also mode (0,1,2,3) select sentence ANY/ALL, RMC, GGA, GLL + * mode (0,1,2,3) selects sentence ANY/ALL, RMC, GGA, GLL, ZDA * $GPGLL,3513.8385,S,14900.7851,E,232420.594,A*21 - * $GPGGA,232420.59,3513.8385,S,14900.7851,E,1,05,3.4,00519,M,,,,*3F - * $GPRMB,... + * $GPGGA,232420.59,3513.8385,S,14900.7851,E,1,05,3.4,00519,M,,,,*3F * $GPRMC,232418.19,A,3513.8386,S,14900.7853,E,00.0,000.0,121199,12.,E*77 - * $GPAPB,... - * $GPGSA,... - * $GPGSV,... - * $GPGSV,... - */ -#define GPXXX 0 -#define GPRMC 1 -#define GPGGA 2 -#define GPGLL 4 + * + * Defining GPZDA to support Standard Time & Date + * sentence. The sentence has the following format + * + * $--ZDA,HHMMSS.SS,DD,MM,YYYY,TH,TM,*CS + * + * Apart from the familiar fields, + * 'TH' Time zone Hours + * 'TM' Time zone Minutes + * + * Defining GPZDG to support Accord GPS Clock's custom NMEA + * sentence. The sentence has the following format + * + * $GPZDG,HHMMSS.S,DD,MM,YYYY,AA.BB,V*CS + * + * It contains the GPS timestamp valid for next PPS pulse. + * Apart from the familiar fields, + * 'AA.BB' denotes the signal strength( should be < 05.00 ) + * 'V' denotes the GPS sync status : + * '0' indicates INVALID time, + * '1' indicates accuracy of +/-20 ms + * '2' indicates accuracy of +/-100 ns + */ +#define GPXXX 0 /* any/all */ +#define GPRMC 1 +#define GPGGA 2 +#define GPGLL 4 +#define GPZDG_ZDA 8 + cp = rd_lastcode; cmdtype=0; - if(strncmp(cp,"$GPRMC",6)==0) { - cmdtype=GPRMC; - } - else if(strncmp(cp,"$GPGGA",6)==0) { - cmdtype=GPGGA; - } - else if(strncmp(cp,"$GPGLL",6)==0) { - cmdtype=GPGLL; - } - else if(strncmp(cp,"$GPXXX",6)==0) { - cmdtype=GPXXX; - } - else - return; - + if (cp[0] == '$') { + /* Allow for GLGGA and GPGGA etc. */ + msg = cp + 3; + + if (strncmp(msg, "RMC", 3) == 0) + cmdtype = GPRMC; + else if (strncmp(msg, "GGA", 3) == 0) + cmdtype = GPGGA; + else if (strncmp(msg, "GLL", 3) == 0) + cmdtype = GPGLL; + else if (strncmp(msg, "ZD", 2) == 0) { + cmdtype = GPZDG_ZDA; + if ('G' == msg[2]) + cmdtypezdg = 1; + else if ('A' != msg[2]) + return; + } else + return; + } else + return; /* See if I want to process this message type */ - if ( ((peer->ttl == 0) && (cmdtype != GPRMC)) - || ((peer->ttl != 0) && !(cmdtype & peer->ttl)) ) + if (peer->ttl && !(cmdtype & (peer->ttl & NMEA_MESSAGE_MASK))) return; - pp->lencode = rd_lencode; - strcpy(pp->a_lastcode,rd_lastcode); - cp = pp->a_lastcode; + /* + * $GPZDG provides GPS time not UTC, and the two mix poorly. + * Once have processed a $GPZDG, do not process any further + * UTC sentences (all but $GPZDG currently). + */ + if (up->gps_time && !cmdtypezdg) + return; + + /* make sure it came in clean */ + if (!nmea_checksum_ok(rd_lastcode)) { + refclock_report(peer, CEVNT_BADREPLY); + return; + } - pp->lastrec = up->tstamp = rd_tmp; - up->pollcnt = 2; + pp->lencode = (u_short) rd_lencode; + memcpy(pp->a_lastcode, rd_lastcode, pp->lencode + 1); + cp = pp->a_lastcode; -#ifdef DEBUG - if (debug) - printf("nmea: timecode %d %s\n", pp->lencode, - pp->a_lastcode); -#endif + up->tstamp = rd_timestamp; + pp->lastrec = up->tstamp; + DPRINTF(1, ("nmea: timecode %d %s\n", pp->lencode, pp->a_lastcode)); /* Grab field depending on clock string type */ - switch( cmdtype ) { - case GPRMC: + switch (cmdtype) { + + case GPRMC: /* * Test for synchronization. Check for quality byte. */ - dp = field_parse(cp,2); - if( dp[0] != 'A') + dp = field_parse(cp, 2); + if (dp[0] != 'A') pp->leap = LEAP_NOTINSYNC; else pp->leap = LEAP_NOWARNING; /* Now point at the time field */ - dp = field_parse(cp,1); + dp = field_parse(cp, 1); break; - - case GPGGA: + case GPGGA: /* * Test for synchronization. Check for quality byte. */ - dp = field_parse(cp,6); - if( dp[0] == '0') + dp = field_parse(cp, 6); + if (dp[0] == '0') pp->leap = LEAP_NOTINSYNC; else pp->leap = LEAP_NOWARNING; /* Now point at the time field */ - dp = field_parse(cp,1); + dp = field_parse(cp, 1); break; - - case GPGLL: + case GPGLL: /* * Test for synchronization. Check for quality byte. */ - dp = field_parse(cp,6); - if( dp[0] != 'A') + dp = field_parse(cp, 6); + if (dp[0] != 'A') pp->leap = LEAP_NOTINSYNC; else pp->leap = LEAP_NOWARNING; /* Now point at the time field */ - dp = field_parse(cp,5); + dp = field_parse(cp, 5); break; + + case GPZDG_ZDA: + /* + * Test for synchronization. For $GPZDG check for validity of GPS time. + */ + if (cmdtypezdg) { + dp = field_parse(cp, 6); + if (dp[0] == '0') + pp->leap = LEAP_NOTINSYNC; + else + pp->leap = LEAP_NOWARNING; + } else + pp->leap = LEAP_NOWARNING; + /* Now point at the time field */ + dp = field_parse(cp, 1); + break; - case GPXXX: + default: return; - default: - return; - } - /* - * Check time code format of NMEA - */ - - if( !isdigit((int)dp[0]) || - !isdigit((int)dp[1]) || - !isdigit((int)dp[2]) || - !isdigit((int)dp[3]) || - !isdigit((int)dp[4]) || - !isdigit((int)dp[5]) - ) { - refclock_report(peer, CEVNT_BADREPLY); - return; - } + /* + * Check time code format of NMEA + */ + if (!isdigit((int)dp[0]) || + !isdigit((int)dp[1]) || + !isdigit((int)dp[2]) || + !isdigit((int)dp[3]) || + !isdigit((int)dp[4]) || + !isdigit((int)dp[5])) { + DPRINTF(1, ("NMEA time code %c%c%c%c%c%c non-numeric", + dp[0], dp[1], dp[2], dp[3], dp[4], dp[5])); + refclock_report(peer, CEVNT_BADTIME); + return; + } /* * Convert time and check values. @@ -573,9 +660,10 @@ pp->hour = ((dp[0] - '0') * 10) + dp[1] - '0'; pp->minute = ((dp[2] - '0') * 10) + dp[3] - '0'; pp->second = ((dp[4] - '0') * 10) + dp[5] - '0'; - /* Default to 0 milliseconds, if decimal convert milliseconds in - one, two or three digits - */ + /* + * Default to 0 milliseconds, if decimal convert milliseconds in + * one, two or three digits + */ pp->nsec = 0; if (dp[6] == '.') { if (isdigit((int)dp[7])) { @@ -589,103 +677,173 @@ } } - if (pp->hour > 23 || pp->minute > 59 || pp->second > 59 - || pp->nsec > 1000000000) { + /* + * Manipulating GPS timestamp in GPZDG as the seconds field + * is valid for next PPS tick. Just rolling back the second, + * minute and hour fields appopriately + */ + if (cmdtypezdg) { + if (pp->second == 0) { + pp->second = 59; + if (pp->minute == 0) { + pp->minute = 59; + if (pp->hour == 0) + pp->hour = 23; + } + } else + pp->second -= 1; + } + + if (pp->hour > 23 || pp->minute > 59 || + pp->second > 59 || pp->nsec > 1000000000) { + + DPRINTF(1, ("NMEA hour/min/sec/nsec range %02d:%02d:%02d.%09ld\n", + pp->hour, pp->minute, pp->second, pp->nsec)); refclock_report(peer, CEVNT_BADTIME); return; } - /* * Convert date and check values. */ - if (cmdtype==GPRMC) { - dp = field_parse(cp,9); - day = dp[0] - '0'; - day = (day * 10) + dp[1] - '0'; - month = dp[2] - '0'; - month = (month * 10) + dp[3] - '0'; - pp->year = dp[4] - '0'; - pp->year = (pp->year * 10) + dp[5] - '0'; - } - else { - /* only time */ - time_t tt = time(NULL); - struct tm * t = gmtime(&tt); - day = t->tm_mday; - month = t->tm_mon + 1; - pp->year= t->tm_year; + if (GPRMC == cmdtype) { + + dp = field_parse(cp,9); + day = dp[0] - '0'; + day = (day * 10) + dp[1] - '0'; + month = dp[2] - '0'; + month = (month * 10) + dp[3] - '0'; + pp->year = dp[4] - '0'; + pp->year = (pp->year * 10) + dp[5] - '0'; + + } else if (GPZDG_ZDA == cmdtype) { + + dp = field_parse(cp, 2); + day = 10 * (dp[0] - '0') + (dp[1] - '0'); + dp = field_parse(cp, 3); + month = 10 * (dp[0] - '0') + (dp[1] - '0'); + dp = field_parse(cp, 4); + pp->year = /* 1000 * (dp[0] - '0') + 100 * (dp[1] - '0') + */ 10 * (dp[2] - '0') + (dp[3] - '0'); + + } else { + /* only time */ + time_t tt = time(NULL); + struct tm * t = gmtime(&tt); + day = t->tm_mday; + month = t->tm_mon + 1; + pp->year= t->tm_year + 1900; } if (month < 1 || month > 12 || day < 1) { - refclock_report(peer, CEVNT_BADTIME); + refclock_report(peer, CEVNT_BADDATE); return; } - /* Hmmmm this will be a nono for 2100,2200,2300 but I don't think I'll be here */ - /* good thing that 2000 is a leap year */ - /* pp->year will be 00-99 if read from GPS, 00-> (years since 1900) from tm_year */ - if (pp->year % 4) { - if (day > day1tab[month - 1]) { - refclock_report(peer, CEVNT_BADTIME); - return; - } - for (i = 0; i < month - 1; i++) - day += day1tab[i]; - } else { - if (day > day2tab[month - 1]) { - refclock_report(peer, CEVNT_BADTIME); - return; - } - for (i = 0; i < month - 1; i++) - day += day2tab[i]; + /* pp->year will be 2 or 4 digits if read from GPS, 4 from gmtime */ + if (pp->year < 100) { + if (pp->year < 9) /* year of our line of code is 2009 */ + pp->year += 2100; + else + pp->year += 2000; } - pp->day = day; - -#ifdef HAVE_PPSAPI - /* - * If the PPSAPI is working, rather use its timestamps. - * assume that the PPS occurs on the second so blow any msec - */ - if (nmea_pps(up, &rd_tmp) == 1) { - pp->lastrec = up->tstamp = rd_tmp; - pp->nsec = 0; + /* pp->year now 4 digits as ymd2yd requires */ + day = ymd2yd(pp->year, month, day); + if (-1 == day) { + refclock_report(peer, CEVNT_BADDATE); + return; } -#endif /* HAVE_PPSAPI */ + pp->day = day; /* - * Process the new sample in the median filter and determine the - * reference clock offset and dispersion. We use lastrec as both - * the reference time and receive time, in order to avoid being - * cute, like setting the reference time later than the receive - * time, which may cause a paranoid protocol module to chuck out - * the data. + * If "fudge 127.127.20.__ flag4 1" is configured in ntp.conf, + * remove the location and checksum from the NMEA sentence + * recorded as the last timecode and visible to remote users + * with: + * + * ntpq -c clockvar + * + * Note that this also removes the location from the clockstats + * log (if it is enabled). Some NTP operators monitor their + * NMEA GPS using the change in location in clockstats over + * time as as a proxy for the quality of GPS reception and + * thereby time reported. */ + if (CLK_FLAG4 & pp->sloppyclockflag) { + /* + * Start by pointing cp and dp at the fields with + * longitude and latitude in the last timecode. + */ + switch (cmdtype) { - if (!refclock_process(pp)) { - refclock_report(peer, CEVNT_BADTIME); - return; - } + case GPGLL: + cp = field_parse(pp->a_lastcode, 1); + dp = field_parse(cp, 2); + break; + + case GPGGA: + cp = field_parse(pp->a_lastcode, 2); + dp = field_parse(cp, 2); + break; + + case GPRMC: + cp = field_parse(pp->a_lastcode, 3); + dp = field_parse(cp, 2); + break; + + case GPZDG_ZDA: + default: + cp = dp = NULL; + } + /* Blank the entire latitude & longitude. */ + while (cp) { + while (',' != *cp) { + if ('.' != *cp) + *cp = '_'; + cp++; + } + /* Longitude at cp then latitude at dp */ + if (cp < dp) + cp = dp; + else + cp = NULL; + } - /* - * Only go on if we had been polled. - */ - if (!up->polled) - return; - up->polled = 0; - pp->lastref = pp->lastrec; - refclock_receive(peer); + /* Blank the checksum, the last two characters */ + if (dp) { + cp = pp->a_lastcode + pp->lencode - 2; + if (0 == cp[2]) + cp[0] = cp[1] = '_'; + } - /* If we get here - what we got from the clock is OK, so say so */ - refclock_report(peer, CEVNT_NOMINAL); + } - record_clock_stats(&peer->srcadr, pp->a_lastcode); + /* + * Note if we're only using GPS timescale from now on. + */ + if (cmdtypezdg && !up->gps_time) { + up->gps_time = 1; + NLOG(NLOG_CLOCKINFO) + msyslog(LOG_INFO, "%s using only $GPZDG", + refnumtoa(&peer->srcadr)); + } + /* + * Process the new sample in the median filter and determine the + * timecode timestamp, but only if the PPS is not in control. + */ +#ifdef HAVE_PPSAPI + up->tcount++; + if (peer->flags & FLAG_PPS) + return; +#endif /* HAVE_PPSAPI */ + if (!refclock_process_f(pp, pp->fudgetime2)) + refclock_report(peer, CEVNT_BADTIME); } + /* * nmea_poll - called by the transmit procedure * @@ -703,20 +861,44 @@ pp = peer->procptr; up = (struct nmeaunit *)pp->unitptr; - if (up->pollcnt == 0) - refclock_report(peer, CEVNT_TIMEOUT); - else - up->pollcnt--; + + /* + * Process median filter samples. If none received, declare a + * timeout and keep going. + */ +#ifdef HAVE_PPSAPI + if (up->pcount == 0) { + peer->flags &= ~FLAG_PPS; + peer->precision = PRECISION; + } + if (up->tcount == 0) { + pp->coderecv = pp->codeproc; + refclock_report(peer, CEVNT_TIMEOUT); + return; + } + up->pcount = up->tcount = 0; +#else /* HAVE_PPSAPI */ + if (pp->coderecv == pp->codeproc) { + refclock_report(peer, CEVNT_TIMEOUT); + return; + } +#endif /* HAVE_PPSAPI */ + pp->polls++; - up->polled = 1; + pp->lastref = pp->lastrec; + refclock_receive(peer); + record_clock_stats(&peer->srcadr, pp->a_lastcode); /* - * usually nmea_receive can get a timestamp every second + * usually nmea_receive can get a timestamp every second, + * but at least one Motorola unit needs prompting each + * time. */ gps_send(pp->io.fd,"$PMOTG,RMC,0000*1D\r\n", peer); } + /* * * gps_send(fd,cmd, peer) Sends a command to the GPS receiver. @@ -735,12 +917,12 @@ struct peer *peer ) { - if (write(fd, cmd, strlen(cmd)) == -1) { refclock_report(peer, CEVNT_FAULT); } } + static char * field_parse( char *cp, @@ -750,14 +932,60 @@ char *tp; int i = fn; - for (tp = cp; *tp != '\0'; tp++) { + for (tp = cp; i && *tp; tp++) if (*tp == ',') - i--; - if (i == 0) - break; + i--; + + return tp; +} + + +/* + * nmea_checksum_ok verifies 8-bit XOR checksum is correct then returns 1 + * + * format is $XXXXX,1,2,3,4*ML + * + * 8-bit XOR of characters between $ and * noninclusive is transmitted + * in last two chars M and L holding most and least significant nibbles + * in hex representation such as: + * + * $GPGLL,5057.970,N,00146.110,E,142451,A*27 + * $GPVTG,089.0,T,,,15.2,N,,*7F + */ +int +nmea_checksum_ok( + const char *sentence + ) +{ + u_char my_cs; + u_long input_cs; + const char *p; + + my_cs = 0; + p = sentence; + + if ('$' != *p++) + return 0; + + for ( ; *p && '*' != *p; p++) { + + my_cs ^= *p; } - return (++tp); + + if ('*' != *p++) + return 0; + + if (0 == p[0] || 0 == p[1] || 0 != p[2]) + return 0; + + if (0 == hextoint(p, &input_cs)) + return 0; + + if (my_cs != input_cs) + return 0; + + return 1; } #else int refclock_nmea_bs; -#endif /* REFCLOCK */ +#endif /* REFCLOCK && CLOCK_NMEA */ diff -urN src/contrib/ntp/ntpd/refclock_oncore.c src.ntp/contrib/ntp/ntpd/refclock_oncore.c --- src/contrib/ntp/ntpd/refclock_oncore.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_oncore.c 2009-12-22 11:01:35.000000000 +0100 @@ -52,6 +52,48 @@ * MANUFACTUR DATE 2J17 MANUFACTUR DATE 3G15 * * -------------------------------------------------------------------------- + * Reg Clemens (June 2009) + * BUG[1220] OK, big patch, but mostly done mechanically. Change direct calls to write + * to clockstats to a call to oncore_log, which now calls the old routine plus msyslog. + * Have to set the LOG_LEVELS of the calls for msyslog, and this was done by hand. New + * routine oncore_log. + * -------------------------------------------------------------------------- + * Reg Clemens (June 2009) + * BUG[1218] The comment on where the oncore driver gets its input file does not + * agree with the code. Change the comment. + * -------------------------------------------------------------------------- + * Reg Clemens (June 2009) + * change exit statements to return(0) in main program. I had assumed that if the + * PPS driver did not start for some reason, we shuould stop NTPD itelf. Others + * disagree. We now give an ERR log message and stop this driver. + * -------------------------------------------------------------------------- + * Reg Clemens (June 2009) + * A bytes available message for the input subsystem (Debug message). + * -------------------------------------------------------------------------- + * Reg Clemens (Nov 2008) + * This code adds a message for TRAIM messages. Users often worry about the + * driver not starting up, and it is often because of signal strength being low. + * Low signal strength will give TRAIM messages. + * -------------------------------------------------------------------------- + * Reg Clemens (Nov 2008) + * Add waiting on Almanac Message. + * -------------------------------------------------------------------------- + * Reg Clemens (Nov 2008) + * Add back in @@Bl code to do the @@Bj/@@Gj that is in later ONCOREs + * LEAP SECONDS: All of the ONCORE receivers, VP -> M12T have the @@Bj command + * that says 'Leap Pending'. As documented it only becomes true in the month + * before the leap second is to be applied, but in practice at least some of + * the receivers turn this indicator on as soon as the message is posted, which + * can be 6months early. As such, we use the Bj command to turn on the + * instance->pp->leap indicator but only run this test in December and June for + * updates on 1Jan and 1July. + * + * The @@Gj command exists in later ONCOREs, and it gives the exact date + * and size of the Leap Update. It can be emulated in the VP using the @@Bl + * command which reads the raw Satellite Broadcast Messages. + * We use these two commands to print informative messages in the clockstats + * file once per day as soon as the message appears on the satellites. + * -------------------------------------------------------------------------- * Reg Clemens (Feb 2006) * Fix some gcc4 compiler complaints * Fix possible segfault in oncore_init_shmem @@ -141,6 +183,18 @@ # include #endif +struct Bl { + int dt_ls; + int dt_lsf; + int WN; + int DN; + int WN_lsf; + int DN_lsf; + int wn_flg; + int lsf_flg; + int Bl_day; +} Bl; + enum receive_state { ONCORE_NO_IDEA, ONCORE_CHECK_ID, @@ -265,10 +319,14 @@ u_char count4; /* cycles thru leap after Gj to issue Bj */ u_char count5; /* cycles thru get_timestamp waiting for valid UTC correction */ u_char count5_set; /* only set count5 once */ + u_char counta; /* count for waiting on almanac message */ u_char pollcnt; u_char timeout; /* count to retry Cj after Fa self-test */ + u_char max_len; /* max length message seen by oncore_log, for debugging */ + u_char max_count; /* count for message statistics */ struct RSM rsm; /* bits extracted from Receiver Status Msg in @@Ea */ + struct Bl Bl; /* Satellite Broadcast Data Message */ u_char printed; u_char polled; u_long ev_serial; @@ -281,6 +339,7 @@ u_char saw_At; u_char saw_Ay; u_char saw_Az; + s_char saw_Bj; s_char saw_Gj; u_char have_dH; u_char init_type; @@ -299,55 +358,57 @@ #define rcvbuf instance->Rcvbuf #define rcvptr instance->Rcvptr -static int oncore_start P((int, struct peer *)); -static void oncore_poll P((int, struct peer *)); -static void oncore_shutdown P((int, struct peer *)); -static void oncore_consume P((struct instance *)); -static void oncore_read_config P((struct instance *)); -static void oncore_receive P((struct recvbuf *)); -static int oncore_ppsapi P((struct instance *)); -static void oncore_get_timestamp P((struct instance *, long, long)); -static void oncore_init_shmem P((struct instance *)); - -static void oncore_antenna_report P((struct instance *, enum antenna_state)); -static void oncore_chan_test P((struct instance *)); -static void oncore_check_almanac P((struct instance *)); -static void oncore_check_antenna P((struct instance *)); -static void oncore_check_leap_sec P((struct instance *)); -static int oncore_checksum_ok P((u_char *, int)); -static void oncore_compute_dH P((struct instance *)); -static void oncore_load_almanac P((struct instance *)); -static void oncore_print_Cb P((struct instance *, u_char *)); -/* static void oncore_print_array P((u_char *, int)); */ -static void oncore_print_posn P((struct instance *)); -static void oncore_sendmsg P((int, u_char *, size_t)); -static void oncore_set_posn P((struct instance *)); -static void oncore_set_traim P((struct instance *)); -static void oncore_shmem_get_3D P((struct instance *)); -static void oncore_ss P((struct instance *)); -static int oncore_wait_almanac P((struct instance *)); - -static void oncore_msg_any P((struct instance *, u_char *, size_t, int)); -static void oncore_msg_Adef P((struct instance *, u_char *, size_t)); -static void oncore_msg_Ag P((struct instance *, u_char *, size_t)); -static void oncore_msg_As P((struct instance *, u_char *, size_t)); -static void oncore_msg_At P((struct instance *, u_char *, size_t)); -static void oncore_msg_Ay P((struct instance *, u_char *, size_t)); -static void oncore_msg_Az P((struct instance *, u_char *, size_t)); -static void oncore_msg_BaEaHa P((struct instance *, u_char *, size_t)); -static void oncore_msg_Bd P((struct instance *, u_char *, size_t)); -static void oncore_msg_Bj P((struct instance *, u_char *, size_t)); -static void oncore_msg_BnEnHn P((struct instance *, u_char *, size_t)); -static void oncore_msg_CaFaIa P((struct instance *, u_char *, size_t)); -static void oncore_msg_Cb P((struct instance *, u_char *, size_t)); -static void oncore_msg_Cf P((struct instance *, u_char *, size_t)); -static void oncore_msg_Cj P((struct instance *, u_char *, size_t)); -static void oncore_msg_Cj_id P((struct instance *, u_char *, size_t)); -static void oncore_msg_Cj_init P((struct instance *, u_char *, size_t)); -static void oncore_msg_Ga P((struct instance *, u_char *, size_t)); -static void oncore_msg_Gb P((struct instance *, u_char *, size_t)); -static void oncore_msg_Gj P((struct instance *, u_char *, size_t)); -static void oncore_msg_Sz P((struct instance *, u_char *, size_t)); +static int oncore_start (int, struct peer *); +static void oncore_poll (int, struct peer *); +static void oncore_shutdown (int, struct peer *); +static void oncore_consume (struct instance *); +static void oncore_read_config (struct instance *); +static void oncore_receive (struct recvbuf *); +static int oncore_ppsapi (struct instance *); +static void oncore_get_timestamp (struct instance *, long, long); +static void oncore_init_shmem (struct instance *); + +static void oncore_antenna_report (struct instance *, enum antenna_state); +static void oncore_chan_test (struct instance *); +static void oncore_check_almanac (struct instance *); +static void oncore_check_antenna (struct instance *); +static void oncore_check_leap_sec (struct instance *); +static int oncore_checksum_ok (u_char *, int); +static void oncore_compute_dH (struct instance *); +static void oncore_load_almanac (struct instance *); +static void oncore_log (struct instance *, int, const char *); +static void oncore_print_Cb (struct instance *, u_char *); +/* static void oncore_print_array (u_char *, int); */ +static void oncore_print_posn (struct instance *); +static void oncore_sendmsg (struct instance *, u_char *, size_t); +static void oncore_set_posn (struct instance *); +static void oncore_set_traim (struct instance *); +static void oncore_shmem_get_3D (struct instance *); +static void oncore_ss (struct instance *); +static int oncore_wait_almanac (struct instance *); + +static void oncore_msg_any (struct instance *, u_char *, size_t, int); +static void oncore_msg_Adef (struct instance *, u_char *, size_t); +static void oncore_msg_Ag (struct instance *, u_char *, size_t); +static void oncore_msg_As (struct instance *, u_char *, size_t); +static void oncore_msg_At (struct instance *, u_char *, size_t); +static void oncore_msg_Ay (struct instance *, u_char *, size_t); +static void oncore_msg_Az (struct instance *, u_char *, size_t); +static void oncore_msg_BaEaHa (struct instance *, u_char *, size_t); +static void oncore_msg_Bd (struct instance *, u_char *, size_t); +static void oncore_msg_Bj (struct instance *, u_char *, size_t); +static void oncore_msg_Bl (struct instance *, u_char *, size_t); +static void oncore_msg_BnEnHn (struct instance *, u_char *, size_t); +static void oncore_msg_CaFaIa (struct instance *, u_char *, size_t); +static void oncore_msg_Cb (struct instance *, u_char *, size_t); +static void oncore_msg_Cf (struct instance *, u_char *, size_t); +static void oncore_msg_Cj (struct instance *, u_char *, size_t); +static void oncore_msg_Cj_id (struct instance *, u_char *, size_t); +static void oncore_msg_Cj_init (struct instance *, u_char *, size_t); +static void oncore_msg_Ga (struct instance *, u_char *, size_t); +static void oncore_msg_Gb (struct instance *, u_char *, size_t); +static void oncore_msg_Gj (struct instance *, u_char *, size_t); +static void oncore_msg_Sz (struct instance *, u_char *, size_t); struct refclock refclock_oncore = { oncore_start, /* start up driver */ @@ -367,7 +428,7 @@ static struct msg_desc { const char flag[3]; const int len; - void (*handler) P((struct instance *, u_char *, size_t)); + void (*handler) (struct instance *, u_char *, size_t); const char *fmt; int shmem; } oncore_messages[] = { @@ -395,6 +456,7 @@ { "Bb", 92, 0, "" }, { "Bd", 23, oncore_msg_Bd, "" }, { "Bj", 8, oncore_msg_Bj, "" }, + { "Bl", 41, oncore_msg_Bl, "" }, { "Ca", 9, oncore_msg_CaFaIa, "" }, { "Cb", 33, oncore_msg_Cb, "" }, { "Cf", 7, oncore_msg_Cf, "" }, @@ -446,6 +508,7 @@ static u_char oncore_cmd_Bd[] = { 'B', 'd', 1 }; /* 6/8/12? Almanac Status Msg. */ static u_char oncore_cmd_Be[] = { 'B', 'e', 1 }; /* 6/8/12 Request Almanac Data */ static u_char oncore_cmd_Bj[] = { 'B', 'j', 0 }; /* 6/8 Leap Second Pending */ +static u_char oncore_cmd_Bl[] = { 'B', 'l', 1 }; /* VP Satellite Broadcast Data Msg */ static u_char oncore_cmd_Bn0[] = { 'B', 'n', 0, 1, 0,10, 2, 0,0,0, 0,0,0,0,0,0,0 }; /* 6 TRAIM setup/status: msg off, traim on */ static u_char oncore_cmd_Bn[] = { 'B', 'n', 1, 1, 0,10, 2, 0,0,0, 0,0,0,0,0,0,0 }; /* 6 TRAIM setup/status: msg on, traim on */ static u_char oncore_cmd_Bnx[] = { 'B', 'n', 0, 0, 0,10, 2, 0,0,0, 0,0,0,0,0,0,0 }; /* 6 TRAIM setup/status: msg off, traim off */ @@ -531,18 +594,14 @@ #define STRING_LEN 32 register struct instance *instance; struct refclockproc *pp; - int fd1, fd2, num; + int fd1, fd2; char device1[STRING_LEN], device2[STRING_LEN], Msg[160]; - const char *cp; struct stat stat1, stat2; /* create instance structure for this unit */ - if (!(instance = (struct instance *) malloc(sizeof *instance))) { - perror("malloc"); - return (0); - } - memset((char *) instance, 0, sizeof *instance); + instance = emalloc(sizeof(*instance)); + memset(instance, 0, sizeof(*instance)); /* initialize miscellaneous variables */ @@ -570,20 +629,17 @@ pp->clockdesc = "Motorola Oncore GPS Receiver"; memcpy((char *)&pp->refid, "GPS\0", (size_t) 4); - cp = "ONCORE DRIVER -- CONFIGURING"; - record_clock_stats(&(instance->peer->srcadr), cp); - + oncore_log(instance, LOG_NOTICE, "ONCORE DRIVER -- CONFIGURING"); instance->o_state = ONCORE_NO_IDEA; - cp = "state = ONCORE_NO_IDEA"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "state = ONCORE_NO_IDEA"); /* Now open files. * This is a bit complicated, a we dont want to open the same file twice * (its a problem on some OS), and device2 may not exist for the new PPS */ - (void)sprintf(device1, DEVICE1, unit); - (void)sprintf(device2, DEVICE2, unit); + (void)snprintf(device1, sizeof(device1), DEVICE1, unit); + (void)snprintf(device2, sizeof(device2), DEVICE2, unit); /* OPEN DEVICES */ /* opening different devices for fd1 and fd2 presents no problems */ @@ -594,42 +650,68 @@ Since things ALWAYS work if we only open the device once, we check to see if the two devices are in fact the same, then proceed to do one open or two. - */ + For use with linuxPPS we assume that the N_TTY file has been opened + and that the line discipline has been changed to N_PPS by another + program (say ppsldisc) so that the two files expected by the oncore + driver can be opened. + + Note that the linuxPPS N_PPS file is just like a N_TTY, so we can do + the stat below without error even though the file has already had its + line discipline changed by another process. + + The Windows port of ntpd arranges to return duplicate handles for + multiple opens of the same serial device, and doesn't have inodes + for serial handles, so we just open both on Windows. + */ +#ifndef SYS_WINNT if (stat(device1, &stat1)) { - sprintf(Msg, "Can't stat fd1 (%s)\n", device1); - record_clock_stats(&(instance->peer->srcadr), Msg); - exit(1); + snprintf(Msg, sizeof(Msg), "Can't stat fd1 (%s)", + device1); + oncore_log(instance, LOG_ERR, Msg); + return(0); /* exit, no file, can't start driver */ } if (stat(device2, &stat2)) { - sprintf(Msg, "Can't stat fd2 (%s)\n", device2); - record_clock_stats(&(instance->peer->srcadr), Msg); - exit(1); + stat2.st_dev = stat2.st_ino = -2; + snprintf(Msg, sizeof(Msg), + "Can't stat fd2 (%s) errno = %d", + device2, errno); + oncore_log(instance, LOG_ERR, Msg); } +#endif /* !SYS_WINNT */ if (!(fd1 = refclock_open(device1, SPEED, LDISC_RAW))) { - sprintf(Msg, "Can't open fd1 (%s)\n", device1); - record_clock_stats(&(instance->peer->srcadr), Msg); - exit(1); + snprintf(Msg, sizeof(Msg), "Can't open fd1 (%s)", + device1); + oncore_log(instance, LOG_ERR, Msg); + return(0); /* exit, can't open file, can't start driver */ } + /* for LINUX the PPS device is the result of a line discipline. + It seems simplest to let an external program create the appropriate + /dev/pps file, and only check (carefully) for its existance here + */ + +#ifndef SYS_WINNT if ((stat1.st_dev == stat2.st_dev) && (stat1.st_ino == stat2.st_ino)) /* same device here */ fd2 = fd1; - else { /* different devices here */ - if ((fd2=open(device2, O_RDWR)) < 0) { - sprintf(Msg, "Can't open fd2 (%s)\n", device2); - record_clock_stats(&(instance->peer->srcadr), Msg); - exit(1); + else +#endif /* !SYS_WINNT */ + { /* different devices here */ + if ((fd2=tty_open(device2, O_RDWR, 0777)) < 0) { + snprintf(Msg, sizeof(Msg), + "Can't open fd2 (%s)", device2); + oncore_log(instance, LOG_ERR, Msg); + return(0); /* exit, can't open PPS file, can't start driver */ } } - num = fd2; - /* open ppsapi soure */ + /* open ppsapi source */ - if (time_pps_create(num, &instance->pps_h) < 0) { - record_clock_stats(&(instance->peer->srcadr), "PPSAPI not found in kernel"); - return(0); + if (time_pps_create(fd2, &instance->pps_h) < 0) { + oncore_log(instance, LOG_ERR, "exit, PPSAPI not found in kernel"); + return(0); /* exit, don't find PPSAPI in kernel */ } /* continue initialization */ @@ -649,7 +731,7 @@ pp->io.datalen = 0; pp->io.fd = fd1; if (!io_addclock(&pp->io)) { - record_clock_stats(&(instance->peer->srcadr), "ONCORE: io_addclock"); + oncore_log(instance, LOG_ERR, "can't do io_addclock"); (void) close(fd1); free(instance); return (0); @@ -671,12 +753,11 @@ */ instance->o_state = ONCORE_CHECK_ID; - cp = "state = ONCORE_CHECK_ID"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "state = ONCORE_CHECK_ID"); instance->timeout = 4; - oncore_sendmsg(instance->ttyfd, oncore_cmd_Cg, sizeof(oncore_cmd_Cg)); /* Set Posn Fix mode (not Idle (VP)) */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Cj, sizeof(oncore_cmd_Cj)); + oncore_sendmsg(instance, oncore_cmd_Cg, sizeof(oncore_cmd_Cg)); /* Set Posn Fix mode (not Idle (VP)) */ + oncore_sendmsg(instance, oncore_cmd_Cj, sizeof(oncore_cmd_Cj)); instance->pollcnt = 2; return (1); @@ -730,17 +811,14 @@ instance = (struct instance *) peer->procptr->unitptr; if (instance->timeout) { - char *cp; - instance->timeout--; if (instance->timeout == 0) { - cp = "Oncore: No response from @@Cj, shutting down driver"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_ERR, + "Oncore: No response from @@Cj, shutting down driver"); oncore_shutdown(unit, peer); } else { - oncore_sendmsg(instance->ttyfd, oncore_cmd_Cj, sizeof(oncore_cmd_Cj)); - cp = "Oncore: Resend @@Cj"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_sendmsg(instance, oncore_cmd_Cj, sizeof(oncore_cmd_Cj)); + oncore_log(instance, LOG_WARNING, "Oncore: Resend @@Cj"); } return; } @@ -768,12 +846,14 @@ char *cp, Msg[160]; if (time_pps_getcap(instance->pps_h, &cap) < 0) { - msyslog(LOG_ERR, "time_pps_getcap failed: %m"); + snprintf(Msg, sizeof(Msg), "time_pps_getcap failed: %m"); + oncore_log(instance, LOG_ERR, Msg); return (0); } if (time_pps_getparams(instance->pps_h, &instance->pps_p) < 0) { - msyslog(LOG_ERR, "time_pps_getparams failed: %m"); + snprintf(Msg, sizeof(Msg), "time_pps_getparams failed: %m"); + oncore_log(instance, LOG_ERR, Msg); return (0); } @@ -782,26 +862,28 @@ */ if (instance->assert) { - cp = "Assert."; + cp = "Assert"; mode = PPS_CAPTUREASSERT; mode1 = PPS_OFFSETASSERT; } else { - cp = "Clear."; + cp = "Clear"; mode = PPS_CAPTURECLEAR; mode1 = PPS_OFFSETCLEAR; } - sprintf(Msg, "Initializing timeing to %s.", cp); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), "Initializing timing to %s.", cp); + oncore_log(instance, LOG_INFO, Msg); if (!(mode & cap)) { - sprintf(Msg, "Can't set timeing to %s, exiting...", cp); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), + "Can't set timing to %s, exiting...", cp); + oncore_log(instance, LOG_ERR, Msg); return(0); } if (!(mode1 & cap)) { - sprintf(Msg, "Can't set PPS_%sCLEAR, this will increase jitter.", cp); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), + "Can't set %s, this will increase jitter.", cp); + oncore_log(instance, LOG_NOTICE, Msg); mode1 = 0; } @@ -810,8 +892,8 @@ instance->pps_p.mode = (mode | mode1 | PPS_TSFMT_TSPEC) & cap; if (time_pps_setparams(instance->pps_h, &instance->pps_p) < 0) { - record_clock_stats(&(instance->peer->srcadr), "ONCORE: time_pps_setparams fails"); - exit(1); + oncore_log(instance, LOG_ERR, "ONCORE: time_pps_setparams fails"); + return(0); /* exit, can't do time_pps_setparans on PPS file */ } /* If HARDPPS is on, we tell kernel */ @@ -819,7 +901,7 @@ if (instance->hardpps) { int i; - record_clock_stats(&(instance->peer->srcadr), "HARDPPS Set."); + oncore_log(instance, LOG_INFO, "HARDPPS Set."); if (instance->assert) i = PPS_CAPTUREASSERT; @@ -830,10 +912,12 @@ if (time_pps_kcbind(instance->pps_h, PPS_KC_HARDPPS, i, PPS_TSFMT_TSPEC) < 0) { - msyslog(LOG_ERR, "time_pps_kcbind failed: %m"); - record_clock_stats(&(instance->peer->srcadr), "HARDPPS failed, abort..."); + snprintf(Msg, sizeof(Msg), "time_pps_kcbind failed: %m"); + oncore_log(instance, LOG_ERR, Msg); + oncore_log(instance, LOG_ERR, "HARDPPS failed, abort..."); return (0); } + pps_enable = 1; } return(1); @@ -854,7 +938,7 @@ struct stat sbuf; size_t shmem_length; - /* + /* * The first thing we do is see if there is an instance->shmem_fname file (still) * out there from a previous run. If so, we copy it in and use it to initialize * shmem (so we won't lose our almanac if we need it). @@ -863,16 +947,13 @@ shmem_old = 0; shmem_old_size = 0; if ((fd = open(instance->shmem_fname, O_RDONLY)) < 0) - record_clock_stats(&(instance->peer->srcadr), "ONCORE: Can't open SHMEM file"); + oncore_log(instance, LOG_WARNING, "ONCORE: Can't open SHMEM file"); else { fstat(fd, &sbuf); shmem_old_size = sbuf.st_size; if (shmem_old_size != 0) { - shmem_old = (u_char *) malloc((unsigned) sbuf.st_size); - if (shmem_old == NULL) - record_clock_stats(&(instance->peer->srcadr), "ONCORE: Can't malloc buffer for shmem_old"); - else - read(fd, shmem_old, shmem_old_size); + shmem_old = emalloc((unsigned) sbuf.st_size); + read(fd, shmem_old, shmem_old_size); } close(fd); } @@ -880,7 +961,7 @@ /* OK, we now create the NEW SHMEM. */ if ((instance->shmemfd = open(instance->shmem_fname, O_RDWR|O_CREAT|O_TRUNC, 0644)) < 0) { - record_clock_stats(&(instance->peer->srcadr), "ONCORE: Can't open shmem"); + oncore_log(instance, LOG_WARNING, "ONCORE: Can't open shmem"); if (shmem_old) free(shmem_old); @@ -913,16 +994,7 @@ } shmem_length = n + 2; - buf = malloc(shmem_length); - if (buf == NULL) { - record_clock_stats(&(instance->peer->srcadr), "ONCORE: Can't malloc buffer for shmem"); - close(instance->shmemfd); - if (shmem_old) - free(shmem_old); - - return; - } - + buf = emalloc(shmem_length); memset(buf, 0, shmem_length); /* next build the new SHMEM buffer in memory */ @@ -977,7 +1049,7 @@ free(buf); if (i != shmem_length) { - record_clock_stats(&(instance->peer->srcadr), "ONCORE: error writing shmem"); + oncore_log(instance, LOG_ERR, "ONCORE: error writing shmem"); close(instance->shmemfd); return; } @@ -995,9 +1067,10 @@ return; } - sprintf(Msg, "SHMEM (size = %ld) is CONFIGURED and available as %s", - (u_long) shmem_length, instance->shmem_fname); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), + "SHMEM (size = %ld) is CONFIGURED and available as %s", + (u_long) shmem_length, instance->shmem_fname); + oncore_log(instance, LOG_NOTICE, Msg); } #endif /* ONCORE_SHMEM_STATUS */ @@ -1014,10 +1087,10 @@ { /* * First we try to open the configuration file - * /etc/oncoreN + * /etc/ntp.oncore.N * where N is the unit number viz 127.127.30.N. * If we don't find it we try - * /etc/ntp.oncore.N + * /etc/ntp.oncoreN * and then * /etc/ntp.oncore * @@ -1127,7 +1200,7 @@ */ FILE *fd; - char *cp, *cc, *ca, line[100], units[2], device[20], Msg[160], **cpp; + char *cp, *cc, *ca, line[100], units[2], device[64], Msg[160], **cpp; char *dirs[] = { "/etc/ntp", "/etc", 0 }; int i, sign, lat_flg, long_flg, ht_flg, mode, mask; double f1, f2, f3; @@ -1135,14 +1208,16 @@ fd = NULL; /* just to shutup gcc complaint */ for (cpp=dirs; *cpp; cpp++) { cp = *cpp; - sprintf(device, "%s/ntp.oncore.%d", cp, instance->unit); /* try "ntp.oncore.0 */ + snprintf(device, sizeof(device), "%s/ntp.oncore.%d", + cp, instance->unit); /* try "ntp.oncore.0 */ if ((fd=fopen(device, "r"))) break; - sprintf(device, "%s/ntp.oncore%d", cp, instance->unit); /* try "ntp.oncore0" */ + snprintf(device, sizeof(device), "%s/ntp.oncore%d", + cp, instance->unit); /* try "ntp.oncore0" */ if ((fd=fopen(device, "r"))) break; - sprintf(device, "%s/ntp.oncore", cp); /* and finally "ntp.oncore" */ - if ((fd=fopen(device, "r"))) + snprintf(device, sizeof(device), "%s/ntp.oncore", cp); + if ((fd=fopen(device, "r"))) /* last try "ntp.oncore" */ break; } @@ -1188,9 +1263,7 @@ continue; if (!strncmp(cc, "STATUS", (size_t) 6) || !strncmp(cc, "SHMEM", (size_t) 5)) { - i = strlen(ca); - instance->shmem_fname = (char *) malloc((unsigned) (i+1)); - strcpy(instance->shmem_fname, ca); + instance->shmem_fname = estrdup(ca); continue; } @@ -1242,8 +1315,10 @@ if (f1 < 0 || f1 > 1.e9) f1 = 0; if (f1 < 0 || f1 > 999999) { - sprintf(Msg, "PPS Cable delay of %fns out of Range, ignored", f1); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), + "PPS Cable delay of %fns out of Range, ignored", + f1); + oncore_log(instance, LOG_WARNING, Msg); } else instance->delay = f1; /* delay in ns */ } else if (!strncmp(cc, "OFFSET", (size_t) 6)) { @@ -1261,8 +1336,10 @@ if (f1 < 0 || f1 > 1.e9) f1 = 0; if (f1 < 0 || f1 > 999999999.) { - sprintf(Msg, "PPS Offset of %fns out of Range, ignored", f1); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), + "PPS Offset of %fns out of Range, ignored", + f1); + oncore_log(instance, LOG_WARNING, Msg); } else instance->offset = f1; /* offset in ns */ } else if (!strncmp(cc, "MODE", (size_t) 4)) { @@ -1302,18 +1379,22 @@ instance->posn_set = 1; if (!( lat_flg && long_flg && ht_flg )) { - printf("ONCORE: incomplete data on %s\n", device); + snprintf(Msg, sizeof(Msg), + "ONCORE: incomplete data on %s", device); + oncore_log (instance, LOG_WARNING, Msg); instance->posn_set = 0; if (mode == 1 || mode == 3) { - sprintf(Msg, "Input Mode = %d, but no/incomplete position, mode set to %d", mode, mode+1); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), + "Input Mode = %d, but no/incomplete position, mode set to %d", + mode, mode+1); + oncore_log(instance, LOG_WARNING, Msg); mode++; } } instance->init_type = mode; - sprintf(Msg, "Input mode = %d", mode); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), "Input mode = %d", mode); + oncore_log(instance, LOG_INFO, Msg); } @@ -1336,17 +1417,27 @@ instance = (struct instance *) peer->procptr->unitptr; p = (u_char *) &rbufp->recv_space; -#if 0 +#ifdef ONCORE_VERBOSE_RECEIVE if (debug > 4) { int i; - printf("ONCORE: >>>"); - for(i=0; irecv_length; i++) - printf("%02x ", p[i]); - printf("\n"); - printf("ONCORE: >>>"); - for(i=0; irecv_length; i++) - printf("%03o ", p[i]); - printf("\n"); + char Msg[120], Msg2[10]; + + snprintf(Msg, sizeof(Msg), ">>> %d bytes available", + rbufp->recv_length); + oncore_log(instance, LOG_DEBUG, Msg); + strncpy(Msg, ">>>", sizeof(Msg)); + for (i = 0; i < rbufp->recv_length; i++) { + snprintf(Msg2, sizeof(Msg2), "%02x ", p[i]); + strncat(Msg, Msg2, sizeof(Msg)); + } + oncore_log(instance, LOG_DEBUG, Msg); + + strncpy(Msg, ">>>", sizeof(Msg)); + for (i = 0; i < rbufp->recv_length; i++) { + snprintf(Msg2, sizeof(Msg2), "%03o ", p[i]); + strncat(Msg, Msg2, sizeof(Msg)); + } + oncore_log(instance, LOG_DEBUG, Msg); } #endif @@ -1378,9 +1469,14 @@ for (i=1; i < rcvptr-1; i++) if (rcvbuf[i] == '@' && rcvbuf[i+1] == '@') break; -#ifdef DEBUG - if (debug > 4) - printf("ONCORE[%d]: >>> skipping %d chars\n", instance->unit, i); +#ifdef ONCORE_VERBOSE_CONSUME + if (debug > 4) { + char Msg[120]; + + snprintf(Msg, sizeof(Msg), + ">>> skipping %d chars", i); + oncore_log(instance, LOG_DEBUG, Msg); + } #endif if (i != rcvptr) memcpy(rcvbuf, rcvbuf+i, (size_t)(rcvptr-i)); @@ -1394,9 +1490,15 @@ if (!strncmp(oncore_messages[m].flag, (char *)(rcvbuf+2), (size_t) 2)) break; if (m == l) { -#ifdef DEBUG - if (debug > 4) - printf("ONCORE[%d]: >>> Unknown MSG, skipping 4 (%c%c)\n", instance->unit, rcvbuf[2], rcvbuf[3]); +#ifdef ONCORE_VERBOSE_CONSUME + if (debug > 4) { + char Msg[120]; + + snprintf(Msg, sizeof(Msg), + ">>> Unknown MSG, skipping 4 (%c%c)", + rcvbuf[2], rcvbuf[3]); + oncore_log(instance, LOG_DEBUG, Msg); + } #endif memcpy(rcvbuf, rcvbuf+4, (size_t) 4); rcvptr -= 4; @@ -1404,9 +1506,16 @@ } l = oncore_messages[m].len; -#if 0 - if (debug > 3) - printf("ONCORE[%d]: GOT: %c%c %d of %d entry %d\n", instance->unit, rcvbuf[2], rcvbuf[3], rcvptr, l, m); +#ifdef ONCORE_VERBOSE_CONSUME + if (debug > 3) { + char Msg[120]; + + snprintf(Msg, sizeof(Msg), + "GOT: %c%c %d of %d entry %d", + instance->unit, rcvbuf[2], rcvbuf[3], + rcvptr, l, m); + oncore_log(instance, LOG_DEBUG, Msg); + } #endif /* Got the entire message ? */ @@ -1416,9 +1525,9 @@ /* are we at the end of message? should be */ if (rcvbuf[l-2] != '\r' || rcvbuf[l-1] != '\n') { -#ifdef DEBUG +#ifdef ONCORE_VERBOSE_CONSUME if (debug) - printf("ONCORE[%d]: NO at end of message\n", instance->unit); + oncore_log(instance, LOG_DEBUG, "NO at end of message"); #endif } else { /* check the CheckSum */ if (oncore_checksum_ok(rcvbuf, l)) { @@ -1431,13 +1540,18 @@ if (oncore_messages[m].handler) oncore_messages[m].handler(instance, rcvbuf, (size_t) (l-3)); } -#ifdef DEBUG +#ifdef ONCORE_VERBOSE_CONSUME else if (debug) { - printf("ONCORE[%d]: Checksum mismatch!\n", instance->unit); - printf("ONCORE[%d]: @@%c%c ", instance->unit, rcvbuf[2], rcvbuf[3]); - for (i=4; ipeer; #if 1 /* If we are in SiteSurvey mode, then we are in 3D mode, and we fall thru. @@ -1479,18 +1596,22 @@ * This gives good time, which gets better when the SS is done. */ - if ((instance->site_survey == ONCORE_SS_DONE) && (instance->mode != MODE_0D)) + if ((instance->site_survey == ONCORE_SS_DONE) && (instance->mode != MODE_0D)) { #else /* old check, only fall thru for SS_DONE and 0D mode, 2h45m wait for ticks */ - if ((instance->site_survey != ONCORE_SS_DONE) || (instance->mode != MODE_0D)) + if ((instance->site_survey != ONCORE_SS_DONE) || (instance->mode != MODE_0D)) { #endif + peer->flags &= ~FLAG_PPS; return; + } /* Don't do anything without an almanac to define the GPS->UTC delta */ - if (instance->rsm.bad_almanac) + if (instance->rsm.bad_almanac) { + peer->flags &= ~FLAG_PPS; return; + } /* Once the Almanac is valid, the M12+T does not produce valid UTC * immediately. @@ -1500,6 +1621,7 @@ if (instance->count5) { instance->count5--; + peer->flags &= ~FLAG_PPS; return; } @@ -1508,51 +1630,63 @@ timeout.tv_nsec = 0; if (time_pps_fetch(instance->pps_h, PPS_TSFMT_TSPEC, &pps_i, &timeout) < 0) { - printf("ONCORE: time_pps_fetch failed\n"); + oncore_log(instance, LOG_ERR, "time_pps_fetch failed"); + peer->flags &= ~FLAG_PPS; return; } if (instance->assert) { tsp = &pps_i.assert_timestamp; -#ifdef DEBUG +#ifdef ONCORE_VERBOSE_GET_TIMESTAMP if (debug > 2) { + u_long i; + i = (u_long) pps_i.assert_sequence; # ifdef HAVE_STRUCT_TIMESPEC - printf("ONCORE[%d]: serial/j (%lu, %lu) %ld.%09ld\n", - instance->unit, i, j, - (long)tsp->tv_sec, (long)tsp->tv_nsec); + snprintf(Msg, sizeof(Msg), + "serial/j (%lu, %lu) %ld.%09ld", i, j, + (long)tsp->tv_sec, (long)tsp->tv_nsec); # else - printf("ONCORE[%d]: serial/j (%lu, %lu) %ld.%06ld\n", - instance->unit, i, j, - (long)tsp->tv_sec, (long)tsp->tv_usec); + snprintf(Msg, sizeof(Msg), + "serial/j (%lu, %lu) %ld.%06ld", i, j, + (long)tsp->tv_sec, (long)tsp->tv_usec); # endif + oncore_log(instance, LOG_DEBUG, Msg); } #endif if (pps_i.assert_sequence == j) { - printf("ONCORE: oncore_get_timestamp, error serial pps\n"); + oncore_log(instance, LOG_NOTICE, "ONCORE: oncore_get_timestamp, error serial pps"); + peer->flags &= ~FLAG_PPS; return; } + instance->ev_serial = pps_i.assert_sequence; } else { tsp = &pps_i.clear_timestamp; -#ifdef DEBUG +#if 0 if (debug > 2) { + u_long i; + i = (u_long) pps_i.clear_sequence; # ifdef HAVE_STRUCT_TIMESPEC - printf("ONCORE[%d]: serial/j (%lu, %lu) %ld.%09ld\n", - instance->unit, i, j, (long)tsp->tv_sec, (long)tsp->tv_nsec); + snprintf(Msg, sizeof(Msg), + "serial/j (%lu, %lu) %ld.%09ld", i, j, + (long)tsp->tv_sec, (long)tsp->tv_nsec); # else - printf("ONCORE[%d]: serial/j (%lu, %lu) %ld.%06ld\n", - instance->unit, i, j, (long)tsp->tv_sec, (long)tsp->tv_usec); + snprintf(Msg. sizeof(Msg), + "serial/j (%lu, %lu) %ld.%06ld", i, j, + (long)tsp->tv_sec, (long)tsp->tv_usec); # endif + oncore_log(instance, LOG_DEBUG, Msg); } #endif if (pps_i.clear_sequence == j) { - printf("ONCORE: oncore_get_timestamp, error serial pps\n"); + oncore_log(instance, LOG_ERR, "oncore_get_timestamp, error serial pps"); + peer->flags &= ~FLAG_PPS; return; } instance->ev_serial = pps_i.clear_sequence; @@ -1611,12 +1745,16 @@ */ if (time_pps_getcap(instance->pps_h, ¤t_mode) < 0) { - msyslog(LOG_ERR, "time_pps_getcap failed: %m"); + snprintf(Msg, sizeof(Msg), "time_pps_getcap failed: %m"); + oncore_log(instance, LOG_ERR, Msg); + peer->flags &= ~FLAG_PPS; return; } if (time_pps_getparams(instance->pps_h, ¤t_params) < 0) { - msyslog(LOG_ERR, "time_pps_getparams failed: %m"); + snprintf(Msg, sizeof(Msg), "time_pps_getparams failed: %m"); + oncore_log(instance, LOG_ERR, Msg); + peer->flags &= ~FLAG_PPS; return; } @@ -1631,7 +1769,7 @@ current_params.clear_offset.tv_nsec = -dt2; if (time_pps_setparams(instance->pps_h, ¤t_params)) - record_clock_stats(&(instance->peer->srcadr), "ONCORE: Error doing time_pps_setparams"); + oncore_log(instance, LOG_ERR, "ONCORE: Error doing time_pps_setparams"); /* have time from UNIX origin, convert to NTP origin. */ @@ -1656,17 +1794,22 @@ if (instance->chan == 6 || instance->chan == 8) { char f1[5], f2[5], f3[5], f4[5]; if (instance->traim) { - sprintf(f1, "%d", instance->BEHn[21]); - sprintf(f2, "%d", instance->BEHn[22]); - sprintf(f3, "%2d", instance->BEHn[23]*256+instance->BEHn[24]); - sprintf(f4, "%3d", (s_char) instance->BEHn[25]); + snprintf(f1, sizeof(f1), "%d", + instance->BEHn[21]); + snprintf(f2, sizeof(f2), "%d", + instance->BEHn[22]); + snprintf(f3, sizeof(f3), "%2d", + instance->BEHn[23] * 256 + + instance->BEHn[24]); + snprintf(f4, sizeof(f4), "%3d", + (s_char)instance->BEHn[25]); } else { - strcpy(f1, "x"); - strcpy(f2, "x"); - strcpy(f3, "xx"); - strcpy(f4, "xxx"); + strncpy(f1, "x", sizeof(f1)); + strncpy(f2, "x", sizeof(f2)); + strncpy(f3, "xx", sizeof(f3)); + strncpy(f4, "xxx", sizeof(f4)); } - sprintf(instance->pp->a_lastcode, /* MAX length 128, currently at 121 */ + snprintf(Msg, sizeof(Msg), /* MAX length 128, currently at 127 */ "%u.%09lu %d %d %2d %2d %2d %2ld rstat %02x dop %4.1f nsat %2d,%d traim %d,%s,%s sigma %s neg-sawtooth %s sat %d%d%d%d%d%d%d%d", ts.l_ui, j, instance->pp->year, instance->pp->day, @@ -1684,17 +1827,22 @@ } else if (instance->chan == 12) { char f1[5], f2[5], f3[5], f4[5]; if (instance->traim) { - sprintf(f1, "%d", instance->BEHn[6]); - sprintf(f2, "%d", instance->BEHn[7]); - sprintf(f3, "%d", instance->BEHn[12]*256+instance->BEHn[13]); - sprintf(f4, "%3d", (s_char) instance->BEHn[14]); + snprintf(f1, sizeof(f1), "%d", + instance->BEHn[6]); + snprintf(f2, sizeof(f2), "%d", + instance->BEHn[7]); + snprintf(f3, sizeof(f3), "%d", + instance->BEHn[12] * 256 + + instance->BEHn[13]); + snprintf(f4, sizeof(f4), "%3d", + (s_char)instance->BEHn[14]); } else { - strcpy(f1, "x"); - strcpy(f2, "x"); - strcpy(f3, "x"); - strcpy(f4, "xxx"); + strncpy(f1, "x", sizeof(f1)); + strncpy(f2, "x", sizeof(f2)); + strncpy(f3, "xx", sizeof(f3)); + strncpy(f4, "xxx", sizeof(f4)); } - sprintf(instance->pp->a_lastcode, + snprintf(Msg, sizeof(Msg), "%u.%09lu %d %d %2d %2d %2d %2ld rstat %02x dop %4.1f nsat %2d,%d traim %d,%s,%s sigma %s neg-sawtooth %s sat %d%d%d%d%d%d%d%d%d%d%d%d", ts.l_ui, j, instance->pp->year, instance->pp->day, @@ -1712,23 +1860,15 @@ ); } -#ifdef DEBUG - if (debug > 2) { - int n; - - n = strlen(instance->pp->a_lastcode); - printf("ONCORE[%d]: len = %d %s\n", instance->unit, n, instance->pp->a_lastcode); - } -#endif - /* and some things I dont understand (magic ntp things) */ if (!refclock_process(instance->pp)) { refclock_report(instance->peer, CEVNT_BADTIME); + peer->flags &= ~FLAG_PPS; return; } - record_clock_stats(&(instance->peer->srcadr), instance->pp->a_lastcode); + oncore_log(instance, LOG_INFO, Msg); /* this is long message above */ instance->pollcnt = 2; if (instance->polled) { @@ -1737,6 +1877,7 @@ instance->pp->lastref = instance->pp->lastrec; refclock_receive(instance->peer); } + peer->flags |= FLAG_PPS; } @@ -1755,15 +1896,18 @@ int idx ) { +#ifdef ONCORE_VERBOSE_MSG_ANY int i; const char *fmt = oncore_messages[idx].fmt; const char *p; + char *q; + char *qlim; #ifdef HAVE_GETCLOCK struct timespec ts; #endif struct timeval tv; + char Msg[120], Msg2[10]; -#ifdef DEBUG if (debug > 3) { # ifdef HAVE_GETCLOCK (void) getclock(TIMEOFDAY, &ts); @@ -1772,26 +1916,38 @@ # else GETTIMEOFDAY(&tv, 0); # endif - printf("ONCORE[%d]: %ld.%06ld\n", instance->unit, (long) tv.tv_sec, (long) tv.tv_usec); + snprintf(Msg, sizeof(Msg), "%ld.%06ld", + (long)tv.tv_sec, (long)tv.tv_usec); + oncore_log(instance, LOG_DEBUG, Msg); if (!*fmt) { - printf(">>@@%c%c ", buf[2], buf[3]); - for(i=2; i < len && i < 2400 ; i++) - printf("%02x", buf[i]); - printf("\n"); + snprintf(Msg, sizeof(Msg), ">>@@%c%c ", buf[2], + buf[3]); + for(i = 2; i < len && i < 2400 ; i++) { + snprintf(Msg2, sizeof(Msg2), "%02x", + buf[i]); + strncpy(Msg, Msg2, sizeof(Msg)); + + } + oncore_log(instance, LOG_DEBUG, Msg); return; } else { - printf("##"); - for (p = fmt; *p; p++) { - putchar(*p); - putchar('_'); + strncat(Msg, "##", sizeof(Msg)); + qlim = Msg + sizeof(Msg) - 3; + for (p = fmt, q = Msg + 2; q < qlim && *p; ) { + *q++ = *p++; + *q++ = '_'; } - printf("\n%c%c", buf[2], buf[3]); + *q = '\0'; + oncore_log(instance, LOG_DEBUG, Msg); + snprintf(Msg, sizeof(Msg), "%c%c", buf[2], + buf[3]); i = 4; for (p = fmt; *p; p++) { - printf("%02x", buf[i++]); + snprintf(Msg2, "%02x", buf[i++]); + strncat(Msg, Msg2, sizeof(Msg)); } - printf("\n"); + oncore_log(instance, LOG_DEBUG, Msg); } } #endif @@ -1827,8 +1983,10 @@ cp = "is"; instance->Ag = buf[4]; - sprintf(Msg, "Satellite mask angle %s %d degrees", cp, (int) instance->Ag); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), + "Satellite mask angle %s %d degrees", cp, + (int)instance->Ag); + oncore_log(instance, LOG_INFO, Msg); } @@ -1866,16 +2024,13 @@ size_t len ) { - char *cp; - instance->saw_At = 1; if (instance->site_survey == ONCORE_SS_TESTING) { if (buf[4] == 2) { - record_clock_stats(&(instance->peer->srcadr), + oncore_log(instance, LOG_NOTICE, "Initiating hardware 3D site survey"); - cp = "SSstate = ONCORE_SS_HW"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "SSstate = ONCORE_SS_HW"); instance->site_survey = ONCORE_SS_HW; } } @@ -1904,8 +2059,9 @@ instance->offset = buf_w32(&buf[4]); - sprintf(Msg, "PPS Offset is set to %ld ns", instance->offset); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), "PPS Offset is set to %ld ns", + instance->offset); + oncore_log(instance, LOG_INFO, Msg); } @@ -1930,8 +2086,9 @@ instance->delay = buf_w32(&buf[4]); - sprintf(Msg, "Cable delay is set to %ld ns", instance->delay); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), "Cable delay is set to %ld ns", + instance->delay); + oncore_log(instance, LOG_INFO, Msg); } @@ -1977,21 +2134,24 @@ else /* set from test */ instance->chan = instance->chan_ck; - sprintf(Msg, "Input says chan = %d", instance->chan_in); - record_clock_stats(&(instance->peer->srcadr), Msg); - sprintf(Msg, "Model # says chan = %d", instance->chan_id); - record_clock_stats(&(instance->peer->srcadr), Msg); - sprintf(Msg, "Testing says chan = %d", instance->chan_ck); - record_clock_stats(&(instance->peer->srcadr), Msg); - sprintf(Msg, "Using chan = %d", instance->chan); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), "Input says chan = %d", + instance->chan_in); + oncore_log(instance, LOG_INFO, Msg); + snprintf(Msg, sizeof(Msg), "Model # says chan = %d", + instance->chan_id); + oncore_log(instance, LOG_INFO, Msg); + snprintf(Msg, sizeof(Msg), "Testing says chan = %d", + instance->chan_ck); + oncore_log(instance, LOG_INFO, Msg); + snprintf(Msg, sizeof(Msg), "Using chan = %d", + instance->chan); + oncore_log(instance, LOG_INFO, Msg); instance->o_state = ONCORE_HAVE_CHAN; - cp = "state = ONCORE_HAVE_CHAN"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "state = ONCORE_HAVE_CHAN"); instance->timeout = 4; - oncore_sendmsg(instance->ttyfd, oncore_cmd_Cj, sizeof(oncore_cmd_Cj)); + oncore_sendmsg(instance, oncore_cmd_Cj, sizeof(oncore_cmd_Cj)); return; } @@ -2030,9 +2190,9 @@ /* if not, message out */ if (instance->chan != 12 && !instance->saw_At) { - cp = "Not Good, no @@At command (no Position Hold), must be a GT/GT+"; - record_clock_stats(&(instance->peer->srcadr), cp); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Av1, sizeof(oncore_cmd_Av1)); + oncore_log(instance, LOG_NOTICE, + "Not Good, no @@At command (no Position Hold), must be a GT/GT+"); + oncore_sendmsg(instance, oncore_cmd_Av1, sizeof(oncore_cmd_Av1)); } /* have an Almanac, can start the SiteSurvey @@ -2046,35 +2206,33 @@ case 1: /* Use given Position */ case 3: instance->site_survey = ONCORE_SS_DONE; - cp = "SSstate = ONCORE_SS_DONE"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "SSstate = ONCORE_SS_DONE"); break; case 2: case 4: /* Site Survey */ - cp = "SSstate = ONCORE_SS_TESTING"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "SSstate = ONCORE_SS_TESTING"); instance->site_survey = ONCORE_SS_TESTING; instance->count1 = 1; if (instance->chan == 12) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Gd3, sizeof(oncore_cmd_Gd3)); /* M12+T */ + oncore_sendmsg(instance, oncore_cmd_Gd3, sizeof(oncore_cmd_Gd3)); /* M12+T */ else - oncore_sendmsg(instance->ttyfd, oncore_cmd_At2, sizeof(oncore_cmd_At2)); /* not GT, arg not VP */ + oncore_sendmsg(instance, oncore_cmd_At2, sizeof(oncore_cmd_At2)); /* not GT, arg not VP */ break; } /* Read back PPS Offset for Output */ /* Nb. This will fail silently for early UT (no plus) and M12 models */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ayx, sizeof(oncore_cmd_Ayx)); + oncore_sendmsg(instance, oncore_cmd_Ayx, sizeof(oncore_cmd_Ayx)); /* Read back Cable Delay for Output */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Azx, sizeof(oncore_cmd_Azx)); + oncore_sendmsg(instance, oncore_cmd_Azx, sizeof(oncore_cmd_Azx)); /* Read back Satellite Mask Angle for Output */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Agx, sizeof(oncore_cmd_Agx)); + oncore_sendmsg(instance, oncore_cmd_Agx, sizeof(oncore_cmd_Agx)); } @@ -2091,13 +2249,13 @@ if (instance->count1++ > 5 || instance->BEHa[130]&0x10) { instance->count1 = 0; if (instance->BEHa[130]&0x10) { - record_clock_stats(&(instance->peer->srcadr), + oncore_log(instance, LOG_NOTICE, "Initiating hardware 3D site survey"); - record_clock_stats(&(instance->peer->srcadr), "SSstate = ONCORE_SS_HW"); + oncore_log(instance, LOG_NOTICE, "SSstate = ONCORE_SS_HW"); instance->site_survey = ONCORE_SS_HW; } else { - record_clock_stats(&(instance->peer->srcadr), "SSstate = ONCORE_SS_SW"); + oncore_log(instance, LOG_NOTICE, "SSstate = ONCORE_SS_SW"); instance->site_survey = ONCORE_SS_SW; } } @@ -2124,19 +2282,20 @@ * We will have to do it ourselves (done above) */ - sprintf(Msg, "Initiating software 3D site survey (%d samples)", - POS_HOLD_AVERAGE); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), + "Initiating software 3D site survey (%d samples)", + POS_HOLD_AVERAGE); + oncore_log(instance, LOG_INFO, Msg); - record_clock_stats(&(instance->peer->srcadr), "SSstate = ONCORE_SS_SW"); + oncore_log(instance, LOG_NOTICE, "SSstate = ONCORE_SS_SW"); instance->site_survey = ONCORE_SS_SW; instance->ss_lat = instance->ss_long = instance->ss_ht = 0; if (instance->chan == 12) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Gd0, sizeof(oncore_cmd_Gd0)); /* disable */ + oncore_sendmsg(instance, oncore_cmd_Gd0, sizeof(oncore_cmd_Gd0)); /* disable */ else { - oncore_sendmsg(instance->ttyfd, oncore_cmd_At0, sizeof(oncore_cmd_At0)); /* disable */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Av0, sizeof(oncore_cmd_Av0)); /* disable */ + oncore_sendmsg(instance, oncore_cmd_At0, sizeof(oncore_cmd_At0)); /* disable */ + oncore_sendmsg(instance, oncore_cmd_Av0, sizeof(oncore_cmd_Av0)); /* disable */ } } } @@ -2208,7 +2367,7 @@ instance->traim = 0; instance->traim_delay = 0; cp = "ONCORE: Did not detect TRAIM response, TRAIM = OFF"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_INFO, cp); oncore_set_traim(instance); } else @@ -2249,8 +2408,7 @@ /* if not, and non-zero offset, zero the offset, and send message */ if (!instance->saw_Ay && instance->offset) { - cp = "No @@Ay command, PPS OFFSET ignored"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_INFO, "No @@Ay command, PPS OFFSET ignored"); instance->offset = 0; } } @@ -2286,9 +2444,11 @@ { char Msg[160]; - sprintf(Msg, "Bd: Almanac %s, week = %d, t = %d, %d SVs: %x", - ((buf[4]) ? "LOADED" : "(NONE)"), buf[5], buf[6], buf[7], w32(&buf[8]) ); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), + "Bd: Almanac %s, week = %d, t = %d, %d SVs: %x", + ((buf[4]) ? "LOADED" : "(NONE)"), buf[5], buf[6], + buf[7], w32(&buf[8])); + oncore_log(instance, LOG_NOTICE, Msg); } @@ -2313,6 +2473,8 @@ { const char *cp; + instance->saw_Bj = 1; + switch(buf[4]) { case 1: instance->pp->leap = LEAP_ADDSECOND; @@ -2328,12 +2490,131 @@ cp = "Set pp.leap to LEAP_NOWARNING"; break; } - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, cp); } static void +oncore_msg_Bl( + struct instance *instance, + u_char *buf, + size_t len + ) +{ + int chan, id, subframe, valid, page, i, j, tow; + int day_now, day_lsf; + char *cp, Msg[120]; + enum { + WARN_NOT_YET, + WARN_0, + WARN_PLUS, + WARN_MINUS + } warn; + + day_now = day_lsf = 0; + cp = NULL; /* keep gcc happy */ + + chan = buf[4] & 0377; + id = buf[5] & 0377; + subframe = buf[6] & 017; + valid = (buf[6] >> 4) & 017; + page = buf[7]; + + if ((!instance->Bl.lsf_flg && !instance->Bl.wn_flg) && (subframe == 4 && page == 18 && valid == 10)) { + instance->Bl.dt_ls = buf[32]; + instance->Bl.WN_lsf = buf[33]; + instance->Bl.DN_lsf = buf[34]; + instance->Bl.dt_lsf = buf[35]; + instance->Bl.lsf_flg++; + } + if ((instance->Bl.lsf_flg && !instance->Bl.wn_flg) && (subframe == 1 && valid == 10)) { + i = (buf[7+7]<<8) + buf[7+8]; + instance->Bl.WN = i >> 6; + tow = (buf[7+4]<<16) + (buf[7+5]<<8) + buf[7+6]; + tow >>= 7; + tow = tow & 0377777; + tow <<= 2; + instance->Bl.DN = tow/57600L + 1; + instance->Bl.wn_flg++; + } + if (instance->Bl.wn_flg && instance->Bl.lsf_flg) { + instance->Bl.wn_flg = instance->Bl.lsf_flg = 0; + oncore_cmd_Bl[2] = 0; + oncore_sendmsg(instance, oncore_cmd_Bl, sizeof oncore_cmd_Bl); + oncore_cmd_Bl[2] = 1; + + i = instance->Bl.WN&01400; + instance->Bl.WN_lsf |= i; + + /* have everything I need, doit */ + + i = (instance->Bl.WN_lsf - instance->Bl.WN); + if (i < 0) + i += 1024; + day_now = instance->Bl.DN; + day_lsf = 7*i + instance->Bl.DN_lsf; + + /* ignore if in past or more than a month in future */ + + warn = WARN_NOT_YET; + if (day_lsf >= day_now && day_lsf - day_now < 32) { + /* if < 28d, doit, if 28-31, ck day-of-month < 20 (not at end of prev month) */ + if (day_lsf - day_now < 28 || instance->BEHa[5] < 20) { + i = instance->Bl.dt_lsf - instance->Bl.dt_ls; + switch (i) { + case -1: + warn = WARN_MINUS; + break; + case 0: + warn = WARN_0; + break; + case 1: + warn = WARN_PLUS; + break; + } + } + } + + switch (warn) { + case WARN_0: + case WARN_NOT_YET: + instance->peer->leap = LEAP_NOWARNING; + cp = "Set peer.leap to LEAP_NOWARNING"; + break; + case WARN_MINUS: + instance->peer->leap = LEAP_DELSECOND; + cp = "Set peer.leap to LEAP_DELSECOND"; + break; + case WARN_PLUS: + instance->peer->leap = LEAP_ADDSECOND; + cp = "Set peer.leap to LEAP_ADDSECOND"; + break; + } + oncore_log(instance, LOG_NOTICE, cp); + + i = instance->Bl.dt_lsf-instance->Bl.dt_ls; + if (i) { + j = (i >= 0) ? i : -i; /* abs(i) */ + snprintf(Msg, sizeof(Msg), + "see Leap_Second (%c%d) in %d days", + ((i >= 0) ? '+' : '-'), j, + day_lsf-day_now); + oncore_log(instance, LOG_NOTICE, Msg); + } + } + snprintf(Msg, sizeof(Msg), + "dt_ls = %d dt_lsf = %d WN = %d DN = %d WN_lsf = %d DNlsf = %d wn_flg = %d lsf_flg = %d Bl_day = %d", + instance->Bl.dt_ls, instance->Bl.dt_lsf, + instance->Bl.WN, instance->Bl.DN, + instance->Bl.WN_lsf, instance->Bl.DN_lsf, + instance->Bl.wn_flg, instance->Bl.lsf_flg, + instance->Bl.Bl_day); + oncore_log(instance, LOG_INFO, Msg); +} + + +static void oncore_msg_BnEnHn( struct instance *instance, u_char *buf, @@ -2341,7 +2622,6 @@ ) { long dt1, dt2; - char *cp; if (instance->o_state != ONCORE_RUN) return; @@ -2349,8 +2629,7 @@ if (instance->traim_delay) { /* flag that @@Bn/@@En/Hn returned */ instance->traim_ck = 1; instance->traim_delay = 0; - cp = "ONCORE: Detected TRAIM, TRAIM = ON"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "ONCORE: Detected TRAIM, TRAIM = ON"); oncore_set_traim(instance); } @@ -2363,8 +2642,10 @@ /* If Time RAIM doesn't like it, don't trust it */ if (buf[2] == 'H') { - if (instance->BEHn[6]) /* bad TRAIM */ + if (instance->BEHn[6]) { /* bad TRAIM */ + oncore_log(instance, LOG_WARNING, "BAD TRAIM"); return; + } dt1 = instance->saw_tooth + instance->offset; /* dt this time step */ instance->saw_tooth = (s_char) instance->BEHn[14]; /* update for next time Hn[14] */ @@ -2406,7 +2687,7 @@ size_t len ) { - char *cp; + char Msg[120]; int i; if (instance->o_state == ONCORE_TEST_SENT) { @@ -2414,12 +2695,17 @@ instance->timeout = 0; -#ifdef DEBUG +#if ONCORE_VERBOSE_SELF_TEST if (debug > 2) { if (buf[2] == 'I') - printf("ONCORE[%d]: >>@@%ca %x %x %x\n", instance->unit, buf[2], buf[4], buf[5], buf[6]); + snprintf(Msg, sizeof(Msg), + ">>@@%ca %x %x %x", buf[2], + buf[4], buf[5], buf[6]); else - printf("ONCORE[%d]: >>@@%ca %x %x\n", instance->unit, buf[2], buf[4], buf[5]); + snprintf(Msg, sizeof(Msg), + ">>@@%ca %x %x", buf[2], + buf[4], buf[5]); + oncore_log(instance, LOG_DEBUG, Msg); } #endif @@ -2429,15 +2715,18 @@ i = buf[4] || buf[5]; if (buf[2] == 'I') i = i || buf[6]; if (i) { - if (buf[2] == 'I') { - msyslog(LOG_ERR, "ONCORE[%d]: self test failed: result %02x %02x %02x", - instance->unit, buf[4], buf[5], buf[6]); - } else { - msyslog(LOG_ERR, "ONCORE[%d]: self test failed: result %02x %02x", - instance->unit, buf[4], buf[5]); - } - cp = "ONCORE: self test failed, shutting down driver"; - record_clock_stats(&instance->peer->srcadr, cp); + if (buf[2] == 'I') + snprintf(Msg, sizeof(Msg), + "self test failed: result %02x %02x %02x", + buf[4], buf[5], buf[6]); + else + snprintf(Msg, sizeof(Msg), + "self test failed: result %02x %02x", + buf[4], buf[5]); + oncore_log(instance, LOG_ERR, Msg); + + oncore_log(instance, LOG_ERR, + "ONCORE: self test failed, shutting down driver"); refclock_report(instance->peer, CEVNT_FAULT); oncore_shutdown(instance->unit, instance->peer); @@ -2449,11 +2738,10 @@ oncore_antenna_report(instance, antenna); instance->o_state = ONCORE_INIT; - cp = "state = ONCORE_INIT"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "state = ONCORE_INIT"); instance->timeout = 4; - oncore_sendmsg(instance->ttyfd, oncore_cmd_Cj, sizeof(oncore_cmd_Cj)); + oncore_sendmsg(instance, oncore_cmd_Cj, sizeof(oncore_cmd_Cj)); } } @@ -2484,10 +2772,7 @@ else if (buf[4] == 4 && buf[5] == 25) i = 34; else { - char *cp; - - cp = "Cb: Response is NO ALMANAC"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "Cb: Response is NO ALMANAC"); return; } @@ -2495,11 +2780,13 @@ instance->shmem[instance->shmem_Cb + i + 2]++; memcpy(instance->shmem + instance->shmem_Cb + i + 3, buf, (size_t) (len + 3)); -#if 1 +#ifdef ONCORE_VERBOSE_MSG_CB { - char Msg[160]; - sprintf(Msg, "See Cb [%d,%d]", buf[4], buf[5]); - record_clock_stats(&(instance->peer->srcadr), Msg); + char Msg[160]; + + snprintf(Msg, sizeof(Msg), "See Cb [%d,%d]", buf[4], + buf[5]); + oncore_log(instance, LOG_DEBUG, Msg); } #endif } @@ -2518,16 +2805,13 @@ size_t len ) { - const char *cp; - if (instance->o_state == ONCORE_RESET_SENT) { - oncore_sendmsg(instance->ttyfd, oncore_cmd_Cg, sizeof(oncore_cmd_Cg)); /* Return to Posn Fix mode */ + oncore_sendmsg(instance, oncore_cmd_Cg, sizeof(oncore_cmd_Cg)); /* Return to Posn Fix mode */ /* Reset set VP to IDLE */ instance->o_state = ONCORE_TEST_SENT; - cp = "state = ONCORE_TEST_SENT"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "state = ONCORE_TEST_SENT"); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Cj, sizeof(oncore_cmd_Cj)); + oncore_sendmsg(instance, oncore_cmd_Cj, sizeof(oncore_cmd_Cj)); } } @@ -2556,7 +2840,6 @@ ) { int mode; - char *cp; memcpy(instance->Cj, buf, len); @@ -2568,23 +2851,21 @@ mode = instance->init_type; if (mode == 3 || mode == 4) { /* Cf will return here to check for TEST */ instance->o_state = ONCORE_RESET_SENT; - cp = "state = ONCORE_RESET_SENT"; - record_clock_stats(&(instance->peer->srcadr), cp); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Cf, sizeof(oncore_cmd_Cf)); + oncore_log(instance, LOG_NOTICE, "state = ONCORE_RESET_SENT"); + oncore_sendmsg(instance, oncore_cmd_Cf, sizeof(oncore_cmd_Cf)); } else { instance->o_state = ONCORE_TEST_SENT; - cp = "state = ONCORE_TEST_SENT"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "state = ONCORE_TEST_SENT"); } } if (instance->o_state == ONCORE_TEST_SENT) { if (instance->chan == 6) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ca, sizeof(oncore_cmd_Ca)); + oncore_sendmsg(instance, oncore_cmd_Ca, sizeof(oncore_cmd_Ca)); else if (instance->chan == 8) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Fa, sizeof(oncore_cmd_Fa)); + oncore_sendmsg(instance, oncore_cmd_Fa, sizeof(oncore_cmd_Fa)); else if (instance->chan == 12) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ia, sizeof(oncore_cmd_Ia)); + oncore_sendmsg(instance, oncore_cmd_Ia, sizeof(oncore_cmd_Ia)); } else if (instance->o_state == ONCORE_INIT) oncore_msg_Cj_init(instance, buf, len); } @@ -2620,7 +2901,7 @@ if (!cp1) cp1 = (char *)&instance->Cj[294]; *cp1 = '\0'; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, cp); *cp1 = '\r'; cp = cp1+2; } @@ -2681,8 +2962,10 @@ /* use MODEL to set CHAN and TRAIM and possibly zero SHMEM */ - sprintf(Msg, "This looks like an Oncore %s with version %d.%d firmware.", cp, instance->version, instance->revision); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), + "This looks like an Oncore %s with version %d.%d firmware.", + cp, instance->version, instance->revision); + oncore_log(instance, LOG_INFO, Msg); instance->chan_id = 8; /* default */ if (instance->model == ONCORE_BASIC || instance->model == ONCORE_PVT6) @@ -2700,9 +2983,14 @@ else if (instance->model == ONCORE_M12) instance->traim_id = -1; - sprintf(Msg, "Channels = %d, TRAIM = %s", instance->chan_id, - ((instance->traim_id < 0) ? "UNKNOWN" : ((instance->traim_id > 0) ? "ON" : "OFF"))); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), "Channels = %d, TRAIM = %s", + instance->chan_id, + ((instance->traim_id < 0) + ? "UNKNOWN" + : (instance->traim_id > 0) + ? "ON" + : "OFF")); + oncore_log(instance, LOG_INFO, Msg); } @@ -2720,8 +3008,8 @@ size_t len ) { - char *cp, Msg[160]; - u_char Cmd[20]; + char Msg[160]; + u_char Cmd[20]; int mode; @@ -2733,17 +3021,19 @@ if (instance->chan == 12) { instance->shmem_bad_Ea = 1; - sprintf(Msg, "*** SHMEM partially enabled for ONCORE M12 s/w v%d.%d ***", instance->version, instance->revision); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), + "*** SHMEM partially enabled for ONCORE M12 s/w v%d.%d ***", + instance->version, instance->revision); + oncore_log(instance, LOG_NOTICE, Msg); } - oncore_sendmsg(instance->ttyfd, oncore_cmd_Cg, sizeof(oncore_cmd_Cg)); /* Return to Posn Fix mode */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Bb, sizeof(oncore_cmd_Bb)); /* turn on for shmem (6/8/12) */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ek, sizeof(oncore_cmd_Ek)); /* turn off (VP) */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Aw, sizeof(oncore_cmd_Aw)); /* UTC time (6/8/12) */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_AB, sizeof(oncore_cmd_AB)); /* Appl type static (VP) */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Be, sizeof(oncore_cmd_Be)); /* Tell us the Almanac for shmem (6/8/12) */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Bd, sizeof(oncore_cmd_Bd)); /* Tell us when Almanac changes */ + oncore_sendmsg(instance, oncore_cmd_Cg, sizeof(oncore_cmd_Cg)); /* Return to Posn Fix mode */ + oncore_sendmsg(instance, oncore_cmd_Bb, sizeof(oncore_cmd_Bb)); /* turn on for shmem (6/8/12) */ + oncore_sendmsg(instance, oncore_cmd_Ek, sizeof(oncore_cmd_Ek)); /* turn off (VP) */ + oncore_sendmsg(instance, oncore_cmd_Aw, sizeof(oncore_cmd_Aw)); /* UTC time (6/8/12) */ + oncore_sendmsg(instance, oncore_cmd_AB, sizeof(oncore_cmd_AB)); /* Appl type static (VP) */ + oncore_sendmsg(instance, oncore_cmd_Be, sizeof(oncore_cmd_Be)); /* Tell us the Almanac for shmem (6/8/12) */ + oncore_sendmsg(instance, oncore_cmd_Bd, sizeof(oncore_cmd_Bd)); /* Tell us when Almanac changes */ mode = instance->init_type; @@ -2753,23 +3043,23 @@ */ if (instance->posn_set) { - record_clock_stats(&(instance->peer->srcadr), "Setting Posn from input data"); + oncore_log(instance, LOG_INFO, "Setting Posn from input data"); oncore_set_posn(instance); /* this should print posn indirectly thru the As cmd */ } else /* must issue an @@At here to check on 6/8 Position Hold, set_posn would have */ if (instance->chan != 12) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Atx, sizeof(oncore_cmd_Atx)); + oncore_sendmsg(instance, oncore_cmd_Atx, sizeof(oncore_cmd_Atx)); if (mode != 0) { /* cable delay in ns */ memcpy(Cmd, oncore_cmd_Az, (size_t) sizeof(oncore_cmd_Az)); w32_buf(&Cmd[-2+4], instance->delay); - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_Az)); /* 6,8,12 */ + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_Az)); /* 6,8,12 */ /* PPS offset in ns */ if (instance->offset) { memcpy(Cmd, oncore_cmd_Ay, (size_t) sizeof(oncore_cmd_Ay)); /* some have it, some don't */ w32_buf(&Cmd[-2+4], instance->offset); /* will check for hw response */ - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_Ay)); + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_Ay)); } /* Satellite mask angle */ @@ -2777,7 +3067,7 @@ if (instance->Ag != 0xff) { /* will have 0xff in it if not set by user */ memcpy(Cmd, oncore_cmd_Ag, (size_t) sizeof(oncore_cmd_Ag)); Cmd[-2+4] = instance->Ag; - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_Ag)); + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_Ag)); } } @@ -2789,29 +3079,28 @@ */ if (instance->chan == 6) { /* start 6chan, kill 8,12chan commands, possibly testing VP in 6chan mode */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ea0, sizeof(oncore_cmd_Ea0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_En0, sizeof(oncore_cmd_En0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ha0, sizeof(oncore_cmd_Ha0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Hn0, sizeof(oncore_cmd_Hn0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ba, sizeof(oncore_cmd_Ba )); + oncore_sendmsg(instance, oncore_cmd_Ea0, sizeof(oncore_cmd_Ea0)); + oncore_sendmsg(instance, oncore_cmd_En0, sizeof(oncore_cmd_En0)); + oncore_sendmsg(instance, oncore_cmd_Ha0, sizeof(oncore_cmd_Ha0)); + oncore_sendmsg(instance, oncore_cmd_Hn0, sizeof(oncore_cmd_Hn0)); + oncore_sendmsg(instance, oncore_cmd_Ba, sizeof(oncore_cmd_Ba )); } else if (instance->chan == 8) { /* start 8chan, kill 6,12chan commands */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ba0, sizeof(oncore_cmd_Ba0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Bn0, sizeof(oncore_cmd_Bn0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ha0, sizeof(oncore_cmd_Ha0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Hn0, sizeof(oncore_cmd_Hn0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ea, sizeof(oncore_cmd_Ea )); + oncore_sendmsg(instance, oncore_cmd_Ba0, sizeof(oncore_cmd_Ba0)); + oncore_sendmsg(instance, oncore_cmd_Bn0, sizeof(oncore_cmd_Bn0)); + oncore_sendmsg(instance, oncore_cmd_Ha0, sizeof(oncore_cmd_Ha0)); + oncore_sendmsg(instance, oncore_cmd_Hn0, sizeof(oncore_cmd_Hn0)); + oncore_sendmsg(instance, oncore_cmd_Ea, sizeof(oncore_cmd_Ea )); } else if (instance->chan == 12){ /* start 12chan, kill 6,12chan commands */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ba0, sizeof(oncore_cmd_Ba0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Bn0, sizeof(oncore_cmd_Bn0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ea0, sizeof(oncore_cmd_Ea0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_En0, sizeof(oncore_cmd_En0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ha, sizeof(oncore_cmd_Ha )); + oncore_sendmsg(instance, oncore_cmd_Ba0, sizeof(oncore_cmd_Ba0)); + oncore_sendmsg(instance, oncore_cmd_Bn0, sizeof(oncore_cmd_Bn0)); + oncore_sendmsg(instance, oncore_cmd_Ea0, sizeof(oncore_cmd_Ea0)); + oncore_sendmsg(instance, oncore_cmd_En0, sizeof(oncore_cmd_En0)); + oncore_sendmsg(instance, oncore_cmd_Ha, sizeof(oncore_cmd_Ha )); } instance->count = 1; instance->o_state = ONCORE_ALMANAC; - cp = "state = ONCORE_ALMANAC"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "state = ONCORE_ALMANAC"); } @@ -2843,8 +3132,10 @@ Ht /= 100; - sprintf(Msg, "Ga Posn Lat = %.7f, Lon = %.7f, Ht = %.2f", Lat, Lon, Ht); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), + "Ga Posn Lat = %.7f, Lon = %.7f, Ht = %.2f", Lat, + Lon, Ht); + oncore_log(instance, LOG_NOTICE, Msg); instance->ss_lat = lat; instance->ss_long = lon; @@ -2879,9 +3170,10 @@ gmth = buf[12]; gmtm = buf[13]; - sprintf(Msg, "Date/Time set to: %d%s%d %2d:%02d:%02d GMT (GMT offset is %s%02d:%02d)", - d, Month[mo-1], y, h, m, s, gmts, gmth, gmtm); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), + "Date/Time set to: %d%s%d %2d:%02d:%02d GMT (GMT offset is %s%02d:%02d)", + d, Month[mo-1], y, h, m, s, gmts, gmth, gmtm); + oncore_log(instance, LOG_NOTICE, Msg); } @@ -2905,20 +3197,21 @@ dt = buf[5] - buf[4]; -#if 1 - sprintf(Msg, "ONCORE[%d]: Leap Sec Msg: %d %d %d %d %d %d %d %d %d %d", - instance->unit, - buf[4], buf[5], 256*buf[6]+buf[7], buf[8], buf[9], buf[10], - (buf[14]+256*(buf[13]+256*(buf[12]+256*buf[11]))), - buf[15], buf[16], buf[17]); - record_clock_stats(&(instance->peer->srcadr), Msg); -#endif + snprintf(Msg, sizeof(Msg), + "Leap Sec Msg: %d %d %d %d %d %d %d %d %d %d", buf[4], + buf[5], 256 * buf[6] + buf[7], buf[8], buf[9], buf[10], + (buf[14] + 256 * + (buf[13] + 256 * (buf[12] + 256 * buf[11]))), + buf[15], buf[16], buf[17]); + oncore_log(instance, LOG_INFO, Msg); + if (dt) { - sprintf(Msg, "ONCORE[%d]: Leap second (%d) scheduled for %d%s%d at %d:%d:%d", - instance->unit, - dt, buf[9], Month[buf[8]-1], 256*buf[6]+buf[7], - buf[15], buf[16], buf[17]); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), + "Leap second (%d) scheduled for %d%s%d at %d:%d:%d", + dt, buf[9], Month[buf[8] - 1], + 256 * buf[6] + buf[7], buf[15], buf[16], + buf[17]); + oncore_log(instance, LOG_NOTICE, Msg); } /* Only raise warning within a month of the leap second */ @@ -2938,7 +3231,7 @@ } } } - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_INFO, cp); } @@ -2952,11 +3245,8 @@ size_t len ) { - const char *cp; - - cp = "Oncore: System Failure at Power On"; if (instance && instance->peer) { - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_ERR, "Oncore: System Failure at Power On"); oncore_shutdown(instance->unit, instance->peer); } } @@ -2983,7 +3273,7 @@ } instance->ant_state = new_state; - record_clock_stats(&instance->peer->srcadr, cp); + oncore_log(instance, LOG_NOTICE, cp); } @@ -2993,8 +3283,6 @@ struct instance *instance ) { - char *cp; - /* subroutine oncore_Cj_id has determined the number of channels from the * model number of the attached oncore. This is not always correct since * the oncore could have non-standard firmware. Here we check (independently) by @@ -3005,13 +3293,12 @@ */ instance->o_state = ONCORE_CHECK_CHAN; - cp = "state = ONCORE_CHECK_CHAN"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "state = ONCORE_CHECK_CHAN"); instance->count3 = 1; - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ba, sizeof(oncore_cmd_Ba)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ea, sizeof(oncore_cmd_Ea)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ha, sizeof(oncore_cmd_Ha)); + oncore_sendmsg(instance, oncore_cmd_Ba, sizeof(oncore_cmd_Ba)); + oncore_sendmsg(instance, oncore_cmd_Ea, sizeof(oncore_cmd_Ea)); + oncore_sendmsg(instance, oncore_cmd_Ha, sizeof(oncore_cmd_Ha)); } @@ -3043,17 +3330,21 @@ instance->count5 = 2; instance->count5_set = 1; } -#if 0 -{ - char Msg[160]; - - sprintf(Msg, "ONCORE[%d]: DEBUG BITS: (%x %x), (%x %x %x), %x %x %x %x %x\n", - instance->unit, - instance->BEHa[129], instance->BEHa[130], bits1, bits2, bits3, instance->mode == MODE_0D, - instance->mode == MODE_2D, instance->mode == MODE_3D, - instance->rsm.bad_almanac, instance->rsm.bad_fix); - record_clock_stats(&(instance->peer->srcadr), Msg); -} +#ifdef ONCORE_VERBOSE_CHECK_ALMANAC + { + char Msg[160]; + + snprintf(Msg, sizeof(Msg), + "DEBUG BITS: (%x %x), (%x %x %x), %x %x %x %x %x", + instance->BEHa[129], + instance->BEHa[130], bits1, bits2, + bits3, instance->mode == MODE_0D, + instance->mode == MODE_2D, + instance->mode == MODE_3D, + instance->rsm.bad_almanac, + instance->rsm.bad_fix); + oncore_log(instance, LOG_DEBUG, Msg); + } #endif } } @@ -3108,19 +3399,21 @@ struct instance *instance ) { - if (instance->Bj_day != instance->BEHa[5]) { /* do this 1/day */ + oncore_cmd_Bl[2] = 1; /* just to be sure */ + if (instance->Bj_day != instance->BEHa[5]) { /* do this 1/day */ instance->Bj_day = instance->BEHa[5]; if (instance->saw_Gj < 0) { /* -1 DONT have Gj use Bj */ if ((instance->BEHa[4] == 6) || (instance->BEHa[4] == 12)) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Bj, sizeof(oncore_cmd_Bj)); + oncore_sendmsg(instance, oncore_cmd_Bj, sizeof(oncore_cmd_Bj)); + oncore_sendmsg(instance, oncore_cmd_Bl, sizeof(oncore_cmd_Bl)); return; } if (instance->saw_Gj == 0) /* 0 is dont know if we have Gj */ instance->count4 = 1; - oncore_sendmsg(instance->ttyfd, oncore_cmd_Gj, sizeof(oncore_cmd_Gj)); + oncore_sendmsg(instance, oncore_cmd_Gj, sizeof(oncore_cmd_Gj)); return; } @@ -3135,7 +3428,8 @@ instance->saw_Gj = -1; /* didnt see it, will use Bj */ instance->count4 = 0; if ((instance->BEHa[4] == 6) || (instance->BEHa[4] == 12)) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Bj, sizeof(oncore_cmd_Bj)); + oncore_sendmsg(instance, oncore_cmd_Bj, sizeof(oncore_cmd_Bj)); + oncore_sendmsg(instance, oncore_cmd_Bl, sizeof(oncore_cmd_Bl)); } } } @@ -3189,8 +3483,9 @@ /* if MSL is not set, the calculation is meaningless */ if (MSL) { /* not set ! */ - sprintf(Msg, "dH = (GPS - MSL) = %.2fm", instance->dH); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), "dH = (GPS - MSL) = %.2fm", + instance->dH); + oncore_log(instance, LOG_INFO, Msg); } } @@ -3213,44 +3508,43 @@ if (!instance->shmem) return; -#if 1 - for (cp=instance->shmem+4; (n = 256*(*(cp-3)) + *(cp-2)); cp+=(n+3)) { +#ifndef ONCORE_VERBOSE_LOAD_ALMANAC + for (cp = instance->shmem + 4; (n = 256 * (*(cp-3)) + *(cp-2)); + cp += (n + 3)) { if (!strncmp((char *) cp, "@@Cb", 4) && oncore_checksum_ok(cp, 33) && (*(cp+4) == 4 || *(cp+4) == 5)) { write(instance->ttyfd, cp, n); -#if 1 oncore_print_Cb(instance, cp); -#endif } } -#else -/************DEBUG************/ - for (cp=instance->shmem+4; (n = 256*(*(cp-3)) + *(cp-2)); cp+=(n+3)) { +#else /* ONCORE_VERBOSE_LOAD_ALMANAC follows */ + for (cp = instance->shmem + 4; (n = 256 * (*(cp-3)) + *(cp-2)); + cp += (n+3)) { char Msg[160]; - sprintf(Msg, "See %c%c%c%c %d", *(cp), *(cp+1), *(cp+2), *(cp+3), *(cp+4)); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), "See %c%c%c%c %d", *(cp), + *(cp+1), *(cp+2), *(cp+3), *(cp+4)); + oncore_log(instance, LOG_DEBUG, Msg); if (!strncmp(cp, "@@Cb", 4)) { oncore_print_Cb(instance, cp); if (oncore_checksum_ok(cp, 33)) { if (*(cp+4) == 4 || *(cp+4) == 5) { - record_clock_stats(&(instance->peer->srcadr), "GOOD SF"); + oncore_log(instance, LOG_DEBUG, "GOOD SF"); write(instance->ttyfd, cp, n); } else - record_clock_stats(&(instance->peer->srcadr), "BAD SF"); + oncore_log(instance, LOG_DEBUG, "BAD SF"); } else - record_clock_stats(&(instance->peer->srcadr), "BAD CHECKSUM"); + oncore_log(instance, LOG_DEBUG, "BAD CHECKSUM"); } } -/************DEBUG************/ #endif /* Must load position and time or the Almanac doesn't do us any good */ if (!instance->posn_set) { /* if we input a posn use it, else from SHMEM */ - record_clock_stats(&(instance->peer->srcadr), "Loading Posn from SHMEM"); + oncore_log(instance, LOG_NOTICE, "Loading Posn from SHMEM"); for (cp=instance->shmem+4; (n = 256*(*(cp-3)) + *(cp-2)); cp+=(n+3)) { if ((instance->chan == 6 && (!strncmp((char *) cp, "@@Ba", 4) && oncore_checksum_ok(cp, 68))) || (instance->chan == 8 && (!strncmp((char *) cp, "@@Ea", 4) && oncore_checksum_ok(cp, 76))) || @@ -3261,12 +3555,15 @@ ii = buf_w32(cp + 15); jj = buf_w32(cp + 19); kk = buf_w32(cp + 23); -#if 0 -{ -char Msg[160]; -sprintf(Msg, "SHMEM posn = %ld (%d, %d, %d)", (long) (cp-instance->shmem), ii, jj, kk); -record_clock_stats(&(instance->peer->srcadr), Msg); -} +#ifdef ONCORE_VERBOSE_LOAD_ALMANAC + { + char Msg[160]; + snprintf(Msg, sizeof(Msg), + "SHMEM posn = %ld (%d, %d, %d)", + (long)(cp-instance->shmem), + ii, jj, kk); + oncore_log(instance, LOG_DEBUG, Msg); + } #endif if (ii != 0 || jj != 0 || kk != 0) { /* phk asked for this test */ instance->ss_lat = ii; @@ -3280,14 +3577,16 @@ /* and set time to time from Computer clock */ - gettimeofday(&tv, 0); + GETTIMEOFDAY(&tv, 0); tm = gmtime((const time_t *) &tv.tv_sec); -#if 1 + +#ifdef ONCORE_VERBOSE_LOAD_ALMANAC { - char Msg[160]; - sprintf(Msg, "DATE %d %d %d, %d %d %d", 1900+tm->tm_year, tm->tm_mon, tm->tm_mday, - tm->tm_hour, tm->tm_min, tm->tm_sec); - record_clock_stats(&(instance->peer->srcadr), Msg); + char Msg[160]; + snprintf(Msg, sizeof(Msg), "DATE %d %d %d, %d %d %d", + 1900 + tm->tm_year, tm->tm_mon, tm->tm_mday, + tm->tm_hour, tm->tm_min, tm->tm_sec); + oncore_log(instance, LOG_DEBUG, Msg); } #endif if (instance->chan == 12) { @@ -3302,27 +3601,27 @@ Cmd[-2+11] = 0; Cmd[-2+12] = 0; Cmd[-2+13] = 0; - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_Gb)); + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_Gb)); } else { /* First set GMT offset to zero */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ab, sizeof(oncore_cmd_Ab)); + oncore_sendmsg(instance, oncore_cmd_Ab, sizeof(oncore_cmd_Ab)); memcpy(Cmd, oncore_cmd_Ac, (size_t) sizeof(oncore_cmd_Ac)); Cmd[-2+4] = tm->tm_mon + 1; Cmd[-2+5] = tm->tm_mday; Cmd[-2+6] = (1900+tm->tm_year)/256; Cmd[-2+7] = (1900+tm->tm_year)%256; - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_Ac)); + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_Ac)); memcpy(Cmd, oncore_cmd_Aa, (size_t) sizeof(oncore_cmd_Aa)); Cmd[-2+4] = tm->tm_hour; Cmd[-2+5] = tm->tm_min; Cmd[-2+6] = tm->tm_sec; - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_Aa)); + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_Aa)); } - record_clock_stats(&(instance->peer->srcadr), "Setting Posn and Time after Loading Almanac"); + oncore_log(instance, LOG_INFO, "Setting Posn and Time after Loading Almanac"); } @@ -3335,18 +3634,24 @@ u_char *cp ) { -#if 0 +#ifdef ONCORE_VERBOSE_CB int ii; - char Msg[160]; - - printf("DEBUG: See: %c%c%c%c\n", *(cp), *(cp+1), *(cp+2), *(cp+3)); - printf("DEBUG: Cb: [%d,%d]", *(cp+4), *(cp+5)); - for(ii=0; ii<33; ii++) - printf(" %d", *(cp+ii)); - printf("\n"); + char Msg[160], Msg2[10]; - sprintf(Msg, "Debug: Cb: [%d,%d]", *(cp+4), *(cp+5)); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), "DEBUG: See: %c%c%c%c", *(cp), + *(cp+1), *(cp+2), *(cp+3)); + oncore_log(instance, LOG_DEBUG, Msg); + snprintf(Msg, sizeof(Msg), "DEBUG: Cb: [%d,%d]", *(cp+4), + *(cp+5)); + for(ii = 0; ii < 33; ii++) { + snprintf(Msg2, sizeof(Msg2), " %d", *(cp+ii)); + strncat(Msg, Msg2, sizeof(Msg)); + } + oncore_log(instance, LOG_DEBUG, Msg); + + snprintf(Msg, sizeof(Msg), "Debug: Cb: [%d,%d]", *(cp+4), + *(cp+5)); + oncore_log(instance, LOG_DEBUG, Msg); #endif } @@ -3384,7 +3689,7 @@ int idx, idy, is, imx, imy; long lat, lon; - record_clock_stats(&(instance->peer->srcadr), "Posn:"); + oncore_log(instance, LOG_INFO, "Posn:"); ew = 'E'; lon = instance->ss_long; if (lon < 0) { @@ -3404,8 +3709,10 @@ xd = lat/3600000.; /* lat, lon in int msec arc, ht in cm. */ yd = lon/3600000.; - sprintf(Msg, "Lat = %c %11.7fdeg, Long = %c %11.7fdeg, Alt = %5.2fm (%5.2fft) GPS", ns, xd, ew, yd, hm, hft); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), + "Lat = %c %11.7fdeg, Long = %c %11.7fdeg, Alt = %5.2fm (%5.2fft) GPS", + ns, xd, ew, yd, hm, hft); + oncore_log(instance, LOG_INFO, Msg); idx = xd; idy = yd; @@ -3413,9 +3720,9 @@ imy = lon%3600000; xm = imx/60000.; ym = imy/60000.; - sprintf(Msg, + snprintf(Msg, sizeof(Msg), "Lat = %c %3ddeg %7.4fm, Long = %c %3ddeg %8.5fm, Alt = %7.2fm (%7.2fft) GPS", ns, idx, xm, ew, idy, ym, hm, hft); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log(instance, LOG_INFO, Msg); imx = xm; imy = ym; @@ -3423,9 +3730,10 @@ xs = is/1000.; is = lon%60000; ys = is/1000.; - sprintf(Msg, - "Lat = %c %3ddeg %2dm %5.2fs, Long = %c %3ddeg %2dm %5.2fs, Alt = %7.2fm (%7.2fft) GPS", ns, idx, imx, xs, ew, idy, imy, ys, hm, hft); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), + "Lat = %c %3ddeg %2dm %5.2fs, Long = %c %3ddeg %2dm %5.2fs, Alt = %7.2fm (%7.2fft) GPS", + ns, idx, imx, xs, ew, idy, imy, ys, hm, hft); + oncore_log(instance, LOG_INFO, Msg); } @@ -3436,16 +3744,23 @@ static void oncore_sendmsg( - int fd, + struct instance *instance, u_char *ptr, size_t len ) { + int fd; u_char cs = 0; -#ifdef DEBUG - if (debug > 4) - printf("ONCORE: Send @@%c%c %d\n", ptr[0], ptr[1], (int) len); + fd = instance->ttyfd; +#ifdef ONCORE_VERBOSE_SENDMSG + if (debug > 4) { + char Msg[120]; + + snprintf(Msg, sizeof(Msg), "ONCORE: Send @@%c%c %d", + ptr[0], ptr[1], (int)len); + oncore_log(instance, LOG_DEBUG, Msg); + } #endif write(fd, "@@", (size_t) 2); write(fd, ptr, len); @@ -3469,10 +3784,10 @@ will get set ON in @@Ea later */ if (instance->chan == 12) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Gd0, sizeof(oncore_cmd_Gd0)); /* (12) */ + oncore_sendmsg(instance, oncore_cmd_Gd0, sizeof(oncore_cmd_Gd0)); /* (12) */ else { - oncore_sendmsg(instance->ttyfd, oncore_cmd_At0, sizeof(oncore_cmd_At0)); /* (6/8) */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Av0, sizeof(oncore_cmd_Av0)); /* (6/8) */ + oncore_sendmsg(instance, oncore_cmd_At0, sizeof(oncore_cmd_At0)); /* (6/8) */ + oncore_sendmsg(instance, oncore_cmd_Av0, sizeof(oncore_cmd_Av0)); /* (6/8) */ } mode = instance->init_type; @@ -3483,12 +3798,12 @@ w32_buf(&Cmd[-2+8], (int) instance->ss_long); w32_buf(&Cmd[-2+12], (int) instance->ss_ht); Cmd[-2+16] = 0; - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_As)); /* posn hold 3D posn (6/8/12) */ + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_As)); /* posn hold 3D posn (6/8/12) */ memcpy(Cmd, oncore_cmd_Au, (size_t) sizeof(oncore_cmd_Au)); w32_buf(&Cmd[-2+4], (int) instance->ss_ht); Cmd[-2+8] = 0; - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_Au)); /* altitude hold (6/8/12 not UT, M12T) */ + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_Au)); /* altitude hold (6/8/12 not UT, M12T) */ /* next set current position */ @@ -3498,28 +3813,28 @@ w32_buf(&Cmd[-2+8], (int) instance->ss_long); w32_buf(&Cmd[-2+12],(int) instance->ss_ht); Cmd[-2+16] = 0; - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_Ga)); /* 3d posn (12) */ + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_Ga)); /* 3d posn (12) */ } else { memcpy(Cmd, oncore_cmd_Ad, (size_t) sizeof(oncore_cmd_Ad)); w32_buf(&Cmd[-2+4], (int) instance->ss_lat); - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_Ad)); /* lat (6/8) */ + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_Ad)); /* lat (6/8) */ memcpy(Cmd, oncore_cmd_Ae, (size_t) sizeof(oncore_cmd_Ae)); w32_buf(&Cmd[-2+4], (int) instance->ss_long); - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_Ae)); /* long (6/8) */ + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_Ae)); /* long (6/8) */ memcpy(Cmd, oncore_cmd_Af, (size_t) sizeof(oncore_cmd_Af)); w32_buf(&Cmd[-2+4], (int) instance->ss_ht); Cmd[-2+8] = 0; - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_Af)); /* ht (6/8) */ + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_Af)); /* ht (6/8) */ } /* Finally, turn on position hold */ if (instance->chan == 12) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Gd1, sizeof(oncore_cmd_Gd1)); + oncore_sendmsg(instance, oncore_cmd_Gd1, sizeof(oncore_cmd_Gd1)); else - oncore_sendmsg(instance->ttyfd, oncore_cmd_At1, sizeof(oncore_cmd_At1)); + oncore_sendmsg(instance, oncore_cmd_At1, sizeof(oncore_cmd_At1)); } } @@ -3537,25 +3852,29 @@ else instance->traim = instance->traim_ck; - sprintf(Msg, "Input says TRAIM = %d", instance->traim_in); - record_clock_stats(&(instance->peer->srcadr), Msg); - sprintf(Msg, "Model # says TRAIM = %d", instance->traim_id); - record_clock_stats(&(instance->peer->srcadr), Msg); - sprintf(Msg, "Testing says TRAIM = %d", instance->traim_ck); - record_clock_stats(&(instance->peer->srcadr), Msg); - sprintf(Msg, "Using TRAIM = %d", instance->traim); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), "Input says TRAIM = %d", + instance->traim_in); + oncore_log(instance, LOG_INFO, Msg); + snprintf(Msg, sizeof(Msg), "Model # says TRAIM = %d", + instance->traim_id); + oncore_log(instance, LOG_INFO, Msg); + snprintf(Msg, sizeof(Msg), "Testing says TRAIM = %d", + instance->traim_ck); + oncore_log(instance, LOG_INFO, Msg); + snprintf(Msg, sizeof(Msg), "Using TRAIM = %d", + instance->traim); + oncore_log(instance, LOG_INFO, Msg); if (instance->traim_ck == 1 && instance->traim == 0) { /* if it should be off, and I turned it on during testing, then turn it off again */ if (instance->chan == 6) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Bnx, sizeof(oncore_cmd_Bnx)); + oncore_sendmsg(instance, oncore_cmd_Bnx, sizeof(oncore_cmd_Bnx)); else if (instance->chan == 8) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Enx, sizeof(oncore_cmd_Enx)); + oncore_sendmsg(instance, oncore_cmd_Enx, sizeof(oncore_cmd_Enx)); else /* chan == 12 */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ge0, sizeof(oncore_cmd_Ge0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Hn0, sizeof(oncore_cmd_Hn0)); + oncore_sendmsg(instance, oncore_cmd_Ge0, sizeof(oncore_cmd_Ge0)); + oncore_sendmsg(instance, oncore_cmd_Hn0, sizeof(oncore_cmd_Hn0)); } } @@ -3574,28 +3893,28 @@ instance->shmem_reset = 1; if (instance->chan == 12) { if (instance->shmem_Posn == 2) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Gd2, sizeof(oncore_cmd_Gd2)); /* 2D */ + oncore_sendmsg(instance, oncore_cmd_Gd2, sizeof(oncore_cmd_Gd2)); /* 2D */ else - oncore_sendmsg(instance->ttyfd, oncore_cmd_Gd0, sizeof(oncore_cmd_Gd0)); /* 3D */ + oncore_sendmsg(instance, oncore_cmd_Gd0, sizeof(oncore_cmd_Gd0)); /* 3D */ } else { if (instance->saw_At) { /* out of 0D -> 3D mode */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_At0, sizeof(oncore_cmd_At0)); + oncore_sendmsg(instance, oncore_cmd_At0, sizeof(oncore_cmd_At0)); if (instance->shmem_Posn == 2) /* 3D -> 2D mode */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Av1, sizeof(oncore_cmd_Av1)); + oncore_sendmsg(instance, oncore_cmd_Av1, sizeof(oncore_cmd_Av1)); } else - oncore_sendmsg(instance->ttyfd, oncore_cmd_Av0, sizeof(oncore_cmd_Av0)); + oncore_sendmsg(instance, oncore_cmd_Av0, sizeof(oncore_cmd_Av0)); } } else if (instance->shmem_reset || (instance->mode != MODE_0D)) { instance->shmem_reset = 0; if (instance->chan == 12) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Gd1, sizeof(oncore_cmd_Gd1)); /* 0D */ + oncore_sendmsg(instance, oncore_cmd_Gd1, sizeof(oncore_cmd_Gd1)); /* 0D */ else { if (instance->saw_At) { if (instance->mode == MODE_2D) /* 2D -> 3D or 0D mode */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Av0, sizeof(oncore_cmd_Av0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_At1, sizeof(oncore_cmd_At1)); /* to 0D mode */ + oncore_sendmsg(instance, oncore_cmd_Av0, sizeof(oncore_cmd_Av0)); + oncore_sendmsg(instance, oncore_cmd_At1, sizeof(oncore_cmd_At1)); /* to 0D mode */ } else - oncore_sendmsg(instance->ttyfd, oncore_cmd_Av1, sizeof(oncore_cmd_Av1)); + oncore_sendmsg(instance, oncore_cmd_Av1, sizeof(oncore_cmd_Av1)); } } } @@ -3614,7 +3933,7 @@ struct instance *instance ) { - char *cp, Msg[160]; + char Msg[160]; double lat, lon, ht; @@ -3625,15 +3944,14 @@ if ((instance->chan == 8 && !(instance->BEHa[37] & 0x20)) || (instance->chan == 12 && !(instance->BEHa[130] & 0x10))) { - record_clock_stats(&(instance->peer->srcadr), "Now in 0D mode"); + oncore_log(instance, LOG_INFO, "Now in 0D mode"); if (instance->chan == 12) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Gax, sizeof(oncore_cmd_Gax)); + oncore_sendmsg(instance, oncore_cmd_Gax, sizeof(oncore_cmd_Gax)); else - oncore_sendmsg(instance->ttyfd, oncore_cmd_Asx, sizeof(oncore_cmd_Asx)); + oncore_sendmsg(instance, oncore_cmd_Asx, sizeof(oncore_cmd_Asx)); - cp = "SSstate = ONCORE_SS_DONE"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "SSstate = ONCORE_SS_DONE"); instance->site_survey = ONCORE_SS_DONE; } } else { @@ -3659,22 +3977,24 @@ instance->ss_long /= POS_HOLD_AVERAGE; instance->ss_ht /= POS_HOLD_AVERAGE; - sprintf(Msg, "Surveyed posn: lat %.3f (mas) long %.3f (mas) ht %.3f (cm)", - instance->ss_lat, instance->ss_long, instance->ss_ht); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), + "Surveyed posn: lat %.3f (mas) long %.3f (mas) ht %.3f (cm)", + instance->ss_lat, instance->ss_long, + instance->ss_ht); + oncore_log(instance, LOG_NOTICE, Msg); lat = instance->ss_lat/3600000.; lon = instance->ss_long/3600000.; ht = instance->ss_ht/100; - sprintf(Msg, "Surveyed posn: lat %.7f (deg) long %.7f (deg) ht %.2f (m)", - lat, lon, ht); - record_clock_stats(&(instance->peer->srcadr), Msg); + snprintf(Msg, sizeof(Msg), + "Surveyed posn: lat %.7f (deg) long %.7f (deg) ht %.2f (m)", + lat, lon, ht); + oncore_log(instance, LOG_NOTICE, Msg); oncore_set_posn(instance); - record_clock_stats(&(instance->peer->srcadr), "Now in 0D mode"); + oncore_log(instance, LOG_INFO, "Now in 0D mode"); - cp = "SSstate = ONCORE_SS_DONE"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "SSstate = ONCORE_SS_DONE"); instance->site_survey = ONCORE_SS_DONE; } } @@ -3687,10 +4007,9 @@ ) { if (instance->rsm.bad_almanac) { -#ifdef DEBUG - if (debug) - printf("ONCORE[%d]: waiting for almanac\n", instance->unit); -#endif + instance->counta++; + if (instance->counta%5 == 0) + oncore_log(instance, LOG_INFO, "Waiting for Almanac"); /* * If we get here (first time) then we don't have an almanac in memory. @@ -3707,26 +4026,71 @@ (5sec) and wait for things to settle down */ if (instance->chan == 6) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Bn, sizeof(oncore_cmd_Bn)); + oncore_sendmsg(instance, oncore_cmd_Bn, sizeof(oncore_cmd_Bn)); else if (instance->chan == 8) - oncore_sendmsg(instance->ttyfd, oncore_cmd_En, sizeof(oncore_cmd_En)); + oncore_sendmsg(instance, oncore_cmd_En, sizeof(oncore_cmd_En)); else if (instance->chan == 12) { - oncore_sendmsg(instance->ttyfd, oncore_cmd_Gc, sizeof(oncore_cmd_Gc)); /* 1PPS on, continuous */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ge, sizeof(oncore_cmd_Ge)); /* TRAIM on */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Hn, sizeof(oncore_cmd_Hn)); /* TRAIM status 1/s */ + oncore_sendmsg(instance, oncore_cmd_Gc, sizeof(oncore_cmd_Gc)); /* 1PPS on, continuous */ + oncore_sendmsg(instance, oncore_cmd_Ge, sizeof(oncore_cmd_Ge)); /* TRAIM on */ + oncore_sendmsg(instance, oncore_cmd_Hn, sizeof(oncore_cmd_Hn)); /* TRAIM status 1/s */ } instance->traim_delay = 1; - record_clock_stats(&(instance->peer->srcadr), "Have now loaded an ALMANAC"); + oncore_log(instance, LOG_NOTICE, "Have now loaded an ALMANAC"); instance->o_state = ONCORE_RUN; - record_clock_stats(&(instance->peer->srcadr), "state = ONCORE_RUN"); + oncore_log(instance, LOG_NOTICE, "state = ONCORE_RUN"); } return(0); } +static void +oncore_log ( + struct instance *instance, + int log_level, + const char *msg + ) +{ + int i; + char Msg[200]; + + snprintf(Msg, sizeof(Msg), "ONCORE[%d]: %s", instance->unit, + msg); + syslog(log_level, Msg); + + i = strlen(msg); + + if (i > 127) { + snprintf(Msg, sizeof(Msg), + "Internal Error: max error msg length exceeded in clockstats file (%d)", + i); + record_clock_stats(&(instance->peer->srcadr), Msg); + record_clock_stats(&(instance->peer->srcadr), "Start of message was"); + strncpy(Msg, msg, 120); + record_clock_stats(&(instance->peer->srcadr), Msg); + } else { /* now put ONCORE[n]: ahead of message if it will fit */ + if (i < 110) { + snprintf(Msg, sizeof(Msg), "ONCORE[%d]: %s", + instance->unit, msg); + record_clock_stats(&(instance->peer->srcadr), Msg); + } else + record_clock_stats(&(instance->peer->srcadr), msg); + } + +#ifdef ONCORE_VERBOSE_ONCORE_LOG + instance->max_len = max(i, instance->max_len); + instance->max_count++; + if (instance->max_count % 100 == 0) { + snprintf(Msg, sizeof(Msg), + "Max Message Length so far is %d", + instance->max_len); + oncore_log(instance, LOG_INFO, Msg); + } +#endif +} + #else int refclock_oncore_bs; -#endif /* REFCLOCK */ +#endif /* REFCLOCK && CLOCK_ONCORE */ diff -urN src/contrib/ntp/ntpd/refclock_palisade.c src.ntp/contrib/ntp/ntpd/refclock_palisade.c --- src/contrib/ntp/ntpd/refclock_palisade.c 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/refclock_palisade.c 2010-02-04 08:26:54.000000000 +0100 @@ -50,10 +50,25 @@ * * Version 2.45; July 14, 1999 * + * + * + * 31/03/06: Added support for Thunderbolt GPS Disciplined Clock. + * Contact: Fernando Pablo Hauscarriaga + * E-mail: fernandoph@iar.unlp.edu.ar + * Home page: www.iar.unlp.edu.ar/~fernandoph + * Instituto Argentino de Radioastronomia + * www.iar.unlp.edu.ar + * + * 14/01/07: Conditinal compilation for Thunderbolt support no longer needed + * now we use mode 2 for decode thunderbolt packets. + * Fernando P. Hauscarriaga + * + * 30/08/09: Added support for Trimble Acutime Gold Receiver. + * Fernando P. Hauscarriaga (fernandoph@iar.unlp.edu.ar) */ #ifdef HAVE_CONFIG_H -#include "config.h" +# include "config.h" #endif #if defined(REFCLOCK) && (defined(PALISADE) || defined(CLOCK_PALISADE)) @@ -72,11 +87,11 @@ #ifdef DEBUG const char * Tracking_Status[15][15] = { - { "Doing Fixes\0" }, { "Good 1SV\0" }, { "Approx. 1SV\0" }, - {"Need Time\0" }, { "Need INIT\0" }, { "PDOP too High\0" }, - { "Bad 1SV\0" }, { "0SV Usable\0" }, { "1SV Usable\0" }, - { "2SV Usable\0" }, { "3SV Usable\0" }, { "No Integrity\0" }, - { "Diff Corr\0" }, { "Overdet Clock\0" }, { "Invalid\0" } }; + { "Doing Fixes\0" }, { "Good 1SV\0" }, { "Approx. 1SV\0" }, + {"Need Time\0" }, { "Need INIT\0" }, { "PDOP too High\0" }, + { "Bad 1SV\0" }, { "0SV Usable\0" }, { "1SV Usable\0" }, + { "2SV Usable\0" }, { "3SV Usable\0" }, { "No Integrity\0" }, + { "Diff Corr\0" }, { "Overdet Clock\0" }, { "Invalid\0" } }; #endif /* @@ -92,7 +107,7 @@ NOFLAGS /* not used */ }; -int day_of_year P((char *dt)); +int day_of_year (char *dt); /* Extract the clock type from the mode setting */ #define CLK_TYPE(x) ((int)(((x)->ttl) & 0x7F)) @@ -100,49 +115,170 @@ /* Supported clock types */ #define CLK_TRIMBLE 0 /* Trimble Palisade */ #define CLK_PRAECIS 1 /* Endrun Technologies Praecis */ +#define CLK_THUNDERBOLT 2 /* Trimble Thunderbolt GPS Receiver */ +#define CLK_ACUTIME 3 /* Trimble Acutime Gold */ +#define CLK_ACUTIMEB 4 /* Trimble Actutime Gold Port B */ int praecis_msg; static void praecis_parse(struct recvbuf *rbufp, struct peer *peer); +/* These routines are for sending packets to the Thunderbolt receiver + * They are taken from Markus Prosch + */ + +#ifdef PALISADE_SENDCMD_RESURRECTED +/* + * sendcmd - Build data packet for sending + */ +static void +sendcmd ( + struct packettx *buffer, + int c + ) +{ + *buffer->data = DLE; + *(buffer->data + 1) = (unsigned char)c; + buffer->size = 2; +} +#endif /* PALISADE_SENDCMD_RESURRECTED */ + +/* + * sendsupercmd - Build super data packet for sending + */ +static void +sendsupercmd ( + struct packettx *buffer, + int c1, + int c2 + ) +{ + *buffer->data = DLE; + *(buffer->data + 1) = (unsigned char)c1; + *(buffer->data + 2) = (unsigned char)c2; + buffer->size = 3; +} + +/* + * sendbyte - + */ +static void +sendbyte ( + struct packettx *buffer, + int b + ) +{ + if (b == DLE) + *(buffer->data+buffer->size++) = DLE; + *(buffer->data+buffer->size++) = (unsigned char)b; +} + +/* + * sendint - + */ +static void +sendint ( + struct packettx *buffer, + int a + ) +{ + sendbyte(buffer, (unsigned char)((a>>8) & 0xff)); + sendbyte(buffer, (unsigned char)(a & 0xff)); +} + +/* + * sendetx - Send packet or super packet to the device + */ +static int +sendetx ( + struct packettx *buffer, + int fd + ) +{ + int result; + + *(buffer->data+buffer->size++) = DLE; + *(buffer->data+buffer->size++) = ETX; + result = write(fd, buffer->data, (unsigned long)buffer->size); + + if (result != -1) + return (result); + else + return (-1); +} + +/* + * init_thunderbolt - Prepares Thunderbolt receiver to be used with + * NTP (also taken from Markus Prosch). + */ +static void +init_thunderbolt ( + int fd + ) +{ + struct packettx tx; + + tx.size = 0; + tx.data = (u_char *) malloc(100); + + /* set UTC time */ + sendsupercmd (&tx, 0x8E, 0xA2); + sendbyte (&tx, 0x3); + sendetx (&tx, fd); + + /* activate packets 0x8F-AB and 0x8F-AC */ + sendsupercmd (&tx, 0x8F, 0xA5); + sendint (&tx, 0x5); + sendetx (&tx, fd); + + free(tx.data); +} + +/* + * init_acutime - Prepares Acutime Receiver to be used with NTP + */ +static void +init_acutime ( + int fd + ) +{ + /* Disable all outputs, Enable Event-Polling on PortA so + we can ask for time packets */ + struct packettx tx; + + tx.size = 0; + tx.data = (u_char *) malloc(100); + + sendsupercmd(&tx, 0x8E, 0xA5); + sendbyte(&tx, 0x02); + sendbyte(&tx, 0x00); + sendbyte(&tx, 0x00); + sendbyte(&tx, 0x00); + sendetx(&tx, fd); + + free(tx.data); +} + /* * palisade_start - open the devices and initialize data for processing */ static int palisade_start ( -#ifdef PALISADE - unit, peer - ) - int unit; - struct peer *peer; -#else /* ANSI */ int unit, struct peer *peer ) -#endif { struct palisade_unit *up; struct refclockproc *pp; int fd; char gpsdev[20]; - struct termios tio; -#ifdef SYS_WINNT - (void) sprintf(gpsdev, "COM%d:", unit); -#else - (void) sprintf(gpsdev, DEVICE, unit); -#endif + + snprintf(gpsdev, sizeof(gpsdev), DEVICE, unit); + /* * Open serial port. */ -#if defined PALISADE - fd = open(gpsdev, O_RDWR -#ifdef O_NONBLOCK - | O_NONBLOCK -#endif - ); -#else /* NTP 4.x */ fd = refclock_open(gpsdev, SPEED232, LDISC_RAW); -#endif if (fd <= 0) { #ifdef DEBUG printf("Palisade(%d) start: open %s failed\n", unit, gpsdev); @@ -153,75 +289,56 @@ msyslog(LOG_NOTICE, "Palisade(%d) fd: %d dev: %s", unit, fd, gpsdev); -#if defined PALISADE - tio.c_cflag = (CS8|CLOCAL|CREAD|PARENB|PARODD); - tio.c_iflag = (IGNBRK); - tio.c_oflag = (0); - tio.c_lflag = (0); - - if (cfsetispeed(&tio, SPEED232) == -1) { - msyslog(LOG_ERR,"Palisade(%d) cfsetispeed(fd, &tio): %m",unit); -#ifdef DEBUG - printf("Palisade(%d) cfsetispeed(fd, &tio)\n",unit); -#endif - return 0; - } - if (cfsetospeed(&tio, SPEED232) == -1) { -#ifdef DEBUG - printf("Palisade(%d) cfsetospeed(fd, &tio)\n",unit); -#endif - msyslog(LOG_ERR,"Palisade(%d) cfsetospeed(fd, &tio): %m",unit); - return 0; - } -#else /* NTP 4.x */ - if (tcgetattr(fd, &tio) < 0) { - msyslog(LOG_ERR, + if (tcgetattr(fd, &tio) < 0) { + msyslog(LOG_ERR, "Palisade(%d) tcgetattr(fd, &tio): %m",unit); #ifdef DEBUG - printf("Palisade(%d) tcgetattr(fd, &tio)\n",unit); + printf("Palisade(%d) tcgetattr(fd, &tio)\n",unit); #endif - return (0); - } + close(fd); + return (0); + } - tio.c_cflag |= (PARENB|PARODD); - tio.c_iflag &= ~ICRNL; -#endif /* NTP 4.x */ - - if (tcsetattr(fd, TCSANOW, &tio) == -1) { - msyslog(LOG_ERR, "Palisade(%d) tcsetattr(fd, &tio): %m",unit); -#ifdef DEBUG - printf("Palisade(%d) tcsetattr(fd, &tio)\n",unit); -#endif - return 0; - } + tio.c_cflag |= (PARENB|PARODD); + tio.c_iflag &= ~ICRNL; /* * Allocate and initialize unit structure */ up = (struct palisade_unit *) emalloc(sizeof(struct palisade_unit)); - - if (!(up)) { - msyslog(LOG_ERR, "Palisade(%d) emalloc: %m",unit); -#ifdef DEBUG - printf("Palisade(%d) emalloc\n",unit); -#endif - (void) close(fd); - return (0); - } memset((char *)up, 0, sizeof(struct palisade_unit)); up->type = CLK_TYPE(peer); switch (up->type) { - case CLK_TRIMBLE: - /* Normal mode, do nothing */ - break; - case CLK_PRAECIS: - msyslog(LOG_NOTICE, "Palisade(%d) Praecis mode enabled\n",unit); - break; - default: - msyslog(LOG_NOTICE, "Palisade(%d) mode unknown\n",unit); - break; + case CLK_TRIMBLE: + /* Normal mode, do nothing */ + break; + case CLK_PRAECIS: + msyslog(LOG_NOTICE, "Palisade(%d) Praecis mode enabled\n" + ,unit); + break; + case CLK_THUNDERBOLT: + msyslog(LOG_NOTICE, "Palisade(%d) Thunderbolt mode enabled\n" + ,unit); + tio.c_cflag = (CS8|CLOCAL|CREAD); + break; + case CLK_ACUTIME: + msyslog(LOG_NOTICE, "Palisade(%d) Acutime Gold mode enabled\n" + ,unit); + break; + default: + msyslog(LOG_NOTICE, "Palisade(%d) mode unknown\n",unit); + break; + } + if (tcsetattr(fd, TCSANOW, &tio) == -1) { + msyslog(LOG_ERR, "Palisade(%d) tcsetattr(fd, &tio): %m",unit); +#ifdef DEBUG + printf("Palisade(%d) tcsetattr(fd, &tio)\n",unit); +#endif + close(fd); + free(up); + return 0; } pp = peer->procptr; @@ -231,9 +348,10 @@ pp->io.fd = fd; if (!io_addclock(&pp->io)) { #ifdef DEBUG - printf("Palisade(%d) io_addclock\n",unit); + printf("Palisade(%d) io_addclock\n",unit); #endif - (void) close(fd); + close(fd); + pp->io.fd = -1; free(up); return (0); } @@ -253,7 +371,12 @@ up->leap_status = 0; up->unit = (short) unit; up->rpt_status = TSIP_PARSED_EMPTY; - up->rpt_cnt = 0; + up->rpt_cnt = 0; + + if (up->type == CLK_THUNDERBOLT) + init_thunderbolt(fd); + if (up->type == CLK_ACUTIME) + init_acutime(fd); return 1; } @@ -264,23 +387,18 @@ */ static void palisade_shutdown ( -#ifdef PALISADE - unit, peer - ) - int unit; - struct peer *peer; -#else /* ANSI */ int unit, struct peer *peer ) -#endif { struct palisade_unit *up; struct refclockproc *pp; pp = peer->procptr; up = (struct palisade_unit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } @@ -290,29 +408,23 @@ */ int day_of_year ( -#ifdef PALISADE - dt - ) - char * dt; -#else char * dt ) -#endif { int day, mon, year; mon = dt[1]; - /* Check month is inside array bounds */ - if ((mon < 1) || (mon > 12)) + /* Check month is inside array bounds */ + if ((mon < 1) || (mon > 12)) return -1; day = dt[0] + days_of_year[mon - 1]; year = getint((u_char *) (dt + 2)); if ( !(year % 4) && ((year % 100) || - (!(year % 100) && !(year%400))) - &&(mon > 2)) - day ++; /* leap year and March or later */ + (!(year % 100) && !(year%400))) + &&(mon > 2)) + day ++; /* leap year and March or later */ return day; } @@ -323,14 +435,8 @@ */ int TSIP_decode ( -#ifdef PALISADE - peer - ) - struct peer *peer; -#else struct peer *peer ) -#endif { int st; long secint; @@ -350,182 +456,430 @@ * proper format, declare bad format and exit. */ - if ((up->rpt_buf[0] == (char) 0x41) || - (up->rpt_buf[0] == (char) 0x46) || - (up->rpt_buf[0] == (char) 0x54) || - (up->rpt_buf[0] == (char) 0x4B) || - (up->rpt_buf[0] == (char) 0x6D)) { + if ((up->type != CLK_THUNDERBOLT) & (up->type != CLK_ACUTIME)){ + if ((up->rpt_buf[0] == (char) 0x41) || + (up->rpt_buf[0] == (char) 0x46) || + (up->rpt_buf[0] == (char) 0x54) || + (up->rpt_buf[0] == (char) 0x4B) || + (up->rpt_buf[0] == (char) 0x6D)) { - /* standard time packet - GPS time and GPS week number */ + /* standard time packet - GPS time and GPS week number */ #ifdef DEBUG printf("Palisade Port B packets detected. Connect to Port A\n"); #endif - return 0; + return 0; + } } /* * We cast both to u_char to as 0x8f uses the sign bit on a char */ if ((u_char) up->rpt_buf[0] == (u_char) 0x8f) { - /* - * Superpackets - */ - event = (unsigned short) (getint((u_char *) &mb(1)) & 0xffff); - if (!((pp->sloppyclockflag & CLK_FLAG2) || event)) - /* Ignore Packet */ + /* + * Superpackets + */ + event = (unsigned short) (getint((u_char *) &mb(1)) & 0xffff); + if (!((pp->sloppyclockflag & CLK_FLAG2) || event)) + /* Ignore Packet */ return 0; - switch (mb(0) & 0xff) { - int GPS_UTC_Offset; - case PACKET_8F0B: + switch (mb(0) & 0xff) { + int GPS_UTC_Offset; + long tow; - if (up->polled <= 0) - return 0; + case PACKET_8F0B: - if (up->rpt_cnt != LENCODE_8F0B) /* check length */ - break; + if (up->polled <= 0) + return 0; + + if (up->rpt_cnt != LENCODE_8F0B) /* check length */ + break; #ifdef DEBUG -if (debug > 1) { - int ts; - double lat, lon, alt; - lat = getdbl((u_char *) &mb(42)) * R2D; - lon = getdbl((u_char *) &mb(50)) * R2D; - alt = getdbl((u_char *) &mb(58)); - - printf("TSIP_decode: unit %d: Latitude: %03.4f Longitude: %03.4f Alt: %05.2f m\n", - up->unit, lat,lon,alt); - printf("TSIP_decode: unit %d: Sats:", up->unit); - for (st = 66, ts = 0; st <= 73; st++) if (mb(st)) { - if (mb(st) > 0) ts++; - printf(" %02d", mb(st)); - } - printf(" : Tracking %d\n", ts); - } + if (debug > 1) { + int ts; + double lat, lon, alt; + lat = getdbl((u_char *) &mb(42)) * R2D; + lon = getdbl((u_char *) &mb(50)) * R2D; + alt = getdbl((u_char *) &mb(58)); + + printf("TSIP_decode: unit %d: Latitude: %03.4f Longitude: %03.4f Alt: %05.2f m\n", + up->unit, lat,lon,alt); + printf("TSIP_decode: unit %d: Sats:", + up->unit); + for (st = 66, ts = 0; st <= 73; st++) + if (mb(st)) { + if (mb(st) > 0) ts++; + printf(" %02d", mb(st)); + } + printf(" : Tracking %d\n", ts); + } #endif - GPS_UTC_Offset = getint((u_char *) &mb(16)); - if (GPS_UTC_Offset == 0) { /* Check UTC offset */ + GPS_UTC_Offset = getint((u_char *) &mb(16)); + if (GPS_UTC_Offset == 0) { /* Check UTC offset */ #ifdef DEBUG - printf("TSIP_decode: UTC Offset Unknown\n"); + printf("TSIP_decode: UTC Offset Unknown\n"); #endif - break; - } + break; + } - secs = getdbl((u_char *) &mb(3)); - secint = (long) secs; - secfrac = secs - secint; /* 0.0 <= secfrac < 1.0 */ - - pp->nsec = (long) (secfrac * 1000000000); - - secint %= 86400; /* Only care about today */ - pp->hour = secint / 3600; - secint %= 3600; - pp->minute = secint / 60; - secint %= 60; - pp->second = secint % 60; + secs = getdbl((u_char *) &mb(3)); + secint = (long) secs; + secfrac = secs - secint; /* 0.0 <= secfrac < 1.0 */ + + pp->nsec = (long) (secfrac * 1000000000); + + secint %= 86400; /* Only care about today */ + pp->hour = secint / 3600; + secint %= 3600; + pp->minute = secint / 60; + secint %= 60; + pp->second = secint % 60; - if ((pp->day = day_of_year(&mb(11))) < 0) break; + if ((pp->day = day_of_year(&mb(11))) < 0) break; - pp->year = getint((u_char *) &mb(13)); + pp->year = getint((u_char *) &mb(13)); #ifdef DEBUG - if (debug > 1) - printf("TSIP_decode: unit %d: %02X #%d %02d:%02d:%02d.%06ld %02d/%02d/%04d UTC %02d\n", - up->unit, mb(0) & 0xff, event, pp->hour, pp->minute, - pp->second, pp->nsec, mb(12), mb(11), pp->year, GPS_UTC_Offset); + if (debug > 1) + printf("TSIP_decode: unit %d: %02X #%d %02d:%02d:%02d.%06ld %02d/%02d/%04d UTC %02d\n", + up->unit, mb(0) & 0xff, event, pp->hour, pp->minute, + pp->second, pp->nsec, mb(12), mb(11), pp->year, GPS_UTC_Offset); #endif - /* Only use this packet when no - * 8F-AD's are being received - */ + /* Only use this packet when no + * 8F-AD's are being received + */ - if (up->leap_status) { - up->leap_status = 0; - return 0; - } + if (up->leap_status) { + up->leap_status = 0; + return 0; + } - return 2; - break; + return 2; + break; - case PACKET_NTP: - /* Palisade-NTP Packet */ + case PACKET_NTP: + /* Palisade-NTP Packet */ - if (up->rpt_cnt != LENCODE_NTP) /* check length */ - break; + if (up->rpt_cnt != LENCODE_NTP) /* check length */ + break; - up->leap_status = mb(19); + up->leap_status = mb(19); - if (up->polled <= 0) - return 0; + if (up->polled <= 0) + return 0; - /* Check Tracking Status */ - st = mb(18); - if (st < 0 || st > 14) st = 14; - if ((st >= 2 && st <= 7) || st == 11 || st == 12) { + /* Check Tracking Status */ + st = mb(18); + if (st < 0 || st > 14) + st = 14; + if ((st >= 2 && st <= 7) || st == 11 || st == 12) { +#ifdef DEBUG + printf("TSIP_decode: Not Tracking Sats : %s\n", + *Tracking_Status[st]); +#endif + refclock_report(peer, CEVNT_BADTIME); + up->polled = -1; + return 0; + break; + } + + if (up->leap_status & PALISADE_LEAP_PENDING) { + if (up->leap_status & PALISADE_UTC_TIME) + pp->leap = LEAP_ADDSECOND; + else + pp->leap = LEAP_DELSECOND; + } + else if (up->leap_status) + pp->leap = LEAP_NOWARNING; + + else { /* UTC flag is not set: + * Receiver may have been reset, and lost + * its UTC almanac data */ + pp->leap = LEAP_NOTINSYNC; +#ifdef DEBUG + printf("TSIP_decode: UTC Almanac unavailable: %d\n", + mb(19)); +#endif + refclock_report(peer, CEVNT_BADTIME); + up->polled = -1; + return 0; + } + + pp->nsec = (long) (getdbl((u_char *) &mb(3)) + * 1000000000); + + if ((pp->day = day_of_year(&mb(14))) < 0) + break; + pp->year = getint((u_char *) &mb(16)); + pp->hour = mb(11); + pp->minute = mb(12); + pp->second = mb(13); + #ifdef DEBUG - printf("TSIP_decode: Not Tracking Sats : %s\n", - *Tracking_Status[st]); + if (debug > 1) + printf("TSIP_decode: unit %d: %02X #%d %02d:%02d:%02d.%06ld %02d/%02d/%04d UTC %02x %s\n", + up->unit, mb(0) & 0xff, event, pp->hour, pp->minute, + pp->second, pp->nsec, mb(15), mb(14), pp->year, + mb(19), *Tracking_Status[st]); #endif - refclock_report(peer, CEVNT_BADTIME); - up->polled = -1; - return 0; + return 1; break; - } - if (up->leap_status & PALISADE_LEAP_PENDING) { - if (up->leap_status & PALISADE_UTC_TIME) - pp->leap = LEAP_ADDSECOND; - else - pp->leap = LEAP_DELSECOND; - } - else if (up->leap_status) - pp->leap = LEAP_NOWARNING; - - else { /* UTC flag is not set: - * Receiver may have been reset, and lost - * its UTC almanac data */ - pp->leap = LEAP_NOTINSYNC; + case PACKET_8FAC: + if (up->polled <= 0) + return 0; + + if (up->rpt_cnt != LENCODE_8FAC)/* check length */ + break; + #ifdef DEBUG - printf("TSIP_decode: UTC Almanac unavailable: %d\n", - mb(19)); + if (debug > 1) { + double lat, lon, alt; + lat = getdbl((u_char *) &mb(36)) * R2D; + lon = getdbl((u_char *) &mb(44)) * R2D; + alt = getdbl((u_char *) &mb(52)); + + printf("TSIP_decode: unit %d: Latitude: %03.4f Longitude: %03.4f Alt: %05.2f m\n", + up->unit, lat,lon,alt); + printf("TSIP_decode: unit %d\n", up->unit); + } #endif - refclock_report(peer, CEVNT_BADTIME); - up->polled = -1; + if (getint((u_char *) &mb(10)) & 0x80) + pp->leap = LEAP_ADDSECOND; /* we ASSUME addsecond */ + else + pp->leap = LEAP_NOWARNING; + +#ifdef DEBUG + if (debug > 1) + printf("TSIP_decode: unit %d: 0x%02x leap %d\n", + up->unit, mb(0) & 0xff, pp->leap); + if (debug > 1) { + printf("Receiver MODE: 0x%02X\n", (u_char)mb(1)); + if (mb(1) == 0x00) + printf(" AUTOMATIC\n"); + if (mb(1) == 0x01) + printf(" SINGLE SATELLITE\n"); + if (mb(1) == 0x03) + printf(" HORIZONTAL(2D)\n"); + if (mb(1) == 0x04) + printf(" FULL POSITION(3D)\n"); + if (mb(1) == 0x05) + printf(" DGPR REFERENCE\n"); + if (mb(1) == 0x06) + printf(" CLOCK HOLD(2D)\n"); + if (mb(1) == 0x07) + printf(" OVERDETERMINED CLOCK\n"); + + printf("\n** Disciplining MODE 0x%02X:\n", (u_char)mb(2)); + if (mb(2) == 0x00) + printf(" NORMAL\n"); + if (mb(2) == 0x01) + printf(" POWER-UP\n"); + if (mb(2) == 0x02) + printf(" AUTO HOLDOVER\n"); + if (mb(2) == 0x03) + printf(" MANUAL HOLDOVER\n"); + if (mb(2) == 0x04) + printf(" RECOVERY\n"); + if (mb(2) == 0x06) + printf(" DISCIPLINING DISABLED\n"); + } +#endif return 0; - } + break; - pp->nsec = (long) (getdbl((u_char *) &mb(3)) * 1000000000); + case PACKET_8FAB: + /* Thunderbolt Primary Timing Packet */ - if ((pp->day = day_of_year(&mb(14))) < 0) + if (up->rpt_cnt != LENCODE_8FAB) /* check length */ + break; + + if (up->polled <= 0) + return 0; + + GPS_UTC_Offset = getint((u_char *) &mb(7)); + + if (GPS_UTC_Offset == 0){ /* Check UTC Offset */ +#ifdef DEBUG + printf("TSIP_decode: UTC Offset Unknown\n"); +#endif + break; + } + + + if ((mb(9) & 0x1d) == 0x0) { + /* if we know the GPS time and the UTC offset, + we expect UTC timing information !!! */ + + pp->leap = LEAP_NOTINSYNC; + refclock_report(peer, CEVNT_BADTIME); + up->polled = -1; + return 0; + } + + pp->nsec = 0; +#ifdef DEBUG + printf("\nTiming Flags are:\n"); + printf("Timing flag value is: 0x%X\n", mb(9)); + if ((mb(9) & 0x01) != 0) + printf (" Getting UTC time\n"); + else + printf (" Getting GPS time\n"); + if ((mb(9) & 0x02) != 0) + printf (" PPS is from UTC\n"); + else + printf (" PPS is from GPS\n"); + if ((mb(9) & 0x04) != 0) + printf (" Time is not Set\n"); + else + printf (" Time is Set\n"); + if ((mb(9) & 0x08) != 0) + printf(" I dont have UTC info\n"); + else + printf (" I have UTC info\n"); + if ((mb(9) & 0x10) != 0) + printf (" Time is from USER\n\n"); + else + printf (" Time is from GPS\n\n"); +#endif + + if ((pp->day = day_of_year(&mb(13))) < 0) + break; + tow = getlong((u_char *) &mb(1)); +#ifdef DEBUG + if (debug > 1) { + printf("pp->day: %d\n", pp->day); + printf("TOW: %ld\n", tow); + printf("DAY: %d\n", mb(13)); + } +#endif + pp->year = getint((u_char *) &mb(15)); + pp->hour = mb(12); + pp->minute = mb(11); + pp->second = mb(10); + + +#ifdef DEBUG + if (debug > 1) + printf("TSIP_decode: unit %d: %02X #%d %02d:%02d:%02d.%06ld %02d/%02d/%04d ",up->unit, mb(0) & 0xff, event, pp->hour, pp->minute, pp->second, pp->nsec, mb(14), mb(13), pp->year); +#endif + return 1; break; - pp->year = getint((u_char *) &mb(16)); - pp->hour = mb(11); - pp->minute = mb(12); - pp->second = mb(13); + default: + /* Ignore Packet */ + return 0; + } /* switch */ + } /* if 8F packets */ + + else if (up->rpt_buf[0] == (u_char)0x42) { + printf("0x42\n"); + return 0; + } + else if (up->rpt_buf[0] == (u_char)0x43) { + printf("0x43\n"); + return 0; + } + else if ((up->rpt_buf[0] == PACKET_41) & (up->type == CLK_THUNDERBOLT)){ + printf("Undocumented 0x41 packet on Thunderbolt\n"); + return 0; + } + else if ((up->rpt_buf[0] == PACKET_41A) & (up->type == CLK_ACUTIME)) { #ifdef DEBUG - if (debug > 1) -printf("TSIP_decode: unit %d: %02X #%d %02d:%02d:%02d.%06ld %02d/%02d/%04d UTC %02x %s\n", - up->unit, mb(0) & 0xff, event, pp->hour, pp->minute, - pp->second, pp->nsec, mb(15), mb(14), pp->year, - mb(19), *Tracking_Status[st]); + printf("GPS TOW: %ld\n", getlong((u_char *) &mb(0))); + printf("GPS WN: %d\n", getint((u_char *) &mb(4))); + printf("GPS UTC-GPS Offser: %ld\n", getlong((u_char *) &mb(6))); #endif - return 1; - break; + return 0; + } - default: - /* Ignore Packet */ + /* Health Status for Acutime Receiver */ + else if ((up->rpt_buf[0] == PACKET_46) & (up->type == CLK_ACUTIME)) { +#ifdef DEBUG + if (debug > 1) + /* Status Codes */ + switch (mb(0)) { + case 0x00: + printf ("Doing Position Fixes\n"); + break; + case 0x01: + printf ("Do no have GPS time yet\n"); + break; + case 0x03: + printf ("PDOP is too high\n"); + break; + case 0x08: + printf ("No usable satellites\n"); + break; + case 0x09: + printf ("Only 1 usable satellite\n"); + break; + case 0x0A: + printf ("Only 2 usable satellites\n"); + break; + case 0x0B: + printf ("Only 3 usable satellites\n"); + break; + case 0x0C: + printf("The Chosen satellite is unusable\n"); + break; + } +#endif + /* Error Codes */ + if (mb(1) != 0) { + + refclock_report(peer, CEVNT_BADTIME); + up->polled = -1; +#ifdef DEBUG + if (debug > 1) { + if (mb(1) && 0x01) + printf ("Signal Processor Error, reset unit.\n"); + if (mb(1) && 0x02) + printf ("Alignment error, channel or chip 1, reset unit.\n"); + if (mb(1) && 0x03) + printf ("Alignment error, channel or chip 2, reset unit.\n"); + if (mb(1) && 0x04) + printf ("Antenna feed line fault (open or short)\n"); + if (mb(1) && 0x05) + printf ("Excessive reference frequency error, refer to packet 0x2D and packet 0x4D documentation for further information\n"); + } +#endif + return 0; - } /* switch */ - }/* if 8F packets */ + } + } + else if (up->rpt_buf[0] == 0x54) + return 0; + + else if (up->rpt_buf[0] == PACKET_6D) { +#ifdef DEBUG + int sats; + if ((mb(0) & 0x01) && (mb(0) & 0x02)) + printf("2d Fix Dimension\n"); + if (mb(0) & 0x04) + printf("3d Fix Dimension\n"); + + if (mb(0) & 0x08) + printf("Fix Mode is MANUAL\n"); + else + printf("Fix Mode is AUTO\n"); + + sats = mb(0) & 0xF0; + sats = sats >> 4; + printf("Tracking %d Satellites\n", sats); +#endif + return 0; + } /* else if not super packet */ refclock_report(peer, CEVNT_BADREPLY); up->polled = -1; #ifdef DEBUG printf("TSIP_decode: unit %d: bad packet %02x-%02x event %d len %d\n", - up->unit, up->rpt_buf[0] & 0xff, mb(0) & 0xff, - event, up->rpt_cnt); + up->unit, up->rpt_buf[0] & 0xff, mb(0) & 0xff, + event, up->rpt_cnt); #endif return 0; } @@ -536,14 +890,8 @@ static void palisade_receive ( -#ifdef PALISADE - peer - ) - struct peer * peer; -#else /* ANSI */ struct peer * peer ) -#endif { struct palisade_unit *up; struct refclockproc *pp; @@ -557,14 +905,14 @@ if (! TSIP_decode(peer)) return; if (up->polled <= 0) - return; /* no poll pending, already received or timeout */ + return; /* no poll pending, already received or timeout */ up->polled = 0; /* Poll reply received */ pp->lencode = 0; /* clear time code */ #ifdef DEBUG if (debug) printf( - "palisade_receive: unit %d: %4d %03d %02d:%02d:%02d.%06ld\n", + "palisade_receive: unit %d: %4d %03d %02d:%02d:%02d.%06ld\n", up->unit, pp->year, pp->day, pp->hour, pp->minute, pp->second, pp->nsec); #endif @@ -575,23 +923,18 @@ * report and process */ - (void) sprintf(pp->a_lastcode,"%4d %03d %02d:%02d:%02d.%06ld", - pp->year,pp->day,pp->hour,pp->minute, pp->second,pp->nsec); + snprintf(pp->a_lastcode, sizeof(pp->a_lastcode), + "%4d %03d %02d:%02d:%02d.%06ld", + pp->year, pp->day, + pp->hour,pp->minute, pp->second, pp->nsec); pp->lencode = 24; -#ifdef PALISADE - pp->lasttime = current_time; -#endif - if (!refclock_process(pp -#ifdef PALISADE - , PALISADE_SAMPLES, PALISADE_SAMPLES * 3 / 5 -#endif - )) { + if (!refclock_process(pp)) { refclock_report(peer, CEVNT_BADTIME); #ifdef DEBUG printf("palisade_receive: unit %d: refclock_process failed!\n", - up->unit); + up->unit); #endif return; } @@ -600,16 +943,11 @@ #ifdef DEBUG if (debug) - printf("palisade_receive: unit %d: %s\n", - up->unit, prettydate(&pp->lastrec)); + printf("palisade_receive: unit %d: %s\n", + up->unit, prettydate(&pp->lastrec)); #endif pp->lastref = pp->lastrec; - refclock_receive(peer -#ifdef PALISADE - , &pp->offset, 0, pp->dispersion, - &pp->lastrec, &pp->lastrec, pp->leap -#endif - ); + refclock_receive(peer); } @@ -619,16 +957,9 @@ */ static void palisade_poll ( -#ifdef PALISADE - unit, peer - ) - int unit; - struct peer *peer; -#else int unit, struct peer *peer ) -#endif { struct palisade_unit *up; struct refclockproc *pp; @@ -638,19 +969,19 @@ pp->polls++; if (up->polled > 0) /* last reply never arrived or error */ - refclock_report(peer, CEVNT_TIMEOUT); + refclock_report(peer, CEVNT_TIMEOUT); up->polled = 2; /* synchronous packet + 1 event */ #ifdef DEBUG if (debug) - printf("palisade_poll: unit %d: polling %s\n", unit, - (pp->sloppyclockflag & CLK_FLAG2) ? - "synchronous packet" : "event"); + printf("palisade_poll: unit %d: polling %s\n", unit, + (pp->sloppyclockflag & CLK_FLAG2) ? + "synchronous packet" : "event"); #endif if (pp->sloppyclockflag & CLK_FLAG2) - return; /* using synchronous packet input */ + return; /* using synchronous packet input */ if(up->type == CLK_PRAECIS) { if(write(peer->procptr->io.fd,"SPSTAT\r\n",8) < 0) @@ -662,11 +993,14 @@ } if (HW_poll(pp) < 0) - refclock_report(peer, CEVNT_FAULT); + refclock_report(peer, CEVNT_FAULT); } static void -praecis_parse(struct recvbuf *rbufp, struct peer *peer) +praecis_parse ( + struct recvbuf *rbufp, + struct peer *peer + ) { static char buf[100]; static int p = 0; @@ -692,14 +1026,8 @@ static void palisade_io ( -#ifdef PALISADE - rbufp - ) - struct recvbuf *rbufp; -#else /* ANSI */ struct recvbuf *rbufp ) -#endif { /* * Initialize pointers and read the timecode and timestamp. @@ -748,21 +1076,21 @@ case TSIP_PARSED_DATA: if (*c == DLE) - up->rpt_status = TSIP_PARSED_DLE_2; + up->rpt_status = TSIP_PARSED_DLE_2; else - mb(up->rpt_cnt++) = *c; + mb(up->rpt_cnt++) = *c; break; case TSIP_PARSED_DLE_2: if (*c == DLE) { up->rpt_status = TSIP_PARSED_DATA; mb(up->rpt_cnt++) = - *c; - } + *c; + } else if (*c == ETX) - up->rpt_status = TSIP_PARSED_FULL; + up->rpt_status = TSIP_PARSED_FULL; else { - /* error: start new report packet */ + /* error: start new report packet */ up->rpt_status = TSIP_PARSED_DLE_1; up->rpt_buf[0] = *c; } @@ -771,23 +1099,23 @@ case TSIP_PARSED_FULL: case TSIP_PARSED_EMPTY: default: - if ( *c != DLE) - up->rpt_status = TSIP_PARSED_EMPTY; - else - up->rpt_status = TSIP_PARSED_DLE_1; - break; + if ( *c != DLE) + up->rpt_status = TSIP_PARSED_EMPTY; + else + up->rpt_status = TSIP_PARSED_DLE_1; + break; } c++; if (up->rpt_status == TSIP_PARSED_DLE_1) { - up->rpt_cnt = 0; + up->rpt_cnt = 0; if (pp->sloppyclockflag & CLK_FLAG2) - /* stamp it */ - get_systime(&pp->lastrec); + /* stamp it */ + get_systime(&pp->lastrec); } else if (up->rpt_status == TSIP_PARSED_EMPTY) - up->rpt_cnt = 0; + up->rpt_cnt = 0; else if (up->rpt_cnt > BMAX) up->rpt_status =TSIP_PARSED_EMPTY; @@ -807,14 +1135,8 @@ */ long HW_poll ( -#ifdef PALISADE - pp /* pointer to unit structure */ - ) - struct refclockproc * pp; /* pointer to unit structure */ -#else struct refclockproc * pp /* pointer to unit structure */ ) -#endif { int x; /* state before & after RTS set */ struct palisade_unit *up; @@ -824,8 +1146,8 @@ /* read the current status, so we put things back right */ if (ioctl(pp->io.fd, TIOCMGET, &x) < 0) { #ifdef DEBUG - if (debug) - printf("Palisade HW_poll: unit %d: GET %s\n", up->unit, strerror(errno)); + if (debug) + printf("Palisade HW_poll: unit %d: GET %s\n", up->unit, strerror(errno)); #endif msyslog(LOG_ERR, "Palisade(%d) HW_poll: ioctl(fd,GET): %m", up->unit); @@ -835,10 +1157,13 @@ x |= TIOCM_RTS; /* turn on RTS */ /* Edge trigger */ + if (up->type == CLK_ACUTIME) + write (pp->io.fd, "", 1); + if (ioctl(pp->io.fd, TIOCMSET, &x) < 0) { #ifdef DEBUG - if (debug) - printf("Palisade HW_poll: unit %d: SET \n", up->unit); + if (debug) + printf("Palisade HW_poll: unit %d: SET \n", up->unit); #endif msyslog(LOG_ERR, "Palisade(%d) HW_poll: ioctl(fd, SET, RTS_on): %m", @@ -853,8 +1178,8 @@ if (ioctl(pp->io.fd, TIOCMSET, &x) == -1) { #ifdef DEBUG - if (debug) - printf("Palisade HW_poll: unit %d: UNSET \n", up->unit); + if (debug) + printf("Palisade HW_poll: unit %d: UNSET \n", up->unit); #endif msyslog(LOG_ERR, "Palisade(%d) HW_poll: ioctl(fd, UNSET, RTS_off): %m", @@ -871,14 +1196,8 @@ */ float getfloat ( -#ifdef PALISADE - bp - ) - u_char *bp; -#else u_char *bp ) -#endif { float sval; #ifdef WORDS_BIGENDIAN @@ -901,14 +1220,8 @@ */ double getdbl ( -#ifdef PALISADE - bp - ) - u_char *bp; -#else u_char *bp ) -#endif { double dval; #ifdef WORDS_BIGENDIAN @@ -938,18 +1251,25 @@ */ short getint ( -#ifdef PALISADE - bp + u_char *bp ) - u_char *bp; -#else +{ + return (short) (bp[1] + (bp[0] << 8)); +} + +/* + * cast a 32 bit character array into a long (32 bit) int + */ +long +getlong( u_char *bp ) -#endif { -return (short) (bp[1] + (bp[0] << 8)); + return (long) (bp[0] << 24) | + (bp[1] << 16) | + (bp[2] << 8) | + bp[3]; } -#else int refclock_palisade_bs; #endif /* REFCLOCK */ diff -urN src/contrib/ntp/ntpd/refclock_palisade.h src.ntp/contrib/ntp/ntpd/refclock_palisade.h --- src/contrib/ntp/ntpd/refclock_palisade.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_palisade.h 2009-12-09 08:36:35.000000000 +0100 @@ -71,6 +71,7 @@ # define _SVID3 # endif # include +# include # ifdef TERMIOS_NEEDS__SVID3 # undef _SVID3 # endif @@ -108,10 +109,23 @@ #define LENCODE_8F0B 74 /* Length of TSIP 8F-0B Packet & header */ #define LENCODE_NTP 22 /* Length of Palisade NTP Packet */ +#define LENCODE_8FAC 68 /* Length of Thunderbolt 8F-AC Position Packet*/ +#define LENCODE_8FAB 17 /* Length of Thunderbolt Primary Timing Packet*/ + /* Allowed Sub-Packet ID's */ #define PACKET_8F0B 0x0B #define PACKET_NTP 0xAD +/* Thunderbolt Packets */ +#define PACKET_8FAC 0xAC /* Supplementary Thunderbolt Time Packet */ +#define PACKET_8FAB 0xAB /* Primary Thunderbolt Time Packet */ +#define PACKET_6D 0x6D /* Supplementary Thunderbolt Tracking Stats */ +#define PACKET_41 0x41 /* Thunderbolt I dont know what this packet is, it's not documented on my manual*/ + +/* Acutime Packets */ +#define PACKET_41A 0x41 /* GPS time */ +#define PACKET_46 0x46 /* Receiver Health */ + #define DLE 0x10 #define ETX 0x03 @@ -139,6 +153,16 @@ #define R2D (180.0/GPS_PI) /* + * Structure for build data packets for send (thunderbolt uses it only) + * taken from Markus Prosch + */ +struct packettx +{ + short size; + u_char *data; +}; + +/* * Palisade unit control structure. */ struct palisade_unit { @@ -147,7 +171,7 @@ char leap_status; /* leap second flag */ char rpt_status; /* TSIP Parser State */ short rpt_cnt; /* TSIP packet length so far */ - char rpt_buf[BMAX]; /* packet assembly buffer */ + char rpt_buf[BMAX]; /* packet assembly buffer */ int type; /* Clock mode type */ }; @@ -155,16 +179,27 @@ * Function prototypes */ -static int palisade_start P((int, struct peer *)); -static void palisade_shutdown P((int, struct peer *)); -static void palisade_receive P((struct peer *)); -static void palisade_poll P((int, struct peer *)); -static void palisade_io P((struct recvbuf *)); -int palisade_configure P((int, struct peer *)); -int TSIP_decode P((struct peer *)); -long HW_poll P((struct refclockproc *)); -float getfloat P((u_char *)); -double getdbl P((u_char *)); -short getint P((u_char *)); +static int palisade_start (int, struct peer *); +static void palisade_shutdown (int, struct peer *); +static void palisade_receive (struct peer *); +static void palisade_poll (int, struct peer *); +static void palisade_io (struct recvbuf *); +int palisade_configure (int, struct peer *); +int TSIP_decode (struct peer *); +long HW_poll (struct refclockproc *); +float getfloat (u_char *); +double getdbl (u_char *); +short getint (u_char *); +long getlong (u_char *); + +#ifdef PALISADE_SENDCMD_RESURRECTED +static void sendcmd (struct packettx *buffer, int c); +#endif +static void sendsupercmd (struct packettx *buffer, int c1, int c2); +static void sendbyte (struct packettx *buffer, int b); +static void sendint (struct packettx *buffer, int a); +static int sendetx (struct packettx *buffer, int fd); +static void init_thunderbolt (int fd); +static void init_acutime (int fd); #endif /* PALISADE_H */ diff -urN src/contrib/ntp/ntpd/refclock_parse.c src.ntp/contrib/ntp/ntpd/refclock_parse.c --- src/contrib/ntp/ntpd/refclock_parse.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_parse.c 2010-02-04 08:26:53.000000000 +0100 @@ -1,7 +1,7 @@ /* - * /src/NTP/REPOSITORY/ntp4-dev/ntpd/refclock_parse.c,v 4.80 2007/08/11 12:06:29 kardel Exp + * /src/NTP/REPOSITORY/ntp4-dev/ntpd/refclock_parse.c,v 4.81 2009/05/01 10:15:29 kardel RELEASE_20090105_A * - * refclock_parse.c,v 4.80 2007/08/11 12:06:29 kardel Exp + * refclock_parse.c,v 4.81 2009/05/01 10:15:29 kardel RELEASE_20090105_A * * generic reference clock driver for several DCF/GPS/MSF/... receivers * @@ -15,7 +15,7 @@ * 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) 1995-2009 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 @@ -141,6 +141,7 @@ #ifdef HAVE_PPSAPI # include "ppsapi_timepps.h" +# include "refclock_atom.h" #endif #ifdef PPS @@ -188,16 +189,16 @@ #include "ieee754io.h" #include "recvbuff.h" -static char rcsid[] = "refclock_parse.c,v 4.80 2007/08/11 12:06:29 kardel Exp"; +static char rcsid[] = "refclock_parse.c,v 4.81 2009/05/01 10:15:29 kardel RELEASE_20090105_A"; /**=========================================================================== ** external interface to ntp mechanism **/ -static int parse_start P((int, struct peer *)); -static void parse_shutdown P((int, struct peer *)); -static void parse_poll P((int, struct peer *)); -static void parse_control P((int, struct refclockstat *, struct refclockstat *, struct peer *)); +static int parse_start (int, struct peer *); +static void parse_shutdown (int, struct peer *); +static void parse_poll (int, struct peer *); +static void parse_control (int, struct refclockstat *, struct refclockstat *, struct peer *); struct refclock refclock_parse = { parse_start, @@ -231,16 +232,16 @@ typedef struct bind { const char *bd_description; /* name of type of binding */ - int (*bd_init) P((struct parseunit *)); /* initialize */ - void (*bd_end) P((struct parseunit *)); /* end */ - int (*bd_setcs) P((struct parseunit *, parsectl_t *)); /* set character size */ - int (*bd_disable) P((struct parseunit *)); /* disable */ - int (*bd_enable) P((struct parseunit *)); /* enable */ - int (*bd_getfmt) P((struct parseunit *, parsectl_t *)); /* get format */ - int (*bd_setfmt) P((struct parseunit *, parsectl_t *)); /* setfmt */ - int (*bd_timecode) P((struct parseunit *, parsectl_t *)); /* get time code */ - void (*bd_receive) P((struct recvbuf *)); /* receive operation */ - int (*bd_io_input) P((struct recvbuf *)); /* input operation */ + int (*bd_init) (struct parseunit *); /* initialize */ + void (*bd_end) (struct parseunit *); /* end */ + int (*bd_setcs) (struct parseunit *, parsectl_t *); /* set character size */ + int (*bd_disable) (struct parseunit *); /* disable */ + int (*bd_enable) (struct parseunit *); /* enable */ + int (*bd_getfmt) (struct parseunit *, parsectl_t *); /* get format */ + int (*bd_setfmt) (struct parseunit *, parsectl_t *); /* setfmt */ + int (*bd_timecode) (struct parseunit *, parsectl_t *); /* get time code */ + void (*bd_receive) (struct recvbuf *); /* receive operation */ + int (*bd_io_input) (struct recvbuf *); /* input operation */ } bind_t; #define PARSE_END(_X_) (*(_X_)->binding->bd_end)(_X_) @@ -405,9 +406,8 @@ u_long ppsserial; /* magic cookie for ppsclock serials (avoids stale ppsclock data) */ int ppsfd; /* fd to ise for PPS io */ #ifdef HAVE_PPSAPI - pps_handle_t ppshandle; /* store PPSAPI handle */ - pps_params_t ppsparams; /* current PPS parameters */ int hardppsstate; /* current hard pps state */ + struct refclock_atom atom; /* PPSAPI structure */ #endif parsetime_t timedata; /* last (parse module) data */ void *localdata; /* optional local, receiver-specific data */ @@ -423,9 +423,9 @@ ** includes NTP parameters, TTY parameters and IO handling parameters **/ -static void poll_dpoll P((struct parseunit *)); -static void poll_poll P((struct peer *)); -static int poll_init P((struct parseunit *)); +static void poll_dpoll (struct parseunit *); +static void poll_poll (struct peer *); +static int poll_init (struct parseunit *); typedef struct poll_info { @@ -536,8 +536,8 @@ /* * Meinberg GPS16X receiver */ -static void gps16x_message P((struct parseunit *, parsetime_t *)); -static int gps16x_poll_init P((struct parseunit *)); +static void gps16x_message (struct parseunit *, parsetime_t *); +static int gps16x_poll_init (struct parseunit *); #define GPS16X_ROOTDELAY 0.0 /* nothing here */ #define GPS16X_BASEDELAY 0.001968 /* XXX to be fixed ! 1.968ms +- 104us (oscilloscope) - relative to start (end of STX) */ @@ -677,7 +677,7 @@ * RAWDCF receivers that need to be powered from DTR * (like Expert mouse clock) */ -static int rawdcf_init_1 P((struct parseunit *)); +static int rawdcf_init_1 (struct parseunit *); #define RAWDCFDTRSET_DESCRIPTION "RAW DCF77 CODE (DTR SET/RTS CLR)" #define RAWDCFDTRSET_INIT rawdcf_init_1 @@ -685,7 +685,7 @@ * RAWDCF receivers that need to be powered from * DTR CLR and RTS SET */ -static int rawdcf_init_2 P((struct parseunit *)); +static int rawdcf_init_2 (struct parseunit *); #define RAWDCFDTRCLRRTSSET_DESCRIPTION "RAW DCF77 CODE (DTR CLR/RTS SET)" #define RAWDCFDTRCLRRTSSET_INIT rawdcf_init_2 @@ -700,17 +700,17 @@ #define TRIM_TAIPCMDSIZE (sizeof(TRIM_TAIPPOLLCMD)-1) static poll_info_t trimbletaip_pollinfo = { TRIM_POLLRATE, TRIM_TAIPPOLLCMD, TRIM_TAIPCMDSIZE }; -static int trimbletaip_init P((struct parseunit *)); -static void trimbletaip_event P((struct parseunit *, int)); +static int trimbletaip_init (struct parseunit *); +static void trimbletaip_event (struct parseunit *, int); /* query time & UTC correction data */ static char tsipquery[] = { DLE, 0x21, DLE, ETX, DLE, 0x2F, DLE, ETX }; static poll_info_t trimbletsip_pollinfo = { TRIM_POLLRATE, tsipquery, sizeof(tsipquery) }; -static int trimbletsip_init P((struct parseunit *)); -static void trimbletsip_end P((struct parseunit *)); -static void trimbletsip_message P((struct parseunit *, parsetime_t *)); -static void trimbletsip_event P((struct parseunit *, int)); +static int trimbletsip_init (struct parseunit *); +static void trimbletsip_end (struct parseunit *); +static void trimbletsip_message (struct parseunit *, parsetime_t *); +static void trimbletsip_event (struct parseunit *, int); #define TRIMBLETSIP_IDLE_TIME (300) /* 5 minutes silence at most */ #define TRIMBLE_RESET_HOLDOFF TRIMBLETSIP_IDLE_TIME @@ -858,11 +858,11 @@ static struct parse_clockinfo { u_long cl_flags; /* operation flags (io modes) */ - void (*cl_poll) P((struct parseunit *)); /* active poll routine */ - int (*cl_init) P((struct parseunit *)); /* active poll init routine */ - void (*cl_event) P((struct parseunit *, int)); /* special event handling (e.g. reset clock) */ - void (*cl_end) P((struct parseunit *)); /* active poll end routine */ - void (*cl_message) P((struct parseunit *, parsetime_t *)); /* process a lower layer message */ + void (*cl_poll) (struct parseunit *); /* active poll routine */ + int (*cl_init) (struct parseunit *); /* active poll init routine */ + void (*cl_event) (struct parseunit *, int); /* special event handling (e.g. reset clock) */ + void (*cl_end) (struct parseunit *); /* active poll end routine */ + void (*cl_message) (struct parseunit *, parsetime_t *); /* process a lower layer message */ void *cl_data; /* local data area for "poll" mechanism */ double cl_rootdelay; /* rootdelay */ double cl_basedelay; /* current offset by which the RS232 @@ -1371,11 +1371,11 @@ #define PARSE_STATETIME(parse, i) ((parse->generic->currentstatus == i) ? parse->statetime[i] + current_time - parse->lastchange : parse->statetime[i]) -static void parse_event P((struct parseunit *, int)); -static void parse_process P((struct parseunit *, parsetime_t *)); -static void clear_err P((struct parseunit *, u_long)); -static int list_err P((struct parseunit *, u_long)); -static char * l_mktime P((u_long)); +static void parse_event (struct parseunit *, int); +static void parse_process (struct parseunit *, parsetime_t *); +static void clear_err (struct parseunit *, u_long); +static int list_err (struct parseunit *, u_long); +static char * l_mktime (u_long); /**=========================================================================== ** implementation error message regression module @@ -1474,10 +1474,10 @@ ) { char *b = buffer; - char *endb = (char *)0; + char *endb = NULL; if (blen < 4) - return (char *)0; /* don't bother with mini buffers */ + return NULL; /* don't bother with mini buffers */ endb = buffer + blen - 4; @@ -1515,7 +1515,7 @@ } else { - sprintf(buffer, "\\x%02x", *src++); + snprintf(buffer, blen, "\\x%02x", *src++); blen -= 4; buffer += 4; } @@ -1554,27 +1554,27 @@ * define possible io handling methods */ #ifdef STREAM -static int ppsclock_init P((struct parseunit *)); -static int stream_init P((struct parseunit *)); -static void stream_end P((struct parseunit *)); -static int stream_enable P((struct parseunit *)); -static int stream_disable P((struct parseunit *)); -static int stream_setcs P((struct parseunit *, parsectl_t *)); -static int stream_getfmt P((struct parseunit *, parsectl_t *)); -static int stream_setfmt P((struct parseunit *, parsectl_t *)); -static int stream_timecode P((struct parseunit *, parsectl_t *)); -static void stream_receive P((struct recvbuf *)); +static int ppsclock_init (struct parseunit *); +static int stream_init (struct parseunit *); +static void stream_end (struct parseunit *); +static int stream_enable (struct parseunit *); +static int stream_disable (struct parseunit *); +static int stream_setcs (struct parseunit *, parsectl_t *); +static int stream_getfmt (struct parseunit *, parsectl_t *); +static int stream_setfmt (struct parseunit *, parsectl_t *); +static int stream_timecode (struct parseunit *, parsectl_t *); +static void stream_receive (struct recvbuf *); #endif -static int local_init P((struct parseunit *)); -static void local_end P((struct parseunit *)); -static int local_nop P((struct parseunit *)); -static int local_setcs P((struct parseunit *, parsectl_t *)); -static int local_getfmt P((struct parseunit *, parsectl_t *)); -static int local_setfmt P((struct parseunit *, parsectl_t *)); -static int local_timecode P((struct parseunit *, parsectl_t *)); -static void local_receive P((struct recvbuf *)); -static int local_input P((struct recvbuf *)); +static int local_init (struct parseunit *); +static void local_end (struct parseunit *); +static int local_nop (struct parseunit *); +static int local_setcs (struct parseunit *, parsectl_t *); +static int local_getfmt (struct parseunit *, parsectl_t *); +static int local_setfmt (struct parseunit *, parsectl_t *); +static int local_timecode (struct parseunit *, parsectl_t *); +static void local_receive (struct recvbuf *); +static int local_input (struct recvbuf *); static bind_t io_bindings[] = { @@ -2073,7 +2073,7 @@ pps_timeout.tv_sec = 0; pps_timeout.tv_nsec = 0; - if (time_pps_fetch(parse->ppshandle, PPS_TSFMT_TSPEC, &pps_info, + if (time_pps_fetch(parse->atom.handle, PPS_TSFMT_TSPEC, &pps_info, &pps_timeout) == 0) { if (pps_info.assert_sequence + pps_info.clear_sequence != parse->ppsserial) @@ -2621,7 +2621,7 @@ #ifdef HAVE_PPSAPI if (parse->flags & PARSE_PPSCLOCK) { - (void)time_pps_destroy(parse->ppshandle); + (void)time_pps_destroy(parse->atom.handle); } #endif if (parse->generic->io.fd != parse->ppsfd && parse->ppsfd != -1) @@ -2684,7 +2684,7 @@ i = PPS_CAPTUREASSERT; } - if (time_pps_kcbind(parse->ppshandle, PPS_KC_HARDPPS, i, + if (time_pps_kcbind(parse->atom.handle, PPS_KC_HARDPPS, i, PPS_TSFMT_TSPEC) < 0) { msyslog(LOG_ERR, "PARSE receiver #%d: time_pps_kcbind failed: %m", CLK_UNIT(parse->peer)); @@ -2711,23 +2711,30 @@ struct parseunit *parse ) { - int cap, mode, mode1; + int cap, mode_ppsoffset; char *cp; parse->flags &= ~PARSE_PPSCLOCK; - if (time_pps_getcap(parse->ppshandle, &cap) < 0) { + /* + * collect PPSAPI offset capability - should move into generic handling + */ + if (time_pps_getcap(parse->atom.handle, &cap) < 0) { msyslog(LOG_ERR, "PARSE receiver #%d: parse_ppsapi: time_pps_getcap failed: %m", CLK_UNIT(parse->peer)); return 0; } - if (time_pps_getparams(parse->ppshandle, &parse->ppsparams) < 0) { - msyslog(LOG_ERR, "PARSE receiver #%d: parse_ppsapi: time_pps_getparams failed: %m", - CLK_UNIT(parse->peer)); + /* + * initialize generic PPSAPI interface + * + * we leave out CLK_FLAG3 as time_pps_kcbind() + * is handled here for now. Ideally this should also + * be part of the generic PPSAPI interface + */ + if (!refclock_params(parse->flags & (CLK_FLAG1|CLK_FLAG2|CLK_FLAG4), &parse->atom)) return 0; - } /* nb. only turn things on, if someone else has turned something * on before we get here, leave it alone! @@ -2735,47 +2742,36 @@ if (parse->flags & PARSE_CLEAR) { cp = "CLEAR"; - mode = PPS_CAPTURECLEAR; - mode1 = PPS_OFFSETCLEAR; + mode_ppsoffset = PPS_OFFSETCLEAR; } else { cp = "ASSERT"; - mode = PPS_CAPTUREASSERT; - mode1 = PPS_OFFSETASSERT; + mode_ppsoffset = PPS_OFFSETASSERT; } msyslog(LOG_INFO, "PARSE receiver #%d: initializing PPS to %s", CLK_UNIT(parse->peer), cp); - if (!(mode & cap)) { - msyslog(LOG_ERR, "PARSE receiver #%d: FAILED to initialize PPS to %s (PPS API capabilities=0x%x)", - CLK_UNIT(parse->peer), cp, cap); - - return 0; - } - - if (!(mode1 & cap)) { + if (!(mode_ppsoffset & cap)) { msyslog(LOG_WARNING, "PARSE receiver #%d: Cannot set PPS_%sCLEAR, this will increase jitter (PPS API capabilities=0x%x)", CLK_UNIT(parse->peer), cp, cap); - mode1 = 0; + mode_ppsoffset = 0; } else { - if (mode1 == PPS_OFFSETCLEAR) + if (mode_ppsoffset == PPS_OFFSETCLEAR) { - parse->ppsparams.clear_offset.tv_sec = -parse->ppsphaseadjust; - parse->ppsparams.clear_offset.tv_nsec = -1e9*(parse->ppsphaseadjust - (long)parse->ppsphaseadjust); + parse->atom.pps_params.clear_offset.tv_sec = -parse->ppsphaseadjust; + parse->atom.pps_params.clear_offset.tv_nsec = -1e9*(parse->ppsphaseadjust - (long)parse->ppsphaseadjust); } - if (mode1 == PPS_OFFSETASSERT) + if (mode_ppsoffset == PPS_OFFSETASSERT) { - parse->ppsparams.assert_offset.tv_sec = -parse->ppsphaseadjust; - parse->ppsparams.assert_offset.tv_nsec = -1e9*(parse->ppsphaseadjust - (long)parse->ppsphaseadjust); + parse->atom.pps_params.assert_offset.tv_sec = -parse->ppsphaseadjust; + parse->atom.pps_params.assert_offset.tv_nsec = -1e9*(parse->ppsphaseadjust - (long)parse->ppsphaseadjust); } } - /* only set what is legal */ - - parse->ppsparams.mode = (mode | mode1 | PPS_TSFMT_TSPEC) & cap; + parse->atom.pps_params.mode |= mode_ppsoffset; - if (time_pps_setparams(parse->ppshandle, &parse->ppsparams) < 0) { + if (time_pps_setparams(parse->atom.handle, &parse->atom.pps_params) < 0) { msyslog(LOG_ERR, "PARSE receiver #%d: FAILED set PPS parameters: %m", CLK_UNIT(parse->peer)); return 0; @@ -2817,7 +2813,7 @@ if (!notice) { NLOG(NLOG_CLOCKINFO) /* conditional if clause for conditional syslog */ - msyslog(LOG_INFO, "NTP PARSE support: Copyright (c) 1989-2006, Frank Kardel"); + msyslog(LOG_INFO, "NTP PARSE support: Copyright (c) 1989-2009, Frank Kardel"); notice = 1; } @@ -3033,7 +3029,7 @@ parse->hardppsstate = PARSE_HARDPPS_DISABLE; if (CLK_PPS(parse->peer)) { - if (time_pps_create(parse->ppsfd, &parse->ppshandle) < 0) + if (!refclock_ppsapi(parse->ppsfd, &parse->atom)) { msyslog(LOG_NOTICE, "PARSE receiver #%d: parse_start: could not set up PPS: %m", CLK_UNIT(parse->peer)); } @@ -3811,7 +3807,7 @@ /* * set fudge = 0.0 if already included in PPS time stamps */ - if (parse->ppsparams.mode & (PPS_OFFSETCLEAR|PPS_OFFSETASSERT)) + if (parse->atom.pps_params.mode & (PPS_OFFSETCLEAR|PPS_OFFSETASSERT)) { ppsphaseadjust = 0.0; } @@ -3996,16 +3992,32 @@ refclock_process_offset(parse->generic, reftime, rectime, fudge); +#ifdef HAVE_PPSAPI /* * pass PPS information on to PPS clock */ if (PARSE_PPS(parsetime->parse_state) && CLK_PPS(parse->peer)) { - (void) pps_sample(&parse->timedata.parse_ptime.fp); + /* refclock_pps includes fudgetime1 - we keep the RS232 offset in there :-( */ + double savedtime1 = parse->generic->fudgetime1; + + parse->generic->fudgetime1 = fudge; + + if (refclock_pps(parse->peer, &parse->atom, + parse->flags & (CLK_FLAG1|CLK_FLAG2|CLK_FLAG3|CLK_FLAG4))) { + parse->peer->flags |= FLAG_PPS; + } else { + parse->peer->flags &= ~FLAG_PPS; + } + + parse->generic->fudgetime1 = savedtime1; + parse_hardpps(parse, PARSE_HARDPPS_ENABLE); } +#endif } else { parse_hardpps(parse, PARSE_HARDPPS_DISABLE); + parse->peer->flags &= ~FLAG_PPS; } /* @@ -4834,11 +4846,11 @@ u_char *txt; /* pointer to actual data buffer */ }; -void sendcmd P((struct txbuf *buf, int c)); -void sendbyte P((struct txbuf *buf, int b)); -void sendetx P((struct txbuf *buf, struct parseunit *parse)); -void sendint P((struct txbuf *buf, int a)); -void sendflt P((struct txbuf *buf, double a)); +void sendcmd (struct txbuf *buf, int c); +void sendbyte (struct txbuf *buf, int b); +void sendetx (struct txbuf *buf, struct parseunit *parse); +void sendint (struct txbuf *buf, int a); +void sendflt (struct txbuf *buf, double a); void sendcmd( @@ -4851,11 +4863,11 @@ buf->idx = 2; } -void sendcmd P((struct txbuf *buf, int c)); -void sendbyte P((struct txbuf *buf, int b)); -void sendetx P((struct txbuf *buf, struct parseunit *parse)); -void sendint P((struct txbuf *buf, int a)); -void sendflt P((struct txbuf *buf, double a)); +void sendcmd (struct txbuf *buf, int c); +void sendbyte (struct txbuf *buf, int b); +void sendetx (struct txbuf *buf, struct parseunit *parse); +void sendint (struct txbuf *buf, int a); +void sendflt (struct txbuf *buf, double a); void sendbyte( @@ -5058,7 +5070,7 @@ parse->localdata = (void *)0; } parse->peer->nextaction = 0; - parse->peer->action = (void (*) P((struct peer *)))0; + parse->peer->action = (void (*) (struct peer *))0; } /*-------------------------------------------------- @@ -5744,6 +5756,9 @@ * History: * * refclock_parse.c,v + * Revision 4.81 2009/05/01 10:15:29 kardel + * use new refclock_ppsapi interface + * * Revision 4.80 2007/08/11 12:06:29 kardel * update comments wrt/ to PPS * diff -urN src/contrib/ntp/ntpd/refclock_pcf.c src.ntp/contrib/ntp/ntpd/refclock_pcf.c --- src/contrib/ntp/ntpd/refclock_pcf.c 2004-07-20 17:01:37.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_pcf.c 2010-02-04 08:26:51.000000000 +0100 @@ -38,9 +38,9 @@ /* * Function prototypes */ -static int pcf_start P((int, struct peer *)); -static void pcf_shutdown P((int, struct peer *)); -static void pcf_poll P((int, struct peer *)); +static int pcf_start (int, struct peer *); +static void pcf_shutdown (int, struct peer *); +static void pcf_poll (int, struct peer *); /* * Transfer vector @@ -72,10 +72,10 @@ /* * Open device file for reading. */ - (void)sprintf(device, DEVICE, unit); + snprintf(device, sizeof(device), DEVICE, unit); fd = open(device, O_RDONLY); if (fd == -1) { - (void)sprintf(device, OLDDEVICE, unit); + snprintf(device, sizeof(device), OLDDEVICE, unit); fd = open(device, O_RDONLY); } #ifdef DEBUG @@ -144,6 +144,8 @@ return; } + memset(&tm, 0, sizeof(tm)); + tm.tm_mday = buf[11] * 10 + buf[10]; tm.tm_mon = buf[13] * 10 + buf[12] - 1; tm.tm_year = buf[15] * 10 + buf[14]; diff -urN src/contrib/ntp/ntpd/refclock_pst.c src.ntp/contrib/ntp/ntpd/refclock_pst.c --- src/contrib/ntp/ntpd/refclock_pst.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_pst.c 2010-02-04 08:26:54.000000000 +0100 @@ -91,10 +91,10 @@ /* * Function prototypes */ -static int pst_start P((int, struct peer *)); -static void pst_shutdown P((int, struct peer *)); -static void pst_receive P((struct recvbuf *)); -static void pst_poll P((int, struct peer *)); +static int pst_start (int, struct peer *); +static void pst_shutdown (int, struct peer *); +static void pst_receive (struct recvbuf *); +static void pst_poll (int, struct peer *); /* * Transfer vector @@ -127,25 +127,23 @@ /* * Open serial port. Use CLK line discipline, if available. */ - (void)sprintf(device, DEVICE, unit); + snprintf(device, sizeof(device), DEVICE, unit); if (!(fd = refclock_open(device, SPEED232, LDISC_CLK))) return (0); /* * Allocate and initialize unit structure */ - if (!(up = (struct pstunit *)emalloc(sizeof(struct pstunit)))) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct pstunit)); + up = emalloc(sizeof(*up)); + memset(up, 0, sizeof(*up)); pp = peer->procptr; pp->io.clock_recv = pst_receive; pp->io.srcclock = (caddr_t)peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + close(fd); + pp->io.fd = -1; free(up); return (0); } @@ -176,8 +174,10 @@ pp = peer->procptr; up = (struct pstunit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } diff -urN src/contrib/ntp/ntpd/refclock_ripencc.c src.ntp/contrib/ntp/ntpd/refclock_ripencc.c --- src/contrib/ntp/ntpd/refclock_ripencc.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_ripencc.c 2009-12-09 08:36:36.000000000 +0100 @@ -411,33 +411,33 @@ /* header/source border XXXXXXXXXXXXXXXXXXXXXXXXXX */ /* Trimble parse functions */ -static int parse0x8FAD P((TSIPPKT *, struct peer *)); -static int parse0x8F0B P((TSIPPKT *, struct peer *)); +static int parse0x8FAD (TSIPPKT *, struct peer *); +static int parse0x8F0B (TSIPPKT *, struct peer *); #ifdef TRIMBLE_OUTPUT_FUNC -static int parseany P((TSIPPKT *, struct peer *)); -static void TranslateTSIPReportToText P((TSIPPKT *, char *)); +static int parseany (TSIPPKT *, struct peer *); +static void TranslateTSIPReportToText (TSIPPKT *, char *); #endif /* TRIMBLE_OUTPUT_FUNC */ -static int parse0x5C P((TSIPPKT *, struct peer *)); -static int parse0x4F P((TSIPPKT *, struct peer *)); -static void tsip_input_proc P((TSIPPKT *, int)); +static int parse0x5C (TSIPPKT *, struct peer *); +static int parse0x4F (TSIPPKT *, struct peer *); +static void tsip_input_proc (TSIPPKT *, int); /* Trimble helper functions */ -static void bPutFloat P((float *, unsigned char *)); -static void bPutDouble P((double *, unsigned char *)); -static void bPutULong P((unsigned long *, unsigned char *)); -static int print_msg_table_header P((int rptcode, char *HdrStr, int force)); -static char * show_time P((float time_of_week)); +static void bPutFloat (float *, unsigned char *); +static void bPutDouble (double *, unsigned char *); +static void bPutULong (unsigned long *, unsigned char *); +static int print_msg_table_header (int rptcode, char *HdrStr, int force); +static char * show_time (float time_of_week); /* RIPE NCC functions */ -static void ripencc_control P((int, struct refclockstat *, struct - refclockstat *, struct peer *)); -static int ripencc_ppsapi P((struct peer *, int, int)); -static int ripencc_get_pps_ts P((struct ripencc_unit *, l_fp *)); -static int ripencc_start P((int, struct peer *)); -static void ripencc_shutdown P((int, struct peer *)); -static void ripencc_poll P((int, struct peer *)); -static void ripencc_send P((struct peer *, TSIPPKT spt)); -static void ripencc_receive P((struct recvbuf *)); +static void ripencc_control (int, struct refclockstat *, struct + refclockstat *, struct peer *); +static int ripencc_ppsapi (struct peer *, int, int); +static int ripencc_get_pps_ts (struct ripencc_unit *, l_fp *); +static int ripencc_start (int, struct peer *); +static void ripencc_shutdown (int, struct peer *); +static void ripencc_poll (int, struct peer *); +static void ripencc_send (struct peer *, TSIPPKT spt); +static void ripencc_receive (struct recvbuf *); /* fill in reflock structure for our clock */ struct refclock refclock_ripencc = { diff -urN src/contrib/ntp/ntpd/refclock_shm.c src.ntp/contrib/ntp/ntpd/refclock_shm.c --- src/contrib/ntp/ntpd/refclock_shm.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_shm.c 2010-02-04 08:26:55.000000000 +0100 @@ -39,6 +39,9 @@ * This driver supports a reference clock attached thru shared memory */ +/* Temp hack to simplify testing of the old mode. */ +#define OLDWAY 0 + /* * SHM interface definitions */ @@ -51,9 +54,12 @@ /* * Function prototypes */ -static int shm_start (int, struct peer *); -static void shm_shutdown (int, struct peer *); -static void shm_poll (int unit, struct peer *); +static int shm_start (int unit, struct peer *peer); +static void shm_shutdown (int unit, struct peer *peer); +static void shm_poll (int unit, struct peer *peer); +static void shm_timer (int unit, struct peer *peer); + int shm_peek (int unit, struct peer *peer); + void shm_clockstats (int unit, struct peer *peer); /* * Transfer vector @@ -61,12 +67,13 @@ struct refclock refclock_shm = { shm_start, /* start up driver */ shm_shutdown, /* shut down driver */ - shm_poll, /* transmit poll message */ - noentry, /* not used */ - noentry, /* initialize driver (not used) */ - noentry, /* not used */ - NOFLAGS /* not used */ + shm_poll, /* transmit poll message */ + noentry, /* not used: control */ + noentry, /* not used: init */ + noentry, /* not used: buginfo */ + shm_timer, /* once per second */ }; + struct shmTime { int mode; /* 0 - if valid set * use values, @@ -88,15 +95,30 @@ int dummy[10]; }; +struct shmunit { + struct shmTime *shm; /* pointer to shared memory segment */ + + /* debugging/monitoring counters - reset when printed */ + int ticks; /* number of attempts to read data*/ + int good; /* number of valid samples */ + int notready; /* number of peeks without data ready */ + int bad; /* number of invalid samples */ + int clash; /* number of access clashes while reading */ +}; + + struct shmTime *getShmTime(int); struct shmTime *getShmTime (int unit) { #ifndef SYS_WINNT int shmid=0; - assert (unit<10); /* MAXUNIT is 4, so should never happen */ + /* 0x4e545030 is NTP0. + * Big units will give non-ascii but that's OK + * as long as everybody does it the same way. + */ shmid=shmget (0x4e545030+unit, sizeof (struct shmTime), - IPC_CREAT|(unit<2?0700:0777)); + IPC_CREAT|(unit<2?0600:0666)); if (shmid==-1) { /*error */ msyslog(LOG_ERR,"SHM shmget (unit %d): %s",unit,strerror(errno)); return 0; @@ -115,8 +137,8 @@ HANDLE shmid=0; SECURITY_DESCRIPTOR sd; SECURITY_ATTRIBUTES sa; - sprintf (buf,"NTP%d",unit); - if (unit>=2) { /* world access */ + snprintf(buf, sizeof(buf), "NTP%d", unit); + if (unit >= 2) { /* world access */ if (!InitializeSecurityDescriptor(&sd, SECURITY_DESCRIPTOR_REVISION)) { msyslog(LOG_ERR,"SHM InitializeSecurityDescriptor (unit %d): %m",unit); return 0; @@ -163,22 +185,29 @@ ) { struct refclockproc *pp; + struct shmunit *up; + pp = peer->procptr; pp->io.clock_recv = noentry; pp->io.srcclock = (caddr_t)peer; pp->io.datalen = 0; pp->io.fd = -1; - pp->unitptr = (caddr_t)getShmTime(unit); + + up = emalloc(sizeof(*up)); + memset(up, 0, sizeof(*up)); + pp->unitptr = (caddr_t)up; + + up->shm = getShmTime(unit); /* * Initialize miscellaneous peer variables */ memcpy((char *)&pp->refid, REFID, 4); - if (pp->unitptr!=0) { - ((struct shmTime*)pp->unitptr)->precision=PRECISION; - peer->precision = ((struct shmTime*)pp->unitptr)->precision; - ((struct shmTime*)pp->unitptr)->valid=0; - ((struct shmTime*)pp->unitptr)->nsamples=NSAMPLES; + if (up->shm != 0) { + up->shm->precision = PRECISION; + peer->precision = up->shm->precision; + up->shm->valid=0; + up->shm->nsamples=NSAMPLES; pp->clockdesc = DESCRIPTION; return (1); } @@ -197,17 +226,34 @@ struct peer *peer ) { - register struct shmTime *up; struct refclockproc *pp; + struct shmunit *up; pp = peer->procptr; - up = (struct shmTime *)pp->unitptr; + up = (struct shmunit *)pp->unitptr; + + if (NULL == up) + return; #ifndef SYS_WINNT /* HMS: shmdt()wants char* or const void * */ - (void) shmdt (up); + (void) shmdt ((char *)up->shm); #else - UnmapViewOfFile (up); + UnmapViewOfFile (up->shm); #endif + free(up); +} + + +/* + * shm_timer - called every second + */ +static void +shm_timer(int unit, struct peer *peer) +{ + if (OLDWAY) + return; + + shm_peek(unit, peer); } @@ -220,26 +266,60 @@ struct peer *peer ) { - register struct shmTime *up; struct refclockproc *pp; + int ok; + + pp = peer->procptr; + + if (OLDWAY) { + ok = shm_peek(unit, peer); + if (!ok) return; + } + + /* + * Process median filter samples. If none received, declare a + * timeout and keep going. + */ + if (pp->coderecv == pp->codeproc) { + refclock_report(peer, CEVNT_TIMEOUT); + shm_clockstats(unit, peer); + return; + } + pp->lastref = pp->lastrec; + refclock_receive(peer); + shm_clockstats(unit, peer); +} + +/* + * shm_peek - try to grab a sample + */ +int shm_peek( + int unit, + struct peer *peer + ) +{ + struct refclockproc *pp; + struct shmunit *up; + struct shmTime *shm; /* * This is the main routine. It snatches the time from the shm * board and tacks on a local timestamp. */ pp = peer->procptr; - up = (struct shmTime*)pp->unitptr; - if (up==0) { /* try to map again - this may succeed if meanwhile some- - body has ipcrm'ed the old (unaccessible) shared mem - segment */ - pp->unitptr = (caddr_t)getShmTime(unit); - up = (struct shmTime*)pp->unitptr; + up = (struct shmunit*)pp->unitptr; + up->ticks++; + if (up->shm == 0) { + /* try to map again - this may succeed if meanwhile some- + body has ipcrm'ed the old (unaccessible) shared mem segment */ + up->shm = getShmTime(unit); } - if (up==0) { + shm = up->shm; + if (shm == 0) { refclock_report(peer, CEVNT_FAULT); - return; + return(0); } - if (up->valid) { + if (shm->valid) { struct timeval tvr; struct timeval tvt; struct tm *t; @@ -248,27 +328,27 @@ tvr.tv_usec = 0; tvt.tv_sec = 0; tvt.tv_usec = 0; - switch (up->mode) { + switch (shm->mode) { case 0: { - tvr.tv_sec=up->receiveTimeStampSec; - tvr.tv_usec=up->receiveTimeStampUSec; - tvt.tv_sec=up->clockTimeStampSec; - tvt.tv_usec=up->clockTimeStampUSec; + tvr.tv_sec=shm->receiveTimeStampSec; + tvr.tv_usec=shm->receiveTimeStampUSec; + tvt.tv_sec=shm->clockTimeStampSec; + tvt.tv_usec=shm->clockTimeStampUSec; } break; case 1: { - int cnt=up->count; - tvr.tv_sec=up->receiveTimeStampSec; - tvr.tv_usec=up->receiveTimeStampUSec; - tvt.tv_sec=up->clockTimeStampSec; - tvt.tv_usec=up->clockTimeStampUSec; - ok=(cnt==up->count); + int cnt=shm->count; + tvr.tv_sec=shm->receiveTimeStampSec; + tvr.tv_usec=shm->receiveTimeStampUSec; + tvt.tv_sec=shm->clockTimeStampSec; + tvt.tv_usec=shm->clockTimeStampUSec; + ok=(cnt==shm->count); } break; default: - msyslog (LOG_ERR, "SHM: bad mode found in shared memory: %d",up->mode); + msyslog (LOG_ERR, "SHM: bad mode found in shared memory: %d",shm->mode); } - up->valid=0; + shm->valid=0; if (ok) { time_t help; /* XXX NetBSD has incompatible tv_sec */ @@ -283,28 +363,53 @@ pp->minute=t->tm_min; pp->second=t->tm_sec; pp->nsec=tvt.tv_usec * 1000; - peer->precision=up->precision; - pp->leap=up->leap; + peer->precision=shm->precision; + pp->leap=shm->leap; } else { refclock_report(peer, CEVNT_FAULT); msyslog (LOG_NOTICE, "SHM: access clash in shared memory"); - return; + up->clash++; + return(0); } } else { refclock_report(peer, CEVNT_TIMEOUT); - /* - msyslog (LOG_NOTICE, "SHM: no new value found in shared memory"); - */ - return; + up->notready++; + return(0); } if (!refclock_process(pp)) { refclock_report(peer, CEVNT_BADTIME); - return; + up->bad++; + return(0); } - pp->lastref = pp->lastrec; - refclock_receive(peer); + up->good++; + return(1); +} + +/* + * shm_clockstats - dump and reset counters + */ +void shm_clockstats( + int unit, + struct peer *peer + ) +{ + struct refclockproc *pp; + struct shmunit *up; + char logbuf[256]; + + pp = peer->procptr; + up = (struct shmunit*)pp->unitptr; + + if (!(pp->sloppyclockflag & CLK_FLAG4)) return; + + snprintf(logbuf, sizeof(logbuf), "%3d %3d %3d %3d %3d", + up->ticks, up->good, up->notready, up->bad, up->clash); + record_clock_stats(&peer->srcadr, logbuf); + + up->ticks = up->good = up->notready =up->bad = up->clash = 0; + } #else diff -urN src/contrib/ntp/ntpd/refclock_tpro.c src.ntp/contrib/ntp/ntpd/refclock_tpro.c --- src/contrib/ntp/ntpd/refclock_tpro.c 2004-07-20 17:01:38.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_tpro.c 2010-02-04 08:26:55.000000000 +0100 @@ -42,9 +42,9 @@ /* * Function prototypes */ -static int tpro_start P((int, struct peer *)); -static void tpro_shutdown P((int, struct peer *)); -static void tpro_poll P((int unit, struct peer *)); +static int tpro_start (int, struct peer *); +static void tpro_shutdown (int, struct peer *); +static void tpro_poll (int unit, struct peer *); /* * Transfer vector @@ -77,7 +77,7 @@ /* * Open TPRO device */ - (void)sprintf(device, DEVICE, unit); + snprintf(device, sizeof(device), DEVICE, unit); fd = open(device, O_RDONLY | O_NDELAY, 0777); if (fd == -1) { msyslog(LOG_ERR, "tpro_start: open of %s: %m", device); @@ -87,11 +87,8 @@ /* * Allocate and initialize unit structure */ - if (!(up = (struct tprounit *) emalloc(sizeof(struct tprounit)))) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct tprounit)); + up = emalloc(sizeof(*up)); + memset(up, 0, sizeof(*up)); pp = peer->procptr; pp->io.clock_recv = noentry; pp->io.srcclock = (caddr_t)peer; @@ -125,7 +122,8 @@ pp = peer->procptr; up = (struct tprounit *)pp->unitptr; io_closeclock(&pp->io); - free(up); + if (NULL != up) + free(up); } @@ -170,13 +168,13 @@ * we could pad the written string appropriately and read the * resulting value in already scaled. */ - sprintf(pp->a_lastcode, - "%1x%1x%1x %1x%1x:%1x%1x:%1x%1x.%1x%1x%1x%1x%1x%1x %1x", - tp->day100, tp->day10, tp->day1, tp->hour10, tp->hour1, - tp->min10, tp->min1, tp->sec10, tp->sec1, tp->ms100, - tp->ms10, tp->ms1, tp->usec100, tp->usec10, tp->usec1, - tp->status); - pp->lencode = strlen(pp->a_lastcode); + snprintf(pp->a_lastcode, sizeof(pp->a_lastcode), + "%1x%1x%1x %1x%1x:%1x%1x:%1x%1x.%1x%1x%1x%1x%1x%1x %1x", + tp->day100, tp->day10, tp->day1, tp->hour10, tp->hour1, + tp->min10, tp->min1, tp->sec10, tp->sec1, tp->ms100, + tp->ms10, tp->ms1, tp->usec100, tp->usec10, tp->usec1, + tp->status); + pp->lencode = strlen(pp->a_lastcode); #ifdef DEBUG if (debug) printf("tpro: time %s timecode %d %s\n", @@ -204,7 +202,6 @@ refclock_report(peer, CEVNT_TIMEOUT); return; } - refclock_receive(peer); pp->lastref = pp->lastrec; record_clock_stats(&peer->srcadr, pp->a_lastcode); refclock_receive(peer); diff -urN src/contrib/ntp/ntpd/refclock_trak.c src.ntp/contrib/ntp/ntpd/refclock_trak.c --- src/contrib/ntp/ntpd/refclock_trak.c 2004-07-20 17:01:38.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_trak.c 2010-02-04 08:26:58.000000000 +0100 @@ -147,7 +147,7 @@ * timestamp following the "*" on-time character of the * timecode. */ - (void)sprintf(device, DEVICE, unit); + snprintf(device, sizeof(device), DEVICE, unit); if ( #ifdef PPS !(fd = refclock_open(device, SPEED232, LDISC_CLK)) @@ -160,12 +160,8 @@ /* * Allocate and initialize unit structure */ - if (!(up = (struct trakunit *) - emalloc(sizeof(struct trakunit)))) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct trakunit)); + up = emalloc(sizeof(*up)); + memset(up, 0, sizeof(*up)); pp = peer->procptr; pp->io.clock_recv = trak_receive; pp->io.srcclock = (caddr_t)peer; @@ -173,6 +169,7 @@ pp->io.fd = fd; if (!io_addclock(&pp->io)) { (void) close(fd); + pp->io.fd = -1; free(up); return (0); } @@ -214,8 +211,10 @@ pp = peer->procptr; up = (struct trakunit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } diff -urN src/contrib/ntp/ntpd/refclock_true.c src.ntp/contrib/ntp/ntpd/refclock_true.c --- src/contrib/ntp/ntpd/refclock_true.c 2004-07-20 17:01:38.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_true.c 2010-04-20 23:50:12.000000000 +0200 @@ -167,15 +167,15 @@ /* * Function prototypes */ -static int true_start P((int, struct peer *)); -static void true_shutdown P((int, struct peer *)); -static void true_receive P((struct recvbuf *)); -static void true_poll P((int, struct peer *)); -static void true_send P((struct peer *, const char *)); -static void true_doevent P((struct peer *, enum true_event)); +static int true_start (int, struct peer *); +static void true_shutdown (int, struct peer *); +static void true_receive (struct recvbuf *); +static void true_poll (int, struct peer *); +static void true_send (struct peer *, const char *); +static void true_doevent (struct peer *, enum true_event); #ifdef CLOCK_PPS720 -static u_long true_sample720 P((void)); +static u_long true_sample720 (void); #endif /* @@ -235,6 +235,7 @@ fprintf(up->debug, "true%d: ", up->unit); vfprintf(up->debug, fmt, ap); } + va_end(ap); } #endif /*STDC*/ @@ -480,7 +481,8 @@ * Adjust the synchronize indicator according to timecode * say were OK, and then say not if we really are not OK */ - if (synced == '>' || synced == '#' || synced == '?') + if (synced == '>' || synced == '#' || synced == '?' + || synced == 'X') pp->leap = LEAP_NOTINSYNC; else pp->leap = LEAP_NOWARNING; diff -urN src/contrib/ntp/ntpd/refclock_tt560.c src.ntp/contrib/ntp/ntpd/refclock_tt560.c --- src/contrib/ntp/ntpd/refclock_tt560.c 2002-10-29 20:58:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/refclock_tt560.c 2009-12-09 08:36:35.000000000 +0100 @@ -47,9 +47,9 @@ /* * Function prototypes */ -static int tt560_start P((int, struct peer *)); -static void tt560_shutdown P((int, struct peer *)); -static void tt560_poll P((int unit, struct peer *)); +static int tt560_start (int, struct peer *); +static void tt560_shutdown (int, struct peer *); +static void tt560_poll (int unit, struct peer *); /* * Transfer vector diff -urN src/contrib/ntp/ntpd/refclock_ulink.c src.ntp/contrib/ntp/ntpd/refclock_ulink.c --- src/contrib/ntp/ntpd/refclock_ulink.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_ulink.c 2009-12-09 08:36:35.000000000 +0100 @@ -106,10 +106,10 @@ /* * Function prototypes */ -static int ulink_start P((int, struct peer *)); -static void ulink_shutdown P((int, struct peer *)); -static void ulink_receive P((struct recvbuf *)); -static void ulink_poll P((int, struct peer *)); +static int ulink_start (int, struct peer *); +static void ulink_shutdown (int, struct peer *); +static void ulink_receive (struct recvbuf *); +static void ulink_poll (int, struct peer *); /* * Transfer vector diff -urN src/contrib/ntp/ntpd/refclock_wwv.c src.ntp/contrib/ntp/ntpd/refclock_wwv.c --- src/contrib/ntp/ntpd/refclock_wwv.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_wwv.c 2009-12-09 08:36:37.000000000 +0100 @@ -39,11 +39,12 @@ * tuned automatically using this program as propagation conditions * change throughout the weasons, both day and night. * - * The driver receives, demodulates and decodes the radio signals when - * connected to the audio codec of a workstation running Solaris, SunOS - * FreeBSD or Linux, and with a little help, other workstations with - * similar codecs or sound cards. In this implementation, only one audio - * driver and codec can be supported on a single machine. + * The driver requires an audio codec or sound card with sampling rate 8 + * kHz and mu-law companding. This is the same standard as used by the + * telephone industry and is supported by most hardware and operating + * systems, including Solaris, SunOS, FreeBSD, NetBSD and Linux. In this + * implementation, only one audio driver and codec can be supported on a + * single machine. * * The demodulation and decoding algorithms used in this driver are * based on those developed for the TAPR DSP93 development board and the @@ -68,6 +69,10 @@ * It does not seem useful to select the compact disc player port. Fudge * flag3 enables audio monitoring of the input signal. For this purpose, * the monitor gain is set to a default value. + * + * CEVNT_BADTIME invalid date or time + * CEVNT_PROP propagation failure - no stations heard + * CEVNT_TIMEOUT timeout (see newgame() below) */ /* * General definitions. These ordinarily do not need to be changed. @@ -92,6 +97,7 @@ #define TCKSIZ (TCKCYC * MS) /* tick filter size */ #define NCHAN 5 /* number of radio channels */ #define AUDIO_PHI 5e-6 /* dispersion growth factor */ +#define TBUF 128 /* max monitor line length */ /* * Tunable parameters. The DGAIN parameter can be changed to fit the @@ -102,12 +108,10 @@ * radio is not tunable, the DCHAN parameter can be changed to fit the * expected best propagation frequency: higher if further from the * transmitter, lower if nearer. The compromise value works for the US - * right coast. The FREQ_OFFSET parameter can be used as a frequency - * vernier to correct codec requency if greater than MAXFREQ. + * right coast. */ #define DCHAN 3 /* default radio channel (15 Mhz) */ #define DGAIN 5. /* subcarrier gain */ -#define FREQ_OFFSET 0. /* codec frequency correction (PPM) */ /* * General purpose status bits (status) @@ -133,6 +137,7 @@ #define FGATE 0x0010 /* frequency gate */ #define DGATE 0x0020 /* data pulse amplitude error */ #define BGATE 0x0040 /* data pulse width error */ +#define METRIC 0x0080 /* one or more stations heard */ #define LEPSEC 0x1000 /* leap minute */ /* @@ -150,10 +155,10 @@ * These bits indicate various alarm conditions, which are decoded to * form the quality character included in the timecode. */ -#define CMPERR 1 /* digit or misc bit compare error */ -#define LOWERR 2 /* low bit or digit amplitude or SNR */ -#define NINERR 4 /* less than nine digits in minute */ -#define SYNERR 8 /* not tracking second sync */ +#define CMPERR 0x1 /* digit or misc bit compare error */ +#define LOWERR 0x2 /* low bit or digit amplitude or SNR */ +#define NINERR 0x4 /* less than nine digits in minute */ +#define SYNERR 0x8 /* not tracking second sync */ /* * Watchcat timeouts (watch) @@ -225,15 +230,21 @@ #define SECWAR 0x40 /* 3 leap second warning */ /* - * The on-time synchronization point for the driver is the second epoch - * sync pulse produced by the FIR matched filters. As the 5-ms delay of - * these filters is compensated, the program delay is 1.1 ms due to the - * 600-Hz IIR bandpass filter. The measured receiver delay is 4.7 ms and - * the codec delay less than 0.2 ms. The additional propagation delay - * specific to each receiver location can be programmed in the fudge - * time1 and time2 values for WWV and WWVH, respectively. + * The on-time synchronization point is the positive-going zero crossing + * of the first cycle of the 5-ms second pulse. The IIR baseband filter + * phase delay is 0.91 ms, while the receiver delay is approximately 4.7 + * ms at 1000 Hz. The fudge value -0.45 ms due to the codec and other + * causes was determined by calibrating to a PPS signal from a GPS + * receiver. The additional propagation delay specific to each receiver + * location can be programmed in the fudge time1 and time2 values for + * WWV and WWVH, respectively. + * + * The resulting offsets with a 2.4-GHz P4 running FreeBSD 6.1 are + * generally within .02 ms short-term with .02 ms jitter. The long-term + * offsets vary up to 0.3 ms due to ionosperhic layer height variations. + * The processor load due to the driver is 5.8 percent. */ -#define PDELAY (.0011 + .0047 + .0002) /* net system delay (s) */ +#define PDELAY ((.91 + 4.7 - 0.45) / 1000) /* system delay (s) */ /* * Table of sine values at 4.5-degree increments. This is used by the @@ -365,7 +376,7 @@ }; /* - * BCD coefficients for maximum likelihood digit decode + * BCD coefficients for maximum-likelihood digit decode */ #define P15 1. /* max positive number */ #define N15 -1. /* max negative number */ @@ -447,14 +458,13 @@ /* * The decoding matrix consists of nine row vectors, one for each digit * of the timecode. The digits are stored from least to most significant - * order. The maximum likelihood timecode is formed from the digits - * corresponding to the maximum likelihood values reading in the + * order. The maximum-likelihood timecode is formed from the digits + * corresponding to the maximum-likelihood values reading in the * opposite order: yy ddd hh:mm. */ struct decvec { int radix; /* radix (3, 4, 6, 10) */ int digit; /* current clock digit */ - int mldigit; /* maximum likelihood digit */ int count; /* match count */ double digprb; /* max digit probability */ double digsnr; /* likelihood function (dB) */ @@ -503,6 +513,7 @@ l_fp tick; /* audio sample increment */ double phase, freq; /* logical clock phase and frequency */ double monitor; /* audio monitor point */ + double pdelay; /* propagation delay (s) */ #ifdef ICOM int fd_icom; /* ICOM file descriptor */ #endif /* ICOM */ @@ -513,7 +524,7 @@ * Audio codec variables */ double comp[SIZE]; /* decompanding table */ - int port; /* codec port */ + int port; /* codec port */ int gain; /* codec gain */ int mongain; /* codec monitor gain */ int clipcnt; /* sample clipped count */ @@ -568,32 +579,32 @@ /* * Function prototypes */ -static int wwv_start P((int, struct peer *)); -static void wwv_shutdown P((int, struct peer *)); -static void wwv_receive P((struct recvbuf *)); -static void wwv_poll P((int, struct peer *)); +static int wwv_start (int, struct peer *); +static void wwv_shutdown (int, struct peer *); +static void wwv_receive (struct recvbuf *); +static void wwv_poll (int, struct peer *); /* * More function prototypes */ -static void wwv_epoch P((struct peer *)); -static void wwv_rf P((struct peer *, double)); -static void wwv_endpoc P((struct peer *, int)); -static void wwv_rsec P((struct peer *, double)); -static void wwv_qrz P((struct peer *, struct sync *, int)); -static void wwv_corr4 P((struct peer *, struct decvec *, - double [], double [][4])); -static void wwv_gain P((struct peer *)); -static void wwv_tsec P((struct peer *)); -static int timecode P((struct wwvunit *, char *)); -static double wwv_snr P((double, double)); -static int carry P((struct decvec *)); -static int wwv_newchan P((struct peer *)); -static void wwv_newgame P((struct peer *)); -static double wwv_metric P((struct sync *)); -static void wwv_clock P((struct peer *)); +static void wwv_epoch (struct peer *); +static void wwv_rf (struct peer *, double); +static void wwv_endpoc (struct peer *, int); +static void wwv_rsec (struct peer *, double); +static void wwv_qrz (struct peer *, struct sync *, int); +static void wwv_corr4 (struct peer *, struct decvec *, + double [], double [][4]); +static void wwv_gain (struct peer *); +static void wwv_tsec (struct peer *); +static int timecode (struct wwvunit *, char *); +static double wwv_snr (double, double); +static int carry (struct decvec *); +static int wwv_newchan (struct peer *); +static void wwv_newgame (struct peer *); +static double wwv_metric (struct sync *); +static void wwv_clock (struct peer *); #ifdef ICOM -static int wwv_qsy P((struct peer *, int)); +static int wwv_qsy (struct peer *, int); #endif /* ICOM */ static double qsy[NCHAN] = {2.5, 5, 10, 15, 20}; /* frequencies (MHz) */ @@ -705,7 +716,9 @@ /* * Initialize autotune if available. Note that the ICOM select * code must be less than 128, so the high order bit can be used - * to select the line speed 0 (9600 bps) or 1 (1200 bps). + * to select the line speed 0 (9600 bps) or 1 (1200 bps). Note + * we don't complain if the ICOM device is not there; but, if it + * is, the radio better be working. */ temp = 0; #ifdef DEBUG @@ -719,25 +732,14 @@ else up->fd_icom = icom_init("/dev/icom", B9600, temp); - if (up->fd_icom < 0) { - NLOG(NLOG_SYNCEVENT | NLOG_SYSEVENT) - msyslog(LOG_NOTICE, - "icom: %m"); - up->errflg = CEVNT_FAULT; - } } if (up->fd_icom > 0) { if (wwv_qsy(peer, DCHAN) != 0) { - NLOG(NLOG_SYNCEVENT | NLOG_SYSEVENT) - msyslog(LOG_NOTICE, - "icom: radio not found"); - up->errflg = CEVNT_FAULT; + msyslog(LOG_NOTICE, "icom: radio not found"); close(up->fd_icom); up->fd_icom = 0; } else { - NLOG(NLOG_SYNCEVENT | NLOG_SYSEVENT) - msyslog(LOG_NOTICE, - "icom: autotune enabled"); + msyslog(LOG_NOTICE, "icom: autotune enabled"); } } #endif /* ICOM */ @@ -837,8 +839,7 @@ * per second, which results in a frequency change of * 125 PPM. */ - up->phase += up->freq / SECOND; - up->phase += FREQ_OFFSET / 1e6; + up->phase += (up->freq + clock_codec) / SECOND; if (up->phase >= .5) { up->phase -= 1.; } else if (up->phase < -.5) { @@ -884,8 +885,6 @@ pp = peer->procptr; up = (struct wwvunit *)pp->unitptr; - if (pp->coderecv == pp->codeproc) - up->errflg = CEVNT_TIMEOUT; if (up->errflg) refclock_report(peer, up->errflg); up->errflg = 0; @@ -974,7 +973,6 @@ static int epopos; /* epoch second sync position buffer */ static int iniflg; /* initialization flag */ - int pdelay; /* propagation delay (samples) */ int epoch; /* comb filter index */ double dtemp; int i; @@ -1012,7 +1010,7 @@ * compensate for the radio audio response at 100 Hz. * * Matlab IIR 4th-order IIR elliptic, 150 Hz lowpass, 0.2 dB - * passband ripple, -50 dB stopband ripple. + * passband ripple, -50 dB stopband ripple, phase delay 0.97 ms. */ data = (lpf[4] = lpf[3]) * 8.360961e-01; data += (lpf[3] = lpf[2]) * -3.481740e+00; @@ -1056,7 +1054,7 @@ * tones and most of the noise and voice modulation components. * * Matlab 4th-order IIR elliptic, 800-1400 Hz bandpass, 0.2 dB - * passband ripple, -50 dB stopband ripple. + * passband ripple, -50 dB stopband ripple, phase delay 0.91 ms. */ syncx = (bpf[8] = bpf[7]) * 4.897278e-01; syncx += (bpf[7] = bpf[6]) * -2.765914e+00; @@ -1174,10 +1172,6 @@ */ if (!wwv_newchan(peer)) up->watch = 0; -#ifdef ICOM - if (up->fd_icom > 0) - wwv_qsy(peer, up->dchan); -#endif /* ICOM */ } else { /* @@ -1212,7 +1206,8 @@ wwv_epoch(peer); } else if (up->sptr != NULL) { sp = up->sptr; - if (sp->metric >= TTHR && epoch == sp->mepoch % SECOND) { + if (sp->metric >= TTHR && epoch == sp->mepoch % SECOND) + { up->rsec = (60 - sp->mepoch / SECOND) % 60; up->rphase = 0; up->status |= MSYNC; @@ -1232,18 +1227,14 @@ * provides a resolution of one sample (125 us). The filters run * only if the station has been reliably determined. */ - if (up->status & SELV) { - pdelay = (int)(pp->fudgetime1 * SECOND); + if (up->status & SELV) mfsync = sqrt(csiamp * csiamp + csqamp * csqamp) / TCKCYC; - } else if (up->status & SELH) { - pdelay = (int)(pp->fudgetime2 * SECOND); + else if (up->status & SELH) mfsync = sqrt(hsiamp * hsiamp + hsqamp * hsqamp) / TCKCYC; - } else { - pdelay = 0; + else mfsync = 0; - } /* * Enhance the seconds sync pulse using a 1-s (8000-sample) comb @@ -1271,7 +1262,7 @@ if (epoch == 0) { up->epomax = epomax; up->eposnr = wwv_snr(epomax, nxtmax); - epopos -= pdelay + TCKCYC * MS; + epopos -= TCKCYC * MS; if (epopos < 0) epopos += SECOND; wwv_endpoc(peer, epopos); @@ -1313,7 +1304,7 @@ { struct refclockproc *pp; struct wwvunit *up; - char tbuf[80]; /* monitor buffer */ + char tbuf[TBUF]; /* monitor buffer */ long epoch; pp = peer->procptr; @@ -1365,7 +1356,7 @@ sp->metric = wwv_metric(sp); if (pp->sloppyclockflag & CLK_FLAG4) { sprintf(tbuf, - "wwv8 %04x %3d %s %04x %.0f %.0f/%.1f %4ld %4ld", + "wwv8 %04x %3d %s %04x %.0f %.0f/%.1f %ld %ld", up->status, up->gain, sp->refid, sp->reach & 0xffff, sp->metric, sp->synmax, sp->synsnr, sp->pos % SECOND, epoch); @@ -1413,7 +1404,7 @@ static int avgcnt; /* averaging interval counter */ static int avginc; /* averaging ratchet */ static int iniflg; /* initialization flag */ - char tbuf[80]; /* monitor buffer */ + char tbuf[TBUF]; /* monitor buffer */ double dtemp; int tmp2; @@ -1489,8 +1480,8 @@ mepoch = xepoch; syncnt = 0; } - if ((pp->sloppyclockflag & CLK_FLAG4) && !(up->status & MSYNC)) - { + if ((pp->sloppyclockflag & CLK_FLAG4) && !(up->status & + MSYNC)) { sprintf(tbuf, "wwv1 %04x %3d %4d %5.0f %5.1f %5d %4d %4d %4d", up->status, up->gain, tepoch, up->epomax, @@ -1768,7 +1759,7 @@ struct wwvunit *up; struct chan *cp; struct sync *sp, *rp; - char tbuf[80]; /* monitor buffer */ + char tbuf[TBUF]; /* monitor buffer */ int sw, arg, nsec; pp = peer->procptr; @@ -1887,35 +1878,28 @@ up->errcnt = up->digcnt = up->alarm = 0; /* - * We now begin the minute scan. If not yet synchronized - * to a station, restart if the units digit has not been - * found within the DATA timeout (15 m) or if not - * synchronized within the SYNCH timeout (40 m). After - * synchronizing to a station, restart if no stations - * are found within the PANIC timeout (2 days). + * If synchronized to a station, restart if no stations + * have been heard within the PANIC timeout (2 days). If + * not and the minute digit has been found, restart if + * not synchronized withing the SYNCH timeout (40 m). If + * not, restart if the unit digit has not been found + * within the DATA timeout (15 m). */ if (up->status & INSYNC) { if (up->watch > PANIC) { wwv_newgame(peer); return; } - } else { - if (!(up->status & DSYNC)) { - if (up->watch > DATA) { - wwv_newgame(peer); - return; - } - } + } else if (up->status & DSYNC) { if (up->watch > SYNCH) { wwv_newgame(peer); return; } + } else if (up->watch > DATA) { + wwv_newgame(peer); + return; } wwv_newchan(peer); -#ifdef ICOM - if (up->fd_icom > 0) - wwv_qsy(peer, up->dchan); -#endif /* ICOM */ break; /* @@ -1987,7 +1971,7 @@ /* * Save the data channel gain, then QSY to the probe channel and - * dim the seconds comb filters. The newchan() routine will + * dim the seconds comb filters. The www_newchan() routine will * light them back up. */ case MSC21: /* 58 */ @@ -2107,7 +2091,7 @@ pp->disp = 0; pp->lastref = up->timestamp; refclock_process_offset(pp, offset, - up->timestamp, PDELAY); + up->timestamp, PDELAY + up->pdelay); refclock_receive(peer); } } @@ -2122,12 +2106,12 @@ /* - * wwv_corr4 - determine maximum likelihood digit + * wwv_corr4 - determine maximum-likelihood digit * * This routine correlates the received digit vector with the BCD * coefficient vectors corresponding to all valid digits at the given * position in the decoding matrix. The maximum value corresponds to the - * maximum likelihood digit, while the ratio of this value to the next + * maximum-likelihood digit, while the ratio of this value to the next * lower value determines the likelihood function. Note that, if the * digit is invalid, the likelihood vector is averaged toward a miss. */ @@ -2143,7 +2127,7 @@ struct wwvunit *up; double topmax, nxtmax; /* metrics */ double acc; /* accumulator */ - char tbuf[80]; /* monitor buffer */ + char tbuf[TBUF]; /* monitor buffer */ int mldigit; /* max likelihood digit */ int i, j; @@ -2176,9 +2160,9 @@ vp->digsnr = wwv_snr(topmax, nxtmax); /* - * The current maximum likelihood digit is compared to the last - * maximum likelihood digit. If different, the compare counter - * and maximum likelihood digit are reset. When the compare + * The current maximum-likelihood digit is compared to the last + * maximum-likelihood digit. If different, the compare counter + * and maximum-likelihood digit are reset. When the compare * counter reaches the BCMP threshold (3), the digit is assumed * correct. When the compare counter of all nine digits have * reached threshold, the clock is assumed correct. @@ -2188,26 +2172,23 @@ * not considered correct until all nine clock digits have * reached threshold. This is intended as eye candy, but avoids * mistakes when the signal is low and the SNR is very marginal. - * once correctly set, the maximum likelihood digit is ignored - * on the assumption the clock will always be correct unless for - * some reason it drifts to a different second. */ - vp->mldigit = mldigit; if (vp->digprb < BTHR || vp->digsnr < BSNR) { - vp->count = 0; up->status |= BGATE; } else { - up->status |= DSYNC; if (vp->digit != mldigit) { - vp->count = 0; up->alarm |= CMPERR; - if (!(up->status & INSYNC)) + if (vp->count > 0) + vp->count--; + if (vp->count == 0) vp->digit = mldigit; } else { if (vp->count < BCMP) vp->count++; - else + if (vp->count == BCMP) { + up->status |= DSYNC; up->digcnt++; + } } } if ((pp->sloppyclockflag & CLK_FLAG4) && !(up->status & @@ -2215,7 +2196,7 @@ sprintf(tbuf, "wwv4 %2d %04x %3d %4d %5.0f %2d %d %d %d %5.0f %5.1f", up->rsec - 1, up->status, up->gain, up->yepoch, - up->epomax, vp->radix, vp->digit, vp->mldigit, + up->epomax, vp->radix, vp->digit, mldigit, vp->count, vp->digprb, vp->digsnr); record_clock_stats(&peer->srcadr, tbuf); #ifdef DEBUG @@ -2326,7 +2307,7 @@ * This routine rotates a likelihood vector one position and increments * the clock digit modulo the radix. It returns the new clock digit or * zero if a carry occurred. Once synchronized, the clock digit will - * match the maximum likelihood digit corresponding to that position. + * match the maximum-likelihood digit corresponding to that position. */ static int carry( @@ -2420,16 +2401,14 @@ struct wwvunit *up; struct sync *sp, *rp; double rank, dtemp; - int i, j; + int i, j, rval; pp = peer->procptr; up = (struct wwvunit *)pp->unitptr; /* * Search all five station pairs looking for the channel with - * maximum metric. If no station is found above thresholds, tune - * to WWV on 15 MHz, set the reference ID to NONE and wait for - * hotter ions. + * maximum metric. */ sp = NULL; j = 0; @@ -2453,39 +2432,57 @@ /* * If the strongest signal is less than the MTHR threshold (13), - * we are beneath the waves, so squelch the second sync. If the - * strongest signal is greater than the threshold, tune to that - * frequency and transmitter QTH. + * we are beneath the waves, so squelch the second sync and + * advance to the next station. This makes sure all stations are + * scanned when the ions grow dim. If the strongest signal is + * greater than the threshold, tune to that frequency and + * transmitter QTH. */ + up->status &= ~(SELV | SELH); if (rank < MTHR) { up->dchan = (up->dchan + 1) % NCHAN; - up->status &= ~(SELV | SELH); - return (FALSE); + if (up->status & METRIC) { + up->status &= ~METRIC; + refclock_report(peer, CEVNT_PROP); + } + rval = FALSE; + } else { + up->dchan = j; + up->sptr = sp; + memcpy(&pp->refid, sp->refid, 4); + peer->refid = pp->refid; + up->status |= METRIC; + if (sp->select & SELV) { + up->status |= SELV; + up->pdelay = pp->fudgetime1; + } else if (sp->select & SELH) { + up->status |= SELH; + up->pdelay = pp->fudgetime2; + } else { + up->pdelay = 0; + } + rval = TRUE; } - up->dchan = j; - up->status |= SELV | SELH; - up->sptr = sp; - memcpy(&pp->refid, sp->refid, 4); - peer->refid = pp->refid; - return (TRUE); +#ifdef ICOM + if (up->fd_icom > 0) + wwv_qsy(peer, up->dchan); +#endif /* ICOM */ + return (rval); } /* * wwv_newgame - reset and start over * - * There are four conditions resulting in a new game: + * There are three conditions resulting in a new game: * - * 1 During initial acquisition (MSYNC dark) going 6 minutes (ACQSN) - * without reliably finding the minute pulse (MSYNC lit). - * - * 2 After finding the minute pulse (MSYNC lit), going 15 minutes + * 1 After finding the minute pulse (MSYNC lit), going 15 minutes * (DATA) without finding the unit seconds digit. * - * 3 After finding good data (DATA lit), going more than 40 minutes + * 2 After finding good data (DSYNC lit), going more than 40 minutes * (SYNCH) without finding station sync (INSYNC lit). * - * 4 After finding station sync (INSYNC lit), going more than 2 days + * 3 After finding station sync (INSYNC lit), going more than 2 days * (PANIC) without finding any station. */ static void @@ -2505,6 +2502,8 @@ * Initialize strategic values. Note we set the leap bits * NOTINSYNC and the refid "NONE". */ + if (up->status) + up->errflg = CEVNT_TIMEOUT; peer->leap = LEAP_NOTINSYNC; up->watch = up->status = up->alarm = 0; up->avgint = MINAVG; @@ -2514,7 +2513,8 @@ /* * Initialize the station processes for audio gain, select bit, * station/frequency identifier and reference identifier. Start - * probing at the next channel after the data channel. + * probing at the strongest channel or the default channel if + * nothing heard. */ memset(up->mitig, 0, sizeof(up->mitig)); for (i = 0; i < NCHAN; i++) { @@ -2525,13 +2525,9 @@ cp->wwvh.select = SELH; sprintf(cp->wwvh.refid, "WH%.0f", floor(qsy[i])); } - up->dchan = (DCHAN + NCHAN - 1) % NCHAN;; + up->dchan = (DCHAN + NCHAN - 1) % NCHAN; wwv_newchan(peer); - up->achan = up->schan = up->dchan; -#ifdef ICOM - if (up->fd_icom > 0) - wwv_qsy(peer, up->dchan); -#endif /* ICOM */ + up->schan = up->dchan; } /* @@ -2668,7 +2664,8 @@ * there are no clips, the gain is bumped up; if there are more than * MAXCLP clips (100), it is bumped down. The decoder is relatively * insensitive to amplitude, so this crudity works just peachy. The - * input port is set and the error flag is cleared, mostly to be ornery. + * routine also jiggles the input port and selectively mutes the + * monitor. */ static void wwv_gain( diff -urN src/contrib/ntp/ntpd/refclock_wwvb.c src.ntp/contrib/ntp/ntpd/refclock_wwvb.c --- src/contrib/ntp/ntpd/refclock_wwvb.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpd/refclock_wwvb.c 2010-02-16 12:17:57.000000000 +0100 @@ -17,6 +17,11 @@ #include #include +#ifdef HAVE_PPSAPI +#include "ppsapi_timepps.h" +#include "refclock_atom.h" +#endif /* HAVE_PPSAPI */ + /* * This driver supports the Spectracom Model 8170 and Netclock/2 WWVB * Synchronized Clocks and the Netclock/GPS Master Clock. Both the WWVB @@ -84,6 +89,16 @@ * makes no attempt to correct for the intrinsic jitter of the radio * itself, which is a known problem with the older radios. * + * PPS Signal Processing + * + * When PPS signal processing is enabled, and when the system clock has + * been set by this or another driver and the PPS signal offset is + * within 0.4 s of the system clock offset, the PPS signal replaces the + * timecode for as long as the PPS signal is active. If for some reason + * the PPS signal fails for one or more poll intervals, the driver + * reverts to the timecode. If the timecode fails for one or more poll + * intervals, the PPS signal is disconnected. + * * Fudge Factors * * This driver can retrieve a table of quality data maintained @@ -100,6 +115,7 @@ #define DEVICE "/dev/wwvb%d" /* device name and unit */ #define SPEED232 B9600 /* uart speed (9600 baud) */ #define PRECISION (-13) /* precision assumed (about 100 us) */ +#define PPS_PRECISION (-13) /* precision assumed (about 100 us) */ #define REFID "WWVB" /* reference ID */ #define DESCRIPTION "Spectracom WWVB/GPS Receiver" /* WRU */ @@ -113,6 +129,13 @@ * WWVB unit control structure */ struct wwvbunit { +#ifdef HAVE_PPSAPI + struct refclock_atom atom; /* PPSAPI structure */ + int ppsapi_tried; /* attempt PPSAPI once */ + int ppsapi_lit; /* time_pps_create() worked */ + int tcount; /* timecode sample counter */ + int pcount; /* PPS sample counter */ +#endif /* HAVE_PPSAPI */ l_fp laststamp; /* last receive timestamp */ u_char lasthour; /* last hour (for monitor) */ u_char linect; /* count ignored lines (for monitor */ @@ -121,11 +144,18 @@ /* * Function prototypes */ -static int wwvb_start P((int, struct peer *)); -static void wwvb_shutdown P((int, struct peer *)); -static void wwvb_receive P((struct recvbuf *)); -static void wwvb_poll P((int, struct peer *)); -static void wwvb_timer P((int, struct peer *)); +static int wwvb_start (int, struct peer *); +static void wwvb_shutdown (int, struct peer *); +static void wwvb_receive (struct recvbuf *); +static void wwvb_poll (int, struct peer *); +static void wwvb_timer (int, struct peer *); +#ifdef HAVE_PPSAPI +static void wwvb_control (int, struct refclockstat *, + struct refclockstat *, struct peer *); +#define WWVB_CONTROL wwvb_control +#else +#define WWVB_CONTROL noentry +#endif /* HAVE_PPSAPI */ /* * Transfer vector @@ -134,7 +164,7 @@ wwvb_start, /* start up driver */ wwvb_shutdown, /* shut down driver */ wwvb_poll, /* transmit poll message */ - noentry, /* not used (old wwvb_control) */ + WWVB_CONTROL, /* fudge set/change notification */ noentry, /* initialize driver (not used) */ noentry, /* not used (old wwvb_buginfo) */ wwvb_timer /* called once per second */ @@ -158,19 +188,15 @@ /* * Open serial port. Use CLK line discipline, if available. */ - sprintf(device, DEVICE, unit); - if (!(fd = refclock_open(device, SPEED232, LDISC_CLK))) + snprintf(device, sizeof(device), DEVICE, unit); + if (0 == (fd = refclock_open(device, SPEED232, LDISC_CLK))) return (0); /* * Allocate and initialize unit structure */ - if (!(up = (struct wwvbunit *) - emalloc(sizeof(struct wwvbunit)))) { - close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct wwvbunit)); + up = emalloc(sizeof(*up)); + memset(up, 0, sizeof(*up)); pp = peer->procptr; pp->unitptr = (caddr_t)up; pp->io.clock_recv = wwvb_receive; @@ -179,7 +205,9 @@ pp->io.fd = fd; if (!io_addclock(&pp->io)) { close(fd); + pp->io.fd = -1; free(up); + pp->unitptr = NULL; return (0); } @@ -188,7 +216,7 @@ */ peer->precision = PRECISION; pp->clockdesc = DESCRIPTION; - memcpy((char *)&pp->refid, REFID, 4); + memcpy(&pp->refid, REFID, 4); return (1); } @@ -207,8 +235,10 @@ pp = peer->procptr; up = (struct wwvbunit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } @@ -368,12 +398,16 @@ /* * Process the new sample in the median filter and determine the - * timecode timestamp. + * timecode timestamp, but only if the PPS is not in control. */ - if (!refclock_process(pp)) +#ifdef HAVE_PPSAPI + up->tcount++; + if (peer->flags & FLAG_PPS) + return; + +#endif /* HAVE_PPSAPI */ + if (!refclock_process_f(pp, pp->fudgetime2)) refclock_report(peer, CEVNT_BADTIME); - if (peer->disp > MAXDISTANCE) - refclock_receive(peer); } @@ -405,6 +439,14 @@ pollchar = 'T'; if (write(pp->io.fd, &pollchar, 1) != 1) refclock_report(peer, CEVNT_FAULT); +#ifdef HAVE_PPSAPI + if (up->ppsapi_lit && + refclock_pps(peer, &up->atom, pp->sloppyclockflag) > 0) { + up->pcount++, + peer->flags |= FLAG_PPS; + peer->precision = PPS_PRECISION; + } +#endif /* HAVE_PPSAPI */ } @@ -435,16 +477,29 @@ if (pp->sloppyclockflag & CLK_FLAG4 && pp->hour < (int)up->lasthour) up->linect = MONLIN; - up->lasthour = pp->hour; + up->lasthour = (u_char)pp->hour; /* * Process median filter samples. If none received, declare a * timeout and keep going. */ +#ifdef HAVE_PPSAPI + if (up->pcount == 0) { + peer->flags &= ~FLAG_PPS; + peer->precision = PRECISION; + } + if (up->tcount == 0) { + pp->coderecv = pp->codeproc; + refclock_report(peer, CEVNT_TIMEOUT); + return; + } + up->pcount = up->tcount = 0; +#else /* HAVE_PPSAPI */ if (pp->coderecv == pp->codeproc) { refclock_report(peer, CEVNT_TIMEOUT); return; } +#endif /* HAVE_PPSAPI */ refclock_receive(peer); record_clock_stats(&peer->srcadr, pp->a_lastcode); #ifdef DEBUG @@ -454,6 +509,56 @@ #endif } + +/* + * wwvb_control - fudge parameters have been set or changed + */ +#ifdef HAVE_PPSAPI +static void +wwvb_control( + int unit, + struct refclockstat *in_st, + struct refclockstat *out_st, + struct peer *peer + ) +{ + register struct wwvbunit *up; + struct refclockproc *pp; + + pp = peer->procptr; + up = (struct wwvbunit *)pp->unitptr; + + if (!(pp->sloppyclockflag & CLK_FLAG1)) { + if (!up->ppsapi_tried) + return; + up->ppsapi_tried = 0; + if (!up->ppsapi_lit) + return; + peer->flags &= ~FLAG_PPS; + peer->precision = PRECISION; + time_pps_destroy(up->atom.handle); + up->atom.handle = 0; + up->ppsapi_lit = 0; + return; + } + + if (up->ppsapi_tried) + return; + /* + * Light up the PPSAPI interface. + */ + up->ppsapi_tried = 1; + if (refclock_ppsapi(pp->io.fd, &up->atom)) { + up->ppsapi_lit = 1; + return; + } + + NLOG(NLOG_CLOCKINFO) + msyslog(LOG_WARNING, "%s flag1 1 but PPSAPI fails", + refnumtoa(&peer->srcadr)); +} +#endif /* HAVE_PPSAPI */ + #else int refclock_wwvb_bs; #endif /* REFCLOCK */ diff -urN src/contrib/ntp/ntpd/refclock_zyfer.c src.ntp/contrib/ntp/ntpd/refclock_zyfer.c --- src/contrib/ntp/ntpd/refclock_zyfer.c 2002-11-04 20:35:24.000000000 +0100 +++ src.ntp/contrib/ntp/ntpd/refclock_zyfer.c 2009-12-09 08:36:36.000000000 +0100 @@ -97,10 +97,10 @@ /* * Function prototypes */ -static int zyfer_start P((int, struct peer *)); -static void zyfer_shutdown P((int, struct peer *)); -static void zyfer_receive P((struct recvbuf *)); -static void zyfer_poll P((int, struct peer *)); +static int zyfer_start (int, struct peer *); +static void zyfer_shutdown (int, struct peer *); +static void zyfer_receive (struct recvbuf *); +static void zyfer_poll (int, struct peer *); /* * Transfer vector diff -urN src/contrib/ntp/ntpdate/Makefile.am src.ntp/contrib/ntp/ntpdate/Makefile.am --- src/contrib/ntp/ntpdate/Makefile.am 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpdate/Makefile.am 2009-12-22 11:01:34.000000000 +0100 @@ -1,14 +1,26 @@ -#AUTOMAKE_OPTIONS= ../util/ansi2knr +NULL= +AUTOMAKE_OPTIONS= -bindir= ${exec_prefix}/${BINSUBDIR} -#bin_PROGRAMS= ntpdate ntptimeset +BUILT_SOURCES= +CLEANFILES= + +if NTP_BINSUBDIR_IS_BIN bin_PROGRAMS= ntpdate +else +sbin_PROGRAMS= ntpdate +endif + EXTRA_PROGRAMS= ntptimeset ntptimeset_SOURCES= ntptimeset.c ntptime_config.c -AM_CPPFLAGS= -I$(top_srcdir)/include + +AM_CPPFLAGS= -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/nothreads/include \ + -I$(top_srcdir)/lib/isc/unix/include + # LDADD might need RESLIB and ADJLIB LDADD= version.o ../libntp/libntp.a +ntpdate_LDADD= $(LDADD) @LCRYPTO@ DISTCLEANFILES= .version version.c stamp-v noinst_HEADERS= ntpdate.h ETAGS_ARGS= Makefile.am @@ -25,4 +37,5 @@ env CSET=`cat $(top_srcdir)/version` $(top_builddir)/scripts/mkver ntpdate $(COMPILE) -c version.c -include ../bincheck.mf +include $(top_srcdir)/bincheck.mf +include $(top_srcdir)/depsver.mf diff -urN src/contrib/ntp/ntpdate/Makefile.in src.ntp/contrib/ntp/ntpdate/Makefile.in --- src/contrib/ntp/ntpdate/Makefile.in 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpdate/Makefile.in 2010-07-09 04:21:34.000000000 +0200 @@ -15,8 +15,6 @@ @SET_MAKE@ -#AUTOMAKE_OPTIONS= ../util/ansi2knr - # we traditionally installed software in bindir, while it should have gone # in sbindir. Now that we offer a choice, look in the "other" installation # subdir to warn folks if there is another version there. @@ -41,15 +39,21 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -bin_PROGRAMS = ntpdate$(EXEEXT) +@NTP_BINSUBDIR_IS_BIN_TRUE@bin_PROGRAMS = ntpdate$(EXEEXT) +@NTP_BINSUBDIR_IS_BIN_FALSE@sbin_PROGRAMS = ntpdate$(EXEEXT) EXTRA_PROGRAMS = ntptimeset$(EXEEXT) -DIST_COMMON = README $(noinst_HEADERS) $(srcdir)/../bincheck.mf \ - $(srcdir)/Makefile.am $(srcdir)/Makefile.in +DIST_COMMON = README $(noinst_HEADERS) $(srcdir)/Makefile.am \ + $(srcdir)/Makefile.in $(top_srcdir)/bincheck.mf \ + $(top_srcdir)/depsver.mf subdir = ntpdate ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ + $(top_srcdir)/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/m4/ntp_openssl.m4 \ + $(top_srcdir)/m4/ntp_vpathhack.m4 \ $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ @@ -58,12 +62,11 @@ CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = -am__installdirs = "$(DESTDIR)$(bindir)" -PROGRAMS = $(bin_PROGRAMS) +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(sbindir)" +PROGRAMS = $(bin_PROGRAMS) $(sbin_PROGRAMS) ntpdate_SOURCES = ntpdate.c ntpdate_OBJECTS = ntpdate.$(OBJEXT) -ntpdate_LDADD = $(LDADD) -ntpdate_DEPENDENCIES = version.o ../libntp/libntp.a +ntpdate_DEPENDENCIES = $(LDADD) am_ntptimeset_OBJECTS = ntptimeset.$(OBJEXT) ntptime_config.$(OBJEXT) ntptimeset_OBJECTS = $(am_ntptimeset_OBJECTS) ntptimeset_LDADD = $(LDADD) @@ -90,7 +93,6 @@ ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -111,6 +113,7 @@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EF_LIBS = @EF_LIBS@ EF_PROGS = @EF_PROGS@ EGREP = @EGREP@ @@ -142,6 +145,7 @@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ @@ -158,18 +162,22 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ PATH_SEPARATOR = @PATH_SEPARATOR@ PATH_SH = @PATH_SH@ PROPDELAY = @PROPDELAY@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ VERSION = @VERSION@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ @@ -180,7 +188,7 @@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ -bindir = ${exec_prefix}/${BINSUBDIR} +bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ @@ -221,18 +229,28 @@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ +NULL = +AUTOMAKE_OPTIONS = +BUILT_SOURCES = .deps-ver +CLEANFILES = .deps-ver ntptimeset_SOURCES = ntptimeset.c ntptime_config.c -AM_CPPFLAGS = -I$(top_srcdir)/include +AM_CPPFLAGS = -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/nothreads/include \ + -I$(top_srcdir)/lib/isc/unix/include + + # LDADD might need RESLIB and ADJLIB LDADD = version.o ../libntp/libntp.a +ntpdate_LDADD = $(LDADD) @LCRYPTO@ DISTCLEANFILES = .version version.c stamp-v noinst_HEADERS = ntpdate.h ETAGS_ARGS = Makefile.am -all: all-am +all: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(srcdir)/../bincheck.mf $(am__configure_deps) +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/bincheck.mf $(top_srcdir)/depsver.mf $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -305,6 +323,49 @@ list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ echo " rm -f" $$list; \ rm -f $$list +install-sbinPROGRAMS: $(sbin_PROGRAMS) + @$(NORMAL_INSTALL) + test -z "$(sbindir)" || $(MKDIR_P) "$(DESTDIR)$(sbindir)" + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p || test -f $$p1; \ + then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-sbinPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(sbindir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(sbindir)" && rm -f $$files + +clean-sbinPROGRAMS: + @list='$(sbin_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list ntpdate$(EXEEXT): $(ntpdate_OBJECTS) $(ntpdate_DEPENDENCIES) @rm -f ntpdate$(EXEEXT) $(LINK) $(ntpdate_OBJECTS) $(ntpdate_LDADD) $(LIBS) @@ -432,13 +493,15 @@ fi; \ done check-am: all-am -check: check-am +check: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) check-am all-am: Makefile $(PROGRAMS) $(HEADERS) installdirs: - for dir in "$(DESTDIR)$(bindir)"; do \ + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(sbindir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done -install: install-am +install: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am @@ -455,6 +518,7 @@ mostlyclean-generic: clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) @@ -464,9 +528,11 @@ maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." + -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-am -clean-am: clean-binPROGRAMS clean-generic clean-libtool mostlyclean-am +clean-am: clean-binPROGRAMS clean-generic clean-libtool \ + clean-sbinPROGRAMS mostlyclean-am distclean: distclean-am -rm -rf ./$(DEPDIR) @@ -492,7 +558,7 @@ install-dvi-am: -install-exec-am: install-binPROGRAMS +install-exec-am: install-binPROGRAMS install-sbinPROGRAMS @$(NORMAL_INSTALL) $(MAKE) $(AM_MAKEFLAGS) install-exec-hook install-html: install-html-am @@ -533,23 +599,24 @@ ps-am: -uninstall-am: uninstall-binPROGRAMS +uninstall-am: uninstall-binPROGRAMS uninstall-sbinPROGRAMS -.MAKE: install-am install-exec-am install-strip +.MAKE: all check install install-am install-exec-am install-strip .PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \ - clean-generic clean-libtool ctags distclean distclean-compile \ - distclean-generic distclean-libtool distclean-tags distdir dvi \ - dvi-am html html-am info info-am install install-am \ - install-binPROGRAMS install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-exec-hook \ - install-html install-html-am install-info install-info-am \ - install-man install-pdf install-pdf-am install-ps \ - install-ps-am install-strip installcheck installcheck-am \ - installdirs maintainer-clean maintainer-clean-generic \ - mostlyclean mostlyclean-compile mostlyclean-generic \ - mostlyclean-libtool pdf pdf-am ps ps-am tags uninstall \ - uninstall-am uninstall-binPROGRAMS + clean-generic clean-libtool clean-sbinPROGRAMS ctags distclean \ + distclean-compile distclean-generic distclean-libtool \ + distclean-tags distdir dvi dvi-am html html-am info info-am \ + install install-am install-binPROGRAMS install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-exec-hook install-html install-html-am \ + install-info install-info-am install-man install-pdf \ + install-pdf-am install-ps install-ps-am install-sbinPROGRAMS \ + install-strip installcheck installcheck-am installdirs \ + maintainer-clean maintainer-clean-generic mostlyclean \ + mostlyclean-compile mostlyclean-generic mostlyclean-libtool \ + pdf pdf-am ps ps-am tags uninstall uninstall-am \ + uninstall-binPROGRAMS uninstall-sbinPROGRAMS $(PROGRAMS): $(LDADD) @@ -565,16 +632,80 @@ $(COMPILE) -c version.c install-exec-hook: - @case ${BINSUBDIR} in \ - bin) ODIR=${exec_prefix}/sbin ;; \ - sbin) ODIR=${exec_prefix}/bin ;; \ - esac; \ - test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ + @case ${BINSUBDIR} in \ + bin) ODIR=${sbindir} ;; \ + sbin) ODIR=${bindir} ;; \ + esac; \ + test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ test ! -f $$ODIR/$$i || echo "*** $$i is also in $$ODIR!"; \ done # +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + ..) \ + cd .. && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + *) \ + echo 'Fatal: depsver.mf Automake fragment limited' \ + 'to immediate subdirectories.' && \ + echo "top_builddir: $(top_builddir)" && \ + echo "subdir: $(subdir)" && \ + exit 1 \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff -urN src/contrib/ntp/ntpdate/ntpdate.c src.ntp/contrib/ntp/ntpdate/ntpdate.c --- src/contrib/ntp/ntpdate/ntpdate.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpdate/ntpdate.c 2010-04-18 10:05:39.000000000 +0200 @@ -20,9 +20,8 @@ #include "ntp_syslog.h" #include "ntp_select.h" #include "ntp_stdlib.h" +#include -/* Don't include ISC's version of IPv6 variables and structures */ -#define ISC_IPV6_H 1 #include "isc/net.h" #include "isc/result.h" #include "isc/sockaddr.h" @@ -37,19 +36,15 @@ #ifdef HAVE_POLL_H # include #endif -#ifndef SYS_WINNT -# ifdef HAVE_SYS_SIGNAL_H -# include -# else -# include -# endif -# ifdef HAVE_SYS_IOCTL_H -# include -# endif -#endif /* SYS_WINNT */ +#ifdef HAVE_SYS_SIGNAL_H +# include +#endif +#ifdef HAVE_SYS_IOCTL_H +# include +#endif #ifdef HAVE_SYS_RESOURCE_H # include -#endif /* HAVE_SYS_RESOURCE_H */ +#endif #include @@ -63,9 +58,9 @@ #elif defined(SYS_WINNT) /* * Windows does not abort a select select call if SIGALRM goes off - * so a 200 ms timeout is needed + * so a 200 ms timeout is needed (TIMER_HZ is 5). */ -struct timeval timeout = {0,1000000/TIMER_HZ}; +struct sock_timeval timeout = {0,1000000/TIMER_HZ}; #else struct timeval timeout = {60,0}; #endif @@ -77,9 +72,6 @@ #include "recvbuff.h" #ifdef SYS_WINNT -#define EPROTONOSUPPORT WSAEPROTONOSUPPORT -#define EAFNOSUPPORT WSAEAFNOSUPPORT -#define EPFNOSUPPORT WSAEPFNOSUPPORT #define TARGET_RESOLUTION 1 /* Try for 1-millisecond accuracy on Windows NT timers. */ #pragma comment(lib, "winmm") @@ -96,7 +88,7 @@ # define NTPDATE_PRIO (100) #endif -#if defined(HAVE_TIMER_SETTIME) || defined (HAVE_TIMER_CREATE) +#ifdef HAVE_TIMER_CREATE /* POSIX TIMERS - vxWorks doesn't have itimer - casey */ static timer_t ntpdate_timerid; #endif @@ -211,35 +203,34 @@ int always_step = 0; int never_step = 0; -int ntpdatemain P((int, char **)); +int ntpdatemain (int, char **); -static void transmit P((struct server *)); -static void receive P((struct recvbuf *)); -static void server_data P((struct server *, s_fp, l_fp *, u_fp)); -static void clock_filter P((struct server *)); -static struct server *clock_select P((void)); -static int clock_adjust P((void)); -static void addserver P((char *)); -static struct server *findserver P((struct sockaddr_storage *)); -void timer P((void)); -static void init_alarm P((void)); +static void transmit (struct server *); +static void receive (struct recvbuf *); +static void server_data (struct server *, s_fp, l_fp *, u_fp); +static void clock_filter (struct server *); +static struct server *clock_select (void); +static int clock_adjust (void); +static void addserver (char *); +static struct server *findserver (sockaddr_u *); + void timer (void); +static void init_alarm (void); #ifndef SYS_WINNT -static RETSIGTYPE alarming P((int)); +static RETSIGTYPE alarming (int); #endif /* SYS_WINNT */ -static void init_io P((void)); -static void sendpkt P((struct sockaddr_storage *, struct pkt *, int)); -void input_handler P((void)); +static void init_io (void); +static void sendpkt (sockaddr_u *, struct pkt *, int); +void input_handler (void); -static int l_adj_systime P((l_fp *)); -static int l_step_systime P((l_fp *)); +static int l_adj_systime (l_fp *); +static int l_step_systime (l_fp *); -static void printserver P((struct server *, FILE *)); +static void printserver (struct server *, FILE *); #ifdef SYS_WINNT int on = 1; WORD wVersionRequested; WSADATA wsaData; -HANDLE TimerThreadHandle = NULL; #endif /* SYS_WINNT */ #ifdef NO_MAIN_ALLOWED @@ -299,7 +290,7 @@ #endif #ifdef HAVE_NETINFO -static ni_namelist *getnetinfoservers P((void)); +static ni_namelist *getnetinfoservers (void); #endif /* @@ -335,31 +326,23 @@ ni_namelist *netinfoservers; #endif #ifdef SYS_WINNT - HANDLE process_handle; - - wVersionRequested = MAKEWORD(1,1); - if (WSAStartup(wVersionRequested, &wsaData)) { - netsyslog(LOG_ERR, "No useable winsock.dll: %m"); - exit(1); - } - key_file = key_file_storage; if (!ExpandEnvironmentStrings(KEYFILE, key_file, MAX_PATH)) - { msyslog(LOG_ERR, "ExpandEnvironmentStrings(KEYFILE) failed: %m\n"); - } + + ssl_applink(); #endif /* SYS_WINNT */ #ifdef NO_MAIN_ALLOWED clear_globals(); #endif + init_lib(); /* sets up ipv4_works, ipv6_works */ - /* Check to see if we have IPv6. Otherwise force the -4 flag */ - if (isc_net_probeipv6() != ISC_R_SUCCESS) { + /* Check to see if we have IPv6. Otherwise default to IPv4 */ + if (!ipv6_works) ai_fam_templ = AF_INET; - } errflg = 0; progname = argv[0]; @@ -436,8 +419,18 @@ } else { sys_timeout = ((LFPTOFP(&tmp) * TIMER_HZ) + 0x8000) >> 16; - if (sys_timeout == 0) - sys_timeout = 1; + /* + * No less than 1s between requests to + * a server to stay within ntpd's + * default "discard minimum 1" (and 1s + * enforcement slop). That is enforced + * only if the nondefault limited + * restriction is in place, such as with + * "restrict ... limited" and "restrict + * ... kod limited". + */ + if (MINTIMEOUT < sys_timeout) + sys_timeout = MINTIMEOUT; } break; case 'v': @@ -463,12 +456,7 @@ if (debug || simple_query) { #ifdef HAVE_SETVBUF static char buf[BUFSIZ]; -#ifdef SYS_WINNT - /* Win32 does not implement line buffering */ - setvbuf(stdout, NULL, _IONBF, BUFSIZ); -#else setvbuf(stdout, buf, _IOLBF, BUFSIZ); -#endif /* SYS_WINNT */ #else setlinebuf(stdout); #endif @@ -561,13 +549,6 @@ #if defined(HAVE_BSD_NICE) (void) setpriority(PRIO_PROCESS, 0, NTPDATE_PRIO); #endif -#ifdef SYS_WINNT - process_handle = GetCurrentProcess(); - if (!SetPriorityClass(process_handle, (DWORD) REALTIME_PRIORITY_CLASS)) { - msyslog(LOG_ERR, "SetPriorityClass failed: %m"); - } -#endif /* SYS_WINNT */ - initializing = 0; @@ -608,7 +589,7 @@ #else if (WSAGetLastError() != WSAEINTR) #endif - netsyslog(LOG_ERR, + msyslog(LOG_ERR, #ifdef HAVE_POLL_H "poll() error: %m" #else @@ -617,7 +598,7 @@ ); } else if (errno != 0) { #ifndef SYS_VXWORKS - netsyslog(LOG_DEBUG, + msyslog(LOG_DEBUG, #ifdef HAVE_POLL_H "poll(): nfound = %d, error: %m", #else @@ -687,7 +668,7 @@ struct pkt xpkt; if (debug) - printf("transmit(%s)\n", stoa(&(server->srcadr))); + printf("transmit(%s)\n", stoa(&server->srcadr)); if (server->filter_nextpt < server->xmtcnt) { l_fp ts; @@ -719,7 +700,7 @@ xpkt.ppoll = NTP_MINPOLL; xpkt.precision = NTPDATE_PRECISION; xpkt.rootdelay = htonl(NTPDATE_DISTANCE); - xpkt.rootdispersion = htonl(NTPDATE_DISP); + xpkt.rootdisp = htonl(NTPDATE_DISP); xpkt.refid = htonl(NTPDATE_REFID); L_CLR(&xpkt.reftime); L_CLR(&xpkt.org); @@ -738,18 +719,18 @@ L_ADDUF(&server->xmt, sys_authdelay); HTONL_FP(&server->xmt, &xpkt.xmt); len = authencrypt(sys_authkey, (u_int32 *)&xpkt, LEN_PKT_NOMAC); - sendpkt(&(server->srcadr), &xpkt, (int)(LEN_PKT_NOMAC + len)); + sendpkt(&server->srcadr, &xpkt, (int)(LEN_PKT_NOMAC + len)); if (debug > 1) printf("transmit auth to %s\n", - stoa(&(server->srcadr))); + stoa(&server->srcadr)); } else { get_systime(&(server->xmt)); HTONL_FP(&server->xmt, &xpkt.xmt); - sendpkt(&(server->srcadr), &xpkt, LEN_PKT_NOMAC); + sendpkt(&server->srcadr, &xpkt, LEN_PKT_NOMAC); if (debug > 1) - printf("transmit to %s\n", stoa(&(server->srcadr))); + printf("transmit to %s\n", stoa(&server->srcadr)); } /* @@ -858,13 +839,26 @@ server->trust |= 1; /* + * Check for a KoD (rate limiting) response, cease and decist. + */ + if (LEAP_NOTINSYNC == PKT_LEAP(rpkt->li_vn_mode) && + STRATUM_PKT_UNSPEC == rpkt->stratum && + !memcmp("RATE", &rpkt->refid, 4)) { + msyslog(LOG_ERR, "%s rate limit response from server.\n", + stoa(&rbufp->recv_srcadr)); + server->event_time = 0; + complete_servers++; + return; + } + + /* * Looks good. Record info from the packet. */ server->leap = PKT_LEAP(rpkt->li_vn_mode); server->stratum = PKT_TO_STRATUM(rpkt->stratum); server->precision = rpkt->precision; server->rootdelay = ntohl(rpkt->rootdelay); - server->rootdispersion = ntohl(rpkt->rootdispersion); + server->rootdisp = ntohl(rpkt->rootdisp); server->refid = rpkt->refid; NTOHL_FP(&rpkt->reftime, &server->reftime); NTOHL_FP(&rpkt->rec, &rec); @@ -874,8 +868,9 @@ * Make sure the server is at least somewhat sane. If not, try * again. */ - if (L_ISZERO(&rec) || !L_ISHIS(&server->org, &rec)) { - transmit(server); + if (L_ISZERO(&rec) || !L_ISHIS(&server->org, &rec) + || L_ISEQU(&rec, &server->org)) { + server->event_time = current_time + sys_timeout; return; } @@ -924,10 +919,10 @@ } /* - * Shift this data in, then transmit again. + * Shift this data in, then schedule another transmit. */ server_data(server, (s_fp) di, &ci, 0); - transmit(server); + server->event_time = current_time + sys_timeout; } @@ -1289,7 +1284,7 @@ lfptoa(&server->offset, 6)); } } else { -#if !defined SYS_WINNT && !defined SYS_CYGWIN32 +#ifndef SYS_WINNT if (simple_query || l_adj_systime(&server->offset)) { msyslog(LOG_NOTICE, "adjust time server %s offset %s sec", stoa(&server->srcadr), @@ -1318,16 +1313,16 @@ * (non-blocking). */ static int -is_reachable (struct sockaddr_storage *dst) +is_reachable (sockaddr_u *dst) { SOCKET sockfd; - sockfd = socket(dst->ss_family, SOCK_DGRAM, 0); + sockfd = socket(AF(dst), SOCK_DGRAM, 0); if (sockfd == -1) { return 0; } - if(connect(sockfd, (struct sockaddr *)dst, SOCKLEN(dst))) { + if (connect(sockfd, &dst->sa, SOCKLEN(dst))) { closesocket(sockfd); return 0; } @@ -1375,28 +1370,31 @@ /* Name server is unusable. Exit after failing on the first server, in order to shorten the timeout caused by waiting for resolution of several servers */ - fprintf(stderr, "Name server cannot be used, exiting"); - msyslog(LOG_ERR, "name server cannot be used, reason: %s\n", gai_strerror(error)); + fprintf(stderr, "Exiting, name server cannot be used: %s (%d)", + gai_strerror(error), error); + msyslog(LOG_ERR, "name server cannot be used: %s (%d)\n", + gai_strerror(error), error); exit(1); } - fprintf(stderr, "Error : %s\n", gai_strerror(error)); - msyslog(LOG_ERR, "can't find host %s\n", serv); + fprintf(stderr, "Error resolving %s: %s (%d)\n", serv, + gai_strerror(error), error); + msyslog(LOG_ERR, "Can't find host %s: %s (%d)\n", serv, + gai_strerror(error), error); return; } #ifdef DEBUG else if (debug) { - fprintf(stderr, "host found : %s\n", stohost((struct sockaddr_storage*)addrResult->ai_addr)); + fprintf(stderr, "host found : %s\n", stohost((sockaddr_u *)addrResult->ai_addr)); } #endif /* We must get all returned server in case the first one fails */ for (ptr = addrResult; ptr != NULL; ptr = ptr->ai_next) { - if (is_reachable ((struct sockaddr_storage *)ptr->ai_addr)) { - server = (struct server *)emalloc(sizeof(struct server)); - memset((char *)server, 0, sizeof(struct server)); + if (is_reachable ((sockaddr_u *)ptr->ai_addr)) { + server = emalloc(sizeof(*server)); + memset(server, 0, sizeof(*server)); - memset(&(server->srcadr), 0, sizeof(struct sockaddr_storage)); - memcpy(&(server->srcadr), ptr->ai_addr, ptr->ai_addrlen); + memcpy(&server->srcadr, ptr->ai_addr, ptr->ai_addrlen); server->event_time = ++sys_numservers; if (sys_servers == NULL) sys_servers = server; @@ -1420,40 +1418,23 @@ */ static struct server * findserver( - struct sockaddr_storage *addr + sockaddr_u *addr ) { struct server *server; struct server *mc_server; - isc_sockaddr_t laddr; - isc_sockaddr_t saddr; - - if(addr->ss_family == AF_INET) { - isc_sockaddr_fromin( &laddr, &((struct sockaddr_in*)addr)->sin_addr, 0); - } - else { - isc_sockaddr_fromin6(&laddr, &((struct sockaddr_in6*)addr)->sin6_addr, 0); - } - mc_server = NULL; - if (htons(((struct sockaddr_in*)addr)->sin_port) != NTP_PORT) + if (SRCPORT(addr) != NTP_PORT) return 0; for (server = sys_servers; server != NULL; server = server->next_server) { - - if(server->srcadr.ss_family == AF_INET) { - isc_sockaddr_fromin(&saddr, &((struct sockaddr_in*)&server->srcadr)->sin_addr, 0); - } - else { - isc_sockaddr_fromin6(&saddr, &((struct sockaddr_in6*)&server->srcadr)->sin6_addr, 0); - } - if (isc_sockaddr_eqaddr(&laddr, &saddr) == ISC_TRUE) + if (SOCK_EQ(addr, &server->srcadr)) return server; - if(addr->ss_family == server->srcadr.ss_family) { - if (isc_sockaddr_ismulticast(&saddr) == ISC_TRUE) + if (AF(addr) == AF(&server->srcadr)) { + if (IS_MCAST(&server->srcadr)) mc_server = server; } } @@ -1467,10 +1448,10 @@ complete_servers++; } - server = (struct server *)emalloc(sizeof(struct server)); - memset((char *)server, 0, sizeof(struct server)); + server = emalloc(sizeof(*server)); + memset(server, 0, sizeof(*server)); - memcpy(&server->srcadr, addr, sizeof(struct sockaddr_storage)); + server->srcadr = *addr; server->event_time = ++sys_numservers; @@ -1526,16 +1507,16 @@ { alarm_flag++; } -#else +#else /* SYS_WINNT follows */ void CALLBACK alarming(UINT uTimerID, UINT uMsg, DWORD dwUser, DWORD dw1, DWORD dw2) { + UNUSED_ARG(uTimerID); UNUSED_ARG(uMsg); UNUSED_ARG(dwUser); + UNUSED_ARG(dw1); UNUSED_ARG(dw2); + alarm_flag++; } -#endif /* SYS_WINNT */ - -#ifdef SYS_WINNT static void callTimeEndPeriod(void) { @@ -1552,16 +1533,14 @@ init_alarm(void) { #ifndef SYS_WINNT -# ifndef HAVE_TIMER_SETTIME - struct itimerval itimer; +# ifdef HAVE_TIMER_CREATE + struct itimerspec its; # else - struct itimerspec ntpdate_itimer; + struct itimerval itv; # endif -#else +#else /* SYS_WINNT follows */ TIMECAPS tc; UINT wTimerID; -# endif /* SYS_WINNT */ -#if defined SYS_CYGWIN32 || defined SYS_WINNT HANDLE hToken; TOKEN_PRIVILEGES tkp; DWORD dwUser = 0; @@ -1570,7 +1549,7 @@ alarm_flag = 0; #ifndef SYS_WINNT -# if defined(HAVE_TIMER_CREATE) && defined(HAVE_TIMER_SETTIME) +# ifdef HAVE_TIMER_CREATE alarm_flag = 0; /* this code was put in as setitimer() is non existant this us the * POSIX "equivalents" setup - casey @@ -1592,44 +1571,26 @@ * Set up the alarm interrupt. The first comes 1/(2*TIMER_HZ) * seconds from now and they continue on every 1/TIMER_HZ seconds. */ - (void) signal_no_reset(SIGALRM, alarming); - ntpdate_itimer.it_interval.tv_sec = ntpdate_itimer.it_value.tv_sec = 0; - ntpdate_itimer.it_interval.tv_nsec = 1000000000/TIMER_HZ; - ntpdate_itimer.it_value.tv_nsec = 1000000000/(TIMER_HZ<<1); - timer_settime(ntpdate_timerid, 0 /* !TIMER_ABSTIME */, &ntpdate_itimer, NULL); -# else + signal_no_reset(SIGALRM, alarming); + its.it_interval.tv_sec = 0; + its.it_value.tv_sec = 0; + its.it_interval.tv_nsec = 1000000000/TIMER_HZ; + its.it_value.tv_nsec = 1000000000/(TIMER_HZ<<1); + timer_settime(ntpdate_timerid, 0 /* !TIMER_ABSTIME */, &its, NULL); +# else /* !HAVE_TIMER_CREATE follows */ /* * Set up the alarm interrupt. The first comes 1/(2*TIMER_HZ) * seconds from now and they continue on every 1/TIMER_HZ seconds. */ - (void) signal_no_reset(SIGALRM, alarming); - itimer.it_interval.tv_sec = itimer.it_value.tv_sec = 0; - itimer.it_interval.tv_usec = 1000000/TIMER_HZ; - itimer.it_value.tv_usec = 1000000/(TIMER_HZ<<1); - - setitimer(ITIMER_REAL, &itimer, (struct itimerval *)0); -# endif -#if defined SYS_CYGWIN32 - /* - * Get privileges needed for fiddling with the clock - */ - - /* get the current process token handle */ - if (!OpenProcessToken(GetCurrentProcess(), TOKEN_ADJUST_PRIVILEGES | TOKEN_QUERY, &hToken)) { - msyslog(LOG_ERR, "OpenProcessToken failed: %m"); - exit(1); - } - /* get the LUID for system-time privilege. */ - LookupPrivilegeValue(NULL, SE_SYSTEMTIME_NAME, &tkp.Privileges[0].Luid); - tkp.PrivilegeCount = 1; /* one privilege to set */ - tkp.Privileges[0].Attributes = SE_PRIVILEGE_ENABLED; - /* get set-time privilege for this process. */ - AdjustTokenPrivileges(hToken, FALSE, &tkp, 0,(PTOKEN_PRIVILEGES) NULL, 0); - /* cannot test return value of AdjustTokenPrivileges. */ - if (GetLastError() != ERROR_SUCCESS) - msyslog(LOG_ERR, "AdjustTokenPrivileges failed: %m"); -#endif -#else /* SYS_WINNT */ + signal_no_reset(SIGALRM, alarming); + itv.it_interval.tv_sec = 0; + itv.it_value.tv_sec = 0; + itv.it_interval.tv_usec = 1000000/TIMER_HZ; + itv.it_value.tv_usec = 1000000/(TIMER_HZ<<1); + + setitimer(ITIMER_REAL, &itv, NULL); +# endif /* !HAVE_TIMER_CREATE */ +#else /* SYS_WINNT follows */ _tzset(); /* @@ -1738,7 +1699,7 @@ #ifdef SYS_WINNT if (check_ntp_port_in_use && ntp_port_inuse(AF_INET, NTP_PORT)){ - netsyslog(LOG_ERR, "the NTP socket is in use, exiting: %m"); + msyslog(LOG_ERR, "the NTP socket is in use, exiting: %m"); exit(1); } #endif @@ -1762,13 +1723,13 @@ err == WSAEPFNOSUPPORT) #endif continue; - netsyslog(LOG_ERR, "socket() failed: %m"); + msyslog(LOG_ERR, "socket() failed: %m"); exit(1); /*NOTREACHED*/ } /* set socket to reuse address */ if (setsockopt(fd[nbsock], SOL_SOCKET, SO_REUSEADDR, (void*) &optval, sizeof(optval)) < 0) { - netsyslog(LOG_ERR, "setsockopt() SO_REUSEADDR failed: %m"); + msyslog(LOG_ERR, "setsockopt() SO_REUSEADDR failed: %m"); exit(1); /*NOTREACHED*/ } @@ -1776,7 +1737,7 @@ /* Restricts AF_INET6 socket to IPv6 communications (see RFC 2553bis-03) */ if (res->ai_family == AF_INET6) if (setsockopt(fd[nbsock], IPPROTO_IPV6, IPV6_V6ONLY, (void*) &optval, sizeof(optval)) < 0) { - netsyslog(LOG_ERR, "setsockopt() IPV6_V6ONLY failed: %m"); + msyslog(LOG_ERR, "setsockopt() IPV6_V6ONLY failed: %m"); exit(1); /*NOTREACHED*/ } @@ -1789,15 +1750,16 @@ * bind the socket to the NTP port */ if (check_ntp_port_in_use) { - if (bind(fd[nbsock], res->ai_addr, SOCKLEN(res->ai_addr)) < 0) { + if (bind(fd[nbsock], res->ai_addr, + SOCKLEN((sockaddr_u *)res->ai_addr)) < 0) { #ifndef SYS_WINNT if (errno == EADDRINUSE) #else if (WSAGetLastError() == WSAEADDRINUSE) #endif /* SYS_WINNT */ - netsyslog(LOG_ERR, "the NTP socket is in use, exiting"); + msyslog(LOG_ERR, "the NTP socket is in use, exiting"); else - netsyslog(LOG_ERR, "bind() fails: %m"); + msyslog(LOG_ERR, "bind() fails: %m"); exit(1); } } @@ -1818,24 +1780,24 @@ #ifndef SYS_WINNT # ifdef SYS_VXWORKS { - int on = TRUE; + int on = TRUE; - if (ioctl(fd[nbsock],FIONBIO, &on) == ERROR) { - netsyslog(LOG_ERR, "ioctl(FIONBIO) fails: %m"); - exit(1); - } + if (ioctl(fd[nbsock],FIONBIO, &on) == ERROR) { + msyslog(LOG_ERR, "ioctl(FIONBIO) fails: %m"); + exit(1); + } } # else /* not SYS_VXWORKS */ # if defined(O_NONBLOCK) if (fcntl(fd[nbsock], F_SETFL, O_NONBLOCK) < 0) { - netsyslog(LOG_ERR, "fcntl(FNDELAY|FASYNC) fails: %m"); + msyslog(LOG_ERR, "fcntl(FNDELAY|FASYNC) fails: %m"); exit(1); /*NOTREACHED*/ } # else /* not O_NONBLOCK */ # if defined(FNDELAY) if (fcntl(fd[nbsock], F_SETFL, FNDELAY) < 0) { - netsyslog(LOG_ERR, "fcntl(FNDELAY|FASYNC) fails: %m"); + msyslog(LOG_ERR, "fcntl(FNDELAY|FASYNC) fails: %m"); exit(1); /*NOTREACHED*/ } @@ -1846,7 +1808,7 @@ # endif /* SYS_VXWORKS */ #else /* SYS_WINNT */ if (ioctlsocket(fd[nbsock], FIONBIO, (u_long *) &on) == SOCKET_ERROR) { - netsyslog(LOG_ERR, "ioctlsocket(FIONBIO) fails: %m"); + msyslog(LOG_ERR, "ioctlsocket(FIONBIO) fails: %m"); exit(1); } #endif /* SYS_WINNT */ @@ -1860,7 +1822,7 @@ */ static void sendpkt( - struct sockaddr_storage *dest, + sockaddr_u *dest, struct pkt *pkt, int len ) @@ -1875,14 +1837,14 @@ /* Find a local family compatible socket to send ntp packet to ntp server */ for(i = 0; (i < MAX_AF); i++) { - if(dest->ss_family == fd_family[i]) { + if(AF(dest) == fd_family[i]) { sock = fd[i]; break; } } - if ( sock == INVALID_SOCKET ) { - netsyslog(LOG_ERR, "cannot find family compatible socket to send ntp packet"); + if (INVALID_SOCKET == sock) { + msyslog(LOG_ERR, "cannot find family compatible socket to send ntp packet"); exit(1); /*NOTREACHED*/ } @@ -1890,14 +1852,14 @@ cc = sendto(sock, (char *)pkt, len, 0, (struct sockaddr *)dest, SOCKLEN(dest)); - if (cc == SOCKET_ERROR) { + if (SOCKET_ERROR == cc) { #ifndef SYS_WINNT if (errno != EWOULDBLOCK && errno != ENOBUFS) #else err = WSAGetLastError(); if (err != WSAEWOULDBLOCK && err != WSAENOBUFS) #endif /* SYS_WINNT */ - netsyslog(LOG_ERR, "sendto(%s): %m", stohost(dest)); + msyslog(LOG_ERR, "sendto(%s): %m", stohost(dest)); } } @@ -1910,7 +1872,7 @@ { register int n; register struct recvbuf *rb; - struct timeval tvzero; + struct sock_timeval tvzero; int fromlen; l_fp ts; int i; @@ -1967,7 +1929,7 @@ return; else if (n == -1) { if (errno != EINTR) - netsyslog(LOG_ERR, + msyslog(LOG_ERR, #ifdef HAVE_POLL_H "poll() error: %m" #else @@ -2002,7 +1964,7 @@ rb = get_free_recv_buffer(); - fromlen = sizeof(struct sockaddr_storage); + fromlen = sizeof(rb->recv_srcadr); rb->recv_length = recvfrom(fdc, (char *)&rb->recv_pkt, sizeof(rb->recv_pkt), 0, (struct sockaddr *)&rb->recv_srcadr, &fromlen); @@ -2272,7 +2234,7 @@ ni_status status; void *domain; ni_id confdir; - ni_namelist *namelist = (ni_namelist*)malloc(sizeof(ni_namelist)); + ni_namelist *namelist = emalloc(sizeof(ni_namelist)); /* Find a time server in NetInfo */ if ((status = ni_open(NULL, ".", &domain)) != NI_OK) return NULL; diff -urN src/contrib/ntp/ntpdate/ntpdate.h src.ntp/contrib/ntp/ntpdate/ntpdate.h --- src/contrib/ntp/ntpdate/ntpdate.h 2004-07-20 17:01:41.000000000 +0200 +++ src.ntp/contrib/ntp/ntpdate/ntpdate.h 2010-04-18 10:05:39.000000000 +0200 @@ -4,7 +4,7 @@ #include "ntp_malloc.h" -extern void loadservers P((char *cfgpath)); +extern void loadservers (char *cfgpath); /* * The server structure is a much simplified version of the @@ -15,14 +15,14 @@ */ struct server { struct server *next_server; /* next server in build list */ - struct sockaddr_storage srcadr; /* address of remote host */ + sockaddr_u srcadr; /* address of remote host */ u_char version; /* version to use */ u_char leap; /* leap indicator */ u_char stratum; /* stratum of remote server */ s_char precision; /* server's clock precision */ u_char trust; /* trustability of the filtered data */ u_fp rootdelay; /* distance from primary clock */ - u_fp rootdispersion; /* peer clock dispersion */ + u_fp rootdisp; /* peer clock dispersion */ u_int32 refid; /* peer reference ID */ l_fp reftime; /* time of peer's last update */ u_long event_time; /* time for next timeout */ @@ -91,7 +91,8 @@ /* * Some defaults */ -#define DEFTIMEOUT 5 /* 5 timer increments */ +#define MINTIMEOUT (2 * TIMER_HZ) /* 2s min. between packets */ +#define DEFTIMEOUT MINTIMEOUT /* (to the same server) */ #define DEFSAMPLES 4 /* get 4 samples per server */ #define DEFPRECISION (-5) /* the precision we claim */ #define DEFMAXPERIOD 60 /* maximum time to wait */ diff -urN src/contrib/ntp/ntpdc/Makefile.am src.ntp/contrib/ntp/ntpdc/Makefile.am --- src/contrib/ntp/ntpdc/Makefile.am 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpdc/Makefile.am 2010-04-20 23:50:13.000000000 +0200 @@ -1,13 +1,21 @@ -AUTOMAKE_OPTIONS= ../util/ansi2knr +NULL= +AUTOMAKE_OPTIONS= -bindir= ${exec_prefix}/${BINSUBDIR} +if NTP_BINSUBDIR_IS_BIN bin_PROGRAMS= ntpdc +else +sbin_PROGRAMS= ntpdc +endif + EXTRA_PROGRAMS= ntpdc-layout EXTRA_DATA= check-layout -BUILT_SOURCES= @MAKE_CHECK_LAYOUT@ -AM_CPPFLAGS= -I$(top_srcdir)/include $(LIBOPTS_CFLAGS) +BUILT_SOURCES= @MAKE_CHECK_LAYOUT@ ntpdc-opts.c ntpdc-opts.h +AM_CPPFLAGS= -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/nothreads/include \ + -I$(top_srcdir)/lib/isc/unix/include $(LIBOPTS_CFLAGS) # LDADD might need RESLIB and ADJLIB -ntpdc_LDADD= version.o @READLINE_LIBS@ $(LIBOPTS_LDADD) ../libntp/libntp.a +ntpdc_LDADD= version.o $(LIBOPTS_LDADD) ../libntp/libntp.a \ + @EDITLINE_LIBS@ @LCRYPTO@ # ntpdc-layout doesn't need any additional libraries at all ntpdc_layout_LDADD= DISTCLEANFILES= .version version.c @@ -16,10 +24,10 @@ ETAGS_ARGS= Makefile.am EXTRA_DIST= nl_in.c nl.pl layout.std \ ntpdc-opts.def ntpdc.1 ntpdc-opts.texi ntpdc-opts.menu -BUILT_SOURCES+= ntpdc-opts.c ntpdc-opts.h ntpdc.1 ntpdc-opts.texi \ - ntpdc-opts.menu -man_MANS= ntpdc.1 -run_ag= cd $(srcdir) && autogen -L ../include --writable +man_MANS= $(srcdir)/ntpdc.1 +noinst_DATA= $(srcdir)/ntpdc-opts.texi $(srcdir)/ntpdc-opts.menu +run_ag= cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" \ + autogen -L ../include --writable std_def_list= $(top_srcdir)/include/debug-opt.def \ $(top_srcdir)/include/autogen-version.def \ $(top_srcdir)/include/copyright.def \ @@ -27,13 +35,18 @@ $(top_srcdir)/include/version.def $(srcdir)/ntpdc-opts.h: $(srcdir)/ntpdc-opts.c + @: do-nothing action to avoid default SCCS get, .h built with .c + $(srcdir)/ntpdc-opts.c: $(srcdir)/ntpdc-opts.def $(std_def_list) $(run_ag) ntpdc-opts.def $(srcdir)/ntpdc.1: $(srcdir)/ntpdc-opts.def $(std_def_list) $(run_ag) -Tagman1.tpl -bntpdc ntpdc-opts.def -$(srcdir)/ntpdc-opts.texi $(srcdir)/ntpdc-opts.menu: $(srcdir)/ntpdc-opts.def $(std_def_list) +$(srcdir)/ntpdc-opts.menu: $(srcdir)/ntpdc-opts.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/ntpdc-opts.texi: $(srcdir)/ntpdc-opts.def $(std_def_list) $(run_ag) -Taginfo.tpl -DLEVEL=section ntpdc-opts.def ntpdc_SOURCES = ntpdc.c ntpdc_ops.c ntpdc-opts.c ntpdc-opts.h @@ -43,7 +56,7 @@ layout.here: ntpdc-layout ./ntpdc-layout > $@ -check-layout: ntpdc-layout layout.std layout.here +check-layout: ntpdc-layout $(srcdir)/layout.std layout.here cmp $(srcdir)/layout.std layout.here && echo stamp > $@ $(PROGRAMS): $(LDADD) @@ -60,7 +73,8 @@ # I ran nl_in.c (attached, to be installed into ntpdc) through # $(CC) -E nl_in.c | nl.pl > nl.c -nl.c: nl_in.c nl.pl Makefile.am +nl.c: nl_in.c nl.pl Makefile.am ../config.h ../include/ntp_request.h ntpdc.h $(CC) -E $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(srcdir)/nl_in.c | ./nl.pl > nl.c -include ../bincheck.mf +include $(top_srcdir)/bincheck.mf +include $(top_srcdir)/depsver.mf diff -urN src/contrib/ntp/ntpdc/Makefile.in src.ntp/contrib/ntp/ntpdc/Makefile.in --- src/contrib/ntp/ntpdc/Makefile.in 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpdc/Makefile.in 2010-07-09 04:21:34.000000000 +0200 @@ -20,6 +20,7 @@ # subdir to warn folks if there is another version there. + VPATH = @srcdir@ pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ @@ -39,16 +40,21 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -ANSI2KNR = ../util/ansi2knr -bin_PROGRAMS = ntpdc$(EXEEXT) +@NTP_BINSUBDIR_IS_BIN_TRUE@bin_PROGRAMS = ntpdc$(EXEEXT) +@NTP_BINSUBDIR_IS_BIN_FALSE@sbin_PROGRAMS = ntpdc$(EXEEXT) EXTRA_PROGRAMS = ntpdc-layout$(EXEEXT) -DIST_COMMON = README $(noinst_HEADERS) $(srcdir)/../bincheck.mf \ - $(srcdir)/Makefile.am $(srcdir)/Makefile.in $(srcdir)/nl.pl.in +DIST_COMMON = README $(noinst_HEADERS) $(srcdir)/Makefile.am \ + $(srcdir)/Makefile.in $(srcdir)/nl.pl.in \ + $(top_srcdir)/bincheck.mf $(top_srcdir)/depsver.mf subdir = ntpdc ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ + $(top_srcdir)/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/m4/ntp_openssl.m4 \ + $(top_srcdir)/m4/ntp_vpathhack.m4 \ $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ @@ -57,16 +63,17 @@ CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = nl.pl CONFIG_CLEAN_VPATH_FILES = -am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)" -PROGRAMS = $(bin_PROGRAMS) -am_ntpdc_OBJECTS = ntpdc$U.$(OBJEXT) ntpdc_ops$U.$(OBJEXT) \ - ntpdc-opts$U.$(OBJEXT) +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(sbindir)" \ + "$(DESTDIR)$(man1dir)" +PROGRAMS = $(bin_PROGRAMS) $(sbin_PROGRAMS) +am_ntpdc_OBJECTS = ntpdc.$(OBJEXT) ntpdc_ops.$(OBJEXT) \ + ntpdc-opts.$(OBJEXT) ntpdc_OBJECTS = $(am_ntpdc_OBJECTS) am__DEPENDENCIES_1 = ntpdc_DEPENDENCIES = version.o $(am__DEPENDENCIES_1) \ ../libntp/libntp.a ntpdc_layout_SOURCES = ntpdc-layout.c -ntpdc_layout_OBJECTS = ntpdc-layout$U.$(OBJEXT) +ntpdc_layout_OBJECTS = ntpdc-layout.$(OBJEXT) ntpdc_layout_DEPENDENCIES = DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) depcomp = $(SHELL) $(top_srcdir)/depcomp @@ -107,6 +114,7 @@ man1dir = $(mandir)/man1 NROFF = nroff MANS = $(man_MANS) +DATA = $(noinst_DATA) HEADERS = $(noinst_HEADERS) ETAGS = etags CTAGS = ctags @@ -114,7 +122,6 @@ ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -135,6 +142,7 @@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EF_LIBS = @EF_LIBS@ EF_PROGS = @EF_PROGS@ EGREP = @EGREP@ @@ -166,6 +174,7 @@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ @@ -182,18 +191,22 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ PATH_SEPARATOR = @PATH_SEPARATOR@ PATH_SH = @PATH_SH@ PROPDELAY = @PROPDELAY@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ VERSION = @VERSION@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ @@ -204,7 +217,7 @@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ -bindir = ${exec_prefix}/${BINSUBDIR} +bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ @@ -245,24 +258,33 @@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -AUTOMAKE_OPTIONS = ../util/ansi2knr +NULL = +AUTOMAKE_OPTIONS = EXTRA_DATA = check-layout -BUILT_SOURCES = @MAKE_CHECK_LAYOUT@ ntpdc-opts.c ntpdc-opts.h ntpdc.1 \ - ntpdc-opts.texi ntpdc-opts.menu -AM_CPPFLAGS = -I$(top_srcdir)/include $(LIBOPTS_CFLAGS) +BUILT_SOURCES = @MAKE_CHECK_LAYOUT@ ntpdc-opts.c ntpdc-opts.h \ + .deps-ver +AM_CPPFLAGS = -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/nothreads/include \ + -I$(top_srcdir)/lib/isc/unix/include $(LIBOPTS_CFLAGS) + # LDADD might need RESLIB and ADJLIB -ntpdc_LDADD = version.o @READLINE_LIBS@ $(LIBOPTS_LDADD) ../libntp/libntp.a +ntpdc_LDADD = version.o $(LIBOPTS_LDADD) ../libntp/libntp.a \ + @EDITLINE_LIBS@ @LCRYPTO@ + # ntpdc-layout doesn't need any additional libraries at all ntpdc_layout_LDADD = DISTCLEANFILES = .version version.c -CLEANFILES = check-layout layout.here nl.c ntpdc-layout +CLEANFILES = check-layout layout.here nl.c ntpdc-layout .deps-ver noinst_HEADERS = ntpdc.h ETAGS_ARGS = Makefile.am EXTRA_DIST = nl_in.c nl.pl layout.std \ ntpdc-opts.def ntpdc.1 ntpdc-opts.texi ntpdc-opts.menu -man_MANS = ntpdc.1 -run_ag = cd $(srcdir) && autogen -L ../include --writable +man_MANS = $(srcdir)/ntpdc.1 +noinst_DATA = $(srcdir)/ntpdc-opts.texi $(srcdir)/ntpdc-opts.menu +run_ag = cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" \ + autogen -L ../include --writable + std_def_list = $(top_srcdir)/include/debug-opt.def \ $(top_srcdir)/include/autogen-version.def \ $(top_srcdir)/include/copyright.def \ @@ -275,7 +297,7 @@ .SUFFIXES: .SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(srcdir)/../bincheck.mf $(am__configure_deps) +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/bincheck.mf $(top_srcdir)/depsver.mf $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -350,6 +372,49 @@ list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ echo " rm -f" $$list; \ rm -f $$list +install-sbinPROGRAMS: $(sbin_PROGRAMS) + @$(NORMAL_INSTALL) + test -z "$(sbindir)" || $(MKDIR_P) "$(DESTDIR)$(sbindir)" + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p || test -f $$p1; \ + then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-sbinPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(sbindir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(sbindir)" && rm -f $$files + +clean-sbinPROGRAMS: + @list='$(sbin_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list ntpdc$(EXEEXT): $(ntpdc_OBJECTS) $(ntpdc_DEPENDENCIES) @rm -f ntpdc$(EXEEXT) $(LINK) $(ntpdc_OBJECTS) $(ntpdc_LDADD) $(LIBS) @@ -362,16 +427,11 @@ distclean-compile: -rm -f *.tab.c -../util/ansi2knr: - $(am__cd) ../util && $(MAKE) $(AM_MAKEFLAGS) ./ansi2knr - -mostlyclean-kr: - -test "$U" = "" || rm -f *_.c -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdc$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdc-layout$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdc-opts$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdc_ops$U.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdc-layout.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdc-opts.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdc.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdc_ops.Po@am__quote@ .c.o: @am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @@ -393,17 +453,6 @@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< -ntpdc_.c: ntpdc.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntpdc.c; then echo $(srcdir)/ntpdc.c; else echo ntpdc.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntpdc-layout_.c: ntpdc-layout.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntpdc-layout.c; then echo $(srcdir)/ntpdc-layout.c; else echo ntpdc-layout.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntpdc-opts_.c: ntpdc-opts.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntpdc-opts.c; then echo $(srcdir)/ntpdc-opts.c; else echo ntpdc-opts.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntpdc_ops_.c: ntpdc_ops.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntpdc_ops.c; then echo $(srcdir)/ntpdc_ops.c; else echo ntpdc_ops.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntpdc_.$(OBJEXT) ntpdc_.lo ntpdc-layout_.$(OBJEXT) ntpdc-layout_.lo \ -ntpdc-opts_.$(OBJEXT) ntpdc-opts_.lo ntpdc_ops_.$(OBJEXT) \ -ntpdc_ops_.lo : $(ANSI2KNR) mostlyclean-libtool: -rm -f *.lo @@ -547,9 +596,9 @@ check-am: all-am check: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) check-am -all-am: Makefile $(PROGRAMS) $(MANS) $(HEADERS) +all-am: Makefile $(PROGRAMS) $(MANS) $(DATA) $(HEADERS) installdirs: - for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)"; do \ + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: $(BUILT_SOURCES) @@ -583,7 +632,8 @@ -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-am -clean-am: clean-binPROGRAMS clean-generic clean-libtool mostlyclean-am +clean-am: clean-binPROGRAMS clean-generic clean-libtool \ + clean-sbinPROGRAMS mostlyclean-am distclean: distclean-am -rm -rf ./$(DEPDIR) @@ -609,7 +659,7 @@ install-dvi-am: -install-exec-am: install-binPROGRAMS +install-exec-am: install-binPROGRAMS install-sbinPROGRAMS @$(NORMAL_INSTALL) $(MAKE) $(AM_MAKEFLAGS) install-exec-hook install-html: install-html-am @@ -639,7 +689,7 @@ mostlyclean: mostlyclean-am -mostlyclean-am: mostlyclean-compile mostlyclean-generic mostlyclean-kr \ +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am @@ -650,37 +700,43 @@ ps-am: -uninstall-am: uninstall-binPROGRAMS uninstall-man +uninstall-am: uninstall-binPROGRAMS uninstall-man \ + uninstall-sbinPROGRAMS uninstall-man: uninstall-man1 -.MAKE: ../util/ansi2knr all check install install-am install-exec-am \ - install-strip +.MAKE: all check install install-am install-exec-am install-strip .PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \ - clean-generic clean-libtool ctags distclean distclean-compile \ - distclean-generic distclean-libtool distclean-tags distdir dvi \ - dvi-am html html-am info info-am install install-am \ - install-binPROGRAMS install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-exec-hook \ - install-html install-html-am install-info install-info-am \ - install-man install-man1 install-pdf install-pdf-am install-ps \ - install-ps-am install-strip installcheck installcheck-am \ - installdirs maintainer-clean maintainer-clean-generic \ - mostlyclean mostlyclean-compile mostlyclean-generic \ - mostlyclean-kr mostlyclean-libtool pdf pdf-am ps ps-am tags \ - uninstall uninstall-am uninstall-binPROGRAMS uninstall-man \ - uninstall-man1 + clean-generic clean-libtool clean-sbinPROGRAMS ctags distclean \ + distclean-compile distclean-generic distclean-libtool \ + distclean-tags distdir dvi dvi-am html html-am info info-am \ + install install-am install-binPROGRAMS install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-exec-hook install-html install-html-am \ + install-info install-info-am install-man install-man1 \ + install-pdf install-pdf-am install-ps install-ps-am \ + install-sbinPROGRAMS install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-compile \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags uninstall uninstall-am uninstall-binPROGRAMS \ + uninstall-man uninstall-man1 uninstall-sbinPROGRAMS $(srcdir)/ntpdc-opts.h: $(srcdir)/ntpdc-opts.c + @: do-nothing action to avoid default SCCS get, .h built with .c + $(srcdir)/ntpdc-opts.c: $(srcdir)/ntpdc-opts.def $(std_def_list) $(run_ag) ntpdc-opts.def $(srcdir)/ntpdc.1: $(srcdir)/ntpdc-opts.def $(std_def_list) $(run_ag) -Tagman1.tpl -bntpdc ntpdc-opts.def -$(srcdir)/ntpdc-opts.texi $(srcdir)/ntpdc-opts.menu: $(srcdir)/ntpdc-opts.def $(std_def_list) +$(srcdir)/ntpdc-opts.menu: $(srcdir)/ntpdc-opts.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/ntpdc-opts.texi: $(srcdir)/ntpdc-opts.def $(std_def_list) $(run_ag) -Taginfo.tpl -DLEVEL=section ntpdc-opts.def ntpdc-layout.o: nl.c @@ -688,7 +744,7 @@ layout.here: ntpdc-layout ./ntpdc-layout > $@ -check-layout: ntpdc-layout layout.std layout.here +check-layout: ntpdc-layout $(srcdir)/layout.std layout.here cmp $(srcdir)/layout.std layout.here && echo stamp > $@ $(PROGRAMS): $(LDADD) @@ -705,20 +761,84 @@ # I ran nl_in.c (attached, to be installed into ntpdc) through # $(CC) -E nl_in.c | nl.pl > nl.c -nl.c: nl_in.c nl.pl Makefile.am +nl.c: nl_in.c nl.pl Makefile.am ../config.h ../include/ntp_request.h ntpdc.h $(CC) -E $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(srcdir)/nl_in.c | ./nl.pl > nl.c install-exec-hook: - @case ${BINSUBDIR} in \ - bin) ODIR=${exec_prefix}/sbin ;; \ - sbin) ODIR=${exec_prefix}/bin ;; \ - esac; \ - test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ + @case ${BINSUBDIR} in \ + bin) ODIR=${sbindir} ;; \ + sbin) ODIR=${bindir} ;; \ + esac; \ + test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ test ! -f $$ODIR/$$i || echo "*** $$i is also in $$ODIR!"; \ done # +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + ..) \ + cd .. && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + *) \ + echo 'Fatal: depsver.mf Automake fragment limited' \ + 'to immediate subdirectories.' && \ + echo "top_builddir: $(top_builddir)" && \ + echo "subdir: $(subdir)" && \ + exit 1 \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff -urN src/contrib/ntp/ntpdc/layout.std src.ntp/contrib/ntp/ntpdc/layout.std --- src/contrib/ntp/ntpdc/layout.std 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpdc/layout.std 2009-12-09 08:36:35.000000000 +0100 @@ -1,4 +1,4 @@ -sizeof(struct req_pkt) = 212 +sizeof(struct req_pkt) = 216 offsetof(rm_vn_mode) = 0 offsetof(auth_seq) = 1 offsetof(implementation) = 2 @@ -10,7 +10,7 @@ offsetof(keyid) = 192 offsetof(mac) = 196 -sizeof(struct req_pkt_tail) = 28 +sizeof(struct req_pkt_tail) = 32 offsetof(tstamp) = 0 offsetof(keyid) = 8 offsetof(mac) = 12 @@ -271,7 +271,7 @@ sizeof(struct info_monitor_1) = 72 offsetof(lasttime) = 0 offsetof(firsttime) = 4 -offsetof(lastdrop) = 8 +offsetof(restr) = 8 offsetof(count) = 12 offsetof(addr) = 16 offsetof(daddr) = 20 @@ -287,7 +287,7 @@ sizeof(struct info_monitor) = 48 offsetof(lasttime) = 0 offsetof(firsttime) = 4 -offsetof(lastdrop) = 8 +offsetof(restr) = 8 offsetof(count) = 12 offsetof(addr) = 16 offsetof(port) = 20 diff -urN src/contrib/ntp/ntpdc/ntpdc-opts.c src.ntp/contrib/ntp/ntpdc/ntpdc-opts.c --- src/contrib/ntp/ntpdc/ntpdc-opts.c 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpdc/ntpdc-opts.c 2010-07-09 04:24:08.000000000 +0200 @@ -1,11 +1,11 @@ /* * EDIT THIS FILE WITH CAUTION (ntpdc-opts.c) * - * It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:00 AM EST + * It has been AutoGen-ed July 9, 2010 at 02:24:09 AM by AutoGen 5.10 * From the definitions ntpdc-opts.def * and the template file options * - * Generated from AutoOpts 29:0:4 templates. + * Generated from AutoOpts 33:0:8 templates. */ /* @@ -19,13 +19,15 @@ * * This source file is copyrighted and licensed under the following terms: * - * ntpdc copyright 1970-2009 David L. Mills and/or others - all rights reserved + * ntpdc copyright (c) 1970-2010 David L. Mills and/or others - all rights reserved * * see html/copyright.html */ - +#include #include +#include +#include #define OPTION_CODE_COMPILE 1 #include "ntpdc-opts.h" @@ -33,12 +35,16 @@ #ifdef __cplusplus extern "C" { #endif + +/* TRANSLATORS: choose the translation for option names wisely because you + cannot ever change your mind. */ tSCC zCopyright[] = - "ntpdc copyright (c) 1970-2009 David L. Mills and/or others, all rights reserved"; -tSCC zCopyrightNotice[] = - + "ntpdc copyright (c) 1970-2010 David L. Mills and/or others, all rights reserved" /* extracted from ../include/copyright.def near line 8 */ +; +tSCC zCopyrightNotice[24] = "see html/copyright.html"; + extern tUsageProc optionUsage; /* @@ -59,22 +65,31 @@ #ifndef EXIT_FAILURE # define EXIT_FAILURE 1 #endif + /* - * Ipv4 option description: + * Ipv4 option description with + * "Must also have options" and "Incompatible options": */ tSCC zIpv4Text[] = "Force IPv4 DNS name resolution"; tSCC zIpv4_NAME[] = "IPV4"; tSCC zIpv4_Name[] = "ipv4"; +static const int + aIpv4CantList[] = { + INDEX_OPT_IPV6, NO_EQUIVALENT }; #define IPV4_FLAGS (OPTST_DISABLED) /* - * Ipv6 option description: + * Ipv6 option description with + * "Must also have options" and "Incompatible options": */ tSCC zIpv6Text[] = "Force IPv6 DNS name resolution"; tSCC zIpv6_NAME[] = "IPV6"; tSCC zIpv6_Name[] = "ipv6"; +static const int + aIpv6CantList[] = { + INDEX_OPT_IPV4, NO_EQUIVALENT }; #define IPV6_FLAGS (OPTST_DISABLED) /* @@ -145,25 +160,15 @@ /* * Debug_Level option description: */ -#ifdef DEBUG tSCC zDebug_LevelText[] = "Increase output debug message level"; tSCC zDebug_Level_NAME[] = "DEBUG_LEVEL"; tSCC zDebug_Level_Name[] = "debug-level"; #define DEBUG_LEVEL_FLAGS (OPTST_DISABLED) -#else /* disable Debug_Level */ -#define VALUE_OPT_DEBUG_LEVEL NO_EQUIVALENT -#define DEBUG_LEVEL_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zDebug_LevelText NULL -#define zDebug_Level_NAME NULL -#define zDebug_Level_Name NULL -#endif /* DEBUG */ - /* * Set_Debug_Level option description: */ -#ifdef DEBUG tSCC zSet_Debug_LevelText[] = "Set the output debug message level"; tSCC zSet_Debug_Level_NAME[] = "SET_DEBUG_LEVEL"; @@ -171,14 +176,6 @@ #define SET_DEBUG_LEVEL_FLAGS (OPTST_DISABLED \ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) -#else /* disable Set_Debug_Level */ -#define VALUE_OPT_SET_DEBUG_LEVEL NO_EQUIVALENT -#define SET_DEBUG_LEVEL_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zSet_Debug_LevelText NULL -#define zSet_Debug_Level_NAME NULL -#define zSet_Debug_Level_Name NULL -#endif /* DEBUG */ - /* * Numeric option description: */ @@ -191,35 +188,36 @@ /* * Help/More_Help/Version option descriptions: */ -tSCC zHelpText[] = "Display usage information and exit"; -tSCC zHelp_Name[] = "help"; - -tSCC zMore_HelpText[] = "Extended usage information passed thru pager"; -tSCC zMore_Help_Name[] = "more-help"; - -tSCC zVersionText[] = "Output version information and exit"; -tSCC zVersion_Name[] = "version"; +tSCC zHelpText[] = "Display extended usage information and exit"; +tSCC zHelp_Name[] = "help"; +#ifdef HAVE_WORKING_FORK +#define OPTST_MORE_HELP_FLAGS (OPTST_IMM | OPTST_NO_INIT) +tSCC zMore_Help_Name[] = "more-help"; +tSCC zMore_HelpText[] = "Extended usage information passed thru pager"; +#else +#define OPTST_MORE_HELP_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#define zMore_Help_Name NULL +#define zMore_HelpText NULL +#endif +#ifdef NO_OPTIONAL_OPT_ARGS +# define OPTST_VERSION_FLAGS OPTST_IMM | OPTST_NO_INIT +#else +# define OPTST_VERSION_FLAGS OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ + OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT +#endif -/* - * Save/Load_Opts option description: - */ +tSCC zVersionText[] = "Output version information and exit"; +tSCC zVersion_Name[] = "version"; tSCC zSave_OptsText[] = "Save the option state to a config file"; tSCC zSave_Opts_Name[] = "save-opts"; - tSCC zLoad_OptsText[] = "Load options from a config file"; tSCC zLoad_Opts_NAME[] = "LOAD_OPTS"; - tSCC zNotLoad_Opts_Name[] = "no-load-opts"; tSCC zNotLoad_Opts_Pfx[] = "no"; #define zLoad_Opts_Name (zNotLoad_Opts_Name + 3) /* * Declare option callback procedures */ -#ifdef DEBUG - static tOptProc doOptSet_Debug_Level; -#else /* not DEBUG */ -# define doOptSet_Debug_Level NULL -#endif /* def/not DEBUG */ #if defined(TEST_NTPDC_OPTS) /* * Under test, omit argument processing, or call optionStackArg, @@ -243,7 +241,7 @@ extern tOptProc optionPagedUsage, optionPrintVersion, optionStackArg; static tOptProc - doUsageOpt; + doOptSet_Debug_Level, doUsageOpt; /* * #define map the "normal" callout procs @@ -264,25 +262,25 @@ */ static tOptDesc optDesc[ OPTION_CT ] = { { /* entry idx, value */ 0, VALUE_OPT_IPV4, - /* equiv idx, value */ NO_EQUIVALENT, 0, + /* equiv idx, value */ 0, VALUE_OPT_IPV4, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ IPV4_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, + /* must/cannot opts */ NULL, aIpv4CantList, /* option proc */ NULL, /* desc, NAME, name */ zIpv4Text, zIpv4_NAME, zIpv4_Name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ 1, VALUE_OPT_IPV6, - /* equiv idx, value */ NOLIMIT, NOLIMIT, - /* equivalenced to */ INDEX_OPT_IPV4, + /* equiv idx, value */ 1, VALUE_OPT_IPV6, + /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ IPV6_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, + /* must/cannot opts */ NULL, aIpv6CantList, /* option proc */ NULL, /* desc, NAME, name */ zIpv6Text, zIpv6_NAME, zIpv6_Name, /* disablement strs */ NULL, NULL }, @@ -383,18 +381,11 @@ /* desc, NAME, name */ zNumericText, zNumeric_NAME, zNumeric_Name, /* disablement strs */ NULL, NULL }, -#ifdef NO_OPTIONAL_OPT_ARGS -# define VERSION_OPT_FLAGS OPTST_IMM | OPTST_NO_INIT -#else -# define VERSION_OPT_FLAGS OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ - OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT -#endif - { /* entry idx, value */ INDEX_OPT_VERSION, VALUE_OPT_VERSION, /* equiv idx value */ NO_EQUIVALENT, 0, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ VERSION_OPT_FLAGS, 0, + /* opt state flags */ OPTST_VERSION_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, @@ -402,7 +393,6 @@ /* desc, NAME, name */ zVersionText, NULL, zVersion_Name, /* disablement strs */ NULL, NULL }, -#undef VERSION_OPT_FLAGS { /* entry idx, value */ INDEX_OPT_HELP, VALUE_OPT_HELP, @@ -421,7 +411,7 @@ /* equiv idx value */ NO_EQUIVALENT, 0, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, 0, + /* opt state flags */ OPTST_MORE_HELP_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, @@ -446,7 +436,7 @@ /* equiv idx value */ NO_EQUIVALENT, 0, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, NOLIMIT, 0, - /* opt state flags */ OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) \ + /* opt state flags */ OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | OPTST_DISABLE_IMM, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, @@ -462,7 +452,7 @@ */ tSCC zPROGNAME[] = "NTPDC"; tSCC zUsageTitle[] = -"ntpdc - vendor-specific NTP query program - Ver. 4.2.4p8\n\ +"ntpdc - vendor-specific NTP query program - Ver. 4.2.6p2\n\ USAGE: %s [ - [] | --[{=| }] ]... [ host ...]\n"; tSCC zRcName[] = ".ntprc"; tSCC* apzHomeList[] = { @@ -490,7 +480,7 @@ ntpd's configuration file may also be specified at run time using\n\ [= prog-name =] .\n"; tSCC zFullVersion[] = NTPDC_FULL_VERSION; -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optcode.tpl near line 408 */ +/* extracted from /usr/local/gnu/share/autogen/optcode.tpl near line 495 */ #if defined(ENABLE_NLS) # define OPTPROC_BASE OPTPROC_TRANSLATE @@ -500,6 +490,9 @@ # define translate_option_strings NULL #endif /* ENABLE_NLS */ + +#define ntpdc_full_usage NULL +#define ntpdc_short_usage NULL tOptions ntpdcOptions = { OPTIONS_STRUCT_VERSION, 0, NULL, /* original argc + argv */ @@ -508,8 +501,7 @@ + OPTPROC_SHORTOPT + OPTPROC_LONGOPT + OPTPROC_NO_REQ_OPT - + OPTPROC_ENVIRON - + OPTPROC_HAS_IMMED ), + + OPTPROC_ENVIRON ), 0, NULL, /* current option index, current option */ NULL, NULL, zPROGNAME, zRcName, zCopyright, zCopyrightNotice, @@ -522,12 +514,14 @@ /* * Indexes to special options */ - { INDEX_OPT_MORE_HELP, - INDEX_OPT_SAVE_OPTS, - NO_EQUIVALENT /* index of '-#' option */, + { INDEX_OPT_MORE_HELP, /* more-help option index */ + INDEX_OPT_SAVE_OPTS, /* save option index */ + NO_EQUIVALENT, /* '-#' option index */ NO_EQUIVALENT /* index of default opt */ }, - 15 /* full option count */, 10 /* user option count */ + 15 /* full option count */, 10 /* user option count */, + ntpdc_full_usage, ntpdc_short_usage, + NULL, NULL }; /* @@ -538,45 +532,39 @@ tOptions* pOptions, tOptDesc* pOptDesc ) { + (void)pOptions; USAGE( EXIT_SUCCESS ); } #if ! defined(TEST_NTPDC_OPTS) -/* * * * * * * +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * For the set-debug-level option, when DEBUG is #define-d. + * For the set-debug-level option. */ -#ifdef DEBUG static void -doOptSet_Debug_Level( - tOptions* pOptions, - tOptDesc* pOptDesc ) +doOptSet_Debug_Level(tOptions* pOptions, tOptDesc* pOptDesc) { - /* extracted from ../include/debug-opt.def, line 29 */ + /* extracted from ../include/debug-opt.def, line 27 */ DESC(DEBUG_LEVEL).optOccCt = atoi( pOptDesc->pzLastArg ); } -#endif /* defined DEBUG */ - #endif /* defined(TEST_NTPDC_OPTS) */ - -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optmain.tpl near line 92 */ +/* extracted from /usr/local/gnu/share/autogen/optmain.tpl near line 109 */ #if defined(TEST_NTPDC_OPTS) /* TEST MAIN PROCEDURE: */ +extern void optionPutShell( tOptions* ); + int -main( int argc, char** argv ) +main(int argc, char** argv) { int res = EXIT_SUCCESS; (void)optionProcess( &ntpdcOptions, argc, argv ); - { - void optionPutShell( tOptions* ); - optionPutShell( &ntpdcOptions ); - } + optionPutShell( &ntpdcOptions ); return res; } #endif /* defined TEST_NTPDC_OPTS */ -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optcode.tpl near line 514 */ +/* extracted from /usr/local/gnu/share/autogen/optcode.tpl near line 627 */ #if ENABLE_NLS #include @@ -619,44 +607,45 @@ * Guard against re-translation. It won't work. The strings will have * been changed by the first pass through this code. One shot only. */ - if (option_usage_text.field_ct == 0) - return; - /* - * Do the translations. The first pointer follows the field count field. - * The field count field is the size of a pointer. - */ - { - char** ppz = (char**)(void*)&(option_usage_text); - int ix = option_usage_text.field_ct; + if (option_usage_text.field_ct != 0) { + + /* + * Do the translations. The first pointer follows the field count + * field. The field count field is the size of a pointer. + */ + tOptDesc* pOD = ntpdcOptions.pOptDesc; + char** ppz = (char**)(void*)&(option_usage_text); + int ix = option_usage_text.field_ct; do { ppz++; *ppz = AO_gettext(*ppz); } while (--ix > 0); + + COERSION(pzCopyright); + COERSION(pzCopyNotice); + COERSION(pzFullVersion); + COERSION(pzUsageTitle); + COERSION(pzExplain); + COERSION(pzDetail); + option_usage_text.field_ct = 0; + + for (ix = ntpdcOptions.optCt; ix > 0; ix--, pOD++) + coerce_it((void*)&(pOD->pzText)); } - option_usage_text.field_ct = 0; - { + if ((ntpdcOptions.fOptSet & OPTPROC_NXLAT_OPT_CFG) == 0) { tOptDesc* pOD = ntpdcOptions.pOptDesc; - int ix = ntpdcOptions.optCt; + int ix; - for (;;) { - pOD->pzText = AO_gettext(pOD->pzText); - pOD->pz_NAME = AO_gettext(pOD->pz_NAME); - pOD->pz_Name = AO_gettext(pOD->pz_Name); - pOD->pz_DisableName = AO_gettext(pOD->pz_DisableName); - pOD->pz_DisablePfx = AO_gettext(pOD->pz_DisablePfx); - if (--ix <= 0) - break; - pOD++; + for (ix = ntpdcOptions.optCt; ix > 0; ix--, pOD++) { + coerce_it((void*)&(pOD->pz_Name)); + coerce_it((void*)&(pOD->pz_DisableName)); + coerce_it((void*)&(pOD->pz_DisablePfx)); } + /* prevent re-translation */ + ntpdcOptions.fOptSet |= OPTPROC_NXLAT_OPT_CFG | OPTPROC_NXLAT_OPT; } - COERSION(pzCopyright); - COERSION(pzCopyNotice); - COERSION(pzFullVersion); - COERSION(pzUsageTitle); - COERSION(pzExplain); - COERSION(pzDetail); } #endif /* ENABLE_NLS */ diff -urN src/contrib/ntp/ntpdc/ntpdc-opts.def src.ntp/contrib/ntp/ntpdc/ntpdc-opts.def --- src/contrib/ntp/ntpdc/ntpdc-opts.def 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpdc/ntpdc-opts.def 2009-12-09 08:36:37.000000000 +0100 @@ -15,7 +15,7 @@ flag = { name = ipv4; value = 4; - equivalence = ipv4; + flags-cant = ipv6; descrip = "Force IPv4 DNS name resolution"; doc = <<- _EndOfDoc_ Force DNS resolution of following host names on the command line @@ -26,7 +26,7 @@ flag = { name = ipv6; value = 6; - equivalence = ipv4; + flags-cant = ipv4; descrip = "Force IPv6 DNS name resolution"; doc = <<- _EndOfDoc_ Force DNS resolution of following host names on the command line diff -urN src/contrib/ntp/ntpdc/ntpdc-opts.h src.ntp/contrib/ntp/ntpdc/ntpdc-opts.h --- src/contrib/ntp/ntpdc/ntpdc-opts.h 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpdc/ntpdc-opts.h 2010-07-09 04:24:08.000000000 +0200 @@ -1,11 +1,11 @@ /* * EDIT THIS FILE WITH CAUTION (ntpdc-opts.h) * - * It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:00 AM EST + * It has been AutoGen-ed July 9, 2010 at 02:24:08 AM by AutoGen 5.10 * From the definitions ntpdc-opts.def * and the template file options * - * Generated from AutoOpts 29:0:4 templates. + * Generated from AutoOpts 33:0:8 templates. */ /* @@ -19,7 +19,7 @@ * * This source file is copyrighted and licensed under the following terms: * - * ntpdc copyright 1970-2009 David L. Mills and/or others - all rights reserved + * ntpdc copyright (c) 1970-2010 David L. Mills and/or others - all rights reserved * * see html/copyright.html */ @@ -30,7 +30,7 @@ * "AutoOpts" chapter. Please refer to that doc for usage help. */ #ifndef AUTOOPTS_NTPDC_OPTS_H_GUARD -#define AUTOOPTS_NTPDC_OPTS_H_GUARD +#define AUTOOPTS_NTPDC_OPTS_H_GUARD 1 #include "config.h" #include @@ -41,7 +41,7 @@ * tolerable version is at least as old as what was current when the header * template was released. */ -#define AO_TEMPLATE_VERSION 118784 +#define AO_TEMPLATE_VERSION 135168 #if (AO_TEMPLATE_VERSION < OPTIONS_MINIMUM_VERSION) \ || (AO_TEMPLATE_VERSION > OPTIONS_STRUCT_VERSION) # error option template version mismatches autoopts/options.h header @@ -52,26 +52,26 @@ * Enumeration of each option: */ typedef enum { - INDEX_OPT_IPV4 = 0, - INDEX_OPT_IPV6 = 1, - INDEX_OPT_COMMAND = 2, - INDEX_OPT_LISTPEERS = 3, - INDEX_OPT_PEERS = 4, - INDEX_OPT_SHOWPEERS = 5, - INDEX_OPT_INTERACTIVE = 6, - INDEX_OPT_DEBUG_LEVEL = 7, - INDEX_OPT_SET_DEBUG_LEVEL = 8, - INDEX_OPT_NUMERIC = 9, - INDEX_OPT_VERSION = 10, - INDEX_OPT_HELP = 11, - INDEX_OPT_MORE_HELP = 12, - INDEX_OPT_SAVE_OPTS = 13, - INDEX_OPT_LOAD_OPTS = 14 + INDEX_OPT_IPV4 = 0, + INDEX_OPT_IPV6 = 1, + INDEX_OPT_COMMAND = 2, + INDEX_OPT_LISTPEERS = 3, + INDEX_OPT_PEERS = 4, + INDEX_OPT_SHOWPEERS = 5, + INDEX_OPT_INTERACTIVE = 6, + INDEX_OPT_DEBUG_LEVEL = 7, + INDEX_OPT_SET_DEBUG_LEVEL = 8, + INDEX_OPT_NUMERIC = 9, + INDEX_OPT_VERSION = 10, + INDEX_OPT_HELP = 11, + INDEX_OPT_MORE_HELP = 12, + INDEX_OPT_SAVE_OPTS = 13, + INDEX_OPT_LOAD_OPTS = 14 } teOptIndex; #define OPTION_CT 15 -#define NTPDC_VERSION "4.2.4p8" -#define NTPDC_FULL_VERSION "ntpdc - vendor-specific NTP query program - Ver. 4.2.4p8" +#define NTPDC_VERSION "4.2.6p2" +#define NTPDC_FULL_VERSION "ntpdc - vendor-specific NTP query program - Ver. 4.2.6p2" /* * Interface defines for all options. Replace "n" with the UPPER_CASED @@ -151,29 +151,23 @@ # undef NUMERIC #endif /* NO_OPTION_NAME_WARNINGS */ -/* +/* * * * * * + * * Interface defines for specific options. */ #define VALUE_OPT_IPV4 '4' -#define WHICH_OPT_IPV4 (DESC(IPV4).optActualValue) -#define WHICH_IDX_IPV4 (DESC(IPV4).optActualIndex) #define VALUE_OPT_IPV6 '6' #define VALUE_OPT_COMMAND 'c' #define VALUE_OPT_LISTPEERS 'l' #define VALUE_OPT_PEERS 'p' #define VALUE_OPT_SHOWPEERS 's' #define VALUE_OPT_INTERACTIVE 'i' -#ifdef DEBUG #define VALUE_OPT_DEBUG_LEVEL 'd' -#endif /* DEBUG */ -#ifdef DEBUG #define VALUE_OPT_SET_DEBUG_LEVEL 'D' -#endif /* DEBUG */ #define VALUE_OPT_NUMERIC 'n' - -#define VALUE_OPT_VERSION 'v' #define VALUE_OPT_HELP '?' #define VALUE_OPT_MORE_HELP '!' +#define VALUE_OPT_VERSION INDEX_OPT_VERSION #define VALUE_OPT_SAVE_OPTS '>' #define VALUE_OPT_LOAD_OPTS '<' #define SET_OPT_SAVE_OPTS(a) STMTS( \ @@ -190,7 +184,7 @@ ntpdcOptions.pzCurOpt = NULL ) #define START_OPT RESTART_OPT(1) #define USAGE(c) (*ntpdcOptions.pUsageProc)( &ntpdcOptions, c ) -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/opthead.tpl near line 360 */ +/* extracted from /usr/local/gnu/share/autogen/opthead.tpl near line 409 */ /* * * * * * * @@ -202,18 +196,37 @@ extern tOptions ntpdcOptions; -#ifndef _ -# if ENABLE_NLS -# include - static inline char* aoGetsText( char const* pz ) { - if (pz == NULL) return NULL; - return (char*)gettext( pz ); - } -# define _(s) aoGetsText(s) -# else /* ENABLE_NLS */ -# define _(s) s -# endif /* ENABLE_NLS */ -#endif +#if defined(ENABLE_NLS) +# ifndef _ +# include + static inline char* aoGetsText( char const* pz ) { + if (pz == NULL) return NULL; + return (char*)gettext( pz ); + } +# define _(s) aoGetsText(s) +# endif /* _() */ + +# define OPT_NO_XLAT_CFG_NAMES STMTS(ntpdcOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT_CFG;) +# define OPT_NO_XLAT_OPT_NAMES STMTS(ntpdcOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG;) + +# define OPT_XLAT_CFG_NAMES STMTS(ntpdcOptions.fOptSet &= \ + ~(OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG);) +# define OPT_XLAT_OPT_NAMES STMTS(ntpdcOptions.fOptSet &= \ + ~OPTPROC_NXLAT_OPT;) + +#else /* ENABLE_NLS */ +# define OPT_NO_XLAT_CFG_NAMES +# define OPT_NO_XLAT_OPT_NAMES + +# define OPT_XLAT_CFG_NAMES +# define OPT_XLAT_OPT_NAMES + +# ifndef _ +# define _(_s) _s +# endif +#endif /* ENABLE_NLS */ #ifdef __cplusplus } diff -urN src/contrib/ntp/ntpdc/ntpdc-opts.texi src.ntp/contrib/ntp/ntpdc/ntpdc-opts.texi --- src/contrib/ntp/ntpdc/ntpdc-opts.texi 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpdc/ntpdc-opts.texi 2010-07-09 04:24:18.000000000 +0200 @@ -6,7 +6,7 @@ # # EDIT THIS FILE WITH CAUTION (ntpdc-opts.texi) # -# It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:02 AM EST +# It has been AutoGen-ed July 9, 2010 at 02:24:18 AM by AutoGen 5.10 # From the definitions ntpdc-opts.def # and the template file aginfo.tpl @end ignore @@ -58,7 +58,7 @@ @exampleindent 0 @example -ntpdc - vendor-specific NTP query program - Ver. 4.2.5p247-RC +ntpdc - vendor-specific NTP query program - Ver. 4.2.6p2 USAGE: ntpdc [ - [] | --[@{=| @}] ]... [ host ...] Flg Arg Option-Name Description -4 no ipv4 Force IPv4 DNS name resolution @@ -101,7 +101,7 @@ or by a single hyphen and the flag character. The following option preset mechanisms are supported: - - reading file /users/stenn/.ntprc + - reading file /deacon/users/stenn/.ntprc - reading file /deacon/backroom/snaps/ntp-stable/ntpdc/.ntprc - examining environment variables named NTPDC_* @@ -135,7 +135,8 @@ This option has some usage constraints. It: @itemize @bullet @item -is a member of the ipv4 class of options. +must not appear in combination with any of the following options: +ipv6. @end itemize Force DNS resolution of following host names on the command line @@ -150,7 +151,8 @@ This option has some usage constraints. It: @itemize @bullet @item -is a member of the ipv4 class of options. +must not appear in combination with any of the following options: +ipv4. @end itemize Force DNS resolution of following host names on the command line @@ -246,8 +248,6 @@ @itemize @bullet @item may appear an unlimited number of times. -@item -must be compiled in by defining @code{DEBUG} during the compilation. @end itemize Increase the debugging message output level. @@ -262,8 +262,6 @@ @itemize @bullet @item may appear an unlimited number of times. -@item -must be compiled in by defining @code{DEBUG} during the compilation. @end itemize Set the output debugging level. Can be supplied multiple times, diff -urN src/contrib/ntp/ntpdc/ntpdc.1 src.ntp/contrib/ntp/ntpdc/ntpdc.1 --- src/contrib/ntp/ntpdc/ntpdc.1 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpdc/ntpdc.1 2010-07-09 04:24:17.000000000 +0200 @@ -1,7 +1,7 @@ -.TH NTPDC 1 2009-12-08 "( 4.2.4p8)" "Programmer's Manual" +.TH NTPDC 1 2010-07-09 "( 4.2.6p2)" "Programmer's Manual" .\" EDIT THIS FILE WITH CAUTION (ntpdc.1) .\" -.\" It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:01 AM EST +.\" It has been AutoGen-ed July 9, 2010 at 02:24:17 AM by AutoGen 5.10 .\" From the definitions ntpdc-opts.def .\" and the template file agman1.tpl .\" @@ -15,7 +15,7 @@ .in +8 [ host ...] .SH "DESCRIPTION" -This manual page documents, briefly, the \fBntpdc\fP command. +This manual page briefly documents the \fBntpdc\fP command. The [= prog-name =] utility program is used to query an NTP daemon about its @@ -38,14 +38,16 @@ .TP .BR \-4 ", " \--ipv4 Force IPv4 DNS name resolution. -This option is a member of the ipv4 class of options. +This option must not appear in combination with any of the following options: +ipv6. .sp Force DNS resolution of following host names on the command line to the IPv4 namespace. .TP .BR \-6 ", " \--ipv6 Force IPv6 DNS name resolution. -This option is a member of the ipv4 class of options. +This option must not appear in combination with any of the following options: +ipv4. .sp Force DNS resolution of following host names on the command line to the IPv6 namespace. @@ -110,7 +112,7 @@ converting to the canonical host names. .TP .BR \-? , " \--help" -Display usage information and exit. +Display extended usage information and exit. .TP .BR \-! , " \--more-help" Extended usage information passed thru pager. @@ -125,7 +127,7 @@ of earlier RC/INI files. \fI--no-load-opts\fP is handled early, out of order. .TP -.BR \-v " [{\fIv|c|n\fP}]," " \--version" "[=\fI{v|c|n}\fP]" +.BR \- " [{\fIv|c|n\fP}]," " \--version" "[=\fI{v|c|n}\fP]" Output version of program and exit. The default mode is `v', a simple version. The `c' mode will print copyright information and `n' will print the full copyright notice. @@ -136,7 +138,7 @@ .nf \fBNTPDC_\fP or \fBNTPDC\fP .fi -.aj +.ad The environmental presets take precedence (are processed later than) the configuration files. The \fIhomerc\fP files are "\fI$HOME\fP", and "\fI.\fP". diff -urN src/contrib/ntp/ntpdc/ntpdc.c src.ntp/contrib/ntp/ntpdc/ntpdc.c --- src/contrib/ntp/ntpdc/ntpdc.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpdc/ntpdc.c 2010-07-09 04:17:42.000000000 +0200 @@ -3,7 +3,7 @@ */ #include - +#include #include #include #include @@ -12,25 +12,19 @@ #include "ntp_select.h" #include "ntp_io.h" #include "ntp_stdlib.h" -/* Don't include ISC's version of IPv6 variables and structures */ -#define ISC_IPV6_H 1 +#include "ntp_assert.h" +#include "ntp_lineedit.h" #include "isc/net.h" #include "isc/result.h" +#include #include "ntpdc-opts.h" #ifdef SYS_WINNT # include # include -#else -# define closesocket close #endif /* SYS_WINNT */ -#if defined(HAVE_LIBREADLINE) || defined (HAVE_LIBEDIT) -# include -# include -#endif /* HAVE_LIBREADLINE || HAVE_LIBEDIT */ - #ifdef SYS_VXWORKS /* vxWorks needs mode flag -casey*/ # define open(name, flags) open(name, flags, 0777) @@ -56,12 +50,8 @@ static u_long info_auth_keyid; static int keyid_entered = 0; -/* - * Type of key md5 - */ -#define KEY_TYPE_MD5 4 - -static int info_auth_keytype = KEY_TYPE_MD5; /* MD5 */ +static int info_auth_keytype = NID_md5; /* MD5 */ +static size_t info_auth_hashlen = 16; /* MD5 */ u_long current_time; /* needed by authkeys; not used */ /* @@ -69,42 +59,42 @@ */ s_char sys_precision; /* local clock precision (log2 s) */ -int ntpdcmain P((int, char **)); +int ntpdcmain (int, char **); /* * Built in command handler declarations */ -static int openhost P((const char *)); -static int sendpkt P((char *, int)); -static void growpktdata P((void)); -static int getresponse P((int, int, int *, int *, char **, int)); -static int sendrequest P((int, int, int, int, int, char *)); -static void getcmds P((void)); -static RETSIGTYPE abortcmd P((int)); -static void docmd P((const char *)); -static void tokenize P((const char *, char **, int *)); -static int findcmd P((char *, struct xcmd *, struct xcmd *, struct xcmd **)); -static int getarg P((char *, int, arg_v *)); -static int getnetnum P((const char *, struct sockaddr_storage *, char *, int)); -static void help P((struct parse *, FILE *)); +static int openhost (const char *); +static int sendpkt (void *, size_t); +static void growpktdata (void); +static int getresponse (int, int, int *, int *, char **, int); +static int sendrequest (int, int, int, u_int, size_t, char *); +static void getcmds (void); +static RETSIGTYPE abortcmd (int); +static void docmd (const char *); +static void tokenize (const char *, char **, int *); +static int findcmd (char *, struct xcmd *, struct xcmd *, struct xcmd **); +static int getarg (char *, int, arg_v *); +static int getnetnum (const char *, sockaddr_u *, char *, int); +static void help (struct parse *, FILE *); #ifdef QSORT_USES_VOID_P -static int helpsort P((const void *, const void *)); +static int helpsort (const void *, const void *); #else -static int helpsort P((char **, char **)); +static int helpsort (char **, char **); #endif -static void printusage P((struct xcmd *, FILE *)); -static void timeout P((struct parse *, FILE *)); -static void my_delay P((struct parse *, FILE *)); -static void host P((struct parse *, FILE *)); -static void keyid P((struct parse *, FILE *)); -static void keytype P((struct parse *, FILE *)); -static void passwd P((struct parse *, FILE *)); -static void hostnames P((struct parse *, FILE *)); -static void setdebug P((struct parse *, FILE *)); -static void quit P((struct parse *, FILE *)); -static void version P((struct parse *, FILE *)); -static void warning P((const char *, const char *, const char *)); -static void error P((const char *, const char *, const char *)); -static u_long getkeyid P((const char *)); +static void printusage (struct xcmd *, FILE *); +static void timeout (struct parse *, FILE *); +static void my_delay (struct parse *, FILE *); +static void host (struct parse *, FILE *); +static void keyid (struct parse *, FILE *); +static void keytype (struct parse *, FILE *); +static void passwd (struct parse *, FILE *); +static void hostnames (struct parse *, FILE *); +static void setdebug (struct parse *, FILE *); +static void quit (struct parse *, FILE *); +static void version (struct parse *, FILE *); +static void warning (const char *, const char *, const char *); +static void error (const char *, const char *, const char *); +static u_long getkeyid (const char *); @@ -159,10 +149,10 @@ /* * Default values we use. */ +#define DEFHOST "localhost" /* default host name */ #define DEFTIMEOUT (5) /* 5 second time out */ #define DEFSTIMEOUT (2) /* 2 second time out after first */ #define DEFDELAY 0x51EB852 /* 20 milliseconds, l_fp fraction */ -#define DEFHOST "localhost" /* default host name */ #define LENHOSTNAME 256 /* host name is 256 characters long */ #define MAXCMDS 100 /* maximum commands on cmd line */ #define MAXHOSTS 200 /* maximum hosts on cmd line */ @@ -173,8 +163,8 @@ /* * Some variables used and manipulated locally */ -static struct timeval tvout = { DEFTIMEOUT, 0 }; /* time out for reads */ -static struct timeval tvsout = { DEFSTIMEOUT, 0 }; /* secondary time out */ +static struct sock_timeval tvout = { DEFTIMEOUT, 0 }; /* time out for reads */ +static struct sock_timeval tvsout = { DEFSTIMEOUT, 0 };/* secondary time out */ static l_fp delay_time; /* delay time */ static char currenthost[LENHOSTNAME]; /* current host name */ int showhostnames = 1; /* show host names by default */ @@ -185,18 +175,6 @@ static int havehost = 0; /* set to 1 when host open */ int s_port = 0; -#if defined (SYS_WINNT) || defined (SYS_VXWORKS) -char password[9]; -#endif /* SYS_WINNT || SYS_VXWORKS */ - -#ifdef SYS_WINNT -DWORD NumberOfBytesWritten; - -HANDLE TimerThreadHandle = NULL; /* 1998/06/03 - Used in ntplib/machines.c */ -void timer(void) { ; }; /* 1998/06/03 - Used in ntplib/machines.c */ - -#endif /* SYS_WINNT */ - /* * Holds data returned from queries. We allocate INITDATASIZE * octets to begin with, increasing this as we need to. @@ -306,18 +284,12 @@ taskPrioritySet(taskIdSelf(), 100 ); #endif -#ifdef SYS_WINNT - if (!Win32InitSockets()) - { - fprintf(stderr, "No useable winsock.dll:"); - exit(1); - } -#endif /* SYS_WINNT */ + init_lib(); /* sets up ipv4_works, ipv6_works */ + ssl_applink(); - /* Check to see if we have IPv6. Otherwise force the -4 flag */ - if (isc_net_probeipv6() != ISC_R_SUCCESS) { + /* Check to see if we have IPv6. Otherwise default to IPv4 */ + if (!ipv6_works) ai_fam_default = AF_INET; - } progname = argv[0]; @@ -327,17 +299,12 @@ argv += optct; } - switch (WHICH_IDX_IPV4) { - case INDEX_OPT_IPV4: + if (HAVE_OPT(IPV4)) ai_fam_templ = AF_INET; - break; - case INDEX_OPT_IPV6: + else if (HAVE_OPT(IPV6)) ai_fam_templ = AF_INET6; - break; - default: + else ai_fam_templ = ai_fam_default; - break; - } if (HAVE_OPT(COMMAND)) { int cmdct = STACKCT_OPT( COMMAND ); @@ -446,12 +413,8 @@ /* * Initialize the packet data buffer */ - pktdata = (char *)malloc(INITDATASIZE); - if (pktdata == NULL) { - (void) fprintf(stderr, "%s: malloc() failed!\n", progname); - exit(1); - } pktdatasize = INITDATASIZE; + pktdata = emalloc(INITDATASIZE); if (numcmds == 0) { (void) openhost(chosts[0]); @@ -499,10 +462,14 @@ if (*cp == '[') { cp++; - for(i = 0; *cp != ']'; cp++, i++) - name[i] = *cp; - name[i] = '\0'; - hname = name; + for (i = 0; *cp && *cp != ']'; cp++, i++) + name[i] = *cp; + if (*cp == ']') { + name[i] = '\0'; + hname = name; + } else { + return 0; + } } /* @@ -543,8 +510,14 @@ return 0; } + /* + * getaddrinfo() has returned without error so ai should not + * be NULL. + */ + NTP_INSIST(ai != NULL); + if (ai->ai_canonname == NULL) { - strncpy(temphost, stoa((struct sockaddr_storage *)ai->ai_addr), + strncpy(temphost, stoa((sockaddr_u *)ai->ai_addr), LENHOSTNAME); temphost[LENHOSTNAME-1] = '\0'; } else { @@ -619,8 +592,8 @@ ai->ai_addrlen) == -1) #endif /* SYS_VXWORKS */ error("connect", "", ""); - if (ai != NULL) - freeaddrinfo(ai); + + freeaddrinfo(ai); havehost = 1; req_pkt_size = REQ_LEN_NOMAC; impl_ver = IMPL_XNTPD; @@ -634,11 +607,11 @@ */ static int sendpkt( - char *xdata, - int xdatalen + void * xdata, + size_t xdatalen ) { - if (send(sockfd, xdata, (size_t)xdatalen, 0) == -1) { + if (send(sockfd, xdata, xdatalen, 0) == -1) { warning("write to %s failed", currenthost, ""); return -1; } @@ -654,11 +627,7 @@ growpktdata(void) { pktdatasize += INCDATASIZE; - pktdata = (char *)realloc(pktdata, (unsigned)pktdatasize); - if (pktdata == 0) { - (void) fprintf(stderr, "%s: realloc() failed!\n", progname); - exit(1); - } + pktdata = erealloc(pktdata, (size_t)pktdatasize); } @@ -676,7 +645,7 @@ ) { struct resp_pkt rpkt; - struct timeval tvo; + struct sock_timeval tvo; int items; int i; int size; @@ -710,9 +679,9 @@ again: if (firstpkt) - tvo = tvout; + tvo = tvout; else - tvo = tvsout; + tvo = tvsout; FD_SET(sockfd, &fds); n = select(sockfd+1, &fds, (fd_set *)0, (fd_set *)0, &tvo); @@ -823,11 +792,12 @@ pad = esize - size; else pad = 0; - if ((datasize = items*size) > (n-RESP_HEADER_SIZE)) { + datasize = items * size; + if ((size_t)datasize > (n-RESP_HEADER_SIZE)) { if (debug) printf( - "Received items %d, size %d (total %d), data in packet is %d\n", - items, size, datasize, n-RESP_HEADER_SIZE); + "Received items %d, size %d (total %d), data in packet is %lu\n", + items, size, datasize, (u_long)(n-RESP_HEADER_SIZE)); goto again; } @@ -869,7 +839,7 @@ if ((datap + datasize + (pad * items)) > (pktdata + pktdatasize)) { int offset = datap - pktdata; growpktdata(); - *rdata = pktdata; /* might have been realloced ! */ + *rdata = pktdata; /* might have been realloced ! */ datap = pktdata + offset; } /* @@ -877,9 +847,9 @@ * items. This is so we can play nice with older implementations */ - tmp_data = (char *)rpkt.data; - for(i = 0; i keyid > 0) - info_auth_keyid = ((struct conf_peer *)qpkt.data)->keyid; - else { - maclen = getkeyid("Keyid: "); - if (maclen == 0) { - (void) fprintf(stderr, - "Invalid key identifier\n"); - return 1; - } - info_auth_keyid = maclen; - } - } - if (!authistrusted(info_auth_keyid)) { - pass = getpass("MD5 Password: "); - if (*pass == '\0') { - (void) fprintf(stderr, - "Invalid password\n"); - return (1); - } + if (info_auth_keyid == 0) { + key_id = getkeyid("Keyid: "); + if (!key_id) { + fprintf(stderr, "Invalid key identifier\n"); + return 1; + } + info_auth_keyid = key_id; + } + if (!authistrusted(info_auth_keyid)) { + pass = getpass_keytype(info_auth_keytype); + if ('\0' == pass[0]) { + fprintf(stderr, "Invalid password\n"); + return 1; } - authusekey(info_auth_keyid, info_auth_keytype, (const u_char *)pass); + authusekey(info_auth_keyid, info_auth_keytype, + (u_char *)pass); authtrust(info_auth_keyid, 1); - qpkt.auth_seq = AUTH_SEQ(1, 0); - qpktail->keyid = htonl(info_auth_keyid); - get_systime(&ts); - L_ADD(&ts, &delay_time); - HTONL_FP(&ts, &qpktail->tstamp); - maclen = authencrypt(info_auth_keyid, (u_int32 *)&qpkt, - req_pkt_size); - if (maclen == 0) { - (void) fprintf(stderr, "Key not found\n"); - return (1); - } - return sendpkt((char *)&qpkt, (int)(req_pkt_size + maclen)); } - /*NOTREACHED*/ + qpkt.auth_seq = AUTH_SEQ(1, 0); + if (info_auth_hashlen > 16) { + /* + * Only ntpd which expects REQ_LEN_NOMAC plus maclen + * octets in an authenticated request using a 16 octet + * digest (that is, a newer ntpd) will handle digests + * larger than 16 octets, so for longer digests, do + * not attempt to shorten the requests for downlevel + * ntpd compatibility. + */ + if (REQ_LEN_NOMAC != req_pkt_size) + return 1; + reqsize = REQ_LEN_HDR + datasize + sizeof(*ptstamp); + /* align to 32 bits */ + reqsize = (reqsize + 3) & ~3; + } else + reqsize = req_pkt_size; + ptstamp = (void *)((char *)&qpkt + reqsize); + ptstamp--; + get_systime(&ts); + L_ADD(&ts, &delay_time); + HTONL_FP(&ts, ptstamp); + maclen = authencrypt(info_auth_keyid, (void *)&qpkt, reqsize); + if (!maclen) { + fprintf(stderr, "Key not found\n"); + return 1; + } else if (maclen != (info_auth_hashlen + sizeof(keyid_t))) { + fprintf(stderr, + "%d octet MAC, %lu expected with %lu octet digest\n", + maclen, (u_long)(info_auth_hashlen + sizeof(keyid_t)), + (u_long)info_auth_hashlen); + return 1; + } + return sendpkt(&qpkt, reqsize + maclen); } @@ -1007,7 +1011,7 @@ int res; char junk[512]; fd_set fds; - struct timeval tvzero; + struct sock_timeval tvzero; /* * Check to make sure host is open @@ -1041,7 +1045,7 @@ */ res = sendrequest(implcode, reqcode, auth, qitems, qsize, qdata); if (res != 0) - return res; + return res; /* * Get the response. If we got a standard error, print a message @@ -1079,36 +1083,36 @@ /* log error message if not told to be quiet */ if ((res > 0) && (((1 << res) & quiet_mask) == 0)) { switch(res) { - case INFO_ERR_IMPL: + case INFO_ERR_IMPL: /* Give us a chance to try the older implementation. */ if (implcode == IMPL_XNTPD) break; (void) fprintf(stderr, "***Server implementation incompatable with our own\n"); break; - case INFO_ERR_REQ: + case INFO_ERR_REQ: (void) fprintf(stderr, "***Server doesn't implement this request\n"); break; - case INFO_ERR_FMT: + case INFO_ERR_FMT: (void) fprintf(stderr, "***Server reports a format error in the received packet (shouldn't happen)\n"); break; - case INFO_ERR_NODATA: + case INFO_ERR_NODATA: (void) fprintf(stderr, "***Server reports data not found\n"); break; - case INFO_ERR_AUTH: + case INFO_ERR_AUTH: (void) fprintf(stderr, "***Permission denied\n"); break; - case ERR_TIMEOUT: + case ERR_TIMEOUT: (void) fprintf(stderr, "***Request timed out\n"); break; - case ERR_INCOMPLETE: + case ERR_INCOMPLETE: (void) fprintf(stderr, "***Response from server was incomplete\n"); break; - default: + default: (void) fprintf(stderr, "***Server returns unknown error code %d\n", res); break; @@ -1124,33 +1128,20 @@ static void getcmds(void) { -#if defined(HAVE_LIBREADLINE) || defined(HAVE_LIBEDIT) - char *line; + char * line; + int count; + + ntp_readline_init(interactive ? prompt : NULL); for (;;) { - if ((line = readline(interactive?prompt:"")) == NULL) return; - if (*line) add_history(line); + line = ntp_readline(&count); + if (NULL == line) + break; docmd(line); free(line); } -#else /* not (HAVE_LIBREADLINE || HAVE_LIBEDIT) */ - char line[MAXLINE]; - - for (;;) { - if (interactive) { -#ifdef VMS /* work around a problem with mixing stdout & stderr */ - fputs("",stdout); -#endif - (void) fputs(prompt, stderr); - (void) fflush(stderr); - } - if (fgets(line, sizeof line, stdin) == NULL) - return; - - docmd(line); - } -#endif /* not HAVE_LIBREADLINE || HAVE_LIBEDIT */ + ntp_readline_uninit(); } @@ -1482,7 +1473,7 @@ static int getnetnum( const char *hname, - struct sockaddr_storage *num, + sockaddr_u *num, char *fullhost, int af ) @@ -1490,9 +1481,7 @@ int sockaddr_len; struct addrinfo hints, *ai = NULL; - sockaddr_len = (af == AF_INET) - ? sizeof(struct sockaddr_in) - : sizeof(struct sockaddr_in6); + sockaddr_len = SIZEOF_SOCKADDR(af); memset((char *)&hints, 0, sizeof(struct addrinfo)); hints.ai_flags = AI_CANONNAME; #ifdef AI_ADDRCONFIG @@ -1502,7 +1491,7 @@ /* decodenetnum only works with addresses */ if (decodenetnum(hname, num)) { if (fullhost != 0) { - getnameinfo((struct sockaddr *)num, sockaddr_len, + getnameinfo(&num->sa, sockaddr_len, fullhost, sizeof(fullhost), NULL, 0, NI_NUMERICHOST); } @@ -1525,13 +1514,13 @@ */ char * nntohost( - struct sockaddr_storage *netnum + sockaddr_u *netnum ) { if (!showhostnames) - return stoa(netnum); + return stoa(netnum); - if ((netnum->ss_family == AF_INET) && ISREFCLOCKADR(netnum)) + if (ISREFCLOCKADR(netnum)) return refnumtoa(netnum); return socktohost(netnum); } @@ -1799,21 +1788,34 @@ FILE *fp ) { - if (pcmd->nargs == 0) - fprintf(fp, "keytype is %s\n", - (info_auth_keytype == KEY_TYPE_MD5) ? "MD5" : "???"); - else - switch (*(pcmd->argval[0].string)) { - case 'm': - case 'M': - info_auth_keytype = KEY_TYPE_MD5; - break; + const char * digest_name; + size_t digest_len; + int key_type; + + if (!pcmd->nargs) { + fprintf(fp, "keytype is %s with %lu octet digests\n", + keytype_name(info_auth_keytype), + (u_long)info_auth_hashlen); + return; + } - default: - fprintf(fp, "keytype must be 'md5'\n"); - } -} + digest_name = pcmd->argval[0].string; + digest_len = 0; + key_type = keytype_from_text(digest_name, &digest_len); + + if (!key_type) { + fprintf(fp, "keytype must be 'md5'%s\n", +#ifdef OPENSSL + " or a digest type provided by OpenSSL"); +#else + ""); +#endif + return; + } + info_auth_keytype = key_type; + info_auth_hashlen = digest_len; +} /* @@ -1840,7 +1842,7 @@ (u_char *)pcmd->argval[0].string); authtrust(info_auth_keyid, 1); } else { - pass = getpass("MD5 Password: "); + pass = getpass_keytype(info_auth_keytype); if (*pass == '\0') (void) fprintf(fp, "Password unchanged\n"); else { @@ -1982,7 +1984,7 @@ #ifndef SYS_WINNT if ((fi = fdopen(open("/dev/tty", 2), "r")) == NULL) #else - if ((fi = _fdopen((int)GetStdHandle(STD_INPUT_HANDLE), "r")) == NULL) + if ((fi = _fdopen(open("CONIN$", _O_TEXT), "r")) == NULL) #endif /* SYS_WINNT */ fi = stdin; else diff -urN src/contrib/ntp/ntpdc/ntpdc.h src.ntp/contrib/ntp/ntpdc/ntpdc.h --- src/contrib/ntp/ntpdc/ntpdc.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpdc/ntpdc.h 2010-07-09 04:17:42.000000000 +0200 @@ -34,7 +34,7 @@ char *string; long ival; u_long uval; - struct sockaddr_storage netnum; + sockaddr_u netnum; } arg_v; /* @@ -53,7 +53,7 @@ */ struct xcmd { const char *keyword; /* command key word */ - void (*handler) P((struct parse *, FILE *)); /* command handler */ + void (*handler) (struct parse *, FILE *); /* command handler */ u_char arg[MAXARGS]; /* descriptors for arguments */ const char *desc[MAXARGS]; /* descriptions for arguments */ const char *comment; @@ -63,5 +63,5 @@ extern int showhostnames; extern int s_port; -extern int doquery P((int, int, int, int, int, char *, int *, int *, char **, int, int)); -extern char * nntohost P((struct sockaddr_storage *)); +extern int doquery (int, int, int, int, int, char *, int *, int *, char **, int, int); +extern char * nntohost (sockaddr_u *); diff -urN src/contrib/ntp/ntpdc/ntpdc_ops.c src.ntp/contrib/ntp/ntpdc/ntpdc_ops.c --- src/contrib/ntp/ntpdc/ntpdc_ops.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpdc/ntpdc_ops.c 2010-07-09 04:17:42.000000000 +0200 @@ -1,5 +1,6 @@ /* - * ntpdc_ops.c - subroutines which are called to perform operations by xntpdc + * ntpdc_ops.c - subroutines which are called to perform operations by + * ntpdc */ #ifdef HAVE_CONFIG_H @@ -10,6 +11,7 @@ #include #include "ntpdc.h" +#include "ntp_net.h" #include "ntp_control.h" #include "ntp_refclock.h" #include "ntp_stdlib.h" @@ -19,67 +21,73 @@ # include #endif #if !defined(__bsdi__) && !defined(apollo) +#ifdef HAVE_NETINET_IN_H #include #endif +#endif #include /* + * utility functions + */ +static int checkitems (int, FILE *); +static int checkitemsize (int, int); +static int check1item (int, FILE *); + +/* * Declarations for command handlers in here */ -static int checkitems P((int, FILE *)); -static int checkitemsize P((int, int)); -static int check1item P((int, FILE *)); -static void peerlist P((struct parse *, FILE *)); -static void peers P((struct parse *, FILE *)); -static void doconfig P((struct parse *pcmd, FILE *fp, int mode, int refc)); -static void dmpeers P((struct parse *, FILE *)); -static void dopeers P((struct parse *, FILE *, int)); -static void printpeer P((struct info_peer *, FILE *)); -static void showpeer P((struct parse *, FILE *)); -static void peerstats P((struct parse *, FILE *)); -static void loopinfo P((struct parse *, FILE *)); -static void sysinfo P((struct parse *, FILE *)); -static void sysstats P((struct parse *, FILE *)); -static void iostats P((struct parse *, FILE *)); -static void memstats P((struct parse *, FILE *)); -static void timerstats P((struct parse *, FILE *)); -static void addpeer P((struct parse *, FILE *)); -static void addserver P((struct parse *, FILE *)); -static void addrefclock P((struct parse *, FILE *)); -static void broadcast P((struct parse *, FILE *)); -static void doconfig P((struct parse *, FILE *, int, int)); -static void unconfig P((struct parse *, FILE *)); -static void set P((struct parse *, FILE *)); -static void sys_clear P((struct parse *, FILE *)); -static void doset P((struct parse *, FILE *, int)); -static void reslist P((struct parse *, FILE *)); -static void new_restrict P((struct parse *, FILE *)); -static void unrestrict P((struct parse *, FILE *)); -static void delrestrict P((struct parse *, FILE *)); -static void do_restrict P((struct parse *, FILE *, int)); -static void monlist P((struct parse *, FILE *)); -static void reset P((struct parse *, FILE *)); -static void preset P((struct parse *, FILE *)); -static void readkeys P((struct parse *, FILE *)); -static void trustkey P((struct parse *, FILE *)); -static void untrustkey P((struct parse *, FILE *)); -static void do_trustkey P((struct parse *, FILE *, int)); -static void authinfo P((struct parse *, FILE *)); -static void traps P((struct parse *, FILE *)); -static void addtrap P((struct parse *, FILE *)); -static void clrtrap P((struct parse *, FILE *)); -static void do_addclr_trap P((struct parse *, FILE *, int)); -static void requestkey P((struct parse *, FILE *)); -static void controlkey P((struct parse *, FILE *)); -static void do_changekey P((struct parse *, FILE *, int)); -static void ctlstats P((struct parse *, FILE *)); -static void clockstat P((struct parse *, FILE *)); -static void fudge P((struct parse *, FILE *)); -static void clkbug P((struct parse *, FILE *)); -static void kerninfo P((struct parse *, FILE *)); -static void get_if_stats P((struct parse *, FILE *)); -static void do_if_reload P((struct parse *, FILE *)); +static void peerlist (struct parse *, FILE *); +static void peers (struct parse *, FILE *); +static void doconfig (struct parse *pcmd, FILE *fp, int mode, int refc); +static void dmpeers (struct parse *, FILE *); +static void dopeers (struct parse *, FILE *, int); +static void printpeer (struct info_peer *, FILE *); +static void showpeer (struct parse *, FILE *); +static void peerstats (struct parse *, FILE *); +static void loopinfo (struct parse *, FILE *); +static void sysinfo (struct parse *, FILE *); +static void sysstats (struct parse *, FILE *); +static void iostats (struct parse *, FILE *); +static void memstats (struct parse *, FILE *); +static void timerstats (struct parse *, FILE *); +static void addpeer (struct parse *, FILE *); +static void addserver (struct parse *, FILE *); +static void addrefclock (struct parse *, FILE *); +static void broadcast (struct parse *, FILE *); +static void doconfig (struct parse *, FILE *, int, int); +static void unconfig (struct parse *, FILE *); +static void set (struct parse *, FILE *); +static void sys_clear (struct parse *, FILE *); +static void doset (struct parse *, FILE *, int); +static void reslist (struct parse *, FILE *); +static void new_restrict (struct parse *, FILE *); +static void unrestrict (struct parse *, FILE *); +static void delrestrict (struct parse *, FILE *); +static void do_restrict (struct parse *, FILE *, int); +static void monlist (struct parse *, FILE *); +static void reset (struct parse *, FILE *); +static void preset (struct parse *, FILE *); +static void readkeys (struct parse *, FILE *); +static void trustkey (struct parse *, FILE *); +static void untrustkey (struct parse *, FILE *); +static void do_trustkey (struct parse *, FILE *, int); +static void authinfo (struct parse *, FILE *); +static void traps (struct parse *, FILE *); +static void addtrap (struct parse *, FILE *); +static void clrtrap (struct parse *, FILE *); +static void do_addclr_trap (struct parse *, FILE *, int); +static void requestkey (struct parse *, FILE *); +static void controlkey (struct parse *, FILE *); +static void do_changekey (struct parse *, FILE *, int); +static void ctlstats (struct parse *, FILE *); +static void clockstat (struct parse *, FILE *); +static void fudge (struct parse *, FILE *); +static void clkbug (struct parse *, FILE *); +static void kerninfo (struct parse *, FILE *); +static void get_if_stats (struct parse *, FILE *); +static void do_if_reload (struct parse *, FILE *); /* * Commands we understand. Ntpdc imports this. @@ -221,6 +229,84 @@ */ #define STREQ(a, b) (*(a) == *(b) && strcmp((a), (b)) == 0) +/* + * SET_SS_LEN_IF_PRESENT - used by SET_ADDR, SET_ADDRS macros + */ + +#ifdef ISC_PLATFORM_HAVESALEN +#define SET_SS_LEN_IF_PRESENT(psau) \ + do { \ + (psau)->sa.sa_len = SOCKLEN(psau); \ + } while (0) +#else +#define SET_SS_LEN_IF_PRESENT(psau) do { } while (0) +#endif + +/* + * SET_ADDR - setup address for v4/v6 as needed + */ +#define SET_ADDR(address, v6flag, v4addr, v6addr) \ +do { \ + memset(&(address), 0, sizeof(address)); \ + if (v6flag) { \ + AF(&(address)) = AF_INET6; \ + SOCK_ADDR6(&(address)) = (v6addr); \ + } else { \ + AF(&(address)) = AF_INET; \ + NSRCADR(&(address)) = (v4addr); \ + } \ + SET_SS_LEN_IF_PRESENT(&(address)); \ +} while (0) + + +/* + * SET_ADDRS - setup source and destination addresses for + * v4/v6 as needed + */ +#define SET_ADDRS(a1, a2, info, a1prefix, a2prefix) \ +do { \ + memset(&(a1), 0, sizeof(a1)); \ + memset(&(a2), 0, sizeof(a2)); \ + if ((info)->v6_flag) { \ + AF(&(a1)) = AF_INET6; \ + AF(&(a2)) = AF_INET6; \ + SOCK_ADDR6(&(a1)) = (info)->a1prefix##6; \ + SOCK_ADDR6(&(a2)) = (info)->a2prefix##6; \ + } else { \ + AF(&(a1)) = AF_INET; \ + AF(&(a2)) = AF_INET; \ + NSRCADR(&(a1)) = (info)->a1prefix; \ + NSRCADR(&(a2)) = (info)->a2prefix; \ + } \ + SET_SS_LEN_IF_PRESENT(&(a1)); \ + SET_SS_LEN_IF_PRESENT(&(a2)); \ +} while (0) + + +/* + * SET_ADDRS - setup source and destination addresses for + * v4/v6 as needed + */ +#if 0 +#define SET_ADDR_MASK(address, addrmask, info) \ +do { \ + memset(&(address), 0, sizeof(address)); \ + memset(&(mask), 0, sizeof(mask)); \ + if ((info)->v6_flag) { \ + AF(&(address)) = AF_INET6; \ + AF(&(addrmask)) = AF_INET6; \ + SOCK_ADDR6(&(address)) = (info)->addr6; \ + SOCK_ADDR6(&(addrmask)) = (info)->mask6; \ + } else { \ + AF(&(address)) = AF_INET; \ + AF(&(addrmask)) = AF_INET; \ + NSRCADR(&(address)) = (info)->addr; \ + NSRCADR(&(addrmask)) = (info)->mask; \ + } \ + SET_SS_LEN_IF_PRESENT(&(address)); \ + SET_SS_LEN_IF_PRESENT(&(addrmask)); \ +} while (0) +#endif /* * checkitems - utility to print a message if no items were returned @@ -280,7 +366,6 @@ } - /* * peerlist - get a short list of peers */ @@ -292,7 +377,7 @@ ) { struct info_peer_list *plist; - struct sockaddr_storage paddr; + sockaddr_u paddr; int items; int itemsize; int res; @@ -318,17 +403,7 @@ return; while (items > 0) { - memset((char *)&paddr, 0, sizeof(paddr)); - if (plist->v6_flag != 0) { - GET_INADDR6(paddr) = plist->addr6; - paddr.ss_family = AF_INET6; - } else { - GET_INADDR(paddr) = plist->addr; - paddr.ss_family = AF_INET; - } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - paddr.ss_len = SOCKLEN(&paddr); -#endif + SET_ADDR(paddr, plist->v6_flag, plist->addr, plist->addr6); if ((pcmd->nargs == 0) || ((pcmd->argval->ival == 6) && (plist->v6_flag != 0)) || ((pcmd->argval->ival == 4) && (plist->v6_flag == 0))) @@ -378,8 +453,8 @@ ) { struct info_peer_summary *plist; - struct sockaddr_storage dstadr; - struct sockaddr_storage srcadr; + sockaddr_u dstadr; + sockaddr_u srcadr; int items; int itemsize; int ntp_poll; @@ -440,23 +515,7 @@ NTOHL_FP(&(plist->offset), &tempts); ntp_poll = 1<ppoll, plist->hpoll, NTP_MAXPOLL), NTP_MINPOLL); - memset((char *)&dstadr, 0, sizeof(dstadr)); - memset((char *)&srcadr, 0, sizeof(srcadr)); - if (plist->v6_flag != 0) { - GET_INADDR6(dstadr) = plist->dstadr6; - GET_INADDR6(srcadr) = plist->srcadr6; - srcadr.ss_family = AF_INET6; - dstadr.ss_family = AF_INET6; - } else { - GET_INADDR(dstadr) = plist->dstadr; - GET_INADDR(srcadr) = plist->srcadr; - srcadr.ss_family = AF_INET; - dstadr.ss_family = AF_INET; - } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - srcadr.ss_len = SOCKLEN(&srcadr); - dstadr.ss_len = SOCKLEN(&dstadr); -#endif + SET_ADDRS(dstadr, srcadr, plist, dstadr, srcadr); if ((pcmd->nargs == 0) || ((pcmd->argval->ival == 6) && (plist->v6_flag != 0)) || ((pcmd->argval->ival == 4) && (plist->v6_flag == 0))) @@ -546,25 +605,10 @@ { register int i; l_fp tempts; - struct sockaddr_storage srcadr, dstadr; + sockaddr_u srcadr, dstadr; + + SET_ADDRS(dstadr, srcadr, pp, dstadr, srcadr); - memset((char *)&srcadr, 0, sizeof(srcadr)); - memset((char *)&dstadr, 0, sizeof(dstadr)); - if (pp->v6_flag != 0) { - srcadr.ss_family = AF_INET6; - dstadr.ss_family = AF_INET6; - GET_INADDR6(srcadr) = pp->srcadr6; - GET_INADDR6(dstadr) = pp->dstadr6; - } else { - srcadr.ss_family = AF_INET; - dstadr.ss_family = AF_INET; - GET_INADDR(srcadr) = pp->srcadr; - GET_INADDR(dstadr) = pp->dstadr; - } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - srcadr.ss_len = SOCKLEN(&srcadr); - dstadr.ss_len = SOCKLEN(&dstadr); -#endif (void) fprintf(fp, "remote %s, local %s\n", stoa(&srcadr), stoa(&dstadr)); (void) fprintf(fp, "hmode %s, pmode %s, stratum %d, precision %d\n", @@ -653,6 +697,7 @@ struct info_peer *pp; /* 4 is the maximum number of peers which will fit in a packet */ struct info_peer_list *pl, plist[min(MAXARGS, 4)]; + int qitemlim; int qitems; int items; int itemsize; @@ -665,9 +710,10 @@ else sendsize = v4sizeof(struct info_peer_list); - for (qitems = 0, pl = plist; qitems < min(pcmd->nargs, 4); qitems++) { - if (pcmd->argval[qitems].netnum.ss_family == AF_INET) { - pl->addr = GET_INADDR(pcmd->argval[qitems].netnum); + qitemlim = min(pcmd->nargs, COUNTOF(plist)); + for (qitems = 0, pl = plist; qitems < qitemlim; qitems++) { + if (IS_IPV4(&pcmd->argval[qitems].netnum)) { + pl->addr = NSRCADR(&pcmd->argval[qitems].netnum); if (impl_ver == IMPL_XNTPD) pl->v6_flag = 0; } else { @@ -676,7 +722,7 @@ "***Server doesn't understand IPv6 addresses\n"); return; } - pl->addr6 = GET_INADDR6(pcmd->argval[qitems].netnum); + pl->addr6 = SOCK_ADDR6(&pcmd->argval[qitems].netnum); pl->v6_flag = 1; } pl->port = (u_short)s_port; @@ -724,7 +770,8 @@ struct info_peer_stats *pp; /* 4 is the maximum number of peers which will fit in a packet */ struct info_peer_list *pl, plist[min(MAXARGS, 4)]; - struct sockaddr_storage src, dst; + sockaddr_u src, dst; + int qitemlim; int qitems; int items; int itemsize; @@ -737,10 +784,12 @@ else sendsize = v4sizeof(struct info_peer_list); - memset((char *)plist, 0, sizeof(struct info_peer_list) * min(MAXARGS, 4)); - for (qitems = 0, pl = plist; qitems < min(pcmd->nargs, 4); qitems++) { - if (pcmd->argval[qitems].netnum.ss_family == AF_INET) { - pl->addr = GET_INADDR(pcmd->argval[qitems].netnum); + memset(plist, 0, sizeof(plist)); + + qitemlim = min(pcmd->nargs, COUNTOF(plist)); + for (qitems = 0, pl = plist; qitems < qitemlim; qitems++) { + if (IS_IPV4(&pcmd->argval[qitems].netnum)) { + pl->addr = NSRCADR(&pcmd->argval[qitems].netnum); if (impl_ver == IMPL_XNTPD) pl->v6_flag = 0; } else { @@ -749,7 +798,7 @@ "***Server doesn't understand IPv6 addresses\n"); return; } - pl->addr6 = GET_INADDR6(pcmd->argval[qitems].netnum); + pl->addr6 = SOCK_ADDR6(&pcmd->argval[qitems].netnum); pl->v6_flag = 1; } pl->port = (u_short)s_port; @@ -778,22 +827,22 @@ return; while (items-- > 0) { - memset((char *)&src, 0, sizeof(src)); - memset((char *)&dst, 0, sizeof(dst)); + ZERO_SOCK(&dst); + ZERO_SOCK(&src); if (pp->v6_flag != 0) { - GET_INADDR6(src) = pp->srcadr6; - GET_INADDR6(dst) = pp->dstadr6; - src.ss_family = AF_INET6; - dst.ss_family = AF_INET6; + AF(&dst) = AF_INET6; + AF(&src) = AF_INET6; + SOCK_ADDR6(&dst) = pp->dstadr6; + SOCK_ADDR6(&src) = pp->srcadr6; } else { - GET_INADDR(src) = pp->srcadr; - GET_INADDR(dst) = pp->dstadr; - src.ss_family = AF_INET; - dst.ss_family = AF_INET; - } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - src.ss_len = SOCKLEN(&src); - dst.ss_len = SOCKLEN(&dst); + AF(&dst) = AF_INET; + AF(&src) = AF_INET; + NSRCADR(&dst) = pp->dstadr; + NSRCADR(&src) = pp->srcadr; + } +#ifdef ISC_PLATFORM_HAVESALEN + src.sa.sa_len = SOCKLEN(&src); + dst.sa.sa_len = SOCKLEN(&dst); #endif (void) fprintf(fp, "remote host: %s\n", nntohost(&src)); @@ -886,7 +935,7 @@ "offset %s, frequency %s, time_const %ld, watchdog %ld\n", lfptoa(&tempts, 6), lfptoa(&temp2ts, 3), - (long)(int32_t)ntohl((u_long)il->compliance), + (long)(int32)ntohl((u_long)il->compliance), (u_long)ntohl((u_long)il->watchdog_timer)); } else { NTOHL_FP(&il->last_offset, &tempts); @@ -896,7 +945,7 @@ (void) fprintf(fp, "frequency: %s ppm\n", lfptoa(&tempts, 3)); (void) fprintf(fp, "poll adjust: %ld\n", - (long)(int32_t)ntohl(il->compliance)); + (long)(int32)ntohl(il->compliance)); (void) fprintf(fp, "watchdog timer: %ld s\n", (u_long)ntohl(il->watchdog_timer)); } @@ -914,7 +963,7 @@ ) { struct info_sys *is; - struct sockaddr_storage peeraddr; + sockaddr_u peeraddr; int items; int itemsize; int res; @@ -940,17 +989,8 @@ !checkitemsize(itemsize, v4sizeof(struct info_sys))) return; - memset((char *)&peeraddr, 0, sizeof(peeraddr)); - if (is->v6_flag != 0) { - GET_INADDR6(peeraddr) = is->peer6; - peeraddr.ss_family = AF_INET6; - } else { - GET_INADDR(peeraddr) = is->peer; - peeraddr.ss_family = AF_INET; - } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - peeraddr.ss_len = SOCKLEN(&peeraddr); -#endif + SET_ADDR(peeraddr, is->v6_flag, is->peer, is->peer6); + (void) fprintf(fp, "system peer: %s\n", nntohost(&peeraddr)); (void) fprintf(fp, "system peer mode: %s\n", modetoa(is->peer_mode)); (void) fprintf(fp, "leap indicator: %c%c\n", @@ -1051,7 +1091,7 @@ (u_long)ntohl(ss->newversionpkt)); fprintf(fp, "previous version: %ld\n", (u_long)ntohl(ss->oldversionpkt)); - fprintf(fp, "bad version: %ld\n", + fprintf(fp, "declined: %ld\n", (u_long)ntohl(ss->unknownversion)); fprintf(fp, "access denied: %ld\n", (u_long)ntohl(ss->denied)); @@ -1292,7 +1332,7 @@ struct parse *pcmd, FILE *fp, int mode, - int refc + int refc ) { struct conf_peer cpeer; @@ -1319,7 +1359,7 @@ maxpoll = NTP_MAXDPOLL; numtyp = 1; if (refc) - numtyp = 5; + numtyp = 5; if (impl_ver == IMPL_XNTPD) sendsize = sizeof(struct conf_peer); @@ -1332,8 +1372,6 @@ flags |= CONF_FLAG_PREFER; else if (STREQ(pcmd->argval[items].string, "burst")) flags |= CONF_FLAG_BURST; - else if (STREQ(pcmd->argval[items].string, "dynamic")) - (void) fprintf(fp, "Warning: the \"dynamic\" keyword has been obsoleted and will be removed in the next release\n"); else if (STREQ(pcmd->argval[items].string, "iburst")) flags |= CONF_FLAG_IBURST; else if (!refc && STREQ(pcmd->argval[items].string, "keyid")) @@ -1408,10 +1446,10 @@ if (res) return; - memset((void *)&cpeer, 0, sizeof(cpeer)); + memset(&cpeer, 0, sizeof(cpeer)); - if (pcmd->argval[0].netnum.ss_family == AF_INET) { - cpeer.peeraddr = GET_INADDR(pcmd->argval[0].netnum); + if (IS_IPV4(&pcmd->argval[0].netnum)) { + cpeer.peeraddr = NSRCADR(&pcmd->argval[0].netnum); if (impl_ver == IMPL_XNTPD) cpeer.v6_flag = 0; } else { @@ -1420,7 +1458,7 @@ "***Server doesn't understand IPv6 addresses\n"); return; } - cpeer.peeraddr6 = GET_INADDR6(pcmd->argval[0].netnum); + cpeer.peeraddr6 = SOCK_ADDR6(&pcmd->argval[0].netnum); cpeer.v6_flag = 1; } cpeer.hmode = (u_char) mode; @@ -1465,6 +1503,7 @@ { /* 8 is the maximum number of peers which will fit in a packet */ struct conf_unpeer *pl, plist[min(MAXARGS, 8)]; + int qitemlim; int qitems; int items; int itemsize; @@ -1478,9 +1517,10 @@ else sendsize = v4sizeof(struct conf_unpeer); - for (qitems = 0, pl = plist; qitems < min(pcmd->nargs, 8); qitems++) { - if (pcmd->argval[0].netnum.ss_family == AF_INET) { - pl->peeraddr = GET_INADDR(pcmd->argval[qitems].netnum); + qitemlim = min(pcmd->nargs, COUNTOF(plist)); + for (qitems = 0, pl = plist; qitems < qitemlim; qitems++) { + if (IS_IPV4(&pcmd->argval[0].netnum)) { + pl->peeraddr = NSRCADR(&pcmd->argval[qitems].netnum); if (impl_ver == IMPL_XNTPD) pl->v6_flag = 0; } else { @@ -1490,7 +1530,7 @@ return; } pl->peeraddr6 = - GET_INADDR6(pcmd->argval[qitems].netnum); + SOCK_ADDR6(&pcmd->argval[qitems].netnum); pl->v6_flag = 1; } pl = (struct conf_unpeer *)((char *)pl + sendsize); @@ -1546,7 +1586,6 @@ int req ) { - /* 8 is the maximum number of peers which will fit in a packet */ struct conf_sys_flags sys; int items; int itemsize; @@ -1632,7 +1671,7 @@ { "lptrap", RES_LPTRAP }, { "limited", RES_LIMITED }, { "version", RES_VERSION }, - { "kod", RES_DEMOBILIZE }, + { "kod", RES_KOD }, { "timeout", RES_TIMEOUT }, { "", 0 } @@ -1656,8 +1695,8 @@ ) { struct info_restrict *rl; - struct sockaddr_storage resaddr; - struct sockaddr_storage maskaddr; + sockaddr_u resaddr; + sockaddr_u maskaddr; int items; int itemsize; int res; @@ -1697,27 +1736,12 @@ "=====================================================================\n"); while (items > 0) { - memset((char *)&resaddr, 0, sizeof(resaddr)); - memset((char *)&maskaddr, 0, sizeof(maskaddr)); + SET_ADDRS(resaddr, maskaddr, rl, addr, mask); if (rl->v6_flag != 0) { - GET_INADDR6(resaddr) = rl->addr6; - GET_INADDR6(maskaddr) = rl->mask6; - resaddr.ss_family = AF_INET6; - maskaddr.ss_family = AF_INET6; -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - resaddr.ss_len = SOCKLEN(&resaddr); -#endif addr = nntohost(&resaddr); } else { - GET_INADDR(resaddr) = rl->addr; - GET_INADDR(maskaddr) = rl->mask; - resaddr.ss_family = AF_INET; - maskaddr.ss_family = AF_INET; -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - resaddr.ss_len = SOCKLEN(&resaddr); -#endif if ((rl->mask == (u_int32)0xffffffff)) - addr = nntohost(&resaddr); + addr = nntohost(&resaddr); else addr = stoa(&resaddr); } @@ -1844,9 +1868,9 @@ else sendsize = v4sizeof(struct conf_restrict); - if (pcmd->argval[0].netnum.ss_family == AF_INET) { - cres.addr = GET_INADDR(pcmd->argval[0].netnum); - cres.mask = GET_INADDR(pcmd->argval[1].netnum); + if (IS_IPV4(&pcmd->argval[0].netnum)) { + cres.addr = NSRCADR(&pcmd->argval[0].netnum); + cres.mask = NSRCADR(&pcmd->argval[1].netnum); if (impl_ver == IMPL_XNTPD) cres.v6_flag = 0; } else { @@ -1855,7 +1879,7 @@ "***Server doesn't understand IPv6 addresses\n"); return; } - cres.addr6 = GET_INADDR6(pcmd->argval[0].netnum); + cres.addr6 = SOCK_ADDR6(&pcmd->argval[0].netnum); cres.v6_flag = 1; } cres.flags = 0; @@ -1892,7 +1916,7 @@ * Make sure mask for default address is zero. Otherwise, * make sure mask bits are contiguous. */ - if (pcmd->argval[0].netnum.ss_family == AF_INET) { + if (IS_IPV4(&pcmd->argval[0].netnum)) { if (cres.addr == 0) { cres.mask = 0; } else { @@ -1942,8 +1966,8 @@ ) { char *struct_star; - struct sockaddr_storage addr; - struct sockaddr_storage dstadr; + sockaddr_u addr; + sockaddr_u dstadr; int items; int itemsize; int res; @@ -1982,27 +2006,11 @@ struct info_monitor_1 *ml = (struct info_monitor_1 *) struct_star; (void) fprintf(fp, - "remote address port local address count m ver code avgint lstint\n"); + "remote address port local address count m ver rstr avgint lstint\n"); (void) fprintf(fp, "===============================================================================\n"); while (items > 0) { - memset((char *)&addr, 0, sizeof(addr)); - memset((char *)&dstadr, 0, sizeof(dstadr)); - if (ml->v6_flag != 0) { - GET_INADDR6(addr) = ml->addr6; - addr.ss_family = AF_INET6; - GET_INADDR6(dstadr) = ml->daddr6; - dstadr.ss_family = AF_INET6; - } else { - GET_INADDR(addr) = ml->addr; - addr.ss_family = AF_INET; - GET_INADDR(dstadr) = ml->daddr; - dstadr.ss_family = AF_INET; - } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - addr.ss_len = SOCKLEN(&addr); - dstadr.ss_len = SOCKLEN(&dstadr); -#endif + SET_ADDRS(dstadr, addr, ml, daddr, addr); if ((pcmd->nargs == 0) || ((pcmd->argval->ival == 6) && (ml->v6_flag != 0)) || ((pcmd->argval->ival == 4) && (ml->v6_flag == 0))) @@ -2014,7 +2022,7 @@ (u_long)ntohl(ml->count), ml->mode, ml->version, - (u_long)ntohl(ml->lastdrop), + (u_long)ntohl(ml->restr), (u_long)ntohl(ml->lasttime), (u_long)ntohl(ml->firsttime)); ml++; @@ -2025,21 +2033,11 @@ struct info_monitor *ml = (struct info_monitor *) struct_star; (void) fprintf(fp, - " address port count mode ver code avgint lstint\n"); + " address port count mode ver rstr avgint lstint\n"); (void) fprintf(fp, "===============================================================================\n"); while (items > 0) { - memset((char *)&dstadr, 0, sizeof(dstadr)); - if (ml->v6_flag != 0) { - GET_INADDR6(dstadr) = ml->addr6; - dstadr.ss_family = AF_INET6; - } else { - GET_INADDR(dstadr) = ml->addr; - dstadr.ss_family = AF_INET; - } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - dstadr.ss_len = SOCKLEN(&dstadr); -#endif + SET_ADDR(dstadr, ml->v6_flag, ml->addr, ml->addr6); if ((pcmd->nargs == 0) || ((pcmd->argval->ival == 6) && (ml->v6_flag != 0)) || ((pcmd->argval->ival == 4) && (ml->v6_flag == 0))) @@ -2050,7 +2048,7 @@ (u_long)ntohl(ml->count), ml->mode, ml->version, - (u_long)ntohl(ml->lastdrop), + (u_long)ntohl(ml->restr), (u_long)ntohl(ml->lasttime), (u_long)ntohl(ml->firsttime)); ml++; @@ -2063,17 +2061,7 @@ (void) fprintf(fp, "======================================================================\n"); while (items > 0) { - memset((char *)&dstadr, 0, sizeof(dstadr)); - if (oml->v6_flag != 0) { - GET_INADDR6(dstadr) = oml->addr6; - dstadr.ss_family = AF_INET6; - } else { - GET_INADDR(dstadr) = oml->addr; - dstadr.ss_family = AF_INET; - } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - dstadr.ss_len = SOCKLEN(&dstadr); -#endif + SET_ADDR(dstadr, oml->v6_flag, oml->addr, oml->addr6); (void) fprintf(fp, "%-20.20s %5d %9ld %4d %3d %9lu %9lu\n", nntohost(&dstadr), ntohs(oml->port), @@ -2175,6 +2163,7 @@ { /* 8 is the maximum number of peers which will fit in a packet */ struct conf_unpeer *pl, plist[min(MAXARGS, 8)]; + int qitemlim; int qitems; int items; int itemsize; @@ -2188,9 +2177,10 @@ else sendsize = v4sizeof(struct conf_unpeer); - for (qitems = 0, pl = plist; qitems < min(pcmd->nargs, 8); qitems++) { - if (pcmd->argval[qitems].netnum.ss_family == AF_INET) { - pl->peeraddr = GET_INADDR(pcmd->argval[qitems].netnum); + qitemlim = min(pcmd->nargs, COUNTOF(plist)); + for (qitems = 0, pl = plist; qitems < qitemlim; qitems++) { + if (IS_IPV4(&pcmd->argval[qitems].netnum)) { + pl->peeraddr = NSRCADR(&pcmd->argval[qitems].netnum); if (impl_ver == IMPL_XNTPD) pl->v6_flag = 0; } else { @@ -2200,7 +2190,7 @@ return; } pl->peeraddr6 = - GET_INADDR6(pcmd->argval[qitems].netnum); + SOCK_ADDR6(&pcmd->argval[qitems].netnum); pl->v6_flag = 1; } pl = (struct conf_unpeer *)((char *)pl + sendsize); @@ -2384,7 +2374,7 @@ { int i; struct info_trap *it; - struct sockaddr_storage trap_addr, local_addr; + sockaddr_u trap_addr, local_addr; int items; int itemsize; int res; @@ -2412,23 +2402,7 @@ for (i = 0; i < items; i++ ) { if (i != 0) (void) fprintf(fp, "\n"); - memset((char *)&trap_addr, 0, sizeof(trap_addr)); - memset((char *)&local_addr, 0, sizeof(local_addr)); - if (it->v6_flag != 0) { - GET_INADDR6(trap_addr) = it->trap_address6; - GET_INADDR6(local_addr) = it->local_address6; - trap_addr.ss_family = AF_INET6; - local_addr.ss_family = AF_INET6; - } else { - GET_INADDR(trap_addr) = it->trap_address; - GET_INADDR(local_addr) = it->local_address; - trap_addr.ss_family = AF_INET; - local_addr.ss_family = AF_INET; - } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - trap_addr.ss_len = SOCKLEN(&trap_addr); - local_addr.ss_len = SOCKLEN(&local_addr); -#endif + SET_ADDRS(trap_addr, local_addr, it, trap_address, local_address); (void) fprintf(fp, "address %s, port %d\n", stoa(&trap_addr), ntohs(it->trap_port)); @@ -2502,8 +2476,8 @@ else sendsize = v4sizeof(struct conf_trap); - if (pcmd->argval[0].netnum.ss_family == AF_INET) { - ctrap.trap_address = GET_INADDR(pcmd->argval[0].netnum); + if (IS_IPV4(&pcmd->argval[0].netnum)) { + ctrap.trap_address = NSRCADR(&pcmd->argval[0].netnum); if (impl_ver == IMPL_XNTPD) ctrap.v6_flag = 0; } else { @@ -2512,7 +2486,7 @@ "***Server doesn't understand IPv6 addresses\n"); return; } - ctrap.trap_address6 = GET_INADDR6(pcmd->argval[0].netnum); + ctrap.trap_address6 = SOCK_ADDR6(&pcmd->argval[0].netnum); ctrap.v6_flag = 1; } ctrap.local_address = 0; @@ -2520,19 +2494,18 @@ ctrap.unused = 0; if (pcmd->nargs > 1) { - ctrap.trap_port - = htons((u_short)(pcmd->argval[1].uval & 0xffff)); + ctrap.trap_port = htons((u_short)pcmd->argval[1].uval); if (pcmd->nargs > 2) { - if (pcmd->argval[2].netnum.ss_family != - pcmd->argval[0].netnum.ss_family) { + if (AF(&pcmd->argval[2].netnum) != + AF(&pcmd->argval[0].netnum)) { fprintf(stderr, "***Cannot mix IPv4 and IPv6 addresses\n"); return; } - if (pcmd->argval[2].netnum.ss_family == AF_INET) - ctrap.local_address = GET_INADDR(pcmd->argval[2].netnum); + if (IS_IPV4(&pcmd->argval[2].netnum)) + ctrap.local_address = NSRCADR(&pcmd->argval[2].netnum); else - ctrap.local_address6 = GET_INADDR6(pcmd->argval[2].netnum); + ctrap.local_address6 = SOCK_ADDR6(&pcmd->argval[2].netnum); } } @@ -2694,6 +2667,7 @@ struct info_clock *cl; /* 8 is the maximum number of clocks which will fit in a packet */ u_long clist[min(MAXARGS, 8)]; + int qitemlim; int qitems; int items; int itemsize; @@ -2701,8 +2675,9 @@ l_fp ts; struct clktype *clk; - for (qitems = 0; qitems < min(pcmd->nargs, 8); qitems++) - clist[qitems] = GET_INADDR(pcmd->argval[qitems].netnum); + qitemlim = min(pcmd->nargs, COUNTOF(clist)); + for (qitems = 0; qitems < qitemlim; qitems++) + clist[qitems] = NSRCADR(&pcmd->argval[qitems].netnum); again: res = doquery(impl_ver, REQ_GET_CLOCKINFO, 0, qitems, @@ -2715,13 +2690,13 @@ } if (res != 0) - return; + return; if (!checkitems(items, fp)) - return; + return; if (!checkitemsize(itemsize, sizeof(struct info_clock))) - return; + return; while (items-- > 0) { (void) fprintf(fp, "clock address: %s\n", @@ -2791,7 +2766,7 @@ err = 0; memset((char *)&fudgedata, 0, sizeof fudgedata); - fudgedata.clockadr = GET_INADDR(pcmd->argval[0].netnum); + fudgedata.clockadr = NSRCADR(&pcmd->argval[0].netnum); if (STREQ(pcmd->argval[1].string, "time1")) { fudgedata.which = htonl(FUDGE_TIME1); @@ -2866,6 +2841,7 @@ /* 8 is the maximum number of clocks which will fit in a packet */ u_long clist[min(MAXARGS, 8)]; u_int32 ltemp; + int qitemlim; int qitems; int items; int itemsize; @@ -2873,8 +2849,9 @@ int needsp; l_fp ts; - for (qitems = 0; qitems < min(pcmd->nargs, 8); qitems++) - clist[qitems] = GET_INADDR(pcmd->argval[qitems].netnum); + qitemlim = min(pcmd->nargs, COUNTOF(clist)); + for (qitems = 0; qitems < qitemlim; qitems++) + clist[qitems] = NSRCADR(&pcmd->argval[qitems].netnum); again: res = doquery(impl_ver, REQ_GET_CLKBUGINFO, 0, qitems, @@ -2887,13 +2864,13 @@ } if (res != 0) - return; + return; if (!checkitems(items, fp)) - return; + return; if (!checkitemsize(itemsize, sizeof(struct info_clkbug))) - return; + return; while (items-- > 0) { (void) fprintf(fp, "clock address: %s\n", @@ -2990,7 +2967,7 @@ tscale = 1e-9; #endif (void)fprintf(fp, "pll offset: %g s\n", - (int32_t)ntohl(ik->offset) * tscale); + (int32)ntohl(ik->offset) * tscale); (void)fprintf(fp, "pll frequency: %s ppm\n", fptoa((s_fp)ntohl(ik->freq), 3)); (void)fprintf(fp, "maximum error: %g s\n", @@ -3082,11 +3059,11 @@ (u_long)ntohl(ik->errcnt)); } -#define IF_LIST_FMT "%2d %c %48s %c %c %12.12s %03x %3d %2d %5d %5d %5d %2d %2d %3d %7d\n" -#define IF_LIST_FMT_STR "%2s %c %48s %c %c %12.12s %3s %3s %2s %5s %5s %5s %2s %2s %3s %7s\n" +#define IF_LIST_FMT "%2d %c %48s %c %c %12.12s %03x %3d %2d %5d %5d %5d %2d %3d %7d\n" +#define IF_LIST_FMT_STR "%2s %c %48s %c %c %12.12s %3s %3s %2s %5s %5s %5s %2s %3s %7s\n" #define IF_LIST_AFMT_STR " %48s %c\n" -#define IF_LIST_LABELS "#", 'A', "Address/Mask/Broadcast", 'T', 'E', "IF name", "Flg", "TL", "#M", "recv", "sent", "drop", "S", "IX", "PC", "uptime" -#define IF_LIST_LINE "=====================================================================================================================\n" +#define IF_LIST_LABELS "#", 'A', "Address/Mask/Broadcast", 'T', 'E', "IF name", "Flg", "TL", "#M", "recv", "sent", "drop", "S", "PC", "uptime" +#define IF_LIST_LINE "==================================================================================================================\n" static void iflist( @@ -3098,7 +3075,7 @@ ) { static char *actions = "?.+-"; - struct sockaddr_storage saddr; + sockaddr_u saddr; if (res != 0) return; @@ -3113,16 +3090,8 @@ fprintf(fp, IF_LIST_LINE); while (items > 0) { - if (ntohl(ifs->v6_flag)) { - memcpy((char *)&GET_INADDR6(saddr), (char *)&ifs->unaddr.addr6, sizeof(ifs->unaddr.addr6)); - saddr.ss_family = AF_INET6; - } else { - memcpy((char *)&GET_INADDR(saddr), (char *)&ifs->unaddr.addr, sizeof(ifs->unaddr.addr)); - saddr.ss_family = AF_INET; - } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - saddr.ss_len = SOCKLEN(&saddr); -#endif + SET_ADDR(saddr, ntohl(ifs->v6_flag), + ifs->unaddr.addr.s_addr, ifs->unaddr.addr6); fprintf(fp, IF_LIST_FMT, ntohl(ifs->ifnum), actions[(ifs->action >= 1 && ifs->action < 4) ? ifs->action : 0], @@ -3136,28 +3105,16 @@ ntohl(ifs->sent), ntohl(ifs->notsent), ntohl(ifs->scopeid), - ntohl(ifs->ifindex), ntohl(ifs->peercnt), ntohl(ifs->uptime)); - if (ntohl(ifs->v6_flag)) { - memcpy((char *)&GET_INADDR6(saddr), (char *)&ifs->unmask.addr6, sizeof(ifs->unmask.addr6)); - saddr.ss_family = AF_INET6; - } else { - memcpy((char *)&GET_INADDR(saddr), (char *)&ifs->unmask.addr, sizeof(ifs->unmask.addr)); - saddr.ss_family = AF_INET; - } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - saddr.ss_len = SOCKLEN(&saddr); -#endif + SET_ADDR(saddr, ntohl(ifs->v6_flag), + ifs->unmask.addr.s_addr, ifs->unmask.addr6); fprintf(fp, IF_LIST_AFMT_STR, stoa(&saddr), 'M'); if (!ntohl(ifs->v6_flag) && ntohl(ifs->flags) & (INT_BCASTOPEN)) { - memcpy((char *)&GET_INADDR(saddr), (char *)&ifs->unbcast.addr, sizeof(ifs->unbcast.addr)); - saddr.ss_family = AF_INET; -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - saddr.ss_len = SOCKLEN(&saddr); -#endif + SET_ADDR(saddr, ntohl(ifs->v6_flag), + ifs->unbcast.addr.s_addr, ifs->unbcast.addr6); fprintf(fp, IF_LIST_AFMT_STR, stoa(&saddr), 'B'); } diff -urN src/contrib/ntp/ntpq/Makefile.am src.ntp/contrib/ntp/ntpq/Makefile.am --- src/contrib/ntp/ntpq/Makefile.am 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpq/Makefile.am 2010-04-20 23:50:13.000000000 +0200 @@ -1,17 +1,31 @@ -AUTOMAKE_OPTIONS= ../util/ansi2knr +NULL= +AUTOMAKE_OPTIONS= +if NTP_BINSUBDIR_IS_BIN bin_PROGRAMS= ntpq -AM_CPPFLAGS= -I$(top_srcdir)/include $(LIBOPTS_CFLAGS) +else +sbin_PROGRAMS= ntpq +endif + +AM_CPPFLAGS= -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/nothreads/include \ + -I$(top_srcdir)/lib/isc/unix/include $(LIBOPTS_CFLAGS) # LDADD might need RESLIB and ADJLIB -ntpq_LDADD= version.o @READLINE_LIBS@ $(LIBOPTS_LDADD) ../libntp/libntp.a -DISTCLEANFILES= .version version.c +ntpq_LDADD= version.o $(LIBOPTS_LDADD) ../libntp/libntp.a \ + @EDITLINE_LIBS@ @LCRYPTO@ noinst_HEADERS= ntpq.h +noinst_LIBRARIES= libntpq.a +libntpq_a_CFLAGS= -DNO_MAIN_ALLOWED -DBUILD_AS_LIB +CLEANFILES= +DISTCLEANFILES= .version version.c ETAGS_ARGS= Makefile.am EXTRA_DIST= ntpq-opts.def ntpq.1 ntpq-opts.texi ntpq-opts.menu -BUILT_SOURCES= ntpq-opts.c ntpq-opts.h ntpq.1 ntpq-opts.texi ntpq-opts.menu -man_MANS= ntpq.1 -run_ag= cd $(srcdir) && autogen -L ../include --writable +BUILT_SOURCES= ntpq-opts.c ntpq-opts.h +man_MANS= $(srcdir)/ntpq.1 +noinst_DATA= $(srcdir)/ntpq-opts.texi $(srcdir)/ntpq-opts.menu +run_ag= cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" \ + autogen -L ../include --writable std_def_list= $(top_srcdir)/include/debug-opt.def \ $(top_srcdir)/include/autogen-version.def \ $(top_srcdir)/include/copyright.def \ @@ -19,14 +33,21 @@ $(top_srcdir)/include/version.def ntpq_SOURCES= ntpq.c ntpq-subs.c ntpq-opts.c ntpq-opts.h +libntpq_a_SOURCES = libntpq.c libntpq.h libntpq_subs.c + $(srcdir)/ntpq-opts.h: $(srcdir)/ntpq-opts.c + @: do-nothing action to avoid default SCCS get, .h built with .c + $(srcdir)/ntpq-opts.c: $(srcdir)/ntpq-opts.def $(std_def_list) $(run_ag) ntpq-opts.def $(srcdir)/ntpq.1: $(srcdir)/ntpq-opts.def $(std_def_list) $(run_ag) -Tagman1.tpl -bntpq ntpq-opts.def -$(srcdir)/ntpq-opts.texi $(srcdir)/ntpq-opts.menu: $(srcdir)/ntpq-opts.def $(std_def_list) +$(srcdir)/ntpq-opts.menu: $(srcdir)/ntpq-opts.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/ntpq-opts.texi: $(srcdir)/ntpq-opts.def $(std_def_list) $(run_ag) -Taginfo.tpl -DLEVEL=section ntpq-opts.def $(PROGRAMS): $(LDADD) @@ -40,3 +61,6 @@ version.o: $(ntpq_OBJECTS) ../libntp/libntp.a Makefile $(top_srcdir)/version env CSET=`cat $(top_srcdir)/version` $(top_builddir)/scripts/mkver ntpq $(COMPILE) -c version.c + +include $(top_srcdir)/bincheck.mf +include $(top_srcdir)/depsver.mf diff -urN src/contrib/ntp/ntpq/Makefile.in src.ntp/contrib/ntp/ntpq/Makefile.in --- src/contrib/ntp/ntpq/Makefile.in 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpq/Makefile.in 2010-07-09 04:21:35.000000000 +0200 @@ -15,6 +15,12 @@ @SET_MAKE@ +# we traditionally installed software in bindir, while it should have gone +# in sbindir. Now that we offer a choice, look in the "other" installation +# subdir to warn folks if there is another version there. + + + VPATH = @srcdir@ pkgdatadir = $(datadir)/@PACKAGE@ @@ -35,15 +41,20 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -ANSI2KNR = ../util/ansi2knr -bin_PROGRAMS = ntpq$(EXEEXT) -subdir = ntpq +@NTP_BINSUBDIR_IS_BIN_TRUE@bin_PROGRAMS = ntpq$(EXEEXT) +@NTP_BINSUBDIR_IS_BIN_FALSE@sbin_PROGRAMS = ntpq$(EXEEXT) DIST_COMMON = README $(noinst_HEADERS) $(srcdir)/Makefile.am \ - $(srcdir)/Makefile.in + $(srcdir)/Makefile.in $(top_srcdir)/bincheck.mf \ + $(top_srcdir)/depsver.mf +subdir = ntpq ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ + $(top_srcdir)/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/m4/ntp_openssl.m4 \ + $(top_srcdir)/m4/ntp_vpathhack.m4 \ $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ @@ -52,10 +63,18 @@ CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = -am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)" -PROGRAMS = $(bin_PROGRAMS) -am_ntpq_OBJECTS = ntpq$U.$(OBJEXT) ntpq-subs$U.$(OBJEXT) \ - ntpq-opts$U.$(OBJEXT) +LIBRARIES = $(noinst_LIBRARIES) +ARFLAGS = cru +libntpq_a_AR = $(AR) $(ARFLAGS) +libntpq_a_LIBADD = +am_libntpq_a_OBJECTS = libntpq_a-libntpq.$(OBJEXT) \ + libntpq_a-libntpq_subs.$(OBJEXT) +libntpq_a_OBJECTS = $(am_libntpq_a_OBJECTS) +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(sbindir)" \ + "$(DESTDIR)$(man1dir)" +PROGRAMS = $(bin_PROGRAMS) $(sbin_PROGRAMS) +am_ntpq_OBJECTS = ntpq.$(OBJEXT) ntpq-subs.$(OBJEXT) \ + ntpq-opts.$(OBJEXT) ntpq_OBJECTS = $(am_ntpq_OBJECTS) am__DEPENDENCIES_1 = ntpq_DEPENDENCIES = version.o $(am__DEPENDENCIES_1) ../libntp/libntp.a @@ -72,8 +91,8 @@ LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ $(LDFLAGS) -o $@ -SOURCES = $(ntpq_SOURCES) -DIST_SOURCES = $(ntpq_SOURCES) +SOURCES = $(libntpq_a_SOURCES) $(ntpq_SOURCES) +DIST_SOURCES = $(libntpq_a_SOURCES) $(ntpq_SOURCES) am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ @@ -98,6 +117,7 @@ man1dir = $(mandir)/man1 NROFF = nroff MANS = $(man_MANS) +DATA = $(noinst_DATA) HEADERS = $(noinst_HEADERS) ETAGS = etags CTAGS = ctags @@ -105,7 +125,6 @@ ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -126,6 +145,7 @@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EF_LIBS = @EF_LIBS@ EF_PROGS = @EF_PROGS@ EGREP = @EGREP@ @@ -157,6 +177,7 @@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ @@ -173,18 +194,22 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ PATH_SEPARATOR = @PATH_SEPARATOR@ PATH_SH = @PATH_SH@ PROPDELAY = @PROPDELAY@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ VERSION = @VERSION@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ @@ -236,18 +261,30 @@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -AUTOMAKE_OPTIONS = ../util/ansi2knr -AM_CPPFLAGS = -I$(top_srcdir)/include $(LIBOPTS_CFLAGS) +NULL = +AUTOMAKE_OPTIONS = +AM_CPPFLAGS = -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/nothreads/include \ + -I$(top_srcdir)/lib/isc/unix/include $(LIBOPTS_CFLAGS) + # LDADD might need RESLIB and ADJLIB -ntpq_LDADD = version.o @READLINE_LIBS@ $(LIBOPTS_LDADD) ../libntp/libntp.a -DISTCLEANFILES = .version version.c +ntpq_LDADD = version.o $(LIBOPTS_LDADD) ../libntp/libntp.a \ + @EDITLINE_LIBS@ @LCRYPTO@ + noinst_HEADERS = ntpq.h +noinst_LIBRARIES = libntpq.a +libntpq_a_CFLAGS = -DNO_MAIN_ALLOWED -DBUILD_AS_LIB +CLEANFILES = .deps-ver +DISTCLEANFILES = .version version.c ETAGS_ARGS = Makefile.am EXTRA_DIST = ntpq-opts.def ntpq.1 ntpq-opts.texi ntpq-opts.menu -BUILT_SOURCES = ntpq-opts.c ntpq-opts.h ntpq.1 ntpq-opts.texi ntpq-opts.menu -man_MANS = ntpq.1 -run_ag = cd $(srcdir) && autogen -L ../include --writable +BUILT_SOURCES = ntpq-opts.c ntpq-opts.h .deps-ver +man_MANS = $(srcdir)/ntpq.1 +noinst_DATA = $(srcdir)/ntpq-opts.texi $(srcdir)/ntpq-opts.menu +run_ag = cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" \ + autogen -L ../include --writable + std_def_list = $(top_srcdir)/include/debug-opt.def \ $(top_srcdir)/include/autogen-version.def \ $(top_srcdir)/include/copyright.def \ @@ -255,12 +292,13 @@ $(top_srcdir)/include/version.def ntpq_SOURCES = ntpq.c ntpq-subs.c ntpq-opts.c ntpq-opts.h +libntpq_a_SOURCES = libntpq.c libntpq.h libntpq_subs.c all: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/bincheck.mf $(top_srcdir)/depsver.mf $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -290,6 +328,13 @@ $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): + +clean-noinstLIBRARIES: + -test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES) +libntpq.a: $(libntpq_a_OBJECTS) $(libntpq_a_DEPENDENCIES) + -rm -f libntpq.a + $(libntpq_a_AR) libntpq.a $(libntpq_a_OBJECTS) $(libntpq_a_LIBADD) + $(RANLIB) libntpq.a install-binPROGRAMS: $(bin_PROGRAMS) @$(NORMAL_INSTALL) test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)" @@ -333,6 +378,49 @@ list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ echo " rm -f" $$list; \ rm -f $$list +install-sbinPROGRAMS: $(sbin_PROGRAMS) + @$(NORMAL_INSTALL) + test -z "$(sbindir)" || $(MKDIR_P) "$(DESTDIR)$(sbindir)" + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p || test -f $$p1; \ + then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-sbinPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(sbindir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(sbindir)" && rm -f $$files + +clean-sbinPROGRAMS: + @list='$(sbin_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list ntpq$(EXEEXT): $(ntpq_OBJECTS) $(ntpq_DEPENDENCIES) @rm -f ntpq$(EXEEXT) $(LINK) $(ntpq_OBJECTS) $(ntpq_LDADD) $(LIBS) @@ -342,15 +430,12 @@ distclean-compile: -rm -f *.tab.c -../util/ansi2knr: - $(am__cd) ../util && $(MAKE) $(AM_MAKEFLAGS) ./ansi2knr - -mostlyclean-kr: - -test "$U" = "" || rm -f *_.c -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpq$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpq-opts$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpq-subs$U.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libntpq_a-libntpq.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libntpq_a-libntpq_subs.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpq-opts.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpq-subs.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpq.Po@am__quote@ .c.o: @am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @@ -372,14 +457,34 @@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< -ntpq_.c: ntpq.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntpq.c; then echo $(srcdir)/ntpq.c; else echo ntpq.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntpq-opts_.c: ntpq-opts.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntpq-opts.c; then echo $(srcdir)/ntpq-opts.c; else echo ntpq-opts.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntpq-subs_.c: ntpq-subs.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntpq-subs.c; then echo $(srcdir)/ntpq-subs.c; else echo ntpq-subs.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntpq_.$(OBJEXT) ntpq_.lo ntpq-opts_.$(OBJEXT) ntpq-opts_.lo \ -ntpq-subs_.$(OBJEXT) ntpq-subs_.lo : $(ANSI2KNR) + +libntpq_a-libntpq.o: libntpq.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libntpq_a_CFLAGS) $(CFLAGS) -MT libntpq_a-libntpq.o -MD -MP -MF $(DEPDIR)/libntpq_a-libntpq.Tpo -c -o libntpq_a-libntpq.o `test -f 'libntpq.c' || echo '$(srcdir)/'`libntpq.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/libntpq_a-libntpq.Tpo $(DEPDIR)/libntpq_a-libntpq.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='libntpq.c' object='libntpq_a-libntpq.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libntpq_a_CFLAGS) $(CFLAGS) -c -o libntpq_a-libntpq.o `test -f 'libntpq.c' || echo '$(srcdir)/'`libntpq.c + +libntpq_a-libntpq.obj: libntpq.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libntpq_a_CFLAGS) $(CFLAGS) -MT libntpq_a-libntpq.obj -MD -MP -MF $(DEPDIR)/libntpq_a-libntpq.Tpo -c -o libntpq_a-libntpq.obj `if test -f 'libntpq.c'; then $(CYGPATH_W) 'libntpq.c'; else $(CYGPATH_W) '$(srcdir)/libntpq.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/libntpq_a-libntpq.Tpo $(DEPDIR)/libntpq_a-libntpq.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='libntpq.c' object='libntpq_a-libntpq.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libntpq_a_CFLAGS) $(CFLAGS) -c -o libntpq_a-libntpq.obj `if test -f 'libntpq.c'; then $(CYGPATH_W) 'libntpq.c'; else $(CYGPATH_W) '$(srcdir)/libntpq.c'; fi` + +libntpq_a-libntpq_subs.o: libntpq_subs.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libntpq_a_CFLAGS) $(CFLAGS) -MT libntpq_a-libntpq_subs.o -MD -MP -MF $(DEPDIR)/libntpq_a-libntpq_subs.Tpo -c -o libntpq_a-libntpq_subs.o `test -f 'libntpq_subs.c' || echo '$(srcdir)/'`libntpq_subs.c +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/libntpq_a-libntpq_subs.Tpo $(DEPDIR)/libntpq_a-libntpq_subs.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='libntpq_subs.c' object='libntpq_a-libntpq_subs.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libntpq_a_CFLAGS) $(CFLAGS) -c -o libntpq_a-libntpq_subs.o `test -f 'libntpq_subs.c' || echo '$(srcdir)/'`libntpq_subs.c + +libntpq_a-libntpq_subs.obj: libntpq_subs.c +@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libntpq_a_CFLAGS) $(CFLAGS) -MT libntpq_a-libntpq_subs.obj -MD -MP -MF $(DEPDIR)/libntpq_a-libntpq_subs.Tpo -c -o libntpq_a-libntpq_subs.obj `if test -f 'libntpq_subs.c'; then $(CYGPATH_W) 'libntpq_subs.c'; else $(CYGPATH_W) '$(srcdir)/libntpq_subs.c'; fi` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/libntpq_a-libntpq_subs.Tpo $(DEPDIR)/libntpq_a-libntpq_subs.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='libntpq_subs.c' object='libntpq_a-libntpq_subs.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libntpq_a_CFLAGS) $(CFLAGS) -c -o libntpq_a-libntpq_subs.obj `if test -f 'libntpq_subs.c'; then $(CYGPATH_W) 'libntpq_subs.c'; else $(CYGPATH_W) '$(srcdir)/libntpq_subs.c'; fi` mostlyclean-libtool: -rm -f *.lo @@ -523,9 +628,9 @@ check-am: all-am check: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) check-am -all-am: Makefile $(PROGRAMS) $(MANS) $(HEADERS) +all-am: Makefile $(LIBRARIES) $(PROGRAMS) $(MANS) $(DATA) $(HEADERS) installdirs: - for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)"; do \ + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: $(BUILT_SOURCES) @@ -546,6 +651,7 @@ mostlyclean-generic: clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) @@ -558,7 +664,8 @@ -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-am -clean-am: clean-binPROGRAMS clean-generic clean-libtool mostlyclean-am +clean-am: clean-binPROGRAMS clean-generic clean-libtool \ + clean-noinstLIBRARIES clean-sbinPROGRAMS mostlyclean-am distclean: distclean-am -rm -rf ./$(DEPDIR) @@ -584,8 +691,9 @@ install-dvi-am: -install-exec-am: install-binPROGRAMS - +install-exec-am: install-binPROGRAMS install-sbinPROGRAMS + @$(NORMAL_INSTALL) + $(MAKE) $(AM_MAKEFLAGS) install-exec-hook install-html: install-html-am install-html-am: @@ -613,7 +721,7 @@ mostlyclean: mostlyclean-am -mostlyclean-am: mostlyclean-compile mostlyclean-generic mostlyclean-kr \ +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am @@ -624,36 +732,43 @@ ps-am: -uninstall-am: uninstall-binPROGRAMS uninstall-man +uninstall-am: uninstall-binPROGRAMS uninstall-man \ + uninstall-sbinPROGRAMS uninstall-man: uninstall-man1 -.MAKE: ../util/ansi2knr all check install install-am install-strip +.MAKE: all check install install-am install-exec-am install-strip .PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \ - clean-generic clean-libtool ctags distclean distclean-compile \ + clean-generic clean-libtool clean-noinstLIBRARIES \ + clean-sbinPROGRAMS ctags distclean distclean-compile \ distclean-generic distclean-libtool distclean-tags distdir dvi \ dvi-am html html-am info info-am install install-am \ install-binPROGRAMS install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-info install-info-am install-man \ - install-man1 install-pdf install-pdf-am install-ps \ - install-ps-am install-strip installcheck installcheck-am \ - installdirs maintainer-clean maintainer-clean-generic \ - mostlyclean mostlyclean-compile mostlyclean-generic \ - mostlyclean-kr mostlyclean-libtool pdf pdf-am ps ps-am tags \ - uninstall uninstall-am uninstall-binPROGRAMS uninstall-man \ - uninstall-man1 + install-dvi-am install-exec install-exec-am install-exec-hook \ + install-html install-html-am install-info install-info-am \ + install-man install-man1 install-pdf install-pdf-am install-ps \ + install-ps-am install-sbinPROGRAMS install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-compile \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags uninstall uninstall-am uninstall-binPROGRAMS \ + uninstall-man uninstall-man1 uninstall-sbinPROGRAMS $(srcdir)/ntpq-opts.h: $(srcdir)/ntpq-opts.c + @: do-nothing action to avoid default SCCS get, .h built with .c + $(srcdir)/ntpq-opts.c: $(srcdir)/ntpq-opts.def $(std_def_list) $(run_ag) ntpq-opts.def $(srcdir)/ntpq.1: $(srcdir)/ntpq-opts.def $(std_def_list) $(run_ag) -Tagman1.tpl -bntpq ntpq-opts.def -$(srcdir)/ntpq-opts.texi $(srcdir)/ntpq-opts.menu: $(srcdir)/ntpq-opts.def $(std_def_list) +$(srcdir)/ntpq-opts.menu: $(srcdir)/ntpq-opts.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/ntpq-opts.texi: $(srcdir)/ntpq-opts.def $(std_def_list) $(run_ag) -Taginfo.tpl -DLEVEL=section ntpq-opts.def $(PROGRAMS): $(LDADD) @@ -668,6 +783,82 @@ env CSET=`cat $(top_srcdir)/version` $(top_builddir)/scripts/mkver ntpq $(COMPILE) -c version.c +install-exec-hook: + @case ${BINSUBDIR} in \ + bin) ODIR=${sbindir} ;; \ + sbin) ODIR=${bindir} ;; \ + esac; \ + test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ + || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ + test ! -f $$ODIR/$$i || echo "*** $$i is also in $$ODIR!"; \ + done + +# +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + ..) \ + cd .. && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + *) \ + echo 'Fatal: depsver.mf Automake fragment limited' \ + 'to immediate subdirectories.' && \ + echo "top_builddir: $(top_builddir)" && \ + echo "subdir: $(subdir)" && \ + exit 1 \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# + # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: diff -urN src/contrib/ntp/ntpq/libntpq.c src.ntp/contrib/ntp/ntpq/libntpq.c --- src/contrib/ntp/ntpq/libntpq.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpq/libntpq.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,790 @@ +/***************************************************************************** + * + * libntpq.c + * + * This is the wrapper library for ntpq, the NTP query utility. + * This library reuses the sourcecode from ntpq and exports a number + * of useful functions in a library that can be linked against applications + * that need to query the status of a running ntpd. The whole + * communcation is based on mode 6 packets. + * + ****************************************************************************/ +#define _LIBNTPQC +#define NO_MAIN_ALLOWED 1 +/* #define BUILD_AS_LIB Already provided by the Makefile */ + +#include "ntpq.c" +#include "libntpq.h" + +/* Function Prototypes */ +int ntpq_openhost(char *); +int ntpq_closehost(void); +int ntpq_queryhost(unsigned short VARSET, unsigned short association, char *resultbuf, int maxlen); +int ntpq_stripquotes ( char *resultbuf, char *srcbuf, int datalen, int maxlen ); +int ntpq_queryhost_peervars(unsigned short association, char *resultbuf, int maxlen); +int ntpq_getvar( char *resultbuf, int datalen, const char *varname, char *varvalue, int maxlen); +int ntpq_get_peervar( const char *varname, char *varvalue, int maxlen); +int ntpq_read_associations ( unsigned short resultbuf[], int max_entries ); +int ntpq_read_sysvars( char *resultbuf, int maxsize ); +int ntpq_get_assoc_allvars( int associd ); +int ntpq_get_sysvars( void ); +int ntpq_get_assocs ( void ); +int ntpq_read_assoc_peervars( int associd, char *resultbuf, int maxsize ); +int ntpq_read_assoc_clockvars( int associd, char *resultbuf, int maxsize ); +int ntpq_get_assoc_number ( int associd ); +int ntpq_get_assoc_peervars( int associd ); +int ntpq_get_assoc_clockvars( int associd ); +int ntpq_get_assoc_clocktype ( int assoc_number ); + + +const char *Version = "libntpq 0.3beta"; + +/* global variables used for holding snapshots of data */ + char peervars[NTPQ_BUFLEN]; + int peervarlen = 0; + int peervar_assoc = 0; + char clockvars[NTPQ_BUFLEN]; + int clockvarlen = 0; + int clockvar_assoc = 0; + char sysvars[NTPQ_BUFLEN]; + int sysvarlen = 0; + char *ntpq_resultbuffer[NTPQ_BUFLEN]; + unsigned short ntpq_associations[MAXASSOC]; + +struct ntpq_varlist ntpq_varlist[MAXLIST]; + +/***************************************************************************** + * + * ntpq_stripquotes + * + * Parses a given character buffer srcbuf and removes all quoted + * characters. The resulting string is copied to the specified + * resultbuf character buffer. E.g. \" will be translated into " + * + **************************************************************************** + * Parameters: + * resultbuf char* The resulting string without quoted + * characters + * srcbuf char* The buffer holding the original string + * datalen int The number of bytes stored in srcbuf + * maxlen int Max. number of bytes for resultbuf + * + * Returns: + * int number of chars that have been copied to + * resultbuf + ****************************************************************************/ + +int ntpq_stripquotes ( char *resultbuf, char *srcbuf, int datalen, int maxlen ) +{ + char* tmpbuf = srcbuf; + + while ( *tmpbuf != 0 ) + { + if ( *tmpbuf == '\"' ) + { + tmpbuf++; + continue; + } + + if ( *tmpbuf == '\\' ) + { + tmpbuf++; + switch ( *tmpbuf ) + { + /* ignore if end of string */ + case 0: + continue; + /* skip and do not copy */ + case '\"': /* quotes */ + case 'n': /*newline*/ + case 'r': /*carriage return*/ + case 'g': /*bell*/ + case 't': /*tab*/ + tmpbuf++; + continue; + } + } + + *resultbuf++ = *tmpbuf++; + + } + + *resultbuf = 0; + return strlen(resultbuf); +} + + +/***************************************************************************** + * + * ntpq_getvar + * + * This function parses a given buffer for a variable/value pair and + * copies the value of the requested variable into the specified + * varvalue buffer. + * + * It returns the number of bytes copied or zero for an empty result + * (=no matching variable found or empty value) + * + **************************************************************************** + * Parameters: + * resultbuf char* The resulting string without quoted + * characters + * datalen int The number of bytes stored in + * resultbuf + * varname char* Name of the required variable + * varvalue char* Where the value of the variable should + * be stored + * maxlen int Max. number of bytes for varvalue + * + * Returns: + * int number of chars that have been copied to + * varvalue + ****************************************************************************/ + +int ntpq_getvar( char *resultbuf, int datalen, const char *varname, char *varvalue, int maxlen) +{ + char *name; + char *value = NULL; + + while (nextvar(&datalen, &resultbuf, &name, &value)) { + + if ( strcmp(varname, name) == 0 ) { + ntpq_stripquotes(varvalue,value,strlen(value),maxlen); + return strlen(varvalue); + } + } + + return 0; +} + + +/***************************************************************************** + * + * ntpq_queryhost + * + * Sends a mode 6 query packet to the current open host (see + * ntpq_openhost) and stores the requested variable set in the specified + * character buffer. + * It returns the number of bytes read or zero for an empty result + * (=no answer or empty value) + * + **************************************************************************** + * Parameters: + * VARSET u_short Which variable set should be + * read (PEERVARS or CLOCKVARS) + * association int The association ID that should be read + * 0 represents the ntpd instance itself + * resultbuf char* The resulting string without quoted + * characters + * maxlen int Max. number of bytes for varvalue + * + * Returns: + * int number of bytes that have been copied to + * resultbuf + * - OR - + * 0 (zero) if no reply has been received or + * another failure occured + ****************************************************************************/ + +int ntpq_queryhost(unsigned short VARSET, unsigned short association, char *resultbuf, int maxlen) +{ + char *datap; + int res; + int dsize; + u_short rstatus; + + if ( numhosts > 0 ) + res = doquery(VARSET,association,0,0, (char *)0, &rstatus, &dsize, &datap); + else + return 0; + + if ( ( res != 0) || ( dsize == 0 ) ) /* no data */ + return 0; + + if ( dsize > maxlen) + dsize = maxlen; + + + /* fill result resultbuf */ + memcpy(resultbuf, datap, dsize); + + return dsize; +} + + + +/***************************************************************************** + * + * ntpq_openhost + * + * Sets up a connection to the ntpd instance of a specified host. Note: + * There is no real "connection" established because NTP solely works + * based on UDP. + * + **************************************************************************** + * Parameters: + * hostname char* Hostname/IP of the host running ntpd + * + * Returns: + * int 1 if the host connection could be set up, i.e. + * name resolution was succesful and/or IP address + * has been validated + * - OR - + * 0 (zero) if a failure occured + ****************************************************************************/ + +int ntpq_openhost(char *hostname) +{ + if ( openhost(hostname) ) + { + numhosts = 1; + } else { + numhosts = 0; + } + + return numhosts; + +} + + +/***************************************************************************** + * + * ntpq_closehost + * + * Cleans up a connection by closing the used socket. Should be called + * when no further queries are required for the currently used host. + * + **************************************************************************** + * Parameters: + * - none - + * + * Returns: + * int 0 (zero) if no host has been opened before + * - OR - + * the resultcode from the closesocket function call + ****************************************************************************/ + +int ntpq_closehost(void) +{ + if ( numhosts ) + return closesocket(sockfd); + + return 0; +} + + +/***************************************************************************** + * + * ntpq_read_associations + * + * This function queries the ntp host for its associations and returns the + * number of associations found. + * + * It takes an u_short array as its first parameter, this array holds the + * IDs of the associations, + * the function will not write more entries than specified with the + * max_entries parameter. + * + * However, if more than max_entries associations were found, the return + * value of this function will reflect the real number, even if not all + * associations have been stored in the array. + * + **************************************************************************** + * Parameters: + * resultbuf u_short*Array that should hold the list of + * association IDs + * maxentries int maximum number of association IDs that can + * be stored in resultbuf + * + * Returns: + * int number of association IDs stored in resultbuf + * - OR - + * 0 (zero) if a failure occured or no association has + * been returned. + ****************************************************************************/ + + int ntpq_read_associations ( u_short resultbuf[], int max_entries ) +{ + int i = 0; + + if (ntpq_dogetassoc()) { + + if(numassoc < max_entries) + max_entries = numassoc; + + for (i=0;i 1) + (void) fprintf(stderr, "server=%s ", currenthost); + (void) fprintf(stderr, + "***No information returned for association %d\n", + associd); + return 0; + } else { + if ( dsize > maxsize ) + dsize = maxsize; + + memcpy(resultbuf,datap,dsize); + resultbuf[dsize]=0x0; + + ntpq_getvar(resultbuf, dsize, "rec", value, sizeof (value) ); + + if (!decodets(value, &rec)) + L_CLR(&rec); + + memcpy(resultbuf,value,maxsize); + resultbuf[dsize]=0x0; + dsize=strlen(resultbuf); + + + } + return dsize; + +} + + + + +/***************************************************************************** + * + * ntpq_read_sysvars + * + * This function reads the sysvars variable-set from a NTP host and writes it + * to the result buffer specified, honoring the maxsize limit. + * + * It returns the number of bytes written or 0 when the variable-set is empty + * or could not be read. + * + **************************************************************************** + * Parameters: + * resultbuf char* character buffer where the variable set + * should be stored + * maxsize int the maximum number of bytes that can be + * written to resultbuf + * + * Returns: + * int number of chars that have been copied to + * resultbuf + * - OR - + * 0 (zero) if an error occured + ****************************************************************************/ +int ntpq_read_sysvars( char *resultbuf, int maxsize ) +{ + + char *datap; + int res; + int dsize; + u_short rstatus; + + res = doquery(CTL_OP_READVAR, 0, 0, 0, (char *)0, &rstatus, + &dsize, &datap); + + if (res != 0) + return 0; + + if (dsize == 0) { + if (numhosts > 1) + (void) fprintf(stderr, "server=%s ", currenthost); + (void) fprintf(stderr, + "***No sysvar information returned \n"); + return 0; + } else { + if ( dsize > maxsize ) + dsize = maxsize; + + memcpy(resultbuf,datap,dsize); + } + + return dsize; + +} + + +/***************************************************************************** + * ntpq_get_assoc_allvars + * + * With this function all association variables for the specified association + * ID can be requested from a NTP host. They are stored internally and can be + * read by using the ntpq_get_peervar or ntpq_get_clockvar functions. + * + * Basically this is only a combination of the ntpq_get_assoc_peervars and + * ntpq_get_assoc_clockvars functions. + * + * It returns 1 if both variable-sets (peervars and clockvars) were + * received successfully. If one variable-set or both of them weren't + * received, + * + **************************************************************************** + * Parameters: + * associd int requested associaton ID + * + * Returns: + * int nonzero if at least one variable set could be read + * - OR - + * 0 (zero) if an error occured and both variable sets + * could not be read + ****************************************************************************/ + int ntpq_get_assoc_allvars( int associd ) +{ + return ( ntpq_get_assoc_peervars ( associd ) & ntpq_get_assoc_clockvars( associd ) ); +} + + + + +/***************************************************************************** + * + * ntpq_get_sysvars + * + * The system variables of a NTP host can be requested by using this function + * and afterwards using ntpq_get_sysvar to read the single variable values. + * + **************************************************************************** + * Parameters: + * - none - + * + * Returns: + * int nonzero if the variable set could be read + * - OR - + * 0 (zero) if an error occured and the sysvars + * could not be read + ****************************************************************************/ + int ntpq_get_sysvars( void ) +{ + sysvarlen = ( ntpq_read_sysvars( sysvars, sizeof(sysvars )) ); + if ( sysvarlen <= 0 ) { + return 0; + } else { + return 1; + } +} + + +/***************************************************************************** + * + * ntp_get_peervar + * + * This function uses the variable-set which was read by using + * ntp_get_peervars and searches for a variable specified with varname. If + * such a variable exists, it writes its value into + * varvalue (maxlen specifies the size of this target buffer). + * + **************************************************************************** + * Parameters: + * varname char* requested variable name + * varvalue char* the buffer where the value should go into + * maxlen int maximum number of bytes that can be copied to + * varvalue + * + * Returns: + * int number of bytes copied to varvalue + * - OR - + * 0 (zero) if an error occured or the variable could + * not be found + ****************************************************************************/ +int ntpq_get_peervar( const char *varname, char *varvalue, int maxlen) +{ + return ( ntpq_getvar(peervars,peervarlen,varname,varvalue,maxlen) ); +} + + + +/***************************************************************************** + * + * ntpq_get_assoc_peervars + * + * This function requests the peer variables of the specified association + * from a NTP host. In order to access the variable values, the function + * ntpq_get_peervar must be used. + * + **************************************************************************** + * Parameters: + * associd int requested associaton ID + * + * Returns: + * int 1 (one) if the peervars have been read + * - OR - + * 0 (zero) if an error occured and the variable set + * could not be read + ****************************************************************************/ + int ntpq_get_assoc_peervars( int associd ) +{ + peervarlen = ( ntpq_read_assoc_peervars( associd, peervars, sizeof(peervars )) ); + if ( peervarlen <= 0 ) { + peervar_assoc = 0; + return 0; + } else { + peervar_assoc = associd; + return 1; + } +} + + +/***************************************************************************** + * + * ntp_read_assoc_clockvars + * + * This function reads the clockvars variable-set of a specified association + * from a NTP host and writes it to the result buffer specified, honoring + * the maxsize limit. + * + * It returns the number of bytes written or 0 when the variable-set is + * empty or failed to read. + * + **************************************************************************** + * Parameters: + * associd int requested associaton ID + * resultbuf char* character buffer where the variable set + * should be stored + * maxsize int the maximum number of bytes that can be + * written to resultbuf + * + * Returns: + * int number of chars that have been copied to + * resultbuf + * - OR - + * 0 (zero) if an error occured + ****************************************************************************/ + +int ntpq_read_assoc_clockvars( int associd, char *resultbuf, int maxsize ) +{ + + char *datap; + int res; + int dsize; + u_short rstatus; + + res = ntpq_doquerylist(ntpq_varlist, CTL_OP_READCLOCK, associd, 0, &rstatus, &dsize, &datap); + + if (res != 0) + return 0; + + if (dsize == 0) { + if (numhosts > 1) /* no information returned from server */ + return 0; + } else { + if ( dsize > maxsize ) + dsize = maxsize; + + memcpy(resultbuf,datap,dsize); + } + + return dsize; +} + + + +/***************************************************************************** + * + * ntpq_get_assoc_clocktype + * + * This function returns a clocktype value for a given association number + * (not ID!): + * + * NTP_CLOCKTYPE_UNKNOWN Unknown clock type + * NTP_CLOCKTYPE_BROADCAST Broadcast server + * NTP_CLOCKTYPE_LOCAL Local clock + * NTP_CLOCKTYPE_UNICAST Unicast server + * NTP_CLOCKTYPE_MULTICAST Multicast server + * + ****************************************************************************/ + int ntpq_get_assoc_clocktype ( int assoc_number ) +{ + int type = 0; + int i, rc = 0; + sockaddr_u dum_store; + char value[LENHOSTNAME]; + char resultbuf[1024]; + + + if ( assoc_number < 0 || assoc_number > numassoc ) { + return -1; + } else { + if ( peervar_assoc != assoc_cache[assoc_number].assid ) { + + i=ntpq_read_assoc_peervars(assoc_cache[assoc_number].assid, resultbuf, sizeof(resultbuf)); + if ( i <= 0 ) { + return -1; + } + + rc = ntpq_getvar(resultbuf, i, "dstadr", value, LENHOSTNAME ); + + + } else { + + rc = ntpq_get_peervar("dstadr",value,LENHOSTNAME); + + } + + if ( rc ) { + if (decodenetnum(value, &dum_store)) { + type = ntpq_decodeaddrtype(&dum_store); + return type; + } + } + + return -1; + } + + return -1; + +} + + + +/***************************************************************************** + * + * ntpq_get_assoc_clockvars + * + * With this function the clock variables of the specified association are + * requested from a NTP host. This makes only sense for associations with + * the type 'l' (Local Clock) and you should check this with + * ntpq_get_assoc_clocktype for each association, before you use this function + * on it. + * + **************************************************************************** + * Parameters: + * associd int requested associaton ID + * + * Returns: + * int 1 (one) if the clockvars have been read + * - OR - + * 0 (zero) if an error occured and the variable set + * could not be read + ****************************************************************************/ + int ntpq_get_assoc_clockvars( int associd ) +{ + + if ( ntpq_get_assoc_clocktype(ntpq_get_assoc_number(associd)) != NTP_CLOCKTYPE_LOCAL ) + return 0; + + clockvarlen = ( ntpq_read_assoc_clockvars( associd, clockvars, sizeof(clockvars )) ); + if ( clockvarlen <= 0 ) { + clockvar_assoc = 0; + return 0; + } else { + clockvar_assoc = associd; + return 1; + } +} + + diff -urN src/contrib/ntp/ntpq/libntpq.h src.ntp/contrib/ntp/ntpq/libntpq.h --- src/contrib/ntp/ntpq/libntpq.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpq/libntpq.h 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,110 @@ +/***************************************************************************** + * + * libntpq.h + * + * This is the wrapper library for ntpq, the NTP query utility. + * This library reuses the sourcecode from ntpq and exports a number + * of useful functions in a library that can be linked against applications + * that need to query the status of a running ntpd. The whole + * communcation is based on mode 6 packets. + * + * This header file can be used in applications that want to link against + * libntpq. + * + ****************************************************************************/ + +#include "ntp_net.h" + +/* general purpose buffer size */ +#define NTPQ_BUFLEN 2048 + +/* max. number of associations */ +#ifndef MAXASSOC +#define MAXASSOC 1024 +#endif + +/* general purpose max array size definition */ +#ifndef MAXLIST +#define MAXLIST 64 +#endif + +#ifndef LENHOSTNAME +#define LENHOSTNAME 256 /* host name is max. 256 characters long */ +#endif + +/* NTP Status codes */ +#define NTP_STATUS_INVALID 0 +#define NTP_STATUS_FALSETICKER 1 +#define NTP_STATUS_EXCESS 2 +#define NTP_STATUS_OUTLYER 3 +#define NTP_STATUS_CANDIDATE 4 +#define NTP_STATUS_SELECTED 5 +#define NTP_STATUS_SYSPEER 6 +#define NTP_STATUS_PPSPEER 7 + +/* NTP association type identifier */ +#define NTP_CLOCKTYPE_UNKNOWN '-' +#define NTP_CLOCKTYPE_BROADCAST 'b' +#define NTP_CLOCKTYPE_LOCAL 'l' +#define NTP_CLOCKTYPE_UNICAST 'u' +#define NTP_CLOCKTYPE_MULTICAST 'm' + +/* Variable Sets */ +#define PEERVARS CTL_OP_READVAR +#define CLOCKVARS CTL_OP_CLOCKVAR + +/* Variable list struct */ +struct ntpq_varlist { + char *name; + char *value; +}; + +/* global variables used for holding snapshots of data */ +#ifndef _LIBNTPQC +extern char peervars[]; +extern int peervarlen; +extern int peervar_assoc; +extern char clockvars[]; +extern int clockvarlen; +extern int clockvar_assoc; +extern char sysvars[]; +extern int sysvarlen; +extern char *ntpq_resultbuffer[]; +extern struct ntpq_varlist ntpq_varlist[MAXLIST]; +#endif + + + +/* + * Prototypes of exported libary functions + */ + +/* from libntpq.c */ +#ifndef _LIBNTPQC +extern int ntpq_openhost(char *); +extern int ntpq_closehost(void); +extern int ntpq_queryhost(unsigned short VARSET, unsigned short association, char *resultbuf, int maxlen); +extern int ntpq_getvar( char *resultbuf, int datalen, const char *varname, char *varvalue, int maxlen); +extern int ntpq_stripquotes ( char *resultbuf, char *srcbuf, int datalen, int maxlen ); +extern int ntpq_queryhost_peervars(unsigned short association, char *resultbuf, int maxlen); +extern int ntpq_get_peervar( const char *varname, char *varvalue, int maxlen); +extern int ntpq_read_sysvars( char *resultbuf, int maxsize ); +extern int ntpq_get_sysvars( void ); +extern int ntpq_read_associations ( unsigned short resultbuf[], int max_entries ); +extern int ntpq_get_assocs ( void ); +extern int ntpq_get_assoc_number ( int associd ); +extern int ntpq_get_assoc_peervars( int associd ); +extern int ntpq_get_assoc_clockvars( int associd ); +extern int ntpq_get_assoc_allvars( int associd ); +extern int ntpq_get_assoc_clocktype ( int assoc_number ); +extern int ntpq_read_assoc_peervars( int associd, char *resultbuf, int maxsize ); +extern int ntpq_read_assoc_clockvars( int associd, char *resultbuf, int maxsize ); + #endif + +/* in libntpq_subs.c */ +#ifndef _LIBNTPQSUBSC +extern int ntpq_dogetassoc(void); +extern char ntpq_decodeaddrtype(sockaddr_u *sock); +extern int ntpq_doquerylist(struct ntpq_varlist *, int , int , int , u_short *, int *, char **datap ); +#endif + diff -urN src/contrib/ntp/ntpq/libntpq_subs.c src.ntp/contrib/ntp/ntpq/libntpq_subs.c --- src/contrib/ntp/ntpq/libntpq_subs.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpq/libntpq_subs.c 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,50 @@ +/***************************************************************************** + * + * libntpq_subs.c + * + * This is the second part of the wrapper library for ntpq, the NTP query utility. + * This library reuses the sourcecode from ntpq and exports a number + * of useful functions in a library that can be linked against applications + * that need to query the status of a running ntpd. The whole + * communcation is based on mode 6 packets. + * + * This source file exports the (private) functions from ntpq-subs.c + * + ****************************************************************************/ + + +#define _LIBNTPQSUBSC +#include "ntpq-subs.c" +#include "libntpq.h" + +/* Function Prototypes */ +int ntpq_dogetassoc(void); +char ntpq_decodeaddrtype(sockaddr_u *sock); +int ntpq_doquerylist(struct varlist *, int , int , int , u_short *, int *, char **datap ); + + +/* the following functions are required internally by a number of libntpq functions + * and since they are defined as static in ntpq-subs.c, they need to be exported here + */ + +int ntpq_dogetassoc(void) +{ + + if ( dogetassoc(NULL)) + { + return numassoc; + } else { + return 0; + } +} + +char ntpq_decodeaddrtype(sockaddr_u *sock) +{ + return decodeaddrtype(sock); +} + +int ntpq_doquerylist(struct varlist *vlist, int op, int associd, int auth, u_short *rstatus, int *dsize, char **datap ) +{ + return doquerylist(vlist, op, associd, auth, rstatus, dsize, &*datap ); +} + diff -urN src/contrib/ntp/ntpq/ntpq-opts.c src.ntp/contrib/ntp/ntpq/ntpq-opts.c --- src/contrib/ntp/ntpq/ntpq-opts.c 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpq/ntpq-opts.c 2010-07-09 04:24:18.000000000 +0200 @@ -1,11 +1,11 @@ /* * EDIT THIS FILE WITH CAUTION (ntpq-opts.c) * - * It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:26 AM EST + * It has been AutoGen-ed July 9, 2010 at 02:24:18 AM by AutoGen 5.10 * From the definitions ntpq-opts.def * and the template file options * - * Generated from AutoOpts 29:0:4 templates. + * Generated from AutoOpts 33:0:8 templates. */ /* @@ -19,13 +19,15 @@ * * This source file is copyrighted and licensed under the following terms: * - * ntpq copyright 1970-2009 David L. Mills and/or others - all rights reserved + * ntpq copyright (c) 1970-2010 David L. Mills and/or others - all rights reserved * * see html/copyright.html */ - +#include #include +#include +#include #define OPTION_CODE_COMPILE 1 #include "ntpq-opts.h" @@ -33,12 +35,16 @@ #ifdef __cplusplus extern "C" { #endif + +/* TRANSLATORS: choose the translation for option names wisely because you + cannot ever change your mind. */ tSCC zCopyright[] = - "ntpq copyright (c) 1970-2009 David L. Mills and/or others, all rights reserved"; -tSCC zCopyrightNotice[] = - + "ntpq copyright (c) 1970-2010 David L. Mills and/or others, all rights reserved" /* extracted from ../include/copyright.def near line 8 */ +; +tSCC zCopyrightNotice[24] = "see html/copyright.html"; + extern tUsageProc optionUsage; /* @@ -59,22 +65,31 @@ #ifndef EXIT_FAILURE # define EXIT_FAILURE 1 #endif + /* - * Ipv4 option description: + * Ipv4 option description with + * "Must also have options" and "Incompatible options": */ tSCC zIpv4Text[] = "Force IPv4 DNS name resolution"; tSCC zIpv4_NAME[] = "IPV4"; tSCC zIpv4_Name[] = "ipv4"; +static const int + aIpv4CantList[] = { + INDEX_OPT_IPV6, NO_EQUIVALENT }; #define IPV4_FLAGS (OPTST_DISABLED) /* - * Ipv6 option description: + * Ipv6 option description with + * "Must also have options" and "Incompatible options": */ tSCC zIpv6Text[] = "Force IPv6 DNS name resolution"; tSCC zIpv6_NAME[] = "IPV6"; tSCC zIpv6_Name[] = "ipv6"; +static const int + aIpv6CantList[] = { + INDEX_OPT_IPV4, NO_EQUIVALENT }; #define IPV6_FLAGS (OPTST_DISABLED) /* @@ -84,31 +99,21 @@ "run a command and exit"; tSCC zCommand_NAME[] = "COMMAND"; tSCC zCommand_Name[] = "command"; -#define COMMAND_FLAGS (OPTST_DISABLED | OPTST_STACKED \ +#define COMMAND_FLAGS (OPTST_DISABLED \ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) /* * Debug_Level option description: */ -#ifdef DEBUG tSCC zDebug_LevelText[] = "Increase output debug message level"; tSCC zDebug_Level_NAME[] = "DEBUG_LEVEL"; tSCC zDebug_Level_Name[] = "debug-level"; #define DEBUG_LEVEL_FLAGS (OPTST_DISABLED) -#else /* disable Debug_Level */ -#define VALUE_OPT_DEBUG_LEVEL NO_EQUIVALENT -#define DEBUG_LEVEL_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zDebug_LevelText NULL -#define zDebug_Level_NAME NULL -#define zDebug_Level_Name NULL -#endif /* DEBUG */ - /* * Set_Debug_Level option description: */ -#ifdef DEBUG tSCC zSet_Debug_LevelText[] = "Set the output debug message level"; tSCC zSet_Debug_Level_NAME[] = "SET_DEBUG_LEVEL"; @@ -116,14 +121,6 @@ #define SET_DEBUG_LEVEL_FLAGS (OPTST_DISABLED \ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) -#else /* disable Set_Debug_Level */ -#define VALUE_OPT_SET_DEBUG_LEVEL NO_EQUIVALENT -#define SET_DEBUG_LEVEL_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zSet_Debug_LevelText NULL -#define zSet_Debug_Level_NAME NULL -#define zSet_Debug_Level_Name NULL -#endif /* DEBUG */ - /* * Peers option description with * "Must also have options" and "Incompatible options": @@ -161,37 +158,47 @@ #define NUMERIC_FLAGS (OPTST_DISABLED) /* - * Help/More_Help/Version option descriptions: + * Old_Rv option description: */ -tSCC zHelpText[] = "Display usage information and exit"; -tSCC zHelp_Name[] = "help"; - -tSCC zMore_HelpText[] = "Extended usage information passed thru pager"; -tSCC zMore_Help_Name[] = "more-help"; - -tSCC zVersionText[] = "Output version information and exit"; -tSCC zVersion_Name[] = "version"; +tSCC zOld_RvText[] = + "Always output status line with readvar"; +tSCC zOld_Rv_NAME[] = "OLD_RV"; +tSCC zOld_Rv_Name[] = "old-rv"; +#define OLD_RV_FLAGS (OPTST_DISABLED) /* - * Save/Load_Opts option description: + * Help/More_Help/Version option descriptions: */ +tSCC zHelpText[] = "Display extended usage information and exit"; +tSCC zHelp_Name[] = "help"; +#ifdef HAVE_WORKING_FORK +#define OPTST_MORE_HELP_FLAGS (OPTST_IMM | OPTST_NO_INIT) +tSCC zMore_Help_Name[] = "more-help"; +tSCC zMore_HelpText[] = "Extended usage information passed thru pager"; +#else +#define OPTST_MORE_HELP_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#define zMore_Help_Name NULL +#define zMore_HelpText NULL +#endif +#ifdef NO_OPTIONAL_OPT_ARGS +# define OPTST_VERSION_FLAGS OPTST_IMM | OPTST_NO_INIT +#else +# define OPTST_VERSION_FLAGS OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ + OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT +#endif + +tSCC zVersionText[] = "Output version information and exit"; +tSCC zVersion_Name[] = "version"; tSCC zSave_OptsText[] = "Save the option state to a config file"; tSCC zSave_Opts_Name[] = "save-opts"; - tSCC zLoad_OptsText[] = "Load options from a config file"; tSCC zLoad_Opts_NAME[] = "LOAD_OPTS"; - tSCC zNotLoad_Opts_Name[] = "no-load-opts"; tSCC zNotLoad_Opts_Pfx[] = "no"; #define zLoad_Opts_Name (zNotLoad_Opts_Name + 3) /* * Declare option callback procedures */ -#ifdef DEBUG - static tOptProc doOptSet_Debug_Level; -#else /* not DEBUG */ -# define doOptSet_Debug_Level NULL -#endif /* def/not DEBUG */ #if defined(TEST_NTPQ_OPTS) /* * Under test, omit argument processing, or call optionStackArg, @@ -205,7 +212,9 @@ /* * #define map the "normal" callout procs to the test ones... */ +#define COMMAND_OPT_PROC optionStackArg #define SET_DEBUG_LEVEL_OPT_PROC optionStackArg +#define PEERS_OPT_PROC optionStackArg #else /* NOT defined TEST_NTPQ_OPTS */ @@ -213,16 +222,20 @@ * When not under test, there are different procs to use */ extern tOptProc - optionPagedUsage, optionPrintVersion, optionStackArg; + ntpq_custom_opt_handler, optionPagedUsage, optionPrintVersion; static tOptProc - doUsageOpt; + doOptSet_Debug_Level, doUsageOpt; /* * #define map the "normal" callout procs */ +#define COMMAND_OPT_PROC ntpq_custom_opt_handler #define SET_DEBUG_LEVEL_OPT_PROC doOptSet_Debug_Level +#define PEERS_OPT_PROC ntpq_custom_opt_handler +#define COMMAND_OPT_PROC ntpq_custom_opt_handler #define SET_DEBUG_LEVEL_OPT_PROC doOptSet_Debug_Level +#define PEERS_OPT_PROC ntpq_custom_opt_handler #endif /* defined(TEST_NTPQ_OPTS) */ #ifdef TEST_NTPQ_OPTS # define DOVERPROC optionVersionStderr @@ -236,25 +249,25 @@ */ static tOptDesc optDesc[ OPTION_CT ] = { { /* entry idx, value */ 0, VALUE_OPT_IPV4, - /* equiv idx, value */ NO_EQUIVALENT, 0, + /* equiv idx, value */ 0, VALUE_OPT_IPV4, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ IPV4_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, + /* must/cannot opts */ NULL, aIpv4CantList, /* option proc */ NULL, /* desc, NAME, name */ zIpv4Text, zIpv4_NAME, zIpv4_Name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ 1, VALUE_OPT_IPV6, - /* equiv idx, value */ NOLIMIT, NOLIMIT, - /* equivalenced to */ INDEX_OPT_IPV4, + /* equiv idx, value */ 1, VALUE_OPT_IPV6, + /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ IPV6_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, + /* must/cannot opts */ NULL, aIpv6CantList, /* option proc */ NULL, /* desc, NAME, name */ zIpv6Text, zIpv6_NAME, zIpv6_Name, /* disablement strs */ NULL, NULL }, @@ -267,7 +280,7 @@ /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, - /* option proc */ optionStackArg, + /* option proc */ COMMAND_OPT_PROC, /* desc, NAME, name */ zCommandText, zCommand_NAME, zCommand_Name, /* disablement strs */ NULL, NULL }, @@ -303,7 +316,7 @@ /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, aPeersCantList, - /* option proc */ NULL, + /* option proc */ PEERS_OPT_PROC, /* desc, NAME, name */ zPeersText, zPeers_NAME, zPeers_Name, /* disablement strs */ NULL, NULL }, @@ -331,18 +344,23 @@ /* desc, NAME, name */ zNumericText, zNumeric_NAME, zNumeric_Name, /* disablement strs */ NULL, NULL }, -#ifdef NO_OPTIONAL_OPT_ARGS -# define VERSION_OPT_FLAGS OPTST_IMM | OPTST_NO_INIT -#else -# define VERSION_OPT_FLAGS OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ - OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT -#endif + { /* entry idx, value */ 8, VALUE_OPT_OLD_RV, + /* equiv idx, value */ 8, VALUE_OPT_OLD_RV, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ OLD_RV_FLAGS, 0, + /* last opt argumnt */ { NULL }, + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ NULL, + /* desc, NAME, name */ zOld_RvText, zOld_Rv_NAME, zOld_Rv_Name, + /* disablement strs */ NULL, NULL }, { /* entry idx, value */ INDEX_OPT_VERSION, VALUE_OPT_VERSION, /* equiv idx value */ NO_EQUIVALENT, 0, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ VERSION_OPT_FLAGS, 0, + /* opt state flags */ OPTST_VERSION_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, @@ -350,7 +368,6 @@ /* desc, NAME, name */ zVersionText, NULL, zVersion_Name, /* disablement strs */ NULL, NULL }, -#undef VERSION_OPT_FLAGS { /* entry idx, value */ INDEX_OPT_HELP, VALUE_OPT_HELP, @@ -369,7 +386,7 @@ /* equiv idx value */ NO_EQUIVALENT, 0, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, 0, + /* opt state flags */ OPTST_MORE_HELP_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, @@ -394,7 +411,7 @@ /* equiv idx value */ NO_EQUIVALENT, 0, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, NOLIMIT, 0, - /* opt state flags */ OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) \ + /* opt state flags */ OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | OPTST_DISABLE_IMM, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, @@ -410,7 +427,7 @@ */ tSCC zPROGNAME[] = "NTPQ"; tSCC zUsageTitle[] = -"ntpq - standard NTP query program - Ver. 4.2.4p8\n\ +"ntpq - standard NTP query program - Ver. 4.2.6p2\n\ USAGE: %s [ - [] | --[{=| }] ]... [ host ...]\n"; tSCC zRcName[] = ".ntprc"; tSCC* apzHomeList[] = { @@ -430,7 +447,7 @@ The same formats are used in NTPv4, although some of the\n\ variables have changed and new ones added.\n"; tSCC zFullVersion[] = NTPQ_FULL_VERSION; -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optcode.tpl near line 408 */ +/* extracted from /usr/local/gnu/share/autogen/optcode.tpl near line 495 */ #if defined(ENABLE_NLS) # define OPTPROC_BASE OPTPROC_TRANSLATE @@ -440,6 +457,9 @@ # define translate_option_strings NULL #endif /* ENABLE_NLS */ + +#define ntpq_full_usage NULL +#define ntpq_short_usage NULL tOptions ntpqOptions = { OPTIONS_STRUCT_VERSION, 0, NULL, /* original argc + argv */ @@ -448,8 +468,7 @@ + OPTPROC_SHORTOPT + OPTPROC_LONGOPT + OPTPROC_NO_REQ_OPT - + OPTPROC_ENVIRON - + OPTPROC_HAS_IMMED ), + + OPTPROC_ENVIRON ), 0, NULL, /* current option index, current option */ NULL, NULL, zPROGNAME, zRcName, zCopyright, zCopyrightNotice, @@ -462,12 +481,14 @@ /* * Indexes to special options */ - { INDEX_OPT_MORE_HELP, - INDEX_OPT_SAVE_OPTS, - NO_EQUIVALENT /* index of '-#' option */, + { INDEX_OPT_MORE_HELP, /* more-help option index */ + INDEX_OPT_SAVE_OPTS, /* save option index */ + NO_EQUIVALENT, /* '-#' option index */ NO_EQUIVALENT /* index of default opt */ }, - 13 /* full option count */, 8 /* user option count */ + 14 /* full option count */, 9 /* user option count */, + ntpq_full_usage, ntpq_short_usage, + NULL, NULL }; /* @@ -478,45 +499,39 @@ tOptions* pOptions, tOptDesc* pOptDesc ) { + (void)pOptions; USAGE( EXIT_SUCCESS ); } #if ! defined(TEST_NTPQ_OPTS) -/* * * * * * * +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * For the set-debug-level option, when DEBUG is #define-d. + * For the set-debug-level option. */ -#ifdef DEBUG static void -doOptSet_Debug_Level( - tOptions* pOptions, - tOptDesc* pOptDesc ) +doOptSet_Debug_Level(tOptions* pOptions, tOptDesc* pOptDesc) { - /* extracted from ../include/debug-opt.def, line 29 */ + /* extracted from ../include/debug-opt.def, line 27 */ DESC(DEBUG_LEVEL).optOccCt = atoi( pOptDesc->pzLastArg ); } -#endif /* defined DEBUG */ - #endif /* defined(TEST_NTPQ_OPTS) */ - -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optmain.tpl near line 92 */ +/* extracted from /usr/local/gnu/share/autogen/optmain.tpl near line 109 */ #if defined(TEST_NTPQ_OPTS) /* TEST MAIN PROCEDURE: */ +extern void optionPutShell( tOptions* ); + int -main( int argc, char** argv ) +main(int argc, char** argv) { int res = EXIT_SUCCESS; (void)optionProcess( &ntpqOptions, argc, argv ); - { - void optionPutShell( tOptions* ); - optionPutShell( &ntpqOptions ); - } + optionPutShell( &ntpqOptions ); return res; } #endif /* defined TEST_NTPQ_OPTS */ -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optcode.tpl near line 514 */ +/* extracted from /usr/local/gnu/share/autogen/optcode.tpl near line 627 */ #if ENABLE_NLS #include @@ -559,44 +574,45 @@ * Guard against re-translation. It won't work. The strings will have * been changed by the first pass through this code. One shot only. */ - if (option_usage_text.field_ct == 0) - return; - /* - * Do the translations. The first pointer follows the field count field. - * The field count field is the size of a pointer. - */ - { - char** ppz = (char**)(void*)&(option_usage_text); - int ix = option_usage_text.field_ct; + if (option_usage_text.field_ct != 0) { + + /* + * Do the translations. The first pointer follows the field count + * field. The field count field is the size of a pointer. + */ + tOptDesc* pOD = ntpqOptions.pOptDesc; + char** ppz = (char**)(void*)&(option_usage_text); + int ix = option_usage_text.field_ct; do { ppz++; *ppz = AO_gettext(*ppz); } while (--ix > 0); + + COERSION(pzCopyright); + COERSION(pzCopyNotice); + COERSION(pzFullVersion); + COERSION(pzUsageTitle); + COERSION(pzExplain); + COERSION(pzDetail); + option_usage_text.field_ct = 0; + + for (ix = ntpqOptions.optCt; ix > 0; ix--, pOD++) + coerce_it((void*)&(pOD->pzText)); } - option_usage_text.field_ct = 0; - { + if ((ntpqOptions.fOptSet & OPTPROC_NXLAT_OPT_CFG) == 0) { tOptDesc* pOD = ntpqOptions.pOptDesc; - int ix = ntpqOptions.optCt; + int ix; - for (;;) { - pOD->pzText = AO_gettext(pOD->pzText); - pOD->pz_NAME = AO_gettext(pOD->pz_NAME); - pOD->pz_Name = AO_gettext(pOD->pz_Name); - pOD->pz_DisableName = AO_gettext(pOD->pz_DisableName); - pOD->pz_DisablePfx = AO_gettext(pOD->pz_DisablePfx); - if (--ix <= 0) - break; - pOD++; + for (ix = ntpqOptions.optCt; ix > 0; ix--, pOD++) { + coerce_it((void*)&(pOD->pz_Name)); + coerce_it((void*)&(pOD->pz_DisableName)); + coerce_it((void*)&(pOD->pz_DisablePfx)); } + /* prevent re-translation */ + ntpqOptions.fOptSet |= OPTPROC_NXLAT_OPT_CFG | OPTPROC_NXLAT_OPT; } - COERSION(pzCopyright); - COERSION(pzCopyNotice); - COERSION(pzFullVersion); - COERSION(pzUsageTitle); - COERSION(pzExplain); - COERSION(pzDetail); } #endif /* ENABLE_NLS */ diff -urN src/contrib/ntp/ntpq/ntpq-opts.def src.ntp/contrib/ntp/ntpq/ntpq-opts.def --- src/contrib/ntp/ntpq/ntpq-opts.def 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpq/ntpq-opts.def 2009-12-09 08:36:36.000000000 +0100 @@ -14,8 +14,8 @@ flag = { name = ipv4; + flags-cant = ipv6; value = 4; - equivalence = ipv4; descrip = "Force IPv4 DNS name resolution"; doc = <<- _EndOfDoc_ Force DNS resolution of following host names on the command line @@ -25,8 +25,8 @@ flag = { name = ipv6; + flags-cant = ipv4; value = 6; - equivalence = ipv4; descrip = "Force IPv6 DNS name resolution"; doc = <<- _EndOfDoc_ Force DNS resolution of following host names on the command line @@ -41,7 +41,7 @@ descrip = "run a command and exit"; max = NOLIMIT; arg-name = cmd; - stack-arg; + call-proc = ntpq_custom_opt_handler; doc = <<- _EndOfDoc_ The following argument is interpreted as an interactive format command and is added to the list of commands to be executed on the specified @@ -56,6 +56,7 @@ value = p; descrip = "Print a list of the peers"; flags-cant = interactive; + call-proc = ntpq_custom_opt_handler; doc = <<- _EndOfDoc_ Print a list of the peers known to the server as well as a summary of their state. This is equivalent to the 'peers' interactive command. @@ -83,6 +84,20 @@ _EndOfDoc_; }; +flag = { + name = old-rv; + descrip = "Always output status line with readvar"; + doc = <<- _EndOfDoc_ + By default, ntpq now suppresses the associd=... line that + precedes the output of "readvar" (alias "rv") when a single + variable is requested, such as ntpq -c "rv 0 offset". This + option causes ntpq to include both lines of output for a + single-variable readvar. Using an environment variable to + preset this option in a script will enable both older and + newer ntpq to behave identically in this regard. + _EndOfDoc_; +}; + detail = <<- _END_DETAIL The [= prog-name =] diff -urN src/contrib/ntp/ntpq/ntpq-opts.h src.ntp/contrib/ntp/ntpq/ntpq-opts.h --- src/contrib/ntp/ntpq/ntpq-opts.h 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpq/ntpq-opts.h 2010-07-09 04:24:18.000000000 +0200 @@ -1,11 +1,11 @@ /* * EDIT THIS FILE WITH CAUTION (ntpq-opts.h) * - * It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:26 AM EST + * It has been AutoGen-ed July 9, 2010 at 02:24:18 AM by AutoGen 5.10 * From the definitions ntpq-opts.def * and the template file options * - * Generated from AutoOpts 29:0:4 templates. + * Generated from AutoOpts 33:0:8 templates. */ /* @@ -19,7 +19,7 @@ * * This source file is copyrighted and licensed under the following terms: * - * ntpq copyright 1970-2009 David L. Mills and/or others - all rights reserved + * ntpq copyright (c) 1970-2010 David L. Mills and/or others - all rights reserved * * see html/copyright.html */ @@ -30,7 +30,7 @@ * "AutoOpts" chapter. Please refer to that doc for usage help. */ #ifndef AUTOOPTS_NTPQ_OPTS_H_GUARD -#define AUTOOPTS_NTPQ_OPTS_H_GUARD +#define AUTOOPTS_NTPQ_OPTS_H_GUARD 1 #include "config.h" #include @@ -41,7 +41,7 @@ * tolerable version is at least as old as what was current when the header * template was released. */ -#define AO_TEMPLATE_VERSION 118784 +#define AO_TEMPLATE_VERSION 135168 #if (AO_TEMPLATE_VERSION < OPTIONS_MINIMUM_VERSION) \ || (AO_TEMPLATE_VERSION > OPTIONS_STRUCT_VERSION) # error option template version mismatches autoopts/options.h header @@ -52,24 +52,25 @@ * Enumeration of each option: */ typedef enum { - INDEX_OPT_IPV4 = 0, - INDEX_OPT_IPV6 = 1, - INDEX_OPT_COMMAND = 2, - INDEX_OPT_DEBUG_LEVEL = 3, - INDEX_OPT_SET_DEBUG_LEVEL = 4, - INDEX_OPT_PEERS = 5, - INDEX_OPT_INTERACTIVE = 6, - INDEX_OPT_NUMERIC = 7, - INDEX_OPT_VERSION = 8, - INDEX_OPT_HELP = 9, - INDEX_OPT_MORE_HELP = 10, - INDEX_OPT_SAVE_OPTS = 11, - INDEX_OPT_LOAD_OPTS = 12 + INDEX_OPT_IPV4 = 0, + INDEX_OPT_IPV6 = 1, + INDEX_OPT_COMMAND = 2, + INDEX_OPT_DEBUG_LEVEL = 3, + INDEX_OPT_SET_DEBUG_LEVEL = 4, + INDEX_OPT_PEERS = 5, + INDEX_OPT_INTERACTIVE = 6, + INDEX_OPT_NUMERIC = 7, + INDEX_OPT_OLD_RV = 8, + INDEX_OPT_VERSION = 9, + INDEX_OPT_HELP = 10, + INDEX_OPT_MORE_HELP = 11, + INDEX_OPT_SAVE_OPTS = 12, + INDEX_OPT_LOAD_OPTS = 13 } teOptIndex; -#define OPTION_CT 13 -#define NTPQ_VERSION "4.2.4p8" -#define NTPQ_FULL_VERSION "ntpq - standard NTP query program - Ver. 4.2.4p8" +#define OPTION_CT 14 +#define NTPQ_VERSION "4.2.6p2" +#define NTPQ_FULL_VERSION "ntpq - standard NTP query program - Ver. 4.2.6p2" /* * Interface defines for all options. Replace "n" with the UPPER_CASED @@ -128,6 +129,10 @@ # warning undefining NUMERIC due to option name conflict # undef NUMERIC # endif +# ifdef OLD_RV +# warning undefining OLD_RV due to option name conflict +# undef OLD_RV +# endif #else /* NO_OPTION_NAME_WARNINGS */ # undef IPV4 # undef IPV6 @@ -137,29 +142,25 @@ # undef PEERS # undef INTERACTIVE # undef NUMERIC +# undef OLD_RV #endif /* NO_OPTION_NAME_WARNINGS */ -/* +/* * * * * * + * * Interface defines for specific options. */ #define VALUE_OPT_IPV4 '4' -#define WHICH_OPT_IPV4 (DESC(IPV4).optActualValue) -#define WHICH_IDX_IPV4 (DESC(IPV4).optActualIndex) #define VALUE_OPT_IPV6 '6' #define VALUE_OPT_COMMAND 'c' -#ifdef DEBUG #define VALUE_OPT_DEBUG_LEVEL 'd' -#endif /* DEBUG */ -#ifdef DEBUG #define VALUE_OPT_SET_DEBUG_LEVEL 'D' -#endif /* DEBUG */ #define VALUE_OPT_PEERS 'p' #define VALUE_OPT_INTERACTIVE 'i' #define VALUE_OPT_NUMERIC 'n' - -#define VALUE_OPT_VERSION 'v' +#define VALUE_OPT_OLD_RV 8 #define VALUE_OPT_HELP '?' #define VALUE_OPT_MORE_HELP '!' +#define VALUE_OPT_VERSION INDEX_OPT_VERSION #define VALUE_OPT_SAVE_OPTS '>' #define VALUE_OPT_LOAD_OPTS '<' #define SET_OPT_SAVE_OPTS(a) STMTS( \ @@ -176,7 +177,7 @@ ntpqOptions.pzCurOpt = NULL ) #define START_OPT RESTART_OPT(1) #define USAGE(c) (*ntpqOptions.pUsageProc)( &ntpqOptions, c ) -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/opthead.tpl near line 360 */ +/* extracted from /usr/local/gnu/share/autogen/opthead.tpl near line 409 */ /* * * * * * * @@ -188,18 +189,37 @@ extern tOptions ntpqOptions; -#ifndef _ -# if ENABLE_NLS -# include - static inline char* aoGetsText( char const* pz ) { - if (pz == NULL) return NULL; - return (char*)gettext( pz ); - } -# define _(s) aoGetsText(s) -# else /* ENABLE_NLS */ -# define _(s) s -# endif /* ENABLE_NLS */ -#endif +#if defined(ENABLE_NLS) +# ifndef _ +# include + static inline char* aoGetsText( char const* pz ) { + if (pz == NULL) return NULL; + return (char*)gettext( pz ); + } +# define _(s) aoGetsText(s) +# endif /* _() */ + +# define OPT_NO_XLAT_CFG_NAMES STMTS(ntpqOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT_CFG;) +# define OPT_NO_XLAT_OPT_NAMES STMTS(ntpqOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG;) + +# define OPT_XLAT_CFG_NAMES STMTS(ntpqOptions.fOptSet &= \ + ~(OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG);) +# define OPT_XLAT_OPT_NAMES STMTS(ntpqOptions.fOptSet &= \ + ~OPTPROC_NXLAT_OPT;) + +#else /* ENABLE_NLS */ +# define OPT_NO_XLAT_CFG_NAMES +# define OPT_NO_XLAT_OPT_NAMES + +# define OPT_XLAT_CFG_NAMES +# define OPT_XLAT_OPT_NAMES + +# ifndef _ +# define _(_s) _s +# endif +#endif /* ENABLE_NLS */ #ifdef __cplusplus } diff -urN src/contrib/ntp/ntpq/ntpq-opts.texi src.ntp/contrib/ntp/ntpq/ntpq-opts.texi --- src/contrib/ntp/ntpq/ntpq-opts.texi 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpq/ntpq-opts.texi 2010-07-09 04:24:28.000000000 +0200 @@ -6,7 +6,7 @@ # # EDIT THIS FILE WITH CAUTION (ntpq-opts.texi) # -# It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:28 AM EST +# It has been AutoGen-ed July 9, 2010 at 02:24:28 AM by AutoGen 5.10 # From the definitions ntpq-opts.def # and the template file aginfo.tpl @end ignore @@ -34,6 +34,7 @@ * ntpq ipv4:: ipv4 option (-4) * ntpq ipv6:: ipv6 option (-6) * ntpq numeric:: numeric option (-n) +* ntpq old-rv:: old-rv option * ntpq peers:: peers option (-p) * ntpq set-debug-level:: set-debug-level option (-D) @end menu @@ -46,7 +47,7 @@ @exampleindent 0 @example -ntpq - standard NTP query program - Ver. 4.2.5p247-RC +ntpq - standard NTP query program - Ver. 4.2.6p2 USAGE: ntpq [ - [] | --[@{=| @}] ]... [ host ...] Flg Arg Option-Name Description -4 no ipv4 Force IPv4 DNS name resolution @@ -82,7 +83,7 @@ or by a single hyphen and the flag character. The following option preset mechanisms are supported: - - reading file /users/stenn/.ntprc + - reading file /deacon/users/stenn/.ntprc - reading file /deacon/backroom/snaps/ntp-stable/ntpq/.ntprc - examining environment variables named NTPQ_* @@ -108,7 +109,8 @@ This option has some usage constraints. It: @itemize @bullet @item -is a member of the ipv4 class of options. +must not appear in combination with any of the following options: +ipv6. @end itemize Force DNS resolution of following host names on the command line @@ -123,7 +125,8 @@ This option has some usage constraints. It: @itemize @bullet @item -is a member of the ipv4 class of options. +must not appear in combination with any of the following options: +ipv4. @end itemize Force DNS resolution of following host names on the command line @@ -155,8 +158,6 @@ @itemize @bullet @item may appear an unlimited number of times. -@item -must be compiled in by defining @code{DEBUG} during the compilation. @end itemize Increase the debugging message output level. @@ -171,8 +172,6 @@ @itemize @bullet @item may appear an unlimited number of times. -@item -must be compiled in by defining @code{DEBUG} during the compilation. @end itemize Set the output debugging level. Can be supplied multiple times, @@ -217,3 +216,16 @@ This is the ``numeric host addresses'' option. Output all host addresses in dotted-quad numeric format rather than converting to the canonical host names. + +@node ntpq old-rv +@subsection old-rv option +@cindex ntpq-old-rv + +This is the ``always output status line with readvar'' option. +By default, ntpq now suppresses the associd=... line that +precedes the output of "readvar" (alias "rv") when a single +variable is requested, such as ntpq -c "rv 0 offset". This +option causes ntpq to include both lines of output for a +single-variable readvar. Using an environment variable to +preset this option in a script will enable both older and +newer ntpq to behave identically in this regard. diff -urN src/contrib/ntp/ntpq/ntpq-subs.c src.ntp/contrib/ntp/ntpq/ntpq-subs.c --- src/contrib/ntp/ntpq/ntpq-subs.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpq/ntpq-subs.c 2010-07-09 04:17:43.000000000 +0200 @@ -7,8 +7,9 @@ #include #include -#include "ntpq.h" #include "ntp_stdlib.h" +#include "ntpq.h" +#include "ntpq-opts.h" extern char * chosts[]; extern char currenthost[]; @@ -18,57 +19,64 @@ /* * Declarations for command handlers in here */ -static int checkassocid P((u_int32)); -static char * strsave P((char *)); -static struct varlist *findlistvar P((struct varlist *, char *)); -static void doaddvlist P((struct varlist *, char *)); -static void dormvlist P((struct varlist *, char *)); -static void doclearvlist P((struct varlist *)); -static void makequerydata P((struct varlist *, int *, char *)); -static int doquerylist P((struct varlist *, int, int, int, u_short *, int *, char **)); -static void doprintvlist P((struct varlist *, FILE *)); -static void addvars P((struct parse *, FILE *)); -static void rmvars P((struct parse *, FILE *)); -static void clearvars P((struct parse *, FILE *)); -static void showvars P((struct parse *, FILE *)); -static int dolist P((struct varlist *, int, int, int, FILE *)); -static void readlist P((struct parse *, FILE *)); -static void writelist P((struct parse *, FILE *)); -static void readvar P((struct parse *, FILE *)); -static void writevar P((struct parse *, FILE *)); -static void clocklist P((struct parse *, FILE *)); -static void clockvar P((struct parse *, FILE *)); -static int findassidrange P((u_int32, u_int32, int *, int *)); -static void mreadlist P((struct parse *, FILE *)); -static void mreadvar P((struct parse *, FILE *)); -static int dogetassoc P((FILE *)); -static void printassoc P((int, FILE *)); -static void associations P((struct parse *, FILE *)); -static void lassociations P((struct parse *, FILE *)); -static void passociations P((struct parse *, FILE *)); -static void lpassociations P((struct parse *, FILE *)); +static int checkassocid (u_int32); +static struct varlist *findlistvar (struct varlist *, char *); +static void doaddvlist (struct varlist *, char *); +static void dormvlist (struct varlist *, char *); +static void doclearvlist (struct varlist *); +static void makequerydata (struct varlist *, int *, char *); +static int doquerylist (struct varlist *, int, int, int, + u_short *, int *, char **); +static void doprintvlist (struct varlist *, FILE *); +static void addvars (struct parse *, FILE *); +static void rmvars (struct parse *, FILE *); +static void clearvars (struct parse *, FILE *); +static void showvars (struct parse *, FILE *); +static int dolist (struct varlist *, int, int, int, + FILE *); +static void readlist (struct parse *, FILE *); +static void writelist (struct parse *, FILE *); +static void readvar (struct parse *, FILE *); +static void writevar (struct parse *, FILE *); +static void clocklist (struct parse *, FILE *); +static void clockvar (struct parse *, FILE *); +static int findassidrange (u_int32, u_int32, int *, int *); +static void mreadlist (struct parse *, FILE *); +static void mreadvar (struct parse *, FILE *); +static int dogetassoc (FILE *); +static void printassoc (int, FILE *); +static void associations (struct parse *, FILE *); +static void lassociations (struct parse *, FILE *); +static void passociations (struct parse *, FILE *); +static void lpassociations (struct parse *, FILE *); #ifdef UNUSED -static void radiostatus P((struct parse *, FILE *)); +static void radiostatus (struct parse *, FILE *); #endif /* UNUSED */ -static void pstatus P((struct parse *, FILE *)); -static long when P((l_fp *, l_fp *, l_fp *)); -static char * prettyinterval P((char *, long)); -static int doprintpeers P((struct varlist *, int, int, int, char *, FILE *, int)); -static int dogetpeers P((struct varlist *, int, FILE *, int)); -static void dopeers P((int, FILE *, int)); -static void peers P((struct parse *, FILE *)); -static void lpeers P((struct parse *, FILE *)); -static void doopeers P((int, FILE *, int)); -static void opeers P((struct parse *, FILE *)); -static void lopeers P((struct parse *, FILE *)); +static void pstatus (struct parse *, FILE *); +static long when (l_fp *, l_fp *, l_fp *); +static char * prettyinterval (char *, size_t, long); +static int doprintpeers (struct varlist *, int, int, int, char *, FILE *, int); +static int dogetpeers (struct varlist *, int, FILE *, int); +static void dopeers (int, FILE *, int); +static void peers (struct parse *, FILE *); +static void lpeers (struct parse *, FILE *); +static void doopeers (int, FILE *, int); +static void opeers (struct parse *, FILE *); +static void lopeers (struct parse *, FILE *); +static void config (struct parse *, FILE *); +static void saveconfig (struct parse *, FILE *); +static void config_from_file(struct parse *, FILE *); /* * Commands we understand. Ntpdc imports this. */ struct xcmd opcmds[] = { + { "saveconfig", saveconfig, { NTP_STR, NO, NO, NO }, + { "filename", "", "", ""}, + "save ntpd configuration to file, . for current config file"}, { "associations", associations, { NO, NO, NO, NO }, { "", "", "", "" }, "print list of association ID's and statuses for the server's peers" }, @@ -150,6 +158,12 @@ { "lopeers", lopeers, { OPT|IP_VERSION, NO, NO, NO }, { "-4|-6", "", "", "" }, "obtain and print a list of all peers and clients showing dstadr [IP version]" }, + { ":config", config, { NTP_STR, NO, NO, NO }, + { "", "", "", "" }, + "send a remote configuration command to ntpd" }, + { "config-from-file", config_from_file, { NTP_STR, NO, NO, NO }, + { "", "", "", "" }, + "configure ntpd using the configuration filename" }, { 0, 0, { NO, NO, NO, NO }, { "-4|-6", "", "", "" }, "" } }; @@ -158,30 +172,31 @@ /* * Variable list data space */ +#define MAXLINE 512 /* maximum length of a line */ #define MAXLIST 64 /* maximum number of variables in list */ #define LENHOSTNAME 256 /* host name is 256 characters long */ /* * Old CTL_PST defines for version 2. */ -#define OLD_CTL_PST_CONFIG 0x80 +#define OLD_CTL_PST_CONFIG 0x80 #define OLD_CTL_PST_AUTHENABLE 0x40 #define OLD_CTL_PST_AUTHENTIC 0x20 -#define OLD_CTL_PST_REACH 0x10 -#define OLD_CTL_PST_SANE 0x08 -#define OLD_CTL_PST_DISP 0x04 +#define OLD_CTL_PST_REACH 0x10 +#define OLD_CTL_PST_SANE 0x08 +#define OLD_CTL_PST_DISP 0x04 + #define OLD_CTL_PST_SEL_REJECT 0 #define OLD_CTL_PST_SEL_SELCAND 1 #define OLD_CTL_PST_SEL_SYNCCAND 2 #define OLD_CTL_PST_SEL_SYSPEER 3 - char flash2[] = " .+* "; /* flash decode for version 2 */ char flash3[] = " x.-+#*o"; /* flash decode for peer status version 3 */ struct varlist { char *name; char *value; -} varlist[MAXLIST] = { { 0, 0 } }; +} g_varlist[MAXLIST] = { { 0, 0 } }; /* * Imported from ntpq.c @@ -217,29 +232,6 @@ /* - * strsave - save a string - * XXX - should be in libntp.a - */ -static char * -strsave( - char *str - ) -{ - char *cp; - u_int len; - - len = strlen(str) + 1; - if ((cp = (char *)malloc(len)) == NULL) { - (void) fprintf(stderr, "Malloc failed!!\n"); - exit(1); - } - - memmove(cp, str, len); - return (cp); -} - - -/* * findlistvar - look for the named variable in a list and return if found */ static struct varlist * @@ -282,14 +274,14 @@ } if (vl->name == 0) { - vl->name = strsave(name); + vl->name = estrdup(name); } else if (vl->value != 0) { free(vl->value); vl->value = 0; } if (value != 0) - vl->value = strsave(value); + vl->value = estrdup(value); } } @@ -318,7 +310,7 @@ free((void *)vl->name); if (vl->value != 0) free(vl->value); - for ( ; (vl+1) < (varlist+MAXLIST) + for ( ; (vl+1) < (g_varlist + MAXLIST) && (vl+1)->name != 0; vl++) { vl->name = (vl+1)->name; vl->value = (vl+1)->value; @@ -442,7 +434,6 @@ } } - /* * addvars - add variables to the variable list */ @@ -453,7 +444,7 @@ FILE *fp ) { - doaddvlist(varlist, pcmd->argval[0].string); + doaddvlist(g_varlist, pcmd->argval[0].string); } @@ -467,7 +458,7 @@ FILE *fp ) { - dormvlist(varlist, pcmd->argval[0].string); + dormvlist(g_varlist, pcmd->argval[0].string); } @@ -481,7 +472,7 @@ FILE *fp ) { - doclearvlist(varlist); + doclearvlist(g_varlist); } @@ -495,7 +486,7 @@ FILE *fp ) { - doprintvlist(varlist, fp); + doprintvlist(g_varlist, fp); } @@ -515,6 +506,16 @@ int res; int dsize; u_short rstatus; + int quiet; + + /* + * if we're asking for specific variables don't include the + * status header line in the output. + */ + if (old_rv) + quiet = 0; + else + quiet = (vlist->name != NULL); res = doquerylist(vlist, op, associd, 0, &rstatus, &dsize, &datap); @@ -534,8 +535,9 @@ return 1; } - (void) fprintf(fp,"assID=%d ",associd); - printvars(dsize, datap, (int)rstatus, type, fp); + if (!quiet) + fprintf(fp,"associd=%d ",associd); + printvars(dsize, datap, (int)rstatus, type, quiet, fp); return 1; } @@ -561,7 +563,7 @@ return; } - (void) dolist(varlist, associd, CTL_OP_READVAR, + (void) dolist(g_varlist, associd, CTL_OP_READVAR, (associd == 0) ? TYPE_SYS : TYPE_PEER, fp); } @@ -591,7 +593,7 @@ return; } - res = doquerylist(varlist, CTL_OP_WRITEVAR, associd, 1, &rstatus, + res = doquerylist(g_varlist, CTL_OP_WRITEVAR, associd, 1, &rstatus, &dsize, &datap); if (res != 0) @@ -602,9 +604,9 @@ if (dsize == 0) (void) fprintf(fp, "done! (no data returned)\n"); else { - (void) fprintf(fp,"assID=%d ",associd); + (void) fprintf(fp,"associd=%d ",associd); printvars(dsize, datap, (int)rstatus, - (associd != 0) ? TYPE_PEER : TYPE_SYS, fp); + (associd != 0) ? TYPE_PEER : TYPE_SYS, 0, fp); } return; } @@ -677,9 +679,12 @@ if (dsize == 0) (void) fprintf(fp, "done! (no data returned)\n"); else { - (void) fprintf(fp,"assID=%d ",associd); + (void) fprintf(fp,"associd=%d ",associd); printvars(dsize, datap, (int)rstatus, - (associd != 0) ? TYPE_PEER : TYPE_SYS, fp); + (associd != 0) + ? TYPE_PEER + : TYPE_SYS, + 0, fp); } return; } @@ -706,7 +711,7 @@ return; } - (void) dolist(varlist, associd, CTL_OP_READCLOCK, TYPE_CLOCK, fp); + (void) dolist(g_varlist, associd, CTL_OP_READCLOCK, TYPE_CLOCK, fp); } @@ -759,8 +764,8 @@ } if (assid2 == 0 || assid2 > 65535) { - (void) fprintf(stderr, - "***Invalid association ID %lu specified\n", (u_long)assid2); + fprintf(stderr, + "***Invalid association ID %lu specified\n", (u_long)assid2); return 0; } @@ -818,7 +823,7 @@ for (i = from; i <= to; i++) { if (i != from) (void) fprintf(fp, "\n"); - if (!dolist(varlist, (int)assoc_cache[i].assid, + if (!dolist(g_varlist, (int)assoc_cache[i].assid, CTL_OP_READVAR, TYPE_PEER, fp)) return; } @@ -852,7 +857,7 @@ for (i = from; i <= to; i++) { if (i != from) (void) fprintf(fp, "\n"); - if (!dolist(varlist, (int)assoc_cache[i].assid, + if (!dolist(g_varlist, (int)assoc_cache[i].assid, CTL_OP_READVAR, TYPE_PEER, fp)) break; } @@ -942,7 +947,7 @@ * Output a header */ (void) fprintf(fp, - "\nind assID status conf reach auth condition last_event cnt\n"); + "\nind assid status conf reach auth condition last_event cnt\n"); (void) fprintf(fp, "===========================================================\n"); for (i = 0; i < numassoc; i++) { @@ -955,112 +960,151 @@ conf = "yes"; else conf = "no"; - if (statval & CTL_PST_REACH || 1) { - reach = "yes"; + if (statval & CTL_PST_BCAST) { + reach = "none"; + if (statval & CTL_PST_AUTHENABLE) + auth = "yes"; + else + auth = "none"; + } else { + if (statval & CTL_PST_REACH) + reach = "yes"; + else + reach = "no"; if (statval & CTL_PST_AUTHENABLE) { if (statval & CTL_PST_AUTHENTIC) auth = "ok "; else auth = "bad"; - } else + } else { auth = "none"; + } + } + if (pktversion > NTP_OLDVERSION) { + switch (statval & 0x7) { - if (pktversion > NTP_OLDVERSION) - switch (statval & 0x7) { - case CTL_PST_SEL_REJECT: - condition = "reject"; - break; - case CTL_PST_SEL_SANE: - condition = "falsetick"; - break; - case CTL_PST_SEL_CORRECT: - condition = "excess"; - break; - case CTL_PST_SEL_SELCAND: - condition = "outlyer"; - break; - case CTL_PST_SEL_SYNCCAND: - condition = "candidat"; - break; - case CTL_PST_SEL_DISTSYSPEER: - condition = "selected"; - break; - case CTL_PST_SEL_SYSPEER: - condition = "sys.peer"; - break; - case CTL_PST_SEL_PPS: - condition = "pps.peer"; - break; - } - else - switch (statval & 0x3) { - case OLD_CTL_PST_SEL_REJECT: - if (!(statval & OLD_CTL_PST_SANE)) + case CTL_PST_SEL_REJECT: + condition = "reject"; + break; + + case CTL_PST_SEL_SANE: + condition = "falsetick"; + break; + + case CTL_PST_SEL_CORRECT: + condition = "excess"; + break; + + case CTL_PST_SEL_SELCAND: + condition = "outlyer"; + break; + + case CTL_PST_SEL_SYNCCAND: + condition = "candidate"; + break; + + case CTL_PST_SEL_EXCESS: + condition = "backup"; + break; + + case CTL_PST_SEL_SYSPEER: + condition = "sys.peer"; + break; + + case CTL_PST_SEL_PPS: + condition = "pps.peer"; + break; + } + } else { + switch (statval & 0x3) { + + case OLD_CTL_PST_SEL_REJECT: + if (!(statval & OLD_CTL_PST_SANE)) condition = "insane"; - else if (!(statval & OLD_CTL_PST_DISP)) + else if (!(statval & OLD_CTL_PST_DISP)) condition = "hi_disp"; - else + else condition = ""; - break; - case OLD_CTL_PST_SEL_SELCAND: - condition = "sel_cand"; - break; - case OLD_CTL_PST_SEL_SYNCCAND: - condition = "sync_cand"; - break; - case OLD_CTL_PST_SEL_SYSPEER: - condition = "sys_peer"; - break; - } + break; - } else { - reach = "no"; - auth = condition = ""; - } + case OLD_CTL_PST_SEL_SELCAND: + condition = "sel_cand"; + break; + + case OLD_CTL_PST_SEL_SYNCCAND: + condition = "sync_cand"; + break; + case OLD_CTL_PST_SEL_SYSPEER: + condition = "sys_peer"; + break; + } + } switch (PEER_EVENT|event) { - case EVNT_PEERIPERR: - last_event = "IP error"; - break; - case EVNT_PEERAUTH: - last_event = "auth fail"; + + case PEVNT_MOBIL: + last_event = "mobilize"; break; - case EVNT_UNREACH: - last_event = "lost reach"; + + case PEVNT_DEMOBIL: + last_event = "demobilize"; break; - case EVNT_REACH: + + case PEVNT_REACH: last_event = "reachable"; break; - case EVNT_PEERCLOCK: - last_event = "clock expt"; + + case PEVNT_UNREACH: + last_event = "unreachable"; + break; + + case PEVNT_RESTART: + last_event = "restart"; break; -#if 0 - case EVNT_PEERSTRAT: - last_event = "stratum chg"; + + case PEVNT_REPLY: + last_event = "no_reply"; break; -#endif - default: + + case PEVNT_RATE: + last_event = "rate_exceeded"; + break; + + case PEVNT_DENY: + last_event = "access_denied"; + break; + + case PEVNT_ARMED: + last_event = "leap_armed"; + break; + + case PEVNT_NEWPEER: + last_event = "sys_peer"; + break; + + case PEVNT_CLOCK: + last_event = "clock_alarm"; + break; + + default: last_event = ""; break; } - - if (event_count != 0) - cnt = uinttoa(event_count); - else - cnt = ""; - (void) sprintf(buf, - "%3d %5u %04x %3.3s %4s %4.4s %9.9s %11s %2s", - i+1, assoc_cache[i].assid, assoc_cache[i].status, - conf, reach, auth, condition, last_event, cnt); - bp = &buf[strlen(buf)]; - while (bp > buf && *(bp-1) == ' ') - *(--bp) = '\0'; - (void) fprintf(fp, "%s\n", buf); + cnt = uinttoa(event_count); + snprintf(buf, sizeof(buf), + "%3d %5u %04x %3.3s %4s %4.4s %9.9s %11s %2s", + i + 1, assoc_cache[i].assid, + assoc_cache[i].status, conf, reach, auth, + condition, last_event, cnt); + bp = buf + strlen(buf); + while (bp > buf && ' ' == bp[-1]) + --bp; + bp[0] = '\0'; + fprintf(fp, "%s\n", buf); } } - /* * associations - get, record and print a list of associations */ @@ -1119,6 +1163,40 @@ } +/* + * saveconfig - dump ntp server configuration to server file + */ +static void +saveconfig( + struct parse *pcmd, + FILE *fp + ) +{ + char *datap; + int res; + int dsize; + u_short rstatus; + + if (0 == pcmd->nargs) + return; + + res = doquery(CTL_OP_SAVECONFIG, 0, 1, + strlen(pcmd->argval[0].string), + pcmd->argval[0].string, &rstatus, &dsize, + &datap); + + if (res != 0) + return; + + if (0 == dsize) + fprintf(fp, "(no response message, curiously)"); + else { + datap[dsize] = '\0'; + fprintf(fp, "%s", datap); + } +} + + #ifdef UNUSED /* * radiostatus - print the radio status returned by the server @@ -1186,8 +1264,8 @@ return; } - (void) fprintf(fp,"assID=%d ",associd); - printvars(dsize, datap, (int)rstatus, TYPE_PEER, fp); + (void) fprintf(fp,"associd=%d ",associd); + printvars(dsize, datap, (int)rstatus, TYPE_PEER, 0, fp); } @@ -1220,6 +1298,7 @@ static char * prettyinterval( char *buf, + size_t cb, long diff ) { @@ -1230,40 +1309,38 @@ } if (diff <= 2048) { - (void) sprintf(buf, "%ld", (long int)diff); + snprintf(buf, cb, "%ld", diff); return buf; } diff = (diff + 29) / 60; if (diff <= 300) { - (void) sprintf(buf, "%ldm", (long int)diff); + snprintf(buf, cb, "%ldm", diff); return buf; } diff = (diff + 29) / 60; if (diff <= 96) { - (void) sprintf(buf, "%ldh", (long int)diff); + snprintf(buf, cb, "%ldh", diff); return buf; } diff = (diff + 11) / 24; - (void) sprintf(buf, "%ldd", (long int)diff); + snprintf(buf, cb, "%ldd", diff); return buf; } static char decodeaddrtype( - struct sockaddr_storage *sock + sockaddr_u *sock ) { char ch = '-'; u_int32 dummy; - struct sockaddr_in6 *sin6; - switch(sock->ss_family) { + switch(AF(sock)) { case AF_INET: - dummy = ((struct sockaddr_in *)sock)->sin_addr.s_addr; - dummy = ntohl(dummy); + dummy = SRCADR(sock); ch = (char)(((dummy&0xf0000000)==0xe0000000) ? 'm' : ((dummy&0x000000ff)==0x000000ff) ? 'b' : ((dummy&0xffffffff)==0x7f000001) ? 'l' : @@ -1271,8 +1348,7 @@ 'u'); break; case AF_INET6: - sin6 = (struct sockaddr_in6 *)sock; - if (IN6_IS_ADDR_MULTICAST(&sin6->sin6_addr)) + if (IN6_IS_ADDR_MULTICAST(PSOCK_ADDR6(sock))) ch = 'm'; else ch = 'u'; @@ -1356,10 +1432,11 @@ int i; int c; - struct sockaddr_storage srcadr; - struct sockaddr_storage dstadr; + sockaddr_u srcadr; + sockaddr_u dstadr; u_long srcport = 0; char *dstadr_refid = "0.0.0.0"; + size_t drlen; u_long stratum = 0; long ppoll = 0; long hpoll = 0; @@ -1381,8 +1458,8 @@ memset((char *)havevar, 0, sizeof(havevar)); get_systime(&ts); - memset((char *)&srcadr, 0, sizeof(struct sockaddr_storage)); - memset((char *)&dstadr, 0, sizeof(struct sockaddr_storage)); + ZERO_SOCK(&srcadr); + ZERO_SOCK(&dstadr); /* Initialize by zeroing out estimate variables */ memset((char *)&estoffset, 0, sizeof(l_fp)); @@ -1391,22 +1468,23 @@ memset((char *)&estdisp, 0, sizeof(l_fp)); while (nextvar(&datalen, &data, &name, &value)) { - struct sockaddr_storage dum_store; + sockaddr_u dum_store; i = findvar(name, peer_var, 1); if (i == 0) continue; /* don't know this one */ switch (i) { case CP_SRCADR: - if (decodenetnum(value, &srcadr)) + if (decodenetnum(value, &srcadr)) { havevar[HAVE_SRCADR] = 1; + } break; case CP_DSTADR: - if (decodenetnum(value, &dum_store)) + if (decodenetnum(value, &dum_store)) { type = decodeaddrtype(&dum_store); - if (pvl == opeervarlist) { - if (decodenetnum(value, &dstadr)) { + if (pvl == opeervarlist) { havevar[HAVE_DSTADR] = 1; + dstadr = dum_store; dstadr_refid = stoa(&dstadr); } } @@ -1415,8 +1493,8 @@ if (pvl == peervarlist) { havevar[HAVE_REFID] = 1; if (*value == '\0') { - dstadr_refid = "0.0.0.0"; - } else if ((int)strlen(value) <= 4) { + dstadr_refid = ""; + } else if (strlen(value) <= 4) { refid_string[0] = '.'; (void) strcpy(&refid_string[1], value); i = strlen(refid_string); @@ -1424,11 +1502,10 @@ refid_string[i+1] = '\0'; dstadr_refid = refid_string; } else if (decodenetnum(value, &dstadr)) { - if (SOCKNUL(&dstadr)) + if (SOCK_UNSPEC(&dstadr)) dstadr_refid = "0.0.0.0"; - else if ((dstadr.ss_family == AF_INET) - && ISREFCLOCKADR(&dstadr)) - dstadr_refid = + else if (ISREFCLOCKADR(&dstadr)) + dstadr_refid = refnumtoa(&dstadr); else dstadr_refid = @@ -1511,18 +1588,26 @@ else c = flash2[CTL_PEER_STATVAL(rstatus) & 0x3]; if (numhosts > 1) - (void) fprintf(fp, "%-*s ", maxhostlen, currenthost); - if (af == 0 || srcadr.ss_family == af){ - strcpy(clock_name, nntohost(&srcadr)); - - (void) fprintf(fp, - "%c%-15.15s %-15.15s %2ld %c %4.4s %4.4s %3lo %7.7s %8.7s %7.7s\n", - c, clock_name, dstadr_refid, stratum, type, - prettyinterval(whenbuf, when(&ts, &rec, &reftime)), - prettyinterval(pollbuf, (int)poll_sec), reach, - lfptoms(&estdelay, 3), lfptoms(&estoffset, 3), - havevar[HAVE_JITTER] ? lfptoms(&estjitter, 3) : - lfptoms(&estdisp, 3)); + fprintf(fp, "%-*s ", maxhostlen, currenthost); + if (AF_UNSPEC == af || AF(&srcadr) == af) { + strncpy(clock_name, nntohost(&srcadr), sizeof(clock_name)); + fprintf(fp, "%c%-15.15s ", c, clock_name); + drlen = strlen(dstadr_refid); + makeascii(drlen, dstadr_refid, fp); + while (drlen++ < 15) + fputc(' ', fp); + fprintf(fp, + " %2ld %c %4.4s %4.4s %3lo %7.7s %8.7s %7.7s\n", + stratum, type, + prettyinterval(whenbuf, sizeof(whenbuf), + when(&ts, &rec, &reftime)), + prettyinterval(pollbuf, sizeof(pollbuf), + (int)poll_sec), + reach, lfptoms(&estdelay, 3), + lfptoms(&estoffset, 3), + (havevar[HAVE_JITTER]) + ? lfptoms(&estjitter, 3) + : lfptoms(&estdisp, 3)); return (1); } else @@ -1602,7 +1687,7 @@ { register int i; char fullname[LENHOSTNAME]; - struct sockaddr_storage netnum; + sockaddr_u netnum; if (!dogetassoc(fp)) return; @@ -1691,7 +1776,7 @@ { register int i; char fullname[LENHOSTNAME]; - struct sockaddr_storage netnum; + sockaddr_u netnum; if (!dogetassoc(fp)) return; @@ -1766,3 +1851,132 @@ } doopeers(1, fp, af); } + + +/* + * config - send a configuration command to a remote host + */ +static void +config ( + struct parse *pcmd, + FILE *fp + ) +{ + char *cfgcmd; + u_short rstatus; + int rsize; + char *rdata; + int res; + int col; + int i; + + cfgcmd = pcmd->argval[0].string; + + if (debug > 2) { + printf("In Config\n"); + printf("Keyword = %s\n", pcmd->keyword); + printf("Command = %s\n", cfgcmd); + } + + res = doquery(CTL_OP_CONFIGURE, 0, 1, strlen(cfgcmd), cfgcmd, + &rstatus, &rsize, &rdata); + + if (res != 0) + return; + + if (rsize > 0 && '\n' == rdata[rsize - 1]) + rsize--; + rdata[rsize] = '\0'; + + col = -1; + if (1 == sscanf(rdata, "column %d syntax error", &col) + && col >= 0 && (size_t)col <= strlen(cfgcmd) + 1) { + if (interactive) { + printf("______"); /* "ntpq> " */ + printf("________"); /* ":config " */ + } else + printf("%s\n", cfgcmd); + for (i = 1; i < col; i++) + putchar('_'); + printf("^\n"); + } + printf("%s\n", rdata); +} + + +/* + * config_from_file - remotely configure an ntpd daemon using the + * specified configuration file + * SK: This function is a kludge at best and is full of bad design + * bugs: + * 1. ntpq uses UDP, which means that there is no guarantee of in-order, + * error-free delivery. + * 2. The maximum length of a packet is constrained, and as a result, the + * maximum length of a line in a configuration file is constrained. + * Longer lines will lead to unpredictable results. + * 3. Since this function is sending a line at a time, we can't update + * the control key through the configuration file (YUCK!!) + */ +static void +config_from_file ( + struct parse *pcmd, + FILE *fp + ) +{ + u_short rstatus; + int rsize; + char *rdata; + int res; + FILE *config_fd; + char config_cmd[MAXLINE]; + size_t config_len; + int i; + int retry_limit; + + if (debug > 2) { + printf("In Config\n"); + printf("Keyword = %s\n", pcmd->keyword); + printf("Filename = %s\n", pcmd->argval[0].string); + } + + config_fd = fopen(pcmd->argval[0].string, "r"); + if (NULL == config_fd) { + printf("ERROR!! Couldn't open file: %s\n", + pcmd->argval[0].string); + return; + } + + printf("Sending configuration file, one line at a time.\n"); + i = 0; + while (fgets(config_cmd, MAXLINE, config_fd) != NULL) { + config_len = strlen(config_cmd); + /* ensure even the last line has newline, if possible */ + if (config_len > 0 && + config_len + 2 < sizeof(config_cmd) && + '\n' != config_cmd[config_len - 1]) + config_cmd[config_len++] = '\n'; + ++i; + retry_limit = 2; + do + res = doquery(CTL_OP_CONFIGURE, 0, 1, + strlen(config_cmd), config_cmd, + &rstatus, &rsize, &rdata); + while (res != 0 && retry_limit--); + if (res != 0) { + printf("Line No: %d query failed: %s", i, + config_cmd); + printf("Subsequent lines not sent.\n"); + fclose(config_fd); + return; + } + + if (rsize > 0 && '\n' == rdata[rsize - 1]) + rsize--; + if (rsize > 0 && '\r' == rdata[rsize - 1]) + rsize--; + rdata[rsize] = '\0'; + printf("Line No: %d %s: %s", i, rdata, config_cmd); + } + printf("Done sending file\n"); + fclose(config_fd); +} diff -urN src/contrib/ntp/ntpq/ntpq.1 src.ntp/contrib/ntp/ntpq/ntpq.1 --- src/contrib/ntp/ntpq/ntpq.1 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpq/ntpq.1 2010-07-09 04:24:28.000000000 +0200 @@ -1,7 +1,7 @@ -.TH NTPQ 1 2009-12-08 "( 4.2.4p8)" "Programmer's Manual" +.TH NTPQ 1 2010-07-09 "( 4.2.6p2)" "Programmer's Manual" .\" EDIT THIS FILE WITH CAUTION (ntpq.1) .\" -.\" It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:27 AM EST +.\" It has been AutoGen-ed July 9, 2010 at 02:24:28 AM by AutoGen 5.10 .\" From the definitions ntpq-opts.def .\" and the template file agman1.tpl .\" @@ -15,7 +15,7 @@ .in +8 [ host ...] .SH "DESCRIPTION" -This manual page documents, briefly, the \fBntpq\fP command. +This manual page briefly documents the \fBntpq\fP command. The [= prog-name =] utility program is used to query NTP servers which @@ -281,14 +281,16 @@ .TP .BR \-4 ", " \--ipv4 Force IPv4 DNS name resolution. -This option is a member of the ipv4 class of options. +This option must not appear in combination with any of the following options: +ipv6. .sp Force DNS resolution of following host names on the command line to the IPv4 namespace. .TP .BR \-6 ", " \--ipv6 Force IPv6 DNS name resolution. -This option is a member of the ipv4 class of options. +This option must not appear in combination with any of the following options: +ipv4. .sp Force DNS resolution of following host names on the command line to the IPv6 namespace. @@ -336,8 +338,19 @@ Output all host addresses in dotted-quad numeric format rather than converting to the canonical host names. .TP +.BR \--old-rv +Always output status line with readvar. +.sp +By default, ntpq now suppresses the associd=... line that +precedes the output of "readvar" (alias "rv") when a single +variable is requested, such as ntpq \-c "rv 0 offset". This +option causes ntpq to include both lines of output for a +single-variable readvar. Using an environment variable to +preset this option in a script will enable both older and +newer ntpq to behave identically in this regard. +.TP .BR \-? , " \--help" -Display usage information and exit. +Display extended usage information and exit. .TP .BR \-! , " \--more-help" Extended usage information passed thru pager. @@ -352,7 +365,7 @@ of earlier RC/INI files. \fI--no-load-opts\fP is handled early, out of order. .TP -.BR \-v " [{\fIv|c|n\fP}]," " \--version" "[=\fI{v|c|n}\fP]" +.BR \- " [{\fIv|c|n\fP}]," " \--version" "[=\fI{v|c|n}\fP]" Output version of program and exit. The default mode is `v', a simple version. The `c' mode will print copyright information and `n' will print the full copyright notice. @@ -363,7 +376,7 @@ .nf \fBNTPQ_\fP or \fBNTPQ\fP .fi -.aj +.ad The environmental presets take precedence (are processed later than) the configuration files. The \fIhomerc\fP files are "\fI$HOME\fP", and "\fI.\fP". diff -urN src/contrib/ntp/ntpq/ntpq.c src.ntp/contrib/ntp/ntpq/ntpq.c --- src/contrib/ntp/ntpq/ntpq.c 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/ntpq/ntpq.c 2010-07-09 04:17:43.000000000 +0200 @@ -16,25 +16,20 @@ #include "ntp_io.h" #include "ntp_select.h" #include "ntp_stdlib.h" -/* Don't include ISC's version of IPv6 variables and structures */ -#define ISC_IPV6_H 1 +#include "ntp_assert.h" +#include "ntp_lineedit.h" +#include "ntp_debug.h" #include "isc/net.h" #include "isc/result.h" +#include #include "ntpq-opts.h" #ifdef SYS_WINNT # include # include -#else -# define closesocket close #endif /* SYS_WINNT */ -#if defined(HAVE_LIBREADLINE) || defined(HAVE_LIBEDIT) -# include -# include -#endif /* HAVE_LIBREADLINE || HAVE_LIBEDIT */ - #ifdef SYS_VXWORKS /* vxWorks needs mode flag -casey*/ # define open(name, flags) open(name, flags, 0777) @@ -53,6 +48,15 @@ int interactive = 0; /* set to 1 when we should prompt */ const char *prompt = "ntpq> "; /* prompt to ask him about */ +/* + * use old readvars behavior? --old-rv processing in ntpq resets + * this value based on the presence or absence of --old-rv. It is + * initialized to 1 here to maintain backward compatibility with + * libntpq clients such as ntpsnmpd, which are free to reset it as + * desired. + */ +int old_rv = 1; + /* * for get_systime() @@ -64,12 +68,8 @@ */ u_long info_auth_keyid = 0; -/* - * Type of key md5 - */ -#define KEY_TYPE_MD5 4 - -static int info_auth_keytype = KEY_TYPE_MD5; /* MD5 */ +static int info_auth_keytype = NID_md5; /* MD5 */ +static size_t info_auth_hashlen = 16; /* MD5 */ u_long current_time; /* needed by authkeys; not used */ /* @@ -129,16 +129,15 @@ { CS_REFTIME, TS, "reftime" }, /* 7 */ { CS_POLL, UI, "poll" }, /* 8 */ { CS_PEERID, UI, "peer" }, /* 9 */ - { CS_STATE, UI, "state" }, /* 10 */ - { CS_OFFSET, FL, "offset" }, /* 11 */ - { CS_DRIFT, FS, "frequency" }, /* 12 */ - { CS_JITTER, FU, "jitter" }, /* 13 */ - { CS_CLOCK, TS, "clock" }, /* 14 */ - { CS_PROCESSOR, ST, "processor" }, /* 15 */ - { CS_SYSTEM, ST, "system" }, /* 16 */ - { CS_VERSION, ST, "version" }, /* 17 */ - { CS_STABIL, FS, "stability" }, /* 18 */ - { CS_VARLIST, ST, "sys_var_list" }, /* 19 */ + { CS_OFFSET, FL, "offset" }, /* 10 */ + { CS_DRIFT, FS, "frequency" }, /* 11 */ + { CS_JITTER, FU, "jitter" }, /* 12 */ + { CS_CLOCK, TS, "clock" }, /* 13 */ + { CS_PROCESSOR, ST, "processor" }, /* 14 */ + { CS_SYSTEM, ST, "system" }, /* 15 */ + { CS_VERSION, ST, "version" }, /* 16 */ + { CS_STABIL, FS, "stability" }, /* 17 */ + { CS_VARLIST, ST, "sys_var_list" }, /* 18 */ { 0, EOV, "" } }; @@ -162,7 +161,7 @@ { CP_HPOLL, UI, "hpoll" }, /* 12 */ { CP_PRECISION, SI, "precision" }, /* 13 */ { CP_ROOTDELAY, FS, "rootdelay" }, /* 14 */ - { CP_ROOTDISPERSION, FU, "rootdispersion" }, /* 15 */ + { CP_ROOTDISPERSION, FU, "rootdisp" }, /* 15 */ { CP_REFID, RF, "refid" }, /* 16 */ { CP_REFTIME, TS, "reftime" }, /* 17 */ { CP_ORG, TS, "org" }, /* 18 */ @@ -224,75 +223,80 @@ static const char *tstflagnames[] = { "pkt_dup", /* TEST1 */ "pkt_bogus", /* TEST2 */ - "pkt_proto", /* TEST3 */ + "pkt_unsync", /* TEST3 */ "pkt_denied", /* TEST4 */ "pkt_auth", /* TEST5 */ - "pkt_synch", /* TEST6 */ - "pkt_dist", /* TEST7 */ + "pkt_stratum", /* TEST6 */ + "pkt_header", /* TEST7 */ "pkt_autokey", /* TEST8 */ "pkt_crypto", /* TEST9 */ "peer_stratum", /* TEST10 */ "peer_dist", /* TEST11 */ "peer_loop", /* TEST12 */ - "peer_unfit" /* TEST13 */ + "peer_unreach" /* TEST13 */ }; -int ntpqmain P((int, char **)); +int ntpqmain (int, char **); /* * Built in command handler declarations */ -static int openhost P((const char *)); -static int sendpkt P((char *, int)); -static int getresponse P((int, int, u_short *, int *, char **, int)); -static int sendrequest P((int, int, int, int, char *)); -static char * tstflags P((u_long)); -static void getcmds P((void)); -static RETSIGTYPE abortcmd P((int)); -static void docmd P((const char *)); -static void tokenize P((const char *, char **, int *)); -static int findcmd P((char *, struct xcmd *, struct xcmd *, struct xcmd **)); -static int getarg P((char *, int, arg_v *)); -static int rtdatetolfp P((char *, l_fp *)); -static int decodearr P((char *, int *, l_fp *)); -static void help P((struct parse *, FILE *)); +static int openhost (const char *); + +static int sendpkt (void *, size_t); +static int getresponse (int, int, u_short *, int *, char **, int); +static int sendrequest (int, int, int, int, char *); +static char * tstflags (u_long); +#ifndef BUILD_AS_LIB +static void getcmds (void); +#ifndef SYS_WINNT +static RETSIGTYPE abortcmd (int); +#endif /* SYS_WINNT */ +static void docmd (const char *); +static void tokenize (const char *, char **, int *); +static int getarg (char *, int, arg_v *); +#endif /* BUILD_AS_LIB */ +static int findcmd (char *, struct xcmd *, struct xcmd *, struct xcmd **); +static int rtdatetolfp (char *, l_fp *); +static int decodearr (char *, int *, l_fp *); +static void help (struct parse *, FILE *); #ifdef QSORT_USES_VOID_P -static int helpsort P((const void *, const void *)); +static int helpsort (const void *, const void *); #else -static int helpsort P((char **, char **)); +static int helpsort (char **, char **); #endif -static void printusage P((struct xcmd *, FILE *)); -static void timeout P((struct parse *, FILE *)); -static void auth_delay P((struct parse *, FILE *)); -static void host P((struct parse *, FILE *)); -static void ntp_poll P((struct parse *, FILE *)); -static void keyid P((struct parse *, FILE *)); -static void keytype P((struct parse *, FILE *)); -static void passwd P((struct parse *, FILE *)); -static void hostnames P((struct parse *, FILE *)); -static void setdebug P((struct parse *, FILE *)); -static void quit P((struct parse *, FILE *)); -static void version P((struct parse *, FILE *)); -static void raw P((struct parse *, FILE *)); -static void cooked P((struct parse *, FILE *)); -static void authenticate P((struct parse *, FILE *)); -static void ntpversion P((struct parse *, FILE *)); -static void warning P((const char *, const char *, const char *)); -static void error P((const char *, const char *, const char *)); -static u_long getkeyid P((const char *)); -static void atoascii P((int, char *, char *)); -static void makeascii P((int, char *, FILE *)); -static void rawprint P((int, int, char *, int, FILE *)); -static void startoutput P((void)); -static void output P((FILE *, char *, char *)); -static void endoutput P((FILE *)); -static void outputarr P((FILE *, char *, int, l_fp *)); -static void cookedprint P((int, int, char *, int, FILE *)); +static void printusage (struct xcmd *, FILE *); +static void timeout (struct parse *, FILE *); +static void auth_delay (struct parse *, FILE *); +static void host (struct parse *, FILE *); +static void ntp_poll (struct parse *, FILE *); +static void keyid (struct parse *, FILE *); +static void keytype (struct parse *, FILE *); +static void passwd (struct parse *, FILE *); +static void hostnames (struct parse *, FILE *); +static void setdebug (struct parse *, FILE *); +static void quit (struct parse *, FILE *); +static void version (struct parse *, FILE *); +static void raw (struct parse *, FILE *); +static void cooked (struct parse *, FILE *); +static void authenticate (struct parse *, FILE *); +static void ntpversion (struct parse *, FILE *); +static void warning (const char *, const char *, const char *); +static void error (const char *, const char *, const char *); +static u_long getkeyid (const char *); +static void atoascii (const char *, size_t, char *, size_t); +static void cookedprint (int, int, char *, int, int, FILE *); +static void rawprint (int, int, char *, int, int, FILE *); +static void startoutput (void); +static void output (FILE *, char *, char *); +static void endoutput (FILE *); +static void outputarr (FILE *, char *, int, l_fp *); #ifdef QSORT_USES_VOID_P -static int assoccmp P((const void *, const void *)); +static int assoccmp (const void *, const void *); #else -static int assoccmp P((struct association *, struct association *)); +static int assoccmp (struct association *, struct association *); #endif /* sgi || bsdi */ +void ntpq_custom_opt_handler (tOptions *, tOptDesc *); /* @@ -361,10 +365,10 @@ /* * Default values we use. */ +#define DEFHOST "localhost" /* default host name */ #define DEFTIMEOUT (5) /* 5 second time out */ #define DEFSTIMEOUT (2) /* 2 second time out after first */ #define DEFDELAY 0x51EB852 /* 20 milliseconds, l_fp fraction */ -#define DEFHOST "localhost" /* default host name */ #define LENHOSTNAME 256 /* host name is 256 characters long */ #define MAXCMDS 100 /* maximum commands on cmd line */ #define MAXHOSTS 200 /* maximum hosts on cmd line */ @@ -373,13 +377,13 @@ #define MAXVARLEN 256 /* maximum length of a variable name */ #define MAXVALLEN 400 /* maximum length of a variable value */ #define MAXOUTLINE 72 /* maximum length of an output line */ -#define SCREENWIDTH 76 /* nominal screen width in columns */ +#define SCREENWIDTH 76 /* nominal screen width in columns */ /* * Some variables used and manipulated locally */ -struct timeval tvout = { DEFTIMEOUT, 0 }; /* time out for reads */ -struct timeval tvsout = { DEFSTIMEOUT, 0 }; /* secondary time out */ +struct sock_timeval tvout = { DEFTIMEOUT, 0 }; /* time out for reads */ +struct sock_timeval tvsout = { DEFSTIMEOUT, 0 };/* secondary time out */ l_fp delay_time; /* delay time */ char currenthost[LENHOSTNAME]; /* current host name */ struct sockaddr_in hostaddr = { 0 }; /* host address */ @@ -392,13 +396,6 @@ int s_port = 0; struct servent *server_entry = NULL; /* server entry for ntp */ -#ifdef SYS_WINNT -DWORD NumberOfBytesWritten; - -HANDLE TimerThreadHandle = NULL; /* 1998/06/03 - Used in ntplib/machines.c */ -void timer(void) { ; }; /* 1998/06/03 - Used in ntplib/machines.c */ - -#endif /* SYS_WINNT */ /* * Sequence number used for requests. It is incremented before @@ -468,20 +465,22 @@ volatile int debug; #ifdef NO_MAIN_ALLOWED +#ifndef BUILD_AS_LIB CALL(ntpq,"ntpq",ntpqmain); void clear_globals(void) { - extern int ntp_optind; - showhostnames = 0; /* don'tshow host names by default */ - ntp_optind = 0; - server_entry = NULL; /* server entry for ntp */ - havehost = 0; /* set to 1 when host open */ - numassoc = 0; /* number of cached associations */ - numcmds = 0; - numhosts = 0; + extern int ntp_optind; + showhostnames = 0; /* don'tshow host names by default */ + ntp_optind = 0; + server_entry = NULL; /* server entry for ntp */ + havehost = 0; /* set to 1 when host open */ + numassoc = 0; /* number of cached associations */ + numcmds = 0; + numhosts = 0; } -#endif +#endif /* !BUILD_AS_LIB */ +#endif /* NO_MAIN_ALLOWED */ /* * main - parse arguments and handle options @@ -497,6 +496,7 @@ } #endif +#ifndef BUILD_AS_LIB int ntpqmain( int argc, @@ -513,18 +513,12 @@ delay_time.l_ui = 0; delay_time.l_uf = DEFDELAY; -#ifdef SYS_WINNT - if (!Win32InitSockets()) - { - fprintf(stderr, "No useable winsock.dll:"); - exit(1); - } -#endif /* SYS_WINNT */ + init_lib(); /* sets up ipv4_works, ipv6_works */ + ssl_applink(); - /* Check to see if we have IPv6. Otherwise force the -4 flag */ - if (isc_net_probeipv6() != ISC_R_SUCCESS) { + /* Check to see if we have IPv6. Otherwise default to IPv4 */ + if (!ipv6_works) ai_fam_default = AF_INET; - } progname = argv[0]; @@ -534,40 +528,27 @@ argv += optct; } - switch (WHICH_IDX_IPV4) { - case INDEX_OPT_IPV4: + /* + * Process options other than -c and -p, which are specially + * handled by ntpq_custom_opt_handler(). + */ + + debug = DESC(DEBUG_LEVEL).optOccCt; + + if (HAVE_OPT(IPV4)) ai_fam_templ = AF_INET; - break; - case INDEX_OPT_IPV6: + else if (HAVE_OPT(IPV6)) ai_fam_templ = AF_INET6; - break; - default: + else ai_fam_templ = ai_fam_default; - break; - } - - if (HAVE_OPT(COMMAND)) { - int cmdct = STACKCT_OPT( COMMAND ); - const char** cmds = STACKLST_OPT( COMMAND ); - - while (cmdct-- > 0) { - ADDCMD(*cmds++); - } - } - - debug = DESC(DEBUG_LEVEL).optOccCt; - if (HAVE_OPT(INTERACTIVE)) { + if (HAVE_OPT(INTERACTIVE)) interactive = 1; - } - if (HAVE_OPT(NUMERIC)) { + if (HAVE_OPT(NUMERIC)) showhostnames = 0; - } - if (HAVE_OPT(PEERS)) { - ADDCMD("peers"); - } + old_rv = HAVE_OPT(OLD_RV); #if 0 while ((c = ntp_getopt(argc, argv, "46c:dinp")) != EOF) @@ -604,11 +585,12 @@ exit(2); } #endif + NTP_INSIST(ntp_optind <= argc); if (ntp_optind == argc) { ADDHOST(DEFHOST); } else { for (; ntp_optind < argc; ntp_optind++) - ADDHOST(argv[ntp_optind]); + ADDHOST(argv[ntp_optind]); } if (numcmds == 0 && interactive == 0 @@ -630,8 +612,8 @@ for (ihost = 0; ihost < numhosts; ihost++) { if (openhost(chosts[ihost])) - for (icmd = 0; icmd < numcmds; icmd++) - docmd(ccmds[icmd]); + for (icmd = 0; icmd < numcmds; icmd++) + docmd(ccmds[icmd]); } } #ifdef SYS_WINNT @@ -639,12 +621,12 @@ #endif /* SYS_WINNT */ return 0; } - +#endif /* !BUILD_AS_LIB */ /* * openhost - open a socket to a host */ -static int +static int openhost( const char *hname ) @@ -662,12 +644,16 @@ cp = hname; - if(*cp == '[') { + if (*cp == '[') { cp++; - for(i = 0; *cp != ']'; cp++, i++) + for (i = 0; *cp && *cp != ']'; cp++, i++) name[i] = *cp; - name[i] = '\0'; - hname = name; + if (*cp == ']') { + name[i] = '\0'; + hname = name; + } else { + return 0; + } } /* @@ -696,32 +682,34 @@ #endif a_info = getaddrinfo(hname, service, &hints, &ai); } +#ifdef AI_ADDRCONFIG /* Some older implementations don't like AI_ADDRCONFIG. */ if (a_info == EAI_BADFLAGS) { hints.ai_flags = AI_CANONNAME; a_info = getaddrinfo(hname, service, &hints, &ai); } +#endif if (a_info != 0) { (void) fprintf(stderr, "%s\n", gai_strerror(a_info)); return 0; } if (ai->ai_canonname == NULL) { - strncpy(temphost, stoa((struct sockaddr_storage *)ai->ai_addr), - LENHOSTNAME); - temphost[LENHOSTNAME-1] = '\0'; + strncpy(temphost, + stoa((sockaddr_u *)ai->ai_addr), + LENHOSTNAME); } else { strncpy(temphost, ai->ai_canonname, LENHOSTNAME); - temphost[LENHOSTNAME-1] = '\0'; } + temphost[LENHOSTNAME-1] = '\0'; if (debug > 2) - printf("Opening host %s\n", temphost); + printf("Opening host %s\n", temphost); if (havehost == 1) { if (debug > 2) - printf("Closing old host %s\n", currenthost); + printf("Closing old host %s\n", currenthost); (void) closesocket(sockfd); havehost = 0; } @@ -744,9 +732,13 @@ int optionValue = SO_SYNCHRONOUS_NONALERT; int err; - err = setsockopt(INVALID_SOCKET, SOL_SOCKET, SO_OPENTYPE, (char *)&optionValue, sizeof(optionValue)); - if (err != NO_ERROR) { - (void) fprintf(stderr, "cannot open nonoverlapped sockets\n"); + err = setsockopt(INVALID_SOCKET, SOL_SOCKET, SO_OPENTYPE, + (char *)&optionValue, sizeof(optionValue)); + if (err) { + err = WSAGetLastError(); + fprintf(stderr, + "setsockopt(SO_SYNCHRONOUS_NONALERT) " + "error: %s\n", strerror(err)); exit(1); } } @@ -789,13 +781,12 @@ */ static int sendpkt( - char *xdata, - int xdatalen + void * xdata, + size_t xdatalen ) { if (debug >= 3) - printf("Sending %d octets\n", xdatalen); - + printf("Sending %lu octets\n", (u_long)xdatalen); if (send(sockfd, xdata, (size_t)xdatalen, 0) == -1) { warning("write to %s failed", currenthost, ""); @@ -804,13 +795,15 @@ if (debug >= 4) { int first = 8; + char *cdata = xdata; + printf("Packet data:\n"); while (xdatalen-- > 0) { if (first-- == 0) { printf("\n"); first = 7; } - printf(" %02x", *xdata++ & 0xff); + printf(" %02x", *cdata++ & 0xff); } printf("\n"); } @@ -833,13 +826,14 @@ ) { struct ntp_control rpkt; - struct timeval tvo; + struct sock_timeval tvo; u_short offsets[MAXFRAGS+1]; u_short counts[MAXFRAGS+1]; u_short offset; u_short count; int numfrags; int seenlastfrag; + int shouldbesize; fd_set fds; int n; @@ -860,305 +854,347 @@ FD_ZERO(&fds); - again: - if (numfrags == 0) - tvo = tvout; - else - tvo = tvsout; - - FD_SET(sockfd, &fds); - n = select(sockfd+1, &fds, (fd_set *)0, (fd_set *)0, &tvo); + /* + * Loop until we have an error or a complete response. Nearly all + * aths to loop again use continue. + */ + for (;;) { -#if 0 - if (debug >= 1) - printf("select() returns %d\n", n); -#endif + if (numfrags == 0) + tvo = tvout; + else + tvo = tvsout; + + FD_SET(sockfd, &fds); + n = select(sockfd+1, &fds, (fd_set *)0, (fd_set *)0, &tvo); - if (n == -1) { - warning("select fails", "", ""); - return -1; - } - if (n == 0) { - /* - * Timed out. Return what we have - */ - if (numfrags == 0) { - if (timeo) - (void) fprintf(stderr, - "%s: timed out, nothing received\n", - currenthost); - return ERR_TIMEOUT; - } else { - if (timeo) - (void) fprintf(stderr, - "%s: timed out with incomplete data\n", - currenthost); - if (debug) { - printf("Received fragments:\n"); - for (n = 0; n < numfrags; n++) - printf("%4d %d\n", offsets[n], - counts[n]); - if (seenlastfrag) - printf("last fragment received\n"); - else - printf("last fragment not received\n"); + if (n == -1) { + warning("select fails", "", ""); + return -1; + } + if (n == 0) { + /* + * Timed out. Return what we have + */ + if (numfrags == 0) { + if (timeo) + (void) fprintf(stderr, + "%s: timed out, nothing received\n", + currenthost); + return ERR_TIMEOUT; + } else { + if (timeo) + (void) fprintf(stderr, + "%s: timed out with incomplete data\n", + currenthost); + if (debug) { + printf("Received fragments:\n"); + for (n = 0; n < numfrags; n++) + printf("%4d %d\n", offsets[n], + counts[n]); + if (seenlastfrag) + printf("last fragment received\n"); + else + printf("last fragment not received\n"); + } + return ERR_INCOMPLETE; } - return ERR_INCOMPLETE; } - } - - n = recv(sockfd, (char *)&rpkt, sizeof(rpkt), 0); - if (n == -1) { - warning("read", "", ""); - return -1; - } - if (debug >= 4) { - int len = n, first = 8; - char *data = (char *)&rpkt; + n = recv(sockfd, (char *)&rpkt, sizeof(rpkt), 0); + if (n == -1) { + warning("read", "", ""); + return -1; + } - printf("Packet data:\n"); - while (len-- > 0) { - if (first-- == 0) { - printf("\n"); - first = 7; + if (debug >= 4) { + int len = n, first = 8; + char *data = (char *)&rpkt; + + printf("Packet data:\n"); + while (len-- > 0) { + if (first-- == 0) { + printf("\n"); + first = 7; + } + printf(" %02x", *data++ & 0xff); } - printf(" %02x", *data++ & 0xff); + printf("\n"); } - printf("\n"); - } - /* - * Check for format errors. Bug proofing. - */ - if (n < CTL_HEADER_LEN) { - if (debug) - printf("Short (%d byte) packet received\n", n); - goto again; - } - if (PKT_VERSION(rpkt.li_vn_mode) > NTP_VERSION - || PKT_VERSION(rpkt.li_vn_mode) < NTP_OLDVERSION) { - if (debug) - printf("Packet received with version %d\n", - PKT_VERSION(rpkt.li_vn_mode)); - goto again; - } - if (PKT_MODE(rpkt.li_vn_mode) != MODE_CONTROL) { - if (debug) - printf("Packet received with mode %d\n", - PKT_MODE(rpkt.li_vn_mode)); - goto again; - } - if (!CTL_ISRESPONSE(rpkt.r_m_e_op)) { - if (debug) - printf("Received request packet, wanted response\n"); - goto again; - } + /* + * Check for format errors. Bug proofing. + */ + if (n < CTL_HEADER_LEN) { + if (debug) + printf("Short (%d byte) packet received\n", n); + continue; + } + if (PKT_VERSION(rpkt.li_vn_mode) > NTP_VERSION + || PKT_VERSION(rpkt.li_vn_mode) < NTP_OLDVERSION) { + if (debug) + printf("Packet received with version %d\n", + PKT_VERSION(rpkt.li_vn_mode)); + continue; + } + if (PKT_MODE(rpkt.li_vn_mode) != MODE_CONTROL) { + if (debug) + printf("Packet received with mode %d\n", + PKT_MODE(rpkt.li_vn_mode)); + continue; + } + if (!CTL_ISRESPONSE(rpkt.r_m_e_op)) { + if (debug) + printf("Received request packet, wanted response\n"); + continue; + } - /* - * Check opcode and sequence number for a match. - * Could be old data getting to us. - */ - if (ntohs(rpkt.sequence) != sequence) { - if (debug) - printf( - "Received sequnce number %d, wanted %d\n", - ntohs(rpkt.sequence), sequence); - goto again; - } - if (CTL_OP(rpkt.r_m_e_op) != opcode) { - if (debug) - printf( - "Received opcode %d, wanted %d (sequence number okay)\n", - CTL_OP(rpkt.r_m_e_op), opcode); - goto again; - } + /* + * Check opcode and sequence number for a match. + * Could be old data getting to us. + */ + if (ntohs(rpkt.sequence) != sequence) { + if (debug) + printf( + "Received sequnce number %d, wanted %d\n", + ntohs(rpkt.sequence), sequence); + continue; + } + if (CTL_OP(rpkt.r_m_e_op) != opcode) { + if (debug) + printf( + "Received opcode %d, wanted %d (sequence number okay)\n", + CTL_OP(rpkt.r_m_e_op), opcode); + continue; + } - /* - * Check the error code. If non-zero, return it. - */ - if (CTL_ISERROR(rpkt.r_m_e_op)) { - int errcode; + /* + * Check the error code. If non-zero, return it. + */ + if (CTL_ISERROR(rpkt.r_m_e_op)) { + int errcode; - errcode = (ntohs(rpkt.status) >> 8) & 0xff; - if (debug && CTL_ISMORE(rpkt.r_m_e_op)) { - printf("Error code %d received on not-final packet\n", - errcode); + errcode = (ntohs(rpkt.status) >> 8) & 0xff; + if (debug && CTL_ISMORE(rpkt.r_m_e_op)) { + printf("Error code %d received on not-final packet\n", + errcode); + } + if (errcode == CERR_UNSPEC) + return ERR_UNSPEC; + return errcode; } - if (errcode == CERR_UNSPEC) - return ERR_UNSPEC; - return errcode; - } - /* - * Check the association ID to make sure it matches what - * we sent. - */ - if (ntohs(rpkt.associd) != associd) { - if (debug) - printf("Association ID %d doesn't match expected %d\n", - ntohs(rpkt.associd), associd); /* - * Hack for silly fuzzballs which, at the time of writing, - * return an assID of sys.peer when queried for system variables. + * Check the association ID to make sure it matches what + * we sent. */ + if (ntohs(rpkt.associd) != associd) { + if (debug) + printf("Association ID %d doesn't match expected %d\n", + ntohs(rpkt.associd), associd); + /* + * Hack for silly fuzzballs which, at the time of writing, + * return an assID of sys.peer when queried for system variables. + */ #ifdef notdef - goto again; + continue; #endif - } - - /* - * Collect offset and count. Make sure they make sense. - */ - offset = ntohs(rpkt.offset); - count = ntohs(rpkt.count); + } - if (debug >= 3) { - int shouldbesize; - u_long key; - u_long *lpkt; - int maclen; + /* + * Collect offset and count. Make sure they make sense. + */ + offset = ntohs(rpkt.offset); + count = ntohs(rpkt.count); /* - * Usually we ignore authentication, but for debugging purposes - * we watch it here. + * validate received payload size is padded to next 32-bit + * boundary and no smaller than claimed by rpkt.count */ - shouldbesize = CTL_HEADER_LEN + count; + if (n & 0x3) { + if (debug) + printf("Response packet not padded, " + "size = %d\n", n); + continue; + } - /* round to 8 octet boundary */ - shouldbesize = (shouldbesize + 7) & ~7; + shouldbesize = (CTL_HEADER_LEN + count + 3) & ~3; + + if (n < shouldbesize) { + printf("Response packet claims %u octets " + "payload, above %d received\n", + count, + n - CTL_HEADER_LEN + ); + return ERR_INCOMPLETE; + } - if (n & 0x3) { - printf("Packet not padded, size = %d\n", n); - } if ((maclen = n - shouldbesize) >= MIN_MAC_LEN) { - printf( - "Packet shows signs of authentication (total %d, data %d, mac %d)\n", - n, shouldbesize, maclen); - lpkt = (u_long *)&rpkt; - printf("%08lx %08lx %08lx %08lx %08lx %08lx\n", - (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_long) - 3]), - (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_long) - 2]), - (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_long) - 1]), - (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_long)]), - (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_long) + 1]), - (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_long) + 2])); - key = ntohl(lpkt[(n - maclen) / sizeof(u_long)]); - printf("Authenticated with keyid %lu\n", (u_long)key); - if (key != 0 && key != info_auth_keyid) { - printf("We don't know that key\n"); - } else { - if (authdecrypt(key, (u_int32 *)&rpkt, - n - maclen, maclen)) { - printf("Auth okay!\n"); + if (debug >= 3 && shouldbesize > n) { + u_int32 key; + u_int32 *lpkt; + int maclen; + + /* + * Usually we ignore authentication, but for debugging purposes + * we watch it here. + */ + /* round to 8 octet boundary */ + shouldbesize = (shouldbesize + 7) & ~7; + + maclen = n - shouldbesize; + if (maclen >= MIN_MAC_LEN) { + printf( + "Packet shows signs of authentication (total %d, data %d, mac %d)\n", + n, shouldbesize, maclen); + lpkt = (u_int32 *)&rpkt; + printf("%08lx %08lx %08lx %08lx %08lx %08lx\n", + (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_int32) - 3]), + (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_int32) - 2]), + (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_int32) - 1]), + (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_int32)]), + (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_int32) + 1]), + (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_int32) + 2])); + key = ntohl(lpkt[(n - maclen) / sizeof(u_int32)]); + printf("Authenticated with keyid %lu\n", (u_long)key); + if (key != 0 && key != info_auth_keyid) { + printf("We don't know that key\n"); } else { - printf("Auth failed!\n"); + if (authdecrypt(key, (u_int32 *)&rpkt, + n - maclen, maclen)) { + printf("Auth okay!\n"); + } else { + printf("Auth failed!\n"); + } } } } - } - if (debug >= 2) - printf("Got packet, size = %d\n", n); - if (count > (u_short)(n-CTL_HEADER_LEN)) { - if (debug) - printf( - "Received count of %d octets, data in packet is %d\n", - count, n-CTL_HEADER_LEN); - goto again; - } - if (count == 0 && CTL_ISMORE(rpkt.r_m_e_op)) { - if (debug) - printf("Received count of 0 in non-final fragment\n"); - goto again; - } - if (offset + count > sizeof(pktdata)) { - if (debug) - printf("Offset %d, count %d, too big for buffer\n", - offset, count); - return ERR_TOOMUCH; - } - if (seenlastfrag && !CTL_ISMORE(rpkt.r_m_e_op)) { - if (debug) - printf("Received second last fragment packet\n"); - goto again; - } + if (debug >= 2) + printf("Got packet, size = %d\n", n); + if ((int)count > (n - CTL_HEADER_LEN)) { + if (debug) + printf("Received count of %d octets, " + "data in packet is %d\n", + count, n-CTL_HEADER_LEN); + continue; + } + if (count == 0 && CTL_ISMORE(rpkt.r_m_e_op)) { + if (debug) + printf("Received count of 0 in non-final fragment\n"); + continue; + } + if (offset + count > sizeof(pktdata)) { + if (debug) + printf("Offset %d, count %d, too big for buffer\n", + offset, count); + return ERR_TOOMUCH; + } + if (seenlastfrag && !CTL_ISMORE(rpkt.r_m_e_op)) { + if (debug) + printf("Received second last fragment packet\n"); + continue; + } - /* - * So far, so good. Record this fragment, making sure it doesn't - * overlap anything. - */ - if (debug >= 2) - printf("Packet okay\n");; + /* + * So far, so good. Record this fragment, making sure it doesn't + * overlap anything. + */ + if (debug >= 2) + printf("Packet okay\n");; - if (numfrags == MAXFRAGS) { - if (debug) - printf("Number of fragments exceeds maximum\n"); - return ERR_TOOMUCH; - } - - for (n = 0; n < numfrags; n++) { - if (offset == offsets[n]) - goto again; /* duplicate */ - if (offset < offsets[n]) - break; - } - - if ((u_short)(n > 0 && offsets[n-1] + counts[n-1]) > offset) - goto overlap; - if (n < numfrags && (u_short)(offset + count) > offsets[n]) - goto overlap; - - { - register int i; - - for (i = numfrags; i > n; i--) { - offsets[i] = offsets[i-1]; - counts[i] = counts[i-1]; + if (numfrags > (MAXFRAGS - 1)) { + if (debug) + printf("Number of fragments exceeds maximum\n"); + return ERR_TOOMUCH; } - } - offsets[n] = offset; - counts[n] = count; - numfrags++; - - /* - * Got that stuffed in right. Figure out if this was the last. - * Record status info out of the last packet. - */ - if (!CTL_ISMORE(rpkt.r_m_e_op)) { - seenlastfrag = 1; - if (rstatus != 0) - *rstatus = ntohs(rpkt.status); - } - /* - * Copy the data into the data buffer. - */ - memmove((char *)pktdata + offset, (char *)rpkt.data, count); + /* + * Find the position for the fragment relative to any + * previously received. + */ + for (n = 0; + n < numfrags && offsets[n] < offset; + n++) { + /* empty body */ ; + } + + if (n < numfrags && offset == offsets[n]) { + if (debug) + printf("duplicate %u octets at %u " + "ignored, prior %u at %u\n", + count, + offset, + counts[n], + offsets[n] + ); + continue; + } + + if (n > 0 && (offsets[n-1] + counts[n-1]) > offset) { + if (debug) + printf("received frag at %u overlaps " + "with %u octet frag at %u\n", + offset, + counts[n-1], + offsets[n-1] + ); + continue; + } + + if (n < numfrags && (offset + count) > offsets[n]) { + if (debug) + printf("received %u octet frag at %u " + "overlaps with frag at %u\n", + count, + offset, + offsets[n] + ); + continue; + } - /* - * If we've seen the last fragment, look for holes in the sequence. - * If there aren't any, we're done. - */ - if (seenlastfrag && offsets[0] == 0) { - for (n = 1; n < numfrags; n++) { - if (offsets[n-1] + counts[n-1] != offsets[n]) - break; + { + register int i; + + for (i = numfrags; i > n; i--) { + offsets[i] = offsets[i-1]; + counts[i] = counts[i-1]; + } } - if (n == numfrags) { - *rsize = offsets[numfrags-1] + counts[numfrags-1]; - return 0; + offsets[n] = offset; + counts[n] = count; + numfrags++; + + /* + * Got that stuffed in right. Figure out if this was the last. + * Record status info out of the last packet. + */ + if (!CTL_ISMORE(rpkt.r_m_e_op)) { + seenlastfrag = 1; + if (rstatus != 0) + *rstatus = ntohs(rpkt.status); } - } - goto again; - overlap: - /* - * Print debugging message about overlapping fragments - */ - if (debug) - printf("Overlapping fragments returned in response\n"); - goto again; -} + /* + * Copy the data into the data buffer. + */ + memmove((char *)pktdata + offset, (char *)rpkt.data, count); + + /* + * If we've seen the last fragment, look for holes in the sequence. + * If there aren't any, we're done. + */ + if (seenlastfrag && offsets[0] == 0) { + for (n = 1; n < numfrags; n++) { + if (offsets[n-1] + counts[n-1] != offsets[n]) + break; + } + if (n == numfrags) { + *rsize = offsets[numfrags-1] + counts[numfrags-1]; + return 0; + } + } + } /* giant for (;;) collecting response packets */ +} /* getresponse() */ /* @@ -1174,15 +1210,18 @@ ) { struct ntp_control qpkt; - int pktsize; + int pktsize; + u_long key_id; + char * pass; + int maclen; /* * Check to make sure the data will fit in one packet */ if (qsize > CTL_MAX_DATA_LEN) { - (void) fprintf(stderr, - "***Internal error! qsize (%d) too large\n", - qsize); + fprintf(stderr, + "***Internal error! qsize (%d) too large\n", + qsize); return 1; } @@ -1197,19 +1236,18 @@ qpkt.offset = 0; qpkt.count = htons((u_short)qsize); + pktsize = CTL_HEADER_LEN; + /* - * If we have data, copy it in and pad it out to a 64 - * bit boundary. + * If we have data, copy and pad it out to a 32-bit boundary. */ if (qsize > 0) { - memmove((char *)qpkt.data, qdata, (unsigned)qsize); - pktsize = qsize + CTL_HEADER_LEN; - while (pktsize & (sizeof(u_long) - 1)) { + memcpy(qpkt.data, qdata, (size_t)qsize); + pktsize += qsize; + while (pktsize & (sizeof(u_int32) - 1)) { qpkt.data[qsize++] = 0; pktsize++; } - } else { - pktsize = CTL_HEADER_LEN; } /* @@ -1217,60 +1255,57 @@ * we're going to have to think about it a little. */ if (!auth && !always_auth) { - return sendpkt((char *)&qpkt, pktsize); - } else { - const char *pass = "\0"; - int maclen = 0; - u_long my_keyid; + return sendpkt(&qpkt, pktsize); + } - /* - * Pad out packet to a multiple of 8 octets to be sure - * receiver can handle it. - */ - while (pktsize & 7) { - qpkt.data[qsize++] = 0; - pktsize++; - } + /* + * Pad out packet to a multiple of 8 octets to be sure + * receiver can handle it. + */ + while (pktsize & 7) { + qpkt.data[qsize++] = 0; + pktsize++; + } - /* - * Get the keyid and the password if we don't have one. - */ - if (info_auth_keyid == 0) { - int u_keyid = getkeyid("Keyid: "); - if (u_keyid == 0 || u_keyid > NTP_MAXKEY) { - (void) fprintf(stderr, - "Invalid key identifier\n"); - return 1; - } - info_auth_keyid = u_keyid; + /* + * Get the keyid and the password if we don't have one. + */ + if (info_auth_keyid == 0) { + key_id = getkeyid("Keyid: "); + if (key_id == 0 || key_id > NTP_MAXKEY) { + fprintf(stderr, + "Invalid key identifier\n"); + return 1; } - if (!authistrusted(info_auth_keyid)) { - pass = getpass("MD5 Password: "); - if (*pass == '\0') { - (void) fprintf(stderr, - "Invalid password\n"); - return (1); - } + info_auth_keyid = key_id; + } + if (!authistrusted(info_auth_keyid)) { + pass = getpass_keytype(info_auth_keytype); + if ('\0' == pass[0]) { + fprintf(stderr, "Invalid password\n"); + return 1; } - authusekey(info_auth_keyid, info_auth_keytype, (const u_char *)pass); + authusekey(info_auth_keyid, info_auth_keytype, + (u_char *)pass); authtrust(info_auth_keyid, 1); + } - /* - * Stick the keyid in the packet where - * cp currently points. Cp should be aligned - * properly. Then do the encryptions. - */ - my_keyid = htonl(info_auth_keyid); - memcpy(&qpkt.data[qsize], &my_keyid, sizeof my_keyid); - maclen = authencrypt(info_auth_keyid, (u_int32 *)&qpkt, - pktsize); - if (maclen == 0) { - (void) fprintf(stderr, "Key not found\n"); - return (1); - } - return sendpkt((char *)&qpkt, pktsize + maclen); + /* + * Do the encryption. + */ + maclen = authencrypt(info_auth_keyid, (void *)&qpkt, pktsize); + if (!maclen) { + fprintf(stderr, "Key not found\n"); + return 1; + } else if ((size_t)maclen != (info_auth_hashlen + sizeof(keyid_t))) { + fprintf(stderr, + "%d octet MAC, %lu expected with %lu octet digest\n", + maclen, (u_long)(info_auth_hashlen + sizeof(keyid_t)), + (u_long)info_auth_hashlen); + return 1; } - /*NOTREACHED*/ + + return sendpkt((char *)&qpkt, pktsize + maclen); } @@ -1380,42 +1415,32 @@ } +#ifndef BUILD_AS_LIB /* * getcmds - read commands from the standard input and execute them */ static void getcmds(void) { -#if defined(HAVE_LIBREADLINE) || defined(HAVE_LIBEDIT) - char *line; + char * line; + int count; - for (;;) { - if ((line = readline(interactive?prompt:"")) == NULL) return; - if (*line) add_history(line); - docmd(line); - free(line); - } -#else /* not (HAVE_LIBREADLINE || HAVE_LIBEDIT) */ - char line[MAXLINE]; - - for (;;) { - if (interactive) { -#ifdef VMS /* work around a problem with mixing stdout & stderr */ - fputs("",stdout); -#endif - (void) fputs(prompt, stderr); - (void) fflush(stderr); - } - - if (fgets(line, sizeof line, stdin) == NULL) - return; - - docmd(line); - } -#endif /* not (HAVE_LIBREADLINE || HAVE_LIBEDIT) */ + ntp_readline_init(interactive ? prompt : NULL); + + for (;;) { + line = ntp_readline(&count); + if (NULL == line) + break; + docmd(line); + free(line); + } + + ntp_readline_uninit(); } +#endif /* !BUILD_AS_LIB */ -#ifndef SYS_WINNT /* Under NT cannot handle SIGINT, WIN32 spawns a handler */ + +#if !defined(SYS_WINNT) && !defined(BUILD_AS_LIB) /* * abortcmd - catch interrupts and abort the current command */ @@ -1430,8 +1455,10 @@ (void) fflush(stderr); if (jump) longjmp(interrupt_buf, 1); } -#endif /* SYS_WINNT */ +#endif /* !SYS_WINNT && !BUILD_AS_LIB */ + +#ifndef BUILD_AS_LIB /* * docmd - decode the command line and execute a command */ @@ -1482,9 +1509,9 @@ break; } if ((xcmd->arg[i] & OPT) && (*tokens[i+1] == '>')) - break; + break; if (!getarg(tokens[i+1], (int)xcmd->arg[i], &pcmd.argval[i])) - return; + return; pcmd.nargs++; } @@ -1493,9 +1520,9 @@ char *fname; if (*(tokens[i]+1) != '\0') - fname = tokens[i]+1; + fname = tokens[i]+1; else if ((i+1) < ntok) - fname = tokens[i+1]; + fname = tokens[i+1]; else { (void) fprintf(stderr, "***No file for redirect\n"); return; @@ -1527,7 +1554,13 @@ /* * tokenize - turn a command line into tokens + * + * SK: Modified to allow a quoted string + * + * HMS: If the first character of the first token is a ':' then (after + * eating inter-token whitespace) the 2nd token is the rest of the line. */ + static void tokenize( const char *line, @@ -1543,84 +1576,44 @@ cp = line; for (*ntok = 0; *ntok < MAXTOKENS; (*ntok)++) { tokens[*ntok] = sp; + + /* Skip inter-token whitespace */ while (ISSPACE(*cp)) cp++; + + /* If we're at EOL we're done */ if (ISEOL(*cp)) break; - do { - *sp++ = *cp++; - } while (!ISSPACE(*cp) && !ISEOL(*cp)); - - *sp++ = '\0'; - } -} - - -/* - * findcmd - find a command in a command description table - */ -static int -findcmd( - register char *str, - struct xcmd *clist1, - struct xcmd *clist2, - struct xcmd **cmd - ) -{ - register struct xcmd *cl; - register int clen; - int nmatch; - struct xcmd *nearmatch = NULL; - struct xcmd *clist; - - clen = strlen(str); - nmatch = 0; - if (clist1 != 0) - clist = clist1; - else if (clist2 != 0) - clist = clist2; - else - return 0; + /* If this is the 2nd token and the first token begins + * with a ':', then just grab to EOL. + */ - again: - for (cl = clist; cl->keyword != 0; cl++) { - /* do a first character check, for efficiency */ - if (*str != *(cl->keyword)) - continue; - if (strncmp(str, cl->keyword, (unsigned)clen) == 0) { - /* - * Could be extact match, could be approximate. - * Is exact if the length of the keyword is the - * same as the str. - */ - if (*((cl->keyword) + clen) == '\0') { - *cmd = cl; - return 1; - } - nmatch++; - nearmatch = cl; + if (*ntok == 1 && tokens[0][0] == ':') { + do { + *sp++ = *cp++; + } while (!ISEOL(*cp)); } - } - /* - * See if there is more to do. If so, go again. Sorry about the - * goto, too much looking at BSD sources... - */ - if (clist == clist1 && clist2 != 0) { - clist = clist2; - goto again; - } + /* Check if this token begins with a double quote. + * If yes, continue reading till the next double quote + */ + else if (*cp == '\"') { + ++cp; + do { + *sp++ = *cp++; + } while ((*cp != '\"') && !ISEOL(*cp)); + /* HMS: a missing closing " should be an error */ + } + else { + do { + *sp++ = *cp++; + } while ((*cp != '\"') && !ISSPACE(*cp) && !ISEOL(*cp)); + /* HMS: Why check for a " in the previous line? */ + } - /* - * If we got extactly 1 near match, use it, else return number - * of matches. - */ - if (nmatch == 1) { - *cmd = nearmatch; - return 1; + *sp++ = '\0'; } - return nmatch; } @@ -1714,6 +1707,74 @@ return 1; } +#endif /* !BUILD_AS_LIB */ + + +/* + * findcmd - find a command in a command description table + */ +static int +findcmd( + register char *str, + struct xcmd *clist1, + struct xcmd *clist2, + struct xcmd **cmd + ) +{ + register struct xcmd *cl; + register int clen; + int nmatch; + struct xcmd *nearmatch = NULL; + struct xcmd *clist; + + clen = strlen(str); + nmatch = 0; + if (clist1 != 0) + clist = clist1; + else if (clist2 != 0) + clist = clist2; + else + return 0; + + again: + for (cl = clist; cl->keyword != 0; cl++) { + /* do a first character check, for efficiency */ + if (*str != *(cl->keyword)) + continue; + if (strncmp(str, cl->keyword, (unsigned)clen) == 0) { + /* + * Could be extact match, could be approximate. + * Is exact if the length of the keyword is the + * same as the str. + */ + if (*((cl->keyword) + clen) == '\0') { + *cmd = cl; + return 1; + } + nmatch++; + nearmatch = cl; + } + } + + /* + * See if there is more to do. If so, go again. Sorry about the + * goto, too much looking at BSD sources... + */ + if (clist == clist1 && clist2 != 0) { + clist = clist2; + goto again; + } + + /* + * If we got extactly 1 near match, use it, else return number + * of matches. + */ + if (nmatch == 1) { + *cmd = nearmatch; + return 1; + } + return nmatch; +} /* @@ -1723,7 +1784,7 @@ int getnetnum( const char *hname, - struct sockaddr_storage *num, + sockaddr_u *num, char *fullhost, int af ) @@ -1731,10 +1792,8 @@ int sockaddr_len; struct addrinfo hints, *ai = NULL; - sockaddr_len = (af == AF_INET) - ? sizeof(struct sockaddr_in) - : sizeof(struct sockaddr_in6); - memset((char *)&hints, 0, sizeof(struct addrinfo)); + sockaddr_len = SIZEOF_SOCKADDR(af); + memset(&hints, 0, sizeof(hints)); hints.ai_flags = AI_CANONNAME; #ifdef AI_ADDRCONFIG hints.ai_flags |= AI_ADDRCONFIG; @@ -1766,14 +1825,15 @@ */ char * nntohost( - struct sockaddr_storage *netnum + sockaddr_u *netnum ) { if (!showhostnames) - return stoa(netnum); - if ((netnum->ss_family == AF_INET) && ISREFCLOCKADR(netnum)) - return refnumtoa(netnum); - return socktohost(netnum); + return stoa(netnum); + else if (ISREFCLOCKADR(netnum)) + return refnumtoa(netnum); + else + return socktohost(netnum); } @@ -1917,7 +1977,7 @@ * If it starts with a 0x, decode as hex. */ if (*str == '0' && (*(str+1) == 'x' || *(str+1) == 'X')) - return hextolfp(str+2, lfp); + return hextolfp(str+2, lfp); /* * If it starts with a '"', try it as an RT-11 date. @@ -1929,7 +1989,7 @@ bp = buf; while (*cp != '"' && *cp != '\0' && bp < &buf[29]) - *bp++ = *cp++; + *bp++ = *cp++; *bp = '\0'; return rtdatetolfp(buf, lfp); } @@ -1939,14 +1999,15 @@ * about heuristics! */ if ((*str >= 'A' && *str <= 'F') || (*str >= 'a' && *str <= 'f')) - return hextolfp(str, lfp); + return hextolfp(str, lfp); /* * Try it as a decimal. If this fails, try as an unquoted * RT-11 date. This code should go away eventually. */ if (atolfp(str, lfp)) - return 1; + return 1; + return rtdatetolfp(str, lfp); } @@ -1975,8 +2036,8 @@ { if (*str == '0') { if (*(str+1) == 'x' || *(str+1) == 'X') - return hextoint(str+2, val); - return octtoint(str, val); + return hextoint(str+2, (u_long *)val); + return octtoint(str, (u_long *)val); } return atoint(str, val); } @@ -2051,21 +2112,21 @@ FILE *fp ) { - struct xcmd *xcp; + struct xcmd *xcp = NULL; /* quiet warning */ char *cmd; const char *list[100]; - int word, words; - int row, rows; - int col, cols; + int word, words; + int row, rows; + int col, cols; if (pcmd->nargs == 0) { words = 0; for (xcp = builtins; xcp->keyword != 0; xcp++) { if (*(xcp->keyword) != '?') - list[words++] = xcp->keyword; + list[words++] = xcp->keyword; } for (xcp = opcmds; xcp->keyword != 0; xcp++) - list[words++] = xcp->keyword; + list[words++] = xcp->keyword; qsort( #ifdef QSORT_USES_VOID_P @@ -2078,21 +2139,22 @@ for (word = 0; word < words; word++) { int length = strlen(list[word]); if (col < length) { - col = length; - } + col = length; + } } cols = SCREENWIDTH / ++col; - rows = (words + cols - 1) / cols; + rows = (words + cols - 1) / cols; (void) fprintf(fp, "ntpq commands:\n"); for (row = 0; row < rows; row++) { - for (word = row; word < words; word += rows) { - (void) fprintf(fp, "%-*.*s", col, col-1, list[word]); - } - (void) fprintf(fp, "\n"); - } + for (word = row; word < words; word += rows) { + (void) fprintf(fp, "%-*.*s", col, + col-1, list[word]); + } + (void) fprintf(fp, "\n"); + } } else { cmd = pcmd->argval[0].string; words = findcmd(cmd, builtins, opcmds, &xcp); @@ -2172,11 +2234,11 @@ int val; if (pcmd->nargs == 0) { - val = tvout.tv_sec * 1000 + tvout.tv_usec / 1000; + val = (int)tvout.tv_sec * 1000 + tvout.tv_usec / 1000; (void) fprintf(fp, "primary timeout %d ms\n", val); } else { tvout.tv_sec = pcmd->argval[0].uval / 1000; - tvout.tv_usec = (pcmd->argval[0].uval - (tvout.tv_sec * 1000)) + tvout.tv_usec = (pcmd->argval[0].uval - ((long)tvout.tv_sec * 1000)) * 1000; } } @@ -2229,9 +2291,10 @@ if (pcmd->nargs == 0) { if (havehost) - (void) fprintf(fp, "current host is %s\n", currenthost); + (void) fprintf(fp, "current host is %s\n", + currenthost); else - (void) fprintf(fp, "no current host\n"); + (void) fprintf(fp, "no current host\n"); return; } @@ -2245,7 +2308,8 @@ else { if (havehost) (void) fprintf(fp, - "current host remains %s\n", currenthost); + "current host remains %s\n", + currenthost); else (void) fprintf(fp, "still no current host\n"); return; @@ -2257,10 +2321,11 @@ numassoc = 0; } else { if (havehost) - (void) fprintf(fp, - "current host remains %s\n", currenthost); + (void) fprintf(fp, + "current host remains %s\n", + currenthost); else - (void) fprintf(fp, "still no current host\n"); + (void) fprintf(fp, "still no current host\n"); } } @@ -2310,21 +2375,34 @@ FILE *fp ) { - if (pcmd->nargs == 0) - fprintf(fp, "keytype is %s\n", - (info_auth_keytype == KEY_TYPE_MD5) ? "MD5" : "???"); - else - switch (*(pcmd->argval[0].string)) { - case 'm': - case 'M': - info_auth_keytype = KEY_TYPE_MD5; - break; + const char * digest_name; + size_t digest_len; + int key_type; + + if (!pcmd->nargs) { + fprintf(fp, "keytype is %s with %lu octet digests\n", + keytype_name(info_auth_keytype), + (u_long)info_auth_hashlen); + return; + } - default: - fprintf(fp, "keytype must be 'md5'\n"); - } -} + digest_name = pcmd->argval[0].string; + digest_len = 0; + key_type = keytype_from_text(digest_name, &digest_len); + + if (!key_type) { + fprintf(fp, "keytype must be 'md5'%s\n", +#ifdef OPENSSL + " or a digest type provided by OpenSSL"); +#else + ""); +#endif + return; + } + info_auth_keytype = key_type; + info_auth_hashlen = digest_len; +} /* @@ -2347,13 +2425,17 @@ } info_auth_keyid = u_keyid; } - pass = getpass("MD5 Password: "); - if (*pass == '\0') - (void) fprintf(fp, "Password unchanged\n"); + if (pcmd->nargs >= 1) + pass = pcmd->argval[0].string; else { - authusekey(info_auth_keyid, info_auth_keytype, (u_char *)pass); - authtrust(info_auth_keyid, 1); + pass = getpass_keytype(info_auth_keytype); + if ('\0' == pass[0]) { + fprintf(fp, "Password unchanged\n"); + return; + } } + authusekey(info_auth_keyid, info_auth_keytype, (u_char *)pass); + authtrust(info_auth_keyid, 1); } @@ -2570,7 +2652,7 @@ #ifndef SYS_WINNT if ((fi = fdopen(open("/dev/tty", 2), "r")) == NULL) #else - if ((fi = _fdopen((int)GetStdHandle(STD_INPUT_HANDLE), "r")) == NULL) + if ((fi = _fdopen(open("CONIN$", _O_TEXT), "r")) == NULL) #endif /* SYS_WINNT */ fi = stdin; else @@ -2596,82 +2678,93 @@ */ static void atoascii( - int length, - char *data, - char *outdata - ) -{ - register u_char *cp; - register u_char *ocp; - register u_char c; - - if (!data) - { - *outdata = '\0'; + const char *in, + size_t in_octets, + char *out, + size_t out_octets + ) +{ + register const u_char * pchIn; + const u_char * pchInLimit; + register u_char * pchOut; + register u_char c; + + pchIn = (const u_char *)in; + pchInLimit = pchIn + in_octets; + pchOut = (u_char *)out; + + if (NULL == pchIn) { + if (0 < out_octets) + *pchOut = '\0'; return; } - ocp = (u_char *)outdata; - for (cp = (u_char *)data; cp < (u_char *)data + length; cp++) { - c = *cp; - if (c == '\0') - break; - if (c == '\0') - break; - if (c > 0177) { - *ocp++ = 'M'; - *ocp++ = '-'; - c &= 0177; +#define ONEOUT(c) \ +do { \ + if (0 == --out_octets) { \ + *pchOut = '\0'; \ + return; \ + } \ + *pchOut++ = (c); \ +} while (0) + + for ( ; pchIn < pchInLimit; pchIn++) { + c = *pchIn; + if ('\0' == c) + break; + if (c & 0x80) { + ONEOUT('M'); + ONEOUT('-'); + c &= 0x7f; } - if (c < ' ') { - *ocp++ = '^'; - *ocp++ = (u_char)(c + '@'); - } else if (c == 0177) { - *ocp++ = '^'; - *ocp++ = '?'; - } else { - *ocp++ = c; - } - if (ocp >= ((u_char *)outdata + length - 4)) - break; + ONEOUT('^'); + ONEOUT((u_char)(c + '@')); + } else if (0x7f == c) { + ONEOUT('^'); + ONEOUT('?'); + } else + ONEOUT(c); } - *ocp++ = '\0'; -} + ONEOUT('\0'); +#undef ONEOUT +} /* * makeascii - print possibly ascii data using the character * transformations that cat -v uses. */ -static void +void makeascii( int length, - char *data, + const char *data, FILE *fp ) { - register u_char *cp; - register int c; + const u_char *data_u_char; + const u_char *cp; + int c; + + data_u_char = (const u_char *)data; - for (cp = (u_char *)data; cp < (u_char *)data + length; cp++) { + for (cp = data_u_char; cp < data_u_char + length; cp++) { c = (int)*cp; - if (c > 0177) { + if (c & 0x80) { putc('M', fp); putc('-', fp); - c &= 0177; + c &= 0x7f; } if (c < ' ') { putc('^', fp); - putc(c+'@', fp); - } else if (c == 0177) { + putc(c + '@', fp); + } else if (0x7f == c) { putc('^', fp); putc('?', fp); - } else { + } else putc(c, fp); - } } } @@ -2840,13 +2933,14 @@ char *data, int status, int sttype, + int quiet, FILE *fp ) { if (rawmode) - rawprint(sttype, length, data, status, fp); + rawprint(sttype, length, data, status, quiet, fp); else - cookedprint(sttype, length, data, status, fp); + cookedprint(sttype, length, data, status, quiet, fp); } @@ -2859,6 +2953,7 @@ int length, char *data, int status, + int quiet, FILE *fp ) { @@ -2871,7 +2966,8 @@ cp = data; cpend = data + length; - (void) fprintf(fp, "status=0x%04x,\n", status); + if (!quiet) + (void) fprintf(fp, "status=0x%04x,\n", status); while (cp < cpend) { if (*cp == '\r') { @@ -2880,13 +2976,12 @@ * \n, supress this, else pretty print it. Otherwise * just output the character. */ - if (cp == (cpend-1) || *(cp+1) != '\n') + if (cp == (cpend - 1) || *(cp + 1) != '\n') makeascii(1, cp, fp); - } else if (isspace((int)*cp) || isprint((int)*cp)) { + } else if (isspace(*cp) || isprint(*cp)) putc(*cp, fp); - } else { + else makeascii(1, cp, fp); - } cp++; } } @@ -2920,32 +3015,27 @@ char *value ) { - int lenname; - int lenvalue; + size_t len; - lenname = strlen(name); - lenvalue = strlen(value); + /* strlen of "name=value" */ + len = strlen(name) + 1 + strlen(value); if (out_chars != 0) { - putc(',', fp); - out_chars++; - out_linecount++; - if ((out_linecount + lenname + lenvalue + 3) > MAXOUTLINE) { - putc('\n', fp); - out_chars++; + out_chars += 2; + if ((out_linecount + len + 2) > MAXOUTLINE) { + fputs(",\n", fp); out_linecount = 0; } else { - putc(' ', fp); - out_chars++; - out_linecount++; + fputs(", ", fp); + out_linecount += 2; } } fputs(name, fp); putc('=', fp); fputs(value, fp); - out_chars += lenname + 1 + lenvalue; - out_linecount += lenname + 1 + lenvalue; + out_chars += len; + out_linecount += len; } @@ -2958,7 +3048,7 @@ ) { if (out_chars != 0) - putc('\n', fp); + putc('\n', fp); } @@ -3012,33 +3102,44 @@ u_long val ) { - register char *cb, *s; + register char *cp, *s; + size_t cb; register int i; register const char *sep; sep = ""; i = 0; - s = cb = &circ_buf[nextcb][0]; + s = cp = circ_buf[nextcb]; if (++nextcb >= NUMCB) - nextcb = 0; + nextcb = 0; + cb = sizeof(circ_buf[0]); - sprintf(cb, "%02lx", val); - cb += strlen(cb); + snprintf(cp, cb, "%02lx", val); + cp += strlen(cp); + cb -= strlen(cp); if (!val) { - strcat(cb, " ok"); - cb += strlen(cb); + strncat(cp, " ok", cb); + cp += strlen(cp); + cb -= strlen(cp); } else { - *cb++ = ' '; - for (i = 0; i < 13; i++) { + if (cb) { + *cp++ = ' '; + cb--; + } + for (i = 0; i < COUNTOF(tstflagnames); i++) { if (val & 0x1) { - sprintf(cb, "%s%s", sep, tstflagnames[i]); + snprintf(cp, cb, "%s%s", sep, + tstflagnames[i]); sep = ", "; - cb += strlen(cb); + cp += strlen(cp); + cb -= strlen(cp); } val >>= 1; } } - *cb = '\0'; + if (cb) + *cp = '\0'; + return s; } @@ -3051,6 +3152,7 @@ int length, char *data, int status, + int quiet, FILE *fp ) { @@ -3062,28 +3164,30 @@ struct ctl_var *varlist; l_fp lfp; long ival; - struct sockaddr_storage hval; + sockaddr_u hval; u_long uval; l_fp lfparr[8]; int narr; switch (datatype) { - case TYPE_PEER: + case TYPE_PEER: varlist = peer_var; break; - case TYPE_SYS: + case TYPE_SYS: varlist = sys_var; break; - case TYPE_CLOCK: + case TYPE_CLOCK: varlist = clock_var; break; - default: - (void) fprintf(stderr, "Unknown datatype(0x%x) in cookedprint\n", datatype); + default: + fprintf(stderr, "Unknown datatype(0x%x) in cookedprint\n", + datatype); return; } - (void) fprintf(fp, "status=%04x %s,\n", status, - statustoa(datatype, status)); + if (!quiet) + fprintf(fp, "status=%04x %s,\n", status, + statustoa(datatype, status)); startoutput(); while (nextvar(&length, &data, &name, &value)) { @@ -3154,8 +3258,7 @@ case RF: if (decodenetnum(value, &hval)) { - if ((hval.ss_family == AF_INET) && - ISREFCLOCKADR(&hval)) + if (ISREFCLOCKADR(&hval)) output(fp, name, refnumtoa(&hval)); else @@ -3226,8 +3329,8 @@ char bv[401]; int len; - atoascii(400, name, bn); - atoascii(400, value, bv); + atoascii(name, MAXVARLEN, bn, sizeof(bn)); + atoascii(value, MAXVARLEN, bv, sizeof(bv)); if (output_raw != '*') { len = strlen(bv); bv[len] = output_raw; @@ -3272,9 +3375,9 @@ const struct association *ass2 = (const struct association *)t2; if (ass1->assid < ass2->assid) - return -1; + return -1; if (ass1->assid > ass2->assid) - return 1; + return 1; return 0; } #else @@ -3291,3 +3394,35 @@ return 0; } #endif /* not QSORT_USES_VOID_P */ + +/* + * ntpq_custom_opt_handler - autoopts handler for -c and -p + * + * By default, autoopts loses the relative order of -c and -p options + * on the command line. This routine replaces the default handler for + * those routines and builds a list of commands to execute preserving + * the order. + */ +void +ntpq_custom_opt_handler( + tOptions *pOptions, + tOptDesc *pOptDesc + ) +{ + switch (pOptDesc->optValue) { + + default: + fprintf(stderr, + "ntpq_custom_opt_handler unexpected option '%c' (%d)\n", + pOptDesc->optValue, pOptDesc->optValue); + exit(-1); + + case 'c': + ADDCMD(pOptDesc->pzLastArg); + break; + + case 'p': + ADDCMD("peers"); + break; + } +} diff -urN src/contrib/ntp/ntpq/ntpq.h src.ntp/contrib/ntp/ntpq/ntpq.h --- src/contrib/ntp/ntpq/ntpq.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/ntpq/ntpq.h 2010-07-09 04:17:43.000000000 +0200 @@ -34,7 +34,7 @@ char *string; long ival; u_long uval; - struct sockaddr_storage netnum; + sockaddr_u netnum; } arg_v; /* @@ -53,7 +53,7 @@ */ struct xcmd { const char *keyword; /* command key word */ - void (*handler) P((struct parse *, FILE *)); /* command handler */ + void (*handler) (struct parse *, FILE *); /* command handler */ u_char arg[MAXARGS]; /* descriptors for arguments */ const char *desc[MAXARGS]; /* descriptions for arguments */ const char *comment; @@ -79,15 +79,19 @@ const char *text; }; -extern void asciize P((int, char *, FILE *)); -extern int getnetnum P((const char *, struct sockaddr_storage *, char *, int)); -extern void sortassoc P((void)); -extern int doquery P((int, int, int, int, char *, u_short *, int *, char **)); -extern char * nntohost P((struct sockaddr_storage *)); -extern int decodets P((char *, l_fp *)); -extern int decodeuint P((char *, u_long *)); -extern int nextvar P((int *, char **, char **, char **)); -extern int decodetime P((char *, l_fp *)); -extern void printvars P((int, char *, int, int, FILE *)); -extern int decodeint P((char *, long *)); -extern int findvar P((char *, struct ctl_var *, int code)); +extern int interactive; /* are we prompting? */ +extern int old_rv; /* use old rv behavior? --old-rv */ + +extern void asciize (int, char *, FILE *); +extern int getnetnum (const char *, sockaddr_u *, char *, int); +extern void sortassoc (void); +extern int doquery (int, int, int, int, char *, u_short *, int *, char **); +extern char * nntohost (sockaddr_u *); +extern int decodets (char *, l_fp *); +extern int decodeuint (char *, u_long *); +extern int nextvar (int *, char **, char **, char **); +extern int decodetime (char *, l_fp *); +extern void printvars (int, char *, int, int, int, FILE *); +extern int decodeint (char *, long *); +extern int findvar (char *, struct ctl_var *, int code); +extern void makeascii (int, const char *, FILE *); diff -urN src/contrib/ntp/ntpsnmpd/Makefile.am src.ntp/contrib/ntp/ntpsnmpd/Makefile.am --- src/contrib/ntp/ntpsnmpd/Makefile.am 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpsnmpd/Makefile.am 2010-01-24 11:01:46.000000000 +0100 @@ -0,0 +1,53 @@ +NULL= +AUTOMAKE_OPTIONS= + +if NTP_BINSUBDIR_IS_BIN +bin_PROGRAMS= @MAKE_NTPSNMPD@ +else +sbin_PROGRAMS= @MAKE_NTPSNMPD@ +endif + +EXTRA_PROGRAMS= ntpsnmpd +ntpsnmpd_SOURCES= netsnmp_daemonize.c ntpsnmpd.c ntpSnmpSubagentObject.c \ + ntpsnmpd-opts.c ntpsnmpd-opts.h +noinst_HEADERS= ntpSnmpSubagentObject.h +# HMS: we probably want a version.o file here, too. +LDADD= ../ntpq/libntpq.a ../libntp/libntp.a @LCRYPTO@ @SNMP_LIBS@ \ + $(LIBOPTS_LDADD) +AM_CPPFLAGS= -I$(top_srcdir)/ntpq -I$(top_srcdir)/include \ + -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/nothreads/include \ + -I$(top_srcdir)/lib/isc/unix/include \ + $(LIBOPTS_CFLAGS) @SNMP_CPPFLAGS@ + +AM_CFLAGS= @SNMP_CFLAGS@ +EXTRA_DIST= ntpsnmpd-opts.def ntpsnmpd.1 ntpsnmpd-opts.texi \ + ntpsnmpd-opts.menu ntpv4-mib.mib +BUILT_SOURCES= ntpsnmpd-opts.c ntpsnmpd-opts.h +CLEANFILES= +noinst_DATA= $(srcdir)/ntpsnmpd-opts.texi $(srcdir)/ntpsnmpd-opts.menu +man_MANS= $(srcdir)/ntpsnmpd.1 +run_ag= cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" \ + autogen -L ../include --writable +std_def_list= $(top_srcdir)/include/autogen-version.def \ + $(top_srcdir)/include/copyright.def \ + $(top_srcdir)/include/homerc.def \ + $(top_srcdir)/include/version.def + +$(srcdir)/ntpsnmpd-opts.h: $(srcdir)/ntpsnmpd-opts.c + @: do-nothing action to avoid default SCCS get, .h built with .c + +$(srcdir)/ntpsnmpd-opts.c: $(srcdir)/ntpsnmpd-opts.def $(std_def_list) + $(run_ag) ntpsnmpd-opts.def + +$(srcdir)/ntpsnmpd.1: $(srcdir)/ntpsnmpd-opts.def $(std_def_list) + $(run_ag) -Tagman1.tpl -bntpsnmpd ntpsnmpd-opts.def + +$(srcdir)/ntpsnmpd-opts.menu: $(srcdir)/ntpsnmpd-opts.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/ntpsnmpd-opts.texi: $(srcdir)/ntpsnmpd-opts.def $(std_def_list) + $(run_ag) -Taginfo.tpl -DLEVEL=section ntpsnmpd-opts.def + +include $(top_srcdir)/bincheck.mf +include $(top_srcdir)/depsver.mf diff -urN src/contrib/ntp/ntpsnmpd/Makefile.in src.ntp/contrib/ntp/ntpsnmpd/Makefile.in --- src/contrib/ntp/ntpsnmpd/Makefile.in 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpsnmpd/Makefile.in 2010-07-09 04:21:35.000000000 +0200 @@ -0,0 +1,810 @@ +# Makefile.in generated by automake 1.11 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, +# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, +# Inc. +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + +# we traditionally installed software in bindir, while it should have gone +# in sbindir. Now that we offer a choice, look in the "other" installation +# subdir to warn folks if there is another version there. + + + +VPATH = @srcdir@ +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +EXTRA_PROGRAMS = ntpsnmpd$(EXEEXT) +DIST_COMMON = README $(noinst_HEADERS) $(srcdir)/Makefile.am \ + $(srcdir)/Makefile.in $(top_srcdir)/bincheck.mf \ + $(top_srcdir)/depsver.mf +subdir = ntpsnmpd +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ + $(top_srcdir)/m4/define_dir.m4 \ + $(top_srcdir)/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/m4/ntp_openssl.m4 \ + $(top_srcdir)/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ + $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(sbindir)" \ + "$(DESTDIR)$(man1dir)" +PROGRAMS = $(bin_PROGRAMS) $(sbin_PROGRAMS) +am_ntpsnmpd_OBJECTS = netsnmp_daemonize.$(OBJEXT) ntpsnmpd.$(OBJEXT) \ + ntpSnmpSubagentObject.$(OBJEXT) ntpsnmpd-opts.$(OBJEXT) +ntpsnmpd_OBJECTS = $(am_ntpsnmpd_OBJECTS) +ntpsnmpd_LDADD = $(LDADD) +am__DEPENDENCIES_1 = +ntpsnmpd_DEPENDENCIES = ../ntpq/libntpq.a ../libntp/libntp.a \ + $(am__DEPENDENCIES_1) +DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) +depcomp = $(SHELL) $(top_srcdir)/depcomp +am__depfiles_maybe = depfiles +am__mv = mv -f +COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ + $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ + --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ + $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +CCLD = $(CC) +LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ + --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ + $(LDFLAGS) -o $@ +SOURCES = $(ntpsnmpd_SOURCES) +DIST_SOURCES = $(ntpsnmpd_SOURCES) +am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; +am__vpath_adj = case $$p in \ + $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ + *) f=$$p;; \ + esac; +am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; +am__install_max = 40 +am__nobase_strip_setup = \ + srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` +am__nobase_strip = \ + for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" +am__nobase_list = $(am__nobase_strip_setup); \ + for p in $$list; do echo "$$p $$p"; done | \ + sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ + $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ + if (++n[$$2] == $(am__install_max)) \ + { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ + END { for (dir in files) print dir, files[dir] }' +am__base_list = \ + sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ + sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +man1dir = $(mandir)/man1 +NROFF = nroff +MANS = $(man_MANS) +DATA = $(noinst_DATA) +HEADERS = $(noinst_HEADERS) +ETAGS = etags +CTAGS = ctags +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +AMTAR = @AMTAR@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +BINSUBDIR = @BINSUBDIR@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CFLAGS = @CFLAGS@ +CHUTEST = @CHUTEST@ +CLKTEST = @CLKTEST@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DCFD = @DCFD@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +ECHO = @ECHO@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ +EF_LIBS = @EF_LIBS@ +EF_PROGS = @EF_PROGS@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +GREP = @GREP@ +HAVE_INLINE = @HAVE_INLINE@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LCRYPTO = @LCRYPTO@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ +LIBOPTS_DIR = @LIBOPTS_DIR@ +LIBOPTS_LDADD = @LIBOPTS_LDADD@ +LIBPARSE = @LIBPARSE@ +LIBS = @LIBS@ +LIBTOOL = @LIBTOOL@ +LN_S = @LN_S@ +LSCF = @LSCF@ +LTLIBOBJS = @LTLIBOBJS@ +MAKEINFO = @MAKEINFO@ +MAKE_ADJTIMED = @MAKE_ADJTIMED@ +MAKE_CHECK_LAYOUT = @MAKE_CHECK_LAYOUT@ +MAKE_CHECK_Y2K = @MAKE_CHECK_Y2K@ +MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ +MAKE_LIBPARSE = @MAKE_LIBPARSE@ +MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ +MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ +MAKE_NTPTIME = @MAKE_NTPTIME@ +MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ +MAKE_TICKADJ = @MAKE_TICKADJ@ +MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MKDIR_P = @MKDIR_P@ +OBJEXT = @OBJEXT@ +OPENSSL = @OPENSSL@ +OPENSSL_INC = @OPENSSL_INC@ +OPENSSL_LIB = @OPENSSL_LIB@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ +PATH_PERL = @PATH_PERL@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PATH_SH = @PATH_SH@ +PROPDELAY = @PROPDELAY@ +RANLIB = @RANLIB@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +STRIP = @STRIP@ +TESTDCF = @TESTDCF@ +VERSION = @VERSION@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_CC = @ac_ct_CC@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +NULL = +AUTOMAKE_OPTIONS = +@NTP_BINSUBDIR_IS_BIN_TRUE@bin_PROGRAMS = @MAKE_NTPSNMPD@ +@NTP_BINSUBDIR_IS_BIN_FALSE@sbin_PROGRAMS = @MAKE_NTPSNMPD@ +ntpsnmpd_SOURCES = netsnmp_daemonize.c ntpsnmpd.c ntpSnmpSubagentObject.c \ + ntpsnmpd-opts.c ntpsnmpd-opts.h + +noinst_HEADERS = ntpSnmpSubagentObject.h +# HMS: we probably want a version.o file here, too. +LDADD = ../ntpq/libntpq.a ../libntp/libntp.a @LCRYPTO@ @SNMP_LIBS@ \ + $(LIBOPTS_LDADD) + +AM_CPPFLAGS = -I$(top_srcdir)/ntpq -I$(top_srcdir)/include \ + -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/nothreads/include \ + -I$(top_srcdir)/lib/isc/unix/include \ + $(LIBOPTS_CFLAGS) @SNMP_CPPFLAGS@ + +AM_CFLAGS = @SNMP_CFLAGS@ +EXTRA_DIST = ntpsnmpd-opts.def ntpsnmpd.1 ntpsnmpd-opts.texi \ + ntpsnmpd-opts.menu ntpv4-mib.mib + +BUILT_SOURCES = ntpsnmpd-opts.c ntpsnmpd-opts.h .deps-ver +CLEANFILES = .deps-ver +noinst_DATA = $(srcdir)/ntpsnmpd-opts.texi $(srcdir)/ntpsnmpd-opts.menu +man_MANS = $(srcdir)/ntpsnmpd.1 +run_ag = cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" \ + autogen -L ../include --writable + +std_def_list = $(top_srcdir)/include/autogen-version.def \ + $(top_srcdir)/include/copyright.def \ + $(top_srcdir)/include/homerc.def \ + $(top_srcdir)/include/version.def + +all: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) all-am + +.SUFFIXES: +.SUFFIXES: .c .lo .o .obj +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/bincheck.mf $(top_srcdir)/depsver.mf $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign ntpsnmpd/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign ntpsnmpd/Makefile +.PRECIOUS: Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): +install-binPROGRAMS: $(bin_PROGRAMS) + @$(NORMAL_INSTALL) + test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)" + @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p || test -f $$p1; \ + then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(bindir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-binPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(bindir)" && rm -f $$files + +clean-binPROGRAMS: + @list='$(bin_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list +install-sbinPROGRAMS: $(sbin_PROGRAMS) + @$(NORMAL_INSTALL) + test -z "$(sbindir)" || $(MKDIR_P) "$(DESTDIR)$(sbindir)" + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p || test -f $$p1; \ + then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-sbinPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(sbindir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(sbindir)" && rm -f $$files + +clean-sbinPROGRAMS: + @list='$(sbin_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list +ntpsnmpd$(EXEEXT): $(ntpsnmpd_OBJECTS) $(ntpsnmpd_DEPENDENCIES) + @rm -f ntpsnmpd$(EXEEXT) + $(LINK) $(ntpsnmpd_OBJECTS) $(ntpsnmpd_LDADD) $(LIBS) + +mostlyclean-compile: + -rm -f *.$(OBJEXT) + +distclean-compile: + -rm -f *.tab.c + +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/netsnmp_daemonize.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpSnmpSubagentObject.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpsnmpd-opts.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpsnmpd.Po@am__quote@ + +.c.o: +@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(COMPILE) -c $< + +.c.obj: +@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` + +.c.lo: +@am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs +install-man1: $(man_MANS) + @$(NORMAL_INSTALL) + test -z "$(man1dir)" || $(MKDIR_P) "$(DESTDIR)$(man1dir)" + @list=''; test -n "$(man1dir)" || exit 0; \ + { for i in $$list; do echo "$$i"; done; \ + l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ + sed -n '/\.1[a-z]*$$/p'; \ + } | while read p; do \ + if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; echo "$$p"; \ + done | \ + sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ + sed 'N;N;s,\n, ,g' | { \ + list=; while read file base inst; do \ + if test "$$base" = "$$inst"; then list="$$list $$file"; else \ + echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man1dir)/$$inst'"; \ + $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man1dir)/$$inst" || exit $$?; \ + fi; \ + done; \ + for i in $$list; do echo "$$i"; done | $(am__base_list) | \ + while read files; do \ + test -z "$$files" || { \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man1dir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(man1dir)" || exit $$?; }; \ + done; } + +uninstall-man1: + @$(NORMAL_UNINSTALL) + @list=''; test -n "$(man1dir)" || exit 0; \ + files=`{ for i in $$list; do echo "$$i"; done; \ + l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ + sed -n '/\.1[a-z]*$$/p'; \ + } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ + test -z "$$files" || { \ + echo " ( cd '$(DESTDIR)$(man1dir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(man1dir)" && rm -f $$files; } + +ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) + list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | \ + $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in files) print i; }; }'`; \ + mkid -fID $$unique +tags: TAGS + +TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ + $(TAGS_FILES) $(LISP) + set x; \ + here=`pwd`; \ + list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | \ + $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in files) print i; }; }'`; \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: CTAGS +CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ + $(TAGS_FILES) $(LISP) + list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | \ + $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in files) print i; }; }'`; \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + +distdir: $(DISTFILES) + @list='$(MANS)'; if test -n "$$list"; then \ + list=`for p in $$list; do \ + if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ + if test -f "$$d$$p"; then echo "$$d$$p"; else :; fi; done`; \ + if test -n "$$list" && \ + grep 'ab help2man is required to generate this page' $$list >/dev/null; then \ + echo "error: found man pages containing the \`missing help2man' replacement text:" >&2; \ + grep -l 'ab help2man is required to generate this page' $$list | sed 's/^/ /' >&2; \ + echo " to fix them, install help2man, remove and regenerate the man pages;" >&2; \ + echo " typically \`make maintainer-clean' will remove them" >&2; \ + exit 1; \ + else :; fi; \ + else :; fi + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) check-am +all-am: Makefile $(PROGRAMS) $(MANS) $(DATA) $(HEADERS) +installdirs: + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)"; do \ + test -z "$$dir" || $(MKDIR_P) "$$dir"; \ + done +install: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + `test -z '$(STRIP)' || \ + echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install +mostlyclean-generic: + +clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." + -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) +clean: clean-am + +clean-am: clean-binPROGRAMS clean-generic clean-libtool \ + clean-sbinPROGRAMS mostlyclean-am + +distclean: distclean-am + -rm -rf ./$(DEPDIR) + -rm -f Makefile +distclean-am: clean-am distclean-compile distclean-generic \ + distclean-tags + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: install-man + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: install-binPROGRAMS install-sbinPROGRAMS + @$(NORMAL_INSTALL) + $(MAKE) $(AM_MAKEFLAGS) install-exec-hook +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: install-man1 + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -rf ./$(DEPDIR) + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ + mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: uninstall-binPROGRAMS uninstall-man \ + uninstall-sbinPROGRAMS + +uninstall-man: uninstall-man1 + +.MAKE: all check install install-am install-exec-am install-strip + +.PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \ + clean-generic clean-libtool clean-sbinPROGRAMS ctags distclean \ + distclean-compile distclean-generic distclean-libtool \ + distclean-tags distdir dvi dvi-am html html-am info info-am \ + install install-am install-binPROGRAMS install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-exec-hook install-html install-html-am \ + install-info install-info-am install-man install-man1 \ + install-pdf install-pdf-am install-ps install-ps-am \ + install-sbinPROGRAMS install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-compile \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags uninstall uninstall-am uninstall-binPROGRAMS \ + uninstall-man uninstall-man1 uninstall-sbinPROGRAMS + + +$(srcdir)/ntpsnmpd-opts.h: $(srcdir)/ntpsnmpd-opts.c + @: do-nothing action to avoid default SCCS get, .h built with .c + +$(srcdir)/ntpsnmpd-opts.c: $(srcdir)/ntpsnmpd-opts.def $(std_def_list) + $(run_ag) ntpsnmpd-opts.def + +$(srcdir)/ntpsnmpd.1: $(srcdir)/ntpsnmpd-opts.def $(std_def_list) + $(run_ag) -Tagman1.tpl -bntpsnmpd ntpsnmpd-opts.def + +$(srcdir)/ntpsnmpd-opts.menu: $(srcdir)/ntpsnmpd-opts.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/ntpsnmpd-opts.texi: $(srcdir)/ntpsnmpd-opts.def $(std_def_list) + $(run_ag) -Taginfo.tpl -DLEVEL=section ntpsnmpd-opts.def + +install-exec-hook: + @case ${BINSUBDIR} in \ + bin) ODIR=${sbindir} ;; \ + sbin) ODIR=${bindir} ;; \ + esac; \ + test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ + || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ + test ! -f $$ODIR/$$i || echo "*** $$i is also in $$ODIR!"; \ + done + +# +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + ..) \ + cd .. && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + *) \ + echo 'Fatal: depsver.mf Automake fragment limited' \ + 'to immediate subdirectories.' && \ + echo "top_builddir: $(top_builddir)" && \ + echo "subdir: $(subdir)" && \ + exit 1 \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff -urN src/contrib/ntp/ntpsnmpd/README src.ntp/contrib/ntp/ntpsnmpd/README --- src/contrib/ntp/ntpsnmpd/README 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpsnmpd/README 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,40 @@ +NTP SNMP subagent for Net-SNMP + +Installation Guides: + +- install net-snmp from source (configure, make;, make install) +- edit the snmpd configuration file (/usr/local/share/snmp/snmpd.conf): + add the lines + master agentx + agentXSocket tcp:localhost:705 + and check which read-only community is configured (should be "rocommunity public") +- start snmpd (sudo /usr/local/sbin/snmpd) and check that it is running correctly by running the command + snmpwalk -v2c -c public localhost + (which should output a lot of data values for the supported built-in MIBs of net-snmp) +- build the libntpq and the libntp library +- build the ntpsnmpd application (make) and run it (./ntpsnmpd) +- now you can run + snmpwalk -v2c -c public localhost enterprises.5597.99 + which should give you a list of all currently supported NTP MIB objects and their current values + +Please note that currently I use a private MIB OID (enterprises.5597 is the Meinberg top level OEM OID and 99 is my temporary working space for this project). +The final OID has to be registered with IANA and this is done by the RFC Editor when the NTPv4 MIB RFC is standardized. +I will try to do this earlier in order to be able to have a working solution at the end of this project. + +In its current state the daemon supports these objects: + +ntpEntSoftwareName +ntpEntSoftwareVersion +ntpEntSoftwareVersionVal +ntpEntSoftwareVendor +ntpEntSystemType +ntpEntTimeResolution +ntpEntTimeResolutionVal +ntpEntTimePrecision +ntpEntTimePrecisionVal +ntpEntTimeDistance + +They all use the libntpq library to access information from the ntpd instance with mode 6 packets. + +Next step is to implement the status section of the MIB (section 2). + diff -urN src/contrib/ntp/ntpsnmpd/netsnmp_daemonize.c src.ntp/contrib/ntp/ntpsnmpd/netsnmp_daemonize.c --- src/contrib/ntp/ntpsnmpd/netsnmp_daemonize.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpsnmpd/netsnmp_daemonize.c 2009-12-25 10:03:40.000000000 +0100 @@ -0,0 +1,266 @@ +/* + * system.c + */ +/* Portions of this file are subject to the following copyright(s). See + * the Net-SNMP's COPYING file for more details and other copyrights + * that may apply: + */ +/*********************************************************** + Copyright 1992 by Carnegie Mellon University + + All Rights Reserved + +Permission to use, copy, modify, and distribute this software and its +documentation for any purpose and without fee is hereby granted, +provided that the above copyright notice appear in all copies and that +both that copyright notice and this permission notice appear in +supporting documentation, and that the name of CMU not be +used in advertising or publicity pertaining to distribution of the +software without specific, written prior permission. + +CMU DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING +ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL +CMU BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR +ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, +WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, +ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS +SOFTWARE. +******************************************************************/ +/* + * Portions of this file are copyrighted by: + * Copyright © 2003 Sun Microsystems, Inc. All rights reserved. + * Use is subject to license terms specified in the COPYING file + * distributed with the Net-SNMP package. + */ +/* + * System dependent routines go here + */ +#include +#undef PACKAGE_BUGREPORT +#undef PACKAGE_NAME +#undef PACKAGE_STRING +#undef PACKAGE_TARNAME +#undef PACKAGE_VERSION +#include + +#ifdef NEED_NETSNMP_DAEMONIZE + +#include +#include +#include + +#if HAVE_UNISTD_H +#include +#endif +#if HAVE_STDLIB_H +#include +#endif + +#if TIME_WITH_SYS_TIME +# ifdef WIN32 +# include +# else +# include +# endif +# include +#else +# if HAVE_SYS_TIME_H +# include +# else +# include +# endif +#endif + +#include + +#if HAVE_NETINET_IN_H +#include +#endif + +#if HAVE_WINSOCK_H +#include +#endif +#if HAVE_SYS_SOCKET_H +#include +#endif +#if HAVE_NET_IF_H +#include +#endif + +#if HAVE_SYS_SOCKIO_H +#include +#endif + +#if HAVE_SYS_IOCTL_H +#include +#endif + +#ifdef HAVE_NLIST_H +#include +#endif + +#if HAVE_SYS_FILE_H +#include +#endif + +#if HAVE_KSTAT_H +#include +#endif + +#if HAVE_SYS_PARAM_H +#include +#endif +#if HAVE_SYS_SYSCTL_H +#include +#endif + +#if HAVE_STRING_H +#include +#else +#include +#endif + +#if HAVE_DMALLOC_H +#include +#endif + +#ifdef HAVE_SYS_STAT_H +#include +#endif +#if HAVE_FCNTL_H +#include +#endif + +#if defined(hpux10) || defined(hpux11) +#include +#endif + +#if HAVE_SYS_UTSNAME_H +#include +#endif + +#if HAVE_SYS_SYSTEMCFG_H +#include +#endif + +#if HAVE_SYS_SYSTEMINFO_H +#include +#endif + +#include +#include +#include +#include /* for "internal" definitions */ + +#include +#include /* for get_temp_file_pattern() */ + +#ifndef IFF_LOOPBACK +# define IFF_LOOPBACK 0 +#endif + +#ifdef INADDR_LOOPBACK +# define LOOPBACK INADDR_LOOPBACK +#else +# define LOOPBACK 0x7f000001 +#endif + +/** + * fork current process into the background. + * + * This function forks a process into the background, in order to + * become a daemon process. It does a few things along the way: + * + * - becoming a process/session group leader, and forking a second time so + * that process/session group leader can exit. + * + * - changing the working directory to / + * + * - closing stdin, stdout and stderr (unless stderr_log is set) and + * redirecting them to /dev/null + * + * @param quit_immediately : indicates if the parent process should + * exit after a successful fork. + * @param stderr_log : indicates if stderr is being used for + * logging and shouldn't be closed + * @returns -1 : fork error + * 0 : child process returning + * >0 : parent process returning. returned value is the child PID. + */ +int +netsnmp_daemonize(int quit_immediately, int stderr_log) +{ + int i = 0; + DEBUGMSGT(("daemonize","deamonizing...\n")); +#if HAVE_WORKING_FORK + /* + * Fork to return control to the invoking process and to + * guarantee that we aren't a process group leader. + */ + i = fork(); + if (i != 0) { + /* Parent. */ + DEBUGMSGT(("daemonize","first fork returned %d.\n", i)); + if(i == -1) { + snmp_log(LOG_ERR,"first fork failed (errno %d) in " + "netsnmp_daemonize()\n", errno); + return -1; + } + if (quit_immediately) { + DEBUGMSGT(("daemonize","parent exiting\n")); + exit(0); + } + } else { + /* Child. */ +#ifdef HAVE_SETSID + /* Become a process/session group leader. */ + setsid(); +#endif + /* + * Fork to let the process/session group leader exit. + */ + if ((i = fork()) != 0) { + DEBUGMSGT(("daemonize","second fork returned %d.\n", i)); + if(i == -1) { + snmp_log(LOG_ERR,"second fork failed (errno %d) in " + "netsnmp_daemonize()\n", errno); + } + /* Parent. */ + exit(0); + } +#ifndef WIN32 + else { + /* Child. */ + + DEBUGMSGT(("daemonize","child continuing\n")); + + /* Avoid keeping any directory in use. */ + chdir("/"); + + if (!stderr_log) { + /* + * Close inherited file descriptors to avoid + * keeping unnecessary references. + */ + close(0); + close(1); + close(2); + + /* + * Redirect std{in,out,err} to /dev/null, just in + * case. + */ + open("/dev/null", O_RDWR); + dup(0); + dup(0); + } + } +#endif /* !WIN32 */ + } +#endif /* HAVE_WORKING_FORK */ + return i; +} + +#else /* !NEED_NETSNMP_DAEMONIZE */ +int netsnp_daemonize_bs; +#endif diff -urN src/contrib/ntp/ntpsnmpd/ntpSnmpSubagentObject.c src.ntp/contrib/ntp/ntpsnmpd/ntpSnmpSubagentObject.c --- src/contrib/ntp/ntpsnmpd/ntpSnmpSubagentObject.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpsnmpd/ntpSnmpSubagentObject.c 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,705 @@ +/***************************************************************************** + * + * ntpSnmpSubAgentObject.c + * + * This file provides the callback functions for net-snmp and registers the + * serviced MIB objects with the master agent. + * + * Each object has its own callback function that is called by the + * master agent process whenever someone queries the corresponding MIB + * object. + * + * At the moment this triggers a full send/receive procedure for each + * queried MIB object, one of the things that are still on my todo list: + * a caching mechanism that reduces the number of requests sent to the + * ntpd process. + * + ****************************************************************************/ +#include +#include +#include +#include "ntpSnmpSubagentObject.h" +#include + +/* general purpose buffer length definition */ +#define NTPQ_BUFLEN 2048 + +static int ntpSnmpSubagentObject = 3; + +char ntpvalue[NTPQ_BUFLEN]; + + + +/***************************************************************************** + * + * ntpsnmpd_strip_string + * + * This function removes white space characters and EOL chars + * from the beginning and end of a given NULL terminated string. + * Be aware that the parameter itself is altered. + * + **************************************************************************** + * Parameters: + * string char* The name of the string variable + * NOTE: must be NULL terminated! + * Returns: + * int length of resulting string (i.e. w/o white spaces) + ****************************************************************************/ + +int ntpsnmpd_strip_string(char *string) +{ + char newstring[2048] = { 0 }; + int i = 0; + int j = 0; + + if ( strlen(string) > 2047 ) + string[2048]=0; + + j = strlen(string); + + for (i=0;i 0x0D ) && ( string[i] != ' ' ) ) + l = j+1; + + if ( ( value[0] != 0 ) || ( ( string[i] > 0x0D ) && ( string[i] != ' ' ) ) ) + { + if (j < valuesize ) + value[j++]=string[i]; + } + } + + value[l]=0; + + if ( value[0]=='"' ) + strcpy(value, (char *) &value[1]); + + if ( value[strlen(value)-1] == '"' ) + value[strlen(value)-1]=0; + + return (strlen(value)); + +} + + +/***************************************************************************** + * + * ntpsnmpd_cut_string + * + * This function will parse a given NULL terminated string and cut it + * into fields using the specified delimiter character. + * It will then copy the requested field into a destination buffer + * Example: + * ntpsnmpd_cut_string(read:my:lips:fool, RESULT, ':', 2, sizeof(RESULT)) + * will copy "lips" to RESULT. + **************************************************************************** + * Parameters: + * src char* The name of the source string variable + * NOTE: must be NULL terminated! + * dest char* The name of the string which takes the + * requested field content + * delim char The delimiter character + * fieldnumber int The number of the required field + * (start counting with 0) + * maxsize int The maximum size of dest + * + * Returns: + * int length of resulting dest string + ****************************************************************************/ + +int ntpsnmpd_cut_string(char *src, char *dest, const char delim, int fieldnumber, int maxsize) +{ + char string[2048]; + int i = 0; + int j = 0; + int l = 0; + int a = 0; + + strncpy (string, src, sizeof(string)); + + a = strlen(string); + + memset (dest, 0, maxsize); + + /* Parsing the field name */ + for (i=0;l<=fieldnumber;i++) + { + if (i>=a) + l=fieldnumber+1; /* terminate loop */ + else + { + if ( string[i] == delim ) + { + l++; /* next field */ + } + else if ( ( l == fieldnumber) && ( j < maxsize ) ) + { + dest[j++]=string[i]; + } + + } + } + + return (strlen(dest)); + +} + + +/***************************************************************************** + * + * read_ntp_value + * + * This function retrieves the value for a given variable, currently + * this only supports sysvars. It starts a full mode 6 send/receive/parse + * iteration and needs to be optimized, e.g. by using a caching mechanism + * + **************************************************************************** + * Parameters: + * variable char* The name of the required variable + * rbuffer char* The buffer where the value goes + * maxlength int Max. number of bytes for resultbuf + * + * Returns: + * u_int number of chars that have been copied to + * rbuffer + ****************************************************************************/ + +unsigned int read_ntp_value(char *variable, char *rbuffer, unsigned int maxlength) +{ + unsigned int i, sv_len = 0; + char sv_data[NTPQ_BUFLEN]; + + memset (sv_data,0, NTPQ_BUFLEN); + sv_len= ntpq_read_sysvars ( sv_data, NTPQ_BUFLEN ); + + if ( sv_len ) + { + i=ntpq_getvar( sv_data, sv_len , variable, rbuffer, maxlength); + return i; + } else { + return 0; + } + +} + + +/***************************************************************************** + * + * The get_xxx functions + * + * The following function calls are callback functions that will be + * used by the master agent process to retrieve a value for a requested + * MIB object. + * + ****************************************************************************/ + + +int get_ntpEntSoftwareName (netsnmp_mib_handler *handler, + netsnmp_handler_registration *reginfo, + netsnmp_agent_request_info *reqinfo, + netsnmp_request_info *requests) +{ + char ntp_softwarename[NTPQ_BUFLEN]; + + memset (ntp_softwarename, 0, NTPQ_BUFLEN); + + switch (reqinfo->mode) { + case MODE_GET: + { + if ( read_ntp_value("product", ntpvalue, NTPQ_BUFLEN) ) + { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)ntpvalue, + strlen(ntpvalue) + ); + } + else if ( read_ntp_value("version", ntpvalue, NTPQ_BUFLEN) ) + { + ntpsnmpd_cut_string(ntpvalue, ntp_softwarename, ' ', 0, sizeof(ntp_softwarename)-1); + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)ntp_softwarename, + strlen(ntp_softwarename) + ); + } else { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)"N/A", + 3 + ); + } + break; + + } + + + default: + /* If we cannot get the information we need, we will return a generic error to the SNMP client */ + return SNMP_ERR_GENERR; + } + + return SNMP_ERR_NOERROR; +} + + +int get_ntpEntSoftwareVersion (netsnmp_mib_handler *handler, + netsnmp_handler_registration *reginfo, + netsnmp_agent_request_info *reqinfo, + netsnmp_request_info *requests) +{ + + switch (reqinfo->mode) { + case MODE_GET: + { + + if ( read_ntp_value("version", ntpvalue, NTPQ_BUFLEN) ) + { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)ntpvalue, + strlen(ntpvalue) + ); + } else { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)"N/A", + 3 + ); + } + break; + + } + + + default: + /* If we cannot get the information we need, we will return a generic error to the SNMP client */ + return SNMP_ERR_GENERR; + } + + return SNMP_ERR_NOERROR; +} + + +int get_ntpEntSoftwareVersionVal (netsnmp_mib_handler *handler, + netsnmp_handler_registration *reginfo, + netsnmp_agent_request_info *reqinfo, + netsnmp_request_info *requests) +{ + unsigned int i = 0; + switch (reqinfo->mode) { + case MODE_GET: + { + + if ( read_ntp_value("versionval", ntpvalue, NTPQ_BUFLEN) ) + { + i=atoi(ntpvalue); + snmp_set_var_typed_value(requests->requestvb, ASN_UNSIGNED, + (u_char *) &i, + sizeof (i) + ); + } else { + i = 0; + snmp_set_var_typed_value(requests->requestvb, ASN_UNSIGNED, + (u_char *) &i, + sizeof(i) + ); + } + break; + + } + + + default: + /* If we cannot get the information we need, we will return a generic error to the SNMP client */ + return SNMP_ERR_GENERR; + } + + return SNMP_ERR_NOERROR; +} + + + +int get_ntpEntSoftwareVendor (netsnmp_mib_handler *handler, + netsnmp_handler_registration *reginfo, + netsnmp_agent_request_info *reqinfo, + netsnmp_request_info *requests) +{ + + switch (reqinfo->mode) { + case MODE_GET: + { + + if ( read_ntp_value("vendor", ntpvalue, NTPQ_BUFLEN) ) + { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)ntpvalue, + strlen(ntpvalue) + ); + } else { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)"N/A", + 3 + ); + } + break; + + default: + /* If we cannot get the information we need, we will return a generic error to the SNMP client */ + return SNMP_ERR_GENERR; + } + } + return SNMP_ERR_NOERROR; +} + + +int get_ntpEntSystemType (netsnmp_mib_handler *handler, + netsnmp_handler_registration *reginfo, + netsnmp_agent_request_info *reqinfo, + netsnmp_request_info *requests) +{ + + switch (reqinfo->mode) { + case MODE_GET: + { + + if ( read_ntp_value("systemtype", ntpvalue, NTPQ_BUFLEN) ) + { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)ntpvalue, + strlen(ntpvalue) + ); + } + + if ( read_ntp_value("system", ntpvalue, NTPQ_BUFLEN) ) + { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)ntpvalue, + strlen(ntpvalue) + ); + } else { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)"N/A", + 3 + ); + } + break; + + } + + + default: + /* If we cannot get the information we need, we will return a generic error to the SNMP client */ + return SNMP_ERR_GENERR; + } + + return SNMP_ERR_NOERROR; +} + +int get_ntpEntTimeResolution (netsnmp_mib_handler *handler, + netsnmp_handler_registration *reginfo, + netsnmp_agent_request_info *reqinfo, + netsnmp_request_info *requests) +{ + + switch (reqinfo->mode) { + case MODE_GET: + { + + if ( read_ntp_value("resolution", ntpvalue, NTPQ_BUFLEN) ) + { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)ntpvalue, + strlen(ntpvalue) + ); + } else { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)"N/A", + 3 + ); + } + break; + + } + + + default: + /* If we cannot get the information we need, we will return a generic error to the SNMP client */ + return SNMP_ERR_GENERR; + } + + return SNMP_ERR_NOERROR; +} + + +int get_ntpEntTimeResolutionVal (netsnmp_mib_handler *handler, + netsnmp_handler_registration *reginfo, + netsnmp_agent_request_info *reqinfo, + netsnmp_request_info *requests) +{ + + unsigned int i = 0; + switch (reqinfo->mode) { + case MODE_GET: + { + + if ( read_ntp_value("resolutionval", ntpvalue, NTPQ_BUFLEN) ) + { + i=atoi(ntpvalue); + snmp_set_var_typed_value(requests->requestvb, ASN_UNSIGNED, + (u_char *) &i, + sizeof (i) + ); + } else { + i = 0; + snmp_set_var_typed_value(requests->requestvb, ASN_UNSIGNED, + (u_char *) &i, + sizeof(i) + ); + } + break; + + } + + + default: + /* If we cannot get the information we need, we will return a generic error to the SNMP client */ + return SNMP_ERR_GENERR; + } + + return SNMP_ERR_NOERROR; +} + + +int get_ntpEntTimePrecision (netsnmp_mib_handler *handler, + netsnmp_handler_registration *reginfo, + netsnmp_agent_request_info *reqinfo, + netsnmp_request_info *requests) +{ + switch (reqinfo->mode) { + case MODE_GET: + { + + if ( read_ntp_value("precision", ntpvalue, NTPQ_BUFLEN) ) + { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)ntpvalue, + strlen(ntpvalue) + ); + } else { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)"N/A", + 3 + ); + } + break; + + } + + + default: + /* If we cannot get the information we need, we will return a generic error to the SNMP client */ + return SNMP_ERR_GENERR; + } + + return SNMP_ERR_NOERROR; +} + +int get_ntpEntTimePrecisionVal (netsnmp_mib_handler *handler, + netsnmp_handler_registration *reginfo, + netsnmp_agent_request_info *reqinfo, + netsnmp_request_info *requests) +{ + + int i = 0; + switch (reqinfo->mode) { + case MODE_GET: + { + + if ( read_ntp_value("precision", ntpvalue, NTPQ_BUFLEN) ) + { + i=atoi(ntpvalue); + snmp_set_var_typed_value(requests->requestvb, ASN_INTEGER, + (u_char *) &i, + sizeof (i) + ); + } else { + i = 0; + snmp_set_var_typed_value(requests->requestvb, ASN_INTEGER, + (u_char *) &i, + sizeof(i) + ); + } + break; + + } + + + default: + /* If we cannot get the information we need, we will return a generic error to the SNMP client */ + return SNMP_ERR_GENERR; + } + + return SNMP_ERR_NOERROR; +} + + + +int get_ntpEntTimeDistance (netsnmp_mib_handler *handler, + netsnmp_handler_registration *reginfo, + netsnmp_agent_request_info *reqinfo, + netsnmp_request_info *requests) +{ + switch (reqinfo->mode) { + case MODE_GET: + { + + if ( read_ntp_value("rootdelay", ntpvalue, NTPQ_BUFLEN) ) + { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)ntpvalue, + strlen(ntpvalue) + ); + } else { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)"N/A", + 3 + ); + } + break; + + } + + + default: + /* If we cannot get the information we need, we will return a generic error to the SNMP client */ + return SNMP_ERR_GENERR; + } + + return SNMP_ERR_NOERROR; +} + + +/* + * + * Initialize sub agent + * TODO: Define NTP MIB OID (has to be assigned by IANA) + * At the moment we use a private MIB branch (enterprises.5597.99) + */ + +void +init_ntpSnmpSubagentObject(void) +{ + + /* Register all MIB objects with the agentx master */ + + _SETUP_OID_RO( ntpEntSoftwareName , NTPV4_OID , 1, 1, 1, 0 ); + _SETUP_OID_RO( ntpEntSoftwareVersion , NTPV4_OID , 1, 1, 2, 0 ); + _SETUP_OID_RO( ntpEntSoftwareVersionVal , NTPV4_OID , 1, 1, 3, 0 ); + _SETUP_OID_RO( ntpEntSoftwareVendor , NTPV4_OID , 1, 1, 4, 0 ); + _SETUP_OID_RO( ntpEntSystemType , NTPV4_OID , 1, 1, 5, 0 ); + _SETUP_OID_RO( ntpEntTimeResolution , NTPV4_OID , 1, 1, 6, 0 ); + _SETUP_OID_RO( ntpEntTimeResolutionVal , NTPV4_OID , 1, 1, 7, 0 ); + _SETUP_OID_RO( ntpEntTimePrecision , NTPV4_OID , 1, 1, 8, 0 ); + _SETUP_OID_RO( ntpEntTimePrecisionVal , NTPV4_OID , 1, 1, 9, 0 ); + _SETUP_OID_RO( ntpEntTimeDistance , NTPV4_OID , 1, 1,10, 0 ); + +} + diff -urN src/contrib/ntp/ntpsnmpd/ntpSnmpSubagentObject.h src.ntp/contrib/ntp/ntpsnmpd/ntpSnmpSubagentObject.h --- src/contrib/ntp/ntpsnmpd/ntpSnmpSubagentObject.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpsnmpd/ntpSnmpSubagentObject.h 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1,75 @@ +/***************************************************************************** + * + * ntpSnmpSubAgentObject.h + * + * Definitions and macros for ntpSnmpSubAgentObject.c + * + ****************************************************************************/ + + +#ifndef NTPSNMPSUBAGENTOBJECT_H +#define NTPSNMPSUBAGENTOBJECT_H + +/* Function Prototypes */ +int ntpsnmpd_strip_string(char *string); +int ntpsnmpd_parse_string(char *src, char *field, int fieldsize, char *value, int valuesize); +int ntpsnmpd_cut_string(char *src, char *dest, const char delim, int fieldnumber, int maxsize); +unsigned int read_ntp_value(char *variable, char *rbuffer, unsigned int maxlength); + +/* Initialization */ +void init_ntpSnmpSubagentObject(void); + +/* MIB Section 1 Callback Functions*/ +Netsnmp_Node_Handler get_ntpEntSoftwareName; +Netsnmp_Node_Handler get_ntpEntSoftwareVersion; +Netsnmp_Node_Handler get_ntpEntSoftwareVersionVal; +Netsnmp_Node_Handler get_ntpEntSoftwareVendor; +Netsnmp_Node_Handler get_ntpEntSystemType; +Netsnmp_Node_Handler get_ntpEntTimeResolution; +Netsnmp_Node_Handler get_ntpEntTimeResolutionVal; +Netsnmp_Node_Handler get_ntpEntTimePrecision; +Netsnmp_Node_Handler get_ntpEntTimePrecisionVal; +Netsnmp_Node_Handler get_ntpEntTimeDistance; + +/* MIB Section 2 Callback Functions (TODO) */ +Netsnmp_Node_Handler get_ntpEntStatusCurrentMode; +Netsnmp_Node_Handler get_ntpEntStatusCurrentModeVal; +Netsnmp_Node_Handler get_ntpEntStatusStratum; +Netsnmp_Node_Handler get_ntpEntStatusActiveRefSourceId; +Netsnmp_Node_Handler get_ntpEntStatusActiveRefSourceName; +Netsnmp_Node_Handler get_ntpEntStatusActiveOffset; + +/* TODO: This needs to be changed as soon as the official OID has been registered with IANA */ +#define NTPV4_OID 1,3,6,1,4,1,5597,99 + + +/* The following two macros simplify the registration of the callback functions + * and allow to easily specify the name and OID of either read-only (RO) or read-write (RW) functions + */ + +#define _SETUP_OID_RO( _oidname, ... ) \ + static oid _oidname##_oid [] = { __VA_ARGS__ }; \ + { \ + netsnmp_register_read_only_instance(netsnmp_create_handler_registration \ + ("#_oidname", \ + get_##_oidname, \ + _oidname##_oid, \ + OID_LENGTH \ + ( _oidname##_oid ), \ + HANDLER_CAN_RONLY)); \ + } + +#define _SETUP_OID_RW( _oidname, ... ) \ + static oid _oidname##_oid [] = { __VA_ARGS__ }; \ + { \ + netsnmp_register_instance(netsnmp_create_handler_registration \ + ("#_oidname", \ + do_##_oidname, \ + _oidname##_oid, \ + OID_LENGTH \ + ( _oidname##_oid ), \ + HANDLER_CAN_RWRITE)); \ + } + + +#endif diff -urN src/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.c src.ntp/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.c --- src/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.c 2010-07-09 04:24:28.000000000 +0200 @@ -0,0 +1,431 @@ +/* + * EDIT THIS FILE WITH CAUTION (ntpsnmpd-opts.c) + * + * It has been AutoGen-ed July 9, 2010 at 02:24:28 AM by AutoGen 5.10 + * From the definitions ntpsnmpd-opts.def + * and the template file options + * + * Generated from AutoOpts 33:0:8 templates. + */ + +/* + * This file was produced by an AutoOpts template. AutoOpts is a + * copyrighted work. This source file is not encumbered by AutoOpts + * licensing, but is provided under the licensing terms chosen by the + * ntpsnmpd author or copyright holder. AutoOpts is licensed under + * the terms of the LGPL. The redistributable library (``libopts'') is + * licensed under the terms of either the LGPL or, at the users discretion, + * the BSD license. See the AutoOpts and/or libopts sources for details. + * + * This source file is copyrighted and licensed under the following terms: + * + * ntpsnmpd copyright (c) 1970-2010 David L. Mills and/or others - all rights reserved + * + * see html/copyright.html + */ + +#include +#include +#include +#include + +#define OPTION_CODE_COMPILE 1 +#include "ntpsnmpd-opts.h" + +#ifdef __cplusplus +extern "C" { +#endif + +/* TRANSLATORS: choose the translation for option names wisely because you + cannot ever change your mind. */ +tSCC zCopyright[] = + "ntpsnmpd copyright (c) 1970-2010 David L. Mills and/or others, all rights reserved" +/* extracted from ../include/copyright.def near line 8 */ +; +tSCC zCopyrightNotice[24] = +"see html/copyright.html"; + +extern tUsageProc optionUsage; + +#ifndef NULL +# define NULL 0 +#endif +#ifndef EXIT_SUCCESS +# define EXIT_SUCCESS 0 +#endif +#ifndef EXIT_FAILURE +# define EXIT_FAILURE 1 +#endif + +/* + * Nofork option description: + */ +tSCC zNoforkText[] = + "Do not fork"; +tSCC zNofork_NAME[] = "NOFORK"; +tSCC zNofork_Name[] = "nofork"; +#define NOFORK_FLAGS (OPTST_DISABLED) + +/* + * Syslog option description: + */ +tSCC zSyslogText[] = + "Log to syslog()"; +tSCC zSyslog_NAME[] = "SYSLOG"; +tSCC zSyslog_Name[] = "syslog"; +#define SYSLOG_FLAGS (OPTST_DISABLED) + +/* + * Agentxsocket option description: + */ +tSCC zAgentxsocketText[] = + "The socket address ntpsnmpd uses to connect to net-snmpd"; +tSCC zAgentxsocket_NAME[] = "AGENTXSOCKET"; +tSCC zAgentxsocket_Name[] = "agentxsocket"; +tSCC zAgentxsocketDefaultArg[] = "unix:/var/agentx/master"; +#define AGENTXSOCKET_FLAGS (OPTST_DISABLED \ + | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) + +/* + * Help/More_Help/Version option descriptions: + */ +tSCC zHelpText[] = "Display extended usage information and exit"; +tSCC zHelp_Name[] = "help"; +#ifdef HAVE_WORKING_FORK +#define OPTST_MORE_HELP_FLAGS (OPTST_IMM | OPTST_NO_INIT) +tSCC zMore_Help_Name[] = "more-help"; +tSCC zMore_HelpText[] = "Extended usage information passed thru pager"; +#else +#define OPTST_MORE_HELP_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#define zMore_Help_Name NULL +#define zMore_HelpText NULL +#endif +#ifdef NO_OPTIONAL_OPT_ARGS +# define OPTST_VERSION_FLAGS OPTST_IMM | OPTST_NO_INIT +#else +# define OPTST_VERSION_FLAGS OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ + OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT +#endif + +tSCC zVersionText[] = "Output version information and exit"; +tSCC zVersion_Name[] = "version"; +tSCC zSave_OptsText[] = "Save the option state to a config file"; +tSCC zSave_Opts_Name[] = "save-opts"; +tSCC zLoad_OptsText[] = "Load options from a config file"; +tSCC zLoad_Opts_NAME[] = "LOAD_OPTS"; +tSCC zNotLoad_Opts_Name[] = "no-load-opts"; +tSCC zNotLoad_Opts_Pfx[] = "no"; +#define zLoad_Opts_Name (zNotLoad_Opts_Name + 3) +/* + * Declare option callback procedures + */ +#if defined(TEST_NTPSNMPD_OPTS) +/* + * Under test, omit argument processing, or call optionStackArg, + * if multiple copies are allowed. + */ +extern tOptProc + optionPagedUsage, optionVersionStderr; +static tOptProc + doUsageOpt; + +#else /* NOT defined TEST_NTPSNMPD_OPTS */ +/* + * When not under test, there are different procs to use + */ +extern tOptProc + optionPagedUsage, optionPrintVersion; +static tOptProc + doUsageOpt; +#endif /* defined(TEST_NTPSNMPD_OPTS) */ +#ifdef TEST_NTPSNMPD_OPTS +# define DOVERPROC optionVersionStderr +#else +# define DOVERPROC optionPrintVersion +#endif /* TEST_NTPSNMPD_OPTS */ + +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * + * + * Define the Ntpsnmpd Option Descriptions. + */ +static tOptDesc optDesc[ OPTION_CT ] = { + { /* entry idx, value */ 0, VALUE_OPT_NOFORK, + /* equiv idx, value */ 0, VALUE_OPT_NOFORK, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ NOFORK_FLAGS, 0, + /* last opt argumnt */ { NULL }, + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ NULL, + /* desc, NAME, name */ zNoforkText, zNofork_NAME, zNofork_Name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ 1, VALUE_OPT_SYSLOG, + /* equiv idx, value */ 1, VALUE_OPT_SYSLOG, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ SYSLOG_FLAGS, 0, + /* last opt argumnt */ { NULL }, + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ NULL, + /* desc, NAME, name */ zSyslogText, zSyslog_NAME, zSyslog_Name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ 2, VALUE_OPT_AGENTXSOCKET, + /* equiv idx, value */ 2, VALUE_OPT_AGENTXSOCKET, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ AGENTXSOCKET_FLAGS, 0, + /* last opt argumnt */ { zAgentxsocketDefaultArg }, + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ NULL, + /* desc, NAME, name */ zAgentxsocketText, zAgentxsocket_NAME, zAgentxsocket_Name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ INDEX_OPT_VERSION, VALUE_OPT_VERSION, + /* equiv idx value */ NO_EQUIVALENT, 0, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ OPTST_VERSION_FLAGS, 0, + /* last opt argumnt */ { NULL }, + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ DOVERPROC, + /* desc, NAME, name */ zVersionText, NULL, zVersion_Name, + /* disablement strs */ NULL, NULL }, + + + + { /* entry idx, value */ INDEX_OPT_HELP, VALUE_OPT_HELP, + /* equiv idx value */ NO_EQUIVALENT, 0, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, 0, + /* last opt argumnt */ { NULL }, + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ doUsageOpt, + /* desc, NAME, name */ zHelpText, NULL, zHelp_Name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ INDEX_OPT_MORE_HELP, VALUE_OPT_MORE_HELP, + /* equiv idx value */ NO_EQUIVALENT, 0, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ OPTST_MORE_HELP_FLAGS, 0, + /* last opt argumnt */ { NULL }, + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ optionPagedUsage, + /* desc, NAME, name */ zMore_HelpText, NULL, zMore_Help_Name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ INDEX_OPT_SAVE_OPTS, VALUE_OPT_SAVE_OPTS, + /* equiv idx value */ NO_EQUIVALENT, 0, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) + | OPTST_ARG_OPTIONAL | OPTST_NO_INIT, 0, + /* last opt argumnt */ { NULL }, + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ NULL, + /* desc, NAME, name */ zSave_OptsText, NULL, zSave_Opts_Name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ INDEX_OPT_LOAD_OPTS, VALUE_OPT_LOAD_OPTS, + /* equiv idx value */ NO_EQUIVALENT, 0, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, NOLIMIT, 0, + /* opt state flags */ OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) + | OPTST_DISABLE_IMM, 0, + /* last opt argumnt */ { NULL }, + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ optionLoadOpt, + /* desc, NAME, name */ zLoad_OptsText, zLoad_Opts_NAME, zLoad_Opts_Name, + /* disablement strs */ zNotLoad_Opts_Name, zNotLoad_Opts_Pfx } +}; + +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * + * + * Define the Ntpsnmpd Option Environment + */ +tSCC zPROGNAME[] = "NTPSNMPD"; +tSCC zUsageTitle[] = +"ntpsnmpd - NTP SNMP MIB agent - Ver. 4.2.6p2\n\ +USAGE: %s [ - [] | --[{=| }] ]...\n"; +tSCC zRcName[] = ".ntprc"; +tSCC* apzHomeList[] = { + "$HOME", + ".", + NULL }; + +tSCC zBugsAddr[] = "http://bugs.ntp.org, bugs@ntp.org"; +#define zExplain NULL +#define zDetail NULL +tSCC zFullVersion[] = NTPSNMPD_FULL_VERSION; +/* extracted from /usr/local/gnu/share/autogen/optcode.tpl near line 495 */ + +#if defined(ENABLE_NLS) +# define OPTPROC_BASE OPTPROC_TRANSLATE + static tOptionXlateProc translate_option_strings; +#else +# define OPTPROC_BASE OPTPROC_NONE +# define translate_option_strings NULL +#endif /* ENABLE_NLS */ + + +#define ntpsnmpd_full_usage NULL +#define ntpsnmpd_short_usage NULL +tOptions ntpsnmpdOptions = { + OPTIONS_STRUCT_VERSION, + 0, NULL, /* original argc + argv */ + ( OPTPROC_BASE + + OPTPROC_ERRSTOP + + OPTPROC_SHORTOPT + + OPTPROC_LONGOPT + + OPTPROC_NO_REQ_OPT + + OPTPROC_ENVIRON + + OPTPROC_NO_ARGS ), + 0, NULL, /* current option index, current option */ + NULL, NULL, zPROGNAME, + zRcName, zCopyright, zCopyrightNotice, + zFullVersion, apzHomeList, zUsageTitle, + zExplain, zDetail, optDesc, + zBugsAddr, /* address to send bugs to */ + NULL, NULL, /* extensions/saved state */ + optionUsage, /* usage procedure */ + translate_option_strings, /* translation procedure */ + /* + * Indexes to special options + */ + { INDEX_OPT_MORE_HELP, /* more-help option index */ + INDEX_OPT_SAVE_OPTS, /* save option index */ + NO_EQUIVALENT, /* '-#' option index */ + NO_EQUIVALENT /* index of default opt */ + }, + 8 /* full option count */, 3 /* user option count */, + ntpsnmpd_full_usage, ntpsnmpd_short_usage, + NULL, NULL +}; + +/* + * Create the static procedure(s) declared above. + */ +static void +doUsageOpt( + tOptions* pOptions, + tOptDesc* pOptDesc ) +{ + (void)pOptions; + USAGE( EXIT_SUCCESS ); +} +/* extracted from /usr/local/gnu/share/autogen/optmain.tpl near line 109 */ + +#if defined(TEST_NTPSNMPD_OPTS) /* TEST MAIN PROCEDURE: */ + +extern void optionPutShell( tOptions* ); + +int +main(int argc, char** argv) +{ + int res = EXIT_SUCCESS; + (void)optionProcess( &ntpsnmpdOptions, argc, argv ); + optionPutShell( &ntpsnmpdOptions ); + return res; +} +#endif /* defined TEST_NTPSNMPD_OPTS */ +/* extracted from /usr/local/gnu/share/autogen/optcode.tpl near line 627 */ + +#if ENABLE_NLS +#include +#include +#include +#include +#include + +static char* AO_gettext( char const* pz ); +static void coerce_it(void** s); + +static char* +AO_gettext( char const* pz ) +{ + char* pzRes; + if (pz == NULL) + return NULL; + pzRes = _(pz); + if (pzRes == pz) + return pzRes; + pzRes = strdup( pzRes ); + if (pzRes == NULL) { + fputs( _("No memory for duping translated strings\n"), stderr ); + exit( EXIT_FAILURE ); + } + return pzRes; +} + +static void coerce_it(void** s) { *s = AO_gettext(*s); } +#define COERSION(_f) \ + coerce_it((void*)&(ntpsnmpdOptions._f)) + +/* + * This invokes the translation code (e.g. gettext(3)). + */ +static void +translate_option_strings( void ) +{ + /* + * Guard against re-translation. It won't work. The strings will have + * been changed by the first pass through this code. One shot only. + */ + if (option_usage_text.field_ct != 0) { + + /* + * Do the translations. The first pointer follows the field count + * field. The field count field is the size of a pointer. + */ + tOptDesc* pOD = ntpsnmpdOptions.pOptDesc; + char** ppz = (char**)(void*)&(option_usage_text); + int ix = option_usage_text.field_ct; + + do { + ppz++; + *ppz = AO_gettext(*ppz); + } while (--ix > 0); + + COERSION(pzCopyright); + COERSION(pzCopyNotice); + COERSION(pzFullVersion); + COERSION(pzUsageTitle); + COERSION(pzExplain); + COERSION(pzDetail); + option_usage_text.field_ct = 0; + + for (ix = ntpsnmpdOptions.optCt; ix > 0; ix--, pOD++) + coerce_it((void*)&(pOD->pzText)); + } + + if ((ntpsnmpdOptions.fOptSet & OPTPROC_NXLAT_OPT_CFG) == 0) { + tOptDesc* pOD = ntpsnmpdOptions.pOptDesc; + int ix; + + for (ix = ntpsnmpdOptions.optCt; ix > 0; ix--, pOD++) { + coerce_it((void*)&(pOD->pz_Name)); + coerce_it((void*)&(pOD->pz_DisableName)); + coerce_it((void*)&(pOD->pz_DisablePfx)); + } + /* prevent re-translation */ + ntpsnmpdOptions.fOptSet |= OPTPROC_NXLAT_OPT_CFG | OPTPROC_NXLAT_OPT; + } +} + +#endif /* ENABLE_NLS */ + +#ifdef __cplusplus +} +#endif +/* ntpsnmpd-opts.c ends here */ diff -urN src/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.def src.ntp/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.def --- src/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.def 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.def 2010-05-03 12:01:12.000000000 +0200 @@ -0,0 +1,40 @@ +/* -*- Mode: Text -*- */ + +autogen definitions options; + +#include copyright.def +#include homerc.def +#include autogen-version.def + +prog-name = "ntpsnmpd"; +prog-title = "NTP SNMP MIB agent"; + +test-main; + +flag = { + name = nofork; + value = n; + descrip = "Do not fork"; + doc = <<- _EndOfDoc_ + _EndOfDoc_; +}; + +flag = { + name = syslog; + value = p; + descrip = "Log to syslog()"; + doc = <<- _EndOfDoc_ + _EndOfDoc_; +}; + +flag = { + name = agentXSocket; +/* value = x; */ + arg-type = string; + arg-default = "unix:/var/agentx/master"; + descrip = "The socket address ntpsnmpd uses to connect to net-snmpd"; + doc = <<- _EndOfDoc_ + [:] + The default is the Unix Domain socket "unix:/var/agentx/master". Another common alternative is tcp:localhost:705. + _EndOfDoc_; +}; diff -urN src/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.h src.ntp/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.h --- src/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.h 2010-07-09 04:24:28.000000000 +0200 @@ -0,0 +1,186 @@ +/* + * EDIT THIS FILE WITH CAUTION (ntpsnmpd-opts.h) + * + * It has been AutoGen-ed July 9, 2010 at 02:24:28 AM by AutoGen 5.10 + * From the definitions ntpsnmpd-opts.def + * and the template file options + * + * Generated from AutoOpts 33:0:8 templates. + */ + +/* + * This file was produced by an AutoOpts template. AutoOpts is a + * copyrighted work. This header file is not encumbered by AutoOpts + * licensing, but is provided under the licensing terms chosen by the + * ntpsnmpd author or copyright holder. AutoOpts is licensed under + * the terms of the LGPL. The redistributable library (``libopts'') is + * licensed under the terms of either the LGPL or, at the users discretion, + * the BSD license. See the AutoOpts and/or libopts sources for details. + * + * This source file is copyrighted and licensed under the following terms: + * + * ntpsnmpd copyright (c) 1970-2010 David L. Mills and/or others - all rights reserved + * + * see html/copyright.html + */ +/* + * This file contains the programmatic interface to the Automated + * Options generated for the ntpsnmpd program. + * These macros are documented in the AutoGen info file in the + * "AutoOpts" chapter. Please refer to that doc for usage help. + */ +#ifndef AUTOOPTS_NTPSNMPD_OPTS_H_GUARD +#define AUTOOPTS_NTPSNMPD_OPTS_H_GUARD 1 +#include "config.h" +#include + +/* + * Ensure that the library used for compiling this generated header is at + * least as new as the version current when the header template was released + * (not counting patch version increments). Also ensure that the oldest + * tolerable version is at least as old as what was current when the header + * template was released. + */ +#define AO_TEMPLATE_VERSION 135168 +#if (AO_TEMPLATE_VERSION < OPTIONS_MINIMUM_VERSION) \ + || (AO_TEMPLATE_VERSION > OPTIONS_STRUCT_VERSION) +# error option template version mismatches autoopts/options.h header + Choke Me. +#endif + +/* + * Enumeration of each option: + */ +typedef enum { + INDEX_OPT_NOFORK = 0, + INDEX_OPT_SYSLOG = 1, + INDEX_OPT_AGENTXSOCKET = 2, + INDEX_OPT_VERSION = 3, + INDEX_OPT_HELP = 4, + INDEX_OPT_MORE_HELP = 5, + INDEX_OPT_SAVE_OPTS = 6, + INDEX_OPT_LOAD_OPTS = 7 +} teOptIndex; + +#define OPTION_CT 8 +#define NTPSNMPD_VERSION "4.2.6p2" +#define NTPSNMPD_FULL_VERSION "ntpsnmpd - NTP SNMP MIB agent - Ver. 4.2.6p2" + +/* + * Interface defines for all options. Replace "n" with the UPPER_CASED + * option name (as in the teOptIndex enumeration above). + * e.g. HAVE_OPT( NOFORK ) + */ +#define DESC(n) (ntpsnmpdOptions.pOptDesc[INDEX_OPT_## n]) +#define HAVE_OPT(n) (! UNUSED_OPT(& DESC(n))) +#define OPT_ARG(n) (DESC(n).optArg.argString) +#define STATE_OPT(n) (DESC(n).fOptState & OPTST_SET_MASK) +#define COUNT_OPT(n) (DESC(n).optOccCt) +#define ISSEL_OPT(n) (SELECTED_OPT(&DESC(n))) +#define ISUNUSED_OPT(n) (UNUSED_OPT(& DESC(n))) +#define ENABLED_OPT(n) (! DISABLED_OPT(& DESC(n))) +#define STACKCT_OPT(n) (((tArgList*)(DESC(n).optCookie))->useCt) +#define STACKLST_OPT(n) (((tArgList*)(DESC(n).optCookie))->apzArgs) +#define CLEAR_OPT(n) STMTS( \ + DESC(n).fOptState &= OPTST_PERSISTENT_MASK; \ + if ( (DESC(n).fOptState & OPTST_INITENABLED) == 0) \ + DESC(n).fOptState |= OPTST_DISABLED; \ + DESC(n).optCookie = NULL ) + +/* + * Make sure there are no #define name conflicts with the option names + */ +#ifndef NO_OPTION_NAME_WARNINGS +# ifdef NOFORK +# warning undefining NOFORK due to option name conflict +# undef NOFORK +# endif +# ifdef SYSLOG +# warning undefining SYSLOG due to option name conflict +# undef SYSLOG +# endif +# ifdef AGENTXSOCKET +# warning undefining AGENTXSOCKET due to option name conflict +# undef AGENTXSOCKET +# endif +#else /* NO_OPTION_NAME_WARNINGS */ +# undef NOFORK +# undef SYSLOG +# undef AGENTXSOCKET +#endif /* NO_OPTION_NAME_WARNINGS */ + +/* * * * * * + * + * Interface defines for specific options. + */ +#define VALUE_OPT_NOFORK 'n' +#define VALUE_OPT_SYSLOG 'p' +#define VALUE_OPT_AGENTXSOCKET 2 +#define VALUE_OPT_HELP '?' +#define VALUE_OPT_MORE_HELP '!' +#define VALUE_OPT_VERSION INDEX_OPT_VERSION +#define VALUE_OPT_SAVE_OPTS '>' +#define VALUE_OPT_LOAD_OPTS '<' +#define SET_OPT_SAVE_OPTS(a) STMTS( \ + DESC(SAVE_OPTS).fOptState &= OPTST_PERSISTENT_MASK; \ + DESC(SAVE_OPTS).fOptState |= OPTST_SET; \ + DESC(SAVE_OPTS).optArg.argString = (char const*)(a) ) +/* + * Interface defines not associated with particular options + */ +#define ERRSKIP_OPTERR STMTS( ntpsnmpdOptions.fOptSet &= ~OPTPROC_ERRSTOP ) +#define ERRSTOP_OPTERR STMTS( ntpsnmpdOptions.fOptSet |= OPTPROC_ERRSTOP ) +#define RESTART_OPT(n) STMTS( \ + ntpsnmpdOptions.curOptIdx = (n); \ + ntpsnmpdOptions.pzCurOpt = NULL ) +#define START_OPT RESTART_OPT(1) +#define USAGE(c) (*ntpsnmpdOptions.pUsageProc)( &ntpsnmpdOptions, c ) +/* extracted from /usr/local/gnu/share/autogen/opthead.tpl near line 409 */ + +/* * * * * * + * + * Declare the ntpsnmpd option descriptor. + */ +#ifdef __cplusplus +extern "C" { +#endif + +extern tOptions ntpsnmpdOptions; + +#if defined(ENABLE_NLS) +# ifndef _ +# include + static inline char* aoGetsText( char const* pz ) { + if (pz == NULL) return NULL; + return (char*)gettext( pz ); + } +# define _(s) aoGetsText(s) +# endif /* _() */ + +# define OPT_NO_XLAT_CFG_NAMES STMTS(ntpsnmpdOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT_CFG;) +# define OPT_NO_XLAT_OPT_NAMES STMTS(ntpsnmpdOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG;) + +# define OPT_XLAT_CFG_NAMES STMTS(ntpsnmpdOptions.fOptSet &= \ + ~(OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG);) +# define OPT_XLAT_OPT_NAMES STMTS(ntpsnmpdOptions.fOptSet &= \ + ~OPTPROC_NXLAT_OPT;) + +#else /* ENABLE_NLS */ +# define OPT_NO_XLAT_CFG_NAMES +# define OPT_NO_XLAT_OPT_NAMES + +# define OPT_XLAT_CFG_NAMES +# define OPT_XLAT_OPT_NAMES + +# ifndef _ +# define _(_s) _s +# endif +#endif /* ENABLE_NLS */ + +#ifdef __cplusplus +} +#endif +#endif /* AUTOOPTS_NTPSNMPD_OPTS_H_GUARD */ +/* ntpsnmpd-opts.h ends here */ diff -urN src/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.menu src.ntp/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.menu --- src/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.menu 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.menu 2010-07-09 04:24:32.000000000 +0200 @@ -0,0 +1 @@ +* ntpsnmpd Invocation:: Invoking ntpsnmpd diff -urN src/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.texi src.ntp/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.texi --- src/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.texi 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.texi 2010-07-09 04:24:32.000000000 +0200 @@ -0,0 +1,83 @@ +@node ntpsnmpd Invocation +@section Invoking ntpsnmpd +@pindex ntpsnmpd +@cindex NTP SNMP MIB agent +@ignore +# +# EDIT THIS FILE WITH CAUTION (ntpsnmpd-opts.texi) +# +# It has been AutoGen-ed July 9, 2010 at 02:24:33 AM by AutoGen 5.10 +# From the definitions ntpsnmpd-opts.def +# and the template file aginfo.tpl +@end ignore +This program has no explanation. + + + +This section was generated by @strong{AutoGen}, +the aginfo template and the option descriptions for the @command{ntpsnmpd} program. It documents the ntpsnmpd usage text and option meanings. + +This software is released under a specialized copyright license. + +@menu +* ntpsnmpd usage:: ntpsnmpd usage help (-?) +* ntpsnmpd agentxsocket:: agentxsocket option +* ntpsnmpd nofork:: nofork option (-n) +* ntpsnmpd syslog:: syslog option (-p) +@end menu + +@node ntpsnmpd usage +@subsection ntpsnmpd usage help (-?) +@cindex ntpsnmpd usage + +This is the automatically generated usage text for ntpsnmpd: + +@exampleindent 0 +@example +ntpsnmpd - NTP SNMP MIB agent - Ver. 4.2.6p2 +USAGE: ntpsnmpd [ - [] | --[@{=| @}] ]... + Flg Arg Option-Name Description + -n no nofork Do not fork + -p no syslog Log to syslog() + Str agentxsocket The socket address ntpsnmpd uses to connect to net-snmpd + opt version Output version information and exit + -? no help Display extended usage information and exit + -! no more-help Extended usage information passed thru pager + -> opt save-opts Save the option state to a config file + -< Str load-opts Load options from a config file + - disabled as --no-load-opts + - may appear multiple times + +Options are specified by doubled hyphens and their name +or by a single hyphen and the flag character. + +The following option preset mechanisms are supported: + - reading file /deacon/users/stenn/.ntprc + - reading file /deacon/backroom/snaps/ntp-stable/ntpsnmpd/.ntprc + - examining environment variables named NTPSNMPD_* + +please send bug reports to: http://bugs.ntp.org, bugs@@ntp.org +@end example +@exampleindent 4 + +@node ntpsnmpd nofork +@subsection nofork option (-n) +@cindex ntpsnmpd-nofork + +This is the ``do not fork'' option. + + +@node ntpsnmpd syslog +@subsection syslog option (-p) +@cindex ntpsnmpd-syslog + +This is the ``log to syslog()'' option. + + +@node ntpsnmpd agentxsocket +@subsection agentxsocket option +@cindex ntpsnmpd-agentxsocket + +This is the ``the socket address ntpsnmpd uses to connect to net-snmpd'' option. +[:] +The default is the Unix Domain socket "unix:/var/agentx/master". Another common alternative is tcp:localhost:705. diff -urN src/contrib/ntp/ntpsnmpd/ntpsnmpd.1 src.ntp/contrib/ntp/ntpsnmpd/ntpsnmpd.1 --- src/contrib/ntp/ntpsnmpd/ntpsnmpd.1 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpsnmpd/ntpsnmpd.1 2010-07-09 04:24:32.000000000 +0200 @@ -0,0 +1,86 @@ +.TH NTPSNMPD 1 2010-07-09 "( 4.2.6p2)" "Programmer's Manual" +.\" EDIT THIS FILE WITH CAUTION (ntpsnmpd.1) +.\" +.\" It has been AutoGen-ed July 9, 2010 at 02:24:32 AM by AutoGen 5.10 +.\" From the definitions ntpsnmpd-opts.def +.\" and the template file agman1.tpl +.\" +.SH NAME +ntpsnmpd \- NTP SNMP MIB agent +.SH SYNOPSIS +.B ntpsnmpd +.\" Mixture of short (flag) options and long options +.RB [ \-\fIflag\fP " [\fIvalue\fP]]... [" \--\fIopt-name\fP " [[=| ]\fIvalue\fP]]..." +.PP +All arguments must be options. +.SH "DESCRIPTION" +This manual page briefly documents the \fBntpsnmpd\fP command. +Its description is not documented. +.SH OPTIONS +.TP +.BR \-n ", " \--nofork +Do not fork. +.sp + +.TP +.BR \-p ", " \--syslog +Log to syslog(). +.sp + +.TP +.BR \--agentxsocket "=\fIstring\fP" +The socket address ntpsnmpd uses to connect to net-snmpd. +The default \fIstring\fP for this option is: +.ti +4 + unix:/var/agentx/master +.sp +[:] +The default is the Unix Domain socket "unix:/var/agentx/master". Another common alternative is tcp:localhost:705. +.TP +.BR \-? , " \--help" +Display extended usage information and exit. +.TP +.BR \-! , " \--more-help" +Extended usage information passed thru pager. +.TP +.BR \-> " [\fIrcfile\fP]," " \--save-opts" "[=\fIrcfile\fP]" +Save the option state to \fIrcfile\fP. The default is the \fIlast\fP +configuration file listed in the \fBOPTION PRESETS\fP section, below. +.TP +.BR \-< " \fIrcfile\fP," " \--load-opts" "=\fIrcfile\fP," " \--no-load-opts" +Load options from \fIrcfile\fP. +The \fIno-load-opts\fP form will disable the loading +of earlier RC/INI files. \fI--no-load-opts\fP is handled early, +out of order. +.TP +.BR \- " [{\fIv|c|n\fP}]," " \--version" "[=\fI{v|c|n}\fP]" +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.SH OPTION PRESETS +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from configuration ("RC" or ".INI") file(s) and values from +environment variables named: +.nf + \fBNTPSNMPD_\fP or \fBNTPSNMPD\fP +.fi +.ad +The environmental presets take precedence (are processed later than) +the configuration files. +The \fIhomerc\fP files are "\fI$HOME\fP", and "\fI.\fP". +If any of these are directories, then the file \fI.ntprc\fP +is searched for within those directories. +.SH AUTHOR +David L. Mills and/or others +.br +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org + +.PP +.nf +.na +see html/copyright.html +.fi +.ad +.PP +This manual page was \fIAutoGen\fP-erated from the \fBntpsnmpd\fP +option definitions. diff -urN src/contrib/ntp/ntpsnmpd/ntpsnmpd.c src.ntp/contrib/ntp/ntpsnmpd/ntpsnmpd.c --- src/contrib/ntp/ntpsnmpd/ntpsnmpd.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpsnmpd/ntpsnmpd.c 2010-07-09 04:17:43.000000000 +0200 @@ -0,0 +1,129 @@ +/***************************************************************************** + * + * ntpsnmpd.c + * + * The NTP SNMP daemon is an Agent X subagent application that + * registers itself with a running SNMP Agent X master process running + * on the same machine on port TCP 705. It utilizes the libntqp library + * which accesses status and general data of a running ntpd process on + * the same machine and enables the user to monitor the status of a + * ntp daemon process via SNMP. + * + * This started as a Google Summer of Code 2008 project, + * including the ntpsnmpd sub agent and the libntpq library. + * + * For more information please visit + * http://support.ntp.org/bin/view/Dev/GSoC2008snmp + * Or contact: + * Harlan Stenn (Mentor) at stenn@ntp.org + * Heiko Gerstung (Student) at gerstung@ntp.org + * + ****************************************************************************/ + +#include +#include + +#ifdef SOLARIS /* needed with at least Solaris 8 */ +#include +#endif + +#include +#include +#include +#include + +#undef PACKAGE_BUGREPORT +#undef PACKAGE_NAME +#undef PACKAGE_STRING +#undef PACKAGE_TARNAME +#undef PACKAGE_VERSION + +#include +#include + +static int keep_running; + +RETSIGTYPE +stop_server(int a) { + keep_running = 0; +} + +/* The main function just sets up a few things and then enters a loop in which it will + * wait for SNMP requests coming from the master agent + */ + +int +main (int argc, char **argv) { + int background = 0; /* start as background process */ + int use_syslog = 1; /* use syslog for logging */ + char varvalue[1024]; + + + { + int optct = optionProcess(&ntpsnmpdOptions, argc, argv); + argc -= optct; + argv += optct; + } + + if (!HAVE_OPT(NOFORK)) + background = 1; + + if (!HAVE_OPT(SYSLOG)) + use_syslog = 0; + + /* using the net-snmp syslog facility */ + if (use_syslog) + snmp_enable_calllog(); + else + snmp_enable_stderrlog(); + + /* Become Subagent */ + netsnmp_ds_set_boolean(NETSNMP_DS_APPLICATION_ID, NETSNMP_DS_AGENT_ROLE, 1); + + /* go into background mode, if requested */ + if (background && netsnmp_daemonize(1, !use_syslog)) + exit(1); + + /* Now register with the master Agent X process */ + + /* call Netsnmp socket startup macro, which will initialize the network stuff if required */ + SOCK_STARTUP; + + /* Set AgentX socket interface */ + netsnmp_ds_set_string(NETSNMP_DS_APPLICATION_ID, + NETSNMP_DS_AGENT_X_SOCKET, OPT_ARG( AGENTXSOCKET )); + + init_agent("ntpsnmpd"); + + /* Try to connect to ntpd */ + if ( ntpq_openhost("localhost") == 0 ) + { + fprintf(stderr, "Error: Could not connect to ntpd. Aborting.\n"); + exit(1); + } + + + /* Register callback functions ... */ + init_ntpSnmpSubagentObject(); + init_snmp("ntpsnmpd"); + + /* Signal handler */ + keep_running = 1; + signal(SIGTERM, stop_server); + signal(SIGINT, stop_server); + + snmp_log(LOG_INFO,"ntpsnmpd started.\n"); + + /* main loop here... */ + while(keep_running) { + agent_check_and_process(1); /* 0 == don't block */ + } + + /* at shutdown time */ + ntpq_closehost(); + snmp_shutdown("ntpsnmpd"); + SOCK_CLEANUP; + + return 0; +} + diff -urN src/contrib/ntp/ntpsnmpd/ntpv4-mib.mib src.ntp/contrib/ntp/ntpsnmpd/ntpv4-mib.mib --- src/contrib/ntp/ntpsnmpd/ntpv4-mib.mib 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ntpsnmpd/ntpv4-mib.mib 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,1005 @@ +-- ********************************************************************* +-- +--$Id: draft-ietf-ntp-ntpv4-mib-05.xml 1.12 2007/11/28 00:00:00Z chelliot $ +--$Name: SUBMIT_1 $ +-- +-- The Network Time Protocol Version 4 +-- Management Information Base (MIB) +-- +-- Authors: Heiko Gerstung (heiko.gerstung@meinberg.de) +-- Chris Elliott (chelliot@cisco.com) +-- +-- for the Internet Engineering Task Force (IETF) +-- NTP Working Group (ntpwg) +-- +-- +-- ********************************************************************* +-- +-- $Log: draft-ietf-ntp-ntpv4-mib-05.xml $ +-- Revision 1.14 2008/08/29 00:00:00Z heiko +-- Re-submitted after expiration: +-- - The working group agreed to forward this draft in its current form (04), +-- but it expired before that could be done +-- Revision 1.13 2008/02/25 00:00:00Z chelliot +-- MIB: +-- - Added statistics table on a per-packet mode basis +-- (ntpEntStatPktModeTable) +-- Revision 1.12 2007/11/28 00:00:00Z chelliot +-- MIB: +-- - Added protocol statistics at the entity and association level +-- XML/RFC: +-- - Changed a couple of instances of "instance" to "entity" and "srv" +-- to "ent". +-- - Changed Meinberg address and Heiko's phone number. +-- Revision 1.11 2007/07/23 00:00:00Z chelliot +-- MIB: +-- - Modified Contact Info +-- - Added Stratum and NTP time TCs +-- - Changed ntpEntNotifNotInSync to ntpEntNotifCurrentMode and +-- deleted ntpEntNotifEntityStarted and ntpEntNotifEntityStopped +-- - Added compliance for SNTP entities +-- - Changed ntpTime to ntpDateTime +-- Revision 1.10 2007/07/09 00:00:00Z chelliot +-- XML/RFC: +-- - Changed RFC to Internet +-- - Changed service and service instance* to entity/entities +-- - Revised the Security Considerations to include read-write object +-- security considerations +-- - Added Chris Elliott as an author +-- - Fixed several lines to be 72 characters long or less +-- MIB: +-- - Changed "service" and "service instance" to "entity", +-- and Srv to Ent +-- - Changed status to mode +-- - Added association status object +-- - Added leap second objects +-- Revision 1.9 2007/03/04 06:59:44Z chelliot +-- MIB: +-- - Added time objects, comments, changed notifications +-- - Changed server to service +-- Revision 1.8 2006/10/23 03:37:44Z chelliot +-- MIB: +-- - Changed various object types, added notification control object +-- Revision 1.7 2006/06/16 07:13:50Z heiko +-- XML/RFC: +-- - Added/changed comments about the to-be-done IANA SMI assignment +-- Revision 1.6 2006/06/16 07:04:43Z heiko +-- RFC/XML: +-- - phone number corrected +-- - removed unused references +-- MIB: +-- - added ntpSrvTimePrecision +-- - changed INTEGER objects to Integer32 +-- - changed default value for ntpSrvStatusStratum from 99 to 16 +-- - changed default value for ntpSrvStatusActiveRefclockId from 99-0 +-- - changed object names to ntpSrvStatusActiveRefSourceName +-- (from ntpSrvStatusActiveRefclockName) and to +-- ntpSrvStatusNumberOfRefSources (from +-- ntpSrvStatusNumberOfRefclocks) +-- - removed ntpSrvStatusAuthKeyId object +-- - added ntpSrvStatusDispersion to provide the current root +-- dispersion +-- - major rework of section 3 (Status of associations) to compile +-- cleanly,including: +-- - added dispersion to the association dataset +-- - renaming of objects +-- - added an index to the association table +-- - formal changes +-- - traps are now reverse mappable +-- - traps are now define with payload where applicable +-- - added compliance statements +-- Revision 1.5 2006/02/27 08:28:16Z heiko +-- - changed to RFC format and added header as well as +-- introduction and technical description +-- - added other necessary RFC components (copyright statement etc.) +-- Revision 1.4 2006/02/27 07:06:49Z heiko +-- - removed all objects with data type REAL +-- - everything that needs to be floating point is now defined as +-- DisplayString +-- Revision 1.2 2006/01/23 08:58:11Z heiko +-- - changed the datatype of offset, jitter and delay objects from +-- Integer32 to REAL +-- +-- ********************************************************************* + +NTPv4-MIB DEFINITIONS ::= BEGIN + + +IMPORTS + MODULE-IDENTITY, OBJECT-TYPE , enterprises, mib-2, Integer32, NOTIFICATION-TYPE, + Unsigned32, Counter32 + FROM SNMPv2-SMI + MODULE-COMPLIANCE, OBJECT-GROUP, NOTIFICATION-GROUP + FROM SNMPv2-CONF + DisplayString, TEXTUAL-CONVENTION + FROM SNMPv2-TC + InetAddressType, InetAddress + FROM INET-ADDRESS-MIB; + +ntpSnmpMIB MODULE-IDENTITY + LAST-UPDATED "200802250000Z" -- February 25, 2008 + + ORGANIZATION "The IETF NTP Working Group (ntpwg)" + CONTACT-INFO + " WG Email: ntpwg@lists.ntp.isc.org + Subscribe: + https://lists.ntp.isc.org/mailman/listinfo/ntpwg + + Heiko Gerstung + Meinberg Funkuhren Gmbh & Co. KG + Lange Wand 9 + Bad Pyrmont 31812 + Germany + + Phone: +49 5281 9309 25 + Email: heiko.gerstung@meinberg.de + + Chris Elliott + Cisco Systems, Inc. + 7025 Kit Creek Rd., P.O. Box 14987 + Research Triangle Park 27709 + USA + + Phone: +1 919-392-2146 + Email: chelliot@cisco.com" + DESCRIPTION + "The Management Information Base for NTP time entities." + REVISION "200802250000Z" + DESCRIPTION + "Added ntpEntStatPktModeTable" + REVISION "200711280000Z" + DESCRIPTION + "Multiple proposed changes for IETF 70" + REVISION "200707230000Z" + DESCRIPTION + "Multiple proposed changes for IETF 69" + REVISION "200707090000Z" + DESCRIPTION + "Multiple changes from IETF 68" + REVISION "200703040000Z" + DESCRIPTION + "More MIB review modifications." + REVISION "200610230000Z" + DESCRIPTION + "Modifications from MIB review." + REVISION "200606190000Z" + DESCRIPTION + "First Draft Version" + REVISION "200512190000Z" + DESCRIPTION + "revised edition (added traps and stuff)" + REVISION "200511160000Z" + DESCRIPTION + "Initial draft" + ::= { enterprises 5597 99 } + + +ntpSnmpMIBObjects OBJECT IDENTIFIER ::= { ntpSnmpMIB 1 } + +-- MIB contains 6 groups + +ntpEntInfo OBJECT IDENTIFIER ::= { ntpSnmpMIBObjects 1 } +ntpEntStatus OBJECT IDENTIFIER ::= { ntpSnmpMIBObjects 2 } +ntpAssociation OBJECT IDENTIFIER ::= { ntpSnmpMIBObjects 3 } +ntpEntControl OBJECT IDENTIFIER ::= { ntpSnmpMIBObjects 4 } +ntpEntNotifObjects OBJECT IDENTIFIER ::= { ntpSnmpMIBObjects 5 } +ntpEntNotifPrefix OBJECT IDENTIFIER ::= { ntpSnmpMIBObjects 6 } + +-- +-- Textual Conventions +-- + +NtpStratum ::= TEXTUAL-CONVENTION + DISPLAY-HINT "d" + STATUS current + DESCRIPTION + "The NTP stratum, with 16 representing no stratum." + SYNTAX Unsigned32 (1..16) + +NtpDateTime ::= TEXTUAL-CONVENTION + DISPLAY-HINT "4d:4d:4d.4d" + STATUS current + DESCRIPTION + "NTP date/time on the device, in 128-bit + NTP date format. Ref: draft-ietf-ntp-ntpv4-proto-06, + section 6: + It includes a 64-bit signed seconds field + spanning 584 billion years and a 64-bit fraction + field resolving .05 attosecond (i.e. 0.5e-18). + For convenience in mapping between formats, the + seconds field is divided into a 32-bit era field + and a 32-bit timestamp field. + + If time is not syncronized this field shall be a + zero-length string. + + This TC is not to be used for objects that are used + to set the time of the node querying this object. + NTP should be used for this--or at least SNTP." + SYNTAX OCTET STRING (SIZE (0 | 16)) + +-- +-- Section 1: General NTP Entity information objects +-- (relatively static information) +-- + +ntpEntSoftwareName OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The product name of the installed NTP version." + -- the product name of the running ntp implementation, e.g. "ntpd" + ::= { ntpEntInfo 1 } + +ntpEntSoftwareVersion OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The software version of the installed NTP implementation." + -- full version string, e.g. "ntpd-4.2.0b@1.1433 ..." + ::= { ntpEntInfo 2 } + +ntpEntSoftwareVersionVal OBJECT-TYPE + SYNTAX Unsigned32 + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "Software version of installed NTP as an unsigned integer + value." + -- e.g. if version string is "4.2.0b" this could be translated into + -- 4202. This could be useful to find out if version of entity on a + -- is newer or older than version of the entity on b (without too + -- much string parsing trouble) + ::= { ntpEntInfo 3 } + +ntpEntSoftwareVendor OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The vendor/author of the installed NTP version." + ::= { ntpEntInfo 4 } + +ntpEntSystemType OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "General hardware/os platform information." + -- e.g. "Linux 2.6.12 / x86" + -- freely configurable, default is OS Version / Hardware platform + ::= { ntpEntInfo 5 } + +ntpEntTimeResolution OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "A string describing the time resolution of the running NTP + implementation." + -- e.g. "100 ns" + -- depends on the NTP implementation and the underlying OS. The + -- current resolution should be used, so if the OS only supports + -- 10ms and ntpd is capable of 1ns, the 10ms should be advertised + ::= { ntpEntInfo 6 } + +ntpEntTimeResolutionVal OBJECT-TYPE + SYNTAX Unsigned32 + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The time resolution in integer format." + -- ntpEntTimeResolution in Integer format + -- shows the resolution based on 1 second, e.g. "1ms" translates to + -- 1000 + ::= { ntpEntInfo 7 } + +ntpEntTimePrecision OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "A string describing the precision with which the NTP entity + implementation/OS manages its time base." + -- e.g. "-18" means 2^-18 = 0.000003814697265625 seconds + -- "-5" means 2^-5 = 0.03125 seconds + -- depends on the NTP implementation and the underlying OS. + ::= { ntpEntInfo 8 } + +ntpEntTimePrecisionVal OBJECT-TYPE + SYNTAX Integer32 + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The entity's precision in integer format." + -- ntpEntTimePrecision in signed Integer format + -- shows the precision. A value of -5 would mean 2^-5 = 31.25 ms + ::= { ntpEntInfo 9 } + +ntpEntTimeDistance OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The distance from this NTP entity to the root time reference + (stratum 0) source." + -- including the unit + -- e.g. "13.243 ms" + ::= { ntpEntInfo 10 } + +-- +-- Section 2: Current NTP status (dynamic information) +-- + +ntpEntStatusCurrentMode OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The actual mode of NTP as a string" + --- possible strings: + --- "not running" : NTP is not running + --- "not synchronized" : NTP is not synchronized to any time source + --- (stratum = 16) + --- "none configured" : NTP is not synchronized and does not have a + --- server configured + --- (stratum = 16) + --- "sync to local" : NTP is synchronized to own local clock + --- (degraded reliability) + --- "sync to refclock" : NTP is synchronized to a local hardware + --- refclock (e.g. GPS) + --- "sync to remote server" : NTP is synchronized to a remote NTP + --- server ("upstream" server) + --- "unknown" : The state of NTP is unknown. + ::= { ntpEntStatus 1 } + +ntpEntStatusCurrentModeVal OBJECT-TYPE + SYNTAX INTEGER { + notRunning(1), + notSynchronized(2), + noneConfigured(3), + syncToLocal(4), + syncToRefclock(5), + syncToRemoteServer(6), + unknown(99) + } + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The current mode of the NTP as integer value." + -- see ntpEntStatusCurrentMode + DEFVAL { 99 } + ::= { ntpEntStatus 2 } + +ntpEntStatusStratum OBJECT-TYPE + SYNTAX NtpStratum + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The NTP entity's own stratum value." + -- should be stratum of syspeer + 1 (or 16 if no syspeer) + DEFVAL { 16 } + ::= { ntpEntStatus 3 } + +ntpEntStatusActiveRefSourceId OBJECT-TYPE + SYNTAX Unsigned32 ( 0..99999 ) + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The association ID of the current syspeer." + DEFVAL { 0 } + ::= { ntpEntStatus 4 } + +ntpEntStatusActiveRefSourceName OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The hostname/descriptive name of the current reference source + selected as syspeer." + -- e.g. "ntp1.ptb.de" or "GPS" or "DCFi" ... + -- maybe something like "RefClk(8)"="hardware clock using driver 8" + -- would be nice + ::= { ntpEntStatus 5 } + +ntpEntStatusActiveOffset OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The Time offset to the current selected reference time source + as a string." + -- including unit, e.g. "0.032 ms" or "1.232 s" + ::= { ntpEntStatus 6 } + +ntpEntStatusNumberOfRefSources OBJECT-TYPE + SYNTAX Unsigned32 (0..99) + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The number of reference sources configured for NTP." + DEFVAL { 0 } + ::= { ntpEntStatus 7 } + +ntpEntStatusDispersion OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The root dispersion of the running NTP entity." + -- e.g. "6.927" + DEFVAL { "n/a" } + ::= { ntpEntStatus 8 } + +ntpEntStatusEntityUptime OBJECT-TYPE + SYNTAX Unsigned32 + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The uptime of the NTP entity in seconds." + -- time since ntpd was (re-)started (not sysUptime!) + DEFVAL { 0 } + ::= { ntpEntStatus 9 } + +ntpEntStatusDateTime OBJECT-TYPE + SYNTAX NtpDateTime + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The current NTP date/time on the device, in 128-bit + NTP date format. Ref: draft-ietf-ntp-ntpv4-proto-06, + section 6: + It includes a 64-bit signed seconds field + spanning 584 billion years and a 64-bit fraction + field resolving .05 attosecond (i.e. 0.5e-18). + For convenience in mapping between formats, the + seconds field is divided into a 32-bit era field + and a 32-bit timestamp field. + + If time is not syncronized this field shall be a + zero-length string. + + This object can be used to timestamp events on this + node and allow a management station to coorelate + different time objects. For example, a management + station could query this object and sysUpTime in + the same operation to be able to relate sysUpTime + to NTP time. + + This object is not to be used to set the time of + the node querying this object. NTP should be used + for this--or at least SNTP." + ::= { ntpEntStatus 10 } + +ntpEntStatusLeapSecond OBJECT-TYPE + SYNTAX Integer32 + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "Date the next known leap second will occur. If there is + no leap second announced then this object should be 0." + DEFVAL { 0 } + ::= { ntpEntStatus 11 } + +ntpEntStatusLeapSecDirection OBJECT-TYPE + SYNTAX Integer32 (-1..1) + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "Direction of next known leap second. If there is no + leap second announced then this object should be 0." + DEFVAL { 0 } + ::= { ntpEntStatus 12 } + +ntpEntStatusInPkts OBJECT-TYPE + SYNTAX Counter32 + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The total number of NTP messages delivered to the + NTP entity from the transport service." + ::= { ntpEntStatus 13 } + +ntpEntStatusOutPkts OBJECT-TYPE + SYNTAX Counter32 + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The total number of NTP messages delivered to the + transport service by this NTP entity." + ::= { ntpEntStatus 14 } + +ntpEntStatusBadVersion OBJECT-TYPE + SYNTAX Counter32 + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The total number of NTP messages which were delivered + to this NTP entity and were for an unsupported NTP + version." + ::= { ntpEntStatus 15 } + +ntpEntStatusProtocolError OBJECT-TYPE + SYNTAX Counter32 + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The total number of NTP messages which were delivered + to this NTP entity and this entity was not able to + process due to an NTP protocol error." + ::= { ntpEntStatus 16 } + +ntpEntStatusNotifications OBJECT-TYPE + SYNTAX Counter32 + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The total number of SNMP notifications which this NTP + entity has generated." + ::= { ntpEntStatus 17 } + +ntpEntStatPktModeTable OBJECT-TYPE + SYNTAX SEQUENCE OF NtpEntStatPktModeEntry + MAX-ACCESS not-accessible + STATUS current + DESCRIPTION + "The number of packets sent and received by packet mode." + ::= { ntpEntStatus 18 } + +ntpEntStatPktModeEntry OBJECT-TYPE + SYNTAX NtpEntStatPktModeEntry + MAX-ACCESS not-accessible + STATUS current + DESCRIPTION + "The number of packets sent and received by packet mode." + INDEX { ntpEntStatPktMode } + ::= { ntpEntStatPktModeTable 1 } + +NtpEntStatPktModeEntry ::= SEQUENCE { + ntpEntStatPktMode INTEGER, + ntpEntStatPktSent Counter32, + ntpEntStatPktReceived Counter32 +} + +ntpEntStatPktMode OBJECT-TYPE + SYNTAX INTEGER { + symetricactive(1), + symetricpassive(2), + client(3), + server(4), + broadcastserver(5), + broadcastclient(6) + } + MAX-ACCESS not-accessible + STATUS current + DESCRIPTION + "The NTP packet mode." + ::= { ntpEntStatPktModeEntry 1 } + +ntpEntStatPktSent OBJECT-TYPE + SYNTAX Counter32 + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The number of NTP packets sent with this packet mode." + ::= { ntpEntStatPktModeEntry 2 } + +ntpEntStatPktReceived OBJECT-TYPE + SYNTAX Counter32 + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The number of NTP packets received with this packet mode." + ::= { ntpEntStatPktModeEntry 3 } + +-- +-- Section 3: The status of all currently mobilized associations +-- + +ntpAssociationTable OBJECT-TYPE + SYNTAX SEQUENCE OF NtpAssociationEntry + MAX-ACCESS not-accessible + STATUS current + DESCRIPTION + "The table of currently mobilized associations." + ::= { ntpAssociation 1 } + +ntpAssociationEntry OBJECT-TYPE + SYNTAX NtpAssociationEntry + MAX-ACCESS not-accessible + STATUS current + DESCRIPTION + "The table entry of currently mobilized associations." + INDEX { ntpAssocId } + ::= { ntpAssociationTable 1 } + +NtpAssociationEntry ::= SEQUENCE { + ntpAssocId Unsigned32, + ntpAssocName DisplayString, + ntpAssocRefId DisplayString, + ntpAssocAddressType InetAddressType, + ntpAssocAddress InetAddress, + ntpAssocOffset DisplayString, + ntpAssocStratum NtpStratum, + ntpAssocStatusJitter DisplayString, + ntpAssocStatusDelay DisplayString, + ntpAssocStatusDispersion DisplayString +} + +ntpAssocId OBJECT-TYPE + SYNTAX Unsigned32 ( 1..99999 ) + MAX-ACCESS not-accessible + STATUS current + DESCRIPTION + "The association ID. This is an internal, unique ID." + ::= { ntpAssociationEntry 1 } + +ntpAssocName OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The hostname or other descriptive name for the association." + ::= { ntpAssociationEntry 2 } + +ntpAssocRefId OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The refclock driver ID, if available." + -- a refclock driver ID like "127.127.1.0" for non + -- uni/multi/broadcast associations + ::= { ntpAssociationEntry 3 } + +ntpAssocAddressType OBJECT-TYPE + SYNTAX InetAddressType + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The type of address of the association." + -- contains the type of address for uni/multi/broadcast associations + ::= { ntpAssociationEntry 4 } + +ntpAssocAddress OBJECT-TYPE + SYNTAX InetAddress + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The IP address (IPv4 or IPv6) of the association." + -- contains IP address of uni/multi/broadcast associations + ::= { ntpAssociationEntry 5 } + +ntpAssocOffset OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The time offset to the association as a string." + -- including unit, e.g. "0.032 ms" or "1.232 s" + ::= { ntpAssociationEntry 6 } + +ntpAssocStratum OBJECT-TYPE + SYNTAX NtpStratum + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The association stratum value." + ::= { ntpAssociationEntry 7 } + +ntpAssocStatusJitter OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The jitter in miliseconds as a string." + ::= { ntpAssociationEntry 8 } + +ntpAssocStatusDelay OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The network delay in miliseconds as a string." + ::= { ntpAssociationEntry 9 } + +ntpAssocStatusDispersion OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The root dispersion of the association." + -- e.g. "6.927" + ::= { ntpAssociationEntry 10 } + +ntpAssociationStatisticsTable OBJECT-TYPE + SYNTAX SEQUENCE OF NtpAssociationStatisticsEntry + MAX-ACCESS not-accessible + STATUS current + DESCRIPTION + "The table of statistics for current associations." + ::= { ntpAssociation 2 } + +ntpAssociationStatisticsEntry OBJECT-TYPE + SYNTAX NtpAssociationStatisticsEntry + MAX-ACCESS not-accessible + STATUS current + DESCRIPTION + "The table entry of statistics for current associations." + INDEX { ntpAssocId } + ::= { ntpAssociationStatisticsTable 1 } + +NtpAssociationStatisticsEntry ::= SEQUENCE { + ntpAssocStatInPkts Counter32, + ntpAssocStatOutPkts Counter32, + ntpAssocStatProtocolError Counter32 +} + +ntpAssocStatInPkts OBJECT-TYPE + SYNTAX Counter32 + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The total number of NTP messages delivered to the + NTP entity from this association." + ::= { ntpAssociationStatisticsEntry 1 } + +ntpAssocStatOutPkts OBJECT-TYPE + SYNTAX Counter32 + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The total number of NTP messages delivered to the + transport service by this NTP entity for this + association." + ::= { ntpAssociationStatisticsEntry 2 } + +ntpAssocStatProtocolError OBJECT-TYPE + SYNTAX Counter32 + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The total number of NTP messages which were delivered + to this NTP entity from this association and this entity + was not able to process due to an NTP protocol error." + ::= { ntpAssociationStatisticsEntry 3 } + +-- +-- Section 4: Control objects +-- + +ntpEntHeartbeatInterval OBJECT-TYPE + SYNTAX Unsigned32 + MAX-ACCESS read-write + STATUS current + DESCRIPTION + "The interval at which the ntpEntNotifHeartbeat notification + should be sent, in seconds. If set to 0 and the + entNotifHeartbeat bit in ntpEntNotifBits is 1 then + ntpEntNotifHeartbeat is sent once." + DEFVAL { 60 } + ::= { ntpEntControl 1 } + +ntpEntNotifBits OBJECT-TYPE + SYNTAX BITS { + notUsed(0), -- Used to sync up bit and notification + -- indices + entNotifModeChange(1), + entNotifStratumChange(2), + entNotifSyspeerChanged(3), + entNotifAddAssociation(4), + entNotifRemoveAssociation(5), + entNotifConfigChanged(6), + entNotifLeapSecondAnnounced(7), + entNotifHeartbeat(8) + } + MAX-ACCESS read-write + STATUS current + DESCRIPTION + "A bit for each notification. A 1 for a particular bit enables + that particular notification, a 0 disables it." + ::= { ntpEntControl 2 } + +-- +-- Section 5: Notification objects +-- + +ntpEntNotifMessage OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS accessible-for-notify + STATUS current + DESCRIPTION + "Used as a payload object for all notifications. Holds a clear + text event message." + DEFVAL { "no event" } + ::= { ntpEntNotifObjects 1 } + +-- +-- SNMP notification definitions +-- + +ntpEntNotifications OBJECT IDENTIFIER ::= { ntpEntNotifPrefix 0 } + +ntpEntNotifModeChange NOTIFICATION-TYPE + OBJECTS { ntpEntStatusCurrentModeVal } + STATUS current + DESCRIPTION + "The notification to be sent when the NTP entity changes mode, + including starting and stopping (if possible)" + ::= { ntpEntNotifications 1 } + +ntpEntNotifStratumChange NOTIFICATION-TYPE + OBJECTS { ntpEntStatusDateTime, ntpEntStatusStratum, + ntpEntNotifMessage } + STATUS current + DESCRIPTION + "The notification to be sent when stratum level of NTP changes." + ::= { ntpEntNotifications 2 } + +ntpEntNotifSyspeerChanged NOTIFICATION-TYPE + OBJECTS { ntpEntStatusDateTime, ntpEntStatusActiveRefSourceId, + ntpEntNotifMessage } + STATUS current + DESCRIPTION + "The notification to be sent when a (new) syspeer has been + selected." + ::= { ntpEntNotifications 3 } + +ntpEntNotifAddAssociation NOTIFICATION-TYPE + OBJECTS { ntpEntStatusDateTime, ntpAssocName, ntpEntNotifMessage } + STATUS current + DESCRIPTION + "The notification to be sent when a new association is + mobilized." + ::= { ntpEntNotifications 4 } + +ntpEntNotifRemoveAssociation NOTIFICATION-TYPE + OBJECTS { ntpEntStatusDateTime, ntpAssocName, ntpEntNotifMessage } + STATUS current + DESCRIPTION + "The notification to be sent when an association is + demobilized." + ::= { ntpEntNotifications 5 } + +ntpEntNotifConfigChanged NOTIFICATION-TYPE + OBJECTS { ntpEntStatusDateTime, ntpEntNotifMessage } + STATUS current + DESCRIPTION + "The notification to be sent when the NTP configuration has + changed." + -- e.g. when the system connected to the internet and was assigned + -- a new IP address by the ISPs DHCP server + ::= { ntpEntNotifications 6 } + +ntpEntNotifLeapSecondAnnounced NOTIFICATION-TYPE + OBJECTS { ntpEntStatusDateTime, ntpEntNotifMessage } + STATUS current + DESCRIPTION + "The notification to be sent when a leap second has been + announced." + ::= { ntpEntNotifications 7 } + +ntpEntNotifHeartbeat NOTIFICATION-TYPE + OBJECTS { ntpEntStatusDateTime, ntpEntStatusCurrentModeVal, + ntpEntHeartbeatInterval, ntpEntNotifMessage } + STATUS current + DESCRIPTION + "The notification to be sent periodically (as defined by + ntpEntHeartbeatInterval) to indicate that the NTP entity is + still alive." + ::= { ntpEntNotifications 8 } + +-- +-- Conformance/Compliance statements +-- + +ntpEntConformance OBJECT IDENTIFIER ::= { ntpSnmpMIB 6 } + +ntpEntCompliances OBJECT IDENTIFIER ::= { ntpEntConformance 1 } +ntpEntGroups OBJECT IDENTIFIER ::= { ntpEntConformance 2 } + +ntpEntNTPCompliance MODULE-COMPLIANCE + STATUS current + DESCRIPTION + "The compliance statement for SNMP entities which use NTP and + implement the NTP MIB" + MODULE -- this module + MANDATORY-GROUPS { + ntpEntObjectsGroup1, + ntpEntObjectsGroup2, + ntpEntNotifPrefixGroup + } + ::= { ntpEntCompliances 1 } + +ntpEntSNTPCompliance MODULE-COMPLIANCE + STATUS current + DESCRIPTION + "The compliance statement for SNMP entities which use SNTP and + implement the NTP MIB" + MODULE -- this module + MANDATORY-GROUPS { + ntpEntObjectsGroup1 + } + ::= { ntpEntCompliances 2 } + +ntpEntObjectsGroup1 OBJECT-GROUP + OBJECTS { + ntpEntSoftwareName, + ntpEntSoftwareVersion, + ntpEntSoftwareVersionVal, + ntpEntSoftwareVendor, + ntpEntSystemType, + ntpEntStatusEntityUptime, + ntpEntStatusDateTime, + ntpAssocName, + ntpAssocRefId, + ntpAssocAddressType, + ntpAssocAddress + } + STATUS current + DESCRIPTION + "A collection of objects for the NTP MIB that all NTP + or SNTP entities should implement." + ::= { ntpEntGroups 1 } + +ntpEntObjectsGroup2 OBJECT-GROUP + OBJECTS { + ntpEntTimeResolution, + ntpEntTimeResolutionVal, + ntpEntTimePrecision, + ntpEntTimePrecisionVal, + ntpEntTimeDistance, + ntpEntStatusCurrentMode, + ntpEntStatusCurrentModeVal, + ntpEntStatusStratum, + ntpEntStatusActiveRefSourceId, + ntpEntStatusActiveRefSourceName, + ntpEntStatusActiveOffset, + ntpEntStatusNumberOfRefSources, + ntpEntStatusDispersion, + ntpEntStatusLeapSecond, + ntpEntStatusLeapSecDirection, + ntpEntStatusInPkts, + ntpEntStatusOutPkts, + ntpEntStatusBadVersion, + ntpEntStatusProtocolError, + ntpEntStatusNotifications, + ntpEntStatPktSent, + ntpEntStatPktReceived, + ntpAssocOffset, + ntpAssocStratum, + ntpAssocStatusJitter, + ntpAssocStatusDelay, + ntpAssocStatusDispersion, + ntpAssocStatInPkts, + ntpAssocStatOutPkts, + ntpAssocStatProtocolError, + ntpEntHeartbeatInterval, + ntpEntNotifBits, + ntpEntNotifMessage + } + STATUS current + DESCRIPTION + "A collection of objects for the NTP MIB that are optional + for NTP or SNTP entities to implement." + ::= { ntpEntGroups 2 } + +ntpEntNotifPrefixGroup NOTIFICATION-GROUP + NOTIFICATIONS { + ntpEntNotifModeChange, + ntpEntNotifStratumChange, + ntpEntNotifSyspeerChanged, + ntpEntNotifAddAssociation, + ntpEntNotifRemoveAssociation, + ntpEntNotifConfigChanged, + ntpEntNotifLeapSecondAnnounced, + ntpEntNotifHeartbeat + } + STATUS current + DESCRIPTION + "A collection of notifications for the NTP MIB" + ::= { ntpEntGroups 3 } + +END diff -urN src/contrib/ntp/packageinfo.sh src.ntp/contrib/ntp/packageinfo.sh --- src/contrib/ntp/packageinfo.sh 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/packageinfo.sh 2010-07-09 04:21:13.000000000 +0200 @@ -1,31 +1,94 @@ +# +# packageinfo.sh - set shell variables with version components +# +# This file is sourced by other scripts and does not need execute +# permission or the #! shell selector. +# +# Most changes to this file are fully or semi-automated using the +# UpdatePoint script on the ntp.org tarball build machine. Changes +# required by the typical ntp.org release sequences are below. +# +## DEV: +# +# To bump the -dev point (p) number, UpdatePoint needs no changes here. +# +# To start a -RC cycle in -dev leading to the next -stable release, +# set prerelease=rc. +# +# To move from dev -RC to new -stable and -dev major/minor version, set +# minor and/or major to the new version, repotype to match the new +# minor version, empty prerelease, and set point=NEW. UpdatePoint +# will empty point and rcpoint, and set betapoint=0. +# +## STABLE: +# +# To start a -stable beta cycle, which normally occurs before a -stable +# -RC1 during the runup to a -stable point release, UpdatePoint needs +# no changes here. Both betapoint and point will be incremented, and +# prerelease will be set to beta. +# +# To move on from -stable beta to RC set prerelease=rc. +# +# To fall back from -stable RC to beta set prerelease=beta. +# +# To skip over -stable beta1 directly to -RC1, set prerelease=rc. +# +# To skip all -stable prereleases and move from one primary or point +# release directly to the next point release, set rcpoint=GO. +# +## +# +# To see what UpdatePoint will do without modifying packageinfo.sh as it +# does by default, use the -t/--test option before the repo type: +# +# shell# scripts/UpdatePoint -t stable +# + +# repotype must be stable or dev repotype=stable + # version=Protocol.Major.Minor # odd minor numbers are for -dev, even minor numbers are for -stable +# UpdatePoint will fail if repotype is inconsistent with minor. proto=4 major=2 -minor=4 +minor=6 version=${proto}.${major}.${minor} -# Point. 3 cases: -# - Numeric values increment -# - empty 'increments' to 1 -# - NEW 'increments' to empty -point=8 + # Special. Normally unused. A suffix. #special=ag special= -# [???] To start an RC cycle: RC->yes -# To release from an RC cycle: rcpoint-> GO -# ReleaseCandidate. 'yes' or 'no'. -#releasecandidate=yes -releasecandidate=no -# ChangeLog tag + +# prerelease can be empty, 'beta', or 'rc'. +prerelease= + +# ChangeLog starting tag (see also CommitLog-4.1.0) CLTAG=NTP_4_2_0 -### -# The following is for ntp-stable. 2 cases: + +### Point number, after "p", normally modified by script. +# 3 cases: +# - Numeric values increment +# - empty 'increments' to 1 +# - NEW 'increments' to empty +point=2 + +### betapoint is normally modified by script. +# ntp-stable Beta number (betapoint) +# Should be zeroed at release, and left at zero until first beta. +# The first beta is -beta1. +# betapoint is always zero in ntp-dev. +betapoint=0 + +### rcpoint is normally modified by script except for GO. +# RC number (rcpoint) +# for ntp-dev, always empty as RC numbers are not used, nor is GO. +# For ntp-stable: +# if prerelease is 'rc': # - Numeric values increment -# - GO triggers a release (from releasecandidate=yes) -# - - rcpoint gets set to 0 -# - - releasecandidate gets set to no -# - GRONK is for -dev +# - GO triggers a release +# - - rcpoint is emptied +# - - betapoint is set to 0 +# - - prerelease is emptied +# else (not in RC) +# - rcpoint is empty and unused (for now). rcpoint= -#rcpoint=GRONK diff -urN src/contrib/ntp/parseutil/Makefile.am src.ntp/contrib/ntp/parseutil/Makefile.am --- src/contrib/ntp/parseutil/Makefile.am 2004-07-20 17:01:44.000000000 +0200 +++ src.ntp/contrib/ntp/parseutil/Makefile.am 2009-12-09 08:36:35.000000000 +0100 @@ -1,8 +1,15 @@ +NULL= #AUTOMAKE_OPTIONS = ../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr +AUTOMAKE_OPTIONS = +BUILT_SOURCES = +CLEANFILES = noinst_PROGRAMS = @TESTDCF@ @DCFD@ EXTRA_PROGRAMS = testdcf dcfd -INCLUDES = -I$(top_srcdir)/include + +INCLUDES = -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/nothreads/include \ + -I$(top_srcdir)/lib/isc/unix/include + ETAGS_ARGS = Makefile.am DISTCLEANFILES = $(EXTRA_PROGRAMS) #EXTRA_DIST= TAGS @@ -11,3 +18,5 @@ case "$(noinst_PROGRAMS)" in \ *dcfd*) ./dcfd -Y ;; \ esac + +include $(top_srcdir)/depsver.mf diff -urN src/contrib/ntp/parseutil/Makefile.in src.ntp/contrib/ntp/parseutil/Makefile.in --- src/contrib/ntp/parseutil/Makefile.in 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/parseutil/Makefile.in 2010-07-09 04:21:35.000000000 +0200 @@ -34,14 +34,18 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -ANSI2KNR = ../util/ansi2knr EXTRA_PROGRAMS = testdcf$(EXEEXT) dcfd$(EXEEXT) +DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ + $(top_srcdir)/depsver.mf subdir = parseutil -DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ + $(top_srcdir)/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/m4/ntp_openssl.m4 \ + $(top_srcdir)/m4/ntp_vpathhack.m4 \ $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ @@ -52,10 +56,10 @@ CONFIG_CLEAN_VPATH_FILES = PROGRAMS = $(noinst_PROGRAMS) dcfd_SOURCES = dcfd.c -dcfd_OBJECTS = dcfd$U.$(OBJEXT) +dcfd_OBJECTS = dcfd.$(OBJEXT) dcfd_LDADD = $(LDADD) testdcf_SOURCES = testdcf.c -testdcf_OBJECTS = testdcf$U.$(OBJEXT) +testdcf_OBJECTS = testdcf.$(OBJEXT) testdcf_LDADD = $(LDADD) DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) depcomp = $(SHELL) $(top_srcdir)/depcomp @@ -78,7 +82,6 @@ ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -99,6 +102,7 @@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EF_LIBS = @EF_LIBS@ EF_PROGS = @EF_PROGS@ EGREP = @EGREP@ @@ -130,6 +134,7 @@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ @@ -146,18 +151,22 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ PATH_SEPARATOR = @PATH_SEPARATOR@ PATH_SH = @PATH_SH@ PROPDELAY = @PROPDELAY@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ VERSION = @VERSION@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ @@ -209,18 +218,24 @@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ - +NULL = #AUTOMAKE_OPTIONS = ../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr +AUTOMAKE_OPTIONS = +BUILT_SOURCES = .deps-ver +CLEANFILES = .deps-ver noinst_PROGRAMS = @TESTDCF@ @DCFD@ -INCLUDES = -I$(top_srcdir)/include +INCLUDES = -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/nothreads/include \ + -I$(top_srcdir)/lib/isc/unix/include + ETAGS_ARGS = Makefile.am DISTCLEANFILES = $(EXTRA_PROGRAMS) -all: all-am +all: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/depsver.mf $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -271,14 +286,9 @@ distclean-compile: -rm -f *.tab.c -../util/ansi2knr: - $(am__cd) ../util && $(MAKE) $(AM_MAKEFLAGS) ./ansi2knr - -mostlyclean-kr: - -test "$U" = "" || rm -f *_.c -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dcfd$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/testdcf$U.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dcfd.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/testdcf.Po@am__quote@ .c.o: @am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @@ -300,11 +310,6 @@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< -dcfd_.c: dcfd.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/dcfd.c; then echo $(srcdir)/dcfd.c; else echo dcfd.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -testdcf_.c: testdcf.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/testdcf.c; then echo $(srcdir)/testdcf.c; else echo testdcf.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -dcfd_.$(OBJEXT) dcfd_.lo testdcf_.$(OBJEXT) testdcf_.lo : $(ANSI2KNR) mostlyclean-libtool: -rm -f *.lo @@ -396,10 +401,12 @@ done check-am: all-am $(MAKE) $(AM_MAKEFLAGS) check-local -check: check-am +check: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) check-am all-am: Makefile $(PROGRAMS) installdirs: -install: install-am +install: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am @@ -416,6 +423,7 @@ mostlyclean-generic: clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) @@ -425,6 +433,7 @@ maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." + -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-am clean-am: clean-generic clean-libtool clean-noinstPROGRAMS \ @@ -483,7 +492,7 @@ mostlyclean: mostlyclean-am -mostlyclean-am: mostlyclean-compile mostlyclean-generic mostlyclean-kr \ +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am @@ -496,7 +505,7 @@ uninstall-am: -.MAKE: ../util/ansi2knr check-am install-am install-strip +.MAKE: all check check-am install install-am install-strip .PHONY: CTAGS GTAGS all all-am check check-am check-local clean \ clean-generic clean-libtool clean-noinstPROGRAMS ctags \ @@ -509,8 +518,8 @@ install-ps install-ps-am install-strip installcheck \ installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-compile \ - mostlyclean-generic mostlyclean-kr mostlyclean-libtool pdf \ - pdf-am ps ps-am tags uninstall uninstall-am + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags uninstall uninstall-am #EXTRA_DIST= TAGS @@ -518,6 +527,70 @@ case "$(noinst_PROGRAMS)" in \ *dcfd*) ./dcfd -Y ;; \ esac +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + ..) \ + cd .. && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + *) \ + echo 'Fatal: depsver.mf Automake fragment limited' \ + 'to immediate subdirectories.' && \ + echo "top_builddir: $(top_builddir)" && \ + echo "subdir: $(subdir)" && \ + exit 1 \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff -urN src/contrib/ntp/parseutil/dcfd.c src.ntp/contrib/ntp/parseutil/dcfd.c --- src/contrib/ntp/parseutil/dcfd.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/parseutil/dcfd.c 2009-12-09 08:36:35.000000000 +0100 @@ -185,7 +185,7 @@ #define R_SHIFT(_X_, _Y_) (((_X_) < 0) ? -(-(_X_) >> (_Y_)) : ((_X_) >> (_Y_))) -static struct timeval max_adj_offset = { 0, 128000 }; +static long max_adj_offset_usec = 128000; static long clock_adjust = 0; /* current adjustment value (usec * 2^USECSCALE) */ static long accum_drift = 0; /* accumulated drift value (usec / ADJINTERVAL) */ @@ -195,8 +195,8 @@ /* * DCF77 state flags */ -#define DCFB_ANNOUNCE 0x0001 /* switch time zone warning (DST switch) */ -#define DCFB_DST 0x0002 /* DST in effect */ +#define DCFB_ANNOUNCE 0x0001 /* switch time zone warning (DST switch) */ +#define DCFB_DST 0x0002 /* DST in effect */ #define DCFB_LEAP 0x0004 /* LEAP warning (1 hour prior to occurrence) */ #define DCFB_ALTERNATE 0x0008 /* alternate antenna used */ @@ -1042,7 +1042,8 @@ toffset = *offset; toffset.tv_sec = l_abs(toffset.tv_sec); toffset.tv_usec = l_abs(toffset.tv_usec); - if (timercmp(&toffset, &max_adj_offset, >)) + if (toffset.tv_sec || + (!toffset.tv_sec && toffset.tv_usec > max_adj_offset_usec)) { /* * hopeless - set the clock - and clear the timing @@ -1609,7 +1610,7 @@ struct sigaction act; # ifdef HAVE_SA_SIGACTION_IN_STRUCT_SIGACTION - act.sa_sigaction = (void (*) P((int, siginfo_t *, void *)))0; + act.sa_sigaction = (void (*) (int, siginfo_t *, void *))0; # endif /* HAVE_SA_SIGACTION_IN_STRUCT_SIGACTION */ act.sa_handler = tick; sigemptyset(&act.sa_mask); diff -urN src/contrib/ntp/scripts/Makefile.am src.ntp/contrib/ntp/scripts/Makefile.am --- src/contrib/ntp/scripts/Makefile.am 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/scripts/Makefile.am 2009-12-22 11:01:33.000000000 +0100 @@ -1,5 +1,37 @@ -bin_SCRIPTS= ntp-wait ntptrace -noinst_SCRIPTS= calc_tickadj checktime freq_adj html2man mkver ntpsweep ntpver plot_summary summary -EXTRA_DIST = VersionName fixautomakedepsmagic genCommitLog genver \ - hpadjtime.sh monitoring ntp-close ntp-groper ntp-restart \ - ntp-status rc1 rc2 stats +NULL= + +if NTP_BINSUBDIR_IS_BIN +bin_SCRIPTS = ntp-wait ntptrace +else +sbin_SCRIPTS = ntp-wait ntptrace +endif + +noinst_SCRIPTS = \ + calc_tickadj \ + checktime \ + freq_adj \ + html2man \ + mkver \ + ntpsweep \ + ntpver \ + plot_summary \ + summary \ + $(NULL) + +EXTRA_DIST = \ + cvo.sh \ + fixautomakedepsmagic \ + genCommitLog \ + genver \ + hpadjtime.sh \ + monitoring \ + ntp-close \ + ntp-groper \ + ntp-restart \ + ntp-status \ + rc1 \ + rc2 \ + stats \ + UpdatePoint \ + VersionName \ + $(NULL) diff -urN src/contrib/ntp/scripts/Makefile.in src.ntp/contrib/ntp/scripts/Makefile.in --- src/contrib/ntp/scripts/Makefile.in 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/scripts/Makefile.in 2010-07-09 04:21:35.000000000 +0200 @@ -44,7 +44,11 @@ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ + $(top_srcdir)/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/m4/ntp_openssl.m4 \ + $(top_srcdir)/m4/ntp_vpathhack.m4 \ $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ @@ -75,15 +79,14 @@ am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' -am__installdirs = "$(DESTDIR)$(bindir)" -SCRIPTS = $(bin_SCRIPTS) $(noinst_SCRIPTS) +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(sbindir)" +SCRIPTS = $(bin_SCRIPTS) $(noinst_SCRIPTS) $(sbin_SCRIPTS) SOURCES = DIST_SOURCES = DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -104,6 +107,7 @@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EF_LIBS = @EF_LIBS@ EF_PROGS = @EF_PROGS@ EGREP = @EGREP@ @@ -135,6 +139,7 @@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ @@ -151,18 +156,22 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ PATH_SEPARATOR = @PATH_SEPARATOR@ PATH_SH = @PATH_SH@ PROPDELAY = @PROPDELAY@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ VERSION = @VERSION@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ @@ -214,11 +223,38 @@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -bin_SCRIPTS = ntp-wait ntptrace -noinst_SCRIPTS = calc_tickadj checktime freq_adj html2man mkver ntpsweep ntpver plot_summary summary -EXTRA_DIST = VersionName fixautomakedepsmagic genCommitLog genver \ - hpadjtime.sh monitoring ntp-close ntp-groper ntp-restart \ - ntp-status rc1 rc2 stats +NULL = +@NTP_BINSUBDIR_IS_BIN_TRUE@bin_SCRIPTS = ntp-wait ntptrace +@NTP_BINSUBDIR_IS_BIN_FALSE@sbin_SCRIPTS = ntp-wait ntptrace +noinst_SCRIPTS = \ + calc_tickadj \ + checktime \ + freq_adj \ + html2man \ + mkver \ + ntpsweep \ + ntpver \ + plot_summary \ + summary \ + $(NULL) + +EXTRA_DIST = \ + cvo.sh \ + fixautomakedepsmagic \ + genCommitLog \ + genver \ + hpadjtime.sh \ + monitoring \ + ntp-close \ + ntp-groper \ + ntp-restart \ + ntp-status \ + rc1 \ + rc2 \ + stats \ + UpdatePoint \ + VersionName \ + $(NULL) all: all-am @@ -309,6 +345,40 @@ test -n "$$list" || exit 0; \ echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \ cd "$(DESTDIR)$(bindir)" && rm -f $$files +install-sbinSCRIPTS: $(sbin_SCRIPTS) + @$(NORMAL_INSTALL) + test -z "$(sbindir)" || $(MKDIR_P) "$(DESTDIR)$(sbindir)" + @list='$(sbin_SCRIPTS)'; test -n "$(sbindir)" || list=; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + if test -f "$$d$$p"; then echo "$$d$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n' \ + -e 'h;s|.*|.|' \ + -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) { files[d] = files[d] " " $$1; \ + if (++n[d] == $(am__install_max)) { \ + print "f", d, files[d]; n[d] = 0; files[d] = "" } } \ + else { print "f", d "/" $$4, $$1 } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_SCRIPT) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ + $(INSTALL_SCRIPT) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-sbinSCRIPTS: + @$(NORMAL_UNINSTALL) + @list='$(sbin_SCRIPTS)'; test -n "$(sbindir)" || exit 0; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 's,.*/,,;$(transform)'`; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(sbindir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(sbindir)" && rm -f $$files mostlyclean-libtool: -rm -f *.lo @@ -356,7 +426,7 @@ check: check-am all-am: Makefile $(SCRIPTS) installdirs: - for dir in "$(DESTDIR)$(bindir)"; do \ + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(sbindir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: install-am @@ -410,7 +480,7 @@ install-dvi-am: -install-exec-am: install-binSCRIPTS +install-exec-am: install-binSCRIPTS install-sbinSCRIPTS install-html: install-html-am @@ -448,7 +518,7 @@ ps-am: -uninstall-am: uninstall-binSCRIPTS +uninstall-am: uninstall-binSCRIPTS uninstall-sbinSCRIPTS .MAKE: install-am install-strip @@ -459,10 +529,11 @@ install-dvi-am install-exec install-exec-am install-html \ install-html-am install-info install-info-am install-man \ install-pdf install-pdf-am install-ps install-ps-am \ - install-strip installcheck installcheck-am installdirs \ - maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - uninstall uninstall-am uninstall-binSCRIPTS + install-sbinSCRIPTS install-strip installcheck installcheck-am \ + installdirs maintainer-clean maintainer-clean-generic \ + mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ + ps ps-am uninstall uninstall-am uninstall-binSCRIPTS \ + uninstall-sbinSCRIPTS # Tell versions [3.59,3.63) of GNU make to not export all variables. diff -urN src/contrib/ntp/scripts/UpdatePoint src.ntp/contrib/ntp/scripts/UpdatePoint --- src/contrib/ntp/scripts/UpdatePoint 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/scripts/UpdatePoint 2009-12-22 11:01:34.000000000 +0100 @@ -0,0 +1,331 @@ +#! /bin/sh + +# showusage is set to 1 on any command-line syntax error +showusage=0 +# are we playing by stable or dev rules? +repo= +# test is set to 1 if -t/--test is given to prevent modifications +test=0 + +case "$#" in + 1) repo=$1 + ;; + 2) repo=$2 + case $1 in + -t|--test) + test=1 + ;; + *) + showusage=1 + ;; + esac + ;; + *) showusage=1 + ;; +esac + +case "$repo" in + dev|stable) + ;; + '') + showusage=1 + ;; + *) echo "Unexpected repo type: <$repo>!" + showusage=1 + ;; +esac + +case "$showusage" in + 1) echo "Usage: $0 [-t] " + echo "No changes are made to packageinfo.sh if -t is given." + exit 1 + ;; +esac + + +set -e + +. ./packageinfo.sh + +case "$repotype" in + $repo) + ;; + *) echo "You indicated repo type <$repo> but packageinfo.sh" + echo "indicates <$repotype>." + exit 1 + ;; +esac + +ver_repo_mismatch=1 + +case "$minor" in + 1|3|5|7|9) + case "$repo" in + dev) + ver_repo_mismatch=0 + ;; + stable) + ;; + esac + ;; + 0|2|4|6|8) + case "$repo" in + dev) + ;; + stable) + ver_repo_mismatch=0 + ;; + esac + ;; +esac + +case "$ver_repo_mismatch" in + 1) echo "Minor version <$minor> mismatches repotype <$repo>." + exit 1 + ;; +esac + +# Do we want to bump the point? +bp=1 +# Do we want to bump the beta point? +bbp=0 +# Do we want to change the RC point? (n=no, z=empty rcpoint and zero +# betapoint, i=incr) +crcp=n +# Do we want to change the prerelease value? +setpr=0 + +# for stable: +# if we are not in a beta or RC state, enter beta unless point is NEW. +# if we are in a beta state: +# - bump the beta point +# else if we are in an RC state: +# - if rcpoint is GO: +# - - set rcpoint= (empty) +# - - set prerelease= (empty) +# - - set betapoint=0 +# - else +# - - if rcpoint==(empty) +# - - - (bump-point) and set rcpoint to 0 (and fall thru, so -RC1 is first) +# - - bump the RC point + +# for dev, we only want to bump-point and possibly clear prerelease, +# but we do not modify rcpoint nor betapoint. + +case "$repo" in + dev) + case "$point" in + [Nn][Ee][Ww]) + crcp=z + ;; + *) + # crcp=n + ;; + esac + # bp=1 + ;; + stable) + case "$prerelease" in + '') + case "$betapoint::$rcpoint::$point" in + *::*::NEW) + # new minor release (no p) + crcp=z + # bp=1 + ;; + 0::::*) + # start of first beta cycle for the next point release + setpr=1 + newpr=beta + # bp=1 + bbp=1 + ;; + 0::[Gg][Oo]::*) + # skip all -beta and -RC prereleases to the next point. + crcp=z + setpr=1 + newpr= + # bp=1 + # bbp=0 + ;; + *) echo "betapoint is <$betapoint>, rcpoint is <$rcpoint>" + echo "betapoint must be 0 and rcpoint must be empty to start the" + echo "beta cycle." + exit 1 + ;; + esac + ;; + beta) + case "$betapoint::$rcpoint" in + [1-9]*::*) + bp=0 + bbp=1 + ;; + 0::) echo "betapoint is 0, rcpoint emtpy, and prerelease is beta." + echo "You probably intended prerelease= (that is, empty). It" + echo "will then be changed to beta by this script, starting the" + echo "first beta for the next point release." + exit 1 + ;; + *) + bp=0 + bbp=1 + ;; + esac + case "$rcpoint" in + [Gg][Oo]) + echo "prerelease is beta, rcpoint is GO, disallowed." + echo "rcpoint GO is allowed only when prerelease is RC or empty." + exit 1 + ;; + esac + ;; + rc|RC) + case "$rcpoint" in + '') + case "$betapoint" in + 0) # bp=1 + ;; + *) bp=0 + ;; + esac + crcp=i + ;; + [1-9]*) + bp=0 + crcp=i + ;; + [Gg][Oo]) + bp=0 + crcp=z + setpr=1 + newpr= + ;; + *) echo "Unexpected value for 'rcpoint' <$rcpoint>!" + exit 1 + ;; + esac + ;; + *) + echo "prerelease <$prerelease> unexpected" + exit 1 + ;; + esac + ;; + *) echo "impossible: repo <$repo>!" + exit 1 + ;; +esac + +case "$bp::$point" in + 0::*) + newpoint=$point + ;; + 1::[1-9]*) + newpoint=`expr $point + 1` + ;; + 1::) + newpoint=1 + ;; + 1::[Nn][Ee][Ww]) + newpoint= + ;; + *) echo "Unexpected value for 'point' <$point>!" + exit 1 + ;; +esac + +case "$bbp::$betapoint" in + 0::*) + newbetapoint=$betapoint + ;; + 1::[0-9]*) + newbetapoint=`expr $betapoint + 1` + ;; + *) echo "Unexpected value for 'betapoint' <$betapoint>!" + exit 1 + ;; +esac + +case "$crcp::$rcpoint" in + n::*) + newrcpoint=$rcpoint + ;; + i::) + newrcpoint=1 + ;; + i::[0-9]*) + newrcpoint=`expr $rcpoint + 1` + ;; + z::*) + newrcpoint= + newbetapoint=0 + ;; + *) echo "Unexpected value for 'crcp::rcpoint' <$crcp::$rcpoint>!" + exit 1 + ;; +esac + +case "$setpr" in + 0) + newpr=$prerelease +esac + +# display results +printf "prerelease $prerelease" +case "$newpr" in + $prerelease) + printf "\n" + ;; + *) printf " -> $newpr\n" + ;; +esac +printf "point $point" +case "$newpoint" in + $point) + printf "\n" + ;; + *) printf " -> $newpoint\n" + ;; +esac +printf "betapoint $betapoint" +case "$newbetapoint" in + $betapoint) + printf "\n" + ;; + *) printf " -> $newbetapoint\n" + ;; +esac +printf "rcpoint $rcpoint" +case "$newrcpoint" in + $rcpoint) + printf "\n" + ;; + *) printf " -> $newrcpoint\n" + ;; +esac + +printf "Previous version: " +scripts/VersionName + +# apply packageinfo.sh changes + +sed -e "s/^point=.*/point=$newpoint/" \ + -e "s/^betapoint=.*/betapoint=$newbetapoint/" \ + -e "s/^rcpoint=.*/rcpoint=$newrcpoint/" \ + -e "s/^prerelease=.*/prerelease=$newpr/" \ + < packageinfo.sh \ + > packageinfo.sh+ + +case "$test" in + 0) + mv packageinfo.sh+ packageinfo.sh + printf "Updated version: " + scripts/VersionName + ;; + *) + printf "Next version would be: " + scripts/VersionName -p ./packageinfo.sh+ + rm packageinfo.sh+ + ;; +esac diff -urN src/contrib/ntp/scripts/VersionName src.ntp/contrib/ntp/scripts/VersionName --- src/contrib/ntp/scripts/VersionName 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/scripts/VersionName 2009-12-22 11:01:35.000000000 +0100 @@ -1,12 +1,27 @@ #! /bin/sh +packageinfo='./packageinfo.sh' +case "$#" in + 2) + case "$1" in + -p|--packageinfo) + packageinfo="$2" + esac + ;; + 0) + ;; + *) echo "Usage: $0 [-p packageinfo.sh]" + exit 1 + ;; +esac + # This script must be executed from the TLD of the source tree... -. ./packageinfo.sh +. "$packageinfo" NAME="$version" case $point in - [0-9]*) - NAME="${NAME}p$point" + [1-9]*) + NAME="${NAME}p${point}" ;; NEW) ;; '') ;; @@ -17,24 +32,23 @@ case $special in '') ;; - *) NAME="${NAME}-$special" ;; + *) NAME="${NAME}-${special}" ;; esac -case $releasecandidate in - [Nn][Oo]) ;; - [Yy][Ee][Ss]) NAME="${NAME}-RC" ;; - *) echo "Unexpected value for 'releasecandidate' <$releasecandidate>!" - exit 1 +case "$prerelease::$repotype" in + ''::*) ;; -esac - -case $repotype in - stable) - case $rcpoint in - [0-9]*) - NAME="${NAME}$rcpoint" - ;; - esac + beta::stable) + NAME="${NAME}-beta${betapoint}" + ;; + rc::dev|RC::dev) + NAME="${NAME}-RC" + ;; + rc::stable|RC::stable) + NAME="${NAME}-RC${rcpoint}" + ;; + *) echo "Unexpected value for 'prerelease::repotype' <$prerelease::$repotype>!" + exit 1 ;; esac diff -urN src/contrib/ntp/scripts/cvo.sh src.ntp/contrib/ntp/scripts/cvo.sh --- src/contrib/ntp/scripts/cvo.sh 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/scripts/cvo.sh 2009-12-09 08:36:37.000000000 +0100 @@ -0,0 +1,149 @@ +#! /bin/sh + +# Copyright 2002, 2009, Harlan Stenn. Used by NTP with permission. +# Author: Harlan Stenn + +# Possible output formats: +# +# CVO=... Shell variable +# CVO=... ; export CVO Old-style exported envariable +# export CVO=... New-style exported envariable +# setenv CVO ... csh-style exported envariable + +TS="$*" + +CVO_raw=`config.guess` +CVO=$CVO_raw + +set 1 `echo $CVO | tr '-' ' '` +shift + +case "$#" in + 4) # eg: i686-pc-linux-gnu + CVO_CPU=$1 + CVO_VENDOR=$2 + cvo_KERN=$3 # Note the capitalization... + CVO_OS=$4 + case "$cvo_KERN" in + linux) # Braindamage. We want OS, not kernel info + if false + then + : + elif test -f /etc/debian_version + then + set `cat /etc/debian_version` + CVO_OS=debian$1 + CVO_KOSVER=`uname -r` + elif test -f /etc/mandrake-release + then + set `cat /etc/mandrake-release` + CVO_OS=mandrake$4 + CVO_KOSVER=`uname -r` + elif test -f /etc/redhat-release + then + set `cat /etc/redhat-release` + case "$1" in + CentOS) + CVO_OS=centos$3 + ;; + Fedora) + CVO_OS=fedora$3 + ;; + *) + case "$3" in + Enterprise) + CVO_OS=redhat$7.E + ;; + Linux) + CVO_OS=redhat$5 + ;; + esac + ;; + esac + CVO_KOSVER=`uname -r` + elif test -f /etc/slackware-version + then + set `cat /etc/slackware-version` + CVO_OS=slackware$2 + CVO_KOSVER=`uname -r` + elif test -f /etc/SuSE-release + then + set `cat /etc/SuSE-release` + CVO_OS=suse$9 + CVO_KOSVER=`uname -r` + else + CVO_OS=$cvo_KERN`uname -r` + + fi + ;; + nto) # QNX + CVO_KOSVER=`uname -r` + ;; + *) + echo "gronk - I don't understand <$CVO>!" + exit 1 + ;; + esac + ;; + 3) CVO_CPU=$1 + CVO_VENDOR=$2 + CVO_OS=$3 + ;; + *) echo "gronk - config.guess returned $# pieces, not 3 pieces!" + exit 1 + ;; +esac + +case "$CVO_OS" in + cygwin) + # Decisions, decisions. + # uname -r is the cygwin version #, eg: 1.3.3(0.46/3/2) + # uname -s returns something like CYGWIN_NT-5.0 + CVO_OS="$CVO_OS`uname -r | sed 's/(.*//'`" + ;; +esac +set `echo $CVO_OS | sed 's/\([0-9]\)/ \1/'` + +case "$#" in + 2) ;; + *) echo "gronk - <$CVO_OS> expanded to $#, not 2 pieces!" + exit 1 + ;; +esac + +CVO_OSNAME=$1 +CVO_OSVER=$2 + +case "$CVO_OSNAME" in + solaris) + CVO_KOSVER=`uname -v` + ;; +esac + +CVO=$CVO_CPU-$CVO_VENDOR-$CVO_OS + +case "$TS" in + '') + set | grep CVO + ;; + *) + # keys['cvo'] = "cvo.CVO['CVO']" + TS=`echo $TS | sed -e s/@cvo@/$CVO/g` + # keys['cpu'] = "cvo.CVO['CVO_CPU']" + TS=`echo $TS | sed -e s/@cpu@/$CVO_CPU/g` + # keys['kosver'] = "cvo.CVO['CVO_KOSVER']" + TS=`echo $TS | sed -e s/@kosver@/$CVO_KOSVER/g` + # keys['os'] = "cvo.CVO['CVO_OS']" + TS=`echo $TS | sed -e s/@os@/$CVO_OS/g` + # keys['osname'] = "cvo.CVO['CVO_OSNAME']" + TS=`echo $TS | sed -e s/@osname@/$CVO_OSNAME/g` + # keys['osver'] = "cvo.CVO['CVO_OSVER']" + TS=`echo $TS | sed -e s/@osver@/$CVO_OSVER/g` + # keys['vendor'] = "cvo.CVO['CVO_VENDOR']" + TS=`echo $TS | sed -e s/@vendor@/$CVO_VENDOR/g` + # keys['raw'] = "cvo.CVO['CVO_raw']" + TS=`echo $TS | sed -e s/@raw@/$CVO_raw/g` + + echo $TS + ;; +esac diff -urN src/contrib/ntp/scripts/genCommitLog src.ntp/contrib/ntp/scripts/genCommitLog --- src/contrib/ntp/scripts/genCommitLog 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/scripts/genCommitLog 2009-12-09 08:36:35.000000000 +0100 @@ -2,6 +2,15 @@ set -e +GCL_REMOVEWRITE=0 . packageinfo.sh +if [ ! -w . ] ; then + GCL_REMOVEWRITE=1 + chmod u+w . + [ -f CommitLog -a ! -w CommitLog ] && chmod u+w CommitLog +fi bk -R prs -hr${CLTAG}.. -nd':I:' | bk changes -m -v - > CommitLog.new mv CommitLog.new CommitLog +case "$GCL_REMOVEWRITE" in + 1) chmod a-w CommitLog . +esac diff -urN src/contrib/ntp/scripts/genver src.ntp/contrib/ntp/scripts/genver --- src/contrib/ntp/scripts/genver 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/scripts/genver 2009-12-09 08:36:35.000000000 +0100 @@ -16,6 +16,9 @@ *version.def) outputs="include/version.def $outputs" ;; + *version.texi) + outputs="include/version.texi $outputs" + ;; *) echo "Unrecognized option: $i" exit 1 ;; @@ -23,7 +26,7 @@ done case "$outputs" in - '') outputs="version.m4 include/version.def" ;; + '') outputs="version.m4 include/version.def include/version.texi" ;; esac set -e @@ -65,3 +68,21 @@ esac ;; esac + +case "$outputs" in + *version.texi*) + echo "@set UPDATED `date +'%d %B %Y'`" > /tmp/version.texi+ + echo "@set EDITION $dversion" >> /tmp/version.texi+ + echo "@set VERSION $dversion" >> /tmp/version.texi+ + cmp -s /tmp/version.texi+ include/version.texi + rc=$? + case "$force$rc" in + 00) + rm -f /tmp/version.texi+ + ;; + *) + mv /tmp/version.texi+ include/version.texi + ;; + esac + ;; +esac diff -urN src/contrib/ntp/scripts/mkver.in src.ntp/contrib/ntp/scripts/mkver.in --- src/contrib/ntp/scripts/mkver.in 2009-07-12 00:30:37.000000000 +0200 +++ src.ntp/contrib/ntp/scripts/mkver.in 2010-01-24 11:01:47.000000000 +0100 @@ -17,6 +17,8 @@ *) ConfStr="${ConfStr}-?" ;; esac +ConfStr="$ConfStr `LC_TIME=C TZ=UTC date`" + if [ ! -f .version ]; then echo 0 > .version fi diff -urN src/contrib/ntp/scripts/ntp-wait.in src.ntp/contrib/ntp/scripts/ntp-wait.in --- src/contrib/ntp/scripts/ntp-wait.in 2001-08-29 16:35:07.000000000 +0200 +++ src.ntp/contrib/ntp/scripts/ntp-wait.in 2009-12-09 08:36:36.000000000 +0100 @@ -4,14 +4,13 @@ use Getopt::Std; -$opt_f = 0; # 'Hard' failure if 'state' is unknown $opt_n = 1000; # How many tries before we give up? (10 min+) $opt_s = 6; # Seconds to sleep between tries (6s = 10/min) $opt_v = 0; # Be verbose? -getopts('fn:s:v'); +getopts('n:s:v'); -$cmd = 'ntpq -c "rv 0 state"'; +$cmd = 'ntpq -c "rv 0"'; $| = 1; # Autoflush output. @@ -19,20 +18,33 @@ for ($i = 0; $i < $opt_n; ++$i) { open(Q, $cmd." 2>&1 |") || die "Can't start ntpq: $!"; while() { - if (/^state=4/) { - print "\bOK!\n" if ($opt_v); - exit 0; - } - - if (/request variable was unknown/) { - print "\bCan't tell!\nPerhaps you are running an old version of ntpd.\n" if ($opt_v); - exit $opt_f; + chomp; + # the first line should be similar to: + # associd=0 status=0645 leap_none, sync_ntp, ... + if (/^associd=0 status=(\S{4}) (\S+), (\S+),/) { + my $status = $1; + my $leap = $2; + my $sync = $3; + # print $_; + # print "status <$status>, leap <$leap>, sync <$sync>\n"; + last if ($leap =~ /(sync|leap)_alarm/); + if ($leap =~ /leap_(none|((add|del)_sec))/) { + # We could check $sync here to make sure we like the source... + print "\bOK!\n" if ($opt_v); + exit 0; + } + print "\bUnexpected 'leap' status <$leap>\n"; + exit 1; } if (/Connection refused/) { print "\bntpd is not running!\n" if ($opt_v); exit 1; } + + # Otherwise, we have a bigger problem. + print "\bUnexpected first line <$_>\n"; + exit 1; } close(Q); print "\b".substr("*+:.", $i % 4, 1) if ($opt_v); diff -urN src/contrib/ntp/scripts/ntptrace.in src.ntp/contrib/ntp/scripts/ntptrace.in --- src/contrib/ntp/scripts/ntptrace.in 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/scripts/ntptrace.in 2009-12-09 08:36:35.000000000 +0100 @@ -8,6 +8,7 @@ $ntpq = "ntpq"; +$Getopt::Std::STANDARD_HELP_VERSION=1; getopts('nm:'); $dodns = 1; diff -urN src/contrib/ntp/sntp/COPYRIGHT src.ntp/contrib/ntp/sntp/COPYRIGHT --- src/contrib/ntp/sntp/COPYRIGHT 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/COPYRIGHT 2010-05-11 09:55:36.000000000 +0200 @@ -1,80 +1,187 @@ - General Public Licence for the software known as MSNTP - ------------------------------------------------------ +This file is automatically generated from html/copyright.html - (c) Copyright, N.M. Maclaren, 1996, 1997, 2000 - (c) Copyright, University of Cambridge, 1996, 1997, 2000 - - - -Free use of MSNTP in source and binary forms is permitted, provided that this -entire licence is duplicated in all copies, and that any documentation, -announcements, and other materials related to use acknowledge that the software -was developed by N.M. Maclaren (hereafter refered to as the Author) at the -University of Cambridge. Neither the name of the Author nor the University of -Cambridge may be used to endorse or promote products derived from this material -without specific prior written permission. - -The Author and the University of Cambridge retain the copyright and all other -legal rights to the software and make it available non-exclusively. All users -must ensure that the software in all its derivations carries a copyright notice -in the form: - (c) Copyright N.M. Maclaren, - (c) Copyright University of Cambridge. - - - - NO WARRANTY - -Because the MSNTP software is licensed free of charge, the Author and the -University of Cambridge provide absolutely no warranty, either expressed or -implied, including, but not limited to, the implied warranties of -merchantability and fitness for a particular purpose. The entire risk as to -the quality and performance of the MSNTP software is with you. Should MSNTP -prove defective, you assume the cost of all necessary servicing or repair. - -In no event, unless required by law, will the Author or the University of -Cambridge, or any other party who may modify and redistribute this software as -permitted in accordance with the provisions below, be liable for damages for -any losses whatsoever, including but not limited to lost profits, lost monies, -lost or corrupted data, or other special, incidental or consequential losses -that may arise out of the use or inability to use the MSNTP software. - - - - COPYING POLICY - -Permission is hereby granted for copying and distribution of copies of the -MSNTP source and binary files, and of any part thereof, subject to the -following licence conditions: - -1. You may distribute MSNTP or components of MSNTP, with or without additions -developed by you or by others. No charge, other than an "at-cost" distribution -fee, may be charged for copies, derivations, or distributions of this material -without the express written consent of the copyright holders. - -2. You may also distribute MSNTP along with any other product for sale, -provided that the cost of the bundled package is the same regardless of whether -MSNTP is included or not, and provided that those interested only in MSNTP must -be notified that it is a product freely available from the University of -Cambridge. - -3. If you distribute MSNTP software or parts of MSNTP, with or without -additions developed by you or others, then you must either make available the -source to all portions of the MSNTP system (exclusive of any additions made by -you or by others) upon request, or instead you may notify anyone requesting -source that it is freely available from the University of Cambridge. - -4. You may not omit any of the copyright notices on either the source files, -the executable files, or the documentation. - -5. You may not omit transmission of this License agreement with whatever -portions of MSNTP that are distributed. - -6. Any users of this software must be notified that it is without warranty or -guarantee of any nature, express or implied, nor is there any fitness for use -represented. - - -October 1996 -April 1997 -October 2000 + Copyright Notice + + jpg "Clone me," says Dolly sheepishly. + + Last update: 11-May-2010 04:41 UTC + _________________________________________________________________ + + The following copyright notice applies to all files collectively + called the Network Time Protocol Version 4 Distribution. Unless + specifically declared otherwise in an individual file, this notice + applies as if the text was explicitly included in the file. +*********************************************************************** +* * +* Copyright (c) University of Delaware 1992-2010 * +* * +* Permission to use, copy, modify, and distribute this software and * +* its documentation for any purpose with or without fee is hereby * +* granted, provided that the above copyright notice appears in all * +* copies and that both the copyright notice and this permission * +* notice appear in supporting documentation, and that the name * +* University of Delaware not be used in advertising or publicity * +* pertaining to distribution of the software without specific, * +* written prior permission. The University of Delaware makes no * +* representations about the suitability this software for any * +* purpose. It is provided "as is" without express or implied * +* warranty. * +* * +*********************************************************************** + + The following individuals contributed in part to the Network Time + Protocol Distribution Version 4 and are acknowledged as authors of + this work. + 1. [1]Mark Andrews Leitch atomic clock + controller + 2. [2]Bernd Altmeier hopf Elektronik serial + line and PCI-bus devices + 3. [3]Viraj Bais and [4]Clayton Kirkwood + port to WindowsNT 3.5 + 4. [5]Michael Barone GPSVME fixes + 5. [6]Karl Berry syslog to file option + 6. [7]Greg Brackley Major rework of WINNT + port. Clean up recvbuf and iosignal code into separate modules. + 7. [8]Marc Brett Magnavox GPS clock driver + 8. [9]Piete Brooks MSF clock driver, + Trimble PARSE support + 9. [10]Nelson B Bolyard update and complete + broadcast and crypto features in sntp + 10. [11]Jean-Francois Boudreault + IPv6 support + 11. [12]Reg Clemens Oncore driver (Current maintainer) + 12. [13]Steve Clift OMEGA clock driver + 13. [14]Casey Crellin vxWorks (Tornado) port and + help with target configuration + 14. [15]Sven Dietrich Palisade reference + clock driver, NT adj. residuals, integrated Greg's Winnt port. + 15. [16]John A. Dundas III Apple A/UX port + 16. [17]Torsten Duwe Linux + port + 17. [18]Dennis Ferguson foundation code for + NTP Version 2 as specified in RFC-1119 + 18. [19]John Hay IPv6 support and testing + 19. [20]Dave Hart General maintenance, Windows + port interpolation rewrite + 20. [21]Claas Hilbrecht NeoClock4X clock driver + 21. [22]Glenn Hollinger GOES clock driver + 22. [23]Mike Iglesias DEC Alpha port + 23. [24]Jim Jagielski A/UX port + 24. [25]Jeff Johnson massive prototyping + overhaul + 25. [26]Hans Lambermont or + [27] ntpsweep + 26. [28]Poul-Henning Kamp Oncore driver (Original + author) + 27. [29]Frank Kardel [30] PARSE + driver (>14 reference clocks), STREAMS modules for PARSE, support + scripts, syslog cleanup, dynamic interface handling + 28. [31]William L. Jones RS/6000 AIX + modifications, HPUX modifications + 29. [32]Dave Katz RS/6000 AIX port + 30. [33]Craig Leres 4.4BSD port, ppsclock, Magnavox + GPS clock driver + 31. [34]George Lindholm SunOS 5.1 port + 32. [35]Louis A. Mamakos MD5-based authentication + 33. [36]Lars H. Mathiesen adaptation of foundation + code for Version 3 as specified in RFC-1305 + 34. [37]Danny Mayer Network I/O, Windows Port, Code + Maintenance + 35. [38]David L. Mills Version 4 foundation: clock + discipline, authentication, precision kernel; clock drivers: + Spectracom, Austron, Arbiter, Heath, ATOM, ACTS, KSI/Odetics; + audio clock drivers: CHU, WWV/H, IRIG + 36. [39]Wolfgang Moeller VMS port + 37. [40]Jeffrey Mogul ntptrace utility + 38. [41]Tom Moore i386 svr4 port + 39. [42]Kamal A Mostafa SCO OpenServer port + 40. [43]Derek Mulcahy and [44]Damon + Hart-Davis ARCRON MSF clock driver + 41. [45]Rob Neal Bancomm refclock and config/parse code + maintenance + 42. [46]Rainer Pruy + monitoring/trap scripts, statistics file handling + 43. [47]Dirce Richards Digital UNIX V4.0 port + 44. [48]Wilfredo Sánchez added support for + NetInfo + 45. [49]Nick Sayer SunOS streams modules + 46. [50]Jack Sasportas Saved a Lot of + space on the stuff in the html/pic/ subdirectory + 47. [51]Ray Schnitzler Unixware1 port + 48. [52]Michael Shields USNO clock driver + 49. [53]Jeff Steinman Datum PTS clock + driver + 50. [54]Harlan Stenn GNU automake/autoconfigure + makeover, various other bits (see the ChangeLog) + 51. [55]Kenneth Stone HP-UX port + 52. [56]Ajit Thyagarajan IP multicast/anycast + support + 53. [57]Tomoaki TSURUOKA TRAK clock + driver + 54. [58]Paul A Vixie TrueTime GPS driver, generic + TrueTime clock driver + 55. [59]Ulrich Windl corrected and + validated HTML documents according to the HTML DTD + _________________________________________________________________ + +References + + 1. mailto:%20mark_andrews@isc.org + 2. mailto:%20altmeier@atlsoft.de + 3. mailto:%20vbais@mailman1.intel.co + 4. mailto:%20kirkwood@striderfm.intel.com + 5. mailto:%20michael.barone@lmco.com + 6. mailto:%20karl@owl.HQ.ileaf.com + 7. mailto:%20greg.brackley@bigfoot.com + 8. mailto:%20Marc.Brett@westgeo.com + 9. mailto:%20Piete.Brooks@cl.cam.ac.uk + 10. mailto:%20nelson@bolyard.me + 11. mailto:%20Jean-Francois.Boudreault@viagenie.qc.ca + 12. mailto:%20reg@dwf.com + 13. mailto:%20clift@ml.csiro.au + 14. mailto:casey@csc.co.za + 15. mailto:%20Sven_Dietrich@trimble.COM + 16. mailto:%20dundas@salt.jpl.nasa.gov + 17. mailto:%20duwe@immd4.informatik.uni-erlangen.de + 18. mailto:%20dennis@mrbill.canet.ca + 19. mailto:%20jhay@icomtek.csir.co.za + 20. mailto:%20davehart@davehart.com + 21. mailto:%20neoclock4x@linum.com + 22. mailto:%20glenn@herald.usask.ca + 23. mailto:%20iglesias@uci.edu + 24. mailto:%20jagubox.gsfc.nasa.gov + 25. mailto:%20jbj@chatham.usdesign.com + 26. mailto:Hans.Lambermont@nl.origin-it.com + 27. mailto:H.Lambermont@chello.nl + 28. mailto:%20phk@FreeBSD.ORG + 29. http://www4.informatik.uni-erlangen.de/%7ekardel + 30. mailto:%20kardel(at)ntp(dot)org + 31. mailto:%20jones@hermes.chpc.utexas.edu + 32. mailto:%20dkatz@cisco.com + 33. mailto:%20leres@ee.lbl.gov + 34. mailto:%20lindholm@ucs.ubc.ca + 35. mailto:%20louie@ni.umd.edu + 36. mailto:%20thorinn@diku.dk + 37. mailto:%20mayer@ntp.org + 38. mailto:%20mills@udel.edu + 39. mailto:%20moeller@gwdgv1.dnet.gwdg.de + 40. mailto:%20mogul@pa.dec.com + 41. mailto:%20tmoore@fievel.daytonoh.ncr.com + 42. mailto:%20kamal@whence.com + 43. mailto:%20derek@toybox.demon.co.uk + 44. mailto:%20d@hd.org + 45. mailto:%20neal@ntp.org + 46. mailto:%20Rainer.Pruy@informatik.uni-erlangen.de + 47. mailto:%20dirce@zk3.dec.com + 48. mailto:%20wsanchez@apple.com + 49. mailto:%20mrapple@quack.kfu.com + 50. mailto:%20jack@innovativeinternet.com + 51. mailto:%20schnitz@unipress.com + 52. mailto:%20shields@tembel.org + 53. mailto:%20pebbles.jpl.nasa.gov + 54. mailto:%20harlan@pfcs.com + 55. mailto:%20ken@sdd.hp.com + 56. mailto:%20ajit@ee.udel.edu + 57. mailto:%20tsuruoka@nc.fukuoka-u.ac.jp + 58. mailto:%20vixie@vix.com + 59. mailto:%20Ulrich.Windl@rz.uni-regensburg.de diff -urN src/contrib/ntp/sntp/Makefile.am src.ntp/contrib/ntp/sntp/Makefile.am --- src/contrib/ntp/sntp/Makefile.am 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/Makefile.am 2010-05-11 09:46:54.000000000 +0200 @@ -1,19 +1,27 @@ -# Makefile.am, by Harlan Stenn, from: -# Makefile for sntp -# N.M. Maclaren, October 2000. +# Makefile.am for JMK's SNTP, by Harlan Stenn -AUTOMAKE_OPTIONS = foreign -ACLOCAL_AMFLAGS= -I libopts/m4 +NULL= -AM_CPPFLAGS= $(LIBOPTS_CFLAGS) -LDADD= $(LIBOPTS_LDADD) +AUTOMAKE_OPTIONS = foreign 1.10 +ACLOCAL_AMFLAGS= -I ../m4 -I libopts/m4 -NULL= +AM_CPPFLAGS= $(LIBOPTS_CFLAGS) -I$(top_srcdir)/../include \ + -I$(top_srcdir)/../lib/isc/include \ + -I$(top_srcdir)/../lib/isc/nothreads/include \ + -I$(top_srcdir)/../lib/isc/unix/include + +LDADD= $(LIBOPTS_LDADD) -lm ../libntp/libntp.a @LCRYPTO@ + +run_ag= cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" \ + autogen -L ../include --writable -bindir= ${exec_prefix}/${BINSUBDIR} +if NTP_BINSUBDIR_IS_BIN bin_PROGRAMS= sntp -#run_ag= cd $(srcdir) && autogen --writable -L $(top_srcdir)/include -run_ag= cd $(srcdir) && autogen --writable +else +sbin_PROGRAMS= sntp +endif + +CLEANFILES = check-COPYRIGHT-submake SUBDIRS= if NEED_LIBOPTS @@ -21,31 +29,70 @@ endif SUBDIRS+= . -sntp_SOURCES = \ - header.h \ - internet.c \ - internet.h \ - kludges.h \ - main.c \ - sntp-opts.c \ - sntp-opts.h \ - socket.c \ - timing.c \ - unix.c \ +sntp_SOURCES = \ + crypto.c \ + crypto.h \ + data_formats.h \ + header.h \ + kod_management.c \ + kod_management.h \ + log.c \ + log.h \ + main.c \ + networking.c \ + networking.h \ + sntp-opts.c \ + sntp-opts.h \ + utilities.c \ + utilities.h \ + $(NULL) + +EXTRA_DIST= \ + $(srcdir)/autogen-version.def \ + bincheck.mf \ + $(srcdir)/COPYRIGHT \ + deps-ver \ + depsver.mf \ + sntp-opts.def \ + sntp-opts.menu \ + sntp-opts.texi \ + sntp.1 \ + sntp.html \ + sntp.texi \ + $(srcdir)/version.def \ + $(srcdir)/version.m4 \ + $(srcdir)/version.texi \ $(NULL) -dist_man_MANS= sntp.1 +OLD_EXTRA_DIST= \ + autogen-version.def version.def version.m4 version.texi + +BUILT_SOURCES= \ + check-autogen-version.def \ + check-version.def \ + check-version.m4 \ + check-version.texi \ + $(srcdir)/COPYRIGHT \ + libtool \ + $(srcdir)/sntp-opts.c \ + $(srcdir)/sntp-opts.h \ + $(NULL) -EXTRA_DIST= bincheck.mf \ - COPYRIGHT \ - sntp-opts.def sntp.1 sntp-opts.texi sntp-opts.menu \ - autogen-version.def version.def -BUILT_SOURCES= check-autogen-version.def check-version.def \ - sntp-opts.c sntp-opts.h sntp.1 sntp-opts.texi sntp-opts.menu -man_MANS= sntp.1 +man_MANS= $(srcdir)/sntp.1 +noinst_DATA= \ + $(srcdir)/sntp.html \ + $(srcdir)/sntp-opts.texi \ + $(srcdir)/sntp-opts.menu \ + $(NULL) FRC: + @: do-nothing action to prevent default SCCS get + @: FRC "force" depends on nothing and is not a file, so is + @: always out-of-date causing targets which depend on it to + @: similarly always be outdated causing their rules to fire + @: each time they or a dependent is built. + check-autogen-version.def: FRC @cd $(srcdir) \ && test -r ../include/autogen-version.def \ @@ -55,6 +102,9 @@ echo "Installing new sntp/autogen-version.def file"; \ fi ) +$(srcdir)/autogen-version.def: + $(MAKE) check-autogen-version.def + check-version.def: FRC @cd $(srcdir) \ && test -r ../include/version.def \ @@ -64,14 +114,73 @@ echo "Installing new sntp/version.def file"; \ fi ) +$(srcdir)/version.def: + $(MAKE) check-version.def + +check-version.m4: FRC + @cd $(srcdir) \ + && test -r ../version.m4 \ + && ( if cmp -s ../version.m4 version.m4; \ + then : ; \ + else cp ../version.m4 version.m4; \ + echo "Installing new sntp/version.m4 file"; \ + fi ) + +$(srcdir)/version.m4: + $(MAKE) check-version.m4 + +check-version.texi: FRC + @cd $(srcdir) \ + && test -r ../include/version.texi \ + && ( if cmp -s ../include/version.texi version.texi; \ + then : ; \ + else cp ../include/version.texi version.texi; \ + echo "Installing new sntp/version.texi file"; \ + fi ) + +$(srcdir)/version.texi: + $(MAKE) check-version.texi + +$(srcdir)/../COPYRIGHT: + cd .. && $(MAKE) COPYRIGHT-please + +check-COPYRIGHT-submake: $(srcdir)/../COPYRIGHT + @cmp -s $(srcdir)/../COPYRIGHT $(srcdir)/COPYRIGHT \ + || { cp $(srcdir)/../COPYRIGHT $(srcdir) \ + && echo 'updated sntp/COPYRIGHT installed' ;} + @echo 'submake avoided if this file is newer than parent COPYRIGHT' > $@ + +check-COPYRIGHT: FRC + [ ! -r $(srcdir)/../COPYRIGHT ] \ + || [ check-COPYRIGHT-submake -nt $(srcdir)/../COPYRIGHT ] \ + || $(MAKE) check-COPYRIGHT-submake + +$(srcdir)/COPYRIGHT: check-COPYRIGHT + @: do-nothing action to prevent any default + $(srcdir)/sntp-opts.h: $(srcdir)/sntp-opts.c -$(srcdir)/sntp-opts.c: $(srcdir)/sntp-opts.def $(srcdir)/version.def + @: do-nothing action to avoid default SCCS get, .h built with .c + +$(srcdir)/sntp-opts.c: $(srcdir)/sntp-opts.def $(srcdir)/version.def $(srcdir)/../include/copyright.def $(run_ag) sntp-opts.def -$(srcdir)/sntp.1: $(srcdir)/sntp-opts.def $(srcdir)/version.def +$(srcdir)/sntp.1: $(srcdir)/sntp-opts.def $(srcdir)/version.def $(srcdir)/../include/copyright.def $(run_ag) -Tagman1.tpl -bsntp sntp-opts.def -$(srcdir)/sntp-opts.texi $(srcdir)/sntp-opts.menu: $(srcdir)/sntp-opts.def $(srcdir)/version.def +$(srcdir)/sntp-opts.menu: $(srcdir)/sntp-opts.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/sntp-opts.texi: $(srcdir)/sntp-opts.def $(srcdir)/version.def $(srcdir)/../include/copyright.def $(run_ag) -Taginfo.tpl -DLEVEL=section sntp-opts.def -include bincheck.mf +$(srcdir)/sntp.html: $(srcdir)/sntp-opts.menu $(srcdir)/sntp-opts.texi $(srcdir)/sntp.texi $(srcdir)/version.texi + cd $(srcdir) && makeinfo --force --html --no-split -o sntp.html sntp.texi + +../libntp/libntp.a: + cd ../libntp && $(MAKE) libntp.a + +libtool: $(LIBTOOL_DEPS) + ./config.status --recheck + +include $(top_srcdir)/bincheck.mf +include $(top_srcdir)/depsver.mf diff -urN src/contrib/ntp/sntp/Makefile.in src.ntp/contrib/ntp/sntp/Makefile.in --- src/contrib/ntp/sntp/Makefile.in 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/Makefile.in 2010-07-09 04:24:44.000000000 +0200 @@ -15,14 +15,13 @@ @SET_MAKE@ -# Makefile.am, by Harlan Stenn, from: -# Makefile for sntp -# N.M. Maclaren, October 2000. +# Makefile.am for JMK's SNTP, by Harlan Stenn # we traditionally installed software in bindir, while it should have gone # in sbindir. Now that we offer a choice, look in the "other" installation # subdir to warn folks if there is another version there. + VPATH = @srcdir@ pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ @@ -42,16 +41,20 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -bin_PROGRAMS = sntp$(EXEEXT) +@NTP_BINSUBDIR_IS_BIN_TRUE@bin_PROGRAMS = sntp$(EXEEXT) +@NTP_BINSUBDIR_IS_BIN_FALSE@sbin_PROGRAMS = sntp$(EXEEXT) @NEED_LIBOPTS_TRUE@am__append_1 = libopts -DIST_COMMON = README $(am__configure_deps) $(dist_man_MANS) \ - $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ - $(srcdir)/bincheck.mf $(srcdir)/config.h.in \ - $(top_srcdir)/configure compile config.guess config.sub \ +DIST_COMMON = $(am__configure_deps) $(srcdir)/Makefile.am \ + $(srcdir)/Makefile.in $(srcdir)/config.h.in \ + $(top_srcdir)/bincheck.mf $(top_srcdir)/configure \ + $(top_srcdir)/depsver.mf compile config.guess config.sub \ depcomp install-sh ltmain.sh missing subdir = . ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ + $(top_srcdir)/../m4/ntp_cacheversion.m4 \ + $(top_srcdir)/../m4/ntp_dir_sep.m4 \ + $(top_srcdir)/../m4/ntp_openssl.m4 $(top_srcdir)/../version.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) @@ -61,16 +64,17 @@ CONFIG_HEADER = config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = -am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)" -PROGRAMS = $(bin_PROGRAMS) +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(sbindir)" \ + "$(DESTDIR)$(man1dir)" +PROGRAMS = $(bin_PROGRAMS) $(sbin_PROGRAMS) am__objects_1 = -am_sntp_OBJECTS = internet.$(OBJEXT) main.$(OBJEXT) \ - sntp-opts.$(OBJEXT) socket.$(OBJEXT) timing.$(OBJEXT) \ - unix.$(OBJEXT) $(am__objects_1) +am_sntp_OBJECTS = crypto.$(OBJEXT) kod_management.$(OBJEXT) \ + log.$(OBJEXT) main.$(OBJEXT) networking.$(OBJEXT) \ + sntp-opts.$(OBJEXT) utilities.$(OBJEXT) $(am__objects_1) sntp_OBJECTS = $(am_sntp_OBJECTS) sntp_LDADD = $(LDADD) am__DEPENDENCIES_1 = -sntp_DEPENDENCIES = $(am__DEPENDENCIES_1) +sntp_DEPENDENCIES = $(am__DEPENDENCIES_1) ../libntp/libntp.a DEFAULT_INCLUDES = -I.@am__isrc@ depcomp = $(SHELL) $(top_srcdir)/depcomp am__depfiles_maybe = depfiles @@ -116,7 +120,8 @@ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' man1dir = $(mandir)/man1 NROFF = nroff -MANS = $(dist_man_MANS) $(man_MANS) +MANS = $(man_MANS) +DATA = $(noinst_DATA) RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ distclean-recursive maintainer-clean-recursive AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \ @@ -190,6 +195,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LCRYPTO = @LCRYPTO@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ @@ -202,6 +208,9 @@ MAKEINFO = @MAKEINFO@ MKDIR_P = @MKDIR_P@ OBJEXT = @OBJEXT@ +OPENSSL = @OPENSSL@ +OPENSSL_INC = @OPENSSL_INC@ +OPENSSL_LIB = @OPENSSL_LIB@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -225,7 +234,7 @@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ -bindir = ${exec_prefix}/${BINSUBDIR} +bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ @@ -265,37 +274,69 @@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -AUTOMAKE_OPTIONS = foreign -ACLOCAL_AMFLAGS = -I libopts/m4 -AM_CPPFLAGS = $(LIBOPTS_CFLAGS) -LDADD = $(LIBOPTS_LDADD) NULL = -#run_ag= cd $(srcdir) && autogen --writable -L $(top_srcdir)/include -run_ag = cd $(srcdir) && autogen --writable +AUTOMAKE_OPTIONS = foreign 1.10 +ACLOCAL_AMFLAGS = -I ../m4 -I libopts/m4 +AM_CPPFLAGS = $(LIBOPTS_CFLAGS) -I$(top_srcdir)/../include \ + -I$(top_srcdir)/../lib/isc/include \ + -I$(top_srcdir)/../lib/isc/nothreads/include \ + -I$(top_srcdir)/../lib/isc/unix/include + +LDADD = $(LIBOPTS_LDADD) -lm ../libntp/libntp.a @LCRYPTO@ +run_ag = cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" \ + autogen -L ../include --writable + +CLEANFILES = check-COPYRIGHT-submake .deps-ver SUBDIRS = $(am__append_1) . sntp_SOURCES = \ - header.h \ - internet.c \ - internet.h \ - kludges.h \ - main.c \ - sntp-opts.c \ - sntp-opts.h \ - socket.c \ - timing.c \ - unix.c \ + crypto.c \ + crypto.h \ + data_formats.h \ + header.h \ + kod_management.c \ + kod_management.h \ + log.c \ + log.h \ + main.c \ + networking.c \ + networking.h \ + sntp-opts.c \ + sntp-opts.h \ + utilities.c \ + utilities.h \ + $(NULL) + +EXTRA_DIST = \ + $(srcdir)/autogen-version.def \ + bincheck.mf \ + $(srcdir)/COPYRIGHT \ + deps-ver \ + depsver.mf \ + sntp-opts.def \ + sntp-opts.menu \ + sntp-opts.texi \ + sntp.1 \ + sntp.html \ + sntp.texi \ + $(srcdir)/version.def \ + $(srcdir)/version.m4 \ + $(srcdir)/version.texi \ $(NULL) -dist_man_MANS = sntp.1 -EXTRA_DIST = bincheck.mf \ - COPYRIGHT \ - sntp-opts.def sntp.1 sntp-opts.texi sntp-opts.menu \ - autogen-version.def version.def +OLD_EXTRA_DIST = \ + autogen-version.def version.def version.m4 version.texi -BUILT_SOURCES = check-autogen-version.def check-version.def \ - sntp-opts.c sntp-opts.h sntp.1 sntp-opts.texi sntp-opts.menu +BUILT_SOURCES = check-autogen-version.def check-version.def \ + check-version.m4 check-version.texi $(srcdir)/COPYRIGHT \ + libtool $(srcdir)/sntp-opts.c $(srcdir)/sntp-opts.h $(NULL) \ + .deps-ver +man_MANS = $(srcdir)/sntp.1 +noinst_DATA = \ + $(srcdir)/sntp.html \ + $(srcdir)/sntp-opts.texi \ + $(srcdir)/sntp-opts.menu \ + $(NULL) -man_MANS = sntp.1 all: $(BUILT_SOURCES) config.h $(MAKE) $(AM_MAKEFLAGS) all-recursive @@ -303,7 +344,7 @@ .SUFFIXES: .c .lo .o .obj am--refresh: @: -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(srcdir)/bincheck.mf $(am__configure_deps) +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/bincheck.mf $(top_srcdir)/depsver.mf $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -395,6 +436,49 @@ list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ echo " rm -f" $$list; \ rm -f $$list +install-sbinPROGRAMS: $(sbin_PROGRAMS) + @$(NORMAL_INSTALL) + test -z "$(sbindir)" || $(MKDIR_P) "$(DESTDIR)$(sbindir)" + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p || test -f $$p1; \ + then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-sbinPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(sbindir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(sbindir)" && rm -f $$files + +clean-sbinPROGRAMS: + @list='$(sbin_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list sntp$(EXEEXT): $(sntp_OBJECTS) $(sntp_DEPENDENCIES) @rm -f sntp$(EXEEXT) $(LINK) $(sntp_OBJECTS) $(sntp_LDADD) $(LIBS) @@ -405,12 +489,13 @@ distclean-compile: -rm -f *.tab.c -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/internet.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/crypto.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kod_management.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/log.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/main.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/networking.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sntp-opts.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/socket.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/timing.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/unix.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/utilities.Po@am__quote@ .c.o: @am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @@ -441,12 +526,12 @@ distclean-libtool: -rm -f libtool config.lt -install-man1: $(dist_man_MANS) $(man_MANS) +install-man1: $(man_MANS) @$(NORMAL_INSTALL) test -z "$(man1dir)" || $(MKDIR_P) "$(DESTDIR)$(man1dir)" @list=''; test -n "$(man1dir)" || exit 0; \ { for i in $$list; do echo "$$i"; done; \ - l2='$(dist_man_MANS) $(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ + l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ sed -n '/\.1[a-z]*$$/p'; \ } | while read p; do \ if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ @@ -472,7 +557,7 @@ @$(NORMAL_UNINSTALL) @list=''; test -n "$(man1dir)" || exit 0; \ files=`{ for i in $$list; do echo "$$i"; done; \ - l2='$(dist_man_MANS) $(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ + l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ sed -n '/\.1[a-z]*$$/p'; \ } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ @@ -805,10 +890,10 @@ check-am: all-am check: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) check-recursive -all-am: Makefile $(PROGRAMS) $(MANS) config.h +all-am: Makefile $(PROGRAMS) $(MANS) $(DATA) config.h installdirs: installdirs-recursive installdirs-am: - for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)"; do \ + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: $(BUILT_SOURCES) @@ -829,6 +914,7 @@ mostlyclean-generic: clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) @@ -840,7 +926,8 @@ -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-recursive -clean-am: clean-binPROGRAMS clean-generic clean-libtool mostlyclean-am +clean-am: clean-binPROGRAMS clean-generic clean-libtool \ + clean-sbinPROGRAMS mostlyclean-am distclean: distclean-recursive -rm -f $(am__CONFIG_DISTCLEAN_FILES) @@ -867,7 +954,7 @@ install-dvi-am: -install-exec-am: install-binPROGRAMS +install-exec-am: install-binPROGRAMS install-sbinPROGRAMS @$(NORMAL_INSTALL) $(MAKE) $(AM_MAKEFLAGS) install-exec-hook install-html: install-html-recursive @@ -910,7 +997,8 @@ ps-am: -uninstall-am: uninstall-binPROGRAMS uninstall-man +uninstall-am: uninstall-binPROGRAMS uninstall-man \ + uninstall-sbinPROGRAMS uninstall-man: uninstall-man1 @@ -920,25 +1008,33 @@ .PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \ all all-am am--refresh check check-am clean clean-binPROGRAMS \ - clean-generic clean-libtool ctags ctags-recursive dist \ - dist-all dist-bzip2 dist-gzip dist-lzma dist-shar dist-tarZ \ - dist-xz dist-zip distcheck distclean distclean-compile \ - distclean-generic distclean-hdr distclean-libtool \ - distclean-tags distcleancheck distdir distuninstallcheck dvi \ - dvi-am html html-am info info-am install install-am \ - install-binPROGRAMS install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-exec-hook \ - install-html install-html-am install-info install-info-am \ - install-man install-man1 install-pdf install-pdf-am install-ps \ - install-ps-am install-strip installcheck installcheck-am \ - installdirs installdirs-am maintainer-clean \ + clean-generic clean-libtool clean-sbinPROGRAMS ctags \ + ctags-recursive dist dist-all dist-bzip2 dist-gzip dist-lzma \ + dist-shar dist-tarZ dist-xz dist-zip distcheck distclean \ + distclean-compile distclean-generic distclean-hdr \ + distclean-libtool distclean-tags distcleancheck distdir \ + distuninstallcheck dvi dvi-am html html-am info info-am \ + install install-am install-binPROGRAMS install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-exec-hook install-html install-html-am \ + install-info install-info-am install-man install-man1 \ + install-pdf install-pdf-am install-ps install-ps-am \ + install-sbinPROGRAMS install-strip installcheck \ + installcheck-am installdirs installdirs-am maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-compile \ mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ tags tags-recursive uninstall uninstall-am \ - uninstall-binPROGRAMS uninstall-man uninstall-man1 + uninstall-binPROGRAMS uninstall-man uninstall-man1 \ + uninstall-sbinPROGRAMS FRC: + @: do-nothing action to prevent default SCCS get + @: FRC "force" depends on nothing and is not a file, so is + @: always out-of-date causing targets which depend on it to + @: similarly always be outdated causing their rules to fire + @: each time they or a dependent is built. + check-autogen-version.def: FRC @cd $(srcdir) \ && test -r ../include/autogen-version.def \ @@ -948,6 +1044,9 @@ echo "Installing new sntp/autogen-version.def file"; \ fi ) +$(srcdir)/autogen-version.def: + $(MAKE) check-autogen-version.def + check-version.def: FRC @cd $(srcdir) \ && test -r ../include/version.def \ @@ -957,27 +1056,149 @@ echo "Installing new sntp/version.def file"; \ fi ) +$(srcdir)/version.def: + $(MAKE) check-version.def + +check-version.m4: FRC + @cd $(srcdir) \ + && test -r ../version.m4 \ + && ( if cmp -s ../version.m4 version.m4; \ + then : ; \ + else cp ../version.m4 version.m4; \ + echo "Installing new sntp/version.m4 file"; \ + fi ) + +$(srcdir)/version.m4: + $(MAKE) check-version.m4 + +check-version.texi: FRC + @cd $(srcdir) \ + && test -r ../include/version.texi \ + && ( if cmp -s ../include/version.texi version.texi; \ + then : ; \ + else cp ../include/version.texi version.texi; \ + echo "Installing new sntp/version.texi file"; \ + fi ) + +$(srcdir)/version.texi: + $(MAKE) check-version.texi + +$(srcdir)/../COPYRIGHT: + cd .. && $(MAKE) COPYRIGHT-please + +check-COPYRIGHT-submake: $(srcdir)/../COPYRIGHT + @cmp -s $(srcdir)/../COPYRIGHT $(srcdir)/COPYRIGHT \ + || { cp $(srcdir)/../COPYRIGHT $(srcdir) \ + && echo 'updated sntp/COPYRIGHT installed' ;} + @echo 'submake avoided if this file is newer than parent COPYRIGHT' > $@ + +check-COPYRIGHT: FRC + [ ! -r $(srcdir)/../COPYRIGHT ] \ + || [ check-COPYRIGHT-submake -nt $(srcdir)/../COPYRIGHT ] \ + || $(MAKE) check-COPYRIGHT-submake + +$(srcdir)/COPYRIGHT: check-COPYRIGHT + @: do-nothing action to prevent any default + $(srcdir)/sntp-opts.h: $(srcdir)/sntp-opts.c -$(srcdir)/sntp-opts.c: $(srcdir)/sntp-opts.def $(srcdir)/version.def + @: do-nothing action to avoid default SCCS get, .h built with .c + +$(srcdir)/sntp-opts.c: $(srcdir)/sntp-opts.def $(srcdir)/version.def $(srcdir)/../include/copyright.def $(run_ag) sntp-opts.def -$(srcdir)/sntp.1: $(srcdir)/sntp-opts.def $(srcdir)/version.def +$(srcdir)/sntp.1: $(srcdir)/sntp-opts.def $(srcdir)/version.def $(srcdir)/../include/copyright.def $(run_ag) -Tagman1.tpl -bsntp sntp-opts.def -$(srcdir)/sntp-opts.texi $(srcdir)/sntp-opts.menu: $(srcdir)/sntp-opts.def $(srcdir)/version.def +$(srcdir)/sntp-opts.menu: $(srcdir)/sntp-opts.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/sntp-opts.texi: $(srcdir)/sntp-opts.def $(srcdir)/version.def $(srcdir)/../include/copyright.def $(run_ag) -Taginfo.tpl -DLEVEL=section sntp-opts.def +$(srcdir)/sntp.html: $(srcdir)/sntp-opts.menu $(srcdir)/sntp-opts.texi $(srcdir)/sntp.texi $(srcdir)/version.texi + cd $(srcdir) && makeinfo --force --html --no-split -o sntp.html sntp.texi + +../libntp/libntp.a: + cd ../libntp && $(MAKE) libntp.a + +libtool: $(LIBTOOL_DEPS) + ./config.status --recheck + install-exec-hook: - @case ${BINSUBDIR} in \ - bin) ODIR=${exec_prefix}/sbin ;; \ - sbin) ODIR=${exec_prefix}/bin ;; \ - esac; \ - test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ + @case ${BINSUBDIR} in \ + bin) ODIR=${sbindir} ;; \ + sbin) ODIR=${bindir} ;; \ + esac; \ + test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ test ! -f $$ODIR/$$i || echo "*** $$i is also in $$ODIR!"; \ done # +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + ..) \ + cd .. && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + *) \ + echo 'Fatal: depsver.mf Automake fragment limited' \ + 'to immediate subdirectories.' && \ + echo "top_builddir: $(top_builddir)" && \ + echo "subdir: $(subdir)" && \ + exit 1 \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff -urN src/contrib/ntp/sntp/README src.ntp/contrib/ntp/sntp/README --- src/contrib/ntp/sntp/README 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/README 1970-01-01 01:00:00.000000000 +0100 @@ -1,536 +0,0 @@ -SNTP (Simple Network Time Protocol Utility) - Version 1.6 ----------------------------------------------------------- - -Please read the file Copyright first. Also note that the file RFC2030.TXT is -David Mills's copyright and not the author's - it is just a copy of the RFC -that is available from so many Internet archives. - -RFC 1305 (Network Time Protocol - NTP) is an attempt to provide globally -consistent timestamps in an extremely hostile environment; it is fiendishly -complicated and an impressive piece of virtuosity. RFC 2030 (Simple Network -Time Protocol - SNTP) which supersedes RFC 1769 describes a subset of this that -will give excellent accuracy in most environments encountered in practice; it -uses only the obvious algorithms that have been used since time immemorial. - -WARNING: the text version of RFC 1305 is incomplete, and omits the tables that -are in the Postscript version. Unfortunately, these contain the only copy of -some critical information. - -draft-mills-sntp-v4-00.txt is the next proposed revision of RFC 2030, -and the current goal is to have this code implement that specification. - -SNTP Servers - Some Little-Known Facts --------------------------------------- - -RFC 2030 states that SNTP clients should be used only at the lowest level, -which is good practice. It then states that SNTP servers should be used only -at stratum 1 (i.e. top level), which is bizarre! A far saner use of them would -be for the very lowest level of server, exporting solely to local clients that -do not themselves act as servers to ANY system (e.g. on a Netware server, -exporting only to the PCs that it manages). - -[There is missing language in the previous paragraph. SNTP is designed -to be used in 2 cases: as a client at the lowest levels of the timing -hierarchy, or as a server of last resort at stratum 1 when connected to -a modem or radio clock.] - -[This is as far as I have updated this file as part of the upgrade.] - -If the NTP network were being run as a directed acyclic graph (i.e. using SNTP -rather than full NTP), with a diameter of D links and a maximum error per link -of E, the maximum synchronisation error would be D*E. Reasonable figures for D -and E are 5 and 0.1 seconds, so this would be adequate for most uses. Note -that the fact that the graph is acyclic is critical, which is one reason why -SNTP client/servers must NEVER be embedded WITHIN an NTP network. - -The other reason is that inserting SNTP client/servers at a low stratum (but -not the root) of an NTP network could easily break NTP! See RFC 1305 for why, -but don't expect the answer to stand out at you. It would be easy to extend -SNTP to a full-function client/server application, thus making it into a true -alternative to ntp, but this incompatibility is why it MUST NOT be done. - -The above does not mean that the SNTP approach is unsatisfactory, but only that -it is incompatible with full NTP. The author would favour a complete SNTP -network using the SNTP approach, and the statistical error reduction used in -SNTP, but it actually addresses a slightly different problem from that -addressed by NTP. TANSTAAFL. - -FINAL WARNING: do NOT use this program to serve NTP requests from outside the -systems that you manage. If you do this, and manage to break the time -synchronisation on other people's systems, you will be regarded very -unfavourably. Actually, this should be possible only if their NTP client is -completely broken, because SNTP does its damnedest to declare its packets as -the lowest form of NTP timestamp. - - - -SNTP and its Assumptions -------------------------- - -SNTP is intended to be a straightforward SNTP daemon/utility that is easy to -build on any reasonable Unix platform (and most near-Unix ones), whether or not -it has ever been ported to them before. It is intended to answer the following -requirements, either by challenge and response or the less reliable broadcast -method: - - A simple command to run on Unix systems that will check the time - and optionally drift compared with a known, local and reliable NTP - time server. No privilege is required just to read the time and - estimate the drift. - - A client for Unix systems that will synchronise the time from a known, - local and reliable NTP time server. This is probably the most common - one, and the need that caused the program to be written. - - A server for Unix systems that are synchronised other than by NTP - methods and that need to synchronise other systems by NTP. This is - the classroom of PCs with a central server scenario. It is NOT - intended to work as a peer with true NTP servers, and won't. - - A simple method by which two or more Unix systems can keep themselves - synchronised using what is becoming a standard protocol. Yes, I know - that there are half-a-dozen other such methods. - - A base for building non-Unix SNTP clients. Some 3/4 of the code - (including all of the complicated algorithms and NTP packet handling) - should work, unchanged, on any system with an ANSI/ISO C compiler. - -There are full tracing facilities and a lot of paranoia in the code to check -for bad packets (more than in ntp) which may need relaxing in the light of -experience. Unfortunately, RFC 1305 does not include a precise description of -the data protocol, despite its length, and there are some internal -inconsistencies and differences between it and RFC 2030 and ntp's behaviour. - -WARNING: SNTP has not been tested in conjunction with ntp broadcasts or ntp -clients, as the ability to do so was not available to the author. It is very -unlikely that it won't work, but you should check. Much of the paranoid code -is only partially tested, too, because it is dealing with cases that are very -hard to provoke. - -It assumes that the local network is tolerably secure and that any accessible -NTP or SNTP servers are trustworthy. It also makes no attempt to check that -it has been installed and is being used correctly (e.g. at an appropriate -priority) or that the changes it makes have the desired effect. When you first -use it, you should both run it in display mode and use the date command as a -cross-check. - -Furthermore, it does not attempt to solve all of the problems addressed by the -NTP protocol and you should NOT use it if any of those problems are likely to -cause you serious trouble. If they are, bite the bullet and implement ntp, or -buy a fancy time-server. - - -Building SNTP -------------- - -The contents of the distribution are: - -README - this file -Copyright - the copyright notice and conditions of use -Makefile - the makefile, with comments for several systems -header.h - the main header (almost entirely portable) -kludges.h - dirty kludges for difficult systems -internet.h - a very small header for internet.c and socket.c -main.c - most of the source (almost entirely portable) -unix.c - just for isatty, sleep and locking -internet.c - Internet host and service name lookup -socket.c - the Berkeley socket code -sntp.1 - the man page -RFC2030.TXT - the SNTPv4 specification - -All you SHOULD need to do is to uncomment the settings in file Makefile for -your system or to add new ones. But real life is not always so simple. As -POSIX does not yet define sub-second timers, Internet addressing facilities, -sockets etc., the code has to rely on the facilities described in the -ill-defined and non-standard 'X/Open' documents and the almost totally -unspecified 'BSD' extensions. - -Most hacks should be limited to the compiler options (e.g. setting flags like -_XOPEN_SOURCE), but perverse systems may need additions to kludges.h - please -report them to the author. See Makefile and kludges.h for documentation on -the standard hacks - there only 6, and most are only for obsolete systems. -But, generally, using the generic set of C options usually works with no -further ado. - - -Sick, Bizarre or non-Unix Systems ---------------------------------- - -A very few Unix systems and almost all non-Unix systems may need changes to the -code, such as: - - If the system doesn't have Berkeley sockets, you will need to replace - socket.c and possibly modify internet.h and internet.c. All of the - systems for which the author needs this have Berkeley sockets. - - NTP is supposedly an Internet protocol, but is not Internet specific. - For other types of network, you will need to replace internet.c and - probably modify internet.h. - - If the system doesn't have gettimeofday or settimeofday, you will - need to modify timing.c. If it doesn't have adjtime (e.g. HP-UX - on PA-RISC before 10.0), you can set -DADJTIME_MISSING and the code - will compile but the -a option will always give an error. - - If the system has totally broken signal handling, the program will - hang or crash if it can't reach its name server or responses time - out. You may be able to improve matters by hacking internet.c and - socket.c, but don't bet on it. - - If the the program won't be able to create files in /etc when - updating the clock, you can use another lock file or even set - -DLOCKFILE=NULL, which will disable the locking code entirely. On - systems that have it, using /var/run would be better than /etc. - - If the the program hangs when flushing outstanding packets (which - you can tell by setting -W), it may help to set -DNONBLOCK_BROKEN. - This seems needed only for obsolete systems, like Ultrix. - - If the system isn't Unix, even vaguely, you will probably need to - modify all of the above, and unix.c as well. - - Note that adjtime is commonly sick, but you don't need to change the - code - just use the -r option whan making large corrections (see below - for more details). - -Any changes needed to header.h or main.c are bugs. They may be bugs in the -code or in the compiler or libraries, but they are bugs. Please prod the -people responsible and tell the author, who may be able to bypass them cleanly -even if they aren't bugs in his code. The code also makes the following -assumptions, which would be quite hard to remove: - - 8-bit bytes. Strictly, neither ANSI/ISO C nor POSIX require these, - and there were some very early versions of Unix on systems with other - byte sizes. But, without a defined sub-byte facility in C, .... - - At least 32-bit ints. Well, actually, this wouldn't be too hard to - remove. But most Unix programs make this assumption, and I have very - little interest in the more rudimentary versions of MS-DOS etc. - - An ANSI/ISO C compiler. It didn't seem worth writing dual-language - code in 1996. Tough luck if you haven't got one. - - Tolerably efficient floating-point arithmetic, with at least 13 digits - (decimal), preferably 15, in the mantissa of doubles. Ditto. If you - want to port this to a toaster, please accept my insincerest sympathies - and don't bother me. - - A trustworthy local network. It does not check for DNS, Ethernet, - packet or other spoofing, and assumes that any accessible NTP or SNTP - servers are properly synchronised. - - -Warnings about Installation and Use ------------------------------------ - -Anyone attempting to fiddle with the clock on their system should already know -how to write system administration scripts, install daemons and so on. There -are a few warnings: - - Don't use the broadcast modes unless you really have to, as the - client-server modes are far more reliable. The broadcast modes were - implemented more for virtuosity (a.k.a. SNTP conformance) than use. - In particular, the error estimates are mere guesses, and may be low - or even very low. And even reading broadcasts needs privilege. - - The program is not intended to be installed setuid or setgid, and - doing so is asking for trouble. Its ownerships and access modes are - not important. It need not be run by root for merely displaying the - time (even in daemon mode). - - The program does not need to run at a high priority (low in Unix - terms!) even when being used to set the clock or as a server, except - when the '-r' option is used. However, doing so may improve its - accuracy. - - Unlike NTP, the SNTP protocol contains no protection against - client-server loops. If you set one up, your systems will spin - themselves off into a disconnected vortex of unreality! - - It will get very confused if another process changes the local time - while it is running. There is some locking code in unix.c to prevent - this program doing this to itself, but it will protect only against - some errors. However, the remaining failures should be harmless. - - Don't run it as a server unless you REALLY know what you are doing. - It should be used as a server only on a system that is properly - synchronised, by fair means or foul. If it isn't, you will simply - perpetrate misinformation. And remember that broadcasts are most - unpopular with overloaded administrators of overloaded networks. - - Watch out for multi-server broadcasts and systems with multiple ports - onto the same Ethernet; there is some code to protect against this, - but it is still easy to get confused. - - Don't put the lock file onto an automounted partition or delete it by - hand, unless you really want to start two daemons at the same time. - Both will probably fail horribly if you do this. - - The daemon save file is checked fairly carefully, but should be in a - reasonably safe directory, unless you want hackers to cause trouble. - /tmp is safe enough on most systems, but not all - /etc is better. - - -Installing and Using the Program --------------------------------- - -Start by copying the executable and man page to where you want them. If you -want only to display the time and as a replacement for the rdate or date -commands, the installation is finished! - -You can use it as a simple unprivileged command to check the time, quite -independently of whether it is running as a time-updating daemon or server, or -whether you are running ntp. You can run it in daemon mode without updating -the clock, to check for drift, but it may fail if the clock is changed under -its feet. Unfortunately, you cannot listen to broadcasts without privilege. - -If it is used with the -a option to keep the time synchronised, it is best to -run it as one of root's cron jobs - for many systems, running it once a day -should be adequate, but it will depend on the reliability of the local clock. -The author runs it this way with -a and -x - see below. - -If it is used with the -r option to set the time (instead of the rdate or date -commands), it should be used interactively and either on a lightly loaded -system or at a high priority. You should then check the result by running it -in display mode. - -You are advised NOT to run it with the -r option in a cron job, though this is -not locked out. If you have to (for example under HP-UX before 10.0), be sure -to run it as the highest priority that will not cause other system problems and -set the maximum automatic change to as low a value as you can get away with. - -WARNING: adjtime is more than a bit sick on many systems, and will ignore large -corrections, usually without any form of hint that it has done so. It is often -(even usually) necessary to reset the clock to approximately the right time -using the -r option before using the -a and -x options to keep it correct. - -It can be started as a time-updating daemon with the -a and -x options (or -r -and -x if you must), and will perform some limited drift correction. In this -case, start it from any suitable system initialisation script and leave it -running. Note that it will stop if it thinks that the time difference or drift -has got out of control, and you will need to reset the time and restart it by -hand. - -In daemon mode, it will survive its time server or network disappearing for a -while, but will eventually fail, and will fail immediately if the network call -returns an unexpected error. If this is a problem, you can start it (say, -hourly or nightly) from cron, and it will fail if it is already running -(provided that you haven't disabled or deleted the lock file). - -If it is used as a server, it should be started from any suitable system -initialisation script, just like any other daemon. It must be started after -the networking, of course. To run it in both server modes, start one copy with -the -B option and one with the -S option. - - -Simple Examples of Use ----------------------- - -Many people use it solely to check the time of their system, especially as a -cross-check on ntpd. You do not need privilege and it will not cause trouble -to the local network, so you can use it on someone else's system! You can -specify one server or several. For example: - - msntp ntp.server.local ntp.server.neighbour - -You can use it to check how your system is drifting, but it isn't very good at -this if the system is drifting very badly (in which case use the previous -technique and dc) or if you are running ntp. You do not need privilege and it -will not cause trouble to the local network. For example: - - sntp -x 120 -f /tmp/msntp.state ntp.server.local - -More generally, it is used to synchronise the clock, in which case you DO need -root privilege. It can be used in many ways, but the author favours running it -in daemon mode, started from a cron job, which will restart after power cuts -with no attention, and send a mail message (if cron is configured to do that) -when it fails badly. For example, the author uses a root crontab entry on one -system of: - - 15 0 * * * /bin/nice --10 /usr/local/bin/sntp -a -x 480 ntp.server.local - -If you have a home computer, it can be set up to resynchronise each time you -dial up. For example, the author uses a /etc/ppp/ip-up.d/sntp file on his -home Linux system of: - - #!/bin/sh - sleep 60 - /bin/nice --10 /usr/local/sbin/sntp -r -P 60 ntp.server.local - --a would be better, but adjtime is broken in Linux. - - -Debugging or Hacking the Program --------------------------------- - -Almost everybody who does this is likely to need to modify only the system -interfaces. While they are messy, they are pretty simple and have a simple -specification. This is documented in comments in the source. This is -described above. - -The main program SHOULD need no attention, though it may need the odd tweak to -bypass compiler problems - please report these, if you encounter any. If -something looks odd while it is running, start by setting the -v option (lower -case), as for investigating network problems, and checking any diagnostics that -appear. Note that most of it can be checked in display mode without harming -your system. - -The client will sometimes give up, complaining about inconsistent timestamps or -similar. This can be caused by the server being rebooted and similar glitches -to the time - unfortunately, there is no reliable way to tell an ignorable -fluctuation from a server up the spout. If this happens annoyingly often, -the -V option may help tie down the problem. In actual use, it is simplest -just to restart the client in a cron job! - -If it needs more than this, then you will need to debug the source seriously. -Start by putting an icepack on your head and pouring yourself a large whisky! -While it is commented, it is not well commented, and much of the code interacts -in complex and horrible ways. This isn't so much because it lacks 'structure' -as because one part needs to make assumptions about the numerical properties of -another. - -The -W option (upper case) will print out a complete trace of everything it -does, and this should be enough to tie down the problem. It does distort the -timing a bit, but not usually too badly. However, wading through that amount -of gibberish (let alone looking at the source) is not a pleasant task. If you -are pretty sure that you have a bug, you may tell the author, and he may ask -for a copy of the output - but he will reply rudely if you send thousands of -lines of tracing to him by Email! - -Note that there are a fair number of circumstances where its error recovery -could be better, but is left as it is to keep the code simple. Most of these -should be pretty rare. - - -Changes in Version 1.2 ----------------------- - -The main change was the addition of the daemon mode for drift correction (i.e. -the -x option). The daemon code is complex and has a lot of special-casing for -strange circumstances, not all of which are testable in practice. - -A lot of the code was reordered while doing this. The output was slightly -different - considerably different with -V. - -The error estimation for broadcasts was modified, and should bear more relation -to reality. It remains a guess, as there is no way to get decent error error -estimates under such circumstances. - -The -B option is now in minutes, and has a different permissible range and -default value. - -The argument consistency checking for broadcasts was tightened up a bit, and a -few other internal checks added. These should not affect any reasonable -requirement. - -A couple of new functions were added to the portability base, but they don't -use any non-standard new facilities. However, the specification of the -functions has changed slightly. - - -Changes in Version 1.3 ----------------------- - -The main change was the addition of the restarting facility for daemon mode -(i.e. the -f option), which is pretty straightforward. - -There were also a lot of minor changes to the paranoia code in daemon mode, to -try to separate out the case of a demented server from network and other -'ignorable' problems. These are not entirely successful. - - -Changes in Version 1.4 and 1.5 ------------------------------- - -There turned out to be a couple of places where the author misunderstood the -specification of NTP, which affect only its use in server mode. The main -change is to use stratum 15 instead of stratum 0. - -And there were some more relaxations of the paranoia code, to allow for more -erratic servers, plus a kludge to improve restarting in daemon mode after a -period of down time has unsynchronised the clock. There is also an -incompatible change to the debugging options to add a new level - the old -V -option is now -W, and -V is an intermediate one for debugging daemon mode - but -they are both hacker's facilities, and not for normal use. - -Version 1.5 adds some very minor fixes. - - -Changes in Version 1.6 ----------------------- - -The first change is support for multiple server addresses - it uses these in a -round-robin fashion. This may be useful when you have access to several -servers, all of which are a bit iffy. This means that the restart file format -is incompatible with msntp 1.5. - -It has also been modified to reset itself automatically after detecting an -inconsistency in its server's timestamps, because the author got sick of the -failures. It writes a comment to syslog (uniquely) in such cases. - -The ability to query a daemon save file was added. - -Related to the above, the -E argument has been redefined to mean an error bound -on various internal times (which is what it had become, anyway) and a -P option -introduced to be what the -E argument was documented to be. - -The lock and save file handling have been changed to allow defaults to be set -at installation time, and to be overridable at run-time. To disable these -at either stage, simply set the file names to the null string. - -And there have been the usual changes for portability, as standards have been -modified and/or introduced. - - -Future Versions ---------------- - -There are unlikely to be any, except probably one to fix bugs in version 1.6. - -I attempted to put support for intermittent connexions (e.g. dial-up) into the -daemon mode, but doing so needs so much code reorganisation that it isn't worth -it. What needs doing for that is to separate the socket handling from the -timekeeping, so that they can be run asynchronously (either in separate -processes or threads), and to look up a network name and open a socket only -when prodded (and to close it immediately thereafter). So just running it -with the -r option is the current best solution. - -I also attempted to put support for the "Unix 2000" interfaces into the code. -Ha, ha. Not merely do very few systems define socklen_t (needed for IPv6 -support), but "Unix 2000" neither addresses the leap second problem nor even -provides an adjtime replacement! Some function like the latter is critical, -not so much because of the gradual change, but because of its atomicity; -without it, msntp really needs to be made non-interruptible, and that brings in -a ghastly number of system-dependencies. - -Realistically, it needs a complete rewrite before adding any more function. -And, worse, the Unix 'standards' need fixing, too. - - - -Miscellaneous -------------- - -Thanks are due to Douglas M. Wells of Connection Technologies for helping the -author with several IP-related conventions, to Sam Nelson of Stirling -University for testing it on some very strange systems, and to David Mills for -clarifying what the NTP specification really is. - -Thanks are also due to several other people with locating bugs, finding -appropriate options for the Makefile and passing on extension code and -suggestions. As I am sure to leave someone out, I shall not name anyone else. - -Version 1.0 - October 1996. -Version 1.1 - November 1996 - mainly portability improvements. -Version 1.2 - January 1997 - mainly drift handling, but much reorganisation. -Version 1.3 - February 1997 - daemon save file, and some robustness changes. -Version 1.4 - May 1997 - relatively minor fixes, more diagnostic levels etc. -Version 1.5 - December 1997 - some very minor fixes -Version 1.6 - October 2000 - quite a few miscellaneous changes - - -Nick Maclaren, -University of Cambridge Computer Laboratory, -New Museums Site, Pembroke Street, Cambridge CB2 3QG, England. -Email: nmm1@cam.ac.uk -Tel.: +44 1223 334761 Fax: +44 1223 334679 diff -urN src/contrib/ntp/sntp/aclocal.m4 src.ntp/contrib/ntp/sntp/aclocal.m4 --- src/contrib/ntp/sntp/aclocal.m4 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/aclocal.m4 2010-07-09 04:24:39.000000000 +0200 @@ -6570,18 +6570,6 @@ [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) ]) -# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005 -# Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# serial 8 - -# AM_CONFIG_HEADER is obsolete. It has been replaced by AC_CONFIG_HEADERS. -AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)]) - # Do all the work for Automake. -*- Autoconf -*- # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, @@ -7126,3 +7114,6 @@ ]) # _AM_PROG_TAR m4_include([libopts/m4/libopts.m4]) +m4_include([../m4/ntp_cacheversion.m4]) +m4_include([../m4/ntp_dir_sep.m4]) +m4_include([../m4/ntp_openssl.m4]) diff -urN src/contrib/ntp/sntp/bincheck.mf src.ntp/contrib/ntp/sntp/bincheck.mf --- src/contrib/ntp/sntp/bincheck.mf 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/bincheck.mf 2010-07-09 04:17:43.000000000 +0200 @@ -3,11 +3,11 @@ # subdir to warn folks if there is another version there. install-exec-hook: - @case ${BINSUBDIR} in \ - bin) ODIR=${exec_prefix}/sbin ;; \ - sbin) ODIR=${exec_prefix}/bin ;; \ - esac; \ - test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ + @case ${BINSUBDIR} in \ + bin) ODIR=${sbindir} ;; \ + sbin) ODIR=${bindir} ;; \ + esac; \ + test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ test ! -f $$ODIR/$$i || echo "*** $$i is also in $$ODIR!"; \ done diff -urN src/contrib/ntp/sntp/config.h.in src.ntp/contrib/ntp/sntp/config.h.in --- src/contrib/ntp/sntp/config.h.in 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/config.h.in 2010-07-09 04:25:38.000000000 +0200 @@ -1,16 +1,16 @@ /* config.h.in. Generated from configure.ac by autoheader. */ +/* Directory separator character, usually / or \\ */ +#undef DIR_SEP + /* fopen(3) accepts a 'b' in the mode flag */ #undef FOPEN_BINARY_FLAG /* fopen(3) accepts a 't' in the mode flag */ #undef FOPEN_TEXT_FLAG -/* Define to 1 if you have the `alarm' function. */ -#undef HAVE_ALARM - -/* Define to 1 if you have the header file. */ -#undef HAVE_ARPA_INET_H +/* What is getsockname()'s socklen type? */ +#undef GETSOCKNAME_SOCKLEN_TYPE /* Define to 1 if you have the `canonicalize_file_name' function. */ #undef HAVE_CANONICALIZE_FILE_NAME @@ -34,14 +34,8 @@ /* Define to 1 if you have the header file. */ #undef HAVE_FCNTL_H -/* Define to 1 if you have the header file. */ -#undef HAVE_FLOAT_H - -/* Define to 1 if you have the `gettimeofday' function. */ -#undef HAVE_GETTIMEOFDAY - -/* Define to 1 if you have the `inet_ntoa' function. */ -#undef HAVE_INET_NTOA +/* Define to 1 if you have the `fork' function. */ +#undef HAVE_FORK /* inline keyword or macro available */ #undef HAVE_INLINE @@ -73,9 +67,6 @@ /* Define to 1 if you have the header file. */ #undef HAVE_MEMORY_H -/* Define to 1 if you have the `memset' function. */ -#undef HAVE_MEMSET - /* Define to 1 if you have the `mmap' function. */ #undef HAVE_MMAP @@ -88,30 +79,39 @@ /* Define to 1 if you have the header file. */ #undef HAVE_NETINET_IN_H +/* sntp does not care about 'nice' */ +#undef HAVE_NO_NICE + /* Define this if pathfind(3) works */ #undef HAVE_PATHFIND +/* Define to 1 if the system has the type `pid_t'. */ +#undef HAVE_PID_T + /* Define this if we have a functional realpath(3C) */ #undef HAVE_REALPATH +/* Define to 1 if you have the header file. */ +#undef HAVE_RUNETYPE_H + /* Define to 1 if you have the header file. */ #undef HAVE_SETJMP_H +/* Define to 1 if the system has the type `size_t'. */ +#undef HAVE_SIZE_T + /* Define to 1 if you have the `snprintf' function. */ #undef HAVE_SNPRINTF /* Define to 1 if you have the `socket' function. */ #undef HAVE_SOCKET -/* Define to 1 if you have the `sqrt' function. */ -#undef HAVE_SQRT - -/* Does struct sockaddr_storage have ss_family? */ -#undef HAVE_SS_FAMILY_IN_SS - /* Define to 1 if you have the header file. */ #undef HAVE_STDARG_H +/* Define to 1 if stdbool.h conforms to C99. */ +#undef HAVE_STDBOOL_H + /* Define to 1 if you have the header file. */ #undef HAVE_STDINT_H @@ -136,6 +136,12 @@ /* Define to 1 if you have the `strrchr' function. */ #undef HAVE_STRRCHR +/* Define to 1 if you have the `strsignal' function. */ +#undef HAVE_STRSIGNAL + +/* Does a system header define struct sockaddr_storage? */ +#undef HAVE_STRUCT_SOCKADDR_STORAGE + /* Define to 1 if you have the header file. */ #undef HAVE_SYSEXITS_H @@ -189,6 +195,12 @@ /* Define to 1 if you have the header file. */ #undef HAVE_SYS_WAIT_H +/* Define to 1 if the system has the type `s_char'. */ +#undef HAVE_S_CHAR + +/* sntp does not care about TTY stuff */ +#undef HAVE_TERMIOS + /* Define to 1 if the system has the type `uint16_t'. */ #undef HAVE_UINT16_T @@ -216,17 +228,108 @@ /* Define to 1 if you have the header file. */ #undef HAVE_VARARGS_H +/* Define to 1 if you have the `vfork' function. */ +#undef HAVE_VFORK + +/* Define to 1 if you have the header file. */ +#undef HAVE_VFORK_H + /* Define to 1 if you have the `vprintf' function. */ #undef HAVE_VPRINTF +/* Define to 1 if you have the `vsnprintf' function. */ +#undef HAVE_VSNPRINTF + +/* Define to 1 if you have the `vsprintf' function. */ +#undef HAVE_VSPRINTF + +/* Define to 1 if you have the header file. */ +#undef HAVE_WCHAR_H + +/* Define to 1 if the system has the type `wchar_t'. */ +#undef HAVE_WCHAR_T + +/* Define to 1 if the system has the type `wint_t'. */ +#undef HAVE_WINT_T + +/* Define to 1 if `fork' works. */ +#undef HAVE_WORKING_FORK + +/* Define to 1 if `vfork' works. */ +#undef HAVE_WORKING_VFORK + +/* Define to 1 if the system has the type `_Bool'. */ +#undef HAVE__BOOL + /* Does struct sockaddr_storage have __ss_family? */ #undef HAVE___SS_FAMILY_IN_SS + + /* Handle sockaddr_storage.__ss_family */ + #ifdef HAVE___SS_FAMILY_IN_SS + # define ss_family __ss_family + #endif /* HAVE___SS_FAMILY_IN_SS */ + + + +/* Does struct sockaddr_storage have __ss_len? */ +#undef HAVE___SS_LEN_IN_SS + + + /* Handle sockaddr_storage.__ss_len */ + #ifdef HAVE___SS_LEN_IN_SS + # define ss_len __ss_len + #endif /* HAVE___SS_LEN_IN_SS */ + + + +/* Do we need to fix in6isaddr? */ +#undef ISC_PLATFORM_FIXIN6ISADDR + +/* have struct if_laddrconf? */ +#undef ISC_PLATFORM_HAVEIF_LADDRCONF + +/* have struct if_laddrreq? */ +#undef ISC_PLATFORM_HAVEIF_LADDRREQ + +/* have struct in6_pktinfo? */ +#undef ISC_PLATFORM_HAVEIN6PKTINFO + +/* have IPv6? */ +#undef ISC_PLATFORM_HAVEIPV6 + +/* have sin6_scope_id? */ +#undef ISC_PLATFORM_HAVESCOPEID + +/* missing in6addr_any? */ +#undef ISC_PLATFORM_NEEDIN6ADDRANY + +/* Do we need netinet6/in6.h? */ +#undef ISC_PLATFORM_NEEDNETINET6IN6H + +/* ISC: provide inet_ntop() */ +#undef ISC_PLATFORM_NEEDNTOP + +/* Declare in_port_t? */ +#undef ISC_PLATFORM_NEEDPORTT + +/* ISC: provide inet_pton() */ +#undef ISC_PLATFORM_NEEDPTON + +/* Do we need netinet6/in6.h? */ +#undef LWRES_PLATFORM_NEEDNETINET6IN6H + +/* Does the target support multicast IP? */ +#undef MCAST + +/* Do we need an s_char typedef? */ +#undef NEED_S_CHAR_TYPEDEF + /* Define this if optional arguments are disallowed */ #undef NO_OPTIONAL_OPT_ARGS -/* Should we avoid #warning on option name collisions? */ -#undef NO_OPTION_NAME_WARNINGS +/* Use OpenSSL? */ +#undef OPENSSL /* Name of package */ #undef PACKAGE @@ -252,9 +355,6 @@ /* name of regex header file */ #undef REGEX_HEADER -/* Define as the return type of signal handlers (`int' or `void'). */ -#undef RETSIGTYPE - /* The size of `char*', as computed by sizeof. */ #undef SIZEOF_CHARP @@ -267,38 +367,55 @@ /* The size of `short', as computed by sizeof. */ #undef SIZEOF_SHORT +/* The size of `signed char', as computed by sizeof. */ +#undef SIZEOF_SIGNED_CHAR + /* Define to 1 if you have the ANSI C header files. */ #undef STDC_HEADERS +/* canonical system (cpu-vendor-os) of where we should run */ +#undef STR_SYSTEM + /* Define to 1 if you can safely include both and . */ #undef TIME_WITH_SYS_TIME -/* Define to 1 if your declares `struct tm'. */ -#undef TM_IN_SYS_TIME +/* What type to use for setsockopt */ +#undef TYPEOF_IP_MULTICAST_LOOP /* Version number of package */ #undef VERSION +/* ISC: Want IPv6? */ +#undef WANT_IPV6 + /* Define this if a working libregex can be found */ #undef WITH_LIBREGEX +/* Define to 1 if type `char' is unsigned and you are not using gcc. */ +#ifndef __CHAR_UNSIGNED__ +# undef __CHAR_UNSIGNED__ +#endif + /* Define to empty if `const' does not conform to ANSI C. */ #undef const +/* Define to `int' if doesn't define. */ +#undef gid_t + /* Define to `__inline__' or `__inline' if that's what the C compiler calls it, or to nothing if 'inline' is not supported under any name. */ #ifndef __cplusplus #undef inline #endif +/* Define to `int' if does not define. */ +#undef pid_t + /* Define to `unsigned int' if does not define. */ #undef size_t -/* normalize ss_family access */ -#undef ss_family - -/* normalize ss_len access */ -#undef ss_len +/* Define to `int' if doesn't define. */ +#undef uid_t -/* Alternate uintptr_t for systems without it. */ -#undef uintptr_t +/* Define as `fork' if `vfork' does not work. */ +#undef vfork diff -urN src/contrib/ntp/sntp/configure src.ntp/contrib/ntp/sntp/configure --- src/contrib/ntp/sntp/configure 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/configure 2010-07-09 04:24:46.000000000 +0200 @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.65. +# Generated by GNU Autoconf 2.65 for sntp 4.2.6p2. # # # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, @@ -697,15 +697,13 @@ MAKEFLAGS= # Identity of this package. -PACKAGE_NAME= -PACKAGE_TARNAME= -PACKAGE_VERSION= -PACKAGE_STRING= -PACKAGE_BUGREPORT= -PACKAGE_URL= +PACKAGE_NAME='sntp' +PACKAGE_TARNAME='sntp' +PACKAGE_VERSION='4.2.6p2' +PACKAGE_STRING='sntp 4.2.6p2' +PACKAGE_BUGREPORT='' +PACKAGE_URL='' -ac_unique_file="main.c" -ac_unique_file="header.h" # Factoring default headers for most tests. ac_includes_default="\ #include @@ -746,23 +744,29 @@ am__EXEEXT_TRUE LTLIBOBJS LIBOBJS +NTP_BINSUBDIR_IS_BIN_FALSE +NTP_BINSUBDIR_IS_BIN_TRUE BINSUBDIR +LCRYPTO +OPENSSL_LIB +OPENSSL_INC +OPENSSL HAVE_INLINE -LIBOPTS_CFLAGS -LIBOPTS_LDADD -NEED_LIBOPTS_FALSE -NEED_LIBOPTS_TRUE -INSTALL_LIBOPTS_FALSE -INSTALL_LIBOPTS_TRUE -LIBOPTS_DIR LIBTOOL -CPP RANLIB AR ECHO LN_S EGREP GREP +CPP +LIBOPTS_CFLAGS +LIBOPTS_LDADD +NEED_LIBOPTS_FALSE +NEED_LIBOPTS_TRUE +INSTALL_LIBOPTS_FALSE +INSTALL_LIBOPTS_TRUE +LIBOPTS_DIR am__fastdepCC_FALSE am__fastdepCC_TRUE CCDEPMODE @@ -853,12 +857,6 @@ enable_option_checking enable_dependency_tracking enable_shared -enable_static -enable_fast_install -with_gnu_ld -enable_libtool_lock -with_pic -with_tags enable_local_libopts enable_libopts_install with_autoopts_config @@ -867,6 +865,17 @@ with_libregex_cflags with_libregex_libs enable_optional_args +enable_static +enable_fast_install +with_gnu_ld +enable_libtool_lock +with_pic +with_tags +with_openssl_libdir +with_openssl_incdir +with_crypto +enable_ipv6 +with_kame with_binsubdir ' ac_precious_vars='build_alias @@ -918,7 +927,7 @@ localstatedir='${prefix}/var' includedir='${prefix}/include' oldincludedir='/usr/include' -docdir='${datarootdir}/doc/${PACKAGE}' +docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' infodir='${datarootdir}/info' htmldir='${docdir}' dvidir='${docdir}' @@ -1419,7 +1428,7 @@ # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures this package to adapt to many kinds of systems. +\`configure' configures sntp 4.2.6p2 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1467,7 +1476,7 @@ --infodir=DIR info documentation [DATAROOTDIR/info] --localedir=DIR locale-dependent data [DATAROOTDIR/locale] --mandir=DIR man documentation [DATAROOTDIR/man] - --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE] + --docdir=DIR documentation root [DATAROOTDIR/doc/sntp] --htmldir=DIR html documentation [DOCDIR] --dvidir=DIR dvi documentation [DOCDIR] --pdfdir=DIR pdf documentation [DOCDIR] @@ -1488,7 +1497,9 @@ fi if test -n "$ac_init_help"; then - + case $ac_init_help in + short | recursive ) echo "Configuration of sntp 4.2.6p2:";; + esac cat <<\_ACEOF Optional Features: @@ -1498,27 +1509,32 @@ --disable-dependency-tracking speeds up one-time build --enable-dependency-tracking do not reject slow dependency extractors --enable-shared[=PKGS] build shared libraries [default=no] - --enable-static[=PKGS] build static libraries [default=yes] - --enable-fast-install[=PKGS] - optimize for fast installation [default=yes] - --disable-libtool-lock avoid locking (might break parallel builds) --enable-local-libopts Force using the supplied libopts tearoff code --disable-libopts-install Do not install libopts with client installation --disable-optional-args not wanting optional option args + --enable-static[=PKGS] build static libraries [default=yes] + --enable-fast-install[=PKGS] + optimize for fast installation [default=yes] + --disable-libtool-lock avoid locking (might break parallel builds) + --enable-ipv6 s use IPv6? Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) - --with-gnu-ld assume the C compiler uses GNU ld [default=no] - --with-pic try to use only PIC/non-PIC objects [default=use - both] - --with-tags[=TAGS] include additional configurations [automatic] --with-autoopts-config specify the config-info script --with-regex-header a reg expr header is specified --with-libregex libregex installation prefix --with-libregex-cflags libregex compile flags --with-libregex-libs libregex link command arguments + --with-gnu-ld assume the C compiler uses GNU ld [default=no] + --with-pic try to use only PIC/non-PIC objects [default=use + both] + --with-tags[=TAGS] include additional configurations [automatic] + --with-openssl-libdir + =/something/reasonable + --with-openssl-incdir + =/something/reasonable + --with-crypto + =openssl + --with-kame - =/usr/local/v6 --with-binsubdir bin ={bin,sbin} Some influential environment variables: @@ -1597,7 +1613,7 @@ test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -configure +sntp configure 4.2.6p2 generated by GNU Autoconf 2.65 Copyright (C) 2009 Free Software Foundation, Inc. @@ -1649,21 +1665,20 @@ } # ac_fn_c_try_compile -# ac_fn_c_try_link LINENO -# ----------------------- -# Try to link conftest.$ac_ext, and return whether this succeeded. -ac_fn_c_try_link () +# ac_fn_c_try_cpp LINENO +# ---------------------- +# Try to preprocess conftest.$ac_ext, and return whether this succeeded. +ac_fn_c_try_cpp () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - rm -f conftest.$ac_objext conftest$ac_exeext - if { { ac_try="$ac_link" + if { { ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>conftest.err + (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 @@ -1671,44 +1686,79 @@ mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { - test -z "$ac_c_werror_flag" || + test $ac_status = 0; } >/dev/null && { + test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext }; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - ac_retval=1 + ac_retval=1 fi - # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information - # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would - # interfere with the next link command; also delete a directory that is - # left behind by Apple's compiler. We do this before executing the actions. - rm -rf conftest.dSYM conftest_ipa8_conftest.oo eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} as_fn_set_status $ac_retval -} # ac_fn_c_try_link +} # ac_fn_c_try_cpp -# ac_fn_c_try_cpp LINENO +# ac_fn_c_try_run LINENO # ---------------------- -# Try to preprocess conftest.$ac_ext, and return whether this succeeded. -ac_fn_c_try_cpp () +# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes +# that executables *can* be run. +ac_fn_c_try_run () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if { { ac_try="$ac_cpp conftest.$ac_ext" + if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err + (eval "$ac_link") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' + { { case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_try") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; }; then : + ac_retval=0 +else + $as_echo "$as_me: program exited with status $ac_status" >&5 + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=$ac_status +fi + rm -rf conftest.dSYM conftest_ipa8_conftest.oo + eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + as_fn_set_status $ac_retval + +} # ac_fn_c_try_run + +# ac_fn_c_try_link LINENO +# ----------------------- +# Try to link conftest.$ac_ext, and return whether this succeeded. +ac_fn_c_try_link () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + rm -f conftest.$ac_objext conftest$ac_exeext + if { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 @@ -1716,21 +1766,29 @@ mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } >/dev/null && { - test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || + test $ac_status = 0; } && { + test -z "$ac_c_werror_flag" || test ! -s conftest.err + } && test -s conftest$ac_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext }; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - ac_retval=1 + ac_retval=1 fi + # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information + # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would + # interfere with the next link command; also delete a directory that is + # left behind by Apple's compiler. We do this before executing the actions. + rm -rf conftest.dSYM conftest_ipa8_conftest.oo eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} as_fn_set_status $ac_retval -} # ac_fn_c_try_cpp +} # ac_fn_c_try_link # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES # ------------------------------------------------------- @@ -1819,48 +1877,6 @@ } # ac_fn_c_check_header_mongrel -# ac_fn_c_try_run LINENO -# ---------------------- -# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes -# that executables *can* be run. -ac_fn_c_try_run () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' - { { case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; }; then : - ac_retval=0 -else - $as_echo "$as_me: program exited with status $ac_status" >&5 - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=$ac_status -fi - rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} - as_fn_set_status $ac_retval - -} # ac_fn_c_try_run - # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES # ------------------------------------------------------- # Tests whether HEADER exists and can be compiled using the include files in @@ -1892,73 +1908,6 @@ } # ac_fn_c_check_header_compile -# ac_fn_c_check_func LINENO FUNC VAR -# ---------------------------------- -# Tests whether FUNC exists, setting the cache variable VAR accordingly -ac_fn_c_check_func () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -/* Define $2 to an innocuous variant, in case declares $2. - For example, HP-UX 11i declares gettimeofday. */ -#define $2 innocuous_$2 - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $2 (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $2 - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $2 (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$2 || defined __stub___$2 -choke me -#endif - -int -main () -{ -return $2 (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - eval "$3=yes" -else - eval "$3=no" -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} - -} # ac_fn_c_check_func - # ac_fn_c_check_type LINENO TYPE VAR INCLUDES # ------------------------------------------- # Tests whether TYPE exists after having included INCLUDES, setting cache @@ -2190,11 +2139,78 @@ as_fn_set_status $ac_retval } # ac_fn_c_compute_int -cat >config.log <<_ACEOF -This file contains any messages produced by compilers while -running configure, to aid debugging if configure makes a mistake. -It was created by $as_me, which was +# ac_fn_c_check_func LINENO FUNC VAR +# ---------------------------------- +# Tests whether FUNC exists, setting the cache variable VAR accordingly +ac_fn_c_check_func () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* Define $2 to an innocuous variant, in case declares $2. + For example, HP-UX 11i declares gettimeofday. */ +#define $2 innocuous_$2 + +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char $2 (); below. + Prefer to if __STDC__ is defined, since + exists even on freestanding compilers. */ + +#ifdef __STDC__ +# include +#else +# include +#endif + +#undef $2 + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char $2 (); +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined __stub_$2 || defined __stub___$2 +choke me +#endif + +int +main () +{ +return $2 (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + eval "$3=yes" +else + eval "$3=no" +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + +} # ac_fn_c_check_func +cat >config.log <<_ACEOF +This file contains any messages produced by compilers while +running configure, to aid debugging if configure makes a mistake. + +It was created by sntp $as_me 4.2.6p2, which was generated by GNU Autoconf 2.65. Invocation command line was $ $0 $@ @@ -2541,10 +2557,9 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu -am__api_version='1.11' ac_aux_dir= -for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do +for ac_dir in . "$srcdir"/.; do for ac_t in install-sh install.sh shtool; do if test -f "$ac_dir/$ac_t"; then ac_aux_dir=$ac_dir @@ -2554,7 +2569,7 @@ done done if test -z "$ac_aux_dir"; then - as_fn_error "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5 + as_fn_error "cannot find install-sh, install.sh, or shtool in . \"$srcdir\"/." "$LINENO" 5 fi # These three variables are undocumented and unsupported, @@ -2566,6 +2581,132 @@ ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. + +# Increment sntp_configure_cache_version by one for each change to +# configure.ac or .m4 files which invalidates cached values from +# previous versions. +# +# If the change affects cache variables used only by the main NTP +# configure.ac, then only its version number should be bumped, while +# the subdir configure.ac version numbers should be unchanged. The +# same is true for a test/variable that is used only by one subdir +# being changed incompatibly; only that subdir's cache version needs +# bumping. +# +# If a change affects variables shared by all NTP configure scripts, +# please bump the version numbers of all three. If you are not sure, +# the safe choice is to bump all three on any cache-invalidating change. +# +# In order to avoid the risk of version stamp collision between -stable +# and -dev branches, do not simply increment the version, instead use +# the date YYYYMMDD optionally with -HHMM if there is more than one +# bump in a day. + +sntp_configure_cache_version=20091117 + +# When the version of config.cache and configure do not +# match, NTP_CACHEVERSION will flush the cache. + + + + ntp_cache_flush=1 + + case "$ntp_cv_sntp_cache_version" in + $sntp_configure_cache_version) + # same version, good + ntp_cache_flush=0 + ;; + '') + # No cache, predates ntp_cv_sntp_cache_version, or is empty. + case "$cache_file" in + /dev/null) + ntp_cache_flush=0 + ;; + *) + case "$NTP_CACHEVERSION_PARENT" in + '') + # Do not clear the cache immediately after it is created + # empty as it is noisy. Differentiate a newly-created + # config.cache from one predating the cache version + # mechanism by looking for the first cached variable set + # by Autoconf + case "$ac_cv_path_install" in + '') + # empty config.cache file + ntp_cache_flush=0 + esac + ;; + *) + # Parent configure just created cache from empty, + # flushing would be counterproductive. + ntp_cache_flush=0; + esac + esac + ;; + *) + # configure cache version mismatches config.cache version + esac + + case "$ntp_cache_flush" in + 1) + c_version="${ntp_cv_sntp_cache_version:-(no version found)}" + + # Do we flush all variables or exclude others' version stamps? + + case "$NTP_CACHEVERSION_PARENT" in + '') + # Clear all *_cv_* variables including our child subdirs' + # ntp_cv_*_cache_version variables. This prevents subdir + # configure scripts from noticing a version mismatch just + # after the top configure in the invocation cleared and + # recreated the cache. + + c_varname_list=`set | + sed -n -e 's/=.*$//' \ + -e '/_cv_/p' + ` + ;; + *) + # This is not the top configure this particular invocation. + # Clear all *_cv_* variables sparing the version stamps + # of other configure scripts, so we don't trigger + # useless repeated clearings. + + c_varname_list=`set | + sed -n -e 's/=.*$//' \ + -e '/ntp_cv_.*_cache_version/d' \ + -e '/_cv_/p' + ` + esac + + for c_varname in $c_varname_list + do + eval ${c_varname}=; $as_unset $c_varname + done + + c_varname_list=; $as_unset c_varname_list c_varname + + { $as_echo "$as_me:${as_lineno-$LINENO}: $cache_file saved by another version, ignored." >&5 +$as_echo "$as_me: $cache_file saved by another version, ignored." >&6;} + { $as_echo "$as_me:${as_lineno-$LINENO}: configure script cache version: $sntp_configure_cache_version" >&5 +$as_echo "$as_me: configure script cache version: $sntp_configure_cache_version" >&6;} + { $as_echo "$as_me:${as_lineno-$LINENO}: $cache_file version: $c_version" >&5 +$as_echo "$as_me: $cache_file version: $c_version" >&6;} + $as_unset c_version + esac + + # save configure version in config.cache for next time + ntp_cv_sntp_cache_version="$sntp_configure_cache_version" + + $as_unset ntp_cache_flush + + # let any subdir configure.ac NTP_CACHEVERSION invocations + # know they are not the top level. + NTP_CACHEVERSION_PARENT='sntp' ; export NTP_CACHEVERSION_PARENT + + +am__api_version='1.11' + # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or # incompatible versions: @@ -3001,8 +3142,8 @@ # Define the identity of the package. - PACKAGE=msntp - VERSION=1.6 + PACKAGE='sntp' + VERSION='4.2.6p2' cat >>confdefs.h <<_ACEOF @@ -3042,7 +3183,6 @@ - # Make sure we can run config.sub. $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 @@ -3114,9 +3254,15 @@ case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac + +cat >>confdefs.h <<_ACEOF +#define STR_SYSTEM "$host" +_ACEOF + ac_config_headers="$ac_config_headers config.h" + # Checks for programs. ac_ext=c ac_cpp='$CPP $CPPFLAGS' @@ -4099,776 +4245,953 @@ -# So far, the only shared library we might use is libopts. -# It's a small library - we might as well use a static version of it. -# Check whether --enable-shared was given. -if test "${enable_shared+set}" = set; then : - enableval=$enable_shared; p=${PACKAGE-default} - case $enableval in - yes) enable_shared=yes ;; - no) enable_shared=no ;; - *) - enable_shared=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_shared=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac +# AC_PROG_CC_STDC has two functions. It attempts to find a compiler +# capable of C99, or failing that, for C89. CC is set afterward with +# the selected invocation, such as "gcc --std=gnu99". Also, the +# ac_cv_prog_cc_stdc variable is no if the compiler selected for CC +# does not accept C89. + + case $ac_cv_prog_cc_stdc in #( + no) : + ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #( + *) : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5 +$as_echo_n "checking for $CC option to accept ISO C99... " >&6; } +if test "${ac_cv_prog_cc_c99+set}" = set; then : + $as_echo_n "(cached) " >&6 else - enable_shared=no -fi + ac_cv_prog_cc_c99=no +ac_save_CC=$CC +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#include +#include +#include +// Check varargs macros. These examples are taken from C99 6.10.3.5. +#define debug(...) fprintf (stderr, __VA_ARGS__) +#define showlist(...) puts (#__VA_ARGS__) +#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__)) +static void +test_varargs_macros (void) +{ + int x = 1234; + int y = 5678; + debug ("Flag"); + debug ("X = %d\n", x); + showlist (The first, second, and third items.); + report (x>y, "x is %d but y is %d", x, y); +} +// Check long long types. +#define BIG64 18446744073709551615ull +#define BIG32 4294967295ul +#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0) +#if !BIG_OK + your preprocessor is broken; +#endif +#if BIG_OK +#else + your preprocessor is broken; +#endif +static long long int bignum = -9223372036854775807LL; +static unsigned long long int ubignum = BIG64; +struct incomplete_array +{ + int datasize; + double data[]; +}; +struct named_init { + int number; + const wchar_t *name; + double average; +}; +typedef const char *ccp; +static inline int +test_restrict (ccp restrict text) +{ + // See if C++-style comments work. + // Iterate through items via the restricted pointer. + // Also check for declarations in for loops. + for (unsigned int i = 0; *(text+i) != '\0'; ++i) + continue; + return 0; +} -# Check whether --enable-static was given. -if test "${enable_static+set}" = set; then : - enableval=$enable_static; p=${PACKAGE-default} - case $enableval in - yes) enable_static=yes ;; - no) enable_static=no ;; - *) - enable_static=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_static=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac -else - enable_static=yes -fi +// Check varargs and va_copy. +static void +test_varargs (const char *format, ...) +{ + va_list args; + va_start (args, format); + va_list args_copy; + va_copy (args_copy, args); + + const char *str; + int number; + float fnumber; + while (*format) + { + switch (*format++) + { + case 's': // string + str = va_arg (args_copy, const char *); + break; + case 'd': // int + number = va_arg (args_copy, int); + break; + case 'f': // float + fnumber = va_arg (args_copy, double); + break; + default: + break; + } + } + va_end (args_copy); + va_end (args); +} -# Check whether --enable-fast-install was given. -if test "${enable_fast_install+set}" = set; then : - enableval=$enable_fast_install; p=${PACKAGE-default} - case $enableval in - yes) enable_fast_install=yes ;; - no) enable_fast_install=no ;; - *) - enable_fast_install=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_fast_install=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac -else - enable_fast_install=yes -fi +int +main () +{ + // Check bool. + _Bool success = false; -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 -$as_echo_n "checking for a sed that does not truncate output... " >&6; } -if test "${lt_cv_path_SED+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - # Loop through the user's path and test for sed and gsed. -# Then use that list of sed's as ones to test for truncation. -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for lt_ac_prog in sed gsed; do - for ac_exec_ext in '' $ac_executable_extensions; do - if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then - lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" - fi - done - done -done -lt_ac_max=0 -lt_ac_count=0 -# Add /usr/xpg4/bin/sed as it is typically found on Solaris -# along with /bin/sed that truncates output. -for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do - test ! -f $lt_ac_sed && continue - cat /dev/null > conftest.in - lt_ac_count=0 - echo $ECHO_N "0123456789$ECHO_C" >conftest.in - # Check for GNU sed and select it if it is found. - if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then - lt_cv_path_SED=$lt_ac_sed - break - fi - while true; do - cat conftest.in conftest.in >conftest.tmp - mv conftest.tmp conftest.in - cp conftest.in conftest.nl - echo >>conftest.nl - $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break - cmp -s conftest.out conftest.nl || break - # 10000 chars as input seems more than enough - test $lt_ac_count -gt 10 && break - lt_ac_count=`expr $lt_ac_count + 1` - if test $lt_ac_count -gt $lt_ac_max; then - lt_ac_max=$lt_ac_count - lt_cv_path_SED=$lt_ac_sed - fi - done -done + // Check restrict. + if (test_restrict ("String literal") == 0) + success = true; + char *restrict newvar = "Another string"; + + // Check varargs. + test_varargs ("s, d' f .", "string", 65, 34.234); + test_varargs_macros (); + + // Check flexible array members. + struct incomplete_array *ia = + malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10)); + ia->datasize = 10; + for (int i = 0; i < ia->datasize; ++i) + ia->data[i] = i * 1.234; + + // Check named initializers. + struct named_init ni = { + .number = 34, + .name = L"Test wide string", + .average = 543.34343, + }; + + ni.number = 58; + + int dynamic_array[ni.number]; + dynamic_array[ni.number - 1] = 543; + + // work around unused variable warnings + return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x' + || dynamic_array[ni.number - 1] != 543); + ; + return 0; +} +_ACEOF +for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99 +do + CC="$ac_save_CC $ac_arg" + if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_prog_cc_c99=$ac_arg fi +rm -f core conftest.err conftest.$ac_objext + test "x$ac_cv_prog_cc_c99" != "xno" && break +done +rm -f conftest.$ac_ext +CC=$ac_save_CC -SED=$lt_cv_path_SED -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $SED" >&5 -$as_echo "$SED" >&6; } - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 -$as_echo_n "checking for grep that handles long lines and -e... " >&6; } -if test "${ac_cv_path_GREP+set}" = set; then : +fi +# AC_CACHE_VAL +case "x$ac_cv_prog_cc_c99" in + x) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 +$as_echo "none needed" >&6; } ;; + xno) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 +$as_echo "unsupported" >&6; } ;; + *) + CC="$CC $ac_cv_prog_cc_c99" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5 +$as_echo "$ac_cv_prog_cc_c99" >&6; } ;; +esac +if test "x$ac_cv_prog_cc_c99" != xno; then : + ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99 +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 +$as_echo_n "checking for $CC option to accept ISO C89... " >&6; } +if test "${ac_cv_prog_cc_c89+set}" = set; then : $as_echo_n "(cached) " >&6 else - if test -z "$GREP"; then - ac_path_GREP_found=false - # Loop through the user's path and test for each of PROGNAME-LIST - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin + ac_cv_prog_cc_c89=no +ac_save_CC=$CC +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#include +#include +/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ +struct buf { int x; }; +FILE * (*rcsopen) (struct buf *, struct stat *, int); +static char *e (p, i) + char **p; + int i; +{ + return p[i]; +} +static char *f (char * (*g) (char **, int), char **p, ...) +{ + char *s; + va_list v; + va_start (v,p); + s = g (p, va_arg (v,int)); + va_end (v); + return s; +} + +/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has + function prototypes and stuff, but not '\xHH' hex character constants. + These don't provoke an error unfortunately, instead are silently treated + as 'x'. The following induces an error, until -std is added to get + proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an + array size at least. It's necessary to write '\x00'==0 to get something + that's true only with -std. */ +int osf4_cc_array ['\x00' == 0 ? 1 : -1]; + +/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters + inside strings and character constants. */ +#define FOO(x) 'x' +int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; + +int test (int i, double x); +struct s1 {int (*f) (int a);}; +struct s2 {int (*f) (double a);}; +int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); +int argc; +char **argv; +int +main () +{ +return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; + ; + return 0; +} +_ACEOF +for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ + -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in grep ggrep; do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" - { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue -# Check for GNU ac_path_GREP and select it if it is found. - # Check for GNU $ac_path_GREP -case `"$ac_path_GREP" --version 2>&1` in -*GNU*) - ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; -*) - ac_count=0 - $as_echo_n 0123456789 >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - $as_echo 'GREP' >> "conftest.nl" - "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_GREP_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_GREP="$ac_path_GREP" - ac_path_GREP_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac + CC="$ac_save_CC $ac_arg" + if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_prog_cc_c89=$ac_arg +fi +rm -f core conftest.err conftest.$ac_objext + test "x$ac_cv_prog_cc_c89" != "xno" && break +done +rm -f conftest.$ac_ext +CC=$ac_save_CC - $ac_path_GREP_found && break 3 - done - done - done -IFS=$as_save_IFS - if test -z "$ac_cv_path_GREP"; then - as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 - fi +fi +# AC_CACHE_VAL +case "x$ac_cv_prog_cc_c89" in + x) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 +$as_echo "none needed" >&6; } ;; + xno) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 +$as_echo "unsupported" >&6; } ;; + *) + CC="$CC $ac_cv_prog_cc_c89" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 +$as_echo "$ac_cv_prog_cc_c89" >&6; } ;; +esac +if test "x$ac_cv_prog_cc_c89" != xno; then : + ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89 else - ac_cv_path_GREP=$GREP + ac_cv_prog_cc_stdc=no fi fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 -$as_echo "$ac_cv_path_GREP" >&6; } - GREP="$ac_cv_path_GREP" + ;; +esac + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5 +$as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; } + if test "${ac_cv_prog_cc_stdc+set}" = set; then : + $as_echo_n "(cached) " >&6 +fi + + case $ac_cv_prog_cc_stdc in #( + no) : + { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 +$as_echo "unsupported" >&6; } ;; #( + '') : + { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 +$as_echo "none needed" >&6; } ;; #( + *) : + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5 +$as_echo "$ac_cv_prog_cc_stdc" >&6; } ;; +esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 -$as_echo_n "checking for egrep... " >&6; } -if test "${ac_cv_path_EGREP+set}" = set; then : +case "$ac_cv_prog_cc_stdc" in + no) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ANSI C89/ISO C90 is the minimum to compile SNTP + version 4.2.5 and higher." >&5 +$as_echo "$as_me: WARNING: ANSI C89/ISO C90 is the minimum to compile SNTP + version 4.2.5 and higher." >&2;} +esac + +case "$GCC" in + yes) + SAVED_CFLAGS_AC="$CFLAGS" + CFLAGS="$CFLAGS -Wstrict-overflow" + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC can handle -Wstrict-overflow" >&5 +$as_echo_n "checking if $CC can handle -Wstrict-overflow... " >&6; } +if test "${ac_cv_gcc_Wstrict_overflow+set}" = set; then : $as_echo_n "(cached) " >&6 else - if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 - then ac_cv_path_EGREP="$GREP -E" - else - if test -z "$EGREP"; then - ac_path_EGREP_found=false - # Loop through the user's path and test for each of PROGNAME-LIST - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in egrep; do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" - { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue -# Check for GNU ac_path_EGREP and select it if it is found. - # Check for GNU $ac_path_EGREP -case `"$ac_path_EGREP" --version 2>&1` in -*GNU*) - ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; -*) - ac_count=0 - $as_echo_n 0123456789 >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - $as_echo 'EGREP' >> "conftest.nl" - "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_EGREP_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_EGREP="$ac_path_EGREP" - ac_path_EGREP_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac - $ac_path_EGREP_found && break 3 - done - done - done -IFS=$as_save_IFS - if test -z "$ac_cv_path_EGREP"; then - as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 - fi + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_gcc_Wstrict_overflow=yes else - ac_cv_path_EGREP=$EGREP -fi + ac_cv_gcc_Wstrict_overflow=no - fi fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 -$as_echo "$ac_cv_path_EGREP" >&6; } - EGREP="$ac_cv_path_EGREP" - +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Check whether --with-gnu-ld was given. -if test "${with_gnu_ld+set}" = set; then : - withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes -else - with_gnu_ld=no fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gcc_Wstrict_overflow" >&5 +$as_echo "$ac_cv_gcc_Wstrict_overflow" >&6; } + CFLAGS="$SAVED_CFLAGS_AC" + SAVED_CFLAGS_AC= + + CFLAGS="$CFLAGS -Wall" + # CFLAGS="$CFLAGS -Wcast-align" + CFLAGS="$CFLAGS -Wcast-qual" + # CFLAGS="$CFLAGS -Wconversion" + # CFLAGS="$CFLAGS -Werror" + # CFLAGS="$CFLAGS -Wextra" + # CFLAGS="$CFLAGS -Wfloat-equal" + CFLAGS="$CFLAGS -Wmissing-prototypes" + CFLAGS="$CFLAGS -Wpointer-arith" + CFLAGS="$CFLAGS -Wshadow" + CFLAGS="$CFLAGS -Wstrict-prototypes" + # CFLAGS="$CFLAGS -Wtraditional" + # CFLAGS="$CFLAGS -Wwrite-strings" + case "$ac_cv_gcc_Wstrict_overflow" in + yes) + CFLAGS="$CFLAGS -Wstrict-overflow" + esac + # -W[no-]strict-prototypes is added later depending on OpenSSL +esac -ac_prog=ld -if test "$GCC" = yes; then - # Check if gcc -print-prog-name=ld gives a path. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 -$as_echo_n "checking for ld used by $CC... " >&6; } - case $host in - *-*-mingw*) - # gcc leaves a trailing carriage return which upsets mingw - ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; - *) - ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; - esac - case $ac_prog in - # Accept absolute paths. - [\\/]* | ?:[\\/]*) - re_direlt='/[^/][^/]*/\.\./' - # Canonicalize the pathname of ld - ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'` - while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do - ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"` +# HMS: These need to be moved to AM_CPPFLAGS and/or AM_CFLAGS +case "$host" in + *-*-solaris*) + # see "man standards". + # -D_XOPEN_SOURCE=500 is probably OK for c89 and before + # -D_XOPEN_SOURCE=600 seems OK for c99 + #CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=500 -D__EXTENSIONS__" + CPPFLAGS="$CPPFLAGS -D__EXTENSIONS__" + libxnet=-lxnet + ;; +esac + +# Check whether --enable-shared was given. +if test "${enable_shared+set}" = set; then : + enableval=$enable_shared; p=${PACKAGE-default} + case $enableval in + yes) enable_shared=yes ;; + no) enable_shared=no ;; + *) + enable_shared=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_shared=yes + fi done - test -z "$LD" && LD="$ac_prog" + IFS="$lt_save_ifs" ;; - "") - # If it fails, then pretend we aren't using GCC. - ac_prog=ld - ;; - *) - # If it is relative, then search for the first ld in PATH. - with_gnu_ld=unknown - ;; - esac -elif test "$with_gnu_ld" = yes; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 -$as_echo_n "checking for GNU ld... " >&6; } + esac else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 -$as_echo_n "checking for non-GNU ld... " >&6; } + enable_shared=no fi -if test "${lt_cv_path_LD+set}" = set; then : + + + + +# NTP has (so far) been relying on leading-edge autogen. +# Therefore, by default: +# - use the version we ship with +# - do not install it +# - build a static copy (AC_DISABLE_SHARED - done earlier) +case "${enable_local_libopts+set}" in + set) ;; + *) enable_local_libopts=yes ;; +esac +case "${enable_libopts_install+set}" in + set) ;; + *) enable_libopts_install=no ;; +esac +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 +$as_echo_n "checking how to run the C preprocessor... " >&6; } +# On Suns, sometimes $CPP names a directory. +if test -n "$CPP" && test -d "$CPP"; then + CPP= +fi +if test -z "$CPP"; then + if test "${ac_cv_prog_CPP+set}" = set; then : $as_echo_n "(cached) " >&6 else - if test -z "$LD"; then - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then - lt_cv_path_LD="$ac_dir/$ac_prog" - # Check to see if the program is GNU ld. I'd rather use --version, - # but apparently some variants of GNU ld only accept -v. - # Break only if it was the GNU/non-GNU ld that we prefer. - case `"$lt_cv_path_LD" -v 2>&1 to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + else - lt_cv_path_LD="$LD" # Let the user override the test with a path. -fi + # Broken: fails on valid input. +continue fi +rm -f conftest.err conftest.$ac_ext -LD="$lt_cv_path_LD" -if test -n "$LD"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 -$as_echo "$LD" >&6; } + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + # Passes both tests. +ac_preproc_ok=: +break fi -test -z "$LD" && as_fn_error "no acceptable ld found in \$PATH" "$LINENO" 5 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 -$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } -if test "${lt_cv_prog_gnu_ld+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - # I'd rather use --version here, but apparently some GNU lds only accept -v. -case `$LD -v 2>&1 &5 -$as_echo "$lt_cv_prog_gnu_ld" >&6; } -with_gnu_ld=$lt_cv_prog_gnu_ld + done + ac_cv_prog_CPP=$CPP -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 -$as_echo_n "checking for $LD option to reload object files... " >&6; } -if test "${lt_cv_ld_reload_flag+set}" = set; then : - $as_echo_n "(cached) " >&6 +fi + CPP=$ac_cv_prog_CPP else - lt_cv_ld_reload_flag='-r' + ac_cv_prog_CPP=$CPP fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5 -$as_echo "$lt_cv_ld_reload_flag" >&6; } -reload_flag=$lt_cv_ld_reload_flag -case $reload_flag in -"" | " "*) ;; -*) reload_flag=" $reload_flag" ;; -esac -reload_cmds='$LD$reload_flag -o $output$reload_objs' -case $host_os in - darwin*) - if test "$GCC" = yes; then - reload_cmds='$CC -nostdlib ${wl}-r -o $output$reload_objs' - else - reload_cmds='$LD$reload_flag -o $output$reload_objs' - fi - ;; -esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 +$as_echo "$CPP" >&6; } +ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD-compatible nm" >&5 -$as_echo_n "checking for BSD-compatible nm... " >&6; } -if test "${lt_cv_path_NM+set}" = set; then : - $as_echo_n "(cached) " >&6 else - if test -n "$NM"; then - # Let the user override the test. - lt_cv_path_NM="$NM" + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue else - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - tmp_nm="$ac_dir/${ac_tool_prefix}nm" - if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then - # Check to see if the nm accepts a BSD-compat flag. - # Adding the `sed 1q' prevents false positives on HP-UX, which says: - # nm: unknown option "B" ignored - # Tru64's nm complains that /dev/null is an invalid object file - case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in - */dev/null* | *'Invalid file or object type'*) - lt_cv_path_NM="$tmp_nm -B" - break - ;; - *) - case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in - */dev/null*) - lt_cv_path_NM="$tmp_nm -p" - break - ;; - *) - lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but - continue # so that we can try to find one that supports BSD flags - ;; - esac - esac + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + +else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error "C preprocessor \"$CPP\" fails sanity check +See \`config.log' for more details." "$LINENO" 5; } +fi + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 +$as_echo_n "checking for grep that handles long lines and -e... " >&6; } +if test "${ac_cv_path_GREP+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$GREP"; then + ac_path_GREP_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in grep ggrep; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" + { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue +# Check for GNU ac_path_GREP and select it if it is found. + # Check for GNU $ac_path_GREP +case `"$ac_path_GREP" --version 2>&1` in +*GNU*) + ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo 'GREP' >> "conftest.nl" + "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_GREP_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_GREP="$ac_path_GREP" + ac_path_GREP_max=$ac_count fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break done - IFS="$lt_save_ifs" - test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_GREP_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_GREP"; then + as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + fi +else + ac_cv_path_GREP=$GREP fi + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5 -$as_echo "$lt_cv_path_NM" >&6; } -NM="$lt_cv_path_NM" +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 +$as_echo "$ac_cv_path_GREP" >&6; } + GREP="$ac_cv_path_GREP" -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 -$as_echo_n "checking whether ln -s works... " >&6; } -LN_S=$as_ln_s -if test "$LN_S" = "ln -s"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 +$as_echo_n "checking for egrep... " >&6; } +if test "${ac_cv_path_EGREP+set}" = set; then : + $as_echo_n "(cached) " >&6 else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 -$as_echo "no, using $LN_S" >&6; } + if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 + then ac_cv_path_EGREP="$GREP -E" + else + if test -z "$EGREP"; then + ac_path_EGREP_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in egrep; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" + { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue +# Check for GNU ac_path_EGREP and select it if it is found. + # Check for GNU $ac_path_EGREP +case `"$ac_path_EGREP" --version 2>&1` in +*GNU*) + ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo 'EGREP' >> "conftest.nl" + "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_EGREP_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_EGREP="$ac_path_EGREP" + ac_path_EGREP_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_EGREP_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_EGREP"; then + as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + fi +else + ac_cv_path_EGREP=$EGREP fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognise dependent libraries" >&5 -$as_echo_n "checking how to recognise dependent libraries... " >&6; } -if test "${lt_cv_deplibs_check_method+set}" = set; then : + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 +$as_echo "$ac_cv_path_EGREP" >&6; } + EGREP="$ac_cv_path_EGREP" + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 +$as_echo_n "checking for ANSI C header files... " >&6; } +if test "${ac_cv_header_stdc+set}" = set; then : $as_echo_n "(cached) " >&6 else - lt_cv_file_magic_cmd='$MAGIC_CMD' -lt_cv_file_magic_test_file= -lt_cv_deplibs_check_method='unknown' -# Need to set the preceding variable on all platforms that support -# interlibrary dependencies. -# 'none' -- dependencies not supported. -# `unknown' -- same as none, but documents that we really don't know. -# 'pass_all' -- all dependencies passed with no checks. -# 'test_compile' -- check by making test program. -# 'file_magic [[regex]]' -- check by looking for files in library path -# which responds to the $file_magic_cmd with a given extended regex. -# If you have `file' or equivalent on your system and you're not sure -# whether `pass_all' will *always* work, you probably want this one. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#include +#include -case $host_os in -aix4* | aix5*) - lt_cv_deplibs_check_method=pass_all - ;; +int +main () +{ -beos*) - lt_cv_deplibs_check_method=pass_all - ;; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_header_stdc=yes +else + ac_cv_header_stdc=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -bsdi[45]*) - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' - lt_cv_file_magic_cmd='/usr/bin/file -L' - lt_cv_file_magic_test_file=/shlib/libc.so - ;; +if test $ac_cv_header_stdc = yes; then + # SunOS 4.x string.h does not declare mem*, contrary to ANSI. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include -cygwin*) - # func_win32_libid is a shell function defined in ltmain.sh - lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' - lt_cv_file_magic_cmd='func_win32_libid' - ;; +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "memchr" >/dev/null 2>&1; then : -mingw* | pw32*) - # Base MSYS/MinGW do not provide the 'file' command needed by - # func_win32_libid shell function, so use a weaker test based on 'objdump'. - lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?' - lt_cv_file_magic_cmd='$OBJDUMP -f' - ;; +else + ac_cv_header_stdc=no +fi +rm -f conftest* -darwin* | rhapsody*) - lt_cv_deplibs_check_method=pass_all - ;; +fi -freebsd* | kfreebsd*-gnu | dragonfly*) - if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then - case $host_cpu in - i*86 ) - # Not sure whether the presence of OpenBSD here was a mistake. - # Let's accept both of them until this is cleared up. - lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` - ;; - esac - else - lt_cv_deplibs_check_method=pass_all - fi - ;; +if test $ac_cv_header_stdc = yes; then + # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include -gnu*) - lt_cv_deplibs_check_method=pass_all - ;; +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "free" >/dev/null 2>&1; then : -hpux10.20* | hpux11*) - lt_cv_file_magic_cmd=/usr/bin/file - case $host_cpu in - ia64*) - lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' - lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so - ;; - hppa*64*) - lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]' - lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl - ;; - *) - lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library' - lt_cv_file_magic_test_file=/usr/lib/libc.sl - ;; - esac - ;; +else + ac_cv_header_stdc=no +fi +rm -f conftest* -irix5* | irix6* | nonstopux*) - case $LD in - *-32|*"-32 ") libmagic=32-bit;; - *-n32|*"-n32 ") libmagic=N32;; - *-64|*"-64 ") libmagic=64-bit;; - *) libmagic=never-match;; - esac - lt_cv_deplibs_check_method=pass_all - ;; +fi -# This must be Linux ELF. -linux*) - lt_cv_deplibs_check_method=pass_all - ;; +if test $ac_cv_header_stdc = yes; then + # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. + if test "$cross_compiling" = yes; then : + : +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#if ((' ' & 0x0FF) == 0x020) +# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') +# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) +#else +# define ISLOWER(c) \ + (('a' <= (c) && (c) <= 'i') \ + || ('j' <= (c) && (c) <= 'r') \ + || ('s' <= (c) && (c) <= 'z')) +# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) +#endif -netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' - fi - ;; +#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) +int +main () +{ + int i; + for (i = 0; i < 256; i++) + if (XOR (islower (i), ISLOWER (i)) + || toupper (i) != TOUPPER (i)) + return 2; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : -newos6*) - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=/usr/lib/libnls.so - ;; +else + ac_cv_header_stdc=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi -nto-qnx*) - lt_cv_deplibs_check_method=unknown - ;; +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 +$as_echo "$ac_cv_header_stdc" >&6; } +if test $ac_cv_header_stdc = yes; then -openbsd*) - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' - fi - ;; +$as_echo "#define STDC_HEADERS 1" >>confdefs.h -osf3* | osf4* | osf5*) - lt_cv_deplibs_check_method=pass_all - ;; +fi -sco3.2v5*) - lt_cv_deplibs_check_method=pass_all - ;; +# On IRIX 5.3, sys/types and inttypes.h are conflicting. +for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ + inttypes.h stdint.h unistd.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default +" +eval as_val=\$$as_ac_Header + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF -solaris*) - lt_cv_deplibs_check_method=pass_all - ;; +fi -sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - case $host_vendor in - motorola) - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]' - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` - ;; - ncr) - lt_cv_deplibs_check_method=pass_all - ;; - sequent) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' - ;; - sni) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib" - lt_cv_file_magic_test_file=/lib/libc.so - ;; - siemens) - lt_cv_deplibs_check_method=pass_all - ;; - esac - ;; +done -sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7* | sysv4*uw2*) - lt_cv_deplibs_check_method=pass_all - ;; -esac + +ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" +if test "x$ac_cv_type_pid_t" = x""yes; then : + +else + +cat >>confdefs.h <<_ACEOF +#define pid_t int +_ACEOF fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5 -$as_echo "$lt_cv_deplibs_check_method" >&6; } -file_magic_cmd=$lt_cv_file_magic_cmd -deplibs_check_method=$lt_cv_deplibs_check_method -test -z "$deplibs_check_method" && deplibs_check_method=unknown + NEED_LIBOPTS_DIR='' + LIBOPTS_DIR=libopts -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} + # Check whether --enable-local-libopts was given. +if test "${enable_local_libopts+set}" = set; then : + enableval=$enable_local_libopts; + if test x$enableval = xyes ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: Using supplied libopts tearoff" >&5 +$as_echo "$as_me: Using supplied libopts tearoff" >&6;} + LIBOPTS_LDADD='$(top_builddir)/libopts/libopts.la' + LIBOPTS_CFLAGS='-I$(top_srcdir)/libopts' + NEED_LIBOPTS_DIR=true + fi +fi -# Allow CC to be a program name with arguments. -compiler=$CC + # Check whether --enable-libopts-install was given. +if test "${enable_libopts_install+set}" = set; then : + enableval=$enable_libopts_install; +fi -# Check whether --enable-libtool-lock was given. -if test "${enable_libtool_lock+set}" = set; then : - enableval=$enable_libtool_lock; + if test "X${enable_libopts_install}" != Xno; then + INSTALL_LIBOPTS_TRUE= + INSTALL_LIBOPTS_FALSE='#' +else + INSTALL_LIBOPTS_TRUE='#' + INSTALL_LIBOPTS_FALSE= fi -test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes -# Some flags need to be propagated to the compiler or linker for good -# libtool support. -case $host in -ia64-*-hpux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - case `/usr/bin/file conftest.$ac_objext` in - *ELF-32*) - HPUX_IA64_MODE="32" - ;; - *ELF-64*) - HPUX_IA64_MODE="64" - ;; - esac - fi - rm -rf conftest* - ;; -*-*-irix6*) - # Find out which ABI we are using. - echo '#line 4774 "configure"' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - if test "$lt_cv_prog_gnu_ld" = yes; then - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -melf32bsmip" - ;; - *N32*) - LD="${LD-ld} -melf32bmipn32" - ;; - *64-bit*) - LD="${LD-ld} -melf64bmip" - ;; - esac - else - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -32" - ;; - *N32*) - LD="${LD-ld} -n32" - ;; - *64-bit*) - LD="${LD-ld} -64" - ;; - esac - fi - fi - rm -rf conftest* - ;; + if test -z "${NEED_LIBOPTS_DIR}" ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether autoopts-config can be found" >&5 +$as_echo_n "checking whether autoopts-config can be found... " >&6; } -x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - case `/usr/bin/file conftest.o` in - *32-bit*) - case $host in - x86_64-*linux*) - LD="${LD-ld} -m elf_i386" - ;; - ppc64-*linux*|powerpc64-*linux*) - LD="${LD-ld} -m elf32ppclinux" - ;; - s390x-*linux*) - LD="${LD-ld} -m elf_s390" - ;; - sparc64-*linux*) - LD="${LD-ld} -m elf32_sparc" - ;; - esac - ;; - *64-bit*) - case $host in - x86_64-*linux*) - LD="${LD-ld} -m elf_x86_64" - ;; - ppc*-*linux*|powerpc*-*linux*) - LD="${LD-ld} -m elf64ppc" - ;; - s390*-*linux*) - LD="${LD-ld} -m elf64_s390" - ;; - sparc*-*linux*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; +# Check whether --with-autoopts-config was given. +if test "${with_autoopts_config+set}" = set; then : + withval=$with_autoopts_config; lo_cv_with_autoopts_config=${with_autoopts_config} +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether autoopts-config is specified" >&5 +$as_echo_n "checking whether autoopts-config is specified... " >&6; } +if test "${lo_cv_with_autoopts_config+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + if autoopts-config --help 2>/dev/null 1>&2 + then lo_cv_with_autoopts_config=autoopts-config + elif libopts-config --help 2>/dev/null 1>&2 + then lo_cv_with_autoopts_config=libopts-config + else lo_cv_with_autoopts_config=no ; fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lo_cv_with_autoopts_config" >&5 +$as_echo "$lo_cv_with_autoopts_config" >&6; } -*-*-sco3.2v5*) - # On SCO OpenServer 5, we need -belf to get full-featured binaries. - SAVE_CFLAGS="$CFLAGS" - CFLAGS="$CFLAGS -belf" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5 -$as_echo_n "checking whether the C compiler needs -belf... " >&6; } -if test "${lt_cv_cc_needs_belf+set}" = set; then : +fi + # end of AC_ARG_WITH + + if test "${lo_cv_test_autoopts+set}" = set; then : $as_echo_n "(cached) " >&6 else - ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + if test -z "${lo_cv_with_autoopts_config}" \ + -o X"${lo_cv_with_autoopts_config}" = Xno + then + if autoopts-config --help 2>/dev/null 1>&2 + then lo_cv_with_autoopts_config=autoopts-config + elif libopts-config --help 2>/dev/null 1>&2 + then lo_cv_with_autoopts_config=libopts-config + else lo_cv_with_autoopts_config=false ; fi + fi + lo_cv_test_autoopts=` + ${lo_cv_with_autoopts_config} --libs` 2> /dev/null + if test $? -ne 0 -o -z "${lo_cv_test_autoopts}" + then lo_cv_test_autoopts=no ; fi + +fi + # end of CACHE_VAL + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lo_cv_test_autoopts}" >&5 +$as_echo "${lo_cv_test_autoopts}" >&6; } + + if test "X${lo_cv_test_autoopts}" != Xno + then + LIBOPTS_LDADD="${lo_cv_test_autoopts}" + LIBOPTS_CFLAGS="`${lo_cv_with_autoopts_config} --cflags`" + else + LIBOPTS_LDADD='$(top_builddir)/libopts/libopts.la' + LIBOPTS_CFLAGS='-I$(top_srcdir)/libopts' + NEED_LIBOPTS_DIR=true + fi + fi # end of if test -z "${NEED_LIBOPTS_DIR}" + + if test -n "${NEED_LIBOPTS_DIR}"; then + NEED_LIBOPTS_TRUE= + NEED_LIBOPTS_FALSE='#' +else + NEED_LIBOPTS_TRUE='#' + NEED_LIBOPTS_FALSE= +fi + + + + LIBOPTS_DIR=libopts + + ac_config_files="$ac_config_files libopts/Makefile" + + + + if test -n "${NEED_LIBOPTS_DIR}" ; then + + +if test X${INVOKE_LIBOPTS_MACROS_FIRST_done} != Xyes ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 +$as_echo_n "checking for ANSI C header files... " >&6; } +if test "${ac_cv_header_stdc+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ +#include +#include +#include +#include int main () @@ -4878,229 +5201,44 @@ return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - lt_cv_cc_needs_belf=yes +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_header_stdc=yes else - lt_cv_cc_needs_belf=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - + ac_cv_header_stdc=no fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5 -$as_echo "$lt_cv_cc_needs_belf" >&6; } - if test x"$lt_cv_cc_needs_belf" != x"yes"; then - # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf - CFLAGS="$SAVE_CFLAGS" - fi - ;; - -esac - -need_locks="$enable_libtool_lock" - +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 -$as_echo_n "checking how to run the C preprocessor... " >&6; } -# On Suns, sometimes $CPP names a directory. -if test -n "$CPP" && test -d "$CPP"; then - CPP= -fi -if test -z "$CPP"; then - if test "${ac_cv_prog_CPP+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - # Double quotes because CPP needs to be expanded - for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" - do - ac_preproc_ok=false -for ac_c_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # Prefer to if __STDC__ is defined, since - # exists even on freestanding compilers. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. +if test $ac_cv_header_stdc = yes; then + # SunOS 4.x string.h does not declare mem*, contrary to ANSI. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#ifdef __STDC__ -# include -#else -# include -#endif - Syntax error +#include + _ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "memchr" >/dev/null 2>&1; then : else - # Broken: fails on valid input. -continue + ac_cv_header_stdc=no fi -rm -f conftest.err conftest.$ac_ext +rm -f conftest* - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. +fi + +if test $ac_cv_header_stdc = yes; then + # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include +#include + _ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - # Broken: success on invalid input. -continue +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "free" >/dev/null 2>&1; then : + else - # Passes both tests. -ac_preproc_ok=: -break + ac_cv_header_stdc=no fi -rm -f conftest.err conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.err conftest.$ac_ext -if $ac_preproc_ok; then : - break -fi - - done - ac_cv_prog_CPP=$CPP - -fi - CPP=$ac_cv_prog_CPP -else - ac_cv_prog_CPP=$CPP -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 -$as_echo "$CPP" >&6; } -ac_preproc_ok=false -for ac_c_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # Prefer to if __STDC__ is defined, since - # exists even on freestanding compilers. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifdef __STDC__ -# include -#else -# include -#endif - Syntax error -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - -else - # Broken: fails on valid input. -continue -fi -rm -f conftest.err conftest.$ac_ext - - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - # Broken: success on invalid input. -continue -else - # Passes both tests. -ac_preproc_ok=: -break -fi -rm -f conftest.err conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.err conftest.$ac_ext -if $ac_preproc_ok; then : - -else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error "C preprocessor \"$CPP\" fails sanity check -See \`config.log' for more details." "$LINENO" 5; } -fi - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 -$as_echo_n "checking for ANSI C header files... " >&6; } -if test "${ac_cv_header_stdc+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#include -#include - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_header_stdc=yes -else - ac_cv_header_stdc=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then : - -else - ac_cv_header_stdc=no -fi -rm -f conftest* - -fi - -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then : - -else - ac_cv_header_stdc=no -fi -rm -f conftest* +rm -f conftest* fi @@ -5155,1755 +5293,1382 @@ fi -# On IRIX 5.3, sys/types and inttypes.h are conflicting. -for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ - inttypes.h stdint.h unistd.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default -" + ac_header_dirent=no +for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do + as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5 +$as_echo_n "checking for $ac_hdr that defines DIR... " >&6; } +if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include <$ac_hdr> + +int +main () +{ +if ((DIR *) 0) +return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + eval "$as_ac_Header=yes" +else + eval "$as_ac_Header=no" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$as_ac_Header + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } eval as_val=\$$as_ac_Header if test "x$as_val" = x""yes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +#define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 _ACEOF +ac_header_dirent=$ac_hdr; break fi done +# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. +if test $ac_header_dirent = dirent.h; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 +$as_echo_n "checking for library containing opendir... " >&6; } +if test "${ac_cv_search_opendir+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - -for ac_header in dlfcn.h -do : - ac_fn_c_check_header_mongrel "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default" -if test "x$ac_cv_header_dlfcn_h" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_DLFCN_H 1 +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char opendir (); +int +main () +{ +return opendir (); + ; + return 0; +} _ACEOF - +for ac_lib in '' dir; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_opendir=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if test "${ac_cv_search_opendir+set}" = set; then : + break fi - done +if test "${ac_cv_search_opendir+set}" = set; then : +else + ac_cv_search_opendir=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 +$as_echo "$ac_cv_search_opendir" >&6; } +ac_res=$ac_cv_search_opendir +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" -# Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers! +fi -# find the maximum length of command line arguments -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5 -$as_echo_n "checking the maximum length of command line arguments... " >&6; } -if test "${lt_cv_sys_max_cmd_len+set}" = set; then : +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 +$as_echo_n "checking for library containing opendir... " >&6; } +if test "${ac_cv_search_opendir+set}" = set; then : $as_echo_n "(cached) " >&6 else - i=0 - teststring="ABCD" - - case $build_os in - msdosdjgpp*) - # On DJGPP, this test can blow up pretty badly due to problems in libc - # (any single argument exceeding 2000 bytes causes a buffer overrun - # during glob expansion). Even if it were fixed, the result of this - # check would be larger than it should be. - lt_cv_sys_max_cmd_len=12288; # 12K is about right - ;; - - gnu*) - # Under GNU Hurd, this test is not required because there is - # no limit to the length of command line arguments. - # Libtool will interpret -1 as no limit whatsoever - lt_cv_sys_max_cmd_len=-1; - ;; - - cygwin* | mingw*) - # On Win9x/ME, this test blows up -- it succeeds, but takes - # about 5 minutes as the teststring grows exponentially. - # Worse, since 9x/ME are not pre-emptively multitasking, - # you end up with a "frozen" computer, even though with patience - # the test eventually succeeds (with a max line length of 256k). - # Instead, let's just punt: use the minimum linelength reported by - # all of the supported platforms: 8192 (on NT/2K/XP). - lt_cv_sys_max_cmd_len=8192; - ;; - - amigaos*) - # On AmigaOS with pdksh, this test takes hours, literally. - # So we just punt and use a minimum line length of 8192. - lt_cv_sys_max_cmd_len=8192; - ;; - - netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) - # This has been around since 386BSD, at least. Likely further. - if test -x /sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` - elif test -x /usr/sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` - else - lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs - fi - # And add a safety zone - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - ;; - osf*) - # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure - # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not - # nice to cause kernel panics so lets avoid the loop below. - # First set a reasonable default. - lt_cv_sys_max_cmd_len=16384 - # - if test -x /sbin/sysconfig; then - case `/sbin/sysconfig -q proc exec_disable_arg_limit` in - *1*) lt_cv_sys_max_cmd_len=-1 ;; - esac - fi - ;; - *) - # If test is not a shell built-in, we'll probably end up computing a - # maximum length that is only half of the actual maximum length, but - # we can't tell. - SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} - while (test "X"`$SHELL $0 --fallback-echo "X$teststring" 2>/dev/null` \ - = "XX$teststring") >/dev/null 2>&1 && - new_result=`expr "X$teststring" : ".*" 2>&1` && - lt_cv_sys_max_cmd_len=$new_result && - test $i != 17 # 1/2 MB should be enough - do - i=`expr $i + 1` - teststring=$teststring$teststring - done - teststring= - # Add a significant safety factor because C++ compilers can tack on massive - # amounts of additional arguments before passing them to the linker. - # It appears as though 1/2 is a usable value. - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` - ;; - esac + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char opendir (); +int +main () +{ +return opendir (); + ; + return 0; +} +_ACEOF +for ac_lib in '' x; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_opendir=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if test "${ac_cv_search_opendir+set}" = set; then : + break fi +done +if test "${ac_cv_search_opendir+set}" = set; then : -if test -n $lt_cv_sys_max_cmd_len ; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5 -$as_echo "$lt_cv_sys_max_cmd_len" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 -$as_echo "none" >&6; } + ac_cv_search_opendir=no fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 +$as_echo "$ac_cv_search_opendir" >&6; } +ac_res=$ac_cv_search_opendir +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" +fi +fi -# Check for command to grab the raw symbol name followed by C symbol from nm. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5 -$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; } -if test "${lt_cv_sys_global_symbol_pipe+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - -# These are sane defaults that work on at least a few old systems. -# [They come from Ultrix. What could be older than Ultrix?!! ;)] - -# Character class describing NM global symbol codes. -symcode='[BCDEGRST]' + # ================= + # AC_CHECK_HEADERS + # ================= + for ac_header in dlfcn.h errno.h fcntl.h libgen.h memory.h netinet/in.h \ + setjmp.h sys/mman.h sys/param.h sys/poll.h sys/procset.h sys/select.h \ + sys/socket.h sys/stropts.h sys/time.h sys/un.h sys/wait.h unistd.h \ + utime.h sysexits.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +eval as_val=\$$as_ac_Header + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF -# Regexp to match symbols that can be accessed directly from C. -sympat='\([_A-Za-z][_A-Za-z0-9]*\)' +fi -# Transform an extracted symbol line into a proper C declaration -lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'" +done -# Transform an extracted symbol line into symbol name and symbol address -lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([^ ]*\) \([^ ]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" -# Define system-specific variables. -case $host_os in -aix*) - symcode='[BCDT]' - ;; -cygwin* | mingw* | pw32*) - symcode='[ABCDGISTW]' - ;; -hpux*) # Its linker distinguishes data from code symbols - if test "$host_cpu" = ia64; then - symcode='[ABCDEGRST]' - fi - lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" - lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" - ;; -linux*) - if test "$host_cpu" = ia64; then - symcode='[ABCDGIRSTW]' - lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" - lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" - fi - ;; -irix* | nonstopux*) - symcode='[BCDEGRST]' - ;; -osf*) - symcode='[BCDEGQRST]' - ;; -solaris* | sysv5*) - symcode='[BDRT]' - ;; -sysv4) - symcode='[DFNSTU]' - ;; -esac + # -------------------------------------------- + # Verify certain entries from AC_CHECK_HEADERS + # -------------------------------------------- + for f in sys_types sys_mman sys_param sys_stat sys_wait \ + string errno stdlib memory setjmp + do eval as_ac_var=\${ac_cv_header_${f}_h+set} + test "${as_ac_var}" = set || \ + as_fn_error "You must have ${f}.h on your system" "$LINENO" 5 + done -# Handle CRLF in mingw tool chain -opt_cr= -case $build_os in -mingw*) - opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp - ;; -esac + # ================================================ + # AC_CHECK_HEADERS: stdarg.h is present define HAVE_STDARG_H, otherwise + # if varargs.h is present define HAVE_VARARGS_H. + # ================================================ + for ac_header in stdarg.h varargs.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +eval as_val=\$$as_ac_Header + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + break +fi -# If we're using GNU nm, then use its standard symbol codes. -case `$NM -V 2>&1` in -*GNU* | *'with BFD'*) - symcode='[ABCDGIRSTW]' ;; -esac +done -# Try without a prefix undercore, then with it. -for ac_symprfx in "" "_"; do + if test `eval echo '${'$as_ac_Header'}'` != yes; then + as_fn_error "You must have stdarg.h or varargs.h on your system" "$LINENO" 5 + fi - # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. - symxfrm="\\1 $ac_symprfx\\2 \\2" + # ================================================ + # Similarly for the string.h and strings.h headers + # ================================================ + for ac_header in string.h strings.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +eval as_val=\$$as_ac_Header + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + break +fi - # Write the raw and C identifiers. - lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" +done - # Check to see that the pipe works correctly. - pipe_works=no + if test `eval echo '${'$as_ac_Header'}'` != yes; then + as_fn_error "You must have string.h or strings.h on your system" "$LINENO" 5 + fi - rm -f conftest* - cat > conftest.$ac_ext <&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - # Now try to grab the symbols. - nlist=conftest.nm - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\""; } >&5 - (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s "$nlist"; then - # Try sorting and uniquifying the output. - if sort "$nlist" | uniq > "$nlist"T; then - mv -f "$nlist"T "$nlist" - else - rm -f "$nlist"T - fi + # ===================== + # ...and limits headers + # ===================== + for ac_header in limits.h sys/limits.h values.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +eval as_val=\$$as_ac_Header + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + break +fi - # Make sure that we snagged all the symbols we need. - if grep ' nm_test_var$' "$nlist" >/dev/null; then - if grep ' nm_test_func$' "$nlist" >/dev/null; then - cat < conftest.$ac_ext -#ifdef __cplusplus -extern "C" { -#endif +done -EOF - # Now generate the symbol file. - eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext' + if test `eval echo '${'$as_ac_Header'}'` != yes; then + as_fn_error "You must have one of limits.h, sys/limits.h or values.h" "$LINENO" 5 + fi - cat <> conftest.$ac_ext -#if defined (__STDC__) && __STDC__ -# define lt_ptr_t void * -#else -# define lt_ptr_t char * -# define const -#endif + # ---------------------------------------------------------------------- + # check for various programs used during the build. + # On OS/X, "wchar.h" needs "runetype.h" to work properly. + # ---------------------------------------------------------------------- + for ac_header in runetype.h wchar.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" " + $ac_includes_default + #if HAVE_RUNETYPE_H + # include + #endif -/* The mapping between symbol names and symbols. */ -const struct { - const char *name; - lt_ptr_t address; -} -lt_preloaded_symbols[] = -{ -EOF - $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext - cat <<\EOF >> conftest.$ac_ext - {0, (lt_ptr_t) 0} -}; +" +eval as_val=\$$as_ac_Header + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF -#ifdef __cplusplus -} -#endif -EOF - # Now try linking the two files. - mv conftest.$ac_objext conftstm.$ac_objext - lt_save_LIBS="$LIBS" - lt_save_CFLAGS="$CFLAGS" - LIBS="conftstm.$ac_objext" - CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext}; then - pipe_works=yes - fi - LIBS="$lt_save_LIBS" - CFLAGS="$lt_save_CFLAGS" - else - echo "cannot find nm_test_func in $nlist" >&5 - fi - else - echo "cannot find nm_test_var in $nlist" >&5 - fi - else - echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 - fi - else - echo "$progname: failed program was:" >&5 - cat conftest.$ac_ext >&5 - fi - rm -f conftest* conftst* +fi - # Do not use the global_symbol_pipe unless it works. - if test "$pipe_works" = yes; then - break - else - lt_cv_sys_global_symbol_pipe= - fi done -fi -if test -z "$lt_cv_sys_global_symbol_pipe"; then - lt_cv_sys_global_symbol_to_cdecl= + # ---------------------------------------------------------------------- + # Checks for typedefs + # ---------------------------------------------------------------------- + ac_fn_c_check_type "$LINENO" "wchar_t" "ac_cv_type_wchar_t" "$ac_includes_default" +if test "x$ac_cv_type_wchar_t" = x""yes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_WCHAR_T 1 +_ACEOF + + fi -if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5 -$as_echo "failed" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 -$as_echo "ok" >&6; } + + ac_fn_c_check_type "$LINENO" "wint_t" "ac_cv_type_wint_t" " + $ac_includes_default + #if HAVE_RUNETYPE_H + # include + #endif + #if HAVE_WCHAR_H + # include + #endif + +" +if test "x$ac_cv_type_wint_t" = x""yes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_WINT_T 1 +_ACEOF + + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5 -$as_echo_n "checking for objdir... " >&6; } -if test "${lt_cv_objdir+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - rm -f .libs 2>/dev/null -mkdir .libs 2>/dev/null -if test -d .libs; then - lt_cv_objdir=.libs -else - # MS-DOS does not allow filenames that begin with a dot. - lt_cv_objdir=_libs + + # ======================== + # ...and int types headers + # ======================== + for ac_header in stdint.h inttypes.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +eval as_val=\$$as_ac_Header + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + break fi -rmdir .libs 2>/dev/null + +done + + ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "$ac_includes_default" +if test "x$ac_cv_type_int8_t" = x""yes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_INT8_T 1 +_ACEOF + + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5 -$as_echo "$lt_cv_objdir" >&6; } -objdir=$lt_cv_objdir +ac_fn_c_check_type "$LINENO" "uint8_t" "ac_cv_type_uint8_t" "$ac_includes_default" +if test "x$ac_cv_type_uint8_t" = x""yes; then : +cat >>confdefs.h <<_ACEOF +#define HAVE_UINT8_T 1 +_ACEOF +fi +ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "$ac_includes_default" +if test "x$ac_cv_type_int16_t" = x""yes; then : +cat >>confdefs.h <<_ACEOF +#define HAVE_INT16_T 1 +_ACEOF -case $host_os in -aix3*) - # AIX sometimes has problems with the GCC collect2 program. For some - # reason, if we set the COLLECT_NAMES environment variable, the problems - # vanish in a puff of smoke. - if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES - fi - ;; -esac -# Sed substitution that helps us do robust quoting. It backslashifies -# metacharacters that are still active within double-quoted strings. -Xsed='sed -e 1s/^X//' -sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g' +fi +ac_fn_c_check_type "$LINENO" "uint16_t" "ac_cv_type_uint16_t" "$ac_includes_default" +if test "x$ac_cv_type_uint16_t" = x""yes; then : -# Same as above, but do not quote variable references. -double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g' +cat >>confdefs.h <<_ACEOF +#define HAVE_UINT16_T 1 +_ACEOF -# Sed substitution to delay expansion of an escaped shell variable in a -# double_quote_subst'ed string. -delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' -# Sed substitution to avoid accidental globbing in evaled expressions -no_glob_subst='s/\*/\\\*/g' +fi +ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default" +if test "x$ac_cv_type_int32_t" = x""yes; then : -# Constants: -rm="rm -f" +cat >>confdefs.h <<_ACEOF +#define HAVE_INT32_T 1 +_ACEOF -# Global variables: -default_ofile=libtool -can_build_shared=yes -# All known linkers require a `.a' archive for static linking (except MSVC, -# which needs '.lib'). -libext=a -ltmain="$ac_aux_dir/ltmain.sh" -ofile="$default_ofile" -with_gnu_ld="$lt_cv_prog_gnu_ld" +fi +ac_fn_c_check_type "$LINENO" "uint32_t" "ac_cv_type_uint32_t" "$ac_includes_default" +if test "x$ac_cv_type_uint32_t" = x""yes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_UINT32_T 1 +_ACEOF -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. -set dummy ${ac_tool_prefix}ar; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_AR+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$AR"; then - ac_cv_prog_AR="$AR" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_AR="${ac_tool_prefix}ar" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS fi -fi -AR=$ac_cv_prog_AR -if test -n "$AR"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 -$as_echo "$AR" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi +ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "$ac_includes_default" +if test "x$ac_cv_type_intptr_t" = x""yes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_INTPTR_T 1 +_ACEOF fi -if test -z "$ac_cv_prog_AR"; then - ac_ct_AR=$AR - # Extract the first word of "ar", so it can be a program name with args. -set dummy ar; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_AR+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_AR"; then - ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_AR="ar" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS +ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default" +if test "x$ac_cv_type_uintptr_t" = x""yes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_UINTPTR_T 1 +_ACEOF + fi +ac_fn_c_check_type "$LINENO" "uint_t" "ac_cv_type_uint_t" "$ac_includes_default" +if test "x$ac_cv_type_uint_t" = x""yes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_UINT_T 1 +_ACEOF + + fi -ac_ct_AR=$ac_cv_prog_ac_ct_AR -if test -n "$ac_ct_AR"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 -$as_echo "$ac_ct_AR" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" +if test "x$ac_cv_type_pid_t" = x""yes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_PID_T 1 +_ACEOF + + fi +ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" +if test "x$ac_cv_type_size_t" = x""yes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_SIZE_T 1 +_ACEOF + - if test "x$ac_ct_AR" = x; then - AR="false" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - AR=$ac_ct_AR - fi -else - AR="$ac_cv_prog_AR" fi -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. -set dummy ${ac_tool_prefix}ranlib; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_RANLIB+set}" = set; then : + + # ===== + # sizes + # ===== + # The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of char*" >&5 +$as_echo_n "checking size of char*... " >&6; } +if test "${ac_cv_sizeof_charp+set}" = set; then : $as_echo_n "(cached) " >&6 else - if test -n "$RANLIB"; then - ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char*))" "ac_cv_sizeof_charp" "$ac_includes_default"; then : -fi -fi -RANLIB=$ac_cv_prog_RANLIB -if test -n "$RANLIB"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 -$as_echo "$RANLIB" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + if test "$ac_cv_type_charp" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +{ as_fn_set_status 77 +as_fn_error "cannot compute sizeof (char*) +See \`config.log' for more details." "$LINENO" 5; }; } + else + ac_cv_sizeof_charp=0 + fi fi - fi -if test -z "$ac_cv_prog_RANLIB"; then - ac_ct_RANLIB=$RANLIB - # Extract the first word of "ranlib", so it can be a program name with args. -set dummy ranlib; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_charp" >&5 +$as_echo "$ac_cv_sizeof_charp" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_CHARP $ac_cv_sizeof_charp +_ACEOF + + + # The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 +$as_echo_n "checking size of int... " >&6; } +if test "${ac_cv_sizeof_int+set}" = set; then : $as_echo_n "(cached) " >&6 else - if test -n "$ac_ct_RANLIB"; then - ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_RANLIB="ranlib" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then : -fi -fi -ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB -if test -n "$ac_ct_RANLIB"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 -$as_echo "$ac_ct_RANLIB" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + if test "$ac_cv_type_int" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +{ as_fn_set_status 77 +as_fn_error "cannot compute sizeof (int) +See \`config.log' for more details." "$LINENO" 5; }; } + else + ac_cv_sizeof_int=0 + fi fi - if test "x$ac_ct_RANLIB" = x; then - RANLIB=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - RANLIB=$ac_ct_RANLIB - fi -else - RANLIB="$ac_cv_prog_RANLIB" fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 +$as_echo "$ac_cv_sizeof_int" >&6; } -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. -set dummy ${ac_tool_prefix}strip; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_STRIP+set}" = set; then : + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_INT $ac_cv_sizeof_int +_ACEOF + + + # The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 +$as_echo_n "checking size of long... " >&6; } +if test "${ac_cv_sizeof_long+set}" = set; then : $as_echo_n "(cached) " >&6 else - if test -n "$STRIP"; then - ac_cv_prog_STRIP="$STRIP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_STRIP="${ac_tool_prefix}strip" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then : -fi -fi -STRIP=$ac_cv_prog_STRIP -if test -n "$STRIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 -$as_echo "$STRIP" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + if test "$ac_cv_type_long" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +{ as_fn_set_status 77 +as_fn_error "cannot compute sizeof (long) +See \`config.log' for more details." "$LINENO" 5; }; } + else + ac_cv_sizeof_long=0 + fi fi - fi -if test -z "$ac_cv_prog_STRIP"; then - ac_ct_STRIP=$STRIP - # Extract the first word of "strip", so it can be a program name with args. -set dummy strip; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 +$as_echo "$ac_cv_sizeof_long" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_LONG $ac_cv_sizeof_long +_ACEOF + + + # The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 +$as_echo_n "checking size of short... " >&6; } +if test "${ac_cv_sizeof_short+set}" = set; then : $as_echo_n "(cached) " >&6 else - if test -n "$ac_ct_STRIP"; then - ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_STRIP="strip" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short" "$ac_includes_default"; then : +else + if test "$ac_cv_type_short" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +{ as_fn_set_status 77 +as_fn_error "cannot compute sizeof (short) +See \`config.log' for more details." "$LINENO" 5; }; } + else + ac_cv_sizeof_short=0 + fi fi + fi -ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP -if test -n "$ac_ct_STRIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 -$as_echo "$ac_ct_STRIP" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 +$as_echo "$ac_cv_sizeof_short" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_SHORT $ac_cv_sizeof_short +_ACEOF + + + + # ---------------------------------------------------------------------- + # AC_CHECK_LIB for SVR4 libgen, and use it if it defines pathfind. + # ---------------------------------------------------------------------- + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pathfind in -lgen" >&5 +$as_echo_n "checking for pathfind in -lgen... " >&6; } +if test "${ac_cv_lib_gen_pathfind+set}" = set; then : + $as_echo_n "(cached) " >&6 else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi + ac_check_lib_save_LIBS=$LIBS +LIBS="-lgen $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - if test "x$ac_ct_STRIP" = x; then - STRIP=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - STRIP=$ac_ct_STRIP - fi +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char pathfind (); +int +main () +{ +return pathfind (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_gen_pathfind=yes else - STRIP="$ac_cv_prog_STRIP" + ac_cv_lib_gen_pathfind=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gen_pathfind" >&5 +$as_echo "$ac_cv_lib_gen_pathfind" >&6; } +if test "x$ac_cv_lib_gen_pathfind" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_LIBGEN 1 +_ACEOF + LIBS="-lgen $LIBS" -old_CC="$CC" -old_CFLAGS="$CFLAGS" +fi -# Set sane defaults for various variables -test -z "$AR" && AR=ar -test -z "$AR_FLAGS" && AR_FLAGS=cru -test -z "$AS" && AS=as -test -z "$CC" && CC=cc -test -z "$LTCC" && LTCC=$CC -test -z "$DLLTOOL" && DLLTOOL=dlltool -test -z "$LD" && LD=ld -test -z "$LN_S" && LN_S="ln -s" -test -z "$MAGIC_CMD" && MAGIC_CMD=file -test -z "$NM" && NM=nm -test -z "$SED" && SED=sed -test -z "$OBJDUMP" && OBJDUMP=objdump -test -z "$RANLIB" && RANLIB=: -test -z "$STRIP" && STRIP=: -test -z "$ac_objext" && ac_objext=o + for ac_func in vprintf +do : + ac_fn_c_check_func "$LINENO" "vprintf" "ac_cv_func_vprintf" +if test "x$ac_cv_func_vprintf" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_VPRINTF 1 +_ACEOF -# Determine commands to create old-style static archives. -old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs' -old_postinstall_cmds='chmod 644 $oldlib' -old_postuninstall_cmds= +ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt" +if test "x$ac_cv_func__doprnt" = x""yes; then : + +$as_echo "#define HAVE_DOPRNT 1" >>confdefs.h -if test -n "$RANLIB"; then - case $host_os in - openbsd*) - old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds" - ;; - *) - old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds" - ;; - esac - old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" fi -for cc_temp in $compiler""; do - case $cc_temp in - compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; - distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; - \-*) ;; - *) break;; - esac +fi done -cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` -# Only perform the check for file, if the check method requires it -case $deplibs_check_method in -file_magic*) - if test "$file_magic_cmd" = '$MAGIC_CMD'; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5 -$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; } -if test "${lt_cv_path_MAGIC_CMD+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - case $MAGIC_CMD in -[\\/*] | ?:[\\/]*) - lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD="$MAGIC_CMD" - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" - for ac_dir in $ac_dummy; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/${ac_tool_prefix}file; then - lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD="$lt_cv_path_MAGIC_CMD" - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <&2 + for ac_header in vfork.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default" +if test "x$ac_cv_header_vfork_h" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_VFORK_H 1 +_ACEOF -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org +fi -EOF - fi ;; - esac - fi - break - fi - done - IFS="$lt_save_ifs" - MAGIC_CMD="$lt_save_MAGIC_CMD" - ;; -esac -fi +done + +for ac_func in fork vfork +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +eval as_val=\$$as_ac_var + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF -MAGIC_CMD="$lt_cv_path_MAGIC_CMD" -if test -n "$MAGIC_CMD"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 -$as_echo "$MAGIC_CMD" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } fi +done -if test -z "$lt_cv_path_MAGIC_CMD"; then - if test -n "$ac_tool_prefix"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5 -$as_echo_n "checking for file... " >&6; } -if test "${lt_cv_path_MAGIC_CMD+set}" = set; then : +if test "x$ac_cv_func_fork" = xyes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5 +$as_echo_n "checking for working fork... " >&6; } +if test "${ac_cv_func_fork_works+set}" = set; then : $as_echo_n "(cached) " >&6 else - case $MAGIC_CMD in -[\\/*] | ?:[\\/]*) - lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD="$MAGIC_CMD" - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" - for ac_dir in $ac_dummy; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/file; then - lt_cv_path_MAGIC_CMD="$ac_dir/file" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD="$lt_cv_path_MAGIC_CMD" - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <&2 - -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org + if test "$cross_compiling" = yes; then : + ac_cv_func_fork_works=cross +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ -EOF - fi ;; - esac - fi - break - fi - done - IFS="$lt_save_ifs" - MAGIC_CMD="$lt_save_MAGIC_CMD" - ;; -esac -fi + /* By Ruediger Kuhlmann. */ + return fork () < 0; -MAGIC_CMD="$lt_cv_path_MAGIC_CMD" -if test -n "$MAGIC_CMD"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 -$as_echo "$MAGIC_CMD" >&6; } + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_func_fork_works=yes else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + ac_cv_func_fork_works=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - else - MAGIC_CMD=: - fi fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5 +$as_echo "$ac_cv_func_fork_works" >&6; } - fi - ;; -esac +else + ac_cv_func_fork_works=$ac_cv_func_fork +fi +if test "x$ac_cv_func_fork_works" = xcross; then + case $host in + *-*-amigaos* | *-*-msdosdjgpp*) + # Override, as these systems have only a dummy fork() stub + ac_cv_func_fork_works=no + ;; + *) + ac_cv_func_fork_works=yes + ;; + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5 +$as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;} +fi +ac_cv_func_vfork_works=$ac_cv_func_vfork +if test "x$ac_cv_func_vfork" = xyes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5 +$as_echo_n "checking for working vfork... " >&6; } +if test "${ac_cv_func_vfork_works+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ac_cv_func_vfork_works=cross +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* Thanks to Paul Eggert for this test. */ +$ac_includes_default +#include +#ifdef HAVE_VFORK_H +# include +#endif +/* On some sparc systems, changes by the child to local and incoming + argument registers are propagated back to the parent. The compiler + is told about this with #include , but some compilers + (e.g. gcc -O) don't grok . Test for this by using a + static variable whose address is put into a register that is + clobbered by the vfork. */ +static void +#ifdef __cplusplus +sparc_address_test (int arg) +# else +sparc_address_test (arg) int arg; +#endif +{ + static pid_t child; + if (!child) { + child = vfork (); + if (child < 0) { + perror ("vfork"); + _exit(2); + } + if (!child) { + arg = getpid(); + write(-1, "", 0); + _exit (arg); + } + } +} -enable_dlopen=no -enable_win32_dll=no +int +main () +{ + pid_t parent = getpid (); + pid_t child; -# Check whether --enable-libtool-lock was given. -if test "${enable_libtool_lock+set}" = set; then : - enableval=$enable_libtool_lock; -fi + sparc_address_test (0); -test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes + child = vfork (); + if (child == 0) { + /* Here is another test for sparc vfork register problems. This + test uses lots of local variables, at least as many local + variables as main has allocated so far including compiler + temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris + 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should + reuse the register of parent for one of the local variables, + since it will think that parent can't possibly be used any more + in this routine. Assigning to the local variable will thus + munge parent in the parent process. */ + pid_t + p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(), + p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid(); + /* Convince the compiler that p..p7 are live; otherwise, it might + use the same hardware register for all 8 local variables. */ + if (p != p1 || p != p2 || p != p3 || p != p4 + || p != p5 || p != p6 || p != p7) + _exit(1); + + /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent + from child file descriptors. If the child closes a descriptor + before it execs or exits, this munges the parent's descriptor + as well. Test for this by closing stdout in the child. */ + _exit(close(fileno(stdout)) != 0); + } else { + int status; + struct stat st; -# Check whether --with-pic was given. -if test "${with_pic+set}" = set; then : - withval=$with_pic; pic_mode="$withval" + while (wait(&status) != child) + ; + return ( + /* Was there some problem with vforking? */ + child < 0 + + /* Did the child fail? (This shouldn't happen.) */ + || status + + /* Did the vfork/compiler bug occur? */ + || parent != getpid() + + /* Did the file descriptor bug occur? */ + || fstat(fileno(stdout), &st) != 0 + ); + } +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_func_vfork_works=yes else - pic_mode=default + ac_cv_func_vfork_works=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -test -z "$pic_mode" && pic_mode=default +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5 +$as_echo "$ac_cv_func_vfork_works" >&6; } -# Use C for the default configuration in the libtool script -tagname= -lt_save_CC="$CC" -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu +fi; +if test "x$ac_cv_func_fork_works" = xcross; then + ac_cv_func_vfork_works=$ac_cv_func_vfork + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5 +$as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;} +fi +if test "x$ac_cv_func_vfork_works" = xyes; then -# Source file extension for C test sources. -ac_ext=c +$as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h -# Object file extension for compiled C test sources. -objext=o -objext=$objext +else -# Code to be used in simple compile tests -lt_simple_compile_test_code="int some_variable = 0;\n" +$as_echo "#define vfork fork" >>confdefs.h -# Code to be used in simple link tests -lt_simple_link_test_code='int main(){return(0);}\n' +fi +if test "x$ac_cv_func_fork_works" = xyes; then +$as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} +fi -# Allow CC to be a program name with arguments. -compiler=$CC + for ac_func in mmap canonicalize_file_name snprintf strdup strchr \ + strrchr strsignal +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +eval as_val=\$$as_ac_var + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF +fi +done -# save warnings/boilerplate of simple test code -ac_outfile=conftest.$ac_objext -printf "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$rm conftest* + INVOKE_LIBOPTS_MACROS_FIRST_done=yes +fi + # Check to see if a reg expr header is specified. -ac_outfile=conftest.$ac_objext -printf "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$rm conftest* +# Check whether --with-regex-header was given. +if test "${with_regex_header+set}" = set; then : + withval=$with_regex_header; libopts_cv_with_regex_header=${with_regex_header} +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a reg expr header is specified" >&5 +$as_echo_n "checking whether a reg expr header is specified... " >&6; } +if test "${libopts_cv_with_regex_header+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + libopts_cv_with_regex_header=no +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_regex_header" >&5 +$as_echo "$libopts_cv_with_regex_header" >&6; } -# -# Check for any special shared library compilation flags. -# -lt_prog_cc_shlib= -if test "$GCC" = no; then - case $host_os in - sco3.2v5*) - lt_prog_cc_shlib='-belf' - ;; - esac fi -if test -n "$lt_prog_cc_shlib"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' requires \`$lt_prog_cc_shlib' to build shared libraries" >&5 -$as_echo "$as_me: WARNING: \`$CC' requires \`$lt_prog_cc_shlib' to build shared libraries" >&2;} - if echo "$old_CC $old_CFLAGS " | grep "[ ]$lt_prog_cc_shlib[ ]" >/dev/null; then : + # end of AC_ARG_WITH + + if test "X${libopts_cv_with_regex_header}" != Xno + then + cat >>confdefs.h <<_ACEOF +#define REGEX_HEADER <${libopts_cv_with_regex_header}> +_ACEOF + else - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: add \`$lt_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&5 -$as_echo "$as_me: WARNING: add \`$lt_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&2;} - lt_cv_prog_cc_can_build_shared=no + +$as_echo "#define REGEX_HEADER " >>confdefs.h + fi -fi -# -# Check to make sure the static flag actually works. -# -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_prog_compiler_static works" >&5 -$as_echo_n "checking if $compiler static flag $lt_prog_compiler_static works... " >&6; } -if test "${lt_prog_compiler_static_works+set}" = set; then : - $as_echo_n "(cached) " >&6 + + # Check to see if a working libregex can be found. + + +# Check whether --with-libregex was given. +if test "${with_libregex+set}" = set; then : + withval=$with_libregex; libopts_cv_with_libregex_root=${with_libregex} else - lt_prog_compiler_static_works=no - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS $lt_prog_compiler_static" - printf "$lt_simple_link_test_code" > conftest.$ac_ext - if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then - # The linker can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - # Append any errors to the config.log. - cat conftest.err 1>&5 - $echo "X$_lt_linker_boilerplate" | $Xsed > conftest.exp - $SED '/^$/d' conftest.err >conftest.er2 - if diff conftest.exp conftest.er2 >/dev/null; then - lt_prog_compiler_static_works=yes - fi - else - lt_prog_compiler_static_works=yes - fi - fi - $rm conftest* - LDFLAGS="$save_LDFLAGS" - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_static_works" >&5 -$as_echo "$lt_prog_compiler_static_works" >&6; } - -if test x"$lt_prog_compiler_static_works" = xyes; then - : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether with-libregex was specified" >&5 +$as_echo_n "checking whether with-libregex was specified... " >&6; } +if test "${libopts_cv_with_libregex_root+set}" = set; then : + $as_echo_n "(cached) " >&6 else - lt_prog_compiler_static= + libopts_cv_with_libregex_root=no fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_libregex_root" >&5 +$as_echo "$libopts_cv_with_libregex_root" >&6; } +fi + # end of AC_ARG_WITH libregex + if test "${with_libguile+set}" = set && \ + test "${withval}" = no + then ## disabled by request + libopts_cv_with_libregex_root=no + libopts_cv_with_libregex_cflags=no + libopts_cv_with_libregex_libs=no + else -lt_prog_compiler_no_builtin_flag= - -if test "$GCC" = yes; then - lt_prog_compiler_no_builtin_flag=' -fno-builtin' - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 -$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } -if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then : +# Check whether --with-libregex-cflags was given. +if test "${with_libregex_cflags+set}" = set; then : + withval=$with_libregex_cflags; libopts_cv_with_libregex_cflags=${with_regex_cflags} +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether with-libregex-cflags was specified" >&5 +$as_echo_n "checking whether with-libregex-cflags was specified... " >&6; } +if test "${libopts_cv_with_libregex_cflags+set}" = set; then : $as_echo_n "(cached) " >&6 else - lt_cv_prog_compiler_rtti_exceptions=no - ac_outfile=conftest.$ac_objext - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="-fno-rtti -fno-exceptions" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:6177: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:6181: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp - $SED '/^$/d' conftest.err >conftest.er2 - if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_rtti_exceptions=yes - fi - fi - $rm conftest* + libopts_cv_with_libregex_cflags=no +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_libregex_cflags" >&5 +$as_echo "$libopts_cv_with_libregex_cflags" >&6; } fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 -$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } + # end of AC_ARG_WITH libregex-cflags -if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then - lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" + +# Check whether --with-libregex-libs was given. +if test "${with_libregex_libs+set}" = set; then : + withval=$with_libregex_libs; libopts_cv_with_libregex_libs=${with_regex_libs} else - : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether with-libregex-libs was specified" >&5 +$as_echo_n "checking whether with-libregex-libs was specified... " >&6; } +if test "${libopts_cv_with_libregex_libs+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + libopts_cv_with_libregex_libs=no fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_libregex_libs" >&5 +$as_echo "$libopts_cv_with_libregex_libs" >&6; } fi + # end of AC_ARG_WITH libregex-libs -lt_prog_compiler_wl= -lt_prog_compiler_pic= -lt_prog_compiler_static= + case "X${libopts_cv_with_libregex_cflags}" in + Xyes|Xno|X ) + case "X${libopts_cv_with_libregex_root}" in + Xyes|Xno|X ) libopts_cv_with_libregex_cflags=no ;; + * ) libopts_cv_with_libregex_cflags=-I${libopts_cv_with_libregex_root}/include ;; + esac + esac + case "X${libopts_cv_with_libregex_libs}" in + Xyes|Xno|X ) + case "X${libopts_cv_with_libregex_root}" in + Xyes|Xno|X ) libopts_cv_with_libregex_libs=no ;; + * ) libopts_cv_with_libregex_libs="-L${libopts_cv_with_libregex_root}/lib -lregex";; + esac + esac + libopts_save_CPPFLAGS="${CPPFLAGS}" + libopts_save_LIBS="${LIBS}" + fi ## disabled by request -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 -$as_echo_n "checking for $compiler option to produce PIC... " >&6; } + case "X${libopts_cv_with_libregex_cflags}" in + Xyes|Xno|X ) + libopts_cv_with_libregex_cflags="" ;; + * ) CPPFLAGS="${CPPFLAGS} ${libopts_cv_with_libregex_cflags}" ;; + esac + case "X${libopts_cv_with_libregex_libs}" in + Xyes|Xno|X ) + libopts_cv_with_libregex_libs="" ;; + * ) + LIBS="${LIBS} ${libopts_cv_with_libregex_libs}" ;; + esac + LIBREGEX_CFLAGS="" + LIBREGEX_LIBS="" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether libregex functions properly" >&5 +$as_echo_n "checking whether libregex functions properly... " >&6; } + if test "${libopts_cv_with_libregex+set}" = set; then : + $as_echo_n "(cached) " >&6 +else - if test "$GCC" = yes; then - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_static='-static' + if test "$cross_compiling" = yes; then : + libopts_cv_with_libregex=no +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#include +#include REGEX_HEADER +static regex_t re; +void comp_re( char const* pzPat ) { + int res = regcomp( &re, pzPat, REG_EXTENDED|REG_ICASE|REG_NEWLINE ); + if (res == 0) return; + exit( res ); } +int main() { + regmatch_t m[2]; + comp_re( "^.*\$" ); + comp_re( "()|no.*" ); + comp_re( "." ); + if (regexec( &re, "X", 2, m, 0 ) != 0) return 1; + if ((m[0].rm_so != 0) || (m[0].rm_eo != 1)) { + fputs( "error: regex -->.<-- did not match\n", stderr ); + return 1; + } + return 0; } +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + libopts_cv_with_libregex=yes +else + libopts_cv_with_libregex=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + # end of AC_TRY_RUN - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static='-Bstatic' - fi - ;; +fi + # end of AC_CACHE_VAL for libopts_cv_with_libregex + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_with_libregex}" >&5 +$as_echo "${libopts_cv_with_libregex}" >&6; } - amigaos*) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' - ;; + if test "X${libopts_cv_with_libregex}" != Xno + then - beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; +$as_echo "#define WITH_LIBREGEX 1" >>confdefs.h - mingw* | pw32* | os2*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - lt_prog_compiler_pic='-DDLL_EXPORT' - ;; + else + CPPFLAGS="${libopts_save_CPPFLAGS}" + LIBS="${libopts_save_LIBS}" + fi - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - lt_prog_compiler_pic='-fno-common' - ;; - msdosdjgpp*) - # Just because we use GCC doesn't mean we suddenly get shared libraries - # on systems that don't support them. - lt_prog_compiler_can_build_shared=no - enable_shared=no - ;; - sysv4*MP*) - if test -d /usr/nec; then - lt_prog_compiler_pic=-Kconform_pic - fi - ;; + # Check to see if pathfind(3) works. - hpux*) - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic='-fPIC' - ;; - esac - ;; + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pathfind(3) works" >&5 +$as_echo_n "checking whether pathfind(3) works... " >&6; } + if test "${libopts_cv_run_pathfind+set}" = set; then : + $as_echo_n "(cached) " >&6 +else - *) - lt_prog_compiler_pic='-fPIC' - ;; - esac - else - # PORTME Check for flag to pass linker flags through the system compiler. - case $host_os in - aix*) - lt_prog_compiler_wl='-Wl,' - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static='-Bstatic' - else - lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' - fi - ;; - darwin*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - case $cc_basename in - xlc*) - lt_prog_compiler_pic='-qnocommon' - lt_prog_compiler_wl='-Wl,' - ;; - esac - ;; + if test "$cross_compiling" = yes; then : + libopts_cv_run_pathfind=no - mingw* | pw32* | os2*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - lt_prog_compiler_pic='-DDLL_EXPORT' - ;; +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +int main (int argc, char** argv) { + char* pz = pathfind( getenv( "PATH" ), "sh", "x" ); + return (pz == 0) ? 1 : 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + libopts_cv_run_pathfind=yes +else + libopts_cv_run_pathfind=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + # end of TRY_RUN - hpux9* | hpux10* | hpux11*) - lt_prog_compiler_wl='-Wl,' - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic='+Z' - ;; - esac - # Is there a better lt_prog_compiler_static that works with the bundled CC? - lt_prog_compiler_static='${wl}-a ${wl}archive' - ;; +fi + # end of AC_CACHE_VAL for libopts_cv_run_pathfind + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_pathfind}" >&5 +$as_echo "${libopts_cv_run_pathfind}" >&6; } - irix5* | irix6* | nonstopux*) - lt_prog_compiler_wl='-Wl,' - # PIC (with -KPIC) is the default. - lt_prog_compiler_static='-non_shared' - ;; + if test "X${libopts_cv_run_pathfind}" != Xno + then - newsos6) - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - ;; +$as_echo "#define HAVE_PATHFIND 1" >>confdefs.h - linux*) - case $cc_basename in - icc* | ecc*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-static' - ;; - pgcc* | pgf77* | pgf90* | pgf95*) - # Portland Group compilers (*not* the Pentium gcc compiler, - # which looks to be a dead project) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-fpic' - lt_prog_compiler_static='-Bstatic' - ;; - ccc*) - lt_prog_compiler_wl='-Wl,' - # All Alpha code is PIC. - lt_prog_compiler_static='-non_shared' - ;; - esac - ;; + fi - osf3* | osf4* | osf5*) - lt_prog_compiler_wl='-Wl,' - # All OSF/1 code is PIC. - lt_prog_compiler_static='-non_shared' - ;; - sco3.2v5*) - lt_prog_compiler_pic='-Kpic' - lt_prog_compiler_static='-dn' - ;; - solaris*) - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - case $cc_basename in - f77* | f90* | f95*) - lt_prog_compiler_wl='-Qoption ld ';; - *) - lt_prog_compiler_wl='-Wl,';; - esac - ;; + # Check to see if /dev/zero is readable device. - sunos4*) - lt_prog_compiler_wl='-Qoption ld ' - lt_prog_compiler_pic='-PIC' - lt_prog_compiler_static='-Bstatic' - ;; + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether /dev/zero is readable device" >&5 +$as_echo_n "checking whether /dev/zero is readable device... " >&6; } + if test "${libopts_cv_test_dev_zero+set}" = set; then : + $as_echo_n "(cached) " >&6 +else - sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - ;; + libopts_cv_test_dev_zero=`exec 2> /dev/null +dzero=\`ls -lL /dev/zero | egrep ^c......r\` +test -z "${dzero}" && exit 1 +echo ${dzero}` + if test $? -ne 0 + then libopts_cv_test_dev_zero=no + elif test -z "$libopts_cv_test_dev_zero" + then libopts_cv_test_dev_zero=no + fi - sysv4*MP*) - if test -d /usr/nec ;then - lt_prog_compiler_pic='-Kconform_pic' - lt_prog_compiler_static='-Bstatic' - fi - ;; +fi + # end of CACHE_VAL of libopts_cv_test_dev_zero + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_test_dev_zero}" >&5 +$as_echo "${libopts_cv_test_dev_zero}" >&6; } - unicos*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_can_build_shared=no - ;; + if test "X${libopts_cv_test_dev_zero}" != Xno + then - uts4*) - lt_prog_compiler_pic='-pic' - lt_prog_compiler_static='-Bstatic' - ;; +$as_echo "#define HAVE_DEV_ZERO 1" >>confdefs.h - *) - lt_prog_compiler_can_build_shared=no - ;; - esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic" >&5 -$as_echo "$lt_prog_compiler_pic" >&6; } -# -# Check to make sure the PIC flag actually works. -# -if test -n "$lt_prog_compiler_pic"; then -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 -$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } -if test "${lt_prog_compiler_pic_works+set}" = set; then : + # Check to see if we have a functional realpath(3C). + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we have a functional realpath(3C)" >&5 +$as_echo_n "checking whether we have a functional realpath(3C)... " >&6; } + if test "${libopts_cv_run_realpath+set}" = set; then : $as_echo_n "(cached) " >&6 else - lt_prog_compiler_pic_works=no - ac_outfile=conftest.$ac_objext - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$lt_prog_compiler_pic -DPIC" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:6439: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:6443: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp - $SED '/^$/d' conftest.err >conftest.er2 - if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then - lt_prog_compiler_pic_works=yes - fi - fi - $rm conftest* -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic_works" >&5 -$as_echo "$lt_prog_compiler_pic_works" >&6; } + if test "$cross_compiling" = yes; then : + libopts_cv_run_realpath=no -if test x"$lt_prog_compiler_pic_works" = xyes; then - case $lt_prog_compiler_pic in - "" | " "*) ;; - *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; - esac else - lt_prog_compiler_pic= - lt_prog_compiler_can_build_shared=no + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +int main (int argc, char** argv) { +#ifndef PATH_MAX +choke me!! +#else + char zPath[PATH_MAX+1]; +#endif + char *pz = realpath(argv[0], zPath); + return (pz == zPath) ? 0 : 1; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + libopts_cv_run_realpath=yes +else + libopts_cv_run_realpath=no fi - +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -case $host_os in - # For platforms which do not support PIC, -DPIC is meaningless: - *djgpp*) - lt_prog_compiler_pic= - ;; - *) - lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" - ;; -esac + # end of TRY_RUN -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 -$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } -if test "${lt_cv_prog_compiler_c_o+set}" = set; then : +fi + # end of AC_CACHE_VAL for libopts_cv_run_realpath + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_realpath}" >&5 +$as_echo "${libopts_cv_run_realpath}" >&6; } + + if test "X${libopts_cv_run_realpath}" != Xno + then + +$as_echo "#define HAVE_REALPATH 1" >>confdefs.h + + fi + + + + # Check to see if strftime() works. + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strftime() works" >&5 +$as_echo_n "checking whether strftime() works... " >&6; } + if test "${libopts_cv_run_strftime+set}" = set; then : $as_echo_n "(cached) " >&6 else - lt_cv_prog_compiler_c_o=no - $rm -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:6501: $lt_compile\"" >&5) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&5 - echo "$as_me:6505: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $echo "X$_lt_compiler_boilerplate" | $Xsed > out/conftest.exp - $SED '/^$/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.err || diff out/conftest.exp out/conftest.er2 >/dev/null; then - lt_cv_prog_compiler_c_o=yes - fi - fi - chmod u+w . 2>&5 - $rm conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files - $rm out/* && rmdir out - cd .. - rmdir conftest - $rm conftest* + if test "$cross_compiling" = yes; then : + libopts_cv_run_strftime=no + +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +char t_buf[ 64 ]; +int main() { + static char const z[] = "Thursday Aug 28 240"; + struct tm tm; + tm.tm_sec = 36; /* seconds after the minute [0, 61] */ + tm.tm_min = 44; /* minutes after the hour [0, 59] */ + tm.tm_hour = 12; /* hour since midnight [0, 23] */ + tm.tm_mday = 28; /* day of the month [1, 31] */ + tm.tm_mon = 7; /* months since January [0, 11] */ + tm.tm_year = 86; /* years since 1900 */ + tm.tm_wday = 4; /* days since Sunday [0, 6] */ + tm.tm_yday = 239; /* days since January 1 [0, 365] */ + tm.tm_isdst = 1; /* flag for daylight savings time */ + strftime( t_buf, sizeof( t_buf ), "%A %b %d %j", &tm ); + return (strcmp( t_buf, z ) != 0); } +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + libopts_cv_run_strftime=yes +else + libopts_cv_run_strftime=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + # end of TRY_RUN fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 -$as_echo "$lt_cv_prog_compiler_c_o" >&6; } + # end of AC_CACHE_VAL for libopts_cv_run_strftime + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_strftime}" >&5 +$as_echo "${libopts_cv_run_strftime}" >&6; } + if test "X${libopts_cv_run_strftime}" != Xno + then + +$as_echo "#define HAVE_STRFTIME 1" >>confdefs.h -hard_links="nottested" -if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then - # do not overwrite the value of need_locks provided by the user - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 -$as_echo_n "checking if we can lock with hard links... " >&6; } - hard_links=yes - $rm conftest* - ln conftest.a conftest.b 2>/dev/null && hard_links=no - touch conftest.a - ln conftest.a conftest.b 2>&5 || hard_links=no - ln conftest.a conftest.b 2>/dev/null && hard_links=no - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 -$as_echo "$hard_links" >&6; } - if test "$hard_links" = no; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 -$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} - need_locks=warn fi + + + + # Check to see if fopen accepts "b" mode. + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fopen accepts \"b\" mode" >&5 +$as_echo_n "checking whether fopen accepts \"b\" mode... " >&6; } + if test "${libopts_cv_run_fopen_binary+set}" = set; then : + $as_echo_n "(cached) " >&6 else - need_locks=no + + if test "$cross_compiling" = yes; then : + libopts_cv_run_fopen_binary=no + +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int main (int argc, char** argv) { +FILE* fp = fopen("conftest.$ac_ext", "rb"); +return (fp == NULL) ? 1 : fclose(fp); } +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + libopts_cv_run_fopen_binary=yes +else + libopts_cv_run_fopen_binary=no fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + # end of TRY_RUN -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 -$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } +fi + # end of AC_CACHE_VAL for libopts_cv_run_fopen_binary + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_fopen_binary}" >&5 +$as_echo "${libopts_cv_run_fopen_binary}" >&6; } - runpath_var= - allow_undefined_flag= - enable_shared_with_static_runtimes=no - archive_cmds= - archive_expsym_cmds= - old_archive_From_new_cmds= - old_archive_from_expsyms_cmds= - export_dynamic_flag_spec= - whole_archive_flag_spec= - thread_safe_flag_spec= - hardcode_libdir_flag_spec= - hardcode_libdir_flag_spec_ld= - hardcode_libdir_separator= - hardcode_direct=no - hardcode_minus_L=no - hardcode_shlibpath_var=unsupported - link_all_deplibs=unknown - hardcode_automatic=no - module_cmds= - module_expsym_cmds= - always_export_symbols=no - export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - # include_expsyms should be a list of space-separated symbols to be *always* - # included in the symbol list - include_expsyms= - # exclude_expsyms can be an extended regexp of symbols to exclude - # it will be wrapped by ` (' and `)$', so one must not match beginning or - # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', - # as well as any symbol that contains `d'. - exclude_expsyms="_GLOBAL_OFFSET_TABLE_" - # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out - # platforms (ab)use it in PIC code, but their linkers get confused if - # the symbol is explicitly referenced. Since portable code cannot - # rely on this symbol name, it's probably fine to never include it in - # preloaded symbol tables. - extract_expsyms_cmds= - # Just being paranoid about ensuring that cc_basename is set. - for cc_temp in $compiler""; do - case $cc_temp in - compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; - distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` + if test "X${libopts_cv_run_fopen_binary}" != Xno + then - case $host_os in - cygwin* | mingw* | pw32*) - # FIXME: the MSVC++ port hasn't been tested in a loooong time - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - if test "$GCC" != yes; then - with_gnu_ld=no - fi - ;; - openbsd*) - with_gnu_ld=no - ;; - esac +$as_echo "#define FOPEN_BINARY_FLAG \"b\"" >>confdefs.h - ld_shlibs=yes - if test "$with_gnu_ld" = yes; then - # If archive_cmds runs LD, not CC, wlarc should be empty - wlarc='${wl}' + else - # Set some defaults for GNU ld with shared library support. These - # are reset later if shared libraries are not supported. Putting them - # here allows them to be overridden if necessary. - runpath_var=LD_RUN_PATH - hardcode_libdir_flag_spec='${wl}--rpath ${wl}$libdir' - export_dynamic_flag_spec='${wl}--export-dynamic' - # ancient GNU ld didn't support --whole-archive et. al. - if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then - whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - else - whole_archive_flag_spec= - fi - supports_anon_versioning=no - case `$LD -v 2>/dev/null` in - *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 - *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... - *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... - *\ 2.11.*) ;; # other 2.11 versions - *) supports_anon_versioning=yes ;; - esac +$as_echo "#define FOPEN_BINARY_FLAG \"\"" >>confdefs.h - # See if GNU ld supports shared libraries. - case $host_os in - aix3* | aix4* | aix5*) - # On AIX/PPC, the GNU linker is very broken - if test "$host_cpu" != ia64; then - ld_shlibs=no - cat <&2 + fi -*** Warning: the GNU linker, at least up to release 2.9.1, is reported -*** to be unable to reliably create shared libraries on AIX. -*** Therefore, libtool is disabling shared libraries support. If you -*** really care for shared libraries, you may want to modify your PATH -*** so that a non-GNU linker is found, and then restart. -EOF - fi - ;; - amigaos*) - archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes + # Check to see if fopen accepts "t" mode. - # Samuel A. Falvo II reports - # that the semantics of dynamic libraries on AmigaOS, at least up - # to version 4, is to share data among multiple programs linked - # with the same dynamic library. Since this doesn't match the - # behavior of shared libraries on other platforms, we can't use - # them. - ld_shlibs=no - ;; + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fopen accepts \"t\" mode" >&5 +$as_echo_n "checking whether fopen accepts \"t\" mode... " >&6; } + if test "${libopts_cv_run_fopen_text+set}" = set; then : + $as_echo_n "(cached) " >&6 +else - beos*) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - allow_undefined_flag=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - else - ld_shlibs=no - fi - ;; + if test "$cross_compiling" = yes; then : + libopts_cv_run_fopen_text=no - cygwin* | mingw* | pw32*) - # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, - # as there is no search path for DLLs. - hardcode_libdir_flag_spec='-L$libdir' - allow_undefined_flag=unsupported - always_export_symbols=no - enable_shared_with_static_runtimes=yes - export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS] /s/.* \([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW] /s/.* //'\'' | sort | uniq > $export_symbols' +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int main (int argc, char** argv) { +FILE* fp = fopen("conftest.$ac_ext", "rt"); +return (fp == NULL) ? 1 : fclose(fp); } +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + libopts_cv_run_fopen_text=yes +else + libopts_cv_run_fopen_text=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + # end of TRY_RUN - if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - else - ld_shlibs=no - fi - ;; +fi + # end of AC_CACHE_VAL for libopts_cv_run_fopen_text + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_fopen_text}" >&5 +$as_echo "${libopts_cv_run_fopen_text}" >&6; } - linux*) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - tmp_addflag= - case $cc_basename,$host_cpu in - pgcc*) # Portland Group C compiler - whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag' - ;; - pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers - whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag -Mnomain' ;; - ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 - tmp_addflag=' -i_dynamic' ;; - efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 - tmp_addflag=' -i_dynamic -nofor_main' ;; - ifc* | ifort*) # Intel Fortran compiler - tmp_addflag=' -nofor_main' ;; - esac - archive_cmds='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + if test "X${libopts_cv_run_fopen_text}" != Xno + then - if test $supports_anon_versioning = yes; then - archive_expsym_cmds='$echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - $echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' - fi - else - ld_shlibs=no - fi - ;; +$as_echo "#define FOPEN_TEXT_FLAG \"t\"" >>confdefs.h - netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' - wlarc= - else - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - fi - ;; + else - solaris* | sysv5*) - if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then - ld_shlibs=no - cat <&2 +$as_echo "#define FOPEN_TEXT_FLAG \"\"" >>confdefs.h -*** Warning: The releases 2.8.* of the GNU linker cannot reliably -*** create shared libraries on Solaris systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.9.1 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. + fi -EOF - elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi - ;; - sunos4*) - archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' - wlarc= - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - *) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi - ;; - esac + # Check to see if not wanting optional option args. - if test "$ld_shlibs" = no; then - runpath_var= - hardcode_libdir_flag_spec= - export_dynamic_flag_spec= - whole_archive_flag_spec= - fi - else - # PORTME fill in a description of your system's linker (not GNU ld) - case $host_os in - aix3*) - allow_undefined_flag=unsupported - always_export_symbols=yes - archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' - # Note: this linker hardcodes the directories in LIBPATH if there - # are no directories specified by -L. - hardcode_minus_L=yes - if test "$GCC" = yes && test -z "$link_static_flag"; then - # Neither direct hardcoding nor static linking is supported with a - # broken collect2. - hardcode_direct=unsupported - fi - ;; + # Check whether --enable-optional-args was given. +if test "${enable_optional_args+set}" = set; then : + enableval=$enable_optional_args; libopts_cv_enable_optional_args=${enable_optional_args} +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether not wanting optional option args" >&5 +$as_echo_n "checking whether not wanting optional option args... " >&6; } +if test "${libopts_cv_enable_optional_args+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + libopts_cv_enable_optional_args=yes +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_enable_optional_args" >&5 +$as_echo "$libopts_cv_enable_optional_args" >&6; } - aix4* | aix5*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - if $NM -V 2>&1 | grep 'GNU' > /dev/null; then - export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' - else - export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' - fi - aix_use_runtimelinking=no +fi + # end of AC_ARG_ENABLE - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[23]|aix4.[23].*|aix5*) - for ld_flag in $LDFLAGS; do - if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then - aix_use_runtimelinking=yes - break - fi - done - esac + if test "X${libopts_cv_enable_optional_args}" = Xno + then - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi +$as_echo "#define NO_OPTIONAL_OPT_ARGS 1" >>confdefs.h - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + fi - archive_cmds='' - hardcode_direct=yes - hardcode_libdir_separator=':' - link_all_deplibs=yes - if test "$GCC" = yes; then - case $host_os in aix4.[012]|aix4.[012].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && \ - strings "$collect2name" | grep resolve_lib_name >/dev/null - then - # We have reworked collect2 - hardcode_direct=yes - else - # We have old collect2 - hardcode_direct=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - hardcode_minus_L=yes - hardcode_libdir_flag_spec='-L$libdir' - hardcode_libdir_separator= - fi - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi - fi - fi - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to export. - always_export_symbols=yes - if test "$aix_use_runtimelinking" = yes; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - allow_undefined_flag='-berok' - # Determine the default libpath from the value encoded in an empty executable. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + else + +if test X${INVOKE_LIBOPTS_MACROS_FIRST_done} != Xyes ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 +$as_echo_n "checking for ANSI C header files... " >&6; } +if test "${ac_cv_header_stdc+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ +#include +#include +#include +#include int main () @@ -6913,1263 +6678,679 @@ return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_header_stdc=yes +else + ac_cv_header_stdc=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'` -# Check for a 64-bit object if we didn't find anything. -if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'`; fi +if test $ac_cv_header_stdc = yes; then + # SunOS 4.x string.h does not declare mem*, contrary to ANSI. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "memchr" >/dev/null 2>&1; then : + +else + ac_cv_header_stdc=no fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi +rm -f conftest* - hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" - archive_expsym_cmds="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag" - else - if test "$host_cpu" = ia64; then - hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib' - allow_undefined_flag="-z nodefs" - archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols" - else - # Determine the default libpath from the value encoded in an empty executable. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext +fi + +if test $ac_cv_header_stdc = yes; then + # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "free" >/dev/null 2>&1; then : + +else + ac_cv_header_stdc=no +fi +rm -f conftest* + +fi + +if test $ac_cv_header_stdc = yes; then + # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. + if test "$cross_compiling" = yes; then : + : +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ +#include +#include +#if ((' ' & 0x0FF) == 0x020) +# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') +# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) +#else +# define ISLOWER(c) \ + (('a' <= (c) && (c) <= 'i') \ + || ('j' <= (c) && (c) <= 'r') \ + || ('s' <= (c) && (c) <= 'z')) +# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) +#endif +#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) int main () { - - ; + int i; + for (i = 0; i < 256; i++) + if (XOR (islower (i), ISLOWER (i)) + || toupper (i) != TOUPPER (i)) + return 2; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_run "$LINENO"; then : -aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'` -# Check for a 64-bit object if we didn't find anything. -if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'`; fi +else + ac_cv_header_stdc=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi - - hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - no_undefined_flag=' ${wl}-bernotok' - allow_undefined_flag=' ${wl}-berok' - # -bexpall does not export symbols beginning with underscore (_) - always_export_symbols=yes - # Exported symbols can be pulled into shared objects from archives - whole_archive_flag_spec=' ' - archive_cmds_need_lc=yes - # This is similar to how AIX traditionally builds its shared libraries. - archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' - fi - fi - ;; - amigaos*) - archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - # see comment about different semantics on the GNU ld section - ld_shlibs=no - ;; +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 +$as_echo "$ac_cv_header_stdc" >&6; } +if test $ac_cv_header_stdc = yes; then - bsdi[45]*) - export_dynamic_flag_spec=-rdynamic - ;; +$as_echo "#define STDC_HEADERS 1" >>confdefs.h - cygwin* | mingw* | pw32*) - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - hardcode_libdir_flag_spec=' ' - allow_undefined_flag=unsupported - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" - # FIXME: Setting linknames here is a bad hack. - archive_cmds='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' - # The linker will automatically build a .lib file if we build a DLL. - old_archive_From_new_cmds='true' - # FIXME: Should let the user specify the lib program. - old_archive_cmds='lib /OUT:$oldlib$oldobjs$old_deplibs' - fix_srcfile_path='`cygpath -w "$srcfile"`' - enable_shared_with_static_runtimes=yes - ;; +fi - darwin* | rhapsody*) - case $host_os in - rhapsody* | darwin1.[012]) - allow_undefined_flag='${wl}-undefined ${wl}suppress' - ;; - *) # Darwin 1.3 on - if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then - allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - else - case ${MACOSX_DEPLOYMENT_TARGET} in - 10.[012]) - allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - ;; - 10.*) - allow_undefined_flag='${wl}-undefined ${wl}dynamic_lookup' - ;; - esac - fi - ;; - esac - archive_cmds_need_lc=no - hardcode_direct=no - hardcode_automatic=yes - hardcode_shlibpath_var=unsupported - whole_archive_flag_spec='' - link_all_deplibs=yes - if test "$GCC" = yes ; then - output_verbose_link_cmd='echo' - archive_cmds='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' - module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds - archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - module_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - else - case $cc_basename in - xlc*) - output_verbose_link_cmd='echo' - archive_cmds='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring' - module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds - archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - module_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - ;; - *) - ld_shlibs=no - ;; - esac - fi - ;; + ac_header_dirent=no +for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do + as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5 +$as_echo_n "checking for $ac_hdr that defines DIR... " >&6; } +if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include <$ac_hdr> - dgux*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_shlibpath_var=no - ;; - - freebsd1*) - ld_shlibs=no - ;; +int +main () +{ +if ((DIR *) 0) +return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + eval "$as_ac_Header=yes" +else + eval "$as_ac_Header=no" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$as_ac_Header + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } +eval as_val=\$$as_ac_Header + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 +_ACEOF - # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor - # support. Future versions do this automatically, but an explicit c++rt0.o - # does not break anything, and helps significantly (at the cost of a little - # extra space). - freebsd2.2*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; +ac_header_dirent=$ac_hdr; break +fi - # Unfortunately, older versions of FreeBSD 2 do not have this feature. - freebsd2*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes - hardcode_minus_L=yes - hardcode_shlibpath_var=no - ;; +done +# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. +if test $ac_header_dirent = dirent.h; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 +$as_echo_n "checking for library containing opendir... " >&6; } +if test "${ac_cv_search_opendir+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - # FreeBSD 3 and greater uses gcc -shared to do shared libraries. - freebsd* | kfreebsd*-gnu | dragonfly*) - archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char opendir (); +int +main () +{ +return opendir (); + ; + return 0; +} +_ACEOF +for ac_lib in '' dir; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_opendir=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if test "${ac_cv_search_opendir+set}" = set; then : + break +fi +done +if test "${ac_cv_search_opendir+set}" = set; then : - hpux9*) - if test "$GCC" = yes; then - archive_cmds='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - else - archive_cmds='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - fi - hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' - hardcode_libdir_separator=: - hardcode_direct=yes +else + ac_cv_search_opendir=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 +$as_echo "$ac_cv_search_opendir" >&6; } +ac_res=$ac_cv_search_opendir +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - export_dynamic_flag_spec='${wl}-E' - ;; +fi - hpux10* | hpux11*) - if test "$GCC" = yes -a "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*|ia64*) - archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - else - case $host_cpu in - hppa*64*|ia64*) - archive_cmds='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags' - ;; - *) - archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' - ;; - esac - fi - if test "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*) - hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' - hardcode_libdir_flag_spec_ld='+b $libdir' - hardcode_libdir_separator=: - hardcode_direct=no - hardcode_shlibpath_var=no - ;; - ia64*) - hardcode_libdir_flag_spec='-L$libdir' - hardcode_direct=no - hardcode_shlibpath_var=no +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 +$as_echo_n "checking for library containing opendir... " >&6; } +if test "${ac_cv_search_opendir+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - ;; - *) - hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' - hardcode_libdir_separator=: - hardcode_direct=yes - export_dynamic_flag_spec='${wl}-E' +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char opendir (); +int +main () +{ +return opendir (); + ; + return 0; +} +_ACEOF +for ac_lib in '' x; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_opendir=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if test "${ac_cv_search_opendir+set}" = set; then : + break +fi +done +if test "${ac_cv_search_opendir+set}" = set; then : - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - ;; - esac - fi - ;; +else + ac_cv_search_opendir=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 +$as_echo "$ac_cv_search_opendir" >&6; } +ac_res=$ac_cv_search_opendir +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" - irix5* | irix6* | nonstopux*) - if test "$GCC" = yes; then - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - hardcode_libdir_flag_spec_ld='-rpath $libdir' - fi - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - link_all_deplibs=yes - ;; +fi - netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out - else - archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF - fi - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; +fi - newsos6) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - hardcode_shlibpath_var=no - ;; - openbsd*) - hardcode_direct=yes - hardcode_shlibpath_var=no - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' - hardcode_libdir_flag_spec='${wl}-rpath,$libdir' - export_dynamic_flag_spec='${wl}-E' - else - case $host_os in - openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-R$libdir' - ;; - *) - archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec='${wl}-rpath,$libdir' - ;; - esac - fi - ;; - - os2*) - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - allow_undefined_flag=unsupported - archive_cmds='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' - old_archive_From_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' - ;; + # ================= + # AC_CHECK_HEADERS + # ================= + for ac_header in dlfcn.h errno.h fcntl.h libgen.h memory.h netinet/in.h \ + setjmp.h sys/mman.h sys/param.h sys/poll.h sys/procset.h sys/select.h \ + sys/socket.h sys/stropts.h sys/time.h sys/un.h sys/wait.h unistd.h \ + utime.h sysexits.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +eval as_val=\$$as_ac_Header + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF - osf3*) - if test "$GCC" = yes; then - allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' - archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - allow_undefined_flag=' -expect_unresolved \*' - archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - fi - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - ;; +fi - osf4* | osf5*) # as osf3* with the addition of -msym flag - if test "$GCC" = yes; then - allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' - archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - else - allow_undefined_flag=' -expect_unresolved \*' - archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ - $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' +done - # Both c and cxx compiler support -rpath directly - hardcode_libdir_flag_spec='-rpath $libdir' - fi - hardcode_libdir_separator=: - ;; - sco3.2v5*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var=no - export_dynamic_flag_spec='${wl}-Bexport' - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - ;; + # -------------------------------------------- + # Verify certain entries from AC_CHECK_HEADERS + # -------------------------------------------- + for f in sys_types sys_mman sys_param sys_stat sys_wait \ + string errno stdlib memory setjmp + do eval as_ac_var=\${ac_cv_header_${f}_h+set} + test "${as_ac_var}" = set || \ + as_fn_error "You must have ${f}.h on your system" "$LINENO" 5 + done - solaris*) - no_undefined_flag=' -z text' - if test "$GCC" = yes; then - wlarc='${wl}' - archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' - else - wlarc='' - archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' - fi - hardcode_libdir_flag_spec='-R$libdir' - hardcode_shlibpath_var=no - case $host_os in - solaris2.[0-5] | solaris2.[0-5].*) ;; - *) - # The compiler driver will combine linker options so we - # cannot just pass the convience library names through - # without $wl, iff we do not link with $LD. - # Luckily, gcc supports the same syntax we need for Sun Studio. - # Supported since Solaris 2.6 (maybe 2.5.1?) - case $wlarc in - '') - whole_archive_flag_spec='-z allextract$convenience -z defaultextract' ;; - *) - whole_archive_flag_spec='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract' ;; - esac ;; - esac - link_all_deplibs=yes - ;; + # ================================================ + # AC_CHECK_HEADERS: stdarg.h is present define HAVE_STDARG_H, otherwise + # if varargs.h is present define HAVE_VARARGS_H. + # ================================================ + for ac_header in stdarg.h varargs.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +eval as_val=\$$as_ac_Header + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + break +fi - sunos4*) - if test "x$host_vendor" = xsequent; then - # Use $CC to link under sequent, because it throws in some extra .o - # files that make .init and .fini sections work. - archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' - fi - hardcode_libdir_flag_spec='-L$libdir' - hardcode_direct=yes - hardcode_minus_L=yes - hardcode_shlibpath_var=no - ;; +done - sysv4) - case $host_vendor in - sni) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes # is this really true??? - ;; - siemens) - ## LD is ld it makes a PLAMLIB - ## CC just makes a GrossModule. - archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' - reload_cmds='$CC -r -o $output$reload_objs' - hardcode_direct=no - ;; - motorola) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=no #Motorola manual says yes, but my tests say they lie - ;; - esac - runpath_var='LD_RUN_PATH' - hardcode_shlibpath_var=no - ;; + if test `eval echo '${'$as_ac_Header'}'` != yes; then + as_fn_error "You must have stdarg.h or varargs.h on your system" "$LINENO" 5 + fi - sysv4.3*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var=no - export_dynamic_flag_spec='-Bexport' - ;; + # ================================================ + # Similarly for the string.h and strings.h headers + # ================================================ + for ac_header in string.h strings.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +eval as_val=\$$as_ac_Header + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + break +fi - sysv4*MP*) - if test -d /usr/nec; then - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var=no - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - ld_shlibs=yes - fi - ;; +done - sysv4.2uw2*) - archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes - hardcode_minus_L=no - hardcode_shlibpath_var=no - hardcode_runpath_var=yes - runpath_var=LD_RUN_PATH - ;; + if test `eval echo '${'$as_ac_Header'}'` != yes; then + as_fn_error "You must have string.h or strings.h on your system" "$LINENO" 5 + fi - sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7*) - no_undefined_flag='${wl}-z ${wl}text' - if test "$GCC" = yes; then - archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - runpath_var='LD_RUN_PATH' - hardcode_shlibpath_var=no - ;; + # ===================== + # ...and limits headers + # ===================== + for ac_header in limits.h sys/limits.h values.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +eval as_val=\$$as_ac_Header + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + break +fi - sysv5*) - no_undefined_flag=' -z text' - # $CC -shared without GNU ld will not create a library from C++ - # object files and a static libstdc++, better avoid it by now - archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' - hardcode_libdir_flag_spec= - hardcode_shlibpath_var=no - runpath_var='LD_RUN_PATH' - ;; +done - uts4*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_shlibpath_var=no - ;; + if test `eval echo '${'$as_ac_Header'}'` != yes; then + as_fn_error "You must have one of limits.h, sys/limits.h or values.h" "$LINENO" 5 + fi - *) - ld_shlibs=no - ;; - esac - fi + # ---------------------------------------------------------------------- + # check for various programs used during the build. + # On OS/X, "wchar.h" needs "runetype.h" to work properly. + # ---------------------------------------------------------------------- + for ac_header in runetype.h wchar.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" " + $ac_includes_default + #if HAVE_RUNETYPE_H + # include + #endif -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5 -$as_echo "$ld_shlibs" >&6; } -test "$ld_shlibs" = no && can_build_shared=no +" +eval as_val=\$$as_ac_Header + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF -variables_saved_for_relink="PATH $shlibpath_var $runpath_var" -if test "$GCC" = yes; then - variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi -# -# Do we need to explicitly link libc? -# -case "x$archive_cmds_need_lc" in -x|xyes) - # Assume -lc should be added - archive_cmds_need_lc=yes +done - if test "$enable_shared" = yes && test "$GCC" = yes; then - case $archive_cmds in - *'~'*) - # FIXME: we may have to deal with multi-command sequences. - ;; - '$CC '*) - # Test whether the compiler implicitly links with -lc since on some - # systems, -lgcc has to come before -lc. If gcc already passes -lc - # to ld, don't add -lc before -lgcc. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 -$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } - $rm conftest* - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } 2>conftest.err; then - soname=conftest - lib=conftest - libobjs=conftest.$ac_objext - deplibs= - wl=$lt_prog_compiler_wl - compiler_flags=-v - linker_flags=-v - verstring= - output_objdir=. - libname=conftest - lt_save_allow_undefined_flag=$allow_undefined_flag - allow_undefined_flag= - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\""; } >&5 - (eval $archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - then - archive_cmds_need_lc=no - else - archive_cmds_need_lc=yes - fi - allow_undefined_flag=$lt_save_allow_undefined_flag - else - cat conftest.err 1>&5 - fi - $rm conftest* - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $archive_cmds_need_lc" >&5 -$as_echo "$archive_cmds_need_lc" >&6; } - ;; - esac - fi - ;; -esac + # ---------------------------------------------------------------------- + # Checks for typedefs + # ---------------------------------------------------------------------- + ac_fn_c_check_type "$LINENO" "wchar_t" "ac_cv_type_wchar_t" "$ac_includes_default" +if test "x$ac_cv_type_wchar_t" = x""yes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_WCHAR_T 1 +_ACEOF + -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 -$as_echo_n "checking dynamic linker characteristics... " >&6; } -library_names_spec= -libname_spec='lib$name' -soname_spec= -shrext_cmds=".so" -postinstall_cmds= -postuninstall_cmds= -finish_cmds= -finish_eval= -shlibpath_var= -shlibpath_overrides_runpath=unknown -version_type=none -dynamic_linker="$host_os ld.so" -sys_lib_dlsearch_path_spec="/lib /usr/lib" -if test "$GCC" = yes; then - sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then - # if the path contains ";" then we assume it to be the separator - # otherwise default to the standard path separator (i.e. ":") - it is - # assumed that no part of a normal pathname contains ";" but that should - # okay in the real world where ";" in dirpaths is itself problematic. - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi -else - sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" fi -need_lib_prefix=unknown -hardcode_into_libs=no -# when you set need_version to no, make sure it does not cause -set_version -# flags to be left without arguments -need_version=unknown + ac_fn_c_check_type "$LINENO" "wint_t" "ac_cv_type_wint_t" " + $ac_includes_default + #if HAVE_RUNETYPE_H + # include + #endif + #if HAVE_WCHAR_H + # include + #endif -case $host_os in -aix3*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' - shlibpath_var=LIBPATH +" +if test "x$ac_cv_type_wint_t" = x""yes; then : - # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='${libname}${release}${shared_ext}$major' - ;; +cat >>confdefs.h <<_ACEOF +#define HAVE_WINT_T 1 +_ACEOF -aix4* | aix5*) - version_type=linux - need_lib_prefix=no - need_version=no - hardcode_into_libs=yes - if test "$host_cpu" = ia64; then - # AIX 5 supports IA64 - library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - else - # With GCC up to 2.95.x, collect2 would create an import file - # for dependence libraries. The import file would start with - # the line `#! .'. This would cause the generated library to - # depend on `.', always an invalid library. This was fixed in - # development snapshots of GCC prior to 3.0. - case $host_os in - aix4 | aix4.[01] | aix4.[01].*) - if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' - echo ' yes ' - echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then - : - else - can_build_shared=no - fi - ;; - esac - # AIX (on Power*) has no versioning support, so currently we can not hardcode correct - # soname into executable. Probably we can add versioning support to - # collect2, so additional links can be useful in future. - if test "$aix_use_runtimelinking" = yes; then - # If using run time linking (on AIX 4.2 or later) use lib.so - # instead of lib.a to let people know that these are not - # typical AIX shared libraries. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - else - # We preserve .a as extension for shared libraries through AIX4.2 - # and later when we are not doing run time linking. - library_names_spec='${libname}${release}.a $libname.a' - soname_spec='${libname}${release}${shared_ext}$major' - fi - shlibpath_var=LIBPATH - fi - ;; -amigaos*) - library_names_spec='$libname.ixlibrary $libname.a' - # Create ${libname}_ixlibrary.a entries in /sys/libs. - finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' - ;; +fi -beos*) - library_names_spec='${libname}${shared_ext}' - dynamic_linker="$host_os ld.so" - shlibpath_var=LIBRARY_PATH - ;; -bsdi[45]*) - version_type=linux - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" - # the default ld.so.conf also contains /usr/contrib/lib and - # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow - # libtool to hard-code these into programs - ;; + # ======================== + # ...and int types headers + # ======================== + for ac_header in stdint.h inttypes.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +eval as_val=\$$as_ac_Header + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + break +fi -cygwin* | mingw* | pw32*) - version_type=windows - shrext_cmds=".dll" - need_version=no - need_lib_prefix=no +done - case $GCC,$host_os in - yes,cygwin* | yes,mingw* | yes,pw32*) - library_names_spec='$libname.dll.a' - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $rm \$dlpath' - shlibpath_overrides_runpath=yes + ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "$ac_includes_default" +if test "x$ac_cv_type_int8_t" = x""yes; then : - case $host_os in - cygwin*) - # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" - ;; - mingw*) - # MinGW DLLs use traditional 'lib' prefix - soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then - # It is most probably a Windows format PATH printed by - # mingw gcc, but we are running on Cygwin. Gcc prints its search - # path with ; separators, and with drive letters. We can handle the - # drive letters (cygwin fileutils understands them), so leave them, - # especially as we might pass files found there to a mingw objdump, - # which wouldn't understand a cygwinified path. Ahh. - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi - ;; - pw32*) - # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - ;; - esac - ;; +cat >>confdefs.h <<_ACEOF +#define HAVE_INT8_T 1 +_ACEOF - *) - library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' - ;; - esac - dynamic_linker='Win32 ld.exe' - # FIXME: first we should search . and the directory the executable is in - shlibpath_var=PATH - ;; -darwin* | rhapsody*) - dynamic_linker="$host_os dyld" - version_type=darwin - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' - soname_spec='${libname}${release}${major}$shared_ext' - shlibpath_overrides_runpath=yes - shlibpath_var=DYLD_LIBRARY_PATH - shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' - # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same. - if test "$GCC" = yes; then - sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"` - else - sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib' - fi - sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' - ;; +fi +ac_fn_c_check_type "$LINENO" "uint8_t" "ac_cv_type_uint8_t" "$ac_includes_default" +if test "x$ac_cv_type_uint8_t" = x""yes; then : -dgux*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; +cat >>confdefs.h <<_ACEOF +#define HAVE_UINT8_T 1 +_ACEOF -freebsd1*) - dynamic_linker=no - ;; -kfreebsd*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='GNU ld.so' - ;; +fi +ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "$ac_includes_default" +if test "x$ac_cv_type_int16_t" = x""yes; then : -freebsd* | dragonfly*) - # DragonFly does not have aout. When/if they implement a new - # versioning mechanism, adjust this. - if test -x /usr/bin/objformat; then - objformat=`/usr/bin/objformat` - else - case $host_os in - freebsd[123]*) objformat=aout ;; - *) objformat=elf ;; - esac - fi - version_type=freebsd-$objformat - case $version_type in - freebsd-elf*) - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - need_version=no - need_lib_prefix=no - ;; - freebsd-*) - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' - need_version=yes - ;; - esac - shlibpath_var=LD_LIBRARY_PATH - case $host_os in - freebsd2*) - shlibpath_overrides_runpath=yes - ;; - freebsd3.[01]* | freebsdelf3.[01]*) - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - *) # from 3.2 on - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - esac - ;; +cat >>confdefs.h <<_ACEOF +#define HAVE_INT16_T 1 +_ACEOF -gnu*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - hardcode_into_libs=yes - ;; -hpux9* | hpux10* | hpux11*) - # Give a soname corresponding to the major version so that dld.sl refuses to - # link against other versions. - version_type=sunos - need_lib_prefix=no - need_version=no - case $host_cpu in - ia64*) - shrext_cmds='.so' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.so" - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - if test "X$HPUX_IA64_MODE" = X32; then - sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" - else - sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" - fi - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - hppa*64*) - shrext_cmds='.sl' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.sl" - shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - *) - shrext_cmds='.sl' - dynamic_linker="$host_os dld.sl" - shlibpath_var=SHLIB_PATH - shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - ;; - esac - # HP-UX runs *really* slowly unless shared libraries are mode 555. - postinstall_cmds='chmod 555 $lib' - ;; +fi +ac_fn_c_check_type "$LINENO" "uint16_t" "ac_cv_type_uint16_t" "$ac_includes_default" +if test "x$ac_cv_type_uint16_t" = x""yes; then : -irix5* | irix6* | nonstopux*) - case $host_os in - nonstopux*) version_type=nonstopux ;; - *) - if test "$lt_cv_prog_gnu_ld" = yes; then - version_type=linux - else - version_type=irix - fi ;; - esac - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' - case $host_os in - irix5* | nonstopux*) - libsuff= shlibsuff= - ;; - *) - case $LD in # libtool.m4 will add one of these switches to LD - *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") - libsuff= shlibsuff= libmagic=32-bit;; - *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") - libsuff=32 shlibsuff=N32 libmagic=N32;; - *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") - libsuff=64 shlibsuff=64 libmagic=64-bit;; - *) libsuff= shlibsuff= libmagic=never-match;; - esac - ;; - esac - shlibpath_var=LD_LIBRARY${shlibsuff}_PATH - shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" - sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" - hardcode_into_libs=yes - ;; +cat >>confdefs.h <<_ACEOF +#define HAVE_UINT16_T 1 +_ACEOF -# No shared lib support for Linux oldld, aout, or coff. -linux*oldld* | linux*aout* | linux*coff*) - dynamic_linker=no - ;; -# This must be Linux ELF. -linux*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes +fi +ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default" +if test "x$ac_cv_type_int32_t" = x""yes; then : - # Append ld.so.conf contents to the search path - if test -f /etc/ld.so.conf; then - lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` - sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" - fi +cat >>confdefs.h <<_ACEOF +#define HAVE_INT32_T 1 +_ACEOF - # We used to test for /lib/ld.so.1 and disable shared libraries on - # powerpc, because MkLinux only supported shared libraries with the - # GNU dynamic linker. Since this was broken with cross compilers, - # most powerpc-linux boxes support dynamic linking these days and - # people can always --disable-shared, the test was removed, and we - # assume the GNU/Linux dynamic linker is in use. - dynamic_linker='GNU/Linux ld.so' - ;; -knetbsd*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='GNU ld.so' - ;; +fi +ac_fn_c_check_type "$LINENO" "uint32_t" "ac_cv_type_uint32_t" "$ac_includes_default" +if test "x$ac_cv_type_uint32_t" = x""yes; then : -netbsd*) - version_type=sunos - need_lib_prefix=no - need_version=no - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - dynamic_linker='NetBSD (a.out) ld.so' - else - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='NetBSD ld.elf_so' - fi - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; +cat >>confdefs.h <<_ACEOF +#define HAVE_UINT32_T 1 +_ACEOF -newsos6) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; -nto-qnx*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; +fi +ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "$ac_includes_default" +if test "x$ac_cv_type_intptr_t" = x""yes; then : -openbsd*) - version_type=sunos - need_lib_prefix=no - # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. - case $host_os in - openbsd3.3 | openbsd3.3.*) need_version=yes ;; - *) need_version=no ;; - esac - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - case $host_os in - openbsd2.[89] | openbsd2.[89].*) - shlibpath_overrides_runpath=no - ;; - *) - shlibpath_overrides_runpath=yes - ;; - esac - else - shlibpath_overrides_runpath=yes - fi - ;; +cat >>confdefs.h <<_ACEOF +#define HAVE_INTPTR_T 1 +_ACEOF -os2*) - libname_spec='$name' - shrext_cmds=".dll" - need_lib_prefix=no - library_names_spec='$libname${shared_ext} $libname.a' - dynamic_linker='OS/2 ld.exe' - shlibpath_var=LIBPATH - ;; -osf3* | osf4* | osf5*) - version_type=osf - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" - ;; +fi +ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default" +if test "x$ac_cv_type_uintptr_t" = x""yes; then : -sco3.2v5*) - version_type=osf - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - ;; +cat >>confdefs.h <<_ACEOF +#define HAVE_UINTPTR_T 1 +_ACEOF -solaris*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - # ldd complains unless libraries are executable - postinstall_cmds='chmod +x $lib' - ;; -sunos4*) - version_type=sunos - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - if test "$with_gnu_ld" = yes; then - need_lib_prefix=no - fi - need_version=yes - ;; +fi +ac_fn_c_check_type "$LINENO" "uint_t" "ac_cv_type_uint_t" "$ac_includes_default" +if test "x$ac_cv_type_uint_t" = x""yes; then : -sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - case $host_vendor in - sni) - shlibpath_overrides_runpath=no - need_lib_prefix=no - export_dynamic_flag_spec='${wl}-Blargedynsym' - runpath_var=LD_RUN_PATH - ;; - siemens) - need_lib_prefix=no - ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - ;; - esac - ;; +cat >>confdefs.h <<_ACEOF +#define HAVE_UINT_T 1 +_ACEOF -sysv4*MP*) - if test -d /usr/nec ;then - version_type=linux - library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' - soname_spec='$libname${shared_ext}.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; -uts4*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; +fi +ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" +if test "x$ac_cv_type_pid_t" = x""yes; then : -*) - dynamic_linker=no - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 -$as_echo "$dynamic_linker" >&6; } -test "$dynamic_linker" = no && can_build_shared=no +cat >>confdefs.h <<_ACEOF +#define HAVE_PID_T 1 +_ACEOF -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 -$as_echo_n "checking how to hardcode library paths into programs... " >&6; } -hardcode_action= -if test -n "$hardcode_libdir_flag_spec" || \ - test -n "$runpath_var" || \ - test "X$hardcode_automatic" = "Xyes" ; then - # We can hardcode non-existant directories. - if test "$hardcode_direct" != no && - # If the only mechanism to avoid hardcoding is shlibpath_var, we - # have to relink, otherwise we might link with an installed library - # when we should be linking with a yet-to-be-installed one - ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, )" != no && - test "$hardcode_minus_L" != no; then - # Linking always hardcodes the temporary library directory. - hardcode_action=relink - else - # We can link without hardcoding, and we can hardcode nonexisting dirs. - hardcode_action=immediate - fi -else - # We cannot hardcode anything, or else we can only hardcode existing - # directories. - hardcode_action=unsupported fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5 -$as_echo "$hardcode_action" >&6; } +ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" +if test "x$ac_cv_type_size_t" = x""yes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_SIZE_T 1 +_ACEOF + -if test "$hardcode_action" = relink; then - # Fast installation is not supported - enable_fast_install=no -elif test "$shlibpath_overrides_runpath" = yes || - test "$enable_shared" = no; then - # Fast installation is not necessary - enable_fast_install=needless fi -striplib= -old_striplib= -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 -$as_echo_n "checking whether stripping libraries is possible... " >&6; } -if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then - test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" - test -z "$striplib" && striplib="$STRIP --strip-unneeded" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } + + # ===== + # sizes + # ===== + # The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of char*" >&5 +$as_echo_n "checking size of char*... " >&6; } +if test "${ac_cv_sizeof_charp+set}" = set; then : + $as_echo_n "(cached) " >&6 else -# FIXME - insert some real tests, host_os isn't really good enough - case $host_os in - darwin*) - if test -n "$STRIP" ; then - striplib="$STRIP -x" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char*))" "ac_cv_sizeof_charp" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_charp" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +{ as_fn_set_status 77 +as_fn_error "cannot compute sizeof (char*) +See \`config.log' for more details." "$LINENO" 5; }; } + else + ac_cv_sizeof_charp=0 + fi fi - ;; - *) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - ;; - esac + fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_charp" >&5 +$as_echo "$ac_cv_sizeof_charp" >&6; } -if test "x$enable_dlopen" != xyes; then - enable_dlopen=unknown - enable_dlopen_self=unknown - enable_dlopen_self_static=unknown -else - lt_cv_dlopen=no - lt_cv_dlopen_libs= - case $host_os in - beos*) - lt_cv_dlopen="load_add_on" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ;; - mingw* | pw32*) - lt_cv_dlopen="LoadLibrary" - lt_cv_dlopen_libs= - ;; +cat >>confdefs.h <<_ACEOF +#define SIZEOF_CHARP $ac_cv_sizeof_charp +_ACEOF - cygwin*) - lt_cv_dlopen="dlopen" - lt_cv_dlopen_libs= - ;; - darwin*) - # if libdl is installed we need to link against it - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 -$as_echo_n "checking for dlopen in -ldl... " >&6; } -if test "${ac_cv_lib_dl_dlopen+set}" = set; then : + # The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 +$as_echo_n "checking size of int... " >&6; } +if test "${ac_cv_sizeof_int+set}" = set; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then : -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); -int -main () -{ -return dlopen (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dl_dlopen=yes else - ac_cv_lib_dl_dlopen=no + if test "$ac_cv_type_int" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +{ as_fn_set_status 77 +as_fn_error "cannot compute sizeof (int) +See \`config.log' for more details." "$LINENO" 5; }; } + else + ac_cv_sizeof_int=0 + fi fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 -$as_echo "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 +$as_echo "$ac_cv_sizeof_int" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_INT $ac_cv_sizeof_int +_ACEOF + + + # The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 +$as_echo_n "checking size of long... " >&6; } +if test "${ac_cv_sizeof_long+set}" = set; then : + $as_echo_n "(cached) " >&6 else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then : - lt_cv_dlopen="dyld" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes +else + if test "$ac_cv_type_long" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +{ as_fn_set_status 77 +as_fn_error "cannot compute sizeof (long) +See \`config.log' for more details." "$LINENO" 5; }; } + else + ac_cv_sizeof_long=0 + fi +fi fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 +$as_echo "$ac_cv_sizeof_long" >&6; } - ;; - *) - ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" -if test "x$ac_cv_func_shl_load" = x""yes; then : - lt_cv_dlopen="shl_load" + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_LONG $ac_cv_sizeof_long +_ACEOF + + + # The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 +$as_echo_n "checking size of short... " >&6; } +if test "${ac_cv_sizeof_short+set}" = set; then : + $as_echo_n "(cached) " >&6 else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 -$as_echo_n "checking for shl_load in -ldld... " >&6; } -if test "${ac_cv_lib_dld_shl_load+set}" = set; then : + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_short" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +{ as_fn_set_status 77 +as_fn_error "cannot compute sizeof (short) +See \`config.log' for more details." "$LINENO" 5; }; } + else + ac_cv_sizeof_short=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 +$as_echo "$ac_cv_sizeof_short" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_SHORT $ac_cv_sizeof_short +_ACEOF + + + + # ---------------------------------------------------------------------- + # AC_CHECK_LIB for SVR4 libgen, and use it if it defines pathfind. + # ---------------------------------------------------------------------- + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pathfind in -lgen" >&5 +$as_echo_n "checking for pathfind in -lgen... " >&6; } +if test "${ac_cv_lib_gen_pathfind+set}" = set; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" +LIBS="-lgen $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -8179,1033 +7360,1635 @@ #ifdef __cplusplus extern "C" #endif -char shl_load (); +char pathfind (); int main () { -return shl_load (); +return pathfind (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dld_shl_load=yes + ac_cv_lib_gen_pathfind=yes else - ac_cv_lib_dld_shl_load=no + ac_cv_lib_gen_pathfind=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 -$as_echo "$ac_cv_lib_dld_shl_load" >&6; } -if test "x$ac_cv_lib_dld_shl_load" = x""yes; then : - lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld" -else - ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" -if test "x$ac_cv_func_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 -$as_echo_n "checking for dlopen in -ldl... " >&6; } -if test "${ac_cv_lib_dl_dlopen+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gen_pathfind" >&5 +$as_echo "$ac_cv_lib_gen_pathfind" >&6; } +if test "x$ac_cv_lib_gen_pathfind" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_LIBGEN 1 +_ACEOF + + LIBS="-lgen $LIBS" + +fi + + for ac_func in vprintf +do : + ac_fn_c_check_func "$LINENO" "vprintf" "ac_cv_func_vprintf" +if test "x$ac_cv_func_vprintf" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_VPRINTF 1 +_ACEOF + +ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt" +if test "x$ac_cv_func__doprnt" = x""yes; then : + +$as_echo "#define HAVE_DOPRNT 1" >>confdefs.h + +fi + +fi +done + + + for ac_header in vfork.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default" +if test "x$ac_cv_header_vfork_h" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_VFORK_H 1 +_ACEOF + +fi + +done + +for ac_func in fork vfork +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +eval as_val=\$$as_ac_var + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + +fi +done + +if test "x$ac_cv_func_fork" = xyes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5 +$as_echo_n "checking for working fork... " >&6; } +if test "${ac_cv_func_fork_works+set}" = set; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + if test "$cross_compiling" = yes; then : + ac_cv_func_fork_works=cross +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); +$ac_includes_default int main () { -return dlopen (); + + /* By Ruediger Kuhlmann. */ + return fork () < 0; + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dl_dlopen=yes +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_func_fork_works=yes else - ac_cv_lib_dl_dlopen=no + ac_cv_func_fork_works=no fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 -$as_echo "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 -$as_echo_n "checking for dlopen in -lsvld... " >&6; } -if test "${ac_cv_lib_svld_dlopen+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lsvld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); -int -main () -{ -return dlopen (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_svld_dlopen=yes +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5 +$as_echo "$ac_cv_func_fork_works" >&6; } + else - ac_cv_lib_svld_dlopen=no + ac_cv_func_fork_works=$ac_cv_func_fork fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +if test "x$ac_cv_func_fork_works" = xcross; then + case $host in + *-*-amigaos* | *-*-msdosdjgpp*) + # Override, as these systems have only a dummy fork() stub + ac_cv_func_fork_works=no + ;; + *) + ac_cv_func_fork_works=yes + ;; + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5 +$as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;} fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 -$as_echo "$ac_cv_lib_svld_dlopen" >&6; } -if test "x$ac_cv_lib_svld_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 -$as_echo_n "checking for dld_link in -ldld... " >&6; } -if test "${ac_cv_lib_dld_dld_link+set}" = set; then : +ac_cv_func_vfork_works=$ac_cv_func_vfork +if test "x$ac_cv_func_vfork" = xyes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5 +$as_echo_n "checking for working vfork... " >&6; } +if test "${ac_cv_func_vfork_works+set}" = set; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + if test "$cross_compiling" = yes; then : + ac_cv_func_vfork_works=cross +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ +/* Thanks to Paul Eggert for this test. */ +$ac_includes_default +#include +#ifdef HAVE_VFORK_H +# include +#endif +/* On some sparc systems, changes by the child to local and incoming + argument registers are propagated back to the parent. The compiler + is told about this with #include , but some compilers + (e.g. gcc -O) don't grok . Test for this by using a + static variable whose address is put into a register that is + clobbered by the vfork. */ +static void #ifdef __cplusplus -extern "C" +sparc_address_test (int arg) +# else +sparc_address_test (arg) int arg; #endif -char dld_link (); +{ + static pid_t child; + if (!child) { + child = vfork (); + if (child < 0) { + perror ("vfork"); + _exit(2); + } + if (!child) { + arg = getpid(); + write(-1, "", 0); + _exit (arg); + } + } +} + int main () { -return dld_link (); - ; - return 0; + pid_t parent = getpid (); + pid_t child; + + sparc_address_test (0); + + child = vfork (); + + if (child == 0) { + /* Here is another test for sparc vfork register problems. This + test uses lots of local variables, at least as many local + variables as main has allocated so far including compiler + temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris + 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should + reuse the register of parent for one of the local variables, + since it will think that parent can't possibly be used any more + in this routine. Assigning to the local variable will thus + munge parent in the parent process. */ + pid_t + p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(), + p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid(); + /* Convince the compiler that p..p7 are live; otherwise, it might + use the same hardware register for all 8 local variables. */ + if (p != p1 || p != p2 || p != p3 || p != p4 + || p != p5 || p != p6 || p != p7) + _exit(1); + + /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent + from child file descriptors. If the child closes a descriptor + before it execs or exits, this munges the parent's descriptor + as well. Test for this by closing stdout in the child. */ + _exit(close(fileno(stdout)) != 0); + } else { + int status; + struct stat st; + + while (wait(&status) != child) + ; + return ( + /* Was there some problem with vforking? */ + child < 0 + + /* Did the child fail? (This shouldn't happen.) */ + || status + + /* Did the vfork/compiler bug occur? */ + || parent != getpid() + + /* Did the file descriptor bug occur? */ + || fstat(fileno(stdout), &st) != 0 + ); + } } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dld_dld_link=yes +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_func_vfork_works=yes else - ac_cv_lib_dld_dld_link=no + ac_cv_func_vfork_works=no fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 -$as_echo "$ac_cv_lib_dld_dld_link" >&6; } -if test "x$ac_cv_lib_dld_dld_link" = x""yes; then : - lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld" +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5 +$as_echo "$ac_cv_func_vfork_works" >&6; } +fi; +if test "x$ac_cv_func_fork_works" = xcross; then + ac_cv_func_vfork_works=$ac_cv_func_vfork + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5 +$as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;} fi +if test "x$ac_cv_func_vfork_works" = xyes; then -fi +$as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h +else + +$as_echo "#define vfork fork" >>confdefs.h fi +if test "x$ac_cv_func_fork_works" = xyes; then +$as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h fi + for ac_func in mmap canonicalize_file_name snprintf strdup strchr \ + strrchr strsignal +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +eval as_val=\$$as_ac_var + if test "x$as_val" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF fi +done - ;; - esac - - if test "x$lt_cv_dlopen" != xno; then - enable_dlopen=yes - else - enable_dlopen=no + INVOKE_LIBOPTS_MACROS_FIRST_done=yes +fi fi +# end of AC_DEFUN of LIBOPTS_CHECK - case $lt_cv_dlopen in - dlopen) - save_CPPFLAGS="$CPPFLAGS" - test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" - - save_LDFLAGS="$LDFLAGS" - eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" - - save_LIBS="$LIBS" - LIBS="$lt_cv_dlopen_libs $LIBS" - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 -$as_echo_n "checking whether a program can dlopen itself... " >&6; } -if test "${lt_cv_dlopen_self+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - lt_cv_dlopen_self=cross -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext < -#endif - -#include -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif -#ifdef __cplusplus -extern "C" void exit (int); -#endif -void fnord() { int i=42;} -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; +# Check whether --enable-static was given. +if test "${enable_static+set}" = set; then : + enableval=$enable_static; p=${PACKAGE-default} + case $enableval in + yes) enable_static=yes ;; + no) enable_static=no ;; + *) + enable_static=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_static=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac +else + enable_static=yes +fi - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - /* dlclose (self); */ - } - exit (status); -} -EOF - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&5 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; - x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; - x$lt_unknown|x*) lt_cv_dlopen_self=no ;; +# Check whether --enable-fast-install was given. +if test "${enable_fast_install+set}" = set; then : + enableval=$enable_fast_install; p=${PACKAGE-default} + case $enableval in + yes) enable_fast_install=yes ;; + no) enable_fast_install=no ;; + *) + enable_fast_install=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_fast_install=yes + fi + done + IFS="$lt_save_ifs" + ;; esac - else : - # compilation failed - lt_cv_dlopen_self=no - fi +else + enable_fast_install=yes fi -rm -fr conftest* -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 -$as_echo "$lt_cv_dlopen_self" >&6; } - - if test "x$lt_cv_dlopen_self" = xyes; then - LDFLAGS="$LDFLAGS $link_static_flag" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 -$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } -if test "${lt_cv_dlopen_self_static+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 +$as_echo_n "checking for a sed that does not truncate output... " >&6; } +if test "${lt_cv_path_SED+set}" = set; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then : - lt_cv_dlopen_self_static=cross -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext < -#endif - -#include - -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif - -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif - -#ifdef __cplusplus -extern "C" void exit (int); -#endif - -void fnord() { int i=42;} -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; - - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - /* dlclose (self); */ - } - - exit (status); -} -EOF - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&5 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; - x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; - x$lt_unknown|x*) lt_cv_dlopen_self_static=no ;; - esac - else : - # compilation failed - lt_cv_dlopen_self_static=no + # Loop through the user's path and test for sed and gsed. +# Then use that list of sed's as ones to test for truncation. +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for lt_ac_prog in sed gsed; do + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then + lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" + fi + done + done +done +lt_ac_max=0 +lt_ac_count=0 +# Add /usr/xpg4/bin/sed as it is typically found on Solaris +# along with /bin/sed that truncates output. +for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do + test ! -f $lt_ac_sed && continue + cat /dev/null > conftest.in + lt_ac_count=0 + echo $ECHO_N "0123456789$ECHO_C" >conftest.in + # Check for GNU sed and select it if it is found. + if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then + lt_cv_path_SED=$lt_ac_sed + break fi + while true; do + cat conftest.in conftest.in >conftest.tmp + mv conftest.tmp conftest.in + cp conftest.in conftest.nl + echo >>conftest.nl + $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break + cmp -s conftest.out conftest.nl || break + # 10000 chars as input seems more than enough + test $lt_ac_count -gt 10 && break + lt_ac_count=`expr $lt_ac_count + 1` + if test $lt_ac_count -gt $lt_ac_max; then + lt_ac_max=$lt_ac_count + lt_cv_path_SED=$lt_ac_sed + fi + done +done + fi -rm -fr conftest* + +SED=$lt_cv_path_SED +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $SED" >&5 +$as_echo "$SED" >&6; } +# Check whether --with-gnu-ld was given. +if test "${with_gnu_ld+set}" = set; then : + withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes +else + with_gnu_ld=no fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 -$as_echo "$lt_cv_dlopen_self_static" >&6; } - fi - CPPFLAGS="$save_CPPFLAGS" - LDFLAGS="$save_LDFLAGS" - LIBS="$save_LIBS" - ;; +ac_prog=ld +if test "$GCC" = yes; then + # Check if gcc -print-prog-name=ld gives a path. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 +$as_echo_n "checking for ld used by $CC... " >&6; } + case $host in + *-*-mingw*) + # gcc leaves a trailing carriage return which upsets mingw + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; + *) + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; esac - - case $lt_cv_dlopen_self in - yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; - *) enable_dlopen_self=unknown ;; + case $ac_prog in + # Accept absolute paths. + [\\/]* | ?:[\\/]*) + re_direlt='/[^/][^/]*/\.\./' + # Canonicalize the pathname of ld + ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'` + while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do + ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"` + done + test -z "$LD" && LD="$ac_prog" + ;; + "") + # If it fails, then pretend we aren't using GCC. + ac_prog=ld + ;; + *) + # If it is relative, then search for the first ld in PATH. + with_gnu_ld=unknown + ;; esac +elif test "$with_gnu_ld" = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 +$as_echo_n "checking for GNU ld... " >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 +$as_echo_n "checking for non-GNU ld... " >&6; } +fi +if test "${lt_cv_path_LD+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$LD"; then + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then + lt_cv_path_LD="$ac_dir/$ac_prog" + # Check to see if the program is GNU ld. I'd rather use --version, + # but apparently some variants of GNU ld only accept -v. + # Break only if it was the GNU/non-GNU ld that we prefer. + case `"$lt_cv_path_LD" -v 2>&1 &5 +$as_echo "$LD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi +test -z "$LD" && as_fn_error "no acceptable ld found in \$PATH" "$LINENO" 5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 +$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } +if test "${lt_cv_prog_gnu_ld+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + # I'd rather use --version here, but apparently some GNU lds only accept -v. +case `$LD -v 2>&1 &5 +$as_echo "$lt_cv_prog_gnu_ld" >&6; } +with_gnu_ld=$lt_cv_prog_gnu_ld -# Report which librarie types wil actually be built -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5 -$as_echo_n "checking if libtool supports shared libraries... " >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5 -$as_echo "$can_build_shared" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 +$as_echo_n "checking for $LD option to reload object files... " >&6; } +if test "${lt_cv_ld_reload_flag+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ld_reload_flag='-r' +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5 +$as_echo "$lt_cv_ld_reload_flag" >&6; } +reload_flag=$lt_cv_ld_reload_flag +case $reload_flag in +"" | " "*) ;; +*) reload_flag=" $reload_flag" ;; +esac +reload_cmds='$LD$reload_flag -o $output$reload_objs' +case $host_os in + darwin*) + if test "$GCC" = yes; then + reload_cmds='$CC -nostdlib ${wl}-r -o $output$reload_objs' + else + reload_cmds='$LD$reload_flag -o $output$reload_objs' + fi + ;; +esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5 -$as_echo_n "checking whether to build shared libraries... " >&6; } -test "$can_build_shared" = "no" && enable_shared=no +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD-compatible nm" >&5 +$as_echo_n "checking for BSD-compatible nm... " >&6; } +if test "${lt_cv_path_NM+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$NM"; then + # Let the user override the test. + lt_cv_path_NM="$NM" +else + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + tmp_nm="$ac_dir/${ac_tool_prefix}nm" + if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then + # Check to see if the nm accepts a BSD-compat flag. + # Adding the `sed 1q' prevents false positives on HP-UX, which says: + # nm: unknown option "B" ignored + # Tru64's nm complains that /dev/null is an invalid object file + case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in + */dev/null* | *'Invalid file or object type'*) + lt_cv_path_NM="$tmp_nm -B" + break + ;; + *) + case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in + */dev/null*) + lt_cv_path_NM="$tmp_nm -p" + break + ;; + *) + lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but + continue # so that we can try to find one that supports BSD flags + ;; + esac + esac + fi + done + IFS="$lt_save_ifs" + test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5 +$as_echo "$lt_cv_path_NM" >&6; } +NM="$lt_cv_path_NM" + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 +$as_echo_n "checking whether ln -s works... " >&6; } +LN_S=$as_ln_s +if test "$LN_S" = "ln -s"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 +$as_echo "no, using $LN_S" >&6; } +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognise dependent libraries" >&5 +$as_echo_n "checking how to recognise dependent libraries... " >&6; } +if test "${lt_cv_deplibs_check_method+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_file_magic_cmd='$MAGIC_CMD' +lt_cv_file_magic_test_file= +lt_cv_deplibs_check_method='unknown' +# Need to set the preceding variable on all platforms that support +# interlibrary dependencies. +# 'none' -- dependencies not supported. +# `unknown' -- same as none, but documents that we really don't know. +# 'pass_all' -- all dependencies passed with no checks. +# 'test_compile' -- check by making test program. +# 'file_magic [[regex]]' -- check by looking for files in library path +# which responds to the $file_magic_cmd with a given extended regex. +# If you have `file' or equivalent on your system and you're not sure +# whether `pass_all' will *always* work, you probably want this one. -# On AIX, shared libraries and static libraries use the same namespace, and -# are all built from PIC. case $host_os in -aix3*) - test "$enable_shared" = yes && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi +aix4* | aix5*) + lt_cv_deplibs_check_method=pass_all ;; -aix4* | aix5*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no - fi - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 -$as_echo "$enable_shared" >&6; } +beos*) + lt_cv_deplibs_check_method=pass_all + ;; -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5 -$as_echo_n "checking whether to build static libraries... " >&6; } -# Make sure either enable_shared or enable_static is yes. -test "$enable_shared" = yes || enable_static=yes -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5 -$as_echo "$enable_static" >&6; } +bsdi[45]*) + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' + lt_cv_file_magic_cmd='/usr/bin/file -L' + lt_cv_file_magic_test_file=/shlib/libc.so + ;; -# The else clause should only fire when bootstrapping the -# libtool distribution, otherwise you forgot to ship ltmain.sh -# with your package, and you will get complaints that there are -# no rules to generate ltmain.sh. -if test -f "$ltmain"; then - # See if we are running on zsh, and set the options which allow our commands through - # without removal of \ escapes. - if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST - fi - # Now quote all the things that may contain metacharacters while being - # careful not to overquote the AC_SUBSTed values. We take copies of the - # variables and quote the copies for generation of the libtool script. - for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \ - SED SHELL STRIP \ - libname_spec library_names_spec soname_spec extract_expsyms_cmds \ - old_striplib striplib file_magic_cmd finish_cmds finish_eval \ - deplibs_check_method reload_flag reload_cmds need_locks \ - lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ - lt_cv_sys_global_symbol_to_c_name_address \ - sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ - old_postinstall_cmds old_postuninstall_cmds \ - compiler \ - CC \ - LD \ - lt_prog_compiler_wl \ - lt_prog_compiler_pic \ - lt_prog_compiler_static \ - lt_prog_compiler_no_builtin_flag \ - export_dynamic_flag_spec \ - thread_safe_flag_spec \ - whole_archive_flag_spec \ - enable_shared_with_static_runtimes \ - old_archive_cmds \ - old_archive_from_new_cmds \ - predep_objects \ - postdep_objects \ - predeps \ - postdeps \ - compiler_lib_search_path \ - archive_cmds \ - archive_expsym_cmds \ - postinstall_cmds \ - postuninstall_cmds \ - old_archive_from_expsyms_cmds \ - allow_undefined_flag \ - no_undefined_flag \ - export_symbols_cmds \ - hardcode_libdir_flag_spec \ - hardcode_libdir_flag_spec_ld \ - hardcode_libdir_separator \ - hardcode_automatic \ - module_cmds \ - module_expsym_cmds \ - lt_cv_prog_compiler_c_o \ - exclude_expsyms \ - include_expsyms; do +cygwin*) + # func_win32_libid is a shell function defined in ltmain.sh + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + ;; - case $var in - old_archive_cmds | \ - old_archive_from_new_cmds | \ - archive_cmds | \ - archive_expsym_cmds | \ - module_cmds | \ - module_expsym_cmds | \ - old_archive_from_expsyms_cmds | \ - export_symbols_cmds | \ - extract_expsyms_cmds | reload_cmds | finish_cmds | \ - postinstall_cmds | postuninstall_cmds | \ - old_postinstall_cmds | old_postuninstall_cmds | \ - sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) - # Double-quote double-evaled strings. - eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" - ;; - *) - eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" +mingw* | pw32*) + # Base MSYS/MinGW do not provide the 'file' command needed by + # func_win32_libid shell function, so use a weaker test based on 'objdump'. + lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?' + lt_cv_file_magic_cmd='$OBJDUMP -f' + ;; + +darwin* | rhapsody*) + lt_cv_deplibs_check_method=pass_all + ;; + +freebsd* | kfreebsd*-gnu | dragonfly*) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + case $host_cpu in + i*86 ) + # Not sure whether the presence of OpenBSD here was a mistake. + # Let's accept both of them until this is cleared up. + lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` ;; esac - done - - case $lt_echo in - *'\$0 --fallback-echo"') - lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` - ;; - esac + else + lt_cv_deplibs_check_method=pass_all + fi + ;; -cfgfile="${ofile}T" - trap "$rm \"$cfgfile\"; exit 1" 1 2 15 - $rm -f "$cfgfile" - { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ofile" >&5 -$as_echo "$as_me: creating $ofile" >&6;} +gnu*) + lt_cv_deplibs_check_method=pass_all + ;; - cat <<__EOF__ >> "$cfgfile" -#! $SHELL - -# `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services. -# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP) -# NOTE: Changes made to this file will be lost: look at ltmain.sh. -# -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001 -# Free Software Foundation, Inc. -# -# This file is part of GNU Libtool: -# Originally by Gordon Matzigkeit , 1996 -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. -# -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - -# A sed program that does not truncate output. -SED=$lt_SED - -# Sed that helps us avoid accidentally triggering echo(1) options like -n. -Xsed="$SED -e 1s/^X//" - -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - -# The names of the tagged configurations supported by this script. -available_tags= - -# ### BEGIN LIBTOOL CONFIG - -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: - -# Shell to use when invoking shell scripts. -SHELL=$lt_SHELL +hpux10.20* | hpux11*) + lt_cv_file_magic_cmd=/usr/bin/file + case $host_cpu in + ia64*) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' + lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so + ;; + hppa*64*) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]' + lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl + ;; + *) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library' + lt_cv_file_magic_test_file=/usr/lib/libc.sl + ;; + esac + ;; -# Whether or not to build shared libraries. -build_libtool_libs=$enable_shared +irix5* | irix6* | nonstopux*) + case $LD in + *-32|*"-32 ") libmagic=32-bit;; + *-n32|*"-n32 ") libmagic=N32;; + *-64|*"-64 ") libmagic=64-bit;; + *) libmagic=never-match;; + esac + lt_cv_deplibs_check_method=pass_all + ;; -# Whether or not to build static libraries. -build_old_libs=$enable_static +# This must be Linux ELF. +linux*) + lt_cv_deplibs_check_method=pass_all + ;; -# Whether or not to add -lc for building shared libraries. -build_libtool_need_lc=$archive_cmds_need_lc +netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' + fi + ;; -# Whether or not to disallow shared libs when runtime libs are static -allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes +newos6*) + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=/usr/lib/libnls.so + ;; -# Whether or not to optimize for fast installation. -fast_install=$enable_fast_install +nto-qnx*) + lt_cv_deplibs_check_method=unknown + ;; -# The host system. -host_alias=$host_alias -host=$host -host_os=$host_os +openbsd*) + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' + fi + ;; -# The build system. -build_alias=$build_alias -build=$build -build_os=$build_os +osf3* | osf4* | osf5*) + lt_cv_deplibs_check_method=pass_all + ;; -# An echo program that does not interpret backslashes. -echo=$lt_echo +sco3.2v5*) + lt_cv_deplibs_check_method=pass_all + ;; -# The archiver. -AR=$lt_AR -AR_FLAGS=$lt_AR_FLAGS +solaris*) + lt_cv_deplibs_check_method=pass_all + ;; -# A C compiler. -LTCC=$lt_LTCC +sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) + case $host_vendor in + motorola) + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]' + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` + ;; + ncr) + lt_cv_deplibs_check_method=pass_all + ;; + sequent) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' + ;; + sni) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib" + lt_cv_file_magic_test_file=/lib/libc.so + ;; + siemens) + lt_cv_deplibs_check_method=pass_all + ;; + esac + ;; -# A language-specific compiler. -CC=$lt_compiler +sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7* | sysv4*uw2*) + lt_cv_deplibs_check_method=pass_all + ;; +esac -# Is the compiler the GNU C compiler? -with_gcc=$GCC +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5 +$as_echo "$lt_cv_deplibs_check_method" >&6; } +file_magic_cmd=$lt_cv_file_magic_cmd +deplibs_check_method=$lt_cv_deplibs_check_method +test -z "$deplibs_check_method" && deplibs_check_method=unknown -# An ERE matcher. -EGREP=$lt_EGREP -# The linker used to build libraries. -LD=$lt_LD -# Whether we need hard or soft links. -LN_S=$lt_LN_S -# A BSD-compatible nm program. -NM=$lt_NM +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} -# A symbol stripping program -STRIP=$lt_STRIP +# Allow CC to be a program name with arguments. +compiler=$CC -# Used to examine libraries when file_magic_cmd begins "file" -MAGIC_CMD=$MAGIC_CMD +# Check whether --enable-libtool-lock was given. +if test "${enable_libtool_lock+set}" = set; then : + enableval=$enable_libtool_lock; +fi -# Used on cygwin: DLL creation program. -DLLTOOL="$DLLTOOL" +test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes -# Used on cygwin: object dumper. -OBJDUMP="$OBJDUMP" +# Some flags need to be propagated to the compiler or linker for good +# libtool support. +case $host in +ia64-*-hpux*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + case `/usr/bin/file conftest.$ac_objext` in + *ELF-32*) + HPUX_IA64_MODE="32" + ;; + *ELF-64*) + HPUX_IA64_MODE="64" + ;; + esac + fi + rm -rf conftest* + ;; +*-*-irix6*) + # Find out which ABI we are using. + echo '#line 8158 "configure"' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + if test "$lt_cv_prog_gnu_ld" = yes; then + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -melf32bsmip" + ;; + *N32*) + LD="${LD-ld} -melf32bmipn32" + ;; + *64-bit*) + LD="${LD-ld} -melf64bmip" + ;; + esac + else + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -32" + ;; + *N32*) + LD="${LD-ld} -n32" + ;; + *64-bit*) + LD="${LD-ld} -64" + ;; + esac + fi + fi + rm -rf conftest* + ;; -# Used on cygwin: assembler. -AS="$AS" +x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + case `/usr/bin/file conftest.o` in + *32-bit*) + case $host in + x86_64-*linux*) + LD="${LD-ld} -m elf_i386" + ;; + ppc64-*linux*|powerpc64-*linux*) + LD="${LD-ld} -m elf32ppclinux" + ;; + s390x-*linux*) + LD="${LD-ld} -m elf_s390" + ;; + sparc64-*linux*) + LD="${LD-ld} -m elf32_sparc" + ;; + esac + ;; + *64-bit*) + case $host in + x86_64-*linux*) + LD="${LD-ld} -m elf_x86_64" + ;; + ppc*-*linux*|powerpc*-*linux*) + LD="${LD-ld} -m elf64ppc" + ;; + s390*-*linux*) + LD="${LD-ld} -m elf64_s390" + ;; + sparc*-*linux*) + LD="${LD-ld} -m elf64_sparc" + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; -# The name of the directory that contains temporary libtool files. -objdir=$objdir +*-*-sco3.2v5*) + # On SCO OpenServer 5, we need -belf to get full-featured binaries. + SAVE_CFLAGS="$CFLAGS" + CFLAGS="$CFLAGS -belf" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5 +$as_echo_n "checking whether the C compiler needs -belf... " >&6; } +if test "${lt_cv_cc_needs_belf+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu -# How to create reloadable object files. -reload_flag=$lt_reload_flag -reload_cmds=$lt_reload_cmds + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# How to pass a linker flag through the compiler. -wl=$lt_lt_prog_compiler_wl +int +main () +{ -# Object file suffix (normally "o"). -objext="$ac_objext" + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + lt_cv_cc_needs_belf=yes +else + lt_cv_cc_needs_belf=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu -# Old archive suffix (normally "a"). -libext="$libext" +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5 +$as_echo "$lt_cv_cc_needs_belf" >&6; } + if test x"$lt_cv_cc_needs_belf" != x"yes"; then + # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf + CFLAGS="$SAVE_CFLAGS" + fi + ;; -# Shared library suffix (normally ".so"). -shrext_cmds='$shrext_cmds' +esac -# Executable file suffix (normally ""). -exeext="$exeext" +need_locks="$enable_libtool_lock" -# Additional compiler flags for building library objects. -pic_flag=$lt_lt_prog_compiler_pic -pic_mode=$pic_mode -# What is the maximum length of a command? -max_cmd_len=$lt_cv_sys_max_cmd_len +for ac_header in dlfcn.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default" +if test "x$ac_cv_header_dlfcn_h" = x""yes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_DLFCN_H 1 +_ACEOF -# Does compiler simultaneously support -c and -o options? -compiler_c_o=$lt_lt_cv_prog_compiler_c_o +fi -# Must we lock files when doing compilation? -need_locks=$lt_need_locks +done -# Do we need the lib prefix for modules? -need_lib_prefix=$need_lib_prefix -# Do we need a version for libraries? -need_version=$need_version +# Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers! -# Whether dlopen is supported. -dlopen_support=$enable_dlopen +# find the maximum length of command line arguments +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5 +$as_echo_n "checking the maximum length of command line arguments... " >&6; } +if test "${lt_cv_sys_max_cmd_len+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + i=0 + teststring="ABCD" -# Whether dlopen of programs is supported. -dlopen_self=$enable_dlopen_self + case $build_os in + msdosdjgpp*) + # On DJGPP, this test can blow up pretty badly due to problems in libc + # (any single argument exceeding 2000 bytes causes a buffer overrun + # during glob expansion). Even if it were fixed, the result of this + # check would be larger than it should be. + lt_cv_sys_max_cmd_len=12288; # 12K is about right + ;; -# Whether dlopen of statically linked programs is supported. -dlopen_self_static=$enable_dlopen_self_static + gnu*) + # Under GNU Hurd, this test is not required because there is + # no limit to the length of command line arguments. + # Libtool will interpret -1 as no limit whatsoever + lt_cv_sys_max_cmd_len=-1; + ;; -# Compiler flag to prevent dynamic linking. -link_static_flag=$lt_lt_prog_compiler_static + cygwin* | mingw*) + # On Win9x/ME, this test blows up -- it succeeds, but takes + # about 5 minutes as the teststring grows exponentially. + # Worse, since 9x/ME are not pre-emptively multitasking, + # you end up with a "frozen" computer, even though with patience + # the test eventually succeeds (with a max line length of 256k). + # Instead, let's just punt: use the minimum linelength reported by + # all of the supported platforms: 8192 (on NT/2K/XP). + lt_cv_sys_max_cmd_len=8192; + ;; -# Compiler flag to turn off builtin functions. -no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag + amigaos*) + # On AmigaOS with pdksh, this test takes hours, literally. + # So we just punt and use a minimum line length of 8192. + lt_cv_sys_max_cmd_len=8192; + ;; -# Compiler flag to allow reflexive dlopens. -export_dynamic_flag_spec=$lt_export_dynamic_flag_spec + netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) + # This has been around since 386BSD, at least. Likely further. + if test -x /sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` + elif test -x /usr/sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` + else + lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs + fi + # And add a safety zone + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + ;; + osf*) + # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure + # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not + # nice to cause kernel panics so lets avoid the loop below. + # First set a reasonable default. + lt_cv_sys_max_cmd_len=16384 + # + if test -x /sbin/sysconfig; then + case `/sbin/sysconfig -q proc exec_disable_arg_limit` in + *1*) lt_cv_sys_max_cmd_len=-1 ;; + esac + fi + ;; + *) + # If test is not a shell built-in, we'll probably end up computing a + # maximum length that is only half of the actual maximum length, but + # we can't tell. + SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} + while (test "X"`$SHELL $0 --fallback-echo "X$teststring" 2>/dev/null` \ + = "XX$teststring") >/dev/null 2>&1 && + new_result=`expr "X$teststring" : ".*" 2>&1` && + lt_cv_sys_max_cmd_len=$new_result && + test $i != 17 # 1/2 MB should be enough + do + i=`expr $i + 1` + teststring=$teststring$teststring + done + teststring= + # Add a significant safety factor because C++ compilers can tack on massive + # amounts of additional arguments before passing them to the linker. + # It appears as though 1/2 is a usable value. + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` + ;; + esac -# Compiler flag to generate shared objects directly from archives. -whole_archive_flag_spec=$lt_whole_archive_flag_spec +fi -# Compiler flag to generate thread-safe objects. -thread_safe_flag_spec=$lt_thread_safe_flag_spec +if test -n $lt_cv_sys_max_cmd_len ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5 +$as_echo "$lt_cv_sys_max_cmd_len" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 +$as_echo "none" >&6; } +fi -# Library versioning type. -version_type=$version_type -# Format of library name prefix. -libname_spec=$lt_libname_spec -# List of archive names. First name is the real one, the rest are links. -# The last name is the one that the linker finds with -lNAME. -library_names_spec=$lt_library_names_spec -# The coded name of the library, if different from the real name. -soname_spec=$lt_soname_spec +# Check for command to grab the raw symbol name followed by C symbol from nm. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5 +$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; } +if test "${lt_cv_sys_global_symbol_pipe+set}" = set; then : + $as_echo_n "(cached) " >&6 +else -# Commands used to build and install an old-style archive. -RANLIB=$lt_RANLIB -old_archive_cmds=$lt_old_archive_cmds -old_postinstall_cmds=$lt_old_postinstall_cmds -old_postuninstall_cmds=$lt_old_postuninstall_cmds +# These are sane defaults that work on at least a few old systems. +# [They come from Ultrix. What could be older than Ultrix?!! ;)] -# Create an old-style archive from a shared archive. -old_archive_from_new_cmds=$lt_old_archive_from_new_cmds +# Character class describing NM global symbol codes. +symcode='[BCDEGRST]' -# Create a temporary old-style archive to link instead of a shared archive. -old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds +# Regexp to match symbols that can be accessed directly from C. +sympat='\([_A-Za-z][_A-Za-z0-9]*\)' -# Commands used to build and install a shared archive. -archive_cmds=$lt_archive_cmds -archive_expsym_cmds=$lt_archive_expsym_cmds -postinstall_cmds=$lt_postinstall_cmds -postuninstall_cmds=$lt_postuninstall_cmds +# Transform an extracted symbol line into a proper C declaration +lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'" -# Commands used to build a loadable module (assumed same as above if empty) -module_cmds=$lt_module_cmds -module_expsym_cmds=$lt_module_expsym_cmds +# Transform an extracted symbol line into symbol name and symbol address +lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([^ ]*\) \([^ ]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" -# Commands to strip libraries. -old_striplib=$lt_old_striplib -striplib=$lt_striplib +# Define system-specific variables. +case $host_os in +aix*) + symcode='[BCDT]' + ;; +cygwin* | mingw* | pw32*) + symcode='[ABCDGISTW]' + ;; +hpux*) # Its linker distinguishes data from code symbols + if test "$host_cpu" = ia64; then + symcode='[ABCDEGRST]' + fi + lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" + lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" + ;; +linux*) + if test "$host_cpu" = ia64; then + symcode='[ABCDGIRSTW]' + lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" + lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" + fi + ;; +irix* | nonstopux*) + symcode='[BCDEGRST]' + ;; +osf*) + symcode='[BCDEGQRST]' + ;; +solaris* | sysv5*) + symcode='[BDRT]' + ;; +sysv4) + symcode='[DFNSTU]' + ;; +esac -# Dependencies to place before the objects being linked to create a -# shared library. -predep_objects=$lt_predep_objects +# Handle CRLF in mingw tool chain +opt_cr= +case $build_os in +mingw*) + opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp + ;; +esac -# Dependencies to place after the objects being linked to create a -# shared library. -postdep_objects=$lt_postdep_objects +# If we're using GNU nm, then use its standard symbol codes. +case `$NM -V 2>&1` in +*GNU* | *'with BFD'*) + symcode='[ABCDGIRSTW]' ;; +esac -# Dependencies to place before the objects being linked to create a -# shared library. -predeps=$lt_predeps +# Try without a prefix undercore, then with it. +for ac_symprfx in "" "_"; do -# Dependencies to place after the objects being linked to create a -# shared library. -postdeps=$lt_postdeps + # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. + symxfrm="\\1 $ac_symprfx\\2 \\2" -# The library search path used internally by the compiler when linking -# a shared library. -compiler_lib_search_path=$lt_compiler_lib_search_path + # Write the raw and C identifiers. + lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" -# Method to check whether dependent libraries are shared objects. -deplibs_check_method=$lt_deplibs_check_method + # Check to see that the pipe works correctly. + pipe_works=no -# Command to use when deplibs_check_method == file_magic. -file_magic_cmd=$lt_file_magic_cmd + rm -f conftest* + cat > conftest.$ac_ext <&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + # Now try to grab the symbols. + nlist=conftest.nm + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\""; } >&5 + (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s "$nlist"; then + # Try sorting and uniquifying the output. + if sort "$nlist" | uniq > "$nlist"T; then + mv -f "$nlist"T "$nlist" + else + rm -f "$nlist"T + fi -# Flag that forces no undefined symbols. -no_undefined_flag=$lt_no_undefined_flag + # Make sure that we snagged all the symbols we need. + if grep ' nm_test_var$' "$nlist" >/dev/null; then + if grep ' nm_test_func$' "$nlist" >/dev/null; then + cat < conftest.$ac_ext +#ifdef __cplusplus +extern "C" { +#endif -# Commands used to finish a libtool library installation in a directory. -finish_cmds=$lt_finish_cmds +EOF + # Now generate the symbol file. + eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext' -# Same as above, but a single script fragment to be evaled but not shown. -finish_eval=$lt_finish_eval + cat <> conftest.$ac_ext +#if defined (__STDC__) && __STDC__ +# define lt_ptr_t void * +#else +# define lt_ptr_t char * +# define const +#endif -# Take the output of nm and produce a listing of raw symbols and C names. -global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe +/* The mapping between symbol names and symbols. */ +const struct { + const char *name; + lt_ptr_t address; +} +lt_preloaded_symbols[] = +{ +EOF + $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext + cat <<\EOF >> conftest.$ac_ext + {0, (lt_ptr_t) 0} +}; -# Transform the output of nm in a proper C declaration -global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl +#ifdef __cplusplus +} +#endif +EOF + # Now try linking the two files. + mv conftest.$ac_objext conftstm.$ac_objext + lt_save_LIBS="$LIBS" + lt_save_CFLAGS="$CFLAGS" + LIBS="conftstm.$ac_objext" + CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest${ac_exeext}; then + pipe_works=yes + fi + LIBS="$lt_save_LIBS" + CFLAGS="$lt_save_CFLAGS" + else + echo "cannot find nm_test_func in $nlist" >&5 + fi + else + echo "cannot find nm_test_var in $nlist" >&5 + fi + else + echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 + fi + else + echo "$progname: failed program was:" >&5 + cat conftest.$ac_ext >&5 + fi + rm -f conftest* conftst* -# Transform the output of nm in a C name address pair -global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address + # Do not use the global_symbol_pipe unless it works. + if test "$pipe_works" = yes; then + break + else + lt_cv_sys_global_symbol_pipe= + fi +done -# This is the shared library runtime path variable. -runpath_var=$runpath_var +fi -# This is the shared library path variable. -shlibpath_var=$shlibpath_var +if test -z "$lt_cv_sys_global_symbol_pipe"; then + lt_cv_sys_global_symbol_to_cdecl= +fi +if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5 +$as_echo "failed" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 +$as_echo "ok" >&6; } +fi -# Is shlibpath searched before the hard-coded library search path? -shlibpath_overrides_runpath=$shlibpath_overrides_runpath +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5 +$as_echo_n "checking for objdir... " >&6; } +if test "${lt_cv_objdir+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + rm -f .libs 2>/dev/null +mkdir .libs 2>/dev/null +if test -d .libs; then + lt_cv_objdir=.libs +else + # MS-DOS does not allow filenames that begin with a dot. + lt_cv_objdir=_libs +fi +rmdir .libs 2>/dev/null +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5 +$as_echo "$lt_cv_objdir" >&6; } +objdir=$lt_cv_objdir -# How to hardcode a shared library path into an executable. -hardcode_action=$hardcode_action -# Whether we should hardcode library paths into libraries. -hardcode_into_libs=$hardcode_into_libs -# Flag to hardcode \$libdir into a binary during linking. -# This must work even if \$libdir does not exist. -hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec -# If ld is used when linking, flag to hardcode \$libdir into -# a binary during linking. This must work even if \$libdir does -# not exist. -hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld - -# Whether we need a single -rpath flag with a separated argument. -hardcode_libdir_separator=$lt_hardcode_libdir_separator - -# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the -# resulting binary. -hardcode_direct=$hardcode_direct - -# Set to yes if using the -LDIR flag during linking hardcodes DIR into the -# resulting binary. -hardcode_minus_L=$hardcode_minus_L - -# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into -# the resulting binary. -hardcode_shlibpath_var=$hardcode_shlibpath_var - -# Set to yes if building a shared library automatically hardcodes DIR into the library -# and all subsequent libraries and executables linked against it. -hardcode_automatic=$hardcode_automatic - -# Variables whose values should be saved in libtool wrapper scripts and -# restored at relink time. -variables_saved_for_relink="$variables_saved_for_relink" - -# Whether libtool must link a program against all its dependency libraries. -link_all_deplibs=$link_all_deplibs - -# Compile-time system search path for libraries -sys_lib_search_path_spec=$lt_sys_lib_search_path_spec -# Run-time system search path for libraries -sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec - -# Fix the shell variable \$srcfile for the compiler. -fix_srcfile_path="$fix_srcfile_path" - -# Set to yes if exported symbols are required. -always_export_symbols=$always_export_symbols +case $host_os in +aix3*) + # AIX sometimes has problems with the GCC collect2 program. For some + # reason, if we set the COLLECT_NAMES environment variable, the problems + # vanish in a puff of smoke. + if test "X${COLLECT_NAMES+set}" != Xset; then + COLLECT_NAMES= + export COLLECT_NAMES + fi + ;; +esac -# The commands to list exported symbols. -export_symbols_cmds=$lt_export_symbols_cmds +# Sed substitution that helps us do robust quoting. It backslashifies +# metacharacters that are still active within double-quoted strings. +Xsed='sed -e 1s/^X//' +sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g' -# The commands to extract the exported symbol list from a shared archive. -extract_expsyms_cmds=$lt_extract_expsyms_cmds +# Same as above, but do not quote variable references. +double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g' -# Symbols that should not be listed in the preloaded symbols. -exclude_expsyms=$lt_exclude_expsyms +# Sed substitution to delay expansion of an escaped shell variable in a +# double_quote_subst'ed string. +delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' -# Symbols that must always be exported. -include_expsyms=$lt_include_expsyms +# Sed substitution to avoid accidental globbing in evaled expressions +no_glob_subst='s/\*/\\\*/g' -# ### END LIBTOOL CONFIG +# Constants: +rm="rm -f" -__EOF__ +# Global variables: +default_ofile=libtool +can_build_shared=yes +# All known linkers require a `.a' archive for static linking (except MSVC, +# which needs '.lib'). +libext=a +ltmain="$ac_aux_dir/ltmain.sh" +ofile="$default_ofile" +with_gnu_ld="$lt_cv_prog_gnu_ld" - case $host_os in - aix3*) - cat <<\EOF >> "$cfgfile" +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. +set dummy ${ac_tool_prefix}ar; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if test "${ac_cv_prog_AR+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$AR"; then + ac_cv_prog_AR="$AR" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + ac_cv_prog_AR="${ac_tool_prefix}ar" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS -# AIX sometimes has problems with the GCC collect2 program. For some -# reason, if we set the COLLECT_NAMES environment variable, the problems -# vanish in a puff of smoke. -if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES fi -EOF - ;; - esac - - # We use sed instead of cat because bash on DJGPP gets confused if - # if finds mixed CR/LF and LF-only lines. Since sed operates in - # text mode, it properly converts lines to CR/LF. This bash problem - # is reportedly fixed, but why not run on old versions too? - sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1) - - mv -f "$cfgfile" "$ofile" || \ - (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") - chmod +x "$ofile" - +fi +AR=$ac_cv_prog_AR +if test -n "$AR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 +$as_echo "$AR" >&6; } else - # If there is no Makefile yet, we rely on a make rule to execute - # `config.status --recheck' to rerun these tests and create the - # libtool script then. - ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` - if test -f "$ltmain_in"; then - test -f Makefile && make "$ltmain" - fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -CC="$lt_save_CC" - - -# Check whether --with-tags was given. -if test "${with_tags+set}" = set; then : - withval=$with_tags; tagnames="$withval" fi +if test -z "$ac_cv_prog_AR"; then + ac_ct_AR=$AR + # Extract the first word of "ar", so it can be a program name with args. +set dummy ar; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if test "${ac_cv_prog_ac_ct_AR+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_AR"; then + ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + ac_cv_prog_ac_ct_AR="ar" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS +fi +fi +ac_ct_AR=$ac_cv_prog_ac_ct_AR +if test -n "$ac_ct_AR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 +$as_echo "$ac_ct_AR" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi -if test -f "$ltmain" && test -n "$tagnames"; then - if test ! -f "${ofile}"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: output file \`$ofile' does not exist" >&5 -$as_echo "$as_me: WARNING: output file \`$ofile' does not exist" >&2;} + if test "x$ac_ct_AR" = x; then + AR="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + AR=$ac_ct_AR fi +else + AR="$ac_cv_prog_AR" +fi - if test -z "$LTCC"; then - eval "`$SHELL ${ofile} --config | grep '^LTCC='`" - if test -z "$LTCC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: output file \`$ofile' does not look like a libtool script" >&5 -$as_echo "$as_me: WARNING: output file \`$ofile' does not look like a libtool script" >&2;} - else - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&5 -$as_echo "$as_me: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&2;} - fi +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. +set dummy ${ac_tool_prefix}ranlib; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if test "${ac_cv_prog_RANLIB+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$RANLIB"; then + ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 fi +done + done +IFS=$as_save_IFS - # Extract list of available tagged configurations in $ofile. - # Note that this assumes the entire list is on one line. - available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'` +fi +fi +RANLIB=$ac_cv_prog_RANLIB +if test -n "$RANLIB"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 +$as_echo "$RANLIB" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for tagname in $tagnames; do - IFS="$lt_save_ifs" - # Check whether tagname contains only valid characters - case `$echo "X$tagname" | $Xsed -e 's:[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]::g'` in - "") ;; - *) as_fn_error "invalid tag name: $tagname" "$LINENO" 5 - ;; - esac - - if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null - then - as_fn_error "tag name \"$tagname\" already exists" "$LINENO" 5 - fi - - # Update the list of available tags. - if test -n "$tagname"; then - echo appending configuration tag \"$tagname\" to $ofile - - case $tagname in - CXX) - if test -n "$CXX" && ( test "X$CXX" != "Xno" && - ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || - (test "X$CXX" != "Xg++"))) ; then - : - else - tagname="" - fi - ;; - F77) - if test -n "$F77" && test "X$F77" != "Xno"; then - : - else - tagname="" - fi - ;; +fi +if test -z "$ac_cv_prog_RANLIB"; then + ac_ct_RANLIB=$RANLIB + # Extract the first word of "ranlib", so it can be a program name with args. +set dummy ranlib; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_RANLIB"; then + ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + ac_cv_prog_ac_ct_RANLIB="ranlib" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS - GCJ) - if test -n "$GCJ" && test "X$GCJ" != "Xno"; then +fi +fi +ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB +if test -n "$ac_ct_RANLIB"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 +$as_echo "$ac_ct_RANLIB" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + if test "x$ac_ct_RANLIB" = x; then + RANLIB=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + RANLIB=$ac_ct_RANLIB + fi +else + RANLIB="$ac_cv_prog_RANLIB" +fi -# Source file extension for Java test sources. -ac_ext=java +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. +set dummy ${ac_tool_prefix}strip; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if test "${ac_cv_prog_STRIP+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$STRIP"; then + ac_cv_prog_STRIP="$STRIP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + ac_cv_prog_STRIP="${ac_tool_prefix}strip" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS -# Object file extension for compiled Java test sources. -objext=o -objext_GCJ=$objext +fi +fi +STRIP=$ac_cv_prog_STRIP +if test -n "$STRIP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 +$as_echo "$STRIP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi -# Code to be used in simple compile tests -lt_simple_compile_test_code="class foo {}\n" -# Code to be used in simple link tests -lt_simple_link_test_code='public class conftest { public static void main(String[] argv) {}; }\n' +fi +if test -z "$ac_cv_prog_STRIP"; then + ac_ct_STRIP=$STRIP + # Extract the first word of "strip", so it can be a program name with args. +set dummy strip; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_STRIP"; then + ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + ac_cv_prog_ac_ct_STRIP="strip" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS -# ltmain only uses $CC for tagged configurations so make sure $CC is set. +fi +fi +ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP +if test -n "$ac_ct_STRIP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 +$as_echo "$ac_ct_STRIP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} + if test "x$ac_ct_STRIP" = x; then + STRIP=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + STRIP=$ac_ct_STRIP + fi +else + STRIP="$ac_cv_prog_STRIP" +fi -# Allow CC to be a program name with arguments. -compiler=$CC +old_CC="$CC" +old_CFLAGS="$CFLAGS" -# save warnings/boilerplate of simple test code -ac_outfile=conftest.$ac_objext -printf "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$rm conftest* +# Set sane defaults for various variables +test -z "$AR" && AR=ar +test -z "$AR_FLAGS" && AR_FLAGS=cru +test -z "$AS" && AS=as +test -z "$CC" && CC=cc +test -z "$LTCC" && LTCC=$CC +test -z "$DLLTOOL" && DLLTOOL=dlltool +test -z "$LD" && LD=ld +test -z "$LN_S" && LN_S="ln -s" +test -z "$MAGIC_CMD" && MAGIC_CMD=file +test -z "$NM" && NM=nm +test -z "$SED" && SED=sed +test -z "$OBJDUMP" && OBJDUMP=objdump +test -z "$RANLIB" && RANLIB=: +test -z "$STRIP" && STRIP=: +test -z "$ac_objext" && ac_objext=o -ac_outfile=conftest.$ac_objext -printf "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$rm conftest* +# Determine commands to create old-style static archives. +old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs' +old_postinstall_cmds='chmod 644 $oldlib' +old_postuninstall_cmds= +if test -n "$RANLIB"; then + case $host_os in + openbsd*) + old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds" + ;; + *) + old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds" + ;; + esac + old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" +fi -# Allow CC to be a program name with arguments. -lt_save_CC="$CC" -CC=${GCJ-"gcj"} -compiler=$CC -compiler_GCJ=$CC for cc_temp in $compiler""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; @@ -9217,289 +9000,287 @@ cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` -# GCJ did not exist at the time GCC didn't implicitly link libc in. -archive_cmds_need_lc_GCJ=no - -old_archive_cmds_GCJ=$old_archive_cmds - - -lt_prog_compiler_no_builtin_flag_GCJ= - -if test "$GCC" = yes; then - lt_prog_compiler_no_builtin_flag_GCJ=' -fno-builtin' - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 -$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } -if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_rtti_exceptions=no - ac_outfile=conftest.$ac_objext - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="-fno-rtti -fno-exceptions" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:9250: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:9254: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp - $SED '/^$/d' conftest.err >conftest.er2 - if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_rtti_exceptions=yes - fi - fi - $rm conftest* +# Only perform the check for file, if the check method requires it +case $deplibs_check_method in +file_magic*) + if test "$file_magic_cmd" = '$MAGIC_CMD'; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5 +$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; } +if test "${lt_cv_path_MAGIC_CMD+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + case $MAGIC_CMD in +[\\/*] | ?:[\\/]*) + lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. + ;; +*) + lt_save_MAGIC_CMD="$MAGIC_CMD" + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" + for ac_dir in $ac_dummy; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/${ac_tool_prefix}file; then + lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file" + if test -n "$file_magic_test_file"; then + case $deplibs_check_method in + "file_magic "*) + file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` + MAGIC_CMD="$lt_cv_path_MAGIC_CMD" + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | + $EGREP "$file_magic_regex" > /dev/null; then + : + else + cat <&2 + +*** Warning: the command libtool uses to detect shared libraries, +*** $file_magic_cmd, produces output that libtool cannot recognize. +*** The result is that libtool may fail to recognize shared libraries +*** as such. This will affect the creation of libtool libraries that +*** depend on shared libraries, but programs linked with such libtool +*** libraries will work regardless of this problem. Nevertheless, you +*** may want to report the problem to your system manager and/or to +*** bug-libtool@gnu.org +EOF + fi ;; + esac + fi + break + fi + done + IFS="$lt_save_ifs" + MAGIC_CMD="$lt_save_MAGIC_CMD" + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 -$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } -if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then - lt_prog_compiler_no_builtin_flag_GCJ="$lt_prog_compiler_no_builtin_flag_GCJ -fno-rtti -fno-exceptions" +MAGIC_CMD="$lt_cv_path_MAGIC_CMD" +if test -n "$MAGIC_CMD"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 +$as_echo "$MAGIC_CMD" >&6; } else - : + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi +if test -z "$lt_cv_path_MAGIC_CMD"; then + if test -n "$ac_tool_prefix"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5 +$as_echo_n "checking for file... " >&6; } +if test "${lt_cv_path_MAGIC_CMD+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + case $MAGIC_CMD in +[\\/*] | ?:[\\/]*) + lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. + ;; +*) + lt_save_MAGIC_CMD="$MAGIC_CMD" + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" + for ac_dir in $ac_dummy; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/file; then + lt_cv_path_MAGIC_CMD="$ac_dir/file" + if test -n "$file_magic_test_file"; then + case $deplibs_check_method in + "file_magic "*) + file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` + MAGIC_CMD="$lt_cv_path_MAGIC_CMD" + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | + $EGREP "$file_magic_regex" > /dev/null; then + : + else + cat <&2 + +*** Warning: the command libtool uses to detect shared libraries, +*** $file_magic_cmd, produces output that libtool cannot recognize. +*** The result is that libtool may fail to recognize shared libraries +*** as such. This will affect the creation of libtool libraries that +*** depend on shared libraries, but programs linked with such libtool +*** libraries will work regardless of this problem. Nevertheless, you +*** may want to report the problem to your system manager and/or to +*** bug-libtool@gnu.org + +EOF + fi ;; + esac + fi + break + fi + done + IFS="$lt_save_ifs" + MAGIC_CMD="$lt_save_MAGIC_CMD" + ;; +esac fi -lt_prog_compiler_wl_GCJ= -lt_prog_compiler_pic_GCJ= -lt_prog_compiler_static_GCJ= +MAGIC_CMD="$lt_cv_path_MAGIC_CMD" +if test -n "$MAGIC_CMD"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 +$as_echo "$MAGIC_CMD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 -$as_echo_n "checking for $compiler option to produce PIC... " >&6; } + else + MAGIC_CMD=: + fi +fi - if test "$GCC" = yes; then - lt_prog_compiler_wl_GCJ='-Wl,' - lt_prog_compiler_static_GCJ='-static' + fi + ;; +esac - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static_GCJ='-Bstatic' - fi - ;; +enable_dlopen=no +enable_win32_dll=no - amigaos*) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - lt_prog_compiler_pic_GCJ='-m68020 -resident32 -malways-restore-a4' - ;; +# Check whether --enable-libtool-lock was given. +if test "${enable_libtool_lock+set}" = set; then : + enableval=$enable_libtool_lock; +fi - beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; +test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes - mingw* | pw32* | os2*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - lt_prog_compiler_pic_GCJ='-DDLL_EXPORT' - ;; - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - lt_prog_compiler_pic_GCJ='-fno-common' - ;; +# Check whether --with-pic was given. +if test "${with_pic+set}" = set; then : + withval=$with_pic; pic_mode="$withval" +else + pic_mode=default +fi - msdosdjgpp*) - # Just because we use GCC doesn't mean we suddenly get shared libraries - # on systems that don't support them. - lt_prog_compiler_can_build_shared_GCJ=no - enable_shared=no - ;; +test -z "$pic_mode" && pic_mode=default - sysv4*MP*) - if test -d /usr/nec; then - lt_prog_compiler_pic_GCJ=-Kconform_pic - fi - ;; +# Use C for the default configuration in the libtool script +tagname= +lt_save_CC="$CC" +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu - hpux*) - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic_GCJ='-fPIC' - ;; - esac - ;; - *) - lt_prog_compiler_pic_GCJ='-fPIC' - ;; - esac - else - # PORTME Check for flag to pass linker flags through the system compiler. - case $host_os in - aix*) - lt_prog_compiler_wl_GCJ='-Wl,' - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static_GCJ='-Bstatic' - else - lt_prog_compiler_static_GCJ='-bnso -bI:/lib/syscalls.exp' - fi - ;; - darwin*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - case $cc_basename in - xlc*) - lt_prog_compiler_pic_GCJ='-qnocommon' - lt_prog_compiler_wl_GCJ='-Wl,' - ;; - esac - ;; - - mingw* | pw32* | os2*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - lt_prog_compiler_pic_GCJ='-DDLL_EXPORT' - ;; - - hpux9* | hpux10* | hpux11*) - lt_prog_compiler_wl_GCJ='-Wl,' - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic_GCJ='+Z' - ;; - esac - # Is there a better lt_prog_compiler_static that works with the bundled CC? - lt_prog_compiler_static_GCJ='${wl}-a ${wl}archive' - ;; - - irix5* | irix6* | nonstopux*) - lt_prog_compiler_wl_GCJ='-Wl,' - # PIC (with -KPIC) is the default. - lt_prog_compiler_static_GCJ='-non_shared' - ;; +# Source file extension for C test sources. +ac_ext=c - newsos6) - lt_prog_compiler_pic_GCJ='-KPIC' - lt_prog_compiler_static_GCJ='-Bstatic' - ;; +# Object file extension for compiled C test sources. +objext=o +objext=$objext - linux*) - case $cc_basename in - icc* | ecc*) - lt_prog_compiler_wl_GCJ='-Wl,' - lt_prog_compiler_pic_GCJ='-KPIC' - lt_prog_compiler_static_GCJ='-static' - ;; - pgcc* | pgf77* | pgf90* | pgf95*) - # Portland Group compilers (*not* the Pentium gcc compiler, - # which looks to be a dead project) - lt_prog_compiler_wl_GCJ='-Wl,' - lt_prog_compiler_pic_GCJ='-fpic' - lt_prog_compiler_static_GCJ='-Bstatic' - ;; - ccc*) - lt_prog_compiler_wl_GCJ='-Wl,' - # All Alpha code is PIC. - lt_prog_compiler_static_GCJ='-non_shared' - ;; - esac - ;; +# Code to be used in simple compile tests +lt_simple_compile_test_code="int some_variable = 0;\n" - osf3* | osf4* | osf5*) - lt_prog_compiler_wl_GCJ='-Wl,' - # All OSF/1 code is PIC. - lt_prog_compiler_static_GCJ='-non_shared' - ;; +# Code to be used in simple link tests +lt_simple_link_test_code='int main(){return(0);}\n' - sco3.2v5*) - lt_prog_compiler_pic_GCJ='-Kpic' - lt_prog_compiler_static_GCJ='-dn' - ;; - solaris*) - lt_prog_compiler_pic_GCJ='-KPIC' - lt_prog_compiler_static_GCJ='-Bstatic' - case $cc_basename in - f77* | f90* | f95*) - lt_prog_compiler_wl_GCJ='-Qoption ld ';; - *) - lt_prog_compiler_wl_GCJ='-Wl,';; - esac - ;; +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} - sunos4*) - lt_prog_compiler_wl_GCJ='-Qoption ld ' - lt_prog_compiler_pic_GCJ='-PIC' - lt_prog_compiler_static_GCJ='-Bstatic' - ;; +# Allow CC to be a program name with arguments. +compiler=$CC - sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - lt_prog_compiler_wl_GCJ='-Wl,' - lt_prog_compiler_pic_GCJ='-KPIC' - lt_prog_compiler_static_GCJ='-Bstatic' - ;; - sysv4*MP*) - if test -d /usr/nec ;then - lt_prog_compiler_pic_GCJ='-Kconform_pic' - lt_prog_compiler_static_GCJ='-Bstatic' - fi - ;; +# save warnings/boilerplate of simple test code +ac_outfile=conftest.$ac_objext +printf "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$rm conftest* - unicos*) - lt_prog_compiler_wl_GCJ='-Wl,' - lt_prog_compiler_can_build_shared_GCJ=no - ;; +ac_outfile=conftest.$ac_objext +printf "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$rm conftest* - uts4*) - lt_prog_compiler_pic_GCJ='-pic' - lt_prog_compiler_static_GCJ='-Bstatic' - ;; - *) - lt_prog_compiler_can_build_shared_GCJ=no - ;; - esac +# +# Check for any special shared library compilation flags. +# +lt_prog_cc_shlib= +if test "$GCC" = no; then + case $host_os in + sco3.2v5*) + lt_prog_cc_shlib='-belf' + ;; + esac +fi +if test -n "$lt_prog_cc_shlib"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' requires \`$lt_prog_cc_shlib' to build shared libraries" >&5 +$as_echo "$as_me: WARNING: \`$CC' requires \`$lt_prog_cc_shlib' to build shared libraries" >&2;} + if echo "$old_CC $old_CFLAGS " | grep "[ ]$lt_prog_cc_shlib[ ]" >/dev/null; then : + else + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: add \`$lt_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&5 +$as_echo "$as_me: WARNING: add \`$lt_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&2;} + lt_cv_prog_cc_can_build_shared=no fi +fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic_GCJ" >&5 -$as_echo "$lt_prog_compiler_pic_GCJ" >&6; } # -# Check to make sure the PIC flag actually works. +# Check to make sure the static flag actually works. # -if test -n "$lt_prog_compiler_pic_GCJ"; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_prog_compiler_static works" >&5 +$as_echo_n "checking if $compiler static flag $lt_prog_compiler_static works... " >&6; } +if test "${lt_prog_compiler_static_works+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + lt_prog_compiler_static_works=no + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS $lt_prog_compiler_static" + printf "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $echo "X$_lt_linker_boilerplate" | $Xsed > conftest.exp + $SED '/^$/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_prog_compiler_static_works=yes + fi + else + lt_prog_compiler_static_works=yes + fi + fi + $rm conftest* + LDFLAGS="$save_LDFLAGS" -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic_GCJ works" >&5 -$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_GCJ works... " >&6; } -if test "${lt_prog_compiler_pic_works_GCJ+set}" = set; then : +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_static_works" >&5 +$as_echo "$lt_prog_compiler_static_works" >&6; } + +if test x"$lt_prog_compiler_static_works" = xyes; then + : +else + lt_prog_compiler_static= +fi + + + + +lt_prog_compiler_no_builtin_flag= + +if test "$GCC" = yes; then + lt_prog_compiler_no_builtin_flag=' -fno-builtin' + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 +$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } +if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then : $as_echo_n "(cached) " >&6 else - lt_prog_compiler_pic_works_GCJ=no + lt_cv_prog_compiler_rtti_exceptions=no ac_outfile=conftest.$ac_objext printf "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$lt_prog_compiler_pic_GCJ" + lt_compiler_flag="-fno-rtti -fno-exceptions" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins @@ -9509,4559 +9290,6558 @@ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:9512: $lt_compile\"" >&5) + (eval echo "\"\$as_me:9293: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:9516: \$? = $ac_status" >&5 + echo "$as_me:9297: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp $SED '/^$/d' conftest.err >conftest.er2 if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then - lt_prog_compiler_pic_works_GCJ=yes + lt_cv_prog_compiler_rtti_exceptions=yes fi fi $rm conftest* fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic_works_GCJ" >&5 -$as_echo "$lt_prog_compiler_pic_works_GCJ" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 +$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } -if test x"$lt_prog_compiler_pic_works_GCJ" = xyes; then - case $lt_prog_compiler_pic_GCJ in - "" | " "*) ;; - *) lt_prog_compiler_pic_GCJ=" $lt_prog_compiler_pic_GCJ" ;; - esac +if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then + lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" else - lt_prog_compiler_pic_GCJ= - lt_prog_compiler_can_build_shared_GCJ=no + : fi fi -case $host_os in - # For platforms which do not support PIC, -DPIC is meaningless: - *djgpp*) - lt_prog_compiler_pic_GCJ= - ;; - *) - lt_prog_compiler_pic_GCJ="$lt_prog_compiler_pic_GCJ" - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 -$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } -if test "${lt_cv_prog_compiler_c_o_GCJ+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_c_o_GCJ=no - $rm -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - printf "$lt_simple_compile_test_code" > conftest.$ac_ext +lt_prog_compiler_wl= +lt_prog_compiler_pic= +lt_prog_compiler_static= - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:9574: $lt_compile\"" >&5) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&5 - echo "$as_me:9578: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $echo "X$_lt_compiler_boilerplate" | $Xsed > out/conftest.exp - $SED '/^$/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.err || diff out/conftest.exp out/conftest.er2 >/dev/null; then - lt_cv_prog_compiler_c_o_GCJ=yes - fi - fi - chmod u+w . 2>&5 - $rm conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files - $rm out/* && rmdir out - cd .. - rmdir conftest - $rm conftest* - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_GCJ" >&5 -$as_echo "$lt_cv_prog_compiler_c_o_GCJ" >&6; } - - -hard_links="nottested" -if test "$lt_cv_prog_compiler_c_o_GCJ" = no && test "$need_locks" != no; then - # do not overwrite the value of need_locks provided by the user - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 -$as_echo_n "checking if we can lock with hard links... " >&6; } - hard_links=yes - $rm conftest* - ln conftest.a conftest.b 2>/dev/null && hard_links=no - touch conftest.a - ln conftest.a conftest.b 2>&5 || hard_links=no - ln conftest.a conftest.b 2>/dev/null && hard_links=no - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 -$as_echo "$hard_links" >&6; } - if test "$hard_links" = no; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 -$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} - need_locks=warn - fi -else - need_locks=no -fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 -$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } - - runpath_var= - allow_undefined_flag_GCJ= - enable_shared_with_static_runtimes_GCJ=no - archive_cmds_GCJ= - archive_expsym_cmds_GCJ= - old_archive_From_new_cmds_GCJ= - old_archive_from_expsyms_cmds_GCJ= - export_dynamic_flag_spec_GCJ= - whole_archive_flag_spec_GCJ= - thread_safe_flag_spec_GCJ= - hardcode_libdir_flag_spec_GCJ= - hardcode_libdir_flag_spec_ld_GCJ= - hardcode_libdir_separator_GCJ= - hardcode_direct_GCJ=no - hardcode_minus_L_GCJ=no - hardcode_shlibpath_var_GCJ=unsupported - link_all_deplibs_GCJ=unknown - hardcode_automatic_GCJ=no - module_cmds_GCJ= - module_expsym_cmds_GCJ= - always_export_symbols_GCJ=no - export_symbols_cmds_GCJ='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - # include_expsyms should be a list of space-separated symbols to be *always* - # included in the symbol list - include_expsyms_GCJ= - # exclude_expsyms can be an extended regexp of symbols to exclude - # it will be wrapped by ` (' and `)$', so one must not match beginning or - # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', - # as well as any symbol that contains `d'. - exclude_expsyms_GCJ="_GLOBAL_OFFSET_TABLE_" - # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out - # platforms (ab)use it in PIC code, but their linkers get confused if - # the symbol is explicitly referenced. Since portable code cannot - # rely on this symbol name, it's probably fine to never include it in - # preloaded symbol tables. - extract_expsyms_cmds= - # Just being paranoid about ensuring that cc_basename is set. - for cc_temp in $compiler""; do - case $cc_temp in - compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; - distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` - - case $host_os in - cygwin* | mingw* | pw32*) - # FIXME: the MSVC++ port hasn't been tested in a loooong time - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - if test "$GCC" != yes; then - with_gnu_ld=no - fi - ;; - openbsd*) - with_gnu_ld=no - ;; - esac - - ld_shlibs_GCJ=yes - if test "$with_gnu_ld" = yes; then - # If archive_cmds runs LD, not CC, wlarc should be empty - wlarc='${wl}' +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; } - # Set some defaults for GNU ld with shared library support. These - # are reset later if shared libraries are not supported. Putting them - # here allows them to be overridden if necessary. - runpath_var=LD_RUN_PATH - hardcode_libdir_flag_spec_GCJ='${wl}--rpath ${wl}$libdir' - export_dynamic_flag_spec_GCJ='${wl}--export-dynamic' - # ancient GNU ld didn't support --whole-archive et. al. - if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then - whole_archive_flag_spec_GCJ="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - else - whole_archive_flag_spec_GCJ= - fi - supports_anon_versioning=no - case `$LD -v 2>/dev/null` in - *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 - *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... - *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... - *\ 2.11.*) ;; # other 2.11 versions - *) supports_anon_versioning=yes ;; - esac + if test "$GCC" = yes; then + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_static='-static' - # See if GNU ld supports shared libraries. case $host_os in - aix3* | aix4* | aix5*) - # On AIX/PPC, the GNU linker is very broken - if test "$host_cpu" != ia64; then - ld_shlibs_GCJ=no - cat <&2 - -*** Warning: the GNU linker, at least up to release 2.9.1, is reported -*** to be unable to reliably create shared libraries on AIX. -*** Therefore, libtool is disabling shared libraries support. If you -*** really care for shared libraries, you may want to modify your PATH -*** so that a non-GNU linker is found, and then restart. - -EOF + aix*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static='-Bstatic' fi ;; amigaos*) - archive_cmds_GCJ='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_minus_L_GCJ=yes - - # Samuel A. Falvo II reports - # that the semantics of dynamic libraries on AmigaOS, at least up - # to version 4, is to share data among multiple programs linked - # with the same dynamic library. Since this doesn't match the - # behavior of shared libraries on other platforms, we can't use - # them. - ld_shlibs_GCJ=no + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the `-m68020' flag to GCC prevents building anything better, + # like `-m68040'. + lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' ;; - beos*) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - allow_undefined_flag_GCJ=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - archive_cmds_GCJ='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - else - ld_shlibs_GCJ=no - fi + beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. ;; - cygwin* | mingw* | pw32*) - # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, GCJ) is actually meaningless, - # as there is no search path for DLLs. - hardcode_libdir_flag_spec_GCJ='-L$libdir' - allow_undefined_flag_GCJ=unsupported - always_export_symbols_GCJ=no - enable_shared_with_static_runtimes_GCJ=yes - export_symbols_cmds_GCJ='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS] /s/.* \([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW] /s/.* //'\'' | sort | uniq > $export_symbols' + mingw* | pw32* | os2*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + lt_prog_compiler_pic='-DDLL_EXPORT' + ;; - if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then - archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - archive_expsym_cmds_GCJ='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - else - ld_shlibs_GCJ=no - fi + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + lt_prog_compiler_pic='-fno-common' ;; - linux*) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - tmp_addflag= - case $cc_basename,$host_cpu in - pgcc*) # Portland Group C compiler - whole_archive_flag_spec_GCJ='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag' - ;; - pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers - whole_archive_flag_spec_GCJ='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag -Mnomain' ;; - ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 - tmp_addflag=' -i_dynamic' ;; - efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 - tmp_addflag=' -i_dynamic -nofor_main' ;; - ifc* | ifort*) # Intel Fortran compiler - tmp_addflag=' -nofor_main' ;; - esac - archive_cmds_GCJ='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + msdosdjgpp*) + # Just because we use GCC doesn't mean we suddenly get shared libraries + # on systems that don't support them. + lt_prog_compiler_can_build_shared=no + enable_shared=no + ;; - if test $supports_anon_versioning = yes; then - archive_expsym_cmds_GCJ='$echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - $echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' - fi - else - ld_shlibs_GCJ=no + sysv4*MP*) + if test -d /usr/nec; then + lt_prog_compiler_pic=-Kconform_pic fi ;; - netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - archive_cmds_GCJ='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' - wlarc= + hpux*) + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic='-fPIC' + ;; + esac + ;; + + *) + lt_prog_compiler_pic='-fPIC' + ;; + esac + else + # PORTME Check for flag to pass linker flags through the system compiler. + case $host_os in + aix*) + lt_prog_compiler_wl='-Wl,' + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static='-Bstatic' else - archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' fi ;; + darwin*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + case $cc_basename in + xlc*) + lt_prog_compiler_pic='-qnocommon' + lt_prog_compiler_wl='-Wl,' + ;; + esac + ;; - solaris* | sysv5*) - if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then - ld_shlibs_GCJ=no - cat <&2 + mingw* | pw32* | os2*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + lt_prog_compiler_pic='-DDLL_EXPORT' + ;; -*** Warning: The releases 2.8.* of the GNU linker cannot reliably -*** create shared libraries on Solaris systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.9.1 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. + hpux9* | hpux10* | hpux11*) + lt_prog_compiler_wl='-Wl,' + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic='+Z' + ;; + esac + # Is there a better lt_prog_compiler_static that works with the bundled CC? + lt_prog_compiler_static='${wl}-a ${wl}archive' + ;; -EOF - elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs_GCJ=no - fi + irix5* | irix6* | nonstopux*) + lt_prog_compiler_wl='-Wl,' + # PIC (with -KPIC) is the default. + lt_prog_compiler_static='-non_shared' + ;; + + newsos6) + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + + linux*) + case $cc_basename in + icc* | ecc*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-static' + ;; + pgcc* | pgf77* | pgf90* | pgf95*) + # Portland Group compilers (*not* the Pentium gcc compiler, + # which looks to be a dead project) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fpic' + lt_prog_compiler_static='-Bstatic' + ;; + ccc*) + lt_prog_compiler_wl='-Wl,' + # All Alpha code is PIC. + lt_prog_compiler_static='-non_shared' + ;; + esac + ;; + + osf3* | osf4* | osf5*) + lt_prog_compiler_wl='-Wl,' + # All OSF/1 code is PIC. + lt_prog_compiler_static='-non_shared' + ;; + + sco3.2v5*) + lt_prog_compiler_pic='-Kpic' + lt_prog_compiler_static='-dn' + ;; + + solaris*) + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + case $cc_basename in + f77* | f90* | f95*) + lt_prog_compiler_wl='-Qoption ld ';; + *) + lt_prog_compiler_wl='-Wl,';; + esac ;; sunos4*) - archive_cmds_GCJ='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' - wlarc= - hardcode_direct_GCJ=yes - hardcode_shlibpath_var_GCJ=no + lt_prog_compiler_wl='-Qoption ld ' + lt_prog_compiler_pic='-PIC' + lt_prog_compiler_static='-Bstatic' ;; - *) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs_GCJ=no - fi + sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' ;; - esac - if test "$ld_shlibs_GCJ" = no; then - runpath_var= - hardcode_libdir_flag_spec_GCJ= - export_dynamic_flag_spec_GCJ= - whole_archive_flag_spec_GCJ= - fi - else - # PORTME fill in a description of your system's linker (not GNU ld) - case $host_os in - aix3*) - allow_undefined_flag_GCJ=unsupported - always_export_symbols_GCJ=yes - archive_expsym_cmds_GCJ='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' - # Note: this linker hardcodes the directories in LIBPATH if there - # are no directories specified by -L. - hardcode_minus_L_GCJ=yes - if test "$GCC" = yes && test -z "$link_static_flag"; then - # Neither direct hardcoding nor static linking is supported with a - # broken collect2. - hardcode_direct_GCJ=unsupported + sysv4*MP*) + if test -d /usr/nec ;then + lt_prog_compiler_pic='-Kconform_pic' + lt_prog_compiler_static='-Bstatic' fi ;; - aix4* | aix5*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - if $NM -V 2>&1 | grep 'GNU' > /dev/null; then - export_symbols_cmds_GCJ='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' - else - export_symbols_cmds_GCJ='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' - fi - aix_use_runtimelinking=no + unicos*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_can_build_shared=no + ;; - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[23]|aix4.[23].*|aix5*) - for ld_flag in $LDFLAGS; do - if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then - aix_use_runtimelinking=yes - break - fi - done - esac + uts4*) + lt_prog_compiler_pic='-pic' + lt_prog_compiler_static='-Bstatic' + ;; - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi + *) + lt_prog_compiler_can_build_shared=no + ;; + esac + fi - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic" >&5 +$as_echo "$lt_prog_compiler_pic" >&6; } - archive_cmds_GCJ='' - hardcode_direct_GCJ=yes - hardcode_libdir_separator_GCJ=':' - link_all_deplibs_GCJ=yes +# +# Check to make sure the PIC flag actually works. +# +if test -n "$lt_prog_compiler_pic"; then - if test "$GCC" = yes; then - case $host_os in aix4.[012]|aix4.[012].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && \ - strings "$collect2name" | grep resolve_lib_name >/dev/null - then - # We have reworked collect2 - hardcode_direct_GCJ=yes - else - # We have old collect2 - hardcode_direct_GCJ=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - hardcode_minus_L_GCJ=yes - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_libdir_separator_GCJ= - fi - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi - fi - fi - - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to export. - always_export_symbols_GCJ=yes - if test "$aix_use_runtimelinking" = yes; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - allow_undefined_flag_GCJ='-berok' - # Determine the default libpath from the value encoded in an empty executable. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 +$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } +if test "${lt_prog_compiler_pic_works+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + lt_prog_compiler_pic_works=no + ac_outfile=conftest.$ac_objext + printf "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$lt_prog_compiler_pic -DPIC" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:9555: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:9559: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp + $SED '/^$/d' conftest.err >conftest.er2 + if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then + lt_prog_compiler_pic_works=yes + fi + fi + $rm conftest* - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic_works" >&5 +$as_echo "$lt_prog_compiler_pic_works" >&6; } -aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'` -# Check for a 64-bit object if we didn't find anything. -if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'`; fi +if test x"$lt_prog_compiler_pic_works" = xyes; then + case $lt_prog_compiler_pic in + "" | " "*) ;; + *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; + esac +else + lt_prog_compiler_pic= + lt_prog_compiler_can_build_shared=no fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi - hardcode_libdir_flag_spec_GCJ='${wl}-blibpath:$libdir:'"$aix_libpath" - archive_expsym_cmds_GCJ="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag" - else - if test "$host_cpu" = ia64; then - hardcode_libdir_flag_spec_GCJ='${wl}-R $libdir:/usr/lib:/lib' - allow_undefined_flag_GCJ="-z nodefs" - archive_expsym_cmds_GCJ="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols" - else - # Determine the default libpath from the value encoded in an empty executable. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +fi +case $host_os in + # For platforms which do not support PIC, -DPIC is meaningless: + *djgpp*) + lt_prog_compiler_pic= + ;; + *) + lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" + ;; +esac -int -main () -{ +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if test "${lt_cv_prog_compiler_c_o+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o=no + $rm -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + printf "$lt_simple_compile_test_code" > conftest.$ac_ext - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:9617: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:9621: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $echo "X$_lt_compiler_boilerplate" | $Xsed > out/conftest.exp + $SED '/^$/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.err || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o=yes + fi + fi + chmod u+w . 2>&5 + $rm conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files + $rm out/* && rmdir out + cd .. + rmdir conftest + $rm conftest* -aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'` -# Check for a 64-bit object if we didn't find anything. -if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'`; fi fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi - - hardcode_libdir_flag_spec_GCJ='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - no_undefined_flag_GCJ=' ${wl}-bernotok' - allow_undefined_flag_GCJ=' ${wl}-berok' - # -bexpall does not export symbols beginning with underscore (_) - always_export_symbols_GCJ=yes - # Exported symbols can be pulled into shared objects from archives - whole_archive_flag_spec_GCJ=' ' - archive_cmds_need_lc_GCJ=yes - # This is similar to how AIX traditionally builds its shared libraries. - archive_expsym_cmds_GCJ="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' - fi - fi - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 +$as_echo "$lt_cv_prog_compiler_c_o" >&6; } - amigaos*) - archive_cmds_GCJ='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_minus_L_GCJ=yes - # see comment about different semantics on the GNU ld section - ld_shlibs_GCJ=no - ;; - bsdi[45]*) - export_dynamic_flag_spec_GCJ=-rdynamic - ;; +hard_links="nottested" +if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then + # do not overwrite the value of need_locks provided by the user + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 +$as_echo_n "checking if we can lock with hard links... " >&6; } + hard_links=yes + $rm conftest* + ln conftest.a conftest.b 2>/dev/null && hard_links=no + touch conftest.a + ln conftest.a conftest.b 2>&5 || hard_links=no + ln conftest.a conftest.b 2>/dev/null && hard_links=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 +$as_echo "$hard_links" >&6; } + if test "$hard_links" = no; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 +$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} + need_locks=warn + fi +else + need_locks=no +fi - cygwin* | mingw* | pw32*) - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - hardcode_libdir_flag_spec_GCJ=' ' - allow_undefined_flag_GCJ=unsupported - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" - # FIXME: Setting linknames here is a bad hack. - archive_cmds_GCJ='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' - # The linker will automatically build a .lib file if we build a DLL. - old_archive_From_new_cmds_GCJ='true' - # FIXME: Should let the user specify the lib program. - old_archive_cmds_GCJ='lib /OUT:$oldlib$oldobjs$old_deplibs' - fix_srcfile_path_GCJ='`cygpath -w "$srcfile"`' - enable_shared_with_static_runtimes_GCJ=yes - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } - darwin* | rhapsody*) - case $host_os in - rhapsody* | darwin1.[012]) - allow_undefined_flag_GCJ='${wl}-undefined ${wl}suppress' - ;; - *) # Darwin 1.3 on - if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then - allow_undefined_flag_GCJ='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - else - case ${MACOSX_DEPLOYMENT_TARGET} in - 10.[012]) - allow_undefined_flag_GCJ='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - ;; - 10.*) - allow_undefined_flag_GCJ='${wl}-undefined ${wl}dynamic_lookup' - ;; - esac - fi - ;; - esac - archive_cmds_need_lc_GCJ=no - hardcode_direct_GCJ=no - hardcode_automatic_GCJ=yes - hardcode_shlibpath_var_GCJ=unsupported - whole_archive_flag_spec_GCJ='' - link_all_deplibs_GCJ=yes - if test "$GCC" = yes ; then - output_verbose_link_cmd='echo' - archive_cmds_GCJ='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' - module_cmds_GCJ='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds - archive_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - module_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - else - case $cc_basename in - xlc*) - output_verbose_link_cmd='echo' - archive_cmds_GCJ='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring' - module_cmds_GCJ='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds - archive_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - module_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - ;; - *) - ld_shlibs_GCJ=no - ;; - esac + runpath_var= + allow_undefined_flag= + enable_shared_with_static_runtimes=no + archive_cmds= + archive_expsym_cmds= + old_archive_From_new_cmds= + old_archive_from_expsyms_cmds= + export_dynamic_flag_spec= + whole_archive_flag_spec= + thread_safe_flag_spec= + hardcode_libdir_flag_spec= + hardcode_libdir_flag_spec_ld= + hardcode_libdir_separator= + hardcode_direct=no + hardcode_minus_L=no + hardcode_shlibpath_var=unsupported + link_all_deplibs=unknown + hardcode_automatic=no + module_cmds= + module_expsym_cmds= + always_export_symbols=no + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + # include_expsyms should be a list of space-separated symbols to be *always* + # included in the symbol list + include_expsyms= + # exclude_expsyms can be an extended regexp of symbols to exclude + # it will be wrapped by ` (' and `)$', so one must not match beginning or + # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', + # as well as any symbol that contains `d'. + exclude_expsyms="_GLOBAL_OFFSET_TABLE_" + # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out + # platforms (ab)use it in PIC code, but their linkers get confused if + # the symbol is explicitly referenced. Since portable code cannot + # rely on this symbol name, it's probably fine to never include it in + # preloaded symbol tables. + extract_expsyms_cmds= + # Just being paranoid about ensuring that cc_basename is set. + for cc_temp in $compiler""; do + case $cc_temp in + compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; + distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; + \-*) ;; + *) break;; + esac +done +cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` + + case $host_os in + cygwin* | mingw* | pw32*) + # FIXME: the MSVC++ port hasn't been tested in a loooong time + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + if test "$GCC" != yes; then + with_gnu_ld=no fi - ;; + ;; + openbsd*) + with_gnu_ld=no + ;; + esac - dgux*) - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_shlibpath_var_GCJ=no - ;; + ld_shlibs=yes + if test "$with_gnu_ld" = yes; then + # If archive_cmds runs LD, not CC, wlarc should be empty + wlarc='${wl}' - freebsd1*) - ld_shlibs_GCJ=no - ;; + # Set some defaults for GNU ld with shared library support. These + # are reset later if shared libraries are not supported. Putting them + # here allows them to be overridden if necessary. + runpath_var=LD_RUN_PATH + hardcode_libdir_flag_spec='${wl}--rpath ${wl}$libdir' + export_dynamic_flag_spec='${wl}--export-dynamic' + # ancient GNU ld didn't support --whole-archive et. al. + if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then + whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + else + whole_archive_flag_spec= + fi + supports_anon_versioning=no + case `$LD -v 2>/dev/null` in + *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 + *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... + *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... + *\ 2.11.*) ;; # other 2.11 versions + *) supports_anon_versioning=yes ;; + esac - # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor - # support. Future versions do this automatically, but an explicit c++rt0.o - # does not break anything, and helps significantly (at the cost of a little - # extra space). - freebsd2.2*) - archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' - hardcode_libdir_flag_spec_GCJ='-R$libdir' - hardcode_direct_GCJ=yes - hardcode_shlibpath_var_GCJ=no - ;; + # See if GNU ld supports shared libraries. + case $host_os in + aix3* | aix4* | aix5*) + # On AIX/PPC, the GNU linker is very broken + if test "$host_cpu" != ia64; then + ld_shlibs=no + cat <&2 - # Unfortunately, older versions of FreeBSD 2 do not have this feature. - freebsd2*) - archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct_GCJ=yes - hardcode_minus_L_GCJ=yes - hardcode_shlibpath_var_GCJ=no - ;; +*** Warning: the GNU linker, at least up to release 2.9.1, is reported +*** to be unable to reliably create shared libraries on AIX. +*** Therefore, libtool is disabling shared libraries support. If you +*** really care for shared libraries, you may want to modify your PATH +*** so that a non-GNU linker is found, and then restart. - # FreeBSD 3 and greater uses gcc -shared to do shared libraries. - freebsd* | kfreebsd*-gnu | dragonfly*) - archive_cmds_GCJ='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec_GCJ='-R$libdir' - hardcode_direct_GCJ=yes - hardcode_shlibpath_var_GCJ=no +EOF + fi ;; - hpux9*) - if test "$GCC" = yes; then - archive_cmds_GCJ='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - else - archive_cmds_GCJ='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - fi - hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' - hardcode_libdir_separator_GCJ=: - hardcode_direct_GCJ=yes + amigaos*) + archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L_GCJ=yes - export_dynamic_flag_spec_GCJ='${wl}-E' + # Samuel A. Falvo II reports + # that the semantics of dynamic libraries on AmigaOS, at least up + # to version 4, is to share data among multiple programs linked + # with the same dynamic library. Since this doesn't match the + # behavior of shared libraries on other platforms, we can't use + # them. + ld_shlibs=no ;; - hpux10* | hpux11*) - if test "$GCC" = yes -a "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*|ia64*) - archive_cmds_GCJ='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - archive_cmds_GCJ='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac + beos*) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + allow_undefined_flag=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' else - case $host_cpu in - hppa*64*|ia64*) - archive_cmds_GCJ='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags' - ;; - *) - archive_cmds_GCJ='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' - ;; - esac + ld_shlibs=no fi - if test "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*) - hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' - hardcode_libdir_flag_spec_ld_GCJ='+b $libdir' - hardcode_libdir_separator_GCJ=: - hardcode_direct_GCJ=no - hardcode_shlibpath_var_GCJ=no - ;; - ia64*) - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_direct_GCJ=no - hardcode_shlibpath_var_GCJ=no + ;; - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L_GCJ=yes - ;; - *) - hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' - hardcode_libdir_separator_GCJ=: - hardcode_direct_GCJ=yes - export_dynamic_flag_spec_GCJ='${wl}-E' + cygwin* | mingw* | pw32*) + # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, + # as there is no search path for DLLs. + hardcode_libdir_flag_spec='-L$libdir' + allow_undefined_flag=unsupported + always_export_symbols=no + enable_shared_with_static_runtimes=yes + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS] /s/.* \([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW] /s/.* //'\'' | sort | uniq > $export_symbols' - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L_GCJ=yes - ;; - esac + if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' + # If the export-symbols file already is a .def file (1st line + # is EXPORTS), use it as is; otherwise, prepend... + archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' + else + ld_shlibs=no fi ;; - irix5* | irix6* | nonstopux*) - if test "$GCC" = yes; then - archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + linux*) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + tmp_addflag= + case $cc_basename,$host_cpu in + pgcc*) # Portland Group C compiler + whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag' + ;; + pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers + whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag -Mnomain' ;; + ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 + tmp_addflag=' -i_dynamic' ;; + efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 + tmp_addflag=' -i_dynamic -nofor_main' ;; + ifc* | ifort*) # Intel Fortran compiler + tmp_addflag=' -nofor_main' ;; + esac + archive_cmds='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + + if test $supports_anon_versioning = yes; then + archive_expsym_cmds='$echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + $echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + fi else - archive_cmds_GCJ='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - hardcode_libdir_flag_spec_ld_GCJ='-rpath $libdir' + ld_shlibs=no fi - hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator_GCJ=: - link_all_deplibs_GCJ=yes ;; netbsd*) if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out + archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' + wlarc= else - archive_cmds_GCJ='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' fi - hardcode_libdir_flag_spec_GCJ='-R$libdir' - hardcode_direct_GCJ=yes - hardcode_shlibpath_var_GCJ=no ;; - newsos6) - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct_GCJ=yes - hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator_GCJ=: - hardcode_shlibpath_var_GCJ=no + solaris* | sysv5*) + if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then + ld_shlibs=no + cat <&2 + +*** Warning: The releases 2.8.* of the GNU linker cannot reliably +*** create shared libraries on Solaris systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.9.1 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +EOF + elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs=no + fi ;; - openbsd*) - hardcode_direct_GCJ=yes - hardcode_shlibpath_var_GCJ=no - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - archive_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' - hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir' - export_dynamic_flag_spec_GCJ='${wl}-E' + sunos4*) + archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' + wlarc= + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + *) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' else - case $host_os in - openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) - archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec_GCJ='-R$libdir' - ;; - *) - archive_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir' - ;; - esac + ld_shlibs=no fi ;; + esac + + if test "$ld_shlibs" = no; then + runpath_var= + hardcode_libdir_flag_spec= + export_dynamic_flag_spec= + whole_archive_flag_spec= + fi + else + # PORTME fill in a description of your system's linker (not GNU ld) + case $host_os in + aix3*) + allow_undefined_flag=unsupported + always_export_symbols=yes + archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' + # Note: this linker hardcodes the directories in LIBPATH if there + # are no directories specified by -L. + hardcode_minus_L=yes + if test "$GCC" = yes && test -z "$link_static_flag"; then + # Neither direct hardcoding nor static linking is supported with a + # broken collect2. + hardcode_direct=unsupported + fi + ;; + + aix4* | aix5*) + if test "$host_cpu" = ia64; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag="" + else + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to AIX nm, but means don't demangle with GNU nm + if $NM -V 2>&1 | grep 'GNU' > /dev/null; then + export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' + else + export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' + fi + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # need to do runtime linking. + case $host_os in aix4.[23]|aix4.[23].*|aix5*) + for ld_flag in $LDFLAGS; do + if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then + aix_use_runtimelinking=yes + break + fi + done + esac + + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + + archive_cmds='' + hardcode_direct=yes + hardcode_libdir_separator=':' + link_all_deplibs=yes + + if test "$GCC" = yes; then + case $host_os in aix4.[012]|aix4.[012].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`${CC} -print-prog-name=collect2` + if test -f "$collect2name" && \ + strings "$collect2name" | grep resolve_lib_name >/dev/null + then + # We have reworked collect2 + hardcode_direct=yes + else + # We have old collect2 + hardcode_direct=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + hardcode_minus_L=yes + hardcode_libdir_flag_spec='-L$libdir' + hardcode_libdir_separator= + fi + esac + shared_flag='-shared' + if test "$aix_use_runtimelinking" = yes; then + shared_flag="$shared_flag "'${wl}-G' + fi + else + # not using gcc + if test "$host_cpu" = ia64; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test "$aix_use_runtimelinking" = yes; then + shared_flag='${wl}-G' + else + shared_flag='${wl}-bM:SRE' + fi + fi + fi + + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to export. + always_export_symbols=yes + if test "$aix_use_runtimelinking" = yes; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + allow_undefined_flag='-berok' + # Determine the default libpath from the value encoded in an empty executable. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + +aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } +}'` +# Check for a 64-bit object if we didn't find anything. +if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } +}'`; fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi + + hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" + archive_expsym_cmds="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag" + else + if test "$host_cpu" = ia64; then + hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib' + allow_undefined_flag="-z nodefs" + archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an empty executable. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + +aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } +}'` +# Check for a 64-bit object if we didn't find anything. +if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } +}'`; fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi + + hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + no_undefined_flag=' ${wl}-bernotok' + allow_undefined_flag=' ${wl}-berok' + # -bexpall does not export symbols beginning with underscore (_) + always_export_symbols=yes + # Exported symbols can be pulled into shared objects from archives + whole_archive_flag_spec=' ' + archive_cmds_need_lc=yes + # This is similar to how AIX traditionally builds its shared libraries. + archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' + fi + fi + ;; + + amigaos*) + archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + # see comment about different semantics on the GNU ld section + ld_shlibs=no + ;; + + bsdi[45]*) + export_dynamic_flag_spec=-rdynamic + ;; + + cygwin* | mingw* | pw32*) + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + hardcode_libdir_flag_spec=' ' + allow_undefined_flag=unsupported + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + archive_cmds='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' + # The linker will automatically build a .lib file if we build a DLL. + old_archive_From_new_cmds='true' + # FIXME: Should let the user specify the lib program. + old_archive_cmds='lib /OUT:$oldlib$oldobjs$old_deplibs' + fix_srcfile_path='`cygpath -w "$srcfile"`' + enable_shared_with_static_runtimes=yes + ;; + + darwin* | rhapsody*) + case $host_os in + rhapsody* | darwin1.[012]) + allow_undefined_flag='${wl}-undefined ${wl}suppress' + ;; + *) # Darwin 1.3 on + if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then + allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' + else + case ${MACOSX_DEPLOYMENT_TARGET} in + 10.[012]) + allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' + ;; + 10.*) + allow_undefined_flag='${wl}-undefined ${wl}dynamic_lookup' + ;; + esac + fi + ;; + esac + archive_cmds_need_lc=no + hardcode_direct=no + hardcode_automatic=yes + hardcode_shlibpath_var=unsupported + whole_archive_flag_spec='' + link_all_deplibs=yes + if test "$GCC" = yes ; then + output_verbose_link_cmd='echo' + archive_cmds='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' + module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' + # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds + archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' + module_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' + else + case $cc_basename in + xlc*) + output_verbose_link_cmd='echo' + archive_cmds='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring' + module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' + # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds + archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' + module_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' + ;; + *) + ld_shlibs=no + ;; + esac + fi + ;; + + dgux*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_shlibpath_var=no + ;; + + freebsd1*) + ld_shlibs=no + ;; + + # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor + # support. Future versions do this automatically, but an explicit c++rt0.o + # does not break anything, and helps significantly (at the cost of a little + # extra space). + freebsd2.2*) + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + # Unfortunately, older versions of FreeBSD 2 do not have this feature. + freebsd2*) + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes + hardcode_minus_L=yes + hardcode_shlibpath_var=no + ;; + + # FreeBSD 3 and greater uses gcc -shared to do shared libraries. + freebsd* | kfreebsd*-gnu | dragonfly*) + archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + hpux9*) + if test "$GCC" = yes; then + archive_cmds='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + else + archive_cmds='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + fi + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' + hardcode_libdir_separator=: + hardcode_direct=yes + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + export_dynamic_flag_spec='${wl}-E' + ;; + + hpux10* | hpux11*) + if test "$GCC" = yes -a "$with_gnu_ld" = no; then + case $host_cpu in + hppa*64*|ia64*) + archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + else + case $host_cpu in + hppa*64*|ia64*) + archive_cmds='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags' + ;; + *) + archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' + ;; + esac + fi + if test "$with_gnu_ld" = no; then + case $host_cpu in + hppa*64*) + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' + hardcode_libdir_flag_spec_ld='+b $libdir' + hardcode_libdir_separator=: + hardcode_direct=no + hardcode_shlibpath_var=no + ;; + ia64*) + hardcode_libdir_flag_spec='-L$libdir' + hardcode_direct=no + hardcode_shlibpath_var=no + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + ;; + *) + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' + hardcode_libdir_separator=: + hardcode_direct=yes + export_dynamic_flag_spec='${wl}-E' + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + ;; + esac + fi + ;; + + irix5* | irix6* | nonstopux*) + if test "$GCC" = yes; then + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + hardcode_libdir_flag_spec_ld='-rpath $libdir' + fi + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator=: + link_all_deplibs=yes + ;; + + netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out + else + archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF + fi + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + newsos6) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator=: + hardcode_shlibpath_var=no + ;; + + openbsd*) + hardcode_direct=yes + hardcode_shlibpath_var=no + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' + hardcode_libdir_flag_spec='${wl}-rpath,$libdir' + export_dynamic_flag_spec='${wl}-E' + else + case $host_os in + openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec='-R$libdir' + ;; + *) + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec='${wl}-rpath,$libdir' + ;; + esac + fi + ;; + + os2*) + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + allow_undefined_flag=unsupported + archive_cmds='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' + old_archive_From_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' + ;; + + osf3*) + if test "$GCC" = yes; then + allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + allow_undefined_flag=' -expect_unresolved \*' + archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + fi + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator=: + ;; + + osf4* | osf5*) # as osf3* with the addition of -msym flag + if test "$GCC" = yes; then + allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + else + allow_undefined_flag=' -expect_unresolved \*' + archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ + $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' + + # Both c and cxx compiler support -rpath directly + hardcode_libdir_flag_spec='-rpath $libdir' + fi + hardcode_libdir_separator=: + ;; + + sco3.2v5*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var=no + export_dynamic_flag_spec='${wl}-Bexport' + runpath_var=LD_RUN_PATH + hardcode_runpath_var=yes + ;; + + solaris*) + no_undefined_flag=' -z text' + if test "$GCC" = yes; then + wlarc='${wl}' + archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ + $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' + else + wlarc='' + archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' + archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ + $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' + fi + hardcode_libdir_flag_spec='-R$libdir' + hardcode_shlibpath_var=no + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; + *) + # The compiler driver will combine linker options so we + # cannot just pass the convience library names through + # without $wl, iff we do not link with $LD. + # Luckily, gcc supports the same syntax we need for Sun Studio. + # Supported since Solaris 2.6 (maybe 2.5.1?) + case $wlarc in + '') + whole_archive_flag_spec='-z allextract$convenience -z defaultextract' ;; + *) + whole_archive_flag_spec='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract' ;; + esac ;; + esac + link_all_deplibs=yes + ;; + + sunos4*) + if test "x$host_vendor" = xsequent; then + # Use $CC to link under sequent, because it throws in some extra .o + # files that make .init and .fini sections work. + archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' + fi + hardcode_libdir_flag_spec='-L$libdir' + hardcode_direct=yes + hardcode_minus_L=yes + hardcode_shlibpath_var=no + ;; + + sysv4) + case $host_vendor in + sni) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes # is this really true??? + ;; + siemens) + ## LD is ld it makes a PLAMLIB + ## CC just makes a GrossModule. + archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' + reload_cmds='$CC -r -o $output$reload_objs' + hardcode_direct=no + ;; + motorola) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=no #Motorola manual says yes, but my tests say they lie + ;; + esac + runpath_var='LD_RUN_PATH' + hardcode_shlibpath_var=no + ;; + + sysv4.3*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var=no + export_dynamic_flag_spec='-Bexport' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var=no + runpath_var=LD_RUN_PATH + hardcode_runpath_var=yes + ld_shlibs=yes + fi + ;; + + sysv4.2uw2*) + archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes + hardcode_minus_L=no + hardcode_shlibpath_var=no + hardcode_runpath_var=yes + runpath_var=LD_RUN_PATH + ;; + + sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7*) + no_undefined_flag='${wl}-z ${wl}text' + if test "$GCC" = yes; then + archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + runpath_var='LD_RUN_PATH' + hardcode_shlibpath_var=no + ;; + + sysv5*) + no_undefined_flag=' -z text' + # $CC -shared without GNU ld will not create a library from C++ + # object files and a static libstdc++, better avoid it by now + archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' + archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ + $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' + hardcode_libdir_flag_spec= + hardcode_shlibpath_var=no + runpath_var='LD_RUN_PATH' + ;; + + uts4*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_shlibpath_var=no + ;; + + *) + ld_shlibs=no + ;; + esac + fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5 +$as_echo "$ld_shlibs" >&6; } +test "$ld_shlibs" = no && can_build_shared=no + +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" +if test "$GCC" = yes; then + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" +fi + +# +# Do we need to explicitly link libc? +# +case "x$archive_cmds_need_lc" in +x|xyes) + # Assume -lc should be added + archive_cmds_need_lc=yes + + if test "$enable_shared" = yes && test "$GCC" = yes; then + case $archive_cmds in + *'~'*) + # FIXME: we may have to deal with multi-command sequences. + ;; + '$CC '*) + # Test whether the compiler implicitly links with -lc since on some + # systems, -lgcc has to come before -lc. If gcc already passes -lc + # to ld, don't add -lc before -lgcc. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 +$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } + $rm conftest* + printf "$lt_simple_compile_test_code" > conftest.$ac_ext + + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } 2>conftest.err; then + soname=conftest + lib=conftest + libobjs=conftest.$ac_objext + deplibs= + wl=$lt_prog_compiler_wl + compiler_flags=-v + linker_flags=-v + verstring= + output_objdir=. + libname=conftest + lt_save_allow_undefined_flag=$allow_undefined_flag + allow_undefined_flag= + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\""; } >&5 + (eval $archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + then + archive_cmds_need_lc=no + else + archive_cmds_need_lc=yes + fi + allow_undefined_flag=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $rm conftest* + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $archive_cmds_need_lc" >&5 +$as_echo "$archive_cmds_need_lc" >&6; } + ;; + esac + fi + ;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 +$as_echo_n "checking dynamic linker characteristics... " >&6; } +library_names_spec= +libname_spec='lib$name' +soname_spec= +shrext_cmds=".so" +postinstall_cmds= +postuninstall_cmds= +finish_cmds= +finish_eval= +shlibpath_var= +shlibpath_overrides_runpath=unknown +version_type=none +dynamic_linker="$host_os ld.so" +sys_lib_dlsearch_path_spec="/lib /usr/lib" +if test "$GCC" = yes; then + sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` + if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then + # if the path contains ";" then we assume it to be the separator + # otherwise default to the standard path separator (i.e. ":") - it is + # assumed that no part of a normal pathname contains ";" but that should + # okay in the real world where ";" in dirpaths is itself problematic. + sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi +else + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" +fi +need_lib_prefix=unknown +hardcode_into_libs=no + +# when you set need_version to no, make sure it does not cause -set_version +# flags to be left without arguments +need_version=unknown + +case $host_os in +aix3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' + shlibpath_var=LIBPATH + + # AIX 3 has no versioning support, so we append a major version to the name. + soname_spec='${libname}${release}${shared_ext}$major' + ;; + +aix4* | aix5*) + version_type=linux + need_lib_prefix=no + need_version=no + hardcode_into_libs=yes + if test "$host_cpu" = ia64; then + # AIX 5 supports IA64 + library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + else + # With GCC up to 2.95.x, collect2 would create an import file + # for dependence libraries. The import file would start with + # the line `#! .'. This would cause the generated library to + # depend on `.', always an invalid library. This was fixed in + # development snapshots of GCC prior to 3.0. + case $host_os in + aix4 | aix4.[01] | aix4.[01].*) + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' + echo ' yes ' + echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then + : + else + can_build_shared=no + fi + ;; + esac + # AIX (on Power*) has no versioning support, so currently we can not hardcode correct + # soname into executable. Probably we can add versioning support to + # collect2, so additional links can be useful in future. + if test "$aix_use_runtimelinking" = yes; then + # If using run time linking (on AIX 4.2 or later) use lib.so + # instead of lib.a to let people know that these are not + # typical AIX shared libraries. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + else + # We preserve .a as extension for shared libraries through AIX4.2 + # and later when we are not doing run time linking. + library_names_spec='${libname}${release}.a $libname.a' + soname_spec='${libname}${release}${shared_ext}$major' + fi + shlibpath_var=LIBPATH + fi + ;; + +amigaos*) + library_names_spec='$libname.ixlibrary $libname.a' + # Create ${libname}_ixlibrary.a entries in /sys/libs. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' + ;; + +beos*) + library_names_spec='${libname}${shared_ext}' + dynamic_linker="$host_os ld.so" + shlibpath_var=LIBRARY_PATH + ;; + +bsdi[45]*) + version_type=linux + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" + # the default ld.so.conf also contains /usr/contrib/lib and + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow + # libtool to hard-code these into programs + ;; + +cygwin* | mingw* | pw32*) + version_type=windows + shrext_cmds=".dll" + need_version=no + need_lib_prefix=no + + case $GCC,$host_os in + yes,cygwin* | yes,mingw* | yes,pw32*) + library_names_spec='$libname.dll.a' + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $rm \$dlpath' + shlibpath_overrides_runpath=yes + + case $host_os in + cygwin*) + # Cygwin DLLs use 'cyg' prefix rather than 'lib' + soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" + ;; + mingw*) + # MinGW DLLs use traditional 'lib' prefix + soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` + if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then + # It is most probably a Windows format PATH printed by + # mingw gcc, but we are running on Cygwin. Gcc prints its search + # path with ; separators, and with drive letters. We can handle the + # drive letters (cygwin fileutils understands them), so leave them, + # especially as we might pass files found there to a mingw objdump, + # which wouldn't understand a cygwinified path. Ahh. + sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + ;; + pw32*) + # pw32 DLLs use 'pw' prefix rather than 'lib' + library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + ;; + esac + ;; + + *) + library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' + ;; + esac + dynamic_linker='Win32 ld.exe' + # FIXME: first we should search . and the directory the executable is in + shlibpath_var=PATH + ;; + +darwin* | rhapsody*) + dynamic_linker="$host_os dyld" + version_type=darwin + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' + soname_spec='${libname}${release}${major}$shared_ext' + shlibpath_overrides_runpath=yes + shlibpath_var=DYLD_LIBRARY_PATH + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' + # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same. + if test "$GCC" = yes; then + sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"` + else + sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib' + fi + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' + ;; + +dgux*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +freebsd1*) + dynamic_linker=no + ;; + +kfreebsd*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='GNU ld.so' + ;; + +freebsd* | dragonfly*) + # DragonFly does not have aout. When/if they implement a new + # versioning mechanism, adjust this. + if test -x /usr/bin/objformat; then + objformat=`/usr/bin/objformat` + else + case $host_os in + freebsd[123]*) objformat=aout ;; + *) objformat=elf ;; + esac + fi + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + need_version=no + need_lib_prefix=no + ;; + freebsd-*) + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' + need_version=yes + ;; + esac + shlibpath_var=LD_LIBRARY_PATH + case $host_os in + freebsd2*) + shlibpath_overrides_runpath=yes + ;; + freebsd3.[01]* | freebsdelf3.[01]*) + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + *) # from 3.2 on + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + esac + ;; + +gnu*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + hardcode_into_libs=yes + ;; + +hpux9* | hpux10* | hpux11*) + # Give a soname corresponding to the major version so that dld.sl refuses to + # link against other versions. + version_type=sunos + need_lib_prefix=no + need_version=no + case $host_cpu in + ia64*) + shrext_cmds='.so' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.so" + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + if test "X$HPUX_IA64_MODE" = X32; then + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + else + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + fi + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + hppa*64*) + shrext_cmds='.sl' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.sl" + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + *) + shrext_cmds='.sl' + dynamic_linker="$host_os dld.sl" + shlibpath_var=SHLIB_PATH + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + ;; + esac + # HP-UX runs *really* slowly unless shared libraries are mode 555. + postinstall_cmds='chmod 555 $lib' + ;; + +irix5* | irix6* | nonstopux*) + case $host_os in + nonstopux*) version_type=nonstopux ;; + *) + if test "$lt_cv_prog_gnu_ld" = yes; then + version_type=linux + else + version_type=irix + fi ;; + esac + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' + case $host_os in + irix5* | nonstopux*) + libsuff= shlibsuff= + ;; + *) + case $LD in # libtool.m4 will add one of these switches to LD + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") + libsuff= shlibsuff= libmagic=32-bit;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") + libsuff=32 shlibsuff=N32 libmagic=N32;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") + libsuff=64 shlibsuff=64 libmagic=64-bit;; + *) libsuff= shlibsuff= libmagic=never-match;; + esac + ;; + esac + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH + shlibpath_overrides_runpath=no + sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" + sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" + hardcode_into_libs=yes + ;; + +# No shared lib support for Linux oldld, aout, or coff. +linux*oldld* | linux*aout* | linux*coff*) + dynamic_linker=no + ;; + +# This must be Linux ELF. +linux*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + # Append ld.so.conf contents to the search path + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi + + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; + +knetbsd*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='GNU ld.so' + ;; + +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' + else + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='NetBSD ld.elf_so' + fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + +newsos6) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +nto-qnx*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +openbsd*) + version_type=sunos + need_lib_prefix=no + # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. + case $host_os in + openbsd3.3 | openbsd3.3.*) need_version=yes ;; + *) need_version=no ;; + esac + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + case $host_os in + openbsd2.[89] | openbsd2.[89].*) + shlibpath_overrides_runpath=no + ;; + *) + shlibpath_overrides_runpath=yes + ;; + esac + else + shlibpath_overrides_runpath=yes + fi + ;; + +os2*) + libname_spec='$name' + shrext_cmds=".dll" + need_lib_prefix=no + library_names_spec='$libname${shared_ext} $libname.a' + dynamic_linker='OS/2 ld.exe' + shlibpath_var=LIBPATH + ;; + +osf3* | osf4* | osf5*) + version_type=osf + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" + sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" + ;; + +sco3.2v5*) + version_type=osf + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + ;; + +solaris*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + # ldd complains unless libraries are executable + postinstall_cmds='chmod +x $lib' + ;; + +sunos4*) + version_type=sunos + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + if test "$with_gnu_ld" = yes; then + need_lib_prefix=no + fi + need_version=yes + ;; + +sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + export_dynamic_flag_spec='${wl}-Blargedynsym' + runpath_var=LD_RUN_PATH + ;; + siemens) + need_lib_prefix=no + ;; + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' + ;; + esac + ;; + +sysv4*MP*) + if test -d /usr/nec ;then + version_type=linux + library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' + soname_spec='$libname${shared_ext}.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; + +uts4*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +*) + dynamic_linker=no + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 +$as_echo "$dynamic_linker" >&6; } +test "$dynamic_linker" = no && can_build_shared=no + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 +$as_echo_n "checking how to hardcode library paths into programs... " >&6; } +hardcode_action= +if test -n "$hardcode_libdir_flag_spec" || \ + test -n "$runpath_var" || \ + test "X$hardcode_automatic" = "Xyes" ; then + + # We can hardcode non-existant directories. + if test "$hardcode_direct" != no && + # If the only mechanism to avoid hardcoding is shlibpath_var, we + # have to relink, otherwise we might link with an installed library + # when we should be linking with a yet-to-be-installed one + ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, )" != no && + test "$hardcode_minus_L" != no; then + # Linking always hardcodes the temporary library directory. + hardcode_action=relink + else + # We can link without hardcoding, and we can hardcode nonexisting dirs. + hardcode_action=immediate + fi +else + # We cannot hardcode anything, or else we can only hardcode existing + # directories. + hardcode_action=unsupported +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5 +$as_echo "$hardcode_action" >&6; } + +if test "$hardcode_action" = relink; then + # Fast installation is not supported + enable_fast_install=no +elif test "$shlibpath_overrides_runpath" = yes || + test "$enable_shared" = no; then + # Fast installation is not necessary + enable_fast_install=needless +fi + +striplib= +old_striplib= +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 +$as_echo_n "checking whether stripping libraries is possible... " >&6; } +if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then + test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" + test -z "$striplib" && striplib="$STRIP --strip-unneeded" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else +# FIXME - insert some real tests, host_os isn't really good enough + case $host_os in + darwin*) + if test -n "$STRIP" ; then + striplib="$STRIP -x" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + ;; + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + ;; + esac +fi + +if test "x$enable_dlopen" != xyes; then + enable_dlopen=unknown + enable_dlopen_self=unknown + enable_dlopen_self_static=unknown +else + lt_cv_dlopen=no + lt_cv_dlopen_libs= + + case $host_os in + beos*) + lt_cv_dlopen="load_add_on" + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + ;; + + mingw* | pw32*) + lt_cv_dlopen="LoadLibrary" + lt_cv_dlopen_libs= + ;; + + cygwin*) + lt_cv_dlopen="dlopen" + lt_cv_dlopen_libs= + ;; + + darwin*) + # if libdl is installed we need to link against it + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 +$as_echo_n "checking for dlopen in -ldl... " >&6; } +if test "${ac_cv_lib_dl_dlopen+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldl $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dl_dlopen=yes +else + ac_cv_lib_dl_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 +$as_echo "$ac_cv_lib_dl_dlopen" >&6; } +if test "x$ac_cv_lib_dl_dlopen" = x""yes; then : + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" +else + + lt_cv_dlopen="dyld" + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + +fi + + ;; + + *) + ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" +if test "x$ac_cv_func_shl_load" = x""yes; then : + lt_cv_dlopen="shl_load" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 +$as_echo_n "checking for shl_load in -ldld... " >&6; } +if test "${ac_cv_lib_dld_shl_load+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char shl_load (); +int +main () +{ +return shl_load (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dld_shl_load=yes +else + ac_cv_lib_dld_shl_load=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 +$as_echo "$ac_cv_lib_dld_shl_load" >&6; } +if test "x$ac_cv_lib_dld_shl_load" = x""yes; then : + lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld" +else + ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" +if test "x$ac_cv_func_dlopen" = x""yes; then : + lt_cv_dlopen="dlopen" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 +$as_echo_n "checking for dlopen in -ldl... " >&6; } +if test "${ac_cv_lib_dl_dlopen+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldl $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dl_dlopen=yes +else + ac_cv_lib_dl_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 +$as_echo "$ac_cv_lib_dl_dlopen" >&6; } +if test "x$ac_cv_lib_dl_dlopen" = x""yes; then : + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 +$as_echo_n "checking for dlopen in -lsvld... " >&6; } +if test "${ac_cv_lib_svld_dlopen+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lsvld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_svld_dlopen=yes +else + ac_cv_lib_svld_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 +$as_echo "$ac_cv_lib_svld_dlopen" >&6; } +if test "x$ac_cv_lib_svld_dlopen" = x""yes; then : + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 +$as_echo_n "checking for dld_link in -ldld... " >&6; } +if test "${ac_cv_lib_dld_dld_link+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dld_link (); +int +main () +{ +return dld_link (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dld_dld_link=yes +else + ac_cv_lib_dld_dld_link=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 +$as_echo "$ac_cv_lib_dld_dld_link" >&6; } +if test "x$ac_cv_lib_dld_dld_link" = x""yes; then : + lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld" +fi - os2*) - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_minus_L_GCJ=yes - allow_undefined_flag_GCJ=unsupported - archive_cmds_GCJ='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' - old_archive_From_new_cmds_GCJ='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' - ;; - osf3*) - if test "$GCC" = yes; then - allow_undefined_flag_GCJ=' ${wl}-expect_unresolved ${wl}\*' - archive_cmds_GCJ='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - allow_undefined_flag_GCJ=' -expect_unresolved \*' - archive_cmds_GCJ='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - fi - hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator_GCJ=: - ;; +fi - osf4* | osf5*) # as osf3* with the addition of -msym flag - if test "$GCC" = yes; then - allow_undefined_flag_GCJ=' ${wl}-expect_unresolved ${wl}\*' - archive_cmds_GCJ='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' - else - allow_undefined_flag_GCJ=' -expect_unresolved \*' - archive_cmds_GCJ='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - archive_expsym_cmds_GCJ='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ - $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' - # Both c and cxx compiler support -rpath directly - hardcode_libdir_flag_spec_GCJ='-rpath $libdir' - fi - hardcode_libdir_separator_GCJ=: - ;; +fi - sco3.2v5*) - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var_GCJ=no - export_dynamic_flag_spec_GCJ='${wl}-Bexport' - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - ;; - solaris*) - no_undefined_flag_GCJ=' -z text' - if test "$GCC" = yes; then - wlarc='${wl}' - archive_cmds_GCJ='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds_GCJ='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' - else - wlarc='' - archive_cmds_GCJ='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - archive_expsym_cmds_GCJ='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' - fi - hardcode_libdir_flag_spec_GCJ='-R$libdir' - hardcode_shlibpath_var_GCJ=no - case $host_os in - solaris2.[0-5] | solaris2.[0-5].*) ;; - *) - # The compiler driver will combine linker options so we - # cannot just pass the convience library names through - # without $wl, iff we do not link with $LD. - # Luckily, gcc supports the same syntax we need for Sun Studio. - # Supported since Solaris 2.6 (maybe 2.5.1?) - case $wlarc in - '') - whole_archive_flag_spec_GCJ='-z allextract$convenience -z defaultextract' ;; - *) - whole_archive_flag_spec_GCJ='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract' ;; - esac ;; - esac - link_all_deplibs_GCJ=yes - ;; +fi - sunos4*) - if test "x$host_vendor" = xsequent; then - # Use $CC to link under sequent, because it throws in some extra .o - # files that make .init and .fini sections work. - archive_cmds_GCJ='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds_GCJ='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' - fi - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_direct_GCJ=yes - hardcode_minus_L_GCJ=yes - hardcode_shlibpath_var_GCJ=no - ;; - sysv4) - case $host_vendor in - sni) - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct_GCJ=yes # is this really true??? - ;; - siemens) - ## LD is ld it makes a PLAMLIB - ## CC just makes a GrossModule. - archive_cmds_GCJ='$LD -G -o $lib $libobjs $deplibs $linker_flags' - reload_cmds_GCJ='$CC -r -o $output$reload_objs' - hardcode_direct_GCJ=no - ;; - motorola) - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct_GCJ=no #Motorola manual says yes, but my tests say they lie - ;; - esac - runpath_var='LD_RUN_PATH' - hardcode_shlibpath_var_GCJ=no - ;; +fi - sysv4.3*) - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var_GCJ=no - export_dynamic_flag_spec_GCJ='-Bexport' - ;; - sysv4*MP*) - if test -d /usr/nec; then - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var_GCJ=no - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - ld_shlibs_GCJ=yes - fi - ;; +fi - sysv4.2uw2*) - archive_cmds_GCJ='$LD -G -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct_GCJ=yes - hardcode_minus_L_GCJ=no - hardcode_shlibpath_var_GCJ=no - hardcode_runpath_var=yes - runpath_var=LD_RUN_PATH - ;; + ;; + esac - sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7*) - no_undefined_flag_GCJ='${wl}-z ${wl}text' - if test "$GCC" = yes; then - archive_cmds_GCJ='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds_GCJ='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - runpath_var='LD_RUN_PATH' - hardcode_shlibpath_var_GCJ=no - ;; + if test "x$lt_cv_dlopen" != xno; then + enable_dlopen=yes + else + enable_dlopen=no + fi - sysv5*) - no_undefined_flag_GCJ=' -z text' - # $CC -shared without GNU ld will not create a library from C++ - # object files and a static libstdc++, better avoid it by now - archive_cmds_GCJ='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - archive_expsym_cmds_GCJ='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' - hardcode_libdir_flag_spec_GCJ= - hardcode_shlibpath_var_GCJ=no - runpath_var='LD_RUN_PATH' - ;; + case $lt_cv_dlopen in + dlopen) + save_CPPFLAGS="$CPPFLAGS" + test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" - uts4*) - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_shlibpath_var_GCJ=no - ;; + save_LDFLAGS="$LDFLAGS" + eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" - *) - ld_shlibs_GCJ=no - ;; - esac - fi + save_LIBS="$LIBS" + LIBS="$lt_cv_dlopen_libs $LIBS" -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_GCJ" >&5 -$as_echo "$ld_shlibs_GCJ" >&6; } -test "$ld_shlibs_GCJ" = no && can_build_shared=no + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 +$as_echo_n "checking whether a program can dlopen itself... " >&6; } +if test "${lt_cv_dlopen_self+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + lt_cv_dlopen_self=cross +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext < +#endif -# -# Do we need to explicitly link libc? -# -case "x$archive_cmds_need_lc_GCJ" in -x|xyes) - # Assume -lc should be added - archive_cmds_need_lc_GCJ=yes +#include - if test "$enable_shared" = yes && test "$GCC" = yes; then - case $archive_cmds_GCJ in - *'~'*) - # FIXME: we may have to deal with multi-command sequences. - ;; - '$CC '*) - # Test whether the compiler implicitly links with -lc since on some - # systems, -lgcc has to come before -lc. If gcc already passes -lc - # to ld, don't add -lc before -lgcc. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 -$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } - $rm conftest* - printf "$lt_simple_compile_test_code" > conftest.$ac_ext +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif + +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif + +#ifdef __cplusplus +extern "C" void exit (int); +#endif - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } 2>conftest.err; then - soname=conftest - lib=conftest - libobjs=conftest.$ac_objext - deplibs= - wl=$lt_prog_compiler_wl_GCJ - compiler_flags=-v - linker_flags=-v - verstring= - output_objdir=. - libname=conftest - lt_save_allow_undefined_flag=$allow_undefined_flag_GCJ - allow_undefined_flag_GCJ= - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_GCJ 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\""; } >&5 - (eval $archive_cmds_GCJ 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5 +void fnord() { int i=42;} +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; + + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + /* dlclose (self); */ + } + + exit (status); +} +EOF + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - then - archive_cmds_need_lc_GCJ=no - else - archive_cmds_need_lc_GCJ=yes - fi - allow_undefined_flag_GCJ=$lt_save_allow_undefined_flag - else - cat conftest.err 1>&5 - fi - $rm conftest* - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $archive_cmds_need_lc_GCJ" >&5 -$as_echo "$archive_cmds_need_lc_GCJ" >&6; } - ;; + test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then + (./conftest; exit; ) >&5 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; + x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; + x$lt_unknown|x*) lt_cv_dlopen_self=no ;; esac + else : + # compilation failed + lt_cv_dlopen_self=no fi - ;; -esac +fi +rm -fr conftest* + -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 -$as_echo_n "checking dynamic linker characteristics... " >&6; } -library_names_spec= -libname_spec='lib$name' -soname_spec= -shrext_cmds=".so" -postinstall_cmds= -postuninstall_cmds= -finish_cmds= -finish_eval= -shlibpath_var= -shlibpath_overrides_runpath=unknown -version_type=none -dynamic_linker="$host_os ld.so" -sys_lib_dlsearch_path_spec="/lib /usr/lib" -if test "$GCC" = yes; then - sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then - # if the path contains ";" then we assume it to be the separator - # otherwise default to the standard path separator (i.e. ":") - it is - # assumed that no part of a normal pathname contains ";" but that should - # okay in the real world where ";" in dirpaths is itself problematic. - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi -else - sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" fi -need_lib_prefix=unknown -hardcode_into_libs=no +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 +$as_echo "$lt_cv_dlopen_self" >&6; } -# when you set need_version to no, make sure it does not cause -set_version -# flags to be left without arguments -need_version=unknown + if test "x$lt_cv_dlopen_self" = xyes; then + LDFLAGS="$LDFLAGS $link_static_flag" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 +$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } +if test "${lt_cv_dlopen_self_static+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + lt_cv_dlopen_self_static=cross +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext < +#endif - # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='${libname}${release}${shared_ext}$major' - ;; +#include -aix4* | aix5*) - version_type=linux - need_lib_prefix=no - need_version=no - hardcode_into_libs=yes - if test "$host_cpu" = ia64; then - # AIX 5 supports IA64 - library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - else - # With GCC up to 2.95.x, collect2 would create an import file - # for dependence libraries. The import file would start with - # the line `#! .'. This would cause the generated library to - # depend on `.', always an invalid library. This was fixed in - # development snapshots of GCC prior to 3.0. - case $host_os in - aix4 | aix4.[01] | aix4.[01].*) - if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' - echo ' yes ' - echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then - : - else - can_build_shared=no - fi - ;; - esac - # AIX (on Power*) has no versioning support, so currently we can not hardcode correct - # soname into executable. Probably we can add versioning support to - # collect2, so additional links can be useful in future. - if test "$aix_use_runtimelinking" = yes; then - # If using run time linking (on AIX 4.2 or later) use lib.so - # instead of lib.a to let people know that these are not - # typical AIX shared libraries. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - else - # We preserve .a as extension for shared libraries through AIX4.2 - # and later when we are not doing run time linking. - library_names_spec='${libname}${release}.a $libname.a' - soname_spec='${libname}${release}${shared_ext}$major' - fi - shlibpath_var=LIBPATH - fi - ;; +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif -amigaos*) - library_names_spec='$libname.ixlibrary $libname.a' - # Create ${libname}_ixlibrary.a entries in /sys/libs. - finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' - ;; +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif -beos*) - library_names_spec='${libname}${shared_ext}' - dynamic_linker="$host_os ld.so" - shlibpath_var=LIBRARY_PATH - ;; +#ifdef __cplusplus +extern "C" void exit (int); +#endif -bsdi[45]*) - version_type=linux - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" - # the default ld.so.conf also contains /usr/contrib/lib and - # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow - # libtool to hard-code these into programs - ;; +void fnord() { int i=42;} +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; + + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + /* dlclose (self); */ + } + + exit (status); +} +EOF + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then + (./conftest; exit; ) >&5 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; + x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; + x$lt_unknown|x*) lt_cv_dlopen_self_static=no ;; + esac + else : + # compilation failed + lt_cv_dlopen_self_static=no + fi +fi +rm -fr conftest* -cygwin* | mingw* | pw32*) - version_type=windows - shrext_cmds=".dll" - need_version=no - need_lib_prefix=no - case $GCC,$host_os in - yes,cygwin* | yes,mingw* | yes,pw32*) - library_names_spec='$libname.dll.a' - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $rm \$dlpath' - shlibpath_overrides_runpath=yes +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 +$as_echo "$lt_cv_dlopen_self_static" >&6; } + fi - case $host_os in - cygwin*) - # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" - ;; - mingw*) - # MinGW DLLs use traditional 'lib' prefix - soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then - # It is most probably a Windows format PATH printed by - # mingw gcc, but we are running on Cygwin. Gcc prints its search - # path with ; separators, and with drive letters. We can handle the - # drive letters (cygwin fileutils understands them), so leave them, - # especially as we might pass files found there to a mingw objdump, - # which wouldn't understand a cygwinified path. Ahh. - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi - ;; - pw32*) - # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - ;; - esac + CPPFLAGS="$save_CPPFLAGS" + LDFLAGS="$save_LDFLAGS" + LIBS="$save_LIBS" ;; + esac - *) - library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' - ;; + case $lt_cv_dlopen_self in + yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; + *) enable_dlopen_self=unknown ;; esac - dynamic_linker='Win32 ld.exe' - # FIXME: first we should search . and the directory the executable is in - shlibpath_var=PATH - ;; -darwin* | rhapsody*) - dynamic_linker="$host_os dyld" - version_type=darwin - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' - soname_spec='${libname}${release}${major}$shared_ext' - shlibpath_overrides_runpath=yes - shlibpath_var=DYLD_LIBRARY_PATH - shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' - # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same. - if test "$GCC" = yes; then - sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"` - else - sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib' - fi - sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' - ;; + case $lt_cv_dlopen_self_static in + yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; + *) enable_dlopen_self_static=unknown ;; + esac +fi -dgux*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; -freebsd1*) - dynamic_linker=no - ;; +# Report which librarie types wil actually be built +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5 +$as_echo_n "checking if libtool supports shared libraries... " >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5 +$as_echo "$can_build_shared" >&6; } -kfreebsd*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='GNU ld.so' +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5 +$as_echo_n "checking whether to build shared libraries... " >&6; } +test "$can_build_shared" = "no" && enable_shared=no + +# On AIX, shared libraries and static libraries use the same namespace, and +# are all built from PIC. +case $host_os in +aix3*) + test "$enable_shared" = yes && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi ;; -freebsd* | dragonfly*) - # DragonFly does not have aout. When/if they implement a new - # versioning mechanism, adjust this. - if test -x /usr/bin/objformat; then - objformat=`/usr/bin/objformat` - else - case $host_os in - freebsd[123]*) objformat=aout ;; - *) objformat=elf ;; - esac +aix4* | aix5*) + if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then + test "$enable_shared" = yes && enable_static=no fi - version_type=freebsd-$objformat - case $version_type in - freebsd-elf*) - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - need_version=no - need_lib_prefix=no - ;; - freebsd-*) - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' - need_version=yes - ;; - esac - shlibpath_var=LD_LIBRARY_PATH - case $host_os in - freebsd2*) - shlibpath_overrides_runpath=yes - ;; - freebsd3.[01]* | freebsdelf3.[01]*) - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - *) # from 3.2 on - shlibpath_overrides_runpath=no - hardcode_into_libs=yes ;; - esac - ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 +$as_echo "$enable_shared" >&6; } -gnu*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - hardcode_into_libs=yes - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5 +$as_echo_n "checking whether to build static libraries... " >&6; } +# Make sure either enable_shared or enable_static is yes. +test "$enable_shared" = yes || enable_static=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5 +$as_echo "$enable_static" >&6; } -hpux9* | hpux10* | hpux11*) - # Give a soname corresponding to the major version so that dld.sl refuses to - # link against other versions. - version_type=sunos - need_lib_prefix=no - need_version=no - case $host_cpu in - ia64*) - shrext_cmds='.so' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.so" - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - if test "X$HPUX_IA64_MODE" = X32; then - sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" - else - sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" - fi - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - hppa*64*) - shrext_cmds='.sl' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.sl" - shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - *) - shrext_cmds='.sl' - dynamic_linker="$host_os dld.sl" - shlibpath_var=SHLIB_PATH - shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - ;; - esac - # HP-UX runs *really* slowly unless shared libraries are mode 555. - postinstall_cmds='chmod 555 $lib' - ;; +# The else clause should only fire when bootstrapping the +# libtool distribution, otherwise you forgot to ship ltmain.sh +# with your package, and you will get complaints that there are +# no rules to generate ltmain.sh. +if test -f "$ltmain"; then + # See if we are running on zsh, and set the options which allow our commands through + # without removal of \ escapes. + if test -n "${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST + fi + # Now quote all the things that may contain metacharacters while being + # careful not to overquote the AC_SUBSTed values. We take copies of the + # variables and quote the copies for generation of the libtool script. + for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \ + SED SHELL STRIP \ + libname_spec library_names_spec soname_spec extract_expsyms_cmds \ + old_striplib striplib file_magic_cmd finish_cmds finish_eval \ + deplibs_check_method reload_flag reload_cmds need_locks \ + lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ + lt_cv_sys_global_symbol_to_c_name_address \ + sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ + old_postinstall_cmds old_postuninstall_cmds \ + compiler \ + CC \ + LD \ + lt_prog_compiler_wl \ + lt_prog_compiler_pic \ + lt_prog_compiler_static \ + lt_prog_compiler_no_builtin_flag \ + export_dynamic_flag_spec \ + thread_safe_flag_spec \ + whole_archive_flag_spec \ + enable_shared_with_static_runtimes \ + old_archive_cmds \ + old_archive_from_new_cmds \ + predep_objects \ + postdep_objects \ + predeps \ + postdeps \ + compiler_lib_search_path \ + archive_cmds \ + archive_expsym_cmds \ + postinstall_cmds \ + postuninstall_cmds \ + old_archive_from_expsyms_cmds \ + allow_undefined_flag \ + no_undefined_flag \ + export_symbols_cmds \ + hardcode_libdir_flag_spec \ + hardcode_libdir_flag_spec_ld \ + hardcode_libdir_separator \ + hardcode_automatic \ + module_cmds \ + module_expsym_cmds \ + lt_cv_prog_compiler_c_o \ + exclude_expsyms \ + include_expsyms; do -irix5* | irix6* | nonstopux*) - case $host_os in - nonstopux*) version_type=nonstopux ;; + case $var in + old_archive_cmds | \ + old_archive_from_new_cmds | \ + archive_cmds | \ + archive_expsym_cmds | \ + module_cmds | \ + module_expsym_cmds | \ + old_archive_from_expsyms_cmds | \ + export_symbols_cmds | \ + extract_expsyms_cmds | reload_cmds | finish_cmds | \ + postinstall_cmds | postuninstall_cmds | \ + old_postinstall_cmds | old_postuninstall_cmds | \ + sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) + # Double-quote double-evaled strings. + eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" + ;; *) - if test "$lt_cv_prog_gnu_ld" = yes; then - version_type=linux - else - version_type=irix - fi ;; - esac - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' - case $host_os in - irix5* | nonstopux*) - libsuff= shlibsuff= - ;; - *) - case $LD in # libtool.m4 will add one of these switches to LD - *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") - libsuff= shlibsuff= libmagic=32-bit;; - *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") - libsuff=32 shlibsuff=N32 libmagic=N32;; - *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") - libsuff=64 shlibsuff=64 libmagic=64-bit;; - *) libsuff= shlibsuff= libmagic=never-match;; + eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" + ;; esac + done + + case $lt_echo in + *'\$0 --fallback-echo"') + lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` ;; esac - shlibpath_var=LD_LIBRARY${shlibsuff}_PATH - shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" - sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" - hardcode_into_libs=yes - ;; -# No shared lib support for Linux oldld, aout, or coff. -linux*oldld* | linux*aout* | linux*coff*) - dynamic_linker=no - ;; +cfgfile="${ofile}T" + trap "$rm \"$cfgfile\"; exit 1" 1 2 15 + $rm -f "$cfgfile" + { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ofile" >&5 +$as_echo "$as_me: creating $ofile" >&6;} -# This must be Linux ELF. -linux*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes + cat <<__EOF__ >> "$cfgfile" +#! $SHELL - # Append ld.so.conf contents to the search path - if test -f /etc/ld.so.conf; then - lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` - sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" - fi +# `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services. +# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP) +# NOTE: Changes made to this file will be lost: look at ltmain.sh. +# +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001 +# Free Software Foundation, Inc. +# +# This file is part of GNU Libtool: +# Originally by Gordon Matzigkeit , 1996 +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. +# +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that program. - # We used to test for /lib/ld.so.1 and disable shared libraries on - # powerpc, because MkLinux only supported shared libraries with the - # GNU dynamic linker. Since this was broken with cross compilers, - # most powerpc-linux boxes support dynamic linking these days and - # people can always --disable-shared, the test was removed, and we - # assume the GNU/Linux dynamic linker is in use. - dynamic_linker='GNU/Linux ld.so' - ;; +# A sed program that does not truncate output. +SED=$lt_SED -knetbsd*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='GNU ld.so' - ;; +# Sed that helps us avoid accidentally triggering echo(1) options like -n. +Xsed="$SED -e 1s/^X//" -netbsd*) - version_type=sunos - need_lib_prefix=no - need_version=no - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - dynamic_linker='NetBSD (a.out) ld.so' - else - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='NetBSD ld.elf_so' - fi - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; +# The HP-UX ksh and POSIX shell print the target directory to stdout +# if CDPATH is set. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH -newsos6) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; +# The names of the tagged configurations supported by this script. +available_tags= -nto-qnx*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; +# ### BEGIN LIBTOOL CONFIG -openbsd*) - version_type=sunos - need_lib_prefix=no - # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. - case $host_os in - openbsd3.3 | openbsd3.3.*) need_version=yes ;; - *) need_version=no ;; - esac - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - case $host_os in - openbsd2.[89] | openbsd2.[89].*) - shlibpath_overrides_runpath=no - ;; - *) - shlibpath_overrides_runpath=yes - ;; - esac - else - shlibpath_overrides_runpath=yes - fi - ;; +# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: + +# Shell to use when invoking shell scripts. +SHELL=$lt_SHELL + +# Whether or not to build shared libraries. +build_libtool_libs=$enable_shared + +# Whether or not to build static libraries. +build_old_libs=$enable_static + +# Whether or not to add -lc for building shared libraries. +build_libtool_need_lc=$archive_cmds_need_lc + +# Whether or not to disallow shared libs when runtime libs are static +allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes + +# Whether or not to optimize for fast installation. +fast_install=$enable_fast_install + +# The host system. +host_alias=$host_alias +host=$host +host_os=$host_os -os2*) - libname_spec='$name' - shrext_cmds=".dll" - need_lib_prefix=no - library_names_spec='$libname${shared_ext} $libname.a' - dynamic_linker='OS/2 ld.exe' - shlibpath_var=LIBPATH - ;; +# The build system. +build_alias=$build_alias +build=$build +build_os=$build_os -osf3* | osf4* | osf5*) - version_type=osf - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" - ;; +# An echo program that does not interpret backslashes. +echo=$lt_echo -sco3.2v5*) - version_type=osf - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - ;; +# The archiver. +AR=$lt_AR +AR_FLAGS=$lt_AR_FLAGS -solaris*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - # ldd complains unless libraries are executable - postinstall_cmds='chmod +x $lib' - ;; +# A C compiler. +LTCC=$lt_LTCC -sunos4*) - version_type=sunos - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - if test "$with_gnu_ld" = yes; then - need_lib_prefix=no - fi - need_version=yes - ;; +# A language-specific compiler. +CC=$lt_compiler -sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - case $host_vendor in - sni) - shlibpath_overrides_runpath=no - need_lib_prefix=no - export_dynamic_flag_spec='${wl}-Blargedynsym' - runpath_var=LD_RUN_PATH - ;; - siemens) - need_lib_prefix=no - ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - ;; - esac - ;; +# Is the compiler the GNU C compiler? +with_gcc=$GCC -sysv4*MP*) - if test -d /usr/nec ;then - version_type=linux - library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' - soname_spec='$libname${shared_ext}.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; +# An ERE matcher. +EGREP=$lt_EGREP -uts4*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; +# The linker used to build libraries. +LD=$lt_LD -*) - dynamic_linker=no - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 -$as_echo "$dynamic_linker" >&6; } -test "$dynamic_linker" = no && can_build_shared=no +# Whether we need hard or soft links. +LN_S=$lt_LN_S -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 -$as_echo_n "checking how to hardcode library paths into programs... " >&6; } -hardcode_action_GCJ= -if test -n "$hardcode_libdir_flag_spec_GCJ" || \ - test -n "$runpath_var_GCJ" || \ - test "X$hardcode_automatic_GCJ" = "Xyes" ; then +# A BSD-compatible nm program. +NM=$lt_NM - # We can hardcode non-existant directories. - if test "$hardcode_direct_GCJ" != no && - # If the only mechanism to avoid hardcoding is shlibpath_var, we - # have to relink, otherwise we might link with an installed library - # when we should be linking with a yet-to-be-installed one - ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, GCJ)" != no && - test "$hardcode_minus_L_GCJ" != no; then - # Linking always hardcodes the temporary library directory. - hardcode_action_GCJ=relink - else - # We can link without hardcoding, and we can hardcode nonexisting dirs. - hardcode_action_GCJ=immediate - fi -else - # We cannot hardcode anything, or else we can only hardcode existing - # directories. - hardcode_action_GCJ=unsupported -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action_GCJ" >&5 -$as_echo "$hardcode_action_GCJ" >&6; } +# A symbol stripping program +STRIP=$lt_STRIP -if test "$hardcode_action_GCJ" = relink; then - # Fast installation is not supported - enable_fast_install=no -elif test "$shlibpath_overrides_runpath" = yes || - test "$enable_shared" = no; then - # Fast installation is not necessary - enable_fast_install=needless -fi +# Used to examine libraries when file_magic_cmd begins "file" +MAGIC_CMD=$MAGIC_CMD -striplib= -old_striplib= -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 -$as_echo_n "checking whether stripping libraries is possible... " >&6; } -if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then - test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" - test -z "$striplib" && striplib="$STRIP --strip-unneeded" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -else -# FIXME - insert some real tests, host_os isn't really good enough - case $host_os in - darwin*) - if test -n "$STRIP" ; then - striplib="$STRIP -x" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - ;; - *) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - ;; - esac -fi +# Used on cygwin: DLL creation program. +DLLTOOL="$DLLTOOL" -if test "x$enable_dlopen" != xyes; then - enable_dlopen=unknown - enable_dlopen_self=unknown - enable_dlopen_self_static=unknown -else - lt_cv_dlopen=no - lt_cv_dlopen_libs= +# Used on cygwin: object dumper. +OBJDUMP="$OBJDUMP" - case $host_os in - beos*) - lt_cv_dlopen="load_add_on" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ;; +# Used on cygwin: assembler. +AS="$AS" - mingw* | pw32*) - lt_cv_dlopen="LoadLibrary" - lt_cv_dlopen_libs= - ;; +# The name of the directory that contains temporary libtool files. +objdir=$objdir - cygwin*) - lt_cv_dlopen="dlopen" - lt_cv_dlopen_libs= - ;; +# How to create reloadable object files. +reload_flag=$lt_reload_flag +reload_cmds=$lt_reload_cmds - darwin*) - # if libdl is installed we need to link against it - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 -$as_echo_n "checking for dlopen in -ldl... " >&6; } -if test "${ac_cv_lib_dl_dlopen+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +# How to pass a linker flag through the compiler. +wl=$lt_lt_prog_compiler_wl -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); -int -main () -{ -return dlopen (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dl_dlopen=yes -else - ac_cv_lib_dl_dlopen=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 -$as_echo "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" -else +# Object file suffix (normally "o"). +objext="$ac_objext" - lt_cv_dlopen="dyld" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes +# Old archive suffix (normally "a"). +libext="$libext" -fi +# Shared library suffix (normally ".so"). +shrext_cmds='$shrext_cmds' - ;; +# Executable file suffix (normally ""). +exeext="$exeext" - *) - ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" -if test "x$ac_cv_func_shl_load" = x""yes; then : - lt_cv_dlopen="shl_load" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 -$as_echo_n "checking for shl_load in -ldld... " >&6; } -if test "${ac_cv_lib_dld_shl_load+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +# Additional compiler flags for building library objects. +pic_flag=$lt_lt_prog_compiler_pic +pic_mode=$pic_mode -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char shl_load (); -int -main () -{ -return shl_load (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dld_shl_load=yes -else - ac_cv_lib_dld_shl_load=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 -$as_echo "$ac_cv_lib_dld_shl_load" >&6; } -if test "x$ac_cv_lib_dld_shl_load" = x""yes; then : - lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld" -else - ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" -if test "x$ac_cv_func_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 -$as_echo_n "checking for dlopen in -ldl... " >&6; } -if test "${ac_cv_lib_dl_dlopen+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +# What is the maximum length of a command? +max_cmd_len=$lt_cv_sys_max_cmd_len -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); -int -main () -{ -return dlopen (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dl_dlopen=yes -else - ac_cv_lib_dl_dlopen=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 -$as_echo "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 -$as_echo_n "checking for dlopen in -lsvld... " >&6; } -if test "${ac_cv_lib_svld_dlopen+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lsvld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +# Does compiler simultaneously support -c and -o options? +compiler_c_o=$lt_lt_cv_prog_compiler_c_o -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); -int -main () -{ -return dlopen (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_svld_dlopen=yes -else - ac_cv_lib_svld_dlopen=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 -$as_echo "$ac_cv_lib_svld_dlopen" >&6; } -if test "x$ac_cv_lib_svld_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 -$as_echo_n "checking for dld_link in -ldld... " >&6; } -if test "${ac_cv_lib_dld_dld_link+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +# Must we lock files when doing compilation? +need_locks=$lt_need_locks -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dld_link (); -int -main () -{ -return dld_link (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dld_dld_link=yes -else - ac_cv_lib_dld_dld_link=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 -$as_echo "$ac_cv_lib_dld_dld_link" >&6; } -if test "x$ac_cv_lib_dld_dld_link" = x""yes; then : - lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld" -fi +# Do we need the lib prefix for modules? +need_lib_prefix=$need_lib_prefix +# Do we need a version for libraries? +need_version=$need_version -fi +# Whether dlopen is supported. +dlopen_support=$enable_dlopen + +# Whether dlopen of programs is supported. +dlopen_self=$enable_dlopen_self +# Whether dlopen of statically linked programs is supported. +dlopen_self_static=$enable_dlopen_self_static -fi +# Compiler flag to prevent dynamic linking. +link_static_flag=$lt_lt_prog_compiler_static +# Compiler flag to turn off builtin functions. +no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag -fi +# Compiler flag to allow reflexive dlopens. +export_dynamic_flag_spec=$lt_export_dynamic_flag_spec +# Compiler flag to generate shared objects directly from archives. +whole_archive_flag_spec=$lt_whole_archive_flag_spec -fi +# Compiler flag to generate thread-safe objects. +thread_safe_flag_spec=$lt_thread_safe_flag_spec +# Library versioning type. +version_type=$version_type -fi +# Format of library name prefix. +libname_spec=$lt_libname_spec - ;; - esac +# List of archive names. First name is the real one, the rest are links. +# The last name is the one that the linker finds with -lNAME. +library_names_spec=$lt_library_names_spec - if test "x$lt_cv_dlopen" != xno; then - enable_dlopen=yes - else - enable_dlopen=no - fi +# The coded name of the library, if different from the real name. +soname_spec=$lt_soname_spec - case $lt_cv_dlopen in - dlopen) - save_CPPFLAGS="$CPPFLAGS" - test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" +# Commands used to build and install an old-style archive. +RANLIB=$lt_RANLIB +old_archive_cmds=$lt_old_archive_cmds +old_postinstall_cmds=$lt_old_postinstall_cmds +old_postuninstall_cmds=$lt_old_postuninstall_cmds + +# Create an old-style archive from a shared archive. +old_archive_from_new_cmds=$lt_old_archive_from_new_cmds + +# Create a temporary old-style archive to link instead of a shared archive. +old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds + +# Commands used to build and install a shared archive. +archive_cmds=$lt_archive_cmds +archive_expsym_cmds=$lt_archive_expsym_cmds +postinstall_cmds=$lt_postinstall_cmds +postuninstall_cmds=$lt_postuninstall_cmds + +# Commands used to build a loadable module (assumed same as above if empty) +module_cmds=$lt_module_cmds +module_expsym_cmds=$lt_module_expsym_cmds + +# Commands to strip libraries. +old_striplib=$lt_old_striplib +striplib=$lt_striplib + +# Dependencies to place before the objects being linked to create a +# shared library. +predep_objects=$lt_predep_objects - save_LDFLAGS="$LDFLAGS" - eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" +# Dependencies to place after the objects being linked to create a +# shared library. +postdep_objects=$lt_postdep_objects - save_LIBS="$LIBS" - LIBS="$lt_cv_dlopen_libs $LIBS" +# Dependencies to place before the objects being linked to create a +# shared library. +predeps=$lt_predeps - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 -$as_echo_n "checking whether a program can dlopen itself... " >&6; } -if test "${lt_cv_dlopen_self+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - lt_cv_dlopen_self=cross -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext < -#endif +# The library search path used internally by the compiler when linking +# a shared library. +compiler_lib_search_path=$lt_compiler_lib_search_path -#include +# Method to check whether dependent libraries are shared objects. +deplibs_check_method=$lt_deplibs_check_method -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif +# Command to use when deplibs_check_method == file_magic. +file_magic_cmd=$lt_file_magic_cmd -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif +# Flag that allows shared libraries with undefined symbols to be built. +allow_undefined_flag=$lt_allow_undefined_flag -#ifdef __cplusplus -extern "C" void exit (int); -#endif +# Flag that forces no undefined symbols. +no_undefined_flag=$lt_no_undefined_flag -void fnord() { int i=42;} -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; +# Commands used to finish a libtool library installation in a directory. +finish_cmds=$lt_finish_cmds - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - /* dlclose (self); */ - } +# Same as above, but a single script fragment to be evaled but not shown. +finish_eval=$lt_finish_eval - exit (status); -} -EOF - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&5 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; - x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; - x$lt_unknown|x*) lt_cv_dlopen_self=no ;; - esac - else : - # compilation failed - lt_cv_dlopen_self=no - fi -fi -rm -fr conftest* +# Take the output of nm and produce a listing of raw symbols and C names. +global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe +# Transform the output of nm in a proper C declaration +global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 -$as_echo "$lt_cv_dlopen_self" >&6; } +# Transform the output of nm in a C name address pair +global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address - if test "x$lt_cv_dlopen_self" = xyes; then - LDFLAGS="$LDFLAGS $link_static_flag" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 -$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } -if test "${lt_cv_dlopen_self_static+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - lt_cv_dlopen_self_static=cross -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext < -#endif +# This is the shared library path variable. +shlibpath_var=$shlibpath_var -#include +# Is shlibpath searched before the hard-coded library search path? +shlibpath_overrides_runpath=$shlibpath_overrides_runpath -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif +# How to hardcode a shared library path into an executable. +hardcode_action=$hardcode_action -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif +# Whether we should hardcode library paths into libraries. +hardcode_into_libs=$hardcode_into_libs -#ifdef __cplusplus -extern "C" void exit (int); -#endif +# Flag to hardcode \$libdir into a binary during linking. +# This must work even if \$libdir does not exist. +hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec -void fnord() { int i=42;} -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; +# If ld is used when linking, flag to hardcode \$libdir into +# a binary during linking. This must work even if \$libdir does +# not exist. +hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - /* dlclose (self); */ - } +# Whether we need a single -rpath flag with a separated argument. +hardcode_libdir_separator=$lt_hardcode_libdir_separator - exit (status); -} -EOF - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&5 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; - x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; - x$lt_unknown|x*) lt_cv_dlopen_self_static=no ;; - esac - else : - # compilation failed - lt_cv_dlopen_self_static=no - fi -fi -rm -fr conftest* +# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the +# resulting binary. +hardcode_direct=$hardcode_direct +# Set to yes if using the -LDIR flag during linking hardcodes DIR into the +# resulting binary. +hardcode_minus_L=$hardcode_minus_L -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 -$as_echo "$lt_cv_dlopen_self_static" >&6; } - fi +# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into +# the resulting binary. +hardcode_shlibpath_var=$hardcode_shlibpath_var - CPPFLAGS="$save_CPPFLAGS" - LDFLAGS="$save_LDFLAGS" - LIBS="$save_LIBS" - ;; - esac +# Set to yes if building a shared library automatically hardcodes DIR into the library +# and all subsequent libraries and executables linked against it. +hardcode_automatic=$hardcode_automatic - case $lt_cv_dlopen_self in - yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; - *) enable_dlopen_self=unknown ;; - esac +# Variables whose values should be saved in libtool wrapper scripts and +# restored at relink time. +variables_saved_for_relink="$variables_saved_for_relink" - case $lt_cv_dlopen_self_static in - yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; - *) enable_dlopen_self_static=unknown ;; - esac -fi +# Whether libtool must link a program against all its dependency libraries. +link_all_deplibs=$link_all_deplibs +# Compile-time system search path for libraries +sys_lib_search_path_spec=$lt_sys_lib_search_path_spec -# The else clause should only fire when bootstrapping the -# libtool distribution, otherwise you forgot to ship ltmain.sh -# with your package, and you will get complaints that there are -# no rules to generate ltmain.sh. -if test -f "$ltmain"; then - # See if we are running on zsh, and set the options which allow our commands through - # without removal of \ escapes. - if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST - fi - # Now quote all the things that may contain metacharacters while being - # careful not to overquote the AC_SUBSTed values. We take copies of the - # variables and quote the copies for generation of the libtool script. - for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \ - SED SHELL STRIP \ - libname_spec library_names_spec soname_spec extract_expsyms_cmds \ - old_striplib striplib file_magic_cmd finish_cmds finish_eval \ - deplibs_check_method reload_flag reload_cmds need_locks \ - lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ - lt_cv_sys_global_symbol_to_c_name_address \ - sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ - old_postinstall_cmds old_postuninstall_cmds \ - compiler_GCJ \ - CC_GCJ \ - LD_GCJ \ - lt_prog_compiler_wl_GCJ \ - lt_prog_compiler_pic_GCJ \ - lt_prog_compiler_static_GCJ \ - lt_prog_compiler_no_builtin_flag_GCJ \ - export_dynamic_flag_spec_GCJ \ - thread_safe_flag_spec_GCJ \ - whole_archive_flag_spec_GCJ \ - enable_shared_with_static_runtimes_GCJ \ - old_archive_cmds_GCJ \ - old_archive_from_new_cmds_GCJ \ - predep_objects_GCJ \ - postdep_objects_GCJ \ - predeps_GCJ \ - postdeps_GCJ \ - compiler_lib_search_path_GCJ \ - archive_cmds_GCJ \ - archive_expsym_cmds_GCJ \ - postinstall_cmds_GCJ \ - postuninstall_cmds_GCJ \ - old_archive_from_expsyms_cmds_GCJ \ - allow_undefined_flag_GCJ \ - no_undefined_flag_GCJ \ - export_symbols_cmds_GCJ \ - hardcode_libdir_flag_spec_GCJ \ - hardcode_libdir_flag_spec_ld_GCJ \ - hardcode_libdir_separator_GCJ \ - hardcode_automatic_GCJ \ - module_cmds_GCJ \ - module_expsym_cmds_GCJ \ - lt_cv_prog_compiler_c_o_GCJ \ - exclude_expsyms_GCJ \ - include_expsyms_GCJ; do +# Run-time system search path for libraries +sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec - case $var in - old_archive_cmds_GCJ | \ - old_archive_from_new_cmds_GCJ | \ - archive_cmds_GCJ | \ - archive_expsym_cmds_GCJ | \ - module_cmds_GCJ | \ - module_expsym_cmds_GCJ | \ - old_archive_from_expsyms_cmds_GCJ | \ - export_symbols_cmds_GCJ | \ - extract_expsyms_cmds | reload_cmds | finish_cmds | \ - postinstall_cmds | postuninstall_cmds | \ - old_postinstall_cmds | old_postuninstall_cmds | \ - sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) - # Double-quote double-evaled strings. - eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" - ;; - *) - eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" - ;; - esac - done +# Fix the shell variable \$srcfile for the compiler. +fix_srcfile_path="$fix_srcfile_path" - case $lt_echo in - *'\$0 --fallback-echo"') - lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` - ;; - esac +# Set to yes if exported symbols are required. +always_export_symbols=$always_export_symbols -cfgfile="$ofile" +# The commands to list exported symbols. +export_symbols_cmds=$lt_export_symbols_cmds - cat <<__EOF__ >> "$cfgfile" -# ### BEGIN LIBTOOL TAG CONFIG: $tagname +# The commands to extract the exported symbol list from a shared archive. +extract_expsyms_cmds=$lt_extract_expsyms_cmds -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: +# Symbols that should not be listed in the preloaded symbols. +exclude_expsyms=$lt_exclude_expsyms -# Shell to use when invoking shell scripts. -SHELL=$lt_SHELL +# Symbols that must always be exported. +include_expsyms=$lt_include_expsyms -# Whether or not to build shared libraries. -build_libtool_libs=$enable_shared +# ### END LIBTOOL CONFIG -# Whether or not to build static libraries. -build_old_libs=$enable_static +__EOF__ -# Whether or not to add -lc for building shared libraries. -build_libtool_need_lc=$archive_cmds_need_lc_GCJ -# Whether or not to disallow shared libs when runtime libs are static -allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_GCJ + case $host_os in + aix3*) + cat <<\EOF >> "$cfgfile" -# Whether or not to optimize for fast installation. -fast_install=$enable_fast_install +# AIX sometimes has problems with the GCC collect2 program. For some +# reason, if we set the COLLECT_NAMES environment variable, the problems +# vanish in a puff of smoke. +if test "X${COLLECT_NAMES+set}" != Xset; then + COLLECT_NAMES= + export COLLECT_NAMES +fi +EOF + ;; + esac -# The host system. -host_alias=$host_alias -host=$host -host_os=$host_os + # We use sed instead of cat because bash on DJGPP gets confused if + # if finds mixed CR/LF and LF-only lines. Since sed operates in + # text mode, it properly converts lines to CR/LF. This bash problem + # is reportedly fixed, but why not run on old versions too? + sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1) -# The build system. -build_alias=$build_alias -build=$build -build_os=$build_os + mv -f "$cfgfile" "$ofile" || \ + (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") + chmod +x "$ofile" -# An echo program that does not interpret backslashes. -echo=$lt_echo +else + # If there is no Makefile yet, we rely on a make rule to execute + # `config.status --recheck' to rerun these tests and create the + # libtool script then. + ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` + if test -f "$ltmain_in"; then + test -f Makefile && make "$ltmain" + fi +fi -# The archiver. -AR=$lt_AR -AR_FLAGS=$lt_AR_FLAGS -# A C compiler. -LTCC=$lt_LTCC +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu -# A language-specific compiler. -CC=$lt_compiler_GCJ +CC="$lt_save_CC" -# Is the compiler the GNU C compiler? -with_gcc=$GCC_GCJ -# An ERE matcher. -EGREP=$lt_EGREP +# Check whether --with-tags was given. +if test "${with_tags+set}" = set; then : + withval=$with_tags; tagnames="$withval" +fi -# The linker used to build libraries. -LD=$lt_LD_GCJ -# Whether we need hard or soft links. -LN_S=$lt_LN_S +if test -f "$ltmain" && test -n "$tagnames"; then + if test ! -f "${ofile}"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: output file \`$ofile' does not exist" >&5 +$as_echo "$as_me: WARNING: output file \`$ofile' does not exist" >&2;} + fi -# A BSD-compatible nm program. -NM=$lt_NM + if test -z "$LTCC"; then + eval "`$SHELL ${ofile} --config | grep '^LTCC='`" + if test -z "$LTCC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: output file \`$ofile' does not look like a libtool script" >&5 +$as_echo "$as_me: WARNING: output file \`$ofile' does not look like a libtool script" >&2;} + else + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&5 +$as_echo "$as_me: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&2;} + fi + fi -# A symbol stripping program -STRIP=$lt_STRIP + # Extract list of available tagged configurations in $ofile. + # Note that this assumes the entire list is on one line. + available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'` -# Used to examine libraries when file_magic_cmd begins "file" -MAGIC_CMD=$MAGIC_CMD + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for tagname in $tagnames; do + IFS="$lt_save_ifs" + # Check whether tagname contains only valid characters + case `$echo "X$tagname" | $Xsed -e 's:[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]::g'` in + "") ;; + *) as_fn_error "invalid tag name: $tagname" "$LINENO" 5 + ;; + esac -# Used on cygwin: DLL creation program. -DLLTOOL="$DLLTOOL" + if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null + then + as_fn_error "tag name \"$tagname\" already exists" "$LINENO" 5 + fi -# Used on cygwin: object dumper. -OBJDUMP="$OBJDUMP" + # Update the list of available tags. + if test -n "$tagname"; then + echo appending configuration tag \"$tagname\" to $ofile -# Used on cygwin: assembler. -AS="$AS" + case $tagname in + CXX) + if test -n "$CXX" && ( test "X$CXX" != "Xno" && + ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || + (test "X$CXX" != "Xg++"))) ; then + : + else + tagname="" + fi + ;; -# The name of the directory that contains temporary libtool files. -objdir=$objdir + F77) + if test -n "$F77" && test "X$F77" != "Xno"; then + : + else + tagname="" + fi + ;; -# How to create reloadable object files. -reload_flag=$lt_reload_flag -reload_cmds=$lt_reload_cmds + GCJ) + if test -n "$GCJ" && test "X$GCJ" != "Xno"; then -# How to pass a linker flag through the compiler. -wl=$lt_lt_prog_compiler_wl_GCJ -# Object file suffix (normally "o"). -objext="$ac_objext" +# Source file extension for Java test sources. +ac_ext=java + +# Object file extension for compiled Java test sources. +objext=o +objext_GCJ=$objext -# Old archive suffix (normally "a"). -libext="$libext" +# Code to be used in simple compile tests +lt_simple_compile_test_code="class foo {}\n" -# Shared library suffix (normally ".so"). -shrext_cmds='$shrext_cmds' +# Code to be used in simple link tests +lt_simple_link_test_code='public class conftest { public static void main(String[] argv) {}; }\n' -# Executable file suffix (normally ""). -exeext="$exeext" +# ltmain only uses $CC for tagged configurations so make sure $CC is set. -# Additional compiler flags for building library objects. -pic_flag=$lt_lt_prog_compiler_pic_GCJ -pic_mode=$pic_mode +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} -# What is the maximum length of a command? -max_cmd_len=$lt_cv_sys_max_cmd_len +# Allow CC to be a program name with arguments. +compiler=$CC -# Does compiler simultaneously support -c and -o options? -compiler_c_o=$lt_lt_cv_prog_compiler_c_o_GCJ -# Must we lock files when doing compilation? -need_locks=$lt_need_locks +# save warnings/boilerplate of simple test code +ac_outfile=conftest.$ac_objext +printf "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$rm conftest* -# Do we need the lib prefix for modules? -need_lib_prefix=$need_lib_prefix +ac_outfile=conftest.$ac_objext +printf "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$rm conftest* -# Do we need a version for libraries? -need_version=$need_version -# Whether dlopen is supported. -dlopen_support=$enable_dlopen +# Allow CC to be a program name with arguments. +lt_save_CC="$CC" +CC=${GCJ-"gcj"} +compiler=$CC +compiler_GCJ=$CC +for cc_temp in $compiler""; do + case $cc_temp in + compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; + distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; + \-*) ;; + *) break;; + esac +done +cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` -# Whether dlopen of programs is supported. -dlopen_self=$enable_dlopen_self -# Whether dlopen of statically linked programs is supported. -dlopen_self_static=$enable_dlopen_self_static +# GCJ did not exist at the time GCC didn't implicitly link libc in. +archive_cmds_need_lc_GCJ=no -# Compiler flag to prevent dynamic linking. -link_static_flag=$lt_lt_prog_compiler_static_GCJ +old_archive_cmds_GCJ=$old_archive_cmds -# Compiler flag to turn off builtin functions. -no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_GCJ -# Compiler flag to allow reflexive dlopens. -export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_GCJ +lt_prog_compiler_no_builtin_flag_GCJ= -# Compiler flag to generate shared objects directly from archives. -whole_archive_flag_spec=$lt_whole_archive_flag_spec_GCJ +if test "$GCC" = yes; then + lt_prog_compiler_no_builtin_flag_GCJ=' -fno-builtin' -# Compiler flag to generate thread-safe objects. -thread_safe_flag_spec=$lt_thread_safe_flag_spec_GCJ -# Library versioning type. -version_type=$version_type +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 +$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } +if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_rtti_exceptions=no + ac_outfile=conftest.$ac_objext + printf "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="-fno-rtti -fno-exceptions" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:12366: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:12370: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp + $SED '/^$/d' conftest.err >conftest.er2 + if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_rtti_exceptions=yes + fi + fi + $rm conftest* -# Format of library name prefix. -libname_spec=$lt_libname_spec +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 +$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } -# List of archive names. First name is the real one, the rest are links. -# The last name is the one that the linker finds with -lNAME. -library_names_spec=$lt_library_names_spec +if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then + lt_prog_compiler_no_builtin_flag_GCJ="$lt_prog_compiler_no_builtin_flag_GCJ -fno-rtti -fno-exceptions" +else + : +fi -# The coded name of the library, if different from the real name. -soname_spec=$lt_soname_spec +fi -# Commands used to build and install an old-style archive. -RANLIB=$lt_RANLIB -old_archive_cmds=$lt_old_archive_cmds_GCJ -old_postinstall_cmds=$lt_old_postinstall_cmds -old_postuninstall_cmds=$lt_old_postuninstall_cmds +lt_prog_compiler_wl_GCJ= +lt_prog_compiler_pic_GCJ= +lt_prog_compiler_static_GCJ= -# Create an old-style archive from a shared archive. -old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_GCJ +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; } -# Create a temporary old-style archive to link instead of a shared archive. -old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_GCJ + if test "$GCC" = yes; then + lt_prog_compiler_wl_GCJ='-Wl,' + lt_prog_compiler_static_GCJ='-static' -# Commands used to build and install a shared archive. -archive_cmds=$lt_archive_cmds_GCJ -archive_expsym_cmds=$lt_archive_expsym_cmds_GCJ -postinstall_cmds=$lt_postinstall_cmds -postuninstall_cmds=$lt_postuninstall_cmds + case $host_os in + aix*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static_GCJ='-Bstatic' + fi + ;; -# Commands used to build a loadable module (assumed same as above if empty) -module_cmds=$lt_module_cmds_GCJ -module_expsym_cmds=$lt_module_expsym_cmds_GCJ + amigaos*) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the `-m68020' flag to GCC prevents building anything better, + # like `-m68040'. + lt_prog_compiler_pic_GCJ='-m68020 -resident32 -malways-restore-a4' + ;; -# Commands to strip libraries. -old_striplib=$lt_old_striplib -striplib=$lt_striplib + beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; -# Dependencies to place before the objects being linked to create a -# shared library. -predep_objects=$lt_predep_objects_GCJ + mingw* | pw32* | os2*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + lt_prog_compiler_pic_GCJ='-DDLL_EXPORT' + ;; -# Dependencies to place after the objects being linked to create a -# shared library. -postdep_objects=$lt_postdep_objects_GCJ + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + lt_prog_compiler_pic_GCJ='-fno-common' + ;; -# Dependencies to place before the objects being linked to create a -# shared library. -predeps=$lt_predeps_GCJ + msdosdjgpp*) + # Just because we use GCC doesn't mean we suddenly get shared libraries + # on systems that don't support them. + lt_prog_compiler_can_build_shared_GCJ=no + enable_shared=no + ;; -# Dependencies to place after the objects being linked to create a -# shared library. -postdeps=$lt_postdeps_GCJ + sysv4*MP*) + if test -d /usr/nec; then + lt_prog_compiler_pic_GCJ=-Kconform_pic + fi + ;; -# The library search path used internally by the compiler when linking -# a shared library. -compiler_lib_search_path=$lt_compiler_lib_search_path_GCJ + hpux*) + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic_GCJ='-fPIC' + ;; + esac + ;; -# Method to check whether dependent libraries are shared objects. -deplibs_check_method=$lt_deplibs_check_method + *) + lt_prog_compiler_pic_GCJ='-fPIC' + ;; + esac + else + # PORTME Check for flag to pass linker flags through the system compiler. + case $host_os in + aix*) + lt_prog_compiler_wl_GCJ='-Wl,' + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static_GCJ='-Bstatic' + else + lt_prog_compiler_static_GCJ='-bnso -bI:/lib/syscalls.exp' + fi + ;; + darwin*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + case $cc_basename in + xlc*) + lt_prog_compiler_pic_GCJ='-qnocommon' + lt_prog_compiler_wl_GCJ='-Wl,' + ;; + esac + ;; -# Command to use when deplibs_check_method == file_magic. -file_magic_cmd=$lt_file_magic_cmd + mingw* | pw32* | os2*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + lt_prog_compiler_pic_GCJ='-DDLL_EXPORT' + ;; -# Flag that allows shared libraries with undefined symbols to be built. -allow_undefined_flag=$lt_allow_undefined_flag_GCJ + hpux9* | hpux10* | hpux11*) + lt_prog_compiler_wl_GCJ='-Wl,' + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic_GCJ='+Z' + ;; + esac + # Is there a better lt_prog_compiler_static that works with the bundled CC? + lt_prog_compiler_static_GCJ='${wl}-a ${wl}archive' + ;; -# Flag that forces no undefined symbols. -no_undefined_flag=$lt_no_undefined_flag_GCJ + irix5* | irix6* | nonstopux*) + lt_prog_compiler_wl_GCJ='-Wl,' + # PIC (with -KPIC) is the default. + lt_prog_compiler_static_GCJ='-non_shared' + ;; -# Commands used to finish a libtool library installation in a directory. -finish_cmds=$lt_finish_cmds + newsos6) + lt_prog_compiler_pic_GCJ='-KPIC' + lt_prog_compiler_static_GCJ='-Bstatic' + ;; -# Same as above, but a single script fragment to be evaled but not shown. -finish_eval=$lt_finish_eval + linux*) + case $cc_basename in + icc* | ecc*) + lt_prog_compiler_wl_GCJ='-Wl,' + lt_prog_compiler_pic_GCJ='-KPIC' + lt_prog_compiler_static_GCJ='-static' + ;; + pgcc* | pgf77* | pgf90* | pgf95*) + # Portland Group compilers (*not* the Pentium gcc compiler, + # which looks to be a dead project) + lt_prog_compiler_wl_GCJ='-Wl,' + lt_prog_compiler_pic_GCJ='-fpic' + lt_prog_compiler_static_GCJ='-Bstatic' + ;; + ccc*) + lt_prog_compiler_wl_GCJ='-Wl,' + # All Alpha code is PIC. + lt_prog_compiler_static_GCJ='-non_shared' + ;; + esac + ;; -# Take the output of nm and produce a listing of raw symbols and C names. -global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe + osf3* | osf4* | osf5*) + lt_prog_compiler_wl_GCJ='-Wl,' + # All OSF/1 code is PIC. + lt_prog_compiler_static_GCJ='-non_shared' + ;; -# Transform the output of nm in a proper C declaration -global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl + sco3.2v5*) + lt_prog_compiler_pic_GCJ='-Kpic' + lt_prog_compiler_static_GCJ='-dn' + ;; -# Transform the output of nm in a C name address pair -global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address + solaris*) + lt_prog_compiler_pic_GCJ='-KPIC' + lt_prog_compiler_static_GCJ='-Bstatic' + case $cc_basename in + f77* | f90* | f95*) + lt_prog_compiler_wl_GCJ='-Qoption ld ';; + *) + lt_prog_compiler_wl_GCJ='-Wl,';; + esac + ;; -# This is the shared library runtime path variable. -runpath_var=$runpath_var + sunos4*) + lt_prog_compiler_wl_GCJ='-Qoption ld ' + lt_prog_compiler_pic_GCJ='-PIC' + lt_prog_compiler_static_GCJ='-Bstatic' + ;; -# This is the shared library path variable. -shlibpath_var=$shlibpath_var + sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) + lt_prog_compiler_wl_GCJ='-Wl,' + lt_prog_compiler_pic_GCJ='-KPIC' + lt_prog_compiler_static_GCJ='-Bstatic' + ;; -# Is shlibpath searched before the hard-coded library search path? -shlibpath_overrides_runpath=$shlibpath_overrides_runpath + sysv4*MP*) + if test -d /usr/nec ;then + lt_prog_compiler_pic_GCJ='-Kconform_pic' + lt_prog_compiler_static_GCJ='-Bstatic' + fi + ;; -# How to hardcode a shared library path into an executable. -hardcode_action=$hardcode_action_GCJ + unicos*) + lt_prog_compiler_wl_GCJ='-Wl,' + lt_prog_compiler_can_build_shared_GCJ=no + ;; -# Whether we should hardcode library paths into libraries. -hardcode_into_libs=$hardcode_into_libs + uts4*) + lt_prog_compiler_pic_GCJ='-pic' + lt_prog_compiler_static_GCJ='-Bstatic' + ;; -# Flag to hardcode \$libdir into a binary during linking. -# This must work even if \$libdir does not exist. -hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_GCJ + *) + lt_prog_compiler_can_build_shared_GCJ=no + ;; + esac + fi -# If ld is used when linking, flag to hardcode \$libdir into -# a binary during linking. This must work even if \$libdir does -# not exist. -hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_GCJ +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic_GCJ" >&5 +$as_echo "$lt_prog_compiler_pic_GCJ" >&6; } -# Whether we need a single -rpath flag with a separated argument. -hardcode_libdir_separator=$lt_hardcode_libdir_separator_GCJ +# +# Check to make sure the PIC flag actually works. +# +if test -n "$lt_prog_compiler_pic_GCJ"; then -# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the -# resulting binary. -hardcode_direct=$hardcode_direct_GCJ +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic_GCJ works" >&5 +$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_GCJ works... " >&6; } +if test "${lt_prog_compiler_pic_works_GCJ+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + lt_prog_compiler_pic_works_GCJ=no + ac_outfile=conftest.$ac_objext + printf "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$lt_prog_compiler_pic_GCJ" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:12628: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:12632: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp + $SED '/^$/d' conftest.err >conftest.er2 + if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then + lt_prog_compiler_pic_works_GCJ=yes + fi + fi + $rm conftest* -# Set to yes if using the -LDIR flag during linking hardcodes DIR into the -# resulting binary. -hardcode_minus_L=$hardcode_minus_L_GCJ +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic_works_GCJ" >&5 +$as_echo "$lt_prog_compiler_pic_works_GCJ" >&6; } -# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into -# the resulting binary. -hardcode_shlibpath_var=$hardcode_shlibpath_var_GCJ +if test x"$lt_prog_compiler_pic_works_GCJ" = xyes; then + case $lt_prog_compiler_pic_GCJ in + "" | " "*) ;; + *) lt_prog_compiler_pic_GCJ=" $lt_prog_compiler_pic_GCJ" ;; + esac +else + lt_prog_compiler_pic_GCJ= + lt_prog_compiler_can_build_shared_GCJ=no +fi -# Set to yes if building a shared library automatically hardcodes DIR into the library -# and all subsequent libraries and executables linked against it. -hardcode_automatic=$hardcode_automatic_GCJ +fi +case $host_os in + # For platforms which do not support PIC, -DPIC is meaningless: + *djgpp*) + lt_prog_compiler_pic_GCJ= + ;; + *) + lt_prog_compiler_pic_GCJ="$lt_prog_compiler_pic_GCJ" + ;; +esac -# Variables whose values should be saved in libtool wrapper scripts and -# restored at relink time. -variables_saved_for_relink="$variables_saved_for_relink" +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if test "${lt_cv_prog_compiler_c_o_GCJ+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o_GCJ=no + $rm -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + printf "$lt_simple_compile_test_code" > conftest.$ac_ext -# Whether libtool must link a program against all its dependency libraries. -link_all_deplibs=$link_all_deplibs_GCJ + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:12690: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:12694: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $echo "X$_lt_compiler_boilerplate" | $Xsed > out/conftest.exp + $SED '/^$/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.err || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o_GCJ=yes + fi + fi + chmod u+w . 2>&5 + $rm conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files + $rm out/* && rmdir out + cd .. + rmdir conftest + $rm conftest* -# Compile-time system search path for libraries -sys_lib_search_path_spec=$lt_sys_lib_search_path_spec +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_GCJ" >&5 +$as_echo "$lt_cv_prog_compiler_c_o_GCJ" >&6; } -# Run-time system search path for libraries -sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec -# Fix the shell variable \$srcfile for the compiler. -fix_srcfile_path="$fix_srcfile_path_GCJ" +hard_links="nottested" +if test "$lt_cv_prog_compiler_c_o_GCJ" = no && test "$need_locks" != no; then + # do not overwrite the value of need_locks provided by the user + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 +$as_echo_n "checking if we can lock with hard links... " >&6; } + hard_links=yes + $rm conftest* + ln conftest.a conftest.b 2>/dev/null && hard_links=no + touch conftest.a + ln conftest.a conftest.b 2>&5 || hard_links=no + ln conftest.a conftest.b 2>/dev/null && hard_links=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 +$as_echo "$hard_links" >&6; } + if test "$hard_links" = no; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 +$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} + need_locks=warn + fi +else + need_locks=no +fi -# Set to yes if exported symbols are required. -always_export_symbols=$always_export_symbols_GCJ +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } -# The commands to list exported symbols. -export_symbols_cmds=$lt_export_symbols_cmds_GCJ + runpath_var= + allow_undefined_flag_GCJ= + enable_shared_with_static_runtimes_GCJ=no + archive_cmds_GCJ= + archive_expsym_cmds_GCJ= + old_archive_From_new_cmds_GCJ= + old_archive_from_expsyms_cmds_GCJ= + export_dynamic_flag_spec_GCJ= + whole_archive_flag_spec_GCJ= + thread_safe_flag_spec_GCJ= + hardcode_libdir_flag_spec_GCJ= + hardcode_libdir_flag_spec_ld_GCJ= + hardcode_libdir_separator_GCJ= + hardcode_direct_GCJ=no + hardcode_minus_L_GCJ=no + hardcode_shlibpath_var_GCJ=unsupported + link_all_deplibs_GCJ=unknown + hardcode_automatic_GCJ=no + module_cmds_GCJ= + module_expsym_cmds_GCJ= + always_export_symbols_GCJ=no + export_symbols_cmds_GCJ='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + # include_expsyms should be a list of space-separated symbols to be *always* + # included in the symbol list + include_expsyms_GCJ= + # exclude_expsyms can be an extended regexp of symbols to exclude + # it will be wrapped by ` (' and `)$', so one must not match beginning or + # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', + # as well as any symbol that contains `d'. + exclude_expsyms_GCJ="_GLOBAL_OFFSET_TABLE_" + # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out + # platforms (ab)use it in PIC code, but their linkers get confused if + # the symbol is explicitly referenced. Since portable code cannot + # rely on this symbol name, it's probably fine to never include it in + # preloaded symbol tables. + extract_expsyms_cmds= + # Just being paranoid about ensuring that cc_basename is set. + for cc_temp in $compiler""; do + case $cc_temp in + compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; + distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; + \-*) ;; + *) break;; + esac +done +cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` -# The commands to extract the exported symbol list from a shared archive. -extract_expsyms_cmds=$lt_extract_expsyms_cmds + case $host_os in + cygwin* | mingw* | pw32*) + # FIXME: the MSVC++ port hasn't been tested in a loooong time + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + if test "$GCC" != yes; then + with_gnu_ld=no + fi + ;; + openbsd*) + with_gnu_ld=no + ;; + esac -# Symbols that should not be listed in the preloaded symbols. -exclude_expsyms=$lt_exclude_expsyms_GCJ + ld_shlibs_GCJ=yes + if test "$with_gnu_ld" = yes; then + # If archive_cmds runs LD, not CC, wlarc should be empty + wlarc='${wl}' -# Symbols that must always be exported. -include_expsyms=$lt_include_expsyms_GCJ + # Set some defaults for GNU ld with shared library support. These + # are reset later if shared libraries are not supported. Putting them + # here allows them to be overridden if necessary. + runpath_var=LD_RUN_PATH + hardcode_libdir_flag_spec_GCJ='${wl}--rpath ${wl}$libdir' + export_dynamic_flag_spec_GCJ='${wl}--export-dynamic' + # ancient GNU ld didn't support --whole-archive et. al. + if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then + whole_archive_flag_spec_GCJ="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + else + whole_archive_flag_spec_GCJ= + fi + supports_anon_versioning=no + case `$LD -v 2>/dev/null` in + *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 + *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... + *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... + *\ 2.11.*) ;; # other 2.11 versions + *) supports_anon_versioning=yes ;; + esac -# ### END LIBTOOL TAG CONFIG: $tagname + # See if GNU ld supports shared libraries. + case $host_os in + aix3* | aix4* | aix5*) + # On AIX/PPC, the GNU linker is very broken + if test "$host_cpu" != ia64; then + ld_shlibs_GCJ=no + cat <&2 -__EOF__ +*** Warning: the GNU linker, at least up to release 2.9.1, is reported +*** to be unable to reliably create shared libraries on AIX. +*** Therefore, libtool is disabling shared libraries support. If you +*** really care for shared libraries, you may want to modify your PATH +*** so that a non-GNU linker is found, and then restart. +EOF + fi + ;; -else - # If there is no Makefile yet, we rely on a make rule to execute - # `config.status --recheck' to rerun these tests and create the - # libtool script then. - ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` - if test -f "$ltmain_in"; then - test -f Makefile && make "$ltmain" - fi -fi + amigaos*) + archive_cmds_GCJ='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + hardcode_libdir_flag_spec_GCJ='-L$libdir' + hardcode_minus_L_GCJ=yes + # Samuel A. Falvo II reports + # that the semantics of dynamic libraries on AmigaOS, at least up + # to version 4, is to share data among multiple programs linked + # with the same dynamic library. Since this doesn't match the + # behavior of shared libraries on other platforms, we can't use + # them. + ld_shlibs_GCJ=no + ;; -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu + beos*) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + allow_undefined_flag_GCJ=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + archive_cmds_GCJ='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + else + ld_shlibs_GCJ=no + fi + ;; -CC="$lt_save_CC" + cygwin* | mingw* | pw32*) + # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, GCJ) is actually meaningless, + # as there is no search path for DLLs. + hardcode_libdir_flag_spec_GCJ='-L$libdir' + allow_undefined_flag_GCJ=unsupported + always_export_symbols_GCJ=no + enable_shared_with_static_runtimes_GCJ=yes + export_symbols_cmds_GCJ='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS] /s/.* \([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW] /s/.* //'\'' | sort | uniq > $export_symbols' + if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then + archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' + # If the export-symbols file already is a .def file (1st line + # is EXPORTS), use it as is; otherwise, prepend... + archive_expsym_cmds_GCJ='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + cp $export_symbols $output_objdir/$soname.def; else - tagname="" - fi - ;; + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' + else + ld_shlibs_GCJ=no + fi + ;; - RC) + linux*) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + tmp_addflag= + case $cc_basename,$host_cpu in + pgcc*) # Portland Group C compiler + whole_archive_flag_spec_GCJ='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag' + ;; + pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers + whole_archive_flag_spec_GCJ='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag -Mnomain' ;; + ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 + tmp_addflag=' -i_dynamic' ;; + efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 + tmp_addflag=' -i_dynamic -nofor_main' ;; + ifc* | ifort*) # Intel Fortran compiler + tmp_addflag=' -nofor_main' ;; + esac + archive_cmds_GCJ='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + if test $supports_anon_versioning = yes; then + archive_expsym_cmds_GCJ='$echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + $echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + fi + else + ld_shlibs_GCJ=no + fi + ;; -# Source file extension for RC test sources. -ac_ext=rc + netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then + archive_cmds_GCJ='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' + wlarc= + else + archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + fi + ;; -# Object file extension for compiled RC test sources. -objext=o -objext_RC=$objext + solaris* | sysv5*) + if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then + ld_shlibs_GCJ=no + cat <&2 -# Code to be used in simple compile tests -lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }\n' +*** Warning: The releases 2.8.* of the GNU linker cannot reliably +*** create shared libraries on Solaris systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.9.1 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. -# Code to be used in simple link tests -lt_simple_link_test_code="$lt_simple_compile_test_code" +EOF + elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs_GCJ=no + fi + ;; -# ltmain only uses $CC for tagged configurations so make sure $CC is set. + sunos4*) + archive_cmds_GCJ='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' + wlarc= + hardcode_direct_GCJ=yes + hardcode_shlibpath_var_GCJ=no + ;; -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} + *) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs_GCJ=no + fi + ;; + esac -# Allow CC to be a program name with arguments. -compiler=$CC + if test "$ld_shlibs_GCJ" = no; then + runpath_var= + hardcode_libdir_flag_spec_GCJ= + export_dynamic_flag_spec_GCJ= + whole_archive_flag_spec_GCJ= + fi + else + # PORTME fill in a description of your system's linker (not GNU ld) + case $host_os in + aix3*) + allow_undefined_flag_GCJ=unsupported + always_export_symbols_GCJ=yes + archive_expsym_cmds_GCJ='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' + # Note: this linker hardcodes the directories in LIBPATH if there + # are no directories specified by -L. + hardcode_minus_L_GCJ=yes + if test "$GCC" = yes && test -z "$link_static_flag"; then + # Neither direct hardcoding nor static linking is supported with a + # broken collect2. + hardcode_direct_GCJ=unsupported + fi + ;; + aix4* | aix5*) + if test "$host_cpu" = ia64; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag="" + else + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to AIX nm, but means don't demangle with GNU nm + if $NM -V 2>&1 | grep 'GNU' > /dev/null; then + export_symbols_cmds_GCJ='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' + else + export_symbols_cmds_GCJ='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' + fi + aix_use_runtimelinking=no -# save warnings/boilerplate of simple test code -ac_outfile=conftest.$ac_objext -printf "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$rm conftest* + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # need to do runtime linking. + case $host_os in aix4.[23]|aix4.[23].*|aix5*) + for ld_flag in $LDFLAGS; do + if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then + aix_use_runtimelinking=yes + break + fi + done + esac -ac_outfile=conftest.$ac_objext -printf "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$rm conftest* + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. -# Allow CC to be a program name with arguments. -lt_save_CC="$CC" -CC=${RC-"windres"} -compiler=$CC -compiler_RC=$CC -for cc_temp in $compiler""; do - case $cc_temp in - compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; - distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` + archive_cmds_GCJ='' + hardcode_direct_GCJ=yes + hardcode_libdir_separator_GCJ=':' + link_all_deplibs_GCJ=yes -lt_cv_prog_compiler_c_o_RC=yes + if test "$GCC" = yes; then + case $host_os in aix4.[012]|aix4.[012].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`${CC} -print-prog-name=collect2` + if test -f "$collect2name" && \ + strings "$collect2name" | grep resolve_lib_name >/dev/null + then + # We have reworked collect2 + hardcode_direct_GCJ=yes + else + # We have old collect2 + hardcode_direct_GCJ=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + hardcode_minus_L_GCJ=yes + hardcode_libdir_flag_spec_GCJ='-L$libdir' + hardcode_libdir_separator_GCJ= + fi + esac + shared_flag='-shared' + if test "$aix_use_runtimelinking" = yes; then + shared_flag="$shared_flag "'${wl}-G' + fi + else + # not using gcc + if test "$host_cpu" = ia64; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test "$aix_use_runtimelinking" = yes; then + shared_flag='${wl}-G' + else + shared_flag='${wl}-bM:SRE' + fi + fi + fi -# The else clause should only fire when bootstrapping the -# libtool distribution, otherwise you forgot to ship ltmain.sh -# with your package, and you will get complaints that there are -# no rules to generate ltmain.sh. -if test -f "$ltmain"; then - # See if we are running on zsh, and set the options which allow our commands through - # without removal of \ escapes. - if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST - fi - # Now quote all the things that may contain metacharacters while being - # careful not to overquote the AC_SUBSTed values. We take copies of the - # variables and quote the copies for generation of the libtool script. - for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \ - SED SHELL STRIP \ - libname_spec library_names_spec soname_spec extract_expsyms_cmds \ - old_striplib striplib file_magic_cmd finish_cmds finish_eval \ - deplibs_check_method reload_flag reload_cmds need_locks \ - lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ - lt_cv_sys_global_symbol_to_c_name_address \ - sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ - old_postinstall_cmds old_postuninstall_cmds \ - compiler_RC \ - CC_RC \ - LD_RC \ - lt_prog_compiler_wl_RC \ - lt_prog_compiler_pic_RC \ - lt_prog_compiler_static_RC \ - lt_prog_compiler_no_builtin_flag_RC \ - export_dynamic_flag_spec_RC \ - thread_safe_flag_spec_RC \ - whole_archive_flag_spec_RC \ - enable_shared_with_static_runtimes_RC \ - old_archive_cmds_RC \ - old_archive_from_new_cmds_RC \ - predep_objects_RC \ - postdep_objects_RC \ - predeps_RC \ - postdeps_RC \ - compiler_lib_search_path_RC \ - archive_cmds_RC \ - archive_expsym_cmds_RC \ - postinstall_cmds_RC \ - postuninstall_cmds_RC \ - old_archive_from_expsyms_cmds_RC \ - allow_undefined_flag_RC \ - no_undefined_flag_RC \ - export_symbols_cmds_RC \ - hardcode_libdir_flag_spec_RC \ - hardcode_libdir_flag_spec_ld_RC \ - hardcode_libdir_separator_RC \ - hardcode_automatic_RC \ - module_cmds_RC \ - module_expsym_cmds_RC \ - lt_cv_prog_compiler_c_o_RC \ - exclude_expsyms_RC \ - include_expsyms_RC; do + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to export. + always_export_symbols_GCJ=yes + if test "$aix_use_runtimelinking" = yes; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + allow_undefined_flag_GCJ='-berok' + # Determine the default libpath from the value encoded in an empty executable. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - case $var in - old_archive_cmds_RC | \ - old_archive_from_new_cmds_RC | \ - archive_cmds_RC | \ - archive_expsym_cmds_RC | \ - module_cmds_RC | \ - module_expsym_cmds_RC | \ - old_archive_from_expsyms_cmds_RC | \ - export_symbols_cmds_RC | \ - extract_expsyms_cmds | reload_cmds | finish_cmds | \ - postinstall_cmds | postuninstall_cmds | \ - old_postinstall_cmds | old_postuninstall_cmds | \ - sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) - # Double-quote double-evaled strings. - eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" - ;; - *) - eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" - ;; - esac - done +int +main () +{ - case $lt_echo in - *'\$0 --fallback-echo"') - lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` - ;; - esac + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : -cfgfile="$ofile" +aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } +}'` +# Check for a 64-bit object if we didn't find anything. +if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } +}'`; fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi - cat <<__EOF__ >> "$cfgfile" -# ### BEGIN LIBTOOL TAG CONFIG: $tagname + hardcode_libdir_flag_spec_GCJ='${wl}-blibpath:$libdir:'"$aix_libpath" + archive_expsym_cmds_GCJ="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag" + else + if test "$host_cpu" = ia64; then + hardcode_libdir_flag_spec_GCJ='${wl}-R $libdir:/usr/lib:/lib' + allow_undefined_flag_GCJ="-z nodefs" + archive_expsym_cmds_GCJ="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an empty executable. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: +int +main () +{ -# Shell to use when invoking shell scripts. -SHELL=$lt_SHELL + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : -# Whether or not to build shared libraries. -build_libtool_libs=$enable_shared +aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } +}'` +# Check for a 64-bit object if we didn't find anything. +if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } +}'`; fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi -# Whether or not to build static libraries. -build_old_libs=$enable_static + hardcode_libdir_flag_spec_GCJ='${wl}-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + no_undefined_flag_GCJ=' ${wl}-bernotok' + allow_undefined_flag_GCJ=' ${wl}-berok' + # -bexpall does not export symbols beginning with underscore (_) + always_export_symbols_GCJ=yes + # Exported symbols can be pulled into shared objects from archives + whole_archive_flag_spec_GCJ=' ' + archive_cmds_need_lc_GCJ=yes + # This is similar to how AIX traditionally builds its shared libraries. + archive_expsym_cmds_GCJ="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' + fi + fi + ;; -# Whether or not to add -lc for building shared libraries. -build_libtool_need_lc=$archive_cmds_need_lc_RC + amigaos*) + archive_cmds_GCJ='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + hardcode_libdir_flag_spec_GCJ='-L$libdir' + hardcode_minus_L_GCJ=yes + # see comment about different semantics on the GNU ld section + ld_shlibs_GCJ=no + ;; -# Whether or not to disallow shared libs when runtime libs are static -allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_RC + bsdi[45]*) + export_dynamic_flag_spec_GCJ=-rdynamic + ;; -# Whether or not to optimize for fast installation. -fast_install=$enable_fast_install + cygwin* | mingw* | pw32*) + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + hardcode_libdir_flag_spec_GCJ=' ' + allow_undefined_flag_GCJ=unsupported + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + archive_cmds_GCJ='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' + # The linker will automatically build a .lib file if we build a DLL. + old_archive_From_new_cmds_GCJ='true' + # FIXME: Should let the user specify the lib program. + old_archive_cmds_GCJ='lib /OUT:$oldlib$oldobjs$old_deplibs' + fix_srcfile_path_GCJ='`cygpath -w "$srcfile"`' + enable_shared_with_static_runtimes_GCJ=yes + ;; -# The host system. -host_alias=$host_alias -host=$host -host_os=$host_os + darwin* | rhapsody*) + case $host_os in + rhapsody* | darwin1.[012]) + allow_undefined_flag_GCJ='${wl}-undefined ${wl}suppress' + ;; + *) # Darwin 1.3 on + if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then + allow_undefined_flag_GCJ='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' + else + case ${MACOSX_DEPLOYMENT_TARGET} in + 10.[012]) + allow_undefined_flag_GCJ='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' + ;; + 10.*) + allow_undefined_flag_GCJ='${wl}-undefined ${wl}dynamic_lookup' + ;; + esac + fi + ;; + esac + archive_cmds_need_lc_GCJ=no + hardcode_direct_GCJ=no + hardcode_automatic_GCJ=yes + hardcode_shlibpath_var_GCJ=unsupported + whole_archive_flag_spec_GCJ='' + link_all_deplibs_GCJ=yes + if test "$GCC" = yes ; then + output_verbose_link_cmd='echo' + archive_cmds_GCJ='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' + module_cmds_GCJ='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' + # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds + archive_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' + module_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' + else + case $cc_basename in + xlc*) + output_verbose_link_cmd='echo' + archive_cmds_GCJ='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring' + module_cmds_GCJ='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' + # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds + archive_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' + module_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' + ;; + *) + ld_shlibs_GCJ=no + ;; + esac + fi + ;; -# The build system. -build_alias=$build_alias -build=$build -build_os=$build_os + dgux*) + archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec_GCJ='-L$libdir' + hardcode_shlibpath_var_GCJ=no + ;; -# An echo program that does not interpret backslashes. -echo=$lt_echo + freebsd1*) + ld_shlibs_GCJ=no + ;; -# The archiver. -AR=$lt_AR -AR_FLAGS=$lt_AR_FLAGS + # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor + # support. Future versions do this automatically, but an explicit c++rt0.o + # does not break anything, and helps significantly (at the cost of a little + # extra space). + freebsd2.2*) + archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' + hardcode_libdir_flag_spec_GCJ='-R$libdir' + hardcode_direct_GCJ=yes + hardcode_shlibpath_var_GCJ=no + ;; -# A C compiler. -LTCC=$lt_LTCC + # Unfortunately, older versions of FreeBSD 2 do not have this feature. + freebsd2*) + archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct_GCJ=yes + hardcode_minus_L_GCJ=yes + hardcode_shlibpath_var_GCJ=no + ;; -# A language-specific compiler. -CC=$lt_compiler_RC + # FreeBSD 3 and greater uses gcc -shared to do shared libraries. + freebsd* | kfreebsd*-gnu | dragonfly*) + archive_cmds_GCJ='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec_GCJ='-R$libdir' + hardcode_direct_GCJ=yes + hardcode_shlibpath_var_GCJ=no + ;; -# Is the compiler the GNU C compiler? -with_gcc=$GCC_RC + hpux9*) + if test "$GCC" = yes; then + archive_cmds_GCJ='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + else + archive_cmds_GCJ='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + fi + hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' + hardcode_libdir_separator_GCJ=: + hardcode_direct_GCJ=yes -# An ERE matcher. -EGREP=$lt_EGREP + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L_GCJ=yes + export_dynamic_flag_spec_GCJ='${wl}-E' + ;; -# The linker used to build libraries. -LD=$lt_LD_RC + hpux10* | hpux11*) + if test "$GCC" = yes -a "$with_gnu_ld" = no; then + case $host_cpu in + hppa*64*|ia64*) + archive_cmds_GCJ='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + archive_cmds_GCJ='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + else + case $host_cpu in + hppa*64*|ia64*) + archive_cmds_GCJ='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags' + ;; + *) + archive_cmds_GCJ='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' + ;; + esac + fi + if test "$with_gnu_ld" = no; then + case $host_cpu in + hppa*64*) + hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' + hardcode_libdir_flag_spec_ld_GCJ='+b $libdir' + hardcode_libdir_separator_GCJ=: + hardcode_direct_GCJ=no + hardcode_shlibpath_var_GCJ=no + ;; + ia64*) + hardcode_libdir_flag_spec_GCJ='-L$libdir' + hardcode_direct_GCJ=no + hardcode_shlibpath_var_GCJ=no -# Whether we need hard or soft links. -LN_S=$lt_LN_S + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L_GCJ=yes + ;; + *) + hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' + hardcode_libdir_separator_GCJ=: + hardcode_direct_GCJ=yes + export_dynamic_flag_spec_GCJ='${wl}-E' -# A BSD-compatible nm program. -NM=$lt_NM + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L_GCJ=yes + ;; + esac + fi + ;; -# A symbol stripping program -STRIP=$lt_STRIP + irix5* | irix6* | nonstopux*) + if test "$GCC" = yes; then + archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + archive_cmds_GCJ='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + hardcode_libdir_flag_spec_ld_GCJ='-rpath $libdir' + fi + hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator_GCJ=: + link_all_deplibs_GCJ=yes + ;; -# Used to examine libraries when file_magic_cmd begins "file" -MAGIC_CMD=$MAGIC_CMD + netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then + archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out + else + archive_cmds_GCJ='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF + fi + hardcode_libdir_flag_spec_GCJ='-R$libdir' + hardcode_direct_GCJ=yes + hardcode_shlibpath_var_GCJ=no + ;; -# Used on cygwin: DLL creation program. -DLLTOOL="$DLLTOOL" + newsos6) + archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct_GCJ=yes + hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator_GCJ=: + hardcode_shlibpath_var_GCJ=no + ;; -# Used on cygwin: object dumper. -OBJDUMP="$OBJDUMP" + openbsd*) + hardcode_direct_GCJ=yes + hardcode_shlibpath_var_GCJ=no + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + archive_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' + hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir' + export_dynamic_flag_spec_GCJ='${wl}-E' + else + case $host_os in + openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) + archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec_GCJ='-R$libdir' + ;; + *) + archive_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir' + ;; + esac + fi + ;; -# Used on cygwin: assembler. -AS="$AS" + os2*) + hardcode_libdir_flag_spec_GCJ='-L$libdir' + hardcode_minus_L_GCJ=yes + allow_undefined_flag_GCJ=unsupported + archive_cmds_GCJ='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' + old_archive_From_new_cmds_GCJ='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' + ;; -# The name of the directory that contains temporary libtool files. -objdir=$objdir + osf3*) + if test "$GCC" = yes; then + allow_undefined_flag_GCJ=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds_GCJ='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + allow_undefined_flag_GCJ=' -expect_unresolved \*' + archive_cmds_GCJ='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + fi + hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator_GCJ=: + ;; -# How to create reloadable object files. -reload_flag=$lt_reload_flag -reload_cmds=$lt_reload_cmds + osf4* | osf5*) # as osf3* with the addition of -msym flag + if test "$GCC" = yes; then + allow_undefined_flag_GCJ=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds_GCJ='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' + else + allow_undefined_flag_GCJ=' -expect_unresolved \*' + archive_cmds_GCJ='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + archive_expsym_cmds_GCJ='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ + $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' -# How to pass a linker flag through the compiler. -wl=$lt_lt_prog_compiler_wl_RC + # Both c and cxx compiler support -rpath directly + hardcode_libdir_flag_spec_GCJ='-rpath $libdir' + fi + hardcode_libdir_separator_GCJ=: + ;; -# Object file suffix (normally "o"). -objext="$ac_objext" + sco3.2v5*) + archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var_GCJ=no + export_dynamic_flag_spec_GCJ='${wl}-Bexport' + runpath_var=LD_RUN_PATH + hardcode_runpath_var=yes + ;; -# Old archive suffix (normally "a"). -libext="$libext" + solaris*) + no_undefined_flag_GCJ=' -z text' + if test "$GCC" = yes; then + wlarc='${wl}' + archive_cmds_GCJ='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_GCJ='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ + $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' + else + wlarc='' + archive_cmds_GCJ='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' + archive_expsym_cmds_GCJ='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ + $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' + fi + hardcode_libdir_flag_spec_GCJ='-R$libdir' + hardcode_shlibpath_var_GCJ=no + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; + *) + # The compiler driver will combine linker options so we + # cannot just pass the convience library names through + # without $wl, iff we do not link with $LD. + # Luckily, gcc supports the same syntax we need for Sun Studio. + # Supported since Solaris 2.6 (maybe 2.5.1?) + case $wlarc in + '') + whole_archive_flag_spec_GCJ='-z allextract$convenience -z defaultextract' ;; + *) + whole_archive_flag_spec_GCJ='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract' ;; + esac ;; + esac + link_all_deplibs_GCJ=yes + ;; -# Shared library suffix (normally ".so"). -shrext_cmds='$shrext_cmds' + sunos4*) + if test "x$host_vendor" = xsequent; then + # Use $CC to link under sequent, because it throws in some extra .o + # files that make .init and .fini sections work. + archive_cmds_GCJ='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds_GCJ='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' + fi + hardcode_libdir_flag_spec_GCJ='-L$libdir' + hardcode_direct_GCJ=yes + hardcode_minus_L_GCJ=yes + hardcode_shlibpath_var_GCJ=no + ;; -# Executable file suffix (normally ""). -exeext="$exeext" + sysv4) + case $host_vendor in + sni) + archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct_GCJ=yes # is this really true??? + ;; + siemens) + ## LD is ld it makes a PLAMLIB + ## CC just makes a GrossModule. + archive_cmds_GCJ='$LD -G -o $lib $libobjs $deplibs $linker_flags' + reload_cmds_GCJ='$CC -r -o $output$reload_objs' + hardcode_direct_GCJ=no + ;; + motorola) + archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct_GCJ=no #Motorola manual says yes, but my tests say they lie + ;; + esac + runpath_var='LD_RUN_PATH' + hardcode_shlibpath_var_GCJ=no + ;; -# Additional compiler flags for building library objects. -pic_flag=$lt_lt_prog_compiler_pic_RC -pic_mode=$pic_mode + sysv4.3*) + archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var_GCJ=no + export_dynamic_flag_spec_GCJ='-Bexport' + ;; -# What is the maximum length of a command? -max_cmd_len=$lt_cv_sys_max_cmd_len + sysv4*MP*) + if test -d /usr/nec; then + archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var_GCJ=no + runpath_var=LD_RUN_PATH + hardcode_runpath_var=yes + ld_shlibs_GCJ=yes + fi + ;; -# Does compiler simultaneously support -c and -o options? -compiler_c_o=$lt_lt_cv_prog_compiler_c_o_RC + sysv4.2uw2*) + archive_cmds_GCJ='$LD -G -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct_GCJ=yes + hardcode_minus_L_GCJ=no + hardcode_shlibpath_var_GCJ=no + hardcode_runpath_var=yes + runpath_var=LD_RUN_PATH + ;; -# Must we lock files when doing compilation? -need_locks=$lt_need_locks + sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7*) + no_undefined_flag_GCJ='${wl}-z ${wl}text' + if test "$GCC" = yes; then + archive_cmds_GCJ='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds_GCJ='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + runpath_var='LD_RUN_PATH' + hardcode_shlibpath_var_GCJ=no + ;; -# Do we need the lib prefix for modules? -need_lib_prefix=$need_lib_prefix + sysv5*) + no_undefined_flag_GCJ=' -z text' + # $CC -shared without GNU ld will not create a library from C++ + # object files and a static libstdc++, better avoid it by now + archive_cmds_GCJ='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' + archive_expsym_cmds_GCJ='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ + $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' + hardcode_libdir_flag_spec_GCJ= + hardcode_shlibpath_var_GCJ=no + runpath_var='LD_RUN_PATH' + ;; -# Do we need a version for libraries? -need_version=$need_version + uts4*) + archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec_GCJ='-L$libdir' + hardcode_shlibpath_var_GCJ=no + ;; + + *) + ld_shlibs_GCJ=no + ;; + esac + fi -# Whether dlopen is supported. -dlopen_support=$enable_dlopen +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_GCJ" >&5 +$as_echo "$ld_shlibs_GCJ" >&6; } +test "$ld_shlibs_GCJ" = no && can_build_shared=no -# Whether dlopen of programs is supported. -dlopen_self=$enable_dlopen_self +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" +if test "$GCC" = yes; then + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" +fi -# Whether dlopen of statically linked programs is supported. -dlopen_self_static=$enable_dlopen_self_static +# +# Do we need to explicitly link libc? +# +case "x$archive_cmds_need_lc_GCJ" in +x|xyes) + # Assume -lc should be added + archive_cmds_need_lc_GCJ=yes -# Compiler flag to prevent dynamic linking. -link_static_flag=$lt_lt_prog_compiler_static_RC + if test "$enable_shared" = yes && test "$GCC" = yes; then + case $archive_cmds_GCJ in + *'~'*) + # FIXME: we may have to deal with multi-command sequences. + ;; + '$CC '*) + # Test whether the compiler implicitly links with -lc since on some + # systems, -lgcc has to come before -lc. If gcc already passes -lc + # to ld, don't add -lc before -lgcc. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 +$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } + $rm conftest* + printf "$lt_simple_compile_test_code" > conftest.$ac_ext -# Compiler flag to turn off builtin functions. -no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_RC + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } 2>conftest.err; then + soname=conftest + lib=conftest + libobjs=conftest.$ac_objext + deplibs= + wl=$lt_prog_compiler_wl_GCJ + compiler_flags=-v + linker_flags=-v + verstring= + output_objdir=. + libname=conftest + lt_save_allow_undefined_flag=$allow_undefined_flag_GCJ + allow_undefined_flag_GCJ= + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_GCJ 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\""; } >&5 + (eval $archive_cmds_GCJ 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + then + archive_cmds_need_lc_GCJ=no + else + archive_cmds_need_lc_GCJ=yes + fi + allow_undefined_flag_GCJ=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $rm conftest* + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $archive_cmds_need_lc_GCJ" >&5 +$as_echo "$archive_cmds_need_lc_GCJ" >&6; } + ;; + esac + fi + ;; +esac -# Compiler flag to allow reflexive dlopens. -export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_RC +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 +$as_echo_n "checking dynamic linker characteristics... " >&6; } +library_names_spec= +libname_spec='lib$name' +soname_spec= +shrext_cmds=".so" +postinstall_cmds= +postuninstall_cmds= +finish_cmds= +finish_eval= +shlibpath_var= +shlibpath_overrides_runpath=unknown +version_type=none +dynamic_linker="$host_os ld.so" +sys_lib_dlsearch_path_spec="/lib /usr/lib" +if test "$GCC" = yes; then + sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` + if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then + # if the path contains ";" then we assume it to be the separator + # otherwise default to the standard path separator (i.e. ":") - it is + # assumed that no part of a normal pathname contains ";" but that should + # okay in the real world where ";" in dirpaths is itself problematic. + sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi +else + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" +fi +need_lib_prefix=unknown +hardcode_into_libs=no -# Compiler flag to generate shared objects directly from archives. -whole_archive_flag_spec=$lt_whole_archive_flag_spec_RC +# when you set need_version to no, make sure it does not cause -set_version +# flags to be left without arguments +need_version=unknown -# Compiler flag to generate thread-safe objects. -thread_safe_flag_spec=$lt_thread_safe_flag_spec_RC +case $host_os in +aix3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' + shlibpath_var=LIBPATH -# Library versioning type. -version_type=$version_type + # AIX 3 has no versioning support, so we append a major version to the name. + soname_spec='${libname}${release}${shared_ext}$major' + ;; -# Format of library name prefix. -libname_spec=$lt_libname_spec +aix4* | aix5*) + version_type=linux + need_lib_prefix=no + need_version=no + hardcode_into_libs=yes + if test "$host_cpu" = ia64; then + # AIX 5 supports IA64 + library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + else + # With GCC up to 2.95.x, collect2 would create an import file + # for dependence libraries. The import file would start with + # the line `#! .'. This would cause the generated library to + # depend on `.', always an invalid library. This was fixed in + # development snapshots of GCC prior to 3.0. + case $host_os in + aix4 | aix4.[01] | aix4.[01].*) + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' + echo ' yes ' + echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then + : + else + can_build_shared=no + fi + ;; + esac + # AIX (on Power*) has no versioning support, so currently we can not hardcode correct + # soname into executable. Probably we can add versioning support to + # collect2, so additional links can be useful in future. + if test "$aix_use_runtimelinking" = yes; then + # If using run time linking (on AIX 4.2 or later) use lib.so + # instead of lib.a to let people know that these are not + # typical AIX shared libraries. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + else + # We preserve .a as extension for shared libraries through AIX4.2 + # and later when we are not doing run time linking. + library_names_spec='${libname}${release}.a $libname.a' + soname_spec='${libname}${release}${shared_ext}$major' + fi + shlibpath_var=LIBPATH + fi + ;; -# List of archive names. First name is the real one, the rest are links. -# The last name is the one that the linker finds with -lNAME. -library_names_spec=$lt_library_names_spec +amigaos*) + library_names_spec='$libname.ixlibrary $libname.a' + # Create ${libname}_ixlibrary.a entries in /sys/libs. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' + ;; -# The coded name of the library, if different from the real name. -soname_spec=$lt_soname_spec +beos*) + library_names_spec='${libname}${shared_ext}' + dynamic_linker="$host_os ld.so" + shlibpath_var=LIBRARY_PATH + ;; -# Commands used to build and install an old-style archive. -RANLIB=$lt_RANLIB -old_archive_cmds=$lt_old_archive_cmds_RC -old_postinstall_cmds=$lt_old_postinstall_cmds -old_postuninstall_cmds=$lt_old_postuninstall_cmds +bsdi[45]*) + version_type=linux + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" + # the default ld.so.conf also contains /usr/contrib/lib and + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow + # libtool to hard-code these into programs + ;; -# Create an old-style archive from a shared archive. -old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_RC +cygwin* | mingw* | pw32*) + version_type=windows + shrext_cmds=".dll" + need_version=no + need_lib_prefix=no -# Create a temporary old-style archive to link instead of a shared archive. -old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_RC + case $GCC,$host_os in + yes,cygwin* | yes,mingw* | yes,pw32*) + library_names_spec='$libname.dll.a' + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $rm \$dlpath' + shlibpath_overrides_runpath=yes -# Commands used to build and install a shared archive. -archive_cmds=$lt_archive_cmds_RC -archive_expsym_cmds=$lt_archive_expsym_cmds_RC -postinstall_cmds=$lt_postinstall_cmds -postuninstall_cmds=$lt_postuninstall_cmds + case $host_os in + cygwin*) + # Cygwin DLLs use 'cyg' prefix rather than 'lib' + soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" + ;; + mingw*) + # MinGW DLLs use traditional 'lib' prefix + soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` + if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then + # It is most probably a Windows format PATH printed by + # mingw gcc, but we are running on Cygwin. Gcc prints its search + # path with ; separators, and with drive letters. We can handle the + # drive letters (cygwin fileutils understands them), so leave them, + # especially as we might pass files found there to a mingw objdump, + # which wouldn't understand a cygwinified path. Ahh. + sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + ;; + pw32*) + # pw32 DLLs use 'pw' prefix rather than 'lib' + library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + ;; + esac + ;; -# Commands used to build a loadable module (assumed same as above if empty) -module_cmds=$lt_module_cmds_RC -module_expsym_cmds=$lt_module_expsym_cmds_RC + *) + library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' + ;; + esac + dynamic_linker='Win32 ld.exe' + # FIXME: first we should search . and the directory the executable is in + shlibpath_var=PATH + ;; -# Commands to strip libraries. -old_striplib=$lt_old_striplib -striplib=$lt_striplib +darwin* | rhapsody*) + dynamic_linker="$host_os dyld" + version_type=darwin + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' + soname_spec='${libname}${release}${major}$shared_ext' + shlibpath_overrides_runpath=yes + shlibpath_var=DYLD_LIBRARY_PATH + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' + # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same. + if test "$GCC" = yes; then + sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"` + else + sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib' + fi + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' + ;; -# Dependencies to place before the objects being linked to create a -# shared library. -predep_objects=$lt_predep_objects_RC +dgux*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; -# Dependencies to place after the objects being linked to create a -# shared library. -postdep_objects=$lt_postdep_objects_RC +freebsd1*) + dynamic_linker=no + ;; -# Dependencies to place before the objects being linked to create a -# shared library. -predeps=$lt_predeps_RC +kfreebsd*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='GNU ld.so' + ;; -# Dependencies to place after the objects being linked to create a -# shared library. -postdeps=$lt_postdeps_RC +freebsd* | dragonfly*) + # DragonFly does not have aout. When/if they implement a new + # versioning mechanism, adjust this. + if test -x /usr/bin/objformat; then + objformat=`/usr/bin/objformat` + else + case $host_os in + freebsd[123]*) objformat=aout ;; + *) objformat=elf ;; + esac + fi + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + need_version=no + need_lib_prefix=no + ;; + freebsd-*) + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' + need_version=yes + ;; + esac + shlibpath_var=LD_LIBRARY_PATH + case $host_os in + freebsd2*) + shlibpath_overrides_runpath=yes + ;; + freebsd3.[01]* | freebsdelf3.[01]*) + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + *) # from 3.2 on + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + esac + ;; -# The library search path used internally by the compiler when linking -# a shared library. -compiler_lib_search_path=$lt_compiler_lib_search_path_RC +gnu*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + hardcode_into_libs=yes + ;; -# Method to check whether dependent libraries are shared objects. -deplibs_check_method=$lt_deplibs_check_method +hpux9* | hpux10* | hpux11*) + # Give a soname corresponding to the major version so that dld.sl refuses to + # link against other versions. + version_type=sunos + need_lib_prefix=no + need_version=no + case $host_cpu in + ia64*) + shrext_cmds='.so' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.so" + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + if test "X$HPUX_IA64_MODE" = X32; then + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + else + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + fi + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + hppa*64*) + shrext_cmds='.sl' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.sl" + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + *) + shrext_cmds='.sl' + dynamic_linker="$host_os dld.sl" + shlibpath_var=SHLIB_PATH + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + ;; + esac + # HP-UX runs *really* slowly unless shared libraries are mode 555. + postinstall_cmds='chmod 555 $lib' + ;; -# Command to use when deplibs_check_method == file_magic. -file_magic_cmd=$lt_file_magic_cmd +irix5* | irix6* | nonstopux*) + case $host_os in + nonstopux*) version_type=nonstopux ;; + *) + if test "$lt_cv_prog_gnu_ld" = yes; then + version_type=linux + else + version_type=irix + fi ;; + esac + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' + case $host_os in + irix5* | nonstopux*) + libsuff= shlibsuff= + ;; + *) + case $LD in # libtool.m4 will add one of these switches to LD + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") + libsuff= shlibsuff= libmagic=32-bit;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") + libsuff=32 shlibsuff=N32 libmagic=N32;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") + libsuff=64 shlibsuff=64 libmagic=64-bit;; + *) libsuff= shlibsuff= libmagic=never-match;; + esac + ;; + esac + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH + shlibpath_overrides_runpath=no + sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" + sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" + hardcode_into_libs=yes + ;; -# Flag that allows shared libraries with undefined symbols to be built. -allow_undefined_flag=$lt_allow_undefined_flag_RC +# No shared lib support for Linux oldld, aout, or coff. +linux*oldld* | linux*aout* | linux*coff*) + dynamic_linker=no + ;; -# Flag that forces no undefined symbols. -no_undefined_flag=$lt_no_undefined_flag_RC +# This must be Linux ELF. +linux*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes -# Commands used to finish a libtool library installation in a directory. -finish_cmds=$lt_finish_cmds + # Append ld.so.conf contents to the search path + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi -# Same as above, but a single script fragment to be evaled but not shown. -finish_eval=$lt_finish_eval + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; -# Take the output of nm and produce a listing of raw symbols and C names. -global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe +knetbsd*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='GNU ld.so' + ;; -# Transform the output of nm in a proper C declaration -global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' + else + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='NetBSD ld.elf_so' + fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; -# Transform the output of nm in a C name address pair -global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address +newsos6) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; -# This is the shared library runtime path variable. -runpath_var=$runpath_var +nto-qnx*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; -# This is the shared library path variable. -shlibpath_var=$shlibpath_var +openbsd*) + version_type=sunos + need_lib_prefix=no + # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. + case $host_os in + openbsd3.3 | openbsd3.3.*) need_version=yes ;; + *) need_version=no ;; + esac + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + case $host_os in + openbsd2.[89] | openbsd2.[89].*) + shlibpath_overrides_runpath=no + ;; + *) + shlibpath_overrides_runpath=yes + ;; + esac + else + shlibpath_overrides_runpath=yes + fi + ;; -# Is shlibpath searched before the hard-coded library search path? -shlibpath_overrides_runpath=$shlibpath_overrides_runpath +os2*) + libname_spec='$name' + shrext_cmds=".dll" + need_lib_prefix=no + library_names_spec='$libname${shared_ext} $libname.a' + dynamic_linker='OS/2 ld.exe' + shlibpath_var=LIBPATH + ;; -# How to hardcode a shared library path into an executable. -hardcode_action=$hardcode_action_RC +osf3* | osf4* | osf5*) + version_type=osf + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" + sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" + ;; -# Whether we should hardcode library paths into libraries. -hardcode_into_libs=$hardcode_into_libs +sco3.2v5*) + version_type=osf + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + ;; -# Flag to hardcode \$libdir into a binary during linking. -# This must work even if \$libdir does not exist. -hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_RC +solaris*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + # ldd complains unless libraries are executable + postinstall_cmds='chmod +x $lib' + ;; -# If ld is used when linking, flag to hardcode \$libdir into -# a binary during linking. This must work even if \$libdir does -# not exist. -hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_RC +sunos4*) + version_type=sunos + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + if test "$with_gnu_ld" = yes; then + need_lib_prefix=no + fi + need_version=yes + ;; -# Whether we need a single -rpath flag with a separated argument. -hardcode_libdir_separator=$lt_hardcode_libdir_separator_RC +sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + export_dynamic_flag_spec='${wl}-Blargedynsym' + runpath_var=LD_RUN_PATH + ;; + siemens) + need_lib_prefix=no + ;; + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' + ;; + esac + ;; -# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the -# resulting binary. -hardcode_direct=$hardcode_direct_RC +sysv4*MP*) + if test -d /usr/nec ;then + version_type=linux + library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' + soname_spec='$libname${shared_ext}.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; -# Set to yes if using the -LDIR flag during linking hardcodes DIR into the -# resulting binary. -hardcode_minus_L=$hardcode_minus_L_RC +uts4*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; -# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into -# the resulting binary. -hardcode_shlibpath_var=$hardcode_shlibpath_var_RC +*) + dynamic_linker=no + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 +$as_echo "$dynamic_linker" >&6; } +test "$dynamic_linker" = no && can_build_shared=no -# Set to yes if building a shared library automatically hardcodes DIR into the library -# and all subsequent libraries and executables linked against it. -hardcode_automatic=$hardcode_automatic_RC +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 +$as_echo_n "checking how to hardcode library paths into programs... " >&6; } +hardcode_action_GCJ= +if test -n "$hardcode_libdir_flag_spec_GCJ" || \ + test -n "$runpath_var_GCJ" || \ + test "X$hardcode_automatic_GCJ" = "Xyes" ; then -# Variables whose values should be saved in libtool wrapper scripts and -# restored at relink time. -variables_saved_for_relink="$variables_saved_for_relink" + # We can hardcode non-existant directories. + if test "$hardcode_direct_GCJ" != no && + # If the only mechanism to avoid hardcoding is shlibpath_var, we + # have to relink, otherwise we might link with an installed library + # when we should be linking with a yet-to-be-installed one + ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, GCJ)" != no && + test "$hardcode_minus_L_GCJ" != no; then + # Linking always hardcodes the temporary library directory. + hardcode_action_GCJ=relink + else + # We can link without hardcoding, and we can hardcode nonexisting dirs. + hardcode_action_GCJ=immediate + fi +else + # We cannot hardcode anything, or else we can only hardcode existing + # directories. + hardcode_action_GCJ=unsupported +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action_GCJ" >&5 +$as_echo "$hardcode_action_GCJ" >&6; } -# Whether libtool must link a program against all its dependency libraries. -link_all_deplibs=$link_all_deplibs_RC +if test "$hardcode_action_GCJ" = relink; then + # Fast installation is not supported + enable_fast_install=no +elif test "$shlibpath_overrides_runpath" = yes || + test "$enable_shared" = no; then + # Fast installation is not necessary + enable_fast_install=needless +fi -# Compile-time system search path for libraries -sys_lib_search_path_spec=$lt_sys_lib_search_path_spec +striplib= +old_striplib= +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 +$as_echo_n "checking whether stripping libraries is possible... " >&6; } +if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then + test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" + test -z "$striplib" && striplib="$STRIP --strip-unneeded" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else +# FIXME - insert some real tests, host_os isn't really good enough + case $host_os in + darwin*) + if test -n "$STRIP" ; then + striplib="$STRIP -x" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + ;; + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + ;; + esac +fi -# Run-time system search path for libraries -sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec +if test "x$enable_dlopen" != xyes; then + enable_dlopen=unknown + enable_dlopen_self=unknown + enable_dlopen_self_static=unknown +else + lt_cv_dlopen=no + lt_cv_dlopen_libs= -# Fix the shell variable \$srcfile for the compiler. -fix_srcfile_path="$fix_srcfile_path_RC" + case $host_os in + beos*) + lt_cv_dlopen="load_add_on" + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + ;; -# Set to yes if exported symbols are required. -always_export_symbols=$always_export_symbols_RC + mingw* | pw32*) + lt_cv_dlopen="LoadLibrary" + lt_cv_dlopen_libs= + ;; -# The commands to list exported symbols. -export_symbols_cmds=$lt_export_symbols_cmds_RC + cygwin*) + lt_cv_dlopen="dlopen" + lt_cv_dlopen_libs= + ;; -# The commands to extract the exported symbol list from a shared archive. -extract_expsyms_cmds=$lt_extract_expsyms_cmds + darwin*) + # if libdl is installed we need to link against it + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 +$as_echo_n "checking for dlopen in -ldl... " >&6; } +if test "${ac_cv_lib_dl_dlopen+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldl $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Symbols that should not be listed in the preloaded symbols. -exclude_expsyms=$lt_exclude_expsyms_RC +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dl_dlopen=yes +else + ac_cv_lib_dl_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 +$as_echo "$ac_cv_lib_dl_dlopen" >&6; } +if test "x$ac_cv_lib_dl_dlopen" = x""yes; then : + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" +else -# Symbols that must always be exported. -include_expsyms=$lt_include_expsyms_RC + lt_cv_dlopen="dyld" + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes -# ### END LIBTOOL TAG CONFIG: $tagname +fi -__EOF__ + ;; + *) + ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" +if test "x$ac_cv_func_shl_load" = x""yes; then : + lt_cv_dlopen="shl_load" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 +$as_echo_n "checking for shl_load in -ldld... " >&6; } +if test "${ac_cv_lib_dld_shl_load+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char shl_load (); +int +main () +{ +return shl_load (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dld_shl_load=yes else - # If there is no Makefile yet, we rely on a make rule to execute - # `config.status --recheck' to rerun these tests and create the - # libtool script then. - ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` - if test -f "$ltmain_in"; then - test -f Makefile && make "$ltmain" - fi + ac_cv_lib_dld_shl_load=no fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 +$as_echo "$ac_cv_lib_dld_shl_load" >&6; } +if test "x$ac_cv_lib_dld_shl_load" = x""yes; then : + lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld" +else + ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" +if test "x$ac_cv_func_dlopen" = x""yes; then : + lt_cv_dlopen="dlopen" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 +$as_echo_n "checking for dlopen in -ldl... " >&6; } +if test "${ac_cv_lib_dl_dlopen+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldl $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dl_dlopen=yes +else + ac_cv_lib_dl_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 +$as_echo "$ac_cv_lib_dl_dlopen" >&6; } +if test "x$ac_cv_lib_dl_dlopen" = x""yes; then : + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 +$as_echo_n "checking for dlopen in -lsvld... " >&6; } +if test "${ac_cv_lib_svld_dlopen+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lsvld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -CC="$lt_save_CC" - - ;; +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_svld_dlopen=yes +else + ac_cv_lib_svld_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 +$as_echo "$ac_cv_lib_svld_dlopen" >&6; } +if test "x$ac_cv_lib_svld_dlopen" = x""yes; then : + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 +$as_echo_n "checking for dld_link in -ldld... " >&6; } +if test "${ac_cv_lib_dld_dld_link+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - *) - as_fn_error "Unsupported tag name: $tagname" "$LINENO" 5 - ;; - esac +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dld_link (); +int +main () +{ +return dld_link (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dld_dld_link=yes +else + ac_cv_lib_dld_dld_link=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 +$as_echo "$ac_cv_lib_dld_dld_link" >&6; } +if test "x$ac_cv_lib_dld_dld_link" = x""yes; then : + lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld" +fi - # Append the new tag name to the list of available tags. - if test -n "$tagname" ; then - available_tags="$available_tags $tagname" - fi - fi - done - IFS="$lt_save_ifs" - # Now substitute the updated list of available tags. - if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then - mv "${ofile}T" "$ofile" - chmod +x "$ofile" - else - rm -f "${ofile}T" - as_fn_error "unable to update list of available tagged configurations." "$LINENO" 5 - fi fi +fi -# This can be used to rebuild libtool when needed -LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh" -# Always use our own libtool. -LIBTOOL='$(SHELL) $(top_builddir)/libtool' +fi -# Prevent multiple expansion +fi +fi + ;; + esac + if test "x$lt_cv_dlopen" != xno; then + enable_dlopen=yes + else + enable_dlopen=no + fi + case $lt_cv_dlopen in + dlopen) + save_CPPFLAGS="$CPPFLAGS" + test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" + save_LDFLAGS="$LDFLAGS" + eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" + save_LIBS="$LIBS" + LIBS="$lt_cv_dlopen_libs $LIBS" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 +$as_echo_n "checking whether a program can dlopen itself... " >&6; } +if test "${lt_cv_dlopen_self+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + lt_cv_dlopen_self=cross +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext < +#endif - NEED_LIBOPTS_DIR='' +#include - LIBOPTS_DIR=libopts +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif - # Check whether --enable-local-libopts was given. -if test "${enable_local_libopts+set}" = set; then : - enableval=$enable_local_libopts; - if test x$enableval = xyes ; then - { $as_echo "$as_me:${as_lineno-$LINENO}: Using supplied libopts tearoff" >&5 -$as_echo "$as_me: Using supplied libopts tearoff" >&6;} - LIBOPTS_LDADD='$(top_builddir)/libopts/libopts.la' - LIBOPTS_CFLAGS='-I$(top_srcdir)/libopts' - NEED_LIBOPTS_DIR=true - fi -fi +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif +#ifdef __cplusplus +extern "C" void exit (int); +#endif - # Check whether --enable-libopts-install was given. -if test "${enable_libopts_install+set}" = set; then : - enableval=$enable_libopts_install; -fi +void fnord() { int i=42;} +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; - if test "X${enable_libopts_install}" != Xno; then - INSTALL_LIBOPTS_TRUE= - INSTALL_LIBOPTS_FALSE='#' -else - INSTALL_LIBOPTS_TRUE='#' - INSTALL_LIBOPTS_FALSE= + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + /* dlclose (self); */ + } + + exit (status); +} +EOF + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then + (./conftest; exit; ) >&5 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; + x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; + x$lt_unknown|x*) lt_cv_dlopen_self=no ;; + esac + else : + # compilation failed + lt_cv_dlopen_self=no + fi fi +rm -fr conftest* - if test -z "${NEED_LIBOPTS_DIR}" ; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether autoopts-config can be found" >&5 -$as_echo_n "checking whether autoopts-config can be found... " >&6; } +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 +$as_echo "$lt_cv_dlopen_self" >&6; } -# Check whether --with-autoopts-config was given. -if test "${with_autoopts_config+set}" = set; then : - withval=$with_autoopts_config; lo_cv_with_autoopts_config=${with_autoopts_config} -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether autoopts-config is specified" >&5 -$as_echo_n "checking whether autoopts-config is specified... " >&6; } -if test "${lo_cv_with_autoopts_config+set}" = set; then : + if test "x$lt_cv_dlopen_self" = xyes; then + LDFLAGS="$LDFLAGS $link_static_flag" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 +$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } +if test "${lt_cv_dlopen_self_static+set}" = set; then : $as_echo_n "(cached) " >&6 else - if autoopts-config --help 2>/dev/null 1>&2 - then lo_cv_with_autoopts_config=autoopts-config - elif libopts-config --help 2>/dev/null 1>&2 - then lo_cv_with_autoopts_config=libopts-config - else lo_cv_with_autoopts_config=no ; fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lo_cv_with_autoopts_config" >&5 -$as_echo "$lo_cv_with_autoopts_config" >&6; } + if test "$cross_compiling" = yes; then : + lt_cv_dlopen_self_static=cross +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext < +#endif - if test "${lo_cv_test_autoopts+set}" = set; then : - $as_echo_n "(cached) " >&6 -else +#include - if test -z "${lo_cv_with_autoopts_config}" \ - -o X"${lo_cv_with_autoopts_config}" = Xno - then - if autoopts-config --help 2>/dev/null 1>&2 - then lo_cv_with_autoopts_config=autoopts-config - elif libopts-config --help 2>/dev/null 1>&2 - then lo_cv_with_autoopts_config=libopts-config - else lo_cv_with_autoopts_config=false ; fi - fi - lo_cv_test_autoopts=` - ${lo_cv_with_autoopts_config} --libs` 2> /dev/null - if test $? -ne 0 -o -z "${lo_cv_test_autoopts}" - then lo_cv_test_autoopts=no ; fi +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif -fi - # end of CACHE_VAL - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lo_cv_test_autoopts}" >&5 -$as_echo "${lo_cv_test_autoopts}" >&6; } +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif + +#ifdef __cplusplus +extern "C" void exit (int); +#endif + +void fnord() { int i=42;} +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; - if test "X${lo_cv_test_autoopts}" != Xno - then - LIBOPTS_LDADD="${lo_cv_test_autoopts}" - LIBOPTS_CFLAGS="`${lo_cv_with_autoopts_config} --cflags`" - else - LIBOPTS_LDADD='$(top_builddir)/libopts/libopts.la' - LIBOPTS_CFLAGS='-I$(top_srcdir)/libopts' - NEED_LIBOPTS_DIR=true - fi - fi # end of if test -z "${NEED_LIBOPTS_DIR}" + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + /* dlclose (self); */ + } - if test -n "${NEED_LIBOPTS_DIR}"; then - NEED_LIBOPTS_TRUE= - NEED_LIBOPTS_FALSE='#' -else - NEED_LIBOPTS_TRUE='#' - NEED_LIBOPTS_FALSE= + exit (status); +} +EOF + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then + (./conftest; exit; ) >&5 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; + x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; + x$lt_unknown|x*) lt_cv_dlopen_self_static=no ;; + esac + else : + # compilation failed + lt_cv_dlopen_self_static=no + fi fi +rm -fr conftest* +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 +$as_echo "$lt_cv_dlopen_self_static" >&6; } + fi - LIBOPTS_DIR=libopts + CPPFLAGS="$save_CPPFLAGS" + LDFLAGS="$save_LDFLAGS" + LIBS="$save_LIBS" + ;; + esac - ac_config_files="$ac_config_files libopts/Makefile" + case $lt_cv_dlopen_self in + yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; + *) enable_dlopen_self=unknown ;; + esac + case $lt_cv_dlopen_self_static in + yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; + *) enable_dlopen_self_static=unknown ;; + esac +fi - if test -n "${NEED_LIBOPTS_DIR}" ; then +# The else clause should only fire when bootstrapping the +# libtool distribution, otherwise you forgot to ship ltmain.sh +# with your package, and you will get complaints that there are +# no rules to generate ltmain.sh. +if test -f "$ltmain"; then + # See if we are running on zsh, and set the options which allow our commands through + # without removal of \ escapes. + if test -n "${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST + fi + # Now quote all the things that may contain metacharacters while being + # careful not to overquote the AC_SUBSTed values. We take copies of the + # variables and quote the copies for generation of the libtool script. + for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \ + SED SHELL STRIP \ + libname_spec library_names_spec soname_spec extract_expsyms_cmds \ + old_striplib striplib file_magic_cmd finish_cmds finish_eval \ + deplibs_check_method reload_flag reload_cmds need_locks \ + lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ + lt_cv_sys_global_symbol_to_c_name_address \ + sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ + old_postinstall_cmds old_postuninstall_cmds \ + compiler_GCJ \ + CC_GCJ \ + LD_GCJ \ + lt_prog_compiler_wl_GCJ \ + lt_prog_compiler_pic_GCJ \ + lt_prog_compiler_static_GCJ \ + lt_prog_compiler_no_builtin_flag_GCJ \ + export_dynamic_flag_spec_GCJ \ + thread_safe_flag_spec_GCJ \ + whole_archive_flag_spec_GCJ \ + enable_shared_with_static_runtimes_GCJ \ + old_archive_cmds_GCJ \ + old_archive_from_new_cmds_GCJ \ + predep_objects_GCJ \ + postdep_objects_GCJ \ + predeps_GCJ \ + postdeps_GCJ \ + compiler_lib_search_path_GCJ \ + archive_cmds_GCJ \ + archive_expsym_cmds_GCJ \ + postinstall_cmds_GCJ \ + postuninstall_cmds_GCJ \ + old_archive_from_expsyms_cmds_GCJ \ + allow_undefined_flag_GCJ \ + no_undefined_flag_GCJ \ + export_symbols_cmds_GCJ \ + hardcode_libdir_flag_spec_GCJ \ + hardcode_libdir_flag_spec_ld_GCJ \ + hardcode_libdir_separator_GCJ \ + hardcode_automatic_GCJ \ + module_cmds_GCJ \ + module_expsym_cmds_GCJ \ + lt_cv_prog_compiler_c_o_GCJ \ + exclude_expsyms_GCJ \ + include_expsyms_GCJ; do + case $var in + old_archive_cmds_GCJ | \ + old_archive_from_new_cmds_GCJ | \ + archive_cmds_GCJ | \ + archive_expsym_cmds_GCJ | \ + module_cmds_GCJ | \ + module_expsym_cmds_GCJ | \ + old_archive_from_expsyms_cmds_GCJ | \ + export_symbols_cmds_GCJ | \ + extract_expsyms_cmds | reload_cmds | finish_cmds | \ + postinstall_cmds | postuninstall_cmds | \ + old_postinstall_cmds | old_postuninstall_cmds | \ + sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) + # Double-quote double-evaled strings. + eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" + ;; + *) + eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" + ;; + esac + done -if test X${INVOKE_LIBOPTS_MACROS_FIRST_done} != Xyes ; then - # ================= - # AC_HEADER_STDC - # ================= - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 -$as_echo_n "checking for ANSI C header files... " >&6; } -if test "${ac_cv_header_stdc+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#include -#include + case $lt_echo in + *'\$0 --fallback-echo"') + lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` + ;; + esac -int -main () -{ +cfgfile="$ofile" - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_header_stdc=yes -else - ac_cv_header_stdc=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + cat <<__EOF__ >> "$cfgfile" +# ### BEGIN LIBTOOL TAG CONFIG: $tagname -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include +# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then : +# Shell to use when invoking shell scripts. +SHELL=$lt_SHELL -else - ac_cv_header_stdc=no -fi -rm -f conftest* +# Whether or not to build shared libraries. +build_libtool_libs=$enable_shared -fi +# Whether or not to build static libraries. +build_old_libs=$enable_static -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include +# Whether or not to add -lc for building shared libraries. +build_libtool_need_lc=$archive_cmds_need_lc_GCJ -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then : +# Whether or not to disallow shared libs when runtime libs are static +allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_GCJ -else - ac_cv_header_stdc=no -fi -rm -f conftest* +# Whether or not to optimize for fast installation. +fast_install=$enable_fast_install -fi +# The host system. +host_alias=$host_alias +host=$host +host_os=$host_os -if test $ac_cv_header_stdc = yes; then - # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. - if test "$cross_compiling" = yes; then : - : -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#if ((' ' & 0x0FF) == 0x020) -# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') -# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) -#else -# define ISLOWER(c) \ - (('a' <= (c) && (c) <= 'i') \ - || ('j' <= (c) && (c) <= 'r') \ - || ('s' <= (c) && (c) <= 'z')) -# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) -#endif +# The build system. +build_alias=$build_alias +build=$build +build_os=$build_os -#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) -int -main () -{ - int i; - for (i = 0; i < 256; i++) - if (XOR (islower (i), ISLOWER (i)) - || toupper (i) != TOUPPER (i)) - return 2; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : +# An echo program that does not interpret backslashes. +echo=$lt_echo -else - ac_cv_header_stdc=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi +# The archiver. +AR=$lt_AR +AR_FLAGS=$lt_AR_FLAGS -fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 -$as_echo "$ac_cv_header_stdc" >&6; } -if test $ac_cv_header_stdc = yes; then +# A C compiler. +LTCC=$lt_LTCC -$as_echo "#define STDC_HEADERS 1" >>confdefs.h +# A language-specific compiler. +CC=$lt_compiler_GCJ -fi +# Is the compiler the GNU C compiler? +with_gcc=$GCC_GCJ - # ================= - # AC_HEADER_DIRENT - # ================= - ac_header_dirent=no -for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do - as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5 -$as_echo_n "checking for $ac_hdr that defines DIR... " >&6; } -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include <$ac_hdr> +# An ERE matcher. +EGREP=$lt_EGREP -int -main () -{ -if ((DIR *) 0) -return 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - eval "$as_ac_Header=yes" -else - eval "$as_ac_Header=no" -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -eval ac_res=\$$as_ac_Header - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 -_ACEOF +# The linker used to build libraries. +LD=$lt_LD_GCJ -ac_header_dirent=$ac_hdr; break -fi +# Whether we need hard or soft links. +LN_S=$lt_LN_S -done -# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. -if test $ac_header_dirent = dirent.h; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 -$as_echo_n "checking for library containing opendir... " >&6; } -if test "${ac_cv_search_opendir+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +# A BSD-compatible nm program. +NM=$lt_NM -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char opendir (); -int -main () -{ -return opendir (); - ; - return 0; -} -_ACEOF -for ac_lib in '' dir; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_opendir=$ac_res -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext - if test "${ac_cv_search_opendir+set}" = set; then : - break -fi -done -if test "${ac_cv_search_opendir+set}" = set; then : +# A symbol stripping program +STRIP=$lt_STRIP -else - ac_cv_search_opendir=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 -$as_echo "$ac_cv_search_opendir" >&6; } -ac_res=$ac_cv_search_opendir -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" +# Used to examine libraries when file_magic_cmd begins "file" +MAGIC_CMD=$MAGIC_CMD -fi +# Used on cygwin: DLL creation program. +DLLTOOL="$DLLTOOL" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 -$as_echo_n "checking for library containing opendir... " >&6; } -if test "${ac_cv_search_opendir+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +# Used on cygwin: object dumper. +OBJDUMP="$OBJDUMP" -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char opendir (); -int -main () -{ -return opendir (); - ; - return 0; -} -_ACEOF -for ac_lib in '' x; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_opendir=$ac_res -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext - if test "${ac_cv_search_opendir+set}" = set; then : - break -fi -done -if test "${ac_cv_search_opendir+set}" = set; then : +# Used on cygwin: assembler. +AS="$AS" -else - ac_cv_search_opendir=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 -$as_echo "$ac_cv_search_opendir" >&6; } -ac_res=$ac_cv_search_opendir -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" +# The name of the directory that contains temporary libtool files. +objdir=$objdir -fi +# How to create reloadable object files. +reload_flag=$lt_reload_flag +reload_cmds=$lt_reload_cmds -fi +# How to pass a linker flag through the compiler. +wl=$lt_lt_prog_compiler_wl_GCJ +# Object file suffix (normally "o"). +objext="$ac_objext" - # ================= - # AC_CHECK_HEADERS - # ================= - for ac_header in dlfcn.h errno.h fcntl.h libgen.h memory.h netinet/in.h \ - setjmp.h sys/mman.h sys/param.h sys/poll.h sys/procset.h sys/select.h \ - sys/socket.h sys/stropts.h sys/time.h sys/un.h sys/wait.h unistd.h \ - utime.h sysexits.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF +# Old archive suffix (normally "a"). +libext="$libext" -fi +# Shared library suffix (normally ".so"). +shrext_cmds='$shrext_cmds' -done +# Executable file suffix (normally ""). +exeext="$exeext" + +# Additional compiler flags for building library objects. +pic_flag=$lt_lt_prog_compiler_pic_GCJ +pic_mode=$pic_mode +# What is the maximum length of a command? +max_cmd_len=$lt_cv_sys_max_cmd_len - # -------------------------------------------- - # Verify certain entries from AC_CHECK_HEADERS - # -------------------------------------------- - for f in sys_types sys_mman sys_param sys_stat sys_wait \ - string errno stdlib memory setjmp - do eval as_ac_var=\${ac_cv_header_${f}_h+set} - test "${as_ac_var}" = set || \ - as_fn_error "You must have ${f}.h on your system" "$LINENO" 5 - done +# Does compiler simultaneously support -c and -o options? +compiler_c_o=$lt_lt_cv_prog_compiler_c_o_GCJ - # ================================================ - # AC_CHECK_HEADERS: stdarg.h is present define HAVE_STDARG_H, otherwise - # if varargs.h is present define HAVE_VARARGS_H. - # ================================================ - for ac_header in stdarg.h varargs.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - break -fi +# Must we lock files when doing compilation? +need_locks=$lt_need_locks -done +# Do we need the lib prefix for modules? +need_lib_prefix=$need_lib_prefix - if test `eval echo '${'$as_ac_Header'}'` != yes; then - as_fn_error "You must have stdarg.h or varargs.h on your system" "$LINENO" 5 - fi +# Do we need a version for libraries? +need_version=$need_version - # ================================================ - # Similarly for the string.h and strings.h headers - # ================================================ - for ac_header in string.h strings.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - break -fi +# Whether dlopen is supported. +dlopen_support=$enable_dlopen -done +# Whether dlopen of programs is supported. +dlopen_self=$enable_dlopen_self - if test `eval echo '${'$as_ac_Header'}'` != yes; then - as_fn_error "You must have string.h or strings.h on your system" "$LINENO" 5 - fi +# Whether dlopen of statically linked programs is supported. +dlopen_self_static=$enable_dlopen_self_static - # ===================== - # ...and limits headers - # ===================== - for ac_header in limits.h sys/limits.h values.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - break -fi +# Compiler flag to prevent dynamic linking. +link_static_flag=$lt_lt_prog_compiler_static_GCJ -done +# Compiler flag to turn off builtin functions. +no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_GCJ - if test `eval echo '${'$as_ac_Header'}'` != yes; then - as_fn_error "You must have one of limits.h, sys/limits.h or values.h" "$LINENO" 5 - fi +# Compiler flag to allow reflexive dlopens. +export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_GCJ - # ======================== - # ...and int types headers - # ======================== - for ac_header in stdint.h inttypes.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - break -fi +# Compiler flag to generate shared objects directly from archives. +whole_archive_flag_spec=$lt_whole_archive_flag_spec_GCJ -done +# Compiler flag to generate thread-safe objects. +thread_safe_flag_spec=$lt_thread_safe_flag_spec_GCJ - ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "$ac_includes_default" -if test "x$ac_cv_type_int8_t" = x""yes; then : +# Library versioning type. +version_type=$version_type -cat >>confdefs.h <<_ACEOF -#define HAVE_INT8_T 1 -_ACEOF +# Format of library name prefix. +libname_spec=$lt_libname_spec +# List of archive names. First name is the real one, the rest are links. +# The last name is the one that the linker finds with -lNAME. +library_names_spec=$lt_library_names_spec -fi -ac_fn_c_check_type "$LINENO" "uint8_t" "ac_cv_type_uint8_t" "$ac_includes_default" -if test "x$ac_cv_type_uint8_t" = x""yes; then : +# The coded name of the library, if different from the real name. +soname_spec=$lt_soname_spec -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT8_T 1 -_ACEOF +# Commands used to build and install an old-style archive. +RANLIB=$lt_RANLIB +old_archive_cmds=$lt_old_archive_cmds_GCJ +old_postinstall_cmds=$lt_old_postinstall_cmds +old_postuninstall_cmds=$lt_old_postuninstall_cmds +# Create an old-style archive from a shared archive. +old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_GCJ -fi -ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "$ac_includes_default" -if test "x$ac_cv_type_int16_t" = x""yes; then : +# Create a temporary old-style archive to link instead of a shared archive. +old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_GCJ -cat >>confdefs.h <<_ACEOF -#define HAVE_INT16_T 1 -_ACEOF +# Commands used to build and install a shared archive. +archive_cmds=$lt_archive_cmds_GCJ +archive_expsym_cmds=$lt_archive_expsym_cmds_GCJ +postinstall_cmds=$lt_postinstall_cmds +postuninstall_cmds=$lt_postuninstall_cmds +# Commands used to build a loadable module (assumed same as above if empty) +module_cmds=$lt_module_cmds_GCJ +module_expsym_cmds=$lt_module_expsym_cmds_GCJ -fi -ac_fn_c_check_type "$LINENO" "uint16_t" "ac_cv_type_uint16_t" "$ac_includes_default" -if test "x$ac_cv_type_uint16_t" = x""yes; then : +# Commands to strip libraries. +old_striplib=$lt_old_striplib +striplib=$lt_striplib -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT16_T 1 -_ACEOF +# Dependencies to place before the objects being linked to create a +# shared library. +predep_objects=$lt_predep_objects_GCJ +# Dependencies to place after the objects being linked to create a +# shared library. +postdep_objects=$lt_postdep_objects_GCJ -fi -ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default" -if test "x$ac_cv_type_int32_t" = x""yes; then : +# Dependencies to place before the objects being linked to create a +# shared library. +predeps=$lt_predeps_GCJ -cat >>confdefs.h <<_ACEOF -#define HAVE_INT32_T 1 -_ACEOF +# Dependencies to place after the objects being linked to create a +# shared library. +postdeps=$lt_postdeps_GCJ +# The library search path used internally by the compiler when linking +# a shared library. +compiler_lib_search_path=$lt_compiler_lib_search_path_GCJ -fi -ac_fn_c_check_type "$LINENO" "uint32_t" "ac_cv_type_uint32_t" "$ac_includes_default" -if test "x$ac_cv_type_uint32_t" = x""yes; then : +# Method to check whether dependent libraries are shared objects. +deplibs_check_method=$lt_deplibs_check_method -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT32_T 1 -_ACEOF +# Command to use when deplibs_check_method == file_magic. +file_magic_cmd=$lt_file_magic_cmd +# Flag that allows shared libraries with undefined symbols to be built. +allow_undefined_flag=$lt_allow_undefined_flag_GCJ -fi -ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "$ac_includes_default" -if test "x$ac_cv_type_intptr_t" = x""yes; then : +# Flag that forces no undefined symbols. +no_undefined_flag=$lt_no_undefined_flag_GCJ -cat >>confdefs.h <<_ACEOF -#define HAVE_INTPTR_T 1 -_ACEOF +# Commands used to finish a libtool library installation in a directory. +finish_cmds=$lt_finish_cmds +# Same as above, but a single script fragment to be evaled but not shown. +finish_eval=$lt_finish_eval -fi -ac_fn_c_check_type "$LINENO" "uint_t" "ac_cv_type_uint_t" "$ac_includes_default" -if test "x$ac_cv_type_uint_t" = x""yes; then : +# Take the output of nm and produce a listing of raw symbols and C names. +global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT_T 1 -_ACEOF +# Transform the output of nm in a proper C declaration +global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl +# Transform the output of nm in a C name address pair +global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address -fi +# This is the shared library runtime path variable. +runpath_var=$runpath_var +# This is the shared library path variable. +shlibpath_var=$shlibpath_var - # ==================== - # uintptr type & sizes - # ==================== - ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default" -if test "x$ac_cv_type_uintptr_t" = x""yes; then : +# Is shlibpath searched before the hard-coded library search path? +shlibpath_overrides_runpath=$shlibpath_overrides_runpath -cat >>confdefs.h <<_ACEOF -#define HAVE_UINTPTR_T 1 -_ACEOF +# How to hardcode a shared library path into an executable. +hardcode_action=$hardcode_action_GCJ +# Whether we should hardcode library paths into libraries. +hardcode_into_libs=$hardcode_into_libs -else +# Flag to hardcode \$libdir into a binary during linking. +# This must work even if \$libdir does not exist. +hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_GCJ -$as_echo "#define uintptr_t unsigned long" >>confdefs.h +# If ld is used when linking, flag to hardcode \$libdir into +# a binary during linking. This must work even if \$libdir does +# not exist. +hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_GCJ -fi +# Whether we need a single -rpath flag with a separated argument. +hardcode_libdir_separator=$lt_hardcode_libdir_separator_GCJ - # The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of char*" >&5 -$as_echo_n "checking size of char*... " >&6; } -if test "${ac_cv_sizeof_charp+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char*))" "ac_cv_sizeof_charp" "$ac_includes_default"; then : +# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the +# resulting binary. +hardcode_direct=$hardcode_direct_GCJ -else - if test "$ac_cv_type_charp" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (char*) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_charp=0 - fi -fi +# Set to yes if using the -LDIR flag during linking hardcodes DIR into the +# resulting binary. +hardcode_minus_L=$hardcode_minus_L_GCJ -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_charp" >&5 -$as_echo "$ac_cv_sizeof_charp" >&6; } +# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into +# the resulting binary. +hardcode_shlibpath_var=$hardcode_shlibpath_var_GCJ + +# Set to yes if building a shared library automatically hardcodes DIR into the library +# and all subsequent libraries and executables linked against it. +hardcode_automatic=$hardcode_automatic_GCJ +# Variables whose values should be saved in libtool wrapper scripts and +# restored at relink time. +variables_saved_for_relink="$variables_saved_for_relink" +# Whether libtool must link a program against all its dependency libraries. +link_all_deplibs=$link_all_deplibs_GCJ -cat >>confdefs.h <<_ACEOF -#define SIZEOF_CHARP $ac_cv_sizeof_charp -_ACEOF +# Compile-time system search path for libraries +sys_lib_search_path_spec=$lt_sys_lib_search_path_spec +# Run-time system search path for libraries +sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec - # The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 -$as_echo_n "checking size of int... " >&6; } -if test "${ac_cv_sizeof_int+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then : +# Fix the shell variable \$srcfile for the compiler. +fix_srcfile_path="$fix_srcfile_path_GCJ" -else - if test "$ac_cv_type_int" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (int) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_int=0 - fi -fi +# Set to yes if exported symbols are required. +always_export_symbols=$always_export_symbols_GCJ -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 -$as_echo "$ac_cv_sizeof_int" >&6; } +# The commands to list exported symbols. +export_symbols_cmds=$lt_export_symbols_cmds_GCJ +# The commands to extract the exported symbol list from a shared archive. +extract_expsyms_cmds=$lt_extract_expsyms_cmds +# Symbols that should not be listed in the preloaded symbols. +exclude_expsyms=$lt_exclude_expsyms_GCJ -cat >>confdefs.h <<_ACEOF -#define SIZEOF_INT $ac_cv_sizeof_int -_ACEOF +# Symbols that must always be exported. +include_expsyms=$lt_include_expsyms_GCJ +# ### END LIBTOOL TAG CONFIG: $tagname + +__EOF__ - # The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 -$as_echo_n "checking size of long... " >&6; } -if test "${ac_cv_sizeof_long+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then : else - if test "$ac_cv_type_long" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (long) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_long=0 - fi + # If there is no Makefile yet, we rely on a make rule to execute + # `config.status --recheck' to rerun these tests and create the + # libtool script then. + ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` + if test -f "$ltmain_in"; then + test -f Makefile && make "$ltmain" + fi fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 -$as_echo "$ac_cv_sizeof_long" >&6; } +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +CC="$lt_save_CC" -cat >>confdefs.h <<_ACEOF -#define SIZEOF_LONG $ac_cv_sizeof_long -_ACEOF + else + tagname="" + fi + ;; + RC) - # The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 -$as_echo_n "checking size of short... " >&6; } -if test "${ac_cv_sizeof_short+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short" "$ac_includes_default"; then : -else - if test "$ac_cv_type_short" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (short) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_short=0 - fi -fi +# Source file extension for RC test sources. +ac_ext=rc -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 -$as_echo "$ac_cv_sizeof_short" >&6; } +# Object file extension for compiled RC test sources. +objext=o +objext_RC=$objext +# Code to be used in simple compile tests +lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }\n' +# Code to be used in simple link tests +lt_simple_link_test_code="$lt_simple_compile_test_code" -cat >>confdefs.h <<_ACEOF -#define SIZEOF_SHORT $ac_cv_sizeof_short -_ACEOF +# ltmain only uses $CC for tagged configurations so make sure $CC is set. +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} +# Allow CC to be a program name with arguments. +compiler=$CC - # ---------------------------------------------------------------------- - # AC_CHECK_LIB for SVR4 libgen, and use it if it defines pathfind. - # ---------------------------------------------------------------------- - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pathfind in -lgen" >&5 -$as_echo_n "checking for pathfind in -lgen... " >&6; } -if test "${ac_cv_lib_gen_pathfind+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lgen $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char pathfind (); -int -main () -{ -return pathfind (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_gen_pathfind=yes -else - ac_cv_lib_gen_pathfind=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gen_pathfind" >&5 -$as_echo "$ac_cv_lib_gen_pathfind" >&6; } -if test "x$ac_cv_lib_gen_pathfind" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBGEN 1 -_ACEOF +# save warnings/boilerplate of simple test code +ac_outfile=conftest.$ac_objext +printf "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$rm conftest* - LIBS="-lgen $LIBS" +ac_outfile=conftest.$ac_objext +printf "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$rm conftest* -fi - for ac_func in vprintf -do : - ac_fn_c_check_func "$LINENO" "vprintf" "ac_cv_func_vprintf" -if test "x$ac_cv_func_vprintf" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_VPRINTF 1 -_ACEOF +# Allow CC to be a program name with arguments. +lt_save_CC="$CC" +CC=${RC-"windres"} +compiler=$CC +compiler_RC=$CC +for cc_temp in $compiler""; do + case $cc_temp in + compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; + distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; + \-*) ;; + *) break;; + esac +done +cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` -ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt" -if test "x$ac_cv_func__doprnt" = x""yes; then : +lt_cv_prog_compiler_c_o_RC=yes -$as_echo "#define HAVE_DOPRNT 1" >>confdefs.h +# The else clause should only fire when bootstrapping the +# libtool distribution, otherwise you forgot to ship ltmain.sh +# with your package, and you will get complaints that there are +# no rules to generate ltmain.sh. +if test -f "$ltmain"; then + # See if we are running on zsh, and set the options which allow our commands through + # without removal of \ escapes. + if test -n "${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST + fi + # Now quote all the things that may contain metacharacters while being + # careful not to overquote the AC_SUBSTed values. We take copies of the + # variables and quote the copies for generation of the libtool script. + for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \ + SED SHELL STRIP \ + libname_spec library_names_spec soname_spec extract_expsyms_cmds \ + old_striplib striplib file_magic_cmd finish_cmds finish_eval \ + deplibs_check_method reload_flag reload_cmds need_locks \ + lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ + lt_cv_sys_global_symbol_to_c_name_address \ + sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ + old_postinstall_cmds old_postuninstall_cmds \ + compiler_RC \ + CC_RC \ + LD_RC \ + lt_prog_compiler_wl_RC \ + lt_prog_compiler_pic_RC \ + lt_prog_compiler_static_RC \ + lt_prog_compiler_no_builtin_flag_RC \ + export_dynamic_flag_spec_RC \ + thread_safe_flag_spec_RC \ + whole_archive_flag_spec_RC \ + enable_shared_with_static_runtimes_RC \ + old_archive_cmds_RC \ + old_archive_from_new_cmds_RC \ + predep_objects_RC \ + postdep_objects_RC \ + predeps_RC \ + postdeps_RC \ + compiler_lib_search_path_RC \ + archive_cmds_RC \ + archive_expsym_cmds_RC \ + postinstall_cmds_RC \ + postuninstall_cmds_RC \ + old_archive_from_expsyms_cmds_RC \ + allow_undefined_flag_RC \ + no_undefined_flag_RC \ + export_symbols_cmds_RC \ + hardcode_libdir_flag_spec_RC \ + hardcode_libdir_flag_spec_ld_RC \ + hardcode_libdir_separator_RC \ + hardcode_automatic_RC \ + module_cmds_RC \ + module_expsym_cmds_RC \ + lt_cv_prog_compiler_c_o_RC \ + exclude_expsyms_RC \ + include_expsyms_RC; do -fi + case $var in + old_archive_cmds_RC | \ + old_archive_from_new_cmds_RC | \ + archive_cmds_RC | \ + archive_expsym_cmds_RC | \ + module_cmds_RC | \ + module_expsym_cmds_RC | \ + old_archive_from_expsyms_cmds_RC | \ + export_symbols_cmds_RC | \ + extract_expsyms_cmds | reload_cmds | finish_cmds | \ + postinstall_cmds | postuninstall_cmds | \ + old_postinstall_cmds | old_postuninstall_cmds | \ + sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) + # Double-quote double-evaled strings. + eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" + ;; + *) + eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" + ;; + esac + done -fi -done + case $lt_echo in + *'\$0 --fallback-echo"') + lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` + ;; + esac +cfgfile="$ofile" - for ac_func in mmap canonicalize_file_name snprintf strdup strchr strrchr -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF + cat <<__EOF__ >> "$cfgfile" +# ### BEGIN LIBTOOL TAG CONFIG: $tagname -fi -done +# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: - INVOKE_LIBOPTS_MACROS_FIRST_done=yes -fi - # Check to see if a reg expr header is specified. +# Shell to use when invoking shell scripts. +SHELL=$lt_SHELL +# Whether or not to build shared libraries. +build_libtool_libs=$enable_shared -# Check whether --with-regex-header was given. -if test "${with_regex_header+set}" = set; then : - withval=$with_regex_header; libopts_cv_with_regex_header=${with_regex_header} -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a reg expr header is specified" >&5 -$as_echo_n "checking whether a reg expr header is specified... " >&6; } -if test "${libopts_cv_with_regex_header+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - libopts_cv_with_regex_header=no -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_regex_header" >&5 -$as_echo "$libopts_cv_with_regex_header" >&6; } +# Whether or not to build static libraries. +build_old_libs=$enable_static -fi - # end of AC_ARG_WITH +# Whether or not to add -lc for building shared libraries. +build_libtool_need_lc=$archive_cmds_need_lc_RC - if test "X${libopts_cv_with_regex_header}" != Xno - then - cat >>confdefs.h <<_ACEOF -#define REGEX_HEADER <${libopts_cv_with_regex_header}> -_ACEOF +# Whether or not to disallow shared libs when runtime libs are static +allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_RC - else +# Whether or not to optimize for fast installation. +fast_install=$enable_fast_install -$as_echo "#define REGEX_HEADER " >>confdefs.h +# The host system. +host_alias=$host_alias +host=$host +host_os=$host_os - fi +# The build system. +build_alias=$build_alias +build=$build +build_os=$build_os +# An echo program that does not interpret backslashes. +echo=$lt_echo +# The archiver. +AR=$lt_AR +AR_FLAGS=$lt_AR_FLAGS - # Check to see if a working libregex can be found. +# A C compiler. +LTCC=$lt_LTCC +# A language-specific compiler. +CC=$lt_compiler_RC -# Check whether --with-libregex was given. -if test "${with_libregex+set}" = set; then : - withval=$with_libregex; libopts_cv_with_libregex_root=${with_libregex} -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether with-libregex was specified" >&5 -$as_echo_n "checking whether with-libregex was specified... " >&6; } -if test "${libopts_cv_with_libregex_root+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - libopts_cv_with_libregex_root=no -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_libregex_root" >&5 -$as_echo "$libopts_cv_with_libregex_root" >&6; } +# Is the compiler the GNU C compiler? +with_gcc=$GCC_RC -fi - # end of AC_ARG_WITH libregex +# An ERE matcher. +EGREP=$lt_EGREP - if test "${with_libguile+set}" = set && \ - test "${withval}" = no - then ## disabled by request - libopts_cv_with_libregex_root=no - libopts_cv_with_libregex_cflags=no - libopts_cv_with_libregex_libs=no - else +# The linker used to build libraries. +LD=$lt_LD_RC +# Whether we need hard or soft links. +LN_S=$lt_LN_S -# Check whether --with-libregex-cflags was given. -if test "${with_libregex_cflags+set}" = set; then : - withval=$with_libregex_cflags; libopts_cv_with_libregex_cflags=${with_regex_cflags} -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether with-libregex-cflags was specified" >&5 -$as_echo_n "checking whether with-libregex-cflags was specified... " >&6; } -if test "${libopts_cv_with_libregex_cflags+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - libopts_cv_with_libregex_cflags=no -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_libregex_cflags" >&5 -$as_echo "$libopts_cv_with_libregex_cflags" >&6; } +# A BSD-compatible nm program. +NM=$lt_NM -fi - # end of AC_ARG_WITH libregex-cflags +# A symbol stripping program +STRIP=$lt_STRIP +# Used to examine libraries when file_magic_cmd begins "file" +MAGIC_CMD=$MAGIC_CMD -# Check whether --with-libregex-libs was given. -if test "${with_libregex_libs+set}" = set; then : - withval=$with_libregex_libs; libopts_cv_with_libregex_libs=${with_regex_libs} -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether with-libregex-libs was specified" >&5 -$as_echo_n "checking whether with-libregex-libs was specified... " >&6; } -if test "${libopts_cv_with_libregex_libs+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - libopts_cv_with_libregex_libs=no -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_libregex_libs" >&5 -$as_echo "$libopts_cv_with_libregex_libs" >&6; } +# Used on cygwin: DLL creation program. +DLLTOOL="$DLLTOOL" -fi - # end of AC_ARG_WITH libregex-libs +# Used on cygwin: object dumper. +OBJDUMP="$OBJDUMP" - case "X${libopts_cv_with_libregex_cflags}" in - Xyes|Xno|X ) - case "X${libopts_cv_with_libregex_root}" in - Xyes|Xno|X ) libopts_cv_with_libregex_cflags=no ;; - * ) libopts_cv_with_libregex_cflags=-I${libopts_cv_with_libregex_root}/include ;; - esac - esac - case "X${libopts_cv_with_libregex_libs}" in - Xyes|Xno|X ) - case "X${libopts_cv_with_libregex_root}" in - Xyes|Xno|X ) libopts_cv_with_libregex_libs=no ;; - * ) libopts_cv_with_libregex_libs="-L${libopts_cv_with_libregex_root}/lib -lregex";; - esac - esac - libopts_save_CPPFLAGS="${CPPFLAGS}" - libopts_save_LIBS="${LIBS}" - fi ## disabled by request +# Used on cygwin: assembler. +AS="$AS" - case "X${libopts_cv_with_libregex_cflags}" in - Xyes|Xno|X ) - libopts_cv_with_libregex_cflags="" ;; - * ) CPPFLAGS="${CPPFLAGS} ${libopts_cv_with_libregex_cflags}" ;; - esac - case "X${libopts_cv_with_libregex_libs}" in - Xyes|Xno|X ) - libopts_cv_with_libregex_libs="" ;; - * ) - LIBS="${LIBS} ${libopts_cv_with_libregex_libs}" ;; - esac - LIBREGEX_CFLAGS="" - LIBREGEX_LIBS="" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether libregex functions properly" >&5 -$as_echo_n "checking whether libregex functions properly... " >&6; } - if test "${libopts_cv_with_libregex+set}" = set; then : - $as_echo_n "(cached) " >&6 -else +# The name of the directory that contains temporary libtool files. +objdir=$objdir - if test "$cross_compiling" = yes; then : - libopts_cv_with_libregex=no -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#include -#include REGEX_HEADER -static regex_t re; -void comp_re( char const* pzPat ) { - int res = regcomp( &re, pzPat, REG_EXTENDED|REG_ICASE|REG_NEWLINE ); - if (res == 0) return; - exit( res ); } -int main() { - regmatch_t m[2]; - comp_re( "^.*\$" ); - comp_re( "()|no.*" ); - comp_re( "." ); - if (regexec( &re, "X", 2, m, 0 ) != 0) return 1; - if ((m[0].rm_so != 0) || (m[0].rm_eo != 1)) { - fputs( "error: regex -->.<-- did not match\n", stderr ); - return 1; - } - return 0; } -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - libopts_cv_with_libregex=yes -else - libopts_cv_with_libregex=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - # end of AC_TRY_RUN +# How to create reloadable object files. +reload_flag=$lt_reload_flag +reload_cmds=$lt_reload_cmds -fi - # end of AC_CACHE_VAL for libopts_cv_with_libregex - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_with_libregex}" >&5 -$as_echo "${libopts_cv_with_libregex}" >&6; } +# How to pass a linker flag through the compiler. +wl=$lt_lt_prog_compiler_wl_RC - if test "X${libopts_cv_with_libregex}" != Xno - then +# Object file suffix (normally "o"). +objext="$ac_objext" -$as_echo "#define WITH_LIBREGEX 1" >>confdefs.h +# Old archive suffix (normally "a"). +libext="$libext" - else - CPPFLAGS="${libopts_save_CPPFLAGS}" - LIBS="${libopts_save_LIBS}" - fi +# Shared library suffix (normally ".so"). +shrext_cmds='$shrext_cmds' +# Executable file suffix (normally ""). +exeext="$exeext" +# Additional compiler flags for building library objects. +pic_flag=$lt_lt_prog_compiler_pic_RC +pic_mode=$pic_mode - # Check to see if pathfind(3) works. +# What is the maximum length of a command? +max_cmd_len=$lt_cv_sys_max_cmd_len - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pathfind(3) works" >&5 -$as_echo_n "checking whether pathfind(3) works... " >&6; } - if test "${libopts_cv_run_pathfind+set}" = set; then : - $as_echo_n "(cached) " >&6 -else +# Does compiler simultaneously support -c and -o options? +compiler_c_o=$lt_lt_cv_prog_compiler_c_o_RC - if test "$cross_compiling" = yes; then : - libopts_cv_run_pathfind=no +# Must we lock files when doing compilation? +need_locks=$lt_need_locks -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -int main (int argc, char** argv) { - char* pz = pathfind( getenv( "PATH" ), "sh", "x" ); - return (pz == 0) ? 1 : 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - libopts_cv_run_pathfind=yes -else - libopts_cv_run_pathfind=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - # end of TRY_RUN +# Do we need the lib prefix for modules? +need_lib_prefix=$need_lib_prefix -fi - # end of AC_CACHE_VAL for libopts_cv_run_pathfind - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_pathfind}" >&5 -$as_echo "${libopts_cv_run_pathfind}" >&6; } +# Do we need a version for libraries? +need_version=$need_version - if test "X${libopts_cv_run_pathfind}" != Xno - then +# Whether dlopen is supported. +dlopen_support=$enable_dlopen -$as_echo "#define HAVE_PATHFIND 1" >>confdefs.h +# Whether dlopen of programs is supported. +dlopen_self=$enable_dlopen_self - fi +# Whether dlopen of statically linked programs is supported. +dlopen_self_static=$enable_dlopen_self_static +# Compiler flag to prevent dynamic linking. +link_static_flag=$lt_lt_prog_compiler_static_RC +# Compiler flag to turn off builtin functions. +no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_RC - # Check to see if /dev/zero is readable device. +# Compiler flag to allow reflexive dlopens. +export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_RC - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether /dev/zero is readable device" >&5 -$as_echo_n "checking whether /dev/zero is readable device... " >&6; } - if test "${libopts_cv_test_dev_zero+set}" = set; then : - $as_echo_n "(cached) " >&6 -else +# Compiler flag to generate shared objects directly from archives. +whole_archive_flag_spec=$lt_whole_archive_flag_spec_RC - libopts_cv_test_dev_zero=`exec 2> /dev/null -dzero=\`ls -lL /dev/zero | egrep ^c......r\` -test -z "${dzero}" && exit 1 -echo ${dzero}` - if test $? -ne 0 - then libopts_cv_test_dev_zero=no - elif test -z "$libopts_cv_test_dev_zero" - then libopts_cv_test_dev_zero=no - fi +# Compiler flag to generate thread-safe objects. +thread_safe_flag_spec=$lt_thread_safe_flag_spec_RC -fi - # end of CACHE_VAL of libopts_cv_test_dev_zero - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_test_dev_zero}" >&5 -$as_echo "${libopts_cv_test_dev_zero}" >&6; } +# Library versioning type. +version_type=$version_type - if test "X${libopts_cv_test_dev_zero}" != Xno - then +# Format of library name prefix. +libname_spec=$lt_libname_spec -$as_echo "#define HAVE_DEV_ZERO 1" >>confdefs.h +# List of archive names. First name is the real one, the rest are links. +# The last name is the one that the linker finds with -lNAME. +library_names_spec=$lt_library_names_spec - fi +# The coded name of the library, if different from the real name. +soname_spec=$lt_soname_spec +# Commands used to build and install an old-style archive. +RANLIB=$lt_RANLIB +old_archive_cmds=$lt_old_archive_cmds_RC +old_postinstall_cmds=$lt_old_postinstall_cmds +old_postuninstall_cmds=$lt_old_postuninstall_cmds +# Create an old-style archive from a shared archive. +old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_RC - # Check to see if we have a functional realpath(3C). +# Create a temporary old-style archive to link instead of a shared archive. +old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_RC - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we have a functional realpath(3C)" >&5 -$as_echo_n "checking whether we have a functional realpath(3C)... " >&6; } - if test "${libopts_cv_run_realpath+set}" = set; then : - $as_echo_n "(cached) " >&6 -else +# Commands used to build and install a shared archive. +archive_cmds=$lt_archive_cmds_RC +archive_expsym_cmds=$lt_archive_expsym_cmds_RC +postinstall_cmds=$lt_postinstall_cmds +postuninstall_cmds=$lt_postuninstall_cmds - if test "$cross_compiling" = yes; then : - libopts_cv_run_realpath=no +# Commands used to build a loadable module (assumed same as above if empty) +module_cmds=$lt_module_cmds_RC +module_expsym_cmds=$lt_module_expsym_cmds_RC -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -int main (int argc, char** argv) { -#ifndef PATH_MAX -choke me!! -#else - char zPath[PATH_MAX+1]; -#endif - char *pz = realpath(argv[0], zPath); - return (pz == zPath) ? 0 : 1; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - libopts_cv_run_realpath=yes -else - libopts_cv_run_realpath=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - # end of TRY_RUN +# Commands to strip libraries. +old_striplib=$lt_old_striplib +striplib=$lt_striplib -fi - # end of AC_CACHE_VAL for libopts_cv_run_realpath - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_realpath}" >&5 -$as_echo "${libopts_cv_run_realpath}" >&6; } +# Dependencies to place before the objects being linked to create a +# shared library. +predep_objects=$lt_predep_objects_RC - if test "X${libopts_cv_run_realpath}" != Xno - then +# Dependencies to place after the objects being linked to create a +# shared library. +postdep_objects=$lt_postdep_objects_RC -$as_echo "#define HAVE_REALPATH 1" >>confdefs.h +# Dependencies to place before the objects being linked to create a +# shared library. +predeps=$lt_predeps_RC - fi +# Dependencies to place after the objects being linked to create a +# shared library. +postdeps=$lt_postdeps_RC + +# The library search path used internally by the compiler when linking +# a shared library. +compiler_lib_search_path=$lt_compiler_lib_search_path_RC +# Method to check whether dependent libraries are shared objects. +deplibs_check_method=$lt_deplibs_check_method +# Command to use when deplibs_check_method == file_magic. +file_magic_cmd=$lt_file_magic_cmd - # Check to see if strftime() works. +# Flag that allows shared libraries with undefined symbols to be built. +allow_undefined_flag=$lt_allow_undefined_flag_RC - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strftime() works" >&5 -$as_echo_n "checking whether strftime() works... " >&6; } - if test "${libopts_cv_run_strftime+set}" = set; then : - $as_echo_n "(cached) " >&6 -else +# Flag that forces no undefined symbols. +no_undefined_flag=$lt_no_undefined_flag_RC - if test "$cross_compiling" = yes; then : - libopts_cv_run_strftime=no +# Commands used to finish a libtool library installation in a directory. +finish_cmds=$lt_finish_cmds -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -char t_buf[ 64 ]; -int main() { - static char const z[] = "Thursday Aug 28 240"; - struct tm tm; - tm.tm_sec = 36; /* seconds after the minute [0, 61] */ - tm.tm_min = 44; /* minutes after the hour [0, 59] */ - tm.tm_hour = 12; /* hour since midnight [0, 23] */ - tm.tm_mday = 28; /* day of the month [1, 31] */ - tm.tm_mon = 7; /* months since January [0, 11] */ - tm.tm_year = 86; /* years since 1900 */ - tm.tm_wday = 4; /* days since Sunday [0, 6] */ - tm.tm_yday = 239; /* days since January 1 [0, 365] */ - tm.tm_isdst = 1; /* flag for daylight savings time */ - strftime( t_buf, sizeof( t_buf ), "%A %b %d %j", &tm ); - return (strcmp( t_buf, z ) != 0); } -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - libopts_cv_run_strftime=yes -else - libopts_cv_run_strftime=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - # end of TRY_RUN +# Same as above, but a single script fragment to be evaled but not shown. +finish_eval=$lt_finish_eval + +# Take the output of nm and produce a listing of raw symbols and C names. +global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe + +# Transform the output of nm in a proper C declaration +global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl + +# Transform the output of nm in a C name address pair +global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address + +# This is the shared library runtime path variable. +runpath_var=$runpath_var + +# This is the shared library path variable. +shlibpath_var=$shlibpath_var -fi - # end of AC_CACHE_VAL for libopts_cv_run_strftime - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_strftime}" >&5 -$as_echo "${libopts_cv_run_strftime}" >&6; } +# Is shlibpath searched before the hard-coded library search path? +shlibpath_overrides_runpath=$shlibpath_overrides_runpath - if test "X${libopts_cv_run_strftime}" != Xno - then +# How to hardcode a shared library path into an executable. +hardcode_action=$hardcode_action_RC -$as_echo "#define HAVE_STRFTIME 1" >>confdefs.h +# Whether we should hardcode library paths into libraries. +hardcode_into_libs=$hardcode_into_libs - fi +# Flag to hardcode \$libdir into a binary during linking. +# This must work even if \$libdir does not exist. +hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_RC +# If ld is used when linking, flag to hardcode \$libdir into +# a binary during linking. This must work even if \$libdir does +# not exist. +hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_RC +# Whether we need a single -rpath flag with a separated argument. +hardcode_libdir_separator=$lt_hardcode_libdir_separator_RC - # Check to see if fopen accepts "b" mode. +# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the +# resulting binary. +hardcode_direct=$hardcode_direct_RC - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fopen accepts \"b\" mode" >&5 -$as_echo_n "checking whether fopen accepts \"b\" mode... " >&6; } - if test "${libopts_cv_run_fopen_binary+set}" = set; then : - $as_echo_n "(cached) " >&6 -else +# Set to yes if using the -LDIR flag during linking hardcodes DIR into the +# resulting binary. +hardcode_minus_L=$hardcode_minus_L_RC - if test "$cross_compiling" = yes; then : - libopts_cv_run_fopen_binary=no +# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into +# the resulting binary. +hardcode_shlibpath_var=$hardcode_shlibpath_var_RC -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -int main (int argc, char** argv) { -FILE* fp = fopen("conftest.$ac_ext", "rb"); -return (fp == NULL) ? 1 : fclose(fp); } -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - libopts_cv_run_fopen_binary=yes -else - libopts_cv_run_fopen_binary=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - # end of TRY_RUN +# Set to yes if building a shared library automatically hardcodes DIR into the library +# and all subsequent libraries and executables linked against it. +hardcode_automatic=$hardcode_automatic_RC -fi - # end of AC_CACHE_VAL for libopts_cv_run_fopen_binary - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_fopen_binary}" >&5 -$as_echo "${libopts_cv_run_fopen_binary}" >&6; } +# Variables whose values should be saved in libtool wrapper scripts and +# restored at relink time. +variables_saved_for_relink="$variables_saved_for_relink" - if test "X${libopts_cv_run_fopen_binary}" != Xno - then +# Whether libtool must link a program against all its dependency libraries. +link_all_deplibs=$link_all_deplibs_RC -$as_echo "#define FOPEN_BINARY_FLAG \"b\"" >>confdefs.h +# Compile-time system search path for libraries +sys_lib_search_path_spec=$lt_sys_lib_search_path_spec - else +# Run-time system search path for libraries +sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec -$as_echo "#define FOPEN_BINARY_FLAG \"\"" >>confdefs.h +# Fix the shell variable \$srcfile for the compiler. +fix_srcfile_path="$fix_srcfile_path_RC" - fi +# Set to yes if exported symbols are required. +always_export_symbols=$always_export_symbols_RC +# The commands to list exported symbols. +export_symbols_cmds=$lt_export_symbols_cmds_RC +# The commands to extract the exported symbol list from a shared archive. +extract_expsyms_cmds=$lt_extract_expsyms_cmds - # Check to see if fopen accepts "t" mode. +# Symbols that should not be listed in the preloaded symbols. +exclude_expsyms=$lt_exclude_expsyms_RC - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fopen accepts \"t\" mode" >&5 -$as_echo_n "checking whether fopen accepts \"t\" mode... " >&6; } - if test "${libopts_cv_run_fopen_text+set}" = set; then : - $as_echo_n "(cached) " >&6 -else +# Symbols that must always be exported. +include_expsyms=$lt_include_expsyms_RC + +# ### END LIBTOOL TAG CONFIG: $tagname + +__EOF__ - if test "$cross_compiling" = yes; then : - libopts_cv_run_fopen_text=no else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -int main (int argc, char** argv) { -FILE* fp = fopen("conftest.$ac_ext", "rt"); -return (fp == NULL) ? 1 : fclose(fp); } -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - libopts_cv_run_fopen_text=yes -else - libopts_cv_run_fopen_text=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext + # If there is no Makefile yet, we rely on a make rule to execute + # `config.status --recheck' to rerun these tests and create the + # libtool script then. + ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` + if test -f "$ltmain_in"; then + test -f Makefile && make "$ltmain" + fi fi - # end of TRY_RUN -fi - # end of AC_CACHE_VAL for libopts_cv_run_fopen_text - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_fopen_text}" >&5 -$as_echo "${libopts_cv_run_fopen_text}" >&6; } - if test "X${libopts_cv_run_fopen_text}" != Xno - then +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu -$as_echo "#define FOPEN_TEXT_FLAG \"t\"" >>confdefs.h +CC="$lt_save_CC" - else + ;; -$as_echo "#define FOPEN_TEXT_FLAG \"\"" >>confdefs.h + *) + as_fn_error "Unsupported tag name: $tagname" "$LINENO" 5 + ;; + esac + + # Append the new tag name to the list of available tags. + if test -n "$tagname" ; then + available_tags="$available_tags $tagname" + fi + fi + done + IFS="$lt_save_ifs" + # Now substitute the updated list of available tags. + if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then + mv "${ofile}T" "$ofile" + chmod +x "$ofile" + else + rm -f "${ofile}T" + as_fn_error "unable to update list of available tagged configurations." "$LINENO" 5 fi +fi - # Check to see if not wanting optional option args. +# This can be used to rebuild libtool when needed +LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh" - # Check whether --enable-optional-args was given. -if test "${enable_optional_args+set}" = set; then : - enableval=$enable_optional_args; libopts_cv_enable_optional_args=${enable_optional_args} -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether not wanting optional option args" >&5 -$as_echo_n "checking whether not wanting optional option args... " >&6; } -if test "${libopts_cv_enable_optional_args+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - libopts_cv_enable_optional_args=yes -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_enable_optional_args" >&5 -$as_echo "$libopts_cv_enable_optional_args" >&6; } +# Always use our own libtool. +LIBTOOL='$(SHELL) $(top_builddir)/libtool' -fi - # end of AC_ARG_ENABLE +# Prevent multiple expansion - if test "X${libopts_cv_enable_optional_args}" = Xno - then -$as_echo "#define NO_OPTIONAL_OPT_ARGS 1" >>confdefs.h - fi - else -if test X${INVOKE_LIBOPTS_MACROS_FIRST_done} != Xyes ; then - # ================= - # AC_HEADER_STDC - # ================= - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 -$as_echo_n "checking for ANSI C header files... " >&6; } -if test "${ac_cv_header_stdc+set}" = set; then : + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for directory path separator" >&5 +$as_echo_n "checking for directory path separator... " >&6; } +if test "${ac_cv_dir_sep+set}" = set; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#include -#include -int -main () -{ + case "$ac_cv_dir_sep" in + '') + case "$target_os" in + *djgpp | *mingw32* | *emx*) ac_cv_dir_sep="'\\'" ;; + *) ac_cv_dir_sep="'/'" ;; + esac + ;; + esac - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_header_stdc=yes -else - ac_cv_header_stdc=no fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_dir_sep" >&5 +$as_echo "$ac_cv_dir_sep" >&6; } +cat >>confdefs.h <<_ACEOF +#define DIR_SEP $ac_cv_dir_sep _ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then : - -else - ac_cv_header_stdc=no -fi -rm -f conftest* -fi -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include +# Checks for libraries. -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then : +ac_fn_c_check_func "$LINENO" "gethostent" "ac_cv_func_gethostent" +if test "x$ac_cv_func_gethostent" = x""yes; then : else - ac_cv_header_stdc=no -fi -rm -f conftest* - -fi - -if test $ac_cv_header_stdc = yes; then - # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. - if test "$cross_compiling" = yes; then : - : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostent" >&5 +$as_echo_n "checking for library containing gethostent... " >&6; } +if test "${ac_cv_search_gethostent+set}" = set; then : + $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include -#if ((' ' & 0x0FF) == 0x020) -# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') -# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) -#else -# define ISLOWER(c) \ - (('a' <= (c) && (c) <= 'i') \ - || ('j' <= (c) && (c) <= 'r') \ - || ('s' <= (c) && (c) <= 'z')) -# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) -#endif -#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char gethostent (); int main () { - int i; - for (i = 0; i < 256; i++) - if (XOR (islower (i), ISLOWER (i)) - || toupper (i) != TOUPPER (i)) - return 2; +return gethostent (); + ; return 0; } _ACEOF -if ac_fn_c_try_run "$LINENO"; then : - -else - ac_cv_header_stdc=no +for ac_lib in '' nsl; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $libxnet -lsocket $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_gethostent=$ac_res fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if test "${ac_cv_search_gethostent+set}" = set; then : + break fi +done +if test "${ac_cv_search_gethostent+set}" = set; then : +else + ac_cv_search_gethostent=no fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 -$as_echo "$ac_cv_header_stdc" >&6; } -if test $ac_cv_header_stdc = yes; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostent" >&5 +$as_echo "$ac_cv_search_gethostent" >&6; } +ac_res=$ac_cv_search_gethostent +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" -$as_echo "#define STDC_HEADERS 1" >>confdefs.h +fi fi - # ================= - # AC_HEADER_DIRENT - # ================= - ac_header_dirent=no -for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do - as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5 -$as_echo_n "checking for $ac_hdr that defines DIR... " >&6; } -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then : +ac_fn_c_check_func "$LINENO" "openlog" "ac_cv_func_openlog" +if test "x$ac_cv_func_openlog" = x""yes; then : + +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing openlog" >&5 +$as_echo_n "checking for library containing openlog... " >&6; } +if test "${ac_cv_search_openlog+set}" = set; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include <$ac_hdr> +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char openlog (); int main () { -if ((DIR *) 0) -return 0; +return openlog (); ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - eval "$as_ac_Header=yes" -else - eval "$as_ac_Header=no" +for ac_lib in '' gen; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_openlog=$ac_res fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if test "${ac_cv_search_openlog+set}" = set; then : + break fi -eval ac_res=\$$as_ac_Header - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 -_ACEOF +done +if test "${ac_cv_search_openlog+set}" = set; then : -ac_header_dirent=$ac_hdr; break +else + ac_cv_search_openlog=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_openlog" >&5 +$as_echo "$ac_cv_search_openlog" >&6; } +ac_res=$ac_cv_search_openlog +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" -done -# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. -if test $ac_header_dirent = dirent.h; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 -$as_echo_n "checking for library containing opendir... " >&6; } -if test "${ac_cv_search_opendir+set}" = set; then : +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing openlog" >&5 +$as_echo_n "checking for library containing openlog... " >&6; } +if test "${ac_cv_search_openlog+set}" = set; then : $as_echo_n "(cached) " >&6 else ac_func_search_save_LIBS=$LIBS @@ -14074,51 +15854,55 @@ #ifdef __cplusplus extern "C" #endif -char opendir (); +char openlog (); int main () { -return opendir (); +return openlog (); ; return 0; } _ACEOF -for ac_lib in '' dir; do +for ac_lib in '' syslog; do if test -z "$ac_lib"; then ac_res="none required" else ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" + LIBS="-l$ac_lib $libxnet -lsocket $ac_func_search_save_LIBS" fi if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_opendir=$ac_res + ac_cv_search_openlog=$ac_res fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext - if test "${ac_cv_search_opendir+set}" = set; then : + if test "${ac_cv_search_openlog+set}" = set; then : break fi done -if test "${ac_cv_search_opendir+set}" = set; then : +if test "${ac_cv_search_openlog+set}" = set; then : else - ac_cv_search_opendir=no + ac_cv_search_openlog=no fi rm conftest.$ac_ext LIBS=$ac_func_search_save_LIBS fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 -$as_echo "$ac_cv_search_opendir" >&6; } -ac_res=$ac_cv_search_opendir +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_openlog" >&5 +$as_echo "$ac_cv_search_openlog" >&6; } +ac_res=$ac_cv_search_openlog if test "$ac_res" != no; then : test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" fi -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 -$as_echo_n "checking for library containing opendir... " >&6; } -if test "${ac_cv_search_opendir+set}" = set; then : +fi + +fi + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setsockopt" >&5 +$as_echo_n "checking for library containing setsockopt... " >&6; } +if test "${ac_cv_search_setsockopt+set}" = set; then : $as_echo_n "(cached) " >&6 else ac_func_search_save_LIBS=$LIBS @@ -14131,16 +15915,16 @@ #ifdef __cplusplus extern "C" #endif -char opendir (); +char setsockopt (); int main () { -return opendir (); +return setsockopt (); ; return 0; } _ACEOF -for ac_lib in '' x; do +for ac_lib in '' socket xnet; do if test -z "$ac_lib"; then ac_res="none required" else @@ -14148,40 +15932,145 @@ LIBS="-l$ac_lib $ac_func_search_save_LIBS" fi if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_opendir=$ac_res + ac_cv_search_setsockopt=$ac_res fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext - if test "${ac_cv_search_opendir+set}" = set; then : + if test "${ac_cv_search_setsockopt+set}" = set; then : break fi done -if test "${ac_cv_search_opendir+set}" = set; then : +if test "${ac_cv_search_setsockopt+set}" = set; then : + +else + ac_cv_search_setsockopt=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_setsockopt" >&5 +$as_echo "$ac_cv_search_setsockopt" >&6; } +ac_res=$ac_cv_search_setsockopt +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + + +# Checks for header files. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 +$as_echo_n "checking for ANSI C header files... " >&6; } +if test "${ac_cv_header_stdc+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#include +#include + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_header_stdc=yes +else + ac_cv_header_stdc=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +if test $ac_cv_header_stdc = yes; then + # SunOS 4.x string.h does not declare mem*, contrary to ANSI. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "memchr" >/dev/null 2>&1; then : + +else + ac_cv_header_stdc=no +fi +rm -f conftest* + +fi + +if test $ac_cv_header_stdc = yes; then + # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "free" >/dev/null 2>&1; then : + +else + ac_cv_header_stdc=no +fi +rm -f conftest* + +fi + +if test $ac_cv_header_stdc = yes; then + # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. + if test "$cross_compiling" = yes; then : + : +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#if ((' ' & 0x0FF) == 0x020) +# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') +# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) +#else +# define ISLOWER(c) \ + (('a' <= (c) && (c) <= 'i') \ + || ('j' <= (c) && (c) <= 'r') \ + || ('s' <= (c) && (c) <= 'z')) +# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) +#endif + +#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) +int +main () +{ + int i; + for (i = 0; i < 256; i++) + if (XOR (islower (i), ISLOWER (i)) + || toupper (i) != TOUPPER (i)) + return 2; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : else - ac_cv_search_opendir=no + ac_cv_header_stdc=no fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 -$as_echo "$ac_cv_search_opendir" >&6; } -ac_res=$ac_cv_search_opendir -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" fi - fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 +$as_echo "$ac_cv_header_stdc" >&6; } +if test $ac_cv_header_stdc = yes; then +$as_echo "#define STDC_HEADERS 1" >>confdefs.h - # ================= - # AC_CHECK_HEADERS - # ================= - for ac_header in dlfcn.h errno.h fcntl.h libgen.h memory.h netinet/in.h \ - setjmp.h sys/mman.h sys/param.h sys/poll.h sys/procset.h sys/select.h \ - sys/socket.h sys/stropts.h sys/time.h sys/un.h sys/wait.h unistd.h \ - utime.h sysexits.h +fi + +for ac_header in netdb.h netinet/in.h stdlib.h string.h strings.h syslog.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" @@ -14195,22 +16084,7 @@ done - - # -------------------------------------------- - # Verify certain entries from AC_CHECK_HEADERS - # -------------------------------------------- - for f in sys_types sys_mman sys_param sys_stat sys_wait \ - string errno stdlib memory setjmp - do eval as_ac_var=\${ac_cv_header_${f}_h+set} - test "${as_ac_var}" = set || \ - as_fn_error "You must have ${f}.h on your system" "$LINENO" 5 - done - - # ================================================ - # AC_CHECK_HEADERS: stdarg.h is present define HAVE_STDARG_H, otherwise - # if varargs.h is present define HAVE_VARARGS_H. - # ================================================ - for ac_header in stdarg.h varargs.h +for ac_header in sys/socket.h sys/time.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" @@ -14219,200 +16093,369 @@ cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF - break + fi done - if test `eval echo '${'$as_ac_Header'}'` != yes; then - as_fn_error "You must have stdarg.h or varargs.h on your system" "$LINENO" 5 - fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5 +$as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; } +if test "${ac_cv_header_time+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#include - # ================================================ - # Similarly for the string.h and strings.h headers - # ================================================ - for ac_header in string.h strings.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +int +main () +{ +if ((struct tm *) 0) +return 0; + ; + return 0; +} _ACEOF - break +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_header_time=yes +else + ac_cv_header_time=no fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5 +$as_echo "$ac_cv_header_time" >&6; } +if test $ac_cv_header_time = yes; then -done - - if test `eval echo '${'$as_ac_Header'}'` != yes; then - as_fn_error "You must have string.h or strings.h on your system" "$LINENO" 5 - fi +$as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h - # ===================== - # ...and limits headers - # ===================== - for ac_header in limits.h sys/limits.h values.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - break fi -done - if test `eval echo '${'$as_ac_Header'}'` != yes; then - as_fn_error "You must have one of limits.h, sys/limits.h or values.h" "$LINENO" 5 - fi +# Checks for typedefs, structures, and compiler characteristics. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5 +$as_echo_n "checking for stdbool.h that conforms to C99... " >&6; } +if test "${ac_cv_header_stdbool_h+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - # ======================== - # ...and int types headers - # ======================== - for ac_header in stdint.h inttypes.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - break -fi +#include +#ifndef bool + "error: bool is not defined" +#endif +#ifndef false + "error: false is not defined" +#endif +#if false + "error: false is not 0" +#endif +#ifndef true + "error: true is not defined" +#endif +#if true != 1 + "error: true is not 1" +#endif +#ifndef __bool_true_false_are_defined + "error: __bool_true_false_are_defined is not defined" +#endif -done + struct s { _Bool s: 1; _Bool t; } s; - ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "$ac_includes_default" -if test "x$ac_cv_type_int8_t" = x""yes; then : + char a[true == 1 ? 1 : -1]; + char b[false == 0 ? 1 : -1]; + char c[__bool_true_false_are_defined == 1 ? 1 : -1]; + char d[(bool) 0.5 == true ? 1 : -1]; + bool e = &s; + char f[(_Bool) 0.0 == false ? 1 : -1]; + char g[true]; + char h[sizeof (_Bool)]; + char i[sizeof s.t]; + enum { j = false, k = true, l = false * true, m = true * 256 }; + /* The following fails for + HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */ + _Bool n[m]; + char o[sizeof n == m * sizeof n[0] ? 1 : -1]; + char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1]; +# if defined __xlc__ || defined __GNUC__ + /* Catch a bug in IBM AIX xlc compiler version 6.0.0.0 + reported by James Lemley on 2005-10-05; see + http://lists.gnu.org/archive/html/bug-coreutils/2005-10/msg00086.html + This test is not quite right, since xlc is allowed to + reject this program, as the initializer for xlcbug is + not one of the forms that C requires support for. + However, doing the test right would require a runtime + test, and that would make cross-compilation harder. + Let us hope that IBM fixes the xlc bug, and also adds + support for this kind of constant expression. In the + meantime, this test will reject xlc, which is OK, since + our stdbool.h substitute should suffice. We also test + this with GCC, where it should work, to detect more + quickly whether someone messes up the test in the + future. */ + char digs[] = "0123456789"; + int xlcbug = 1 / (&(digs + 5)[-2 + (bool) 1] == &digs[4] ? 1 : -1); +# endif + /* Catch a bug in an HP-UX C compiler. See + http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html + http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html + */ + _Bool q = true; + _Bool *pq = &q; -cat >>confdefs.h <<_ACEOF -#define HAVE_INT8_T 1 -_ACEOF +int +main () +{ + *pq |= q; + *pq |= ! q; + /* Refer to every declared value, to avoid compiler optimizations. */ + return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l + + !m + !n + !o + !p + !q + !pq); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_header_stdbool_h=yes +else + ac_cv_header_stdbool_h=no fi -ac_fn_c_check_type "$LINENO" "uint8_t" "ac_cv_type_uint8_t" "$ac_includes_default" -if test "x$ac_cv_type_uint8_t" = x""yes; then : +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5 +$as_echo "$ac_cv_header_stdbool_h" >&6; } +ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default" +if test "x$ac_cv_type__Bool" = x""yes; then : cat >>confdefs.h <<_ACEOF -#define HAVE_UINT8_T 1 +#define HAVE__BOOL 1 _ACEOF fi -ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "$ac_includes_default" -if test "x$ac_cv_type_int16_t" = x""yes; then : -cat >>confdefs.h <<_ACEOF -#define HAVE_INT16_T 1 -_ACEOF +if test $ac_cv_header_stdbool_h = yes; then +$as_echo "#define HAVE_STDBOOL_H 1" >>confdefs.h fi -ac_fn_c_check_type "$LINENO" "uint16_t" "ac_cv_type_uint16_t" "$ac_includes_default" -if test "x$ac_cv_type_uint16_t" = x""yes; then : -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT16_T 1 -_ACEOF +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 +$as_echo_n "checking for an ANSI C-conforming const... " >&6; } +if test "${ac_cv_c_const+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +int +main () +{ +/* FIXME: Include the comments suggested by Paul. */ +#ifndef __cplusplus + /* Ultrix mips cc rejects this. */ + typedef int charset[2]; + const charset cs; + /* SunOS 4.1.1 cc rejects this. */ + char const *const *pcpcc; + char **ppc; + /* NEC SVR4.0.2 mips cc rejects this. */ + struct point {int x, y;}; + static struct point const zero = {0,0}; + /* AIX XL C 1.02.0.0 rejects this. + It does not let you subtract one const X* pointer from another in + an arm of an if-expression whose if-part is not a constant + expression */ + const char *g = "string"; + pcpcc = &g + (g ? g-g : 0); + /* HPUX 7.0 cc rejects these. */ + ++pcpcc; + ppc = (char**) pcpcc; + pcpcc = (char const *const *) ppc; + { /* SCO 3.2v4 cc rejects this. */ + char *t; + char const *s = 0 ? (char *) 0 : (char const *) 0; -fi -ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default" -if test "x$ac_cv_type_int32_t" = x""yes; then : + *t++ = 0; + if (s) return 0; + } + { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ + int x[] = {25, 17}; + const int *foo = &x[0]; + ++foo; + } + { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ + typedef const int *iptr; + iptr p = 0; + ++p; + } + { /* AIX XL C 1.02.0.0 rejects this saying + "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ + struct s { int j; const int *ap[3]; }; + struct s *b; b->j = 5; + } + { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ + const int foo = 10; + if (!foo) return 0; + } + return !cs[0] && !zero.x; +#endif -cat >>confdefs.h <<_ACEOF -#define HAVE_INT32_T 1 + ; + return 0; +} _ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_const=yes +else + ac_cv_c_const=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 +$as_echo "$ac_cv_c_const" >&6; } +if test $ac_cv_c_const = no; then +$as_echo "#define const /**/" >>confdefs.h fi -ac_fn_c_check_type "$LINENO" "uint32_t" "ac_cv_type_uint32_t" "$ac_includes_default" -if test "x$ac_cv_type_uint32_t" = x""yes; then : - -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT32_T 1 -_ACEOF +ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" +if test "x$ac_cv_type_size_t" = x""yes; then : -fi -ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "$ac_includes_default" -if test "x$ac_cv_type_intptr_t" = x""yes; then : +else cat >>confdefs.h <<_ACEOF -#define HAVE_INTPTR_T 1 +#define size_t unsigned int _ACEOF - fi -ac_fn_c_check_type "$LINENO" "uint_t" "ac_cv_type_uint_t" "$ac_includes_default" -if test "x$ac_cv_type_uint_t" = x""yes; then : -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT_T 1 -_ACEOF +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 +$as_echo_n "checking for inline... " >&6; } +if test "${ac_cv_c_inline+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + ac_cv_c_inline=no +for ac_kw in inline __inline__ __inline; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifndef __cplusplus +typedef int foo_t; +static $ac_kw foo_t static_foo () {return 0; } +$ac_kw foo_t foo () {return 0; } +#endif +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_inline=$ac_kw fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + test "$ac_cv_c_inline" != no && break +done +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 +$as_echo "$ac_cv_c_inline" >&6; } - # ==================== - # uintptr type & sizes - # ==================== - ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default" -if test "x$ac_cv_type_uintptr_t" = x""yes; then : - -cat >>confdefs.h <<_ACEOF -#define HAVE_UINTPTR_T 1 +case $ac_cv_c_inline in + inline | yes) ;; + *) + case $ac_cv_c_inline in + no) ac_val=;; + *) ac_val=$ac_cv_c_inline;; + esac + cat >>confdefs.h <<_ACEOF +#ifndef __cplusplus +#define inline $ac_val +#endif _ACEOF + ;; +esac -else +case "$ac_cv_c_inline" in + '') + ;; + *) + +$as_echo "#define HAVE_INLINE 1" >>confdefs.h + -$as_echo "#define uintptr_t unsigned long" >>confdefs.h +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5 +$as_echo_n "checking whether char is unsigned... " >&6; } +if test "${ac_cv_c_char_unsigned+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ +static int test_array [1 - 2 * !(((char) -1) < 0)]; +test_array [0] = 0 + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_char_unsigned=no +else + ac_cv_c_char_unsigned=yes fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_char_unsigned" >&5 +$as_echo "$ac_cv_c_char_unsigned" >&6; } +if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then + $as_echo "#define __CHAR_UNSIGNED__ 1" >>confdefs.h - # The cast to long int works around a bug in the HP C Compiler +fi + # The cast to long int works around a bug in the HP C Compiler # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. # This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of char*" >&5 -$as_echo_n "checking size of char*... " >&6; } -if test "${ac_cv_sizeof_charp+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of signed char" >&5 +$as_echo_n "checking size of signed char... " >&6; } +if test "${ac_cv_sizeof_signed_char+set}" = set; then : $as_echo_n "(cached) " >&6 else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char*))" "ac_cv_sizeof_charp" "$ac_includes_default"; then : + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (signed char))" "ac_cv_sizeof_signed_char" "$ac_includes_default"; then : else - if test "$ac_cv_type_charp" = yes; then + if test "$ac_cv_type_signed_char" = yes; then { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} { as_fn_set_status 77 -as_fn_error "cannot compute sizeof (char*) +as_fn_error "cannot compute sizeof (signed char) See \`config.log' for more details." "$LINENO" 5; }; } else - ac_cv_sizeof_charp=0 + ac_cv_sizeof_signed_char=0 fi fi fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_charp" >&5 -$as_echo "$ac_cv_sizeof_charp" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_signed_char" >&5 +$as_echo "$ac_cv_sizeof_signed_char" >&6; } cat >>confdefs.h <<_ACEOF -#define SIZEOF_CHARP $ac_cv_sizeof_charp +#define SIZEOF_SIGNED_CHAR $ac_cv_sizeof_signed_char _ACEOF - # The cast to long int works around a bug in the HP C Compiler +# The cast to long int works around a bug in the HP C Compiler # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. # This bug is HP SR number 8606223364. @@ -14446,7 +16489,7 @@ _ACEOF - # The cast to long int works around a bug in the HP C Compiler +# The cast to long int works around a bug in the HP C Compiler # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. # This bug is HP SR number 8606223364. @@ -14480,891 +16523,1257 @@ _ACEOF - # The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 -$as_echo_n "checking size of short... " >&6; } -if test "${ac_cv_sizeof_short+set}" = set; then : + +ac_fn_c_check_type "$LINENO" "s_char" "ac_cv_type_s_char" "$ac_includes_default" +if test "x$ac_cv_type_s_char" = x""yes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_S_CHAR 1 +_ACEOF + + +fi + +case "$ac_cv_c_char_unsigned$ac_cv_sizeof_signed_char$ac_cv_type_s_char" in + *yes) + # We have a typedef for s_char. Might as well believe it... + ;; + no0no) + # We have signed chars, can't say 'signed char', no s_char typedef. + +$as_echo "#define NEED_S_CHAR_TYPEDEF 1" >>confdefs.h + + ;; + no1no) + # We have signed chars, can say 'signed char', no s_char typedef. + $as_echo "#define NEED_S_CHAR_TYPEDEF 1" >>confdefs.h + + ;; + yes0no) + # We have unsigned chars, can't say 'signed char', no s_char typedef. + as_fn_error "No way to specify a signed character!" "$LINENO" 5 + ;; + yes1no) + # We have unsigned chars, can say 'signed char', no s_char typedef. + $as_echo "#define NEED_S_CHAR_TYPEDEF 1" >>confdefs.h + + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5 +$as_echo_n "checking for uid_t in sys/types.h... " >&6; } +if test "${ac_cv_type_uid_t+set}" = set; then : $as_echo_n "(cached) " >&6 else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short" "$ac_includes_default"; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "uid_t" >/dev/null 2>&1; then : + ac_cv_type_uid_t=yes else - if test "$ac_cv_type_short" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (short) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_short=0 - fi + ac_cv_type_uid_t=no fi +rm -f conftest* fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 -$as_echo "$ac_cv_sizeof_short" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5 +$as_echo "$ac_cv_type_uid_t" >&6; } +if test $ac_cv_type_uid_t = no; then +$as_echo "#define uid_t int" >>confdefs.h -cat >>confdefs.h <<_ACEOF -#define SIZEOF_SHORT $ac_cv_sizeof_short +$as_echo "#define gid_t int" >>confdefs.h + +fi + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for openssl library directory" >&5 +$as_echo_n "checking for openssl library directory... " >&6; } + +# Check whether --with-openssl-libdir was given. +if test "${with_openssl_libdir+set}" = set; then : + withval=$with_openssl_libdir; ans=$withval +else + case "$build" in + $host) ans=yes ;; + *) ans=no ;; +esac +fi + +case "$ans" in + no) ;; + yes) # Look in: + ans="/usr/lib /usr/lib/openssl /usr/sfw/lib /usr/local/lib /usr/local/ssl/lib /lib" + ;; + *) # Look where they said + ;; +esac +case "$ans" in + no) ;; + *) # Look for libcrypto.a and libssl.a: + for i in $ans no + do + case "$host" in + *-*-darwin*) + test -f $i/libcrypto.dylib -a -f $i/libssl.dylib && break + ;; + *) + test -f $i/libcrypto.so -a -f $i/libssl.so && break + test -f $i/libcrypto.a -a -f $i/libssl.a && break + ;; + esac + done + case "$i" in + no) + ans=no + OPENSSL_LIB= + ;; + *) ans=$i + OPENSSL_LIB=$ans + ;; + esac + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for openssl include directory" >&5 +$as_echo_n "checking for openssl include directory... " >&6; } + +# Check whether --with-openssl-incdir was given. +if test "${with_openssl_incdir+set}" = set; then : + withval=$with_openssl_incdir; ans=$withval +else + case "$build" in + $host) ans=yes ;; + *) ans=no ;; +esac +fi + +case "$ans" in + no) ;; + yes) # look in: + ans="/usr/include /usr/sfw/include /usr/local/include /usr/local/ssl/include" + ;; + *) # Look where they said + ;; +esac +case "$ans" in + no) ;; + *) # look for openssl/opensslconf.h: + for i in $ans no + do + test -f $i/openssl/opensslconf.h && break + done + case "$i" in + no) + ans=no + OPENSSL_INC= + ;; + *) ans=$i + OPENSSL_INC=$ans + ;; + esac + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we will use crypto" >&5 +$as_echo_n "checking if we will use crypto... " >&6; } + +# Check whether --with-crypto was given. +if test "${with_crypto+set}" = set; then : + withval=$with_crypto; ans=$withval +else + ans=yes +fi + +case "$ans" in + no) + ;; + yes|openssl) + if test -z "$OPENSSL_LIB" -o -z "$OPENSSL_INC" + then + ans=no + else + ans=yes + fi +esac +ntp_openssl=$ans +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } + +case "$ntp_openssl" in + yes) + # We have OpenSSL inc/lib - use them. + CPPFLAGS="$CPPFLAGS -I$OPENSSL_INC" + LDFLAGS="$LDFLAGS -L$OPENSSL_LIB" + case "$need_dash_r" in + 1) LDFLAGS="$LDFLAGS -R$OPENSSL_LIB" + esac + LCRYPTO=-lcrypto + + +$as_echo "#define OPENSSL /**/" >>confdefs.h + +esac + +# +# Older OpenSSL headers have a number of callback prototypes inside +# other function prototypes which trigger copious warnings with gcc's +# -Wstrict-prototypes, which is included in -Wall. +# +# An example: +# +# int i2d_RSA_NET(const RSA *a, unsigned char **pp, +# int (*cb)(), int sgckey); +# ^^^^^^^^^^^ +# +# +# +openssl_triggers_warnings=unknown +SAVED_CFLAGS="$CFLAGS" + +case "$GCC$ntp_openssl" in + yesyes) + CFLAGS="$CFLAGS -Werror" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + /* see if -Werror breaks gcc */ _ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + gcc_handles_Werror=yes +else + gcc_handles_Werror=no + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + case "$gcc_handles_Werror" in + no) + # if this gcc doesn't do -Werror go ahead and use + # -Wstrict-prototypes. + openssl_triggers_warnings=yes + ;; + yes) + CFLAGS="$CFLAGS -Wstrict-prototypes" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + #include "openssl/asn1_mac.h" + #include "openssl/bn.h" + #include "openssl/err.h" + #include "openssl/evp.h" + #include "openssl/pem.h" + #include "openssl/rand.h" + #include "openssl/x509v3.h" +int +main () +{ + /* empty body */ - # ---------------------------------------------------------------------- - # AC_CHECK_LIB for SVR4 libgen, and use it if it defines pathfind. - # ---------------------------------------------------------------------- - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pathfind in -lgen" >&5 -$as_echo_n "checking for pathfind in -lgen... " >&6; } -if test "${ac_cv_lib_gen_pathfind+set}" = set; then : + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + openssl_triggers_warnings=no +else + openssl_triggers_warnings=yes + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + esac + case "$openssl_triggers_warnings" in + yes) + CFLAGS="$SAVED_CFLAGS -Wno-strict-prototypes" + ;; + *) + CFLAGS="$SAVED_CFLAGS -Wstrict-prototypes" + esac + ;; + yesno) + # gcc without OpenSSL + CFLAGS="$SAVED_CFLAGS -Wstrict-prototypes" +esac + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking type of socklen arg for getsockname()" >&5 +$as_echo_n "checking type of socklen arg for getsockname()... " >&6; } +if test "${ac_cv_func_getsockname_arg2+set}" = set; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lgen $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + if test "${ac_cv_func_getsockname_socklen_type+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + for ac_cv_func_getsockname_arg2 in 'struct sockaddr *' 'void *'; do + for ac_cv_func_getsockname_socklen_type in 'socklen_t' 'size_t' 'unsigned int' 'int'; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" +#ifdef HAVE_SYS_TYPES_H +#include +#endif +#ifdef HAVE_SYS_SOCKET_H +#include #endif -char pathfind (); +extern getsockname (int, $ac_cv_func_getsockname_arg2, $ac_cv_func_getsockname_socklen_type *); int main () { -return pathfind (); + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_gen_pathfind=yes +if ac_fn_c_try_compile "$LINENO"; then : + ac_not_found=no ; break 2 else - ac_cv_lib_gen_pathfind=no + ac_not_found=yes fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gen_pathfind" >&5 -$as_echo "$ac_cv_lib_gen_pathfind" >&6; } -if test "x$ac_cv_lib_gen_pathfind" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBGEN 1 -_ACEOF +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + done + done - LIBS="-lgen $LIBS" +fi fi +if test "$ac_not_found" = yes; then + ac_cv_func_getsockname_socklen_type='socklen_t' +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getsockname_socklen_type" >&5 +$as_echo "$ac_cv_func_getsockname_socklen_type" >&6; } - for ac_func in vprintf -do : - ac_fn_c_check_func "$LINENO" "vprintf" "ac_cv_func_vprintf" -if test "x$ac_cv_func_vprintf" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_VPRINTF 1 +cat >>confdefs.h <<_ACEOF +#define GETSOCKNAME_SOCKLEN_TYPE $ac_cv_func_getsockname_socklen_type _ACEOF -ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt" -if test "x$ac_cv_func__doprnt" = x""yes; then : -$as_echo "#define HAVE_DOPRNT 1" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct sockaddr_storage" >&5 +$as_echo_n "checking for struct sockaddr_storage... " >&6; } +if test "${ntp_cv_sockaddr_storage+set}" = set; then : + $as_echo_n "(cached) " >&6 +else -fi + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -fi -done + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif +int +main () +{ - for ac_func in mmap canonicalize_file_name snprintf strdup strchr strrchr -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 + struct sockaddr_storage n; + + ; + return 0; +} _ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_sockaddr_storage="yes" +else + ntp_cv_sockaddr_storage="no" fi -done +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + - INVOKE_LIBOPTS_MACROS_FIRST_done=yes fi - fi -# end of AC_DEFUN of LIBOPTS_CHECK +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_sockaddr_storage" >&5 +$as_echo "$ntp_cv_sockaddr_storage" >&6; } +case "$ntp_cv_sockaddr_storage" in + yes) +$as_echo "#define HAVE_STRUCT_SOCKADDR_STORAGE 1" >>confdefs.h -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC can handle #warning" >&5 -$as_echo_n "checking if $CC can handle #warning... " >&6; } -cat confdefs.h - <<_ACEOF >conftest.$ac_ext +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_storage.ss_family" >&5 +$as_echo_n "checking for sockaddr_storage.ss_family... " >&6; } +if test "${ntp_cv_have_ss_family+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif + int main () { -#warning foo + + struct sockaddr_storage s; + s.ss_family = 1; + ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_cpp_warning=yes + ntp_cv_have_ss_family="yes" else - ac_cv_cpp_warning=no + ntp_cv_have_ss_family="no" + fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cpp_warning" >&5 -$as_echo "$ac_cv_cpp_warning" >&6; } - -case "$ac_cv_cpp_warning" in - no) -$as_echo "#define NO_OPTION_NAME_WARNINGS 1" >>confdefs.h - { $as_echo "$as_me:${as_lineno-$LINENO}: result: Enabling NO_OPTION_NAME_WARNINGS as #warning does not work" >&5 -$as_echo "Enabling NO_OPTION_NAME_WARNINGS as #warning does not work" >&6; } - ;; -esac +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_have_ss_family" >&5 +$as_echo "$ntp_cv_have_ss_family" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 -$as_echo_n "checking for inline... " >&6; } -if test "${ac_cv_c_inline+set}" = set; then : +case "$ntp_cv_have_ss_family" in + no) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_storage.__ss_family" >&5 +$as_echo_n "checking for sockaddr_storage.__ss_family... " >&6; } +if test "${ntp_cv_have___ss_family+set}" = set; then : $as_echo_n "(cached) " >&6 else - ac_cv_c_inline=no -for ac_kw in inline __inline__ __inline; do - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#ifndef __cplusplus -typedef int foo_t; -static $ac_kw foo_t static_foo () {return 0; } -$ac_kw foo_t foo () {return 0; } -#endif -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_c_inline=$ac_kw -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - test "$ac_cv_c_inline" != no && break -done + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 -$as_echo "$ac_cv_c_inline" >&6; } +int +main () +{ -case $ac_cv_c_inline in - inline | yes) ;; - *) - case $ac_cv_c_inline in - no) ac_val=;; - *) ac_val=$ac_cv_c_inline;; - esac - cat >>confdefs.h <<_ACEOF -#ifndef __cplusplus -#define inline $ac_val -#endif + struct sockaddr_storage s; + s.__ss_family = 1; + + ; + return 0; +} _ACEOF - ;; -esac +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_have___ss_family="yes" +else + ntp_cv_have___ss_family="no" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -case "$ac_cv_c_inline" in - '') - ;; - *) -$as_echo "#define HAVE_INLINE 1" >>confdefs.h +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_have___ss_family" >&5 +$as_echo "$ntp_cv_have___ss_family" >&6; } + case "$ntp_cv_have___ss_family" in + yes) +$as_echo "#define HAVE___SS_FAMILY_IN_SS 1" >>confdefs.h + esac esac -# Checks for libraries. -# Checks for header files. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 -$as_echo_n "checking for ANSI C header files... " >&6; } -if test "${ac_cv_header_stdc+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_storage.ss_len" >&5 +$as_echo_n "checking for sockaddr_storage.ss_len... " >&6; } +if test "${ntp_cv_have_ss_len+set}" = set; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include -#include -#include + + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif int main () { + struct sockaddr_storage s; + s.ss_len = 1; + ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_header_stdc=yes + ntp_cv_have_ss_len="yes" else - ac_cv_header_stdc=no + ntp_cv_have_ss_len="no" + fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then : - -else - ac_cv_header_stdc=no -fi -rm -f conftest* fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_have_ss_len" >&5 +$as_echo "$ntp_cv_have_ss_len" >&6; } -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then : - +case "$ntp_cv_have_ss_len" in + no) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_storage.__ss_len" >&5 +$as_echo_n "checking for sockaddr_storage.__ss_len... " >&6; } +if test "${ntp_cv_have___ss_len+set}" = set; then : + $as_echo_n "(cached) " >&6 else - ac_cv_header_stdc=no -fi -rm -f conftest* - -fi -if test $ac_cv_header_stdc = yes; then - # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. - if test "$cross_compiling" = yes; then : - : -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include -#if ((' ' & 0x0FF) == 0x020) -# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') -# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) -#else -# define ISLOWER(c) \ - (('a' <= (c) && (c) <= 'i') \ - || ('j' <= (c) && (c) <= 'r') \ - || ('s' <= (c) && (c) <= 'z')) -# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) -#endif -#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif + int main () { - int i; - for (i = 0; i < 256; i++) - if (XOR (islower (i), ISLOWER (i)) - || toupper (i) != TOUPPER (i)) - return 2; + + struct sockaddr_storage s; + s.__ss_len = 1; + + ; return 0; } _ACEOF -if ac_fn_c_try_run "$LINENO"; then : - +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_have___ss_len="yes" else - ac_cv_header_stdc=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi + ntp_cv_have___ss_len="no" fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 -$as_echo "$ac_cv_header_stdc" >&6; } -if test $ac_cv_header_stdc = yes; then +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -$as_echo "#define STDC_HEADERS 1" >>confdefs.h fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_have___ss_len" >&5 +$as_echo "$ntp_cv_have___ss_len" >&6; } + case "$ntp_cv_have___ss_len" in + yes) -for ac_header in arpa/inet.h fcntl.h float.h limits.h netdb.h netinet/in.h stdlib.h string.h sys/socket.h sys/time.h syslog.h unistd.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +$as_echo "#define HAVE___SS_LEN_IN_SS 1" >>confdefs.h + + esac +esac + + + +# +# Look for in_port_t. +# +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for in_port_t" >&5 +$as_echo_n "checking for in_port_t... " >&6; } +if test "${isc_cv_have_in_port_t+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + #include + +int +main () +{ + + in_port_t port = 25; + return (0); + + ; + return 0; +} _ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + isc_cv_have_in_port_t=yes +else + isc_cv_have_in_port_t=no fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_have_in_port_t" >&5 +$as_echo "$isc_cv_have_in_port_t" >&6; } +case "$isc_cv_have_in_port_t" in + no) -# Checks for typedefs, structures, and compiler characteristics. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 -$as_echo_n "checking for an ANSI C-conforming const... " >&6; } -if test "${ac_cv_c_const+set}" = set; then : +$as_echo "#define ISC_PLATFORM_NEEDPORTT 1" >>confdefs.h + +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for multicast IP support" >&5 +$as_echo_n "checking for multicast IP support... " >&6; } +if test "${ntp_cv_multicast+set}" = set; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + ntp_cv_multicast=no + case "$host" in + i386-sequent-sysv4) + ;; + *) + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ + #ifdef HAVE_NETINET_IN_H + #include + #endif + int main () { -/* FIXME: Include the comments suggested by Paul. */ -#ifndef __cplusplus - /* Ultrix mips cc rejects this. */ - typedef int charset[2]; - const charset cs; - /* SunOS 4.1.1 cc rejects this. */ - char const *const *pcpcc; - char **ppc; - /* NEC SVR4.0.2 mips cc rejects this. */ - struct point {int x, y;}; - static struct point const zero = {0,0}; - /* AIX XL C 1.02.0.0 rejects this. - It does not let you subtract one const X* pointer from another in - an arm of an if-expression whose if-part is not a constant - expression */ - const char *g = "string"; - pcpcc = &g + (g ? g-g : 0); - /* HPUX 7.0 cc rejects these. */ - ++pcpcc; - ppc = (char**) pcpcc; - pcpcc = (char const *const *) ppc; - { /* SCO 3.2v4 cc rejects this. */ - char *t; - char const *s = 0 ? (char *) 0 : (char const *) 0; - *t++ = 0; - if (s) return 0; - } - { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ - int x[] = {25, 17}; - const int *foo = &x[0]; - ++foo; - } - { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ - typedef const int *iptr; - iptr p = 0; - ++p; - } - { /* AIX XL C 1.02.0.0 rejects this saying - "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ - struct s { int j; const int *ap[3]; }; - struct s *b; b->j = 5; - } - { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ - const int foo = 10; - if (!foo) return 0; - } - return !cs[0] && !zero.x; -#endif + struct ip_mreq ipmr; + ipmr.imr_interface.s_addr = 0; + ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_c_const=yes -else - ac_cv_c_const=no + ntp_cv_multicast=yes fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 -$as_echo "$ac_cv_c_const" >&6; } -if test $ac_cv_c_const = no; then + esac -$as_echo "#define const /**/" >>confdefs.h fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_multicast" >&5 +$as_echo "$ntp_cv_multicast" >&6; } -ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" -if test "x$ac_cv_type_size_t" = x""yes; then : +case "$ntp_cv_multicast" in + yes) + +$as_echo "#define MCAST 1" >>confdefs.h + { $as_echo "$as_me:${as_lineno-$LINENO}: checking arg type needed for setsockopt() IP*_MULTICAST_LOOP" >&5 +$as_echo_n "checking arg type needed for setsockopt() IP*_MULTICAST_LOOP... " >&6; } +if test "${ntp_cv_typeof_ip_multicast_loop+set}" = set; then : + $as_echo_n "(cached) " >&6 else + case "$host" in + *-*-netbsd*|*-*-*linux*) + ntp_cv_typeof_ip_multicast_loop=u_int + ;; + *-*-winnt*) + ntp_cv_typeof_ip_multicast_loop=BOOL + ;; + *) + ntp_cv_typeof_ip_multicast_loop=u_char + esac + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_typeof_ip_multicast_loop" >&5 +$as_echo "$ntp_cv_typeof_ip_multicast_loop" >&6; } + cat >>confdefs.h <<_ACEOF -#define size_t unsigned int +#define TYPEOF_IP_MULTICAST_LOOP $ntp_cv_typeof_ip_multicast_loop _ACEOF +esac + +# HMS: We don't need res_init, but since we may be using cached +# values from ntpd we need to test the same way +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing res_init" >&5 +$as_echo_n "checking for library containing res_init... " >&6; } +if test "${ac_cv_search_res_init+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char res_init (); +int +main () +{ +return res_init (); + ; + return 0; +} +_ACEOF +for ac_lib in '' resolv; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib -lsocket -lnsl $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_res_init=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if test "${ac_cv_search_res_init+set}" = set; then : + break fi +done +if test "${ac_cv_search_res_init+set}" = set; then : -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5 -$as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; } -if test "${ac_cv_header_time+set}" = set; then : +else + ac_cv_search_res_init=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_res_init" >&5 +$as_echo "$ac_cv_search_res_init" >&6; } +ac_res=$ac_cv_search_res_init +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_ntop" >&5 +$as_echo_n "checking for library containing inet_ntop... " >&6; } +if test "${ac_cv_search_inet_ntop+set}" = set; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include -#include +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char inet_ntop (); int main () { -if ((struct tm *) 0) -return 0; +return inet_ntop (); ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_header_time=yes +for ac_lib in '' resolv; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib -lsocket -lnsl $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_inet_ntop=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if test "${ac_cv_search_inet_ntop+set}" = set; then : + break +fi +done +if test "${ac_cv_search_inet_ntop+set}" = set; then : + else - ac_cv_header_time=no + ac_cv_search_inet_ntop=no fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5 -$as_echo "$ac_cv_header_time" >&6; } -if test $ac_cv_header_time = yes; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_ntop" >&5 +$as_echo "$ac_cv_search_inet_ntop" >&6; } +ac_res=$ac_cv_search_inet_ntop +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" -$as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h +fi + +ac_fn_c_check_func "$LINENO" "inet_ntop" "ac_cv_func_inet_ntop" +if test "x$ac_cv_func_inet_ntop" = x""yes; then : + +else + +$as_echo "#define ISC_PLATFORM_NEEDNTOP 1" >>confdefs.h fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5 -$as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; } -if test "${ac_cv_struct_tm+set}" = set; then : +ac_fn_c_check_func "$LINENO" "inet_pton" "ac_cv_func_inet_pton" +if test "x$ac_cv_func_inet_pton" = x""yes; then : + +else + +$as_echo "#define ISC_PLATFORM_NEEDPTON 1" >>confdefs.h + +fi + + +# Check whether --enable-ipv6 was given. +if test "${enable_ipv6+set}" = set; then : + enableval=$enable_ipv6; +fi + + +case "$enable_ipv6" in + yes|''|autodetect) + case "$host" in + powerpc-ibm-aix4*) ;; + *) + +$as_echo "#define WANT_IPV6 /**/" >>confdefs.h + + ;; + esac + ;; + no) + ;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for IPv6 structures" >&5 +$as_echo_n "checking for IPv6 structures... " >&6; } +if test "${ac_cv_isc_found_ipv6+set}" = set; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include + + + #include + #include + #include int main () { -struct tm tm; - int *p = &tm.tm_sec; - return !p; + + struct sockaddr_in6 sin6; + + ; return 0; } + _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_struct_tm=time.h + ac_cv_isc_found_ipv6=yes else - ac_cv_struct_tm=sys/time.h + ac_cv_isc_found_ipv6=no + fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_isc_found_ipv6" >&5 +$as_echo "$ac_cv_isc_found_ipv6" >&6; } + +# +# See whether IPv6 support is provided via a Kame add-on. +# This is done before other IPv6 linking tests so LIBS is properly set. +# +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Kame IPv6 support" >&5 +$as_echo_n "checking for Kame IPv6 support... " >&6; } + +# Check whether --with-kame was given. +if test "${with_kame+set}" = set; then : + withval=$with_kame; use_kame="$withval" +else + use_kame="no" fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5 -$as_echo "$ac_cv_struct_tm" >&6; } -if test $ac_cv_struct_tm = sys/time.h; then -$as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h -fi +case "$use_kame" in + no) + ;; + yes) + kame_path=/usr/local/v6 + ;; + *) + kame_path="$use_kame" + ;; +esac + +case "$use_kame" in + no) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + ;; + *) + if test -f $kame_path/lib/libinet6.a; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $kame_path/lib/libinet6.a" >&5 +$as_echo "$kame_path/lib/libinet6.a" >&6; } + LIBS="-L$kame_path/lib -linet6 $LIBS" + else + as_fn_error "$kame_path/lib/libinet6.a not found. + +Please choose the proper path with the following command: + + configure --with-kame=PATH +" "$LINENO" 5 + fi + ;; +esac + +# +# Whether netinet6/in6.h is needed has to be defined in isc/platform.h. +# Including it on Kame-using platforms is very bad, though, because +# Kame uses #error against direct inclusion. So include it on only +# the platform that is otherwise broken without it -- BSD/OS 4.0 through 4.1. +# This is done before the in6_pktinfo check because that's what +# netinet6/in6.h is needed for. +# +case "$host" in + *-bsdi4.[01]*) + +$as_echo "#define ISC_PLATFORM_NEEDNETINET6IN6H 1" >>confdefs.h + + # does anything use LWRES_PLATFORM_NEEDNETINET6IN6H? Can't it use above? + +$as_echo "#define LWRES_PLATFORM_NEEDNETINET6IN6H 1" >>confdefs.h + + isc_netinet6in6_hack="#include " + ;; + *) + isc_netinet6in6_hack="" +esac + +# +# This is similar to the netinet6/in6.h issue. +# +case "$host" in + *-sco-sysv*uw*|*-*-sysv*UnixWare*|*-*-sysv*OpenUNIX*) + +$as_echo "#define ISC_PLATFORM_FIXIN6ISADDR 1" >>confdefs.h + + isc_netinetin6_hack="#include " + ;; + *) + isc_netinetin6_hack="" +esac + + +case "$ac_cv_isc_found_ipv6" in + yes) + +$as_echo "#define ISC_PLATFORM_HAVEIPV6 /**/" >>confdefs.h -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ss_family field in struct sockaddr_storage" >&5 -$as_echo_n "checking for ss_family field in struct sockaddr_storage... " >&6; } -if test "${ac_cv_have_ss_family_in_struct_ss+set}" = set; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for in6_pktinfo" >&5 +$as_echo_n "checking for in6_pktinfo... " >&6; } +if test "${ac_cv_have_in6_pktinfo+set}" = set; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include + + #include + #include + #include + $isc_netinetin6_hack + $isc_netinet6in6_hack int main () { - struct sockaddr_storage s; s.ss_family = 1; + + struct in6_pktinfo xyzzy; + + ; return 0; } + _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_have_ss_family_in_struct_ss="yes" + ac_cv_have_in6_pktinfo=yes else - ac_cv_have_ss_family_in_struct_ss="no" + ac_cv_have_in6_pktinfo=no + fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_ss_family_in_struct_ss" >&5 -$as_echo "$ac_cv_have_ss_family_in_struct_ss" >&6; } -case "$ac_cv_have_ss_family_in_struct_ss" in - yes) +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_in6_pktinfo" >&5 +$as_echo "$ac_cv_have_in6_pktinfo" >&6; } -$as_echo "#define HAVE_SS_FAMILY_IN_SS 1" >>confdefs.h + case "$ac_cv_have_in6_pktinfo" in + yes) - ;; -esac +$as_echo "#define ISC_PLATFORM_HAVEIN6PKTINFO /**/" >>confdefs.h -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for __ss_family field in struct sockaddr_storage" >&5 -$as_echo_n "checking for __ss_family field in struct sockaddr_storage... " >&6; } -if test "${ac_cv_have___ss_family_in_struct_ss+set}" = set; then : + esac + + + # HMS: Use HAVE_STRUCT_SOCKADDR_IN6_SIN6_SCOPE_ID instead? + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_in6.sin6_scope_id" >&5 +$as_echo_n "checking for sockaddr_in6.sin6_scope_id... " >&6; } +if test "${ac_cv_have_sin6_scope_id+set}" = set; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include + + #include + #include + #include + $isc_netinetin6_hack + $isc_netinet6in6_hack int main () { - struct sockaddr_storage s; s.__ss_family = 1; + + struct sockaddr_in6 xyzzy; + xyzzy.sin6_scope_id = 0; + + ; return 0; } + _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_have___ss_family_in_struct_ss="yes" + ac_cv_have_sin6_scope_id=yes else - ac_cv_have___ss_family_in_struct_ss="no" + ac_cv_have_sin6_scope_id=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have___ss_family_in_struct_ss" >&5 -$as_echo "$ac_cv_have___ss_family_in_struct_ss" >&6; } -case "$ac_cv_have___ss_family_in_struct_ss" in - yes) - -$as_echo "#define HAVE___SS_FAMILY_IN_SS 1" >>confdefs.h - - ;; -esac -case "$ac_cv_have_ss_family_in_struct_ss$ac_cv_have___ss_family_in_struct_ss" in - noyes) - -cat >>confdefs.h <<_ACEOF -#define ss_family __ss_family -_ACEOF +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_sin6_scope_id" >&5 +$as_echo "$ac_cv_have_sin6_scope_id" >&6; } + case "$ac_cv_have_sin6_scope_id" in + yes) -cat >>confdefs.h <<_ACEOF -#define ss_len __ss_len -_ACEOF +$as_echo "#define ISC_PLATFORM_HAVESCOPEID /**/" >>confdefs.h - ;; + esac esac -# Checks for library functions. -#AC_FUNC_MEMCMP dnl HMS: we don't have a memcmp.c to use here, so why bother? -if test "${ac_cv_func_setvbuf_reversed+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_func_setvbuf_reversed=no -fi +# We need this check run even without ac_cv_isc_found_ipv6=yes -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5 -$as_echo_n "checking return type of signal handlers... " >&6; } -if test "${ac_cv_type_signal+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for in6addr_any" >&5 +$as_echo_n "checking for in6addr_any... " >&6; } +if test "${isc_cv_have_in6addr_any+set}" = set; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include + + + #include + #include + #include + $isc_netinetin6_hack + $isc_netinet6in6_hack int main () { -return *(signal (0, 0)) (0) == 1; + + struct in6_addr in6; + in6 = in6addr_any; + + ; return 0; } + _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_type_signal=int +if ac_fn_c_try_link "$LINENO"; then : + isc_cv_have_in6addr_any=yes else - ac_cv_type_signal=void -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + isc_cv_have_in6addr_any=no + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5 -$as_echo "$ac_cv_type_signal" >&6; } +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext -cat >>confdefs.h <<_ACEOF -#define RETSIGTYPE $ac_cv_type_signal -_ACEOF +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_have_in6addr_any" >&5 +$as_echo "$isc_cv_have_in6addr_any" >&6; } -for ac_func in alarm -do : - ac_fn_c_check_func "$LINENO" "alarm" "ac_cv_func_alarm" -if test "x$ac_cv_func_alarm" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_ALARM 1 -_ACEOF +case "$isc_cv_have_in6addr_any" in + no) -fi -done +$as_echo "#define ISC_PLATFORM_NEEDIN6ADDRANY /**/" >>confdefs.h -ac_fn_c_check_func "$LINENO" "gethostent" "ac_cv_func_gethostent" -if test "x$ac_cv_func_gethostent" = x""yes; then : +esac -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostent" >&5 -$as_echo_n "checking for library containing gethostent... " >&6; } -if test "${ac_cv_search_gethostent+set}" = set; then : + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct if_laddrconf" >&5 +$as_echo_n "checking for struct if_laddrconf... " >&6; } +if test "${ac_cv_isc_struct_if_laddrconf+set}" = set; then : $as_echo_n "(cached) " >&6 else - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char gethostent (); + + #include + #include + int main () { -return gethostent (); + + struct if_laddrconf a; + + ; return 0; } -_ACEOF -for ac_lib in '' nsl; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib -lsocket $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_gethostent=$ac_res -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext - if test "${ac_cv_search_gethostent+set}" = set; then : - break -fi -done -if test "${ac_cv_search_gethostent+set}" = set; then : +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_isc_struct_if_laddrconf=yes else - ac_cv_search_gethostent=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostent" >&5 -$as_echo "$ac_cv_search_gethostent" >&6; } -ac_res=$ac_cv_search_gethostent -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + ac_cv_isc_struct_if_laddrconf=no fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_isc_struct_if_laddrconf" >&5 +$as_echo "$ac_cv_isc_struct_if_laddrconf" >&6; } -for ac_func in gettimeofday inet_ntoa memset -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF +case "$ac_cv_isc_struct_if_laddrconf" in + yes) -fi -done +$as_echo "#define ISC_PLATFORM_HAVEIF_LADDRCONF /**/" >>confdefs.h -for ac_func in socket -do : - ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket" -if test "x$ac_cv_func_socket" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_SOCKET 1 -_ACEOF +esac -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing socket" >&5 -$as_echo_n "checking for library containing socket... " >&6; } -if test "${ac_cv_search_socket+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct if_laddrreq" >&5 +$as_echo_n "checking for struct if_laddrreq... " >&6; } +if test "${ac_cv_isc_struct_if_laddrreq+set}" = set; then : $as_echo_n "(cached) " >&6 else - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char socket (); + + #include + #include + int main () { -return socket (); + + struct if_laddrreq a; + + ; return 0; } -_ACEOF -for ac_lib in '' socket; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_socket=$ac_res -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext - if test "${ac_cv_search_socket+set}" = set; then : - break -fi -done -if test "${ac_cv_search_socket+set}" = set; then : +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_isc_struct_if_laddrreq=yes else - ac_cv_search_socket=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_socket" >&5 -$as_echo "$ac_cv_search_socket" >&6; } -ac_res=$ac_cv_search_socket -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + ac_cv_isc_struct_if_laddrreq=no fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi -done +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_isc_struct_if_laddrreq" >&5 +$as_echo "$ac_cv_isc_struct_if_laddrreq" >&6; } -for ac_func in sqrt -do : - ac_fn_c_check_func "$LINENO" "sqrt" "ac_cv_func_sqrt" -if test "x$ac_cv_func_sqrt" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_SQRT 1 -_ACEOF +case "$ac_cv_isc_struct_if_laddrreq" in + yes) -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sqrt" >&5 -$as_echo_n "checking for library containing sqrt... " >&6; } -if test "${ac_cv_search_sqrt+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +$as_echo "#define ISC_PLATFORM_HAVEIF_LADDRREQ /**/" >>confdefs.h -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char sqrt (); -int -main () -{ -return sqrt (); - ; - return 0; -} -_ACEOF -for ac_lib in '' m; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_sqrt=$ac_res -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext - if test "${ac_cv_search_sqrt+set}" = set; then : - break -fi -done -if test "${ac_cv_search_sqrt+set}" = set; then : +esac -else - ac_cv_search_sqrt=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sqrt" >&5 -$as_echo "$ac_cv_search_sqrt" >&6; } -ac_res=$ac_cv_search_sqrt -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" -fi +### + +# Hacks + +$as_echo "#define HAVE_NO_NICE 1" >>confdefs.h -fi -done -for ac_func in strrchr +$as_echo "#define HAVE_TERMIOS 1" >>confdefs.h + + +# Checks for library functions. +for ac_func in socket vsnprintf vsprintf do : - ac_fn_c_check_func "$LINENO" "strrchr" "ac_cv_func_strrchr" -if test "x$ac_cv_func_strrchr" = x""yes; then : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +eval as_val=\$$as_ac_var + if test "x$as_val" = x""yes; then : cat >>confdefs.h <<_ACEOF -#define HAVE_STRRCHR 1 +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF fi done -case "$host" in - *-*-hpux10.*) # at least for hppa2.0-hp-hpux10.20 - case "$GCC" in - yes) - ;; - *) CFLAGS="$CFLAGS -Wp,-H18816" - ;; - esac - ;; - *-*-linux*) - CFLAGS="$CFLAGS -DADJTIME_MISSING" - ;; - *-*-sunos*) - CFLAGS="$CFLAGS -DNONBLOCK_BROKEN" - ;; -esac - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bin subdirectory" >&5 $as_echo_n "checking for bin subdirectory... " >&6; } @@ -15387,8 +17796,17 @@ esac { $as_echo "$as_me:${as_lineno-$LINENO}: result: $use_binsubdir" >&5 $as_echo "$use_binsubdir" >&6; } + BINSUBDIR=$use_binsubdir + if test "bin" = "$BINSUBDIR"; then + NTP_BINSUBDIR_IS_BIN_TRUE= + NTP_BINSUBDIR_IS_BIN_FALSE='#' +else + NTP_BINSUBDIR_IS_BIN_TRUE='#' + NTP_BINSUBDIR_IS_BIN_FALSE= +fi + ac_config_files="$ac_config_files Makefile" @@ -15513,6 +17931,10 @@ as_fn_error "conditional \"NEED_LIBOPTS\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi +if test -z "${NTP_BINSUBDIR_IS_BIN_TRUE}" && test -z "${NTP_BINSUBDIR_IS_BIN_FALSE}"; then + as_fn_error "conditional \"NTP_BINSUBDIR_IS_BIN\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi : ${CONFIG_STATUS=./config.status} ac_write_fail=0 @@ -15921,7 +18343,7 @@ # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by $as_me, which was +This file was extended by sntp $as_me 4.2.6p2, which was generated by GNU Autoconf 2.65. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -15987,7 +18409,7 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ -config.status +sntp config.status 4.2.6p2 configured by $0, generated by GNU Autoconf 2.65, with options \\"\$ac_cs_config\\" diff -urN src/contrib/ntp/sntp/configure.ac src.ntp/contrib/ntp/sntp/configure.ac --- src/contrib/ntp/sntp/configure.ac 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/configure.ac 2010-06-03 08:05:26.000000000 +0200 @@ -1,21 +1,116 @@ +# -*- Autoconf -*- # Process this file with autoconf to produce a configure script. -AC_INIT(main.c) -AM_INIT_AUTOMAKE([msntp],[1.6]) -AC_CONFIG_SRCDIR([header.h]) +m4_include([../version.m4]) +AC_PREREQ(2.61) +AC_INIT([sntp], [VERSION_NUMBER]) +AC_CONFIG_MACRO_DIR([../m4]) +AC_CONFIG_AUX_DIR([.]) + +# Increment sntp_configure_cache_version by one for each change to +# configure.ac or .m4 files which invalidates cached values from +# previous versions. +# +# If the change affects cache variables used only by the main NTP +# configure.ac, then only its version number should be bumped, while +# the subdir configure.ac version numbers should be unchanged. The +# same is true for a test/variable that is used only by one subdir +# being changed incompatibly; only that subdir's cache version needs +# bumping. +# +# If a change affects variables shared by all NTP configure scripts, +# please bump the version numbers of all three. If you are not sure, +# the safe choice is to bump all three on any cache-invalidating change. +# +# In order to avoid the risk of version stamp collision between -stable +# and -dev branches, do not simply increment the version, instead use +# the date YYYYMMDD optionally with -HHMM if there is more than one +# bump in a day. + +sntp_configure_cache_version=20091117 + +# When the version of config.cache and configure do not +# match, NTP_CACHEVERSION will flush the cache. + +NTP_CACHEVERSION([sntp], [$sntp_configure_cache_version]) + +AM_INIT_AUTOMAKE +AC_CANONICAL_BUILD AC_CANONICAL_HOST -AM_CONFIG_HEADER(config.h) +dnl the 'build' machine is where we run configure and compile +dnl the 'host' machine is where the resulting stuff runs. +AC_DEFINE_UNQUOTED([STR_SYSTEM], "$host", [canonical system (cpu-vendor-os) of where we should run]) +AC_CONFIG_HEADER([config.h]) +dnl AC_ARG_PROGRAM +AC_PREREQ([2.53]) # Checks for programs. AC_PROG_CC -# So far, the only shared library we might use is libopts. -# It's a small library - we might as well use a static version of it. -AC_DISABLE_SHARED +# AC_PROG_CC_STDC has two functions. It attempts to find a compiler +# capable of C99, or failing that, for C89. CC is set afterward with +# the selected invocation, such as "gcc --std=gnu99". Also, the +# ac_cv_prog_cc_stdc variable is no if the compiler selected for CC +# does not accept C89. -m4_defun([_LT_AC_LANG_CXX_CONFIG], [:]) -m4_defun([_LT_AC_LANG_F77_CONFIG], [:]) +AC_PROG_CC_STDC -AC_PROG_LIBTOOL +case "$ac_cv_prog_cc_stdc" in + no) + AC_MSG_WARN([ANSI C89/ISO C90 is the minimum to compile SNTP ] + [version 4.2.5 and higher.]) +esac + +case "$GCC" in + yes) + SAVED_CFLAGS_AC="$CFLAGS" + CFLAGS="$CFLAGS -Wstrict-overflow" + AC_CACHE_CHECK( + [if $CC can handle -Wstrict-overflow], + ac_cv_gcc_Wstrict_overflow, + [ + AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM([], [])], + [ac_cv_gcc_Wstrict_overflow=yes], + [ac_cv_gcc_Wstrict_overflow=no] + ) + ] + ) + CFLAGS="$SAVED_CFLAGS_AC" + SAVED_CFLAGS_AC= + + CFLAGS="$CFLAGS -Wall" + # CFLAGS="$CFLAGS -Wcast-align" + CFLAGS="$CFLAGS -Wcast-qual" + # CFLAGS="$CFLAGS -Wconversion" + # CFLAGS="$CFLAGS -Werror" + # CFLAGS="$CFLAGS -Wextra" + # CFLAGS="$CFLAGS -Wfloat-equal" + CFLAGS="$CFLAGS -Wmissing-prototypes" + CFLAGS="$CFLAGS -Wpointer-arith" + CFLAGS="$CFLAGS -Wshadow" + CFLAGS="$CFLAGS -Wstrict-prototypes" + # CFLAGS="$CFLAGS -Wtraditional" + # CFLAGS="$CFLAGS -Wwrite-strings" + case "$ac_cv_gcc_Wstrict_overflow" in + yes) + CFLAGS="$CFLAGS -Wstrict-overflow" + esac + # -W[no-]strict-prototypes is added later depending on OpenSSL +esac + +# HMS: These need to be moved to AM_CPPFLAGS and/or AM_CFLAGS +case "$host" in + *-*-solaris*) + # see "man standards". + # -D_XOPEN_SOURCE=500 is probably OK for c89 and before + # -D_XOPEN_SOURCE=600 seems OK for c99 + #CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=500 -D__EXTENSIONS__" + CPPFLAGS="$CPPFLAGS -D__EXTENSIONS__" + libxnet=-lxnet + ;; +esac + +AC_DISABLE_SHARED # NTP has (so far) been relying on leading-edge autogen. # Therefore, by default: @@ -30,18 +125,34 @@ set) ;; *) enable_libopts_install=no ;; esac -LIBOPTS_CHECK +LIBOPTS_CHECK([libopts]) -AC_MSG_CHECKING([[if $CC can handle #warning]]) -AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[#warning foo]])],[ac_cv_cpp_warning=yes],[ac_cv_cpp_warning=no]) -AC_MSG_RESULT([$ac_cv_cpp_warning]) +m4_defun([_LT_AC_LANG_CXX_CONFIG], [:]) +m4_defun([_LT_AC_LANG_F77_CONFIG], [:]) -case "$ac_cv_cpp_warning" in - no) - AC_DEFINE([NO_OPTION_NAME_WARNINGS], [1], [Should we avoid #warning on option name collisions?]) - AC_MSG_RESULT([[Enabling NO_OPTION_NAME_WARNINGS as #warning does not work]]) - ;; -esac +AC_PROG_LIBTOOL +NTP_DIR_SEP + +# Checks for libraries. + +AC_CHECK_FUNC([gethostent], , + [AC_SEARCH_LIBS([gethostent], [nsl], , , [$libxnet -lsocket])]) +AC_CHECK_FUNC([openlog], , + [AC_SEARCH_LIBS([openlog], [gen], , + [AC_SEARCH_LIBS([openlog], [syslog], , , [$libxnet -lsocket])])]) + +AC_SEARCH_LIBS([setsockopt], [socket xnet]) + +# Checks for header files. +AC_HEADER_STDC +AC_CHECK_HEADERS([netdb.h netinet/in.h stdlib.h string.h strings.h syslog.h]) +AC_CHECK_HEADERS([sys/socket.h sys/time.h]) +AC_HEADER_TIME + +# Checks for typedefs, structures, and compiler characteristics. +AC_HEADER_STDBOOL +AC_C_CONST +AC_TYPE_SIZE_T AC_C_INLINE @@ -53,93 +164,595 @@ AC_SUBST(HAVE_INLINE) esac +AC_C_CHAR_UNSIGNED dnl CROSS_COMPILE? +AC_CHECK_SIZEOF([signed char]) +AC_CHECK_SIZEOF([int]) +AC_CHECK_SIZEOF([long]) + +AC_CHECK_TYPES([s_char]) +case "$ac_cv_c_char_unsigned$ac_cv_sizeof_signed_char$ac_cv_type_s_char" in + *yes) + # We have a typedef for s_char. Might as well believe it... + ;; + no0no) + # We have signed chars, can't say 'signed char', no s_char typedef. + AC_DEFINE([NEED_S_CHAR_TYPEDEF], 1, [Do we need an s_char typedef?]) + ;; + no1no) + # We have signed chars, can say 'signed char', no s_char typedef. + AC_DEFINE([NEED_S_CHAR_TYPEDEF]) + ;; + yes0no) + # We have unsigned chars, can't say 'signed char', no s_char typedef. + AC_MSG_ERROR([No way to specify a signed character!]) + ;; + yes1no) + # We have unsigned chars, can say 'signed char', no s_char typedef. + AC_DEFINE([NEED_S_CHAR_TYPEDEF]) + ;; +esac +AC_TYPE_UID_T + +NTP_OPENSSL -# Checks for libraries. +AC_MSG_CHECKING([type of socklen arg for getsockname()]) +AC_CACHE_VAL(ac_cv_func_getsockname_arg2,dnl +[AC_CACHE_VAL(ac_cv_func_getsockname_socklen_type,dnl + [for ac_cv_func_getsockname_arg2 in 'struct sockaddr *' 'void *'; do + for ac_cv_func_getsockname_socklen_type in 'socklen_t' 'size_t' 'unsigned int' 'int'; do + AC_TRY_COMPILE(dnl +[#ifdef HAVE_SYS_TYPES_H +#include +#endif +#ifdef HAVE_SYS_SOCKET_H +#include +#endif +extern getsockname (int, $ac_cv_func_getsockname_arg2, $ac_cv_func_getsockname_socklen_type *);],,dnl + [ac_not_found=no ; break 2], ac_not_found=yes) + done + done + ])dnl AC_CACHE_VAL +])dnl AC_CACHE_VAL +if test "$ac_not_found" = yes; then + ac_cv_func_getsockname_socklen_type='socklen_t' +fi +AC_MSG_RESULT([$ac_cv_func_getsockname_socklen_type]) +AC_DEFINE_UNQUOTED([GETSOCKNAME_SOCKLEN_TYPE], + $ac_cv_func_getsockname_socklen_type, + [What is getsockname()'s socklen type?]) + +AC_CACHE_CHECK( + [for struct sockaddr_storage], + ntp_cv_sockaddr_storage, + [ + AC_TRY_COMPILE( + [ + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif + ], + [ + struct sockaddr_storage n; + ], + [ntp_cv_sockaddr_storage="yes"], + [ntp_cv_sockaddr_storage="no"] + ) + ] +) +case "$ntp_cv_sockaddr_storage" in + yes) + AC_DEFINE(HAVE_STRUCT_SOCKADDR_STORAGE, 1, [Does a system header define struct sockaddr_storage?]) +esac -# Checks for header files. -AC_HEADER_STDC -AC_CHECK_HEADERS([arpa/inet.h fcntl.h float.h limits.h netdb.h netinet/in.h stdlib.h string.h sys/socket.h sys/time.h syslog.h unistd.h]) +AC_CACHE_CHECK( + [for sockaddr_storage.ss_family], + ntp_cv_have_ss_family, + [ + AC_TRY_COMPILE( + [ + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif + ], + [ + struct sockaddr_storage s; + s.ss_family = 1; + ], + [ntp_cv_have_ss_family="yes"], + [ntp_cv_have_ss_family="no"] + ) + ] +) -# Checks for typedefs, structures, and compiler characteristics. -AC_C_CONST -AC_TYPE_SIZE_T -AC_HEADER_TIME -AC_STRUCT_TM +case "$ntp_cv_have_ss_family" in + no) + AC_CACHE_CHECK( + [for sockaddr_storage.__ss_family], + ntp_cv_have___ss_family, + [ + AC_TRY_COMPILE( + [ + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif + ], + [ + struct sockaddr_storage s; + s.__ss_family = 1; + ], + [ntp_cv_have___ss_family="yes"], + [ntp_cv_have___ss_family="no"] + ) + ] + ) + case "$ntp_cv_have___ss_family" in + yes) + AC_DEFINE(HAVE___SS_FAMILY_IN_SS, 1, [Does struct sockaddr_storage have __ss_family?]) + esac +esac -AC_CACHE_CHECK([for ss_family field in struct sockaddr_storage], - ac_cv_have_ss_family_in_struct_ss, [ +AH_VERBATIM( + [HAVE___SS_FAMILY_IN_SS_VERBATIM], + [ + /* Handle sockaddr_storage.__ss_family */ + #ifdef HAVE___SS_FAMILY_IN_SS + # define ss_family __ss_family + #endif /* HAVE___SS_FAMILY_IN_SS */ + ] +) + +AC_CACHE_CHECK( + [for sockaddr_storage.ss_len], + ntp_cv_have_ss_len, + [ AC_TRY_COMPILE( + [ + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif + ], + [ + struct sockaddr_storage s; + s.ss_len = 1; + ], + [ntp_cv_have_ss_len="yes"], + [ntp_cv_have_ss_len="no"] + ) + ] +) + +case "$ntp_cv_have_ss_len" in + no) + AC_CACHE_CHECK( + [for sockaddr_storage.__ss_len], + ntp_cv_have___ss_len, + [ + AC_TRY_COMPILE( [ -#include -#include + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif ], - [ struct sockaddr_storage s; s.ss_family = 1; ], - [ ac_cv_have_ss_family_in_struct_ss="yes" ], - [ ac_cv_have_ss_family_in_struct_ss="no" ], + [ + struct sockaddr_storage s; + s.__ss_len = 1; + ], + [ntp_cv_have___ss_len="yes"], + [ntp_cv_have___ss_len="no"] + ) + ] + ) + case "$ntp_cv_have___ss_len" in + yes) + AC_DEFINE(HAVE___SS_LEN_IN_SS, 1, [Does struct sockaddr_storage have __ss_len?]) + esac +esac + +AH_VERBATIM( + [HAVE___SS_LEN_IN_SS_VERBATIM], + [ + /* Handle sockaddr_storage.__ss_len */ + #ifdef HAVE___SS_LEN_IN_SS + # define ss_len __ss_len + #endif /* HAVE___SS_LEN_IN_SS */ + ] +) + +# +# Look for in_port_t. +# +AC_CACHE_CHECK( + [for in_port_t], + isc_cv_have_in_port_t, + [ + AC_TRY_COMPILE( + [ + #include + #include + ], + [ + in_port_t port = 25; + return (0); + ], + [isc_cv_have_in_port_t=yes], + [isc_cv_have_in_port_t=no] ) -]) -case "$ac_cv_have_ss_family_in_struct_ss" in + ] +) +case "$isc_cv_have_in_port_t" in + no) + AC_DEFINE(ISC_PLATFORM_NEEDPORTT, 1, [Declare in_port_t?]) +esac + +AC_CACHE_CHECK( + [for multicast IP support], + ntp_cv_multicast, + [ + ntp_cv_multicast=no + case "$host" in + i386-sequent-sysv4) + ;; + *) + AC_COMPILE_IFELSE( + AC_LANG_PROGRAM( + [ + #ifdef HAVE_NETINET_IN_H + #include + #endif + ], + [ + struct ip_mreq ipmr; + ipmr.imr_interface.s_addr = 0; + ] + ), + [ntp_cv_multicast=yes], + [] + ) + esac + ] +) + +case "$ntp_cv_multicast" in yes) - AC_DEFINE(HAVE_SS_FAMILY_IN_SS, 1, [Does struct sockaddr_storage have ss_family?]) + AC_DEFINE(MCAST, 1, [Does the target support multicast IP?]) + AC_CACHE_CHECK( + [[arg type needed for setsockopt() IP*_MULTICAST_LOOP]], + ntp_cv_typeof_ip_multicast_loop, + [ + case "$host" in + *-*-netbsd*|*-*-*linux*) + ntp_cv_typeof_ip_multicast_loop=u_int + ;; + *-*-winnt*) + ntp_cv_typeof_ip_multicast_loop=BOOL + ;; + *) + ntp_cv_typeof_ip_multicast_loop=u_char + esac + ] + ) + AC_DEFINE_UNQUOTED([TYPEOF_IP_MULTICAST_LOOP], + $ntp_cv_typeof_ip_multicast_loop, + [What type to use for setsockopt] + ) +esac + +# HMS: We don't need res_init, but since we may be using cached +# values from ntpd we need to test the same way +AC_SEARCH_LIBS([res_init], [resolv], , , [-lsocket -lnsl]) +AC_SEARCH_LIBS([inet_ntop], [resolv], , , [-lsocket -lnsl]) +AC_CHECK_FUNC(inet_ntop, [], [AC_DEFINE(ISC_PLATFORM_NEEDNTOP, 1, [ISC: provide inet_ntop()])]) +AC_CHECK_FUNC(inet_pton, [], [AC_DEFINE(ISC_PLATFORM_NEEDPTON, 1, [ISC: provide inet_pton()])]) + +AC_ARG_ENABLE([ipv6], [AC_HELP_STRING([--enable-ipv6], [s use IPv6?])]) + +case "$enable_ipv6" in + yes|''|autodetect) + case "$host" in + powerpc-ibm-aix4*) ;; + *) + AC_DEFINE([WANT_IPV6], ,[ISC: Want IPv6?]) + ;; + esac + ;; + no) ;; esac -AC_CACHE_CHECK([for __ss_family field in struct sockaddr_storage], - ac_cv_have___ss_family_in_struct_ss, [ - AC_TRY_COMPILE( - [ -#include -#include - ], - [ struct sockaddr_storage s; s.__ss_family = 1; ], - [ ac_cv_have___ss_family_in_struct_ss="yes" ], - [ ac_cv_have___ss_family_in_struct_ss="no" ] +AC_CACHE_CHECK( + [for IPv6 structures], + ac_cv_isc_found_ipv6, + [ + AC_COMPILE_IFELSE( + [ + AC_LANG_PROGRAM( + [ + #include + #include + #include + ], + [ + struct sockaddr_in6 sin6; + ] + ) + ], + [ac_cv_isc_found_ipv6=yes], + [ac_cv_isc_found_ipv6=no] ) -]) -case "$ac_cv_have___ss_family_in_struct_ss" in + ] +) + +# +# See whether IPv6 support is provided via a Kame add-on. +# This is done before other IPv6 linking tests so LIBS is properly set. +# +AC_MSG_CHECKING([for Kame IPv6 support]) +AC_ARG_WITH(kame, + [AC_HELP_STRING([--with-kame], [- =/usr/local/v6])], + use_kame="$withval", use_kame="no") + +case "$use_kame" in + no) + ;; yes) - AC_DEFINE(HAVE___SS_FAMILY_IN_SS, 1, [Does struct sockaddr_storage have __ss_family?]) + kame_path=/usr/local/v6 + ;; + *) + kame_path="$use_kame" ;; esac -case "$ac_cv_have_ss_family_in_struct_ss$ac_cv_have___ss_family_in_struct_ss" in - noyes) - AC_DEFINE_UNQUOTED([ss_family], [__ss_family], [normalize ss_family access]) - AC_DEFINE_UNQUOTED([ss_len], [__ss_len], [normalize ss_len access]) +case "$use_kame" in + no) + AC_MSG_RESULT(no) + ;; + *) + if test -f $kame_path/lib/libinet6.a; then + AC_MSG_RESULT($kame_path/lib/libinet6.a) + LIBS="-L$kame_path/lib -linet6 $LIBS" + else + AC_MSG_ERROR([$kame_path/lib/libinet6.a not found. + +Please choose the proper path with the following command: + + configure --with-kame=PATH +]) + fi ;; esac -# Checks for library functions. -#AC_FUNC_MEMCMP dnl HMS: we don't have a memcmp.c to use here, so why bother? -AC_FUNC_SETVBUF_REVERSED -AC_TYPE_SIGNAL -AC_CHECK_FUNCS([alarm]) -AC_CHECK_FUNC([gethostent], , AC_SEARCH_LIBS([gethostent], [nsl], , , [-lsocket])) -AC_CHECK_FUNCS([gettimeofday inet_ntoa memset]) -AC_CHECK_FUNCS([socket], , AC_SEARCH_LIBS([socket], [socket])) -AC_CHECK_FUNCS([sqrt], , AC_SEARCH_LIBS([sqrt], [m])) -AC_CHECK_FUNCS([strrchr]) +# +# Whether netinet6/in6.h is needed has to be defined in isc/platform.h. +# Including it on Kame-using platforms is very bad, though, because +# Kame uses #error against direct inclusion. So include it on only +# the platform that is otherwise broken without it -- BSD/OS 4.0 through 4.1. +# This is done before the in6_pktinfo check because that's what +# netinet6/in6.h is needed for. +# +case "$host" in + *-bsdi4.[[01]]*) + AC_DEFINE(ISC_PLATFORM_NEEDNETINET6IN6H, 1, [Do we need netinet6/in6.h?]) + # does anything use LWRES_PLATFORM_NEEDNETINET6IN6H? Can't it use above? + AC_DEFINE(LWRES_PLATFORM_NEEDNETINET6IN6H, 1, [Do we need netinet6/in6.h?]) + isc_netinet6in6_hack="#include " + ;; + *) + isc_netinet6in6_hack="" +esac +# +# This is similar to the netinet6/in6.h issue. +# case "$host" in - *-*-hpux10.*) # at least for hppa2.0-hp-hpux10.20 - case "$GCC" in + *-sco-sysv*uw*|*-*-sysv*UnixWare*|*-*-sysv*OpenUNIX*) + AC_DEFINE(ISC_PLATFORM_FIXIN6ISADDR, 1,[Do we need to fix in6isaddr?]) + isc_netinetin6_hack="#include " + ;; + *) + isc_netinetin6_hack="" +esac + + +case "$ac_cv_isc_found_ipv6" in + yes) + AC_DEFINE(ISC_PLATFORM_HAVEIPV6, ,[have IPv6?]) + + AC_CACHE_CHECK( + [for in6_pktinfo], + ac_cv_have_in6_pktinfo, + [ + AC_COMPILE_IFELSE( + [ + AC_LANG_PROGRAM( + [ + #include + #include + #include + $isc_netinetin6_hack + $isc_netinet6in6_hack + ], + [ + struct in6_pktinfo xyzzy; + ] + ) + ], + [ac_cv_have_in6_pktinfo=yes], + [ac_cv_have_in6_pktinfo=no] + ) + ] + ) + + case "$ac_cv_have_in6_pktinfo" in yes) - ;; - *) CFLAGS="$CFLAGS -Wp,-H18816" - ;; + AC_DEFINE(ISC_PLATFORM_HAVEIN6PKTINFO, , [have struct in6_pktinfo?]) + esac + + + # HMS: Use HAVE_STRUCT_SOCKADDR_IN6_SIN6_SCOPE_ID instead? + AC_CACHE_CHECK( + [for sockaddr_in6.sin6_scope_id], + ac_cv_have_sin6_scope_id, + [ + AC_COMPILE_IFELSE( + [ + AC_LANG_PROGRAM( + [ + #include + #include + #include + $isc_netinetin6_hack + $isc_netinet6in6_hack + ], + [ + struct sockaddr_in6 xyzzy; + xyzzy.sin6_scope_id = 0; + ] + ) + ], + [ac_cv_have_sin6_scope_id=yes], + [ac_cv_have_sin6_scope_id=no] + ) + ] + ) + + case "$ac_cv_have_sin6_scope_id" in + yes) + AC_DEFINE(ISC_PLATFORM_HAVESCOPEID, , [have sin6_scope_id?]) esac - ;; - *-*-linux*) - CFLAGS="$CFLAGS -DADJTIME_MISSING" - ;; - *-*-sunos*) - CFLAGS="$CFLAGS -DNONBLOCK_BROKEN" - ;; esac + +# We need this check run even without ac_cv_isc_found_ipv6=yes + +AC_CACHE_CHECK( + [for in6addr_any], + isc_cv_have_in6addr_any, + [ + AC_LINK_IFELSE( + [ + AC_LANG_PROGRAM( + [ + #include + #include + #include + $isc_netinetin6_hack + $isc_netinet6in6_hack + ], + [ + struct in6_addr in6; + in6 = in6addr_any; + ] + ) + ], + [isc_cv_have_in6addr_any=yes], + [isc_cv_have_in6addr_any=no] + ) + ] +) + +case "$isc_cv_have_in6addr_any" in + no) + AC_DEFINE(ISC_PLATFORM_NEEDIN6ADDRANY, , [missing in6addr_any?]) +esac + + +AC_CACHE_CHECK( + [for struct if_laddrconf], + ac_cv_isc_struct_if_laddrconf, + [ + AC_COMPILE_IFELSE( + [ + AC_LANG_PROGRAM( + [ + #include + #include + ], + [ + struct if_laddrconf a; + ] + ) + ], + [ac_cv_isc_struct_if_laddrconf=yes], + [ac_cv_isc_struct_if_laddrconf=no] + ) + ] +) + +case "$ac_cv_isc_struct_if_laddrconf" in + yes) + AC_DEFINE(ISC_PLATFORM_HAVEIF_LADDRCONF, , [have struct if_laddrconf?]) +esac + +AC_CACHE_CHECK( + [for struct if_laddrreq], + ac_cv_isc_struct_if_laddrreq, + [ + AC_COMPILE_IFELSE( + [ + AC_LANG_PROGRAM( + [ + #include + #include + ], + [ + struct if_laddrreq a; + ] + ) + ], + [ac_cv_isc_struct_if_laddrreq=yes], + [ac_cv_isc_struct_if_laddrreq=no] + ) + ] +) + +case "$ac_cv_isc_struct_if_laddrreq" in + yes) + AC_DEFINE(ISC_PLATFORM_HAVEIF_LADDRREQ, , [have struct if_laddrreq?]) +esac + + +### + +# Hacks +AC_DEFINE(HAVE_NO_NICE, 1, [sntp does not care about 'nice']) +AC_DEFINE(HAVE_TERMIOS, 1, [sntp does not care about TTY stuff]) + +# Checks for library functions. +AC_CHECK_FUNCS([socket vsnprintf vsprintf]) + AC_MSG_CHECKING(for bin subdirectory) AC_ARG_WITH(binsubdir, - AC_HELP_STRING([--with-binsubdir], [bin ={bin,sbin}]), + [AC_HELP_STRING([--with-binsubdir], [bin ={bin,sbin}])], use_binsubdir="$withval", use_binsubdir="bin") case "$use_binsubdir" in @@ -152,8 +765,10 @@ ;; esac AC_MSG_RESULT($use_binsubdir) + BINSUBDIR=$use_binsubdir AC_SUBST(BINSUBDIR) +AM_CONDITIONAL(NTP_BINSUBDIR_IS_BIN, test "bin" = "$BINSUBDIR") AC_CONFIG_FILES([Makefile]) AC_OUTPUT diff -urN src/contrib/ntp/sntp/crypto.c src.ntp/contrib/ntp/sntp/crypto.c --- src/contrib/ntp/sntp/crypto.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/crypto.c 2010-05-11 09:46:54.000000000 +0200 @@ -0,0 +1,210 @@ +#include "crypto.h" +#include + +struct key *key_ptr; +int key_cnt = 0; + +int +make_mac( + char *pkt_data, + int pkt_size, + int mac_size, + struct key *cmp_key, + char * digest + ) +{ + u_int len = mac_size; + int key_type; + EVP_MD_CTX ctx; + + if (cmp_key->key_len > 64) + return 0; + if (pkt_size % 4 != 0) + return 0; + + INIT_SSL(); + key_type = keytype_from_text(cmp_key->type, NULL); + EVP_DigestInit(&ctx, EVP_get_digestbynid(key_type)); + EVP_DigestUpdate(&ctx, (u_char *)cmp_key->key_seq, (u_int)cmp_key->key_len); + EVP_DigestUpdate(&ctx, (u_char *)pkt_data, (u_int)pkt_size); + EVP_DigestFinal(&ctx, (u_char *)digest, &len); + + return (int)len; +} + + +/* Generates a md5 digest of the key specified in keyid concatinated with the + * ntp packet (exluding the MAC) and compares this digest to the digest in + * the packet's MAC. If they're equal this function returns 1 (packet is + * authentic) or else 0 (not authentic). + */ +int +auth_md5( + char *pkt_data, + int pkt_size, + int mac_size, + struct key *cmp_key + ) +{ + int hash_len; + int authentic; + char digest[20]; + + if (mac_size > sizeof(digest)) + return 0; + hash_len = make_mac(pkt_data, pkt_size, sizeof(digest), cmp_key, + digest); + if (!hash_len) + authentic = FALSE; + else + authentic = !memcmp(digest, pkt_data + pkt_size + 4, + hash_len); + return authentic; +} + +static int +hex_val( + unsigned char x + ) +{ + int val; + + if ('0' <= x && x <= '9') + val = x - '0'; + else if ('a' <= x && x <= 'f') + val = x - 'a' + 0xa; + else if ('A' <= x && x <= 'F') + val = x - 'A' + 0xA; + else + val = -1; + + return val; +} + +/* Load keys from the specified keyfile into the key structures. + * Returns -1 if the reading failed, otherwise it returns the + * number of keys it read + */ +int +auth_init( + const char *keyfile, + struct key **keys + ) +{ + FILE *keyf = fopen(keyfile, "r"); + struct key *prev = NULL; + int scan_cnt, line_cnt = 0; + char kbuf[200]; + char keystring[129]; + + if (keyf == NULL) { + if (ENABLED_OPT(NORMALVERBOSE)) + printf("sntp auth_init: Couldn't open key file %s for reading!\n", keyfile); + return -1; + } + if (feof(keyf)) { + if (ENABLED_OPT(NORMALVERBOSE)) + printf("sntp auth_init: Key file %s is empty!\n", keyfile); + fclose(keyf); + return -1; + } + key_cnt = 0; + while (!feof(keyf)) { + char * octothorpe; + struct key *act = emalloc(sizeof(struct key)); + int goodline = 0; + + fgets(kbuf, sizeof(kbuf), keyf); + kbuf[sizeof(kbuf) - 1] = '\0'; + octothorpe = strchr(kbuf, '#'); + if (octothorpe) + *octothorpe = '\0'; +#ifdef DEBUG + printf("sntp auth_init: fgets: %s", kbuf); +#endif + scan_cnt = sscanf(kbuf, "%d %9s %128s", &act->key_id, act->type, keystring); + if (scan_cnt == 3) { + int len = strlen(keystring); + if (len <= 20) { + act->key_len = len; + memcpy(act->key_seq, keystring, len + 1); + goodline = 1; + } else if ((len & 1) != 0) { + goodline = 0; /* it's bad */ + } else { + int j; + goodline = 1; + act->key_len = len >> 1; + for (j = 0; j < len; j+=2) { + int val; + val = (hex_val(keystring[j]) << 4) | + hex_val(keystring[j+1]); + if (val < 0) { + goodline = 0; /* it's bad */ + break; + } + act->key_seq[j>>1] = (char)val; + } + } + } + if (goodline) { + act->next = NULL; + if (NULL == prev) + *keys = act; + else + prev->next = act; + prev = act; + key_cnt++; +#ifdef DEBUG + printf("sntp auth_init: key_id %i type %s with key %s\n", act->key_id, act->type, act->key_seq); +#endif + } else { +#ifdef DEBUG + printf("sntp auth_init: scanf read %i items, doesn't look good, skipping line %i.\n", scan_cnt, line_cnt); +#endif + free(act); + } + line_cnt++; + } + fclose(keyf); + +#ifdef DEBUG + STDLINE + printf("sntp auth_init: Read %i keys from file %s:\n", line_cnt, keyfile); + { + struct key *kptr = *keys; + register int a; + + for (a = 0; a < key_cnt; a++) { + printf("key_id %i type %s with key %s (key length: %i)\n", + kptr->key_id, kptr->type, kptr->key_seq, kptr->key_len); + kptr = kptr->next; + } + } + STDLINE +#endif + key_ptr = *keys; + return key_cnt; +} + +/* Looks for the key with keyid key_id and sets the d_key pointer to the + * address of the key. If no matching key is found the pointer is not touched. + */ +void +get_key( + int key_id, + struct key **d_key + ) +{ + struct key *itr_key; + + if (key_cnt == 0) + return; + for (itr_key = key_ptr; itr_key; itr_key = itr_key->next) { + if (itr_key->key_id == key_id) { + *d_key = itr_key; + break; + } + } + return; +} diff -urN src/contrib/ntp/sntp/crypto.h src.ntp/contrib/ntp/sntp/crypto.h --- src/contrib/ntp/sntp/crypto.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/crypto.h 2010-05-11 09:46:54.000000000 +0200 @@ -0,0 +1,36 @@ +#ifndef CRYPTO_H +#define CRYPTO_H + +#include +#include +#include + +#include +#include +#include +#ifdef OPENSSL +# include "openssl/evp.h" +#else +# include /* provides clone of OpenSSL MD5 API */ +#endif +#include "utilities.h" +#include "sntp-opts.h" + +#define LEN_PKT_MAC LEN_PKT_NOMAC + sizeof(u_int32) + +/* #include "sntp-opts.h" */ + +struct key { + struct key *next; + int key_id; + int key_len; + char type[10]; + char key_seq[64]; +}; + +int auth_init(const char *keyfile, struct key **keys); +void get_key(int key_id, struct key **d_key); +int make_mac(char *pkt_data, int pkt_size, int mac_size, struct key *cmp_key, char *digest); +int auth_md5(char *pkt_data, int pkt_size, int mac_size, struct key *cmp_key); + +#endif diff -urN src/contrib/ntp/sntp/data_formats.h src.ntp/contrib/ntp/sntp/data_formats.h --- src/contrib/ntp/sntp/data_formats.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/data_formats.h 2009-12-09 08:36:46.000000000 +0100 @@ -0,0 +1,8 @@ +#ifndef DATA_FORMATS_H +#define DATA_FORMATS_H + +#include +#include +#include + +#endif diff -urN src/contrib/ntp/sntp/deps-ver src.ntp/contrib/ntp/sntp/deps-ver --- src/contrib/ntp/sntp/deps-ver 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/deps-ver 2009-12-09 08:36:35.000000000 +0100 @@ -0,0 +1 @@ +Fri Nov 13 17:21:31 UTC 2009 diff -urN src/contrib/ntp/sntp/depsver.mf src.ntp/contrib/ntp/sntp/depsver.mf --- src/contrib/ntp/sntp/depsver.mf 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/depsver.mf 2010-07-09 04:17:43.000000000 +0200 @@ -0,0 +1,67 @@ +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + ..) \ + cd .. && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + *) \ + echo 'Fatal: depsver.mf Automake fragment limited' \ + 'to immediate subdirectories.' && \ + echo "top_builddir: $(top_builddir)" && \ + echo "subdir: $(subdir)" && \ + exit 1 \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(DEPDIR)/deps-ver + @touch $@ + +BUILT_SOURCES += .deps-ver +CLEANFILES += .deps-ver + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# diff -urN src/contrib/ntp/sntp/header.h src.ntp/contrib/ntp/sntp/header.h --- src/contrib/ntp/sntp/header.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/header.h 2009-12-09 08:36:46.000000000 +0100 @@ -15,7 +15,6 @@ -#define VERSION "1.6" /* Just the version string */ #define MAX_SOCKETS 10 /* Maximum number of addresses */ #ifndef LOCKNAME @@ -25,6 +24,8 @@ # define SAVENAME "/etc/sntp.state" /* Stores the recovery state */ #endif +#define DEBUG + /* Defined in main.c */ @@ -32,7 +33,7 @@ #define op_client 1 /* Behave as a challenge client */ #define op_listen 2 /* Behave as a listening client */ -extern const char *argv0; +/* extern const char *argv0; extern int verbose, operation; @@ -42,7 +43,7 @@ -/* Defined in unix.c */ + Defined in unix.c */ extern void do_nothing (int seconds); @@ -74,7 +75,7 @@ extern int flush_socket (int which); -extern void close_socket (int which); +/* extern void close_socket (int which); */ diff -urN src/contrib/ntp/sntp/internet.c src.ntp/contrib/ntp/sntp/internet.c --- src/contrib/ntp/sntp/internet.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/internet.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,207 +0,0 @@ -/* Copyright (C) 1996 N.M. Maclaren - Copyright (C) 1996 The University of Cambridge - -This includes all of the code needed to handle Internet addressing. It is way -outside current POSIX, unfortunately. It should be easy to convert to a system -that uses another mechanism. The signal handling is not necessary for its -function, but is an attempt to avoid the program hanging when the name server -is inaccessible. */ - - - -#include "header.h" -#include "internet.h" - -#include -#include - -#define INTERNET -#include "kludges.h" -#undef INTERNET - - -/* Used to force dns resolving to ipv4 or ipv6 addresses. */ -static int pref_family; - -/* There needs to be some disgusting grobble for handling timeouts, which is -identical to the grobble in socket.c. */ - -static jmp_buf jump_buffer; - -static void jump_handler (int sig) { - longjmp(jump_buffer,1); -} - -static void clear_alarm (void) { - int k; - - k = errno; - alarm(0); - errno = 0; - if (signal(SIGALRM,SIG_DFL) == SIG_ERR) - fatal(1,"unable to reset signal handler",NULL); - errno = k; -} - -void preferred_family(int fam) { - switch(fam) { - case PREF_FAM_INET: - pref_family = AF_INET; - break; -#ifdef HAVE_IPV6 - case PREF_FAM_INET6: - pref_family = AF_INET6; - break; -#endif - default: - fatal(0,"unable to set the preferred family", NULL); - break; - } -} - -#ifdef HAVE_IPV6 - -void find_address (struct sockaddr_storage *address, - struct sockaddr_storage *anywhere, - int *port, char *hostname, int timespan) { - -/* Locate the specified NTP server and return its Internet address and port -number. */ - - int family, rval; - struct addrinfo hints; - struct addrinfo *res; - - res = NULL; - memset(address, 0, sizeof(struct sockaddr_storage)); - memset(anywhere, 0, sizeof(struct sockaddr_storage)); - - if (setjmp(jump_buffer)) - fatal(0,"unable to set up access to NTP server %s",hostname); - errno = 0; - if (signal(SIGALRM,jump_handler) == SIG_ERR) - fatal(1,"unable to set up signal handler",NULL); - alarm((unsigned int)timespan); - -/* Look up the Internet name or IP number. */ - memset(&hints, 0, sizeof(hints)); - hints.ai_socktype = SOCK_DGRAM; - hints.ai_family = pref_family; - rval = getaddrinfo(hostname, "ntp", &hints, &res); - if (rval != 0) - fatal(0, "getaddrinfo(hostname, ntp) failed with %s", - gai_strerror(rval)); - -/* Now clear the timer and check the result. */ - - clear_alarm(); - /* There can be more than one address in the list, but for now only - use the first. */ - memcpy(address, res->ai_addr, res->ai_addrlen); - family = res->ai_family; - freeaddrinfo(res); - - switch(family) { - case AF_INET: - hints.ai_family = AF_INET; - hints.ai_flags = AI_PASSIVE; - rval = getaddrinfo(NULL, "ntp", &hints, &res); - if (rval != 0) - fatal(0, "getaddrinfo(NULL, ntp) failed with %s", - gai_strerror(rval)); - memcpy(anywhere, res->ai_addr, res->ai_addrlen); - freeaddrinfo(res); - break; - case AF_INET6: - hints.ai_family = AF_INET6; - hints.ai_flags = AI_PASSIVE; - rval = getaddrinfo(NULL, "ntp", &hints, &res); - if (rval != 0) - fatal(0, "getaddrinfo(NULL, ntp, INET6, AI_PASSIVE) failed with %s", - gai_strerror(rval)); - memcpy(anywhere, res->ai_addr, res->ai_addrlen); - freeaddrinfo(res); - break; - } -} - -#else - -void find_address (struct in_addr *address, struct in_addr *anywhere, - int *port, char *hostname, int timespan) { - -/* Locate the specified NTP server and return its Internet address and port -number. */ - - unsigned long ipaddr; - struct in_addr nowhere[1]; - struct hostent *host; - struct servent *service; - -/* Set up the reserved Internet addresses, attempting not to assume that -addresses are 32 bits. */ - - local_to_address(nowhere,INADDR_LOOPBACK); - local_to_address(anywhere,INADDR_ANY); - -/* Check the address, if any. This assumes that the DNS is reliable, or is at -least checked by someone else. But it doesn't assume that it is accessible, so -it needs to set up a timeout. */ - - if (hostname == NULL) - *address = *anywhere; - else { - if (setjmp(jump_buffer)) - fatal(0,"unable to set up access to NTP server %s",hostname); - errno = 0; - if (signal(SIGALRM,jump_handler) == SIG_ERR) - fatal(1,"unable to set up signal handler",NULL); - alarm((unsigned int)timespan); - -/* Look up the Internet name or IP number. */ - - if (! isdigit(hostname[0])) { - errno = 0; - host = gethostbyname(hostname); - } else { - if ((ipaddr = inet_addr(hostname)) == (unsigned long)-1) - fatal(0,"invalid IP number %s",hostname); - network_to_address(address,ipaddr); - errno = 0; - host = gethostbyaddr((void *)address,sizeof(struct in_addr), - AF_INET); - } - -/* Now clear the timer and check the result. */ - - clear_alarm(); - if (host == NULL) fatal(1,"unable to locate IP address/number",NULL); - if (host->h_length != sizeof(struct in_addr)) - fatal(0,"the address does not seem to be an Internet one",NULL); - *address = *((struct in_addr **)host->h_addr_list)[0]; - if (memcmp(address,nowhere,sizeof(struct in_addr)) == 0 - || memcmp(address,anywhere,sizeof(struct in_addr)) == 0) - fatal(0,"reserved IP numbers cannot be used",NULL); - if (verbose) - fprintf(stderr, - "%s: using NTP server %s (%s)\n", - argv0,host->h_name,inet_ntoa(*address)); - } - -/* Find out the port number (usually from /etc/services), and leave it in -network format. This is assumed not to be obtained from a network service! -Note that a port number is not assumed to be 16 bits. */ - - if ((service = getservbyname("ntp","udp")) != NULL) { - *port = service->s_port; - if (verbose > 2) - fprintf(stderr,"Using port %d for NTP\n",port_to_integer(*port)); - } else { - *port = NTP_PORT; - if (verbose) - fprintf(stderr, - "%s: assuming port %d for NTP - check /etc/services\n", - argv0,port_to_integer(*port)); - } -} -#endif diff -urN src/contrib/ntp/sntp/internet.h src.ntp/contrib/ntp/sntp/internet.h --- src/contrib/ntp/sntp/internet.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/internet.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,47 +0,0 @@ -/* Copyright (C) 1996 N.M. Maclaren - Copyright (C) 1996 The University of Cambridge - -This includes all of the 'Internet' headers and definitions used across -modules, including those for handling timeouts. No changes should be needed -for any version of Unix with Internet (IP version 5) addressing, but would be -for other addressing domains. It needs only because AF_INET is -needed by gethostbyaddr and is defined there rather than in , for some -damn-fool reason. */ - - - -#include -#include - -#include -#include -#include -#include - - - -/* It is most unclear whether these should be here or in kludges.h, as they are -kludges to keep 32-bit address dependencies out of the main body of internet.c, -to allow for the much heralded arrival of IP version 6. It will be interesting -to see whether the universal availability of 64-bit integers arrives first. */ - -#define local_to_address(x,y) ((x)->s_addr = htonl((unsigned long)y)) -#define network_to_address(x,y) ((x)->s_addr = (y)) - -#define NTP_PORT htons((unsigned short)123) /* If not in /etc/services */ -#define port_to_integer(x) (ntohs((unsigned short)(x))) - - -#if defined(_SS_MAXSIZE) || defined(_SS_SIZE) -#define HAVE_IPV6 -#endif - -/* Defined in internet.c */ -#ifdef HAVE_IPV6 -extern void find_address (struct sockaddr_storage *address, - struct sockaddr_storage *anywhere, - int *port, char *hostname, int timespan); -#else -extern void find_address (struct in_addr *address, struct in_addr *anywhere, - int *port, char *hostname, int timespan); -#endif diff -urN src/contrib/ntp/sntp/kludges.h src.ntp/contrib/ntp/sntp/kludges.h --- src/contrib/ntp/sntp/kludges.h 2004-07-20 17:01:50.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/kludges.h 1970-01-01 01:00:00.000000000 +0100 @@ -1,62 +0,0 @@ -/* Copyright (C) 1996, 2000 N.M. Maclaren - Copyright (C) 1996, 2000 The University of Cambridge - -This includes all of the kludges necessary for certain broken systems. It is -called after all other headers. All of the modules set a flag to say which -they are, but none of the current kludges critically need that information. */ - - - -/* stdlib.h is broken under SunOS4. */ - -#ifndef EXIT_SUCCESS -#define EXIT_SUCCESS 0 -#define EXIT_FAILURE 1 -#endif - - - -/* stdio.h is also broken under SunOS4. */ - -#ifndef SEEK_SET -#define SEEK_SET 0 -#endif - - - -/* netinet/in.h sometimes omits INADDR_LOOPBACK, or makes it conditional on -peculiar preprocessor symbols. */ - -#ifndef INADDR_LOOPBACK -#define INADDR_LOOPBACK 0x7f000001ul -#endif - - - -/* HP-UX up to version 9.x does not have adjtime, so make it fail. This needs -a flag setting in Makefile. */ - -#ifdef ADJTIME_MISSING -#define adjtime(x,y) 1 -#endif - - - -/* O_NONBLOCK doesn't work under Ultrix 4.3. This needs a flag setting in -Makefile. */ - -#ifdef NONBLOCK_BROKEN -#ifdef O_NONBLOCK -#undef O_NONBLOCK -#endif -#define O_NONBLOCK O_NDELAY -#endif - - - -/* Some older systems use EWOULDBLOCK rather than EAGAIN, but don't assume that -it is defined. The differences are not relevant to this program. */ - -#ifndef EWOULDBLOCK -#define EWOULDBLOCK EAGAIN -#endif diff -urN src/contrib/ntp/sntp/kod_management.c src.ntp/contrib/ntp/sntp/kod_management.c --- src/contrib/ntp/sntp/kod_management.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/kod_management.c 2010-01-24 11:01:46.000000000 +0100 @@ -0,0 +1,314 @@ +#include +#include +#include + +#include "kod_management.h" +#include "log.h" +#include "sntp-opts.h" +#include "ntp_stdlib.h" +#define DEBUG + +int kod_init = 0, kod_db_cnt = 0; +const char *kod_db_file; +struct kod_entry **kod_db; /* array of pointers to kod_entry */ + + +/* + * Search for a KOD entry + */ +int +search_entry ( + char *hostname, + struct kod_entry **dst + ) +{ + register int a, b, resc = 0; + + for (a = 0; a < kod_db_cnt; a++) + if (!strcmp(kod_db[a]->hostname, hostname)) + resc++; + + if (!resc) { + *dst = NULL; + return 0; + } + + *dst = emalloc(resc * sizeof(**dst)); + + b = 0; + for (a = 0; a < kod_db_cnt; a++) + if (!strcmp(kod_db[a]->hostname, hostname)) { + (*dst)[b] = *kod_db[a]; + b++; + } + + return resc; +} + + +void +add_entry( + char *hostname, + char *type /* 4 bytes not \0 terminated */ + ) +{ + int n; + struct kod_entry *pke; + + pke = emalloc(sizeof(*pke)); + pke->timestamp = time(NULL); + memcpy(pke->type, type, 4); + pke->type[sizeof(pke->type) - 1] = '\0'; + strncpy(pke->hostname, hostname, + sizeof(pke->hostname)); + pke->hostname[sizeof(pke->hostname) - 1] = '\0'; + + /* + * insert in address ("hostname") order to find duplicates + */ + for (n = 0; n < kod_db_cnt; n++) + if (strcmp(kod_db[n]->hostname, pke->hostname) >= 0) + break; + + if (n < kod_db_cnt && + 0 == strcmp(kod_db[n]->hostname, pke->hostname)) { + kod_db[n]->timestamp = pke->timestamp; + free(pke); + return; + } + + kod_db_cnt++; + kod_db = erealloc(kod_db, kod_db_cnt * sizeof(kod_db[0])); + if (n != kod_db_cnt - 1) + memmove(&kod_db[n + 1], &kod_db[n], + sizeof(kod_db[0]) * ((kod_db_cnt - 1) - n)); + kod_db[n] = pke; +} + + +void +delete_entry( + char *hostname, + char *type + ) +{ + register int a; + + for (a = 0; a < kod_db_cnt; a++) + if (!strcmp(kod_db[a]->hostname, hostname) + && !strcmp(kod_db[a]->type, type)) + break; + + if (a == kod_db_cnt) + return; + + free(kod_db[a]); + kod_db_cnt--; + + if (a < kod_db_cnt) + memmove(&kod_db[a], &kod_db[a + 1], + (kod_db_cnt - a) * sizeof(kod_db[0])); +} + + +void +write_kod_db(void) +{ + FILE *db_s; + char *pch; + int dirmode; + register int a; + + db_s = fopen(kod_db_file, "w"); + + /* + * If opening fails, blindly attempt to create each directory + * in the path first, then retry the open. + */ + if (NULL == db_s && strlen(kod_db_file)) { + dirmode = S_IRUSR | S_IWUSR | S_IXUSR + | S_IRGRP | S_IXGRP + | S_IROTH | S_IXOTH; + pch = strchr(kod_db_file + 1, DIR_SEP); + while (NULL != pch) { + *pch = '\0'; + mkdir(kod_db_file, dirmode); + *pch = DIR_SEP; + pch = strchr(pch + 1, DIR_SEP); + } + db_s = fopen(kod_db_file, "w"); + } + + if (NULL == db_s) { + char msg[80]; + + snprintf(msg, sizeof(msg), + "Can't open KOD db file %s for writing!", + kod_db_file); +#ifdef DEBUG + debug_msg(msg); +#endif + log_msg(msg, 2); + + return; + } + + for (a = 0; a < kod_db_cnt; a++) { + fprintf(db_s, "%16.16llx %s %s\n", (unsigned long long) + kod_db[a]->timestamp, kod_db[a]->type, + kod_db[a]->hostname); + } + + fflush(db_s); + fclose(db_s); +} + + +void +kod_init_kod_db( + const char *db_file + ) +{ + /* + * Max. of 254 characters for hostname, 10 for timestamp, 4 for + * kisscode, 2 for spaces, 1 for \n, and 1 for \0 + */ + char fbuf[254+10+4+2+1+1]; + FILE *db_s; + int a, b, sepc, len; + unsigned long long ull; + char *str_ptr; + char error = 0; + + atexit(write_kod_db); + +#ifdef DEBUG + printf("Initializing KOD DB...\n"); +#endif + + kod_db_file = estrdup(db_file); + + + db_s = fopen(db_file, "r"); + + if (NULL == db_s) { + char msg[80]; + + snprintf(msg, sizeof(msg), "kod_init_kod_db(): Cannot open KoD db file %s", db_file); +#ifdef DEBUG + debug_msg(msg); + printf("%s\n", msg); +#endif + log_msg(msg, 2); + + return; + } + + if (ENABLED_OPT(NORMALVERBOSE)) + printf("Starting to read KoD file %s...\n", db_file); + /* First let's see how many entries there are and check for right syntax */ + + while (!feof(db_s) && NULL != fgets(fbuf, sizeof(fbuf), db_s)) { + + /* ignore blank lines */ + if ('\n' == fbuf[0]) + continue; + + sepc = 0; + len = strlen(fbuf); + for (a = 0; a < len; a++) { + if (' ' == fbuf[a]) + sepc++; + + if ('\n' == fbuf[a]) { + if (sepc != 2) { + if (strcmp(db_file, "/dev/null")) { + char msg[80]; + snprintf(msg, sizeof(msg), + "Syntax error in KoD db file %s in line %i (missing space)", + db_file, kod_db_cnt + 1); + #ifdef DEBUG + debug_msg(msg); + printf("%s\n", msg); + #endif + log_msg(msg, 1); + } + fclose(db_s); + return; + } + sepc = 0; + kod_db_cnt++; + } + } + } + + if (0 == kod_db_cnt) { +#ifdef DEBUG + printf("KoD DB %s empty.\n", db_file); +#endif + fclose(db_s); + return; + } + +#ifdef DEBUG + printf("KoD DB %s contains %d entries, reading...\n", db_file, kod_db_cnt); +#endif + + rewind(db_s); + + kod_db = emalloc(sizeof(kod_db[0]) * kod_db_cnt); + + /* Read contents of file */ + for (b = 0; + !feof(db_s) && !ferror(db_s) && b < kod_db_cnt; + b++) { + + str_ptr = fgets(fbuf, sizeof(fbuf), db_s); + if (NULL == str_ptr) { + error = 1; + break; + } + + /* ignore blank lines */ + if ('\n' == fbuf[0]) { + b--; + continue; + } + + kod_db[b] = emalloc(sizeof(*kod_db[b])); + + if (3 != sscanf(fbuf, "%llx %4s %254s", &ull, + kod_db[b]->type, kod_db[b]->hostname)) { + + free(kod_db[b]); + kod_db[b] = NULL; + error = 1; + break; + } + + kod_db[b]->timestamp = (time_t)ull; + } + + if (ferror(db_s) || error) { + char msg[80]; + + kod_db_cnt = b; + snprintf(msg, sizeof(msg), "An error occured while parsing the KoD db file %s", db_file); +#ifdef DEBUG + debug_msg(msg); +#endif + log_msg(msg, 2); + fclose(db_s); + + return; + } + + fclose(db_s); +#ifdef DEBUG + for (a = 0; a < kod_db_cnt; a++) + printf("KoD entry %d: %s at %llx type %s\n", a, + kod_db[a]->hostname, + (unsigned long long)kod_db[a]->timestamp, + kod_db[a]->type); +#endif +} diff -urN src/contrib/ntp/sntp/kod_management.h src.ntp/contrib/ntp/sntp/kod_management.h --- src/contrib/ntp/sntp/kod_management.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/kod_management.h 2009-12-09 08:36:46.000000000 +0100 @@ -0,0 +1,20 @@ +#ifndef KOD_MANAGEMENT_H +#define KOD_MANAGEMENT_H + +#include + +struct kod_entry { + char hostname[255]; + time_t timestamp; + char type[5]; +}; + +int search_entry(char *hostname, struct kod_entry **dst); + +void add_entry(char *hostname, char *type); +void delete_entry(char *hostname, char *type); +void kod_init_kod_db(const char *db_file); +void write_kod_db(void); + + +#endif diff -urN src/contrib/ntp/sntp/libopts/COPYING.gplv3 src.ntp/contrib/ntp/sntp/libopts/COPYING.gplv3 --- src/contrib/ntp/sntp/libopts/COPYING.gplv3 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/libopts/COPYING.gplv3 2009-12-09 08:36:46.000000000 +0100 @@ -0,0 +1,674 @@ + GNU GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 + + copyright (c) 2009 by Bruce Korb - all rights reserved + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The GNU General Public License is a free, copyleft license for +software and other kinds of works. + + The licenses for most software and other practical works are designed +to take away your freedom to share and change the works. By contrast, +the GNU General Public License is intended to guarantee your freedom to +share and change all versions of a program--to make sure it remains free +software for all its users. We, the Free Software Foundation, use the +GNU General Public License for most of our software; it applies also to +any other work released this way by its authors. You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +them if you wish), that you receive source code or can get it if you +want it, that you can change the software or use pieces of it in new +free programs, and that you know you can do these things. + + To protect your rights, we need to prevent others from denying you +these rights or asking you to surrender the rights. Therefore, you have +certain responsibilities if you distribute copies of the software, or if +you modify it: responsibilities to respect the freedom of others. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must pass on to the recipients the same +freedoms that you received. You must make sure that they, too, receive +or can get the source code. And you must show them these terms so they +know their rights. + + Developers that use the GNU GPL protect your rights with two steps: +(1) assert copyright on the software, and (2) offer you this License +giving you legal permission to copy, distribute and/or modify it. + + For the developers' and authors' protection, the GPL clearly explains +that there is no warranty for this free software. For both users' and +authors' sake, the GPL requires that modified versions be marked as +changed, so that their problems will not be attributed erroneously to +authors of previous versions. + + Some devices are designed to deny users access to install or run +modified versions of the software inside them, although the manufacturer +can do so. This is fundamentally incompatible with the aim of +protecting users' freedom to change the software. The systematic +pattern of such abuse occurs in the area of products for individuals to +use, which is precisely where it is most unacceptable. Therefore, we +have designed this version of the GPL to prohibit the practice for those +products. If such problems arise substantially in other domains, we +stand ready to extend this provision to those domains in future versions +of the GPL, as needed to protect the freedom of users. + + Finally, every program is threatened constantly by software patents. +States should not allow patents to restrict development and use of +software on general-purpose computers, but in those that do, we wish to +avoid the special danger that patents applied to a free program could +make it effectively proprietary. To prevent this, the GPL assures that +patents cannot be used to render the program non-free. + + The precise terms and conditions for copying, distribution and +modification follow. + + TERMS AND CONDITIONS + + 0. Definitions. + + "This License" refers to version 3 of the GNU General Public License. + + "Copyright" also means copyright-like laws that apply to other kinds of +works, such as semiconductor masks. + + "The Program" refers to any copyrightable work licensed under this +License. Each licensee is addressed as "you". "Licensees" and +"recipients" may be individuals or organizations. + + To "modify" a work means to copy from or adapt all or part of the work +in a fashion requiring copyright permission, other than the making of an +exact copy. The resulting work is called a "modified version" of the +earlier work or a work "based on" the earlier work. + + A "covered work" means either the unmodified Program or a work based +on the Program. + + To "propagate" a work means to do anything with it that, without +permission, would make you directly or secondarily liable for +infringement under applicable copyright law, except executing it on a +computer or modifying a private copy. Propagation includes copying, +distribution (with or without modification), making available to the +public, and in some countries other activities as well. + + To "convey" a work means any kind of propagation that enables other +parties to make or receive copies. Mere interaction with a user through +a computer network, with no transfer of a copy, is not conveying. + + An interactive user interface displays "Appropriate Legal Notices" +to the extent that it includes a convenient and prominently visible +feature that (1) displays an appropriate copyright notice, and (2) +tells the user that there is no warranty for the work (except to the +extent that warranties are provided), that licensees may convey the +work under this License, and how to view a copy of this License. If +the interface presents a list of user commands or options, such as a +menu, a prominent item in the list meets this criterion. + + 1. Source Code. + + The "source code" for a work means the preferred form of the work +for making modifications to it. "Object code" means any non-source +form of a work. + + A "Standard Interface" means an interface that either is an official +standard defined by a recognized standards body, or, in the case of +interfaces specified for a particular programming language, one that +is widely used among developers working in that language. + + The "System Libraries" of an executable work include anything, other +than the work as a whole, that (a) is included in the normal form of +packaging a Major Component, but which is not part of that Major +Component, and (b) serves only to enable use of the work with that +Major Component, or to implement a Standard Interface for which an +implementation is available to the public in source code form. A +"Major Component", in this context, means a major essential component +(kernel, window system, and so on) of the specific operating system +(if any) on which the executable work runs, or a compiler used to +produce the work, or an object code interpreter used to run it. + + The "Corresponding Source" for a work in object code form means all +the source code needed to generate, install, and (for an executable +work) run the object code and to modify the work, including scripts to +control those activities. However, it does not include the work's +System Libraries, or general-purpose tools or generally available free +programs which are used unmodified in performing those activities but +which are not part of the work. For example, Corresponding Source +includes interface definition files associated with source files for +the work, and the source code for shared libraries and dynamically +linked subprograms that the work is specifically designed to require, +such as by intimate data communication or control flow between those +subprograms and other parts of the work. + + The Corresponding Source need not include anything that users +can regenerate automatically from other parts of the Corresponding +Source. + + The Corresponding Source for a work in source code form is that +same work. + + 2. Basic Permissions. + + All rights granted under this License are granted for the term of +copyright on the Program, and are irrevocable provided the stated +conditions are met. This License explicitly affirms your unlimited +permission to run the unmodified Program. The output from running a +covered work is covered by this License only if the output, given its +content, constitutes a covered work. This License acknowledges your +rights of fair use or other equivalent, as provided by copyright law. + + You may make, run and propagate covered works that you do not +convey, without conditions so long as your license otherwise remains +in force. You may convey covered works to others for the sole purpose +of having them make modifications exclusively for you, or provide you +with facilities for running those works, provided that you comply with +the terms of this License in conveying all material for which you do +not control copyright. Those thus making or running the covered works +for you must do so exclusively on your behalf, under your direction +and control, on terms that prohibit them from making any copies of +your copyrighted material outside their relationship with you. + + Conveying under any other circumstances is permitted solely under +the conditions stated below. Sublicensing is not allowed; section 10 +makes it unnecessary. + + 3. Protecting Users' Legal Rights From Anti-Circumvention Law. + + No covered work shall be deemed part of an effective technological +measure under any applicable law fulfilling obligations under article +11 of the WIPO copyright treaty adopted on 20 December 1996, or +similar laws prohibiting or restricting circumvention of such +measures. + + When you convey a covered work, you waive any legal power to forbid +circumvention of technological measures to the extent such circumvention +is effected by exercising rights under this License with respect to +the covered work, and you disclaim any intention to limit operation or +modification of the work as a means of enforcing, against the work's +users, your or third parties' legal rights to forbid circumvention of +technological measures. + + 4. Conveying Verbatim Copies. + + You may convey verbatim copies of the Program's source code as you +receive it, in any medium, provided that you conspicuously and +appropriately publish on each copy an appropriate copyright notice; +keep intact all notices stating that this License and any +non-permissive terms added in accord with section 7 apply to the code; +keep intact all notices of the absence of any warranty; and give all +recipients a copy of this License along with the Program. + + You may charge any price or no price for each copy that you convey, +and you may offer support or warranty protection for a fee. + + 5. Conveying Modified Source Versions. + + You may convey a work based on the Program, or the modifications to +produce it from the Program, in the form of source code under the +terms of section 4, provided that you also meet all of these conditions: + + a) The work must carry prominent notices stating that you modified + it, and giving a relevant date. + + b) The work must carry prominent notices stating that it is + released under this License and any conditions added under section + 7. This requirement modifies the requirement in section 4 to + "keep intact all notices". + + c) You must license the entire work, as a whole, under this + License to anyone who comes into possession of a copy. This + License will therefore apply, along with any applicable section 7 + additional terms, to the whole of the work, and all its parts, + regardless of how they are packaged. This License gives no + permission to license the work in any other way, but it does not + invalidate such permission if you have separately received it. + + d) If the work has interactive user interfaces, each must display + Appropriate Legal Notices; however, if the Program has interactive + interfaces that do not display Appropriate Legal Notices, your + work need not make them do so. + + A compilation of a covered work with other separate and independent +works, which are not by their nature extensions of the covered work, +and which are not combined with it such as to form a larger program, +in or on a volume of a storage or distribution medium, is called an +"aggregate" if the compilation and its resulting copyright are not +used to limit the access or legal rights of the compilation's users +beyond what the individual works permit. Inclusion of a covered work +in an aggregate does not cause this License to apply to the other +parts of the aggregate. + + 6. Conveying Non-Source Forms. + + You may convey a covered work in object code form under the terms +of sections 4 and 5, provided that you also convey the +machine-readable Corresponding Source under the terms of this License, +in one of these ways: + + a) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by the + Corresponding Source fixed on a durable physical medium + customarily used for software interchange. + + b) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by a + written offer, valid for at least three years and valid for as + long as you offer spare parts or customer support for that product + model, to give anyone who possesses the object code either (1) a + copy of the Corresponding Source for all the software in the + product that is covered by this License, on a durable physical + medium customarily used for software interchange, for a price no + more than your reasonable cost of physically performing this + conveying of source, or (2) access to copy the + Corresponding Source from a network server at no charge. + + c) Convey individual copies of the object code with a copy of the + written offer to provide the Corresponding Source. This + alternative is allowed only occasionally and noncommercially, and + only if you received the object code with such an offer, in accord + with subsection 6b. + + d) Convey the object code by offering access from a designated + place (gratis or for a charge), and offer equivalent access to the + Corresponding Source in the same way through the same place at no + further charge. You need not require recipients to copy the + Corresponding Source along with the object code. If the place to + copy the object code is a network server, the Corresponding Source + may be on a different server (operated by you or a third party) + that supports equivalent copying facilities, provided you maintain + clear directions next to the object code saying where to find the + Corresponding Source. Regardless of what server hosts the + Corresponding Source, you remain obligated to ensure that it is + available for as long as needed to satisfy these requirements. + + e) Convey the object code using peer-to-peer transmission, provided + you inform other peers where the object code and Corresponding + Source of the work are being offered to the general public at no + charge under subsection 6d. + + A separable portion of the object code, whose source code is excluded +from the Corresponding Source as a System Library, need not be +included in conveying the object code work. + + A "User Product" is either (1) a "consumer product", which means any +tangible personal property which is normally used for personal, family, +or household purposes, or (2) anything designed or sold for incorporation +into a dwelling. In determining whether a product is a consumer product, +doubtful cases shall be resolved in favor of coverage. For a particular +product received by a particular user, "normally used" refers to a +typical or common use of that class of product, regardless of the status +of the particular user or of the way in which the particular user +actually uses, or expects or is expected to use, the product. A product +is a consumer product regardless of whether the product has substantial +commercial, industrial or non-consumer uses, unless such uses represent +the only significant mode of use of the product. + + "Installation Information" for a User Product means any methods, +procedures, authorization keys, or other information required to install +and execute modified versions of a covered work in that User Product from +a modified version of its Corresponding Source. The information must +suffice to ensure that the continued functioning of the modified object +code is in no case prevented or interfered with solely because +modification has been made. + + If you convey an object code work under this section in, or with, or +specifically for use in, a User Product, and the conveying occurs as +part of a transaction in which the right of possession and use of the +User Product is transferred to the recipient in perpetuity or for a +fixed term (regardless of how the transaction is characterized), the +Corresponding Source conveyed under this section must be accompanied +by the Installation Information. But this requirement does not apply +if neither you nor any third party retains the ability to install +modified object code on the User Product (for example, the work has +been installed in ROM). + + The requirement to provide Installation Information does not include a +requirement to continue to provide support service, warranty, or updates +for a work that has been modified or installed by the recipient, or for +the User Product in which it has been modified or installed. Access to a +network may be denied when the modification itself materially and +adversely affects the operation of the network or violates the rules and +protocols for communication across the network. + + Corresponding Source conveyed, and Installation Information provided, +in accord with this section must be in a format that is publicly +documented (and with an implementation available to the public in +source code form), and must require no special password or key for +unpacking, reading or copying. + + 7. Additional Terms. + + "Additional permissions" are terms that supplement the terms of this +License by making exceptions from one or more of its conditions. +Additional permissions that are applicable to the entire Program shall +be treated as though they were included in this License, to the extent +that they are valid under applicable law. If additional permissions +apply only to part of the Program, that part may be used separately +under those permissions, but the entire Program remains governed by +this License without regard to the additional permissions. + + When you convey a copy of a covered work, you may at your option +remove any additional permissions from that copy, or from any part of +it. (Additional permissions may be written to require their own +removal in certain cases when you modify the work.) You may place +additional permissions on material, added by you to a covered work, +for which you have or can give appropriate copyright permission. + + Notwithstanding any other provision of this License, for material you +add to a covered work, you may (if authorized by the copyright holders of +that material) supplement the terms of this License with terms: + + a) Disclaiming warranty or limiting liability differently from the + terms of sections 15 and 16 of this License; or + + b) Requiring preservation of specified reasonable legal notices or + author attributions in that material or in the Appropriate Legal + Notices displayed by works containing it; or + + c) Prohibiting misrepresentation of the origin of that material, or + requiring that modified versions of such material be marked in + reasonable ways as different from the original version; or + + d) Limiting the use for publicity purposes of names of licensors or + authors of the material; or + + e) Declining to grant rights under trademark law for use of some + trade names, trademarks, or service marks; or + + f) Requiring indemnification of licensors and authors of that + material by anyone who conveys the material (or modified versions of + it) with contractual assumptions of liability to the recipient, for + any liability that these contractual assumptions directly impose on + those licensors and authors. + + All other non-permissive additional terms are considered "further +restrictions" within the meaning of section 10. If the Program as you +received it, or any part of it, contains a notice stating that it is +governed by this License along with a term that is a further +restriction, you may remove that term. If a license document contains +a further restriction but permits relicensing or conveying under this +License, you may add to a covered work material governed by the terms +of that license document, provided that the further restriction does +not survive such relicensing or conveying. + + If you add terms to a covered work in accord with this section, you +must place, in the relevant source files, a statement of the +additional terms that apply to those files, or a notice indicating +where to find the applicable terms. + + Additional terms, permissive or non-permissive, may be stated in the +form of a separately written license, or stated as exceptions; +the above requirements apply either way. + + 8. Termination. + + You may not propagate or modify a covered work except as expressly +provided under this License. Any attempt otherwise to propagate or +modify it is void, and will automatically terminate your rights under +this License (including any patent licenses granted under the third +paragraph of section 11). + + However, if you cease all violation of this License, then your +license from a particular copyright holder is reinstated (a) +provisionally, unless and until the copyright holder explicitly and +finally terminates your license, and (b) permanently, if the copyright +holder fails to notify you of the violation by some reasonable means +prior to 60 days after the cessation. + + Moreover, your license from a particular copyright holder is +reinstated permanently if the copyright holder notifies you of the +violation by some reasonable means, this is the first time you have +received notice of violation of this License (for any work) from that +copyright holder, and you cure the violation prior to 30 days after +your receipt of the notice. + + Termination of your rights under this section does not terminate the +licenses of parties who have received copies or rights from you under +this License. If your rights have been terminated and not permanently +reinstated, you do not qualify to receive new licenses for the same +material under section 10. + + 9. Acceptance Not Required for Having Copies. + + You are not required to accept this License in order to receive or +run a copy of the Program. Ancillary propagation of a covered work +occurring solely as a consequence of using peer-to-peer transmission +to receive a copy likewise does not require acceptance. However, +nothing other than this License grants you permission to propagate or +modify any covered work. These actions infringe copyright if you do +not accept this License. Therefore, by modifying or propagating a +covered work, you indicate your acceptance of this License to do so. + + 10. Automatic Licensing of Downstream Recipients. + + Each time you convey a covered work, the recipient automatically +receives a license from the original licensors, to run, modify and +propagate that work, subject to this License. You are not responsible +for enforcing compliance by third parties with this License. + + An "entity transaction" is a transaction transferring control of an +organization, or substantially all assets of one, or subdividing an +organization, or merging organizations. If propagation of a covered +work results from an entity transaction, each party to that +transaction who receives a copy of the work also receives whatever +licenses to the work the party's predecessor in interest had or could +give under the previous paragraph, plus a right to possession of the +Corresponding Source of the work from the predecessor in interest, if +the predecessor has it or can get it with reasonable efforts. + + You may not impose any further restrictions on the exercise of the +rights granted or affirmed under this License. For example, you may +not impose a license fee, royalty, or other charge for exercise of +rights granted under this License, and you may not initiate litigation +(including a cross-claim or counterclaim in a lawsuit) alleging that +any patent claim is infringed by making, using, selling, offering for +sale, or importing the Program or any portion of it. + + 11. Patents. + + A "contributor" is a copyright holder who authorizes use under this +License of the Program or a work on which the Program is based. The +work thus licensed is called the contributor's "contributor version". + + A contributor's "essential patent claims" are all patent claims +owned or controlled by the contributor, whether already acquired or +hereafter acquired, that would be infringed by some manner, permitted +by this License, of making, using, or selling its contributor version, +but do not include claims that would be infringed only as a +consequence of further modification of the contributor version. For +purposes of this definition, "control" includes the right to grant +patent sublicenses in a manner consistent with the requirements of +this License. + + Each contributor grants you a non-exclusive, worldwide, royalty-free +patent license under the contributor's essential patent claims, to +make, use, sell, offer for sale, import and otherwise run, modify and +propagate the contents of its contributor version. + + In the following three paragraphs, a "patent license" is any express +agreement or commitment, however denominated, not to enforce a patent +(such as an express permission to practice a patent or covenant not to +sue for patent infringement). To "grant" such a patent license to a +party means to make such an agreement or commitment not to enforce a +patent against the party. + + If you convey a covered work, knowingly relying on a patent license, +and the Corresponding Source of the work is not available for anyone +to copy, free of charge and under the terms of this License, through a +publicly available network server or other readily accessible means, +then you must either (1) cause the Corresponding Source to be so +available, or (2) arrange to deprive yourself of the benefit of the +patent license for this particular work, or (3) arrange, in a manner +consistent with the requirements of this License, to extend the patent +license to downstream recipients. "Knowingly relying" means you have +actual knowledge that, but for the patent license, your conveying the +covered work in a country, or your recipient's use of the covered work +in a country, would infringe one or more identifiable patents in that +country that you have reason to believe are valid. + + If, pursuant to or in connection with a single transaction or +arrangement, you convey, or propagate by procuring conveyance of, a +covered work, and grant a patent license to some of the parties +receiving the covered work authorizing them to use, propagate, modify +or convey a specific copy of the covered work, then the patent license +you grant is automatically extended to all recipients of the covered +work and works based on it. + + A patent license is "discriminatory" if it does not include within +the scope of its coverage, prohibits the exercise of, or is +conditioned on the non-exercise of one or more of the rights that are +specifically granted under this License. You may not convey a covered +work if you are a party to an arrangement with a third party that is +in the business of distributing software, under which you make payment +to the third party based on the extent of your activity of conveying +the work, and under which the third party grants, to any of the +parties who would receive the covered work from you, a discriminatory +patent license (a) in connection with copies of the covered work +conveyed by you (or copies made from those copies), or (b) primarily +for and in connection with specific products or compilations that +contain the covered work, unless you entered into that arrangement, +or that patent license was granted, prior to 28 March 2007. + + Nothing in this License shall be construed as excluding or limiting +any implied license or other defenses to infringement that may +otherwise be available to you under applicable patent law. + + 12. No Surrender of Others' Freedom. + + If conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot convey a +covered work so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you may +not convey it at all. For example, if you agree to terms that obligate you +to collect a royalty for further conveying from those to whom you convey +the Program, the only way you could satisfy both those terms and this +License would be to refrain entirely from conveying the Program. + + 13. Use with the GNU Affero General Public License. + + Notwithstanding any other provision of this License, you have +permission to link or combine any covered work with a work licensed +under version 3 of the GNU Affero General Public License into a single +combined work, and to convey the resulting work. The terms of this +License will continue to apply to the part which is the covered work, +but the special requirements of the GNU Affero General Public License, +section 13, concerning interaction through a network will apply to the +combination as such. + + 14. Revised Versions of this License. + + The Free Software Foundation may publish revised and/or new versions of +the GNU General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + + Each version is given a distinguishing version number. If the +Program specifies that a certain numbered version of the GNU General +Public License "or any later version" applies to it, you have the +option of following the terms and conditions either of that numbered +version or of any later version published by the Free Software +Foundation. If the Program does not specify a version number of the +GNU General Public License, you may choose any version ever published +by the Free Software Foundation. + + If the Program specifies that a proxy can decide which future +versions of the GNU General Public License can be used, that proxy's +public statement of acceptance of a version permanently authorizes you +to choose that version for the Program. + + Later license versions may give you additional or different +permissions. However, no additional obligations are imposed on any +author or copyright holder as a result of your choosing to follow a +later version. + + 15. Disclaimer of Warranty. + + THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY +APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT +HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY +OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, +THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM +IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF +ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. Limitation of Liability. + + IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS +THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY +GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE +USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF +DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD +PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), +EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF +SUCH DAMAGES. + + 17. Interpretation of Sections 15 and 16. + + If the disclaimer of warranty and limitation of liability provided +above cannot be given local legal effect according to their terms, +reviewing courts shall apply local law that most closely approximates +an absolute waiver of all civil liability in connection with the +Program, unless a warranty or assumption of liability accompanies a +copy of the Program in return for a fee. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +state the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + copyright (c) by Bruce Korb - all rights reserved + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + +Also add information on how to contact you by electronic and paper mail. + + If the program does terminal interaction, make it output a short +notice like this when it starts in an interactive mode: + + copyright (c) by Bruce Korb - all rights reserved + This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, your program's commands +might be different; for a GUI interface, you would use an "about box". + + You should also get your employer (if you work as a programmer) or school, +if any, to sign a "copyright disclaimer" for the program, if necessary. +For more information on this, and how to apply and follow the GNU GPL, see +. + + The GNU General Public License does not permit incorporating your program +into proprietary programs. If your program is a subroutine library, you +may consider it more useful to permit linking proprietary applications with +the library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. But first, please read +. diff -urN src/contrib/ntp/sntp/libopts/COPYING.lgpl src.ntp/contrib/ntp/sntp/libopts/COPYING.lgpl --- src/contrib/ntp/sntp/libopts/COPYING.lgpl 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/COPYING.lgpl 1970-01-01 01:00:00.000000000 +0100 @@ -1,502 +0,0 @@ - GNU LESSER GENERAL PUBLIC LICENSE - Version 2.1, February 1999 - - Copyright (C) 1991, 1999 Free Software Foundation, Inc. - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - -[This is the first released version of the Lesser GPL. It also counts - as the successor of the GNU Library Public License, version 2, hence - the version number 2.1.] - - Preamble - - The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -Licenses are intended to guarantee your freedom to share and change -free software--to make sure the software is free for all its users. - - This license, the Lesser General Public License, applies to some -specially designated software packages--typically libraries--of the -Free Software Foundation and other authors who decide to use it. You -can use it too, but we suggest you first think carefully about whether -this license or the ordinary General Public License is the better -strategy to use in any particular case, based on the explanations below. - - When we speak of free software, we are referring to freedom of use, -not price. Our General Public Licenses are designed to make sure that -you have the freedom to distribute copies of free software (and charge -for this service if you wish); that you receive source code or can get -it if you want it; that you can change the software and use pieces of -it in new free programs; and that you are informed that you can do -these things. - - To protect your rights, we need to make restrictions that forbid -distributors to deny you these rights or to ask you to surrender these -rights. These restrictions translate to certain responsibilities for -you if you distribute copies of the library or if you modify it. - - For example, if you distribute copies of the library, whether gratis -or for a fee, you must give the recipients all the rights that we gave -you. You must make sure that they, too, receive or can get the source -code. If you link other code with the library, you must provide -complete object files to the recipients, so that they can relink them -with the library after making changes to the library and recompiling -it. And you must show them these terms so they know their rights. - - We protect your rights with a two-step method: (1) we copyright the -library, and (2) we offer you this license, which gives you legal -permission to copy, distribute and/or modify the library. - - To protect each distributor, we want to make it very clear that -there is no warranty for the free library. Also, if the library is -modified by someone else and passed on, the recipients should know -that what they have is not the original version, so that the original -author's reputation will not be affected by problems that might be -introduced by others. - - Finally, software patents pose a constant threat to the existence of -any free program. We wish to make sure that a company cannot -effectively restrict the users of a free program by obtaining a -restrictive license from a patent holder. Therefore, we insist that -any patent license obtained for a version of the library must be -consistent with the full freedom of use specified in this license. - - Most GNU software, including some libraries, is covered by the -ordinary GNU General Public License. This license, the GNU Lesser -General Public License, applies to certain designated libraries, and -is quite different from the ordinary General Public License. We use -this license for certain libraries in order to permit linking those -libraries into non-free programs. - - When a program is linked with a library, whether statically or using -a shared library, the combination of the two is legally speaking a -combined work, a derivative of the original library. The ordinary -General Public License therefore permits such linking only if the -entire combination fits its criteria of freedom. The Lesser General -Public License permits more lax criteria for linking other code with -the library. - - We call this license the "Lesser" General Public License because it -does Less to protect the user's freedom than the ordinary General -Public License. It also provides other free software developers Less -of an advantage over competing non-free programs. These disadvantages -are the reason we use the ordinary General Public License for many -libraries. However, the Lesser license provides advantages in certain -special circumstances. - - For example, on rare occasions, there may be a special need to -encourage the widest possible use of a certain library, so that it becomes -a de-facto standard. To achieve this, non-free programs must be -allowed to use the library. A more frequent case is that a free -library does the same job as widely used non-free libraries. In this -case, there is little to gain by limiting the free library to free -software only, so we use the Lesser General Public License. - - In other cases, permission to use a particular library in non-free -programs enables a greater number of people to use a large body of -free software. For example, permission to use the GNU C Library in -non-free programs enables many more people to use the whole GNU -operating system, as well as its variant, the GNU/Linux operating -system. - - Although the Lesser General Public License is Less protective of the -users' freedom, it does ensure that the user of a program that is -linked with the Library has the freedom and the wherewithal to run -that program using a modified version of the Library. - - The precise terms and conditions for copying, distribution and -modification follow. Pay close attention to the difference between a -"work based on the library" and a "work that uses the library". The -former contains code derived from the library, whereas the latter must -be combined with the library in order to run. - - GNU LESSER GENERAL PUBLIC LICENSE - TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - - 0. This License Agreement applies to any software library or other -program which contains a notice placed by the copyright holder or -other authorized party saying it may be distributed under the terms of -this Lesser General Public License (also called "this License"). -Each licensee is addressed as "you". - - A "library" means a collection of software functions and/or data -prepared so as to be conveniently linked with application programs -(which use some of those functions and data) to form executables. - - The "Library", below, refers to any such software library or work -which has been distributed under these terms. A "work based on the -Library" means either the Library or any derivative work under -copyright law: that is to say, a work containing the Library or a -portion of it, either verbatim or with modifications and/or translated -straightforwardly into another language. (Hereinafter, translation is -included without limitation in the term "modification".) - - "Source code" for a work means the preferred form of the work for -making modifications to it. For a library, complete source code means -all the source code for all modules it contains, plus any associated -interface definition files, plus the scripts used to control compilation -and installation of the library. - - Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running a program using the Library is not restricted, and output from -such a program is covered only if its contents constitute a work based -on the Library (independent of the use of the Library in a tool for -writing it). Whether that is true depends on what the Library does -and what the program that uses the Library does. - - 1. You may copy and distribute verbatim copies of the Library's -complete source code as you receive it, in any medium, provided that -you conspicuously and appropriately publish on each copy an -appropriate copyright notice and disclaimer of warranty; keep intact -all the notices that refer to this License and to the absence of any -warranty; and distribute a copy of this License along with the -Library. - - You may charge a fee for the physical act of transferring a copy, -and you may at your option offer warranty protection in exchange for a -fee. - - 2. You may modify your copy or copies of the Library or any portion -of it, thus forming a work based on the Library, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - - a) The modified work must itself be a software library. - - b) You must cause the files modified to carry prominent notices - stating that you changed the files and the date of any change. - - c) You must cause the whole of the work to be licensed at no - charge to all third parties under the terms of this License. - - d) If a facility in the modified Library refers to a function or a - table of data to be supplied by an application program that uses - the facility, other than as an argument passed when the facility - is invoked, then you must make a good faith effort to ensure that, - in the event an application does not supply such function or - table, the facility still operates, and performs whatever part of - its purpose remains meaningful. - - (For example, a function in a library to compute square roots has - a purpose that is entirely well-defined independent of the - application. Therefore, Subsection 2d requires that any - application-supplied function or table used by this function must - be optional: if the application does not supply it, the square - root function must still compute square roots.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Library, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Library, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote -it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Library. - -In addition, mere aggregation of another work not based on the Library -with the Library (or with a work based on the Library) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - - 3. You may opt to apply the terms of the ordinary GNU General Public -License instead of this License to a given copy of the Library. To do -this, you must alter all the notices that refer to this License, so -that they refer to the ordinary GNU General Public License, version 2, -instead of to this License. (If a newer version than version 2 of the -ordinary GNU General Public License has appeared, then you can specify -that version instead if you wish.) Do not make any other change in -these notices. - - Once this change is made in a given copy, it is irreversible for -that copy, so the ordinary GNU General Public License applies to all -subsequent copies and derivative works made from that copy. - - This option is useful when you wish to copy part of the code of -the Library into a program that is not a library. - - 4. You may copy and distribute the Library (or a portion or -derivative of it, under Section 2) in object code or executable form -under the terms of Sections 1 and 2 above provided that you accompany -it with the complete corresponding machine-readable source code, which -must be distributed under the terms of Sections 1 and 2 above on a -medium customarily used for software interchange. - - If distribution of object code is made by offering access to copy -from a designated place, then offering equivalent access to copy the -source code from the same place satisfies the requirement to -distribute the source code, even though third parties are not -compelled to copy the source along with the object code. - - 5. A program that contains no derivative of any portion of the -Library, but is designed to work with the Library by being compiled or -linked with it, is called a "work that uses the Library". Such a -work, in isolation, is not a derivative work of the Library, and -therefore falls outside the scope of this License. - - However, linking a "work that uses the Library" with the Library -creates an executable that is a derivative of the Library (because it -contains portions of the Library), rather than a "work that uses the -library". The executable is therefore covered by this License. -Section 6 states terms for distribution of such executables. - - When a "work that uses the Library" uses material from a header file -that is part of the Library, the object code for the work may be a -derivative work of the Library even though the source code is not. -Whether this is true is especially significant if the work can be -linked without the Library, or if the work is itself a library. The -threshold for this to be true is not precisely defined by law. - - If such an object file uses only numerical parameters, data -structure layouts and accessors, and small macros and small inline -functions (ten lines or less in length), then the use of the object -file is unrestricted, regardless of whether it is legally a derivative -work. (Executables containing this object code plus portions of the -Library will still fall under Section 6.) - - Otherwise, if the work is a derivative of the Library, you may -distribute the object code for the work under the terms of Section 6. -Any executables containing that work also fall under Section 6, -whether or not they are linked directly with the Library itself. - - 6. As an exception to the Sections above, you may also combine or -link a "work that uses the Library" with the Library to produce a -work containing portions of the Library, and distribute that work -under terms of your choice, provided that the terms permit -modification of the work for the customer's own use and reverse -engineering for debugging such modifications. - - You must give prominent notice with each copy of the work that the -Library is used in it and that the Library and its use are covered by -this License. You must supply a copy of this License. If the work -during execution displays copyright notices, you must include the -copyright notice for the Library among them, as well as a reference -directing the user to the copy of this License. Also, you must do one -of these things: - - a) Accompany the work with the complete corresponding - machine-readable source code for the Library including whatever - changes were used in the work (which must be distributed under - Sections 1 and 2 above); and, if the work is an executable linked - with the Library, with the complete machine-readable "work that - uses the Library", as object code and/or source code, so that the - user can modify the Library and then relink to produce a modified - executable containing the modified Library. (It is understood - that the user who changes the contents of definitions files in the - Library will not necessarily be able to recompile the application - to use the modified definitions.) - - b) Use a suitable shared library mechanism for linking with the - Library. A suitable mechanism is one that (1) uses at run time a - copy of the library already present on the user's computer system, - rather than copying library functions into the executable, and (2) - will operate properly with a modified version of the library, if - the user installs one, as long as the modified version is - interface-compatible with the version that the work was made with. - - c) Accompany the work with a written offer, valid for at - least three years, to give the same user the materials - specified in Subsection 6a, above, for a charge no more - than the cost of performing this distribution. - - d) If distribution of the work is made by offering access to copy - from a designated place, offer equivalent access to copy the above - specified materials from the same place. - - e) Verify that the user has already received a copy of these - materials or that you have already sent this user a copy. - - For an executable, the required form of the "work that uses the -Library" must include any data and utility programs needed for -reproducing the executable from it. However, as a special exception, -the materials to be distributed need not include anything that is -normally distributed (in either source or binary form) with the major -components (compiler, kernel, and so on) of the operating system on -which the executable runs, unless that component itself accompanies -the executable. - - It may happen that this requirement contradicts the license -restrictions of other proprietary libraries that do not normally -accompany the operating system. Such a contradiction means you cannot -use both them and the Library together in an executable that you -distribute. - - 7. You may place library facilities that are a work based on the -Library side-by-side in a single library together with other library -facilities not covered by this License, and distribute such a combined -library, provided that the separate distribution of the work based on -the Library and of the other library facilities is otherwise -permitted, and provided that you do these two things: - - a) Accompany the combined library with a copy of the same work - based on the Library, uncombined with any other library - facilities. This must be distributed under the terms of the - Sections above. - - b) Give prominent notice with the combined library of the fact - that part of it is a work based on the Library, and explaining - where to find the accompanying uncombined form of the same work. - - 8. You may not copy, modify, sublicense, link with, or distribute -the Library except as expressly provided under this License. Any -attempt otherwise to copy, modify, sublicense, link with, or -distribute the Library is void, and will automatically terminate your -rights under this License. However, parties who have received copies, -or rights, from you under this License will not have their licenses -terminated so long as such parties remain in full compliance. - - 9. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Library or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Library (or any work based on the -Library), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Library or works based on it. - - 10. Each time you redistribute the Library (or any work based on the -Library), the recipient automatically receives a license from the -original licensor to copy, distribute, link with or modify the Library -subject to these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties with -this License. - - 11. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Library at all. For example, if a patent -license would not permit royalty-free redistribution of the Library by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Library. - -If any portion of this section is held invalid or unenforceable under any -particular circumstance, the balance of the section is intended to apply, -and the section as a whole is intended to apply in other circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - - 12. If the distribution and/or use of the Library is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Library under this License may add -an explicit geographical distribution limitation excluding those countries, -so that distribution is permitted only in or among countries not thus -excluded. In such case, this License incorporates the limitation as if -written in the body of this License. - - 13. The Free Software Foundation may publish revised and/or new -versions of the Lesser General Public License from time to time. -Such new versions will be similar in spirit to the present version, -but may differ in detail to address new problems or concerns. - -Each version is given a distinguishing version number. If the Library -specifies a version number of this License which applies to it and -"any later version", you have the option of following the terms and -conditions either of that version or of any later version published by -the Free Software Foundation. If the Library does not specify a -license version number, you may choose any version ever published by -the Free Software Foundation. - - 14. If you wish to incorporate parts of the Library into other free -programs whose distribution conditions are incompatible with these, -write to the author to ask for permission. For software which is -copyrighted by the Free Software Foundation, write to the Free -Software Foundation; we sometimes make exceptions for this. Our -decision will be guided by the two goals of preserving the free status -of all derivatives of our free software and of promoting the sharing -and reuse of software generally. - - NO WARRANTY - - 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO -WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. -EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR -OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY -KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE -IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE -LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME -THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN -WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY -AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU -FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR -CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE -LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING -RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A -FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF -SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH -DAMAGES. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Libraries - - If you develop a new library, and you want it to be of the greatest -possible use to the public, we recommend making it free software that -everyone can redistribute and change. You can do so by permitting -redistribution under these terms (or, alternatively, under the terms of the -ordinary General Public License). - - To apply these terms, attach the following notices to the library. It is -safest to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least the -"copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA - -Also add information on how to contact you by electronic and paper mail. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the library, if -necessary. Here is a sample; alter the names: - - Yoyodyne, Inc., hereby disclaims all copyright interest in the - library `Frob' (a library for tweaking knobs) written by James Random Hacker. - - , 1 April 1990 - Ty Coon, President of Vice - -That's all there is to it! diff -urN src/contrib/ntp/sntp/libopts/COPYING.lgplv3 src.ntp/contrib/ntp/sntp/libopts/COPYING.lgplv3 --- src/contrib/ntp/sntp/libopts/COPYING.lgplv3 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/libopts/COPYING.lgplv3 2009-12-09 08:36:46.000000000 +0100 @@ -0,0 +1,165 @@ + GNU LESSER GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 + + copyright (c) 2009 by Bruce Korb - all rights reserved + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + + This version of the GNU Lesser General Public License incorporates +the terms and conditions of version 3 of the GNU General Public +License, supplemented by the additional permissions listed below. + + 0. Additional Definitions. + + As used herein, "this License" refers to version 3 of the GNU Lesser +General Public License, and the "GNU GPL" refers to version 3 of the GNU +General Public License. + + "The Library" refers to a covered work governed by this License, +other than an Application or a Combined Work as defined below. + + An "Application" is any work that makes use of an interface provided +by the Library, but which is not otherwise based on the Library. +Defining a subclass of a class defined by the Library is deemed a mode +of using an interface provided by the Library. + + A "Combined Work" is a work produced by combining or linking an +Application with the Library. The particular version of the Library +with which the Combined Work was made is also called the "Linked +Version". + + The "Minimal Corresponding Source" for a Combined Work means the +Corresponding Source for the Combined Work, excluding any source code +for portions of the Combined Work that, considered in isolation, are +based on the Application, and not on the Linked Version. + + The "Corresponding Application Code" for a Combined Work means the +object code and/or source code for the Application, including any data +and utility programs needed for reproducing the Combined Work from the +Application, but excluding the System Libraries of the Combined Work. + + 1. Exception to Section 3 of the GNU GPL. + + You may convey a covered work under sections 3 and 4 of this License +without being bound by section 3 of the GNU GPL. + + 2. Conveying Modified Versions. + + If you modify a copy of the Library, and, in your modifications, a +facility refers to a function or data to be supplied by an Application +that uses the facility (other than as an argument passed when the +facility is invoked), then you may convey a copy of the modified +version: + + a) under this License, provided that you make a good faith effort to + ensure that, in the event an Application does not supply the + function or data, the facility still operates, and performs + whatever part of its purpose remains meaningful, or + + b) under the GNU GPL, with none of the additional permissions of + this License applicable to that copy. + + 3. Object Code Incorporating Material from Library Header Files. + + The object code form of an Application may incorporate material from +a header file that is part of the Library. You may convey such object +code under terms of your choice, provided that, if the incorporated +material is not limited to numerical parameters, data structure +layouts and accessors, or small macros, inline functions and templates +(ten or fewer lines in length), you do both of the following: + + a) Give prominent notice with each copy of the object code that the + Library is used in it and that the Library and its use are + covered by this License. + + b) Accompany the object code with a copy of the GNU GPL and this license + document. + + 4. Combined Works. + + You may convey a Combined Work under terms of your choice that, +taken together, effectively do not restrict modification of the +portions of the Library contained in the Combined Work and reverse +engineering for debugging such modifications, if you also do each of +the following: + + a) Give prominent notice with each copy of the Combined Work that + the Library is used in it and that the Library and its use are + covered by this License. + + b) Accompany the Combined Work with a copy of the GNU GPL and this license + document. + + c) For a Combined Work that displays copyright notices during + execution, include the copyright notice for the Library among + these notices, as well as a reference directing the user to the + copies of the GNU GPL and this license document. + + d) Do one of the following: + + 0) Convey the Minimal Corresponding Source under the terms of this + License, and the Corresponding Application Code in a form + suitable for, and under terms that permit, the user to + recombine or relink the Application with a modified version of + the Linked Version to produce a modified Combined Work, in the + manner specified by section 6 of the GNU GPL for conveying + Corresponding Source. + + 1) Use a suitable shared library mechanism for linking with the + Library. A suitable mechanism is one that (a) uses at run time + a copy of the Library already present on the user's computer + system, and (b) will operate properly with a modified version + of the Library that is interface-compatible with the Linked + Version. + + e) Provide Installation Information, but only if you would otherwise + be required to provide such information under section 6 of the + GNU GPL, and only to the extent that such information is + necessary to install and execute a modified version of the + Combined Work produced by recombining or relinking the + Application with a modified version of the Linked Version. (If + you use option 4d0, the Installation Information must accompany + the Minimal Corresponding Source and Corresponding Application + Code. If you use option 4d1, you must provide the Installation + Information in the manner specified by section 6 of the GNU GPL + for conveying Corresponding Source.) + + 5. Combined Libraries. + + You may place library facilities that are a work based on the +Library side by side in a single library together with other library +facilities that are not Applications and are not covered by this +License, and convey such a combined library under terms of your +choice, if you do both of the following: + + a) Accompany the combined library with a copy of the same work based + on the Library, uncombined with any other library facilities, + conveyed under the terms of this License. + + b) Give prominent notice with the combined library that part of it + is a work based on the Library, and explaining where to find the + accompanying uncombined form of the same work. + + 6. Revised Versions of the GNU Lesser General Public License. + + The Free Software Foundation may publish revised and/or new versions +of the GNU Lesser General Public License from time to time. Such new +versions will be similar in spirit to the present version, but may +differ in detail to address new problems or concerns. + + Each version is given a distinguishing version number. If the +Library as you received it specifies that a certain numbered version +of the GNU Lesser General Public License "or any later version" +applies to it, you have the option of following the terms and +conditions either of that published version or of any later version +published by the Free Software Foundation. If the Library as you +received it does not specify a version number of the GNU Lesser +General Public License, you may choose any version of the GNU Lesser +General Public License ever published by the Free Software Foundation. + + If the Library as you received it specifies that a proxy can decide +whether future versions of the GNU Lesser General Public License shall +apply, that proxy's public statement of acceptance of any version is +permanent authorization for you to choose that version for the +Library. diff -urN src/contrib/ntp/sntp/libopts/Makefile.am src.ntp/contrib/ntp/sntp/libopts/Makefile.am --- src/contrib/ntp/sntp/libopts/Makefile.am 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/Makefile.am 2009-12-09 08:36:46.000000000 +0100 @@ -7,18 +7,22 @@ endif libopts_la_SOURCES = libopts.c libopts_la_CPPFLAGS = -I$(top_srcdir) -libopts_la_LDFLAGS = -version-info 29:0:4 +libopts_la_LDFLAGS = -version-info 33:0:8 EXTRA_DIST = \ - COPYING.lgpl COPYING.mbsd MakeDefs.inc \ - README autoopts/options.h autoopts/usage-txt.h \ - autoopts.c autoopts.h boolean.c \ - compat/windows-config.h compat/compat.h compat/pathfind.c \ - compat/snprintf.c compat/strdup.c compat/strchr.c \ - configfile.c cook.c enumeration.c \ - environment.c genshell.c genshell.h \ + COPYING.gplv3 COPYING.lgplv3 COPYING.mbsd \ + MakeDefs.inc README ag-char-map.h \ + autoopts/options.h autoopts/usage-txt.h autoopts.c \ + autoopts.h boolean.c compat/windows-config.h \ + compat/compat.h compat/pathfind.c compat/snprintf.c \ + compat/strdup.c compat/strchr.c configfile.c \ + cook.c enumeration.c environment.c \ + file.c genshell.c genshell.h \ load.c m4/libopts.m4 m4/liboptschk.m4 \ makeshell.c nested.c numeric.c \ - pgusage.c proto.h putshell.c \ + parse-duration.c parse-duration.h pgusage.c \ + proto.h putshell.c reset.c \ restore.c save.c sort.c \ stack.c streqvcmp.c text_mmap.c \ - tokenize.c usage.c version.c + time.c tokenize.c usage.c \ + value-type.c value-type.h version.c \ + xat-attribute.c xat-attribute.h diff -urN src/contrib/ntp/sntp/libopts/Makefile.in src.ntp/contrib/ntp/sntp/libopts/Makefile.in --- src/contrib/ntp/sntp/libopts/Makefile.in 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/libopts/Makefile.in 2010-07-09 04:24:44.000000000 +0200 @@ -38,6 +38,9 @@ DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ + $(top_srcdir)/../m4/ntp_cacheversion.m4 \ + $(top_srcdir)/../m4/ntp_dir_sep.m4 \ + $(top_srcdir)/../m4/ntp_openssl.m4 $(top_srcdir)/../version.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) @@ -123,6 +126,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LCRYPTO = @LCRYPTO@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ @@ -135,6 +139,9 @@ MAKEINFO = @MAKEINFO@ MKDIR_P = @MKDIR_P@ OBJEXT = @OBJEXT@ +OPENSSL = @OPENSSL@ +OPENSSL_INC = @OPENSSL_INC@ +OPENSSL_LIB = @OPENSSL_LIB@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -203,21 +210,25 @@ @INSTALL_LIBOPTS_FALSE@noinst_LTLIBRARIES = libopts.la libopts_la_SOURCES = libopts.c libopts_la_CPPFLAGS = -I$(top_srcdir) -libopts_la_LDFLAGS = -version-info 29:0:4 +libopts_la_LDFLAGS = -version-info 33:0:8 EXTRA_DIST = \ - COPYING.lgpl COPYING.mbsd MakeDefs.inc \ - README autoopts/options.h autoopts/usage-txt.h \ - autoopts.c autoopts.h boolean.c \ - compat/windows-config.h compat/compat.h compat/pathfind.c \ - compat/snprintf.c compat/strdup.c compat/strchr.c \ - configfile.c cook.c enumeration.c \ - environment.c genshell.c genshell.h \ + COPYING.gplv3 COPYING.lgplv3 COPYING.mbsd \ + MakeDefs.inc README ag-char-map.h \ + autoopts/options.h autoopts/usage-txt.h autoopts.c \ + autoopts.h boolean.c compat/windows-config.h \ + compat/compat.h compat/pathfind.c compat/snprintf.c \ + compat/strdup.c compat/strchr.c configfile.c \ + cook.c enumeration.c environment.c \ + file.c genshell.c genshell.h \ load.c m4/libopts.m4 m4/liboptschk.m4 \ makeshell.c nested.c numeric.c \ - pgusage.c proto.h putshell.c \ + parse-duration.c parse-duration.h pgusage.c \ + proto.h putshell.c reset.c \ restore.c save.c sort.c \ stack.c streqvcmp.c text_mmap.c \ - tokenize.c usage.c version.c + time.c tokenize.c usage.c \ + value-type.c value-type.h version.c \ + xat-attribute.c xat-attribute.h all: all-am @@ -232,9 +243,9 @@ exit 1;; \ esac; \ done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu libopts/Makefile'; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign libopts/Makefile'; \ $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --gnu libopts/Makefile + $(AUTOMAKE) --foreign libopts/Makefile .PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ diff -urN src/contrib/ntp/sntp/libopts/README src.ntp/contrib/ntp/sntp/libopts/README --- src/contrib/ntp/sntp/libopts/README 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/README 2009-12-09 08:36:46.000000000 +0100 @@ -85,7 +85,7 @@ LICENSING: -This material is copyright 1993-2007 by Bruce Korb. +This material is copyright (c) 1993-2009 by Bruce Korb. You are licensed to use this under the terms of either the GNU Lesser General Public License (see: COPYING.lgpl), or, at your option, the modified Berkeley Software Distribution diff -urN src/contrib/ntp/sntp/libopts/ag-char-map.h src.ntp/contrib/ntp/sntp/libopts/ag-char-map.h --- src/contrib/ntp/sntp/libopts/ag-char-map.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/libopts/ag-char-map.h 2009-12-09 08:36:46.000000000 +0100 @@ -0,0 +1,160 @@ +/* + * Character mapping generated 11/08/09 08:41:19 + * + * This file contains the character classifications + * used by AutoGen and AutoOpts for identifying tokens. + */ +#ifndef AG_CHAR_MAP_H_GUARD +#define AG_CHAR_MAP_H_GUARD 1 + +#ifdef HAVE_CONFIG_H +# if defined(HAVE_INTTYPES_H) +# include +# elif defined(HAVE_STDINT_H) +# include + +# else +# ifndef HAVE_INT8_T + typedef signed char int8_t; +# endif +# ifndef HAVE_UINT8_T + typedef unsigned char uint8_t; +# endif +# ifndef HAVE_INT16_T + typedef signed short int16_t; +# endif +# ifndef HAVE_UINT16_T + typedef unsigned short uint16_t; +# endif +# ifndef HAVE_UINT_T + typedef unsigned int uint_t; +# endif + +# ifndef HAVE_INT32_T +# if SIZEOF_INT == 4 + typedef signed int int32_t; +# elif SIZEOF_LONG == 4 + typedef signed long int32_t; +# endif +# endif + +# ifndef HAVE_UINT32_T +# if SIZEOF_INT == 4 + typedef unsigned int uint32_t; +# elif SIZEOF_LONG == 4 + typedef unsigned long uint32_t; +# endif +# endif +# endif /* HAVE_*INT*_H header */ + +#else /* not HAVE_CONFIG_H -- */ +# ifdef __sun +# include +# else +# include +# endif +#endif /* HAVE_CONFIG_H */ + +#if 0 /* mapping specification source (from autogen.map) */ +// +// %guard autoopts_internal +// %file ag-char-map.h +// %table opt-char-cat +// +// %comment +// This file contains the character classifications +// used by AutoGen and AutoOpts for identifying tokens. +// % +// +// lower-case "a-z" +// upper-case "A-Z" +// alphabetic +lower-case +upper-case +// oct-digit "0-7" +// dec-digit "89" +oct-digit +// hex-digit "a-fA-F" +dec-digit +// alphanumeric +alphabetic +dec-digit +// var-first "_" +alphabetic +// variable-name +var-first +dec-digit +// option-name "^-" +variable-name +// value-name ":" +option-name +// horiz-white "\t " +// compound-name "[.]" +value-name +horiz-white +// whitespace "\v\f\r\n\b" +horiz-white +// unquotable "!-~" -"\"#(),;<=>[\\]`{}?*'" +// end-xml-token "/>" +whitespace +// graphic "!-~" +// plus-n-space "+" +whitespace +// punctuation "!-~" -alphanumeric -"_" +// suffix "-._" +alphanumeric +// suffix-fmt "%/" +suffix +// false-type "nNfF0\x00" +// +#endif /* 0 -- mapping spec. source */ + +typedef uint32_t opt_char_cat_mask_t; +extern opt_char_cat_mask_t const opt_char_cat[128]; + +static inline int is_opt_char_cat_char(char ch, opt_char_cat_mask_t mask) { + unsigned int ix = (unsigned char)ch; + return ((ix < 0x7F) && ((opt_char_cat[ix] & mask) != 0)); } + +#define IS_LOWER_CASE_CHAR(_c) is_opt_char_cat_char((_c), 0x00001) +#define IS_UPPER_CASE_CHAR(_c) is_opt_char_cat_char((_c), 0x00002) +#define IS_ALPHABETIC_CHAR(_c) is_opt_char_cat_char((_c), 0x00003) +#define IS_OCT_DIGIT_CHAR(_c) is_opt_char_cat_char((_c), 0x00004) +#define IS_DEC_DIGIT_CHAR(_c) is_opt_char_cat_char((_c), 0x0000C) +#define IS_HEX_DIGIT_CHAR(_c) is_opt_char_cat_char((_c), 0x0001C) +#define IS_ALPHANUMERIC_CHAR(_c) is_opt_char_cat_char((_c), 0x0000F) +#define IS_VAR_FIRST_CHAR(_c) is_opt_char_cat_char((_c), 0x00023) +#define IS_VARIABLE_NAME_CHAR(_c) is_opt_char_cat_char((_c), 0x0002F) +#define IS_OPTION_NAME_CHAR(_c) is_opt_char_cat_char((_c), 0x0006F) +#define IS_VALUE_NAME_CHAR(_c) is_opt_char_cat_char((_c), 0x000EF) +#define IS_HORIZ_WHITE_CHAR(_c) is_opt_char_cat_char((_c), 0x00100) +#define IS_COMPOUND_NAME_CHAR(_c) is_opt_char_cat_char((_c), 0x003EF) +#define IS_WHITESPACE_CHAR(_c) is_opt_char_cat_char((_c), 0x00500) +#define IS_UNQUOTABLE_CHAR(_c) is_opt_char_cat_char((_c), 0x00800) +#define IS_END_XML_TOKEN_CHAR(_c) is_opt_char_cat_char((_c), 0x01500) +#define IS_GRAPHIC_CHAR(_c) is_opt_char_cat_char((_c), 0x02000) +#define IS_PLUS_N_SPACE_CHAR(_c) is_opt_char_cat_char((_c), 0x04500) +#define IS_PUNCTUATION_CHAR(_c) is_opt_char_cat_char((_c), 0x08000) +#define IS_SUFFIX_CHAR(_c) is_opt_char_cat_char((_c), 0x1000F) +#define IS_SUFFIX_FMT_CHAR(_c) is_opt_char_cat_char((_c), 0x3000F) +#define IS_FALSE_TYPE_CHAR(_c) is_opt_char_cat_char((_c), 0x40000) + +#ifdef AUTOOPTS_INTERNAL +opt_char_cat_mask_t const opt_char_cat[128] = { + /*x00*/ 0x40000, /*x01*/ 0x00000, /*x02*/ 0x00000, /*x03*/ 0x00000, + /*x04*/ 0x00000, /*x05*/ 0x00000, /*x06*/ 0x00000, /*\a */ 0x00000, + /*\b */ 0x00400, /*\t */ 0x00100, /*\n */ 0x00400, /*\v */ 0x00400, + /*\f */ 0x00400, /*\r */ 0x00400, /*x0E*/ 0x00000, /*x0F*/ 0x00000, + /*x10*/ 0x00000, /*x11*/ 0x00000, /*x12*/ 0x00000, /*x13*/ 0x00000, + /*x14*/ 0x00000, /*x15*/ 0x00000, /*x16*/ 0x00000, /*x17*/ 0x00000, + /*x18*/ 0x00000, /*x19*/ 0x00000, /*x1A*/ 0x00000, /*x1B*/ 0x00000, + /*x1C*/ 0x00000, /*x1D*/ 0x00000, /*x1E*/ 0x00000, /*x1F*/ 0x00000, + /* */ 0x00100, /* ! */ 0x0A800, /* " */ 0x0A000, /* # */ 0x0A000, + /* $ */ 0x0A800, /* % */ 0x2A800, /* & */ 0x0A800, /* ' */ 0x0A000, + /* ( */ 0x0A000, /* ) */ 0x0A000, /* * */ 0x0A000, /* + */ 0x0E800, + /* , */ 0x0A000, /* - */ 0x1A840, /* . */ 0x1AA00, /* / */ 0x2B800, + /* 0 */ 0x42804, /* 1 */ 0x02804, /* 2 */ 0x02804, /* 3 */ 0x02804, + /* 4 */ 0x02804, /* 5 */ 0x02804, /* 6 */ 0x02804, /* 7 */ 0x02804, + /* 8 */ 0x02808, /* 9 */ 0x02808, /* : */ 0x0A880, /* ; */ 0x0A000, + /* < */ 0x0A000, /* = */ 0x0A000, /* > */ 0x0B000, /* ? */ 0x0A000, + /* @ */ 0x0A800, /* A */ 0x02812, /* B */ 0x02812, /* C */ 0x02812, + /* D */ 0x02812, /* E */ 0x02812, /* F */ 0x42812, /* G */ 0x02802, + /* H */ 0x02802, /* I */ 0x02802, /* J */ 0x02802, /* K */ 0x02802, + /* L */ 0x02802, /* M */ 0x02802, /* N */ 0x42802, /* O */ 0x02802, + /* P */ 0x02802, /* Q */ 0x02802, /* R */ 0x02802, /* S */ 0x02802, + /* T */ 0x02802, /* U */ 0x02802, /* V */ 0x02802, /* W */ 0x02802, + /* X */ 0x02802, /* Y */ 0x02802, /* Z */ 0x02802, /* [ */ 0x0A200, + /* \ */ 0x0A000, /* ] */ 0x0A200, /* ^ */ 0x0A840, /* _ */ 0x12820, + /* ` */ 0x0A000, /* a */ 0x02811, /* b */ 0x02811, /* c */ 0x02811, + /* d */ 0x02811, /* e */ 0x02811, /* f */ 0x42811, /* g */ 0x02801, + /* h */ 0x02801, /* i */ 0x02801, /* j */ 0x02801, /* k */ 0x02801, + /* l */ 0x02801, /* m */ 0x02801, /* n */ 0x42801, /* o */ 0x02801, + /* p */ 0x02801, /* q */ 0x02801, /* r */ 0x02801, /* s */ 0x02801, + /* t */ 0x02801, /* u */ 0x02801, /* v */ 0x02801, /* w */ 0x02801, + /* x */ 0x02801, /* y */ 0x02801, /* z */ 0x02801, /* { */ 0x0A000, + /* | */ 0x0A800, /* } */ 0x0A000, /* ~ */ 0x0A800, /*x7F*/ 0x00000 +}; +#endif /* AUTOOPTS_INTERNAL */ +#endif /* AG_CHAR_MAP_H_GUARD */ diff -urN src/contrib/ntp/sntp/libopts/autoopts/options.h src.ntp/contrib/ntp/sntp/libopts/autoopts/options.h --- src/contrib/ntp/sntp/libopts/autoopts/options.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/autoopts/options.h 2009-12-09 08:36:46.000000000 +0100 @@ -2,34 +2,32 @@ * * DO NOT EDIT THIS FILE (options.h) * - * It has been AutoGen-ed Saturday May 5, 2007 at 12:02:34 PM PDT + * It has been AutoGen-ed November 8, 2009 at 08:41:08 AM by AutoGen 5.9.10pre13 * From the definitions funcs.def * and the template file options_h * * This file defines all the global structures and special values * used in the automated option processing library. * - * Automated Options copyright 1992-Y Bruce Korb + * Automated Options copyright (c) 1992-Y by Bruce Korb * - * AutoOpts is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * AutoOpts is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with AutoOpts. If not, write to: - * The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor - * Boston, MA 02110-1301, USA. + * AutoOpts is free software: you can redistribute it and/or modify it + * under the terms of the GNU Lesser General Public License as published + * by the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * AutoOpts is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with this program. If not, see . */ #ifndef AUTOOPTS_OPTIONS_H_GUARD -#define AUTOOPTS_OPTIONS_H_GUARD +#define AUTOOPTS_OPTIONS_H_GUARD 1 #include +#include #if defined(HAVE_STDINT_H) # include @@ -68,8 +66,8 @@ * values for "opt_name" are available. */ -#define OPTIONS_STRUCT_VERSION 118784 -#define OPTIONS_VERSION_STRING "29:0:4" +#define OPTIONS_STRUCT_VERSION 135168 +#define OPTIONS_VERSION_STRING "33:0:8" #define OPTIONS_MINIMUM_VERSION 102400 #define OPTIONS_MIN_VER_STRING "25:0:0" @@ -80,7 +78,9 @@ OPARG_TYPE_BOOLEAN = 3, /* opt arg is boolean-valued */ OPARG_TYPE_MEMBERSHIP = 4, /* opt arg sets set membership bits */ OPARG_TYPE_NUMERIC = 5, /* opt arg has numeric value */ - OPARG_TYPE_HIERARCHY = 6 /* option arg is hierarchical value */ + OPARG_TYPE_HIERARCHY = 6, /* option arg is hierarchical value */ + OPARG_TYPE_FILE = 7, /* option arg names a file */ + OPARG_TYPE_TIME = 8 /* opt arg is a time duration */ } teOptArgType; typedef struct optionValue { @@ -96,6 +96,22 @@ } v; } tOptionValue; +typedef enum { + FTYPE_MODE_MAY_EXIST = 0x00, + FTYPE_MODE_MUST_EXIST = 0x01, + FTYPE_MODE_MUST_NOT_EXIST = 0x02, + FTYPE_MODE_EXIST_MASK = 0x03, + FTYPE_MODE_NO_OPEN = 0x00, + FTYPE_MODE_OPEN_FD = 0x10, + FTYPE_MODE_FOPEN_FP = 0x20, + FTYPE_MODE_OPEN_MASK = 0x30 +} teOptFileType; + +typedef union { + int file_flags; + char const * file_mode; +} tuFileMode; + /* * Bits in the fOptState option descriptor field. */ @@ -103,6 +119,7 @@ OPTST_SET_ID = 0, /* Set via the "SET_OPT()" macro */ OPTST_PRESET_ID = 1, /* Set via an RC/INI file */ OPTST_DEFINED_ID = 2, /* Set via a command line option */ + OPTST_RESET_ID = 3, /* Reset via command line option */ OPTST_EQUIVALENCE_ID = 4, /* selected by equiv'ed option */ OPTST_DISABLED_ID = 5, /* option is in disabled state */ OPTST_ALLOC_ARG_ID = 6, /* pzOptArg was allocated */ @@ -121,13 +138,17 @@ OPTST_MUST_SET_ID = 20, /* must be set or pre-set */ OPTST_DOCUMENT_ID = 21, /* opt is for doc only */ OPTST_TWICE_ID = 22, /* process opt twice - imm + reg */ - OPTST_DISABLE_TWICE_ID = 23 /* process disabled option twice */ + OPTST_DISABLE_TWICE_ID = 23, /* process disabled option twice */ + OPTST_SCALED_NUM_ID = 24, /* scaled integer value */ + OPTST_NO_COMMAND_ID = 25, /* disable from cmd line */ + OPTST_DEPRECATED_ID = 26 /* support is being removed */ } opt_state_enum_t; -#define OPTST_INIT 0U +#define OPTST_INIT 0U #define OPTST_SET (1U << OPTST_SET_ID) #define OPTST_PRESET (1U << OPTST_PRESET_ID) #define OPTST_DEFINED (1U << OPTST_DEFINED_ID) +#define OPTST_RESET (1U << OPTST_RESET_ID) #define OPTST_EQUIVALENCE (1U << OPTST_EQUIVALENCE_ID) #define OPTST_DISABLED (1U << OPTST_DISABLED_ID) #define OPTST_ALLOC_ARG (1U << OPTST_ALLOC_ARG_ID) @@ -147,30 +168,39 @@ #define OPTST_DOCUMENT (1U << OPTST_DOCUMENT_ID) #define OPTST_TWICE (1U << OPTST_TWICE_ID) #define OPTST_DISABLE_TWICE (1U << OPTST_DISABLE_TWICE_ID) -#define OPT_STATE_MASK 0x00FFFF77U - -#define OPTST_SET_MASK ( \ - OPTST_SET | \ - OPTST_PRESET | \ - OPTST_DEFINED ) - -#define OPTST_MUTABLE_MASK ( \ - OPTST_SET | \ - OPTST_PRESET | \ - OPTST_DEFINED | \ - OPTST_EQUIVALENCE | \ - OPTST_DISABLED | \ - OPTST_ALLOC_ARG ) - -#define OPTST_SELECTED_MASK ( \ - OPTST_SET | \ - OPTST_DEFINED ) - -#define OPTST_ARG_TYPE_MASK ( \ - OPTST_ARG_TYPE_1 | \ - OPTST_ARG_TYPE_2 | \ - OPTST_ARG_TYPE_3 | \ - OPTST_ARG_TYPE_4 ) +#define OPTST_SCALED_NUM (1U << OPTST_SCALED_NUM_ID) +#define OPTST_NO_COMMAND (1U << OPTST_NO_COMMAND_ID) +#define OPTST_DEPRECATED (1U << OPTST_DEPRECATED_ID) +#define OPT_STATE_MASK 0x07FFFF7FU + +#define OPTST_SET_MASK ( \ + OPTST_DEFINED | OPTST_PRESET | OPTST_RESET | \ + OPTST_SET \ + /* 0x0000000FU */ ) + +#define OPTST_MUTABLE_MASK ( \ + OPTST_ALLOC_ARG | OPTST_DEFINED | \ + OPTST_DISABLED | OPTST_EQUIVALENCE | \ + OPTST_PRESET | OPTST_RESET | \ + OPTST_SET \ + /* 0x0000007FU */ ) + +#define OPTST_SELECTED_MASK ( \ + OPTST_DEFINED | OPTST_SET \ + /* 0x00000005U */ ) + +#define OPTST_ARG_TYPE_MASK ( \ + OPTST_ARG_TYPE_1 | OPTST_ARG_TYPE_2 | OPTST_ARG_TYPE_3 | \ + OPTST_ARG_TYPE_4 \ + /* 0x0000F000U */ ) + +#define OPTST_DO_NOT_SAVE_MASK ( \ + OPTST_DOCUMENT | OPTST_NO_INIT | OPTST_OMITTED \ + /* 0x00280100U */ ) + +#define OPTST_NO_USAGE_MASK ( \ + OPTST_DEPRECATED | OPTST_NO_COMMAND | OPTST_OMITTED \ + /* 0x06080000U */ ) #ifdef NO_OPTIONAL_OPT_ARGS # undef OPTST_ARG_OPTIONAL @@ -179,13 +209,12 @@ #define OPTST_PERSISTENT_MASK (~OPTST_MUTABLE_MASK) -#define SELECTED_OPT( pod ) ((pod)->fOptState & OPTST_SELECTED_MASK) -#define UNUSED_OPT( pod ) (((pod)->fOptState & OPTST_SET_MASK) == 0) -#define DISABLED_OPT( pod ) ((pod)->fOptState & OPTST_DISABLED) -#define OPTION_STATE( pod ) ((pod)->fOptState) - -#define OPTST_SET_ARGTYPE(n) ((n) << OPTST_ARG_TYPE_1_ID) -#define OPTST_GET_ARGTYPE(f) (((f) & OPTST_ARG_TYPE_MASK)>>OPTST_ARG_TYPE_1_ID) +#define SELECTED_OPT(_od) ((_od)->fOptState & OPTST_SELECTED_MASK) +#define UNUSED_OPT( _od) (((_od)->fOptState & OPTST_SET_MASK) == 0) +#define DISABLED_OPT(_od) ((_od)->fOptState & OPTST_DISABLED) +#define OPTION_STATE(_od) ((_od)->fOptState) +#define OPTST_SET_ARGTYPE(_n) ((_n) << OPTST_ARG_TYPE_1_ID) +#define OPTST_GET_ARGTYPE(_f) (((_f)&OPTST_ARG_TYPE_MASK)>>OPTST_ARG_TYPE_1_ID) /* * PRIVATE INTERFACES @@ -199,42 +228,48 @@ * Define the processing state flags */ typedef enum { - OPTPROC_LONGOPT_ID = 0, /* Process long style options */ - OPTPROC_SHORTOPT_ID = 1, /* Process short style "flags" */ - OPTPROC_ERRSTOP_ID = 2, /* Stop on argument errors */ - OPTPROC_DISABLEDOPT_ID = 3, /* Current option is disabled */ - OPTPROC_NO_REQ_OPT_ID = 4, /* no options are required */ - OPTPROC_NUM_OPT_ID = 5, /* there is a number option */ - OPTPROC_INITDONE_ID = 6, /* have initializations been done? */ - OPTPROC_NEGATIONS_ID = 7, /* any negation options? */ - OPTPROC_ENVIRON_ID = 8, /* check environment? */ - OPTPROC_NO_ARGS_ID = 9, /* Disallow remaining arguments */ - OPTPROC_ARGS_REQ_ID = 10, /* Require arguments after options */ - OPTPROC_REORDER_ID = 11, /* reorder operands after options */ - OPTPROC_GNUUSAGE_ID = 12, /* emit usage in GNU style */ - OPTPROC_TRANSLATE_ID = 13, /* Translate strings in tOptions */ - OPTPROC_HAS_IMMED_ID = 14, /* program defines immed options */ - OPTPROC_PRESETTING_ID = 19 /* opt processing in preset state */ + OPTPROC_LONGOPT_ID = 0, /* Process long style options */ + OPTPROC_SHORTOPT_ID = 1, /* Process short style "flags" */ + OPTPROC_ERRSTOP_ID = 2, /* Stop on argument errors */ + OPTPROC_DISABLEDOPT_ID = 3, /* Current option is disabled */ + OPTPROC_NO_REQ_OPT_ID = 4, /* no options are required */ + OPTPROC_NUM_OPT_ID = 5, /* there is a number option */ + OPTPROC_INITDONE_ID = 6, /* have inits been done? */ + OPTPROC_NEGATIONS_ID = 7, /* any negation options? */ + OPTPROC_ENVIRON_ID = 8, /* check environment? */ + OPTPROC_NO_ARGS_ID = 9, /* Disallow remaining arguments */ + OPTPROC_ARGS_REQ_ID = 10, /* Require args after options */ + OPTPROC_REORDER_ID = 11, /* reorder operands after opts */ + OPTPROC_GNUUSAGE_ID = 12, /* emit usage in GNU style */ + OPTPROC_TRANSLATE_ID = 13, /* Translate strings in tOptions */ + OPTPROC_NXLAT_OPT_CFG_ID = 16, /* suppress for config only */ + OPTPROC_NXLAT_OPT_ID = 17, /* suppress xlation always */ + OPTPROC_PRESETTING_ID = 19 /* opt processing in preset state */ } optproc_state_enum_t; -#define OPTPROC_NONE 0U -#define OPTPROC_LONGOPT (1U << OPTPROC_LONGOPT_ID) -#define OPTPROC_SHORTOPT (1U << OPTPROC_SHORTOPT_ID) -#define OPTPROC_ERRSTOP (1U << OPTPROC_ERRSTOP_ID) -#define OPTPROC_DISABLEDOPT (1U << OPTPROC_DISABLEDOPT_ID) -#define OPTPROC_NO_REQ_OPT (1U << OPTPROC_NO_REQ_OPT_ID) -#define OPTPROC_NUM_OPT (1U << OPTPROC_NUM_OPT_ID) -#define OPTPROC_INITDONE (1U << OPTPROC_INITDONE_ID) -#define OPTPROC_NEGATIONS (1U << OPTPROC_NEGATIONS_ID) -#define OPTPROC_ENVIRON (1U << OPTPROC_ENVIRON_ID) -#define OPTPROC_NO_ARGS (1U << OPTPROC_NO_ARGS_ID) -#define OPTPROC_ARGS_REQ (1U << OPTPROC_ARGS_REQ_ID) -#define OPTPROC_REORDER (1U << OPTPROC_REORDER_ID) -#define OPTPROC_GNUUSAGE (1U << OPTPROC_GNUUSAGE_ID) -#define OPTPROC_TRANSLATE (1U << OPTPROC_TRANSLATE_ID) -#define OPTPROC_HAS_IMMED (1U << OPTPROC_HAS_IMMED_ID) -#define OPTPROC_PRESETTING (1U << OPTPROC_PRESETTING_ID) -#define OPTPROC_STATE_MASK 0x00087FFFU +#define OPTPROC_NONE 0U +#define OPTPROC_LONGOPT (1U << OPTPROC_LONGOPT_ID) +#define OPTPROC_SHORTOPT (1U << OPTPROC_SHORTOPT_ID) +#define OPTPROC_ERRSTOP (1U << OPTPROC_ERRSTOP_ID) +#define OPTPROC_DISABLEDOPT (1U << OPTPROC_DISABLEDOPT_ID) +#define OPTPROC_NO_REQ_OPT (1U << OPTPROC_NO_REQ_OPT_ID) +#define OPTPROC_NUM_OPT (1U << OPTPROC_NUM_OPT_ID) +#define OPTPROC_INITDONE (1U << OPTPROC_INITDONE_ID) +#define OPTPROC_NEGATIONS (1U << OPTPROC_NEGATIONS_ID) +#define OPTPROC_ENVIRON (1U << OPTPROC_ENVIRON_ID) +#define OPTPROC_NO_ARGS (1U << OPTPROC_NO_ARGS_ID) +#define OPTPROC_ARGS_REQ (1U << OPTPROC_ARGS_REQ_ID) +#define OPTPROC_REORDER (1U << OPTPROC_REORDER_ID) +#define OPTPROC_GNUUSAGE (1U << OPTPROC_GNUUSAGE_ID) +#define OPTPROC_TRANSLATE (1U << OPTPROC_TRANSLATE_ID) +#define OPTPROC_NXLAT_OPT_CFG (1U << OPTPROC_NXLAT_OPT_CFG_ID) +#define OPTPROC_NXLAT_OPT (1U << OPTPROC_NXLAT_OPT_ID) +#define OPTPROC_PRESETTING (1U << OPTPROC_PRESETTING_ID) +#define OPTPROC_STATE_MASK 0x000B3FFFU + +#define OPTPROC_NO_XLAT_MASK ( \ + OPTPROC_NXLAT_OPT | OPTPROC_NXLAT_OPT_CFG \ + /* 0x00030000U */ ) #define STMTS(s) do { s; } while (0) @@ -265,19 +300,24 @@ typedef struct options tOptions; typedef struct optDesc tOptDesc; typedef struct optNames tOptNames; +#define OPTPROC_EMIT_USAGE ((tOptions *)0x01UL) +#define OPTPROC_EMIT_SHELL ((tOptions *)0x02UL) +#define OPTPROC_RETURN_VALNAME ((tOptions *)0x03UL) +#define OPTPROC_EMIT_LIMIT ((tOptions *)0x0FUL) /* * The option procedures do the special processing for each * option flag that needs it. */ -typedef void (tOptProc)( tOptions* pOpts, tOptDesc* pOptDesc ); +typedef void (tOptProc)(tOptions* pOpts, tOptDesc* pOptDesc); typedef tOptProc* tpOptProc; /* * The usage procedure will never return. It calls "exit(2)" * with the "exitCode" argument passed to it. */ -typedef void (tUsageProc)( tOptions* pOpts, int exitCode ); +// coverity[+kill] +typedef void (tUsageProc)(tOptions* pOpts, int exitCode); typedef tUsageProc* tpUsageProc; /* @@ -311,6 +351,8 @@ long argInt; unsigned long argUint; unsigned int argBool; + FILE* argFp; + int argFd; } optArgBucket_t; /* @@ -334,15 +376,15 @@ # define pzLastArg optArg.argString void* optCookie; /* PUBLIC */ - const int * pOptMust; - const int * pOptCant; - tpOptProc pOptProc; - char const* pzText; - - char const* pz_NAME; - char const* pz_Name; - char const* pz_DisableName; - char const* pz_DisablePfx; + int const * const pOptMust; + int const * const pOptCant; + tpOptProc const pOptProc; + char const* const pzText; + + char const* const pz_NAME; + char const* const pz_Name; + char const* const pz_DisableName; + char const* const pz_DisablePfx; }; /* @@ -370,32 +412,46 @@ unsigned int curOptIdx; char* pzCurOpt; - char const* pzProgPath; - char const* pzProgName; - char const* const pzPROGNAME; - char const* const pzRcName; - char const* const pzCopyright; - char const* const pzCopyNotice; - char const* const pzFullVersion; + char const* pzProgPath; /* PUBLIC */ + char const* pzProgName; /* PUBLIC */ + char const* const pzPROGNAME; /* PUBLIC */ + char const* const pzRcName; /* PUBLIC */ + char const* const pzCopyright; /* PUBLIC */ + char const* const pzCopyNotice; /* PUBLIC */ + char const* const pzFullVersion; /* PUBLIC */ char const* const* const papzHomeList; char const* const pzUsageTitle; char const* const pzExplain; char const* const pzDetail; - tOptDesc* const pOptDesc; - char const* const pzBugAddr; + tOptDesc* const pOptDesc; /* PUBLIC */ + char const* const pzBugAddr; /* PUBLIC */ void* pExtensions; void* pSavedState; + // coverity[+kill] tpUsageProc pUsageProc; tOptionXlateProc* pTransProc; tOptSpecIndex specOptIdx; int const optCt; int const presetOptCt; + char const * pzFullUsage; + char const * pzShortUsage; + /* PUBLIC: */ + optArgBucket_t const * const originalOptArgArray; + void * const * const originalOptArgCookie; }; /* + * Versions where in various fields first appear: + * ($AO_CURRENT * 4096 + $AO_REVISION, but $AO_REVISION must be zero) + */ +#define originalOptArgArray_STRUCT_VERSION 131072 /* AO_CURRENT = 32 */ +#define HAS_originalOptArgArray(_opt) \ + ((_opt)->structVersion >= originalOptArgArray_STRUCT_VERSION) + +/* * "token list" structure returned by "string_tokenize()" */ typedef struct { @@ -447,7 +503,7 @@ * The following routines may be coded into AutoOpts client code: */ -/* From: tokenize.c line 115 +/* From: tokenize.c line 117 * * ao_string_tokenize - tokenize an input string * @@ -488,10 +544,10 @@ * Double quote strings are formed according to the rules of string * constants in ANSI-C programs. */ -extern token_list_t* ao_string_tokenize( char const* ); +extern token_list_t* ao_string_tokenize(char const*); -/* From: configfile.c line 113 +/* From: configfile.c line 85 * * configFileLoad - parse a configuration file * @@ -508,10 +564,10 @@ * @code{optionGetValue()}, @code{optionNextValue()} and * @code{optionUnloadNested()}. */ -extern const tOptionValue* configFileLoad( char const* ); +extern const tOptionValue* configFileLoad(char const*); -/* From: configfile.c line 883 +/* From: configfile.c line 897 * * optionFileLoad - Load the locatable config files, in order * @@ -538,10 +594,10 @@ * * Configuration files not found or not decipherable are simply ignored. */ -extern int optionFileLoad( tOptions*, char const* ); +extern int optionFileLoad(tOptions*, char const*); -/* From: configfile.c line 245 +/* From: configfile.c line 217 * * optionFindNextValue - find a hierarcicaly valued option instance * @@ -557,10 +613,10 @@ * configurable. It will search through the list and return the next entry * that matches the criteria. */ -extern const tOptionValue* optionFindNextValue( const tOptDesc*, const tOptionValue*, char const*, char const* ); +extern const tOptionValue* optionFindNextValue(const tOptDesc*, const tOptionValue*, char const*, char const*); -/* From: configfile.c line 171 +/* From: configfile.c line 143 * * optionFindValue - find a hierarcicaly valued option instance * @@ -574,10 +630,10 @@ * This routine will find an entry in a nested value option or configurable. * It will search through the list and return a matching entry. */ -extern const tOptionValue* optionFindValue( const tOptDesc*, char const*, char const* ); +extern const tOptionValue* optionFindValue(const tOptDesc*, char const*, char const*); -/* From: restore.c line 188 +/* From: restore.c line 165 * * optionFree - free allocated option processing memory * @@ -587,10 +643,10 @@ * AutoOpts sometimes allocates memory and puts pointers to it in the * option state structures. This routine deallocates all such memory. */ -extern void optionFree( tOptions* ); +extern void optionFree(tOptions*); -/* From: configfile.c line 314 +/* From: configfile.c line 286 * * optionGetValue - get a specific value from a hierarcical list * @@ -605,10 +661,10 @@ * the first entry with a name that exactly matches the argument will be * returned. */ -extern const tOptionValue* optionGetValue( const tOptionValue*, char const* ); +extern const tOptionValue* optionGetValue(const tOptionValue*, char const*); -/* From: load.c line 521 +/* From: load.c line 498 * * optionLoadLine - process a string for an option name and value * @@ -629,10 +685,10 @@ * formation used in AutoGen definition files (@pxref{basic expression}), * except that you may not use backquotes. */ -extern void optionLoadLine( tOptions*, char const* ); +extern void optionLoadLine(tOptions*, char const*); -/* From: configfile.c line 373 +/* From: configfile.c line 345 * * optionNextValue - get the next value from a hierarchical list * @@ -648,10 +704,10 @@ * The "@var{pOldValue}" must have been gotten from a prior call to this * routine or to "@code{opitonGetValue()}". */ -extern const tOptionValue* optionNextValue( const tOptionValue*, const tOptionValue* ); +extern const tOptionValue* optionNextValue(const tOptionValue*, const tOptionValue*); -/* From: usage.c line 128 +/* From: usage.c line 107 * * optionOnlyUsage - Print usage text for just the options * @@ -663,10 +719,10 @@ * This function may be used when the emitted usage must incorporate * information not available to AutoOpts. */ -extern void optionOnlyUsage( tOptions*, int ); +extern void optionOnlyUsage(tOptions*, int); -/* From: autoopts.c line 1012 +/* From: autoopts.c line 1058 * * optionProcess - this is the main option processing routine * @@ -693,10 +749,10 @@ * is treated as an operand. Encountering an operand stops option * processing. */ -extern int optionProcess( tOptions*, int, char** ); +extern int optionProcess(tOptions*, int, char**); -/* From: restore.c line 145 +/* From: restore.c line 122 * * optionRestore - restore option state from memory copy * @@ -710,10 +766,10 @@ * to optionProcess(3AO), then you may change the contents of the * argc/argv parameters to optionProcess. */ -extern void optionRestore( tOptions* ); +extern void optionRestore(tOptions*); -/* From: save.c line 334 +/* From: save.c line 671 * * optionSaveFile - saves the option state to a file * @@ -726,11 +782,19 @@ * @code{homerc} attribute. If no @code{rcfile} attribute was specified, it * will default to @code{.@i{programname}rc}. If you wish to specify another * file, you should invoke the @code{SET_OPT_SAVE_OPTS( @i{filename} )} macro. + * + * The recommend usage is as follows: + * @example + * optionProcess(&progOptions, argc, argv); + * if (i_want_a_non_standard_place_for_this) + * SET_OPT_SAVE_OPTS("myfilename"); + * optionSaveFile(&progOptions); + * @end example */ -extern void optionSaveFile( tOptions* ); +extern void optionSaveFile(tOptions*); -/* From: restore.c line 93 +/* From: restore.c line 70 * * optionSaveState - saves the option state to memory * @@ -749,10 +813,10 @@ * restoring of stacked string arguments and hierarchical values is * disabled. The values are not saved. */ -extern void optionSaveState( tOptions* ); +extern void optionSaveState(tOptions*); -/* From: nested.c line 559 +/* From: nested.c line 569 * * optionUnloadNested - Deallocate the memory for a nested value * @@ -763,10 +827,10 @@ * have been gotten from a call to @code{configFileLoad()} (See * @pxref{libopts-configFileLoad}). */ -extern void optionUnloadNested( tOptionValue const * ); +extern void optionUnloadNested(tOptionValue const *); -/* From: version.c line 58 +/* From: version.c line 37 * * optionVersion - return the compiled AutoOpts version number * @@ -775,10 +839,10 @@ * Returns the full version string compiled into the library. * The returned string cannot be modified. */ -extern char const* optionVersion( void ); +extern char const* optionVersion(void); -/* From: ../compat/pathfind.c line 34 +/* From: ../compat/pathfind.c line 32 * * pathfind - fild a file in a list of directories * @@ -818,11 +882,11 @@ * @end example */ #ifndef HAVE_PATHFIND -extern char* pathfind( char const*, char const*, char const* ); +extern char* pathfind(char const*, char const*, char const*); #endif /* HAVE_PATHFIND */ -/* From: streqvcmp.c line 233 +/* From: streqvcmp.c line 208 * * strequate - map a list of characters to the same value * @@ -834,10 +898,10 @@ * This function name is mapped to option_strequate so as to not conflict * with the POSIX name space. */ -extern void strequate( char const* ); +extern void strequate(char const*); -/* From: streqvcmp.c line 143 +/* From: streqvcmp.c line 118 * * streqvcmp - compare two strings with an equivalence mapping * @@ -853,10 +917,10 @@ * This function name is mapped to option_streqvcmp so as to not conflict * with the POSIX name space. */ -extern int streqvcmp( char const*, char const* ); +extern int streqvcmp(char const*, char const*); -/* From: streqvcmp.c line 180 +/* From: streqvcmp.c line 155 * * streqvmap - Set the character mappings for the streqv functions * @@ -881,10 +945,10 @@ * This function name is mapped to option_streqvmap so as to not conflict * with the POSIX name space. */ -extern void streqvmap( char, char, int ); +extern void streqvmap(char, char, int); -/* From: streqvcmp.c line 102 +/* From: streqvcmp.c line 77 * * strneqvcmp - compare two strings with an equivalence mapping * @@ -902,10 +966,10 @@ * This function name is mapped to option_strneqvcmp so as to not conflict * with the POSIX name space. */ -extern int strneqvcmp( char const*, char const*, int ); +extern int strneqvcmp(char const*, char const*, int); -/* From: streqvcmp.c line 259 +/* From: streqvcmp.c line 234 * * strtransform - convert a string into its mapped-to value * @@ -917,55 +981,65 @@ * character is put into the output. * This function name is mapped to option_strtransform so as to not conflict * with the POSIX name space. + * + * The source and destination may be the same. */ -extern void strtransform( char*, char const* ); +extern void strtransform(char*, char const*); /* AutoOpts PRIVATE FUNCTIONS: */ tOptProc optionStackArg, optionUnstackArg, optionBooleanVal, optionNumericVal; -extern char* ao_string_cook( char*, int* ); +extern char* ao_string_cook(char*, int*); + +extern unsigned int ao_string_cook_escape_char(char const*, char*, unsigned int); + +extern void export_options_to_guile(tOptions*); + +extern void genshelloptUsage(tOptions*, int); + +extern void optionBooleanVal(tOptions*, tOptDesc*); -extern unsigned int ao_string_cook_escape_char( char const*, char*, unsigned int ); +extern uintptr_t optionEnumerationVal(tOptions*, tOptDesc*, char const * const *, unsigned int); -extern void export_options_to_guile( tOptions* ); +extern void optionFileCheck(tOptions*, tOptDesc*, teOptFileType, tuFileMode); -extern void genshelloptUsage( tOptions*, int ); +extern char const* optionKeywordName(tOptDesc*, unsigned int); -extern void optionBooleanVal( tOptions*, tOptDesc* ); +extern void optionLoadOpt(tOptions*, tOptDesc*); -extern uintptr_t optionEnumerationVal( tOptions*, tOptDesc*, char const * const *, unsigned int ); +extern ag_bool optionMakePath(char*, int, char const*, char const*); -extern char const* optionKeywordName( tOptDesc*, unsigned int ); +extern void optionNestedVal(tOptions*, tOptDesc*); -extern void optionLoadOpt( tOptions*, tOptDesc* ); +extern void optionNumericVal(tOptions*, tOptDesc*); -extern ag_bool optionMakePath( char*, int, char const*, char const* ); +extern void optionPagedUsage(tOptions*, tOptDesc*); -extern void optionNestedVal( tOptions*, tOptDesc* ); +extern void optionParseShell(tOptions*); -extern void optionNumericVal( tOptions*, tOptDesc* ); +extern void optionPrintVersion(tOptions*, tOptDesc*); -extern void optionPagedUsage( tOptions*, tOptDesc* ); +extern void optionPutShell(tOptions*); -extern void optionParseShell( tOptions* ); +extern void optionResetOpt(tOptions*, tOptDesc*); -extern void optionPrintVersion( tOptions*, tOptDesc* ); +extern void optionSetMembers(tOptions*, tOptDesc*, char const * const *, unsigned int); -extern void optionPutShell( tOptions* ); +extern void optionShowRange(tOptions*, tOptDesc*, void *, int); -extern void optionSetMembers( tOptions*, tOptDesc*, char const * const *, unsigned int ); +extern void optionStackArg(tOptions*, tOptDesc*); -extern void optionStackArg( tOptions*, tOptDesc* ); +extern void optionTimeVal(tOptions*, tOptDesc*); -extern void optionUnstackArg( tOptions*, tOptDesc* ); +extern void optionUnstackArg(tOptions*, tOptDesc*); -extern void optionUsage( tOptions*, int ); +extern void optionUsage(tOptions*, int); -extern void optionVersionStderr( tOptions*, tOptDesc* ); +extern void optionVersionStderr(tOptions*, tOptDesc*); -extern void* text_mmap( char const*, int, int, tmap_info_t* ); +extern void* text_mmap(char const*, int, int, tmap_info_t*); -extern int text_munmap( tmap_info_t* ); +extern int text_munmap(tmap_info_t*); CPLUSPLUS_CLOSER #endif /* AUTOOPTS_OPTIONS_H_GUARD */ diff -urN src/contrib/ntp/sntp/libopts/autoopts/usage-txt.h src.ntp/contrib/ntp/sntp/libopts/autoopts/usage-txt.h --- src/contrib/ntp/sntp/libopts/autoopts/usage-txt.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/autoopts/usage-txt.h 2009-12-09 08:36:46.000000000 +0100 @@ -2,35 +2,32 @@ * * DO NOT EDIT THIS FILE (usage-txt.h) * - * It has been AutoGen-ed Saturday May 5, 2007 at 12:02:33 PM PDT + * It has been AutoGen-ed November 8, 2009 at 08:41:07 AM by AutoGen 5.9.10pre13 * From the definitions usage-txt.def * and the template file usage-txt.tpl * * This file handles all the bookkeeping required for tracking all the little - * tiny strings used by the AutoOpts library. There are 113 + * tiny strings used by the AutoOpts library. There are 134 * of them. This is not versioned because it is entirely internal to the * library and accessed by client code only in a very well-controlled way: * they may substitute translated strings using a procedure that steps through * all the string pointers. * - * AutoOpts is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. + * AutoOpts is free software: you can redistribute it and/or modify it + * under the terms of the GNU Lesser General Public License as published + * by the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. * - * AutoOpts is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. + * AutoOpts is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the GNU Lesser General Public License for more details. * - * You should have received a copy of the GNU Lesser General Public - * License along with AutoOpts. If not, write to: - * The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor - * Boston, MA 02110-1301, USA. + * You should have received a copy of the GNU Lesser General Public License + * along with this program. If not, see . */ #ifndef AUTOOPTS_USAGE_TXT_H_GUARD -#define AUTOOPTS_USAGE_TXT_H_GUARD +#define AUTOOPTS_USAGE_TXT_H_GUARD 1 #undef cch_t #define cch_t char const @@ -42,10 +39,12 @@ int field_ct; char* utpz_GnuBoolArg; char* utpz_GnuKeyArg; + char* utpz_GnuFileArg; char* utpz_GnuKeyLArg; + char* utpz_GnuTimeArg; char* utpz_GnuNumArg; char* utpz_GnuStrArg; - cch_t* apz_str[ 108 ]; + cch_t* apz_str[ 127 ]; } usage_text_t; /* @@ -62,115 +61,136 @@ #define zAO_Big (option_usage_text.apz_str[ 1]) #define zAO_Err (option_usage_text.apz_str[ 2]) #define zAO_Sml (option_usage_text.apz_str[ 3]) -#define zAll (option_usage_text.apz_str[ 4]) -#define zAlt (option_usage_text.apz_str[ 5]) -#define zAmbigKey (option_usage_text.apz_str[ 6]) -#define zAmbiguous (option_usage_text.apz_str[ 7]) -#define zArgsMust (option_usage_text.apz_str[ 8]) -#define zAtMost (option_usage_text.apz_str[ 9]) -#define zAuto (option_usage_text.apz_str[ 10]) -#define zBadPipe (option_usage_text.apz_str[ 11]) -#define zBadVerArg (option_usage_text.apz_str[ 12]) -#define zCantFmt (option_usage_text.apz_str[ 13]) -#define zCantSave (option_usage_text.apz_str[ 14]) -#define zDefaultOpt (option_usage_text.apz_str[ 15]) -#define zDis (option_usage_text.apz_str[ 16]) -#define zEnab (option_usage_text.apz_str[ 17]) -#define zEquiv (option_usage_text.apz_str[ 18]) -#define zErrOnly (option_usage_text.apz_str[ 19]) -#define zExamineFmt (option_usage_text.apz_str[ 20]) -#define zFiveSpaces (option_usage_text.apz_str[ 21]) -#define zFlagOkay (option_usage_text.apz_str[ 22]) -#define zFmtFmt (option_usage_text.apz_str[ 23]) -#define zForkFail (option_usage_text.apz_str[ 24]) -#define zFSErrOptLoad (option_usage_text.apz_str[ 25]) -#define zFSErrReadFile (option_usage_text.apz_str[ 26]) -#define zGenshell (option_usage_text.apz_str[ 27]) +#define zAO_Ver (option_usage_text.apz_str[ 4]) +#define zAO_Woops (option_usage_text.apz_str[ 5]) +#define zAliasRange (option_usage_text.apz_str[ 6]) +#define zAll (option_usage_text.apz_str[ 7]) +#define zAlt (option_usage_text.apz_str[ 8]) +#define zAmbigKey (option_usage_text.apz_str[ 9]) +#define zAmbigOptStr (option_usage_text.apz_str[ 10]) +#define zArgsMust (option_usage_text.apz_str[ 11]) +#define zAtMost (option_usage_text.apz_str[ 12]) +#define zAuto (option_usage_text.apz_str[ 13]) +#define zBadPipe (option_usage_text.apz_str[ 14]) +#define zBadVerArg (option_usage_text.apz_str[ 15]) +#define zCantFmt (option_usage_text.apz_str[ 16]) +#define zCantSave (option_usage_text.apz_str[ 17]) +#define zDefaultOpt (option_usage_text.apz_str[ 18]) +#define zDis (option_usage_text.apz_str[ 19]) +#define zDisabledErr (option_usage_text.apz_str[ 20]) +#define zDisabledOpt (option_usage_text.apz_str[ 21]) +#define zDisabledWhy (option_usage_text.apz_str[ 22]) +#define zEnab (option_usage_text.apz_str[ 23]) +#define zEquiv (option_usage_text.apz_str[ 24]) +#define zErrOnly (option_usage_text.apz_str[ 25]) +#define zExamineFmt (option_usage_text.apz_str[ 26]) +#define zFiveSpaces (option_usage_text.apz_str[ 27]) +#define zFlagOkay (option_usage_text.apz_str[ 28]) +#define zFmtFmt (option_usage_text.apz_str[ 29]) +#define zForkFail (option_usage_text.apz_str[ 30]) +#define zFSErrOptLoad (option_usage_text.apz_str[ 31]) +#define zFSErrReadFile (option_usage_text.apz_str[ 32]) +#define zFSOptError (option_usage_text.apz_str[ 33]) +#define zFSOptErrMayExist (option_usage_text.apz_str[ 34]) +#define zFSOptErrMustExist (option_usage_text.apz_str[ 35]) +#define zFSOptErrNoExist (option_usage_text.apz_str[ 36]) +#define zFSOptErrOpen (option_usage_text.apz_str[ 37]) +#define zFSOptErrFopen (option_usage_text.apz_str[ 38]) +#define zFileCannotExist (option_usage_text.apz_str[ 39]) +#define zFileMustExist (option_usage_text.apz_str[ 40]) +#define zGenshell (option_usage_text.apz_str[ 41]) #define zGnuBoolArg (option_usage_text.utpz_GnuBoolArg) -#define zGnuBreak (option_usage_text.apz_str[ 28]) +#define zGnuBreak (option_usage_text.apz_str[ 42]) #define zGnuKeyArg (option_usage_text.utpz_GnuKeyArg) +#define zGnuFileArg (option_usage_text.utpz_GnuFileArg) #define zGnuKeyLArg (option_usage_text.utpz_GnuKeyLArg) -#define zGnuNestArg (option_usage_text.apz_str[ 29]) +#define zGnuTimeArg (option_usage_text.utpz_GnuTimeArg) +#define zGnuNestArg (option_usage_text.apz_str[ 43]) #define zGnuNumArg (option_usage_text.utpz_GnuNumArg) -#define zGnuOptArg (option_usage_text.apz_str[ 30]) -#define zGnuOptFmt (option_usage_text.apz_str[ 31]) +#define zGnuOptArg (option_usage_text.apz_str[ 44]) +#define zGnuOptFmt (option_usage_text.apz_str[ 45]) #define zGnuStrArg (option_usage_text.utpz_GnuStrArg) -#define zIllOptChr (option_usage_text.apz_str[ 32]) -#define zIllOptStr (option_usage_text.apz_str[ 33]) -#define zIllegal (option_usage_text.apz_str[ 34]) -#define zInvalOptDesc (option_usage_text.apz_str[ 35]) -#define zKeyWords (option_usage_text.apz_str[ 36]) -#define zLoadCooked (option_usage_text.apz_str[ 37]) -#define zLoadKeep (option_usage_text.apz_str[ 38]) -#define zLoadType (option_usage_text.apz_str[ 39]) -#define zLoadUncooked (option_usage_text.apz_str[ 40]) -#define zLtypeInteger (option_usage_text.apz_str[ 41]) -#define zLtypeNest (option_usage_text.apz_str[ 42]) -#define zLtypeString (option_usage_text.apz_str[ 43]) -#define zLtypeBool (option_usage_text.apz_str[ 44]) -#define zLtypeKeyword (option_usage_text.apz_str[ 45]) -#define zLtypeSetMembership (option_usage_text.apz_str[ 46]) -#define zMembers (option_usage_text.apz_str[ 47]) -#define zMisArg (option_usage_text.apz_str[ 48]) -#define zMultiEquiv (option_usage_text.apz_str[ 49]) -#define zMust (option_usage_text.apz_str[ 50]) -#define zNeedOne (option_usage_text.apz_str[ 51]) -#define zNoArg (option_usage_text.apz_str[ 52]) -#define zNoArgs (option_usage_text.apz_str[ 53]) -#define zNoCreat (option_usage_text.apz_str[ 54]) -#define zNoFlags (option_usage_text.apz_str[ 55]) -#define zNoKey (option_usage_text.apz_str[ 56]) -#define zNoLim (option_usage_text.apz_str[ 57]) -#define zNoPreset (option_usage_text.apz_str[ 58]) -#define zNoRq_NoShrtTtl (option_usage_text.apz_str[ 59]) -#define zNoRq_ShrtTtl (option_usage_text.apz_str[ 60]) -#define zNoStat (option_usage_text.apz_str[ 61]) -#define zNoState (option_usage_text.apz_str[ 62]) -#define zNone (option_usage_text.apz_str[ 63]) -#define zNotDef (option_usage_text.apz_str[ 64]) -#define zNotEnough (option_usage_text.apz_str[ 65]) -#define zNotFile (option_usage_text.apz_str[ 66]) -#define zNotNumber (option_usage_text.apz_str[ 67]) -#define zNrmOptFmt (option_usage_text.apz_str[ 68]) -#define zNumberOpt (option_usage_text.apz_str[ 69]) -#define zOneSpace (option_usage_text.apz_str[ 70]) -#define zOnlyOne (option_usage_text.apz_str[ 71]) -#define zOptsOnly (option_usage_text.apz_str[ 72]) -#define zPathFmt (option_usage_text.apz_str[ 73]) -#define zPlsSendBugs (option_usage_text.apz_str[ 74]) -#define zPreset (option_usage_text.apz_str[ 75]) -#define zPresetFile (option_usage_text.apz_str[ 76]) -#define zPresetIntro (option_usage_text.apz_str[ 77]) -#define zProg (option_usage_text.apz_str[ 78]) -#define zProhib (option_usage_text.apz_str[ 79]) -#define zReorder (option_usage_text.apz_str[ 80]) -#define zReqFmt (option_usage_text.apz_str[ 81]) -#define zReqOptFmt (option_usage_text.apz_str[ 82]) -#define zReqThese (option_usage_text.apz_str[ 83]) -#define zReq_NoShrtTtl (option_usage_text.apz_str[ 84]) -#define zReq_ShrtTtl (option_usage_text.apz_str[ 85]) -#define zSepChars (option_usage_text.apz_str[ 86]) -#define zSetMembers (option_usage_text.apz_str[ 87]) -#define zSetMemberSettings (option_usage_text.apz_str[ 88]) -#define zShrtGnuOptFmt (option_usage_text.apz_str[ 89]) -#define zSixSpaces (option_usage_text.apz_str[ 90]) -#define zStdBoolArg (option_usage_text.apz_str[ 91]) -#define zStdBreak (option_usage_text.apz_str[ 92]) -#define zStdKeyArg (option_usage_text.apz_str[ 93]) -#define zStdKeyLArg (option_usage_text.apz_str[ 94]) -#define zStdNestArg (option_usage_text.apz_str[ 95]) -#define zStdNoArg (option_usage_text.apz_str[ 96]) -#define zStdNumArg (option_usage_text.apz_str[ 97]) -#define zStdOptArg (option_usage_text.apz_str[ 98]) -#define zStdReqArg (option_usage_text.apz_str[ 99]) -#define zStdStrArg (option_usage_text.apz_str[100]) -#define zTabHyp (option_usage_text.apz_str[101]) -#define zTabHypAnd (option_usage_text.apz_str[102]) -#define zTabout (option_usage_text.apz_str[103]) -#define zThreeSpaces (option_usage_text.apz_str[104]) -#define zTwoSpaces (option_usage_text.apz_str[105]) -#define zUpTo (option_usage_text.apz_str[106]) -#define zValidKeys (option_usage_text.apz_str[107]) +#define zIllOptChr (option_usage_text.apz_str[ 46]) +#define zIllOptStr (option_usage_text.apz_str[ 47]) +#define zIllegal (option_usage_text.apz_str[ 48]) +#define zIntRange (option_usage_text.apz_str[ 49]) +#define zInvalOptDesc (option_usage_text.apz_str[ 50]) +#define zLowerBits (option_usage_text.apz_str[ 51]) +#define zMembers (option_usage_text.apz_str[ 52]) +#define zMisArg (option_usage_text.apz_str[ 53]) +#define zMultiEquiv (option_usage_text.apz_str[ 54]) +#define zMust (option_usage_text.apz_str[ 55]) +#define zNeedOne (option_usage_text.apz_str[ 56]) +#define zNoArg (option_usage_text.apz_str[ 57]) +#define zNoArgs (option_usage_text.apz_str[ 58]) +#define zNoCreat (option_usage_text.apz_str[ 59]) +#define zNoFlags (option_usage_text.apz_str[ 60]) +#define zNoKey (option_usage_text.apz_str[ 61]) +#define zNoLim (option_usage_text.apz_str[ 62]) +#define zNoPreset (option_usage_text.apz_str[ 63]) +#define zNoResetArg (option_usage_text.apz_str[ 64]) +#define zNoRq_NoShrtTtl (option_usage_text.apz_str[ 65]) +#define zNoRq_ShrtTtl (option_usage_text.apz_str[ 66]) +#define zNoStat (option_usage_text.apz_str[ 67]) +#define zNoState (option_usage_text.apz_str[ 68]) +#define zNone (option_usage_text.apz_str[ 69]) +#define zNotDef (option_usage_text.apz_str[ 70]) +#define zNotCmdOpt (option_usage_text.apz_str[ 71]) +#define zNotEnough (option_usage_text.apz_str[ 72]) +#define zNotFile (option_usage_text.apz_str[ 73]) +#define zNotNumber (option_usage_text.apz_str[ 74]) +#define zNrmOptFmt (option_usage_text.apz_str[ 75]) +#define zNumberOpt (option_usage_text.apz_str[ 76]) +#define zOneSpace (option_usage_text.apz_str[ 77]) +#define zOnlyOne (option_usage_text.apz_str[ 78]) +#define zOptsOnly (option_usage_text.apz_str[ 79]) +#define zPathFmt (option_usage_text.apz_str[ 80]) +#define zPlsSendBugs (option_usage_text.apz_str[ 81]) +#define zPreset (option_usage_text.apz_str[ 82]) +#define zPresetFile (option_usage_text.apz_str[ 83]) +#define zPresetIntro (option_usage_text.apz_str[ 84]) +#define zProg (option_usage_text.apz_str[ 85]) +#define zProhib (option_usage_text.apz_str[ 86]) +#define zReorder (option_usage_text.apz_str[ 87]) +#define zRange (option_usage_text.apz_str[ 88]) +#define zRangeAbove (option_usage_text.apz_str[ 89]) +#define zRangeLie (option_usage_text.apz_str[ 90]) +#define zRangeBadLie (option_usage_text.apz_str[ 91]) +#define zRangeOnly (option_usage_text.apz_str[ 92]) +#define zRangeOr (option_usage_text.apz_str[ 93]) +#define zRangeErr (option_usage_text.apz_str[ 94]) +#define zRangeExact (option_usage_text.apz_str[ 95]) +#define zRangeScaled (option_usage_text.apz_str[ 96]) +#define zRangeUpto (option_usage_text.apz_str[ 97]) +#define zResetNotConfig (option_usage_text.apz_str[ 98]) +#define zReqFmt (option_usage_text.apz_str[ 99]) +#define zReqOptFmt (option_usage_text.apz_str[100]) +#define zReqThese (option_usage_text.apz_str[101]) +#define zReq_NoShrtTtl (option_usage_text.apz_str[102]) +#define zReq_ShrtTtl (option_usage_text.apz_str[103]) +#define zSepChars (option_usage_text.apz_str[104]) +#define zSetMemberSettings (option_usage_text.apz_str[105]) +#define zShrtGnuOptFmt (option_usage_text.apz_str[106]) +#define zSixSpaces (option_usage_text.apz_str[107]) +#define zStdBoolArg (option_usage_text.apz_str[108]) +#define zStdBreak (option_usage_text.apz_str[109]) +#define zStdFileArg (option_usage_text.apz_str[110]) +#define zStdKeyArg (option_usage_text.apz_str[111]) +#define zStdKeyLArg (option_usage_text.apz_str[112]) +#define zStdTimeArg (option_usage_text.apz_str[113]) +#define zStdNestArg (option_usage_text.apz_str[114]) +#define zStdNoArg (option_usage_text.apz_str[115]) +#define zStdNumArg (option_usage_text.apz_str[116]) +#define zStdOptArg (option_usage_text.apz_str[117]) +#define zStdReqArg (option_usage_text.apz_str[118]) +#define zStdStrArg (option_usage_text.apz_str[119]) +#define zTabHyp (option_usage_text.apz_str[120]) +#define zTabHypAnd (option_usage_text.apz_str[121]) +#define zTabout (option_usage_text.apz_str[122]) +#define zThreeSpaces (option_usage_text.apz_str[123]) +#define zTwoSpaces (option_usage_text.apz_str[124]) +#define zUpTo (option_usage_text.apz_str[125]) +#define zValidKeys (option_usage_text.apz_str[126]) /* * First, set up the strings. Some of these are writable. These are all in @@ -180,19 +200,25 @@ static char eng_zGnuBoolArg[] = "=T/F"; static char eng_zGnuKeyArg[] = "=KWd"; + static char eng_zGnuFileArg[] = "=file"; static char eng_zGnuKeyLArg[] = "=Mbr"; + static char eng_zGnuTimeArg[] = "=Tim"; static char eng_zGnuNumArg[] = "=num"; static char eng_zGnuStrArg[] = "=str"; -static char const usage_txt[3208] = +static char const usage_txt[4159] = "AutoOpts function called without option descriptor\n\0" "\tThis exceeds the compiled library version: \0" "Automated Options Processing Error!\n" "\t%s called AutoOpts function with structure version %d:%d:%d.\n\0" "\tThis is less than the minimum library version: \0" + "Automated Options version %s\n" + "\tcopyright (c) 1999-2009 by Bruce Korb - all rights reserved\n\0" + "AutoOpts lib error: defaulted to option with optional arg\n\0" + "(AutoOpts bug): Aliasing option is out of range.\0" "all\0" "\t\t\t\t- an alternate for %s\n\0" "%s error: the keyword `%s' is ambiguous for %s\n\0" - "ambiguous\0" + "%s: ambiguous option -- %s\n\0" "%s: Command line arguments required\n\0" "%d %s%s options allowed\n\0" "version and help options:\0" @@ -205,6 +231,9 @@ "%s(optionSaveState): error: cannot allocate %d bytes\n\0" "\t\t\t\t- default option for unnamed options\n\0" "\t\t\t\t- disabled as --%s\n\0" + "%s: The ``%s'' option has been disabled\0" + " --- %-14s %s\n\0" + "This option has been disabled\0" "\t\t\t\t- enabled by default\n\0" "-equivalence\0" "ERROR: only \0" @@ -216,6 +245,14 @@ "fs error %d (%s) on fork - cannot obtain %s usage\n\0" "File error %d (%s) opening %s for loading options\n\0" "fs error %d (%s) reading file %s\n\0" + "fs error %d (%s) on %s %s for option %s\n\0" + "stat-ing for directory\0" + "stat-ing for regular file\0" + "stat-ing for non-existant file\0" + "open-ing file\0" + "fopen-ing file\0" + "\t\t\t\t- file must not pre-exist\n\0" + "\t\t\t\t- file must pre-exist\n\0" "\n" "= = = = = = = =\n\n" "This incarnation of genshell will produce\n" @@ -226,20 +263,11 @@ "[=arg]\0" "--%2$s%1$s\0" "%s: illegal option -- %c\n\0" - "%s: %s option -- %s\n\0" + "%s: illegal option -- %s\n\0" "illegal\0" + " or an integer from %d through %d\n\0" "AutoOpts ERROR: invalid option descriptor for %s\n\0" - "words=\0" - "cooked\0" - "keep\0" - "type=\0" - "uncooked\0" - "integer\0" - "nested\0" - "string\0" - "bool\0" - "keyword\0" - "set\0" + " or an integer mask with any of the lower %d bits set\n\0" "\t\t\t\t- is a set membership option\n\0" "%s: option `%s' requires an argument\n\0" "Equivalenced option '%s' was equivalenced to both\n" @@ -253,12 +281,14 @@ "%s error: `%s' does not match any %s keywords\n\0" "\t\t\t\t- may appear multiple times\n\0" "\t\t\t\t- may not be preset\n\0" + "The 'reset-option' option requires an argument\n\0" " Arg Option-Name Description\n\0" " Flg Arg Option-Name Description\n\0" "error %d (%s) stat-ing %s\n\0" "%s(optionRestore): error: no saved option state\n\0" "none\0" "'%s' not defined\n\0" + "'%s' is not a command line option\n\0" "ERROR: The %s option must appear %d times\n\0" "error: cannot load options from non-regular file %s\n\0" "%s error: `%s' is not a recognizable number\n\0" @@ -278,13 +308,23 @@ "program\0" "prohibits these options:\n\0" "Operands and options may be intermixed. They will be reordered.\n\0" + "%s%ld to %ld\0" + "%sgreater than or equal to %ld\0" + "%sIt must lie in one of the ranges:\n\0" + "%sThis option must lie in one of the ranges:\n\0" + "%sit must be: \0" + ", or\n\0" + "%s error: %s option value ``%s'' is out of range.\n\0" + "%s%ld exactly\0" + "%sis scalable with a suffix: k/K/m/M/g/G/t/T\n\0" + "%sless than or equal to %ld\0" + "The --reset-option has not been configured.\n\0" "ERROR: %s option requires the %s option\n\0" " %3s %-14s %s\0" "requires these options:\n\0" " Arg Option-Name Req? Description\n\0" " Flg Arg Option-Name Req? Description\n\0" "-_^\0" - "members=\0" "or you may use a numeric representation. Preceding these with a '!' will\n" "clear the bits, specifying 'none' will clear all bits, and 'all' will set them\n" "all. Multiple entries may be passed as an option argument list.\n\0" @@ -294,8 +334,10 @@ "\n" "%s\n\n" "%s\0" + "Fil\0" "KWd\0" "Mbr\0" + "Tim\0" "Cpx\0" "no \0" "Num\0" @@ -317,37 +359,42 @@ * Aren't you glad you don't maintain this by hand? */ usage_text_t option_usage_text = { - 113, - eng_zGnuBoolArg, eng_zGnuKeyArg, eng_zGnuKeyLArg, eng_zGnuNumArg, - eng_zGnuStrArg, + 134, + eng_zGnuBoolArg, eng_zGnuKeyArg, eng_zGnuFileArg, eng_zGnuKeyLArg, + eng_zGnuTimeArg, eng_zGnuNumArg, eng_zGnuStrArg, { usage_txt + 0, usage_txt + 52, usage_txt + 98, usage_txt + 197, - usage_txt + 247, usage_txt + 251, usage_txt + 278, usage_txt + 327, - usage_txt + 337, usage_txt + 374, usage_txt + 399, usage_txt + 425, - usage_txt + 465, usage_txt + 602, usage_txt + 650, usage_txt + 704, - usage_txt + 746, usage_txt + 770, usage_txt + 796, usage_txt + 809, - usage_txt + 823, usage_txt + 870, usage_txt + 876, usage_txt + 979, - usage_txt + 991, usage_txt +1042, usage_txt +1093, usage_txt +1127, - usage_txt +1233, usage_txt +1239, usage_txt +1245, usage_txt +1252, - usage_txt +1263, usage_txt +1289, usage_txt +1310, usage_txt +1318, - usage_txt +1369, usage_txt +1376, usage_txt +1383, usage_txt +1388, - usage_txt +1394, usage_txt +1403, usage_txt +1411, usage_txt +1418, - usage_txt +1425, usage_txt +1430, usage_txt +1438, usage_txt +1442, - usage_txt +1476, usage_txt +1514, usage_txt +1579, usage_txt +1622, - usage_txt +1657, usage_txt +1698, usage_txt +1738, usage_txt +1765, - usage_txt +1832, usage_txt +1880, usage_txt +1913, usage_txt +1938, - usage_txt +1973, usage_txt +2011, usage_txt +2038, usage_txt +2087, - usage_txt +2092, usage_txt +2110, usage_txt +2154, usage_txt +2208, - usage_txt +2254, usage_txt +2262, usage_txt +2310, usage_txt +2312, - usage_txt +2337, usage_txt +2371, usage_txt +2390, usage_txt +2424, - usage_txt +2460, usage_txt +2498, usage_txt +2554, usage_txt +2562, - usage_txt +2588, usage_txt +2654, usage_txt +2696, usage_txt +2710, - usage_txt +2735, usage_txt +2775, usage_txt +2818, usage_txt +2822, - usage_txt +2831, usage_txt +3050, usage_txt +3053, usage_txt +3060, - usage_txt +3064, usage_txt +3072, usage_txt +3076, usage_txt +3080, - usage_txt +3084, usage_txt +3088, usage_txt +3092, usage_txt +3096, - usage_txt +3100, usage_txt +3104, usage_txt +3111, usage_txt +3123, - usage_txt +3131, usage_txt +3135, usage_txt +3138, usage_txt +3171 + usage_txt + 247, usage_txt + 338, usage_txt + 397, usage_txt + 447, + usage_txt + 451, usage_txt + 478, usage_txt + 527, usage_txt + 555, + usage_txt + 592, usage_txt + 617, usage_txt + 643, usage_txt + 683, + usage_txt + 820, usage_txt + 868, usage_txt + 922, usage_txt + 964, + usage_txt + 988, usage_txt +1028, usage_txt +1043, usage_txt +1073, + usage_txt +1099, usage_txt +1112, usage_txt +1126, usage_txt +1173, + usage_txt +1179, usage_txt +1282, usage_txt +1294, usage_txt +1345, + usage_txt +1396, usage_txt +1430, usage_txt +1471, usage_txt +1494, + usage_txt +1520, usage_txt +1551, usage_txt +1565, usage_txt +1580, + usage_txt +1611, usage_txt +1638, usage_txt +1744, usage_txt +1750, + usage_txt +1756, usage_txt +1763, usage_txt +1774, usage_txt +1800, + usage_txt +1826, usage_txt +1834, usage_txt +1870, usage_txt +1921, + usage_txt +1977, usage_txt +2011, usage_txt +2049, usage_txt +2114, + usage_txt +2157, usage_txt +2192, usage_txt +2233, usage_txt +2273, + usage_txt +2300, usage_txt +2367, usage_txt +2415, usage_txt +2448, + usage_txt +2473, usage_txt +2521, usage_txt +2556, usage_txt +2594, + usage_txt +2621, usage_txt +2670, usage_txt +2675, usage_txt +2693, + usage_txt +2728, usage_txt +2772, usage_txt +2826, usage_txt +2872, + usage_txt +2880, usage_txt +2928, usage_txt +2930, usage_txt +2955, + usage_txt +2989, usage_txt +3008, usage_txt +3042, usage_txt +3078, + usage_txt +3116, usage_txt +3172, usage_txt +3180, usage_txt +3206, + usage_txt +3272, usage_txt +3285, usage_txt +3316, usage_txt +3353, + usage_txt +3399, usage_txt +3415, usage_txt +3421, usage_txt +3473, + usage_txt +3487, usage_txt +3533, usage_txt +3561, usage_txt +3606, + usage_txt +3648, usage_txt +3662, usage_txt +3687, usage_txt +3727, + usage_txt +3770, usage_txt +3774, usage_txt +3993, usage_txt +3996, + usage_txt +4003, usage_txt +4007, usage_txt +4015, usage_txt +4019, + usage_txt +4023, usage_txt +4027, usage_txt +4031, usage_txt +4035, + usage_txt +4039, usage_txt +4043, usage_txt +4047, usage_txt +4051, + usage_txt +4055, usage_txt +4062, usage_txt +4074, usage_txt +4082, + usage_txt +4086, usage_txt +4089, usage_txt +4122 } }; diff -urN src/contrib/ntp/sntp/libopts/autoopts.c src.ntp/contrib/ntp/sntp/libopts/autoopts.c --- src/contrib/ntp/sntp/libopts/autoopts.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/autoopts.c 2009-12-09 08:36:46.000000000 +0100 @@ -1,66 +1,52 @@ /* - * $Id: autoopts.c,v 4.25 2007/04/15 19:01:18 bkorb Exp $ - * Time-stamp: "2007-04-15 11:10:40 bkorb" + * $Id: 56abb301f50605ec5bae137ded730e330d8d7735 $ + * Time-stamp: "2009-11-01 10:50:34 bkorb" * * This file contains all of the routines that must be linked into * an executable to use the generated option processing. The optional * routines are in separately compiled modules so that they will not * necessarily be linked in. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ static char const zNil[] = ""; /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static tSuccess findOptDesc( tOptions* pOpts, tOptState* pOptState ); static tSuccess -nextOption( tOptions* pOpts, tOptState* pOptState ); +next_opt_arg_must(tOptions* pOpts, tOptState* pOptState); + +static tSuccess +next_opt_arg_may(tOptions* pOpts, tOptState* pOptState); + +static tSuccess +next_opt_arg_none(tOptions* pOpts, tOptState* pOptState); + +static tSuccess +nextOption(tOptions* pOpts, tOptState* pOptState); static tSuccess doPresets( tOptions* pOpts ); @@ -111,7 +97,7 @@ { char * res = strdup(str); if (res == NULL) { - fprintf( stderr, "strdup of %d byte string failed\n", (int)strlen(str) ); + fprintf(stderr, "strdup of %d byte string failed\n", (int)strlen(str)); exit( EXIT_FAILURE ); } return res; @@ -254,7 +240,7 @@ /* * If provided a procedure to call, call it */ - if (pOP != (tpOptProc)NULL) + if (pOP != NULL) (*pOP)( pOpts, pOD ); return SUCCESS; @@ -284,20 +270,30 @@ int matchCt = 0; int matchIdx = 0; int nameLen; + char opt_name_buf[128]; /* * IF the value is attached to the name, - * THEN clip it off. - * Either way, figure out how long our name is + * copy it off so we can NUL terminate. */ if (pzEq != NULL) { nameLen = (int)(pzEq - pzOptName); - *pzEq = NUL; + if (nameLen >= sizeof(opt_name_buf)) + return FAILURE; + memcpy(opt_name_buf, pzOptName, nameLen); + opt_name_buf[nameLen] = NUL; + pzOptName = opt_name_buf; + pzEq++; + } else nameLen = strlen( pzOptName ); do { - if (SKIP_OPT(pOD)) - continue; + if (SKIP_OPT(pOD)) { + if ( (pOD->fOptState != (OPTST_OMITTED | OPTST_NO_INIT)) + || (pOD->pz_Name == NULL)) + continue; + } + else assert(pOD->pz_Name != NULL); if (strneqvcmp( pzOptName, pOD->pz_Name, nameLen ) == 0) { /* @@ -348,13 +344,21 @@ } while (pOD++, (++idx < idxLim)); - if (pzEq != NULL) - *(pzEq++) = '='; - /* * Make sure we either found an exact match or found only one partial */ if (matchCt == 1) { + pOD = pOpts->pOptDesc + matchIdx; + + if (SKIP_OPT(pOD)) { + fprintf(stderr, zDisabledErr, pOpts->pzProgName, pOD->pz_Name); + if (pOD->pzText != NULL) + fprintf(stderr, " -- %s", pOD->pzText); + fputc('\n', stderr); + (*pOpts->pUsageProc)(pOpts, EXIT_FAILURE); + /* NOTREACHED */ + } + /* * IF we found a disablement name, * THEN set the bit in the callers' flag word @@ -362,7 +366,7 @@ if (disable) pOptState->flags |= OPTST_DISABLED; - pOptState->pOD = pOpts->pOptDesc + matchIdx; + pOptState->pOD = pOD; pOptState->pzOptArg = pzEq; pOptState->optType = TOPT_LONG; return SUCCESS; @@ -389,9 +393,9 @@ * THEN call the usage procedure. */ if ((pOpts->fOptSet & OPTPROC_ERRSTOP) != 0) { - fprintf( stderr, zIllOptStr, pOpts->pzProgPath, - (matchCt == 0) ? zIllegal : zAmbiguous, pzOptName ); - (*pOpts->pUsageProc)( pOpts, EXIT_FAILURE ); + fprintf(stderr, (matchCt == 0) ? zIllOptStr : zAmbigOptStr, + pOpts->pzProgPath, pzOptName); + (*pOpts->pUsageProc)(pOpts, EXIT_FAILURE); } return FAILURE; @@ -412,28 +416,28 @@ /* * Search the option list */ - for (;;) { - /* - * IF the values match, - * THEN we stop here - */ - if ((! SKIP_OPT(pRes)) && (optValue == pRes->optValue)) { - pOptState->pOD = pRes; - pOptState->optType = TOPT_SHORT; - return SUCCESS; + do { + if (optValue != pRes->optValue) + continue; + + if (SKIP_OPT(pRes)) { + if ( (pRes->fOptState == (OPTST_OMITTED | OPTST_NO_INIT)) + && (pRes->pz_Name != NULL)) { + fprintf(stderr, zDisabledErr, pOpts->pzProgPath, pRes->pz_Name); + if (pRes->pzText != NULL) + fprintf(stderr, " -- %s", pRes->pzText); + fputc('\n', stderr); + (*pOpts->pUsageProc)(pOpts, EXIT_FAILURE); + /* NOTREACHED */ + } + goto short_opt_error; } - /* - * Advance to next option description - */ - pRes++; + pOptState->pOD = pRes; + pOptState->optType = TOPT_SHORT; + return SUCCESS; - /* - * IF we have searched everything, ... - */ - if (--ct <= 0) - break; - } + } while (pRes++, --ct > 0); /* * IF the character value is a digit @@ -441,7 +445,7 @@ * THEN the result is the "option" itself and the * option is the specially marked "number" option. */ - if ( isdigit( optValue ) + if ( IS_DEC_DIGIT_CHAR(optValue) && (pOpts->specOptIdx.number_option != NO_EQUIVALENT) ) { pOptState->pOD = \ pRes = pOpts->pOptDesc + pOpts->specOptIdx.number_option; @@ -450,6 +454,8 @@ return SUCCESS; } + short_opt_error: + /* * IF we are to stop on errors (the default, actually) * THEN call the usage procedure. @@ -488,16 +494,28 @@ * IF all arguments must be named options, ... */ if (NAMED_OPTS(pOpts)) { - char* pz = pOpts->pzCurOpt; + char * pz = pOpts->pzCurOpt; + int def; + tSuccess res; + tAoUS * def_opt; + pOpts->curOptIdx++; - /* - * Skip over any flag/option markers. - * In this mode, they are not required. - */ - while (*pz == '-') pz++; + if (*pz != '-') + return longOptionFind(pOpts, pz, pOptState); - return longOptionFind( pOpts, pz, pOptState ); + /* + * The name is prefixed with one or more hyphens. Strip them off + * and disable the "default_opt" setting. Use heavy recasting to + * strip off the "const" quality of the "default_opt" field. + */ + while (*(++pz) == '-') ; + def_opt = (void *)&(pOpts->specOptIdx.default_opt); + def = *def_opt; + *def_opt = NO_EQUIVALENT; + res = longOptionFind(pOpts, pz, pOptState); + *def_opt = def; + return res; } /* @@ -553,186 +571,213 @@ } -/* - * nextOption - * - * Find the option descriptor and option argument (if any) for the - * next command line argument. DO NOT modify the descriptor. Put - * all the state in the state argument so that the option can be skipped - * without consequence (side effect). - */ static tSuccess -nextOption( tOptions* pOpts, tOptState* pOptState ) +next_opt_arg_must(tOptions* pOpts, tOptState* pOptState) { - tSuccess res; - enum { ARG_NONE, ARG_MAY, ARG_MUST } arg_type = ARG_NONE; - teOptArgType at; - - res = findOptDesc( pOpts, pOptState ); - if (! SUCCESSFUL( res )) - return res; - pOptState->flags |= (pOptState->pOD->fOptState & OPTST_PERSISTENT_MASK); - at = OPTST_GET_ARGTYPE(pOptState->flags); - /* - * Figure out what to do about option arguments. An argument may be - * required, not associated with the option, or be optional. We detect the - * latter by examining for an option marker on the next possible argument. - * Disabled mode option selection also disables option arguments. + * An option argument is required. Long options can either have + * a separate command line argument, or an argument attached by + * the '=' character. Figure out which. */ - if ((pOptState->flags & OPTST_DISABLED) != 0) - arg_type = ARG_NONE; - else if (at == OPARG_TYPE_NONE) - arg_type = ARG_NONE; - else if (pOptState->flags & OPTST_ARG_OPTIONAL) - arg_type = ARG_MAY; - else - arg_type = ARG_MUST; - - switch (arg_type) { - case ARG_MUST: + switch (pOptState->optType) { + case TOPT_SHORT: /* - * An option argument is required. Long options can either have - * a separate command line argument, or an argument attached by - * the '=' character. Figure out which. + * See if an arg string follows the flag character */ - switch (pOptState->optType) { - case TOPT_SHORT: - /* - * See if an arg string follows the flag character - */ - if (*++(pOpts->pzCurOpt) == NUL) - pOpts->pzCurOpt = pOpts->origArgVect[ pOpts->curOptIdx++ ]; - pOptState->pzOptArg = pOpts->pzCurOpt; - break; + if (*++(pOpts->pzCurOpt) == NUL) + pOpts->pzCurOpt = pOpts->origArgVect[ pOpts->curOptIdx++ ]; + pOptState->pzOptArg = pOpts->pzCurOpt; + break; - case TOPT_LONG: - /* - * See if an arg string has already been assigned (glued on - * with an `=' character) - */ - if (pOptState->pzOptArg == NULL) - pOptState->pzOptArg = pOpts->origArgVect[ pOpts->curOptIdx++ ]; - break; + case TOPT_LONG: + /* + * See if an arg string has already been assigned (glued on + * with an `=' character) + */ + if (pOptState->pzOptArg == NULL) + pOptState->pzOptArg = pOpts->origArgVect[ pOpts->curOptIdx++ ]; + break; - default: + default: #ifdef DEBUG - fputs( "AutoOpts lib error: option type not selected\n", - stderr ); - exit( EXIT_FAILURE ); + fputs( "AutoOpts lib error: option type not selected\n", + stderr ); + exit( EXIT_FAILURE ); #endif - case TOPT_DEFAULT: - /* - * The option was selected by default. The current token is - * the option argument. - */ - break; - } - + case TOPT_DEFAULT: /* - * Make sure we did not overflow the argument list. + * The option was selected by default. The current token is + * the option argument. */ - if (pOpts->curOptIdx > pOpts->origArgCt) { - fprintf( stderr, zMisArg, pOpts->pzProgPath, - pOptState->pOD->pz_Name ); - return FAILURE; - } - - pOpts->pzCurOpt = NULL; /* next time advance to next arg */ break; + } - case ARG_MAY: - /* - * An option argument is optional. - */ - switch (pOptState->optType) { - case TOPT_SHORT: - if (*++pOpts->pzCurOpt != NUL) - pOptState->pzOptArg = pOpts->pzCurOpt; - else { - char* pzLA = pOpts->origArgVect[ pOpts->curOptIdx ]; + /* + * Make sure we did not overflow the argument list. + */ + if (pOpts->curOptIdx > pOpts->origArgCt) { + fprintf( stderr, zMisArg, pOpts->pzProgPath, + pOptState->pOD->pz_Name ); + return FAILURE; + } - /* - * BECAUSE it is optional, we must make sure - * we did not find another flag and that there - * is such an argument. - */ - if ((pzLA == NULL) || (*pzLA == '-')) - pOptState->pzOptArg = NULL; - else { - pOpts->curOptIdx++; /* argument found */ - pOptState->pzOptArg = pzLA; - } - } - break; + pOpts->pzCurOpt = NULL; /* next time advance to next arg */ + return SUCCESS; +} + + +static tSuccess +next_opt_arg_may(tOptions* pOpts, tOptState* pOptState) +{ + /* + * An option argument is optional. + */ + switch (pOptState->optType) { + case TOPT_SHORT: + if (*++pOpts->pzCurOpt != NUL) + pOptState->pzOptArg = pOpts->pzCurOpt; + else { + char* pzLA = pOpts->origArgVect[ pOpts->curOptIdx ]; - case TOPT_LONG: /* - * Look for an argument if we don't already have one (glued on - * with a `=' character) *AND* we are not in named argument mode + * BECAUSE it is optional, we must make sure + * we did not find another flag and that there + * is such an argument. */ - if ( (pOptState->pzOptArg == NULL) - && (! NAMED_OPTS(pOpts))) { - char* pzLA = pOpts->origArgVect[ pOpts->curOptIdx ]; - - /* - * BECAUSE it is optional, we must make sure - * we did not find another flag and that there - * is such an argument. - */ - if ((pzLA == NULL) || (*pzLA == '-')) - pOptState->pzOptArg = NULL; - else { - pOpts->curOptIdx++; /* argument found */ - pOptState->pzOptArg = pzLA; - } + if ((pzLA == NULL) || (*pzLA == '-')) + pOptState->pzOptArg = NULL; + else { + pOpts->curOptIdx++; /* argument found */ + pOptState->pzOptArg = pzLA; } - break; - - default: - case TOPT_DEFAULT: - fputs( "AutoOpts lib error: defaulted to option with optional arg\n", - stderr ); - exit( EX_SOFTWARE ); } - - /* - * After an option with an optional argument, we will - * *always* start with the next option because if there - * were any characters following the option name/flag, - * they would be interpreted as the argument. - */ - pOpts->pzCurOpt = NULL; break; - default: /* CANNOT */ + case TOPT_LONG: /* - * No option argument. Make sure next time around we find - * the correct option flag character for short options + * Look for an argument if we don't already have one (glued on + * with a `=' character) *AND* we are not in named argument mode */ - if (pOptState->optType == TOPT_SHORT) - (pOpts->pzCurOpt)++; + if ( (pOptState->pzOptArg == NULL) + && (! NAMED_OPTS(pOpts))) { + char* pzLA = pOpts->origArgVect[ pOpts->curOptIdx ]; - /* - * It is a long option. Make sure there was no ``=xxx'' argument - */ - else if (pOptState->pzOptArg != NULL) { - fprintf( stderr, zNoArg, pOpts->pzProgPath, - pOptState->pOD->pz_Name ); - return FAILURE; + /* + * BECAUSE it is optional, we must make sure + * we did not find another flag and that there + * is such an argument. + */ + if ((pzLA == NULL) || (*pzLA == '-')) + pOptState->pzOptArg = NULL; + else { + pOpts->curOptIdx++; /* argument found */ + pOptState->pzOptArg = pzLA; + } } + break; - /* - * It is a long option. Advance to next command line argument. - */ - else - pOpts->pzCurOpt = NULL; + default: + case TOPT_DEFAULT: + fputs(zAO_Woops, stderr ); + exit( EX_SOFTWARE ); + } + + /* + * After an option with an optional argument, we will + * *always* start with the next option because if there + * were any characters following the option name/flag, + * they would be interpreted as the argument. + */ + pOpts->pzCurOpt = NULL; + return SUCCESS; +} + + +static tSuccess +next_opt_arg_none(tOptions* pOpts, tOptState* pOptState) +{ + /* + * No option argument. Make sure next time around we find + * the correct option flag character for short options + */ + if (pOptState->optType == TOPT_SHORT) + (pOpts->pzCurOpt)++; + + /* + * It is a long option. Make sure there was no ``=xxx'' argument + */ + else if (pOptState->pzOptArg != NULL) { + fprintf(stderr, zNoArg, pOpts->pzProgPath, pOptState->pOD->pz_Name); + return FAILURE; } + /* + * It is a long option. Advance to next command line argument. + */ + else + pOpts->pzCurOpt = NULL; return SUCCESS; } +/* + * nextOption + * + * Find the option descriptor and option argument (if any) for the + * next command line argument. DO NOT modify the descriptor. Put + * all the state in the state argument so that the option can be skipped + * without consequence (side effect). + */ +static tSuccess +nextOption(tOptions* pOpts, tOptState* pOptState) +{ + { + tSuccess res; + res = findOptDesc( pOpts, pOptState ); + if (! SUCCESSFUL( res )) + return res; + } + + if ( ((pOptState->flags & OPTST_DEFINED) != 0) + && ((pOptState->pOD->fOptState & OPTST_NO_COMMAND) != 0)) { + fprintf(stderr, zNotCmdOpt, pOptState->pOD->pz_Name); + return FAILURE; + } + + pOptState->flags |= (pOptState->pOD->fOptState & OPTST_PERSISTENT_MASK); + + /* + * Figure out what to do about option arguments. An argument may be + * required, not associated with the option, or be optional. We detect the + * latter by examining for an option marker on the next possible argument. + * Disabled mode option selection also disables option arguments. + */ + { + enum { ARG_NONE, ARG_MAY, ARG_MUST } arg_type = ARG_NONE; + tSuccess res; + + if ((pOptState->flags & OPTST_DISABLED) != 0) + arg_type = ARG_NONE; + + else if (OPTST_GET_ARGTYPE(pOptState->flags) == OPARG_TYPE_NONE) + arg_type = ARG_NONE; + + else if (pOptState->flags & OPTST_ARG_OPTIONAL) + arg_type = ARG_MAY; + + else + arg_type = ARG_MUST; + + switch (arg_type) { + case ARG_MUST: res = next_opt_arg_must(pOpts, pOptState); break; + case ARG_MAY: res = next_opt_arg_may( pOpts, pOptState); break; + case ARG_NONE: res = next_opt_arg_none(pOpts, pOptState); break; + } + + return res; + } +} + /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * @@ -837,7 +882,8 @@ * has a --load-opts option. See if a command line option has disabled * option presetting. */ - if (pOpts->specOptIdx.save_opts != 0) { + if ( (pOpts->specOptIdx.save_opts != NO_EQUIVALENT) + && (pOpts->specOptIdx.save_opts != 0)) { pOD = pOpts->pOptDesc + pOpts->specOptIdx.save_opts + 1; if (DISABLED_OPT(pOD)) return SUCCESS; @@ -1064,6 +1110,20 @@ if (! SUCCESSFUL( doPresets( pOpts ))) return 0; + /* + * IF option name conversion was suppressed but it is not suppressed + * for the command line, then it's time to translate option names. + * Usage text will not get retranslated. + */ + if ( ((pOpts->fOptSet & OPTPROC_TRANSLATE) != 0) + && (pOpts->pTransProc != NULL) + && ((pOpts->fOptSet & OPTPROC_NO_XLAT_MASK) + == OPTPROC_NXLAT_OPT_CFG) ) { + + pOpts->fOptSet &= ~OPTPROC_NXLAT_OPT_CFG; + (*pOpts->pTransProc)(); + } + if ((pOpts->fOptSet & OPTPROC_REORDER) != 0) optionSort( pOpts ); @@ -1090,7 +1150,8 @@ * THEN do that now before testing for conflicts. * (conflicts are ignored in preset options) */ - if (pOpts->specOptIdx.save_opts != 0) { + if ( (pOpts->specOptIdx.save_opts != NO_EQUIVALENT) + && (pOpts->specOptIdx.save_opts != 0)) { tOptDesc* pOD = pOpts->pOptDesc + pOpts->specOptIdx.save_opts; if (SELECTED_OPT( pOD )) { diff -urN src/contrib/ntp/sntp/libopts/autoopts.h src.ntp/contrib/ntp/sntp/libopts/autoopts.h --- src/contrib/ntp/sntp/libopts/autoopts.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/autoopts.h 2009-12-09 08:36:46.000000000 +0100 @@ -1,61 +1,38 @@ /* - * Time-stamp: "2007-04-15 09:59:39 bkorb" + * Time-stamp: "2008-11-01 20:08:06 bkorb" * - * autoopts.h $Id: autoopts.h,v 4.23 2007/04/15 19:01:18 bkorb Exp $ - * Time-stamp: "2005-02-14 05:59:50 bkorb" + * autoopts.h $Id: d5e30331d37ca10ec88c592d24d8615dd6c1f0ee $ * * This file defines all the global structures and special values * used in the automated option processing library. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ #ifndef AUTOGEN_AUTOOPTS_H #define AUTOGEN_AUTOOPTS_H #include "compat/compat.h" +#include "ag-char-map.h" #define AO_NAME_LIMIT 127 #define AO_NAME_SIZE ((size_t)(AO_NAME_LIMIT + 1)) @@ -110,8 +87,6 @@ #define PROCESSING(d) ((d)>0) #define PRESETTING(d) ((d)<0) -#define ISNAMECHAR( c ) (isalnum(c) || ((c) == '_') || ((c) == '-')) - /* * Procedure success codes * @@ -222,6 +197,7 @@ tCC* pzStr; tCC* pzReq; tCC* pzNum; + tCC* pzFile; tCC* pzKey; tCC* pzKeyL; tCC* pzBool; @@ -232,11 +208,12 @@ tCC* pzNoF; tCC* pzSpc; tCC* pzOptFmt; + tCC* pzTime; } arg_types_t; #define AGALOC( c, w ) ao_malloc((size_t)c) #define AGREALOC( p, c, w ) ao_realloc((void*)p, (size_t)c) -#define AGFREE( p ) ao_free((void*)p) +#define AGFREE(_p) do{void*X=(void*)_p;ao_free(X);}while(0) #define AGDUPSTR( p, s, w ) (p = ao_strdup(s)) static void * diff -urN src/contrib/ntp/sntp/libopts/boolean.c src.ntp/contrib/ntp/sntp/libopts/boolean.c --- src/contrib/ntp/sntp/libopts/boolean.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/boolean.c 2009-12-09 08:36:46.000000000 +0100 @@ -1,55 +1,32 @@ /* - * $Id: boolean.c,v 4.10 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-13 10:10:39 bkorb" + * $Id: 329b43154b88d78564d8f960a00a83ec7d8baee0 $ + * Time-stamp: "2008-08-03 13:06:02 bkorb" * * Automated Options Paged Usage module. * * This routine will run run-on options through a pager so the * user may examine, print or edit them at their leisure. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ /*=export_func optionBooleanVal @@ -70,6 +47,14 @@ char* pz; ag_bool res = AG_TRUE; + if ((pOD->fOptState & OPTST_RESET) != 0) + return; + + if (pOD->optArg.argString == NULL) { + pOD->optArg.argBool = AG_FALSE; + return; + } + switch (*(pOD->optArg.argString)) { case '0': { diff -urN src/contrib/ntp/sntp/libopts/compat/compat.h src.ntp/contrib/ntp/sntp/libopts/compat/compat.h --- src/contrib/ntp/sntp/libopts/compat/compat.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/compat/compat.h 2009-12-09 08:36:46.000000000 +0100 @@ -1,13 +1,51 @@ /* -*- Mode: C -*- */ -/* --- fake the preprocessor into handlng portability */ -/* - * Time-stamp: "2007-02-03 17:41:06 bkorb" +/* compat.h --- fake the preprocessor into handlng portability + * + * Time-stamp: "2009-10-18 11:14:14 bkorb" + * + * $Id: 27c1eb45f171295ab6176280aeca742cfdbe9fed $ + * + * compat.h is free software. + * This file is part of AutoGen. + * + * AutoGen copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoGen is free software: you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * AutoGen is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the GNU General Public License for more details. * - * Author: Gary V Vaughan - * Created: Mon Jun 30 15:54:46 1997 + * You should have received a copy of the GNU General Public License along + * with this program. If not, see . * - * $Id: compat.h,v 4.16 2007/04/27 01:10:47 bkorb Exp $ + * As a special exception, Bruce Korb gives permission for additional + * uses of the text contained in the release of compat.h. + * + * The exception is that, if you link the compat.h library with other + * files to produce an executable, this does not by itself cause the + * resulting executable to be covered by the GNU General Public License. + * Your use of that executable is in no way restricted on account of + * linking the compat.h library code into it. + * + * This exception does not however invalidate any other reasons why + * the executable file might be covered by the GNU General Public License. + * + * This exception applies only to the code released by Bruce Korb under + * the name compat.h. If you copy code from other sources under the + * General Public License into a copy of compat.h, as the General Public + * License permits, the exception does not apply to the code that you add + * in this way. To avoid misleading anyone as to the status of such + * modified files, you must delete this exception notice from them. + * + * If you write modifications of your own for compat.h, it is your choice + * whether to permit this exception to apply to your modifications. + * If you do not wish that, delete this exception notice. */ #ifndef COMPAT_H_GUARD #define COMPAT_H_GUARD 1 @@ -221,57 +259,89 @@ #endif #ifndef SHORT_MAX -# define SHORT_MAX ~(1 << (8*sizeof(short) -1)) +# define SHORT_MAX ~(1 << (8*sizeof(short) - 1)) #else # define USHORT_MAX ~(OUS) #endif #ifndef HAVE_INT8_T - typedef signed char int8_t; + typedef signed char int8_t; +# define HAVE_INT8_T 1 #endif #ifndef HAVE_UINT8_T - typedef unsigned char uint8_t; + typedef unsigned char uint8_t; +# define HAVE_UINT8_T 1 #endif #ifndef HAVE_INT16_T - typedef signed short int16_t; + typedef signed short int16_t; +# define HAVE_INT16_T 1 #endif #ifndef HAVE_UINT16_T - typedef unsigned short uint16_t; -#endif -#ifndef HAVE_UINT_T - typedef unsigned int uint_t; + typedef unsigned short uint16_t; +# define HAVE_UINT16_T 1 #endif #ifndef HAVE_INT32_T -# if SIZEOF_INT == 4 - typedef signed int int32_t; -# elif SIZEOF_LONG == 4 - typedef signed long int32_t; +# if SIZEOF_INT == 4 + typedef signed int int32_t; +# elif SIZEOF_LONG == 4 + typedef signed long int32_t; # endif +# define HAVE_INT32_T 1 #endif #ifndef HAVE_UINT32_T -# if SIZEOF_INT == 4 - typedef unsigned int uint32_t; -# elif SIZEOF_LONG == 4 - typedef unsigned long uint32_t; +# if SIZEOF_INT == 4 + typedef unsigned int uint32_t; +# elif SIZEOF_LONG == 4 + typedef unsigned long uint32_t; # else # error Cannot create a uint32_t type. Choke Me. # endif +# define HAVE_UINT32_T 1 #endif #ifndef HAVE_INTPTR_T - typedef signed long intptr_t; +# if SIZEOF_CHARP == SIZEOF_LONG + typedef signed long intptr_t; +# else + typedef signed int intptr_t; +# endif +# define HAVE_INTPTR_T 1 #endif + #ifndef HAVE_UINTPTR_T - typedef unsigned long uintptr_t; +# if SIZEOF_CHARP == SIZEOF_LONG + typedef unsigned long intptr_t; +# else + typedef unsigned int intptr_t; +# endif +# define HAVE_INTPTR_T 1 +#endif + +#ifndef HAVE_UINT_T + typedef unsigned int uint_t; +# define HAVE_UINT_T 1 +#endif + +#ifndef HAVE_SIZE_T + typedef unsigned int size_t; +# define HAVE_SIZE_T 1 +#endif +#ifndef HAVE_WINT_T + typedef unsigned int wint_t; +# define HAVE_WINT_T 1 +#endif +#ifndef HAVE_PID_T + typedef signed int pid_t; +# define HAVE_PID_T 1 #endif /* redefine these for BSD style string libraries */ #ifndef HAVE_STRCHR -# define strchr index -# define strrchr rindex +# define strchr index +# define strrchr rindex #endif #ifdef USE_FOPEN_BINARY diff -urN src/contrib/ntp/sntp/libopts/compat/pathfind.c src.ntp/contrib/ntp/sntp/libopts/compat/pathfind.c --- src/contrib/ntp/sntp/libopts/compat/pathfind.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/compat/pathfind.c 2009-12-09 08:36:46.000000000 +0100 @@ -5,11 +5,9 @@ /* * Author: Gary V Vaughan * Time-stamp: "2006-09-23 19:46:16 bkorb" - * Created: Tue Jun 24 15:07:31 1997 - * Last Modified: $Date: 2006/11/27 01:52:23 $ * by: bkorb * - * $Id: pathfind.c,v 4.10 2006/11/27 01:52:23 bkorb Exp $ + * $Id: 8ce7ddfe2378f0b75c91c0ab348a6ad81634fb01 $ */ /* Code: */ diff -urN src/contrib/ntp/sntp/libopts/compat/windows-config.h src.ntp/contrib/ntp/sntp/libopts/compat/windows-config.h --- src/contrib/ntp/sntp/libopts/compat/windows-config.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/compat/windows-config.h 2009-12-09 08:36:46.000000000 +0100 @@ -1,8 +1,24 @@ /* - * Time-stamp: "2006-10-14 14:55:09 bkorb" + * Time-stamp: "2009-07-22 18:53:59 bkorb" * by: bkorb - * Last Committed: $Date: 2007/04/28 22:19:23 $ + * + * This file is part of AutoGen. + * + * AutoGen copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoGen is free software: you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * AutoGen is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along + * with this program. If not, see . */ #ifndef WINDOWS_CONFIG_HACKERY #define WINDOWS_CONFIG_HACKERY 1 diff -urN src/contrib/ntp/sntp/libopts/configfile.c src.ntp/contrib/ntp/sntp/libopts/configfile.c --- src/contrib/ntp/sntp/libopts/configfile.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/configfile.c 2009-12-09 08:36:46.000000000 +0100 @@ -1,55 +1,32 @@ /* - * $Id: configfile.c,v 1.21 2007/04/15 19:01:18 bkorb Exp $ - * Time-stamp: "2007-04-15 11:22:46 bkorb" + * $Id: f1650b45a91ec95af830ff76041cc4f0048e60f0 $ + * Time-stamp: "2009-01-18 10:21:58 bkorb" * * configuration/rc/ini file handling. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static void filePreset( tOptions* pOpts, @@ -90,11 +67,6 @@ tOptionValue* pType ); static char* -parseLoadMode( - char* pzText, - tOptionLoadMode* pMode ); - -static char* parseSetMemType( tOptions* pOpts, char* pzText, @@ -444,7 +416,7 @@ int direction ) { tmap_info_t cfgfile; - tOptState st = OPTSTATE_INITIALIZER(PRESET); + tOptState optst = OPTSTATE_INITIALIZER(PRESET); char* pzFileText = text_mmap( pzFileName, PROT_READ|PROT_WRITE, MAP_PRIVATE, &cfgfile ); @@ -452,8 +424,8 @@ return; if (direction == DIRECTION_CALLED) { - st.flags = OPTST_DEFINED; - direction = DIRECTION_PROCESS; + optst.flags = OPTST_DEFINED; + direction = DIRECTION_PROCESS; } /* @@ -463,18 +435,19 @@ * and we consider stuff set herein to be "set" by the client program. */ if ((pOpts->fOptSet & OPTPROC_PRESETTING) == 0) - st.flags = OPTST_SET; + optst.flags = OPTST_SET; do { - while (isspace( (int)*pzFileText )) pzFileText++; + while (IS_WHITESPACE_CHAR(*pzFileText)) pzFileText++; - if (isalpha( (int)*pzFileText )) { - pzFileText = handleConfig( pOpts, &st, pzFileText, direction ); + if (IS_VAR_FIRST_CHAR(*pzFileText)) { + pzFileText = handleConfig(pOpts, &optst, pzFileText, direction); } else switch (*pzFileText) { case '<': - if (isalpha( (int)pzFileText[1] )) - pzFileText = handleStructure(pOpts, &st, pzFileText, direction); + if (IS_VAR_FIRST_CHAR(pzFileText[1])) + pzFileText = + handleStructure(pOpts, &optst, pzFileText, direction); else switch (pzFileText[1]) { case '?': @@ -549,8 +522,8 @@ if (pzEnd == NULL) return pzText + strlen(pzText); - while (ISNAMECHAR( (int)*pzText )) pzText++; - while (isspace( (int)*pzText )) pzText++; + while (IS_VALUE_NAME_CHAR(*pzText)) pzText++; + while (IS_WHITESPACE_CHAR(*pzText)) pzText++; if (pzText > pzEnd) { name_only: *pzEnd++ = NUL; @@ -564,10 +537,10 @@ * is an invalid format and we give up parsing the text. */ if ((*pzText == '=') || (*pzText == ':')) { - while (isspace( (int)*++pzText )) ; + while (IS_WHITESPACE_CHAR(*++pzText)) ; if (pzText > pzEnd) goto name_only; - } else if (! isspace((int)pzText[-1])) + } else if (! IS_WHITESPACE_CHAR(pzText[-1])) return NULL; /* @@ -631,7 +604,7 @@ size_t name_len; if ( (strncmp( pzText+2, zProg, title_len ) != 0) - || (! isspace( (int)pzText[title_len+2] )) ) { + || (! IS_WHITESPACE_CHAR(pzText[title_len+2])) ) { pzText = strchr( pzText+2, '>' ); if (pzText != NULL) pzText++; @@ -645,8 +618,8 @@ do { pzText += title_len; - if (isspace((int)*pzText)) { - while (isspace((int)*pzText)) pzText++; + if (IS_WHITESPACE_CHAR(*pzText)) { + while (IS_WHITESPACE_CHAR(*++pzText)) ; if ( (strneqvcmp( pzText, pOpts->pzProgName, (int)name_len) == 0) && (pzText[name_len] == '>')) { pzText += name_len + 1; @@ -706,13 +679,13 @@ int direction ) { tOptionLoadMode mode = option_load_mode; - tOptionValue valu; + tOptionValue valu; char* pzName = ++pzText; char* pzData; char* pcNulPoint; - while (ISNAMECHAR( *pzText )) pzText++; + while (IS_VALUE_NAME_CHAR(*pzText)) pzText++; pcNulPoint = pzText; valu.valType = OPARG_TYPE_STRING; @@ -780,6 +753,36 @@ memset(pcNulPoint, ' ', pzData - pcNulPoint); /* + * If we are getting a "string" value, the process the XML-ish + * %XX hex characters. + */ + if (valu.valType == OPARG_TYPE_STRING) { + char * pzSrc = pzData; + char * pzDst = pzData; + char bf[4]; + bf[2] = NUL; + + for (;;) { + int ch = ((int)*(pzSrc++)) & 0xFF; + switch (ch) { + case NUL: goto string_fixup_done; + + case '%': + bf[0] = *(pzSrc++); + bf[1] = *(pzSrc++); + if ((bf[0] == NUL) || (bf[1] == NUL)) + goto string_fixup_done; + ch = strtoul(bf, NULL, 16); + /* FALLTHROUGH */ + + default: + *(pzDst++) = ch; + } + } string_fixup_done:; + *pzDst = NUL; + } + + /* * "pzName" points to what looks like text for one option/configurable. * It is NUL terminated. Process it. */ @@ -798,13 +801,22 @@ LOCAL void internalFileLoad( tOptions* pOpts ) { - int idx; - int inc = DIRECTION_PRESET; - char zFileName[ AG_PATH_MAX+1 ]; + uint32_t svfl; + int idx; + int inc; + char zFileName[ AG_PATH_MAX+1 ]; if (pOpts->papzHomeList == NULL) return; + svfl = pOpts->fOptSet; + inc = DIRECTION_PRESET; + + /* + * Never stop on errors in config files. + */ + pOpts->fOptSet &= ~OPTPROC_ERRSTOP; + /* * Find the last RC entry (highest priority entry) */ @@ -877,6 +889,8 @@ } } } /* twice for every path in the home list, ... */ + + pOpts->fOptSet = svfl; } @@ -939,35 +953,38 @@ void optionLoadOpt( tOptions* pOpts, tOptDesc* pOptDesc ) { + struct stat sb; + /* * IF the option is not being disabled, THEN load the file. There must * be a file. (If it is being disabled, then the disablement processing * already took place. It must be done to suppress preloading of ini/rc * files.) */ - if (! DISABLED_OPT( pOptDesc )) { - struct stat sb; - if (stat( pOptDesc->optArg.argString, &sb ) != 0) { - if ((pOpts->fOptSet & OPTPROC_ERRSTOP) == 0) - return; - - fprintf( stderr, zFSErrOptLoad, errno, strerror( errno ), - pOptDesc->optArg.argString ); - exit(EX_NOINPUT); - /* NOT REACHED */ - } + if ( DISABLED_OPT(pOptDesc) + || ((pOptDesc->fOptState & OPTST_RESET) != 0)) + return; - if (! S_ISREG( sb.st_mode )) { - if ((pOpts->fOptSet & OPTPROC_ERRSTOP) == 0) - return; - - fprintf( stderr, zNotFile, pOptDesc->optArg.argString ); - exit(EX_NOINPUT); - /* NOT REACHED */ - } + if (stat( pOptDesc->optArg.argString, &sb ) != 0) { + if ((pOpts->fOptSet & OPTPROC_ERRSTOP) == 0) + return; + + fprintf( stderr, zFSErrOptLoad, errno, strerror( errno ), + pOptDesc->optArg.argString ); + exit(EX_NOINPUT); + /* NOT REACHED */ + } - filePreset(pOpts, pOptDesc->optArg.argString, DIRECTION_CALLED); + if (! S_ISREG( sb.st_mode )) { + if ((pOpts->fOptSet & OPTPROC_ERRSTOP) == 0) + return; + + fprintf( stderr, zNotFile, pOptDesc->optArg.argString ); + exit(EX_NOINPUT); + /* NOT REACHED */ } + + filePreset(pOpts, pOptDesc->optArg.argString, DIRECTION_CALLED); } @@ -982,45 +999,65 @@ tOptionLoadMode* pMode, tOptionValue* pType ) { - size_t lenLoadType = strlen( zLoadType ); - size_t lenKeyWords = strlen( zKeyWords ); - size_t lenSetMem = strlen( zSetMembers ); + size_t len; do { - switch (*pzText) { - case '/': pType->valType = OPARG_TYPE_NONE; - case '>': return pzText; + if (! IS_WHITESPACE_CHAR(*pzText)) + switch (*pzText) { + case '/': pType->valType = OPARG_TYPE_NONE; + case '>': return pzText; - default: - case NUL: return NULL; + default: + case NUL: return NULL; + } - case ' ': - case '\t': - case '\n': - case '\f': - case '\r': - case '\v': + while (IS_WHITESPACE_CHAR(*++pzText)) ; + len = 0; + while (IS_LOWER_CASE_CHAR(pzText[len])) len++; + + switch (find_xat_attribute_id(pzText, len)) { + case XAT_KWD_TYPE: + pzText = parseValueType( pzText+len, pType ); break; - } - while (isspace( (int)*++pzText )) ; + case XAT_KWD_WORDS: + pzText = parseKeyWordType( pOpts, pzText+len, pType ); + break; - if (strncmp( pzText, zLoadType, lenLoadType ) == 0) { - pzText = parseValueType( pzText+lenLoadType, pType ); - continue; - } + case XAT_KWD_MEMBERS: + pzText = parseSetMemType( pOpts, pzText+len, pType ); + break; - if (strncmp( pzText, zKeyWords, lenKeyWords ) == 0) { - pzText = parseKeyWordType( pOpts, pzText+lenKeyWords, pType ); - continue; - } + case XAT_KWD_COOKED: + pzText += len; + if (! IS_END_XML_TOKEN_CHAR(*pzText)) + goto invalid_kwd; - if (strncmp( pzText, zSetMembers, lenSetMem ) == 0) { - pzText = parseSetMemType( pOpts, pzText+lenSetMem, pType ); - continue; - } + *pMode = OPTION_LOAD_COOKED; + break; + + case XAT_KWD_UNCOOKED: + pzText += len; + if (! IS_END_XML_TOKEN_CHAR(*pzText)) + goto invalid_kwd; + + *pMode = OPTION_LOAD_UNCOOKED; + break; + + case XAT_KWD_KEEP: + pzText += len; + if (! IS_END_XML_TOKEN_CHAR(*pzText)) + goto invalid_kwd; - pzText = parseLoadMode( pzText, pMode ); + *pMode = OPTION_LOAD_KEEP; + break; + + default: + case XAT_KWD_INVALID: + invalid_kwd: + pType->valType = OPARG_TYPE_NONE; + return skipUnknown( pzText ); + } } while (pzText != NULL); return pzText; @@ -1042,61 +1079,6 @@ } -/* parseLoadMode - * - * "pzText" points to some name character. We check for "cooked" or - * "uncooked" or "keep". This function should handle any attribute - * that does not have an associated value. - */ -static char* -parseLoadMode( - char* pzText, - tOptionLoadMode* pMode ) -{ - { - size_t len = strlen(zLoadCooked); - if (strncmp( pzText, zLoadCooked, len ) == 0) { - if ( (pzText[len] == '>') - || (pzText[len] == '/') - || isspace((int)pzText[len])) { - *pMode = OPTION_LOAD_COOKED; - return pzText + len; - } - goto unknown; - } - } - - { - size_t len = strlen(zLoadUncooked); - if (strncmp( pzText, zLoadUncooked, len ) == 0) { - if ( (pzText[len] == '>') - || (pzText[len] == '/') - || isspace((int)pzText[len])) { - *pMode = OPTION_LOAD_UNCOOKED; - return pzText + len; - } - goto unknown; - } - } - - { - size_t len = strlen(zLoadKeep); - if (strncmp( pzText, zLoadKeep, len ) == 0) { - if ( (pzText[len] == '>') - || (pzText[len] == '/') - || isspace((int)pzText[len])) { - *pMode = OPTION_LOAD_KEEP; - return pzText + len; - } - goto unknown; - } - } - - unknown: - return skipUnknown( pzText ); -} - - /* parseSetMemType * * "pzText" points to the character after "members=" @@ -1122,75 +1104,52 @@ char* pzText, tOptionValue* pType ) { - { - size_t len = strlen(zLtypeString); - if (strncmp( pzText, zLtypeString, len ) == 0) { - if ((pzText[len] == '>') || isspace((int)pzText[len])) { - pType->valType = OPARG_TYPE_STRING; - return pzText + len; - } - goto unknown; - } - } + size_t len = 0; - { - size_t len = strlen(zLtypeInteger); - if (strncmp( pzText, zLtypeInteger, len ) == 0) { - if ((pzText[len] == '>') || isspace((int)pzText[len])) { - pType->valType = OPARG_TYPE_NUMERIC; - return pzText + len; - } - goto unknown; - } - } + if (*(pzText++) != '=') + goto woops; - { - size_t len = strlen(zLtypeBool); - if (strncmp( pzText, zLtypeBool, len ) == 0) { - if ((pzText[len] == '>') || isspace(pzText[len])) { - pType->valType = OPARG_TYPE_BOOLEAN; - return pzText + len; - } - goto unknown; - } - } + while (IS_OPTION_NAME_CHAR(pzText[len])) len++; + pzText += len; - { - size_t len = strlen(zLtypeKeyword); - if (strncmp( pzText, zLtypeKeyword, len ) == 0) { - if ((pzText[len] == '>') || isspace((int)pzText[len])) { - pType->valType = OPARG_TYPE_ENUMERATION; - return pzText + len; - } - goto unknown; - } + if ((len == 0) || (! IS_END_XML_TOKEN_CHAR(*pzText))) { + woops: + pType->valType = OPARG_TYPE_NONE; + return skipUnknown( pzText ); } - { - size_t len = strlen(zLtypeSetMembership); - if (strncmp( pzText, zLtypeSetMembership, len ) == 0) { - if ((pzText[len] == '>') || isspace((int)pzText[len])) { - pType->valType = OPARG_TYPE_MEMBERSHIP; - return pzText + len; - } - goto unknown; - } - } + switch (find_value_type_id(pzText - len, len)) { + default: + case VTP_KWD_INVALID: goto woops; - { - size_t len = strlen(zLtypeNest); - if (strncmp( pzText, zLtypeNest, len ) == 0) { - if ((pzText[len] == '>') || isspace((int)pzText[len])) { - pType->valType = OPARG_TYPE_HIERARCHY; - return pzText + len; - } - goto unknown; - } + case VTP_KWD_STRING: + pType->valType = OPARG_TYPE_STRING; + break; + + case VTP_KWD_INTEGER: + pType->valType = OPARG_TYPE_NUMERIC; + break; + + case VTP_KWD_BOOL: + case VTP_KWD_BOOLEAN: + pType->valType = OPARG_TYPE_BOOLEAN; + break; + + case VTP_KWD_KEYWORD: + pType->valType = OPARG_TYPE_ENUMERATION; + break; + + case VTP_KWD_SET: + case VTP_KWD_SET_MEMBERSHIP: + pType->valType = OPARG_TYPE_MEMBERSHIP; + break; + + case VTP_KWD_NESTED: + case VTP_KWD_HIERARCHY: + pType->valType = OPARG_TYPE_HIERARCHY; } - unknown: - pType->valType = OPARG_TYPE_NONE; - return skipUnknown( pzText ); + return pzText; } @@ -1202,12 +1161,8 @@ skipUnknown( char* pzText ) { for (;; pzText++) { - if (isspace( (int)*pzText )) return pzText; - switch (*pzText) { - case NUL: return NULL; - case '/': - case '>': return pzText; - } + if (IS_END_XML_TOKEN_CHAR(*pzText)) return pzText; + if (*pzText == NUL) return NULL; } } @@ -1233,7 +1188,14 @@ * is available, then go do it. */ if ( ((pOpts->fOptSet & OPTPROC_TRANSLATE) != 0) - && (pOpts->pTransProc != 0) ) { + && (pOpts->pTransProc != NULL) ) { + /* + * If option names are not to be translated at all, then do not do + * it for configuration parsing either. (That is the bit that really + * gets tested anyway.) + */ + if ((pOpts->fOptSet & OPTPROC_NO_XLAT_MASK) == OPTPROC_NXLAT_OPT) + pOpts->fOptSet |= OPTPROC_NXLAT_OPT_CFG; (*pOpts->pTransProc)(); pOpts->fOptSet &= ~OPTPROC_TRANSLATE; } @@ -1248,8 +1210,7 @@ || (pOpts->structVersion < OPTIONS_MINIMUM_VERSION ) ) ) { - fprintf( stderr, zAO_Err, pOpts->origArgVect[0], - NUM_TO_VER( pOpts->structVersion )); + fprintf(stderr, zAO_Err, pzProgram, NUM_TO_VER(pOpts->structVersion)); if (pOpts->structVersion > OPTIONS_STRUCT_VERSION ) fputs( zAO_Big, stderr ); else diff -urN src/contrib/ntp/sntp/libopts/cook.c src.ntp/contrib/ntp/sntp/libopts/cook.c --- src/contrib/ntp/sntp/libopts/cook.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/cook.c 2009-12-09 08:36:46.000000000 +0100 @@ -1,57 +1,33 @@ - /* - * $Id: cook.c,v 4.10 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2006-09-24 15:21:02 bkorb" + * $Id: 3da9a5fc88c904673b3b95d0c9667b2bcbccfc80 $ + * Time-stamp: "2007-11-16 22:49:11 bkorb" * * This file contains the routines that deal with processing quoted strings * into an internal format. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ /* = = = END-STATIC-FORWARD = = = */ /*=export_func ao_string_cook_escape_char @@ -105,79 +81,42 @@ case 't': *pRes = '\t'; break; case 'v': *pRes = '\v'; break; - case 'x': /* HEX Escape */ - if (isxdigit( (int)*pzIn )) { - unsigned int val; - unsigned char ch = *pzIn++; - - if ((ch >= 'A') && (ch <= 'F')) - val = 10 + (ch - 'A'); - else if ((ch >= 'a') && (ch <= 'f')) - val = 10 + (ch - 'a'); - else val = ch - '0'; - - ch = *pzIn; - - if (! isxdigit( ch )) { - *pRes = val; - res = 2; - break; - } - val <<= 4; - if ((ch >= 'A') && (ch <= 'F')) - val += 10 + (ch - 'A'); - else if ((ch >= 'a') && (ch <= 'f')) - val += 10 + (ch - 'a'); - else val += ch - '0'; - - res = 3; - *pRes = val; + case 'x': + case 'X': /* HEX Escape */ + if (IS_HEX_DIGIT_CHAR(*pzIn)) { + char z[4], *pz = z; + + do *(pz++) = *(pzIn++); + while (IS_HEX_DIGIT_CHAR(*pzIn) && (pz < z + 2)); + *pz = NUL; + *pRes = (unsigned char)strtoul(z, NULL, 16); + res += pz - z; } break; - default: + case '0': case '1': case '2': case '3': + case '4': case '5': case '6': case '7': + { /* * IF the character copied was an octal digit, * THEN set the output character to an octal value */ - if (isdigit( (int)*pRes ) && (*pRes < '8')) { - unsigned int val = *pRes - '0'; - unsigned char ch = *pzIn++; - - /* - * IF the second character is *not* an octal digit, - * THEN save the value and bail - */ - if ((ch < '0') || (ch > '7')) { - *pRes = val; - break; - } - - val = (val<<3) + (ch - '0'); - ch = *pzIn; - res = 2; - - /* - * IF the THIRD character is *not* an octal digit, - * THEN save the value and bail - */ - if ((ch < '0') || (ch > '7')) { - *pRes = val; - break; - } - - /* - * IF the new value would not be too large, - * THEN add on the third and last character value - */ - if ((val<<3) < 0xFF) { - val = (val<<3) + (ch - '0'); - res = 3; - } + char z[4], *pz = z + 1; + unsigned long val; + z[0] = *pRes; + + while (IS_OCT_DIGIT_CHAR(*pzIn) && (pz < z + 3)) + *(pz++) = *(pzIn++); + *pz = NUL; + val = strtoul(z, NULL, 8); + if (val > 0xFF) + val = 0xFF; + *pRes = (unsigned char)val; + res = pz - z; + break; + } - *pRes = val; - break; - } + default: ; } return res; @@ -239,7 +178,7 @@ pzS++; scan_for_quote: - while (isspace((int)*pzS)) + while (IS_WHITESPACE_CHAR(*pzS)) if (*(pzS++) == '\n') (*pLineCt)++; diff -urN src/contrib/ntp/sntp/libopts/enumeration.c src.ntp/contrib/ntp/sntp/libopts/enumeration.c --- src/contrib/ntp/sntp/libopts/enumeration.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/enumeration.c 2009-12-09 08:36:46.000000000 +0100 @@ -1,61 +1,38 @@ /* - * $Id: enumeration.c,v 4.17 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-13 10:22:35 bkorb" + * $Id: 27595043d23170eb4bb8b9831fc54016944e00e8 $ + * Time-stamp: "2008-07-27 12:28:01 bkorb" * * Automated Options Paged Usage module. * * This routine will run run-on options through a pager so the * user may examine, print or edit them at their leisure. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ tSCC* pz_enum_err_fmt; /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static void enumError( tOptions* pOpts, @@ -81,16 +58,27 @@ { size_t max_len = 0; size_t ttl_len = 0; + int ct_down = name_ct; + int hidden = 0; - if (pOpts != NULL) - fprintf( option_usage_fp, pz_enum_err_fmt, pOpts->pzProgName, - pOD->optArg.argString, pOD->pz_Name ); + /* + * A real "pOpts" pointer means someone messed up. Give a real error. + */ + if (pOpts > OPTPROC_EMIT_LIMIT) + fprintf(option_usage_fp, pz_enum_err_fmt, pOpts->pzProgName, + pOD->optArg.argString, pOD->pz_Name); - fprintf( option_usage_fp, zValidKeys, pOD->pz_Name ); + fprintf(option_usage_fp, zValidKeys, pOD->pz_Name); + /* + * If the first name starts with this funny character, then we have + * a first value with an unspellable name. You cannot specify it. + * So, we don't list it either. + */ if (**paz_names == 0x7F) { paz_names++; - name_ct--; + hidden = 1; + ct_down = --name_ct; } /* @@ -99,14 +87,15 @@ */ { tCC * const * paz = paz_names; - int ct = name_ct; do { size_t len = strlen( *(paz++) ) + 1; if (len > max_len) max_len = len; ttl_len += len; - } while (--ct > 0); + } while (--ct_down > 0); + + ct_down = name_ct; } /* @@ -115,7 +104,7 @@ if (max_len > 35) { do { fprintf( option_usage_fp, " %s\n", *(paz_names++) ); - } while (--name_ct > 0); + } while (--ct_down > 0); } /* @@ -126,7 +115,7 @@ do { fputc( ' ', option_usage_fp ); fputs( *(paz_names++), option_usage_fp ); - } while (--name_ct > 0); + } while (--ct_down > 0); fputc( '\n', option_usage_fp ); } @@ -144,7 +133,8 @@ /* * Loop through all but the last entry */ - while (--name_ct > 0) { + ct_down = name_ct; + while (--ct_down > 0) { if (++ent_no == max_len) { /* * Last entry on a line. Start next line, too. @@ -154,19 +144,25 @@ } else - fprintf( option_usage_fp, zFmt, *(paz_names++) ); + fprintf(option_usage_fp, zFmt, *(paz_names++) ); } - fprintf( option_usage_fp, "%s\n", *paz_names ); + fprintf(option_usage_fp, "%s\n", *paz_names); } - /* - * IF we do not have a pOpts pointer, then this output is being requested - * by the usage procedure. Let's not re-invoke it recursively. - */ - if (pOpts != NULL) + if (pOpts > OPTPROC_EMIT_LIMIT) { + fprintf(option_usage_fp, zIntRange, hidden, name_ct - 1 + hidden); + (*(pOpts->pUsageProc))( pOpts, EXIT_FAILURE ); - if (OPTST_GET_ARGTYPE(pOD->fOptState) == OPARG_TYPE_MEMBERSHIP) - fputs( zSetMemberSettings, option_usage_fp ); + /* NOTREACHED */ + } + + + if (OPTST_GET_ARGTYPE(pOD->fOptState) == OPARG_TYPE_MEMBERSHIP) { + fprintf(option_usage_fp, zLowerBits, name_ct); + fputs(zSetMemberSettings, option_usage_fp); + } else { + fprintf(option_usage_fp, zIntRange, hidden, name_ct - 1 + hidden); + } } @@ -178,9 +174,23 @@ tCC* const * paz_names, unsigned int name_ct ) { + /* + * Return the matching index as a pointer sized integer. + * The result gets stashed in a char* pointer. + */ uintptr_t res = name_ct; size_t len = strlen( (char*)pzName ); uintptr_t idx; + + if (IS_DEC_DIGIT_CHAR(*pzName)) { + char * pz = (char *)(void *)pzName; + unsigned long val = strtoul(pz, &pz, 0); + if ((*pz == NUL) && (val < name_ct)) + return (uintptr_t)val; + enumError(pOpts, pOD, paz_names, (int)name_ct); + return name_ct; + } + /* * Look for an exact match, but remember any partial matches. * Multiple partial matches means we have an ambiguous match. @@ -190,29 +200,17 @@ if (paz_names[idx][len] == NUL) return idx; /* full match */ - if (res != name_ct) { - pz_enum_err_fmt = zAmbigKey; - option_usage_fp = stderr; - enumError( pOpts, pOD, paz_names, (int)name_ct ); - } - res = idx; /* save partial match */ + res = (res != name_ct) ? ~0 : idx; /* save partial match */ } } - /* - * no partial match -> error - */ - if (res == name_ct) { - pz_enum_err_fmt = zNoKey; - option_usage_fp = stderr; - enumError( pOpts, pOD, paz_names, (int)name_ct ); - } + if (res < name_ct) + return res; /* partial match */ - /* - * Return the matching index as a char* pointer. - * The result gets stashed in a char* pointer, so it will have to fit. - */ - return res; + pz_enum_err_fmt = (res == name_ct) ? zNoKey : zAmbigKey; + option_usage_fp = stderr; + enumError(pOpts, pOD, paz_names, (int)name_ct); + return name_ct; } @@ -236,7 +234,7 @@ tOptDesc od; od.optArg.argEnum = enum_val; - (*(pOD->pOptProc))( (void*)(2UL), &od ); + (*(pOD->pOptProc))(OPTPROC_RETURN_VALNAME, &od ); return od.optArg.argString; } @@ -273,14 +271,14 @@ * then it is some sort of special request. */ switch ((uintptr_t)pOpts) { - case 0UL: + case (uintptr_t)OPTPROC_EMIT_USAGE: /* * print the list of enumeration names. */ - enumError( pOpts, pOD, paz_names, (int)name_ct ); + enumError(pOpts, pOD, paz_names, (int)name_ct); break; - case 1UL: + case (uintptr_t)OPTPROC_EMIT_SHELL: { unsigned int ix = pOD->optArg.argEnum; /* @@ -294,7 +292,7 @@ break; } - case 2UL: + case (uintptr_t)OPTPROC_RETURN_VALNAME: { tSCC zInval[] = "*INVALID*"; unsigned int ix = pOD->optArg.argEnum; @@ -304,12 +302,12 @@ if (ix >= name_ct) return (uintptr_t)zInval; - res = (uintptr_t)paz_names[ ix ]; + pOD->optArg.argString = paz_names[ix]; break; } default: - res = findName( pOD->optArg.argString, pOpts, pOD, paz_names, name_ct ); + res = findName(pOD->optArg.argString, pOpts, pOD, paz_names, name_ct); if (pOD->fOptState & OPTST_ALLOC_ARG) { AGFREE(pOD->optArg.argString); @@ -350,39 +348,43 @@ * then it is some sort of special request. */ switch ((uintptr_t)pOpts) { - case 0UL: + case (uintptr_t)OPTPROC_EMIT_USAGE: /* * print the list of enumeration names. */ - enumError( pOpts, pOD, paz_names, (int)name_ct ); + enumError(OPTPROC_EMIT_USAGE, pOD, paz_names, (int)name_ct ); return; - case 1UL: + case (uintptr_t)OPTPROC_EMIT_SHELL: { /* * print the name string. */ + int ix = 0; uintptr_t bits = (uintptr_t)pOD->optCookie; - uintptr_t res = 0; size_t len = 0; + bits &= ((uintptr_t)1 << (uintptr_t)name_ct) - (uintptr_t)1; + while (bits != 0) { if (bits & 1) { if (len++ > 0) fputs( " | ", stdout ); - fputs( paz_names[ res ], stdout ); + fputs(paz_names[ix], stdout); } - if (++res >= name_ct) break; + if (++ix >= name_ct) break; bits >>= 1; } return; } - case 2UL: + case (uintptr_t)OPTPROC_RETURN_VALNAME: { char* pz; uintptr_t bits = (uintptr_t)pOD->optCookie; - uintptr_t res = 0; - size_t len = 0; + int ix = 0; + size_t len = 5; + + bits &= ((uintptr_t)1 << (uintptr_t)name_ct) - (uintptr_t)1; /* * Replace the enumeration value with the name string. @@ -390,12 +392,12 @@ */ while (bits != 0) { if (bits & 1) - len += strlen( paz_names[ res ]) + 8; - if (++res >= name_ct) break; + len += strlen( paz_names[ix]) + 8; + if (++ix >= name_ct) break; bits >>= 1; } - pOD->optArg.argString = pz = AGALOC( len, "enum name" ); + pOD->optArg.argString = pz = AGALOC(len, "enum name"); /* * Start by clearing all the bits. We want to turn off any defaults @@ -405,14 +407,16 @@ strcpy( pz, "none" ); pz += 4; bits = (uintptr_t)pOD->optCookie; - res = 0; + bits &= ((uintptr_t)1 << (uintptr_t)name_ct) - (uintptr_t)1; + ix = 0; + while (bits != 0) { if (bits & 1) { strcpy( pz, " + " ); - strcpy( pz+3, paz_names[ res ]); - pz += strlen( paz_names[ res ]) + 3; + strcpy( pz+3, paz_names[ix]); + pz += strlen( paz_names[ix]) + 3; } - if (++res >= name_ct) break; + if (++ix >= name_ct) break; bits >>= 1; } return; @@ -422,6 +426,9 @@ break; } + if ((pOD->fOptState & OPTST_RESET) != 0) + return; + { tCC* pzArg = pOD->optArg.argString; uintptr_t res; @@ -460,6 +467,8 @@ if (pz != pzArg + len) { char z[ AO_NAME_SIZE ]; tCC* p; + int shift_ct; + if (*pz != NUL) { if (len >= AO_NAME_LIMIT) break; @@ -470,7 +479,12 @@ p = pzArg; } - bit = 1UL << findName(p, pOpts, pOD, paz_names, name_ct); + shift_ct = findName(p, pOpts, pOD, paz_names, name_ct); + if (shift_ct >= name_ct) { + pOD->optCookie = (void*)0; + return; + } + bit = 1UL << shift_ct; } if (iv) res &= ~bit; diff -urN src/contrib/ntp/sntp/libopts/environment.c src.ntp/contrib/ntp/sntp/libopts/environment.c --- src/contrib/ntp/sntp/libopts/environment.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/environment.c 2009-12-09 08:36:46.000000000 +0100 @@ -1,59 +1,36 @@ /* - * $Id: environment.c,v 4.13 2007/04/15 19:01:18 bkorb Exp $ - * Time-stamp: "2007-04-15 11:50:35 bkorb" + * $Id: 8700c8e91e8094c455392c691d9b6a7d62222240 $ + * Time-stamp: "2009-07-20 20:12:24 bkorb" * * This file contains all of the routines that must be linked into * an executable to use the generated option processing. The optional * routines are in separately compiled modules so that they will not * necessarily be linked in. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. + * These files have the following md5sums: * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static void checkEnvOpt(tOptState * os, char * env_name, tOptions* pOpts, teEnvPresetType type); @@ -75,15 +52,9 @@ char** sv_argv; /* - * IF there is no such environment variable - * *or* there is, but we are doing immediate opts and there are - * no immediate opts to do (--help inside $PROGNAME is silly, - * but --no-load-defs is not, so that is marked) - * THEN bail out now. ( + * No such beast? Then bail now. */ - if ( (pczOptStr == NULL) - || ( (type == ENV_IMM) - && ((pOpts->fOptSet & OPTPROC_HAS_IMMED) == 0) ) ) + if (pczOptStr == NULL) return; /* @@ -116,27 +87,17 @@ switch (type) { case ENV_IMM: - /* - * We know the OPTPROC_HAS_IMMED bit is set. - */ (void)doImmediateOpts( pOpts ); break; - case ENV_NON_IMM: - (void)doRegularOpts( pOpts ); - break; + case ENV_ALL: + (void)doImmediateOpts( pOpts ); + pOpts->curOptIdx = 1; + pOpts->pzCurOpt = NULL; + /* FALLTHROUGH */ - default: - /* - * Only to immediate opts if the OPTPROC_HAS_IMMED bit is set. - */ - if (pOpts->fOptSet & OPTPROC_HAS_IMMED) { - (void)doImmediateOpts( pOpts ); - pOpts->curOptIdx = 1; - pOpts->pzCurOpt = NULL; - } + case ENV_NON_IMM: (void)doRegularOpts( pOpts ); - break; } /* @@ -263,7 +224,8 @@ /* * Special handling for ${PROGNAME_LOAD_OPTS} */ - if (pOpts->specOptIdx.save_opts != 0) { + if ( (pOpts->specOptIdx.save_opts != NO_EQUIVALENT) + && (pOpts->specOptIdx.save_opts != 0)) { st.pOD = pOpts->pOptDesc + pOpts->specOptIdx.save_opts + 1; strcpy( pzFlagName, st.pOD->pz_NAME ); checkEnvOpt(&st, zEnvName, pOpts, type); diff -urN src/contrib/ntp/sntp/libopts/file.c src.ntp/contrib/ntp/sntp/libopts/file.c --- src/contrib/ntp/sntp/libopts/file.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/libopts/file.c 2009-12-09 08:36:46.000000000 +0100 @@ -0,0 +1,170 @@ + +/* + * $Id: 1410aaa5f08a562e0cd6c28ffae5a49dc7a3164f $ + * Time-stamp: "2009-07-23 17:23:46 bkorb" + * + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd + */ + +/*=export_func optionFileCheck + * private: + * + * what: Decipher a boolean value + * arg: + tOptions* + pOpts + program options descriptor + + * arg: + tOptDesc* + pOptDesc + the descriptor for this arg + + * arg: + teOptFileType + ftype + File handling type + + * arg: + tuFileMode + mode + file open mode (if needed) + + * + * doc: + * Make sure the named file conforms with the file type mode. + * The mode specifies if the file must exist, must not exist or may + * (or may not) exist. The mode may also specify opening the + * file: don't, open just the descriptor (fd), or open as a stream + * (FILE* pointer). +=*/ +void +optionFileCheck(tOptions* pOpts, tOptDesc* pOD, + teOptFileType ftype, tuFileMode mode) +{ + if (pOpts <= OPTPROC_EMIT_LIMIT) { + if (pOpts != OPTPROC_EMIT_USAGE) + return; + + switch (ftype & FTYPE_MODE_EXIST_MASK) { + case FTYPE_MODE_MUST_NOT_EXIST: + fputs(zFileCannotExist, option_usage_fp); + break; + + case FTYPE_MODE_MUST_EXIST: + fputs(zFileMustExist, option_usage_fp); + break; + } + return; + } + + if ((pOD->fOptState & OPTST_RESET) != 0) { + if (pOD->optCookie != NULL) + AGFREE(pOD->optCookie); + return; + } + + { + struct stat sb; + + errno = 0; + + switch (ftype & FTYPE_MODE_EXIST_MASK) { + case FTYPE_MODE_MUST_NOT_EXIST: + if ( (stat(pOD->optArg.argString, &sb) == 0) + || (errno != ENOENT) ){ + if (errno == 0) + errno = EINVAL; + fprintf(stderr, zFSOptError, errno, strerror(errno), + zFSOptErrNoExist, pOD->optArg.argString, pOD->pz_Name); + pOpts->pUsageProc(pOpts, EXIT_FAILURE); + /* NOTREACHED */ + } + /* FALLTHROUGH */ + + default: + case FTYPE_MODE_MAY_EXIST: + { + char * p = strrchr(pOD->optArg.argString, DIRCH); + if (p != NULL) + *p = NUL; + if ( (stat(pOD->optArg.argString, &sb) != 0) + || (errno = EINVAL, ! S_ISDIR(sb.st_mode)) ){ + fprintf(stderr, zFSOptError, errno, strerror(errno), + zFSOptErrMayExist, pOD->optArg.argString, pOD->pz_Name); + pOpts->pUsageProc(pOpts, EXIT_FAILURE); + /* NOTREACHED */ + } + if (p != NULL) + *p = DIRCH; + break; + } + + case FTYPE_MODE_MUST_EXIST: + if ( (stat(pOD->optArg.argString, &sb) != 0) + || (errno = EINVAL, ! S_ISREG(sb.st_mode)) ){ + fprintf(stderr, zFSOptError, errno, strerror(errno), + zFSOptErrMustExist, pOD->optArg.argString, + pOD->pz_Name); + pOpts->pUsageProc(pOpts, EXIT_FAILURE); + /* NOTREACHED */ + } + break; + } + } + + switch (ftype & FTYPE_MODE_OPEN_MASK) { + default: + case FTYPE_MODE_NO_OPEN: + break; + + case FTYPE_MODE_OPEN_FD: + { + int fd = open(pOD->optArg.argString, mode.file_flags); + if (fd < 0) { + fprintf(stderr, zFSOptError, errno, strerror(errno), + zFSOptErrOpen, pOD->optArg.argString, pOD->pz_Name); + pOpts->pUsageProc(pOpts, EXIT_FAILURE); + /* NOTREACHED */ + } + + if ((pOD->fOptState & OPTST_ALLOC_ARG) != 0) + pOD->optCookie = (void *)pOD->optArg.argString; + else + AGDUPSTR(pOD->optCookie, pOD->optArg.argString, "file name"); + + pOD->optArg.argFd = fd; + pOD->fOptState &= ~OPTST_ALLOC_ARG; + break; + } + + case FTYPE_MODE_FOPEN_FP: + { + FILE* fp = fopen(pOD->optArg.argString, mode.file_mode); + if (fp == NULL) { + fprintf(stderr, zFSOptError, errno, strerror(errno), + zFSOptErrFopen, pOD->optArg.argString, pOD->pz_Name); + pOpts->pUsageProc(pOpts, EXIT_FAILURE); + /* NOTREACHED */ + } + + if ((pOD->fOptState & OPTST_ALLOC_ARG) != 0) + pOD->optCookie = (void *)pOD->optArg.argString; + else + AGDUPSTR(pOD->optCookie, pOD->optArg.argString, "file name"); + + pOD->optArg.argFp = fp; + pOD->fOptState &= ~OPTST_ALLOC_ARG; + break; + } + } +} +/* + * Local Variables: + * mode: C + * c-file-style: "stroustrup" + * indent-tabs-mode: nil + * End: + * end of autoopts/file.c */ diff -urN src/contrib/ntp/sntp/libopts/genshell.c src.ntp/contrib/ntp/sntp/libopts/genshell.c --- src/contrib/ntp/sntp/libopts/genshell.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/genshell.c 2009-12-09 08:36:46.000000000 +0100 @@ -2,11 +2,11 @@ * * DO NOT EDIT THIS FILE (genshell.c) * - * It has been AutoGen-ed Saturday May 5, 2007 at 12:02:35 PM PDT + * It has been AutoGen-ed November 8, 2009 at 08:41:09 AM by AutoGen 5.9.10pre13 * From the definitions genshell.def * and the template file options * - * Generated from AutoOpts 29:0:4 templates. + * Generated from AutoOpts @AO_CURRENT@:@AO_REVISION@:@AO_AGE@ templates. */ /* @@ -20,27 +20,26 @@ * * This source file is copyrighted and licensed under the following terms: * - * genshellopt copyright 1999-2007 Bruce Korb - all rights reserved + * genshellopt copyright (c) 1999-2009 Bruce Korb - all rights reserved * - * genshellopt is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. + * genshellopt is free software: you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. * - * genshellopt is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. + * genshellopt is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the GNU General Public License for more details. * - * You should have received a copy of the GNU Lesser General Public - * License along with genshellopt. If not, write to: - * The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor - * Boston, MA 02110-1301, USA. + * You should have received a copy of the GNU General Public License along + * with this program. If not, see . */ - +#include #include +#include +#include #define OPTION_CODE_COMPILE 1 #include "genshell.h" @@ -48,22 +47,22 @@ #ifdef __cplusplus extern "C" { #endif + +/* TRANSLATORS: choose the translation for option names wisely because you + cannot ever change your mind. */ tSCC zCopyright[] = - "genshellopt copyright (c) 1999-2007 Bruce Korb, all rights reserved"; -tSCC zCopyrightNotice[] = - "genshellopt is free software; you can redistribute it and/or\n\ -modify it under the terms of the GNU Lesser General Public\n\ -License as published by the Free Software Foundation; either\n\ -version 2.1 of the License, or (at your option) any later version.\n\n\ -genshellopt is distributed in the hope that it will be useful,\n\ -but WITHOUT ANY WARRANTY; without even the implied warranty of\n\ -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\n\ -Lesser General Public License for more details.\n\n\ -You should have received a copy of the GNU Lesser General Public\n\ -License along with genshellopt. If not, write to:\n\ -\tThe Free Software Foundation, Inc.,\n\ -\t51 Franklin Street, Fifth Floor\n\ -\tBoston, MA 02110-1301, USA."; + "genshellopt copyright (c) 1999-2009 Bruce Korb, all rights reserved"; +tSCC zCopyrightNotice[610] = +"genshellopt is free software: you can redistribute it and/or modify it under\n\ +the terms of the GNU General Public License as published by the Free Software\n\ +Foundation, either version 3 of the License, or (at your option) any later\n\ +version.\n\n\ +genshellopt is distributed in the hope that it will be useful, but WITHOUT ANY\n\ +WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A\n\ +PARTICULAR PURPOSE. See the GNU General Public License for more details.\n\n\ +You should have received a copy of the GNU General Public License along with\n\ +this program. If not, see ."; + extern tUsageProc genshelloptUsage; #ifndef NULL @@ -75,6 +74,7 @@ #ifndef EXIT_FAILURE # define EXIT_FAILURE 1 #endif + /* * Script option description: */ @@ -100,14 +100,26 @@ /* * Help/More_Help/Version option descriptions: */ -tSCC zHelpText[] = "Display usage information and exit"; -tSCC zHelp_Name[] = "help"; - -tSCC zMore_HelpText[] = "Extended usage information passed thru pager"; -tSCC zMore_Help_Name[] = "more-help"; +tSCC zHelpText[] = "Display extended usage information and exit"; +tSCC zHelp_Name[] = "help"; +#ifdef HAVE_WORKING_FORK +#define OPTST_MORE_HELP_FLAGS (OPTST_IMM | OPTST_NO_INIT) +tSCC zMore_Help_Name[] = "more-help"; +tSCC zMore_HelpText[] = "Extended usage information passed thru pager"; +#else +#define OPTST_MORE_HELP_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#define zMore_Help_Name NULL +#define zMore_HelpText NULL +#endif +#ifdef NO_OPTIONAL_OPT_ARGS +# define OPTST_VERSION_FLAGS OPTST_IMM | OPTST_NO_INIT +#else +# define OPTST_VERSION_FLAGS OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ + OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT +#endif -tSCC zVersionText[] = "Output version information and exit"; -tSCC zVersion_Name[] = "version"; +tSCC zVersionText[] = "Output version information and exit"; +tSCC zVersion_Name[] = "version"; /* * Declare option callback procedures */ @@ -145,18 +157,11 @@ /* desc, NAME, name */ zShellText, zShell_NAME, zShell_Name, /* disablement strs */ zNotShell_Name, zNotShell_Pfx }, -#ifdef NO_OPTIONAL_OPT_ARGS -# define VERSION_OPT_FLAGS OPTST_IMM | OPTST_NO_INIT -#else -# define VERSION_OPT_FLAGS OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ - OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT -#endif - { /* entry idx, value */ INDEX_OPT_VERSION, VALUE_OPT_VERSION, /* equiv idx value */ NO_EQUIVALENT, 0, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ VERSION_OPT_FLAGS, 0, + /* opt state flags */ OPTST_VERSION_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, @@ -164,7 +169,6 @@ /* desc, NAME, name */ zVersionText, NULL, zVersion_Name, /* disablement strs */ NULL, NULL }, -#undef VERSION_OPT_FLAGS { /* entry idx, value */ INDEX_OPT_HELP, VALUE_OPT_HELP, @@ -183,7 +187,7 @@ /* equiv idx value */ NO_EQUIVALENT, 0, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, 0, + /* opt state flags */ OPTST_MORE_HELP_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, @@ -213,7 +217,7 @@ text, the second line of the file through the ending tag will be replaced\n\ by the newly generated text. The first `#!' line will be regenerated.\n"; tSCC zFullVersion[] = GENSHELLOPT_FULL_VERSION; -/* extracted from optcode.tpl near line 408 */ +/* extracted from optcode.tpl near line 495 */ #if defined(ENABLE_NLS) # define OPTPROC_BASE OPTPROC_TRANSLATE @@ -223,6 +227,9 @@ # define translate_option_strings NULL #endif /* ENABLE_NLS */ + +#define genshellopt_full_usage NULL +#define genshellopt_short_usage NULL tOptions genshelloptOptions = { OPTIONS_STRUCT_VERSION, 0, NULL, /* original argc + argv */ @@ -245,12 +252,14 @@ /* * Indexes to special options */ - { INDEX_OPT_MORE_HELP, - 0 /* no option state saving */, - NO_EQUIVALENT /* index of '-#' option */, + { INDEX_OPT_MORE_HELP, /* more-help option index */ + NO_EQUIVALENT, /* save option index */ + NO_EQUIVALENT, /* '-#' option index */ NO_EQUIVALENT /* index of default opt */ }, - 5 /* full option count */, 2 /* user option count */ + 5 /* full option count */, 2 /* user option count */, + genshellopt_full_usage, genshellopt_short_usage, + NULL, NULL }; /* @@ -261,9 +270,10 @@ tOptions* pOptions, tOptDesc* pOptDesc ) { + (void)pOptions; USAGE( EXIT_SUCCESS ); } -/* extracted from optcode.tpl near line 514 */ +/* extracted from optcode.tpl near line 627 */ #if ENABLE_NLS #include @@ -306,44 +316,45 @@ * Guard against re-translation. It won't work. The strings will have * been changed by the first pass through this code. One shot only. */ - if (option_usage_text.field_ct == 0) - return; - /* - * Do the translations. The first pointer follows the field count field. - * The field count field is the size of a pointer. - */ - { - char** ppz = (char**)(void*)&(option_usage_text); - int ix = option_usage_text.field_ct; + if (option_usage_text.field_ct != 0) { + + /* + * Do the translations. The first pointer follows the field count + * field. The field count field is the size of a pointer. + */ + tOptDesc* pOD = genshelloptOptions.pOptDesc; + char** ppz = (char**)(void*)&(option_usage_text); + int ix = option_usage_text.field_ct; do { ppz++; *ppz = AO_gettext(*ppz); } while (--ix > 0); + + COERSION(pzCopyright); + COERSION(pzCopyNotice); + COERSION(pzFullVersion); + COERSION(pzUsageTitle); + COERSION(pzExplain); + COERSION(pzDetail); + option_usage_text.field_ct = 0; + + for (ix = genshelloptOptions.optCt; ix > 0; ix--, pOD++) + coerce_it((void*)&(pOD->pzText)); } - option_usage_text.field_ct = 0; - { + if ((genshelloptOptions.fOptSet & OPTPROC_NXLAT_OPT_CFG) == 0) { tOptDesc* pOD = genshelloptOptions.pOptDesc; - int ix = genshelloptOptions.optCt; + int ix; - for (;;) { - pOD->pzText = AO_gettext(pOD->pzText); - pOD->pz_NAME = AO_gettext(pOD->pz_NAME); - pOD->pz_Name = AO_gettext(pOD->pz_Name); - pOD->pz_DisableName = AO_gettext(pOD->pz_DisableName); - pOD->pz_DisablePfx = AO_gettext(pOD->pz_DisablePfx); - if (--ix <= 0) - break; - pOD++; + for (ix = genshelloptOptions.optCt; ix > 0; ix--, pOD++) { + coerce_it((void*)&(pOD->pz_Name)); + coerce_it((void*)&(pOD->pz_DisableName)); + coerce_it((void*)&(pOD->pz_DisablePfx)); } + /* prevent re-translation */ + genshelloptOptions.fOptSet |= OPTPROC_NXLAT_OPT_CFG | OPTPROC_NXLAT_OPT; } - COERSION(pzCopyright); - COERSION(pzCopyNotice); - COERSION(pzFullVersion); - COERSION(pzUsageTitle); - COERSION(pzExplain); - COERSION(pzDetail); } #endif /* ENABLE_NLS */ diff -urN src/contrib/ntp/sntp/libopts/genshell.h src.ntp/contrib/ntp/sntp/libopts/genshell.h --- src/contrib/ntp/sntp/libopts/genshell.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/genshell.h 2009-12-09 08:36:46.000000000 +0100 @@ -2,11 +2,11 @@ * * DO NOT EDIT THIS FILE (genshell.h) * - * It has been AutoGen-ed Saturday May 5, 2007 at 12:02:35 PM PDT + * It has been AutoGen-ed November 8, 2009 at 08:41:09 AM by AutoGen 5.9.10pre13 * From the definitions genshell.def * and the template file options * - * Generated from AutoOpts 29:0:4 templates. + * Generated from AutoOpts @AO_CURRENT@:@AO_REVISION@:@AO_AGE@ templates. */ /* @@ -20,23 +20,20 @@ * * This source file is copyrighted and licensed under the following terms: * - * genshellopt copyright 1999-2007 Bruce Korb - all rights reserved + * genshellopt copyright (c) 1999-2009 Bruce Korb - all rights reserved * - * genshellopt is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. + * genshellopt is free software: you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. * - * genshellopt is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. + * genshellopt is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the GNU General Public License for more details. * - * You should have received a copy of the GNU Lesser General Public - * License along with genshellopt. If not, write to: - * The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor - * Boston, MA 02110-1301, USA. + * You should have received a copy of the GNU General Public License along + * with this program. If not, see . */ /* * This file contains the programmatic interface to the Automated @@ -45,7 +42,7 @@ * "AutoOpts" chapter. Please refer to that doc for usage help. */ #ifndef AUTOOPTS_GENSHELL_H_GUARD -#define AUTOOPTS_GENSHELL_H_GUARD +#define AUTOOPTS_GENSHELL_H_GUARD 1 #include /* @@ -55,7 +52,7 @@ * tolerable version is at least as old as what was current when the header * template was released. */ -#define AO_TEMPLATE_VERSION 118784 +#define AO_TEMPLATE_VERSION 135168 #if (AO_TEMPLATE_VERSION < OPTIONS_MINIMUM_VERSION) \ || (AO_TEMPLATE_VERSION > OPTIONS_STRUCT_VERSION) # error option template version mismatches autoopts/options.h header @@ -66,11 +63,11 @@ * Enumeration of each option: */ typedef enum { - INDEX_OPT_SCRIPT = 0, - INDEX_OPT_SHELL = 1, - INDEX_OPT_VERSION = 2, - INDEX_OPT_HELP = 3, - INDEX_OPT_MORE_HELP = 4 + INDEX_OPT_SCRIPT = 0, + INDEX_OPT_SHELL = 1, + INDEX_OPT_VERSION = 2, + INDEX_OPT_HELP = 3, + INDEX_OPT_MORE_HELP = 4 } teOptIndex; #define OPTION_CT 5 @@ -98,15 +95,15 @@ DESC(n).fOptState |= OPTST_DISABLED; \ DESC(n).optCookie = NULL ) -/* +/* * * * * * + * * Interface defines for specific options. */ #define VALUE_OPT_SCRIPT 'o' #define VALUE_OPT_SHELL 's' - -#define VALUE_OPT_VERSION 'v' #define VALUE_OPT_HELP '?' #define VALUE_OPT_MORE_HELP '!' +#define VALUE_OPT_VERSION 'v' /* * Interface defines not associated with particular options */ @@ -117,7 +114,7 @@ genshelloptOptions.pzCurOpt = NULL ) #define START_OPT RESTART_OPT(1) #define USAGE(c) (*genshelloptOptions.pUsageProc)( &genshelloptOptions, c ) -/* extracted from opthead.tpl near line 360 */ +/* extracted from opthead.tpl near line 409 */ /* * * * * * * @@ -129,18 +126,37 @@ extern tOptions genshelloptOptions; -#ifndef _ -# if ENABLE_NLS -# include - static inline char* aoGetsText( char const* pz ) { - if (pz == NULL) return NULL; - return (char*)gettext( pz ); - } -# define _(s) aoGetsText(s) -# else /* ENABLE_NLS */ -# define _(s) s -# endif /* ENABLE_NLS */ -#endif +#if defined(ENABLE_NLS) +# ifndef _ +# include + static inline char* aoGetsText( char const* pz ) { + if (pz == NULL) return NULL; + return (char*)gettext( pz ); + } +# define _(s) aoGetsText(s) +# endif /* _() */ + +# define OPT_NO_XLAT_CFG_NAMES STMTS(genshelloptOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT_CFG;) +# define OPT_NO_XLAT_OPT_NAMES STMTS(genshelloptOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG;) + +# define OPT_XLAT_CFG_NAMES STMTS(genshelloptOptions.fOptSet &= \ + ~(OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG);) +# define OPT_XLAT_OPT_NAMES STMTS(genshelloptOptions.fOptSet &= \ + ~OPTPROC_NXLAT_OPT;) + +#else /* ENABLE_NLS */ +# define OPT_NO_XLAT_CFG_NAMES +# define OPT_NO_XLAT_OPT_NAMES + +# define OPT_XLAT_CFG_NAMES +# define OPT_XLAT_OPT_NAMES + +# ifndef _ +# define _(_s) _s +# endif +#endif /* ENABLE_NLS */ #ifdef __cplusplus } diff -urN src/contrib/ntp/sntp/libopts/libopts.c src.ntp/contrib/ntp/sntp/libopts/libopts.c --- src/contrib/ntp/sntp/libopts/libopts.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/libopts.c 2009-12-09 08:36:46.000000000 +0100 @@ -4,14 +4,20 @@ #include "autoopts/options.h" #include "autoopts/usage-txt.h" #include "genshell.h" +#include "xat-attribute.h" +#include "value-type.h" +#include "ag-char-map.h" #include "autoopts.h" #include "proto.h" +#include "value-type.c" +#include "xat-attribute.c" #include "autoopts.c" #include "boolean.c" #include "configfile.c" #include "cook.c" #include "enumeration.c" #include "environment.c" +#include "file.c" #include "genshell.c" #include "load.c" #include "makeshell.c" @@ -19,6 +25,7 @@ #include "numeric.c" #include "pgusage.c" #include "putshell.c" +#include "reset.c" #include "restore.c" #include "save.c" #include "sort.c" @@ -26,5 +33,6 @@ #include "streqvcmp.c" #include "text_mmap.c" #include "tokenize.c" +#include "time.c" #include "usage.c" #include "version.c" diff -urN src/contrib/ntp/sntp/libopts/load.c src.ntp/contrib/ntp/sntp/libopts/load.c --- src/contrib/ntp/sntp/libopts/load.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/load.c 2009-12-09 08:36:46.000000000 +0100 @@ -1,60 +1,37 @@ /* - * $Id: load.c,v 4.20 2007/02/04 22:17:39 bkorb Exp $ - * Time-stamp: "2007-02-04 11:54:57 bkorb" + * $Id: f0ececd5fec43bacb417d7b50294accc2121923f $ + * Time-stamp: "2008-12-06 10:16:05 bkorb" * * This file contains the routines that deal with processing text strings * for options, either from a NUL-terminated string passed in or from an * rc/ini file. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ tOptionLoadMode option_load_mode = OPTION_LOAD_UNCOOKED; /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static ag_bool insertProgramPath( char* pzBuf, @@ -86,8 +63,8 @@ * ret-desc: AG_TRUE if the name was handled, otherwise AG_FALSE. * If the name does not start with ``$'', then it is handled * simply by copying the input name to the output buffer and - * resolving the name with either @code{canonicalize_file_name(3GLIBC)} - * or @code{realpath(3C)}. + * resolving the name with either + * @code{canonicalize_file_name(3GLIBC)} or @code{realpath(3C)}. * * doc: * @@ -277,7 +254,7 @@ * allocated and we need to deallocate it. */ if (pzPath != pzProgPath) - free( (void*)pzPath ); + AGFREE(pzPath); return AG_TRUE; } @@ -293,7 +270,7 @@ for (;;) { int ch = (int)*++pzName; - if (! ISNAMECHAR( ch )) + if (! IS_VALUE_NAME_CHAR(ch)) break; *(pzDir++) = (char)ch; } @@ -327,16 +304,16 @@ if (mode == OPTION_LOAD_KEEP) return; - if (isspace( (int)*pzTxt )) { + if (IS_WHITESPACE_CHAR(*pzTxt)) { char* pzS = pzTxt; char* pzD = pzTxt; - while (isspace( (int)*++pzS )) ; + while (IS_WHITESPACE_CHAR(*++pzS)) ; while ((*(pzD++) = *(pzS++)) != NUL) ; pzE = pzD-1; } else pzE = pzTxt + strlen( pzTxt ); - while ((pzE > pzTxt) && isspace( (int)pzE[-1] )) pzE--; + while ((pzE > pzTxt) && IS_WHITESPACE_CHAR(pzE[-1])) pzE--; *pzE = NUL; if (mode == OPTION_LOAD_UNCOOKED) @@ -361,7 +338,7 @@ static char* assembleArgValue( char* pzTxt, tOptionLoadMode mode ) { - tSCC zBrk[] = " \t:="; + tSCC zBrk[] = " \t\n:="; char* pzEnd = strpbrk( pzTxt, zBrk ); int space_break; @@ -386,11 +363,11 @@ * because we'll have to skip over an immediately following ':' or '=' * (and the white space following *that*). */ - space_break = isspace((int)*pzEnd); + space_break = IS_WHITESPACE_CHAR(*pzEnd); *(pzEnd++) = NUL; - while (isspace((int)*pzEnd)) pzEnd++; + while (IS_WHITESPACE_CHAR(*pzEnd)) pzEnd++; if (space_break && ((*pzEnd == ':') || (*pzEnd == '='))) - while (isspace((int)*++pzEnd)) ; + while (IS_WHITESPACE_CHAR(*++pzEnd)) ; return pzEnd; } @@ -410,7 +387,7 @@ tDirection direction, tOptionLoadMode load_mode ) { - while (isspace( (int)*pzLine )) pzLine++; + while (IS_WHITESPACE_CHAR(*pzLine)) pzLine++; { char* pzArg = assembleArgValue( pzLine, load_mode ); diff -urN src/contrib/ntp/sntp/libopts/m4/libopts.m4 src.ntp/contrib/ntp/sntp/libopts/m4/libopts.m4 --- src/contrib/ntp/sntp/libopts/m4/libopts.m4 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/m4/libopts.m4 2009-12-09 08:36:46.000000000 +0100 @@ -2,7 +2,7 @@ dnl dnl DO NOT EDIT THIS FILE (libopts.m4) dnl -dnl It has been AutoGen-ed Saturday May 5, 2007 at 12:02:37 PM PDT +dnl It has been AutoGen-ed November 8, 2009 at 08:41:10 AM by AutoGen 5.9.10pre13 dnl From the definitions libopts.def dnl and the template file conftest.tpl dnl @@ -10,13 +10,7 @@ dnl AC_DEFUN([INVOKE_LIBOPTS_MACROS_FIRST],[ [if test X${INVOKE_LIBOPTS_MACROS_FIRST_done} != Xyes ; then] - # ================= - # AC_HEADER_STDC - # ================= AC_HEADER_STDC - # ================= - # AC_HEADER_DIRENT - # ================= AC_HEADER_DIRENT # ================= @@ -62,19 +56,41 @@ AC_MSG_ERROR([You must have one of limits.h, sys/limits.h or values.h]) fi + # ---------------------------------------------------------------------- + # check for various programs used during the build. + # On OS/X, "wchar.h" needs "runetype.h" to work properly. + # ---------------------------------------------------------------------- + AC_CHECK_HEADERS([runetype.h wchar.h], [], [],[ + AC_INCLUDES_DEFAULT + #if HAVE_RUNETYPE_H + # include + #endif + ]) + + # ---------------------------------------------------------------------- + # Checks for typedefs + # ---------------------------------------------------------------------- + AC_CHECK_TYPES(wchar_t) + AC_CHECK_TYPES(wint_t, [], [], [ + AC_INCLUDES_DEFAULT + #if HAVE_RUNETYPE_H + # include + #endif + #if HAVE_WCHAR_H + # include + #endif + ]) + # ======================== # ...and int types headers # ======================== AC_CHECK_HEADERS(stdint.h inttypes.h, break) AC_CHECK_TYPES([int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, - intptr_t, uint_t]) + intptr_t, uintptr_t, uint_t, pid_t, size_t]) - # ==================== - # uintptr type & sizes - # ==================== - AC_CHECK_TYPES([uintptr_t], , - [AC_DEFINE([uintptr_t], unsigned long, - [Alternate uintptr_t for systems without it.])]) + # ===== + # sizes + # ===== AC_CHECK_SIZEOF(char*, 4) AC_CHECK_SIZEOF(int, 4) AC_CHECK_SIZEOF(long, 4) @@ -85,7 +101,9 @@ # ---------------------------------------------------------------------- AC_CHECK_LIB(gen, pathfind) AC_FUNC_VPRINTF - AC_CHECK_FUNCS([mmap canonicalize_file_name snprintf strdup strchr strrchr]) + AC_FUNC_FORK + AC_CHECK_FUNCS([mmap canonicalize_file_name snprintf strdup strchr \ + strrchr strsignal]) [ INVOKE_LIBOPTS_MACROS_FIRST_done=yes fi]]) @@ -420,14 +438,29 @@ dnl @synopsis LIBOPTS_CHECK dnl -dnl Time-stamp: "2006-09-23 19:36:24 bkorb" -dnl Last Committed: $Date: 2006/09/24 02:59:00 $ +dnl Time-stamp: "2009-07-22 18:50:49 bkorb" dnl dnl If autoopts-config works, add the linking information to LIBS. dnl Otherwise, add ``libopts-${ao_rev}'' to SUBDIRS and run all dnl the config tests that the library needs. Invoke the dnl "INVOKE_LIBOPTS_MACROS" macro iff we are building libopts. dnl +dnl This file is part of AutoGen. +dnl AutoGen copyright (c) 1992-2009 by Bruce Korb - all rights reserved +dnl +dnl AutoGen is free software: you can redistribute it and/or modify it +dnl under the terms of the GNU General Public License as published by the +dnl Free Software Foundation, either version 3 of the License, or +dnl (at your option) any later version. +dnl +dnl AutoGen is distributed in the hope that it will be useful, but +dnl WITHOUT ANY WARRANTY; without even the implied warranty of +dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +dnl See the GNU General Public License for more details. +dnl +dnl You should have received a copy of the GNU General Public License along +dnl with this program. If not, see . +dnl dnl Default to system libopts dnl AC_DEFUN([LIBOPTS_CHECK],[ diff -urN src/contrib/ntp/sntp/libopts/m4/liboptschk.m4 src.ntp/contrib/ntp/sntp/libopts/m4/liboptschk.m4 --- src/contrib/ntp/sntp/libopts/m4/liboptschk.m4 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/m4/liboptschk.m4 2009-12-09 08:36:46.000000000 +0100 @@ -1,11 +1,11 @@ # liboptschk.m4 serial 1 (autogen - 5.7.3) -dnl Copyright (C) 2005 Free Software Foundation, Inc. +dnl copyright (c) 2005-2009 by Bruce Korb - all rights reserved +dnl dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, dnl with or without modifications, as long as this notice is preserved. -dnl Time-stamp: "2006-09-23 19:42:31 bkorb" -dnl Last Committed: $Date: 2006/09/24 02:59:00 $ +dnl Time-stamp: "2009-07-22 18:53:27 bkorb" dnl This file can can be used in projects which are not available under dnl the GNU General Public License or the GNU Library General Public diff -urN src/contrib/ntp/sntp/libopts/makeshell.c src.ntp/contrib/ntp/sntp/libopts/makeshell.c --- src/contrib/ntp/sntp/libopts/makeshell.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/makeshell.c 2009-12-09 08:36:46.000000000 +0100 @@ -1,53 +1,30 @@ /* - * $Id: makeshell.c,v 4.20 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-27 06:05:45 bkorb" + * $Id: 7226344c6486a4eda395f893881080b7d80a2003 $ + * Time-stamp: "2009-11-01 11:52:37 bkorb" * * This module will interpret the options set in the tOptions * structure and create a Bourne shell script capable of parsing them. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ tOptions* pShellParseOptions = NULL; @@ -56,19 +33,19 @@ * * Setup Format Strings */ -tSCC zStartMarker[] = +static char const zStartMarker[] = "# # # # # # # # # # -- do not modify this marker --\n#\n" "# DO NOT EDIT THIS SECTION"; -tSCC zPreamble[] = +static char const zPreamble[] = "%s OF %s\n#\n" "# From here to the next `-- do not modify this marker --',\n" "# the text has been generated %s\n"; -tSCC zEndPreamble[] = +static char const zEndPreamble[] = "# From the %s option definitions\n#\n"; -tSCC zMultiDef[] = "\n" +static char const zMultiDef[] = "\n" "if test -z \"${%1$s_%2$s}\"\n" "then\n" " %1$s_%2$s_CT=0\n" @@ -78,12 +55,12 @@ "fi\n" "export %1$s_%2$s_CT"; -tSCC zSingleDef[] = "\n" +static char const zSingleDef[] = "\n" "%1$s_%2$s=\"${%1$s_%2$s-'%3$s'}\"\n" "%1$s_%2$s_set=false\n" "export %1$s_%2$s\n"; -tSCC zSingleNoDef[] = "\n" +static char const zSingleNoDef[] = "\n" "%1$s_%2$s=\"${%1$s_%2$s}\"\n" "%1$s_%2$s_set=false\n" "export %1$s_%2$s\n"; @@ -96,7 +73,7 @@ * all options are named options (loop only) * regular, marked option processing. */ -tSCC zLoopCase[] = "\n" +static char const zLoopCase[] = "\n" "OPT_PROCESS=true\n" "OPT_ARG=\"$1\"\n\n" "while ${OPT_PROCESS} && [ $# -gt 0 ]\ndo\n" @@ -111,7 +88,7 @@ " shift\n" " ;;\n\n"; -tSCC zLoopOnly[] = "\n" +static char const zLoopOnly[] = "\n" "OPT_ARG=\"$1\"\n\n" "while [ $# -gt 0 ]\ndo\n" " OPT_ELEMENT=''\n" @@ -126,16 +103,16 @@ * then we must have selectors for each acceptable option * type (long option, flag character and non-option) */ -tSCC zLongSelection[] = +static char const zLongSelection[] = " --* )\n"; -tSCC zFlagSelection[] = +static char const zFlagSelection[] = " -* )\n"; -tSCC zEndSelection[] = +static char const zEndSelection[] = " ;;\n\n"; -tSCC zNoSelection[] = +static char const zNoSelection[] = " * )\n" " OPT_PROCESS=false\n" " ;;\n" @@ -145,7 +122,7 @@ * * LOOP END */ -tSCC zLoopEnd[] = +static char const zLoopEnd[] = " if [ -n \"${OPT_ARG_VAL}\" ]\n" " then\n" " eval %1$s_${OPT_NAME}${OPT_ELEMENT}=\"'${OPT_ARG_VAL}'\"\n" @@ -160,7 +137,7 @@ "unset OPT_CODE || :\n" "unset OPT_ARG_VAL || :\n%2$s"; -tSCC zTrailerMarker[] = "\n" +static char const zTrailerMarker[] = "\n" "# # # # # # # # # #\n#\n" "# END OF AUTOMATED OPTION PROCESSING\n" "#\n# # # # # # # # # # -- do not modify this marker --\n"; @@ -169,22 +146,22 @@ * * OPTION SELECTION */ -tSCC zOptionCase[] = +static char const zOptionCase[] = " case \"${OPT_CODE}\" in\n"; -tSCC zOptionPartName[] = +static char const zOptionPartName[] = " '%s' | \\\n"; -tSCC zOptionFullName[] = +static char const zOptionFullName[] = " '%s' )\n"; -tSCC zOptionFlag[] = +static char const zOptionFlag[] = " '%c' )\n"; -tSCC zOptionEndSelect[] = +static char const zOptionEndSelect[] = " ;;\n\n"; -tSCC zOptionUnknown[] = +static char const zOptionUnknown[] = " * )\n" " echo Unknown %s: \"${OPT_CODE}\" >&2\n" " echo \"$%s_USAGE_TEXT\"\n" @@ -198,29 +175,29 @@ * * Formats for emitting the text for handling particular options */ -tSCC zTextExit[] = +static char const zTextExit[] = " echo \"$%s_%s_TEXT\"\n" " exit 0\n"; -tSCC zPagedUsageExit[] = +static char const zPagedUsageExit[] = " echo \"$%s_LONGUSAGE_TEXT\" | ${PAGER-more}\n" " exit 0\n"; -tSCC zCmdFmt[] = +static char const zCmdFmt[] = " %s\n"; -tSCC zCountTest[] = +static char const zCountTest[] = " if [ $%1$s_%2$s_CT -ge %3$d ] ; then\n" " echo Error: more than %3$d %2$s options >&2\n" " echo \"$%1$s_USAGE_TEXT\"\n" " exit 1 ; fi\n"; -tSCC zMultiArg[] = +static char const zMultiArg[] = " %1$s_%2$s_CT=`expr ${%1$s_%2$s_CT} + 1`\n" " OPT_ELEMENT=\"_${%1$s_%2$s_CT}\"\n" " OPT_NAME='%2$s'\n"; -tSCC zSingleArg[] = +static char const zSingleArg[] = " if [ -n \"${%1$s_%2$s}\" ] && ${%1$s_%2$s_set} ; then\n" " echo Error: duplicate %2$s option >&2\n" " echo \"$%1$s_USAGE_TEXT\"\n" @@ -228,14 +205,14 @@ " %1$s_%2$s_set=true\n" " OPT_NAME='%2$s'\n"; -tSCC zNoMultiArg[] = +static char const zNoMultiArg[] = " %1$s_%2$s_CT=0\n" " OPT_ELEMENT=''\n" " %1$s_%2$s='%3$s'\n" " export %1$s_%2$s\n" " OPT_NAME='%2$s'\n"; -tSCC zNoSingleArg[] = +static char const zNoSingleArg[] = " if [ -n \"${%1$s_%2$s}\" ] && ${%1$s_%2$s_set} ; then\n" " echo Error: duplicate %2$s option >&2\n" " echo \"$%1$s_USAGE_TEXT\"\n" @@ -245,15 +222,15 @@ " export %1$s_%2$s\n" " OPT_NAME='%2$s'\n"; -tSCC zMayArg[] = +static char const zMayArg[] = " eval %1$s_%2$s${OPT_ELEMENT}=true\n" " export %1$s_%2$s${OPT_ELEMENT}\n" " OPT_ARG_NEEDED=OK\n"; -tSCC zMustArg[] = +static char const zMustArg[] = " OPT_ARG_NEEDED=YES\n"; -tSCC zCantArg[] = +static char const zCantArg[] = " eval %1$s_%2$s${OPT_ELEMENT}=true\n" " export %1$s_%2$s${OPT_ELEMENT}\n" " OPT_ARG_NEEDED=NO\n"; @@ -264,7 +241,7 @@ * * Formats for emitting the text for handling long option types */ -tSCC zLongOptInit[] = +static char const zLongOptInit[] = " OPT_CODE=`echo \"X${OPT_ARG}\"|sed 's/^X-*//'`\n" " shift\n" " OPT_ARG=\"$1\"\n\n" @@ -272,7 +249,7 @@ " OPT_ARG_VAL=`echo \"${OPT_CODE}\"|sed 's/^[^=]*=//'`\n" " OPT_CODE=`echo \"${OPT_CODE}\"|sed 's/=.*$//'` ;; esac\n\n"; -tSCC zLongOptArg[] = +static char const zLongOptArg[] = " case \"${OPT_ARG_NEEDED}\" in\n" " NO )\n" " OPT_ARG_VAL=''\n" @@ -308,11 +285,11 @@ * * Formats for emitting the text for handling flag option types */ -tSCC zFlagOptInit[] = +static char const zFlagOptInit[] = " OPT_CODE=`echo \"X${OPT_ARG}\" | sed 's/X-\\(.\\).*/\\1/'`\n" " OPT_ARG=` echo \"X${OPT_ARG}\" | sed 's/X-.//'`\n\n"; -tSCC zFlagOptArg[] = +static char const zFlagOptArg[] = " case \"${OPT_ARG_NEEDED}\" in\n" " NO )\n" " if [ -n \"${OPT_ARG}\" ]\n" @@ -364,7 +341,7 @@ static char* pzTrailer = NULL; /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static void textToVariable( tOptions* pOpts, teTextTo whichVar, tOptDesc* pOD ); @@ -506,7 +483,7 @@ static char const* apzTTNames[] = { TEXTTO_TABLE }; # undef _TT_ -#if defined(__windows__) && !defined(__CYGWIN__) +#if ! defined(HAVE_WORKING_FORK) printf( "%1$s_%2$s_TEXT='no %2$s text'\n", pOpts->pzPROGNAME, apzTTNames[ whichVar ]); #else @@ -695,7 +672,7 @@ */ switch (OPTST_GET_ARGTYPE(pOptDesc->fOptState)) { case OPARG_TYPE_ENUMERATION: - (*(pOptDesc->pOptProc))( (tOptions*)2UL, pOptDesc ); + (*(pOptDesc->pOptProc))(OPTPROC_EMIT_SHELL, pOptDesc ); pzDefault = pOptDesc->optArg.argString; break; @@ -815,7 +792,7 @@ if (SKIP_OPT(pOptDesc)) continue; - if (isprint( pOptDesc->optValue )) { + if (IS_GRAPHIC_CHAR(pOptDesc->optValue)) { printf( zOptionFlag, pOptDesc->optValue ); printOptionAction( pOpts, pOptDesc ); } @@ -1036,7 +1013,7 @@ void genshelloptUsage( tOptions* pOpts, int exitCode ) { -#if defined(__windows__) && !defined(__CYGWIN__) +#if ! defined(HAVE_WORKING_FORK) optionUsage( pOpts, exitCode ); #else /* @@ -1056,13 +1033,13 @@ switch (fork()) { case -1: optionUsage( pOpts, EXIT_FAILURE ); - /*NOTREACHED*/ + /* NOTREACHED */ _exit( EXIT_FAILURE ); case 0: pagerState = PAGER_STATE_CHILD; optionUsage( pOpts, EXIT_SUCCESS ); - /*NOTREACHED*/ + /* NOTREACHED */ _exit( EXIT_FAILURE ); default: diff -urN src/contrib/ntp/sntp/libopts/nested.c src.ntp/contrib/ntp/sntp/libopts/nested.c --- src/contrib/ntp/sntp/libopts/nested.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/nested.c 2009-12-09 08:36:46.000000000 +0100 @@ -1,57 +1,49 @@ /* - * $Id: nested.c,v 4.14 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-26 11:04:35 bkorb" + * $Id: 43877d3ade0b626b4bec87f2f340a8358c118333 $ + * Time-stamp: "2008-07-28 19:18:28 bkorb" * * Automated Options Nested Values module. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd + */ + +typedef struct { + int xml_ch; + int xml_len; + char xml_txt[8]; +} xml_xlate_t; + +static xml_xlate_t const xml_xlate[] = { + { '&', 4, "amp;" }, + { '<', 3, "lt;" }, + { '>', 3, "gt;" }, + { '"', 5, "quot;" }, + { '\'',5, "apos;" } +}; + /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static void -removeBackslashes( char* pzSrc ); +removeLineContinue( char* pzSrc ); static char const* scanQuotedString( char const* pzTxt ); @@ -85,27 +77,42 @@ sortNestedList( tArgList* pAL ); /* = = = END-STATIC-FORWARD = = = */ -/* removeBackslashes +/* removeLineContinue * - * This function assumes that all newline characters were preceeded by - * backslashes that need removal. + * Backslashes are used for line continuations. We keep the newline + * characters, but trim out the backslash: */ static void -removeBackslashes( char* pzSrc ) +removeLineContinue( char* pzSrc ) { - char* pzD = strchr(pzSrc, '\n'); + char* pzD; - if (pzD == NULL) - return; - *--pzD = '\n'; + do { + while (*pzSrc == '\n') pzSrc++; + pzD = strchr(pzSrc, '\n'); + if (pzD == NULL) + return; + + /* + * pzD has skipped at least one non-newline character and now + * points to a newline character. It now becomes the source and + * pzD goes to the previous character. + */ + pzSrc = pzD--; + if (*pzD != '\\') + pzD++; + } while (pzD == pzSrc); + /* + * Start shifting text. + */ for (;;) { char ch = ((*pzD++) = *(pzSrc++)); switch (ch) { - case '\n': *--pzD = ch; break; case NUL: return; - default: - ; + case '\\': + if (*pzSrc == '\n') + --pzD; /* rewrite on next iteration */ } } } @@ -170,9 +177,24 @@ } else { pNV->valType = OPARG_TYPE_STRING; - if (dataLen > 0) - memcpy( pNV->v.strVal, pzValue, dataLen ); - pNV->v.strVal[dataLen] = NUL; + if (dataLen > 0) { + char const * pzSrc = pzValue; + char * pzDst = pNV->v.strVal; + int ct = dataLen; + do { + int ch = *(pzSrc++) & 0xFF; + if (ch == NUL) goto data_copy_done; + if (ch == '&') + ch = get_special_char(&pzSrc, &ct); + *(pzDst++) = ch; + } while (--ct > 0); + data_copy_done: + *pzDst = NUL; + + } else { + pNV->v.strVal[0] = NUL; + } + pNV->pzName = pNV->v.strVal + dataLen + 1; } @@ -197,22 +219,16 @@ pNV = AGALOC( sz, "option name/bool value pair" ); if (pNV == NULL) return NULL; - while (isspace( (int)*pzValue ) && (dataLen > 0)) { + while (IS_WHITESPACE_CHAR(*pzValue) && (dataLen > 0)) { dataLen--; pzValue++; } if (dataLen == 0) pNV->v.boolVal = 0; - else if (isdigit( (int)*pzValue )) - pNV->v.boolVal = atoi( pzValue ); - else switch (*pzValue) { - case 'f': - case 'F': - case 'n': - case 'N': - pNV->v.boolVal = 0; break; - default: - pNV->v.boolVal = 1; - } + + else if (IS_DEC_DIGIT_CHAR(*pzValue)) + pNV->v.boolVal = atoi(pzValue); + + else pNV->v.boolVal = ! IS_FALSE_TYPE_CHAR(*pzValue); pNV->valType = OPARG_TYPE_BOOLEAN; pNV->pzName = (char*)(pNV + 1); @@ -237,16 +253,16 @@ pNV = AGALOC( sz, "option name/bool value pair" ); if (pNV == NULL) return NULL; - while (isspace( (int)*pzValue ) && (dataLen > 0)) { + while (IS_WHITESPACE_CHAR(*pzValue) && (dataLen > 0)) { dataLen--; pzValue++; } if (dataLen == 0) - pNV->v.boolVal = 0; + pNV->v.longVal = 0; else - pNV->v.boolVal = atoi( pzValue ); + pNV->v.longVal = strtol(pzValue, 0, 0); pNV->valType = OPARG_TYPE_NUMERIC; - pNV->pzName = (char*)(pNV + 1); + pNV->pzName = (char*)(pNV + 1); memcpy( pNV->pzName, pzName, nameLen ); pNV->pzName[ nameLen ] = NUL; addArgListEntry( pp, pNV ); @@ -295,46 +311,39 @@ scanNameEntry(char const* pzName, tOptionValue* pRes) { tOptionValue* pNV; - char const * pzScan = pzName+1; + char const * pzScan = pzName+1; /* we know first char is a name char */ char const * pzVal; size_t nameLen = 1; size_t dataLen = 0; - while (ISNAMECHAR( (int)*pzScan )) { pzScan++; nameLen++; } - - while (isspace( (int)*pzScan )) { - char ch = *(pzScan++); - if ((ch == '\n') || (ch == ',')) { - addStringValue(&(pRes->v.nestVal), pzName, nameLen, NULL,(size_t)0); - return pzScan - 1; - } - } + /* + * Scan over characters that name a value. These names may not end + * with a colon, but they may contain colons. + */ + while (IS_VALUE_NAME_CHAR(*pzScan)) { pzScan++; nameLen++; } + if (pzScan[-1] == ':') { pzScan--; nameLen--; } + while (IS_HORIZ_WHITE_CHAR(*pzScan)) pzScan++; +re_switch: switch (*pzScan) { case '=': case ':': - while (isspace( (int)*++pzScan )) ; - switch (*pzScan) { - case ',': goto comma_char; - case '"': - case '\'': goto quote_char; - case NUL: goto nul_byte; - default: goto default_char; - } + while (IS_HORIZ_WHITE_CHAR( (int)*++pzScan )) ; + if ((*pzScan == '=') || (*pzScan == ':')) + goto default_char; + goto re_switch; + case '\n': case ',': - comma_char: pzScan++; /* FALLTHROUGH */ case NUL: - nul_byte: addStringValue(&(pRes->v.nestVal), pzName, nameLen, NULL, (size_t)0); break; case '"': case '\'': - quote_char: pzVal = pzScan; pzScan = scanQuotedString( pzScan ); dataLen = pzScan - pzVal; @@ -373,7 +382,7 @@ pNV = addStringValue( &(pRes->v.nestVal), pzName, nameLen, pzVal, dataLen ); if (pNV != NULL) - removeBackslashes( pNV->v.strVal ); + removeLineContinue( pNV->v.strVal ); goto leave_scan_name; } } @@ -400,7 +409,7 @@ tOptionValue* pNewVal; tOptionLoadMode save_mode = option_load_mode; - if (! isalpha((int)*pzName)) { + if (! IS_VAR_FIRST_CHAR(*pzName)) { switch (*pzName) { default: pzName = NULL; @@ -421,7 +430,8 @@ return pzName; } - while (isalpha( (int)*++pzScan )) nameLen++; + pzScan++; + while (IS_VALUE_NAME_CHAR( (int)*pzScan )) { pzScan++; nameLen++; } if (nameLen > 64) return NULL; valu.valType = OPARG_TYPE_STRING; @@ -449,7 +459,7 @@ } addStringValue(&(pRes->v.nestVal), pzName, nameLen, NULL, (size_t)0); option_load_mode = save_mode; - return pzScan+2; + return pzScan+1; default: option_load_mode = save_mode; @@ -484,7 +494,7 @@ } valLen = (pzScan - pzVal); pzScan += nameLen + 3; - while (isspace( (int)*pzScan )) pzScan++; + while (IS_WHITESPACE_CHAR(*pzScan)) pzScan++; } switch (valu.valType) { @@ -651,7 +661,7 @@ errno = EINVAL; return NULL; } - while (isspace( (int)*pzTxt )) pzTxt++; + while (IS_WHITESPACE_CHAR(*pzTxt)) pzTxt++; if (*pzTxt == NUL) { errno = ENOENT; return NULL; @@ -679,13 +689,14 @@ * Scan until we hit a NUL. */ do { - while (isspace( (int)*pzTxt )) pzTxt++; - if (isalpha( (int)*pzTxt )) { + while (IS_WHITESPACE_CHAR( (int)*pzTxt )) pzTxt++; + if (IS_VAR_FIRST_CHAR( (int)*pzTxt )) { pzTxt = scanNameEntry( pzTxt, pRes ); } else switch (*pzTxt) { case NUL: goto scan_done; case '<': pzTxt = scanXmlEntry( pzTxt, pRes ); + if (pzTxt == NULL) goto woops; if (*pzTxt == ',') pzTxt++; break; case '#': pzTxt = strchr( pzTxt, '\n' ); break; default: goto woops; @@ -716,14 +727,113 @@ * Nested value was found on the command line =*/ void -optionNestedVal( tOptions* pOpts, tOptDesc* pOD ) +optionNestedVal(tOptions* pOpts, tOptDesc* pOD) +{ + if (pOpts < OPTPROC_EMIT_LIMIT) + return; + + if (pOD->fOptState & OPTST_RESET) { + tArgList* pAL = pOD->optCookie; + int ct; + tCC ** av; + + if (pAL == NULL) + return; + ct = pAL->useCt; + av = pAL->apzArgs; + + while (--ct >= 0) { + void * p = (void *)*(av++); + optionUnloadNested((tOptionValue const *)p); + } + + AGFREE(pOD->optCookie); + + } else { + tOptionValue* pOV = optionLoadNested( + pOD->optArg.argString, pOD->pz_Name, strlen(pOD->pz_Name)); + + if (pOV != NULL) + addArgListEntry( &(pOD->optCookie), (void*)pOV ); + } +} + + +/* + * get_special_char + */ +LOCAL int +get_special_char(char const ** ppz, int * ct) +{ + char const * pz = *ppz; + + if (*ct < 3) + return '&'; + + if (*pz == '#') { + int base = 10; + int retch; + + pz++; + if (*pz == 'x') { + base = 16; + pz++; + } + retch = (int)strtoul(pz, (char **)&pz, base); + if (*pz != ';') + return '&'; + base = ++pz - *ppz; + if (base > *ct) + return '&'; + + *ct -= base; + *ppz = pz; + return retch; + } + + { + int ctr = sizeof(xml_xlate) / sizeof(xml_xlate[0]); + xml_xlate_t const * xlatp = xml_xlate; + + for (;;) { + if ( (*ct >= xlatp->xml_len) + && (strncmp(pz, xlatp->xml_txt, xlatp->xml_len) == 0)) { + *ppz += xlatp->xml_len; + *ct -= xlatp->xml_len; + return xlatp->xml_ch; + } + + if (--ctr <= 0) + break; + xlatp++; + } + } + return '&'; +} + + +/* + * emit_special_char + */ +LOCAL void +emit_special_char(FILE * fp, int ch) { - tOptionValue* pOV = optionLoadNested( - pOD->optArg.argString, pOD->pz_Name, strlen(pOD->pz_Name)); + int ctr = sizeof(xml_xlate) / sizeof(xml_xlate[0]); + xml_xlate_t const * xlatp = xml_xlate; - if (pOV != NULL) - addArgListEntry( &(pOD->optCookie), (void*)pOV ); + putc('&', fp); + for (;;) { + if (ch == xlatp->xml_ch) { + fputs(xlatp->xml_txt, fp); + return; + } + if (--ctr <= 0) + break; + xlatp++; + } + fprintf(fp, "#x%02X;", (ch & 0xFF)); } + /* * Local Variables: * mode: C diff -urN src/contrib/ntp/sntp/libopts/numeric.c src.ntp/contrib/ntp/sntp/libopts/numeric.c --- src/contrib/ntp/sntp/libopts/numeric.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/numeric.c 2009-12-09 08:36:46.000000000 +0100 @@ -1,56 +1,108 @@ /* - * $Id: numeric.c,v 4.11 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-13 10:28:20 bkorb" + * $Id: 52d772d69bed7f2911d88ff17b9a44308d6ca0b1 $ + * Time-stamp: "2009-07-23 17:25:39 bkorb" + * + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ -/* - * Automated Options copyright 1992-2007 Bruce Korb +/*=export_func optionShowRange + * private: * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ + * what: + * arg: + tOptions* + pOpts + program options descriptor + + * arg: + tOptDesc* + pOptDesc + the descriptor for this arg + + * arg: + void * + rng_table + the value range tables + + * arg: + int + rng_count + the number of entries + + * + * doc: + * Show information about a numeric option with range constraints. +=*/ +void +optionShowRange(tOptions* pOpts, tOptDesc* pOD, void * rng_table, int rng_ct) +{ + static char const bullet[] = "\t\t\t\t- "; + static char const deepin[] = "\t\t\t\t "; + static char const onetab[] = "\t"; + + const struct {long const rmin, rmax;} * rng = rng_table; + + char const * pz_indent = + (pOpts != OPTPROC_EMIT_USAGE) ? onetab : bullet; + + if ((pOpts == OPTPROC_EMIT_USAGE) || (pOpts > OPTPROC_EMIT_LIMIT)) { + char const * lie_in_range = zRangeLie; + + if (pOpts > OPTPROC_EMIT_LIMIT) { + fprintf(option_usage_fp, zRangeErr, + pOpts->pzProgName, pOD->pz_Name, pOD->optArg.argString); + fprintf(option_usage_fp, "The %s option:\n", pOD->pz_Name); + lie_in_range = zRangeBadLie; + pz_indent = ""; + } + + if (pOD->fOptState & OPTST_SCALED_NUM) + fprintf(option_usage_fp, zRangeScaled, pz_indent); + + if (rng_ct > 1) { + fprintf(option_usage_fp, lie_in_range, pz_indent); + pz_indent = + (pOpts != OPTPROC_EMIT_USAGE) ? onetab : deepin; + + } else { + fprintf(option_usage_fp, zRangeOnly, pz_indent); + pz_indent = onetab + 1; /* empty string */ + } + + for (;;) { + if (rng->rmax == LONG_MIN) + fprintf(option_usage_fp, zRangeExact, pz_indent, rng->rmin); + else if (rng->rmin == LONG_MIN) + fprintf(option_usage_fp, zRangeUpto, pz_indent, rng->rmax); + else if (rng->rmax == LONG_MAX) + fprintf(option_usage_fp, zRangeAbove, pz_indent, rng->rmin); + else + fprintf(option_usage_fp, zRange, pz_indent, rng->rmin, + rng->rmax); + + if (--rng_ct <= 0) { + fputc('\n', option_usage_fp); + break; + } + fputs(zRangeOr, option_usage_fp); + rng++; + pz_indent = + (pOpts != OPTPROC_EMIT_USAGE) ? onetab : deepin; + } + + if (pOpts > OPTPROC_EMIT_LIMIT) + pOpts->pUsageProc(pOpts, EXIT_FAILURE); + } +} + /*=export_func optionNumericVal * private: * - * what: Decipher a boolean value + * what: process an option with a numeric value. * arg: + tOptions* + pOpts + program options descriptor + * arg: + tOptDesc* + pOptDesc + the descriptor for this arg + * @@ -58,7 +110,7 @@ * Decipher a numeric value. =*/ void -optionNumericVal( tOptions* pOpts, tOptDesc* pOD ) +optionNumericVal(tOptions* pOpts, tOptDesc* pOD ) { char* pz; long val; @@ -66,16 +118,37 @@ /* * Numeric options may have a range associated with it. * If it does, the usage procedure requests that it be - * emitted by passing a NULL pOD pointer. + * emitted by passing a NULL pOD pointer. Also bail out + * if there is no option argument or if we are being reset. */ - if ((pOD == NULL) || (pOD->optArg.argString == NULL)) + if ( (pOD == NULL) + || (pOD->optArg.argString == NULL) + || ((pOD->fOptState & OPTST_RESET) != 0)) return; - val = strtol( pOD->optArg.argString, &pz, 0 ); - if (*pz != NUL) { - fprintf( stderr, zNotNumber, pOpts->pzProgName, pOD->optArg.argString ); - (*(pOpts->pUsageProc))(pOpts, EXIT_FAILURE); - } + errno = 0; + val = strtol(pOD->optArg.argString, &pz, 0); + if ((pz == pOD->optArg.argString) || (errno != 0)) + goto bad_number; + + if ((pOD->fOptState & OPTST_SCALED_NUM) != 0) + switch (*(pz++)) { + case '\0': pz--; break; + case 't': val *= 1000; + case 'g': val *= 1000; + case 'm': val *= 1000; + case 'k': val *= 1000; break; + + case 'T': val *= 1024; + case 'G': val *= 1024; + case 'M': val *= 1024; + case 'K': val *= 1024; break; + + default: goto bad_number; + } + + if (*pz != NUL) + goto bad_number; if (pOD->fOptState & OPTST_ALLOC_ARG) { AGFREE(pOD->optArg.argString); @@ -83,7 +156,17 @@ } pOD->optArg.argInt = val; + return; + + bad_number: + + fprintf( stderr, zNotNumber, pOpts->pzProgName, pOD->optArg.argString ); + if ((pOpts->fOptSet & OPTPROC_ERRSTOP) != 0) + (*(pOpts->pUsageProc))(pOpts, EXIT_FAILURE); + + pOD->optArg.argInt = ~0; } + /* * Local Variables: * mode: C diff -urN src/contrib/ntp/sntp/libopts/parse-duration.c src.ntp/contrib/ntp/sntp/libopts/parse-duration.c --- src/contrib/ntp/sntp/libopts/parse-duration.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/libopts/parse-duration.c 2009-12-09 08:36:46.000000000 +0100 @@ -0,0 +1,582 @@ +/* Parse a time duration and return a seconds count + Copyright (C) 2008 Free Software Foundation, Inc. + Written by Bruce Korb , 2008. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . */ + +#include + +#include +#include +#include +#include +#include +#include + +#include "parse-duration.h" + +#ifndef _ +#define _(_s) _s +#endif + +#ifndef NUL +#define NUL '\0' +#endif + +#define cch_t char const + +typedef enum { + NOTHING_IS_DONE, + YEAR_IS_DONE, + MONTH_IS_DONE, + WEEK_IS_DONE, + DAY_IS_DONE, + HOUR_IS_DONE, + MINUTE_IS_DONE, + SECOND_IS_DONE +} whats_done_t; + +#define SEC_PER_MIN 60 +#define SEC_PER_HR (SEC_PER_MIN * 60) +#define SEC_PER_DAY (SEC_PER_HR * 24) +#define SEC_PER_WEEK (SEC_PER_DAY * 7) +#define SEC_PER_MONTH (SEC_PER_DAY * 30) +#define SEC_PER_YEAR (SEC_PER_DAY * 365) + +#define TIME_MAX 0x7FFFFFFF + +static unsigned long inline +str_const_to_ul (cch_t * str, cch_t ** ppz, int base) +{ + return strtoul (str, (char **)ppz, base); +} + +static long inline +str_const_to_l (cch_t * str, cch_t ** ppz, int base) +{ + return strtol (str, (char **)ppz, base); +} + +static time_t inline +scale_n_add (time_t base, time_t val, int scale) +{ + if (base == BAD_TIME) + { + if (errno == 0) + errno = EINVAL; + return BAD_TIME; + } + + if (val > TIME_MAX / scale) + { + errno = ERANGE; + return BAD_TIME; + } + + val *= scale; + if (base > TIME_MAX - val) + { + errno = ERANGE; + return BAD_TIME; + } + + return base + val; +} + +static time_t +parse_hr_min_sec (time_t start, cch_t * pz) +{ + int lpct = 0; + + errno = 0; + + /* For as long as our scanner pointer points to a colon *AND* + we've not looped before, then keep looping. (two iterations max) */ + while ((*pz == ':') && (lpct++ <= 1)) + { + unsigned long v = str_const_to_ul (pz+1, &pz, 10); + + if (errno != 0) + return BAD_TIME; + + start = scale_n_add (v, start, 60); + + if (errno != 0) + return BAD_TIME; + } + + /* allow for trailing spaces */ + while (isspace ((unsigned char)*pz)) pz++; + if (*pz != NUL) + { + errno = EINVAL; + return BAD_TIME; + } + + return start; +} + +static time_t +parse_scaled_value (time_t base, cch_t ** ppz, cch_t * endp, int scale) +{ + cch_t * pz = *ppz; + time_t val; + + if (base == BAD_TIME) + return base; + + errno = 0; + val = str_const_to_ul (pz, &pz, 10); + if (errno != 0) + return BAD_TIME; + while (isspace ((unsigned char)*pz)) pz++; + if (pz != endp) + { + errno = EINVAL; + return BAD_TIME; + } + + *ppz = pz; + return scale_n_add (base, val, scale); +} + +static time_t +parse_year_month_day (cch_t * pz, cch_t * ps) +{ + time_t res = 0; + + res = parse_scaled_value (0, &pz, ps, SEC_PER_YEAR); + + ps = strchr (++pz, '-'); + if (ps == NULL) + { + errno = EINVAL; + return BAD_TIME; + } + res = parse_scaled_value (res, &pz, ps, SEC_PER_MONTH); + + pz++; + ps = pz + strlen (pz); + return parse_scaled_value (res, &pz, ps, SEC_PER_DAY); +} + +static time_t +parse_yearmonthday (cch_t * in_pz) +{ + time_t res = 0; + char buf[8]; + cch_t * pz; + + if (strlen (in_pz) != 8) + { + errno = EINVAL; + return BAD_TIME; + } + + memcpy (buf, in_pz, 4); + buf[4] = NUL; + pz = buf; + res = parse_scaled_value (0, &pz, buf + 4, SEC_PER_YEAR); + + memcpy (buf, in_pz + 4, 2); + buf[2] = NUL; + pz = buf; + res = parse_scaled_value (res, &pz, buf + 2, SEC_PER_MONTH); + + memcpy (buf, in_pz + 6, 2); + buf[2] = NUL; + pz = buf; + return parse_scaled_value (res, &pz, buf + 2, SEC_PER_DAY); +} + +static time_t +parse_YMWD (cch_t * pz) +{ + time_t res = 0; + cch_t * ps = strchr (pz, 'Y'); + if (ps != NULL) + { + res = parse_scaled_value (0, &pz, ps, SEC_PER_YEAR); + pz++; + } + + ps = strchr (pz, 'M'); + if (ps != NULL) + { + res = parse_scaled_value (res, &pz, ps, SEC_PER_MONTH); + pz++; + } + + ps = strchr (pz, 'W'); + if (ps != NULL) + { + res = parse_scaled_value (res, &pz, ps, SEC_PER_WEEK); + pz++; + } + + ps = strchr (pz, 'D'); + if (ps != NULL) + { + res = parse_scaled_value (res, &pz, ps, SEC_PER_DAY); + pz++; + } + + while (isspace ((unsigned char)*pz)) pz++; + if (*pz != NUL) + { + errno = EINVAL; + return BAD_TIME; + } + + return res; +} + +static time_t +parse_hour_minute_second (cch_t * pz, cch_t * ps) +{ + time_t res = 0; + + res = parse_scaled_value (0, &pz, ps, SEC_PER_HR); + + ps = strchr (++pz, ':'); + if (ps == NULL) + { + errno = EINVAL; + return BAD_TIME; + } + + res = parse_scaled_value (res, &pz, ps, SEC_PER_MIN); + + pz++; + ps = pz + strlen (pz); + return parse_scaled_value (res, &pz, ps, 1); +} + +static time_t +parse_hourminutesecond (cch_t * in_pz) +{ + time_t res = 0; + char buf[4]; + cch_t * pz; + + if (strlen (in_pz) != 6) + { + errno = EINVAL; + return BAD_TIME; + } + + memcpy (buf, in_pz, 2); + buf[2] = NUL; + pz = buf; + res = parse_scaled_value (0, &pz, buf + 2, SEC_PER_HR); + + memcpy (buf, in_pz + 2, 2); + buf[2] = NUL; + pz = buf; + res = parse_scaled_value (res, &pz, buf + 2, SEC_PER_MIN); + + memcpy (buf, in_pz + 4, 2); + buf[2] = NUL; + pz = buf; + return parse_scaled_value (res, &pz, buf + 2, 1); +} + +static time_t +parse_HMS (cch_t * pz) +{ + time_t res = 0; + cch_t * ps = strchr (pz, 'H'); + if (ps != NULL) + { + res = parse_scaled_value (0, &pz, ps, SEC_PER_HR); + pz++; + } + + ps = strchr (pz, 'M'); + if (ps != NULL) + { + res = parse_scaled_value (res, &pz, ps, SEC_PER_MIN); + pz++; + } + + ps = strchr (pz, 'S'); + if (ps != NULL) + { + res = parse_scaled_value (res, &pz, ps, 1); + pz++; + } + + while (isspace ((unsigned char)*pz)) pz++; + if (*pz != NUL) + { + errno = EINVAL; + return BAD_TIME; + } + + return res; +} + +static time_t +parse_time (cch_t * pz) +{ + cch_t * ps; + time_t res = 0; + + /* + * Scan for a hyphen + */ + ps = strchr (pz, ':'); + if (ps != NULL) + { + res = parse_hour_minute_second (pz, ps); + } + + /* + * Try for a 'H', 'M' or 'S' suffix + */ + else if (ps = strpbrk (pz, "HMS"), + ps == NULL) + { + /* Its a YYYYMMDD format: */ + res = parse_hourminutesecond (pz); + } + + else + res = parse_HMS (pz); + + return res; +} + +static char * +trim(char * pz) +{ + /* trim leading white space */ + while (isspace ((unsigned char)*pz)) pz++; + + /* trim trailing white space */ + { + char * pe = pz + strlen (pz); + while ((pe > pz) && isspace ((unsigned char)pe[-1])) pe--; + *pe = NUL; + } + + return pz; +} + +/* + * Parse the year/months/days of a time period + */ +static time_t +parse_period (cch_t * in_pz) +{ + char * pz = xstrdup (in_pz); + char * pT = strchr (pz, 'T'); + char * ps; + void * fptr = pz; + time_t res = 0; + + if (pT != NUL) + { + *(pT++) = NUL; + pz = trim (pz); + pT = trim (pT); + } + + /* + * Scan for a hyphen + */ + ps = strchr (pz, '-'); + if (ps != NULL) + { + res = parse_year_month_day (pz, ps); + } + + /* + * Try for a 'Y', 'M' or 'D' suffix + */ + else if (ps = strpbrk (pz, "YMWD"), + ps == NULL) + { + /* Its a YYYYMMDD format: */ + res = parse_yearmonthday (pz); + } + + else + res = parse_YMWD (pz); + + if ((errno == 0) && (pT != NULL)) + { + time_t val = parse_time (pT); + res = scale_n_add (res, val, 1); + } + + free (fptr); + return res; +} + +static time_t +parse_non_iso8601(cch_t * pz) +{ + whats_done_t whatd_we_do = NOTHING_IS_DONE; + + time_t res = 0; + + do { + time_t val; + + errno = 0; + val = str_const_to_l (pz, &pz, 10); + if (errno != 0) + goto bad_time; + + /* IF we find a colon, then we're going to have a seconds value. + We will not loop here any more. We cannot already have parsed + a minute value and if we've parsed an hour value, then the result + value has to be less than an hour. */ + if (*pz == ':') + { + if (whatd_we_do >= MINUTE_IS_DONE) + break; + + val = parse_hr_min_sec (val, pz); + + if ((whatd_we_do == HOUR_IS_DONE) && (val >= SEC_PER_HR)) + break; + + return scale_n_add (res, val, 1); + } + + { + unsigned int mult; + + /* Skip over white space following the number we just parsed. */ + while (isspace ((unsigned char)*pz)) pz++; + + switch (*pz) + { + default: goto bad_time; + case NUL: + return scale_n_add (res, val, 1); + + case 'y': case 'Y': + if (whatd_we_do >= YEAR_IS_DONE) + goto bad_time; + mult = SEC_PER_YEAR; + whatd_we_do = YEAR_IS_DONE; + break; + + case 'M': + if (whatd_we_do >= MONTH_IS_DONE) + goto bad_time; + mult = SEC_PER_MONTH; + whatd_we_do = MONTH_IS_DONE; + break; + + case 'W': + if (whatd_we_do >= WEEK_IS_DONE) + goto bad_time; + mult = SEC_PER_WEEK; + whatd_we_do = WEEK_IS_DONE; + break; + + case 'd': case 'D': + if (whatd_we_do >= DAY_IS_DONE) + goto bad_time; + mult = SEC_PER_DAY; + whatd_we_do = DAY_IS_DONE; + break; + + case 'h': + if (whatd_we_do >= HOUR_IS_DONE) + goto bad_time; + mult = SEC_PER_HR; + whatd_we_do = HOUR_IS_DONE; + break; + + case 'm': + if (whatd_we_do >= MINUTE_IS_DONE) + goto bad_time; + mult = SEC_PER_MIN; + whatd_we_do = MINUTE_IS_DONE; + break; + + case 's': + mult = 1; + whatd_we_do = SECOND_IS_DONE; + break; + } + + res = scale_n_add (res, val, mult); + + while (isspace ((unsigned char)*++pz)) ; + if (*pz == NUL) + return res; + + if (! isdigit ((unsigned char)*pz)) + break; + } + + } while (whatd_we_do < SECOND_IS_DONE); + + bad_time: + errno = EINVAL; + return BAD_TIME; +} + +time_t +parse_duration (char const * pz) +{ + time_t res = 0; + + while (isspace ((unsigned char)*pz)) pz++; + + do { + if (*pz == 'P') + { + res = parse_period (pz + 1); + if ((errno != 0) || (res == BAD_TIME)) + break; + return res; + } + + if (*pz == 'T') + { + res = parse_time (pz + 1); + if ((errno != 0) || (res == BAD_TIME)) + break; + return res; + } + + if (! isdigit ((unsigned char)*pz)) + break; + + res = parse_non_iso8601 (pz); + if ((errno == 0) && (res != BAD_TIME)) + return res; + + } while (0); + + fprintf (stderr, _("Invalid time duration: %s\n"), pz); + if (errno == 0) + errno = EINVAL; + return BAD_TIME; +} + +/* + * Local Variables: + * mode: C + * c-file-style: "gnu" + * indent-tabs-mode: nil + * End: + * end of parse-duration.c */ diff -urN src/contrib/ntp/sntp/libopts/parse-duration.h src.ntp/contrib/ntp/sntp/libopts/parse-duration.h --- src/contrib/ntp/sntp/libopts/parse-duration.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/libopts/parse-duration.h 2009-12-09 08:36:46.000000000 +0100 @@ -0,0 +1,82 @@ +/* Parse a time duration and return a seconds count + Copyright (C) 2008 Free Software Foundation, Inc. + Written by Bruce Korb , 2008. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . */ + +/* + + Readers and users of this function are referred to the ISO-8601 + specification, with particular attention to "Durations". + + At the time of writing, this worked: + + http://en.wikipedia.org/wiki/ISO_8601#Durations + + The string must start with a 'P', 'T' or a digit. + + ==== if it is a digit + + the string may contain: NNN d NNN h NNN m NNN s + This represents NNN days, NNN hours, NNN minutes and NNN seconds. + The embeded white space is optional. + These terms must appear in this order. + The final "s" is optional. + All of the terms ("NNN" plus designator) are optional. + Minutes and seconds may optionally be represented as NNN:NNN. + Also, hours, minute and seconds may be represented as NNN:NNN:NNN. + There is no limitation on the value of any of the terms, except + that the final result must fit in a time_t value. + + ==== if it is a 'P' or 'T', please see ISO-8601 for a rigorous definition. + + The 'P' term may be followed by any of three formats: + yyyymmdd + yy-mm-dd + yy Y mm M ww W dd D + + or it may be empty and followed by a 'T'. The "yyyymmdd" must be eight + digits long. Note: months are always 30 days and years are always 365 + days long. 5 years is always 1825, not 1826 or 1827 depending on leap + year considerations. 3 months is always 90 days. There is no consideration + for how many days are in the current, next or previous months. + + For the final format: + * Embedded white space is allowed, but it is optional. + * All of the terms are optional. Any or all-but-one may be omitted. + * The meanings are yy years, mm months, ww weeks and dd days. + * The terms must appear in this order. + + ==== The 'T' term may be followed by any of these formats: + + hhmmss + hh:mm:ss + hh H mm M ss S + + For the final format: + * Embedded white space is allowed, but it is optional. + * All of the terms are optional. Any or all-but-one may be omitted. + * The terms must appear in this order. + + */ +#ifndef GNULIB_PARSE_DURATION_H +#define GNULIB_PARSE_DURATION_H + +#include + +#define BAD_TIME ((time_t)~0) + +extern time_t parse_duration(char const * in_pz); + +#endif /* GNULIB_PARSE_DURATION_H */ diff -urN src/contrib/ntp/sntp/libopts/pgusage.c src.ntp/contrib/ntp/sntp/libopts/pgusage.c --- src/contrib/ntp/sntp/libopts/pgusage.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/pgusage.c 2009-12-09 08:36:46.000000000 +0100 @@ -1,55 +1,32 @@ /* - * $Id: pgusage.c,v 4.12 2007/04/28 22:19:23 bkorb Exp $ - * Time-stamp: "2006-07-16 08:13:26 bkorb" + * $Id: da09fc943da953195b243b7697fdbf5127f5b6c2 $ + * Time-stamp: "2009-11-01 11:52:51 bkorb" * * Automated Options Paged Usage module. * * This routine will run run-on options through a pager so the * user may examine, print or edit them at their leisure. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ tePagerState pagerState = PAGER_STATE_INITIAL; @@ -64,11 +41,15 @@ * doc: * Run the usage output through a pager. * This is very handy if it is very long. + * This is disabled on platforms without a working fork() function. =*/ void optionPagedUsage( tOptions* pOptions, tOptDesc* pOD ) { -#if defined(__windows__) && !defined(__CYGWIN__) +#if ! defined(HAVE_WORKING_FORK) + if ((pOD->fOptState & OPTST_RESET) != 0) + return; + (*pOptions->pUsageProc)( pOptions, EXIT_SUCCESS ); #else static pid_t my_pid; @@ -82,6 +63,9 @@ switch (pagerState) { case PAGER_STATE_INITIAL: { + if ((pOD->fOptState & OPTST_RESET) != 0) + return; + my_pid = getpid(); #ifdef HAVE_SNPRINTF snprintf(zPageUsage, sizeof(zPageUsage), "/tmp/use.%lu", (tAoUL)my_pid); @@ -110,7 +94,7 @@ */ (*pOptions->pUsageProc)( pOptions, EXIT_SUCCESS ); - /*NOTREACHED*/ + /* NOTREACHED */ _exit( EXIT_FAILURE ); } diff -urN src/contrib/ntp/sntp/libopts/proto.h src.ntp/contrib/ntp/sntp/libopts/proto.h --- src/contrib/ntp/sntp/libopts/proto.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/proto.h 2009-12-09 08:36:46.000000000 +0100 @@ -1,17 +1,20 @@ /* -*- buffer-read-only: t -*- vi: set ro: * * Prototypes for autoopts - * Generated Sat May 5 12:02:36 PDT 2007 + * Generated Sun Nov 8 08:41:10 PST 2009 */ #ifndef AUTOOPTS_PROTO_H_GUARD #define AUTOOPTS_PROTO_H_GUARD 1 + #ifndef LOCAL # define LOCAL extern # define REDEF_LOCAL 1 #else # undef REDEF_LOCAL #endif -/*\n * Extracted from autoopts.c\n */ +/* + * Extracted from autoopts.c + */ LOCAL void * ao_malloc( size_t sz ); @@ -39,7 +42,9 @@ LOCAL tSuccess doRegularOpts( tOptions* pOpts ); -/*\n * Extracted from configfile.c\n */ +/* + * Extracted from configfile.c + */ LOCAL void internalFileLoad( tOptions* pOpts ); @@ -53,14 +58,18 @@ LOCAL tSuccess validateOptionsStruct( tOptions* pOpts, char const* pzProgram ); -/*\n * Extracted from environment.c\n */ +/* + * Extracted from environment.c + */ LOCAL void doPrognameEnv( tOptions* pOpts, teEnvPresetType type ); LOCAL void doEnvPresets( tOptions* pOpts, teEnvPresetType type ); -/*\n * Extracted from load.c\n */ +/* + * Extracted from load.c + */ LOCAL void mungeString( char* pzTxt, tOptionLoadMode mode ); @@ -72,15 +81,27 @@ tDirection direction, tOptionLoadMode load_mode ); -/*\n * Extracted from nested.c\n */ +/* + * Extracted from nested.c + */ LOCAL tOptionValue* optionLoadNested(char const* pzTxt, char const* pzName, size_t nameLen); -/*\n * Extracted from sort.c\n */ +LOCAL int +get_special_char(char const ** ppz, int * ct); + +LOCAL void +emit_special_char(FILE * fp, int ch); + +/* + * Extracted from sort.c + */ LOCAL void optionSort( tOptions* pOpts ); -/*\n * Extracted from stack.c\n */ +/* + * Extracted from stack.c + */ LOCAL void addArgListEntry( void** ppAL, void* entry ); diff -urN src/contrib/ntp/sntp/libopts/putshell.c src.ntp/contrib/ntp/sntp/libopts/putshell.c --- src/contrib/ntp/sntp/libopts/putshell.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/putshell.c 2009-12-09 08:36:46.000000000 +0100 @@ -1,58 +1,35 @@ /* - * $Id: putshell.c,v 4.18 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-13 10:29:39 bkorb" + * $Id: 5d14243d5d32d234f05bc8a20b1a6464716b30aa $ + * Time-stamp: "2008-07-27 12:14:38 bkorb" * * This module will interpret the options set in the tOptions * structure and print them to standard out in a fashion that * will allow them to be interpreted by the Bourne or Korn shells. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. + * These files have the following md5sums: * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static void putQuotedStr( tCC* pzStr ); /* = = = END-STATIC-FORWARD = = = */ @@ -181,7 +158,7 @@ printf( zOptNumFmt, pOpts->pzPROGNAME, pOD->pz_NAME, (int)(uintptr_t)(pOD->optCookie) ); pOD->optCookie = (void*)(uintptr_t)~0UL; - (*(pOD->pOptProc))( (tOptions*)2UL, pOD ); + (*(pOD->pOptProc))(OPTPROC_RETURN_VALNAME, pOD); /* * We are building the typeset list. The list returned starts with @@ -190,15 +167,15 @@ pz = pOD->optArg.argString + 7; while (*pz != NUL) { printf( "typeset -x -i %s_", pOD->pz_NAME ); - pz += strspn( pz, " +\t\n\f" ); + while (IS_PLUS_N_SPACE_CHAR(*pz)) pz++; + for (;;) { - int ch = *(pz++); - if (islower( ch )) fputc( toupper( ch ), stdout ); - else if (isalnum( ch )) fputc( ch, stdout ); - else if (isspace( ch ) - || (ch == '+')) goto name_done; - else if (ch == NUL) { pz--; goto name_done; } - else fputc( '_', stdout ); + int ch = *(pz++); + if (IS_LOWER_CASE_CHAR(ch)) fputc(toupper(ch), stdout); + else if (IS_UPPER_CASE_CHAR(ch)) fputc(ch, stdout); + else if (IS_PLUS_N_SPACE_CHAR(ch)) goto name_done; + else if (ch == NUL) { pz--; goto name_done; } + else fputc( '_', stdout ); } name_done:; printf( "=%1$lu # 0x%1$lX\n", (unsigned long)val ); val <<= 1; @@ -267,11 +244,19 @@ * to emit the value corresponding to the "optArg" number. */ else if (OPTST_GET_ARGTYPE(pOD->fOptState) == OPARG_TYPE_ENUMERATION) { + uintptr_t e_val = pOD->optArg.argEnum; printf( zOptValFmt, pOpts->pzPROGNAME, pOD->pz_NAME ); - fputc( '\'', stdout ); - (*(pOD->pOptProc))( (tOptions*)1UL, pOD ); - fputc( '\'', stdout ); - printf( zOptEnd, pOpts->pzPROGNAME, pOD->pz_NAME ); + + /* + * Convert value to string, print that and restore numeric value. + */ + (*(pOD->pOptProc))(OPTPROC_RETURN_VALNAME, pOD); + printf("'%s'", pOD->optArg.argString); + if (pOD->fOptState & OPTST_ALLOC_ARG) + AGFREE(pOD->optArg.argString); + pOD->optArg.argEnum = e_val; + + printf(zOptEnd, pOpts->pzPROGNAME, pOD->pz_NAME); } /* diff -urN src/contrib/ntp/sntp/libopts/reset.c src.ntp/contrib/ntp/sntp/libopts/reset.c --- src/contrib/ntp/sntp/libopts/reset.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/libopts/reset.c 2009-12-09 08:36:46.000000000 +0100 @@ -0,0 +1,134 @@ + +/* + * $Id: 808e536555f06924b450ab6b5a72c03b67c5b99a $ + * Time-stamp: "2009-11-01 11:45:57 bkorb" + * + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd + */ + +static void +optionReset( tOptions* pOpts, tOptDesc* pOD ) +{ + pOD->fOptState &= OPTST_PERSISTENT_MASK; + pOD->fOptState |= OPTST_RESET; + if (pOD->pOptProc != NULL) + pOD->pOptProc(pOpts, pOD); + pOD->optArg.argString = + pOpts->originalOptArgArray[ pOD->optIndex ].argString; + pOD->optCookie = pOpts->originalOptArgCookie[ pOD->optIndex ]; + pOD->fOptState &= OPTST_PERSISTENT_MASK; +} + + +static void +optionResetEverything(tOptions * pOpts) +{ + tOptDesc * pOD = pOpts->pOptDesc; + int ct = pOpts->presetOptCt; + + for (;;) { + optionReset(pOpts, pOD); + + if (--ct <= 0) + break; + pOD++; + } +} + + +/*=export_func optionResetOpt + * private: + * + * what: Reset the value of an option + * arg: + tOptions* + pOpts + program options descriptor + + * arg: + tOptDesc* + pOptDesc + the descriptor for this arg + + * + * doc: + * This code will cause another option to be reset to its initial state. + * For example, --reset=foo will cause the --foo option to be reset. +=*/ +void +optionResetOpt( tOptions* pOpts, tOptDesc* pOD ) +{ + static ag_bool reset_active = AG_FALSE; + + tOptState opt_state = OPTSTATE_INITIALIZER(DEFINED); + char const * pzArg = pOD->optArg.argString; + tSuccess succ; + + if (reset_active) + return; + + if ( (! HAS_originalOptArgArray(pOpts)) + || (pOpts->originalOptArgCookie == NULL)) { + fputs(zResetNotConfig, stderr); + _exit(EX_SOFTWARE); + } + + if ((pzArg == NULL) || (*pzArg == NUL)) { + fputs(zNoResetArg, stderr); + pOpts->pUsageProc(pOpts, EXIT_FAILURE); + /* NOTREACHED */ + assert(0 == 1); + } + + reset_active = AG_TRUE; + + if (pzArg[1] == NUL) { + if (*pzArg == '*') { + optionResetEverything(pOpts); + reset_active = AG_FALSE; + return; + } + + succ = shortOptionFind(pOpts, (tAoUC)*pzArg, &opt_state); + if (! SUCCESSFUL(succ)) { + fprintf(stderr, zIllOptChr, pOpts->pzProgPath, *pzArg); + pOpts->pUsageProc(pOpts, EXIT_FAILURE); + /* NOTREACHED */ + assert(0 == 1); + } + } else { + succ = longOptionFind(pOpts, (char *)pzArg, &opt_state); + if (! SUCCESSFUL(succ)) { + fprintf(stderr, zIllOptStr, pOpts->pzProgPath, pzArg); + pOpts->pUsageProc(pOpts, EXIT_FAILURE); + /* NOTREACHED */ + assert(0 == 1); + } + } + + /* + * We've found the indicated option. Turn off all non-persistent + * flags because we're forcing the option back to its initialized state. + * Call any callout procedure to handle whatever it needs to. + * Finally, clear the reset flag, too. + */ + optionReset(pOpts, opt_state.pOD); + reset_active = AG_FALSE; +} +/* + * Local Variables: + * mode: C + * c-file-style: "stroustrup" + * indent-tabs-mode: nil + * End: + * end of autoopts/reset.c */ diff -urN src/contrib/ntp/sntp/libopts/restore.c src.ntp/contrib/ntp/sntp/libopts/restore.c --- src/contrib/ntp/sntp/libopts/restore.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/restore.c 2009-12-09 08:36:46.000000000 +0100 @@ -1,54 +1,31 @@ /* - * restore.c $Id: restore.c,v 4.10 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-13 14:13:17 bkorb" + * restore.c $Id: 6f5237ba2586755d8ca354f325fc00e7fa1395ec $ + * Time-stamp: "2007-07-04 11:34:40 bkorb" * * This module's routines will save the current option state to memory * and restore it. If saved prior to the initial optionProcess call, * then the initial state will be restored. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ /* diff -urN src/contrib/ntp/sntp/libopts/save.c src.ntp/contrib/ntp/sntp/libopts/save.c --- src/contrib/ntp/sntp/libopts/save.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/save.c 2009-12-09 08:36:46.000000000 +0100 @@ -1,60 +1,38 @@ /* - * save.c $Id: save.c,v 4.18 2007/04/15 19:01:18 bkorb Exp $ - * Time-stamp: "2007-04-15 11:11:10 bkorb" + * save.c $Id: 5a69234fab4c2d8d7eaf4aed4dbb3052ce6be5b6 $ + * Time-stamp: "2009-07-20 20:40:28 bkorb" * * This module's routines will take the currently set options and * store them into an ".rc" file for re-interpretation the next * time the invoking program is run. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ -tSCC zWarn[] = "%s WARNING: cannot save options - "; +static char const zWarn[] = "%s WARNING: cannot save options - "; +static char const close_xml[] = "\n"; /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static tCC* findDirName( tOptions* pOpts, int* p_free ); @@ -66,6 +44,36 @@ FILE * fp, tOptDesc * p, tCC* pzLA ); + +static void +print_a_value(FILE * fp, int depth, tOptDesc * pOD, tOptionValue const * ovp); + +static void +print_a_string(FILE * fp, char const * name, char const * pz); + +static void +printValueList(FILE * fp, char const * name, tArgList * al); + +static void +printHierarchy(FILE * fp, tOptDesc * p); + +static FILE * +openSaveFile( tOptions* pOpts ); + +static void +printNoArgOpt(FILE * fp, tOptDesc * p, tOptDesc * pOD); + +static void +printStringArg(FILE * fp, tOptDesc * pOD); + +static void +printEnumArg(FILE * fp, tOptDesc * pOD); + +static void +printSetMemberArg(FILE * fp, tOptDesc * pOD); + +static void +printFileArg(FILE * fp, tOptDesc * pOD, tOptions* pOpts); /* = = = END-STATIC-FORWARD = = = */ static tCC* @@ -73,7 +81,8 @@ { tCC* pzDir; - if (pOpts->specOptIdx.save_opts == 0) + if ( (pOpts->specOptIdx.save_opts == NO_EQUIVALENT) + || (pOpts->specOptIdx.save_opts == 0)) return NULL; pzDir = pOpts->pOptDesc[ pOpts->specOptIdx.save_opts ].optArg.argString; @@ -331,39 +340,194 @@ } -/*=export_func optionSaveFile - * - * what: saves the option state to a file - * - * arg: tOptions*, pOpts, program options descriptor - * - * doc: - * - * This routine will save the state of option processing to a file. The name - * of that file can be specified with the argument to the @code{--save-opts} - * option, or by appending the @code{rcfile} attribute to the last - * @code{homerc} attribute. If no @code{rcfile} attribute was specified, it - * will default to @code{.@i{programname}rc}. If you wish to specify another - * file, you should invoke the @code{SET_OPT_SAVE_OPTS( @i{filename} )} macro. - * - * err: - * - * If no @code{homerc} file was specified, this routine will silently return - * and do nothing. If the output file cannot be created or updated, a message - * will be printed to @code{stderr} and the routine will return. -=*/ -void -optionSaveFile( tOptions* pOpts ) +static void +print_a_value(FILE * fp, int depth, tOptDesc * pOD, tOptionValue const * ovp) +{ + static char const bool_atr[] = "<%1$s type=boolean>%2$s\n"; + static char const numb_atr[] = "<%1$s type=integer>0x%2$lX\n"; + static char const type_atr[] = "<%s type=%s>"; + static char const null_atr[] = "<%s/>\n"; + + while (--depth >= 0) + putc(' ', fp), putc(' ', fp); + + switch (ovp->valType) { + default: + case OPARG_TYPE_NONE: + fprintf(fp, null_atr, ovp->pzName); + break; + + case OPARG_TYPE_STRING: + print_a_string(fp, ovp->pzName, ovp->v.strVal); + break; + + case OPARG_TYPE_ENUMERATION: + case OPARG_TYPE_MEMBERSHIP: + if (pOD != NULL) { + tAoUI opt_state = pOD->fOptState; + uintptr_t val = pOD->optArg.argEnum; + char const * typ = (ovp->valType == OPARG_TYPE_ENUMERATION) + ? "keyword" : "set-membership"; + + fprintf(fp, type_atr, ovp->pzName, typ); + + /* + * This is a magic incantation that will convert the + * bit flag values back into a string suitable for printing. + */ + (*(pOD->pOptProc))(OPTPROC_RETURN_VALNAME, pOD ); + if (pOD->optArg.argString != NULL) { + fputs(pOD->optArg.argString, fp); + + if (ovp->valType != OPARG_TYPE_ENUMERATION) { + /* + * set membership strings get allocated + */ + AGFREE( (void*)pOD->optArg.argString ); + } + } + + pOD->optArg.argEnum = val; + pOD->fOptState = opt_state; + fprintf(fp, close_xml, ovp->pzName); + break; + } + /* FALLTHROUGH */ + + case OPARG_TYPE_NUMERIC: + fprintf(fp, numb_atr, ovp->pzName, ovp->v.longVal); + break; + + case OPARG_TYPE_BOOLEAN: + fprintf(fp, bool_atr, ovp->pzName, + ovp->v.boolVal ? "true" : "false"); + break; + + case OPARG_TYPE_HIERARCHY: + printValueList(fp, ovp->pzName, ovp->v.nestVal); + break; + } +} + + +static void +print_a_string(FILE * fp, char const * name, char const * pz) +{ + static char const open_atr[] = "<%s>"; + + fprintf(fp, open_atr, name); + for (;;) { + int ch = ((int)*(pz++)) & 0xFF; + + switch (ch) { + case NUL: goto string_done; + + case '&': + case '<': + case '>': +#if __GNUC__ >= 4 + case 1 ... (' ' - 1): + case ('~' + 1) ... 0xFF: +#endif + emit_special_char(fp, ch); + break; + + default: +#if __GNUC__ < 4 + if ( ((ch >= 1) && (ch <= (' ' - 1))) + || ((ch >= ('~' + 1)) && (ch <= 0xFF)) ) { + emit_special_char(fp, ch); + break; + } +#endif + putc(ch, fp); + } + } string_done:; + fprintf(fp, close_xml, name); +} + + +static void +printValueList(FILE * fp, char const * name, tArgList * al) +{ + static int depth = 1; + + int sp_ct; + int opt_ct; + void ** opt_list; + + if (al == NULL) + return; + opt_ct = al->useCt; + opt_list = (void **)al->apzArgs; + + if (opt_ct <= 0) { + fprintf(fp, "<%s/>\n", name); + return; + } + + fprintf(fp, "<%s type=nested>\n", name); + + depth++; + while (--opt_ct >= 0) { + tOptionValue const * ovp = *(opt_list++); + + print_a_value(fp, depth, NULL, ovp); + } + depth--; + + for (sp_ct = depth; --sp_ct >= 0;) + putc(' ', fp), putc(' ', fp); + fprintf(fp, "\n", name); +} + + +static void +printHierarchy(FILE * fp, tOptDesc * p) +{ + int opt_ct; + tArgList * al = p->optCookie; + void ** opt_list; + + if (al == NULL) + return; + + opt_ct = al->useCt; + opt_list = (void **)al->apzArgs; + + if (opt_ct <= 0) + return; + + do { + tOptionValue const * base = *(opt_list++); + tOptionValue const * ovp = optionGetValue(base, NULL); + + if (ovp == NULL) + continue; + + fprintf(fp, "<%s type=nested>\n", p->pz_Name); + + do { + print_a_value(fp, 1, p, ovp); + + } while (ovp = optionNextValue(base, ovp), + ovp != NULL); + + fprintf(fp, "\n", p->pz_Name); + } while (--opt_ct > 0); +} + + +static FILE * +openSaveFile( tOptions* pOpts ) { - tOptDesc* pOD; - int ct; FILE* fp; { int free_name = 0; tCC* pzFName = findFileName( pOpts, &free_name ); if (pzFName == NULL) - return; + return NULL; fp = fopen( pzFName, "w" FOPEN_BINARY_FLAG ); if (fp == NULL) { @@ -371,7 +535,7 @@ fprintf( stderr, zNoCreat, errno, strerror( errno ), pzFName ); if (free_name) AGFREE((void*) pzFName ); - return; + return fp; } if (free_name) @@ -399,13 +563,156 @@ #endif } + return fp; +} + +static void +printNoArgOpt(FILE * fp, tOptDesc * p, tOptDesc * pOD) +{ + /* + * The aliased to argument indicates whether or not the option + * is "disabled". However, the original option has the name + * string, so we get that there, not with "p". + */ + char const * pznm = + (DISABLED_OPT( p )) ? pOD->pz_DisableName : pOD->pz_Name; + /* + * If the option was disabled and the disablement name is NULL, + * then the disablement was caused by aliasing. + * Use the name as the string to emit. + */ + if (pznm == NULL) + pznm = pOD->pz_Name; + + fprintf(fp, "%s\n", pznm); +} + +static void +printStringArg(FILE * fp, tOptDesc * pOD) +{ + if (pOD->fOptState & OPTST_STACKED) { + tArgList* pAL = (tArgList*)pOD->optCookie; + int uct = pAL->useCt; + tCC** ppz = pAL->apzArgs; + + /* + * un-disable multiple copies of disabled options. + */ + if (uct > 1) + pOD->fOptState &= ~OPTST_DISABLED; + + while (uct-- > 0) + printEntry( fp, pOD, *(ppz++) ); + } else { + printEntry( fp, pOD, pOD->optArg.argString ); + } +} + +static void +printEnumArg(FILE * fp, tOptDesc * pOD) +{ + uintptr_t val = pOD->optArg.argEnum; + + /* + * This is a magic incantation that will convert the + * bit flag values back into a string suitable for printing. + */ + (*(pOD->pOptProc))(OPTPROC_RETURN_VALNAME, pOD); + printEntry( fp, pOD, (void*)(pOD->optArg.argString)); + + pOD->optArg.argEnum = val; +} + +static void +printSetMemberArg(FILE * fp, tOptDesc * pOD) +{ + uintptr_t val = pOD->optArg.argEnum; + + /* + * This is a magic incantation that will convert the + * bit flag values back into a string suitable for printing. + */ + (*(pOD->pOptProc))(OPTPROC_RETURN_VALNAME, pOD); + printEntry( fp, pOD, (void*)(pOD->optArg.argString)); + + if (pOD->optArg.argString != NULL) { + /* + * set membership strings get allocated + */ + AGFREE( (void*)pOD->optArg.argString ); + pOD->fOptState &= ~OPTST_ALLOC_ARG; + } + + pOD->optArg.argEnum = val; +} + +static void +printFileArg(FILE * fp, tOptDesc * pOD, tOptions* pOpts) +{ + /* + * If the cookie is not NULL, then it has the file name, period. + * Otherwise, if we have a non-NULL string argument, then.... + */ + if (pOD->optCookie != NULL) + printEntry(fp, pOD, pOD->optCookie); + + else if (HAS_originalOptArgArray(pOpts)) { + char const * orig = + pOpts->originalOptArgArray[pOD->optIndex].argString; + + if (pOD->optArg.argString == orig) + return; + + printEntry(fp, pOD, pOD->optArg.argString); + } +} + + +/*=export_func optionSaveFile + * + * what: saves the option state to a file + * + * arg: tOptions*, pOpts, program options descriptor + * + * doc: + * + * This routine will save the state of option processing to a file. The name + * of that file can be specified with the argument to the @code{--save-opts} + * option, or by appending the @code{rcfile} attribute to the last + * @code{homerc} attribute. If no @code{rcfile} attribute was specified, it + * will default to @code{.@i{programname}rc}. If you wish to specify another + * file, you should invoke the @code{SET_OPT_SAVE_OPTS( @i{filename} )} macro. + * + * The recommend usage is as follows: + * @example + * optionProcess(&progOptions, argc, argv); + * if (i_want_a_non_standard_place_for_this) + * SET_OPT_SAVE_OPTS("myfilename"); + * optionSaveFile(&progOptions); + * @end example + * + * err: + * + * If no @code{homerc} file was specified, this routine will silently return + * and do nothing. If the output file cannot be created or updated, a message + * will be printed to @code{stderr} and the routine will return. +=*/ +void +optionSaveFile( tOptions* pOpts ) +{ + tOptDesc* pOD; + int ct; + FILE* fp = openSaveFile(pOpts); + + if (fp == NULL) + return; + /* * FOR each of the defined options, ... */ ct = pOpts->presetOptCt; pOD = pOpts->pOptDesc; do { - int arg_state; tOptDesc* p; /* @@ -413,98 +720,61 @@ * OR it does not take an initialization value * OR it is equivalenced to another option * THEN continue (ignore it) + * + * Equivalenced options get picked up when the equivalenced-to + * option is processed. */ if (UNUSED_OPT( pOD )) continue; - if ((pOD->fOptState & (OPTST_NO_INIT|OPTST_DOCUMENT|OPTST_OMITTED)) - != 0) + if ((pOD->fOptState & OPTST_DO_NOT_SAVE_MASK) != 0) continue; if ( (pOD->optEquivIndex != NO_EQUIVALENT) - && (pOD->optEquivIndex != pOD->optIndex)) + && (pOD->optEquivIndex != pOD->optIndex)) continue; /* - * Set a temporary pointer to the real option description - * (i.e. account for equivalencing) + * The option argument data are found at the equivalenced-to option, + * but the actual option argument type comes from the original + * option descriptor. Be careful! */ p = ((pOD->fOptState & OPTST_EQUIVALENCE) != 0) ? (pOpts->pOptDesc + pOD->optActualIndex) : pOD; - /* - * IF no arguments are allowed - * THEN just print the name and continue - */ - if (OPTST_GET_ARGTYPE(pOD->fOptState) == OPARG_TYPE_NONE) { - char const * pznm = - (DISABLED_OPT( p )) ? p->pz_DisableName : p->pz_Name; - /* - * If the option was disabled and the disablement name is NULL, - * then the disablement was caused by aliasing. - * Use the name as the string to emit. - */ - if (pznm == NULL) - pznm = p->pz_Name; - - fprintf(fp, "%s\n", pznm); - continue; - } + switch (OPTST_GET_ARGTYPE(pOD->fOptState)) { + case OPARG_TYPE_NONE: + printNoArgOpt(fp, p, pOD); + break; - arg_state = OPTST_GET_ARGTYPE(p->fOptState); - switch (arg_state) { - case 0: case OPARG_TYPE_NUMERIC: printEntry( fp, p, (void*)(p->optArg.argInt)); break; case OPARG_TYPE_STRING: - if (p->fOptState & OPTST_STACKED) { - tArgList* pAL = (tArgList*)p->optCookie; - int uct = pAL->useCt; - tCC** ppz = pAL->apzArgs; - - /* - * Disallow multiple copies of disabled options. - */ - if (uct > 1) - p->fOptState &= ~OPTST_DISABLED; - - while (uct-- > 0) - printEntry( fp, p, *(ppz++) ); - } else { - printEntry( fp, p, p->optArg.argString ); - } + printStringArg(fp, p); break; case OPARG_TYPE_ENUMERATION: - case OPARG_TYPE_MEMBERSHIP: - { - uintptr_t val = p->optArg.argEnum; - /* - * This is a magic incantation that will convert the - * bit flag values back into a string suitable for printing. - */ - (*(p->pOptProc))( (tOptions*)2UL, p ); - printEntry( fp, p, (void*)(p->optArg.argString)); - - if ( (p->optArg.argString != NULL) - && (arg_state != OPARG_TYPE_ENUMERATION)) { - /* - * set membership strings get allocated - */ - AGFREE( (void*)p->optArg.argString ); - p->fOptState &= ~OPTST_ALLOC_ARG; - } + printEnumArg(fp, p); + break; - p->optArg.argEnum = val; + case OPARG_TYPE_MEMBERSHIP: + printSetMemberArg(fp, p); break; - } case OPARG_TYPE_BOOLEAN: printEntry( fp, p, p->optArg.argBool ? "true" : "false" ); break; + case OPARG_TYPE_HIERARCHY: + printHierarchy(fp, p); + break; + + case OPARG_TYPE_FILE: + printFileArg(fp, p, pOpts); + break; + default: break; /* cannot handle - skip it */ } diff -urN src/contrib/ntp/sntp/libopts/sort.c src.ntp/contrib/ntp/sntp/libopts/sort.c --- src/contrib/ntp/sntp/libopts/sort.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/sort.c 2009-12-09 08:36:46.000000000 +0100 @@ -1,56 +1,33 @@ /* - * sort.c $Id: sort.c,v 4.10 2007/04/28 22:19:23 bkorb Exp $ - * Time-stamp: "2006-10-18 11:29:04 bkorb" + * sort.c $Id: aac1bf81481f4bb149a72129fbd11fe54db7fa35 $ + * Time-stamp: "2007-07-04 11:34:52 bkorb" * * This module implements argument sorting. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. + * These files have the following md5sums: * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static tSuccess mustHandleArg( tOptions* pOpts, char* pzArg, tOptState* pOS, char** ppzOpts, int* pOptsIdx ); diff -urN src/contrib/ntp/sntp/libopts/stack.c src.ntp/contrib/ntp/sntp/libopts/stack.c --- src/contrib/ntp/sntp/libopts/stack.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/stack.c 2009-12-09 08:36:46.000000000 +0100 @@ -1,54 +1,31 @@ /* * stack.c - * $Id: stack.c,v 4.13 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-13 10:43:21 bkorb" + * $Id: 9d4a7c1c6ae364a6134dc5ff01f58f08b52f1a16 $ + * Time-stamp: "2008-07-30 16:56:32 bkorb" * * This is a special option processing routine that will save the * argument to an option in a FIFO queue. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ #ifdef WITH_LIBREGEX @@ -72,7 +49,12 @@ { int res; - tArgList* pAL = (tArgList*)pOptDesc->optCookie; + tArgList* pAL; + + if ((pOptDesc->fOptState & OPTST_RESET) != 0) + return; + pAL = (tArgList*)pOptDesc->optCookie; + /* * IF we don't have any stacked options, * THEN indicate that we don't have any of these options @@ -254,11 +236,24 @@ { char * pz; - if (pOD->optArg.argString == NULL) - return; + if ((pOD->fOptState & OPTST_RESET) != 0) { + tArgList* pAL = (void*)pOD->optCookie; + int ix; + if (pAL == NULL) + return; - AGDUPSTR(pz, pOD->optArg.argString, "stack arg"); - addArgListEntry( &(pOD->optCookie), (void*)pz ); + ix = pAL->useCt; + while (--ix >= 0) + AGFREE(pAL->apzArgs[ix]); + AGFREE(pAL); + + } else { + if (pOD->optArg.argString == NULL) + return; + + AGDUPSTR(pz, pOD->optArg.argString, "stack arg"); + addArgListEntry( &(pOD->optCookie), (void*)pz ); + } } /* * Local Variables: diff -urN src/contrib/ntp/sntp/libopts/streqvcmp.c src.ntp/contrib/ntp/sntp/libopts/streqvcmp.c --- src/contrib/ntp/sntp/libopts/streqvcmp.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/streqvcmp.c 2009-12-09 08:36:46.000000000 +0100 @@ -1,7 +1,7 @@ /* - * $Id: streqvcmp.c,v 4.10 2007/04/28 22:19:23 bkorb Exp $ - * Time-stamp: "2006-07-26 18:25:53 bkorb" + * $Id: cb437d22b0c48960c9e1c23501fba6e3291fecd8 $ + * Time-stamp: "2008-12-26 10:15:46 bkorb" * * String Equivalence Comparison * @@ -9,52 +9,27 @@ * character before comparison. In processing long option names, * the characters "-", "_" and "^" all need to be equivalent * (because they are treated so by different development environments). - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ - -/* + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd + * * This array is designed for mapping upper and lower case letter * together for a case independent comparison. The mappings are * based upon ascii character sequences. @@ -270,6 +245,8 @@ * This function name is mapped to option_strtransform so as to not conflict * with the POSIX name space. * + * The source and destination may be the same. + * * err: none. =*/ void diff -urN src/contrib/ntp/sntp/libopts/text_mmap.c src.ntp/contrib/ntp/sntp/libopts/text_mmap.c --- src/contrib/ntp/sntp/libopts/text_mmap.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/text_mmap.c 2009-12-09 08:36:46.000000000 +0100 @@ -1,7 +1,27 @@ /* - * $Id: text_mmap.c,v 4.15 2006/11/27 01:52:23 bkorb Exp $ + * $Id: 14e1f51d1a5a31d8395fdf1e93a07bace1c59e87 $ * - * Time-stamp: "2006-09-10 14:50:04 bkorb" + * Time-stamp: "2007-07-04 11:35:49 bkorb" + * + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ #ifndef MAP_ANONYMOUS diff -urN src/contrib/ntp/sntp/libopts/time.c src.ntp/contrib/ntp/sntp/libopts/time.c --- src/contrib/ntp/sntp/libopts/time.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/libopts/time.c 2009-12-09 08:36:46.000000000 +0100 @@ -0,0 +1,88 @@ + +/* + * $Id: 63d3312044fd7854ad0995faea41c96f5185cb93 $ + * Time-stamp: "2008-11-16 14:51:48 bkorb" + * + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd + */ + +#ifndef HAVE_PARSE_DURATION +#include + +static inline char * +ao_xstrdup(char const * pz) +{ + char * str; + AGDUPSTR(str, pz, "time val str"); + return str; +} + +#define xstrdup(_s) ao_xstrdup(_s) + +#include "parse-duration.c" + +#undef xstrdup +#endif + +/*=export_func optionTimeVal + * private: + * + * what: process an option with a time value. + * arg: + tOptions* + pOpts + program options descriptor + + * arg: + tOptDesc* + pOptDesc + the descriptor for this arg + + * + * doc: + * Decipher a time duration value. +=*/ +void +optionTimeVal(tOptions* pOpts, tOptDesc* pOD ) +{ + long val; + + if ((pOD->fOptState & OPTST_RESET) != 0) + return; + + val = parse_duration(pOD->optArg.argString); + if (errno != 0) + goto bad_time; + + if (pOD->fOptState & OPTST_ALLOC_ARG) { + AGFREE(pOD->optArg.argString); + pOD->fOptState &= ~OPTST_ALLOC_ARG; + } + + pOD->optArg.argInt = val; + return; + +bad_time: + fprintf( stderr, zNotNumber, pOpts->pzProgName, pOD->optArg.argString ); + if ((pOpts->fOptSet & OPTPROC_ERRSTOP) != 0) + (*(pOpts->pUsageProc))(pOpts, EXIT_FAILURE); + + pOD->optArg.argInt = ~0; +} +/* + * Local Variables: + * mode: C + * c-file-style: "stroustrup" + * indent-tabs-mode: nil + * End: + * end of autoopts/numeric.c */ diff -urN src/contrib/ntp/sntp/libopts/tokenize.c src.ntp/contrib/ntp/sntp/libopts/tokenize.c --- src/contrib/ntp/sntp/libopts/tokenize.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/tokenize.c 2009-12-09 08:36:46.000000000 +0100 @@ -1,26 +1,28 @@ /* * This file defines the string_tokenize interface - * Time-stamp: "2006-06-24 15:27:49 bkorb" + * Time-stamp: "2007-11-12 20:40:36 bkorb" * - * string_tokenize copyright 2005 Bruce Korb + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved * - * string_tokenize is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * string_tokenize is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with string_tokenize; if not, write to: - * The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ -#include + #include #include @@ -28,7 +30,7 @@ #define ch_t unsigned char /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static void copy_cooked( ch_t** ppDest, char const ** ppSrc ); @@ -189,7 +191,7 @@ * Trim leading white space. Use "ENOENT" and a NULL return to indicate * an empty string was passed. */ - while (isspace( (ch_t)*str )) str++; + while (IS_WHITESPACE_CHAR(*str)) str++; if (*str == NUL) { bogus_str: errno = ENOENT; @@ -206,9 +208,9 @@ do { max_token_ct++; - while (! isspace( *++pz )) + while (! IS_WHITESPACE_CHAR(*++pz)) if (*pz == NUL) goto found_nul; - while (isspace( *pz )) pz++; + while (IS_WHITESPACE_CHAR(*pz)) pz++; } while (*pz != NUL); found_nul: @@ -232,9 +234,9 @@ res->tkn_list[ res->tkn_ct++ ] = pzDest; for (;;) { int ch = (ch_t)*str; - if (isspace( ch )) { + if (IS_WHITESPACE_CHAR(ch)) { found_white_space: - while (isspace( (ch_t)*++str )) ; + while (IS_WHITESPACE_CHAR(*++str)) ; break; } @@ -246,7 +248,7 @@ errno = EINVAL; return NULL; } - if (isspace( (ch_t)*str )) + if (IS_WHITESPACE_CHAR(*str)) goto found_white_space; break; @@ -257,7 +259,7 @@ errno = EINVAL; return NULL; } - if (isspace( (ch_t)*str )) + if (IS_WHITESPACE_CHAR(*str)) goto found_white_space; break; diff -urN src/contrib/ntp/sntp/libopts/usage.c src.ntp/contrib/ntp/sntp/libopts/usage.c --- src/contrib/ntp/sntp/libopts/usage.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/usage.c 2009-12-09 08:36:46.000000000 +0100 @@ -1,7 +1,7 @@ /* - * usage.c $Id: usage.c,v 4.15 2007/04/28 22:19:23 bkorb Exp $ - * Time-stamp: "2007-04-15 11:02:46 bkorb" + * usage.c $Id: f611ee45aa9aa8dc102b8acf6b4bc568c60fa99f $ + * Time-stamp: "2009-10-02 23:18:50 bkorb" * * This module implements the default usage procedure for * Automated Options. It may be overridden, of course. @@ -13,46 +13,25 @@ */ /* - * Automated Options copyright 1992-2007 Bruce Korb + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ #define OPTPROC_L_N_S (OPTPROC_LONGOPT | OPTPROC_SHORTOPT) @@ -64,7 +43,7 @@ static ag_bool displayEnum; /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static ag_bool checkGNUUsage( tOptions* pOpts ); @@ -82,6 +61,12 @@ tCC* pzPN ); static void +printOptPreamble( + tOptions* pOptions, + tOptDesc* pOD, + arg_types_t* pAT ); + +static void printOneUsage( tOptions* pOptions, tOptDesc* pOD, @@ -89,9 +74,9 @@ static void printOptionUsage( - tOptions* pOpts, - int ex_code, - tCC* pOptTitle ); + tOptions * pOpts, + int ex_code, + tCC * pOptTitle ); static void printProgramDetails( tOptions* pOptions ); @@ -187,9 +172,32 @@ * Paged usage will preset option_usage_fp to an output file. * If it hasn't already been set, then set it to standard output * on successful exit (help was requested), otherwise error out. + * + * Test the version before obtaining pzFullUsage or pzShortUsage. + * These fields do not exist before revision 30. */ - if (option_usage_fp == NULL) - option_usage_fp = (actual_exit_code != EXIT_SUCCESS) ? stderr : stdout; + { + char const * pz; + + if (actual_exit_code == EXIT_SUCCESS) { + pz = (pOptions->structVersion >= 30 * 4096) + ? pOptions->pzFullUsage : NULL; + + if (option_usage_fp == NULL) + option_usage_fp = stdout; + } else { + pz = (pOptions->structVersion >= 30 * 4096) + ? pOptions->pzShortUsage : NULL; + + if (option_usage_fp == NULL) + option_usage_fp = stderr; + } + + if (pz != NULL) { + fputs(pz, option_usage_fp); + exit(actual_exit_code); + } + } fprintf( option_usage_fp, pOptions->pzUsageTitle, pOptions->pzProgName ); @@ -319,13 +327,23 @@ fprintf( option_usage_fp, zDis, pOD->pz_DisableName ); /* - * IF the numeric option has a special callback, - * THEN call it, requesting the range or other special info + * Check for argument types that have callbacks with magical properties */ - if ( (OPTST_GET_ARGTYPE(pOD->fOptState) == OPARG_TYPE_NUMERIC) - && (pOD->pOptProc != NULL) - && (pOD->pOptProc != optionNumericVal) ) { - (*(pOD->pOptProc))( pOptions, NULL ); + switch (OPTST_GET_ARGTYPE(pOD->fOptState)) { + case OPARG_TYPE_NUMERIC: + /* + * IF the numeric option has a special callback, + * THEN call it, requesting the range or other special info + */ + if ( (pOD->pOptProc != NULL) + && (pOD->pOptProc != optionNumericVal) ) { + (*(pOD->pOptProc))(OPTPROC_EMIT_USAGE, pOD); + } + break; + + case OPARG_TYPE_FILE: + (*(pOD->pOptProc))(OPTPROC_EMIT_USAGE, pOD); + break; } /* @@ -450,11 +468,8 @@ } -/* - * Print the usage information for a single option. - */ static void -printOneUsage( +printOptPreamble( tOptions* pOptions, tOptDesc* pOD, arg_types_t* pAT ) @@ -467,17 +482,31 @@ */ if ((pOptions->fOptSet & OPTPROC_SHORTOPT) == 0) fputs( pAT->pzSpc, option_usage_fp ); - else if (! isgraph( pOD->optValue)) { + + else if (! IS_GRAPHIC_CHAR(pOD->optValue)) { if ( (pOptions->fOptSet & (OPTPROC_GNUUSAGE|OPTPROC_LONGOPT)) == (OPTPROC_GNUUSAGE|OPTPROC_LONGOPT)) fputc( ' ', option_usage_fp ); fputs( pAT->pzNoF, option_usage_fp ); + } else { fprintf( option_usage_fp, " -%c", pOD->optValue ); if ( (pOptions->fOptSet & (OPTPROC_GNUUSAGE|OPTPROC_LONGOPT)) == (OPTPROC_GNUUSAGE|OPTPROC_LONGOPT)) fputs( ", ", option_usage_fp ); } +} + +/* + * Print the usage information for a single option. + */ +static void +printOneUsage( + tOptions* pOptions, + tOptDesc* pOD, + arg_types_t* pAT ) +{ + printOptPreamble(pOptions, pOD, pAT); { char z[ 80 ]; @@ -487,20 +516,20 @@ * when the option argument is required, base the type string on the * argument type. */ - if (OPTST_GET_ARGTYPE(pOD->fOptState) == OPARG_TYPE_NONE) { - pzArgType = pAT->pzNo; - - } else if (pOD->fOptState & OPTST_ARG_OPTIONAL) { + if (pOD->fOptState & OPTST_ARG_OPTIONAL) { pzArgType = pAT->pzOpt; } else switch (OPTST_GET_ARGTYPE(pOD->fOptState)) { + case OPARG_TYPE_NONE: pzArgType = pAT->pzNo; break; case OPARG_TYPE_ENUMERATION: pzArgType = pAT->pzKey; break; + case OPARG_TYPE_FILE : pzArgType = pAT->pzFile; break; case OPARG_TYPE_MEMBERSHIP: pzArgType = pAT->pzKeyL; break; case OPARG_TYPE_BOOLEAN: pzArgType = pAT->pzBool; break; case OPARG_TYPE_NUMERIC: pzArgType = pAT->pzNum; break; case OPARG_TYPE_HIERARCHY: pzArgType = pAT->pzNest; break; case OPARG_TYPE_STRING: pzArgType = pAT->pzStr; break; - default: goto bogus_desc; break; + case OPARG_TYPE_TIME: pzArgType = pAT->pzTime; break; + default: goto bogus_desc; } snprintf( z, sizeof(z), pAT->pzOptFmt, pzArgType, pOD->pz_Name, @@ -527,18 +556,36 @@ */ static void printOptionUsage( - tOptions* pOpts, - int ex_code, - tCC* pOptTitle ) + tOptions * pOpts, + int ex_code, + tCC * pOptTitle ) { - int ct = pOpts->optCt; - int optNo = 0; - tOptDesc* pOD = pOpts->pOptDesc; - int docCt = 0; + int ct = pOpts->optCt; + int optNo = 0; + tOptDesc * pOD = pOpts->pOptDesc; + int docCt = 0; do { - if ((pOD->fOptState & OPTST_OMITTED) != 0) + if ((pOD->fOptState & OPTST_NO_USAGE_MASK) != 0) { + + /* + * IF this is a compiled-out option + * *AND* usage was requested with "omitted-usage" + * *AND* this is NOT abbreviated usage + * THEN display this option. + */ + if ( (pOD->fOptState == (OPTST_OMITTED | OPTST_NO_INIT)) + && (pOD->pz_Name != NULL) + && (ex_code == EXIT_SUCCESS)) { + + char const * why_pz = + (pOD->pzText == NULL) ? zDisabledWhy : pOD->pzText; + printOptPreamble(pOpts, pOD, &argTypes); + fprintf(option_usage_fp, zDisabledOpt, pOD->pz_Name, why_pz); + } + continue; + } if ((pOD->fOptState & OPTST_DOCUMENT) != 0) { if (ex_code == EXIT_SUCCESS) { @@ -558,12 +605,12 @@ * THEN document that the remaining options are not user opts */ if ( (pOpts->presetOptCt == optNo) - && (ex_code == EXIT_SUCCESS) - && (docCt > 0) - && ((pOD[-1].fOptState & OPTST_DOCUMENT) == 0) ) + && (ex_code == EXIT_SUCCESS) + && (docCt > 0) + && ((pOD[-1].fOptState & OPTST_DOCUMENT) == 0) ) fprintf( option_usage_fp, argTypes.pzBrk, zAuto, pOptTitle ); - printOneUsage( pOpts, pOD, &argTypes ); + printOneUsage(pOpts, pOD, &argTypes); /* * IF we were invoked because of the --help option, @@ -619,7 +666,7 @@ switch (OPTST_GET_ARGTYPE(pOD->fOptState)) { case OPARG_TYPE_ENUMERATION: case OPARG_TYPE_MEMBERSHIP: - (*(pOD->pOptProc))( NULL, pOD ); + (*(pOD->pOptProc))(OPTPROC_EMIT_USAGE, pOD); } } while (pOD++, optNo++, (--ct > 0)); } @@ -657,6 +704,8 @@ argTypes.pzNum = zGnuNumArg; argTypes.pzKey = zGnuKeyArg; argTypes.pzKeyL = zGnuKeyLArg; + argTypes.pzTime = zGnuTimeArg; + argTypes.pzFile = zGnuFileArg; argTypes.pzBool = zGnuBoolArg; argTypes.pzNest = zGnuNestArg; argTypes.pzOpt = zGnuOptArg; @@ -694,6 +743,8 @@ argTypes.pzNum = zStdNumArg; argTypes.pzKey = zStdKeyArg; argTypes.pzKeyL = zStdKeyLArg; + argTypes.pzTime = zStdTimeArg; + argTypes.pzFile = zStdFileArg; argTypes.pzBool = zStdBoolArg; argTypes.pzNest = zStdNestArg; argTypes.pzOpt = zStdOptArg; diff -urN src/contrib/ntp/sntp/libopts/value-type.c src.ntp/contrib/ntp/sntp/libopts/value-type.c --- src/contrib/ntp/sntp/libopts/value-type.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/libopts/value-type.c 2009-12-09 08:36:46.000000000 +0100 @@ -0,0 +1,120 @@ +/* ANSI-C code produced by gperf version 3.0.2 */ + + +#if 0 /* gperf build options: */ +// %struct-type +// %language=ANSI-C +// %includes +// %global-table +// %omit-struct-type +// %readonly-tables +// %compare-strncmp +// +// %define slot-name vtp_name +// %define hash-function-name value_type_hash +// %define lookup-function-name find_value_type_name +// %define word-array-name value_type_table +// %define initializer-suffix ,VTP_COUNT_KWD +#endif /* gperf build options: */ + +#include "value-type.h" + +typedef struct { + char const * vtp_name; + value_type_enum_t vtp_id; +} value_type_map_t; +#include + +/* maximum key range = 20, duplicates = 0 */ + +#ifdef __GNUC__ +#else +#ifdef __cplusplus +#endif +#endif +inline static unsigned int +value_type_hash (register const char *str, register unsigned int len) +{ + static const unsigned char asso_values[] = + { + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 10, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 5, 23, 23, 5, 0, 0, 23, 15, 23, + 23, 10, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, + 23, 23, 23, 23, 23, 23 + }; + return len + asso_values[(unsigned char)str[2]]; +} + +static const value_type_map_t value_type_table[] = + { + {"",VTP_COUNT_KWD}, {"",VTP_COUNT_KWD}, + {"",VTP_COUNT_KWD}, + {"set", VTP_KWD_SET}, + {"",VTP_COUNT_KWD}, {"",VTP_COUNT_KWD}, + {"nested", VTP_KWD_NESTED}, + {"integer", VTP_KWD_INTEGER}, + {"",VTP_COUNT_KWD}, + {"bool", VTP_KWD_BOOL}, + {"",VTP_COUNT_KWD}, + {"string", VTP_KWD_STRING}, + {"boolean", VTP_KWD_BOOLEAN}, + {"",VTP_COUNT_KWD}, + {"set-membership", VTP_KWD_SET_MEMBERSHIP}, + {"",VTP_COUNT_KWD}, {"",VTP_COUNT_KWD}, + {"keyword", VTP_KWD_KEYWORD}, + {"",VTP_COUNT_KWD}, + {"hierarchy", VTP_KWD_HIERARCHY}, + {"",VTP_COUNT_KWD}, {"",VTP_COUNT_KWD}, + {"invalid", VTP_KWD_INVALID} + }; + +#ifdef __GNUC__ +#endif +static inline const value_type_map_t * +find_value_type_name (register const char *str, register unsigned int len) +{ + if (len <= 14 && len >= 3) + { + register int key = value_type_hash (str, len); + + if (key <= 22 && key >= 0) + { + register const char *s = value_type_table[key].vtp_name; + + if (*str == *s && !strncmp (str + 1, s + 1, len - 1) && s[len] == '\0') + return &value_type_table[key]; + } + } + return 0; +} + + +value_type_enum_t +find_value_type_id(char const * str, unsigned int len) +{ + const value_type_map_t * p = + find_value_type_name(str, len); + return (p == 0) ? VTP_KWD_INVALID : p->vtp_id; +} diff -urN src/contrib/ntp/sntp/libopts/value-type.h src.ntp/contrib/ntp/sntp/libopts/value-type.h --- src/contrib/ntp/sntp/libopts/value-type.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/libopts/value-type.h 2009-12-09 08:36:46.000000000 +0100 @@ -0,0 +1,25 @@ +/* + * Generated header for gperf generated source Sun Nov 8 08:41:19 PST 2009 + * This file enumerates the list of names and declares the + * procedure for mapping string names to the enum value. + */ +#ifndef AUTOOPTS_VALUE_TYPE_H_GUARD +#define AUTOOPTS_VALUE_TYPE_H_GUARD 1 + +typedef enum { + VTP_KWD_INVALID, + VTP_KWD_STRING, + VTP_KWD_INTEGER, + VTP_KWD_BOOLEAN, + VTP_KWD_BOOL, + VTP_KWD_KEYWORD, + VTP_KWD_SET, + VTP_KWD_SET_MEMBERSHIP, + VTP_KWD_NESTED, + VTP_KWD_HIERARCHY, + VTP_COUNT_KWD +} value_type_enum_t; + +extern value_type_enum_t +find_value_type_id(char const * str, unsigned int len); +#endif /* AUTOOPTS_VALUE_TYPE_H_GUARD */ diff -urN src/contrib/ntp/sntp/libopts/version.c src.ntp/contrib/ntp/sntp/libopts/version.c --- src/contrib/ntp/sntp/libopts/version.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/libopts/version.c 2009-12-09 08:36:46.000000000 +0100 @@ -1,56 +1,35 @@ -/* $Id: version.c,v 4.10 2007/04/28 22:19:23 bkorb Exp $ - * Time-stamp: "2007-04-28 10:08:34 bkorb" +/* $Id: e21e2bf9958c54e440efbdc7c1026e46ac589f66 $ + * Time-stamp: "2008-07-27 10:11:30 bkorb" * * This module implements the default usage procedure for * Automated Options. It may be overridden, of course. */ -static char const zAOV[] = - "Automated Options version %s, copyright (c) 1999-2007 Bruce Korb\n"; - -/* Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. +/* + * This file is part of AutoOpts, a companion to AutoGen. + * AutoOpts is free software. + * AutoOpts is copyright (c) 1992-2009 by Bruce Korb - all rights reserved + * + * AutoOpts is available under any one of two licenses. The license + * in use must be one of these two and the choice is under the control + * of the user of the license. + * + * The GNU Lesser General Public License, version 3 or later + * See the files "COPYING.lgplv3" and "COPYING.gplv3" + * + * The Modified Berkeley Software Distribution License + * See the file "COPYING.mbsd" + * + * These files have the following md5sums: + * + * 43b91e8ca915626ed3818ffb1b71248b pkg/libopts/COPYING.gplv3 + * 06a1a2e4760c90ea5e1dad8dfaac4d39 pkg/libopts/COPYING.lgplv3 + * 66a5cedaf62c4b2637025f049f9b826f pkg/libopts/COPYING.mbsd */ /* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ +/* static forward declarations maintained by mk-fwd */ static void printVersion( tOptions* pOpts, tOptDesc* pOD, FILE* fp ); /* = = = END-STATIC-FORWARD = = = */ @@ -107,7 +86,7 @@ fputs( pOpts->pzCopyright, fp ); fputc( '\n', fp ); } - fprintf( fp, zAOV, optionVersion() ); + fprintf( fp, zAO_Ver, optionVersion() ); if (pOpts->pzBugAddr != NULL) fprintf( fp, zPlsSendBugs, pOpts->pzBugAddr ); break; @@ -124,7 +103,7 @@ fputc( '\n', fp ); } - fprintf( fp, zAOV, optionVersion() ); + fprintf( fp, zAO_Ver, optionVersion() ); if (pOpts->pzBugAddr != NULL) fprintf( fp, zPlsSendBugs, pOpts->pzBugAddr ); break; diff -urN src/contrib/ntp/sntp/libopts/xat-attribute.c src.ntp/contrib/ntp/sntp/libopts/xat-attribute.c --- src/contrib/ntp/sntp/libopts/xat-attribute.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/libopts/xat-attribute.c 2009-12-09 08:36:46.000000000 +0100 @@ -0,0 +1,111 @@ +/* ANSI-C code produced by gperf version 3.0.2 */ + + +#if 0 /* gperf build options: */ +// %struct-type +// %language=ANSI-C +// %includes +// %global-table +// %omit-struct-type +// %readonly-tables +// %compare-strncmp +// +// %define slot-name xat_name +// %define hash-function-name xat_attribute_hash +// %define lookup-function-name find_xat_attribute_name +// %define word-array-name xat_attribute_table +// %define initializer-suffix ,XAT_COUNT_KWD +#endif /* gperf build options: */ + +#include "xat-attribute.h" + +typedef struct { + char const * xat_name; + xat_attribute_enum_t xat_id; +} xat_attribute_map_t; +#include + +/* maximum key range = 9, duplicates = 0 */ + +#ifdef __GNUC__ +#else +#ifdef __cplusplus +#endif +#endif +inline static unsigned int +xat_attribute_hash (register const char *str, register unsigned int len) +{ + static const unsigned char asso_values[] = + { + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 0, + 13, 13, 13, 13, 13, 5, 13, 5, 13, 0, + 13, 13, 13, 13, 13, 13, 0, 0, 13, 0, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13 + }; + return len + asso_values[(unsigned char)str[0]]; +} + +static const xat_attribute_map_t xat_attribute_table[] = + { + {"",XAT_COUNT_KWD}, {"",XAT_COUNT_KWD}, + {"",XAT_COUNT_KWD}, {"",XAT_COUNT_KWD}, + {"type", XAT_KWD_TYPE}, + {"words", XAT_KWD_WORDS}, + {"cooked", XAT_KWD_COOKED}, + {"members", XAT_KWD_MEMBERS}, + {"uncooked", XAT_KWD_UNCOOKED}, + {"keep", XAT_KWD_KEEP}, + {"",XAT_COUNT_KWD}, {"",XAT_COUNT_KWD}, + {"invalid", XAT_KWD_INVALID} + }; + +#ifdef __GNUC__ +#endif +static inline const xat_attribute_map_t * +find_xat_attribute_name (register const char *str, register unsigned int len) +{ + if (len <= 8 && len >= 4) + { + register int key = xat_attribute_hash (str, len); + + if (key <= 12 && key >= 0) + { + register const char *s = xat_attribute_table[key].xat_name; + + if (*str == *s && !strncmp (str + 1, s + 1, len - 1) && s[len] == '\0') + return &xat_attribute_table[key]; + } + } + return 0; +} + + +xat_attribute_enum_t +find_xat_attribute_id(char const * str, unsigned int len) +{ + const xat_attribute_map_t * p = + find_xat_attribute_name(str, len); + return (p == 0) ? XAT_KWD_INVALID : p->xat_id; +} diff -urN src/contrib/ntp/sntp/libopts/xat-attribute.h src.ntp/contrib/ntp/sntp/libopts/xat-attribute.h --- src/contrib/ntp/sntp/libopts/xat-attribute.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/libopts/xat-attribute.h 2009-12-09 08:36:46.000000000 +0100 @@ -0,0 +1,22 @@ +/* + * Generated header for gperf generated source Sun Nov 8 08:41:19 PST 2009 + * This file enumerates the list of names and declares the + * procedure for mapping string names to the enum value. + */ +#ifndef AUTOOPTS_XAT_ATTRIBUTE_H_GUARD +#define AUTOOPTS_XAT_ATTRIBUTE_H_GUARD 1 + +typedef enum { + XAT_KWD_INVALID, + XAT_KWD_TYPE, + XAT_KWD_WORDS, + XAT_KWD_MEMBERS, + XAT_KWD_COOKED, + XAT_KWD_UNCOOKED, + XAT_KWD_KEEP, + XAT_COUNT_KWD +} xat_attribute_enum_t; + +extern xat_attribute_enum_t +find_xat_attribute_id(char const * str, unsigned int len); +#endif /* AUTOOPTS_XAT_ATTRIBUTE_H_GUARD */ diff -urN src/contrib/ntp/sntp/log.c src.ntp/contrib/ntp/sntp/log.c --- src/contrib/ntp/sntp/log.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/log.c 2009-12-09 08:36:46.000000000 +0100 @@ -0,0 +1,78 @@ +#include "log.h" +#include "sntp-opts.h" + +int init = 0; +int filelog = 0; + +FILE *log_file; + + +void log_msg(char *message, char type) { + if(init) { + time_t cur_time = time(NULL); + char *timestamp = ctime(&cur_time); + + fprintf(log_file, "%s: %s\n", timestamp, message); + fflush(log_file); + } + else { + switch(type) { + case 0: + type = LOG_CONS; + break; + + case 1: + type = LOG_DEBUG | LOG_CONS; + break; + + case 2: + type = LOG_WARNING | LOG_CONS; + break; + } + + syslog(type, message); + } +} + +void debug_msg(char *message) { + if(HAVE_OPT(FILELOG)) { + time_t cur_time = time(NULL); + char *timestamp = ctime(&cur_time); + + fprintf(stderr, "%s: %s\n", timestamp, message); + } + else { + syslog(LOG_DEBUG +#ifdef LOG_PERROR + | LOG_PERROR +#endif + | LOG_CONS, message); + } +} + +void init_log( + const char *logfile + ) +{ + char error_msg[80]; + + log_file = fopen(logfile, "a"); + if (log_file == NULL) { + filelog = 0; + + snprintf(error_msg, 80, "init_log(): Cannot open logfile %s", logfile); + debug_msg(error_msg); + + return; + } else { + filelog = 1; + init = 1; + atexit(cleanup_log); + } +} + +void cleanup_log(void) { + init = 0; + fflush(log_file); + fclose(log_file); +} diff -urN src/contrib/ntp/sntp/log.h src.ntp/contrib/ntp/sntp/log.h --- src/contrib/ntp/sntp/log.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/log.h 2009-12-09 08:36:46.000000000 +0100 @@ -0,0 +1,19 @@ +#ifndef LOG_H +#define LOG_H + +#include "config.h" + +#include +#include +#include +#include +#include + + +void log_msg(char *message, char type); +void debug_msg(char *message); + +void init_log(const char *logfile); +void cleanup_log(void); + +#endif diff -urN src/contrib/ntp/sntp/ltmain.sh src.ntp/contrib/ntp/sntp/ltmain.sh --- src/contrib/ntp/sntp/ltmain.sh 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/ltmain.sh 2005-09-24 03:15:44.000000000 +0200 @@ -43,8 +43,8 @@ PROGRAM=ltmain.sh PACKAGE=libtool -VERSION=1.5.22 -TIMESTAMP=" (1.1220.2.365 2005/12/18 22:14:06)" +VERSION=1.5.20 +TIMESTAMP=" (1.1220.2.287 2005/08/31 18:54:15)" # See if we are running on zsh, and set the options which allow our # commands through without removal of \ escapes. @@ -132,8 +132,6 @@ show="$echo" show_help= execute_dlfiles= -duplicate_deps=no -preserve_args= lo2o="s/\\.lo\$/.${objext}/" o2lo="s/\\.${objext}\$/.lo/" @@ -141,43 +139,6 @@ # Shell function definitions: # This seems to be the best place for them -# func_mktempdir [string] -# Make a temporary directory that won't clash with other running -# libtool processes, and avoids race conditions if possible. If -# given, STRING is the basename for that directory. -func_mktempdir () -{ - my_template="${TMPDIR-/tmp}/${1-$progname}" - - if test "$run" = ":"; then - # Return a directory name, but don't create it in dry-run mode - my_tmpdir="${my_template}-$$" - else - - # If mktemp works, use that first and foremost - my_tmpdir=`mktemp -d "${my_template}-XXXXXXXX" 2>/dev/null` - - if test ! -d "$my_tmpdir"; then - # Failing that, at least try and use $RANDOM to avoid a race - my_tmpdir="${my_template}-${RANDOM-0}$$" - - save_mktempdir_umask=`umask` - umask 0077 - $mkdir "$my_tmpdir" - umask $save_mktempdir_umask - fi - - # If we're not in dry-run mode, bomb out on failure - test -d "$my_tmpdir" || { - $echo "cannot create temporary directory \`$my_tmpdir'" 1>&2 - exit $EXIT_FAILURE - } - fi - - $echo "X$my_tmpdir" | $Xsed -} - - # func_win32_libid arg # return the library type of file 'arg' # @@ -196,11 +157,12 @@ if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null | \ $EGREP -e 'file format pe-i386(.*architecture: i386)?' >/dev/null ; then win32_nmres=`eval $NM -f posix -A $1 | \ - $SED -n -e '1,100{/ I /{s,.*,import,;p;q;};}'` - case $win32_nmres in - import*) win32_libid_type="x86 archive import";; - *) win32_libid_type="x86 archive static";; - esac + sed -n -e '1,100{/ I /{x;/import/!{s/^/import/;h;p;};x;};}'` + if test "X$win32_nmres" = "Ximport" ; then + win32_libid_type="x86 archive import" + else + win32_libid_type="x86 archive static" + fi fi ;; *DLL*) @@ -333,9 +295,9 @@ $run ${rm}r "$my_xdir" $show "$mkdir $my_xdir" $run $mkdir "$my_xdir" - exit_status=$? - if test "$exit_status" -ne 0 && test ! -d "$my_xdir"; then - exit $exit_status + status=$? + if test "$status" -ne 0 && test ! -d "$my_xdir"; then + exit $status fi case $host in *-darwin*) @@ -390,8 +352,6 @@ # Darwin sucks eval std_shrext=\"$shrext_cmds\" -disable_libs=no - # Parse our command line options once, thoroughly. while test "$#" -gt 0 do @@ -508,11 +468,7 @@ preserve_args="$preserve_args $arg" ;; - --tag) - prevopt="--tag" - prev=tag - preserve_args="$preserve_args --tag" - ;; + --tag) prevopt="--tag" prev=tag ;; --tag=*) set tag "$optarg" ${1+"$@"} shift @@ -544,18 +500,6 @@ exit $EXIT_FAILURE fi -case $disable_libs in -no) - ;; -shared) - build_libtool_libs=no - build_old_libs=yes - ;; -static) - build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac` - ;; -esac - # If this variable is set in any of the actions, the command in it # will be execed at the end. This prevents here-documents from being # left over by shells. @@ -912,9 +856,9 @@ if test ! -d "${xdir}$objdir"; then $show "$mkdir ${xdir}$objdir" $run $mkdir ${xdir}$objdir - exit_status=$? - if test "$exit_status" -ne 0 && test ! -d "${xdir}$objdir"; then - exit $exit_status + status=$? + if test "$status" -ne 0 && test ! -d "${xdir}$objdir"; then + exit $status fi fi @@ -1117,7 +1061,6 @@ no_install=no objs= non_pic_objects= - notinst_path= # paths that contain not-installed libtool libraries precious_files_regex= prefer_static_libs=no preload=no @@ -1146,15 +1089,14 @@ if test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi - prefer_static_libs=yes else if test -z "$pic_flag" && test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi - prefer_static_libs=built fi build_libtool_libs=no build_old_libs=yes + prefer_static_libs=yes break ;; esac @@ -1329,11 +1271,6 @@ if test -z "$pic_object" || test "$pic_object" = none ; then arg="$non_pic_object" fi - else - # If the PIC object exists, use it instead. - # $xdir was prepended to $pic_object above. - non_pic_object="$pic_object" - non_pic_objects="$non_pic_objects $non_pic_object" fi else # Only an error if not doing a dry-run. @@ -1417,8 +1354,8 @@ prev= continue ;; - darwin_framework|darwin_framework_skip) - test "$prev" = "darwin_framework" && compiler_flags="$compiler_flags $arg" + darwin_framework) + compiler_flags="$compiler_flags $arg" compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" prev= @@ -1482,17 +1419,13 @@ continue ;; - -framework|-arch|-isysroot) - case " $CC " in - *" ${arg} ${1} "* | *" ${arg} ${1} "*) - prev=darwin_framework_skip ;; - *) compiler_flags="$compiler_flags $arg" - prev=darwin_framework ;; - esac + -framework|-arch) + prev=darwin_framework + compiler_flags="$compiler_flags $arg" compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" - continue - ;; + continue + ;; -inst-prefix-dir) prev=inst_prefix @@ -1520,8 +1453,7 @@ absdir=`cd "$dir" && pwd` if test -z "$absdir"; then $echo "$modename: cannot determine absolute directory name of \`$dir'" 1>&2 - absdir="$dir" - notinst_path="$notinst_path $dir" + exit $EXIT_FAILURE fi dir="$absdir" ;; @@ -1535,15 +1467,10 @@ esac case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*) - testbindir=`$echo "X$dir" | $Xsed -e 's*/lib$*/bin*'` case :$dllsearchpath: in *":$dir:"*) ;; *) dllsearchpath="$dllsearchpath:$dir";; esac - case :$dllsearchpath: in - *":$testbindir:"*) ;; - *) dllsearchpath="$dllsearchpath:$testbindir";; - esac ;; esac continue @@ -1552,11 +1479,11 @@ -l*) if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos*) + *-*-cygwin* | *-*-pw32* | *-*-beos*) # These systems don't actually have a C or math library (as such) continue ;; - *-*-os2*) + *-*-mingw* | *-*-os2*) # These systems don't actually have a C library (as such) test "X$arg" = "X-lc" && continue ;; @@ -1568,15 +1495,6 @@ # Rhapsody C and math libraries are in the System framework deplibs="$deplibs -framework System" continue - ;; - *-*-sco3.2v5* | *-*-sco5v6*) - # Causes problems with __ctype - test "X$arg" = "X-lc" && continue - ;; - *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) - # Compiler inserts libc in the correct place for threads to work - test "X$arg" = "X-lc" && continue - ;; esac elif test "X$arg" = "X-lc_r"; then case $host in @@ -1618,12 +1536,7 @@ # +DA*, +DD* enable 64-bit mode on the HP compiler # -q* pass through compiler args for the IBM compiler # -m* pass through architecture-specific compiler args for GCC - # -m*, -t[45]*, -txscale* pass through architecture-specific - # compiler args for GCC - # -pg pass through profiling flag for GCC - # @file GCC response files - -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*|-pg| \ - -t[45]*|-txscale*|@*) + -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*) # Unknown arguments in both finalize_command and compile_command need # to be aesthetically quoted because they are evaled later. @@ -1635,7 +1548,9 @@ esac compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" - compiler_flags="$compiler_flags $arg" + if test "$with_gcc" = "yes" ; then + compiler_flags="$compiler_flags $arg" + fi continue ;; @@ -1873,11 +1788,6 @@ if test -z "$pic_object" || test "$pic_object" = none ; then arg="$non_pic_object" fi - else - # If the PIC object exists, use it instead. - # $xdir was prepended to $pic_object above. - non_pic_object="$pic_object" - non_pic_objects="$non_pic_objects $non_pic_object" fi else # Only an error if not doing a dry-run. @@ -1983,9 +1893,9 @@ if test ! -d "$output_objdir"; then $show "$mkdir $output_objdir" $run $mkdir $output_objdir - exit_status=$? - if test "$exit_status" -ne 0 && test ! -d "$output_objdir"; then - exit $exit_status + status=$? + if test "$status" -ne 0 && test ! -d "$output_objdir"; then + exit $status fi fi @@ -2048,6 +1958,7 @@ newlib_search_path= need_relink=no # whether we're linking any uninstalled libtool libraries notinst_deplibs= # not-installed libtool libraries + notinst_path= # paths that contain not-installed libtool libraries case $linkmode in lib) passes="conv link" @@ -2283,7 +2194,7 @@ esac # case $deplib if test "$found" = yes || test -f "$lib"; then : else - $echo "$modename: cannot find the library \`$lib' or unhandled argument \`$deplib'" 1>&2 + $echo "$modename: cannot find the library \`$lib'" 1>&2 exit $EXIT_FAILURE fi @@ -2534,12 +2445,8 @@ fi link_static=no # Whether the deplib will be linked statically - use_static_libs=$prefer_static_libs - if test "$use_static_libs" = built && test "$installed" = yes ; then - use_static_libs=no - fi if test -n "$library_names" && - { test "$use_static_libs" = no || test -z "$old_library"; }; then + { test "$prefer_static_libs" = no || test -z "$old_library"; }; then if test "$installed" = no; then notinst_deplibs="$notinst_deplibs $lib" need_relink=yes @@ -2652,15 +2559,11 @@ if test "$hardcode_direct" = no; then add="$dir/$linklib" case $host in - *-*-sco3.2v5.0.[024]*) add_dir="-L$dir" ;; - *-*-sysv4*uw2*) add_dir="-L$dir" ;; - *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \ - *-*-unixware7*) add_dir="-L$dir" ;; + *-*-sco3.2v5* ) add_dir="-L$dir" ;; *-*-darwin* ) # if the lib is a module then we can not link against # it, someone is ignoring the new warnings I added - if /usr/bin/file -L $add 2> /dev/null | - $EGREP ": [^:]* bundle" >/dev/null ; then + if /usr/bin/file -L $add 2> /dev/null | $EGREP "bundle" >/dev/null ; then $echo "** Warning, lib $linklib is a module, not a shared library" if test -z "$old_library" ; then $echo @@ -3411,9 +3314,9 @@ # Eliminate all temporary directories. for path in $notinst_path; do - lib_search_path=`$echo "$lib_search_path " | ${SED} -e "s% $path % %g"` - deplibs=`$echo "$deplibs " | ${SED} -e "s% -L$path % %g"` - dependency_libs=`$echo "$dependency_libs " | ${SED} -e "s% -L$path % %g"` + lib_search_path=`$echo "$lib_search_path " | ${SED} -e 's% $path % %g'` + deplibs=`$echo "$deplibs " | ${SED} -e 's% -L$path % %g'` + dependency_libs=`$echo "$dependency_libs " | ${SED} -e 's% -L$path % %g'` done if test -n "$xrpath"; then @@ -3466,12 +3369,7 @@ ;; *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) # Do not include libc due to us having libc/libc_r. - ;; - *-*-sco3.2v5* | *-*-sco5v6*) - # Causes problems with __ctype - ;; - *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) - # Compiler inserts libc in the correct place for threads to work + test "X$arg" = "X-lc" && continue ;; *) # Add libc to deplibs on all other systems if necessary. @@ -3515,7 +3413,7 @@ int main() { return 0; } EOF $rm conftest - $LTCC $LTCFLAGS -o conftest conftest.c $deplibs + $LTCC -o conftest conftest.c $deplibs if test "$?" -eq 0 ; then ldd_output=`ldd conftest` for i in $deplibs; do @@ -3560,7 +3458,7 @@ # If $name is empty we are operating on a -L argument. if test "$name" != "" && test "$name" != "0"; then $rm conftest - $LTCC $LTCFLAGS -o conftest conftest.c $i + $LTCC -o conftest conftest.c $i # Did it work? if test "$?" -eq 0 ; then ldd_output=`ldd conftest` @@ -3807,35 +3705,6 @@ deplibs=$newdeplibs fi - - # move library search paths that coincide with paths to not yet - # installed libraries to the beginning of the library search list - new_libs= - for path in $notinst_path; do - case " $new_libs " in - *" -L$path/$objdir "*) ;; - *) - case " $deplibs " in - *" -L$path/$objdir "*) - new_libs="$new_libs -L$path/$objdir" ;; - esac - ;; - esac - done - for deplib in $deplibs; do - case $deplib in - -L*) - case " $new_libs " in - *" $deplib "*) ;; - *) new_libs="$new_libs $deplib" ;; - esac - ;; - *) new_libs="$new_libs $deplib" ;; - esac - done - deplibs="$new_libs" - - # All the library-specific variables (install_libdir is set above). library_names= old_library= @@ -3919,7 +3788,6 @@ fi lib="$output_objdir/$realname" - linknames= for link do linknames="$linknames $link" @@ -4351,35 +4219,6 @@ ;; esac - - # move library search paths that coincide with paths to not yet - # installed libraries to the beginning of the library search list - new_libs= - for path in $notinst_path; do - case " $new_libs " in - *" -L$path/$objdir "*) ;; - *) - case " $compile_deplibs " in - *" -L$path/$objdir "*) - new_libs="$new_libs -L$path/$objdir" ;; - esac - ;; - esac - done - for deplib in $compile_deplibs; do - case $deplib in - -L*) - case " $new_libs " in - *" $deplib "*) ;; - *) new_libs="$new_libs $deplib" ;; - esac - ;; - *) new_libs="$new_libs $deplib" ;; - esac - done - compile_deplibs="$new_libs" - - compile_command="$compile_command $compile_deplibs" finalize_command="$finalize_command $finalize_deplibs" @@ -4424,15 +4263,10 @@ fi case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*) - testbindir=`$echo "X$libdir" | $Xsed -e 's*/lib$*/bin*'` case :$dllsearchpath: in *":$libdir:"*) ;; *) dllsearchpath="$dllsearchpath:$libdir";; esac - case :$dllsearchpath: in - *":$testbindir:"*) ;; - *) dllsearchpath="$dllsearchpath:$testbindir";; - esac ;; esac done @@ -4549,22 +4383,10 @@ export_symbols="$output_objdir/$outputname.exp" $run $rm $export_symbols $run eval "${SED} -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"' - case $host in - *cygwin* | *mingw* ) - $run eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' - $run eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"' - ;; - esac else - $run eval "${SED} -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"' + $run eval "${SED} -e 's/\([ ][.*^$]\)/\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"' $run eval 'grep -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T' $run eval 'mv "$nlist"T "$nlist"' - case $host in - *cygwin* | *mingw* ) - $run eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' - $run eval 'cat "$nlist" >> "$output_objdir/$outputname.def"' - ;; - esac fi fi @@ -4681,29 +4503,16 @@ esac # Now compile the dynamic symbol file. - $show "(cd $output_objdir && $LTCC $LTCFLAGS -c$no_builtin_flag$pic_flag_for_symtable \"$dlsyms\")" - $run eval '(cd $output_objdir && $LTCC $LTCFLAGS -c$no_builtin_flag$pic_flag_for_symtable "$dlsyms")' || exit $? + $show "(cd $output_objdir && $LTCC -c$no_builtin_flag$pic_flag_for_symtable \"$dlsyms\")" + $run eval '(cd $output_objdir && $LTCC -c$no_builtin_flag$pic_flag_for_symtable "$dlsyms")' || exit $? # Clean up the generated files. $show "$rm $output_objdir/$dlsyms $nlist ${nlist}S ${nlist}T" $run $rm "$output_objdir/$dlsyms" "$nlist" "${nlist}S" "${nlist}T" # Transform the symbol file into the correct name. - case $host in - *cygwin* | *mingw* ) - if test -f "$output_objdir/${outputname}.def" ; then - compile_command=`$echo "X$compile_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}.def $output_objdir/${outputname}S.${objext}%"` - finalize_command=`$echo "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}.def $output_objdir/${outputname}S.${objext}%"` - else - compile_command=`$echo "X$compile_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%"` - finalize_command=`$echo "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%"` - fi - ;; - * ) - compile_command=`$echo "X$compile_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%"` - finalize_command=`$echo "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%"` - ;; - esac + compile_command=`$echo "X$compile_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%"` + finalize_command=`$echo "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%"` ;; *) $echo "$modename: unknown suffix for \`$dlsyms'" 1>&2 @@ -4728,7 +4537,7 @@ # We have no uninstalled library dependencies, so finalize right now. $show "$link_command" $run eval "$link_command" - exit_status=$? + status=$? # Delete the generated files. if test -n "$dlsyms"; then @@ -4736,7 +4545,7 @@ $run $rm "$output_objdir/${outputname}S.${objext}" fi - exit $exit_status + exit $status fi if test -n "$shlibpath_var"; then @@ -4876,12 +4685,10 @@ esac case $host in *cygwin* | *mingw* ) - output_name=`basename $output` - output_path=`dirname $output` - cwrappersource="$output_path/$objdir/lt-$output_name.c" - cwrapper="$output_path/$output_name.exe" - $rm $cwrappersource $cwrapper - trap "$rm $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15 + cwrappersource=`$echo ${objdir}/lt-${outputname}.c` + cwrapper=`$echo ${output}.exe` + $rm $cwrappersource $cwrapper + trap "$rm $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15 cat > $cwrappersource < #include #include -#include -#include -#include #if defined(PATH_MAX) # define LT_PATHMAX PATH_MAX @@ -4919,19 +4723,15 @@ #endif #ifndef DIR_SEPARATOR -# define DIR_SEPARATOR '/' -# define PATH_SEPARATOR ':' +#define DIR_SEPARATOR '/' #endif #if defined (_WIN32) || defined (__MSDOS__) || defined (__DJGPP__) || \ defined (__OS2__) -# define HAVE_DOS_BASED_FILE_SYSTEM -# ifndef DIR_SEPARATOR_2 -# define DIR_SEPARATOR_2 '\\' -# endif -# ifndef PATH_SEPARATOR_2 -# define PATH_SEPARATOR_2 ';' -# endif +#define HAVE_DOS_BASED_FILE_SYSTEM +#ifndef DIR_SEPARATOR_2 +#define DIR_SEPARATOR_2 '\\' +#endif #endif #ifndef DIR_SEPARATOR_2 @@ -4941,32 +4741,17 @@ (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2)) #endif /* DIR_SEPARATOR_2 */ -#ifndef PATH_SEPARATOR_2 -# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR) -#else /* PATH_SEPARATOR_2 */ -# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2) -#endif /* PATH_SEPARATOR_2 */ - #define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type))) #define XFREE(stale) do { \ if (stale) { free ((void *) stale); stale = 0; } \ } while (0) -/* -DDEBUG is fairly common in CFLAGS. */ -#undef DEBUG -#if defined DEBUGWRAPPER -# define DEBUG(format, ...) fprintf(stderr, format, __VA_ARGS__) -#else -# define DEBUG(format, ...) -#endif - const char *program_name = NULL; void * xmalloc (size_t num); char * xstrdup (const char *string); -const char * base_name (const char *name); -char * find_executable(const char *wrapper); -int check_executable(const char *path); +char * basename (const char *name); +char * fnqualify(const char *path); char * strendzap(char *str, const char *pat); void lt_fatal (const char *message, ...); @@ -4976,50 +4761,29 @@ char **newargz; int i; - program_name = (char *) xstrdup (base_name (argv[0])); - DEBUG("(main) argv[0] : %s\n",argv[0]); - DEBUG("(main) program_name : %s\n",program_name); + program_name = (char *) xstrdup ((char *) basename (argv[0])); newargz = XMALLOC(char *, argc+2); EOF - cat >> $cwrappersource <> $cwrappersource <> $cwrappersource <<"EOF" - newargz[1] = find_executable(argv[0]); - if (newargz[1] == NULL) - lt_fatal("Couldn't find %s", argv[0]); - DEBUG("(main) found exe at : %s\n",newargz[1]); + cat >> $cwrappersource <<"EOF" + newargz[1] = fnqualify(argv[0]); /* we know the script has the same name, without the .exe */ /* so make sure newargz[1] doesn't end in .exe */ strendzap(newargz[1],".exe"); for (i = 1; i < argc; i++) newargz[i+1] = xstrdup(argv[i]); newargz[argc+1] = NULL; - - for (i=0; i> $cwrappersource <> $cwrappersource <> $cwrappersource <> $cwrappersource <<"EOF" + cat >> $cwrappersource <<"EOF" return 127; } @@ -5040,148 +4804,48 @@ ; } -const char * -base_name (const char *name) +char * +basename (const char *name) { const char *base; #if defined (HAVE_DOS_BASED_FILE_SYSTEM) /* Skip over the disk name in MSDOS pathnames. */ - if (isalpha ((unsigned char)name[0]) && name[1] == ':') + if (isalpha (name[0]) && name[1] == ':') name += 2; #endif for (base = name; *name; name++) if (IS_DIR_SEPARATOR (*name)) base = name + 1; - return base; + return (char *) base; } -int -check_executable(const char * path) -{ - struct stat st; - - DEBUG("(check_executable) : %s\n", path ? (*path ? path : "EMPTY!") : "NULL!"); - if ((!path) || (!*path)) - return 0; - - if ((stat (path, &st) >= 0) && - ( - /* MinGW & native WIN32 do not support S_IXOTH or S_IXGRP */ -#if defined (S_IXOTH) - ((st.st_mode & S_IXOTH) == S_IXOTH) || -#endif -#if defined (S_IXGRP) - ((st.st_mode & S_IXGRP) == S_IXGRP) || -#endif - ((st.st_mode & S_IXUSR) == S_IXUSR)) - ) - return 1; - else - return 0; -} - -/* Searches for the full path of the wrapper. Returns - newly allocated full path name if found, NULL otherwise */ char * -find_executable (const char* wrapper) +fnqualify(const char *path) { - int has_slash = 0; - const char* p; - const char* p_next; - /* static buffer for getcwd */ + size_t size; + char *p; char tmp[LT_PATHMAX + 1]; - int tmp_len; - char* concat_name; - - DEBUG("(find_executable) : %s\n", wrapper ? (*wrapper ? wrapper : "EMPTY!") : "NULL!"); - if ((wrapper == NULL) || (*wrapper == '\0')) - return NULL; + assert(path != NULL); - /* Absolute path? */ -#if defined (HAVE_DOS_BASED_FILE_SYSTEM) - if (isalpha ((unsigned char)wrapper[0]) && wrapper[1] == ':') - { - concat_name = xstrdup (wrapper); - if (check_executable(concat_name)) - return concat_name; - XFREE(concat_name); - } - else - { -#endif - if (IS_DIR_SEPARATOR (wrapper[0])) - { - concat_name = xstrdup (wrapper); - if (check_executable(concat_name)) - return concat_name; - XFREE(concat_name); - } + /* Is it qualified already? */ #if defined (HAVE_DOS_BASED_FILE_SYSTEM) - } + if (isalpha (path[0]) && path[1] == ':') + return xstrdup (path); #endif + if (IS_DIR_SEPARATOR (path[0])) + return xstrdup (path); - for (p = wrapper; *p; p++) - if (*p == '/') - { - has_slash = 1; - break; - } - if (!has_slash) - { - /* no slashes; search PATH */ - const char* path = getenv ("PATH"); - if (path != NULL) - { - for (p = path; *p; p = p_next) - { - const char* q; - size_t p_len; - for (q = p; *q; q++) - if (IS_PATH_SEPARATOR(*q)) - break; - p_len = q - p; - p_next = (*q == '\0' ? q : q + 1); - if (p_len == 0) - { - /* empty path: current directory */ - if (getcwd (tmp, LT_PATHMAX) == NULL) - lt_fatal ("getcwd failed"); - tmp_len = strlen(tmp); - concat_name = XMALLOC(char, tmp_len + 1 + strlen(wrapper) + 1); - memcpy (concat_name, tmp, tmp_len); - concat_name[tmp_len] = '/'; - strcpy (concat_name + tmp_len + 1, wrapper); - } - else - { - concat_name = XMALLOC(char, p_len + 1 + strlen(wrapper) + 1); - memcpy (concat_name, p, p_len); - concat_name[p_len] = '/'; - strcpy (concat_name + p_len + 1, wrapper); - } - if (check_executable(concat_name)) - return concat_name; - XFREE(concat_name); - } - } - /* not found in PATH; assume curdir */ - } - /* Relative path | not found in path: prepend cwd */ + /* prepend the current directory */ + /* doesn't handle '~' */ if (getcwd (tmp, LT_PATHMAX) == NULL) lt_fatal ("getcwd failed"); - tmp_len = strlen(tmp); - concat_name = XMALLOC(char, tmp_len + 1 + strlen(wrapper) + 1); - memcpy (concat_name, tmp, tmp_len); - concat_name[tmp_len] = '/'; - strcpy (concat_name + tmp_len + 1, wrapper); - - if (check_executable(concat_name)) - return concat_name; - XFREE(concat_name); - return NULL; + size = strlen(tmp) + 1 + strlen(path) + 1; /* +2 for '/' and '\0' */ + p = XMALLOC(char, size); + sprintf(p, "%s%c%s", tmp, DIR_SEPARATOR, path); + return p; } char * @@ -5225,16 +4889,16 @@ va_end (ap); } EOF - # we should really use a build-platform specific compiler - # here, but OTOH, the wrappers (shell script and this C one) - # are only useful if you want to execute the "real" binary. - # Since the "real" binary is built for $host, then this - # wrapper might as well be built for $host, too. - $run $LTCC $LTCFLAGS -s -o $cwrapper $cwrappersource - ;; - esac - $rm $output - trap "$rm $output; exit $EXIT_FAILURE" 1 2 15 + # we should really use a build-platform specific compiler + # here, but OTOH, the wrappers (shell script and this C one) + # are only useful if you want to execute the "real" binary. + # Since the "real" binary is built for $host, then this + # wrapper might as well be built for $host, too. + $run $LTCC -s -o $cwrapper $cwrappersource + ;; + esac + $rm $output + trap "$rm $output; exit $EXIT_FAILURE" 1 2 15 $echo > $output "\ #! $SHELL @@ -5464,9 +5128,9 @@ $run ${rm}r "$gentop" $show "$mkdir $gentop" $run $mkdir "$gentop" - exit_status=$? - if test "$exit_status" -ne 0 && test ! -d "$gentop"; then - exit $exit_status + status=$? + if test "$status" -ne 0 && test ! -d "$gentop"; then + exit $status fi fi @@ -6133,7 +5797,18 @@ outputname= if test "$fast_install" = no && test -n "$relink_command"; then if test "$finalize" = yes && test -z "$run"; then - tmpdir=`func_mktempdir` + tmpdir="/tmp" + test -n "$TMPDIR" && tmpdir="$TMPDIR" + tmpdir="$tmpdir/libtool-$$" + save_umask=`umask` + umask 0077 + if $mkdir "$tmpdir"; then + umask $save_umask + else + umask $save_umask + $echo "$modename: error: cannot create temporary directory \`$tmpdir'" 1>&2 + continue + fi file=`$echo "X$file$stripped_ext" | $Xsed -e 's%^.*/%%'` outputname="$tmpdir/$file" # Replace the output file specification. @@ -6257,7 +5932,7 @@ # Exit here if they wanted silent mode. test "$show" = : && exit $EXIT_SUCCESS - $echo "X----------------------------------------------------------------------" | $Xsed + $echo "----------------------------------------------------------------------" $echo "Libraries have been installed in:" for libdir in $libdirs; do $echo " $libdir" @@ -6290,7 +5965,7 @@ $echo $echo "See any operating system documentation about shared libraries for" $echo "more information, such as the ld(1) and ld.so(8) manual pages." - $echo "X----------------------------------------------------------------------" | $Xsed + $echo "----------------------------------------------------------------------" exit $EXIT_SUCCESS ;; @@ -6507,17 +6182,9 @@ rmfiles="$rmfiles $objdir/$n" done test -n "$old_library" && rmfiles="$rmfiles $objdir/$old_library" + test "$mode" = clean && rmfiles="$rmfiles $objdir/$name $objdir/${name}i" - case "$mode" in - clean) - case " $library_names " in - # " " in the beginning catches empty $dlname - *" $dlname "*) ;; - *) rmfiles="$rmfiles $objdir/$dlname" ;; - esac - test -n "$libdir" && rmfiles="$rmfiles $objdir/$name $objdir/${name}i" - ;; - uninstall) + if test "$mode" = uninstall; then if test -n "$library_names"; then # Do each command in the postuninstall commands. cmds=$postuninstall_cmds @@ -6550,8 +6217,7 @@ IFS="$save_ifs" fi # FIXME: should reinstall the best remaining shared library. - ;; - esac + fi fi ;; @@ -6850,11 +6516,12 @@ # configuration. But we'll never go from static-only to shared-only. # ### BEGIN LIBTOOL TAG CONFIG: disable-shared -disable_libs=shared +build_libtool_libs=no +build_old_libs=yes # ### END LIBTOOL TAG CONFIG: disable-shared # ### BEGIN LIBTOOL TAG CONFIG: disable-static -disable_libs=static +build_old_libs=`case $build_libtool_libs in yes) $echo no;; *) $echo yes;; esac` # ### END LIBTOOL TAG CONFIG: disable-static # Local Variables: diff -urN src/contrib/ntp/sntp/main.c src.ntp/contrib/ntp/sntp/main.c --- src/contrib/ntp/sntp/main.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/main.c 2010-05-11 09:46:54.000000000 +0200 @@ -1,1735 +1,422 @@ -/* Copyright (C) 1996, 1997, 2000 N.M. Maclaren - Copyright (C) 1996, 1997, 2000 The University of Cambridge - -This is a complete SNTP implementation, which was easier to write than to port -xntp to a new version of Unix with any hope of maintaining it thereafter. It -supports the full SNTP (RFC 2030) client- and server-side challenge-response -and broadcast protocols. It should achieve nearly optimal accuracy with very -few transactions, provided only that a client has access to a trusted server -and that communications are not INVARIABLY slow. As this is the environment in -which 90-99% of all NTP systems are run .... - -The specification of this program is: - - sntp [ --help | -h | -? ] [ -v | -V | -W ] - [ -q [ -f savefile ] | - [ { -r | -a } [ -P prompt ] [ -l lockfile ] ] - [ -c count ] [ -e minerr ][ -E maxerr ] - [ -d delay | -x [ separation ] [ -f savefile ] ] - [ -4 | -6 ] [ address(es) ] ] - - --help, -h and -? all print the syntax of the command. - - -v indicates that diagnostic messages should be written to standard error, -and -V requests more output for investigating apparently inconsistent -timestamps. -W requests very verbose debugging output, and will interfere with -the timing when writing to the terminal (because of line buffered output from -C); it is useful only when debugging the source. Note that the times produced -by -V and -W are the corrections needed, and not the error in the local clock. - - -q indicates that it will query a savefile that is being maintained by -it being run in daemon mode. - - The default is that it should behave as a client, and the following options -are then relevant: - - -r indicates that the system clock should be reset by 'settimeofday'. -Naturally, this will work only if the user has enough privilege. - - -a indicates that the system clock should be reset by 'adjtime'. -Naturally, this will work only if the user has enough privilege. - - -x indicates that the program should run as a daemon (i.e. forever), and -allow for clock drift. - - -4 or -6 force dns resolving to ipv4 or ipv6 addresses. - - The default is to write the current date and time to the standard output in -a format like '1996 Oct 15 20:17:25.123 + 4.567 +/- 0.089 secs', indicating the -estimated true (local) time and the error in the local clock. In daemon mode, -it will add drift information in a format like ' + 1.3 +/- 0.1 ppm', and -display this at roughly 'separation' intervals. - - 'minerr' is the maximum ignorable variation between the clocks. Acceptable -values are from 0.001 to 1, and the default is 0.1 if 'address' is specified -and 0.5 otherwise. - - 'maxerr' is the maximum value of various delays that are deemed acceptable. -Acceptable values are from 1 to 60, and the default is 5. It should sometimes -be increased if there are problems with the network, NTP server or system -clock, but take care. - - 'prompt' is the maximum clock change that will be made automatically. -Acceptable values are from 1 to 3600, and the default is 30. If the program is -being run interactively, larger values will cause a prompt. The value may also -be 'no', and the change will be made without prompting. - - 'count' is the maximum number of NTP packets to require. Acceptable values -are from 1 to 25 if 'address' is specified and '-x' is not, and from 5 to 25 -otherwise; the default is 5. If the maximum isn't enough, you need a better -consistency algorithm than this program uses. Don't increase it. - - 'delay' is a rough limit on the total running time in seconds. Acceptable -values are from 1 to 3600, and the default is 15 if 'address' is specified and -300 otherwise. - - 'separation' is the time to wait between calls to the server in minutes if -'address' is specified, and the minimum time between broadcast packets if not. -Acceptable values are from 1 to 1440 (a day), and the default is 300. - - 'lockfile' may be used in an update mode to ensure that there is only -one copy of sntp running at once. The default is installation-dependent, -but will usually be /etc/sntp.pid. - - 'savefile' may be used in daemon mode to store a record of previous -packets, which may speed up recalculating the drift after sntp has to be -restarted (e.g. because of network or server outages). The default is -installation-dependent, but will usually be /etc/sntp.state. Note that -there is no locking of this file, and using it twice may cause chaos. - - 'address' is the DNS name or IP number of a host to poll; if no name is -given, the program waits for broadcasts. Note that a single component numeric -address is not allowed. - -For sanity, it is also required that 'minerr' < 'maxerr' < 'delay' (if -listening for broadcasts, 'delay/count' and, in daemon mode, 'separation') and, -for sordid Unixish reasons, that 2*'count' < 'delay'. The last could be fixed, -but isn't worth it. Note that none of the above values are closely linked to -the limits described in the NTP protocol (RFC 1305). Do not increase the -compiled-in bounds excessively, or the code will fail. - -The algorithm used to decide whether to accept a correction is whether it would -seem to improve matters. Unlike the 'xntp' suite, little attempt is made to -handle really knotted scenarios, and diagnostics are written to standard error. -In non-daemon client mode, it is intended to be run as a command or in a 'cron' -job. Unlike 'ntpdate', its default mode is simply to display the clock error. - -It assumes that floating-point arithmetic is tolerably efficient, which is true -for even the cheapest personal computer nowadays. If, however, you want to -port this to a toaster, you may have problems! - -In its terminating modes, its return code is EXIT_SUCCESS if the operation was -completed successfully and EXIT_FAILURE otherwise. - -In daemon mode, it runs for ever and stops with a return code EXIT_FAILURE -only after a severe error. In daemon mode, it will fail if the server is -inaccessible for a long time or seriously sick, and will need manual -restarting. - - -WARNING: this program has reached its 'hack count' and needs restructuring, -badly. Perhaps the worst code is in run_daemon(). You are advised not to -fiddle unless you really have to. */ - - - -#include "header.h" - -#include -#include -#include - -#define MAIN -#include "kludges.h" -#undef MAIN - - - -/* NTP definitions. Note that these assume 8-bit bytes - sigh. There is -little point in parameterising everything, as it is neither feasible nor -useful. It would be very useful if more fields could be defined as -unspecified. The NTP packet-handling routines contain a lot of extra -assumptions. */ - -#define JAN_1970 2208988800.0 /* 1970 - 1900 in seconds */ -#define NTP_SCALE 4294967296.0 /* 2^32, of course! */ - -#define NTP_PACKET_MIN 48 /* Without authentication */ -#define NTP_PACKET_MAX 68 /* With authentication (ignored) */ -#define NTP_DISP_FIELD 8 /* Offset of dispersion field */ -#define NTP_REFERENCE 16 /* Offset of reference timestamp */ -#define NTP_ORIGINATE 24 /* Offset of originate timestamp */ -#define NTP_RECEIVE 32 /* Offset of receive timestamp */ -#define NTP_TRANSMIT 40 /* Offset of transmit timestamp */ - -#define NTP_LI_FUDGE 0 /* The current 'status' */ -#define NTP_VERSION 3 /* The current version */ -#define NTP_VERSION_MAX 4 /* The maximum valid version */ -#define NTP_STRATUM 15 /* The current stratum as a server */ -#define NTP_STRATUM_MAX 15 /* The maximum valid stratum */ -#define NTP_POLLING 8 /* The current 'polling interval' */ -#define NTP_PRECISION 0 /* The current 'precision' - 1 sec. */ - -#define NTP_ACTIVE 1 /* NTP symmetric active request */ -#define NTP_PASSIVE 2 /* NTP symmetric passive response */ -#define NTP_CLIENT 3 /* NTP client request */ -#define NTP_SERVER 4 /* NTP server response */ -#define NTP_BROADCAST 5 /* NTP server broadcast */ - -#define NTP_INSANITY 3600.0 /* Errors beyond this are hopeless */ -#define RESET_MIN 15 /* Minimum period between resets */ -#define ABSCISSA 3.0 /* Scale factor for standard errors */ - - - -/* Local definitions and global variables (mostly options). These are all of -the quantities that control the main actions of the program. The first three -are the only ones that are exported to other modules. */ - -const char *argv0 = NULL; /* For diagnostics only - not NULL */ -int verbose = 0, /* Default = 0, -v = 1, -V = 2, -W = 3 */ - operation = 0; /* Defined in header.h - see action */ -const char *lockname = NULL; /* The name of the lock file */ -int unprivport = 0; /* Use an unpriv port for query? */ - -#define COUNT_MAX 25 /* Do NOT increase this! */ -#define WEEBLE_FACTOR 1.2 /* See run_server() and run_daemon() */ -#define ETHERNET_MAX 5 /* See run_daemon() and run_client() */ - -#define action_display 1 /* Just display the result */ -#define action_reset 2 /* Reset using 'settimeofday' */ -#define action_adjust 3 /* Reset using 'adjtime' */ -#define action_broadcast 4 /* Behave as a server, broadcasting */ -#define action_server 5 /* Behave as a server for clients */ -#define action_query 6 /* Query a daemon savefile */ - -#define save_read_only 1 /* Read the saved state only */ -#define save_read_check 2 /* Read and check it */ -#define save_write 3 /* Write the saved state */ -#define save_clear 4 /* Clear the saved state */ - -static const char version[] = VERSION; /* For reverse engineering :-) */ -static int action = 0, /* Defined above - see operation */ - count = 0, /* -c value in seconds */ - delay = 0, /* -d or -x value in seconds */ - attempts = 0, /* Packets transmitted up to 2*count */ - waiting = 0, /* -d/-c except for in daemon mode */ - locked = 0; /* set_lock(1) has been called */ -static double outgoing[2*COUNT_MAX], /* Transmission timestamps */ - minerr = 0.0, /* -e value in seconds */ - maxerr = 0.0, /* -E value in seconds */ - prompt = 0.0, /* -p value in seconds */ - dispersion = 0.0; /* The source dispersion in seconds */ -static FILE *savefile = NULL; /* Holds the data to restart from */ - - - -/* The unpacked NTP data structure, with all the fields even remotely relevant -to SNTP. */ - -typedef struct NTP_DATA { - unsigned char status, version, mode, stratum, polling; - signed char precision; - double dispersion, reference, originate, receive, transmit, current; -} ntp_data; - - - -/* The following structure is used to keep a record of packets in daemon mode; -it contains only the information that is actually used for the drift and error -calculations. */ - -typedef struct { - double dispersion, weight, when, offset, error; -} data_record; - -void syntax(int); -void display_data(ntp_data *); -void display_packet(unsigned char *, int); -void pack_ntp(unsigned char *, int, ntp_data *); -void unpack_ntp(ntp_data *, unsigned char *, int); -void make_packet(ntp_data *, int); -int read_packet(int, ntp_data *, double *, double *); -void format_time(char *, int, double, double, double, double, int); -double reset_clock(double, double, int); -void run_server(void); -double estimate_stats(int *, int *, data_record *, double, double *, double *, - double *, double *, double *, double *, int *, int); -double correct_drift(double *, double *, double); -void handle_saving(int, int *, int *, int *, data_record *, double *, - double *, double *); -void query_savefile(void); -void run_daemon(char **, int, int); -void run_client(char **, int); - -void fatal (int syserr, const char *message, const char *insert) { - -/* Issue a diagnostic and stop. Be a little paranoid about recursion. */ - - int k = errno; - static int called = 0; - - if (message != NULL) { - fprintf(stderr,"%s: ",argv0); - fprintf(stderr,message,insert); - fprintf(stderr,"\n"); - } - errno = k; - if (syserr) perror(argv0); - if (! called) { - called = 1; - if (savefile != NULL && fclose(savefile)) - fatal(1,"unable to close the daemon save file",NULL); - if (locked) set_lock(0); - } - exit(EXIT_FAILURE); -} - - - -void syntax (int halt) { - -/* The standard, unfriendly Unix error message. Some errors are diagnosed more -helpfully. This is called before any files or sockets are opened. */ - - fprintf(stderr,"Syntax: %s [ --help | -h | -? ] [ -v | -V | -W ] \n",argv0); - fprintf(stderr," [ -q [ -f savefile ] |\n"); - fprintf(stderr," [ { -r | -a } [ -P prompt ] [ -l lockfile ] ]\n"); - fprintf(stderr," [ -c count ] [ -e minerr ] [ -E maxerr ]\n"); - fprintf(stderr," [ -d delay | -x [ separation ] "); - fprintf(stderr,"[ -f savefile ] ]\n"); - fprintf(stderr," [ -4 | -6 ] [-u] [ address(es) ] ]\n"); - if (halt) exit(EXIT_FAILURE); -} - - - -void display_data (ntp_data *data) { - -/* This formats the essential NTP data, as a debugging aid. */ - - fprintf(stderr,"sta=%d ver=%d mod=%d str=%d pol=%d dis=%.6f ref=%.6f\n", - data->status,data->version,data->mode,data->stratum,data->polling, - data->dispersion,data->reference); - fprintf(stderr,"ori=%.6f rec=%.6f\n",data->originate,data->receive); - fprintf(stderr,"tra=%.6f cur=%.6f\n",data->transmit,data->current); -} - - - -void display_packet (unsigned char *packet, int length) { - -/* This formats a possible packet very roughly, as a debugging aid. */ - - int i; - - if (length < NTP_PACKET_MIN || length > NTP_PACKET_MAX) return; - for (i = 0; i < length; ++i) { - if (i != 0 && i%32 == 0) - fprintf(stderr,"\n"); - else if (i != 0 && i%4 == 0) - fprintf(stderr," "); - fprintf(stderr,"%.2x",packet[i]); - } - fprintf(stderr,"\n"); -} - - - -void pack_ntp (unsigned char *packet, int length, ntp_data *data) { - -/* Pack the essential data into an NTP packet, bypassing struct layout and -endian problems. Note that it ignores fields irrelevant to SNTP. */ - - int i, k; - double d; - - memset(packet,0,(size_t)length); - packet[0] = (data->status<<6)|(data->version<<3)|data->mode; - packet[1] = data->stratum; - packet[2] = data->polling; - packet[3] = data->precision; - d = data->originate/NTP_SCALE; - for (i = 0; i < 8; ++i) { - if ((k = (int)(d *= 256.0)) >= 256) k = 255; - packet[NTP_ORIGINATE+i] = k; - d -= k; - } - d = data->receive/NTP_SCALE; - for (i = 0; i < 8; ++i) { - if ((k = (int)(d *= 256.0)) >= 256) k = 255; - packet[NTP_RECEIVE+i] = k; - d -= k; - } - d = data->transmit/NTP_SCALE; - for (i = 0; i < 8; ++i) { - if ((k = (int)(d *= 256.0)) >= 256) k = 255; - packet[NTP_TRANSMIT+i] = k; - d -= k; - } -} - - - -void unpack_ntp (ntp_data *data, unsigned char *packet, int length) { - -/* Unpack the essential data from an NTP packet, bypassing struct layout and -endian problems. Note that it ignores fields irrelevant to SNTP. */ - - int i; - double d; - - data->current = current_time(JAN_1970); /* Best to come first */ - data->status = (packet[0] >> 6); - data->version = (packet[0] >> 3)&0x07; - data->mode = packet[0]&0x07; - data->stratum = packet[1]; - data->polling = packet[2]; - data->precision = packet[3]; - d = 0.0; - for (i = 0; i < 4; ++i) d = 256.0*d+packet[NTP_DISP_FIELD+i]; - data->dispersion = d/65536.0; - d = 0.0; - for (i = 0; i < 8; ++i) d = 256.0*d+packet[NTP_REFERENCE+i]; - data->reference = d/NTP_SCALE; - d = 0.0; - for (i = 0; i < 8; ++i) d = 256.0*d+packet[NTP_ORIGINATE+i]; - data->originate = d/NTP_SCALE; - d = 0.0; - for (i = 0; i < 8; ++i) d = 256.0*d+packet[NTP_RECEIVE+i]; - data->receive = d/NTP_SCALE; - d = 0.0; - for (i = 0; i < 8; ++i) d = 256.0*d+packet[NTP_TRANSMIT+i]; - data->transmit = d/NTP_SCALE; -} - - - -void make_packet (ntp_data *data, int mode) { - -/* Create an outgoing NTP packet, either from scratch or starting from a -request from a client. Note that it implements the NTP specification, even -when this is clearly misguided, except possibly for the setting of LI. It -would be easy enough to add a sanity flag, but I am not in the business of -designing an alternative protocol (however much better it might be). */ - - data->status = NTP_LI_FUDGE<<6; - data->stratum = NTP_STRATUM; - data->reference = data->dispersion = 0.0; - if (mode == NTP_SERVER) { - data->mode = (data->mode == NTP_CLIENT ? NTP_SERVER : NTP_PASSIVE); - data->originate = data->transmit; - data->receive = data->current; - } else { - data->version = NTP_VERSION; - data->mode = mode; - data->polling = NTP_POLLING; - data->precision = NTP_PRECISION; - data->receive = data->originate = 0.0; - } - data->current = data->transmit = current_time(JAN_1970); -} - - - -int read_packet (int which, ntp_data *data, double *off, double *err) { - -/* Check the packet and work out the offset and optionally the error. Note -that this contains more checking than xntp does. This returns 0 for success, 1 -for failure and 2 for an ignored broadcast packet (a kludge for servers). Note -that it must not change its arguments if it fails. */ - - unsigned char receive[NTP_PACKET_MAX+1]; - double delay1, delay2, x, y; - int response = 0, failed, length, i, k; - -/* Read the packet and deal with diagnostics. */ - - if ((length = read_socket(which,receive,NTP_PACKET_MAX+1,waiting)) <= 0) - return 1; - if (length < NTP_PACKET_MIN || length > NTP_PACKET_MAX) { - if (verbose) - fprintf(stderr,"%s: bad length %d for NTP packet on socket %d\n", - argv0,length,which); - return 1; - } - if (verbose > 2) { - fprintf(stderr,"Incoming packet on socket %d:\n",which); - display_packet(receive,length); - } - unpack_ntp(data,receive,length); - if (verbose > 2) display_data(data); - -/* Start by checking that the packet looks reasonable. Be a little paranoid, -but allow for version 1 semantics and sick clients. */ - - if (operation == op_listen) - failed = (data->mode != NTP_BROADCAST); - else { - failed = (data->mode != NTP_SERVER && data->mode != NTP_PASSIVE); - response = 1; - } - if (failed || data->status == 3 || data->version < 1 || - data->version > NTP_VERSION_MAX || - data->stratum > NTP_STRATUM_MAX) { - if (verbose) - fprintf(stderr, - "%s: Unusable NTP packet rejected on socket %d (f=%d, status %d, version %d, stratum %d)\n", - argv0, which, - failed, data->status, data->version, data->stratum); - return 1; - } - -/* Note that the conventions are very poorly defined in the NTP protocol, so we -have to guess. Any full NTP server perpetrating completely unsynchronised -packets is an abomination, anyway, so reject it. */ - - delay1 = data->transmit-data->receive; - delay2 = data->current-data->originate; - failed = ( - ( data->stratum != 0 - /* && data->stratum != NTP_STRATUM_MAX */ - && data->reference == 0.0 - ) - || data->transmit == 0.0 - ); - if (response && - (data->originate == 0.0 || data->receive == 0.0 || - (data->reference != 0.0 && data->receive < data->reference) || - delay1 < 0.0 || delay1 > NTP_INSANITY || delay2 < 0.0 || - data->dispersion > NTP_INSANITY)) - failed = 1; - if (failed) { - if (verbose) - fprintf(stderr, - "%s: incomprehensible NTP packet rejected on socket %d\n", - argv0,which); - return 1; - } - if (data->stratum == NTP_STRATUM_MAX) { - fprintf(stderr, - "%s: unsynch NTP response on socket %d\n", - argv0,which); - return 1; - } - -/* If it is a response, check that it corresponds to one of our requests and -has got here in a reasonable length of time. */ - - if (response) { - k = 0; - for (i = 0; i < attempts; ++i) - if (data->originate == outgoing[i]) { - outgoing[i] = 0.0; - ++k; - } - if (k != 1 || delay2 > NTP_INSANITY) { - if (verbose) - fprintf(stderr, - "%s: bad response from NTP server rejected on socket %d\n", - argv0,which); - return 1; - } - } - -/* Now return the time information. If it is a server response, it contains -enough information that we can be almost certain that we have not been fooled -too badly. Heaven help us with broadcasts - make a wild kludge here, and see -elsewhere for other kludges. */ - - if (dispersion < data->dispersion) dispersion = data->dispersion; - if (operation == op_listen) { - *off = data->transmit-data->current; - *err = NTP_INSANITY; - } else { - x = data->receive-data->originate; - y = (data->transmit == 0.0 ? 0.0 : data->transmit-data->current); - *off = 0.5*(x+y); - *err = x-y; - x = data->current-data->originate; - if (0.5*x > *err) *err = 0.5*x; - } - return 0; -} - - - -void format_time (char *text, int length, double offset, double error, - double drift, double drifterr, int precision) { - -/* Format the current time into a string, with the extra information as -requested. Note that the rest of the program uses the correction needed, which -is what is printed for diagnostics, but this formats the error in the local -system for display to users. So the results from this are the negation of -those printed by the verbose options. */ - - int milli, len; - time_t now; - struct tm *gmt; - static const char *months[] = { - "Jan", "Feb", "Mar", "Apr", "May", "Jun", - "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" - }; - -/* Work out and format the current local time. Note that some semi-ANSI -systems do not set the return value from (s)printf. */ - - now = convert_time(current_time(offset),&milli); - errno = 0; - if ((gmt = localtime(&now)) == NULL) - fatal(1,"unable to work out local time",NULL); - len = 21; - if (length <= len) fatal(0,"internal error calling format_time",NULL); - errno = 0; - precision /= -3; - len += precision; - sprintf(text,"%.4d %s %.2d %.2d:%.2d:%.2d.%.*d", - gmt->tm_year+1900,months[gmt->tm_mon],gmt->tm_mday, - gmt->tm_hour,gmt->tm_min,gmt->tm_sec,precision,milli); - if (strlen(text) != len) - fatal(1,"unable to format current local time",NULL); - -/* Append the information about the offset, if requested. */ - - if (error >= 0.0) { - if (length < len+30) - fatal(0,"internal error calling format_time",NULL); - errno = 0; - sprintf(&text[len]," %c %.*f +/- %.*f secs",(offset > 0.0 ? '-' : '+'), - precision,(offset > 0.0 ? offset : -offset), - precision,dispersion+error); - if (strlen(&text[len]) < 22) - fatal(1,"unable to format clock correction",NULL); - } - -/* Append the information about the drift, if requested. */ - - if (drifterr >= 0.0) { - len = strlen(text); - if (length < len+25) - fatal(0,"internal error calling format_time",NULL); - errno = 0; - sprintf(&text[len]," %c %.1f +/- %.1f ppm", - (drift > 0.0 ? '-' : '+'),1.0e6*fabs(drift), - 1.0e6*drifterr); - if (strlen(&text[len]) < 17) - fatal(1,"unable to format clock correction",NULL); - } - -/* It would be better to check for field overflow, but it is a lot of code to -trap extremely implausible scenarios. This will usually stop chaos from -spreading. */ - - if (strlen(text) >= length) - fatal(0,"internal error calling format_time",NULL); -} - - - -double reset_clock (double offset, double error, int daemon) { - -/* Reset the clock, if appropriate, and return the correction actually used. -This contains most of the checking for whether changes are worthwhile, except -in daemon mode. */ - - double absoff = (offset < 0 ? -offset : offset); - char text[50]; - -/* If the correction is large, ask for confirmation before proceeding. */ - - if (absoff > prompt) { - if (! daemon && ftty(stdin) && ftty(stdout)) { - printf("The time correction is %.3f +/- %.3f+%.3f seconds\n", - offset,dispersion,error); - printf("Do you want to correct the time anyway? "); - fflush(stdout); - if (toupper(getchar()) != 'Y') { - printf("OK - quitting\n"); - fatal(0,NULL,NULL); - } - } else { - sprintf(text,"%.3f +/- %.3f+%.3f",offset,dispersion,error); - fatal(0,"time correction too large: %s seconds",text); - } - } - -/* See if the correction is reasonably reliable and worth making. */ - - if (absoff < (daemon ? 0.5 : 1.0)*minerr) { - if (daemon ? verbose > 1 : verbose) - fprintf(stderr,"%s: correction %.3f +/- %.3f+%.3f secs - ignored\n", - argv0,offset,dispersion,error); - return 0.0; - } else if (absoff < 2.0*error) { - if (daemon ? verbose > 1 : verbose) - fprintf(stderr, - "%s: correction %.3f +/- %.3f+%.3f secs - suppressed\n", - argv0,offset,dispersion,error); - return 0.0; - } - -/* Make the correction. Provide some protection against the previous -correction not having completed, but it will rarely help much. */ - - adjust_time(offset,(action == action_reset ? 1 : 0), - (daemon ? 2.0*minerr : 0.0)); - if (daemon ? verbose > 1 : verbose) { - format_time(text,50,0.0,-1.0,0.0,-1.0,-10); - fprintf(stderr, - "%s: time changed by %.3f secs to %s +/- %.3f+%.3f\n", - argv0,offset,text,dispersion,error); - } - return offset; -} - - -double estimate_stats (int *a_total, int *a_index, data_record *record, - double correction, double *a_disp, double *a_when, double *a_offset, - double *a_error, double *a_drift, double *a_drifterr, int *a_wait, - int update) { - -/* This updates the running statistics and returns the best estimate of what to -do now. It returns the timestamp relevant to the correction. If broadcasts -are rare and the drift is large, it will fail - you should then use a better -synchronisation method. It will also fail if something goes severely wrong -(e.g. if the local clock is reset by another process or the transmission errors -are beyond reason). - -There is a kludge for synchronisation loss during down time. If it detects -this, it will update only the history data and return zero; this is then -handled specially in run_daemon(). While it could correct the offset, this -might not always be the right thing to do. */ - - double weight, disp, when, offset, error, drift, drifterr, - now, e, w, x, y, z; - int total = *a_total, index = *a_index, wait = *a_wait, i; - char text[50]; - -/* Correct the previous data and store a new entry in the circular buffer. */ - - for (i = 0; i < total; ++i) { - record[i].when += correction; - record[i].offset -= correction; - } - if (update) { - record[index].dispersion = *a_disp; - record[index].when = *a_when; - record[index].offset = *a_offset; - if (verbose > 1) - fprintf(stderr,"%s: corr=%.3f when=%.3f disp=%.3f off=%.3f", - argv0,correction,*a_when,*a_disp,*a_offset); /* See below */ - if (operation == op_listen) { - if (verbose > 1) fprintf(stderr,"\n"); - record[index].error = minerr; - record[index].weight = 1.0; - } else { - if (verbose > 1) fprintf(stderr," err=%.3f\n",*a_error); - record[index].error = x = *a_error; - record[index].weight = 1.0/(x > minerr ? x*x : minerr*minerr); - } - if (++index >= count) index = 0; - *a_index = index; - if (++total > count) total = count; - *a_total = total; - if (verbose > 2) - fprintf(stderr,"corr=%.6f tot=%d ind=%d\n",correction,total,index); - } - -/* If there is insufficient data yet, use the latest estimates and return -forthwith. Note that this will not work for broadcasts, but they will be -disabled in run_daemon(). */ - - if ((operation == op_listen && total < count && update) || total < 3) { - *a_drift = 0.0; - *a_drifterr = -1.0; - *a_wait = delay; - return *a_when; - } - -/* Work out the average time, offset, error etc. Note that the dispersion is -not subject to the central limit theorem. Unfortunately, the variation in the -source's dispersion is our only indication of how consistent its clock is. */ - - disp = weight = when = offset = y = 0.0; - for (i = 0; i < total; ++i) { - weight += w = record[i].weight; - when += w*record[i].when; - offset += w*record[i].offset; - y += w*record[i].dispersion; - if (disp < record[i].dispersion) - disp = record[i].dispersion; - } - when /= weight; - offset /= weight; - y /= weight; - if (verbose > 2) - fprintf(stderr,"disp=%.6f wgt=%.3f when=%.6f off=%.6f\n", - disp,weight,when,offset); - -/* If there is enough data, estimate the drift and errors by regression. Note -that it is essential to calculate the mean square error, not the mean error. */ - - error = drift = x = z = 0.0; - for (i = 0; i < total; ++i) { - w = record[i].weight/weight; - x += w*(record[i].when-when)*(record[i].when-when); - drift += w*(record[i].when-when)*(record[i].offset-offset); - z += w*(record[i].offset-offset)*(record[i].offset-offset); - error += w*record[i].error*record[i].error+ - 2.0*w*(record[i].dispersion-y)*(record[i].dispersion-y); - } - if (verbose > 2) - fprintf(stderr,"X2=%.3f XY=%.6f Y2=%.9f E2=%.9f ",x,drift,z,error); - -/* When calculating the errors, add some paranoia mainly to check for coding -errors and complete lunacy, attempting to retry if at all possible. Because -glitches at this point are so common, log a reset even in non-verbose mode. -There will be more thorough checks later. Note that we cannot usefully check -the error for broadcasts. */ - - z -= drift*drift/x; - if (verbose > 2) fprintf(stderr,"S2=%.9f\n",z); - if (! update) { - if (z > 1.0e6) - fatal(0,"stored data too unreliable for time estimation",NULL); - } else if (operation == op_client) { - e = error+disp*disp+minerr*minerr; - if (z > e) { - if (verbose || z >= maxerr*maxerr) - fprintf(stderr, - "%s: excessively high error %.3f > %.3f > %.3f\n", - argv0,sqrt(z),sqrt(e),sqrt(error)); - if (total <= 1) - return 0.0; - else if (z < maxerr*maxerr) { - sprintf(text,"resetting on error %.3g > %.3g", - sqrt(z),sqrt(e)); - log_message(text); - return 0.0; - } else - fatal(0,"incompatible (i.e. erroneous) timestamps",NULL); - } else if (z > error && verbose) - fprintf(stderr, - "%s: anomalously high error %.3f > %.3f, but < %.3f\n", - argv0,sqrt(z),sqrt(error),sqrt(e)); - } else { - if (z > maxerr*maxerr) - fatal(0,"broadcasts too unreliable for time estimation",NULL); - } - drift /= x; - drifterr = ABSCISSA*sqrt(z/(x*total)); - error = (operation == op_listen ? minerr : 0.0)+ABSCISSA*sqrt(z/total); - if (verbose > 2) - fprintf(stderr,"err=%.6f drift=%.6f+/-%.6f\n",error,drift,drifterr); - if (error+drifterr*delay > NTP_INSANITY) - fatal(0,"unable to get a reasonable drift estimate",NULL); - -/* Estimate the optimal short-loop period, checking it carefully. Remember to -check that this whole process is likely to be accurate enough and that the -delay function may be inaccurate. */ - - wait = delay; - x = (drift < 0.0 ? -drift : drift); - if (x*delay < 0.5*minerr) { - if (verbose > 2) fprintf(stderr,"Drift too small to correct\n"); - } else if (x < 2.0*drifterr) { - if (verbose > 2) - fprintf(stderr,"Drift correction suppressed\n"); - } else { - if ((z = drifterr*delay) < 0.5*minerr) z = 0.5*minerr; - wait = (x < z/delay ? delay : (int)(z/x+0.5)); - wait = (int)(delay/(int)(delay/(double)wait+0.999)+0.999); - if (wait > delay) - fatal(0,"internal error in drift calculation",NULL); - if (update && (drift*wait > maxerr || wait < RESET_MIN)) { - sprintf(text,"%.6f+/-%.6f",drift,drifterr); - fatal(0,"drift correction too large: %s",text); - } - } - if (wait < *a_wait/2) wait = *a_wait/2; - if (wait > *a_wait*2) wait = *a_wait*2; - -/* Now work out what the correction should be, as distinct from what it should -have been, remembering that older times are less certain. */ - - now = current_time(JAN_1970); - x = now-when; - offset += x*drift; - error += x*drifterr; - for (i = 0; i < total; ++i) { - x = now-record[i].when; - z = record[i].error+x*drifterr; - if (z < error) { - when = record[i].when; - offset = record[i].offset+x*drift; - error = z; - } - } - if (verbose > 2) - fprintf(stderr,"now=%.6f when=%.6f off=%.6f err=%.6f wait=%d\n", - now,when,offset,error,wait); - -/* Finally, return the result. */ - - *a_disp = disp; - *a_when = when; - *a_offset = offset; - *a_error = error; - *a_drift = drift; - *a_drifterr = drifterr; - *a_wait = wait; - return now; -} - - - -double correct_drift (double *a_when, double *a_offset, double drift) { - -/* Correct for the drift since the last time it was done, provided that a long -enough time has elapsed. And do remember to kludge up the time and -discrepancy, when appropriate. */ - - double d, x; - - d = current_time(JAN_1970)-*a_when; - *a_when += d; - x = *a_offset+d*drift; - if (verbose > 2) - fprintf(stderr,"Correction %.6f @ %.6f off=%.6f ",x,*a_when,*a_offset); - if (d >= waiting && (x < 0.0 ? -x : x) >= 0.5*minerr) { - if (verbose > 2) fprintf(stderr,"performed\n"); - adjust_time(x,(action == action_reset ? 1 : 0),0.5*minerr); - *a_offset = 0.0; - return x; - } else { - if (verbose > 2) fprintf(stderr,"ignored\n"); - *a_offset = x; - return 0.0; - } -} - - - -void handle_saving (int operation, int *total, int *index, int *cycle, - data_record *record, double *previous, double *when, double *correction) { - -/* This handles the saving and restoring of the state to a file. While it is -subject to spoofing, this is not a major security problem. But, out of general -paranoia, check everything in sight when restoring. Note that this function -has no external effect if something goes wrong. */ - - struct { - data_record record[COUNT_MAX]; - double previous, when, correction; - int operation, delay, count, total, index, cycle, waiting; - } buffer; - double x, y; - int i, j; - - if (savefile == NULL) return; - -/* Read the restart file and print its data in diagnostic mode. Note that some -care is necessary to avoid introducing a security exposure - but we trust the -C library not to trash the stack on bad numbers! */ - - if (operation == save_read_only || operation == save_read_check) { - if (fread(&buffer,sizeof(buffer),1,savefile) != 1 || ferror(savefile)) { - if (ferror(savefile)) - fatal(1,"unable to read record from daemon save file",NULL); - else if (verbose) - fprintf(stderr,"%s: bad daemon restart information\n",argv0); - return; - } - if (verbose > 2) { - fprintf(stderr,"Reading prev=%.6f when=%.6f corr=%.6f\n", - buffer.previous,buffer.when,buffer.correction); - fprintf(stderr,"op=%d dly=%d cnt=%d tot=%d ind=%d cyc=%d wait=%d\n", - buffer.operation,buffer.delay,buffer.count,buffer.total, - buffer.index,buffer.cycle,buffer.waiting); - if (buffer.total < COUNT_MAX) - for (i = 0; i < buffer.total; ++i) - fprintf(stderr, - "disp=%.6f wgt=%.3f when=%.6f off=%.6f err=%.6f\n", - buffer.record[i].dispersion,buffer.record[i].weight, - buffer.record[i].when,buffer.record[i].offset, - buffer.record[i].error); - } - - -/* Start checking the data for sanity. */ - - if (buffer.operation == 0 && buffer.delay == 0 && buffer.count == 0) { - if (operation < 0) - fatal(0,"the daemon save file has been cleared",NULL); - if (verbose) - fprintf(stderr,"%s: restarting from a cleared file\n",argv0); - return; - } - if (operation == save_read_check) { - if (buffer.operation != operation || buffer.delay != delay || - buffer.count != count) { - if (verbose) - fprintf(stderr,"%s: different parameters for restart\n", - argv0); - return; - } - if (buffer.total < 1 || buffer.total > count || buffer.index < 0 || - buffer.index >= count || buffer.cycle < 0 || - buffer.cycle >= count || buffer.correction < -maxerr || - buffer.correction > maxerr || buffer.waiting < RESET_MIN || - buffer.waiting > delay || buffer.previous > buffer.when || - buffer.previous < buffer.when-count*delay || - buffer.when >= *when) { - if (verbose) - fprintf(stderr,"%s: corrupted restart information\n",argv0); - return; - } - -/* Checking the record is even more tedious. */ - - x = *when; - y = 0.0; - for (i = 0; i < buffer.total; ++i) { - if (buffer.record[i].dispersion < 0.0 || - buffer.record[i].dispersion > maxerr || - buffer.record[i].weight <= 0.0 || - buffer.record[i].weight > 1.001/(minerr*minerr) || - buffer.record[i].offset < -count*maxerr || - buffer.record[i].offset > count*maxerr || - buffer.record[i].error < 0.0 || - buffer.record[i].error > maxerr) { - if (verbose) - fprintf(stderr,"%s: corrupted restart record\n",argv0); - return; - } - if (buffer.record[i].when < x) x = buffer.record[i].when; - if (buffer.record[i].when > y) y = buffer.record[i].when; - } - -/* Check for consistency and, finally, whether this is too old. */ - - if (y > buffer.when || y-x < (buffer.total-1)*delay || - y-x > (buffer.total-1)*count*delay) { - if (verbose) - fprintf(stderr,"%s: corrupted restart times\n",argv0); - return; - } - if (buffer.when < *when-count*delay) { - if (verbose) - fprintf(stderr,"%s: restart information too old\n",argv0); - return; - } - } - -/* If we get here, just copy the data back. */ - - memcpy(record,buffer.record,sizeof(buffer.record)); - *previous = buffer.previous; - *when = buffer.when; - *correction = buffer.correction; - *total = buffer.total; - *index = buffer.index; - *cycle = buffer.cycle; - waiting = buffer.waiting; - memset(&buffer,0,sizeof(buffer)); - -/* Print out the data if requested. */ - - if (verbose > 1) { - fprintf(stderr,"%s: prev=%.3f when=%.3f corr=%.3f\n", - argv0,*previous,*when,*correction); - for (i = 0; i < *total; ++i) { - if ((j = i+*index-*total) < 0) j += *total; - fprintf(stderr,"%s: when=%.3f disp=%.3f off=%.3f", - argv0,record[j].when,record[j].dispersion,record[j].offset); - if (operation == op_client) - fprintf(stderr," err=%.3f\n",record[j].error); - else - fprintf(stderr,"\n"); - } - } - -/* All errors on output are fatal. */ - - } else if (operation == save_write) { - memcpy(buffer.record,record,sizeof(buffer.record)); - buffer.previous = *previous; - buffer.when = *when; - buffer.correction = *correction; - buffer.operation = operation; - buffer.delay = delay; - buffer.count = count; - buffer.total = *total; - buffer.index = *index; - buffer.cycle = *cycle; - buffer.waiting = waiting; - if (fseek(savefile,0l,SEEK_SET) != 0 || - fwrite(&buffer,sizeof(buffer),1,savefile) != 1 || - fflush(savefile) != 0 || ferror(savefile)) - fatal(1,"unable to write record to daemon save file",NULL); - if (verbose > 2) { - fprintf(stderr,"Writing prev=%.6f when=%.6f corr=%.6f\n", - *previous,*when,*correction); - fprintf(stderr,"op=%d dly=%d cnt=%d tot=%d ind=%d cyc=%d wait=%d\n", - operation,delay,count,*total,*index,*cycle,waiting); - if (*total < COUNT_MAX) - for (i = 0; i < *total; ++i) - fprintf(stderr, - "disp=%.6f wgt=%.3f when=%.6f off=%.6f err=%.6f\n", - record[i].dispersion,record[i].weight, - record[i].when,record[i].offset,record[i].error); - } - -/* Clearing the save file is similar. */ - - } else if (operation == save_clear) { - if (fseek(savefile,0l,SEEK_SET) != 0 || - fwrite(&buffer,sizeof(buffer),1,savefile) != 1 || - fflush(savefile) != 0 || ferror(savefile)) - fatal(1,"unable to clear daemon save file",NULL); - } else - fatal(0,"internal error in handle_saving",NULL); -} - - - -void query_savefile (void) { - -/* This queries a daemon save file. */ - - double previous, when, correction = 0.0, offset = 0.0, error = -1.0, - drift = 0.0, drifterr = -1.0; - data_record record[COUNT_MAX]; - int total = 0, index = 0, cycle = 0; - char text[100]; - -/* This is a few lines stripped out of run_daemon() and slightly hacked. */ - - previous = when = current_time(JAN_1970); - if (verbose > 2) { - format_time(text,50,0.0,-1.0,0.0,-1.0,-10); - fprintf(stderr,"Started=%.6f %s\n",when,text); - } - handle_saving(save_read_only,&total,&index,&cycle,record,&previous,&when, - &correction); - estimate_stats(&total,&index,record,correction,&dispersion, - &when,&offset,&error,&drift,&drifterr,&waiting,0); - format_time(text,100,offset,error,drift,drifterr,-10); - printf("%s\n",text); - if (fclose(savefile)) fatal(1,"unable to close daemon save file",NULL); - if (verbose > 2) fprintf(stderr,"Stopped normally\n"); - exit(EXIT_SUCCESS); -} - - - -void run_daemon (char *hostnames[], int nhosts, int initial) { - -/* This does not adjust the time between calls to the server, but it does -adjust the time between clock resets. This function will survive short periods -of server inaccessibility or network glitches, but not long ones, and will then -need restarting manually. - -It is far too complex for a single function, but could really only be -simplified by making most of its variables global or by a similarly horrible -trick. Oh, for nested scopes as in Algol 68! */ - - double history[COUNT_MAX], started, previous, when, correction = 0.0, - weeble = 1.0, accepts = 0.0, rejects = 0.0, flushes = 0.0, - replicates = 0.0, skips = 0.0, offset = 0.0, error = -1.0, - drift = 0.0, drifterr = -1.0, maxoff = 0.0, x; - data_record record[COUNT_MAX]; - int total = 0, index = 0, item = 0, rej_level = 0, rep_level = 0, - cycle = 0, retry = 1, i, j, k; - unsigned char transmit[NTP_PACKET_MIN]; - ntp_data data; - char text[100]; - -/* After initialising, restore from a previous run if possible. Note that -only a few of the variables are actually needed to control the operation and -the rest are mainly for diagnostics. */ - - started = previous = when = current_time(JAN_1970); - if (verbose > 2) { - format_time(text,50,0.0,-1.0,0.0,-1.0,-10); - fprintf(stderr,"Started=%.6f %s\n",when,text); - } - if (initial) { - handle_saving(save_read_check,&total,&index,&cycle,record, - &previous,&when,&correction); - cycle = (nhosts > 0 ? cycle%nhosts : 0); - if (total > 0 && started-previous < delay) { - if (verbose > 2) fprintf(stderr,"Last packet too recent\n"); - retry = 0; - } - if (verbose > 2) - fprintf(stderr,"prev=%.6f when=%.6f retry=%d\n", - previous,when,retry); - for (i = 0; i < nhosts; ++i) open_socket(i,hostnames[i],delay); - if (action != action_display) { - set_lock(1); - locked = 1; - } - } - dispersion = 0.0; - attempts = 0; - for (i = 0; i < count; ++i) history[i] = 0.0; - while (1) { - -/* Print out a reasonable amount of diagnostics, rather like a server. Note -that it may take a little time, but shouldn't affect the estimates much. Then -check that we aren't in a failing loop. */ - - if (verbose > 2) fprintf(stderr,"item=%d rej=%d\n",item,rej_level); - x = current_time(JAN_1970)-started; - if (verbose && - x/3600.0+accepts+rejects+flushes+replicates+skips >= weeble) { - weeble *= WEEBLE_FACTOR; - x -= 3600.0*(i = (int)(x/3600.0)); - x -= 60.0*(j = (int)(x/60.0)); - if (i > 0) - fprintf(stderr,"%s: after %d hours %d mins ",argv0,i,j); - else if (j > 0) - fprintf(stderr,"%s: after %d mins %.0f secs ",argv0,j,x); - else - fprintf(stderr,"%s: after %.1f secs ",argv0,x); - fprintf(stderr,"acc. %.0f rej. %.0f flush %.0f", - accepts,rejects,flushes); - if (operation == op_listen) - fprintf(stderr," rep. %.0f skip %.0f",replicates,skips); - fprintf(stderr," max.off. %.3f corr. %.3f\n",maxoff,correction); - format_time(text,100,offset,error,drift,drifterr,-10); - fprintf(stderr,"%s: %s\n",argv0,text); - maxoff = 0.0; - } - if (current_time(JAN_1970)-previous > count*delay) { - if (verbose) - fprintf(stderr,"%s: no packets in too long a period\n",argv0); - return; - } - -/* Listen for the next broadcast packet. This allows up to ETHERNET_MAX -replications per packet, for systems with multiple addresses for receiving -broadcasts; the only reason for a limit is to protect against broken NTP -servers always returning the same time. */ - - if (operation == op_listen) { - flushes += flush_socket(0); - if (read_packet(0,&data,&offset,&error)) { - ++rejects; - if (++rej_level > count) - fatal(0,"too many bad or lost packets",NULL); - if (action != action_display && drifterr >= 0.0) { - correction += correct_drift(&when,&offset,drift); - handle_saving(save_write,&total,&index,&cycle,record, - &previous,&when,&correction); - } - continue; - } - if ((rej_level -= (count < 5 ? count : 5)) < 0) rej_level = 0; - x = data.transmit; - for (i = 0; i < count; ++i) - if (x == history[i]) { - ++replicates; - if (++rep_level > ETHERNET_MAX) - fatal(0,"too many replicated packets",NULL); - goto continue1; - } - rep_level = 0; - history[item] = x; - if (++item >= count) item = 0; - -/* Accept a packet only after a long enough period has elapsed. */ - - when = data.current; - if (! retry && when < previous+delay) { - if (verbose > 2) fprintf(stderr,"Skipping too recent packet\n"); - ++skips; - continue; - } - retry = 0; - if (verbose > 2) - fprintf(stderr,"Offset=%.6f @ %.6f disp=%.6f\n", - offset,when,dispersion); - -/* Handle the client/server model. It keeps a record of transmitted times, -mainly out of paranoia. The waiting time is kludged up to attempt to provide -reasonable resilience against both lost packets and dead servers. But it -won't handle much of either, and will stop after a while, needing manual -restarting. Running it under cron is the best approach. */ - - } else { - if (! retry) { - if (verbose > 2) fprintf(stderr,"Sleeping for %d\n",waiting); - do_nothing(waiting); - } - make_packet(&data,NTP_CLIENT); - outgoing[item] = data.transmit; - if (++item >= 2*count) item = 0; - if (attempts < 2*count) ++attempts; - if (verbose > 2) { - fprintf(stderr,"Outgoing packet on socket %d:\n",cycle); - display_data(&data); - } - pack_ntp(transmit,NTP_PACKET_MIN,&data); - if (verbose > 2) display_packet(transmit,NTP_PACKET_MIN); - flushes += flush_socket(cycle); - write_socket(cycle,transmit,NTP_PACKET_MIN); - -/* Read the packet and check that it is an appropriate response. Because this -is rather more numerically sensitive than simple resynchronisation, reject all -very inaccurate packets. Be careful if you modify this, because the error -handling is rather nasty to avoid replicating code. */ - - k = read_packet(cycle,&data,&offset,&error); - if (++cycle >= nhosts) cycle = 0; - if (! k) - when = (data.originate+data.current)/2.0; - else if (action != action_display && drifterr >= 0.0) { - correction += correct_drift(&when,&offset,drift); - handle_saving(save_write,&total,&index,&cycle,record, - &previous,&when,&correction); - } - if (! k && ! retry && when < previous+delay-2) { - if (verbose) - fprintf(stderr,"%s: packets out of order on socket %d\n", - argv0,cycle); - k = 1; - } - if (! k && data.current-data.originate > maxerr) { - if (verbose) - fprintf(stderr, - "%s: very slow response rejected on socket %d\n", - argv0,cycle); - k = 1; - } - -/* Count the number of rejected packets and fail if there are too many. */ - - if (k) { - ++rejects; - if (++rej_level > count) - fatal(0,"too many bad or lost packets",NULL); - else { - retry = 1; - continue; - } - } else - retry = 0; - if ((rej_level -= (count < 5 ? count : 5)) < 0) rej_level = 0; - if (verbose > 2) - fprintf(stderr,"Offset=%.6f+/-%.6f @ %.6f disp=%.6f\n", - offset,error,when,dispersion); - } - -/* Calculate the statistics, and display the results or make the initial -correction. Note that estimate_stats() will return zero if a timestamp -indicates synchronisation loss (usually due to down time or a change of server, -somewhere upstream), and that the recovery operation is unstructured, so great -care should be taken when modifying it. Also, we want to clear the saved state -is the statistics are bad. */ - - handle_saving(save_clear,&total,&index,&cycle,record,&previous,&when, - &correction); - ++accepts; - dispersion = data.dispersion; - previous = when = - estimate_stats(&total,&index,record,correction,&dispersion, - &when,&offset,&error,&drift,&drifterr,&waiting,1); - if (verbose > 2) { - fprintf(stderr,"tot=%d ind=%d dis=%.3f when=%.3f off=%.3f ", - total,index,dispersion,when,offset); - fprintf(stderr,"err=%.3f wait=%d\n",error,waiting); - } - if (when == 0.0) return; - x = (maxoff < 0.0 ? -maxoff : maxoff); - if ((offset < 0.0 ? -offset : offset) > x) maxoff = offset; - correction = 0.0; - if (operation == op_client || accepts >= count) { - if (action == action_display) { - format_time(text,100,offset,error,drift,drifterr,-10); - printf("%s\n",text); - } else { - x = reset_clock(offset,error,1); - correction += x; - offset -= x; - } - } else - waiting = delay; - handle_saving(save_write,&total,&index,&cycle,record,&previous,&when, - &correction); - -/* Now correct the clock for a while, before getting another packet and -updating the statistics. */ - - while (when < previous+delay-waiting) { - do_nothing(waiting); - if (action == action_display) - when += waiting; - else { - correction += correct_drift(&when,&offset,drift); - handle_saving(save_write,&total,&index,&cycle,record, - &previous,&when,&correction); - } - } -continue1: ; - } -} - - - -void run_client (char *hostnames[], int nhosts) { - -/* Get enough responses to do something with; or not, as the case may be. Note -that it allows for half of the packets to be bad, so may make up to twice as -many attempts as specified by the -c value. The deadline checking is merely -paranoia, to protect against broken signal handling - it cannot easily be -triggered if the signal handling works. */ - - double history[COUNT_MAX], guesses[COUNT_MAX], offset, error, deadline, - a, b, x, y; - int precs[COUNT_MAX], precision = 0; - int accepts = 0, rejects = 0, flushes = 0, replicates = 0, cycle = 0, k; - unsigned char transmit[NTP_PACKET_MIN]; - ntp_data data; - char text[100]; - - if (verbose > 2) { - format_time(text,50,0.0,-1.0,0.0,-1.0,-10); - fprintf(stderr,"Started=%.6f %s\n",current_time(JAN_1970),text); - } - for (k = 0; k < nhosts; ++k) open_socket(k,hostnames[k],delay); - if (action != action_display) { - set_lock(1); - locked = 1; - } - attempts = 0; - deadline = current_time(JAN_1970)+delay; - -/* Listen to broadcast packets and select the best (i.e. earliest). This will -be sensitive to a bad NTP broadcaster, but I believe such things are very rare -in practice. In any case, if you have one, it is probably the only one on your -subnet, so you are knackered! This allows up to ETHERNET_MAX replications per -packet, for systems with multiple addresses for receiving broadcasts; the only -reason for a limit is to protect against broken NTP servers always returning -the same time. */ - - if (operation == op_listen) { - while (accepts < count) { - if (current_time(JAN_1970) > deadline) - fatal(0,"not enough valid broadcasts received in time",NULL); - flushes += flush_socket(0); - if (read_packet(0,&data,&x,&y)) { - if (++rejects > count) - fatal(0,"too many bad or lost packets",NULL); - else - continue; - } else { - a = data.transmit; - for (k = 0; k < accepts; ++k) - if (a == history[k]) { - if (++replicates > ETHERNET_MAX*count) - fatal(0,"too many replicated packets",NULL); - goto continue1; - } - history[accepts] = a; - precs[accepts] = data.precision; - guesses[accepts++] = x; - } - if (verbose > 2) - fprintf(stderr,"Offset=%.6f disp=%.6f\n",x,dispersion); - else if (verbose > 1) - fprintf(stderr,"%s: offset=%.3f disp=%.3f\n", - argv0,x,dispersion); - -/* Note that bubblesort IS a good method for this amount of data. */ - - for (k = accepts-2; k >= 0; --k) - if (guesses[k] < guesses[k+1]) - break; - else { - x = guesses[k]; - guesses[k] = guesses[k+1]; - guesses[k+1] = x; - precision = precs[k]; - precs[k] = precs[k+1]; - precs[k+1] = precision; - } -continue1: ; - } - offset = guesses[0]; - precision = precs[0]; - error = minerr+guesses[count <= 5 ? count-1 : 5]-offset; - if (verbose > 2) - fprintf(stderr,"accepts=%d rejects=%d flushes=%d replicates=%d\n", - accepts,rejects,flushes,replicates); - -/* Handle the client/server model. It keeps a record of transmitted times, -mainly out of paranoia. */ - - } else { - offset = 0.0; - precision = 0; - error = NTP_INSANITY; - while (accepts < count && attempts < 2*count) { - if (current_time(JAN_1970) > deadline) - fatal(0,"not enough valid responses received in time",NULL); - make_packet(&data,NTP_CLIENT); - precs[attempts] = data.precision; - outgoing[attempts++] = data.transmit; - if (verbose > 2) { - fprintf(stderr,"Outgoing packet on socket %d:\n",cycle); - display_data(&data); - } - pack_ntp(transmit,NTP_PACKET_MIN,&data); - if (verbose > 2) display_packet(transmit,NTP_PACKET_MIN); - flushes += flush_socket(cycle); - write_socket(cycle,transmit,NTP_PACKET_MIN); - if (read_packet(cycle,&data,&x,&y)) { - if (++rejects > count) - fatal(0,"too many bad or lost packets",NULL); - else - continue; - } else - ++accepts; - if (++cycle >= nhosts) cycle = 0; - -/* Work out the most accurate time, and check that it isn't more accurate than -the results warrant. */ - - if (verbose > 2) - fprintf(stderr,"Offset=%.6f+/-%.6f disp=%.6f\n",x,y,dispersion); - else if (verbose > 1) - fprintf(stderr,"%s: offset=%.3f+/-%.3f disp=%.3f\n", - argv0,x,y,dispersion); - if ((a = x-offset) < 0.0) a = -a; - if (accepts <= 1) a = 0.0; - b = error+y; - if (y < error) { - offset = x; - error = y; - precision = data.precision; - } - if (verbose > 2) - fprintf(stderr,"best=%.6f+/-%.6f\n",offset,error); - if (a > b) { - sprintf(text,"%d",cycle); - fatal(0,"inconsistent times got from NTP server on socket %s", - text); - } - if (error <= minerr) break; - } - if (verbose > 2) - fprintf(stderr,"accepts=%d rejects=%d flushes=%d\n", - accepts,rejects,flushes); - } - -/* Tidy up the socket, issues diagnostics and perform the action. */ - - for (k = 0; k < nhosts; ++k) close_socket(k); - if (accepts == 0) fatal(0,"no acceptable packets received",NULL); - if (error > NTP_INSANITY) - fatal(0,"unable to get a reasonable time estimate",NULL); - if (verbose > 2) - fprintf(stderr,"Correction: %.6f +/- %.6f disp=%.6f\n", - offset,error,dispersion); - if (action == action_display) { - format_time(text,75,offset,error,0.0,-1.0,precision); - printf("%s\n",text); - } else - (void)reset_clock(offset,error,0); - if (locked) set_lock(0); - if (verbose > 2) fprintf(stderr,"Stopped normally\n"); - exit(EXIT_SUCCESS); -} - - - -int main (int argc, char *argv[]) { - -/* This is the entry point and all that. It decodes the arguments and calls -one of the specialised routines to do the work. */ - - char *hostnames[MAX_SOCKETS], *savename = NULL; - int daemon = 0, nhosts = 0, help = 0, args = argc-1, k; - char c; - - if (argv[0] == NULL || argv[0][0] == '\0') - argv0 = "sntp"; - else if ((argv0 = strrchr(argv[0],'/')) != NULL) - ++argv0; - else - argv0 = argv[0]; - - setvbuf(stdout,NULL,_IOLBF,BUFSIZ); - setvbuf(stderr,NULL,_IOLBF,BUFSIZ); - - if (INT_MAX < 2147483647) fatal(0,"sntp requires >= 32-bit ints",NULL); - if (DBL_EPSILON > 1.0e-13) - fatal(0,"sntp requires doubles with eps <= 1.0e-13",NULL); - for (k = 0; k < MAX_SOCKETS; ++k) hostnames[k] = NULL; - -/* Decode the arguments. */ - - while (argc > 1) { - k = 1; - if (strcmp(argv[1],"-4") == 0) - preferred_family(PREF_FAM_INET); - else if (strcmp(argv[1],"-6") == 0) - preferred_family(PREF_FAM_INET6); - else if (strcmp(argv[1],"-u") == 0) - ++unprivport; - else if (strcmp(argv[1],"-q") == 0 && action == 0) - action = action_query; - else if (strcmp(argv[1],"-r") == 0 && action == 0) - action = action_reset; - else if (strcmp(argv[1],"-a") == 0 && action == 0) - action = action_adjust; - else if (strcmp(argv[1],"-l") == 0 && lockname == NULL && argc > 2) { - lockname = argv[2]; - k = 2; - } else if ((strcmp(argv[1],"-x") == 0) && - daemon == 0) { - if (argc > 2 && sscanf(argv[2],"%d%c",&daemon,&c) == 1) { - if (daemon < 1 || daemon > 1440) - fatal(0,"%s option value out of range",argv[1]); - k = 2; - } else - daemon = 300; - } else if (strcmp(argv[1],"-f") == 0 && savename == NULL && argc > 2) { - savename = argv[2]; - k = 2; - } else if ((strcmp(argv[1],"--help") == 0 || - strcmp(argv[1],"-h") == 0 || strcmp(argv[1],"-?") == 0) && - help == 0) - help = 1; - else if (strcmp(argv[1],"-v") == 0 && verbose == 0) - verbose = 1; - else if (strcmp(argv[1],"-V") == 0 && verbose == 0) - verbose = 2; - else if (strcmp(argv[1],"-W") == 0 && verbose == 0) - verbose = 3; - else if (strcmp(argv[1],"-e") == 0 && minerr == 0.0 && argc > 2) { - if (sscanf(argv[2],"%lf%c",&minerr,&c) != 1) syntax(1); - if (minerr <= 0.000999999 || minerr > 1.0) - fatal(0,"%s option value out of range","-e"); - k = 2; - } else if (strcmp(argv[1],"-E") == 0 && maxerr == 0.0 && argc > 2) { - if (sscanf(argv[2],"%lf%c",&maxerr,&c) != 1) syntax(1); - if (maxerr < 1.0 || maxerr > 60.0) - fatal(0,"%s option value out of range","-E"); - k = 2; - } else if (strcmp(argv[1],"-P") == 0 && prompt == 0.0 && argc > 2) { - if (strcmp(argv[2],"no") == 0) - prompt = (double)INT_MAX; - else { - if (sscanf(argv[2],"%lf%c",&prompt,&c) != 1) syntax(1); - if (prompt < 1.0 || prompt > 3600.0) - fatal(0,"%s option value out of range","-p"); - } - k = 2; - } else if (strcmp(argv[1],"-d") == 0 && delay == 0 && argc > 2) { - if (sscanf(argv[2],"%d%c",&delay,&c) != 1) syntax(1); - if (delay < 1 || delay > 3600) - fatal(0,"%s option value out of range","-d"); - k = 2; - } else if (strcmp(argv[1],"-c") == 0 && count == 0 && argc > 2) { - if (sscanf(argv[2],"%d%c",&count,&c) != 1) syntax(1); - if (count < 1 || count > COUNT_MAX) - fatal(0,"%s option value out of range","-c"); - k = 2; - } else - break; - argc -= k; - argv += k; - } - -/* Check the arguments for consistency and set the defaults. */ - - if (action == action_query) { - if (argc != 1 || minerr != 0.0 || maxerr != 0.0 || count != 0 || - delay != 0 || daemon != 0 || prompt != 0.0 || lockname != NULL) - syntax(1); - } else { - if (argc < 1 || argc > MAX_SOCKETS || (daemon != 0 && delay != 0)) - syntax(1); - if ((prompt || lockname != NULL) && - action != action_reset && action != action_adjust) - syntax(1); - if (count > 0 && count < argc-1) - fatal(0,"-c value less than number of addresses",NULL); - if (argc > 1) { - operation = op_client; - for (k = 1; k < argc; ++k) { - if (argv[k][0] == '\0' || argv[k][0] == '-') - fatal(0,"invalid Internet address '%s'",argv[k]); - hostnames[k-1] = argv[k]; - } - nhosts = argc-1; - } else { - operation = op_listen; - nhosts = 0; - } - if (action == 0) action = action_display; - if (minerr <= 0.0) minerr = (operation == op_listen ? 0.5 : 0.1); - if (maxerr <= 0.0) maxerr = 5.0; - if (count == 0) count = (argc-1 < 5 ? 5 : argc-1); - if ((argc == 1 || (daemon != 0 && action != action_query)) && count < 5) - fatal(0,"at least 5 packets needed in this mode",NULL); - if ((action == action_reset || action == action_adjust) && - lockname == NULL) - lockname = LOCKNAME; - -/* The '-x' option changes the implications of many other settings, though this -is not usually apparent to the caller. Most of the time delays are to ensure -that stuck states terminate, and do not affect the result. */ - - if (daemon != 0) { - if (minerr >= maxerr || maxerr >= daemon) - fatal(0,"values not in order -e < -E < -x",NULL); - waiting = delay = daemon *= 60; - } else { - if (savename != NULL) - fatal(0,"-f can be specified only with -x",NULL); - if (delay == 0) - delay = (operation == op_listen ? 300 : - (2*count >= 15 ? 2*count+1 :15)); - if (operation == op_listen) { - if (minerr >= maxerr || maxerr >= delay/count) - fatal(0,"values not in order -e < -E < -d/-c",NULL); - } else { - if (minerr >= maxerr || maxerr >= delay) - fatal(0,"values not in order -e < -E < -d",NULL); - } - if (2*count >= delay) fatal(0,"-c must be less than half -d",NULL); - waiting = delay/count; - } - if (prompt == 0.0) prompt = 30.0; - } - if ((daemon || action == action_query) && savename == NULL) - savename = SAVENAME; - -/* Diagnose where we are, if requested, and separate out the classes of -operation. The calls do not return. */ - - if (help) syntax(args == 1); - if (verbose) { - fprintf(stderr,"%s options: a=%d v=%d e=%.3f E=%.3f P=%.3f\n", - argv0,action,verbose,minerr,maxerr,prompt); - fprintf(stderr," d=%d c=%d %c=%d op=%d l=%s f=%s", - delay,count,'x',daemon,operation, - (lockname == NULL ? "" : lockname), - (savename == NULL ? "" : savename)); - for (k = 0; k < MAX_SOCKETS; ++k) - if (hostnames[k] != NULL) fprintf(stderr," %s",hostnames[k]); - fprintf(stderr,"\n"); - } - if (nhosts == 0) nhosts = 1; /* Kludge for broadcasts */ - if (action == action_query) { - if (savename == NULL || savename[0] == '\0') - fatal(0,"no daemon save file specified",NULL); - else if ((savefile = fopen(savename,"rb")) == NULL) - fatal(0,"unable to open the daemon save file",NULL); - query_savefile(); - } else if (daemon != 0) { - if (savename != NULL && savename[0] != '\0' && - (savefile = fopen(savename,"rb+")) == NULL && - (savefile = fopen(savename,"wb+")) == NULL) - fatal(0,"unable to open the daemon save file",NULL); - run_daemon(hostnames,nhosts,1); - while (1) run_daemon(hostnames,nhosts,0); - } else - run_client(hostnames,nhosts); - fatal(0,"internal error at end of main",NULL); - return EXIT_FAILURE; +#include +#include +#include +#include +#include +#include +#include +#include + +#include + +#include "crypto.h" +#include "kod_management.h" +#include "networking.h" +#include "utilities.h" +#include "log.h" + +char *progname = "sntp"; /* for msyslog */ + +int ai_fam_pref = AF_UNSPEC; +volatile int debug; + +struct key *keys = NULL; + +void set_li_vn_mode (struct pkt *spkt, char leap, char version, char mode); +int sntp_main (int argc, char **argv); +int on_wire (struct addrinfo *host, struct addrinfo *bcastaddr); +int set_time (double offset); + + +int +main ( + int argc, + char **argv + ) +{ + return sntp_main(argc, argv); +} + +/* + * The actual main function. + */ +int +sntp_main ( + int argc, + char **argv + ) +{ + register int c; + struct kod_entry *reason = NULL; + int optct; + int sync_data_suc = 0; + struct addrinfo **bcastaddr = NULL; + struct addrinfo **resh = NULL; + struct addrinfo *ai; + int resc; + int kodc; + int ow_ret; + int bcast = 0; + char *hostname; + + /* IPv6 available? */ + if (isc_net_probeipv6() != ISC_R_SUCCESS) { + ai_fam_pref = AF_INET; +#ifdef DEBUG + printf("No ipv6 support available, forcing ipv4\n"); +#endif + } else { + /* Check for options -4 and -6 */ + if (HAVE_OPT(IPV4)) + ai_fam_pref = AF_INET; + else if (HAVE_OPT(IPV6)) + ai_fam_pref = AF_INET6; + } + + log_msg("Started sntp", 0); + + optct = optionProcess(&sntpOptions, argc, argv); + argc -= optct; + argv += optct; + + /* Parse config file if declared TODO */ + + /* Initialize logging system */ + if (HAVE_OPT(FILELOG)) + init_log(OPT_ARG(FILELOG)); + + /* + * If there's a specified KOD file init KOD system. If not use + * default file. For embedded systems with no writable + * filesystem, -K /dev/null can be used to disable KoD storage. + */ + if (HAVE_OPT(KOD)) + kod_init_kod_db(OPT_ARG(KOD)); + else + kod_init_kod_db("/var/db/ntp-kod"); + + if (HAVE_OPT(KEYFILE)) + auth_init(OPT_ARG(KEYFILE), &keys); + +#ifdef EXERCISE_KOD_DB + add_entry("192.168.169.170", "DENY"); + add_entry("192.168.169.171", "DENY"); + add_entry("192.168.169.172", "DENY"); + add_entry("192.168.169.173", "DENY"); + add_entry("192.168.169.174", "DENY"); + delete_entry("192.168.169.174", "DENY"); + delete_entry("192.168.169.172", "DENY"); + delete_entry("192.168.169.170", "DENY"); + if ((kodc = search_entry("192.168.169.173", &reason)) == 0) + printf("entry for 192.168.169.173 not found but should have been!\n"); + else + free(reason); +#endif + + /* Considering employing a variable that prevents functions of doing anything until + * everything is initialized properly + */ + resc = resolve_hosts((const char **)argv, argc, &resh, ai_fam_pref); + if (resc < 1) { + printf("Unable to resolve hostname(s)\n"); + return -1; + } + bcast = ENABLED_OPT(BROADCAST); + if (bcast) { + const char * myargv[2]; + + myargv[0] = OPT_ARG(BROADCAST); + myargv[1] = NULL; + bcast = resolve_hosts(myargv, 1, &bcastaddr, ai_fam_pref); + } + + /* Select a certain ntp server according to simple criteria? For now + * let's just pay attention to previous KoDs. + */ + for (c = 0; c < resc && !sync_data_suc; c++) { + ai = resh[c]; + do { + hostname = addrinfo_to_str(ai); + if ((kodc = search_entry(hostname, &reason)) == 0) { + if (is_reachable(ai)) { + ow_ret = on_wire(ai, bcast ? bcastaddr[0] : NULL); + if (ow_ret < 0) + printf("on_wire failed for server %s!\n", hostname); + else + sync_data_suc = 1; + } + } else { + printf("%d prior KoD%s for %s, skipping.\n", + kodc, (kodc > 1) ? "s" : "", hostname); + free(reason); + } + free(hostname); + ai = ai->ai_next; + } while (NULL != ai); + freeaddrinfo(resh[c]); + } + free(resh); + return 0; +} + +static union { + struct pkt pkt; + char buf[1500]; +} rbuf; + +#define r_pkt rbuf.pkt + +/* The heart of (S)NTP, exchange NTP packets and compute values to correct the local clock */ +int +on_wire ( + struct addrinfo *host, + struct addrinfo *bcast + ) +{ + char logmsg[32 + INET6_ADDRSTRLEN]; + char addr_buf[INET6_ADDRSTRLEN]; + register int try; + SOCKET sock; + struct pkt x_pkt; + char *ref; + struct key *pkt_key = NULL; + int key_id = 0; + + if (ENABLED_OPT(AUTHENTICATION)) { + key_id = (int) OPT_ARG(AUTHENTICATION); + get_key(key_id, &pkt_key); + } + for(try=0; try<5; try++) { + struct timeval tv_xmt, tv_dst; + double t21, t34, delta, offset, precision, root_dispersion; + int digits, error, rpktl, sw_case; + char *hostname = NULL, *ts_str = NULL; + char *log_str; + u_fp p_rdly, p_rdsp; + l_fp p_rec, p_xmt, p_ref, p_org, xmt, tmp, dst; + + memset(&r_pkt, 0, sizeof rbuf); + memset(&x_pkt, 0, sizeof(x_pkt)); + + error = GETTIMEOFDAY(&tv_xmt, (struct timezone *)NULL); + tv_xmt.tv_sec += JAN_1970; + +#ifdef DEBUG + printf("sntp on_wire: Current time sec: %i msec: %i\n", (unsigned int) tv_xmt.tv_sec, + (unsigned int) tv_xmt.tv_usec); +#endif + + if (bcast) { + create_socket(&sock, (sockaddr_u *)bcast->ai_addr); + rpktl = recv_bcst_pkt(sock, &r_pkt, sizeof rbuf, (sockaddr_u *)bcast->ai_addr); + closesocket(sock); + } else { + int pkt_len = LEN_PKT_NOMAC; + TVTOTS(&tv_xmt, &xmt); + HTONL_FP(&xmt, &(x_pkt.xmt)); + x_pkt.stratum = STRATUM_TO_PKT(STRATUM_UNSPEC); + x_pkt.ppoll = 8; + /* FIXME! Modus broadcast + adr. check -> bdr. pkt */ + set_li_vn_mode(&x_pkt, LEAP_NOTINSYNC, 4, 3); + if (pkt_key != NULL) { + int mac_size = 20; /* max room for MAC */ + x_pkt.exten[0] = htonl(key_id); + mac_size = make_mac((char *)&x_pkt, pkt_len, mac_size, pkt_key, (char *)&x_pkt.exten[1]); + if (mac_size) + pkt_len += mac_size + 4; + } + create_socket(&sock, (sockaddr_u *)host->ai_addr); + sendpkt(sock, (sockaddr_u *)host->ai_addr, &x_pkt, pkt_len); + rpktl = recvpkt(sock, &r_pkt, sizeof rbuf, &x_pkt); + closesocket(sock); + } + + if(rpktl > 0) + sw_case = 1; + else + sw_case = rpktl; + + switch(sw_case) { + case SERVER_UNUSEABLE: + return -1; + break; + + case PACKET_UNUSEABLE: + break; + + case SERVER_AUTH_FAIL: + break; + + case KOD_DEMOBILIZE: + /* Received a DENY or RESTR KOD packet */ + hostname = addrinfo_to_str(host); + ref = (char *)&r_pkt.refid; + add_entry(hostname, ref); + + if (ENABLED_OPT(NORMALVERBOSE)) + printf("sntp on_wire: Received KOD packet with code: %c%c%c%c from %s, demobilizing all connections\n", + ref[0], ref[1], ref[2], ref[3], + hostname); + + log_str = emalloc(INET6_ADDRSTRLEN + 72); + snprintf(log_str, INET6_ADDRSTRLEN + 72, + "Received a KOD packet with code %c%c%c%c from %s, demobilizing all connections", + ref[0], ref[1], ref[2], ref[3], + hostname); + log_msg(log_str, 2); + free(log_str); + break; + + case KOD_RATE: + /* Hmm... probably we should sleep a bit here */ + break; + + case 1: + /* Convert timestamps from network to host byte order */ + p_rdly = NTOHS_FP(r_pkt.rootdelay); + p_rdsp = NTOHS_FP(r_pkt.rootdisp); + NTOHL_FP(&r_pkt.reftime, &p_ref); + NTOHL_FP(&r_pkt.org, &p_org); + NTOHL_FP(&r_pkt.rec, &p_rec); + NTOHL_FP(&r_pkt.xmt, &p_xmt); + + if (ENABLED_OPT(NORMALVERBOSE)) { + getnameinfo(host->ai_addr, host->ai_addrlen, addr_buf, + sizeof(addr_buf), NULL, 0, NI_NUMERICHOST); + printf("sntp on_wire: Received %i bytes from %s\n", rpktl, addr_buf); + } + + precision = LOGTOD(r_pkt.precision); +#ifdef DEBUG + printf("sntp precision: %f\n", precision); +#endif /* DEBUG */ + for (digits = 0; (precision *= 10.) < 1.; ++digits) + /* empty */ ; + if (digits > 6) + digits = 6; + + root_dispersion = FPTOD(p_rdsp); + +#ifdef DEBUG + printf("sntp rootdelay: %f\n", FPTOD(p_rdly)); + printf("sntp rootdisp: %f\n", root_dispersion); + + pkt_output(&r_pkt, rpktl, stdout); + + printf("sntp on_wire: r_pkt.reftime:\n"); + l_fp_output(&(r_pkt.reftime), stdout); + printf("sntp on_wire: r_pkt.org:\n"); + l_fp_output(&(r_pkt.org), stdout); + printf("sntp on_wire: r_pkt.rec:\n"); + l_fp_output(&(r_pkt.rec), stdout); + printf("sntp on_wire: r_pkt.rec:\n"); + l_fp_output_bin(&(r_pkt.rec), stdout); + printf("sntp on_wire: r_pkt.rec:\n"); + l_fp_output_dec(&(r_pkt.rec), stdout); + printf("sntp on_wire: r_pkt.xmt:\n"); + l_fp_output(&(r_pkt.xmt), stdout); +#endif + + /* Compute offset etc. */ + GETTIMEOFDAY(&tv_dst, (struct timezone *)NULL); + tv_dst.tv_sec += JAN_1970; + tmp = p_rec; + L_SUB(&tmp, &p_org); + LFPTOD(&tmp, t21); + TVTOTS(&tv_dst, &dst); + tmp = dst; + L_SUB(&tmp, &p_xmt); + LFPTOD(&tmp, t34); + offset = (t21 + t34) / 2.; + delta = t21 - t34; + + if(ENABLED_OPT(NORMALVERBOSE)) + printf("sntp on_wire:\tt21: %.6f\t\t t34: %.6f\n\t\tdelta: %.6f\t offset: %.6f\n", + t21, t34, delta, offset); + + ts_str = tv_to_str(&tv_dst); + printf("%s ", ts_str); + if(offset > 0) + printf("+"); + printf("%.*f", digits, offset); + if (root_dispersion > 0.) + printf(" +/- %f secs", root_dispersion); + printf("\n"); + free(ts_str); + + if(ENABLED_OPT(SETTOD) || ENABLED_OPT(ADJTIME)) + return set_time(offset); + + return 0; + } + } + + getnameinfo(host->ai_addr, host->ai_addrlen, addr_buf, sizeof(addr_buf), NULL, 0, NI_NUMERICHOST); + + snprintf(logmsg, sizeof(logmsg), "Received no useable packet from %s!", addr_buf); + log_msg(logmsg, 1); + + if (ENABLED_OPT(NORMALVERBOSE)) + printf("sntp on_wire: Received no useable packet from %s!\n", addr_buf); + + return -1; +} + +/* Compute the 8 bits for li_vn_mode */ +void +set_li_vn_mode ( + struct pkt *spkt, + char leap, + char version, + char mode + ) +{ + + if(leap > 3) { + debug_msg("set_li_vn_mode: leap > 3 using max. 3"); + leap = 3; + } + + if(mode > 7) { + debug_msg("set_li_vn_mode: mode > 7, using client mode 3"); + mode = 3; + } + + spkt->li_vn_mode = leap << 6; + spkt->li_vn_mode |= version << 3; + spkt->li_vn_mode |= mode; +} + +/* set_time corrects the local clock by offset with either settimeofday() or by default + * with adjtime()/adjusttimeofday(). + */ +int +set_time( + double offset + ) +{ + struct timeval tp; + + if(ENABLED_OPT(SETTOD)) { + GETTIMEOFDAY(&tp, (struct timezone *)NULL); + + tp.tv_sec += (int) offset; + tp.tv_usec += offset - (double)((int)offset); + + if(SETTIMEOFDAY(&tp, (struct timezone *)NULL) < 0) { + printf("set_time: settimeofday(): Time not set: %s\n", + strerror(errno)); + return -1; + } + return 0; + } + tp.tv_sec = (int) offset; + tp.tv_usec = offset - (double)((int)offset); + + if(ADJTIMEOFDAY(&tp, NULL) < 0) { + printf("set_time: adjtime(): Time not set: %s\n", + strerror(errno)); + return -1; + } + return 0; } diff -urN src/contrib/ntp/sntp/networking.c src.ntp/contrib/ntp/sntp/networking.c --- src/contrib/ntp/sntp/networking.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/networking.c 2010-05-19 05:53:12.000000000 +0200 @@ -0,0 +1,533 @@ +#include +#include "networking.h" + +char adr_buf[INET6_ADDRSTRLEN]; + + +/* resolve_hosts consumes an array of hostnames/addresses and its length, stores a pointer + * to the array with the resolved hosts in res and returns the size of the array res. + * pref_family enforces IPv4 or IPv6 depending on commandline options and system + * capability. If pref_family is NULL or PF_UNSPEC any compatible family will be accepted. + * Check here: Probably getaddrinfo() can do without ISC's IPv6 availability check? + */ +int +resolve_hosts ( + const char **hosts, + int hostc, + struct addrinfo ***res, + int pref_family + ) +{ + register unsigned int a; + unsigned int resc; + struct addrinfo **tres; + + if (hostc < 1 || NULL == res) + return 0; + + tres = emalloc(sizeof(struct addrinfo *) * hostc); + for (a = 0, resc = 0; a < hostc; a++) { + struct addrinfo hints; + int error; + + tres[resc] = NULL; +#ifdef DEBUG + printf("sntp resolve_hosts: Starting host resolution for %s...\n", hosts[a]); +#endif + memset(&hints, 0, sizeof(hints)); + if (AF_UNSPEC == pref_family) + hints.ai_family = PF_UNSPEC; + else + hints.ai_family = pref_family; + hints.ai_socktype = SOCK_DGRAM; + error = getaddrinfo(hosts[a], "123", &hints, &tres[resc]); + if (error) { + size_t msg_length = strlen(hosts[a]) + 21; + char *logmsg = (char *) emalloc(sizeof(char) * msg_length); + + snprintf(logmsg, msg_length, "Error looking up %s", hosts[a]); +#ifdef DEBUG + printf("%s\n", logmsg); +#endif + log_msg(logmsg, 1); + free(logmsg); + } else { +#ifdef DEBUG + for (dres = tres[resc]; dres; dres = dres->ai_next) { + getnameinfo(dres->ai_addr, dres->ai_addrlen, adr_buf, sizeof(adr_buf), NULL, 0, NI_NUMERICHOST); + STDLINE + printf("Resolv No.: %i Result of getaddrinfo for %s:\n", resc, hosts[a]); + printf("socktype: %i ", dres->ai_socktype); + printf("protocol: %i ", dres->ai_protocol); + printf("Prefered socktype: %i IP: %s\n", dres->ai_socktype, adr_buf); + STDLINE + } +#endif + resc++; + } + } + + if (resc) + *res = realloc(tres, sizeof(struct addrinfo *) * resc); + else { + free(tres); + *res = NULL; + } + return resc; +} + +/* Creates a socket and returns. */ +void +create_socket ( + SOCKET *rsock, + sockaddr_u *dest + ) +{ + *rsock = socket(AF(dest), SOCK_DGRAM, 0); + + if (-1 == *rsock && ENABLED_OPT(NORMALVERBOSE)) + printf("Failed to create UDP socket with family %d\n", AF(dest)); +} + +/* Send a packet */ +void +sendpkt ( + SOCKET rsock, + sockaddr_u *dest, + struct pkt *pkt, + int len + ) +{ + int cc; + +#ifdef DEBUG + printf("sntp sendpkt: Packet data:\n"); + pkt_output(pkt, len, stdout); +#endif + + if (ENABLED_OPT(NORMALVERBOSE)) { + getnameinfo(&dest->sa, SOCKLEN(dest), adr_buf, sizeof(adr_buf), NULL, 0, NI_NUMERICHOST); + printf("sntp sendpkt: Sending packet to %s... ", adr_buf); + } + + cc = sendto(rsock, (void *)pkt, len, 0, &dest->sa, SOCKLEN(dest)); + if (cc == SOCKET_ERROR) { +#ifdef DEBUG + printf("\n sntp sendpkt: Socket error: %i. Couldn't send packet!\n", cc); +#endif + if (errno != EWOULDBLOCK && errno != ENOBUFS) { + /* oh well */ + } + } else if (ENABLED_OPT(NORMALVERBOSE)) { + printf("Packet sent.\n"); + } +} + +/* Receive raw data */ +int +recvdata( + SOCKET rsock, + sockaddr_u *sender, + char *rdata, + int rdata_length + ) +{ + GETSOCKNAME_SOCKLEN_TYPE slen; + int recvc; + +#ifdef DEBUG + printf("sntp recvdata: Trying to receive data from...\n"); +#endif + slen = sizeof(*sender); + recvc = recvfrom(rsock, rdata, rdata_length, 0, + &sender->sa, &slen); +#ifdef DEBUG + if (recvc > 0) { + printf("Received %d bytes from %s:\n", recvc, stoa(sender)); + pkt_output((struct pkt *) rdata, recvc, stdout); + } else { + saved_errno = errno; + printf("recvfrom error %d (%s)\n", errno, strerror(errno)); + errno = saved_errno; + } +#endif + return recvc; +} + +/* Receive data from broadcast. Couldn't finish that. Need to do some digging + * here, especially for protocol independence and IPv6 multicast */ +int +recv_bcst_data ( + SOCKET rsock, + char *rdata, + int rdata_len, + sockaddr_u *sas, + sockaddr_u *ras + ) +{ + char *buf; + int btrue = 1; + int recv_bytes = 0; + int rdy_socks; + GETSOCKNAME_SOCKLEN_TYPE ss_len; + struct timeval timeout_tv; + fd_set bcst_fd; +#ifdef MCAST + struct ip_mreq mdevadr; + TYPEOF_IP_MULTICAST_LOOP mtrue = 1; +#endif + + setsockopt(rsock, SOL_SOCKET, SO_REUSEADDR, &btrue, sizeof(btrue)); + if (IS_IPV4(sas)) { + if (bind(rsock, &sas->sa, SOCKLEN(sas)) < 0) { + if (ENABLED_OPT(NORMALVERBOSE)) + printf("sntp recv_bcst_data: Couldn't bind() address %s:%d.\n", + stoa(sas), SRCPORT(sas)); + } + +#ifdef MCAST + if (setsockopt(rsock, IPPROTO_IP, IP_MULTICAST_LOOP, &mtrue, sizeof(mtrue)) < 0) { + /* some error message regarding setting up multicast loop */ + return BROADCAST_FAILED; + } + mdevadr.imr_multiaddr.s_addr = NSRCADR(sas); + mdevadr.imr_interface.s_addr = htonl(INADDR_ANY); + if (mdevadr.imr_multiaddr.s_addr == -1) { + if (ENABLED_OPT(NORMALVERBOSE)) { + printf("sntp recv_bcst_data: %s:%d is not a broad-/multicast address, aborting...\n", + stoa(sas), SRCPORT(sas)); + } + return BROADCAST_FAILED; + } + if (setsockopt(rsock, IPPROTO_IP, IP_ADD_MEMBERSHIP, &mdevadr, sizeof(mdevadr)) < 0) { + if (ENABLED_OPT(NORMALVERBOSE)) { + buf = ss_to_str(sas); + printf("sntp recv_bcst_data: Couldn't add IP membership for %s\n", buf); + free(buf); + } + } +#endif /* MCAST */ + } +#ifdef ISC_PLATFORM_HAVEIPV6 + else if (IS_IPV6(sas)) { + if (bind(rsock, &sas->sa, SOCKLEN(sas)) < 0) { + if (ENABLED_OPT(NORMALVERBOSE)) + printf("sntp recv_bcst_data: Couldn't bind() address.\n"); + } +#ifdef INCLUDE_IPV6_MULTICAST_SUPPORT + struct ipv6_mreq mdevadr; + if (setsockopt(rsock, IPPROTO_IPV6, IPV6_MULTICAST_LOOP, &btrue, sizeof (btrue)) < 0) { + /* some error message regarding setting up multicast loop */ + return BROADCAST_FAILED; + } + memset(&mdevadr, 0, sizeof(mdevadr)); + mdevadr.ipv6mr_multiaddr = SOCK_ADDR6(sas); + if (!IN6_IS_ADDR_MULTICAST(&mdevadr.ipv6mr_multiaddr)) { + if (ENABLED_OPT(NORMALVERBOSE)) { + buf = ss_to_str(sas); + printf("sntp recv_bcst_data: %s is not a broad-/multicast address, aborting...\n", buf); + free(buf); + } + return BROADCAST_FAILED; + } + if (setsockopt(rsock, IPPROTO_IPV6, IPV6_JOIN_GROUP, &mdevadr, sizeof(mdevadr)) < 0) { + if (ENABLED_OPT(NORMALVERBOSE)) { + buf = ss_to_str(sas); + printf("sntp recv_bcst_data: Couldn't join group for %s\n", buf); + free(buf); + } + } +#endif /* INCLUDE_IPV6_MULTICAST_SUPPORT */ + } +#endif /* ISC_PLATFORM_HAVEIPV6 */ + FD_ZERO(&bcst_fd); + FD_SET(rsock, &bcst_fd); + if (ENABLED_OPT(TIMEOUT)) + timeout_tv.tv_sec = (int) OPT_ARG(TIMEOUT); + else + timeout_tv.tv_sec = 68; /* ntpd broadcasts every 64s */ + timeout_tv.tv_usec = 0; + rdy_socks = select(rsock + 1, &bcst_fd, 0, 0, &timeout_tv); + switch (rdy_socks) { + case -1: + if (ENABLED_OPT(NORMALVERBOSE)) + perror("sntp recv_bcst_data: select()"); + return BROADCAST_FAILED; + break; + case 0: + if (ENABLED_OPT(NORMALVERBOSE)) + printf("sntp recv_bcst_data: select() reached timeout (%u sec), aborting.\n", + (unsigned)timeout_tv.tv_sec); + return BROADCAST_FAILED; + break; + default: + ss_len = sizeof(*ras); + recv_bytes = recvfrom(rsock, rdata, rdata_len, 0, &ras->sa, &ss_len); + break; + } + if (recv_bytes == -1) { + if (ENABLED_OPT(NORMALVERBOSE)) + perror("sntp recv_bcst_data: recvfrom:"); + recv_bytes = BROADCAST_FAILED; + } +#ifdef MCAST + if (IS_IPV4(sas)) + setsockopt(rsock, IPPROTO_IP, IP_DROP_MEMBERSHIP, &btrue, sizeof(btrue)); +#endif +#ifdef INCLUDE_IPV6_MULTICAST_SUPPORT + if (IS_IPV6(sas)) + setsockopt(rsock, IPPROTO_IPV6, IPV6_LEAVE_GROUP, &btrue, sizeof(btrue)); +#endif + return recv_bytes; +} + +static int +process_pkt ( + struct pkt *rpkt, + sockaddr_u *sas, + int pkt_len, + int mode, + char * func_name + ) +{ + unsigned int key_id = 0; + struct key *pkt_key = NULL; + int is_authentic = 0; + unsigned int exten_words, exten_words_used = 0; + int mac_size; + /* + * Parse the extension field if present. We figure out whether + * an extension field is present by measuring the MAC size. If + * the number of words following the packet header is 0, no MAC + * is present and the packet is not authenticated. If 1, the + * packet is a crypto-NAK; if 3, the packet is authenticated + * with DES; if 5, the packet is authenticated with MD5; if 6, + * the packet is authenticated with SHA. If 2 or 4, the packet + * is a runt and discarded forthwith. If greater than 6, an + * extension field is present, so we subtract the length of the + * field and go around again. + */ + if (pkt_len < LEN_PKT_NOMAC || (pkt_len & 3) != 0) { +unusable: + if (ENABLED_OPT(NORMALVERBOSE)) + printf("sntp %s: Funny packet length: %i. Discarding package.\n", func_name, pkt_len); + return PACKET_UNUSEABLE; + } + /* skip past the extensions, if any */ + exten_words = ((unsigned)pkt_len - LEN_PKT_NOMAC) >> 2; + while (exten_words > 6) { + unsigned int exten_len; + exten_len = ntohl(rpkt->exten[exten_words_used]) & 0xffff; + exten_len = (exten_len + 7) >> 2; /* convert to words, add 1 */ + if (exten_len > exten_words || exten_len < 5) + goto unusable; + exten_words -= exten_len; + exten_words_used += exten_len; + } + + switch (exten_words) { + case 1: + key_id = ntohl(rpkt->exten[exten_words_used]); + printf("Crypto NAK = 0x%08x\n", key_id); + break; + case 5: + case 6: + /* Look for the key used by the server in the specified keyfile + * and if existent, fetch it or else leave the pointer untouched */ + key_id = ntohl(rpkt->exten[exten_words_used]); + get_key(key_id, &pkt_key); + if (!pkt_key) { + printf("unrecognized key ID = 0x%08x\n", key_id); + break; + } + /* Seems like we've got a key with matching keyid */ + /* Generate a md5sum of the packet with the key from our keyfile + * and compare those md5sums */ + mac_size = exten_words << 2; + if (!auth_md5((char *)rpkt, pkt_len - mac_size, mac_size - 4, pkt_key)) { + break; + } + /* Yay! Things worked out! */ + if (ENABLED_OPT(NORMALVERBOSE)) { + char *hostname = ss_to_str(sas); + printf("sntp %s: packet received from %s successfully authenticated using key id %i.\n", + func_name, hostname, key_id); + free(hostname); + } + is_authentic = 1; + break; + case 0: + break; + default: + goto unusable; + break; + } + if (!is_authentic) { + if (ENABLED_OPT(AUTHENTICATION)) { + /* We want a authenticated packet */ + if (ENABLED_OPT(NORMALVERBOSE)) { + char *hostname = ss_to_str(sas); + printf("sntp %s: packet received from %s is not authentic. Will discard it.\n", + func_name, hostname); + free(hostname); + } + return SERVER_AUTH_FAIL; + } + /* We don't know if the user wanted authentication so let's + * use it anyways */ + if (ENABLED_OPT(NORMALVERBOSE)) { + char *hostname = ss_to_str(sas); + printf("sntp %s: packet received from %s is not authentic. Authentication not enforced.\n", + func_name, hostname); + free(hostname); + } + } + /* Check for server's ntp version */ + if (PKT_VERSION(rpkt->li_vn_mode) < NTP_OLDVERSION || + PKT_VERSION(rpkt->li_vn_mode) > NTP_VERSION) { + if (ENABLED_OPT(NORMALVERBOSE)) + printf("sntp %s: Packet shows wrong version (%i)\n", + func_name, PKT_VERSION(rpkt->li_vn_mode)); + return SERVER_UNUSEABLE; + } + /* We want a server to sync with */ + if (PKT_MODE(rpkt->li_vn_mode) != mode && + PKT_MODE(rpkt->li_vn_mode) != MODE_PASSIVE) { + if (ENABLED_OPT(NORMALVERBOSE)) + printf("sntp %s: mode %d stratum %i\n", func_name, + PKT_MODE(rpkt->li_vn_mode), rpkt->stratum); + return SERVER_UNUSEABLE; + } + /* Stratum is unspecified (0) check what's going on */ + if (STRATUM_PKT_UNSPEC == rpkt->stratum) { + char *ref_char; + if (ENABLED_OPT(NORMALVERBOSE)) + printf("sntp %s: Stratum unspecified, going to check for KOD (stratum: %i)\n", + func_name, rpkt->stratum); + ref_char = (char *) &rpkt->refid; + if (ENABLED_OPT(NORMALVERBOSE)) + printf("sntp %s: Packet refid: %c%c%c%c\n", func_name, + ref_char[0], ref_char[1], ref_char[2], ref_char[3]); + /* If it's a KOD packet we'll just use the KOD information */ + if (ref_char[0] != 'X') { + if (strncmp(ref_char, "DENY", 4)) + return KOD_DEMOBILIZE; + if (strncmp(ref_char, "RSTR", 4)) + return KOD_DEMOBILIZE; + if (strncmp(ref_char, "RATE", 4)) + return KOD_RATE; + /* There are other interesting kiss codes which might be interesting for authentication */ + } + } + /* If the server is not synced it's not really useable for us */ + if (LEAP_NOTINSYNC == PKT_LEAP(rpkt->li_vn_mode)) { + if (ENABLED_OPT(NORMALVERBOSE)) + printf("sntp %s: Server not in sync, skipping this server\n", func_name); + return SERVER_UNUSEABLE; + } + return pkt_len; +} + +int +recv_bcst_pkt ( + SOCKET rsock, + struct pkt *rpkt, + unsigned int rsize, + sockaddr_u *sas + ) +{ + sockaddr_u sender; + int pkt_len = recv_bcst_data(rsock, (char *)rpkt, rsize, sas, &sender); + if (pkt_len < 0) { + return BROADCAST_FAILED; + } + pkt_len = process_pkt(rpkt, sas, pkt_len, MODE_BROADCAST, "recv_bcst_pkt"); + return pkt_len; +} + +/* Fetch data, check if it's data for us and whether it's useable or not. If not, return + * a failure code so we can delete this server from our list and continue with another one. + */ +int +recvpkt ( + SOCKET rsock, + struct pkt *rpkt, /* received packet (response) */ + unsigned int rsize, /* size of rpkt buffer */ + struct pkt *spkt /* sent packet (request) */ + ) +{ + int rdy_socks; + int pkt_len; + sockaddr_u sender; + struct timeval timeout_tv; + fd_set recv_fd; + + FD_ZERO(&recv_fd); + FD_SET(rsock, &recv_fd); + if (ENABLED_OPT(TIMEOUT)) + timeout_tv.tv_sec = (int) OPT_ARG(TIMEOUT); + else + timeout_tv.tv_sec = 68; /* ntpd broadcasts every 64s */ + timeout_tv.tv_usec = 0; + rdy_socks = select(rsock + 1, &recv_fd, 0, 0, &timeout_tv); + switch (rdy_socks) { + case -1: + if (ENABLED_OPT(NORMALVERBOSE)) + perror("sntp recvpkt: select()"); + return PACKET_UNUSEABLE; + break; + case 0: + if (ENABLED_OPT(NORMALVERBOSE)) + printf("sntp recvpkt: select() reached timeout (%u sec), aborting.\n", + (unsigned)timeout_tv.tv_sec); + return PACKET_UNUSEABLE; + break; + default: + break; + } + pkt_len = recvdata(rsock, &sender, (char *)rpkt, rsize); + if (pkt_len > 0) + pkt_len = process_pkt(rpkt, &sender, pkt_len, MODE_SERVER, "recvpkt"); + if (pkt_len < 0) + return pkt_len; + /* + * Decode the org timestamp and make sure we're getting a response + * to our last request. + */ +#ifdef DEBUG + printf("rpkt->org:\n"); + l_fp_output(&rpkt->org, stdout); + printf("spkt->xmt:\n"); + l_fp_output(&spkt->xmt, stdout); +#endif + if (!L_ISEQU(&rpkt->org, &spkt->xmt)) { + if (ENABLED_OPT(NORMALVERBOSE)) + printf("sntp recvpkt: pkt.org and peer.xmt differ\n"); + return PACKET_UNUSEABLE; + } + return pkt_len; +} + +/* + * is_reachable - check to see if we have a route to given destination + */ +int +is_reachable ( + struct addrinfo *dst + ) +{ + SOCKET sockfd = socket(dst->ai_family, SOCK_DGRAM, 0); + + if (-1 == sockfd) { +#ifdef DEBUG + printf("is_reachable: Couldn't create socket\n"); +#endif + return 0; + } + if (connect(sockfd, dst->ai_addr, SOCKLEN((sockaddr_u *)dst->ai_addr))) { + closesocket(sockfd); + return 0; + } + closesocket(sockfd); + return 1; +} diff -urN src/contrib/ntp/sntp/networking.h src.ntp/contrib/ntp/sntp/networking.h --- src/contrib/ntp/sntp/networking.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/networking.h 2010-05-11 09:46:54.000000000 +0200 @@ -0,0 +1,119 @@ +#ifndef NETWORKING_H +#define NETWORKING_H + +#include +#include + +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include + +#include "crypto.h" +#include "log.h" +#include "sntp-opts.h" +#include "utilities.h" + +/* FIXME To be replaced by the constants in ntp.h */ +#define SERVER_UNUSEABLE -1 /* Skip server */ +#define PACKET_UNUSEABLE -2 /* Discard packet and try to get a useable packet again if not tried too often */ +#define SERVER_AUTH_FAIL -3 /* Authentication failed, act upon settings */ +#define KOD_DEMOBILIZE -4 /* KOD packet with code DENY or RSTR, stop all communication and save KOD information */ +#define KOD_RATE -5 /* KOD packet with code RATE, reduce poll intervall */ +#define BROADCAST_FAILED -6 + + +/* From ntpdate.c */ +int is_reachable (struct addrinfo *dst); + +int resolve_hosts (const char **hosts, int hostc, struct addrinfo ***res, int pref_family); + +void create_socket (SOCKET *rsock, sockaddr_u *dest); + +void sendpkt (SOCKET rsock, sockaddr_u *dest, struct pkt *pkt, int len); + +int recvdata (SOCKET rsock, sockaddr_u *sender, char *rdata, int rdata_len); + +int recvpkt (SOCKET rsock, struct pkt *rpkt, unsigned int rsize, struct pkt *spkt); + +int recv_bcst_data (SOCKET rsock, char *rdata, int rdata_len, sockaddr_u *sas, sockaddr_u *ras); + +int recv_bcst_pkt (SOCKET rsock, struct pkt *rpkt, unsigned int rsize, sockaddr_u *sas); + +/* Shortened peer structure. Not absolutely necessary yet */ +struct speer { + struct speer *next; + sockaddr_u srcadr; + u_char version; + u_char hmode; + u_char hpoll; + u_char minpoll; + u_char maxpoll; + u_int flags; + u_char num_events; + u_char ttl; + u_char leap; + u_char pmode; + u_char stratum; + u_char ppoll; + u_char precision; /* should be s_char */ + u_int32 refid; + l_fp reftime; + keyid_t keyid; + +#ifdef OPENSSL +#define clear_to_zero opcode + u_int32 opcode; /* last request opcode */ + associd_t assoc; /* peer association ID */ + u_int32 crypto; /* peer status word */ + EVP_PKEY *pkey; /* public key */ + const EVP_MD *digest; /* message digest algorithm */ + char *subject; /* certificate subject name */ + char *issuer; /* certificate issuer name */ + struct cert_info *xinfo; /* issuer certificate */ + keyid_t pkeyid; /* previous key ID */ + keyid_t hcookie; /* host cookie */ + keyid_t pcookie; /* peer cookie */ + const struct pkey_info *ident_pkey; /* identity key */ + BIGNUM *iffval; /* identity challenge (IFF, GQ, MV) */ + const BIGNUM *grpkey; /* identity challenge key (GQ) */ + struct value cookval; /* receive cookie values */ + struct value recval; /* receive autokey values */ + struct exten *cmmd; /* extension pointer */ + u_long refresh; /* next refresh epoch */ + + /* + * Variables used by authenticated server + */ + keyid_t *keylist; /* session key ID list */ + int keynumber; /* current key number */ + struct value encrypt; /* send encrypt values */ + struct value sndval; /* send autokey values */ +#else /* OPENSSL */ +#define clear_to_zero status +#endif /* OPENSSL */ + + l_fp rec; /* receive time stamp */ + l_fp xmt; /* transmit time stamp */ + l_fp dst; /* destination timestamp */ + l_fp aorg; /* origin timestamp */ + l_fp borg; /* alternate origin timestamp */ + double offset; /* peer clock offset */ + double delay; /* peer roundtrip delay */ +}; + + + + + +#endif diff -urN src/contrib/ntp/sntp/sntp-opts.c src.ntp/contrib/ntp/sntp/sntp-opts.c --- src/contrib/ntp/sntp/sntp-opts.c 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/sntp-opts.c 2010-07-09 04:25:38.000000000 +0200 @@ -1,11 +1,11 @@ /* * EDIT THIS FILE WITH CAUTION (sntp-opts.c) * - * It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:49 AM EST + * It has been AutoGen-ed July 9, 2010 at 02:25:37 AM by AutoGen 5.10 * From the definitions sntp-opts.def * and the template file options * - * Generated from AutoOpts 29:0:4 templates. + * Generated from AutoOpts 33:0:8 templates. */ /* @@ -19,92 +19,15 @@ * * This source file is copyrighted and licensed under the following terms: * - * sntp copyright 1970-2006 ntp.org - all rights reserved + * sntp copyright (c) 1970-2010 David L. Mills and/or others - all rights reserved * - * General Public Licence for the software known as MSNTP - * ------------------------------------------------------ - * - * (c) Copyright, N.M. Maclaren, 1996, 1997, 2000 - * (c) Copyright, University of Cambridge, 1996, 1997, 2000 - * - * - * - * Free use of MSNTP in source and binary forms is permitted, provided that this - * entire licence is duplicated in all copies, and that any documentation, - * announcements, and other materials related to use acknowledge that the software - * was developed by N.M. Maclaren (hereafter refered to as the Author) at the - * University of Cambridge. Neither the name of the Author nor the University of - * Cambridge may be used to endorse or promote products derived from this material - * without specific prior written permission. - * - * The Author and the University of Cambridge retain the copyright and all other - * legal rights to the software and make it available non-exclusively. All users - * must ensure that the software in all its derivations carries a copyright notice - * in the form: - * (c) Copyright N.M. Maclaren, - * (c) Copyright University of Cambridge. - * - * - * - * NO WARRANTY - * - * Because the MSNTP software is licensed free of charge, the Author and the - * University of Cambridge provide absolutely no warranty, either expressed or - * implied, including, but not limited to, the implied warranties of - * merchantability and fitness for a particular purpose. The entire risk as to - * the quality and performance of the MSNTP software is with you. Should MSNTP - * prove defective, you assume the cost of all necessary servicing or repair. - * - * In no event, unless required by law, will the Author or the University of - * Cambridge, or any other party who may modify and redistribute this software as - * permitted in accordance with the provisions below, be liable for damages for - * any losses whatsoever, including but not limited to lost profits, lost monies, - * lost or corrupted data, or other special, incidental or consequential losses - * that may arise out of the use or inability to use the MSNTP software. - * - * - * - * COPYING POLICY - * - * Permission is hereby granted for copying and distribution of copies of the - * MSNTP source and binary files, and of any part thereof, subject to the - * following licence conditions: - * - * 1. You may distribute MSNTP or components of MSNTP, with or without additions - * developed by you or by others. No charge, other than an "at-cost" distribution - * fee, may be charged for copies, derivations, or distributions of this material - * without the express written consent of the copyright holders. - * - * 2. You may also distribute MSNTP along with any other product for sale, - * provided that the cost of the bundled package is the same regardless of whether - * MSNTP is included or not, and provided that those interested only in MSNTP must - * be notified that it is a product freely available from the University of - * Cambridge. - * - * 3. If you distribute MSNTP software or parts of MSNTP, with or without - * additions developed by you or others, then you must either make available the - * source to all portions of the MSNTP system (exclusive of any additions made by - * you or by others) upon request, or instead you may notify anyone requesting - * source that it is freely available from the University of Cambridge. - * - * 4. You may not omit any of the copyright notices on either the source files, - * the executable files, or the documentation. - * - * 5. You may not omit transmission of this License agreement with whatever - * portions of MSNTP that are distributed. - * - * 6. Any users of this software must be notified that it is without warranty or - * guarantee of any nature, express or implied, nor is there any fitness for use - * represented. - * - * - * October 1996 - * April 1997 - * October 2000 + * see html/copyright.html */ - +#include #include +#include +#include #define OPTION_CODE_COMPILE 1 #include "sntp-opts.h" @@ -112,69 +35,16 @@ #ifdef __cplusplus extern "C" { #endif + +/* TRANSLATORS: choose the translation for option names wisely because you + cannot ever change your mind. */ tSCC zCopyright[] = - "sntp copyright (c) 1970-2006 ntp.org, all rights reserved"; -tSCC zCopyrightNotice[] = - -/* extracted from sntp-opts.def near line 12 */ -" General Public Licence for the software known as MSNTP\n\ - ------------------------------------------------------\n\n\ -\t (c) Copyright, N.M. Maclaren, 1996, 1997, 2000\n\ -\t (c) Copyright, University of Cambridge, 1996, 1997, 2000\n\n\n\n\ -Free use of MSNTP in source and binary forms is permitted, provided that this\n\ -entire licence is duplicated in all copies, and that any documentation,\n\ -announcements, and other materials related to use acknowledge that the software\n\ -was developed by N.M. Maclaren (hereafter refered to as the Author) at the\n\ -University of Cambridge. Neither the name of the Author nor the University of\n\ -Cambridge may be used to endorse or promote products derived from this material\n\ -without specific prior written permission.\n\n\ -The Author and the University of Cambridge retain the copyright and all other\n\ -legal rights to the software and make it available non-exclusively. All users\n\ -must ensure that the software in all its derivations carries a copyright notice\n\ -in the form:\n\ -\t (c) Copyright N.M. Maclaren,\n\ -\t (c) Copyright University of Cambridge.\n\n\n\n\ - NO WARRANTY\n\n\ -Because the MSNTP software is licensed free of charge, the Author and the\n\ -University of Cambridge provide absolutely no warranty, either expressed or\n\ -implied, including, but not limited to, the implied warranties of\n\ -merchantability and fitness for a particular purpose. The entire risk as to\n\ -the quality and performance of the MSNTP software is with you. Should MSNTP\n\ -prove defective, you assume the cost of all necessary servicing or repair.\n\n\ -In no event, unless required by law, will the Author or the University of\n\ -Cambridge, or any other party who may modify and redistribute this software as\n\ -permitted in accordance with the provisions below, be liable for damages for\n\ -any losses whatsoever, including but not limited to lost profits, lost monies,\n\ -lost or corrupted data, or other special, incidental or consequential losses\n\ -that may arise out of the use or inability to use the MSNTP software.\n\n\n\n\ - COPYING POLICY\n\n\ -Permission is hereby granted for copying and distribution of copies of the\n\ -MSNTP source and binary files, and of any part thereof, subject to the\n\ -following licence conditions:\n\n\ -1. You may distribute MSNTP or components of MSNTP, with or without additions\n\ -developed by you or by others. No charge, other than an \"at-cost\" distribution\n\ -fee, may be charged for copies, derivations, or distributions of this material\n\ -without the express written consent of the copyright holders.\n\n\ -2. You may also distribute MSNTP along with any other product for sale,\n\ -provided that the cost of the bundled package is the same regardless of whether\n\ -MSNTP is included or not, and provided that those interested only in MSNTP must\n\ -be notified that it is a product freely available from the University of\n\ -Cambridge.\n\n\ -3. If you distribute MSNTP software or parts of MSNTP, with or without\n\ -additions developed by you or others, then you must either make available the\n\ -source to all portions of the MSNTP system (exclusive of any additions made by\n\ -you or by others) upon request, or instead you may notify anyone requesting\n\ -source that it is freely available from the University of Cambridge.\n\n\ -4. You may not omit any of the copyright notices on either the source files,\n\ -the executable files, or the documentation.\n\n\ -5. You may not omit transmission of this License agreement with whatever\n\ -portions of MSNTP that are distributed.\n\n\ -6. Any users of this software must be notified that it is without warranty or\n\ -guarantee of any nature, express or implied, nor is there any fitness for use\n\ -represented.\n\n\n\ -October 1996\n\ -April 1997\n\ -October 2000"; + "sntp copyright (c) 1970-2010 David L. Mills and/or others, all rights reserved" +/* extracted from ../include/copyright.def near line 8 */ +; +tSCC zCopyrightNotice[24] = +"see html/copyright.html"; + extern tUsageProc optionUsage; #ifndef NULL @@ -186,87 +56,91 @@ #ifndef EXIT_FAILURE # define EXIT_FAILURE 1 #endif + /* - * Ipv4 option description: + * Ipv4 option description with + * "Must also have options" and "Incompatible options": */ tSCC zIpv4Text[] = "Force IPv4 DNS name resolution"; tSCC zIpv4_NAME[] = "IPV4"; tSCC zIpv4_Name[] = "ipv4"; +static const int + aIpv4CantList[] = { + INDEX_OPT_IPV6, NO_EQUIVALENT }; #define IPV4_FLAGS (OPTST_DISABLED) /* - * Ipv6 option description: + * Ipv6 option description with + * "Must also have options" and "Incompatible options": */ tSCC zIpv6Text[] = "Force IPv6 DNS name resolution"; tSCC zIpv6_NAME[] = "IPV6"; tSCC zIpv6_Name[] = "ipv6"; +static const int + aIpv6CantList[] = { + INDEX_OPT_IPV4, NO_EQUIVALENT }; #define IPV6_FLAGS (OPTST_DISABLED) /* - * Unprivport option description: - */ -tSCC zUnprivportText[] = - "Use an unprivileged port"; -tSCC zUnprivport_NAME[] = "UNPRIVPORT"; -tSCC zUnprivport_Name[] = "unprivport"; -#define UNPRIVPORT_FLAGS (OPTST_DISABLED) - -/* - * Normalverbose option description with - * "Must also have options" and "Incompatible options": + * Normalverbose option description: */ tSCC zNormalverboseText[] = - "Slightly verbose"; + "Normal verbose"; tSCC zNormalverbose_NAME[] = "NORMALVERBOSE"; tSCC zNormalverbose_Name[] = "normalverbose"; -static const int - aNormalverboseCantList[] = { - INDEX_OPT_EXTRAVERBOSE, - INDEX_OPT_MEGAVERBOSE, NO_EQUIVALENT }; #define NORMALVERBOSE_FLAGS (OPTST_DISABLED) /* - * Extraverbose option description with + * Kod option description: + */ +tSCC zKodText[] = + "KoD history filename"; +tSCC zKod_NAME[] = "KOD"; +tSCC zKod_Name[] = "kod"; +#define KOD_FLAGS (OPTST_DISABLED \ + | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) + +/* + * Syslog option description with * "Must also have options" and "Incompatible options": */ -tSCC zExtraverboseText[] = - "Extra verbose"; -tSCC zExtraverbose_NAME[] = "EXTRAVERBOSE"; -tSCC zExtraverbose_Name[] = "extraverbose"; +tSCC zSyslogText[] = + "Logging with syslog"; +tSCC zSyslog_NAME[] = "SYSLOG"; +tSCC zSyslog_Name[] = "syslog"; static const int - aExtraverboseCantList[] = { - INDEX_OPT_NORMALVERBOSE, - INDEX_OPT_MEGAVERBOSE, NO_EQUIVALENT }; -#define EXTRAVERBOSE_FLAGS (OPTST_DISABLED) + aSyslogCantList[] = { + INDEX_OPT_FILELOG, NO_EQUIVALENT }; +#define SYSLOG_FLAGS (OPTST_DISABLED) /* - * Megaverbose option description with + * Filelog option description with * "Must also have options" and "Incompatible options": */ -tSCC zMegaverboseText[] = - "Mega verbose"; -tSCC zMegaverbose_NAME[] = "MEGAVERBOSE"; -tSCC zMegaverbose_Name[] = "megaverbose"; +tSCC zFilelogText[] = + "Log to specified logfile"; +tSCC zFilelog_NAME[] = "FILELOG"; +tSCC zFilelog_Name[] = "filelog"; static const int - aMegaverboseCantList[] = { - INDEX_OPT_NORMALVERBOSE, - INDEX_OPT_EXTRAVERBOSE, NO_EQUIVALENT }; -#define MEGAVERBOSE_FLAGS (OPTST_DISABLED) + aFilelogCantList[] = { + INDEX_OPT_SYSLOG, NO_EQUIVALENT }; +#define FILELOG_FLAGS (OPTST_DISABLED \ + | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) /* - * Settimeofday option description with + * Settod option description with * "Must also have options" and "Incompatible options": */ -tSCC zSettimeofdayText[] = +tSCC zSettodText[] = "Set (step) the time with settimeofday()"; -tSCC zSettimeofday_NAME[] = "SETTIMEOFDAY"; -tSCC zSettimeofday_Name[] = "settimeofday"; +tSCC zSettod_NAME[] = "SETTOD"; +tSCC zSettod_Name[] = "settod"; static const int - aSettimeofdayCantList[] = { + aSettodCantList[] = { INDEX_OPT_ADJTIME, NO_EQUIVALENT }; -#define SETTIMEOFDAY_FLAGS (OPTST_DISABLED) +#define SETTOD_FLAGS (OPTST_DISABLED) /* * Adjtime option description with @@ -278,30 +152,77 @@ tSCC zAdjtime_Name[] = "adjtime"; static const int aAdjtimeCantList[] = { - INDEX_OPT_SETTIMEOFDAY, NO_EQUIVALENT }; + INDEX_OPT_SETTOD, NO_EQUIVALENT }; #define ADJTIME_FLAGS (OPTST_DISABLED) /* - * Help/More_Help/Version option descriptions: + * Broadcast option description: + */ +tSCC zBroadcastText[] = + "Use broadcasts to the address specified for synchronisation"; +tSCC zBroadcast_NAME[] = "BROADCAST"; +tSCC zBroadcast_Name[] = "broadcast"; +#define BROADCAST_FLAGS (OPTST_DISABLED \ + | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) + +/* + * Timeout option description: */ -tSCC zHelpText[] = "Display usage information and exit"; -tSCC zHelp_Name[] = "help"; +tSCC zTimeoutText[] = + "Specify the number of seconds to wait for broadcasts"; +tSCC zTimeout_NAME[] = "TIMEOUT"; +tSCC zTimeout_Name[] = "timeout"; +#define zTimeoutDefaultArg ((char const*)68) +#define TIMEOUT_FLAGS (OPTST_DISABLED \ + | OPTST_SET_ARGTYPE(OPARG_TYPE_NUMERIC)) -tSCC zMore_HelpText[] = "Extended usage information passed thru pager"; -tSCC zMore_Help_Name[] = "more-help"; +/* + * Authentication option description: + */ +tSCC zAuthenticationText[] = + "Enable authentication with the key auth-keynumber"; +tSCC zAuthentication_NAME[] = "AUTHENTICATION"; +tSCC zAuthentication_Name[] = "authentication"; +#define AUTHENTICATION_FLAGS (OPTST_DISABLED \ + | OPTST_SET_ARGTYPE(OPARG_TYPE_NUMERIC)) -tSCC zVersionText[] = "Output version information and exit"; -tSCC zVersion_Name[] = "version"; +/* + * Keyfile option description: + */ +tSCC zKeyfileText[] = + "Specify a keyfile. SNTP will look in this file for the key specified with -a"; +tSCC zKeyfile_NAME[] = "KEYFILE"; +tSCC zKeyfile_Name[] = "keyfile"; +#define KEYFILE_FLAGS (OPTST_DISABLED \ + | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) /* - * Save/Load_Opts option description: + * Help/More_Help/Version option descriptions: */ +tSCC zHelpText[] = "Display extended usage information and exit"; +tSCC zHelp_Name[] = "help"; +#ifdef HAVE_WORKING_FORK +#define OPTST_MORE_HELP_FLAGS (OPTST_IMM | OPTST_NO_INIT) +tSCC zMore_Help_Name[] = "more-help"; +tSCC zMore_HelpText[] = "Extended usage information passed thru pager"; +#else +#define OPTST_MORE_HELP_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#define zMore_Help_Name NULL +#define zMore_HelpText NULL +#endif +#ifdef NO_OPTIONAL_OPT_ARGS +# define OPTST_VERSION_FLAGS OPTST_IMM | OPTST_NO_INIT +#else +# define OPTST_VERSION_FLAGS OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ + OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT +#endif + +tSCC zVersionText[] = "Output version information and exit"; +tSCC zVersion_Name[] = "version"; tSCC zSave_OptsText[] = "Save the option state to a config file"; tSCC zSave_Opts_Name[] = "save-opts"; - tSCC zLoad_OptsText[] = "Load options from a config file"; tSCC zLoad_Opts_NAME[] = "LOAD_OPTS"; - tSCC zNotLoad_Opts_Name[] = "no-load-opts"; tSCC zNotLoad_Opts_Pfx[] = "no"; #define zLoad_Opts_Name (zNotLoad_Opts_Name + 3) @@ -314,7 +235,7 @@ * if multiple copies are allowed. */ extern tOptProc - optionPagedUsage, optionVersionStderr; + optionNumericVal, optionPagedUsage, optionVersionStderr; static tOptProc doUsageOpt; @@ -323,7 +244,7 @@ * When not under test, there are different procs to use */ extern tOptProc - optionPagedUsage, optionPrintVersion; + optionNumericVal, optionPagedUsage, optionPrintVersion; static tOptProc doUsageOpt; #endif /* defined(TEST_SNTP_OPTS) */ @@ -339,87 +260,87 @@ */ static tOptDesc optDesc[ OPTION_CT ] = { { /* entry idx, value */ 0, VALUE_OPT_IPV4, - /* equiv idx, value */ NO_EQUIVALENT, 0, + /* equiv idx, value */ 0, VALUE_OPT_IPV4, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ IPV4_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, + /* must/cannot opts */ NULL, aIpv4CantList, /* option proc */ NULL, /* desc, NAME, name */ zIpv4Text, zIpv4_NAME, zIpv4_Name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ 1, VALUE_OPT_IPV6, - /* equiv idx, value */ NOLIMIT, NOLIMIT, - /* equivalenced to */ INDEX_OPT_IPV4, + /* equiv idx, value */ 1, VALUE_OPT_IPV6, + /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ IPV6_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, + /* must/cannot opts */ NULL, aIpv6CantList, /* option proc */ NULL, /* desc, NAME, name */ zIpv6Text, zIpv6_NAME, zIpv6_Name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 2, VALUE_OPT_UNPRIVPORT, - /* equiv idx, value */ 2, VALUE_OPT_UNPRIVPORT, + { /* entry idx, value */ 2, VALUE_OPT_NORMALVERBOSE, + /* equiv idx, value */ 2, VALUE_OPT_NORMALVERBOSE, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ UNPRIVPORT_FLAGS, 0, + /* opt state flags */ NORMALVERBOSE_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ NULL, - /* desc, NAME, name */ zUnprivportText, zUnprivport_NAME, zUnprivport_Name, + /* desc, NAME, name */ zNormalverboseText, zNormalverbose_NAME, zNormalverbose_Name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 3, VALUE_OPT_NORMALVERBOSE, - /* equiv idx, value */ 3, VALUE_OPT_NORMALVERBOSE, + { /* entry idx, value */ 3, VALUE_OPT_KOD, + /* equiv idx, value */ 3, VALUE_OPT_KOD, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ NORMALVERBOSE_FLAGS, 0, + /* opt state flags */ KOD_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, aNormalverboseCantList, + /* must/cannot opts */ NULL, NULL, /* option proc */ NULL, - /* desc, NAME, name */ zNormalverboseText, zNormalverbose_NAME, zNormalverbose_Name, + /* desc, NAME, name */ zKodText, zKod_NAME, zKod_Name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 4, VALUE_OPT_EXTRAVERBOSE, - /* equiv idx, value */ 4, VALUE_OPT_EXTRAVERBOSE, + { /* entry idx, value */ 4, VALUE_OPT_SYSLOG, + /* equiv idx, value */ 4, VALUE_OPT_SYSLOG, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ EXTRAVERBOSE_FLAGS, 0, + /* opt state flags */ SYSLOG_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, aExtraverboseCantList, + /* must/cannot opts */ NULL, aSyslogCantList, /* option proc */ NULL, - /* desc, NAME, name */ zExtraverboseText, zExtraverbose_NAME, zExtraverbose_Name, + /* desc, NAME, name */ zSyslogText, zSyslog_NAME, zSyslog_Name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 5, VALUE_OPT_MEGAVERBOSE, - /* equiv idx, value */ 5, VALUE_OPT_MEGAVERBOSE, + { /* entry idx, value */ 5, VALUE_OPT_FILELOG, + /* equiv idx, value */ 5, VALUE_OPT_FILELOG, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ MEGAVERBOSE_FLAGS, 0, + /* opt state flags */ FILELOG_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, aMegaverboseCantList, + /* must/cannot opts */ NULL, aFilelogCantList, /* option proc */ NULL, - /* desc, NAME, name */ zMegaverboseText, zMegaverbose_NAME, zMegaverbose_Name, + /* desc, NAME, name */ zFilelogText, zFilelog_NAME, zFilelog_Name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 6, VALUE_OPT_SETTIMEOFDAY, - /* equiv idx, value */ 6, VALUE_OPT_SETTIMEOFDAY, + { /* entry idx, value */ 6, VALUE_OPT_SETTOD, + /* equiv idx, value */ 6, VALUE_OPT_SETTOD, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ SETTIMEOFDAY_FLAGS, 0, + /* opt state flags */ SETTOD_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, aSettimeofdayCantList, + /* must/cannot opts */ NULL, aSettodCantList, /* option proc */ NULL, - /* desc, NAME, name */ zSettimeofdayText, zSettimeofday_NAME, zSettimeofday_Name, + /* desc, NAME, name */ zSettodText, zSettod_NAME, zSettod_Name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ 7, VALUE_OPT_ADJTIME, @@ -434,18 +355,59 @@ /* desc, NAME, name */ zAdjtimeText, zAdjtime_NAME, zAdjtime_Name, /* disablement strs */ NULL, NULL }, -#ifdef NO_OPTIONAL_OPT_ARGS -# define VERSION_OPT_FLAGS OPTST_IMM | OPTST_NO_INIT -#else -# define VERSION_OPT_FLAGS OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ - OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT -#endif + { /* entry idx, value */ 8, VALUE_OPT_BROADCAST, + /* equiv idx, value */ 8, VALUE_OPT_BROADCAST, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ BROADCAST_FLAGS, 0, + /* last opt argumnt */ { NULL }, + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ NULL, + /* desc, NAME, name */ zBroadcastText, zBroadcast_NAME, zBroadcast_Name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ 9, VALUE_OPT_TIMEOUT, + /* equiv idx, value */ 9, VALUE_OPT_TIMEOUT, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ TIMEOUT_FLAGS, 0, + /* last opt argumnt */ { zTimeoutDefaultArg }, + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ optionNumericVal, + /* desc, NAME, name */ zTimeoutText, zTimeout_NAME, zTimeout_Name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ 10, VALUE_OPT_AUTHENTICATION, + /* equiv idx, value */ 10, VALUE_OPT_AUTHENTICATION, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ AUTHENTICATION_FLAGS, 0, + /* last opt argumnt */ { NULL }, + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ optionNumericVal, + /* desc, NAME, name */ zAuthenticationText, zAuthentication_NAME, zAuthentication_Name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ 11, VALUE_OPT_KEYFILE, + /* equiv idx, value */ 11, VALUE_OPT_KEYFILE, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ KEYFILE_FLAGS, 0, + /* last opt argumnt */ { NULL }, + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ NULL, + /* desc, NAME, name */ zKeyfileText, zKeyfile_NAME, zKeyfile_Name, + /* disablement strs */ NULL, NULL }, { /* entry idx, value */ INDEX_OPT_VERSION, VALUE_OPT_VERSION, /* equiv idx value */ NO_EQUIVALENT, 0, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ VERSION_OPT_FLAGS, 0, + /* opt state flags */ OPTST_VERSION_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, @@ -453,7 +415,6 @@ /* desc, NAME, name */ zVersionText, NULL, zVersion_Name, /* disablement strs */ NULL, NULL }, -#undef VERSION_OPT_FLAGS { /* entry idx, value */ INDEX_OPT_HELP, VALUE_OPT_HELP, @@ -472,7 +433,7 @@ /* equiv idx value */ NO_EQUIVALENT, 0, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, 0, + /* opt state flags */ OPTST_MORE_HELP_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, @@ -497,7 +458,7 @@ /* equiv idx value */ NO_EQUIVALENT, 0, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, NOLIMIT, 0, - /* opt state flags */ OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) \ + /* opt state flags */ OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | OPTST_DISABLE_IMM, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, @@ -513,8 +474,8 @@ */ tSCC zPROGNAME[] = "SNTP"; tSCC zUsageTitle[] = -"sntp - standard SNTP program - Ver. 4.2.4p8\n\ -USAGE: %s [ - | -- ]...\n"; +"sntp - standard SNTP program - Ver. 4.2.6p2\n\ +USAGE: %s [ - [] | --[{=| }] ]... hostname-or-IP ...\n"; tSCC zRcName[] = ".ntprc"; tSCC* apzHomeList[] = { "$HOME", @@ -525,15 +486,19 @@ #define zExplain NULL tSCC zDetail[] = "\n\ .I sntp\n\ -can be used as a SNTP client to query a NTP or SNTP server and either display\n\ -the time or set the local system's time (given suitable privilege). It can be\n\ -run as an interactive command or in a\n\ +implements the Simple Network Time Protocol, and is used\n\ +to query an NTP or SNTP server and either\n\ +display the time\n\ +or\n\ +set the local system's time (given suitable privilege).\n\n\ +It can be\n\ +run interactively from the command line or as a\n\ .I cron\n\ -job.\n\ -NTP is the Network Time Protocol (RFC 1305) and SNTP is the\n\ -Simple Network Time Protocol (RFC 2030, which supersedes RFC 1769).\n"; +job.\n\n\ +NTP and SNTP are defined by draft-ietf-ntp-ntpv4-proto-13, which\n\ +obsoletes RFC 4330 and RFC 1305.\n"; tSCC zFullVersion[] = SNTP_FULL_VERSION; -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optcode.tpl near line 408 */ +/* extracted from /usr/local/gnu/share/autogen/optcode.tpl near line 495 */ #if defined(ENABLE_NLS) # define OPTPROC_BASE OPTPROC_TRANSLATE @@ -543,6 +508,9 @@ # define translate_option_strings NULL #endif /* ENABLE_NLS */ + +#define sntp_full_usage NULL +#define sntp_short_usage NULL tOptions sntpOptions = { OPTIONS_STRUCT_VERSION, 0, NULL, /* original argc + argv */ @@ -552,8 +520,7 @@ + OPTPROC_LONGOPT + OPTPROC_NO_REQ_OPT + OPTPROC_ENVIRON - + OPTPROC_NO_ARGS - + OPTPROC_HAS_IMMED ), + + OPTPROC_ARGS_REQ ), 0, NULL, /* current option index, current option */ NULL, NULL, zPROGNAME, zRcName, zCopyright, zCopyrightNotice, @@ -566,12 +533,14 @@ /* * Indexes to special options */ - { INDEX_OPT_MORE_HELP, - INDEX_OPT_SAVE_OPTS, - NO_EQUIVALENT /* index of '-#' option */, + { INDEX_OPT_MORE_HELP, /* more-help option index */ + INDEX_OPT_SAVE_OPTS, /* save option index */ + NO_EQUIVALENT, /* '-#' option index */ NO_EQUIVALENT /* index of default opt */ }, - 13 /* full option count */, 8 /* user option count */ + 17 /* full option count */, 12 /* user option count */, + sntp_full_usage, sntp_short_usage, + NULL, NULL }; /* @@ -582,25 +551,25 @@ tOptions* pOptions, tOptDesc* pOptDesc ) { + (void)pOptions; USAGE( EXIT_SUCCESS ); } -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optmain.tpl near line 92 */ +/* extracted from /usr/local/gnu/share/autogen/optmain.tpl near line 109 */ #if defined(TEST_SNTP_OPTS) /* TEST MAIN PROCEDURE: */ +extern void optionPutShell( tOptions* ); + int -main( int argc, char** argv ) +main(int argc, char** argv) { int res = EXIT_SUCCESS; (void)optionProcess( &sntpOptions, argc, argv ); - { - void optionPutShell( tOptions* ); - optionPutShell( &sntpOptions ); - } + optionPutShell( &sntpOptions ); return res; } #endif /* defined TEST_SNTP_OPTS */ -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optcode.tpl near line 514 */ +/* extracted from /usr/local/gnu/share/autogen/optcode.tpl near line 627 */ #if ENABLE_NLS #include @@ -643,44 +612,45 @@ * Guard against re-translation. It won't work. The strings will have * been changed by the first pass through this code. One shot only. */ - if (option_usage_text.field_ct == 0) - return; - /* - * Do the translations. The first pointer follows the field count field. - * The field count field is the size of a pointer. - */ - { - char** ppz = (char**)(void*)&(option_usage_text); - int ix = option_usage_text.field_ct; + if (option_usage_text.field_ct != 0) { + + /* + * Do the translations. The first pointer follows the field count + * field. The field count field is the size of a pointer. + */ + tOptDesc* pOD = sntpOptions.pOptDesc; + char** ppz = (char**)(void*)&(option_usage_text); + int ix = option_usage_text.field_ct; do { ppz++; *ppz = AO_gettext(*ppz); } while (--ix > 0); + + COERSION(pzCopyright); + COERSION(pzCopyNotice); + COERSION(pzFullVersion); + COERSION(pzUsageTitle); + COERSION(pzExplain); + COERSION(pzDetail); + option_usage_text.field_ct = 0; + + for (ix = sntpOptions.optCt; ix > 0; ix--, pOD++) + coerce_it((void*)&(pOD->pzText)); } - option_usage_text.field_ct = 0; - { + if ((sntpOptions.fOptSet & OPTPROC_NXLAT_OPT_CFG) == 0) { tOptDesc* pOD = sntpOptions.pOptDesc; - int ix = sntpOptions.optCt; + int ix; - for (;;) { - pOD->pzText = AO_gettext(pOD->pzText); - pOD->pz_NAME = AO_gettext(pOD->pz_NAME); - pOD->pz_Name = AO_gettext(pOD->pz_Name); - pOD->pz_DisableName = AO_gettext(pOD->pz_DisableName); - pOD->pz_DisablePfx = AO_gettext(pOD->pz_DisablePfx); - if (--ix <= 0) - break; - pOD++; + for (ix = sntpOptions.optCt; ix > 0; ix--, pOD++) { + coerce_it((void*)&(pOD->pz_Name)); + coerce_it((void*)&(pOD->pz_DisableName)); + coerce_it((void*)&(pOD->pz_DisablePfx)); } + /* prevent re-translation */ + sntpOptions.fOptSet |= OPTPROC_NXLAT_OPT_CFG | OPTPROC_NXLAT_OPT; } - COERSION(pzCopyright); - COERSION(pzCopyNotice); - COERSION(pzFullVersion); - COERSION(pzUsageTitle); - COERSION(pzExplain); - COERSION(pzDetail); } #endif /* ENABLE_NLS */ diff -urN src/contrib/ntp/sntp/sntp-opts.def src.ntp/contrib/ntp/sntp/sntp-opts.def --- src/contrib/ntp/sntp/sntp-opts.def 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/sntp-opts.def 2009-12-09 08:36:46.000000000 +0100 @@ -3,19 +3,13 @@ autogen definitions options; #include autogen-version.def - -copyright = { - date = "1970-2006"; - owner = "ntp.org"; - eaddr = "http://bugs.ntp.org, bugs@ntp.org"; - type = note; - text = `cat COPYRIGHT`; -}; - +#include copyright.def prog-name = "sntp"; prog-title = "standard SNTP program"; homerc = $HOME, "."; +argument = 'hostname-or-IP ...'; + long-opts; config-header = "config.h"; @@ -35,7 +29,7 @@ flag = { name = ipv4; value = 4; - equivalence = ipv4; + flags-cant = ipv6; descrip = "Force IPv4 DNS name resolution"; doc = <<- _EndOfDoc_ Force DNS resolution of following host names on the command line @@ -46,7 +40,7 @@ flag = { name = ipv6; value = 6; - equivalence = ipv4; + flags-cant = ipv4; descrip = "Force IPv6 DNS name resolution"; doc = <<- _EndOfDoc_ Force DNS resolution of following host names on the command line @@ -54,20 +48,11 @@ _EndOfDoc_; }; -flag = { - name = unprivport; - value = u; - descrip = "Use an unprivileged port"; - doc = <<- _EndOfDoc_ - Use an unprivilegded UDP port for our queries. - _EndOfDoc_; -}; flag = { name = normalverbose; - value = v; - flags-cant = extraverbose, megaverbose; - descrip = "Slightly verbose"; + value = d; + descrip = "Normal verbose"; doc = <<- _EndOfDoc_ Diagnostic messages for non-fatal errors and a limited amount of tracing should be written to standard error. Fatal ones always @@ -77,35 +62,45 @@ }; flag = { - name = extraverbose; - value = V; - flags-cant = normalverbose, megaverbose; - descrip = "Extra verbose"; + name = kod; + value = K; + arg-type = string; + arg-name = "file-name"; + descrip = "KoD history filename"; doc = <<- _EndOfDoc_ - Produce more and less comprehensible output, mainly for investigating - problems with apparently inconsistent timestamps. This option should - be set when the program fails with a message indicating that is the - trouble. + Modifies the filename to be used to persist the history of KoD + responses received from servers. The default is + /var/db/ntp-kod. _EndOfDoc_; }; + flag = { - name = megaverbose; - value = W; - flags-cant = normalverbose, extraverbose; - descrip = "Mega verbose"; - doc = <<- _EndOfDoc_ - Very verbose debugging output that will interfere with the timing - when writing to the terminal (because of line buffered output from C). - Note that the times produced by this are the corrections needed, and - not the error in the local clock. This option should be set only when - debugging the source. + name = syslog; + value = p; + flags-cant = filelog; + descrip = "Logging with syslog"; + doc = <<- _EndOfDoc_ + When this option is set all logging will be done using syslog. + _EndOfDoc_; +}; + +flag = { + name = filelog; + value = l; + arg-type = string; + arg-name = "file-name"; + flags-cant = syslog; + descrip = "Log to specified logfile"; + doc = <<- _EndOfDoc_ + This option causes the client to write log messages to the specified + logfile. _EndOfDoc_; }; flag = { - name = settimeofday; - value = r; + name = settod; + value = s; flags-cant = adjtime; descrip = "Set (step) the time with settimeofday()"; doc = <<- _EndOfDoc_ @@ -114,22 +109,93 @@ flag = { name = adjtime; - value = a; - flags-cant = settimeofday; + value = j; + flags-cant = settod; descrip = "Set (slew) the time with adjtime()"; doc = <<- _EndOfDoc_ _EndOfDoc_; }; +flag = { + name = broadcast; + value = b; + descrip = "Use broadcasts to the address specified for synchronisation"; + arg-type = string; + arg-name = "broadcast-address"; + doc = <<- _EndOfDoc_ + If specified SNTP will listen to the specified broadcast address + for NTP broadcasts. The default maximum wait time, + 68 seconds, can be modified with -t. + _EndOfDoc_; +}; + +flag = { + name = timeout; + value = t; + descrip = "Specify the number of seconds to wait for broadcasts"; + arg-type = number; + arg-name = "seconds"; + arg-default = 68; + doc = <<- _EndOfDoc_ + When waiting for a broadcast packet SNTP will wait the number + of seconds specified before giving up. Default 68 seconds. + _EndOfDoc_; +}; + +flag = { + name = authentication; + value = a; + descrip = "Enable authentication with the key auth-keynumber"; + arg-type = number; + arg-name = "auth-keynumber"; + doc = <<- _EndOfDoc_ + This option enables authentication using the key specified in this option's argument. + The argument of this option is the keyid, a number specified in the keyfile as this + key's identifier. See the keyfile option (-k) for more details. + _EndOfDoc_; +}; + +flag = { + name = keyfile; + value = k; + descrip = "Specify a keyfile. SNTP will look in this file for the key specified with -a"; + arg-type = string; + arg-name = "file-name"; + doc = <<- _EndOfDoc_ + This option specifies the keyfile. SNTP will search for the key specified with -a keyno in this + file. Key files follow the following format: + + keyid keytype key + + Where keyid is a number identifying this key + keytype is one of the follow: + S Key in 64 Bit hexadecimal number as specified in in the DES specification. + N Key in 64 Bit hexadecimal number as specified in the NTP standard. + A Key in a 1-to-8 character ASCII string. + M Key in a 1-to-8 character ASCII string using the MD5 authentication scheme. + + For more information see ntp.keys(5). + _EndOfDoc_; +}; + + + + detail = <<- _END_DETAIL .I sntp -can be used as a SNTP client to query a NTP or SNTP server and either display -the time or set the local system's time (given suitable privilege). It can be -run as an interactive command or in a +implements the Simple Network Time Protocol, and is used +to query an NTP or SNTP server and either +display the time +or +set the local system's time (given suitable privilege). + +It can be +run interactively from the command line or as a .I cron job. -NTP is the Network Time Protocol (RFC 1305) and SNTP is the -Simple Network Time Protocol (RFC 2030, which supersedes RFC 1769). + +NTP and SNTP are defined by draft-ietf-ntp-ntpv4-proto-13, which +obsoletes RFC 4330 and RFC 1305. _END_DETAIL; prog-man-descrip = <<- _END_PROG_MAN_DESCRIP @@ -139,132 +205,28 @@ run as an interactive command or in a .I cron job. -NTP is the Network Time Protocol (RFC 1305) and SNTP is the -Simple Network Time Protocol (RFC 2030, which supersedes RFC 1769). -.SS Options -.PP -.I sntp -recognizes the following options: -.TP -.B \-v -indicates that diagnostic messages for non-fatal errors and a limited amount of -tracing should be written to standard error. Fatal ones always produce a -diagnostic. This option should be set when there is a suspected problem with -the server, network or the source. -.TP -.B \-V -requests more and less comprehensible output, mainly for investigating problems -with apparently inconsistent timestamps. This option should be set when the -program fails with a message indicating that is the trouble. -.TP -.B \-W -requests very verbose debugging output, and will interfere with the timing -when writing to the terminal (because of line buffered output from C). Note -that the times produced by this are the corrections needed, and not the error -in the local clock. This option should be set only when debugging the source. -.TP -.B \-q -indicates that it should query a daemon save file being maintained by it. -This needs no privilege and will change neither the save file nor the clock. -.PP -The default is that it should behave as a client, and the following options -are then relevant: -.TP -.B \-r -indicates that the system clock should be reset by -.IR settimeofday . -Naturally, this will work only if the user has enough privilege. -.TP -.B \-a -indicates that the system clock should be reset by -.IR adjtime . -Naturally, this will work only if the user has enough privilege. + +NTP (the Network Time Protocol) and SNTP (the Simple Network Time Protocol) +are defined and described by +draft-ietf-ntp-ntpv4-proto-13, +which should become a full RFC any month now. + .PP The default is to write the estimated correct local date and time (i.e. not UTC) to the standard output in a format like -.BR "'1996 Oct 15 20:17:25.123 + 4.567 +/- 0.089 secs'" , +.BR "'1996 Oct 15 20:17:25.123 +4.567 +/- 0.089 secs'" , where the -.B "'+ 4.567 +/- 0.089 secs'" -indicates the estimated error in the time on the local system. -.TP -.BI \-l " lockfile" -sets the name of the lock file to ensure that there is only -one copy of -.I sntp -running at once. The default is installation-dependent, but will usually be -.IR /etc/sntp.pid . -.TP -.BI \-e " minerr" -sets the maximum ignorable variation between the clocks to -.IR minerr . -Acceptable values are from 0.001 to 1, and the default is 0.1 if a NTP host is -is specified and 0.5 otherwise. -.TP -.BI \-E " maxerr" -sets the maximum value of various delays that are deemed acceptable to -.IR maxerr . -Acceptable values are from 1 to 60, and the default is 5. It should sometimes -be increased if there are problems with the network, NTP server or system -clock, but take care. -.TP -.BI \-P " prompt" -sets the maximum clock change that will be made automatically to -.IR maxerr . -Acceptable values are from 1 to 3600 or -.IR no , -and the default is 30. If the program is being run interactively in ordinary -client mode, and the system clock is to be changed, larger corrections will -prompt the user for confirmation. Specifying -.I no -will disable this and the correction will be made regardless. -.TP -.BI \-c " count" -sets the maximum number of NTP packets required to -.IR count . -Acceptable values are from 1 to 25 if a NTP host is specified and from 5 to 25 -otherwise, and the default is 5. If the maximum isn't enough, the system needs -a better consistency algorithm than this program uses. -.TP -.BI \-d " delay" -sets a rough limit on the total running time to -.I delay -seconds. Acceptable values are from 1 to 3600, and the default is 15 if a NTP -host is specified and 300 otherwise. -.TP -.B -4 -force IPv4 DNS resolution. -.TP -.B -6 -force IPv6 DNS resolution. -.PP -.B address(es) -are the DNS names or IP numbers of hosts to use for the challenge and response -protocol; if no names are given, the program waits for broadcasts. Polling a -server is vastly more reliable than listening to broadcasts. Note that a -single component numeric address is not allowed, to avoid ambiguities. If -more than one name is give, they will be used in a round-robin fashion. -.PP -Constraints: -.IP -.B minerr -must be less than -.B maxerr -which must be less than -.B delay -(or, if a NTP host is not specified -.BR delay / count ")," -and -.B count -must be less than half of -.BR delay . -.IP -In update mode, -.B maxerr -must be less than -.BR prompt. -.PP -Note that none of the above values are closely linked to the limits described -in the NTP protocol (RFC 1305). +.B "'+4.567 +/- 0.089 secs'" +indicates the local clock is 4.567 seconds behind the correct time +(so 4.567 seconds must be added to the local clock to get it to be correct), +and the time of +'1996 Oct 15 20:17:25.123' +is believed to be correct to within ++/- 0.089 +seconds. + _END_PROG_MAN_DESCRIP; + +man-doc = <<- _END_MAN_DOC .SH USAGE The simplest use of this program is as an unprivileged command to check the current time and error in the local clock. For example: @@ -280,48 +242,9 @@ commands. For example: .IP .B sntp -a ntpserver.somewhere -.PP -More information on how to use this utility is given in the -.I README -file in the distribution. In particular, this -.I man -page does not describe how to set it up as a server, which needs special care -to avoid propagating misinformation. .SH RETURN VALUE -When used as a client in non-daemon mode, the program returns a zero exit -status for success, and a non-zero one otherwise. When used as a daemon -(either client or server), it does not return except after a serious error. +The program returns a zero exit +status for success, and a non-zero one otherwise. .SH BUGS -The program implements the SNTP protocol, and does not provide all NTP -facilities. In particular, it contains no checks against any form of spoofing. -If this is a serious concern, some network security mechanism (like a firewall -or even just -.IR tcpwrappers ) -should be installed. -.PP -There are some errors, ambiguities and inconsistencies in the RFCs, and this -code may not interwork with all other NTP implementations. Any unreasonable -restrictions should be reported as bugs to whoever is responsible. It may -be difficult to find out who that is. -.PP -The program will stop as soon as it feels that things have got out of control. -In client daemon mode, it will usually fail during an extended period of -network or server inaccessibility or excessively slow performance, or when the -local clock is reset by another process. It will then need restarting -manually. Experienced system administrators can write a shell script, a -.I cron -job or put it in -.IR inittab , -to do this automatically. -.PP -The error cannot be estimated reliably with broadcast packets or for the drift -in daemon mode (even with client-server packets), and the guess made by the -program may be wrong (possibly even very wrong). If this is a problem, then -setting the -.B \-c -option to a larger value may help. Or it may not. -.SH AUTHOR -.I sntp -was developed by N.M. Maclaren of the University of Cambridge Computing -Service. - _END_PROG_MAN_DESCRIP; +Please report bugs to http://bugs.ntp.org . + _END_MAN_DOC; diff -urN src/contrib/ntp/sntp/sntp-opts.h src.ntp/contrib/ntp/sntp/sntp-opts.h --- src/contrib/ntp/sntp/sntp-opts.h 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/sntp-opts.h 2010-07-09 04:25:38.000000000 +0200 @@ -1,11 +1,11 @@ /* * EDIT THIS FILE WITH CAUTION (sntp-opts.h) * - * It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:49 AM EST + * It has been AutoGen-ed July 9, 2010 at 02:25:37 AM by AutoGen 5.10 * From the definitions sntp-opts.def * and the template file options * - * Generated from AutoOpts 29:0:4 templates. + * Generated from AutoOpts 33:0:8 templates. */ /* @@ -19,88 +19,9 @@ * * This source file is copyrighted and licensed under the following terms: * - * sntp copyright 1970-2006 ntp.org - all rights reserved + * sntp copyright (c) 1970-2010 David L. Mills and/or others - all rights reserved * - * General Public Licence for the software known as MSNTP - * ------------------------------------------------------ - * - * (c) Copyright, N.M. Maclaren, 1996, 1997, 2000 - * (c) Copyright, University of Cambridge, 1996, 1997, 2000 - * - * - * - * Free use of MSNTP in source and binary forms is permitted, provided that this - * entire licence is duplicated in all copies, and that any documentation, - * announcements, and other materials related to use acknowledge that the software - * was developed by N.M. Maclaren (hereafter refered to as the Author) at the - * University of Cambridge. Neither the name of the Author nor the University of - * Cambridge may be used to endorse or promote products derived from this material - * without specific prior written permission. - * - * The Author and the University of Cambridge retain the copyright and all other - * legal rights to the software and make it available non-exclusively. All users - * must ensure that the software in all its derivations carries a copyright notice - * in the form: - * (c) Copyright N.M. Maclaren, - * (c) Copyright University of Cambridge. - * - * - * - * NO WARRANTY - * - * Because the MSNTP software is licensed free of charge, the Author and the - * University of Cambridge provide absolutely no warranty, either expressed or - * implied, including, but not limited to, the implied warranties of - * merchantability and fitness for a particular purpose. The entire risk as to - * the quality and performance of the MSNTP software is with you. Should MSNTP - * prove defective, you assume the cost of all necessary servicing or repair. - * - * In no event, unless required by law, will the Author or the University of - * Cambridge, or any other party who may modify and redistribute this software as - * permitted in accordance with the provisions below, be liable for damages for - * any losses whatsoever, including but not limited to lost profits, lost monies, - * lost or corrupted data, or other special, incidental or consequential losses - * that may arise out of the use or inability to use the MSNTP software. - * - * - * - * COPYING POLICY - * - * Permission is hereby granted for copying and distribution of copies of the - * MSNTP source and binary files, and of any part thereof, subject to the - * following licence conditions: - * - * 1. You may distribute MSNTP or components of MSNTP, with or without additions - * developed by you or by others. No charge, other than an "at-cost" distribution - * fee, may be charged for copies, derivations, or distributions of this material - * without the express written consent of the copyright holders. - * - * 2. You may also distribute MSNTP along with any other product for sale, - * provided that the cost of the bundled package is the same regardless of whether - * MSNTP is included or not, and provided that those interested only in MSNTP must - * be notified that it is a product freely available from the University of - * Cambridge. - * - * 3. If you distribute MSNTP software or parts of MSNTP, with or without - * additions developed by you or others, then you must either make available the - * source to all portions of the MSNTP system (exclusive of any additions made by - * you or by others) upon request, or instead you may notify anyone requesting - * source that it is freely available from the University of Cambridge. - * - * 4. You may not omit any of the copyright notices on either the source files, - * the executable files, or the documentation. - * - * 5. You may not omit transmission of this License agreement with whatever - * portions of MSNTP that are distributed. - * - * 6. Any users of this software must be notified that it is without warranty or - * guarantee of any nature, express or implied, nor is there any fitness for use - * represented. - * - * - * October 1996 - * April 1997 - * October 2000 + * see html/copyright.html */ /* * This file contains the programmatic interface to the Automated @@ -109,7 +30,7 @@ * "AutoOpts" chapter. Please refer to that doc for usage help. */ #ifndef AUTOOPTS_SNTP_OPTS_H_GUARD -#define AUTOOPTS_SNTP_OPTS_H_GUARD +#define AUTOOPTS_SNTP_OPTS_H_GUARD 1 #include "config.h" #include @@ -120,7 +41,7 @@ * tolerable version is at least as old as what was current when the header * template was released. */ -#define AO_TEMPLATE_VERSION 118784 +#define AO_TEMPLATE_VERSION 135168 #if (AO_TEMPLATE_VERSION < OPTIONS_MINIMUM_VERSION) \ || (AO_TEMPLATE_VERSION > OPTIONS_STRUCT_VERSION) # error option template version mismatches autoopts/options.h header @@ -131,24 +52,28 @@ * Enumeration of each option: */ typedef enum { - INDEX_OPT_IPV4 = 0, - INDEX_OPT_IPV6 = 1, - INDEX_OPT_UNPRIVPORT = 2, - INDEX_OPT_NORMALVERBOSE = 3, - INDEX_OPT_EXTRAVERBOSE = 4, - INDEX_OPT_MEGAVERBOSE = 5, - INDEX_OPT_SETTIMEOFDAY = 6, - INDEX_OPT_ADJTIME = 7, - INDEX_OPT_VERSION = 8, - INDEX_OPT_HELP = 9, - INDEX_OPT_MORE_HELP = 10, - INDEX_OPT_SAVE_OPTS = 11, - INDEX_OPT_LOAD_OPTS = 12 + INDEX_OPT_IPV4 = 0, + INDEX_OPT_IPV6 = 1, + INDEX_OPT_NORMALVERBOSE = 2, + INDEX_OPT_KOD = 3, + INDEX_OPT_SYSLOG = 4, + INDEX_OPT_FILELOG = 5, + INDEX_OPT_SETTOD = 6, + INDEX_OPT_ADJTIME = 7, + INDEX_OPT_BROADCAST = 8, + INDEX_OPT_TIMEOUT = 9, + INDEX_OPT_AUTHENTICATION = 10, + INDEX_OPT_KEYFILE = 11, + INDEX_OPT_VERSION = 12, + INDEX_OPT_HELP = 13, + INDEX_OPT_MORE_HELP = 14, + INDEX_OPT_SAVE_OPTS = 15, + INDEX_OPT_LOAD_OPTS = 16 } teOptIndex; -#define OPTION_CT 13 -#define SNTP_VERSION "4.2.4p8" -#define SNTP_FULL_VERSION "sntp - standard SNTP program - Ver. 4.2.4p8" +#define OPTION_CT 17 +#define SNTP_VERSION "4.2.6p2" +#define SNTP_FULL_VERSION "sntp - standard SNTP program - Ver. 4.2.6p2" /* * Interface defines for all options. Replace "n" with the UPPER_CASED @@ -183,58 +108,84 @@ # warning undefining IPV6 due to option name conflict # undef IPV6 # endif -# ifdef UNPRIVPORT -# warning undefining UNPRIVPORT due to option name conflict -# undef UNPRIVPORT -# endif # ifdef NORMALVERBOSE # warning undefining NORMALVERBOSE due to option name conflict # undef NORMALVERBOSE # endif -# ifdef EXTRAVERBOSE -# warning undefining EXTRAVERBOSE due to option name conflict -# undef EXTRAVERBOSE -# endif -# ifdef MEGAVERBOSE -# warning undefining MEGAVERBOSE due to option name conflict -# undef MEGAVERBOSE -# endif -# ifdef SETTIMEOFDAY -# warning undefining SETTIMEOFDAY due to option name conflict -# undef SETTIMEOFDAY +# ifdef KOD +# warning undefining KOD due to option name conflict +# undef KOD +# endif +# ifdef SYSLOG +# warning undefining SYSLOG due to option name conflict +# undef SYSLOG +# endif +# ifdef FILELOG +# warning undefining FILELOG due to option name conflict +# undef FILELOG +# endif +# ifdef SETTOD +# warning undefining SETTOD due to option name conflict +# undef SETTOD # endif # ifdef ADJTIME # warning undefining ADJTIME due to option name conflict # undef ADJTIME # endif +# ifdef BROADCAST +# warning undefining BROADCAST due to option name conflict +# undef BROADCAST +# endif +# ifdef TIMEOUT +# warning undefining TIMEOUT due to option name conflict +# undef TIMEOUT +# endif +# ifdef AUTHENTICATION +# warning undefining AUTHENTICATION due to option name conflict +# undef AUTHENTICATION +# endif +# ifdef KEYFILE +# warning undefining KEYFILE due to option name conflict +# undef KEYFILE +# endif #else /* NO_OPTION_NAME_WARNINGS */ # undef IPV4 # undef IPV6 -# undef UNPRIVPORT # undef NORMALVERBOSE -# undef EXTRAVERBOSE -# undef MEGAVERBOSE -# undef SETTIMEOFDAY +# undef KOD +# undef SYSLOG +# undef FILELOG +# undef SETTOD # undef ADJTIME +# undef BROADCAST +# undef TIMEOUT +# undef AUTHENTICATION +# undef KEYFILE #endif /* NO_OPTION_NAME_WARNINGS */ -/* +/* * * * * * + * * Interface defines for specific options. */ #define VALUE_OPT_IPV4 '4' -#define WHICH_OPT_IPV4 (DESC(IPV4).optActualValue) -#define WHICH_IDX_IPV4 (DESC(IPV4).optActualIndex) #define VALUE_OPT_IPV6 '6' -#define VALUE_OPT_UNPRIVPORT 'u' -#define VALUE_OPT_NORMALVERBOSE 'v' -#define VALUE_OPT_EXTRAVERBOSE 'V' -#define VALUE_OPT_MEGAVERBOSE 'W' -#define VALUE_OPT_SETTIMEOFDAY 'r' -#define VALUE_OPT_ADJTIME 'a' +#define VALUE_OPT_NORMALVERBOSE 'd' +#define VALUE_OPT_KOD 'K' +#define VALUE_OPT_SYSLOG 'p' +#define VALUE_OPT_FILELOG 'l' +#define VALUE_OPT_SETTOD 's' +#define VALUE_OPT_ADJTIME 'j' +#define VALUE_OPT_BROADCAST 'b' +#define VALUE_OPT_TIMEOUT 't' -#define VALUE_OPT_VERSION 'v' +#define OPT_VALUE_TIMEOUT (DESC(TIMEOUT).optArg.argInt) +#define VALUE_OPT_AUTHENTICATION 'a' + +#define OPT_VALUE_AUTHENTICATION (DESC(AUTHENTICATION).optArg.argInt) +#define VALUE_OPT_KEYFILE 'k' #define VALUE_OPT_HELP '?' #define VALUE_OPT_MORE_HELP '!' +#define VALUE_OPT_VERSION INDEX_OPT_VERSION #define VALUE_OPT_SAVE_OPTS '>' #define VALUE_OPT_LOAD_OPTS '<' #define SET_OPT_SAVE_OPTS(a) STMTS( \ @@ -251,7 +202,7 @@ sntpOptions.pzCurOpt = NULL ) #define START_OPT RESTART_OPT(1) #define USAGE(c) (*sntpOptions.pUsageProc)( &sntpOptions, c ) -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/opthead.tpl near line 360 */ +/* extracted from /usr/local/gnu/share/autogen/opthead.tpl near line 409 */ /* * * * * * * @@ -263,18 +214,37 @@ extern tOptions sntpOptions; -#ifndef _ -# if ENABLE_NLS -# include - static inline char* aoGetsText( char const* pz ) { - if (pz == NULL) return NULL; - return (char*)gettext( pz ); - } -# define _(s) aoGetsText(s) -# else /* ENABLE_NLS */ -# define _(s) s -# endif /* ENABLE_NLS */ -#endif +#if defined(ENABLE_NLS) +# ifndef _ +# include + static inline char* aoGetsText( char const* pz ) { + if (pz == NULL) return NULL; + return (char*)gettext( pz ); + } +# define _(s) aoGetsText(s) +# endif /* _() */ + +# define OPT_NO_XLAT_CFG_NAMES STMTS(sntpOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT_CFG;) +# define OPT_NO_XLAT_OPT_NAMES STMTS(sntpOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG;) + +# define OPT_XLAT_CFG_NAMES STMTS(sntpOptions.fOptSet &= \ + ~(OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG);) +# define OPT_XLAT_OPT_NAMES STMTS(sntpOptions.fOptSet &= \ + ~OPTPROC_NXLAT_OPT;) + +#else /* ENABLE_NLS */ +# define OPT_NO_XLAT_CFG_NAMES +# define OPT_NO_XLAT_OPT_NAMES + +# define OPT_XLAT_CFG_NAMES +# define OPT_XLAT_OPT_NAMES + +# ifndef _ +# define _(_s) _s +# endif +#endif /* ENABLE_NLS */ #ifdef __cplusplus } diff -urN src/contrib/ntp/sntp/sntp-opts.texi src.ntp/contrib/ntp/sntp/sntp-opts.texi --- src/contrib/ntp/sntp/sntp-opts.texi 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/sntp-opts.texi 2010-07-09 04:25:41.000000000 +0200 @@ -6,20 +6,26 @@ # # EDIT THIS FILE WITH CAUTION (sntp-opts.texi) # -# It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:51 AM EST +# It has been AutoGen-ed July 9, 2010 at 02:25:41 AM by AutoGen 5.10 # From the definitions sntp-opts.def # and the template file aginfo.tpl @end ignore This program has no explanation. .I sntp -can be used as a SNTP client to query a NTP or SNTP server and either display -the time or set the local system's time (given suitable privilege). It can be -run as an interactive command or in a +implements the Simple Network Time Protocol, and is used +to query an NTP or SNTP server and either +display the time +or +set the local system's time (given suitable privilege). + +It can be +run interactively from the command line or as a .I cron job. -NTP is the Network Time Protocol (RFC 1305) and SNTP is the -Simple Network Time Protocol (RFC 2030, which supersedes RFC 1769). + +NTP and SNTP are defined by draft-ietf-ntp-ntpv4-proto-13, which +obsoletes RFC 4330 and RFC 1305. This section was generated by @strong{AutoGen}, the aginfo template and the option descriptions for the @command{sntp} program. It documents the sntp usage text and option meanings. @@ -28,14 +34,18 @@ @menu * sntp usage:: sntp usage help (-?) -* sntp adjtime:: adjtime option (-a) -* sntp extraverbose:: extraverbose option (-V) +* sntp adjtime:: adjtime option (-j) +* sntp authentication:: authentication option (-a) +* sntp broadcast:: broadcast option (-b) +* sntp filelog:: filelog option (-l) * sntp ipv4:: ipv4 option (-4) * sntp ipv6:: ipv6 option (-6) -* sntp megaverbose:: megaverbose option (-W) -* sntp normalverbose:: normalverbose option (-v) -* sntp settimeofday:: settimeofday option (-r) -* sntp unprivport:: unprivport option (-u) +* sntp keyfile:: keyfile option (-k) +* sntp kod:: kod option (-K) +* sntp normalverbose:: normalverbose option (-d) +* sntp settod:: settod option (-s) +* sntp syslog:: syslog option (-p) +* sntp timeout:: timeout option (-t) @end menu @node sntp usage @@ -46,59 +56,7 @@ @exampleindent 0 @example -sntp - standard SNTP program - Ver. 4.2.5p247-RC -USAGE: sntp [ - [] | --[@{=| @}] ]... ... - Flg Arg Option-Name Description - -4 no ipv4 Force IPv4 DNS name resolution - - prohibits these options: - ipv6 - -6 no ipv6 Force IPv6 DNS name resolution - - prohibits these options: - ipv4 - -d no normalverbose Normal verbose - -K Str kod KoD history filename - -p no syslog Logging with syslog - - prohibits these options: - filelog - -l Str filelog Logging to specified logfile - - prohibits these options: - syslog - -s no settod Set (step) the time with settimeofday() - - prohibits these options: - adjtime - -j no adjtime Set (slew) the time with adjtime() - - prohibits these options: - settod - -b Str broadcast Use broadcasts to the address specified for synchronisation - -t Num timeout Specify the number of seconds to wait for broadcasts - -a Num authentication Enable authentication with the key keyno. This option is used as -a keyno - -k Str keyfile Specify a keyfile. SNTP will look in this file for the key specified with -a - opt version Output version information and exit - -? no help Display extended usage information and exit - -! no more-help Extended usage information passed thru pager - -> opt save-opts Save the option state to a config file - -< Str load-opts Load options from a config file - - disabled as --no-load-opts - - may appear multiple times - -Options are specified by doubled hyphens and their name -or by a single hyphen and the flag character. - -The following option preset mechanisms are supported: - - reading file /users/stenn/.ntprc - - reading file /deacon/backroom/snaps/ntp-stable/sntp/.ntprc - - examining environment variables named SNTP_* - -.I sntp -can be used as a SNTP client to query a NTP or SNTP server and either display -the time or set the local system's time (given suitable privilege). It can be -run as an interactive command or in a -.I cron -job. -NTP is the Network Time Protocol (RFC 1305) and SNTP is the -Simple Network Time Protocol (RFC 2030, which supersedes RFC 1769). - -please send bug reports to: http://bugs.ntp.org, bugs@@ntp.org +sntp is unavailable - no --help @end example @exampleindent 4 @@ -111,7 +69,8 @@ This option has some usage constraints. It: @itemize @bullet @item -is a member of the ipv4 class of options. +must not appear in combination with any of the following options: +ipv6. @end itemize Force DNS resolution of following host names on the command line @@ -126,77 +85,66 @@ This option has some usage constraints. It: @itemize @bullet @item -is a member of the ipv4 class of options. +must not appear in combination with any of the following options: +ipv4. @end itemize Force DNS resolution of following host names on the command line to the IPv6 namespace. -@node sntp unprivport -@subsection unprivport option (-u) -@cindex sntp-unprivport - -This is the ``use an unprivileged port'' option. -Use an unprivilegded UDP port for our queries. - @node sntp normalverbose -@subsection normalverbose option (-v) +@subsection normalverbose option (-d) @cindex sntp-normalverbose -This is the ``slightly verbose'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -must not appear in combination with any of the following options: -extraverbose, megaverbose. -@end itemize - +This is the ``normal verbose'' option. Diagnostic messages for non-fatal errors and a limited amount of tracing should be written to standard error. Fatal ones always produce a diagnostic. This option should be set when there is a suspected problem with the server, network or the source. -@node sntp extraverbose -@subsection extraverbose option (-V) -@cindex sntp-extraverbose +@node sntp kod +@subsection kod option (-K) +@cindex sntp-kod + +This is the ``kod history filename'' option. +Modifies the filename to be used to persist the history of KoD +responses received from servers. The default is +/var/db/ntp-kod. + +@node sntp syslog +@subsection syslog option (-p) +@cindex sntp-syslog -This is the ``extra verbose'' option. +This is the ``logging with syslog'' option. This option has some usage constraints. It: @itemize @bullet @item must not appear in combination with any of the following options: -normalverbose, megaverbose. +filelog. @end itemize -Produce more and less comprehensible output, mainly for investigating -problems with apparently inconsistent timestamps. This option should -be set when the program fails with a message indicating that is the -trouble. +When this option is set all logging will be done using syslog. -@node sntp megaverbose -@subsection megaverbose option (-W) -@cindex sntp-megaverbose +@node sntp filelog +@subsection filelog option (-l) +@cindex sntp-filelog -This is the ``mega verbose'' option. +This is the ``log to specified logfile'' option. This option has some usage constraints. It: @itemize @bullet @item must not appear in combination with any of the following options: -normalverbose, extraverbose. +syslog. @end itemize -Very verbose debugging output that will interfere with the timing -when writing to the terminal (because of line buffered output from C). -Note that the times produced by this are the corrections needed, and -not the error in the local clock. This option should be set only when -debugging the source. +This option causes the client to write log messages to the specified +logfile. -@node sntp settimeofday -@subsection settimeofday option (-r) -@cindex sntp-settimeofday +@node sntp settod +@subsection settod option (-s) +@cindex sntp-settod This is the ``set (step) the time with settimeofday()'' option. @@ -210,7 +158,7 @@ @node sntp adjtime -@subsection adjtime option (-a) +@subsection adjtime option (-j) @cindex sntp-adjtime This is the ``set (slew) the time with adjtime()'' option. @@ -219,7 +167,52 @@ @itemize @bullet @item must not appear in combination with any of the following options: -settimeofday. +settod. @end itemize + +@node sntp broadcast +@subsection broadcast option (-b) +@cindex sntp-broadcast + +This is the ``use broadcasts to the address specified for synchronisation'' option. +If specified SNTP will listen to the specified broadcast address +for NTP broadcasts. The default maximum wait time, +68 seconds, can be modified with -t. + +@node sntp timeout +@subsection timeout option (-t) +@cindex sntp-timeout + +This is the ``specify the number of seconds to wait for broadcasts'' option. +When waiting for a broadcast packet SNTP will wait the number +of seconds specified before giving up. Default 68 seconds. + +@node sntp authentication +@subsection authentication option (-a) +@cindex sntp-authentication + +This is the ``enable authentication with the key auth-keynumber'' option. +This option enables authentication using the key specified in this option's argument. +The argument of this option is the keyid, a number specified in the keyfile as this +key's identifier. See the keyfile option (-k) for more details. + +@node sntp keyfile +@subsection keyfile option (-k) +@cindex sntp-keyfile + +This is the ``specify a keyfile. sntp will look in this file for the key specified with -a'' option. +This option specifies the keyfile. SNTP will search for the key specified with -a keyno in this +file. Key files follow the following format: + +keyid keytype key + +Where keyid is a number identifying this key +keytype is one of the follow: +S Key in 64 Bit hexadecimal number as specified in in the DES specification. +N Key in 64 Bit hexadecimal number as specified in the NTP standard. +A Key in a 1-to-8 character ASCII string. +M Key in a 1-to-8 character ASCII string using the MD5 authentication scheme. + +For more information see ntp.keys(5). diff -urN src/contrib/ntp/sntp/sntp.1 src.ntp/contrib/ntp/sntp/sntp.1 --- src/contrib/ntp/sntp/sntp.1 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/sntp.1 2010-07-09 04:25:41.000000000 +0200 @@ -1,7 +1,7 @@ -.TH SNTP 1 2009-12-08 "( 4.2.4p8)" "Programmer's Manual" +.TH SNTP 1 2010-07-09 "( 4.2.6p2)" "Programmer's Manual" .\" EDIT THIS FILE WITH CAUTION (sntp.1) .\" -.\" It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:50 AM EST +.\" It has been AutoGen-ed July 9, 2010 at 02:25:41 AM by AutoGen 5.10 .\" From the definitions sntp-opts.def .\" and the template file agman1.tpl .\" @@ -11,269 +11,142 @@ .B sntp .\" Mixture of short (flag) options and long options .RB [ \-\fIflag\fP " [\fIvalue\fP]]... [" \--\fIopt-name\fP " [[=| ]\fIvalue\fP]]..." -.PP -All arguments must be options. +.br +.in +8 +hostname-or-IP ... .SH "DESCRIPTION" -This manual page documents, briefly, the \fBsntp\fP command. +This manual page briefly documents the \fBsntp\fP command. .I sntp can be used as a SNTP client to query a NTP or SNTP server and either display the time or set the local system's time (given suitable privilege). It can be run as an interactive command or in a .I cron job. -NTP is the Network Time Protocol (RFC 1305) and SNTP is the -Simple Network Time Protocol (RFC 2030, which supersedes RFC 1769). -.SS Options -.PP -.I sntp -recognizes the following options: -.TP -.B \-v -indicates that diagnostic messages for non-fatal errors and a limited amount of -tracing should be written to standard error. Fatal ones always produce a -diagnostic. This option should be set when there is a suspected problem with -the server, network or the source. -.TP -.B \-V -requests more and less comprehensible output, mainly for investigating problems -with apparently inconsistent timestamps. This option should be set when the -program fails with a message indicating that is the trouble. -.TP -.B \-W -requests very verbose debugging output, and will interfere with the timing -when writing to the terminal (because of line buffered output from C). Note -that the times produced by this are the corrections needed, and not the error -in the local clock. This option should be set only when debugging the source. -.TP -.B \-q -indicates that it should query a daemon save file being maintained by it. -This needs no privilege and will change neither the save file nor the clock. -.PP -The default is that it should behave as a client, and the following options -are then relevant: -.TP -.B \-r -indicates that the system clock should be reset by -.IR settimeofday . -Naturally, this will work only if the user has enough privilege. -.TP -.B \-a -indicates that the system clock should be reset by -.IR adjtime . -Naturally, this will work only if the user has enough privilege. + +NTP (the Network Time Protocol) and SNTP (the Simple Network Time Protocol) +are defined and described by +draft-ietf-ntp-ntpv4-proto-13, +which should become a full RFC any month now. + .PP The default is to write the estimated correct local date and time (i.e. not UTC) to the standard output in a format like -.BR "'1996 Oct 15 20:17:25.123 + 4.567 +/- 0.089 secs'" , +.BR "'1996 Oct 15 20:17:25.123 +4.567 +/- 0.089 secs'" , where the -.B "'+ 4.567 +/- 0.089 secs'" -indicates the estimated error in the time on the local system. -.TP -.BI \-l " lockfile" -sets the name of the lock file to ensure that there is only -one copy of -.I sntp -running at once. The default is installation-dependent, but will usually be -.IR /etc/sntp.pid . -.TP -.BI \-e " minerr" -sets the maximum ignorable variation between the clocks to -.IR minerr . -Acceptable values are from 0.001 to 1, and the default is 0.1 if a NTP host is -is specified and 0.5 otherwise. -.TP -.BI \-E " maxerr" -sets the maximum value of various delays that are deemed acceptable to -.IR maxerr . -Acceptable values are from 1 to 60, and the default is 5. It should sometimes -be increased if there are problems with the network, NTP server or system -clock, but take care. -.TP -.BI \-P " prompt" -sets the maximum clock change that will be made automatically to -.IR maxerr . -Acceptable values are from 1 to 3600 or -.IR no , -and the default is 30. If the program is being run interactively in ordinary -client mode, and the system clock is to be changed, larger corrections will -prompt the user for confirmation. Specifying -.I no -will disable this and the correction will be made regardless. -.TP -.BI \-c " count" -sets the maximum number of NTP packets required to -.IR count . -Acceptable values are from 1 to 25 if a NTP host is specified and from 5 to 25 -otherwise, and the default is 5. If the maximum isn't enough, the system needs -a better consistency algorithm than this program uses. -.TP -.BI \-d " delay" -sets a rough limit on the total running time to -.I delay -seconds. Acceptable values are from 1 to 3600, and the default is 15 if a NTP -host is specified and 300 otherwise. -.TP -.B \-4 -force IPv4 DNS resolution. -.TP -.B \-6 -force IPv6 DNS resolution. -.PP -.B address(es) -are the DNS names or IP numbers of hosts to use for the challenge and response -protocol; if no names are given, the program waits for broadcasts. Polling a -server is vastly more reliable than listening to broadcasts. Note that a -single component numeric address is not allowed, to avoid ambiguities. If -more than one name is give, they will be used in a round-robin fashion. -.PP -Constraints: -.IP -.B minerr -must be less than -.B maxerr -which must be less than -.B delay -(or, if a NTP host is not specified -.BR delay / count ")," -and -.B count -must be less than half of -.BR delay . -.IP -In update mode, -.B maxerr -must be less than -.BR prompt. -.PP -Note that none of the above values are closely linked to the limits described -in the NTP protocol (RFC 1305). -.SH USAGE -The simplest use of this program is as an unprivileged command to check the -current time and error in the local clock. For example: -.IP -.B sntp ntpserver.somewhere -.PP -With suitable privilege, it can be run as a command or in a -.I cron -job to reset the local clock from a reliable server, like the -.I ntpdate -and -.I rdate -commands. For example: -.IP -.B sntp \-a ntpserver.somewhere -.PP -More information on how to use this utility is given in the -.I README -file in the distribution. In particular, this -.I man -page does not describe how to set it up as a server, which needs special care -to avoid propagating misinformation. -.SH RETURN VALUE -When used as a client in non-daemon mode, the program returns a zero exit -status for success, and a non-zero one otherwise. When used as a daemon -(either client or server), it does not return except after a serious error. -.SH BUGS -The program implements the SNTP protocol, and does not provide all NTP -facilities. In particular, it contains no checks against any form of spoofing. -If this is a serious concern, some network security mechanism (like a firewall -or even just -.IR tcpwrappers ) -should be installed. -.PP -There are some errors, ambiguities and inconsistencies in the RFCs, and this -code may not interwork with all other NTP implementations. Any unreasonable -restrictions should be reported as bugs to whoever is responsible. It may -be difficult to find out who that is. -.PP -The program will stop as soon as it feels that things have got out of control. -In client daemon mode, it will usually fail during an extended period of -network or server inaccessibility or excessively slow performance, or when the -local clock is reset by another process. It will then need restarting -manually. Experienced system administrators can write a shell script, a -.I cron -job or put it in -.IR inittab , -to do this automatically. -.PP -The error cannot be estimated reliably with broadcast packets or for the drift -in daemon mode (even with client-server packets), and the guess made by the -program may be wrong (possibly even very wrong). If this is a problem, then -setting the -.B \-c -option to a larger value may help. Or it may not. -.SH AUTHOR -.I sntp -was developed by N.M. Maclaren of the University of Cambridge Computing -Service. +.B "'+4.567 +/- 0.089 secs'" +indicates the local clock is 4.567 seconds behind the correct time +(so 4.567 seconds must be added to the local clock to get it to be correct), +and the time of +'1996 Oct 15 20:17:25.123' +is believed to be correct to within ++/- 0.089 +seconds. .SH OPTIONS .TP .BR \-4 ", " \--ipv4 Force IPv4 DNS name resolution. -This option is a member of the ipv4 class of options. +This option must not appear in combination with any of the following options: +ipv6. .sp Force DNS resolution of following host names on the command line to the IPv4 namespace. .TP .BR \-6 ", " \--ipv6 Force IPv6 DNS name resolution. -This option is a member of the ipv4 class of options. +This option must not appear in combination with any of the following options: +ipv4. .sp Force DNS resolution of following host names on the command line to the IPv6 namespace. .TP -.BR \-u ", " \--unprivport -Use an unprivileged port. -.sp -Use an unprivilegded UDP port for our queries. -.TP -.BR \-v ", " \--normalverbose -Slightly verbose. -This option must not appear in combination with any of the following options: -extraverbose, megaverbose. +.BR \-d ", " \--normalverbose +Normal verbose. .sp Diagnostic messages for non-fatal errors and a limited amount of tracing should be written to standard error. Fatal ones always produce a diagnostic. This option should be set when there is a suspected problem with the server, network or the source. .TP -.BR \-V ", " \--extraverbose -Extra verbose. +.BR \-K " \fIfile-name\fP, " \--kod "=" \fIfile-name\fP +KoD history filename. +.sp +Modifies the filename to be used to persist the history of KoD +responses received from servers. The default is +/var/db/ntp-kod. +.TP +.BR \-p ", " \--syslog +Logging with syslog. This option must not appear in combination with any of the following options: -normalverbose, megaverbose. +filelog. .sp -Produce more and less comprehensible output, mainly for investigating -problems with apparently inconsistent timestamps. This option should -be set when the program fails with a message indicating that is the -trouble. +When this option is set all logging will be done using syslog. .TP -.BR \-W ", " \--megaverbose -Mega verbose. +.BR \-l " \fIfile-name\fP, " \--filelog "=" \fIfile-name\fP +Log to specified logfile. This option must not appear in combination with any of the following options: -normalverbose, extraverbose. +syslog. .sp -Very verbose debugging output that will interfere with the timing -when writing to the terminal (because of line buffered output from C). -Note that the times produced by this are the corrections needed, and -not the error in the local clock. This option should be set only when -debugging the source. +This option causes the client to write log messages to the specified +logfile. .TP -.BR \-r ", " \--settimeofday +.BR \-s ", " \--settod Set (step) the time with settimeofday(). This option must not appear in combination with any of the following options: adjtime. .sp .TP -.BR \-a ", " \--adjtime +.BR \-j ", " \--adjtime Set (slew) the time with adjtime(). This option must not appear in combination with any of the following options: -settimeofday. +settod. .sp .TP +.BR \-b " \fIbroadcast-address\fP, " \--broadcast "=" \fIbroadcast-address\fP +Use broadcasts to the address specified for synchronisation. +.sp +If specified SNTP will listen to the specified broadcast address +for NTP broadcasts. The default maximum wait time, +68 seconds, can be modified with \-t. +.TP +.BR \-t " \fIseconds\fP, " \--timeout "=" \fIseconds\fP +Specify the number of seconds to wait for broadcasts. +This option takes an integer number as its argument. +The default \fIseconds\fP for this option is: +.ti +4 + 68 +.sp +When waiting for a broadcast packet SNTP will wait the number +of seconds specified before giving up. Default 68 seconds. +.TP +.BR \-a " \fIauth-keynumber\fP, " \--authentication "=" \fIauth-keynumber\fP +Enable authentication with the key auth-keynumber. +This option takes an integer number as its argument. +.sp +This option enables authentication using the key specified in this option's argument. +The argument of this option is the keyid, a number specified in the keyfile as this +key's identifier. See the keyfile option (-k) for more details. +.TP +.BR \-k " \fIfile-name\fP, " \--keyfile "=" \fIfile-name\fP +Specify a keyfile. SNTP will look in this file for the key specified with \-a. +.sp +This option specifies the keyfile. SNTP will search for the key specified with \-a keyno in this +file. Key files follow the following format: + +keyid keytype key + +Where keyid is a number identifying this key +keytype is one of the follow: +S Key in 64 Bit hexadecimal number as specified in in the DES specification. +N Key in 64 Bit hexadecimal number as specified in the NTP standard. +A Key in a 1-to-8 character ASCII string. +M Key in a 1-to-8 character ASCII string using the MD5 authentication scheme. + +For more information see ntp.keys(5). +.TP .BR \-? , " \--help" -Display usage information and exit. +Display extended usage information and exit. .TP .BR \-! , " \--more-help" Extended usage information passed thru pager. @@ -288,7 +161,7 @@ of earlier RC/INI files. \fI--no-load-opts\fP is handled early, out of order. .TP -.BR \-v " [{\fIv|c|n\fP}]," " \--version" "[=\fI{v|c|n}\fP]" +.BR \- " [{\fIv|c|n\fP}]," " \--version" "[=\fI{v|c|n}\fP]" Output version of program and exit. The default mode is `v', a simple version. The `c' mode will print copyright information and `n' will print the full copyright notice. @@ -299,100 +172,41 @@ .nf \fBSNTP_\fP or \fBSNTP\fP .fi -.aj +.ad The environmental presets take precedence (are processed later than) the configuration files. The \fIhomerc\fP files are "\fI$HOME\fP", and "\fI.\fP". If any of these are directories, then the file \fI.ntprc\fP is searched for within those directories. +.SH USAGE +The simplest use of this program is as an unprivileged command to check the +current time and error in the local clock. For example: +.IP +.B sntp ntpserver.somewhere +.PP +With suitable privilege, it can be run as a command or in a +.I cron +job to reset the local clock from a reliable server, like the +.I ntpdate +and +.I rdate +commands. For example: +.IP +.B sntp \-a ntpserver.somewhere +.SH RETURN VALUE +The program returns a zero exit +status for success, and a non-zero one otherwise. +.SH BUGS +Please report bugs to http://bugs.ntp.org . .SH AUTHOR -ntp.org +David L. Mills and/or others .br Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org .PP .nf .na - General Public Licence for the software known as MSNTP - \------------------------------------------------------ - - (c) Copyright, N.M. Maclaren, 1996, 1997, 2000 - (c) Copyright, University of Cambridge, 1996, 1997, 2000 - - - -Free use of MSNTP in source and binary forms is permitted, provided that this -entire licence is duplicated in all copies, and that any documentation, -announcements, and other materials related to use acknowledge that the software -was developed by N.M. Maclaren (hereafter refered to as the Author) at the -University of Cambridge. Neither the name of the Author nor the University of -Cambridge may be used to endorse or promote products derived from this material -without specific prior written permission. - -The Author and the University of Cambridge retain the copyright and all other -legal rights to the software and make it available non-exclusively. All users -must ensure that the software in all its derivations carries a copyright notice -in the form: - (c) Copyright N.M. Maclaren, - (c) Copyright University of Cambridge. - - - - NO WARRANTY - -Because the MSNTP software is licensed free of charge, the Author and the -University of Cambridge provide absolutely no warranty, either expressed or -implied, including, but not limited to, the implied warranties of -merchantability and fitness for a particular purpose. The entire risk as to -the quality and performance of the MSNTP software is with you. Should MSNTP -prove defective, you assume the cost of all necessary servicing or repair. - -In no event, unless required by law, will the Author or the University of -Cambridge, or any other party who may modify and redistribute this software as -permitted in accordance with the provisions below, be liable for damages for -any losses whatsoever, including but not limited to lost profits, lost monies, -lost or corrupted data, or other special, incidental or consequential losses -that may arise out of the use or inability to use the MSNTP software. - - - - COPYING POLICY - -Permission is hereby granted for copying and distribution of copies of the -MSNTP source and binary files, and of any part thereof, subject to the -following licence conditions: - -1. You may distribute MSNTP or components of MSNTP, with or without additions -developed by you or by others. No charge, other than an "at-cost" distribution -fee, may be charged for copies, derivations, or distributions of this material -without the express written consent of the copyright holders. - -2. You may also distribute MSNTP along with any other product for sale, -provided that the cost of the bundled package is the same regardless of whether -MSNTP is included or not, and provided that those interested only in MSNTP must -be notified that it is a product freely available from the University of -Cambridge. - -3. If you distribute MSNTP software or parts of MSNTP, with or without -additions developed by you or others, then you must either make available the -source to all portions of the MSNTP system (exclusive of any additions made by -you or by others) upon request, or instead you may notify anyone requesting -source that it is freely available from the University of Cambridge. - -4. You may not omit any of the copyright notices on either the source files, -the executable files, or the documentation. - -5. You may not omit transmission of this License agreement with whatever -portions of MSNTP that are distributed. - -6. Any users of this software must be notified that it is without warranty or -guarantee of any nature, express or implied, nor is there any fitness for use -represented. - - -October 1996 -April 1997 -October 2000 +see html/copyright.html .fi .ad .PP diff -urN src/contrib/ntp/sntp/sntp.html src.ntp/contrib/ntp/sntp/sntp.html --- src/contrib/ntp/sntp/sntp.html 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/sntp.html 2010-07-09 04:25:41.000000000 +0200 @@ -0,0 +1,101 @@ + + +Sntp User's Manual + + + + + + + + + +

    Sntp User's Manual

    +
    +


    +Next: , +Previous: (dir), +Up: (dir) +
    +
    + +

    Simple Network Time Protocol User Manual

    + +

    This document describes the use of the NTP Project's sntp program, +that can be used to query a Network Time Protocol (NTP) server and +display the time offset of the system clock relative to the server +clock. Run as root, it can correct the system clock to this offset as +well. It can be run as an interactive command or from a cron job. + +

    This document applies to version 4.2.6p2 of sntp. + +

    The program implements the SNTP protocol as defined by the draft NTPv4 +IETF specification. + +

    + + + +
    +


    +Next: , +Previous: Top, +Up: Top +
    +
    + + +

    Description

    + +

    By default, sntp writes the local data and time (i.e., not UTC) to the +standard output in the format: + +

         1996 Oct 15 20:17:25.123 +4.567 +/- 0.089 secs
    +
    +

    where the +4.567 +/- 0.089 secs indicates the time offset and +error bound of the system clock relative to the server clock. + + +

    +


    +Previous: sntp Description, +Up: Top +
    +
    + + +

    Usage

    + +

    The simplest use of this program is as an unprivileged command to +check the current time, offset, and error in the local clock. +For example: + +

         sntp ntpserver.somewhere
    +
    +

    With suitable privilege, it can be run as a command or in a +crom job to reset the local clock from a reliable server, like +the ntpdate and rdate commands. +For example: + +

         sntp -a ntpserver.somewhere
    +
    + + diff -urN src/contrib/ntp/sntp/sntp.texi src.ntp/contrib/ntp/sntp/sntp.texi --- src/contrib/ntp/sntp/sntp.texi 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/sntp.texi 2010-07-09 04:17:43.000000000 +0200 @@ -0,0 +1,84 @@ +\input texinfo @c -*-texinfo-*- +@c %**start of header +@setfilename sntp.info +@settitle Sntp User's Manual +@include version.texi +@paragraphindent 2 +@c %**end of header + +@ifinfo +This file documents the use of the NTP Project's SNTP, a program for +querying and setting the time. +@end ifinfo + +@direntry +* sntp: (sntp). Simple Network Time Protocol +@end direntry + +@titlepage +@title Simple Network Time Protocol User's Manual +@subtitle sntp, version @value{VERSION}, @value{UPDATED} +@c @author Max @email{foo@ntp.org} +@end titlepage + +@c @page +@c @vskip 0pt plus 1filll + +@node Top, sntp Description, (dir), (dir) +@top Simple Network Time Protocol User Manual + +This document describes the use of the NTP Project's @code{sntp} program, +that can be used to query a Network Time Protocol (NTP) server and +display the time offset of the system clock relative to the server +clock. Run as root, it can correct the system clock to this offset as +well. It can be run as an interactive command or from a cron job. + +This document applies to version @value{VERSION} of @code{sntp}. + +The program implements the SNTP protocol as defined by the draft NTPv4 +IETF specification. + +@shortcontents + +@menu +* sntp Description:: Description +@include sntp-opts.menu +* Usage:: Usage +@end menu + +@node sntp Description, Usage, Top, Top +@comment node-name, next, previous, up +@section Description + +By default, @code{sntp} writes the local data and time (i.e., not UTC) to the +standard output in the format: + +@example +1996 Oct 15 20:17:25.123 +4.567 +/- 0.089 secs +@end example + +where the +4.567 +/- 0.089 secs indicates the time offset and +error bound of the system clock relative to the server clock. + +@c @include sntp-opts.texi + +@node Usage, , sntp Description, Top +@comment node-name, next, previous, up +@section Usage + +The simplest use of this program is as an unprivileged command to +check the current time, offset, and error in the local clock. +For example: + +@example +sntp ntpserver.somewhere +@end example + +With suitable privilege, it can be run as a command or in a +@code{crom} job to reset the local clock from a reliable server, like +the @code{ntpdate} and @code{rdate} commands. +For example: + +@example +sntp -a ntpserver.somewhere +@end example diff -urN src/contrib/ntp/sntp/socket.c src.ntp/contrib/ntp/sntp/socket.c --- src/contrib/ntp/sntp/socket.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/socket.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,385 +0,0 @@ -/* Copyright (C) 1996, 2000 N.M. Maclaren - Copyright (C) 1996, 2000 The University of Cambridge - -This includes all of the code needed to handle Berkeley sockets. It is way -outside current POSIX, unfortunately. It should be easy to convert to a system -that uses another mechanism. It does not currently use socklen_t, because -the only system that the author uses that has it is Linux. */ - - - -#include "config.h" - -#include "header.h" -#include "internet.h" -#include - -#define SOCKET -#include "kludges.h" -#undef SOCKET - - - -/* The code needs to set some variables during the open, for use by later -functions. */ - -static int initial = 1, - descriptors[MAX_SOCKETS]; - -#ifdef HAVE_IPV6 -static struct sockaddr_storage here[MAX_SOCKETS], there[MAX_SOCKETS]; -#else -static struct sockaddr_in here[MAX_SOCKETS], there[MAX_SOCKETS]; -#endif - -void display_in_hex(const void *, int); -#ifdef HAVE_IPV6 -void display_sock_in_hex(struct sockaddr_storage *); -#else -void display_sock_in_hex (struct sockaddr_in *); -#endif - -/* There needs to be some disgusting grobble for handling timeouts, that is -identical to the grobble in internet.c. */ - -static jmp_buf jump_buffer; - -static void jump_handler (int sig) { - longjmp(jump_buffer,1); -} - -static void clear_alarm (void) { - int k; - - k = errno; - alarm(0); - errno = 0; - if (signal(SIGALRM,SIG_DFL) == SIG_ERR) - fatal(1,"unable to reset signal handler",NULL); - errno = k; -} - - - -void display_in_hex (const void *data, int length) { - int i; - - for (i = 0; i < length; ++i) - fprintf(stderr,"%.2x",((const unsigned char *)data)[i]); -} - -#ifdef HAVE_IPV6 - -void display_sock_in_hex (struct sockaddr_storage *sock) { - int family; - struct sockaddr_in *sin; - struct sockaddr_in6 *sin6; - - family = sock->ss_family; - switch(family) { - case AF_INET: - sin = (struct sockaddr_in *)sock; - display_in_hex(&sin->sin_addr, sizeof(struct in_addr)); - fprintf(stderr,"/"); - display_in_hex(&sin->sin_port, 2); - break; - case AF_INET6: - sin6 = (struct sockaddr_in6 *)sock; - display_in_hex(&sin6->sin6_addr, sizeof(struct in6_addr)); - fprintf(stderr,"/"); - display_in_hex(&sin6->sin6_port, 2); - break; - } -} - -#else - -void display_sock_in_hex (struct sockaddr_in *sock) { - int family, len; - struct sockaddr_in *sin; - - family = sock->sin_family; - switch(family) { - case AF_INET: - sin = (struct sockaddr_in *)sock; - display_in_hex(&sin->sin_addr, sizeof(struct in_addr)); - fprintf(stderr,"/"); - display_in_hex(&sin->sin_port, 2); - break; - } -} -#endif - -extern int unprivport; - -#ifdef HAVE_IPV6 - -void open_socket (int which, char *hostname, int timespan) { - -/* Locate the specified NTP server, set up a couple of addresses and open a -socket. */ - - int port, k, sl; - struct sockaddr_storage address, anywhere; - -/* Initialise and find out the server and port number. Note that the port -number is in network format. */ - - if (initial) - for (k = 0; k < MAX_SOCKETS; ++k) - descriptors[k] = -1; - initial = 0; - if (which < 0 || which >= MAX_SOCKETS || descriptors[which] >= 0) - fatal(0,"socket index out of range or already open",NULL); - if (verbose > 2) - fprintf(stderr,"Looking for the socket addresses\n"); - find_address(&address,&anywhere,&port,hostname,timespan); - if (verbose > 2) { - fprintf(stderr,"Internet address: address="); - display_sock_in_hex(&address); - fprintf(stderr," anywhere="); - display_sock_in_hex(&anywhere); - fputc('\n',stderr); - } - -/* Set up our own and the target addresses. Note that the target address will -be reset before use in server mode. */ - - memset(&here[which], 0, sizeof(struct sockaddr_storage)); - here[which] = anywhere; - if (operation != op_listen || unprivport) - ((struct sockaddr_in6 *)&here[which])->sin6_port = 0; - memset(&there[which], 0, sizeof(struct sockaddr_storage)); - there[which] = address; - if (verbose > 2) { - fprintf(stderr,"Initial sockets: here="); - display_sock_in_hex(&here[which]); - fprintf(stderr," there="); - display_sock_in_hex(&there[which]); - fputc('\n',stderr); - } - -/* Allocate a local UDP socket and configure it. */ - - switch(((struct sockaddr_in *)&there[which])->sin_family) { - case AF_INET: - sl = sizeof(struct sockaddr_in); - break; -#ifdef HAVE_IPV6 - case AF_INET6: - sl = sizeof(struct sockaddr_in6); - break; -#endif - default: - sl = 0; - break; - } - errno = 0; - if ((descriptors[which] = socket(here[which].ss_family,SOCK_DGRAM,0)) < 0 - || bind(descriptors[which],(struct sockaddr *)&here[which], sl) < 0) - fatal(1,"unable to allocate socket for NTP",NULL); -} - -#else - -void open_socket (int which, char *hostname, int timespan) { - -/* Locate the specified NTP server, set up a couple of addresses and open a -socket. */ - - int port, k; - struct in_addr address, anywhere; - -/* Initialise and find out the server and port number. Note that the port -number is in network format. */ - - if (initial) for (k = 0; k < MAX_SOCKETS; ++k) descriptors[k] = -1; - initial = 0; - if (which < 0 || which >= MAX_SOCKETS || descriptors[which] >= 0) - fatal(0,"socket index out of range or already open",NULL); - if (verbose > 2) fprintf(stderr,"Looking for the socket addresses\n"); - find_address(&address,&anywhere,&port,hostname,timespan); - if (verbose > 2) { - fprintf(stderr,"Internet address: address="); - display_in_hex(&address,sizeof(struct in_addr)); - fprintf(stderr," anywhere="); - display_in_hex(&anywhere,sizeof(struct in_addr)); - fputc('\n',stderr); - } - -/* Set up our own and the target addresses. */ - - memset(&here[which],0,sizeof(struct sockaddr_in)); - here[which].sin_family = AF_INET; - here[which].sin_port = - (operation == op_listen || !unprivport ? port : 0); - here[which].sin_addr = anywhere; - memset(&there[which],0,sizeof(struct sockaddr_in)); - there[which].sin_family = AF_INET; - there[which].sin_port = port; - there[which].sin_addr = address; - if (verbose > 2) { - fprintf(stderr,"Initial sockets: here="); - display_in_hex(&here[which].sin_addr,sizeof(struct in_addr)); - fputc('/',stderr); - display_in_hex(&here[which].sin_port,sizeof(here[which].sin_port)); - fprintf(stderr," there="); - display_in_hex(&there[which].sin_addr,sizeof(struct in_addr)); - fputc('/',stderr); - display_in_hex(&there[which].sin_port,sizeof(there[which].sin_port)); - fputc('\n',stderr); - } - -/* Allocate a local UDP socket and configure it. */ - - errno = 0; - if ((descriptors[which] = socket(AF_INET,SOCK_DGRAM,0)) < 0 || - bind(descriptors[which],(struct sockaddr *)&here[which], - sizeof(here[which])) < 0) - fatal(1,"unable to allocate socket for NTP",NULL); -} - -#endif - -extern void write_socket (int which, void *packet, int length) { - -/* Any errors in doing this are fatal - including blocking. Yes, this leaves a -server vulnerable to a denial of service attack. */ - - int k, sl; - - switch(((struct sockaddr_in *)&there[which])->sin_family) { - case AF_INET: - sl = sizeof(struct sockaddr_in); - break; -#ifdef HAVE_IPV6 - case AF_INET6: - sl = sizeof(struct sockaddr_in6); - break; -#endif - default: - sl = 0; - break; - } - if (which < 0 || which >= MAX_SOCKETS || descriptors[which] < 0) - fatal(0,"socket index out of range or not open",NULL); - errno = 0; - k = sendto(descriptors[which],packet,(size_t)length,0, - (struct sockaddr *)&there[which],sl); - if (k != length) fatal(1,"unable to send NTP packet",NULL); -} - - - -extern int read_socket (int which, void *packet, int length, int waiting) { - -/* Read a packet and return its length or -1 for failure. Only incorrect -length and timeout are not fatal. */ - -#ifdef HAVE_IPV6 - struct sockaddr_storage scratch, *ptr; -#else - struct sockaddr_in scratch, *ptr; -#endif - int n; - int k; - -/* Under normal circumstances, set up a timeout. */ - - if (which < 0 || which >= MAX_SOCKETS || descriptors[which] < 0) - fatal(0,"socket index out of range or not open",NULL); - if (waiting > 0) { - if (setjmp(jump_buffer)) { - if (verbose > 2) - fprintf(stderr,"Receive timed out\n"); - else if (verbose > 1) - fprintf(stderr,"%s: receive timed out after %d seconds\n", - argv0,waiting); - return -1; - } - errno = 0; - if (signal(SIGALRM,jump_handler) == SIG_ERR) - fatal(1,"unable to set up signal handler",NULL); - alarm((unsigned int)waiting); - } - -/* Get the packet and clear the timeout, if any. */ - - memcpy(ptr = &scratch,&there[which],sizeof(scratch)); - n = sizeof(scratch); - errno = 0; - k = recvfrom(descriptors[which],packet,(size_t)length,0, - (struct sockaddr *)ptr,&n); - if (waiting > 0) clear_alarm(); - -/* Now issue some low-level diagnostics. */ - - if (k <= 0) fatal(1,"unable to receive NTP packet from server",NULL); - if (verbose > 2) { - fprintf(stderr,"Packet of length %d received from ",k); - display_sock_in_hex(ptr); - fputc('\n',stderr); - } - return k; -} - - - -extern int flush_socket (int which) { - -/* Get rid of any outstanding input, because it may have been hanging around -for a while. Ignore packet length oddities and return the number of packets -skipped. */ - -#ifdef HAVE_IPV6 - struct sockaddr_storage scratch; -#else - struct sockaddr_in scratch; -#endif - int n; - char buffer[256]; - int flags, count = 0, total = 0, k; - -/* The code is the obvious. */ - - if (which < 0 || which >= MAX_SOCKETS || descriptors[which] < 0) - fatal(0,"socket index out of range or not open",NULL); - if (verbose > 2) fprintf(stderr,"Flushing outstanding packets\n"); - errno = 0; - if ((flags = fcntl(descriptors[which],F_GETFL,0)) < 0 || - fcntl(descriptors[which],F_SETFL,flags|O_NONBLOCK) == -1) - fatal(1,"unable to set non-blocking mode",NULL); - while (1) { - n = sizeof(scratch); - errno = 0; - k = recvfrom(descriptors[which],buffer,256,0, - (struct sockaddr *)&scratch,&n); - if (k < 0) { - if (errno == EAGAIN || errno == EWOULDBLOCK) break; - fatal(1,"unable to flush socket",NULL); - } - ++count; - total += k; - } - errno = 0; - if (fcntl(descriptors[which],F_SETFL,flags) == -1) - fatal(1,"unable to restore blocking mode",NULL); - if (verbose > 2) - fprintf(stderr,"Flushed %d packets totalling %d bytes\n",count,total); - return count; -} - - - -extern void close_socket (int which) { - -/* There is little point in shielding this with a timeout, because any hangs -are unlikely to be interruptible. It can get called when the sockets haven't -been opened, so ignore that case. */ - - if (which < 0 || which >= MAX_SOCKETS) - fatal(0,"socket index out of range",NULL); - if (descriptors[which] < 0) return; - errno = 0; - if (close(descriptors[which])) fatal(1,"unable to close NTP socket",NULL); -} diff -urN src/contrib/ntp/sntp/timing.c src.ntp/contrib/ntp/sntp/timing.c --- src/contrib/ntp/sntp/timing.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/timing.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,112 +0,0 @@ -/* Copyright (C) 1996 N.M. Maclaren - Copyright (C) 1996 The University of Cambridge - -This includes all of the code needed to handle the time. It assumes rather -more than is defined by POSIX, unfortunately. Systems that do not have the -'X/Open' extensions may need changes. */ - - - -#include "header.h" - -#include -#include - -#define TIMING -#include "kludges.h" -#undef TIMING - - - -#define MILLION_L 1000000l /* For conversion to/from timeval */ -#define MILLION_D 1.0e6 /* Must be equal to MILLION_L */ - - - -double current_time (double offset) { - -/* Get the current UTC time in seconds since the Epoch plus an offset (usually -the time from the beginning of the century to the Epoch!) */ - - struct timeval current; - - errno = 0; - if (gettimeofday(¤t,NULL)) - fatal(1,"unable to read current machine/system time",NULL); - return offset+current.tv_sec+1.0e-6*current.tv_usec; -} - - - -time_t convert_time (double value, int *millisecs) { - -/* Convert the time to the ANSI C form. */ - - time_t result = (time_t)value; - - if ((*millisecs = (int)(1000.0*(value-result))) >= 1000) { - *millisecs = 0; - ++result; - } - return result; -} - - - -void adjust_time (double difference, int immediate, double ignore) { - -/* Adjust the current UTC time. This is portable, even if struct timeval uses -an unsigned long for tv_sec. */ - - struct timeval old, new, adjust, previous; - char text[40]; - long n; - -/* Start by converting to timeval format. Note that we have to cater for -negative, unsigned values. */ - - if ((n = (long)difference) > difference) --n; - adjust.tv_sec = n; - adjust.tv_usec = (long)(MILLION_D*(difference-n)); - errno = 0; - if (gettimeofday(&old,NULL)) - fatal(1,"unable to read machine/system time",NULL); - new.tv_sec = old.tv_sec+adjust.tv_sec; - new.tv_usec = (n = (long)old.tv_usec+(long)adjust.tv_usec); - if (n < 0) { - new.tv_usec += MILLION_L; - --new.tv_sec; - } else if (n >= MILLION_L) { - new.tv_usec -= MILLION_L; - ++new.tv_sec; - } - -/* Now diagnose the situation if necessary, and perform the dirty deed. */ - - if (verbose > 2) - fprintf(stderr, - "Times: old=(%ld,%.6ld) new=(%ld,%.6ld) adjust=(%ld,%.6ld)\n", - (long)old.tv_sec,(long)old.tv_usec, - (long)new.tv_sec,(long)new.tv_usec, - (long)adjust.tv_sec,(long)adjust.tv_usec); - if (immediate) { - errno = 0; - if (settimeofday(&new,NULL)) - fatal(1,"unable to reset current system time",NULL); - } else { - previous.tv_sec = 0; - previous.tv_usec = 0; - errno = 0; - if (adjtime(&adjust,&previous)) - fatal(1,"unable to adjust current system time",NULL); - if (previous.tv_sec != 0 || previous.tv_usec != 0) { - sprintf(text,"(%ld,%.6ld)", - (long)previous.tv_sec,(long)previous.tv_usec); - if (previous.tv_sec+1.0e-6*previous.tv_usec > ignore) - fatal(0,"outstanding time adjustment %s",text); - else if (verbose) - fprintf(stderr,"%s: outstanding time adjustment %s\n", - argv0,text); - } - } -} diff -urN src/contrib/ntp/sntp/unix.c src.ntp/contrib/ntp/sntp/unix.c --- src/contrib/ntp/sntp/unix.c 2004-07-20 17:01:50.000000000 +0200 +++ src.ntp/contrib/ntp/sntp/unix.c 1970-01-01 01:00:00.000000000 +0100 @@ -1,92 +0,0 @@ -/* Copyright (C) 1996 N.M. Maclaren - Copyright (C) 1996 The University of Cambridge - -This includes code that really should have been part of ANSI/ISO C, but was -left out for historical reasons (despite requests to define ftty), plus -the get_lock() and log_message() functions. -*/ - -#include "header.h" - -#include -#include -#include -#include - -#define UNIX -#include "kludges.h" -#undef UNIX - - -void do_nothing (int seconds) { - -/* Wait for a fixed period, possibly uninterruptibly. This should not wait -for less than the specified period, if that can be avoided. */ - - sleep((unsigned int)(seconds+2)); /* +2 is enough for POSIX */ -} - - - -int ftty (FILE *file) { - -/* Return whether the file is attached to an interactive device. */ - - return isatty(fileno(file)); -} - - - -void set_lock (int lock) { - -/* Check that we have enough privileges to reset the time and that no other -updating msntp process is running, but don't bother with fancy interlocking. -This function is really only to permit the daemon mode to be restarted in a -cron job and improve the diagnostics; it can be replaced by a 'return' -statement if it causes implementation difficulties. Note that there is little -point in clearing the lock under Unix, but do so anyway. */ - - FILE *file; - long pid; - - if (lockname == NULL || lockname[0] == '\0') return; - if (lock) { - errno = 0; - if ((file = fopen(lockname,"r")) != NULL && - fscanf(file,"%ld",&pid) == 1 && kill(pid,0) == 0) { - if (verbose || isatty(STDIN_FILENO) || isatty(STDOUT_FILENO)) - fatal(0,"another msntp process is currently running",NULL); - else - fatal(0,NULL,NULL); - } - if (file != NULL) fclose(file); - errno = 0; - if ((file = fopen(lockname,"w")) == NULL || - fprintf(file,"%ld\n",(long)getpid()) <= 0 || - ferror(file) || fclose(file) != 0) - fatal(1,"unable to write PID to %s",lockname); - adjust_time(0.0,1,0.0); - } else { - errno = 0; - if (remove(lockname) != 0) - fatal(1,"unable to remove the msntp lockname %s",lockname); - } -} - - - -/* - * Log a message, crudely. - * This is used in only one place, but could be used more widely. - */ - -void -log_message (const char *message) -{ - - syslog( -#ifdef LOG_DAEMON - LOG_DAEMON | -#endif - LOG_WARNING, "%s", message); -} diff -urN src/contrib/ntp/sntp/utilities.c src.ntp/contrib/ntp/sntp/utilities.c --- src/contrib/ntp/sntp/utilities.c 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/utilities.c 2009-12-09 08:36:46.000000000 +0100 @@ -0,0 +1,176 @@ +#include "utilities.h" + +/* Display a NTP packet in hex with leading address offset + * e.g. offset: value, 0: ff 1: fe ... 255: 00 + */ +void +pkt_output ( + struct pkt *dpkg, + int pkt_length, + FILE *output + ) +{ + register int a; + u_char *pkt; + + pkt = (u_char *)dpkg; + + fprintf(output, HLINE); + + for (a = 0; a < pkt_length; a++) { + if (a > 0 && a % 8 == 0) + fprintf(output, "\n"); + + fprintf(output, "%d: %x \t", a, pkt[a]); + } + + fprintf(output, "\n"); + fprintf(output, HLINE); +} + +/* Output a long floating point value in hex in the style described above + */ +void +l_fp_output ( + l_fp *ts, + FILE *output + ) +{ + register int a; + + fprintf(output, HLINE); + + for(a=0; a<8; a++) + fprintf(output, "%i: %x \t", a, ((unsigned char *) ts)[a]); + + fprintf(output, "\n"); + fprintf(output, HLINE); + +} + +/* Output a long floating point value in binary in the style described above + */ +void +l_fp_output_bin ( + l_fp *ts, + FILE *output + ) +{ + register int a, b; + + fprintf(output, HLINE); + + for(a=0; a<8; a++) { + short tmp = ((unsigned char *) ts)[a]; + tmp++; + + fprintf(output, "%i: ", a); + + for(b=7; b>=0; b--) { + int texp = (int) pow(2, b); + + if(tmp - texp > 0) { + fprintf(output, "1"); + tmp -= texp; + } + else { + fprintf(output, "0"); + } + } + + fprintf(output, " "); + } + + fprintf(output, "\n"); + fprintf(output, HLINE); +} + +/* Output a long floating point value in decimal in the style described above + */ +void +l_fp_output_dec ( + l_fp *ts, + FILE *output + ) +{ + register int a; + + fprintf(output, HLINE); + + for(a=0; a<8; a++) + fprintf(output, "%i: %i \t", a, ((unsigned char *) ts)[a]); + + fprintf(output, "\n"); + fprintf(output, HLINE); + +} + +/* Convert a struct addrinfo to a string containing the address in style + * of inet_ntoa + */ +char * +addrinfo_to_str ( + struct addrinfo *addr + ) +{ + char *buf = (char *) emalloc(sizeof(char) * INET6_ADDRSTRLEN); + + getnameinfo(addr->ai_addr, addr->ai_addrlen, buf, + INET6_ADDRSTRLEN, NULL, 0, NI_NUMERICHOST); + + return buf; +} + +/* Convert a sockaddr_u to a string containing the address in + * style of inet_ntoa + * Why not switch callers to use stoa from libntp? No free() needed + * in that case. + */ +char * +ss_to_str ( + sockaddr_u *saddr + ) +{ + char *buf = (char *) emalloc(sizeof(char) * INET6_ADDRSTRLEN); + + getnameinfo(&saddr->sa, SOCKLEN(saddr), buf, + INET6_ADDRSTRLEN, NULL, 0, NI_NUMERICHOST); + + + return buf; +} + +/* Converts a struct tv to a date string + */ +char * +tv_to_str ( + struct timeval *tv + ) +{ + static const char *month_names[] = { + "Jan", "Feb", "Mar", "Apr", "May", "Jun", + "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" + }; + + char *buf = (char *) emalloc(sizeof(char) * 48); + time_t cur_time = time(NULL); + struct tm *tm_ptr; + + tm_ptr = localtime(&cur_time); + + + snprintf(buf, 48, "%i %s %.2d %.2d:%.2d:%.2d.%.3d", + tm_ptr->tm_year + 1900, + month_names[tm_ptr->tm_mon], + tm_ptr->tm_mday, + tm_ptr->tm_hour, + tm_ptr->tm_min, + tm_ptr->tm_sec, + (int)tv->tv_usec); + + return buf; +} + + + + diff -urN src/contrib/ntp/sntp/utilities.h src.ntp/contrib/ntp/sntp/utilities.h --- src/contrib/ntp/sntp/utilities.h 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/utilities.h 2009-12-09 08:36:46.000000000 +0100 @@ -0,0 +1,25 @@ +#ifndef UTILITIES_H +#define UTILITIES_H + +#include +#include +#include +#include +#include +#include + +#define HLINE "--------------------------------------------------------------------------------\n" +#define PHLINE fprintf(output, HLINE); +#define STDLINE printf(HLINE); + + +void pkt_output (struct pkt *dpkg, int pkt_length, FILE *output); +void l_fp_output (l_fp *ts, FILE *output); +void l_fp_output_bin (l_fp *ts, FILE *output); +void l_fp_output_dec (l_fp *ts, FILE *output); + +char *addrinfo_to_str (struct addrinfo *addr); +char *ss_to_str (sockaddr_u *saddr); +char *tv_to_str (struct timeval *tv); + +#endif diff -urN src/contrib/ntp/sntp/version.def src.ntp/contrib/ntp/sntp/version.def --- src/contrib/ntp/sntp/version.def 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/version.def 2010-07-09 04:25:37.000000000 +0200 @@ -1 +1 @@ -version = '4.2.4p8'; +version = '4.2.6p2'; diff -urN src/contrib/ntp/sntp/version.m4 src.ntp/contrib/ntp/sntp/version.m4 --- src/contrib/ntp/sntp/version.m4 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/version.m4 2010-07-09 04:25:37.000000000 +0200 @@ -0,0 +1 @@ +m4_define([VERSION_NUMBER],[4.2.6p2]) diff -urN src/contrib/ntp/sntp/version.texi src.ntp/contrib/ntp/sntp/version.texi --- src/contrib/ntp/sntp/version.texi 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/sntp/version.texi 2010-07-09 04:25:37.000000000 +0200 @@ -0,0 +1,3 @@ +@set UPDATED 09 July 2010 +@set EDITION 4.2.6p2 +@set VERSION 4.2.6p2 diff -urN src/contrib/ntp/util/Makefile.am src.ntp/contrib/ntp/util/Makefile.am --- src/contrib/ntp/util/Makefile.am 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/util/Makefile.am 2010-02-04 08:26:53.000000000 +0100 @@ -1,24 +1,36 @@ +NULL= #AUTOMAKE_OPTIONS = ../ansi2knr no-dependencies -AUTOMAKE_OPTIONS= ansi2knr +AUTOMAKE_OPTIONS= +if NTP_BINSUBDIR_IS_BIN bin_PROGRAMS= @MAKE_NTPTIME@ @MAKE_TICKADJ@ @MAKE_TIMETRIM@ \ ntp-keygen +else +sbin_PROGRAMS= @MAKE_NTPTIME@ @MAKE_TICKADJ@ @MAKE_TIMETRIM@ \ + ntp-keygen +endif + EXTRA_PROGRAMS= audio-pcm byteorder hist jitter kern longsize \ ntptime pps-api precision sht testrs6000 tg tickadj timetrim -AM_CPPFLAGS= -I$(top_srcdir)/include $(LIBOPTS_CFLAGS) +AM_CPPFLAGS= -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/nothreads/include \ + -I$(top_srcdir)/lib/isc/unix/include $(LIBOPTS_CFLAGS) + # LDADD might need RESLIB and ADJLIB LDADD= ../libntp/libntp.a ntp_keygen_SOURCES = ntp-keygen.c ntp-keygen-opts.c ntp-keygen-opts.h -ntp_keygen_LDADD= @LCRYPTO@ $(LIBOPTS_LDADD) ../libntp/libntp.a +ntp_keygen_LDADD= $(LIBOPTS_LDADD) ../libntp/libntp.a @LCRYPTO@ ETAGS_ARGS= Makefile.am #EXTRA_DIST= README TAGS EXTRA_DIST= ntp-keygen-opts.def ntp-keygen.1 ntp-keygen-opts.texi ntp-keygen-opts.menu -BUILT_SOURCES= ntp-keygen-opts.c ntp-keygen-opts.h ntp-keygen.1 \ - ntp-keygen-opts.texi ntp-keygen-opts.menu -man_MANS= ntp-keygen.1 -run_ag= cd $(srcdir) && autogen -L ../include --writable +BUILT_SOURCES= ntp-keygen-opts.c ntp-keygen-opts.h +CLEANFILES= +noinst_DATA= $(srcdir)/ntp-keygen-opts.texi $(srcdir)/ntp-keygen-opts.menu +man_MANS= $(srcdir)/ntp-keygen.1 +run_ag= cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" \ + autogen -L ../include --writable std_def_list= $(top_srcdir)/include/debug-opt.def \ $(top_srcdir)/include/autogen-version.def \ $(top_srcdir)/include/copyright.def \ @@ -26,13 +38,18 @@ $(top_srcdir)/include/version.def $(srcdir)/ntp-keygen-opts.h: $(srcdir)/ntp-keygen-opts.c + @: do-nothing action to avoid default SCCS get, .h built with .c + $(srcdir)/ntp-keygen-opts.c: $(srcdir)/ntp-keygen-opts.def $(std_def_list) $(run_ag) ntp-keygen-opts.def $(srcdir)/ntp-keygen.1: $(srcdir)/ntp-keygen-opts.def $(std_def_list) $(run_ag) -Tagman1.tpl -bntp-keygen ntp-keygen-opts.def -$(srcdir)/ntp-keygen-opts.texi $(srcdir)/ntp-keygen-opts.menu: $(srcdir)/ntp-keygen-opts.def $(std_def_list) +$(srcdir)/ntp-keygen-opts.menu: $(srcdir)/ntp-keygen-opts.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/ntp-keygen-opts.texi: $(srcdir)/ntp-keygen-opts.def $(std_def_list) $(run_ag) -Taginfo.tpl -DLEVEL=section ntp-keygen-opts.def @@ -44,3 +61,6 @@ kern.o: kern.c $(COMPILE) -DHAVE_TIMEX_H -c kern.c + +include $(top_srcdir)/bincheck.mf +include $(top_srcdir)/depsver.mf diff -urN src/contrib/ntp/util/Makefile.in src.ntp/contrib/ntp/util/Makefile.in --- src/contrib/ntp/util/Makefile.in 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/util/Makefile.in 2010-07-09 04:21:36.000000000 +0200 @@ -15,6 +15,11 @@ @SET_MAKE@ +# we traditionally installed software in bindir, while it should have gone +# in sbindir. Now that we offer a choice, look in the "other" installation +# subdir to warn folks if there is another version there. + + VPATH = @srcdir@ pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ @@ -34,21 +39,29 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -ANSI2KNR = @ANSI2KNR@ -bin_PROGRAMS = @MAKE_NTPTIME@ @MAKE_TICKADJ@ @MAKE_TIMETRIM@ \ - ntp-keygen$(EXEEXT) +@NTP_BINSUBDIR_IS_BIN_TRUE@bin_PROGRAMS = @MAKE_NTPTIME@ \ +@NTP_BINSUBDIR_IS_BIN_TRUE@ @MAKE_TICKADJ@ @MAKE_TIMETRIM@ \ +@NTP_BINSUBDIR_IS_BIN_TRUE@ ntp-keygen$(EXEEXT) +@NTP_BINSUBDIR_IS_BIN_FALSE@sbin_PROGRAMS = @MAKE_NTPTIME@ \ +@NTP_BINSUBDIR_IS_BIN_FALSE@ @MAKE_TICKADJ@ @MAKE_TIMETRIM@ \ +@NTP_BINSUBDIR_IS_BIN_FALSE@ ntp-keygen$(EXEEXT) EXTRA_PROGRAMS = audio-pcm$(EXEEXT) byteorder$(EXEEXT) hist$(EXEEXT) \ jitter$(EXEEXT) kern$(EXEEXT) longsize$(EXEEXT) \ ntptime$(EXEEXT) pps-api$(EXEEXT) precision$(EXEEXT) \ sht$(EXEEXT) testrs6000$(EXEEXT) tg$(EXEEXT) tickadj$(EXEEXT) \ timetrim$(EXEEXT) -subdir = util DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ - ansi2knr.1 ansi2knr.c + $(top_srcdir)/bincheck.mf $(top_srcdir)/depsver.mf ansi2knr.1 \ + ansi2knr.c +subdir = util ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ + $(top_srcdir)/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/m4/ntp_openssl.m4 \ + $(top_srcdir)/m4/ntp_vpathhack.m4 \ $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ @@ -57,66 +70,66 @@ CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = -am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)" -PROGRAMS = $(bin_PROGRAMS) +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(sbindir)" \ + "$(DESTDIR)$(man1dir)" +PROGRAMS = $(bin_PROGRAMS) $(sbin_PROGRAMS) audio_pcm_SOURCES = audio-pcm.c -audio_pcm_OBJECTS = audio-pcm$U.$(OBJEXT) +audio_pcm_OBJECTS = audio-pcm.$(OBJEXT) audio_pcm_LDADD = $(LDADD) audio_pcm_DEPENDENCIES = ../libntp/libntp.a byteorder_SOURCES = byteorder.c -byteorder_OBJECTS = byteorder$U.$(OBJEXT) +byteorder_OBJECTS = byteorder.$(OBJEXT) byteorder_LDADD = $(LDADD) byteorder_DEPENDENCIES = ../libntp/libntp.a hist_SOURCES = hist.c -hist_OBJECTS = hist$U.$(OBJEXT) +hist_OBJECTS = hist.$(OBJEXT) hist_LDADD = $(LDADD) hist_DEPENDENCIES = ../libntp/libntp.a -am_jitter_OBJECTS = jitter$U.$(OBJEXT) +am_jitter_OBJECTS = jitter.$(OBJEXT) jitter_OBJECTS = $(am_jitter_OBJECTS) jitter_DEPENDENCIES = kern_SOURCES = kern.c -kern_OBJECTS = kern$U.$(OBJEXT) +kern_OBJECTS = kern.$(OBJEXT) kern_LDADD = $(LDADD) kern_DEPENDENCIES = ../libntp/libntp.a longsize_SOURCES = longsize.c -longsize_OBJECTS = longsize$U.$(OBJEXT) +longsize_OBJECTS = longsize.$(OBJEXT) longsize_LDADD = $(LDADD) longsize_DEPENDENCIES = ../libntp/libntp.a -am_ntp_keygen_OBJECTS = ntp-keygen$U.$(OBJEXT) \ - ntp-keygen-opts$U.$(OBJEXT) +am_ntp_keygen_OBJECTS = ntp-keygen.$(OBJEXT) ntp-keygen-opts.$(OBJEXT) ntp_keygen_OBJECTS = $(am_ntp_keygen_OBJECTS) am__DEPENDENCIES_1 = ntp_keygen_DEPENDENCIES = $(am__DEPENDENCIES_1) ../libntp/libntp.a ntptime_SOURCES = ntptime.c -ntptime_OBJECTS = ntptime$U.$(OBJEXT) +ntptime_OBJECTS = ntptime.$(OBJEXT) ntptime_LDADD = $(LDADD) ntptime_DEPENDENCIES = ../libntp/libntp.a pps_api_SOURCES = pps-api.c -pps_api_OBJECTS = pps-api$U.$(OBJEXT) +pps_api_OBJECTS = pps-api.$(OBJEXT) pps_api_LDADD = $(LDADD) pps_api_DEPENDENCIES = ../libntp/libntp.a precision_SOURCES = precision.c -precision_OBJECTS = precision$U.$(OBJEXT) +precision_OBJECTS = precision.$(OBJEXT) precision_LDADD = $(LDADD) precision_DEPENDENCIES = ../libntp/libntp.a sht_SOURCES = sht.c -sht_OBJECTS = sht$U.$(OBJEXT) +sht_OBJECTS = sht.$(OBJEXT) sht_LDADD = $(LDADD) sht_DEPENDENCIES = ../libntp/libntp.a testrs6000_SOURCES = testrs6000.c -testrs6000_OBJECTS = testrs6000$U.$(OBJEXT) +testrs6000_OBJECTS = testrs6000.$(OBJEXT) testrs6000_LDADD = $(LDADD) testrs6000_DEPENDENCIES = ../libntp/libntp.a tg_SOURCES = tg.c -tg_OBJECTS = tg$U.$(OBJEXT) +tg_OBJECTS = tg.$(OBJEXT) tg_LDADD = $(LDADD) tg_DEPENDENCIES = ../libntp/libntp.a tickadj_SOURCES = tickadj.c -tickadj_OBJECTS = tickadj$U.$(OBJEXT) +tickadj_OBJECTS = tickadj.$(OBJEXT) tickadj_LDADD = $(LDADD) tickadj_DEPENDENCIES = ../libntp/libntp.a timetrim_SOURCES = timetrim.c -timetrim_OBJECTS = timetrim$U.$(OBJEXT) +timetrim_OBJECTS = timetrim.$(OBJEXT) timetrim_LDADD = $(LDADD) timetrim_DEPENDENCIES = ../libntp/libntp.a DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) @@ -162,13 +175,13 @@ man1dir = $(mandir)/man1 NROFF = nroff MANS = $(man_MANS) +DATA = $(noinst_DATA) ETAGS = etags CTAGS = ctags DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -189,6 +202,7 @@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EF_LIBS = @EF_LIBS@ EF_PROGS = @EF_PROGS@ EGREP = @EGREP@ @@ -220,6 +234,7 @@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ @@ -236,18 +251,22 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ PATH_SEPARATOR = @PATH_SEPARATOR@ PATH_SH = @PATH_SH@ PROPDELAY = @PROPDELAY@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ VERSION = @VERSION@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ @@ -299,22 +318,28 @@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ - +NULL = #AUTOMAKE_OPTIONS = ../ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ansi2knr -AM_CPPFLAGS = -I$(top_srcdir)/include $(LIBOPTS_CFLAGS) +AUTOMAKE_OPTIONS = +AM_CPPFLAGS = -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/nothreads/include \ + -I$(top_srcdir)/lib/isc/unix/include $(LIBOPTS_CFLAGS) + + # LDADD might need RESLIB and ADJLIB LDADD = ../libntp/libntp.a ntp_keygen_SOURCES = ntp-keygen.c ntp-keygen-opts.c ntp-keygen-opts.h -ntp_keygen_LDADD = @LCRYPTO@ $(LIBOPTS_LDADD) ../libntp/libntp.a +ntp_keygen_LDADD = $(LIBOPTS_LDADD) ../libntp/libntp.a @LCRYPTO@ ETAGS_ARGS = Makefile.am #EXTRA_DIST= README TAGS EXTRA_DIST = ntp-keygen-opts.def ntp-keygen.1 ntp-keygen-opts.texi ntp-keygen-opts.menu -BUILT_SOURCES = ntp-keygen-opts.c ntp-keygen-opts.h ntp-keygen.1 \ - ntp-keygen-opts.texi ntp-keygen-opts.menu +BUILT_SOURCES = ntp-keygen-opts.c ntp-keygen-opts.h .deps-ver +CLEANFILES = .deps-ver +noinst_DATA = $(srcdir)/ntp-keygen-opts.texi $(srcdir)/ntp-keygen-opts.menu +man_MANS = $(srcdir)/ntp-keygen.1 +run_ag = cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" \ + autogen -L ../include --writable -man_MANS = ntp-keygen.1 -run_ag = cd $(srcdir) && autogen -L ../include --writable std_def_list = $(top_srcdir)/include/debug-opt.def \ $(top_srcdir)/include/autogen-version.def \ $(top_srcdir)/include/copyright.def \ @@ -328,7 +353,7 @@ .SUFFIXES: .SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/bincheck.mf $(top_srcdir)/depsver.mf $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -401,6 +426,49 @@ list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ echo " rm -f" $$list; \ rm -f $$list +install-sbinPROGRAMS: $(sbin_PROGRAMS) + @$(NORMAL_INSTALL) + test -z "$(sbindir)" || $(MKDIR_P) "$(DESTDIR)$(sbindir)" + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p || test -f $$p1; \ + then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-sbinPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(sbindir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(sbindir)" && rm -f $$files + +clean-sbinPROGRAMS: + @list='$(sbin_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list audio-pcm$(EXEEXT): $(audio_pcm_OBJECTS) $(audio_pcm_DEPENDENCIES) @rm -f audio-pcm$(EXEEXT) $(LINK) $(audio_pcm_OBJECTS) $(audio_pcm_LDADD) $(LIBS) @@ -452,32 +520,23 @@ distclean-compile: -rm -f *.tab.c -./ansi2knr: ansi2knr.$(OBJEXT) - $(LINK) ansi2knr.$(OBJEXT) $(LIBS) -ansi2knr.$(OBJEXT): $(CONFIG_HEADER) - -clean-krextra: - -rm -f ansi2knr - -mostlyclean-kr: - -test "$U" = "" || rm -f *_.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/audio-pcm$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/byteorder$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/hist$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jitter$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kern$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/longsize$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp-keygen$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp-keygen-opts$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntptime$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pps-api$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/precision$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sht$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/testrs6000$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tg$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tickadj$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/timetrim$U.Po@am__quote@ + +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/audio-pcm.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/byteorder.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/hist.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jitter.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kern.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/longsize.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp-keygen-opts.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp-keygen.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntptime.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pps-api.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/precision.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sht.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/testrs6000.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tg.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tickadj.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/timetrim.Po@am__quote@ .c.o: @am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @@ -499,47 +558,6 @@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< -audio-pcm_.c: audio-pcm.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/audio-pcm.c; then echo $(srcdir)/audio-pcm.c; else echo audio-pcm.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -byteorder_.c: byteorder.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/byteorder.c; then echo $(srcdir)/byteorder.c; else echo byteorder.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -hist_.c: hist.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/hist.c; then echo $(srcdir)/hist.c; else echo hist.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -jitter_.c: jitter.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/jitter.c; then echo $(srcdir)/jitter.c; else echo jitter.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -kern_.c: kern.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/kern.c; then echo $(srcdir)/kern.c; else echo kern.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -longsize_.c: longsize.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/longsize.c; then echo $(srcdir)/longsize.c; else echo longsize.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp-keygen_.c: ntp-keygen.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp-keygen.c; then echo $(srcdir)/ntp-keygen.c; else echo ntp-keygen.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp-keygen-opts_.c: ntp-keygen-opts.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp-keygen-opts.c; then echo $(srcdir)/ntp-keygen-opts.c; else echo ntp-keygen-opts.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntptime_.c: ntptime.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntptime.c; then echo $(srcdir)/ntptime.c; else echo ntptime.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -pps-api_.c: pps-api.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/pps-api.c; then echo $(srcdir)/pps-api.c; else echo pps-api.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -precision_.c: precision.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/precision.c; then echo $(srcdir)/precision.c; else echo precision.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -sht_.c: sht.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/sht.c; then echo $(srcdir)/sht.c; else echo sht.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -testrs6000_.c: testrs6000.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/testrs6000.c; then echo $(srcdir)/testrs6000.c; else echo testrs6000.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -tg_.c: tg.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/tg.c; then echo $(srcdir)/tg.c; else echo tg.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -tickadj_.c: tickadj.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/tickadj.c; then echo $(srcdir)/tickadj.c; else echo tickadj.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -timetrim_.c: timetrim.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/timetrim.c; then echo $(srcdir)/timetrim.c; else echo timetrim.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -audio-pcm_.$(OBJEXT) audio-pcm_.lo byteorder_.$(OBJEXT) byteorder_.lo \ -hist_.$(OBJEXT) hist_.lo jitter_.$(OBJEXT) jitter_.lo kern_.$(OBJEXT) \ -kern_.lo longsize_.$(OBJEXT) longsize_.lo ntp-keygen_.$(OBJEXT) \ -ntp-keygen_.lo ntp-keygen-opts_.$(OBJEXT) ntp-keygen-opts_.lo \ -ntptime_.$(OBJEXT) ntptime_.lo pps-api_.$(OBJEXT) pps-api_.lo \ -precision_.$(OBJEXT) precision_.lo sht_.$(OBJEXT) sht_.lo \ -testrs6000_.$(OBJEXT) testrs6000_.lo tg_.$(OBJEXT) tg_.lo \ -tickadj_.$(OBJEXT) tickadj_.lo timetrim_.$(OBJEXT) timetrim_.lo : \ -$(ANSI2KNR) mostlyclean-libtool: -rm -f *.lo @@ -683,9 +701,9 @@ check-am: all-am check: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) check-am -all-am: Makefile $(ANSI2KNR) $(PROGRAMS) $(MANS) +all-am: Makefile $(PROGRAMS) $(MANS) $(DATA) installdirs: - for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)"; do \ + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: $(BUILT_SOURCES) @@ -706,6 +724,7 @@ mostlyclean-generic: clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) @@ -717,8 +736,8 @@ -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-am -clean-am: clean-binPROGRAMS clean-generic clean-krextra clean-libtool \ - mostlyclean-am +clean-am: clean-binPROGRAMS clean-generic clean-libtool \ + clean-sbinPROGRAMS mostlyclean-am distclean: distclean-am -rm -rf ./$(DEPDIR) @@ -744,8 +763,9 @@ install-dvi-am: -install-exec-am: install-binPROGRAMS - +install-exec-am: install-binPROGRAMS install-sbinPROGRAMS + @$(NORMAL_INSTALL) + $(MAKE) $(AM_MAKEFLAGS) install-exec-hook install-html: install-html-am install-html-am: @@ -773,7 +793,7 @@ mostlyclean: mostlyclean-am -mostlyclean-am: mostlyclean-compile mostlyclean-generic mostlyclean-kr \ +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am @@ -784,36 +804,43 @@ ps-am: -uninstall-am: uninstall-binPROGRAMS uninstall-man +uninstall-am: uninstall-binPROGRAMS uninstall-man \ + uninstall-sbinPROGRAMS uninstall-man: uninstall-man1 -.MAKE: all check install install-am install-strip +.MAKE: all check install install-am install-exec-am install-strip .PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \ - clean-generic clean-krextra clean-libtool ctags distclean \ + clean-generic clean-libtool clean-sbinPROGRAMS ctags distclean \ distclean-compile distclean-generic distclean-libtool \ distclean-tags distdir dvi dvi-am html html-am info info-am \ install install-am install-binPROGRAMS install-data \ install-data-am install-dvi install-dvi-am install-exec \ - install-exec-am install-html install-html-am install-info \ - install-info-am install-man install-man1 install-pdf \ - install-pdf-am install-ps install-ps-am install-strip \ - installcheck installcheck-am installdirs maintainer-clean \ + install-exec-am install-exec-hook install-html install-html-am \ + install-info install-info-am install-man install-man1 \ + install-pdf install-pdf-am install-ps install-ps-am \ + install-sbinPROGRAMS install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-compile \ - mostlyclean-generic mostlyclean-kr mostlyclean-libtool pdf \ - pdf-am ps ps-am tags uninstall uninstall-am \ - uninstall-binPROGRAMS uninstall-man uninstall-man1 + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags uninstall uninstall-am uninstall-binPROGRAMS \ + uninstall-man uninstall-man1 uninstall-sbinPROGRAMS $(srcdir)/ntp-keygen-opts.h: $(srcdir)/ntp-keygen-opts.c + @: do-nothing action to avoid default SCCS get, .h built with .c + $(srcdir)/ntp-keygen-opts.c: $(srcdir)/ntp-keygen-opts.def $(std_def_list) $(run_ag) ntp-keygen-opts.def $(srcdir)/ntp-keygen.1: $(srcdir)/ntp-keygen-opts.def $(std_def_list) $(run_ag) -Tagman1.tpl -bntp-keygen ntp-keygen-opts.def -$(srcdir)/ntp-keygen-opts.texi $(srcdir)/ntp-keygen-opts.menu: $(srcdir)/ntp-keygen-opts.def $(std_def_list) +$(srcdir)/ntp-keygen-opts.menu: $(srcdir)/ntp-keygen-opts.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/ntp-keygen-opts.texi: $(srcdir)/ntp-keygen-opts.def $(std_def_list) $(run_ag) -Taginfo.tpl -DLEVEL=section ntp-keygen-opts.def ../libntp/libntp.a: @@ -822,6 +849,82 @@ kern.o: kern.c $(COMPILE) -DHAVE_TIMEX_H -c kern.c +install-exec-hook: + @case ${BINSUBDIR} in \ + bin) ODIR=${sbindir} ;; \ + sbin) ODIR=${bindir} ;; \ + esac; \ + test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ + || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ + test ! -f $$ODIR/$$i || echo "*** $$i is also in $$ODIR!"; \ + done + +# +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + ..) \ + cd .. && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + *) \ + echo 'Fatal: depsver.mf Automake fragment limited' \ + 'to immediate subdirectories.' && \ + echo "top_builddir: $(top_builddir)" && \ + echo "subdir: $(subdir)" && \ + exit 1 \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# + # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: diff -urN src/contrib/ntp/util/hist.c src.ntp/contrib/ntp/util/hist.c --- src/contrib/ntp/util/hist.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/util/hist.c 2009-12-09 08:36:36.000000000 +0100 @@ -20,7 +20,7 @@ #define NSRT 20000 /* size of overflow histogram */ #define NCNT (600 * 1000000) /* sample interval (us) */ -int col P((long *, long *)); +int col (long *, long *); int main( diff -urN src/contrib/ntp/util/jitter.c src.ntp/contrib/ntp/util/jitter.c --- src/contrib/ntp/util/jitter.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/util/jitter.c 2009-12-09 08:36:35.000000000 +0100 @@ -16,7 +16,7 @@ #include #include "jitter.h" -#define NBUF 80002 +#define NBUF 800002 #define FRAC 4294967296. /* a bbbbillion */ #define JAN_1970 2208988800UL /* Unix base epoch */ #define CLOCK_GETTIME /* Solaris hires clock */ diff -urN src/contrib/ntp/util/jitter.h src.ntp/contrib/ntp/util/jitter.h --- src/contrib/ntp/util/jitter.h 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/util/jitter.h 2009-12-09 08:36:36.000000000 +0100 @@ -7,17 +7,6 @@ #define SIZEOF_INT 4 /* - * Set up for prototyping - */ -#ifndef P -#if defined(__STDC__) || defined(HAVE_PROTOTYPES) -#define P(x) x -#else /* not __STDC__ and not HAVE_PROTOTYPES */ -#define P(x) () -#endif /* not __STDC__ and HAVE_PROTOTYPES */ -#endif /* P */ - -/* * VMS DECC (v4.1), {u_char,u_short,u_long} are only in SOCKET.H, * and u_int isn't defined anywhere */ @@ -382,25 +371,25 @@ * Prototypes */ #if 0 -extern char * dofptoa P((u_fp, int, short, int)); -extern char * dolfptoa P((u_long, u_long, int, short, int)); +extern char * dofptoa (u_fp, int, short, int); +extern char * dolfptoa (u_long, u_long, int, short, int); #endif -extern int atolfp P((const char *, l_fp *)); -extern int buftvtots P((const char *, l_fp *)); -extern char * fptoa P((s_fp, short)); -extern char * fptoms P((s_fp, short)); -extern int hextolfp P((const char *, l_fp *)); -extern void gpstolfp P((int, int, unsigned long, l_fp *)); -extern int mstolfp P((const char *, l_fp *)); -extern char * prettydate P((l_fp *)); -extern char * gmprettydate P((l_fp *)); -extern char * uglydate P((l_fp *)); -extern void mfp_mul P((int32 *, u_int32 *, int32, u_int32, int32, u_int32)); - -extern void get_systime P((l_fp *)); -extern int step_systime P((double)); -extern int adj_systime P((double)); +extern int atolfp (const char *, l_fp *); +extern int buftvtots (const char *, l_fp *); +extern char * fptoa (s_fp, short); +extern char * fptoms (s_fp, short); +extern int hextolfp (const char *, l_fp *); +extern void gpstolfp (int, int, unsigned long, l_fp *); +extern int mstolfp (const char *, l_fp *); +extern char * prettydate (l_fp *); +extern char * gmprettydate (l_fp *); +extern char * uglydate (l_fp *); +extern void mfp_mul (int32 *, u_int32 *, int32, u_int32, int32, u_int32); + +extern void get_systime (l_fp *); +extern int step_systime (double); +extern int adj_systime (double); #define lfptoa(_fpv, _ndec) mfptoa((_fpv)->l_ui, (_fpv)->l_uf, (_ndec)) #define lfptoms(_fpv, _ndec) mfptoms((_fpv)->l_ui, (_fpv)->l_uf, (_ndec)) diff -urN src/contrib/ntp/util/ntp-keygen-opts.c src.ntp/contrib/ntp/util/ntp-keygen-opts.c --- src/contrib/ntp/util/ntp-keygen-opts.c 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/util/ntp-keygen-opts.c 2010-07-09 04:25:41.000000000 +0200 @@ -1,11 +1,11 @@ /* * EDIT THIS FILE WITH CAUTION (ntp-keygen-opts.c) * - * It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:56 AM EST + * It has been AutoGen-ed July 9, 2010 at 02:25:41 AM by AutoGen 5.10 * From the definitions ntp-keygen-opts.def * and the template file options * - * Generated from AutoOpts 29:0:4 templates. + * Generated from AutoOpts 33:0:8 templates. */ /* @@ -19,26 +19,33 @@ * * This source file is copyrighted and licensed under the following terms: * - * ntp-keygen copyright 1970-2009 David L. Mills and/or others - all rights reserved + * ntp-keygen copyright (c) 1970-2010 David L. Mills and/or others - all rights reserved * * see html/copyright.html */ - +#include #include #include +#include +#include +extern FILE * option_usage_fp; #define OPTION_CODE_COMPILE 1 #include "ntp-keygen-opts.h" #ifdef __cplusplus extern "C" { #endif + +/* TRANSLATORS: choose the translation for option names wisely because you + cannot ever change your mind. */ tSCC zCopyright[] = - "ntp-keygen copyright (c) 1970-2009 David L. Mills and/or others, all rights reserved"; -tSCC zCopyrightNotice[] = - + "ntp-keygen copyright (c) 1970-2010 David L. Mills and/or others, all rights reserved" /* extracted from ../include/copyright.def near line 8 */ +; +tSCC zCopyrightNotice[24] = "see html/copyright.html"; + extern tUsageProc optionUsage; /* @@ -60,6 +67,7 @@ #ifndef EXIT_FAILURE # define EXIT_FAILURE 1 #endif + /* * Certificate option description: */ @@ -72,35 +80,24 @@ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) #else /* disable Certificate */ -#define VALUE_OPT_CERTIFICATE NO_EQUIVALENT #define CERTIFICATE_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zCertificateText NULL #define zCertificate_NAME NULL +#define zCertificateText NULL #define zCertificate_Name NULL #endif /* OPENSSL */ /* * Debug_Level option description: */ -#ifdef DEBUG tSCC zDebug_LevelText[] = "Increase output debug message level"; tSCC zDebug_Level_NAME[] = "DEBUG_LEVEL"; tSCC zDebug_Level_Name[] = "debug-level"; #define DEBUG_LEVEL_FLAGS (OPTST_DISABLED) -#else /* disable Debug_Level */ -#define VALUE_OPT_DEBUG_LEVEL NO_EQUIVALENT -#define DEBUG_LEVEL_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zDebug_LevelText NULL -#define zDebug_Level_NAME NULL -#define zDebug_Level_Name NULL -#endif /* DEBUG */ - /* * Set_Debug_Level option description: */ -#ifdef DEBUG tSCC zSet_Debug_LevelText[] = "Set the output debug message level"; tSCC zSet_Debug_Level_NAME[] = "SET_DEBUG_LEVEL"; @@ -108,29 +105,20 @@ #define SET_DEBUG_LEVEL_FLAGS (OPTST_DISABLED \ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) -#else /* disable Set_Debug_Level */ -#define VALUE_OPT_SET_DEBUG_LEVEL NO_EQUIVALENT -#define SET_DEBUG_LEVEL_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zSet_Debug_LevelText NULL -#define zSet_Debug_Level_NAME NULL -#define zSet_Debug_Level_Name NULL -#endif /* DEBUG */ - /* * Id_Key option description: */ #ifdef OPENSSL tSCC zId_KeyText[] = - "Write identity keys"; + "Write IFF or GQ identity keys"; tSCC zId_Key_NAME[] = "ID_KEY"; tSCC zId_Key_Name[] = "id-key"; #define ID_KEY_FLAGS (OPTST_DISABLED) #else /* disable Id_Key */ -#define VALUE_OPT_ID_KEY NO_EQUIVALENT #define ID_KEY_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zId_KeyText NULL #define zId_Key_NAME NULL +#define zId_KeyText NULL #define zId_Key_Name NULL #endif /* OPENSSL */ @@ -145,32 +133,13 @@ #define GQ_PARAMS_FLAGS (OPTST_DISABLED) #else /* disable Gq_Params */ -#define VALUE_OPT_GQ_PARAMS NO_EQUIVALENT #define GQ_PARAMS_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zGq_ParamsText NULL #define zGq_Params_NAME NULL +#define zGq_ParamsText NULL #define zGq_Params_Name NULL #endif /* OPENSSL */ /* - * Gq_Keys option description: - */ -#ifdef OPENSSL -tSCC zGq_KeysText[] = - "update GQ keys"; -tSCC zGq_Keys_NAME[] = "GQ_KEYS"; -tSCC zGq_Keys_Name[] = "gq-keys"; -#define GQ_KEYS_FLAGS (OPTST_DISABLED) - -#else /* disable Gq_Keys */ -#define VALUE_OPT_GQ_KEYS NO_EQUIVALENT -#define GQ_KEYS_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zGq_KeysText NULL -#define zGq_Keys_NAME NULL -#define zGq_Keys_Name NULL -#endif /* OPENSSL */ - -/* * Host_Key option description: */ #ifdef OPENSSL @@ -181,10 +150,9 @@ #define HOST_KEY_FLAGS (OPTST_DISABLED) #else /* disable Host_Key */ -#define VALUE_OPT_HOST_KEY NO_EQUIVALENT #define HOST_KEY_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zHost_KeyText NULL #define zHost_Key_NAME NULL +#define zHost_KeyText NULL #define zHost_Key_Name NULL #endif /* OPENSSL */ @@ -199,10 +167,9 @@ #define IFFKEY_FLAGS (OPTST_DISABLED) #else /* disable Iffkey */ -#define VALUE_OPT_IFFKEY NO_EQUIVALENT #define IFFKEY_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zIffkeyText NULL #define zIffkey_NAME NULL +#define zIffkeyText NULL #define zIffkey_Name NULL #endif /* OPENSSL */ @@ -214,13 +181,13 @@ "set issuer name"; tSCC zIssuer_Name_NAME[] = "ISSUER_NAME"; tSCC zIssuer_Name_Name[] = "issuer-name"; -#define ISSUER_NAME_FLAGS (OPTST_DISABLED) +#define ISSUER_NAME_FLAGS (OPTST_DISABLED \ + | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) #else /* disable Issuer_Name */ -#define VALUE_OPT_ISSUER_NAME NO_EQUIVALENT #define ISSUER_NAME_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zIssuer_NameText NULL #define zIssuer_Name_NAME NULL +#define zIssuer_NameText NULL #define zIssuer_Name_Name NULL #endif /* OPENSSL */ @@ -245,10 +212,9 @@ | OPTST_SET_ARGTYPE(OPARG_TYPE_NUMERIC)) #else /* disable Modulus */ -#define VALUE_OPT_MODULUS NO_EQUIVALENT #define MODULUS_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zModulusText NULL #define zModulus_NAME NULL +#define zModulusText NULL #define zModulus_Name NULL #endif /* OPENSSL */ @@ -263,10 +229,9 @@ #define PVT_CERT_FLAGS (OPTST_DISABLED) #else /* disable Pvt_Cert */ -#define VALUE_OPT_PVT_CERT NO_EQUIVALENT #define PVT_CERT_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zPvt_CertText NULL #define zPvt_Cert_NAME NULL +#define zPvt_CertText NULL #define zPvt_Cert_Name NULL #endif /* OPENSSL */ @@ -282,10 +247,9 @@ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) #else /* disable Pvt_Passwd */ -#define VALUE_OPT_PVT_PASSWD NO_EQUIVALENT #define PVT_PASSWD_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zPvt_PasswdText NULL #define zPvt_Passwd_NAME NULL +#define zPvt_PasswdText NULL #define zPvt_Passwd_Name NULL #endif /* OPENSSL */ @@ -301,10 +265,9 @@ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) #else /* disable Get_Pvt_Passwd */ -#define VALUE_OPT_GET_PVT_PASSWD NO_EQUIVALENT #define GET_PVT_PASSWD_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zGet_Pvt_PasswdText NULL #define zGet_Pvt_Passwd_NAME NULL +#define zGet_Pvt_PasswdText NULL #define zGet_Pvt_Passwd_Name NULL #endif /* OPENSSL */ @@ -320,10 +283,9 @@ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) #else /* disable Sign_Key */ -#define VALUE_OPT_SIGN_KEY NO_EQUIVALENT #define SIGN_KEY_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zSign_KeyText NULL #define zSign_Key_NAME NULL +#define zSign_KeyText NULL #define zSign_Key_Name NULL #endif /* OPENSSL */ @@ -339,10 +301,9 @@ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) #else /* disable Subject_Name */ -#define VALUE_OPT_SUBJECT_NAME NO_EQUIVALENT #define SUBJECT_NAME_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zSubject_NameText NULL #define zSubject_Name_NAME NULL +#define zSubject_NameText NULL #define zSubject_Name_Name NULL #endif /* OPENSSL */ @@ -357,10 +318,9 @@ #define TRUSTED_CERT_FLAGS (OPTST_DISABLED) #else /* disable Trusted_Cert */ -#define VALUE_OPT_TRUSTED_CERT NO_EQUIVALENT #define TRUSTED_CERT_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zTrusted_CertText NULL #define zTrusted_Cert_NAME NULL +#define zTrusted_CertText NULL #define zTrusted_Cert_Name NULL #endif /* OPENSSL */ @@ -376,10 +336,9 @@ | OPTST_SET_ARGTYPE(OPARG_TYPE_NUMERIC)) #else /* disable Mv_Params */ -#define VALUE_OPT_MV_PARAMS NO_EQUIVALENT #define MV_PARAMS_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zMv_ParamsText NULL #define zMv_Params_NAME NULL +#define zMv_ParamsText NULL #define zMv_Params_Name NULL #endif /* OPENSSL */ @@ -395,45 +354,45 @@ | OPTST_SET_ARGTYPE(OPARG_TYPE_NUMERIC)) #else /* disable Mv_Keys */ -#define VALUE_OPT_MV_KEYS NO_EQUIVALENT #define MV_KEYS_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zMv_KeysText NULL #define zMv_Keys_NAME NULL +#define zMv_KeysText NULL #define zMv_Keys_Name NULL #endif /* OPENSSL */ /* * Help/More_Help/Version option descriptions: */ -tSCC zHelpText[] = "Display usage information and exit"; -tSCC zHelp_Name[] = "help"; - -tSCC zMore_HelpText[] = "Extended usage information passed thru pager"; -tSCC zMore_Help_Name[] = "more-help"; - -tSCC zVersionText[] = "Output version information and exit"; -tSCC zVersion_Name[] = "version"; +tSCC zHelpText[] = "Display extended usage information and exit"; +tSCC zHelp_Name[] = "help"; +#ifdef HAVE_WORKING_FORK +#define OPTST_MORE_HELP_FLAGS (OPTST_IMM | OPTST_NO_INIT) +tSCC zMore_Help_Name[] = "more-help"; +tSCC zMore_HelpText[] = "Extended usage information passed thru pager"; +#else +#define OPTST_MORE_HELP_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#define zMore_Help_Name NULL +#define zMore_HelpText NULL +#endif +#ifdef NO_OPTIONAL_OPT_ARGS +# define OPTST_VERSION_FLAGS OPTST_IMM | OPTST_NO_INIT +#else +# define OPTST_VERSION_FLAGS OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ + OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT +#endif -/* - * Save/Load_Opts option description: - */ +tSCC zVersionText[] = "Output version information and exit"; +tSCC zVersion_Name[] = "version"; tSCC zSave_OptsText[] = "Save the option state to a config file"; tSCC zSave_Opts_Name[] = "save-opts"; - tSCC zLoad_OptsText[] = "Load options from a config file"; tSCC zLoad_Opts_NAME[] = "LOAD_OPTS"; - tSCC zNotLoad_Opts_Name[] = "no-load-opts"; tSCC zNotLoad_Opts_Pfx[] = "no"; #define zLoad_Opts_Name (zNotLoad_Opts_Name + 3) /* * Declare option callback procedures */ -#ifdef DEBUG - static tOptProc doOptSet_Debug_Level; -#else /* not DEBUG */ -# define doOptSet_Debug_Level NULL -#endif /* def/not DEBUG */ #ifdef OPENSSL static tOptProc doOptModulus; #else /* not OPENSSL */ @@ -472,7 +431,7 @@ extern tOptProc optionPagedUsage, optionPrintVersion; static tOptProc - doUsageOpt; + doOptSet_Debug_Level, doUsageOpt; /* * #define map the "normal" callout procs @@ -552,20 +511,8 @@ /* desc, NAME, name */ zGq_ParamsText, zGq_Params_NAME, zGq_Params_Name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 5, VALUE_OPT_GQ_KEYS, - /* equiv idx, value */ 5, VALUE_OPT_GQ_KEYS, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ GQ_KEYS_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zGq_KeysText, zGq_Keys_NAME, zGq_Keys_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 6, VALUE_OPT_HOST_KEY, - /* equiv idx, value */ 6, VALUE_OPT_HOST_KEY, + { /* entry idx, value */ 5, VALUE_OPT_HOST_KEY, + /* equiv idx, value */ 5, VALUE_OPT_HOST_KEY, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ HOST_KEY_FLAGS, 0, @@ -576,8 +523,8 @@ /* desc, NAME, name */ zHost_KeyText, zHost_Key_NAME, zHost_Key_Name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 7, VALUE_OPT_IFFKEY, - /* equiv idx, value */ 7, VALUE_OPT_IFFKEY, + { /* entry idx, value */ 6, VALUE_OPT_IFFKEY, + /* equiv idx, value */ 6, VALUE_OPT_IFFKEY, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ IFFKEY_FLAGS, 0, @@ -588,8 +535,8 @@ /* desc, NAME, name */ zIffkeyText, zIffkey_NAME, zIffkey_Name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 8, VALUE_OPT_ISSUER_NAME, - /* equiv idx, value */ 8, VALUE_OPT_ISSUER_NAME, + { /* entry idx, value */ 7, VALUE_OPT_ISSUER_NAME, + /* equiv idx, value */ 7, VALUE_OPT_ISSUER_NAME, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ ISSUER_NAME_FLAGS, 0, @@ -600,8 +547,8 @@ /* desc, NAME, name */ zIssuer_NameText, zIssuer_Name_NAME, zIssuer_Name_Name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 9, VALUE_OPT_MD5KEY, - /* equiv idx, value */ 9, VALUE_OPT_MD5KEY, + { /* entry idx, value */ 8, VALUE_OPT_MD5KEY, + /* equiv idx, value */ 8, VALUE_OPT_MD5KEY, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ MD5KEY_FLAGS, 0, @@ -612,8 +559,8 @@ /* desc, NAME, name */ zMd5keyText, zMd5key_NAME, zMd5key_Name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 10, VALUE_OPT_MODULUS, - /* equiv idx, value */ 10, VALUE_OPT_MODULUS, + { /* entry idx, value */ 9, VALUE_OPT_MODULUS, + /* equiv idx, value */ 9, VALUE_OPT_MODULUS, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ MODULUS_FLAGS, 0, @@ -624,8 +571,8 @@ /* desc, NAME, name */ zModulusText, zModulus_NAME, zModulus_Name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 11, VALUE_OPT_PVT_CERT, - /* equiv idx, value */ 11, VALUE_OPT_PVT_CERT, + { /* entry idx, value */ 10, VALUE_OPT_PVT_CERT, + /* equiv idx, value */ 10, VALUE_OPT_PVT_CERT, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ PVT_CERT_FLAGS, 0, @@ -636,8 +583,8 @@ /* desc, NAME, name */ zPvt_CertText, zPvt_Cert_NAME, zPvt_Cert_Name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 12, VALUE_OPT_PVT_PASSWD, - /* equiv idx, value */ 12, VALUE_OPT_PVT_PASSWD, + { /* entry idx, value */ 11, VALUE_OPT_PVT_PASSWD, + /* equiv idx, value */ 11, VALUE_OPT_PVT_PASSWD, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ PVT_PASSWD_FLAGS, 0, @@ -648,8 +595,8 @@ /* desc, NAME, name */ zPvt_PasswdText, zPvt_Passwd_NAME, zPvt_Passwd_Name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 13, VALUE_OPT_GET_PVT_PASSWD, - /* equiv idx, value */ 13, VALUE_OPT_GET_PVT_PASSWD, + { /* entry idx, value */ 12, VALUE_OPT_GET_PVT_PASSWD, + /* equiv idx, value */ 12, VALUE_OPT_GET_PVT_PASSWD, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ GET_PVT_PASSWD_FLAGS, 0, @@ -660,8 +607,8 @@ /* desc, NAME, name */ zGet_Pvt_PasswdText, zGet_Pvt_Passwd_NAME, zGet_Pvt_Passwd_Name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 14, VALUE_OPT_SIGN_KEY, - /* equiv idx, value */ 14, VALUE_OPT_SIGN_KEY, + { /* entry idx, value */ 13, VALUE_OPT_SIGN_KEY, + /* equiv idx, value */ 13, VALUE_OPT_SIGN_KEY, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ SIGN_KEY_FLAGS, 0, @@ -672,8 +619,8 @@ /* desc, NAME, name */ zSign_KeyText, zSign_Key_NAME, zSign_Key_Name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 15, VALUE_OPT_SUBJECT_NAME, - /* equiv idx, value */ 15, VALUE_OPT_SUBJECT_NAME, + { /* entry idx, value */ 14, VALUE_OPT_SUBJECT_NAME, + /* equiv idx, value */ 14, VALUE_OPT_SUBJECT_NAME, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ SUBJECT_NAME_FLAGS, 0, @@ -684,8 +631,8 @@ /* desc, NAME, name */ zSubject_NameText, zSubject_Name_NAME, zSubject_Name_Name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 16, VALUE_OPT_TRUSTED_CERT, - /* equiv idx, value */ 16, VALUE_OPT_TRUSTED_CERT, + { /* entry idx, value */ 15, VALUE_OPT_TRUSTED_CERT, + /* equiv idx, value */ 15, VALUE_OPT_TRUSTED_CERT, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ TRUSTED_CERT_FLAGS, 0, @@ -696,8 +643,8 @@ /* desc, NAME, name */ zTrusted_CertText, zTrusted_Cert_NAME, zTrusted_Cert_Name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 17, VALUE_OPT_MV_PARAMS, - /* equiv idx, value */ 17, VALUE_OPT_MV_PARAMS, + { /* entry idx, value */ 16, VALUE_OPT_MV_PARAMS, + /* equiv idx, value */ 16, VALUE_OPT_MV_PARAMS, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ MV_PARAMS_FLAGS, 0, @@ -708,8 +655,8 @@ /* desc, NAME, name */ zMv_ParamsText, zMv_Params_NAME, zMv_Params_Name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 18, VALUE_OPT_MV_KEYS, - /* equiv idx, value */ 18, VALUE_OPT_MV_KEYS, + { /* entry idx, value */ 17, VALUE_OPT_MV_KEYS, + /* equiv idx, value */ 17, VALUE_OPT_MV_KEYS, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ MV_KEYS_FLAGS, 0, @@ -720,18 +667,11 @@ /* desc, NAME, name */ zMv_KeysText, zMv_Keys_NAME, zMv_Keys_Name, /* disablement strs */ NULL, NULL }, -#ifdef NO_OPTIONAL_OPT_ARGS -# define VERSION_OPT_FLAGS OPTST_IMM | OPTST_NO_INIT -#else -# define VERSION_OPT_FLAGS OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ - OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT -#endif - { /* entry idx, value */ INDEX_OPT_VERSION, VALUE_OPT_VERSION, /* equiv idx value */ NO_EQUIVALENT, 0, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ VERSION_OPT_FLAGS, 0, + /* opt state flags */ OPTST_VERSION_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, @@ -739,7 +679,6 @@ /* desc, NAME, name */ zVersionText, NULL, zVersion_Name, /* disablement strs */ NULL, NULL }, -#undef VERSION_OPT_FLAGS { /* entry idx, value */ INDEX_OPT_HELP, VALUE_OPT_HELP, @@ -758,7 +697,7 @@ /* equiv idx value */ NO_EQUIVALENT, 0, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, 0, + /* opt state flags */ OPTST_MORE_HELP_FLAGS, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, @@ -783,7 +722,7 @@ /* equiv idx value */ NO_EQUIVALENT, 0, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, NOLIMIT, 0, - /* opt state flags */ OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) \ + /* opt state flags */ OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | OPTST_DISABLE_IMM, 0, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, @@ -799,7 +738,7 @@ */ tSCC zPROGNAME[] = "NTP_KEYGEN"; tSCC zUsageTitle[] = -"ntp-keygen (ntp) - Create a NTP host key - Ver. 4.2.4p8\n\ +"ntp-keygen (ntp) - Create a NTP host key - Ver. 4.2.6p2\n\ USAGE: %s [ - [] | --[{=| }] ]...\n"; tSCC zRcName[] = ".ntprc"; tSCC* apzHomeList[] = { @@ -813,7 +752,7 @@ If there is no new host key, look for an existing one.\n\ If one is not found, create it.\n"; tSCC zFullVersion[] = NTP_KEYGEN_FULL_VERSION; -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optcode.tpl near line 408 */ +/* extracted from /usr/local/gnu/share/autogen/optcode.tpl near line 495 */ #if defined(ENABLE_NLS) # define OPTPROC_BASE OPTPROC_TRANSLATE @@ -823,6 +762,9 @@ # define translate_option_strings NULL #endif /* ENABLE_NLS */ + +#define ntp_keygen_full_usage NULL +#define ntp_keygen_short_usage NULL tOptions ntp_keygenOptions = { OPTIONS_STRUCT_VERSION, 0, NULL, /* original argc + argv */ @@ -832,8 +774,7 @@ + OPTPROC_LONGOPT + OPTPROC_NO_REQ_OPT + OPTPROC_ENVIRON - + OPTPROC_NO_ARGS - + OPTPROC_HAS_IMMED ), + + OPTPROC_NO_ARGS ), 0, NULL, /* current option index, current option */ NULL, NULL, zPROGNAME, zRcName, zCopyright, zCopyrightNotice, @@ -846,12 +787,14 @@ /* * Indexes to special options */ - { INDEX_OPT_MORE_HELP, - INDEX_OPT_SAVE_OPTS, - NO_EQUIVALENT /* index of '-#' option */, + { INDEX_OPT_MORE_HELP, /* more-help option index */ + INDEX_OPT_SAVE_OPTS, /* save option index */ + NO_EQUIVALENT, /* '-#' option index */ NO_EQUIVALENT /* index of default opt */ }, - 24 /* full option count */, 19 /* user option count */ + 23 /* full option count */, 18 /* user option count */, + ntp_keygen_full_usage, ntp_keygen_short_usage, + NULL, NULL }; /* @@ -862,98 +805,91 @@ tOptions* pOptions, tOptDesc* pOptDesc ) { + (void)pOptions; USAGE( EXIT_SUCCESS ); } #if ! defined(TEST_NTP_KEYGEN_OPTS) -/* * * * * * * +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * For the set-debug-level option, when DEBUG is #define-d. + * For the set-debug-level option. */ -#ifdef DEBUG static void -doOptSet_Debug_Level( - tOptions* pOptions, - tOptDesc* pOptDesc ) +doOptSet_Debug_Level(tOptions* pOptions, tOptDesc* pOptDesc) { - /* extracted from ../include/debug-opt.def, line 29 */ + /* extracted from ../include/debug-opt.def, line 27 */ DESC(DEBUG_LEVEL).optOccCt = atoi( pOptDesc->pzLastArg ); } -#endif /* defined DEBUG */ - #endif /* defined(TEST_NTP_KEYGEN_OPTS) */ -/* * * * * * * +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * For the modulus option, when OPENSSL is #define-d. */ #ifdef OPENSSL static void -doOptModulus( - tOptions* pOptions, - tOptDesc* pOptDesc ) +doOptModulus(tOptions* pOptions, tOptDesc* pOptDesc) { - static const struct {const int rmin, rmax;} rng[ 1 ] = { + static const struct {long const rmin, rmax;} rng[1] = { { 256, 2048 } }; - int val; - int ix; - char const* pzIndent = "\t\t\t\t "; - extern FILE* option_usage_fp; + long val; + int ix; + char * pzEnd; - if (pOptDesc == NULL) /* usage is requesting range list - option_usage_fp has already been set */ + if (pOptions <= OPTPROC_EMIT_LIMIT) goto emit_ranges; - val = atoi( pOptDesc->optArg.argString ); + errno = 0; + val = strtol(pOptDesc->optArg.argString, &pzEnd, 0); + if ((pOptDesc->optArg.argString == pzEnd) || (errno != 0)) + goto bad_value; + + if (*pzEnd != '\0') + goto bad_value; for (ix = 0; ix < 1; ix++) { if (val < rng[ix].rmin) continue; /* ranges need not be ordered. */ if (val == rng[ix].rmin) goto valid_return; - if (rng[ix].rmax == INT_MIN) + if (rng[ix].rmax == LONG_MIN) continue; if (val <= rng[ix].rmax) goto valid_return; } + bad_value: + option_usage_fp = stderr; - fprintf(stderr, _("%s error: %s option value ``%s''is out of range.\n"), - pOptions->pzProgName, pOptDesc->pz_Name, pOptDesc->optArg.argString); - pzIndent = "\t"; emit_ranges: - fprintf( option_usage_fp, _("%sit must lie in the range: %d to %d\n"), - pzIndent, rng[0].rmin, rng[0].rmax ); - if (pOptDesc == NULL) - return; - - USAGE( EXIT_FAILURE ); - /* NOTREACHED */ + optionShowRange(pOptions, pOptDesc, (void *)rng, 1); return; valid_return: + if ((pOptDesc->fOptState & OPTST_ALLOC_ARG) != 0) { + free((void *)pOptDesc->optArg.argString); + pOptDesc->fOptState &= ~OPTST_ALLOC_ARG; + } pOptDesc->optArg.argInt = val; } #endif /* defined OPENSSL */ - -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optmain.tpl near line 92 */ +/* extracted from /usr/local/gnu/share/autogen/optmain.tpl near line 109 */ #if defined(TEST_NTP_KEYGEN_OPTS) /* TEST MAIN PROCEDURE: */ +extern void optionPutShell( tOptions* ); + int -main( int argc, char** argv ) +main(int argc, char** argv) { int res = EXIT_SUCCESS; (void)optionProcess( &ntp_keygenOptions, argc, argv ); - { - void optionPutShell( tOptions* ); - optionPutShell( &ntp_keygenOptions ); - } + optionPutShell( &ntp_keygenOptions ); return res; } #endif /* defined TEST_NTP_KEYGEN_OPTS */ -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optcode.tpl near line 514 */ +/* extracted from /usr/local/gnu/share/autogen/optcode.tpl near line 627 */ #if ENABLE_NLS #include @@ -996,44 +932,45 @@ * Guard against re-translation. It won't work. The strings will have * been changed by the first pass through this code. One shot only. */ - if (option_usage_text.field_ct == 0) - return; - /* - * Do the translations. The first pointer follows the field count field. - * The field count field is the size of a pointer. - */ - { - char** ppz = (char**)(void*)&(option_usage_text); - int ix = option_usage_text.field_ct; + if (option_usage_text.field_ct != 0) { + + /* + * Do the translations. The first pointer follows the field count + * field. The field count field is the size of a pointer. + */ + tOptDesc* pOD = ntp_keygenOptions.pOptDesc; + char** ppz = (char**)(void*)&(option_usage_text); + int ix = option_usage_text.field_ct; do { ppz++; *ppz = AO_gettext(*ppz); } while (--ix > 0); + + COERSION(pzCopyright); + COERSION(pzCopyNotice); + COERSION(pzFullVersion); + COERSION(pzUsageTitle); + COERSION(pzExplain); + COERSION(pzDetail); + option_usage_text.field_ct = 0; + + for (ix = ntp_keygenOptions.optCt; ix > 0; ix--, pOD++) + coerce_it((void*)&(pOD->pzText)); } - option_usage_text.field_ct = 0; - { + if ((ntp_keygenOptions.fOptSet & OPTPROC_NXLAT_OPT_CFG) == 0) { tOptDesc* pOD = ntp_keygenOptions.pOptDesc; - int ix = ntp_keygenOptions.optCt; + int ix; - for (;;) { - pOD->pzText = AO_gettext(pOD->pzText); - pOD->pz_NAME = AO_gettext(pOD->pz_NAME); - pOD->pz_Name = AO_gettext(pOD->pz_Name); - pOD->pz_DisableName = AO_gettext(pOD->pz_DisableName); - pOD->pz_DisablePfx = AO_gettext(pOD->pz_DisablePfx); - if (--ix <= 0) - break; - pOD++; + for (ix = ntp_keygenOptions.optCt; ix > 0; ix--, pOD++) { + coerce_it((void*)&(pOD->pz_Name)); + coerce_it((void*)&(pOD->pz_DisableName)); + coerce_it((void*)&(pOD->pz_DisablePfx)); } + /* prevent re-translation */ + ntp_keygenOptions.fOptSet |= OPTPROC_NXLAT_OPT_CFG | OPTPROC_NXLAT_OPT; } - COERSION(pzCopyright); - COERSION(pzCopyNotice); - COERSION(pzFullVersion); - COERSION(pzUsageTitle); - COERSION(pzExplain); - COERSION(pzDetail); } #endif /* ENABLE_NLS */ diff -urN src/contrib/ntp/util/ntp-keygen-opts.def src.ntp/contrib/ntp/util/ntp-keygen-opts.def --- src/contrib/ntp/util/ntp-keygen-opts.def 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/util/ntp-keygen-opts.def 2009-12-09 08:36:35.000000000 +0100 @@ -16,191 +16,198 @@ #include version.def flag = { - name = certificate; value = c; + name = certificate; arg-type = string; arg-name = scheme; ifdef = OPENSSL; descrip = "certificate scheme"; doc = <<- _EndOfDoc_ - Just some descriptive text. + scheme is one of + RSA-MD2, RSA-MD5, RSA-SHA, RSA-SHA1, RSA-MDC2, RSA-RIPEMD160, + DSA-SHA, or DSA-SHA1. + + Select the certificate message digest/signature encryption scheme. + Note that RSA schemes must be used with a RSA sign key and DSA + schemes must be used with a DSA sign key. The default without + this option is RSA-MD5. _EndOfDoc_; }; #include debug-opt.def flag = { - name = id-key; value = e; + name = id-key; ifdef = OPENSSL; - descrip = "Write identity keys"; + descrip = "Write IFF or GQ identity keys"; doc = <<- _EndOfDoc_ - Just some descriptive text. + Write the IFF or GQ client keys to the standard output. This is + intended for automatic key distribution by mail. _EndOfDoc_; }; flag = { - name = gq-params; value = G; + name = gq-params; ifdef = OPENSSL; descrip = "Generate GQ parameters and keys"; doc = <<- _EndOfDoc_ - Just some descriptive text. + Generate parameters and keys for the GQ identification scheme, + obsoleting any that may exist. _EndOfDoc_; }; flag = { - name = gq-keys; - value = g; - ifdef = OPENSSL; - descrip = "update GQ keys"; - doc = <<- _EndOfDoc_ - Just some descriptive text. - _EndOfDoc_; -}; - -flag = { - name = host-key; value = H; + name = host-key; ifdef = OPENSSL; descrip = "generate RSA host key"; doc = <<- _EndOfDoc_ - Just some descriptive text. + Generate new host keys, obsoleting any that may exist. _EndOfDoc_; }; flag = { - name = iffkey; value = I; + name = iffkey; ifdef = OPENSSL; descrip = "generate IFF parameters"; doc = <<- _EndOfDoc_ - Just some descriptive text. + Generate parameters for the IFF identification scheme, obsoleting + any that may exist. _EndOfDoc_; }; flag = { - name = issuer-name; value = i; + name = issuer-name; ifdef = OPENSSL; + arg-type = string; + arg-name = issuer-name; descrip = "set issuer name"; doc = <<- _EndOfDoc_ - Just some descriptive text. + Set the suject name to name. This is used as the subject field + in certificates and in the file name for host and sign keys. _EndOfDoc_; }; flag = { - name = md5key; value = M; + name = md5key; descrip = "generate MD5 keys"; doc = <<- _EndOfDoc_ - Just some descriptive text. + Generate MD5 keys, obsoleting any that may exist. _EndOfDoc_; }; flag = { - name = modulus; value = m; + name = modulus; arg-type = number; arg-name = modulus; arg-range = '256->2048'; ifdef = OPENSSL; descrip = "modulus"; doc = <<- _EndOfDoc_ - Just some descriptive text. + The number of bits in the prime modulus. The default is 512. _EndOfDoc_; }; flag = { - name = pvt-cert; value = P; + name = pvt-cert; ifdef = OPENSSL; descrip = "generate PC private certificate"; doc = <<- _EndOfDoc_ - Just some descriptive text. + Generate a private certificate. By default, the program generates + public certificates. _EndOfDoc_; }; flag = { - name = pvt-passwd; value = p; + name = pvt-passwd; ifdef = OPENSSL; arg-type = string; arg-name = passwd; descrip = "output private password"; doc = <<- _EndOfDoc_ - Just some descriptive text. + Encrypt generated files containing private data with the specified + password and the DES-CBC algorithm. _EndOfDoc_; }; flag = { - name = get-pvt-passwd; value = q; + name = get-pvt-passwd; ifdef = OPENSSL; arg-type = string; arg-name = passwd; descrip = "input private password"; doc = <<- _EndOfDoc_ - Just some descriptive text. + Set the password for reading files to the specified password. _EndOfDoc_; }; flag = { - name = sign-key; value = S; + name = sign-key; arg-type = string; arg-name = sign; ifdef = OPENSSL; descrip = "generate sign key (RSA or DSA)"; doc = <<- _EndOfDoc_ - Just some descriptive text. + Generate a new sign key of the designated type, obsoleting any + that may exist. By default, the program uses the host key as the + sign key. _EndOfDoc_; }; flag = { - name = subject-name; value = s; + name = subject-name; arg-type = string; arg-name = host; ifdef = OPENSSL; descrip = "set subject name"; doc = <<- _EndOfDoc_ - Just some descriptive text. - _EndOfDoc_; + Set the issuer name to name. This is used for the issuer field + in certificates and in the file name for identity files. + _EndOfDoc_; }; flag = { - name = trusted-cert; value = T; + name = trusted-cert; ifdef = OPENSSL; descrip = "trusted certificate (TC scheme)"; doc = <<- _EndOfDoc_ - Just some descriptive text. + Generate a trusted certificate. By default, the program generates + a non-trusted certificate. _EndOfDoc_; }; flag = { - name = mv-params; value = V; + name = mv-params; arg-type = number; arg-name = num; ifdef = OPENSSL; descrip = "generate MV parameters"; doc = <<- _EndOfDoc_ - Just some descriptive text. + Generate parameters and keys for the Mu-Varadharajan (MV) + identification scheme. _EndOfDoc_; }; flag = { - name = mv-keys; value = v; + name = mv-keys; arg-type = number; arg-name = num; ifdef = OPENSSL; descrip = "update MV keys"; - doc = <<- _EndOfDoc_ - Just some descriptive text. - _EndOfDoc_; }; detail = <<- _EODetail_ diff -urN src/contrib/ntp/util/ntp-keygen-opts.h src.ntp/contrib/ntp/util/ntp-keygen-opts.h --- src/contrib/ntp/util/ntp-keygen-opts.h 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/util/ntp-keygen-opts.h 2010-07-09 04:25:41.000000000 +0200 @@ -1,11 +1,11 @@ /* * EDIT THIS FILE WITH CAUTION (ntp-keygen-opts.h) * - * It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:55 AM EST + * It has been AutoGen-ed July 9, 2010 at 02:25:41 AM by AutoGen 5.10 * From the definitions ntp-keygen-opts.def * and the template file options * - * Generated from AutoOpts 29:0:4 templates. + * Generated from AutoOpts 33:0:8 templates. */ /* @@ -19,7 +19,7 @@ * * This source file is copyrighted and licensed under the following terms: * - * ntp-keygen copyright 1970-2009 David L. Mills and/or others - all rights reserved + * ntp-keygen copyright (c) 1970-2010 David L. Mills and/or others - all rights reserved * * see html/copyright.html */ @@ -30,7 +30,7 @@ * "AutoOpts" chapter. Please refer to that doc for usage help. */ #ifndef AUTOOPTS_NTP_KEYGEN_OPTS_H_GUARD -#define AUTOOPTS_NTP_KEYGEN_OPTS_H_GUARD +#define AUTOOPTS_NTP_KEYGEN_OPTS_H_GUARD 1 #include "config.h" #include @@ -41,7 +41,7 @@ * tolerable version is at least as old as what was current when the header * template was released. */ -#define AO_TEMPLATE_VERSION 118784 +#define AO_TEMPLATE_VERSION 135168 #if (AO_TEMPLATE_VERSION < OPTIONS_MINIMUM_VERSION) \ || (AO_TEMPLATE_VERSION > OPTIONS_STRUCT_VERSION) # error option template version mismatches autoopts/options.h header @@ -52,35 +52,34 @@ * Enumeration of each option: */ typedef enum { - INDEX_OPT_CERTIFICATE = 0, - INDEX_OPT_DEBUG_LEVEL = 1, - INDEX_OPT_SET_DEBUG_LEVEL = 2, - INDEX_OPT_ID_KEY = 3, - INDEX_OPT_GQ_PARAMS = 4, - INDEX_OPT_GQ_KEYS = 5, - INDEX_OPT_HOST_KEY = 6, - INDEX_OPT_IFFKEY = 7, - INDEX_OPT_ISSUER_NAME = 8, - INDEX_OPT_MD5KEY = 9, - INDEX_OPT_MODULUS = 10, - INDEX_OPT_PVT_CERT = 11, - INDEX_OPT_PVT_PASSWD = 12, - INDEX_OPT_GET_PVT_PASSWD = 13, - INDEX_OPT_SIGN_KEY = 14, - INDEX_OPT_SUBJECT_NAME = 15, - INDEX_OPT_TRUSTED_CERT = 16, - INDEX_OPT_MV_PARAMS = 17, - INDEX_OPT_MV_KEYS = 18, - INDEX_OPT_VERSION = 19, - INDEX_OPT_HELP = 20, - INDEX_OPT_MORE_HELP = 21, - INDEX_OPT_SAVE_OPTS = 22, - INDEX_OPT_LOAD_OPTS = 23 + INDEX_OPT_CERTIFICATE = 0, + INDEX_OPT_DEBUG_LEVEL = 1, + INDEX_OPT_SET_DEBUG_LEVEL = 2, + INDEX_OPT_ID_KEY = 3, + INDEX_OPT_GQ_PARAMS = 4, + INDEX_OPT_HOST_KEY = 5, + INDEX_OPT_IFFKEY = 6, + INDEX_OPT_ISSUER_NAME = 7, + INDEX_OPT_MD5KEY = 8, + INDEX_OPT_MODULUS = 9, + INDEX_OPT_PVT_CERT = 10, + INDEX_OPT_PVT_PASSWD = 11, + INDEX_OPT_GET_PVT_PASSWD = 12, + INDEX_OPT_SIGN_KEY = 13, + INDEX_OPT_SUBJECT_NAME = 14, + INDEX_OPT_TRUSTED_CERT = 15, + INDEX_OPT_MV_PARAMS = 16, + INDEX_OPT_MV_KEYS = 17, + INDEX_OPT_VERSION = 18, + INDEX_OPT_HELP = 19, + INDEX_OPT_MORE_HELP = 20, + INDEX_OPT_SAVE_OPTS = 21, + INDEX_OPT_LOAD_OPTS = 22 } teOptIndex; -#define OPTION_CT 24 -#define NTP_KEYGEN_VERSION "4.2.4p8" -#define NTP_KEYGEN_FULL_VERSION "ntp-keygen (ntp) - Create a NTP host key - Ver. 4.2.4p8" +#define OPTION_CT 23 +#define NTP_KEYGEN_VERSION "4.2.6p2" +#define NTP_KEYGEN_FULL_VERSION "ntp-keygen (ntp) - Create a NTP host key - Ver. 4.2.6p2" /* * Interface defines for all options. Replace "n" with the UPPER_CASED @@ -127,10 +126,6 @@ # warning undefining GQ_PARAMS due to option name conflict # undef GQ_PARAMS # endif -# ifdef GQ_KEYS -# warning undefining GQ_KEYS due to option name conflict -# undef GQ_KEYS -# endif # ifdef HOST_KEY # warning undefining HOST_KEY due to option name conflict # undef HOST_KEY @@ -189,7 +184,6 @@ # undef SET_DEBUG_LEVEL # undef ID_KEY # undef GQ_PARAMS -# undef GQ_KEYS # undef HOST_KEY # undef IFFKEY # undef ISSUER_NAME @@ -205,71 +199,43 @@ # undef MV_KEYS #endif /* NO_OPTION_NAME_WARNINGS */ -/* +/* * * * * * + * * Interface defines for specific options. */ -#ifdef OPENSSL #define VALUE_OPT_CERTIFICATE 'c' -#endif /* OPENSSL */ -#ifdef DEBUG #define VALUE_OPT_DEBUG_LEVEL 'd' -#endif /* DEBUG */ -#ifdef DEBUG #define VALUE_OPT_SET_DEBUG_LEVEL 'D' -#endif /* DEBUG */ -#ifdef OPENSSL #define VALUE_OPT_ID_KEY 'e' -#endif /* OPENSSL */ -#ifdef OPENSSL #define VALUE_OPT_GQ_PARAMS 'G' -#endif /* OPENSSL */ -#ifdef OPENSSL -#define VALUE_OPT_GQ_KEYS 'g' -#endif /* OPENSSL */ -#ifdef OPENSSL #define VALUE_OPT_HOST_KEY 'H' -#endif /* OPENSSL */ -#ifdef OPENSSL #define VALUE_OPT_IFFKEY 'I' -#endif /* OPENSSL */ -#ifdef OPENSSL #define VALUE_OPT_ISSUER_NAME 'i' -#endif /* OPENSSL */ #define VALUE_OPT_MD5KEY 'M' -#ifdef OPENSSL #define VALUE_OPT_MODULUS 'm' +#ifdef OPENSSL + #define OPT_VALUE_MODULUS (DESC(MODULUS).optArg.argInt) #endif /* OPENSSL */ -#ifdef OPENSSL #define VALUE_OPT_PVT_CERT 'P' -#endif /* OPENSSL */ -#ifdef OPENSSL #define VALUE_OPT_PVT_PASSWD 'p' -#endif /* OPENSSL */ -#ifdef OPENSSL #define VALUE_OPT_GET_PVT_PASSWD 'q' -#endif /* OPENSSL */ -#ifdef OPENSSL #define VALUE_OPT_SIGN_KEY 'S' -#endif /* OPENSSL */ -#ifdef OPENSSL #define VALUE_OPT_SUBJECT_NAME 's' -#endif /* OPENSSL */ -#ifdef OPENSSL #define VALUE_OPT_TRUSTED_CERT 'T' -#endif /* OPENSSL */ -#ifdef OPENSSL #define VALUE_OPT_MV_PARAMS 'V' +#ifdef OPENSSL + #define OPT_VALUE_MV_PARAMS (DESC(MV_PARAMS).optArg.argInt) #endif /* OPENSSL */ -#ifdef OPENSSL #define VALUE_OPT_MV_KEYS 'v' +#ifdef OPENSSL + #define OPT_VALUE_MV_KEYS (DESC(MV_KEYS).optArg.argInt) #endif /* OPENSSL */ - -#define VALUE_OPT_VERSION 'v' #define VALUE_OPT_HELP '?' #define VALUE_OPT_MORE_HELP '!' +#define VALUE_OPT_VERSION INDEX_OPT_VERSION #define VALUE_OPT_SAVE_OPTS '>' #define VALUE_OPT_LOAD_OPTS '<' #define SET_OPT_SAVE_OPTS(a) STMTS( \ @@ -286,7 +252,7 @@ ntp_keygenOptions.pzCurOpt = NULL ) #define START_OPT RESTART_OPT(1) #define USAGE(c) (*ntp_keygenOptions.pUsageProc)( &ntp_keygenOptions, c ) -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/opthead.tpl near line 360 */ +/* extracted from /usr/local/gnu/share/autogen/opthead.tpl near line 409 */ /* * * * * * * @@ -298,18 +264,37 @@ extern tOptions ntp_keygenOptions; -#ifndef _ -# if ENABLE_NLS -# include - static inline char* aoGetsText( char const* pz ) { - if (pz == NULL) return NULL; - return (char*)gettext( pz ); - } -# define _(s) aoGetsText(s) -# else /* ENABLE_NLS */ -# define _(s) s -# endif /* ENABLE_NLS */ -#endif +#if defined(ENABLE_NLS) +# ifndef _ +# include + static inline char* aoGetsText( char const* pz ) { + if (pz == NULL) return NULL; + return (char*)gettext( pz ); + } +# define _(s) aoGetsText(s) +# endif /* _() */ + +# define OPT_NO_XLAT_CFG_NAMES STMTS(ntp_keygenOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT_CFG;) +# define OPT_NO_XLAT_OPT_NAMES STMTS(ntp_keygenOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG;) + +# define OPT_XLAT_CFG_NAMES STMTS(ntp_keygenOptions.fOptSet &= \ + ~(OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG);) +# define OPT_XLAT_OPT_NAMES STMTS(ntp_keygenOptions.fOptSet &= \ + ~OPTPROC_NXLAT_OPT;) + +#else /* ENABLE_NLS */ +# define OPT_NO_XLAT_CFG_NAMES +# define OPT_NO_XLAT_OPT_NAMES + +# define OPT_XLAT_CFG_NAMES +# define OPT_XLAT_OPT_NAMES + +# ifndef _ +# define _(_s) _s +# endif +#endif /* ENABLE_NLS */ #ifdef __cplusplus } diff -urN src/contrib/ntp/util/ntp-keygen-opts.texi src.ntp/contrib/ntp/util/ntp-keygen-opts.texi --- src/contrib/ntp/util/ntp-keygen-opts.texi 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/util/ntp-keygen-opts.texi 2010-07-09 04:25:49.000000000 +0200 @@ -6,7 +6,7 @@ # # EDIT THIS FILE WITH CAUTION (ntp-keygen-opts.texi) # -# It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:57 AM EST +# It has been AutoGen-ed July 9, 2010 at 02:25:49 AM by AutoGen 5.10 # From the definitions ntp-keygen-opts.def # and the template file aginfo.tpl @end ignore @@ -25,7 +25,6 @@ * ntp-keygen certificate:: certificate option (-c) * ntp-keygen debug-level:: debug-level option (-d) * ntp-keygen get-pvt-passwd:: get-pvt-passwd option (-q) -* ntp-keygen gq-keys:: gq-keys option (-g) * ntp-keygen gq-params:: gq-params option (-G) * ntp-keygen host-key:: host-key option (-H) * ntp-keygen id-key:: id-key option (-e) @@ -52,7 +51,7 @@ @exampleindent 0 @example Using OpenSSL version 90704f -ntp-keygen (ntp) - Create a NTP host key - Ver. 4.2.5p247-RC +ntp-keygen (ntp) - Create a NTP host key - Ver. 4.2.6p2 USAGE: ntp-keygen [ - [] | --[@{=| @}] ]... Flg Arg Option-Name Description -c Str certificate certificate scheme @@ -88,7 +87,7 @@ or by a single hyphen and the flag character. The following option preset mechanisms are supported: - - reading file /users/stenn/.ntprc + - reading file /deacon/users/stenn/.ntprc - reading file /deacon/backroom/snaps/ntp-stable/util/.ntprc - examining environment variables named NTP_KEYGEN_* @@ -111,7 +110,14 @@ must be compiled in by defining @code{OPENSSL} during the compilation. @end itemize -Just some descriptive text. +scheme is one of +RSA-MD2, RSA-MD5, RSA-SHA, RSA-SHA1, RSA-MDC2, RSA-RIPEMD160, +DSA-SHA, or DSA-SHA1. + +Select the certificate message digest/signature encryption scheme. +Note that RSA schemes must be used with a RSA sign key and DSA +schemes must be used with a DSA sign key. The default without +this option is RSA-MD5. @node ntp-keygen debug-level @subsection debug-level option (-d) @@ -123,8 +129,6 @@ @itemize @bullet @item may appear an unlimited number of times. -@item -must be compiled in by defining @code{DEBUG} during the compilation. @end itemize Increase the debugging message output level. @@ -139,8 +143,6 @@ @itemize @bullet @item may appear an unlimited number of times. -@item -must be compiled in by defining @code{DEBUG} during the compilation. @end itemize Set the output debugging level. Can be supplied multiple times, @@ -150,7 +152,7 @@ @subsection id-key option (-e) @cindex ntp-keygen-id-key -This is the ``write identity keys'' option. +This is the ``write iff or gq identity keys'' option. This option has some usage constraints. It: @itemize @bullet @@ -158,7 +160,8 @@ must be compiled in by defining @code{OPENSSL} during the compilation. @end itemize -Just some descriptive text. +Write the IFF or GQ client keys to the standard output. This is +intended for automatic key distribution by mail. @node ntp-keygen gq-params @subsection gq-params option (-G) @@ -172,21 +175,8 @@ must be compiled in by defining @code{OPENSSL} during the compilation. @end itemize -Just some descriptive text. - -@node ntp-keygen gq-keys -@subsection gq-keys option (-g) -@cindex ntp-keygen-gq-keys - -This is the ``update gq keys'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -must be compiled in by defining @code{OPENSSL} during the compilation. -@end itemize - -Just some descriptive text. +Generate parameters and keys for the GQ identification scheme, +obsoleting any that may exist. @node ntp-keygen host-key @subsection host-key option (-H) @@ -200,7 +190,7 @@ must be compiled in by defining @code{OPENSSL} during the compilation. @end itemize -Just some descriptive text. +Generate new host keys, obsoleting any that may exist. @node ntp-keygen iffkey @subsection iffkey option (-I) @@ -214,7 +204,8 @@ must be compiled in by defining @code{OPENSSL} during the compilation. @end itemize -Just some descriptive text. +Generate parameters for the IFF identification scheme, obsoleting +any that may exist. @node ntp-keygen issuer-name @subsection issuer-name option (-i) @@ -228,14 +219,15 @@ must be compiled in by defining @code{OPENSSL} during the compilation. @end itemize -Just some descriptive text. +Set the suject name to name. This is used as the subject field +in certificates and in the file name for host and sign keys. @node ntp-keygen md5key @subsection md5key option (-M) @cindex ntp-keygen-md5key This is the ``generate md5 keys'' option. -Just some descriptive text. +Generate MD5 keys, obsoleting any that may exist. @node ntp-keygen modulus @subsection modulus option (-m) @@ -249,7 +241,7 @@ must be compiled in by defining @code{OPENSSL} during the compilation. @end itemize -Just some descriptive text. +The number of bits in the prime modulus. The default is 512. @node ntp-keygen pvt-cert @subsection pvt-cert option (-P) @@ -263,7 +255,8 @@ must be compiled in by defining @code{OPENSSL} during the compilation. @end itemize -Just some descriptive text. +Generate a private certificate. By default, the program generates +public certificates. @node ntp-keygen pvt-passwd @subsection pvt-passwd option (-p) @@ -277,7 +270,8 @@ must be compiled in by defining @code{OPENSSL} during the compilation. @end itemize -Just some descriptive text. +Encrypt generated files containing private data with the specified +password and the DES-CBC algorithm. @node ntp-keygen get-pvt-passwd @subsection get-pvt-passwd option (-q) @@ -291,7 +285,7 @@ must be compiled in by defining @code{OPENSSL} during the compilation. @end itemize -Just some descriptive text. +Set the password for reading files to the specified password. @node ntp-keygen sign-key @subsection sign-key option (-S) @@ -305,7 +299,9 @@ must be compiled in by defining @code{OPENSSL} during the compilation. @end itemize -Just some descriptive text. +Generate a new sign key of the designated type, obsoleting any +that may exist. By default, the program uses the host key as the +sign key. @node ntp-keygen subject-name @subsection subject-name option (-s) @@ -319,7 +315,8 @@ must be compiled in by defining @code{OPENSSL} during the compilation. @end itemize -Just some descriptive text. +Set the issuer name to name. This is used for the issuer field +in certificates and in the file name for identity files. @node ntp-keygen trusted-cert @subsection trusted-cert option (-T) @@ -333,7 +330,8 @@ must be compiled in by defining @code{OPENSSL} during the compilation. @end itemize -Just some descriptive text. +Generate a trusted certificate. By default, the program generates +a non-trusted certificate. @node ntp-keygen mv-params @subsection mv-params option (-V) @@ -347,7 +345,8 @@ must be compiled in by defining @code{OPENSSL} during the compilation. @end itemize -Just some descriptive text. +Generate parameters and keys for the Mu-Varadharajan (MV) +identification scheme. @node ntp-keygen mv-keys @subsection mv-keys option (-v) @@ -361,4 +360,4 @@ must be compiled in by defining @code{OPENSSL} during the compilation. @end itemize -Just some descriptive text. +This option has no @samp{doc} documentation. diff -urN src/contrib/ntp/util/ntp-keygen.1 src.ntp/contrib/ntp/util/ntp-keygen.1 --- src/contrib/ntp/util/ntp-keygen.1 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/util/ntp-keygen.1 2010-07-09 04:25:49.000000000 +0200 @@ -1,7 +1,7 @@ -.TH NTP-KEYGEN 1 2009-12-08 "(ntp 4.2.4p8)" "Programmer's Manual" +.TH NTP-KEYGEN 1 2010-07-09 "(ntp 4.2.6p2)" "Programmer's Manual" .\" EDIT THIS FILE WITH CAUTION (ntp-keygen.1) .\" -.\" It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:57 AM EST +.\" It has been AutoGen-ed July 9, 2010 at 02:25:49 AM by AutoGen 5.10 .\" From the definitions ntp-keygen-opts.def .\" and the template file agman1.tpl .\" @@ -14,7 +14,7 @@ .PP All arguments must be options. .SH "DESCRIPTION" -This manual page documents, briefly, the \fBntp-keygen\fP command. +This manual page briefly documents the \fBntp-keygen\fP command. If there is no new host key, look for an existing one. If one is not found, create it. .SH OPTIONS @@ -22,7 +22,14 @@ .BR \-c " \fIscheme\fP, " \--certificate "=" \fIscheme\fP certificate scheme. .sp -Just some descriptive text. +scheme is one of +RSA-MD2, RSA-MD5, RSA-SHA, RSA-SHA1, RSA-MDC2, RSA-RIPEMD160, +DSA-SHA, or DSA-SHA1. + +Select the certificate message digest/signature encryption scheme. +Note that RSA schemes must be used with a RSA sign key and DSA +schemes must be used with a DSA sign key. The default without +this option is RSA-MD5. .TP .BR \-d ", " \--debug-level Increase output debug message level. @@ -38,39 +45,38 @@ but each overrides the previous value(s). .TP .BR \-e ", " \--id-key -Write identity keys. +Write IFF or GQ identity keys. .sp -Just some descriptive text. +Write the IFF or GQ client keys to the standard output. This is +intended for automatic key distribution by mail. .TP .BR \-G ", " \--gq-params Generate GQ parameters and keys. .sp -Just some descriptive text. -.TP -.BR \-g ", " \--gq-keys -update GQ keys. -.sp -Just some descriptive text. +Generate parameters and keys for the GQ identification scheme, +obsoleting any that may exist. .TP .BR \-H ", " \--host-key generate RSA host key. .sp -Just some descriptive text. +Generate new host keys, obsoleting any that may exist. .TP .BR \-I ", " \--iffkey generate IFF parameters. .sp -Just some descriptive text. +Generate parameters for the IFF identification scheme, obsoleting +any that may exist. .TP -.BR \-i ", " \--issuer-name +.BR \-i " \fIissuer-name\fP, " \--issuer-name "=" \fIissuer-name\fP set issuer name. .sp -Just some descriptive text. +Set the suject name to name. This is used as the subject field +in certificates and in the file name for host and sign keys. .TP .BR \-M ", " \--md5key generate MD5 keys. .sp -Just some descriptive text. +Generate MD5 keys, obsoleting any that may exist. .TP .BR \-m " \fImodulus\fP, " \--modulus "=" \fImodulus\fP modulus. @@ -83,52 +89,59 @@ .fi .in -4 .sp -Just some descriptive text. +The number of bits in the prime modulus. The default is 512. .TP .BR \-P ", " \--pvt-cert generate PC private certificate. .sp -Just some descriptive text. +Generate a private certificate. By default, the program generates +public certificates. .TP .BR \-p " \fIpasswd\fP, " \--pvt-passwd "=" \fIpasswd\fP output private password. .sp -Just some descriptive text. +Encrypt generated files containing private data with the specified +password and the DES-CBC algorithm. .TP .BR \-q " \fIpasswd\fP, " \--get-pvt-passwd "=" \fIpasswd\fP input private password. .sp -Just some descriptive text. +Set the password for reading files to the specified password. .TP .BR \-S " \fIsign\fP, " \--sign-key "=" \fIsign\fP generate sign key (RSA or DSA). .sp -Just some descriptive text. +Generate a new sign key of the designated type, obsoleting any +that may exist. By default, the program uses the host key as the +sign key. .TP .BR \-s " \fIhost\fP, " \--subject-name "=" \fIhost\fP set subject name. .sp -Just some descriptive text. +Set the issuer name to name. This is used for the issuer field +in certificates and in the file name for identity files. .TP .BR \-T ", " \--trusted-cert trusted certificate (TC scheme). .sp -Just some descriptive text. +Generate a trusted certificate. By default, the program generates +a non-trusted certificate. .TP .BR \-V " \fInum\fP, " \--mv-params "=" \fInum\fP generate MV parameters. This option takes an integer number as its argument. .sp -Just some descriptive text. +Generate parameters and keys for the Mu-Varadharajan (MV) +identification scheme. .TP .BR \-v " \fInum\fP, " \--mv-keys "=" \fInum\fP update MV keys. This option takes an integer number as its argument. .sp -Just some descriptive text. +This option has not been fully documented. .TP .BR \-? , " \--help" -Display usage information and exit. +Display extended usage information and exit. .TP .BR \-! , " \--more-help" Extended usage information passed thru pager. @@ -143,7 +156,7 @@ of earlier RC/INI files. \fI--no-load-opts\fP is handled early, out of order. .TP -.BR \-v " [{\fIv|c|n\fP}]," " \--version" "[=\fI{v|c|n}\fP]" +.BR \- " [{\fIv|c|n\fP}]," " \--version" "[=\fI{v|c|n}\fP]" Output version of program and exit. The default mode is `v', a simple version. The `c' mode will print copyright information and `n' will print the full copyright notice. @@ -154,7 +167,7 @@ .nf \fBNTP_KEYGEN_\fP or \fBNTP_KEYGEN\fP .fi -.aj +.ad The environmental presets take precedence (are processed later than) the configuration files. The \fIhomerc\fP files are "\fI$HOME\fP", and "\fI.\fP". diff -urN src/contrib/ntp/util/ntp-keygen.c src.ntp/contrib/ntp/util/ntp-keygen.c --- src/contrib/ntp/util/ntp-keygen.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/util/ntp-keygen.c 2010-07-09 04:17:43.000000000 +0200 @@ -1,70 +1,65 @@ /* - * Program to generate cryptographic keys for NTP clients and servers + * Program to generate cryptographic keys for ntp clients and servers * - * This program generates files "ntpkey__.", - * where is the file type, is the generating host and - * is the NTP seconds in decimal format. The NTP programs - * expect generic names such as "ntpkey__whimsy.udel.edu" with the - * association maintained by soft links. - * - * Files are prefixed with a header giving the name and date of creation + * This program generates password encrypted data files for use with the + * Autokey security protocol and Network Time Protocol Version 4. Files + * are prefixed with a header giving the name and date of creation * followed by a type-specific descriptive label and PEM-encoded data - * string compatible with programs of the OpenSSL library. - * - * Note that private keys can be password encrypted as per OpenSSL - * conventions. + * structure compatible with programs of the OpenSSL library. * - * The file types include + * All file names are like "ntpkey__.", where + * is the file type, the generating host name and + * the generation time in NTP seconds. The NTP programs + * expect generic names such as "ntpkey__whimsy.udel.edu" with the + * association maintained by soft links. Following is a list of file + * types; the first line is the file name and the second link name. * * ntpkey_MD5key_. * MD5 (128-bit) keys used to compute message digests in symmetric * key cryptography * - * ntpkey_RSAkey_. - * ntpkey_host_ (RSA) link + * ntpkey_RSAhost_. + * ntpkey_host_ * RSA private/public host key pair used for public key signatures - * and data encryption * - * ntpkey_DSAkey_. - * ntpkey_sign_ (RSA or DSA) link - * DSA private/public sign key pair used for public key signatures, - * but not data encryption - * - * ntpkey_IFFpar_. - * ntpkey_iff_ (IFF server/client) link - * ntpkey_iffkey_ (IFF client) link - * Schnorr (IFF) server/client identity parameters - * - * ntpkey_IFFkey_. - * Schnorr (IFF) client identity parameters - * - * ntpkey_GQpar_., - * ntpkey_gq_ (GQ) link - * Guillou-Quisquater (GQ) identity parameters - * - * ntpkey_MVpar_., - * Mu-Varadharajan (MV) server identity parameters - * - * ntpkey_MVkeyX_., - * ntpkey_mv_ (MV server) link - * ntpkey_mvkey_ (MV client) link - * Mu-Varadharajan (MV) client identity parameters + * ntpkey_RSAsign_. + * ntpkey_sign_ + * RSA private/public sign key pair used for public key signatures + * + * ntpkey_DSAsign_. + * ntpkey_sign_ + * DSA Private/public sign key pair used for public key signatures + * + * Available digest/signature schemes + * + * RSA: RSA-MD2, RSA-MD5, RSA-SHA, RSA-SHA1, RSA-MDC2, EVP-RIPEMD160 + * DSA: DSA-SHA, DSA-SHA1 * * ntpkey_XXXcert_. - * ntpkey_cert_ (RSA or DSA) link + * ntpkey_cert_ * X509v3 certificate using RSA or DSA public keys and signatures. * XXX is a code identifying the message digest and signature * encryption algorithm * - * Available digest/signature schemes + * Identity schemes. The key type par is used for the challenge; the key + * type key is used for the response. * - * RSA: RSA-MD2, RSA-MD5, RSA-SHA, RSA-SHA1, RSA-MDC2, EVP-RIPEMD160 - * DSA: DSA-SHA, DSA-SHA1 + * ntpkey_IFFkey_. + * ntpkey_iffkey_ + * Schnorr (IFF) identity parameters and keys + * + * ntpkey_GQkey_., + * ntpkey_gqkey_ + * Guillou-Quisquater (GQ) identity parameters and keys + * + * ntpkey_MVkeyX_., + * ntpkey_mvkey_ + * Mu-Varadharajan (MV) identity parameters and keys * * Note: Once in a while because of some statistical fluke this program * fails to generate and verify some cryptographic data, as indicated by * exit status -1. In this case simply run the program again. If the - * program does complete with return code 0, the data are correct as + * program does complete with exit code 0, the data are correct as * verified. * * These cryptographic routines are characterized by the prime modulus @@ -92,21 +87,14 @@ #include #include #include -#if HAVE_SYS_TYPES_H -# include -#endif +#include #include "ntp_types.h" #include "ntp_random.h" -#include "l_stdlib.h" +#include "ntp_stdlib.h" +#include "ntp_assert.h" #include "ntp-keygen-opts.h" -#ifdef SYS_WINNT -extern int ntp_getopt P((int, char **, const char *)); -#define getopt ntp_getopt -#define optarg ntp_optarg -#endif - #ifdef OPENSSL #include "openssl/bn.h" #include "openssl/evp.h" @@ -116,17 +104,21 @@ #include "openssl/x509v3.h" #include #endif /* OPENSSL */ +#include /* * Cryptodefines */ -#define MD5KEYS 16 /* number of MD5 keys generated */ -#define JAN_1970 ULONG_CONST(2208988800) /* NTP seconds */ +#define MD5KEYS 10 /* number of keys generated of each type */ +#define MD5SIZE 20 /* maximum key size */ +#define JAN_1970 2208988800UL /* NTP seconds */ #define YEAR ((long)60*60*24*365) /* one year in seconds */ #define MAXFILENAME 256 /* max file name length */ #define MAXHOSTNAME 256 /* max host name length */ #ifdef OPENSSL #define PLEN 512 /* default prime modulus size (bits) */ +#define ILEN 256 /* default identity modulus size (bits) */ +#define MVMAX 100 /* max MV parameters */ /* * Strings used in X509v3 extension fields @@ -140,35 +132,39 @@ /* * Prototypes */ -FILE *fheader P((const char *, const char *)); -void fslink P((const char *, const char *)); -int gen_md5 P((char *)); +FILE *fheader (const char *, const char *, const char *); +int gen_md5 (char *); #ifdef OPENSSL -EVP_PKEY *gen_rsa P((char *)); -EVP_PKEY *gen_dsa P((char *)); -EVP_PKEY *gen_iff P((char *)); -EVP_PKEY *gen_gqpar P((char *)); -EVP_PKEY *gen_gqkey P((char *, EVP_PKEY *)); -EVP_PKEY *gen_mv P((char *)); -int x509 P((EVP_PKEY *, const EVP_MD *, char *, char *)); -void cb P((int, int, void *)); -EVP_PKEY *genkey P((char *, char *)); -u_long asn2ntp P((ASN1_TIME *)); +EVP_PKEY *gen_rsa (char *); +EVP_PKEY *gen_dsa (char *); +EVP_PKEY *gen_iffkey (char *); +EVP_PKEY *gen_gqkey (char *); +EVP_PKEY *gen_mvkey (char *, EVP_PKEY **); +void gen_mvserv (char *, EVP_PKEY **); +int x509 (EVP_PKEY *, const EVP_MD *, char *, char *, + char *); +void cb (int, int, void *); +EVP_PKEY *genkey (char *, char *); +EVP_PKEY *readkey (char *, char *, u_int *, EVP_PKEY **); +void writekey (char *, char *, u_int *, EVP_PKEY **); +u_long asn2ntp (ASN1_TIME *); #endif /* OPENSSL */ /* * Program variables */ extern char *optarg; /* command line argument */ -int debug = 0; /* debug, not de bug */ -int rval; /* return status */ +char *progname; +volatile int debug = 0; /* debug, not de bug */ #ifdef OPENSSL u_int modulus = PLEN; /* prime modulus size (bits) */ +u_int modulus2 = ILEN; /* identity modulus size (bits) */ #endif -int nkeys = 0; /* MV keys */ +int nkeys; /* MV keys */ time_t epoch; /* Unix epoch (seconds) since 1970 */ -char *hostname; /* host name (subject name) */ -char *trustname; /* trusted host name (issuer name) */ +u_int fstamp; /* NTP filestamp */ +char *hostname = NULL; /* host name (subject name) */ +char *groupname = NULL; /* trusted host name (issuer name) */ char filename[MAXFILENAME + 1]; /* file name */ char *passwd1 = NULL; /* input private key password */ char *passwd2 = NULL; /* output private key password */ @@ -183,9 +179,11 @@ * Don't try to follow symbolic links */ int -readlink(char * link, char * file, int len) { +readlink(char *link, char *file, int len) +{ return (-1); } + /* * Don't try to create a symbolic link for now. * Just move the file to the name you need. @@ -194,7 +192,7 @@ symlink(char *filename, char *linkname) { DeleteFile(linkname); MoveFile(filename, linkname); - return 0; + return (0); } void InitWin32Sockets() { @@ -203,7 +201,7 @@ wVersionRequested = MAKEWORD(2,0); if (WSAStartup(wVersionRequested, &wsaData)) { - fprintf(stderr, "No useable winsock.dll"); + fprintf(stderr, "No useable winsock.dll\n"); exit(1); } } @@ -222,17 +220,18 @@ int md5key = 0; /* generate MD5 keys */ #ifdef OPENSSL X509 *cert = NULL; /* X509 certificate */ + X509_EXTENSION *ext; /* X509v3 extension */ EVP_PKEY *pkey_host = NULL; /* host key */ EVP_PKEY *pkey_sign = NULL; /* sign key */ - EVP_PKEY *pkey_iff = NULL; /* IFF parameters */ - EVP_PKEY *pkey_gq = NULL; /* GQ parameters */ - EVP_PKEY *pkey_mv = NULL; /* MV parameters */ + EVP_PKEY *pkey_iffkey = NULL; /* IFF sever keys */ + EVP_PKEY *pkey_gqkey = NULL; /* GQ server keys */ + EVP_PKEY *pkey_mvkey = NULL; /* MV trusted agen keys */ + EVP_PKEY *pkey_mvpar[MVMAX]; /* MV cleient keys */ int hostkey = 0; /* generate RSA keys */ - int iffkey = 0; /* generate IFF parameters */ - int gqpar = 0; /* generate GQ parameters */ - int gqkey = 0; /* update GQ keys */ - int mvpar = 0; /* generate MV parameters */ + int iffkey = 0; /* generate IFF keys */ + int gqkey = 0; /* generate GQ keys */ int mvkey = 0; /* update MV keys */ + int mvpar = 0; /* generate MV parameters */ char *sign = NULL; /* sign key */ EVP_PKEY *pkey = NULL; /* temp key */ const EVP_MD *ectx; /* EVP digest */ @@ -242,33 +241,24 @@ char *grpkey = NULL; /* identity extension */ int nid; /* X509 digest/signature scheme */ FILE *fstr = NULL; /* file handle */ - u_int temp; #define iffsw HAVE_OPT(ID_KEY) #endif /* OPENSSL */ char hostbuf[MAXHOSTNAME + 1]; + char groupbuf[MAXHOSTNAME + 1]; + + progname = argv[0]; #ifdef SYS_WINNT /* Initialize before OpenSSL checks */ InitWin32Sockets(); - if(!init_randfile()) + if (!init_randfile()) fprintf(stderr, "Unable to initialize .rnd file\n"); + ssl_applink(); #endif #ifdef OPENSSL - /* - * OpenSSL version numbers: MNNFFPPS: major minor fix patch status - * We match major, minor, fix and status (not patch) - */ - if ((SSLeay() ^ OPENSSL_VERSION_NUMBER) & ~0xff0L) { - fprintf(stderr, - "OpenSSL version mismatch. Built against %lx, you have %lx\n", - OPENSSL_VERSION_NUMBER, SSLeay()); - return (-1); - - } else { - fprintf(stderr, - "Using OpenSSL version %lx\n", SSLeay()); - } + ssl_check_version(); + fprintf(stderr, "Using OpenSSL version %lx\n", SSLeay()); #endif /* OPENSSL */ /* @@ -276,393 +266,574 @@ */ gethostname(hostbuf, MAXHOSTNAME); hostname = hostbuf; -#ifdef OPENSSL - trustname = hostbuf; - passwd1 = hostbuf; -#endif -#ifndef SYS_WINNT gettimeofday(&tv, 0); -#else - gettimeofday(&tv); -#endif + epoch = tv.tv_sec; - rval = 0; { int optct = optionProcess(&ntp_keygenOptions, argc, argv); argc -= optct; argv += optct; } - -#ifdef OPENSSL - if (HAVE_OPT( CERTIFICATE )) - scheme = OPT_ARG( CERTIFICATE ); -#endif - debug = DESC(DEBUG_LEVEL).optOccCt; - -#ifdef OPENSSL - if (HAVE_OPT( GQ_PARAMS )) - gqpar++; - - if (HAVE_OPT( GQ_KEYS )) - gqkey++; - - if (HAVE_OPT( HOST_KEY )) - hostkey++; - - if (HAVE_OPT( IFFKEY )) - iffkey++; - - if (HAVE_OPT( ISSUER_NAME )) - trustname = OPT_ARG( ISSUER_NAME ); -#endif - if (HAVE_OPT( MD5KEY )) - md5key++; + md5key++; #ifdef OPENSSL - if (HAVE_OPT( MODULUS )) - modulus = OPT_VALUE_MODULUS; - - if (HAVE_OPT( PVT_CERT )) - exten = EXT_KEY_PRIVATE; - + passwd1 = hostbuf; if (HAVE_OPT( PVT_PASSWD )) - passwd2 = OPT_ARG( PVT_PASSWD ); + passwd1 = strdup(OPT_ARG( PVT_PASSWD )); if (HAVE_OPT( GET_PVT_PASSWD )) - passwd1 = OPT_ARG( GET_PVT_PASSWD ); + passwd2 = strdup(OPT_ARG( GET_PVT_PASSWD )); + + if (HAVE_OPT( HOST_KEY )) + hostkey++; if (HAVE_OPT( SIGN_KEY )) - sign = OPT_ARG( SIGN_KEY ); + sign = strdup(OPT_ARG( SIGN_KEY )); - if (HAVE_OPT( SUBJECT_NAME )) - hostname = OPT_ARG( SUBJECT_NAME ); + if (HAVE_OPT( GQ_PARAMS )) + gqkey++; - if (HAVE_OPT( TRUSTED_CERT )) - exten = EXT_KEY_TRUST; + if (HAVE_OPT( IFFKEY )) + iffkey++; if (HAVE_OPT( MV_PARAMS )) { - mvpar++; + mvkey++; nkeys = OPT_VALUE_MV_PARAMS; } - if (HAVE_OPT( MV_KEYS )) { - mvkey++; + mvpar++; nkeys = OPT_VALUE_MV_KEYS; } -#endif + if (HAVE_OPT( MODULUS )) + modulus = OPT_VALUE_MODULUS; + + if (HAVE_OPT( CERTIFICATE )) + scheme = OPT_ARG( CERTIFICATE ); + + if (HAVE_OPT( SUBJECT_NAME )) + hostname = strdup(OPT_ARG( SUBJECT_NAME )); + + if (HAVE_OPT( ISSUER_NAME )) + groupname = strdup(OPT_ARG( ISSUER_NAME )); + + if (HAVE_OPT( PVT_CERT )) + exten = EXT_KEY_PRIVATE; + + if (HAVE_OPT( TRUSTED_CERT )) + exten = EXT_KEY_TRUST; - if (passwd1 != NULL && passwd2 == NULL) - passwd2 = passwd1; -#ifdef OPENSSL /* * Seed random number generator and grow weeds. */ ERR_load_crypto_strings(); OpenSSL_add_all_algorithms(); - if (RAND_file_name(pathbuf, MAXFILENAME) == NULL) { - fprintf(stderr, "RAND_file_name %s\n", - ERR_error_string(ERR_get_error(), NULL)); - return (-1); - } - temp = RAND_load_file(pathbuf, -1); - if (temp == 0) { + if (!RAND_status()) { + u_int temp; + + if (RAND_file_name(pathbuf, MAXFILENAME) == NULL) { + fprintf(stderr, "RAND_file_name %s\n", + ERR_error_string(ERR_get_error(), NULL)); + exit (-1); + } + temp = RAND_load_file(pathbuf, -1); + if (temp == 0) { + fprintf(stderr, + "RAND_load_file %s not found or empty\n", + pathbuf); + exit (-1); + } fprintf(stderr, - "RAND_load_file %s not found or empty\n", pathbuf); - return (-1); + "Random seed file %s %u bytes\n", pathbuf, temp); + RAND_add(&epoch, sizeof(epoch), 4.0); } - fprintf(stderr, - "Random seed file %s %u bytes\n", pathbuf, temp); - RAND_add(&epoch, sizeof(epoch), 4.0); -#endif /* - * Generate new parameters and keys as requested. These replace - * any values already generated. + * Load previous certificate if available. */ - if (md5key) - gen_md5("MD5"); -#ifdef OPENSSL - if (hostkey) - pkey_host = genkey("RSA", "host"); - if (sign != NULL) - pkey_sign = genkey(sign, "sign"); - if (iffkey) - pkey_iff = gen_iff("iff"); - if (gqpar) - pkey_gq = gen_gqpar("gq"); - if (mvpar) - pkey_mv = gen_mv("mv"); + sprintf(filename, "ntpkey_cert_%s", hostname); + if ((fstr = fopen(filename, "r")) != NULL) { + cert = PEM_read_X509(fstr, NULL, NULL, NULL); + fclose(fstr); + } + if (cert != NULL) { - /* - * If there is no new host key, look for an existing one. If not - * found, create it. - */ - while (pkey_host == NULL && rval == 0 && !HAVE_OPT(ID_KEY)) { - sprintf(filename, "ntpkey_host_%s", hostname); - if ((fstr = fopen(filename, "r")) != NULL) { - pkey_host = PEM_read_PrivateKey(fstr, NULL, - NULL, passwd1); - fclose(fstr); - readlink(filename, filename, sizeof(filename)); - if (pkey_host == NULL) { - fprintf(stderr, "Host key\n%s\n", - ERR_error_string(ERR_get_error(), - NULL)); - rval = -1; - } else { - fprintf(stderr, - "Using host key %s\n", filename); - } - break; + /* + * Extract subject name. + */ + X509_NAME_oneline(X509_get_subject_name(cert), groupbuf, + MAXFILENAME); - } else if ((pkey_host = genkey("RSA", "host")) == - NULL) { - rval = -1; - break; + /* + * Extract digest/signature scheme. + */ + if (scheme == NULL) { + nid = OBJ_obj2nid(cert->cert_info-> + signature->algorithm); + scheme = OBJ_nid2sn(nid); + } + + /* + * If a key_usage extension field is present, determine + * whether this is a trusted or private certificate. + */ + if (exten == NULL) { + BIO *bp; + int i, cnt; + char *ptr; + + ptr = strstr(groupbuf, "CN="); + cnt = X509_get_ext_count(cert); + for (i = 0; i < cnt; i++) { + ext = X509_get_ext(cert, i); + if (OBJ_obj2nid(ext->object) == + NID_ext_key_usage) { + bp = BIO_new(BIO_s_mem()); + X509V3_EXT_print(bp, ext, 0, 0); + BIO_gets(bp, pathbuf, + MAXFILENAME); + BIO_free(bp); + if (strcmp(pathbuf, + "Trust Root") == 0) + exten = EXT_KEY_TRUST; + else if (strcmp(pathbuf, + "Private") == 0) + exten = EXT_KEY_PRIVATE; + if (groupname == NULL) + groupname = ptr + 3; + } + } } } + if (scheme == NULL) + scheme = "RSA-MD5"; + if (groupname == NULL) + groupname = hostname; + fprintf(stderr, "Using host %s group %s\n", hostname, + groupname); + if ((iffkey || gqkey || mvkey) && exten == NULL) + fprintf(stderr, + "Warning: identity files may not be useful with a nontrusted certificate.\n"); +#endif /* OPENSSL */ /* - * If there is no new sign key, look for an existing one. If not - * found, use the host key instead. + * Create new unencrypted MD5 keys file if requested. If this + * option is selected, ignore all other options. */ - pkey = pkey_sign; - while (pkey_sign == NULL && rval == 0 && !HAVE_OPT(ID_KEY)) { - sprintf(filename, "ntpkey_sign_%s", hostname); - if ((fstr = fopen(filename, "r")) != NULL) { - pkey_sign = PEM_read_PrivateKey(fstr, NULL, - NULL, passwd1); - fclose(fstr); + if (md5key) { + gen_md5("md5"); + exit (0); + } + +#ifdef OPENSSL + /* + * Create a new encrypted RSA host key file if requested; + * otherwise, look for an existing host key file. If not found, + * create a new encrypted RSA host key file. If that fails, go + * no further. + */ + if (hostkey) + pkey_host = genkey("RSA", "host"); + if (pkey_host == NULL) { + sprintf(filename, "ntpkey_host_%s", hostname); + pkey_host = readkey(filename, passwd1, &fstamp, NULL); + if (pkey_host != NULL) { readlink(filename, filename, sizeof(filename)); - if (pkey_sign == NULL) { - fprintf(stderr, "Sign key\n%s\n", - ERR_error_string(ERR_get_error(), - NULL)); - rval = -1; - } else { - fprintf(stderr, "Using sign key %s\n", - filename); - } - break; + fprintf(stderr, "Using host key %s\n", + filename); } else { - pkey = pkey_host; - fprintf(stderr, "Using host key as sign key\n"); - break; + pkey_host = genkey("RSA", "host"); } } + if (pkey_host == NULL) { + fprintf(stderr, "Generating host key fails\n"); + exit (-1); + } /* - * If there is no new IFF file, look for an existing one. + * Create new encrypted RSA or DSA sign keys file if requested; + * otherwise, look for an existing sign key file. If not found, + * use the host key instead. */ - if (pkey_iff == NULL && rval == 0) { - sprintf(filename, "ntpkey_iff_%s", hostname); - if ((fstr = fopen(filename, "r")) != NULL) { - pkey_iff = PEM_read_PrivateKey(fstr, NULL, - NULL, passwd1); - fclose(fstr); + if (sign != NULL) + pkey_sign = genkey(sign, "sign"); + if (pkey_sign == NULL) { + sprintf(filename, "ntpkey_sign_%s", hostname); + pkey_sign = readkey(filename, passwd1, &fstamp, NULL); + if (pkey_sign != NULL) { readlink(filename, filename, sizeof(filename)); - if (pkey_iff == NULL) { - fprintf(stderr, "IFF parameters\n%s\n", - ERR_error_string(ERR_get_error(), - NULL)); - rval = -1; - } else { - fprintf(stderr, - "Using IFF parameters %s\n", - filename); - } + fprintf(stderr, "Using sign key %s\n", + filename); + } else if (pkey_host != NULL) { + pkey_sign = pkey_host; + fprintf(stderr, "Using host key as sign key\n"); } } /* - * If there is no new GQ file, look for an existing one. - */ - if (pkey_gq == NULL && rval == 0 && !HAVE_OPT(ID_KEY)) { - sprintf(filename, "ntpkey_gq_%s", hostname); - if ((fstr = fopen(filename, "r")) != NULL) { - pkey_gq = PEM_read_PrivateKey(fstr, NULL, NULL, - passwd1); - fclose(fstr); + * Create new encrypted GQ server keys file if requested; + * otherwise, look for an exisiting file. If found, fetch the + * public key for the certificate. + */ + if (gqkey) + pkey_gqkey = gen_gqkey("gqkey"); + if (pkey_gqkey == NULL) { + sprintf(filename, "ntpkey_gqkey_%s", groupname); + pkey_gqkey = readkey(filename, passwd1, &fstamp, NULL); + if (pkey_gqkey != NULL) { readlink(filename, filename, sizeof(filename)); - if (pkey_gq == NULL) { - fprintf(stderr, "GQ parameters\n%s\n", - ERR_error_string(ERR_get_error(), - NULL)); - rval = -1; - } else { - fprintf(stderr, - "Using GQ parameters %s\n", - filename); - } + fprintf(stderr, "Using GQ parameters %s\n", + filename); } } + if (pkey_gqkey != NULL) + grpkey = BN_bn2hex(pkey_gqkey->pkey.rsa->q); + + /* + * Write the nonencrypted GQ client parameters to the stdout + * stream. The parameter file is the server key file with the + * private key obscured. + */ + if (pkey_gqkey != NULL && HAVE_OPT(ID_KEY)) { + RSA *rsa; + + epoch = fstamp - JAN_1970; + sprintf(filename, "ntpkey_gqpar_%s.%u", groupname, + fstamp); + fprintf(stderr, "Writing GQ parameters %s to stdout\n", + filename); + fprintf(stdout, "# %s\n# %s\n", filename, + ctime(&epoch)); + rsa = pkey_gqkey->pkey.rsa; + BN_copy(rsa->p, BN_value_one()); + BN_copy(rsa->q, BN_value_one()); + pkey = EVP_PKEY_new(); + EVP_PKEY_assign_RSA(pkey, rsa); + PEM_write_PrivateKey(stdout, pkey, NULL, NULL, 0, NULL, + NULL); + fclose(stdout); + if (debug) + RSA_print_fp(stderr, rsa, 0); + } /* - * If there is a GQ parameter file, create GQ private/public - * keys and extract the public key for the certificate. + * Write the encrypted GQ server keys to the stdout stream. */ - if (pkey_gq != NULL && rval == 0) { - gen_gqkey("gq", pkey_gq); - grpkey = BN_bn2hex(pkey_gq->pkey.rsa->q); + if (pkey_gqkey != NULL && passwd2 != NULL) { + RSA *rsa; + + sprintf(filename, "ntpkey_gqkey_%s.%u", groupname, + fstamp); + fprintf(stderr, "Writing GQ keys %s to stdout\n", + filename); + fprintf(stdout, "# %s\n# %s\n", filename, + ctime(&epoch)); + rsa = pkey_gqkey->pkey.rsa; + pkey = EVP_PKEY_new(); + EVP_PKEY_assign_RSA(pkey, rsa); + PEM_write_PrivateKey(stdout, pkey, + EVP_des_cbc(), NULL, 0, NULL, passwd2); + fclose(stdout); + if (debug) + RSA_print_fp(stderr, rsa, 0); } /* - * Generate a X509v3 certificate. + * Create new encrypted IFF server keys file if requested; + * otherwise, look for existing file. */ - while (scheme == NULL && rval == 0 && !HAVE_OPT(ID_KEY)) { - sprintf(filename, "ntpkey_cert_%s", hostname); - if ((fstr = fopen(filename, "r")) != NULL) { - cert = PEM_read_X509(fstr, NULL, NULL, NULL); - fclose(fstr); + if (iffkey) + pkey_iffkey = gen_iffkey("iffkey"); + if (pkey_iffkey == NULL) { + sprintf(filename, "ntpkey_iffkey_%s", groupname); + pkey_iffkey = readkey(filename, passwd1, &fstamp, NULL); + if (pkey_iffkey != NULL) { readlink(filename, filename, sizeof(filename)); - if (cert == NULL) { - fprintf(stderr, "Cert \n%s\n", - ERR_error_string(ERR_get_error(), - NULL)); - rval = -1; - } else { - nid = OBJ_obj2nid( - cert->cert_info->signature->algorithm); - scheme = OBJ_nid2sn(nid); - fprintf(stderr, - "Using scheme %s from %s\n", scheme, - filename); - break; - } - } - scheme = "RSA-MD5"; - } - if (pkey != NULL && rval == 0 && !HAVE_OPT(ID_KEY)) { - ectx = EVP_get_digestbyname(scheme); - if (ectx == NULL) { - fprintf(stderr, - "Invalid digest/signature combination %s\n", - scheme); - rval = -1; - } else { - x509(pkey, ectx, grpkey, exten); + fprintf(stderr, "Using IFF keys %s\n", + filename); } } /* - * Write the IFF client parameters and keys as a DSA private key - * encoded in PEM. Note the private key is obscured. + * Write the nonencrypted IFF client parameters to the stdout + * stream. The parameter file is the server key file with the + * private key obscured. */ - if (pkey_iff != NULL && rval == 0 && HAVE_OPT(ID_KEY)) { + if (pkey_iffkey != NULL && HAVE_OPT(ID_KEY)) { DSA *dsa; - char *sptr; - char *tld; - sptr = strrchr(filename, '.'); - tld = malloc(strlen(sptr)); /* we have an extra byte ... */ - strcpy(tld, 1+sptr); /* ... see? */ - sprintf(filename, "ntpkey_IFFkey_%s.%s", trustname, - tld); - free(tld); - fprintf(stderr, "Writing new IFF key %s\n", filename); - fprintf(stdout, "# %s\n# %s", filename, ctime(&epoch)); - dsa = pkey_iff->pkey.dsa; + epoch = fstamp - JAN_1970; + sprintf(filename, "ntpkey_iffpar_%s.%u", groupname, + fstamp); + fprintf(stderr, "Writing IFF parameters %s to stdout\n", + filename); + fprintf(stdout, "# %s\n# %s\n", filename, + ctime(&epoch)); + dsa = pkey_iffkey->pkey.dsa; BN_copy(dsa->priv_key, BN_value_one()); pkey = EVP_PKEY_new(); EVP_PKEY_assign_DSA(pkey, dsa); - PEM_write_PrivateKey(stdout, pkey, passwd2 ? - EVP_des_cbc() : NULL, NULL, 0, NULL, passwd2); + PEM_write_PrivateKey(stdout, pkey, NULL, NULL, 0, NULL, + NULL); fclose(stdout); if (debug) - DSA_print_fp(stdout, dsa, 0); + DSA_print_fp(stderr, dsa, 0); } /* - * Return the marbles. + * Write the encrypted IFF server keys to the stdout stream. */ - if (grpkey != NULL) - OPENSSL_free(grpkey); - if (pkey_host != NULL) - EVP_PKEY_free(pkey_host); - if (pkey_sign != NULL) - EVP_PKEY_free(pkey_sign); - if (pkey_iff != NULL) - EVP_PKEY_free(pkey_iff); - if (pkey_gq != NULL) - EVP_PKEY_free(pkey_gq); - if (pkey_mv != NULL) - EVP_PKEY_free(pkey_mv); -#endif /* OPENSSL */ - return (rval); -} + if (pkey_iffkey != NULL && passwd2 != NULL) { + DSA *dsa; + epoch = fstamp - JAN_1970; + sprintf(filename, "ntpkey_iffkey_%s.%u", groupname, + fstamp); + fprintf(stderr, "Writing IFF keys %s to stdout\n", + filename); + fprintf(stdout, "# %s\n# %s\n", filename, + ctime(&epoch)); + dsa = pkey_iffkey->pkey.dsa; + pkey = EVP_PKEY_new(); + EVP_PKEY_assign_DSA(pkey, dsa); + PEM_write_PrivateKey(stdout, pkey, EVP_des_cbc(), NULL, + 0, NULL, passwd2); + fclose(stdout); + if (debug) + DSA_print_fp(stderr, dsa, 0); + } -#if 0 -/* - * Generate random MD5 key with password. - */ -int -gen_md5( - char *id /* file name id */ - ) -{ - BIGNUM *key; - BIGNUM *keyid; - FILE *str; - u_char bin[16]; + /* + * Create new encrypted MV trusted-authority keys file if + * requested; otherwise, look for existing keys file. + */ + if (mvkey) + pkey_mvkey = gen_mvkey("mv", pkey_mvpar); + if (pkey_mvkey == NULL) { + sprintf(filename, "ntpkey_mvta_%s", groupname); + pkey_mvkey = readkey(filename, passwd1, &fstamp, + pkey_mvpar); + if (pkey_mvkey != NULL) { + readlink(filename, filename, sizeof(filename)); + fprintf(stderr, "Using MV keys %s\n", + filename); + } + } - fprintf(stderr, "Generating MD5 keys...\n"); - str = fheader("MD5key", hostname); - keyid = BN_new(); key = BN_new(); - BN_rand(keyid, 16, -1, 0); - BN_rand(key, 128, -1, 0); - BN_bn2bin(key, bin); - PEM_write_fp(str, MD5, NULL, bin); - fclose(str); - fslink(id, hostname); - return (1); + /* + * Write the nonencrypted MV client parameters to the stdout + * stream. For the moment, we always use the client parameters + * associated with client key 1. + */ + if (pkey_mvkey != NULL && HAVE_OPT(ID_KEY)) { + epoch = fstamp - JAN_1970; + sprintf(filename, "ntpkey_mvpar_%s.%u", groupname, + fstamp); + fprintf(stderr, "Writing MV parameters %s to stdout\n", + filename); + fprintf(stdout, "# %s\n# %s\n", filename, + ctime(&epoch)); + pkey = pkey_mvpar[2]; + PEM_write_PrivateKey(stdout, pkey, NULL, NULL, 0, NULL, + NULL); + fclose(stdout); + if (debug) + DSA_print_fp(stderr, pkey->pkey.dsa, 0); + } + + /* + * Write the encrypted MV server keys to the stdout stream. + */ + if (pkey_mvkey != NULL && passwd2 != NULL) { + epoch = fstamp - JAN_1970; + sprintf(filename, "ntpkey_mvkey_%s.%u", groupname, + fstamp); + fprintf(stderr, "Writing MV keys %s to stdout\n", + filename); + fprintf(stdout, "# %s\n# %s\n", filename, + ctime(&epoch)); + pkey = pkey_mvpar[1]; + PEM_write_PrivateKey(stdout, pkey, EVP_des_cbc(), NULL, + 0, NULL, passwd2); + fclose(stdout); + if (debug) + DSA_print_fp(stderr, pkey->pkey.dsa, 0); + } + + /* + * Don't generate a certificate if no host keys or extracting + * encrypted or nonencrypted keys to the standard output stream. + */ + if (pkey_host == NULL || HAVE_OPT(ID_KEY) || passwd2 != NULL) + exit (0); + + /* + * Decode the digest/signature scheme. If trusted, set the + * subject and issuer names to the group name; if not set both + * to the host name. + */ + ectx = EVP_get_digestbyname(scheme); + if (ectx == NULL) { + fprintf(stderr, + "Invalid digest/signature combination %s\n", + scheme); + exit (-1); + } + if (exten == NULL) + x509(pkey_sign, ectx, grpkey, exten, hostname); + else + x509(pkey_sign, ectx, grpkey, exten, groupname); +#endif /* OPENSSL */ + exit (0); } -#else /* - * Generate semi-random MD5 keys compatible with NTPv3 and NTPv4 + * Generate semi-random MD5 keys compatible with NTPv3 and NTPv4. Also, + * if OpenSSL is around, generate random SHA1 keys compatible with + * symmetric key cryptography. */ int gen_md5( char *id /* file name id */ ) { - u_char md5key[16]; /* MD5 key */ + u_char md5key[MD5SIZE + 1]; /* MD5 key */ FILE *str; - u_int temp = 0; /* Initialize to prevent warnings during compile */ int i, j; +#ifdef OPENSSL + u_char keystr[MD5SIZE]; + u_char hexstr[2 * MD5SIZE + 1]; + u_char hex[] = "0123456789abcdef"; +#endif /* OPENSSL */ - fprintf(stderr, "Generating MD5 keys...\n"); - str = fheader("MD5key", hostname); - ntp_srandom(epoch); + str = fheader("MD5key", id, groupname); + ntp_srandom((u_long)epoch); for (i = 1; i <= MD5KEYS; i++) { - for (j = 0; j < 16; j++) { + for (j = 0; j < MD5SIZE; j++) { + int temp; + while (1) { temp = ntp_random() & 0xff; if (temp == '#') continue; + if (temp > 0x20 && temp < 0x7f) break; } md5key[j] = (u_char)temp; } - md5key[15] = '\0'; - fprintf(str, "%2d MD5 %16s # MD5 key\n", i, + md5key[j] = '\0'; + fprintf(str, "%2d MD5 %s # MD5 key\n", i, md5key); } +#ifdef OPENSSL + for (i = 1; i <= MD5KEYS; i++) { + RAND_bytes(keystr, 20); + for (j = 0; j < MD5SIZE; j++) { + hexstr[2 * j] = hex[keystr[j] >> 4]; + hexstr[2 * j + 1] = hex[keystr[j] & 0xf]; + } + hexstr[2 * MD5SIZE] = '\0'; + fprintf(str, "%2d SHA1 %s # SHA1 key\n", i + MD5KEYS, + hexstr); + } +#endif /* OPENSSL */ fclose(str); - fslink(id, hostname); return (1); } -#endif /* OPENSSL */ #ifdef OPENSSL /* + * readkey - load cryptographic parameters and keys + * + * This routine loads a PEM-encoded file of given name and password and + * extracts the filestamp from the file name. It returns a pointer to + * the first key if valid, NULL if not. + */ +EVP_PKEY * /* public/private key pair */ +readkey( + char *cp, /* file name */ + char *passwd, /* password */ + u_int *estamp, /* file stamp */ + EVP_PKEY **evpars /* parameter list pointer */ + ) +{ + FILE *str; /* file handle */ + EVP_PKEY *pkey = NULL; /* public/private key */ + u_int gstamp; /* filestamp */ + char linkname[MAXFILENAME]; /* filestamp buffer) */ + EVP_PKEY *parkey; + char *ptr; + int i; + + /* + * Open the key file. + */ + str = fopen(cp, "r"); + if (str == NULL) + return (NULL); + + /* + * Read the filestamp, which is contained in the first line. + */ + if ((ptr = fgets(linkname, MAXFILENAME, str)) == NULL) { + fprintf(stderr, "Empty key file %s\n", cp); + fclose(str); + return (NULL); + } + if ((ptr = strrchr(ptr, '.')) == NULL) { + fprintf(stderr, "No filestamp found in %s\n", cp); + fclose(str); + return (NULL); + } + if (sscanf(++ptr, "%u", &gstamp) != 1) { + fprintf(stderr, "Invalid filestamp found in %s\n", cp); + fclose(str); + return (NULL); + } + + /* + * Read and decrypt PEM-encoded private keys. The first one + * found is returned. If others are expected, add them to the + * parameter list. + */ + for (i = 0; i <= MVMAX - 1;) { + parkey = PEM_read_PrivateKey(str, NULL, NULL, passwd); + if (evpars != NULL) { + evpars[i++] = parkey; + evpars[i] = NULL; + } + if (parkey == NULL) + break; + + if (pkey == NULL) + pkey = parkey; + if (debug) { + if (parkey->type == EVP_PKEY_DSA) + DSA_print_fp(stderr, parkey->pkey.dsa, + 0); + else if (parkey->type == EVP_PKEY_RSA) + RSA_print_fp(stderr, parkey->pkey.rsa, + 0); + } + } + fclose(str); + if (pkey == NULL) { + fprintf(stderr, "Corrupt file %s or wrong key %s\n%s\n", + cp, passwd, ERR_error_string(ERR_get_error(), + NULL)); + exit (-1); + } + *estamp = gstamp; + return (pkey); +} + + +/* * Generate RSA public/private key pair */ EVP_PKEY * /* public/private key pair */ @@ -680,7 +851,6 @@ if (rsa == NULL) { fprintf(stderr, "RSA generate keys fails\n%s\n", ERR_error_string(ERR_get_error(), NULL)); - rval = -1; return (NULL); } @@ -694,7 +864,6 @@ fprintf(stderr, "Invalid RSA key\n%s\n", ERR_error_string(ERR_get_error(), NULL)); RSA_free(rsa); - rval = -1; return (NULL); } @@ -702,15 +871,17 @@ * Write the RSA parameters and keys as a RSA private key * encoded in PEM. */ - str = fheader("RSAkey", hostname); + if (strcmp(id, "sign") == 0) + str = fheader("RSAsign", id, hostname); + else + str = fheader("RSAhost", id, hostname); pkey = EVP_PKEY_new(); EVP_PKEY_assign_RSA(pkey, rsa); - PEM_write_PrivateKey(str, pkey, passwd2 ? EVP_des_cbc() : NULL, - NULL, 0, NULL, passwd2); + PEM_write_PrivateKey(str, pkey, EVP_des_cbc(), NULL, 0, NULL, + passwd1); fclose(str); if (debug) - RSA_print_fp(stdout, rsa, 0); - fslink(id, hostname); + RSA_print_fp(stderr, rsa, 0); return (pkey); } @@ -740,7 +911,6 @@ if (dsa == NULL) { fprintf(stderr, "DSA generate parameters fails\n%s\n", ERR_error_string(ERR_get_error(), NULL)); - rval = -1; return (NULL); } @@ -752,7 +922,6 @@ fprintf(stderr, "DSA generate keys fails\n%s\n", ERR_error_string(ERR_get_error(), NULL)); DSA_free(dsa); - rval = -1; return (NULL); } @@ -760,45 +929,70 @@ * Write the DSA parameters and keys as a DSA private key * encoded in PEM. */ - str = fheader("DSAkey", hostname); + str = fheader("DSAsign", id, hostname); pkey = EVP_PKEY_new(); EVP_PKEY_assign_DSA(pkey, dsa); - PEM_write_PrivateKey(str, pkey, passwd2 ? EVP_des_cbc() : NULL, - NULL, 0, NULL, passwd2); + PEM_write_PrivateKey(str, pkey, EVP_des_cbc(), NULL, 0, NULL, + passwd1); fclose(str); if (debug) - DSA_print_fp(stdout, dsa, 0); - fslink(id, hostname); + DSA_print_fp(stderr, dsa, 0); return (pkey); } /* - * Generate Schnorr (IFF) parameters and keys + *********************************************************************** + * * + * The following routines implement the Schnorr (IFF) identity scheme * + * * + *********************************************************************** * - * The Schnorr (IFF)identity scheme is intended for use when + * The Schnorr (IFF) identity scheme is intended for use when * certificates are generated by some other trusted certificate - * authority and the parameters cannot be conveyed in the certificate - * itself. For this purpose, new generations of IFF values must be - * securely transmitted to all members of the group before use. There - * are two kinds of files: server/client files that include private and - * public parameters and client files that include only public - * parameters. The scheme is self contained and independent of new - * generations of host keys, sign keys and certificates. + * authority and the certificate cannot be used to convey public + * parameters. There are two kinds of files: encrypted server files that + * contain private and public values and nonencrypted client files that + * contain only public values. New generations of server files must be + * securely transmitted to all servers of the group; client files can be + * distributed by any means. The scheme is self contained and + * independent of new generations of host keys, sign keys and + * certificates. * * The IFF values hide in a DSA cuckoo structure which uses the same * parameters. The values are used by an identity scheme based on DSA * cryptography and described in Stimson p. 285. The p is a 512-bit * prime, g a generator of Zp* and q a 160-bit prime that divides p - 1 * and is a qth root of 1 mod p; that is, g^q = 1 mod p. The TA rolls a - * private random group key b (0 < b < q), then computes public - * v = g^(q - a). All values except the group key are known to all group - * members; the group key is known to the group servers, but not the - * group clients. Alice challenges Bob to confirm identity using the - * protocol described below. + * private random group key b (0 < b < q) and public key v = g^b, then + * sends (p, q, g, b) to the servers and (p, q, g, v) to the clients. + * Alice challenges Bob to confirm identity using the protocol described + * below. + * + * How it works + * + * The scheme goes like this. Both Alice and Bob have the public primes + * p, q and generator g. The TA gives private key b to Bob and public + * key v to Alice. + * + * Alice rolls new random challenge r (o < r < q) and sends to Bob in + * the IFF request message. Bob rolls new random k (0 < k < q), then + * computes y = k + b r mod q and x = g^k mod p and sends (y, hash(x)) + * to Alice in the response message. Besides making the response + * shorter, the hash makes it effectivey impossible for an intruder to + * solve for b by observing a number of these messages. + * + * Alice receives the response and computes g^y v^r mod p. After a bit + * of algebra, this simplifies to g^k. If the hash of this result + * matches hash(x), Alice knows that Bob has the group key b. The signed + * response binds this knowledge to Bob's private key and the public key + * previously received in his certificate. + */ +/* + * Generate Schnorr (IFF) keys. */ EVP_PKEY * /* DSA cuckoo nest */ -gen_iff( +gen_iffkey( char *id /* file name id */ ) { @@ -813,24 +1007,23 @@ /* * Generate DSA parameters for use as IFF parameters. */ - fprintf(stderr, "Generating IFF parameters (%d bits)...\n", - modulus); + fprintf(stderr, "Generating IFF keys (%d bits)...\n", + modulus2); RAND_bytes(seed, sizeof(seed)); - dsa = DSA_generate_parameters(modulus, seed, sizeof(seed), NULL, + dsa = DSA_generate_parameters(modulus2, seed, sizeof(seed), NULL, NULL, cb, "IFF"); fprintf(stderr, "\n"); if (dsa == NULL) { fprintf(stderr, "DSA generate parameters fails\n%s\n", ERR_error_string(ERR_get_error(), NULL)); - rval = -1; return (NULL);; } /* * Generate the private and public keys. The DSA parameters and - * these keys are distributed to all members of the group. + * private key are distributed to the servers, while all except + * the private key are distributed to the clients. */ - fprintf(stderr, "Generating IFF keys (%d bits)...\n", modulus); b = BN_new(); r = BN_new(); k = BN_new(); u = BN_new(); v = BN_new(); w = BN_new(); ctx = BN_CTX_new(); BN_rand(b, BN_num_bits(dsa->q), -1, 0); /* a */ @@ -846,7 +1039,6 @@ if (!temp) { BN_free(b); BN_free(r); BN_free(k); BN_free(u); BN_free(v); BN_free(w); BN_CTX_free(ctx); - rval = -1; return (NULL); } dsa->priv_key = BN_dup(b); /* private key */ @@ -854,16 +1046,16 @@ /* * Here is a trial round of the protocol. First, Alice rolls - * random r (0 < r < q) and sends it to Bob. She needs only - * modulus q. + * random nonce r mod q and sends it to Bob. She needs only + * q from parameters. */ BN_rand(r, BN_num_bits(dsa->q), -1, 0); /* r */ BN_mod(r, r, dsa->q, ctx); /* - * Bob rolls random k (0 < k < q), computes y = k + b r mod q + * Bob rolls random nonce k mod q, computes y = k + b r mod q * and x = g^k mod p, then sends (y, x) to Alice. He needs - * moduli p, q and the group key b. + * p, q and b from parameters and r from Alice. */ BN_rand(k, BN_num_bits(dsa->q), -1, 0); /* k, 0 < k < q */ BN_mod(k, k, dsa->q, ctx); @@ -873,9 +1065,10 @@ BN_mod_exp(u, dsa->g, k, dsa->p, ctx); /* x = g^k mod p */ /* - * Alice computes g^y v^r and verifies the result is equal to x. - * She needs modulus p, generator g, and the public key v, as - * well as her original r. + * Alice verifies x = g^y v^r to confirm that Bob has group key + * b. She needs p, q, g from parameters, (y, x) from Bob and the + * original r. We omit the detail here thatt only the hash of y + * is sent. */ BN_mod_exp(v, dsa->g, v, dsa->p, ctx); /* g^y mod p */ BN_mod_exp(w, dsa->pub_key, r, dsa->p, ctx); /* v^r */ @@ -888,42 +1081,52 @@ BN_free(u); BN_free(v); BN_free(w); BN_CTX_free(ctx); if (temp != 0) { DSA_free(dsa); - rval = -1; return (NULL); } /* - * Write the IFF server parameters and keys as a DSA private key - * encoded in PEM. + * Write the IFF keys as an encrypted DSA private key encoded in + * PEM. * * p modulus p * q modulus q * g generator g * priv_key b * public_key v + * kinv not used + * r not used */ - str = fheader("IFFpar", trustname); + str = fheader("IFFkey", id, groupname); pkey = EVP_PKEY_new(); EVP_PKEY_assign_DSA(pkey, dsa); - PEM_write_PrivateKey(str, pkey, passwd2 ? EVP_des_cbc() : NULL, - NULL, 0, NULL, passwd2); + PEM_write_PrivateKey(str, pkey, EVP_des_cbc(), NULL, 0, NULL, + passwd1); fclose(str); if (debug) - DSA_print_fp(stdout, dsa, 0); - fslink(id, trustname); + DSA_print_fp(stderr, dsa, 0); return (pkey); } /* - * Generate Guillou-Quisquater (GQ) parameters and keys + *********************************************************************** + * * + * The following routines implement the Guillou-Quisquater (GQ) * + * identity scheme * + * * + *********************************************************************** * * The Guillou-Quisquater (GQ) identity scheme is intended for use when - * the parameters, keys and certificates are generated by this program. - * The scheme uses a certificate extension field do convey the public - * key of a particular group identified by a group key known only to - * members of the group. The scheme is self contained and independent of - * new generations of host keys and sign keys. + * the certificate can be used to convey public parameters. The scheme + * uses a X509v3 certificate extension field do convey the public key of + * a private key known only to servers. There are two kinds of files: + * encrypted server files that contain private and public values and + * nonencrypted client files that contain only public values. New + * generations of server files must be securely transmitted to all + * servers of the group; client files can be distributed by any means. + * The scheme is self contained and independent of new generations of + * host keys and sign keys. The scheme is self contained and independent + * of new generations of host keys and sign keys. * * The GQ parameters hide in a RSA cuckoo structure which uses the same * parameters. The values are used by an identity scheme based on RSA @@ -932,105 +1135,81 @@ * The TA rolls private random group key b as RSA exponent. These values * are known to all group members. * - * When rolling new certificates, a member recomputes the private and + * When rolling new certificates, a server recomputes the private and * public keys. The private key u is a random roll, while the public key * is the inverse obscured by the group key v = (u^-1)^b. These values * replace the private and public keys normally generated by the RSA * scheme. Alice challenges Bob to confirm identity using the protocol * described below. + * + * How it works + * + * The scheme goes like this. Both Alice and Bob have the same modulus n + * and some random b as the group key. These values are computed and + * distributed in advance via secret means, although only the group key + * b is truly secret. Each has a private random private key u and public + * key (u^-1)^b, although not necessarily the same ones. Bob and Alice + * can regenerate the key pair from time to time without affecting + * operations. The public key is conveyed on the certificate in an + * extension field; the private key is never revealed. + * + * Alice rolls new random challenge r and sends to Bob in the GQ + * request message. Bob rolls new random k, then computes y = k u^r mod + * n and x = k^b mod n and sends (y, hash(x)) to Alice in the response + * message. Besides making the response shorter, the hash makes it + * effectivey impossible for an intruder to solve for b by observing + * a number of these messages. + * + * Alice receives the response and computes y^b v^r mod n. After a bit + * of algebra, this simplifies to k^b. If the hash of this result + * matches hash(x), Alice knows that Bob has the group key b. The signed + * response binds this knowledge to Bob's private key and the public key + * previously received in his certificate. + */ +/* + * Generate Guillou-Quisquater (GQ) parameters file. */ EVP_PKEY * /* RSA cuckoo nest */ -gen_gqpar( +gen_gqkey( char *id /* file name id */ ) { EVP_PKEY *pkey; /* private key */ - RSA *rsa; /* GQ parameters */ + RSA *rsa; /* RSA parameters */ BN_CTX *ctx; /* BN working space */ + BIGNUM *u, *v, *g, *k, *r, *y; /* BN temps */ FILE *str; + u_int temp; /* * Generate RSA parameters for use as GQ parameters. */ fprintf(stderr, - "Generating GQ parameters (%d bits)...\n", modulus); - rsa = RSA_generate_key(modulus, 3, cb, "GQ"); + "Generating GQ parameters (%d bits)...\n", + modulus2); + rsa = RSA_generate_key(modulus2, 3, cb, "GQ"); fprintf(stderr, "\n"); if (rsa == NULL) { fprintf(stderr, "RSA generate keys fails\n%s\n", ERR_error_string(ERR_get_error(), NULL)); - rval = -1; return (NULL); } + ctx = BN_CTX_new(); u = BN_new(); v = BN_new(); + g = BN_new(); k = BN_new(); r = BN_new(); y = BN_new(); /* * Generate the group key b, which is saved in the e member of - * the RSA structure. These values are distributed to all - * members of the group, but shielded from all other groups. We - * don't use all the parameters, but set the unused ones to a - * small number to minimize the file size. + * the RSA structure. The group key is transmitted to each group + * member encrypted by the member private key. */ ctx = BN_CTX_new(); BN_rand(rsa->e, BN_num_bits(rsa->n), -1, 0); /* b */ BN_mod(rsa->e, rsa->e, rsa->n, ctx); - BN_copy(rsa->d, BN_value_one()); - BN_copy(rsa->p, BN_value_one()); - BN_copy(rsa->q, BN_value_one()); - BN_copy(rsa->dmp1, BN_value_one()); - BN_copy(rsa->dmq1, BN_value_one()); - BN_copy(rsa->iqmp, BN_value_one()); - - /* - * Write the GQ parameters as a RSA private key encoded in PEM. - * The public and private keys are filled in later. - * - * n modulus n - * e group key b - * (remaining values are not used) - */ - str = fheader("GQpar", trustname); - pkey = EVP_PKEY_new(); - EVP_PKEY_assign_RSA(pkey, rsa); - PEM_write_PrivateKey(str, pkey, passwd2 ? EVP_des_cbc() : NULL, - NULL, 0, NULL, passwd2); - fclose(str); - if (debug) - RSA_print_fp(stdout, rsa, 0); - fslink(id, trustname); - return (pkey); -} - - -/* - * Update Guillou-Quisquater (GQ) parameters - */ -EVP_PKEY * /* RSA cuckoo nest */ -gen_gqkey( - char *id, /* file name id */ - EVP_PKEY *gqpar /* GQ parameters */ - ) -{ - EVP_PKEY *pkey; /* private key */ - RSA *rsa; /* RSA parameters */ - BN_CTX *ctx; /* BN working space */ - BIGNUM *u, *v, *g, *k, *r, *y; /* BN temps */ - FILE *str; - u_int temp; - - /* - * Generate GQ keys. Note that the group key b is the e member - * of - * the GQ parameters. - */ - fprintf(stderr, "Updating GQ keys (%d bits)...\n", modulus); - ctx = BN_CTX_new(); u = BN_new(); v = BN_new(); - g = BN_new(); k = BN_new(); r = BN_new(); y = BN_new(); /* * When generating his certificate, Bob rolls random private key - * u. + * u, then computes inverse v = u^-1. */ - rsa = gqpar->pkey.rsa; BN_rand(u, BN_num_bits(rsa->n), -1, 0); /* u */ BN_mod(u, u, rsa->n, ctx); BN_mod_inverse(v, u, rsa->n, ctx); /* u^-1 mod n */ @@ -1053,7 +1232,6 @@ BN_free(g); BN_free(k); BN_free(r); BN_free(y); BN_CTX_free(ctx); RSA_free(rsa); - rval = -1; return (NULL); } BN_copy(rsa->p, u); /* private key */ @@ -1061,28 +1239,29 @@ /* * Here is a trial run of the protocol. First, Alice rolls - * random r (0 < r < n) and sends it to Bob. She needs only - * modulus n from the parameters. + * random nonce r mod n and sends it to Bob. She needs only n + * from parameters. */ BN_rand(r, BN_num_bits(rsa->n), -1, 0); /* r */ BN_mod(r, r, rsa->n, ctx); /* - * Bob rolls random k (0 < k < n), computes y = k u^r mod n and - * g = k^b mod n, then sends (y, g) to Alice. He needs modulus n - * from the parameters and his private key u. + * Bob rolls random nonce k mod n, computes y = k u^r mod n and + * g = k^b mod n, then sends (y, g) to Alice. He needs n, u, b + * from parameters and r from Alice. */ BN_rand(k, BN_num_bits(rsa->n), -1, 0); /* k */ BN_mod(k, k, rsa->n, ctx); BN_mod_exp(y, rsa->p, r, rsa->n, ctx); /* u^r mod n */ BN_mod_mul(y, k, y, rsa->n, ctx); /* y = k u^r mod n */ - BN_mod_exp(g, k, rsa->e, rsa->n, ctx); /* g = k^b mod n */ + BN_mod_exp(g, k, rsa->e, rsa->n, ctx); /* g = k^b mod n */ /* - * Alice computes v^r y^b mod n and verifies the result is equal - * to g. She needs modulus n, generator g and group key b from - * the parameters and Bob's public key v = (u^-1)^b from his - * certificate. + * Alice verifies g = v^r y^b mod n to confirm that Bob has + * private key u. She needs n, g from parameters, public key v = + * (u^-1)^b from the certificate, (y, g) from Bob and the + * original r. We omit the detaul here that only the hash of g + * is sent. */ BN_mod_exp(v, rsa->q, r, rsa->n, ctx); /* v^r mod n */ BN_mod_exp(y, y, rsa->e, rsa->n, ctx); /* y^b mod n */ @@ -1094,43 +1273,53 @@ BN_free(g); BN_free(k); BN_free(r); BN_free(y); if (temp != 0) { RSA_free(rsa); - rval = -1; return (NULL); } /* - * Write the GQ parameters and keys as a RSA private key encoded - * in PEM. + * Write the GQ parameter file as an encrypted RSA private key + * encoded in PEM. * * n modulus n * e group key b + * d not used * p private key u * q public key (u^-1)^b - * (remaining values are not used) + * dmp1 not used + * dmq1 not used + * iqmp not used */ - str = fheader("GQpar", trustname); + BN_copy(rsa->d, BN_value_one()); + BN_copy(rsa->dmp1, BN_value_one()); + BN_copy(rsa->dmq1, BN_value_one()); + BN_copy(rsa->iqmp, BN_value_one()); + str = fheader("GQkey", id, groupname); pkey = EVP_PKEY_new(); EVP_PKEY_assign_RSA(pkey, rsa); - PEM_write_PrivateKey(str, pkey, passwd2 ? EVP_des_cbc() : NULL, - NULL, 0, NULL, passwd2); + PEM_write_PrivateKey(str, pkey, EVP_des_cbc(), NULL, 0, NULL, + passwd1); fclose(str); if (debug) - RSA_print_fp(stdout, rsa, 0); - fslink(id, trustname); + RSA_print_fp(stderr, rsa, 0); return (pkey); } /* - * Generate Mu-Varadharajan (MV) parameters and keys - * - * The Mu-Varadharajan (MV) cryptosystem is useful when servers - * broadcast messages to clients, but clients never send messages to - * servers. There is one encryption key for the server and a separate - * decryption key for each client. It operates something like a + *********************************************************************** + * * + * The following routines implement the Mu-Varadharajan (MV) identity * + * scheme * + * * + *********************************************************************** + * + * The Mu-Varadharajan (MV) cryptosystem was originally intended when + * servers broadcast messages to clients, but clients never send + * messages to servers. There is one encryption key for the server and a + * separate decryption key for each client. It operated something like a * pay-per-view satellite broadcasting system where the session key is * encrypted by the broadcaster and the decryption keys are held in a - * tamperproof set-top box. We don't use it this way, but read on. + * tamperproof set-top box. * * The MV parameters and private encryption key hide in a DSA cuckoo * structure which uses the same parameters, but generated in a @@ -1140,18 +1329,16 @@ * Varadharajan: Robust and Secure Broadcasting, Proc. Indocrypt 2001, * 223-231. The paper has significant errors and serious omissions. * - * Let q be the product of n distinct primes s'[j] (j = 1...n), where - * each s'[j] has m significant bits. Let p be a prime p = 2 * q + 1, so - * that q and each s'[j] divide p - 1 and p has M = n * m + 1 + * Let q be the product of n distinct primes s1[j] (j = 1...n), where + * each s1[j] has m significant bits. Let p be a prime p = 2 * q + 1, so + * that q and each s1[j] divide p - 1 and p has M = n * m + 1 * significant bits. Let g be a generator of Zp; that is, gcd(g, p - 1) * = 1 and g^q = 1 mod p. We do modular arithmetic over Zq and then * project into Zp* as exponents of g. Sometimes we have to compute an * inverse b^-1 of random b in Zq, but for that purpose we require * gcd(b, q) = 1. We expect M to be in the 500-bit range and n - * relatively small, like 30. Associated with each s'[j] is an element - * s[j] such that s[j] s'[j] = s'[j] mod q. We find s[j] as the quotient - * (q + s'[j]) / s'[j]. These are the parameters of the scheme and they - * are expensive to compute. + * relatively small, like 30. These are the parameters of the scheme and + * they are expensive to compute. * * We set up an instance of the scheme as follows. A set of random * values x[j] mod q (j = 1...n), are generated as the zeros of a @@ -1162,37 +1349,52 @@ * pairs (xbar[j], xhat[j]) (j = 1...n) of private client keys are used * to construct the decryption keys. The devil is in the details. * - * This routine generates a private encryption file including the - * private encryption key E and public key (gbar, ghat). It then - * generates decryption files including the private key (xbar[j], - * xhat[j]) for each client. E is a permutation that encrypts a block - * y = E x. The jth client computes the inverse permutation E^-1 = - * gbar^xhat[j] ghat^xbar[j] and decrypts the block x = E^-1 y. + * This routine generates a private server encryption file including the + * private encryption key E and partial decryption keys gbar and ghat. + * It then generates public client decryption files including the public + * keys xbar[j] and xhat[j] for each client j. The partial decryption + * files are used to compute the inverse of E. These values are suitably + * blinded so secrets are not revealed. * * The distinguishing characteristic of this scheme is the capability to * revoke keys. Included in the calculation of E, gbar and ghat is the - * product s = prod(s'[j]) (j = 1...n) above. If the factor s'[j] is + * product s = prod(s1[j]) (j = 1...n) above. If the factor s1[j] is * subsequently removed from the product and E, gbar and ghat * recomputed, the jth client will no longer be able to compute E^-1 and - * thus unable to decrypt the block. + * thus unable to decrypt the messageblock. + * + * How it works + * + * The scheme goes like this. Bob has the server values (p, E, q, gbar, + * ghat) and Alice has the client values (p, xbar, xhat). + * + * Alice rolls new random nonce r mod p and sends to Bob in the MV + * request message. Bob rolls random nonce k mod q, encrypts y = r E^k + * mod p and sends (y, gbar^k, ghat^k) to Alice. + * + * Alice receives the response and computes the inverse (E^k)^-1 from + * the partial decryption keys gbar^k, ghat^k, xbar and xhat. She then + * decrypts y and verifies it matches the original r. The signed + * response binds this knowledge to Bob's private key and the public key + * previously received in his certificate. */ EVP_PKEY * /* DSA cuckoo nest */ -gen_mv( - char *id /* file name id */ +gen_mvkey( + char *id, /* file name id */ + EVP_PKEY **evpars /* parameter list pointer */ ) { - EVP_PKEY *pkey, *pkey1; /* private key */ - DSA *dsa; /* DSA parameters */ - DSA *sdsa; /* DSA parameters */ + EVP_PKEY *pkey, *pkey1; /* private keys */ + DSA *dsa, *dsa2, *sdsa; /* DSA parameters */ BN_CTX *ctx; /* BN working space */ - BIGNUM **x; /* polynomial zeros vector */ - BIGNUM **a; /* polynomial coefficient vector */ - BIGNUM **g; /* public key vector */ - BIGNUM **s, **s1; /* private enabling keys */ - BIGNUM **xbar, **xhat; /* private keys vector */ + BIGNUM *a[MVMAX]; /* polynomial coefficient vector */ + BIGNUM *g[MVMAX]; /* public key vector */ + BIGNUM *s1[MVMAX]; /* private enabling keys */ + BIGNUM *x[MVMAX]; /* polynomial zeros vector */ + BIGNUM *xbar[MVMAX], *xhat[MVMAX]; /* private keys vector */ BIGNUM *b; /* group key */ BIGNUM *b1; /* inverse group key */ - BIGNUM *ss; /* enabling key */ + BIGNUM *s; /* enabling key */ BIGNUM *biga; /* master encryption key */ BIGNUM *bige; /* session encryption key */ BIGNUM *gbar, *ghat; /* public key */ @@ -1200,39 +1402,34 @@ int i, j, n; FILE *str; u_int temp; - char ident[20]; /* * Generate MV parameters. * * The object is to generate a multiplicative group Zp* modulo a * prime p and a subset Zq mod q, where q is the product of n - * distinct primes s'[j] (j = 1...n) and q divides p - 1. We - * first generate n distinct primes, which may have to be - * regenerated later. As a practical matter, it is tough to find - * more than 31 distinct primes for modulus 512 or 61 primes for - * modulus 1024. The latter can take several hundred iterations + * distinct primes s1[j] (j = 1...n) and q divides p - 1. We + * first generate n m-bit primes, where the product n m is in + * the order of 512 bits. One or more of these may have to be + * replaced later. As a practical matter, it is tough to find + * more than 31 distinct primes for 512 bits or 61 primes for + * 1024 bits. The latter can take several hundred iterations * and several minutes on a Sun Blade 1000. */ n = nkeys; fprintf(stderr, "Generating MV parameters for %d keys (%d bits)...\n", n, - modulus / n); + modulus2 / n); ctx = BN_CTX_new(); u = BN_new(); v = BN_new(); w = BN_new(); b = BN_new(); b1 = BN_new(); dsa = DSA_new(); - dsa->p = BN_new(); - dsa->q = BN_new(); - dsa->g = BN_new(); - s = malloc((n + 1) * sizeof(BIGNUM)); - s1 = malloc((n + 1) * sizeof(BIGNUM)); - for (j = 1; j <= n; j++) - s1[j] = BN_new(); + dsa->p = BN_new(); dsa->q = BN_new(); dsa->g = BN_new(); + dsa->priv_key = BN_new(); dsa->pub_key = BN_new(); temp = 0; for (j = 1; j <= n; j++) { + s1[j] = BN_new(); while (1) { - fprintf(stderr, "Birthdays %d\r", temp); - BN_generate_prime(s1[j], modulus / n, 0, NULL, + BN_generate_prime(s1[j], modulus2 / n, 0, NULL, NULL, NULL, NULL); for (i = 1; i < j; i++) { if (BN_cmp(s1[i], s1[j]) == 0) @@ -1243,14 +1440,14 @@ temp++; } } - fprintf(stderr, "Birthday keys rejected %d\n", temp); + fprintf(stderr, "Birthday keys regenerated %d\n", temp); /* * Compute the modulus q as the product of the primes. Compute * the modulus p as 2 * q + 1 and test p for primality. If p * is composite, replace one of the primes with a new distinct * one and try again. Note that q will hardly be a secret since - * we have to reveal p to servers and clients. However, + * we have to reveal p to servers, but not clients. However, * factoring q to find the primes should be adequately hard, as * this is the same problem considered hard in RSA. Question: is * it as hard to find n small prime factors totalling n bits as @@ -1259,7 +1456,6 @@ */ temp = 0; while (1) { - fprintf(stderr, "Duplicate keys rejected %d\r", ++temp); BN_one(dsa->q); for (j = 1; j <= n; j++) BN_mul(dsa->q, dsa->q, s1[j], ctx); @@ -1270,9 +1466,10 @@ NULL)) break; + temp++; j = temp % n + 1; while (1) { - BN_generate_prime(u, modulus / n, 0, 0, NULL, + BN_generate_prime(u, modulus2 / n, 0, 0, NULL, NULL, NULL); for (i = 1; i <= n; i++) { if (BN_cmp(u, s1[i]) == 0) @@ -1283,12 +1480,12 @@ } BN_copy(s1[j], u); } - fprintf(stderr, "Duplicate keys rejected %d\n", temp); + fprintf(stderr, "Defective keys regenerated %d\n", temp); /* * Compute the generator g using a random roll such that * gcd(g, p - 1) = 1 and g^q = 1. This is a generator of p, not - * q. + * q. This may take several iterations. */ BN_copy(v, dsa->p); BN_sub_word(v, 1); @@ -1305,29 +1502,17 @@ } /* - * Compute s[j] such that s[j] * s'[j] = s'[j] for all j. The - * easy way to do this is to compute q + s'[j] and divide the - * result by s'[j]. Exercise for the student: prove the - * remainder is always zero. - */ - for (j = 1; j <= n; j++) { - s[j] = BN_new(); - BN_add(s[j], dsa->q, s1[j]); - BN_div(s[j], u, s[j], s1[j], ctx); - } - - /* * Setup is now complete. Roll random polynomial roots x[j] - * (0 < x[j] < q) for all j. While it may not be strictly + * (j = 1...n) for all j. While it may not be strictly * necessary, Make sure each root has no factors in common with * q. */ fprintf(stderr, "Generating polynomial coefficients for %d roots (%d bits)\n", n, BN_num_bits(dsa->q)); - x = malloc((n + 1) * sizeof(BIGNUM)); for (j = 1; j <= n; j++) { x[j] = BN_new(); + while (1) { BN_rand(x[j], BN_num_bits(dsa->q), 0, 0); BN_mod(x[j], x[j], dsa->q, ctx); @@ -1342,9 +1527,9 @@ * expansion of root products (x - x[j]) mod q for all j. The * method is a present from Charlie Boncelet. */ - a = malloc((n + 1) * sizeof(BIGNUM)); for (i = 0; i <= n; i++) { a[i] = BN_new(); + BN_one(a[i]); } for (j = 1; j <= n; j++) { @@ -1362,18 +1547,17 @@ /* * Generate g[i] = g^a[i] mod p for all i and the generator g. */ - fprintf(stderr, "Generating g[i] parameters\n"); - g = malloc((n + 1) * sizeof(BIGNUM)); for (i = 0; i <= n; i++) { g[i] = BN_new(); + BN_mod_exp(g[i], dsa->g, a[i], dsa->p, ctx); } /* - * Verify prod(g[i]^(a[i] x[j]^i)) = 1 for all i, j; otherwise, - * exit. Note the a[i] x[j]^i exponent is computed mod q, but - * the g[i] is computed mod p. also note the expression given in - * the paper is incorrect. + * Verify prod(g[i]^(a[i] x[j]^i)) = 1 for all i, j. Note the + * a[i] x[j]^i exponent is computed mod q, but the g[i] is + * computed mod p. also note the expression given in the paper + * is incorrect. */ temp = 1; for (j = 1; j <= n; j++) { @@ -1392,7 +1576,6 @@ "Confirm prod(g[i]^(x[j]^i)) = 1 for all i, j: %s\n", temp ? "yes" : "no"); if (!temp) { - rval = -1; return (NULL); } @@ -1401,6 +1584,7 @@ * since it is expensive to compute. */ biga = BN_new(); + BN_one(biga); for (j = 1; j <= n; j++) { for (i = 0; i < n; i++) { @@ -1413,7 +1597,7 @@ /* * Roll private random group key b mod q (0 < b < q), where - * gcd(b, q) = 1 to guarantee b^1 exists, then compute b^-1 + * gcd(b, q) = 1 to guarantee b^-1 exists, then compute b^-1 * mod q. If b is changed, the client keys must be recomputed. */ while (1) { @@ -1427,14 +1611,18 @@ /* * Make private client keys (xbar[j], xhat[j]) for all j. Note - * that the keys for the jth client involve s[j], but not s'[j] - * or the product s = prod(s'[j]) mod q, which is the enabling - * key. + * that the keys for the jth client do not s1[j] or the product + * s1[j]) (j = 1...n) which is q by construction. + * + * Compute the factor w such that w s1[j] = s1[j] for all j. The + * easy way to do this is to compute (q + s1[j]) / s1[j]. + * Exercise for the student: prove the remainder is always zero. */ - xbar = malloc((n + 1) * sizeof(BIGNUM)); - xhat = malloc((n + 1) * sizeof(BIGNUM)); for (j = 1; j <= n; j++) { xbar[j] = BN_new(); xhat[j] = BN_new(); + + BN_add(w, dsa->q, s1[j]); + BN_div(w, u, w, s1[j], ctx); BN_zero(xbar[j]); BN_set_word(v, n); for (i = 1; i <= n; i++) { @@ -1445,154 +1633,169 @@ } BN_mod_mul(xbar[j], xbar[j], b1, dsa->q, ctx); BN_mod_exp(xhat[j], x[j], v, dsa->q, ctx); - BN_mod_mul(xhat[j], xhat[j], s[j], dsa->q, ctx); + BN_mod_mul(xhat[j], xhat[j], w, dsa->q, ctx); } /* - * The enabling key is initially q by construction. We can - * revoke client j by dividing q by s'[j]. The quotient becomes - * the enabling key s. Note we always have to revoke one key; - * otherwise, the plaintext and cryptotext would be identical. + * We revoke client j by dividing q by s1[j]. The quotient + * becomes the enabling key s. Note we always have to revoke + * one key; otherwise, the plaintext and cryptotext would be + * identical. For the present there are no provisions to revoke + * additional keys, so we sail on with only token revocations. */ - ss = BN_new(); - BN_copy(ss, dsa->q); - BN_div(ss, u, dsa->q, s1[n], ctx); + s = BN_new(); + + BN_copy(s, dsa->q); + BN_div(s, u, s, s1[10], ctx); + BN_div(s, u, s, s1[n], ctx); /* - * Make private server encryption key E = A^s and public server - * keys gbar = g^s mod p and ghat = g^(s b) mod p. The (gbar, - * ghat) is the public key provided to the server, which uses it - * to compute the session encryption key and public key included - * in its messages. These values must be regenerated if the - * enabling key is changed. + * For each combination of clients to be revoked, make private + * encryption key E = A^s and partial decryption keys gbar = g^s + * and ghat = g^(s b), all mod p. The servers use these keys to + * compute the session encryption key and partial decryption + * keys. These values must be regenerated if the enabling key is + * changed. */ bige = BN_new(); gbar = BN_new(); ghat = BN_new(); - BN_mod_exp(bige, biga, ss, dsa->p, ctx); - BN_mod_exp(gbar, dsa->g, ss, dsa->p, ctx); - BN_mod_mul(v, ss, b, dsa->q, ctx); - BN_mod_exp(ghat, dsa->g, v, dsa->p, ctx); + BN_mod_exp(bige, biga, s, dsa->p, ctx); + BN_mod_exp(gbar, dsa->g, s, dsa->p, ctx); + BN_mod_mul(v, s, b, dsa->q, ctx); + BN_mod_exp(ghat, dsa->g, v, dsa->p, ctx); + /* - * We produce the key media in three steps. The first step is to - * generate the private values that do not depend on the - * enabling key. These include the server values p, q, g, b, A - * and the client values s'[j], xbar[j] and xhat[j] for each j. - * The p, xbar[j] and xhat[j] values are encoded in private - * files which are distributed to respective clients. The p, q, - * g, A and s'[j] values (will be) written to a secret file to - * be read back later. - * - * The secret file (will be) read back at some later time to - * enable/disable individual keys and generate/regenerate the - * enabling key s. The p, q, E, gbar and ghat values are written - * to a secret file to be read back later by the server. + * Notes: We produce the key media in three steps. The first + * step is to generate the system parameters p, q, g, b, A and + * the enabling keys s1[j]. Associated with each s1[j] are + * parameters xbar[j] and xhat[j]. All of these parameters are + * retained in a data structure protecteted by the trusted-agent + * password. The p, xbar[j] and xhat[j] paremeters are + * distributed to the j clients. When the client keys are to be + * activated, the enabled keys are multipied together to form + * the master enabling key s. This and the other parameters are + * used to compute the server encryption key E and the partial + * decryption keys gbar and ghat. * - * The server reads the secret file and rolls the session key - * k, which is used only once, then computes E^k, gbar^k and - * ghat^k. The E^k is the session encryption key. The encrypted - * data, gbar^k and ghat^k are transmtted to clients in an - * extension field. The client receives the message and computes - * x = (gbar^k)^xbar[j] (ghat^k)^xhat[j], finds the session - * encryption key E^k as the inverse x^-1 and decrypts the data. - */ - BN_copy(dsa->g, bige); - dsa->priv_key = BN_dup(gbar); - dsa->pub_key = BN_dup(ghat); - + * In the identity exchange the client rolls random r and sends + * it to the server. The server rolls random k, which is used + * only once, then computes the session key E^k and partial + * decryption keys gbar^k and ghat^k. The server sends the + * encrypted r along with gbar^k and ghat^k to the client. The + * client completes the decryption and verifies it matches r. + */ /* - * Write the MV server parameters and keys as a DSA private key - * encoded in PEM. + * Write the MV trusted-agent parameters and keys as a DSA + * private key encoded in PEM. * * p modulus p - * q modulus q (used only to generate k) - * g E mod p - * priv_key gbar mod p - * pub_key ghat mod p + * q modulus q + * g generator g + * priv_key A mod p + * pub_key b mod q + * (remaining values are not used) */ - str = fheader("MVpar", trustname); + i = 0; + str = fheader("MVta", "mvta", groupname); + fprintf(stderr, "Generating MV trusted-authority keys\n"); + BN_copy(dsa->priv_key, biga); + BN_copy(dsa->pub_key, b); pkey = EVP_PKEY_new(); EVP_PKEY_assign_DSA(pkey, dsa); - PEM_write_PrivateKey(str, pkey, passwd2 ? EVP_des_cbc() : NULL, - NULL, 0, NULL, passwd2); - fclose(str); + PEM_write_PrivateKey(str, pkey, EVP_des_cbc(), NULL, 0, NULL, + passwd1); + evpars[i++] = pkey; if (debug) - DSA_print_fp(stdout, dsa, 0); - fslink(id, trustname); + DSA_print_fp(stderr, dsa, 0); /* - * Write the parameters and private key (xbar[j], xhat[j]) for - * all j as a DSA private key encoded in PEM. It is used only by - * the designated recipient(s) who pay a suitably outrageous fee - * for its use. - */ - sdsa = DSA_new(); - sdsa->p = BN_dup(dsa->p); - sdsa->q = BN_dup(BN_value_one()); - sdsa->g = BN_dup(BN_value_one()); - sdsa->priv_key = BN_new(); - sdsa->pub_key = BN_new(); + * Append the MV server parameters and keys as a DSA key encoded + * in PEM. + * + * p modulus p + * q modulus q (used only when generating k) + * g bige + * priv_key gbar + * pub_key ghat + * (remaining values are not used) + */ + fprintf(stderr, "Generating MV server keys\n"); + dsa2 = DSA_new(); + dsa2->p = BN_dup(dsa->p); + dsa2->q = BN_dup(dsa->q); + dsa2->g = BN_dup(bige); + dsa2->priv_key = BN_dup(gbar); + dsa2->pub_key = BN_dup(ghat); + pkey1 = EVP_PKEY_new(); + EVP_PKEY_assign_DSA(pkey1, dsa2); + PEM_write_PrivateKey(str, pkey1, EVP_des_cbc(), NULL, 0, NULL, + passwd1); + evpars[i++] = pkey1; + if (debug) + DSA_print_fp(stderr, dsa2, 0); + + /* + * Append the MV client parameters for each client j as DSA keys + * encoded in PEM. + * + * p modulus p + * priv_key xbar[j] mod q + * pub_key xhat[j] mod q + * (remaining values are not used) + */ + fprintf(stderr, "Generating %d MV client keys\n", n); for (j = 1; j <= n; j++) { - BN_copy(sdsa->priv_key, xbar[j]); - BN_copy(sdsa->pub_key, xhat[j]); - BN_mod_exp(v, dsa->priv_key, sdsa->pub_key, dsa->p, + sdsa = DSA_new(); + + sdsa->p = BN_dup(dsa->p); + sdsa->q = BN_dup(BN_value_one()); + sdsa->g = BN_dup(BN_value_one()); + sdsa->priv_key = BN_dup(xbar[j]); + sdsa->pub_key = BN_dup(xhat[j]); + pkey1 = EVP_PKEY_new(); + EVP_PKEY_set1_DSA(pkey1, sdsa); + PEM_write_PrivateKey(str, pkey1, EVP_des_cbc(), NULL, 0, + NULL, passwd1); + evpars[i++] = pkey1; + if (debug) + DSA_print_fp(stderr, sdsa, 0); + + /* + * The product gbar^k)^xbar[j] (ghat^k)^xhat[j] and E + * are inverses of each other. We check that the product + * is one for each client except the ones that have been + * revoked. + */ + BN_mod_exp(v, dsa2->priv_key, sdsa->pub_key, dsa->p, ctx); - BN_mod_exp(u, dsa->pub_key, sdsa->priv_key, dsa->p, + BN_mod_exp(u, dsa2->pub_key, sdsa->priv_key, dsa->p, ctx); BN_mod_mul(u, u, v, dsa->p, ctx); - BN_mod_mul(u, u, dsa->g, dsa->p, ctx); - BN_free(xbar[j]); BN_free(xhat[j]); - BN_free(x[j]); BN_free(s[j]); BN_free(s1[j]); + BN_mod_mul(u, u, bige, dsa->p, ctx); if (!BN_is_one(u)) { fprintf(stderr, "Revoke key %d\n", j); continue; } - - /* - * Write the client parameters as a DSA private key - * encoded in PEM. We don't make links for these. - * - * p modulus p - * priv_key xbar[j] mod q - * pub_key xhat[j] mod q - * (remaining values are not used) - */ - sprintf(ident, "MVkey%d", j); - str = fheader(ident, trustname); - pkey1 = EVP_PKEY_new(); - EVP_PKEY_set1_DSA(pkey1, sdsa); - PEM_write_PrivateKey(str, pkey1, passwd2 ? - EVP_des_cbc() : NULL, NULL, 0, NULL, passwd2); - fclose(str); - fprintf(stderr, "ntpkey_%s_%s.%lu\n", ident, trustname, - epoch + JAN_1970); - if (debug) - DSA_print_fp(stdout, sdsa, 0); - EVP_PKEY_free(pkey1); } + evpars[i++] = NULL; + fclose(str); /* * Free the countries. */ for (i = 0; i <= n; i++) { - BN_free(a[i]); - BN_free(g[i]); + BN_free(a[i]); BN_free(g[i]); + } + for (j = 1; j <= n; j++) { + BN_free(x[j]); BN_free(xbar[j]); BN_free(xhat[j]); + BN_free(s1[j]); } - BN_free(u); BN_free(v); BN_free(w); BN_CTX_free(ctx); - BN_free(b); BN_free(b1); BN_free(biga); BN_free(bige); - BN_free(ss); BN_free(gbar); BN_free(ghat); - DSA_free(sdsa); - - /* - * Free the world. - */ - free(x); free(a); free(g); free(s); free(s1); - free(xbar); free(xhat); return (pkey); } /* - * Generate X509v3 scertificate. + * Generate X509v3 certificate. * * The certificate consists of the version number, serial number, * validity interval, issuer name, subject name and public key. For a @@ -1607,7 +1810,8 @@ EVP_PKEY *pkey, /* generic signature algorithm */ const EVP_MD *md, /* generic digest algorithm */ char *gqpub, /* identity extension (hex string) */ - char *exten /* private cert extension */ + char *exten, /* private cert extension */ + char *name /* subject/issuer namd */ ) { X509 *cert; /* X509 certificate */ @@ -1622,31 +1826,29 @@ * Generate X509 self-signed certificate. * * Set the certificate serial to the NTP seconds for grins. Set - * the version to 3. Set the subject name and issuer name to the - * subject name in the request. Set the initial validity to the - * current time and the final validity one year hence. + * the version to 3. Set the initial validity to the current + * time and the finalvalidity one year hence. */ - id = OBJ_nid2sn(md->pkey_type); - fprintf(stderr, "Generating certificate %s\n", id); + id = OBJ_nid2sn(md->pkey_type); + fprintf(stderr, "Generating new certificate %s %s\n", name, id); cert = X509_new(); X509_set_version(cert, 2L); serial = ASN1_INTEGER_new(); - ASN1_INTEGER_set(serial, epoch + JAN_1970); + ASN1_INTEGER_set(serial, (long)epoch + JAN_1970); X509_set_serialNumber(cert, serial); ASN1_INTEGER_free(serial); X509_time_adj(X509_get_notBefore(cert), 0L, &epoch); X509_time_adj(X509_get_notAfter(cert), YEAR, &epoch); subj = X509_get_subject_name(cert); X509_NAME_add_entry_by_txt(subj, "commonName", MBSTRING_ASC, - (unsigned char *) hostname, strlen(hostname), -1, 0); + (unsigned char *) name, strlen(name), -1, 0); subj = X509_get_issuer_name(cert); X509_NAME_add_entry_by_txt(subj, "commonName", MBSTRING_ASC, - (unsigned char *) trustname, strlen(trustname), -1, 0); + (unsigned char *) name, strlen(name), -1, 0); if (!X509_set_pubkey(cert, pkey)) { fprintf(stderr, "Assign key fails\n%s\n", ERR_error_string(ERR_get_error(), NULL)); X509_free(cert); - rval = -1; return (0); } @@ -1666,7 +1868,6 @@ if (!X509_add_ext(cert, ex, -1)) { fprintf(stderr, "Add extension field fails\n%s\n", ERR_error_string(ERR_get_error(), NULL)); - rval = -1; return (0); } X509_EXTENSION_free(ex); @@ -1680,7 +1881,6 @@ if (!X509_add_ext(cert, ex, -1)) { fprintf(stderr, "Add extension field fails\n%s\n", ERR_error_string(ERR_get_error(), NULL)); - rval = -1; return (0); } X509_EXTENSION_free(ex); @@ -1696,7 +1896,6 @@ fprintf(stderr, "Add extension field fails\n%s\n", ERR_error_string(ERR_get_error(), NULL)); - rval = -1; return (0); } X509_EXTENSION_free(ex); @@ -1718,7 +1917,6 @@ fprintf(stderr, "Add extension field fails\n%s\n", ERR_error_string(ERR_get_error(), NULL)); - rval = -1; return (0); } X509_EXTENSION_free(ex); @@ -1728,11 +1926,10 @@ * Sign and verify. */ X509_sign(cert, pkey, md); - if (!X509_verify(cert, pkey)) { + if (X509_verify(cert, pkey) <= 0) { fprintf(stderr, "Verify %s certificate fails\n%s\n", id, ERR_error_string(ERR_get_error(), NULL)); X509_free(cert); - rval = -1; return (0); } @@ -1740,17 +1937,16 @@ * Write the certificate encoded in PEM. */ sprintf(pathbuf, "%scert", id); - str = fheader(pathbuf, hostname); + str = fheader(pathbuf, "cert", hostname); PEM_write_X509(str, cert); fclose(str); if (debug) - X509_print_fp(stdout, cert); + X509_print_fp(stderr, cert); X509_free(cert); - fslink("cert", hostname); return (1); } -#if 0 /* asn2ntp is not used */ +#if 0 /* asn2ntp is used only with commercial certificates */ /* * asn2ntp - convert ASN1_TIME time structure to NTP time */ @@ -1840,51 +2036,38 @@ return (gen_dsa(id)); fprintf(stderr, "Invalid %s key type %s\n", id, type); - rval = -1; return (NULL); } #endif /* OPENSSL */ /* - * Generate file header + * Generate file header and link */ FILE * fheader ( - const char *id, /* file name id */ - const char *name /* owner name */ + const char *file, /* file name id */ + const char *ulink, /* linkname */ + const char *owner /* owner name */ ) { FILE *str; /* file handle */ + char linkname[MAXFILENAME]; /* link name */ + int temp; - sprintf(filename, "ntpkey_%s_%s.%lu", id, name, epoch + + sprintf(filename, "ntpkey_%s_%s.%lu", file, owner, epoch + JAN_1970); if ((str = fopen(filename, "w")) == NULL) { perror("Write"); exit (-1); } - fprintf(str, "# %s\n# %s", filename, ctime(&epoch)); - return (str); -} - - -/* - * Generate symbolic links - */ -void -fslink( - const char *id, /* file name id */ - const char *name /* owner name */ - ) -{ - char linkname[MAXFILENAME]; /* link name */ - int temp; - - sprintf(linkname, "ntpkey_%s_%s", id, name); + sprintf(linkname, "ntpkey_%s_%s", ulink, owner); remove(linkname); temp = symlink(filename, linkname); if (temp < 0) - perror(id); - fprintf(stderr, "Generating new %s file and link\n", id); + perror(file); + fprintf(stderr, "Generating new %s file and link\n", ulink); fprintf(stderr, "%s->%s\n", linkname, filename); + fprintf(str, "# %s\n# %s\n", filename, ctime(&epoch)); + return (str); } diff -urN src/contrib/ntp/util/ntptime.c src.ntp/contrib/ntp/util/ntptime.c --- src/contrib/ntp/util/ntptime.c 2008-08-22 17:58:00.000000000 +0200 +++ src.ntp/contrib/ntp/util/ntptime.c 2009-12-09 08:36:35.000000000 +0100 @@ -52,11 +52,11 @@ /* * Function prototypes */ -char *sprintb P((u_int, const char *)); -const char *timex_state P((int)); +char *sprintb (u_int, const char *); +const char *timex_state (int); #ifdef SIGSYS -void pll_trap P((int)); +void pll_trap (int); static struct sigaction newsigsys; /* new sigaction status */ static struct sigaction sigsys; /* current sigaction status */ @@ -67,6 +67,7 @@ static volatile int status; /* most recent status bits */ static volatile int flash; /* most recent ntp_adjtime() bits */ char* progname; +volatile int debug; /* for libntp */ static char optargs[] = "MNT:cde:f:hm:o:rs:t:"; int diff -urN src/contrib/ntp/util/tickadj.c src.ntp/contrib/ntp/util/tickadj.c --- src/contrib/ntp/util/tickadj.c 2004-07-20 17:01:56.000000000 +0200 +++ src.ntp/contrib/ntp/util/tickadj.c 2009-12-09 08:36:37.000000000 +0100 @@ -183,8 +183,8 @@ # include #endif -#include "ntp_io.h" #include "ntp_stdlib.h" +#include "ntp_io.h" #ifdef hz /* Was: RS6000 */ # undef hz @@ -225,10 +225,10 @@ const char *file = NULL; int fd = -1; -static void getoffsets P((off_t *, off_t *, off_t *, off_t *)); -static int openfile P((const char *, int)); -static void writevar P((int, off_t, int)); -static void readvar P((int, off_t, int *)); +static void getoffsets (off_t *, off_t *, off_t *, off_t *); +static int openfile (const char *, int); +static void writevar (int, off_t, int); +static void readvar (int, off_t, int *); /* * main - parse arguments and handle options diff -urN src/contrib/ntp/version src.ntp/contrib/ntp/version --- src/contrib/ntp/version 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/version 2010-07-09 04:27:20.000000000 +0200 @@ -1 +1 @@ -1.1612 +1.2194 diff -urN src/contrib/ntp/version.m4 src.ntp/contrib/ntp/version.m4 --- src/contrib/ntp/version.m4 2009-12-15 15:58:10.000000000 +0100 +++ src.ntp/contrib/ntp/version.m4 2010-07-09 04:21:13.000000000 +0200 @@ -1 +1 @@ -m4_define([VERSION_NUMBER],[4.2.4p8]) +m4_define([VERSION_NUMBER],[4.2.6p2]) diff -urN src/contrib/ntp/ylwrap src.ntp/contrib/ntp/ylwrap --- src/contrib/ntp/ylwrap 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/contrib/ntp/ylwrap 2009-12-09 08:40:12.000000000 +0100 @@ -0,0 +1,222 @@ +#! /bin/sh +# ylwrap - wrapper for lex/yacc invocations. + +scriptversion=2009-04-28.21; # UTC + +# Copyright (C) 1996, 1997, 1998, 1999, 2001, 2002, 2003, 2004, 2005, +# 2007, 2009 Free Software Foundation, Inc. +# +# Written by Tom Tromey . +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that program. + +# This file is maintained in Automake, please report +# bugs to or send patches to +# . + +case "$1" in + '') + echo "$0: No files given. Try \`$0 --help' for more information." 1>&2 + exit 1 + ;; + --basedir) + basedir=$2 + shift 2 + ;; + -h|--h*) + cat <<\EOF +Usage: ylwrap [--help|--version] INPUT [OUTPUT DESIRED]... -- PROGRAM [ARGS]... + +Wrapper for lex/yacc invocations, renaming files as desired. + + INPUT is the input file + OUTPUT is one file PROG generates + DESIRED is the file we actually want instead of OUTPUT + PROGRAM is program to run + ARGS are passed to PROG + +Any number of OUTPUT,DESIRED pairs may be used. + +Report bugs to . +EOF + exit $? + ;; + -v|--v*) + echo "ylwrap $scriptversion" + exit $? + ;; +esac + + +# The input. +input="$1" +shift +case "$input" in + [\\/]* | ?:[\\/]*) + # Absolute path; do nothing. + ;; + *) + # Relative path. Make it absolute. + input="`pwd`/$input" + ;; +esac + +pairlist= +while test "$#" -ne 0; do + if test "$1" = "--"; then + shift + break + fi + pairlist="$pairlist $1" + shift +done + +# The program to run. +prog="$1" +shift +# Make any relative path in $prog absolute. +case "$prog" in + [\\/]* | ?:[\\/]*) ;; + *[\\/]*) prog="`pwd`/$prog" ;; +esac + +# FIXME: add hostname here for parallel makes that run commands on +# other machines. But that might take us over the 14-char limit. +dirname=ylwrap$$ +trap "cd '`pwd`'; rm -rf $dirname > /dev/null 2>&1" 1 2 3 15 +mkdir $dirname || exit 1 + +cd $dirname + +case $# in + 0) "$prog" "$input" ;; + *) "$prog" "$@" "$input" ;; +esac +ret=$? + +if test $ret -eq 0; then + set X $pairlist + shift + first=yes + # Since DOS filename conventions don't allow two dots, + # the DOS version of Bison writes out y_tab.c instead of y.tab.c + # and y_tab.h instead of y.tab.h. Test to see if this is the case. + y_tab_nodot="no" + if test -f y_tab.c || test -f y_tab.h; then + y_tab_nodot="yes" + fi + + # The directory holding the input. + input_dir=`echo "$input" | sed -e 's,\([\\/]\)[^\\/]*$,\1,'` + # Quote $INPUT_DIR so we can use it in a regexp. + # FIXME: really we should care about more than `.' and `\'. + input_rx=`echo "$input_dir" | sed 's,\\\\,\\\\\\\\,g;s,\\.,\\\\.,g'` + + while test "$#" -ne 0; do + from="$1" + # Handle y_tab.c and y_tab.h output by DOS + if test $y_tab_nodot = "yes"; then + if test $from = "y.tab.c"; then + from="y_tab.c" + else + if test $from = "y.tab.h"; then + from="y_tab.h" + fi + fi + fi + if test -f "$from"; then + # If $2 is an absolute path name, then just use that, + # otherwise prepend `../'. + case "$2" in + [\\/]* | ?:[\\/]*) target="$2";; + *) target="../$2";; + esac + + # We do not want to overwrite a header file if it hasn't + # changed. This avoid useless recompilations. However the + # parser itself (the first file) should always be updated, + # because it is the destination of the .y.c rule in the + # Makefile. Divert the output of all other files to a temporary + # file so we can compare them to existing versions. + if test $first = no; then + realtarget="$target" + target="tmp-`echo $target | sed s/.*[\\/]//g`" + fi + # Edit out `#line' or `#' directives. + # + # We don't want the resulting debug information to point at + # an absolute srcdir; it is better for it to just mention the + # .y file with no path. + # + # We want to use the real output file name, not yy.lex.c for + # instance. + # + # We want the include guards to be adjusted too. + FROM=`echo "$from" | sed \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'\ + -e 's/[^ABCDEFGHIJKLMNOPQRSTUVWXYZ]/_/g'` + TARGET=`echo "$2" | sed \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'\ + -e 's/[^ABCDEFGHIJKLMNOPQRSTUVWXYZ]/_/g'` + + sed -e "/^#/!b" -e "s,$input_rx,," -e "s,$from,$2," \ + -e "s,$FROM,$TARGET," "$from" >"$target" || ret=$? + + # Check whether header files must be updated. + if test $first = no; then + if test -f "$realtarget" && cmp -s "$realtarget" "$target"; then + echo "$2" is unchanged + rm -f "$target" + else + echo updating "$2" + mv -f "$target" "$realtarget" + fi + fi + else + # A missing file is only an error for the first file. This + # is a blatant hack to let us support using "yacc -d". If -d + # is not specified, we don't want an error when the header + # file is "missing". + if test $first = yes; then + ret=1 + fi + fi + shift + shift + first=no + done +else + ret=$? +fi + +# Remove the directory. +cd .. +rm -rf $dirname + +exit $ret + +# Local Variables: +# mode: shell-script +# sh-indentation: 2 +# eval: (add-hook 'write-file-hooks 'time-stamp) +# time-stamp-start: "scriptversion=" +# time-stamp-format: "%:y-%02m-%02d.%02H" +# time-stamp-time-zone: "UTC" +# time-stamp-end: "; # UTC" +# End: diff -urN src/usr.sbin/ntp/Makefile src.ntp/usr.sbin/ntp/Makefile --- src/usr.sbin/ntp/Makefile 2009-12-15 15:59:58.000000000 +0100 +++ src.ntp/usr.sbin/ntp/Makefile 2010-07-22 01:08:30.000000000 +0200 @@ -1,7 +1,7 @@ # Makefile for ntpd. # $FreeBSD: src/usr.sbin/ntp/Makefile,v 1.14 2009/12/15 14:59:58 roberto Exp $ -SUBDIR= libopts libntp libparse ntpd ntpdc ntpq ntpdate \ +SUBDIR= libopts libntp libparse ntpd ntpdate ntpdc ntpq \ ntptime ntp-keygen sntp SUBDIR+= doc diff -urN src/usr.sbin/ntp/config.h src.ntp/usr.sbin/ntp/config.h --- src/usr.sbin/ntp/config.h 2009-12-26 19:32:35.000000000 +0100 +++ src.ntp/usr.sbin/ntp/config.h 2010-07-22 01:08:30.000000000 +0200 @@ -1,6 +1,8 @@ -/* config.h. Generated by configure. */ +/* config.h. Generated from config.h.in by configure. */ /* config.h.in. Generated from configure.ac by autoheader. */ -/* $FreeBSD: src/usr.sbin/ntp/config.h,v 1.17 2009/12/26 18:32:35 ed Exp $ */ + +/* Define if building universal (internal helper macro) */ +/* #undef AC_APPLE_UNIVERSAL_BUILD */ /* Is adjtime() accurate? */ /* #undef ADJTIME_IS_ACCURATE */ @@ -161,7 +163,7 @@ /* Zyfer GPStarplus */ /* #undef CLOCK_ZYFER */ -/* Enable debugging? */ +/* Enable ntpd debugging code? */ /* #undef DEBUG */ /* Enable processing time debugging? */ @@ -266,6 +268,12 @@ /* What is the fallback value for HZ? */ #define DEFAULT_HZ 100 +/* Directory separator character, usually / or \\ */ +#define DIR_SEP '/' + +/* use old autokey session key behavior? */ +/* #undef DISABLE_BUG1243_FIX */ + /* synch TODR hourly? */ /* #undef DOSYNCTODR */ @@ -278,6 +286,9 @@ /* fopen(3) accepts a 't' in the mode flag */ #define FOPEN_TEXT_FLAG "t" +/* Force deferred DNS lookups? */ +/* #undef FORCE_DEFER_DNS */ + /* force ntpdate to step the clock if !defined(STEP_SLEW) ? */ /* #undef FORCE_NTPDATE_STEP */ @@ -291,7 +302,7 @@ #define HAVE_ARPA_NAMESER_H 1 /* Do we have audio support? */ -#define HAVE_AUDIO 1 +#define HAVE_AUDIO /**/ /* Define to 1 if you have the header file. */ /* #undef HAVE_BSTRING_H */ @@ -333,18 +344,15 @@ /* Define to 1 if you have the header file. */ #define HAVE_ERRNO_H 1 -/* Define to 1 if you have the `EVP_md2' function. */ -/* #undef HAVE_EVP_MD2 */ - -/* Define to 1 if you have the `EVP_mdc2' function. */ -/* #undef HAVE_EVP_MDC2 */ - /* Define to 1 if you have the header file. */ #define HAVE_FCNTL_H 1 /* Define to 1 if you have the `finite' function. */ /* #undef HAVE_FINITE */ +/* Define to 1 if you have the `fork' function. */ +#define HAVE_FORK 1 + /* Define to 1 if you have the `getbootfile' function. */ #define HAVE_GETBOOTFILE 1 @@ -357,12 +365,21 @@ /* Define to 1 if you have the `getifaddrs' function. */ #define HAVE_GETIFADDRS 1 +/* Define to 1 if you have the `getpassphrase' function. */ +/* #undef HAVE_GETPASSPHRASE */ + /* Define to 1 if you have the `getrusage' function. */ #define HAVE_GETRUSAGE 1 /* Define to 1 if you have the `getuid' function. */ #define HAVE_GETUID 1 +/* Define to 1 if you have the header file. */ +#define HAVE_HISTEDIT_H 1 + +/* Define to 1 if you have the header file. */ +/* #undef HAVE_HISTORY_H */ + /* Define to 1 if you have the `hstrerror' function. */ #define HAVE_HSTRERROR 1 @@ -372,9 +389,12 @@ /* Define to 1 if you have the header file. */ #define HAVE_IEEEFP_H 1 -/* ISC: Use iflist_sysctl? */ +/* have iflist_sysctl? */ #define HAVE_IFLIST_SYSCTL 1 +/* inline keyword or macro available */ +#define HAVE_INLINE 1 + /* Define to 1 if the system has the type `int16_t'. */ #define HAVE_INT16_T 1 @@ -390,24 +410,21 @@ /* Define to 1 if you have the header file. */ #define HAVE_INTTYPES_H 1 +/* Do we have IPTOS support? */ +#define HAVE_IPTOS_SUPPORT 1 + /* Define to 1 if you have the `isfinite' function. */ #define HAVE_ISFINITE 1 +/* Define to 1 if you have the header file. */ +#define HAVE_KVM_H 1 + /* Define to 1 if you have the `kvm_open' function. */ #define HAVE_KVM_OPEN 1 -/* Define to 1 if you have the `K_open' function. */ -/* #undef HAVE_K_OPEN */ - /* Define to 1 if you have the `advapi32' library (-ladvapi32). */ /* #undef HAVE_LIBADVAPI32 */ -/* Do we have the curses library? */ -/* #undef HAVE_LIBCURSES */ - -/* Do we have the edit library? */ -/* #undef HAVE_LIBEDIT */ - /* Define to 1 if you have the `elf' library (-lelf). */ #define HAVE_LIBELF 1 @@ -423,35 +440,23 @@ /* Define to 1 if you have the `ld' library (-lld). */ /* #undef HAVE_LIBLD */ -/* Define to 1 if you have the `md' library (-lmd). */ -#define HAVE_LIBMD 1 - -/* Define to 1 if you have the `md5' library (-lmd5). */ -/* #undef HAVE_LIBMD5 */ - /* Define to 1 if you have the `mld' library (-lmld). */ /* #undef HAVE_LIBMLD */ -/* Define to 1 if you have the `nsl' library (-lnsl). */ -/* #undef HAVE_LIBNSL */ +/* Define to 1 if you have the `netsnmp' library (-lnetsnmp). */ +/* #undef HAVE_LIBNETSNMP */ /* Define to 1 if you have the `posix4' library (-lposix4). */ /* #undef HAVE_LIBPOSIX4 */ -/* Define to 1 if you have the `readline' library (-lreadline). */ -/* #undef HAVE_LIBREADLINE */ +/* Define to 1 if you have the `resolv' library (-lresolv). */ +/* #undef HAVE_LIBRESOLV */ /* Define to 1 if you have the `rt' library (-lrt). */ #define HAVE_LIBRT 1 -/* Define to 1 if you have the `socket' library (-lsocket). */ -/* #undef HAVE_LIBSOCKET */ - -/* Define to 1 if you have the `syslog' library (-lsyslog). */ -/* #undef HAVE_LIBSYSLOG */ - -/* Define to 1 if you have the `xnet' library (-lxnet). */ -/* #undef HAVE_LIBXNET */ +/* Define to 1 if you have the header file. */ +/* #undef HAVE_LIBSCF_H */ /* Define to 1 if you have the header file. */ #define HAVE_LIMITS_H 1 @@ -496,9 +501,7 @@ #define HAVE_MKTIME 1 /* Define to 1 if you have the `mlockall' function. */ -#if __FreeBSD_version >= 500102 #define HAVE_MLOCKALL 1 -#endif /* Define to 1 if you have the `mmap' function. */ #define HAVE_MMAP 1 @@ -548,9 +551,15 @@ /* Define to 1 if you have the `ntp_gettime' function. */ #define HAVE_NTP_GETTIME 1 +/* Do we want support for Samba's signing daemon? */ +/* #undef HAVE_NTP_SIGND */ + /* Define this if pathfind(3) works */ /* #undef HAVE_PATHFIND */ +/* Define to 1 if the system has the type `pid_t'. */ +#define HAVE_PID_T 1 + /* Define to 1 if you have the `plock' function. */ /* #undef HAVE_PLOCK */ @@ -560,20 +569,23 @@ /* Do we have the PPS API per the Draft RFC? */ #define HAVE_PPSAPI 1 -/* Are function prototypes OK? */ -#define HAVE_PROTOTYPES 1 - /* Define to 1 if you have the `pututline' function. */ /* #undef HAVE_PUTUTLINE */ /* Define to 1 if you have the `pututxline' function. */ -/* #undef HAVE_PUTUTXLINE */ +#define HAVE_PUTUTXLINE 1 + +/* Define to 1 if you have the header file. */ +/* #undef HAVE_READLINE_H */ + +/* Define if your readline library has \`add_history' */ +/* #undef HAVE_READLINE_HISTORY */ /* Define to 1 if you have the header file. */ -/* #undef HAVE_READLINE_HISTORY_H */ +#define HAVE_READLINE_HISTORY_H 1 /* Define to 1 if you have the header file. */ -/* #undef HAVE_READLINE_READLINE_H */ +#define HAVE_READLINE_READLINE_H 1 /* Define to 1 if you have the `readlink' function. */ #define HAVE_READLINK 1 @@ -587,20 +599,26 @@ /* Define to 1 if you have the header file. */ #define HAVE_RESOLV_H 1 +/* Define to 1 if you have the `res_init' function. */ +#define HAVE_RES_INIT 1 + +/* Do we have Linux routing socket? */ +/* #undef HAVE_RTNETLINK */ + /* Define to 1 if you have the `rtprio' function. */ #define HAVE_RTPRIO 1 -/* Should be obvious... */ -#define HAVE_SA_LEN_IN_STRUCT_SOCKADDR 1 +/* Define to 1 if you have the header file. */ +#define HAVE_RUNETYPE_H 1 /* Obvious... */ #define HAVE_SA_SIGACTION_IN_STRUCT_SIGACTION 1 /* Define to 1 if you have the header file. */ -/* #undef HAVE_SCHED_H */ +#define HAVE_SCHED_H 1 /* Define to 1 if you have the `sched_setscheduler' function. */ -/* #undef HAVE_SCHED_SETSCHEDULER */ +#define HAVE_SCHED_SETSCHEDULER 1 /* Define to 1 if you have the header file. */ #define HAVE_SETJMP_H 1 @@ -639,7 +657,7 @@ /* #undef HAVE_SIGNALED_IO */ /* Define to 1 if you have the `sigset' function. */ -/* #undef HAVE_SIGSET */ +#define HAVE_SIGSET 1 /* Define to 1 if you have the `sigsuspend' function. */ #define HAVE_SIGSUSPEND 1 @@ -647,14 +665,14 @@ /* Define to 1 if you have the `sigvec' function. */ #define HAVE_SIGVEC 1 +/* Define to 1 if the system has the type `size_t'. */ +#define HAVE_SIZE_T 1 + /* Define to 1 if you have the `snprintf' function. */ #define HAVE_SNPRINTF 1 -/* Does struct sockaddr_storage have ss_family? */ -#define HAVE_SS_FAMILY_IN_SS 1 - -/* Does struct sockaddr_storage have ss_len? */ -#define HAVE_SS_LEN_IN_SS 1 +/* Are Solaris privileges available? */ +/* #undef HAVE_SOLARIS_PRIVS */ /* Define to 1 if you have the header file. */ #define HAVE_STDARG_H 1 @@ -689,13 +707,16 @@ /* Define to 1 if you have the `strrchr' function. */ #define HAVE_STRRCHR 1 +/* Define to 1 if you have the `strsignal' function. */ +#define HAVE_STRSIGNAL 1 + /* Define to 1 if you have the `strstr' function. */ #define HAVE_STRSTR 1 /* Do we have struct ntptimeval? */ #define HAVE_STRUCT_NTPTIMEVAL 1 -/* Define to 1 if `time.tv_nsec' is member of `struct ntptimeval'. */ +/* Define to 1 if `time.tv_nsec' is a member of `struct ntptimeval'. */ #define HAVE_STRUCT_NTPTIMEVAL_TIME_TV_NSEC 1 /* Does a system header define struct ppsclockev? */ @@ -704,9 +725,6 @@ /* Do we have struct snd_size? */ #define HAVE_STRUCT_SND_SIZE 1 -/* Define to 1 if `sin6_scope_id' is member of `struct sockaddr_in6'. */ -#define HAVE_STRUCT_SOCKADDR_IN6_SIN6_SCOPE_ID 1 - /* Does a system header define struct sockaddr_storage? */ #define HAVE_STRUCT_SOCKADDR_STORAGE 1 @@ -757,7 +775,7 @@ /* #undef HAVE_SYS_LIMITS_H */ /* Define to 1 if you have the header file. */ -/* #undef HAVE_SYS_LOCK_H */ +#define HAVE_SYS_LOCK_H 1 /* Define to 1 if you have the header file. */ #define HAVE_SYS_MMAN_H 1 @@ -943,10 +961,10 @@ /* Define to 1 if you have the header file. */ #define HAVE_UTIME_H 1 -/* Define to 1 if you have the header file. */ -/* #undef HAVE_UTMPX_H */ +/* Define HAVE_UTMPX_H to 1 if you have the header file. */ +#define HAVE_UTMPX_H 1 -/* Define to 1 if you have the header file. */ +/* Define HAVE_UTMP_H to 1 if you have the header file */ /* #undef HAVE_UTMP_H */ /* Define to 1 if you have the header file. */ @@ -955,6 +973,12 @@ /* Define to 1 if you have the header file. */ /* #undef HAVE_VARARGS_H */ +/* Define to 1 if you have the `vfork' function. */ +#define HAVE_VFORK 1 + +/* Define to 1 if you have the header file. */ +/* #undef HAVE_VFORK_H */ + /* Define to 1 if you have the `vprintf' function. */ #define HAVE_VPRINTF 1 @@ -964,6 +988,21 @@ /* Define to 1 if you have the `vsprintf' function. */ #define HAVE_VSPRINTF 1 +/* Define to 1 if you have the header file. */ +#define HAVE_WCHAR_H 1 + +/* Define to 1 if the system has the type `wchar_t'. */ +#define HAVE_WCHAR_T 1 + +/* Define to 1 if the system has the type `wint_t'. */ +#define HAVE_WINT_T 1 + +/* Define to 1 if `fork' works. */ +#define HAVE_WORKING_FORK 1 + +/* Define to 1 if `vfork' works. */ +#define HAVE_WORKING_VFORK 1 + /* Define to 1 if you have the header file. */ /* #undef HAVE__SYS_SYNC_QUEUE_H */ @@ -976,12 +1015,34 @@ /* Define to 1 if you have the `__ntp_gettime' function. */ /* #undef HAVE___NTP_GETTIME */ +/* Define to 1 if you have the `__res_init' function. */ +#define HAVE___RES_INIT 1 + /* Does struct sockaddr_storage have __ss_family? */ /* #undef HAVE___SS_FAMILY_IN_SS */ + + /* Handle sockaddr_storage.__ss_family */ + #ifdef HAVE___SS_FAMILY_IN_SS + # define ss_family __ss_family + #endif /* HAVE___SS_FAMILY_IN_SS */ + + + /* Does struct sockaddr_storage have __ss_len? */ /* #undef HAVE___SS_LEN_IN_SS */ + + /* Handle sockaddr_storage.__ss_len */ + #ifdef HAVE___SS_LEN_IN_SS + # define ss_len __ss_len + #endif /* HAVE___SS_LEN_IN_SS */ + + + +/* [Retry queries on _any_ DNS error?] */ +/* #undef IGNORE_DNS_ERRORS */ + /* Should we use the IRIG sawtooth filter? */ /* #undef IRIG_SUCKS */ @@ -991,34 +1052,34 @@ /* ISC: do we have if_nametoindex()? */ #define ISC_PLATFORM_HAVEIFNAMETOINDEX 1 -/* ISC: have struct if_laddrconf? */ +/* have struct if_laddrconf? */ /* #undef ISC_PLATFORM_HAVEIF_LADDRCONF */ -/* ISC: have struct if_laddrreq? */ +/* have struct if_laddrreq? */ /* #undef ISC_PLATFORM_HAVEIF_LADDRREQ */ -/* ISC: Have struct in6_pktinfo? */ -#define ISC_PLATFORM_HAVEIN6PKTINFO - -/* ISC: Have IPv6? */ -#define ISC_PLATFORM_HAVEIPV6 +/* have struct in6_pktinfo? */ +#define ISC_PLATFORM_HAVEIN6PKTINFO /**/ -/* ISC: struct sockaddr as sa_len? */ -#define ISC_PLATFORM_HAVESALEN +/* have IPv6? */ +#define ISC_PLATFORM_HAVEIPV6 /**/ -/* ISC: Have sin6_scope_id? */ -#define ISC_PLATFORM_HAVESCOPEID +/* struct sockaddr has sa_len? */ +#define ISC_PLATFORM_HAVESALEN /**/ -/* ISC: provide inet_aton() */ -/* #undef ISC_PLATFORM_NEEDATON */ +/* have sin6_scope_id? */ +#define ISC_PLATFORM_HAVESCOPEID /**/ -/* ISC: Need in6addr_any? */ +/* missing in6addr_any? */ /* #undef ISC_PLATFORM_NEEDIN6ADDRANY */ +/* Do we need netinet6/in6.h? */ +/* #undef ISC_PLATFORM_NEEDNETINET6IN6H */ + /* ISC: provide inet_ntop() */ /* #undef ISC_PLATFORM_NEEDNTOP */ -/* Do we need our own in_port_t? */ +/* Declare in_port_t? */ /* #undef ISC_PLATFORM_NEEDPORTT */ /* ISC: provide inet_pton() */ @@ -1045,7 +1106,7 @@ /* Should we align with the NIST lockclock scheme? */ /* #undef LOCKCLOCK */ -/* Does the kernel support multicasting IP? */ +/* Does the target support multicast IP? */ #define MCAST 1 /* Should we recommend a minimum value for tickadj? */ @@ -1057,6 +1118,9 @@ /* Do we want the HPUX FindConfig()? */ /* #undef NEED_HPUX_FINDCONFIG */ +/* We need to provide netsnmp_daemonize() */ +/* #undef NEED_NETSNMP_DAEMONIZE */ + /* Do we need the qnx adjtime call? */ /* #undef NEED_QNX_ADJTIME */ @@ -1088,11 +1152,14 @@ /* #undef NO_OPTION_NAME_WARNINGS */ /* Is there a problem using PARENB and IGNPAR (IRIX)? */ -#define NO_PARENB_IGNPAR 1 +/* #undef NO_PARENB_IGNPAR */ /* Default location of crypto key info */ #define NTP_KEYSDIR "/etc/ntp" +/* Path to sign daemon rendezvous socket */ +/* #undef NTP_SIGND_PATH */ + /* Do we have ntp_{adj,get}time in libc? */ #define NTP_SYSCALLS_LIBC 1 @@ -1103,6 +1170,7 @@ #define ONCORE_SHMEM_STATUS 1 /* Use OpenSSL? */ +/* This is picked up from the command line in case we want OpenSSL */ /* #undef OPENSSL */ /* Should we open the broadcast socket? */ @@ -1122,26 +1190,26 @@ #define PACKAGE "ntp" /* Define to the address where bug reports for this package should be sent. */ -#define PACKAGE_BUGREPORT "roberto@FreeBSD.org" +#define PACKAGE_BUGREPORT "niclas.zeising@gmail.com" /* Define to the full name of this package. */ #define PACKAGE_NAME "ntp" /* Define to the full name and version of this package. */ -#define PACKAGE_STRING "ntp 4.2.4p5" +#define PACKAGE_STRING "ntp 4.2.6p2" /* Define to the one symbol short name of this package. */ #define PACKAGE_TARNAME "ntp" +/* Define to the home page for this package. */ +#define PACKAGE_URL "" + /* Define to the version of this package. */ -#define PACKAGE_VERSION "4.2.4p5" +#define PACKAGE_VERSION "4.2.6p2" /* Do we have the ppsclock streams module? */ /* #undef PPS */ -/* PPS auxiliary interface for ATOM? */ -#define PPS_SAMPLE 1 - /* PARSE kernel PLL PPS support */ /* #undef PPS_SYNC */ @@ -1151,9 +1219,6 @@ /* Preset a value for 'tickadj'? */ #define PRESET_TICKADJ 500/hz -/* Define to 1 if the C compiler supports function prototypes. */ -#define PROTOTYPES 1 - /* Does qsort expect to work on "void *" stuff? */ #define QSORT_USES_VOID_P 1 @@ -1172,33 +1237,36 @@ /* Define as the return type of signal handlers (`int' or `void'). */ #define RETSIGTYPE void +/* saveconfig mechanism */ +#define SAVECONFIG 1 + /* Do we want the SCO clock hacks? */ /* #undef SCO5_CLOCK */ -/* The size of a `char*', as computed by sizeof. */ +/* The size of `char*', as computed by sizeof. */ #if defined(__alpha__) || defined(__ia64__) || defined(__sparc64__) || defined(__amd64__) #define SIZEOF_CHARP 8 #else #define SIZEOF_CHARP 4 #endif -/* The size of a `int', as computed by sizeof. */ +/* The size of `int', as computed by sizeof. */ #define SIZEOF_INT 4 -/* The size of a `long', as computed by sizeof. */ +/* The size of `long', as computed by sizeof. */ #if defined(__alpha__) || defined(__ia64__) || defined(__sparc64__) || defined(__amd64__) #define SIZEOF_LONG 8 #else #define SIZEOF_LONG 4 #endif -/* The size of a `short', as computed by sizeof. */ +/* The size of `short', as computed by sizeof. */ #define SIZEOF_SHORT 2 -/* The size of a `signed char', as computed by sizeof. */ +/* The size of `signed char', as computed by sizeof. */ #define SIZEOF_SIGNED_CHAR 1 -/* The size of a `time_t', as computed by sizeof. */ +/* The size of `time_t', as computed by sizeof */ #if defined(__alpha__) || defined(__ia64__) || defined(__sparc64__) || defined(__amd64__) #define SIZEOF_TIME_T 8 #else @@ -1223,14 +1291,16 @@ /* canonical system (cpu-vendor-os) of where we should run */ #if defined(__alpha__) #define STR_SYSTEM "alpha-undermydesk-freebsd" -#elif defined(__sparc64__) -#define STR_SYSTEM "sparc64-undermydesk-freebsd" #elif defined(__amd64__) #define STR_SYSTEM "amd64-undermydesk-freebsd" #elif defined(__ia64__) #define STR_SYSTEM "ia64-undermydesk-freebsd" -#else +#elif defined(__sparc64__) +#define STR_SYSTEM "sparc64-undermydesk-freebsd" +#elif defined(__i386__) #define STR_SYSTEM "i386-undermydesk-freebsd" +#else +#define STR_SYSTEM "unknown-undermydesk-freebsd" #endif /* Buggy syscall() (Solaris2.4)? */ @@ -1269,12 +1339,31 @@ /* Do we set process groups with -pid? */ /* #undef UDP_BACKWARDS_SETOWN */ -/* How do we create unsigned long constants? */ -#define ULONG_CONST(a) a ## UL - /* Must we have a CTTY for fsetown? */ #define USE_FSETOWNCTTY 1 +/* Enable extensions on AIX 3, Interix. */ +#ifndef _ALL_SOURCE +# define _ALL_SOURCE 1 +#endif +/* Enable GNU extensions on systems that have them. */ +#ifndef _GNU_SOURCE +# define _GNU_SOURCE 1 +#endif +/* Enable threading extensions on Solaris. */ +#ifndef _POSIX_PTHREAD_SEMANTICS +# define _POSIX_PTHREAD_SEMANTICS 1 +#endif +/* Enable extensions on HP NonStop. */ +#ifndef _TANDEM_SOURCE +# define _TANDEM_SOURCE 1 +#endif +/* Enable general extensions on Solaris. */ +#ifndef __EXTENSIONS__ +# define __EXTENSIONS__ 1 +#endif + + /* Can we use SIGPOLL for tty IO? */ /* #undef USE_TTY_SIGPOLL */ @@ -1282,35 +1371,18 @@ /* #undef USE_UDP_SIGPOLL */ /* Version number of package */ -#define VERSION "4.2.4p5" +#define VERSION "4.2.6p2" -/* ISC: Want IPv6? */ -#define WANT_IPV6 1 +/* configure --enable-ipv6 */ +#define WANT_IPV6 /**/ /* Define this if a working libregex can be found */ #define WITH_LIBREGEX 1 -/* Define to 1 if your processor stores words with the most significant byte - first (like Motorola and SPARC, unlike Intel and VAX). */ +/* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most + significant byte first (like Motorola and SPARC, unlike Intel). */ #if defined(__sparc64__) -#define WORDS_BIGENDIAN 1 -#endif - -/* Handle ss_family */ -#if !defined(HAVE_SS_FAMILY_IN_SS) && defined(HAVE___SS_FAMILY_IN_SS) -# define ss_family __ss_family -#endif /* !defined(HAVE_SS_FAMILY_IN_SS) && defined(HAVE_SA_FAMILY_IN_SS) */ - -/* Handle ss_len */ -#if !defined(HAVE_SS_LEN_IN_SS) && defined(HAVE___SS_LEN_IN_SS) -# define ss_len __ss_len -#endif /* !defined(HAVE_SS_LEN_IN_SS) && defined(HAVE_SA_LEN_IN_SS) */ - -/* Define to 1 if on AIX 3. - System headers sometimes define this. - We just want to avoid a redefinition error message. */ -#ifndef _ALL_SOURCE -/* # undef _ALL_SOURCE */ +#define WORDS_BIGENDIAN 1 #endif /* Define to 1 if on MINIX. */ @@ -1328,9 +1400,6 @@ /* # undef __CHAR_UNSIGNED__ */ #endif -/* Define like PROTOTYPES; this can be used by system headers. */ -#define __PROTOTYPES 1 - /* Define to empty if `const' does not conform to ANSI C. */ /* #undef const */ @@ -1343,10 +1412,13 @@ /* #undef inline */ #endif -/* Define to `long' if does not define. */ +/* Define to `long int' if does not define. */ /* #undef off_t */ -/* Define to `unsigned' if does not define. */ +/* Define to `int' if does not define. */ +/* #undef pid_t */ + +/* Define to `unsigned int' if does not define. */ /* #undef size_t */ /* Define to `long' if does not define. */ @@ -1355,8 +1427,8 @@ /* Define to `int' if doesn't define. */ /* #undef uid_t */ -/* Alternate uintptr_t for systems without it. */ -/* #undef uintptr_t */ +/* Define as `fork' if `vfork' does not work. */ +/* #undef vfork */ /* Does the compiler like "volatile"? */ /* #undef volatile */ diff -urN src/usr.sbin/ntp/config.mk src.ntp/usr.sbin/ntp/config.mk --- src/usr.sbin/ntp/config.mk 1970-01-01 01:00:00.000000000 +0100 +++ src.ntp/usr.sbin/ntp/config.mk 2010-07-22 01:09:28.000000000 +0200 @@ -0,0 +1,13 @@ +# $FreeBSD $ + +.include + +# Use the right version of the atomic.h file from lib/isc +# This is shamelessly stolen from src/lib/bind/config.mk +.if ${MACHINE_ARCH} == amd64 +ISC_ATOMIC_ARCH= x86_64 +.elif ${MACHINE_ARCH} == i386 +ISC_ATOMIC_ARCH= x86_32 +.else +ISC_ATOMIC_ARCH= ${MACHINE_CPUARCH} +.endif diff -urN src/usr.sbin/ntp/doc/Makefile src.ntp/usr.sbin/ntp/doc/Makefile --- src/usr.sbin/ntp/doc/Makefile 2010-01-03 23:29:06.000000000 +0100 +++ src.ntp/usr.sbin/ntp/doc/Makefile 2010-07-22 01:08:30.000000000 +0200 @@ -2,32 +2,7 @@ .include -FILESDIR= ${SHAREDIR}/doc/ntp - -.if ${MK_HTML} != "no" -FILES= accopt.html assoc.html audio.html authopt.html build.html \ - clockopt.html \ - config.html confopt.html copyright.html debug.html driver1.html \ - driver10.html driver11.html driver12.html driver16.html driver18.html \ - driver19.html driver2.html driver20.html driver22.html \ - driver26.html driver27.html driver28.html driver29.html \ - driver3.html driver30.html driver32.html driver33.html driver34.html \ - driver35.html driver36.html driver37.html \ - driver4.html driver5.html driver6.html driver7.html driver8.html \ - driver9.html extern.html hints.html \ - howto.html index.html kern.html \ - ldisc.html measure.html miscopt.html monopt.html mx4200data.html \ - notes.html ntpd.html ntpdate.html ntpdc.html ntpq.html ntptime.html \ - ntptrace.html parsedata.html parsenew.html patches.html porting.html \ - pps.html prefer.html quick.html rdebug.html refclock.html \ - release.html tickadj.html -.endif - MAN= ntp.conf.5 ntp.keys.5 MAN+= ntp-keygen.8 ntpd.8 ntpdate.8 ntpdc.8 ntpq.8 ntptime.8 -.PATH: ${.CURDIR}/../../../contrib/ntp/html \ - ${.CURDIR}/../../../contrib/ntp/html/build \ - ${.CURDIR}/../../../contrib/ntp/html/drivers - .include diff -urN src/usr.sbin/ntp/libntp/Makefile src.ntp/usr.sbin/ntp/libntp/Makefile --- src/usr.sbin/ntp/libntp/Makefile 2008-08-25 01:28:56.000000000 +0200 +++ src.ntp/usr.sbin/ntp/libntp/Makefile 2010-07-22 01:08:30.000000000 +0200 @@ -1,37 +1,57 @@ # $FreeBSD: src/usr.sbin/ntp/libntp/Makefile,v 1.12 2008/08/24 23:28:56 roberto Exp $ +# -.PATH: ${.CURDIR}/../../../contrib/ntp/libntp \ - ${.CURDIR}/../../../contrib/ntp/libisc +NTP_DIR= ${.CURDIR}/../../../contrib/ntp +SRC_DIR= ${NTP_DIR}/libntp -LIB= ntp +LIB= ntp INTERNALLIB= +SRCS= -NTP_SRCS= a_md5encrypt.c adjtime.c atoint.c atolfp.c \ - atouint.c audio.c authkeys.c \ - authreadkeys.c authusekey.c \ - buftvtots.c caljulian.c caltontp.c \ - calyearstart.c clocktime.c clocktypes.c decodenetnum.c \ - dofptoa.c dolfptoa.c emalloc.c findconfig.c \ - fptoa.c fptoms.c getopt.c \ - hextoint.c hextolfp.c humandate.c icom.c \ - inttoa.c iosignal.c lib_strbuf.c \ - machines.c md5c.c memmove.c \ - mfptoa.c mfptoms.c mktime.c modetoa.c \ - mstolfp.c ntp_random.c \ - msutotsf.c msyslog.c netof.c ntp_rfc2553.c \ - numtoa.c numtohost.c octtoint.c prettydate.c \ - recvbuff.c refnumtoa.c snprintf.c socktoa.c \ - socktohost.c strstr.c systime.c statestr.c \ - strerror.c syssignal.c tsftomsu.c tstotv.c \ - tvtoa.c tvtots.c uglydate.c uinttoa.c \ - utvtoa.c ymd2yd.c - -ISC_SRCS= assertions.c error.c inet_ntop.c inet_pton.c interfaceiter.c \ - isc_strerror.c lib.c mem.c msgcat.c net.c netscope.c netaddr.c \ - sockaddr.c +.include "${.CURDIR}/../config.mk" -SRCS= ${NTP_SRCS} ${ISC_SRCS} - -CFLAGS+= -I${.CURDIR}/../../../contrib/ntp/include -I${.CURDIR}/../ +.PATH: ${SRC_DIR} +SRCS+= a_md5encrypt.c adjtime.c atoint.c atolfp.c \ + atouint.c audio.c authkeys.c authreadkeys.c \ + authusekey.c bsd_strerror.c buftvtots.c caljulian.c \ + caltontp.c calyearstart.c clocktime.c clocktypes.c \ + decodenetnum.c dofptoa.c dolfptoa.c emalloc.c \ + findconfig.c fptoa.c fptoms.c getopt.c \ + hextoint.c hextolfp.c humandate.c icom.c \ + inttoa.c iosignal.c lib_strbuf.c machines.c \ + memmove.c mfptoa.c mfptoms.c mktime.c \ + modetoa.c mstolfp.c msutotsf.c msyslog.c \ + netof.c ntp_lineedit.c ntp_random.c ntp_rfc2553.c \ + numtoa.c numtohost.c octtoint.c prettydate.c \ + recvbuff.c refnumtoa.c snprintf.c socktoa.c \ + socktohost.c ssl_init.c statestr.c strdup.c \ + strstr.c systime.c syssignal.c tsftomsu.c \ + tstotv.c tvtots.c uglydate.c uinttoa.c \ + ymd2yd.c + +.PATH: ${NTP_DIR}/lib/isc +SRCS+= assertions.c buffer.c error.c event.c \ + inet_ntop.c inet_pton.c lib.c log.c \ + md5.c netaddr.c netscope.c ondestroy.c \ + random.c result.c task.c sockaddr.c + +.PATH: ${NTP_DIR}/lib/isc/nls +SRCS+= msgcat.c + +.PATH: ${NTP_DIR}/lib/isc/nothreads +SRCS+= condition.c thread.c + +.PATH: ${NTP_DIR}/lib/isc/unix +SRCS+= dir.c errno2result.c file.c \ + interfaceiter.c net.c stdio.c stdtime.c \ + strerror.c time.c + + +CFLAGS+= -I${NTP_DIR}/include +CFLAGS+= -I${NTP_DIR}/lib/isc/include +CFLAGS+= -I${NTP_DIR}/lib/isc/nothreads/include +CFLAGS+= -I${NTP_DIR}/lib/isc/unix/include +CFLAGS+= -I${NTP_DIR}/lib/isc/${ISC_ATMOIC_ARCH}/include +CFLAGS+= -I${.CURDIR}/../ .include diff -urN src/usr.sbin/ntp/libopts/Makefile src.ntp/usr.sbin/ntp/libopts/Makefile --- src/usr.sbin/ntp/libopts/Makefile 2008-08-22 22:04:35.000000000 +0200 +++ src.ntp/usr.sbin/ntp/libopts/Makefile 2010-07-22 01:08:30.000000000 +0200 @@ -1,13 +1,16 @@ # $FreeBSD: src/usr.sbin/ntp/libopts/Makefile,v 1.1 2008/08/22 20:04:35 roberto Exp $ -.PATH: ${.CURDIR}/../../../contrib/ntp/libopts +NTP_DIR= ${.CURDIR}/../../../contrib/ntp +SRC_DIR= ${NTP_DIR}/libopts LIB= opts INTERNALLIB= +.PATH: ${SRC_DIR} SRCS= libopts.c -CFLAGS+= -I${.CURDIR}/../../../contrib/ntp/include -I${.CURDIR}/../ \ - -I${.CURDIR}/../../../contrib/ntp/libopts +CFLAGS+= -I${NTP_DIR}/include +CFLAGS+= -I${NTP_DIR}/libopts +CFLAGS+= -I${.CURDIR}/../ .include diff -urN src/usr.sbin/ntp/libparse/Makefile src.ntp/usr.sbin/ntp/libparse/Makefile --- src/usr.sbin/ntp/libparse/Makefile 2008-08-22 18:00:48.000000000 +0200 +++ src.ntp/usr.sbin/ntp/libparse/Makefile 2010-07-22 01:08:30.000000000 +0200 @@ -1,16 +1,25 @@ # $FreeBSD: src/usr.sbin/ntp/libparse/Makefile,v 1.8 2008/08/22 16:00:48 roberto Exp $ -.PATH: ${.CURDIR}/../../../contrib/ntp/libparse +NTP_DIR= ${.CURDIR}/../../../contrib/ntp +SRC_DIR= ${NTP_DIR}/libparse LIB= parse INTERNALLIB= -SRCS= clk_computime.c clk_dcf7000.c clk_hopf6021.c clk_meinberg.c \ - clk_rawdcf.c clk_rcc8000.c clk_schmid.c clk_trimtaip.c \ - clk_trimtsip.c clk_varitext.c clk_wharton.c data_mbg.c \ - info_trimble.c parse.c parse_conf.c trim_info.c \ - binio.c gpstolfp.c +.include "${.CURDIR}/../config.mk" -CFLAGS+= -I${.CURDIR}/../../../contrib/ntp/include -I${.CURDIR}/../ +.PATH: ${SRC_DIR} +SRCS= binio.c clk_computime.c clk_dcf7000.c clk_hopf6021.c \ + clk_meinberg.c clk_rawdcf.c clk_rcc8000.c clk_schmid.c \ + clk_trimtaip.c clk_trimtsip.c clk_varitext.c clk_wharton.c \ + data_mbg.c gpstolfp.c ieee754io.c info_trimble.c\ + mfp_mul.c parse.c parse_conf.c trim_info.c + +CFLAGS+= -I${NTP_DIR}/include +CFLAGS+= -I${NTP_DIR}/lib/isc/include +CFLAGS+= -I${NTP_DIR}/lib/isc/unix/include +CFLAGS+= -I${NTP_DIR}/kernel +CFLAGS+= -I${NTP_DIR}/lib/isc/${ISC_ATOMIC_ARCH}/include +CFLAGS+= -I${.CURDIR}/../ .include diff -urN src/usr.sbin/ntp/ntp-keygen/Makefile src.ntp/usr.sbin/ntp/ntp-keygen/Makefile --- src/usr.sbin/ntp/ntp-keygen/Makefile 2008-08-22 18:00:48.000000000 +0200 +++ src.ntp/usr.sbin/ntp/ntp-keygen/Makefile 2010-07-22 01:08:30.000000000 +0200 @@ -4,14 +4,23 @@ .include -.PATH: ${.CURDIR}/../../../contrib/ntp/util \ - ${.CURDIR}/../../../contrib/ntp/ntpd +NTP_DIR= ${.CURDIR}/../../../contrib/ntp +SRC_DIR= ${NTP_DIR}/util + +.include "${.CURDIR}/../config.mk" + +.PATH: ${SRC_DIR} PROG= ntp-keygen SRCS= ntp-keygen.c ntp-keygen-opts.c -CFLAGS+= -I${.CURDIR}/../../../contrib/ntp/include -I${.CURDIR}/../ \ - -I${.CURDIR}/../../../contrib/ntp/libopts +CFLAGS+= -I${NTP_DIR}/include +CFLAGS+= -I${NTP_DIR}/libopts +CFLAGS+= -I${NTP_DIR}/lib/isc/include +CFLAGS+= -I${NTP_DIR}/lib/isc/nothread/include +CFLAGS+= -I${NTP_DIR}/lib/isc/unix/include +CFLAGS+= -I${NTP_DIR}/lib/isc/${ISC_ATOMIC_ARCH}/include +CFLAGS+= -I${.CURDIR}/../ DPADD= ${LIBNTP} ${LIBOPTS} LDADD= ${LIBNTP} ${LIBOPTS} diff -urN src/usr.sbin/ntp/ntpd/Makefile src.ntp/usr.sbin/ntp/ntpd/Makefile --- src/usr.sbin/ntp/ntpd/Makefile 2008-08-22 18:00:48.000000000 +0200 +++ src.ntp/usr.sbin/ntp/ntpd/Makefile 2010-07-22 01:08:30.000000000 +0200 @@ -4,33 +4,42 @@ .include -.PATH: ${.CURDIR}/../../../contrib/ntp/ntpd +NTP_DIR= ${.CURDIR}/../../../contrib/ntp +SRC_DIR= ${NTP_DIR}/ntpd + +.include "${.CURDIR}/../config.mk" PROG= ntpd -SRCS= cmd_args.c ntp_config.c \ - ntp_control.c ntp_crypto.c ntp_filegen.c \ - ntp_intres.c ntp_io.c ntp_loopfilter.c \ - ntp_monitor.c ntp_peer.c ntp_proto.c \ - ntp_refclock.c ntp_request.c \ - ntp_restrict.c ntp_timer.c ntp_util.c \ - ntpd.c refclock_acts.c refclock_arbiter.c \ - refclock_arc.c refclock_as2201.c refclock_atom.c \ - refclock_bancomm.c refclock_chronolog.c refclock_chu.c \ - refclock_conf.c refclock_datum.c refclock_dumbclock.c \ - refclock_fg.c refclock_gpsvme.c refclock_heath.c \ - refclock_hopfpci.c refclock_hopfser.c refclock_hpgps.c \ - refclock_irig.c refclock_jupiter.c refclock_leitch.c \ - refclock_local.c refclock_msfees.c refclock_mx4200.c \ - refclock_neoclock4x.c refclock_nmea.c refclock_oncore.c \ - refclock_palisade.c refclock_parse.c refclock_pcf.c \ - refclock_pst.c refclock_ripencc.c \ - refclock_shm.c refclock_tpro.c refclock_trak.c refclock_true.c \ - refclock_ulink.c refclock_wwv.c \ - refclock_wwvb.c ntpd-opts.c \ - version.c -CFLAGS+= -I${.CURDIR}/../../../contrib/ntp/include -I${.CURDIR}/../ \ - -I${.CURDIR}/../../../contrib/ntp/libopts -I${.CURDIR} +.PATH: ${SRC_DIR} +SRCS= cmd_args.c ntp_config.c ntp_control.c ntp_crypto.c \ + ntp_data_structures.c ntp_filegen.c ntp_intres.c \ + ntp_io.c ntp_loopfilter.c ntp_monitor.c \ + ntp_parser.c ntp_peer.c ntp_proto.c ntp_refclock.c \ + ntp_request.c ntp_restrict.c ntp_scanner.c ntp_signd.c \ + ntp_timer.c ntp_util.c ntpd.c ntpd-opts.c \ + refclock_acts.c refclock_arbiter.c refclock_arc.c \ + refclock_as2201.c refclock_atom.c refclock_bancomm.c \ + refclock_chronolog.c refclock_chu.c refclock_conf.c \ + refclock_datum.c refclock_dumbclock.c refclock_fg.c \ + refclock_gpsvme.c refclock_heath.c refclock_hopfser.c \ + refclock_hpgps.c refclock_irig.c refclock_jjy.c \ + refclock_jupiter.c refclock_leitch.c refclock_local.c \ + refclock_mx4200.c refclock_neoclock4x.c refclock_nmea.c \ + refclock_oncore.c refclock_palisade.c refclock_parse.c \ + refclock_pcf.c refclock_pst.c refclock_ripencc.c \ + refclock_shm.c refclock_tpro.c refclock_true.c \ + refclock_tt560.c refclock_ulink.c refclock_wwv.c \ + refclock_wwvb.c refclock_zyfer.c version.c + +CFLAGS+= -I${NTP_DIR}/include +CFLAGS+= -I${NTP_DIR}/libopts +CFLAGS+= -I${NTP_DIR}/lib/isc/include +CFLAGS+= -I${NTP_DIR}/lib/isc/nothreads/include +CFLAGS+= -I${NTP_DIR}/lib/isc/unix/include +CFLAGS+= -I${NTP_DIR}/lib/isc/${ISC_ATOMIC_ARCH}/include +CFLAGS+= -I${.CURDIR}/../ +CFLAGS+= -I${.CURDIR} DPADD= ${LIBPARSE} ${LIBNTP} ${LIBM} ${LIBMD} ${LIBRT} ${LIBOPTS} LDADD= ${LIBPARSE} ${LIBNTP} -lm -lmd -lrt ${LIBOPTS} diff -urN src/usr.sbin/ntp/ntpdate/Makefile src.ntp/usr.sbin/ntp/ntpdate/Makefile --- src/usr.sbin/ntp/ntpdate/Makefile 2008-08-22 18:00:48.000000000 +0200 +++ src.ntp/usr.sbin/ntp/ntpdate/Makefile 2010-07-22 01:08:30.000000000 +0200 @@ -1,16 +1,32 @@ # $FreeBSD: src/usr.sbin/ntp/ntpdate/Makefile,v 1.7 2008/08/22 16:00:48 roberto Exp $ -.PATH: ${.CURDIR}/../../../contrib/ntp/ntpdate +NO_MAN= + +NTP_DIR= ${.CURDIR}/../../../contrib/ntp +SRC_DIR= ${NTP_DIR}/ntpdate + +.include "${.CURDIR}/../config.mk" PROG= ntpdate -NO_MAN= + +.PATH: ${SRC_DIR} SRCS= ntpdate.c version.c -CFLAGS+= -I${.CURDIR}/../../../contrib/ntp/include -I${.CURDIR}/../ +CFLAGS+= -I${NTP_DIR}/include +CFLAGS+= -I${NTP_DIR}/lib/isc/include +CFLAGS+= -I${NTP_DIR}/lib/isc/nothreads/include +CFLAGS+= -I${NTP_DIR}/lib/isc/unix/include +CFLAGS+= -I${NTP_DIR}/lib/isc/${ISC_ATOMIC_ARCH}/include +CFLAGS+= -I${.CURDIR}/../ DPADD= ${LIBNTP} ${LIBM} ${LIBMD} ${LIBRT} LDADD= ${LIBNTP} -lm -lmd -lrt +.if ${MK_OPENSSL} != "no" && !defined(RELEASE_CRUNCH) +DPADD+= ${LIBCRYPTO} +LDADD+= -lcrypto +.endif + CLEANFILES+= .version version.c version.c: diff -urN src/usr.sbin/ntp/ntpdc/Makefile src.ntp/usr.sbin/ntp/ntpdc/Makefile --- src/usr.sbin/ntp/ntpdc/Makefile 2008-08-22 18:00:48.000000000 +0200 +++ src.ntp/usr.sbin/ntp/ntpdc/Makefile 2010-07-22 01:08:30.000000000 +0200 @@ -4,22 +4,38 @@ .include -.PATH: ${.CURDIR}/../../../contrib/ntp/ntpdc +NTP_DIR= ${.CURDIR}/../../../contrib/ntp/ +SRC_DIR= ${NTP_DIR}/ntpdc + +.include "${.CURDIR}/../config.mk" PROG= ntpdc + +.PATH: ${SRC_DIR} SRCS= ntpdc.c ntpdc_ops.c ntpdc-opts.c version.c -CFLAGS+= -I${.CURDIR}/../../../contrib/ntp/include -I${.CURDIR}/../ \ - -I${.CURDIR}/../../../contrib/ntp/libopts +CFLAGS+= -I${NTP_DIR}/include +CFLAGS+= -I${NTP_DIR}/libopts +CFLAGS+= -I${NTP_DIR}/lib/isc/include +CFLAGS+= -I${NTP_DIR}/lib/isc/nothread/include +CFLAGS+= -I${NTP_DIR}/lib/isc/unix/include +CFLAGS+= -I${NTP_DIR}/lib/isc/${ISC_ATOMIC_ARCH}/include +CFLAGS+= -I${.CURDIR}/../ -DPADD= ${LIBNTP} ${LIBM} ${LIBMD} ${LIBOPTS} -LDADD= ${LIBNTP} -lm -lmd ${LIBOPTS} +DPADD= ${LIBNTP} ${LIBEDIT} ${LIBM} ${LIBMD} ${LIBOPTS} +LDADD= ${LIBNTP} -ledit -lm -lmd ${LIBOPTS} -.if ${MK_GNU_SUPPORT} != "no" -DPADD+= ${LIBREADLINE} ${LIBTERMCAP} -LDADD+= -lreadline -ltermcap CFLAGS+= -DHAVE_LIBREADLINE -DHAVE_READLINE_HISTORY_H \ -DHAVE_READLINE_READLINE_H + +.if ${MK_GNU_SUPPORT} != "no" +DPADD+= ${LIBTERMCAP} +LDADD+= -ltermcap +.endif + +.if ${MK_OPENSSL} != "no" && !defined(RELEASE_CRUNCH) +DPADD+= ${LIBCRYPTO} +LDADD+= -lcrypto .endif CLEANFILES+= .version version.c diff -urN src/usr.sbin/ntp/ntpq/Makefile src.ntp/usr.sbin/ntp/ntpq/Makefile --- src/usr.sbin/ntp/ntpq/Makefile 2008-08-22 18:00:48.000000000 +0200 +++ src.ntp/usr.sbin/ntp/ntpq/Makefile 2010-07-22 01:08:30.000000000 +0200 @@ -4,24 +4,39 @@ .include -.PATH: ${.CURDIR}/../../../contrib/ntp/ntpq +NTP_DIR= ${.CURDIR}/../../../contrib/ntp +SRC_DIR= ${NTP_DIR}/ntpq + +.include "${.CURDIR}/../config.mk" BINDIR= /usr/bin PROG= ntpq -SRCS= ntpq.c ntpq-opts.c ntpq-subs.c version.c +.PATH: ${SRC_DIR} -CFLAGS+= -I${.CURDIR}/../../../contrib/ntp/include -I${.CURDIR}/../ \ - -I${.CURDIR}/../../../contrib/ntp/libopts +SRCS= ntpq.c ntpq-opts.c ntpq-subs.c version.c -DPADD= ${LIBNTP} ${LIBM} ${LIBMD} ${LIBOPTS} -LDADD= ${LIBNTP} -lm -lmd ${LIBOPTS} +CFLAGS+= -I${NTP_DIR}/include +CFLAGS+= -I${NTP_DIR}/libopts +CFLAGS+= -I${NTP_DIR}/lib/isc/include +CFLAGS+= -I${NTP_DIR}/lib/isc/nothreads/include +CFLAGS+= -I${NTP_DIR}/lib/isc/unix/include +CFLAGS+= -I${NTP_DIR}/lib/isc/${ISC_ATOMIC_ARCH}/include +CFLAGS+= -I${.CURDIR}/../ -.if ${MK_GNU_SUPPORT} != "no" -DPADD+= ${LIBREADLINE} ${LIBTERMCAP} -LDADD+= -lreadline -ltermcap +DPADD= ${LIBNTP} ${LIBEDIT} ${LIBM} ${LIBMD} ${LIBOPTS} +LDADD= ${LIBNTP} -ledit -lm -lmd ${LIBOPTS} CFLAGS+= -DHAVE_LIBREADLINE -DHAVE_READLINE_HISTORY_H \ -DHAVE_READLINE_READLINE_H + +.if ${MK_GNU_SUPPORT} != "no" +DPADD+= ${LIBTERMCAP} +LDADD+= -ltermcap +.endif + +.if ${MK_OPENSSL} != "no" && !defined(RELEASE_CRUNCH) +DPADD+= ${LIBCRYPTO} +LDADD+= -lcrypto .endif CLEANFILES+= .version version.c diff -urN src/usr.sbin/ntp/ntptime/Makefile src.ntp/usr.sbin/ntp/ntptime/Makefile --- src/usr.sbin/ntp/ntptime/Makefile 2005-01-28 17:08:11.000000000 +0100 +++ src.ntp/usr.sbin/ntp/ntptime/Makefile 2010-07-22 01:08:30.000000000 +0200 @@ -1,11 +1,22 @@ # $FreeBSD: src/usr.sbin/ntp/ntptime/Makefile,v 1.6 2005/01/28 16:08:11 ru Exp $ -.PATH: ${.CURDIR}/../../../contrib/ntp/util +NO_MAN= + +NTP_DIR= ${.CURDIR}/../../../contrib/ntp +SRC_DIR= ${NTP_DIR}/util + +.include "${.CURDIR}/../config.mk" + +.PATH: ${SRC_DIR} PROG= ntptime -NO_MAN= -CFLAGS+= -I${.CURDIR}/../../../contrib/ntp/include -I${.CURDIR}/../ +CFLAGS+= -I${NTP_DIR}/include +CFLAGS+= -I${NTP_DIR}/lib/isc/include +CFLAGS+= -I${NTP_DIR}/lib/isc/nothreads/include +CFLAGS+= -I${NTP_DIR}/lib/isc/unix/include +CFLAGS+= -I${NTP_DIR}/lib/isc/${ISC_ATOMIC_ARCH}/include +CFLAGS+= -I${.CURDIR}/../ DPADD= ${LIBNTP} LDADD= ${LIBNTP} diff -urN src/usr.sbin/ntp/scripts/mkver src.ntp/usr.sbin/ntp/scripts/mkver --- src/usr.sbin/ntp/scripts/mkver 2009-08-12 13:55:26.000000000 +0200 +++ src.ntp/usr.sbin/ntp/scripts/mkver 2010-07-22 01:08:30.000000000 +0200 @@ -6,7 +6,7 @@ ConfStr="$PROG" -ConfStr="$ConfStr 4.2.4p5" +ConfStr="$ConfStr 4.2.6p2" case "$CSET" in '') ;; diff -urN src/usr.sbin/ntp/sntp/Makefile src.ntp/usr.sbin/ntp/sntp/Makefile --- src/usr.sbin/ntp/sntp/Makefile 2008-08-22 18:00:48.000000000 +0200 +++ src.ntp/usr.sbin/ntp/sntp/Makefile 2010-07-22 01:08:30.000000000 +0200 @@ -1,16 +1,34 @@ # $FreeBSD: src/usr.sbin/ntp/sntp/Makefile,v 1.4 2008/08/22 16:00:48 roberto Exp $ -.PATH: ${.CURDIR}/../../../contrib/ntp/sntp +NO_MAN= + +NTP_DIR= ${.CURDIR}/../../../contrib/ntp +SRC_DIR= ${NTP_DIR}/sntp + +.include "${.CURDIR}/../config.mk" PROG= sntp -NO_MAN= -SRCS= internet.c main.c socket.c timing.c unix.c -CFLAGS+= -I${.CURDIR}/../../../contrib/ntp/include -I${.CURDIR}/../ \ - -DPACKAGE=\"sntp\" -DVERSION=\"1.6\" \ - -I${.CURDIR}/../../../contrib/ntp/libopts +.PATH: ${SRC_DIR} +SRCS= crypto.c kod_management.c log.c main.c \ + networking.c sntp-opts.c utilities.c + +CFLAGS+= -I${NTP_DIR}/include +CFLAGS+= -I${NTP_DIR}/lib/isc/include +CFLAGS+= -I${NTP_DIR}/lib/isc/nothreads/include +CFLAGS+= -I${NTP_DIR}/lib/isc/unix/include +CFLAGS+= -I${NTP_DIR}/lib/isc/${ISC_ATOMIC_ARCH}/include +CFLAGS+= -I${NTP_DIR}/libopts +CFLAGS+= -I${SRC_DIR} +CFLAGS+= -I${.CURDIR}/../ +CFLAGS+= -DPACKAGE=\"sntp\" -DVERSION=\"1.6\" \ + +DPADD= ${LIBNTP} ${LIBM} ${LIBOPTS} +LDADD= ${LIBNTP} -lm ${LIBOPTS} -DPADD= ${LIBM} ${LIBOPTS} -LDADD= -lm ${LIBOPTS} +.if ${MK_OPENSSL} != "no" && !defined(RELEASE_CRUNCH) +DPADD+= ${LIBCRYPTO} +LDADD+= -lcrypto +.endif .include